feat: 长文本组件的详情页面调整
This commit is contained in:
@@ -32,15 +32,11 @@
|
||||
"navigationBarBackgroundColor": "#FFFFFF",
|
||||
"navigationBarTextStyle": "black"
|
||||
}
|
||||
}
|
||||
,
|
||||
},
|
||||
{
|
||||
"path": "pages/long-answer/index",
|
||||
"style": {
|
||||
"navigationStyle": "custom",
|
||||
"backgroundColor": "#FFFFFF",
|
||||
"navigationBarBackgroundColor": "#FFFFFF",
|
||||
"navigationBarTextStyle": "black"
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
}
|
||||
],
|
||||
|
||||
@@ -1,9 +1,16 @@
|
||||
<template>
|
||||
<view class="bg-F5F7FA flex flex-col h-screen overflow-hidden">
|
||||
<TopNavBar title="详情" backgroundColor="transparent" />
|
||||
<view class="flex-full overflow-hidden scroll-y p-12 border-box">
|
||||
<ChatMarkdown :text="answerText" />
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
<script setup>
|
||||
import TopNavBar from "@/components/TopNavBar/index.vue";
|
||||
import ChatMarkdown from "../index/components/chat/ChatMarkdown/index.vue";
|
||||
import { defineProps, onLoad } from "vue";
|
||||
import { defineProps, ref } from "vue";
|
||||
import { onLoad } from "@dcloudio/uni-app";
|
||||
|
||||
const props = defineProps({
|
||||
answerText: {
|
||||
@@ -12,8 +19,10 @@ const props = defineProps({
|
||||
}
|
||||
});
|
||||
|
||||
const answerText = ref(props.answerText || "");
|
||||
|
||||
onLoad(({ message = "" }) => {
|
||||
props.answerText = decodeURIComponent(message);
|
||||
answerText.value = decodeURIComponent(message);
|
||||
});
|
||||
|
||||
</script>
|
||||
Reference in New Issue
Block a user