浏览代码

Change ToC/footer/figure style

Track3 3 年之前
父节点
当前提交
f3edb903c6
共有 4 个文件被更改,包括 35 次插入25 次删除
  1. 1 1
      assets/scss/partials/_list.scss
  2. 2 2
      assets/scss/partials/_single.scss
  3. 17 9
      assets/scss/style.scss
  4. 15 13
      layouts/partials/footer.html

+ 1 - 1
assets/scss/partials/_list.scss

@@ -26,7 +26,7 @@
     justify-content: space-between;
     align-items: baseline;
     padding: 12px 0;
-    border-bottom: 1px dashed;
+    border-bottom: 1px dashed var(--c-txt-alt);
   }
 
   .post-day {

+ 2 - 2
assets/scss/partials/_single.scss

@@ -70,12 +70,12 @@
 
   figure.left {
     float: left;
-    margin-right: 1.5em;
+    margin-right: 1em;
     max-width: 50%;
   }
   figure.right {
     float: right;
-    margin-left: 1.5em;
+    margin-left: 1em;
     max-width: 50%;
   }
   figure.big {

+ 17 - 9
assets/scss/style.scss

@@ -209,10 +209,14 @@ h1#page-title {
   html {
     font-size: 1.1em;
   }
-  .wrapper#site-footer {
-    display: flex;
-    flex-direction: row-reverse;
+  #site-footer {
     background: transparent;
+    &>.footer-inner {
+      display: flex;
+      flex-direction: row-reverse;
+      padding-top: 1em;
+      border-top: 2px solid var(--c-bg-alt);
+    }
   }
   .posts-group {
     display: flex;
@@ -292,7 +296,6 @@ h1#page-title {
     padding-right: 15vw;
   }
   .wrapper {
-    width: 1028px;
     margin-left: var(--offset);
   }
   #toc-btn {
@@ -306,7 +309,7 @@ h1#page-title {
     width: calc(var(--offset) - 2em);
     padding: 0 0 0 1em;
     margin-left: calc(0px - var(--offset));
-    border-right: 1px dashed;
+    border-right: 2px solid var(--c-bg-alt);
     border-radius: 0;
     background: transparent;
     text-align: right;
@@ -324,12 +327,17 @@ h1#page-title {
       display: inline;
     }
   }
-  .content figure.big {
-    width: calc(var(--vw) * 100 - var(--offset) - 1em);
-    margin-left: 0;
+  .content > figure {
     text-align: left;
-    &>img {
+    &.big {
+      width: calc(var(--vw) * 100 - var(--offset) - 1em);
       margin-left: 0;
+      &>img {
+        margin-left: 0;
+      }
+    }
+    &.right  {
+      margin-right: -280px;
     }
   }
 }

+ 15 - 13
layouts/partials/footer.html

@@ -1,16 +1,18 @@
 	<footer id="site-footer" class="wrapper">
-		<div class="footer-r">
-			{{- with .Site.Params.social -}}
-			<p class="social-icon">{{ partialCached "social-icons.html" . }}</p>
-			{{- end -}}
-		</div>
-		<div class="footer-l">
-			<nav class="site-nav">
-				<a href="{{.Site.BaseURL}}">Home</a><span>&#47;</span>
-				{{- range .Site.Menus.main -}}
-				<a href="{{ .URL }}">{{ .Name }}</a><span>&#47;</span>
-				{{- end }}
-			</nav>
-			<p class="site-copy">&copy; {{ now.Format "2006" }} <a href="{{ .Site.BaseURL }}">{{ .Site.Author.name }}</a> &#183; <a href="https://creativecommons.org/licenses/by-nc/4.0/deed.zh" target="_blank" rel="noopener">CC BY-NC 4.0</a> &#183; <a href="{{ "posts/index.xml" | absURL }}" target="_blank" title="RSS" class="icon-link"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-rss"><path d="M4 11a9 9 0 0 1 9 9"></path><path d="M4 4a16 16 0 0 1 16 16"></path><circle cx="5" cy="19" r="1"></circle></svg></a></p>
+		<div class="footer-inner">
+			<div class="footer-r">
+				{{- with .Site.Params.social -}}
+				<p class="social-icon">{{ partialCached "social-icons.html" . }}</p>
+				{{- end -}}
+			</div>
+			<div class="footer-l">
+				<nav class="site-nav">
+					<a href="{{.Site.BaseURL}}">Home</a><span>&#47;</span>
+					{{- range .Site.Menus.main -}}
+					<a href="{{ .URL }}">{{ .Name }}</a><span>&#47;</span>
+					{{- end }}
+				</nav>
+				<p class="site-copy">&copy; {{ now.Format "2006" }} <a href="{{ .Site.BaseURL }}">{{ .Site.Author.name }}</a> &#183; <a href="https://creativecommons.org/licenses/by-nc/4.0/deed.zh" target="_blank" rel="noopener">CC BY-NC 4.0</a> &#183; <a href="{{ "posts/index.xml" | absURL }}" target="_blank" title="RSS" class="icon-link"><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-rss"><path d="M4 11a9 9 0 0 1 9 9"></path><path d="M4 4a16 16 0 0 1 16 16"></path><circle cx="5" cy="19" r="1"></circle></svg></a></p>
+			</div>
 		</div>
 	</footer>