这个问题是之前提出的问题的延续 how to add a gradient over a leaflet map?
我试图在传单地图的左侧添加文字叠加层,从左到右有一个黑色透明的渐变背景。
修改我的文本(使用css设置为白色),在地图显示无效后加载。谁能告诉我我需要做些什么来让我的文字显示在地图上?谢谢!
<style>
#map-id {
height: 100%;
width: 100%;
position: absolute;
}
html,body{margin: 0; padding: 0}
#map-id:before {
position: absolute;
content: '';
height: 100%;
width: 100%;
background: linear-gradient(to right, rgba(0, 0, 0, 1), rgba(0, 0, 0, 0));
pointer-events: none;
z-index: 999;
}
#menu-text{
display: inline-bloc;
}
#menu-text:before{
position: absolute;
content: '';
height: 100%;
width: 100%;
color: white;
pointer-events: none;
z-index: 999;
}
</style>
<div id="map-id">
<script type="text/javascript" src="{% static "js/map.js" %}"></script>
</div>
<div id="menu-text">
<h1>
This is the text that should be showing up, but isn't.
</h1>
</div>
侧面显示为黑色,没有白色文字。
答案 0 :(得分:1)
您在上一个问题的回复中已经有了实例。 http://codepen.io/hkadyanji/pen/bwNLKK
您的代码已损坏,namespaces = cmds.namespaceInfo(lon=True)
current_namespace = cmds.namespaceInfo(currentNamespace=True)
references = cmds.ls(type="reference")
标记不应放入shldr = cmds.xform('*:L_shldrFK_match_LOC', ws = True, t = True, q = True)