Add two_sided option

This commit is contained in:
Pieter Vander Vennet 2023-03-24 12:16:41 +01:00
parent b99588b4ba
commit 9cb80cd001
3 changed files with 99 additions and 4 deletions

View file

@ -64,6 +64,19 @@
"images",
{
"mappings": [
{
"if": {
"and":["backrest=yes","two_sided=yes"]
},
"then": {
"en": "This bench is two-sided and shares the backrest",
"nl": "Dit is een dubbele bank waarbij de rugleuning gedeeld wordt"
},
"icon": {
"path": "./assets/layers/bench/two_sided.svg",
"class": "large"
}
},
{
"if": "backrest=yes",
"then": {
@ -86,7 +99,8 @@
"ca": "Té espatller",
"da": "Har et ryglæn",
"cs": "Má opěradlo"
}
},
"addExtraTags": ["two_sided=no"]
},
{
"if": "backrest=no",
@ -438,7 +452,10 @@
"labels": [
"bench-questions"
],
"id": "bench-direction"
"id": "bench-direction",
"condition": {
"and": ["two_sided!=yes"]
}
},
{
"render": {
@ -1020,4 +1037,4 @@
},
"has_image"
]
}
}

View file

@ -8,5 +8,13 @@
"sources": [
"https://github.com/streetcomplete/StreetComplete/"
]
},
{
"path": "two_sided.svg",
"license": "CC0",
"authors": [
"Pieter Vander Vennet"
],
"sources": ["https://commons.wikimedia.org/wiki/File:ISO_7010_P018.svg"]
}
]
]

View file

@ -0,0 +1,70 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
width="238.05174"
height="163.948"
fill-rule="evenodd"
version="1.1"
id="svg8"
sodipodi:docname="two_sided.svg"
inkscape:version="1.1.2 (0a00cf5339, 2022-02-04)"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<defs
id="defs12" />
<sodipodi:namedview
id="namedview10"
pagecolor="#ffffff"
bordercolor="#eeeeee"
borderopacity="1"
inkscape:pageshadow="0"
inkscape:pageopacity="0"
inkscape:pagecheckerboard="0"
showgrid="false"
inkscape:zoom="1.6993326"
inkscape:cx="102.39314"
inkscape:cy="60.906263"
inkscape:window-width="1920"
inkscape:window-height="995"
inkscape:window-x="0"
inkscape:window-y="0"
inkscape:window-maximized="1"
inkscape:current-layer="layer1" />
<g
inkscape:groupmode="layer"
id="layer1"
inkscape:label="Layer 1"
transform="translate(-52.206125,-38.533)">
<path
d="m 114.88,108.537 -26.997,13.016 c -4.026,2.032 -6.642,5.325 -5.573,9.458 1.069,4.133 5.753,7.177 9.458,5.573 l 33.194,-14.617 3.372,-5.684 v 19.709 H 94.399 c -1.521,0 -3.113,0.738 -4.188,1.813 l -35.405,35.406 c -3.466,3.466 -3.467,9.14 0,12.606 3.467,3.466 9.14,3.467 12.606,0 l 18.664,-18.664 v 26.414 c 0,4.903 4.011,8.914 8.914,8.914 4.903,0 8.914,-4.011 8.914,-8.914 v -39.748 h 53.999 v -63.92 c 0,-15.054 -19.966,-20.225 -27.381,-7.728 z m 44.6,-54.296 c 0,-8.675 -7.033,-15.708 -15.709,-15.708 -8.67483,0.0011 -15.7069,7.033169 -15.708,15.708 0,8.676 7.033,15.709 15.708,15.709 8.675,0 15.709,-7.033 15.709,-15.709"
id="path4"
sodipodi:nodetypes="ccsccccsccsccsssccscccccsc"
style="fill:#7a7a7a;fill-opacity:1" />
<rect
style="fill:#000000;fill-opacity:1;stroke:none;stroke-width:8.7864;stroke-linecap:round;stroke-linejoin:round;stroke-opacity:0.991298"
id="rect2641"
width="14.618492"
height="53.306324"
x="164.56784"
y="116.40991" />
<path
d="m 227.584,108.537 26.99699,13.016 c 4.026,2.032 6.642,5.325 5.573,9.458 -1.069,4.133 -5.753,7.177 -9.458,5.573 L 217.502,121.967 214.13,116.283 v 19.709 h 33.93499 c 1.521,0 3.113,0.738 4.188,1.813 l 35.405,35.406 c 3.466,3.466 3.467,9.14 0,12.606 -3.467,3.466 -9.14,3.467 -12.606,0 l -18.664,-18.664 v 26.414 c 0,4.903 -4.011,8.914 -8.914,8.914 -4.903,0 -8.914,-4.011 -8.914,-8.914 V 153.819 H 184.561 v -63.92 c 0,-15.054 19.966,-20.225 27.381,-7.728 z m -44.6,-54.296 c 0,-8.675 7.033,-15.708 15.709,-15.708 8.67483,0.0011 15.7069,7.033169 15.708,15.708 0,8.676 -7.033,15.709 -15.708,15.709 -8.675,0 -15.709,-7.033 -15.709,-15.709"
id="path2822"
sodipodi:nodetypes="ccsccccsccsccsssccscccccsc"
style="fill:#7a7a7a;fill-opacity:1" />
</g>
<g
inkscape:groupmode="layer"
id="layer2"
inkscape:label="Layer 2"
transform="translate(-52.206125,-38.533)">
<rect
style="fill:#000000;fill-opacity:0.936032;stroke:none;stroke-width:8;stroke-linecap:round;stroke-linejoin:round;stroke-opacity:0.991298"
id="rect1529"
width="119.68268"
height="16.931273"
x="110.08833"
y="158.63087" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.3 KiB