Streamline hotkeys

This commit is contained in:
Pieter Vander Vennet 2023-12-09 15:28:11 +01:00
parent d9b084f7d9
commit df01b1683a
5 changed files with 574 additions and 386 deletions

View file

@ -460,7 +460,8 @@
"if": "surface=fine_gravel",
"then": {
"en": "The surface is <b>fine gravel</b>",
"nl": "De ondergrond bestaat uit <b>grind</b>"
"nl": "De ondergrond bestaat uit <b>grind</b>",
"de": "Die Oberfläche ist <b>feiner Kies</b>"
}
}
],

View file

@ -1,13 +1,33 @@
{
"id": "mapcomplete-changes",
"title": {
"en": "Changes made with MapComplete"
"en": "Changes made with MapComplete",
"ca": "Canvis fets amb MapComplete",
"cs": "Změny provedené pomocí MapComplete",
"de": "Mit MapComplete erstellte Änderungen",
"es": "Cambios realizados con MapComplete",
"fr": "Changements faits avec MapComplete",
"nl": "Wijzigingen gemaakt met MapComplete",
"pl": "Zmiany wprowadzone za pomocą MapComplete"
},
"shortDescription": {
"en": "Shows changes made by MapComplete"
"en": "Show changes made with MapComplete",
"ca": "Mostra els canvis fets amb MapComplete",
"cs": "Zobrazení změn provedených pomocí nástroje MapComplete",
"de": "Mit MapComplete erstellte Änderungen anzeigen",
"es": "Mostrar cambios realizados con MapComplete",
"nl": "Toon wijzigingen gemaakt met MapComplete",
"pl": "Pokaż zmiany wprowadzone za pomocą MapComplete"
},
"description": {
"en": "This maps shows all the changes made with MapComplete"
"en": "This maps shows all the changes made with MapComplete",
"ca": "Aquest mapa mostra tots els canvis fets amb MapComplete",
"cs": "Tato mapa zobrazuje všechny změny provedené pomocí MapComplete",
"de": "Diese Karte zeigt alle mit MapComplete vorgenommenen Änderungen",
"es": "Este mapa muestra todos los cambios realizados con MapComplete",
"fr": "Cette carte montre tous les changements faits avec MapComplete",
"nl": "Deze kaart toont alle wijzigingen die met MapComplete gemaakt werden",
"pl": "Ta mapa pokazuje wszystkie zmiany wprowadzone za pomocą MapComplete"
},
"icon": "./assets/svg/logo.svg",
"hideFromOverview": true,
@ -20,7 +40,13 @@
{
"id": "mapcomplete-changes",
"name": {
"en": "Changeset centers"
"en": "Changeset centers",
"ca": "Centre del conjunt de canvis",
"cs": "Centrum změn",
"de": "Zentrum der Änderungssätze",
"es": "Centro del conjunto de cambios",
"nl": "Centerpunt van changeset",
"pl": "Centra zmian"
},
"minzoom": 0,
"source": {
@ -31,41 +57,85 @@
},
"title": {
"render": {
"en": "Changeset for {theme}"
"en": "Changeset for {theme}",
"ca": "Conjunt de canvis per a {theme}",
"cs": "Změna pro {theme}",
"de": "Änderungssatz für {theme}",
"es": "Conjunto de cambios para {theme}",
"fr": "Groupe de modifications pour {theme}",
"pl": "Zestaw zmian dla {theme}"
}
},
"description": {
"en": "Shows all MapComplete changes"
"en": "Show all MapComplete changes",
"ca": "Mostra tots els canvis de MapComplete",
"cs": "Zobrazit všechny změny MapComplete",
"de": "Alle MapComplete-Änderungen anzeigen",
"es": "Mostrar todos los cambios de MapComplete",
"nl": "Toon alle MapComplete wijzigingen",
"pl": "Wyświetl wszystkie zmiany MapComplete"
},
"tagRenderings": [
{
"id": "show_changeset_id",
"render": {
"en": "Changeset <a href='https://openstreetmap.org/changeset/{id}' target='_blank'>{id}</a>"
"en": "Changeset <a href='https://openstreetmap.org/changeset/{id}' target='_blank'>{id}</a>",
"ca": "Conjunt de canvi <a href='https://openstreetmap.org/changeset/{id}' target='_blank'>{id}</a>",
"cs": "Změny <a href='https://openstreetmap.org/changeset/{id}' target='_blank'>{id}</a>",
"de": "Änderungssatz <a href='https://openstreetmap.org/changeset/{id}' target='_blank'>{id}</a>",
"es": "Conjunto de cambios <a href='https://openstreetmap.org/changeset/{id}' target='_blank'>{id}</a>",
"fr": "Groupe de modifications <a href='https://openstreetmap.org/changeset/{id}' target='_blank'>{id}</a>",
"pl": "Zestaw zmian <a href='https://openstreetmap.org/changeset/{id}' target='_blank'>{id}</a>"
}
},
{
"id": "contributor",
"question": {
"en": "What contributor did make this change?"
"en": "Which contributor made this change?",
"ca": "Quin col·laborador va fer aquest canvi?",
"cs": "Který přispěvatel tuto změnu provedl?",
"de": "Wer hat diese Änderung vorgenommen?",
"es": "¿Qué contribuidor hizo este cambio?",
"fr": "Quel contributeur a fait cette modification ?",
"nl": "Welke bijdrager maakte deze wijziging?",
"pl": "Który współautor dokonał tej zmiany?"
},
"freeform": {
"key": "user"
},
"render": {
"en": "Change made by <a href='https://openstreetmap.org/user/{user}' target='_blank'>{user}</a>"
"en": "Change made by <a href='https://openstreetmap.org/user/{user}' target='_blank'>{user}</a>",
"ca": "Canvi fet per <a href='https://openstreetmap.org/user/{user}' target='_blank'>{user}</a>",
"cs": "Změna provedená <a href='https://openstreetmap.org/user/{user}' target='_blank'>{user}</a>",
"de": "Änderung von <a href='https://openstreetmap.org/user/{user}' target='_blank'>{user}</a>",
"es": "Cambio realizado por <a href='https://openstreetmap.org/user/{user}' target='_blank'>{user}</a>",
"fr": "Modification faite par <a href='https://openstreetmap.org/user/{user}' target='_blank'>{user}</a>",
"nl": "Wijziging gemaakt door <a href='https://openstreetmap.org/user/{user}' target='_blank'>{user}</a>",
"pl": "Zmiana dokonana przez <a href='https://openstreetmap.org/user/{user}' target='_blank'>{user}</a>"
}
},
{
"id": "theme-id",
"question": {
"en": "What theme was used to make this change?"
"en": "What theme was used to make this change?",
"ca": "Quin tema es va utilitzar per fer aquest canvi?",
"cs": "Jaké téma bylo použito k provedení této změny?",
"de": "Welches Thema wurde für diese Änderung verwendet?",
"es": "¿Qué tema se utilizó para realizar este cambio?",
"fr": "Quel thème a été utilisé pour faire cette modification ?",
"pl": "Jakiego tematu użyto do wprowadzenia tej zmiany?"
},
"freeform": {
"key": "theme"
},
"render": {
"en": "Change with theme <a href='https://mapcomplete.org/{theme}'>{theme}</a>"
"en": "Change with theme <a href='https://mapcomplete.osm.be/{theme}'>{theme}</a>",
"ca": "Canvi amb el tema <a href='https://mapcomplete.osm.be/{theme}'>{theme}</a>",
"cs": "Změna s motivem <a href='https://mapcomplete.osm.be/{theme}'>{theme}</a>",
"de": "Geändert mit Thema <a href='https://mapcomplete.osm.be/{theme}'>{theme}</a>",
"es": "Cambio con tema <a href='https://mapcomplete.osm.be/{theme}'>{theme}</a>",
"fr": "Modifié avec le thème <a href='https://mapcomplete.osm.be/{theme}'>{theme}</a>",
"pl": "Zmiana za pomocą motywu <a href='https://mapcomplete.osm.be/{theme}'>{theme}</a>"
}
},
{
@ -74,19 +144,45 @@
"key": "locale"
},
"question": {
"en": "What locale (language) was this change made in?"
"en": "What locale (language) was this change made in?",
"ca": "Amb quina configuració regional (idioma) s'ha fet aquest canvi?",
"cs": "V jakém národním prostředí (jazyce) byla tato změna provedena?",
"de": "In welcher Benutzersprache wurde diese Änderung vorgenommen?",
"es": "¿En qué configuración regional (idioma) se realizó este cambio?",
"fr": "En quelle langue est-ce que ce changement a été fait ?",
"nl": "In welke locale (taal) werd deze wijziging gemaakt?",
"pl": "W jakim języku wprowadzono tę zmianę?"
},
"render": {
"en": "User locale is {locale}"
"en": "User locale is {locale}",
"ca": "La configuració regional de l'usuari és {locale}",
"cs": "Uživatelské prostředí je {locale}",
"de": "Benutzersprache {locale}",
"es": "La configuración regional del usuario es {locale}",
"nl": "De gebruikerstaal is {locale}",
"pl": "Ustawienia regionalne użytkownika to {locale}"
}
},
{
"id": "host",
"render": {
"en": "Change with with <a href='{host}'>{host}</a>"
"en": "Change made with <a href='{host}'>{host}</a>",
"ca": "Canviat fet amb <a href='{host}'>{host}</a>",
"cs": "Změna provedená pomocí <a href='{host}'>{host}</a>",
"de": "Geändert über <a href='{host}'>{host}</a>",
"es": "Cambio realizado con <a href='{host}'>{host}</a>",
"fr": "Modification faite avec <a href='{host}'>{host}</a>",
"nl": "Wijziging gemaakt met <a href='{host}'>{host}</a>",
"pl": "Zmiana dokonana w <a href='{host}'>{host}</a>"
},
"question": {
"en": "What host (website) was this change made with?"
"en": "What host (website) was this change made with?",
"ca": "Amb quin amfitrió (lloc web) es va fer aquest canvi?",
"cs": "U jakého hostitele (webové stránky) byla tato změna provedena?",
"de": "Über welchen Host (Webseite) wurde diese Änderung vorgenommen?",
"es": "¿Con qué host (página web) se realizó este cambio?",
"nl": "Met welke host (website) werd deze wijziging gemaakt?",
"pl": "Na jakim hoście (stronie internetowej) dokonano tej zmiany?"
},
"freeform": {
"key": "host"
@ -107,10 +203,22 @@
{
"id": "version",
"question": {
"en": "What version of MapComplete was used to make this change?"
"en": "What version of MapComplete was used to make this change?",
"ca": "Quina versió de MapComplete es va utilitzar per fer aquest canvi?",
"cs": "Jaká verze aplikace MapComplete byla použita k provedení této změny?",
"de": "Mit welcher Version von MapComplete wurde diese Änderung gemacht?",
"es": "¿Qué versión de MapComplete se usó para realizar este cambio?",
"fr": "Quelle version de MapComplete a été utilisée pour faire cette modification ?",
"pl": "Która wersja MapComplete została wykorzystana, aby zrobić tę zmianę?"
},
"render": {
"en": "Made with {editor}"
"en": "Made with {editor}",
"ca": "Fet amb {editor}",
"cs": "Vyrobeno pomocí {editor}",
"de": "Erstellt mit {editor}",
"es": "Realizado con {editor}",
"fr": "Fait avec {editor}",
"pl": "Zrobione za pomocą {editor}"
},
"freeform": {
"key": "editor"
@ -460,7 +568,13 @@
}
],
"question": {
"en": "Themename contains {search}"
"en": "Theme name contains {search}",
"ca": "El nom del tema conté {search}",
"cs": "Název motivu obsahuje {search}",
"de": "Themenname enthält {search}",
"es": "El nombre del tema contiene {search}",
"nl": "Themenaam bevat {search}",
"pl": "Nazwa tematu zawiera {search}"
}
}
]
@ -476,7 +590,7 @@
}
],
"question": {
"en": "Themename does <b>not</b> contain {search}"
"en": "Theme name does <b>not</b> contain {search}"
}
}
]
@ -492,7 +606,13 @@
}
],
"question": {
"en": "Made by contributor {search}"
"en": "Made by contributor {search}",
"ca": "Fet pel col·laborador {search}",
"cs": "Vytvořil přispěvatel {search}",
"de": "Erstellt von {search}",
"es": "Hecho por el colaborador {search}",
"nl": "Gemaakt door bijdrager {search}",
"pl": "Wykonane przez współautora {search}"
}
}
]
@ -508,7 +628,13 @@
}
],
"question": {
"en": "<b>Not</b> made by contributor {search}"
"en": "<b>Not</b> made by contributor {search}",
"ca": "<b>No</b> fet pel col·laborador {search}",
"cs": "<b>Není</b> vytvořeno přispěvatelem {search}",
"de": "<b>Nicht</b> erstellt von {search}",
"es": "<b>No</b> hecho por el colaborador {search}",
"nl": "<b>Niet</b> gemaakt door bijdrager {search}",
"pl": "<b>Nie</b> wykonane przez współautora {search}"
}
}
]
@ -525,7 +651,13 @@
}
],
"question": {
"en": "Made before {search}"
"en": "Made before {search}",
"ca": "Fet abans de {search}",
"cs": "Vytvořeno před {search}",
"de": "Erstellt vor {search}",
"es": "Hecho antes de {search}",
"nl": "Gemaakt voor {search}",
"pl": "Stworzone przed {search}"
}
}
]
@ -542,7 +674,13 @@
}
],
"question": {
"en": "Made after {search}"
"en": "Made after {search}",
"ca": "Fet després de {search}",
"cs": "Vytvořeno po {search}",
"de": "Erstellt nach {search}",
"es": "Hecho después de {search}",
"nl": "Gemaakt na {search}",
"pl": "Stworzone po {search}"
}
}
]
@ -558,7 +696,14 @@
}
],
"question": {
"en": "User language (iso-code) {search}"
"en": "User language (iso-code) {search}",
"ca": "Idioma de l'usuari (codi iso) {search}",
"cs": "Jazyk uživatele (iso-kód) {search}",
"de": "Benutzersprache (ISO-Code) {search}",
"es": "Use idioma (ISO-code) {search}",
"fr": "Langage utilisateur (code-ISO) {search}",
"nl": "De taal van de bijdrager is {search}",
"pl": "Język użytkownika (kod iso) {search}"
}
}
]
@ -574,7 +719,13 @@
}
],
"question": {
"en": "Made with host {search}"
"en": "Made with host {search}",
"ca": "Fet amb l'amfitrió {search}",
"cs": "Vytvořeno pomocí hostitele {search}",
"de": "Erstellt mit Host {search}",
"es": "Hecho con el host {search}",
"nl": "Gemaakt met host {search}",
"pl": "Wykonane z hostem {search}"
}
}
]
@ -585,7 +736,14 @@
{
"osmTags": "add-image>0",
"question": {
"en": "Changeset added at least one image"
"en": "Changeset added at least one image",
"ca": "El conjunt de canvis ha afegit almenys una imatge",
"cs": "Sada změn přidala alespoň jeden obrázek",
"de": "Im Änderungssatz wurde mindestens ein Bild hinzugefügt",
"es": "El conjunto de cambios ha añadido al menos una imagen",
"fr": "Le groupe de modifications a ajouté au moins une image",
"nl": "Changeset bevat minstens één afbeelding",
"pl": "Zestaw zmian dodał co najmniej jedno zdjęcie"
}
}
]
@ -596,7 +754,7 @@
{
"osmTags": "theme!=grb",
"question": {
"en": "Exclude GRB theme"
"en": "Made with host {search}"
}
}
]
@ -607,7 +765,7 @@
{
"osmTags": "theme!=etymology",
"question": {
"en": "Exclude etymology theme"
"en": "Changeset added at least one image"
}
}
]
@ -622,7 +780,13 @@
{
"id": "link_to_more",
"render": {
"en": "More statistics can be found <a href='https://github.com/pietervdvn/MapComplete/tree/develop/Docs/Tools/graphs' target='_blank'>here</a>"
"en": "More statistics can be found <a href='https://github.com/pietervdvn/MapComplete/tree/develop/Docs/Tools/graphs' target='_blank'>here</a>",
"ca": "Es pot trobar més estadística <a href='https://github.com/pietervdvn/MapComplete/tree/develop/Docs/Tools/graphs' target='_blank'>aquí</a>",
"cs": "Další statistiky najdete <a href='https://github.com/pietervdvn/MapComplete/tree/develop/Docs/Tools/graphs' target='_blank'>here</a>",
"de": "Mehr Statistiken gibt es <a href='https://github.com/pietervdvn/MapComplete/tree/develop/Docs/Tools/graphs' target='_blank'>hier</a>",
"es": "Puede encontrar más estadísticas <a href='https://github.com/pietervdvn/MapComplete/tree/develop/Docs/Tools/graphs' target='_blank'>aquí</a>",
"fr": "D'autres statistiques sont disponibles <a href='https://github.com/pietervdvn/MapComplete/tree/develop/Docs/Tools/graphs' target='_blank'>ici</a>",
"pl": "Więcej statystyk można znaleźć <a href='https://github.com/pietervdvn/MapComplete/tree/develop/Docs/Tools/graphs' target='_blank'>tutaj</a>"
}
},
{

View file

@ -418,10 +418,14 @@
"geolocate": "Pan the map to the current location or zoom the map to the current location. Requests geopermission",
"intro": "MapComplete supports the following keys:",
"key": "Key combination",
"openLayersPanel": "Opens the layers and filters panel",
"openFilterPanel": "Opens the POI-layers and filter panel",
"openLayersPanel": "Opens the background layers panel",
"selectAerial": "Set the background to aerial or satellite imagery. Toggles between the two best, available layers",
"selectFavourites": "Open the favourites page",
"selectItem": "Select the POI which is closest to the map center (crosshair). Only when in keyboard navigation is used",
"selectItem2": "Select the POI which is second closest element to the map center (crosshair). Only when in keyboard navigation is used",
"selectItem3": "Select the POI which is third closest element to the map center (crosshair). Only when in keyboard navigation is used",
"selectItemI": "Select the POI which is the {i}th closest element to the map center (crosshair). Only when in keyboard navigation is used",
"selectMap": "Set the background to a map from external sources. Toggles between the two best, available layers",
"selectMapnik": "Set the background layer to OpenStreetMap-carto",
"selectOsmbasedmap": "Set the background layer to on OpenStreetMap-based map (or disable the background raster layer)",

File diff suppressed because it is too large Load diff

View file

@ -512,12 +512,20 @@ export default class ThemeViewState implements SpecialVisualizationState {
() => this.selectClosestAtCenter(0)
)
for (let i = 1; i < 9; i++) {
let doc = Translations.t.hotkeyDocumentation.selectItemI.Subs({ i })
if (i === 1) {
doc = Translations.t.hotkeyDocumentation.selectItem
} else if (i === 2) {
doc = Translations.t.hotkeyDocumentation.selectItem2
} else if (i === 3) {
doc = Translations.t.hotkeyDocumentation.selectItem3
}
Hotkeys.RegisterHotkey(
{
nomod: "" + i,
onUp: true,
},
Translations.t.hotkeyDocumentation.selectItem,
doc,
() => this.selectClosestAtCenter(i - 1)
)
}
@ -533,6 +541,17 @@ export default class ThemeViewState implements SpecialVisualizationState {
nomod: "b",
},
Translations.t.hotkeyDocumentation.openLayersPanel,
() => {
if (this.featureSwitches.featureSwitchBackgroundSelection.data) {
this.guistate.backgroundLayerSelectionIsOpened.setData(true)
}
}
)
Hotkeys.RegisterHotkey(
{
nomod: "s",
},
Translations.t.hotkeyDocumentation.openFilterPanel,
() => {
if (this.featureSwitches.featureSwitchFilter.data) {
this.guistate.openFilterView()