# Niveus — reference Every class, token, attribute and function the system exposes, with the name the rest of the industry uses for it. Two audiences: - **People.** Find the thing you mean by its usual name, then use the class beside it. - **Models.** This file is the whole API. Hand it over on its own and an assistant can build correct Niveus markup without seeing the CSS: it does not need to know *how* `.nv-nav-tabs` works, only that a tab list is spelled that way here. Nothing below is aspirational — `tools/check.py` fails if a class exists in the CSS and is missing from this file. Everything ships inside the `niveus` cascade layer, so unlayered application styles win without `!important`. ```html ``` --- ## Button | Class | Known as | Does | | --- | --- | --- | | `.nv-button` | button, secondary button | Raised surface. The default; use it for anything that is not *the* action. | | `.nv-button--primary` | filled / CTA button | The single affirmative action in a view. | | `.nv-button--subtle` | tonal button | Accent-tinted fill, no elevation. Mid-emphasis. | | `.nv-button--ghost` | text / quiet button | No material until hovered. Lowest emphasis. | | `.nv-button--danger` | destructive button | Irreversible actions only. | | `.nv-button--frosted` | glass button | For use over imagery or frosted chrome. | | `.nv-button--float` | FAB, overlay control | Floats over content: grows on hover instead of lifting, and keeps its own positioning via `--nv-button-offset`. | | `.nv-button--sm` `.nv-button--lg` | size variants | 28px and 44px; default is 36px. | | `.nv-button--icon` | icon button | Square. Requires `aria-label`. | | `.nv-button--pill` | pill button | Fully rounded. | | `.nv-button--block` | full-width button | Fills its container. | | `.nv-button__icon` | button icon slot | Sizes an inline SVG to the label. | | `.nv-button-group` | segmented control, button group | Buttons sharing edges; only outer corners round. | States come from the element: `disabled`, `aria-disabled`, `aria-busy="true"` (shows a spinner and keeps the width), `aria-pressed` for toggles. ## Form controls | Class | Known as | Does | | --- | --- | --- | | `.nv-field` | form field, form group | Label + control + hint, correctly spaced. | | `.nv-field__label` | field label | Add `data-optional="(optional)"` to append a muted suffix. | | `.nv-field__hint` | helper text | Guidance below the control. | | `.nv-field__error` | validation message | Pair with `aria-invalid="true"` + `aria-describedby`. | | `.nv-input` | text field, form control | `input`, `textarea` and `select`. Inset material. | | `.nv-input--sm` `.nv-input--lg` | size variants | Match the button sizes. | | `.nv-input--color` | color well / swatch input | `input[type=color]` as a square swatch. | | `.nv-input-group` | input with adornment | Wrapper for a field with a prefix or suffix. | | `.nv-input-group__affix` | prefix / suffix adornment | Sits inside the field's recess. First child = leading, last = trailing. | | `.nv-select` | select, dropdown | Wrapper that draws the chevron around a native `select.nv-input`. | | `.nv-checkbox` | checkbox | Native input, custom mark. Supports `:indeterminate`. | | `.nv-radio` | radio button | Native input, custom mark. | | `.nv-switch` | toggle switch | Inset track, elevated thumb that travels. | | `.nv-choice` | control with inline label | `