Repository navigation
feat: restyle the site as the S2 terminal on the Whatsaaaa design system - #2
Merged
Merged
Conversation
Build every page in the design system's terminal frame: a ws-term window with the ghost and handle in the tab bar, numbered tabs and a status line whose key hints all work (p, i, g, t and the tab numbers), with the keys switch and the theme name. The home page is the two panes of the S2 mockup, whoami and ls ~/projects; lists, detail pages and the 404 share the frame in one column. Load @whatsaaaa/design-system 0.1.0 the documented way: its stylesheet after the theme and keys head scripts, defineGhost() and enableShortcuts() on the client, and <ws-ghost> rendered on the server. All site styles take their colors, type and space from its tokens. The handle's favicons and social card come from its asset kit, unchanged. Replace the placeholder content with form-builder, design-system, dotfiles and building-blocks, written from their public READMEs, and two ideas: a React and a Vue component library on the design system. Align the Node engines with the package's (^22.18.0 || >=24.12.0).
The t hint is hidden on a phone, so a phone visitor had no way to switch themes. The theme name in the status line (rose-pine or rose-pine-dawn) is now a button that switches the theme at every width, as in the Vue sample app. When it is pressed from the keyboard the focus moves to the name that shows next, so it is not lost. To keep the path readable next to it on a phone, the status line's segments are a little tighter there and the path shows only the file's name; the current tab says where it is. The phone gutter now starts where the tab bar's brand does.
…--frozen-lockfile` with ERR_PNPM_MINIMUM_RELEASE_AGE_VIOLATION. pnpm 11.27.0 by default rejects packages less than a day old, and `@whatsaaaa/design-system@0.1.0` was published today (2026-11-13T17:33Z). This PR's lockfile is the first to depend on it, so the failure comes from this change, not from the CI infrastructure. Reproduced with a fresh copy (package.json + pnpm-lock.yaml, its own store and cache dirs, CI=true): same error. A plain local install passed only because pnpm reused a check result it had already saved for this lockfile ("verified 2h ago"). Invariant: every install that reads the committed lockfile must pass pnpm's active supply-chain policies. That covers three paths: the CI job (`ci.yml`), the deploy workflow's `withastro/action` install on push to `main` (`deploy.yml`), and a fresh local install. All three read the root `pnpm-workspace.yaml`, so the fix goes in that one file. Fix: added `pnpm-workspace.yaml` with `minimumReleaseAgeExclude: ['@whatsaaaa/design-system']` and a two-line comment saying why. The exception covers only the user's own design-system package. The default one-day wait still applies to every other dependency (`pnpm config get minimumReleaseAge` is unset, so the default holds), and the lockfile is unchanged. Verification: - The fresh copy plus the new file runs `pnpm install --frozen-lockfile` with exit 0 ("Lockfile passes supply-chain policies"), and its lockfile is byte-identical afterwards. - In the worktree: `pnpm install --frozen-lockfile` ok, `pnpm format:check` clean, `pnpm lint` clean, `pnpm check` 0 errors/0 warnings/0 hints, `pnpm build` built 10 pages. - The temporary `.ci-repro` directory was removed. Alternative not taken: no code change. The failure clears on its own after 2026-11-14T17:33Z, but until then both CI and the deploy stay blocked, and it would recur on every same-day design-system release
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.
Intent
Apply the Whatsaaaa design system to this personal website, following the "S2 Terminal" direction picked while the design system was planned: the site as a terminal session, with a tab bar, a two-pane home page (
whoamiwith the ghost, handle, tagline, bio and stack;ls ~/projects), and a status line with real key shortcuts, the keys on/off switch and the theme name.Decisions made for it:
What Changed
@whatsaaaa/design-systemas a terminal session. Each page has a tab bar with the ghost and its easter egg, the section tabs and agithub ↗link. The home page has two panes:whoami(handle with a block cursor, tagline, bio, stack) andls ~/projects. The status line has thep/i/g/tshortcuts and a keys on/off switch. The oldProjectCard/StatusBadgecomponents and most of the hand-rolled CSS are replaced by newTabBar,StatusLine,Listing,Entry,State,Ghost,PromptLinkandDocumentcomponents.theme-colorfollows the active theme, and the 404 page shows the missing path and is markednoindex.form-builder,design-systemanddotfiles(active) andbuilding-blocks(experimental), plus two ideas for React and Vue component libraries. Also adds a favicon set, an apple-touch icon and a 1280x640 social card (og:image,summary_large_image), and loosens the Node engine range to^22.23.4 || >=24.12.0.🤖 Generated with Claude Code
Risk Assessment
✅ Low: A well-bounded restyle of a static Astro site onto the published design system; both fix rounds (theme-color sync, focus hand-off, 320px reflow, status-path container query) were traced against the current code and the built output and hold, and no new defects, intent contradictions, or privacy/security paths were found.
Testing
I built the site for production and served it with astro preview, then drove it end to end in headless Chrome for Testing. All of it passed: - Every page renders in the S2 terminal frame with the agreed content. - The keyboard shortcuts and the remembered keys switch work. - On a 390px touch phone, tapping the theme name switches the theme. The choice is remembered and the browser-bar color follows it. - Keyboard focus stays on the visible theme name aftert, Enter or Space. - A 328-combination sweep from 320 to 400px (both themes, keys on and off) found no clipped functional item, no overflow inside the frame's overflow-hidden parts, and no partial glyph in the path. The screenshots and status-line strips show the same. - No console errors. I removeddist/and stopped the preview server and the browser.Evidence: Phone tap transcript (theme, storage, theme-color, both system schemes)
Evidence: t shortcut and theme persistence transcript
Evidence: Navigation shortcuts and keys switch transcript
Evidence: Theme focus hand-off transcript (t, Enter, Space, keys off)
Evidence: 320-400px reflow sweep, 328 combinations, 0 issues
Pipeline
Updates from git push no-mistakes
✅ **Intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
🔧 **Review** - 2 issues found → auto-fixed (2) ✅
src/layouts/Base.astro:57- The browser-bar color ignores the theme the visitor picks. The two theme-color meta tags are chosen only byprefers-color-scheme, but this change adds a theme switch (thetkey, and now the theme-name buttons at every width) that setsdata-themeon <html> and remembers the choice. Example: an Android phone with a dark system theme opens the site, tapsrose-pinein the status line, and the page turns Dawn (#faf4ed) while Chrome's address bar stays #191724. The mismatch then returns on every later page load, becausethemeInitScriptreappliesdata-theme=lightbut nothing updates theme-color. Phone visitors are exactly who the last intent decision ("so phone visitors can switch themes") is for. The defect is mechanical, but the fix needs a decision on where it lives, which is why this is ask-user. Option 1 is in@whatsaaaa/design-system(setTheme/themeInitScript), the shared boundary every consumer uses, including the Vue sample app. Option 2 is a local fix in this site: a head script after the meta tags plus the click handler at Base.astro:107-119, both setting the meta content fromgetTheme().src/layouts/Base.astro:109- The focus hand-off only runs when the clicked control was itself the focused one, so it misses thetkey path. Sequence: on a wide screen with keys on, a keyboard user Tabs to therose-pinetheme-name button and pressest.enableShortcutsclicks the hint button[data-ws-key=t], sofocusedis false (activeElement is the theme-name button, notcontrol). The theme switches, the focusedrose-pinebutton getsdisplay:none, and focus falls to <body> instead of moving torose-pine-dawn. This breaks the invariant the comment at lines 111-112 promises. Fix: captureconst active = document.activeElementbeforetoggleTheme(), then move focus whenactivematches[data-theme-name]and has no client rects. That covers both the click path and the shortcut path.🔧 Fix applied.
3 issues (2 warnings, 1 info) still open:
src/layouts/Base.astro:57- The browser-bar color ignores the theme the visitor picks. The two theme-color meta tags are chosen only byprefers-color-scheme, but this change adds a theme switch (thetkey, and now the theme-name buttons at every width) that setsdata-themeon <html> and remembers the choice. Example: an Android phone with a dark system theme opens the site, tapsrose-pinein the status line, and the page turns Dawn (#faf4ed) while Chrome's address bar stays #191724. The mismatch then returns on every later page load, becausethemeInitScriptreappliesdata-theme=lightbut nothing updates theme-color. Phone visitors are exactly who the last intent decision ("so phone visitors can switch themes") is for. The defect is mechanical, but the fix needs a decision on where it lives, which is why this is ask-user. Option 1 is in@whatsaaaa/design-system(setTheme/themeInitScript), the shared boundary every consumer uses, including the Vue sample app. Option 2 is a local fix in this site: a head script after the meta tags plus the click handler at Base.astro:107-119, both setting the meta content fromgetTheme().src/layouts/Base.astro:109- The focus hand-off only runs when the clicked control was itself the focused one, so it misses thetkey path. Sequence: on a wide screen with keys on, a keyboard user Tabs to therose-pinetheme-name button and pressest.enableShortcutsclicks the hint button[data-ws-key=t], sofocusedis false (activeElement is the theme-name button, notcontrol). The theme switches, the focusedrose-pinebutton getsdisplay:none, and focus falls to <body> instead of moving torose-pine-dawn. This breaks the invariant the comment at lines 111-112 promises. Fix: captureconst active = document.activeElementbeforetoggleTheme(), then move focus whenactivematches[data-theme-name]and has no client rects. That covers both the click path and the shortcut path.src/layouts/Base.astro:148- Simplification: fix round 1 added afocusoutlistener on every theme-name button (Base.astro:148-153). When the system theme flips while a theme-name button has focus, it moves focus to the visible one. Nothing required it. The finding it came from (focus-lost-on-t-key) asked only to capturedocument.activeElementbeforetoggleTheme()so the click path and thet-key path both hand focus over, and the round already did that at Base.astro:131-146. Nothing in the user intent asks for focus handling when the system theme changes. No defect was found in it: focusout with a null relatedTarget from clicking elsewhere or leaving the window is a no-op because the button is still visible. Recommended remedy: remove the listener (lines 148-153) and keep the minimalkeepFocus(focused)click-path fix, unless the author wants this extra behavior.🔧 Fix applied.
✅ Re-checked - no issues remain.
✅ **Test** - passed
✅ No issues found.
pnpm build(exit 0, 10 pages) thenpnpm preview --port 4391 --host 127.0.0.1(the preview daemon actually listened on 127.0.0.1:4393), stopped afterwards withastro preview stopHeadless Chrome for Testing viachrome-devtools-axi(session nm01m7b4): desktop 1440x900 screenshots of home in both themes, projects list, design-system project, ideas list, vue idea, 404 (HTTP 404 + noindex)Keyboard run:p,i,1,2,3,g(click intercepted, so the browser never left the site),/, the keys switch on/off/remembered, andtwith keys on and offPhone 390x844 mobile+touch: tapped the theme name (system dark, then system light). Checked data-theme, the stored ws-theme, the matching theme-color meta, the background, and that the choice survives to the next pageFocus hand-off: Tab to the theme-name button, thent,t, Enter, Space, plus Enter with keys remembered off. Checked that activeElement and :focus-visible move to the shown theme nameReflow sweep: 320-400px in 2px steps in same-origin iframes, dark/light x keys on/off, on/and/ideas/react-component-library/(328 combinations). Checked that the mode, keys switch and theme name are inside the status line and not clipped. Checked .window/.ws-tab-bar/.ws-status-line/.pane/.column/page overflow. Checked that the path is absent or shows at least one character plus the ellipsis with its full 10px padding and doesn't overlap the keys switch. Checked that the whoami cursor, h1 and tagline fit the paneVisual status-line strips at all 41 widths for each theme/keys combination, plus full-page 320px home screenshots (light/keys off, dark/keys on)Ghost easter egg: pressed the ghost 3-4 times, which brought up the speech bubble (screenshot)Console check: no console messages✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.