diff --git a/src/App.vue b/src/App.vue index 644d80a737..e68d1a22b7 100644 --- a/src/App.vue +++ b/src/App.vue @@ -20,6 +20,7 @@ import useHtmlDataset from '/@/composables/document/useHtmlDataset' import { useThemeVariables } from '/@/composables/document/useThemeVariables' import { useBeforeUnload } from '/@/composables/dom/useBeforeUnload' import useResponsive from '/@/composables/useResponsive' +import { updateStampShadowTheme } from '/@/lib/stampShadowDirective' import { useBrowserSettings } from '/@/store/app/browserSettings' import { useThemeSettings } from '/@/store/app/themeSettings' import { useTts } from '/@/store/app/tts' @@ -54,6 +55,12 @@ const useThemeObserver = () => { const stampEdge = computed(() => currentTheme.value.specific.stampEdgeEnable) useHtmlDataset('stampEdge', stampEdge) + + watch( + currentTheme, + theme => updateStampShadowTheme(theme.specific.stampEdgeEnable), + { immediate: true, flush: 'post' } + ) } const useEcoModeObserver = () => { diff --git a/src/components/Main/NavigationBar/EphemeralNavigationContent/DraftList/DraftListDetailsPanelChannel.vue b/src/components/Main/NavigationBar/EphemeralNavigationContent/DraftList/DraftListDetailsPanelChannel.vue index 7a42f862c4..9567b8244f 100644 --- a/src/components/Main/NavigationBar/EphemeralNavigationContent/DraftList/DraftListDetailsPanelChannel.vue +++ b/src/components/Main/NavigationBar/EphemeralNavigationContent/DraftList/DraftListDetailsPanelChannel.vue @@ -4,6 +4,7 @@
channelIdToLink(props.channelId) ?? '') const hasAttachments = computed(() => props.state.attachments.length > 0) -const renderedContent = ref() +const renderedContent = ref() watchEffect(async () => { const { renderedText } = await renderInline(props.state.text) renderedContent.value = renderedText diff --git a/src/components/UI/AStamp.vue b/src/components/UI/AStamp.vue index 264837e2fd..2bc15ad771 100644 --- a/src/components/UI/AStamp.vue +++ b/src/components/UI/AStamp.vue @@ -2,7 +2,10 @@
stampsMap.value.get(props.stampId)?.name ?? 'unknown stamp' -) +const stamp = computed(() => stampsMap.value.get(props.stampId)) +const name = computed(() => stamp.value?.name ?? 'unknown stamp') const imageUrl = computed(() => { - const fileId = stampsMap.value.get(props.stampId)?.fileId + const fileId = stamp.value?.fileId return fileId ? buildFilePath(fileId) : '' }) @@ -58,11 +61,5 @@ const containerStyle = computed(() => ({ .img { max-height: 100%; margin: auto; - html[data-stamp-edge='true'] & { - filter: drop-shadow(0.1px 0.1px 0 rgb(255, 255, 255, 0.1)) - drop-shadow(0.1px -0.1px 0 rgb(255, 255, 255, 0.1)) - drop-shadow(-0.1px 0.1px 0 rgb(255, 255, 255, 0.1)) - drop-shadow(-0.1px -0.1px 0 rgb(255, 255, 255, 0.1)); - } } diff --git a/src/components/UI/MarkdownContent.vue b/src/components/UI/MarkdownContent.vue index 8b63786af7..5794589d82 100644 --- a/src/components/UI/MarkdownContent.vue +++ b/src/components/UI/MarkdownContent.vue @@ -1,6 +1,7 @@