diff options
-rw-r--r-- | Makefile | 4 | ||||
-rw-r--r-- | assets/css/default-simple.css | 8 | ||||
-rw-r--r-- | assets/css/default.css | 67 | ||||
-rw-r--r-- | config/_default/config.json (renamed from config.json) | 0 | ||||
-rw-r--r-- | config/_default/config.toml (renamed from config.toml) | 0 | ||||
-rw-r--r-- | config/_default/config.yaml (renamed from config.yaml) | 0 | ||||
-rw-r--r-- | themes/default/layouts/_default/home.sources.html | 8 | ||||
-rw-r--r-- | themes/default/layouts/partials/following-list.html | 5 |
8 files changed, 50 insertions, 42 deletions
@@ -21,8 +21,8 @@ build-sub: # Build everything into substitute directory mv public/* public/m || true build-config: # Build configuration files - yj -yj -i < config.yaml > config.json - yj -yt -i < config.yaml > config.toml + yj -yj -i < config/_default/config.yaml > config/_default/config.json + yj -yt -i < config/_default/config.yaml > config/_default/config.toml build-js: # Build js bundle deno run --allow-all static/js/index-bundle.ts diff --git a/assets/css/default-simple.css b/assets/css/default-simple.css index 8b7fca3..29f7c0d 100644 --- a/assets/css/default-simple.css +++ b/assets/css/default-simple.css @@ -33,14 +33,16 @@ micro-card[id] > article > :nth-last-child(2) { margin-bottom: 0; } -[data-kind="page"] micro-card[id]:first-child > a, micro-card[id] micro-tags, micro-card[id] > header meta-data, -micro-card[id] > article figcaption { +micro-card[id] > article figcaption, +[data-kind="page"] micro-card[id]:first-child > a { display: none; } -micro-card[id] > article footer:not(blockquote footer) { +micro-card[id] + > article + footer:not(blockquote footer):not(code-block + footer) { display: none; } diff --git a/assets/css/default.css b/assets/css/default.css index 74eb0fc..d3d2b6f 100644 --- a/assets/css/default.css +++ b/assets/css/default.css @@ -248,6 +248,7 @@ code, svg text, following-list details summary:after, micro-card article details[data-disclosure] summary:after { + font-size: 0.95rem; font-family: "Fira Code", "Lucida Console", "Andale Mono", "Roboto Mono", "Ubuntu Monospace", "Noto Mono", "Oxygen Mono", "Liberation Mono", monospace, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; @@ -489,15 +490,6 @@ kbd { /* ----- Elements ----- */ -html { - font-size: 95%; - line-height: 1.5; - word-break: break-word; - text-rendering: optimizeSpeed; - margin-left: calc(100vw - 100%); - margin-right: 0; -} - button, textarea { margin: 0; @@ -971,6 +963,31 @@ article a[href*="pdf"]::after { /* ----- Base ----- */ +html { + font-size: 95%; + height: 100%; + line-height: 1.5; + margin: 0; + overflow-y: scroll; + text-rendering: optimizeSpeed; + word-break: break-word; +} + +html[data-document="html"], +html[data-document="xhtml"] { + height: auto; + margin-left: calc(100vw - 100%); + margin-right: 0; + overflow-y: visible; +} + +html[data-document="html"] body, +html[data-document="xhtml"] body { + display: flex; + margin: 0 auto; + max-width: 1250px; +} + body { background-color: #fefefe; background-color: var(--background); @@ -983,13 +1000,6 @@ body { -webkit-text-size-adjust: none; } -html[data-document="html"] body, -html[data-document="xhtml"] body { - display: flex; - margin: 0 auto; - max-width: 1250px; -} - column-base[position="left"] { width: 14.25%; } @@ -1408,7 +1418,6 @@ micro-card details[data-disclosure] summary:after, micro-card details[data-disclosure][open] summary:after { border-radius: 0.5rem; display: inline; - font-size: 85%; vertical-align: bottom; } @@ -1662,7 +1671,7 @@ code-block[data-lines] pre code { code-block header { position: relative; - top: 1.85rem; + top: 2.125rem; margin-top: -1rem; height: 1rem; padding: 0 0.5rem; @@ -1673,12 +1682,12 @@ code-block header { } code-block header language-label { - padding: 0.125rem 1rem; font-variant: all-small-caps; } code-block header language-label a { text-decoration: none; + padding: 0.125rem 1rem; } code-block header language-label a:hover { @@ -2379,6 +2388,7 @@ nav[hidden] { [data-xml] micro-card { flex-direction: row; + align-items: center; } [data-xml] micro-card article { @@ -2408,9 +2418,12 @@ nav[hidden] { /* ----- Responsive ----- */ @media screen and (max-width: 1220px) { + column-base[position="right"] { + width: 38%; + } column-base[position="left"] { flex: none; - margin: 0.5rem; + width: auto; } column-base[position="left"] nav a { flex-direction: column-reverse; @@ -2421,9 +2434,6 @@ nav[hidden] { column-base[position="left"] nav a span { padding-top: 0.5rem; } - column-base[position="right"] { - width: 38%; - } micro-author micro-card { flex-direction: column; text-align: center; @@ -2463,6 +2473,10 @@ nav[hidden] { } @media screen and (max-width: 920px) { + html[data-document="html"], + html[data-document="xhtml"] { + margin: 0; + } nav + main, profile-box { margin-top: 4rem; @@ -2500,13 +2514,6 @@ nav[hidden] { flex: auto; margin: 0 0 0.75rem 0; } - html { - margin: 0; - } - body { - display: block; - overflow-y: scroll; - } tab-bar:active, tab-bar:hover, tab-bar:focus, diff --git a/config.json b/config/_default/config.json index 2f29e53..2f29e53 100644 --- a/config.json +++ b/config/_default/config.json diff --git a/config.toml b/config/_default/config.toml index 16ca22b..16ca22b 100644 --- a/config.toml +++ b/config/_default/config.toml diff --git a/config.yaml b/config/_default/config.yaml index 6ba49df..6ba49df 100644 --- a/config.yaml +++ b/config/_default/config.yaml diff --git a/themes/default/layouts/_default/home.sources.html b/themes/default/layouts/_default/home.sources.html index 42b6cc3..32f7822 100644 --- a/themes/default/layouts/_default/home.sources.html +++ b/themes/default/layouts/_default/home.sources.html @@ -47,7 +47,7 @@ {{ range sort $_default ".ModTime" "desc" }} {{ if not .IsDir }} <li> - <a download="true" title="{{ .Name }}" href="{{ "" | absURL }}/sources/files/_default/{{ .Name }}"> + <a download="" title="{{ .Name }}" href="{{ "sources/files/_default" | relURL }}/{{ .Name }}"> <span><code>{{- .ModTime | time.Format "2006-01-02 15:04 MST" }}</code></span> <span><code>{{ .Name }}</code></span> <span><code>{{ .Size -}}</code></span> @@ -62,7 +62,7 @@ {{ range sort $_markup ".ModTime" "desc" }} {{ if not .IsDir }} <li> - <a download="true" title="{{ .Name }}" href="{{ "" | absURL }}/sources/files/_default/_markup/{{ .Name }}"> + <a download="" title="{{ .Name }}" href="{{ "sources/files/_default/_markup" | relURL }}/{{ .Name }}"> <span><code>{{- .ModTime | time.Format "2006-01-02 15:04 MST" }}</code></span> <span><code>{{ .Name }}</code></span> <span><code>{{ .Size -}}</code></span> @@ -77,7 +77,7 @@ {{ range sort $partials ".ModTime" "desc" }} {{ if not .IsDir }} <li> - <a download="true" title="{{ .Name }}" href="{{ "" | absURL }}/sources/files/partials/{{ .Name }}"> + <a download="" title="{{ .Name }}" href="{{ "sources/files/partials" | relURL }}/{{ .Name }}"> <span><code>{{- .ModTime | time.Format "2006-01-02 15:04 MST" }}</code></span> <span><code>{{ .Name }}</code></span> <span><code>{{ .Size -}}</code></span> @@ -92,7 +92,7 @@ {{ range sort $shortcodes ".ModTime" "desc" }} {{ if not .IsDir }} <li> - <a download="true" title="{{ .Name }}" href="{{ "" | absURL }}/sources/files/shortcodes/{{ .Name }}"> + <a download="" title="{{ .Name }}" href="{{ "sources/files/shortcodes" | relURL }}/{{ .Name }}"> <span><code>{{- .ModTime | time.Format "2006-01-02 15:04 MST" }}</code></span> <span><code>{{ .Name }}</code></span> <span><code>{{ .Size -}}</code></span> diff --git a/themes/default/layouts/partials/following-list.html b/themes/default/layouts/partials/following-list.html index c04d55c..510d3d2 100644 --- a/themes/default/layouts/partials/following-list.html +++ b/themes/default/layouts/partials/following-list.html @@ -1,7 +1,6 @@ {{- $count := 0 -}} {{- $author := partial "function-authors-data.html" . -}} -{{- $feeds := print "public/" $author.user "/following.html" -}} -{{- $hash := print (truncate 4 "" (sha256 .RelPermalink)) (truncate 4 "" (sha256 .Section)) -}} +{{- $feeds := print "public/" .Section "/following.html" -}} {{- with $items := $author.feeds.rss -}} {{- $count = len $items -}} @@ -11,7 +10,7 @@ <following-list> <details - id="web-feeds-{{ $hash }}" + id="web-feeds" data-expand="{{- $expand -}}" > <summary> |