Dialog: closeOnEscape
is not working when closable
is false
#6922
Labels
Type: Bug
Issue contains a bug related to a specific component. Something about the component is not working
Milestone
Describe the bug
Following API documentation from the https://primevue.org/dialog/#api.dialog.props I faced with unexpected behavior of Dialog component.
I wanted to use Dialog: without closable button "X", with possibility to close Dialog on Escape button, also on clicking to the background which is disabled using modal prop. Removing "X" button will block functionality of the Escape button and focus will be lost in background until components within Dialog comes to their turn to be focused.
Reproducer
https://stackblitz.com/edit/primevue-nuxt-issue-template-4yg7uf?file=app.vue
PrimeVue version
^4.1.1
Vue version
4.x
Language
TypeScript
Build / Runtime
Nuxt
Browser(s)
Firefox 133.0
Steps to reproduce the behavior
First case
Second case
Expected behavior
Removing "X" button from the dialog with Dialog prop "closable", I want to be able to use Escape button and it's behavior (closing dialog). Also, after opening the Dialog, I expect to focus be inside of the Dialog on very start, not to go outside of it.
Thanks for everything! :-)
The text was updated successfully, but these errors were encountered: