summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVolpeon <git@volpeon.ink>2021-11-14 10:28:18 +0100
committerVolpeon <git@volpeon.ink>2021-11-14 10:28:18 +0100
commitf9a74f5ca7c1e919bba46d99d65a7b3a893a7bd7 (patch)
tree14853441ca7cd8f7e283c93e871d801cd43db10a
parentGenerate special list metadata (diff)
downloadvolpeon.ink-f9a74f5ca7c1e919bba46d99d65a7b3a893a7bd7.tar.gz
volpeon.ink-f9a74f5ca7c1e919bba46d99d65a7b3a893a7bd7.tar.bz2
volpeon.ink-f9a74f5ca7c1e919bba46d99d65a7b3a893a7bd7.zip
List improvements
-rw-r--r--assets/css/components/_card-list.scss10
-rw-r--r--content/profiles/bandcamp.md6
-rw-r--r--content/profiles/bandcamp/index.md5
-rw-r--r--content/profiles/bandcamp/main.md5
-rw-r--r--content/profiles/email.md6
-rw-r--r--content/profiles/email/index.md5
-rw-r--r--content/profiles/email/main.md5
-rw-r--r--content/profiles/fediverse.md6
-rw-r--r--content/profiles/fediverse/index.md5
-rw-r--r--content/profiles/fediverse/main.md5
-rw-r--r--content/profiles/git.md6
-rw-r--r--content/profiles/git/index.md5
-rw-r--r--content/profiles/git/main.md5
-rw-r--r--content/profiles/index.md7
-rw-r--r--scripts/metadata_filter.lua13
-rw-r--r--templates/layouts/categorized_list.html11
-rw-r--r--templates/partials/grid_card.html3
-rw-r--r--templates/partials/list_card.html6
18 files changed, 62 insertions, 52 deletions
diff --git a/assets/css/components/_card-list.scss b/assets/css/components/_card-list.scss
index 2a2ae69..0f44b00 100644
--- a/assets/css/components/_card-list.scss
+++ b/assets/css/components/_card-list.scss
@@ -20,7 +20,9 @@
20 @include element('category-header') { 20 @include element('category-header') {
21 margin-top: $line-height * 2rem; 21 margin-top: $line-height * 2rem;
22 color: prop(--colors --cat --fg); 22 color: prop(--colors --cat --fg);
23 }
23 24
25 @include element('category-title') {
24 :link, 26 :link,
25 :visited { 27 :visited {
26 text-decoration: none; 28 text-decoration: none;
@@ -31,6 +33,14 @@
31 } 33 }
32 } 34 }
33 35
36 @include element('category-subtitle') {
37 display: block;
38
39 p {
40 margin-top: $line-height * .25rem;
41 }
42 }
43
34 @include element('category-content') { 44 @include element('category-content') {
35 margin-top: $line-height * .5rem; 45 margin-top: $line-height * .5rem;
36 filter: drop-shadow(#{prop(--dims --obj-shadow, $global: true)} #{prop(--colors --obj-shadow, $global: true)}); 46 filter: drop-shadow(#{prop(--dims --obj-shadow, $global: true)} #{prop(--colors --obj-shadow, $global: true)});
diff --git a/content/profiles/bandcamp.md b/content/profiles/bandcamp.md
new file mode 100644
index 0000000..d3a5e2b
--- /dev/null
+++ b/content/profiles/bandcamp.md
@@ -0,0 +1,6 @@
1---
2title: Bandcamp
3subtitle: volpeon
4icon: parallelogram
5url: https://bandcamp.com/volpeon
6---
diff --git a/content/profiles/bandcamp/index.md b/content/profiles/bandcamp/index.md
deleted file mode 100644
index 0a47469..0000000
--- a/content/profiles/bandcamp/index.md
+++ /dev/null
@@ -1,5 +0,0 @@
1---
2title: Bandcamp
3icon: parallelogram
4list_post_icon: icon-arrow-up-right
5---
diff --git a/content/profiles/bandcamp/main.md b/content/profiles/bandcamp/main.md
deleted file mode 100644
index f94213f..0000000
--- a/content/profiles/bandcamp/main.md
+++ /dev/null
@@ -1,5 +0,0 @@
1---
2title: volpeon
3titlecase: false
4url: https://bandcamp.com/volpeon
5---
diff --git a/content/profiles/email.md b/content/profiles/email.md
new file mode 100644
index 0000000..657d620
--- /dev/null
+++ b/content/profiles/email.md
@@ -0,0 +1,6 @@
1---
2title: E-Mail
3subtitle: me@volpeon.ink
4icon: envelope
5url: mailto:me@volpeon.ink
6---
diff --git a/content/profiles/email/index.md b/content/profiles/email/index.md
deleted file mode 100644
index 6eef738..0000000
--- a/content/profiles/email/index.md
+++ /dev/null
@@ -1,5 +0,0 @@
1---
2title: E-Mail
3icon: envelope
4list_post_icon: icon-arrow-up-right
5---
diff --git a/content/profiles/email/main.md b/content/profiles/email/main.md
deleted file mode 100644
index 16f103a..0000000
--- a/content/profiles/email/main.md
+++ /dev/null
@@ -1,5 +0,0 @@
1---
2title: me@volpeon.ink
3titlecase: false
4url: "mailto:me@volpeon.ink"
5---
diff --git a/content/profiles/fediverse.md b/content/profiles/fediverse.md
new file mode 100644
index 0000000..d43b1fa
--- /dev/null
+++ b/content/profiles/fediverse.md
@@ -0,0 +1,6 @@
1---
2title: Fediverse
3subtitle: "@volpeon@mk.vulpes.one"
4icon: graph
5url: https://mk.vulpes.one/@volpeon
6---
diff --git a/content/profiles/fediverse/index.md b/content/profiles/fediverse/index.md
deleted file mode 100644
index 56eb848..0000000
--- a/content/profiles/fediverse/index.md
+++ /dev/null
@@ -1,5 +0,0 @@
1---
2title: Fediverse
3icon: graph
4list_post_icon: icon-arrow-up-right
5---
diff --git a/content/profiles/fediverse/main.md b/content/profiles/fediverse/main.md
deleted file mode 100644
index 70ee902..0000000
--- a/content/profiles/fediverse/main.md
+++ /dev/null
@@ -1,5 +0,0 @@
1---
2title: "@volpeon@mk.vulpes.one"
3titlecase: false
4url: "https://mk.vulpes.one/@volpeon"
5---
diff --git a/content/profiles/git.md b/content/profiles/git.md
new file mode 100644
index 0000000..63b1bfc
--- /dev/null
+++ b/content/profiles/git.md
@@ -0,0 +1,6 @@
1---
2title: Git
3subtitle: git.vulpes.one
4icon: git-branch
5url: https://git.vulpes.one/
6---
diff --git a/content/profiles/git/index.md b/content/profiles/git/index.md
deleted file mode 100644
index 0d747a6..0000000
--- a/content/profiles/git/index.md
+++ /dev/null
@@ -1,5 +0,0 @@
1---
2title: Git
3icon: git-branch
4list_post_icon: icon-arrow-up-right
5---
diff --git a/content/profiles/git/main.md b/content/profiles/git/main.md
deleted file mode 100644
index fb25680..0000000
--- a/content/profiles/git/main.md
+++ /dev/null
@@ -1,5 +0,0 @@
1---
2title: "git.vulpes.one"
3titlecase: false
4url: "https://git.vulpes.one/"
5---
diff --git a/content/profiles/index.md b/content/profiles/index.md
index 6514367..265a23b 100644
--- a/content/profiles/index.md
+++ b/content/profiles/index.md
@@ -1,5 +1,6 @@
1--- 1---
2title: Profiles 2title: Profiles
3position: 1 3position: 1
4list_grid: true 4list_grid: true
5list_post_icon: icon-arrow-up-right
5--- 6---
diff --git a/scripts/metadata_filter.lua b/scripts/metadata_filter.lua
index b16d472..b6df703 100644
--- a/scripts/metadata_filter.lua
+++ b/scripts/metadata_filter.lua
@@ -200,7 +200,7 @@ function generate_list(meta)
200 return meta.pages.all:map(function(cat) 200 return meta.pages.all:map(function(cat)
201 return { 201 return {
202 title = cat.title, 202 title = cat.title,
203 content = pandoc.utils.stringify(cat.content), 203 content = cat.content,
204 url = cat.url, 204 url = cat.url,
205 grid = cat.list_grid, 205 grid = cat.list_grid,
206 items = cat.pages.all:map(function(p) 206 items = cat.pages.all:map(function(p)
@@ -220,7 +220,7 @@ function generate_list(meta)
220 return meta.pages.all:map(function(cat) 220 return meta.pages.all:map(function(cat)
221 return { 221 return {
222 title = cat.title, 222 title = cat.title,
223 content = pandoc.utils.stringify(cat.content), 223 content = cat.content,
224 url = cat.url, 224 url = cat.url,
225 grid = cat.list_grid, 225 grid = cat.list_grid,
226 items = cat.pages.all:flatMap(function(c) 226 items = cat.pages.all:flatMap(function(c)
@@ -228,7 +228,8 @@ function generate_list(meta)
228 return c.pages.all:map(function(p) 228 return c.pages.all:map(function(p)
229 return { 229 return {
230 title = p.title, 230 title = p.title,
231 subtitle = p.subtitle or c.title, 231 subtitle = p.subtitle,
232 category = c.title,
232 url = p.url, 233 url = p.url,
233 icon = p.icon or c.icon, 234 icon = p.icon or c.icon,
234 post_icon = c.list_post_icon or cat.list_post_icon, 235 post_icon = c.list_post_icon or cat.list_post_icon,
@@ -241,9 +242,9 @@ function generate_list(meta)
241 title = c.title, 242 title = c.title,
242 subtitle = c.subtitle, 243 subtitle = c.subtitle,
243 url = c.url, 244 url = c.url,
244 icon = c.icon or meta.icon, 245 icon = c.icon or cat.icon,
245 post_icon = meta.list_post_icon, 246 post_icon = cat.list_post_icon,
246 indicator = meta.list_read_indicators, 247 indicator = cat.list_read_indicators,
247 }) 248 })
248 return l 249 return l
249 end 250 end
diff --git a/templates/layouts/categorized_list.html b/templates/layouts/categorized_list.html
index aea8863..256e9de 100644
--- a/templates/layouts/categorized_list.html
+++ b/templates/layouts/categorized_list.html
@@ -7,9 +7,14 @@ $body$
7 7
8 <div class="c-card-list"> 8 <div class="c-card-list">
9 $for(list)$ 9 $for(list)$
10 <h2 class="c-card-list__category-header"> 10 <header class="c-card-list__category-header">
11 <a href="$it.url.rel$">$it.title$</a> 11 <h2 class="c-card-list__category-title">
12 </h2> 12 <a href="$it.url.rel$">$it.title$</a>
13 </h2>
14 $if(it.content)$
15 <small class="c-card-list__category-subtitle">$it.content$</small>
16 $endif$
17 </header>
13 $if(it.grid)$ 18 $if(it.grid)$
14 <div class="c-card-list__category-content c-card-list__category-content--grid"> 19 <div class="c-card-list__category-content c-card-list__category-content--grid">
15 $it.items:partials/grid_card()$ 20 $it.items:partials/grid_card()$
diff --git a/templates/partials/grid_card.html b/templates/partials/grid_card.html
index 25c2271..4b24711 100644
--- a/templates/partials/grid_card.html
+++ b/templates/partials/grid_card.html
@@ -9,7 +9,10 @@
9 $endif$ 9 $endif$
10 <div class="c-card__block c-card__block--main"> 10 <div class="c-card__block c-card__block--main">
11 $if(it.subtitle)$ 11 $if(it.subtitle)$
12 <strong class="u-db">$it.title$</strong>
12 <small class="u-db">$it.subtitle$</small> 13 <small class="u-db">$it.subtitle$</small>
14 $elseif(it.category)$
15 <small class="u-db">$it.category$</small>
13 <strong class="u-db">$it.title$</strong> 16 <strong class="u-db">$it.title$</strong>
14 $elseif(it.date)$ 17 $elseif(it.date)$
15 <time datetime="$it.date.yyyy_mm_dd$"> 18 <time datetime="$it.date.yyyy_mm_dd$">
diff --git a/templates/partials/list_card.html b/templates/partials/list_card.html
index 644e0d3..0ed6360 100644
--- a/templates/partials/list_card.html
+++ b/templates/partials/list_card.html
@@ -16,6 +16,12 @@
16 $it.subtitle$ 16 $it.subtitle$
17 </small> 17 </small>
18 </div> 18 </div>
19 $elseif(it.category)$
20 <div class="c-card__block u-fs0">
21 <small>
22 $it.category$
23 </small>
24 </div>
19 $elseif(it.date)$ 25 $elseif(it.date)$
20 <time datetime="$it.date.yyyy_mm_dd$" class="c-card__block u-fs0"> 26 <time datetime="$it.date.yyyy_mm_dd$" class="c-card__block u-fs0">
21 <small class="u-dn@sm-hi"> 27 <small class="u-dn@sm-hi">