动态详情完成
This commit is contained in:
@@ -5,8 +5,8 @@
|
|||||||
<div class="user">
|
<div class="user">
|
||||||
<image class="userface" src="{{dyn.modules.module_author.face}}@65w_65h"></image>
|
<image class="userface" src="{{dyn.modules.module_author.face}}@65w_65h"></image>
|
||||||
<div class="userinfo">
|
<div class="userinfo">
|
||||||
<text class="username">{{ dyn.modules.module_author.name }}</text>
|
<text class="username" style="margin-bottom: 3px">{{ dyn.modules.module_author.name }}</text>
|
||||||
<text style="font-size: 18px; color: #5e5e5e; margin-top: 3px">
|
<text style="font-size: 18px; color: #5e5e5e" if="{{ dyn.modules.module_author.pub_time }}">
|
||||||
{{ dyn.modules.module_author.pub_time }}
|
{{ dyn.modules.module_author.pub_time }}
|
||||||
</text>
|
</text>
|
||||||
<text style="font-size: 18px; color: #5e5e5e">
|
<text style="font-size: 18px; color: #5e5e5e">
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
.user {
|
.user {
|
||||||
align-items: center;
|
align-items: center;
|
||||||
width: 76%;
|
.w(76%);
|
||||||
.flex-row(10px, #00000000);
|
.flex-row(10px, #00000000);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -34,7 +34,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.ctx {
|
.ctx {
|
||||||
width: 76%;
|
.w(76%);
|
||||||
.flex-column(10px, #00000000);
|
.flex-column(10px, #00000000);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -42,4 +42,22 @@
|
|||||||
font-size: 22px;
|
font-size: 22px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ctx-forwarded-box {
|
||||||
|
.w(100%);
|
||||||
|
.radius(25px);
|
||||||
|
.flex-column(10px);
|
||||||
|
margin-top: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.txt-at {
|
||||||
|
color: #2886f8;
|
||||||
|
max-width: 200px;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
}
|
||||||
|
|
||||||
|
.ctx-forwarded-txt {
|
||||||
|
.font-semibold();
|
||||||
|
font-size: 18px;
|
||||||
}
|
}
|
||||||
@@ -8,8 +8,8 @@
|
|||||||
<div class="user">
|
<div class="user">
|
||||||
<image class="userface" src="{{dyn.modules.module_author.face}}@75w_75h"></image>
|
<image class="userface" src="{{dyn.modules.module_author.face}}@75w_75h"></image>
|
||||||
<div class="userinfo">
|
<div class="userinfo">
|
||||||
<text class="username">{{ dyn.modules.module_author.name }}</text>
|
<text class="username" style="margin-bottom: 3px">{{ dyn.modules.module_author.name }}</text>
|
||||||
<text style="font-size: 18px; color: #5e5e5e; margin-top: 3px">
|
<text style="font-size: 18px; color: #5e5e5e;" if="{{ dyn.modules.module_author.pub_time }}">
|
||||||
{{ dyn.modules.module_author.pub_time }}
|
{{ dyn.modules.module_author.pub_time }}
|
||||||
</text>
|
</text>
|
||||||
<text style="font-size: 18px; color: #5e5e5e">
|
<text style="font-size: 18px; color: #5e5e5e">
|
||||||
@@ -21,10 +21,23 @@
|
|||||||
<!-- 动态文本desc 不为空时渲染 -->
|
<!-- 动态文本desc 不为空时渲染 -->
|
||||||
<text class="dyn-content-text" if="{{dyn.modules.module_dynamic.desc.text}}">{{ dyn.modules.module_dynamic.desc.text }}</text>
|
<text class="dyn-content-text" if="{{dyn.modules.module_dynamic.desc.text}}">{{ dyn.modules.module_dynamic.desc.text }}</text>
|
||||||
|
|
||||||
|
<!-- 纯文本动态 不展示任何内容 -->
|
||||||
|
<text if="{{dyn.type == 'DYNAMIC_TYPE_WORD'}}"></text>
|
||||||
<!-- 图文动态 直接列表图片渲染 -->
|
<!-- 图文动态 直接列表图片渲染 -->
|
||||||
<online-image if="{{dyn.type == 'DYNAMIC_TYPE_DRAW'}}" for="{{dyn.modules.module_dynamic.major.draw.items}}" src="{{$item.src}}@350w" loading-anim="true"></online-image>
|
<online-image elif="{{dyn.type == 'DYNAMIC_TYPE_DRAW'}}" for="{{dyn.modules.module_dynamic.major.draw.items}}" src="{{$item.src}}@350w" loading-anim="true"></online-image>
|
||||||
<!-- 视频投稿动态 展示视频跳转 -->
|
<!-- 视频投稿动态 展示视频跳转 -->
|
||||||
<videoshow if="{{dyn.type == 'DYNAMIC_TYPE_AV'}}" bvid="{{dyn.modules.module_dynamic.major.archive.bvid}}"></videoshow>
|
<videoshow elif="{{dyn.type == 'DYNAMIC_TYPE_AV'}}" bvid="{{dyn.modules.module_dynamic.major.archive.bvid}}"></videoshow>
|
||||||
|
<!-- 转发动态 显示原动态简略信息 -->
|
||||||
|
<div elif="{{dyn.type == 'DYNAMIC_TYPE_FORWARD'}}" class="ctx-forwarded-box" @click="JumpToOrigDetail">
|
||||||
|
<div style="flex-direction: row">
|
||||||
|
<text class="ctx-forwarded-txt">转发自</text>
|
||||||
|
<text class="ctx-forwarded-txt txt-at"> @{{dyn.orig.modules.module_author.name}} </text>
|
||||||
|
<text class="ctx-forwarded-txt">的动态:</text>
|
||||||
|
</div>
|
||||||
|
<text class="ctx-forwarded-txt" if="{{dyn.orig.modules.module_dynamic.desc.text}}">{{dyn.orig.modules.module_dynamic.desc.text}}</text>
|
||||||
|
<text class="ctx-forwarded-txt" else>[暂无文本内容]</text>
|
||||||
|
<text class="ctx-forwarded-txt" style="color: gray;">点击可查看详情</text>
|
||||||
|
</div>
|
||||||
|
|
||||||
<text else>该类型动态暂不支持展示</text>
|
<text else>该类型动态暂不支持展示</text>
|
||||||
</div>
|
</div>
|
||||||
@@ -33,11 +46,22 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import router from "@system.router";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
public: {
|
public: {
|
||||||
dyn: null,
|
dyn: null,
|
||||||
pubAction: "N/A"
|
pubAction: "N/A"
|
||||||
},
|
},
|
||||||
|
JumpToOrigDetail(){
|
||||||
|
router.push({
|
||||||
|
uri: "pages/app/features/dynamic/detail",
|
||||||
|
params: {
|
||||||
|
dyn: this.dyn.orig,
|
||||||
|
pubAction: "发布了动态"
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
onInit(){
|
onInit(){
|
||||||
// 来自子组件push的object传递会变成字符串
|
// 来自子组件push的object传递会变成字符串
|
||||||
// 因此需要进行类型检查和手动parse
|
// 因此需要进行类型检查和手动parse
|
||||||
|
|||||||
Reference in New Issue
Block a user