@infinite-table/infinite-react 4.0.0 → 4.1.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.css +1 -1
- package/index.d.ts +42 -13
- package/index.dev.js +522 -384
- package/index.dev.mjs +521 -385
- package/index.js +2 -2
- package/index.mjs +2 -2
- package/package.json +2 -2
package/index.dev.mjs
CHANGED
|
@@ -1176,9 +1176,10 @@ var useOnScroll = (domRef, onScroll) => {
|
|
|
1176
1176
|
};
|
|
1177
1177
|
|
|
1178
1178
|
// src/components/VirtualScrollContainer/VirtualScrollContainer.css.ts
|
|
1179
|
-
var ScrollableCls = { true: "
|
|
1180
|
-
var ScrollableHorizontalCls = { true: "
|
|
1181
|
-
var ScrollableVerticalCls = { true: "
|
|
1179
|
+
var ScrollableCls = { true: "VirtualScrollContainer_getOverflowFor_true__1ueijco2", false: "VirtualScrollContainer_getOverflowFor_false__1ueijco3", visible: "VirtualScrollContainer_getOverflowFor_visible__1ueijco4", auto: "VirtualScrollContainer_getOverflowFor_auto__1ueijco5", hidden: "VirtualScrollContainer_getOverflowFor_hidden__1ueijco6" };
|
|
1180
|
+
var ScrollableHorizontalCls = { true: "VirtualScrollContainer_getOverflowFor_true__1ueijco7", false: "VirtualScrollContainer_getOverflowFor_false__1ueijco8", visible: "VirtualScrollContainer_getOverflowFor_visible__1ueijco9", auto: "VirtualScrollContainer_getOverflowFor_auto__1ueijcoa", hidden: "VirtualScrollContainer_getOverflowFor_hidden__1ueijcob" };
|
|
1181
|
+
var ScrollableVerticalCls = { true: "VirtualScrollContainer_getOverflowFor_true__1ueijcoc", false: "VirtualScrollContainer_getOverflowFor_false__1ueijcod", visible: "VirtualScrollContainer_getOverflowFor_visible__1ueijcoe", auto: "VirtualScrollContainer_getOverflowFor_auto__1ueijcof", hidden: "VirtualScrollContainer_getOverflowFor_hidden__1ueijcog" };
|
|
1182
|
+
var VirtualScrollContainerChildToScrollCls = "VirtualScrollContainer_VirtualScrollContainerChildToScrollCls__1ueijco1";
|
|
1182
1183
|
var VirtualScrollContainerCls = "VirtualScrollContainer_VirtualScrollContainerCls__1ueijco0 utilities_boxSizingBorderBox__16lm1iw0";
|
|
1183
1184
|
|
|
1184
1185
|
// src/components/VirtualScrollContainer/getScrollableClassName.ts
|
|
@@ -1387,7 +1388,7 @@ var internalProps = {
|
|
|
1387
1388
|
};
|
|
1388
1389
|
|
|
1389
1390
|
// src/components/InfiniteTable/vars.css.ts
|
|
1390
|
-
var ThemeVars = { color: { accent: "var(--infinite-accent-color)", error: "var(--infinite-error-color)", color: "var(--infinite-color)" }, spacing: { "0": "var(--infinite-space-0)", "1": "var(--infinite-space-1)", "2": "var(--infinite-space-2)", "3": "var(--infinite-space-3)", "4": "var(--infinite-space-4)", "5": "var(--infinite-space-5)", "6": "var(--infinite-space-6)", "7": "var(--infinite-space-7)", "8": "var(--infinite-space-8)", "9": "var(--infinite-space-9)", "10": "var(--infinite-space-10)" }, fontSize: { "0": "var(--infinite-font-size-0)", "1": "var(--infinite-font-size-1)", "2": "var(--infinite-font-size-2)", "3": "var(--infinite-font-size-3)", "4": "var(--infinite-font-size-4)", "5": "var(--infinite-font-size-5)", "6": "var(--infinite-font-size-6)", "7": "var(--infinite-font-size-7)" }, fontFamily: "var(--infinite-font-family)", minHeight: "var(--infinite-min-height)", borderRadius: "var(--infinite-border-radius)", background: "var(--infinite-background)", iconSize: "var(--infinite-icon-size)", 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)" }, Cell: { 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)", selectedBackground: "var(--infinite-row-selected-background)", activeBackground: "var(--infinite-active-row-background)", activeBorderColor: "var(--infinite-active-row-border-color)", activeBorderWidth: "var(--infinite-active-row-border-width)", activeBorderStyle: "var(--infinite-active-row-border-style)", activeBorder: "var(--infinite-active-row-border)", activeBackgroundAlpha: "var(--infinite-active-row-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-row-background-alpha--table-unfocused)", hoverBackground: "var(--infinite-row-hover-background)", selectedHoverBackground: "var(--infinite-row-selected-hover-background)", groupRowBackground: "var(--infinite-group-row-background)", groupRowColumnNesting: "var(--infinite-group-row-column-nesting)", groupNesting: "var(--infinite-dont-override-group-row-nesting-length)", pointerEventsWhileScrolling: "var(--infinite-row-pointer-events-while-scrolling)" }, ColumnCell: { background: "var(--infinite-column-cell-bg-dont-override)" } } };
|
|
1391
|
+
var ThemeVars = { color: { accent: "var(--infinite-accent-color)", error: "var(--infinite-error-color)", color: "var(--infinite-color)" }, spacing: { "0": "var(--infinite-space-0)", "1": "var(--infinite-space-1)", "2": "var(--infinite-space-2)", "3": "var(--infinite-space-3)", "4": "var(--infinite-space-4)", "5": "var(--infinite-space-5)", "6": "var(--infinite-space-6)", "7": "var(--infinite-space-7)", "8": "var(--infinite-space-8)", "9": "var(--infinite-space-9)", "10": "var(--infinite-space-10)" }, fontSize: { "0": "var(--infinite-font-size-0)", "1": "var(--infinite-font-size-1)", "2": "var(--infinite-font-size-2)", "3": "var(--infinite-font-size-3)", "4": "var(--infinite-font-size-4)", "5": "var(--infinite-font-size-5)", "6": "var(--infinite-font-size-6)", "7": "var(--infinite-font-size-7)" }, fontFamily: "var(--infinite-font-family)", minHeight: "var(--infinite-min-height)", borderRadius: "var(--infinite-border-radius)", background: "var(--infinite-background)", iconSize: "var(--infinite-icon-size)", runtime: { bodyWidth: "var(--infinite-runtime-body-content-width)", totalVisibleColumnsWidth: "var(--infinite-runtime-total-visible-columns-width)", visibleColumnsCount: "var(--infinite-runtime-visible-columns-count)" }, 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: { 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)", selectedBackground: "var(--infinite-row-selected-background)", activeBackground: "var(--infinite-active-row-background)", activeBorderColor: "var(--infinite-active-row-border-color)", activeBorderWidth: "var(--infinite-active-row-border-width)", activeBorderStyle: "var(--infinite-active-row-border-style)", activeBorder: "var(--infinite-active-row-border)", activeBackgroundAlpha: "var(--infinite-active-row-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-row-background-alpha--table-unfocused)", hoverBackground: "var(--infinite-row-hover-background)", selectedHoverBackground: "var(--infinite-row-selected-hover-background)", groupRowBackground: "var(--infinite-group-row-background)", groupRowColumnNesting: "var(--infinite-group-row-column-nesting)", groupNesting: "var(--infinite-dont-override-group-row-nesting-length)", pointerEventsWhileScrolling: "var(--infinite-row-pointer-events-while-scrolling)" }, ColumnCell: { background: "var(--infinite-column-cell-bg-dont-override)" } } };
|
|
1391
1392
|
var columnHeaderHeightName = "column-header-height";
|
|
1392
1393
|
|
|
1393
1394
|
// src/components/InfiniteTable/utils/infiniteDOMUtils.ts
|
|
@@ -4096,8 +4097,8 @@ var useRerender = () => {
|
|
|
4096
4097
|
};
|
|
4097
4098
|
|
|
4098
4099
|
// src/components/InfiniteTable/components/ActiveCellIndicator.css.ts
|
|
4099
|
-
var ActiveCellIndicatorCls = { visible: "ActiveCellIndicator_ActiveCellIndicatorCls_visible__nxbq1c2 ActiveCellIndicator_ActiveCellIndicator__nxbq1c1 utilities_pointerEvents_none__16lm1iwl
|
|
4100
|
-
var ActiveIndicatorWrapperCls = "utilities_pointerEvents_none__16lm1iwl utilities_position_sticky__16lm1iw4 utilities_left_0__16lm1iw1e utilities_top_0__16lm1iw1c utilities_height_0__16lm1iw18 utilities_zIndex_1000000__16lm1iwu";
|
|
4100
|
+
var ActiveCellIndicatorCls = { visible: "ActiveCellIndicator_ActiveCellIndicatorCls_visible__nxbq1c2 ActiveCellIndicator_ActiveCellIndicator__nxbq1c1 utilities_pointerEvents_none__16lm1iwl utilities_position_absolute__16lm1iw2", hidden: "ActiveCellIndicator_ActiveCellIndicatorCls_hidden__nxbq1c3 ActiveCellIndicator_ActiveCellIndicator__nxbq1c1 utilities_pointerEvents_none__16lm1iwl utilities_position_absolute__16lm1iw2" };
|
|
4101
|
+
var ActiveIndicatorWrapperCls = "ActiveCellIndicator_ActiveIndicatorWrapperCls__nxbq1c0 utilities_pointerEvents_none__16lm1iwl utilities_position_sticky__16lm1iw4 utilities_left_0__16lm1iw1e utilities_top_0__16lm1iw1c utilities_height_0__16lm1iw18 utilities_zIndex_1000000__16lm1iwu";
|
|
4101
4102
|
|
|
4102
4103
|
// src/components/InfiniteTable/components/ActiveRowIndicator.css.ts
|
|
4103
4104
|
var ActiveRowIndicatorCls = { visible: "ActiveRowIndicator_ActiveRowIndicatorCls_visible__j26lrx1 ActiveRowIndicator_ActiveRowIndicator__j26lrx0 utilities_pointerEvents_none__16lm1iwl utilities_position_sticky__16lm1iw4 utilities_width_100%__16lm1iw1b utilities_top_0__16lm1iw1c utilities_left_0__16lm1iw1e", hidden: "ActiveRowIndicator_ActiveRowIndicatorCls_hidden__j26lrx2 ActiveRowIndicator_ActiveRowIndicator__j26lrx0 utilities_pointerEvents_none__16lm1iwl utilities_position_sticky__16lm1iw4 utilities_width_100%__16lm1iw1b utilities_top_0__16lm1iw1c utilities_left_0__16lm1iw1e" };
|
|
@@ -4167,13 +4168,6 @@ import { useEffect as useEffect6, useLayoutEffect as useLayoutEffect5, useRef as
|
|
|
4167
4168
|
var { rootClassName: rootClassName4 } = internalProps;
|
|
4168
4169
|
var baseCls2 = `${rootClassName4}-ActiveCellIndicator`;
|
|
4169
4170
|
var columnZIndexAtIndex2 = stripVar(InternalVars.columnZIndexAtIndex);
|
|
4170
|
-
var ActiveStyle2 = {
|
|
4171
|
-
[stripVar(InternalVars.activeCellOffsetX)]: InternalVars.activeCellColOffset,
|
|
4172
|
-
[stripVar(InternalVars.activeCellOffsetY)]: InternalVars.activeCellRowOffset,
|
|
4173
|
-
transform: `translate3d(${InternalVars.activeCellOffsetX}, ${InternalVars.activeCellOffsetY}, 0px)`,
|
|
4174
|
-
width: InternalVars.activeCellColWidth,
|
|
4175
|
-
height: InternalVars.activeCellRowHeight
|
|
4176
|
-
};
|
|
4177
4171
|
var reposition = (brain, activeCellIndex, rowHeight, domRef) => {
|
|
4178
4172
|
if (activeCellIndex == null) {
|
|
4179
4173
|
return;
|
|
@@ -4212,6 +4206,7 @@ var ActiveCellIndicatorFn = (props) => {
|
|
|
4212
4206
|
"div",
|
|
4213
4207
|
{
|
|
4214
4208
|
className: ActiveIndicatorWrapperCls,
|
|
4209
|
+
ref: domRef,
|
|
4215
4210
|
"data-name": "active-cell",
|
|
4216
4211
|
style: active ? {
|
|
4217
4212
|
zIndex: `var(${columnZIndexAtIndex2}-${props.activeCellIndex[1]})`
|
|
@@ -4220,10 +4215,8 @@ var ActiveCellIndicatorFn = (props) => {
|
|
|
4220
4215
|
/* @__PURE__ */ React12.createElement(
|
|
4221
4216
|
"div",
|
|
4222
4217
|
{
|
|
4223
|
-
ref: domRef,
|
|
4224
4218
|
"data-name": "active-cell-indicator",
|
|
4225
|
-
className: `${baseCls2} ${active ? ActiveCellIndicatorCls.visible : ActiveCellIndicatorCls.hidden}
|
|
4226
|
-
style: active ? ActiveStyle2 : void 0
|
|
4219
|
+
className: `${baseCls2} ${active ? ActiveCellIndicatorCls.visible : ActiveCellIndicatorCls.hidden}`
|
|
4227
4220
|
}
|
|
4228
4221
|
)
|
|
4229
4222
|
)
|
|
@@ -4254,6 +4247,10 @@ function useMatrixBrain(brain, brainOptions, fixedCellsInfo) {
|
|
|
4254
4247
|
colspan: brainOptions.colspan
|
|
4255
4248
|
});
|
|
4256
4249
|
}
|
|
4250
|
+
var CHILD_TO_SCROLL_CLS = join(
|
|
4251
|
+
scrollTransformTargetCls,
|
|
4252
|
+
VirtualScrollContainerChildToScrollCls
|
|
4253
|
+
);
|
|
4257
4254
|
function HeadlessTable(props) {
|
|
4258
4255
|
const _a = props, {
|
|
4259
4256
|
brain,
|
|
@@ -4332,7 +4329,7 @@ function HeadlessTable(props) {
|
|
|
4332
4329
|
"div",
|
|
4333
4330
|
{
|
|
4334
4331
|
ref: domRef,
|
|
4335
|
-
className:
|
|
4332
|
+
className: CHILD_TO_SCROLL_CLS,
|
|
4336
4333
|
"data-name": "scroll-transform-target"
|
|
4337
4334
|
},
|
|
4338
4335
|
/* @__PURE__ */ React13.createElement(
|
|
@@ -4768,7 +4765,7 @@ function useComponentState() {
|
|
|
4768
4765
|
return React14.useContext(Context);
|
|
4769
4766
|
}
|
|
4770
4767
|
|
|
4771
|
-
// src/components/InfiniteTable/components/
|
|
4768
|
+
// src/components/InfiniteTable/components/InfiniteTableFooter/InfiniteTableFooter.tsx
|
|
4772
4769
|
import * as React15 from "react";
|
|
4773
4770
|
|
|
4774
4771
|
// src/components/InfiniteTable/hooks/useInternalProps.ts
|
|
@@ -4795,49 +4792,25 @@ var userSelect = { none: "utilities_userSelect_none__16lm1iw17" };
|
|
|
4795
4792
|
var visibility = { visible: "utilities_visibility_visible__16lm1iw20", hidden: "utilities_visibility_hidden__16lm1iw21" };
|
|
4796
4793
|
var zIndex = { "1": "utilities_zIndex_1__16lm1iwo", "10": "utilities_zIndex_10__16lm1iwp", "100": "utilities_zIndex_100__16lm1iwq", "1000": "utilities_zIndex_1000__16lm1iwr", "10000": "utilities_zIndex_10000__16lm1iws", "100000": "utilities_zIndex_100000__16lm1iwt", "1000000": "utilities_zIndex_1000000__16lm1iwu", "10000000": "utilities_zIndex_10000000__16lm1iwv", "1k": "utilities_zIndex_1k__16lm1iww", "10k": "utilities_zIndex_10k__16lm1iwx", "100k": "utilities_zIndex_100k__16lm1iwy" };
|
|
4797
4794
|
|
|
4798
|
-
// src/components/InfiniteTable/components/
|
|
4799
|
-
|
|
4795
|
+
// src/components/InfiniteTable/components/InfiniteTableFooter/InfiniteTableFooter.tsx
|
|
4796
|
+
function InfiniteTableFooter(props) {
|
|
4800
4797
|
const { rootClassName: rootClassName12 } = useInternalProps();
|
|
4801
4798
|
return /* @__PURE__ */ React15.createElement(
|
|
4802
4799
|
"div",
|
|
4803
|
-
__spreadProps(__spreadValues({
|
|
4804
|
-
ref
|
|
4805
|
-
}, props), {
|
|
4800
|
+
__spreadProps(__spreadValues({}, props), {
|
|
4806
4801
|
className: join(
|
|
4807
|
-
`${rootClassName12}
|
|
4802
|
+
`${rootClassName12}Footer`,
|
|
4808
4803
|
position.relative,
|
|
4809
|
-
flex
|
|
4810
|
-
|
|
4804
|
+
display.flex,
|
|
4805
|
+
flexFlow.row,
|
|
4811
4806
|
props.className
|
|
4812
4807
|
)
|
|
4813
4808
|
})
|
|
4814
4809
|
);
|
|
4815
|
-
}
|
|
4816
|
-
|
|
4817
|
-
// src/components/InfiniteTable/components/InfiniteTableFooter/InfiniteTableFooter.tsx
|
|
4818
|
-
import * as React16 from "react";
|
|
4819
|
-
var InfiniteTableFooter = React16.forwardRef(
|
|
4820
|
-
function InfiniteTableFooter2(props, ref) {
|
|
4821
|
-
const { rootClassName: rootClassName12 } = useInternalProps();
|
|
4822
|
-
return /* @__PURE__ */ React16.createElement(
|
|
4823
|
-
"div",
|
|
4824
|
-
__spreadProps(__spreadValues({
|
|
4825
|
-
ref
|
|
4826
|
-
}, props), {
|
|
4827
|
-
className: join(
|
|
4828
|
-
`${rootClassName12}Footer`,
|
|
4829
|
-
position.relative,
|
|
4830
|
-
display.flex,
|
|
4831
|
-
flexFlow.row,
|
|
4832
|
-
props.className
|
|
4833
|
-
)
|
|
4834
|
-
})
|
|
4835
|
-
);
|
|
4836
|
-
}
|
|
4837
|
-
);
|
|
4810
|
+
}
|
|
4838
4811
|
|
|
4839
4812
|
// src/components/InfiniteTable/components/InfiniteTableHeader/InfiniteTableHeaderCell.tsx
|
|
4840
|
-
import * as
|
|
4813
|
+
import * as React42 from "react";
|
|
4841
4814
|
import { useCallback as useCallback14, useContext as useContext7, useEffect as useEffect15, useRef as useRef16 } from "react";
|
|
4842
4815
|
import { createPortal } from "react-dom";
|
|
4843
4816
|
|
|
@@ -4851,7 +4824,7 @@ function keyMirror(obj) {
|
|
|
4851
4824
|
}
|
|
4852
4825
|
|
|
4853
4826
|
// src/components/InfiniteTable/components/icons/Icon.tsx
|
|
4854
|
-
import * as
|
|
4827
|
+
import * as React16 from "react";
|
|
4855
4828
|
var Icon = (props) => {
|
|
4856
4829
|
var _a;
|
|
4857
4830
|
const size = (_a = props.size) != null ? _a : `var(--infinite-icon-size)`;
|
|
@@ -4863,69 +4836,69 @@ var Icon = (props) => {
|
|
|
4863
4836
|
}, props.style);
|
|
4864
4837
|
return (
|
|
4865
4838
|
//@ts-ignore
|
|
4866
|
-
/* @__PURE__ */
|
|
4839
|
+
/* @__PURE__ */ React16.createElement("svg", __spreadProps(__spreadValues({ viewBox: "0 0 24 24" }, props), { style: style2 }), props.children)
|
|
4867
4840
|
);
|
|
4868
4841
|
};
|
|
4869
4842
|
|
|
4870
4843
|
// src/components/InfiniteTable/components/icons/IncludesOperatorIcon.tsx
|
|
4871
|
-
import * as
|
|
4844
|
+
import * as React17 from "react";
|
|
4872
4845
|
var IncludesOperatorIcon = (props) => {
|
|
4873
|
-
return /* @__PURE__ */
|
|
4846
|
+
return /* @__PURE__ */ React17.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React17.createElement("path", { d: "M5,4V7H10.5V19H13.5V7H19V4H5Z" }));
|
|
4874
4847
|
};
|
|
4875
4848
|
|
|
4876
4849
|
// src/components/InfiniteTable/components/icons/EndsWithOperatorIcon.tsx
|
|
4877
|
-
import * as
|
|
4850
|
+
import * as React18 from "react";
|
|
4878
4851
|
var EndsWithOperatorIcon = (props) => {
|
|
4879
|
-
return /* @__PURE__ */
|
|
4852
|
+
return /* @__PURE__ */ React18.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React18.createElement("path", { d: "M11.14 4L6.43 16H8.36L9.32 13.43H14.67L15.64 16H17.57L12.86 4M12 6.29L14.03 11.71H9.96M20 14V18H2V20H22V14Z" }));
|
|
4880
4853
|
};
|
|
4881
4854
|
|
|
4882
4855
|
// src/components/InfiniteTable/components/icons/EqualOperatorIcon.tsx
|
|
4883
|
-
import * as
|
|
4856
|
+
import * as React19 from "react";
|
|
4884
4857
|
var EqualOperatorIcon = (props) => {
|
|
4885
|
-
return /* @__PURE__ */
|
|
4858
|
+
return /* @__PURE__ */ React19.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React19.createElement("path", { d: "M19,10H5V8H19V10M19,16H5V14H19V16Z" }));
|
|
4886
4859
|
};
|
|
4887
4860
|
|
|
4888
4861
|
// src/components/InfiniteTable/components/icons/GTEOperatorIcon.tsx
|
|
4889
|
-
import * as
|
|
4862
|
+
import * as React20 from "react";
|
|
4890
4863
|
var GTEOperatorIcon = (props) => {
|
|
4891
|
-
return /* @__PURE__ */
|
|
4864
|
+
return /* @__PURE__ */ React20.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React20.createElement("path", { d: "M6.5,2.27L20,10.14L6.5,18L5.5,16.27L16.03,10.14L5.5,4L6.5,2.27M20,20V22H5V20H20Z" }));
|
|
4892
4865
|
};
|
|
4893
4866
|
|
|
4894
4867
|
// src/components/InfiniteTable/components/icons/GTOperatorIcon.tsx
|
|
4895
|
-
import * as
|
|
4868
|
+
import * as React21 from "react";
|
|
4896
4869
|
var GTOperatorIcon = (props) => {
|
|
4897
|
-
return /* @__PURE__ */
|
|
4870
|
+
return /* @__PURE__ */ React21.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React21.createElement("path", { d: "M5.5,4.14L4.5,5.86L15,12L4.5,18.14L5.5,19.86L19,12L5.5,4.14Z" }));
|
|
4898
4871
|
};
|
|
4899
4872
|
|
|
4900
4873
|
// src/components/InfiniteTable/components/icons/LTEOperatorIcon.tsx
|
|
4901
|
-
import * as
|
|
4874
|
+
import * as React22 from "react";
|
|
4902
4875
|
var LTEOperatorIcon = (props) => {
|
|
4903
|
-
return /* @__PURE__ */
|
|
4876
|
+
return /* @__PURE__ */ React22.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React22.createElement("path", { d: "M18.5,2.27L5,10.14L18.5,18L19.5,16.27L8.97,10.14L19.5,4L18.5,2.27M5,20V22H20V20H5Z" }));
|
|
4904
4877
|
};
|
|
4905
4878
|
|
|
4906
4879
|
// src/components/InfiniteTable/components/icons/LTOperatorIcon.tsx
|
|
4907
|
-
import * as
|
|
4880
|
+
import * as React23 from "react";
|
|
4908
4881
|
var LTOperatorIcon = (props) => {
|
|
4909
|
-
return /* @__PURE__ */
|
|
4882
|
+
return /* @__PURE__ */ React23.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React23.createElement("path", { d: "M18.5,4.14L19.5,5.86L8.97,12L19.5,18.14L18.5,19.86L5,12L18.5,4.14Z" }));
|
|
4910
4883
|
};
|
|
4911
4884
|
|
|
4912
4885
|
// src/components/InfiniteTable/components/icons/NotEqualOperatorIcon.tsx
|
|
4913
|
-
import * as
|
|
4886
|
+
import * as React24 from "react";
|
|
4914
4887
|
var NotEqualOperatorIcon = (props) => {
|
|
4915
|
-
return /* @__PURE__ */
|
|
4888
|
+
return /* @__PURE__ */ React24.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React24.createElement("path", { d: "M21,10H9V8H21V10M21,16H9V14H21V16M4,5H6V16H4V5M6,18V20H4V18H6Z" }));
|
|
4916
4889
|
};
|
|
4917
4890
|
|
|
4918
4891
|
// src/components/InfiniteTable/components/icons/StartsWithOperatorIcon.tsx
|
|
4919
|
-
import * as
|
|
4892
|
+
import * as React25 from "react";
|
|
4920
4893
|
var StartsWithOperatorIcon = (props) => {
|
|
4921
|
-
return /* @__PURE__ */
|
|
4894
|
+
return /* @__PURE__ */ React25.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React25.createElement("path", { d: "M11.14 4L6.43 16H8.36L9.32 13.43H14.67L15.64 16H17.57L12.86 4M12 6.29L14.03 11.71H9.96M4 18V15H2V20H22V18Z" }));
|
|
4922
4895
|
};
|
|
4923
4896
|
|
|
4924
4897
|
// src/components/InfiniteTable/components/FilterEditors.tsx
|
|
4925
|
-
import * as
|
|
4898
|
+
import * as React29 from "react";
|
|
4926
4899
|
|
|
4927
4900
|
// src/components/InfiniteTable/components/InfiniteTableHeader/InfiniteTableColumnHeaderFilter.tsx
|
|
4928
|
-
import * as
|
|
4901
|
+
import * as React28 from "react";
|
|
4929
4902
|
import { useEffect as useEffect11, useState as useState6 } from "react";
|
|
4930
4903
|
|
|
4931
4904
|
// src/components/InfiniteTable/hooks/useInfiniteTable.ts
|
|
@@ -4958,7 +4931,7 @@ var useInfiniteTableState = () => {
|
|
|
4958
4931
|
};
|
|
4959
4932
|
|
|
4960
4933
|
// src/components/InfiniteTable/components/icons/FilterIcon.tsx
|
|
4961
|
-
import * as
|
|
4934
|
+
import * as React26 from "react";
|
|
4962
4935
|
import { useEffect as useEffect10, useLayoutEffect as useLayoutEffect8, useState as useState5 } from "react";
|
|
4963
4936
|
|
|
4964
4937
|
// ../node_modules/@vanilla-extract/recipes/dist/createRuntimeFn-62c9670f.esm.js
|
|
@@ -5132,7 +5105,7 @@ function FilterIcon(props) {
|
|
|
5132
5105
|
return null;
|
|
5133
5106
|
}
|
|
5134
5107
|
const indexStyle = {};
|
|
5135
|
-
return /* @__PURE__ */
|
|
5108
|
+
return /* @__PURE__ */ React26.createElement(
|
|
5136
5109
|
"div",
|
|
5137
5110
|
{
|
|
5138
5111
|
"data-name": "filter-icon",
|
|
@@ -5144,7 +5117,7 @@ function FilterIcon(props) {
|
|
|
5144
5117
|
`${InfiniteTableIconClassName}-sort`
|
|
5145
5118
|
)
|
|
5146
5119
|
},
|
|
5147
|
-
showIndex ? /* @__PURE__ */
|
|
5120
|
+
showIndex ? /* @__PURE__ */ React26.createElement(
|
|
5148
5121
|
"div",
|
|
5149
5122
|
{
|
|
5150
5123
|
"data-name": "index",
|
|
@@ -5153,9 +5126,9 @@ function FilterIcon(props) {
|
|
|
5153
5126
|
},
|
|
5154
5127
|
index
|
|
5155
5128
|
) : null,
|
|
5156
|
-
/* @__PURE__ */
|
|
5157
|
-
/* @__PURE__ */
|
|
5158
|
-
/* @__PURE__ */
|
|
5129
|
+
/* @__PURE__ */ React26.createElement("div", { style: __spreadValues({ width: sizes[0] }, lineStyle) }),
|
|
5130
|
+
/* @__PURE__ */ React26.createElement("div", { style: __spreadValues({ width: sizes[1] }, lineStyle) }),
|
|
5131
|
+
/* @__PURE__ */ React26.createElement("div", { style: __spreadValues({ width: sizes[2] }, lineStyle) })
|
|
5159
5132
|
);
|
|
5160
5133
|
}
|
|
5161
5134
|
|
|
@@ -6200,10 +6173,10 @@ function getColumnLabel(colIdOrCol, context) {
|
|
|
6200
6173
|
}
|
|
6201
6174
|
|
|
6202
6175
|
// src/components/InfiniteTable/components/InfiniteTableHeader/InfiniteTableColumnHeaderFilterContext.ts
|
|
6203
|
-
import
|
|
6176
|
+
import React27 from "react";
|
|
6204
6177
|
var InfiniteTableColumnHeaderFilterClassName = `${rootClassName2}HeaderCell__filter`;
|
|
6205
6178
|
var InfiniteTableColumnHeaderFilterOperatorClassName = `${rootClassName2}HeaderCell__filterOperator`;
|
|
6206
|
-
var InfiniteTableColumnHeaderFilterContext =
|
|
6179
|
+
var InfiniteTableColumnHeaderFilterContext = React27.createContext(null);
|
|
6207
6180
|
|
|
6208
6181
|
// src/components/InfiniteTable/components/InfiniteTableHeader/InfiniteTableColumnHeaderFilter.tsx
|
|
6209
6182
|
var InfiniteTableColumnHeaderFilterInputClassName = `${InfiniteTableColumnHeaderFilterClassName}__input`;
|
|
@@ -6214,14 +6187,14 @@ function InfiniteTableColumnHeaderFilter(props) {
|
|
|
6214
6187
|
const FilterEditor = props.filterEditor;
|
|
6215
6188
|
const FilterOperatorSwitch = props.filterOperatorSwitch;
|
|
6216
6189
|
const [focused, setFocused] = useState6(false);
|
|
6217
|
-
const onFocus =
|
|
6190
|
+
const onFocus = React28.useCallback(() => {
|
|
6218
6191
|
setFocused(true);
|
|
6219
6192
|
}, []);
|
|
6220
|
-
const onBlur =
|
|
6193
|
+
const onBlur = React28.useCallback(() => {
|
|
6221
6194
|
setFocused(false);
|
|
6222
6195
|
}, []);
|
|
6223
6196
|
const active = filterOperatorMenuVisibleForColumnId === column.id || focused;
|
|
6224
|
-
return /* @__PURE__ */
|
|
6197
|
+
return /* @__PURE__ */ React28.createElement(
|
|
6225
6198
|
"div",
|
|
6226
6199
|
{
|
|
6227
6200
|
onPointerUp: stopPropagation,
|
|
@@ -6235,14 +6208,14 @@ function InfiniteTableColumnHeaderFilter(props) {
|
|
|
6235
6208
|
)}`,
|
|
6236
6209
|
style: { height: props.columnHeaderHeight }
|
|
6237
6210
|
},
|
|
6238
|
-
/* @__PURE__ */
|
|
6211
|
+
/* @__PURE__ */ React28.createElement(InfiniteTableColumnHeaderFilterContext.Provider, { value: props }, /* @__PURE__ */ React28.createElement(FilterOperatorSwitch, null), /* @__PURE__ */ React28.createElement(FilterEditor, null))
|
|
6239
6212
|
);
|
|
6240
6213
|
}
|
|
6241
6214
|
function InfiniteTableFilterOperatorSwitch() {
|
|
6242
6215
|
var _a, _b;
|
|
6243
6216
|
const { columnApi, disabled, operator } = useInfiniteColumnFilterEditor();
|
|
6244
6217
|
const Icon2 = (_b = (_a = operator == null ? void 0 : operator.components) == null ? void 0 : _a.Icon) != null ? _b : FilterIcon;
|
|
6245
|
-
return /* @__PURE__ */
|
|
6218
|
+
return /* @__PURE__ */ React28.createElement(
|
|
6246
6219
|
"div",
|
|
6247
6220
|
{
|
|
6248
6221
|
"data-name": "filter-operator",
|
|
@@ -6260,7 +6233,7 @@ function InfiniteTableFilterOperatorSwitch() {
|
|
|
6260
6233
|
disabled ? `${InfiniteTableColumnHeaderFilterOperatorClassName}--disabled` : ""
|
|
6261
6234
|
)
|
|
6262
6235
|
},
|
|
6263
|
-
/* @__PURE__ */
|
|
6236
|
+
/* @__PURE__ */ React28.createElement(
|
|
6264
6237
|
Icon2,
|
|
6265
6238
|
{
|
|
6266
6239
|
size: 20,
|
|
@@ -6272,7 +6245,7 @@ function InfiniteTableFilterOperatorSwitch() {
|
|
|
6272
6245
|
);
|
|
6273
6246
|
}
|
|
6274
6247
|
function InfiniteTableColumnHeaderFilterEmpty() {
|
|
6275
|
-
return /* @__PURE__ */
|
|
6248
|
+
return /* @__PURE__ */ React28.createElement(
|
|
6276
6249
|
"div",
|
|
6277
6250
|
{
|
|
6278
6251
|
onPointerUp: stopPropagation,
|
|
@@ -6289,7 +6262,7 @@ function useInfiniteColumnFilterEditor() {
|
|
|
6289
6262
|
const context = useInfiniteTable();
|
|
6290
6263
|
const { column, columnApi } = useInfiniteHeaderCell();
|
|
6291
6264
|
const columnLabel = getColumnLabel(column, context);
|
|
6292
|
-
const filterContextValue =
|
|
6265
|
+
const filterContextValue = React28.useContext(
|
|
6293
6266
|
InfiniteTableColumnHeaderFilterContext
|
|
6294
6267
|
);
|
|
6295
6268
|
const { columnFilterType, filterTypes, columnFilterValue } = filterContextValue;
|
|
@@ -6297,17 +6270,17 @@ function useInfiniteColumnFilterEditor() {
|
|
|
6297
6270
|
const [theValue, setTheValue] = useState6(
|
|
6298
6271
|
(_a = columnFilterValue == null ? void 0 : columnFilterValue.filter.value) != null ? _a : ""
|
|
6299
6272
|
);
|
|
6300
|
-
const onInputChange =
|
|
6273
|
+
const onInputChange = React28.useCallback(
|
|
6301
6274
|
(filterValue) => {
|
|
6302
6275
|
setTheValue(filterValue);
|
|
6303
6276
|
filterContextValue.onChange(filterValue);
|
|
6304
6277
|
},
|
|
6305
6278
|
[filterContextValue.onChange]
|
|
6306
6279
|
);
|
|
6307
|
-
const clearValue =
|
|
6280
|
+
const clearValue = React28.useCallback(() => {
|
|
6308
6281
|
context.api.clearColumnFilter(column.id);
|
|
6309
6282
|
}, [column.id]);
|
|
6310
|
-
const removeColumnFilter =
|
|
6283
|
+
const removeColumnFilter = React28.useCallback(() => {
|
|
6311
6284
|
context.api.removeColumnFilter(column.id);
|
|
6312
6285
|
}, [column.id]);
|
|
6313
6286
|
useEffect11(() => {
|
|
@@ -6350,7 +6323,7 @@ function useInfiniteColumnFilterEditor() {
|
|
|
6350
6323
|
// src/components/InfiniteTable/components/FilterEditors.tsx
|
|
6351
6324
|
function StringFilterEditor() {
|
|
6352
6325
|
const { ariaLabel, value, setValue, className, disabled } = useInfiniteColumnFilterEditor();
|
|
6353
|
-
return /* @__PURE__ */
|
|
6326
|
+
return /* @__PURE__ */ React29.createElement(
|
|
6354
6327
|
"input",
|
|
6355
6328
|
{
|
|
6356
6329
|
"data-xxx": true,
|
|
@@ -6367,7 +6340,7 @@ function StringFilterEditor() {
|
|
|
6367
6340
|
}
|
|
6368
6341
|
function NumberFilterEditor() {
|
|
6369
6342
|
const { ariaLabel, value, setValue, className, disabled } = useInfiniteColumnFilterEditor();
|
|
6370
|
-
return /* @__PURE__ */
|
|
6343
|
+
return /* @__PURE__ */ React29.createElement(
|
|
6371
6344
|
"input",
|
|
6372
6345
|
{
|
|
6373
6346
|
"aria-label": ariaLabel,
|
|
@@ -6608,6 +6581,17 @@ var rafFn = (fn) => {
|
|
|
6608
6581
|
};
|
|
6609
6582
|
|
|
6610
6583
|
// src/components/InfiniteTable/hooks/useDOMProps.ts
|
|
6584
|
+
var publicRuntimeVars = {
|
|
6585
|
+
bodyWidth: { name: stripVar(ThemeVars.runtime.bodyWidth), value: "" },
|
|
6586
|
+
totalVisibleColumnsWidth: {
|
|
6587
|
+
name: stripVar(ThemeVars.runtime.totalVisibleColumnsWidth),
|
|
6588
|
+
value: ""
|
|
6589
|
+
},
|
|
6590
|
+
visibleColumnsCount: {
|
|
6591
|
+
name: stripVar(ThemeVars.runtime.visibleColumnsCount),
|
|
6592
|
+
value: ""
|
|
6593
|
+
}
|
|
6594
|
+
};
|
|
6611
6595
|
var scrollbarWidthHorizontal = stripVar(
|
|
6612
6596
|
InternalVars.scrollbarWidthHorizontal
|
|
6613
6597
|
);
|
|
@@ -6663,6 +6647,7 @@ function useDOMProps(initialDOMProps) {
|
|
|
6663
6647
|
computedPinnedStartColumns,
|
|
6664
6648
|
computedPinnedEndColumns,
|
|
6665
6649
|
computedVisibleColumns,
|
|
6650
|
+
computedUnpinnedColumnsWidth,
|
|
6666
6651
|
scrollbars
|
|
6667
6652
|
} = computed;
|
|
6668
6653
|
const prevPinnedEndCols = [];
|
|
@@ -6688,6 +6673,9 @@ function useDOMProps(initialDOMProps) {
|
|
|
6688
6673
|
},
|
|
6689
6674
|
{}
|
|
6690
6675
|
);
|
|
6676
|
+
cssVars[publicRuntimeVars.bodyWidth.name] = `calc(${InternalVars.bodyWidth} - ${InternalVars.scrollbarWidthVertical})`;
|
|
6677
|
+
cssVars[publicRuntimeVars.totalVisibleColumnsWidth.name] = `${computedPinnedStartColumnsWidth + computedPinnedEndColumnsWidth + computedUnpinnedColumnsWidth}px`;
|
|
6678
|
+
cssVars[publicRuntimeVars.visibleColumnsCount.name] = computedVisibleColumns.length;
|
|
6691
6679
|
if (activeCellIndex != null) {
|
|
6692
6680
|
cssVars[activeCellColWidth] = `var(${getCSSVarNameForColWidth(
|
|
6693
6681
|
activeCellIndex[1]
|
|
@@ -7427,14 +7415,14 @@ var useColumnPointerEvents = ({
|
|
|
7427
7415
|
};
|
|
7428
7416
|
|
|
7429
7417
|
// src/components/InfiniteTable/utils/RenderHookComponentForInfinite.tsx
|
|
7430
|
-
import * as
|
|
7418
|
+
import * as React37 from "react";
|
|
7431
7419
|
|
|
7432
7420
|
// src/components/InfiniteTable/components/InfiniteTableRow/InfiniteTableColumnCell.tsx
|
|
7433
|
-
import * as
|
|
7421
|
+
import * as React36 from "react";
|
|
7434
7422
|
import { useCallback as useCallback12, useContext as useContext6, useMemo as useMemo4 } from "react";
|
|
7435
7423
|
|
|
7436
7424
|
// src/components/InfiniteTable/utils/getColumnForGroupBy.tsx
|
|
7437
|
-
import * as
|
|
7425
|
+
import * as React32 from "react";
|
|
7438
7426
|
|
|
7439
7427
|
// src/components/DataSource/state/rowInfoStatus.ts
|
|
7440
7428
|
var showLoadingIcon = (rowInfo) => {
|
|
@@ -7445,7 +7433,7 @@ var showLoadingIcon = (rowInfo) => {
|
|
|
7445
7433
|
};
|
|
7446
7434
|
|
|
7447
7435
|
// src/components/InfiniteTable/components/icons/ExpanderIcon.tsx
|
|
7448
|
-
import * as
|
|
7436
|
+
import * as React30 from "react";
|
|
7449
7437
|
import { useState as useState8 } from "react";
|
|
7450
7438
|
|
|
7451
7439
|
// src/components/InfiniteTable/components/icons/ExpanderIcon.css.ts
|
|
@@ -7466,12 +7454,12 @@ function ExpanderIcon(props) {
|
|
|
7466
7454
|
setExpanded(!expanded);
|
|
7467
7455
|
}
|
|
7468
7456
|
};
|
|
7469
|
-
|
|
7457
|
+
React30.useEffect(() => {
|
|
7470
7458
|
if (isControlled("expanded", props)) {
|
|
7471
7459
|
setExpanded(props.expanded);
|
|
7472
7460
|
}
|
|
7473
7461
|
}, [props.expanded]);
|
|
7474
|
-
return /* @__PURE__ */
|
|
7462
|
+
return /* @__PURE__ */ React30.createElement(
|
|
7475
7463
|
"svg",
|
|
7476
7464
|
{
|
|
7477
7465
|
"data-name": "expander-icon",
|
|
@@ -7494,19 +7482,19 @@ function ExpanderIcon(props) {
|
|
|
7494
7482
|
`InfiniteIcon-expander--${direction === "end" ? "end" : "start"}`
|
|
7495
7483
|
)
|
|
7496
7484
|
},
|
|
7497
|
-
/* @__PURE__ */
|
|
7485
|
+
/* @__PURE__ */ React30.createElement("path", { d: "M8.59 16.59L13.17 12 8.59 7.41 10 6l6 6-6 6-1.41-1.41z" })
|
|
7498
7486
|
);
|
|
7499
7487
|
}
|
|
7500
7488
|
|
|
7501
7489
|
// src/components/InfiniteTable/components/icons/LoadingIcon.tsx
|
|
7502
|
-
import * as
|
|
7490
|
+
import * as React31 from "react";
|
|
7503
7491
|
|
|
7504
7492
|
// src/components/InfiniteTable/components/icons/LoadingIcon.css.ts
|
|
7505
7493
|
var LoadingIconCls = "utilities_stroke_accentColor__16lm1iwb utilities_flex_none__16lm1iwn utilities_cursor_pointer__16lm1iwi";
|
|
7506
7494
|
|
|
7507
7495
|
// src/components/InfiniteTable/components/icons/LoadingIcon.tsx
|
|
7508
7496
|
var LoadingIcon = (props) => {
|
|
7509
|
-
return /* @__PURE__ */
|
|
7497
|
+
return /* @__PURE__ */ React31.createElement(
|
|
7510
7498
|
"svg",
|
|
7511
7499
|
{
|
|
7512
7500
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -7526,7 +7514,7 @@ var LoadingIcon = (props) => {
|
|
|
7526
7514
|
"InfiniteIcon-loading"
|
|
7527
7515
|
)
|
|
7528
7516
|
},
|
|
7529
|
-
/* @__PURE__ */
|
|
7517
|
+
/* @__PURE__ */ React31.createElement(
|
|
7530
7518
|
"circle",
|
|
7531
7519
|
{
|
|
7532
7520
|
cx: "50",
|
|
@@ -7536,7 +7524,7 @@ var LoadingIcon = (props) => {
|
|
|
7536
7524
|
r: "35",
|
|
7537
7525
|
strokeDasharray: "164.93361431346415 56.97787143782138"
|
|
7538
7526
|
},
|
|
7539
|
-
/* @__PURE__ */
|
|
7527
|
+
/* @__PURE__ */ React31.createElement(
|
|
7540
7528
|
"animateTransform",
|
|
7541
7529
|
{
|
|
7542
7530
|
attributeName: "transform",
|
|
@@ -7581,11 +7569,11 @@ function getGroupColumnRender({
|
|
|
7581
7569
|
);
|
|
7582
7570
|
if (groupRenderStrategy === "multi-column") {
|
|
7583
7571
|
if (groupIndexForColumn + 1 !== groupRowInfo.groupNesting && groupRowInfo.isGroupRow) {
|
|
7584
|
-
return selectionCheckBox ? /* @__PURE__ */
|
|
7572
|
+
return selectionCheckBox ? /* @__PURE__ */ React32.createElement("div", { className }, selectionCheckBox) : null;
|
|
7585
7573
|
}
|
|
7586
7574
|
} else if (groupRenderStrategy === "single-column" && !groupRowInfo.isGroupRow) {
|
|
7587
7575
|
}
|
|
7588
|
-
return /* @__PURE__ */
|
|
7576
|
+
return /* @__PURE__ */ React32.createElement("div", { className }, groupIcon, selectionCheckBox, /* @__PURE__ */ React32.createElement("div", { className: cssEllipsisClassName }, valueToRender != null ? valueToRender : null));
|
|
7589
7577
|
};
|
|
7590
7578
|
}
|
|
7591
7579
|
function getGroupColumnRenderGroupIcon({
|
|
@@ -7634,9 +7622,9 @@ function getGroupColumnRenderGroupIcon({
|
|
|
7634
7622
|
const showExpanderIcon = pivotBy ? (((_b = groupRowInfo.groupKeys) == null ? void 0 : _b.length) || 0) < (groupBy == null ? void 0 : groupBy.length) : (((_c = groupRowInfo.groupKeys) == null ? void 0 : _c.length) || 0) <= (groupBy == null ? void 0 : groupBy.length);
|
|
7635
7623
|
const isLoading = showLoadingIcon(groupRowInfo);
|
|
7636
7624
|
if (isLoading) {
|
|
7637
|
-
icon = /* @__PURE__ */
|
|
7625
|
+
icon = /* @__PURE__ */ React32.createElement(LoadingIcon, null);
|
|
7638
7626
|
} else if (showExpanderIcon) {
|
|
7639
|
-
const defaultIcon = /* @__PURE__ */
|
|
7627
|
+
const defaultIcon = /* @__PURE__ */ React32.createElement(
|
|
7640
7628
|
ExpanderIcon,
|
|
7641
7629
|
{
|
|
7642
7630
|
expanded: !collapsed,
|
|
@@ -7650,7 +7638,7 @@ function getGroupColumnRenderGroupIcon({
|
|
|
7650
7638
|
}
|
|
7651
7639
|
if (initialRenderGroupIcon) {
|
|
7652
7640
|
renderOptions.renderBag.groupIcon = icon;
|
|
7653
|
-
icon = /* @__PURE__ */
|
|
7641
|
+
icon = /* @__PURE__ */ React32.createElement(
|
|
7654
7642
|
RenderCellHookComponent,
|
|
7655
7643
|
{
|
|
7656
7644
|
render: initialRenderGroupIcon,
|
|
@@ -7730,7 +7718,7 @@ var ColumnCellSelectionIndicatorRecipe = createRuntimeFn({ defaultClassName: "ce
|
|
|
7730
7718
|
var SelectionCheckboxCls = "cell_SelectionCheckboxCls__1eexc2a7";
|
|
7731
7719
|
|
|
7732
7720
|
// src/components/InfiniteTable/components/CheckBox.tsx
|
|
7733
|
-
import * as
|
|
7721
|
+
import * as React33 from "react";
|
|
7734
7722
|
import { useEffect as useEffect13, useRef as useRef12 } from "react";
|
|
7735
7723
|
|
|
7736
7724
|
// src/components/InfiniteTable/components/CheckBox.css.ts
|
|
@@ -7769,7 +7757,7 @@ function InfiniteCheckBoxComponent() {
|
|
|
7769
7757
|
useEffect13(() => {
|
|
7770
7758
|
inputRef.current.indeterminate = checked == null;
|
|
7771
7759
|
}, [checked]);
|
|
7772
|
-
return /* @__PURE__ */
|
|
7760
|
+
return /* @__PURE__ */ React33.createElement(
|
|
7773
7761
|
"input",
|
|
7774
7762
|
__spreadProps(__spreadValues({}, domProps), {
|
|
7775
7763
|
className: join("InfiniteCheckBox", CheckBoxCls, domProps == null ? void 0 : domProps.className),
|
|
@@ -7787,7 +7775,7 @@ function InfiniteCheckBoxComponent() {
|
|
|
7787
7775
|
);
|
|
7788
7776
|
}
|
|
7789
7777
|
function InfiniteCheckBox(props) {
|
|
7790
|
-
return /* @__PURE__ */
|
|
7778
|
+
return /* @__PURE__ */ React33.createElement(InfiniteCheckBoxRoot, __spreadValues({}, props), /* @__PURE__ */ React33.createElement(InfiniteCheckBoxComponent, null));
|
|
7791
7779
|
}
|
|
7792
7780
|
|
|
7793
7781
|
// src/components/InfiniteTable/components/InfiniteTableRow/columnRendering.tsx
|
|
@@ -8098,7 +8086,7 @@ function getFormattedValueContextForCell(options) {
|
|
|
8098
8086
|
}
|
|
8099
8087
|
|
|
8100
8088
|
// src/components/InfiniteTable/components/InfiniteTableRow/InfiniteTableCell.tsx
|
|
8101
|
-
import * as
|
|
8089
|
+
import * as React34 from "react";
|
|
8102
8090
|
var { rootClassName: rootClassName5 } = internalProps;
|
|
8103
8091
|
var InfiniteTableCellClassName = `${rootClassName5}Cell`;
|
|
8104
8092
|
var InfiniteTableCellContentClassName = `${rootClassName5}Cell_content`;
|
|
@@ -8157,7 +8145,7 @@ function InfiniteTableCellFn(props) {
|
|
|
8157
8145
|
// ? `${InfiniteTableCellClassName}--shifting ${CellClsVariants.shifting}`
|
|
8158
8146
|
// : '',
|
|
8159
8147
|
),
|
|
8160
|
-
children: /* @__PURE__ */
|
|
8148
|
+
children: /* @__PURE__ */ React34.createElement(React34.Fragment, null, beforeChildren, /* @__PURE__ */ React34.createElement(
|
|
8161
8149
|
"div",
|
|
8162
8150
|
{
|
|
8163
8151
|
className: join(
|
|
@@ -8175,21 +8163,21 @@ function InfiniteTableCellFn(props) {
|
|
|
8175
8163
|
}
|
|
8176
8164
|
const RenderComponent = cellType === "body" ? (_b = column.components) == null ? void 0 : _b.ColumnCell : (_c = column.components) == null ? void 0 : _c.HeaderCell;
|
|
8177
8165
|
if (RenderComponent) {
|
|
8178
|
-
return /* @__PURE__ */
|
|
8166
|
+
return /* @__PURE__ */ React34.createElement(RenderComponent, __spreadValues({}, finalDOMProps));
|
|
8179
8167
|
}
|
|
8180
|
-
return /* @__PURE__ */
|
|
8168
|
+
return /* @__PURE__ */ React34.createElement("div", __spreadProps(__spreadValues({}, finalDOMProps), { ref: domRef }));
|
|
8181
8169
|
}
|
|
8182
|
-
var InfiniteTableCell =
|
|
8170
|
+
var InfiniteTableCell = React34.memo(
|
|
8183
8171
|
InfiniteTableCellFn
|
|
8184
8172
|
);
|
|
8185
8173
|
|
|
8186
8174
|
// src/components/InfiniteTable/components/InfiniteTableRow/InfiniteTableColumnEditor.tsx
|
|
8187
|
-
import * as
|
|
8175
|
+
import * as React35 from "react";
|
|
8188
8176
|
import { useCallback as useCallback10, useRef as useRef13 } from "react";
|
|
8189
8177
|
function InfiniteTableColumnEditor() {
|
|
8190
8178
|
const { initialValue, setValue, confirmEdit, cancelEdit, readOnly } = useInfiniteColumnEditor();
|
|
8191
8179
|
const domRef = useRef13();
|
|
8192
|
-
const refCallback =
|
|
8180
|
+
const refCallback = React35.useCallback((node) => {
|
|
8193
8181
|
domRef.current = node;
|
|
8194
8182
|
if (node) {
|
|
8195
8183
|
node.focus();
|
|
@@ -8205,7 +8193,7 @@ function InfiniteTableColumnEditor() {
|
|
|
8205
8193
|
event.stopPropagation();
|
|
8206
8194
|
}
|
|
8207
8195
|
}, []);
|
|
8208
|
-
return /* @__PURE__ */
|
|
8196
|
+
return /* @__PURE__ */ React35.createElement(React35.Fragment, null, /* @__PURE__ */ React35.createElement(
|
|
8209
8197
|
"input",
|
|
8210
8198
|
{
|
|
8211
8199
|
readOnly,
|
|
@@ -8225,11 +8213,11 @@ function InfiniteTableColumnEditor() {
|
|
|
8225
8213
|
// src/components/InfiniteTable/components/InfiniteTableRow/InfiniteTableColumnCell.tsx
|
|
8226
8214
|
var { rootClassName: rootClassName6 } = internalProps;
|
|
8227
8215
|
var columnZIndexAtIndex4 = stripVar(InternalVars.columnZIndexAtIndex);
|
|
8228
|
-
var InfiniteTableColumnCellContext =
|
|
8216
|
+
var InfiniteTableColumnCellContext = React36.createContext(null);
|
|
8229
8217
|
var InfiniteTableColumnCellClassName = `${rootClassName6}ColumnCell`;
|
|
8230
8218
|
var defaultRenderRowDetailIcon = (params) => {
|
|
8231
8219
|
const { toggleCurrentRowDetails, rowDetailState } = params;
|
|
8232
|
-
return /* @__PURE__ */
|
|
8220
|
+
return /* @__PURE__ */ React36.createElement(
|
|
8233
8221
|
ExpanderIcon,
|
|
8234
8222
|
{
|
|
8235
8223
|
style: {
|
|
@@ -8250,7 +8238,7 @@ var defaultRenderSelectionCheckBox = (params) => {
|
|
|
8250
8238
|
} = params;
|
|
8251
8239
|
if (rowInfo.isGroupRow && !column.groupByForColumn) {
|
|
8252
8240
|
}
|
|
8253
|
-
return /* @__PURE__ */
|
|
8241
|
+
return /* @__PURE__ */ React36.createElement(
|
|
8254
8242
|
InfiniteCheckBox,
|
|
8255
8243
|
{
|
|
8256
8244
|
domProps: {
|
|
@@ -8302,7 +8290,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8302
8290
|
showZebraRows
|
|
8303
8291
|
} = props;
|
|
8304
8292
|
if (!column) {
|
|
8305
|
-
return /* @__PURE__ */
|
|
8293
|
+
return /* @__PURE__ */ React36.createElement("div", { ref: domRef }, "no column");
|
|
8306
8294
|
}
|
|
8307
8295
|
const { rowSelected } = rowInfo;
|
|
8308
8296
|
const {
|
|
@@ -8349,7 +8337,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8349
8337
|
} = colRenderingParams;
|
|
8350
8338
|
const { align: align2, verticalAlign } = renderParams;
|
|
8351
8339
|
const renderParam = renderParams;
|
|
8352
|
-
const renderParamRef =
|
|
8340
|
+
const renderParamRef = React36.useRef(renderParam);
|
|
8353
8341
|
const onClick = useCallback12(
|
|
8354
8342
|
(event) => {
|
|
8355
8343
|
const colIndex = column.computedVisibleIndex;
|
|
@@ -8403,7 +8391,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8403
8391
|
[rowInfo]
|
|
8404
8392
|
);
|
|
8405
8393
|
const EditorComponent = (_b = (_a = column.components) == null ? void 0 : _a.Editor) != null ? _b : InfiniteTableColumnEditor;
|
|
8406
|
-
const editor = inEdit ? /* @__PURE__ */
|
|
8394
|
+
const editor = inEdit ? /* @__PURE__ */ React36.createElement(CellEditorContextComponent, { contextValue: renderParam }, /* @__PURE__ */ React36.createElement(EditorComponent, null)) : null;
|
|
8407
8395
|
const renderChildren = useCallback12(
|
|
8408
8396
|
once(() => {
|
|
8409
8397
|
if (hidden) {
|
|
@@ -8413,7 +8401,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8413
8401
|
return null;
|
|
8414
8402
|
}
|
|
8415
8403
|
if (renderFunctions.renderGroupIcon) {
|
|
8416
|
-
renderParam.renderBag.groupIcon = /* @__PURE__ */
|
|
8404
|
+
renderParam.renderBag.groupIcon = /* @__PURE__ */ React36.createElement(
|
|
8417
8405
|
RenderCellHookComponent,
|
|
8418
8406
|
{
|
|
8419
8407
|
render: renderFunctions.renderGroupIcon,
|
|
@@ -8424,7 +8412,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8424
8412
|
);
|
|
8425
8413
|
}
|
|
8426
8414
|
if (renderFunctions.renderSelectionCheckBox && selectionMode == "multi-row") {
|
|
8427
|
-
renderParam.renderBag.selectionCheckBox = /* @__PURE__ */
|
|
8415
|
+
renderParam.renderBag.selectionCheckBox = /* @__PURE__ */ React36.createElement(
|
|
8428
8416
|
RenderCellHookComponent,
|
|
8429
8417
|
{
|
|
8430
8418
|
render: defaultRenderSelectionCheckBox,
|
|
@@ -8432,7 +8420,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8432
8420
|
}
|
|
8433
8421
|
);
|
|
8434
8422
|
if (renderFunctions.renderSelectionCheckBox !== true) {
|
|
8435
|
-
renderParam.renderBag.selectionCheckBox = /* @__PURE__ */
|
|
8423
|
+
renderParam.renderBag.selectionCheckBox = /* @__PURE__ */ React36.createElement(
|
|
8436
8424
|
RenderCellHookComponent,
|
|
8437
8425
|
{
|
|
8438
8426
|
render: renderFunctions.renderSelectionCheckBox,
|
|
@@ -8444,7 +8432,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8444
8432
|
}
|
|
8445
8433
|
}
|
|
8446
8434
|
if (renderFunctions.renderRowDetailIcon) {
|
|
8447
|
-
renderParam.renderBag.rowDetailsIcon = /* @__PURE__ */
|
|
8435
|
+
renderParam.renderBag.rowDetailsIcon = /* @__PURE__ */ React36.createElement(
|
|
8448
8436
|
RenderCellHookComponent,
|
|
8449
8437
|
{
|
|
8450
8438
|
render: defaultRenderRowDetailIcon,
|
|
@@ -8454,7 +8442,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8454
8442
|
}
|
|
8455
8443
|
);
|
|
8456
8444
|
if (typeof renderFunctions.renderRowDetailIcon === "function") {
|
|
8457
|
-
renderParam.renderBag.rowDetailsIcon = /* @__PURE__ */
|
|
8445
|
+
renderParam.renderBag.rowDetailsIcon = /* @__PURE__ */ React36.createElement(
|
|
8458
8446
|
RenderCellHookComponent,
|
|
8459
8447
|
{
|
|
8460
8448
|
render: renderFunctions.renderRowDetailIcon,
|
|
@@ -8466,7 +8454,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8466
8454
|
}
|
|
8467
8455
|
}
|
|
8468
8456
|
if (renderFunctions.renderValue) {
|
|
8469
|
-
renderParam.renderBag.value = /* @__PURE__ */
|
|
8457
|
+
renderParam.renderBag.value = /* @__PURE__ */ React36.createElement(
|
|
8470
8458
|
RenderCellHookComponent,
|
|
8471
8459
|
{
|
|
8472
8460
|
render: renderFunctions.renderValue,
|
|
@@ -8477,7 +8465,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8477
8465
|
);
|
|
8478
8466
|
}
|
|
8479
8467
|
if (rowInfo.isGroupRow && renderFunctions.renderGroupValue) {
|
|
8480
|
-
renderParam.renderBag.value = /* @__PURE__ */
|
|
8468
|
+
renderParam.renderBag.value = /* @__PURE__ */ React36.createElement(
|
|
8481
8469
|
RenderCellHookComponent,
|
|
8482
8470
|
{
|
|
8483
8471
|
render: renderFunctions.renderGroupValue,
|
|
@@ -8488,7 +8476,7 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8488
8476
|
);
|
|
8489
8477
|
}
|
|
8490
8478
|
if (!rowInfo.isGroupRow && renderFunctions.renderLeafValue) {
|
|
8491
|
-
renderParam.renderBag.value = /* @__PURE__ */
|
|
8479
|
+
renderParam.renderBag.value = /* @__PURE__ */ React36.createElement(
|
|
8492
8480
|
RenderCellHookComponent,
|
|
8493
8481
|
{
|
|
8494
8482
|
render: renderFunctions.renderLeafValue,
|
|
@@ -8503,9 +8491,9 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8503
8491
|
if (valueToRender instanceof Date) {
|
|
8504
8492
|
valueToRender = valueToRender.toLocaleDateString();
|
|
8505
8493
|
}
|
|
8506
|
-
const all = /* @__PURE__ */
|
|
8494
|
+
const all = /* @__PURE__ */ React36.createElement(React36.Fragment, null, align2 !== "end" ? renderParam.renderBag.groupIcon : null, align2 !== "end" ? renderParam.renderBag.rowDetailsIcon : null, align2 !== "end" ? renderParam.renderBag.selectionCheckBox : null, valueToRender, align2 === "end" ? renderParam.renderBag.selectionCheckBox : null, align2 === "end" ? renderParam.renderBag.rowDetailsIcon : null, align2 === "end" ? renderParam.renderBag.groupIcon : null);
|
|
8507
8495
|
if (column.render) {
|
|
8508
|
-
return /* @__PURE__ */
|
|
8496
|
+
return /* @__PURE__ */ React36.createElement(
|
|
8509
8497
|
RenderCellHookComponent,
|
|
8510
8498
|
{
|
|
8511
8499
|
render: column.render,
|
|
@@ -8667,16 +8655,16 @@ function InfiniteTableColumnCellFn(props) {
|
|
|
8667
8655
|
return (
|
|
8668
8656
|
// this context is here for supporting useInfiniteColumnCell to be used
|
|
8669
8657
|
// with a custom column component, specified via column.components.ColumnCell
|
|
8670
|
-
/* @__PURE__ */
|
|
8658
|
+
/* @__PURE__ */ React36.createElement(
|
|
8671
8659
|
ContextProvider,
|
|
8672
8660
|
{
|
|
8673
8661
|
value: renderParamRef.current
|
|
8674
8662
|
},
|
|
8675
|
-
/* @__PURE__ */
|
|
8663
|
+
/* @__PURE__ */ React36.createElement(InfiniteTableCell, __spreadValues({}, cellProps))
|
|
8676
8664
|
)
|
|
8677
8665
|
);
|
|
8678
8666
|
}
|
|
8679
|
-
var InfiniteTableColumnCell =
|
|
8667
|
+
var InfiniteTableColumnCell = React36.memo(
|
|
8680
8668
|
InfiniteTableColumnCellFn
|
|
8681
8669
|
);
|
|
8682
8670
|
function useInfiniteColumnCell() {
|
|
@@ -8691,14 +8679,14 @@ function useInfiniteColumnEditor() {
|
|
|
8691
8679
|
state: { editingValueRef, editingCell }
|
|
8692
8680
|
} = useInfiniteTable();
|
|
8693
8681
|
const { column, rowInfo } = useInfiniteColumnCell();
|
|
8694
|
-
const [initialValue] =
|
|
8695
|
-
const [currentValue, setCurrentValue] =
|
|
8682
|
+
const [initialValue] = React36.useState(() => editingCell == null ? void 0 : editingCell.value);
|
|
8683
|
+
const [currentValue, setCurrentValue] = React36.useState(initialValue);
|
|
8696
8684
|
const readOnly = editingCell ? !editingCell.active && !!editingCell.waiting : false;
|
|
8697
|
-
const setValue =
|
|
8685
|
+
const setValue = React36.useCallback((value) => {
|
|
8698
8686
|
editingValueRef.current = value;
|
|
8699
8687
|
setCurrentValue(value);
|
|
8700
8688
|
}, []);
|
|
8701
|
-
|
|
8689
|
+
React36.useLayoutEffect(() => {
|
|
8702
8690
|
editingValueRef.current = initialValue;
|
|
8703
8691
|
}, []);
|
|
8704
8692
|
const confirmEdit = api.confirmEdit;
|
|
@@ -8727,7 +8715,7 @@ function RenderHookComponent(props) {
|
|
|
8727
8715
|
// src/components/InfiniteTable/utils/RenderHookComponentForInfinite.tsx
|
|
8728
8716
|
function RenderCellHookComponent(props) {
|
|
8729
8717
|
const ContextProvider = InfiniteTableColumnCellContext.Provider;
|
|
8730
|
-
return /* @__PURE__ */
|
|
8718
|
+
return /* @__PURE__ */ React37.createElement(ContextProvider, { value: props.renderParam }, /* @__PURE__ */ React37.createElement(
|
|
8731
8719
|
RenderHookComponent,
|
|
8732
8720
|
{
|
|
8733
8721
|
render: props.render,
|
|
@@ -8737,11 +8725,11 @@ function RenderCellHookComponent(props) {
|
|
|
8737
8725
|
}
|
|
8738
8726
|
function CellEditorContextComponent(props) {
|
|
8739
8727
|
const ContextProvider = InfiniteTableColumnCellContext.Provider;
|
|
8740
|
-
return /* @__PURE__ */
|
|
8728
|
+
return /* @__PURE__ */ React37.createElement(ContextProvider, { value: props.contextValue }, props.children);
|
|
8741
8729
|
}
|
|
8742
8730
|
function RenderHeaderCellHookComponent(props) {
|
|
8743
8731
|
const ContextProvider = InfiniteTableHeaderCellContext.Provider;
|
|
8744
|
-
return /* @__PURE__ */
|
|
8732
|
+
return /* @__PURE__ */ React37.createElement(ContextProvider, { value: props.renderParam }, /* @__PURE__ */ React37.createElement(
|
|
8745
8733
|
RenderHookComponent,
|
|
8746
8734
|
{
|
|
8747
8735
|
render: props.render,
|
|
@@ -8751,7 +8739,7 @@ function RenderHeaderCellHookComponent(props) {
|
|
|
8751
8739
|
}
|
|
8752
8740
|
|
|
8753
8741
|
// src/components/InfiniteTable/components/icons/MenuIcon.tsx
|
|
8754
|
-
import * as
|
|
8742
|
+
import * as React38 from "react";
|
|
8755
8743
|
var defaultLineStyle2 = {
|
|
8756
8744
|
width: "100%",
|
|
8757
8745
|
pointerEvents: "none"
|
|
@@ -8775,7 +8763,7 @@ function MenuIcon(props) {
|
|
|
8775
8763
|
const lineStyle = __spreadValues(__spreadProps(__spreadValues({}, defaultLineStyle2), {
|
|
8776
8764
|
borderTop: `${ThemeVars.components.HeaderCell.menuIconLineWidth} solid currentColor`
|
|
8777
8765
|
}), props.lineStyle);
|
|
8778
|
-
return /* @__PURE__ */
|
|
8766
|
+
return /* @__PURE__ */ React38.createElement(
|
|
8779
8767
|
"div",
|
|
8780
8768
|
__spreadProps(__spreadValues(__spreadProps(__spreadValues({}, domProps), {
|
|
8781
8769
|
style: style2
|
|
@@ -8791,12 +8779,12 @@ function MenuIcon(props) {
|
|
|
8791
8779
|
`${InfiniteTableIconClassName}-menu`
|
|
8792
8780
|
)
|
|
8793
8781
|
}),
|
|
8794
|
-
children != null ? children : /* @__PURE__ */
|
|
8782
|
+
children != null ? children : /* @__PURE__ */ React38.createElement(React38.Fragment, null, /* @__PURE__ */ React38.createElement("div", { className: lineClassName, style: lineStyle }), /* @__PURE__ */ React38.createElement("div", { className: lineClassName, style: lineStyle }), /* @__PURE__ */ React38.createElement("div", { className: lineClassName, style: lineStyle }))
|
|
8795
8783
|
);
|
|
8796
8784
|
}
|
|
8797
8785
|
|
|
8798
8786
|
// src/components/InfiniteTable/components/icons/SortIcon.tsx
|
|
8799
|
-
import * as
|
|
8787
|
+
import * as React39 from "react";
|
|
8800
8788
|
import { useEffect as useEffect14, useState as useState10 } from "react";
|
|
8801
8789
|
|
|
8802
8790
|
// src/components/InfiniteTable/components/icons/SortIcon.css.ts
|
|
@@ -8855,7 +8843,7 @@ function SortIcon(props) {
|
|
|
8855
8843
|
if (direction === -1) {
|
|
8856
8844
|
indexStyle.top = "100%";
|
|
8857
8845
|
}
|
|
8858
|
-
return /* @__PURE__ */
|
|
8846
|
+
return /* @__PURE__ */ React39.createElement(
|
|
8859
8847
|
"div",
|
|
8860
8848
|
{
|
|
8861
8849
|
"data-name": "sort-icon",
|
|
@@ -8867,7 +8855,7 @@ function SortIcon(props) {
|
|
|
8867
8855
|
`${InfiniteTableIconClassName}-sort`
|
|
8868
8856
|
)
|
|
8869
8857
|
},
|
|
8870
|
-
showIndex ? /* @__PURE__ */
|
|
8858
|
+
showIndex ? /* @__PURE__ */ React39.createElement(
|
|
8871
8859
|
"div",
|
|
8872
8860
|
{
|
|
8873
8861
|
"data-name": "index",
|
|
@@ -8876,25 +8864,25 @@ function SortIcon(props) {
|
|
|
8876
8864
|
},
|
|
8877
8865
|
index
|
|
8878
8866
|
) : null,
|
|
8879
|
-
/* @__PURE__ */
|
|
8867
|
+
/* @__PURE__ */ React39.createElement(
|
|
8880
8868
|
"div",
|
|
8881
8869
|
{
|
|
8882
8870
|
style: __spreadValues({ width: sizes[0] }, lineStyle),
|
|
8883
8871
|
onTransitionEnd
|
|
8884
8872
|
}
|
|
8885
8873
|
),
|
|
8886
|
-
/* @__PURE__ */
|
|
8887
|
-
/* @__PURE__ */
|
|
8874
|
+
/* @__PURE__ */ React39.createElement("div", { style: __spreadValues({ width: sizes[1] }, lineStyle) }),
|
|
8875
|
+
/* @__PURE__ */ React39.createElement("div", { style: __spreadValues({ width: sizes[2] }, lineStyle) })
|
|
8888
8876
|
);
|
|
8889
8877
|
}
|
|
8890
8878
|
|
|
8891
8879
|
// src/components/InfiniteTable/components/InfiniteTableHeader/useColumnResizeHandle.tsx
|
|
8892
|
-
import * as
|
|
8880
|
+
import * as React41 from "react";
|
|
8893
8881
|
import { useCallback as useCallback13 } from "react";
|
|
8894
8882
|
|
|
8895
8883
|
// src/components/InfiniteTable/components/InfiniteTableHeader/ResizeHandle/index.tsx
|
|
8896
8884
|
import { useRef as useRef15, useState as useState11 } from "react";
|
|
8897
|
-
import * as
|
|
8885
|
+
import * as React40 from "react";
|
|
8898
8886
|
|
|
8899
8887
|
// src/components/InfiniteTable/components/InfiniteTableHeader/ResizeHandle/columnResizer.ts
|
|
8900
8888
|
function getColumnResizer(colIndex, {
|
|
@@ -9069,7 +9057,7 @@ function ResizeHandleFn(props) {
|
|
|
9069
9057
|
right: computedPinned === "start" ? void 0 : 0
|
|
9070
9058
|
//ThemeVars.components.HeaderCell.resizeHandleWidth,
|
|
9071
9059
|
} : computedPinned === "end" && computedFirstInCategory ? { right: void 0 } : void 0;
|
|
9072
|
-
return /* @__PURE__ */
|
|
9060
|
+
return /* @__PURE__ */ React40.createElement(
|
|
9073
9061
|
"div",
|
|
9074
9062
|
{
|
|
9075
9063
|
ref: domRef,
|
|
@@ -9082,7 +9070,7 @@ function ResizeHandleFn(props) {
|
|
|
9082
9070
|
)}`,
|
|
9083
9071
|
onPointerDown
|
|
9084
9072
|
},
|
|
9085
|
-
/* @__PURE__ */
|
|
9073
|
+
/* @__PURE__ */ React40.createElement(
|
|
9086
9074
|
"div",
|
|
9087
9075
|
{
|
|
9088
9076
|
style: style2,
|
|
@@ -9096,7 +9084,7 @@ function ResizeHandleFn(props) {
|
|
|
9096
9084
|
)
|
|
9097
9085
|
);
|
|
9098
9086
|
}
|
|
9099
|
-
var ResizeHandle =
|
|
9087
|
+
var ResizeHandle = React40.memo(ResizeHandleFn);
|
|
9100
9088
|
|
|
9101
9089
|
// src/components/InfiniteTable/components/InfiniteTableHeader/useColumnResizeHandle.tsx
|
|
9102
9090
|
function useColumnResizeHandle(column) {
|
|
@@ -9160,7 +9148,7 @@ function useColumnResizeHandle(column) {
|
|
|
9160
9148
|
},
|
|
9161
9149
|
[computeResizeForDiff]
|
|
9162
9150
|
);
|
|
9163
|
-
const resizeHandle = column.computedResizable ? /* @__PURE__ */
|
|
9151
|
+
const resizeHandle = column.computedResizable ? /* @__PURE__ */ React41.createElement(
|
|
9164
9152
|
ResizeHandle,
|
|
9165
9153
|
{
|
|
9166
9154
|
columns: computedVisibleColumns,
|
|
@@ -9179,7 +9167,7 @@ var InfiniteTableHeaderCellClassName = `${rootClassName2}HeaderCell`;
|
|
|
9179
9167
|
var defaultRenderSelectionCheckBox2 = (params) => {
|
|
9180
9168
|
const { allRowsSelected, someRowsSelected, api } = params;
|
|
9181
9169
|
const selected = allRowsSelected ? true : someRowsSelected ? null : false;
|
|
9182
|
-
return /* @__PURE__ */
|
|
9170
|
+
return /* @__PURE__ */ React42.createElement(
|
|
9183
9171
|
InfiniteCheckBox,
|
|
9184
9172
|
{
|
|
9185
9173
|
domProps: {
|
|
@@ -9196,9 +9184,9 @@ var defaultRenderSelectionCheckBox2 = (params) => {
|
|
|
9196
9184
|
}
|
|
9197
9185
|
);
|
|
9198
9186
|
};
|
|
9199
|
-
var InfiniteTableHeaderCellContext =
|
|
9187
|
+
var InfiniteTableHeaderCellContext = React42.createContext(null);
|
|
9200
9188
|
var columnZIndexAtIndex5 = stripVar(InternalVars.columnZIndexAtIndex);
|
|
9201
|
-
var spacer = /* @__PURE__ */
|
|
9189
|
+
var spacer = /* @__PURE__ */ React42.createElement("div", { className: flex["1"] });
|
|
9202
9190
|
var InfiniteHeaderCellDataAttributes = keyMirror({
|
|
9203
9191
|
"data-name": ``,
|
|
9204
9192
|
"data-field": ``,
|
|
@@ -9235,7 +9223,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9235
9223
|
const dragging = columnReorderDragColumnId === column.id;
|
|
9236
9224
|
const { onResize, height, width, headerOptions, columnsMap } = props;
|
|
9237
9225
|
const sortInfo = column.computedSortInfo;
|
|
9238
|
-
|
|
9226
|
+
const header = column.header;
|
|
9239
9227
|
const ref = useCallback14(
|
|
9240
9228
|
(node) => {
|
|
9241
9229
|
var _a2;
|
|
@@ -9259,7 +9247,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9259
9247
|
getState
|
|
9260
9248
|
});
|
|
9261
9249
|
const computedSortable = columnApi.isSortable();
|
|
9262
|
-
const sortIcon = computedSortable && (column.computedSorted || alwaysShow) ? /* @__PURE__ */
|
|
9250
|
+
const sortIcon = computedSortable && (column.computedSorted || alwaysShow) ? /* @__PURE__ */ React42.createElement(
|
|
9263
9251
|
SortIcon,
|
|
9264
9252
|
{
|
|
9265
9253
|
index: column.computedMultiSort ? column.computedSortIndex + 1 : void 0,
|
|
@@ -9276,7 +9264,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9276
9264
|
}
|
|
9277
9265
|
) : null;
|
|
9278
9266
|
const filtered = column.computedFilterable && column.computedFiltered;
|
|
9279
|
-
const filterIcon = filtered ? /* @__PURE__ */
|
|
9267
|
+
const filterIcon = filtered ? /* @__PURE__ */ React42.createElement(FilterIcon, null) : null;
|
|
9280
9268
|
const headerCSSEllipsis = (_e = (_d = column.headerCssEllipsis) != null ? _d : column.cssEllipsis) != null ? _e : true;
|
|
9281
9269
|
const menuIconProps = {
|
|
9282
9270
|
reserveSpaceWhenHidden: align2 === "center",
|
|
@@ -9296,7 +9284,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9296
9284
|
}
|
|
9297
9285
|
};
|
|
9298
9286
|
const MenuIconCmp = ((_f = column.components) == null ? void 0 : _f.MenuIcon) || (components2 == null ? void 0 : components2.MenuIcon) || MenuIcon;
|
|
9299
|
-
const menuIcon = /* @__PURE__ */
|
|
9287
|
+
const menuIcon = /* @__PURE__ */ React42.createElement(MenuIconCmp, __spreadValues({}, menuIconProps));
|
|
9300
9288
|
const initialRenderParam = {
|
|
9301
9289
|
dragging,
|
|
9302
9290
|
domRef: ref,
|
|
@@ -9327,7 +9315,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9327
9315
|
renderBag: __spreadValues({}, initialRenderParam.renderBag)
|
|
9328
9316
|
});
|
|
9329
9317
|
if (column.renderSortIcon) {
|
|
9330
|
-
renderParam2.renderBag.sortIcon = /* @__PURE__ */
|
|
9318
|
+
renderParam2.renderBag.sortIcon = /* @__PURE__ */ React42.createElement(
|
|
9331
9319
|
RenderHeaderCellHookComponent,
|
|
9332
9320
|
{
|
|
9333
9321
|
render: column.renderSortIcon,
|
|
@@ -9338,7 +9326,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9338
9326
|
);
|
|
9339
9327
|
}
|
|
9340
9328
|
if (column.renderFilterIcon) {
|
|
9341
|
-
renderParam2.renderBag.filterIcon = /* @__PURE__ */
|
|
9329
|
+
renderParam2.renderBag.filterIcon = /* @__PURE__ */ React42.createElement(
|
|
9342
9330
|
RenderHeaderCellHookComponent,
|
|
9343
9331
|
{
|
|
9344
9332
|
render: column.renderFilterIcon,
|
|
@@ -9349,7 +9337,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9349
9337
|
);
|
|
9350
9338
|
}
|
|
9351
9339
|
if (typeof column.renderMenuIcon === "function") {
|
|
9352
|
-
renderParam2.renderBag.menuIcon = /* @__PURE__ */
|
|
9340
|
+
renderParam2.renderBag.menuIcon = /* @__PURE__ */ React42.createElement(
|
|
9353
9341
|
RenderHeaderCellHookComponent,
|
|
9354
9342
|
{
|
|
9355
9343
|
render: (param) => {
|
|
@@ -9361,7 +9349,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9361
9349
|
if (result.type === MenuIconCmp || result.type === MenuIcon) {
|
|
9362
9350
|
return result;
|
|
9363
9351
|
}
|
|
9364
|
-
return /* @__PURE__ */
|
|
9352
|
+
return /* @__PURE__ */ React42.createElement(MenuIconCmp, __spreadValues({}, menuIconProps), result);
|
|
9365
9353
|
}
|
|
9366
9354
|
return null;
|
|
9367
9355
|
},
|
|
@@ -9372,7 +9360,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9372
9360
|
);
|
|
9373
9361
|
}
|
|
9374
9362
|
if (column.renderSelectionCheckBox && selectionMode === "multi-row") {
|
|
9375
|
-
renderParam2.renderBag.selectionCheckBox = /* @__PURE__ */
|
|
9363
|
+
renderParam2.renderBag.selectionCheckBox = /* @__PURE__ */ React42.createElement(
|
|
9376
9364
|
RenderHeaderCellHookComponent,
|
|
9377
9365
|
{
|
|
9378
9366
|
render: defaultRenderSelectionCheckBox2,
|
|
@@ -9383,7 +9371,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9383
9371
|
);
|
|
9384
9372
|
const renderHeaderSelectionCheckBox = (_a2 = column.renderHeaderSelectionCheckBox) != null ? _a2 : column.renderSelectionCheckBox;
|
|
9385
9373
|
if (renderHeaderSelectionCheckBox && renderHeaderSelectionCheckBox !== true) {
|
|
9386
|
-
renderParam2.renderBag.selectionCheckBox = /* @__PURE__ */
|
|
9374
|
+
renderParam2.renderBag.selectionCheckBox = /* @__PURE__ */ React42.createElement(
|
|
9387
9375
|
RenderHeaderCellHookComponent,
|
|
9388
9376
|
{
|
|
9389
9377
|
render: renderHeaderSelectionCheckBox,
|
|
@@ -9395,7 +9383,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9395
9383
|
}
|
|
9396
9384
|
}
|
|
9397
9385
|
if (header instanceof Function) {
|
|
9398
|
-
renderParam2.renderBag.header = /* @__PURE__ */
|
|
9386
|
+
renderParam2.renderBag.header = /* @__PURE__ */ React42.createElement(
|
|
9399
9387
|
RenderHeaderCellHookComponent,
|
|
9400
9388
|
{
|
|
9401
9389
|
render: header,
|
|
@@ -9406,10 +9394,10 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9406
9394
|
);
|
|
9407
9395
|
}
|
|
9408
9396
|
const theMenuIcon = column.renderMenuIcon === false ? null : renderParam2.renderBag.menuIcon;
|
|
9409
|
-
const headerContent = headerCSSEllipsis ? /* @__PURE__ */
|
|
9410
|
-
const all = /* @__PURE__ */
|
|
9397
|
+
const headerContent = headerCSSEllipsis ? /* @__PURE__ */ React42.createElement("div", { className: cssEllipsisClassName }, renderParam2.renderBag.header) : renderParam2.renderBag.header;
|
|
9398
|
+
const all = /* @__PURE__ */ React42.createElement(React42.Fragment, null, align2 === "center" ? spacer : null, renderParam2.renderBag.selectionCheckBox, headerContent, renderParam2.renderBag.sortIcon, renderParam2.renderBag.filterIcon, align2 === "center" ? spacer : null, align2 !== "center" ? spacer : null, theMenuIcon);
|
|
9411
9399
|
if (column.renderHeader) {
|
|
9412
|
-
return /* @__PURE__ */
|
|
9400
|
+
return /* @__PURE__ */ React42.createElement(
|
|
9413
9401
|
RenderHeaderCellHookComponent,
|
|
9414
9402
|
{
|
|
9415
9403
|
render: column.renderHeader,
|
|
@@ -9446,7 +9434,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9446
9434
|
});
|
|
9447
9435
|
let draggingProxy = null;
|
|
9448
9436
|
if (dragging && proxyPosition) {
|
|
9449
|
-
draggingProxy = /* @__PURE__ */
|
|
9437
|
+
draggingProxy = /* @__PURE__ */ React42.createElement(
|
|
9450
9438
|
"div",
|
|
9451
9439
|
{
|
|
9452
9440
|
key: column.id,
|
|
@@ -9470,7 +9458,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9470
9458
|
verticalAlign,
|
|
9471
9459
|
align: align2
|
|
9472
9460
|
};
|
|
9473
|
-
const debouncedOnFilterValueChange =
|
|
9461
|
+
const debouncedOnFilterValueChange = React42.useMemo(() => {
|
|
9474
9462
|
const fn = (filterValue) => {
|
|
9475
9463
|
api.setColumnFilter(column.id, filterValue);
|
|
9476
9464
|
};
|
|
@@ -9496,7 +9484,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9496
9484
|
"data-sort": column.computedSortedAsc ? "asc" : column.computedSortedDesc ? "desc" : "none",
|
|
9497
9485
|
"data-sort-index": `${(_p = column.computedSortIndex) != null ? _p : -1}`
|
|
9498
9486
|
};
|
|
9499
|
-
return /* @__PURE__ */
|
|
9487
|
+
return /* @__PURE__ */ React42.createElement(ContextProvider, { value: renderParam }, /* @__PURE__ */ React42.createElement(
|
|
9500
9488
|
InfiniteTableCell,
|
|
9501
9489
|
__spreadProps(__spreadValues({
|
|
9502
9490
|
domRef: ref,
|
|
@@ -9538,7 +9526,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9538
9526
|
CellCls
|
|
9539
9527
|
),
|
|
9540
9528
|
cssEllipsis: headerCSSEllipsis,
|
|
9541
|
-
afterChildren: /* @__PURE__ */
|
|
9529
|
+
afterChildren: /* @__PURE__ */ React42.createElement(React42.Fragment, null, showColumnFilters ? column.computedFilterable ? /* @__PURE__ */ React42.createElement(
|
|
9542
9530
|
InfiniteTableColumnHeaderFilter,
|
|
9543
9531
|
{
|
|
9544
9532
|
filterEditor: FilterEditor,
|
|
@@ -9551,7 +9539,7 @@ function InfiniteTableHeaderCell(props) {
|
|
|
9551
9539
|
columnFilterValue: column.computedFilterValue,
|
|
9552
9540
|
columnHeaderHeight
|
|
9553
9541
|
}
|
|
9554
|
-
) : /* @__PURE__ */
|
|
9542
|
+
) : /* @__PURE__ */ React42.createElement(InfiniteTableColumnHeaderFilterEmpty, null) : null, resizeHandle),
|
|
9555
9543
|
renderChildren
|
|
9556
9544
|
})
|
|
9557
9545
|
), draggingProxy);
|
|
@@ -9564,7 +9552,7 @@ function useInfiniteHeaderCell() {
|
|
|
9564
9552
|
}
|
|
9565
9553
|
|
|
9566
9554
|
// src/components/InfiniteTable/components/InfiniteTableHeader/InfiniteTableHeaderWrapper.tsx
|
|
9567
|
-
import * as
|
|
9555
|
+
import * as React47 from "react";
|
|
9568
9556
|
|
|
9569
9557
|
// src/components/InfiniteTable/components/InfiniteTableHeader/buildColumnAndGroupTree.ts
|
|
9570
9558
|
function buildColumnAndGroupTree(columns, columnGroups, columnGroupsDepthsMap, columnGroupsMaxDepth) {
|
|
@@ -9670,19 +9658,19 @@ function assignGroupOffsetsAndComputedWidths(items, groupOffset = 0) {
|
|
|
9670
9658
|
}
|
|
9671
9659
|
|
|
9672
9660
|
// src/components/InfiniteTable/components/InfiniteTableHeader/InfiniteTableHeader.tsx
|
|
9673
|
-
import * as
|
|
9661
|
+
import * as React46 from "react";
|
|
9674
9662
|
import { useCallback as useCallback16, useEffect as useEffect16, useRef as useRef18 } from "react";
|
|
9675
9663
|
|
|
9676
9664
|
// src/components/InfiniteTable/components/InfiniteTableHeader/InfiniteTableHeaderGroup.tsx
|
|
9677
|
-
import * as
|
|
9665
|
+
import * as React45 from "react";
|
|
9678
9666
|
|
|
9679
9667
|
// src/components/InfiniteTable/components/InfiniteTableHeader/useColumnGroupResizeHandle.tsx
|
|
9680
|
-
import * as
|
|
9668
|
+
import * as React44 from "react";
|
|
9681
9669
|
import { useCallback as useCallback15 } from "react";
|
|
9682
9670
|
|
|
9683
9671
|
// src/components/InfiniteTable/components/InfiniteTableHeader/ResizeHandle/GroupResizeHandle.tsx
|
|
9684
9672
|
import { useRef as useRef17, useState as useState12 } from "react";
|
|
9685
|
-
import * as
|
|
9673
|
+
import * as React43 from "react";
|
|
9686
9674
|
var { rootClassName: rootClassName8 } = internalProps;
|
|
9687
9675
|
var InfiniteTableHeaderCellResizeHandleCls2 = `${rootClassName8}HeaderCell_ResizeHandle`;
|
|
9688
9676
|
function GroupResizeHandleFn(props) {
|
|
@@ -9751,7 +9739,7 @@ function GroupResizeHandleFn(props) {
|
|
|
9751
9739
|
const style2 = (computedPinned === false || computedPinned === "start") && computedLastInCategory ? {
|
|
9752
9740
|
right: computedPinned === "start" ? void 0 : ThemeVars.components.HeaderCell.resizeHandleWidth
|
|
9753
9741
|
} : computedPinned === "end" && computedFirstInCategory ? { right: void 0 } : void 0;
|
|
9754
|
-
return /* @__PURE__ */
|
|
9742
|
+
return /* @__PURE__ */ React43.createElement(
|
|
9755
9743
|
"div",
|
|
9756
9744
|
{
|
|
9757
9745
|
ref: domRef,
|
|
@@ -9764,7 +9752,7 @@ function GroupResizeHandleFn(props) {
|
|
|
9764
9752
|
)}`,
|
|
9765
9753
|
onPointerDown
|
|
9766
9754
|
},
|
|
9767
|
-
/* @__PURE__ */
|
|
9755
|
+
/* @__PURE__ */ React43.createElement(
|
|
9768
9756
|
"div",
|
|
9769
9757
|
{
|
|
9770
9758
|
style: __spreadValues(__spreadValues({}, style2), props.style),
|
|
@@ -9775,7 +9763,7 @@ function GroupResizeHandleFn(props) {
|
|
|
9775
9763
|
)
|
|
9776
9764
|
);
|
|
9777
9765
|
}
|
|
9778
|
-
var GroupResizeHandle =
|
|
9766
|
+
var GroupResizeHandle = React43.memo(
|
|
9779
9767
|
GroupResizeHandleFn
|
|
9780
9768
|
);
|
|
9781
9769
|
|
|
@@ -9834,7 +9822,7 @@ function useColumnGroupResizeHandle(groupColumns, config) {
|
|
|
9834
9822
|
[computeResizeForDiff]
|
|
9835
9823
|
);
|
|
9836
9824
|
const groupResizable = groupColumns.some((c) => c.computedResizable);
|
|
9837
|
-
const resizeHandle = groupResizable ? /* @__PURE__ */
|
|
9825
|
+
const resizeHandle = groupResizable ? /* @__PURE__ */ React44.createElement(
|
|
9838
9826
|
GroupResizeHandle,
|
|
9839
9827
|
{
|
|
9840
9828
|
brain: bodyBrain,
|
|
@@ -9874,7 +9862,7 @@ function InfiniteTableHeaderGroup(props) {
|
|
|
9874
9862
|
(col) => `var(${columnWidthAtIndex5}-${col.computedVisibleIndex})`
|
|
9875
9863
|
).join(" + ") + " )" : `var(${columnWidthAtIndex5}-${firstColumn.computedVisibleIndex})`;
|
|
9876
9864
|
const zIndex2 = `calc(var(${columnZIndexAtIndex6}-${firstColumn.computedVisibleIndex}) + ${columnGroupsMaxDepth - columnGroup.depth})`;
|
|
9877
|
-
return /* @__PURE__ */
|
|
9865
|
+
return /* @__PURE__ */ React45.createElement(
|
|
9878
9866
|
"div",
|
|
9879
9867
|
{
|
|
9880
9868
|
ref: props.domRef,
|
|
@@ -9883,7 +9871,7 @@ function InfiniteTableHeaderGroup(props) {
|
|
|
9883
9871
|
style: { width, height },
|
|
9884
9872
|
"data-z-index": zIndex2
|
|
9885
9873
|
},
|
|
9886
|
-
/* @__PURE__ */
|
|
9874
|
+
/* @__PURE__ */ React45.createElement(
|
|
9887
9875
|
"div",
|
|
9888
9876
|
{
|
|
9889
9877
|
className: join(
|
|
@@ -9965,7 +9953,7 @@ function InfiniteTableHeaderFn(props) {
|
|
|
9965
9953
|
computedWidth: colGroupItem.computedWidth,
|
|
9966
9954
|
groupOffset: colGroupItem.groupOffset
|
|
9967
9955
|
});
|
|
9968
|
-
return /* @__PURE__ */
|
|
9956
|
+
return /* @__PURE__ */ React46.createElement(
|
|
9969
9957
|
InfiniteTableHeaderGroup,
|
|
9970
9958
|
{
|
|
9971
9959
|
bodyBrain,
|
|
@@ -9978,7 +9966,7 @@ function InfiniteTableHeaderFn(props) {
|
|
|
9978
9966
|
}
|
|
9979
9967
|
);
|
|
9980
9968
|
}
|
|
9981
|
-
return /* @__PURE__ */
|
|
9969
|
+
return /* @__PURE__ */ React46.createElement(
|
|
9982
9970
|
InfiniteTableHeaderCell,
|
|
9983
9971
|
{
|
|
9984
9972
|
domRef: domRef2,
|
|
@@ -10002,7 +9990,7 @@ function InfiniteTableHeaderFn(props) {
|
|
|
10002
9990
|
showColumnFilters
|
|
10003
9991
|
]
|
|
10004
9992
|
);
|
|
10005
|
-
return /* @__PURE__ */
|
|
9993
|
+
return /* @__PURE__ */ React46.createElement("div", __spreadValues({}, domProps), /* @__PURE__ */ React46.createElement(
|
|
10006
9994
|
RawTable,
|
|
10007
9995
|
{
|
|
10008
9996
|
name: "header",
|
|
@@ -10012,7 +10000,7 @@ function InfiniteTableHeaderFn(props) {
|
|
|
10012
10000
|
}
|
|
10013
10001
|
));
|
|
10014
10002
|
}
|
|
10015
|
-
var InfiniteTableHeader =
|
|
10003
|
+
var InfiniteTableHeader = React46.memo(
|
|
10016
10004
|
InfiniteTableHeaderFn
|
|
10017
10005
|
);
|
|
10018
10006
|
|
|
@@ -10037,7 +10025,7 @@ function TableHeaderWrapper(props) {
|
|
|
10037
10025
|
} = tableContextValue;
|
|
10038
10026
|
const rows = !computedColumnGroups || !Object.keys(computedColumnGroups).length ? 1 : columnGroupsMaxDepth + 2;
|
|
10039
10027
|
const height = rows * columnHeaderHeight + (showColumnFilters ? columnHeaderHeight : 0);
|
|
10040
|
-
const columnAndGroupTreeInfo =
|
|
10028
|
+
const columnAndGroupTreeInfo = React47.useMemo(() => {
|
|
10041
10029
|
if (!computedColumnGroups || !Object.keys(computedColumnGroups).length) {
|
|
10042
10030
|
return void 0;
|
|
10043
10031
|
}
|
|
@@ -10048,7 +10036,7 @@ function TableHeaderWrapper(props) {
|
|
|
10048
10036
|
columnGroupsMaxDepth
|
|
10049
10037
|
);
|
|
10050
10038
|
}, [computedVisibleColumns, computedColumnGroups, columnGroupsDepthsMap]);
|
|
10051
|
-
const cellspan =
|
|
10039
|
+
const cellspan = React47.useCallback(
|
|
10052
10040
|
({ rowIndex, colIndex }) => {
|
|
10053
10041
|
const column = computedVisibleColumns[colIndex];
|
|
10054
10042
|
const rowspan2 = 1;
|
|
@@ -10086,15 +10074,15 @@ function TableHeaderWrapper(props) {
|
|
|
10086
10074
|
columnGroupsDepthsMap
|
|
10087
10075
|
]
|
|
10088
10076
|
);
|
|
10089
|
-
const rowspan =
|
|
10077
|
+
const rowspan = React47.useCallback(
|
|
10090
10078
|
({ rowIndex, colIndex }) => cellspan({ rowIndex, colIndex }).rowspan,
|
|
10091
10079
|
[cellspan]
|
|
10092
10080
|
);
|
|
10093
|
-
const colspan =
|
|
10081
|
+
const colspan = React47.useCallback(
|
|
10094
10082
|
({ rowIndex, colIndex }) => cellspan({ rowIndex, colIndex }).colspan,
|
|
10095
10083
|
[cellspan]
|
|
10096
10084
|
);
|
|
10097
|
-
const rowHeight =
|
|
10085
|
+
const rowHeight = React47.useCallback(
|
|
10098
10086
|
(index) => {
|
|
10099
10087
|
return showColumnFilters ? index < rows - 1 ? columnHeaderHeight : 2 * columnHeaderHeight : columnHeaderHeight;
|
|
10100
10088
|
},
|
|
@@ -10116,7 +10104,7 @@ function TableHeaderWrapper(props) {
|
|
|
10116
10104
|
fixedColsStart: computedPinnedStartColumns.length
|
|
10117
10105
|
}
|
|
10118
10106
|
);
|
|
10119
|
-
const header = /* @__PURE__ */
|
|
10107
|
+
const header = /* @__PURE__ */ React47.createElement(
|
|
10120
10108
|
InfiniteTableHeader,
|
|
10121
10109
|
{
|
|
10122
10110
|
columns: computedVisibleColumns,
|
|
@@ -10127,7 +10115,7 @@ function TableHeaderWrapper(props) {
|
|
|
10127
10115
|
columnAndGroupTreeInfo
|
|
10128
10116
|
}
|
|
10129
10117
|
);
|
|
10130
|
-
const verticalScrollbarPlaceholder = scrollbars.vertical && getScrollbarWidth() ? /* @__PURE__ */
|
|
10118
|
+
const verticalScrollbarPlaceholder = scrollbars.vertical && getScrollbarWidth() ? /* @__PURE__ */ React47.createElement(
|
|
10131
10119
|
"div",
|
|
10132
10120
|
{
|
|
10133
10121
|
className: HeaderScrollbarPlaceholderCls,
|
|
@@ -10137,7 +10125,7 @@ function TableHeaderWrapper(props) {
|
|
|
10137
10125
|
}
|
|
10138
10126
|
}
|
|
10139
10127
|
) : null;
|
|
10140
|
-
return /* @__PURE__ */
|
|
10128
|
+
return /* @__PURE__ */ React47.createElement(
|
|
10141
10129
|
"div",
|
|
10142
10130
|
{
|
|
10143
10131
|
className: HeaderWrapperCls,
|
|
@@ -10151,7 +10139,7 @@ function TableHeaderWrapper(props) {
|
|
|
10151
10139
|
}
|
|
10152
10140
|
|
|
10153
10141
|
// src/components/InfiniteTable/components/InfiniteTableLicenseFooter/index.tsx
|
|
10154
|
-
import * as
|
|
10142
|
+
import * as React48 from "react";
|
|
10155
10143
|
import { useEffect as useEffect17 } from "react";
|
|
10156
10144
|
|
|
10157
10145
|
// src/components/utils/decamelize.ts
|
|
@@ -10194,11 +10182,11 @@ var enforceStyle = (node, style2) => {
|
|
|
10194
10182
|
);
|
|
10195
10183
|
}
|
|
10196
10184
|
};
|
|
10197
|
-
var InfiniteTableLicenseFooter =
|
|
10185
|
+
var InfiniteTableLicenseFooter = React48.forwardRef(
|
|
10198
10186
|
function InfiniteTableLicenseFooter2(props, ref) {
|
|
10199
10187
|
const { rootClassName: rootClassName12 } = useInternalProps();
|
|
10200
|
-
const domRef =
|
|
10201
|
-
const domCallback =
|
|
10188
|
+
const domRef = React48.useRef(null);
|
|
10189
|
+
const domCallback = React48.useCallback((node) => {
|
|
10202
10190
|
domRef.current = node;
|
|
10203
10191
|
if (!ref) {
|
|
10204
10192
|
return;
|
|
@@ -10226,7 +10214,7 @@ var InfiniteTableLicenseFooter = React49.forwardRef(
|
|
|
10226
10214
|
clearInterval(intervalId);
|
|
10227
10215
|
};
|
|
10228
10216
|
}, []);
|
|
10229
|
-
return /* @__PURE__ */
|
|
10217
|
+
return /* @__PURE__ */ React48.createElement(
|
|
10230
10218
|
"div",
|
|
10231
10219
|
__spreadProps(__spreadValues({
|
|
10232
10220
|
ref: domCallback
|
|
@@ -10240,7 +10228,7 @@ var InfiniteTableLicenseFooter = React49.forwardRef(
|
|
|
10240
10228
|
}),
|
|
10241
10229
|
"Powered by",
|
|
10242
10230
|
" ",
|
|
10243
|
-
/* @__PURE__ */
|
|
10231
|
+
/* @__PURE__ */ React48.createElement(
|
|
10244
10232
|
"a",
|
|
10245
10233
|
{
|
|
10246
10234
|
href: "https://infinite-table.com",
|
|
@@ -10255,7 +10243,7 @@ var InfiniteTableLicenseFooter = React49.forwardRef(
|
|
|
10255
10243
|
);
|
|
10256
10244
|
|
|
10257
10245
|
// src/components/InfiniteTable/components/LoadMask.tsx
|
|
10258
|
-
import * as
|
|
10246
|
+
import * as React49 from "react";
|
|
10259
10247
|
|
|
10260
10248
|
// src/components/InfiniteTable/components/LoadMask.css.ts
|
|
10261
10249
|
var LoadMaskCls = { visible: "LoadMask_LoadMaskCls_visible__qy58ya1 LoadMask_LoadMaskBaseCls__qy58ya0 utilities_position_absolute__16lm1iw2 utilities_top_0__16lm1iw1c utilities_left_0__16lm1iw1e utilities_right_0__16lm1iw1j utilities_bottom_0__16lm1iw1h", hidden: "LoadMask_LoadMaskCls_hidden__qy58ya2 LoadMask_LoadMaskBaseCls__qy58ya0 utilities_position_absolute__16lm1iw2 utilities_top_0__16lm1iw1c utilities_left_0__16lm1iw1e utilities_right_0__16lm1iw1j utilities_bottom_0__16lm1iw1h" };
|
|
@@ -10267,16 +10255,16 @@ var { rootClassName: rootClassName10 } = internalProps;
|
|
|
10267
10255
|
var baseCls3 = `${rootClassName10}-LoadMask`;
|
|
10268
10256
|
function LoadMaskFn(props) {
|
|
10269
10257
|
const { visible, children = "Loading" } = props;
|
|
10270
|
-
return /* @__PURE__ */
|
|
10258
|
+
return /* @__PURE__ */ React49.createElement(
|
|
10271
10259
|
"div",
|
|
10272
10260
|
{
|
|
10273
10261
|
className: `${LoadMaskCls[visible ? "visible" : "hidden"]} ${baseCls3}`
|
|
10274
10262
|
},
|
|
10275
|
-
/* @__PURE__ */
|
|
10276
|
-
/* @__PURE__ */
|
|
10263
|
+
/* @__PURE__ */ React49.createElement("div", { className: `${LoadMaskOverlayCls} ${baseCls3}-Overlay` }),
|
|
10264
|
+
/* @__PURE__ */ React49.createElement("div", { className: `${LoadMaskTextCls} ${baseCls3}-Text` }, children)
|
|
10277
10265
|
);
|
|
10278
10266
|
}
|
|
10279
|
-
var LoadMask =
|
|
10267
|
+
var LoadMask = React49.memo(LoadMaskFn);
|
|
10280
10268
|
|
|
10281
10269
|
// src/utils/deepClone.ts
|
|
10282
10270
|
function cloneArray(arr) {
|
|
@@ -10948,7 +10936,7 @@ function enhancedFlatten(param) {
|
|
|
10948
10936
|
}
|
|
10949
10937
|
|
|
10950
10938
|
// src/components/DataSource/index.tsx
|
|
10951
|
-
import * as
|
|
10939
|
+
import * as React50 from "react";
|
|
10952
10940
|
import { useEffect as useEffect20, useLayoutEffect as useLayoutEffect10 } from "react";
|
|
10953
10941
|
|
|
10954
10942
|
// src/utils/multisort/sortTypes.ts
|
|
@@ -14945,7 +14933,7 @@ function DataSourceWithContext(props) {
|
|
|
14945
14933
|
var _a;
|
|
14946
14934
|
(_a = componentState.onReady) == null ? void 0 : _a.call(componentState, api);
|
|
14947
14935
|
}, []);
|
|
14948
|
-
return /* @__PURE__ */
|
|
14936
|
+
return /* @__PURE__ */ React50.createElement(React50.Fragment, null, children);
|
|
14949
14937
|
}
|
|
14950
14938
|
var DataSourceRoot = getComponentStateRoot({
|
|
14951
14939
|
//@ts-ignore
|
|
@@ -14975,7 +14963,7 @@ function DataSourceCmp({
|
|
|
14975
14963
|
const { componentState, componentActions, assignState } = useComponentState();
|
|
14976
14964
|
componentState.getDataSourceMasterContextRef.current = getDataSourceMasterContext;
|
|
14977
14965
|
const getState = useLatest(componentState);
|
|
14978
|
-
const [api] =
|
|
14966
|
+
const [api] = React50.useState(() => {
|
|
14979
14967
|
return getDataSourceApi({ getState, actions: componentActions });
|
|
14980
14968
|
});
|
|
14981
14969
|
const contextValue = {
|
|
@@ -15027,13 +15015,13 @@ function DataSourceCmp({
|
|
|
15027
15015
|
});
|
|
15028
15016
|
}
|
|
15029
15017
|
}, [componentState.originalDataArrayChangedInfo]);
|
|
15030
|
-
return /* @__PURE__ */
|
|
15018
|
+
return /* @__PURE__ */ React50.createElement(DataSourceContext.Provider, { value: contextValue }, /* @__PURE__ */ React50.createElement(DataSourceWithContext, { children }));
|
|
15031
15019
|
}
|
|
15032
15020
|
function DataSource(props) {
|
|
15033
15021
|
const masterContext = useMasterDetailContext();
|
|
15034
15022
|
const isDetail = !!masterContext;
|
|
15035
15023
|
const key = isDetail ? masterContext.masterRowInfo.id : "master";
|
|
15036
|
-
return /* @__PURE__ */
|
|
15024
|
+
return /* @__PURE__ */ React50.createElement(DataSourceRoot, __spreadProps(__spreadValues({}, props), { key }), /* @__PURE__ */ React50.createElement(DataSourceCmp, { children: props.children, isDetail }));
|
|
15037
15025
|
}
|
|
15038
15026
|
function useRowInfoReducers() {
|
|
15039
15027
|
const { rowInfoReducerResults } = useDataSource();
|
|
@@ -15355,7 +15343,8 @@ function getRowDetailApi(param) {
|
|
|
15355
15343
|
return !rowDetailApi.isRowDetailCollapsed(pk);
|
|
15356
15344
|
},
|
|
15357
15345
|
collapseRowDetail(pk) {
|
|
15358
|
-
const
|
|
15346
|
+
const componentState = getState();
|
|
15347
|
+
const currentState = componentState.rowDetailState;
|
|
15359
15348
|
if (!currentState) {
|
|
15360
15349
|
console.error(
|
|
15361
15350
|
`Cannot collapse row details via rowDetailState, as no props.rowDetailState is provided.`
|
|
@@ -15364,10 +15353,13 @@ function getRowDetailApi(param) {
|
|
|
15364
15353
|
}
|
|
15365
15354
|
const state = new RowDetailState(currentState);
|
|
15366
15355
|
state.collapseRowDetails(pk);
|
|
15356
|
+
componentState.lastRowToExpandRef.current = null;
|
|
15357
|
+
componentState.lastRowToCollapseRef.current = pk;
|
|
15367
15358
|
actions.rowDetailState = state;
|
|
15368
15359
|
},
|
|
15369
15360
|
expandRowDetail(pk) {
|
|
15370
|
-
const
|
|
15361
|
+
const componentState = getState();
|
|
15362
|
+
const currentState = componentState.rowDetailState;
|
|
15371
15363
|
if (!currentState) {
|
|
15372
15364
|
console.error(
|
|
15373
15365
|
`Cannot expand row details via rowDetailState, as no props.rowDetailState is provided.`
|
|
@@ -15376,6 +15368,8 @@ function getRowDetailApi(param) {
|
|
|
15376
15368
|
}
|
|
15377
15369
|
const state = new RowDetailState(currentState);
|
|
15378
15370
|
state.expandRowDetails(pk);
|
|
15371
|
+
componentState.lastRowToCollapseRef.current = null;
|
|
15372
|
+
componentState.lastRowToExpandRef.current = pk;
|
|
15379
15373
|
actions.rowDetailState = state;
|
|
15380
15374
|
},
|
|
15381
15375
|
toggleRowDetail(pk) {
|
|
@@ -16408,7 +16402,7 @@ function useAutoSizeColumns() {
|
|
|
16408
16402
|
// src/components/InfiniteTable/hooks/useCellRendering.tsx
|
|
16409
16403
|
import { useMemo as useMemo9 } from "react";
|
|
16410
16404
|
import { useCallback as useCallback19, useEffect as useEffect22, useRef as useRef24 } from "react";
|
|
16411
|
-
import * as
|
|
16405
|
+
import * as React52 from "react";
|
|
16412
16406
|
|
|
16413
16407
|
// src/components/InfiniteTable/hooks/useYourBrain.ts
|
|
16414
16408
|
function useYourBrain(param) {
|
|
@@ -16445,7 +16439,7 @@ function useYourBrain(param) {
|
|
|
16445
16439
|
}
|
|
16446
16440
|
|
|
16447
16441
|
// src/components/InfiniteTable/components/InfiniteTableRow/InfiniteTableDetailRow.tsx
|
|
16448
|
-
import * as
|
|
16442
|
+
import * as React51 from "react";
|
|
16449
16443
|
|
|
16450
16444
|
// src/components/InfiniteTable/components/rowDetail.css.ts
|
|
16451
16445
|
var RowDetailRecipe = createRuntimeFn({ defaultClassName: "rowDetail_RowDetailRecipe__evqes20", variantClassNames: {}, defaultVariants: {}, compoundVariants: [] });
|
|
@@ -16582,7 +16576,7 @@ function InfiniteTableDetailRowFn(props) {
|
|
|
16582
16576
|
rowDetailsCache,
|
|
16583
16577
|
rowInfo
|
|
16584
16578
|
});
|
|
16585
|
-
return /* @__PURE__ */
|
|
16579
|
+
return /* @__PURE__ */ React51.createElement(DataSourceMasterDetailContext.Provider, { value: masterDetailContextValue }, /* @__PURE__ */ React51.createElement(
|
|
16586
16580
|
"div",
|
|
16587
16581
|
{
|
|
16588
16582
|
ref: domRef,
|
|
@@ -16591,6 +16585,7 @@ function InfiniteTableDetailRowFn(props) {
|
|
|
16591
16585
|
position: "absolute",
|
|
16592
16586
|
top: `${detailOffset}px`,
|
|
16593
16587
|
left: 0,
|
|
16588
|
+
// TODO see #rowDetailWidth
|
|
16594
16589
|
width: `calc(${InternalVars.bodyWidth} - ${InternalVars.scrollbarWidthVertical})`,
|
|
16595
16590
|
height: rowDetailHeight
|
|
16596
16591
|
}
|
|
@@ -16598,7 +16593,7 @@ function InfiniteTableDetailRowFn(props) {
|
|
|
16598
16593
|
rowDetailRenderer(rowInfo, currentRowCache)
|
|
16599
16594
|
));
|
|
16600
16595
|
}
|
|
16601
|
-
var InfiniteTableDetailRow =
|
|
16596
|
+
var InfiniteTableDetailRow = React51.memo(
|
|
16602
16597
|
InfiniteTableDetailRowFn
|
|
16603
16598
|
);
|
|
16604
16599
|
|
|
@@ -16757,7 +16752,7 @@ function useCellRendering(param) {
|
|
|
16757
16752
|
cellStyle,
|
|
16758
16753
|
cellClassName
|
|
16759
16754
|
};
|
|
16760
|
-
return /* @__PURE__ */
|
|
16755
|
+
return /* @__PURE__ */ React52.createElement(InfiniteTableColumnCell, __spreadValues({}, cellProps));
|
|
16761
16756
|
},
|
|
16762
16757
|
[
|
|
16763
16758
|
rowHeight,
|
|
@@ -16788,10 +16783,10 @@ function useCellRendering(param) {
|
|
|
16788
16783
|
const dataArray2 = getData();
|
|
16789
16784
|
const rowInfo = dataArray2[rowIndex];
|
|
16790
16785
|
if (!rowInfo || !isRowDetailsExpanded(rowInfo) || !computedRowSizeCacheForDetails) {
|
|
16791
|
-
return /* @__PURE__ */
|
|
16786
|
+
return /* @__PURE__ */ React52.createElement("div", { ref: domRef, className: visibility.hidden });
|
|
16792
16787
|
}
|
|
16793
16788
|
const { rowDetailHeight: rowDetailHeight2, rowHeight: rowHeight2 } = computedRowSizeCacheForDetails.getSize(rowIndex);
|
|
16794
|
-
return /* @__PURE__ */
|
|
16789
|
+
return /* @__PURE__ */ React52.createElement(
|
|
16795
16790
|
InfiniteTableDetailRow,
|
|
16796
16791
|
{
|
|
16797
16792
|
rowInfo,
|
|
@@ -17124,10 +17119,10 @@ function computeColumnGroupsDepths(columnGroups) {
|
|
|
17124
17119
|
}
|
|
17125
17120
|
|
|
17126
17121
|
// src/components/InfiniteTable/state/rowDetailRendererFromComponent.tsx
|
|
17127
|
-
import * as
|
|
17122
|
+
import * as React53 from "react";
|
|
17128
17123
|
function getRowDetailRendererFromComponent(RowDetail) {
|
|
17129
17124
|
return (rowInfo, cache) => {
|
|
17130
|
-
return /* @__PURE__ */
|
|
17125
|
+
return /* @__PURE__ */ React53.createElement(RowDetail, { key: rowInfo.id, rowInfo, cache });
|
|
17131
17126
|
};
|
|
17132
17127
|
}
|
|
17133
17128
|
|
|
@@ -17176,6 +17171,8 @@ function initSetupState2({
|
|
|
17176
17171
|
renderer,
|
|
17177
17172
|
onRenderUpdater,
|
|
17178
17173
|
propsCache: /* @__PURE__ */ new Map([]),
|
|
17174
|
+
lastRowToCollapseRef: { current: null },
|
|
17175
|
+
lastRowToExpandRef: { current: null },
|
|
17179
17176
|
cellContextMenuVisibleFor: null,
|
|
17180
17177
|
contextMenuVisibleFor: null,
|
|
17181
17178
|
columnMenuVisibleForColumnId: null,
|
|
@@ -17376,6 +17373,21 @@ function getGroupByMap(groupBy) {
|
|
|
17376
17373
|
}, /* @__PURE__ */ new Map());
|
|
17377
17374
|
}
|
|
17378
17375
|
var weakMap2 = /* @__PURE__ */ new WeakMap();
|
|
17376
|
+
function getMappedCallbacks2() {
|
|
17377
|
+
return {
|
|
17378
|
+
rowDetailState: (rowDetailState, state) => {
|
|
17379
|
+
return {
|
|
17380
|
+
callbackParams: [
|
|
17381
|
+
rowDetailState,
|
|
17382
|
+
{
|
|
17383
|
+
expandRow: state.lastRowToExpandRef.current,
|
|
17384
|
+
collapseRow: state.lastRowToCollapseRef.current
|
|
17385
|
+
}
|
|
17386
|
+
]
|
|
17387
|
+
};
|
|
17388
|
+
}
|
|
17389
|
+
};
|
|
17390
|
+
}
|
|
17379
17391
|
var mapPropsToState = (params) => {
|
|
17380
17392
|
var _a, _b, _c, _d, _e;
|
|
17381
17393
|
const { props, state, oldState, parentState } = params;
|
|
@@ -18593,7 +18605,7 @@ var useLicense = (licenseKey = "") => {
|
|
|
18593
18605
|
}
|
|
18594
18606
|
let valid2 = isValidLicense(licenseKey, {
|
|
18595
18607
|
publishedAt: 1624970570587,
|
|
18596
|
-
version: "4.
|
|
18608
|
+
version: "4.1.0"
|
|
18597
18609
|
});
|
|
18598
18610
|
if (!licenseKey && !valid2 && isInsidePlayground) {
|
|
18599
18611
|
return true;
|
|
@@ -19632,7 +19644,7 @@ function useDOMEventHandlers() {
|
|
|
19632
19644
|
import { useEffect as useEffect32 } from "react";
|
|
19633
19645
|
|
|
19634
19646
|
// src/components/hooks/useOverlay/index.tsx
|
|
19635
|
-
import * as
|
|
19647
|
+
import * as React54 from "react";
|
|
19636
19648
|
import {
|
|
19637
19649
|
useCallback as useCallback23,
|
|
19638
19650
|
useEffect as useEffect30,
|
|
@@ -20023,10 +20035,10 @@ function retrieveElement(elementGetter) {
|
|
|
20023
20035
|
});
|
|
20024
20036
|
}
|
|
20025
20037
|
function DefaultOverlayPortal(props) {
|
|
20026
|
-
return /* @__PURE__ */
|
|
20038
|
+
return /* @__PURE__ */ React54.createElement("div", { style: { position: "fixed", top: 0, left: 0 } }, props.children);
|
|
20027
20039
|
}
|
|
20028
20040
|
function OverlayContent(props) {
|
|
20029
|
-
const nodeRef =
|
|
20041
|
+
const nodeRef = React54.useRef(null);
|
|
20030
20042
|
useEffect30(() => {
|
|
20031
20043
|
return props.realign.onChange((handle) => {
|
|
20032
20044
|
if (nodeRef.current && handle) {
|
|
@@ -20034,7 +20046,7 @@ function OverlayContent(props) {
|
|
|
20034
20046
|
}
|
|
20035
20047
|
});
|
|
20036
20048
|
}, [props.realign]);
|
|
20037
|
-
return /* @__PURE__ */
|
|
20049
|
+
return /* @__PURE__ */ React54.createElement(
|
|
20038
20050
|
"div",
|
|
20039
20051
|
{
|
|
20040
20052
|
style: { position: "absolute", top: 0, left: 0 },
|
|
@@ -20105,22 +20117,22 @@ function useOverlayPortal(content, portalContainer) {
|
|
|
20105
20117
|
}, [portalContainer]);
|
|
20106
20118
|
return portalContainer ? container ? createPortal2(content, container) : (
|
|
20107
20119
|
// we're probably still fetching the container
|
|
20108
|
-
/* @__PURE__ */
|
|
20109
|
-
) : portalContainer === null || portalContainer === false ? content : /* @__PURE__ */
|
|
20120
|
+
/* @__PURE__ */ React54.createElement(React54.Fragment, null)
|
|
20121
|
+
) : portalContainer === null || portalContainer === false ? content : /* @__PURE__ */ React54.createElement(DefaultOverlayPortal, null, content);
|
|
20110
20122
|
}
|
|
20111
20123
|
function getIdForReactOnlyChild(children) {
|
|
20112
|
-
if (
|
|
20113
|
-
const child =
|
|
20114
|
-
if (
|
|
20124
|
+
if (React54.Children.count(children) === 1) {
|
|
20125
|
+
const child = React54.Children.only(children);
|
|
20126
|
+
if (React54.isValidElement(child)) {
|
|
20115
20127
|
return child.props.id || child.key;
|
|
20116
20128
|
}
|
|
20117
20129
|
}
|
|
20118
20130
|
return null;
|
|
20119
20131
|
}
|
|
20120
20132
|
function injectPortalContainerAndConstrainInMenuChild(children, portalContainer, constrainTo) {
|
|
20121
|
-
if (
|
|
20122
|
-
const child =
|
|
20123
|
-
if (
|
|
20133
|
+
if (React54.Children.count(children) === 1) {
|
|
20134
|
+
const child = React54.Children.only(children);
|
|
20135
|
+
if (React54.isValidElement(child) && child.type[propToIdentifyMenu]) {
|
|
20124
20136
|
const newProps = {};
|
|
20125
20137
|
if (child.props.portalContainer === void 0) {
|
|
20126
20138
|
newProps.portalContainer = portalContainer;
|
|
@@ -20128,7 +20140,7 @@ function injectPortalContainerAndConstrainInMenuChild(children, portalContainer,
|
|
|
20128
20140
|
if (child.props.constrainTo === void 0) {
|
|
20129
20141
|
newProps.constrainTo = constrainTo;
|
|
20130
20142
|
}
|
|
20131
|
-
return
|
|
20143
|
+
return React54.cloneElement(child, newProps);
|
|
20132
20144
|
}
|
|
20133
20145
|
}
|
|
20134
20146
|
return children;
|
|
@@ -20144,7 +20156,7 @@ function useOverlay(params) {
|
|
|
20144
20156
|
const contentForPortal = [];
|
|
20145
20157
|
for (const [_2, handle] of handles) {
|
|
20146
20158
|
contentForPortal.push(
|
|
20147
|
-
/* @__PURE__ */
|
|
20159
|
+
/* @__PURE__ */ React54.createElement(OverlayContent, __spreadProps(__spreadValues({}, handle), { key: handle.key }))
|
|
20148
20160
|
);
|
|
20149
20161
|
}
|
|
20150
20162
|
return contentForPortal;
|
|
@@ -20189,7 +20201,7 @@ function useOverlay(params) {
|
|
|
20189
20201
|
},
|
|
20190
20202
|
[handles, rootParams.portalContainer, updateContent]
|
|
20191
20203
|
);
|
|
20192
|
-
|
|
20204
|
+
React54.useEffect(() => {
|
|
20193
20205
|
if (handleToRealign) {
|
|
20194
20206
|
const handle = handles.get(handleToRealign);
|
|
20195
20207
|
if (handle) {
|
|
@@ -20208,7 +20220,7 @@ function useOverlay(params) {
|
|
|
20208
20220
|
handles.clear();
|
|
20209
20221
|
updateContent();
|
|
20210
20222
|
};
|
|
20211
|
-
|
|
20223
|
+
React54.useEffect(() => {
|
|
20212
20224
|
}, []);
|
|
20213
20225
|
return {
|
|
20214
20226
|
portal,
|
|
@@ -20220,16 +20232,16 @@ function useOverlay(params) {
|
|
|
20220
20232
|
}
|
|
20221
20233
|
|
|
20222
20234
|
// src/components/InfiniteTable/utils/getMenuForColumn.tsx
|
|
20223
|
-
import * as
|
|
20235
|
+
import * as React60 from "react";
|
|
20224
20236
|
|
|
20225
20237
|
// src/components/Menu/index.tsx
|
|
20226
|
-
import * as
|
|
20238
|
+
import * as React58 from "react";
|
|
20227
20239
|
|
|
20228
20240
|
// src/components/Menu/getMenuState.tsx
|
|
20229
|
-
import * as
|
|
20241
|
+
import * as React56 from "react";
|
|
20230
20242
|
|
|
20231
20243
|
// src/components/Menu/childrenToRuntimeItems.tsx
|
|
20232
|
-
import * as
|
|
20244
|
+
import * as React55 from "react";
|
|
20233
20245
|
|
|
20234
20246
|
// src/components/Menu/MenuItem.tsx
|
|
20235
20247
|
function MenuItem(_props) {
|
|
@@ -20248,7 +20260,7 @@ var MenuSeparatorCls = "MenuCls_MenuSeparatorCls__db3arfd";
|
|
|
20248
20260
|
// src/components/Menu/childrenToRuntimeItems.tsx
|
|
20249
20261
|
var SEPARATOR = "-";
|
|
20250
20262
|
function MenuSeparator() {
|
|
20251
|
-
return /* @__PURE__ */
|
|
20263
|
+
return /* @__PURE__ */ React55.createElement("hr", { className: MenuSeparatorCls });
|
|
20252
20264
|
}
|
|
20253
20265
|
var toRuntimeItem = ({
|
|
20254
20266
|
columns,
|
|
@@ -20257,7 +20269,7 @@ var toRuntimeItem = ({
|
|
|
20257
20269
|
menuId
|
|
20258
20270
|
}, item) => {
|
|
20259
20271
|
const menuItem = item && (item.key != null || item.label != null) ? item : null;
|
|
20260
|
-
const menuDecoration = menuItem === null ? item === SEPARATOR ? /* @__PURE__ */
|
|
20272
|
+
const menuDecoration = menuItem === null ? item === SEPARATOR ? /* @__PURE__ */ React55.createElement(MenuSeparator, null) : item : null;
|
|
20261
20273
|
const runtimeItem = menuItem != null ? {
|
|
20262
20274
|
type: "item",
|
|
20263
20275
|
parentMenuId: menuId,
|
|
@@ -20285,7 +20297,7 @@ var toRuntimeItem = ({
|
|
|
20285
20297
|
return runtimeItem;
|
|
20286
20298
|
};
|
|
20287
20299
|
function childrenToRuntimeItems(context, children) {
|
|
20288
|
-
return
|
|
20300
|
+
return React55.Children.map(children, (child) => {
|
|
20289
20301
|
if (child) {
|
|
20290
20302
|
if (child.props.__is_menu_item || child.type === MenuItem) {
|
|
20291
20303
|
const itemProps = __spreadValues({}, child.props);
|
|
@@ -20308,7 +20320,7 @@ function childrenToRuntimeItems(context, children) {
|
|
|
20308
20320
|
// src/components/Menu/getMenuState.tsx
|
|
20309
20321
|
var SUBMENU_COL_NAME = "submenu";
|
|
20310
20322
|
function getInitialMenuState() {
|
|
20311
|
-
const domRef =
|
|
20323
|
+
const domRef = React56.createRef();
|
|
20312
20324
|
return {
|
|
20313
20325
|
keyboardActiveItemKey: null,
|
|
20314
20326
|
activeItemKey: null,
|
|
@@ -20363,7 +20375,7 @@ var deriveStateFromProps2 = (params) => {
|
|
|
20363
20375
|
columns.push({
|
|
20364
20376
|
name: SUBMENU_COL_NAME,
|
|
20365
20377
|
render: ({ domProps, item }) => {
|
|
20366
|
-
return item.menu ? /* @__PURE__ */
|
|
20378
|
+
return item.menu ? /* @__PURE__ */ React56.createElement("div", __spreadValues({}, domProps), /* @__PURE__ */ React56.createElement(ExpanderIcon, { expanded: false })) : /* @__PURE__ */ React56.createElement("div", __spreadValues({}, domProps));
|
|
20367
20379
|
}
|
|
20368
20380
|
});
|
|
20369
20381
|
}
|
|
@@ -20380,7 +20392,7 @@ var deriveStateFromProps2 = (params) => {
|
|
|
20380
20392
|
};
|
|
20381
20393
|
|
|
20382
20394
|
// src/components/Menu/Menu.tsx
|
|
20383
|
-
import * as
|
|
20395
|
+
import * as React57 from "react";
|
|
20384
20396
|
import {
|
|
20385
20397
|
useCallback as useCallback25,
|
|
20386
20398
|
useLayoutEffect as useLayoutEffect14,
|
|
@@ -20645,7 +20657,7 @@ function renderSubmenuForItem(item, config) {
|
|
|
20645
20657
|
if (typeof itemMenu === "function") {
|
|
20646
20658
|
itemMenu = itemMenu();
|
|
20647
20659
|
}
|
|
20648
|
-
return /* @__PURE__ */
|
|
20660
|
+
return /* @__PURE__ */ React57.createElement(
|
|
20649
20661
|
Menu,
|
|
20650
20662
|
__spreadProps(__spreadValues({
|
|
20651
20663
|
key: overlayId,
|
|
@@ -20858,7 +20870,7 @@ function MenuComponent(props) {
|
|
|
20858
20870
|
setActiveItemKey(key);
|
|
20859
20871
|
}
|
|
20860
20872
|
});
|
|
20861
|
-
renderedChildren = runtimeItems.map((runtimeItem, index) => /* @__PURE__ */
|
|
20873
|
+
renderedChildren = runtimeItems.map((runtimeItem, index) => /* @__PURE__ */ React57.createElement(
|
|
20862
20874
|
RuntimeItemRenderer,
|
|
20863
20875
|
{
|
|
20864
20876
|
key: runtimeItem.type === "item" ? runtimeItem.key : index,
|
|
@@ -21043,7 +21055,7 @@ function MenuComponent(props) {
|
|
|
21043
21055
|
domRef.current = node;
|
|
21044
21056
|
}
|
|
21045
21057
|
}, []);
|
|
21046
|
-
const result = /* @__PURE__ */
|
|
21058
|
+
const result = /* @__PURE__ */ React57.createElement("div", { className: display.contents }, /* @__PURE__ */ React57.createElement(
|
|
21047
21059
|
"div",
|
|
21048
21060
|
__spreadProps(__spreadValues({}, domProps), {
|
|
21049
21061
|
"data-menu-id": menuId,
|
|
@@ -21075,12 +21087,12 @@ function MenuComponent(props) {
|
|
|
21075
21087
|
return destroyed ? null : result;
|
|
21076
21088
|
}
|
|
21077
21089
|
function RuntimeItemRenderer(props) {
|
|
21078
|
-
const [pressed, setPressed] =
|
|
21090
|
+
const [pressed, setPressed] = React57.useState(false);
|
|
21079
21091
|
const { columns, item, index, active, keyboardActive } = props;
|
|
21080
21092
|
const key = item.type === "item" ? item.value.key : index;
|
|
21081
21093
|
let content = null;
|
|
21082
21094
|
if (item.type === "decoration") {
|
|
21083
|
-
content = /* @__PURE__ */
|
|
21095
|
+
content = /* @__PURE__ */ React57.createElement("div", { style: item.style }, item.value);
|
|
21084
21096
|
} else {
|
|
21085
21097
|
let spanIndex = 0;
|
|
21086
21098
|
content = columns.map((col, i) => {
|
|
@@ -21141,7 +21153,7 @@ function RuntimeItemRenderer(props) {
|
|
|
21141
21153
|
}
|
|
21142
21154
|
}
|
|
21143
21155
|
};
|
|
21144
|
-
return col.render ? /* @__PURE__ */
|
|
21156
|
+
return col.render ? /* @__PURE__ */ React57.createElement(
|
|
21145
21157
|
RenderHookComponent,
|
|
21146
21158
|
{
|
|
21147
21159
|
key: `${key}-${field}`,
|
|
@@ -21153,10 +21165,10 @@ function RuntimeItemRenderer(props) {
|
|
|
21153
21165
|
domProps
|
|
21154
21166
|
}
|
|
21155
21167
|
}
|
|
21156
|
-
) : /* @__PURE__ */
|
|
21168
|
+
) : /* @__PURE__ */ React57.createElement("div", __spreadValues({ key: `${key}-${field}` }, domProps), target[field]);
|
|
21157
21169
|
}).filter(Boolean);
|
|
21158
21170
|
}
|
|
21159
|
-
return /* @__PURE__ */
|
|
21171
|
+
return /* @__PURE__ */ React57.createElement("div", { className: MenuRowCls }, content);
|
|
21160
21172
|
}
|
|
21161
21173
|
|
|
21162
21174
|
// src/components/Menu/index.tsx
|
|
@@ -21170,12 +21182,12 @@ var MenuRoot = getComponentStateRoot({
|
|
|
21170
21182
|
function MenuContextProvider(props) {
|
|
21171
21183
|
const { componentActions, componentState } = useComponentState();
|
|
21172
21184
|
const getState = useLatest(componentState);
|
|
21173
|
-
return /* @__PURE__ */
|
|
21185
|
+
return /* @__PURE__ */ React58.createElement(
|
|
21174
21186
|
MenuContext.Provider,
|
|
21175
21187
|
{
|
|
21176
21188
|
value: { componentActions, componentState, getState }
|
|
21177
21189
|
},
|
|
21178
|
-
/* @__PURE__ */
|
|
21190
|
+
/* @__PURE__ */ React58.createElement(MenuComponent, { domProps: props.domProps })
|
|
21179
21191
|
);
|
|
21180
21192
|
}
|
|
21181
21193
|
function Menu(props) {
|
|
@@ -21217,24 +21229,24 @@ function Menu(props) {
|
|
|
21217
21229
|
//@ts-ignore
|
|
21218
21230
|
"__is_infinite_menu_component"
|
|
21219
21231
|
]);
|
|
21220
|
-
const menu = /* @__PURE__ */
|
|
21232
|
+
const menu = /* @__PURE__ */ React58.createElement(
|
|
21221
21233
|
MenuRoot,
|
|
21222
21234
|
__spreadValues({
|
|
21223
21235
|
addSubmenuColumnIfNeeded,
|
|
21224
21236
|
bubbleActionsFromSubmenus,
|
|
21225
21237
|
wrapLabels
|
|
21226
21238
|
}, props),
|
|
21227
|
-
/* @__PURE__ */
|
|
21239
|
+
/* @__PURE__ */ React58.createElement(MenuContextProvider, { domProps })
|
|
21228
21240
|
);
|
|
21229
21241
|
if (false) {
|
|
21230
|
-
return /* @__PURE__ */
|
|
21242
|
+
return /* @__PURE__ */ React58.createElement(React58.StrictMode, null, menu);
|
|
21231
21243
|
}
|
|
21232
21244
|
return menu;
|
|
21233
21245
|
}
|
|
21234
21246
|
Menu[propToIdentifyMenu] = true;
|
|
21235
21247
|
|
|
21236
21248
|
// src/components/InfiniteTable/utils/defaultGetColumnMenuItems.tsx
|
|
21237
|
-
import * as
|
|
21249
|
+
import * as React59 from "react";
|
|
21238
21250
|
function defaultGetColumnMenuItems(_items, params) {
|
|
21239
21251
|
const { columnApi, column, getComputed, api } = params;
|
|
21240
21252
|
const sortable = columnApi.isSortable();
|
|
@@ -21321,7 +21333,7 @@ function defaultGetColumnMenuItems(_items, params) {
|
|
|
21321
21333
|
colItems.push({
|
|
21322
21334
|
key: id,
|
|
21323
21335
|
label,
|
|
21324
|
-
check: /* @__PURE__ */
|
|
21336
|
+
check: /* @__PURE__ */ React59.createElement(
|
|
21325
21337
|
InfiniteCheckBox,
|
|
21326
21338
|
{
|
|
21327
21339
|
key: col.id,
|
|
@@ -21384,7 +21396,7 @@ function getMenuForColumn(columnId, context, onHideIntent) {
|
|
|
21384
21396
|
if (!items || !items.length) {
|
|
21385
21397
|
return null;
|
|
21386
21398
|
}
|
|
21387
|
-
return /* @__PURE__ */
|
|
21399
|
+
return /* @__PURE__ */ React60.createElement(
|
|
21388
21400
|
MenuCmp,
|
|
21389
21401
|
{
|
|
21390
21402
|
autoFocus: true,
|
|
@@ -21504,7 +21516,7 @@ function useColumnMenu() {
|
|
|
21504
21516
|
}
|
|
21505
21517
|
|
|
21506
21518
|
// src/components/InfiniteTable/components/FocusDetect.tsx
|
|
21507
|
-
import * as
|
|
21519
|
+
import * as React61 from "react";
|
|
21508
21520
|
import { useCallback as useCallback26 } from "react";
|
|
21509
21521
|
var style = {
|
|
21510
21522
|
width: 0,
|
|
@@ -21538,7 +21550,7 @@ function FocusDetect() {
|
|
|
21538
21550
|
};
|
|
21539
21551
|
focusLastFocusableCell(context);
|
|
21540
21552
|
}), []);
|
|
21541
|
-
return /* @__PURE__ */
|
|
21553
|
+
return /* @__PURE__ */ React61.createElement(
|
|
21542
21554
|
"div",
|
|
21543
21555
|
{
|
|
21544
21556
|
onFocus,
|
|
@@ -21669,18 +21681,18 @@ function useEditingCallbackProps() {
|
|
|
21669
21681
|
import { useEffect as useEffect34 } from "react";
|
|
21670
21682
|
|
|
21671
21683
|
// src/components/InfiniteTable/utils/getFilterOperatorMenuForColumn.tsx
|
|
21672
|
-
import * as
|
|
21684
|
+
import * as React64 from "react";
|
|
21673
21685
|
|
|
21674
21686
|
// src/components/InfiniteTable/components/icons/ClearIcon.tsx
|
|
21675
|
-
import * as
|
|
21687
|
+
import * as React62 from "react";
|
|
21676
21688
|
var ClearIcon = (props) => {
|
|
21677
|
-
return /* @__PURE__ */
|
|
21689
|
+
return /* @__PURE__ */ React62.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React62.createElement("path", { d: "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" }));
|
|
21678
21690
|
};
|
|
21679
21691
|
|
|
21680
21692
|
// src/components/InfiniteTable/components/icons/DoneIcon.tsx
|
|
21681
|
-
import * as
|
|
21693
|
+
import * as React63 from "react";
|
|
21682
21694
|
var DoneIcon = (props) => {
|
|
21683
|
-
return /* @__PURE__ */
|
|
21695
|
+
return /* @__PURE__ */ React63.createElement(Icon, __spreadValues({}, props), /* @__PURE__ */ React63.createElement("path", { d: "m9.55 19-6.725-6.725L5.25 9.85l4.3 4.325 9.225-9.225 2.425 2.4Z" }));
|
|
21684
21696
|
};
|
|
21685
21697
|
|
|
21686
21698
|
// src/components/InfiniteTable/utils/getFilterOperatorMenuForColumn.tsx
|
|
@@ -21726,12 +21738,12 @@ function getFilterOperatorMenuForColumn(columnId, context, onHideIntent) {
|
|
|
21726
21738
|
const IconCmp = (_b = (_a2 = operator.components) == null ? void 0 : _a2.Icon) != null ? _b : FilterIcon;
|
|
21727
21739
|
return {
|
|
21728
21740
|
key,
|
|
21729
|
-
icon: /* @__PURE__ */
|
|
21730
|
-
label: /* @__PURE__ */
|
|
21741
|
+
icon: /* @__PURE__ */ React64.createElement(IconCmp, null),
|
|
21742
|
+
label: /* @__PURE__ */ React64.createElement(React64.Fragment, null, (_c = operator.label) != null ? _c : operator.name),
|
|
21731
21743
|
onAction: () => {
|
|
21732
21744
|
api.setColumnFilterOperator(columnId, key);
|
|
21733
21745
|
},
|
|
21734
|
-
checked: checked ? /* @__PURE__ */
|
|
21746
|
+
checked: checked ? /* @__PURE__ */ React64.createElement(DoneIcon, { size: 16 }) : null
|
|
21735
21747
|
};
|
|
21736
21748
|
});
|
|
21737
21749
|
const firstItems = [
|
|
@@ -21746,7 +21758,7 @@ function getFilterOperatorMenuForColumn(columnId, context, onHideIntent) {
|
|
|
21746
21758
|
{
|
|
21747
21759
|
key: "reset",
|
|
21748
21760
|
label: "Reset",
|
|
21749
|
-
icon: /* @__PURE__ */
|
|
21761
|
+
icon: /* @__PURE__ */ React64.createElement(ClearIcon, null),
|
|
21750
21762
|
disabled: !column.computedFiltered,
|
|
21751
21763
|
onAction: () => {
|
|
21752
21764
|
api.clearColumnFilter(columnId);
|
|
@@ -21768,7 +21780,7 @@ function getFilterOperatorMenuForColumn(columnId, context, onHideIntent) {
|
|
|
21768
21780
|
filterTypes
|
|
21769
21781
|
};
|
|
21770
21782
|
const items = getFilterOperatorMenuItems ? getFilterOperatorMenuItems(defaultItems, param) : defaultItems;
|
|
21771
|
-
return /* @__PURE__ */
|
|
21783
|
+
return /* @__PURE__ */ React64.createElement(
|
|
21772
21784
|
MenuCmp,
|
|
21773
21785
|
{
|
|
21774
21786
|
autoFocus: true,
|
|
@@ -21875,7 +21887,7 @@ function useColumnFilterOperatorMenu() {
|
|
|
21875
21887
|
import { useEffect as useEffect35 } from "react";
|
|
21876
21888
|
|
|
21877
21889
|
// src/components/InfiniteTable/utils/getCellContextMenu.tsx
|
|
21878
|
-
import * as
|
|
21890
|
+
import * as React65 from "react";
|
|
21879
21891
|
function getCellContextMenu(cellLocation, context, onHideIntent) {
|
|
21880
21892
|
var _a;
|
|
21881
21893
|
const { columnId, rowIndex, event } = cellLocation;
|
|
@@ -21915,7 +21927,7 @@ function getCellContextMenu(cellLocation, context, onHideIntent) {
|
|
|
21915
21927
|
}
|
|
21916
21928
|
return {
|
|
21917
21929
|
preventDefault: true,
|
|
21918
|
-
menu: /* @__PURE__ */
|
|
21930
|
+
menu: /* @__PURE__ */ React65.createElement(
|
|
21919
21931
|
MenuCmp,
|
|
21920
21932
|
{
|
|
21921
21933
|
columns: menuColumns,
|
|
@@ -21970,7 +21982,7 @@ function getTableContextMenu(menuLocation, context, onHideIntent) {
|
|
|
21970
21982
|
}
|
|
21971
21983
|
return {
|
|
21972
21984
|
preventDefault: true,
|
|
21973
|
-
menu: /* @__PURE__ */
|
|
21985
|
+
menu: /* @__PURE__ */ React65.createElement(
|
|
21974
21986
|
MenuCmp,
|
|
21975
21987
|
{
|
|
21976
21988
|
columns: menuColumns,
|
|
@@ -22174,6 +22186,83 @@ function useTableContextMenu() {
|
|
|
22174
22186
|
return { menuPortal };
|
|
22175
22187
|
}
|
|
22176
22188
|
|
|
22189
|
+
// src/components/InfiniteTable/components/HScrollSyncContent.tsx
|
|
22190
|
+
import { useRef as useRef30 } from "react";
|
|
22191
|
+
import * as React66 from "react";
|
|
22192
|
+
|
|
22193
|
+
// src/components/InfiniteTable/hooks/useGridScroll.ts
|
|
22194
|
+
import { useCallback as useCallback27, useEffect as useEffect36 } from "react";
|
|
22195
|
+
function useGridScroll(onScroll, deps) {
|
|
22196
|
+
const {
|
|
22197
|
+
state: { brain }
|
|
22198
|
+
} = useInfiniteTable();
|
|
22199
|
+
const memoizedOnScroll = useCallback27(onScroll, deps);
|
|
22200
|
+
useEffect36(() => {
|
|
22201
|
+
const removeOnScroll = brain.onScroll(memoizedOnScroll);
|
|
22202
|
+
return removeOnScroll;
|
|
22203
|
+
}, [brain, memoizedOnScroll]);
|
|
22204
|
+
}
|
|
22205
|
+
|
|
22206
|
+
// src/components/InfiniteTable/components/HScrollSyncContent.css.ts
|
|
22207
|
+
var HScrollSyncContentCls = "HScrollSyncContent_HScrollSyncContentCls__yzx0vj0";
|
|
22208
|
+
|
|
22209
|
+
// src/components/InfiniteTable/components/HScrollSyncContent.tsx
|
|
22210
|
+
function HScrollSyncContent(props) {
|
|
22211
|
+
const _a = props, { width, maxWidth, minWidth, scrollable } = _a, domProps = __objRest(_a, ["width", "maxWidth", "minWidth", "scrollable"]);
|
|
22212
|
+
const domRef = useRef30(null);
|
|
22213
|
+
useGridScroll(
|
|
22214
|
+
(scrollPos) => {
|
|
22215
|
+
if (domRef.current && scrollable !== false) {
|
|
22216
|
+
domRef.current.style.transform = `translate3d(${-scrollPos.scrollLeft}px, 0px, 0px)`;
|
|
22217
|
+
}
|
|
22218
|
+
},
|
|
22219
|
+
[scrollable]
|
|
22220
|
+
);
|
|
22221
|
+
const style2 = __spreadValues({}, domProps.style);
|
|
22222
|
+
if (width === "column") {
|
|
22223
|
+
style2.width = ThemeVars.runtime.totalVisibleColumnsWidth;
|
|
22224
|
+
} else if (width === "viewport") {
|
|
22225
|
+
style2.width = ThemeVars.runtime.bodyWidth;
|
|
22226
|
+
}
|
|
22227
|
+
if (minWidth === "column") {
|
|
22228
|
+
style2.minWidth = ThemeVars.runtime.totalVisibleColumnsWidth;
|
|
22229
|
+
} else if (minWidth === "viewport") {
|
|
22230
|
+
style2.minWidth = ThemeVars.runtime.bodyWidth;
|
|
22231
|
+
}
|
|
22232
|
+
if (maxWidth === "column") {
|
|
22233
|
+
style2.maxWidth = ThemeVars.runtime.totalVisibleColumnsWidth;
|
|
22234
|
+
} else if (maxWidth === "viewport") {
|
|
22235
|
+
style2.maxWidth = ThemeVars.runtime.bodyWidth;
|
|
22236
|
+
}
|
|
22237
|
+
return /* @__PURE__ */ React66.createElement(
|
|
22238
|
+
"div",
|
|
22239
|
+
__spreadProps(__spreadValues({
|
|
22240
|
+
ref: domRef
|
|
22241
|
+
}, domProps), {
|
|
22242
|
+
className: domProps.className ? join(domProps.className, HScrollSyncContentCls) : HScrollSyncContentCls,
|
|
22243
|
+
style: style2
|
|
22244
|
+
}),
|
|
22245
|
+
domProps.children
|
|
22246
|
+
);
|
|
22247
|
+
}
|
|
22248
|
+
|
|
22249
|
+
// src/components/InfiniteTable/hooks/useVisibleColumnSizes.ts
|
|
22250
|
+
var columnWidthAtIndex6 = stripVar(InternalVars.columnWidthAtIndex);
|
|
22251
|
+
var columnOffsetAtIndex5 = stripVar(InternalVars.columnOffsetAtIndex);
|
|
22252
|
+
function useVisibleColumnSizes() {
|
|
22253
|
+
const context = useInfiniteTable();
|
|
22254
|
+
return context.computed.computedVisibleColumns.map((column) => {
|
|
22255
|
+
return {
|
|
22256
|
+
id: column.id,
|
|
22257
|
+
width: column.computedWidth,
|
|
22258
|
+
cssVarForWidth: `var(${columnWidthAtIndex6}-${column.computedVisibleIndex})`,
|
|
22259
|
+
offset: column.computedOffset,
|
|
22260
|
+
cssVarForOffset: `var(${columnOffsetAtIndex5}-${column.computedVisibleIndex})`,
|
|
22261
|
+
pinned: column.computedPinned
|
|
22262
|
+
};
|
|
22263
|
+
});
|
|
22264
|
+
}
|
|
22265
|
+
|
|
22177
22266
|
// src/components/InfiniteTable/index.tsx
|
|
22178
22267
|
var InfiniteTableClassName = internalProps.rootClassName;
|
|
22179
22268
|
var HOVERED_CLASS_NAMES = [RowHoverCls, "InfiniteColumnCell--hovered"];
|
|
@@ -22191,44 +22280,154 @@ var InfiniteTableRoot = getComponentStateRoot({
|
|
|
22191
22280
|
rowHeight: true,
|
|
22192
22281
|
columnHeaderHeight: true
|
|
22193
22282
|
},
|
|
22283
|
+
//@ts-ignore
|
|
22284
|
+
mappedCallbacks: getMappedCallbacks2(),
|
|
22194
22285
|
// @ts-ignore
|
|
22195
22286
|
getParentState: () => useDataSource(),
|
|
22196
22287
|
debugName: "InfiniteTable"
|
|
22197
22288
|
});
|
|
22289
|
+
function InfiniteTableHeader2() {
|
|
22290
|
+
const context = useInfiniteTable();
|
|
22291
|
+
const { state: componentState, getComputed } = context;
|
|
22292
|
+
const { header, brain, headerBrain } = componentState;
|
|
22293
|
+
const { scrollbars } = getComputed();
|
|
22294
|
+
return header ? /* @__PURE__ */ React67.createElement(
|
|
22295
|
+
TableHeaderWrapper,
|
|
22296
|
+
{
|
|
22297
|
+
bodyBrain: brain,
|
|
22298
|
+
headerBrain,
|
|
22299
|
+
scrollbars
|
|
22300
|
+
}
|
|
22301
|
+
) : null;
|
|
22302
|
+
}
|
|
22303
|
+
var InfiniteTableBodyCls = join(
|
|
22304
|
+
`${rootClassName2}Body`,
|
|
22305
|
+
position.relative,
|
|
22306
|
+
flex["1"],
|
|
22307
|
+
transformTranslateZero
|
|
22308
|
+
);
|
|
22309
|
+
function InfiniteTableBodyContainer(props) {
|
|
22310
|
+
return /* @__PURE__ */ React67.createElement(
|
|
22311
|
+
"div",
|
|
22312
|
+
__spreadProps(__spreadValues({}, props), {
|
|
22313
|
+
className: props.className ? join(InfiniteTableBodyCls, props.className) : InfiniteTableBodyCls
|
|
22314
|
+
})
|
|
22315
|
+
);
|
|
22316
|
+
}
|
|
22317
|
+
function InfiniteTableBody() {
|
|
22318
|
+
var _a;
|
|
22319
|
+
const context = useInfiniteTable();
|
|
22320
|
+
const masterContext = useMasterDetailContext();
|
|
22321
|
+
const { state: componentState, getComputed, api } = context;
|
|
22322
|
+
const {
|
|
22323
|
+
renderer,
|
|
22324
|
+
onRenderUpdater,
|
|
22325
|
+
debugId,
|
|
22326
|
+
keyboardNavigation,
|
|
22327
|
+
activeRowIndex,
|
|
22328
|
+
loadingText,
|
|
22329
|
+
scrollStopDelay,
|
|
22330
|
+
brain,
|
|
22331
|
+
scrollerDOMRef,
|
|
22332
|
+
components: components2,
|
|
22333
|
+
bodySize,
|
|
22334
|
+
activeCellIndex,
|
|
22335
|
+
rowDetailRenderer
|
|
22336
|
+
} = componentState;
|
|
22337
|
+
const LoadMaskCmp = (_a = components2 == null ? void 0 : components2.LoadMask) != null ? _a : LoadMask;
|
|
22338
|
+
const computed = getComputed();
|
|
22339
|
+
const { computedRowHeight, computedRowSizeCacheForDetails } = computed;
|
|
22340
|
+
const activeCellRowHeight = (computedRowSizeCacheForDetails == null ? void 0 : computedRowSizeCacheForDetails.getRowHeight) || computedRowHeight;
|
|
22341
|
+
const {
|
|
22342
|
+
componentState: { loading }
|
|
22343
|
+
} = useDataSourceContextValue();
|
|
22344
|
+
const onContextMenu = React67.useCallback((event) => {
|
|
22345
|
+
const state = context.getState();
|
|
22346
|
+
const target = event.target;
|
|
22347
|
+
if (!masterContext && event._from_row_detail) {
|
|
22348
|
+
return;
|
|
22349
|
+
}
|
|
22350
|
+
if (masterContext) {
|
|
22351
|
+
event._from_row_detail = true;
|
|
22352
|
+
}
|
|
22353
|
+
const cell = selectParentUntil(
|
|
22354
|
+
target,
|
|
22355
|
+
getCellSelector(),
|
|
22356
|
+
state.domRef.current
|
|
22357
|
+
);
|
|
22358
|
+
let columnId;
|
|
22359
|
+
let colIndex;
|
|
22360
|
+
let rowId;
|
|
22361
|
+
let rowIndex;
|
|
22362
|
+
if (cell) {
|
|
22363
|
+
colIndex = Number(cell.dataset.colIndex);
|
|
22364
|
+
rowIndex = Number(cell.dataset.rowIndex);
|
|
22365
|
+
columnId = context.getComputed().computedVisibleColumns[colIndex].id;
|
|
22366
|
+
rowId = context.dataSourceApi.getRowInfoArray()[rowIndex].id;
|
|
22367
|
+
}
|
|
22368
|
+
const param = {
|
|
22369
|
+
columnId,
|
|
22370
|
+
colIndex,
|
|
22371
|
+
rowId,
|
|
22372
|
+
rowIndex,
|
|
22373
|
+
event,
|
|
22374
|
+
target: cell != null ? cell : event.target
|
|
22375
|
+
};
|
|
22376
|
+
if (cell) {
|
|
22377
|
+
state.cellContextMenu(param);
|
|
22378
|
+
}
|
|
22379
|
+
state.contextMenu(param);
|
|
22380
|
+
}, []);
|
|
22381
|
+
const { renderCell, renderDetailRow } = useCellRendering({
|
|
22382
|
+
imperativeApi: api,
|
|
22383
|
+
getComputed,
|
|
22384
|
+
domRef: componentState.domRef,
|
|
22385
|
+
bodySize,
|
|
22386
|
+
computed
|
|
22387
|
+
});
|
|
22388
|
+
return /* @__PURE__ */ React67.createElement(InfiniteTableBodyContainer, { onContextMenu }, /* @__PURE__ */ React67.createElement(
|
|
22389
|
+
HeadlessTable,
|
|
22390
|
+
{
|
|
22391
|
+
debugId,
|
|
22392
|
+
tabIndex: 0,
|
|
22393
|
+
activeRowIndex: componentState.ready && keyboardNavigation === "row" ? activeRowIndex : null,
|
|
22394
|
+
activeCellIndex: componentState.ready && keyboardNavigation === "cell" && // we want to hide the active cell indicator while column reodering is happening
|
|
22395
|
+
!componentState.columnReorderDragColumnId ? activeCellIndex : null,
|
|
22396
|
+
scrollStopDelay,
|
|
22397
|
+
renderer,
|
|
22398
|
+
onRenderUpdater,
|
|
22399
|
+
brain,
|
|
22400
|
+
activeCellRowHeight,
|
|
22401
|
+
renderCell,
|
|
22402
|
+
renderDetailRow: rowDetailRenderer ? renderDetailRow : void 0,
|
|
22403
|
+
cellHoverClassNames: HOVERED_CLASS_NAMES,
|
|
22404
|
+
scrollerDOMRef
|
|
22405
|
+
}
|
|
22406
|
+
), /* @__PURE__ */ React67.createElement(LoadMaskCmp, { visible: loading }, loadingText));
|
|
22407
|
+
}
|
|
22198
22408
|
var InfiniteTableComponent = React67.memo(
|
|
22199
22409
|
function InfiniteTableComponent2() {
|
|
22200
|
-
var _a;
|
|
22201
22410
|
const context = useInfiniteTable();
|
|
22202
22411
|
const masterContext = useMasterDetailContext();
|
|
22203
|
-
const { state: componentState,
|
|
22412
|
+
const { state: componentState, api, children: initialChildren } = context;
|
|
22204
22413
|
const {
|
|
22205
|
-
componentState: {
|
|
22414
|
+
componentState: { dataArray },
|
|
22206
22415
|
getState: getDataSourceState,
|
|
22207
22416
|
componentActions: dataSourceActions
|
|
22208
22417
|
} = useDataSourceContextValue();
|
|
22209
22418
|
const {
|
|
22210
22419
|
domRef,
|
|
22211
|
-
scrollerDOMRef,
|
|
22212
22420
|
portalDOMRef,
|
|
22213
|
-
loadingText,
|
|
22214
|
-
rowDetailRenderer,
|
|
22215
|
-
header,
|
|
22216
22421
|
onRowHeightCSSVarChange,
|
|
22217
22422
|
onRowDetailHeightCSSVarChange,
|
|
22218
22423
|
onColumnHeaderHeightCSSVarChange,
|
|
22219
22424
|
rowHeightCSSVar,
|
|
22220
22425
|
rowDetailHeightCSSVar,
|
|
22221
22426
|
columnHeaderHeightCSSVar,
|
|
22222
|
-
components: components2,
|
|
22223
22427
|
scrollStopDelay,
|
|
22224
22428
|
brain,
|
|
22225
|
-
headerBrain,
|
|
22226
|
-
renderer,
|
|
22227
|
-
keyboardNavigation,
|
|
22228
22429
|
activeRowIndex,
|
|
22229
|
-
activeCellIndex
|
|
22230
|
-
onRenderUpdater,
|
|
22231
|
-
debugId
|
|
22430
|
+
activeCellIndex
|
|
22232
22431
|
} = componentState;
|
|
22233
22432
|
let { licenseKey } = componentState;
|
|
22234
22433
|
if (!licenseKey && InfiniteTable.licenseKey) {
|
|
@@ -22237,16 +22436,6 @@ var InfiniteTableComponent = React67.memo(
|
|
|
22237
22436
|
useScrollToActiveRow(activeRowIndex, dataArray.length, api);
|
|
22238
22437
|
useScrollToActiveCell(activeCellIndex, dataArray.length, api);
|
|
22239
22438
|
const { onKeyDown: onKeyDown2 } = useDOMEventHandlers();
|
|
22240
|
-
const { bodySize } = componentState;
|
|
22241
|
-
const { scrollbars, computedRowHeight, computedRowSizeCacheForDetails } = computed;
|
|
22242
|
-
const activeCellRowHeight = (computedRowSizeCacheForDetails == null ? void 0 : computedRowSizeCacheForDetails.getRowHeight) || computedRowHeight;
|
|
22243
|
-
const { renderCell, renderDetailRow } = useCellRendering({
|
|
22244
|
-
imperativeApi: api,
|
|
22245
|
-
getComputed,
|
|
22246
|
-
domRef: componentState.domRef,
|
|
22247
|
-
bodySize,
|
|
22248
|
-
computed
|
|
22249
|
-
});
|
|
22250
22439
|
React67.useEffect(() => {
|
|
22251
22440
|
const dataSourceState = getDataSourceState();
|
|
22252
22441
|
const onChange = debounce(
|
|
@@ -22262,7 +22451,6 @@ var InfiniteTableComponent = React67.memo(
|
|
|
22262
22451
|
}, [brain, scrollStopDelay]);
|
|
22263
22452
|
const licenseValid = useLicense(licenseKey);
|
|
22264
22453
|
const domProps = useDOMProps(componentState.domProps);
|
|
22265
|
-
const LoadMaskCmp = (_a = components2 == null ? void 0 : components2.LoadMask) != null ? _a : LoadMask;
|
|
22266
22454
|
React67.useEffect(() => {
|
|
22267
22455
|
brain.setScrollStopDelay(scrollStopDelay);
|
|
22268
22456
|
dataSourceActions.scrollStopDelayUpdatedByTable = scrollStopDelay;
|
|
@@ -22286,74 +22474,13 @@ var InfiniteTableComponent = React67.memo(
|
|
|
22286
22474
|
globalThis.infiniteApi = context.api;
|
|
22287
22475
|
}
|
|
22288
22476
|
}, [componentState.ready]);
|
|
22289
|
-
const onContextMenu = React67.useCallback((event) => {
|
|
22290
|
-
const state = context.getState();
|
|
22291
|
-
const target = event.target;
|
|
22292
|
-
if (!masterContext && event._from_row_detail) {
|
|
22293
|
-
return;
|
|
22294
|
-
}
|
|
22295
|
-
if (masterContext) {
|
|
22296
|
-
event._from_row_detail = true;
|
|
22297
|
-
}
|
|
22298
|
-
const cell = selectParentUntil(
|
|
22299
|
-
target,
|
|
22300
|
-
getCellSelector(),
|
|
22301
|
-
state.domRef.current
|
|
22302
|
-
);
|
|
22303
|
-
let columnId;
|
|
22304
|
-
let colIndex;
|
|
22305
|
-
let rowId;
|
|
22306
|
-
let rowIndex;
|
|
22307
|
-
if (cell) {
|
|
22308
|
-
colIndex = Number(cell.dataset.colIndex);
|
|
22309
|
-
rowIndex = Number(cell.dataset.rowIndex);
|
|
22310
|
-
columnId = context.getComputed().computedVisibleColumns[colIndex].id;
|
|
22311
|
-
rowId = context.dataSourceApi.getRowInfoArray()[rowIndex].id;
|
|
22312
|
-
}
|
|
22313
|
-
const param = {
|
|
22314
|
-
columnId,
|
|
22315
|
-
colIndex,
|
|
22316
|
-
rowId,
|
|
22317
|
-
rowIndex,
|
|
22318
|
-
event,
|
|
22319
|
-
target: cell != null ? cell : event.target
|
|
22320
|
-
};
|
|
22321
|
-
if (cell) {
|
|
22322
|
-
state.cellContextMenu(param);
|
|
22323
|
-
}
|
|
22324
|
-
state.contextMenu(param);
|
|
22325
|
-
}, []);
|
|
22326
22477
|
React67.useEffect(() => {
|
|
22327
22478
|
if (masterContext) {
|
|
22328
22479
|
portalDOMRef.current = masterContext.getMasterState().portalDOMRef.current;
|
|
22329
22480
|
}
|
|
22330
22481
|
}, []);
|
|
22331
|
-
|
|
22332
|
-
|
|
22333
|
-
{
|
|
22334
|
-
bodyBrain: brain,
|
|
22335
|
-
headerBrain,
|
|
22336
|
-
scrollbars
|
|
22337
|
-
}
|
|
22338
|
-
) : null, /* @__PURE__ */ React67.createElement(InfiniteTableBody, { onContextMenu }, /* @__PURE__ */ React67.createElement(
|
|
22339
|
-
HeadlessTable,
|
|
22340
|
-
{
|
|
22341
|
-
debugId,
|
|
22342
|
-
tabIndex: 0,
|
|
22343
|
-
activeRowIndex: componentState.ready && keyboardNavigation === "row" ? activeRowIndex : null,
|
|
22344
|
-
activeCellIndex: componentState.ready && keyboardNavigation === "cell" && // we want to hide the active cell indicator while column reodering is happening
|
|
22345
|
-
!componentState.columnReorderDragColumnId ? activeCellIndex : null,
|
|
22346
|
-
scrollStopDelay,
|
|
22347
|
-
renderer,
|
|
22348
|
-
onRenderUpdater,
|
|
22349
|
-
brain,
|
|
22350
|
-
activeCellRowHeight,
|
|
22351
|
-
renderCell,
|
|
22352
|
-
renderDetailRow: rowDetailRenderer ? renderDetailRow : void 0,
|
|
22353
|
-
cellHoverClassNames: HOVERED_CLASS_NAMES,
|
|
22354
|
-
scrollerDOMRef
|
|
22355
|
-
}
|
|
22356
|
-
), /* @__PURE__ */ React67.createElement(LoadMaskCmp, { visible: loading }, loadingText)), /* @__PURE__ */ React67.createElement(
|
|
22482
|
+
const children = initialChildren != null ? initialChildren : /* @__PURE__ */ React67.createElement(React67.Fragment, null, /* @__PURE__ */ React67.createElement(InfiniteTableHeader2, null), /* @__PURE__ */ React67.createElement(InfiniteTableBody, null));
|
|
22483
|
+
return /* @__PURE__ */ React67.createElement("div", __spreadValues({ onKeyDown: onKeyDown2, ref: domRef }, domProps), children, /* @__PURE__ */ React67.createElement(
|
|
22357
22484
|
"div",
|
|
22358
22485
|
{
|
|
22359
22486
|
ref: portalDOMRef,
|
|
@@ -22387,10 +22514,12 @@ var InfiniteTableComponent = React67.memo(
|
|
|
22387
22514
|
varName: columnHeaderHeightCSSVar,
|
|
22388
22515
|
onChange: onColumnHeaderHeightCSSVarChange
|
|
22389
22516
|
}
|
|
22390
|
-
) : null,
|
|
22517
|
+
) : null, licenseValid ? null : /* @__PURE__ */ React67.createElement(InfiniteTableLicenseFooter, null), /* @__PURE__ */ React67.createElement(FocusDetect, null));
|
|
22391
22518
|
}
|
|
22392
22519
|
);
|
|
22393
|
-
function InfiniteTableContextProvider(
|
|
22520
|
+
function InfiniteTableContextProvider({
|
|
22521
|
+
children
|
|
22522
|
+
}) {
|
|
22394
22523
|
const { componentActions, componentState } = useComponentState();
|
|
22395
22524
|
const { scrollerDOMRef, scrollTopKey } = componentState;
|
|
22396
22525
|
const computed = useComputed();
|
|
@@ -22430,7 +22559,8 @@ function InfiniteTableContextProvider() {
|
|
|
22430
22559
|
getComputed,
|
|
22431
22560
|
getState,
|
|
22432
22561
|
api: imperativeApi,
|
|
22433
|
-
dataSourceApi
|
|
22562
|
+
dataSourceApi,
|
|
22563
|
+
children
|
|
22434
22564
|
};
|
|
22435
22565
|
useResizeObserver(
|
|
22436
22566
|
scrollerDOMRef,
|
|
@@ -22463,7 +22593,7 @@ var InfiniteTable = function(props) {
|
|
|
22463
22593
|
rowHeight: DEFAULT_ROW_HEIGHT,
|
|
22464
22594
|
columnHeaderHeight: DEFAULT_COLUMN_HEADER_HEIGHT
|
|
22465
22595
|
}, props),
|
|
22466
|
-
/* @__PURE__ */ React67.createElement(InfiniteTableContextProvider,
|
|
22596
|
+
/* @__PURE__ */ React67.createElement(InfiniteTableContextProvider, { children: props.children })
|
|
22467
22597
|
)
|
|
22468
22598
|
);
|
|
22469
22599
|
if (false) {
|
|
@@ -22471,6 +22601,10 @@ var InfiniteTable = function(props) {
|
|
|
22471
22601
|
}
|
|
22472
22602
|
return table;
|
|
22473
22603
|
};
|
|
22604
|
+
InfiniteTable.Header = InfiniteTableHeader2;
|
|
22605
|
+
InfiniteTable.Body = InfiniteTableBody;
|
|
22606
|
+
InfiniteTable.HScrollSyncContent = HScrollSyncContent;
|
|
22607
|
+
InfiniteTable.Footer = () => /* @__PURE__ */ React67.createElement(InfiniteTableFooter, null);
|
|
22474
22608
|
|
|
22475
22609
|
// src/components/InfiniteTable/eventHandlers/keyboardShortcuts.ts
|
|
22476
22610
|
var instantEdit = {
|
|
@@ -22517,7 +22651,7 @@ var keyboardShortcuts = {
|
|
|
22517
22651
|
};
|
|
22518
22652
|
|
|
22519
22653
|
// src/components/hooks/useInterceptedMap.ts
|
|
22520
|
-
import { useEffect as
|
|
22654
|
+
import { useEffect as useEffect38 } from "react";
|
|
22521
22655
|
function interceptMap(map2, fns) {
|
|
22522
22656
|
const { set, delete: deleteKey, clear } = map2;
|
|
22523
22657
|
if (fns.set) {
|
|
@@ -22717,6 +22851,7 @@ export {
|
|
|
22717
22851
|
useDataSource,
|
|
22718
22852
|
useEffectWithChanges,
|
|
22719
22853
|
useEffectWithObject,
|
|
22854
|
+
useGridScroll,
|
|
22720
22855
|
useInfiniteColumnCell,
|
|
22721
22856
|
useInfiniteColumnEditor,
|
|
22722
22857
|
useInfiniteColumnFilterEditor,
|
|
@@ -22724,6 +22859,7 @@ export {
|
|
|
22724
22859
|
useMasterRowInfo,
|
|
22725
22860
|
useOverlay,
|
|
22726
22861
|
useOverlayPortal,
|
|
22727
|
-
useRowInfoReducers
|
|
22862
|
+
useRowInfoReducers,
|
|
22863
|
+
useVisibleColumnSizes
|
|
22728
22864
|
};
|
|
22729
22865
|
//!collapsed || lazyLoad;
|