Skip to content

Keep post heroes one height; analytics only on the deployed build - #108

Merged
bits-bytes-nn merged 1 commit into
mainfrom
hero-height
Oct 17, 2026
Merged

bits-bytes-nn merged 1 commit into
mainfrom
hero-height

Conversation

@bits-bytes-nn

Copy link
Copy Markdown
Owner

Changes

  • _sass/_layout.scss: the post hero title reserves two lines (min-height: 2lh, centred), so a one- and a two-line title give the same hero height (539px at 1440px for 28 of 30 paper posts; only Gemini 2.5's three-line title is taller). Reset in print. Browsers without lh keep the old behaviour.
  • _includes/head.html: Google Analytics only when jekyll.environment == 'production' (CI sets it); local serves no longer count as traffic.
  • js/search.js: !statusEl in the early-return guard.
  • _sass/base/_typography.scss: h4/h6 weight 600 -> 700; only 400/700 are loaded, so rendering is unchanged.
  • READMEs: Centrarium link over https; note that the production build loads analytics.

New lint rule (script/lint-posts.rb)

title and subtitle may not contain < followed by a letter or /, since the layouts print them unescaped.

  • Fails: title: "Reasoning with <think> Tokens", subtitle: "<s> 토큰"
  • Passes: title: "Mistral 7B < 13B", "A <= B", "<3"

No post_conventions.yml change.

Verification

All five gates pass (179 tests). Hero heights measured in Chrome at 360-1440px with no horizontal overflow; print min-height verified as 0.

- Reserve two title lines in the post hero, so a two-line title no longer
  makes its cover taller than its neighbours'; reset for print.
- Load Google Analytics only when JEKYLL_ENV=production.
- Lint: title and subtitle may not contain a tag (the layouts print them
  unescaped).
- search.js: guard on the status element it writes to.
- h4/h6: weight 700, the one loaded (600 already rendered as 700).
- README: https link for Centrarium.
@bits-bytes-nn
bits-bytes-nn merged commit e1d9754 into main Oct 17, 2026
3 checks passed
@bits-bytes-nn
bits-bytes-nn deleted the hero-height branch October 17, 2026 13:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant