@xleddyl/443-components-vue 0.16.97 → 0.16.99
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CATALOG.md +44 -40
- package/README.md +69 -32
- package/dist/components/core/FormField.vue +46 -2
- package/dist/components/core/FormField.vue.d.ts +2 -0
- package/dist/components/core/Root.vue +2 -0
- package/dist/components/core/Root.vue.d.ts +2 -0
- package/dist/components/core/types.d.ts +1 -0
- package/dist/components/data/FilterPills.vue +2 -1
- package/dist/components/data/Table.vue +3 -1
- package/dist/components/data/Table.vue.d.ts +1 -0
- package/dist/components/data/TileGrid.vue +1 -0
- package/dist/components/data/types.d.ts +1 -0
- package/dist/components/feedback/Alert.vue +13 -3
- package/dist/components/feedback/Alert.vue.d.ts +4 -4
- package/dist/components/forms/FileDropOverlay.vue +28 -0
- package/dist/components/forms/FileDropOverlay.vue.d.ts +410 -0
- package/dist/components/forms/SegmentedControl.vue +20 -1
- package/dist/components/forms/index.d.ts +1 -0
- package/dist/components/forms/index.mjs +1 -0
- package/dist/components/forms/types.d.ts +4 -1
- package/dist/components/layout/Accordion.vue +7 -2
- package/dist/components/layout/Accordion.vue.d.ts +2 -0
- package/dist/components/layout/Card.vue +47 -6
- package/dist/components/layout/Card.vue.d.ts +4 -0
- package/dist/components/layout/PageHeader.vue +5 -2
- package/dist/components/layout/Stack.vue +3 -2
- package/dist/components/layout/Stack.vue.d.ts +2 -0
- package/dist/components/overlays/CommandList.vue +22 -4
- package/dist/components/overlays/types.d.ts +7 -1
- package/dist/components/templates/ListPage.vue +3 -2
- package/dist/components/templates/SettingsSection.vue.d.ts +4 -0
- package/dist/composables/core.d.ts +1 -0
- package/dist/composables/core.mjs +1 -0
- package/dist/composables/forms.d.ts +1 -0
- package/dist/composables/forms.mjs +1 -0
- package/dist/composables/useFieldHighlight.d.ts +8 -0
- package/dist/composables/useFieldHighlight.mjs +19 -0
- package/dist/composables/useFileDialog.d.ts +17 -0
- package/dist/composables/useFileDialog.mjs +40 -0
- package/dist/internal/core/HighlightText.d.ts +12 -0
- package/dist/internal/core/HighlightText.mjs +30 -0
- package/dist/locale/de.mjs +3 -0
- package/dist/locale/en.mjs +3 -0
- package/dist/locale/it.mjs +3 -0
- package/dist/locale/types.d.ts +3 -0
- package/dist/nuxt/runtime/layouts/auth.vue.d.ts +2 -0
- package/dist/nuxt/runtime/layouts/dashboard.vue.d.ts +2 -0
- package/dist/styles/base.css +13 -0
- package/dist/styles/core/form-field.css +13 -0
- package/dist/styles/core/root.css +23 -0
- package/dist/styles/data/table.css +17 -0
- package/dist/styles/data/thumbnail.css +5 -2
- package/dist/styles/data/tile-grid.css +2 -1
- package/dist/styles/design-tokens.css +4 -0
- package/dist/styles/feedback/alert.css +13 -0
- package/dist/styles/forced-colors.css +12 -1
- package/dist/styles/forms/file-drop-overlay.css +48 -0
- package/dist/styles/forms/segmented.css +36 -0
- package/dist/styles/forms.css +1 -0
- package/dist/styles/layout/accordion.css +8 -0
- package/dist/styles/layout/card.css +19 -7
- package/dist/styles/layout/page-header.css +17 -2
- package/dist/styles/layout/stack.css +5 -0
- package/dist/styles/overlays/command.css +17 -0
- package/dist/styles/shared.css +8 -0
- package/dist/styles/templates/list-page.css +1 -21
- package/dist/styles/templates/workspace-layout.css +9 -0
- package/package.json +3 -2
package/CATALOG.md
CHANGED
|
@@ -10,6 +10,7 @@ This file is a map, not the full reference. For all props, tokens, theming and a
|
|
|
10
10
|
- Every `use*` composable, `toast` and `withLoading` are auto-imported in Nuxt. Without Nuxt, or in a Nuxt module or layer (it cannot rely on the auto-imports of the host), import them from `@xleddyl/443-components-vue`, and the Nuxt only `useDashboard` and `useNavigationPending` from `@xleddyl/443-components-vue/nuxt/composables`.
|
|
11
11
|
- Mount `<KOverlayHost />` once (the ready Nuxt layouts do it). It is needed for `toast`, `useConfirm`, `useAlert`, `usePrompt`, `useModal`, `useDrawer` and `useLoading`.
|
|
12
12
|
- Wrap the app in `<KRoot>` (it holds the theme, preset and scoping). The ready layouts do it.
|
|
13
|
+
- Styling markup outside the components (a site page, an iframe, a non Vue widget): import `@xleddyl/443-components-vue/tokens.css` (only the `--k-*` tokens and presets, scoped to `.k-root`) and read `var(--k-*)` inside a `class="k-root"` element, instead of copying colors.
|
|
13
14
|
- Icons are passed as names (`icon="plus"`). The type is `IconName`.
|
|
14
15
|
- Tones are always `neutral`, `accent`, `info`, `success`, `warning`, `danger` (type `Tone`).
|
|
15
16
|
- Field sizes are `sm`, `md`, `lg`. Button sizes are `xs`, `sm`, `md`, `lg`.
|
|
@@ -62,7 +63,8 @@ Playground paths in this file are relative to `playground/nuxt/app/pages/compone
|
|
|
62
63
|
| One time code, OTP | `PinInput` |
|
|
63
64
|
| File or folder upload with drop zone | `FileInput` |
|
|
64
65
|
| Focal point of an image (the part kept in view when cropped) | `FocalPointInput` (preview the crops with `Thumbnail` `focal`) |
|
|
65
|
-
| Drop files on any element | `useFileDrop`
|
|
66
|
+
| Drop files on any element | `useFileDrop` (with `FileDropOverlay` over the area while dragging) |
|
|
67
|
+
| `useFileDialog` | Open the native file dialog from a menu item or any action, without a visible input. | `useFileDialog({ accept, multiple, directory, onChange })` returns `{ files, open(overrides?), reset }`; `open()` resolves to the chosen files, empty when cancelled. | `forms/file-input.vue` |
|
|
66
68
|
| Confirm a destructive action | `useConfirm` |
|
|
67
69
|
| Show a message the user must acknowledge | `useAlert` |
|
|
68
70
|
| Ask for one text value | `usePrompt` |
|
|
@@ -156,13 +158,13 @@ Playground paths in this file are relative to `playground/nuxt/app/pages/compone
|
|
|
156
158
|
|
|
157
159
|
| Component | Purpose and when to use it | Main props, models, slots, events | Playground |
|
|
158
160
|
| ---------------- | ----------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------- |
|
|
159
|
-
| `Root` | App root. Scopes all styles under `.k-root` and sets theme, preset and tokens. Mount once. Add `is-canvas` for the page background. | Props: `theme` (system, light, dark), `preset`, `accent`, `accentContrast`, `fontSans`, `fontMono`, `fontDisplay`, `radiusScale`, `as`. Slot: default.
|
|
161
|
+
| `Root` | App root. Scopes all styles under `.k-root` and sets theme, preset and tokens. Mount once. Add `is-canvas` for the page background. | Props: `theme` (system, light, dark), `preset`, `accent`, `accentContrast`, `fontSans`, `fontMono`, `fontDisplay`, `radiusScale`, `document` (the root is the page: viewport height on the canvas, `<html>` follows its color scheme, no body margin), `as`. Slot: default. | `core/root.vue` |
|
|
160
162
|
| `Button` | Every button and button-like link. Use `CopyButton` to copy text, `DropdownMenu` for a menu. | Props: `label`, `variant` (solid, soft, subtle, outline, ghost, link), `tone`, `size`, `icon`, `trailingIcon`, `to`, `href`, `target`, `external`, `type`, `disabled`, `loading`, `block`, `square` (icon only), `tooltip` (tooltip text on hover and focus; `false` turns off the automatic one), `disabledReason` (with `disabled`: the button stays focusable and hoverable with `aria-disabled`, ignores clicks and shows the reason in a tooltip and as its description). An icon-only button shows its `aria-label` (or `title`) as a tooltip; inside a `Tooltip` it shows none. Slot: default. A `to` or `href` makes it a link. | `core/button.vue` |
|
|
161
163
|
| `Icon` | Show an icon by name. | Props: `name` (required), `label` (makes it non decorative), `size`. | `core/icon.vue` |
|
|
162
164
|
| `Spinner` | Loading indicator. Use `block` for a centered loading state that fills its container. | Props: `size` (xs to lg), `label`, `decorative`, `block`. | `core/spinner.vue` |
|
|
163
165
|
| `Input` | Single line text field. Use `NumberInput` for numbers, `PasswordInput` for passwords. | Model: `v-model` (string, number or null; modifiers `.number`, `.trim`). Props: `type`, `size`, `icon`, `clearable`, `counter` (needs `maxlength`), `transform`, `numeric` (decimal keyboard, number model, tabular digits, left aligned), `invalid`, `disabled`, `readonly`, `required`, `noAutofill`. Slots: `leading`, `trailing`. Event: `clear`. | `core/input.vue` |
|
|
164
166
|
| `Textarea` | Multi line text field. | Model: `v-model`. Props: `rows`, `maxRows`, `autoresize`, `counter`, `size`, `invalid`, `disabled`, `readonly`, `required`. Slot: `trailing`. | `core/textarea.vue` |
|
|
165
|
-
| `FormField` | Label, description, hint, error and required marker around one control. It links ids and ARIA for the control inside. | Props: `label`, `name` (reads error and warning from the surrounding `Form`), `description`, `hint`, `error`, `warning`, `required`, `optional`, `disabled`, `icon`, `help` (an info icon after the label with the text as tooltip, also linked to the control as a description). Slots: default, `label`, `label-actions`, `description`, `hint`.
|
|
167
|
+
| `FormField` | Label, description, hint, error and required marker around one control. It links ids and ARIA for the control inside. | Props: `label`, `name` (reads error and warning from the surrounding `Form`), `description`, `hint`, `error`, `warning`, `required`, `optional`, `disabled`, `icon`, `help` (an info icon after the label with the text as tooltip, also linked to the control as a description), `highlight` (scroll into view and a brief tint for deep links, with `useFieldHighlight`). Slots: default, `label`, `label-actions`, `description`, `hint`. | `core/form-field.vue` |
|
|
166
168
|
| `FieldMessage` | One error, warning or hint line outside a `FormField`. | Props: `message`, `tone` (danger, warning, neutral), `icon`. Slot: default. | `core/field-message.vue` |
|
|
167
169
|
| `FieldBoundary` | Cut the field context for controls inside a `FormField` that are not the main control (a search box above a `Tree`). | Prop: `auxiliary` (keeps own id, follows only `disabled`). Without it the context is fully cut. | `core/form-field.vue` |
|
|
168
170
|
| `Form` | Connects a `useForm` result to a `<form>`. Provides errors to `FormField`, handles submit, reset, focus on first error. | Props: `form` (required), `as` (form or div; use `div` for a form nested in a modal), `focusOnError`, `alerts` (start, end, false), `disabled` (every `FormField` and control inside is disabled; a nested form inherits it unless it sets its own, and a control with an explicit `:disabled="false"` stays enabled), `guard` (`false` keeps this form out of the leave guard; default: the `guard` option of `useForm`). While mounted it registers its dirty state in the nearest leave scope (`Modal`, `Drawer`, `FormDrawer`, `FormModal`, `SettingsModal`, else the page): leaving it dirty asks `confirm.discard()` first. Not while submitting or disabled. Slot: default, `alerts`. Events: `submitted`, `invalid`, `reset`. | `core/form.vue` |
|
|
@@ -180,7 +182,7 @@ All field components work inside `FormField` and take `invalid`, `disabled`, `re
|
|
|
180
182
|
| `CheckboxGroup` | Several choices as checkboxes from `options`. | Model: `T[]`. Props: `options` (`label`, `value`, `description`, `disabled`, `icon`), `legend`, `orientation`, `columns`, `variant` (default, filled), `name`. | `forms/checkbox-group.vue` |
|
|
181
183
|
| `Radio` | One radio option, used inside `RadioGroup`. | Props: `value`, `label`, `description`, `icon`. Slots: default, `description`. | `forms/radio-group.vue` |
|
|
182
184
|
| `RadioGroup` | One choice from a short list. Use `Select` for long lists, `SegmentedControl` for a compact toggle. | Model: value or null. Props: `options`, `legend`, `orientation`, `variant` (default, card), `name`. | `forms/radio-group.vue` |
|
|
183
|
-
| `SegmentedControl` | Compact toggle between 2 to 5 options (view mode, period). | Model: value (with `required` it is never null). Props: `options` (`label`, `value`, `icon`, `title`, `muted`), `iconOnly`, `block`, `label`. Slot: `option`.
|
|
185
|
+
| `SegmentedControl` | Compact toggle between 2 to 5 options (view mode, period). | Model: value (with `required` it is never null). Props: `options` (`label`, `value`, `icon`, `title`, `muted`, `dot`, `dotTone`, `dotLabel`: a status dot like Tabs items), `iconOnly`, `block`, `label`. Slot: `option`. | `forms/segmented-control.vue` |
|
|
184
186
|
| `Select` | Native styled select. Use `Combobox` when search or async options are needed. | Model: `T or null`. Props: `options` (items or groups with `label`, `value`, `disabled`), `placeholder`, `icon`. Option values can be string, number or boolean. | `forms/select.vue` |
|
|
185
187
|
| `Combobox` | Searchable select. Local filter, async `search`, `multiple` with tags, `creatable`. `:searchable="false"` makes it a plain select with dots and icons. | Models: `v-model`, `v-model:query`. Props: `options` (`label`, `value`, `description`, `icon`, `color` (dot and tag color), `group` (divider with the group name, also the tooltip of a selected tag), `keywords`), `search(query, signal)`, `filter`, `searchable` (default `true`; `false` is a button trigger without typing, with typeahead, and ignores `creatable`, `createActions` and `search`), `multiple`, `hideTags`, `creatable`, `createActions`, `createTransform`, `createValidate` (a returned string is the inline error), `debounce`, `minQueryLength`, `maxSelected`, `clearable`, `loading`, `placeholder`, `emptyText`. Slots: `option`, `empty`, `header` (top of the panel, for example quick filter pills). Events: `create`, `open`, `close`. | `forms/combobox.vue` |
|
|
186
188
|
| `TreeSelect` | Pick one node of a hierarchy (category, folder) with a drill-down panel, one level at a time. | Model: `TreeNodeId or null`. Props: `nodes` (`TreeNode`: `id`, `label`, `description`, `icon`, `disabled`, `children`), `leavesOnly` (parents only navigate), `separator` (path in the control and in search results, default `' / '`), `clearable`, `placeholder`, `searchPlaceholder`, `emptyText`, `icon`. Search lists every match with its path. Slots: `node` (`node`, `selected`, `path`), `empty`. Events: `open`, `close`. | `forms/tree-select.vue` |
|
|
@@ -199,6 +201,7 @@ All field components work inside `FormField` and take `invalid`, `disabled`, `re
|
|
|
199
201
|
| `PaletteSelect` | Select of a palette color, with the dot and the localized color name. | Model: `ColorValue` (palette name or `#rrggbb`) or null. A non-searchable `Combobox` (pass `:searchable="true"` to type a filter). Props: `colors` (subset of `PALETTE_COLORS`), `clearable` (placeholder "Automatic"), `custom` (adds "Custom": choosing it shows a `ColorInput` under the select and the model becomes the hex), `customLabel` (name of the color input), `placeholder`, `size`, `disabled`, `readonly`, `invalid`. | `forms/palette-select.vue` |
|
|
200
202
|
| `Slider` | Number in a range with drag handle. | Model: number. Props: `min`, `max`, `step`, `bubble` (true, always), `marks`, `format(value)`, `label`. Event: `change` (on release). | `forms/slider.vue` |
|
|
201
203
|
| `FileInput` | Drop zone and file picker. Validates type, size and count. Supports folders and previews. | Model: `File`, `File[]` or null. Props: `accept`, `acceptMode`, `maxSize`, `maxFiles`, `multiple`, `directory`, `directoryAction`, `previews`, `list`, `fill` (fills the height of its parent, centered), `loading`, `capture`, `title`, `dropText`, `hint`. Slots: `title`, `hint`, `actions`. Events: `add`, `remove`, `invalid`, `reject`. | `forms/file-input.vue` |
|
|
204
|
+
| `FileDropOverlay` | Overlay over a whole drop area while files are dragged over it (the `over` state of `useFileDrop`). | Props: `active` (bind `over`, default true), `icon`, `title`, `description`. Slots: default (rich title), `icon`, `description`. Covers its positioned container, ignores the pointer. Tokens: `--k-file-drop-overlay-inset`, `--k-file-drop-overlay-radius`. | `forms/file-input.vue` |
|
|
202
205
|
| `FocalPointInput` | Point on an image that must stay visible when it is cropped: click or drag on the image, or the arrow keys. | Model: `FocalPoint` (`{ x, y }` from 0 to 1) or null. Props: `src`, `alt`, `label`, `clearable` (a Reset button, Delete and Backspace clear), `clearLabel`, `horizontalLabel`, `verticalLabel`, `emptyText`, `step` (0.01, Shift times 10), `invalid`, `disabled`, `readonly`. | `forms/focal-point-input.vue` |
|
|
203
206
|
|
|
204
207
|
## Overlays
|
|
@@ -218,7 +221,7 @@ Mount `OverlayHost` once for the imperative hooks (see [Composables](#composable
|
|
|
218
221
|
| `Popover` | Floating panel with any content (a form, filters) opened by its trigger, or next to any element or point with `anchor`. Use `DropdownMenu` for a list of actions. | Model: `v-model:open`. Props: `placement`, `offset`, `arrow`, `label`, `initialFocus`, `width` (any CSS length, capped at the viewport), `anchor` (an element, also inside a same origin iframe, or a virtual `{ getBoundingClientRect() }`; positions against it instead of the trigger, the trigger slot becomes optional). `sheet` (a bottom sheet `Modal` with the same content when the viewport is 640px wide or less). Slots: default (the trigger), `content`. Exposed: `show`, `hide`, `toggle`. | `overlays/popover.vue` |
|
|
219
222
|
| `HoverCard` | Rich preview on hover or focus (user card, link preview). Use `Tooltip` for plain text. | Model: `v-model:open`. Props: `placement`, `openDelay`, `closeDelay`, `arrow`, `disabled`. Slots: default (trigger), `content`. | `overlays/hover-card.vue` |
|
|
220
223
|
| `Tooltip` | Short text on hover or focus. Optional shortcut. `Button` already shows one for icon-only buttons, `tooltip` and `disabledReason`. | Props: `text`, `placement`, `openDelay`, `closeDelay`, `arrow`, `shortcut`, `disabled`. Slots: default (trigger), `content`. | `overlays/tooltip.vue` |
|
|
221
|
-
| `CommandPalette` | Search and command dialog (Cmd+K) with groups, recent items, async search and typed item data. Groups take `icon` (default item icon) and `more` (a last "show all" item). Matching (`matchesSearch`, exported) finds every word in any order, without case or accents. | Models: `v-model:open`, `v-model:query`. Props: `groups` (items with `id`, `label`, `description`, `icon`, `badge`, `shortcut`, `keywords`, `to`, `data`, `disabled`, `disabledReason` (with `disabled`: reachable with the arrow keys but not selectable, a tooltip on hover and keyboard focus, linked with `aria-describedby`), `onSelect`), `search(query, signal)`, `pinned` (items or `(query) => items` shown first, never filtered or saved as recent), `shortcut`, `trigger`, `recentKey`, `emptyText`, `notice`. Slots: `item`, `empty`, `group-label`, `after-results`. Events: `select`, `open`, `close`.
|
|
224
|
+
| `CommandPalette` | Search and command dialog (Cmd+K) with groups, recent items, async search and typed item data. Groups take `icon` (default item icon) and `more` (a last "show all" item). Matching (`matchesSearch`, exported) finds every word in any order, without case or accents. | Models: `v-model:open`, `v-model:query`. Props: `groups` (items with `id`, `label`, `description`, `meta` (inline secondary label), `highlight` (`{ label, description }` ranges `[start, end]` marked with `k-mark`), `icon`, `badge`, `shortcut`, `keywords`, `to`, `data`, `disabled`, `disabledReason` (with `disabled`: reachable with the arrow keys but not selectable, a tooltip on hover and keyboard focus, linked with `aria-describedby`), `onSelect`), `search(query, signal)`, `pinned` (items or `(query) => items` shown first, never filtered or saved as recent), `shortcut`, `trigger`, `recentKey`, `emptyText`, `notice`. Slots: `item`, `empty`, `group-label`, `after-results`. Events: `select`, `open`, `close`. | `overlays/command-palette.vue` |
|
|
222
225
|
| `CommandList` | The search field and grouped list of `CommandPalette` without the dialog: place it inline in a panel or in a `Popover` (with `anchor` for a picker opened next to any element). Arrow keys, Enter and the same matching. | Model: `v-model:query`. Props: the `CommandPalette` list props (`groups`, `search`, `pinned`, `filter`, `loading`, `placeholder`, `label`, `recentKey`, `emptyText`, `notice` and the copy props), `autofocus` (default `true`), `footer` (the key hints, default `false`). Slots: `item`, `empty`, `group-label`, `after-results`. Events: `select`, `close` (Escape). Exposed: `focus`, `refresh`. | `overlays/command-palette.vue` |
|
|
223
226
|
| `CommandButton` | A `Button` made from a `CommandItem`: label, icon, `to`, `href`, `disabled`, `disabledReason` (tooltip on the disabled button) and `onSelect` come from the command. | Props: `command`, `label`, `icon`, `iconOnly` (a square button with the icon only, the label as `aria-label` and tooltip), and every `Button` prop (size, variant, tone). | `overlays/command-palette.vue` |
|
|
224
227
|
|
|
@@ -226,10 +229,10 @@ Mount `OverlayHost` once for the imperative hooks (see [Composables](#composable
|
|
|
226
229
|
|
|
227
230
|
| Component | Purpose and when to use it | Main props, models, slots, events | Playground |
|
|
228
231
|
| ----------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | --------------------------- |
|
|
229
|
-
| `Table` | Small to medium table with sort, selection, links and loading rows. For thousands of rows or editing use `DataGrid`. | Models: `v-model:sort` (`{ key, direction }`), `v-model:selected` (row keys). Props: `rows`, `columns` (`key`, `label`, `align`, `width`, `numeric`, `sortable`, `value`, `format`), `rowKey`, `selectable`, `rowTo`, `loading`, `emptyText`, `density`, `stickyHeader`, `maxHeight`, `bordered`, `caption`, `rowAttrs(row, index)` (attributes and listeners on each row), `rowDraggable` with `dragData(row, rows)` and `dragEffect` (rows dragged onto external drop targets). Slots: `cell-<key>`, `header-<key>`, `empty`. Events: `rowClick`, `rowDragStart`, `rowDragEnd`.
|
|
232
|
+
| `Table` | Small to medium table with sort, selection, links and loading rows. For thousands of rows or editing use `DataGrid`. | Models: `v-model:sort` (`{ key, direction }`), `v-model:selected` (row keys). Props: `rows`, `columns` (`key`, `label`, `align`, `width`, `numeric`, `sortable`, `value`, `format`), `rowKey`, `selectable`, `rowTo`, `loading`, `emptyText`, `density`, `stickyHeader`, `maxHeight`, `fill` (takes the rest of a fill `Card` body: rows scroll under the sticky header, the empty row centered), `bordered`, `caption`, `rowAttrs(row, index)` (attributes and listeners on each row), `rowDraggable` with `dragData(row, rows)` and `dragEffect` (rows dragged onto external drop targets). Slots: `cell-<key>`, `header-<key>`, `empty`. Events: `rowClick`, `rowDragStart`, `rowDragEnd`. | `data/table.vue` |
|
|
230
233
|
| `Pagination` | Page buttons, page size select and summary. Client or server paging. | Models: `v-model:page`, `v-model:pageSize`. Props: `total`, `pageSizes` (numbers, `'all'` for every row), `allLabel`, `showEdges`, `showJump`, `compact`, `loading`, `showSummary`. Slot: `summary`. | `data/pagination.vue` |
|
|
231
234
|
| `SelectionBar` | Shows the selected count and bulk actions for a list or table. | Props: `count`, `total`, `placement` (inline, sticky, floating), `onSelectAll` (may return a promise: spinner), `onClear`. With everything selected, select all becomes "Clear selection". Slots: `actions`, `count`. With `count` 0 it renders nothing visible. | `data/selection-bar.vue` |
|
|
232
|
-
| `FilterPills` | Quick filters as pills: single, multiple, menu or panel pills, removable active filters. | Model: value, array (`multiple`) or null. Props: `options` (`value`, `label`, `valueLabel`, `count`, `icon`, `color`, `menu`, `panel`, `removable`), `multiple`, `required`, `clearable`, `size`. Slots: `pill`, `panel-<value>`. Events: `select`, `remove`.
|
|
235
|
+
| `FilterPills` | Quick filters as pills: single, multiple, menu or panel pills, removable active filters. | Model: value, array (`multiple`) or null. Props: `options` (`value`, `label`, `valueLabel`, `count`, `icon`, `color`, `menu`, `panel`, `panelWidth` (width of the panel popover), `removable`), `multiple`, `required`, `clearable`, `size`. Slots: `pill`, `panel-<value>`. Events: `select`, `remove`. | `data/filter-pills.vue` |
|
|
233
236
|
| `FilterPill` | One pill button. Use it alone for a custom filter trigger. `FilterPills` uses it. | Props: `label`, `valueLabel`, `icon`, `count`, `active`, `pressed`, `caret`, `size`, `disabled`. Slot: default. | `data/filter-pills.vue` |
|
|
234
237
|
| `Tag` | Chip or label, optionally removable. Use `Badge` for a status. | Props: `label`, `tone`, `color` (palette name or hex), `size`, `icon`, `removable`, `removeLabel`, `removeTabindex`, `disabled`. Slot: default. Event: `remove`. | `data/tag.vue` |
|
|
235
238
|
| `TagList` | A list of `Tag` chips, reorderable by drag, by keyboard (Alt with an arrow key) or move buttons, removable, and a drop target for items dragged from another panel (columns of an export). | Model: `v-model` (`TagListItem[]`: `value`, `label`, `tone`, `icon`, `removable`, `disabled`). Props: `label`, `sortable`, `removable`, `moveButtons`, `accept` (MIME types or a function), `dropEffect`, `tone`, `size`, `disabled`, `emptyText`, `removeLabel`. Slots: `item`, `empty`. Events: `remove`, `move`, `itemDrop` (`{ index, dataTransfer, event }`). | `data/tag-list.vue` |
|
|
@@ -237,7 +240,7 @@ Mount `OverlayHost` once for the imperative hooks (see [Composables](#composable
|
|
|
237
240
|
| `Badge` | Status label, counter or dot. Not interactive. | Props: `label` (string or number), `tone`, `color` (palette name or hex), `variant` (soft, solid, outline), `size`, `dot`, `pulse`, `icon`. Slot: default. | `data/badge.vue` |
|
|
238
241
|
| `Avatar` | User picture with initials fallback and status dot. | Props: `src`, `name`, `alt`, `size` (xs to xl), `shape` (circle, square), `status` (online, away, busy, offline), `decorative`. Slot: `fallback`. | `data/avatar.vue` |
|
|
239
242
|
| `AvatarGroup` | Overlapping stack of avatars with "+N". | Props: `items` (`src`, `name`, `alt`), `max`, `size`, `shape`, `moreLabel`. | `data/avatar.vue` |
|
|
240
|
-
| `Thumbnail` | Preview box for an image, the first frame of a video or a file icon, with loading and missing states. Fixed sizes for inline use or fluid with an aspect ratio. | Props: `src`, `alt`, `kind` (image, video, file, icon), `icon` (fallback icon), `fit` (cover, contain), `aspect` (`'4/3'`, `'16/9'` or a number, default 1), `size` (xs to lg, fluid when unset), `rounded` (none, sm, md, lg, full), `missing`, `missingText`, `focal` (`{ x, y }` from 0 to 1), `objectPosition`, `caption`, `reveal` (overlays shown only on hover and focus, default `['caption']`), `lazy`. Slots: default (replaces the media), `top-start`, `top-end`, `caption`.
|
|
243
|
+
| `Thumbnail` | Preview box for an image, the first frame of a video or a file icon, with loading and missing states. Fixed sizes for inline use or fluid with an aspect ratio. | Props: `src`, `alt`, `kind` (image, video, file, icon), `icon` (fallback icon), `fit` (cover, contain), `aspect` (`'4/3'`, `'16/9'` or a number, default 1), `size` (xs to lg, fluid when unset), `rounded` (none, sm, md, lg, full), `missing`, `missingText`, `focal` (`{ x, y }` from 0 to 1), `objectPosition`, `caption`, `reveal` (overlays shown only on hover and focus of the thumbnail, or of the link, button, label, TileGrid tile, interactive Card or `k-thumbnail-anchor` element around it, default `['caption']`), `lazy`. Slots: default (replaces the media), `top-start`, `top-end`, `caption`. | `data/thumbnail.vue` |
|
|
241
244
|
| `TileGrid` | Responsive grid of tiles (cards, thumbnails) with roving arrow key focus across rows, an optional multi selection (check overlay, Shift ranges, Space, Ctrl or Cmd with A), reorder by drag or Alt with the arrow keys, native drag to external drop targets and a trailing add tile. | Models: `v-model:items` (order), `v-model:selected` (keys). Props: `itemKey`, `itemLabel`, `label`, `minItemWidth`, `columns`, `gap`, `selectable`, `sortable`, `handle`, `dragData(item, items)`, `dragEffect`, `disabled`. Slots: `tile` (`{ item, index, selected, dragging }`), `add`. Events: `activate`, `move`, `itemDragStart`, `itemDragEnd`. | `data/tile-grid.vue` |
|
|
242
245
|
| `Stat` | Key figure (KPI) with unit, delta, trend, hint and optional sparkline. Can be a link. | Props: `label`, `value`, `unit`, `delta`, `trend` (up, down, flat), `invert` (down is good), `hint`, `icon`, `loading`, `to`, `href`, `plain`. Slots: `label`, `value`, `icon`, `sparkline`, `footer`. | `data/stat.vue` |
|
|
243
246
|
| `RecordList` | Short list of records (settings, users, tokens): title, badge, description, leading and action slots, `SkeletonList` while `loading`, empty state. | Props: `items` (`RecordListItem`: `id`, `title` (truncated, full text on hover), `description`, `badge` `{ label, tone }`, `icon`, `meta` (trailing text), `to`, `href`, `target` (a link row: the title link covers the row, Cmd click and middle click open a new tab)), `loading`, `avatar`, `action`, `label`, `skeletonRows`, `emptyText`, `emptyDescription`, `emptyIcon`, `emptyVariant` (card, the default, plain, or hint: the empty text as one muted line). Event: `row-click` (`item`, `event`): each row becomes a navigation item (padding, hover and press background like a ghost button, no separators) and its title a button, so Tab reaches every row and Enter or Space opens it (focus ring on the row, the description is the button description). Clicks on buttons, links, inputs, menu items and inside an open menu, popover or dialog of the row are ignored, and pressing them does not tint the row; `rowClickable(item)` keeps some rows static in the same list (no button, no hover). Slots: `leading` (default: the `icon`), `meta`, `action` (`{ item }`), `empty`, `empty-actions` (buttons in the default empty state). | `data/record-list.vue` |
|
|
@@ -247,40 +250,40 @@ Mount `OverlayHost` once for the imperative hooks (see [Composables](#composable
|
|
|
247
250
|
|
|
248
251
|
## Layout
|
|
249
252
|
|
|
250
|
-
| Component | Purpose and when to use it | Main props, models, slots, events
|
|
251
|
-
| ---------------- | --------------------------------------------------------------------------------------------------------------------------------- |
|
|
252
|
-
| `Card` | Container with optional title, description, icon, actions and footer. Can be a link or a selectable button. | Props: `title`, `description`, `icon`, `variant` (raised, outline, subtle, dashed: a centered add or empty tile), `padding`, `as`, `to`, `href`, `selected`, `disabled`, `animated
|
|
253
|
-
| `PageHeader` | Page title with description, breadcrumbs, badge and actions. The page templates include it. | Props: `title`, `description`, `icon`, `breadcrumbs` (small trail above the title), `trail` (the earlier levels as links: the title becomes a breadcrumb trail whose last item is the heading), `trailLabel`, `level`, `bordered`, `align`, `truncate
|
|
254
|
-
| `Breadcrumbs` | Path navigation. | Props: `items` (`label`, `to`, `href`, `icon`), `separator`, `linkLast`, `ancestors`, `size` (`sm` for panel headers, `md`, `lg` for a title sized trail), `heading` (the current item is a heading of that level). Slot: `item`.
|
|
255
|
-
| `Stepper` | Step indicator for wizards and multi step flows (import, checkout). Horizontal or vertical, compact on narrow widths. | Model: `v-model` (current step value). Props: `steps` (`value`, `label`, `description`, `icon`, `disabled`, `state`: `complete` or `error`), `label`, `orientation`, `size`, `linear` (only completed and current steps clickable), `readonly`, `compact` (`'auto'` by default, `true`, `false`), `summary` (false hides the compact "Step 2 of 4" line), `positionLabel`, `completeLabel`, `errorLabel`. Event: `select`.
|
|
256
|
-
| `Tabs` | Tabs with panels, badges and dots. Segmented or underline. | Model: `v-model` (active value). Props: `items` (`value`, `label`, `icon`, `color` (a palette name or hex, a dot before the label), `badge`, `badgeTone`, `dot`, `title` (a tooltip on hover and focus, also on a disabled tab; native `title` until mount), `disabled`), `variant`, `size`, `lazy`, `fill`, `stretch`, `inset`, `controls` (id of a panel outside the component: only the tab list renders). Slots: `panel-<value>`, `panel`.
|
|
257
|
-
| `Accordion` | Collapsible sections. | Model: `v-model` (open value or values). Props: `items` (`value`, `title`, `description`, `content`, `icon`), `multiple`, `collapsible`, `variant`, `contentVariant` (text, or neutral: inherited font and color for forms, same padding), `padded` (default `true`; `false` for flush content). Slots: default, `title`.
|
|
258
|
-
| `ResizeHandle` | Draggable and keyboard resizable separator between a panel and the rest (a side pane, a split editor). | Model: `v-model` (size in px). Props: `orientation` (`vertical`, `horizontal`), `target` (`before`, `after`: where the resized panel is), `min`, `max`, `step` (arrow keys, default 16), `label`, `onReset` (double click). Events: `resizeStart`, `resizeEnd`.
|
|
259
|
-
| `Separator` | Divider, labelled divider, or section heading with description and actions. | Props: `orientation`, `variant` (label, heading), `label`, `description`, `align`, `level`, `lines` (default `true`; `false` hides the lines of either variant). Slots: default, `description`, `actions`.
|
|
260
|
-
| `Stack` | Flex row or column with gap. | Props: `direction`, `gap` (none to xl), `align`, `justify`, `wrap`, `responsive`, `as`.
|
|
261
|
-
| `Grid` | Responsive CSS grid. | Props: `columns` (number or breakpoints), `minItemWidth` (auto fit), `gap`, `as`.
|
|
262
|
-
| `Toolbar` | Group of controls with arrow key navigation (ARIA toolbar). | Props: `label`, `orientation`, `roving`, `bordered`.
|
|
263
|
-
| `CopyButton` | Button that copies a value and shows "copied". | Props: `value`, `label`, `copiedLabel`, `showLabel`, `size`, `variant`, `tone`, `resetAfter`. Event: `copy(success)`.
|
|
264
|
-
| `ThemeSwitch` | Light, dark and system switch. | Props: `variant` (segmented, icon), `size`, `showLabels`.
|
|
265
|
-
| `NavLink` | One navigation link with icon, badge and active state. | Props: `label`, `to`, `href`, `icon`, `badge`, `active`, `match` (exact, prefix), `external`, `disabled`. Slots: default, `icon`.
|
|
266
|
-
| `AppShell` | App frame: sidebar, topbar, mobile menu, collapse, skip link. Use it for a custom frame. Use `DashboardLayout` for the ready one. | Models: `v-model:collapsed`, `v-model:open`. Props: `variant` (inset, sidebar, floating), `content` (`page`, `fill`, `centered`, `bleed`), `fluid`, `fill`, `topbar`, `storageKey` (collapsed state in the preferences store), `shortcut`, `loading` (hides the page content and shows a page skeleton, `aria-busy` on `main`), `loadingLabel`. Slots: default, `sidebar`, `topbar`, `overlays`, `loading` (replaces the default page skeleton).
|
|
267
|
-
| `Sidebar` | Sidebar content with header, collapse button and footer. Goes in the `sidebar` slot of `AppShell`. | Props: `label`, `collapsible`, `collapseLabel`, `brandAlign` (`start`, `center`). Icons `sidebar-collapse` and `sidebar-expand` for the collapse button. Slots: default, `header`, `top`, `footer`.
|
|
268
|
-
| `SidebarNav` | Navigation list from data, with groups and children. | Props: `items` (`NavItem[]` or `NavSection[]`: `label`, `to`, `icon`, `badge`, `children`), `currentPath`.
|
|
269
|
-
| `SidebarSection` | Labelled block inside a sidebar for hand written links. | Prop: `label`. Slot: default.
|
|
253
|
+
| Component | Purpose and when to use it | Main props, models, slots, events | Playground |
|
|
254
|
+
| ---------------- | --------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------- |
|
|
255
|
+
| `Card` | Container with optional title, description, icon, actions and footer. Can be a link or a selectable button. | Props: `title`, `description`, `icon`, `variant` (raised, outline, subtle, dashed: a centered add or empty tile), `padding`, `as`, `to`, `href`, `selected`, `disabled`, `disabledReason` (with `disabled` on a button or link card: it stays focusable with `aria-disabled`, ignores clicks and shows the reason in a tooltip and as its description), `animated`, `fill` (takes the rest of the parent height, the body is a scrolling flex column, the footer pinned at the bottom). Slots: default, `header`, `title`, `description`, `icon`, `actions`, `footer`. | `layout/card.vue` |
|
|
256
|
+
| `PageHeader` | Page title with description, breadcrumbs, badge and actions. The page templates include it. | Props: `title`, `description`, `icon`, `breadcrumbs` (small trail above the title), `trail` (the earlier levels as links: the title becomes a breadcrumb trail whose last item is the heading), `trailLabel`, `level`, `bordered`, `align`, `truncate` (one line; with a `trail` the title keeps a minimum width and the earlier crumbs truncate), `size` (`md`, `sm` for a panel or inspector header). Slots: `actions`, `badge`, `description`, `title`, `icon`, `breadcrumbs`. | `layout/page-header.vue` |
|
|
257
|
+
| `Breadcrumbs` | Path navigation. | Props: `items` (`label`, `to`, `href`, `icon`), `separator`, `linkLast`, `ancestors`, `size` (`sm` for panel headers, `md`, `lg` for a title sized trail), `heading` (the current item is a heading of that level). Slot: `item`. | `layout/breadcrumbs.vue` |
|
|
258
|
+
| `Stepper` | Step indicator for wizards and multi step flows (import, checkout). Horizontal or vertical, compact on narrow widths. | Model: `v-model` (current step value). Props: `steps` (`value`, `label`, `description`, `icon`, `disabled`, `state`: `complete` or `error`), `label`, `orientation`, `size`, `linear` (only completed and current steps clickable), `readonly`, `compact` (`'auto'` by default, `true`, `false`), `summary` (false hides the compact "Step 2 of 4" line), `positionLabel`, `completeLabel`, `errorLabel`. Event: `select`. | `layout/stepper.vue` |
|
|
259
|
+
| `Tabs` | Tabs with panels, badges and dots. Segmented or underline. | Model: `v-model` (active value). Props: `items` (`value`, `label`, `icon`, `color` (a palette name or hex, a dot before the label), `badge`, `badgeTone`, `dot`, `title` (a tooltip on hover and focus, also on a disabled tab; native `title` until mount), `disabled`), `variant`, `size`, `lazy`, `fill`, `stretch`, `inset`, `controls` (id of a panel outside the component: only the tab list renders). Slots: `panel-<value>`, `panel`. | `layout/tabs.vue` |
|
|
260
|
+
| `Accordion` | Collapsible sections. | Model: `v-model` (open value or values). Props: `items` (`value`, `title`, `description`, `content`, `icon`), `multiple`, `collapsible`, `variant`, `contentVariant` (text, or neutral: inherited font and color for forms, same padding), `padded` (default `true`; `false` for flush content), `divided` (a line between the trigger and the open content). Slots: default, `title`. | `layout/accordion.vue` |
|
|
261
|
+
| `ResizeHandle` | Draggable and keyboard resizable separator between a panel and the rest (a side pane, a split editor). | Model: `v-model` (size in px). Props: `orientation` (`vertical`, `horizontal`), `target` (`before`, `after`: where the resized panel is), `min`, `max`, `step` (arrow keys, default 16), `label`, `onReset` (double click). Events: `resizeStart`, `resizeEnd`. | `layout/resize-handle.vue` |
|
|
262
|
+
| `Separator` | Divider, labelled divider, or section heading with description and actions. | Props: `orientation`, `variant` (label, heading), `label`, `description`, `align`, `level`, `lines` (default `true`; `false` hides the lines of either variant). Slots: default, `description`, `actions`. | `layout/separator.vue` |
|
|
263
|
+
| `Stack` | Flex row or column with gap. | Props: `direction`, `gap` (none to xl), `align`, `justify`, `wrap`, `responsive`, `grow` (flex 1 with `min-height: 0`, passes a height down to a fill card), `as`. | `layout/stack.vue` |
|
|
264
|
+
| `Grid` | Responsive CSS grid. | Props: `columns` (number or breakpoints), `minItemWidth` (auto fit), `gap`, `as`. | `layout/grid.vue` |
|
|
265
|
+
| `Toolbar` | Group of controls with arrow key navigation (ARIA toolbar). | Props: `label`, `orientation`, `roving`, `bordered`. | `layout/toolbar.vue` |
|
|
266
|
+
| `CopyButton` | Button that copies a value and shows "copied". | Props: `value`, `label`, `copiedLabel`, `showLabel`, `size`, `variant`, `tone`, `resetAfter`. Event: `copy(success)`. | `layout/copy-button.vue` |
|
|
267
|
+
| `ThemeSwitch` | Light, dark and system switch. | Props: `variant` (segmented, icon), `size`, `showLabels`. | `layout/theme-switch.vue` |
|
|
268
|
+
| `NavLink` | One navigation link with icon, badge and active state. | Props: `label`, `to`, `href`, `icon`, `badge`, `active`, `match` (exact, prefix), `external`, `disabled`. Slots: default, `icon`. | `layout/nav-link.vue` |
|
|
269
|
+
| `AppShell` | App frame: sidebar, topbar, mobile menu, collapse, skip link. Use it for a custom frame. Use `DashboardLayout` for the ready one. | Models: `v-model:collapsed`, `v-model:open`. Props: `variant` (inset, sidebar, floating), `content` (`page`, `fill`, `centered`, `bleed`), `fluid`, `fill`, `topbar`, `storageKey` (collapsed state in the preferences store), `shortcut`, `loading` (hides the page content and shows a page skeleton, `aria-busy` on `main`), `loadingLabel`. Slots: default, `sidebar`, `topbar`, `overlays`, `loading` (replaces the default page skeleton). | `layout/app-shell.vue` |
|
|
270
|
+
| `Sidebar` | Sidebar content with header, collapse button and footer. Goes in the `sidebar` slot of `AppShell`. | Props: `label`, `collapsible`, `collapseLabel`, `brandAlign` (`start`, `center`). Icons `sidebar-collapse` and `sidebar-expand` for the collapse button. Slots: default, `header`, `top`, `footer`. | `layout/app-shell.vue` |
|
|
271
|
+
| `SidebarNav` | Navigation list from data, with groups and children. | Props: `items` (`NavItem[]` or `NavSection[]`: `label`, `to`, `icon`, `badge`, `children`), `currentPath`. | `layout/app-shell.vue` |
|
|
272
|
+
| `SidebarSection` | Labelled block inside a sidebar for hand written links. | Prop: `label`. Slot: default. | `layout/app-shell.vue` |
|
|
270
273
|
|
|
271
274
|
## Feedback
|
|
272
275
|
|
|
273
|
-
| Component | Purpose and when to use it | Main props, models, slots, events
|
|
274
|
-
| ---------------- | -------------------------------------------------------------------------------------------------- |
|
|
275
|
-
| `Alert` | Inline message with tone, title, description and actions. Use `toast` for short lived messages. | Model: `v-model:open`. Props: `tone`, `variant`, `title`, `description
|
|
276
|
-
| `EmptyState` | "Nothing here" block with icon, text and actions. For a full first run screen use `EmptyPage`. | Props: `title`, `description`, `icon`, `size`, `variant` (card, plain), `fill`. Slots: default, `title`, `description`, `icon`, `actions`.
|
|
277
|
-
| `Skeleton` | Placeholder shape while content loads. | Props: `shape`, `width`, `height`, `lines`, `lastLineWidth`, `radius`, `animation`.
|
|
278
|
-
| `SkeletonForm` | Rough placeholder of a form: a label and a control for each field. | Props: `fields` (4), `columns` (1, one column on narrow screens), `label`, `animation`.
|
|
279
|
-
| `SkeletonList` | Rough placeholder of a list: one or two text lines per row, optional avatar and action. | Props: `rows` (4), `lines` (1 or 2), `avatar`, `action`, `label`, `animation`.
|
|
280
|
-
| `LoadingOverlay` | Cover its content with a spinner while `loading`. | Props: `loading`, `label`, `showLabel`, `blur`, `spinnerSize`. Slot: default.
|
|
281
|
-
| `Progress` | Linear progress, determinate or indeterminate (`value` null). | Props: `value`, `max`, `label`, `showLabel`, `showValue`, `valueText`, `tone`, `size`. Slot: `label`.
|
|
282
|
-
| `ProgressRing` | Circular progress with optional center content. | Props: `value`, `max`, `label`, `size`, `thickness`, `showValue`, `tone`. Slot: default.
|
|
283
|
-
| `Meter` | A value inside a known range with low, high and optimum zones (quota, score). Not a task progress. | Props: `value`, `min`, `max`, `low`, `high`, `optimum`, `label`, `hideLabel`, `showValue`, `valueText`, `size`.
|
|
276
|
+
| Component | Purpose and when to use it | Main props, models, slots, events | Playground |
|
|
277
|
+
| ---------------- | -------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------ |
|
|
278
|
+
| `Alert` | Inline message with tone, title, description and actions. Use `toast` for short lived messages. | Model: `v-model:open`. Props: `tone`, `variant`, `title`, `description` (a string, or an array rendered as a list), `icon` (or false), `dismissible`, `role`. Slots: default, `title`, `icon`, `actions`. Event: `dismiss`. | `feedback/alert.vue` |
|
|
279
|
+
| `EmptyState` | "Nothing here" block with icon, text and actions. For a full first run screen use `EmptyPage`. | Props: `title`, `description`, `icon`, `size`, `variant` (card, plain), `fill`. Slots: default, `title`, `description`, `icon`, `actions`. | `feedback/empty-state.vue` |
|
|
280
|
+
| `Skeleton` | Placeholder shape while content loads. | Props: `shape`, `width`, `height`, `lines`, `lastLineWidth`, `radius`, `animation`. | `feedback/skeleton.vue` |
|
|
281
|
+
| `SkeletonForm` | Rough placeholder of a form: a label and a control for each field. | Props: `fields` (4), `columns` (1, one column on narrow screens), `label`, `animation`. | `feedback/skeleton.vue` |
|
|
282
|
+
| `SkeletonList` | Rough placeholder of a list: one or two text lines per row, optional avatar and action. | Props: `rows` (4), `lines` (1 or 2), `avatar`, `action`, `label`, `animation`. | `feedback/skeleton.vue` |
|
|
283
|
+
| `LoadingOverlay` | Cover its content with a spinner while `loading`. | Props: `loading`, `label`, `showLabel`, `blur`, `spinnerSize`. Slot: default. | `feedback/loading-overlay.vue` |
|
|
284
|
+
| `Progress` | Linear progress, determinate or indeterminate (`value` null). | Props: `value`, `max`, `label`, `showLabel`, `showValue`, `valueText`, `tone`, `size`. Slot: `label`. | `feedback/progress.vue` |
|
|
285
|
+
| `ProgressRing` | Circular progress with optional center content. | Props: `value`, `max`, `label`, `size`, `thickness`, `showValue`, `tone`. Slot: default. | `feedback/progress.vue` |
|
|
286
|
+
| `Meter` | A value inside a known range with low, high and optimum zones (quota, score). Not a task progress. | Props: `value`, `min`, `max`, `low`, `high`, `optimum`, `label`, `hideLabel`, `showValue`, `valueText`, `size`. | `feedback/meter.vue` |
|
|
284
287
|
|
|
285
288
|
## Templates
|
|
286
289
|
|
|
@@ -289,7 +292,7 @@ Templates combine core parts into whole pages and layouts. Start from them for n
|
|
|
289
292
|
| Component | Purpose and when to use it | Main props, models, slots, events | Playground |
|
|
290
293
|
| -------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------- |
|
|
291
294
|
| `DashboardLayout` | Ready app frame: brand, navigation, command search, account menu, settings modal, breadcrumbs, theme switch. Put it in `layouts/default.vue`. | Models: `v-model:collapsed`, `v-model:open`, `v-model:settingsOpen`, `v-model:settingsSection`. Props: `navigation` (`NavItem[]` or `NavSection[]`), `account` (`name`, `email`, `avatar`, `role`, `menu`), `brandName`, `brandIcon`, `brandLogo`, `breadcrumbs`, `search` (true, groups or function), `settingsSections`, `settingsRoute`, `settingsRouteLocation`, `settingsAccountSection`, `settingsResolvePage`, `settingsHideSession`, `variant`, `content` (`page`, `fill`, `centered`, `bleed`; per page with `definePageMeta({ content })` in `k-dashboard`), `fluid`, `fill`, `loading` (page skeleton while a navigation is pending: bind `useNavigationPending()` in Nuxt), `loadingLabel`, `onSignOut`. Slots: default, `loading`, `actions`, `brand`, `sidebar-top`, `sidebar`, `sidebar-footer`, `account`, `topbar`, `search-item`, `settings-account-start`, `settings-account-fields`, `settings-section-<id>`, `settings-actions-<id>`, `settings-tabs-<id>`, `settings-nav-footer`. Event: `accountSelect`. | `templates/dashboard-layout.vue` |
|
|
292
|
-
| `WorkspaceLayout` | Full height editor workspace: top bar (`start`, `center`, `end`) and up to three panes, the side panes resizable, collapsible and persisted, tabs under a container breakpoint. | Models: `v-model:pane` (active tab in compact mode), `v-model:left-collapsed`, `v-model:right-collapsed`, `v-model:left-width`, `v-model:right-width`. Props: `left`, `right` (`label`, `min`, `max`, `initial`, tab `badge`, `badgeTone`, `badgeLabel`, `dot`, `icon`), `main` (`label`, badge), `storageKey`, `breakpoint` (1024), `step`, `panesLabel`, `resizeLabel`. Slots: `start`, `center`, `end`, `left`, `left-header`, `main`, `main-header`, `right`, `right-header` (scope `{ compact, pane, collapsed, toggle, reveal }`). Exposed: `toggle`, `reveal`, `compact`.
|
|
295
|
+
| `WorkspaceLayout` | Full height editor workspace: top bar (`start`, `center`, `end`) and up to three panes, the side panes resizable, collapsible and persisted, tabs under a container breakpoint. | Models: `v-model:pane` (active tab in compact mode), `v-model:left-collapsed`, `v-model:right-collapsed`, `v-model:left-width`, `v-model:right-width`. Props: `left`, `right` (`label`, `min`, `max`, `initial`, tab `badge`, `badgeTone`, `badgeLabel`, `dot`, `icon`), `main` (`label`, badge), `storageKey`, `breakpoint` (1024), `step`, `panesLabel`, `resizeLabel`. Slots: `start`, `center`, `end`, `left`, `left-header`, `main`, `main-header`, `right`, `right-header` (scope `{ compact, pane, collapsed, toggle, reveal }`; a `PageHeader` in `start` or a pane header fills the row and shrinks, its actions stay on the title row). Exposed: `toggle`, `reveal`, `compact`. | `templates/workspace-layout.vue` |
|
|
293
296
|
| `AuthLayout` | Frame of sign in, sign up and reset password pages: left column with brand, title (or a large breadcrumb), form and footer; aside panel on the right from 960px. | Props: `title`, `description`, `breadcrumbs`, `footer`, `brandName`, `brandIcon`, `brandLogo`, `aside`, `asideTitle`, `asideDescription`, `themeSwitch`. Slots: default, `links`, `footer`, `brand`, `aside`, `corner`. | `templates/auth-layout.vue` |
|
|
294
297
|
| `AuthLogin` | Complete sign in page in two steps (email, then password with a breadcrumb back). Offers to sign in again after `AuthLogout`. | Props: `submit` (`{ email, password }`), `submitError`, `title`, `description`, `emailLabel`, `emailPlaceholder`, `passwordLabel`, `submitLabel`, `stepKey`, `reasonKey`, frame props of `AuthLayout`. Slots: `links` (`{ email, step }`), `footer`, `brand`, `aside`, `corner`. | `templates/auth-login.vue` |
|
|
295
298
|
| `AuthLogout` | Sign out page: runs `logout()`, remembers the account, reloads the sign in page. Retry on error. | Props: `logout`, `account` (`{ email, name }`), `loginTo`, `reasonKey`, frame props of `AuthLayout`. Slots: `footer`, `brand`, `aside`, `corner`. Helpers: `rememberSignedOutAccount`, `takeSignedOutAccount`, `SIGNED_OUT_REASON`. | `templates/auth-login.vue` |
|
|
@@ -362,6 +365,7 @@ All are exported from `@xleddyl/443-components-vue` (the Nuxt only ones from `@x
|
|
|
362
365
|
| ---------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------ |
|
|
363
366
|
| `useForm` | State of a form: values, errors, warnings, touched, dirty, submit, server errors. Use it for every form with more than one field. | `useForm({ schema, values, validator, warnings, validateOn, onSubmit, onInvalid, submitError, messages, translateMessage, guard })` (`guard: false` keeps the form out of the leave guard; `createFormConfig({ guard: false })` for every form). Schema fields: `initial`, `required`, `min`, `max`, `minLength`, `maxLength`, `pattern`, `validate`. `validator` takes any Standard Schema (Zod 4, Valibot, ArkType). Returns `values`, `errors`, `dirty`, `dirtyFields`, `valid`, `submitting`, `validate`, `validateSync`, `setError`, `setErrors`, `setIssues`, `reset(next?)`, `markClean()` (the current values become the saved state), `submit` (a successful `onSubmit` marks the form clean; throw to keep it dirty), `touch`, `isRequired`. Pass it to `Form`. | `core/form.vue` |
|
|
364
367
|
| `useField`, `useFieldControl` | Build your own field control that reads the surrounding `FormField` (id, invalid, described by). | `useFieldControl({ role: 'auxiliary' })` for a secondary control. `control.setControlError(message)` reports a control level error. | `core/form-field.vue` |
|
|
368
|
+
| `useFieldHighlight` | Flash a `FormField` from a deep link or a search result. | `const { highlighted, highlight } = useFieldHighlight()`, `highlight(name)`, then `:highlight="highlighted === name"` on the field; it clears after the flash (`duration`, default 2400ms). | `core/form-field.vue` |
|
|
365
369
|
| `provideFieldBoundary`, `provideAuxiliaryControls` | In your own overlay component, stop controls from inheriting the field context of the trigger. | Call in `setup`. | - |
|
|
366
370
|
| `toast` / `useToast` | Toasts. | `toast(title, opts)`, `toast.success`, `.error`, `.warning`, `.info`, `.loading`, `.promise(promise, { loading, success, error })`, `.update(id, opts)`, `.dismiss(id)`. Options: `description` (string or list), `action` (`label`, `onClick`), `duration`, `dismissible`. | `overlays/toast.vue` |
|
|
367
371
|
| `useConfirm` | Ask yes or no. Returns a promise of `true` or `false`. | `await useConfirm()({ title, description, tone, confirmLabel, cancelLabel, body })`. Presets: `confirm.delete(title, options?)` (danger, Delete) and `confirm.discard(options?)` (unsaved changes; one dialog at a time, and once per route navigation however many guards ask). | `overlays/hooks.vue` |
|