Skip to content

Commit 05fbfbd

Browse files
committed
Fix comment sort switching data error
1 parent 909969f commit 05fbfbd

File tree

9 files changed

+332
-92
lines changed

9 files changed

+332
-92
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ tmp/
77
npm-debug.log
88
yarn-error.log
99
package-lock.json
10+
modify.log
1011

1112
# System/Editor directories and files
1213
.DS_Store

src/assets/css/style.scss

Lines changed: 154 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,6 @@ $succN: #2ecc71;
101101
.pg-nav-content {
102102
position: absolute;
103103
right: 0;
104-
top: 2.5rem;
105104
min-width: 7.5rem;
106105
opacity: 0;
107106
transform: translateY(50%);
@@ -125,70 +124,33 @@ $succN: #2ecc71;
125124
.fixed-footer {
126125
bottom: 0;
127126
}
128-
129-
/* loading */
130-
.page-loading {
127+
/* footer nav */
128+
.fixed-footer-nav {
131129
position: fixed;
132-
top: 0;
133-
width: 100%;
134-
height: 100%;
135-
background: rgba(0, 0, 0, 0.75);
136-
z-index: $z-lod;
137-
.v-dot1 {
138-
height: 60px;
139-
width: 60px;
140-
position: absolute;
141-
top: calc(50% - 30px);
142-
left: calc(50% - 30px);
143-
animation: v-dotRotate 2s 0s infinite linear;
144-
animation-fill-mode: forwards;
145-
.v-dot2 {
146-
background-color: rgb(93, 197, 150);
147-
height: 30px;
148-
width: 30px;
149-
border-radius: 100%;
150-
animation: v-dotBounce 2s 0s infinite linear;
151-
animation-fill-mode: forwards;
152-
position: absolute;
153-
top: 0;
154-
bottom: auto;
155-
}
156-
.v-dot3 {
157-
animation: v-dotBounce 2s -1s infinite linear;
158-
animation-fill-mode: forwards;
159-
position: absolute;
160-
top: auto;
161-
bottom: 0;
162-
background-color: rgb(93, 197, 150);
163-
height: 30px;
164-
width: 30px;
165-
border-radius: 100%;
130+
bottom: 0;
131+
left: 0;
132+
right: 0;
133+
z-index: $z-fix;
134+
background: #fff;
135+
padding: 10px;
136+
border-top: 1px solid #eee;
137+
> ul {
138+
display: flex;
139+
text-align: center;
140+
> li {
141+
width: 100%;
166142
}
167143
}
168144
}
169-
@keyframes v-dotRotate {
170-
100% {
171-
transform: rotate(360deg);
172-
}
173-
}
174-
@keyframes v-dotBounce {
175-
0%,
176-
100% {
177-
transform: scale(0);
178-
}
179-
50% {
180-
transform: scale(1.0);
181-
}
182-
}
183145

184146
/*-----------------------------------------------------------------------
185147
------------------------------ Home Style ------------------------------
186148
-----------------------------------------------------------------------*/
187149
.articles {
188150
.articles-nav {
189-
margin: 10px 0;
151+
margin: 0.625rem 0;
190152
padding: 0;
191-
box-shadow: 0 0px 5px rgba(0, 0, 0, 0.15);
153+
box-shadow: 0 0 0.3125rem rgba(0, 0, 0, 0.15);
192154
overflow: hidden;
193155
&::-webkit-scrollbar {
194156
display: none;
@@ -226,7 +188,7 @@ $succN: #2ecc71;
226188
height: 7.5rem;
227189
background-size: cover;
228190
background-position: center center;
229-
border-radius: 5px;
191+
border-radius: 0.3125rem;
230192
border: 1px solid #eee;
231193
}
232194
.cont-prev {
@@ -281,23 +243,23 @@ $succN: #2ecc71;
281243
color: #888;
282244
}
283245
.article-desc {
284-
padding: 15px 0;
246+
padding: 0.9375rem 0;
285247
color: #999;
286-
font-size: 15px;
248+
font-size: 0.9375rem;
287249
margin-bottom: 0;
288250
&:after {
289251
display: block;
290-
width: 160px;
291-
height: 4px;
292-
border-radius: 3px;
252+
width: 10rem;
253+
height: 0.25rem;
254+
border-radius: 0.1875rem;
293255
background: #efefef;
294256
content: "";
295257
margin-top: 1rem;
296258
}
297259
}
298260
.article-content {
299261
width: 100%;
300-
font-size: 14px;
262+
font-size: 0.875rem;
301263
> p {
302264
margin-bottom: 0.625rem;
303265
}
@@ -308,19 +270,123 @@ $succN: #2ecc71;
308270
.dp-highlighter {
309271
width: 100%;
310272
overflow-x: auto;
311-
margin: 15px 0;
273+
margin: 0.9375rem 0;
312274
ol {
313-
margin: 0 0 2px 15px;
275+
margin: 0 0 0.125rem 0.9375rem;
314276
li {
315277
white-space: nowrap;
316278
}
317279
}
318280
}
319281
}
282+
.article-protected {
283+
margin: 2.1875rem 0.625rem;
284+
padding: 1.5625rem 0.9375rem;
285+
border: 0.125rem dashed #0887e2;
286+
> p {
287+
color: #999;
288+
line-height: 1;
289+
margin: 0.3125rem 0;
290+
font-size: 0.875rem;
291+
text-align: right;
292+
}
293+
> input {
294+
position: relative;
295+
&::placeholder {
296+
color: #999;
297+
}
298+
&::before {
299+
content: "\e600";
300+
}
301+
}
302+
}
303+
.article-comments {
304+
> h3 {
305+
font-size: 1.125rem;
306+
margin-top: 2.1875rem;
307+
}
308+
ul {
309+
li {
310+
margin: 0.3125rem auto;
311+
padding: 0.3125rem 0;
312+
border-bottom: 1px solid #ccc;
313+
}
314+
}
315+
.comment-content {
316+
display: flex;
317+
.comment-avatar {
318+
text-align: center;
319+
width: 3.75rem;
320+
padding: 0 0.3125rem;
321+
img {
322+
display: inline-block;
323+
width: 3rem;
324+
height: 3rem;
325+
border-radius: 50%;
326+
border: 1px solid #eee;
327+
white-space: nowrap;
328+
text-overflow: clip;
329+
overflow: hidden;
330+
}6
331+
p {
332+
font-size: 0.875rem;
333+
white-space: nowrap;
334+
text-overflow: ellipsis;
335+
overflow-x: hidden;
336+
}
337+
}
338+
.comment-desc {
339+
width: calc(100% - 3.75rem);
340+
.comment-info {
341+
font-size: 0.75rem;
342+
color: #999;
343+
margin-top: 0.3125rem;
344+
span:first-child {
345+
font-size: 1rem;
346+
font-weight: bold;
347+
color: #222;
348+
}
349+
}
350+
.comment-response {
351+
min-height: 3rem;
352+
font-size: 0.875rem;
353+
color: #555;
354+
}
355+
}
356+
}
357+
}
358+
}
359+
.fixed-response {
360+
display: flex;
361+
.response-input {
362+
width: calc(100% - 2.875rem);
363+
input {
364+
border: none;
365+
box-shadow: none;
366+
border-radius: 0;
367+
border-bottom: 1px solid #aaa;
368+
&:focus {
369+
border-color: $MC;
370+
}
371+
}
372+
}
373+
.response-submit {
374+
button {
375+
background: none;
376+
line-height: 1;
377+
outline: none;
378+
&:active {
379+
color: $MC;
380+
}
381+
i {
382+
font-size: 22px;
383+
}
384+
}
385+
}
320386
}
321387

322388
/*-----------------------------------------------------------------------
323-
----------------------------- article Style -----------------------------
389+
------------------------------ topic Style ------------------------------
324390
-----------------------------------------------------------------------*/
325391
.topic {
326392
padding: 1.25rem 0;
@@ -440,7 +506,6 @@ $succN: #2ecc71;
440506
border-bottom: 1px solid #eee;
441507
}
442508
.comments-content {
443-
444509
ul {
445510
li {
446511
margin: 0.3125rem auto;
@@ -466,22 +531,43 @@ $succN: #2ecc71;
466531
}
467532
}
468533
.comment-desc {
469-
width: calc(100% - 60px);
534+
width: calc(100% - 3.75rem);
470535
.comment-response {
471536
min-height: 3rem;
472-
font-size: 14px;
537+
font-size: 0.875rem;
473538
color: #555;
474539
}
475540
.comment-info {
476541
font-size: 0.75rem;
477542
color: #999;
478-
margin-top: 5px;
543+
margin-top: 0.3125rem;
479544
}
480545
}
481546
}
482547
}
483548
}
484549

550+
/*-----------------------------------------------------------------------
551+
------------------------------- pages nav -------------------------------
552+
-----------------------------------------------------------------------*/
553+
.pages-nav {
554+
.prev-next {
555+
display: flex;
556+
border: 1px solid #eee;
557+
margin: 1.5625rem auto;
558+
.prev-page,
559+
.next-page {
560+
width: 50%;
561+
padding: 0.4375rem;
562+
text-align: center;
563+
background: #eee;
564+
&.empty {
565+
background: #fafafa;
566+
}
567+
}
568+
}
569+
}
570+
485571
/*-----------------------------------------------------------------------
486572
-------------------------- fixed compoment css --------------------------
487573
-----------------------------------------------------------------------*/

src/utils/routers.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ import tags from '../views/tags.vue';
1010
import tag from '../views/tag.vue';
1111
import media from '../views/media.vue';
1212
import comments from '../views/comments.vue';
13-
import login from '../views/login.vue';
13+
import login from '../views/oauth/login.vue';
14+
import register from '../views/oauth/register.vue';
1415
import member from '../views/member.vue';
1516

1617
Vue.use(Router);
@@ -62,6 +63,10 @@ export default new Router({
6263
path: '/login',
6364
component: login
6465
},
66+
{
67+
path: '/register',
68+
component: register
69+
},
6570
{
6671
path: '/member',
6772
name: 'member',

0 commit comments

Comments
 (0)