You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug: ion-toggle with ion-item not properly toggling #25570
I have searched for existing issues that already report this problem, without success.
Ionic Framework Version
v4.x
v5.x
v6.x
Nightly
Current Behavior
I have a ion-toggle inside an ion-item as the documentation details, and opposed to what I expected and desire, when I click on the ion-item (not including the ion-toggle) the toggle does not change, only when I click exactly on the toggle.
Expected Behavior
I expected that clicking anywhere on the ion-item would toggle the ion-toggle, as in mobile and even in desktop is pretty difficult and in general uncomfortable clicking exactly the toggle.
Steps to Reproduce
I am using Vue 3, and this is (an adaptation of) the code that I'm using:
Thanks for the issue. This behavior was a design decision made to align with iOS. However, the behavior has been seen as confusing by others, so I think it makes sense to align the ion-toggle behavior with that of other components such as ion-checkbox.
Thanks for the report. In Ionic 7.0 we will be introducing a new ion-toggle syntax that resolves this issue. Details on the syntax change can be found here: #25660
The work for this was completed in #26357, so I am going to close this issue. We will have a public beta period in the future for developers to test and provide feedback on Ionic 7. Please let me know if there are any questions.
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.
Activity
liamdebeasi commentedon Jul 5, 2022
Thanks for the issue. This behavior was a design decision made to align with iOS. However, the behavior has been seen as confusing by others, so I think it makes sense to align the
ion-togglebehavior with that of other components such asion-checkbox.[-]bug: ion-toggle with ion-item not properly toggleling[/-][+]bug: ion-toggle with ion-item not properly toggling[/+]HipyCas commentedon Aug 31, 2022
Any updates on this?
liamdebeasi commentedon Aug 31, 2022
We have a proposal for updating the form control API that should fix the issue: #25660
feat(toggle): component can be used outside of ion-item (#26357)
liamdebeasi commentedon Nov 29, 2022
Thanks for the report. In Ionic 7.0 we will be introducing a new
ion-togglesyntax that resolves this issue. Details on the syntax change can be found here: #25660The work for this was completed in #26357, so I am going to close this issue. We will have a public beta period in the future for developers to test and provide feedback on Ionic 7. Please let me know if there are any questions.
ionitron-bot commentedon Dec 29, 2022
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.