commit 3a5a676118f015351e254f66edac52e3f9c0311c
parent 4a8f9aa7983bbc9959cd18c46dff691791619b04
Author: panr <radoslaw.koziel@gmail.com>
Date: Sat, 10 Jun 2023 00:27:17 +0200
fixes after PRs
Diffstat:
11 files changed, 73 insertions(+), 53 deletions(-)
diff --git a/assets/css/buttons.scss b/assets/css/buttons.scss
@@ -12,7 +12,7 @@ a.button {
align-items: center;
justify-content: center;
padding: 8px 18px;
- margin-bottom: 5px;
+ margin: 5px 0;
text-decoration: none;
text-align: center;
border-radius: 8;
diff --git a/assets/css/form.scss b/assets/css/form.scss
@@ -4,6 +4,7 @@ input, textarea, select {
border: 1px solid $accent;
border-radius: 0;
padding: 10px;
+ margin: 5px 0;
font: inherit;
appearance: none;
@@ -28,3 +29,15 @@ select {
::placeholder {
color: transparentize($accent, .5);
}
+
+input {
+ &[type="checkbox"] {
+ vertical-align: middle;
+ padding: 10px;
+ box-shadow: inset 0 0 0 3px $background;
+
+ &:checked {
+ background: $accent;
+ }
+ }
+}
diff --git a/assets/css/post.scss b/assets/css/post.scss
@@ -33,6 +33,14 @@
font-size: 1rem;
margin-bottom: 10px;
color: transparentize($accent, .3);
+
+ & > *:not(:first-child) {
+ &::before {
+ content: "::";
+ display: inline-block;
+ margin: 0 8px;
+ }
+ }
}
&-title {
@@ -72,16 +80,6 @@
margin-top: 30px;
}
- input[type="checkbox"] {
- vertical-align: middle;
- padding: 5px;
- margin: 0 .2em .25em -.2em;
- }
-
- input[type="checkbox"]:checked {
- background: $accent;
- }
-
&-cover {
border: 20px solid $accent;
background: transparent;
diff --git a/assets/css/style.scss b/assets/css/style.scss
@@ -16,5 +16,4 @@
@import "syntax";
@import "code";
@import "terms";
-@import "term";
@import "gist";
diff --git a/assets/css/term.scss b/assets/css/term.scss
@@ -1,3 +0,0 @@
-h1.term {
- color: $accent;
-}
diff --git a/assets/css/terms.scss b/assets/css/terms.scss
@@ -1,9 +1,22 @@
.terms {
- h1 {
- color: $accent;
- }
-
h3 {
font-size: initial;
}
+
+ ul {
+ list-style: none;
+
+ li {
+ a {
+ color: $accent;
+ }
+ }
+
+ li:not(:empty):before {
+ content: '-';
+ position: absolute;
+ left: -20px;
+ color: $accent;
+ }
+ }
}
diff --git a/layouts/_default/index.html b/layouts/_default/index.html
@@ -21,14 +21,14 @@
</h1>
<div class="post-meta">
- {{ if .Date }}
+ {{- if .Date -}}
<time class="post-date">
- {{ .Date.Format "2006-01-02" }} ::
+ {{- .Date.Format "2006-01-02" -}}
</time>
- {{ end }}
- {{ with .Params.Author }}
+ {{- end -}}
+ {{- with .Params.Author -}}
<span class="post-author">{{ . }}</span>
- {{ end }}
+ {{- end -}}
</div>
{{ if .Params.tags }}
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
@@ -11,14 +11,14 @@
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
</h1>
<div class="post-meta">
- {{ if .Date }}
+ {{- if .Date -}}
<time class="post-date">
- {{ .Date.Format "2006-01-02" }}
+ {{- .Date.Format "2006-01-02" -}}
</time>
- {{ end }}
- {{ with .Params.Author }}
- :: <span class="post-author">{{ . }}</span>
- {{ end }}
+ {{- end -}}
+ {{- with .Params.Author -}}
+ <span class="post-author">{{- . -}}</span>
+ {{- end -}}
</div>
{{ if .Params.tags }}
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
@@ -4,20 +4,20 @@
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
</h1>
<div class="post-meta">
- {{ if .Date }}
+ {{- if .Date -}}
<time class="post-date">
- {{ .Date.Format "2006-01-02" }}
- {{ if $.Site.Params.showLastUpdated }}
- :: [{{or $.Site.Params.updatedDatePrefix "Updated"}} :: {{ .Lastmod.Format "2006-01-02" }}]
- {{ end }}
+ {{- .Date.Format "2006-01-02" -}}
+ {{- if $.Site.Params.showLastUpdated -}}
+ [{{- or $.Site.Params.updatedDatePrefix "Updated" -}} :: {{- .Lastmod.Format "2006-01-02" -}}]
+ {{- end -}}
</time>
- {{ end }}
- {{ with .Params.Author }}
- <span class="post-author"> :: {{ . }}</span>
- {{ end }}
- {{ if and (.Param "readingTime") (eq (.Param "readingTime") true) }}
- <span class="post-reading-time">:: {{ .ReadingTime }} {{ $.Site.Params.minuteReadingTime | default "min read" }} ({{ .WordCount }} {{ $.Site.Params.words | default "words" }})</span>
- {{ end }}
+ {{- end -}}
+ {{- with .Params.Author -}}
+ <span class="post-author">{{ . }}</span>
+ {{- end -}}
+ {{- if and (.Param "readingTime") (eq (.Param "readingTime") true) -}}
+ <span class="post-reading-time">{{ .ReadingTime }} {{ $.Site.Params.minuteReadingTime | default "min read" }} ({{ .WordCount }} {{ $.Site.Params.words | default "words" }})</span>
+ {{- end -}}
</div>
{{ if .Params.tags }}
diff --git a/layouts/_default/term.html b/layouts/_default/term.html
@@ -1,5 +1,5 @@
{{ define "main" }}
- <h1 class="term">{{ .Title }}</h1>
+ <h1>Posts for: #{{ .Title }}</h1>
{{ with .Content }}
<div class="index-content">
{{ . }}
@@ -12,14 +12,14 @@
<a href="{{ .Permalink }}">{{ .Title | markdownify }}</a>
</h1>
<div class="post-meta">
- {{ if .Date }}
+ {{- if .Date -}}
<time class="post-date">
- {{ .Date.Format "2006-01-02" }}
+ {{- .Date.Format "2006-01-02" -}}
</time>
- {{ end }}
- {{ with .Params.Author }}
- <span class="post-author"> :: {{ . }}</span>
- {{ end }}
+ {{- end -}}
+ {{- with .Params.Author -}}
+ <span class="post-author">{{- . -}}</span>
+ {{- end -}}
</div>
{{ if .Params.tags }}
diff --git a/layouts/_default/terms.html b/layouts/_default/terms.html
@@ -2,9 +2,9 @@
<div class="terms">
<h1>{{ .Title }}</h1>
{{ with .Content }}
- <div class="index-content">
- {{ . }}
- </div>
+ <div class="index-content">
+ {{ . }}
+ </div>
{{ end }}
<ul>
{{ $type := .Type }}
@@ -13,7 +13,7 @@
{{ $count := .Count }}
{{ with $.Site.GetPage (printf "/%s/%s" $type $name) }}
<li>
- <a class="terms-title" href="{{ .Permalink }}">{{ .Name }} ({{ $count }})</a>
+ <a class="terms-title" href="{{ .Permalink }}">{{ .Name }} [{{ $count }}]</a>
</li>
{{ end }}
{{ end }}