Skip to content

CSS API reference

The CSS API reference covers pantoken's class-based component layer: components, utilities, global rules, and declarations built on the token system.

Components

NameClassSummary
agent-shell.instui-agent-shellA surface container for AI agents.
alert.instui-alertAn inline message with a status colour bar and a masked status glyph from the shared icon set.
avatar.instui-avatarA user avatar showing initials or an image, circular by default.
badge.instui-badgeA small count or status dot placed over a target's corner.
banner.instui-bannerA dismissible, iconed message surface for page-level or in-context announcements.
billboard.instui-billboardA large empty-state or call-to-action block: a hero icon or image, a heading, and a message.
breadcrumb.instui-breadcrumbA breadcrumb trail with separators; the last crumb is the current page.
breadcrumb.linkliA crumb (InstUI Breadcrumb.Link), an <li> in the parent's <ol>; the last one is the current page.
button.instui-buttonAn accessible action control, styled from the token palette; primary by default.
byline.instui-bylineA media object: a hero figure beside a title and description.
calendar.instui-calendarA static month grid with navigation, weekday headers, and day cells.
calendar.day.dayA day cell (InstUI Calendar.Day); -today, -selected, and -outside-month mark its state.
card.instui-cardA surface container that accepts arbitrary content.
checkbox.instui-checkboxA native checkbox and its label, or a switch via -variant-toggle.
close-button.instui-close-buttonA transparent icon button that draws its own × glyph, in three sizes plus an inverse variant.
context-view.instui-context-viewAn elevated callout with a caret, positionable on any side; works as a native [popover].
drawer-layout.instui-drawer-layoutA split layout with a collapsible side tray and a primary scrollable content pane.
drawer-layout.content.contentThe primary content pane that fills remaining space beside the tray.
drawer-layout.tray.trayThe side panel beside main content, with optional overlay and tray-like surface modifiers.
file-drop.instui-file-dropA file dropzone with hover, accepted, and rejected states.
form-field.instui-form-fieldA form-field wrapper: a label, its controls, and inline, required, or readonly layouts.
form-field-group.instui-form-field-groupA <fieldset> group with a legend, a column or inline layout, and configurable spacing.
form-field-messages.instui-form-field-messagesField help and validation messages — hint, error, success, and screen-reader-only — with a glyph on error and success.
heading.instui-headingHeading typography from -level-h1 to -level-h6.
img.instui-imgA styled <img> with display, crop, and effect modifiers that stack.
in-place-edit.instui-in-place-editA [contenteditable] that reads as text until focused, then shows input chrome.
input-group.instui-input-groupA facade around a text input with leading and trailing icon slots.
link.instui-linkA styled hyperlink with sizes, an inverse variant for dark backgrounds, and inline or unstyled forms.
list.instui-listA list with token-driven item spacing.
list.item.instui-listA list item (InstUI List.Item).
mask.instui-maskAn in-flow overlay that fills its positioned parent and centres its content — e.g. a spinner over a card. For a modal, prefer a native <dialog> (its ::backdrop is the mask). Every one of these modifiers is also available globally (bare, or chained onto any other component) — see the mask global utility.
menu.instui-menuA dropdown surface of items, groups, and separators.
menu.group.groupA labelled group heading (InstUI Menu.Group/Menu.ItemGroup).
menu.item.itemA menu entry (InstUI Menu.Item); add -disabled, -highlighted, or -active/[aria-checked].
menu.separator.separatorA divider rule between items (InstUI Menu.Separator).
metric.instui-metricA labelled statistic — a large value over a caption.
modal.instui-modalA dialog surface (works on a native <dialog>); header/body/footer parts.
modal.body.bodyThe content region (InstUI Modal.Body); a lone <img> goes full-bleed.
modal.footer.footerThe actions row (InstUI Modal.Footer).
modal.header.headerThe title row (InstUI Modal.Header).
number-input.instui-number-inputA number-input facade with a +/- spinner column.
pagination.instui-paginationPage navigation: numbered pages, first, previous, next, and last arrows, and an ellipsis for gaps.
pagination.page.pageA page link or button (InstUI Pagination.Page); the current page carries [aria-current].
pill.instui-pillA compact status label; add a leading glyph with the shared -icon-<name> form.
popover.instui-popoverAn elevated surface for a native [popover], positioned with CSS anchor positioning.
progress.instui-progressA determinate progress bar with a coloured meter, sizes, and an optional value label.
progress-circle.instui-progress-circleA circular progress ring driven by --value and --value-max custom properties.
radio.instui-radioA native radio button and its label.
radio-input-group.instui-radio-input-groupA single-select radio <fieldset>, plain or as a connected segmented toggle.
range-input.instui-range-inputA styled range slider with an inverse value bubble.
rating.instui-ratingA star rating with filled and empty glyphs and an optional numeric label.
side-nav-bar.instui-side-nav-barA vertical navigation rail of icon-over-label items, with a minimized icons-only mode.
side-nav-bar.item.itemA navigation entry (InstUI SideNavBar.Item); -selected marks the active one.
simple-select.instui-simple-selectA styled native <select> with a caret, matching the text-input states and sizes.
spinner.instui-spinnerAn animated loading ring; give it role="status" and an aria-label.
table.instui-tableA styled data table for th and td plus an optional caption, with hover, fixed, and stacked-card layouts.
table.bodytbodyThe table's data row group (InstUI Table.Body).
table.celltdA data cell (InstUI Table.Cell).
table.col-headerthA column-header cell (InstUI Table.ColHeader); the default th styling, overridden by table.row-header for th[scope="row"].
table.headtheadThe table's header row group (InstUI Table.Head).
table.rowtrA table row (InstUI Table.Row).
table.row-headerth[scope="row"]A row-header cell (InstUI Table.RowHeader); styled from the row-header tokens, not the column-header ones.
tabs.instui-tabsA tabbed panel set: a tab list, selectable tabs, and their panels.
tabs.panel.panelThe content panel for a tab (InstUI Tabs.Panel).
tabs.tab.tabA single tab button (InstUI Tabs.Tab, configured via the parent Tabs's tab list); -selected marks the active one.
tag.instui-tagAn inline chip for a keyword or filter.
text.instui-textBody-text typography with size, weight, colour, and style modifiers.
text-area.instui-text-areaA styled, resizable native <textarea> with the same states and sizes as the text input.
text-input.instui-text-inputA styled native <input> — including date, time, and datetime-local, where the browser supplies the picker — with validation states and sizes.
toggle-details.instui-toggle-detailsA styled native <details> disclosure with a rotating chevron.
toggle-group.instui-toggle-groupA bordered disclosure built on <details>: a chevron summary row and collapsible content.
tooltip.instui-tooltipA CSS hover and focus tooltip bubble, positionable on any side.
tray.instui-trayAn edge-pinned panel that slides in from any side; a native [popover] or <dialog>.
tree-browser.instui-tree-browserA disclosure tree of nested collections and leaf items, with rotating chevrons.
view.instui-viewThe View primitive: a neutral box with key-value modifiers for background, border, radius, shadow, display, position, overflow, and cursor. Every one of these modifiers is also available globally (bare, or chained onto any other component) — see the background/border/shadow/display/position/overflow/cursor utilities.

Utilities

NameClassSummary
color.--text-dangerSemantic colour utilities: .--bg-<name>, .--text-<name> (aliased as .--color-<name>), and .--border-<name> for the curated semantic palette. Every one of these also has a component-attached alias modifier (for example -bg-danger on any .instui-<component>).
cursor.--cursor-pointercursor as a composable, global class — .--cursor-<value> — usable bare or chained onto any component (.instui-button.--cursor-pointer).
gap.--gap-mdFlex/grid gap utilities on the spacing scale, short (--gap-sm) or long (--gap-small) spelling. Usable bare or chained onto any component (.instui-view.--gap-sm) — components that already set their own gap from a component-specific token may have it overridden.
icon.instui-iconThe icon system: .instui-icon sizing plus the shared -icon-<name> painter that masks a glyph (in currentColor) before any element.
layout.--display-flexDisplay and text-align utilities — .--display-<value> and .--text-align-<value> — as composable, global classes, usable bare or chained onto any component.
maskglobal.--mask-overlayA global, dual copy of the mask component's overlay modifiers — --mask-overlay, --mask-fullscreen, --mask-blur — usable bare or chained onto any component, without wrapping in a .instui-mask element.
overflow.--overflow-x-hiddenoverflow-x/overflow-y as composable, global classes — .--overflow-x-<value> / .--overflow-y-<value> — usable bare or chained onto any component.
position.--position-relativeposition as a composable, global class — .--position-<value> — usable bare or chained onto any component (.instui-button.--position-relative).
responsive[class*="-hidden-"],[class*="-show-"]Viewport- or container-width show/hide classes across a themed breakpoint scale.
screen-reader-content.instui-screen-reader-contentVisually hides content while keeping it available to assistive tech (the standard clip pattern).
spacing.--p-mdMargin and padding utilities — .--m<side>-<step> / .--margin-<side>-<step> and .--p<side>-<step> / .--padding-<side>-<step> on the spacing scale (sides t/b/s/e/x/y or none, spelled short or fully long — for example --mb-sm and --margin-bottom-small are the same rule; margin also takes auto). Usable bare or chained onto any component (for example class="instui-view --mb-sm").
stacking.--stack-topmostz-index depth utilities — .--stack-<level> (deepest, below, above, topmost) — usable bare or chained onto any component, so layers stack predictably instead of by hand-tuned numbers.
transition.instui-transition.-transition-fade-enteringAnimation state classes for the Transition component — .instui-transition and state classes (-transition-fade-entering, -transition-scale-exited, etc.) — usable bare or chained onto any component.
truncate.--truncateEllipsis truncation with line clamping controlled by --lines — usable bare or chained onto any component (.instui-button.--truncate).
visual-debug.-with-visual-debugA layout-debugging outline: compound .-with-visual-debug onto any element to outline the box and its immediate children, so a layout's structure is visible at a glance.

Rules

NameClassSummary
base*The opt-in global reset: box-sizing, the page surface, base text colour and font, color-scheme, and link defaults.
prose:where(body)Typographic defaults for raw HTML — headings, paragraphs, lists, links, and code — applied automatically wherever it's imported (default :where(body)); pass options.scope to target a different content root instead (e.g. .vp-doc).

Plugins

NameClassSummary
logos.logosInstructure product logos as CSS image tokens: --instui-logo-<product>-<layout>-<mode> holds a data-URI SVG, so a logo paints via e.g. background-image: var(--instui-logo-canvas-horizontal-color).
primitives.instui-bg-primitive-color-whiteOpt-in utility classes for the raw primitive palette: .instui-bg-/fg-/border-primitive-color-<name> paint a colour from the primitive colour tokens, plus font-family/font-weight utilities for the primitive font tokens. Kept out of the semantic utilities so overrides there stay semantic-only.
visual-debug.-with-visual-debugA layout-debugging outline: compound .-with-visual-debug onto any element to outline the box and its immediate children, so a layout's structure is visible at a glance.

layout

NameClassSummary
wrapperbody[class~="instui-display-flex"]App-shell row: side nav, container with header, and optional panel.