Repository navigation
Keep the home hero rotating, with a pause control - #25
Merged
Merged
Conversation
The page-wide key handler took Enter for the view's pivot and called preventDefault, so a keyboard user could not follow a focused link or press a focused button anywhere on the site. Enter on those is the browser's now; the pivot still runs when focus is on the page or a list. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The typed tagline was liked enough to keep going: the hero now cycles the name, the tagline and two jokes on 16, each held for its own time (the name and tagline longer). All lines sit invisibly in the hero's grid cell, so its height is the tallest line's and the page never shifts. Motion that runs past 5 s needs a way to stop it (WCAG 2.2.2), so a small "pause" toggle hangs in the h1's bottom margin, out of the flow; hovering the line or keyboard focus on the toggle holds it too. A hidden tab or a hero scrolled out of view stops the timers. Screen readers still get only the tagline, and reduced motion gets it still, with no toggle. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The user's pick from the alternatives: it lands the 16 on the game's own lore rather than on portal arithmetic. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
The home hero from #11 no longer stops on the tagline. It types each line, holds it, backspaces it and moves on to the next, round and round, with the same 35-70 ms jitter as before.
Phrases
All lines are in one array in
site/src/views/Home.svelte, written as{ text, hold }. Adding, dropping or retiming a line changes one line of code.NMSii: No Man's Sky Items InterfaceThe numbers No Man's Sky doesn't show you16 glyphs. 0 wiki tabs.Six-teen. Not six-seven. :xLine 4 is the 6-7 meme. It is a separate entry with a comment, so it can be dropped when the meme ages.
:xis plain ASCII, so it renders in 0xProto and doesn't affect line height.Other 16 jokes that could replace line 3:
12 glyphs to anywhere. 16 to choose from.Portal addresses: 12 glyphs, 16 to pick from, 0 guesswork.16 glyphs, 16 Atlas interfaces, 1 spreadsheet.The Atlas counts in 16. So do we.Behaviour
Pausing (WCAG 2.2.2)
I added a small
‖ pause/▶ resumetoggle instead of making the h1 clickable. Making the heading a button would remove its heading semantics. An h1 that toggles on click also gives no hint that it can be clicked.aria-labelthat switches between "Pause the title animation" and "Resume the title animation".The rotation also stops in these cases:
:focus-visible); pressing it to resume also lifts this holdvisibilitychange)A pause keeps the current position in the line. Every timer and observer is cleared when the page is destroyed.
Screen readers only hear the h1's
aria-label, which is the tagline, and never the rotation. With reduced motion the tagline is shown still, with no toggle and no rotation.Also: Enter on focused links and buttons
The page-wide key handler (
lib/keys.js) treated Enter as the view's pivot key and calledpreventDefault. As a result, Enter could not activate a focused link or button anywhere on the site, and the new toggle didn't respond to Enter either. Enter ona[href],buttonandsummarynow does the browser's default. The pivot still works when focus is on the page or a list. This is a separate commit.<title>, the markdown export and llms.txt are unchanged.Checks
npm run check: 0 errors, 0 warningsmise run test: 247 passeddist/(CDP), dark and light themes, at 1400 px and 390 px:document.hiddenoverridden andvisibilitychangedispatched) and scrolling the hero away each kept the text unchanged for 5.5 s mid-typing, and it resumed afterwards.mise run web:lighthouse --local --preset desktop: perf 97, a11y 100, CLS 0.006🤖 Generated with Claude Code