From b0fdf25b24901c429a59b5e4033ffee4b5b8a794 Mon Sep 17 00:00:00 2001 From: syuilo Date: Thu, 2 Aug 2018 06:58:15 +0900 Subject: [PATCH] Improve i18n --- locales/en.yml | 16 +++++----- locales/ja.yml | 31 ++++++++++++------- .../app/common/views/widgets/calendar.vue | 24 +++++++++----- 3 files changed, 44 insertions(+), 27 deletions(-) diff --git a/locales/en.yml b/locales/en.yml index 53be9ec494..1761342ec0 100644 --- a/locales/en.yml +++ b/locales/en.yml @@ -238,7 +238,7 @@ common/views/widgets/broadcast.vue: no-broadcasts: "No announcements" have-a-nice-day: "Have a nice day!" next: "Next" - + common/views/widgets/calendar.vue: year-english: "Year " year-japanese: "" @@ -251,7 +251,7 @@ common/views/widgets/calendar.vue: today: "Today: " this-month: "This month: " this-year: "This year: " - + common/views/widgets/donation.vue: title: "Request for donations" text: "To keep Misskey up and running, we have to spend money on our domain name, the server costs and so on. Since we don't receive money from advertisements, we count on donations from all of you. If you're interested in helping, contact {}. Thank you for your contribution!" @@ -276,7 +276,7 @@ common/views/widgets/slideshow.vue: folder-customize-mode: "To specify a folder, please exit customize mode" folder: "Please click and specify a folder" no-image: "There is no image in this folder" - + common/views/widgets/tips.vue: tips-line1: "You can focus on the timeline with t." tips-line2: "Open posting form with p or n." @@ -715,18 +715,18 @@ desktop/views/pages/selectdrive.vue: ok: "OK" cancel: "Cancel" upload: "Upload files from your device" - + desktop/views/pages/search.vue: not-available: "The search function can not be used." not-found-quotes1: "\"" not-found-quotes2: "\"" not-found-text-english: "No posts were found for " - not-found-text-japanese: "." + not-found-text-japanese: "." desktop/views/pages/share.vue: share-with: "Share with Misskey" close: "Close" - + desktop/views/pages/tag.vue: no-posts-found-english: "No posts were found for " no-posts-found-japanese: "" @@ -888,7 +888,7 @@ mobile/views/components/sub-note-content.vue: mobile/views/components/timeline.vue: empty: "No notes" load-more: "More" - + mobile/views/components/ui.header.vue: welcome-back: "Welcome back, " @@ -977,7 +977,7 @@ mobile/views/pages/settings/settings.profile.vue: saved: "Profile updated" uploading: "Uploading" upload-failed: "Failed to upload" - + mobile/views/pages/search.vue: search: "Search" empty: "No posts were found for '{}'" diff --git a/locales/ja.yml b/locales/ja.yml index d85be9e13b..917e98bf93 100644 --- a/locales/ja.yml +++ b/locales/ja.yml @@ -37,6 +37,15 @@ common: friday: "金" saturday: "土" + weekday: + sunday: "日曜日" + monday: "月曜日" + tuesday: "火曜日" + wednesday: "水曜日" + thursday: "木曜日" + friday: "金曜日" + saturday: "土曜日" + reactions: like: "いいね" love: "しゅき" @@ -265,7 +274,7 @@ common/views/widgets/broadcast.vue: no-broadcasts: "お知らせはありません" have-a-nice-day: "良い一日を!" next: "次" - + common/views/widgets/calendar.vue: year-english: "" year-japanese: "年" @@ -304,7 +313,7 @@ common/views/widgets/memo.vue: title: "付箋" memo: "ここに書いて!" save: "保存" - + common/views/widgets/slideshow.vue: folder-customize-mode: "フォルダを指定するには、カスタマイズモードを終了してください" folder: "クリックしてフォルダを指定してください" @@ -541,7 +550,7 @@ desktop/views/components/post-form.vue: geolocation-alert: "お使いの端末は位置情報に対応していません" error: "エラー" enter-username: "ユーザー名を入力してください" - + desktop/views/components/post-form-window.vue: note: "新規投稿" reply: "返信" @@ -760,7 +769,7 @@ desktop/views/components/received-follow-requests-window.vue: title: "フォロー申請" accept: "承認" reject: "拒否" - + desktop/views/components/user-lists-window.vue: @@ -830,17 +839,17 @@ desktop/views/pages/search.vue: not-found-quotes2: "」" not-found-text-english: "" not-found-text-japanese: "に関する投稿は見つかりませんでした。" - + desktop/views/pages/share.vue: share-with: "Misskeyで共有" close: "閉じる" - + desktop/views/pages/tag.vue: no-posts-found-english: "" no-posts-found-japanese: "に関する投稿は見つかりませんでした。" left-quote: "「" right-quote: "」" - + desktop/views/pages/user-list.users.vue: users: "ユーザー" add-user: "ユーザーを追加" @@ -1068,7 +1077,7 @@ mobile/views/pages/user-lists.vue: mobile/views/pages/drive.vue: drive: "ドライブ" more: "もっと見る" - + mobile/views/pages/signup.vue: lets-start: "📦 始めましょう" @@ -1089,12 +1098,12 @@ mobile/views/pages/tag.vue: no-posts-found-english: "" left-quote: "「" right-quote: "」" - + mobile/views/pages/welcome.vue: signup: "新規登録" mobile/views/pages/widgets.vue: - dashboard: "ダッシュボード" + dashboard: "ダッシュボード" mobile/views/pages/widgets/activity.vue: activity: "アクティビティ" @@ -1118,7 +1127,7 @@ mobile/views/pages/note.vue: mobile/views/pages/notifications.vue: notifications: "通知" read-all: "すべての通知を既読にしますか?" - + mobile/views/pages/reversi.vue: reversi: "リバーシ" diff --git a/src/client/app/common/views/widgets/calendar.vue b/src/client/app/common/views/widgets/calendar.vue index d928663bb4..68a58f8936 100644 --- a/src/client/app/common/views/widgets/calendar.vue +++ b/src/client/app/common/views/widgets/calendar.vue @@ -4,27 +4,27 @@

- %i18n:year-english%{{ year }}%i18n:year-japanese% - %i18n:month-english%{{ month }}%i18n:month-japanese% + %i18n:@year-english%{{ year }}%i18n:@year-japanese% + %i18n:@month-english%{{ month }}%i18n:@month-japanese%

-

>%i18n:day-english%{{ day }}%i18n:day-japanese%

-

%i18n:weekday-english%{{ weekDay }}%i18n:weekday-japanese%

+

%i18n:@day-english%{{ day }}%i18n:@day-japanese%

+

{{ weekDay }}

-

%i18n:today%{{ dayP.toFixed(1) }}%

+

%i18n:@today%{{ dayP.toFixed(1) }}%

-

%i18n:this-month%{{ monthP.toFixed(1) }}%

+

%i18n:@this-month%{{ monthP.toFixed(1) }}%

-

%i18n:this-year%{{ yearP.toFixed(1) }}%

+

%i18n:@this-year%{{ yearP.toFixed(1) }}%

@@ -84,7 +84,15 @@ export default define({ this.year = ny; this.month = nm + 1; this.day = nd; - this.weekDay = ['日', '月', '火', '水', '木', '金', '土'][now.getDay()]; + this.weekDay = [ + '%i18n:common.weekday.sunday%', + '%i18n:common.weekday.monday%', + '%i18n:common.weekday.tuesday%', + '%i18n:common.weekday.wednesday%', + '%i18n:common.weekday.thursday%', + '%i18n:common.weekday.friday%', + '%i18n:common.weekday.saturday%' + ][now.getDay()]; const dayNumer = now.getTime() - new Date(ny, nm, nd).getTime(); const dayDenom = 1000/*ms*/ * 60/*s*/ * 60/*m*/ * 24/*h*/;