Rotating words: {Next|Now} in titles and text cycles through its choices

Migration 084: site defaults for the motion (slide, flip, fade, type,
mirror), direction and seconds per word in Site settings, and a hero's
and a block's own. The hero's headline, section and band titles,
headings, paragraphs, callouts and quotes rotate; menus, tab titles,
search text and emails show the first word; less motion shows it still.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Aidan Dona 2026-10-17 00:43:59 -05:00
parent ab8dcdd608
commit a10ff6d75f
30 changed files with 411 additions and 37 deletions

View file

@ -13,6 +13,7 @@ import { useCallback } from 'react'
import { useSitePageHeadings } from './useSitePages.ts'
import { UNLISTED_PRESETS } from '../pages/sections/Bands.tsx'
import { firstWords } from '../lib/words.ts'
export type NavSection = { label: string; hash: string }
@ -23,7 +24,7 @@ export function useNavSections(): (path: string) => NavSection[] {
(path: string) =>
(sitePages?.[path] ?? [])
.filter((section) => !UNLISTED_PRESETS.includes(section.preset ?? ''))
.map((section) => ({ label: section.title, hash: `#${section.anchor}` })),
.map((section) => ({ label: firstWords(section.title), hash: `#${section.anchor}` })),
[sitePages],
)
}