diff --git a/Customizations/SharedTagRenderings.ts b/Customizations/SharedTagRenderings.ts index 035a61dcc..0f47ef9a9 100644 --- a/Customizations/SharedTagRenderings.ts +++ b/Customizations/SharedTagRenderings.ts @@ -15,7 +15,7 @@ export default class SharedTagRenderings { const d = new Map() for (const key of Array.from(configJsons.keys())) { try { - d.set(key, new TagRenderingConfig(configJsons.get(key), undefined, `SharedTagRenderings.${key}`)) + d.set(key, new TagRenderingConfig(configJsons.get(key), `SharedTagRenderings.${key}`)) } catch (e) { if (!Utils.runningFromConsole) { console.error("BUG: could not parse", key, " from questions.json or icons.json - this error happened during the build step of the SharedTagRenderings", e) diff --git a/Models/ThemeConfig/PointRenderingConfig.ts b/Models/ThemeConfig/PointRenderingConfig.ts index 75f382029..51cfc18d6 100644 --- a/Models/ThemeConfig/PointRenderingConfig.ts +++ b/Models/ThemeConfig/PointRenderingConfig.ts @@ -27,7 +27,6 @@ export default class PointRenderingConfig extends WithContextLoader { this.iconOverlays = (json.iconOverlays ?? []).map((overlay, i) => { let tr = new TagRenderingConfig( overlay.then, - undefined, `iconoverlays.${i}` ); if ( @@ -93,15 +92,6 @@ export default class PointRenderingConfig extends WithContextLoader { return n; } - function rendernum(tr: TagRenderingConfig, deflt: number) { - const str = Number(render(tr, "" + deflt)); - const n = Number(str); - if (isNaN(n)) { - return deflt; - } - return n; - } - function render(tr: TagRenderingConfig, deflt?: string) { if (tags === undefined) { return deflt diff --git a/Models/ThemeConfig/TagRenderingConfig.ts b/Models/ThemeConfig/TagRenderingConfig.ts index a498894d1..42c8e60ea 100644 --- a/Models/ThemeConfig/TagRenderingConfig.ts +++ b/Models/ThemeConfig/TagRenderingConfig.ts @@ -37,9 +37,8 @@ export default class TagRenderingConfig { readonly then: Translation readonly hideInAnswer: boolean | TagsFilter }[] - readonly roaming: boolean; - constructor(json: string | TagRenderingConfigJson, conditionIfRoaming: TagsFilter, context?: string) { + constructor(json: string | TagRenderingConfigJson, context?: string) { if (json === "questions") { // Very special value @@ -61,13 +60,7 @@ export default class TagRenderingConfig { this.id = json.id ?? ""; this.render = Translations.T(json.render, context + ".render"); this.question = Translations.T(json.question, context + ".question"); - this.roaming = json.roaming ?? false; - const condition = TagUtils.Tag(json.condition ?? {"and": []}, `${context}.condition`); - if (this.roaming && conditionIfRoaming !== undefined) { - this.condition = new And([condition, conditionIfRoaming]); - } else { - this.condition = condition; - } + this.condition = TagUtils.Tag(json.condition ?? {"and": []}, `${context}.condition`); if (json.freeform) { if(json.freeform.addExtraTags !== undefined && json.freeform.addExtraTags.map === undefined){ diff --git a/Models/ThemeConfig/WithContextLoader.ts b/Models/ThemeConfig/WithContextLoader.ts index 9a4758a23..cfdc5439b 100644 --- a/Models/ThemeConfig/WithContextLoader.ts +++ b/Models/ThemeConfig/WithContextLoader.ts @@ -24,7 +24,6 @@ export default class WithContextLoader { } return new TagRenderingConfig( deflt, - undefined, `${this._context}.${key}.default value` ); } @@ -36,7 +35,6 @@ export default class WithContextLoader { } return new TagRenderingConfig( v, - undefined, `${this._context}.${key}` ); } @@ -72,7 +70,7 @@ export default class WithContextLoader { )}`; } - const tr = new TagRenderingConfig("questions", undefined, context); + const tr = new TagRenderingConfig("questions", context); renderings.push(tr) continue; } @@ -81,7 +79,6 @@ export default class WithContextLoader { const sharedJson = SharedTagRenderings.SharedTagRenderingJson.get(renderingId) const tr = new TagRenderingConfig( Utils.Merge(renderingJson["override"], sharedJson), - undefined, `${context}.tagrendering[${i}]+override` ); renderings.push(tr) @@ -106,7 +103,6 @@ export default class WithContextLoader { const tr = new TagRenderingConfig( renderingJson, - undefined, `${context}.tagrendering[${i}]` ); renderings.push(tr) diff --git a/UI/Input/LocationInput.ts b/UI/Input/LocationInput.ts index 8e5474c33..3ff7fe5da 100644 --- a/UI/Input/LocationInput.ts +++ b/UI/Input/LocationInput.ts @@ -6,7 +6,6 @@ import BaseLayer from "../../Models/BaseLayer"; import Combine from "../Base/Combine"; import Svg from "../../Svg"; import State from "../../State"; -import AvailableBaseLayers from "../../Logic/Actors/AvailableBaseLayers"; import {GeoOperations} from "../../Logic/GeoOperations"; import ShowDataMultiLayer from "../ShowDataLayer/ShowDataMultiLayer"; import StaticFeatureSource from "../../Logic/FeatureSource/Sources/StaticFeatureSource"; @@ -16,7 +15,6 @@ import {FixedUiElement} from "../Base/FixedUiElement"; import ShowDataLayer from "../ShowDataLayer/ShowDataLayer"; import BaseUIElement from "../BaseUIElement"; import Toggle from "./Toggle"; -import {start} from "repl"; export default class LocationInput extends InputElement implements MinimapObj { @@ -25,12 +23,17 @@ export default class LocationInput extends InputElement implements MinimapO id: "matchpoint", source: { osmTags: {and: []} }, - icon: "./assets/svg/crosshair-empty.svg" + mapRendering: [{ + location: ["point"], + icon: "./assets/svg/crosshair-empty.svg" + }] }, "matchpoint icon", true ) - + IsSelected: UIEventSource = new UIEventSource(false); public readonly snappedOnto: UIEventSource = new UIEventSource(undefined) + public readonly _matching_layer: LayerConfig; + public readonly leafletMap: UIEventSource private _centerLocation: UIEventSource; private readonly mapBackground: UIEventSource; /** @@ -43,10 +46,7 @@ export default class LocationInput extends InputElement implements MinimapO private readonly _maxSnapDistance: number private readonly _snappedPointTags: any; private readonly _bounds: UIEventSource; - public readonly _matching_layer: LayerConfig; private readonly map: BaseUIElement & MinimapObj; - public readonly leafletMap: UIEventSource - private readonly clickLocation: UIEventSource; private readonly _minZoom: number; @@ -83,7 +83,7 @@ export default class LocationInput extends InputElement implements MinimapO } this._matching_layer = matchingLayer; } else { - this._matching_layer = LocationInput.matchLayer + this._matching_layer = LocationInput.matchLayer } this._snappedPoint = options.centerLocation.map(loc => { @@ -158,25 +158,29 @@ export default class LocationInput extends InputElement implements MinimapO IsValid(t: Loc): boolean { return t !== undefined; } - + + installBounds(factor: number | BBox, showRange?: boolean): void { + this.map.installBounds(factor, showRange) + } + protected InnerConstructElement(): HTMLElement { try { const self = this; const hasMoved = new UIEventSource(false) - const startLocation = { ...this._centerLocation.data } - this._centerLocation. addCallbackD(newLocation => { + const startLocation = {...this._centerLocation.data} + this._centerLocation.addCallbackD(newLocation => { const f = 100000 console.log(newLocation.lon, startLocation.lon) - const diff = (Math.abs(newLocation.lon * f - startLocation.lon* f ) + Math.abs(newLocation.lat* f - startLocation.lat* f )) - if(diff < 1){ + const diff = (Math.abs(newLocation.lon * f - startLocation.lon * f) + Math.abs(newLocation.lat * f - startLocation.lat * f)) + if (diff < 1) { return; } hasMoved.setData(true) return true; }) this.clickLocation.addCallbackAndRunD(location => this._centerLocation.setData(location)) - if (this._snapTo !== undefined) { - + if (this._snapTo !== undefined) { + // Show the lines to snap to new ShowDataMultiLayer({ features: new StaticFeatureSource(this._snapTo, true), @@ -184,7 +188,7 @@ export default class LocationInput extends InputElement implements MinimapO zoomToFeatures: false, leafletMap: this.map.leafletMap, layers: State.state.filteredLayers, - allElements: State.state.allElements + allElements: State.state.allElements } ) // Show the central point @@ -194,16 +198,16 @@ export default class LocationInput extends InputElement implements MinimapO } return [{feature: loc}]; }) - new ShowDataLayer({ - features: new StaticFeatureSource(matchPoint, true), - enablePopups: false, - zoomToFeatures: false, - leafletMap: this.map.leafletMap, - layerToShow: this._matching_layer, - allElements: State.state.allElements, - selectedElement: State.state.selectedElement - }) - + new ShowDataLayer({ + features: new StaticFeatureSource(matchPoint, true), + enablePopups: false, + zoomToFeatures: false, + leafletMap: this.map.leafletMap, + layerToShow: this._matching_layer, + allElements: State.state.allElements, + selectedElement: State.state.selectedElement + }) + } this.mapBackground.map(layer => { const leaflet = this.map.leafletMap.data @@ -216,19 +220,19 @@ export default class LocationInput extends InputElement implements MinimapO leaflet.setZoom(layer.max_zoom - 1) }, [this.map.leafletMap]) - + const animatedHand = Svg.hand_ui() .SetStyle("width: 2rem; height: unset;") .SetClass("hand-drag-animation block pointer-events-none") - + return new Combine([ new Combine([ Svg.move_arrows_ui() .SetClass("block relative pointer-events-none") .SetStyle("left: -2.5rem; top: -2.5rem; width: 5rem; height: 5rem") - ]).SetClass("block w-0 h-0 z-10 relative") + ]).SetClass("block w-0 h-0 z-10 relative") .SetStyle("background: rgba(255, 128, 128, 0.21); left: 50%; top: 50%; opacity: 0.5"), - + new Toggle(undefined, animatedHand, hasMoved) .SetClass("block w-0 h-0 z-10 relative") @@ -244,9 +248,4 @@ export default class LocationInput extends InputElement implements MinimapO } } - - installBounds(factor: number | BBox, showRange?: boolean): void { - this.map.installBounds(factor, showRange) - } - } \ No newline at end of file diff --git a/UI/Popup/DeleteWizard.ts b/UI/Popup/DeleteWizard.ts index 478737a9e..b0981f78b 100644 --- a/UI/Popup/DeleteWizard.ts +++ b/UI/Popup/DeleteWizard.ts @@ -264,7 +264,7 @@ export default class DeleteWizard extends Toggle { ] - }, undefined, "Delete wizard" + }, "Delete wizard" ) } diff --git a/UI/Popup/FeatureInfoBox.ts b/UI/Popup/FeatureInfoBox.ts index 155df8bdc..c31eff395 100644 --- a/UI/Popup/FeatureInfoBox.ts +++ b/UI/Popup/FeatureInfoBox.ts @@ -37,7 +37,7 @@ export default class FeatureInfoBox extends ScrollableFullScreen { private static GenerateTitleBar(tags: UIEventSource, layerConfig: LayerConfig): BaseUIElement { - const title = new TagRenderingAnswer(tags, layerConfig.title ?? new TagRenderingConfig("POI", undefined)) + const title = new TagRenderingAnswer(tags, layerConfig.title ?? new TagRenderingConfig("POI")) .SetClass("break-words font-bold sm:p-0.5 md:p-1 sm:p-1.5 md:p-2"); const titleIcons = new Combine( layerConfig.titleIcons.map(icon => new TagRenderingAnswer(tags, icon, @@ -132,7 +132,7 @@ export default class FeatureInfoBox extends ScrollableFullScreen { new VariableUiElement( State.state.featureSwitchIsDebugging.map(isDebugging => { if (isDebugging) { - const config: TagRenderingConfig = new TagRenderingConfig({render: "{all_tags()}"}, new Tag("id", ""), ""); + const config: TagRenderingConfig = new TagRenderingConfig({render: "{all_tags()}"}, ""); return new TagRenderingAnswer(tags, config, "all_tags") } }) diff --git a/UI/Popup/SplitRoadWizard.ts b/UI/Popup/SplitRoadWizard.ts index 9c321d8b9..2e2f38c85 100644 --- a/UI/Popup/SplitRoadWizard.ts +++ b/UI/Popup/SplitRoadWizard.ts @@ -21,8 +21,13 @@ export default class SplitRoadWizard extends Toggle { private static splitLayerStyling = new LayerConfig({ id: "splitpositions", source: {osmTags: "_cutposition=yes"}, - icon: {render: "circle:white;./assets/svg/scissors.svg"}, - iconSize: {render: "30,30,center"}, + mapRendering: [ + { + location: ["point"], + icon: {render: "circle:white;./assets/svg/scissors.svg"}, + iconSize: {render: "30,30,center"} + } + ], }, "(BUILTIN) SplitRoadWizard.ts", true) public dialogIsOpened: UIEventSource @@ -61,7 +66,7 @@ export default class SplitRoadWizard extends Toggle { miniMap.installBounds(BBox.get(roadElement).pad(0.25), false) // Define how a cut is displayed on the map - + // Datalayer displaying the road and the cut points (if any) new ShowDataLayer({ features: new StaticFeatureSource(splitPoints, true), diff --git a/assets/layers/artwork/artwork.json b/assets/layers/artwork/artwork.json index b89f83df7..82e27e9c7 100644 --- a/assets/layers/artwork/artwork.json +++ b/assets/layers/artwork/artwork.json @@ -394,5 +394,16 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/artwork/artwork.svg" + }, + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/barrier/barrier.json b/assets/layers/barrier/barrier.json index afa8bcfaf..8461abce3 100644 --- a/assets/layers/barrier/barrier.json +++ b/assets/layers/barrier/barrier.json @@ -323,5 +323,13 @@ }, "id": "Overlap (cyclebarrier)" } + ], + "mapRendering": [ + { + "icon": "./assets/layers/barrier/barrier.svg", + "location": [ + "point" + ] + } ] } \ No newline at end of file diff --git a/assets/layers/bench/bench.json b/assets/layers/bench/bench.json index ca08d1575..11587d5aa 100644 --- a/assets/layers/bench/bench.json +++ b/assets/layers/bench/bench.json @@ -644,5 +644,18 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/layers/bench/bench.svg" + }, + "iconSize": { + "render": "35,35,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/bench_at_pt/bench_at_pt.json b/assets/layers/bench_at_pt/bench_at_pt.json index 29c759a63..c43ec58e6 100644 --- a/assets/layers/bench_at_pt/bench_at_pt.json +++ b/assets/layers/bench_at_pt/bench_at_pt.json @@ -148,5 +148,18 @@ }, "color": { "render": "#00f" - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/benches/bench_public_transport.svg" + }, + "iconSize": { + "render": "35,35,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/bicycle_library/bicycle_library.json b/assets/layers/bicycle_library/bicycle_library.json index 735a45990..3d5dcc455 100644 --- a/assets/layers/bicycle_library/bicycle_library.json +++ b/assets/layers/bicycle_library/bicycle_library.json @@ -287,5 +287,31 @@ "color": { "render": "#c00" }, - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "pin:#22ff55;./assets/layers/bicycle_library/bicycle_library.svg" + }, + "iconOverlays": [ + { + "if": "opening_hours~*", + "then": "isOpen", + "badge": true + }, + { + "if": "service:bicycle:pump=yes", + "then": "circle:#e2783d;./assets/layers/bike_repair_station/pump.svg", + "badge": true + } + ], + "iconSize": { + "render": "50,50,bottom" + }, + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/bicycle_tube_vending_machine/bicycle_tube_vending_machine.json b/assets/layers/bicycle_tube_vending_machine/bicycle_tube_vending_machine.json index 6f069aacf..5b44f6882 100644 --- a/assets/layers/bicycle_tube_vending_machine/bicycle_tube_vending_machine.json +++ b/assets/layers/bicycle_tube_vending_machine/bicycle_tube_vending_machine.json @@ -276,5 +276,29 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "pin:#ffffff;./assets/layers/bicycle_tube_vending_machine/pinIcon.svg" + }, + "iconOverlays": [ + { + "if": { + "or": [ + "operational_status=broken", + "operational_status=closed" + ] + }, + "then": "close:#c33", + "badge": true + } + ], + "iconSize": "50,50,bottom", + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/bike_cafe/bike_cafe.json b/assets/layers/bike_cafe/bike_cafe.json index c3b328beb..53caf147b 100644 --- a/assets/layers/bike_cafe/bike_cafe.json +++ b/assets/layers/bike_cafe/bike_cafe.json @@ -365,5 +365,19 @@ ] } ], - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/bike_cafe/bike_cafe.svg" + }, + "iconSize": { + "render": "50,50,bottom" + }, + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/bike_cleaning/bike_cleaning.json b/assets/layers/bike_cleaning/bike_cleaning.json index 9d56e19a5..0d6217933 100644 --- a/assets/layers/bike_cleaning/bike_cleaning.json +++ b/assets/layers/bike_cleaning/bike_cleaning.json @@ -162,5 +162,31 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/bike_cleaning/bike_cleaning.svg" + }, + "iconOverlays": [ + { + "if": { + "and": [ + "service:bicycle:cleaning~*", + "amenity!=bike_wash" + ] + }, + "then": { + "render": "./assets/layers/bike_cleaning/bike_cleaning_icon.svg", + "roaming": true + }, + "badge": true + } + ], + "iconSize": "50,50,bottom", + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/bike_parking/bike_parking.json b/assets/layers/bike_parking/bike_parking.json index 380f97c37..94880bfe7 100644 --- a/assets/layers/bike_parking/bike_parking.json +++ b/assets/layers/bike_parking/bike_parking.json @@ -551,5 +551,17 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/bike_parking/parking.svg" + }, + "iconSize": "40,40,bottom", + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/bike_repair_station/bike_repair_station.json b/assets/layers/bike_repair_station/bike_repair_station.json index 8b78c689d..0a44bf6ce 100644 --- a/assets/layers/bike_repair_station/bike_repair_station.json +++ b/assets/layers/bike_repair_station/bike_repair_station.json @@ -768,5 +768,78 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": { + "en": "./assets/layers/bike_repair_station/repair_station.svg", + "ru": "./assets/layers/bike_repair_station/repair_station.svg", + "it": "./assets/layers/bike_repair_station/repair_station.svg", + "fi": "./assets/layers/bike_repair_station/repair_station.svg", + "fr": "./assets/layers/bike_repair_station/repair_station.svg", + "pt_BR": "./assets/layers/bike_repair_station/repair_station.svg", + "de": "./assets/layers/bike_repair_station/repair_station.svg", + "pt": "./assets/layers/bike_repair_station/repair_station.svg" + }, + "mappings": [ + { + "if": { + "and": [ + "service:bicycle:pump=no", + "service:bicycle:pump:operational_status=broken" + ] + }, + "then": "./assets/layers/bike_repair_station/repair_station.svg" + }, + { + "if": { + "and": [ + "service:bicycle:pump=yes", + "service:bicycle:tools=yes" + ] + }, + "then": "./assets/layers/bike_repair_station/repair_station_pump.svg" + }, + { + "if": { + "and": [ + "service:bicycle:pump:operational_status=broken", + "service:bicycle:tools=no" + ] + }, + "then": "./assets/layers/bike_repair_station/broken_pump_2.svg" + }, + { + "if": { + "and": [ + "service:bicycle:pump=yes", + { + "or": [ + "service:bicycle:tools=no", + "service:bicycle:tools=" + ] + } + ] + }, + "then": "./assets/layers/bike_repair_station/pump.svg" + } + ] + }, + "iconOverlays": [ + { + "if": "operator=De Fietsambassade Gent", + "then": "./assets/themes/cyclofix/fietsambassade_gent_logo_small.svg", + "badge": true + } + ], + "iconSize": { + "render": "50,50,bottom" + }, + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/bike_shop/bike_shop.json b/assets/layers/bike_shop/bike_shop.json index 061575037..0654df919 100644 --- a/assets/layers/bike_shop/bike_shop.json +++ b/assets/layers/bike_shop/bike_shop.json @@ -711,5 +711,41 @@ "color": { "render": "#c00" }, - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/bike_shop/repair_shop.svg", + "mappings": [ + { + "if": "operator=De Fietsambassade Gent", + "then": "./assets/themes/cyclofix/fietsambassade_gent_logo_small.svg" + }, + { + "if": "service:bicycle:retail=yes", + "then": "./assets/layers/bike_shop/shop.svg" + } + ] + }, + "iconOverlays": [ + { + "if": "opening_hours~*", + "then": "isOpen", + "badge": true + }, + { + "if": "service:bicycle:pump=yes", + "then": "circle:#e2783d;./assets/layers/bike_repair_station/pump.svg", + "badge": true + } + ], + "iconSize": { + "render": "50,50,bottom" + }, + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/bike_themed_object/bike_themed_object.json b/assets/layers/bike_themed_object/bike_themed_object.json index 527376742..a6653c8b7 100644 --- a/assets/layers/bike_themed_object/bike_themed_object.json +++ b/assets/layers/bike_themed_object/bike_themed_object.json @@ -69,5 +69,19 @@ "render": "#AB76D5" }, "presets": [], - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/bike_themed_object/other_services.svg" + }, + "iconSize": { + "render": "50,50,bottom" + }, + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/binocular/binocular.json b/assets/layers/binocular/binocular.json index 5b84365e2..4e44ad7d9 100644 --- a/assets/layers/binocular/binocular.json +++ b/assets/layers/binocular/binocular.json @@ -127,5 +127,18 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "circle:white;./assets/layers/binocular/telescope.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/birdhide/birdhide.json b/assets/layers/birdhide/birdhide.json index c8015e5f4..c09c7e958 100644 --- a/assets/layers/birdhide/birdhide.json +++ b/assets/layers/birdhide/birdhide.json @@ -309,5 +309,29 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": { + "nl": "./assets/layers/birdhide/birdhide.svg" + }, + "mappings": [ + { + "if": { + "or": [ + "building=yes", + "shelter=yes", + "amenity=shelter" + ] + }, + "then": "./assets/layers/birdhide/birdshelter.svg" + } + ] + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/cafe_pub/cafe_pub.json b/assets/layers/cafe_pub/cafe_pub.json index cd5f6de2e..6fcbf9d14 100644 --- a/assets/layers/cafe_pub/cafe_pub.json +++ b/assets/layers/cafe_pub/cafe_pub.json @@ -203,5 +203,36 @@ ] } }, - "allowMove": true + "allowMove": true, + "mapRendering": [ + { + "icon": { + "render": "circle:white;./assets/layers/cafe_pub/pub.svg", + "mappings": [ + { + "if": "amenity=cafe", + "then": "circle:white;./assets/layers/cafe_pub/cafe.svg" + } + ] + }, + "iconOverlays": [ + { + "if": "opening_hours~*", + "then": "isOpen", + "badge": true + } + ], + "label": { + "mappings": [ + { + "if": "name~*", + "then": "
{name}
" + } + ] + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/charging_station/charging_station.json b/assets/layers/charging_station/charging_station.json index 3e421b24d..67ebde7a0 100644 --- a/assets/layers/charging_station/charging_station.json +++ b/assets/layers/charging_station/charging_station.json @@ -3729,5 +3729,69 @@ ], "eraseInvalidValues": true } + ], + "mapRendering": [ + { + "icon": { + "render": "pin:#fff;./assets/themes/charging_stations/plug.svg", + "mappings": [ + { + "if": "bicycle=yes", + "then": "pin:#fff;./assets/themes/charging_stations/bicycle.svg" + }, + { + "if": { + "or": [ + "car=yes", + "motorcar=yes" + ] + }, + "then": "pin:#fff;./assets/themes/charging_stations/car.svg" + } + ] + }, + "iconOverlays": [ + { + "if": { + "or": [ + "disused:amenity=charging_station", + "operational_status=broken" + ] + }, + "then": "cross_bottom_right:#c22;" + }, + { + "if": { + "or": [ + "proposed:amenity=charging_station", + "planned:amenity=charging_station" + ] + }, + "then": "./assets/layers/charging_station/under_construction.svg", + "badge": true + }, + { + "if": { + "and": [ + "bicycle=yes", + { + "or": [ + "motorcar=yes", + "car=yes" + ] + } + ] + }, + "then": "circle:#fff;./assets/themes/charging_stations/car.svg", + "badge": true + } + ], + "iconSize": { + "render": "50,50,bottom" + }, + "location": [ + "point" + ] + } ] } \ No newline at end of file diff --git a/assets/layers/cluster_style/cluster_style.json b/assets/layers/cluster_style/cluster_style.json index 7e93c506a..16bd123c7 100644 --- a/assets/layers/cluster_style/cluster_style.json +++ b/assets/layers/cluster_style/cluster_style.json @@ -36,5 +36,21 @@ "then": "
{kilocount}K
" } ] - } + }, + "mapRendering": [ + { + "label": { + "render": "
{showCount}
", + "mappings": [ + { + "if": "showCount>1000", + "then": "
{kilocount}K
" + } + ] + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/crossings/crossings.json b/assets/layers/crossings/crossings.json index 3b71f3f1e..a4e005b6e 100644 --- a/assets/layers/crossings/crossings.json +++ b/assets/layers/crossings/crossings.json @@ -331,5 +331,26 @@ } ] } + ], + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/crossings/pedestrian_crossing.svg", + "mappings": [ + { + "if": { + "or": [ + "highway=traffic_signals", + "crossing=traffic_signals" + ] + }, + "then": "./assets/layers/crossings/traffic_lights.svg" + } + ] + }, + "location": [ + "point" + ] + } ] } \ No newline at end of file diff --git a/assets/layers/cycleways_and_roads/cycleways_and_roads.json b/assets/layers/cycleways_and_roads/cycleways_and_roads.json index 8b10ac7b3..c6eb50400 100644 --- a/assets/layers/cycleways_and_roads/cycleways_and_roads.json +++ b/assets/layers/cycleways_and_roads/cycleways_and_roads.json @@ -1176,5 +1176,18 @@ } ] }, - "allowSplit": true + "allowSplit": true, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/cycle_infra/bicycleway.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/defibrillator/defibrillator.json b/assets/layers/defibrillator/defibrillator.json index 8a7fff1ec..a994361e4 100644 --- a/assets/layers/defibrillator/defibrillator.json +++ b/assets/layers/defibrillator/defibrillator.json @@ -553,5 +553,26 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/aed/aed.svg", + "mappings": [ + { + "if": "_recently_surveyed=true", + "then": { + "en": "./assets/layers/defibrillator/aed_checked.svg", + "ru": "./assets/layers/defibrillator/aed_checked.svg", + "it": "./assets/layers/defibrillator/aed_checked.svg", + "fr": "./assets/layers/defibrillator/aed_checked.svg" + } + } + ] + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/direction/direction.json b/assets/layers/direction/direction.json index 4d3fd684d..cb5b8b7da 100644 --- a/assets/layers/direction/direction.json +++ b/assets/layers/direction/direction.json @@ -43,5 +43,27 @@ "color": "--catch-detail-color", "stroke": "0", "presets": [], - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "direction_gradient:var(--catch-detail-color)", + "#": "For some weird reason, showing the icon in the layer control panel breaks the svg-gradient (because the svg gradient has a global color or smthng) - so we use a different icon without gradient", + "mappings": [ + { + "if": "id=node/-1", + "then": "direction:var(--catch-detail-color)" + } + ] + }, + "iconSize": "200,200,center", + "location": [ + "point", + "centroid" + ], + "rotation": { + "render": "{_direction:numerical}deg" + } + } + ] } \ No newline at end of file diff --git a/assets/layers/drinking_water/drinking_water.json b/assets/layers/drinking_water/drinking_water.json index c6040e3af..76130921f 100644 --- a/assets/layers/drinking_water/drinking_water.json +++ b/assets/layers/drinking_water/drinking_water.json @@ -179,5 +179,28 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "pin:#6BC4F7;./assets/layers/drinking_water/drips.svg" + }, + "iconOverlays": [ + { + "if": { + "or": [ + "operational_status=broken", + "operational_status=closed" + ] + }, + "then": "close:#c33", + "badge": true + } + ], + "iconSize": "40,40,bottom", + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/etymology/etymology.json b/assets/layers/etymology/etymology.json index 690612341..48cd87fe4 100644 --- a/assets/layers/etymology/etymology.json +++ b/assets/layers/etymology/etymology.json @@ -167,5 +167,29 @@ "then": "#fcca05aa" } ] - } + }, + "mapRendering": [ + { + "icon": { + "render": "pin:#05d7fcaa;./assets/layers/etymology/logo.svg", + "mappings": [ + { + "if": { + "and": [ + "name:etymology=", + "name:etymology:wikidata=" + ] + }, + "then": "pin:#fcca05aa;./assets/layers/etymology/logo.svg" + } + ] + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/food/food.json b/assets/layers/food/food.json index c2c966aac..3386e1b79 100644 --- a/assets/layers/food/food.json +++ b/assets/layers/food/food.json @@ -635,5 +635,57 @@ ] } }, - "allowMove": true + "allowMove": true, + "mapRendering": [ + { + "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": "
{name}
" + } + ] + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/ghost_bike/ghost_bike.json b/assets/layers/ghost_bike/ghost_bike.json index de82c8bae..1ec2c9dab 100644 --- a/assets/layers/ghost_bike/ghost_bike.json +++ b/assets/layers/ghost_bike/ghost_bike.json @@ -202,5 +202,14 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": "./assets/layers/ghost_bike/ghost_bike.svg", + "iconSize": "40,40,bottom", + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/grass_in_parks/grass_in_parks.json b/assets/layers/grass_in_parks/grass_in_parks.json index a95d6e0eb..321cebcb3 100644 --- a/assets/layers/grass_in_parks/grass_in_parks.json +++ b/assets/layers/grass_in_parks/grass_in_parks.json @@ -51,5 +51,15 @@ "id": "grass-in-parks-reviews", "render": "{reviews(name, landuse=grass )}" } + ], + "mapRendering": [ + { + "icon": "./assets/themes/playgrounds/playground.svg", + "iconSize": "40,40,center", + "location": [ + "point", + "centroid" + ] + } ] } \ No newline at end of file diff --git a/assets/layers/home_location/home_location.json b/assets/layers/home_location/home_location.json index 0bf07c75a..1cb233440 100644 --- a/assets/layers/home_location/home_location.json +++ b/assets/layers/home_location/home_location.json @@ -13,5 +13,18 @@ }, "color": { "render": "#00f" - } + }, + "mapRendering": [ + { + "icon": { + "render": "circle:white;./assets/svg/home.svg" + }, + "iconSize": { + "render": "20,20,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/information_board/information_board.json b/assets/layers/information_board/information_board.json index 1f6b08c2d..2f93526a8 100644 --- a/assets/layers/information_board/information_board.json +++ b/assets/layers/information_board/information_board.json @@ -68,5 +68,18 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/information_board/board.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/map/map.json b/assets/layers/map/map.json index b0031e573..ca7a5c389 100644 --- a/assets/layers/map/map.json +++ b/assets/layers/map/map.json @@ -240,5 +240,47 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/map/map.svg", + "mappings": [ + { + "if": { + "and": [ + "map_source=OpenStreetMap", + "map_source:attribution=sticker" + ] + }, + "then": "./assets/layers/map/map-stickered.svg" + }, + { + "if": { + "and": [ + "map_source=OpenStreetMap", + "map_source:attribution=yes" + ] + }, + "then": "./assets/layers/map/osm-logo-white-bg.svg" + }, + { + "if": { + "and": [ + "map_source=OpenStreetMap" + ] + }, + "then": "./assets/layers/map/osm-logo-buggy-attr.svg" + } + ] + }, + "iconSize": { + "render": "50,50,center" + }, + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/nature_reserve/nature_reserve.json b/assets/layers/nature_reserve/nature_reserve.json index 786f5e87b..28b27071c 100644 --- a/assets/layers/nature_reserve/nature_reserve.json +++ b/assets/layers/nature_reserve/nature_reserve.json @@ -461,5 +461,19 @@ } ] } + ], + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/nature_reserve/nature_reserve.svg" + }, + "iconSize": { + "render": "50,50,center" + }, + "location": [ + "point", + "centroid" + ] + } ] } \ No newline at end of file diff --git a/assets/layers/observation_tower/observation_tower.json b/assets/layers/observation_tower/observation_tower.json index 20f92ad8b..d40c9b81b 100644 --- a/assets/layers/observation_tower/observation_tower.json +++ b/assets/layers/observation_tower/observation_tower.json @@ -189,5 +189,18 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "circle:white;./assets/layers/observation_tower/Tower_observation.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/parking/parking.json b/assets/layers/parking/parking.json index b428d5f99..b2eccdd9e 100644 --- a/assets/layers/parking/parking.json +++ b/assets/layers/parking/parking.json @@ -94,5 +94,18 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/parking/parking.svg" + }, + "iconSize": { + "render": "36,36,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/picnic_table/picnic_table.json b/assets/layers/picnic_table/picnic_table.json index e4cdc4ac2..cf06e950b 100644 --- a/assets/layers/picnic_table/picnic_table.json +++ b/assets/layers/picnic_table/picnic_table.json @@ -114,5 +114,18 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "circle:#e6cf39;./assets/layers/picnic_table/picnic_table.svg" + }, + "iconSize": { + "render": "35,35,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/play_forest/play_forest.json b/assets/layers/play_forest/play_forest.json index 0b1f2485e..257f9249c 100644 --- a/assets/layers/play_forest/play_forest.json +++ b/assets/layers/play_forest/play_forest.json @@ -116,5 +116,19 @@ "description": "Een zone in het bos, duidelijk gemarkeerd als speelzone met de overeenkomstige borden.
" } ], - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/play_forest/icon.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/playground/playground.json b/assets/layers/playground/playground.json index 1baaab7cc..eb489ed71 100644 --- a/assets/layers/playground/playground.json +++ b/assets/layers/playground/playground.json @@ -535,5 +535,49 @@ "leisure=" ] } - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/playgrounds/playground.svg" + }, + "iconOverlays": [ + { + "if": { + "and": [ + "opening_hours!=24/7", + "opening_hours~*" + ] + }, + "then": "isOpen", + "badge": true + } + ], + "iconSize": { + "render": "40,40,center", + "mappings": [ + { + "if": "id~node/.*", + "then": "40,40,center" + }, + { + "if": "_size_classification=small", + "then": "25,25,center" + }, + { + "if": "_size_classification=medium", + "then": "40,40,center" + }, + { + "if": "_size_classification=large", + "then": "60,60,center" + } + ] + }, + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/public_bookcase/public_bookcase.json b/assets/layers/public_bookcase/public_bookcase.json index 64b6230c1..3f9abe815 100644 --- a/assets/layers/public_bookcase/public_bookcase.json +++ b/assets/layers/public_bookcase/public_bookcase.json @@ -485,5 +485,24 @@ } ] } + ], + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/bookcases/bookcase.svg;" + }, + "label": { + "mappings": [ + { + "if": "name~*", + "then": "
{name}
" + } + ] + }, + "location": [ + "point", + "centroid" + ] + } ] } \ No newline at end of file diff --git a/assets/layers/shops/shops.json b/assets/layers/shops/shops.json index 1e5679d48..15ced87ad 100644 --- a/assets/layers/shops/shops.json +++ b/assets/layers/shops/shops.json @@ -322,5 +322,26 @@ ] } }, - "allowMove": true + "allowMove": true, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/shops/shop.svg" + }, + "iconOverlays": [ + { + "if": "opening_hours~*", + "then": "isOpen", + "badge": true + } + ], + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point", + "centroid" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/slow_roads/slow_roads.json b/assets/layers/slow_roads/slow_roads.json index 50e7cd61d..f1624c853 100644 --- a/assets/layers/slow_roads/slow_roads.json +++ b/assets/layers/slow_roads/slow_roads.json @@ -252,5 +252,13 @@ "color": { "render": "#eaba2a" }, - "presets": [] + "presets": [], + "mapRendering": [ + { + "icon": "./assets/layers/slow_roads/slow_road.svg", + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/sport_pitch/sport_pitch.json b/assets/layers/sport_pitch/sport_pitch.json index 90f1dca73..cc39de256 100644 --- a/assets/layers/sport_pitch/sport_pitch.json +++ b/assets/layers/sport_pitch/sport_pitch.json @@ -490,5 +490,78 @@ "fixme=Toegevoegd met MapComplete, geometry nog uit te tekenen" ] } + ], + "mapRendering": [ + { + "icon": { + "render": "circle:white;./assets/layers/sport_pitch/sport_pitch.svg", + "mappings": [ + { + "if": { + "or": [ + "sport=baseball", + "sport=basketball", + "sport=beachvolleyball", + "sport=boules", + "sport=skateboard", + "sport=soccer", + "sport=table_tennis", + "sport=tennis", + "sport=volleyball" + ] + }, + "then": "circle:white;./assets/layers/sport_pitch/{sport}.svg" + } + ] + }, + "iconOverlays": [ + { + "if": { + "and": [ + "opening_hours!=24/7", + "opening_hours~*" + ] + }, + "then": "isOpen", + "badge": true + }, + { + "if": { + "or": [ + "access=customers", + "access=private", + "access=no" + ] + }, + "then": "circle:white;./assets/layers/sport_pitch/lock.svg", + "badge": true + } + ], + "iconSize": { + "render": "25,25,center", + "mappings": [ + { + "if": { + "or": [ + "_size_classification=medium", + "id~node/.*" + ] + }, + "then": "40,40,center" + }, + { + "if": "_size_classification=small", + "then": "25,25,center" + }, + { + "if": "_size_classification=large", + "then": "50,50,center" + } + ] + }, + "location": [ + "point" + ] + } ] } \ No newline at end of file diff --git a/assets/layers/surveillance_camera/surveillance_camera.json b/assets/layers/surveillance_camera/surveillance_camera.json index 7472ffd80..e1efe7c79 100644 --- a/assets/layers/surveillance_camera/surveillance_camera.json +++ b/assets/layers/surveillance_camera/surveillance_camera.json @@ -480,5 +480,57 @@ "title": "Surveillance camera" } ], - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/surveillance/logo.svg", + "mappings": [ + { + "if": "camera:type=dome", + "then": "./assets/themes/surveillance/dome.svg" + }, + { + "if": "_direction:leftright=right", + "then": "./assets/themes/surveillance/cam_right.svg" + }, + { + "if": "_direction:leftright=left", + "then": "./assets/themes/surveillance/cam_left.svg" + } + ] + }, + "iconSize": { + "mappings": [ + { + "if": "camera:type=dome", + "then": "50,50,center" + }, + { + "if": "_direction:leftright~*", + "then": "100,35,center" + } + ], + "render": "50,50,center" + }, + "location": [ + "point", + "centroid" + ], + "rotation": { + "#": "Note: {camera:direction} is substituted by a number, giving the string 'calc(123deg + 90deg)' ; it is this string that is used as css property, which interprets the calc", + "render": "calc({_direction:numerical}deg + 90deg)", + "mappings": [ + { + "if": "camera:type=dome", + "then": "0" + }, + { + "if": "_direction:leftright=right", + "then": "calc({_direction:numerical}deg - 90deg)" + } + ] + } + } + ] } \ No newline at end of file diff --git a/assets/layers/toilet/toilet.json b/assets/layers/toilet/toilet.json index 7b0366ca9..e30407251 100644 --- a/assets/layers/toilet/toilet.json +++ b/assets/layers/toilet/toilet.json @@ -511,5 +511,30 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/toilet/toilets.svg", + "mappings": [ + { + "if": "wheelchair=yes", + "then": "circle:white;./assets/layers/toilet/wheelchair.svg" + }, + { + "if": { + "or": [ + "toilets:position=urinals", + "toilets:position=urinal" + ] + }, + "then": "./assets/layers/toilet/urinal.svg" + } + ] + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/trail/trail.json b/assets/layers/trail/trail.json index fa33cc095..e7579f24b 100644 --- a/assets/layers/trail/trail.json +++ b/assets/layers/trail/trail.json @@ -206,5 +206,28 @@ }, "dashArray": { "render": "5 5" - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/trail/trail.svg", + "mappings": [ + { + "if": "wheelchair=yes", + "then": "./assets/layers/trail/wheelchair.svg" + }, + { + "if": "pushchair=yes", + "then": "./assets/layers/trail/pushchair.svg" + } + ] + }, + "iconSize": { + "render": "35,35,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/tree_node/tree_node.json b/assets/layers/tree_node/tree_node.json index 6d99b8382..428789429 100644 --- a/assets/layers/tree_node/tree_node.json +++ b/assets/layers/tree_node/tree_node.json @@ -582,5 +582,36 @@ }, "deletion": { "minNeededChangesets": 5 - } + }, + "mapRendering": [ + { + "icon": { + "render": "circle:#ffffff;./assets/themes/trees/unknown.svg", + "mappings": [ + { + "if": { + "and": [ + "leaf_type=broadleaved" + ] + }, + "then": "circle:#ffffff;./assets/themes/trees/broadleaved.svg" + }, + { + "if": { + "and": [ + "leaf_type=needleleaved" + ] + }, + "then": "circle:#ffffff;./assets/themes/trees/needleleaved.svg" + } + ] + }, + "iconSize": { + "render": "40,40,bottom" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/viewpoint/viewpoint.json b/assets/layers/viewpoint/viewpoint.json index 6f34c3159..08c05640f 100644 --- a/assets/layers/viewpoint/viewpoint.json +++ b/assets/layers/viewpoint/viewpoint.json @@ -70,5 +70,14 @@ }, "id": "viewpoint-description" } + ], + "mapRendering": [ + { + "icon": "./assets/layers/viewpoint/viewpoint.svg", + "iconSize": "20,20,center", + "location": [ + "point" + ] + } ] } \ No newline at end of file diff --git a/assets/layers/village_green/village_green.json b/assets/layers/village_green/village_green.json index 9aa60fca4..447bfe0e9 100644 --- a/assets/layers/village_green/village_green.json +++ b/assets/layers/village_green/village_green.json @@ -35,5 +35,15 @@ "id": "village_green-reviews", "render": "{reviews(name, landuse=village_green )}" } + ], + "mapRendering": [ + { + "icon": "./assets/themes/playgrounds/playground.svg", + "iconSize": "40,40,center", + "location": [ + "point", + "centroid" + ] + } ] } \ No newline at end of file diff --git a/assets/layers/visitor_information_centre/visitor_information_centre.json b/assets/layers/visitor_information_centre/visitor_information_centre.json index 322fb4eab..2ad99d47c 100644 --- a/assets/layers/visitor_information_centre/visitor_information_centre.json +++ b/assets/layers/visitor_information_centre/visitor_information_centre.json @@ -66,5 +66,18 @@ "render": "#E64C00" }, "presets": [], - "wayHandling": 1 + "wayHandling": 1, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/visitor_information_centre/information.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/waste_basket/waste_basket.json b/assets/layers/waste_basket/waste_basket.json index 98296a942..9172dd452 100644 --- a/assets/layers/waste_basket/waste_basket.json +++ b/assets/layers/waste_basket/waste_basket.json @@ -177,5 +177,32 @@ "allowMove": { "enableRelocation": false, "enableImproveAccuraccy": true - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/waste_basket/waste_basket.svg" + }, + "iconSize": { + "render": "40,40,center", + "mappings": [ + { + "if": { + "and": [ + "amenity=waste_basket" + ] + }, + "then": { + "en": "Waste Basket", + "nl": "Vuilnisbak", + "ru": "Контейнер для мусора" + } + } + ] + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/layers/watermill/watermill.json b/assets/layers/watermill/watermill.json index 1804424a7..1764ccc4f 100644 --- a/assets/layers/watermill/watermill.json +++ b/assets/layers/watermill/watermill.json @@ -171,5 +171,18 @@ }, "color": { "render": "#FFC0CB" - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/layers/watermill/watermill.svg" + }, + "iconSize": { + "render": "50,50,center" + }, + "location": [ + "point" + ] + } + ] } \ No newline at end of file diff --git a/assets/themes/aed/aed_brugge.json b/assets/themes/aed/aed_brugge.json index aad99cd44..8e74aafb0 100644 --- a/assets/themes/aed/aed_brugge.json +++ b/assets/themes/aed/aed_brugge.json @@ -42,6 +42,23 @@ "iconSize": "20,20,center", "tagRenderings": [ "all_tags" + ], + "mapRendering": [ + { + "icon": { + "render": "circle:red", + "mappings": [ + { + "if": "_has_closeby_feature=yes", + "then": "circle:#008000aa" + } + ] + }, + "iconSize": "20,20,center", + "location": [ + "point" + ] + } ] } ], diff --git a/assets/themes/buurtnatuur/buurtnatuur.json b/assets/themes/buurtnatuur/buurtnatuur.json index 9c4f2a189..2b75a568d 100644 --- a/assets/themes/buurtnatuur/buurtnatuur.json +++ b/assets/themes/buurtnatuur/buurtnatuur.json @@ -124,6 +124,19 @@ "nl": "Voeg een ontbrekend, erkend natuurreservaat toe, bv. een gebied dat beheerd wordt door het ANB of natuurpunt" } } + ], + "mapRendering": [ + { + "icon": { + "render": "circle:#ffffff;./assets/themes/buurtnatuur/nature_reserve.svg" + }, + "iconSize": { + "render": "50,50,center" + }, + "location": [ + "point" + ] + } ] }, { @@ -222,6 +235,19 @@ "nl": "Voeg een ontbrekend park toe" } } + ], + "mapRendering": [ + { + "icon": { + "render": "circle:#ffffff;./assets/themes/buurtnatuur/park.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } ] }, { @@ -339,6 +365,19 @@ "nl": "Voeg een ontbrekend bos toe aan de kaart" } } + ], + "mapRendering": [ + { + "icon": { + "render": "circle:#ffffff;./assets/themes/buurtnatuur/forest.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } ] }, "viewpoint" diff --git a/assets/themes/campersite/campersite.json b/assets/themes/campersite/campersite.json index a255aed85..3742c22d6 100644 --- a/assets/themes/campersite/campersite.json +++ b/assets/themes/campersite/campersite.json @@ -676,7 +676,31 @@ } } ], - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "circle:white;./assets/themes/campersite/caravan.svg", + "mappings": [ + { + "if": { + "and": [ + "fee=no" + ] + }, + "then": "circle:white;./assets/themes/campersite/caravan_green.svg" + } + ] + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point", + "centroid" + ] + } + ] }, { "id": "dumpstations", @@ -1075,6 +1099,19 @@ "de": "Fügen Sie eine neue sanitäre Entsorgungsstation hinzu. Hier können Camper Abwasser oder chemischen Toilettenabfälle entsorgen. Oft gibt es auch Trinkwasser und Strom." } } + ], + "mapRendering": [ + { + "icon": { + "render": "circle:white;./assets/themes/campersite/sanitary_dump_station.svg" + }, + "iconSize": { + "render": "32,32,center" + }, + "location": [ + "point" + ] + } ] } ], diff --git a/assets/themes/climbing/climbing.json b/assets/themes/climbing/climbing.json index b5720d4ae..161dd5d8d 100644 --- a/assets/themes/climbing/climbing.json +++ b/assets/themes/climbing/climbing.json @@ -215,7 +215,27 @@ } } ], - "wayHandling": 1 + "wayHandling": 1, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/climbing/club.svg" + }, + "iconOverlays": [ + { + "if": "opening_hours~*", + "then": "isOpen", + "badge": true + } + ], + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } + ] }, { "id": "climbing_gym", @@ -313,7 +333,27 @@ "iconSize": { "render": "40,40,center" }, - "wayHandling": 1 + "wayHandling": 1, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/climbing/climbing_gym.svg" + }, + "iconOverlays": [ + { + "if": "opening_hours~*", + "then": "isOpen", + "badge": true + } + ], + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } + ] }, { "id": "climbing_route", @@ -532,7 +572,21 @@ ] } ], - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "circle:white;./assets/themes/climbing/climbing_route.svg" + }, + "iconSize": { + "render": "28,28,center" + }, + "location": [ + "point", + "centroid" + ] + } + ] }, { "id": "climbing", @@ -801,6 +855,20 @@ "_difficulty_hist=JSON.parse(feat.properties._contained_climbing_routes_properties ?? '[]').map(p => p['climbing:grade:french'])", "_length_hist=JSON.parse(feat.properties._contained_climbing_routes_properties ?? '[]').map(p => p['climbing:length'])", "_contained_climbing_routes_count=JSON.parse(feat.properties._contained_climbing_routes_properties ?? '[]').length" + ], + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/climbing/climbing_no_rope.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point", + "centroid" + ] + } ] }, { @@ -930,7 +998,15 @@ "color": { "render": "#ddff55AA" }, - "wayHandling": 0 + "wayHandling": 0, + "mapRendering": [ + { + "icon": "./assets/themes/climbing/climbing_unknown.svg", + "location": [ + "point" + ] + } + ] } ], "roamingRenderings": [ diff --git a/assets/themes/cycle_highways/cycle_highways.json b/assets/themes/cycle_highways/cycle_highways.json index 35f49b110..01653d649 100644 --- a/assets/themes/cycle_highways/cycle_highways.json +++ b/assets/themes/cycle_highways/cycle_highways.json @@ -233,6 +233,13 @@ } ] } + ], + "mapRendering": [ + { + "location": [ + "point" + ] + } ] } ], diff --git a/assets/themes/cyclestreets/cyclestreets.json b/assets/themes/cyclestreets/cyclestreets.json index 339267198..cb53867f6 100644 --- a/assets/themes/cyclestreets/cyclestreets.json +++ b/assets/themes/cyclestreets/cyclestreets.json @@ -183,6 +183,14 @@ "width": "10", "tagRenderings": [ "images" + ], + "mapRendering": [ + { + "icon": "./assets/themes/cyclestreets/F111.svg", + "location": [ + "point" + ] + } ] }, { @@ -235,6 +243,14 @@ "width": "5", "tagRenderings": [ "images" + ], + "mapRendering": [ + { + "icon": "./assets/themes/cyclestreets/F113.svg", + "location": [ + "point" + ] + } ] }, { @@ -300,6 +316,14 @@ }, "tagRenderings": [ "images" + ], + "mapRendering": [ + { + "icon": "./assets/svg/pencil.svg", + "location": [ + "point" + ] + } ] } ], diff --git a/assets/themes/facadegardens/facadegardens.json b/assets/themes/facadegardens/facadegardens.json index 526dd699c..3d584898f 100644 --- a/assets/themes/facadegardens/facadegardens.json +++ b/assets/themes/facadegardens/facadegardens.json @@ -454,7 +454,78 @@ } } ], - "wayHandling": 1 + "wayHandling": 1, + "mapRendering": [ + { + "icon": { + "render": "circle:white;./assets/themes/facadegardens/geveltuin.svg", + "mappings": [ + { + "if": { + "and": [ + "direct_sunlight=yes" + ] + }, + "then": "circle:white;./assets/themes/facadegardens/zon.svg" + }, + { + "if": { + "and": [ + "direct_sunlight=partial" + ] + }, + "then": "circle:white;./assets/themes/facadegardens/halfzon.svg" + }, + { + "if": { + "and": [ + "direct_sunlight=no" + ] + }, + "then": "circle:white;./assets/themes/facadegardens/schaduw.svg" + } + ] + }, + "iconOverlays": [ + { + "if": "plant~.*vine.*", + "then": "circle:white;./assets/themes/facadegardens/klimplant.svg", + "badge": true + }, + { + "if": "plant~.*groundcover.*", + "then": "circle:white;./assets/themes/facadegardens/bodembedekker.svg", + "badge": true + }, + { + "if": "edible=true", + "then": "circle:white;./assets/themes/facadegardens/eetbaar.svg", + "badge": true + }, + { + "if": "rain_barel=yes", + "then": "circle:white;./assets/themes/facadegardens/gevelton.svg", + "badge": true + }, + { + "if": "plant~.*shrub.*", + "then": "circle:white;./assets/themes/facadegardens/struik.svg", + "badge": true + }, + { + "if": "plant~.*flower.*", + "then": "circle:white;./assets/themes/facadegardens/bloei.svg", + "badge": true + } + ], + "iconSize": { + "render": "50,50,center" + }, + "location": [ + "point" + ] + } + ] } ], "roamingRenderings": [] diff --git a/assets/themes/fruit_trees/fruit_trees.json b/assets/themes/fruit_trees/fruit_trees.json index 68ce79228..3af096cf9 100644 --- a/assets/themes/fruit_trees/fruit_trees.json +++ b/assets/themes/fruit_trees/fruit_trees.json @@ -68,6 +68,19 @@ "nl": "Voeg een boomgaard toe (als punt - omtrek nog te tekenen)" } } + ], + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/buurtnatuur/forest.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } ] }, { @@ -170,6 +183,19 @@ "nl": "Voeg hier een boom toe" } } + ], + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/fruit_trees/fruit_tree.svg" + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } ] } ], diff --git a/assets/themes/grb.json b/assets/themes/grb.json index a0f32cdc6..3839c319e 100644 --- a/assets/themes/grb.json +++ b/assets/themes/grb.json @@ -197,7 +197,26 @@ "render": "#00f" }, "wayHandling": 2, - "presets": [] + "presets": [], + "mapRendering": [ + { + "label": { + "mappings": [ + { + "if": "addr:housenumber~*", + "then": "
{addr:housenumber}
" + } + ] + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point", + "centroid" + ] + } + ] } ], "hideFromOverview": true, diff --git a/assets/themes/hackerspaces/hackerspaces.json b/assets/themes/hackerspaces/hackerspaces.json index b2fc74c3a..8744e94c9 100644 --- a/assets/themes/hackerspaces/hackerspaces.json +++ b/assets/themes/hackerspaces/hackerspaces.json @@ -233,7 +233,34 @@ "leisure=hackerspace" ] } - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/hackerspaces/glider.svg", + "mappings": [ + { + "if": { + "and": [ + "hackerspace=makerspace" + ] + }, + "then": { + "en": "./assets/themes/hackerspaces/led.png", + "de": "./assets/themes/hackerspaces/led.png" + } + } + ] + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point", + "centroid" + ] + } + ] } ] } \ No newline at end of file diff --git a/assets/themes/hailhydrant/hailhydrant.json b/assets/themes/hailhydrant/hailhydrant.json index 3a94dbb1b..1481a652f 100644 --- a/assets/themes/hailhydrant/hailhydrant.json +++ b/assets/themes/hailhydrant/hailhydrant.json @@ -316,7 +316,21 @@ } } ], - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/hailhydrant/hydrant.svg" + }, + "iconSize": { + "render": "20,20,center" + }, + "location": [ + "point", + "centroid" + ] + } + ] }, { "id": "extinguisher", @@ -433,7 +447,20 @@ } } ], - "wayHandling": 1 + "wayHandling": 1, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/hailhydrant/Twemoji12_1f9ef.svg" + }, + "iconSize": { + "render": "20,20,center" + }, + "location": [ + "point" + ] + } + ] }, { "id": "fire_stations", @@ -657,6 +684,20 @@ "fr": "Une caserne de pompiers est un lieu où les pompiers et leur équipements sont situés en dehors des missions." } } + ], + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/hailhydrant/Twemoji12_1f692.svg" + }, + "iconSize": { + "render": "35,35,center" + }, + "location": [ + "point", + "centroid" + ] + } ] }, { @@ -858,7 +899,21 @@ } } ], - "wayHandling": 2 + "wayHandling": 2, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/hailhydrant/Twemoji_1f691.svg" + }, + "iconSize": { + "render": "35,35,center" + }, + "location": [ + "point", + "centroid" + ] + } + ] } ], "defaultBackgroundId": "HDM_HOT" diff --git a/assets/themes/natuurpunt/natuurpunt.json b/assets/themes/natuurpunt/natuurpunt.json index ecbe8afe9..fc9bcd4cd 100644 --- a/assets/themes/natuurpunt/natuurpunt.json +++ b/assets/themes/natuurpunt/natuurpunt.json @@ -54,9 +54,13 @@ }, "minzoom": 13, "minzoomVisible": 0, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/nature_reserve.svg" - } + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/nature_reserve.svg" + } + } + ] } }, { @@ -74,9 +78,13 @@ "isOsmCache": "duplicate" }, "minzoom": 1, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/nature_reserve.svg" - }, + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/nature_reserve.svg" + } + } + ], "presets": [] } }, @@ -93,9 +101,13 @@ "isOsmCache": true }, "minzoom": 1, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/information.svg" - } + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/information.svg" + } + } + ] } }, { @@ -112,19 +124,23 @@ "isOsmCache": true }, "minzoom": 10, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/trail.svg", - "mappings": [ - { - "if": "wheelchair=yes", - "then": "circle:#FE6F32;./assets/themes/natuurpunt/walk_wheelchair.svg" - }, - { - "if": "pushchair=yes", - "then": "circle:#FE6F32;./assets/themes/natuurpunt/pushchair.svg" + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/trail.svg", + "mappings": [ + { + "if": "wheelchair=yes", + "then": "circle:#FE6F32;./assets/themes/natuurpunt/walk_wheelchair.svg" + }, + { + "if": "pushchair=yes", + "then": "circle:#FE6F32;./assets/themes/natuurpunt/pushchair.svg" + } + ] } - ] - } + } + ] } }, { @@ -136,19 +152,23 @@ "geoJsonZoomLevel": 12, "isOsmCache": true }, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/toilets.svg", - "mappings": [ - { - "if": "wheelchair=yes", - "then": "circle:#FE6F32;./assets/themes/natuurpunt/wheelchair.svg" - }, - { - "if": "toilets:position=urinals", - "then": "circle:#FE6F32;./assets/themes/natuurpunt/urinal.svg" + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/toilets.svg", + "mappings": [ + { + "if": "wheelchair=yes", + "then": "circle:#FE6F32;./assets/themes/natuurpunt/wheelchair.svg" + }, + { + "if": "toilets:position=urinals", + "then": "circle:#FE6F32;./assets/themes/natuurpunt/urinal.svg" + } + ] } - ] - } + } + ] } }, { @@ -160,10 +180,14 @@ "geoJsonZoomLevel": 12, "isOsmCache": true }, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/birdhide.svg", - "mappings": null - } + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/birdhide.svg", + "mappings": null + } + } + ] } }, { @@ -175,9 +199,13 @@ "geoJsonZoomLevel": 12, "isOsmCache": true }, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/picnic_table.svg" - } + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/picnic_table.svg" + } + } + ] } }, { @@ -189,34 +217,42 @@ "geoJsonZoomLevel": 12, "isOsmCache": true }, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/drips.svg" - } + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/drips.svg" + } + } + ] } }, { "builtin": "parking", "override": { "minzoom": "16", - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/parking.svg", - "mappings": [ - { - "if": "amenity=bicycle_parking", - "then": "circle:#FE6F32;./assets/themes/natuurpunt/parkingbike.svg" - } - ] - }, - "iconOverlays": [ + "mapRendering": [ { - "if": "amenity=motorcycle_parking", - "then": "circle:#335D9F;./assets/themes/natuurpunt/parkingmotor.svg", - "badge": true - }, - { - "if": "capacity:disabled=yes", - "then": "circle:#335D9F;./assets/themes/natuurpunt/parkingwheels.svg", - "badge": true + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/parking.svg", + "mappings": [ + { + "if": "amenity=bicycle_parking", + "then": "circle:#FE6F32;./assets/themes/natuurpunt/parkingbike.svg" + } + ] + }, + "iconOverlays": [ + { + "if": "amenity=motorcycle_parking", + "then": "circle:#335D9F;./assets/themes/natuurpunt/parkingmotor.svg", + "badge": true + }, + { + "if": "capacity:disabled=yes", + "then": "circle:#335D9F;./assets/themes/natuurpunt/parkingwheels.svg", + "badge": true + } + ] } ] } @@ -230,9 +266,13 @@ "geoJsonZoomLevel": 12, "isOsmCache": true }, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/information_board.svg" - } + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/information_board.svg" + } + } + ] } }, { @@ -244,9 +284,13 @@ "geoJsonZoomLevel": 12, "isOsmCache": true }, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/bench.svg" - } + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/bench.svg" + } + } + ] } }, { @@ -258,9 +302,13 @@ "geoJsonZoomLevel": 12, "isOsmCache": true }, - "icon": { - "render": "circle:#FE6F32;./assets/themes/natuurpunt/watermill.svg" - } + "mapRendering": [ + { + "icon": { + "render": "circle:#FE6F32;./assets/themes/natuurpunt/watermill.svg" + } + } + ] } } ], diff --git a/assets/themes/openwindpowermap/openwindpowermap.json b/assets/themes/openwindpowermap/openwindpowermap.json index a437a06bd..10a7859fb 100644 --- a/assets/themes/openwindpowermap/openwindpowermap.json +++ b/assets/themes/openwindpowermap/openwindpowermap.json @@ -227,6 +227,23 @@ } ] } + ], + "mapRendering": [ + { + "icon": "./assets/themes/openwindpowermap/wind_turbine.svg", + "label": { + "mappings": [ + { + "if": "generator:output:electricity~^[0-9]+.*[W]$", + "then": "
{generator:output:electricity}
" + } + ] + }, + "iconSize": "40, 40, bottom", + "location": [ + "point" + ] + } ] } ], diff --git a/assets/themes/postboxes/postboxes.json b/assets/themes/postboxes/postboxes.json index d90c5a1c3..6a881b29a 100644 --- a/assets/themes/postboxes/postboxes.json +++ b/assets/themes/postboxes/postboxes.json @@ -79,7 +79,21 @@ "razed:amenity=post_box" ] } - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/postboxes/postbox.svg" + }, + "iconSize": { + "render": "40,40,bottom" + }, + "location": [ + "point", + "centroid" + ] + } + ] }, { "id": "postoffices", @@ -168,6 +182,27 @@ } ] } + ], + "mapRendering": [ + { + "icon": { + "render": "square:white;./assets/themes/postboxes/post_office.svg" + }, + "iconOverlays": [ + { + "if": "opening_hours~*", + "then": "isOpen", + "badge": true + } + ], + "iconSize": { + "render": "40,40,bottom" + }, + "location": [ + "point", + "centroid" + ] + } ] } ] diff --git a/assets/themes/speelplekken/speelplekken.json b/assets/themes/speelplekken/speelplekken.json index d25d24cf9..702087d8c 100644 --- a/assets/themes/speelplekken/speelplekken.json +++ b/assets/themes/speelplekken/speelplekken.json @@ -36,7 +36,14 @@ "color": "#444444", "width": { "render": "1" - } + }, + "mapRendering": [ + { + "location": [ + "point" + ] + } + ] }, { "builtin": "play_forest", @@ -252,7 +259,15 @@ }, "width": { "render": "9" - } + }, + "mapRendering": [ + { + "icon": "./assets/themes/speelplekken/walking_route.svg", + "location": [ + "point" + ] + } + ] } ], "clustering": { diff --git a/assets/themes/uk_addresses/uk_addresses.json b/assets/themes/uk_addresses/uk_addresses.json index 4a9ab30ab..f334634b3 100644 --- a/assets/themes/uk_addresses/uk_addresses.json +++ b/assets/themes/uk_addresses/uk_addresses.json @@ -108,6 +108,29 @@ } ] } + ], + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/uk_addresses/housenumber_unknown.svg", + "mappings": [ + { + "if": "_embedding_object:id~*", + "then": "./assets/themes/uk_addresses/housenumber_unknown_small.svg" + }, + { + "if": "_imported=yes", + "then": "./assets/themes/uk_addresses/housenumber_unknown_small.svg" + } + ] + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } ] }, { @@ -254,7 +277,36 @@ "then": "#ff0" } ] - } + }, + "mapRendering": [ + { + "icon": { + "render": "./assets/themes/uk_addresses/housenumber_ok.svg", + "mappings": [ + { + "if": { + "or": [ + { + "and": [ + "addr:housenumber=", + "nohousenumber!=yes" + ] + }, + "addr:street=" + ] + }, + "then": "./assets/themes/uk_addresses/housenumber_unknown.svg" + } + ] + }, + "iconSize": { + "render": "40,40,center" + }, + "location": [ + "point" + ] + } + ] }, { "id": "named_streets", @@ -272,7 +324,14 @@ }, "width": { "render": "0" - } + }, + "mapRendering": [ + { + "location": [ + "point" + ] + } + ] } ], "roamingRenderings": [] diff --git a/css/index-tailwind-output.css b/css/index-tailwind-output.css index 63c10a8d0..7ba52d19b 100644 --- a/css/index-tailwind-output.css +++ b/css/index-tailwind-output.css @@ -924,6 +924,10 @@ video { margin-right: 0.75rem; } +.mb-0 { + margin-bottom: 0px; +} + .box-border { box-sizing: border-box; } diff --git a/test/Tag.spec.ts b/test/Tag.spec.ts index 833a7afc5..790d641b5 100644 --- a/test/Tag.spec.ts +++ b/test/Tag.spec.ts @@ -166,7 +166,7 @@ export default class TagSpec extends T { } ], condition: "x=" - }, undefined, "Tests"); + }, "Tests"); equal(undefined, tr.GetRenderValue({"foo": "bar"})); equal("Has no name", tr.GetRenderValue({"noname": "yes"})?.txt); @@ -483,7 +483,7 @@ export default class TagSpec extends T { ] }; - const tagRendering = new TagRenderingConfig(config, null, "test"); + const tagRendering = new TagRenderingConfig(config, "test"); equal(true, tagRendering.IsKnown({bottle: "yes"})) equal(false, tagRendering.IsKnown({})) }],