带对话框的自定义标记 [英] Custom marker with dialog box
本文介绍了带对话框的自定义标记的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何实现如上所示的对话框.到目前为止,这是我现在可以做的
How do I achieve dialog like those shown above. So far this is what I can do right now
map.addLayer({
"id": "markers",
"type": "symbol",
"source": "markers",
"interactive": true,
"layout": {
"text-field": "{price2}",
"text-font": ["Open Sans Semibold", "Arial Unicode MS Bold"],
"text-offset": [0, 0.6],
"text-anchor": "top",
"text-size": 12,
"text-letter-spacing": 0.05,
"icon-image": "marker-15"
},
"paint": {
"text-color": "#fff",
"text-halo-width": 2,
"text-halo-color": "rgb(11, 148, 68)"
}
});
我是否必须使用studio才能达到这种效果?
Do I have to use studio to have such effect?
推荐答案
The only way I see to do this is to use markers with a custom HTML Element. You won't be able to use a source though.
这篇关于带对话框的自定义标记的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文