diff --git a/ui/src/components/login-layout/index.vue b/ui/src/components/login-layout/index.vue index efd88c993..9d9b87dca 100644 --- a/ui/src/components/login-layout/index.vue +++ b/ui/src/components/login-layout/index.vue @@ -3,7 +3,7 @@
- + @@ -16,6 +16,7 @@ import { computed } from 'vue' import { getThemeImg } from '@/utils/theme' import useStore from '@/stores' +import { request } from '@/request' defineOptions({ name: 'LoginLayout' }) const { user } = useStore() @@ -31,15 +32,12 @@ const fileURL = computed(() => { } }) -const loginImageStyle = computed(() => { +const loginImage = computed(() => { if (user.themeInfo?.loginImage) { - return { - backgroundImage: `url(${fileURL.value})` - } + return `${fileURL.value}` } else { - return { - backgroundImage: `url(src/assets/theme/${getThemeImg(user.themeInfo?.theme)}.jpg)` - } + return new URL(`../../assets/theme/${getThemeImg(user.themeInfo?.theme)}.jpg`, import.meta.url) + .href } }) diff --git a/ui/src/layout/components/top-bar/avatar/AboutDialog.vue b/ui/src/layout/components/top-bar/avatar/AboutDialog.vue index c5bef4e56..fc8bd380a 100644 --- a/ui/src/layout/components/top-bar/avatar/AboutDialog.vue +++ b/ui/src/layout/components/top-bar/avatar/AboutDialog.vue @@ -2,7 +2,7 @@