From f90ed6d3ba785212c0c6518fc8617571da44b118 Mon Sep 17 00:00:00 2001 From: taiyme <53635909+taiyme@users.noreply.github.com> Date: Sat, 2 Nov 2024 20:39:51 +0900 Subject: [PATCH 1/3] =?UTF-8?q?enh(frontend):=20=E6=96=9C=E7=B7=9A?= =?UTF-8?q?=E3=83=87=E3=82=B6=E3=82=A4=E3=83=B3=E3=81=AE=E8=AA=BF=E6=95=B4?= =?UTF-8?q?,=20Mk.*CardMini=E3=81=AE=E6=94=B9=E4=BF=AE=20(taiyme#289)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/components/MkInstanceCardMini.vue | 194 +++++++++++------- .../src/components/MkNoteDetailed.vue | 4 +- .../src/components/MkUserCardMini.vue | 67 +++++- .../src/components/global/MkFooterSpacer.vue | 24 ++- .../src/components/global/MkPageHeader.vue | 21 +- packages/frontend/src/pages/admin-file.vue | 2 +- .../src/pages/admin/overview.users.vue | 4 +- .../frontend/src/pages/admin/roles.role.vue | 3 +- packages/frontend/src/pages/admin/users.vue | 2 +- packages/frontend/src/pages/instance-info.vue | 2 +- packages/frontend/src/pages/list.vue | 2 +- packages/frontend/src/pages/my-lists/list.vue | 2 +- packages/frontend/src/pages/search.note.vue | 2 +- .../frontend/src/pages/settings/accounts.vue | 2 +- 14 files changed, 205 insertions(+), 126 deletions(-) diff --git a/packages/frontend/src/components/MkInstanceCardMini.vue b/packages/frontend/src/components/MkInstanceCardMini.vue index b0601cf7f9..7a11dc4666 100644 --- a/packages/frontend/src/components/MkInstanceCardMini.vue +++ b/packages/frontend/src/components/MkInstanceCardMini.vue @@ -4,114 +4,158 @@ SPDX-License-Identifier: AGPL-3.0-only --> diff --git a/packages/frontend/src/components/MkNoteDetailed.vue b/packages/frontend/src/components/MkNoteDetailed.vue index e0473dce5e..8366dc8a9e 100644 --- a/packages/frontend/src/components/MkNoteDetailed.vue +++ b/packages/frontend/src/components/MkNoteDetailed.vue @@ -166,7 +166,7 @@ SPDX-License-Identifier: AGPL-3.0-only @@ -183,7 +183,7 @@ SPDX-License-Identifier: AGPL-3.0-only diff --git a/packages/frontend/src/components/MkUserCardMini.vue b/packages/frontend/src/components/MkUserCardMini.vue index 7a2e878931..0489729875 100644 --- a/packages/frontend/src/components/MkUserCardMini.vue +++ b/packages/frontend/src/components/MkUserCardMini.vue @@ -4,7 +4,12 @@ SPDX-License-Identifier: AGPL-3.0-only --> @@ -49,8 +67,37 @@ $bodyInfoHieght: 16px; display: flex; align-items: center; padding: 16px; - background: var(--MI_THEME-panel); border-radius: 8px; + background-color: var(--MI-THEME-panel); + background-image: repeating-linear-gradient( + 135deg, + transparent, + transparent 10px, + var(--c) 6px, + var(--c) 16px + ); + --c: transparent; + + &, + html[data-color-scheme=light] & { + &.isSilenced { + --c: color(from color-mix(in srgb, var(--MI_THEME-panel), blue 50%) srgb r g b / 0.25); + } + + &.isSuspended { + --c: color(from color-mix(in srgb, var(--MI_THEME-panel), black 15%) srgb r g b / 0.25); + } + } + + html[data-color-scheme=dark] & { + &.isSilenced { + --c: color(from color-mix(in srgb, var(--MI_THEME-panel), blue 50%) srgb r g b / 0.5); + } + + &.isSuspended { + --c: color(from color-mix(in srgb, var(--MI_THEME-panel), white 15%) srgb r g b / 0.5); + } + } } .avatar { diff --git a/packages/frontend/src/components/global/MkFooterSpacer.vue b/packages/frontend/src/components/global/MkFooterSpacer.vue index 1a75855fa1..cbb35b978f 100644 --- a/packages/frontend/src/components/global/MkFooterSpacer.vue +++ b/packages/frontend/src/components/global/MkFooterSpacer.vue @@ -4,13 +4,9 @@ SPDX-License-Identifier: AGPL-3.0-only --> - - diff --git a/packages/frontend/src/components/global/MkPageHeader.vue b/packages/frontend/src/components/global/MkPageHeader.vue index aa4be69b2c..4e2ae9d41e 100644 --- a/packages/frontend/src/components/global/MkPageHeader.vue +++ b/packages/frontend/src/components/global/MkPageHeader.vue @@ -4,7 +4,7 @@ SPDX-License-Identifier: AGPL-3.0-only --> diff --git a/packages/frontend/src/pages/admin/users.vue b/packages/frontend/src/pages/admin/users.vue index 870c3ce88b..e83a0eb927 100644 --- a/packages/frontend/src/pages/admin/users.vue +++ b/packages/frontend/src/pages/admin/users.vue @@ -46,7 +46,7 @@ SPDX-License-Identifier: AGPL-3.0-only
- +
diff --git a/packages/frontend/src/pages/instance-info.vue b/packages/frontend/src/pages/instance-info.vue index 6cec3f9d45..b242665e49 100644 --- a/packages/frontend/src/pages/instance-info.vue +++ b/packages/frontend/src/pages/instance-info.vue @@ -119,7 +119,7 @@ SPDX-License-Identifier: AGPL-3.0-only
- +
diff --git a/packages/frontend/src/pages/list.vue b/packages/frontend/src/pages/list.vue index 0ff1854154..07d2fefe96 100644 --- a/packages/frontend/src/pages/list.vue +++ b/packages/frontend/src/pages/list.vue @@ -21,7 +21,7 @@ SPDX-License-Identifier: AGPL-3.0-only
- +
diff --git a/packages/frontend/src/pages/my-lists/list.vue b/packages/frontend/src/pages/my-lists/list.vue index 69e404bd85..edcf154ee2 100644 --- a/packages/frontend/src/pages/my-lists/list.vue +++ b/packages/frontend/src/pages/my-lists/list.vue @@ -36,7 +36,7 @@ SPDX-License-Identifier: AGPL-3.0-only
- + diff --git a/packages/frontend/src/pages/search.note.vue b/packages/frontend/src/pages/search.note.vue index 105c947d25..38dca224c3 100644 --- a/packages/frontend/src/pages/search.note.vue +++ b/packages/frontend/src/pages/search.note.vue @@ -29,7 +29,7 @@ SPDX-License-Identifier: AGPL-3.0-only
- +
{{ i18n.ts.selectSelf }}
{{ i18n.ts.selectUser }}
diff --git a/packages/frontend/src/pages/settings/accounts.vue b/packages/frontend/src/pages/settings/accounts.vue index 97e960675f..65f06937d5 100644 --- a/packages/frontend/src/pages/settings/accounts.vue +++ b/packages/frontend/src/pages/settings/accounts.vue @@ -12,7 +12,7 @@ SPDX-License-Identifier: AGPL-3.0-only {{ i18n.ts.reloadAccountsList }}
- +
From f68f05eb81297b703279393b5987befaa11a6487 Mon Sep 17 00:00:00 2001 From: kakkokari-gtyih <67428053+kakkokari-gtyih@users.noreply.github.com> Date: Sat, 2 Nov 2024 20:46:51 +0900 Subject: [PATCH 2/3] =?UTF-8?q?enh(frontend):=20=E6=96=9C=E7=B7=9A?= =?UTF-8?q?=E3=83=87=E3=82=B6=E3=82=A4=E3=83=B3=E3=81=AE=E8=AA=BF=E6=95=B4?= =?UTF-8?q?,=20Mk.*CardMini=E3=81=AE=E6=94=B9=E4=BF=AE=20(taiyme#289)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- idea/MkDisableSection.vue | 11 +++++--- .../MkCustomEmojiDetailedDialog.vue | 27 ++++++++++++++----- .../src/components/MkEmbedCodeGenDialog.vue | 11 +++++--- .../src/components/MkFlashPreview.vue | 10 ++++--- packages/frontend/src/components/MkFolder.vue | 9 +++++-- .../frontend/src/components/MkPostForm.vue | 21 ++++++++++----- packages/frontend/src/style.scss | 17 +++++++----- 7 files changed, 75 insertions(+), 31 deletions(-) diff --git a/idea/MkDisableSection.vue b/idea/MkDisableSection.vue index 360705071b..b9e964c400 100644 --- a/idea/MkDisableSection.vue +++ b/idea/MkDisableSection.vue @@ -34,8 +34,13 @@ defineProps<{ width: 100%; height: 100%; cursor: not-allowed; - --color: color(from var(--MI_THEME-error) srgb r g b / 0.25); - background-size: auto auto; - background-image: repeating-linear-gradient(135deg, transparent, transparent 10px, var(--color) 4px, var(--color) 14px); + background-image: repeating-linear-gradient( + 135deg, + transparent, + transparent 10px, + var(--c) 6px, + var(--c) 16px + ); + --c: color(from var(--MI_THEME-error) srgb r g b / 0.25); } diff --git a/packages/frontend/src/components/MkCustomEmojiDetailedDialog.vue b/packages/frontend/src/components/MkCustomEmojiDetailedDialog.vue index ecbee864dc..57dd5257df 100644 --- a/packages/frontend/src/components/MkCustomEmojiDetailedDialog.vue +++ b/packages/frontend/src/components/MkCustomEmojiDetailedDialog.vue @@ -83,12 +83,27 @@ function cancel() { diff --git a/packages/frontend/src/components/MkPostForm.vue b/packages/frontend/src/components/MkPostForm.vue index f2fe048449..947848b7f4 100644 --- a/packages/frontend/src/components/MkPostForm.vue +++ b/packages/frontend/src/components/MkPostForm.vue @@ -1197,15 +1197,22 @@ defineExpose({ min-height: 75px; max-height: 150px; overflow: auto; - background-size: auto auto; -} + background-image: repeating-linear-gradient( + 135deg, + transparent, + transparent 10px, + var(--c) 6px, + var(--c) 16px + ); -html[data-color-scheme=dark] .preview { - background-image: repeating-linear-gradient(135deg, transparent, transparent 5px, #0004 5px, #0004 10px); -} + &, + html[data-color-scheme=light] & { + --c: rgb(0 0 0 / 0.02); + } -html[data-color-scheme=light] .preview { - background-image: repeating-linear-gradient(135deg, transparent, transparent 5px, #00000005 5px, #00000005 10px); + html[data-color-scheme=dark] & { + --c: rgb(255 255 255 / 0.02); + } } .targetNote { diff --git a/packages/frontend/src/style.scss b/packages/frontend/src/style.scss index 4204c5af59..77ff0741b2 100644 --- a/packages/frontend/src/style.scss +++ b/packages/frontend/src/style.scss @@ -444,14 +444,17 @@ rt { box-shadow: 0 6px 16px #0007, 0 0 1px 1px #693410, inset 0 0 2px 1px #ce8a5c; border-radius: 10px; - --MI_THEME-bg: #F1E8DC; - --MI_THEME-fg: #693410; -} + &, + html[data-color-scheme=light] & { + --bg: #F1E8DC; + --fg: #693410; + } -html[data-color-scheme=dark] ._woodenFrame { - --MI_THEME-bg: #1d0c02; - --MI_THEME-fg: #F1E8DC; - --MI_THEME-panel: #192320; + html[data-color-scheme=dark] & { + --bg: #1d0c02; + --fg: #F1E8DC; + --panel: #192320; + } } ._woodenFrameH { From f6f96f24d1c4b0ae798ff6c4918bd95cd633ac87 Mon Sep 17 00:00:00 2001 From: kakkokari-gtyih <67428053+kakkokari-gtyih@users.noreply.github.com> Date: Sat, 2 Nov 2024 20:50:26 +0900 Subject: [PATCH 3/3] =?UTF-8?q?=E3=83=9E=E3=83=BC=E3=82=B8=E3=83=9F?= =?UTF-8?q?=E3=82=B9=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/frontend/src/pages/admin/roles.role.vue | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/frontend/src/pages/admin/roles.role.vue b/packages/frontend/src/pages/admin/roles.role.vue index aa2f6f8126..bdff1345ed 100644 --- a/packages/frontend/src/pages/admin/roles.role.vue +++ b/packages/frontend/src/pages/admin/roles.role.vue @@ -49,6 +49,7 @@ SPDX-License-Identifier: AGPL-3.0-only
Period: {{ i18n.ts.indefinitely }}
+