From 6798effbabe52e1afb9c83767f971679306c3428 Mon Sep 17 00:00:00 2001 From: tamaina Date: Wed, 5 Apr 2023 14:30:03 +0900 Subject: [PATCH] =?UTF-8?q?enhance(client):=20=E6=8A=95=E7=A8=BF=E3=83=95?= =?UTF-8?q?=E3=82=A9=E3=83=BC=E3=83=A0=E3=82=92=E3=81=A1=E3=82=87=E3=81=A3?= =?UTF-8?q?=E3=81=A8=E3=81=84=E3=81=84=E6=84=9F=E3=81=98=E3=81=AB=20(#1044?= =?UTF-8?q?2)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * .formラッパーを削除 * fix type of MkPostFormAttaches * :rocket: * :art: * :art: * :art: * :art: * specifiedの時は連合なしをdisabledに * :v: * set select default * gap: 2px (max-width: 500px) / 4px * wip * :v: * :art: * fix maxTextLength * 今後表示しない * :art: * cache channel * :art: * 連合なしにする * use i18n.ts.neverShow * :v: * refactor * fix indent * tweak --------- Co-authored-by: syuilo --- locales/ja-JP.yml | 4 +- packages/frontend/src/components/MkDialog.vue | 3 +- packages/frontend/src/components/MkNote.vue | 2 +- .../src/components/MkNoteDetailed.vue | 4 +- .../frontend/src/components/MkNoteHeader.vue | 2 +- .../frontend/src/components/MkNotePreview.vue | 5 +- .../frontend/src/components/MkPostForm.vue | 399 +++++++++++------- .../src/components/MkPostFormAttaches.vue | 6 +- .../src/components/MkVisibilityPicker.vue | 76 ++-- packages/frontend/src/local-storage.ts | 1 + packages/frontend/src/os.ts | 2 + packages/frontend/src/pages/channel.vue | 4 +- packages/frontend/src/store.ts | 2 +- .../frontend/src/ui/deck/channel-column.vue | 15 +- packages/frontend/test/note.test.ts | 21 +- packages/frontend/test/url-preview.test.ts | 3 +- 16 files changed, 338 insertions(+), 211 deletions(-) diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index a4f1d802cc..66b591760c 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -961,7 +961,9 @@ copyErrorInfo: "エラー情報をコピー" joinThisServer: "このサーバーに登録する" exploreOtherServers: "他のサーバーを探す" letsLookAtTimeline: "タイムラインを見てみる" -disableFederationWarn: "連合が無効になっています。無効にしても投稿が非公開にはなりません。ほとんどの場合、このオプションを有効にする必要はありません。" +disableFederationConfirm: "連合なしにしますか?" +disableFederationConfirmWarn: "連合なしにしても投稿は非公開になりません。ほとんどの場合、連合なしにする必要はありません。" +disableFederationOk: "連合なしにする" invitationRequiredToRegister: "現在このサーバーは招待制です。招待コードをお持ちの方のみ登録できます。" emailNotSupported: "このサーバーではメール配信はサポートされていません" postToTheChannel: "チャンネルに投稿" diff --git a/packages/frontend/src/components/MkDialog.vue b/packages/frontend/src/components/MkDialog.vue index 863ea702cd..7649eb54ea 100644 --- a/packages/frontend/src/components/MkDialog.vue +++ b/packages/frontend/src/components/MkDialog.vue @@ -36,7 +36,7 @@ {{ cancelText ?? i18n.ts.cancel }}
- {{ action.text }} + {{ action.text }}
@@ -84,6 +84,7 @@ const props = withDefaults(defineProps<{ actions?: { text: string; primary?: boolean, + danger?: boolean, callback: (...args: any[]) => void; }[]; showOkButton?: boolean; diff --git a/packages/frontend/src/components/MkNote.vue b/packages/frontend/src/components/MkNote.vue index 700bbde6f0..36ec778a14 100644 --- a/packages/frontend/src/components/MkNote.vue +++ b/packages/frontend/src/components/MkNote.vue @@ -31,7 +31,7 @@ - + diff --git a/packages/frontend/src/components/MkNoteDetailed.vue b/packages/frontend/src/components/MkNoteDetailed.vue index 67bdfd2258..b9ab366850 100644 --- a/packages/frontend/src/components/MkNoteDetailed.vue +++ b/packages/frontend/src/components/MkNoteDetailed.vue @@ -30,7 +30,7 @@ - +
@@ -48,7 +48,7 @@ - +
diff --git a/packages/frontend/src/components/MkNoteHeader.vue b/packages/frontend/src/components/MkNoteHeader.vue index 15d7ea2e14..e468650430 100644 --- a/packages/frontend/src/components/MkNoteHeader.vue +++ b/packages/frontend/src/components/MkNoteHeader.vue @@ -17,7 +17,7 @@ - + diff --git a/packages/frontend/src/components/MkNotePreview.vue b/packages/frontend/src/components/MkNotePreview.vue index 16196834b7..6b55c27869 100644 --- a/packages/frontend/src/components/MkNotePreview.vue +++ b/packages/frontend/src/components/MkNotePreview.vue @@ -3,7 +3,7 @@
- +
@@ -50,6 +50,9 @@ const props = defineProps<{ .header { margin-bottom: 2px; font-weight: bold; + width: 100%; + overflow: clip; + text-overflow: ellipsis; } @container (min-width: 350px) { diff --git a/packages/frontend/src/components/MkPostForm.vue b/packages/frontend/src/components/MkPostForm.vue index 2f1b74baad..247292a1b2 100644 --- a/packages/frontend/src/components/MkPostForm.vue +++ b/packages/frontend/src/components/MkPostForm.vue @@ -7,20 +7,35 @@ @drop.stop="onDrop" >
- - -
- {{ maxTextLength - textLength }} - - + +
+
+ + + -
-
- - -
{{ i18n.ts.quoteAttached }}
-
- {{ i18n.ts.recipient }} -
- - - - - -
+ + +
{{ i18n.ts.quoteAttached }}
+
+ {{ i18n.ts.recipient }} +
+ + + + +
- {{ i18n.ts.disableFederationWarn }} - {{ i18n.ts.notSpecifiedMentionWarning }} - - -