2626 />
2727
2828 <!-- 标题文字 -->
29- <a class =" u-title" :style =" hightStyle" :href =" postLink(item.id)" :target =" target" v-html =" highlightText(item.title)" >
29+ <a
30+ class =" u-title"
31+ :style =" hightStyle"
32+ :href =" postLink(item.id)"
33+ :target =" target"
34+ v-html =" highlightText(item.title)"
35+ >
3036 </a >
3137
3238 <!-- 角标 -->
3541 </span> -->
3642
3743 <span class =" u-push" v-if =" hasPermission" >
38- <time v-if =" showPushDate" class =" u-push__time" :class =" {'is-recent': isRecent()}" >{{ pushDate }} 已推送</time >
39- <el-button class =" u-push__btn" size =" mini" type =" warning" @click =" onPush" icon =" el-icon-s-promotion" >推送</el-button >
44+ <time v-if =" showPushDate" class =" u-push__time" :class =" { 'is-recent': isRecent() }"
45+ >{{ pushDate }} 已推送</time
46+ >
47+ <el-button class =" u-push__btn" size =" mini" type =" warning" @click =" onPush" icon =" el-icon-s-promotion"
48+ >推送</el-button
49+ >
4050 </span >
4151 </h2 >
4252
6474 </div >
6575 <div class =" u-metalist u-topics" >
6676 <strong >标签</strong >
67- <template v-if =" ~~ item .collection_id " >
68- <a :href =" `/collection/${item.collection_id}`" target =" _blank"
69- >《{{ item.collection && item.collection.title }}》</a
70- >
71- </template >
7277 <span class =" m-topic-tag" >
73- <span class =" u-tag" >{{ showCategory(item.category) }}</span >
78+ <a class =" u-tag" :href =" `/community?category=${item.category}&page=1`" target =" _blank" >{{
79+ showCategory(item.category)
80+ }}</a >
7481 <template v-if =" item .color_tag " >
7582 <a
7683 class =" u-tag"
7784 v-for =" (_item, index) in item.color_tag"
7885 :key =" index"
7986 :style =" { backgroundColor: _item.color }"
8087 :href =" getLink(_item)"
88+ target =" _blank"
8189 >
8290 {{ _item.label }}
8391 </a >
8492 </template >
85- <span class =" u-tag u-star-tag" v-if =" item.is_star" >精选</span >
93+ <!-- <span class="u-tag u-star-tag" v-if="item.is_star">精选</span> -->
94+ <template v-if =" ~~ item .collection_id " >
95+ <a class =" u-tag u-tag--collection" :href =" `/collection/${item.collection_id}`" target =" _blank" >{{
96+ item.collection && item.collection.title.replace(/(^《|》$)/g, "")
97+ }}</a >
98+ </template >
8699 </span >
87100 </div >
88101 </div >
@@ -120,7 +133,7 @@ import bus from "@/utils/bus";
120133import { getSkinJson } from " @/service/community" ;
121134const appKey = " community" ;
122135const skinKey = " community_topic_skin" ;
123- import {tabsMap } from " @/assets/data/community_category.js" ;
136+ import { tabsMap } from " @/assets/data/community_category.js" ;
124137
125138export default {
126139 name: " ListItem" ,
@@ -217,7 +230,7 @@ export default {
217230 post_title: this .item .title ,
218231 ID : this .item .id ,
219232 author: this .item ? .ext_user_info ? .display_name || " 匿名" ,
220- }
233+ };
221234 bus .emit (" design-task" , data);
222235 },
223236 postLink: function (val ) {
@@ -246,7 +259,7 @@ export default {
246259 const url = new URL (window .location .href );
247260 url .searchParams .set (" tag" , item .label );
248261 return url .toString ();
249- }
262+ },
250263 },
251264 filters: {
252265 authorLink,
@@ -283,8 +296,8 @@ export default {
283296 border: 1px solid #fff ! important;
284297 background- color: #fff;
285298
286- & : hover{
287- border: 1px solid @color- link ! important;
299+ & : hover {
300+ border: 1px solid @color- link ! important;
288301 }
289302
290303 .u - post {
@@ -303,15 +316,15 @@ export default {
303316 align- items: center;
304317 }
305318}
306- @media screen and (max - width : @phone ){
307- .m - topic- list .u - community- item{
308- .u - post{
319+ @media screen and (max - width : @phone ) {
320+ .m - topic- list .u - community- item {
321+ .u - post {
309322 .flex ;
310323 align- items: flex- start;
311324 }
312- .u - title{
325+ .u - title {
313326 .pr ;
314- top: - 3px ;
327+ top: - 3px ;
315328 }
316329 }
317330}
0 commit comments