Skip to content

refactor(content): share native disclosures with mobile TOC - #90

Merged
hakula139 merged 1 commit into
mainfrom
refactor/native-mobile-toc
Sep 30, 2026
Merged

hakula139 merged 1 commit into
mainfrom
refactor/native-mobile-toc

Conversation

@hakula139

@hakula139 hakula139 commented Sep 30, 2026 •

Copy link
Copy Markdown
Owner

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

@hakula139 hakula139 added the refactor Reorganize the code to be cleaner and easier readable label Sep 30, 2026
@hakula139 hakula139 self-assigned this Sep 30, 2026
@hakula139
hakula139 force-pushed the refactor/native-mobile-toc branch from 5c836a5 to d1dad0c Compare September 30, 2026 18:54
@hakula139
hakula139 merged commit 001060c into main Sep 30, 2026
1 check passed
@hakula139
hakula139 deleted the refactor/native-mobile-toc branch September 30, 2026 18:55
hakula139 added a commit to hakula139/hakula.xyz-kiln that referenced this pull request Sep 30, 2026
## Summary

- Pin merged IgnIt #90 at `001060c` and regenerate the committed
stylesheet. The mobile TOC uses native `<details>` / `<summary>` and
shares disclosure behavior with callouts, including reduced motion and
browser-specific animation limits.

## Verification

- `pnpm build`, `pnpm format`, `pnpm lint`, `pnpm spellcheck`, `nix
flake check`, commit / push hooks, and `git diff --check` passed. The
minified build rendered and indexed 75 pages.
- The final pin produces the same TOC markup and stylesheet as the
browser-tested site build. Chromium checked the rendered LR2 article
with JavaScript enabled and disabled for native state, closed-content
focus, open links, the 16px inset, and desktop sidebar visibility.
- Chromium, Firefox, and WebKit component checks covered Enter / Space
toggling, TOC fragment navigation and active tracking, reduced motion,
and no-JavaScript use. Native Safari 27.0 frame sampling confirmed
matching callout and TOC animation behavior, including shortened closing
motion.

## Related PRs

- [Theme implementation](hakula139/IgnIt#90)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

refactor Reorganize the code to be cleaner and easier readable

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant