فهرست منبع

详情页推荐资讯

Jing 4 روز پیش
والد
کامیت
639e78a9eb

+ 1 - 1
.nuxt/manifest/latest.json

@@ -1 +1 @@
-{"id":"2fa3d237-e010-4c9b-94ff-617137ed39ca","timestamp":1754015951375}
+{"id":"4048dcd7-0889-45d1-a989-1804f0136117","timestamp":1754619448493}

+ 0 - 1
.nuxt/manifest/meta/2fa3d237-e010-4c9b-94ff-617137ed39ca.json

@@ -1 +0,0 @@
-{"id":"2fa3d237-e010-4c9b-94ff-617137ed39ca","timestamp":1754015951375,"matcher":{"static":{},"wildcard":{},"dynamic":{}},"prerendered":[]}

+ 1 - 0
.nuxt/manifest/meta/4048dcd7-0889-45d1-a989-1804f0136117.json

@@ -0,0 +1 @@
+{"id":"4048dcd7-0889-45d1-a989-1804f0136117","timestamp":1754619448493,"matcher":{"static":{},"wildcard":{},"dynamic":{}},"prerendered":[]}

+ 1 - 1
.nuxt/tsconfig.json

@@ -102,7 +102,7 @@
         "./imports"
       ],
       "#app-manifest": [
-        "./manifest/meta/2fa3d237-e010-4c9b-94ff-617137ed39ca.json"
+        "./manifest/meta/4048dcd7-0889-45d1-a989-1804f0136117.json"
       ],
       "#components": [
         "./components"

+ 72 - 0
assets/css/detail.less

@@ -110,6 +110,7 @@
                 font-size: 20px;
                 line-height: 38px;
                 margin-bottom: 30px;
+                min-height: 300px;
 
                 ul>li img {
                     width: 885px;
@@ -165,6 +166,77 @@
                     line-height: 30px;
                 }
             }
+
+            .recommendRead {
+                width: 900px;
+                margin: 30px 0px;
+
+                .recommendReadTitle {
+                    width: 100px;
+                    font-family: Microsoft YaHei, Microsoft YaHei;
+                    font-weight: bold;
+                    font-size: 22px;
+                    color: #489D97;
+                    margin: 10px 0 20px;
+                    position: relative;
+                    border-left: #489D97 5px solid;
+                    padding-left: 15px;
+
+                    em {
+                        display: inline-block;
+                        width: 8px;
+                        height: 8px;
+                        border-radius: 4px;
+                        background-color: #a01c0e;
+                        position: absolute;
+                        top: 6px;
+                        right: 8px;
+                    }
+                }
+
+                .recommendReadList {
+                    min-height: 155px;
+                    margin-top: 30px;
+                    padding-bottom: 10px;
+                    font-size: 20px;
+                    border-bottom: 1px solid #D9D9D9;
+
+                    .recommendReadListTitle {
+                        margin-top: 25px;
+                        width: 900px;
+                        color: #333333;
+
+                        a {
+                            width: 700px;
+                            color: #333333;
+                            white-space: nowrap;
+                            overflow: hidden;
+                            text-overflow: ellipsis;
+                        }
+
+                        span {
+                            float: right;
+                        }
+                    }
+
+                    .recommendReadListTitle:hover a {
+                        color: #489d97;
+                    }
+
+                    .recommendReadListTitle:nth-child(1) {
+                        font-weight: bold;
+                    }
+
+                    .recommendReadListTitle:nth-child(1)::after {
+                        content: "热";
+                        margin-left: 13px;
+                        background: #ffb302;
+                        color: #fff;
+                        font-size: 14px;
+                        padding: 0px 2px;
+                    }
+                }
+            }
         }
 
         .innerRight {

+ 15 - 0
pages/[dir]/[dir]/[id].vue

@@ -48,6 +48,21 @@
                 <div v-if="articleChoice">
                     <HomeSurveyvote></HomeSurveyvote>
                 </div>
+                <!-- 推荐阅读 -->
+                <div class="recommendRead" v-if="newsDetail.commendArticle != false">
+                    <div class="recommendReadTitle">
+                        推荐阅读
+                    </div>
+                    <div class="recommendReadList">
+                        <div class="recommendReadListTitle" v-for="(item, index) in newsDetail.commendArticle"
+                            :key="item.id">
+                            <a :href="`/${item.alias_pinyin}/${item.id}.html`" v-if="index < 3">
+                                {{ item.title }}
+                            </a>
+                            <span v-if="index < 3">{{ getTime(item.created_at, "month", 1) }}</span>
+                        </div>
+                    </div>
+                </div>
             </div>
             <div class="innerRight">
                 <!-- 热点资讯1 -->

+ 15 - 0
pages/[dir]/[id].vue

@@ -46,6 +46,21 @@
                 <div v-if="articleChoice">
                     <HomeSurveyvote></HomeSurveyvote>
                 </div>
+                <!-- 推荐阅读 -->
+                <div class="recommendRead" v-if="newsDetail.commendArticle != false">
+                    <div class="recommendReadTitle">
+                        推荐阅读
+                    </div>
+                    <div class="recommendReadList">
+                        <div class="recommendReadListTitle" v-for="(item, index) in newsDetail.commendArticle"
+                            :key="item.id">
+                            <a :href="`/${item.alias_pinyin}/${item.id}.html`" v-if="index < 3">
+                                {{ item.title }}
+                            </a>
+                            <span v-if="index < 3">{{ getTime(item.created_at, "month", 1) }}</span>
+                        </div>
+                    </div>
+                </div>
             </div>
             <div class="innerRight">
                 <!-- 热点资讯1 -->