优化布局
This commit is contained in:
parent
595c1c8879
commit
c9ad72dbe0
@ -15,9 +15,8 @@
|
|||||||
</head>
|
</head>
|
||||||
<style>
|
<style>
|
||||||
body{box-sizing: border-box;min-width: 200px;max-width: 900px;margin: 20px auto;padding: 45px;font-size: 16px;font-family: sans-serif;line-height: 1.25;}
|
body{box-sizing: border-box;min-width: 200px;max-width: 900px;margin: 20px auto;padding: 45px;font-size: 16px;font-family: sans-serif;line-height: 1.25;}
|
||||||
.avatar {transition: 0.8s;}
|
|
||||||
.avatar:hover {transform: scale(1.15) rotate(360deg);}
|
|
||||||
#header{display:flex;padding-bottom:8px;border-bottom: 1px solid var(--borderColor-muted, var(--color-border-muted));margin-bottom: 16px;}
|
#header{display:flex;padding-bottom:8px;border-bottom: 1px solid var(--borderColor-muted, var(--color-border-muted));margin-bottom: 16px;}
|
||||||
|
#content {width:100%;}
|
||||||
#footer {margin-top:64px; text-align: center;font-size: small;}
|
#footer {margin-top:64px; text-align: center;font-size: small;}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@ -5,6 +5,8 @@
|
|||||||
|
|
||||||
{% block style %}
|
{% block style %}
|
||||||
<style>
|
<style>
|
||||||
|
.avatar {transition: 0.8s;}
|
||||||
|
.avatar:hover {transform: scale(1.15) rotate(360deg);}
|
||||||
h1 a:not([href]){color:inherit;text-decoration:none;vertical-align: bottom;font-size:40px;font-family:Monaco;}
|
h1 a:not([href]){color:inherit;text-decoration:none;vertical-align: bottom;font-size:40px;font-family:Monaco;}
|
||||||
.title-right{display:flex;margin:auto 0 0 auto;}
|
.title-right{display:flex;margin:auto 0 0 auto;}
|
||||||
.title-right button{margin-right:8px;padding:16px;}
|
.title-right button{margin-right:8px;padding:16px;}
|
||||||
@ -24,7 +26,7 @@ h1 a:not([href]){color:inherit;text-decoration:none;vertical-align: bottom;font-
|
|||||||
.subnav-search form{display:none;}
|
.subnav-search form{display:none;}
|
||||||
.subnav-search svg{display:none;}
|
.subnav-search svg{display:none;}
|
||||||
#buttonRSS{display:none;}
|
#buttonRSS{display:none;}
|
||||||
.SideNav-item .listLabels{display:none;}
|
.LabelTime{display:none;}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
@ -77,8 +79,8 @@ h1 a:not([href]){color:inherit;text-decoration:none;vertical-align: bottom;font-
|
|||||||
</div>
|
</div>
|
||||||
<div class="listLabels">
|
<div class="listLabels">
|
||||||
{% if postListJson[num]['commentNum']>0 %}<span class="Label" style="background-color:{{ blogBase['commentLabelColor'] }}">{{ postListJson[num]['commentNum'] }}</span>{% endif %}
|
{% if postListJson[num]['commentNum']>0 %}<span class="Label" style="background-color:{{ blogBase['commentLabelColor'] }}">{{ postListJson[num]['commentNum'] }}</span>{% endif %}
|
||||||
<span class="Label" style="background-color:{{ postListJson[num]['labelColor'] }}"><object><a style="color:#fff" href="/tag.html#{{ postListJson[num]['label'] }}">{{ postListJson[num]['label'] }}</a></object></span>
|
<span class="Label LabelName" style="background-color:{{ postListJson[num]['labelColor'] }}"><object><a style="color:#fff" href="/tag.html#{{ postListJson[num]['label'] }}">{{ postListJson[num]['label'] }}</a></object></span>
|
||||||
<span class="Label" style="background-color:{{ postListJson[num]['dateLabelColor'] }}">{{ postListJson[num]['createdDate'] }}</span>
|
<span class="Label LabelTime" style="background-color:{{ postListJson[num]['dateLabelColor'] }}">{{ postListJson[num]['createdDate'] }}</span>
|
||||||
</div>
|
</div>
|
||||||
</a>
|
</a>
|
||||||
{%- endfor %}
|
{%- endfor %}
|
||||||
|
|||||||
@ -19,9 +19,7 @@ h1 a:not([href]){color:inherit;text-decoration:none;vertical-align: bottom;font-
|
|||||||
@media (max-width: 767px) {
|
@media (max-width: 767px) {
|
||||||
body { padding: 8px;}
|
body { padding: 8px;}
|
||||||
h1 a{font-size:24px;}
|
h1 a{font-size:24px;}
|
||||||
.SideNav-item .listLabels{display:none;}
|
.LabelTime{display:none;}
|
||||||
.subTitle{display:none;}
|
|
||||||
.genTime{float: none;}
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
@ -124,12 +122,12 @@ function showList(){
|
|||||||
let listLabels=document.createElement("div");
|
let listLabels=document.createElement("div");
|
||||||
listLabels.setAttribute("class","listLabels");
|
listLabels.setAttribute("class","listLabels");
|
||||||
let LabelName=document.createElement("span");
|
let LabelName=document.createElement("span");
|
||||||
LabelName.setAttribute("class","Label");
|
LabelName.setAttribute("class","Label LabelName");
|
||||||
LabelName.setAttribute("style","background-color:"+jsonData["postListJson"][i]['labelColor']);
|
LabelName.setAttribute("style","background-color:"+jsonData["postListJson"][i]['labelColor']);
|
||||||
LabelName.innerHTML=jsonData["postListJson"][i]['label'];
|
LabelName.innerHTML=jsonData["postListJson"][i]['label'];
|
||||||
listLabels.appendChild(LabelName);
|
listLabels.appendChild(LabelName);
|
||||||
let LabelTime=document.createElement("span");
|
let LabelTime=document.createElement("span");
|
||||||
LabelTime.setAttribute("class","Label");
|
LabelTime.setAttribute("class","Label LabelTime");
|
||||||
LabelTime.setAttribute("style","background-color:"+jsonData["postListJson"][i]['dateLabelColor']);
|
LabelTime.setAttribute("style","background-color:"+jsonData["postListJson"][i]['dateLabelColor']);
|
||||||
LabelTime.innerHTML=jsonData["postListJson"][i]['createdDate'];
|
LabelTime.innerHTML=jsonData["postListJson"][i]['createdDate'];
|
||||||
listLabels.appendChild(LabelTime);
|
listLabels.appendChild(LabelTime);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user