本文介紹了如何更改 LeafletJS 中的默認加載磁貼顏色?的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!
問題描述
默認情況下,leafletJS 在加載地圖時,背景圖塊都是灰色的.我想將該顏色更改為黑色(或任何其他任意顏色).我該怎么做?
By default, when leafletJS is loading a map, the background tiles are all grey. I'd like to change that color to be black (or any other arbitrary color). How can I go about doing this?
推薦答案
它由文件'leaflet.css'中的以下css規則控制:
It's controlled by the below css rule in the file 'leaflet.css':
.leaflet-container {
background: #ddd;
}
所以你只需要改變這個規則.
so you just need to change this rule.
這篇關于如何更改 LeafletJS 中的默認加載磁貼顏色?的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!
【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!