diff --git a/assets/layers/ambulancestation/ambulancestation.json b/assets/layers/ambulancestation/ambulancestation.json index 0cca6d819a..1a6b1414e5 100644 --- a/assets/layers/ambulancestation/ambulancestation.json +++ b/assets/layers/ambulancestation/ambulancestation.json @@ -1,14 +1,14 @@ { "id": "ambulancestation", "name": { - "en": "Map of ambulance stations", + "en": "Ambulance stations", "ja": "救急ステーションの地図", "ru": "Карта станций скорой помощи", "fr": "Couche des ambulances", "de": "Rettungswachen", "it": "Carta delle stazioni delle ambulanze", "hu": "Mentőállomás-térkép", - "nl": "Kaart van ambulancestations", + "nl": "Ambulancestations", "zh_Hans": "救护车站地图", "id": "Peta stasiun ambulans", "es": "Mapa de estaciones de ambulancias", diff --git a/assets/layers/extinguisher/extinguisher.json b/assets/layers/extinguisher/extinguisher.json index 592753b56e..9fba18de02 100644 --- a/assets/layers/extinguisher/extinguisher.json +++ b/assets/layers/extinguisher/extinguisher.json @@ -1,14 +1,14 @@ { "id": "extinguisher", "name": { - "en": "Map of fire extinguishers", + "en": "Fire extinguishers", "ja": "消火器の地図です。", "nb_NO": "Kart over brannhydranter", "ru": "Карта огнетушителей.", "fr": "Couche des extincteurs", "de": "Feuerlöscher", "it": "Mappa degli estintori", - "nl": "Kaart van brandblussers", + "nl": "Brandblussers", "es": "Mapa de extintores", "ca": "Mapa d'extintors", "pl": "Mapa gaśnic", diff --git a/assets/layers/fire_station/fire_station.json b/assets/layers/fire_station/fire_station.json index f6dec3e432..4cf34e4f82 100644 --- a/assets/layers/fire_station/fire_station.json +++ b/assets/layers/fire_station/fire_station.json @@ -1,14 +1,14 @@ { "id": "fire_station", "name": { - "en": "Map of fire stations", + "en": "Fire stations", "ja": "消防署の地図", "nb_NO": "Kart over brannstasjoner", "it": "Mappa delle caserme dei vigili del fuoco", "ru": "Карта пожарных частей", "fr": "Couche des stations de pompiers", "de": "Feuerwachen", - "nl": "Kaart van de brandweerstations", + "nl": "Brandweerstations", "es": "Mapa de estaciones de bomberos", "ca": "Mapa de parcs de bombers", "cs": "Mapa požárních stanic" diff --git a/assets/layers/hydrant/hydrant.json b/assets/layers/hydrant/hydrant.json index 6ed86cc7c4..a68c44b52e 100644 --- a/assets/layers/hydrant/hydrant.json +++ b/assets/layers/hydrant/hydrant.json @@ -1,7 +1,7 @@ { "id": "hydrant", "name": { - "en": "Map of hydrants", + "en": "Hydrants", "ja": "消火栓の地図", "zh_Hant": "消防栓地圖", "nb_NO": "Kart over brannhydranter", @@ -9,7 +9,7 @@ "fr": "Carte des bornes incendie", "de": "Hydranten", "it": "Mappa degli idranti", - "nl": "Kaart van brandkranen", + "nl": "Brandkranen", "es": "Mapa de bocas de incendio", "ca": "Mapa d'hidrants", "cs": "Mapa hydrantů", diff --git a/assets/layers/questions/questions.json b/assets/layers/questions/questions.json index 4c5f2e3a0e..6ba8076f77 100644 --- a/assets/layers/questions/questions.json +++ b/assets/layers/questions/questions.json @@ -3084,9 +3084,8 @@ "classes": "flex items-center gap-x-2", "render": { "special": { - "type": "qr_code" - }, - "after": { + "type": "qr_code", + "text": { "en": "Scan this code to open this location on another device", "nl": "Scan deze code om deze locatie op een ander apparaat te zien", "de": "QR Code scannen, um diesen Ort auf einem anderen Gerät zu öffnen", @@ -3098,6 +3097,7 @@ "cs": "Naskenováním tohoto kódu otevřete toto umístění na jiném zařízení", "ca": "Escaneja aquest codi per obrir aquesta ubicació en un altre dispositiu", "it": "Scansiona questo codice per aprire questa posizione su un altro dispositivo" + } } } }, diff --git a/assets/layers/usersettings/usersettings.json b/assets/layers/usersettings/usersettings.json index d8e7b7d1b9..41c2c813a0 100644 --- a/assets/layers/usersettings/usersettings.json +++ b/assets/layers/usersettings/usersettings.json @@ -1549,7 +1549,7 @@ "special": { "type": "group", "header": "share-login-group-title", - "labels": "share-login-qr" + "labels": "share-login-content" } } }, @@ -1565,11 +1565,30 @@ { "id": "share-login-qr", "labels": [ - "hidden" + "hidden", + "share-login-content" ], "render": { "special": { - "type": "qr_login" + "type": "qr_login", + "text": "Everyone with this QR-code can act as {_name}", + "textClass": "alert h-fit" + } + } + }, + { + "id": "share-login-revoke", + "labels": [ + "hidden", + "share-login-content" + ], + "render": { + "special": { + "type": "link", + "href": "https://www.openstreetmap.org/oauth2/authorized_applications", + "text": { + "en": "You can revoke access here" + } } } }, diff --git a/assets/themes/mapcomplete-changes/mapcomplete-changes.json b/assets/themes/mapcomplete-changes/mapcomplete-changes.json index 18d93f66a8..a6952adf0c 100644 --- a/assets/themes/mapcomplete-changes/mapcomplete-changes.json +++ b/assets/themes/mapcomplete-changes/mapcomplete-changes.json @@ -10,6 +10,16 @@ "ko": "MapComplete로 이루어진 변경 사항", "it": "Modifiche fatte con MapComplete" }, + "shortDescription": { + "en": "Shows changes made by MapComplete", + "de": "Zeigt die von MapComplete vorgenommenen Änderungen an", + "cs": "Zobrazuje změny provedené nástrojem MapComplete", + "es": "Muestra los cambios realizados por MapComplete", + "fr": "Afficher les modifications faites avec MapComplete", + "nl": "Toont wijzigingen gemaakt met MapComplete", + "ko": "MapComplete를 통해 이루어진 변경 사항을 표시합니다", + "it": "Mostra le modifiche fatte con MapComplete" + }, "description": { "en": "This maps shows all the changes made with MapComplete", "de": "Diese Karte zeigt alle mit MapComplete vorgenommenen Änderungen", @@ -21,18 +31,11 @@ "ko": "이 지도는 MapComplete를 사용하여 이루어진 모든 변경 사항을 표시합니다", "it": "Questa mappa mostra tutte le modifiche effettuate con MapComplete" }, - "shortDescription": { - "en": "Shows changes made by MapComplete", - "de": "Zeigt die von MapComplete vorgenommenen Änderungen an", - "cs": "Zobrazuje změny provedené nástrojem MapComplete", - "es": "Muestra los cambios realizados por MapComplete", - "fr": "Afficher les modifications faites avec MapComplete", - "nl": "Toont wijzigingen gemaakt met MapComplete", - "ko": "MapComplete를 통해 이루어진 변경 사항을 표시합니다", - "it": "Mostra le modifiche fatte con MapComplete" - }, "icon": "./assets/svg/logo.svg", "hideFromOverview": true, + "startLat": 0, + "startLon": 0, + "startZoom": 1, "layers": [ { "id": "mapcomplete-changes", @@ -426,6 +429,14 @@ "if": "theme=healthcare", "then": "./assets/layers/doctors/doctors.svg" }, + { + "if": "theme=historic_aircraft", + "then": "./assets/svg/airport.svg" + }, + { + "if": "theme=historic_rolling_stock", + "then": "./assets/layers/historic_rolling_stock/steam_locomotive.svg" + }, { "if": "theme=hotels", "then": "./assets/layers/tourism_accomodation/hotel.svg" diff --git a/langs/layers/ca.json b/langs/layers/ca.json index e547b7122a..48771cd1fd 100644 --- a/langs/layers/ca.json +++ b/langs/layers/ca.json @@ -9157,7 +9157,7 @@ }, "qr_code": { "render": { - "after": "Escaneja aquest codi per obrir aquesta ubicació en un altre dispositiu" + "text": "Escaneja aquest codi per obrir aquesta ubicació en un altre dispositiu" } }, "repeated": { diff --git a/langs/layers/cs.json b/langs/layers/cs.json index 652b5b2e1f..073ea9ef5b 100644 --- a/langs/layers/cs.json +++ b/langs/layers/cs.json @@ -8406,7 +8406,7 @@ }, "qr_code": { "render": { - "after": "Naskenováním tohoto kódu otevřete toto umístění na jiném zařízení" + "text": "Naskenováním tohoto kódu otevřete toto umístění na jiném zařízení" } }, "repeated": { diff --git a/langs/layers/da.json b/langs/layers/da.json index 758e715ba9..7da7e5f181 100644 --- a/langs/layers/da.json +++ b/langs/layers/da.json @@ -1835,7 +1835,7 @@ }, "qr_code": { "render": { - "after": "Skan denne kode for at åbne dette sted på en anden enhed" + "text": "Skan denne kode for at åbne dette sted på en anden enhed" } }, "service:electricity": { diff --git a/langs/layers/de.json b/langs/layers/de.json index e520d63933..a17fe641e1 100644 --- a/langs/layers/de.json +++ b/langs/layers/de.json @@ -9121,7 +9121,7 @@ }, "qr_code": { "render": { - "after": "QR Code scannen, um diesen Ort auf einem anderen Gerät zu öffnen" + "text": "QR Code scannen, um diesen Ort auf einem anderen Gerät zu öffnen" } }, "repeated": { diff --git a/langs/layers/en.json b/langs/layers/en.json index fb4d67fb59..a4b10a5243 100644 --- a/langs/layers/en.json +++ b/langs/layers/en.json @@ -423,7 +423,7 @@ }, "ambulancestation": { "description": "An ambulance station is an area for storage of ambulance vehicles, medical equipment, personal protective equipment, and other medical supplies.", - "name": "Ambulance stations", + "name": "Ambulance stations", "presets": { "0": { "description": "Add an ambulance station to the map", @@ -2401,6 +2401,20 @@ "Name": { "question": "What is the name of this business?", "render": "This business is named {name}" + }, + "pub_reusable_packaging": { + "mappings": { + "0": { + "then": "Accepts reusable cups" + }, + "1": { + "then": "Does not accept reusable cups" + }, + "2": { + "then": "Only serves to people who bring reusable cups" + } + }, + "question": "Does {title()} accept bring-your-own reusable cups?" } }, "title": { @@ -5511,7 +5525,7 @@ }, "extinguisher": { "description": "Map layer to show fire extinguishers.", - "name": "Fire extinguishers", + "name": "Fire extinguishers", "presets": { "0": { "description": "A fire extinguisher is a small, portable device used to stop a fire", @@ -5703,7 +5717,7 @@ }, "fire_station": { "description": "Map layer to show fire stations.", - "name": "Fire stations", + "name": "Fire stations", "presets": { "0": { "description": "A fire station is a place where the fire trucks and firefighters are located when not in operation.", @@ -6828,6 +6842,10 @@ } }, "question": "Does this also serve as a memorial?" + }, + "model": { + "question": "What is the model of this rolling stock?", + "render": "Model {model}" } }, "title": { @@ -6880,7 +6898,7 @@ }, "hydrant": { "description": "Map layer to show fire hydrants.", - "name": "Hydrants", + "name": "Hydrants", "presets": { "0": { "description": "A hydrant is a connection point where firefighters can tap water. It might be located underground.", @@ -9692,7 +9710,7 @@ }, "qr_code": { "render": { - "after": "Scan this code to open this location on another device" + "text": "Scan this code to open this location on another device" } }, "ref": { @@ -13833,6 +13851,15 @@ } } }, + "share-login-explanation": { + "render": "With the below QR-code, you can login on another device without having to share your password" + }, + "share-login-group-title": { + "render": "Allow to log in and act as {_name}" + }, + "share-login-title": { + "render": "

Login via QR code

" + }, "show_crosshair": { "mappings": { "0": { @@ -14763,4 +14790,4 @@ "render": "wind turbine" } } -} +} \ No newline at end of file diff --git a/langs/layers/es.json b/langs/layers/es.json index 9605f131b2..1220dfbf81 100644 --- a/langs/layers/es.json +++ b/langs/layers/es.json @@ -8733,7 +8733,7 @@ }, "qr_code": { "render": { - "after": "Escanea este código para abrir esta ubicación en otro dispositivo" + "text": "Escanea este código para abrir esta ubicación en otro dispositivo" } }, "repeated": { diff --git a/langs/layers/hu.json b/langs/layers/hu.json index e1865e8597..335c18606a 100644 --- a/langs/layers/hu.json +++ b/langs/layers/hu.json @@ -944,7 +944,7 @@ }, "qr_code": { "render": { - "after": "Szkenneld be ezt a kódot, hogy egy másik eszközön is meg tudd nyitni a helyet" + "text": "Szkenneld be ezt a kódot, hogy egy másik eszközön is meg tudd nyitni a helyet" } }, "service:electricity": { diff --git a/langs/layers/it.json b/langs/layers/it.json index f9dcd1f653..bd5d244f2c 100644 --- a/langs/layers/it.json +++ b/langs/layers/it.json @@ -9609,7 +9609,7 @@ }, "qr_code": { "render": { - "after": "Scansiona questo codice per aprire questa posizione su un altro dispositivo" + "text": "Scansiona questo codice per aprire questa posizione su un altro dispositivo" } }, "repeated": { diff --git a/langs/layers/nl.json b/langs/layers/nl.json index 567db56ce9..5b4ad76f7d 100644 --- a/langs/layers/nl.json +++ b/langs/layers/nl.json @@ -409,7 +409,7 @@ }, "ambulancestation": { "description": "Een ambulancestation is een plaats waar ambulances, medisch materiaal, persoonlijk beschermingsmateriaal en aanverwanten worden bewaard.", - "name": "Ambulancestations", + "name": "Ambulancestations", "presets": { "0": { "description": "Voeg een ambulancestation toe aan de kaart", @@ -5140,7 +5140,7 @@ }, "extinguisher": { "description": "Kaartlaag met brandblussers.", - "name": "Brandblussers", + "name": "Brandblussers", "presets": { "0": { "description": "Een brandblusser is een klein, draagbaar apparaat om een brand te blussen", @@ -5269,7 +5269,7 @@ }, "fire_station": { "description": "Kaartlaag die de brandweerstations toont.", - "name": "Brandweerstations", + "name": "Brandweerstations", "presets": { "0": { "description": "Een brandweerstation is een plaats waar brandweerwagens en brandweerlieden gebaseerd zijn.", @@ -6010,7 +6010,7 @@ }, "hydrant": { "description": "Kaartlaag met brandkranen.", - "name": "Brandkranen", + "name": "Brandkranen", "presets": { "0": { "description": "Een brandkraan is een kraan waar brandweerlieden een brandslang kunnen aansluiten. Soms zit deze ondergronds.", @@ -8183,7 +8183,7 @@ }, "qr_code": { "render": { - "after": "Scan deze code om deze locatie op een ander apparaat te zien" + "text": "Scan deze code om deze locatie op een ander apparaat te zien" } }, "repeated": { @@ -11638,4 +11638,4 @@ "render": "windturbine" } } -} +} \ No newline at end of file diff --git a/langs/layers/sl.json b/langs/layers/sl.json index 7c7b1b751b..81995b125f 100644 --- a/langs/layers/sl.json +++ b/langs/layers/sl.json @@ -239,7 +239,7 @@ }, "qr_code": { "render": { - "after": "Skenirajte to kodo, da odprete ta kraj na drugi napravi" + "text": "Skenirajte to kodo, da odprete ta kraj na drugi napravi" } }, "single_level": { diff --git a/langs/layers/uk.json b/langs/layers/uk.json index 2975bcd8c6..bd8fb4ca77 100644 --- a/langs/layers/uk.json +++ b/langs/layers/uk.json @@ -1919,7 +1919,7 @@ }, "qr_code": { "render": { - "after": "Відскануйте цей код, щоб відкрити це місце на іншому пристрої" + "text": "Відскануйте цей код, щоб відкрити це місце на іншому пристрої" } }, "share": { diff --git a/src/UI/Popup/QrCode.svelte b/src/UI/Popup/QrCode.svelte index e6d02fd870..f8fd21f891 100644 --- a/src/UI/Popup/QrCode.svelte +++ b/src/UI/Popup/QrCode.svelte @@ -1,19 +1,20 @@ {#if $id?.startsWith("node/-")} {:else} - + toggleSize()} src={new Qr($url).toImageElement($size)} style={`width: ${$size}px; height: ${$size}px`} /> + {#if sideText} +
{ $sideTextSub}
+ {/if} + {/if} diff --git a/src/UI/SpecialVisualisations/SettingsVisualisations.ts b/src/UI/SpecialVisualisations/SettingsVisualisations.ts index 183dd7ef0a..26f3fea791 100644 --- a/src/UI/SpecialVisualisations/SettingsVisualisations.ts +++ b/src/UI/SpecialVisualisations/SettingsVisualisations.ts @@ -151,15 +151,23 @@ export class SettingsVisualisations { }, { funcName: "qr_login", - args: [], + args: [{ + name: "text", + doc: "Extra text on the side of the QR-code" + }, { + name: "textClass", + doc: "CSS class of the the side text" + }], docs: "A QR-code which shares the current URL and adds the login token. Anyone with this login token will have the same permissions as you currently have. Logging out from this session will also log them out", group: "settings", constr(state: SpecialVisualizationState, tags: UIEventSource>, argument: string[], feature: Feature, layer: LayerConfig): SvelteUIElement { const shared_oauth_cookie = state.osmConnection.getToken() + const sideText = argument[0] + const sideTextClass = argument[1] ?? "" return new SvelteUIElement(QrCode, { state, tags, - feature, + sideText, sideTextClass, extraUrlParams: { shared_oauth_cookie } }) } diff --git a/src/UI/SpecialVisualisations/UISpecialVisualisations.ts b/src/UI/SpecialVisualisations/UISpecialVisualisations.ts index 1414c27325..4dc248b09d 100644 --- a/src/UI/SpecialVisualisations/UISpecialVisualisations.ts +++ b/src/UI/SpecialVisualisations/UISpecialVisualisations.ts @@ -174,7 +174,13 @@ export class UISpecialVisualisations { }, { funcName: "qr_code", - args: [], + args: [{ + name: "text", + doc: "Extra text on the side of the QR-code" + }, { + name: "textClass", + doc: "CSS class of the the side text" + }], group: "default", docs: "Generates a QR-code to share the selected object", constr( @@ -183,7 +189,9 @@ export class UISpecialVisualisations { argument: string[], feature: Feature ): SvelteUIElement { - return new SvelteUIElement(QrCode, { state, tags, feature }) + const sideText = argument[0] + const sideTextClass = argument[1] ?? "" + return new SvelteUIElement(QrCode, { state, tags, feature, sideText, sideTextClass }) }, }, {