-
-
Notifications
You must be signed in to change notification settings - Fork 46.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create modal #39660
Closed
Closed
Create modal #39660
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
之前提过一次:#36734 ,这次添加了结合 useModal 的用法。可以看下这个设计如何,如果可以的话我再继续完善代码、文档、PR等。 |
bowencool
force-pushed
the
createModal
branch
from
December 19, 2022 13:05
a95ae32
to
1e00488
Compare
我们目前没有计划继续增强 static 方法的使用,还是推荐用 useModal 或 。 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
[中文版模板 / Chinese template]
🤔 This is a ...
🔗 Related issue link
💡 Background and solution
📝 Changelog
create()
to create a one-time modal dialog dynamically without maintenance loading and visible. Let onCancel/onOk function return a promise object to delay closing the dialog. onOK takes the parameters passed by the content component.create()
可以快捷地创建一次性弹窗,无需维护 loading 和 visible。 onCancel/onOk 返回 promise 可以延迟关闭。 onOk 可以拿到内容组件传递的参数。☑️ Self-Check before Merge