diff --git a/UI/BigComponents/Attribution.ts b/UI/BigComponents/Attribution.ts index 3b60134f2..d1f7bb497 100644 --- a/UI/BigComponents/Attribution.ts +++ b/UI/BigComponents/Attribution.ts @@ -9,6 +9,7 @@ import { VariableUiElement } from "../Base/VariableUIElement" import LayoutConfig from "../../Models/ThemeConfig/LayoutConfig" import { BBox } from "../../Logic/BBox" import { Utils } from "../../Utils" +import Translations from "../i18n/Translations" /** * The bottom right attribution panel in the leaflet map @@ -58,7 +59,13 @@ export default class Attribution extends Combine { true ) - let editWithJosm = new VariableUiElement( + const mapDataByOsm = new Link( + Translations.t.general.attribution.mapDataByOsm, + "https://openstreetmap.org/copyright", + true + ) + + const editWithJosm = new VariableUiElement( userDetails.map( (userDetails) => { if (userDetails.csCount < Constants.userJourney.tagsVisibleAndWikiLinked) { @@ -79,7 +86,7 @@ export default class Attribution extends Combine { [location, currentBounds] ) ) - super([mapComplete, reportBug, stats, editHere, editWithJosm, mapillary]) + super([mapComplete, reportBug, stats, editHere, editWithJosm, mapillary, mapDataByOsm]) this.SetClass("flex") } } diff --git a/UI/BigComponents/CopyrightPanel.ts b/UI/BigComponents/CopyrightPanel.ts index 83dad07db..2cdadec7e 100644 --- a/UI/BigComponents/CopyrightPanel.ts +++ b/UI/BigComponents/CopyrightPanel.ts @@ -2,13 +2,13 @@ import Combine from "../Base/Combine" import Translations from "../i18n/Translations" import { Store, UIEventSource } from "../../Logic/UIEventSource" import { FixedUiElement } from "../Base/FixedUiElement" -import * as licenses from "../../assets/generated/license_info.json" +import licenses from "../../assets/generated/license_info.json" import SmallLicense from "../../Models/smallLicense" import { Utils } from "../../Utils" import Link from "../Base/Link" import { VariableUiElement } from "../Base/VariableUIElement" -import * as contributors from "../../assets/contributors.json" -import * as translators from "../../assets/translators.json" +import contributors from "../../assets/contributors.json" +import translators from "../../assets/translators.json" import BaseUIElement from "../BaseUIElement" import LayoutConfig from "../../Models/ThemeConfig/LayoutConfig" import Title from "../Base/Title" diff --git a/UI/BigComponents/FullWelcomePaneWithTabs.ts b/UI/BigComponents/FullWelcomePaneWithTabs.ts index e54b2e29a..5637a05d1 100644 --- a/UI/BigComponents/FullWelcomePaneWithTabs.ts +++ b/UI/BigComponents/FullWelcomePaneWithTabs.ts @@ -85,15 +85,6 @@ export default class FullWelcomePaneWithTabs extends ScrollableFullScreen { tabs.push({ header: Svg.share_img, content: new ShareScreen(state) }) } - const copyright = { - header: Svg.copyright_svg(), - content: new Combine([ - Translations.t.general.openStreetMapIntro.SetClass("link-underline"), - new CopyrightPanel(state), - ]), - } - tabs.push(copyright) - const privacy = { header: Svg.eye_svg(), content: new PrivacyPolicy(), diff --git a/UI/BigComponents/LeftControls.ts b/UI/BigComponents/LeftControls.ts index a75daabd2..9a342c0ba 100644 --- a/UI/BigComponents/LeftControls.ts +++ b/UI/BigComponents/LeftControls.ts @@ -105,24 +105,7 @@ export default class LeftControls extends Combine { state.featureSwitchBackgroundSelection ) - // If the welcomeMessage is disabled, the copyright is hidden (as that is where the copyright is located - const copyright = new Toggle( - undefined, - new Lazy(() => { - new ScrollableFullScreen( - () => Translations.t.general.attribution.attributionTitle, - () => new CopyrightPanel(state), - "copyright", - guiState.copyrightViewIsOpened - ) - return new MapControlButton(Svg.copyright_svg()).onClick(() => - guiState.copyrightViewIsOpened.setData(true) - ) - }), - state.featureSwitchWelcomeMessage - ) - - super([currentViewAction, filterButton, downloadButton, copyright, mapSwitch]) + super([currentViewAction, filterButton, downloadButton, mapSwitch]) this.SetClass("flex flex-col") } diff --git a/UI/DefaultGUI.ts b/UI/DefaultGUI.ts index d368d0cab..5aa832043 100644 --- a/UI/DefaultGUI.ts +++ b/UI/DefaultGUI.ts @@ -33,6 +33,8 @@ import GeoLocationHandler from "../Logic/Actors/GeoLocationHandler" import { GeoLocationState } from "../Logic/State/GeoLocationState" import Hotkeys from "./Base/Hotkeys" import AvailableBaseLayers from "../Logic/Actors/AvailableBaseLayers" +import Lazy from "./Base/Lazy" +import CopyrightPanel from "./BigComponents/CopyrightPanel" /** * The default MapComplete GUI initializer @@ -239,7 +241,22 @@ export default class DefaultGUI { const testingBadge = Toggle.If(state.featureSwitchIsTesting, () => new FixedUiElement("TESTING").SetClass("alert m-2 border-2 border-black") ) - new Combine([welcomeMessageMapControl, userInfoMapControl, extraLink, testingBadge]) + new ScrollableFullScreen( + () => Translations.t.general.attribution.attributionTitle, + () => new CopyrightPanel(state), + "copyright", + guiState.copyrightViewIsOpened + ) + const copyright = new MapControlButton(Svg.copyright_svg()).onClick(() => + guiState.copyrightViewIsOpened.setData(true) + ) + new Combine([ + welcomeMessageMapControl, + userInfoMapControl, + copyright, + extraLink, + testingBadge, + ]) .SetClass("flex flex-col") .AttachTo("top-left") diff --git a/assets/layers/birdhide/birdhide.json b/assets/layers/birdhide/birdhide.json index f92fe9649..e243f6fa6 100644 --- a/assets/layers/birdhide/birdhide.json +++ b/assets/layers/birdhide/birdhide.json @@ -404,4 +404,4 @@ ] } ] -} +} \ No newline at end of file diff --git a/assets/svg/copyright.svg b/assets/svg/copyright.svg index 786af75a2..38335671a 100644 --- a/assets/svg/copyright.svg +++ b/assets/svg/copyright.svg @@ -1,6 +1,42 @@ - - - - + + + + + + - \ No newline at end of file + diff --git a/assets/tagRenderings/questions.json b/assets/tagRenderings/questions.json index c84ed8924..efbf42e57 100644 --- a/assets/tagRenderings/questions.json +++ b/assets/tagRenderings/questions.json @@ -1233,7 +1233,8 @@ }, "question": { "en": "what notes can you use to pay here?", - "nl": "Met welke bankbiljetten kan je hier betalen?" + "nl": "Met welke bankbiljetten kan je hier betalen?", + "de": "Mit welchen Banknoten kann man hier bezahlen?" }, "multiAnswer": true, "mappings": [ @@ -1242,7 +1243,8 @@ "icon": "./assets/tagRenderings/5euro.svg", "then": { "en": "5 euro notes are accepted", - "nl": "Biljetten van 5 euro worden geaccepteerd" + "nl": "Biljetten van 5 euro worden geaccepteerd", + "de": "5-Euro-Scheine werden angenommen" } }, { @@ -1250,7 +1252,8 @@ "icon": "./assets/tagRenderings/10euro.svg", "then": { "en": "10 euro notes are accepted", - "nl": "Biljetten van 10 euro worden geaccepteerd" + "nl": "Biljetten van 10 euro worden geaccepteerd", + "de": "10-Euro-Scheine werden angenommen" } }, { @@ -1258,7 +1261,8 @@ "icon": "./assets/tagRenderings/20euro.svg", "then": { "en": "20 euro notes are accepted", - "nl": "Biljetten van 20 euro worden geaccepteerd" + "nl": "Biljetten van 20 euro worden geaccepteerd", + "de": "20-Euro-Scheine werden angenommen" } }, { @@ -1266,7 +1270,8 @@ "icon": "./assets/tagRenderings/50euro.svg", "then": { "en": "50 euro notes are accepted", - "nl": "Biljetten van 50 euro worden geaccepteerd" + "nl": "Biljetten van 50 euro worden geaccepteerd", + "de": "50-Euro-Scheine werden angenommen" } }, { @@ -1274,7 +1279,8 @@ "icon": "./assets/tagRenderings/100euro.svg", "then": { "en": "100 euro notes are accepted", - "nl": "Biljetten van 100 euro worden geaccepteerd" + "nl": "Biljetten van 100 euro worden geaccepteerd", + "de": "100-Euro-Scheine werden angenommen" } }, { @@ -1282,7 +1288,8 @@ "icon": "./assets/tagRenderings/200euro.svg", "then": { "en": "200 euro notes are accepted", - "nl": "Biljetten van 200 euro worden geaccepteerd" + "nl": "Biljetten van 200 euro worden geaccepteerd", + "de": "200-Euro-Scheine werden angenommen" } }, { @@ -1290,7 +1297,8 @@ "icon": "./assets/tagRenderings/500euro.svg", "then": { "en": "500 euro notes are accepted", - "nl": "Biljetten van 500 euro worden geaccepteerd" + "nl": "Biljetten van 500 euro worden geaccepteerd", + "de": "500-Euro-Scheine werden angenommen" } } ] diff --git a/css/index-tailwind-output.css b/css/index-tailwind-output.css index 3ac35f142..1b42e5aca 100644 --- a/css/index-tailwind-output.css +++ b/css/index-tailwind-output.css @@ -8,7 +8,7 @@ */ /* - ! tailwindcss v3.1.8 | MIT License | https://tailwindcss.com + ! tailwindcss v3.2.4 | MIT License | https://tailwindcss.com */ /* @@ -39,6 +39,7 @@ 2. Prevent adjustments of font size after orientation changes in iOS. 3. Use a more readable tab size. 4. Use the user's configured `sans` font-family by default. +5. Use the user's configured `sans` font-feature-settings by default. */ html { @@ -51,6 +52,9 @@ html { /* 3 */ font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; /* 4 */ + -webkit-font-feature-settings: normal; + font-feature-settings: normal; + /* 5 */ } /* @@ -417,6 +421,12 @@ video { height: auto; } +/* Make elements with the HTML hidden attribute stay hidden by default */ + +[hidden] { + display: none; +} + *, ::before, ::after { --tw-border-spacing-x: 0; --tw-border-spacing-y: 0; @@ -592,6 +602,18 @@ video { } } +.sr-only { + position: absolute; + width: 1px; + height: 1px; + padding: 0; + margin: -1px; + overflow: hidden; + clip: rect(0, 0, 0, 0); + white-space: nowrap; + border-width: 0; +} + .pointer-events-none { pointer-events: none; } @@ -608,6 +630,10 @@ video { visibility: hidden; } +.collapse { + visibility: collapse; +} + .static { position: static; } @@ -624,10 +650,6 @@ video { position: relative; } -.\!relative { - position: relative !important; -} - .sticky { position: -webkit-sticky; position: sticky; @@ -997,10 +1019,6 @@ video { height: 3rem; } -.h-6 { - height: 1.5rem; -} - .h-4 { height: 1rem; } @@ -1017,6 +1035,10 @@ video { height: 2.75rem; } +.h-6 { + height: 1.5rem; +} + .h-96 { height: 24rem; } @@ -1132,10 +1154,6 @@ video { flex: none; } -.flex-auto { - flex: 1 1 auto; -} - .flex-shrink-0 { flex-shrink: 0; } @@ -1512,11 +1530,6 @@ video { padding: 0.125rem; } -.px-2 { - padding-left: 0.5rem; - padding-right: 0.5rem; -} - .px-0 { padding-left: 0px; padding-right: 0px; @@ -1721,13 +1734,11 @@ video { } .underline { - -webkit-text-decoration-line: underline; - text-decoration-line: underline; + text-decoration-line: underline; } .line-through { - -webkit-text-decoration-line: line-through; - text-decoration-line: line-through; + text-decoration-line: line-through; } .opacity-50 { @@ -1791,17 +1802,15 @@ video { } .transition { - transition-property: color, background-color, border-color, fill, stroke, opacity, box-shadow, -webkit-text-decoration-color, -webkit-transform, -webkit-filter, -webkit-backdrop-filter; + transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, -webkit-transform, -webkit-filter, -webkit-backdrop-filter; transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter; - transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-text-decoration-color, -webkit-transform, -webkit-filter, -webkit-backdrop-filter; + transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-transform, -webkit-filter, -webkit-backdrop-filter; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; } .transition-colors { - transition-property: color, background-color, border-color, fill, stroke, -webkit-text-decoration-color; transition-property: color, background-color, border-color, text-decoration-color, fill, stroke; - transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, -webkit-text-decoration-color; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; } @@ -1836,14 +1845,6 @@ video { color: var(--unsubtle-detail-color-contrast); } -.\[out\:json\] { - out: json; -} - -.\[timeout\:90\] { - timeout: 90; -} - .\[key\:string\] { key: string; } @@ -1908,7 +1909,7 @@ body { } .leaflet-control-attribution { - display: block ruby; + display: flex; } .badge { diff --git a/index.css b/index.css index 57918e7db..4f707d254 100644 --- a/index.css +++ b/index.css @@ -118,7 +118,7 @@ body { } .leaflet-control-attribution { - display: block ruby; + display: flex; } .badge { diff --git a/langs/en.json b/langs/en.json index e9e2c2fc8..50605772e 100644 --- a/langs/en.json +++ b/langs/en.json @@ -133,6 +133,7 @@ "josmOpened": "JOSM is opened", "mapContributionsBy": "The current visible data has edits made by {contributors}", "mapContributionsByAndHidden": "The current visible data has edits made by {contributors} and {hiddenCount} more contributors", + "mapDataByOsm": "Map data: OpenStreetMap", "mapillaryHelp": "Mapillary is an online service which gathers street-level pictures and offers them under a free license. Contributors are allowed to use these pictures to improve OpenStreetMap", "openIssueTracker": "File a bug", "openMapillary": "Open Mapillary here", diff --git a/langs/shared-questions/de.json b/langs/shared-questions/de.json index 9defd816c..0050991ff 100644 --- a/langs/shared-questions/de.json +++ b/langs/shared-questions/de.json @@ -297,4 +297,4 @@ "question": "Wie lautet der zugehörige Wikipedia Artikel?" } } -} +} \ No newline at end of file diff --git a/langs/themes/de.json b/langs/themes/de.json index fe684986c..02886e181 100644 --- a/langs/themes/de.json +++ b/langs/themes/de.json @@ -878,33 +878,6 @@ "onwheels": { "description": "Auf dieser Karte können Sie öffentlich zugängliche Orte für Rollstuhlfahrer ansehen, bearbeiten oder hinzufügen", "layers": { - "19": { - "override": { - "=title": { - "render": "Statistik" - } - } - }, - "20": { - "override": { - "+tagRenderings": { - "0": { - "render": { - "special": { - "text": "Import" - } - } - }, - "1": { - "render": { - "special": { - "message": "Alle vorgeschlagenen Tags hinzufügen" - } - } - } - } - } - }, "4": { "override": { "filter": { @@ -947,6 +920,33 @@ "override": { "name": "Barrierefreie Parkplätze" } + }, + "19": { + "override": { + "=title": { + "render": "Statistik" + } + } + }, + "20": { + "override": { + "+tagRenderings": { + "0": { + "render": { + "special": { + "text": "Import" + } + } + }, + "1": { + "render": { + "special": { + "message": "Alle vorgeschlagenen Tags hinzufügen" + } + } + } + } + } } }, "title": "Auf Rädern" @@ -1107,6 +1107,10 @@ "stations": { "description": "Bahnhofsdetails ansehen, bearbeiten und hinzufügen", "layers": { + "3": { + "description": "Ebene mit Bahnhöfen", + "name": "Bahnhöfe" + }, "15": { "description": "Anzeigen der Züge, die von diesem Bahnhof abfahren", "name": "Abfahrtstafeln", @@ -1138,10 +1142,6 @@ "title": { "render": "Abfahrtstafel" } - }, - "3": { - "description": "Ebene mit Bahnhöfen", - "name": "Bahnhöfe" } }, "title": "Bahnhöfe" @@ -1233,4 +1233,4 @@ "shortDescription": "Eine Karte mit Abfalleimern", "title": "Abfalleimer" } -} +} \ No newline at end of file