diff --git a/.plan2code/lessons/general.md b/.plan2code/lessons/general.md index 94fa921..b857b3c 100644 --- a/.plan2code/lessons/general.md +++ b/.plan2code/lessons/general.md @@ -38,6 +38,11 @@ - About: install.js - Noted: 2026-11-17, implement-review +### Every heading and .md-h gets text-wrap: balance from tokens.css, so a long heading such as a lesson title splits into two even halves; set text-wrap: wrap where a heading runs longer than a line. +- Kind: how-it-works +- About: src/web-console/public/styles/tokens.css, src/web-console/public/styles/learning.css +- Noted: 2026-11-19, quick-task + ### In a Markdown field (md-field.js), CodeMirror's scroller and content are only as tall as the text, not the bordered host: code that hit-tests the scroller must not assume it fills the box. - Kind: how-it-works - About: src/web-console/public/md-field.js diff --git a/src/web-console/public/styles/learning.css b/src/web-console/public/styles/learning.css index 123dedb..5f07411 100644 --- a/src/web-console/public/styles/learning.css +++ b/src/web-console/public/styles/learning.css @@ -116,6 +116,10 @@ /* Open the lessons: each file under its own name. */ .learn-lessons-file + .learn-lessons-file { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--rule); } .learn-lessons-name { margin: 0 0 6px; font-family: var(--mono); font-size: var(--fs-sm); color: var(--ink-3); } +/* Each file's own .md block would keep the page-wide 68ch cap; let it fill the dialog. + A lesson's title is a long heading: balanced wrapping (tokens.css) halves it, so fill each line. */ +.learn-lessons-file .md { max-width: none; } +.learn-lessons-file .md-h { text-wrap: wrap; } /* The lessons card (cards.js buildLessons): one block per item, none chosen at first. */ .lessons-opening { margin: 14px 0 0; font-size: var(--fs-md); color: var(--ink-3); }