diff --git a/src/pages/index/components/chat/ChatTopNavBar/index.vue b/src/pages/index/components/chat/ChatTopNavBar/index.vue index 8c08e0c..99702df 100644 --- a/src/pages/index/components/chat/ChatTopNavBar/index.vue +++ b/src/pages/index/components/chat/ChatTopNavBar/index.vue @@ -5,18 +5,11 @@ - - + + {{ config.name }} @@ -32,22 +25,31 @@ import { getCurrentConfig } from "@/constant/base"; const props = defineProps({ mainPageDataModel: { type: Object, - default: () => ({}), + default: () => ({ + initPageImages: {}, + }), }, }); +const initPageImages = computed(() => { + return props.mainPageDataModel?.initPageImages || {}; +}); + const show = ref(false); const config = getCurrentConfig(); const getStyle = computed(() => { - return { - "--ipSmallImageStep": config.ipSmallImageStep, - "--ipSmallImageHeight": config.ipSmallImageHeight, - "--ipSmallTime": config.ipSmallTime, - backgroundImage: `url(${config.ipSmallImage})`, + const images = initPageImages.value; + const style = { + "--ipSmallImageStep": images.ipSmallImageStep ?? config.ipSmallImageStep, + "--ipSmallImageHeight": images.ipSmallImageHeight ?? config.ipSmallImageHeight, + "--ipSmallTime": images.ipSmallTime ?? config.ipSmallTime, + backgroundImage: `url(${images.ipSmallImage ?? config.ipSmallImage})`, backgroundRepeat: "no-repeat", backgroundSize: "32px auto", backgroundPosition: "0 0", }; + console.log("top nav bar image style:", style); + return style; }); const showDrawer = () => uni.$emit("SHOW_DRAWER"); diff --git a/src/pages/index/components/chat/ChatTopWelcome/index.vue b/src/pages/index/components/chat/ChatTopWelcome/index.vue index eecbfc8..7c03319 100644 --- a/src/pages/index/components/chat/ChatTopWelcome/index.vue +++ b/src/pages/index/components/chat/ChatTopWelcome/index.vue @@ -2,13 +2,9 @@ v