feat(文章组件): 添加国内新闻处理逻辑
为文章组件添加 isDomestic 属性,用于控制国内新闻的显示逻辑 调整首页搜索框和国内新闻列表的显示条件及间距
This commit is contained in:
parent
d74ce73971
commit
cda80c62d6
|
|
@ -8,7 +8,7 @@
|
||||||
</text>
|
</text>
|
||||||
|
|
||||||
<view class="author">
|
<view class="author">
|
||||||
<view class="name">
|
<view class="name" v-if="!isDomestic">
|
||||||
<text class="text">来源:</text>
|
<text class="text">来源:</text>
|
||||||
<text class="text">{{ props.data.tag }}</text>
|
<text class="text">{{ props.data.tag }}</text>
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -53,7 +53,10 @@
|
||||||
<!-- 两个标签 end -->
|
<!-- 两个标签 end -->
|
||||||
|
|
||||||
<!-- 摘要 -->
|
<!-- 摘要 -->
|
||||||
<view :class="['desc', isLogin ? '' : 'mohu']" v-if="props.data.summary">
|
<view
|
||||||
|
:class="['desc', isLogin ? '' : 'mohu']"
|
||||||
|
v-if="props.data.summary && !isDomestic"
|
||||||
|
>
|
||||||
<!-- <view class="bill_icon"></view> -->
|
<!-- <view class="bill_icon"></view> -->
|
||||||
{{ props.data.summary }}
|
{{ props.data.summary }}
|
||||||
</view>
|
</view>
|
||||||
|
|
@ -100,6 +103,10 @@ const props = defineProps({
|
||||||
type: Object,
|
type: Object,
|
||||||
default: () => {},
|
default: () => {},
|
||||||
},
|
},
|
||||||
|
isDomestic: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
});
|
});
|
||||||
const tagList1 = ref([
|
const tagList1 = ref([
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -37,7 +37,7 @@
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<!-- 文章正文 start -->
|
<!-- 文章正文 start -->
|
||||||
<Article :data="data" />
|
<Article :data="data" :isDomestic="isDomestic" />
|
||||||
<!-- 分割 -->
|
<!-- 分割 -->
|
||||||
<view class="line"></view>
|
<view class="line"></view>
|
||||||
<!-- 推荐栏目 -->
|
<!-- 推荐栏目 -->
|
||||||
|
|
|
||||||
|
|
@ -45,7 +45,7 @@
|
||||||
>
|
>
|
||||||
</image>
|
</image>
|
||||||
|
|
||||||
<view class="sreach" @click="goSreach">
|
<view class="sreach" @click="goSreach" v-if="tabIndex == 0">
|
||||||
<view class="sreach_icon">
|
<view class="sreach_icon">
|
||||||
<image
|
<image
|
||||||
src="https://cankao.obs.cn-east-3.myhuaweicloud.com/mini/newmini/icon_search_line.png"
|
src="https://cankao.obs.cn-east-3.myhuaweicloud.com/mini/newmini/icon_search_line.png"
|
||||||
|
|
@ -77,7 +77,7 @@
|
||||||
<RankListMini :newsList="newsList"></RankListMini>
|
<RankListMini :newsList="newsList"></RankListMini>
|
||||||
</view>
|
</view>
|
||||||
<!-- 列表区域 -->
|
<!-- 列表区域 -->
|
||||||
<view style="margin-top: 30rpx" v-if="tabIndex == 2">
|
<view style="margin-top: 50rpx" v-if="tabIndex == 2">
|
||||||
<Domestic />
|
<Domestic />
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue