UI(basemap): add language support: labels now show in the selected language

This commit is contained in:
Pieter Vander Vennet 2025-02-24 16:49:40 +01:00
parent 4d40200d47
commit 304e15ac2b
7 changed files with 5458 additions and 45 deletions

View file

@ -30,6 +30,47 @@
"fill-color": "#fcf7e5"
}
},
{
"id": "landcover_low_zooms",
"type": "fill",
"source": "protomaps",
"source-layer": "landcover",
"paint": {
"fill-color": [
"match",
[
"get",
"kind"
],
"grassland",
"#e5f2c9",
"barren",
"rgba(255, 243, 215, 1)",
"urban_area",
"rgba(230, 230, 230, 1)",
"farmland",
"rgba(216, 239, 210, 1)",
"glacier",
"rgba(255, 255, 255, 1)",
"scrub",
"rgba(234, 239, 210, 1)",
"#f0efdd"
],
"fill-opacity": [
"interpolate",
[
"linear"
],
[
"zoom"
],
5,
1,
7,
0
]
}
},
{
"id": "landuse_farmland",
"type": "fill",
@ -70,16 +111,13 @@
"source": "protomaps",
"source-layer": "landuse",
"filter": [
"any",
[
"in",
"kind",
"national_park",
"park",
"cemetery",
"nature_reserve",
"golf_course"
]
"in",
"kind",
"national_park",
"park",
"cemetery",
"nature_reserve",
"golf_course"
],
"paint": {
"fill-color": [

View file

@ -109,15 +109,14 @@
"type": "fill",
"source": "protomaps",
"source-layer": "landuse",
"filter":
[
"in",
"kind",
"national_park",
"park",
"cemetery",
"nature_reserve",
"golf_course"
"filter": [
"in",
"kind",
"national_park",
"park",
"cemetery",
"nature_reserve",
"golf_course"
],
"paint": {
"fill-color": [
@ -3010,19 +3009,16 @@
}
},
{
"id": "physical_line_waterway_label",
"id": "water_waterway_label",
"type": "symbol",
"source": "protomaps",
"source-layer": "physical_line",
"source-layer": "water",
"minzoom": 13,
"filter": [
"all",
[
"in",
"kind",
"river",
"stream"
]
"in",
"kind",
"river",
"stream"
],
"layout": {
"symbol-placement": "line",
@ -3120,10 +3116,10 @@
}
},
{
"id": "pois_ocean",
"id": "water_label_ocean",
"type": "symbol",
"source": "protomaps",
"source-layer": "pois",
"source-layer": "water",
"filter": [
"any",
[
@ -3168,7 +3164,7 @@
}
},
{
"id": "pois_lakes",
"id": "water_label_lakes",
"type": "symbol",
"source": "protomaps",
"source-layer": "water",
@ -3313,7 +3309,7 @@
}
},
{
"id": "pois_important",
"id": "pois",
"type": "symbol",
"source": "protomaps",
"source-layer": "pois",