OGE logoOGE

Color Palette

An inline swatch grid as a form editor — Kendo's ColorPalette: a built-in preset (default, basic, office, material, monochrome) or your own list, in an APG role="grid" with one roving tab stop and real DOM focus on the tiles. The selected tile carries aria-selected and a checkmark colored for contrast.

Works standalone via [(value)], with Signal Forms via [formField], and with reactive/template forms via formControl/ngModel.

APG grid presets roving tabindex forms

Getting started

Arrows move by tile / row (RTL-mirrored; the grid neither wraps nor crosses rows), Home/End to the row edges, Ctrl+Home/Ctrl+End to the corners; Enter, Space or a click picks. The value is the swatch string exactly as listed.

value APG grid Enter / Space

Value: #4a86e8

Presets

palette takes a preset name — 'default' | 'basic' | 'office' | 'material' | 'monochrome' — and each preset brings its own column count. OGE_COLOR_PALETTE_PRESETS exports the data for building around the same sets.

palette office material

Custom swatches

Pass your own CSS colors (unparseable entries are dropped), a columns count and a fixed tileSize in px — the grid then shrink-wraps the tiles instead of sharing the width.

palette: string[] columns tileSize

Inside a form

A FormValueControl and a ControlValueAccessor: formControl, ngModel and [formField] all bind it. Disabling the control takes every tile out of the Tab sequence.

formControl Validators.required disabled

Valid: false