diff options
author | Volpeon <git@volpeon.ink> | 2022-07-31 10:00:03 +0200 |
---|---|---|
committer | Volpeon <git@volpeon.ink> | 2022-07-31 10:00:03 +0200 |
commit | 20c5ad5a7a737d721cb39b75852a79f20502da74 (patch) | |
tree | 217a5cf991d73b482f39553ca1908f891b0611d7 /templates/partials | |
parent | Update (diff) | |
download | volpeon.ink-20c5ad5a7a737d721cb39b75852a79f20502da74.tar.gz volpeon.ink-20c5ad5a7a737d721cb39b75852a79f20502da74.tar.bz2 volpeon.ink-20c5ad5a7a737d721cb39b75852a79f20502da74.zip |
Simplified "list" list layout code
Diffstat (limited to 'templates/partials')
-rw-r--r-- | templates/partials/gallery_card.html | 34 | ||||
-rw-r--r-- | templates/partials/grid_card.html | 40 | ||||
-rw-r--r-- | templates/partials/list_card.html | 48 |
3 files changed, 69 insertions, 53 deletions
diff --git a/templates/partials/gallery_card.html b/templates/partials/gallery_card.html index a340148..4728461 100644 --- a/templates/partials/gallery_card.html +++ b/templates/partials/gallery_card.html | |||
@@ -1,11 +1,12 @@ | |||
1 | $if(it.thumbnail)$ | ||
2 | <a | 1 | <a |
3 | href="$it.url.rel$" | 2 | href="$it.url.rel$" |
4 | class="l-card-list__card c-card t-raised h-entry" | 3 | class="l-card-list__card c-card t-raised h-entry" |
5 | itemprop="dataFeedElement" | 4 | itemprop="dataFeedElement" |
6 | itemscope | 5 | itemscope |
7 | itemtype="https://schema.org/$it.schema_type$" | 6 | itemtype="https://schema.org/$it.schema_type$" |
8 | $if(it.rel)$rel="$it.rel$"$endif$ | 7 | $if(it.rel)$ |
8 | rel="$it.rel$" | ||
9 | $endif$ | ||
9 | > | 10 | > |
10 | <link itemprop="thumbnailUrl" href="$it.thumbnail.full$" /> | 11 | <link itemprop="thumbnailUrl" href="$it.thumbnail.full$" /> |
11 | 12 | ||
@@ -32,14 +33,24 @@ $if(it.thumbnail)$ | |||
32 | $if(it.subtitle)$ | 33 | $if(it.subtitle)$ |
33 | <div> | 34 | <div> |
34 | <strong class="p-name" itemprop="name headline">$it.title$</strong> | 35 | <strong class="p-name" itemprop="name headline">$it.title$</strong> |
35 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | 36 | $if(it.draft)$ |
37 | <span class="o-badge u-ml-100">Draft</span> | ||
38 | $endif$ | ||
36 | </div> | 39 | </div> |
37 | <small class="u-d-block">$it.subtitle$</small> | 40 | <small class="u-d-block"> |
41 | $it.subtitle$ | ||
42 | </small> | ||
38 | $elseif(it.category)$ | 43 | $elseif(it.category)$ |
39 | <small class="u-d-block">$it.category$</small> | 44 | <small class="u-d-block"> |
45 | $it.category$ | ||
46 | </small> | ||
40 | <div> | 47 | <div> |
41 | <strong class="p-name" itemprop="name headline">$it.title$</strong> | 48 | <strong class="p-name" itemprop="name headline"> |
42 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | 49 | $it.title$ |
50 | </strong> | ||
51 | $if(it.draft)$ | ||
52 | <span class="o-badge u-ml-100">Draft</span> | ||
53 | $endif$ | ||
43 | </div> | 54 | </div> |
44 | $elseif(it.show_date)$ | 55 | $elseif(it.show_date)$ |
45 | <small class="u-d-block"> | 56 | <small class="u-d-block"> |
@@ -49,13 +60,17 @@ $if(it.thumbnail)$ | |||
49 | </small> | 60 | </small> |
50 | <div> | 61 | <div> |
51 | <strong class="p-name" itemprop="name headline">$it.title$</strong> | 62 | <strong class="p-name" itemprop="name headline">$it.title$</strong> |
52 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | 63 | $if(it.draft)$ |
64 | <span class="o-badge u-ml-100">Draft</span> | ||
65 | $endif$ | ||
53 | </div> | 66 | </div> |
54 | $else$ | 67 | $else$ |
55 | <span class="p-name" itemprop="name headline"> | 68 | <span class="p-name" itemprop="name headline"> |
56 | $it.title$ | 69 | $it.title$ |
57 | </span> | 70 | </span> |
58 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | 71 | $if(it.draft)$ |
72 | <span class="o-badge u-ml-100">Draft</span> | ||
73 | $endif$ | ||
59 | $endif$ | 74 | $endif$ |
60 | </div> | 75 | </div> |
61 | $if(it.post_icon)$ | 76 | $if(it.post_icon)$ |
@@ -65,4 +80,3 @@ $if(it.thumbnail)$ | |||
65 | $endif$ | 80 | $endif$ |
66 | </div> | 81 | </div> |
67 | </a> | 82 | </a> |
68 | $endif$ | ||
diff --git a/templates/partials/grid_card.html b/templates/partials/grid_card.html index 170f478..9a0b06e 100644 --- a/templates/partials/grid_card.html +++ b/templates/partials/grid_card.html | |||
@@ -4,7 +4,9 @@ | |||
4 | itemprop="dataFeedElement" | 4 | itemprop="dataFeedElement" |
5 | itemscope | 5 | itemscope |
6 | itemtype="https://schema.org/$it.schema_type$" | 6 | itemtype="https://schema.org/$it.schema_type$" |
7 | $if(it.rel)$rel="$it.rel$"$endif$ | 7 | $if(it.rel)$ |
8 | rel="$it.rel$" | ||
9 | $endif$ | ||
8 | > | 10 | > |
9 | <div class="c-card__row l-media"> | 11 | <div class="c-card__row l-media"> |
10 | $if(it.indicator)$ | 12 | $if(it.indicator)$ |
@@ -18,15 +20,27 @@ | |||
18 | <div class="l-media__block l-media__block--main"> | 20 | <div class="l-media__block l-media__block--main"> |
19 | $if(it.subtitle)$ | 21 | $if(it.subtitle)$ |
20 | <div> | 22 | <div> |
21 | <strong class="p-name" itemprop="name headline">$it.title$</strong> | 23 | <strong class="p-name" itemprop="name headline"> |
22 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | 24 | $it.title$ |
25 | </strong> | ||
26 | $if(it.draft)$ | ||
27 | <span class="o-badge u-ml-100">Draft</span> | ||
28 | $endif$ | ||
23 | </div> | 29 | </div> |
24 | <small class="u-d-block">$it.subtitle$</small> | 30 | <small class="u-d-block"> |
31 | $it.subtitle$ | ||
32 | </small> | ||
25 | $elseif(it.category)$ | 33 | $elseif(it.category)$ |
26 | <small class="u-d-block">$it.category$</small> | 34 | <small class="u-d-block"> |
35 | $it.category$ | ||
36 | </small> | ||
27 | <div> | 37 | <div> |
28 | <strong class="p-name" itemprop="name headline">$it.title$</strong> | 38 | <strong class="p-name" itemprop="name headline"> |
29 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | 39 | $it.title$ |
40 | </strong> | ||
41 | $if(it.draft)$ | ||
42 | <span class="o-badge u-ml-100">Draft</span> | ||
43 | $endif$ | ||
30 | </div> | 44 | </div> |
31 | $elseif(it.show_date)$ | 45 | $elseif(it.show_date)$ |
32 | <small class="u-d-block"> | 46 | <small class="u-d-block"> |
@@ -35,14 +49,20 @@ | |||
35 | </time> | 49 | </time> |
36 | </small> | 50 | </small> |
37 | <div> | 51 | <div> |
38 | <strong class="p-name" itemprop="name headline">$it.title$</strong> | 52 | <strong class="p-name" itemprop="name headline"> |
39 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | 53 | $it.title$ |
54 | </strong> | ||
55 | $if(it.draft)$ | ||
56 | <span class="o-badge u-ml-100">Draft</span> | ||
57 | $endif$ | ||
40 | </div> | 58 | </div> |
41 | $else$ | 59 | $else$ |
42 | <span class="p-name" itemprop="name headline"> | 60 | <span class="p-name" itemprop="name headline"> |
43 | $it.title$ | 61 | $it.title$ |
44 | </span> | 62 | </span> |
45 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | 63 | $if(it.draft)$ |
64 | <span class="o-badge u-ml-100">Draft</span> | ||
65 | $endif$ | ||
46 | $endif$ | 66 | $endif$ |
47 | </div> | 67 | </div> |
48 | $if(it.post_icon)$ | 68 | $if(it.post_icon)$ |
diff --git a/templates/partials/list_card.html b/templates/partials/list_card.html index 24948a6..e12f62f 100644 --- a/templates/partials/list_card.html +++ b/templates/partials/list_card.html | |||
@@ -4,7 +4,9 @@ | |||
4 | itemprop="dataFeedElement" | 4 | itemprop="dataFeedElement" |
5 | itemscope | 5 | itemscope |
6 | itemtype="https://schema.org/$it.schema_type$" | 6 | itemtype="https://schema.org/$it.schema_type$" |
7 | $if(it.rel)$rel="$it.rel$"$endif$ | 7 | $if(it.rel)$ |
8 | rel="$it.rel$" | ||
9 | $endif$ | ||
8 | > | 10 | > |
9 | <div class="c-card__row l-media"> | 11 | <div class="c-card__row l-media"> |
10 | $if(it.indicator)$ | 12 | $if(it.indicator)$ |
@@ -15,42 +17,22 @@ | |||
15 | <use href="$assets.icons_svg$#$it.icon$"></use> | 17 | <use href="$assets.icons_svg$#$it.icon$"></use> |
16 | </svg> | 18 | </svg> |
17 | $endif$ | 19 | $endif$ |
18 | <div class="l-media__block l-media__block--main u-d-none@sm-hi"> | 20 | <div class="l-media__block l-media__block--main"> |
19 | $if(it.subtitle)$ | 21 | <span class="p-name" itemprop="name headline"> |
20 | <small class="u-d-block">$it.subtitle$</small> | 22 | $it.title$ |
21 | <div> | 23 | </span> |
22 | <strong>$it.title$</strong> | 24 | $if(it.draft)$ |
23 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | 25 | <span class="o-badge u-ml-100">Draft</span> |
24 | </div> | ||
25 | $elseif(it.category)$ | ||
26 | <small class="u-d-block">$it.category$</small> | ||
27 | <div> | ||
28 | <strong>$it.title$</strong> | ||
29 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | ||
30 | </div> | ||
31 | $elseif(it.last_update)$ | ||
32 | <small> | ||
33 | <time datetime="$it.last_update.yyyy_mm_dd$">$it.last_update.long$</time> | ||
34 | </small> | ||
35 | <div> | ||
36 | <strong>$it.title$</strong> | ||
37 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | ||
38 | </div> | ||
39 | $else$ | ||
40 | <span> | ||
41 | $it.title$ | ||
42 | </span> | ||
43 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | ||
44 | $endif$ | 26 | $endif$ |
45 | </div> | ||
46 | <div class="l-media__block l-media__block--main u-d-none@sm-lo"> | ||
47 | <span class="p-name" itemprop="name headline">$it.title$</span> | ||
48 | $if(it.draft)$<span class="o-badge u-ml-100">Draft</span>$endif$ | ||
49 | </div> | 27 | </div> |
50 | $if(it.subtitle)$ | 28 | $if(it.subtitle)$ |
51 | <small class="l-media__block u-d-none@sm-lo">$it.subtitle$</small> | 29 | <small class="l-media__block u-d-none@sm-lo"> |
30 | $it.subtitle$ | ||
31 | </small> | ||
52 | $elseif(it.category)$ | 32 | $elseif(it.category)$ |
53 | <small class="l-media__block u-d-none@sm-lo">$it.category$</small> | 33 | <small class="l-media__block u-d-none@sm-lo"> |
34 | $it.category$ | ||
35 | </small> | ||
54 | $elseif(it.show_date)$ | 36 | $elseif(it.show_date)$ |
55 | <small class="l-media__block u-d-none@sm-lo"> | 37 | <small class="l-media__block u-d-none@sm-lo"> |
56 | <time datetime="$it.last_update.yyyy_mm_dd$" class="dt-updated" itemprop="dateModified"> | 38 | <time datetime="$it.last_update.yyyy_mm_dd$" class="dt-updated" itemprop="dateModified"> |