防止vue2单张地图覆盖在Vuetify的导航抽屉顶部

问题描述 投票:0回答:1

我正在使用Vuetify来构建一个显示本地兴趣点的应用。该应用程序使用vue2-leaflet显示地图。不幸的是,地图从导航抽屉,对话框和加深屏幕的覆盖层中弹出。这是展示它的图像:

Navigation Drawer off - Showing where the map is supposed to be.Navigation Draawer on - Map is on top of navigation drawer

我该如何解决?

leaflet navigation-drawer vuetify.js z-index
1个回答
0
投票

这是z-index问题。尝试将以下内容添加到CSS:

.v-navigation-drawer--temporary {
    z-index: 1001;
}

您可以see a working example on Codepen。我认为这是将为您提供所需覆盖层的最小z-index值,但是您可能不得不反复尝试直到获得正确的值。

© www.soinside.com 2019 - 2024. All rights reserved.