docs/design
| Name | Last commit message | Last commit date |
|---|---|---|
| .. | ||
README.md
Neon Glow design#
Status: design specification for the first usable product. Web and native UIs are now implemented; implementation notes record the delivered scope and remaining validation. Framework documentation checked on 20 November 2026.
Build through chat, try the result, send it, and change what comes back. The interface should make a strange idea easy to pursue. The examples and starter prompts demonstrate possibilities rather than define the available formats.
Documents#
- Experience: navigation, screens, interactions, sharing, and failure behavior.
- Web: TanStack Start, Base UI, CSS Modules, and responsive layout.
- Native: Expo, native navigation, React Native components, and platform behavior.
- Client state: TanStack DB on web and native, Neon Realtime, optimistic writes, reconnects, and collection ownership.
- ASCII sketches: the proposed screen compositions.
These specifications refine the sketches. The build plan, agent runtime, and gameplay state remain the source for backend behavior. Stack choices explicitly requested by the founder are decisions; visual values and native component choices below are initial recommendations.
Stack decisions#
| Area | Choice |
|---|---|
| Web framework | TanStack Start with React, TypeScript, and TanStack Router |
| Web controls | Base UI, published as @base-ui/react |
| Web styling | CSS Modules and shared semantic design tokens |
| Application state on both platforms | TanStack DB with React bindings |
| Live collection synchronization | Official Neon Realtime TanStack DB adapter |
| Native framework | Expo and React Native, with Expo Router |
| Native UI | React Native primitives, StyleSheet, native navigation and platform APIs |
| Generated creations | Shared browser player; isolated frame on web and isolated content within a native WebView |
Share contracts, collection factories, API actions, and visual tokens. Render web and native controls separately. Generated creations have their own visual identity and are not required to use the builder's UI libraries.
Review of the sketches#
| Gap | Design resolution |
|---|---|
| Switching to Play could destroy a running game | Keep one player instance where feasible; suspend it when hidden; recover safely after suspension |
| A completed edit could interrupt active play | Announce a ready version and let an active player choose when to load it |
| Copying a link could accidentally publish a draft | First sharing has an explicit Create link action; closing the dialog changes nothing |
| Shared edits update friends' apps | Show shared status persistently and explain automatic working updates at first sharing |
| Chat could imply a queued message interrupts the agent | Label queued messages and keep Stop distinct from Send |
| Undo has consequences for active and queued requests | Explain those consequences before restoring; keep the conversation and player progress |
| Live data might look fresh while disconnected | Track connection health separately from collection readiness and show stale state |
| A native app could become a website wrapper | Use native chat, navigation, keyboard behavior, pickers, and sharing; reserve WebView for creations |
| Library examples span incompatible releases | Pin and validate one compatible TanStack DB/Neon adapter set before scaffolding |
Visual direction#
Revised 23 November 2026: the first calm, single-accent shell read as flat, and the colourful creations were hidden behind text cards. The shell now leans into the name: deep blacks, a lime/cyan/pink glow gradient for primary actions, bold type, and each app's own cover blurred behind its player ("ambient" backdrop). Creations still supply most of the colour and motion; the shell frames them. Avoid a developer-console treatment of chat.
Use system sans-serif fonts. Start with 16px web body text, a 1.5 line height, and native body text around 16-17 logical units that respects system text scaling. Metadata can be smaller, but controls must not depend on tiny text. Chat messages are ordinary text with clear author labels and modest spacing.
Starting semantic colors, subject to visual review:
| Token | Dark | Light |
|---|---|---|
color.canvas | #07070C | #F7F8F4 |
color.surface | #11111A | #FFFFFF |
color.text | #F7F6FF | #19231D |
color.textMuted | #A8A6C2 | #526358 |
color.border | #262637 | #CDD6CE |
color.accent | #B7FF5A | #326D12 |
color.onAccent | #0F1A05 | #FFFFFF |
color.pink / color.cyan | #FF4FD8 / #45E6FF | — |
Follow the system color scheme initially, with an account preference later if needed. Generated content keeps its own theme. Add semantic success, warning, error, and focus tokens when those components are implemented; verify contrast in their actual states. Decorative border colors are not the only indication of an input, selection, focus, or error.
Use a spacing scale of 4, 8, 12, 16, 24, 32, and 48. Start with radii of 8 for controls, 14 for cards, and 20 for larger floating surfaces. Reserve pills for compact state labels and the Chat / Play selector. Use elevation for overlays rather than applying shadows to every surface.
Store platform-neutral values in the planned packages/design-tokens package.
Web maps values to CSS custom properties; native maps them to typed theme objects.
Share semantic names and values, with platform-specific typography and elevation.
CSS files are not imported into native code.
Accessibility and motion#
- Aim for WCAG 2.2 AA in the web builder: readable contrast, visible focus, keyboard access, meaningful labels, and no color-only status communication.
- Give primary touch controls at least 44 CSS pixels on mobile web, 44pt on iOS, and 48dp on Android; expand icon hit areas without crowding adjacent controls.
- Respect reduced motion, text scaling, safe areas, screen readers, and platform back behavior. Keep close/back controls outside generated content.
- Use short transitions for focus, pressed state, and view changes. Loading indicators remain legible with motion disabled. Do not animate every token.
- Validate generated content separately; accessible builder controls do not make an arbitrary generated game accessible automatically.
First implementation review#
Review one end-to-end exchange: create a sandwich, change it, share it, remix it as a second account, send the remix back, and reopen the original after an update. The original should retain its link and compatible progress; the remix should stay independent. Repeat with a narrow screen and the keyboard open, then move the same conversation between web and native.
Implementation acceptance scenarios are in each document. They are requirements for later validation, not evidence that these behaviors already work.