-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
zIndex of ConfirmDialog is not adaptive (always less by one) #13498
Comments
Same issue |
Can you share a stackblitz, please? |
DemoSteps to reproduce
Expected behavior
Supposed ProblemI deep to styles and source code, and this is what I found out: ConfirmDialog moveOnTop method call ZIndexUtils.set() util and sets this ConfirmDialog z-indexes styles and his backdrop (current z-index - 1). And finally wrapper (backdrop) has same z-index (example on the screenshot above = z-index: 1101) the same as the previously opened sidebar z-index (example on the screenshot above = z-index: 1101). This leads to this problem described above. Dialog modals (Dialog/DynamicDialog/ConfirmDialog components) uses backdrop as wrapper over dialog content. And its own (content) styles for z-index: 1102 overrides by backdrop z-index: 1101. |
I can suggest such a solution - increment the current z-index, which is stored in the ZIndexUtils utility for the Dialog, not by one, but by two points at once, then the backdrop value will be higher than the sidebar value. |
This is what we did in our code to get around this problem, and it works fine. |
Hi @dkhrunov, thanks for your examples and explanation. |
Good job 💪 & Thank you ! |
Describe the bug
The modal ConfirmDialog opened after a normal modal dialog has a zIndex lower than the normal dialog and is not visible anymore.
Environment
Angular version: 14.2.0
PrimeNG version: 14.2.3
Reproducer
No response
Angular version
14.2.0
PrimeNG version
14.2.3
Build / Runtime
Angular CLI App
Language
TypeScript
Node version (for AoT issues node --version)
9.1.2
Browser(s)
No response
Steps to reproduce the behavior
No response
Expected behavior
No response
The text was updated successfully, but these errors were encountered: