本文介紹了傳單 - 模式在地圖后面打開的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!
問題描述
我正在使用 leaflet
和 modalcss 在其中顯示模式一張地圖.這就像 leaflet
v0.7.7 的魅力一樣.查看此 Plunker:點擊--> 點擊縮放控件下方的按鈕.
I'm using leaflet
and modalcss to display a modal within a map.
This worked like a charm with leaflet
v0.7.7. See this Plunker: click
--> Click the button under the zoom controls.
當我切換到 leaflet
v1.2.0 時,模式會打開但在地圖后面.查看此 Plunker:點擊
When I switch to leaflet
v1.2.0 the modal gets opened but behind the map. See this Plunker: click
為什么會這樣?關于如何在舊版本的 leaflet
中顯示模式的任何想法?謝謝!
Why is this happening?
Any idea on how to show the modal in front of the map like in the old version of leaflet
?
Thanks!
推薦答案
將此 CSS 規則應用于地圖和模型:
Apply this CSS rules to map and model:
#map{ z-index:1; }
#modal{ z-index:2; }
這篇關于傳單 - 模式在地圖后面打開的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!
【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!