Kaynağa Gözat

提交代码

cl 3 hafta önce
ebeveyn
işleme
85b4eb3e06

+ 67 - 2
src/views/weatherHome/components/importantWeather.vue

@@ -4,7 +4,7 @@
             历史>
         </div>
         <weatherTitle :title="'重要天气'" refreshName="statisRefreshName"></weatherTitle>
-        <div v-for="(item, index) in getSignificantWeatherData" :key="index" class="weat-box">
+        <div v-for="(item, index) in getSignificantWeatherData" :key="index" class="weat-box1">
             <div>
                 <img src="/src/assets/newDp/img18.png">
                 <span>重要天气提醒</span>
@@ -37,6 +37,7 @@
                             <img src="/src/assets/newDp/img18.png">
                             <span>重要天气提醒</span>
                             <span>{{ item.year }}</span>
+                            <span style="margin:auto">发布时间:{{ item.time }}</span>
                             <span>{{ item.period }}</span>
                         </div>
                         <div class="text text-box">
@@ -130,7 +131,7 @@ onMounted(async () => {
 .weat-box-d{
     margin-top: 20px;
 }
-.weat-box {
+.weat-box1{
     &>div:nth-child(1) {
         display: inline-block;
         font-weight: bold;
@@ -194,6 +195,70 @@ onMounted(async () => {
         }
     }
 }
+.weat-box {
+    &>div:nth-child(1) {
+        display: inline-block;
+        font-weight: bold;
+        font-size: 16px;
+        color: #FFFFFF;
+        display: flex;
+
+        img {
+            display: inline-block;
+        }
+
+        span {
+            display: inline-block;
+        }
+
+        span:nth-child(2) {
+            margin-left: 20px;
+            position: relative;
+            top: 4px;
+        }
+
+        span:nth-child(3) {
+            display: inline-block;
+            position: relative;
+            top: 2px;
+        }
+
+        span:nth-child(5) {
+            height: 28px;
+            line-height: 28px;
+            width: 70px;
+            background-image: url('/src/assets/newDp/img16.png');
+            text-align: center;
+            font-size: 14px;
+            margin-left: auto;
+        }
+    }
+
+    .text {
+        font-size: 16px;
+        color: #FFFFFF;
+        // text-indent: 2em;
+        height: 120px;
+        overflow-y: auto;
+        margin: 10px 0px;
+        
+    }
+    .text-box{
+        // background-image: url('/src/assets/images/weatheHome/icon-bg-7.png');
+        // background-repeat: no-repeat;
+        // background-size: 100%;
+        // background-position: 0px;
+        position: relative;
+        height: initial;
+        padding-bottom: 20px;
+        img{
+            width: 100%;
+            position: absolute;
+            left: 0px;
+            bottom: 0px;
+        }
+    }
+}
 .toplist{
     height: calc(100% - 20px);
     overflow-y: auto;

+ 1 - 1
src/views/weatherHome/components/importantWeather2.vue

@@ -36,7 +36,7 @@
                         <div>
                             <img src="/src/assets/newDp/img18.png">
                             <span>突发事件提醒</span>
-                            <span></span>
+                            <span style="margin-left: 30px; margin:auto">发布时间:{{ item.time }}</span>
                             <span>{{ item.period }}</span>
                         </div>
                         <div class="text text-box">