I have been using PrimeNG in the project.
I came across one issue regarding the focus of the
p-dialog component.
Even in the example given in PrimeNG website we are able to reproduce this issue.
e.g. https://www.primefaces.org/primeng/#/dialog
Steps to reproduce this:
- Click on the 'show' button
- Press 'Tab' on the keyboard.
You can see the focus is lost and goes to the back screen.
Now I have tried using modal
attribute provided in the document with the values modal
or true
.
Anybody has faced this issue? Is there anything that I am missing?
When the dialog opens, how should I keep and restrict the focus on the dialog and not on the back screen?