css,ori-templates: margin-inline on body > * instead of body to allow figures to grow

This commit is contained in:
Hans Fast 2026-03-25 10:13:15 +01:00
parent 7d5a0dbe50
commit e1455783c8
3 changed files with 78 additions and 56 deletions

View File

@ -58,11 +58,33 @@
--oc-violet-9: #5f3dc4; --oc-violet-9: #5f3dc4;
} }
body { body {
font-family: "sans-serif"; font-family: "sans-serif";
margin: 0 auto; & > :not(.wider) {
max-width: 66ch; max-width: 38rem;
margin-inline: auto;
} }
& > .wider {
max-width: min(55rem, 100%);
margin-inline: auto;
}
}
figure img {
max-width: 100%;
}
figcaption {
margin-inline: auto;
width: max-content;
}
trl-group {
display: block;
}
@layer translations { @layer translations {
body > trl-selector:first-child {display: none;} /* was adding a grid row! */ body > trl-selector:first-child {display: none;} /* was adding a grid row! */
trl-selector { trl-selector {

View File

@ -4,7 +4,7 @@
title: page.title title: page.title
_body: Tree.indent` _body: Tree.indent`
<h1>${page.title}</h1> <h1>${page.title}</h1>
<span>${page.fnd.addr} ${page.fnd.tags || ''}</span> <p><span>${page.fnd.addr} ${page.fnd.tags || ''}</span></p>
${page._body} ${page._body}
<a href="/">↖index</a> <a href="/">↖index</a>
` `

View File

@ -3,6 +3,6 @@
--- ---
<article> <article>
<a href=${key}><h1>${value.title}</h1></a> <a href=${key}><h1>${value.title}</h1></a>
<span>${value.fnd.addr} ${value.fnd.tags || ''}</span> <p><span>${value.fnd.addr} ${value.fnd.tags || ''}</span></p>
${value.summary || ""} ${value.summary || ""}
</article> </article>