From ebd317cebce234449a5ea52bab40d078a7169b03 Mon Sep 17 00:00:00 2001 From: taiyme <53635909+taiyme@users.noreply.github.com> Date: Sat, 11 Feb 2023 16:34:17 +0900 Subject: [PATCH] =?UTF-8?q?feat(client):=20=E3=83=AA=E3=82=A2=E3=82=AF?= =?UTF-8?q?=E3=82=B7=E3=83=A7=E3=83=B3=E4=B8=80=E8=A6=A7=E8=A9=B3=E7=B4=B0?= =?UTF-8?q?=E3=83=80=E3=82=A4=E3=82=A2=E3=83=AD=E3=82=B0=E3=82=92=E8=A1=A8?= =?UTF-8?q?=E7=A4=BA=E3=81=A7=E3=81=8D=E3=82=8B=E3=82=88=E3=81=86=E3=81=AB?= =?UTF-8?q?=20(for=20v12)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: syuilo --- locales/ar-SA.yml | 1 + locales/bn-BD.yml | 1 + locales/ca-ES.yml | 1 + locales/cs-CZ.yml | 1 + locales/de-DE.yml | 1 + locales/en-US.yml | 1 + locales/es-ES.yml | 1 + locales/fr-FR.yml | 1 + locales/id-ID.yml | 1 + locales/it-IT.yml | 3 +- locales/ja-JP.yml | 1 + locales/ja-KS.yml | 1 + locales/ko-KR.yml | 2 + locales/nl-NL.yml | 2 + locales/pl-PL.yml | 1 + locales/pt-PT.yml | 1 + locales/ro-RO.yml | 1 + locales/ru-RU.yml | 1 + locales/sk-SK.yml | 1 + locales/sv-SE.yml | 1 + locales/th-TH.yml | 1 + locales/uk-UA.yml | 1 + locales/vi-VN.yml | 1 + locales/zh-CN.yml | 1 + locales/zh-TW.yml | 1 + .../src/components/MkReactedUsersDialog.vue | 100 ++++++++++++++++++ .../client/src/components/MkUserCardMini.vue | 20 ++-- packages/client/src/scripts/get-note-menu.ts | 13 ++- 28 files changed, 153 insertions(+), 9 deletions(-) create mode 100644 packages/client/src/components/MkReactedUsersDialog.vue diff --git a/locales/ar-SA.yml b/locales/ar-SA.yml index 7fa8c23ad05c..0982305ac7b5 100644 --- a/locales/ar-SA.yml +++ b/locales/ar-SA.yml @@ -107,6 +107,7 @@ clickToShow: "اضغط للعرض" sensitive: "محتوى حساس" add: "إضافة" reaction: "التفاعلات" +reactions: "التفاعلات" reactionSetting: "التفاعلات المراد عرضها في منتقي التفاعلات." reactionSettingDescription2: "اسحب لترتيب ، انقر للحذف ، استخدم \"+\" للإضافة." rememberNoteVisibility: "تذكر إعدادت مدى رؤية الملاحظات" diff --git a/locales/bn-BD.yml b/locales/bn-BD.yml index a19fc0832edb..6da1f4c4ce73 100644 --- a/locales/bn-BD.yml +++ b/locales/bn-BD.yml @@ -107,6 +107,7 @@ clickToShow: "দেখার জন্য ক্লিক করুন" sensitive: "সংবেদনশীল বিষয়বস্তু" add: "যুক্ত করুন" reaction: "প্রতিক্রিয়া" +reactions: "প্রতিক্রিয়া" reactionSetting: "রিঅ্যাকশন পিকারে যেসকল প্রতিক্রিয়া দেখানো হবে" reactionSettingDescription2: "পুনরায় সাজাতে টেনে আনুন, মুছতে ক্লিক করুন, যোগ করতে + টিপুন।" rememberNoteVisibility: "নোটের দৃশ্যমান্যতার সেটিংস মনে রাখুন" diff --git a/locales/ca-ES.yml b/locales/ca-ES.yml index 1c859b68f576..96c5ca859cbd 100644 --- a/locales/ca-ES.yml +++ b/locales/ca-ES.yml @@ -106,6 +106,7 @@ clickToShow: "Fes clic per mostrar" sensitive: "NSFW" add: "Afegir" reaction: "Reaccions" +reactions: "Reaccions" reactionSetting: "Reaccions a mostrar al selector de reaccions" reactionSettingDescription2: "Arrossega per reordenar, fes clic per suprimir, prem \"+\" per afegir." rememberNoteVisibility: "Recorda la configuració de visibilitat de les notes" diff --git a/locales/cs-CZ.yml b/locales/cs-CZ.yml index 9d54e0082f87..4c2b0e92d3e4 100644 --- a/locales/cs-CZ.yml +++ b/locales/cs-CZ.yml @@ -105,6 +105,7 @@ clickToShow: "Klikněte pro zobrazení" sensitive: "NSFW" add: "Přidat" reaction: "Reakce" +reactions: "Reakce" reactionSettingDescription2: "Přetažením změníte pořadí, kliknutím smažete, zmáčkněte \"+\" k přidání" rememberNoteVisibility: "Zapamatovat nastavení zobrazení poznámky" attachCancel: "Odstranit přílohu" diff --git a/locales/de-DE.yml b/locales/de-DE.yml index 1498992586d0..a7f78da00ade 100644 --- a/locales/de-DE.yml +++ b/locales/de-DE.yml @@ -107,6 +107,7 @@ clickToShow: "Zum Anzeigen anklicken" sensitive: "NSFW" add: "Hinzufügen" reaction: "Reaktionen" +reactions: "Reaktionen" reactionSetting: "In der Reaktionsauswahl anzuzeigende Reaktionen" reactionSettingDescription2: "Ziehe um Anzuordnen, klicke um zu löschen, drücke „+“ um hinzuzufügen" rememberNoteVisibility: "Notizsichtbarkeit merken" diff --git a/locales/en-US.yml b/locales/en-US.yml index 3b04b401dd42..eb7d5487b06c 100644 --- a/locales/en-US.yml +++ b/locales/en-US.yml @@ -107,6 +107,7 @@ clickToShow: "Click to show" sensitive: "NSFW" add: "Add" reaction: "Reactions" +reactions: "Reactions" reactionSetting: "Reactions to show in the reaction picker" reactionSettingDescription2: "Drag to reorder, click to delete, press \"+\" to add." rememberNoteVisibility: "Remember note visibility settings" diff --git a/locales/es-ES.yml b/locales/es-ES.yml index b74eed85d6cb..d4daac1597a2 100644 --- a/locales/es-ES.yml +++ b/locales/es-ES.yml @@ -107,6 +107,7 @@ clickToShow: "Click para ver" sensitive: "Marcado como sensible" add: "Agregar" reaction: "Reacción" +reactions: "Reacción" reactionSetting: "Reacciones para mostrar en el menú de reacciones" reactionSettingDescription2: "Arrastre para reordenar, click para borrar, apriete la tecla + para añadir." rememberNoteVisibility: "Recordar visibilidad" diff --git a/locales/fr-FR.yml b/locales/fr-FR.yml index d6047b48daae..c8c38988c3de 100644 --- a/locales/fr-FR.yml +++ b/locales/fr-FR.yml @@ -107,6 +107,7 @@ clickToShow: "Cliquer pour afficher" sensitive: "Contenu sensible" add: "Ajouter" reaction: "Réactions" +reactions: "Réactions" reactionSetting: "Réactions à afficher dans le sélecteur de réactions" reactionSettingDescription2: "Déplacer pour réorganiser, cliquer pour effacer, utiliser « + » pour ajouter." rememberNoteVisibility: "Activer l'option \" se souvenir de la visibilité des notes \" vous permet de réutiliser automatiquement la visibilité utilisée lors de la publication de votre note précédente." diff --git a/locales/id-ID.yml b/locales/id-ID.yml index dc214f4ea140..7d0c9bd4d471 100644 --- a/locales/id-ID.yml +++ b/locales/id-ID.yml @@ -107,6 +107,7 @@ clickToShow: "Klik untuk melihat" sensitive: "Konten sensitif" add: "Tambahkan" reaction: "Reaksi" +reactions: "Reaksi" reactionSetting: "Reaksi untuk dimunculkan di bilah reaksi" reactionSettingDescription2: "Geser untuk memindah urutkan, klik untuk menghapus, tekan \"+\" untuk menambahkan" rememberNoteVisibility: "Ingat pengaturan visibilitas catatan" diff --git a/locales/it-IT.yml b/locales/it-IT.yml index 410928bc51f2..29cead580165 100644 --- a/locales/it-IT.yml +++ b/locales/it-IT.yml @@ -106,7 +106,8 @@ you: "Tu" clickToShow: "Clicca per visualizzare" sensitive: "Contenuto sensibile" add: "Aggiungi" -reaction: "Reazione" +reaction: "Reazioni" +reactions: "Reazioni" reactionSetting: "Reazioni visualizzate sul pannello" reactionSettingDescription2: "Trascina per riorganizzare, clicca per cancellare, usa il pulsante \"+\" per aggiungere." rememberNoteVisibility: "Ricordare le impostazioni di visibilità delle note" diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index b10cce923127..1b122c14b22b 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -107,6 +107,7 @@ clickToShow: "クリックして表示" sensitive: "閲覧注意" add: "追加" reaction: "リアクション" +reactions: "リアクション" reactionSetting: "ピッカーに表示するリアクション" reactionSettingDescription2: "ドラッグして並び替え、クリックして削除、+を押して追加します。" rememberNoteVisibility: "公開範囲を記憶する" diff --git a/locales/ja-KS.yml b/locales/ja-KS.yml index 7d93fd83e95c..a0103519f583 100644 --- a/locales/ja-KS.yml +++ b/locales/ja-KS.yml @@ -107,6 +107,7 @@ clickToShow: "押したら見えるで" sensitive: "ちょっとアカンやつやで" add: "増やす" reaction: "リアクション" +reactions: "リアクション" reactionSetting: "Reaction that will be displayed in Picker. " reactionSettingDescription2: "ドラッグで並び替え、クリックで削除、+を押して追加やで。" rememberNoteVisibility: "公開範囲覚えといて" diff --git a/locales/ko-KR.yml b/locales/ko-KR.yml index d77f7e920053..b7f93e18bfc2 100644 --- a/locales/ko-KR.yml +++ b/locales/ko-KR.yml @@ -107,6 +107,7 @@ clickToShow: "클릭하여 보기" sensitive: "열람주의" add: "추가" reaction: "리액션" +reactions: "리액션" reactionSetting: "선택기에 표시할 리액션" reactionSettingDescription2: "끌어서 순서 변경, 클릭해서 삭제, +를 눌러서 추가할 수 있습니다." rememberNoteVisibility: "공개 범위를 기억하기" @@ -1696,6 +1697,7 @@ _notification: youWereInvitedToGroup: "그룹에 초대되었습니다" pollEnded: "투표 결과가 발표되었습니다" emptyPushNotificationMessage: "푸시 알림이 갱신되었습니다" + achievementEarned: "도전 과제를 달성했습니다" _types: all: "전부" follow: "팔로잉" diff --git a/locales/nl-NL.yml b/locales/nl-NL.yml index 7a0580f2d0a3..802449f59f9d 100644 --- a/locales/nl-NL.yml +++ b/locales/nl-NL.yml @@ -106,6 +106,8 @@ clickToShow: "Klik om te bekijken" sensitive: "NSFW" add: "Toevoegen" reaction: "Reacties" +reactions: "Reacties" +reactionSetting: "Reacties die in de reactie-selector worden getoond" reactionSettingDescription2: "Sleep om opnieuw te ordenen, Klik om te verwijderen, Druk op \"+\" om toe te voegen" rememberNoteVisibility: "Vergeet niet de notitie zichtbaarheidsinstellingen" attachCancel: "Verwijder bijlage" diff --git a/locales/pl-PL.yml b/locales/pl-PL.yml index 933b722c539c..d0f01f85a4f0 100644 --- a/locales/pl-PL.yml +++ b/locales/pl-PL.yml @@ -107,6 +107,7 @@ clickToShow: "Kliknij, aby wyświetlić" sensitive: "NSFW" add: "Dodaj" reaction: "Reakcja" +reactions: "Reakcja" reactionSetting: "Reakcje do pokazania w wyborniku reakcji" reactionSettingDescription2: "Przeciągnij aby zmienić kolejność, naciśnij aby usunąć, naciśnij „+” aby dodać" rememberNoteVisibility: "Zapamiętuj ustawienia widoczności wpisu" diff --git a/locales/pt-PT.yml b/locales/pt-PT.yml index 054e845b7317..098d3849a201 100644 --- a/locales/pt-PT.yml +++ b/locales/pt-PT.yml @@ -107,6 +107,7 @@ clickToShow: "Clique para ver" sensitive: "Conteúdo sensível" add: "Adicionar" reaction: "Reações" +reactions: "Reações" reactionSetting: "Quais reações a mostrar no selecionador de reações" reactionSettingDescription2: "Arraste para reordenar, clique para excluir, pressione + para adicionar." rememberNoteVisibility: "Lembrar das configurações de visibilidade de notas" diff --git a/locales/ro-RO.yml b/locales/ro-RO.yml index 8254994b2370..8b17280e6277 100644 --- a/locales/ro-RO.yml +++ b/locales/ro-RO.yml @@ -107,6 +107,7 @@ clickToShow: "Click pentru a afișa" sensitive: "NSFW" add: "Adaugă" reaction: "Reacție" +reactions: "Reacție" reactionSetting: "Reacții care să apară in selectorul de reacții" reactionSettingDescription2: "Trage pentru a rearanja, apasă pe \"+\" pentru a adăuga." rememberNoteVisibility: "Amintește setarea de vizibilitate a notelor" diff --git a/locales/ru-RU.yml b/locales/ru-RU.yml index afce5ec023a6..1f9c2c192014 100644 --- a/locales/ru-RU.yml +++ b/locales/ru-RU.yml @@ -107,6 +107,7 @@ clickToShow: "Нажмите для просмотра" sensitive: "Содержимое не для всех" add: "Добавить" reaction: "Реакции" +reactions: "Реакции" reactionSetting: "Реакции, отображаемые в палитре" reactionSettingDescription2: "Расставляйте перетаскиванием, удаляйте нажатием, добавляйте кнопкой «+»." rememberNoteVisibility: "Запоминать видимость заметок" diff --git a/locales/sk-SK.yml b/locales/sk-SK.yml index 43129edcf0b2..c6fcd4c4cd2a 100644 --- a/locales/sk-SK.yml +++ b/locales/sk-SK.yml @@ -107,6 +107,7 @@ clickToShow: "Kliknutím zobrazíte" sensitive: "NSFW" add: "Pridať" reaction: "Reakcie" +reactions: "Reakcie" reactionSetting: "Reakcie zobrazené vo výbere reakcií" reactionSettingDescription2: "Ťahaním preusporiadate, kliknutím odstránite, Stlačením \"+\" pridáte" rememberNoteVisibility: "Zapamätať nastavenia viditeľnosti poznámky" diff --git a/locales/sv-SE.yml b/locales/sv-SE.yml index 3f68d36417ba..487c20a2da02 100644 --- a/locales/sv-SE.yml +++ b/locales/sv-SE.yml @@ -106,6 +106,7 @@ clickToShow: "Klicka för att visa" sensitive: "Känsligt innehåll" add: "Lägg till" reaction: "Reaktioner" +reactions: "Reaktioner" reactionSetting: "Reaktioner som ska visas i reaktionsväljaren" reactionSettingDescription2: "Dra för att omordna, klicka för att radera, tryck \"+\" för att lägga till." rememberNoteVisibility: "Komihåg notvisningsinställningar" diff --git a/locales/th-TH.yml b/locales/th-TH.yml index 6f794a7c7f6a..3de363e5176d 100644 --- a/locales/th-TH.yml +++ b/locales/th-TH.yml @@ -107,6 +107,7 @@ clickToShow: "คลิกเพื่อแสดง" sensitive: "เนื้อหาที่ละเอียดอ่อน NSFW" add: "เพิ่ม" reaction: "รีแอคชั่น" +reactions: "รีแอคชั่น" reactionSetting: "รีแอคชั่นไปยังแสดงผลในตัวเลือกการรีแอคชั่น" reactionSettingDescription2: "กดลากเพื่อจัดลำดับใหม่ กดคลิกเพื่อลบ กด \"+\" เพื่อเพิ่ม" rememberNoteVisibility: "จดจำการตั้งค่าการมองเห็นตัวโน้ต" diff --git a/locales/uk-UA.yml b/locales/uk-UA.yml index b696a58b957b..96c68cf36202 100644 --- a/locales/uk-UA.yml +++ b/locales/uk-UA.yml @@ -107,6 +107,7 @@ clickToShow: "Натисніть для перегляду" sensitive: "NSFW" add: "Додати" reaction: "Реакції" +reactions: "Реакції" reactionSetting: "Налаштування реакцій" reactionSettingDescription2: "Перемістити щоб змінити порядок, Клацнути мишою щоб видалити, Натиснути \"+\" щоб додати." rememberNoteVisibility: "Пам’ятати параметри видимісті" diff --git a/locales/vi-VN.yml b/locales/vi-VN.yml index 3cac0585a893..1b51efe482ec 100644 --- a/locales/vi-VN.yml +++ b/locales/vi-VN.yml @@ -107,6 +107,7 @@ clickToShow: "Nhấn để xem" sensitive: "Nhạy cảm" add: "Thêm" reaction: "Biểu cảm" +reactions: "Biểu cảm" reactionSetting: "Chọn những biểu cảm hiển thị" reactionSettingDescription2: "Kéo để sắp xếp, nhấn để xóa, nhấn \"+\" để thêm." rememberNoteVisibility: "Lưu kiểu tút mặc định" diff --git a/locales/zh-CN.yml b/locales/zh-CN.yml index 1b6f29667f22..022d8fa66d5f 100644 --- a/locales/zh-CN.yml +++ b/locales/zh-CN.yml @@ -107,6 +107,7 @@ clickToShow: "点击以显示" sensitive: "敏感内容" add: "添加" reaction: "回应" +reactions: "回应" reactionSetting: "在选择器中显示的回应" reactionSettingDescription2: "拖动重新排序,单击删除,点击 + 添加。" rememberNoteVisibility: "保存上次设置的可见性" diff --git a/locales/zh-TW.yml b/locales/zh-TW.yml index 3449da99a66a..eb06cfc2859e 100644 --- a/locales/zh-TW.yml +++ b/locales/zh-TW.yml @@ -107,6 +107,7 @@ clickToShow: "按一下以顯示" sensitive: "敏感內容" add: "新增" reaction: "情感" +reactions: "情感" reactionSetting: "在選擇器中顯示反應" reactionSettingDescription2: "拖動以重新列序,點擊以刪除,按下 + 添加。" rememberNoteVisibility: "記住貼文可見性" diff --git a/packages/client/src/components/MkReactedUsersDialog.vue b/packages/client/src/components/MkReactedUsersDialog.vue new file mode 100644 index 000000000000..cc76ed3f932d --- /dev/null +++ b/packages/client/src/components/MkReactedUsersDialog.vue @@ -0,0 +1,100 @@ + + + + + diff --git a/packages/client/src/components/MkUserCardMini.vue b/packages/client/src/components/MkUserCardMini.vue index 1a4c49498733..960e229dd3fa 100644 --- a/packages/client/src/components/MkUserCardMini.vue +++ b/packages/client/src/components/MkUserCardMini.vue @@ -11,20 +11,28 @@ diff --git a/packages/client/src/scripts/get-note-menu.ts b/packages/client/src/scripts/get-note-menu.ts index 8f088bc026cd..c9277c6f35fd 100644 --- a/packages/client/src/scripts/get-note-menu.ts +++ b/packages/client/src/scripts/get-note-menu.ts @@ -179,6 +179,12 @@ export function getNoteMenu(props: { }); } + function showReactions(): void { + os.popup(defineAsyncComponent(() => import('@/components/MkReactedUsersDialog.vue')), { + noteId: appearNote.id, + }, {}, 'closed'); + } + async function translate(): Promise { if (props.translation.value != null) return; props.translating.value = true; @@ -204,8 +210,11 @@ export function getNoteMenu(props: { danger: true, action: unclip, }, null] : [] - ), - { + ), { + icon: 'ti ti-users', + text: i18n.ts.reactions, + action: showReactions, + }, { icon: 'ti ti-copy', text: i18n.ts.copyContent, action: copyContent,