# Rhubarb Index

Editorial · Light preview · `rhubarb-index`

## Design intent

Bright red type and a small botanical index lend structure to a garden notebook.

**Design rule.** Arrange specimen names by planting season and keep a single accent for the active index tab.

## Semantic palette

The first column of HEX values drives the light preview. Use the dark column when the appearance changes.

| Token | Default | Alternate | Role |
| --- | --- | --- | --- |
| `background` | `#F7E9E1` | `#1E161E` | Screen canvas |
| `surface` | `#FFF7EF` | `#2E262E` | Primary cards, fields and settings rows |
| `text` | `#3E2227` | `#F1E8E4` | Body text, headings and key figures |
| `muted` | `#734C52` | `#BAA9B4` | Supporting labels, axes and timestamps |
| `accent` | `#9B3048` | `#C68C96` | Primary action, focus and current data |
| `on_accent` | `#FFFFFF` | `#000000` | Action labels and icons on accent fills |
| `secondary` | `#EAB6AA` | `#B2ADAE` | Supporting artwork, comparison series and selected fills |
| `border` | `#E7C1BB` | `#574F54` | Card outlines, dividers and field boundaries |

## Type hierarchy

Display family `"Nimbus Roman", "Noto Serif CJK SC", serif`. Interface family `"Noto Sans", "Noto Sans CJK SC", sans-serif`. Font tracking is relative to the display size.

| Role | Size / line height | Weight | Treatment |
| --- | --- | --- | --- |
| Screen title | 49 / 50 px | 700 | Display, -0.045 em tracking |
| Section title | 19 / 24 px | 700 | Display, natural wrapping |
| Body and list | 15 / 22 px | 500 | Interface, sentence case |
| Caption and status | 12 / 16 px | 500 | Interface, pair states with labels |
| Metric | 63 / 63 px | 700 | Display, tabular lining figures |

## Shape and spacing

Use a 7 px spacing step, with 14 px between groups and 24 px horizontal screen insets. Feature cards use a 5 px radius. Nested input and icon containers use 0 px. Reserve at least 44 × 44 pt on iOS or 48 × 48 dp on Android for touch controls. The baseline is a 390 × 844 logical canvas.

Use solid fills to separate panels and transparent borders at rest. Give the feature card poster-like proportions with the copy and graphic on separate sides.

## Core components

- **Home.** Lead with “From seed” and the key measure 18 (varieties in stock). Put Cherry radish · Slate kale · Low marigold in the first list with a visible row label and trailing state.
- **Detail.** Pair the chart with a readable summary. Late-sown greens produced the steadiest leaves. Give the figure its unit, time window and a textual equivalent for users who skip the chart.
- **Upgrade.** Build the section around “Archive another season”. Present billing interval and price together, then a primary action and visible restore and dismissal controls.
- **Settings.** Use a profile group, labeled settings rows and plain-language switch states. Place destructive actions in a separate group with confirmation.

Set a distinct leading rhythm for headlines and captions. Label one chart baseline and let list rows grow to fit their text.

## Appearance and accessibility

Switch the complete token set on an appearance change. Preserve the hierarchy, spacing and chart labels. Verify 4.5:1 contrast for regular text and 3:1 for large text and focus indicators. If a chart series is hard to tell apart, add a point marker, dash or inline label. Test larger type, wrapping and reduced motion before shipping.

## Originality checklist

- Check that the first screen still communicates BEDS's purpose when its title is hidden.
- Keep one leading action in the first viewport and use the palette roles consistently.
- Replace generic decorative marks with a visual that clarifies the task or data.
- Check long labels, empty states and the dark appearance with real content.

## Implementation

- **iOS SwiftUI.** Define semantic colors in an asset catalog with two appearances. Use `@ScaledMetric` for type-linked spacing, `ViewThatFits` for crowded metric rows, and `accessibilityLabel` plus a summary for charts. Extend row hit areas with `contentShape(Rectangle())`.
- **Flutter.** Use paired `ThemeData` values and a `ThemeExtension` for chart tokens. Define spacing and radius in the theme and let `TextScaler` drive text growth. Add `Semantics` for indicators and actions.
- **React Native.** Map `useColorScheme()` to one semantic palette. Keep shared values in `StyleSheet.create`. Use `FlatList` for long lists, `hitSlop` to enlarge compact actions and meaningful accessibility roles and values.
