fix(content): use native details for stable callouts - #86
Merged
Merged
Conversation
hakula139
force-pushed
the
fix/callout-initial-layout
branch
from
September 29, 2026 19:58
8e80eed to
4bf8175
Compare
hakula139
force-pushed
the
fix/callout-initial-layout
branch
from
September 29, 2026 20:13
4bf8175 to
576a15a
Compare
hakula139
force-pushed
the
fix/callout-initial-layout
branch
from
September 30, 2026 17:59
8b032fe to
33d7ced
Compare
hakula139
added a commit
to hakula139/hakula.xyz-kiln
that referenced
this pull request
Sep 30, 2026
## Summary - Pin [kiln v0.4.0-rc.2](https://github.com/hakula139/kiln/releases/tag/v0.4.0-rc.2), which renders the callout body wrapper before first paint. - Pin merged IgnIt #86 at `8179b09` and regenerate the committed CSS. Native `<details>` controls callout state without a JavaScript DOM rewrite, and reduced motion disables the body and chevron transitions. ## Verification - `pnpm build`, `pnpm format`, `pnpm lint`, `pnpm spellcheck`, `nix flake check`, push hooks, and `git diff --check` passed after rebasing onto current main. The minified rc.2 build indexed 75 pages. - Chromium, Firefox, and WebKit checks covered Enter / Space toggling, closed-content tab order, nested callouts, and JavaScript-disabled behavior. Earlier paired-site checks at 390px confirmed one inner wrapper and a stable 16px content inset. - Native Safari 27.0 frame sampling with the theme CSS confirms that closing motion is shorter than the declared 300ms. Firefox hides text immediately during closing. These browser limitations remain part of the CSS progressive enhancement. ## Related PRs - hakula139/kiln#79 - hakula139/IgnIt#86
This was referenced Sep 30, 2026
hakula139
added a commit
that referenced
this pull request
Sep 30, 2026
) ## Summary - Keep article heading text aligned with body text. Below 1280px, the heading is a section link that turns blue on hover or keyboard focus. At desktop widths, it keeps its normal color and reveals the original `#` marker on hover or focus. - Use one native section link with a desktop-only CSS marker. Remove heading link underlines, preserve the h2 divider, and wrap long headings. Preserve inline formatting and existing authored links, and leave callout and blockquote headings unchanged. - Retain merged floating controls from #85 and native callouts from #86. ## Verification - `pnpm build`, `pnpm format`, `pnpm lint`, `pnpm spellcheck`, `nix flake check`, commit hooks, `git diff --check`, and CSS sync passed for the theme. The consuming site passed the same checks and its minified build rendered and indexed 75 pages after CSS generation. - Managed headless Chromium checked the generated LR2 / BMS and FFT articles at 320px, 390px, 768px, 1279px, 1280px, and 1440px in light and dark themes. Heading text aligned with body text, section links stayed inside the cards, and pages had no horizontal overflow. Default typography, responsive hover / focus colors, no link underlines, desktop marker visibility and containment, focus outlines, and Enter fragment navigation passed. - Long Chinese and unbroken Latin heading probes wrapped within the card. Inline emphasis and code were preserved, authored links remained intact without nested anchors, and repeated initialization did not duplicate heading links. - Browser checks used generated assets with external resources excluded. Local Nix validation covered aarch64-darwin. Other browser engines and Nix systems were not tested locally.
hakula139
added a commit
that referenced
this pull request
Sep 30, 2026
## Summary Use native `<details>` and `<summary>` for the mobile TOC, matching callouts. Remove the TOC wrapper and JavaScript initializer, and share summary markers, open-state chevrons, body transitions, and reduced-motion behavior in `collapse.css`. Component files retain their appearance rules. Closed TOC links are excluded from keyboard navigation, and disclosure works without JavaScript. ## Verification - `pnpm build`, `pnpm format`, `pnpm lint`, `pnpm spellcheck`, `nix flake check`, and `git diff --check` passed. The compiled CSS matches the source. - An isolated site build with this theme rendered and indexed 75 pages. The rendered LR2 article passed Chromium checks with JavaScript enabled and disabled for native state, closed-content focus, open links, padding, and desktop sidebar visibility. - Chromium, Firefox, and WebKit checks covered Enter / Space toggling, closed-content focus, open links, TOC fragment navigation and active tracking, the 16px content inset, desktop hiding, no-JavaScript interaction, and reduced motion. - Native Safari 27.0 frame sampling confirms that callouts and the mobile TOC share the same opening and shortened closing behavior. Firefox's immediate text hiding and Safari's shortened closing motion remain browser limitations of the CSS enhancement. ## Related PRs - Follows merged #86.
hakula139
added a commit
that referenced
this pull request
Oct 3, 2026
## Summary Use native code-block disclosures from kiln and share summary markers, open-state chevrons, body transitions, and reduced-motion behavior with callouts and the mobile TOC. Remove the custom JavaScript toggler, keeping clipboard behavior. Require kiln `0.4.0-rc.3` so older renderers fail the existing version check before producing incompatible code-block markup. Cancel the copy click default before replacing its icon so native summary activation cannot toggle the block after the original click target is detached. Direct-child chevron selectors keep nested disclosure states independent. ## Verification - `pnpm build`, `pnpm format`, `pnpm lint`, `pnpm spellcheck`, `nix flake check`, and `git diff --check` passed. Compiled CSS matches the source. - Headless Chromium, Firefox, and WebKit fixtures using the compiled CSS and shipped JavaScript passed native Enter / Space toggling with JavaScript enabled and disabled, initial collapsed state, nested disclosure chevrons, line-limit scrolling, reduced motion, and closed-content printing behavior. - Copy-button click, Enter, and Space copied the exact code through a mocked clipboard and left disclosure state unchanged in all three engines. Explicit icon-target clicks covered open and closed blocks with immediate, task-delayed, and rejected clipboard promises. The immediate icon click reproduces the unwanted Chromium toggle before the default cancellation. - Integrated site checks in hakula139/hakula.xyz-kiln#92 passed in Chromium, Firefox, and WebKit at mobile dark and desktop light viewports for native toggling, copying, nested state, closed-body focus exclusion, reduced motion, and page overflow. Native disclosure closing animation retains the browser differences documented in #86 and #90. - Runtime compatibility: kiln `0.4.0-rc.2` rejects this theme before writing output, while the new `0.4.0-rc.3` binary builds it. Follow-up review found no issues with the version requirement. ## Related PRs - Follows merged #90. - Requires hakula139/kiln#82 for native code-block markup. - Draft site integration: hakula139/hakula.xyz-kiln#92.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Use native
<details>and<summary>for callout state, keyboard interaction, and hidden content. Kiln renders the inner layout wrapper, so callouts keep their layout from first paint. CSS progressively enhances disclosure motion, and reduced-motion preferences disable both the body and chevron transitions. Group callout rules by container, title, body, motion, and variant, removing redundant declarations and comments.Verification
pnpm build,pnpm format,pnpm lint,pnpm spellcheck,nix flake check, andgit diff --checkpassed. The committed CSS matches the source.content-visibility: visiblelets Tab enter closed content in Chromium and Firefox. Addingvisibility: hiddenrestores keyboard hiding but makes previously searchable closed text unfindable in Chromium, so neither alternative was adopted.Related PRs