WIP: everything is on fire

This commit is contained in:
a 2024-11-13 11:24:48 -06:00
parent dbbf12a07c
commit 612b07672e
99 changed files with 1039 additions and 683 deletions

View file

@ -11,14 +11,28 @@
@import "components/table-of-contents"; @import "components/table-of-contents";
@import "components/site-header"; @import "components/site-header";
@import "components/site-footer";
// default layout // default layout
@import "layouts/_default/list"; @import "layouts/_default/list";
@import "components/feed-header"; @import "components/feed-header";
@import "components/feed-permalink";
@import "components/feed-entries"; @import "components/feed-entries";
@import "components/feed-entry";
@import "components/feed-entry-compact";
@import "components/feed-entry-in-series"; @import "components/feed-entry-in-series";
@import "layouts/_default/single"; @import "layouts/_default/single";
@import "components/article";
@import "components/article-header";
@import "components/article-authors";
@import "components/article-published-datetime";
@import "components/in-reply-to-prepend";
@import "components/article-tags";
@import "components/article-permalink";
@import "components/article-syndication-list";
@import "components/article-series-list";
@import "features/content"; @import "features/content";
@import "layouts/_default/_markup/render-heading"; @import "layouts/_default/_markup/render-heading";
@ -26,12 +40,10 @@
@import "layouts/partials/mf2/h-entry"; @import "layouts/partials/mf2/h-entry";
@import "layouts/partials/mf2/h-card"; @import "layouts/partials/mf2/h-card";
@import "layouts/partials/mf2/u-in-reply-to";
@import "components/admonition"; @import "components/admonition";
@import "components/quote-block"; @import "components/quote-block";
@import "components/codeblock"; @import "components/codeblock";
@import "components/series-list";
@import "components/syndication-list";
@import "components/alt-formats"; @import "components/alt-formats";
@import "features/footnotes"; @import "features/footnotes";

View file

@ -1,5 +1,5 @@
:root { :root {
--site-max-width: 120ch; --site-max-width: 100em;
} }
html { html {
@ -51,4 +51,8 @@ Containers are an immediate child <div>, purely for constraining width.
.container { .container {
padding: 0 2em; padding: 0 2em;
} }
}
.nobr {
display: inline-block;
} }

View file

@ -15,6 +15,7 @@
--ui-overlay-transparent: hsla(210, 100%, 87.5%, 0.4); --ui-overlay-transparent: hsla(210, 100%, 87.5%, 0.4);
--ui-overlay-text: var(--ui-text); --ui-overlay-text: var(--ui-text);
--ui-overlay-highlight: hsl(210, 100%, 80%); --ui-overlay-highlight: hsl(210, 100%, 80%);
--ui-overlay-deemphasized: hsl(210, 100%, 95%);
} }
@media (prefers-color-scheme: dark) { @media (prefers-color-scheme: dark) {
@ -35,5 +36,6 @@
--ui-overlay-transparent: hsla(210, 100%, 20%, 0.25); --ui-overlay-transparent: hsla(210, 100%, 20%, 0.25);
--ui-overlay-text: var(--ui-text); --ui-overlay-text: var(--ui-text);
--ui-overlay-highlight: hsl(210, 100%, 27.5%); --ui-overlay-highlight: hsl(210, 100%, 27.5%);
--ui-overlay-deemphasized: hsl(210, 100%, 5%);
} }
} }

View file

@ -51,6 +51,16 @@ figcaption {
padding-block: 1em; padding-block: 1em;
padding-inline: 1em; padding-inline: 1em;
} }
figure img {
display: block;
margin: 0 auto;
width: 100%;
}
figure img ~ figcaption {
background: var(--ui-overlay);
color: var(--ui-overlay-text);
text-align: center;
}
/* extra style and flair */ /* extra style and flair */
code { code {
background: var(--ui-overlay); background: var(--ui-overlay);

View file

@ -2,7 +2,7 @@ h1 {font-size: 2.027rem}
h2 {font-size: 1.802rem} h2 {font-size: 1.802rem}
h3 {font-size: 1.602rem} h3 {font-size: 1.602rem}
h4 {font-size: 1.424rem} h4 {font-size: 1.424rem}
h5 {font-size: 1.266rem} h5, .subtitle {font-size: 1.266rem}
h6 {font-size: 1.125rem} h6 {font-size: 1.125rem}
h1, h2, h3, h4, h5, h6 { h1, h2, h3, h4, h5, h6 {
line-height: 1.2; line-height: 1.2;

View file

@ -1,12 +1,36 @@
.alt-formats { .alt-formats {
.path, .mediaType {font-family: monospace;} .path, .mediaType {font-family: monospace;}
p { &-hint {
margin-block-end: 0; margin-block-end: 0;
display: grid;
place-items: start start;
grid-template-columns: auto 1fr;
&__text {
place-self: center start;
line-height: 1.5em;
}
&:before {
content: '';
display: inline-block;
background: var(--ui-overlay);
background-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9IndoaXRlIiBkPSJNOS44IDE0LjVoMS42bC44LTIuM2gzLjY1bC44IDIuM2gxLjU1bC0zLjQtOWgtMS42em0yLjg1LTMuNmwxLjMtMy43NWguMWwxLjMgMy43NXpNOCAxOHEtLjgyNSAwLTEuNDEyLS41ODdUNiAxNlY0cTAtLjgyNS41ODgtMS40MTJUOCAyaDEycS44MjUgMCAxLjQxMy41ODhUMjIgNHYxMnEwIC44MjUtLjU4NyAxLjQxM1QyMCAxOHptLTQgNHEtLjgyNSAwLTEuNDEyLS41ODdUMiAyMFY2aDJ2MTRoMTR2MnoiLz48L3N2Zz4=);
width: 1em;
height: 1em;
padding: 0.25em;
border-radius: 100em;
background-repeat: no-repeat;
background-size: 60%;
background-position-x: 45%;
background-position-y: 55%;
margin-inline-end: 0.5em;
}
} }
.alt-formats-list { .alt-formats-list {
margin-block-start: 0; margin-block-start: 0;
list-style: none;
&-item { &-item {
margin-block: 0; margin-block: 0;
margin-inline-start: 2em;
a {} a {}
} }
} }

View file

@ -0,0 +1,9 @@
.article-authors-hint {
display: none;
}
.article-authors {
list-style: none;
}
.article-author {
margin: 0;
}

View file

@ -0,0 +1,17 @@
.article-header {
hr {
display: none;
}
}
.article-title {
margin-block-start: 0;
line-height: 1.15;
letter-spacing: -0.022rem;
}
.article-summary {
font-style: italic;
font-size: 1.215rem;
line-height: 1.15;
letter-spacing: -0.022rem;
margin-block-start: 0.5rem;
}

View file

@ -0,0 +1,23 @@
.article-permalink {
display: grid;
place-items: start start;
grid-template-columns: auto 1fr;
&__text {
place-self: center start;
line-height: 1.5em;
}
&:before {
content: '';
display: inline-block;
background: var(--ui-overlay);
background-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9IndoaXRlIiBkPSJNMyAzdjE4aDE4VjN6bTE1IDE1SDZ2LTFoMTJ6bTAtMkg2di0xaDEyem0wLTRINlY2aDEyeiIvPjwvc3ZnPg==);
width: 1em;
height: 1em;
padding: 0.25em;
border-radius: 100em;
background-repeat: no-repeat;
background-position-x: 50%;
background-position-y: 47.5%;
margin-inline-end: 0.5em;
}
}

View file

@ -0,0 +1,29 @@
.article-published-datetime {
.time {
}
.date {
}
display: grid;
place-items: start start;
grid-template-columns: auto 1fr;
&__text {
place-self: center start;
line-height: 1.5em;
}
&:before {
content: '';
display: inline-block;
background: var(--ui-overlay);
background-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9IndoaXRlIiBkPSJNMTIgMkExMCAxMCAwIDAgMCAyIDEyYTEwIDEwIDAgMCAwIDEwIDEwYTEwIDEwIDAgMCAwIDEwLTEwQTEwIDEwIDAgMCAwIDEyIDJtNC4yIDE0LjJMMTEgMTNWN2gxLjV2NS4ybDQuNSAyLjd6Ii8+PC9zdmc+);
width: 1em;
height: 1em;
padding: 0.25em;
border-radius: 100em;
background-repeat: no-repeat;
background-position-x: 50%;
background-position-y: 47.5%;
margin-inline-end: 0.5em;
}
}

View file

@ -6,12 +6,13 @@
} }
.series-list { .series-list {
list-style: none; list-style: none;
padding-inline-start: 1em; padding-inline-start: 0em;
.current-post { .current-post {
font-weight: bold; font-weight: bold;
} }
.series-post { .series-post {
margin-block: 0.5em; margin-block: 0.5em;
margin-inline-start: 0;
&__part { &__part {
margin-inline-end: 0.5em; margin-inline-end: 0.5em;
} }

View file

@ -0,0 +1,32 @@
.article-syndication-hint {
margin-block-end: 0;
display: grid;
place-items: start start;
grid-template-columns: auto 1fr;
&__text {
place-self: center start;
line-height: 1.5em;
}
&:before {
content: '';
display: inline-block;
background: var(--ui-overlay);
background-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9IndoaXRlIiBkPSJNMTcgMjJxLTEuMjUgMC0yLjEyNS0uODc1VDE0IDE5cTAtLjE1LjA3NS0uN0w3LjA1IDE0LjJxLS40LjM3NS0uOTI1LjU4OFQ1IDE1cS0xLjI1IDAtMi4xMjUtLjg3NVQyIDEydC44NzUtMi4xMjVUNSA5cS42IDAgMS4xMjUuMjEzdC45MjUuNTg3bDcuMDI1LTQuMXEtLjA1LS4xNzUtLjA2Mi0uMzM3VDE0IDVxMC0xLjI1Ljg3NS0yLjEyNVQxNyAydDIuMTI1Ljg3NVQyMCA1dC0uODc1IDIuMTI1VDE3IDhxLS42IDAtMS4xMjUtLjIxM1QxNC45NSA3LjJsLTcuMDI1IDQuMXEuMDUuMTc1LjA2My4zMzhUOCAxMnQtLjAxMi4zNjN0LS4wNjMuMzM3bDcuMDI1IDQuMXEuNC0uMzc1LjkyNS0uNTg3VDE3IDE2cTEuMjUgMCAyLjEyNS44NzVUMjAgMTl0LS44NzUgMi4xMjVUMTcgMjIiLz48L3N2Zz4=);
width: 1em;
height: 1em;
padding: 0.25em;
border-radius: 100em;
background-repeat: no-repeat;
background-position: center;
margin-inline-end: 0.5em;
}
}
.article-syndication-list {
margin-block-start: 0;
list-style: none;
&-item {
margin-block: 0;
margin-inline-start: 2em;
.u-syndication {}
}
}

View file

@ -0,0 +1,24 @@
.article-tags {
display: grid;
place-items: start start;
grid-template-columns: auto 1fr;
&__text {
place-self: center start;
line-height: 1.5em;
}
&:before {
content: '';
display: inline-block;
background: var(--ui-overlay);
background-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9IndoaXRlIiBkPSJNNS41IDdBMS41IDEuNSAwIDAgMSA0IDUuNUExLjUgMS41IDAgMCAxIDUuNSA0QTEuNSAxLjUgMCAwIDEgNyA1LjVBMS41IDEuNSAwIDAgMSA1LjUgN20xNS45MSA0LjU4bC05LTlDMTIuMDUgMi4yMiAxMS41NSAyIDExIDJINGMtMS4xMSAwLTIgLjg5LTIgMnY3YzAgLjU1LjIyIDEuMDUuNTkgMS40MWw4Ljk5IDljLjM3LjM2Ljg3LjU5IDEuNDIuNTlzMS4wNS0uMjMgMS40MS0uNTlsNy03Yy4zNy0uMzYuNTktLjg2LjU5LTEuNDFjMC0uNTYtLjIzLTEuMDYtLjU5LTEuNDIiLz48L3N2Zz4=);
width: 1em;
height: 1em;
padding: 0.25em;
border-radius: 100em;
background-repeat: no-repeat;
background-position-x: 55%;
background-position-y: 55%;
background-size: 60%;
margin-inline-end: 0.5em;
}
}

View file

@ -0,0 +1,69 @@
.article {
h1 {font-size: 1.476rem}
h2 {font-size: 1.383rem}
h3 {font-size: 1.296rem}
h4 {font-size: 1.215rem}
h5 {font-size: 1.138rem}
h6 {font-size: 1.067rem}
&-footer {
hr {
display: none;
}
}
}
.article[has-toc] {
padding-block-end: 4em;
> .table-of-contents {display: none;}
#toc-toggle {
display: none;
&:checked ~ .table-of-contents {
display: block;
position: fixed;
z-index: 10;
inset-block-end: 6em;
block-size: max-content;
inline-size: 80%;
max-inline-size: 20em;
max-block-size: #{m}in(40em, 70vh);
overflow-block: scroll;
inset-inline-end: 1em;
background: var(--ui-overlay);
border-radius: 1em;
@include shadow-low;
padding-inline: 1em;
> .container {
padding: 0;
}
}
}
label[for="toc-toggle"] {
position: fixed;
inset-block-end: 1em;
inset-inline-end: 1em;
z-index: 5;
background: var(--ui-overlay);
padding: 1em;
border-radius: 100em;
inline-size: 6em;
display: flex;
justify-content: center;
@include shadow-low;
}
#toc-toggle ~ label[for="toc-toggle"] {
}
#toc-toggle:checked ~ label[for="toc-toggle"] {
}
#toc-toggle__label-hide {
display: none;
}
#toc-toggle:checked ~ #toc-toggle__label-hide {
display: flex;
}
#toc-toggle:checked ~ #toc-toggle__label-show {
display: none;
}
}

View file

@ -1,12 +1,15 @@
.feed-entries { .feed-entries {
inline-size: 100%; inline-size: 100%;
max-inline-size: 80ch;
margin-inline: auto;
&-list { &-list {
list-style: none; list-style: none;
padding-inline-start: 0; padding-inline-start: 0;
margin-block: 0;
&-item { &-item {
margin-inline-start: 0; margin-inline-start: 0;
margin-block: 2em;
&:first-child {
margin-block-start: 0;
}
} }
} }
} }

View file

@ -0,0 +1,27 @@
.feed-entry-compact {
border-left: 0.25em solid var(--ui-overlay);
padding-left: 1em;
border-top: 0.25em solid var(--ui-overlay);
padding-top: 1em;
&__header {
}
&__title {
font-size: 1rem;
margin: 0;
line-height: 2;
}
&__summary {
grid-area: summary;
}
&__footer {
}
&__date {
margin: 0;
line-height: 1;
&:after {
content: ': '
}
}
}

View file

@ -1,23 +1,28 @@
.feed-entry-in-series { .feed-entry-in-series {
background: var(--ui-overlay);
padding: 1em;
&__header {} &__header {}
&__part { &__part {
margin: 0; margin: 0;
font-size: 1em;
display: inline-block; display: inline-block;
font-variant: small-caps;
} }
&__title { &__title {
margin: 0; margin: 0;
font-size: 1em; display: grid;
display: inline-grid; place-items: start;
place-items: center; margin-block-end: 0.5em;
a { a {
display: grid; display: grid;
} }
} }
&__summary { &__summary {
font-style: italic; font-size: 1rem
} }
&__date { &__date {
margin: 0; margin: 0;
} }
&__readmore {
margin-block-end: 0;
}
} }

View file

@ -0,0 +1,17 @@
.feed-entry {
&__header {
}
&__title {
margin-block-start: 0;
}
&__summary {
}
&__footer {
}
&__date {
}
}

View file

@ -2,8 +2,6 @@
hr {display: none;} hr {display: none;}
.container { .container {
inline-size: 100%; inline-size: 100%;
max-inline-size: 80ch;
margin-inline: auto;
} }
} }
.feed-title { .feed-title {
@ -13,7 +11,15 @@
letter-spacing: -0.022rem; letter-spacing: -0.022rem;
grid-area: title; grid-area: title;
} }
.feed-author {} .feed-authors-hint {
display: none;
}
.feed-authors {
list-style: none;
}
.feed-author {
margin: 0;
}
.feed-summary { .feed-summary {
font-style: italic; font-style: italic;
font-size: 1.266rem; font-size: 1.266rem;

View file

@ -0,0 +1,23 @@
.feed-permalink {
display: grid;
place-items: start start;
grid-template-columns: auto 1fr;
&__text {
place-self: center start;
line-height: 1.5em;
}
&:before {
content: '';
display: inline-block;
background: var(--ui-overlay);
background-image: url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxZW0iIGhlaWdodD0iMWVtIiB2aWV3Qm94PSIwIDAgMjQgMjQiPjxwYXRoIGZpbGw9IndoaXRlIiBkPSJNNSAyMXEtLjgyNSAwLTEuNDEyLS41ODdUMyAxOXQuNTg4LTEuNDEyVDUgMTd0MS40MTMuNTg4VDcgMTl0LS41ODcgMS40MTNUNSAyMW0xMiAwcTAtMi45MjUtMS4xLTUuNDYydC0zLTQuNDM4dC00LjQzNy0zVDMgN1Y0cTMuNTUgMCA2LjYyNSAxLjMyNXQ1LjQgMy42NXQzLjY1IDUuNFQyMCAyMXptLTYgMHEwLTEuNjc1LS42MjUtMy4xMTNUOC42NSAxNS4zNXQtMi41MzctMS43MjVUMyAxM3YtM3EyLjMgMCA0LjI4OC44NjN0My40ODcgMi4zNjJ0Mi4zNjMgMy40ODhUMTQgMjF6Ii8+PC9zdmc+);
width: 1em;
height: 1em;
padding: 0.25em;
border-radius: 100em;
background-repeat: no-repeat;
background-position-x: 60%;
background-position-y: 40%;
margin-inline-end: 0.5em;
}
}

View file

@ -16,7 +16,8 @@
padding: 0.25em; padding: 0.25em;
border-radius: 100em; border-radius: 100em;
background-repeat: no-repeat; background-repeat: no-repeat;
background-position: center; background-position-x: center;
background-position-y: 45%;
margin-inline-end: 0.5em; margin-inline-end: 0.5em;
} }
} }

View file

@ -56,7 +56,10 @@
background: var(--ui-overlay-transparent); background: var(--ui-overlay-transparent);
} }
&__header { &__header {
padding-block: 1em; padding-block-start: 1em;
}
&__header:has(&__card) {
padding-block-end: 1em;
} }
&__content, &__footer { &__content, &__footer {
padding-block-end: 1em; padding-block-end: 1em;

View file

@ -0,0 +1,31 @@
.site-footer {
hr {
display: none;
}
.on-this-site {
h2 {
font-size: 1.383rem;
margin: 0;
}
h3 {
font-size: 1.296rem;
margin: 0;
}
ul {
list-style: none;
margin: 0;
display: flex;
flex-flow: row wrap;
gap: 0em 1em;
}
li {
margin: 0;
}
}
.on-this-site-sections {
}
.on-this-site-taxonomies {
}
}

View file

@ -1,10 +0,0 @@
.syndication-hint {
margin-block-end: 0;
}
.syndication-list {
margin-block-start: 0;
&-item {
margin-block: 0;
.u-syndication {}
}
}

View file

@ -5,9 +5,9 @@ body {
} }
.back-to-top { .back-to-top {
position: absolute;
inset-block-end: 1em; inset-block-end: 1em;
inset-inline-start: -12em; inset-inline-start: 1em;
transition: 0.25s all ease-in; transition: 0.25s all ease-in;
background: var(--ui-overlay); background: var(--ui-overlay);
color: var(--ui-overlay-text) !important; color: var(--ui-overlay-text) !important;
@ -20,8 +20,7 @@ body {
.skip-to-items { .skip-to-items {
position: absolute; position: absolute;
inset-block-start: -5em; inset-block-start: -10em;
inset-inline-start: 1em;
transition: all 0.25s ease-in; transition: all 0.25s ease-in;
background: var(--ui-overlay); background: var(--ui-overlay);
color: var(--ui-overlay-text) !important; color: var(--ui-overlay-text) !important;
@ -32,9 +31,9 @@ body {
} }
} }
.skip-syndication { .skip-metadata {
position: absolute; position: absolute;
inset-block-start: -5em; inset-block-start: -10em;
inset-inline-start: 1em; inset-inline-start: 1em;
transition: 0.25s all ease-in; transition: 0.25s all ease-in;
background: var(--ui-overlay); background: var(--ui-overlay);
@ -45,6 +44,6 @@ body {
inset-block-start: 1em; inset-block-start: 1em;
} }
&:before { &:before {
content: "Skip syndication information"; content: "Skip further metadata";
} }
} }

View file

@ -1,24 +1,14 @@
.rendered-heading { .rendered-heading {
display: grid;
grid-template-columns: 1fr auto;
gap: 0.5em;
&:is(h2) { &:is(h2) {
border-block-end: 1px solid var(--ui-text-muted); border-block-end: 1px solid var(--ui-overlay);
padding-block-end: 1rem; padding-block-end: 1rem;
} }
&__text { &__text {
grid-column: 1;
} }
&__anchor-link { &__anchor-link {
grid-column: 2;
line-height: 1em;
margin-block-start: 0.15em;
display: grid;
place-items: center;
align-self: start;
&:before { &:before {
content: "[link]"; content: "§ link";
display: inline-block;
font-size: 1rem; font-size: 1rem;
} }
} }

View file

@ -1,3 +1,2 @@
.layout-_default-list { .layout-_default-list {
} }

View file

@ -1,203 +1,73 @@
.layout-_default-single {
.page-header {
hr {display: none;}
.container {
max-inline-size: 80ch;
margin-inline: auto;
}
}
.page-title {
margin-block-start: 0;
font-size: 2.025rem;
line-height: 1.15;
letter-spacing: -0.022rem;
grid-area: title;
}
.page-summary {
font-style: italic;
font-size: 1.266rem;
line-height: 1.15;
letter-spacing: -0.022rem;
margin-block-start: 0.5rem;
grid-area: summary;
}
.page-author {
grid-area: author;
margin-block: 0;
}
.page-date {
grid-area: date;
margin-block-end: 0;
.date {display: inline-block;}
}
.page-inreplyto {
display: grid;
grid-template-columns: auto 1fr;
gap: 0.5em;
align-items: center;
.reply-icon {
background: var(--ui-overlay);
display: inline-block;
inline-size: 1em;
block-size: 1em;
padding: 0.25em;
border-radius: 100em;
}
}
.page-tags {
.page-tag {
font-family: monospace;
}
}
.page-permalink {
margin-block-end: 0;
align-self: end;
.u-url {font-family: monospace;}
}
.page-syndication {
}
.page-series {
hr {display: none;}
// background: var(--ui-overlay);
// color: var(--ui-overlay-text);
.container {
max-inline-size: 80ch;
margin-inline: auto;
}
}
.page-content {
inline-size: 100%;
max-inline-size: 80ch;
margin-inline: auto;
}
.page-footer {
hr {display: none;}
inline-size: 100%;
max-inline-size: 80ch;
margin-inline: auto;
}
.page[has-toc] {
padding-block-end: 4em;
}
.page > .table-of-contents {
display: none;
}
#toc-toggle {
display: none;
&:checked ~ .table-of-contents {
display: block;
position: fixed;
z-index: 10;
inset-block-end: 6em;
block-size: max-content;
inline-size: 80%;
max-inline-size: 20em;
max-block-size: #{m}in(40em, 70vh);
overflow-block: scroll;
inset-inline-end: 1em;
background: var(--ui-overlay);
border-radius: 1em;
@include shadow-low;
padding-inline: 1em;
> .container {
padding: 0;
}
}
}
label[for="toc-toggle"] {
position: fixed;
inset-block-end: 1em;
inset-inline-end: 1em;
z-index: 5;
background: var(--ui-overlay);
padding: 1em;
border-radius: 100em;
inline-size: 6em;
display: flex;
justify-content: center;
@include shadow-low;
}
#toc-toggle ~ label[for="toc-toggle"] {
}
#toc-toggle:checked ~ label[for="toc-toggle"] {
}
#toc-toggle__label-hide { // .page[has-toc] {
display: none; // padding-block-end: 4em;
} // }
#toc-toggle:checked ~ #toc-toggle__label-hide { // .page > .table-of-contents {
display: flex; // display: none;
} // }
#toc-toggle:checked ~ #toc-toggle__label-show {
display: none; // @media (min-width: 400px) {
} // .container {
@media (min-width: 400px) { // padding: 0 2em;
.container { // }
padding: 0 2em; // }
} // @media (min-width: 60rem) {
} // label[for="toc-toggle"] {
@media (min-width: 60rem) { // display: none;
label[for="toc-toggle"] { // }
display: none; // .page[has-toc] {
} // inline-size: 100%;
.container {padding: 0;} // max-inline-size: var(--site-max-width);
.page[has-toc] { // margin-inline: auto;
display: grid; // display: grid;
grid-template-columns: 1fr minmax(37em, 80ch) minmax(17em, 20em) 1fr; // grid-template-columns: minmax(37em, 1fr) minmax(17em, 20em);
grid-template-rows: auto auto auto; // grid-template-rows: auto auto auto;
gap: 2em; // gap: 2em;
padding-block-end: unset; // padding-block-end: unset;
.page-header { // .page-header {
grid-column: 1 / span 4; // grid-column: 1 / span 2;
grid-row: 1; // grid-row: 1;
display: grid; // }
grid-template-columns: 1fr minmax(37em, 80ch) minmax(17em, 20em) 1fr; // .table-of-contents {
gap: 2em; // display: block;
.container { // grid-column: 2;
max-width: unset; // grid-row: 2;
grid-column: 2 / span 2; // position: sticky;
} // inset-block-start: 2em;
} // align-self: start;
.table-of-contents { // justify-self: start;
display: block; // max-width: unset;
grid-column: 3; // border-inline-start: thin solid var(--ui-overlay);
grid-row: 2 / span 2; // padding-inline: 2em;
position: sticky; // max-height: 90vh;
inset-block-start: 2em; // overflow-y: auto;
align-self: start; // scrollbar-color: var(--ui-text) var(--ui-overlay);
justify-self: start; // &::-webkit-scrollbar-thumb {
max-width: unset; // background-color: var(--ui-text)
border-inline-start: thin solid var(--ui-overlay); // }
padding-inline: 2em; // &::-webkit-scrollbar-track {
max-height: 90vh; // background-color: var(--ui-overlay)
overflow-y: auto; // }
scrollbar-color: var(--ui-text) var(--ui-overlay); // }
&::-webkit-scrollbar-thumb { // .page-content {
background-color: var(--ui-text) // grid-column: 1;
} // grid-row: 2;
&::-webkit-scrollbar-track { // max-width: unset;
background-color: var(--ui-overlay) // padding-block-start: 0.5rem;
} // padding-block-end: 0;
} // .toc {
.page-content { // display: none;
grid-column: 2; // }
grid-row: 2; // }
max-width: unset; // .page-footer {
padding-block-start: 0.5rem; // grid-column: 1;
padding-block-end: 0; // grid-row: 3;
.toc { // max-width: unset;
display: none; // #footnotes h2 {margin-block-start: 0;}
} // padding-block: 0;
} // }
.page-footer { // }
grid-column: 2; // }
grid-row: 3; // }
max-width: unset;
#footnotes h2 {margin-block-start: 0;}
padding-block: 0;
}
}
}
}

View file

@ -13,12 +13,14 @@
} }
} }
.section-title { .section-header {
font-size: 2em;
border-block-end: 1px solid var(--ui-text-muted); border-block-end: 1px solid var(--ui-text-muted);
padding-block-end: 0.5em; padding-block-end: 0.5em;
}
.section-title {
font-size: 2em;
margin-block-start: 0; margin-block-start: 0;
margin-block-end: 1em; margin-block-end: 0;
} }
.subsections-title, .subsections-title,
.subpages-title { .subpages-title {

View file

@ -23,14 +23,14 @@ src = "opengraph.jpg"
The FTC is suing AT&T over its mobile data policies, particularly throttling "unlimited" customers. [AT&T filed a motion to dismiss this suit](https://arstechnica.com/tech-policy/2015/01/att-defends-unlimited-data-throttling-says-the-ftc-cant-stop-it/), saying that since AT&T is a common carrier, they fall under the jurisdiction of the FCC instead. The FTC is suing AT&T over its mobile data policies, particularly throttling "unlimited" customers. [AT&T filed a motion to dismiss this suit](https://arstechnica.com/tech-policy/2015/01/att-defends-unlimited-data-throttling-says-the-ftc-cant-stop-it/), saying that since AT&T is a common carrier, they fall under the jurisdiction of the FCC instead.
<figure> <figure>
<img src="ftc.jpg" alt="Ars Technica headline, January 8, 2015: AT&T defends unlimited data throttling, says the FTC can't stop it" /> <img src="ftc.jpg" alt="Per an Ars Technica headline, January 8, 2015: AT&T defends unlimited data throttling, says the FTC can't stop it." />
<figcaption>"You have no power here. Only the FCC can stop us."</figcaption> <figcaption>"You have no power here. Only the FCC can stop us."</figcaption>
</figure> </figure>
Except just a few days later, [AT&T tells the FCC](https://arstechnica.com/information-technology/2015/01/att-tells-fcc-it-cant-treat-mobile-data-as-a-common-carrier-service/) that mobile data doesn't fall under common carrier rules, and cannot be regulated without Title II. Except just a few days later, [AT&T tells the FCC](https://arstechnica.com/information-technology/2015/01/att-tells-fcc-it-cant-treat-mobile-data-as-a-common-carrier-service/) that mobile data doesn't fall under common carrier rules, and cannot be regulated without Title II.
<figure> <figure>
<img src="fcc.jpg" alt="Ars Technica headline, January 9, 2015: AT&T tells FCC it can't treat mobile data as a common carrier service." /> <img src="fcc.jpg" alt="Per an Ars Technica headline, January 9, 2015: AT&T tells FCC it can't treat mobile data as a common carrier service." />
<figcaption>"You can't stop us. You don't have that power."</figcaption> <figcaption>"You can't stop us. You don't have that power."</figcaption>
</figure> </figure>

View file

@ -1,9 +1,9 @@
+++ +++
title = "What makes a unified messaging client perfect?" title = "What makes a unified messaging client perfect?"
summary = "A rant in which I focus on what I like and hate about messaging apps, the characteristics I would implement if I were designing the perfect unified mobile messenger, and which current offerings are the closest to perfect." summary = "A rant in which I focus on what I like and hate about messaging apps, the characteristics I would implement if I were designing the perfect unified mobile messenger, and which current offerings are the closest to perfect."
date = 2014-08-08T12:00:00-06:00 date = 2014-08-08T12:00:00-05:00
tags = [] tags = ["unified messaging", "communication"]
categories = [] streams = []
[[params.syndication]] [[params.syndication]]
name = "Medium" name = "Medium"
url = "https://medium.com/trwnh/what-makes-a-unified-messaging-client-perfect-322a83e3aa64" url = "https://medium.com/trwnh/what-makes-a-unified-messaging-client-perfect-322a83e3aa64"

View file

@ -1,2 +1,3 @@
+++ +++
title = "wiki"
+++ +++

View file

@ -1,2 +1,3 @@
+++ +++
summary = "things that need clarification. could be improved by a rewrite."
+++ +++

View file

@ -0,0 +1,15 @@
i personally see attachment as a way to append sidecar things, similar to how in email you would say "i have attached..." or "see attached for..."
i see tag as a way to generically list a bunch of related things, similar to how you might say "see also..."
attachment is "included" in the object, while the tag is not; it is just a "reference". but it's a reference without a relation.
attachment is a kind of "here's some stuff i'm including with my object because you might/probably need to do something with it". in that sense, it's similar to instrument on an Activity, but less specific (and also available to non-Activity objects). you attach something as (fundamentally) "part of" the current object.
tag is a kind of "these things may be considered relevant so i'm "tagging" a reference to them". in that sense, it's similar to context on an Object, but far less specific (and without the purpose or meaning imparted by context). you tag something as (fundamentally) "related to" the current object.
things that (are intended to) go in attachment are usually some kind of media, but there's no universal processing rules for what to do when you encounter something with an attachment. i think hubzilla used to treat attachment as "show this thing below the content" at some point? so before FEP-e232 they would just put a Note in attachment. this is kind of like attaching an email as a file to some other email. note that this isn't the same semantically as "quoting", but it relies on display-specific implementation logic to serve a similar purpose.
things that (are intended to) go in tag are usually some kind of taxonomy. there's no universal processing rules here either, but the expectation is that you can use them taxonomically to link to other related objects. for example, i might tag an Image with a Person, as a way of saying that the Person is related to the Image. i might filter some set of objects for all objects that include that have a tag of that Person.
see also [tag-for-actual-taxonomy]({{< relref "tag-for-actual-taxonomy" >}})

View file

@ -1,5 +1,4 @@
+++ +++
tags = ["wrong"]
+++ +++
i kinda don't like most todo apps because they don't really mesh with how i think. maybe i just don't vibe with the GTD-inspired flow most apps use. the only app i've seen do tasks/todos in an actually useful way is Things 3 for iOS. i kinda don't like most todo apps because they don't really mesh with how i think. maybe i just don't vibe with the GTD-inspired flow most apps use. the only app i've seen do tasks/todos in an actually useful way is Things 3 for iOS.

View file

@ -4,6 +4,8 @@ name = "~a | monologues"
summary = "assorted musings. mostly a compilation of times i replied to myself on social media or in chat. what you see here is minimally curated and lightly formatted. it might disappear at any time or be upgraded to a proper or formal writing at some point." summary = "assorted musings. mostly a compilation of times i replied to myself on social media or in chat. what you see here is minimally curated and lightly formatted. it might disappear at any time or be upgraded to a proper or formal writing at some point."
[pagination] [pagination]
pagerSize = 100 pagerSize = 100
[params]
compactEntries = true
+++ +++
[[rejected outtakes]](misc) [[rejected outtakes]](misc)

View file

@ -1,10 +1,10 @@
+++ +++
title = "microsyntaxes in fedi were probably a mistake" title = "microsyntaxes in fedi were probably a mistake"
summary = "i am... moderately worried that we might be doubling down on a fundamentally flawed abstraction here [...] in effect, by specifying fallback behavior and representations, we are actually **making it harder for your average consumer to understand** [...] a whole swathe of other functionality that relies on them processing the `content` in such a way that transforms it." summary = "i am... *moderately worried* that we might be doubling down on a fundamentally flawed abstraction here [...] in effect, by specifying fallback behavior and representations, we are actually **making it harder for your average consumer to understand** [...] a whole swathe of other functionality that relies on them processing the `content` in such a way that transforms it."
date = 2024-11-08T10:48:00-06:00 date = 2024-11-08T10:48:00-06:00
draft = true streams = []
streams = ["all"]
tags = [] tags = []
source = "https://github.com/mastodon/draft-feps/pull/3#discussion_r1834717926"
+++ +++
> the `name` and federated `content` do not match > the `name` and federated `content` do not match
@ -75,7 +75,7 @@ in plain english, "this Image is related to Sally". we might get clever and pars
for the issue of "quote tags" where the "quote" is part of the content, we are not really saying that "this Note is related to this Link", but rather we are saying "this facet of `content` (as indicated by `name`?) should be marked up as a `Link` with a `preview`." specifically, the `preview` might be an Object that is a "post". but this is only one way of doing it. for the issue of "quote tags" where the "quote" is part of the content, we are not really saying that "this Note is related to this Link", but rather we are saying "this facet of `content` (as indicated by `name`?) should be marked up as a `Link` with a `preview`." specifically, the `preview` might be an Object that is a "post". but this is only one way of doing it.
i am... moderately worried that we might be doubling down on a fundamentally flawed abstraction here. i am... *moderately worried* that we might be doubling down on a fundamentally flawed abstraction here.
i think we should give more consideration to what the expected behavior of producers and consumers might be here. for example, might we say that producers are expected to mark up a "quote" in such a way that the consumer doesn't have to parse the `content` for microsyntaxes? because i think we might be overloading `tag` in a way that is detrimental to future uses that are more "proper" to what it's supposed to mean. i think we should give more consideration to what the expected behavior of producers and consumers might be here. for example, might we say that producers are expected to mark up a "quote" in such a way that the consumer doesn't have to parse the `content` for microsyntaxes? because i think we might be overloading `tag` in a way that is detrimental to future uses that are more "proper" to what it's supposed to mean.

View file

@ -1,6 +1,6 @@
+++ +++
title = "" title = "date ranges on contact info (address, phone, email)"
summary = "" summary = "Addresses are not owned. They are leased [...] People move houses all the time, so their address changes. In the same way, people change digital addresses like phone numbers [...] \"X was using this phone number between 2011-01-01 and 2015-06-01.\" For messaging archives you can now reliably dereference a phone number to a contact name, without having to worry about who has the phone number *now*."
date = 2019-08-20T02:09:00-05:00 date = 2019-08-20T02:09:00-05:00
source = "https://mastodon.social/@trwnh/102648053339382526" source = "https://mastodon.social/@trwnh/102648053339382526"
tags = ["wrong"] tags = ["wrong"]

View file

@ -2,6 +2,7 @@
title = "fully responsive web design" title = "fully responsive web design"
summary = "my pipe dream is to redesign my website to be fully responsive -- not across mere pixel widths, but by aspect ratio and overall size" summary = "my pipe dream is to redesign my website to be fully responsive -- not across mere pixel widths, but by aspect ratio and overall size"
date = 2018-04-22T10:42:00-05:00 date = 2018-04-22T10:42:00-05:00
updated = 2024-11-11T05:58:10-06:00
source = "https://mastodon.social/@trwnh/99903847448978099" source = "https://mastodon.social/@trwnh/99903847448978099"
+++ +++
@ -9,4 +10,36 @@ my pipe dream is to redesign my website to be fully responsive -- not across mer
does anyone consider what their website looks like when it's fullscreened across one of those samsung 3840x1080 monitors? probably not, and why would you? does anyone consider what their website looks like when it's fullscreened across one of those samsung 3840x1080 monitors? probably not, and why would you?
but i do but i do
---
## refinement
let's say the base case is when the aspect ratio is square
you can set width-based breakpoints as usual, but logically extend your approach to multiple different media query sets
- one height-based breakpoint for when there is less than some minimum required height? ("too small" mode)
- one for when there is less than a square aspect ratio (landscape mode)
- one for everything beyond that (portrait mode)
so you might have for example assuming liberal use of breakpoints:
- min-width 320, min-height 320
- min-width 400, min-height 320
- min-width 400, min-height 400
- min-width 480, min-height 320
- min-width 480, min-height 480
- min-width 600, min-height 320
- min-width 600, min-height 600
- min-width 800
- min-width 960
- min-width 1150
- min-width 1320
- min-width 1560
- ...
notice we stopped taking height into account past a certain point, because we are assuming the page content is flowing vertically and will overflow the viewport in the vertical direction. if we were designing a site that flowed horizontally then we would continue in the height axis (and perhaps cap off the width queries at some point instead).
for more extreme widths it becomes more interesting to consider those horizontal flows although it should be recognized that this is niche.

View file

@ -1,6 +1,6 @@
+++ +++
title = "" title = "i wish personal websites were more personal"
summary = "" summary = "when i say \"personal website\" i do not mean a portfolio. i do not mean a page for potential employers to hire you. i mean like a place to be yourself and how to express yourself to others."
date = 2023-01-02T04:51:00-06:00 date = 2023-01-02T04:51:00-06:00
source = [ source = [
"https://mastodon.social/@trwnh/109593314053174200", "https://mastodon.social/@trwnh/109593314053174200",

View file

@ -0,0 +1,4 @@
+++
title = "series"
summary = "content pages that follow up on each other"
+++

View file

@ -16,6 +16,7 @@
"path" .id "path" .id
"kind" "term" "kind" "term"
}} }}
{{/* TODO: kind=term causes a "term is empty" error */}}
{{ $.Store.Set (urlize $id) true }}{{/* mark this tag as already having a page */}} {{ $.Store.Set (urlize $id) true }}{{/* mark this tag as already having a page */}}
{{ $.AddPage $page }} {{ $.AddPage $page }}
@ -29,6 +30,7 @@
"path" . "path" .
"kind" "term" "kind" "term"
}} }}
{{/* TODO: kind=term causes a "term is empty" error */}}
{{ $.Store.Set (urlize .) true }}{{/* mark this tag as already having a page */}} {{ $.Store.Set (urlize .) true }}{{/* mark this tag as already having a page */}}
{{ $.AddPage $page }} {{ $.AddPage $page }}
{{ end }} {{ end }}

View file

@ -0,0 +1,4 @@
+++
title = "tags"
summary = "terms and keywords that are related to a page."
+++

View file

@ -1,5 +0,0 @@
+++
layout = "page"
+++
test

View file

@ -0,0 +1,16 @@
+++
title = "how to handle networking in a social web"
summary = "you should be able to make a new social app without starting over on network effects. the key is in consenting to people messaging you, but separately being able to signal interest in specific subsets of messages."
date = 2024-11-10T03:56:12-06:00
toc = true
draft = true
streams = ["all"]
tags = []
+++
## problem statement
You want to manage your network of contacts separately from all other apps -- this is the "bsky problem" where the data for apps is tied up in records which are stored in repos that are validated against schemas and namespaced to lexicons.
When starting a new networked app (anything where messages or publishing might be involved), you want to be able to bootstrap off of your existing network of contacts and followers.

View file

@ -1,5 +1,5 @@
+++ +++
title = "so you want to make a social communication protocol" title = "social web foundations: defining posts, contexts, and audiences"
summary = "looking at prior art and synthesizing a data model that makes sense as the foundation for a protocol" summary = "looking at prior art and synthesizing a data model that makes sense as the foundation for a protocol"
date = 2024-10-20T03:58:55-05:00 date = 2024-10-20T03:58:55-05:00
toc = true toc = true
@ -7,8 +7,6 @@ autonumbering = false
draft = true draft = true
streams = ["all"] streams = ["all"]
tags = ["activitypub", "activity streams", "as2", "fedi", "indieweb", "social web", "social networking", "social media", "social communication", "social"] tags = ["activitypub", "activity streams", "as2", "fedi", "indieweb", "social web", "social networking", "social media", "social communication", "social"]
series = "fedi and the social web 2024"
series_part = "3"
+++ +++
## Things vs References ## Things vs References

View file

@ -8,5 +8,6 @@
"id": "as2", "id": "as2",
"name": "Activity Streams 2.0", "name": "Activity Streams 2.0",
"summary": "This specification details a model for representing potential and completed activities using the JSON format. It is intended to be used with vocabularies that detail the structure of activities, and define specific types of activities.", "summary": "This specification details a model for representing potential and completed activities using the JSON format. It is intended to be used with vocabularies that detail the structure of activities, and define specific types of activities.",
"alsoKnownAs": ["activitystreams", "activity streams 2.0"] "alsoKnownAs": ["activitystreams", "activity streams 2.0", "activity streams"],
"url": "activitystreams"
} }

View file

@ -49,7 +49,7 @@ suffixes = ["atom"]
suffixes = ["jsonfeed"] # not a standard but whatever suffixes = ["jsonfeed"] # not a standard but whatever
[mediaTypes."application/jf2feed+json"] [mediaTypes."application/jf2feed+json"]
suffixes = ["json"] suffixes = ["jf2feed"]
[mediaTypes."application/activity+json"] [mediaTypes."application/activity+json"]
suffixes = ["as2"] # not a standard but whatever suffixes = ["as2"] # not a standard but whatever
@ -91,6 +91,12 @@ tag = "tags"
series = "series" series = "series"
stream = "streams" stream = "streams"
[params.author] # TODO: what other params make sense here? should probably also allow setting this in .Site.Data or maybe even in a /people taxonomy? [params]
summary = "trwnh.com is the personal site of a"
themeColor = "#001a33"
icon = "/.assets/icon.png"
[[params.author]]
name = "a" name = "a"
# url = "" url = "https://trwnh.com"
icon = "/.assets/icon.png"

View file

@ -1,5 +1,5 @@
<h{{.Level}} class="rendered-heading" id="{{.Anchor | safeURL}}">{{- /* chomp whitespace */ -}} <h{{.Level}} class="rendered-heading" id="{{.Anchor | safeURL}}">{{- /* chomp whitespace */ -}}
<span class="rendered-heading__text">{{.Text | safeHTML}}</span>{{- /* chomp whitespace */ -}} <span class="rendered-heading__text">{{.Text | safeHTML}}</span> {{/* chomp whitespace */ -}}
<a class="rendered-heading__anchor-link" href="#{{.Anchor | safeURL}}" aria-hidden="true">{{- /* chomp whitespace */ -}} <a class="rendered-heading__anchor-link" href="#{{.Anchor | safeURL}}" aria-hidden="true">{{- /* chomp whitespace */ -}}
</a>{{- /* chomp whitespace */ -}} </a>{{- /* chomp whitespace */ -}}
</h{{.Level}}> </h{{.Level}}>

View file

@ -4,12 +4,7 @@
{{- define "body" }} {{- define "body" }}
<body class="layout-_default-list"> <body class="layout-_default-list">
{{ partial "site-header.html" . }} {{ partial "site-header.html" . }}
<main class="h-feed hfeed feed" id="main"> {{ partial "components/feed.html" (dict "ctx" .) }}
{{ "<!-- the main header contains list metadata -->" | safeHTML }}
{{ partial "components/feed-header.html" . }}
{{ $pages := .RegularPages }}
{{ partial "components/feed-entries.html" $pages }}
</main>
{{ partial "site-footer.html" . }} {{ partial "site-footer.html" . }}
</body> </body>
{{- end }} {{- end }}

View file

@ -11,16 +11,16 @@
{{- /* next_url = allows for pagination but i don't think i have to worry about that yet. TODO:?*/}} {{- /* next_url = allows for pagination but i don't think i have to worry about that yet. TODO:?*/}}
"icon": "https://trwnh.com/.assets/icon.png", {{- /* TODO: make this variable (512x512?) */}} "icon": "https://trwnh.com/.assets/icon.png", {{- /* TODO: make this variable (512x512?) */}}
"favicon": "https://trwnh.com/.assets/icon.png", {{- /* TODO: make this variable and also 64x64 */}} "favicon": "https://trwnh.com/.assets/icon.png", {{- /* TODO: make this variable and also 64x64 */}}
"authors": [ {{- /* TODO: make this variable and also loopable? */}} "authors": [ {{- /* TODO: make it variable and loopable */}}
{ {
"name": {{ (or .Params.author.name .Site.Params.author.name ) | jsonify }}, "name": "a",
"url": {{ (or .Params.author.url .Site.Params.author.url .Site.Home.Permalink .Site.BaseURL) | jsonify }}, "url": "https://trwnh.com",
"avatar": "https://trwnh.com/.assets/icon.png" {{- /* TODO: make this variable (512x512?) */}} "avatar": "https://trwnh.com/.assets/icon.png" {{- /* TODO: make this variable (512x512?) */}}
} }
], ],
"author": { {{- /* TODO: make this variable */}} "author": { {{- /* TODO: make it variable */}}
"name": {{ (or .Params.author.name .Site.Params.author.name ) | jsonify }}, "name": "a",
"url": {{ (or .Params.author.url .Site.Params.author.url .Site.Home.Permalink .Site.BaseURL) | jsonify }}, "url": "https://trwnh.com",
"avatar": "https://trwnh.com/.assets/icon.png" {{- /* TODO: make this variable (512x512?) */}} "avatar": "https://trwnh.com/.assets/icon.png" {{- /* TODO: make this variable (512x512?) */}}
}, },
"language": {{ (or .Language.LanguageCode .Site.Language.LanguageCode) | jsonify }}, "language": {{ (or .Language.LanguageCode .Site.Language.LanguageCode) | jsonify }},
@ -61,14 +61,14 @@
{{- end }}, {{- end }},
"authors": [ {{- /* TODO: make this variable and also loopable? or should this be omitted since it's implied by the top-level prop? maybe omit it only when it's equal? */}} "authors": [ {{- /* TODO: make this variable and also loopable? or should this be omitted since it's implied by the top-level prop? maybe omit it only when it's equal? */}}
{ {
"name": {{ (or .Params.author.name .Site.Params.author.name ) | jsonify }}, "name": "a",
"url": {{ (or .Params.author.url .Site.Params.author.url .Site.Home.Permalink .Site.BaseURL) | jsonify }}, "url": "https://trwnh.com",
"avatar": "https://trwnh.com/.assets/icon.png" {{- /* TODO: make this variable (512x512?) */}} "avatar": "https://trwnh.com/.assets/icon.png" {{- /* TODO: make this variable (512x512?) */}}
} }
], ],
"author": { {{- /* TODO: make this variable? or should this be omitted since it's implied by the top-level prop? maybe omit it only when it's equal? */}} "author": { {{- /* TODO: make this variable? or should this be omitted since it's implied by the top-level prop? maybe omit it only when it's equal? */}}
"name": {{ (or .Params.author.name .Site.Params.author.name ) | jsonify }}, "name": "a",
"url": {{ (or .Params.author.url .Site.Params.author.url .Site.Home.Permalink .Site.BaseURL) | jsonify }}, "url": "https://trwnh.com",
"avatar": "https://trwnh.com/.assets/icon.png" {{- /* TODO: make this variable (512x512?) */}} "avatar": "https://trwnh.com/.assets/icon.png" {{- /* TODO: make this variable (512x512?) */}}
} }
{{- with .Params.tags }}, {{- with .Params.tags }},

View file

@ -6,102 +6,7 @@
<body class="layout-_default-single"> <body class="layout-_default-single">
{{ partial "site-header.html" . }} {{ partial "site-header.html" . }}
<main id="main"> <main id="main">
{{ "<!-- begin article -->" | safeHTML }} {{ partial "components/article.html" . }}
<article class="page h-entry hentry" {{- if .Param "autonumbering" }} autonumbering {{- end }}{{- if .Param "toc" }} has-toc {{- end }}>
<header class="page-header section">
<div class="container">
{{ with .Title | safeHTML }}<h1 class="page-title p-name entry-title">{{.}}</h1>{{ end }}
{{- if .Params.summary }}{{/* only use explicitly-set summaries, not auto-generated ones */}}
{{ with .Summary | safeHTML }}<p class="page-summary p-summary entry-summary">{{.}}</p>{{ end }}
{{- end }}
{{- with (index .Site.Data.people "trwnh.com").a }}{{/* TODO: make author a variable instead of assuming it's always me. also maybe support multiple authors */}}
<p class="page-author">
<span style="display: none">Written by </span>
{{- partial "components/author-card.html" . }}
</p>
{{- end }}
{{- with .Date }}
<p class="page-date">
Published <time class="dt-published published" datetime="{{.Format "2006-01-02T15:04:05-07:00"}}"><span class="time">{{ .Format "3:04 PM MST (-07:00)" }}</span> on <span class="date">{{ .Format "Mon Jan 2, 2006"}}</span></time>
</p>
{{- end }}
{{- with .Params.inReplyTo }}
{{- range . }}
{{- if . }}
{{- $name := or .name "[link]" }}
{{- $href := "" }}
{{- if .pageRef }}
{{- $href = ref $ .pageRef }}
{{- else }}
{{- $href = .url }}
{{- end }}
{{- partial "mf2/u-in-reply-to.html" . }}
{{- end }}
{{- end }}
{{- end }}
{{- with .GetTerms "tags" }}
<p class="page-tags">Tagged {{ range $k, $v := . }}{{ if $k }}, {{end}}{{$tag := $v}}{{ if $tag.Params.tag_canonical }}{{ $tag = .GetPage (printf "/tags/%s" .Params.tag_canonical) }}{{ end }}<a href="{{$tag.Permalink}}" class="p-category page-tag">{{$tag.Name}}</a>{{ end }}</p>
{{- end }}
<a href="#end-of-header" class="skip-syndication" aria-label="Skip syndication information"></a>
{{- with .Permalink }}
<p class="page-permalink" aria-hidden="true">h-entry URL: <a class="u-url url" href="{{.}}">{{.}}</a></p>
{{- end }}
{{ partial "components/alt-formats.html" . }}
{{- with .Params.syndication }}
<aside class="page-syndication">
{{ partial "components/syndication-list.html" . }}
</aside>
{{- end }}
{{- /* {{ with .Params.source }}
{{ $type := (printf "%T" .) }}
{{ if eq $type "string"}}
{{ if (findRE "^http" .) }}
<p class="page-sourcelink"><a href="{{.}}">[source]</a></p>
{{ end}}
{{ end }}
{{ if eq $type "[]string"}}
{{ end }}
{{ end }} */}}
</div>
<hr />
<a id="end-of-header" aria-hidden="true"></a>
</header>
{{- if .Params.series }}
{{ "<!-- article aside: this article is part of a series -->" | safeHTML }}
<aside class="page-series section">
<div class="container">
{{ partial "components/series-list.html" . }}
</div>
<hr />
</aside>
{{- end }}
{{- if .Params.toc }}
{{ "<!-- article nav/toc -->" | safeHTML }}
<input type="checkbox" id="toc-toggle">
<label for="toc-toggle" id="toc-toggle__label-show" role="button" tabindex=0>Show TOC</label>
<label for="toc-toggle" id="toc-toggle__label-hide" role="button" tabindex=0>Hide TOC</label>
{{ partial "components/table-of-contents.html" . }}
{{- end }}
{{ "<!-- article content -->" | safeHTML }}
<section class="page-content section">
<div class="container e-content entry-content hugo-content">
{{ replaceRE `(?s)<div class="footnotes".*` "" .Content | safeHTML -}}
</div>
</section>
{{ "<!-- article footer -->" | safeHTML }}
<footer class="page-footer section">
<div class="container">
<hr />
{{- with (index (.RawContent | .RenderString | findRE `(?s)<div class="footnotes".*`) 0 | safeHTML) }}
<section id="footnotes">
<h2>Footnotes</h2>
{{ . | replaceRE `<hr>\n` "" | replaceRE `&#x21a9;&#xfe0e;` "Return to text" | safeHTML -}}
</section>
{{- end }}
</div>
</footer>
</article>
{{ "<!-- end article -->" | safeHTML }}
</main> </main>
{{ partial "site-footer.html" . }} {{ partial "site-footer.html" . }}
</body> </body>

View file

@ -14,7 +14,7 @@
<h2>most recently updated</h2> <h2>most recently updated</h2>
</header> </header>
<ul class="page-list"> <ul class="page-list">
{{ range where .Pages "Sitemap.Disable" "ne" true }} {{ range where .Site.Pages "Sitemap.Disable" "ne" true }}
{{- if .Permalink -}} {{- if .Permalink -}}
<li> <li>
<a href="{{.Permalink}}"> <a href="{{.Permalink}}">

View file

@ -0,0 +1,23 @@
{{ define "head" }}
{{ end }}
{{ define "body" }}
<body class="layout-_default-taxonomy">
{{ partial "site-header.html" . }}
<main id="main">
<div class="container">
<h1>{{or .Title .File.ContentBaseName}}</h1>
{{- if isset .Params "summary" }}<p>{{.Summary}}</p>{{end}}
{{- with .Data.Terms.ByCount }}
<dl>
{{- range . }}
<dt><a href="{{.Page.Permalink}}">{{.Page.Title}}</a></dt>
<dd>{{.Count}} entries</dd>
{{- end }}
</dl>
{{- end }}
</div>
</main>
{{ partial "site-footer.html" . }}
</body>
{{ end }}

View file

@ -0,0 +1,10 @@
{{- define "head" }}
{{- end }}
{{- define "body" }}
<body class="layout-_default-term">
{{ partial "site-header.html" . }}
{{ partial "components/feed.html" (dict "ctx" .) }}
{{ partial "site-footer.html" . }}
</body>
{{- end }}

View file

@ -12,6 +12,9 @@
{{ else }} {{ else }}
<h1 class="section-title">{{or .Title .File.Dir}}</h1> <h1 class="section-title">{{or .Title .File.Dir}}</h1>
{{ end }} {{ end }}
{{ if isset .Params "summary" }}
{{ .Summary }}
{{ end }}
</header> </header>
<div class="content hugo-content"> <div class="content hugo-content">
{{.Content}} {{.Content}}

View file

@ -1,9 +1,9 @@
{{- with .AlternativeOutputFormats }} {{- with .AlternativeOutputFormats }}
<div class="alt-formats"> <div class="alt-formats">
<p>Alternate formats:</p> <p class="alt-formats-hint"><span class="alt-formats-hint__text">Alternate formats:</span></p>
<ul class="alt-formats-list"> <ul class="alt-formats-list">
{{- range . }} {{- range . }}
<li class="alt-formats-list-item">{{.Name}} (<span class="mediaType">{{.MediaType}}</span>): <a href="{{.Permalink}}"><span class="path">{{.RelPermalink}}</span></a></li> <li class="alt-formats-list-item"><a href="{{.Permalink}}"><span class="mediaType">{{.MediaType}}</span></a></li>
{{- end }} {{- end }}
</ul> </ul>
</div> </div>

View file

@ -0,0 +1,13 @@
{{- $author := or .Params.author .Site.Params.author }}
{{- /* normalize [params.author] to [[params.author]] */}}
{{- if reflect.IsMap $author }}
{{- $author = slice ($author) }}
{{- end }}
{{- with $author }}
<p class="article-authors-hint">Article authored by:</p>
<ul class="article-authors" data-authors-count="{{len .}}">
{{- range . }}
<li class="article-author">{{- partial "components/author-card.html" . }}</li>
{{- end }}
</ul>
{{ end -}}{{/* end with author h-card */ -}}

View file

@ -0,0 +1,18 @@
<header class="article-header section">
<div class="container">
{{ with .Title | safeHTML }}<h1 class="article-title p-name entry-title">{{.}}</h1>{{ end }}
{{- if isset .Params "summary" }}{{/* only use explicitly-set summaries, not auto-generated ones */}}
{{ with .Summary | safeHTML }}<p class="article-summary p-summary entry-summary">{{.}}</p>{{ end }}
{{- end }}
{{ partial "components/article-authors.html" . }}
{{/* <a href="#end-of-header" class="skip-metadata" aria-label="Skip further metadata"></a> */}}
{{ partial "components/article-published-datetime.html" . }}
{{ partial "components/article-in-reply-to.html" . }}
{{ partial "components/article-tags.html" . }}
{{ partial "components/article-permalink.html" . }}
{{ partial "components/alt-formats.html" . }}
{{ partial "components/article-syndication-list.html" . }}
</div>
<hr />
<a id="end-of-header" aria-hidden="true"></a>
</header>

View file

@ -0,0 +1,5 @@
{{- with .Params.inReplyTo }}
{{- range . }}
{{- partial "components/in-reply-to-prepend.html" . }}
{{- end }}
{{- end }}

View file

@ -0,0 +1,3 @@
{{- with .Permalink }}
<p class="article-permalink" aria-hidden="true"><span class="article-permalink__text">h-entry URL: <a class="u-url url" href="{{.}}">{{.}}</a></span></p>
{{- end }}

View file

@ -0,0 +1,5 @@
{{- with .Date }}
<p class="article-published-datetime">
<span class="article-published-datetime__text">Published <time class="dt-published published" datetime="{{.Format "2006-01-02T15:04:05-07:00"}}"><span class="time">{{ .Format "3:04 PM MST (-07:00)" }}</span> <span class="nobr">on <span class="date">{{ .Format "Mon Jan 2, 2006"}}</span></span></span></time>
</p>
{{- end }}

View file

@ -0,0 +1,10 @@
{{- if .Params.series }}
{{/* TODO: maybe support multiple series? probably not though */}}
{{ "<!-- article aside: this article is part of a series -->" | safeHTML }}
<aside class="article-series section">
<div class="container">
{{ partial "components/article-series-list.html" . }}
</div>
<hr />
</aside>
{{- end }}

View file

@ -0,0 +1,10 @@
{{- with .Params.syndication }}
<p class="article-syndication-hint"><span class="article-syndication-hint__text">This entry has been posted elsewhere:</span></p>
<ul class="article-syndication-list">
{{- range . }}
<li class="article-syndication-list-item">
<a{{with .url}} href="{{.}}" class="u-syndication"{{end}}>{{or .name .url}}</a>
</li>
{{- end }}
</ul>
{{- end }}

View file

@ -0,0 +1,3 @@
{{- with .GetTerms "tags" }}
<p class="article-tags"><span class="article-tags__text">Tagged {{ range $k, $v := . }}{{ if $k }}, {{end}}{{$tag := $v}}{{ if $tag.Params.tag_canonical }}{{ $tag = .GetPage (printf "/tags/%s" .Params.tag_canonical) }}{{ end }}<a href="{{$tag.Permalink}}" class="article-tag p-category">{{$tag.Name}}</a>{{ end }}</span></p>
{{- end }}

View file

@ -0,0 +1,31 @@
{{ "<!-- begin article -->" | safeHTML }}
<article class="article h-entry hentry" {{- if .Param "autonumbering" }} autonumbering {{- end }}{{- if .Param "toc" }} has-toc {{- end }}>
{{ partial "components/article-header.html" . }}
{{ partial "components/article-series.html" . }}
{{- if .Params.toc }}
{{ "<!-- article nav/toc -->" | safeHTML }}
<input type="checkbox" id="toc-toggle">
<label for="toc-toggle" id="toc-toggle__label-show" role="button" tabindex=0>Show TOC</label>
<label for="toc-toggle" id="toc-toggle__label-hide" role="button" tabindex=0>Hide TOC</label>
{{ partial "components/table-of-contents.html" . }}
{{- end }}
{{ "<!-- article content -->" | safeHTML }}
<section class="page-content section">
<div class="container e-content entry-content hugo-content">
{{ replaceRE `(?s)<div class="footnotes".*` "" .Content | safeHTML -}}
</div>
</section>
{{ "<!-- article footer -->" | safeHTML }}
<footer class="article-footer section">
<div class="container">
<hr />
{{- with (index (.RawContent | .RenderString | findRE `(?s)<div class="footnotes".*`) 0 | safeHTML) }}
<section id="footnotes">
<h2>Footnotes</h2>
{{ . | replaceRE `<hr>\n` "" | replaceRE `&#x21a9;&#xfe0e;` "Return to text" | safeHTML -}}
</section>
{{- end }}
</div>
</footer>
</article>
{{ "<!-- end article -->" | safeHTML }}

View file

@ -0,0 +1,13 @@
{{- $author := or .Params.author .Site.Params.author }}
{{- /* normalize [params.author] to [[params.author]] */}}
{{- if reflect.IsMap $author }}
{{- $author = slice ($author) }}
{{- end }}
{{- with $author }}
<p class="feed-authors-hint">Feed authored by:</p>
<ul class="feed-authors" data-authors-count="{{len .}}">
{{- range . }}
<li class="feed-author">{{- partial "components/author-card.html" . }}</li>
{{- end }}
</ul>
{{ end -}}{{/* end with author h-card */ -}}

View file

@ -0,0 +1,11 @@
<section class="feed-entries section" id="items">
<div class="container">
<ol class="feed-entries-list">
{{- range . }}
<li class="feed-entries-list-item">
{{ partial "components/feed-entry-compact.html" . }}
</li>
{{- end }}
</ol>
</div>
</section>

View file

@ -0,0 +1,11 @@
<section class="feed-entries section" id="items">
<div class="container">
<ol class="feed-entries-list">
{{- range . }}
<li class="feed-entries-list-item">
{{ partial "components/feed-entry-in-series.html" . }}
</li>
{{- end }}
</ol>
</div>
</section>

View file

@ -0,0 +1,13 @@
<article class="h-entry hentry feed-entry-compact">
<header class="feed-entry-compact__header">
<hgroup>
<p class="feed-entry-compact__date">{{ partial "mf2/dt-published-full.html" . }}</p>
<h2 class="p-name entry-title feed-entry-compact__title"><a href="{{.Permalink}}">{{.Title}}</a></h2>
</hgroup>
</header>
<section class="e-summary entry-summary feed-entry-compact__summary">
{{ .Summary }}
</section>
<footer class="feed-entry-compact__footer">
</footer>
</article>

View file

@ -6,7 +6,4 @@
<section class="e-summary entry-summary feed-entry-in-series__summary"> <section class="e-summary entry-summary feed-entry-in-series__summary">
{{ .Summary }} {{ .Summary }}
</section> </section>
<footer class="feed-entry-in-series__footer">
<p class="feed-entry-in-series__date">{{ partial "mf2/dt-published.html" . }}</p>
</footer>
</article> </article>

View file

@ -1,11 +1,12 @@
<article class="h-entry hentry feed-entry"> <article class="h-entry hentry feed-entry">
<header class="feed-entry__header"> <header class="feed-entry__header">
<h2 class="p-name entry-title feed-entry__title"><a href="{{.Permalink}}">{{.Title}}</a></h2> <h2 class="p-name entry-title feed-entry__title"><a href="{{.Permalink}}">{{.Title}}</a></h2>
{{/* {{ partial "components/entry-in-reply-to.html" . }} */}}
</header> </header>
<section class="e-summary entry-summary feed-entry__summary"> <section class="e-summary entry-summary feed-entry__summary">
{{ .Summary }} {{ .Summary }}
</section> </section>
<footer class="feed-entry__footer"> <footer class="feed-entry__footer">
<p class="feed-item-series__date">{{ partial "mf2/dt-published.html" . }}</p> <p class="feed-entry__date">{{ partial "mf2/dt-published.html" . }}</p>
</footer> </footer>
</article> </article>

View file

@ -1,26 +1,18 @@
<header class="feed-header section"> <header class="feed-header section">
<div class="container"> <div class="container">
<h1 class="feed-title p-name">{{.Title}}</h1> <h1 class="feed-title p-name">{{.Title | safeHTML}}</h1>
{{ with .Summary }}<p class="feed-summary p-summary">{{ . }}</p>{{ end }} {{- if isset .Params "summary" }}
{{- with (index .Site.Data.people "trwnh.com").a }}{{/* TODO: make author a variable instead of assuming it's always me */}} <p class="feed-summary p-summary">{{ .Summary | safeHTML }}</p>
<p class="feed-author"> {{- end }}
{{- partial "components/author-card.html" . }} {{ partial "components/feed-authors.html" . }}
</p> {{- with .Content }}
{{ end -}}{{/* end with author h-card */ -}}
<div class="feed-content e-content hugo-content"> <div class="feed-content e-content hugo-content">
{{- .Content }} {{ . }}
</div> </div>
{{- with .Params.tag_aliases }}
<p class="tag-aliases">Also known as: {{ range $k, $v := . }}
{{- $alias_page := $.GetPage (printf "%s/%s" $.Type .) }}
{{- with $alias_page }}
{{- if $k }}, {{ end -}}
<a class="tag-alias" property="https://www.w3.org/ns/activitystreams#alsoKnownAs" href="{{.Permalink}}">{{or .Params.tag_name .Name}}</a>
{{- end }} {{- end }}
{{- end }}</p> {{ partial "components/tag-aliases.html" . }}
{{- end }} {{/* <a href="#items" class="skip-to-items">Skip to the feed items</a> */}}
<a href="#items" class="skip-to-items">Skip to the feed items</a> {{ partial "components/feed-permalink.html" . }}
<p class="list-permalink">h-feed URL: <a href="{{.Permalink}}" rel="self" class="u-url">{{.Permalink}}</a></p>
{{ partial "components/alt-formats.html" . }} {{ partial "components/alt-formats.html" . }}
<hr> <hr>
</div> </div>

View file

@ -0,0 +1,3 @@
{{- with .Permalink }}
<p class="feed-permalink" aria-hidden="true"><span class="feed-permalink__text">h-feed URL: <a class="u-url url" href="{{.}}">{{.}}</a></span></p>
{{- end }}

View file

@ -0,0 +1,18 @@
{{- $ctx := .ctx }}
{{- $pages := or .pages $ctx.RegularPages }}
<main class="h-feed hfeed feed" id="main">
{{ "<!-- the main header contains list metadata -->" | safeHTML }}
{{ partial "components/feed-header.html" $ctx }}
{{- if and (eq $ctx.Section "tags") (eq $ctx.Kind "term") }}
{{- "<!-- list the pages labeled with this tag -->" | safeHTML }}
{{- $pages := slice }}
{{- $tagSet := slice $ctx.Name | append $ctx.Params.tag_aliases }}
{{- $pages = where $ctx.Site.RegularPages "Params.tags" "intersect" $tagSet }}
{{ partial "components/feed-entries-compact.html" $ctx.Pages }}
{{- else if eq $ctx.Section "series" }}
{{ $pages = sort $ctx.RegularPages "Params.series_part" "asc" }}
{{ partial "components/feed-entries-in-series.html" $pages }}
{{- else }}
{{ partial "components/feed-entries-compact.html" $pages }}
{{- end }}
</main>

View file

@ -1,2 +1,6 @@
{{- $url := or .url (site.GetPage .pageRef).Permalink}} {{- $pageLink := "" }}
{{- if .pageRef }}
{{- $pageLink = (site.GetPage .pageRef).Permalink}}
{{- end }}
{{- $url := or .url $pageLink }}
<p class="in-reply-to-prepend"><span class="in-reply-to-prepend__text">In response to <a class="u-in-reply-to h-entry"{{with $url}} href="{{.}}"{{end}}>{{or .name $url}}</a></span></p> <p class="in-reply-to-prepend"><span class="in-reply-to-prepend__text">In response to <a class="u-in-reply-to h-entry"{{with $url}} href="{{.}}"{{end}}>{{or .name $url}}</a></span></p>

View file

@ -1,8 +0,0 @@
<p class="syndication-hint">This entry has been posted elsewhere:</p>
<ul class="syndication-list">
{{- range . }}
<li class="syndication-list-item">
<a{{with .url}} href="{{.}}" class="u-syndication"{{end}}>{{or .name .url}}</a>
</li>
{{- end }}
</ul>

View file

@ -0,0 +1,9 @@
{{- with .Params.tag_aliases }}
<p class="tag-aliases">Also known as: {{ range $k, $v := . }}
{{- $alias_page := $.GetPage (printf "%s/%s" $.Type .) }}
{{- with $alias_page }}
{{- if $k }}, {{ end -}}
<a class="tag-alias" property="https://www.w3.org/ns/activitystreams#alsoKnownAs" href="{{.Permalink}}">{{or .Params.tag_name .Name}}</a>
{{- end }}
{{- end }}</p>
{{- end }}

View file

@ -0,0 +1,23 @@
{{/* {{- with .AlternativeOutputFormats }}
{{- range . }}
{{- $type := "" }}
{{- if eq (.MediaType.String | safeHTML) "application/atom+xml" }}
{{- $type = "Atom feed" }}
{{- else if eq (.MediaType.String | safeHTML) "application/feed+json"}}
{{- $type = "JSON feed" }}
{{- else if eq (.MediaType.String | safeHTML) "application/jf2feed+json"}}
{{- $type = "JF2 feed" }}
{{- end }}
<link rel="{{.Rel}}" {{printf "type=%q" .MediaType | safeHTMLAttr}} title="{{$fullTitle}}{{with $type}} ({{.}}){{end}}" href="{{.Permalink}}" />
{{- end }}
{{- end }} */}}
{{/* {{ with .OutputFormats.Get "RSS" -}}
<link rel="feed alternate" type="application/rss+xml" title="{{ $fullTitle }}" href="{{ .Permalink }}" />
{{- end }}
{{- with .OutputFormats.Get "Atom" -}}
<link rel="feed alternate" type="application/atom+xml" title="{{ $fullTitle }}" href="{{ .Permalink }}" />
{{- end }}
{{- with .OutputFormats.Get "Sitemap" -}}
<link rel="sitemap" type="application/xml" title="Sitemap" href="{{ .Permalink }}" />
{{- end -}} */}}
{{- /* TODO: more output formats? or possibly loop/iterate over all output formats? (probably not, don't want to link to lunr.json do we?) */ -}}

View file

@ -0,0 +1,55 @@
{{ "<!-- author -->" | safeHTML }}
<meta name="author" property="article:author" content="{{ . }}" />
<meta property="article:publisher" content="{{ .Site.BaseURL }}" />
{{- if or .Date .Lastmod }}
{{ "<!-- time -->" | safeHTML }}
{{- end }}
{{ with .Date -}}
<meta property="article:published_time" itemprop="datePublished" content={{ .Format "2006-01-02T03:04:05Z" | safeHTML }} />
{{ end -}}
{{ with .Lastmod -}}
<meta property="article:modified_time" itemprop="dateModified" content={{ .Format "2006-01-02T03:04:05Z" | safeHTML }} />
{{ end -}}
{{/*=== section and keywords ===*/}}
{{- with.Params.category -}}
{{- "<!-- keywords -->" | safeHTML -}}
<meta property="article:section" content="{{ . }}" />
{{- end -}}
{{- with .Params.tags -}}
<meta property="article:tag" itemprop="keywords" name="keywords" content='{{ delimit . ", "}}' />
{{- end -}}
{{- "<!-- article metadata -->" | safeHTML }}
<meta property="og:type" content="article" />
<meta itemprop="wordCount" content="{{ .WordCount }}" />
<script defer type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "Article",
"headline": {{ .Title }},
"author": {
"@type": "Person",
"name": "TODO: fixme",
"url": "TODO: fixme"
},
"datePublished": {{ .Date.UTC.Format "2006-01-02T03:04:05Z" }},
"description": {{ (or .Description .Summary) | plainify }},
"wordCount": {{ .WordCount }},
"mainEntityOfPage": {{ .Permalink }},
"dateModified": "{{ .Lastmod.UTC.Format "2006-01-02T03:04:05Z" }}",
"image": {
"@type": "ImageObject",
"url": "TODO: fixme"
},
"publisher": {
"@type": "WebSite",
"name": {{ .Site.Title }},
"url": {{ .Site.BaseURL }},
"image": {
"@type": "ImageObject",
"url": "TODO: fixme"
}
}
}
</script>

View file

@ -0,0 +1,4 @@
{{- with or .Description .Params.summary .Site.Params.description (plainify (.Content | safeHTML) | strings.Truncate 140) }}
<meta name="description" itemprop="description" property="og:description" content="{{ . }}" />
<meta name="twitter:description" content="{{ . }}" />
{{- end }}

View file

@ -0,0 +1,3 @@
{{- with . }}
<link rel="shortcut icon" href='{{ .Permalink }}' sizes="{{.Width}}x{{.Height}}" />
{{- end }}

View file

@ -0,0 +1,17 @@
{{- with .image }}
<meta property="og:image" itemprop="image" content="{{ .Permalink | absURL }}" />
{{- with .Width }}
<meta property="og:image:width" content="{{ . }}" />
{{- end }}
{{- with .Height }}
<meta property="og:image:height" content="{{ . }}" />
{{- end }}
<meta name="twitter:image" content="{{ .Permalink | absURL }}" />
<meta name="twitter:image:src" content="{{ .Permalink | absURL }}" />
{{- end -}}
{{- with .Params.audio }}<meta property="og:audio" content="{{ . }}" />{{ end }}
{{- with .Params.videos }}{{- range . }}
<meta property="og:video" content="{{ . | absURL }}" />
{{ end }}{{ end -}}

View file

@ -0,0 +1,2 @@
<meta name="robots" content="index,follow" />
<meta name="googlebot" content="index,follow" />

View file

@ -0,0 +1,6 @@
{{- with .Site.Title }}
<meta name="application-name" property="og:site_name" content="{{ . }}" />
{{- end -}}
{{- with .Language.LanguageCode }}
<meta property="og:locale" content="{{ replace . "-" "_" }}" />
{{- end }}

View file

@ -0,0 +1,4 @@
{{- with .Site.Params.themeColor }}
<meta name="theme-color" content="{{.}}" />
<meta name="msapplication-TileColor" content="{{.}}" />
{{- end }}

View file

@ -0,0 +1,2 @@
<title>{{ .fullTitle }}</title>
<meta property="og:title" name="twitter:title" itemprop="name" content="{{ .title }}" />

View file

@ -0,0 +1,6 @@
{{- with .Permalink | absURL}}
<base href="{{ . }}" />
<link rel="canonical" href="{{ or $.Params.canonical . }}" />
<meta name="url" property="og:url" itemprop="url" content="{{ . }}" />
<meta name="twitter:url" content="{{ . }}" />
{{- end -}}

View file

@ -0,0 +1,15 @@
{{- "<!-- webpage metadata -->" | safeHTML }}
<meta property="og:type" content="website" />
<script defer type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "WebPage",
"name": {{ .Title }},
"url": {{ .Permalink }},
"description": {{ (or .Description .Summary) | plainify }},
"image": {
"@type": "ImageObject",
"url": "TODO: fixme"
}
}
</script>

View file

@ -0,0 +1 @@
<time class="dt-published published" datetime="{{.Date.Format "2006-01-02T15:04:05-07:00"}}" property="https://www.w3.org/ns/activitystreams#published">{{.Date.Format "2006-01-02 15:04:05 -07:00 (MST)"}}</time>

View file

@ -3,7 +3,7 @@
<p style="display: contents"><span style="display: none">Published on </span><span class="feed-item__date">{{ partial "mf2/dt-published.html" . }}</span></p> <p style="display: contents"><span style="display: none">Published on </span><span class="feed-item__date">{{ partial "mf2/dt-published.html" . }}</span></p>
{{- range .Params.inReplyTo }} {{- range .Params.inReplyTo }}
{{- with . }} {{- with . }}
{{ partial "mf2/u-in-reply-to.html" . }} {{ partial "components/in-reply-to-prepend.html" . }}
{{- end }} {{- end }}
{{- end }} {{- end }}
<section class="feed-item__summary e-summary"> <section class="feed-item__summary e-summary">

View file

@ -9,180 +9,23 @@
{{- $firstH1 := partial "firstH1.html" . }} {{- $firstH1 := partial "firstH1.html" . }}
{{- $fallbackTitle = or $firstH1 $.File.ContentBaseName }} {{- $fallbackTitle = or $firstH1 $.File.ContentBaseName }}
{{- end }} {{- end }}
{{- $title := or .Title $fallbackTitle }} {{- $title := or .Title $fallbackTitle }}
{{- $fullTitle := print .Site.Title " | " $title}} {{- $fullTitle := print .Site.Title " | " $title}}
{{- $cover := ($.Resources.ByType "image").GetMatch "{*opengraph*}" -}} {{- $cover := ($.Resources.ByType "image").GetMatch "{*opengraph*}" -}}
{{ $icon := resources.GetMatch (default "" .Site.Params.icon) -}} {{ $icon := resources.GetMatch (or .Site.Params.icon ("icon.png" | absURL)) -}}
{{/*=== title ===*/}} {{- $author := or .Params.author .Site.Params.author }}
{{ "<!-- text -->" | safeHTML }} {{- $author_string := "" }}
{{- with .Site.Title }}
<meta name="application-name" property="og:site_name" content="{{ . }}" />
{{- end -}}
{{- if .IsHome}}
{{- with or .Params.name .Site.Title }}
<title>{{ . }}</title>
<meta property="og:title" name="twitter:title" itemprop="name" content="{{ . }}" />
{{- end }}
{{- else }}
<title>{{ or .Params.name $fullTitle }}</title>
<meta property="og:title" name="twitter:title" itemprop="name" content="{{ or .Params.name $title }}" />
{{- end -}}
{{/*=== description ===*/}} {{/* TODO: clean up this mess */}}
{{- with or .Description .Params.summary .Site.Params.description (plainify (.Content | safeHTML) | strings.Truncate 140) }}
<meta name="description" itemprop="description" property="og:description" content="{{ . }}" />
<meta name="twitter:description" content="{{ . }}" />
{{- end }}
{{ "<!-- url -->" | safeHTML }}
{{- with .Permalink | absURL}}
<base href="{{ . }}" />
<link rel="canonical" href="{{ or $.Params.canonical . }}" />
<meta name="url" property="og:url" itemprop="url" content="{{ . }}" />
<meta name="twitter:url" content="{{ . }}" />
{{- end -}}
{{/*=== image ===*/}}
{{- $staticIcon := "icon.png" | absURL -}}
{{- with or $cover $icon }}
{{ "<!-- image -->" | safeHTML }}
<meta property="og:image" itemprop="image" content="{{ .Permalink | absURL }}" />
{{- with .Width }}
<meta property="og:image:width" content="{{ . }}" />
{{- end }}
{{- with .Height }}
<meta property="og:image:height" content="{{ . }}" />
{{- end }}
<meta name="twitter:image" content="{{ .Permalink | absURL }}" />
<meta name="twitter:image:src" content="{{ .Permalink | absURL }}" />
{{- else }}
{{ "<!-- image -->" | safeHTML }}
<meta property="og:image" itemprop="image" content="{{ $staticIcon }}" />
<meta name="twitter:image" content="{{ $staticIcon }}" />
<meta name="twitter:image:src" content="{{ $staticIcon }}" />
{{- end -}}
{{/*=== extra params? ===*/}} {{ partial "head/title.html" (dict "title" $title "fullTitle" $fullTitle) }}
{{- with .Params.audio }}<meta property="og:audio" content="{{ . }}" />{{ end }} {{ partial "head/description.html" . }}
{{- with .Params.locale }}<meta property="og:locale" content="{{ . }}" />{{ end }} {{ partial "head/url.html" . }}
{{- with .Params.videos }}{{- range . }} {{ partial "head/icon.html" $icon }}
<meta property="og:video" content="{{ . | absURL }}" /> {{ partial "head/theme-color.html" . }}
{{ end }}{{ end -}} {{ partial "head/site.html" . }}
{{ partial "head/robots.html" . }}
{{/*=== article ===*/}}
{{- with or .Params.author .Site.Params.author }}
{{ "<!-- author -->" | safeHTML }}
<meta name="author" property="article:author" content="{{ .name }}" />
{{- end }}
<meta property="article:publisher" content="{{ .Site.BaseURL }}" />
{{- if or .Date .Lastmod }}
{{ "<!-- time -->" | safeHTML }}
{{- end }}
{{ with .Date -}}
<meta property="article:published_time" itemprop="datePublished" content={{ .Format "2006-01-02T03:04:05Z" | safeHTML }} />
{{ end -}}
{{ with .Lastmod -}}
<meta property="article:modified_time" itemprop="dateModified" content={{ .Format "2006-01-02T03:04:05Z" | safeHTML }} />
{{ end -}}
{{/*=== section and keywords ===*/}}
{{- with.Params.category -}}
{{- "<!-- keywords -->" | safeHTML -}}
<meta property="article:section" content="{{ . }}" />
{{- end -}}
{{- with .Params.tags -}}
<meta property="article:tag" itemprop="keywords" name="keywords" content='{{ delimit . ", "}}' />
{{- end -}}
{{/* if it has a date, it's probably an article */}}
{{- if isset .Params "date" }}
{{- "<!-- article metadata -->" | safeHTML }}
<meta property="og:type" content="article" />
<meta itemprop="wordCount" content="{{ .WordCount }}" />
<script defer type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "Article",
"headline": {{ $title }},
"author": {
"@type": "Person",
"name": {{ or .Params.author.name .Site.Params.author.name }},
"url": {{ or .Params.author.url .Site.Params.author.url .Site.BaseURL }}
},
"datePublished": {{ .Date.UTC.Format "2006-01-02T03:04:05Z" }},
"description": {{ (or .Description .Summary) | plainify }},
"wordCount": {{ .WordCount }},
"mainEntityOfPage": {{.Permalink}},
"dateModified": "{{ .Lastmod.UTC.Format "2006-01-02T03:04:05Z" }}",
{{ with or $cover $icon }}
"image": {
"@type": "ImageObject",
"url": {{ .Permalink | absURL }}
},{{ end }}
"publisher": {
"@type": "WebSite",
"name": {{ .Site.Title }},
"url": {{ .Site.BaseURL }},
"image": {
"@type": "ImageObject",
"url": {{with $icon}}{{.Permalink}}{{else}}{{$staticIcon}}{{end}}
}
}
}
</script>
{{- else }}
{{- /* otherwise if it doesn't have a date it's probably just a webpage */}}
{{- "<!-- webpage metadata -->" | safeHTML }}
<meta property="og:type" content="website" />
<script defer type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "WebPage",
"name": {{ .Title }},
"url": {{ .Permalink }},
"description": {{ (or .Description .Summary) | plainify }},
"image": {
"@type": "ImageObject",
"url": {{with $icon}}{{.Permalink}}{{else}}{{$staticIcon}}{{end}}
}
}
</script>
{{- end -}}
{{/* auxiliary info */}}
{{ "<!-- site presentation -->" | safeHTML }}
{{ with $icon }}
<link rel="shortcut icon" href='{{ .Permalink }}' sizes="{{.Width}}x{{.Height}}" />
{{- else -}}
<link rel="shortcut icon" href='{{ $staticIcon }}' sizes="512x512" />
{{- end }}
<meta name="theme-color" content="#001a33" />{{/* TODO: make this a variable in site config */}}
<meta name="msapplication-TileColor" content="#001a33" />{{/* TODO: make this a variable in site config */}}
{{- with .AlternativeOutputFormats }}
{{- range . }}
{{- $type := "" }}
{{- if eq (.MediaType.String | safeHTML) "application/atom+xml" }}
{{- $type = "Atom feed" }}
{{- else if eq (.MediaType.String | safeHTML) "application/feed+json"}}
{{- $type = "JSON feed" }}
{{- else if eq (.MediaType.String | safeHTML) "application/jf2feed+json"}}
{{- $type = "JF2 feed" }}
{{- end }}
<link rel="{{.Rel}}" {{printf "type=%q" .MediaType | safeHTMLAttr}} title="{{$fullTitle}}{{with $type}} ({{.}}){{end}}" href="{{.Permalink}}" />
{{- end }}
{{- end }}
{{/* {{ with .OutputFormats.Get "RSS" -}}
<link rel="feed alternate" type="application/rss+xml" title="{{ $fullTitle }}" href="{{ .Permalink }}" />
{{- end }}
{{- with .OutputFormats.Get "Atom" -}}
<link rel="feed alternate" type="application/atom+xml" title="{{ $fullTitle }}" href="{{ .Permalink }}" />
{{- end }}
{{- with .OutputFormats.Get "Sitemap" -}}
<link rel="sitemap" type="application/xml" title="Sitemap" href="{{ .Permalink }}" />
{{- end -}} */}}
{{- /* TODO: more output formats? or possibly loop/iterate over all output formats? (probably not, don't want to link to lunr.json do we?) */ -}}
{{- /* robots */ -}}
{{ "<!-- robots -->" | safeHTML }}
<meta name="robots" content="index,follow" />
<meta name="googlebot" content="index,follow" />

View file

@ -1,5 +1,42 @@
<footer class="site-footer"> <footer class="site-footer">
<div class="container"> <div class="container">
<a href="#main" class="back-to-top">Back to top</a> <hr />
{{/* <a href="#main" class="back-to-top">Back to top</a> */}}
<section>
<h2>About this site</h2>
{{- with .Site.Params.summary }}
<p>{{ . | markdownify }}</p>
{{- end }}
</section>
<nav class="on-this-site">
<h2>On this site</h2>
<ul>
<li><a href="{{.Site.Home.Permalink}}">Home</a></li>
<li><a href="{{absURL .Sitemap.Filename}}">Sitemap</a></li>
</ul>
{{- $sections := where .Site.Sections "Section" "not in" (slice "_dump" "meta" "responses") }}
{{- $sections = sort $sections "Title" "asc"}}
{{- with $sections }}
<section class="on-this-site-sections">
<h3>Sections</h3>
<ul>
{{- range . }}
<li><a href="{{.Permalink}}">{{or .Title .File.ContentBaseName}}</a></li>
{{- end }}
</ul>
</section>
{{- end }}
{{- with .Site.Taxonomies }}
<section class="on-this-site-taxonomies">
<h3>Taxonomies</h3>
<ul>
{{- range $k, $v := . }}
{{- $url := printf "/%s" $k | absURL}}
<li><a href="{{$url}}">{{$k}}</a></li>
{{- end }}
</ul>
</section>
{{- end }}
</nav>
</div> </div>
</footer> </footer>

View file

@ -0,0 +1,22 @@
<div class="site-sidebar">
<aside>
<div class="container">
<h2>{{.Site.Title}}</h2>
</div>
</aside>
<nav>
<div class="container">
{{ $sections := where .Site.Sections "Section" "not in" (slice "_dump" "meta" "responses") }}
{{ $sections = sort $sections "Title" "asc"}}
<h2>Other content</h2>
{{ range $sections }}
<h3><a href="{{.Permalink}}">{{or .Title .File.ContentBaseName}}</a></h3>
<ul>
{{ range first 5 .RegularPages }}
<li><a href="{{.Permalink}}">{{or .Title .File.LogicalName}}</a></li>
{{ end }}
</ul>
{{ end }}
</div>
</nav>
</div>

View file

@ -1,5 +1,6 @@
<style> <style>
a[href]:not(.footnote-ref):after { a[href^="http://"]:not(.footnote-ref):after,
a[href^="https://"]:not(.footnote-ref):after {
content: ''; content: '';
display: inline-grid; display: inline-grid;
inline-size: 1rem; inline-size: 1rem;
@ -10,9 +11,7 @@ a[href]:not(.footnote-ref):after {
mask-repeat: no-repeat; mask-repeat: no-repeat;
} }
a[href^="{{.Site.BaseURL}}"]:not(.footnote-ref):after, a[href^="{{.Site.BaseURL}}"]:not(.footnote-ref):after
a[href^="#"]:not(.footnote-ref):after,
a[href^="/"]:not(.footnote-ref):after
{ {
background-image: none !important; background-image: none !important;
display: none; display: none;

View file

@ -1,25 +0,0 @@
{{- define "head" }}
{{- end }}
{{- define "body" }}
<body class="layout-_default-list">
{{ partial "site-header.html" . }}
<main class="h-feed hfeed feed" id="main">
{{ "<!-- the main header contains list metadata -->" | safeHTML }}
{{ partial "components/feed-header.html" . }}
{{ $pages := sort .RegularPages "Params.series_part" "asc" }}
<section class="feed-entries section" id="items" data-feed-type="series">
<div class="container">
<ol class="feed-entries-list">
{{- range $pages }}
<li class="feed-entries-list-item">
{{ partial "components/feed-entry-in-series.html" .}}
</li>
{{- end }}
</ol>
</div>
</section>
</main>
{{ partial "site-footer.html" . }}
</body>
{{- end }}

View file

@ -1,8 +0,0 @@
{{ define "body" }}
<body class="layout-tags-taxonomy">
{{ partial "site-header.html" . }}
<main id="main">
test
</main>
</body>
{{ end }}

View file

@ -1,47 +0,0 @@
{{- define "head" }}
{{- end }}
{{- define "body" }}
{{- if .Params.tag_canonical }}{{/* if there's a canonical tag, link to that instead */}}
{{ $canonical_page := $.GetPage (printf "%s/%s" $.Type .Params.tag_canonical) }}
<body class="layout-taxonomy-term">
{{ partial "site-header.html" . }}
<main id="main">
<div class="container">
<h1>{{.Params.tag_name}}</h1>
<p><code>{{.Params.tag_name}}</code> is a tag alias for <code>{{.Params.tag_canonical}}</code>. <a href="{{$canonical_page.Permalink}}">Go to the canonical tag page.</a></a></p>
</div>
</main>
{{ partial "site-footer.html" . }}
</body>
{{- else }}{{/* otherwise, it's already a canonical tag and we should render it normally */}}
<body class="layout-taxonomy-term">
{{ partial "site-header.html" . }}
<main class="h-feed hfeed feed-page" id="main">
{{ "<!-- the main header contains list metadata -->" | safeHTML }}
{{ partial "components/feed-header.html" . }}
{{- $pages := slice }}
{{- "<!-- list the pages labeled with this tag -->" | safeHTML }}
{{- $tagSet := slice .Name | append .Params.tag_aliases }}
{{- $pages = where .Site.RegularPages "Params.tags" "intersect" $tagSet }}
{{- with $pages }}
<section class="list-pages section" id="items">
<div class="container">
<ol class="pages-list">
{{- range . }}
<li class="pages-list-item">
{{ partial "mf2/h-entry.html" . }}
</li>
{{- end }}
</ol>
</div>
</section>
</main>
{{ partial "site-footer.html" . }}
</body>
{{- end }}
{{- end }}
{{- end }}{{/* end define-body */ -}}