Skip to content

Commit e24b78c

Browse files
TMHSDigitalclaude
andcommitted
docs(site): record how the font subset was made and how to redo it
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Signed-off-by: TMHSDigital <154358121+TMHSDigital@users.noreply.github.com>
1 parent ae24dc4 commit e24b78c

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

‎scripts/site/template.html.j2‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,13 @@
2525
{% if og_image %}<meta name="twitter:image" content="{{ og_image }}" />
2626
{% if site.ogImageAlt %}<meta name="twitter:image:alt" content="{{ site.ogImageAlt }}" />{% endif %}{% endif %}
2727
<style>
28-
/* ---- fonts (self-hosted, copied to docs/fonts/ by build_site.py) ---- */
28+
/* ---- fonts (self-hosted, copied to docs/fonts/ by build_site.py) ----
29+
Subset to the code points the built pages use plus Latin-1 and General
30+
Punctuation (#216); a character outside that set falls back to the next
31+
family in the stack. To re-subset after content adds new symbols, collect
32+
the pages' characters into a U+XXXX list and run, per original font:
33+
python -m fontTools.subset ORIG.woff2 --unicodes-file=LIST
34+
--layout-features='*' --flavor=woff2 --output-file=fonts/NAME.woff2 */
2935
@font-face { font-family: 'Barlow Condensed'; font-weight: 500; font-display: swap;
3036
src: url('fonts/barlow-condensed-500.woff2') format('woff2'); }
3137
@font-face { font-family: 'Barlow Condensed'; font-weight: 600; font-display: swap;

0 commit comments

Comments
 (0)