Merge branch 'develop'

This commit is contained in:
Pieter Vander Vennet 2020-11-09 19:55:37 +01:00
commit 613ed74276
6 changed files with 83 additions and 6 deletions

View file

@ -28,9 +28,10 @@ export class AllKnownLayouts {
const layout = Layout.LayoutFromJSON(cyclofix, SharedLayers.sharedLayers) const layout = Layout.LayoutFromJSON(cyclofix, SharedLayers.sharedLayers)
const now = new Date(); const now = new Date();
const m = now.getMonth() + 1; const m = now.getMonth() + 1;
const day = new Date().getDay() + 1; const day = new Date().getDate() + 1;
const date = day + "/" + m; const date = day + "/" + m;
if (date === "31/10" || date === "1/11" || date === "2/11") { if (date === "31/10" || date === "1/11" || date === "2/11") {
console.log("The current date is ",date,", which means we remember our dead")
// Around Halloween/Fiesta de muerte/Allerzielen, we remember the dead // Around Halloween/Fiesta de muerte/Allerzielen, we remember the dead
layout.layers.push( layout.layers.push(
SharedLayers.sharedLayers.get("ghost_bike") SharedLayers.sharedLayers.get("ghost_bike")

View file

@ -10,6 +10,7 @@ import * as bike_cafes from "../assets/layers/bike_cafe/bike_cafes.json"
import * as bike_monitoring_station from "../assets/layers/bike_monitoring_station/bike_monitoring_station.json" import * as bike_monitoring_station from "../assets/layers/bike_monitoring_station/bike_monitoring_station.json"
import * as cycling_themed_objects from "../assets/layers/cycling_themed_object/cycling_themed_objects.json" import * as cycling_themed_objects from "../assets/layers/cycling_themed_object/cycling_themed_objects.json"
import * as bike_shops from "../assets/layers/bike_shop/bike_shop.json" import * as bike_shops from "../assets/layers/bike_shop/bike_shop.json"
import * as bike_cleaning from "../assets/layers/bike_cleaning/bike_cleaning.json"
import * as maps from "../assets/layers/maps/maps.json" import * as maps from "../assets/layers/maps/maps.json"
import * as information_boards from "../assets/layers/information_board/information_board.json" import * as information_boards from "../assets/layers/information_board/information_board.json"
import LayerConfig from "./JSON/LayerConfig"; import LayerConfig from "./JSON/LayerConfig";
@ -34,6 +35,7 @@ export default class SharedLayers {
new LayerConfig(bike_cafes, "shared_layers"), new LayerConfig(bike_cafes, "shared_layers"),
new LayerConfig(cycling_themed_objects, "shared_layers"), new LayerConfig(cycling_themed_objects, "shared_layers"),
new LayerConfig(bike_shops, "shared_layers"), new LayerConfig(bike_shops, "shared_layers"),
new LayerConfig(bike_cleaning, "shared_layers"),
new LayerConfig(maps, "shared_layers"), new LayerConfig(maps, "shared_layers"),
new LayerConfig(information_boards, "shared_layers") new LayerConfig(information_boards, "shared_layers")
]; ];

View file

@ -211,4 +211,7 @@ https://commons.wikimedia.org/w/index.php?title=Antu_chronometer
Fries icon: Fries icon:
https://www.flaticon.com/free-icon/french-fries_1144288 https://www.flaticon.com/free-icon/french-fries_1144288
Shower icon (used in 'bike_cleaning.svg'):
https://commons.wikimedia.org/wiki/File:Shower_symbol.svg
Bench icons from StreetComplete: https://github.com/westnordost/StreetComplete/tree/v25.0-beta1/res/graphics/quest%20icons, GPLv3.0 Bench icons from StreetComplete: https://github.com/westnordost/StreetComplete/tree/v25.0-beta1/res/graphics/quest%20icons, GPLv3.0

View file

@ -139,6 +139,40 @@
} }
] ]
}, },
"titleIcons": [
{
"mappings": [
{
"if": "service:bicycle:pump=yes",
"then": "<img src='./assets/layers/bike_shop/pump.svg'>"
}
]
},
{
"mappings": [
{
"if": "service:bicycle:diy=yes",
"then": "<img src='./assets/layers/bike_shop/tools.svg'>"
}
]
},
{
"mappings": [
{
"if": {
"or": [
"service:bicycle:cleaning=yes",
"service:bicycle:cleaning=diy"
]
},
"then": "<img src='./assets/layers/bike_shop/bike_cleaning.svg'>"
}
]
},
"wikipedialink",
"osmlink"
],
"description": { "description": {
"en": "A shop specifically selling bicycles or related items", "en": "A shop specifically selling bicycles or related items",
"nl": "Een winkel die hoofdzakelijk fietsen en fietstoebehoren verkoopt" "nl": "Een winkel die hoofdzakelijk fietsen en fietstoebehoren verkoopt"
@ -438,6 +472,35 @@
} }
} }
] ]
},
{
"question": {
"en": "Are bicycles washed here?",
"nl": "Biedt deze winkel een fietsschoonmaak aan?"
},
"mappings": [
{
"if": "service:bicycle:cleaning=yes",
"then": {
"en": "This shop cleans bicycles",
"nl": "Deze winkel biedt fietsschoonmaak aan"
}
},
{
"if": "service:bicycle:cleaning=diy",
"then": {
"en": "This shop has an installation where one can clean bicycles themselves",
"nl": "Deze winkel biedt een installatie aan om zelf je fiets schoon te maken"
}
},
{
"if": "service:bicycle:cleaning=no",
"then": {
"en": "This shop doesn't offer bicycle cleaning",
"nl": "Deze winkel biedt geen fietsschoonmaak aan"
}
}
]
} }
], ],
"hideUnderlayingFeaturesMinPercentage": 1, "hideUnderlayingFeaturesMinPercentage": 1,

View file

@ -16,7 +16,16 @@
"de": "Trinkwasser" "de": "Trinkwasser"
} }
}, },
"icon": "./assets/layers/drinking_water/drinking_water.svg", "icon": {
"render": "./assets/layers/drinking_water/drinking_water.svg",
"mappings": [
{
"if": {"or": ["operational_status=broken", "operational_status=closed"]},
"then": "./assets/layers/drinking_water/drinking_water_broken.svg"
}
]
},
"iconSize": "40,40,bottom", "iconSize": "40,40,bottom",
"overpassTags": { "overpassTags": {
"and": [ "and": [
@ -41,7 +50,7 @@
] ]
} }
], ],
"color": "#00bb00", "color": "#6bc4f7",
"tagRenderings": [ "tagRenderings": [
"images", "images",
{ {
@ -63,8 +72,7 @@
"then": { "then": {
"en": "This drinking water works", "en": "This drinking water works",
"nl": "Deze drinkwaterfonteint werkt" "nl": "Deze drinkwaterfonteint werkt"
}, }
"hideInAnswer": true
}, },
{ {
"if": "operational_status=broken", "if": "operational_status=broken",

View file

@ -25,6 +25,6 @@
"startZoom": 16, "startZoom": 16,
"widenFactor": 0.05, "widenFactor": 0.05,
"socialImage": "./assets/themes/cyclofix/logo.svg", "socialImage": "./assets/themes/cyclofix/logo.svg",
"layers": ["bike_cafes", "bike_shops", "bike_repair_station", "drinking_water", "bike_themed_object","bike_parking"], "layers": ["bike_cafes", "bike_shops", "bike_repair_station", "drinking_water", "bike_themed_object","bike_cleaning","bike_parking"],
"roamingRenderings": [] "roamingRenderings": []
} }