Automate traffic sign theme
46
assets/layers/traffic_sign/README.md
Normal file
|
@ -0,0 +1,46 @@
|
|||
# Traffic sign layer
|
||||
|
||||
As you might have noticed, the traffic sign theme and this layer is quite complex and large.
|
||||
To keep this manageable, this is generated from a JSON file per country.
|
||||
|
||||
## Adding a new country
|
||||
|
||||
Adding a country is as easy as creating a new JSON(`.protojson`) file in the `signs` folder named after the country code and adding the required images in a subfolder named after the country code.
|
||||
|
||||
## Regenerating the layer
|
||||
|
||||
To regenerate the layer, run `npm run generate:traffic_signs`.
|
||||
|
||||
## The JSON file format
|
||||
|
||||
The JSON files are formatted formatted based on [this](https://osm.rlin.eu/traffic_sign/schema/schema.json) JSON schema.
|
||||
A small example, not showing all properties is shown below.
|
||||
|
||||
```jsonc
|
||||
{
|
||||
// Indication for the JSON schema
|
||||
"$schema": "https://osm.rlin.eu/traffic_sign/schema/schema.json",
|
||||
// Name of the file
|
||||
"name": "Dutch Traffic Signs",
|
||||
// Country code
|
||||
"country": "NL",
|
||||
// Description of the file
|
||||
"description": "Traffic signs in the Netherlands",
|
||||
// Version of the file, can be either a date, a version number or something else
|
||||
"version": "1.0",
|
||||
// Object containing all traffic signs
|
||||
"traffic_signs": [
|
||||
{
|
||||
// ID of the traffic sign, as to be used in OSM
|
||||
"id": "NL:G11",
|
||||
// English name of the traffic sign
|
||||
"name": "Mandatory cycleway",
|
||||
// Image object, can be remote or as in this case local
|
||||
"image": {
|
||||
// File path of the image starting from the country folder in the images folder
|
||||
"file": "G/Nederlands_verkeersbord_G11.svg"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
133
assets/layers/traffic_sign/generateSigns.ts
Normal file
|
@ -0,0 +1,133 @@
|
|||
import { readFileSync, writeFileSync, readdirSync } from "fs";
|
||||
import type { LayerConfigJson } from "../../../Models/ThemeConfig/Json/LayerConfigJson";
|
||||
import PointRenderingConfigJson from "../../../Models/ThemeConfig/Json/PointRenderingConfigJson";
|
||||
import { MappingConfigJson, QuestionableTagRenderingConfigJson } from "../../../Models/ThemeConfig/Json/QuestionableTagRenderingConfigJson";
|
||||
import { TagRenderingConfigJson } from "../../../Models/ThemeConfig/Json/TagRenderingConfigJson";
|
||||
|
||||
interface SignFile {
|
||||
name: string;
|
||||
description: string;
|
||||
version: string;
|
||||
country: string;
|
||||
traffic_signs: TrafficSign[];
|
||||
}
|
||||
|
||||
interface TrafficSign {
|
||||
id: string;
|
||||
name: string;
|
||||
image: LocalImage;
|
||||
use?: {
|
||||
way: boolean;
|
||||
node: boolean;
|
||||
};
|
||||
implications?: Implication[];
|
||||
}
|
||||
|
||||
interface LocalImage {
|
||||
file: string;
|
||||
}
|
||||
|
||||
interface Implication {
|
||||
key: string;
|
||||
value: string;
|
||||
}
|
||||
|
||||
const worldWideMappings: MappingConfigJson[] = [
|
||||
{
|
||||
if: "traffic_sign=city_limit",
|
||||
then: {
|
||||
en: "City limit",
|
||||
},
|
||||
},
|
||||
{
|
||||
if: "traffic_sign=maxspeed",
|
||||
then: {
|
||||
en: "Maximum speed",
|
||||
},
|
||||
}
|
||||
]
|
||||
|
||||
function main(){
|
||||
// Open original file
|
||||
const originalFile = readFileSync("traffic_sign.json", "utf8");
|
||||
const originalLayer = JSON.parse(originalFile) as LayerConfigJson
|
||||
// Save current tagrendering, so we can use the translations in there
|
||||
const originalTagRenderings = originalLayer.tagRenderings as QuestionableTagRenderingConfigJson[];
|
||||
const originalSignTagRendering = originalTagRenderings.find(t => t.id === "traffic_sign") as QuestionableTagRenderingConfigJson;
|
||||
const originalSignMappings = originalSignTagRendering.mappings;
|
||||
const originalSignMapRendering = originalLayer.mapRendering[0] as PointRenderingConfigJson;
|
||||
const originalSignIcon = originalSignMapRendering.icon as TagRenderingConfigJson;
|
||||
|
||||
// Create new list of mappings
|
||||
const mappings: MappingConfigJson[] = [];
|
||||
const iconMappings: MappingConfigJson[] = [];
|
||||
|
||||
// Add world wide mappings
|
||||
for(const mapping of worldWideMappings){
|
||||
mappings.push({
|
||||
...mapping,
|
||||
then: {
|
||||
en: mapping.then.en,
|
||||
...originalSignMappings.find(m => m.if === mapping.if)?.then,
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
// Check which different files there are
|
||||
const files = readdirSync("signs");
|
||||
for(const file of files){
|
||||
const signFile = readFileSync("signs/" + file, "utf8");
|
||||
const signs = JSON.parse(signFile) as SignFile;
|
||||
for(const sign of signs.traffic_signs){
|
||||
const originalMapping = originalSignMappings.find(m => m.if === "traffic_sign=" + sign.id);
|
||||
// Create new mapping, reusing original translations
|
||||
const mapping: MappingConfigJson = {
|
||||
if: "traffic_sign=" + sign.id,
|
||||
then: {
|
||||
...originalMapping?.then,
|
||||
en: sign.name,
|
||||
},
|
||||
hideInAnswer: "_country!="+signs.country.toLowerCase()
|
||||
};
|
||||
const icon: MappingConfigJson = {
|
||||
if: "traffic_sign=" + sign.id + "(;.*)*$",
|
||||
then:
|
||||
"./assets/layers/traffic_sign/images/"+signs.country.toLowerCase()+"/"+sign.image.file
|
||||
};
|
||||
mappings.push(mapping);
|
||||
iconMappings.push(icon);
|
||||
}
|
||||
}
|
||||
|
||||
// Create new layer
|
||||
const newLayer: LayerConfigJson = {
|
||||
...originalLayer,
|
||||
tagRenderings: [
|
||||
originalLayer.tagRenderings[0],
|
||||
{
|
||||
...originalSignTagRendering,
|
||||
mappings: mappings,
|
||||
}
|
||||
],
|
||||
mapRendering: [
|
||||
{
|
||||
...originalSignMapRendering,
|
||||
icon: {
|
||||
...originalSignIcon,
|
||||
mappings: iconMappings,
|
||||
}
|
||||
}
|
||||
]
|
||||
};
|
||||
|
||||
for (let i = 2; i < originalLayer.tagRenderings.length; i++) {
|
||||
newLayer.tagRenderings.push(originalLayer.tagRenderings[i]);
|
||||
}
|
||||
|
||||
// Write new layer to file
|
||||
writeFileSync("traffic_sign.json", JSON.stringify(newLayer, null, 2));
|
||||
|
||||
|
||||
}
|
||||
|
||||
main();
|
|
@ -0,0 +1,10 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg id="Nederlands_verkeersbord_F1" width="300" height="300" viewBox="0 0 300 300" xmlns="http://www.w3.org/2000/svg" version="1.1">
|
||||
|
||||
<circle id="witte_cirkel_met_rode_rand" cx="150" cy="150" r="130.5" fill="#f7fbf5" stroke="#c1121c" stroke-width="39"/>
|
||||
|
||||
<path id="rode_auto" fill="#c1121c" d="M 61.16843,156.36794 C 60.62604,156.36794 60.17922,155.91863 60.17922,155.34678 L 60.17922,146.37693 C 60.17922,145.80508 60.62604,145.35577 61.16843,145.35577 L 61.80639,145.35577 C 62.34878,145.35577 62.7956,145.80508 62.7956,146.37693 L 62.7956,155.34678 C 62.7956,155.91863 62.34878,156.36794 61.80639,156.36794 L 61.16843,156.36794 z M 86.63138,153.10841 L 108.13749,153.10841 L 108.13749,156.55584 L 86.63138,156.55584 L 86.63138,153.10841 z M 97.48001,165.29695 L 121.98561,165.29695 L 121.98561,176.14574 C 121.98561,178.28609 123.61278,178.18806 123.61278,178.18806 L 130.98406,178.18806 C 130.98406,178.18806 132.61124,178.28609 132.61124,176.14574 L 132.61124,165.29695 L 133.31291,165.29695 L 138.29082,159.83988 L 138.29082,142.54554 L 133.31291,138.97557 L 126.10173,122.28576 C 109.95663,120.24344 97.38444,120.08006 97.38444,120.17809 C 97.38444,120.08006 84.81225,120.24344 68.699,122.28576 L 61.45596,138.97557 L 56.47806,142.54554 L 56.47806,159.83988 L 61.45596,165.29695 L 62.18949,165.29695 L 62.18949,176.14574 C 62.18949,178.28609 63.78481,178.18806 63.78481,178.18806 L 71.18795,178.18806 C 71.18795,178.18806 72.78326,178.28609 72.78326,176.14574 L 72.78326,165.29695 L 97.48001,165.29695 z M 65.92251,138.87754 L 65.8588,139.03276 L 71.34724,126.42758 C 87.49316,124.38526 97.38444,124.23005 97.38444,124.32808 C 97.38444,124.23005 107.27571,124.38526 123.42164,126.42758 L 128.94193,138.87754 L 128.84636,139.06544 C 128.94193,139.03276 97.38444,138.77951 97.38444,138.87754 C 97.38444,138.77951 65.92251,138.87754 65.92251,138.87754 z M 133.05805,156.36794 C 132.51566,156.36794 132.1007,155.91863 132.1007,155.34678 L 132.1007,146.37693 C 132.1007,145.80508 132.51566,145.35577 133.05805,145.35577 L 133.69602,145.35577 C 134.23841,145.35577 134.68523,145.80508 134.68523,146.37693 L 134.68523,155.34678 C 134.68523,155.91863 134.23841,156.36794 133.69602,156.36794 L 133.05805,156.36794"/>
|
||||
|
||||
<path id="zwarte_auto" fill="#2a2d2f" d="M 166.11529,156.36794 C 166.65768,156.36794 167.07264,155.91863 167.07264,155.34678 L 167.07264,146.37693 C 167.07264,145.80508 166.65768,145.35577 166.11529,145.35577 L 165.47651,145.35577 C 164.93412,145.35577 164.48812,145.80508 164.48812,146.37693 L 164.48812,155.34678 C 164.48812,155.91863 164.93412,156.36794 165.47651,156.36794 L 166.11529,156.36794 z M 201.59695,165.29695 L 177.09135,165.29695 L 177.09135,176.14574 C 177.09135,178.28609 175.49603,178.18806 175.49603,178.18806 L 168.09371,178.18806 C 168.09371,178.18806 166.49758,178.28609 166.49758,176.14574 L 166.49758,165.29695 L 165.76404,165.29695 L 160.78614,159.83988 L 160.78614,142.54554 L 165.76404,138.97557 L 173.00708,122.28576 C 189.12115,120.24344 201.69252,120.08006 201.69252,120.17809 C 201.69252,120.08006 214.26471,120.24344 230.37877,122.28576 L 237.62181,138.97557 L 242.59972,142.54554 L 242.59972,159.83988 L 237.62181,165.29695 L 236.91932,165.29695 L 236.91932,176.14574 C 236.91932,178.28609 235.29215,178.18806 235.29215,178.18806 L 227.88982,178.18806 C 227.88982,178.18806 226.29451,178.28609 226.29451,176.14574 L 226.29451,165.29695 L 201.59695,165.29695 z M 201.69252,138.87754 C 201.69252,138.77951 233.25001,139.03276 233.15444,139.06544 L 233.25001,138.87754 L 227.72972,126.42758 C 211.58461,124.38526 201.69252,124.23005 201.69252,124.32808 C 201.69252,124.23005 191.80124,124.38526 175.65532,126.42758 L 170.13584,139.03276 L 170.23141,138.87754 C 170.23141,138.87754 201.69252,138.77951 201.69252,138.87754 z M 190.93946,156.55584 L 212.47825,156.55584 L 212.47825,153.10841 L 190.93946,153.10841 L 190.93946,156.55584 z M 238.00492,156.36794 C 238.54731,156.36794 238.99331,155.91863 238.99331,155.34678 L 238.99331,146.37693 C 238.99331,145.80508 238.54731,145.35577 238.00492,145.35577 L 237.36614,145.35577 C 236.82375,145.35577 236.40879,145.80508 236.40879,146.37693 L 236.40879,155.34678 C 236.40879,155.91863 236.82375,156.36794 237.36614,156.36794 L 238.00492,156.36794"/>
|
||||
|
||||
</svg>
|
After Width: | Height: | Size: 4.2 KiB |
|
@ -0,0 +1,22 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg id="Nederlands_verkeersbord_F2" width="300" height="300" viewBox="0 0 300 300" xmlns="http://www.w3.org/2000/svg" version="1.1" xmlns:xlink="http://www.w3.org/1999/xlink">
|
||||
|
||||
<circle id="witte_cirkel_met_zwarte_rand" cx="150" cy="150" r="149.7675" fill="#f7fbf5" stroke="#2a2d2f" stroke-width="0.465"/>
|
||||
|
||||
<path id="grijze_auto_links" fill="#8f9695" d="M 40.047002,158.71734 C 39.313772,158.71734 38.743482,158.11441 38.743482,157.34857 L 38.743482,145.4457 C 38.743482,144.67987 39.313772,144.07701 40.047002,144.07701 L 40.878022,144.07701 C 41.603102,144.07701 42.181532,144.67987 42.181532,145.4457 L 42.181532,157.34857 C 42.181532,158.11441 41.603102,158.71734 40.878022,158.71734 L 40.047002,158.71734 z M 73.873722,154.39118 L 102.48631,154.39118 L 102.48631,158.96986 L 73.873722,158.96986 L 73.873722,154.39118 z M 88.294072,170.58763 L 120.88242,170.58763 L 120.88242,185.04053 C 120.88242,187.83494 123.01696,187.74532 123.01696,187.74532 L 132.85051,187.74532 C 132.85051,187.74532 134.9769,187.83494 134.9769,185.04053 L 134.9769,170.58763 L 135.93824,170.58763 L 142.55369,163.3611 L 142.55369,140.35378 L 135.93824,135.6122 L 126.32469,113.42766 C 104.90598,110.72286 88.163722,110.50293 88.163722,110.60067 C 88.163722,110.50293 71.486632,110.72286 50.043482,113.42766 L 40.462522,135.6122 L 33.806332,140.35378 L 33.806332,163.3611 L 40.462522,170.58763 L 41.383132,170.58763 L 41.383132,185.04053 C 41.383132,187.83494 43.517662,187.74532 43.517662,187.74532 L 53.351222,187.74532 C 53.351222,187.74532 55.485742,187.83494 55.485742,185.04053 L 55.485742,170.58763 L 88.294072,170.58763 z M 46.377282,135.45742 L 46.255082,135.67736 L 53.603762,118.96774 C 75.022462,116.23028 88.163722,116.04293 88.163722,116.14067 C 88.163722,116.04293 101.33757,116.23028 122.75626,118.96774 L 130.11308,135.45742 L 130.01532,135.70994 C 130.11308,135.67736 88.163722,135.3596 88.163722,135.45742 C 88.163722,135.3596 46.377282,135.45742 46.377282,135.45742 z M 135.61236,158.71734 C 134.88729,158.71734 134.30884,158.11441 134.30884,157.34857 L 134.30884,145.4457 C 134.30884,144.67987 134.88729,144.07701 135.61236,144.07701 L 136.44336,144.07701 C 137.17661,144.07701 137.74691,144.67987 137.74691,145.4457 L 137.74691,157.34857 C 137.74691,158.11441 137.17661,158.71734 136.44336,158.71734 L 135.61236,158.71734"/>
|
||||
|
||||
<use id="grijze_auto_rechts" x="0" y="0" xlink:href="#grijze_auto_links" transform="translate(128.6,0)" width="300" height="300"/>
|
||||
|
||||
<g id="zwarte_strepen_met_witte_randen">
|
||||
|
||||
<path id="zwarte_streep_met_witte_rand_rechts" d="M 242.29035,35.712735 L 231.72359,29.602381 L 87.275682,279.77478 L 97.875042,285.88505 L 242.29035,35.712735 z " style="fill:#2a2d2f;stroke:#f7fbf5;stroke-width:1.4"/>
|
||||
|
||||
<path id="zwarte_streep_met_witte_rand_midden" d="M 227.26713,27.027902 L 216.7085,20.91763 L 72.252452,271.08995 L 82.851832,277.20029 L 227.26713,27.027902 z " style="fill:#2a2d2f;stroke:#f7fbf5;stroke-width:1.4"/>
|
||||
|
||||
<path id="zwarte_streep_met_witte_rand_links" d="M 212.25204,18.375732 L 201.68526,12.265377 L 57.229212,262.4052 L 67.796012,268.51547 L 212.25204,18.375732 z " style="fill:#2a2d2f;stroke:#f7fbf5;stroke-width:1.4"/>
|
||||
|
||||
</g>
|
||||
|
||||
<circle id="witte_bies" cx="150" cy="150" r="143.69" stroke="#f7fbf5" fill="none" stroke-width="9.32"/>
|
||||
|
||||
</svg>
|
After Width: | Height: | Size: 3.3 KiB |
|
@ -0,0 +1,18 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg id="Nederlands_verkeersbord_F3" width="300" height="300" viewBox="0 0 300 300" xmlns="http://www.w3.org/2000/svg" version="1.1">
|
||||
|
||||
<circle id="witte_cirkel_met_rode_rand" cx="150" cy="150" r="130.5" fill="#f7fbf5" stroke="#c1121c" stroke-width="39"/>
|
||||
|
||||
<g id="rode_vrachtauto">
|
||||
|
||||
<path fill="#c1121c" d="M 111.34197,196.88751 L 131.06312,196.41369 C 131.12031,198.90532 130.99777,203.91308 131.79021,204.7055 C 132.49278,205.38355 133.86526,205.31819 136.00566,205.28552 C 137.91732,205.25284 139.55122,205.63679 140.53973,204.48493 C 141.14427,203.74969 140.95637,198.80729 140.95637,193.47275 C 140.95637,188.2771 141.1116,183.90654 140.40902,183.26117 C 139.55122,182.50143 138.17875,182.68932 135.97299,182.68932 C 133.83258,182.68932 132.40292,182.33804 131.56963,183.13863 C 130.74451,183.96373 131.18567,186.00604 131.06312,190.95662 L 111.27662,189.7394 C 111.27662,189.7394 108.94831,185.65477 104.25086,185.59758 C 99.56157,185.53223 97.26594,189.7394 97.26594,189.7394 L 77.44676,190.95662 C 77.29154,186.00604 77.89608,184.69896 76.99744,183.3592 C 76.58897,182.722 74.73449,182.722 72.59409,182.68932 C 70.39649,182.65665 68.80344,182.68932 68.22341,183.26117 C 67.33293,184.12711 67.33293,188.02385 67.33293,193.31754 C 67.33293,198.6439 67.10419,203.94576 68.15805,204.83621 C 68.95866,205.50609 70.7151,205.25284 72.62676,205.28552 C 74.76717,205.31819 76.00893,205.44073 76.74419,204.7055 C 77.76537,203.71702 77.31605,198.90532 77.38141,196.44637 L 97.20059,196.88751 C 97.20059,196.88751 99.62693,200.68622 104.25086,200.68622 C 108.43364,200.68622 111.34197,196.88751 111.34197,196.88751" id="path270"/>
|
||||
|
||||
<path fill="#c1121c" d="M 141.20963,167.46998 C 141.20963,111.20823 141.30766,98.831795 138.93851,96.462707 C 137.2801,94.804346 129.91122,95.033085 103.64632,95.033085 C 80.061,95.033085 71.16442,93.946573 68.64005,96.462707 C 66.46697,98.603055 67.01432,105.78384 67.01432,167.46998 L 141.20963,167.46998"/>
|
||||
|
||||
<path fill="#c1121c" d="M 66.3771,178.67004 L 141.94488,178.67004 L 141.94488,172.47774 L 66.3771,172.47774 L 66.3771,178.67004 z "/>
|
||||
|
||||
</g>
|
||||
|
||||
<path id="zwarte_personenauto" fill="#2a2d2f" d="M 159.49295,182.78735 C 160.06481,182.78735 160.51413,182.30537 160.51413,181.73352 L 160.51413,172.51042 C 160.51413,171.93857 160.06481,171.4239 159.49295,171.4239 L 158.85573,171.4239 C 158.28386,171.4239 157.83454,171.93857 157.83454,172.51042 L 157.83454,181.73352 C 157.83454,182.30537 158.28386,182.78735 158.85573,182.78735 L 159.49295,182.78735 z M 196.06775,191.97778 L 170.82403,191.97778 L 170.82403,203.17784 C 170.82403,205.35087 169.16562,205.28552 169.16562,205.28552 L 161.53532,205.28552 C 161.53532,205.28552 159.90959,205.35087 159.90959,203.17784 L 159.90959,191.97778 L 159.14166,191.97778 L 154.00305,186.39 L 154.00305,168.55649 L 159.14166,164.88032 L 166.57589,147.68401 C 183.20081,145.57634 196.15762,145.42113 196.15762,145.51099 C 196.15762,145.42113 209.08175,145.57634 225.71483,147.68401 L 233.14907,164.88032 L 238.28767,168.55649 L 238.28767,186.39 L 233.14907,191.97778 L 232.41381,191.97778 L 232.41381,203.17784 C 232.41381,205.35087 230.75541,205.28552 230.75541,205.28552 L 223.15778,205.28552 C 223.15778,205.28552 221.49937,205.35087 221.49937,203.17784 L 221.49937,191.97778 L 196.06775,191.97778 z M 196.15762,164.75778 C 196.15762,164.65975 228.64768,164.94567 228.54964,164.94567 L 228.64768,164.75778 L 222.96988,151.95654 C 206.3368,149.88971 196.15762,149.69365 196.15762,149.79168 C 196.15762,149.69365 185.94575,149.88971 169.35352,151.95654 L 163.67573,164.94567 L 163.74108,164.75778 C 163.74108,164.75778 196.15762,164.65975 196.15762,164.75778 z M 185.05528,182.97525 L 207.23544,182.97525 L 207.23544,179.43795 L 185.05528,179.43795 L 185.05528,182.97525 z M 233.55754,182.78735 C 234.1049,182.78735 234.55422,182.30537 234.55422,181.73352 L 234.55422,172.51042 C 234.55422,171.93857 234.1049,171.4239 233.55754,171.4239 L 232.88764,171.4239 C 232.34846,171.4239 231.89913,171.93857 231.89913,172.51042 L 231.89913,181.73352 C 231.89913,182.30537 232.34846,182.78735 232.88764,182.78735 L 233.55754,182.78735"/>
|
||||
|
||||
</svg>
|
After Width: | Height: | Size: 4.1 KiB |
|
@ -0,0 +1,31 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg id="Nederlands_verkeersbord_F4" width="300" height="300" viewBox="0 0 300 300" xmlns="http://www.w3.org/2000/svg" version="1.1">
|
||||
|
||||
|
||||
<circle id="witte_cirkel_met_zwarte_rand" cx="150" cy="150" r="149.7675" fill="#f7fbf5" stroke="#2a2d2f" stroke-width="0.465"/>
|
||||
|
||||
<path id="auto" fill="#8f9695" d="M 168.2196,177.26824 C 168.95278,177.26824 169.52303,176.63272 169.52303,175.89946 L 169.52303,164.00473 C 169.52303,163.2389 168.95278,162.63604 168.2196,162.63604 L 167.38867,162.63604 C 166.66363,162.63604 166.08524,163.2389 166.08524,164.00473 L 166.08524,175.89946 C 166.08524,176.63272 166.66363,177.26824 167.38867,177.26824 L 168.2196,177.26824 z M 215.37928,189.13851 L 182.82614,189.13851 L 182.82614,203.55881 C 182.82614,206.39401 180.69179,206.29626 180.69179,206.29626 L 170.85904,206.29626 C 170.85904,206.29626 168.73284,206.39401 168.73284,203.55881 L 168.73284,189.13851 L 167.77155,189.13851 L 161.15667,181.9202 L 161.15667,158.91282 L 167.77155,154.16312 L 177.38433,131.98673 C 198.83387,129.28193 215.5096,129.05379 215.5096,129.15153 C 215.5096,129.05379 232.21792,129.28193 253.6593,131.98673 L 263.23951,154.16312 L 269.89514,158.91282 L 269.89514,181.9202 L 263.23951,189.13851 L 262.31896,189.13851 L 262.31896,203.55881 C 262.31896,206.39401 260.15201,206.29626 260.15201,206.29626 L 250.31928,206.29626 C 250.31928,206.29626 248.21749,206.39401 248.21749,203.55881 L 248.21749,189.13851 L 215.37928,189.13851 z M 215.5096,154.00826 C 215.5096,153.87794 257.41481,154.22827 257.3252,154.26085 L 257.41481,154.00826 L 250.09933,137.49414 C 228.68237,134.78935 215.5096,134.5612 215.5096,134.69161 C 215.5096,134.5612 202.36128,134.78935 180.91988,137.49414 L 173.59624,154.22827 L 173.694,154.00826 C 173.694,154.00826 215.5096,153.87794 215.5096,154.00826 z M 201.22078,177.52887 L 229.83103,177.52887 L 229.83103,172.94207 L 201.22078,172.94207 L 201.22078,177.52887 z M 263.78532,177.26824 C 264.47775,177.26824 265.08875,176.63272 265.08875,175.89946 L 265.08875,164.00473 C 265.08875,163.2389 264.47775,162.63604 263.78532,162.63604 L 262.92178,162.63604 C 262.2212,162.63604 261.65094,163.2389 261.65094,164.00473 L 261.65094,175.89946 C 261.65094,176.63272 262.2212,177.26824 262.92178,177.26824 L 263.78532,177.26824"/>
|
||||
|
||||
<g id="vrachtauto">
|
||||
|
||||
<path fill="#8f9695" d="M 104.86485,194.26301 L 130.32244,193.66016 C 130.41205,196.84561 130.25726,203.3063 131.27557,204.32464 C 132.19611,205.21267 133.9476,205.14751 136.71738,205.08235 C 139.16945,205.0579 141.26309,205.56302 142.54208,204.03955 C 143.33228,203.11073 143.11232,196.74787 143.11232,189.87177 C 143.11232,183.15857 143.33228,177.52887 142.37916,176.6653 C 141.29567,175.67953 139.51976,175.93213 136.65221,175.93213 C 133.88242,175.93213 132.07392,175.52475 131.02303,176.5431 C 129.93955,177.58591 130.50981,180.20117 130.32244,186.59662 L 104.79969,185.04049 C 104.79969,185.04049 101.80994,179.78568 95.765302,179.68785 C 89.679922,179.59824 86.755352,185.06495 86.755352,185.06495 L 61.167442,186.6292 C 60.947472,180.23375 61.745832,178.51473 60.564602,176.7957 C 60.026932,175.99729 57.672622,175.99729 54.902822,175.93213 C 52.067872,175.89946 49.998682,175.96471 49.265502,176.6653 C 48.092422,177.81405 48.125012,182.80823 48.125012,189.65175 C 48.125012,196.52793 47.807292,203.37146 49.208482,204.512 C 50.226782,205.37565 52.483342,205.0579 54.968012,205.08235 C 57.705202,205.14751 59.326342,205.27784 60.279482,204.35723 C 61.582912,203.04557 61.012652,196.87819 61.110412,193.66016 L 86.657592,194.26301 C 86.657592,194.26301 89.777692,199.16757 95.765302,199.16757 C 101.14193,199.16757 104.86485,194.26301 104.86485,194.26301"/>
|
||||
|
||||
<path fill="#8f9695" d="M 143.39745,156.29764 C 143.39745,83.707122 143.56037,67.7307 140.50547,64.675567 C 138.3385,62.541044 128.8235,62.834344 94.999532,62.834344 C 64.540062,62.834344 53.053602,61.432996 49.811322,64.675567 C 47.008952,67.478184 47.709532,76.741405 47.709532,156.29764 L 143.39745,156.29764"/>
|
||||
|
||||
<path fill="#8f9695" d="M 46.854162,170.75051 L 144.35059,170.75051 L 144.35059,162.75824 L 46.854162,162.75824 L 46.854162,170.75051 z"/>
|
||||
|
||||
</g>
|
||||
|
||||
<g id="zwarte_strepen_met_witte_randen">
|
||||
|
||||
<path id="zwarte_streep_met_witte_rand_rechts" d="M 242.29035,35.712735 L 231.72359,29.602381 L 87.275682,279.77478 L 97.875042,285.88505 L 242.29035,35.712735 z " style="fill:#2a2d2f;stroke:#f7fbf5;stroke-width:1.4"/>
|
||||
|
||||
<path id="zwarte_streep_met_witte_rand_midden" d="M 227.26713,27.027902 L 216.7085,20.91763 L 72.252452,271.08995 L 82.851832,277.20029 L 227.26713,27.027902 z " style="fill:#2a2d2f;stroke:#f7fbf5;stroke-width:1.4"/>
|
||||
|
||||
<path id="zwarte_streep_met_witte_rand_links" d="M 212.25204,18.375732 L 201.68526,12.265377 L 57.229212,262.4052 L 67.796012,268.51547 L 212.25204,18.375732 z " style="fill:#2a2d2f;stroke:#f7fbf5;stroke-width:1.4"/>
|
||||
|
||||
</g>
|
||||
|
||||
<circle id="witte_bies" cx="150" cy="150" r="143.69" stroke="#f7fbf5" fill="none" stroke-width="9.32"/>
|
||||
|
||||
</svg>
|
After Width: | Height: | Size: 4.9 KiB |
|
@ -0,0 +1,10 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg id="Nederlands_verkeersbord_F5" width="300" height="300" viewBox="0 0 300 300" xmlns="http://www.w3.org/2000/svg" version="1.1">
|
||||
|
||||
<circle id="witte_cirkel_met_rode_rand" cx="150" cy="150" r="130.5" fill="#f7fbf5" stroke="#c1121c" stroke-width="39"/>
|
||||
|
||||
<path id="rode_pijl" fill="#c1121c" d="M 200.70575,224.54735 L 200.70575,129.64898 L 222.23876,134.6667 C 227.43935,136.69653 231.56183,134.02528 228.61245,128.98319 L 195.75845,81.793824 C 192.80988,77.571788 190.27291,77.571788 187.32353,81.793824 L 154.46954,128.98319 C 151.55182,134.02528 155.64263,136.69653 160.84403,134.6667 L 182.37623,129.64898 L 182.37623,224.54735 L 200.70575,224.54735"/>
|
||||
|
||||
<path id="zwarte_pijl" fill="#2a2d2f" d="M 97.03898,73.9587 L 97.03898,168.84895 L 75.50597,163.83935 C 70.30538,161.77704 66.18291,164.47265 69.13229,169.51474 L 101.98628,216.67975 C 104.93485,220.90178 107.44016,220.90178 110.42121,216.67975 L 143.24354,169.51474 C 146.19292,164.47265 142.1021,161.77704 136.9007,163.83935 L 115.3685,168.84895 L 115.3685,73.9587 L 97.03898,73.9587"/>
|
||||
|
||||
</svg>
|
After Width: | Height: | Size: 1.1 KiB |
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg id="Nederlands_verkeersbord_F6" width="300" height="300" viewBox="0 0 300 300" xmlns="http://www.w3.org/2000/svg" version="1.1">
|
||||
|
||||
<rect id="blauw_vlak" width="300" height="300" fill="#0e518d"/>
|
||||
|
||||
<path id="witte_bies" style="fill:none;stroke:#f7fbf5;stroke-width:6.7612772" d="M 276.33022,292.06475 C 285.02492,292.06475 292.09652,285.02651 292.09652,276.30011 L 292.09652,23.66726 C 292.09652,14.97345 285.02492,7.894449 276.33022,7.894449 L 23.66982,7.894449 C 14.94249,7.894449 7.86274,14.97345 7.86274,23.66726 L 7.86274,276.30011 C 7.86274,285.02651 14.94249,292.06475 23.66982,292.06475 L 276.33022,292.06475 z"/>
|
||||
|
||||
<path id="witte_pijl" fill="#f7fbf5" d="M 224.02378,255.25571 L 224.02378,117.77283 L 255.18858,125.05384 C 262.77193,128.00154 268.70929,124.09649 264.44311,116.81548 L 216.84352,48.456197 C 212.54376,42.350905 208.89905,42.350905 204.6077,48.456197 L 157.04171,116.81548 C 152.77554,124.09649 158.7129,128.00154 166.25425,125.05384 L 197.45264,117.77283 L 197.45264,255.25571 L 224.02378,255.25571"/>
|
||||
|
||||
<path id="rode_pijl" fill="#c1121c" d="M 76.47175,45.172591 L 76.47175,182.65539 L 45.27337,175.40796 C 37.73201,172.41834 31.79464,176.32338 36.05238,183.63799 L 83.6184,251.9721 C 87.91817,258.07739 91.56286,258.07739 95.86262,251.9721 L 143.45382,183.63799 C 147.71997,176.32338 141.78262,172.41834 134.24124,175.40796 L 103.04286,182.65539 L 103.04286,45.172591 L 76.47175,45.172591"/>
|
||||
|
||||
</svg>
|
After Width: | Height: | Size: 1.4 KiB |
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<svg id="Nederlands_verkeersbord_F7" width="300" height="300" viewBox="0 0 300 300" xmlns="http://www.w3.org/2000/svg" version="1.1">
|
||||
|
||||
<circle id="witte_cirkel_met_rode_rand" cx="150" cy="150" r="130.5" fill="#f7fbf5" stroke="#c1121c" stroke-width="39"/>
|
||||
|
||||
<path id="keerpijl" fill="#2a2d2f" d="M 121.46191,110.52203 L 121.46191,137.9287 L 147.88366,131.79944 C 154.30595,129.25168 159.3282,132.55644 155.70599,138.75895 L 115.35707,196.68982 C 111.73486,201.87486 108.64988,201.87486 104.99512,196.68982 L 64.67875,138.75895 C 61.0484,132.55644 66.07065,129.25168 72.49295,131.79944 L 98.92283,137.9287 L 98.92283,110.52203 C 98.92283,44.101367 206.64478,44.581615 206.64478,110.52203 C 206.64478,159.74333 206.64478,217.32418 206.64478,217.32418 L 183.43011,217.32418 L 183.43011,110.52203 C 183.43011,74.788366 121.46191,74.788366 121.46191,110.52203"/>
|
||||
|
||||
</svg>
|
After Width: | Height: | Size: 918 B |
|
@ -0,0 +1,11 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
||||
<svg version="1.1" id="sign" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="300px" height="300px" viewBox="0 0 300 300" enable-background="new 0 0 300 300" xml:space="preserve">
|
||||
<circle id="circle" fill="#F7FBF5" stroke="#808080" stroke-width="0.5" cx="150" cy="150" r="149.8"/>
|
||||
<g id="stripes">
|
||||
<line fill="none" stroke="#2a2d2f" stroke-width="10" x1="63" y1="265" x2="206" y2="17"/>
|
||||
<line fill="none" stroke="#2a2d2f" stroke-width="10" x1="77" y1="276" x2="221" y2="24"/>
|
||||
<line fill="none" stroke="#2a2d2f" stroke-width="10" x1="94" y1="282" x2="236" y2="33"/>
|
||||
</g>
|
||||
<circle id="white" fill="none" stroke="#F7FBF5" stroke-width="9" cx="150" cy="150" r="144"/>
|
||||
</svg>
|
After Width: | Height: | Size: 862 B |
82
assets/layers/traffic_sign/images/nl/F/license_info.json
Normal file
|
@ -0,0 +1,82 @@
|
|||
[
|
||||
{
|
||||
"path": "Nederlands_verkeersbord_F1.svg",
|
||||
"license": "CC0",
|
||||
"authors": [
|
||||
"Ministerie van Infrastructuur en Waterstaat"
|
||||
],
|
||||
"sources": [
|
||||
"https://commons.wikimedia.org/wiki/File:Nederlands_verkeersbord_F1.svg"
|
||||
]
|
||||
},
|
||||
{
|
||||
"path": "Nederlands_verkeersbord_F2.svg",
|
||||
"license": "CC0",
|
||||
"authors": [
|
||||
"Ministerie van Infrastructuur en Waterstaat"
|
||||
],
|
||||
"sources": [
|
||||
"https://commons.wikimedia.org/wiki/File:Nederlands_verkeersbord_F2.svg"
|
||||
]
|
||||
},
|
||||
{
|
||||
"path": "Nederlands_verkeersbord_F3.svg",
|
||||
"license": "CC0",
|
||||
"authors": [
|
||||
"Ministerie van Infrastructuur en Waterstaat"
|
||||
],
|
||||
"sources": [
|
||||
"https://commons.wikimedia.org/wiki/File:Nederlands_verkeersbord_F3.svg"
|
||||
]
|
||||
},
|
||||
{
|
||||
"path": "Nederlands_verkeersbord_F4.svg",
|
||||
"license": "CC0",
|
||||
"authors": [
|
||||
"Ministerie van Infrastructuur en Waterstaat"
|
||||
],
|
||||
"sources": [
|
||||
"https://commons.wikimedia.org/wiki/File:Nederlands_verkeersbord_F4.svg"
|
||||
]
|
||||
},
|
||||
{
|
||||
"path": "Nederlands_verkeersbord_F5.svg",
|
||||
"license": "CC0",
|
||||
"authors": [
|
||||
"Ministerie van Infrastructuur en Waterstaat"
|
||||
],
|
||||
"sources": [
|
||||
"https://commons.wikimedia.org/wiki/File:Nederlands_verkeersbord_F5.svg"
|
||||
]
|
||||
},
|
||||
{
|
||||
"path": "Nederlands_verkeersbord_F6.svg",
|
||||
"license": "CC0",
|
||||
"authors": [
|
||||
"Ministerie van Infrastructuur en Waterstaat"
|
||||
],
|
||||
"sources": [
|
||||
"https://commons.wikimedia.org/wiki/File:Nederlands_verkeersbord_F6.svg"
|
||||
]
|
||||
},
|
||||
{
|
||||
"path": "Nederlands_verkeersbord_F7.svg",
|
||||
"license": "CC0",
|
||||
"authors": [
|
||||
"Ministerie van Infrastructuur en Waterstaat"
|
||||
],
|
||||
"sources": [
|
||||
"https://commons.wikimedia.org/wiki/File:Nederlands_verkeersbord_F7.svg"
|
||||
]
|
||||
},
|
||||
{
|
||||
"path": "Nederlands_verkeersbord_F8.svg",
|
||||
"license": "CC0",
|
||||
"authors": [
|
||||
"Ministerie van Infrastructuur en Waterstaat"
|
||||
],
|
||||
"sources": [
|
||||
"https://commons.wikimedia.org/wiki/File:Nederlands_verkeersbord_F8.svg"
|
||||
]
|
||||
}
|
||||
]
|
1052
assets/layers/traffic_sign/signs/nl.protojson
Normal file
|
@ -38,8 +38,9 @@
|
|||
"optimize-images": "cd assets/generated/ && find -name '*.png' -exec optipng '{}' \\; && echo 'PNGs are optimized'",
|
||||
"generate:graphs": "ts-node Docs/Tools/GenerateSeries.ts",
|
||||
"reset:layeroverview": "echo {\\\"layers\\\":[], \\\"themes\\\":[]} > ./assets/generated/known_layers_and_themes.json && echo {\\\"layers\\\": []} > ./assets/generated/known_layers.json && rm -f ./assets/generated/layers/*.json && rm -f ./assets/generated/themes/*.json && npm run generate:layeroverview && ts-node scripts/generateLayerOverview.ts --force",
|
||||
"generate": "mkdir -p ./assets/generated; npm run generate:licenses; npm run generate:images; npm run generate:charging-stations; npm run generate:translations; npm run reset:layeroverview; npm run generate:service-worker",
|
||||
"generate": "mkdir -p ./assets/generated; npm run generate:licenses; npm run generate:images; npm run generate:charging-stations; npm run generate:traffic-signs; npm run generate:translations; npm run reset:layeroverview; npm run generate:service-worker",
|
||||
"generate:charging-stations": "cd ./assets/layers/charging_station && ts-node csvToJson.ts && cd -",
|
||||
"generate:traffic-signs": "cd ./assets/layers/traffic_sign && ts-node generateSigns.ts && cd -",
|
||||
"prepare-deploy": "npm run generate:service-worker && ./scripts/build.sh",
|
||||
"gittag": "ts-node scripts/printVersion.ts | bash",
|
||||
"format": "npx prettier --write '**/*.ts'",
|
||||
|
|