@nocopypaste/vue-grid 0.0.0-stage → 0.2.0
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/AGENTS.md +285 -0
- package/CHANGELOG.md +31 -0
- package/README.md +881 -2
- package/agent/api.json +2336 -0
- package/agent/api.md +632 -0
- package/agent/grid-config.schema.json +609 -0
- package/dist/agent/api.js +2301 -0
- package/dist/agent/api.js.map +1 -0
- package/dist/agent/index.js +8 -0
- package/dist/agent/index.js.map +1 -0
- package/dist/agent/requirements.js +57 -0
- package/dist/agent/requirements.js.map +1 -0
- package/dist/agent/validate.js +181 -0
- package/dist/agent/validate.js.map +1 -0
- package/dist/base.css +1 -0
- package/dist/components/VGrid.js +6 -0
- package/dist/components/VGrid.js.map +1 -0
- package/dist/components/VGrid.vue_vue_type_script_setup_true_lang.js +759 -0
- package/dist/components/VGrid.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridCell.js +6 -0
- package/dist/components/VGridCell.js.map +1 -0
- package/dist/components/VGridCell.vue_vue_type_script_setup_true_lang.js +167 -0
- package/dist/components/VGridCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridCheckbox.js +6 -0
- package/dist/components/VGridCheckbox.js.map +1 -0
- package/dist/components/VGridCheckbox.vue_vue_type_script_setup_true_lang.js +39 -0
- package/dist/components/VGridCheckbox.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridColumnMenu.js +6 -0
- package/dist/components/VGridColumnMenu.js.map +1 -0
- package/dist/components/VGridColumnMenu.vue_vue_type_script_setup_true_lang.js +100 -0
- package/dist/components/VGridColumnMenu.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridFilterInput.js +6 -0
- package/dist/components/VGridFilterInput.js.map +1 -0
- package/dist/components/VGridFilterInput.vue_vue_type_script_setup_true_lang.js +89 -0
- package/dist/components/VGridFilterInput.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridFilterPanel.js +6 -0
- package/dist/components/VGridFilterPanel.js.map +1 -0
- package/dist/components/VGridFilterPanel.vue_vue_type_script_setup_true_lang.js +248 -0
- package/dist/components/VGridFilterPanel.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridFilterPopover.js +6 -0
- package/dist/components/VGridFilterPopover.js.map +1 -0
- package/dist/components/VGridFilterPopover.vue_vue_type_script_setup_true_lang.js +79 -0
- package/dist/components/VGridFilterPopover.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridGroupRow.js +6 -0
- package/dist/components/VGridGroupRow.js.map +1 -0
- package/dist/components/VGridGroupRow.vue_vue_type_script_setup_true_lang.js +49 -0
- package/dist/components/VGridGroupRow.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridHeader.js +6 -0
- package/dist/components/VGridHeader.js.map +1 -0
- package/dist/components/VGridHeader.vue_vue_type_script_setup_true_lang.js +130 -0
- package/dist/components/VGridHeader.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridMenu.js +6 -0
- package/dist/components/VGridMenu.js.map +1 -0
- package/dist/components/VGridMenu.vue_vue_type_script_setup_true_lang.js +133 -0
- package/dist/components/VGridMenu.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridPagination.js +6 -0
- package/dist/components/VGridPagination.js.map +1 -0
- package/dist/components/VGridPagination.vue_vue_type_script_setup_true_lang.js +102 -0
- package/dist/components/VGridPagination.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridPinnedRows.js +6 -0
- package/dist/components/VGridPinnedRows.js.map +1 -0
- package/dist/components/VGridPinnedRows.vue_vue_type_script_setup_true_lang.js +75 -0
- package/dist/components/VGridPinnedRows.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridResizeHandle.js +6 -0
- package/dist/components/VGridResizeHandle.js.map +1 -0
- package/dist/components/VGridResizeHandle.vue_vue_type_script_setup_true_lang.js +34 -0
- package/dist/components/VGridResizeHandle.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridRows.js +6 -0
- package/dist/components/VGridRows.js.map +1 -0
- package/dist/components/VGridRows.vue_vue_type_script_setup_true_lang.js +178 -0
- package/dist/components/VGridRows.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridSearch.js +6 -0
- package/dist/components/VGridSearch.js.map +1 -0
- package/dist/components/VGridSearch.vue_vue_type_script_setup_true_lang.js +46 -0
- package/dist/components/VGridSearch.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/components/VGridTotalCell.js +6 -0
- package/dist/components/VGridTotalCell.js.map +1 -0
- package/dist/components/VGridTotalCell.vue_vue_type_script_setup_true_lang.js +74 -0
- package/dist/components/VGridTotalCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/composables/useColumnDrag.js +79 -0
- package/dist/composables/useColumnDrag.js.map +1 -0
- package/dist/composables/useColumnResize.js +68 -0
- package/dist/composables/useColumnResize.js.map +1 -0
- package/dist/composables/useDataSource.js +47 -0
- package/dist/composables/useDataSource.js.map +1 -0
- package/dist/composables/useGridFilters.js +125 -0
- package/dist/composables/useGridFilters.js.map +1 -0
- package/dist/composables/useGridKeyboard.js +111 -0
- package/dist/composables/useGridKeyboard.js.map +1 -0
- package/dist/composables/useGridMenus.js +214 -0
- package/dist/composables/useGridMenus.js.map +1 -0
- package/dist/composables/useGridSelection.js +75 -0
- package/dist/composables/useGridSelection.js.map +1 -0
- package/dist/composables/usePinnedOffsets.js +61 -0
- package/dist/composables/usePinnedOffsets.js.map +1 -0
- package/dist/composables/usePinnedRows.js +58 -0
- package/dist/composables/usePinnedRows.js.map +1 -0
- package/dist/composables/useScrollEdges.js +27 -0
- package/dist/composables/useScrollEdges.js.map +1 -0
- package/dist/composables/useSubRows.js +101 -0
- package/dist/composables/useSubRows.js.map +1 -0
- package/dist/composables/useTotals.js +30 -0
- package/dist/composables/useTotals.js.map +1 -0
- package/dist/composables/useVirtualRows.js +160 -0
- package/dist/composables/useVirtualRows.js.map +1 -0
- package/dist/core/aggregate.js +39 -0
- package/dist/core/aggregate.js.map +1 -0
- package/dist/core/columns.js +106 -0
- package/dist/core/columns.js.map +1 -0
- package/dist/core/filter.js +218 -0
- package/dist/core/filter.js.map +1 -0
- package/dist/core/helpers.js +7 -0
- package/dist/core/helpers.js.map +1 -0
- package/dist/core/pagination.js +25 -0
- package/dist/core/pagination.js.map +1 -0
- package/dist/core/patch.js +41 -0
- package/dist/core/patch.js.map +1 -0
- package/dist/core/selection.js +15 -0
- package/dist/core/selection.js.map +1 -0
- package/dist/core/sort.js +36 -0
- package/dist/core/sort.js.map +1 -0
- package/dist/core/storage.js +36 -0
- package/dist/core/storage.js.map +1 -0
- package/dist/core/value.js +19 -0
- package/dist/core/value.js.map +1 -0
- package/dist/core/virtual.js +83 -0
- package/dist/core/virtual.js.map +1 -0
- package/dist/core.css +1 -0
- package/dist/features/aggregation.js +11 -0
- package/dist/features/aggregation.js.map +1 -0
- package/dist/features/columnGroups.js +9 -0
- package/dist/features/columnGroups.js.map +1 -0
- package/dist/features/columnPinning.js +11 -0
- package/dist/features/columnPinning.js.map +1 -0
- package/dist/features/columnReorder.js +12 -0
- package/dist/features/columnReorder.js.map +1 -0
- package/dist/features/columnResizing.js +11 -0
- package/dist/features/columnResizing.js.map +1 -0
- package/dist/features/columnVisibility.js +9 -0
- package/dist/features/columnVisibility.js.map +1 -0
- package/dist/features/filtering.js +13 -0
- package/dist/features/filtering.js.map +1 -0
- package/dist/features/index.js +38 -0
- package/dist/features/index.js.map +1 -0
- package/dist/features/keyboardNavigation.js +9 -0
- package/dist/features/keyboardNavigation.js.map +1 -0
- package/dist/features/menus.js +11 -0
- package/dist/features/menus.js.map +1 -0
- package/dist/features/pagination.js +9 -0
- package/dist/features/pagination.js.map +1 -0
- package/dist/features/rowPinning.js +11 -0
- package/dist/features/rowPinning.js.map +1 -0
- package/dist/features/selection.js +11 -0
- package/dist/features/selection.js.map +1 -0
- package/dist/features/serverData.js +9 -0
- package/dist/features/serverData.js.map +1 -0
- package/dist/features/sorting.js +9 -0
- package/dist/features/sorting.js.map +1 -0
- package/dist/features/subGrids.js +9 -0
- package/dist/features/subGrids.js.map +1 -0
- package/dist/features/virtualScrolling.js +9 -0
- package/dist/features/virtualScrolling.js.map +1 -0
- package/dist/index.js +67 -0
- package/dist/internal/RenderSlot.js +6 -0
- package/dist/internal/RenderSlot.js.map +1 -0
- package/dist/internal/anchor.js +41 -0
- package/dist/internal/anchor.js.map +1 -0
- package/dist/internal/clipboard.js +11 -0
- package/dist/internal/clipboard.js.map +1 -0
- package/dist/internal/context.js +11 -0
- package/dist/internal/context.js.map +1 -0
- package/dist/internal/dev.js +8 -0
- package/dist/internal/dev.js.map +1 -0
- package/dist/internal/features.js +9 -0
- package/dist/internal/features.js.map +1 -0
- package/dist/internal/supports.js +10 -0
- package/dist/internal/supports.js.map +1 -0
- package/dist/internal/touchHold.js +43 -0
- package/dist/internal/touchHold.js.map +1 -0
- package/dist/registry/plugin.js +25 -0
- package/dist/registry/plugin.js.map +1 -0
- package/dist/registry/registry.js +15 -0
- package/dist/registry/registry.js.map +1 -0
- package/dist/renderers/ActionButtonCell.js +6 -0
- package/dist/renderers/ActionButtonCell.js.map +1 -0
- package/dist/renderers/ActionButtonCell.vue_vue_type_script_setup_true_lang.js +44 -0
- package/dist/renderers/ActionButtonCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/ActionsMenuCell.js +6 -0
- package/dist/renderers/ActionsMenuCell.js.map +1 -0
- package/dist/renderers/ActionsMenuCell.vue_vue_type_script_setup_true_lang.js +75 -0
- package/dist/renderers/ActionsMenuCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/BooleanCell.js +6 -0
- package/dist/renderers/BooleanCell.js.map +1 -0
- package/dist/renderers/BooleanCell.vue_vue_type_script_setup_true_lang.js +45 -0
- package/dist/renderers/BooleanCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/ButtonGroupCell.js +6 -0
- package/dist/renderers/ButtonGroupCell.js.map +1 -0
- package/dist/renderers/ButtonGroupCell.vue_vue_type_script_setup_true_lang.js +46 -0
- package/dist/renderers/ButtonGroupCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/ChangeCell.js +6 -0
- package/dist/renderers/ChangeCell.js.map +1 -0
- package/dist/renderers/ChangeCell.vue_vue_type_script_setup_true_lang.js +59 -0
- package/dist/renderers/ChangeCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/CheckboxCell.js +6 -0
- package/dist/renderers/CheckboxCell.js.map +1 -0
- package/dist/renderers/CheckboxCell.vue_vue_type_script_setup_true_lang.js +41 -0
- package/dist/renderers/CheckboxCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/ChipCell.js +6 -0
- package/dist/renderers/ChipCell.js.map +1 -0
- package/dist/renderers/ChipCell.vue_vue_type_script_setup_true_lang.js +59 -0
- package/dist/renderers/ChipCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/CodeCell.js +6 -0
- package/dist/renderers/CodeCell.js.map +1 -0
- package/dist/renderers/CodeCell.vue_vue_type_script_setup_true_lang.js +49 -0
- package/dist/renderers/CodeCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/CopyCell.js +6 -0
- package/dist/renderers/CopyCell.js.map +1 -0
- package/dist/renderers/CopyCell.vue_vue_type_script_setup_true_lang.js +51 -0
- package/dist/renderers/CopyCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/CurrencyCell.js +6 -0
- package/dist/renderers/CurrencyCell.js.map +1 -0
- package/dist/renderers/CurrencyCell.vue_vue_type_script_setup_true_lang.js +38 -0
- package/dist/renderers/CurrencyCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/DateCell.js +6 -0
- package/dist/renderers/DateCell.js.map +1 -0
- package/dist/renderers/DateCell.vue_vue_type_script_setup_true_lang.js +30 -0
- package/dist/renderers/DateCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/DateTimeCell.js +6 -0
- package/dist/renderers/DateTimeCell.js.map +1 -0
- package/dist/renderers/DateTimeCell.vue_vue_type_script_setup_true_lang.js +34 -0
- package/dist/renderers/DateTimeCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/DetailsCell.js +6 -0
- package/dist/renderers/DetailsCell.js.map +1 -0
- package/dist/renderers/DetailsCell.vue_vue_type_script_setup_true_lang.js +82 -0
- package/dist/renderers/DetailsCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/EditCell.js +6 -0
- package/dist/renderers/EditCell.js.map +1 -0
- package/dist/renderers/EditCell.vue_vue_type_script_setup_true_lang.js +41 -0
- package/dist/renderers/EditCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/IconCell.js +6 -0
- package/dist/renderers/IconCell.js.map +1 -0
- package/dist/renderers/IconCell.vue_vue_type_script_setup_true_lang.js +39 -0
- package/dist/renderers/IconCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/IconToggleCell.js +6 -0
- package/dist/renderers/IconToggleCell.js.map +1 -0
- package/dist/renderers/IconToggleCell.vue_vue_type_script_setup_true_lang.js +44 -0
- package/dist/renderers/IconToggleCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/ImageCell.js +6 -0
- package/dist/renderers/ImageCell.js.map +1 -0
- package/dist/renderers/ImageCell.vue_vue_type_script_setup_true_lang.js +47 -0
- package/dist/renderers/ImageCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/JsonCell.js +6 -0
- package/dist/renderers/JsonCell.js.map +1 -0
- package/dist/renderers/JsonCell.vue_vue_type_script_setup_true_lang.js +47 -0
- package/dist/renderers/JsonCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/JsonTreeCell.js +6 -0
- package/dist/renderers/JsonTreeCell.js.map +1 -0
- package/dist/renderers/JsonTreeCell.vue_vue_type_script_setup_true_lang.js +56 -0
- package/dist/renderers/JsonTreeCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/JsonTreeNode.js +6 -0
- package/dist/renderers/JsonTreeNode.js.map +1 -0
- package/dist/renderers/JsonTreeNode.vue_vue_type_script_setup_true_lang.js +80 -0
- package/dist/renderers/JsonTreeNode.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/LinkCell.js +6 -0
- package/dist/renderers/LinkCell.js.map +1 -0
- package/dist/renderers/LinkCell.vue_vue_type_script_setup_true_lang.js +63 -0
- package/dist/renderers/LinkCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/ListCell.js +6 -0
- package/dist/renderers/ListCell.js.map +1 -0
- package/dist/renderers/ListCell.vue_vue_type_script_setup_true_lang.js +46 -0
- package/dist/renderers/ListCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/MultiLineCell.js +6 -0
- package/dist/renderers/MultiLineCell.js.map +1 -0
- package/dist/renderers/MultiLineCell.vue_vue_type_script_setup_true_lang.js +102 -0
- package/dist/renderers/MultiLineCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/NumberCell.js +6 -0
- package/dist/renderers/NumberCell.js.map +1 -0
- package/dist/renderers/NumberCell.vue_vue_type_script_setup_true_lang.js +35 -0
- package/dist/renderers/NumberCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/RadioCell.js +6 -0
- package/dist/renderers/RadioCell.js.map +1 -0
- package/dist/renderers/RadioCell.vue_vue_type_script_setup_true_lang.js +43 -0
- package/dist/renderers/RadioCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/StatusCell.js +6 -0
- package/dist/renderers/StatusCell.js.map +1 -0
- package/dist/renderers/StatusCell.vue_vue_type_script_setup_true_lang.js +51 -0
- package/dist/renderers/StatusCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/SwitchCell.js +6 -0
- package/dist/renderers/SwitchCell.js.map +1 -0
- package/dist/renderers/SwitchCell.vue_vue_type_script_setup_true_lang.js +41 -0
- package/dist/renderers/SwitchCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/TextCell.js +6 -0
- package/dist/renderers/TextCell.js.map +1 -0
- package/dist/renderers/TextCell.vue_vue_type_script_setup_true_lang.js +92 -0
- package/dist/renderers/TextCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/ToggleTextCell.js +6 -0
- package/dist/renderers/ToggleTextCell.js.map +1 -0
- package/dist/renderers/ToggleTextCell.vue_vue_type_script_setup_true_lang.js +36 -0
- package/dist/renderers/ToggleTextCell.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/format.js +142 -0
- package/dist/renderers/format.js.map +1 -0
- package/dist/renderers/index.js +188 -0
- package/dist/renderers/index.js.map +1 -0
- package/dist/renderers/options.js +17 -0
- package/dist/renderers/options.js.map +1 -0
- package/dist/renderers/parts/CopyButton.js +6 -0
- package/dist/renderers/parts/CopyButton.js.map +1 -0
- package/dist/renderers/parts/CopyButton.vue_vue_type_script_setup_true_lang.js +37 -0
- package/dist/renderers/parts/CopyButton.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/parts/NumberValue.js +6 -0
- package/dist/renderers/parts/NumberValue.js.map +1 -0
- package/dist/renderers/parts/NumberValue.vue_vue_type_script_setup_true_lang.js +25 -0
- package/dist/renderers/parts/NumberValue.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/parts/ValueBadge.js +6 -0
- package/dist/renderers/parts/ValueBadge.js.map +1 -0
- package/dist/renderers/parts/ValueBadge.vue_vue_type_script_setup_true_lang.js +17 -0
- package/dist/renderers/parts/ValueBadge.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/renderers/parts/icons.js +27 -0
- package/dist/renderers/parts/icons.js.map +1 -0
- package/dist/renderers/parts/routerLink.js +9 -0
- package/dist/renderers/parts/routerLink.js.map +1 -0
- package/dist/renderers/parts/useToggleControl.js +15 -0
- package/dist/renderers/parts/useToggleControl.js.map +1 -0
- package/dist/renderers/text.js +10 -0
- package/dist/renderers/text.js.map +1 -0
- package/dist/renderers.css +1 -0
- package/dist/theme.css +1 -0
- package/dist/types/agent/index.d.ts +50 -0
- package/dist/types/agent/requirements.d.ts +17 -0
- package/dist/types/agent/validate.d.ts +33 -0
- package/dist/types/components/VGrid.vue.d.ts +205 -0
- package/dist/types/components/VGridCell.vue.d.ts +19 -0
- package/dist/types/components/VGridCheckbox.vue.d.ts +14 -0
- package/dist/types/components/VGridColumnMenu.vue.d.ts +22 -0
- package/dist/types/components/VGridFilterInput.vue.d.ts +17 -0
- package/dist/types/components/VGridFilterPanel.vue.d.ts +20 -0
- package/dist/types/components/VGridFilterPopover.vue.d.ts +12 -0
- package/dist/types/components/VGridGroupRow.vue.d.ts +3 -0
- package/dist/types/components/VGridHeader.vue.d.ts +26 -0
- package/dist/types/components/VGridMenu.vue.d.ts +42 -0
- package/dist/types/components/VGridPagination.vue.d.ts +27 -0
- package/dist/types/components/VGridPinnedRows.vue.d.ts +15 -0
- package/dist/types/components/VGridResizeHandle.vue.d.ts +8 -0
- package/dist/types/components/VGridRows.vue.d.ts +28 -0
- package/dist/types/components/VGridSearch.vue.d.ts +22 -0
- package/dist/types/components/VGridTotalCell.vue.d.ts +13 -0
- package/dist/types/composables/useColumnDrag.d.ts +26 -0
- package/dist/types/composables/useColumnResize.d.ts +29 -0
- package/dist/types/composables/useDataSource.d.ts +39 -0
- package/dist/types/composables/useGridFilters.d.ts +45 -0
- package/dist/types/composables/useGridKeyboard.d.ts +16 -0
- package/dist/types/composables/useGridMenus.d.ts +55 -0
- package/dist/types/composables/useGridSelection.d.ts +27 -0
- package/dist/types/composables/usePinnedOffsets.d.ts +22 -0
- package/dist/types/composables/usePinnedRows.d.ts +26 -0
- package/dist/types/composables/useScrollEdges.d.ts +8 -0
- package/dist/types/composables/useSubRows.d.ts +38 -0
- package/dist/types/composables/useTotals.d.ts +17 -0
- package/dist/types/composables/useVirtualRows.d.ts +72 -0
- package/dist/types/core/aggregate.d.ts +9 -0
- package/dist/types/core/columns.d.ts +35 -0
- package/dist/types/core/filter.d.ts +85 -0
- package/dist/types/core/helpers.d.ts +3 -0
- package/dist/types/core/pagination.d.ts +3 -0
- package/dist/types/core/patch.d.ts +23 -0
- package/dist/types/core/selection.d.ts +8 -0
- package/dist/types/core/sort.d.ts +10 -0
- package/dist/types/core/storage.d.ts +6 -0
- package/dist/types/core/value.d.ts +6 -0
- package/dist/types/core/virtual.d.ts +72 -0
- package/dist/types/features/aggregation.d.ts +8 -0
- package/dist/types/features/columnGroups.d.ts +7 -0
- package/dist/types/features/columnPinning.d.ts +7 -0
- package/dist/types/features/columnReorder.d.ts +7 -0
- package/dist/types/features/columnResizing.d.ts +8 -0
- package/dist/types/features/columnVisibility.d.ts +7 -0
- package/dist/types/features/filtering.d.ts +7 -0
- package/dist/types/features/index.d.ts +20 -0
- package/dist/types/features/keyboardNavigation.d.ts +10 -0
- package/dist/types/features/menus.d.ts +8 -0
- package/dist/types/features/pagination.d.ts +8 -0
- package/dist/types/features/rowPinning.d.ts +8 -0
- package/dist/types/features/selection.d.ts +6 -0
- package/dist/types/features/serverData.d.ts +6 -0
- package/dist/types/features/sorting.d.ts +6 -0
- package/dist/types/features/subGrids.d.ts +6 -0
- package/dist/types/features/virtualScrolling.d.ts +8 -0
- package/dist/types/index.d.ts +21 -0
- package/dist/types/internal/RenderSlot.d.ts +6 -0
- package/dist/types/internal/anchor.d.ts +18 -0
- package/dist/types/internal/clipboard.d.ts +2 -0
- package/dist/types/internal/context.d.ts +123 -0
- package/dist/types/internal/dev.d.ts +1 -0
- package/dist/types/internal/features.d.ts +22 -0
- package/dist/types/internal/supports.d.ts +11 -0
- package/dist/types/internal/touchHold.d.ts +19 -0
- package/dist/types/registry/plugin.d.ts +18 -0
- package/dist/types/registry/registry.d.ts +18 -0
- package/dist/types/renderers/ActionButtonCell.vue.d.ts +10 -0
- package/dist/types/renderers/ActionsMenuCell.vue.d.ts +10 -0
- package/dist/types/renderers/BooleanCell.vue.d.ts +6 -0
- package/dist/types/renderers/ButtonGroupCell.vue.d.ts +10 -0
- package/dist/types/renderers/ChangeCell.vue.d.ts +6 -0
- package/dist/types/renderers/CheckboxCell.vue.d.ts +10 -0
- package/dist/types/renderers/ChipCell.vue.d.ts +6 -0
- package/dist/types/renderers/CodeCell.vue.d.ts +6 -0
- package/dist/types/renderers/CopyCell.vue.d.ts +10 -0
- package/dist/types/renderers/CurrencyCell.vue.d.ts +10 -0
- package/dist/types/renderers/DateCell.vue.d.ts +6 -0
- package/dist/types/renderers/DateTimeCell.vue.d.ts +6 -0
- package/dist/types/renderers/DetailsCell.vue.d.ts +6 -0
- package/dist/types/renderers/EditCell.vue.d.ts +10 -0
- package/dist/types/renderers/IconCell.vue.d.ts +6 -0
- package/dist/types/renderers/IconToggleCell.vue.d.ts +10 -0
- package/dist/types/renderers/ImageCell.vue.d.ts +6 -0
- package/dist/types/renderers/JsonCell.vue.d.ts +6 -0
- package/dist/types/renderers/JsonTreeCell.vue.d.ts +6 -0
- package/dist/types/renderers/JsonTreeNode.vue.d.ts +14 -0
- package/dist/types/renderers/LinkCell.vue.d.ts +10 -0
- package/dist/types/renderers/ListCell.vue.d.ts +10 -0
- package/dist/types/renderers/MultiLineCell.vue.d.ts +10 -0
- package/dist/types/renderers/NumberCell.vue.d.ts +12 -0
- package/dist/types/renderers/RadioCell.vue.d.ts +10 -0
- package/dist/types/renderers/StatusCell.vue.d.ts +10 -0
- package/dist/types/renderers/SwitchCell.vue.d.ts +10 -0
- package/dist/types/renderers/TextCell.vue.d.ts +10 -0
- package/dist/types/renderers/ToggleTextCell.vue.d.ts +10 -0
- package/dist/types/renderers/format.d.ts +27 -0
- package/dist/types/renderers/index.d.ts +132 -0
- package/dist/types/renderers/options.d.ts +325 -0
- package/dist/types/renderers/parts/CopyButton.vue.d.ts +16 -0
- package/dist/types/renderers/parts/NumberValue.vue.d.ts +12 -0
- package/dist/types/renderers/parts/ValueBadge.vue.d.ts +7 -0
- package/dist/types/renderers/parts/icons.d.ts +21 -0
- package/dist/types/renderers/parts/routerLink.d.ts +7 -0
- package/dist/types/renderers/parts/useToggleControl.d.ts +12 -0
- package/dist/types/renderers/text.d.ts +3 -0
- package/dist/types/types.d.ts +383 -0
- package/dist/vue-grid.css +1 -0
- package/llms-full.txt +1806 -0
- package/llms.txt +23 -0
- package/package.json +74 -4
package/agent/api.md
ADDED
|
@@ -0,0 +1,632 @@
|
|
|
1
|
+
# @nocopypaste/vue-grid 0.2.0 — API reference
|
|
2
|
+
|
|
3
|
+
> Generated from the TypeScript sources (`scripts/gen-agent.mjs`). Machine-readable: `agent/api.json`, `agent/grid-config.schema.json`.
|
|
4
|
+
|
|
5
|
+
## Features
|
|
6
|
+
|
|
7
|
+
Opt-in: pass them as `:features="[…]"` on `<VGrid>` or once via `createVueGrid({ features })` (`allFeatures` = all). An option whose feature is missing does nothing.
|
|
8
|
+
|
|
9
|
+
| Export | What it enables | Props | Column options |
|
|
10
|
+
|---|---|---|---|
|
|
11
|
+
| `aggregationFeature` | Aggregates and the totals row: columns with an `aggregate` (`sum`, `avg`, `min`, `max`, `count` or a function) and `totals` (`true` / `'bottom'` or `'top'`) show a sticky totals row over the rows that pass the filters, on every page. `aggregates` supplies the values instead (e.g. from a server). Without it, `aggregate` and `totals` are ignored. | `totals` `totalsLabel` `aggregates` | `aggregate` |
|
|
12
|
+
| `columnGroupsFeature` | Grouped column headers: give columns a `group` and adjacent visible columns of the same group get one header cell spanning them, in a sticky row above the column headers. Groups follow reordering, hiding and pinning (a pin boundary splits a group). Without it, `group` is ignored. | | `group` |
|
|
13
|
+
| `columnPinningFeature` | Pinned columns: `pinned: 'left' \| 'right'` columns stay put (sticky) while the grid scrolls sideways, with edge shadows; runtime pins from the header menu (Pin left / Pin right / Unpin) are kept in `v-model:column-state` and persisted with `storage`. Without it, pins are ignored. | | `pinned` `pinnable` |
|
|
14
|
+
| `columnReorderFeature` | Column reordering: drag a header (mouse, pen, touch), Alt+←/→ on a focused header, and the header menu's Move left / Move right. Columns opt out with `reorderable: false`. The order is part of `v-model:column-state` and persisted with `storage`; `<VGridColumnMenu>` works without it. | | `reorderable` |
|
|
15
|
+
| `columnResizingFeature` | Column resizing: drag a header's edge (mouse, pen, touch), use ←/→ on the focused edge (Alt+Shift+←/→ on a header with keyboard navigation), or double-click the edge to fit the content. `minWidth` / `maxWidth` bound it; columns opt out with `resizable: false`. Widths are kept in `columnState.widths` and persisted with `storage`. The header menu gains Fit width / Reset width. | | `maxWidth` `resizable` |
|
|
16
|
+
| `columnVisibilityFeature` | Column visibility: `hidden: true` columns, `columnState.hidden` (persisted with `storage`), the header menu's Hide column item and `<VGridColumnMenu>`'s checkboxes. Columns opt out with `hideable: false`. Without it, every column shows. | | `hidden` `hideable` |
|
|
17
|
+
| `filteringFeature` | Filtering: header funnels with typed filter popovers on `filterable` columns, the filter row, `<VGridSearch>`, the filter items of the header menu, `v-model:filters` and filter persistence. The popover body and the filter-row editors load on demand (own chunks). | `filterMode` `filterRow` `filterStorage` `noMatchText` `filters` | `filterable` `filter` `filterValue` `filterFn` `filterComponent` `searchable` |
|
|
18
|
+
| `keyboardNavigationFeature` | Keyboard navigation (the ARIA grid pattern): the grid is one tab stop, arrow keys / Home / End / PageUp / PageDown move between cells, Enter activates a cell's control, Space selects a row, →/← expand and collapse, Alt+←/→ move a column, ContextMenu / Shift+F10 open the cell menu. Without it the grid is an ARIA `table`: its own controls (sort buttons, expanders, checkboxes, filter buttons) sit in the normal Tab order instead. | | |
|
|
19
|
+
| `menusFeature` | Context menus: the built-in header menu (sort, filter, pin, move, hide, reset, your own items via `header-menu`) and body-cell menus (`context-menu`), opened by right-click, the ContextMenu key or Shift+F10. Without it the browser's own menu shows. The standalone `<VGridMenu>` and the `actions-menu` renderer don't need it. | `contextMenu` `headerMenu` | |
|
|
20
|
+
| `paginationFeature` | Built-in pagination: the `pagination` prop and `v-model:page` / `v-model:page-size`. Pages the client rows, or asks the `dataSource` for pages. The pager loads on demand (own chunk). Not needed for the standalone `<VGridPagination>` component. | `pagination` `page` `pageSize` | |
|
|
21
|
+
| `rowPinningFeature` | Pinned rows: `v-model:pinned-rows` (`{ top, bottom }` row keys), `pinned-top-rows` / `pinned-bottom-rows` (extra rows that aren't in the data) and the `pinRow()` method. Pinned rows stay in view (sticky) under the header or at the bottom while the body scrolls, and aren't filtered, sorted or paged. Without it, those options are ignored. | `pinnedTopRows` `pinnedBottomRows` `pinnedRows` | |
|
|
22
|
+
| `selectionFeature` | Row selection: the `selectable` prop (multi or single), `v-model:selected`, `selection-mode` (cascade through sub-grids), `is-row-selectable`, Space on a row and the select-all checkbox. | `selectable` `selectionMode` `isRowSelectable` `selected` | |
|
|
23
|
+
| `serverDataFeature` | Server data: the `dataSource` prop. The grid sends sort, filters and page to your function, cancels superseded requests, and shows loading, error and retry states. | `dataSource` | |
|
|
24
|
+
| `sortingFeature` | Sorting: the sort button on `sortable` column headers, the sort items of the header menu and, with `sort-mode="client"`, sorting the rows in the browser. | | `sortable` `sortValue` `sortFn` |
|
|
25
|
+
| `subGridsFeature` | Sub-grids: nested child rows in a CSS `subgrid`, from `sub-rows` (synchronous) or `load-sub-rows` (lazy, cached, with loading / error / retry). Detail rows (`#detail` slot) don't need it. | `subRows` `loadSubRows` `hasSubRows` | |
|
|
26
|
+
| `virtualScrollingFeature` | Virtual scrolling: `:virtual="{ rowHeight, overscan?, detailHeight? }"` renders only the rows in view (plus `overscan`), so tens of thousands of rows stay fast — sub-grids and detail rows included, inside the same CSS grid / subgrid layout. Without it, `virtual` is ignored and every row renders. | `virtual` | |
|
|
27
|
+
|
|
28
|
+
## `<VGrid>` props
|
|
29
|
+
|
|
30
|
+
| Prop | Type | Default | Needs | Description |
|
|
31
|
+
|---|---|---|---|---|
|
|
32
|
+
| `rows` | `readonly T[]` | `[]` | | The rows (client data), used as-is and never mutated. Omit when using `dataSource`. |
|
|
33
|
+
| `columns` (required) | `readonly ColumnDef<T>[]` | | | Column definitions, in default display order (see `ColumnDef`). |
|
|
34
|
+
| `rowKey` (required) | `RowKeyGetter<T>` | | | Stable unique id of a row: a property name or `(row) => string \| number`. All row state is keyed by it. |
|
|
35
|
+
| `features` | `readonly GridFeature[]` | | | Opt-in features for this grid (added to the app-wide `createVueGrid({ features })`): `sortingFeature`, `filteringFeature`, `serverDataFeature`, `paginationFeature`, or `allFeatures`. Read once, when the grid is created. |
|
|
36
|
+
| `dataSource` | `DataSource<T>` | | `serverDataFeature` | Server data: called with the current query (sort, filters, search, page) whenever it changes. The grid cancels superseded requests, shows loading and errors, and sorts / filters / pages nothing itself. |
|
|
37
|
+
| `pagination` | `boolean \| { pageSizes?: number[] }` | `false` | `paginationFeature` | Built-in pagination under the grid (server-side with `dataSource`, client-side otherwise). |
|
|
38
|
+
| `sortMode` | `'controlled' \| 'client'` | `'controlled'` | | `controlled` (default): a header click only updates `v-model:sort` (sort on the server or in your own code). `client`: the grid sorts the rows itself. Ignored with `dataSource`. |
|
|
39
|
+
| `filterMode` | `'client' \| 'controlled'` | `'client'` | `filteringFeature` | `client` (default): the grid filters its rows. `controlled`: it only emits `update:filters`. |
|
|
40
|
+
| `filterRow` | `boolean` | `false` | `filteringFeature` | Show the filter row: an input under each filterable column's header. |
|
|
41
|
+
| `filterStorage` | `FilterStateStorage \| string` | | `filteringFeature` | Persist the filter model (`string` = localStorage key). |
|
|
42
|
+
| `noMatchText` | `string` | `'No rows match the current filters.'` | `filteringFeature` | Shown when filters hide every row. |
|
|
43
|
+
| `selectable` | `boolean \| 'single'` | `false` | `selectionFeature` | A selection column: `true` = multi-select (with select-all), `'single'` = one row. |
|
|
44
|
+
| `selectionMode` | `'cascade' \| 'independent'` | `'cascade'` | `selectionFeature` | `cascade` (default): selecting a parent selects its children. `independent`: rows alone. |
|
|
45
|
+
| `isRowSelectable` | `(row: T) => boolean` | | `selectionFeature` | Rows that can't be selected get a disabled checkbox. |
|
|
46
|
+
| `subRows` | `(row: T) => T[] \| undefined \| null` | | `subGridsFeature` | Synchronous child rows of a row: shown in a nested sub-grid when expanded. |
|
|
47
|
+
| `loadSubRows` | `(row: T) => Promise<T[]>` | | `subGridsFeature` | Lazy child rows, loaded on first expand (cached, with loading / error / retry). |
|
|
48
|
+
| `hasSubRows` | `(row: T) => boolean` | | `subGridsFeature` | With `loadSubRows`: which rows get an expander (default: every row). |
|
|
49
|
+
| `rowExpandable` | `(row: T) => boolean` | | | With a `#detail` slot: which rows can expand to show it (default: every row). |
|
|
50
|
+
| `rowClickable` | `boolean` | `false` | | Pointer cursor on rows (`row-click` is emitted either way). |
|
|
51
|
+
| `rowClass` | `(row: T, index: number) => ClassValue` | | | Extra classes for a row. |
|
|
52
|
+
| `highlightedRows` | `readonly RowKey[]` | | | Keys of rows to highlight (e.g. the row being edited). |
|
|
53
|
+
| `flash` | `FlashMode` | | | Briefly highlight cells whose value changes (live data, enrichment). Columns can override. |
|
|
54
|
+
| `virtual` | `VirtualOptions \| false` | `false` | `virtualScrollingFeature` | Virtual scrolling: only the rows in view render. Rows share one height (`rowHeight`, px) and the grid needs a bounded height. Needs the virtual scrolling feature. |
|
|
55
|
+
| `storage` | `ColumnStateStorage \| string` | | | Persist column state (order, hidden, pins, widths): a localStorage key or your own storage. |
|
|
56
|
+
| `renderers` | `CellRendererDefinition[]` | | | Renderers usable by name in this grid (merged over the app-wide ones). |
|
|
57
|
+
| `locale` | `string` | | | Locale for number / date renderers (default: the plugin's, else the browser's). |
|
|
58
|
+
| `currency` | `string` | | | Default ISO 4217 currency for currency renderers. |
|
|
59
|
+
| `timeZone` | `string` | | | IANA time zone for date renderers and date filters. |
|
|
60
|
+
| `density` | `Density` | | | Cell padding scale. |
|
|
61
|
+
| `loading` | `boolean` | `false` | | Shows a progress bar and sets `aria-busy` (server data sets it by itself). |
|
|
62
|
+
| `emptyText` | `string` | `'No data to show.'` | | Shown when there are no rows. |
|
|
63
|
+
| `ariaLabel` | `string` | | | Accessible name of the grid. |
|
|
64
|
+
| `ui` | `Partial<Record<GridPart, ClassValue>>` | | | Extra classes per part (`root`, `header`, `headerCell`, `row`, `cell`, `subgrid`, `detail`, `empty`), e.g. Tailwind utilities. |
|
|
65
|
+
| `contextMenu` | `(ctx: CellContext<T>) => MenuItem[] \| null \| undefined` | | `menusFeature` | Right-click menu items for a body cell. Return `null`/`[]` to keep the browser's menu. |
|
|
66
|
+
| `headerMenu` | `boolean \| ((ctx: HeaderMenuContext<T>) => MenuItem[] \| null \| undefined)` | `true` | `menusFeature` | Header right-click menu: `true` = built-in items (sort, pin, move, hide, reset), `false` = off, or a function that receives the built-in items and returns the items to show. |
|
|
67
|
+
| `pinnedTopRows` | `readonly T[]` | | `rowPinningFeature` | Extra rows above the body, not part of the data (row pinning feature). |
|
|
68
|
+
| `pinnedBottomRows` | `readonly T[]` | | `rowPinningFeature` | Extra rows below the body, not part of the data (row pinning feature). |
|
|
69
|
+
| `totals` | `boolean \| 'top' \| 'bottom'` | `false` | `aggregationFeature` | A totals row with each column's `aggregate` (aggregation feature): `true` / `'bottom'` sticks it to the bottom, `'top'` under the header. |
|
|
70
|
+
| `totalsLabel` | `string` | `'Total'` | `aggregationFeature` | The totals row's label, in its first column (unless that column has an aggregate). |
|
|
71
|
+
| `aggregates` | `Record<string, unknown>` | | `aggregationFeature` | Totals row values by column key, instead of computing them (e.g. totals from a server). |
|
|
72
|
+
|
|
73
|
+
## `v-model`s
|
|
74
|
+
|
|
75
|
+
| Model | Type | Default | Needs | Description |
|
|
76
|
+
|---|---|---|---|---|
|
|
77
|
+
| `v-model:sort` | `SortState \| null` | `null` | | Sort state: a header click cycles asc → desc → none. Header UI needs the sorting feature. |
|
|
78
|
+
| `v-model:columnState` | `ColumnState \| undefined` | `undefined` | | Column order, hidden columns, runtime pins and resized widths (persisted with `storage`). |
|
|
79
|
+
| `v-model:expanded` | `RowKey[]` | `[]` | | Keys of expanded rows (sub-grids and detail rows). |
|
|
80
|
+
| `v-model:selected` | `RowKey[]` | `[]` | `selectionFeature` | Keys of selected rows. Needs the selection feature. |
|
|
81
|
+
| `v-model:filters` | `FilterState \| null` | `null` | `filteringFeature` | Column filters and quick search: `{ columns: Record<key, ColumnFilter>, search }`. Needs the filtering feature. |
|
|
82
|
+
| `v-model:page` | `number` | `1` | `paginationFeature` | Current page (1-based); resets to 1 when sort or filters change. Needs the pagination feature. |
|
|
83
|
+
| `v-model:pageSize` | `number` | `25` | `paginationFeature` | Rows per page. Needs the pagination feature. |
|
|
84
|
+
| `v-model:pinnedRows` | `PinnedRowsState \| null` | `null` | `rowPinningFeature` | Top-level rows pinned above / below the body, by key: `{ top, bottom }`. Needs the row pinning feature. |
|
|
85
|
+
|
|
86
|
+
## Events
|
|
87
|
+
|
|
88
|
+
| Event | Payload | Description |
|
|
89
|
+
|---|---|---|
|
|
90
|
+
| `query-change` | `[query: GridQuery]` | The combined query (sort, filters, search, page) — on mount and whenever it changes. |
|
|
91
|
+
| `load-error` | `[error: unknown]` | A `dataSource` call failed (the grid shows an error with Retry). |
|
|
92
|
+
| `row-click` | `[row: T, event: MouseEvent \| KeyboardEvent]` | A row was clicked (not on a link, button or input inside it, nor a `clickable` column). |
|
|
93
|
+
| `cell-click` | `[event: CellClickEvent<T>]` | A cell of a `clickable: true` column was clicked. |
|
|
94
|
+
| `cell-action` | `[event: CellActionEvent<T>]` | A renderer emitted an action (buttons, toggles, menus, edit, copy). |
|
|
95
|
+
| `sub-rows-error` | `[event: { row: T; error: unknown }]` | `loadSubRows` rejected for a row. |
|
|
96
|
+
| `context-action` | `[event: ContextActionEvent<T>]` | An item of the body-cell context menu was chosen. |
|
|
97
|
+
| `header-action` | `[event: HeaderActionEvent<T>]` | A custom item of the header menu was chosen (built-in items act by themselves). |
|
|
98
|
+
|
|
99
|
+
## Slots
|
|
100
|
+
|
|
101
|
+
| Slot | Scope | Description |
|
|
102
|
+
|---|---|---|
|
|
103
|
+
| `cell-<key>` | `{ row: T; value: unknown; rowKey: RowKey; rowIndex: number; depth: number; column: ColumnDef<T> }` | A column's body cell, replacing its renderer: `#cell-<key>`. |
|
|
104
|
+
| `header-<key>` | `{ column: ColumnDef<T> }` | A column's header content: `#header-<key>`. |
|
|
105
|
+
| `total-<key>` | `{ value: unknown; column: ColumnDef<T> }` | A column's cell in the totals row (aggregation feature). |
|
|
106
|
+
| `detail` | `{ row: T; rowKey: RowKey; depth: number }` | Expandable detail row under a row: any content, even another grid. |
|
|
107
|
+
| `empty` | | Shown when there are no rows. |
|
|
108
|
+
| `loading` | | Shown while loading with no rows yet. |
|
|
109
|
+
| `sub-rows-loading` | `{ row: T }` | Shown while a row's lazy children load. |
|
|
110
|
+
| `toolbar` | `{ columns: readonly ColumnDef<T>[]; columnState: ColumnState; setColumnState: (state: ColumnState) => void; filters: FilterState; setFilters: (state: FilterState) => void; clearFilters: () => void; activeFilterCount: number }` | Above the grid: put a search box, column menu or filter summary here. |
|
|
111
|
+
|
|
112
|
+
## Exposed methods (`ref<VGridExposed>()`)
|
|
113
|
+
|
|
114
|
+
| Method | Signature | Needs | Description |
|
|
115
|
+
|---|---|---|---|
|
|
116
|
+
| `scrollToTop` | `void` | | Scrolls the grid back to its first row. |
|
|
117
|
+
| `scrollToRow` | `void` | | Scrolls a row (top-level or nested, also in virtual mode) into view. |
|
|
118
|
+
| `expandAll` | `void` | | Expands every expandable row (sub-grids and detail rows) that passes the filters. |
|
|
119
|
+
| `collapseAll` | `void` | | Collapses every row. |
|
|
120
|
+
| `setColumnState` | `void` | | Replaces the column state (order, hidden, pins, widths), and saves it with `storage`. |
|
|
121
|
+
| `patchLoadedRows` | `number` | | Applies field patches to lazily loaded child rows (`loadSubRows`), which the grid caches and the; app can't reach. Top-level and synchronous `subRows` data belong to the app: update them there (assign fields on reactive rows, or use `patchRows`). Returns the number of rows patched. |
|
|
122
|
+
| `setFilters` | `void` | `filteringFeature` | Replaces the filter model (also persisted with `filter-storage`). |
|
|
123
|
+
| `clearFilters` | `void` | `filteringFeature` | Removes every column filter and the search. |
|
|
124
|
+
| `openFilter` | `void` | `filteringFeature` | Opens a column's filter popover. |
|
|
125
|
+
| `reload` | `Promise<void>` | `serverDataFeature` | Re-runs the `dataSource` with the current query; lazily loaded child rows load again too. |
|
|
126
|
+
| `reloadSubRows` | `void` | | Forgets lazily loaded child rows (one row's, or all): expanded rows load them again. |
|
|
127
|
+
| `pinRow` | `void` | `rowPinningFeature` | Pins a top-level row above or below the body, or unpins it (`null`). Row pinning feature. |
|
|
128
|
+
|
|
129
|
+
## `ColumnDef<T>`
|
|
130
|
+
|
|
131
|
+
| Option | Type | Needs | Description |
|
|
132
|
+
|---|---|---|---|
|
|
133
|
+
| `key` (required) | `string` | | Unique, stable column id. Also used for sort state, column state and slot names. |
|
|
134
|
+
| `header` | `string` | | Header text (default: the key). |
|
|
135
|
+
| `headerTooltip` | `string` | | Tooltip on the header cell. |
|
|
136
|
+
| `field` | `string` | | Dot path into the row, e.g. `user.address.city`. Defaults to `key`. |
|
|
137
|
+
| `value` | `(row: T) => unknown` | | Computes the cell value; wins over `field`. |
|
|
138
|
+
| `renderer` | `R \| Component` | | A renderer definition (`currencyRenderer`), a registered renderer name, or a component. Defaults to `text`. |
|
|
139
|
+
| `rendererOptions` | `RendererOptions<R>` | | Options of the column's renderer, typed against it (merged over the renderer's defaults). |
|
|
140
|
+
| `width` | `string` | | Any CSS grid track size. Defaults to `auto`. |
|
|
141
|
+
| `minWidth` | `string` | | Lower bound; combined with `width` into `minmax(minWidth, width)`, and the resize minimum. |
|
|
142
|
+
| `maxWidth` | `string` | `columnResizingFeature` | Upper bound when the user resizes the column (column resizing feature). |
|
|
143
|
+
| `resizable` | `boolean` | `columnResizingFeature` | Can the user resize this column (column resizing feature)? Default `true`. |
|
|
144
|
+
| `group` | `string` | `columnGroupsFeature` | Header group label (column groups feature): adjacent visible columns with the same `group`; share one header cell above their own headers. |
|
|
145
|
+
| `align` | `Align` | | Cell and header alignment (default: the renderer's, e.g. `end` for numbers, else `start`). |
|
|
146
|
+
| `sortable` | `boolean` | `sortingFeature` | A sort button in the header (sorting feature). Client sorting needs `sort-mode="client"`. |
|
|
147
|
+
| `sortValue` | `(row: T) => unknown` | `sortingFeature` | The value client sorting compares (default: the renderer's sort value, else the cell value). |
|
|
148
|
+
| `sortFn` | `(a: T, b: T) => number` | `sortingFeature` | A full comparator for client sorting; wins over `sortValue`. |
|
|
149
|
+
| `pinned` | `PinSide` | `columnPinningFeature` | Initial pin side (the header menu can change it at runtime unless `pinnable: false`). |
|
|
150
|
+
| `pinnable` | `boolean` | `columnPinningFeature` | Can the user pin/unpin it from the header menu? Default `true`. |
|
|
151
|
+
| `hidden` | `boolean` | `columnVisibilityFeature` | Initial visibility (column state wins once it exists). |
|
|
152
|
+
| `hideable` | `boolean` | `columnVisibilityFeature` | Can the user hide it from the column menu? Default `true`. |
|
|
153
|
+
| `reorderable` | `boolean` | `columnReorderFeature` | Can the user move it? Default `true`. |
|
|
154
|
+
| `clickable` | `boolean` | | Cell click emits `cell-click` instead of `row-click`. |
|
|
155
|
+
| `filterable` | `boolean` | `filteringFeature` | Show a filter for this column (funnel in the header, and an input in the filter row). |
|
|
156
|
+
| `filter` | `FilterType \| ColumnFilterOptions` | `filteringFeature` | Filter type — default from the renderer (number, date, boolean, set for status/chip, else text) — or options. |
|
|
157
|
+
| `filterValue` | `(row: T) => unknown` | `filteringFeature` | Value used for filtering (default: the cell value). |
|
|
158
|
+
| `filterFn` | `(row: T, filter: ColumnFilter, value: unknown) => boolean` | `filteringFeature` | Custom predicate; replaces the built-in matching for this column. |
|
|
159
|
+
| `filterComponent` | `Component` | `filteringFeature` | Custom filter UI (popover), receives `modelValue` / emits `update:modelValue` with a filter. |
|
|
160
|
+
| `searchable` | `boolean` | `filteringFeature` | Include in the quick search. Default `true` for visible columns. |
|
|
161
|
+
| `flash` | `FlashMode` | | Briefly highlight the cell when its value changes (overrides the grid's `flash` prop). `'direction'`: green when a number goes up, red when it goes down. |
|
|
162
|
+
| `aggregate` | `AggregateName \| AggregateFn<T>` | `aggregationFeature` | The column's value in the totals row (aggregation feature): `'sum' \| 'avg' \| 'min' \| 'max'`; over the cell values (empty values skipped), `'count'` of rows, or a function of the values and; the rows. Shown with the column's renderer (`count` as a plain number). |
|
|
163
|
+
| `cellClass` | `ClassValue \| ((row: T) => ClassValue)` | | Extra classes for the column's body cells (or a function of the row). |
|
|
164
|
+
| `headerClass` | `ClassValue` | | Extra classes for the column's header cell. |
|
|
165
|
+
|
|
166
|
+
## Renderers
|
|
167
|
+
|
|
168
|
+
Set `renderer` to the definition (`renderer: currencyRenderer`, tree-shakeable) or to a name registered with `createVueGrid({ renderers })` / `:renderers`; `rendererOptions` are typed against it. Option values marked `RowFn` / `RowOption` may also be `(value, row) => …`.
|
|
169
|
+
|
|
170
|
+
### `text` — `textRenderer`
|
|
171
|
+
|
|
172
|
+
Text, the default renderer (the only one `<VGrid>` bundles): ellipsis, line clamp, tone, badge, icon, secondary text, copy button. Align: `start` · filter type: `text`.
|
|
173
|
+
|
|
174
|
+
| Option | Type | Description |
|
|
175
|
+
|---|---|---|
|
|
176
|
+
| `ellipsis` | `boolean` | Single line with ellipsis (full text in a tooltip). |
|
|
177
|
+
| `lines` | `number` | Clamp to N lines. |
|
|
178
|
+
| `maxWidth` | `string` | |
|
|
179
|
+
| `preserveNewlines` | `boolean` | Keep line breaks in the value (`white-space: pre-line`). |
|
|
180
|
+
| `tooltip` | `boolean \| RowFn<string \| undefined>` | `true` = value as tooltip; a function computes it. |
|
|
181
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
182
|
+
| `tone` | `RowOption<Tone \| undefined>` | |
|
|
183
|
+
| `toneMode` | `'text' \| 'fill'` | `text` (default) colours the text; `fill` colours the badge-like background. |
|
|
184
|
+
| `bold` | `RowOption<boolean>` | |
|
|
185
|
+
| `secondary` | `RowFn<string \| null \| undefined>` | Muted text after the value, e.g. a half-time score: `2:1 (1:0)`. |
|
|
186
|
+
| `badge` | `RowFn<BadgeSpec \| string \| null \| undefined>` | Badge before (default) or after the value. |
|
|
187
|
+
| `badgePosition` | `'start' \| 'end'` | |
|
|
188
|
+
| `icon` | `RowFn<IconSpec \| null \| undefined>` | Icon before the value, e.g. `{ icon: BellIcon, tone: 'warning', label: 'Notify' }`. |
|
|
189
|
+
| `copyable` | `boolean` | Adds a copy-to-clipboard button; emits `copy` with the copied text. |
|
|
190
|
+
| `copyValue` | `RowFn<string>` | What gets copied (default: the displayed text). |
|
|
191
|
+
|
|
192
|
+
### `toggle-text` — `toggleTextRenderer`
|
|
193
|
+
|
|
194
|
+
Text that toggles a highlight when clicked. Emits `toggle` (with `clickable`). Align: `start` · filter type: `text`.
|
|
195
|
+
|
|
196
|
+
| Option | Type | Description |
|
|
197
|
+
|---|---|---|
|
|
198
|
+
| `clickable` | `boolean \| RowFn<boolean>` | When true, the text is a button that emits action `toggle`. |
|
|
199
|
+
| `highlighted` | `boolean \| RowFn<boolean>` | |
|
|
200
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
201
|
+
|
|
202
|
+
### `number` — `numberRenderer`
|
|
203
|
+
|
|
204
|
+
Locale-formatted numbers. With `clickable`, a link-style button that emits `click`. Align: `end` · filter type: `number`.
|
|
205
|
+
|
|
206
|
+
| Option | Type | Description |
|
|
207
|
+
|---|---|---|
|
|
208
|
+
| `format` | `Intl.NumberFormatOptions` | `Intl.NumberFormat` options, e.g. `{ maximumFractionDigits: 0 }` or `{ style: 'percent' }`. |
|
|
209
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
210
|
+
| `clickable` | `RowOption<boolean>` | Renders the number as a link-style button that emits `click` (drill-down). |
|
|
211
|
+
|
|
212
|
+
### `signed-number` — `signedNumberRenderer`
|
|
213
|
+
|
|
214
|
+
Numbers that always show their sign (+ / −). With `clickable`, emits `click`. Align: `end` · filter type: `number` · defaults: `{ signed: true }`.
|
|
215
|
+
|
|
216
|
+
| Option | Type | Description |
|
|
217
|
+
|---|---|---|
|
|
218
|
+
| `format` | `Intl.NumberFormatOptions` | `Intl.NumberFormat` options, e.g. `{ maximumFractionDigits: 0 }` or `{ style: 'percent' }`. |
|
|
219
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
220
|
+
| `clickable` | `RowOption<boolean>` | Renders the number as a link-style button that emits `click` (drill-down). |
|
|
221
|
+
| `signed` | `boolean` | |
|
|
222
|
+
|
|
223
|
+
### `currency` — `currencyRenderer`
|
|
224
|
+
|
|
225
|
+
Money in a fixed or per-row currency (default: the grid's `currency`). With `clickable`, emits `click`. Align: `end` · filter type: `number`.
|
|
226
|
+
|
|
227
|
+
| Option | Type | Description |
|
|
228
|
+
|---|---|---|
|
|
229
|
+
| `currency` | `string \| RowFn<string \| undefined>` | ISO 4217 code, or derived from the row. Defaults to the grid context currency. |
|
|
230
|
+
| `format` | `Intl.NumberFormatOptions` | `Intl.NumberFormat` options, e.g. `{ maximumFractionDigits: 0 }` or `{ style: 'percent' }`. |
|
|
231
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
232
|
+
| `clickable` | `RowOption<boolean>` | Renders the number as a link-style button that emits `click` (drill-down). |
|
|
233
|
+
|
|
234
|
+
### `change` — `changeRenderer`
|
|
235
|
+
|
|
236
|
+
A rise or fall: the value with an up / down arrow, green or red. Align: `end` · filter type: `number`.
|
|
237
|
+
|
|
238
|
+
| Option | Type | Description |
|
|
239
|
+
|---|---|---|
|
|
240
|
+
| `direction` | `RowFn<'up' \| 'down' \| 'equal' \| undefined>` | Defaults to the sign of a numeric value, or `true` / `false` (also as strings) → up / down. |
|
|
241
|
+
| `currency` | `boolean \| string` | Format as currency (`true` = context currency). |
|
|
242
|
+
| `iconOnly` | `boolean` | Only the arrow (the value becomes its accessible label). |
|
|
243
|
+
| `format` | `Intl.NumberFormatOptions` | `Intl.NumberFormat` options, e.g. `{ maximumFractionDigits: 0 }` or `{ style: 'percent' }`. |
|
|
244
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
245
|
+
| `clickable` | `RowOption<boolean>` | Renders the number as a link-style button that emits `click` (drill-down). |
|
|
246
|
+
|
|
247
|
+
### `date` — `dateRenderer`
|
|
248
|
+
|
|
249
|
+
A calendar day, in the grid's locale and time zone (date-only strings never shift a day). Align: `start` · filter type: `date`.
|
|
250
|
+
|
|
251
|
+
| Option | Type | Description |
|
|
252
|
+
|---|---|---|
|
|
253
|
+
| `format` | `Intl.DateTimeFormatOptions` | `Intl.DateTimeFormat` options, e.g. `{ dateStyle: 'medium' }`. |
|
|
254
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
255
|
+
|
|
256
|
+
### `datetime` — `dateTimeRenderer`
|
|
257
|
+
|
|
258
|
+
Date and time, on two lines by default. Align: `start` · filter type: `date`.
|
|
259
|
+
|
|
260
|
+
| Option | Type | Description |
|
|
261
|
+
|---|---|---|
|
|
262
|
+
| `milliseconds` | `boolean` | |
|
|
263
|
+
| `twoLines` | `boolean` | Date and time on two lines (default true). |
|
|
264
|
+
| `format` | `Intl.DateTimeFormatOptions` | `Intl.DateTimeFormat` options, e.g. `{ dateStyle: 'medium' }`. |
|
|
265
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
266
|
+
|
|
267
|
+
### `boolean` — `booleanRenderer`
|
|
268
|
+
|
|
269
|
+
Yes / no as text labels or icons. Align: `start` · filter type: `boolean`.
|
|
270
|
+
|
|
271
|
+
| Option | Type | Description |
|
|
272
|
+
|---|---|---|
|
|
273
|
+
| `trueLabel` | `string` | |
|
|
274
|
+
| `falseLabel` | `string` | |
|
|
275
|
+
| `nullLabel` | `string` | |
|
|
276
|
+
| `display` | `'text' \| 'icon'` | `text` (default): labels. `icon`: a check for true, nothing (or a cross) for false. |
|
|
277
|
+
| `falseIcon` | `boolean` | In icon mode, show a cross for false (default: nothing). |
|
|
278
|
+
|
|
279
|
+
### `status` — `statusRenderer`
|
|
280
|
+
|
|
281
|
+
A coloured status badge (tone from a map, a function or a constant). With `clickable`, emits `click`. Align: `start` · filter type: `set`.
|
|
282
|
+
|
|
283
|
+
| Option | Type | Description |
|
|
284
|
+
|---|---|---|
|
|
285
|
+
| `tone` | `ToneOption` | |
|
|
286
|
+
| `label` | `RowFn<string> \| Record<string, string>` | Label from a function, or a value → label map. |
|
|
287
|
+
| `dot` | `boolean` | |
|
|
288
|
+
| `variant` | `'soft' \| 'solid' \| 'outline'` | `soft` (default, tinted), `solid` (filled) or `outline`. |
|
|
289
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
290
|
+
| `clickable` | `RowOption<boolean>` | Badge becomes a button that emits `click`. |
|
|
291
|
+
|
|
292
|
+
### `link` — `linkRenderer`
|
|
293
|
+
|
|
294
|
+
A safe link (http(s), mailto, tel only), or a `<RouterLink>` with `to` when vue-router is installed. Align: `start` · filter type: `text`.
|
|
295
|
+
|
|
296
|
+
| Option | Type | Description |
|
|
297
|
+
|---|---|---|
|
|
298
|
+
| `href` | `RowFn<string \| undefined>` | |
|
|
299
|
+
| `to` | `RowFn<RouteTarget \| null \| undefined>` | Router location; rendered with `<RouterLink>` when vue-router is installed, else as an href. |
|
|
300
|
+
| `label` | `RowFn<string>` | |
|
|
301
|
+
| `target` | `'_self' \| '_blank'` | |
|
|
302
|
+
| `tooltip` | `RowFn<string \| undefined>` | |
|
|
303
|
+
|
|
304
|
+
### `icon` — `iconRenderer`
|
|
305
|
+
|
|
306
|
+
An icon component, fixed or picked per row. Align: `center` · filter type: `text`.
|
|
307
|
+
|
|
308
|
+
| Option | Type | Description |
|
|
309
|
+
|---|---|---|
|
|
310
|
+
| `icon` | `Component` | Static icon component. |
|
|
311
|
+
| `iconFor` | `RowFn<Component \| undefined>` | Picks the icon per row (wins over `icon`). Kept separate because functional components are functions too. |
|
|
312
|
+
| `show` | `RowFn<boolean>` | |
|
|
313
|
+
| `label` | `string \| RowFn<string>` | |
|
|
314
|
+
| `tone` | `Tone \| RowFn<Tone \| undefined>` | |
|
|
315
|
+
|
|
316
|
+
### `json` — `jsonRenderer`
|
|
317
|
+
|
|
318
|
+
A button that opens the value as escaped JSON in a dialog. Align: `start` · filter type: `text`.
|
|
319
|
+
|
|
320
|
+
| Option | Type | Description |
|
|
321
|
+
|---|---|---|
|
|
322
|
+
| `label` | `string` | |
|
|
323
|
+
| `dialogTitle` | `string \| RowFn<string>` | |
|
|
324
|
+
|
|
325
|
+
### `json-tree` — `jsonTreeRenderer`
|
|
326
|
+
|
|
327
|
+
A collapsible tree of nested data. Align: `start` · filter type: `text`.
|
|
328
|
+
|
|
329
|
+
| Option | Type | Description |
|
|
330
|
+
|---|---|---|
|
|
331
|
+
| `collapseAt` | `number` | Nodes deeper than this start collapsed. Default 1. |
|
|
332
|
+
| `maxDepth` | `number` | Deeper nodes are summarised (“3 items”) instead of expanded. Default unlimited. |
|
|
333
|
+
| `parseNested` | `boolean` | String values that contain JSON are shown as nested trees. |
|
|
334
|
+
| `collapsed` | `boolean` | Starts hidden behind a toggle button (labelled `toggleLabel`, default “More info”). |
|
|
335
|
+
| `toggleLabel` | `string` | |
|
|
336
|
+
| `emptyText` | `string` | Shown for null / empty values. Default: nothing. |
|
|
337
|
+
|
|
338
|
+
### `actions-menu` — `actionsMenuRenderer`
|
|
339
|
+
|
|
340
|
+
A `⋯` button with a keyboard-friendly menu. Emits the chosen item's `name`. Align: `center` · filter type: `text`.
|
|
341
|
+
|
|
342
|
+
| Option | Type | Description |
|
|
343
|
+
|---|---|---|
|
|
344
|
+
| `actions` | `MenuItem[] \| ((row: any) => MenuItem[])` | Menu items (actions and `{ separator: true }`), or a function of the row. |
|
|
345
|
+
| `label` | `string` | |
|
|
346
|
+
|
|
347
|
+
### `action-button` — `actionButtonRenderer`
|
|
348
|
+
|
|
349
|
+
One button per row. Emits its `action` (default `click`). Align: `start` · filter type: `text`.
|
|
350
|
+
|
|
351
|
+
| Option | Type | Description |
|
|
352
|
+
|---|---|---|
|
|
353
|
+
| `label` | `string \| RowFn<string>` | |
|
|
354
|
+
| `action` | `string` | Action name emitted on click. Default `click`. |
|
|
355
|
+
| `icon` | `Component` | |
|
|
356
|
+
| `tone` | `Tone` | |
|
|
357
|
+
| `disabled` | `RowFn<boolean>` | |
|
|
358
|
+
| `visible` | `RowFn<boolean>` | Hide the button for some rows. |
|
|
359
|
+
| `variant` | `ButtonVariant` | |
|
|
360
|
+
| `iconOnly` | `boolean` | Only the icon; the label becomes its accessible name and tooltip. |
|
|
361
|
+
|
|
362
|
+
### `multi-line` — `multiLineRenderer`
|
|
363
|
+
|
|
364
|
+
Stacked lines, each with its own style, link, badge, trend or action. Align: `start` · filter type: `text`.
|
|
365
|
+
|
|
366
|
+
| Option | Type | Description |
|
|
367
|
+
|---|---|---|
|
|
368
|
+
| `lines` | `RowFn<LineInput[] \| null \| undefined>` | Builds the lines; default: the value itself when it's an array. |
|
|
369
|
+
| `boldLines` | `number[]` | Indexes of lines to show in bold. |
|
|
370
|
+
| `ellipsis` | `boolean` | Each line on one row with ellipsis (default true). |
|
|
371
|
+
| `target` | `'_self' \| '_blank'` | |
|
|
372
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
373
|
+
|
|
374
|
+
### `copy` — `copyRenderer`
|
|
375
|
+
|
|
376
|
+
A value with a copy-to-clipboard button. Emits `copy` / `copy-error`. Align: `start` · filter type: `text`.
|
|
377
|
+
|
|
378
|
+
| Option | Type | Description |
|
|
379
|
+
|---|---|---|
|
|
380
|
+
| `copyValue` | `RowFn<string>` | What gets copied (default: the displayed text). |
|
|
381
|
+
| `iconOnly` | `boolean` | Only the copy button; the value becomes its tooltip. |
|
|
382
|
+
| `label` | `string` | Accessible name of the button. Default “Copy”. |
|
|
383
|
+
| `title` | `string` | Shown before the value in the tooltip, e.g. “Serial number”. |
|
|
384
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
385
|
+
|
|
386
|
+
### `chip` — `chipRenderer`
|
|
387
|
+
|
|
388
|
+
A chip in any colour (readable text picked by contrast), square, circle or pill. Align: `start` · filter type: `set`.
|
|
389
|
+
|
|
390
|
+
| Option | Type | Description |
|
|
391
|
+
|---|---|---|
|
|
392
|
+
| `color` | `RowOption<string \| null \| undefined>` | Any CSS colour (e.g. from an API); text colour is picked for contrast. |
|
|
393
|
+
| `tone` | `ToneOption` | Named tone instead of a raw colour. |
|
|
394
|
+
| `label` | `RowFn<string>` | |
|
|
395
|
+
| `tooltip` | `RowFn<string \| null \| undefined>` | |
|
|
396
|
+
| `shape` | `'square' \| 'circle' \| 'pill'` | |
|
|
397
|
+
| `size` | `string` | Box size for square/circle. Default `1.75rem`. |
|
|
398
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
399
|
+
|
|
400
|
+
### `checkbox` — `checkboxRenderer`
|
|
401
|
+
|
|
402
|
+
A controlled checkbox, with a tooltip when disabled. Emits `change` with the requested state. Align: `center` · filter type: `boolean`.
|
|
403
|
+
|
|
404
|
+
| Option | Type | Description |
|
|
405
|
+
|---|---|---|
|
|
406
|
+
| `checked` | `RowFn<boolean>` | Default: the value is truthy. |
|
|
407
|
+
| `disabled` | `RowOption<boolean>` | |
|
|
408
|
+
| `disabledReason` | `RowFn<string \| null \| undefined>` | Tooltip explaining why it's disabled. |
|
|
409
|
+
| `label` | `RowOption<string>` | Accessible name. Default: the column header. |
|
|
410
|
+
|
|
411
|
+
### `switch` — `switchRenderer`
|
|
412
|
+
|
|
413
|
+
A controlled on / off switch. Emits `change` with the requested state. Align: `center` · filter type: `boolean`.
|
|
414
|
+
|
|
415
|
+
| Option | Type | Description |
|
|
416
|
+
|---|---|---|
|
|
417
|
+
| `checked` | `RowFn<boolean>` | Default: the value is truthy. |
|
|
418
|
+
| `disabled` | `RowOption<boolean>` | |
|
|
419
|
+
| `disabledReason` | `RowFn<string \| null \| undefined>` | Tooltip explaining why it's disabled. |
|
|
420
|
+
| `label` | `RowOption<string>` | Accessible name. Default: the column header. |
|
|
421
|
+
|
|
422
|
+
### `radio` — `radioRenderer`
|
|
423
|
+
|
|
424
|
+
One selected row across the column (controlled). Emits `select`. Align: `center` · filter type: `boolean`.
|
|
425
|
+
|
|
426
|
+
| Option | Type | Description |
|
|
427
|
+
|---|---|---|
|
|
428
|
+
| `name` | `string` | Radio group name. Default: the column key. |
|
|
429
|
+
| `checked` | `RowFn<boolean>` | Default: the value is truthy. |
|
|
430
|
+
| `disabled` | `RowOption<boolean>` | |
|
|
431
|
+
| `disabledReason` | `RowFn<string \| null \| undefined>` | Tooltip explaining why it's disabled. |
|
|
432
|
+
| `label` | `RowOption<string>` | Accessible name. Default: the column header. |
|
|
433
|
+
|
|
434
|
+
### `edit` — `editRenderer`
|
|
435
|
+
|
|
436
|
+
A value with an edit button, for opening your own editor. Emits `edit`. Align: `start` · filter type: `text`.
|
|
437
|
+
|
|
438
|
+
| Option | Type | Description |
|
|
439
|
+
|---|---|---|
|
|
440
|
+
| `format` | `RowFn<string>` | Text shown next to the edit button (default: the value). |
|
|
441
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
442
|
+
| `label` | `string` | Accessible name of the button. Default “Edit”. |
|
|
443
|
+
| `disabled` | `RowOption<boolean>` | |
|
|
444
|
+
| `bold` | `boolean` | |
|
|
445
|
+
|
|
446
|
+
### `image` — `imageRenderer`
|
|
447
|
+
|
|
448
|
+
A thumbnail, with a placeholder when empty or broken. Align: `center` · filter type: `text`.
|
|
449
|
+
|
|
450
|
+
| Option | Type | Description |
|
|
451
|
+
|---|---|---|
|
|
452
|
+
| `src` | `RowFn<string \| null \| undefined>` | Default: the value. |
|
|
453
|
+
| `baseUrl` | `string` | Prefixed to relative paths (e.g. a CDN). |
|
|
454
|
+
| `alt` | `RowOption<string>` | |
|
|
455
|
+
| `size` | `string` | Default `2.5rem`. |
|
|
456
|
+
| `fit` | `'contain' \| 'cover'` | |
|
|
457
|
+
| `shape` | `'rounded' \| 'circle' \| 'square'` | |
|
|
458
|
+
|
|
459
|
+
### `code` — `codeRenderer`
|
|
460
|
+
|
|
461
|
+
Monospaced code, with JSON pretty-printing and highlighting. Align: `start` · filter type: `text`.
|
|
462
|
+
|
|
463
|
+
| Option | Type | Description |
|
|
464
|
+
|---|---|---|
|
|
465
|
+
| `language` | `'auto' \| 'json' \| 'text'` | `auto` (default): JSON for objects and JSON strings, plain text otherwise. |
|
|
466
|
+
| `lines` | `number` | Clamp to N lines (full text in a tooltip). |
|
|
467
|
+
| `indent` | `number` | JSON indent. Default 2. |
|
|
468
|
+
| `highlight` | `boolean` | Colour JSON tokens. Default true. |
|
|
469
|
+
|
|
470
|
+
### `button-group` — `buttonGroupRenderer`
|
|
471
|
+
|
|
472
|
+
Several buttons, fixed or per row. Emits the clicked button's `name`. Align: `start` · filter type: `text`.
|
|
473
|
+
|
|
474
|
+
| Option | Type | Description |
|
|
475
|
+
|---|---|---|
|
|
476
|
+
| `buttons` | `ButtonSpec[] \| ((row: any) => ButtonSpec[])` | |
|
|
477
|
+
|
|
478
|
+
### `icon-toggle` — `iconToggleRenderer`
|
|
479
|
+
|
|
480
|
+
A star / flag style on-off button (controlled). Emits `toggle`. Align: `center` · filter type: `boolean`.
|
|
481
|
+
|
|
482
|
+
| Option | Type | Description |
|
|
483
|
+
|---|---|---|
|
|
484
|
+
| `active` | `RowFn<boolean>` | Default: the value is truthy. |
|
|
485
|
+
| `icon` | `Component` | Default: an outlined star. |
|
|
486
|
+
| `activeIcon` | `Component` | Default: a filled star (or `icon`). |
|
|
487
|
+
| `label` | `RowOption<string>` | Accessible name. Default “Toggle”. |
|
|
488
|
+
| `activeTone` | `Tone` | Tone when active. Default `warning`. |
|
|
489
|
+
| `disabled` | `RowOption<boolean>` | |
|
|
490
|
+
|
|
491
|
+
### `details` — `detailsRenderer`
|
|
492
|
+
|
|
493
|
+
A status badge plus an info button with an anchored popover of label / value rows. Align: `start` · filter type: `text`.
|
|
494
|
+
|
|
495
|
+
| Option | Type | Description |
|
|
496
|
+
|---|---|---|
|
|
497
|
+
| `tone` | `ToneOption` | Summary badge tone, like `status`. |
|
|
498
|
+
| `label` | `RowFn<string>` | |
|
|
499
|
+
| `items` | `RowFn<DetailItem[] \| null \| undefined>` | Popover rows. Empty → no info button. |
|
|
500
|
+
| `title` | `RowOption<string>` | Popover heading. Default: the column header. |
|
|
501
|
+
| `triggerLabel` | `string` | Accessible name of the info button. Default “Details”. |
|
|
502
|
+
|
|
503
|
+
### `list` — `listRenderer`
|
|
504
|
+
|
|
505
|
+
The first items of a list, with a “+N more” toggle. Emits `expand`. Align: `start` · filter type: `text`.
|
|
506
|
+
|
|
507
|
+
| Option | Type | Description |
|
|
508
|
+
|---|---|---|
|
|
509
|
+
| `items` | `RowFn<unknown[] \| null \| undefined>` | Default: the value when it's an array. |
|
|
510
|
+
| `itemLabel` | `RowFn<string>` | |
|
|
511
|
+
| `max` | `number` | Items shown before “+N more”. Default 1. |
|
|
512
|
+
| `placeholder` | `string` | Shown when the value is empty. |
|
|
513
|
+
|
|
514
|
+
## Types
|
|
515
|
+
|
|
516
|
+
### `VirtualOptions`
|
|
517
|
+
|
|
518
|
+
| Field | Type | Description |
|
|
519
|
+
|---|---|---|
|
|
520
|
+
| `rowHeight` | `number` | Fixed row height in px. |
|
|
521
|
+
| `overscan`? | `number` | Extra rows rendered above/below the viewport. Default 6. |
|
|
522
|
+
| `detailHeight`? | `number` | Estimated height in px of a detail row (`#detail` slot) until it has been rendered and; measured. Default 4 × `rowHeight`. Data rows always have `rowHeight`. |
|
|
523
|
+
|
|
524
|
+
### `PinnedRowsState`
|
|
525
|
+
|
|
526
|
+
| Field | Type | Description |
|
|
527
|
+
|---|---|---|
|
|
528
|
+
| `top`? | `RowKey[]` | |
|
|
529
|
+
| `bottom`? | `RowKey[]` | |
|
|
530
|
+
|
|
531
|
+
### `ColumnState`
|
|
532
|
+
|
|
533
|
+
| Field | Type | Description |
|
|
534
|
+
|---|---|---|
|
|
535
|
+
| `order` | `string[]` | Column keys in display order (all known columns, visible or not). |
|
|
536
|
+
| `hidden` | `string[]` | Keys of hidden columns. |
|
|
537
|
+
| `pinned`? | `Record<string, PinSide \| null>` | Runtime pin overrides (e.g. from the header menu). `null` = explicitly unpinned; a missing key; falls back to the column's `pinned` definition. Optional so older persisted state still loads. |
|
|
538
|
+
| `widths`? | `Record<string, string>` | Widths the user resized columns to (CSS lengths, e.g. `'240px'`). Column resizing feature. |
|
|
539
|
+
|
|
540
|
+
### `SortState`
|
|
541
|
+
|
|
542
|
+
| Field | Type | Description |
|
|
543
|
+
|---|---|---|
|
|
544
|
+
| `key` | `string` | |
|
|
545
|
+
| `dir` | `SortDir` | |
|
|
546
|
+
|
|
547
|
+
### `ColumnFilterOptions`
|
|
548
|
+
|
|
549
|
+
| Field | Type | Description |
|
|
550
|
+
|---|---|---|
|
|
551
|
+
| `type`? | `FilterType` | |
|
|
552
|
+
| `options`? | `readonly FilterOption[] \| FilterOptionsLoader` | Choices for a `set` filter: a list, or a loader called with the search text (e.g. from a; backend — honour `signal`). Default: distinct values from the rows. |
|
|
553
|
+
| `placeholder`? | `string` | Placeholder of the filter-row input. |
|
|
554
|
+
|
|
555
|
+
### `FilterOption`
|
|
556
|
+
|
|
557
|
+
| Field | Type | Description |
|
|
558
|
+
|---|---|---|
|
|
559
|
+
| `value` | `unknown` | |
|
|
560
|
+
| `label`? | `string` | |
|
|
561
|
+
| `count`? | `number` | Shown next to the option (e.g. number of rows). |
|
|
562
|
+
|
|
563
|
+
### `MenuAction`
|
|
564
|
+
|
|
565
|
+
| Field | Type | Description |
|
|
566
|
+
|---|---|---|
|
|
567
|
+
| `name` | `string` | Emitted as the action name. |
|
|
568
|
+
| `label` | `string` | |
|
|
569
|
+
| `disabled`? | `boolean` | |
|
|
570
|
+
| `tone`? | `MenuTone` | |
|
|
571
|
+
| `icon`? | `Component` | |
|
|
572
|
+
| `hint`? | `string` | Shown right-aligned, e.g. a shortcut hint. |
|
|
573
|
+
|
|
574
|
+
### `CellContext`
|
|
575
|
+
|
|
576
|
+
| Field | Type | Description |
|
|
577
|
+
|---|---|---|
|
|
578
|
+
| `row` | `T` | |
|
|
579
|
+
| `rowKey` | `RowKey` | |
|
|
580
|
+
| `column` | `ColumnDef<T>` | |
|
|
581
|
+
| `value` | `unknown` | |
|
|
582
|
+
|
|
583
|
+
### `CellActionEvent`
|
|
584
|
+
|
|
585
|
+
| Field | Type | Description |
|
|
586
|
+
|---|---|---|
|
|
587
|
+
| `name` | `string` | |
|
|
588
|
+
| `payload` | `unknown` | |
|
|
589
|
+
| `row` | `T` | |
|
|
590
|
+
| `rowKey` | `RowKey` | |
|
|
591
|
+
| `column` | `ColumnDef<T>` | |
|
|
592
|
+
|
|
593
|
+
### `CellClickEvent`
|
|
594
|
+
|
|
595
|
+
| Field | Type | Description |
|
|
596
|
+
|---|---|---|
|
|
597
|
+
| `row` | `T` | |
|
|
598
|
+
| `rowKey` | `RowKey` | |
|
|
599
|
+
| `column` | `ColumnDef<T>` | |
|
|
600
|
+
| `value` | `unknown` | |
|
|
601
|
+
| `event` | `MouseEvent \| KeyboardEvent` | |
|
|
602
|
+
|
|
603
|
+
### `ContextActionEvent`
|
|
604
|
+
|
|
605
|
+
| Field | Type | Description |
|
|
606
|
+
|---|---|---|
|
|
607
|
+
| `name` | `string` | |
|
|
608
|
+
| `item` | `MenuAction` | |
|
|
609
|
+
| `row` | `T` | |
|
|
610
|
+
| `rowKey` | `RowKey` | |
|
|
611
|
+
| `column` | `ColumnDef<T>` | |
|
|
612
|
+
| `value` | `unknown` | |
|
|
613
|
+
|
|
614
|
+
### `HeaderActionEvent`
|
|
615
|
+
|
|
616
|
+
| Field | Type | Description |
|
|
617
|
+
|---|---|---|
|
|
618
|
+
| `name` | `string` | |
|
|
619
|
+
| `item` | `MenuAction` | |
|
|
620
|
+
| `column` | `ColumnDef<T>` | |
|
|
621
|
+
|
|
622
|
+
### `VueGridConfig`
|
|
623
|
+
|
|
624
|
+
| Field | Type | Description |
|
|
625
|
+
|---|---|---|
|
|
626
|
+
| `renderers`? | `CellRendererDefinition[]` | |
|
|
627
|
+
| `features`? | `readonly GridFeature[]` | Features every grid in the app gets (`allFeatures` for all of them). |
|
|
628
|
+
| `locale`? | `string` | |
|
|
629
|
+
| `currency`? | `string` | |
|
|
630
|
+
| `timeZone`? | `string` | |
|
|
631
|
+
| `density`? | `Density` | |
|
|
632
|
+
|