-
Notifications
You must be signed in to change notification settings - Fork 2k
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 checkbox input type in prompt dialog #1980
Allow checkbox input type in prompt dialog #1980
Conversation
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.
Hi @superruzafa! Thanks for putting up this PR; LGTM! Just one suggestion regarding spacing, and then good to go!
In the future it would be nice to update the onComplete
callback to accept the true type (boolean
, integer
, string
), but this is good for now. 😃
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.
That's exactly what I was looking for :)
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.
This PR allows the Prompt modal dialog to show
<input type="checkbox">
elements.You only have to call it by setting
inputType
tocheckbox
. You can also setdefaultValue
tofalse
/true
to uncheck/check the checkbox, respectively.The modal will return the string value
"true"
if the the checkbox was checked and"false"
otherwise..