@vuu-ui/vuu-table-extras 5.0.0-alpha.2 → 5.0.0-alpha.4

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.
Files changed (29) hide show
  1. package/package.json +13 -13
  2. package/src/bulk-edit-dialog/useBulkEditDialog.js +93 -0
  3. package/src/csv-upload/parse/csv-parse.js +6 -2
  4. package/src/csv-upload/useCsvUpload.js +17 -0
  5. package/src/editable-table/EditableTable.css.js +41 -0
  6. package/src/editable-table/EditableTable.js +176 -0
  7. package/src/editable-table/EditableTableLayout.js +61 -0
  8. package/src/index.js +4 -0
  9. package/src/inline-add-row/useInlineAddRow.js +0 -8
  10. package/src/table-editor/TableEditorContext.js +9 -0
  11. package/src/table-editor/TableEditorControls.js +86 -0
  12. package/src/table-editor/TableEditorForm.js +142 -0
  13. package/src/table-editor/TableEditorLayout.css.js +16 -0
  14. package/src/table-editor/TableEditorLayout.js +30 -0
  15. package/src/table-editor/TableEditorProvider.js +434 -0
  16. package/src/table-editor/TableEditorTable.js +112 -0
  17. package/src/table-editor/index.js +5 -0
  18. package/types/bulk-edit-dialog/useBulkEditDialog.d.ts +27 -0
  19. package/types/editable-table/EditableTable.d.ts +178 -0
  20. package/types/editable-table/EditableTableLayout.d.ts +41 -0
  21. package/types/index.d.ts +4 -0
  22. package/types/inline-add-row/useInlineAddRow.d.ts +1 -0
  23. package/types/table-editor/TableEditorContext.d.ts +100 -0
  24. package/types/table-editor/TableEditorControls.d.ts +43 -0
  25. package/types/table-editor/TableEditorForm.d.ts +58 -0
  26. package/types/table-editor/TableEditorLayout.d.ts +10 -0
  27. package/types/table-editor/TableEditorProvider.d.ts +57 -0
  28. package/types/table-editor/TableEditorTable.d.ts +24 -0
  29. package/types/table-editor/index.d.ts +5 -0
@@ -0,0 +1,24 @@
1
+ import { type EditableColumnsHookProps } from "@vuu-ui/vuu-data-editing";
2
+ import { type TableProps } from "@vuu-ui/vuu-table";
3
+ export interface TableEditorTableProps extends Omit<TableProps, "customHeader" | "dataSource" | "isRowSelectable" | "selectionModel">, Partial<Pick<EditableColumnsHookProps, "undoColumn">> {
4
+ /**
5
+ * Session table editing: show a row, above the column headers, for adding
6
+ * rows.
7
+ */
8
+ showInlineAddRow?: boolean;
9
+ }
10
+ /**
11
+ * The Table of the enclosing `EditableTable`, bound to its dataSource and
12
+ * mode. Its `config.columns` are also used by generated forms, for labels,
13
+ * editors etc.
14
+ *
15
+ * - Inline session editing: cells become editable in edit mode, edited,
16
+ * added and deleted rows are styled, and rows can be checked for deletion
17
+ * when `allowDelete` is set on the provider.
18
+ * - Inline direct editing: cells are editable in edit mode, and each edit is
19
+ * sent straight to the dataSource. `showInlineAddRow` and `undoColumn`
20
+ * are ignored.
21
+ * - Form editing: single selection, which selects the row shown in
22
+ * `TableEditorForm`. Selection is locked while the form is being edited.
23
+ */
24
+ export declare const TableEditorTable: (props: TableEditorTableProps) => import("react").JSX.Element;
@@ -0,0 +1,5 @@
1
+ export { type TableEditorCreateStrategy, type TableEditorEditModel, type TableEditorEditStrategy, type TableEditorMode, type TableEditorPanelVisibility, type TableEditorState, useTableEditor, } from "./TableEditorContext";
2
+ export { TableEditorButtons, type TableEditorButtonsProps, TableEditorEditButton, type TableEditorEditButtonProps, TableEditorModeToggle, type TableEditorModeToggleProps, TableEditorNewButton, type TableEditorNewButtonProps, TableEditorPanelCloseButton, } from "./TableEditorControls";
3
+ export { type TableEditorCreateFormProps, type TableEditorField, TableEditorCreateForm, TableEditorForm, type TableEditorFormProps, } from "./TableEditorForm";
4
+ export { TableEditorPlaceholder, type TableEditorPlaceholderProps, TableEditorToolbar, type TableEditorToolbarProps, } from "./TableEditorLayout";
5
+ export { TableEditorTable, type TableEditorTableProps, } from "./TableEditorTable";