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
I have searched for existing issues that already report this problem, without success.
Ionic Framework Version
v7.x
Current Behavior
When using other components that utilize the Angular CDK or similar methods to present content in an overlay (for example, a select, date, or color picker) within an Ionic modal, this overlay is affected by the Ionic modal's focus. This seems to be related to the class: "ion-disable-focus-trap".
Is there a way to disable this requirement when starting an Ionic modal via a declarative element or via ModalController?
This helps, but not gracefully, as this code has to be duplicated in all Ionic modals where there are other components that utilize the Angular CDK overlays or similar.
Using ModalController and passing a function to the component, something similar to this would be necessary:
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.
Prerequisites
Ionic Framework Version
v7.x
Current Behavior
When using other components that utilize the Angular CDK or similar methods to present content in an overlay (for example, a select, date, or color picker) within an Ionic modal, this overlay is affected by the Ionic modal's focus. This seems to be related to the class: "ion-disable-focus-trap".
Is there a way to disable this requirement when starting an Ionic modal via a declarative element or via ModalController?
I found a post on Ionic Forum: https://forum.ionicframework.com/t/work-around-for-ionic-modal-focus-trapping/216633/6 where a user described a similar issue and other user sugested a hack:
This helps, but not gracefully, as this code has to be duplicated in all Ionic modals where there are other components that utilize the Angular CDK overlays or similar.
Using ModalController and passing a function to the component, something similar to this would be necessary:
Expected Behavior
Let user define the modal focus behavior or disable focus trap it not currently necessary ionic framework.
Steps to Reproduce
Code Reproduction URL
https://hatsbytes@bitbucket.org/hatslab/taigaui-combobox-ionmodal.git
Ionic Info
Ionic:
Ionic CLI : 7.1.5
Ionic Framework : @ionic/angular 7.7.2
@angular-devkit/build-angular : 17.1.3
@angular-devkit/schematics : 17.1.3
@angular/cli : 17.1.3
@ionic/angular-toolkit : 9.0.0
Capacitor:
Capacitor CLI : 5.5.1
@capacitor/android : not installed
@capacitor/core : not installed
@capacitor/ios : not installed
Utility:
cordova-res : not installed globally
native-run : 1.7.4
System:
NodeJS : v20.10.0 (C:\Program Files\nodejs\node.exe)
npm : 10.2.3
OS : Windows 10
Additional Information
No response
The text was updated successfully, but these errors were encountered: