浏览代码

修改bug

master
suomingxiang 2 个月前
父节点
当前提交
dd35f37da7
共有 2 个文件被更改,包括 29 次插入15 次删除
  1. 18
    8
      src/pages/articleDetails/index.less
  2. 11
    7
      src/pages/common/js/Common.js

+ 18
- 8
src/pages/articleDetails/index.less 查看文件

70
             margin-top: 80px;
70
             margin-top: 80px;
71
             .title{
71
             .title{
72
                 font-weight: bold;
72
                 font-weight: bold;
73
-                font-size: 40px;
73
+                font-size: 38px;
74
                 color: #333333;
74
                 color: #333333;
75
-                text-align: left;
75
+                text-align: center;
76
                 margin-bottom: 80px;
76
                 margin-bottom: 80px;
77
             }
77
             }
78
             .date{
78
             .date{
97
             width: 100%;
97
             width: 100%;
98
             background-color: #EAECEF;
98
             background-color: #EAECEF;
99
             img{
99
             img{
100
-                width: 100%;
101
-                height: 731px;
100
+                // width: 100%;
101
+                width: auto;
102
+                // height: 731px;
102
             }
103
             }
103
         }
104
         }
104
         .detail_footer{
105
         .detail_footer{
119
         }
120
         }
120
         
121
         
121
     }
122
     }
123
+    img{
124
+        width: auto;
125
+    }
126
+    p{
127
+        white-space: pre-wrap;
128
+    }
122
 }
129
 }
123
 a{
130
 a{
124
     display: inline-block;
131
     display: inline-block;
125
 }
132
 }
126
 
133
 
127
-.main img{
128
-    width: auto !important;
129
-}
130
 .ql-align-center{
134
 .ql-align-center{
131
     text-align: center;
135
     text-align: center;
132
 }
136
 }
137
+.ql-align-right{
138
+    text-align: right;
139
+}
133
 @media screen and (min-width: 801px) and (max-width: 1400px) {
140
 @media screen and (min-width: 801px) and (max-width: 1400px) {
134
     .main{
141
     .main{
135
         
142
         
216
                 background-color: #EAECEF;
223
                 background-color: #EAECEF;
217
                 img{
224
                 img{
218
                     width: 100%;
225
                     width: 100%;
219
-                    height: 40.125vw;
226
+                    // height: 40.125vw;
220
                 }
227
                 }
221
             }
228
             }
222
             .detail_footer{
229
             .detail_footer{
234
                 }
241
                 }
235
             }
242
             }
236
         }
243
         }
244
+        img{
245
+            max-width: 100%;
246
+        }
237
     }
247
     }
238
 }
248
 }

+ 11
- 7
src/pages/common/js/Common.js 查看文件

149
 
149
 
150
     try {
150
     try {
151
       let logo = document.querySelector(".headerPC .logo");
151
       let logo = document.querySelector(".headerPC .logo");
152
-      logo.addEventListener("click", (e) => {
153
-        window.location.href = "./index.html"
154
-      });
152
+      if(logo){
153
+        logo.addEventListener("click", (e) => {
154
+          window.location.href = "./index.html"
155
+        });
156
+      }
155
   
157
   
156
       let logos = document.querySelector(".headerPC .logos");
158
       let logos = document.querySelector(".headerPC .logos");
157
-      logos.addEventListener("click", (e) => {
158
-        window.location.href = "../index.html"
159
-      });
159
+      if(logos){
160
+        logos.addEventListener("click", (e) => {
161
+          window.location.href = "../index.html"
162
+        });
163
+      }
160
     } catch (error) {
164
     } catch (error) {
161
-      
165
+      console.log(error)
162
     }
166
     }
163
    
167
    
164
 
168
 

正在加载...
取消
保存