TabotaboColors

data class TabotaboColors(val hue: Hue, val isDark: Boolean, val background: Color, val surface: Color, val primary: Color, val onPrimary: Color, val accent: Color, val muted: Color, val outline: Color, val outlineStrong: Color, val disabled: Color)(source)

The design system's full palette. It is a superset of what M3's ColorScheme can express: accent and muted have no exact M3 slot.

Constructors

Link copied to clipboard
constructor(hue: Hue, isDark: Boolean, background: Color, surface: Color, primary: Color, onPrimary: Color, accent: Color, muted: Color, outline: Color, outlineStrong: Color, disabled: Color)

Properties

Link copied to clipboard

Baseline text: near-white / near-black with a hint of the hue.

Link copied to clipboard

Screen background: near-black / near-white, faintly tinted.

Link copied to clipboard

Content and outline of disabled controls.

Link copied to clipboard
val hue: Hue

The hue every role is derived from.

Link copied to clipboard

Whether this is the dark variant.

Link copied to clipboard

Subtitles, descriptions, inactive labels.

Link copied to clipboard

Content drawn on a primary fill (rare; buttons are outlined).

Link copied to clipboard

Soft, decorative borders: cards, dialogs and tags. Not contrast-checked.

Link copied to clipboard

Borders that identify an interactive control (secondary buttons, unselected pills): the outline tone nudged to ContrastTargets.Graphics (3:1) against both background and surface.

Link copied to clipboard

Emphasis: focused text, highlighted outlines, primary actions.

Link copied to clipboard

Card and button fill, one step off background.

Functions

Link copied to clipboard
fun distinct(index: Int): Color

Returns a color for the index-th item that must be told apart from the others (people, chart series, tags). The hue steps by the golden angle (137.5°) from primary, uses the primary's tone, and gets the same contrast nudging. Index 0 is primary.

Link copied to clipboard

Maps the palette onto Material3 roles so stock M3 components follow the scheme. Secondary and tertiary reuse TabotaboColors.primary (single hue), every surface container is TabotaboColors.surface, and surfaceTint is transparent so tonal elevation never tints. M3 outline (important boundaries) is TabotaboColors.outlineStrong and outlineVariant (decorative) is TabotaboColors.outline. The error roles are not overridden: they keep Material's own light / dark values.