@1771technologies/lytenyte-pro 1.0.20 → 2.0.0-dev.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/css/all-colors.css +8 -0
- package/css/components/button.css +176 -0
- package/css/components/checkbox.css +54 -0
- package/css/components/input.css +64 -0
- package/css/components/tree-view.css +108 -0
- package/css/components.css +300 -0
- package/css/cotton-candy.css +1 -0
- package/css/dark.css +1 -0
- package/css/design.css +1 -0
- package/css/fonts.css +1 -0
- package/css/grid-full.css +3 -0
- package/css/grid.css +81 -0
- package/css/light-dark.css +3 -0
- package/css/light.css +1 -0
- package/css/pill-manager.css +184 -0
- package/css/shadcn-vars.css +1 -0
- package/css/shadcn.css +1 -0
- package/css/teal.css +1 -0
- package/css/term.css +1 -0
- package/css/tw.css +1 -0
- package/package.json +29 -16
- package/dist/+types.d.ts +0 -6177
- package/dist/+types.js +0 -1
- package/dist/__play__/cell-selections/cell-selection.play.d.ts +0 -5
- package/dist/__play__/cell-selections/cell-selection.play.js +0 -80
- package/dist/__play__/filter-select/filter-select.play.d.ts +0 -4
- package/dist/__play__/filter-select/filter-select.play.js +0 -76
- package/dist/__play__/test-utils/bank-data-smaller.d.ts +0 -19
- package/dist/__play__/test-utils/bank-data-smaller.js +0 -252
- package/dist/__play__/test-utils/row-handler.d.ts +0 -6
- package/dist/__play__/test-utils/row-handler.js +0 -32
- package/dist/cell-selection/adjust-rect-for-row-and-cell-span.d.ts +0 -2
- package/dist/cell-selection/adjust-rect-for-row-and-cell-span.js +0 -43
- package/dist/cell-selection/are-rects-equal.d.ts +0 -2
- package/dist/cell-selection/are-rects-equal.js +0 -6
- package/dist/cell-selection/bound-selection-rect.d.ts +0 -2
- package/dist/cell-selection/bound-selection-rect.js +0 -17
- package/dist/cell-selection/cell-selection-containers.d.ts +0 -3
- package/dist/cell-selection/cell-selection-containers.js +0 -91
- package/dist/cell-selection/cell-selection-driver.d.ts +0 -1
- package/dist/cell-selection/cell-selection-driver.js +0 -289
- package/dist/cell-selection/cell-style-row.d.ts +0 -8
- package/dist/cell-selection/cell-style-row.js +0 -84
- package/dist/cell-selection/deselect-rect-range.d.ts +0 -2
- package/dist/cell-selection/deselect-rect-range.js +0 -43
- package/dist/cell-selection/expand-cell-selection-down.d.ts +0 -5
- package/dist/cell-selection/expand-cell-selection-down.js +0 -39
- package/dist/cell-selection/expand-cell-selection-end.d.ts +0 -5
- package/dist/cell-selection/expand-cell-selection-end.js +0 -40
- package/dist/cell-selection/expand-cell-selection-start.d.ts +0 -5
- package/dist/cell-selection/expand-cell-selection-start.js +0 -39
- package/dist/cell-selection/expand-cell-selection-up.d.ts +0 -5
- package/dist/cell-selection/expand-cell-selection-up.js +0 -39
- package/dist/cell-selection/full-width-start-end-index.d.ts +0 -2
- package/dist/cell-selection/full-width-start-end-index.js +0 -5
- package/dist/cell-selection/get-root-cell.d.ts +0 -2
- package/dist/cell-selection/get-root-cell.js +0 -6
- package/dist/cell-selection/index.d.ts +0 -18
- package/dist/cell-selection/index.js +0 -18
- package/dist/cell-selection/is-bottom-rect.d.ts +0 -2
- package/dist/cell-selection/is-bottom-rect.js +0 -7
- package/dist/cell-selection/is-center-col-rect.d.ts +0 -5
- package/dist/cell-selection/is-center-col-rect.js +0 -5
- package/dist/cell-selection/is-center-rect.d.ts +0 -2
- package/dist/cell-selection/is-center-rect.js +0 -5
- package/dist/cell-selection/is-end-rect.d.ts +0 -5
- package/dist/cell-selection/is-end-rect.js +0 -4
- package/dist/cell-selection/is-overlapping-rect.d.ts +0 -2
- package/dist/cell-selection/is-overlapping-rect.js +0 -6
- package/dist/cell-selection/is-start-rect.d.ts +0 -5
- package/dist/cell-selection/is-start-rect.js +0 -4
- package/dist/cell-selection/is-top-rect.d.ts +0 -2
- package/dist/cell-selection/is-top-rect.js +0 -4
- package/dist/cell-selection/is-within-selection-rect.d.ts +0 -2
- package/dist/cell-selection/is-within-selection-rect.js +0 -3
- package/dist/cell-selection/split-cell-selection-rect.d.ts +0 -46
- package/dist/cell-selection/split-cell-selection-rect.js +0 -88
- package/dist/cell-selection/split-on-pivot.d.ts +0 -3
- package/dist/cell-selection/split-on-pivot.js +0 -50
- package/dist/cell-selection/update-additive-cell-selection.d.ts +0 -5
- package/dist/cell-selection/update-additive-cell-selection.js +0 -23
- package/dist/cell-selection/use-edge-scroll.d.ts +0 -10
- package/dist/cell-selection/use-edge-scroll.js +0 -66
- package/dist/column-manager/branch-lookup-context.d.ts +0 -4
- package/dist/column-manager/branch-lookup-context.js +0 -3
- package/dist/column-manager/branch.d.ts +0 -15
- package/dist/column-manager/branch.js +0 -54
- package/dist/column-manager/column-manager.d.ts +0 -13
- package/dist/column-manager/column-manager.js +0 -18
- package/dist/column-manager/context.d.ts +0 -7
- package/dist/column-manager/context.js +0 -3
- package/dist/column-manager/label.d.ts +0 -5
- package/dist/column-manager/label.js +0 -18
- package/dist/column-manager/leaf.d.ts +0 -6
- package/dist/column-manager/leaf.js +0 -58
- package/dist/column-manager/move-handle.d.ts +0 -5
- package/dist/column-manager/move-handle.js +0 -72
- package/dist/column-manager/panel.d.ts +0 -1
- package/dist/column-manager/panel.js +0 -2
- package/dist/column-manager/root.d.ts +0 -8
- package/dist/column-manager/root.js +0 -7
- package/dist/column-manager/use-column-manager.d.ts +0 -10
- package/dist/column-manager/use-column-manager.js +0 -24
- package/dist/column-manager/use-columns-from-context.d.ts +0 -3
- package/dist/column-manager/use-columns-from-context.js +0 -23
- package/dist/column-manager/visibility-checkbox.d.ts +0 -9
- package/dist/column-manager/visibility-checkbox.js +0 -30
- package/dist/context.d.ts +0 -11
- package/dist/context.js +0 -5
- package/dist/filter-selects/apply.d.ts +0 -7
- package/dist/filter-selects/apply.js +0 -22
- package/dist/filter-selects/clear.d.ts +0 -7
- package/dist/filter-selects/clear.js +0 -22
- package/dist/filter-selects/context.d.ts +0 -13
- package/dist/filter-selects/context.js +0 -3
- package/dist/filter-selects/filter-combinator.d.ts +0 -10
- package/dist/filter-selects/filter-combinator.js +0 -19
- package/dist/filter-selects/filter-row-context.d.ts +0 -30
- package/dist/filter-selects/filter-row-context.js +0 -3
- package/dist/filter-selects/filter-row.d.ts +0 -13
- package/dist/filter-selects/filter-row.js +0 -118
- package/dist/filter-selects/index.d.ts +0 -22
- package/dist/filter-selects/index.js +0 -20
- package/dist/filter-selects/is-complete-filter.d.ts +0 -2
- package/dist/filter-selects/is-complete-filter.js +0 -5
- package/dist/filter-selects/operator-select.d.ts +0 -14
- package/dist/filter-selects/operator-select.js +0 -25
- package/dist/filter-selects/options.d.ts +0 -9
- package/dist/filter-selects/options.js +0 -100
- package/dist/filter-selects/reset.d.ts +0 -7
- package/dist/filter-selects/reset.js +0 -22
- package/dist/filter-selects/root.d.ts +0 -14
- package/dist/filter-selects/root.js +0 -5
- package/dist/filter-selects/to-filter-item.d.ts +0 -3
- package/dist/filter-selects/to-filter-item.js +0 -7
- package/dist/filter-selects/use-filter-select.d.ts +0 -38
- package/dist/filter-selects/use-filter-select.js +0 -167
- package/dist/filter-selects/value-input.d.ts +0 -12
- package/dist/filter-selects/value-input.js +0 -27
- package/dist/filter-tree/branch.d.ts +0 -13
- package/dist/filter-tree/branch.js +0 -21
- package/dist/filter-tree/context.d.ts +0 -27
- package/dist/filter-tree/context.js +0 -5
- package/dist/filter-tree/filter-tree.d.ts +0 -14
- package/dist/filter-tree/filter-tree.js +0 -18
- package/dist/filter-tree/hooks/use-filter-tree.d.ts +0 -38
- package/dist/filter-tree/hooks/use-filter-tree.js +0 -101
- package/dist/filter-tree/hooks/use-tree-item.d.ts +0 -8
- package/dist/filter-tree/hooks/use-tree-item.js +0 -116
- package/dist/filter-tree/inclusion-checkbox.d.ts +0 -9
- package/dist/filter-tree/inclusion-checkbox.js +0 -14
- package/dist/filter-tree/label.d.ts +0 -5
- package/dist/filter-tree/label.js +0 -18
- package/dist/filter-tree/leaf.d.ts +0 -6
- package/dist/filter-tree/leaf.js +0 -14
- package/dist/filter-tree/root.d.ts +0 -13
- package/dist/filter-tree/root.js +0 -30
- package/dist/grid/cell.d.ts +0 -6
- package/dist/grid/cell.js +0 -3
- package/dist/grid/dialog-driver.d.ts +0 -1
- package/dist/grid/dialog-driver.js +0 -21
- package/dist/grid/header-cell.d.ts +0 -10
- package/dist/grid/header-cell.js +0 -3
- package/dist/grid/header-group-cell.d.ts +0 -6
- package/dist/grid/header-group-cell.js +0 -3
- package/dist/grid/header-row.d.ts +0 -5
- package/dist/grid/header-row.js +0 -2
- package/dist/grid/header.d.ts +0 -1
- package/dist/grid/header.js +0 -2
- package/dist/grid/popover-driver.d.ts +0 -1
- package/dist/grid/popover-driver.js +0 -21
- package/dist/grid/root.d.ts +0 -8
- package/dist/grid/root.js +0 -37
- package/dist/grid/row-full-width.d.ts +0 -9
- package/dist/grid/row-full-width.js +0 -3
- package/dist/grid/row.d.ts +0 -8
- package/dist/grid/row.js +0 -3
- package/dist/grid/rows-container.d.ts +0 -1
- package/dist/grid/rows-container.js +0 -2
- package/dist/grid/rows-sections.d.ts +0 -3
- package/dist/grid/rows-sections.js +0 -13
- package/dist/grid/viewport.d.ts +0 -1
- package/dist/grid/viewport.js +0 -9
- package/dist/grid-box/+types.d.ts +0 -15
- package/dist/grid-box/+types.js +0 -1
- package/dist/grid-box/context.d.ts +0 -9
- package/dist/grid-box/context.js +0 -3
- package/dist/grid-box/grid-box.d.ts +0 -12
- package/dist/grid-box/grid-box.js +0 -14
- package/dist/grid-box/item.d.ts +0 -10
- package/dist/grid-box/item.js +0 -62
- package/dist/grid-box/panel.d.ts +0 -1
- package/dist/grid-box/panel.js +0 -9
- package/dist/grid-box/root.d.ts +0 -9
- package/dist/grid-box/root.js +0 -8
- package/dist/grid-box/use-aggregation-box-items.d.ts +0 -18
- package/dist/grid-box/use-aggregation-box-items.js +0 -61
- package/dist/grid-box/use-column-box-items.d.ts +0 -34
- package/dist/grid-box/use-column-box-items.js +0 -78
- package/dist/grid-box/use-row-group-box-items.d.ts +0 -18
- package/dist/grid-box/use-row-group-box-items.js +0 -169
- package/dist/grid-provider/context.d.ts +0 -5
- package/dist/grid-provider/context.js +0 -2
- package/dist/grid-provider/provider.d.ts +0 -3
- package/dist/grid-provider/provider.js +0 -2
- package/dist/grid-provider/use-grid.d.ts +0 -3
- package/dist/grid-provider/use-grid.js +0 -3
- package/dist/grid.d.ts +0 -18
- package/dist/grid.js +0 -28
- package/dist/icons/index.d.ts +0 -1
- package/dist/icons/index.js +0 -1
- package/dist/index.d.ts +0 -14
- package/dist/index.js +0 -14
- package/dist/license/index.d.ts +0 -1
- package/dist/license/index.js +0 -1
- package/dist/license/license.d.ts +0 -3
- package/dist/license/license.js +0 -215
- package/dist/license/md5-hash.d.ts +0 -9
- package/dist/license/md5-hash.js +0 -167
- package/dist/license.d.ts +0 -3
- package/dist/license.js +0 -214
- package/dist/listbox/context.d.ts +0 -6
- package/dist/listbox/context.js +0 -3
- package/dist/listbox/item.d.ts +0 -1
- package/dist/listbox/item.js +0 -25
- package/dist/listbox/panel.d.ts +0 -1
- package/dist/listbox/panel.js +0 -50
- package/dist/listbox/root.d.ts +0 -6
- package/dist/listbox/root.js +0 -12
- package/dist/row-data-source-client/+constants.d.ts +0 -2
- package/dist/row-data-source-client/+constants.js +0 -2
- package/dist/row-data-source-client/+types.d.ts +0 -27
- package/dist/row-data-source-client/+types.js +0 -1
- package/dist/row-data-source-client/built-ins/avg.d.ts +0 -10
- package/dist/row-data-source-client/built-ins/avg.js +0 -16
- package/dist/row-data-source-client/built-ins/built-ins.d.ts +0 -44
- package/dist/row-data-source-client/built-ins/built-ins.js +0 -44
- package/dist/row-data-source-client/built-ins/count.d.ts +0 -10
- package/dist/row-data-source-client/built-ins/count.js +0 -16
- package/dist/row-data-source-client/built-ins/first.d.ts +0 -10
- package/dist/row-data-source-client/built-ins/first.js +0 -12
- package/dist/row-data-source-client/built-ins/group.d.ts +0 -1
- package/dist/row-data-source-client/built-ins/group.js +0 -3
- package/dist/row-data-source-client/built-ins/last.d.ts +0 -10
- package/dist/row-data-source-client/built-ins/last.js +0 -12
- package/dist/row-data-source-client/built-ins/max.d.ts +0 -11
- package/dist/row-data-source-client/built-ins/max.js +0 -25
- package/dist/row-data-source-client/built-ins/min.d.ts +0 -11
- package/dist/row-data-source-client/built-ins/min.js +0 -25
- package/dist/row-data-source-client/built-ins/sum.d.ts +0 -10
- package/dist/row-data-source-client/built-ins/sum.js +0 -21
- package/dist/row-data-source-client/filter/+types.d.ts +0 -23
- package/dist/row-data-source-client/filter/+types.js +0 -1
- package/dist/row-data-source-client/filter/compute-filtered-rows.d.ts +0 -2
- package/dist/row-data-source-client/filter/compute-filtered-rows.js +0 -109
- package/dist/row-data-source-client/pivots/create-agg-model.d.ts +0 -6
- package/dist/row-data-source-client/pivots/create-agg-model.js +0 -13
- package/dist/row-data-source-client/pivots/create-pivot-columns-from-paths.d.ts +0 -2
- package/dist/row-data-source-client/pivots/create-pivot-columns-from-paths.js +0 -50
- package/dist/row-data-source-client/pivots/create-pivot-columns.d.ts +0 -2
- package/dist/row-data-source-client/pivots/create-pivot-columns.js +0 -22
- package/dist/row-data-source-client/pivots/create-pivot-tree.d.ts +0 -2
- package/dist/row-data-source-client/pivots/create-pivot-tree.js +0 -23
- package/dist/row-data-source-client/tree/client-tree.d.ts +0 -18
- package/dist/row-data-source-client/tree/client-tree.js +0 -76
- package/dist/row-data-source-client/tree/evaluator-aggregation.d.ts +0 -2
- package/dist/row-data-source-client/tree/evaluator-aggregation.js +0 -8
- package/dist/row-data-source-client/tree/evaluator-group.d.ts +0 -2
- package/dist/row-data-source-client/tree/evaluator-group.js +0 -9
- package/dist/row-data-source-client/tree/traverse.d.ts +0 -2
- package/dist/row-data-source-client/tree/traverse.js +0 -22
- package/dist/row-data-source-client/use-client-data-source-paginated.d.ts +0 -10
- package/dist/row-data-source-client/use-client-data-source-paginated.js +0 -573
- package/dist/row-data-source-client/use-client-data-source.d.ts +0 -10
- package/dist/row-data-source-client/use-client-data-source.js +0 -667
- package/dist/row-data-source-client/use-client-tree-data-source.d.ts +0 -9
- package/dist/row-data-source-client/use-client-tree-data-source.js +0 -512
- package/dist/row-data-source-server/async-tree/+constants.async-tree.d.ts +0 -1
- package/dist/row-data-source-server/async-tree/+constants.async-tree.js +0 -1
- package/dist/row-data-source-server/async-tree/+types.async-tree.d.ts +0 -59
- package/dist/row-data-source-server/async-tree/+types.async-tree.js +0 -1
- package/dist/row-data-source-server/async-tree/apply-delete-action-to-tree.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/apply-delete-action-to-tree.js +0 -27
- package/dist/row-data-source-server/async-tree/apply-set-action-to-tree.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/apply-set-action-to-tree.js +0 -36
- package/dist/row-data-source-server/async-tree/check-set-action-item-keys-are-unique.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/check-set-action-item-keys-are-unique.js +0 -24
- package/dist/row-data-source-server/async-tree/check-set-action-item-keys-are-valid.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/check-set-action-item-keys-are-valid.js +0 -14
- package/dist/row-data-source-server/async-tree/check-set-action-item-keys-fit.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/check-set-action-item-keys-fit.js +0 -18
- package/dist/row-data-source-server/async-tree/check-set-action-item-kinds.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/check-set-action-item-kinds.js +0 -14
- package/dist/row-data-source-server/async-tree/get-parent-node-by-path.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/get-parent-node-by-path.js +0 -18
- package/dist/row-data-source-server/async-tree/is-set-action-a-no-op-on-node.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/is-set-action-a-no-op-on-node.js +0 -3
- package/dist/row-data-source-server/async-tree/make-async-tree.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/make-async-tree.js +0 -19
- package/dist/row-data-source-server/async-tree/maybe-apply-parent-remove-self.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/maybe-apply-parent-remove-self.js +0 -8
- package/dist/row-data-source-server/async-tree/maybe-apply-resize.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/maybe-apply-resize.js +0 -17
- package/dist/row-data-source-server/async-tree/maybe-apply-set-action-items.d.ts +0 -2
- package/dist/row-data-source-server/async-tree/maybe-apply-set-action-items.js +0 -52
- package/dist/row-data-source-server/range-tree/range-tree.d.ts +0 -66
- package/dist/row-data-source-server/range-tree/range-tree.js +0 -102
- package/dist/row-data-source-server/server-data.d.ts +0 -70
- package/dist/row-data-source-server/server-data.js +0 -519
- package/dist/row-data-source-server/use-server-data-source.d.ts +0 -3
- package/dist/row-data-source-server/use-server-data-source.js +0 -413
- package/dist/row-data-source-server/utils/get-node-depth.d.ts +0 -2
- package/dist/row-data-source-server/utils/get-node-depth.js +0 -9
- package/dist/row-data-source-server/utils/get-node-path.d.ts +0 -2
- package/dist/row-data-source-server/utils/get-node-path.js +0 -9
- package/dist/row-data-source-server/utils/get-request-id.d.ts +0 -1
- package/dist/row-data-source-server/utils/get-request-id.js +0 -6
- package/dist/sort-manager/+types.d.ts +0 -13
- package/dist/sort-manager/+types.js +0 -1
- package/dist/sort-manager/context.d.ts +0 -14
- package/dist/sort-manager/context.js +0 -5
- package/dist/sort-manager/hooks/use-sort-manager.d.ts +0 -15
- package/dist/sort-manager/hooks/use-sort-manager.js +0 -56
- package/dist/sort-manager/hooks/use-sort-row-item.d.ts +0 -51
- package/dist/sort-manager/hooks/use-sort-row-item.js +0 -145
- package/dist/sort-manager/hooks/use-sortable-column-items.d.ts +0 -5
- package/dist/sort-manager/hooks/use-sortable-column-items.js +0 -13
- package/dist/sort-manager/root.d.ts +0 -3
- package/dist/sort-manager/root.js +0 -14
- package/dist/sort-manager/sort-add.d.ts +0 -8
- package/dist/sort-manager/sort-add.js +0 -14
- package/dist/sort-manager/sort-apply.d.ts +0 -7
- package/dist/sort-manager/sort-apply.js +0 -24
- package/dist/sort-manager/sort-cancel.d.ts +0 -7
- package/dist/sort-manager/sort-cancel.js +0 -27
- package/dist/sort-manager/sort-clear.d.ts +0 -7
- package/dist/sort-manager/sort-clear.js +0 -22
- package/dist/sort-manager/sort-column-select.d.ts +0 -10
- package/dist/sort-manager/sort-column-select.js +0 -20
- package/dist/sort-manager/sort-direction-select.d.ts +0 -10
- package/dist/sort-manager/sort-direction-select.js +0 -24
- package/dist/sort-manager/sort-manager.d.ts +0 -16
- package/dist/sort-manager/sort-manager.js +0 -26
- package/dist/sort-manager/sort-remove.d.ts +0 -7
- package/dist/sort-manager/sort-remove.js +0 -14
- package/dist/sort-manager/sort-row.d.ts +0 -5
- package/dist/sort-manager/sort-row.js +0 -7
- package/dist/sort-manager/sort-rows.d.ts +0 -1
- package/dist/sort-manager/sort-rows.js +0 -6
- package/dist/sort-manager/sort-value-select.d.ts +0 -11
- package/dist/sort-manager/sort-value-select.js +0 -25
- package/dist/sort-manager/utils/sort-item-to-sort-model.d.ts +0 -3
- package/dist/sort-manager/utils/sort-item-to-sort-model.js +0 -62
- package/dist/sort-manager/utils/sort-model-to-sort-items.d.ts +0 -3
- package/dist/sort-manager/utils/sort-model-to-sort-items.js +0 -50
- package/dist/state/+types.d.ts +0 -36
- package/dist/state/+types.js +0 -1
- package/dist/state/api/cell-root.d.ts +0 -5
- package/dist/state/api/cell-root.js +0 -65
- package/dist/state/api/column-autosize.d.ts +0 -5
- package/dist/state/api/column-autosize.js +0 -72
- package/dist/state/api/column-by-id.d.ts +0 -2
- package/dist/state/api/column-by-id.js +0 -6
- package/dist/state/api/column-field.d.ts +0 -2
- package/dist/state/api/column-field.js +0 -23
- package/dist/state/api/column-from-index.d.ts +0 -2
- package/dist/state/api/column-from-index.js +0 -6
- package/dist/state/api/column-group-toggle.d.ts +0 -2
- package/dist/state/api/column-group-toggle.js +0 -10
- package/dist/state/api/column-index.d.ts +0 -2
- package/dist/state/api/column-index.js +0 -7
- package/dist/state/api/column-move.d.ts +0 -2
- package/dist/state/api/column-move.js +0 -49
- package/dist/state/api/column-resize.d.ts +0 -2
- package/dist/state/api/column-resize.js +0 -9
- package/dist/state/api/column-update.d.ts +0 -5
- package/dist/state/api/column-update.js +0 -26
- package/dist/state/api/dialog-frame.d.ts +0 -8
- package/dist/state/api/dialog-frame.js +0 -16
- package/dist/state/api/edit-begin.d.ts +0 -5
- package/dist/state/api/edit-begin.js +0 -87
- package/dist/state/api/edit-end.d.ts +0 -5
- package/dist/state/api/edit-end.js +0 -43
- package/dist/state/api/edit-is-cell-active.d.ts +0 -5
- package/dist/state/api/edit-is-cell-active.js +0 -22
- package/dist/state/api/edit-update.d.ts +0 -5
- package/dist/state/api/edit-update.js +0 -88
- package/dist/state/api/event-listeners.d.ts +0 -5
- package/dist/state/api/event-listeners.js +0 -19
- package/dist/state/api/export-csv.d.ts +0 -3
- package/dist/state/api/export-csv.js +0 -40
- package/dist/state/api/export-data-rect.d.ts +0 -2
- package/dist/state/api/export-data-rect.js +0 -24
- package/dist/state/api/popover-frame.d.ts +0 -8
- package/dist/state/api/popover-frame.js +0 -16
- package/dist/state/api/position-from-element.d.ts +0 -5
- package/dist/state/api/position-from-element.js +0 -9
- package/dist/state/api/row-by-id.d.ts +0 -2
- package/dist/state/api/row-by-id.js +0 -5
- package/dist/state/api/row-by-index.d.ts +0 -2
- package/dist/state/api/row-by-index.js +0 -9
- package/dist/state/api/row-detail-is-expanded.d.ts +0 -2
- package/dist/state/api/row-detail-is-expanded.js +0 -6
- package/dist/state/api/row-detail-rendered-height.d.ts +0 -5
- package/dist/state/api/row-detail-rendered-height.js +0 -14
- package/dist/state/api/row-detail-toggle.d.ts +0 -2
- package/dist/state/api/row-detail-toggle.js +0 -32
- package/dist/state/api/row-group-apply-expansions.d.ts +0 -2
- package/dist/state/api/row-group-apply-expansions.js +0 -20
- package/dist/state/api/row-group-column-index.d.ts +0 -2
- package/dist/state/api/row-group-column-index.js +0 -14
- package/dist/state/api/row-group-is-expanded.d.ts +0 -2
- package/dist/state/api/row-group-is-expanded.js +0 -15
- package/dist/state/api/row-group-toggle.d.ts +0 -2
- package/dist/state/api/row-group-toggle.js +0 -7
- package/dist/state/api/row-handle-select.d.ts +0 -5
- package/dist/state/api/row-handle-select.js +0 -43
- package/dist/state/api/row-select-all.d.ts +0 -2
- package/dist/state/api/row-select-all.js +0 -17
- package/dist/state/api/row-select.d.ts +0 -5
- package/dist/state/api/row-select.js +0 -35
- package/dist/state/api/row-selected.d.ts +0 -2
- package/dist/state/api/row-selected.js +0 -13
- package/dist/state/api/scroll-into-view.d.ts +0 -5
- package/dist/state/api/scroll-into-view.js +0 -50
- package/dist/state/api/sort-for-column.d.ts +0 -2
- package/dist/state/api/sort-for-column.js +0 -9
- package/dist/state/api/use-row-drag.d.ts +0 -2
- package/dist/state/api/use-row-drag.js +0 -20
- package/dist/state/helpers/cell-row-group.d.ts +0 -2
- package/dist/state/helpers/cell-row-group.js +0 -19
- package/dist/state/helpers/column-add-row-group.d.ts +0 -10
- package/dist/state/helpers/column-add-row-group.js +0 -74
- package/dist/state/helpers/column-layout.d.ts +0 -3
- package/dist/state/helpers/column-layout.js +0 -59
- package/dist/state/helpers/column-marker.d.ts +0 -8
- package/dist/state/helpers/column-marker.js +0 -45
- package/dist/state/helpers/column-view.d.ts +0 -21
- package/dist/state/helpers/column-view.js +0 -33
- package/dist/state/helpers/edit-on-change.d.ts +0 -15
- package/dist/state/helpers/edit-on-change.js +0 -27
- package/dist/state/helpers/empty-row-data-source.d.ts +0 -2
- package/dist/state/helpers/empty-row-data-source.js +0 -18
- package/dist/state/helpers/get-data-rect.d.ts +0 -13
- package/dist/state/helpers/get-data-rect.js +0 -65
- package/dist/state/helpers/get-full-width-callback.d.ts +0 -2
- package/dist/state/helpers/get-full-width-callback.js +0 -10
- package/dist/state/helpers/get-span-callback.d.ts +0 -2
- package/dist/state/helpers/get-span-callback.js +0 -22
- package/dist/state/helpers/resolve-column.d.ts +0 -4
- package/dist/state/helpers/resolve-column.js +0 -29
- package/dist/state/helpers/row-layout/get-focus-criteria.d.ts +0 -17
- package/dist/state/helpers/row-layout/get-focus-criteria.js +0 -62
- package/dist/state/helpers/row-layout/row-layout.d.ts +0 -19
- package/dist/state/helpers/row-layout/row-layout.js +0 -162
- package/dist/state/use-lytenyte.d.ts +0 -3
- package/dist/state/use-lytenyte.js +0 -686
- package/dist/tree-view/branch/branch.d.ts +0 -14
- package/dist/tree-view/branch/branch.js +0 -63
- package/dist/tree-view/branch/use-branch-keys.d.ts +0 -2
- package/dist/tree-view/branch/use-branch-keys.js +0 -87
- package/dist/tree-view/context.d.ts +0 -22
- package/dist/tree-view/context.js +0 -3
- package/dist/tree-view/depth-provider.d.ts +0 -2
- package/dist/tree-view/depth-provider.js +0 -3
- package/dist/tree-view/hooks/use-tree-view-paths.d.ts +0 -2
- package/dist/tree-view/hooks/use-tree-view-paths.js +0 -9
- package/dist/tree-view/index.d.ts +0 -16
- package/dist/tree-view/index.js +0 -16
- package/dist/tree-view/leaf.d.ts +0 -4
- package/dist/tree-view/leaf.js +0 -28
- package/dist/tree-view/navigation/get-all-ids.d.ts +0 -1
- package/dist/tree-view/navigation/get-all-ids.js +0 -7
- package/dist/tree-view/navigation/get-first-node.d.ts +0 -1
- package/dist/tree-view/navigation/get-first-node.js +0 -7
- package/dist/tree-view/navigation/get-last-node.d.ts +0 -1
- package/dist/tree-view/navigation/get-last-node.js +0 -7
- package/dist/tree-view/navigation/get-next-node.d.ts +0 -1
- package/dist/tree-view/navigation/get-next-node.js +0 -13
- package/dist/tree-view/navigation/get-prev-node.d.ts +0 -1
- package/dist/tree-view/navigation/get-prev-node.js +0 -13
- package/dist/tree-view/panel/make-handle-navigation.d.ts +0 -2
- package/dist/tree-view/panel/make-handle-navigation.js +0 -39
- package/dist/tree-view/panel/make-handle-selection.d.ts +0 -2
- package/dist/tree-view/panel/make-handle-selection.js +0 -92
- package/dist/tree-view/panel/make-handle-typeahead.d.ts +0 -1
- package/dist/tree-view/panel/make-handle-typeahead.js +0 -45
- package/dist/tree-view/panel/panel.d.ts +0 -1
- package/dist/tree-view/panel/panel.js +0 -30
- package/dist/tree-view/panel/use-tree-navigation.d.ts +0 -1
- package/dist/tree-view/panel/use-tree-navigation.js +0 -63
- package/dist/tree-view/root.d.ts +0 -17
- package/dist/tree-view/root.js +0 -63
- package/dist/tree-view/utils/get-focusable-nodes.d.ts +0 -1
- package/dist/tree-view/utils/get-focusable-nodes.js +0 -5
- package/dist/tree-view/utils/get-focused-node.d.ts +0 -1
- package/dist/tree-view/utils/get-focused-node.js +0 -14
- package/dist/tree-view/utils/get-ids-between-nodes.d.ts +0 -1
- package/dist/tree-view/utils/get-ids-between-nodes.js +0 -15
- package/dist/tree-view/utils/get-panel.d.ts +0 -1
- package/dist/tree-view/utils/get-panel.js +0 -7
- package/dist/tree-view/utils/get-parent-node.d.ts +0 -1
- package/dist/tree-view/utils/get-parent-node.js +0 -10
- package/dist/tree-view/utils/get-sibling-branches.d.ts +0 -1
- package/dist/tree-view/utils/get-sibling-branches.js +0 -14
- package/dist/tree-view/utils/get-tree-node-id.d.ts +0 -1
- package/dist/tree-view/utils/get-tree-node-id.js +0 -3
- package/dist/tree-view/utils/is-branch-node.d.ts +0 -1
- package/dist/tree-view/utils/is-branch-node.js +0 -3
- package/dist/tree-view/utils/is-leaf-node.d.ts +0 -1
- package/dist/tree-view/utils/is-leaf-node.js +0 -3
- package/dist/tree-view/utils/is-tree-node-disabled.d.ts +0 -1
- package/dist/tree-view/utils/is-tree-node-disabled.js +0 -3
- package/dist/tree-view/utils/select-node.d.ts +0 -2
- package/dist/tree-view/utils/select-node.js +0 -15
- package/dist/tree-view/utils/toggle-all-selections.d.ts +0 -2
- package/dist/tree-view/utils/toggle-all-selections.js +0 -9
- package/dist/tree-view/utils/toggle-selection.d.ts +0 -2
- package/dist/tree-view/utils/toggle-selection.js +0 -21
- package/dist/tree-view/virtualized/force-sync-scrolling.d.ts +0 -2
- package/dist/tree-view/virtualized/force-sync-scrolling.js +0 -23
- package/dist/tree-view/virtualized/get-virtual-tree-paths.d.ts +0 -2
- package/dist/tree-view/virtualized/get-virtual-tree-paths.js +0 -14
- package/dist/tree-view/virtualized/make-virtual-tree.d.ts +0 -31
- package/dist/tree-view/virtualized/make-virtual-tree.js +0 -90
- package/dist/tree-view/virtualized/use-flattened-tree.d.ts +0 -9
- package/dist/tree-view/virtualized/use-flattened-tree.js +0 -36
- package/dist/tree-view/virtualized/use-row-start-and-end.d.ts +0 -2
- package/dist/tree-view/virtualized/use-row-start-and-end.js +0 -27
- package/dist/tree-view/virtualized/use-virtualized-tree.d.ts +0 -22
- package/dist/tree-view/virtualized/use-virtualized-tree.js +0 -100
- package/dist/types/types.d.ts +0 -8
- package/dist/types/types.js +0 -1
- package/main.css +0 -465
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef, useCallback, useMemo } from "react";
|
|
3
|
-
import { TreeBranch } from "../tree-view/branch/branch.js";
|
|
4
|
-
import { ColumnItemContext } from "./context.js";
|
|
5
|
-
import { useGrid } from "../grid-provider/use-grid.js";
|
|
6
|
-
import { useColumnsFromContext } from "./use-columns-from-context.js";
|
|
7
|
-
import { dragState, DropWrap } from "@1771technologies/lytenyte-core/yinternal";
|
|
8
|
-
export const Branch = forwardRef(function Branch({ item, label, labelWrapClassName, labelWrapStyle, ...props }, forwarded) {
|
|
9
|
-
const grid = useGrid();
|
|
10
|
-
const id = grid.state.gridId.useValue();
|
|
11
|
-
const accepted = `${id}-columns`;
|
|
12
|
-
const base = grid.state.columnBase.useValue();
|
|
13
|
-
const columns = useColumnsFromContext(item);
|
|
14
|
-
const isVisible = useMemo(() => {
|
|
15
|
-
const allVisible = columns.every((c) => !(c.hide ?? base.hide));
|
|
16
|
-
return allVisible;
|
|
17
|
-
}, [base.hide, columns]);
|
|
18
|
-
const toggle = useCallback((s) => {
|
|
19
|
-
const next = s ?? isVisible;
|
|
20
|
-
grid.api.columnUpdate(Object.fromEntries(columns.map((c) => [c.id, { hide: next }])));
|
|
21
|
-
}, [columns, grid.api, isVisible]);
|
|
22
|
-
return (_jsx(ColumnItemContext, { value: useMemo(() => ({ item }), [item]), children: _jsx(TreeBranch, { ...props, itemId: item.data.idOccurrence, ref: forwarded, onKeyDown: (ev) => {
|
|
23
|
-
props.onKeyDown?.(ev);
|
|
24
|
-
if (ev.key === " ") {
|
|
25
|
-
toggle();
|
|
26
|
-
ev.preventDefault();
|
|
27
|
-
}
|
|
28
|
-
}, labelWrap: _jsx(DropWrap, { "data-ln-column-manager-branch": true, "data-ln-column-id": item.data.idOccurrence, accepted: [accepted], className: labelWrapClassName, style: labelWrapStyle, onEnter: (el) => {
|
|
29
|
-
const data = dragState.data
|
|
30
|
-
.get()
|
|
31
|
-
?.siteLocalData?.[accepted]?.at(-1);
|
|
32
|
-
if (!data)
|
|
33
|
-
return;
|
|
34
|
-
const move = data.id;
|
|
35
|
-
if (columns.some((c) => c.id === move))
|
|
36
|
-
return;
|
|
37
|
-
const allColumns = grid.state.columns.get();
|
|
38
|
-
const moveIndex = allColumns.findIndex((c) => c.id === move);
|
|
39
|
-
if (moveIndex === -1)
|
|
40
|
-
return;
|
|
41
|
-
const thisIndex = allColumns.findIndex((c) => c.id === columns[0].id);
|
|
42
|
-
const isBefore = thisIndex > moveIndex;
|
|
43
|
-
// Flipped since our source is the one moving
|
|
44
|
-
if (!isBefore) {
|
|
45
|
-
el.setAttribute("data-ln-is-before", "true");
|
|
46
|
-
}
|
|
47
|
-
else {
|
|
48
|
-
el.setAttribute("data-ln-is-after", "true");
|
|
49
|
-
}
|
|
50
|
-
}, onLeave: (el) => {
|
|
51
|
-
el.removeAttribute("data-ln-is-before");
|
|
52
|
-
el.removeAttribute("data-ln-is-after");
|
|
53
|
-
} }), label: label }) }));
|
|
54
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { Root } from "./root.js";
|
|
2
|
-
import { useColumnManager } from "./use-column-manager.js";
|
|
3
|
-
import { VisibilityCheckbox } from "./visibility-checkbox.js";
|
|
4
|
-
export declare const ColumnManager: {
|
|
5
|
-
Root: typeof Root;
|
|
6
|
-
Leaf: import("react").ForwardRefExoticComponent<Omit<import("./leaf.js").ColumnManagerLeafProps & import("react").ClassAttributes<HTMLLIElement> & import("react").LiHTMLAttributes<HTMLLIElement>, "ref"> & import("react").RefAttributes<HTMLLIElement>>;
|
|
7
|
-
Label: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & import("./label.js").LabelProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
8
|
-
Branch: import("react").ForwardRefExoticComponent<Omit<import("./branch.js").ColumnManagerBranchProps & import("react").ClassAttributes<HTMLLIElement> & import("react").LiHTMLAttributes<HTMLLIElement>, "ref"> & import("react").RefAttributes<HTMLLIElement>>;
|
|
9
|
-
Panel: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLUListElement>, HTMLUListElement>, "ref"> & import("react").RefAttributes<HTMLUListElement>>;
|
|
10
|
-
MoveHandle: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & import("./move-handle.js").MoveHandleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
11
|
-
VisibilityCheckbox: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & VisibilityCheckbox, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
12
|
-
useColumnManager: typeof useColumnManager;
|
|
13
|
-
};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { Branch } from "./branch.js";
|
|
2
|
-
import { Label } from "./label.js";
|
|
3
|
-
import { Leaf } from "./leaf.js";
|
|
4
|
-
import { MoveHandle } from "./move-handle.js";
|
|
5
|
-
import { Panel } from "./panel.js";
|
|
6
|
-
import { Root } from "./root.js";
|
|
7
|
-
import { useColumnManager } from "./use-column-manager.js";
|
|
8
|
-
import { VisibilityCheckbox } from "./visibility-checkbox.js";
|
|
9
|
-
export const ColumnManager = {
|
|
10
|
-
Root,
|
|
11
|
-
Leaf,
|
|
12
|
-
Label,
|
|
13
|
-
Branch,
|
|
14
|
-
Panel,
|
|
15
|
-
MoveHandle,
|
|
16
|
-
VisibilityCheckbox,
|
|
17
|
-
useColumnManager: useColumnManager,
|
|
18
|
-
};
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import type { Column } from "../+types";
|
|
2
|
-
import type { PathBranch, PathLeaf } from "@1771technologies/lytenyte-shared";
|
|
3
|
-
export interface TreeItemContextValue {
|
|
4
|
-
readonly item: PathBranch<Column<any>> | PathLeaf<Column<any>>;
|
|
5
|
-
}
|
|
6
|
-
export declare const ColumnItemContext: import("react").Context<TreeItemContextValue>;
|
|
7
|
-
export declare const useColumnItemContext: () => TreeItemContextValue;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { type SlotComponent } from "@1771technologies/lytenyte-core/yinternal";
|
|
2
|
-
export interface LabelProps {
|
|
3
|
-
readonly as?: SlotComponent;
|
|
4
|
-
}
|
|
5
|
-
export declare const Label: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & LabelProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef, useMemo } from "react";
|
|
3
|
-
import { useColumnItemContext } from "./context.js";
|
|
4
|
-
import { useSlot } from "@1771technologies/lytenyte-core/yinternal";
|
|
5
|
-
export const Label = forwardRef(function Label({ as, ...props }, forwarded) {
|
|
6
|
-
const { item } = useColumnItemContext();
|
|
7
|
-
const label = useMemo(() => {
|
|
8
|
-
if (item.kind == "branch")
|
|
9
|
-
return item.id.split("#").at(-2);
|
|
10
|
-
return item.data.name ?? item.data.id;
|
|
11
|
-
}, [item]);
|
|
12
|
-
const rendered = useSlot({
|
|
13
|
-
props: [{ children: label }, props],
|
|
14
|
-
ref: forwarded,
|
|
15
|
-
slot: as ?? _jsx("div", {}),
|
|
16
|
-
});
|
|
17
|
-
return rendered;
|
|
18
|
-
});
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import type { Column } from "../+types";
|
|
2
|
-
import type { PathLeaf } from "@1771technologies/lytenyte-shared";
|
|
3
|
-
export interface ColumnManagerLeafProps {
|
|
4
|
-
readonly item: PathLeaf<Column<any>>;
|
|
5
|
-
}
|
|
6
|
-
export declare const Leaf: import("react").ForwardRefExoticComponent<Omit<ColumnManagerLeafProps & import("react").ClassAttributes<HTMLLIElement> & import("react").LiHTMLAttributes<HTMLLIElement>, "ref"> & import("react").RefAttributes<HTMLLIElement>>;
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef, useCallback, useMemo } from "react";
|
|
3
|
-
import { ColumnItemContext } from "./context.js";
|
|
4
|
-
import { TreeLeaf } from "../tree-view/leaf.js";
|
|
5
|
-
import { useGrid } from "../grid-provider/use-grid.js";
|
|
6
|
-
import { useColumnsFromContext } from "./use-columns-from-context.js";
|
|
7
|
-
import { dragState, DropWrap } from "@1771technologies/lytenyte-core/yinternal";
|
|
8
|
-
export const Leaf = forwardRef(function ColumnManagerLeaf({ item, ...props }, forwarded) {
|
|
9
|
-
const context = useMemo(() => {
|
|
10
|
-
return { item: item };
|
|
11
|
-
}, [item]);
|
|
12
|
-
const grid = useGrid();
|
|
13
|
-
const id = grid.state.gridId.useValue();
|
|
14
|
-
const accepted = `${id}-columns`;
|
|
15
|
-
const base = grid.state.columnBase.useValue();
|
|
16
|
-
const columns = useColumnsFromContext(item);
|
|
17
|
-
const isVisible = useMemo(() => {
|
|
18
|
-
const allVisible = columns.every((c) => !(c.hide ?? base.hide));
|
|
19
|
-
return allVisible;
|
|
20
|
-
}, [base.hide, columns]);
|
|
21
|
-
const toggle = useCallback((s) => {
|
|
22
|
-
const next = s ?? isVisible;
|
|
23
|
-
grid.api.columnUpdate(Object.fromEntries(columns.map((c) => [c.id, { hide: next }])));
|
|
24
|
-
}, [columns, grid.api, isVisible]);
|
|
25
|
-
return (_jsx(ColumnItemContext.Provider, { value: context, children: _jsx(DropWrap, { accepted: [accepted], onEnter: (el) => {
|
|
26
|
-
const data = dragState.data
|
|
27
|
-
.get()
|
|
28
|
-
?.siteLocalData?.[accepted]?.at(-1);
|
|
29
|
-
if (!data)
|
|
30
|
-
return;
|
|
31
|
-
const columns = [item.data];
|
|
32
|
-
const move = data.id;
|
|
33
|
-
if (columns.some((c) => c.id === move))
|
|
34
|
-
return;
|
|
35
|
-
const allColumns = grid.state.columns.get();
|
|
36
|
-
const moveIndex = allColumns.findIndex((c) => c.id === move);
|
|
37
|
-
if (moveIndex === -1)
|
|
38
|
-
return;
|
|
39
|
-
const thisIndex = allColumns.findIndex((c) => c.id === columns[0].id);
|
|
40
|
-
const isBefore = thisIndex > moveIndex;
|
|
41
|
-
// Flipped since our source is the one moving
|
|
42
|
-
if (!isBefore) {
|
|
43
|
-
el.setAttribute("data-ln-is-before", "true");
|
|
44
|
-
}
|
|
45
|
-
else {
|
|
46
|
-
el.setAttribute("data-ln-is-after", "true");
|
|
47
|
-
}
|
|
48
|
-
}, onLeave: (el) => {
|
|
49
|
-
el.removeAttribute("data-ln-is-before");
|
|
50
|
-
el.removeAttribute("data-ln-is-after");
|
|
51
|
-
}, as: _jsx(TreeLeaf, { ...props, itemId: item.data.id, ref: forwarded, onKeyDown: (ev) => {
|
|
52
|
-
props.onKeyDown?.(ev);
|
|
53
|
-
if (ev.key === " ") {
|
|
54
|
-
toggle();
|
|
55
|
-
ev.preventDefault();
|
|
56
|
-
}
|
|
57
|
-
}, "data-ln-column-manager-leaf": true, "data-ln-column-id": item.data.id }) }) }));
|
|
58
|
-
});
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { type SlotComponent } from "@1771technologies/lytenyte-core/yinternal";
|
|
2
|
-
export interface MoveHandleProps {
|
|
3
|
-
readonly as?: SlotComponent;
|
|
4
|
-
}
|
|
5
|
-
export declare const MoveHandle: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & MoveHandleProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef, useMemo } from "react";
|
|
3
|
-
import { useColumnItemContext } from "./context.js";
|
|
4
|
-
import { useColumnsFromContext } from "./use-columns-from-context.js";
|
|
5
|
-
import { useGrid } from "../grid-provider/use-grid.js";
|
|
6
|
-
import { useCombinedRefs, useDraggable, useSlot, } from "@1771technologies/lytenyte-core/yinternal";
|
|
7
|
-
export const MoveHandle = forwardRef(function MoveHandle({ as, ...props }, forwarded) {
|
|
8
|
-
const item = useColumnItemContext().item;
|
|
9
|
-
const grid = useGrid();
|
|
10
|
-
const columns = useColumnsFromContext(item);
|
|
11
|
-
const base = grid.state.columnBase.useValue();
|
|
12
|
-
const isMovable = useMemo(() => {
|
|
13
|
-
return columns.every((c) => c.uiHints?.movable ?? base.uiHints?.movable);
|
|
14
|
-
}, [base.uiHints?.movable, columns]);
|
|
15
|
-
const { dragProps: { ref, ...otherProps }, } = useDraggable({
|
|
16
|
-
getItems: () => {
|
|
17
|
-
const gridId = grid.state.gridId.get();
|
|
18
|
-
const isGroupable = columns.length === 1 && (columns[0].uiHints?.rowGroupable ?? base.uiHints?.rowGroupable);
|
|
19
|
-
if (isGroupable) {
|
|
20
|
-
return {
|
|
21
|
-
siteLocalData: {
|
|
22
|
-
[`${gridId}-columns`]: columns,
|
|
23
|
-
[`${gridId}-group`]: columns[0].id,
|
|
24
|
-
},
|
|
25
|
-
};
|
|
26
|
-
}
|
|
27
|
-
return {
|
|
28
|
-
siteLocalData: {
|
|
29
|
-
[`${gridId}-columns`]: columns,
|
|
30
|
-
},
|
|
31
|
-
};
|
|
32
|
-
},
|
|
33
|
-
onDrop: (p) => {
|
|
34
|
-
const move = p.dropElement.getAttribute("data-ln-column-id");
|
|
35
|
-
if (!move)
|
|
36
|
-
return null;
|
|
37
|
-
if (columns.some((c) => c.id === move))
|
|
38
|
-
return;
|
|
39
|
-
const allColumns = grid.state.columns.get();
|
|
40
|
-
const moveIndex = allColumns.findIndex((c) => c.id === move);
|
|
41
|
-
if (moveIndex === -1)
|
|
42
|
-
return;
|
|
43
|
-
const thisIndex = allColumns.findIndex((c) => c.id === columns[0].id);
|
|
44
|
-
const isBefore = thisIndex > moveIndex;
|
|
45
|
-
grid.api.columnMove({
|
|
46
|
-
moveColumns: columns,
|
|
47
|
-
moveTarget: move,
|
|
48
|
-
before: isBefore,
|
|
49
|
-
});
|
|
50
|
-
},
|
|
51
|
-
placeholder: (_, el) => {
|
|
52
|
-
let current = el;
|
|
53
|
-
while (current &&
|
|
54
|
-
!current.getAttribute("data-ln-column-manager-leaf") &&
|
|
55
|
-
!current.getAttribute("data-ln-tree-branch")) {
|
|
56
|
-
current = current.parentElement;
|
|
57
|
-
}
|
|
58
|
-
if (current)
|
|
59
|
-
return current;
|
|
60
|
-
else
|
|
61
|
-
return el;
|
|
62
|
-
},
|
|
63
|
-
});
|
|
64
|
-
const combined = useCombinedRefs(ref, forwarded);
|
|
65
|
-
const additionalProps = isMovable ? otherProps : {};
|
|
66
|
-
const renderer = useSlot({
|
|
67
|
-
props: [{ "aria-label": "Drag to move column" }, additionalProps, props],
|
|
68
|
-
ref: isMovable ? combined : forwarded,
|
|
69
|
-
slot: as ?? _jsx("div", {}),
|
|
70
|
-
});
|
|
71
|
-
return renderer;
|
|
72
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const Panel: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLUListElement>, HTMLUListElement>, "ref"> & import("react").RefAttributes<HTMLUListElement>>;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import type { PropsWithChildren } from "react";
|
|
2
|
-
import type { Column, Grid } from "../+types";
|
|
3
|
-
import type { PathBranch } from "@1771technologies/lytenyte-shared";
|
|
4
|
-
export interface ColumnManagerRootProps<T> {
|
|
5
|
-
readonly grid: Grid<T>;
|
|
6
|
-
readonly lookup: Record<string, PathBranch<Column<any>>>;
|
|
7
|
-
}
|
|
8
|
-
export declare function Root<T>({ grid, lookup, children }: PropsWithChildren<ColumnManagerRootProps<T>>): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { GridProvider } from "../grid-provider/provider.js";
|
|
3
|
-
import { TreeRoot } from "../tree-view/root.js";
|
|
4
|
-
import { branchLookupContext } from "./branch-lookup-context.js";
|
|
5
|
-
export function Root({ grid, lookup, children }) {
|
|
6
|
-
return (_jsx(branchLookupContext.Provider, { value: lookup, children: _jsx(GridProvider, { value: grid, children: _jsx(TreeRoot, { children: children }) }) }));
|
|
7
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { Column, Grid } from "../+types";
|
|
2
|
-
import type { PathBranch } from "@1771technologies/lytenyte-shared";
|
|
3
|
-
export interface UseColumnManagerProps<T> {
|
|
4
|
-
readonly grid: Grid<T>;
|
|
5
|
-
readonly query?: string;
|
|
6
|
-
}
|
|
7
|
-
export declare function useColumnManager<T>({ grid, query }: UseColumnManagerProps<T>): {
|
|
8
|
-
items: (PathBranch<Column<T>> | import("@1771technologies/lytenyte-shared").PathLeaf<Column<T>>)[];
|
|
9
|
-
lookup: Record<string, PathBranch<Column<any>>>;
|
|
10
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { useMemo } from "react";
|
|
2
|
-
import { useTreeViewPaths } from "../tree-view/hooks/use-tree-view-paths.js";
|
|
3
|
-
export function useColumnManager({ grid, query }) {
|
|
4
|
-
const columns = grid.state.columns.useValue();
|
|
5
|
-
const filteredColumns = useMemo(() => {
|
|
6
|
-
if (!query)
|
|
7
|
-
return columns;
|
|
8
|
-
return columns.filter((c) => (c.name ?? c.id).toLowerCase().includes(query.toLowerCase()));
|
|
9
|
-
}, [columns, query]);
|
|
10
|
-
const items = useTreeViewPaths(filteredColumns, true);
|
|
11
|
-
const branchLookup = useMemo(() => {
|
|
12
|
-
const stack = [...items];
|
|
13
|
-
const lookup = {};
|
|
14
|
-
while (stack.length) {
|
|
15
|
-
const item = stack.pop();
|
|
16
|
-
if (item.kind === "leaf")
|
|
17
|
-
continue;
|
|
18
|
-
lookup[item.data.idOccurrence] = item;
|
|
19
|
-
stack.push(...item.children.values());
|
|
20
|
-
}
|
|
21
|
-
return lookup;
|
|
22
|
-
}, [items]);
|
|
23
|
-
return { items, lookup: branchLookup };
|
|
24
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { useMemo } from "react";
|
|
2
|
-
import { useBranchLookup } from "./branch-lookup-context.js";
|
|
3
|
-
export function useColumnsFromContext(item) {
|
|
4
|
-
const lookup = useBranchLookup();
|
|
5
|
-
const columns = useMemo(() => {
|
|
6
|
-
if (item.kind === "branch") {
|
|
7
|
-
const allChildren = [];
|
|
8
|
-
const branch = lookup[item.data.idOccurrence];
|
|
9
|
-
const stack = [...branch.children.values()];
|
|
10
|
-
while (stack.length) {
|
|
11
|
-
const p = stack.pop();
|
|
12
|
-
if (p.kind === "branch") {
|
|
13
|
-
stack.push(...p.children.values());
|
|
14
|
-
continue;
|
|
15
|
-
}
|
|
16
|
-
allChildren.push(p.data);
|
|
17
|
-
}
|
|
18
|
-
return allChildren;
|
|
19
|
-
}
|
|
20
|
-
return [item.data];
|
|
21
|
-
}, [item, lookup]);
|
|
22
|
-
return columns;
|
|
23
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { type SlotComponent } from "@1771technologies/lytenyte-core/yinternal";
|
|
2
|
-
export interface VisibilityCheckbox {
|
|
3
|
-
readonly as?: SlotComponent<{
|
|
4
|
-
visible: boolean;
|
|
5
|
-
indeterminate: boolean;
|
|
6
|
-
toggle: (s?: boolean) => void;
|
|
7
|
-
}>;
|
|
8
|
-
}
|
|
9
|
-
export declare const VisibilityCheckbox: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & VisibilityCheckbox, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { useColumnItemContext } from "./context.js";
|
|
3
|
-
import { forwardRef, useCallback, useMemo } from "react";
|
|
4
|
-
import { useGrid } from "../grid-provider/use-grid.js";
|
|
5
|
-
import { useColumnsFromContext } from "./use-columns-from-context.js";
|
|
6
|
-
import { useSlot } from "@1771technologies/lytenyte-core/yinternal";
|
|
7
|
-
export const VisibilityCheckbox = forwardRef(function VisibilityCheckbox({ as, ...props }, forwarded) {
|
|
8
|
-
const { item } = useColumnItemContext();
|
|
9
|
-
const grid = useGrid();
|
|
10
|
-
const base = grid.state.columnBase.useValue();
|
|
11
|
-
const columns = useColumnsFromContext(item);
|
|
12
|
-
const [isVisible, isIndeterminate] = useMemo(() => {
|
|
13
|
-
const allVisible = columns.every((c) => !(c.hide ?? base.hide));
|
|
14
|
-
const someVisible = columns.some((c) => !(c.hide ?? base.hide));
|
|
15
|
-
return [allVisible, !allVisible && someVisible];
|
|
16
|
-
}, [base.hide, columns]);
|
|
17
|
-
const toggle = useCallback((s) => {
|
|
18
|
-
const next = s ?? isVisible;
|
|
19
|
-
grid.api.columnUpdate(Object.fromEntries(columns.map((c) => [c.id, { hide: next }])));
|
|
20
|
-
}, [columns, grid.api, isVisible]);
|
|
21
|
-
const rendered = useSlot({
|
|
22
|
-
props: [props],
|
|
23
|
-
ref: forwarded,
|
|
24
|
-
slot: as ?? (_jsx("input", { type: "checkbox", checked: isVisible, "aria-label": "visibility toggle", onChange: () => {
|
|
25
|
-
toggle();
|
|
26
|
-
} })),
|
|
27
|
-
state: { visible: isVisible, indeterminate: isIndeterminate, toggle },
|
|
28
|
-
});
|
|
29
|
-
return rendered;
|
|
30
|
-
});
|
package/dist/context.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { Grid } from "./+types.js";
|
|
2
|
-
import type { InternalAtoms } from "./state/+types.js";
|
|
3
|
-
import type { Provider } from "react";
|
|
4
|
-
export interface GridRootContext {
|
|
5
|
-
readonly ref: (el: HTMLElement | null) => void;
|
|
6
|
-
readonly grid: Grid<any> & {
|
|
7
|
-
internal: InternalAtoms;
|
|
8
|
-
};
|
|
9
|
-
}
|
|
10
|
-
export declare const RootProvider: Provider<GridRootContext>;
|
|
11
|
-
export declare const useGridRoot: () => GridRootContext;
|
package/dist/context.js
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { RootProvider as CoreProvider, useGridRoot as useCoreRoot, } from "@1771technologies/lytenyte-core/yinternal";
|
|
2
|
-
// The PRO context is a superset of the Core context, but we still want to leverage some of the core
|
|
3
|
-
// components to share code. Hence we share the context functionality.
|
|
4
|
-
export const RootProvider = CoreProvider;
|
|
5
|
-
export const useGridRoot = useCoreRoot;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { type SlotComponent } from "@1771technologies/lytenyte-core/yinternal";
|
|
2
|
-
export interface ApplyProps {
|
|
3
|
-
readonly as?: SlotComponent<{
|
|
4
|
-
onApply: () => void;
|
|
5
|
-
}>;
|
|
6
|
-
}
|
|
7
|
-
export declare const Apply: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & ApplyProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { useSlot } from "@1771technologies/lytenyte-core/yinternal";
|
|
3
|
-
import { forwardRef } from "react";
|
|
4
|
-
import { useFilterSelectRoot } from "./context.js";
|
|
5
|
-
function ApplyImpl({ as, ...props }, ref) {
|
|
6
|
-
const ctx = useFilterSelectRoot();
|
|
7
|
-
const slot = useSlot({
|
|
8
|
-
props: [
|
|
9
|
-
{
|
|
10
|
-
onClick: ctx.apply,
|
|
11
|
-
},
|
|
12
|
-
props,
|
|
13
|
-
],
|
|
14
|
-
ref: ref,
|
|
15
|
-
slot: as ?? _jsx("button", { children: "Apply" }),
|
|
16
|
-
state: {
|
|
17
|
-
onReset: ctx.apply,
|
|
18
|
-
},
|
|
19
|
-
});
|
|
20
|
-
return slot;
|
|
21
|
-
}
|
|
22
|
-
export const Apply = forwardRef(ApplyImpl);
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { type SlotComponent } from "@1771technologies/lytenyte-core/yinternal";
|
|
2
|
-
export interface ClearProps {
|
|
3
|
-
readonly as?: SlotComponent<{
|
|
4
|
-
onClear: () => void;
|
|
5
|
-
}>;
|
|
6
|
-
}
|
|
7
|
-
export declare const Clear: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLButtonElement> & import("react").ButtonHTMLAttributes<HTMLButtonElement> & ClearProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { useSlot } from "@1771technologies/lytenyte-core/yinternal";
|
|
3
|
-
import { forwardRef } from "react";
|
|
4
|
-
import { useFilterSelectRoot } from "./context.js";
|
|
5
|
-
function ClearImpl({ as, ...props }, ref) {
|
|
6
|
-
const ctx = useFilterSelectRoot();
|
|
7
|
-
const slot = useSlot({
|
|
8
|
-
props: [
|
|
9
|
-
{
|
|
10
|
-
onClick: ctx.clear,
|
|
11
|
-
},
|
|
12
|
-
props,
|
|
13
|
-
],
|
|
14
|
-
ref: ref,
|
|
15
|
-
slot: as ?? _jsx("button", { children: "Clear" }),
|
|
16
|
-
state: {
|
|
17
|
-
onReset: ctx.clear,
|
|
18
|
-
},
|
|
19
|
-
});
|
|
20
|
-
return slot;
|
|
21
|
-
}
|
|
22
|
-
export const Clear = forwardRef(ClearImpl);
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { type Dispatch, type SetStateAction } from "react";
|
|
2
|
-
import type { FilterSelectFlat } from "./use-filter-select";
|
|
3
|
-
export interface FilterSelectRoot {
|
|
4
|
-
readonly defaultFilter: FilterSelectFlat;
|
|
5
|
-
readonly filters: FilterSelectFlat[];
|
|
6
|
-
readonly setFilters: Dispatch<SetStateAction<FilterSelectFlat[]>>;
|
|
7
|
-
readonly maxCount: number;
|
|
8
|
-
readonly apply: () => void;
|
|
9
|
-
readonly reset: () => void;
|
|
10
|
-
readonly clear: () => void;
|
|
11
|
-
}
|
|
12
|
-
export declare const context: import("react").Context<FilterSelectRoot>;
|
|
13
|
-
export declare const useFilterSelectRoot: () => FilterSelectRoot;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { type SlotComponent } from "@1771technologies/lytenyte-core/yinternal";
|
|
2
|
-
export interface FilterCombinatorSlotProps {
|
|
3
|
-
readonly value: "AND" | "OR" | null;
|
|
4
|
-
readonly onChange: (v: "AND" | "OR" | null) => void;
|
|
5
|
-
readonly shouldShow: boolean;
|
|
6
|
-
}
|
|
7
|
-
export interface FilterCombinatorProps {
|
|
8
|
-
readonly as?: SlotComponent<FilterCombinatorSlotProps>;
|
|
9
|
-
}
|
|
10
|
-
export declare const FilterCombinator: import("react").ForwardRefExoticComponent<Omit<import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & FilterCombinatorProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { useSlot } from "@1771technologies/lytenyte-core/yinternal";
|
|
3
|
-
import { forwardRef } from "react";
|
|
4
|
-
import { useFilterRow } from "./filter-row-context.js";
|
|
5
|
-
function FilterCombinatorImpl({ as, ...props }, ref) {
|
|
6
|
-
const ctx = useFilterRow();
|
|
7
|
-
const slot = useSlot({
|
|
8
|
-
props: [props],
|
|
9
|
-
ref: ref,
|
|
10
|
-
slot: as ?? (_jsx(_Fragment, { children: ctx.showExtender && (_jsxs("div", { ...props, ref: ref, children: [_jsxs("label", { children: ["AND", _jsx("input", { type: "radio", checked: ctx.extender === "AND", value: "AND", onChange: (e) => ctx.onExtenderChange(e.target.value) })] }), _jsxs("label", { children: ["OR", _jsx("input", { type: "radio", checked: ctx.extender === "OR", value: "OR", onChange: (e) => ctx.onExtenderChange(e.target.value) })] })] })) })),
|
|
11
|
-
state: {
|
|
12
|
-
onChange: ctx.onExtenderChange,
|
|
13
|
-
shouldShow: ctx.showExtender,
|
|
14
|
-
value: ctx.extender,
|
|
15
|
-
},
|
|
16
|
-
});
|
|
17
|
-
return slot;
|
|
18
|
-
}
|
|
19
|
-
export const FilterCombinator = forwardRef(FilterCombinatorImpl);
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import type { SelectOption } from "./operator-select";
|
|
2
|
-
import type { FilterSelectFlat } from "./use-filter-select";
|
|
3
|
-
export declare const context: import("react").Context<{
|
|
4
|
-
readonly filter: FilterSelectFlat;
|
|
5
|
-
readonly extender: "AND" | "OR" | null;
|
|
6
|
-
readonly showExtender: boolean;
|
|
7
|
-
readonly onExtenderChange: (v: "AND" | "OR" | null) => void;
|
|
8
|
-
readonly operatorOptions: SelectOption[];
|
|
9
|
-
readonly operatorValue: SelectOption | null;
|
|
10
|
-
readonly operatorOnChange: (v: SelectOption) => void;
|
|
11
|
-
readonly value: string | number | null | undefined;
|
|
12
|
-
readonly valueDisabled: boolean;
|
|
13
|
-
readonly onValueChange: (v: string | number | null) => void;
|
|
14
|
-
readonly isNumberInput: boolean;
|
|
15
|
-
readonly filterHasNoValue: boolean;
|
|
16
|
-
}>;
|
|
17
|
-
export declare const useFilterRow: () => {
|
|
18
|
-
readonly filter: FilterSelectFlat;
|
|
19
|
-
readonly extender: "AND" | "OR" | null;
|
|
20
|
-
readonly showExtender: boolean;
|
|
21
|
-
readonly onExtenderChange: (v: "AND" | "OR" | null) => void;
|
|
22
|
-
readonly operatorOptions: SelectOption[];
|
|
23
|
-
readonly operatorValue: SelectOption | null;
|
|
24
|
-
readonly operatorOnChange: (v: SelectOption) => void;
|
|
25
|
-
readonly value: string | number | null | undefined;
|
|
26
|
-
readonly valueDisabled: boolean;
|
|
27
|
-
readonly onValueChange: (v: string | number | null) => void;
|
|
28
|
-
readonly isNumberInput: boolean;
|
|
29
|
-
readonly filterHasNoValue: boolean;
|
|
30
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type { FilterSelectFlat } from "./use-filter-select";
|
|
2
|
-
import type { SelectOption } from "./operator-select";
|
|
3
|
-
export interface SelectSlotProps {
|
|
4
|
-
readonly options: SelectOption[];
|
|
5
|
-
readonly value: SelectOption | null;
|
|
6
|
-
readonly onChange: (v: SelectOption) => void;
|
|
7
|
-
}
|
|
8
|
-
export interface FilterRowProps {
|
|
9
|
-
readonly filter: FilterSelectFlat;
|
|
10
|
-
}
|
|
11
|
-
export declare const FilterRow: import("react").ForwardRefExoticComponent<FilterRowProps & {
|
|
12
|
-
children?: import("react").ReactNode | undefined;
|
|
13
|
-
} & import("react").RefAttributes<HTMLDivElement>>;
|