-
-
Notifications
You must be signed in to change notification settings - Fork 50.5k
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
Allow to set type of Popconfirm OK button #6848
Conversation
@yociduo, thanks for your PR! By analyzing the history of the files in this pull request, we identified @afc163, @benjycui and @waywardmonkeys to be potential reviewers. |
Link Issue #6840 |
components/popconfirm/index.en-US.md
Outdated
| cancelText| text of the cancel button | string | Cancel | | ||
| cancelType| type of the confirmation button | string | none | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we need a cancelType
, let's keep it as simple as possible.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove cancelType
.
|
|
Nope. |
Codecov Report
@@ Coverage Diff @@
## feature-2.13 #6848 +/- ##
=============================================
Coverage 86.02% 86.02%
=============================================
Files 231 231
Lines 4917 4917
Branches 1406 1406
=============================================
Hits 4230 4230
Misses 687 687
Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## feature-2.13 #6848 +/- ##
=============================================
Coverage 86.06% 86.06%
=============================================
Files 231 231
Lines 4957 4957
Branches 1416 1416
=============================================
Hits 4266 4266
Misses 691 691
Continue to review full report at Codecov.
|
@afc163 Added |
Could you rebase the |
Ok |
Please make sure travis ci is passed~ |
Passed |
@benjycui remove cancel type, but I think cancel type is useful, because people can't override the footer in |
I don't think we need another type of cancel type but |
Ok, removed |
components/popconfirm/demo/basic.md
Outdated
@@ -27,7 +27,7 @@ function cancel(e) { | |||
} | |||
|
|||
ReactDOM.render( | |||
<Popconfirm title="Are you sure delete this task?" onConfirm={confirm} onCancel={cancel} okText="Yes" cancelText="No"> | |||
<Popconfirm title="Are you sure delete this task?" onConfirm={confirm} onCancel={cancel} okText="Yes" okType="danger" cancelText="No" cancelType="dashed"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You forget to update demo
components/modal/index.en-US.md
Outdated
| cancelText | Text of cancel button | string | Cancel | | ||
| cancelType| type of the confirmation button | string | none | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And docs ....
Just grep -r 'cancelType' ./components
to find all the cancelType and remove it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, updated
components/popconfirm/demo/basic.md
Outdated
@@ -27,7 +27,7 @@ function cancel(e) { | |||
} | |||
|
|||
ReactDOM.render( | |||
<Popconfirm title="Are you sure delete this task?" onConfirm={confirm} onCancel={cancel} okText="Yes" cancelText="No"> | |||
<Popconfirm title="Are you sure delete this task?" onConfirm={confirm} onCancel={cancel} okText="Yes" okType="danger" cancelText="No"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个例子不要改。
First of all, thank you for your contribution! :-)
Please makes sure that these checkboxes are checked before submitting your PR, thank you!
master
, feature for latest active branchfeature-x.x
.npm run lint
and fix those errors before submitting in order to keep consistent code style.Extra checklist:
if isBugFix :
elif isNewFeature :