Repos / s4g / a7f30c590b
commit a7f30c590b50008dbd82dc0e75eb9abf8e7cda14
Author: Nhân <hi@imnhan.com>
Date: Mon Aug 21 18:13:02 2023 +0700
clean up home page + use sans serif
diff --git a/docs/_theme/base.css b/docs/_theme/base.css
index c061eb7..53a5d64 100644
--- a/docs/_theme/base.css
+++ b/docs/_theme/base.css
@@ -1,5 +1,6 @@
html {
- font-family: serif;
+ font-family: system-ui, sans-serif;
+ font-size: 1em;
max-width: 50rem;
margin: auto;
}
diff --git a/docs/_theme/home.tmpl b/docs/_theme/home.tmpl
index d85797f..8938254 100644
--- a/docs/_theme/home.tmpl
+++ b/docs/_theme/home.tmpl
@@ -27,10 +27,10 @@
<ul>
{{- range .ArticlesInFeed}}
{{- if not .IsDraft}}
- <li>
- <span class="time-prefix">{{.PostedAt.Local.Format "2006-01-02"}} — </span>
+ <li class="article">
<a href="{{.WebPath}}">{{.Title}}</a>
- <span class="time-suffix">({{.PostedAt.Local.Format "2006-01-02"}})</span>
+ <br>
+ <span>{{.PostedAt.Local.Format "January 1, 2006"}}</span>
</li>
{{- end}}
{{- end}}
@@ -64,26 +64,10 @@ hr {
ul {
padding: 0;
list-style: none;
- /*font-size: 1.1rem;*/
}
-.time-suffix {
- display: none;
-}
-
-@media (max-width: 30rem) {
- .time-suffix {
- display: inline;
- }
- .time-prefix {
- display: none;
- }
- li {
- margin-bottom: 0.5rem;
- }
- li::before {
- content: '❖';
- }
+.article {
+ margin-bottom: 1rem;
}
</style>
diff --git a/theme/base.css b/theme/base.css
index c061eb7..53a5d64 100644
--- a/theme/base.css
+++ b/theme/base.css
@@ -1,5 +1,6 @@
html {
- font-family: serif;
+ font-family: system-ui, sans-serif;
+ font-size: 1em;
max-width: 50rem;
margin: auto;
}
diff --git a/theme/home.tmpl b/theme/home.tmpl
index d85797f..8938254 100644
--- a/theme/home.tmpl
+++ b/theme/home.tmpl
@@ -27,10 +27,10 @@
<ul>
{{- range .ArticlesInFeed}}
{{- if not .IsDraft}}
- <li>
- <span class="time-prefix">{{.PostedAt.Local.Format "2006-01-02"}} — </span>
+ <li class="article">
<a href="{{.WebPath}}">{{.Title}}</a>
- <span class="time-suffix">({{.PostedAt.Local.Format "2006-01-02"}})</span>
+ <br>
+ <span>{{.PostedAt.Local.Format "January 1, 2006"}}</span>
</li>
{{- end}}
{{- end}}
@@ -64,26 +64,10 @@ hr {
ul {
padding: 0;
list-style: none;
- /*font-size: 1.1rem;*/
}
-.time-suffix {
- display: none;
-}
-
-@media (max-width: 30rem) {
- .time-suffix {
- display: inline;
- }
- .time-prefix {
- display: none;
- }
- li {
- margin-bottom: 0.5rem;
- }
- li::before {
- content: '❖';
- }
+.article {
+ margin-bottom: 1rem;
}
</style>