Add first version of the food theme

This commit is contained in:
pietervdvn 2021-09-02 21:22:34 +02:00
parent 23af637a81
commit 92e8f3f89d
20 changed files with 629 additions and 30 deletions

View file

@ -2,7 +2,7 @@ import { Utils } from "../Utils";
export default class Constants {
public static vNumber = "0.9.3";
public static vNumber = "0.9.4";
// The user journey states thresholds when a new feature gets unlocked
public static userJourney = {

View file

@ -23,7 +23,10 @@ export default class Attribution extends Combine {
const reportBug = new Link(Svg.bug_ui().SetClass("small-image"), "https://github.com/pietervdvn/MapComplete/issues", true);
const layoutId = layoutToUse?.data?.id;
const osmChaLink = `https://osmcha.org/?filters=%7B%22comment%22%3A%5B%7B%22label%22%3A%22%23${layoutId}%22%2C%22value%22%3A%22%23${layoutId}%22%7D%5D%2C%22date__gte%22%3A%5B%7B%22label%22%3A%222020-07-05%22%2C%22value%22%3A%222020-07-05%22%7D%5D%2C%22editor%22%3A%5B%7B%22label%22%3A%22MapComplete%22%2C%22value%22%3A%22MapComplete%22%7D%5D%7D`
const now = new Date()
// Note: getMonth is zero-index, we want 1-index but with one substracted, so it checks out!
const startDate = now.getFullYear()+"-"+now.getMonth()+"-"+now.getDate()
const osmChaLink = `https://osmcha.org/?filters=%7B%22comment%22%3A%5B%7B%22label%22%3A%22%23${layoutId}%22%2C%22value%22%3A%22%23${layoutId}%22%7D%5D%2C%22date__gte%22%3A%5B%7B%22label%22%3A%22${startDate}%22%2C%22value%22%3A%222020-07-05%22%7D%5D%2C%22editor%22%3A%5B%7B%22label%22%3A%22MapComplete%22%2C%22value%22%3A%22MapComplete%22%7D%5D%7D`
const stats = new Link(Svg.statistics_ui().SetClass("small-image"), osmChaLink, true)

View file

@ -256,6 +256,9 @@ export class OH {
start?: string,
end?: string
} {
if(str === undefined){
return null
}
str = str.trim();
if (!str.startsWith("PH")) {
return null;

View file

@ -111,9 +111,10 @@ export class Translation extends BaseUIElement {
rtext = date.toLocaleString();
} else if (el.ConstructElement === undefined) {
console.error("ConstructElement is not defined", el);
throw "ConstructElement is not defined, you are working with a "+(typeof el)+":"+(el.constructor.name)
throw "ConstructElement is not defined, you are working with a " + (typeof el) + ":" + (el.constructor.name)
}else if(el["translations"] !== undefined){
rtext = el["translations"][lang]
} else {
Translation.forcedLanguage = lang; // This is a very dirty hack - it'll bite me one day
rtext = el.ConstructElement().innerHTML;
}
@ -126,7 +127,6 @@ export class Translation extends BaseUIElement {
}
newTranslations[lang] = template;
}
Translation.forcedLanguage = undefined;
return new Translation(newTranslations);
}

Binary file not shown.

View file

@ -0,0 +1,31 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
version="1.0"
width="340pt"
height="362pt"
viewBox="0 0 340 362">
<title>Vegetarian mark</title>
<metadata>
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title>Vegetarian mark</dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
transform="matrix(0.1,0,0,-0.1,0,362)"
style="fill:#000000;stroke:none">
<path
d="m 3190,3550 c -80,-21 -249,-59 -375,-84 -321,-63 -372,-82 -515,-188 -203,-151 -345,-443 -344,-708 1,-101 16,-173 33,-154 4,5 18,34 30,64 61,147 238,371 389,492 77,62 232,123 232,91 0,-11 -53,-77 -116,-143 -59,-63 -79,-89 -190,-250 -115,-169 -265,-471 -366,-740 -98,-261 -170,-469 -218,-625 -81,-267 -154,-478 -167,-482 -16,-6 -60,137 -152,492 -143,556 -204,747 -350,1095 -100,237 -232,427 -500,718 -147,161 -356,315 -482,357 -82,28 -89,14 -27,-55 292,-329 461,-573 640,-920 151,-295 255,-588 444,-1260 48,-172 154,-610 188,-780 38,-189 80,-374 91,-403 4,-9 19,-21 34,-25 34,-9 198,-9 233,0 52,15 62,56 134,528 48,319 89,510 171,795 139,486 287,842 377,900 13,8 77,24 144,35 260,43 469,158 617,341 99,122 125,212 150,512 13,159 21,204 51,299 19,62 32,118 30,125 -7,18 -23,16 -186,-27 z"
style="fill:#017f00" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 1.6 KiB

View file

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
version="1.1"
width="16"
height="16"
viewBox="0 0 16 16"
id="svg2">
<metadata id="metadata8">
<rdf:RDF>
<cc:Work rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
<dc:title/>
</cc:Work>
</rdf:RDF>
</metadata>
<defs id="defs6"/>
<rect width="16" height="16" x="0" y="0" id="canvas" style="fill:none;stroke:none;visibility:hidden"/>
<path d="M 5,3 C 2,3 0.960032,5.000799 1,6 L 1,7 13,7 13,6 C 13,5 12,3 9,3 z M 1,8 C 0,8 0,9 1,9 l 12,0 c 1,0 1,-1 0,-1 z m 0,2.03125 0,0.625 C 1,11.34045 1.81579,12 2.5,12 l 9,0 c 0.68421,0 1.5,-0.65955 1.5,-1.34375 l 0,-0.625 z" id="fast-food" style="fill:#C77400;fill-opacity:1;stroke:none" transform="translate(1,1)"/>
</svg>

After

Width:  |  Height:  |  Size: 1.1 KiB

View file

@ -0,0 +1,381 @@
{
"id": "food",
"name": {
"nl": "Eetgelegenheden",
"en": "Restaurants and fast food"
},
"source": {
"osmTags": {
"or": [
"amenity=fast_food",
"amenity=restaurant"
]
}
},
"wayHandling": 1,
"icon": {
"render": "circle:white;./assets/layers/food/restaurant.svg",
"mappings": [
{
"if": {
"and": [
"amenity=fast_food",
"cuisine=friture"
]
},
"then": "circle:white;./assets/layers/food/fries.svg"
},
{
"if": "amenity=fast_food",
"then": "circle:white;./assets/layers/food/fastfood.svg"
}
]
},
"iconOverlays": [
{
"if": "opening_hours~*",
"then": "isOpen",
"badge": true
},
{
"if": {
"or": [
"diet:vegetarian=yes",
"diet:vegan=yes"
]
},
"then": {
"render": "circle:white;./assets/themes/fritures/Vegetarian-mark.svg"
},
"badge": true
}
],
"label": {
"mappings": [
{
"if": "name~*",
"then": "<div style='background: white; padding: 0.25em; border-radius:0.5em'>{name}</div>"
}
]
},
"presets": [
{
"title": {
"en": "restaurant",
"nl": "restaurant"
},
"tags": [
"amenity=restaurant"
],
"description": {
"nl": "Een eetgegelegenheid waar je aan tafel wordt bediend",
"en": "A formal eating place with sit-down facilities selling full meals served by waiters"
},
"preciseInput": {
"preferredBackground": "map"
}
},
{
"title": {
"en": "fastfood",
"nl": "fastfood-zaak"
},
"tags": [
"amenity=fast_food"
],
"description": {
"nl": "Een zaak waar je snel bediend wordt, vaak met de focus op afhalen. Zitgelegenheid is eerder beperkt tot afwezig"
},
"preciseInput": {
"preferredBackground": "map"
}
},
{
"title": {
"en": "Friture",
"nl": "Friture"
},
"tags": [
"amenity=fast_food",
"cuisine=friture"
],
"description": {
"nl": "Een fastfood-zaak waar je frieten koopt"
},
"preciseInput": {
"preferredBackground": "map"
}
}
],
"title": {
"render": {
"nl": "Eetgelegenheid"
},
"mappings": [
{
"if": {
"and": [
"name~*",
"amenity=restaurant"
]
},
"then": {
"nl": "Restaurant <i>{name}</i>",
"en": "Restaurant <i>{name}</i>"
}
},
{
"if": {
"and": [
"name~*",
"amenity=fast_food"
]
},
"then": {
"nl": "Fastfood-zaak <i>{name}</i>",
"en": "Fastfood <i>{name}</i>"
}
}
]
},
"tagRenderings": [
"images",
{
"question": {
"nl": "Wat is de naam van deze eetgelegenheid?"
},
"render": {
"nl": "De naam van deze eetgelegeheid is {name}"
},
"freeform": {
"key": "name"
}
},
"opening_hours",
"website",
"email",
"phone",
{
"question": {
"nl": "Heeft deze eetgelegenheid een vegetarische optie?",
"en": "Does this restaurant have a vegetarian option?"
},
"mappings": [
{
"if": "diet:vegetarian=no",
"then": {
"nl": "Geen vegetarische opties beschikbaar"
}
},
{
"if": "diet:vegetarian=limited",
"then": {
"nl": "Beperkte vegetarische opties zijn beschikbaar"
}
},
{
"if": "diet:vegetarian=yes",
"then": {
"nl": "Vegetarische opties zijn beschikbaar"
}
},
{
"if": "diet:vegetarian=only",
"then": {
"nl": "Enkel vegetarische opties zijn beschikbaar"
}
}
],
"condition": "cuisine!=friture"
},
{
"question": {
"nl": "Heeft deze eetgelegenheid een veganistische optie?"
},
"mappings": [
{
"if": "diet:vegan=no",
"then": {
"nl": "Geen veganistische opties beschikbaar"
}
},
{
"if": "diet:vegan=limited",
"then": {
"nl": "Beperkte veganistische opties zijn beschikbaar"
}
},
{
"if": "diet:vegan=yes",
"then": {
"nl": "Veganistische opties zijn beschikbaar"
}
},
{
"if": "diet:vegan=only",
"then": {
"nl": "Enkel veganistische opties zijn beschikbaar"
}
}
],
"condition": "cuisine!=friture"
},
{
"question": {
"nl": "Heeft deze frituur vegetarische snacks?",
"fr": "Cette friterie est-elle équipée de snacks végétariens ?"
},
"mappings": [
{
"if": {
"and": [
"diet:vegetarian=yes"
]
},
"then": {
"nl": "Er zijn vegetarische snacks aanwezig",
"fr": "Des collations végétariennes sont disponibles"
}
},
{
"if": {
"and": [
"diet:vegetarian=limited"
]
},
"then": {
"nl": "Slechts enkele vegetarische snacks",
"fr": "Quelques snacks végétariens seulement"
}
},
{
"if": {
"and": [
"diet:vegetarian=no"
]
},
"then": {
"nl": "Geen vegetarische snacks beschikbaar",
"fr": "Pas d'en-cas végétariens disponibles"
}
}
],
"condition": "cuisine=friture"
},
{
"question": {
"nl": "Heeft deze frituur veganistische snacks?",
"fr": "Cette friterie est-elle équipée de snacks végétaliens ?"
},
"mappings": [
{
"if": {
"and": [
"diet:vegan=yes"
]
},
"then": {
"nl": "Er zijn veganistische snacks aanwezig",
"fr": "Des collations végétaliens sont disponibles"
}
},
{
"if": {
"and": [
"diet:vegan=limited"
]
},
"then": {
"nl": "Slechts enkele veganistische snacks",
"fr": "Quelques snacks végétaliens seulement"
}
},
{
"if": {
"and": [
"diet:vegetarian=no"
]
},
"then": {
"nl": "Geen veganistische snacks beschikbaar",
"fr": "Pas d'en-cas végétaliens disponibles"
}
}
],
"condition": "cuisine=friture"
},
{
"question": {
"nl": "Bakt deze frituur met dierlijk vet of met plantaardige olie?",
"fr": "Cette friteuse fonctionne-t-elle avec de la graisse animale ou végétale ?"
},
"mappings": [
{
"if": {
"and": [
"friture:oil=vegetable"
]
},
"then": {
"nl": "Plantaardige olie",
"fr": "Huile végétale"
}
},
{
"if": {
"and": [
"friture:oil=animal"
]
},
"then": {
"nl": "Dierlijk vet",
"fr": "Graisse animale"
}
}
],
"condition": "cuisine=friture"
},
{
"question": {
"nl": "Als je je eigen container (bv. kookpot of kleine potjes voor saus) meeneemt, gebruikt de frituur deze dan om je bestelling in te doen?",
"en": "If you bring your own container (such as a cooking pot and small pots), is it used to package your order?<br/>",
"ja": "お客様が持参容器(調理用の鍋や小さな鍋など)をもってきた場合は、注文の梱包に使用されますか?<br/>",
"fr": "Est-il proposé dutiliser ses propres contenants pour sa commande ?<br/>"
},
"mappings": [
{
"if": "bulk_purchase=yes",
"then": {
"nl": "Je mag je <b>eigen containers</b> meenemen om je bestelling in mee te nemen en zo minder afval te maken",
"en": "You can bring <b>your own containers</b> to get your order, saving on single-use packaging material and thus waste",
"ja": "<b>自分の容器</b>を持ってきて、注文を受け取ることができ、使い捨ての梱包材を節約して、無駄を省くことができます",
"fr": "Vous pouvez <b>apporter vos contenants</b> pour votre commande, limitant lusage de matériaux à usage unique et les déchets"
}
},
{
"if": "bulk_purchase=no",
"then": {
"nl": "Je mag <b>geen</b> eigen containers meenemen om je bestelling in mee te nemen",
"en": "Bringing your own container is <b>not allowed</b>",
"ja": "独自の容器を持参することは<b>できません</b>",
"ru": "Приносить свою тару <b>не разрешено</b>",
"fr": "Apporter ses propres contenants <b>nest pas permis</b>"
}
},
{
"if": "bulk_purchase=only",
"then": {
"nl": "Je <b>moet</b> je eigen containers meenemen om je bestelling in mee te nemen.",
"en": "You <b>must</b> bring your own container to order here.",
"ja": "自身の容器が注文に<b>必要</b>。",
"fr": "Il est <b>obligatoire</b> dapporter ses propres contenants"
}
}
],
"condition": "cuisine=friture"
}
]
}

View file

@ -0,0 +1 @@
<svg viewBox="-158 0 511 511.99966" xmlns="http://www.w3.org/2000/svg"><path d="m131.976562 9.859375v208.125h-44.277343v-192.0625c0-3.320313 1.679687-6.417969 4.460937-8.234375l24.589844-16.070312c6.550781-4.273438 15.226562.421874 15.226562 8.242187zm0 0" fill="#ffbd48"/><path d="m130.183594 46.851562c-11.25 0-20.746094 8.417969-22.078125 19.566407l-3.921875 32.734375v-15.71875c0-7.519532-3.761719-14.472656-10.066406-18.582032l-6.417969-4.191406v157.328125h44.277343v-171.0625c-.597656-.050781-1.195312-.074219-1.792968-.074219zm0 0" fill="#ff9c26"/><path d="m62.953125 25.921875v142.863281h-44.277344v-158.925781c0-7.820313 8.675781-12.515625 15.226563-8.242187l24.589844 16.070312c2.78125 1.816406 4.460937 4.914062 4.460937 8.234375zm0 0" fill="#ffdf4a"/><path d="m57.402344 45.152344c1.882812 0 3.75.246094 5.550781.722656v122.910156h-27.773437v-101.410156c0-12.25 9.972656-22.222656 22.222656-22.222656zm0 0" fill="#ffbd48"/><path d="m162.417969 89.109375-.886719 7.429687-16.109375 134.429688-40.085937-4.8125-3.882813-.464844 18.925781-157.800781c.925782-7.757813 10.09375-11.386719 16.089844-6.367187l22.507812 18.882812c2.546876 2.132812 3.84375 5.40625 3.441407 8.703125zm0 0" fill="#ffdf4a"/><path d="m161.53125 96.539062-16.109375 134.429688-40.085937-4.8125 31.140624-111.175781c2.03125-7.242188 7.53125-12.917969 14.703126-15.175781zm0 0" fill="#ffbd48"/><path d="m91.816406 226.304688h-44.277344v-158.929688c0-7.816406 8.675782-12.511719 15.222657-8.238281l24.597656 16.066406c2.78125 1.816406 4.457031 4.914063 4.457031 8.238281zm0 0" fill="#ffdf4a"/><path d="m109.835938 255.886719 42.636718 11.945312 42.878906-153.035156c2.109376-7.527344-4.976562-14.390625-12.433593-12.039063l-28.019531 8.832032c-3.167969 1-5.621094 3.53125-6.515626 6.726562zm0 0" fill="#ffdf4a"/><path d="m194.777344 208.085938-32.523438 68.703124-59.0625 124.753907-49.621094 104.8125c-4.492187 9.488281-18.730468 6.292969-18.730468-4.203125l-11.15625-123.386719-13.144532-145.441406-9.992187-110.484375c-.898437-9.921875 11.761719-14.652344 17.707031-6.667969 46.894532 62.964844 133.945313 75.429687 168.34375 77.882813 6.902344.496093 11.136719 7.777343 8.179688 14.03125zm0 0" fill="#ff5656"/><path d="m194.777344 208.085938-32.523438 68.703124-59.058594 124.753907-49.625 104.8125c-4.492187 9.488281-18.726562 6.292969-18.726562-4.203125l-.3125-3.390625 145.988281-305.199219c2.175781.195312 4.203125.359375 6.078125.492188 6.902344.496093 11.136719 7.777343 8.179688 14.03125zm0 0" fill="#f72d2d"/><path d="m162.304688 276.789062-59.058594 124.753907-19.480469-5.582031-60.027344-17.195313-1.804687-19.964844-8.210938-90.859375-3.128906-34.613281 132.777344 38.03125zm0 0" fill="#fe9e80"/><path d="m162.304688 276.789062-59.058594 124.753907-19.480469-5.582031 59.605469-124.601563zm0 0" fill="#fe835f"/><path d="m56.722656 314.019531c0 21.59375-14.816406 39.726563-34.839844 44.78125l-8.210937-90.859375c24.042969 1.605469 43.050781 21.621094 43.050781 46.078125zm0 0" fill="#ffdf4a"/></svg>

After

Width:  |  Height:  |  Size: 2.9 KiB

View file

@ -0,0 +1,42 @@
[
{
"authors": [
"OSM Carto"
],
"path": "fastfood.svg",
"license": "CC0",
"sources": [
"https://wiki.openstreetmap.org/w/images/1/1f/Fast-food-16.svg"
]
},
{
"authors": [
"OSM Carto"
],
"path": "restaurant.svg",
"license": "CC0",
"sources": [
"https://wiki.openstreetmap.org/w/images/b/bb/Restaurant-14.svg"
]
},
{
"authors": [
"European Vegetarian Union"
],
"path": "Vegetarian-mark.svg",
"license": "PD",
"sources": [
"https://commons.wikimedia.org/wiki/File:Vegetarian-mark.svg"
]
},
{
"authors": [
"Freepik"
],
"path": "fries.svg",
"license": "CC-BY",
"sources": [
"https://www.flaticon.com/free-icon/french-fries_1144288"
]
}
]

View file

@ -0,0 +1,31 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 14 14"
height="14"
width="14"
id="svg109"
version="1.1">
<metadata
id="metadata115">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<defs
id="defs113" />
<path
id="restaurant"
d="M 1.5 0 C 1.25 0 1 0.25 1 0.75 L 1 7 C 1 8 2.75 8 2.75 9 L 2.25 14 L 4.75 14 L 4.25 9 C 4.25 8 6 8 6 7 L 6 0.75 C 6 -0.25 5 -0.25 5 0.75 L 5 6 C 5 6.5632885 4 6.5632884 4 6 L 4 0.75 C 4 -0.25 3 -0.25 3 0.75 L 3 6 C 3 6.5273339 2 6.5273339 2 6 L 2 0.75 C 2 0.25 1.75 0 1.5 0 z M 10 0 C 9 0 7 2 7 5 C 7 8 9.25 9 9.25 9 L 8.75 14 L 11.25 14 L 10.75 9 C 10.75 9 13 8 13 5 C 13 2 11 0 10 0 z "
style="fill:#C77400" />
</svg>

After

Width:  |  Height:  |  Size: 1.2 KiB

View file

@ -0,0 +1,26 @@
{
"id": "food",
"title": {
"nl": "Eetgelegenheden",
"en": "Restaurants and fast food"
},
"description": {
"nl": "Restaurants en fast food"
},
"language": [
"nl",
"fr",
"en"
],
"maintainer": "",
"icon": "./assets/layers/food/restaurant.svg",
"version": "0",
"startLat": 0,
"startLon": 0,
"startZoom": 1,
"widenFactor": 0.05,
"socialImage": "",
"layers": [
"food"
]
}

View file

@ -229,7 +229,7 @@
},
{
"question": {
"nl": "Bakt deze frituur in dierlijk vetof plantaardig olie?",
"nl": "Bakt deze frituur met dierlijk vet of met plantaardige olie?",
"fr": "Cette friteuse fonctionne-t-elle avec de la graisse animale ou végétale ?"
},
"mappings": [
@ -266,7 +266,7 @@
},
"mappings": [
{
"if": "bulk_purchase=yes",
"if": "reusable_packaging:accept=yes",
"then": {
"nl": "Je mag je <b>eigen containers</b> meenemen om je bestelling in mee te nemen en zo minder afval te maken",
"en": "You can bring <b>your own containers</b> to get your order, saving on single-use packaging material and thus waste",
@ -275,7 +275,7 @@
}
},
{
"if": "bulk_purchase=no",
"if": "reusable_packaging:accept=no",
"then": {
"nl": "Je mag <b>geen</b> eigen containers meenemen om je bestelling in mee te nemen",
"en": "Bringing your own container is <b>not allowed</b>",
@ -285,7 +285,7 @@
}
},
{
"if": "bulk_purchase=only",
"if": "reusable_packaging:accept=only",
"then": {
"nl": "Je <b>moet</b> je eigen containers meenemen om je bestelling in mee te nemen.",
"en": "You <b>must</b> bring your own container to order here.",

View file

@ -21,6 +21,7 @@ import * as L from "leaflet";
import ValidatedTextField from "./UI/Input/ValidatedTextField";
import AvailableBaseLayers from "./Logic/Actors/AvailableBaseLayers";
import LayoutConfig from "./Models/ThemeConfig/LayoutConfig";
import Constants from "./Models/Constants";
// Workaround for a stupid crash: inject some functions which would give stupid circular dependencies or crash the other nodejs scripts
SimpleMetaTagger.coder = new CountryCoder("https://pietervdvn.github.io/latlon2country/");
@ -159,7 +160,8 @@ if (layoutFromBase64.startsWith("http")) {
new FixedUiElement("").AttachTo("centermessage")
State.state = new State(undefined);
new Combine([new MoreScreen(true),
Translations.t.general.aboutMapcomplete.SetClass("link-underline")
Translations.t.general.aboutMapcomplete.SetClass("link-underline"),
new FixedUiElement("v"+Constants.vNumber)
]).SetClass("block m-5 lg:w-3/4 lg:ml-40")
.SetStyle("pointer-events: all;")
.AttachTo("topleft-tools");

View file

@ -1499,6 +1499,28 @@
}
}
},
"food": {
"name": "Restaurants and fast food",
"presets": {
"0": {
"title": "restaurant",
"description": "A formal eating place with sit-down facilities selling full meals served by waiters"
},
"1": {
"title": "fastfood"
}
},
"title": {
"mappings": {
"0": {
"then": "Restaurant <i>{name}</i>"
},
"1": {
"then": "Fastfood <i>{name}</i>"
}
}
}
},
"ghost_bike": {
"name": "Ghost bikes",
"title": {

View file

@ -1555,6 +1555,36 @@
}
}
},
"food": {
"name": "Eetgelegenheden",
"presets": {
"0": {
"title": "restaurant",
"description": "Een eetgegelegenheid waar je aan tafel wordt bediend"
},
"1": {
"title": "fastfood-zaak",
"description": "Een zaak waar je snel bediend wordt, vaak met de focus op afhalen. Zitgelegenheid is eerder beperkt tot afwezig"
}
},
"title": {
"render": "Eetgelegenheid",
"mappings": {
"0": {
"then": "Restaurant <i>{name}</i>"
},
"1": {
"then": "Fastfood-zaak <i>{name}</i>"
}
}
},
"tagRenderings": {
"1": {
"question": "Wat is de naam van deze eetgelegenheid?",
"render": "De naam van deze eetgelegeheid is {name}"
}
}
},
"ghost_bike": {
"name": "Witte Fietsen",
"title": {

View file

@ -52,11 +52,12 @@
"intro": "Je klikte ergens waar er nog geen data is. Kies hieronder welk punt je wilt toevoegen<br/>",
"pleaseLogin": "<a class='activate-osm-authentication'>Gelieve je aan te melden om een punt to te voegen</a>",
"zoomInFurther": "Gelieve verder in te zoomen om een punt toe te voegen.",
"stillLoading": "De data wordt nog geladen. Nog even geduld en dan kan je een punt toevoegen.",
"stillLoading": "De data worden nog geladen. Nog even geduld en dan kan je een punt toevoegen.",
"confirmIntro": "<h3>Voeg hier een {title} toe?</h3>Het punt dat je hier toevoegt, is <b>zichtbaar voor iedereen</b>. Veel applicaties gebruiken deze data, voeg dus enkel punten toe die echt bestaan.",
"confirmButton": "Voeg hier een {category} toe<br/><div class='alert'>Je toevoeging is voor iedereen zichtbaar</div>",
"openLayerControl": "Open de laag-instellingen",
"layerNotEnabled": "De laag {layer} is gedeactiveerd. Activeer deze om een punt toe te voegen"
"layerNotEnabled": "De laag {layer} is gedeactiveerd. Activeer deze om een punt toe te voegen",
"presetInfo": "Het nieuwe punt krijgt de attributen {tags}"
},
"pickLanguage": "Kies je taal: ",
"about": "Bewerk en voeg data toe aan OpenStreetMap over een specifiek onderwerp op een gemakkelijke manier",

View file

@ -692,6 +692,18 @@
}
}
},
"cycle_highways": {
"title": "Cycle highways",
"description": "This map shows cycle highways",
"layers": {
"0": {
"name": "cycle highways",
"title": {
"render": "cycle highway"
}
}
}
},
"cycle_infra": {
"title": "Bicycle infrastructure",
"shortDescription": "A map where you can view and edit things related to the bicycle infrastructure.",
@ -845,6 +857,9 @@
}
}
},
"food": {
"title": "Restaurants and fast food"
},
"fritures": {
"layers": {
"0": {

View file

@ -733,6 +733,10 @@
}
}
},
"food": {
"title": "Eetgelegenheden",
"description": "Restaurants en fast food"
},
"fritures": {
"title": "Friturenkaart",
"description": "Op deze kaart vind je je favoriete frituur!",

View file

@ -65,12 +65,6 @@ function missingLicenseInfos(licenseInfos: SmallLicense[], allIcons: string[]) {
const prompt = require('prompt-sync')();
const knownLicenses = new Map<string, SmallLicense>()
knownLicenses.set("cf", {
authors: ["Pieter Fiers", "Thibault Declercq", "Pierre Barban", "Joost Schouppe", "Pieter Vander Vennet"],
path: undefined,
license: "CC-BY-SA",
sources: ["https://osoc.be/editions/2020/cyclofix"]
})
knownLicenses.set("me", {
authors: ["Pieter Vander Vennet"],
path: undefined,
@ -92,19 +86,7 @@ knownLicenses.set("na", {
sources: []
})
knownLicenses.set("chrn", {
authors: ["Christian Neumann"],
path: undefined,
license: "CC-BY-SA 3.0",
sources: ["https://utopicode.de/", "https://github.com/chrneumann/MapComplete"]
})
knownLicenses.set("klimaan", {
authors: ["Klimaan VZW"],
path: undefined,
license: "CC-BY-SA 3.0",
sources: ["https://klimaan.be/"]
})
function promptLicenseFor(path): SmallLicense {
console.log("License abbreviations:")