@infinite-table/infinite-react 0.4.11 → 0.4.12

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/index.js CHANGED
@@ -632,6 +632,8 @@ __export(exports, {
632
632
  InfiniteTable: () => InfiniteTable,
633
633
  InfiniteTableClassName: () => InfiniteTableClassName,
634
634
  InfiniteTableComponent: () => InfiniteTableComponent,
635
+ Menu: () => Menu,
636
+ MenuItem: () => MenuItem,
635
637
  NumberFilterEditor: () => NumberFilterEditor,
636
638
  RowSelectionState: () => RowSelectionState,
637
639
  StringFilterEditor: () => StringFilterEditor,
@@ -1096,7 +1098,7 @@ function stripVar(cssVariableWithVarString) {
1096
1098
 
1097
1099
  // src/components/InfiniteTable/theme.css.ts
1098
1100
  var InternalVars = { currentColumnWidth: "var(--_1slvgu90)", currentColumnTransformX: "var(--_1slvgu91)", currentColumnTransformY: "var(--_1slvgu92)", activeCellRowOffset: "var(--_1slvgu93)", activeCellRowHeight: "var(--_1slvgu94)", activeCellOffsetX: "var(--_1slvgu95)", activeCellOffsetY: "var(--_1slvgu96)", scrollTopForActiveRow: "var(--_1slvgu97)", activeCellColWidth: "var(--_1slvgu98)", activeCellColOffset: "var(--_1slvgu99)", columnReorderEffectDurationAtIndex: "var(--_1slvgu9a)", columnWidthAtIndex: "var(--_1slvgu9b)", columnOffsetAtIndex: "var(--_1slvgu9c)", columnOffsetAtIndexWhileReordering: "var(--_1slvgu9d)", columnZIndexAtIndex: "var(--_1slvgu9e)", pinnedStartWidth: "var(--_1slvgu9f)", pinnedEndWidth: "var(--_1slvgu9g)", pinnedEndOffset: "var(--_1slvgu9h)", computedVisibleColumnsCount: "var(--_1slvgu9i)", baseZIndexForCells: "var(--_1slvgu9j)", bodyWidth: "var(--_1slvgu9k)", bodyHeight: "var(--_1slvgu9l)", scrollbarWidthHorizontal: "var(--_1slvgu9m)", scrollbarWidthVertical: "var(--_1slvgu9n)", scrollLeft: "var(--_1slvgu9o)", scrollTop: "var(--_1slvgu9p)" };
1099
- var ThemeVars = { color: { accent: "var(--infinite-accent-color)", error: "var(--infinite-error-color)", color: "var(--infinite-color)" }, spacing: { "0": "var(--infinite-space-0)", "1": "var(--infinite-space-1)", "2": "var(--infinite-space-2)", "3": "var(--infinite-space-3)", "4": "var(--infinite-space-4)", "5": "var(--infinite-space-5)", "6": "var(--infinite-space-6)", "7": "var(--infinite-space-7)", "8": "var(--infinite-space-8)", "9": "var(--infinite-space-9)", "10": "var(--infinite-space-10)" }, fontSize: { "0": "var(--infinite-font-size-0)", "1": "var(--infinite-font-size-1)", "2": "var(--infinite-font-size-2)", "3": "var(--infinite-font-size-3)", "4": "var(--infinite-font-size-4)", "5": "var(--infinite-font-size-5)", "6": "var(--infinite-font-size-6)", "7": "var(--infinite-font-size-7)" }, fontFamily: "var(--infinite-font-family)", minHeight: "var(--infinite-min-height)", borderRadius: "var(--infinite-border-radius)", background: "var(--infinite-background)", components: { LoadMask: { padding: "var(--infinite-load-mask-padding)", color: "var(--infinite-load-mask-color)", textBackground: "var(--infinite-load-mask-text-background)", overlayBackground: "var(--infinite-load-mask-overlay-background)", overlayOpacity: "var(--infinite-load-mask-overlay-opacity)", borderRadius: "var(--infinite-load-mask-border-radius)" }, Header: { background: "var(--infinite-header-background)", color: "var(--infinite-header-color)", columnHeaderHeight: "var(--infinite-column-header-height)" }, HeaderCell: { background: "var(--infinite-header-cell-background)", hoverBackground: "var(--infinite-header-cell-hover-background)", padding: "var(--infinite-header-cell-padding)", paddingX: "var(--infinite-header-cell-padding-x)", paddingY: "var(--infinite-header-cell-padding-y)", iconSize: "var(--infinite-header-cell-icon-size)", sortIconMargin: "var(--infinite-header-cell-sort-icon-margin)", resizeHandleActiveAreaWidth: "var(--infinite-resize-handle-active-area-width)", resizeHandleWidth: "var(--infinite-resize-handle-width)", resizeHandleHoverBackground: "var(--infinite-resize-handle-hover-background)", resizeHandleConstrainedHoverBackground: "var(--infinite-resize-handle-constrained-hover-background)" }, Cell: { padding: "var(--infinite-cell-padding)", borderWidth: "var(--infinite-cell-border-width)", border: "var(--infinite-cell-border)", borderInvisible: "var(--infinite-cell-border-invisible)", borderRadius: "var(--infinite-cell-border-radius)", reorderEffectDuration: "var(--infinite-column-reorder-effect-duration)", pinnedBorder: "var(--infinite-pinned-cell-border)", color: "var(--infinite-cell-color)", activeBorderColor_R: "var(--infinite-active-cell-border-color--r)", activeBorderColor_G: "var(--infinite-active-cell-border-color--g)", activeBorderColor_B: "var(--infinite-active-cell-border-color--b)", activeBackgroundAlpha: "var(--infinite-active-cell-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-cell-background-alpha--table-unfocused)", activeBackground: "var(--infinite-active-cell-background)", activeBorderColor: "var(--infinite-active-cell-border-color)", activeBorderWidth: "var(--infinite-active-cell-border-width)", activeBorderStyle: "var(--infinite-active-cell-border-style)", activeBorder: "var(--infinite-active-cell-border)" }, SelectionCheckBox: { marginInline: "var(--infinite-selection-checkbox-margin-inline)" }, Row: { background: "var(--infinite-row-background)", oddBackground: "var(--infinite-row-odd-background)", selectedBackground: "var(--infinite-row-selected-background)", activeBackground: "var(--infinite-active-row-background)", activeBorderColor: "var(--infinite-active-row-border-color)", activeBorderWidth: "var(--infinite-active-row-border-width)", activeBorderStyle: "var(--infinite-active-row-border-style)", activeBorder: "var(--infinite-active-row-border)", activeBackgroundAlpha: "var(--infinite-active-row-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-row-background-alpha--table-unfocused)", hoverBackground: "var(--infinite-row-hover-background)", selectedHoverBackground: "var(--infinite-row-selected-hover-background)", groupRowBackground: "var(--infinite-group-row-background)", groupRowColumnNesting: "var(--infinite-group-row-column-nesting)", groupNesting: "var(--infinite-dont-override-group-row-nesting-length)", pointerEventsWhileScrolling: "var(--infinite-row-pointer-events-while-scrolling)" }, ColumnCell: { background: "var(--infinite-column-cell-bg-dont-override)" } } };
1101
+ var ThemeVars = { color: { accent: "var(--infinite-accent-color)", error: "var(--infinite-error-color)", color: "var(--infinite-color)" }, spacing: { "0": "var(--infinite-space-0)", "1": "var(--infinite-space-1)", "2": "var(--infinite-space-2)", "3": "var(--infinite-space-3)", "4": "var(--infinite-space-4)", "5": "var(--infinite-space-5)", "6": "var(--infinite-space-6)", "7": "var(--infinite-space-7)", "8": "var(--infinite-space-8)", "9": "var(--infinite-space-9)", "10": "var(--infinite-space-10)" }, fontSize: { "0": "var(--infinite-font-size-0)", "1": "var(--infinite-font-size-1)", "2": "var(--infinite-font-size-2)", "3": "var(--infinite-font-size-3)", "4": "var(--infinite-font-size-4)", "5": "var(--infinite-font-size-5)", "6": "var(--infinite-font-size-6)", "7": "var(--infinite-font-size-7)" }, fontFamily: "var(--infinite-font-family)", minHeight: "var(--infinite-min-height)", borderRadius: "var(--infinite-border-radius)", background: "var(--infinite-background)", components: { LoadMask: { padding: "var(--infinite-load-mask-padding)", color: "var(--infinite-load-mask-color)", textBackground: "var(--infinite-load-mask-text-background)", overlayBackground: "var(--infinite-load-mask-overlay-background)", overlayOpacity: "var(--infinite-load-mask-overlay-opacity)", borderRadius: "var(--infinite-load-mask-border-radius)" }, Header: { background: "var(--infinite-header-background)", color: "var(--infinite-header-color)", columnHeaderHeight: "var(--infinite-column-header-height)" }, HeaderCell: { background: "var(--infinite-header-cell-background)", hoverBackground: "var(--infinite-header-cell-hover-background)", padding: "var(--infinite-header-cell-padding)", paddingX: "var(--infinite-header-cell-padding-x)", paddingY: "var(--infinite-header-cell-padding-y)", iconSize: "var(--infinite-header-cell-icon-size)", sortIconMargin: "var(--infinite-header-cell-sort-icon-margin)", resizeHandleActiveAreaWidth: "var(--infinite-resize-handle-active-area-width)", resizeHandleWidth: "var(--infinite-resize-handle-width)", resizeHandleHoverBackground: "var(--infinite-resize-handle-hover-background)", resizeHandleConstrainedHoverBackground: "var(--infinite-resize-handle-constrained-hover-background)" }, Cell: { padding: "var(--infinite-cell-padding)", borderWidth: "var(--infinite-cell-border-width)", border: "var(--infinite-cell-border)", borderInvisible: "var(--infinite-cell-border-invisible)", borderRadius: "var(--infinite-cell-border-radius)", reorderEffectDuration: "var(--infinite-column-reorder-effect-duration)", pinnedBorder: "var(--infinite-pinned-cell-border)", color: "var(--infinite-cell-color)", activeBorderColor_R: "var(--infinite-active-cell-border-color--r)", activeBorderColor_G: "var(--infinite-active-cell-border-color--g)", activeBorderColor_B: "var(--infinite-active-cell-border-color--b)", activeBackgroundAlpha: "var(--infinite-active-cell-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-cell-background-alpha--table-unfocused)", activeBackground: "var(--infinite-active-cell-background)", activeBorderColor: "var(--infinite-active-cell-border-color)", activeBorderWidth: "var(--infinite-active-cell-border-width)", activeBorderStyle: "var(--infinite-active-cell-border-style)", activeBorder: "var(--infinite-active-cell-border)" }, SelectionCheckBox: { marginInline: "var(--infinite-selection-checkbox-margin-inline)" }, Menu: { background: "var(--infinite-menu-background)", color: "var(--infinite-menu-color)", padding: "var(--infinite-menu-padding)", cellPaddingVertical: "var(--infinite-menu-cell-padding-vertical)", cellPaddingHorizontal: "var(--infinite-menu-cell-padding-horizontal)", cellMarginVertical: "var(--infinite-menu-cell-margin-vertical)", itemDisabledBackground: "var(--infinite-menu-item-disabled-background)", itemHoverBackground: "var(--infinite-menu-item-hover-background)", itemHoverOpacity: "var(--infinite-menu-item-hover-opacity)", itemPressedOpacity: "var(--infinite-menu-item-pressed-opacity)", itemPressedBackground: "var(--infinite-menu-item-pressed-background)", itemDisabledOpacity: "var(--infinite-menu-item-disabled-opacity)" }, Row: { background: "var(--infinite-row-background)", oddBackground: "var(--infinite-row-odd-background)", selectedBackground: "var(--infinite-row-selected-background)", activeBackground: "var(--infinite-active-row-background)", activeBorderColor: "var(--infinite-active-row-border-color)", activeBorderWidth: "var(--infinite-active-row-border-width)", activeBorderStyle: "var(--infinite-active-row-border-style)", activeBorder: "var(--infinite-active-row-border)", activeBackgroundAlpha: "var(--infinite-active-row-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-row-background-alpha--table-unfocused)", hoverBackground: "var(--infinite-row-hover-background)", selectedHoverBackground: "var(--infinite-row-selected-hover-background)", groupRowBackground: "var(--infinite-group-row-background)", groupRowColumnNesting: "var(--infinite-group-row-column-nesting)", groupNesting: "var(--infinite-dont-override-group-row-nesting-length)", pointerEventsWhileScrolling: "var(--infinite-row-pointer-events-while-scrolling)" }, ColumnCell: { background: "var(--infinite-column-cell-bg-dont-override)" } } };
1100
1102
  var columnHeaderHeightName = "column-header-height";
1101
1103
 
1102
1104
  // src/utils/selectParent.ts
@@ -3652,11 +3654,11 @@ var useRerender = () => {
3652
3654
  };
3653
3655
 
3654
3656
  // src/components/InfiniteTable/components/ActiveCellIndicator.css.ts
3655
- var ActiveCellIndicatorCls = { visible: "nxbq1c2 nxbq1c1 _16lm1iwg _16lm1iw3 _16lm1iw15 _16lm1iw13", hidden: "nxbq1c3 nxbq1c1 _16lm1iwg _16lm1iw3 _16lm1iw15 _16lm1iw13" };
3656
- var ActiveIndicatorWrapperCls = "_16lm1iwg _16lm1iw3 _16lm1iw15 _16lm1iw13 _16lm1iwz _16lm1iwp";
3657
+ var ActiveCellIndicatorCls = { visible: "nxbq1c2 nxbq1c1 _16lm1iwi _16lm1iw3 _16lm1iw1b _16lm1iw19", hidden: "nxbq1c3 nxbq1c1 _16lm1iwi _16lm1iw3 _16lm1iw1b _16lm1iw19" };
3658
+ var ActiveIndicatorWrapperCls = "_16lm1iwi _16lm1iw3 _16lm1iw1b _16lm1iw19 _16lm1iw15 _16lm1iwr";
3657
3659
 
3658
3660
  // src/components/InfiniteTable/components/ActiveRowIndicator.css.ts
3659
- var ActiveRowIndicatorCls = { visible: "j26lrx1 j26lrx0 _16lm1iwg _16lm1iw3 _16lm1iw12 _16lm1iw13 _16lm1iw15", hidden: "j26lrx2 j26lrx0 _16lm1iwg _16lm1iw3 _16lm1iw12 _16lm1iw13 _16lm1iw15" };
3661
+ var ActiveRowIndicatorCls = { visible: "j26lrx1 j26lrx0 _16lm1iwi _16lm1iw3 _16lm1iw18 _16lm1iw19 _16lm1iw1b", hidden: "j26lrx2 j26lrx0 _16lm1iwi _16lm1iw3 _16lm1iw18 _16lm1iw19 _16lm1iw1b" };
3660
3662
 
3661
3663
  // src/components/InfiniteTable/components/ActiveRowIndicator.tsx
3662
3664
  var { rootClassName: rootClassName3 } = internalProps;
@@ -4186,20 +4188,20 @@ var useInternalProps = () => {
4186
4188
  };
4187
4189
 
4188
4190
  // src/components/InfiniteTable/utilities.css.ts
4189
- var alignItems = { center: "_16lm1iw1h", stretch: "_16lm1iw1i" };
4190
- var cssEllipsisClassName = "_16lm1iw1s _16lm1iw1t _16lm1iw1m";
4191
- var cursor = { pointer: "_16lm1iwe", colResize: "_16lm1iwf" };
4192
- var display = { flex: "_16lm1iwu", none: "_16lm1iwv", block: "_16lm1iww", inlineBlock: "_16lm1iwx" };
4193
- var flex = { "1": "_16lm1iwh", none: "_16lm1iwi" };
4194
- var flexFlow = { column: "_16lm1iw1d", columnReverse: "_16lm1iw1e", row: "_16lm1iw1f", rowReverse: "_16lm1iw1g" };
4195
- var justifyContent = { center: "_16lm1iw1j", start: "_16lm1iw1k", end: "_16lm1iw1l" };
4196
- var left = { "0": "_16lm1iw15", "100%": "_16lm1iw16", auto: "_16lm1iw17" };
4197
- var overflow = { hidden: "_16lm1iw1m", auto: "_16lm1iw1n", visible: "_16lm1iw1o" };
4191
+ var alignItems = { center: "_16lm1iw1n", stretch: "_16lm1iw1o" };
4192
+ var cssEllipsisClassName = "_16lm1iw1y _16lm1iw1z _16lm1iw1s";
4193
+ var cursor = { pointer: "_16lm1iwf", "default": "_16lm1iwg", colResize: "_16lm1iwh" };
4194
+ var display = { flex: "_16lm1iww", contents: "_16lm1iwx", none: "_16lm1iwy", block: "_16lm1iwz", grid: "_16lm1iw10", inlineBlock: "_16lm1iw11", inlineFlex: "_16lm1iw12", inlineGrid: "_16lm1iw13" };
4195
+ var flex = { "1": "_16lm1iwj", none: "_16lm1iwk" };
4196
+ var flexFlow = { column: "_16lm1iw1j", columnReverse: "_16lm1iw1k", row: "_16lm1iw1l", rowReverse: "_16lm1iw1m" };
4197
+ var justifyContent = { center: "_16lm1iw1p", start: "_16lm1iw1q", end: "_16lm1iw1r" };
4198
+ var left = { "0": "_16lm1iw1b", "100%": "_16lm1iw1c", auto: "_16lm1iw1d" };
4199
+ var overflow = { hidden: "_16lm1iw1s", auto: "_16lm1iw1t", visible: "_16lm1iw1u" };
4198
4200
  var position = { relative: "_16lm1iw1", absolute: "_16lm1iw2", sticky: "_16lm1iw3", fixed: "_16lm1iw4" };
4199
- var top = { "0": "_16lm1iw13", "100%": "_16lm1iw14" };
4200
- var transformTranslateZero = "_16lm1iwa";
4201
- var userSelect = { none: "_16lm1iwy" };
4202
- var zIndex = { "1": "_16lm1iwj", "10": "_16lm1iwk", "100": "_16lm1iwl", "1000": "_16lm1iwm", "10000": "_16lm1iwn", "100000": "_16lm1iwo", "1000000": "_16lm1iwp", "10000000": "_16lm1iwq", "1k": "_16lm1iwr", "10k": "_16lm1iws", "100k": "_16lm1iwt" };
4201
+ var top = { "0": "_16lm1iw19", "100%": "_16lm1iw1a" };
4202
+ var transformTranslateZero = "_16lm1iwb";
4203
+ var userSelect = { none: "_16lm1iw14" };
4204
+ var zIndex = { "1": "_16lm1iwl", "10": "_16lm1iwm", "100": "_16lm1iwn", "1000": "_16lm1iwo", "10000": "_16lm1iwp", "100000": "_16lm1iwq", "1000000": "_16lm1iwr", "10000000": "_16lm1iws", "1k": "_16lm1iwt", "10k": "_16lm1iwu", "100k": "_16lm1iwv" };
4203
4205
 
4204
4206
  // src/components/InfiniteTable/components/InfiniteTableBody/InfiniteTableBody.tsx
4205
4207
  var InfiniteTableBody = React14.forwardRef(function InfiniteTableBody2(props, ref) {
@@ -4360,14 +4362,14 @@ var useInfiniteTable = () => {
4360
4362
  // src/components/InfiniteTable/InfiniteCls.css.ts
4361
4363
  var import_createRuntimeFn = __toModule(require_vanilla_extract_recipes_createRuntimeFn_cjs());
4362
4364
  var FooterCls = "_16lm1iw1";
4363
- var InfiniteCls = "_1yeub2v0 _16lm1iw1 _16lm1iwu _16lm1iw1d _16lm1iw0";
4365
+ var InfiniteCls = "_1yeub2v0 _16lm1iw1 _16lm1iww _16lm1iw1j _16lm1iw0";
4364
4366
  var InfiniteClsHasPinnedEnd = "_1yeub2vo";
4365
4367
  var InfiniteClsHasPinnedStart = "_1yeub2vn";
4366
4368
  var InfiniteClsRecipe = (0, import_createRuntimeFn.createRuntimeFn)({ defaultClassName: "", variantClassNames: { focused: { true: "_1yeub2v2", false: "_1yeub2v3" }, focusedWithin: { true: "_1yeub2v4", false: "_1yeub2v5" }, hasPinnedStart: { true: "_1yeub2v6", false: "_1yeub2v7" }, hasPinnedEnd: { true: "_1yeub2v8", false: "_1yeub2v9" }, hasPinnedStartOverflow: { true: "_1yeub2va", false: "_1yeub2vb" }, hasPinnedEndOverflow: { true: "_1yeub2vc", false: "_1yeub2vd" } }, defaultVariants: {}, compoundVariants: [[{ focused: false, focusedWithin: false }, "_1yeub2ve"]] });
4367
4369
  var InfiniteClsShiftingColumns = "_1yeub2vl";
4368
- var PinnedEndIndicatorBorder = "_1yeub2vr _1yeub2vp _16lm1iw2 _16lm1iw13 _16lm1iwf _16lm1iwy _16lm1iw11 _16lm1iw1q _16lm1iwg _16lm1iwq";
4370
+ var PinnedEndIndicatorBorder = "_1yeub2vr _1yeub2vp _16lm1iw2 _16lm1iw19 _16lm1iwh _16lm1iw14 _16lm1iw17 _16lm1iw1w _16lm1iwi _16lm1iws";
4369
4371
  var PinnedRowsContainerClsVariants = (0, import_createRuntimeFn.createRuntimeFn)({ defaultClassName: "", variantClassNames: { pinned: { start: "_1yeub2vi", end: "_1yeub2vj", false: "_1yeub2vk" } }, defaultVariants: {}, compoundVariants: [] });
4370
- var PinnedStartIndicatorBorder = "_1yeub2vq _1yeub2vp _16lm1iw2 _16lm1iw13 _16lm1iwf _16lm1iwy _16lm1iw11 _16lm1iw1q _16lm1iwg _16lm1iwq";
4372
+ var PinnedStartIndicatorBorder = "_1yeub2vq _1yeub2vp _16lm1iw2 _16lm1iw19 _16lm1iwh _16lm1iw14 _16lm1iw17 _16lm1iw1w _16lm1iwi _16lm1iws";
4371
4373
 
4372
4374
  // src/components/utils/getScrollbarWidth.ts
4373
4375
  var scrollbarWidth;
@@ -5100,7 +5102,7 @@ var useColumnPointerEvents = ({
5100
5102
  };
5101
5103
  };
5102
5104
 
5103
- // src/components/InfiniteTable/utils/RenderHookComponent.tsx
5105
+ // src/components/InfiniteTable/utils/RenderHookComponentForInfinite.tsx
5104
5106
  var React22 = __toModule(require("react"));
5105
5107
 
5106
5108
  // src/components/InfiniteTable/components/InfiniteTableRow/InfiniteTableColumnCell.tsx
@@ -5124,8 +5126,8 @@ var import_react17 = __toModule(require("react"));
5124
5126
 
5125
5127
  // src/components/InfiniteTable/components/icons/ExpanderIcon.css.ts
5126
5128
  var import_createRuntimeFn2 = __toModule(require_vanilla_extract_recipes_createRuntimeFn_cjs());
5127
- var ExpanderIconCls = "_16lm1iw6 _16lm1iwi _16lm1iwe";
5128
- var ExpanderIconClsVariants = (0, import_createRuntimeFn2.createRuntimeFn)({ defaultClassName: "", variantClassNames: { expanded: { true: "_16lm1iwc", false: "_198z9782" }, direction: { end: "_198z9783", start: "_198z9784" } }, defaultVariants: {}, compoundVariants: [[{ expanded: false, direction: "end" }, "_16lm1iwd"]] });
5129
+ var ExpanderIconCls = "_16lm1iw6 _16lm1iwk _16lm1iwf";
5130
+ var ExpanderIconClsVariants = (0, import_createRuntimeFn2.createRuntimeFn)({ defaultClassName: "", variantClassNames: { expanded: { true: "_16lm1iwd", false: "_198z9782" }, direction: { end: "_198z9783", start: "_198z9784" } }, defaultVariants: {}, compoundVariants: [[{ expanded: false, direction: "end" }, "_16lm1iwe"]] });
5129
5131
 
5130
5132
  // src/components/InfiniteTable/components/icons/ExpanderIcon.tsx
5131
5133
  function ExpanderIcon(props) {
@@ -5165,7 +5167,7 @@ function ExpanderIcon(props) {
5165
5167
  var React17 = __toModule(require("react"));
5166
5168
 
5167
5169
  // src/components/InfiniteTable/components/icons/LoadingIcon.css.ts
5168
- var LoadingIconCls = "_16lm1iw8 _16lm1iwi _16lm1iwe";
5170
+ var LoadingIconCls = "_16lm1iw9 _16lm1iwk _16lm1iwf";
5169
5171
 
5170
5172
  // src/components/InfiniteTable/components/icons/LoadingIcon.tsx
5171
5173
  var LoadingIcon = (props) => {
@@ -5363,7 +5365,7 @@ function objectValuesExcept(obj, exceptList) {
5363
5365
 
5364
5366
  // src/components/InfiniteTable/components/cell.css.ts
5365
5367
  var import_createRuntimeFn4 = __toModule(require_vanilla_extract_recipes_createRuntimeFn_cjs());
5366
- var ColumnCellCls = "_1eexc2a6 _1eexc2a5 _16lm1iwu _16lm1iw1f _16lm1iw1h _16lm1iw2 _16lm1iw1r _16lm1iw1s _16lm1iwy";
5368
+ var ColumnCellCls = "_1eexc2a6 _1eexc2a5 _16lm1iww _16lm1iw1l _16lm1iw1n _16lm1iw2 _16lm1iw1x _16lm1iw1y _16lm1iw14";
5367
5369
  var ColumnCellRecipe = (0, import_createRuntimeFn4.createRuntimeFn)({ defaultClassName: "_1eexc2a8", variantClassNames: { dragging: { false: "_1eexc2a9", true: "_1eexc2aa" }, rowActive: { false: "_1eexc2ab", true: "_1eexc2ac" }, zebra: { false: "_1eexc2ad", even: "_1eexc2ae", odd: "_1eexc2af" }, rowSelected: { true: "_1eexc2ag", false: "_1eexc2ah", null: "_1eexc2ai" }, first: { true: "_1eexc2aj", false: "_1eexc2ak" }, last: { true: "_1eexc2al", false: "_1eexc2am" }, groupByField: { true: "_1eexc2an", false: "_1eexc2ao" }, firstInCategory: { true: "_1eexc2ap", false: "_1eexc2aq" }, lastInCategory: { true: "_1eexc2ar", false: "_1eexc2as" }, pinned: { start: "_1eexc2at", end: "_1eexc2au", false: "_1eexc2av" }, filtered: { true: "_1eexc2aw", false: "_1eexc2ax" } }, defaultVariants: {}, compoundVariants: [[{ pinned: "start", lastInCategory: true }, "_1eexc2ay"], [{ pinned: "start", firstInCategory: true }, "_1eexc2az"], [{ pinned: "end", firstInCategory: true }, "_1eexc2a10"], [{ pinned: "end", lastInCategory: true }, "_1eexc2a11"]] });
5368
5370
  var SelectionCheckboxCls = "_1eexc2a7";
5369
5371
 
@@ -5372,7 +5374,7 @@ var React19 = __toModule(require("react"));
5372
5374
  var import_react18 = __toModule(require("react"));
5373
5375
 
5374
5376
  // src/components/InfiniteTable/components/CheckBox.css.ts
5375
- var CheckBoxCls = "_16lm1iwe";
5377
+ var CheckBoxCls = "_16lm1iwf";
5376
5378
 
5377
5379
  // src/components/InfiniteTable/components/CheckBox.tsx
5378
5380
  function forwardProps2() {
@@ -5871,11 +5873,13 @@ function useInfiniteColumnCell() {
5871
5873
  return result;
5872
5874
  }
5873
5875
 
5874
- // src/components/InfiniteTable/utils/RenderHookComponent.tsx
5876
+ // src/components/RenderHookComponent.tsx
5875
5877
  function RenderHookComponent(props) {
5876
5878
  var _a;
5877
5879
  return (_a = props.render(props.renderParam)) != null ? _a : null;
5878
5880
  }
5881
+
5882
+ // src/components/InfiniteTable/utils/RenderHookComponentForInfinite.tsx
5879
5883
  function RenderCellHookComponent(props) {
5880
5884
  const ContextProvider = InfiniteTableColumnCellContext.Provider;
5881
5885
  return /* @__PURE__ */ React22.createElement(ContextProvider, {
@@ -5937,19 +5941,19 @@ var import_react20 = __toModule(require("react"));
5937
5941
 
5938
5942
  // src/components/InfiniteTable/components/InfiniteTableHeader/header.css.ts
5939
5943
  var import_createRuntimeFn5 = __toModule(require_vanilla_extract_recipes_createRuntimeFn_cjs());
5940
- var CellCls = "_1eexc2a5 _16lm1iwu _16lm1iw1f _16lm1iw1h _16lm1iw2 _16lm1iw1r _16lm1iw1s _16lm1iwy";
5941
- var HeaderCellContentRecipe = (0, import_createRuntimeFn5.createRuntimeFn)({ defaultClassName: "_12zfob11e _16lm1iw10 _16lm1iw12 _16lm1iwu _16lm1iw1f _16lm1iw1h", variantClassNames: { filtered: { false: "_12zfob11f", true: "_12zfob11g" } }, defaultVariants: {}, compoundVariants: [] });
5942
- var HeaderCellProxy = "_12zfob1k _16lm1iw1s _16lm1iw1t _16lm1iw1m";
5943
- var HeaderCellRecipe = (0, import_createRuntimeFn5.createRuntimeFn)({ defaultClassName: "_12zfob1l _16lm1iww", variantClassNames: { rowActive: { false: "_12zfob1m", true: "_12zfob1n" }, rowSelected: { false: "_12zfob1o", true: "_12zfob1p", null: "_12zfob1q" }, zebra: { false: "_12zfob1r", even: "_12zfob1s", odd: "_12zfob1t" }, dragging: { true: "_12zfob1u", false: "_12zfob1v" }, first: { true: "_12zfob1w", false: "_12zfob1x" }, last: { true: "_12zfob1y", false: "_12zfob1z" }, groupByField: { true: "_12zfob110", false: "_12zfob111" }, firstInCategory: { true: "_12zfob112", false: "_12zfob113" }, lastInCategory: { true: "_12zfob114", false: "_12zfob115" }, pinned: { start: "_12zfob116", end: "_12zfob117", false: "_12zfob118" }, filtered: { true: "_12zfob119", false: "_12zfob11a" } }, defaultVariants: {}, compoundVariants: [[{ pinned: "start", lastInCategory: true }, "_12zfob11b"], [{ pinned: "end", firstInCategory: true }, "_12zfob11c"], [{ pinned: false, lastInCategory: true }, "_12zfob11d"]] });
5944
- var HeaderClsRecipe = (0, import_createRuntimeFn5.createRuntimeFn)({ defaultClassName: "_12zfob16 _16lm1iww _16lm1iw2", variantClassNames: { pinned: { start: "_12zfob17", end: "_12zfob18", false: "_12zfob19" }, firstInCategory: { true: "_12zfob1a", false: "_12zfob1b" }, lastInCategory: { true: "_12zfob1c", false: "_12zfob1d" }, overflow: { true: "_12zfob1e", false: "_12zfob1f" } }, defaultVariants: {}, compoundVariants: [[{ overflow: true, pinned: "start" }, "_12zfob1g"], [{ pinned: "start", firstInCategory: true }, "_12zfob1h"], [{ overflow: true, pinned: "end" }, "_12zfob1i"], [{ pinned: "end", lastInCategory: true }, "_12zfob1j"]] });
5945
- var HeaderFilterCls = "_12zfob11j _16lm1iwu _16lm1iw1f _16lm1iw1h _16lm1iw1";
5946
- var HeaderFilterEditorCls = "_16lm1iw12 _16lm1iw10";
5947
- var HeaderGroupCls = "_12zfob11i _16lm1iwu _16lm1iw1f _16lm1iw1h";
5944
+ var CellCls = "_1eexc2a5 _16lm1iww _16lm1iw1l _16lm1iw1n _16lm1iw2 _16lm1iw1x _16lm1iw1y _16lm1iw14";
5945
+ var HeaderCellContentRecipe = (0, import_createRuntimeFn5.createRuntimeFn)({ defaultClassName: "_12zfob11e _16lm1iw16 _16lm1iw18 _16lm1iww _16lm1iw1l _16lm1iw1n", variantClassNames: { filtered: { false: "_12zfob11f", true: "_12zfob11g" } }, defaultVariants: {}, compoundVariants: [] });
5946
+ var HeaderCellProxy = "_12zfob1k _16lm1iw1y _16lm1iw1z _16lm1iw1s";
5947
+ var HeaderCellRecipe = (0, import_createRuntimeFn5.createRuntimeFn)({ defaultClassName: "_12zfob1l _16lm1iwz", variantClassNames: { rowActive: { false: "_12zfob1m", true: "_12zfob1n" }, rowSelected: { false: "_12zfob1o", true: "_12zfob1p", null: "_12zfob1q" }, zebra: { false: "_12zfob1r", even: "_12zfob1s", odd: "_12zfob1t" }, dragging: { true: "_12zfob1u", false: "_12zfob1v" }, first: { true: "_12zfob1w", false: "_12zfob1x" }, last: { true: "_12zfob1y", false: "_12zfob1z" }, groupByField: { true: "_12zfob110", false: "_12zfob111" }, firstInCategory: { true: "_12zfob112", false: "_12zfob113" }, lastInCategory: { true: "_12zfob114", false: "_12zfob115" }, pinned: { start: "_12zfob116", end: "_12zfob117", false: "_12zfob118" }, filtered: { true: "_12zfob119", false: "_12zfob11a" } }, defaultVariants: {}, compoundVariants: [[{ pinned: "start", lastInCategory: true }, "_12zfob11b"], [{ pinned: "end", firstInCategory: true }, "_12zfob11c"], [{ pinned: false, lastInCategory: true }, "_12zfob11d"]] });
5948
+ var HeaderClsRecipe = (0, import_createRuntimeFn5.createRuntimeFn)({ defaultClassName: "_12zfob16 _16lm1iwz _16lm1iw2", variantClassNames: { pinned: { start: "_12zfob17", end: "_12zfob18", false: "_12zfob19" }, firstInCategory: { true: "_12zfob1a", false: "_12zfob1b" }, lastInCategory: { true: "_12zfob1c", false: "_12zfob1d" }, overflow: { true: "_12zfob1e", false: "_12zfob1f" } }, defaultVariants: {}, compoundVariants: [[{ overflow: true, pinned: "start" }, "_12zfob1g"], [{ pinned: "start", firstInCategory: true }, "_12zfob1h"], [{ overflow: true, pinned: "end" }, "_12zfob1i"], [{ pinned: "end", lastInCategory: true }, "_12zfob1j"]] });
5949
+ var HeaderFilterCls = "_12zfob11j _16lm1iww _16lm1iw1l _16lm1iw1n _16lm1iw1";
5950
+ var HeaderFilterEditorCls = "_16lm1iw18 _16lm1iw16";
5951
+ var HeaderGroupCls = "_12zfob11i _16lm1iww _16lm1iw1l _16lm1iw1n";
5948
5952
  var HeaderScrollbarPlaceholderCls = "_12zfob15 _16lm1iw2";
5949
5953
  var HeaderSortIconCls = "_16lm1iw1";
5950
5954
  var HeaderSortIconIndexCls = "_12zfob14";
5951
5955
  var HeaderSortIconRecipe = (0, import_createRuntimeFn5.createRuntimeFn)({ defaultClassName: "", variantClassNames: { align: { start: "_12zfob11", center: "_12zfob12", end: "_12zfob13" } }, defaultVariants: {}, compoundVariants: [] });
5952
- var HeaderWrapperCls = "_12zfob11h _16lm1iw1m _16lm1iw1 _16lm1iwu _16lm1iw1f";
5956
+ var HeaderWrapperCls = "_12zfob11h _16lm1iw1s _16lm1iw1 _16lm1iww _16lm1iw1l";
5953
5957
 
5954
5958
  // src/components/InfiniteTable/components/icons/SortIcon.tsx
5955
5959
  var defaultLineStyle = {
@@ -6512,9 +6516,9 @@ function getColumnGroupResizer(colIndexes, config) {
6512
6516
 
6513
6517
  // src/components/InfiniteTable/components/InfiniteTableHeader/ResizeHandle/ResizeHandle.css.ts
6514
6518
  var import_createRuntimeFn6 = __toModule(require_vanilla_extract_recipes_createRuntimeFn_cjs());
6515
- var ResizeHandleCls = "zneyzh0 _16lm1iw2 _16lm1iw13 _16lm1iw1a _16lm1iw18 _16lm1iwf _16lm1iw1m";
6516
- var ResizeHandleDraggerClsRecipe = (0, import_createRuntimeFn6.createRuntimeFn)({ defaultClassName: "zneyzhb _16lm1iw2 _16lm1iw13 _16lm1iw18", variantClassNames: { constrained: { false: "zneyzhc", true: "zneyzhd" } }, defaultVariants: {}, compoundVariants: [] });
6517
- var ResizeHandleRecipeCls = (0, import_createRuntimeFn6.createRuntimeFn)({ defaultClassName: "", variantClassNames: { computedPinned: { start: "zneyzh1", end: "zneyzh2 _16lm1iw15 _16lm1iw1c", false: "zneyzh3" }, computedFirstInCategory: { true: "zneyzh4", false: "zneyzh5" }, computedLastInCategory: { true: "zneyzh6", false: "zneyzh7" } }, defaultVariants: {}, compoundVariants: [[{ computedPinned: "end", computedLastInCategory: false, computedFirstInCategory: true }, "zneyzh8"], [{ computedPinned: false, computedFirstInCategory: false, computedLastInCategory: true }, "zneyzh9"], [{ computedPinned: "start", computedFirstInCategory: false, computedLastInCategory: true }, "zneyzha"]] });
6519
+ var ResizeHandleCls = "zneyzh0 _16lm1iw2 _16lm1iw19 _16lm1iw1g _16lm1iw1e _16lm1iwh _16lm1iw1s";
6520
+ var ResizeHandleDraggerClsRecipe = (0, import_createRuntimeFn6.createRuntimeFn)({ defaultClassName: "zneyzhb _16lm1iw2 _16lm1iw19 _16lm1iw1e", variantClassNames: { constrained: { false: "zneyzhc", true: "zneyzhd" } }, defaultVariants: {}, compoundVariants: [] });
6521
+ var ResizeHandleRecipeCls = (0, import_createRuntimeFn6.createRuntimeFn)({ defaultClassName: "", variantClassNames: { computedPinned: { start: "zneyzh1", end: "zneyzh2 _16lm1iw1b _16lm1iw1i", false: "zneyzh3" }, computedFirstInCategory: { true: "zneyzh4", false: "zneyzh5" }, computedLastInCategory: { true: "zneyzh6", false: "zneyzh7" } }, defaultVariants: {}, compoundVariants: [[{ computedPinned: "end", computedLastInCategory: false, computedFirstInCategory: true }, "zneyzh8"], [{ computedPinned: false, computedFirstInCategory: false, computedLastInCategory: true }, "zneyzh9"], [{ computedPinned: "start", computedFirstInCategory: false, computedLastInCategory: true }, "zneyzha"]] });
6518
6522
 
6519
6523
  // src/components/InfiniteTable/components/InfiniteTableHeader/ResizeHandle/index.tsx
6520
6524
  var { rootClassName: rootClassName8 } = internalProps;
@@ -7491,8 +7495,8 @@ var InfiniteTableLicenseFooter = React34.forwardRef(function InfiniteTableLicens
7491
7495
  var React35 = __toModule(require("react"));
7492
7496
 
7493
7497
  // src/components/InfiniteTable/components/LoadMask.css.ts
7494
- var LoadMaskCls = { visible: "qy58ya1 qy58ya0 _16lm1iw2 _16lm1iw13 _16lm1iw15 _16lm1iw1a _16lm1iw18", hidden: "qy58ya2 qy58ya0 _16lm1iw2 _16lm1iw13 _16lm1iw15 _16lm1iw1a _16lm1iw18" };
7495
- var LoadMaskOverlayCls = "qy58ya3 _16lm1iw2 _16lm1iw13 _16lm1iw15 _16lm1iw1a _16lm1iw18";
7498
+ var LoadMaskCls = { visible: "qy58ya1 qy58ya0 _16lm1iw2 _16lm1iw19 _16lm1iw1b _16lm1iw1g _16lm1iw1e", hidden: "qy58ya2 qy58ya0 _16lm1iw2 _16lm1iw19 _16lm1iw1b _16lm1iw1g _16lm1iw1e" };
7499
+ var LoadMaskOverlayCls = "qy58ya3 _16lm1iw2 _16lm1iw19 _16lm1iw1b _16lm1iw1g _16lm1iw1e";
7496
7500
  var LoadMaskTextCls = "qy58ya4";
7497
7501
 
7498
7502
  // src/components/InfiniteTable/components/LoadMask.tsx
@@ -7541,12 +7545,14 @@ function deepClone(source) {
7541
7545
  return target;
7542
7546
  }
7543
7547
 
7544
- // src/utils/groupAndPivot/index.ts
7545
- var LAZY_ROOT_KEY_FOR_GROUPS = "____root____";
7546
- var NOT_LOADED_YET_KEY_PREFIX = "____not_loaded_yet____";
7548
+ // src/utils/groupAndPivot/defaultToKey.ts
7547
7549
  function DEFAULT_TO_KEY(value) {
7548
7550
  return value;
7549
7551
  }
7552
+
7553
+ // src/utils/groupAndPivot/index.ts
7554
+ var LAZY_ROOT_KEY_FOR_GROUPS = "____root____";
7555
+ var NOT_LOADED_YET_KEY_PREFIX = "____not_loaded_yet____";
7550
7556
  function initReducers(reducers) {
7551
7557
  if (!reducers || !Object.keys(reducers).length) {
7552
7558
  return {};
@@ -7716,14 +7722,6 @@ function processGroup(deepMap, currentGroupKeys, currentPivotKeys, item, itemInd
7716
7722
  currentPivotKeys.length = 0;
7717
7723
  }
7718
7724
  }
7719
- function getGroupKeysForDataItem(data, groupBy) {
7720
- return groupBy.reduce((groupKeys, groupBy2) => {
7721
- const { field: groupByProperty, toKey: groupToKey } = groupBy2;
7722
- const key = (groupToKey || DEFAULT_TO_KEY)(data[groupByProperty], data);
7723
- groupKeys.push(key);
7724
- return groupKeys;
7725
- }, []);
7726
- }
7727
7725
  function group(groupParams, data) {
7728
7726
  const {
7729
7727
  groupBy,
@@ -8816,6 +8814,16 @@ function lazyLoadRange(options, cache) {
8816
8814
  }, initialPromise);
8817
8815
  }
8818
8816
 
8817
+ // src/utils/groupAndPivot/getGroupKeysForDataItem.ts
8818
+ function getGroupKeysForDataItem(data, groupBy) {
8819
+ return groupBy.reduce((groupKeys, groupBy2) => {
8820
+ const { field: groupByProperty, toKey: groupToKey } = groupBy2;
8821
+ const key = (groupToKey || DEFAULT_TO_KEY)(data[groupByProperty], data);
8822
+ groupKeys.push(key);
8823
+ return groupKeys;
8824
+ }, []);
8825
+ }
8826
+
8819
8827
  // src/components/DataSource/RowSelectionState.ts
8820
8828
  var RowSelectionState = class {
8821
8829
  constructor(state, getConfig, _forTestingOnly) {
@@ -8892,8 +8900,8 @@ var RowSelectionState = class {
8892
8900
  getGroupByLength() {
8893
8901
  return this.getConfig().groupBy.length;
8894
8902
  }
8895
- static from(rowSeleStateObject, getConfig, _forTestingOnly) {
8896
- return new RowSelectionState(rowSeleStateObject, getConfig, _forTestingOnly);
8903
+ static from(rowSeleStateObject, getConfig, overrides) {
8904
+ return new RowSelectionState(rowSeleStateObject, getConfig, overrides);
8897
8905
  }
8898
8906
  update(stateObject) {
8899
8907
  var _a, _b;
@@ -9261,6 +9269,9 @@ var RowSelectionState = class {
9261
9269
  };
9262
9270
 
9263
9271
  // src/components/InfiniteTable/api/getSelectionApi.ts
9272
+ function cloneRowSelection(rowSelection, stateOrGetDataSourceState) {
9273
+ return new RowSelectionState(rowSelection, rowSelectionStateConfigGetter(stateOrGetDataSourceState));
9274
+ }
9264
9275
  function rowSelectionStateConfigGetter(stateOrStateGetter) {
9265
9276
  return () => {
9266
9277
  const state = typeof stateOrStateGetter === "function" ? stateOrStateGetter() : stateOrStateGetter;
@@ -12415,7 +12426,7 @@ var useLicense = (licenseKey = "") => {
12415
12426
  const valid = (0, import_react44.useMemo)(() => {
12416
12427
  let valid2 = isValidLicense(licenseKey, {
12417
12428
  publishedAt: 1624970570587,
12418
- version: "0.4.11"
12429
+ version: "0.4.12"
12419
12430
  });
12420
12431
  if (!licenseKey && !valid2 && isInsidePlayground) {
12421
12432
  return true;
@@ -12750,7 +12761,14 @@ function onCellClick(context, event) {
12750
12761
  updateRowSelectionOnCellClick(context, event);
12751
12762
  }
12752
12763
  function updateRowSelectionOnCellClick(context, event) {
12753
- const { rowIndex, getDataSourceState, getComputed, dataSourceActions, api } = context;
12764
+ const {
12765
+ rowIndex,
12766
+ getDataSourceState,
12767
+ getComputed,
12768
+ dataSourceActions,
12769
+ api,
12770
+ cloneRowSelection: cloneRowSelection2
12771
+ } = context;
12754
12772
  const { multiRowSelector, renderSelectionCheckBox } = getComputed();
12755
12773
  const dataSourceState = getDataSourceState();
12756
12774
  const { selectionMode, groupBy, dataArray } = dataSourceState;
@@ -12762,7 +12780,7 @@ function updateRowSelectionOnCellClick(context, event) {
12762
12780
  return false;
12763
12781
  }
12764
12782
  let { rowSelection: rowSelectionState } = dataSourceState;
12765
- rowSelectionState = new RowSelectionState(rowSelectionState, rowSelectionStateConfigGetter(getDataSourceState));
12783
+ rowSelectionState = cloneRowSelection2(rowSelectionState);
12766
12784
  multiRowSelector.rowSelectionState = rowSelectionState;
12767
12785
  if (rowSelectionState && typeof rowSelectionState === "object") {
12768
12786
  if (event.shiftKey) {
@@ -12792,8 +12810,9 @@ function clamp(value, min, max) {
12792
12810
  }
12793
12811
 
12794
12812
  // src/components/InfiniteTable/eventHandlers/keyboardNavigation.ts
12795
- function handleRowNavigation(options) {
12796
- const { key, getState, getDataSourceState, actions, api } = options;
12813
+ function handleRowNavigation(options, event) {
12814
+ const { getState, getDataSourceState, actions, api } = options;
12815
+ const { key } = event;
12797
12816
  const dataArray = getDataSourceState().dataArray;
12798
12817
  const arrLength = dataArray.length;
12799
12818
  const state = getState();
@@ -12858,16 +12877,15 @@ function handleRowNavigation(options) {
12858
12877
  actions.activeRowIndex = activeRowIndex;
12859
12878
  return true;
12860
12879
  }
12861
- function handleCellNavigation(options) {
12880
+ function handleCellNavigation(options, event) {
12862
12881
  const {
12863
12882
  api,
12864
- key,
12865
- shiftKey,
12866
12883
  getState,
12867
12884
  getComputed,
12868
12885
  getDataSourceState,
12869
12886
  actions
12870
12887
  } = options;
12888
+ const { key, shiftKey } = event;
12871
12889
  const dataArray = getDataSourceState().dataArray;
12872
12890
  const state = getState();
12873
12891
  const { activeCellIndex, brain } = state;
@@ -12957,18 +12975,19 @@ var validKeys = {
12957
12975
  Enter: true,
12958
12976
  " ": true
12959
12977
  };
12960
- function handleKeyboardNavigation(options) {
12978
+ function handleKeyboardNavigation(options, event) {
12979
+ const { key } = event;
12961
12980
  const { getState } = options;
12962
12981
  const state = getState();
12963
12982
  const { activeRowIndex, activeCellIndex, keyboardNavigation } = state;
12964
- if (!validKeys[options.key]) {
12983
+ if (!validKeys[key]) {
12965
12984
  return false;
12966
12985
  }
12967
12986
  if (activeRowIndex != null && keyboardNavigation === "row") {
12968
- return handleRowNavigation(options);
12987
+ return handleRowNavigation(options, event);
12969
12988
  }
12970
12989
  if (activeCellIndex != null && keyboardNavigation === "cell") {
12971
- return handleCellNavigation(options);
12990
+ return handleCellNavigation(options, event);
12972
12991
  }
12973
12992
  return false;
12974
12993
  }
@@ -12979,16 +12998,15 @@ var validKeys2 = {
12979
12998
  " ": true,
12980
12999
  a: true
12981
13000
  };
12982
- function handleKeyboardSelection(context) {
13001
+ function handleKeyboardSelection(context, keyboardEvent) {
12983
13002
  const {
12984
13003
  getState,
12985
13004
  getDataSourceState,
12986
13005
  dataSourceActions,
12987
13006
  api: imperativeApi,
12988
- key,
12989
- ctrlKey,
12990
- metaKey
13007
+ cloneRowSelection: cloneRowSelection2
12991
13008
  } = context;
13009
+ const { key, ctrlKey, metaKey } = keyboardEvent;
12992
13010
  if (!validKeys2[key]) {
12993
13011
  return false;
12994
13012
  }
@@ -13017,21 +13035,21 @@ function handleKeyboardSelection(context) {
13017
13035
  return false;
13018
13036
  }
13019
13037
  if (key === "a" && (ctrlKey || metaKey)) {
13020
- const rowSelectionState = new RowSelectionState(rowSelection, rowSelectionStateConfigGetter(getDataSourceState));
13038
+ const rowSelectionState = cloneRowSelection2(rowSelection);
13021
13039
  rowSelectionState.selectAll();
13022
13040
  dataSourceActions.rowSelection = rowSelectionState;
13023
13041
  return true;
13024
13042
  }
13025
13043
  if (key === " ") {
13026
13044
  if (groupBy.length) {
13027
- if (rowInfo.isGroupRow) {
13045
+ if (rowInfo.isGroupRow && rowInfo.groupKeys) {
13028
13046
  imperativeApi.selectionApi.toggleGroupRowSelection(rowInfo.groupKeys);
13029
13047
  } else {
13030
13048
  imperativeApi.selectionApi.toggleRowSelection(rowInfo.id);
13031
13049
  }
13032
13050
  return true;
13033
13051
  } else {
13034
- const event = __spreadValues({}, context);
13052
+ const event = __spreadValues({}, keyboardEvent);
13035
13053
  const { renderSelectionCheckBox } = context.getComputed();
13036
13054
  if (renderSelectionCheckBox) {
13037
13055
  event.metaKey = false;
@@ -13046,15 +13064,14 @@ function handleKeyboardSelection(context) {
13046
13064
  // src/components/InfiniteTable/eventHandlers/onKeyDown.ts
13047
13065
  function onKeyDown(context, event) {
13048
13066
  const keyboardHandlerContext = __spreadProps(__spreadValues({}, context), {
13049
- key: event.key,
13050
- metaKey: event.metaKey,
13051
- ctrlKey: event.ctrlKey,
13052
- shiftKey: event.shiftKey
13067
+ cloneRowSelection: (rowSelection) => {
13068
+ return cloneRowSelection(rowSelection, context.getDataSourceState);
13069
+ }
13053
13070
  });
13054
- if (handleKeyboardSelection(keyboardHandlerContext)) {
13071
+ if (handleKeyboardSelection(keyboardHandlerContext, event)) {
13055
13072
  event.preventDefault();
13056
13073
  }
13057
- if (handleKeyboardNavigation(keyboardHandlerContext)) {
13074
+ if (handleKeyboardNavigation(keyboardHandlerContext, event)) {
13058
13075
  event.preventDefault();
13059
13076
  }
13060
13077
  }
@@ -13075,7 +13092,10 @@ function useEventHandlersContext() {
13075
13092
  getState,
13076
13093
  actions,
13077
13094
  getDataSourceState,
13078
- dataSourceActions
13095
+ dataSourceActions,
13096
+ cloneRowSelection: (rowSelection) => {
13097
+ return cloneRowSelection(rowSelection, getDataSourceState);
13098
+ }
13079
13099
  };
13080
13100
  return context2;
13081
13101
  }, [getState, actions, getDataSourceState, dataSourceActions]);
@@ -13085,13 +13105,7 @@ function handleDOMEvents() {
13085
13105
  const context = useEventHandlersContext();
13086
13106
  (0, import_react48.useEffect)(() => {
13087
13107
  const removeOnKeyDown = context.getState().keyDown.onChange((event) => {
13088
- onKeyDown(__spreadProps(__spreadValues({}, context), {
13089
- key: event.key,
13090
- metaKey: event.metaKey,
13091
- ctrlKey: event.ctrlKey,
13092
- shiftKey: event.shiftKey,
13093
- preventDefault: () => event.preventDefault()
13094
- }), event);
13108
+ onKeyDown(context, event);
13095
13109
  });
13096
13110
  function cellClickHandler(cellClickParam) {
13097
13111
  if (!cellClickParam) {
@@ -13105,10 +13119,10 @@ function handleDOMEvents() {
13105
13119
  key: "",
13106
13120
  preventDefault: () => event.preventDefault()
13107
13121
  };
13108
- onCellClick(__spreadValues(__spreadProps(__spreadValues({}, context), {
13122
+ onCellClick(__spreadProps(__spreadValues({}, context), {
13109
13123
  rowIndex: cellClickParam.rowIndex,
13110
13124
  colIndex: cellClickParam.colIndex
13111
- }), virtualEvent), virtualEvent);
13125
+ }), virtualEvent);
13112
13126
  }
13113
13127
  const removeOnCellClick = context.getState().cellClick.onChange(cellClickHandler);
13114
13128
  return () => {
@@ -13303,6 +13317,241 @@ InfiniteTable.defaultProps = {
13303
13317
  columnHeaderHeight: toCSSVarName(columnHeaderHeightName)
13304
13318
  };
13305
13319
 
13320
+ // src/components/Menu/index.tsx
13321
+ var React39 = __toModule(require("react"));
13322
+ var import_react49 = __toModule(require("react"));
13323
+
13324
+ // src/components/Menu/MenuCls.css.ts
13325
+ var import_createRuntimeFn7 = __toModule(require_vanilla_extract_recipes_createRuntimeFn_cjs());
13326
+ var MenuCls = "db3arf0 _16lm1iw0 _16lm1iw1 _16lm1iw13 _16lm1iw1j _16lm1iw7";
13327
+ var MenuItemCls = (0, import_createRuntimeFn7.createRuntimeFn)({ defaultClassName: "db3arf2 _16lm1iww _16lm1iw1n _16lm1iw14", variantClassNames: { disabled: { true: "db3arf3 _16lm1iwg _16lm1iw14", false: "_16lm1iwf" }, hover: { true: "db3arf5", false: "db3arf6" }, pressed: { false: "db3arf7", true: "db3arf8" }, active: { true: "db3arf9", false: "db3arfa" } }, defaultVariants: {}, compoundVariants: [[{ pressed: true, hover: true }, "db3arfb"]] });
13328
+ var MenuRowCls = "_16lm1iwx";
13329
+ var MenuSeparatorCls = "db3arfc";
13330
+
13331
+ // src/components/Menu/index.tsx
13332
+ var SEPARATOR = "-";
13333
+ function MenuSeparator() {
13334
+ return /* @__PURE__ */ React39.createElement("hr", {
13335
+ className: MenuSeparatorCls
13336
+ });
13337
+ }
13338
+ var toRuntimeItem = ({ columns, activeItemKey }, item) => {
13339
+ const menuItem = item && (item.key != null || item.label != null) ? item : null;
13340
+ const menuDecoration = menuItem === null ? item === SEPARATOR ? /* @__PURE__ */ React39.createElement(MenuSeparator, null) : item : null;
13341
+ const runtimeItem = menuItem != null ? {
13342
+ type: "item",
13343
+ disabled: !!menuItem.disabled,
13344
+ active: menuItem.key === activeItemKey,
13345
+ value: menuItem,
13346
+ span: menuItem.span || 1,
13347
+ key: menuItem.key,
13348
+ menu: menuItem.menu || null
13349
+ } : {
13350
+ type: "decoration",
13351
+ value: menuDecoration,
13352
+ span: columns.length,
13353
+ style: {
13354
+ gridColumnStart: 1,
13355
+ gridColumnEnd: columns.length + 10
13356
+ }
13357
+ };
13358
+ return runtimeItem;
13359
+ };
13360
+ function childrenToRuntimeItems(context, children) {
13361
+ return React39.Children.map(children, (child) => {
13362
+ if (child == null ? void 0 : child.props.__is_menu_item) {
13363
+ const itemProps = __spreadValues({}, child.props);
13364
+ if (!itemProps.key) {
13365
+ itemProps.key = child.key;
13366
+ }
13367
+ if (!itemProps.description) {
13368
+ itemProps.description = child.props.children;
13369
+ }
13370
+ if (!itemProps.label) {
13371
+ itemProps.label = itemProps.children;
13372
+ }
13373
+ return toRuntimeItem(context, itemProps);
13374
+ }
13375
+ return toRuntimeItem(context, child);
13376
+ }) || [];
13377
+ }
13378
+ var defaultColumns = [
13379
+ {
13380
+ name: "label"
13381
+ }
13382
+ ];
13383
+ function Menu(props) {
13384
+ const _a = props, {
13385
+ children,
13386
+ items,
13387
+ columns: cols,
13388
+ addSubmenuColumnIfNeeded
13389
+ } = _a, domProps = __objRest(_a, [
13390
+ "children",
13391
+ "items",
13392
+ "columns",
13393
+ "addSubmenuColumnIfNeeded"
13394
+ ]);
13395
+ const [activeItemKey, setActiveItemKey] = (0, import_react49.useState)(null);
13396
+ const columns = cols || defaultColumns;
13397
+ let runtimeItems = [];
13398
+ let renderedChildren = null;
13399
+ const context = { columns, activeItemKey };
13400
+ if (items) {
13401
+ runtimeItems = items.map(toRuntimeItem.bind(null, context));
13402
+ } else if (!items && typeof children !== "function") {
13403
+ runtimeItems = childrenToRuntimeItems(context, children);
13404
+ }
13405
+ if (addSubmenuColumnIfNeeded) {
13406
+ const hasSubmenus = runtimeItems.filter((item) => item.type === "item" && item.menu != null).length > 0;
13407
+ if (hasSubmenus && !columns.find((col) => col.name == "submenu")) {
13408
+ columns.push({
13409
+ name: "submenu",
13410
+ render: ({ domProps: domProps2, item }) => {
13411
+ return item.menu ? /* @__PURE__ */ React39.createElement("div", __spreadValues({}, domProps2), /* @__PURE__ */ React39.createElement(ExpanderIcon, null)) : /* @__PURE__ */ React39.createElement("div", __spreadValues({}, domProps2));
13412
+ }
13413
+ });
13414
+ }
13415
+ }
13416
+ renderedChildren = runtimeItems.map((runtimeItem, index) => /* @__PURE__ */ React39.createElement(RuntimeItemRenderer, {
13417
+ columns,
13418
+ item: runtimeItem,
13419
+ index,
13420
+ onClick: (item) => setActiveItemKey(item.key)
13421
+ }));
13422
+ const gridTemplateColumns = columns.map((col) => {
13423
+ return col.width || (typeof col.flex === "number" ? `${col.flex}fr` : col.flex) || "auto";
13424
+ }).join(" ");
13425
+ const style = __spreadProps(__spreadValues({}, domProps.style), {
13426
+ gridTemplateColumns,
13427
+ gridTemplateRows: runtimeItems.map(() => `auto`).join(" ")
13428
+ });
13429
+ function handleKeydown(event) {
13430
+ const selectableRuntimeItems = runtimeItems.filter((item) => item.type === "item" && !item.disabled);
13431
+ let activeIndex = selectableRuntimeItems.findIndex((runtimeItem) => runtimeItem.key === activeItemKey);
13432
+ let newActiveIndex = activeIndex;
13433
+ const validKeys3 = {
13434
+ ArrowUp: () => {
13435
+ newActiveIndex--;
13436
+ },
13437
+ ArrowDown: () => {
13438
+ newActiveIndex++;
13439
+ },
13440
+ PageUp: () => {
13441
+ newActiveIndex = 0;
13442
+ },
13443
+ PageDown: () => {
13444
+ newActiveIndex = selectableRuntimeItems.length - 1;
13445
+ }
13446
+ };
13447
+ const fn = validKeys3[event.key];
13448
+ if (fn) {
13449
+ fn();
13450
+ }
13451
+ newActiveIndex = clamp(newActiveIndex, 0, selectableRuntimeItems.length - 1);
13452
+ if (newActiveIndex != activeIndex) {
13453
+ setActiveItemKey(selectableRuntimeItems[newActiveIndex].key);
13454
+ }
13455
+ }
13456
+ return /* @__PURE__ */ React39.createElement("div", __spreadProps(__spreadValues({}, domProps), {
13457
+ onKeyDown: (event) => {
13458
+ if (domProps.onKeyDown) {
13459
+ domProps.onKeyDown(event);
13460
+ }
13461
+ handleKeydown(event);
13462
+ },
13463
+ tabIndex: 0,
13464
+ className: join(MenuCls, domProps.className),
13465
+ style
13466
+ }), renderedChildren);
13467
+ }
13468
+ var menuDefaultProps = {
13469
+ addSubmenuColumnIfNeeded: true
13470
+ };
13471
+ Menu.defaultProps = menuDefaultProps;
13472
+ function RuntimeItemRenderer(props) {
13473
+ const [hover, setHover] = React39.useState(false);
13474
+ const [pressed, setPressed] = React39.useState(false);
13475
+ const { columns, item, index } = props;
13476
+ const key = item.type === "item" ? item.value.key : index;
13477
+ let content = null;
13478
+ if (item.type === "decoration") {
13479
+ content = /* @__PURE__ */ React39.createElement("div", {
13480
+ style: item.style
13481
+ }, item.value);
13482
+ } else {
13483
+ let spanIndex = 0;
13484
+ content = columns.map((col, i) => {
13485
+ const target = item.value;
13486
+ const field = col.field || col.name;
13487
+ const start = i + 1;
13488
+ const end = start + item.span;
13489
+ if (start < spanIndex) {
13490
+ return null;
13491
+ }
13492
+ spanIndex = end;
13493
+ const style = __spreadProps(__spreadValues(__spreadValues({}, col.style), item.style), {
13494
+ gridColumnStart: start,
13495
+ gridColumnEnd: end
13496
+ });
13497
+ const domProps = {
13498
+ style,
13499
+ className: MenuItemCls({
13500
+ hover,
13501
+ disabled: !!item.disabled,
13502
+ active: item.active,
13503
+ pressed
13504
+ }),
13505
+ onMouseEnter: () => {
13506
+ if (!item.disabled) {
13507
+ setHover(true);
13508
+ }
13509
+ },
13510
+ onMouseLeave: () => {
13511
+ if (!item.disabled) {
13512
+ setHover(false);
13513
+ }
13514
+ },
13515
+ onMouseDown: () => {
13516
+ if (!item.disabled) {
13517
+ setPressed(true);
13518
+ }
13519
+ },
13520
+ onMouseUp: () => {
13521
+ if (!item.disabled) {
13522
+ setPressed(false);
13523
+ }
13524
+ },
13525
+ onClick: () => {
13526
+ if (!item.disabled) {
13527
+ props.onClick(item);
13528
+ }
13529
+ }
13530
+ };
13531
+ return col.render ? /* @__PURE__ */ React39.createElement(RenderHookComponent, {
13532
+ render: col.render,
13533
+ renderParam: {
13534
+ item: target,
13535
+ column: col,
13536
+ value: target[field],
13537
+ domProps
13538
+ }
13539
+ }) : /* @__PURE__ */ React39.createElement("div", __spreadValues({
13540
+ key: `${key}-${field}`
13541
+ }, domProps), target[field]);
13542
+ }).filter(Boolean);
13543
+ }
13544
+ return /* @__PURE__ */ React39.createElement("div", {
13545
+ className: MenuRowCls
13546
+ }, content);
13547
+ }
13548
+ function MenuItem(_props) {
13549
+ return null;
13550
+ }
13551
+ MenuItem.defaultProps = {
13552
+ __is_menu_item: true
13553
+ };
13554
+
13306
13555
  // src/index.tsx
13307
13556
  var components = {
13308
13557
  CheckBox: InfiniteCheckBox,