Just noticed that when I display a dialog over a google map, the small links "Map data...", "Terms of use" and the Google logo at the bottom of the map are displayed OVER the dialog overlay. Their z-index are 1000000 and 1000001. The dialog overlay seems to have a z-index of 79. Why so small?
The same happens with the overlay of the sidebar.
Note: there is no issue under Chrome (and I don't know why because the z-indexes are the same...)
It seems I can workaround the problem by explicitely setting a small z-index on my map.
@cadilhac I'm wondering why the Google Maps Widget uses so high z-indexs for their widget. This seems to me like, lazy typing any high integers for the z-index.
I'm not sure, why we should change the z-index, there will be always problems with the z-index, because every developer uses a different number.
To be honest, I think - using the workaround / modification of the z-index is a more elegant solution.
If you have any thoughts, please let me know.
$z-index-toast: 105 !default;
$z-index-tooltip: 100 !default;
$z-index-menu: 100 !default;
$z-index-select: 90 !default;
$z-index-dialog: 80 !default;
$z-index-bottom-sheet: 70 !default;
$z-index-scroll-mask: 65 !default;
$z-index-sidenav: 60 !default;
$z-index-backdrop: 50 !default;
$z-index-fab: 20 !default;
You're right and I agree that you should not adapt your code to every possible z-index in 3rd parties. I was totally fine with setting an overriden z-index on the map.
Perfect, if there are anymore thoughts you have, just let me know and we'll discuss.
Thought I'd bring this one back from the grave with a question.
Why does $mdDialog not support a configuration option of zIndex like the $mdPanel one does? I feel like this logically makes sense and could solve everyone's problems...
Going to track ability to specify a custom z-index for components in https://github.com/angular/material/issues/8475.
Most helpful comment
Thought I'd bring this one back from the grave with a question.
Why does $mdDialog not support a configuration option of zIndex like the $mdPanel one does? I feel like this logically makes sense and could solve everyone's problems...