mirror of
https://github.com/enzet/map-machine.git
synced 2025-06-06 21:01:53 +02:00
Issue #62: fix selector escaping.
This commit is contained in:
parent
eae7f706f2
commit
e284e34c72
2 changed files with 3 additions and 7 deletions
|
@ -168,7 +168,9 @@ class NodeMatcher(Matcher):
|
|||
"""Get MapCSS 0.2 selector for one key."""
|
||||
if value == "*":
|
||||
return f"[{key}]"
|
||||
return f"[{key}={value}]"
|
||||
if '"' in value:
|
||||
return f"[{key}='{value}']"
|
||||
return f'[{key}="{value}"]'
|
||||
|
||||
return "".join([get_selector(x, y) for (x, y) in self.tags.items()])
|
||||
|
||||
|
|
|
@ -992,12 +992,6 @@ node_icons:
|
|||
{shape: digit_4, offset: [-2, 2]},
|
||||
{shape: digit_0, offset: [2, 2]},
|
||||
]
|
||||
- tags: {traffic_sign: maxspeed, maxspeed: ".."}
|
||||
shapes: [
|
||||
circle_11,
|
||||
{shape: digit_3, offset: [-2, 0], color: "#FFFFFF"},
|
||||
{shape: digit_0, offset: [2, 0], color: "#FFFFFF"},
|
||||
]
|
||||
- tags: {traffic_sign: stop}
|
||||
shapes: [stop]
|
||||
- tags: {highway: give_way}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue