@infinite-table/infinite-react 5.0.0-canary.8 → 5.0.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/index.dev.mjs CHANGED
@@ -1253,49 +1253,6 @@ function buildSubscriptionCallback(withRaf = false) {
1253
1253
  return updater;
1254
1254
  }
1255
1255
 
1256
- // src/components/InfiniteTable/vars.css.ts
1257
- var ThemeVars = { color: { accent: "var(--infinite-accent-color)", success: "var(--infinite-success-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)", iconSize: "var(--infinite-icon-size)", runtime: { bodyWidth: "var(--infinite-runtime-body-content-width)", totalVisibleColumnsWidthValue: "var(--infinite-runtime-total-visible-columns-width)", totalVisibleColumnsWidthVar: "var(--infinite-runtime-total-visible-columns-width-var)", visibleColumnsCount: "var(--infinite-runtime-visible-columns-count)", browserScrollbarWidth: "var(--infinite-runtime-browser-scrollbar-width)" }, 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)", border: "var(--infinite-header-cell-border)", 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)", menuIconLineWidth: "var(--infinite-header-cell-menu-icon-line-width)", sortIconMargin: "var(--infinite-header-cell-sort-icon-margin)", borderRight: "var(--infinite-header-cell-border-right)", 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)", filterOperatorPaddingX: "var(--infinite-filter-operator-padding-x)", filterEditorPaddingX: "var(--infinite-filter-editor-padding-x)", filterEditorMarginX: "var(--infinite-filter-editor-margin-x)", filterOperatorPaddingY: "var(--infinite-filter-operator-padding-y)", filterEditorPaddingY: "var(--infinite-filter-editor-padding-y)", filterEditorMarginY: "var(--infinite-filter-editor-margin-y)", filterEditorBackground: "var(--infinite-filter-editor-background)", filterEditorBorder: "var(--infinite-filter-editor-border)", filterEditorFocusBorderColor: "var(--infinite-filter-editor-focus-border-color)", filterEditorBorderRadius: "var(--infinite-filter-editor-border-radius)", filterEditorColor: "var(--infinite-filter-editor-color)" }, ActiveCellIndicator: { inset: "var(--infinite-active-cell-indicator-inset)" }, Cell: { flashingDuration: "var(--infinite-flashing-duration)", flashingAnimationName: "var(--infinite-flashing-animation-name)", flashingOverlayZIndex: "var(--infinite-flashing-overlay-z-index)", flashingBackground: "var(--infinite-flashing-background)", flashingUpBackground: "var(--infinite-flashing-up-background)", flashingDownBackground: "var(--infinite-flashing-down-background)", padding: "var(--infinite-cell-padding)", borderWidth: "var(--infinite-cell-border-width)", border: "var(--infinite-cell-border)", borderLeft: "var(--infinite-cell-border-left)", borderRight: "var(--infinite-cell-border-right)", borderTop: "var(--infinite-cell-border-top)", 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)", selectedBackground: "var(--infinite-selected-cell-background)", selectedBackgroundDefault: "var(--infinite-selected-cell-background-default)", selectedBackgroundAlpha: "var(--infinite-selected-cell-background-alpha)", selectedBackgroundAlphaWhenTableUnfocused: "var(--infinite-selected-cell-background-alpha--table-unfocused)", selectedBorderColor: "var(--infinite-selected-cell-border-color)", selectedBorderWidth: "var(--infinite-selected-cell-border-width)", selectedBorderStyle: "var(--infinite-selected-cell-border-style)", selectedBorder: "var(--infinite-selected-cell-border)", activeBackgroundAlpha: "var(--infinite-active-cell-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-cell-background-alpha--table-unfocused)", activeBackground: "var(--infinite-active-cell-background)", activeBackgroundDefault: "var(--infinite-active-cell-background-default)", 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)", separatorColor: "var(--infinite-menu-separator-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)", itemActiveBackground: "var(--infinite-menu-item-active-background)", itemActiveOpacity: "var(--infinite-menu-item-active-opacity)", itemPressedOpacity: "var(--infinite-menu-item-pressed-opacity)", itemPressedBackground: "var(--infinite-menu-item-pressed-background)", itemDisabledOpacity: "var(--infinite-menu-item-disabled-opacity)", borderRadius: "var(--infinite-menu-border-radius)", shadowColor: "var(--infinite-menu-shadow-color)" }, RowDetail: { background: "var(--infinite-rowdetail-background)", padding: "var(--infinite-rowdetail-padding)", gridHeight: "var(--infinite-rowdetail-grid-height)" }, Row: { background: "var(--infinite-row-background)", oddBackground: "var(--infinite-row-odd-background)", disabledBackground: "var(--infinite-row-disabled-background)", oddDisabledBackground: "var(--infinite-row-odd-disabled-background)", selectedBackground: "var(--infinite-row-selected-background)", disabledOpacity: "var(--infinite-row-disabled-opacity)", 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)", selectedDisabledBackground: "var(--infinite-row-selected-disabled-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)" } } };
1258
- var columnHeaderHeightName = "column-header-height";
1259
-
1260
- // src/components/HeadlessTable/ReactHeadlessTableRenderer.tsx
1261
- import * as React9 from "react";
1262
-
1263
- // src/utils/mathIntersection.ts
1264
- function arrayIntersection(...arrays) {
1265
- if (!arrays.length) {
1266
- return [];
1267
- }
1268
- const map2 = /* @__PURE__ */ new Map();
1269
- arrays.forEach((arr) => {
1270
- for (let i = 0, len2 = arr.length; i < len2; i++) {
1271
- const item = arr[i];
1272
- const count = map2.get(item) ?? 0;
1273
- map2.set(item, count + 1);
1274
- }
1275
- return map2;
1276
- });
1277
- const len = arrays.length;
1278
- return arrays[0].filter((x) => {
1279
- return map2.get(x) === len;
1280
- });
1281
- }
1282
-
1283
- // src/utils/raf.ts
1284
- var raf = getGlobal().requestAnimationFrame || ((fn) => {
1285
- return setTimeout(fn, 16);
1286
- });
1287
- var cancelRaf = getGlobal().cancelAnimationFrame || ((timeoutId) => {
1288
- return clearTimeout(timeoutId);
1289
- });
1290
-
1291
- // src/utils/stripVar.ts
1292
- function stripVar(cssVariableWithVarString) {
1293
- return cssVariableWithVarString.slice(4, -1);
1294
- }
1295
-
1296
- // src/components/InfiniteTable/internalVars.css.ts
1297
- var InternalVars = { currentColumnTransformX: "var(--currentColumnTransformX__16hkbkc0)", y: "var(--y__16hkbkc1)", currentFlashingBackground: "var(--currentFlashingBackground__16hkbkc2)", currentFlashingDuration: "var(--currentFlashingDuration__16hkbkc3)", activeCellRowOffset: "var(--activeCellRowOffset__16hkbkc4)", activeCellRowOffsetX: "var(--activeCellRowOffsetX__16hkbkc5)", activeCellRowHeight: "var(--activeCellRowHeight__16hkbkc6)", activeCellOffsetX: "var(--activeCellOffsetX__16hkbkc7)", activeCellOffsetY: "var(--activeCellOffsetY__16hkbkc8)", scrollTopForActiveRow: "var(--scrollTopForActiveRow__16hkbkc9)", scrollLeftForActiveRowWhenHorizontalLayout: "var(--scrollLeftForActiveRowWhenHorizontalLayout__16hkbkca)", activeCellColWidth: "var(--activeCellColWidth__16hkbkcb)", activeCellColOffset: "var(--activeCellColOffset__16hkbkcc)", columnReorderEffectDurationAtIndex: "var(--columnReorderEffectDurationAtIndex__16hkbkcd)", columnWidthAtIndex: "var(--columnWidthAtIndex__16hkbkce)", columnOffsetAtIndex: "var(--columnOffsetAtIndex__16hkbkcf)", columnOffsetAtIndexWhileReordering: "var(--columnOffsetAtIndexWhileReordering__16hkbkcg)", columnZIndexAtIndex: "var(--columnZIndexAtIndex__16hkbkch)", pinnedStartWidth: "var(--pinnedStartWidth__16hkbkci)", pinnedEndWidth: "var(--pinnedEndWidth__16hkbkcj)", pinnedEndOffset: "var(--pinnedEndOffset__16hkbkck)", computedVisibleColumnsCount: "var(--computedVisibleColumnsCount__16hkbkcl)", baseZIndexForCells: "var(--baseZIndexForCells__16hkbkcm)", bodyWidth: "var(--bodyWidth__16hkbkcn)", bodyHeight: "var(--bodyHeight__16hkbkco)", scrollbarWidthHorizontal: "var(--scrollbarWidthHorizontal__16hkbkcp)", scrollbarWidthVertical: "var(--scrollbarWidthVertical__16hkbkcq)", scrollLeft: "var(--scrollLeft__16hkbkcr)", scrollTop: "var(--scrollTop__16hkbkcs)" };
1298
-
1299
1256
  // src/utils/selectParent.ts
1300
1257
  function selectParent(el, selector2) {
1301
1258
  let node = el;
@@ -1331,12 +1288,24 @@ function selectParentUntil(el, selector2, root) {
1331
1288
  return null;
1332
1289
  }
1333
1290
 
1291
+ // src/utils/stripVar.ts
1292
+ function stripVar(cssVariableWithVarString) {
1293
+ return cssVariableWithVarString.slice(4, -1);
1294
+ }
1295
+
1334
1296
  // src/components/InfiniteTable/internalProps.ts
1335
1297
  var rootClassName2 = "Infinite";
1336
1298
  var internalProps = {
1337
1299
  rootClassName: rootClassName2
1338
1300
  };
1339
1301
 
1302
+ // src/components/InfiniteTable/internalVars.css.ts
1303
+ var InternalVars = { currentColumnTransformX: "var(--currentColumnTransformX__16hkbkc0)", y: "var(--y__16hkbkc1)", currentFlashingBackground: "var(--currentFlashingBackground__16hkbkc2)", currentFlashingDuration: "var(--currentFlashingDuration__16hkbkc3)", activeCellRowOffset: "var(--activeCellRowOffset__16hkbkc4)", activeCellRowOffsetX: "var(--activeCellRowOffsetX__16hkbkc5)", activeCellRowHeight: "var(--activeCellRowHeight__16hkbkc6)", activeCellOffsetX: "var(--activeCellOffsetX__16hkbkc7)", activeCellOffsetY: "var(--activeCellOffsetY__16hkbkc8)", scrollTopForActiveRow: "var(--scrollTopForActiveRow__16hkbkc9)", scrollLeftForActiveRowWhenHorizontalLayout: "var(--scrollLeftForActiveRowWhenHorizontalLayout__16hkbkca)", activeCellColWidth: "var(--activeCellColWidth__16hkbkcb)", activeCellColOffset: "var(--activeCellColOffset__16hkbkcc)", columnReorderEffectDurationAtIndex: "var(--columnReorderEffectDurationAtIndex__16hkbkcd)", columnWidthAtIndex: "var(--columnWidthAtIndex__16hkbkce)", columnOffsetAtIndex: "var(--columnOffsetAtIndex__16hkbkcf)", columnOffsetAtIndexWhileReordering: "var(--columnOffsetAtIndexWhileReordering__16hkbkcg)", columnZIndexAtIndex: "var(--columnZIndexAtIndex__16hkbkch)", pinnedStartWidth: "var(--pinnedStartWidth__16hkbkci)", pinnedEndWidth: "var(--pinnedEndWidth__16hkbkcj)", pinnedEndOffset: "var(--pinnedEndOffset__16hkbkck)", computedVisibleColumnsCount: "var(--computedVisibleColumnsCount__16hkbkcl)", baseZIndexForCells: "var(--baseZIndexForCells__16hkbkcm)", bodyWidth: "var(--bodyWidth__16hkbkcn)", bodyHeight: "var(--bodyHeight__16hkbkco)", scrollbarWidthHorizontal: "var(--scrollbarWidthHorizontal__16hkbkcp)", scrollbarWidthVertical: "var(--scrollbarWidthVertical__16hkbkcq)", scrollLeft: "var(--scrollLeft__16hkbkcr)", scrollTop: "var(--scrollTop__16hkbkcs)" };
1304
+
1305
+ // src/components/InfiniteTable/vars.css.ts
1306
+ var ThemeVars = { color: { accent: "var(--infinite-accent-color)", success: "var(--infinite-success-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)", iconSize: "var(--infinite-icon-size)", runtime: { bodyWidth: "var(--infinite-runtime-body-content-width)", totalVisibleColumnsWidthValue: "var(--infinite-runtime-total-visible-columns-width)", totalVisibleColumnsWidthVar: "var(--infinite-runtime-total-visible-columns-width-var)", visibleColumnsCount: "var(--infinite-runtime-visible-columns-count)", browserScrollbarWidth: "var(--infinite-runtime-browser-scrollbar-width)" }, 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)", border: "var(--infinite-header-cell-border)", 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)", menuIconLineWidth: "var(--infinite-header-cell-menu-icon-line-width)", sortIconMargin: "var(--infinite-header-cell-sort-icon-margin)", borderRight: "var(--infinite-header-cell-border-right)", 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)", filterOperatorPaddingX: "var(--infinite-filter-operator-padding-x)", filterEditorPaddingX: "var(--infinite-filter-editor-padding-x)", filterEditorMarginX: "var(--infinite-filter-editor-margin-x)", filterOperatorPaddingY: "var(--infinite-filter-operator-padding-y)", filterEditorPaddingY: "var(--infinite-filter-editor-padding-y)", filterEditorMarginY: "var(--infinite-filter-editor-margin-y)", filterEditorBackground: "var(--infinite-filter-editor-background)", filterEditorBorder: "var(--infinite-filter-editor-border)", filterEditorFocusBorderColor: "var(--infinite-filter-editor-focus-border-color)", filterEditorBorderRadius: "var(--infinite-filter-editor-border-radius)", filterEditorColor: "var(--infinite-filter-editor-color)" }, ActiveCellIndicator: { inset: "var(--infinite-active-cell-indicator-inset)" }, Cell: { flashingDuration: "var(--infinite-flashing-duration)", flashingAnimationName: "var(--infinite-flashing-animation-name)", flashingOverlayZIndex: "var(--infinite-flashing-overlay-z-index)", flashingBackground: "var(--infinite-flashing-background)", flashingUpBackground: "var(--infinite-flashing-up-background)", flashingDownBackground: "var(--infinite-flashing-down-background)", padding: "var(--infinite-cell-padding)", borderWidth: "var(--infinite-cell-border-width)", border: "var(--infinite-cell-border)", borderLeft: "var(--infinite-cell-border-left)", borderRight: "var(--infinite-cell-border-right)", borderTop: "var(--infinite-cell-border-top)", 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)", horizontalLayoutColumnReorderDisabledPageOpacity: "var(--infinite-horizontal-layout-column-reorder-disabled-page-opacity)", color: "var(--infinite-cell-color)", selectedBackground: "var(--infinite-selected-cell-background)", selectedBackgroundDefault: "var(--infinite-selected-cell-background-default)", selectedBackgroundAlpha: "var(--infinite-selected-cell-background-alpha)", selectedBackgroundAlphaWhenTableUnfocused: "var(--infinite-selected-cell-background-alpha--table-unfocused)", selectedBorderColor: "var(--infinite-selected-cell-border-color)", selectedBorderWidth: "var(--infinite-selected-cell-border-width)", selectedBorderStyle: "var(--infinite-selected-cell-border-style)", selectedBorder: "var(--infinite-selected-cell-border)", activeBackgroundAlpha: "var(--infinite-active-cell-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-cell-background-alpha--table-unfocused)", activeBackground: "var(--infinite-active-cell-background)", activeBackgroundDefault: "var(--infinite-active-cell-background-default)", 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)", separatorColor: "var(--infinite-menu-separator-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)", itemActiveBackground: "var(--infinite-menu-item-active-background)", itemActiveOpacity: "var(--infinite-menu-item-active-opacity)", itemPressedOpacity: "var(--infinite-menu-item-pressed-opacity)", itemPressedBackground: "var(--infinite-menu-item-pressed-background)", itemDisabledOpacity: "var(--infinite-menu-item-disabled-opacity)", borderRadius: "var(--infinite-menu-border-radius)", shadowColor: "var(--infinite-menu-shadow-color)" }, RowDetail: { background: "var(--infinite-rowdetail-background)", padding: "var(--infinite-rowdetail-padding)", gridHeight: "var(--infinite-rowdetail-grid-height)" }, Row: { background: "var(--infinite-row-background)", oddBackground: "var(--infinite-row-odd-background)", disabledBackground: "var(--infinite-row-disabled-background)", oddDisabledBackground: "var(--infinite-row-odd-disabled-background)", selectedBackground: "var(--infinite-row-selected-background)", disabledOpacity: "var(--infinite-row-disabled-opacity)", 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)", selectedDisabledBackground: "var(--infinite-row-selected-disabled-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)" } } };
1307
+ var columnHeaderHeightName = "column-header-height";
1308
+
1340
1309
  // src/components/InfiniteTable/utils/infiniteDOMUtils.ts
1341
1310
  var InfiniteSelector = `.${internalProps.rootClassName}`;
1342
1311
  function getParentInfiniteNode(node) {
@@ -1359,34 +1328,20 @@ function setInfiniteVarOnRoot(varName, varValue, node) {
1359
1328
  }
1360
1329
  function setInfiniteVarOnNode(varName, varValue, node) {
1361
1330
  if (node) {
1362
- const prop = InternalVars[varName] ? stripVar(InternalVars[varName]) : varName;
1331
+ const name = varName;
1332
+ const prop = InternalVars[name] ? stripVar(InternalVars[name]) : varName;
1363
1333
  node.style.setProperty(prop, `${varValue}`);
1364
1334
  }
1365
1335
  }
1366
1336
  function setInfiniteVarsOnNode(vars, node) {
1367
1337
  if (node) {
1368
1338
  for (var varName in vars) {
1369
- node.style.setProperty(
1370
- InternalVars[varName] ? stripVar(InternalVars[varName]) : varName,
1371
- `${vars[varName]}`
1372
- );
1339
+ const propName = InternalVars[varName] ? stripVar(InternalVars[varName]) : varName;
1340
+ const propValue = `${vars[varName]}`;
1341
+ node.style.setProperty(propName, propValue);
1373
1342
  }
1374
1343
  }
1375
1344
  }
1376
- function setInfiniteColumnWidth(colIndex, colWidth, node) {
1377
- setInfiniteVarOnRoot(
1378
- `${columnWidthAtIndex}-${colIndex}`,
1379
- typeof colWidth === "number" ? colWidth + "px" : colWidth,
1380
- node
1381
- );
1382
- }
1383
- function setInfiniteColumnOffset(colIndex, colOffset, node) {
1384
- setInfiniteVarOnRoot(
1385
- `${columnOffsetAtIndex}-${colIndex}`,
1386
- typeof colOffset === "number" ? colOffset + "px" : colOffset,
1387
- node
1388
- );
1389
- }
1390
1345
  function addToInfiniteColumnOffset(column, amountToAdd, node) {
1391
1346
  setInfiniteVarOnRoot(
1392
1347
  `${columnOffsetAtIndex}-${column.computedVisibleIndex}`,
@@ -1423,12 +1378,42 @@ function restoreInfiniteColumnReorderDuration(colIndex, node) {
1423
1378
  node
1424
1379
  );
1425
1380
  }
1426
- function getCSSVarNameForColWidth(colIndex) {
1427
- return `${columnWidthAtIndex}-${colIndex}`;
1428
- }
1429
- function getCSSVarNameForColOffset(colIndex) {
1430
- return `${columnOffsetAtIndex}-${colIndex}`;
1431
- }
1381
+ var InternalVarUtils = {
1382
+ columnWidths: {
1383
+ get(index) {
1384
+ return `var(${this.getVarName(index)})`;
1385
+ },
1386
+ getVarName(index) {
1387
+ return this.varName.get(index);
1388
+ },
1389
+ varName: {
1390
+ get(index) {
1391
+ return `${columnWidthAtIndex}-${index}`;
1392
+ }
1393
+ },
1394
+ set(index, value, node) {
1395
+ value = typeof value === "number" ? value + "px" : value;
1396
+ setInfiniteVarOnRoot(this.varName.get(index), value, node);
1397
+ }
1398
+ },
1399
+ columnOffsets: {
1400
+ get(index) {
1401
+ return `var(${this.getVarName(index)})`;
1402
+ },
1403
+ getVarName(index) {
1404
+ return this.varName.get(index);
1405
+ },
1406
+ varName: {
1407
+ get(index) {
1408
+ return `${columnOffsetAtIndex}-${index}`;
1409
+ }
1410
+ },
1411
+ set(index, value, node) {
1412
+ value = typeof value === "number" ? value + "px" : value;
1413
+ setInfiniteVarOnRoot(this.varName.get(index), value, node);
1414
+ }
1415
+ }
1416
+ };
1432
1417
  function setInfiniteScrollPosition(scrollPosition, node) {
1433
1418
  setInfiniteVarsOnNode(
1434
1419
  {
@@ -1439,6 +1424,37 @@ function setInfiniteScrollPosition(scrollPosition, node) {
1439
1424
  );
1440
1425
  }
1441
1426
 
1427
+ // src/components/HeadlessTable/ReactHeadlessTableRenderer.tsx
1428
+ import * as React9 from "react";
1429
+
1430
+ // src/utils/mathIntersection.ts
1431
+ function arrayIntersection(...arrays) {
1432
+ if (!arrays.length) {
1433
+ return [];
1434
+ }
1435
+ const map2 = /* @__PURE__ */ new Map();
1436
+ arrays.forEach((arr) => {
1437
+ for (let i = 0, len2 = arr.length; i < len2; i++) {
1438
+ const item = arr[i];
1439
+ const count = map2.get(item) ?? 0;
1440
+ map2.set(item, count + 1);
1441
+ }
1442
+ return map2;
1443
+ });
1444
+ const len = arrays.length;
1445
+ return arrays[0].filter((x) => {
1446
+ return map2.get(x) === len;
1447
+ });
1448
+ }
1449
+
1450
+ // src/utils/raf.ts
1451
+ var raf = getGlobal().requestAnimationFrame || ((fn) => {
1452
+ return setTimeout(fn, 16);
1453
+ });
1454
+ var cancelRaf = getGlobal().cancelAnimationFrame || ((timeoutId) => {
1455
+ return clearTimeout(timeoutId);
1456
+ });
1457
+
1442
1458
  // src/components/VirtualBrain/MatrixBrain.ts
1443
1459
  var import_binary_search = __toESM(require_binary_search());
1444
1460
 
@@ -1449,7 +1465,41 @@ var ALL_DIRECTIONS = {
1449
1465
  vertical: true
1450
1466
  };
1451
1467
 
1468
+ // src/components/VirtualBrain/getGreatestCountVisibleInSize.ts
1469
+ function getGreatestCountVisibleInSize(availableSize, itemSizes) {
1470
+ const len = itemSizes.length;
1471
+ if (!len) {
1472
+ return 0;
1473
+ }
1474
+ let maxCount = -1;
1475
+ for (let start = 0; start < len; start++) {
1476
+ let sum2 = 0;
1477
+ let count = 0;
1478
+ if (len - start <= maxCount) {
1479
+ break;
1480
+ }
1481
+ for (let i = start; i < len; i++) {
1482
+ sum2 += itemSizes[i];
1483
+ count++;
1484
+ if (sum2 > availableSize) {
1485
+ if (count > maxCount) {
1486
+ maxCount = count;
1487
+ }
1488
+ break;
1489
+ }
1490
+ }
1491
+ }
1492
+ return maxCount < 0 ? len : Math.min(maxCount, len);
1493
+ }
1494
+
1452
1495
  // src/components/VirtualBrain/MatrixBrain.ts
1496
+ var DEFAULT_EXTEND_BY = {
1497
+ start: 0,
1498
+ end: 0
1499
+ };
1500
+ var immediateCallback = (fn) => {
1501
+ fn();
1502
+ };
1453
1503
  var getRenderRangeCellCount = (range) => {
1454
1504
  const { start, end } = range;
1455
1505
  const [startRow, startCol] = start;
@@ -1474,6 +1524,8 @@ var MatrixBrain = class extends Logger {
1474
1524
  const logName = `MatrixBrain${name ? `:${name}` : ""}`;
1475
1525
  super(logName);
1476
1526
  this.scrolling = false;
1527
+ this.RENDER_COUNT_SAFETY_MARGIN_START = 1;
1528
+ this.RENDER_COUNT_SAFETY_MARGIN_END = 1;
1477
1529
  this.availableWidth = 0;
1478
1530
  this.availableRenderWidth = 0;
1479
1531
  this.isHorizontalLayoutBrain = false;
@@ -1482,6 +1534,7 @@ var MatrixBrain = class extends Logger {
1482
1534
  this.availableRenderHeight = 0;
1483
1535
  this.cols = 0;
1484
1536
  this.rows = 0;
1537
+ this.alwaysRenderedColumns = /* @__PURE__ */ new Set();
1485
1538
  this._rowsPerPage = 0;
1486
1539
  this.rowHeight = 0;
1487
1540
  this.colWidth = 0;
@@ -1489,6 +1542,8 @@ var MatrixBrain = class extends Logger {
1489
1542
  this.horizontalTotalSize = 0;
1490
1543
  this.horizontalRenderCount = void 0;
1491
1544
  this.verticalRenderCount = void 0;
1545
+ this.horizontalExtendRangeBy = DEFAULT_EXTEND_BY;
1546
+ this.verticalExtendRangeBy = DEFAULT_EXTEND_BY;
1492
1547
  this.horizontalRenderRange = {
1493
1548
  startIndex: 0,
1494
1549
  endIndex: 0
@@ -1594,14 +1649,15 @@ var MatrixBrain = class extends Logger {
1594
1649
  });
1595
1650
  });
1596
1651
  };
1597
- this.notifyVerticalRenderRangeChange = () => {
1652
+ this.notifyVerticalRenderRangeChange = (immediate = false) => {
1598
1653
  if (this.destroyed) {
1599
1654
  return;
1600
1655
  }
1601
1656
  const fns = this.onVerticalRenderRangeChangeFns;
1602
1657
  const range = this.verticalRenderRange;
1658
+ const callback = immediate ? immediateCallback : raf2;
1603
1659
  fns.forEach((fn) => {
1604
- raf2(() => {
1660
+ callback(() => {
1605
1661
  if (this.destroyed) {
1606
1662
  return;
1607
1663
  }
@@ -1611,14 +1667,15 @@ var MatrixBrain = class extends Logger {
1611
1667
  });
1612
1668
  });
1613
1669
  };
1614
- this.notifyHorizontalRenderRangeChange = () => {
1670
+ this.notifyHorizontalRenderRangeChange = (immediate = false) => {
1615
1671
  if (this.destroyed) {
1616
1672
  return;
1617
1673
  }
1618
1674
  const fns = this.onHorizontalRenderRangeChangeFns;
1619
1675
  const range = this.horizontalRenderRange;
1676
+ const callback = immediate ? immediateCallback : raf2;
1620
1677
  fns.forEach((fn) => {
1621
- raf2(() => {
1678
+ callback(() => {
1622
1679
  if (this.destroyed) {
1623
1680
  return;
1624
1681
  }
@@ -1628,34 +1685,6 @@ var MatrixBrain = class extends Logger {
1628
1685
  });
1629
1686
  });
1630
1687
  };
1631
- this.computeDirectionalRenderCount = (direction, itemSize, count, theRenderSize) => {
1632
- let renderCount = 0;
1633
- let size = direction === "horizontal" ? theRenderSize.width : theRenderSize.height;
1634
- size -= this.getFixedSize(direction);
1635
- if (size <= 0) {
1636
- return 0;
1637
- }
1638
- if (typeof itemSize === "function") {
1639
- const sizes = [];
1640
- for (let i = 0; i < count; i++) {
1641
- sizes.push(this.getItemSize(i, direction));
1642
- }
1643
- sizes.sort(SORT_ASC);
1644
- let sum2 = 0;
1645
- for (let i = 0; i < count; i++) {
1646
- sum2 += sizes[i];
1647
- renderCount++;
1648
- if (sum2 > size) {
1649
- break;
1650
- }
1651
- }
1652
- renderCount += 1;
1653
- } else {
1654
- renderCount = (itemSize ? Math.ceil(size / itemSize) : 0) + 1;
1655
- }
1656
- renderCount = Math.min(count, renderCount);
1657
- return renderCount;
1658
- };
1659
1688
  this.isColFixedEnd = (colIndex) => {
1660
1689
  if (!this.fixedColsEnd) {
1661
1690
  return false;
@@ -1922,7 +1951,8 @@ var MatrixBrain = class extends Logger {
1922
1951
  };
1923
1952
  };
1924
1953
  this.computeDirectionalRenderRange = (direction) => {
1925
- const renderCount = direction === "horizontal" ? this.horizontalRenderCount : this.verticalRenderCount;
1954
+ const itemSize = direction === "horizontal" ? this.colWidth : this.rowHeight;
1955
+ let renderCount = direction === "horizontal" ? this.horizontalRenderCount : this.verticalRenderCount;
1926
1956
  const count = direction === "horizontal" ? this.cols : this.rows;
1927
1957
  if (!renderCount) {
1928
1958
  return {
@@ -1933,7 +1963,22 @@ var MatrixBrain = class extends Logger {
1933
1963
  const fixedStartIndex = (direction === "horizontal" ? this.fixedColsStart : this.fixedRowsStart) || 0;
1934
1964
  let scrollPositionForDirection = direction === "horizontal" ? this.scrollPosition.scrollLeft : this.scrollPosition.scrollTop;
1935
1965
  scrollPositionForDirection += this.getFixedStartSize(direction);
1966
+ const isItemSizeConstant = typeof itemSize !== "function";
1967
+ const extendBy = direction === "horizontal" ? this.horizontalExtendRangeBy : this.verticalExtendRangeBy;
1936
1968
  let startIndex = this.getItemAt(scrollPositionForDirection, direction);
1969
+ let extendByStart = extendBy.start || 0;
1970
+ let extendByEnd = extendBy.end || 0;
1971
+ if (!isItemSizeConstant) {
1972
+ extendByStart += this.RENDER_COUNT_SAFETY_MARGIN_START;
1973
+ extendByEnd += this.RENDER_COUNT_SAFETY_MARGIN_END;
1974
+ }
1975
+ if (extendByStart) {
1976
+ startIndex = Math.max(0, startIndex - extendByStart);
1977
+ renderCount += extendByStart;
1978
+ }
1979
+ if (extendByEnd) {
1980
+ renderCount += extendByEnd;
1981
+ }
1937
1982
  let endIndex = startIndex + renderCount;
1938
1983
  const theEnd = Math.max(
1939
1984
  fixedStartIndex,
@@ -1977,7 +2022,6 @@ var MatrixBrain = class extends Logger {
1977
2022
  return searchResult;
1978
2023
  }
1979
2024
  return ~searchResult - 1;
1980
- return 0;
1981
2025
  };
1982
2026
  this.computeCacheFor = (itemIndex, direction) => {
1983
2027
  const itemSizeValueOrFn = direction === "horizontal" ? this.colWidth : this.rowHeight;
@@ -2142,6 +2186,15 @@ var MatrixBrain = class extends Logger {
2142
2186
  }
2143
2187
  return cachedSize;
2144
2188
  };
2189
+ this.keepColumnRendered = (colIndex) => {
2190
+ this.alwaysRenderedColumns.add(colIndex);
2191
+ return () => {
2192
+ this.alwaysRenderedColumns.delete(colIndex);
2193
+ };
2194
+ };
2195
+ this.getAlwaysRenderedColumns = () => {
2196
+ return Array.from(this.alwaysRenderedColumns);
2197
+ };
2145
2198
  this.setRenderRange = ({
2146
2199
  horizontal,
2147
2200
  vertical,
@@ -2411,28 +2464,30 @@ var MatrixBrain = class extends Logger {
2411
2464
  * @param options.right - if true, extends the right side with the amount of current visible columns, otherwise with the specified number
2412
2465
  */
2413
2466
  extendRenderRange(options) {
2414
- const leftAmount = typeof options.left === "number" ? options.left : options.left === true ? this.getInitialCols() : 0;
2415
- const rightAmount = typeof options.right === "number" ? options.right : options.right === true ? this.getInitialCols() : 0;
2416
- const currentRenderCount = this.horizontalRenderCount;
2467
+ const { direction } = options;
2468
+ const horizontal = direction === "horizontal";
2469
+ const extendValueWhenTrue = horizontal ? this.horizontalRenderCount || this.getInitialCols() : this.verticalRenderCount || this.getInitialRows();
2470
+ const startAmount = typeof options.start === "number" ? options.start : options.start === true ? extendValueWhenTrue : 0;
2471
+ const endAmount = typeof options.end === "number" ? options.end : options.end === true ? extendValueWhenTrue : 0;
2472
+ if (horizontal) {
2473
+ this.horizontalExtendRangeBy = {
2474
+ start: startAmount,
2475
+ end: endAmount
2476
+ };
2477
+ } else {
2478
+ this.verticalExtendRangeBy = {
2479
+ start: startAmount,
2480
+ end: endAmount
2481
+ };
2482
+ }
2483
+ this.updateRenderRange({ horizontal, vertical: !horizontal });
2417
2484
  const restore = () => {
2418
- this.setRenderCount({
2419
- horizontal: currentRenderCount,
2420
- vertical: void 0
2485
+ this.extendRenderRange({
2486
+ start: 0,
2487
+ end: 0,
2488
+ direction
2421
2489
  });
2422
2490
  };
2423
- const { start, end } = this.getRenderRange();
2424
- const [startRow, startCol] = start;
2425
- const [endRow, endCol] = end;
2426
- this.setRenderRange({
2427
- horizontal: {
2428
- startIndex: Math.max(0, startCol - leftAmount),
2429
- endIndex: Math.min(this.cols, endCol + rightAmount)
2430
- },
2431
- vertical: {
2432
- startIndex: startRow,
2433
- endIndex: endRow
2434
- }
2435
- });
2436
2491
  return restore;
2437
2492
  }
2438
2493
  updateRenderCount(which = ALL_DIRECTIONS) {
@@ -2477,14 +2532,15 @@ var MatrixBrain = class extends Logger {
2477
2532
  this.notifyScrollChange();
2478
2533
  }
2479
2534
  }
2480
- notifyRenderRangeChange() {
2535
+ notifyRenderRangeChange(immediate = false) {
2481
2536
  if (this.destroyed) {
2482
2537
  return;
2483
2538
  }
2484
2539
  const fns = this.onRenderRangeChangeFns;
2485
2540
  const range = this.getRenderRange();
2541
+ const callback = immediate ? immediateCallback : raf2;
2486
2542
  fns.forEach((fn) => {
2487
- raf2(() => {
2543
+ callback(() => {
2488
2544
  if (this.destroyed) {
2489
2545
  return;
2490
2546
  }
@@ -2504,6 +2560,25 @@ var MatrixBrain = class extends Logger {
2504
2560
  fns[i](scrollPosition);
2505
2561
  }
2506
2562
  }
2563
+ computeDirectionalRenderCount(direction, itemSize, count, theRenderSize) {
2564
+ let renderCount = 0;
2565
+ let size = direction === "horizontal" ? theRenderSize.width : theRenderSize.height;
2566
+ size -= this.getFixedSize(direction);
2567
+ if (size <= 0) {
2568
+ return 0;
2569
+ }
2570
+ if (typeof itemSize === "function") {
2571
+ const sizes = [];
2572
+ for (let i = 0; i < count; i++) {
2573
+ sizes.push(this.getItemSize(i, direction));
2574
+ }
2575
+ renderCount = getGreatestCountVisibleInSize(size, sizes);
2576
+ } else {
2577
+ renderCount = (itemSize ? Math.ceil(size / itemSize) : 0) + 1;
2578
+ }
2579
+ renderCount = Math.min(count, renderCount);
2580
+ return renderCount;
2581
+ }
2507
2582
  getFixedSize(direction) {
2508
2583
  return direction === "horizontal" ? this.getFixedStartColsWidth() + this.getFixedEndColsWidth() : this.getFixedStartRowsHeight() + this.getFixedEndRowsHeight();
2509
2584
  }
@@ -2617,6 +2692,9 @@ var MatrixBrain = class extends Logger {
2617
2692
  this.reset();
2618
2693
  this.rowspanParent.clear();
2619
2694
  this.colspanParent.clear();
2695
+ this.alwaysRenderedColumns.clear();
2696
+ this.horizontalExtendRangeBy = DEFAULT_EXTEND_BY;
2697
+ this.verticalExtendRangeBy = DEFAULT_EXTEND_BY;
2620
2698
  this.destroyed = true;
2621
2699
  this.onDestroyFns = [];
2622
2700
  this.onScrollFns = [];
@@ -2650,6 +2728,9 @@ var MappedCells = class extends Logger {
2650
2728
  }
2651
2729
  return elementsOutsideItemRange.pop();
2652
2730
  };
2731
+ this.getElementFromListForRow = (elementsOutsideItemRange, _rowIndex) => {
2732
+ return elementsOutsideItemRange.pop();
2733
+ };
2653
2734
  /**
2654
2735
  * Retrieves the elements that contain rendered cells that are outside
2655
2736
  * of the specified range
@@ -2947,7 +3028,8 @@ var ReactHeadlessTableRenderer = class extends Logger {
2947
3028
  this.detailRowUpdaters = [];
2948
3029
  this.items = [];
2949
3030
  this.detailItems = [];
2950
- this.currentHoveredRow = -1;
3031
+ this.lastEnteredRow = -1;
3032
+ this.lastExitedRow = -1;
2951
3033
  this.hoverRowUpdatesInProgress = /* @__PURE__ */ new Map();
2952
3034
  this.infiniteNode = null;
2953
3035
  this.setDetailTransform = (element, _rowIndex, {
@@ -2969,14 +3051,14 @@ var ReactHeadlessTableRenderer = class extends Logger {
2969
3051
  scrollLeft: scrollLeft2,
2970
3052
  scrollTop: scrollTop2
2971
3053
  }, zIndex2) => {
2972
- const columnOffsetX = `${columnOffsetAtIndex2}-${colIndex}`;
3054
+ const columnOffsetX = InternalVarUtils.columnOffsets.get(colIndex);
2973
3055
  const columnOffsetXWhileReordering = `${columnOffsetAtIndexWhileReordering2}-${colIndex}`;
2974
3056
  const currentTransformYValue = scrollTop2 ? `calc( ${y}px + var(${scrollTopCSSVar}) )` : `${y}px`;
2975
3057
  if (element.__currentTransformY !== currentTransformYValue) {
2976
3058
  element.__currentTransformY = currentTransformYValue;
2977
3059
  element.style.setProperty(currentTransformY, currentTransformYValue);
2978
3060
  }
2979
- const transformValue = `translate3d(var(${columnOffsetXWhileReordering}, var(${columnOffsetX})), var(${currentTransformY}), 0)`;
3061
+ const transformValue = `translate3d(var(${columnOffsetXWhileReordering}, ${columnOffsetX}), var(${currentTransformY}), 0)`;
2980
3062
  if (element.__transformValue !== transformValue) {
2981
3063
  element.__transformValue = transformValue;
2982
3064
  element.style.transform = transformValue;
@@ -3376,11 +3458,14 @@ var ReactHeadlessTableRenderer = class extends Logger {
3376
3458
  return covered ? [rowspanParent, colspanParent] : false;
3377
3459
  };
3378
3460
  this.onMouseEnter = (rowIndex) => {
3379
- this.currentHoveredRow = rowIndex;
3461
+ this.lastEnteredRow = rowIndex;
3462
+ this.lastExitedRow = -1;
3380
3463
  if (this.scrolling) {
3381
3464
  return;
3382
3465
  }
3383
- this.addHoverClass(rowIndex);
3466
+ if (rowIndex != -1) {
3467
+ this.addHoverClass(rowIndex);
3468
+ }
3384
3469
  };
3385
3470
  this.addHoverClass = (rowIndex) => {
3386
3471
  this.mappedCells.getElementsForRowIndex(rowIndex).forEach((elIndex) => {
@@ -3393,14 +3478,14 @@ var ReactHeadlessTableRenderer = class extends Logger {
3393
3478
  });
3394
3479
  };
3395
3480
  this.onMouseLeave = (rowIndex) => {
3396
- if (this.currentHoveredRow != -1 && this.currentHoveredRow === rowIndex) {
3397
- this.removeHoverClass(rowIndex);
3398
- }
3399
- this.currentHoveredRow = -1;
3481
+ this.lastExitedRow = rowIndex;
3482
+ this.lastEnteredRow = -1;
3400
3483
  if (this.scrolling) {
3401
3484
  return;
3402
3485
  }
3403
- this.removeHoverClass(rowIndex);
3486
+ if (rowIndex != -1) {
3487
+ this.removeHoverClass(rowIndex);
3488
+ }
3404
3489
  };
3405
3490
  this.removeHoverClass = (rowIndex) => {
3406
3491
  this.mappedCells.getElementsForRowIndex(rowIndex).forEach((elIndex) => {
@@ -3424,8 +3509,8 @@ var ReactHeadlessTableRenderer = class extends Logger {
3424
3509
  }
3425
3510
  this.hoverRowUpdatesInProgress.set(rowIndex, true);
3426
3511
  const checkHoverClass = () => {
3427
- if (this.currentHoveredRow != -1 && !this.scrolling) {
3428
- if (this.currentHoveredRow === rowIndex) {
3512
+ if (!this.scrolling && this.lastEnteredRow != -1) {
3513
+ if (this.lastEnteredRow === rowIndex) {
3429
3514
  this.addHoverClass(rowIndex);
3430
3515
  } else {
3431
3516
  this.removeHoverClass(rowIndex);
@@ -3518,11 +3603,17 @@ var ReactHeadlessTableRenderer = class extends Logger {
3518
3603
  };
3519
3604
  this.onScrollStart = () => {
3520
3605
  this.scrolling = true;
3606
+ if (this.lastEnteredRow != -1) {
3607
+ this.removeHoverClass(this.lastEnteredRow);
3608
+ }
3521
3609
  };
3522
3610
  this.onScrollStop = () => {
3523
3611
  this.scrolling = false;
3524
- if (this.currentHoveredRow != -1) {
3525
- this.addHoverClass(this.currentHoveredRow);
3612
+ if (this.lastEnteredRow != -1) {
3613
+ this.addHoverClass(this.lastEnteredRow);
3614
+ }
3615
+ if (this.lastExitedRow != -1) {
3616
+ this.removeHoverClass(this.lastExitedRow);
3526
3617
  }
3527
3618
  };
3528
3619
  this.adjustFixedElementsOnScroll = (scrollPosition = this.brain.getScrollPosition()) => {
@@ -3789,12 +3880,27 @@ var ReactHeadlessTableRenderer = class extends Logger {
3789
3880
  return [];
3790
3881
  }
3791
3882
  const { start, end } = range;
3883
+ const horizontalLayout = this.brain.isHorizontalLayoutBrain;
3792
3884
  if (false) {
3793
3885
  this.debug(`Render range ${start}-${end}. Force ${force}`);
3794
3886
  }
3795
3887
  const { mappedCells, mappedDetailRows } = this;
3796
3888
  const fixedRanges = this.getFixedRanges(range);
3797
3889
  const ranges = [range, ...fixedRanges];
3890
+ const alwaysRenderedColumns = this.brain.getAlwaysRenderedColumns();
3891
+ if (alwaysRenderedColumns.length > 0) {
3892
+ const startCol = range.start[1];
3893
+ const endCol = range.end[1];
3894
+ alwaysRenderedColumns.forEach((colIndex) => {
3895
+ const colInRange = startCol <= colIndex && colIndex < endCol;
3896
+ if (!colInRange) {
3897
+ ranges.push({
3898
+ start: [range.start[0], colIndex],
3899
+ end: [range.end[0], colIndex + 1]
3900
+ });
3901
+ }
3902
+ });
3903
+ }
3798
3904
  const extraCellsMap = /* @__PURE__ */ new Map();
3799
3905
  const extraCells = ranges.map(this.getExtraSpanCellsForRange).flat();
3800
3906
  if (extraCells) {
@@ -3914,9 +4020,15 @@ var ReactHeadlessTableRenderer = class extends Logger {
3914
4020
  if (cellRendered && !force && cellMappedCorrectly) {
3915
4021
  continue;
3916
4022
  }
3917
- const elementIndex = cellRendered ? mappedCells.getElementIndexForCell(row, col) : mappedCells.getElementFromListForColumn(
3918
- elementsOutsideItemRange,
3919
- col
4023
+ const elementIndex = cellRendered ? mappedCells.getElementIndexForCell(row, col) : (
4024
+ // TODO when horizontal layout, just do elementsOutsideItemRange.pop()
4025
+ horizontalLayout ? mappedCells.getElementFromListForRow(
4026
+ elementsOutsideItemRange,
4027
+ row
4028
+ ) : mappedCells.getElementFromListForColumn(
4029
+ elementsOutsideItemRange,
4030
+ col
4031
+ )
3920
4032
  );
3921
4033
  if (elementIndex == null) {
3922
4034
  if (false) {
@@ -4159,17 +4271,18 @@ var HorizontalLayoutTableRenderer = class extends ReactHeadlessTableRenderer {
4159
4271
  );
4160
4272
  const pageWidth = ThemeVars.runtime.totalVisibleColumnsWidthVar;
4161
4273
  const pageOffset = pageIndex ? `calc(${pageWidth} * ${pageIndex})` : "0px";
4162
- const columnOffsetX = `${columnOffsetAtIndex2}-${horizontalLayoutCoords.colIndex}`;
4274
+ const columnOffsetX = InternalVarUtils.columnOffsets.get(
4275
+ horizontalLayoutCoords.colIndex
4276
+ );
4163
4277
  const columnOffsetXWhileReordering = `${columnOffsetAtIndexWhileReordering2}-${horizontalLayoutCoords.colIndex}`;
4164
4278
  const currentTransformYValue = `${y}px`;
4165
4279
  if (element.__currentTransformY !== currentTransformYValue) {
4166
4280
  element.__currentTransformY = currentTransformYValue;
4167
4281
  element.style.setProperty(currentTransformY, currentTransformYValue);
4168
4282
  }
4169
- const xOffset = `calc(var(${columnOffsetX}) + ${pageOffset})`;
4170
- const transformX2 = `var(${columnOffsetXWhileReordering}, ${xOffset})`;
4283
+ const xOffset = `calc(var(${columnOffsetXWhileReordering}, ${columnOffsetX}) + ${pageOffset})`;
4171
4284
  const transformY = `var(${currentTransformY})`;
4172
- const transformValue = `translate3d(${transformX2}, ${transformY}, 0px)`;
4285
+ const transformValue = `translate3d(${xOffset}, ${transformY}, 0px)`;
4173
4286
  if (element.__transformValue !== transformValue) {
4174
4287
  element.__transformValue = transformValue;
4175
4288
  element.style.transform = transformValue;
@@ -4232,7 +4345,7 @@ function createRenderer(brain) {
4232
4345
 
4233
4346
  // src/components/HeadlessTable/RawTable.tsx
4234
4347
  function RawTableFn(props) {
4235
- const { brain, renderCell, renderDetailRow } = props;
4348
+ const { brain, renderCell, renderDetailRow, forceRerenderTimestamp } = props;
4236
4349
  const { renderer, onRenderUpdater } = useMemo2(() => {
4237
4350
  return props.onRenderUpdater && props.renderer ? {
4238
4351
  renderer: props.renderer,
@@ -4250,7 +4363,14 @@ function RawTableFn(props) {
4250
4363
  renderCell,
4251
4364
  renderDetailRow
4252
4365
  });
4253
- }, [renderer, brain, renderCell, renderDetailRow, onRenderUpdater]);
4366
+ }, [
4367
+ renderer,
4368
+ brain,
4369
+ renderCell,
4370
+ renderDetailRow,
4371
+ onRenderUpdater,
4372
+ forceRerenderTimestamp
4373
+ ]);
4254
4374
  useEffect4(() => {
4255
4375
  const remove = brain.onRenderRangeChange((renderRange) => {
4256
4376
  renderer.renderRange(renderRange, {
@@ -4589,6 +4709,7 @@ function HeadlessTable(props) {
4589
4709
  activeCellIndex,
4590
4710
  onRenderUpdater,
4591
4711
  wrapRowsHorizontally,
4712
+ forceRerenderTimestamp,
4592
4713
  ...domProps
4593
4714
  } = props;
4594
4715
  const { autoFocus } = domProps;
@@ -4656,6 +4777,7 @@ function HeadlessTable(props) {
4656
4777
  /* @__PURE__ */ React13.createElement(
4657
4778
  RawTable,
4658
4779
  {
4780
+ forceRerenderTimestamp,
4659
4781
  renderer,
4660
4782
  onRenderUpdater,
4661
4783
  renderCell,
@@ -5278,22 +5400,22 @@ import { useEffect as useEffect10, useLayoutEffect as useLayoutEffect8, useState
5278
5400
 
5279
5401
  // src/components/InfiniteTable/components/InfiniteTableHeader/header.css.ts
5280
5402
  var CellCls = "cell_CellCls__1eexc2a5 utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_center__16lm1iw1q utilities_position_absolute__16lm1iw2 utilities_willChange_transform__16lm1iw22 utilities_whiteSpace_nowrap__16lm1iw23 utilities_userSelect_none__16lm1iw17";
5281
- var HeaderCellContentRecipe = createRuntimeFn({ defaultClassName: "header_HeaderCellContentRecipe__12zfob124 utilities_height_100%__16lm1iw19 utilities_width_100%__16lm1iw1b utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_center__16lm1iw1q utilities_justifyContent_start__16lm1iw1v", variantClassNames: { filtered: { false: "header_HeaderCellContentRecipe_filtered_false__12zfob125", true: "header_HeaderCellContentRecipe_filtered_true__12zfob126" }, verticalAlign: { start: "header_HeaderCellContentRecipe_verticalAlign_start__12zfob127", end: "header_HeaderCellContentRecipe_verticalAlign_end__12zfob128", center: "header_HeaderCellContentRecipe_verticalAlign_center__12zfob129" }, align: { start: "header_HeaderCellContentRecipe_align_start__12zfob12a", end: "header_HeaderCellContentRecipe_align_end__12zfob12b", center: "header_HeaderCellContentRecipe_align_center__12zfob12c" } }, defaultVariants: {}, compoundVariants: [] });
5403
+ var HeaderCellContentRecipe = createRuntimeFn({ defaultClassName: "header_HeaderCellContentRecipe__12zfob126 utilities_height_100%__16lm1iw19 utilities_width_100%__16lm1iw1b utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_center__16lm1iw1q utilities_justifyContent_start__16lm1iw1v", variantClassNames: { filtered: { false: "header_HeaderCellContentRecipe_filtered_false__12zfob127", true: "header_HeaderCellContentRecipe_filtered_true__12zfob128" }, verticalAlign: { start: "header_HeaderCellContentRecipe_verticalAlign_start__12zfob129", end: "header_HeaderCellContentRecipe_verticalAlign_end__12zfob12a", center: "header_HeaderCellContentRecipe_verticalAlign_center__12zfob12b" }, align: { start: "header_HeaderCellContentRecipe_align_start__12zfob12c", end: "header_HeaderCellContentRecipe_align_end__12zfob12d", center: "header_HeaderCellContentRecipe_align_center__12zfob12e" } }, defaultVariants: {}, compoundVariants: [] });
5282
5404
  var HeaderCellProxy = "header_HeaderCellProxy__12zfob1n utilities_whiteSpace_nowrap__16lm1iw23 utilities_textOverflow_ellipsis__16lm1iw24 utilities_overflow_hidden__16lm1iw1x";
5283
- var HeaderCellRecipe = createRuntimeFn({ defaultClassName: "header_HeaderCellRecipe__12zfob1o utilities_display_block__16lm1iw12", variantClassNames: { rowActive: { false: "header_HeaderCellRecipe_rowActive_false__12zfob1p", true: "header_HeaderCellRecipe_rowActive_true__12zfob1q" }, cellSelected: { false: "header_HeaderCellRecipe_cellSelected_false__12zfob1r", true: "header_HeaderCellRecipe_cellSelected_true__12zfob1s" }, rowSelected: { false: "header_HeaderCellRecipe_rowSelected_false__12zfob1t", true: "header_HeaderCellRecipe_rowSelected_true__12zfob1u", null: "header_HeaderCellRecipe_rowSelected_null__12zfob1v" }, rowDisabled: { false: "header_HeaderCellRecipe_rowDisabled_false__12zfob1w", true: "header_HeaderCellRecipe_rowDisabled_true__12zfob1x" }, firstRow: { false: "header_HeaderCellRecipe_firstRow_false__12zfob1y", true: "header_HeaderCellRecipe_firstRow_true__12zfob1z" }, firstRowInHorizontalLayoutPage: { false: "header_HeaderCellRecipe_firstRowInHorizontalLayoutPage_false__12zfob110", true: "header_HeaderCellRecipe_firstRowInHorizontalLayoutPage_true__12zfob111" }, groupRow: { false: "header_HeaderCellRecipe_groupRow_false__12zfob112", true: "header_HeaderCellRecipe_groupRow_true__12zfob113" }, groupCell: { false: "header_HeaderCellRecipe_groupCell_false__12zfob114", true: "header_HeaderCellRecipe_groupCell_true__12zfob115" }, align: { start: "header_HeaderCellRecipe_align_start__12zfob116", end: "header_HeaderCellRecipe_align_end__12zfob117", center: "header_HeaderCellRecipe_align_center__12zfob118" }, verticalAlign: { start: "header_HeaderCellRecipe_verticalAlign_start__12zfob119", end: "header_HeaderCellRecipe_verticalAlign_end__12zfob11a", center: "header_HeaderCellRecipe_verticalAlign_center__12zfob11b" }, zebra: { false: "header_HeaderCellRecipe_zebra_false__12zfob11c", even: "header_HeaderCellRecipe_zebra_even__12zfob11d", odd: "header_HeaderCellRecipe_zebra_odd__12zfob11e" }, dragging: { true: "header_HeaderCellRecipe_dragging_true__12zfob11f", false: "header_HeaderCellRecipe_dragging_false__12zfob11g" }, first: { true: "header_HeaderCellRecipe_first_true__12zfob11h", false: "header_HeaderCellRecipe_first_false__12zfob11i" }, last: { true: "header_HeaderCellRecipe_last_true__12zfob11j", false: "header_HeaderCellRecipe_last_false__12zfob11k" }, groupByField: { true: "header_HeaderCellRecipe_groupByField_true__12zfob11l", false: "header_HeaderCellRecipe_groupByField_false__12zfob11m" }, firstInCategory: { true: "header_HeaderCellRecipe_firstInCategory_true__12zfob11n", false: "header_HeaderCellRecipe_firstInCategory_false__12zfob11o" }, lastInCategory: { true: "header_HeaderCellRecipe_lastInCategory_true__12zfob11p", false: "header_HeaderCellRecipe_lastInCategory_false__12zfob11q" }, pinned: { start: "header_HeaderCellRecipe_pinned_start__12zfob11r", end: "header_HeaderCellRecipe_pinned_end__12zfob11s", false: "header_HeaderCellRecipe_pinned_false__12zfob11t" }, filtered: { true: "header_HeaderCellRecipe_filtered_true__12zfob11u", false: "header_HeaderCellRecipe_filtered_false__12zfob11v" } }, defaultVariants: {}, compoundVariants: [[{ pinned: "start", lastInCategory: true }, "header_HeaderCellRecipe_compound_0__12zfob11w"], [{ pinned: "end", firstInCategory: true }, "header_HeaderCellRecipe_compound_1__12zfob11x"], [{ pinned: false, lastInCategory: true }, "header_HeaderCellRecipe_compound_2__12zfob11y"]] });
5405
+ var HeaderCellRecipe = createRuntimeFn({ defaultClassName: "header_HeaderCellRecipe__12zfob1o utilities_display_block__16lm1iw12", variantClassNames: { rowActive: { false: "header_HeaderCellRecipe_rowActive_false__12zfob1p", true: "header_HeaderCellRecipe_rowActive_true__12zfob1q" }, cellSelected: { false: "header_HeaderCellRecipe_cellSelected_false__12zfob1r", true: "header_HeaderCellRecipe_cellSelected_true__12zfob1s" }, rowSelected: { false: "header_HeaderCellRecipe_rowSelected_false__12zfob1t", true: "header_HeaderCellRecipe_rowSelected_true__12zfob1u", null: "header_HeaderCellRecipe_rowSelected_null__12zfob1v" }, rowDisabled: { false: "header_HeaderCellRecipe_rowDisabled_false__12zfob1w", true: "header_HeaderCellRecipe_rowDisabled_true__12zfob1x" }, firstRow: { false: "header_HeaderCellRecipe_firstRow_false__12zfob1y", true: "header_HeaderCellRecipe_firstRow_true__12zfob1z" }, firstRowInHorizontalLayoutPage: { false: "header_HeaderCellRecipe_firstRowInHorizontalLayoutPage_false__12zfob110", true: "header_HeaderCellRecipe_firstRowInHorizontalLayoutPage_true__12zfob111" }, groupRow: { false: "header_HeaderCellRecipe_groupRow_false__12zfob112", true: "header_HeaderCellRecipe_groupRow_true__12zfob113" }, groupCell: { false: "header_HeaderCellRecipe_groupCell_false__12zfob114", true: "header_HeaderCellRecipe_groupCell_true__12zfob115" }, align: { start: "header_HeaderCellRecipe_align_start__12zfob116", end: "header_HeaderCellRecipe_align_end__12zfob117", center: "header_HeaderCellRecipe_align_center__12zfob118" }, verticalAlign: { start: "header_HeaderCellRecipe_verticalAlign_start__12zfob119", end: "header_HeaderCellRecipe_verticalAlign_end__12zfob11a", center: "header_HeaderCellRecipe_verticalAlign_center__12zfob11b" }, zebra: { false: "header_HeaderCellRecipe_zebra_false__12zfob11c", even: "header_HeaderCellRecipe_zebra_even__12zfob11d", odd: "header_HeaderCellRecipe_zebra_odd__12zfob11e" }, dragging: { true: "header_HeaderCellRecipe_dragging_true__12zfob11f", false: "header_HeaderCellRecipe_dragging_false__12zfob11g" }, insideDisabledDraggingPage: { true: "header_HeaderCellRecipe_insideDisabledDraggingPage_true__12zfob11h", false: "header_HeaderCellRecipe_insideDisabledDraggingPage_false__12zfob11i" }, first: { true: "header_HeaderCellRecipe_first_true__12zfob11j", false: "header_HeaderCellRecipe_first_false__12zfob11k" }, last: { true: "header_HeaderCellRecipe_last_true__12zfob11l", false: "header_HeaderCellRecipe_last_false__12zfob11m" }, groupByField: { true: "header_HeaderCellRecipe_groupByField_true__12zfob11n", false: "header_HeaderCellRecipe_groupByField_false__12zfob11o" }, firstInCategory: { true: "header_HeaderCellRecipe_firstInCategory_true__12zfob11p", false: "header_HeaderCellRecipe_firstInCategory_false__12zfob11q" }, lastInCategory: { true: "header_HeaderCellRecipe_lastInCategory_true__12zfob11r", false: "header_HeaderCellRecipe_lastInCategory_false__12zfob11s" }, pinned: { start: "header_HeaderCellRecipe_pinned_start__12zfob11t", end: "header_HeaderCellRecipe_pinned_end__12zfob11u", false: "header_HeaderCellRecipe_pinned_false__12zfob11v" }, filtered: { true: "header_HeaderCellRecipe_filtered_true__12zfob11w", false: "header_HeaderCellRecipe_filtered_false__12zfob11x" } }, defaultVariants: {}, compoundVariants: [[{ pinned: "start", lastInCategory: true }, "header_HeaderCellRecipe_compound_0__12zfob11y"], [{ pinned: "end", firstInCategory: true }, "header_HeaderCellRecipe_compound_1__12zfob11z"], [{ pinned: false, lastInCategory: true }, "header_HeaderCellRecipe_compound_2__12zfob120"]] });
5284
5406
  var HeaderClsRecipe = createRuntimeFn({ defaultClassName: "header_HeaderClsRecipe__12zfob19 utilities_display_block__16lm1iw12 utilities_position_absolute__16lm1iw2", variantClassNames: { pinned: { start: "header_HeaderClsRecipe_pinned_start__12zfob1a", end: "header_HeaderClsRecipe_pinned_end__12zfob1b", false: "header_HeaderClsRecipe_pinned_false__12zfob1c" }, firstInCategory: { true: "header_HeaderClsRecipe_firstInCategory_true__12zfob1d", false: "header_HeaderClsRecipe_firstInCategory_false__12zfob1e" }, lastInCategory: { true: "header_HeaderClsRecipe_lastInCategory_true__12zfob1f", false: "header_HeaderClsRecipe_lastInCategory_false__12zfob1g" }, overflow: { true: "header_HeaderClsRecipe_overflow_true__12zfob1h", false: "header_HeaderClsRecipe_overflow_false__12zfob1i" } }, defaultVariants: {}, compoundVariants: [[{ overflow: true, pinned: "start" }, "header_HeaderClsRecipe_compound_0__12zfob1j"], [{ pinned: "start", firstInCategory: true }, "header_HeaderClsRecipe_compound_1__12zfob1k"], [{ overflow: true, pinned: "end" }, "header_HeaderClsRecipe_compound_2__12zfob1l"], [{ pinned: "end", lastInCategory: true }, "header_HeaderClsRecipe_compound_3__12zfob1m"]] });
5285
- var HeaderFilterEditorCls = "header_HeaderFilterEditorCls__12zfob12m utilities_width_100%__16lm1iw1b utilities_height_100%__16lm1iw19";
5407
+ var HeaderFilterEditorCls = "header_HeaderFilterEditorCls__12zfob12o utilities_width_100%__16lm1iw1b utilities_height_100%__16lm1iw19";
5286
5408
  var HeaderFilterIconIndexCls = "header_HeaderFilterIconIndexCls__12zfob17";
5287
- var HeaderFilterOperatorCls = "header_HeaderFilterOperatorCls__12zfob12i utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_center__16lm1iw1q utilities_position_relative__16lm1iw1";
5288
- var HeaderFilterOperatorIconRecipe = createRuntimeFn({ defaultClassName: "header_HeaderFilterOperatorIconRecipe__12zfob12j utilities_position_relative__16lm1iw1 utilities_top_0__16lm1iw1c", variantClassNames: { disabled: { true: "header_HeaderFilterOperatorIconRecipe_disabled_true__12zfob12k", false: "header_HeaderFilterOperatorIconRecipe_disabled_false__12zfob12l" } }, defaultVariants: {}, compoundVariants: [] });
5289
- var HeaderFilterRecipe = createRuntimeFn({ defaultClassName: "header_HeaderFilterRecipe__12zfob12f utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_stretch__16lm1iw1r utilities_position_relative__16lm1iw1", variantClassNames: { active: { true: "header_HeaderFilterRecipe_active_true__12zfob12g", false: "header_HeaderFilterRecipe_active_false__12zfob12h" } }, defaultVariants: {}, compoundVariants: [] });
5290
- var HeaderGroupCls = "header_HeaderGroupCls__12zfob12e utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_center__16lm1iw1q";
5291
- var HeaderMenuIconCls = createRuntimeFn({ defaultClassName: "header_HeaderMenuIconCls__12zfob11z utilities_position_relative__16lm1iw1 utilities_display_flex__16lm1iwz utilities_flexFlow_column__16lm1iw1m utilities_justifyContent_spaceAround__16lm1iw1u utilities_visibility_hidden__16lm1iw21", variantClassNames: { menuVisible: { true: "header_HeaderMenuIconCls_menuVisible_true__12zfob120" }, reserveSpaceWhenHidden: { true: "header_HeaderMenuIconCls_reserveSpaceWhenHidden_true__12zfob121", false: "header_HeaderMenuIconCls_reserveSpaceWhenHidden_false__12zfob122" } }, defaultVariants: {}, compoundVariants: [[{ menuVisible: true, reserveSpaceWhenHidden: false }, "header_HeaderMenuIconCls_compound_0__12zfob123"]] });
5409
+ var HeaderFilterOperatorCls = "header_HeaderFilterOperatorCls__12zfob12k utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_center__16lm1iw1q utilities_position_relative__16lm1iw1";
5410
+ var HeaderFilterOperatorIconRecipe = createRuntimeFn({ defaultClassName: "header_HeaderFilterOperatorIconRecipe__12zfob12l utilities_position_relative__16lm1iw1 utilities_top_0__16lm1iw1c", variantClassNames: { disabled: { true: "header_HeaderFilterOperatorIconRecipe_disabled_true__12zfob12m", false: "header_HeaderFilterOperatorIconRecipe_disabled_false__12zfob12n" } }, defaultVariants: {}, compoundVariants: [] });
5411
+ var HeaderFilterRecipe = createRuntimeFn({ defaultClassName: "header_HeaderFilterRecipe__12zfob12h utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_stretch__16lm1iw1r utilities_position_relative__16lm1iw1", variantClassNames: { active: { true: "header_HeaderFilterRecipe_active_true__12zfob12i", false: "header_HeaderFilterRecipe_active_false__12zfob12j" } }, defaultVariants: {}, compoundVariants: [] });
5412
+ var HeaderGroupCls = "header_HeaderGroupCls__12zfob12g utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_center__16lm1iw1q";
5413
+ var HeaderMenuIconCls = createRuntimeFn({ defaultClassName: "header_HeaderMenuIconCls__12zfob121 utilities_position_relative__16lm1iw1 utilities_display_flex__16lm1iwz utilities_flexFlow_column__16lm1iw1m utilities_justifyContent_spaceAround__16lm1iw1u utilities_visibility_hidden__16lm1iw21", variantClassNames: { menuVisible: { true: "header_HeaderMenuIconCls_menuVisible_true__12zfob122" }, reserveSpaceWhenHidden: { true: "header_HeaderMenuIconCls_reserveSpaceWhenHidden_true__12zfob123", false: "header_HeaderMenuIconCls_reserveSpaceWhenHidden_false__12zfob124" } }, defaultVariants: {}, compoundVariants: [[{ menuVisible: true, reserveSpaceWhenHidden: false }, "header_HeaderMenuIconCls_compound_0__12zfob125"]] });
5292
5414
  var HeaderScrollbarPlaceholderCls = "header_HeaderScrollbarPlaceholderCls__12zfob18 utilities_position_absolute__16lm1iw2";
5293
5415
  var HeaderSortIconCls = "utilities_position_relative__16lm1iw1";
5294
5416
  var HeaderSortIconIndexCls = "header_HeaderSortIconIndexCls__12zfob16";
5295
5417
  var HeaderSortIconRecipe = createRuntimeFn({ defaultClassName: "header__12zfob12", variantClassNames: { align: { start: "header_HeaderSortIconRecipe_align_start__12zfob13", center: "header_HeaderSortIconRecipe_align_center__12zfob14", end: "header_HeaderSortIconRecipe_align_end__12zfob15" } }, defaultVariants: {}, compoundVariants: [] });
5296
- var HeaderWrapperCls = "header_HeaderWrapperCls__12zfob12d utilities_overflow_hidden__16lm1iw1x utilities_position_relative__16lm1iw1 utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o";
5418
+ var HeaderWrapperCls = "header_HeaderWrapperCls__12zfob12f utilities_overflow_hidden__16lm1iw1x utilities_position_relative__16lm1iw1 utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o";
5297
5419
 
5298
5420
  // src/components/InfiniteTable/components/icons/InfiniteTableIconClassName.ts
5299
5421
  var InfiniteTableIconClassName = "InfiniteTableIcon";
@@ -6735,6 +6857,7 @@ function useCellClassName(column, baseClasses, variants, extraFlags) {
6735
6857
  rowSelected: extraFlags.rowSelected ?? "null",
6736
6858
  rowActive: extraFlags.rowActive,
6737
6859
  dragging: extraFlags.dragging,
6860
+ insideDisabledDraggingPage: extraFlags.insideDisabledDraggingPage,
6738
6861
  firstRow: extraFlags.firstRow ?? false,
6739
6862
  firstRowInHorizontalLayoutPage: extraFlags.firstRowInHorizontalLayoutPage ?? false,
6740
6863
  rowDisabled: extraFlags.rowDisabled,
@@ -6802,11 +6925,11 @@ import { useCallback as useCallback8, useState as useState7 } from "react";
6802
6925
  // src/components/InfiniteTable/InfiniteCls.css.ts
6803
6926
  var FooterCls = "utilities_position_relative__16lm1iw1";
6804
6927
  var InfiniteCls = "InfiniteCls_InfiniteCls__1yeub2v0 utilities_position_relative__16lm1iw1 utilities_display_flex__16lm1iwz utilities_flexFlow_column__16lm1iw1m utilities_boxSizingBorderBox__16lm1iw0";
6805
- var InfiniteClsHasPinnedEnd = "InfiniteCls_InfiniteClsHasPinnedEnd__1yeub2vq";
6806
- var InfiniteClsHasPinnedStart = "InfiniteCls_InfiniteClsHasPinnedStart__1yeub2vp";
6807
- var InfiniteClsRecipe = createRuntimeFn({ defaultClassName: "InfiniteCls__1yeub2v2", variantClassNames: { focused: { true: "InfiniteCls_InfiniteClsRecipe_focused_true__1yeub2v3", false: "InfiniteCls_InfiniteClsRecipe_focused_false__1yeub2v4" }, focusedWithin: { true: "InfiniteCls_InfiniteClsRecipe_focusedWithin_true__1yeub2v5", false: "InfiniteCls_InfiniteClsRecipe_focusedWithin_false__1yeub2v6" }, hasPinnedStart: { true: "InfiniteCls_InfiniteClsRecipe_hasPinnedStart_true__1yeub2v7", false: "InfiniteCls_InfiniteClsRecipe_hasPinnedStart_false__1yeub2v8" }, hasPinnedEnd: { true: "InfiniteCls_InfiniteClsRecipe_hasPinnedEnd_true__1yeub2v9", false: "InfiniteCls_InfiniteClsRecipe_hasPinnedEnd_false__1yeub2va" }, hasPinnedStartOverflow: { true: "InfiniteCls_InfiniteClsRecipe_hasPinnedStartOverflow_true__1yeub2vb", false: "InfiniteCls_InfiniteClsRecipe_hasPinnedStartOverflow_false__1yeub2vc" }, hasPinnedEndOverflow: { true: "InfiniteCls_InfiniteClsRecipe_hasPinnedEndOverflow_true__1yeub2vd", false: "InfiniteCls_InfiniteClsRecipe_hasPinnedEndOverflow_false__1yeub2ve" } }, defaultVariants: {}, compoundVariants: [[{ focused: false, focusedWithin: false }, "InfiniteCls_InfiniteClsRecipe_compound_0__1yeub2vf"]] });
6808
- var InfiniteClsShiftingColumns = "InfiniteCls_shiftingcols__1yeub2vn";
6809
- var PinnedRowsContainerClsVariants = createRuntimeFn({ defaultClassName: "InfiniteCls__1yeub2vj", variantClassNames: { pinned: { start: "InfiniteCls_PinnedRowsContainerClsVariants_pinned_start__1yeub2vk", end: "InfiniteCls_PinnedRowsContainerClsVariants_pinned_end__1yeub2vl", false: "InfiniteCls_PinnedRowsContainerClsVariants_pinned_false__1yeub2vm" } }, defaultVariants: {}, compoundVariants: [] });
6928
+ var InfiniteClsHasPinnedEnd = "InfiniteCls_InfiniteClsHasPinnedEnd__1yeub2vs";
6929
+ var InfiniteClsHasPinnedStart = "InfiniteCls_InfiniteClsHasPinnedStart__1yeub2vr";
6930
+ var InfiniteClsRecipe = createRuntimeFn({ defaultClassName: "InfiniteCls__1yeub2v2", variantClassNames: { horizontalLayout: { true: "InfiniteCls_InfiniteClsRecipe_horizontalLayout_true__1yeub2v3", false: "InfiniteCls_InfiniteClsRecipe_horizontalLayout_false__1yeub2v4" }, focused: { true: "InfiniteCls_InfiniteClsRecipe_focused_true__1yeub2v5", false: "InfiniteCls_InfiniteClsRecipe_focused_false__1yeub2v6" }, focusedWithin: { true: "InfiniteCls_InfiniteClsRecipe_focusedWithin_true__1yeub2v7", false: "InfiniteCls_InfiniteClsRecipe_focusedWithin_false__1yeub2v8" }, hasPinnedStart: { true: "InfiniteCls_InfiniteClsRecipe_hasPinnedStart_true__1yeub2v9", false: "InfiniteCls_InfiniteClsRecipe_hasPinnedStart_false__1yeub2va" }, hasPinnedEnd: { true: "InfiniteCls_InfiniteClsRecipe_hasPinnedEnd_true__1yeub2vb", false: "InfiniteCls_InfiniteClsRecipe_hasPinnedEnd_false__1yeub2vc" }, hasPinnedStartOverflow: { true: "InfiniteCls_InfiniteClsRecipe_hasPinnedStartOverflow_true__1yeub2vd", false: "InfiniteCls_InfiniteClsRecipe_hasPinnedStartOverflow_false__1yeub2ve" }, hasPinnedEndOverflow: { true: "InfiniteCls_InfiniteClsRecipe_hasPinnedEndOverflow_true__1yeub2vf", false: "InfiniteCls_InfiniteClsRecipe_hasPinnedEndOverflow_false__1yeub2vg" } }, defaultVariants: {}, compoundVariants: [[{ focused: false, focusedWithin: false }, "InfiniteCls_InfiniteClsRecipe_compound_0__1yeub2vh"]] });
6931
+ var InfiniteClsShiftingColumns = "InfiniteCls_shiftingcols__1yeub2vp";
6932
+ var PinnedRowsContainerClsVariants = createRuntimeFn({ defaultClassName: "InfiniteCls__1yeub2vl", variantClassNames: { pinned: { start: "InfiniteCls_PinnedRowsContainerClsVariants_pinned_start__1yeub2vm", end: "InfiniteCls_PinnedRowsContainerClsVariants_pinned_end__1yeub2vn", false: "InfiniteCls_PinnedRowsContainerClsVariants_pinned_false__1yeub2vo" } }, defaultVariants: {}, compoundVariants: [] });
6810
6933
 
6811
6934
  // src/components/InfiniteTable/utils/rafFn.ts
6812
6935
  var rafFn = (fn) => {
@@ -6847,7 +6970,6 @@ var scrollbarWidthHorizontal = stripVar(
6847
6970
  );
6848
6971
  var scrollbarWidthVertical = stripVar(InternalVars.scrollbarWidthVertical);
6849
6972
  var columnWidthAtIndex2 = stripVar(InternalVars.columnWidthAtIndex);
6850
- var columnOffsetAtIndex3 = stripVar(InternalVars.columnOffsetAtIndex);
6851
6973
  var columnZIndexAtIndex3 = stripVar(InternalVars.columnZIndexAtIndex);
6852
6974
  var scrollLeftCSSVar = stripVar(InternalVars.scrollLeft);
6853
6975
  var activeCellColWidth = stripVar(InternalVars.activeCellColWidth);
@@ -6889,7 +7011,8 @@ function useDOMProps(initialDOMProps) {
6889
7011
  onSelfFocus,
6890
7012
  onSelfBlur,
6891
7013
  bodySize,
6892
- activeCellIndex
7014
+ activeCellIndex,
7015
+ wrapRowsHorizontally
6893
7016
  } = state;
6894
7017
  const {
6895
7018
  computedPinnedStartColumnsWidth,
@@ -6904,11 +7027,11 @@ function useDOMProps(initialDOMProps) {
6904
7027
  const cssVars = computedVisibleColumns.reduce(
6905
7028
  (vars, col) => {
6906
7029
  const index = col.computedVisibleIndex;
6907
- vars[`${columnWidthAtIndex2}-${index}`] = col.computedWidth + "px";
6908
- vars[`${columnOffsetAtIndex3}-${index}`] = col.computedPinned === "start" ? `calc( ${col.computedOffset}px + var(${scrollLeftCSSVar}) )` : col.computedPinned === "end" ? (
7030
+ vars[InternalVarUtils.columnWidths.varName.get(index)] = col.computedWidth + "px";
7031
+ vars[InternalVarUtils.columnOffsets.varName.get(index)] = col.computedPinned === "start" ? `calc( ${col.computedOffset}px + var(${scrollLeftCSSVar}) )` : col.computedPinned === "end" ? (
6909
7032
  // see #startcoloffsets-pinnedend
6910
7033
  `calc( var(${pinnedEndOffsetCSSVar}) ${prevPinnedEndCols.length ? "+" : ""} ${prevPinnedEndCols.map(
6911
- (c) => `var(${columnWidthAtIndex2}-${c.computedVisibleIndex})`
7034
+ (c) => InternalVarUtils.columnWidths.get(c.computedVisibleIndex)
6912
7035
  ).join(" + ")} + var(${scrollLeftCSSVar}) )`
6913
7036
  ) : `${col.computedOffset}px`;
6914
7037
  const zIndexValue = getColumnZIndex(col, {
@@ -6933,12 +7056,12 @@ function useDOMProps(initialDOMProps) {
6933
7056
  }).join(" + ")})`;
6934
7057
  cssVars[publicRuntimeVars.visibleColumnsCount.name] = computedVisibleColumns.length;
6935
7058
  if (activeCellIndex != null) {
6936
- cssVars[activeCellColWidth] = `var(${getCSSVarNameForColWidth(
7059
+ cssVars[activeCellColWidth] = InternalVarUtils.columnWidths.get(
6937
7060
  activeCellIndex[1]
6938
- )})`;
6939
- const defaultActiveCellColOffset = `var(${getCSSVarNameForColOffset(
7061
+ );
7062
+ const defaultActiveCellColOffset = InternalVarUtils.columnOffsets.get(
6940
7063
  activeCellIndex[1]
6941
- )})`;
7064
+ );
6942
7065
  if (state.brain.isHorizontalLayoutBrain) {
6943
7066
  const pageIndex = state.brain.getPageIndexForRow(activeCellIndex[0]);
6944
7067
  cssVars[activeCellColOffset] = pageIndex ? `calc( ${ThemeVars.runtime.totalVisibleColumnsWidthVar} * ${pageIndex} + ${defaultActiveCellColOffset})` : defaultActiveCellColOffset;
@@ -6949,8 +7072,8 @@ function useDOMProps(initialDOMProps) {
6949
7072
  cssVars[computedVisibleColumnsCountCSSVar] = computedVisibleColumns.length;
6950
7073
  cssVars[scrollbarWidthHorizontal] = scrollbars.horizontal ? `${scrollbarWidth2}px` : "0px";
6951
7074
  cssVars[scrollbarWidthVertical] = scrollbars.vertical ? `${scrollbarWidth2}px` : "0px";
6952
- cssVars[pinnedStartWidthCSSVar] = `calc( ` + computedPinnedStartColumns.map((c) => `var(${getCSSVarNameForColWidth(c.computedVisibleIndex)})`).join(" + ") + ")";
6953
- cssVars[pinnedEndWidthCSSVar] = `calc( ` + computedPinnedEndColumns.map((c) => `var(${getCSSVarNameForColWidth(c.computedVisibleIndex)})`).join(" + ") + ")";
7075
+ cssVars[pinnedStartWidthCSSVar] = `calc( ` + computedPinnedStartColumns.map((c) => InternalVarUtils.columnWidths.get(c.computedVisibleIndex)).join(" + ") + ")";
7076
+ cssVars[pinnedEndWidthCSSVar] = `calc( ` + computedPinnedEndColumns.map((c) => InternalVarUtils.columnWidths.get(c.computedVisibleIndex)).join(" + ") + ")";
6954
7077
  cssVars[baseZIndexForCells] = computedVisibleColumns.length * 10;
6955
7078
  cssVars[pinnedEndOffsetCSSVar] = `calc( var(${bodyWidthCSSVar}) - var(${pinnedEndWidthCSSVar}) - var(${scrollbarWidthVertical}) )`;
6956
7079
  cssVars[bodyWidthCSSVar] = `${bodySize.width}px`;
@@ -7008,6 +7131,7 @@ function useDOMProps(initialDOMProps) {
7008
7131
  const className = join(
7009
7132
  InfiniteTableClassName,
7010
7133
  InfiniteCls,
7134
+ wrapRowsHorizontally ? `${InfiniteTableClassName}--horizontal-layout` : null,
7011
7135
  domProps?.className,
7012
7136
  computedPinnedStartColumnsWidth ? `${InfiniteTableClassName}--has-pinned-start ${InfiniteClsHasPinnedStart}` : null,
7013
7137
  computedPinnedEndColumnsWidth ? `${InfiniteTableClassName}--has-pinned-end ${InfiniteClsHasPinnedEnd}` : null,
@@ -7018,6 +7142,7 @@ function useDOMProps(initialDOMProps) {
7018
7142
  computed.computedPinnedStartOverflow ? `${InfiniteTableClassName}--has-pinned-start-overflow` : null,
7019
7143
  computed.computedPinnedEndOverflow ? `${InfiniteTableClassName}--has-pinned-end-overflow` : null,
7020
7144
  InfiniteClsRecipe({
7145
+ horizontalLayout: !!wrapRowsHorizontally,
7021
7146
  hasPinnedStart: !!computedPinnedStartColumnsWidth,
7022
7147
  hasPinnedEnd: !!computedPinnedEndColumnsWidth,
7023
7148
  // hasPinnedStartOverflow: !!computed.computedPinnedStartOverflow,
@@ -7047,6 +7172,68 @@ function useDOMProps(initialDOMProps) {
7047
7172
  // src/components/InfiniteTable/hooks/reorderColumnsOnDrag.ts
7048
7173
  var import_binary_search2 = __toESM(require_binary_search());
7049
7174
 
7175
+ // src/components/InfiniteTable/utils/CSSCalc.ts
7176
+ function mapToContinuation(args) {
7177
+ return args.map(
7178
+ (arg) => arg instanceof CssContinuation ? arg : new CssContinuation(null, [arg])
7179
+ );
7180
+ }
7181
+ var CssContinuation = class {
7182
+ constructor(operation, operands = []) {
7183
+ this.__operands = [];
7184
+ this.__operation = null;
7185
+ this.__operands = operands;
7186
+ this.__operation = operation;
7187
+ }
7188
+ add(...args) {
7189
+ return new CssContinuation("+", [this, ...args]);
7190
+ }
7191
+ subtract(...args) {
7192
+ return new CssContinuation("-", [this, ...args]);
7193
+ }
7194
+ minus(...args) {
7195
+ return this.subtract(...args);
7196
+ }
7197
+ multiply(...args) {
7198
+ return new CssContinuation("*", [this, ...args]);
7199
+ }
7200
+ divide(...args) {
7201
+ return new CssContinuation("/", [this, ...args]);
7202
+ }
7203
+ __get(parent) {
7204
+ const { __operation, __operands } = this;
7205
+ const result = __operands.map((operand) => operandToString(operand, this)).join(` ${__operation} `);
7206
+ const skipParens = __operands.length <= 1 ? true : parent?.__operation === "+" || parent?.__operation === "-";
7207
+ return skipParens ? result : `(${result})`;
7208
+ }
7209
+ done() {
7210
+ const str = this.__get();
7211
+ const hasParens = str.startsWith("(") && str.endsWith(")");
7212
+ const value = hasParens ? str : `(${str})`;
7213
+ return `calc${value}`;
7214
+ }
7215
+ };
7216
+ function operandToString(operand, parent) {
7217
+ if (typeof operand === "string" || typeof operand === "number") {
7218
+ return `${operand}`;
7219
+ }
7220
+ if (!parent) {
7221
+ return operand.done();
7222
+ }
7223
+ return operand.__get(parent);
7224
+ }
7225
+ var add = (...args) => new CssContinuation("+", mapToContinuation(args));
7226
+ var subtract = (...args) => new CssContinuation("-", mapToContinuation(args));
7227
+ var multiply = (...args) => new CssContinuation("*", mapToContinuation(args));
7228
+ var divide = (...args) => new CssContinuation("/", mapToContinuation(args));
7229
+ var CSSCalc = {
7230
+ add,
7231
+ subtract,
7232
+ minus: subtract,
7233
+ multiply,
7234
+ divide
7235
+ };
7236
+
7050
7237
  // src/components/InfiniteTable/utils/moveXatY.ts
7051
7238
  var moveXatY = (arr, dragIndex, dropIndex) => {
7052
7239
  arr = [...arr];
@@ -7147,8 +7334,6 @@ var PROXY_OFFSET = 10;
7147
7334
  var pinnedStartWidthCSSVar2 = stripVar(InternalVars.pinnedStartWidth);
7148
7335
  function reorderColumnsOnDrag(params) {
7149
7336
  const {
7150
- columnOffsetAtIndexCSSVar,
7151
- columnWidthAtIndexCSSVar,
7152
7337
  computedVisibleColumns,
7153
7338
  computedVisibleColumnsMap,
7154
7339
  computedPinnedEndColumns,
@@ -7160,7 +7345,9 @@ function reorderColumnsOnDrag(params) {
7160
7345
  draggableColumnsRestrictTo,
7161
7346
  tableRect,
7162
7347
  setProxyPosition,
7163
- api: imperativeApi
7348
+ api: imperativeApi,
7349
+ horizontalLayoutPageIndex,
7350
+ pageWidth
7164
7351
  } = params;
7165
7352
  function getCurrentPinnedWidth(pinned) {
7166
7353
  let currentWidth = pinned === "start" ? pinnedStartInitialWidth : pinnedEndInitialWidth;
@@ -7176,27 +7363,32 @@ function reorderColumnsOnDrag(params) {
7176
7363
  return currentWidth;
7177
7364
  }
7178
7365
  function isColumnVisible2(b) {
7179
- if (b.index === dragColumnIndex) {
7366
+ if (b.columnIndex === dragColumnIndex) {
7367
+ return true;
7368
+ }
7369
+ if (horizontalLayoutPageIndex != null) {
7180
7370
  return true;
7181
7371
  }
7182
- const col = computedVisibleColumns[b.index];
7372
+ const col = computedVisibleColumns[b.columnIndex];
7183
7373
  if (col.computedPinned) {
7184
7374
  return true;
7185
7375
  }
7186
7376
  const scrollLeft2 = brain.getScrollPosition().scrollLeft;
7187
- return col.computedOffset >= scrollLeft2 + getCurrentPinnedWidth("start") && col.computedOffset + col.computedWidth < scrollLeft2 + tableRect.width - getCurrentPinnedWidth("end");
7377
+ const colOffset = col.computedOffset + (horizontalLayoutPageIndex != null && pageWidth != null ? pageWidth * horizontalLayoutPageIndex : 0);
7378
+ const visible = colOffset >= scrollLeft2 + getCurrentPinnedWidth("start") && colOffset + col.computedWidth <= scrollLeft2 + tableRect.width - getCurrentPinnedWidth("end");
7379
+ return visible;
7188
7380
  }
7189
7381
  const getBreakPoints = (columns, options) => {
7190
7382
  const { restrictToParentGroup, dragColumn: dragColumn2 } = options;
7191
7383
  let breakpoints = [];
7192
7384
  columns.forEach((c) => {
7385
+ if (c.computedVisibleIndex === dragColumnIndex) {
7386
+ return;
7387
+ }
7193
7388
  const b = {
7194
7389
  columnId: c.id,
7195
- index: c.computedVisibleIndex,
7196
- breakpoint: (
7197
- // tableRect.left +
7198
- c.computedOffset + Math.round(c.computedWidth / 2)
7199
- )
7390
+ columnIndex: c.computedVisibleIndex,
7391
+ offsetX: c.computedOffset + Math.round(c.computedWidth / 2)
7200
7392
  };
7201
7393
  if (isColumnVisible2(b)) {
7202
7394
  breakpoints.push(b);
@@ -7308,7 +7500,7 @@ function reorderColumnsOnDrag(params) {
7308
7500
  }
7309
7501
  }
7310
7502
  function updateDropIndex(newDropIndex) {
7311
- if (newDropIndex === currentDropIndex) {
7503
+ if (newDropIndex == null || newDropIndex === currentDropIndex) {
7312
7504
  return;
7313
7505
  }
7314
7506
  currentDropIndex = newDropIndex;
@@ -7350,23 +7542,32 @@ function reorderColumnsOnDrag(params) {
7350
7542
  newPosition = isDragColumn ? (
7351
7543
  // this is the column we're dragging to the left
7352
7544
  // so we place it exactly at the offset of the currentDropIndex
7353
- `var(${columnOffsetAtIndexCSSVar}-${currentDropIndex})`
7545
+ InternalVarUtils.columnOffsets.get(currentDropIndex)
7354
7546
  ) : isOutsideCol ? (
7355
7547
  // this col should have the initial pos, so we're good
7356
- `var(${columnOffsetAtIndexCSSVar}-${colIndex})`
7548
+ InternalVarUtils.columnOffsets.get(colIndex)
7357
7549
  ) : (
7358
7550
  // place it at the default offset + the width of the drag column
7359
7551
  // as these are columns situated between the dragindex and the dropindex
7360
- `calc( var(${columnOffsetAtIndexCSSVar}-${colIndex}) + var(${columnWidthAtIndexCSSVar}-${dragColumnIndex}) )`
7552
+ CSSCalc.add(
7553
+ InternalVarUtils.columnOffsets.get(colIndex),
7554
+ InternalVarUtils.columnWidths.get(dragColumnIndex)
7555
+ ).done()
7361
7556
  );
7362
7557
  } else {
7363
7558
  newPosition = isOutsideCol ? (
7364
7559
  // this is the default value for a column
7365
- `var(${columnOffsetAtIndexCSSVar}-${colIndex})`
7560
+ InternalVarUtils.columnOffsets.get(colIndex)
7366
7561
  ) : isDragColumn ? (
7367
7562
  // this is the column we're dragging to the right
7368
- `calc( var(${columnOffsetAtIndexCSSVar}-${currentDropIndex - 1}) + var(${columnWidthAtIndexCSSVar}-${currentDropIndex - 1}) - var(${columnWidthAtIndexCSSVar}-${dragColumnIndex}) )`
7369
- ) : `calc( var(${columnOffsetAtIndexCSSVar}-${colIndex}) - var(${columnWidthAtIndexCSSVar}-${dragColumnIndex}) )`;
7563
+ CSSCalc.add(
7564
+ InternalVarUtils.columnOffsets.get(currentDropIndex - 1),
7565
+ InternalVarUtils.columnWidths.get(currentDropIndex - 1)
7566
+ ).minus(InternalVarUtils.columnWidths.get(dragColumnIndex)).done()
7567
+ ) : CSSCalc.minus(
7568
+ InternalVarUtils.columnOffsets.get(colIndex),
7569
+ InternalVarUtils.columnWidths.get(dragColumnIndex)
7570
+ ).done();
7370
7571
  }
7371
7572
  setInfiniteColumnOffsetWhileReordering(
7372
7573
  colIndex,
@@ -7406,20 +7607,25 @@ function reorderColumnsOnDrag(params) {
7406
7607
  let idx = (0, import_binary_search2.default)(
7407
7608
  breakpoints,
7408
7609
  currentPos,
7409
- ({ breakpoint }, value) => {
7410
- return breakpoint < value ? -1 : breakpoint > value ? 1 : 0;
7610
+ ({ offsetX }, value) => {
7611
+ return offsetX < value ? -1 : offsetX > value ? 1 : 0;
7411
7612
  }
7412
7613
  );
7413
7614
  if (idx < 0) {
7414
7615
  idx = ~idx;
7415
7616
  }
7416
- idx = breakpoints[idx] ? breakpoints[idx].index : breakpoints[breakpoints.length - 1].index + 1;
7417
- if (idx != null && idx !== currentDropIndex) {
7418
- if (dir === 1 && currentDropIndex === dragColumnIndex + 1) {
7419
- idx = dragColumnIndex;
7617
+ if (!breakpoints.length) {
7618
+ if (computedVisibleColumns.length > 1) {
7619
+ console.error("No breakpoints available, something is wrong!");
7420
7620
  }
7421
- updateDropIndex(idx);
7621
+ idx = 0;
7622
+ } else {
7623
+ idx = breakpoints[idx] ? breakpoints[idx].columnIndex : breakpoints[breakpoints.length - 1].columnIndex + 1;
7624
+ }
7625
+ if (idx === dragColumnIndex + 1) {
7626
+ idx = dragColumnIndex;
7422
7627
  }
7628
+ updateDropIndex(idx);
7423
7629
  const columnPinning = {};
7424
7630
  computedPinnedEndColumns.forEach((col) => {
7425
7631
  columnPinning[col.id] = "end";
@@ -7516,8 +7722,6 @@ function adjustColumnOrderForAllColumns(options) {
7516
7722
  }
7517
7723
 
7518
7724
  // src/components/InfiniteTable/hooks/useColumnPointerEvents.ts
7519
- var columnOffsetAtIndex4 = stripVar(InternalVars.columnOffsetAtIndex);
7520
- var columnWidthAtIndex3 = stripVar(InternalVars.columnWidthAtIndex);
7521
7725
  var baseZIndexForCells2 = stripVar(InternalVars.baseZIndexForCells);
7522
7726
  var equalPinning = (pinning1, pinning2) => {
7523
7727
  const empty1 = !pinning1 || Object.keys(pinning1).length === 0;
@@ -7532,7 +7736,8 @@ var equalPinning = (pinning1, pinning2) => {
7532
7736
  };
7533
7737
  var useColumnPointerEvents = ({
7534
7738
  columnId,
7535
- domRef
7739
+ domRef,
7740
+ horizontalLayoutPageIndex
7536
7741
  }) => {
7537
7742
  const [proxyPosition, setProxyPosition] = useState7(null);
7538
7743
  const {
@@ -7576,13 +7781,20 @@ var useColumnPointerEvents = ({
7576
7781
  const tableRect = rootRef.current.getBoundingClientRect();
7577
7782
  const initialAvailableSize = brain.getAvailableSize();
7578
7783
  const dragColumnIndex = dragColumn.computedVisibleIndex;
7784
+ const dragColumnIndexInHorizontalLayout = brain.getVirtualColIndex(
7785
+ dragColumn.computedVisibleIndex,
7786
+ {
7787
+ pageIndex: horizontalLayoutPageIndex || 0
7788
+ }
7789
+ );
7790
+ const pageWidth = brain.isHorizontalLayoutBrain ? brain.getPageWidth() : null;
7579
7791
  let initialCursor = target.style.cursor ?? "auto";
7580
7792
  let didDragAtLeastOnce = false;
7581
7793
  const dragger = reorderColumnsOnDrag({
7582
7794
  brain,
7795
+ horizontalLayoutPageIndex,
7796
+ pageWidth,
7583
7797
  draggableColumnsRestrictTo,
7584
- columnOffsetAtIndexCSSVar: columnOffsetAtIndex4,
7585
- columnWidthAtIndexCSSVar: columnWidthAtIndex3,
7586
7798
  computedPinnedEndColumns,
7587
7799
  computedPinnedStartColumns,
7588
7800
  computedUnpinnedColumns,
@@ -7600,6 +7812,8 @@ var useColumnPointerEvents = ({
7600
7812
  }
7601
7813
  });
7602
7814
  let reorderDragResult = null;
7815
+ let discardAlwaysRenderedColumn;
7816
+ let restoreRenderRange;
7603
7817
  function persistColumnOrder(reorderDragResult2) {
7604
7818
  const { columnPinning, columnOrder } = reorderDragResult2;
7605
7819
  if (!equalPinning(getState().columnPinning, columnPinning)) {
@@ -7628,15 +7842,37 @@ var useColumnPointerEvents = ({
7628
7842
  const { headerBrain, brain: brain2 } = getState();
7629
7843
  if (!didDragAtLeastOnce) {
7630
7844
  didDragAtLeastOnce = true;
7631
- brain2.setRenderCount({
7632
- horizontal: computedVisibleColumns.length,
7633
- vertical: void 0
7634
- });
7635
- headerBrain.setRenderCount({
7636
- horizontal: computedVisibleColumns.length,
7637
- vertical: void 0
7638
- });
7845
+ const discardForBody = brain2.keepColumnRendered(
7846
+ dragColumnIndexInHorizontalLayout
7847
+ );
7848
+ const discardForHeader = headerBrain.keepColumnRendered(
7849
+ dragColumnIndexInHorizontalLayout
7850
+ );
7851
+ if (brain2.isHorizontalLayoutBrain) {
7852
+ const extendBy = true;
7853
+ const restoreBodyRange = brain2.extendRenderRange({
7854
+ start: extendBy,
7855
+ end: extendBy,
7856
+ direction: "horizontal"
7857
+ });
7858
+ const restoreHeaderRange = headerBrain.extendRenderRange({
7859
+ start: extendBy,
7860
+ end: extendBy,
7861
+ direction: "horizontal"
7862
+ });
7863
+ restoreRenderRange = () => {
7864
+ restoreBodyRange();
7865
+ restoreHeaderRange();
7866
+ };
7867
+ }
7868
+ discardAlwaysRenderedColumn = () => {
7869
+ discardForBody();
7870
+ discardForHeader();
7871
+ };
7639
7872
  actions.columnReorderDragColumnId = dragColumn.id;
7873
+ if (horizontalLayoutPageIndex != null) {
7874
+ actions.columnReorderInPageIndex = horizontalLayoutPageIndex;
7875
+ }
7640
7876
  setInfiniteColumnZIndex(
7641
7877
  dragColumnIndex,
7642
7878
  `calc( var(${baseZIndexForCells2}) + 10000 )`,
@@ -7655,6 +7891,8 @@ var useColumnPointerEvents = ({
7655
7891
  brain.update({
7656
7892
  ...initialAvailableSize
7657
7893
  });
7894
+ discardAlwaysRenderedColumn?.();
7895
+ restoreRenderRange?.();
7658
7896
  computedVisibleColumns.forEach((col) => {
7659
7897
  clearInfiniteColumnReorderDuration(
7660
7898
  col.computedVisibleIndex,
@@ -7689,12 +7927,15 @@ var useColumnPointerEvents = ({
7689
7927
  persistColumnOrder(reorderDragResult);
7690
7928
  }
7691
7929
  actions.columnReorderDragColumnId = false;
7930
+ if (horizontalLayoutPageIndex != null) {
7931
+ actions.columnReorderInPageIndex = null;
7932
+ }
7692
7933
  };
7693
7934
  target.addEventListener("pointermove", onPointerMove);
7694
7935
  target.addEventListener("pointerup", onPointerUp);
7695
7936
  target.setPointerCapture(e.pointerId);
7696
7937
  },
7697
- [columnId]
7938
+ [columnId, horizontalLayoutPageIndex]
7698
7939
  );
7699
7940
  return {
7700
7941
  onPointerDown: computed.computedVisibleColumnsMap.get(columnId)?.computedDraggable ? onPointerDown : defaultPointerDown,
@@ -8004,7 +8245,7 @@ function objectValuesExcept(obj, exceptList) {
8004
8245
 
8005
8246
  // src/components/InfiniteTable/components/cell.css.ts
8006
8247
  var ColumnCellCls = "cell_ColumnCellCls__1eexc2a6 cell_CellCls__1eexc2a5 utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_center__16lm1iw1q utilities_position_absolute__16lm1iw2 utilities_willChange_transform__16lm1iw22 utilities_whiteSpace_nowrap__16lm1iw23 utilities_userSelect_none__16lm1iw17";
8007
- var ColumnCellRecipe = createRuntimeFn({ defaultClassName: "cell_ColumnCellRecipe__1eexc2am", variantClassNames: { dragging: { false: "cell_ColumnCellRecipe_dragging_false__1eexc2an", true: "cell_ColumnCellRecipe_dragging_true__1eexc2ao" }, cellSelected: { false: "cell_ColumnCellRecipe_cellSelected_false__1eexc2ap", true: "cell_ColumnCellRecipe_cellSelected_true__1eexc2aq" }, align: { start: "cell_ColumnCellRecipe_align_start__1eexc2ar", end: "cell_ColumnCellRecipe_align_end__1eexc2as", center: "cell_ColumnCellRecipe_align_center__1eexc2at" }, verticalAlign: { start: "cell_ColumnCellRecipe_verticalAlign_start__1eexc2au", end: "cell_ColumnCellRecipe_verticalAlign_end__1eexc2av", center: "cell_ColumnCellRecipe_verticalAlign_center__1eexc2aw" }, rowActive: { false: "cell_ColumnCellRecipe_rowActive_false__1eexc2ax", true: "cell_ColumnCellRecipe_rowActive_true__1eexc2ay" }, groupRow: { false: "cell_ColumnCellRecipe_groupRow_false__1eexc2az", true: "cell_ColumnCellRecipe_groupRow_true__1eexc2a10" }, groupCell: { false: "cell_ColumnCellRecipe_groupCell_false__1eexc2a11", true: "cell_ColumnCellRecipe_groupCell_true__1eexc2a12" }, rowDisabled: { false: "cell_ColumnCellRecipe_rowDisabled_false__1eexc2a13", true: "cell_ColumnCellRecipe_rowDisabled_true__1eexc2a14" }, zebra: { false: "cell_ColumnCellRecipe_zebra_false__1eexc2a15", even: "cell_ColumnCellRecipe_zebra_even__1eexc2a16", odd: "cell_ColumnCellRecipe_zebra_odd__1eexc2a17" }, rowSelected: { true: "cell_ColumnCellRecipe_rowSelected_true__1eexc2a18", false: "cell_ColumnCellRecipe_rowSelected_false__1eexc2a19", null: "cell_ColumnCellRecipe_rowSelected_null__1eexc2a1a" }, first: { true: "cell_ColumnCellRecipe_first_true__1eexc2a1b", false: "cell_ColumnCellRecipe_first_false__1eexc2a1c" }, last: { true: "cell_ColumnCellRecipe_last_true__1eexc2a1d", false: "cell_ColumnCellRecipe_last_false__1eexc2a1e" }, groupByField: { true: "cell_ColumnCellRecipe_groupByField_true__1eexc2a1f", false: "cell_ColumnCellRecipe_groupByField_false__1eexc2a1g" }, firstInCategory: { true: "cell_ColumnCellRecipe_firstInCategory_true__1eexc2a1h", false: "cell_ColumnCellRecipe_firstInCategory_false__1eexc2a1i" }, firstRow: { true: "cell_ColumnCellRecipe_firstRow_true__1eexc2a1j", false: "cell_ColumnCellRecipe_firstRow_false__1eexc2a1k" }, firstRowInHorizontalLayoutPage: { true: "cell_ColumnCellRecipe_firstRowInHorizontalLayoutPage_true__1eexc2a1l", false: "cell_ColumnCellRecipe_firstRowInHorizontalLayoutPage_false__1eexc2a1m" }, lastInCategory: { true: "cell_ColumnCellRecipe_lastInCategory_true__1eexc2a1n", false: "cell_ColumnCellRecipe_lastInCategory_false__1eexc2a1o" }, pinned: { start: "cell_ColumnCellRecipe_pinned_start__1eexc2a1p", end: "cell_ColumnCellRecipe_pinned_end__1eexc2a1q", false: "cell_ColumnCellRecipe_pinned_false__1eexc2a1r" }, filtered: { true: "cell_ColumnCellRecipe_filtered_true__1eexc2a1s", false: "cell_ColumnCellRecipe_filtered_false__1eexc2a1t" } }, defaultVariants: {}, compoundVariants: [[{ firstRowInHorizontalLayoutPage: true, firstRow: false }, "cell_ColumnCellRecipe_compound_0__1eexc2a1u"], [{ pinned: "start", lastInCategory: true }, "cell_ColumnCellRecipe_compound_1__1eexc2a1v"], [{ pinned: "start", firstInCategory: true }, "cell_ColumnCellRecipe_compound_2__1eexc2a1w"], [{ pinned: "end", firstInCategory: true }, "cell_ColumnCellRecipe_compound_3__1eexc2a1x"], [{ pinned: "end", lastInCategory: true }, "cell_ColumnCellRecipe_compound_4__1eexc2a1y"], [{ align: "center", groupCell: false }, "cell_ColumnCellRecipe_compound_5__1eexc2a1z"], [{ rowDisabled: true, zebra: "odd" }, "cell_ColumnCellRecipe_compound_6__1eexc2a20"]] });
8248
+ var ColumnCellRecipe = createRuntimeFn({ defaultClassName: "cell_ColumnCellRecipe__1eexc2am", variantClassNames: { dragging: { false: "cell_ColumnCellRecipe_dragging_false__1eexc2an", true: "cell_ColumnCellRecipe_dragging_true__1eexc2ao" }, insideDisabledDraggingPage: { true: "cell_ColumnCellRecipe_insideDisabledDraggingPage_true__1eexc2ap", false: "cell_ColumnCellRecipe_insideDisabledDraggingPage_false__1eexc2aq" }, cellSelected: { false: "cell_ColumnCellRecipe_cellSelected_false__1eexc2ar", true: "cell_ColumnCellRecipe_cellSelected_true__1eexc2as" }, align: { start: "cell_ColumnCellRecipe_align_start__1eexc2at", end: "cell_ColumnCellRecipe_align_end__1eexc2au", center: "cell_ColumnCellRecipe_align_center__1eexc2av" }, verticalAlign: { start: "cell_ColumnCellRecipe_verticalAlign_start__1eexc2aw", end: "cell_ColumnCellRecipe_verticalAlign_end__1eexc2ax", center: "cell_ColumnCellRecipe_verticalAlign_center__1eexc2ay" }, rowActive: { false: "cell_ColumnCellRecipe_rowActive_false__1eexc2az", true: "cell_ColumnCellRecipe_rowActive_true__1eexc2a10" }, groupRow: { false: "cell_ColumnCellRecipe_groupRow_false__1eexc2a11", true: "cell_ColumnCellRecipe_groupRow_true__1eexc2a12" }, groupCell: { false: "cell_ColumnCellRecipe_groupCell_false__1eexc2a13", true: "cell_ColumnCellRecipe_groupCell_true__1eexc2a14" }, rowDisabled: { false: "cell_ColumnCellRecipe_rowDisabled_false__1eexc2a15", true: "cell_ColumnCellRecipe_rowDisabled_true__1eexc2a16" }, zebra: { false: "cell_ColumnCellRecipe_zebra_false__1eexc2a17", even: "cell_ColumnCellRecipe_zebra_even__1eexc2a18", odd: "cell_ColumnCellRecipe_zebra_odd__1eexc2a19" }, rowSelected: { true: "cell_ColumnCellRecipe_rowSelected_true__1eexc2a1a", false: "cell_ColumnCellRecipe_rowSelected_false__1eexc2a1b", null: "cell_ColumnCellRecipe_rowSelected_null__1eexc2a1c" }, first: { true: "cell_ColumnCellRecipe_first_true__1eexc2a1d", false: "cell_ColumnCellRecipe_first_false__1eexc2a1e" }, last: { true: "cell_ColumnCellRecipe_last_true__1eexc2a1f", false: "cell_ColumnCellRecipe_last_false__1eexc2a1g" }, groupByField: { true: "cell_ColumnCellRecipe_groupByField_true__1eexc2a1h", false: "cell_ColumnCellRecipe_groupByField_false__1eexc2a1i" }, firstInCategory: { true: "cell_ColumnCellRecipe_firstInCategory_true__1eexc2a1j", false: "cell_ColumnCellRecipe_firstInCategory_false__1eexc2a1k" }, firstRow: { true: "cell_ColumnCellRecipe_firstRow_true__1eexc2a1l", false: "cell_ColumnCellRecipe_firstRow_false__1eexc2a1m" }, firstRowInHorizontalLayoutPage: { true: "cell_ColumnCellRecipe_firstRowInHorizontalLayoutPage_true__1eexc2a1n", false: "cell_ColumnCellRecipe_firstRowInHorizontalLayoutPage_false__1eexc2a1o" }, lastInCategory: { true: "cell_ColumnCellRecipe_lastInCategory_true__1eexc2a1p", false: "cell_ColumnCellRecipe_lastInCategory_false__1eexc2a1q" }, pinned: { start: "cell_ColumnCellRecipe_pinned_start__1eexc2a1r", end: "cell_ColumnCellRecipe_pinned_end__1eexc2a1s", false: "cell_ColumnCellRecipe_pinned_false__1eexc2a1t" }, filtered: { true: "cell_ColumnCellRecipe_filtered_true__1eexc2a1u", false: "cell_ColumnCellRecipe_filtered_false__1eexc2a1v" } }, defaultVariants: {}, compoundVariants: [[{ firstRowInHorizontalLayoutPage: true, firstRow: false }, "cell_ColumnCellRecipe_compound_0__1eexc2a1w"], [{ pinned: "start", lastInCategory: true }, "cell_ColumnCellRecipe_compound_1__1eexc2a1x"], [{ pinned: "start", firstInCategory: true }, "cell_ColumnCellRecipe_compound_2__1eexc2a1y"], [{ pinned: "end", firstInCategory: true }, "cell_ColumnCellRecipe_compound_3__1eexc2a1z"], [{ pinned: "end", lastInCategory: true }, "cell_ColumnCellRecipe_compound_4__1eexc2a20"], [{ align: "center", groupCell: false }, "cell_ColumnCellRecipe_compound_5__1eexc2a21"], [{ rowDisabled: true, zebra: "odd" }, "cell_ColumnCellRecipe_compound_6__1eexc2a22"]] });
8008
8249
  var ColumnCellSelectionIndicatorRecipe = createRuntimeFn({ defaultClassName: "cell_ColumnCellSelectionIndicatorRecipe__1eexc2ad", variantClassNames: { right: { true: "cell_ColumnCellSelectionIndicatorRecipe_right_true__1eexc2ae", false: "cell_ColumnCellSelectionIndicatorRecipe_right_false__1eexc2af" }, left: { true: "cell_ColumnCellSelectionIndicatorRecipe_left_true__1eexc2ag", false: "cell_ColumnCellSelectionIndicatorRecipe_left_false__1eexc2ah" }, top: { true: "cell_ColumnCellSelectionIndicatorRecipe_top_true__1eexc2ai", false: "cell_ColumnCellSelectionIndicatorRecipe_top_false__1eexc2aj" }, bottom: { true: "cell_ColumnCellSelectionIndicatorRecipe_bottom_true__1eexc2ak", false: "cell_ColumnCellSelectionIndicatorRecipe_bottom_false__1eexc2al" } }, defaultVariants: {}, compoundVariants: [] });
8009
8250
  var FlashingColumnCellRecipe = createRuntimeFn({ defaultClassName: "cell_FlashingColumnCellRecipe__1eexc2a9", variantClassNames: { direction: { up: "cell_FlashingColumnCellRecipe_direction_up__1eexc2aa", down: "cell_FlashingColumnCellRecipe_direction_down__1eexc2ab", neutral: "cell_FlashingColumnCellRecipe_direction_neutral__1eexc2ac" } }, defaultVariants: {}, compoundVariants: [] });
8010
8251
  var SelectionCheckboxCls = "cell_SelectionCheckboxCls__1eexc2a7";
@@ -8397,7 +8638,7 @@ import * as React34 from "react";
8397
8638
  var { rootClassName: rootClassName5 } = internalProps;
8398
8639
  var InfiniteTableCellClassName = `${rootClassName5}Cell`;
8399
8640
  var InfiniteTableCellContentClassName = `${rootClassName5}Cell_content`;
8400
- var columnWidthAtIndex4 = stripVar(InternalVars.columnWidthAtIndex);
8641
+ var columnWidthAtIndex3 = stripVar(InternalVars.columnWidthAtIndex);
8401
8642
  var columnReorderEffectDurationAtIndex2 = stripVar(
8402
8643
  InternalVars.columnReorderEffectDurationAtIndex
8403
8644
  );
@@ -8422,7 +8663,7 @@ function InfiniteTableCellFn(props) {
8422
8663
  } = props;
8423
8664
  const children = renderChildren();
8424
8665
  const style2 = {
8425
- width: `var(${columnWidthAtIndex4}-${column.computedVisibleIndex})`,
8666
+ width: `var(${columnWidthAtIndex3}-${column.computedVisibleIndex})`,
8426
8667
  transition: `transform var(${columnReorderEffectDurationAtIndex2}-${column.computedVisibleIndex}, 0s)`,
8427
8668
  ...domProps.style
8428
8669
  };
@@ -8612,7 +8853,7 @@ function InfiniteTableColumnCellFn(props) {
8612
8853
  api: dataSourceApi,
8613
8854
  componentActions: dataSourceActions
8614
8855
  } = useDataSourceContextValue();
8615
- const { activeRowIndex, keyboardNavigation } = getState();
8856
+ const { activeRowIndex, keyboardNavigation, columnReorderInPageIndex } = getState();
8616
8857
  const rowActive = rowIndex === activeRowIndex && keyboardNavigation === "row";
8617
8858
  const renderingContext = {
8618
8859
  getState,
@@ -8936,6 +9177,7 @@ function InfiniteTableColumnCellFn(props) {
8936
9177
  right: rightSelectionBorder,
8937
9178
  bottom: bottomSelectionBorder
8938
9179
  } : null;
9180
+ const insideDisabledDraggingPage = columnReorderInPageIndex != null ? horizontalLayoutPageIndex !== columnReorderInPageIndex : false;
8939
9181
  const afterChildren = editor;
8940
9182
  const theChildren = renderChildren();
8941
9183
  const cellProps = {
@@ -8960,6 +9202,7 @@ function InfiniteTableColumnCellFn(props) {
8960
9202
  ColumnCellRecipe,
8961
9203
  {
8962
9204
  dragging: false,
9205
+ insideDisabledDraggingPage,
8963
9206
  zebra,
8964
9207
  align: align2,
8965
9208
  verticalAlign,
@@ -9223,7 +9466,7 @@ function getColumnResizer(colIndex, {
9223
9466
  const column = columns[colIndex];
9224
9467
  return {
9225
9468
  resize(diff) {
9226
- setInfiniteColumnWidth(
9469
+ InternalVarUtils.columnWidths.set(
9227
9470
  colIndex,
9228
9471
  column.computedWidth + diff,
9229
9472
  domRef.current
@@ -9234,7 +9477,7 @@ function getColumnResizer(colIndex, {
9234
9477
  if (!nextColumn) {
9235
9478
  return;
9236
9479
  }
9237
- setInfiniteColumnWidth(
9480
+ InternalVarUtils.columnWidths.set(
9238
9481
  nextColIndex,
9239
9482
  nextColumn.computedWidth - diff,
9240
9483
  domRef.current
@@ -9242,7 +9485,7 @@ function getColumnResizer(colIndex, {
9242
9485
  if (nextColumn.computedPinned === "start") {
9243
9486
  addToInfiniteColumnOffset(nextColumn, diff, domRef.current);
9244
9487
  } else {
9245
- setInfiniteColumnOffset(
9488
+ InternalVarUtils.columnOffsets.set(
9246
9489
  nextColIndex,
9247
9490
  nextColumn.computedOffset + diff,
9248
9491
  domRef.current
@@ -9263,7 +9506,11 @@ function getColumnResizer(colIndex, {
9263
9506
  if (col.computedPinned === "end") {
9264
9507
  continue;
9265
9508
  }
9266
- setInfiniteColumnOffset(i, col.computedOffset + diff, domRef.current);
9509
+ InternalVarUtils.columnOffsets.set(
9510
+ i,
9511
+ col.computedOffset + diff,
9512
+ domRef.current
9513
+ );
9267
9514
  }
9268
9515
  return;
9269
9516
  }
@@ -9272,7 +9519,11 @@ function getColumnResizer(colIndex, {
9272
9519
  if (col.computedPinned) {
9273
9520
  continue;
9274
9521
  }
9275
- setInfiniteColumnOffset(i, col.computedOffset + diff, domRef.current);
9522
+ InternalVarUtils.columnOffsets.set(
9523
+ i,
9524
+ col.computedOffset + diff,
9525
+ domRef.current
9526
+ );
9276
9527
  }
9277
9528
  }
9278
9529
  };
@@ -9300,12 +9551,12 @@ function getColumnGroupResizer(colIndexes, config) {
9300
9551
  const colIndex = colIndexes[i];
9301
9552
  const column = columns[colIndex];
9302
9553
  const newWidth = column.computedWidth + diff;
9303
- setInfiniteColumnWidth(colIndex, newWidth, node);
9554
+ InternalVarUtils.columnWidths.set(colIndex, newWidth, node);
9304
9555
  if (column.computedPinned === "end") {
9305
9556
  return;
9306
9557
  }
9307
9558
  if (offset) {
9308
- setInfiniteColumnOffset(colIndex, offset, node);
9559
+ InternalVarUtils.columnOffsets.set(colIndex, offset, node);
9309
9560
  }
9310
9561
  offset += newWidth;
9311
9562
  });
@@ -9317,7 +9568,11 @@ function getColumnGroupResizer(colIndexes, config) {
9317
9568
  if (col.computedPinned === "end") {
9318
9569
  continue;
9319
9570
  }
9320
- setInfiniteColumnOffset(i, col.computedOffset + diffSum, node);
9571
+ InternalVarUtils.columnOffsets.set(
9572
+ i,
9573
+ col.computedOffset + diffSum,
9574
+ node
9575
+ );
9321
9576
  }
9322
9577
  }
9323
9578
  };
@@ -9357,12 +9612,14 @@ function ResizeHandleFn(props) {
9357
9612
  const target = e.target;
9358
9613
  if (brain.isHorizontalLayoutBrain) {
9359
9614
  const restoreBodyRange = brain.extendRenderRange({
9360
- left: true,
9361
- right: true
9615
+ start: true,
9616
+ end: true,
9617
+ direction: "horizontal"
9362
9618
  });
9363
9619
  const restoreHeaderRange = headerBrain.extendRenderRange({
9364
- left: true,
9365
- right: true
9620
+ start: true,
9621
+ end: true,
9622
+ direction: "horizontal"
9366
9623
  });
9367
9624
  restoreRenderRange = () => {
9368
9625
  restoreBodyRange();
@@ -9572,7 +9829,8 @@ function InfiniteTableHeaderCell(props) {
9572
9829
  portalDOMRef,
9573
9830
  columnHeaderHeight,
9574
9831
  columnReorderDragColumnId,
9575
- columnMenuVisibleForColumnId
9832
+ columnMenuVisibleForColumnId,
9833
+ columnReorderInPageIndex
9576
9834
  },
9577
9835
  getDataSourceMasterContext
9578
9836
  } = useInfiniteTable();
@@ -9583,7 +9841,9 @@ function InfiniteTableHeaderCell(props) {
9583
9841
  componentState: { filterDelay, filterTypes }
9584
9842
  } = useDataSourceContextValue();
9585
9843
  const { allRowsSelected, someRowsSelected, selectionMode } = useDataSourceState();
9844
+ const horizontalLayoutPageIndex = props.horizontalLayoutPageIndex;
9586
9845
  const dragging = columnReorderDragColumnId === column.id;
9846
+ const insideDisabledDraggingPage = columnReorderInPageIndex != null ? horizontalLayoutPageIndex !== columnReorderInPageIndex : false;
9587
9847
  const { onResize, height, width, headerOptions, columnsMap } = props;
9588
9848
  const sortInfo = column.computedSortInfo;
9589
9849
  const header = column.header;
@@ -9648,7 +9908,7 @@ function InfiniteTableHeaderCell(props) {
9648
9908
  const MenuIconCmp = column.components?.MenuIcon || components2?.MenuIcon || MenuIcon;
9649
9909
  const menuIcon = /* @__PURE__ */ React42.createElement(MenuIconCmp, { ...menuIconProps });
9650
9910
  const initialRenderParam = {
9651
- horizontalLayoutPageIndex: props.horizontalLayoutPageIndex,
9911
+ horizontalLayoutPageIndex,
9652
9912
  dragging,
9653
9913
  domRef: ref,
9654
9914
  insideColumnMenu: false,
@@ -9812,7 +10072,8 @@ function InfiniteTableHeaderCell(props) {
9812
10072
  const headerClassName = typeof column.headerClassName === "function" ? column.headerClassName(renderParam) : column.headerClassName;
9813
10073
  const { onPointerDown, proxyPosition } = useColumnPointerEvents({
9814
10074
  columnId: column.id,
9815
- domRef
10075
+ domRef,
10076
+ horizontalLayoutPageIndex
9816
10077
  });
9817
10078
  let draggingProxy = null;
9818
10079
  if (dragging && proxyPosition) {
@@ -9856,7 +10117,7 @@ function InfiniteTableHeaderCell(props) {
9856
10117
  const FilterEditor = operator?.components?.FilterEditor || filterType?.components?.FilterEditor || column.components?.FilterEditor || StringFilterEditor;
9857
10118
  const FilterOperatorSwitch = filterType?.components?.FilterOperatorSwitch || column.components?.FilterOperatorSwitch;
9858
10119
  const resizeHandle = useColumnResizeHandle(column, {
9859
- horizontalLayoutPageIndex: props.horizontalLayoutPageIndex
10120
+ horizontalLayoutPageIndex
9860
10121
  });
9861
10122
  const zIndex2 = `var(${columnZIndexAtIndex5}-${column.computedVisibleIndex})`;
9862
10123
  style2.zIndex = zIndex2;
@@ -9896,6 +10157,7 @@ function InfiniteTableHeaderCell(props) {
9896
10157
  HeaderCellRecipe,
9897
10158
  {
9898
10159
  dragging,
10160
+ insideDisabledDraggingPage,
9899
10161
  align: align2,
9900
10162
  verticalAlign,
9901
10163
  rowSelected: false,
@@ -9916,7 +10178,7 @@ function InfiniteTableHeaderCell(props) {
9916
10178
  afterChildren: /* @__PURE__ */ React42.createElement(React42.Fragment, null, showColumnFilters ? column.computedFilterable ? /* @__PURE__ */ React42.createElement(
9917
10179
  InfiniteTableColumnHeaderFilter,
9918
10180
  {
9919
- horizontalLayoutPageIndex: props.horizontalLayoutPageIndex,
10181
+ horizontalLayoutPageIndex,
9920
10182
  filterEditor: FilterEditor,
9921
10183
  filterOperatorSwitch: FilterOperatorSwitch ?? InfiniteTableFilterOperatorSwitch,
9922
10184
  operator,
@@ -10234,7 +10496,7 @@ function useColumnGroupResizeHandle(groupColumns, config) {
10234
10496
 
10235
10497
  // src/components/InfiniteTable/components/InfiniteTableHeader/InfiniteTableHeaderGroup.tsx
10236
10498
  var TableHeaderGroupClassName = `${rootClassName2}HeaderGroup`;
10237
- var columnWidthAtIndex5 = stripVar(InternalVars.columnWidthAtIndex);
10499
+ var columnWidthAtIndex4 = stripVar(InternalVars.columnWidthAtIndex);
10238
10500
  var columnZIndexAtIndex6 = stripVar(InternalVars.columnZIndexAtIndex);
10239
10501
  function InfiniteTableHeaderGroup(props) {
10240
10502
  const { columnGroup, height, columns, bodyBrain, columnGroupsMaxDepth } = props;
@@ -10253,8 +10515,8 @@ function InfiniteTableHeaderGroup(props) {
10253
10515
  });
10254
10516
  const firstColumn = columns[0];
10255
10517
  const width = columns.length > 1 ? `calc( ` + columns.map(
10256
- (col) => `var(${columnWidthAtIndex5}-${col.computedVisibleIndex})`
10257
- ).join(" + ") + " )" : `var(${columnWidthAtIndex5}-${firstColumn.computedVisibleIndex})`;
10518
+ (col) => `var(${columnWidthAtIndex4}-${col.computedVisibleIndex})`
10519
+ ).join(" + ") + " )" : `var(${columnWidthAtIndex4}-${firstColumn.computedVisibleIndex})`;
10258
10520
  const zIndex2 = `calc(var(${columnZIndexAtIndex6}-${firstColumn.computedVisibleIndex}) + ${columnGroupsMaxDepth - columnGroup.depth})`;
10259
10521
  let style2 = typeof userStyle === "function" ? userStyle({
10260
10522
  columnGroup,
@@ -11186,6 +11448,14 @@ function getEnhancedGroupData(options, deepMapValue) {
11186
11448
  };
11187
11449
  return enhancedGroupData;
11188
11450
  }
11451
+ function toDuplicateRow(parent, indexInAll, currentPage) {
11452
+ return {
11453
+ ...parent,
11454
+ id: `duplicate_row_on_page_${currentPage}_for__${parent.id}`,
11455
+ indexInAll,
11456
+ duplicateOf: parent.id
11457
+ };
11458
+ }
11189
11459
  function completeReducers(reducers, reducerResults, items) {
11190
11460
  if (reducers) {
11191
11461
  for (const key in reducers)
@@ -11202,6 +11472,8 @@ function enhancedFlatten(param) {
11202
11472
  const {
11203
11473
  lazyLoad,
11204
11474
  groupResult,
11475
+ rowsPerPage,
11476
+ repeatWrappedGroupRows,
11205
11477
  withRowInfo,
11206
11478
  toPrimaryKey,
11207
11479
  groupRowsState,
@@ -11267,6 +11539,17 @@ function enhancedFlatten(param) {
11267
11539
  include = false;
11268
11540
  }
11269
11541
  if (include) {
11542
+ if (repeatWrappedGroupRows && rowsPerPage != null && rowsPerPage > 0) {
11543
+ const indexInAll = enhancedGroupData.indexInAll;
11544
+ const currentParents = enhancedGroupData.parents;
11545
+ if (currentParents.length > 0 && indexInAll % rowsPerPage === 0) {
11546
+ const currentPage = indexInAll / rowsPerPage;
11547
+ currentParents.forEach((parent2, i) => {
11548
+ result.push(toDuplicateRow(parent2, indexInAll + i, currentPage));
11549
+ });
11550
+ enhancedGroupData.indexInAll += currentParents.length;
11551
+ }
11552
+ }
11270
11553
  result.push(enhancedGroupData);
11271
11554
  groupRowsIndexes.push(result.length - 1);
11272
11555
  }
@@ -11286,13 +11569,26 @@ function enhancedFlatten(param) {
11286
11569
  if (continueWithChildren) {
11287
11570
  if (!next) {
11288
11571
  if (!pivot) {
11289
- const startIndex = result.length;
11572
+ let startIndex = result.length;
11290
11573
  if (!collapsed) {
11291
11574
  result.length += items.length;
11292
11575
  }
11576
+ let extraArtificialGroupRows = 0;
11293
11577
  for (let index = 0, len = items.length; index < len; index++) {
11294
11578
  const item = items[index];
11295
- const indexInAll = startIndex + index;
11579
+ if (!collapsed && repeatWrappedGroupRows && rowsPerPage != null && rowsPerPage > 0) {
11580
+ const currentInsertIndex = startIndex + index + extraArtificialGroupRows;
11581
+ if (currentInsertIndex % rowsPerPage === 0) {
11582
+ const currentPage = currentInsertIndex / rowsPerPage;
11583
+ result.length += parents.length;
11584
+ parents.forEach((parent2) => {
11585
+ const i = startIndex + index + extraArtificialGroupRows;
11586
+ result[i] = toDuplicateRow(parent2, i, currentPage);
11587
+ extraArtificialGroupRows++;
11588
+ });
11589
+ }
11590
+ }
11591
+ const indexInAll = startIndex + index + extraArtificialGroupRows;
11296
11592
  const itemId = item ? toPrimaryKey(item, indexInAll) : `${groupKeys}-${index}`;
11297
11593
  const rowInfo = {
11298
11594
  id: itemId,
@@ -11335,7 +11631,7 @@ function enhancedFlatten(param) {
11335
11631
  parent2.deepRowInfoArray.push(rowInfo);
11336
11632
  });
11337
11633
  if (!collapsed) {
11338
- result[startIndex + index] = rowInfo;
11634
+ result[startIndex + index + extraArtificialGroupRows] = rowInfo;
11339
11635
  }
11340
11636
  }
11341
11637
  }
@@ -14103,7 +14399,9 @@ function concludeReducer(params) {
14103
14399
  "aggregationReducers",
14104
14400
  "pivotTotalColumnPosition",
14105
14401
  "pivotGrandTotalColumnPosition",
14106
- "showSeparatePivotColumnForSingleAggregation"
14402
+ "showSeparatePivotColumnForSingleAggregation",
14403
+ "repeatWrappedGroupRows",
14404
+ "rowsPerPage"
14107
14405
  ]);
14108
14406
  const rowInfoReducersChanged = haveDepsChanged(previousState, state, [
14109
14407
  "rowInfoReducers"
@@ -14222,6 +14520,8 @@ function concludeReducer(params) {
14222
14520
  isRowSelected,
14223
14521
  rowSelectionState,
14224
14522
  withRowInfo,
14523
+ repeatWrappedGroupRows: state.repeatWrappedGroupRows && state.rowsPerPage != null,
14524
+ rowsPerPage: state.rowsPerPage,
14225
14525
  groupRowsState: state.groupRowsState,
14226
14526
  generateGroupRows: state.generateGroupRows
14227
14527
  });
@@ -15010,6 +15310,7 @@ function initSetupState() {
15010
15310
  return {
15011
15311
  // TODO cleanup indexer on unmount
15012
15312
  indexer: new Indexer(),
15313
+ repeatWrappedGroupRows: false,
15013
15314
  destroyedRef: {
15014
15315
  current: false
15015
15316
  },
@@ -15024,6 +15325,7 @@ function initSetupState() {
15024
15325
  timestamp: 0,
15025
15326
  mutations: void 0
15026
15327
  },
15328
+ rowsPerPage: null,
15027
15329
  lazyLoadCacheOfLoadedBatches: new DeepMap(),
15028
15330
  dataParams: void 0,
15029
15331
  onCleanup: buildSubscriptionCallback(),
@@ -17005,6 +17307,17 @@ var InfiniteTableApiImpl = class {
17005
17307
  setColumnVisibility(columnVisibility) {
17006
17308
  this.actions.columnVisibility = columnVisibility;
17007
17309
  }
17310
+ get scrollContainer() {
17311
+ return this.getState().scrollerDOMRef.current;
17312
+ }
17313
+ get scrollLeftMax() {
17314
+ const scrollLeftMax = this.getState().brain.scrollLeftMax;
17315
+ return scrollLeftMax;
17316
+ }
17317
+ get scrollTopMax() {
17318
+ const scrollTopMax = this.getState().brain.scrollTopMax;
17319
+ return scrollTopMax;
17320
+ }
17008
17321
  get scrollLeft() {
17009
17322
  const state = this.getState();
17010
17323
  return state.brain.getScrollPosition().scrollLeft;
@@ -18020,6 +18333,28 @@ var HorizontalLayoutMatrixBrain = class extends MatrixBrain {
18020
18333
  });
18021
18334
  }
18022
18335
  }
18336
+ computeDirectionalRenderCount(direction, itemSize, count, theRenderSize) {
18337
+ if (direction === "vertical" || typeof itemSize === "number") {
18338
+ return super.computeDirectionalRenderCount(
18339
+ direction,
18340
+ itemSize,
18341
+ count,
18342
+ theRenderSize
18343
+ );
18344
+ }
18345
+ let renderCount = 0;
18346
+ let size = theRenderSize.width;
18347
+ const pagesInView = Math.floor(size / this.pageWidth);
18348
+ renderCount += pagesInView * this.initialCols;
18349
+ const remainingSize = size - pagesInView * this.pageWidth;
18350
+ const sizes = [];
18351
+ for (let i = 0; i < this.initialCols; i++) {
18352
+ sizes.push(this.getItemSize(i, direction));
18353
+ }
18354
+ renderCount += getGreatestCountVisibleInSize(remainingSize, sizes);
18355
+ renderCount = Math.min(count, renderCount);
18356
+ return renderCount;
18357
+ }
18023
18358
  getRowIndexInPage(rowIndex) {
18024
18359
  return this.rowsPerPage ? rowIndex % this.rowsPerPage : rowIndex;
18025
18360
  }
@@ -18166,6 +18501,9 @@ var HorizontalLayoutMatrixBrain = class extends MatrixBrain {
18166
18501
  }
18167
18502
  this._totalPageCount = value;
18168
18503
  }
18504
+ getPageWidth() {
18505
+ return this.pageWidth;
18506
+ }
18169
18507
  doUpdateRenderCount(which = ALL_DIRECTIONS) {
18170
18508
  const rowHeight = this.getInitialRowHeight();
18171
18509
  let pageWidth = 0;
@@ -18318,6 +18656,7 @@ function initSetupState2({
18318
18656
  scrollLeft: 0
18319
18657
  },
18320
18658
  columnReorderDragColumnId: false,
18659
+ columnReorderInPageIndex: null,
18321
18660
  ready: false,
18322
18661
  focused: false,
18323
18662
  focusedWithin: false,
@@ -18326,7 +18665,8 @@ function initSetupState2({
18326
18665
  pinnedStartScrollListener: new ScrollListener(),
18327
18666
  pinnedEndScrollListener: new ScrollListener(),
18328
18667
  columnsWhenInlineGroupRenderStrategy: void 0,
18329
- editingCell: null
18668
+ editingCell: null,
18669
+ forceBodyRerenderTimestamp: 0
18330
18670
  };
18331
18671
  }
18332
18672
  var forwardProps4 = (_setupState) => {
@@ -18371,6 +18711,7 @@ var forwardProps4 = (_setupState) => {
18371
18711
  rowProps: 1,
18372
18712
  rowClassName: 1,
18373
18713
  cellClassName: 1,
18714
+ repeatWrappedGroupRows: 1,
18374
18715
  pinnedStartMaxWidth: 1,
18375
18716
  pinnedEndMaxWidth: 1,
18376
18717
  pivotColumn: 1,
@@ -19742,7 +20083,7 @@ var useLicense = (licenseKey = "") => {
19742
20083
  }
19743
20084
  let valid2 = isValidLicense(licenseKey, {
19744
20085
  publishedAt: 1624970570587,
19745
- version: "5.0.0-canary.8"
20086
+ version: "5.0.0"
19746
20087
  });
19747
20088
  if (!licenseKey && !valid2 && isInsidePlayground) {
19748
20089
  return true;
@@ -23404,17 +23745,17 @@ function HScrollSyncContent(props) {
23404
23745
  }
23405
23746
 
23406
23747
  // src/components/InfiniteTable/hooks/useVisibleColumnSizes.ts
23407
- var columnWidthAtIndex6 = stripVar(InternalVars.columnWidthAtIndex);
23408
- var columnOffsetAtIndex5 = stripVar(InternalVars.columnOffsetAtIndex);
23748
+ var columnWidthAtIndex5 = stripVar(InternalVars.columnWidthAtIndex);
23749
+ var columnOffsetAtIndex3 = stripVar(InternalVars.columnOffsetAtIndex);
23409
23750
  function useVisibleColumnSizes() {
23410
23751
  const context = useInfiniteTable();
23411
23752
  return context.computed.computedVisibleColumns.map((column) => {
23412
23753
  return {
23413
23754
  id: column.id,
23414
23755
  width: column.computedWidth,
23415
- cssVarForWidth: `var(${columnWidthAtIndex6}-${column.computedVisibleIndex})`,
23756
+ cssVarForWidth: `var(${columnWidthAtIndex5}-${column.computedVisibleIndex})`,
23416
23757
  offset: column.computedOffset,
23417
- cssVarForOffset: `var(${columnOffsetAtIndex5}-${column.computedVisibleIndex})`,
23758
+ cssVarForOffset: `var(${columnOffsetAtIndex3}-${column.computedVisibleIndex})`,
23418
23759
  pinned: column.computedPinned
23419
23760
  };
23420
23761
  });
@@ -23445,6 +23786,52 @@ function useToggleWrapRowsHorizontally() {
23445
23786
  }, [oldWrapRowsHorizontally, wrapRowsHorizontally]);
23446
23787
  }
23447
23788
 
23789
+ // src/components/InfiniteTable/hooks/useHorizontalLayout.ts
23790
+ import { useEffect as useEffect38 } from "react";
23791
+ function useHorizontalLayout() {
23792
+ const { getState, actions, dataSourceActions, getDataSourceState } = useInfiniteTable();
23793
+ const { groupBy } = getDataSourceState();
23794
+ const { brain, wrapRowsHorizontally, repeatWrappedGroupRows } = getState();
23795
+ useEffect38(() => {
23796
+ if (!wrapRowsHorizontally) {
23797
+ return;
23798
+ }
23799
+ const onVerticalRenderRangeChange = () => {
23800
+ const {
23801
+ rowsPerPage: currentRowsPerPage,
23802
+ repeatWrappedGroupRows: currentRepeatWrappedGroupRows
23803
+ } = getDataSourceState();
23804
+ let changes = false;
23805
+ const rowsPerPage = brain.rowsPerPage;
23806
+ const newRowsPerPage = groupBy && groupBy.length > 0 ? rowsPerPage : null;
23807
+ if (currentRowsPerPage != newRowsPerPage) {
23808
+ dataSourceActions.rowsPerPage = newRowsPerPage;
23809
+ changes = true;
23810
+ }
23811
+ if (currentRepeatWrappedGroupRows != !!repeatWrappedGroupRows) {
23812
+ dataSourceActions.repeatWrappedGroupRows = !!repeatWrappedGroupRows;
23813
+ changes = true;
23814
+ }
23815
+ return changes;
23816
+ };
23817
+ onVerticalRenderRangeChange();
23818
+ let timeoutId;
23819
+ const off = brain.onVerticalRenderRangeChange(() => {
23820
+ if (onVerticalRenderRangeChange()) {
23821
+ timeoutId = setTimeout(() => {
23822
+ actions.forceBodyRerenderTimestamp = Date.now();
23823
+ });
23824
+ }
23825
+ });
23826
+ return () => {
23827
+ if (timeoutId) {
23828
+ clearTimeout(timeoutId);
23829
+ }
23830
+ off();
23831
+ };
23832
+ }, [brain, wrapRowsHorizontally, groupBy, repeatWrappedGroupRows]);
23833
+ }
23834
+
23448
23835
  // src/components/InfiniteTable/index.tsx
23449
23836
  var InfiniteTableClassName = internalProps.rootClassName;
23450
23837
  var HOVERED_CLASS_NAMES = [RowHoverCls, "InfiniteColumnCell--hovered"];
@@ -23576,6 +23963,7 @@ function InfiniteTableBody() {
23576
23963
  return /* @__PURE__ */ React68.createElement(InfiniteTableBodyContainer, { onContextMenu }, /* @__PURE__ */ React68.createElement(
23577
23964
  HeadlessTable,
23578
23965
  {
23966
+ forceRerenderTimestamp: componentState.forceBodyRerenderTimestamp,
23579
23967
  debugId,
23580
23968
  tabIndex: tabIndex ?? 0,
23581
23969
  autoFocus: autoFocus ?? void 0,
@@ -23655,6 +24043,7 @@ var InfiniteTableComponent = React68.memo(
23655
24043
  dataSourceActions.scrollStopDelayUpdatedByTable = scrollStopDelay;
23656
24044
  }, [scrollStopDelay]);
23657
24045
  useAutoSizeColumns();
24046
+ useHorizontalLayout();
23658
24047
  useEditingCallbackProps();
23659
24048
  const { menuPortal } = useColumnMenu();
23660
24049
  const { menuPortal: cellContextMenuPortal } = useCellContextMenu();
@@ -23800,6 +24189,7 @@ var InfiniteTable = function(props) {
23800
24189
  /* @__PURE__ */ React68.createElement(
23801
24190
  InfiniteTableRoot,
23802
24191
  {
24192
+ repeatWrappedGroupRows: !!props.wrapRowsHorizontally,
23803
24193
  rowHeight: DEFAULT_ROW_HEIGHT,
23804
24194
  columnHeaderHeight: DEFAULT_COLUMN_HEADER_HEIGHT,
23805
24195
  ...props
@@ -24056,7 +24446,7 @@ var keyboardShortcuts = {
24056
24446
  };
24057
24447
 
24058
24448
  // src/components/hooks/useInterceptedMap.ts
24059
- import { useEffect as useEffect39 } from "react";
24449
+ import { useEffect as useEffect40 } from "react";
24060
24450
  function interceptMap(map2, fns) {
24061
24451
  const { set, delete: deleteKey, clear } = map2;
24062
24452
  if (fns.set) {
@@ -24218,7 +24608,7 @@ var WeakFixedSizeSet = _WeakFixedSizeSet;
24218
24608
  WeakFixedSizeSet.DEFAULT_SIZE = 10;
24219
24609
 
24220
24610
  // src/components/hooks/useEffectWhenSameDeps.ts
24221
- import { useEffect as useEffect40, useRef as useRef31 } from "react";
24611
+ import { useEffect as useEffect41, useRef as useRef31 } from "react";
24222
24612
  var isSameDeps = (deps, prevDeps) => {
24223
24613
  return deps.every((dep, index) => dep === prevDeps[index]);
24224
24614
  };
@@ -24232,7 +24622,7 @@ var useEffectWhenSameDeps = (callback, deps) => {
24232
24622
  effectDepsRef.current = effectDeps;
24233
24623
  const callbackRef = useRef31(callback);
24234
24624
  callbackRef.current = callback;
24235
- useEffect40(() => {
24625
+ useEffect41(() => {
24236
24626
  if (isInitialRef.current) {
24237
24627
  isInitialRef.current = false;
24238
24628
  return;
@@ -24242,7 +24632,7 @@ var useEffectWhenSameDeps = (callback, deps) => {
24242
24632
  };
24243
24633
 
24244
24634
  // src/components/hooks/useEffectWhen.ts
24245
- import { useEffect as useEffect41, useRef as useRef32 } from "react";
24635
+ import { useEffect as useEffect42, useRef as useRef32 } from "react";
24246
24636
  var isSameDeps2 = (deps, prevDeps, compare) => {
24247
24637
  return deps.every((dep, index) => {
24248
24638
  if (compare) {
@@ -24272,7 +24662,7 @@ var useEffectWhen = (callback, options) => {
24272
24662
  if (sameRespected && differentRespected) {
24273
24663
  isInitialRef.current = false;
24274
24664
  }
24275
- useEffect41(() => {
24665
+ useEffect42(() => {
24276
24666
  if (isInitialRef.current) {
24277
24667
  return;
24278
24668
  }