Blog post and style tweaks

This commit is contained in:
Dan 2026-02-19 09:49:00 +00:00
parent ff56875de9
commit 73b2473c24
14 changed files with 67 additions and 35 deletions

View file

@ -44,7 +44,7 @@
<div>
<!-- prettier-ignore -->
{{ partial "responsive-image.html" (dict "src"
"images/misc/thinkpad_t480s.jpg" "alt" "My Thinkpad T480s with stickerbomb" "width" "900x" "page" .) }}
"images/misc/thinkpad_t480s.jpg" "alt" "My Thinkpad T480s with stickerbomb" "page" .) }}
</div>
</section>
</article>

View file

@ -1,15 +1,15 @@
<!-- prettier-ignore -->
{{ $src := .src }}
{{ $alt := .alt | default "" }}
{{ $width := .width | default "800x" }}
{{ $width := or .width "800x800" }}
<figure class="blog-img-container">
{{ with .page.Resources.GetMatch $src }}
{{ $resized := .Resize $width }}
{{ $resized := .Fit $width }}
<img src="{{ $resized.RelPermalink }}" alt="{{ $alt }}" loading="lazy" class="blog-img" />
{{ else }}
{{ with resources.Get $src }}
{{ $resized := .Resize $width }}
{{ $resized := .Fit $width }}
<img src="{{ $resized.RelPermalink }}" alt="{{ $alt }}" loading="lazy" class="blog-img" />
{{ else }}
<img src="{{ $src }}" alt="{{ $alt }}" loading="lazy" class="blog-img" />

View file

@ -6,7 +6,7 @@
loop
muted
playsinline
style="position: relative; z-index: 4; max-width: 100%; height: auto"
style="position: relative; z-index: 4; max-width: 100%; height: auto; border-radius: 12px; border: 3px solid transparent; background: linear-gradient(#000, #000) padding-box, linear-gradient(180deg, #0f0, #000) border-box;"
>
<source src="{{ .RelPermalink }}" type="{{ .MediaType }}" />
</video>