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
[4.12.0] [ion-picker] dismiss function doesn't pass data and role data to onDidDismiss #18454
Comments
Thanks for the issue! I was able to reproduce this with the following: https://codepen.io/brandyscarney/pen/YbggLb I believe this line of code is the problem: https://github.com/ionic-team/ionic/blob/0a7aae28a7eb0270cdcd100933c01850403b66db/core/src/components/picker/picker.tsx#L176 Also, the backdrop dismiss is wrong: https://github.com/ionic-team/ionic/blob/0a7aae28a7eb0270cdcd100933c01850403b66db/core/src/components/picker/picker.tsx#L201 |
Any updates on this issue? |
Also interested in a fix for this. Cancelling a picker is a pretty fundamental operation for a core component. |
Same issue here |
Any updates ? Having the same issue. |
Hi Team, Any updates for this issue? |
Hi guys,
Don't need to use the onDidDismiss anymore. |
Hi, Any news? |
Hi, any news?
return undefiined |
PR submitted here: #19787 Dev release is based on the |
…or backdrop (#19787) - Pass the button role on dismiss of the picker (on button click or backdrop tap) - Pass the selected values in the data on dismiss ONLY if the dismiss role is not "cancel" or "backdrop" - Call the cancel handler when dismissing if the role is "cancel" or "backdrop" Fixes #18454
…or backdrop (#19787) - Pass the button role on dismiss of the picker (on button click or backdrop tap) - Pass the selected values in the data on dismiss ONLY if the dismiss role is not "cancel" or "backdrop" - Call the cancel handler when dismissing if the role is "cancel" or "backdrop" Fixes #18454
…or backdrop (#19787) - Pass the button role on dismiss of the picker (on button click or backdrop tap) - Pass the selected values in the data on dismiss ONLY if the dismiss role is not "cancel" or "backdrop" - Call the cancel handler when dismissing if the role is "cancel" or "backdrop" Fixes #18454
fix won't be backported to 4.x branch? |
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out. |
Bug Report
Ionic version:
4.12.0
Current behavior:
When the ion-picker gets dismissed the onDidDismiss() data and role properties are both undefined.
Expected behavior:
When the picker gets dismissed it should have the role parameter set. E.g. When closing via a Button with that button's role.
So we can perform some action based on whether the user clicked the button or not
Steps to reproduce:
Create a picker, present it and tap on one of the buttons so the onDidDismiss() method is called.
Ionic info:
The text was updated successfully, but these errors were encountered: