微信小程序新闻详情页组件引用问题

This commit is contained in:
77 2024-08-08 13:40:17 +08:00
parent 5f13c4efae
commit 8d2565127c
3 changed files with 58 additions and 4 deletions

View File

@ -88,7 +88,8 @@
"style" : "style" :
{ {
"navigationBarTitleText" : "详情", "navigationBarTitleText" : "详情",
"enablePullDownRefresh" : false "enablePullDownRefresh" : true,
"navigationStyle": "default"
} }
} }
], ],

View File

@ -0,0 +1,52 @@
<!-- 商品详情描述卡片 -->
<template>
<view class="detail-content-card bg-white ss-m-x-20 ss-p-t-20">
<view class="card-header ss-flex ss-col-center ss-m-b-30 ss-m-l-20">
<view class="line"></view>
<view class="title ss-m-l-20 ss-m-r-20">详情</view>
</view>
<view class="card-content">
<mp-html :content="content" />
</view>
</view>
</template>
<script setup>
import sheep from '@/sheep';
const { safeAreaInsets } = sheep.$platform.device;
const props = defineProps({
content: {
type: String,
default: '',
},
});
</script>
<style lang="scss" scoped>
.detail-content-card {
.card-header {
.line {
width: 6rpx;
height: 30rpx;
background: linear-gradient(180deg, var(--ui-BG-Main) 0%, var(--ui-BG-Main-gradient) 100%);
border-radius: 3rpx;
}
.title {
font-size: 30rpx;
font-weight: bold;
}
.des {
font-size: 24rpx;
color: $dark-9;
}
.more-btn {
font-size: 24rpx;
color: var(--ui-BG-Main);
}
}
}
</style>

View File

@ -10,10 +10,11 @@
</template> </template>
<script setup> <script setup>
import detailContentCard from '@/pages/goods/components/detail/detail-content-card.vue';
import { onLoad, onPageScroll } from '@dcloudio/uni-app'; import { onLoad, onPageScroll } from '@dcloudio/uni-app';
import { ref, reactive, unref } from 'vue'; import { ref, reactive, unref, createApp } from 'vue';
import AddressApi from '@/sheep/api/member/address'; import AddressApi from '../../sheep/api/member/address';
import detailContentCard from './detail-content-card.vue';
const state = reactive({ const state = reactive({
model: [], model: [],
}); });