From ccffe9daa86df7c0a9c886007558bf5fc936a8d2 Mon Sep 17 00:00:00 2001 From: Anthony Fu Date: Wed, 30 Nov 2022 07:25:29 +0800 Subject: [PATCH] i18n: improve translations --- .eslintignore | 1 + components/common/CommonPaginator.vue | 2 +- components/nav/NavTitle.vue | 2 +- components/publish/PublishWidget.vue | 4 +- components/status/StatusActions.vue | 26 ++-- components/status/StatusDetails.vue | 4 +- components/user/UserSwitcher.vue | 20 +-- composables/masto.ts | 8 -- composables/statusDrafts.ts | 6 +- composables/time.ts | 3 +- locales/en-US.json | 39 +++++- locales/es-ES.json | 183 +++++++++++++------------- locales/ja-JP.json | 5 +- locales/zh-CN.json | 46 ++++++- pages/notifications.vue | 25 +++- 15 files changed, 231 insertions(+), 143 deletions(-) create mode 100644 .eslintignore diff --git a/.eslintignore b/.eslintignore new file mode 100644 index 00000000..b3a52671 --- /dev/null +++ b/.eslintignore @@ -0,0 +1 @@ +*.css diff --git a/components/common/CommonPaginator.vue b/components/common/CommonPaginator.vue index 20a8315b..bb742a2f 100644 --- a/components/common/CommonPaginator.vue +++ b/components/common/CommonPaginator.vue @@ -51,7 +51,7 @@ const { items, prevItems, update, state, endAnchor, error } = usePaginator(pagin
- Loading... + {{ $t('state.loading') }}
diff --git a/components/nav/NavTitle.vue b/components/nav/NavTitle.vue index 6efc5647..acb8d9cc 100644 --- a/components/nav/NavTitle.vue +++ b/components/nav/NavTitle.vue @@ -7,7 +7,7 @@ const sub = process.dev ? 'dev' : window.location.hostname.includes('deploy-prev Elk Logo
- Elk {{ sub }} + {{ $t('app_name') }} {{ sub }}
diff --git a/components/publish/PublishWidget.vue b/components/publish/PublishWidget.vue index c3893251..342f2872 100644 --- a/components/publish/PublishWidget.vue +++ b/components/publish/PublishWidget.vue @@ -245,9 +245,9 @@ const { isOverDropZone } = useDropZone(dropZoneRef, onDrop) :checked="visibility.value === draft.params.visibility" @click="chooseVisibility(visibility.value)" > - {{ visibility.label }} + {{ $t(`visibility.${visibility.value}`) }} diff --git a/components/status/StatusActions.vue b/components/status/StatusActions.vue index 14f4db22..56e9c515 100644 --- a/components/status/StatusActions.vue +++ b/components/status/StatusActions.vue @@ -133,7 +133,7 @@ function editStatus() {
@@ -193,7 +193,7 @@ function editStatus() {