Skip to main content

Signature directions and complete screens

Atelier, Precision, Prism, Play, Grove, Relay and Marquee coordinate typography, density, surfaces and motion. They are additional recipes; existing presets and Theme::seeded keep their original mappings.

use stucco::theme::{Direction, Radius};
let theme = Direction::Atelier.theme().radius(Radius::Soft);
let variation = Direction::Prism.guided_v1(42);

Choose a direction

DirectionComposition
AtelierWarm terracotta, system serif headings, quiet rules, gentle motion
PrecisionCool grey/blue, compact controls, crisp sans headings, sharp edges
PrismViolet, layered depth, selective frost, luminous backdrop
PlayGold, heavy rounded headings, strong outlines, offset button shadows
GroveBotanical green, airy rounded headings, pill buttons, soft filled controls and open tables
RelayMonochrome ink, monospace throughout, compact square controls, dashed rules and striped tables
MarqueeWarm gold, heavy serif headings, uppercase labels, beveled corners and layered depth

Grove, Relay and Marquee are new in Stucco 0.5.

Grove suits calm community and wellbeing spaces. Relay takes its cues from printed dispatches and instrument panels. Marquee brings a theatrical feel to portfolios and cultural programs. Their guided palettes stay within those families: botanical and mineral tones for Grove, ink and signal colors for Relay, and gold, sepia and ember for Marquee.

Each supports light and dark. Tables and reading content stay opaque. The project's focal card uses the material; supporting metrics use simple rules. Reduced transparency makes translucent surfaces solid. Increased contrast and forced colors remove decorative backgrounds; reduced motion disables movement. Named ThemeScopes apply the direction's body typography as well as its colors; a scope that only switches the color scheme keeps the surrounding typography.

Explore orders, the reading page, and the project overview. Each page links all seven directions and renders both schemes without JavaScript. The copyable compositions live in examples/showcase, an unpublished workspace crate with no HTTP or storage dependency. Replace its sample content with application data; keep page-scoped metrics honestly labeled.

Guided variations and locks

The playground defaults to guided Atelier. Version 1 varies compatible palettes, typography and shape choices. Seed zero is the exact signature. Unrestricted mode still accepts the original presets, numeric seeds and text names.

Palette, typography and surfaces/motion locks capture the current effective choices when generating. Unlocked groups return to the new seed's choices. Changing direction clears locks and overrides so the new signature is visible. Explicit option edits remain available. Six favorites can be stored locally; when storage is unavailable they last only for the current visit. Comparison uses the same screen, scheme and narrow-width setting for both themes.

The canonical recipe retains the direction, generation version, seed and resolved overrides. Rust, CLI and WebAssembly use the same implementation:

stucco theme --direction atelier --format rust
stucco theme --guided prism:1:42 --format css
stucco theme 'guided=atelier:1:42&palette=sand&heading-font=serif' --format json

JSON preserves the existing light and dark color maps and adds recipe.format and recipe.query. Feed that query back into the CLI or parse it with stucco::theme::spec::ThemeSpec to recreate typography and all other choices. CSS exports contain all theme tokens. Unsupported generation versions are rejected by the strict parser. Browser URL parsing is lenient for old or malformed links. Fonts are opt-in presentation assets, separate from theme recipes; their setup must accompany an exported theme if used.

Data recipes

Avatar, Badge, Stat and ordinary text compose identity cells and statuses. Progress::new(label, value, maximum).show_value() provides native progress semantics and a visible percentage.

use stucco::data::{Sparkline, Timeline, TimelineEntry};
let trend = Sparkline::new("Tasks per week: 2 to 7 over six weeks", [2., 3., 3., 5., 4., 7.]);
let activity = Timeline::new("Recent activity, newest first")
    .entry(TimelineEntry::new("2026-10-21T14:30:00Z", "21 October · 14:30 UTC", "Keyboard review complete"));

Sparklines display the supplied summary and expose all finite samples as text. Empty series say “No data”; one sample is a point; a constant series is a flat line. Non-finite values are omitted. Supply ordered data and a meaningful period and unit in the summary. Timelines use an ordered list and native timestamps; callers determine order and time-zone labels. Optional entry icons are decorative, so the content must explain the activity.

Optional local fonts

The default directions use system fonts and request no font assets. The showcase's optional atelier-fonts feature registers local Newsreader and DM Sans faces through the existing asset registry. Add showcase-fonts to an Atelier composition to use them:

cargo run -p gallery --features atelier-fonts -- target/gallery-fonts

Open showcase-fonts.html in that output. The faces use font-display: optional to avoid a late swap; system sans and Georgia remain usable fallbacks. This opt-in adds about 127 KB of uncompressed CSS (95,016 bytes of WOFF2 before base64). It is deliberately excluded from default builds. The bundled Latin subset covers the showcase's accented names; other scripts and italic styles use the system fallback. See examples/showcase/fonts/README.md for exact coverage, weights, provenance and the included SIL Open Font Licenses.