@bison-lab/admin-ui
v4.9.2
Published
Payload-free admin kit primitives for Bison Lab CMS fields
Maintainers
Readme
@bison-lab/admin-ui
Payload-free kit primitives for CMS field editors: type cards, dialogs
(title and optional helper at the top, outline Cancel in a footer row, optional primary confirm), buttons,
checkbox, input, switch, textarea, a stacked Field/Label (12px/700,
8px above the control), Kicker (uppercase eyebrow), Fold (accordion
that keeps its own open state and leaves children mounted; onTitleChange
edits the title in the header), ActionMenu
(the ⋯ Header, Footer, and Fold share: caller rows pass an icon; Delete
is onDelete, last, destructive, and confirmed), Stack (locked
12px column gap for a list of folds and the add button after them), a Radix
select (not a native <select>; a custom closed face such as a swatch +
label goes in SelectTrigger — skip SelectValue), Table (a CSS grid the
caller sizes with columns; align moves a column's header and cells together), Thumbnail (rounded preview cell), Dropzone
(dashed well; drag or click), Pagination (page buttons plus the kit Select
for page size), Badge (variant={false} drops the semantic
preset so a caller class can paint), and the glyphs a rail or icon button
uses (Glyph variants, or variant={false} plus className). Wrap a screen
in KitProvider once so those styles mount. Field adapters in
@bison-lab/payload-blocks/admin (and later @bison-lab/payload-core/admin)
compose them and own useField / useForm.
The . entry does not import payload or @payloadcms/ui.
ActionMenu (and Fold) take non-destructive actions plus optional
onDelete. Every action must pass icon. Delete is not an action: the
kit appends it last, paints it destructive, and confirms before calling
onDelete. deleteConfirm may override title, description, and the
Cancel / Delete button labels. See CLAUDE.md in this package.
