@infinite-table/infinite-react 5.0.0-canary.3 → 5.0.0-canary.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.css +89 -30
- package/index.d.ts +25 -2
- package/index.dev.js +191 -6
- package/index.dev.mjs +186 -6
- package/index.js +191 -6
- package/index.mjs +186 -6
- package/package.json +2 -2
package/index.js
CHANGED
|
@@ -132,6 +132,7 @@ __export(src_exports, {
|
|
|
132
132
|
DataSourceActionType: () => DataSourceActionType,
|
|
133
133
|
DeepMap: () => DeepMap,
|
|
134
134
|
FixedSizeSet: () => FixedSizeSet,
|
|
135
|
+
FlashingColumnCell: () => FlashingColumnCell,
|
|
135
136
|
GroupRowsState: () => GroupRowsState,
|
|
136
137
|
InfiniteTable: () => InfiniteTable,
|
|
137
138
|
InfiniteTableClassName: () => InfiniteTableClassName,
|
|
@@ -143,6 +144,7 @@ __export(src_exports, {
|
|
|
143
144
|
RowSelectionState: () => RowSelectionState,
|
|
144
145
|
WeakFixedSizeSet: () => WeakFixedSizeSet,
|
|
145
146
|
components: () => components,
|
|
147
|
+
createFlashingColumnCellComponent: () => createFlashingColumnCellComponent,
|
|
146
148
|
debounce: () => debounce,
|
|
147
149
|
debug: () => debug,
|
|
148
150
|
defaultFilterTypes: () => defaultFilterTypes2,
|
|
@@ -158,6 +160,8 @@ __export(src_exports, {
|
|
|
158
160
|
useComponentState: () => useManagedComponentState,
|
|
159
161
|
useDataSourceInternal: () => useDataSourceInternal,
|
|
160
162
|
useDataSourceState: () => useDataSourceState,
|
|
163
|
+
useEffectWhen: () => useEffectWhen,
|
|
164
|
+
useEffectWhenSameDeps: () => useEffectWhenSameDeps,
|
|
161
165
|
useEffectWithChanges: () => useEffectWithChanges,
|
|
162
166
|
useEffectWithObject: () => useEffectWithObject,
|
|
163
167
|
useGridScroll: () => useGridScroll,
|
|
@@ -169,6 +173,7 @@ __export(src_exports, {
|
|
|
169
173
|
useMasterRowInfo: () => useMasterRowInfo,
|
|
170
174
|
useOverlay: () => useOverlay,
|
|
171
175
|
useOverlayPortal: () => useOverlayPortal,
|
|
176
|
+
usePrevious: () => usePrevious,
|
|
172
177
|
useRowInfoReducers: () => useRowInfoReducers,
|
|
173
178
|
useVisibleColumnSizes: () => useVisibleColumnSizes
|
|
174
179
|
});
|
|
@@ -1369,7 +1374,7 @@ function buildSubscriptionCallback(withRaf = false) {
|
|
|
1369
1374
|
}
|
|
1370
1375
|
|
|
1371
1376
|
// src/components/InfiniteTable/vars.css.ts
|
|
1372
|
-
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)", totalVisibleColumnsWidthValue: "var(--infinite-runtime-total-visible-columns-width)", totalVisibleColumnsWidthVar: "var(--infinite-runtime-total-visible-columns-width-var)", visibleColumnsCount: "var(--infinite-runtime-visible-columns-count)", browserScrollbarWidth: "var(--infinite-runtime-browser-scrollbar-width)" }, components: { LoadMask: { padding: "var(--infinite-load-mask-padding)", color: "var(--infinite-load-mask-color)", textBackground: "var(--infinite-load-mask-text-background)", overlayBackground: "var(--infinite-load-mask-overlay-background)", overlayOpacity: "var(--infinite-load-mask-overlay-opacity)", borderRadius: "var(--infinite-load-mask-border-radius)" }, Header: { background: "var(--infinite-header-background)", color: "var(--infinite-header-color)", columnHeaderHeight: "var(--infinite-column-header-height)" }, HeaderCell: { background: "var(--infinite-header-cell-background)", hoverBackground: "var(--infinite-header-cell-hover-background)", border: "var(--infinite-header-cell-border)", padding: "var(--infinite-header-cell-padding)", paddingX: "var(--infinite-header-cell-padding-x)", paddingY: "var(--infinite-header-cell-padding-y)", iconSize: "var(--infinite-header-cell-icon-size)", menuIconLineWidth: "var(--infinite-header-cell-menu-icon-line-width)", sortIconMargin: "var(--infinite-header-cell-sort-icon-margin)", borderRight: "var(--infinite-header-cell-border-right)", resizeHandleActiveAreaWidth: "var(--infinite-resize-handle-active-area-width)", resizeHandleWidth: "var(--infinite-resize-handle-width)", resizeHandleHoverBackground: "var(--infinite-resize-handle-hover-background)", resizeHandleConstrainedHoverBackground: "var(--infinite-resize-handle-constrained-hover-background)", filterOperatorPaddingX: "var(--infinite-filter-operator-padding-x)", filterEditorPaddingX: "var(--infinite-filter-editor-padding-x)", filterEditorMarginX: "var(--infinite-filter-editor-margin-x)", filterOperatorPaddingY: "var(--infinite-filter-operator-padding-y)", filterEditorPaddingY: "var(--infinite-filter-editor-padding-y)", filterEditorMarginY: "var(--infinite-filter-editor-margin-y)", filterEditorBackground: "var(--infinite-filter-editor-background)", filterEditorBorder: "var(--infinite-filter-editor-border)", filterEditorFocusBorderColor: "var(--infinite-filter-editor-focus-border-color)", filterEditorBorderRadius: "var(--infinite-filter-editor-border-radius)", filterEditorColor: "var(--infinite-filter-editor-color)" }, ActiveCellIndicator: { inset: "var(--infinite-active-cell-indicator-inset)" }, Cell: { padding: "var(--infinite-cell-padding)", borderWidth: "var(--infinite-cell-border-width)", border: "var(--infinite-cell-border)", borderLeft: "var(--infinite-cell-border-left)", borderRight: "var(--infinite-cell-border-right)", borderTop: "var(--infinite-cell-border-top)", borderInvisible: "var(--infinite-cell-border-invisible)", borderRadius: "var(--infinite-cell-border-radius)", reorderEffectDuration: "var(--infinite-column-reorder-effect-duration)", pinnedBorder: "var(--infinite-pinned-cell-border)", color: "var(--infinite-cell-color)", selectedBackground: "var(--infinite-selected-cell-background)", selectedBackgroundDefault: "var(--infinite-selected-cell-background-default)", selectedBackgroundAlpha: "var(--infinite-selected-cell-background-alpha)", selectedBackgroundAlphaWhenTableUnfocused: "var(--infinite-selected-cell-background-alpha--table-unfocused)", selectedBorderColor: "var(--infinite-selected-cell-border-color)", selectedBorderWidth: "var(--infinite-selected-cell-border-width)", selectedBorderStyle: "var(--infinite-selected-cell-border-style)", selectedBorder: "var(--infinite-selected-cell-border)", activeBackgroundAlpha: "var(--infinite-active-cell-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-cell-background-alpha--table-unfocused)", activeBackground: "var(--infinite-active-cell-background)", activeBackgroundDefault: "var(--infinite-active-cell-background-default)", activeBorderColor: "var(--infinite-active-cell-border-color)", activeBorderWidth: "var(--infinite-active-cell-border-width)", activeBorderStyle: "var(--infinite-active-cell-border-style)", activeBorder: "var(--infinite-active-cell-border)" }, SelectionCheckBox: { marginInline: "var(--infinite-selection-checkbox-margin-inline)" }, Menu: { background: "var(--infinite-menu-background)", color: "var(--infinite-menu-color)", separatorColor: "var(--infinite-menu-separator-color)", padding: "var(--infinite-menu-padding)", cellPaddingVertical: "var(--infinite-menu-cell-padding-vertical)", cellPaddingHorizontal: "var(--infinite-menu-cell-padding-horizontal)", cellMarginVertical: "var(--infinite-menu-cell-margin-vertical)", itemDisabledBackground: "var(--infinite-menu-item-disabled-background)", itemActiveBackground: "var(--infinite-menu-item-active-background)", itemActiveOpacity: "var(--infinite-menu-item-active-opacity)", itemPressedOpacity: "var(--infinite-menu-item-pressed-opacity)", itemPressedBackground: "var(--infinite-menu-item-pressed-background)", itemDisabledOpacity: "var(--infinite-menu-item-disabled-opacity)", borderRadius: "var(--infinite-menu-border-radius)", shadowColor: "var(--infinite-menu-shadow-color)" }, RowDetail: { background: "var(--infinite-rowdetail-background)", padding: "var(--infinite-rowdetail-padding)", gridHeight: "var(--infinite-rowdetail-grid-height)" }, Row: { background: "var(--infinite-row-background)", oddBackground: "var(--infinite-row-odd-background)", disabledBackground: "var(--infinite-row-disabled-background)", oddDisabledBackground: "var(--infinite-row-odd-disabled-background)", selectedBackground: "var(--infinite-row-selected-background)", disabledOpacity: "var(--infinite-row-disabled-opacity)", activeBackground: "var(--infinite-active-row-background)", activeBorderColor: "var(--infinite-active-row-border-color)", activeBorderWidth: "var(--infinite-active-row-border-width)", activeBorderStyle: "var(--infinite-active-row-border-style)", activeBorder: "var(--infinite-active-row-border)", activeBackgroundAlpha: "var(--infinite-active-row-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-row-background-alpha--table-unfocused)", hoverBackground: "var(--infinite-row-hover-background)", selectedHoverBackground: "var(--infinite-row-selected-hover-background)", selectedDisabledBackground: "var(--infinite-row-selected-disabled-background)", groupRowBackground: "var(--infinite-group-row-background)", groupRowColumnNesting: "var(--infinite-group-row-column-nesting)", groupNesting: "var(--infinite-dont-override-group-row-nesting-length)", pointerEventsWhileScrolling: "var(--infinite-row-pointer-events-while-scrolling)" }, ColumnCell: { background: "var(--infinite-column-cell-bg-dont-override)" } } };
|
|
1377
|
+
var ThemeVars = { color: { accent: "var(--infinite-accent-color)", success: "var(--infinite-success-color)", error: "var(--infinite-error-color)", color: "var(--infinite-color)" }, spacing: { "0": "var(--infinite-space-0)", "1": "var(--infinite-space-1)", "2": "var(--infinite-space-2)", "3": "var(--infinite-space-3)", "4": "var(--infinite-space-4)", "5": "var(--infinite-space-5)", "6": "var(--infinite-space-6)", "7": "var(--infinite-space-7)", "8": "var(--infinite-space-8)", "9": "var(--infinite-space-9)", "10": "var(--infinite-space-10)" }, fontSize: { "0": "var(--infinite-font-size-0)", "1": "var(--infinite-font-size-1)", "2": "var(--infinite-font-size-2)", "3": "var(--infinite-font-size-3)", "4": "var(--infinite-font-size-4)", "5": "var(--infinite-font-size-5)", "6": "var(--infinite-font-size-6)", "7": "var(--infinite-font-size-7)" }, fontFamily: "var(--infinite-font-family)", minHeight: "var(--infinite-min-height)", borderRadius: "var(--infinite-border-radius)", background: "var(--infinite-background)", iconSize: "var(--infinite-icon-size)", runtime: { bodyWidth: "var(--infinite-runtime-body-content-width)", totalVisibleColumnsWidthValue: "var(--infinite-runtime-total-visible-columns-width)", totalVisibleColumnsWidthVar: "var(--infinite-runtime-total-visible-columns-width-var)", visibleColumnsCount: "var(--infinite-runtime-visible-columns-count)", browserScrollbarWidth: "var(--infinite-runtime-browser-scrollbar-width)" }, components: { LoadMask: { padding: "var(--infinite-load-mask-padding)", color: "var(--infinite-load-mask-color)", textBackground: "var(--infinite-load-mask-text-background)", overlayBackground: "var(--infinite-load-mask-overlay-background)", overlayOpacity: "var(--infinite-load-mask-overlay-opacity)", borderRadius: "var(--infinite-load-mask-border-radius)" }, Header: { background: "var(--infinite-header-background)", color: "var(--infinite-header-color)", columnHeaderHeight: "var(--infinite-column-header-height)" }, HeaderCell: { background: "var(--infinite-header-cell-background)", hoverBackground: "var(--infinite-header-cell-hover-background)", border: "var(--infinite-header-cell-border)", padding: "var(--infinite-header-cell-padding)", paddingX: "var(--infinite-header-cell-padding-x)", paddingY: "var(--infinite-header-cell-padding-y)", iconSize: "var(--infinite-header-cell-icon-size)", menuIconLineWidth: "var(--infinite-header-cell-menu-icon-line-width)", sortIconMargin: "var(--infinite-header-cell-sort-icon-margin)", borderRight: "var(--infinite-header-cell-border-right)", resizeHandleActiveAreaWidth: "var(--infinite-resize-handle-active-area-width)", resizeHandleWidth: "var(--infinite-resize-handle-width)", resizeHandleHoverBackground: "var(--infinite-resize-handle-hover-background)", resizeHandleConstrainedHoverBackground: "var(--infinite-resize-handle-constrained-hover-background)", filterOperatorPaddingX: "var(--infinite-filter-operator-padding-x)", filterEditorPaddingX: "var(--infinite-filter-editor-padding-x)", filterEditorMarginX: "var(--infinite-filter-editor-margin-x)", filterOperatorPaddingY: "var(--infinite-filter-operator-padding-y)", filterEditorPaddingY: "var(--infinite-filter-editor-padding-y)", filterEditorMarginY: "var(--infinite-filter-editor-margin-y)", filterEditorBackground: "var(--infinite-filter-editor-background)", filterEditorBorder: "var(--infinite-filter-editor-border)", filterEditorFocusBorderColor: "var(--infinite-filter-editor-focus-border-color)", filterEditorBorderRadius: "var(--infinite-filter-editor-border-radius)", filterEditorColor: "var(--infinite-filter-editor-color)" }, ActiveCellIndicator: { inset: "var(--infinite-active-cell-indicator-inset)" }, Cell: { flashingDuration: "var(--infinite-flashing-duration)", flashingAnimationName: "var(--infinite-flashing-animation-name)", flashingOverlayZIndex: "var(--infinite-flashing-overlay-z-index)", flashingBackground: "var(--infinite-flashing-background)", flashingUpBackground: "var(--infinite-flashing-up-background)", flashingDownBackground: "var(--infinite-flashing-down-background)", padding: "var(--infinite-cell-padding)", borderWidth: "var(--infinite-cell-border-width)", border: "var(--infinite-cell-border)", borderLeft: "var(--infinite-cell-border-left)", borderRight: "var(--infinite-cell-border-right)", borderTop: "var(--infinite-cell-border-top)", borderInvisible: "var(--infinite-cell-border-invisible)", borderRadius: "var(--infinite-cell-border-radius)", reorderEffectDuration: "var(--infinite-column-reorder-effect-duration)", pinnedBorder: "var(--infinite-pinned-cell-border)", color: "var(--infinite-cell-color)", selectedBackground: "var(--infinite-selected-cell-background)", selectedBackgroundDefault: "var(--infinite-selected-cell-background-default)", selectedBackgroundAlpha: "var(--infinite-selected-cell-background-alpha)", selectedBackgroundAlphaWhenTableUnfocused: "var(--infinite-selected-cell-background-alpha--table-unfocused)", selectedBorderColor: "var(--infinite-selected-cell-border-color)", selectedBorderWidth: "var(--infinite-selected-cell-border-width)", selectedBorderStyle: "var(--infinite-selected-cell-border-style)", selectedBorder: "var(--infinite-selected-cell-border)", activeBackgroundAlpha: "var(--infinite-active-cell-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-cell-background-alpha--table-unfocused)", activeBackground: "var(--infinite-active-cell-background)", activeBackgroundDefault: "var(--infinite-active-cell-background-default)", activeBorderColor: "var(--infinite-active-cell-border-color)", activeBorderWidth: "var(--infinite-active-cell-border-width)", activeBorderStyle: "var(--infinite-active-cell-border-style)", activeBorder: "var(--infinite-active-cell-border)" }, SelectionCheckBox: { marginInline: "var(--infinite-selection-checkbox-margin-inline)" }, Menu: { background: "var(--infinite-menu-background)", color: "var(--infinite-menu-color)", separatorColor: "var(--infinite-menu-separator-color)", padding: "var(--infinite-menu-padding)", cellPaddingVertical: "var(--infinite-menu-cell-padding-vertical)", cellPaddingHorizontal: "var(--infinite-menu-cell-padding-horizontal)", cellMarginVertical: "var(--infinite-menu-cell-margin-vertical)", itemDisabledBackground: "var(--infinite-menu-item-disabled-background)", itemActiveBackground: "var(--infinite-menu-item-active-background)", itemActiveOpacity: "var(--infinite-menu-item-active-opacity)", itemPressedOpacity: "var(--infinite-menu-item-pressed-opacity)", itemPressedBackground: "var(--infinite-menu-item-pressed-background)", itemDisabledOpacity: "var(--infinite-menu-item-disabled-opacity)", borderRadius: "var(--infinite-menu-border-radius)", shadowColor: "var(--infinite-menu-shadow-color)" }, RowDetail: { background: "var(--infinite-rowdetail-background)", padding: "var(--infinite-rowdetail-padding)", gridHeight: "var(--infinite-rowdetail-grid-height)" }, Row: { background: "var(--infinite-row-background)", oddBackground: "var(--infinite-row-odd-background)", disabledBackground: "var(--infinite-row-disabled-background)", oddDisabledBackground: "var(--infinite-row-odd-disabled-background)", selectedBackground: "var(--infinite-row-selected-background)", disabledOpacity: "var(--infinite-row-disabled-opacity)", activeBackground: "var(--infinite-active-row-background)", activeBorderColor: "var(--infinite-active-row-border-color)", activeBorderWidth: "var(--infinite-active-row-border-width)", activeBorderStyle: "var(--infinite-active-row-border-style)", activeBorder: "var(--infinite-active-row-border)", activeBackgroundAlpha: "var(--infinite-active-row-background-alpha)", activeBackgroundAlphaWhenTableUnfocused: "var(--infinite-active-row-background-alpha--table-unfocused)", hoverBackground: "var(--infinite-row-hover-background)", selectedHoverBackground: "var(--infinite-row-selected-hover-background)", selectedDisabledBackground: "var(--infinite-row-selected-disabled-background)", groupRowBackground: "var(--infinite-group-row-background)", groupRowColumnNesting: "var(--infinite-group-row-column-nesting)", groupNesting: "var(--infinite-dont-override-group-row-nesting-length)", pointerEventsWhileScrolling: "var(--infinite-row-pointer-events-while-scrolling)" }, ColumnCell: { background: "var(--infinite-column-cell-bg-dont-override)" } } };
|
|
1373
1378
|
var columnHeaderHeightName = "column-header-height";
|
|
1374
1379
|
|
|
1375
1380
|
// src/components/HeadlessTable/ReactHeadlessTableRenderer.tsx
|
|
@@ -1410,7 +1415,7 @@ function stripVar(cssVariableWithVarString) {
|
|
|
1410
1415
|
}
|
|
1411
1416
|
|
|
1412
1417
|
// src/components/InfiniteTable/internalVars.css.ts
|
|
1413
|
-
var InternalVars = { currentColumnTransformX: "var(--currentColumnTransformX__16hkbkc0)", y: "var(--y__16hkbkc1)", activeCellRowOffset: "var(--
|
|
1418
|
+
var InternalVars = { currentColumnTransformX: "var(--currentColumnTransformX__16hkbkc0)", y: "var(--y__16hkbkc1)", currentFlashingBackground: "var(--currentFlashingBackground__16hkbkc2)", currentFlashingDuration: "var(--currentFlashingDuration__16hkbkc3)", activeCellRowOffset: "var(--activeCellRowOffset__16hkbkc4)", activeCellRowOffsetX: "var(--activeCellRowOffsetX__16hkbkc5)", activeCellRowHeight: "var(--activeCellRowHeight__16hkbkc6)", activeCellOffsetX: "var(--activeCellOffsetX__16hkbkc7)", activeCellOffsetY: "var(--activeCellOffsetY__16hkbkc8)", scrollTopForActiveRow: "var(--scrollTopForActiveRow__16hkbkc9)", scrollLeftForActiveRowWhenHorizontalLayout: "var(--scrollLeftForActiveRowWhenHorizontalLayout__16hkbkca)", activeCellColWidth: "var(--activeCellColWidth__16hkbkcb)", activeCellColOffset: "var(--activeCellColOffset__16hkbkcc)", columnReorderEffectDurationAtIndex: "var(--columnReorderEffectDurationAtIndex__16hkbkcd)", columnWidthAtIndex: "var(--columnWidthAtIndex__16hkbkce)", columnOffsetAtIndex: "var(--columnOffsetAtIndex__16hkbkcf)", columnOffsetAtIndexWhileReordering: "var(--columnOffsetAtIndexWhileReordering__16hkbkcg)", columnZIndexAtIndex: "var(--columnZIndexAtIndex__16hkbkch)", pinnedStartWidth: "var(--pinnedStartWidth__16hkbkci)", pinnedEndWidth: "var(--pinnedEndWidth__16hkbkcj)", pinnedEndOffset: "var(--pinnedEndOffset__16hkbkck)", computedVisibleColumnsCount: "var(--computedVisibleColumnsCount__16hkbkcl)", baseZIndexForCells: "var(--baseZIndexForCells__16hkbkcm)", bodyWidth: "var(--bodyWidth__16hkbkcn)", bodyHeight: "var(--bodyHeight__16hkbkco)", scrollbarWidthHorizontal: "var(--scrollbarWidthHorizontal__16hkbkcp)", scrollbarWidthVertical: "var(--scrollbarWidthVertical__16hkbkcq)", scrollLeft: "var(--scrollLeft__16hkbkcr)", scrollTop: "var(--scrollTop__16hkbkcs)" };
|
|
1414
1419
|
|
|
1415
1420
|
// src/utils/selectParent.ts
|
|
1416
1421
|
function selectParent(el, selector2) {
|
|
@@ -8124,8 +8129,9 @@ function objectValuesExcept(obj, exceptList) {
|
|
|
8124
8129
|
|
|
8125
8130
|
// src/components/InfiniteTable/components/cell.css.ts
|
|
8126
8131
|
var ColumnCellCls = "cell_ColumnCellCls__1eexc2a6 cell_CellCls__1eexc2a5 utilities_display_flex__16lm1iwz utilities_flexFlow_row__16lm1iw1o utilities_alignItems_center__16lm1iw1q utilities_position_absolute__16lm1iw2 utilities_willChange_transform__16lm1iw22 utilities_whiteSpace_nowrap__16lm1iw23 utilities_userSelect_none__16lm1iw17";
|
|
8127
|
-
var ColumnCellRecipe = createRuntimeFn({ defaultClassName: "
|
|
8128
|
-
var ColumnCellSelectionIndicatorRecipe = createRuntimeFn({ defaultClassName: "
|
|
8132
|
+
var ColumnCellRecipe = createRuntimeFn({ defaultClassName: "cell_ColumnCellRecipe__1eexc2am", variantClassNames: { dragging: { false: "cell_ColumnCellRecipe_dragging_false__1eexc2an", true: "cell_ColumnCellRecipe_dragging_true__1eexc2ao" }, cellSelected: { false: "cell_ColumnCellRecipe_cellSelected_false__1eexc2ap", true: "cell_ColumnCellRecipe_cellSelected_true__1eexc2aq" }, align: { start: "cell_ColumnCellRecipe_align_start__1eexc2ar", end: "cell_ColumnCellRecipe_align_end__1eexc2as", center: "cell_ColumnCellRecipe_align_center__1eexc2at" }, verticalAlign: { start: "cell_ColumnCellRecipe_verticalAlign_start__1eexc2au", end: "cell_ColumnCellRecipe_verticalAlign_end__1eexc2av", center: "cell_ColumnCellRecipe_verticalAlign_center__1eexc2aw" }, rowActive: { false: "cell_ColumnCellRecipe_rowActive_false__1eexc2ax", true: "cell_ColumnCellRecipe_rowActive_true__1eexc2ay" }, groupRow: { false: "cell_ColumnCellRecipe_groupRow_false__1eexc2az", true: "cell_ColumnCellRecipe_groupRow_true__1eexc2a10" }, groupCell: { false: "cell_ColumnCellRecipe_groupCell_false__1eexc2a11", true: "cell_ColumnCellRecipe_groupCell_true__1eexc2a12" }, rowDisabled: { false: "cell_ColumnCellRecipe_rowDisabled_false__1eexc2a13", true: "cell_ColumnCellRecipe_rowDisabled_true__1eexc2a14" }, zebra: { false: "cell_ColumnCellRecipe_zebra_false__1eexc2a15", even: "cell_ColumnCellRecipe_zebra_even__1eexc2a16", odd: "cell_ColumnCellRecipe_zebra_odd__1eexc2a17" }, rowSelected: { true: "cell_ColumnCellRecipe_rowSelected_true__1eexc2a18", false: "cell_ColumnCellRecipe_rowSelected_false__1eexc2a19", null: "cell_ColumnCellRecipe_rowSelected_null__1eexc2a1a" }, first: { true: "cell_ColumnCellRecipe_first_true__1eexc2a1b", false: "cell_ColumnCellRecipe_first_false__1eexc2a1c" }, last: { true: "cell_ColumnCellRecipe_last_true__1eexc2a1d", false: "cell_ColumnCellRecipe_last_false__1eexc2a1e" }, groupByField: { true: "cell_ColumnCellRecipe_groupByField_true__1eexc2a1f", false: "cell_ColumnCellRecipe_groupByField_false__1eexc2a1g" }, firstInCategory: { true: "cell_ColumnCellRecipe_firstInCategory_true__1eexc2a1h", false: "cell_ColumnCellRecipe_firstInCategory_false__1eexc2a1i" }, firstRow: { true: "cell_ColumnCellRecipe_firstRow_true__1eexc2a1j", false: "cell_ColumnCellRecipe_firstRow_false__1eexc2a1k" }, firstRowInHorizontalLayoutPage: { true: "cell_ColumnCellRecipe_firstRowInHorizontalLayoutPage_true__1eexc2a1l", false: "cell_ColumnCellRecipe_firstRowInHorizontalLayoutPage_false__1eexc2a1m" }, lastInCategory: { true: "cell_ColumnCellRecipe_lastInCategory_true__1eexc2a1n", false: "cell_ColumnCellRecipe_lastInCategory_false__1eexc2a1o" }, pinned: { start: "cell_ColumnCellRecipe_pinned_start__1eexc2a1p", end: "cell_ColumnCellRecipe_pinned_end__1eexc2a1q", false: "cell_ColumnCellRecipe_pinned_false__1eexc2a1r" }, filtered: { true: "cell_ColumnCellRecipe_filtered_true__1eexc2a1s", false: "cell_ColumnCellRecipe_filtered_false__1eexc2a1t" } }, defaultVariants: {}, compoundVariants: [[{ firstRowInHorizontalLayoutPage: true, firstRow: false }, "cell_ColumnCellRecipe_compound_0__1eexc2a1u"], [{ pinned: "start", lastInCategory: true }, "cell_ColumnCellRecipe_compound_1__1eexc2a1v"], [{ pinned: "start", firstInCategory: true }, "cell_ColumnCellRecipe_compound_2__1eexc2a1w"], [{ pinned: "end", firstInCategory: true }, "cell_ColumnCellRecipe_compound_3__1eexc2a1x"], [{ pinned: "end", lastInCategory: true }, "cell_ColumnCellRecipe_compound_4__1eexc2a1y"], [{ align: "center", groupCell: false }, "cell_ColumnCellRecipe_compound_5__1eexc2a1z"], [{ rowDisabled: true, zebra: "odd" }, "cell_ColumnCellRecipe_compound_6__1eexc2a20"]] });
|
|
8133
|
+
var ColumnCellSelectionIndicatorRecipe = createRuntimeFn({ defaultClassName: "cell_ColumnCellSelectionIndicatorRecipe__1eexc2ad", variantClassNames: { right: { true: "cell_ColumnCellSelectionIndicatorRecipe_right_true__1eexc2ae", false: "cell_ColumnCellSelectionIndicatorRecipe_right_false__1eexc2af" }, left: { true: "cell_ColumnCellSelectionIndicatorRecipe_left_true__1eexc2ag", false: "cell_ColumnCellSelectionIndicatorRecipe_left_false__1eexc2ah" }, top: { true: "cell_ColumnCellSelectionIndicatorRecipe_top_true__1eexc2ai", false: "cell_ColumnCellSelectionIndicatorRecipe_top_false__1eexc2aj" }, bottom: { true: "cell_ColumnCellSelectionIndicatorRecipe_bottom_true__1eexc2ak", false: "cell_ColumnCellSelectionIndicatorRecipe_bottom_false__1eexc2al" } }, defaultVariants: {}, compoundVariants: [] });
|
|
8134
|
+
var FlashingColumnCellRecipe = createRuntimeFn({ defaultClassName: "cell_FlashingColumnCellRecipe__1eexc2a9", variantClassNames: { direction: { up: "cell_FlashingColumnCellRecipe_direction_up__1eexc2aa", down: "cell_FlashingColumnCellRecipe_direction_down__1eexc2ab", neutral: "cell_FlashingColumnCellRecipe_direction_neutral__1eexc2ac" } }, defaultVariants: {}, compoundVariants: [] });
|
|
8129
8135
|
var SelectionCheckboxCls = "cell_SelectionCheckboxCls__1eexc2a7";
|
|
8130
8136
|
|
|
8131
8137
|
// src/components/InfiniteTable/components/CheckBox.tsx
|
|
@@ -18405,6 +18411,8 @@ function initSetupState2({
|
|
|
18405
18411
|
cellContextMenu: buildSubscriptionCallback(),
|
|
18406
18412
|
contextMenu: buildSubscriptionCallback(),
|
|
18407
18413
|
onFilterOperatorMenuClick: buildSubscriptionCallback(),
|
|
18414
|
+
flashingDurationCSSVarValue: null,
|
|
18415
|
+
onFlashingDurationCSSVarChange: buildSubscriptionCallback(),
|
|
18408
18416
|
onRowHeightCSSVarChange: buildSubscriptionCallback(),
|
|
18409
18417
|
onRowDetailHeightCSSVarChange: buildSubscriptionCallback(),
|
|
18410
18418
|
onColumnHeaderHeightCSSVarChange: buildSubscriptionCallback(),
|
|
@@ -18558,6 +18566,7 @@ var cleanupState = (state) => {
|
|
|
18558
18566
|
state.headerBrain.destroy();
|
|
18559
18567
|
state.renderer.destroy();
|
|
18560
18568
|
state.onRenderUpdater.destroy();
|
|
18569
|
+
state.onFlashingDurationCSSVarChange.destroy();
|
|
18561
18570
|
state.onRowHeightCSSVarChange.destroy();
|
|
18562
18571
|
state.onColumnHeaderHeightCSSVarChange.destroy();
|
|
18563
18572
|
state.onColumnMenuClick.destroy();
|
|
@@ -19514,6 +19523,14 @@ function useComputed() {
|
|
|
19514
19523
|
componentActions.rowHeight = rowHeight2;
|
|
19515
19524
|
}
|
|
19516
19525
|
});
|
|
19526
|
+
componentState.onFlashingDurationCSSVarChange.onChange(
|
|
19527
|
+
(flashingDuration) => {
|
|
19528
|
+
const num = flashingDuration ? flashingDuration * 1 : null;
|
|
19529
|
+
if (num != null && !isNaN(num)) {
|
|
19530
|
+
componentActions.flashingDurationCSSVarValue = num;
|
|
19531
|
+
}
|
|
19532
|
+
}
|
|
19533
|
+
);
|
|
19517
19534
|
componentState.onRowDetailHeightCSSVarChange.onChange((rowDetailHeight2) => {
|
|
19518
19535
|
if (rowDetailHeight2) {
|
|
19519
19536
|
componentActions.rowDetailHeight = rowDetailHeight2;
|
|
@@ -19838,7 +19855,7 @@ var useLicense = (licenseKey = "") => {
|
|
|
19838
19855
|
}
|
|
19839
19856
|
let valid2 = isValidLicense(licenseKey, {
|
|
19840
19857
|
publishedAt: 1624970570587,
|
|
19841
|
-
version: "5.0.0-canary.
|
|
19858
|
+
version: "5.0.0-canary.4"
|
|
19842
19859
|
});
|
|
19843
19860
|
if (!licenseKey && !valid2 && isInsidePlayground) {
|
|
19844
19861
|
return true;
|
|
@@ -23741,6 +23758,7 @@ var InfiniteTableComponent = React68.memo(
|
|
|
23741
23758
|
domRef,
|
|
23742
23759
|
portalDOMRef,
|
|
23743
23760
|
onRowHeightCSSVarChange,
|
|
23761
|
+
onFlashingDurationCSSVarChange,
|
|
23744
23762
|
onRowDetailHeightCSSVarChange,
|
|
23745
23763
|
onColumnHeaderHeightCSSVarChange,
|
|
23746
23764
|
rowHeightCSSVar,
|
|
@@ -23831,18 +23849,29 @@ var InfiniteTableComponent = React68.memo(
|
|
|
23831
23849
|
), rowHeightCSSVar ? /* @__PURE__ */ React68.createElement(
|
|
23832
23850
|
CSSNumericVariableWatch,
|
|
23833
23851
|
{
|
|
23852
|
+
key: "row-height",
|
|
23834
23853
|
varName: rowHeightCSSVar,
|
|
23835
23854
|
onChange: onRowHeightCSSVarChange
|
|
23836
23855
|
}
|
|
23837
|
-
) : null,
|
|
23856
|
+
) : null, /* @__PURE__ */ React68.createElement(
|
|
23857
|
+
CSSNumericVariableWatch,
|
|
23858
|
+
{
|
|
23859
|
+
key: "flashing-duration",
|
|
23860
|
+
allowInts: true,
|
|
23861
|
+
varName: ThemeVars.components.Cell.flashingDuration,
|
|
23862
|
+
onChange: onFlashingDurationCSSVarChange
|
|
23863
|
+
}
|
|
23864
|
+
), rowDetailHeightCSSVar ? /* @__PURE__ */ React68.createElement(
|
|
23838
23865
|
CSSNumericVariableWatch,
|
|
23839
23866
|
{
|
|
23867
|
+
key: "row-detail-height",
|
|
23840
23868
|
varName: rowDetailHeightCSSVar,
|
|
23841
23869
|
onChange: onRowDetailHeightCSSVarChange
|
|
23842
23870
|
}
|
|
23843
23871
|
) : null, columnHeaderHeightCSSVar ? /* @__PURE__ */ React68.createElement(
|
|
23844
23872
|
CSSNumericVariableWatch,
|
|
23845
23873
|
{
|
|
23874
|
+
key: "column-header-height",
|
|
23846
23875
|
varName: columnHeaderHeightCSSVar,
|
|
23847
23876
|
onChange: onColumnHeaderHeightCSSVarChange
|
|
23848
23877
|
}
|
|
@@ -24340,6 +24369,157 @@ var _WeakFixedSizeSet = class {
|
|
|
24340
24369
|
var WeakFixedSizeSet = _WeakFixedSizeSet;
|
|
24341
24370
|
WeakFixedSizeSet.DEFAULT_SIZE = 10;
|
|
24342
24371
|
|
|
24372
|
+
// src/components/hooks/useEffectWhenSameDeps.ts
|
|
24373
|
+
var import_react67 = require("react");
|
|
24374
|
+
var isSameDeps = (deps, prevDeps) => {
|
|
24375
|
+
return deps.every((dep, index) => dep === prevDeps[index]);
|
|
24376
|
+
};
|
|
24377
|
+
var useEffectWhenSameDeps = (callback, deps) => {
|
|
24378
|
+
const depsRef = (0, import_react67.useRef)(deps);
|
|
24379
|
+
const sameDeps = isSameDeps(deps, depsRef.current);
|
|
24380
|
+
const isInitialRef = (0, import_react67.useRef)(true);
|
|
24381
|
+
depsRef.current = deps;
|
|
24382
|
+
const effectDepsRef = (0, import_react67.useRef)(["same"]);
|
|
24383
|
+
const effectDeps = sameDeps ? [Date.now()] : effectDepsRef.current;
|
|
24384
|
+
effectDepsRef.current = effectDeps;
|
|
24385
|
+
const callbackRef = (0, import_react67.useRef)(callback);
|
|
24386
|
+
callbackRef.current = callback;
|
|
24387
|
+
(0, import_react67.useEffect)(() => {
|
|
24388
|
+
if (isInitialRef.current) {
|
|
24389
|
+
isInitialRef.current = false;
|
|
24390
|
+
return;
|
|
24391
|
+
}
|
|
24392
|
+
return callbackRef.current();
|
|
24393
|
+
}, effectDeps);
|
|
24394
|
+
};
|
|
24395
|
+
|
|
24396
|
+
// src/components/hooks/useEffectWhen.ts
|
|
24397
|
+
var import_react68 = require("react");
|
|
24398
|
+
var isSameDeps2 = (deps, prevDeps, compare) => {
|
|
24399
|
+
return deps.every((dep, index) => {
|
|
24400
|
+
if (compare) {
|
|
24401
|
+
return compare(dep, prevDeps[index]);
|
|
24402
|
+
}
|
|
24403
|
+
return dep === prevDeps[index];
|
|
24404
|
+
});
|
|
24405
|
+
};
|
|
24406
|
+
var useEffectWhen = (callback, options) => {
|
|
24407
|
+
const { same: depsForSame, different: depsForDifferent, compare } = options;
|
|
24408
|
+
const sameDepsRef = (0, import_react68.useRef)(depsForSame);
|
|
24409
|
+
const differentDepsRef = (0, import_react68.useRef)(depsForDifferent);
|
|
24410
|
+
const sameRespected = isSameDeps2(depsForSame, sameDepsRef.current, compare);
|
|
24411
|
+
const differentRespected = !isSameDeps2(
|
|
24412
|
+
depsForDifferent,
|
|
24413
|
+
differentDepsRef.current,
|
|
24414
|
+
compare
|
|
24415
|
+
);
|
|
24416
|
+
const isInitialRef = (0, import_react68.useRef)(true);
|
|
24417
|
+
sameDepsRef.current = depsForSame;
|
|
24418
|
+
differentDepsRef.current = depsForDifferent;
|
|
24419
|
+
const effectDepsRef = (0, import_react68.useRef)(["same"]);
|
|
24420
|
+
const effectDeps = sameRespected && differentRespected ? [Date.now()] : effectDepsRef.current;
|
|
24421
|
+
effectDepsRef.current = effectDeps;
|
|
24422
|
+
const callbackRef = (0, import_react68.useRef)(callback);
|
|
24423
|
+
callbackRef.current = callback;
|
|
24424
|
+
if (sameRespected && differentRespected) {
|
|
24425
|
+
isInitialRef.current = false;
|
|
24426
|
+
}
|
|
24427
|
+
(0, import_react68.useEffect)(() => {
|
|
24428
|
+
if (isInitialRef.current) {
|
|
24429
|
+
return;
|
|
24430
|
+
}
|
|
24431
|
+
return callbackRef.current();
|
|
24432
|
+
}, effectDeps);
|
|
24433
|
+
};
|
|
24434
|
+
|
|
24435
|
+
// src/components/InfiniteTable/components/InfiniteTableRow/FlashingColumnCell.tsx
|
|
24436
|
+
var React69 = __toESM(require("react"));
|
|
24437
|
+
var currentFlashingDurationVar = stripVar(
|
|
24438
|
+
InternalVars.currentFlashingDuration
|
|
24439
|
+
);
|
|
24440
|
+
var defaultRender = ({ children }) => {
|
|
24441
|
+
return /* @__PURE__ */ React69.createElement(React69.Fragment, null, children);
|
|
24442
|
+
};
|
|
24443
|
+
var DEFAULT_FLASH_DURATION = 1e3;
|
|
24444
|
+
var createFlashingColumnCellComponent = (options = {}) => {
|
|
24445
|
+
const {
|
|
24446
|
+
flashDuration: FLASH_DURATION,
|
|
24447
|
+
// fadeDuration,
|
|
24448
|
+
flashClassName,
|
|
24449
|
+
// fadeClassName,
|
|
24450
|
+
render = defaultRender
|
|
24451
|
+
} = options;
|
|
24452
|
+
const FlashingColumnCell2 = React69.forwardRef(
|
|
24453
|
+
(props, _ref) => {
|
|
24454
|
+
var _a;
|
|
24455
|
+
const cellContext = useInfiniteColumnCell();
|
|
24456
|
+
const {
|
|
24457
|
+
state: { flashingDurationCSSVarValue }
|
|
24458
|
+
} = useInfiniteTable();
|
|
24459
|
+
const duration = typeof flashingDurationCSSVarValue === "number" ? (_a = flashingDurationCSSVarValue != null ? flashingDurationCSSVarValue : FLASH_DURATION) != null ? _a : DEFAULT_FLASH_DURATION : FLASH_DURATION != null ? FLASH_DURATION : DEFAULT_FLASH_DURATION;
|
|
24460
|
+
const { domRef, value, column, rowInfo, htmlElementRef } = cellContext;
|
|
24461
|
+
const rowId = rowInfo.id;
|
|
24462
|
+
const columnId = column.id;
|
|
24463
|
+
const initialRef = React69.useRef(true);
|
|
24464
|
+
const oldValueRef = React69.useRef(value);
|
|
24465
|
+
const oldValue = initialRef.current ? null : oldValueRef.current;
|
|
24466
|
+
initialRef.current = false;
|
|
24467
|
+
const flashTimeoutIdRef = React69.useRef();
|
|
24468
|
+
const fadeTimeoutIdRef = React69.useRef();
|
|
24469
|
+
useEffectWhen(
|
|
24470
|
+
() => {
|
|
24471
|
+
if (value === oldValueRef.current) {
|
|
24472
|
+
return;
|
|
24473
|
+
}
|
|
24474
|
+
if (flashTimeoutIdRef.current) {
|
|
24475
|
+
clearTimeout(flashTimeoutIdRef.current);
|
|
24476
|
+
}
|
|
24477
|
+
if (fadeTimeoutIdRef.current) {
|
|
24478
|
+
clearTimeout(fadeTimeoutIdRef.current);
|
|
24479
|
+
}
|
|
24480
|
+
const el = htmlElementRef.current;
|
|
24481
|
+
oldValueRef.current = value;
|
|
24482
|
+
if (!el) {
|
|
24483
|
+
return;
|
|
24484
|
+
}
|
|
24485
|
+
const flashDirection = typeof value === "number" ? value > oldValue ? "up" : "down" : "neutral";
|
|
24486
|
+
const internalflashCls = FlashingColumnCellRecipe({
|
|
24487
|
+
direction: flashDirection
|
|
24488
|
+
}).split(" ");
|
|
24489
|
+
el.style.setProperty(currentFlashingDurationVar, `${duration}`);
|
|
24490
|
+
if (flashClassName) {
|
|
24491
|
+
el.classList.add(flashClassName);
|
|
24492
|
+
}
|
|
24493
|
+
el.classList.add(...internalflashCls);
|
|
24494
|
+
flashTimeoutIdRef.current = setTimeout(() => {
|
|
24495
|
+
flashTimeoutIdRef.current = void 0;
|
|
24496
|
+
if (flashClassName) {
|
|
24497
|
+
el.classList.remove(flashClassName);
|
|
24498
|
+
}
|
|
24499
|
+
el.classList.remove(...internalflashCls);
|
|
24500
|
+
el.style.removeProperty(currentFlashingDurationVar);
|
|
24501
|
+
}, duration);
|
|
24502
|
+
return () => {
|
|
24503
|
+
if (flashTimeoutIdRef.current) {
|
|
24504
|
+
clearTimeout(flashTimeoutIdRef.current);
|
|
24505
|
+
}
|
|
24506
|
+
if (fadeTimeoutIdRef.current) {
|
|
24507
|
+
clearTimeout(fadeTimeoutIdRef.current);
|
|
24508
|
+
}
|
|
24509
|
+
};
|
|
24510
|
+
},
|
|
24511
|
+
{
|
|
24512
|
+
same: [columnId, rowId],
|
|
24513
|
+
different: [value]
|
|
24514
|
+
}
|
|
24515
|
+
);
|
|
24516
|
+
return /* @__PURE__ */ React69.createElement("div", __spreadProps(__spreadValues({ ref: domRef }, props), { className: join(props.className) }), render({ children: props.children, oldValue }));
|
|
24517
|
+
}
|
|
24518
|
+
);
|
|
24519
|
+
return FlashingColumnCell2;
|
|
24520
|
+
};
|
|
24521
|
+
var FlashingColumnCell = createFlashingColumnCellComponent();
|
|
24522
|
+
|
|
24343
24523
|
// src/index.tsx
|
|
24344
24524
|
var components = {
|
|
24345
24525
|
CheckBox: InfiniteCheckBox,
|
|
@@ -24356,6 +24536,7 @@ var components = {
|
|
|
24356
24536
|
DataSourceActionType,
|
|
24357
24537
|
DeepMap,
|
|
24358
24538
|
FixedSizeSet,
|
|
24539
|
+
FlashingColumnCell,
|
|
24359
24540
|
GroupRowsState,
|
|
24360
24541
|
InfiniteTable,
|
|
24361
24542
|
InfiniteTableClassName,
|
|
@@ -24367,6 +24548,7 @@ var components = {
|
|
|
24367
24548
|
RowSelectionState,
|
|
24368
24549
|
WeakFixedSizeSet,
|
|
24369
24550
|
components,
|
|
24551
|
+
createFlashingColumnCellComponent,
|
|
24370
24552
|
debounce,
|
|
24371
24553
|
debug,
|
|
24372
24554
|
defaultFilterTypes,
|
|
@@ -24382,6 +24564,8 @@ var components = {
|
|
|
24382
24564
|
useComponentState,
|
|
24383
24565
|
useDataSourceInternal,
|
|
24384
24566
|
useDataSourceState,
|
|
24567
|
+
useEffectWhen,
|
|
24568
|
+
useEffectWhenSameDeps,
|
|
24385
24569
|
useEffectWithChanges,
|
|
24386
24570
|
useEffectWithObject,
|
|
24387
24571
|
useGridScroll,
|
|
@@ -24393,6 +24577,7 @@ var components = {
|
|
|
24393
24577
|
useMasterRowInfo,
|
|
24394
24578
|
useOverlay,
|
|
24395
24579
|
useOverlayPortal,
|
|
24580
|
+
usePrevious,
|
|
24396
24581
|
useRowInfoReducers,
|
|
24397
24582
|
useVisibleColumnSizes
|
|
24398
24583
|
});
|