带三角形下标的提示框(按钮button)

时间:2022-10-09 06:39:26
HTML:
<div class="leaflet-popup-content-wrapper">
<div class="leaflet-popup-content" >按钮</div>
</div>
<div class="leaflet-popup-tip-container">
<div class="leaflet-popup-tip"></div>
</div>

css:
<style>
.leaflet-popup-content-wrapper,.leaflet-popup-tip{
background:white;
box-shadow:0 1px 14px rgba(0,0,0,0.4)
}
.leaflet-popup-content-wrapper{
zoom:1;
border:1px solid #999;
padding:1px;
border-radius:12px;
text-align:center !important;
}
.leaflet-popup-tip-container{
margin:-1px auto;
width:40px;
height:20px;
position:relative;
overflow:hidden;
}
.leaflet-popup-tip{
width:17px;
height:17px;
padding:1px;
margin:-10px auto 0;
-webkit-transform:rotate(45deg);
-moz-transform:rotate(45deg);
-ms-transform:rotate(45deg);
-o-transform:rotate(45deg);
transform:rotate(45deg);
}
.leaflet-popup-content{
width: 51px;
margin:0 !important;
overflow: hidden;
padding: 10px;
line-height: 1.4
}
</style>