From e5447e87e1dcf2dbbdd51dc61977f9fc4eeba5e1 Mon Sep 17 00:00:00 2001 From: kozakura913 <98575220+kozakura913@users.noreply.github.com> Date: Wed, 18 Dec 2024 12:28:23 +0900 Subject: [PATCH 1/3] =?UTF-8?q?=E3=82=A4=E3=83=B3=E3=83=9D=E3=83=BC?= =?UTF-8?q?=E3=83=88=E6=99=82=E3=81=AB=E3=83=A9=E3=82=A4=E3=82=BB=E3=83=B3?= =?UTF-8?q?=E3=82=B9=E6=AC=84=E3=81=AB=E3=82=A4=E3=83=B3=E3=83=9D=E3=83=BC?= =?UTF-8?q?=E3=83=88=E5=85=83=E3=82=92=E8=BF=BD=E8=A8=98=E3=81=99=E3=82=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/frontend/src/scripts/import-emoji.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/frontend/src/scripts/import-emoji.ts b/packages/frontend/src/scripts/import-emoji.ts index 0417559f03..fedbe8d373 100644 --- a/packages/frontend/src/scripts/import-emoji.ts +++ b/packages/frontend/src/scripts/import-emoji.ts @@ -2,8 +2,9 @@ * SPDX-FileCopyrightText: syuilo and misskey-project, yojo-art team * SPDX-License-Identifier: AGPL-3.0-only */ +import { i18n } from '@/i18n.js'; export async function importEmojiMeta(emoji, host:string) { - emoji.category = '取得失敗'; + emoji.category = i18n.ts.unavailable; try { const json = await(await fetch('https://' + host + '/api/emoji?name=' + emoji.name)).json(); emoji.category = ''; @@ -24,5 +25,6 @@ export async function importEmojiMeta(emoji, host:string) { console.log(err); //リモートから取得に失敗 } + emoji.license = (emoji.license ? emoji.license + '\n' : '') + 'import from ' + host; return emoji; } From df8ad8e8593fe16fdbb4d68d1b52a7cb1b1c92c4 Mon Sep 17 00:00:00 2001 From: kozakura913 <98575220+kozakura913@users.noreply.github.com> Date: Wed, 18 Dec 2024 12:45:04 +0900 Subject: [PATCH 2/3] locale --- locales/index.d.ts | 4 ++++ locales/ja-JP.yml | 1 + packages/frontend/src/scripts/import-emoji.ts | 2 +- 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/locales/index.d.ts b/locales/index.d.ts index 7f5c05d572..fe54e9492b 100644 --- a/locales/index.d.ts +++ b/locales/index.d.ts @@ -1137,6 +1137,10 @@ export interface Locale extends ILocale { * カスタム絵文字 */ "customEmojis": string; + /** + * 詳細情報が利用できません + */ + "emojiRemoteDetailedUnavailable": string; /** * 絵文字 */ diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index b85892a01c..7aa93ece5f 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -277,6 +277,7 @@ selectWidget: "ウィジェットを選択" editWidgets: "ウィジェットを編集" editWidgetsExit: "編集を終了" customEmojis: "カスタム絵文字" +emojiRemoteDetailedUnavailable: "詳細情報が利用できません" emoji: "絵文字" emojis: "絵文字" emojiName: "絵文字名" diff --git a/packages/frontend/src/scripts/import-emoji.ts b/packages/frontend/src/scripts/import-emoji.ts index fedbe8d373..d74b9086ac 100644 --- a/packages/frontend/src/scripts/import-emoji.ts +++ b/packages/frontend/src/scripts/import-emoji.ts @@ -4,7 +4,7 @@ */ import { i18n } from '@/i18n.js'; export async function importEmojiMeta(emoji, host:string) { - emoji.category = i18n.ts.unavailable; + emoji.category = i18n.ts.emojiRemoteDetailedUnavailable; try { const json = await(await fetch('https://' + host + '/api/emoji?name=' + emoji.name)).json(); emoji.category = ''; From 815c927757b4f53ba34555eddbb9ecb9b7c4a528 Mon Sep 17 00:00:00 2001 From: kozakura913 <98575220+kozakura913@users.noreply.github.com> Date: Fri, 27 Dec 2024 01:51:44 +0900 Subject: [PATCH 3/3] Update CHANGELOG_YOJO.md --- CHANGELOG_YOJO.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG_YOJO.md b/CHANGELOG_YOJO.md index 5541202e98..d99e6647d8 100644 --- a/CHANGELOG_YOJO.md +++ b/CHANGELOG_YOJO.md @@ -3,8 +3,10 @@ ### Release Date ### General +- ### Client +- Enhance: インポート時にライセンス欄にインポート元を追記する [#573](https://github.com/yojo-art/cherrypick/pull/573) ### Server - Feat: フォローしているユーザーなら鍵ノートでもアンテナにひっかかるように [#568](https://github.com/yojo-art/cherrypick/pull/568)