From 50aa8917090af743fa99e9da79327496640a0014 Mon Sep 17 00:00:00 2001 From: Nicolai Ort Date: Wed, 10 Mar 2021 18:01:09 +0100 Subject: [PATCH] =?UTF-8?q?i18n=20run:=20Added=20keys=20=F0=9F=8C=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ref #93 --- src/components/dashboard/Dashboard.svelte | 2 +- .../scanstations/AddScanStationModal.svelte | 17 +- .../ConfirmScanStationDeletion.svelte | 8 +- .../scanstations/ScanStationDetail.svelte | 26 +- .../scanstations/ScanStations.svelte | 4 +- .../ScanStationsEmptyState.svelte | 5 +- .../scanstations/ScanStationsOverview.svelte | 10 +- src/locales/en.json | 641 +++++++++--------- 8 files changed, 365 insertions(+), 348 deletions(-) diff --git a/src/components/dashboard/Dashboard.svelte b/src/components/dashboard/Dashboard.svelte index b61f6736..edf3b2a6 100644 --- a/src/components/dashboard/Dashboard.svelte +++ b/src/components/dashboard/Dashboard.svelte @@ -201,7 +201,7 @@ viewBox="0 0 640 512"> - Scanstations + {$_('scanstations')} {/if}

- Create a new scanstation + {$_('create-a-new-scanstation')}

- Please provide the required information to create a new - scanstation + {$_('please-provide-the-required-information-to-create-a-new-scanstation')}

@@ -136,11 +135,11 @@
+ class="block text-sm font-medium text-gray-700">{$_('description')} + class="ml-1 font-medium text-gray-700">{$_('enabled')}

- This scanstation is {#if enabled}enabled{:else}disabled{/if} + {$_('this-scanstation-is')} {#if enabled}{$_('enabled')}{:else}{$_('disabled')}{/if}

diff --git a/src/components/scanstations/ConfirmScanStationDeletion.svelte b/src/components/scanstations/ConfirmScanStationDeletion.svelte index f69a059f..9dbd8b8e 100644 --- a/src/components/scanstations/ConfirmScanStationDeletion.svelte +++ b/src/components/scanstations/ConfirmScanStationDeletion.svelte @@ -19,7 +19,7 @@ ) .then((resp) => { Toastify({ - text: "Station deleted", + text: $_('station-deleted'), duration: 500, backgroundColor: "linear-gradient(to right, #00b09b, #96c93d)", }).showToast(); @@ -66,7 +66,7 @@ 'do-you-want-to-delete-this-donor-with-all-related-donations' )}
- All associated scans will get deleted as well + {$_('all-associated-scans-will-get-deleted-as-well')}

@@ -77,13 +77,13 @@ on:click={deleteStation} type="button" class="w-full inline-flex justify-center rounded-md border border-transparent shadow-sm px-4 py-2 bg-red-600 text-base font-medium text-white hover:bg-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 sm:ml-3 sm:w-auto sm:text-sm"> - Confirm, delete station with all scans + {$_('confirm-delete-station-with-all-scans')} diff --git a/src/components/scanstations/ScanStationDetail.svelte b/src/components/scanstations/ScanStationDetail.svelte index 44f10a6c..f8585749 100644 --- a/src/components/scanstations/ScanStationDetail.svelte +++ b/src/components/scanstations/ScanStationDetail.svelte @@ -4,8 +4,7 @@ import { ScanStationService, TrackService } from "@odit/lfk-client-js"; import Toastify from "toastify-js"; import PromiseError from "../base/PromiseError.svelte"; - import { edit } from "marked/src/helpers"; -import ConfirmScanStationDeletion from "./ConfirmScanStationDeletion.svelte"; + import ConfirmScanStationDeletion from "./ConfirmScanStationDeletion.svelte"; let data_loaded = false; let modal_open; let delete_station; @@ -32,7 +31,7 @@ import ConfirmScanStationDeletion from "./ConfirmScanStationDeletion.svelte"; function submit() { if (data_loaded === true && save_enabled) { Toastify({ - text: "Station is being updated", + text: $_('station-is-being-updated'), duration: 2500, }).showToast(); ScanStationService.scanStationControllerPut(original_data.id, editable) @@ -40,7 +39,7 @@ import ConfirmScanStationDeletion from "./ConfirmScanStationDeletion.svelte"; Object.assign(original_data, editable); original_data = original_data; Toastify({ - text: "Updated station", + text: $_('updated-station'), duration: 2500, backgroundColor: "linear-gradient(to right, #00b09b, #96c93d)", }).showToast(); @@ -53,7 +52,7 @@ import ConfirmScanStationDeletion from "./ConfirmScanStationDeletion.svelte"; ScanStationService.scanStationControllerRemove(original_data.id, false) .then((resp) => { Toastify({ - text: "Station deleted", + text: $_('station-deleted'), duration: 500, backgroundColor: "linear-gradient(to right, #00b09b, #96c93d)", }).showToast(); @@ -68,7 +67,7 @@ import ConfirmScanStationDeletion from "./ConfirmScanStationDeletion.svelte"; {#await promise} - Loading station details + {$_('loading-station-details')} {:then}
@@ -86,7 +85,7 @@ import ConfirmScanStationDeletion from "./ConfirmScanStationDeletion.svelte"; d="M2 22a8 8 0 1 1 16 0H2zm8-9c-3.315 0-6-2.685-6-6s2.685-6 6-6 6 2.685 6 6-2.685 6-6 6zm10 4h4v2h-4v-2zm-3-5h7v2h-7v-2zm2-5h5v2h-5V7z" />
  • - Scanstation{$_('scanstation')}Delete - station + class="w-full justify-center rounded-md border border-transparent shadow-sm px-4 py-2 bg-red-600 text-base font-medium text-white hover:bg-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 sm:ml-3 sm:w-auto sm:text-sm">{$_('delete-station')} {/if} {/if} {#if !delete_triggered} @@ -161,10 +159,10 @@ import ConfirmScanStationDeletion from "./ConfirmScanStationDeletion.svelte";
    + class="font-medium text-gray-700">{$_('description')} + class="ml-1 font-medium text-gray-700">{$_('enabled')}

    - This scanstation is - {#if editable.enabled}enabled{:else}disabled{/if} + {$_('this-scanstation-is')} + {#if editable.enabled}{$_('enabled')}{:else}{$_('disabled')}{/if}

  • diff --git a/src/components/scanstations/ScanStations.svelte b/src/components/scanstations/ScanStations.svelte index f1518604..882f03d3 100644 --- a/src/components/scanstations/ScanStations.svelte +++ b/src/components/scanstations/ScanStations.svelte @@ -9,7 +9,7 @@
    - Scanstations + {$_('scanstations')} {#if store.state.jwtinfo.userdetails.permissions.includes('STATION:CREATE')} {/if} diff --git a/src/components/scanstations/ScanStationsEmptyState.svelte b/src/components/scanstations/ScanStationsEmptyState.svelte index 72aa4bdc..3d34d5b5 100644 --- a/src/components/scanstations/ScanStationsEmptyState.svelte +++ b/src/components/scanstations/ScanStationsEmptyState.svelte @@ -1,7 +1,6 @@