@revolist/revogrid 4.23.6 → 4.23.8

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.
Files changed (29) hide show
  1. package/dist/cjs/{column.drag.plugin-yUSx3qoN.js → column.drag.plugin-CHyc9aCK.js} +32 -3
  2. package/dist/cjs/index.cjs.js +2 -1
  3. package/dist/cjs/revo-grid.cjs.entry.js +1 -1
  4. package/dist/cjs/revogr-data_4.cjs.entry.js +10 -2
  5. package/dist/cjs/revogr-filter-panel.cjs.entry.js +2 -2
  6. package/dist/collection/components/scroll/revogr-viewport-scroll.js +10 -2
  7. package/dist/collection/plugins/filter/filter.panel.js +2 -2
  8. package/dist/collection/plugins/filter/filter.plugin.js +1 -1
  9. package/dist/collection/plugins/moveColumn/column.drag.plugin.js +30 -2
  10. package/dist/esm/{column.drag.plugin-Cg2U-91C.js → column.drag.plugin-DEKk4rrp.js} +32 -4
  11. package/dist/esm/index.js +2 -2
  12. package/dist/esm/revo-grid.entry.js +1 -1
  13. package/dist/esm/revogr-data_4.entry.js +10 -2
  14. package/dist/esm/revogr-filter-panel.entry.js +2 -2
  15. package/dist/revo-grid/{column.drag.plugin-Cg2U-91C.js → column.drag.plugin-DEKk4rrp.js} +32 -4
  16. package/dist/revo-grid/index.esm.js +2 -2
  17. package/dist/revo-grid/revo-grid.entry.js +1 -1
  18. package/dist/revo-grid/revogr-data_4.entry.js +10 -2
  19. package/dist/revo-grid/revogr-filter-panel.entry.js +2 -2
  20. package/dist/types/plugins/filter/filter.plugin.d.ts +1 -0
  21. package/dist/types/plugins/filter/filter.types.d.ts +1 -0
  22. package/dist/types/plugins/moveColumn/column.drag.plugin.d.ts +4 -0
  23. package/hydrate/index.js +43 -7
  24. package/hydrate/index.mjs +43 -7
  25. package/package.json +1 -1
  26. package/standalone/index.js +1 -1
  27. package/standalone/revo-grid.js +1 -1
  28. package/standalone/revogr-filter-panel.js +1 -1
  29. package/standalone/revogr-viewport-scroll2.js +1 -1
@@ -1416,7 +1416,7 @@ class FilterPlugin extends BasePlugin {
1416
1416
  // filter button clicked, open filter dialog
1417
1417
  const gridPos = this.revogrid.getBoundingClientRect();
1418
1418
  const buttonPos = el.getBoundingClientRect();
1419
- const data = Object.assign(Object.assign(Object.assign({}, e.detail), this.filterCollection[prop]), { x: buttonPos.x - gridPos.x, y: buttonPos.y - gridPos.y + buttonPos.height, autoCorrect: true, filterTypes: this.getColumnFilter(e.detail.filter), filterItems: this.multiFilterItems, extraContent: this.extraHyperContent });
1419
+ const data = Object.assign(Object.assign(Object.assign({}, e.detail), this.filterCollection[prop]), { x: buttonPos.x - gridPos.x, y: buttonPos.y - gridPos.y + buttonPos.height, autoCorrect: true, filterTypes: this.getColumnFilter(e.detail.filter), filterItems: this.multiFilterItems, extraContent: this.extraHyperContent, extraBottomContent: this.extraBottomHyperContent });
1420
1420
  (_b = this.beforeshow) === null || _b === void 0 ? void 0 : _b.call(this, data);
1421
1421
  this.pop.show(data);
1422
1422
  }
@@ -2670,8 +2670,17 @@ class ColumnMovePlugin extends BasePlugin {
2670
2670
  constructor(revogrid, providers) {
2671
2671
  super(revogrid, providers);
2672
2672
  this.moveFunc = debounce((e) => this.doMove(e), 5);
2673
+ this.preventHeaderClickAfterDrag = (event) => {
2674
+ if (!this.preventNextHeaderClick) {
2675
+ return;
2676
+ }
2677
+ this.preventNextHeaderClick = false;
2678
+ event.preventDefault();
2679
+ };
2673
2680
  this.staticDragData = null;
2674
2681
  this.dragData = null;
2682
+ this.columnDragMoved = false;
2683
+ this.preventNextHeaderClick = false;
2675
2684
  this.localSubscriptions = {};
2676
2685
  this.orderUi = new ColumnOrderHandler();
2677
2686
  revogrid.appendChild(this.orderUi.render());
@@ -2690,11 +2699,13 @@ class ColumnMovePlugin extends BasePlugin {
2690
2699
  callback: (e) => this.move(e),
2691
2700
  };
2692
2701
  this.addEventListener(COLUMN_CLICK, ({ detail }) => this.dragStart(detail));
2702
+ this.revogrid.addEventListener('beforeheaderclick', this.preventHeaderClickAfterDrag, { capture: true });
2693
2703
  }
2694
2704
  dragStart({ event, data }) {
2695
2705
  if (event.defaultPrevented) {
2696
2706
  return;
2697
2707
  }
2708
+ this.preventNextHeaderClick = false;
2698
2709
  const { defaultPrevented } = dispatch(this.revogrid, COLUMN_DRAG_START_EVENT, data);
2699
2710
  // check if allowed to drag particulat column
2700
2711
  if (defaultPrevented) {
@@ -2716,7 +2727,8 @@ class ColumnMovePlugin extends BasePlugin {
2716
2727
  const cols = this.getDimension(data.pin || 'rgCol');
2717
2728
  const gridRect = this.revogrid.getBoundingClientRect();
2718
2729
  const elRect = dataEl.getBoundingClientRect();
2719
- const startItem = getItemByPosition(cols, getLeftRelative(event.x, gridRect.left, elRect.left - gridRect.left) + (cols.renderOffset || 0));
2730
+ const startItem = getItemByPosition(cols, getLeftRelative(event.x, gridRect.left, elRect.left - gridRect.left) +
2731
+ (cols.renderOffset || 0));
2720
2732
  this.staticDragData = {
2721
2733
  startPos: event.x,
2722
2734
  startItem,
@@ -2747,10 +2759,14 @@ class ColumnMovePlugin extends BasePlugin {
2747
2759
  if (rgCol.itemIndex >= this.staticDragData.cols.count) {
2748
2760
  return;
2749
2761
  }
2750
- this.orderUi.showHandler(rgCol.end - (this.staticDragData.cols.renderOffset || 0) + dragData.scrollOffset, dragData.gridRect.width);
2762
+ this.orderUi.showHandler(getColumnDragPosition(rgCol, this.staticDragData.startItem, this.staticDragData.cols.renderOffset || 0, dragData.scrollOffset), dragData.gridRect.width);
2751
2763
  }
2752
2764
  }
2753
2765
  move(e) {
2766
+ if (this.staticDragData &&
2767
+ Math.abs(this.staticDragData.startPos - e.x) > 10) {
2768
+ this.columnDragMoved = true;
2769
+ }
2754
2770
  dispatch(this.revogrid, COLUMN_DRAG_MOVE_EVENT, e);
2755
2771
  // then do move
2756
2772
  this.moveFunc(e);
@@ -2759,6 +2775,7 @@ class ColumnMovePlugin extends BasePlugin {
2759
2775
  this.clearOrder();
2760
2776
  }
2761
2777
  onMouseUp(e) {
2778
+ const suppressClick = this.columnDragMoved;
2762
2779
  // apply new positions
2763
2780
  if (this.dragData && this.staticDragData) {
2764
2781
  let relativePos = getLeftRelative(e.x, this.dragData.gridRect.left, this.dragData.scrollOffset);
@@ -2781,6 +2798,9 @@ class ColumnMovePlugin extends BasePlugin {
2781
2798
  }
2782
2799
  dispatch(this.revogrid, COLUMN_DRAG_END_EVENT, this.getData(this.staticDragData, newItems, source));
2783
2800
  }
2801
+ if (suppressClick) {
2802
+ this.preventNextHeaderClick = !!e.target.closest('revogr-header');
2803
+ }
2784
2804
  this.clearOrder();
2785
2805
  }
2786
2806
  clearLocalSubscriptions() {
@@ -2789,6 +2809,7 @@ class ColumnMovePlugin extends BasePlugin {
2789
2809
  clearOrder() {
2790
2810
  this.staticDragData = null;
2791
2811
  this.dragData = null;
2812
+ this.columnDragMoved = false;
2792
2813
  this.clearLocalSubscriptions();
2793
2814
  this.orderUi.stop(this.revogrid);
2794
2815
  }
@@ -2798,6 +2819,7 @@ class ColumnMovePlugin extends BasePlugin {
2798
2819
  clearSubscriptions() {
2799
2820
  super.clearSubscriptions();
2800
2821
  this.clearLocalSubscriptions();
2822
+ this.revogrid.removeEventListener('beforeheaderclick', this.preventHeaderClickAfterDrag, { capture: true });
2801
2823
  }
2802
2824
  getData({ gridEl, dataEl, pin }, order, source = []) {
2803
2825
  const gridRect = gridEl.getBoundingClientRect();
@@ -2819,5 +2841,11 @@ class ColumnMovePlugin extends BasePlugin {
2819
2841
  function getLeftRelative(absoluteX, gridPos, offset) {
2820
2842
  return absoluteX - gridPos - offset;
2821
2843
  }
2844
+ function getColumnDragPosition(targetItem, startItem, renderOffset, scrollOffset) {
2845
+ const insertionEdge = startItem.itemIndex > targetItem.itemIndex
2846
+ ? targetItem.start
2847
+ : targetItem.end;
2848
+ return insertionEdge - renderOffset + scrollOffset;
2849
+ }
2822
2850
 
2823
- export { AutoSizeColumnPlugin as A, BasePlugin as B, ColumnAutoSizeMode as C, DimensionStore as D, ExportFilePlugin as E, FILTER_TRIMMED_TYPE as F, GroupingRowPlugin as G, SelectionStore as S, StretchColumn as a, ExportCsv as b, FILTER_CONFIG_CHANGED_EVENT as c, FILTE_PANEL as d, FilterPlugin as e, filterCoreFunctionsIndexedByType as f, filterTypes as g, filterNames as h, isStretchPlugin as i, doCollapse as j, doExpand as k, COLUMN_DRAG_MOVE_EVENT as l, COLUMN_DRAG_END_EVENT as m, BEFORE_COLUMN_DRAG_END_EVENT as n, COLUMN_DRAG_START_EVENT as o, ColumnMovePlugin as p, getLeftRelative as q, SortingPlugin as r, hasActiveSorting as s, getSortingIndex as t, sortIndexByItems as u, defaultCellCompare as v, descCellCompare as w, getNextOrder as x, getComparer as y };
2851
+ export { AutoSizeColumnPlugin as A, BasePlugin as B, ColumnAutoSizeMode as C, DimensionStore as D, ExportFilePlugin as E, FILTER_TRIMMED_TYPE as F, GroupingRowPlugin as G, SelectionStore as S, StretchColumn as a, ExportCsv as b, FILTER_CONFIG_CHANGED_EVENT as c, FILTE_PANEL as d, FilterPlugin as e, filterCoreFunctionsIndexedByType as f, filterTypes as g, filterNames as h, isStretchPlugin as i, doCollapse as j, doExpand as k, COLUMN_DRAG_MOVE_EVENT as l, COLUMN_DRAG_END_EVENT as m, BEFORE_COLUMN_DRAG_END_EVENT as n, COLUMN_DRAG_START_EVENT as o, ColumnMovePlugin as p, getLeftRelative as q, getColumnDragPosition as r, SortingPlugin as s, hasActiveSorting as t, getSortingIndex as u, sortIndexByItems as v, defaultCellCompare as w, descCellCompare as x, getNextOrder as y, getComparer as z };
@@ -2,8 +2,8 @@
2
2
  * Built by Revolist OU ❤️
3
3
  */
4
4
  export { o as GROUPING_ROW_TYPE, j as GROUP_COLUMN_PROP, G as GROUP_DEPTH, h as GROUP_EXPANDED, l as GROUP_EXPAND_BTN, m as GROUP_EXPAND_EVENT, k as GROUP_ORIGINAL_INDEX, f as PSEUDO_GROUP_COLUMN, P as PSEUDO_GROUP_ITEM, d as PSEUDO_GROUP_ITEM_ID, e as PSEUDO_GROUP_ITEM_VALUE, c as columnTypes, a as cropCellToMax, H as gatherGroup, s as gatherGrouping, z as getCellData, B as getCellDataParsed, A as getCellRaw, I as getColumnByProp, D as getColumnSizes, C as getColumnType, F as getColumns, q as getExpanded, t as getGroupingName, x as getParsedGroup, g as getRange, p as getSource, E as isColGrouping, u as isGrouping, v as isGroupingColumn, b as isRangeSingleCell, i as isRowType, y as isSameGroup, w as measureEqualDepth, n as nextCell, r as rowTypes } from './column.service-CC_SD8W3.js';
5
- import { B as BasePlugin } from './column.drag.plugin-Cg2U-91C.js';
6
- export { A as AutoSizeColumnPlugin, n as BEFORE_COLUMN_DRAG_END_EVENT, m as COLUMN_DRAG_END_EVENT, l as COLUMN_DRAG_MOVE_EVENT, o as COLUMN_DRAG_START_EVENT, C as ColumnAutoSizeMode, p as ColumnMovePlugin, D as DimensionStore, b as ExportCsv, E as ExportFilePlugin, c as FILTER_CONFIG_CHANGED_EVENT, F as FILTER_TRIMMED_TYPE, d as FILTE_PANEL, e as FilterPlugin, G as GroupingRowPlugin, S as SelectionStore, r as SortingPlugin, a as StretchColumn, v as defaultCellCompare, w as descCellCompare, j as doCollapse, k as doExpand, f as filterCoreFunctionsIndexedByType, h as filterNames, g as filterTypes, y as getComparer, q as getLeftRelative, x as getNextOrder, t as getSortingIndex, s as hasActiveSorting, i as isStretchPlugin, u as sortIndexByItems } from './column.drag.plugin-Cg2U-91C.js';
5
+ import { B as BasePlugin } from './column.drag.plugin-DEKk4rrp.js';
6
+ export { A as AutoSizeColumnPlugin, n as BEFORE_COLUMN_DRAG_END_EVENT, m as COLUMN_DRAG_END_EVENT, l as COLUMN_DRAG_MOVE_EVENT, o as COLUMN_DRAG_START_EVENT, C as ColumnAutoSizeMode, p as ColumnMovePlugin, D as DimensionStore, b as ExportCsv, E as ExportFilePlugin, c as FILTER_CONFIG_CHANGED_EVENT, F as FILTER_TRIMMED_TYPE, d as FILTE_PANEL, e as FilterPlugin, G as GroupingRowPlugin, S as SelectionStore, s as SortingPlugin, a as StretchColumn, w as defaultCellCompare, x as descCellCompare, j as doCollapse, k as doExpand, f as filterCoreFunctionsIndexedByType, h as filterNames, g as filterTypes, r as getColumnDragPosition, z as getComparer, q as getLeftRelative, y as getNextOrder, u as getSortingIndex, t as hasActiveSorting, i as isStretchPlugin, v as sortIndexByItems } from './column.drag.plugin-DEKk4rrp.js';
7
7
  export { d as dispatch, a as dispatchByEvent } from './header-cell-renderer-B-LX2sgu.js';
8
8
  export { C as CellRenderer, G as GroupingRowRenderer, S as SortingSign, e as expandEvent, a as expandSvgIconVNode } from './cell-renderer-BtN-NGCk.js';
9
9
  export { a as applyMixins, f as findPositionInArray, g as getScrollbarSize, m as mergeSortedArray, p as pushSorted, r as range, s as scaleValue, t as timeout } from './index-Db3qZoW5.js';
@@ -6,7 +6,7 @@ import { c as columnTypes, J as reduce, C as getColumnType, r as rowTypes, i as
6
6
  import { D as DataStore, b as getSourceItem, f as getSourceItemVirtualIndexByProp, d as setSourceByPhysicalIndex, s as setSourceByVirtualIndex, a as getVisibleSourceItem, h as gatherTrimmedItems, k as getItemByIndex, R as RESIZE_INTERVAL } from './dimension.helpers-CGKwSvw6.js';
7
7
  import { d as debounce } from './debounce-PCRWZliA.js';
8
8
  import { g as getScrollDimension, v as viewportDataPartition, F as FOOTER_SLOT, C as CONTENT_SLOT, H as HEADER_SLOT, D as DATA_SLOT } from './viewport.helpers-CoCAvmZs.js';
9
- import { D as DimensionStore, S as SelectionStore, B as BasePlugin, G as GroupingRowPlugin, a as StretchColumn, i as isStretchPlugin, A as AutoSizeColumnPlugin, e as FilterPlugin, E as ExportFilePlugin, r as SortingPlugin, p as ColumnMovePlugin } from './column.drag.plugin-Cg2U-91C.js';
9
+ import { D as DimensionStore, S as SelectionStore, B as BasePlugin, G as GroupingRowPlugin, a as StretchColumn, i as isStretchPlugin, A as AutoSizeColumnPlugin, e as FilterPlugin, E as ExportFilePlugin, s as SortingPlugin, p as ColumnMovePlugin } from './column.drag.plugin-DEKk4rrp.js';
10
10
  import { V as ViewportStore } from './viewport.store-_c579YyM.js';
11
11
  import { T as ThemeService } from './theme.service-BmnDvr6P.js';
12
12
  import { t as timeout } from './index-Db3qZoW5.js';
@@ -828,9 +828,17 @@ const RevogrViewportScroll = class {
828
828
  }
829
829
  render() {
830
830
  var _a, _b;
831
- const physicalContentHeight = getContentSize(this.contentHeight, (_b = (_a = this.verticalScroll) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0);
831
+ const clientHeight = (_b = (_a = this.verticalScroll) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0;
832
+ // When content fits in the viewport (no scroll needed), don't inflate content-wrapper
833
+ // to clientHeight — that would prevent inner-content-table from shrinking and push
834
+ // rowPinEnd (footer) to the bottom instead of letting it follow the data rows.
835
+ // For large/compressed grids (content > clientHeight), physicalContentHeight handles
836
+ // the browser scroll-size compression correctly.
837
+ const physicalContentHeight = this.contentHeight < clientHeight
838
+ ? Math.max(this.contentHeight, 0)
839
+ : getContentSize(this.contentHeight, clientHeight);
832
840
  const physicalContentWidth = getContentSize(this.contentWidth, 0);
833
- return (h(Host, { key: 'ec8d907976c1d50f7aab3c263be3f0249a274df6', onWheel: this.horizontalMouseWheel, onScroll: (e) => this.applyScroll('rgCol', e) }, h("div", { key: 'e35696a7993ac94261426b45c28d488cdc42b7f0', class: "inner-content-table", style: { width: `${physicalContentWidth}px` } }, h("div", { key: 'a6997451e01eacda1d27d4efa1d74e1748626218', class: "header-wrapper", ref: e => (this.header = e) }, h("slot", { key: '1d401e87d32d5b1531c2211723b552bbc894f22c', name: HEADER_SLOT })), h("div", { key: 'ceab6f9e812d6ca9a0aa376afcd2562a17f505e0', class: "vertical-inner", ref: el => (this.verticalScroll = el), onWheel: this.verticalMouseWheel, onScroll: (e) => this.applyScroll('rgRow', e) }, h("div", { key: 'a9556578a23d6efddec2e982e863aec064042154', class: "content-wrapper", style: { height: `${physicalContentHeight}px` } }, h("slot", { key: '0ae01f9736b9740612e75261f6e3abebda533377', name: CONTENT_SLOT }))), h("div", { key: '09c2565d4ed449a43820f92d97b6558fca3758e7', class: "footer-wrapper", ref: e => (this.footer = e) }, h("slot", { key: '1ffb08ff8138a560cc09d82e3fe22a53e502aafe', name: FOOTER_SLOT })))));
841
+ return (h(Host, { key: '3dd9d29cf26743d7aa4995f51180d56008526e54', onWheel: this.horizontalMouseWheel, onScroll: (e) => this.applyScroll('rgCol', e) }, h("div", { key: 'af75428e845044c33eba2fecd1ec04a9177b9b5c', class: "inner-content-table", style: { width: `${physicalContentWidth}px` } }, h("div", { key: 'a0149f597588371e1fafe69efc3bd4411379a017', class: "header-wrapper", ref: e => (this.header = e) }, h("slot", { key: 'e5d2570bf93897cd97ef702141c83bb8c0e13ee2', name: HEADER_SLOT })), h("div", { key: 'd1388ff0d721dd8ce925b934bb2128fddc1ac17b', class: "vertical-inner", ref: el => (this.verticalScroll = el), onWheel: this.verticalMouseWheel, onScroll: (e) => this.applyScroll('rgRow', e) }, h("div", { key: 'a306ff56f62279402e2a881a081e3224341d5bdf', class: "content-wrapper", style: { height: `${physicalContentHeight}px` } }, h("slot", { key: '898bda8e9429da06c9ff2bd41626ac27f3cde3cc', name: CONTENT_SLOT }))), h("div", { key: '5e9eba1edd5fca07a964971054a7900e4dd84099', class: "footer-wrapper", ref: e => (this.footer = e) }, h("slot", { key: 'f233ad1c23b3f692c45e1db235cfef4704a80726', name: FOOTER_SLOT })))));
834
842
  }
835
843
  /**
836
844
  * Extra layer for scroll event monitoring, where MouseWheel event is not passing
@@ -346,7 +346,7 @@ const FilterPanel = class {
346
346
  } }));
347
347
  }
348
348
  render() {
349
- var _a, _b, _c;
349
+ var _a, _b, _c, _d, _e;
350
350
  if (!this.changes) {
351
351
  return h(Host, { style: { display: 'none' } });
352
352
  }
@@ -363,7 +363,7 @@ const FilterPanel = class {
363
363
  h("label", null, capts.title),
364
364
  h("div", { class: "filter-holder" }, this.getFilterItemsList()),
365
365
  h("div", { class: "add-filter" }, h("select", { id: FILTER_ID, class: "select-css", onChange: e => this.onAddNewFilter(e) }, this.renderSelectOptions(this.currentFilterType)))
366
- ]), h("slot", null), h("div", { class: "filter-actions" }, this.disableDynamicFiltering && [
366
+ ]), h("slot", null), ((_e = (_d = this.changes).extraBottomContent) === null || _e === void 0 ? void 0 : _e.call(_d, this.changes)) || '', h("div", { class: "filter-actions" }, this.disableDynamicFiltering && [
367
367
  h("button", { id: "revo-button-save", "aria-label": "save", class: "revo-button green", onClick: () => this.onSave() }, capts.save),
368
368
  h("button", { id: "revo-button-ok", "aria-label": "ok", class: "revo-button green", onClick: () => this.onCancel() }, capts.cancel),
369
369
  ], !this.disableDynamicFiltering && [
@@ -47,6 +47,7 @@ export declare class FilterPlugin extends BasePlugin {
47
47
  filterFunctionsIndexedByType: Record<string, LogicFunction>;
48
48
  filterProp: string;
49
49
  extraHyperContent?: (data: ShowData) => VNode | VNode[];
50
+ extraBottomHyperContent?: (data: ShowData) => VNode | VNode[];
50
51
  constructor(revogrid: HTMLRevoGridElement, providers: PluginProviders, config?: ColumnFilterConfig | undefined);
51
52
  beforeshow(_: ShowData): void;
52
53
  extraContent(): any;
@@ -126,4 +126,5 @@ export interface ShowData extends FilterItem, Omit<ColumnRegular, 'filter'> {
126
126
  filterItems?: MultiFilterItem;
127
127
  hideDefaultFilters?: boolean;
128
128
  extraContent?: (data: ShowData) => any;
129
+ extraBottomContent?: (data: ShowData) => any;
129
130
  }
@@ -53,8 +53,11 @@ declare global {
53
53
  }
54
54
  export declare class ColumnMovePlugin extends BasePlugin {
55
55
  protected moveFunc: import("lodash").DebouncedFunc<(e: MouseEvent) => void>;
56
+ protected preventHeaderClickAfterDrag: (event: Event) => void;
56
57
  protected staticDragData: StaticData | null;
57
58
  protected dragData: ColumnDragEventData | null;
59
+ protected columnDragMoved: boolean;
60
+ protected preventNextHeaderClick: boolean;
58
61
  readonly orderUi: ColumnOrderHandler;
59
62
  readonly localSubscriptions: LocalSubscriptions;
60
63
  constructor(revogrid: HTMLRevoGridElement, providers: PluginProviders);
@@ -73,4 +76,5 @@ export declare class ColumnMovePlugin extends BasePlugin {
73
76
  protected getDimension(type: MultiDimensionType): DimensionSettingsState;
74
77
  }
75
78
  export declare function getLeftRelative(absoluteX: number, gridPos: number, offset: number): number;
79
+ export declare function getColumnDragPosition(targetItem: PositionItem, startItem: PositionItem, renderOffset: number, scrollOffset: number): number;
76
80
  export {};
package/hydrate/index.js CHANGED
@@ -7725,7 +7725,7 @@ class FilterPanel {
7725
7725
  } }));
7726
7726
  }
7727
7727
  render() {
7728
- var _a, _b, _c;
7728
+ var _a, _b, _c, _d, _e;
7729
7729
  if (!this.changes) {
7730
7730
  return hAsync(Host, { style: { display: 'none' } });
7731
7731
  }
@@ -7742,7 +7742,7 @@ class FilterPanel {
7742
7742
  hAsync("label", null, capts.title),
7743
7743
  hAsync("div", { class: "filter-holder" }, this.getFilterItemsList()),
7744
7744
  hAsync("div", { class: "add-filter" }, hAsync("select", { id: FILTER_ID, class: "select-css", onChange: e => this.onAddNewFilter(e) }, this.renderSelectOptions(this.currentFilterType)))
7745
- ]), hAsync("slot", null), hAsync("div", { class: "filter-actions" }, this.disableDynamicFiltering && [
7745
+ ]), hAsync("slot", null), ((_e = (_d = this.changes).extraBottomContent) === null || _e === void 0 ? void 0 : _e.call(_d, this.changes)) || '', hAsync("div", { class: "filter-actions" }, this.disableDynamicFiltering && [
7746
7746
  hAsync("button", { id: "revo-button-save", "aria-label": "save", class: "revo-button green", onClick: () => this.onSave() }, capts.save),
7747
7747
  hAsync("button", { id: "revo-button-ok", "aria-label": "ok", class: "revo-button green", onClick: () => this.onCancel() }, capts.cancel),
7748
7748
  ], !this.disableDynamicFiltering && [
@@ -15722,7 +15722,7 @@ class FilterPlugin extends BasePlugin {
15722
15722
  // filter button clicked, open filter dialog
15723
15723
  const gridPos = this.revogrid.getBoundingClientRect();
15724
15724
  const buttonPos = el.getBoundingClientRect();
15725
- const data = Object.assign(Object.assign(Object.assign({}, e.detail), this.filterCollection[prop]), { x: buttonPos.x - gridPos.x, y: buttonPos.y - gridPos.y + buttonPos.height, autoCorrect: true, filterTypes: this.getColumnFilter(e.detail.filter), filterItems: this.multiFilterItems, extraContent: this.extraHyperContent });
15725
+ const data = Object.assign(Object.assign(Object.assign({}, e.detail), this.filterCollection[prop]), { x: buttonPos.x - gridPos.x, y: buttonPos.y - gridPos.y + buttonPos.height, autoCorrect: true, filterTypes: this.getColumnFilter(e.detail.filter), filterItems: this.multiFilterItems, extraContent: this.extraHyperContent, extraBottomContent: this.extraBottomHyperContent });
15726
15726
  (_b = this.beforeshow) === null || _b === void 0 ? void 0 : _b.call(this, data);
15727
15727
  this.pop.show(data);
15728
15728
  }
@@ -18487,8 +18487,17 @@ class ColumnMovePlugin extends BasePlugin {
18487
18487
  constructor(revogrid, providers) {
18488
18488
  super(revogrid, providers);
18489
18489
  this.moveFunc = debounce$1((e) => this.doMove(e), 5);
18490
+ this.preventHeaderClickAfterDrag = (event) => {
18491
+ if (!this.preventNextHeaderClick) {
18492
+ return;
18493
+ }
18494
+ this.preventNextHeaderClick = false;
18495
+ event.preventDefault();
18496
+ };
18490
18497
  this.staticDragData = null;
18491
18498
  this.dragData = null;
18499
+ this.columnDragMoved = false;
18500
+ this.preventNextHeaderClick = false;
18492
18501
  this.localSubscriptions = {};
18493
18502
  this.orderUi = new ColumnOrderHandler();
18494
18503
  revogrid.appendChild(this.orderUi.render());
@@ -18507,11 +18516,13 @@ class ColumnMovePlugin extends BasePlugin {
18507
18516
  callback: (e) => this.move(e),
18508
18517
  };
18509
18518
  this.addEventListener(COLUMN_CLICK, ({ detail }) => this.dragStart(detail));
18519
+ this.revogrid.addEventListener('beforeheaderclick', this.preventHeaderClickAfterDrag, { capture: true });
18510
18520
  }
18511
18521
  dragStart({ event, data }) {
18512
18522
  if (event.defaultPrevented) {
18513
18523
  return;
18514
18524
  }
18525
+ this.preventNextHeaderClick = false;
18515
18526
  const { defaultPrevented } = dispatch(this.revogrid, COLUMN_DRAG_START_EVENT, data);
18516
18527
  // check if allowed to drag particulat column
18517
18528
  if (defaultPrevented) {
@@ -18533,7 +18544,8 @@ class ColumnMovePlugin extends BasePlugin {
18533
18544
  const cols = this.getDimension(data.pin || 'rgCol');
18534
18545
  const gridRect = this.revogrid.getBoundingClientRect();
18535
18546
  const elRect = dataEl.getBoundingClientRect();
18536
- const startItem = getItemByPosition(cols, getLeftRelative(event.x, gridRect.left, elRect.left - gridRect.left) + (cols.renderOffset || 0));
18547
+ const startItem = getItemByPosition(cols, getLeftRelative(event.x, gridRect.left, elRect.left - gridRect.left) +
18548
+ (cols.renderOffset || 0));
18537
18549
  this.staticDragData = {
18538
18550
  startPos: event.x,
18539
18551
  startItem,
@@ -18564,10 +18576,14 @@ class ColumnMovePlugin extends BasePlugin {
18564
18576
  if (rgCol.itemIndex >= this.staticDragData.cols.count) {
18565
18577
  return;
18566
18578
  }
18567
- this.orderUi.showHandler(rgCol.end - (this.staticDragData.cols.renderOffset || 0) + dragData.scrollOffset, dragData.gridRect.width);
18579
+ this.orderUi.showHandler(getColumnDragPosition(rgCol, this.staticDragData.startItem, this.staticDragData.cols.renderOffset || 0, dragData.scrollOffset), dragData.gridRect.width);
18568
18580
  }
18569
18581
  }
18570
18582
  move(e) {
18583
+ if (this.staticDragData &&
18584
+ Math.abs(this.staticDragData.startPos - e.x) > 10) {
18585
+ this.columnDragMoved = true;
18586
+ }
18571
18587
  dispatch(this.revogrid, COLUMN_DRAG_MOVE_EVENT, e);
18572
18588
  // then do move
18573
18589
  this.moveFunc(e);
@@ -18576,6 +18592,7 @@ class ColumnMovePlugin extends BasePlugin {
18576
18592
  this.clearOrder();
18577
18593
  }
18578
18594
  onMouseUp(e) {
18595
+ const suppressClick = this.columnDragMoved;
18579
18596
  // apply new positions
18580
18597
  if (this.dragData && this.staticDragData) {
18581
18598
  let relativePos = getLeftRelative(e.x, this.dragData.gridRect.left, this.dragData.scrollOffset);
@@ -18598,6 +18615,9 @@ class ColumnMovePlugin extends BasePlugin {
18598
18615
  }
18599
18616
  dispatch(this.revogrid, COLUMN_DRAG_END_EVENT, this.getData(this.staticDragData, newItems, source));
18600
18617
  }
18618
+ if (suppressClick) {
18619
+ this.preventNextHeaderClick = !!e.target.closest('revogr-header');
18620
+ }
18601
18621
  this.clearOrder();
18602
18622
  }
18603
18623
  clearLocalSubscriptions() {
@@ -18606,6 +18626,7 @@ class ColumnMovePlugin extends BasePlugin {
18606
18626
  clearOrder() {
18607
18627
  this.staticDragData = null;
18608
18628
  this.dragData = null;
18629
+ this.columnDragMoved = false;
18609
18630
  this.clearLocalSubscriptions();
18610
18631
  this.orderUi.stop(this.revogrid);
18611
18632
  }
@@ -18615,6 +18636,7 @@ class ColumnMovePlugin extends BasePlugin {
18615
18636
  clearSubscriptions() {
18616
18637
  super.clearSubscriptions();
18617
18638
  this.clearLocalSubscriptions();
18639
+ this.revogrid.removeEventListener('beforeheaderclick', this.preventHeaderClickAfterDrag, { capture: true });
18618
18640
  }
18619
18641
  getData({ gridEl, dataEl, pin }, order, source = []) {
18620
18642
  const gridRect = gridEl.getBoundingClientRect();
@@ -18636,6 +18658,12 @@ class ColumnMovePlugin extends BasePlugin {
18636
18658
  function getLeftRelative(absoluteX, gridPos, offset) {
18637
18659
  return absoluteX - gridPos - offset;
18638
18660
  }
18661
+ function getColumnDragPosition(targetItem, startItem, renderOffset, scrollOffset) {
18662
+ const insertionEdge = startItem.itemIndex > targetItem.itemIndex
18663
+ ? targetItem.start
18664
+ : targetItem.end;
18665
+ return insertionEdge - renderOffset + scrollOffset;
18666
+ }
18639
18667
 
18640
18668
  function isMobileDevice() {
18641
18669
  return /Mobi/i.test(navigator.userAgent) || /Android/i.test(navigator.userAgent) || navigator.maxTouchPoints > 0;
@@ -21853,9 +21881,17 @@ class RevogrViewportScroll {
21853
21881
  }
21854
21882
  render() {
21855
21883
  var _a, _b;
21856
- const physicalContentHeight = getContentSize(this.contentHeight, (_b = (_a = this.verticalScroll) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0);
21884
+ const clientHeight = (_b = (_a = this.verticalScroll) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0;
21885
+ // When content fits in the viewport (no scroll needed), don't inflate content-wrapper
21886
+ // to clientHeight — that would prevent inner-content-table from shrinking and push
21887
+ // rowPinEnd (footer) to the bottom instead of letting it follow the data rows.
21888
+ // For large/compressed grids (content > clientHeight), physicalContentHeight handles
21889
+ // the browser scroll-size compression correctly.
21890
+ const physicalContentHeight = this.contentHeight < clientHeight
21891
+ ? Math.max(this.contentHeight, 0)
21892
+ : getContentSize(this.contentHeight, clientHeight);
21857
21893
  const physicalContentWidth = getContentSize(this.contentWidth, 0);
21858
- return (hAsync(Host, { key: 'ec8d907976c1d50f7aab3c263be3f0249a274df6', onWheel: this.horizontalMouseWheel, onScroll: (e) => this.applyScroll('rgCol', e) }, hAsync("div", { key: 'e35696a7993ac94261426b45c28d488cdc42b7f0', class: "inner-content-table", style: { width: `${physicalContentWidth}px` } }, hAsync("div", { key: 'a6997451e01eacda1d27d4efa1d74e1748626218', class: "header-wrapper", ref: e => (this.header = e) }, hAsync("slot", { key: '1d401e87d32d5b1531c2211723b552bbc894f22c', name: HEADER_SLOT })), hAsync("div", { key: 'ceab6f9e812d6ca9a0aa376afcd2562a17f505e0', class: "vertical-inner", ref: el => (this.verticalScroll = el), onWheel: this.verticalMouseWheel, onScroll: (e) => this.applyScroll('rgRow', e) }, hAsync("div", { key: 'a9556578a23d6efddec2e982e863aec064042154', class: "content-wrapper", style: { height: `${physicalContentHeight}px` } }, hAsync("slot", { key: '0ae01f9736b9740612e75261f6e3abebda533377', name: CONTENT_SLOT }))), hAsync("div", { key: '09c2565d4ed449a43820f92d97b6558fca3758e7', class: "footer-wrapper", ref: e => (this.footer = e) }, hAsync("slot", { key: '1ffb08ff8138a560cc09d82e3fe22a53e502aafe', name: FOOTER_SLOT })))));
21894
+ return (hAsync(Host, { key: '3dd9d29cf26743d7aa4995f51180d56008526e54', onWheel: this.horizontalMouseWheel, onScroll: (e) => this.applyScroll('rgCol', e) }, hAsync("div", { key: 'af75428e845044c33eba2fecd1ec04a9177b9b5c', class: "inner-content-table", style: { width: `${physicalContentWidth}px` } }, hAsync("div", { key: 'a0149f597588371e1fafe69efc3bd4411379a017', class: "header-wrapper", ref: e => (this.header = e) }, hAsync("slot", { key: 'e5d2570bf93897cd97ef702141c83bb8c0e13ee2', name: HEADER_SLOT })), hAsync("div", { key: 'd1388ff0d721dd8ce925b934bb2128fddc1ac17b', class: "vertical-inner", ref: el => (this.verticalScroll = el), onWheel: this.verticalMouseWheel, onScroll: (e) => this.applyScroll('rgRow', e) }, hAsync("div", { key: 'a306ff56f62279402e2a881a081e3224341d5bdf', class: "content-wrapper", style: { height: `${physicalContentHeight}px` } }, hAsync("slot", { key: '898bda8e9429da06c9ff2bd41626ac27f3cde3cc', name: CONTENT_SLOT }))), hAsync("div", { key: '5e9eba1edd5fca07a964971054a7900e4dd84099', class: "footer-wrapper", ref: e => (this.footer = e) }, hAsync("slot", { key: 'f233ad1c23b3f692c45e1db235cfef4704a80726', name: FOOTER_SLOT })))));
21859
21895
  }
21860
21896
  /**
21861
21897
  * Extra layer for scroll event monitoring, where MouseWheel event is not passing
package/hydrate/index.mjs CHANGED
@@ -7723,7 +7723,7 @@ class FilterPanel {
7723
7723
  } }));
7724
7724
  }
7725
7725
  render() {
7726
- var _a, _b, _c;
7726
+ var _a, _b, _c, _d, _e;
7727
7727
  if (!this.changes) {
7728
7728
  return hAsync(Host, { style: { display: 'none' } });
7729
7729
  }
@@ -7740,7 +7740,7 @@ class FilterPanel {
7740
7740
  hAsync("label", null, capts.title),
7741
7741
  hAsync("div", { class: "filter-holder" }, this.getFilterItemsList()),
7742
7742
  hAsync("div", { class: "add-filter" }, hAsync("select", { id: FILTER_ID, class: "select-css", onChange: e => this.onAddNewFilter(e) }, this.renderSelectOptions(this.currentFilterType)))
7743
- ]), hAsync("slot", null), hAsync("div", { class: "filter-actions" }, this.disableDynamicFiltering && [
7743
+ ]), hAsync("slot", null), ((_e = (_d = this.changes).extraBottomContent) === null || _e === void 0 ? void 0 : _e.call(_d, this.changes)) || '', hAsync("div", { class: "filter-actions" }, this.disableDynamicFiltering && [
7744
7744
  hAsync("button", { id: "revo-button-save", "aria-label": "save", class: "revo-button green", onClick: () => this.onSave() }, capts.save),
7745
7745
  hAsync("button", { id: "revo-button-ok", "aria-label": "ok", class: "revo-button green", onClick: () => this.onCancel() }, capts.cancel),
7746
7746
  ], !this.disableDynamicFiltering && [
@@ -15720,7 +15720,7 @@ class FilterPlugin extends BasePlugin {
15720
15720
  // filter button clicked, open filter dialog
15721
15721
  const gridPos = this.revogrid.getBoundingClientRect();
15722
15722
  const buttonPos = el.getBoundingClientRect();
15723
- const data = Object.assign(Object.assign(Object.assign({}, e.detail), this.filterCollection[prop]), { x: buttonPos.x - gridPos.x, y: buttonPos.y - gridPos.y + buttonPos.height, autoCorrect: true, filterTypes: this.getColumnFilter(e.detail.filter), filterItems: this.multiFilterItems, extraContent: this.extraHyperContent });
15723
+ const data = Object.assign(Object.assign(Object.assign({}, e.detail), this.filterCollection[prop]), { x: buttonPos.x - gridPos.x, y: buttonPos.y - gridPos.y + buttonPos.height, autoCorrect: true, filterTypes: this.getColumnFilter(e.detail.filter), filterItems: this.multiFilterItems, extraContent: this.extraHyperContent, extraBottomContent: this.extraBottomHyperContent });
15724
15724
  (_b = this.beforeshow) === null || _b === void 0 ? void 0 : _b.call(this, data);
15725
15725
  this.pop.show(data);
15726
15726
  }
@@ -18485,8 +18485,17 @@ class ColumnMovePlugin extends BasePlugin {
18485
18485
  constructor(revogrid, providers) {
18486
18486
  super(revogrid, providers);
18487
18487
  this.moveFunc = debounce$1((e) => this.doMove(e), 5);
18488
+ this.preventHeaderClickAfterDrag = (event) => {
18489
+ if (!this.preventNextHeaderClick) {
18490
+ return;
18491
+ }
18492
+ this.preventNextHeaderClick = false;
18493
+ event.preventDefault();
18494
+ };
18488
18495
  this.staticDragData = null;
18489
18496
  this.dragData = null;
18497
+ this.columnDragMoved = false;
18498
+ this.preventNextHeaderClick = false;
18490
18499
  this.localSubscriptions = {};
18491
18500
  this.orderUi = new ColumnOrderHandler();
18492
18501
  revogrid.appendChild(this.orderUi.render());
@@ -18505,11 +18514,13 @@ class ColumnMovePlugin extends BasePlugin {
18505
18514
  callback: (e) => this.move(e),
18506
18515
  };
18507
18516
  this.addEventListener(COLUMN_CLICK, ({ detail }) => this.dragStart(detail));
18517
+ this.revogrid.addEventListener('beforeheaderclick', this.preventHeaderClickAfterDrag, { capture: true });
18508
18518
  }
18509
18519
  dragStart({ event, data }) {
18510
18520
  if (event.defaultPrevented) {
18511
18521
  return;
18512
18522
  }
18523
+ this.preventNextHeaderClick = false;
18513
18524
  const { defaultPrevented } = dispatch(this.revogrid, COLUMN_DRAG_START_EVENT, data);
18514
18525
  // check if allowed to drag particulat column
18515
18526
  if (defaultPrevented) {
@@ -18531,7 +18542,8 @@ class ColumnMovePlugin extends BasePlugin {
18531
18542
  const cols = this.getDimension(data.pin || 'rgCol');
18532
18543
  const gridRect = this.revogrid.getBoundingClientRect();
18533
18544
  const elRect = dataEl.getBoundingClientRect();
18534
- const startItem = getItemByPosition(cols, getLeftRelative(event.x, gridRect.left, elRect.left - gridRect.left) + (cols.renderOffset || 0));
18545
+ const startItem = getItemByPosition(cols, getLeftRelative(event.x, gridRect.left, elRect.left - gridRect.left) +
18546
+ (cols.renderOffset || 0));
18535
18547
  this.staticDragData = {
18536
18548
  startPos: event.x,
18537
18549
  startItem,
@@ -18562,10 +18574,14 @@ class ColumnMovePlugin extends BasePlugin {
18562
18574
  if (rgCol.itemIndex >= this.staticDragData.cols.count) {
18563
18575
  return;
18564
18576
  }
18565
- this.orderUi.showHandler(rgCol.end - (this.staticDragData.cols.renderOffset || 0) + dragData.scrollOffset, dragData.gridRect.width);
18577
+ this.orderUi.showHandler(getColumnDragPosition(rgCol, this.staticDragData.startItem, this.staticDragData.cols.renderOffset || 0, dragData.scrollOffset), dragData.gridRect.width);
18566
18578
  }
18567
18579
  }
18568
18580
  move(e) {
18581
+ if (this.staticDragData &&
18582
+ Math.abs(this.staticDragData.startPos - e.x) > 10) {
18583
+ this.columnDragMoved = true;
18584
+ }
18569
18585
  dispatch(this.revogrid, COLUMN_DRAG_MOVE_EVENT, e);
18570
18586
  // then do move
18571
18587
  this.moveFunc(e);
@@ -18574,6 +18590,7 @@ class ColumnMovePlugin extends BasePlugin {
18574
18590
  this.clearOrder();
18575
18591
  }
18576
18592
  onMouseUp(e) {
18593
+ const suppressClick = this.columnDragMoved;
18577
18594
  // apply new positions
18578
18595
  if (this.dragData && this.staticDragData) {
18579
18596
  let relativePos = getLeftRelative(e.x, this.dragData.gridRect.left, this.dragData.scrollOffset);
@@ -18596,6 +18613,9 @@ class ColumnMovePlugin extends BasePlugin {
18596
18613
  }
18597
18614
  dispatch(this.revogrid, COLUMN_DRAG_END_EVENT, this.getData(this.staticDragData, newItems, source));
18598
18615
  }
18616
+ if (suppressClick) {
18617
+ this.preventNextHeaderClick = !!e.target.closest('revogr-header');
18618
+ }
18599
18619
  this.clearOrder();
18600
18620
  }
18601
18621
  clearLocalSubscriptions() {
@@ -18604,6 +18624,7 @@ class ColumnMovePlugin extends BasePlugin {
18604
18624
  clearOrder() {
18605
18625
  this.staticDragData = null;
18606
18626
  this.dragData = null;
18627
+ this.columnDragMoved = false;
18607
18628
  this.clearLocalSubscriptions();
18608
18629
  this.orderUi.stop(this.revogrid);
18609
18630
  }
@@ -18613,6 +18634,7 @@ class ColumnMovePlugin extends BasePlugin {
18613
18634
  clearSubscriptions() {
18614
18635
  super.clearSubscriptions();
18615
18636
  this.clearLocalSubscriptions();
18637
+ this.revogrid.removeEventListener('beforeheaderclick', this.preventHeaderClickAfterDrag, { capture: true });
18616
18638
  }
18617
18639
  getData({ gridEl, dataEl, pin }, order, source = []) {
18618
18640
  const gridRect = gridEl.getBoundingClientRect();
@@ -18634,6 +18656,12 @@ class ColumnMovePlugin extends BasePlugin {
18634
18656
  function getLeftRelative(absoluteX, gridPos, offset) {
18635
18657
  return absoluteX - gridPos - offset;
18636
18658
  }
18659
+ function getColumnDragPosition(targetItem, startItem, renderOffset, scrollOffset) {
18660
+ const insertionEdge = startItem.itemIndex > targetItem.itemIndex
18661
+ ? targetItem.start
18662
+ : targetItem.end;
18663
+ return insertionEdge - renderOffset + scrollOffset;
18664
+ }
18637
18665
 
18638
18666
  function isMobileDevice() {
18639
18667
  return /Mobi/i.test(navigator.userAgent) || /Android/i.test(navigator.userAgent) || navigator.maxTouchPoints > 0;
@@ -21851,9 +21879,17 @@ class RevogrViewportScroll {
21851
21879
  }
21852
21880
  render() {
21853
21881
  var _a, _b;
21854
- const physicalContentHeight = getContentSize(this.contentHeight, (_b = (_a = this.verticalScroll) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0);
21882
+ const clientHeight = (_b = (_a = this.verticalScroll) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0;
21883
+ // When content fits in the viewport (no scroll needed), don't inflate content-wrapper
21884
+ // to clientHeight — that would prevent inner-content-table from shrinking and push
21885
+ // rowPinEnd (footer) to the bottom instead of letting it follow the data rows.
21886
+ // For large/compressed grids (content > clientHeight), physicalContentHeight handles
21887
+ // the browser scroll-size compression correctly.
21888
+ const physicalContentHeight = this.contentHeight < clientHeight
21889
+ ? Math.max(this.contentHeight, 0)
21890
+ : getContentSize(this.contentHeight, clientHeight);
21855
21891
  const physicalContentWidth = getContentSize(this.contentWidth, 0);
21856
- return (hAsync(Host, { key: 'ec8d907976c1d50f7aab3c263be3f0249a274df6', onWheel: this.horizontalMouseWheel, onScroll: (e) => this.applyScroll('rgCol', e) }, hAsync("div", { key: 'e35696a7993ac94261426b45c28d488cdc42b7f0', class: "inner-content-table", style: { width: `${physicalContentWidth}px` } }, hAsync("div", { key: 'a6997451e01eacda1d27d4efa1d74e1748626218', class: "header-wrapper", ref: e => (this.header = e) }, hAsync("slot", { key: '1d401e87d32d5b1531c2211723b552bbc894f22c', name: HEADER_SLOT })), hAsync("div", { key: 'ceab6f9e812d6ca9a0aa376afcd2562a17f505e0', class: "vertical-inner", ref: el => (this.verticalScroll = el), onWheel: this.verticalMouseWheel, onScroll: (e) => this.applyScroll('rgRow', e) }, hAsync("div", { key: 'a9556578a23d6efddec2e982e863aec064042154', class: "content-wrapper", style: { height: `${physicalContentHeight}px` } }, hAsync("slot", { key: '0ae01f9736b9740612e75261f6e3abebda533377', name: CONTENT_SLOT }))), hAsync("div", { key: '09c2565d4ed449a43820f92d97b6558fca3758e7', class: "footer-wrapper", ref: e => (this.footer = e) }, hAsync("slot", { key: '1ffb08ff8138a560cc09d82e3fe22a53e502aafe', name: FOOTER_SLOT })))));
21892
+ return (hAsync(Host, { key: '3dd9d29cf26743d7aa4995f51180d56008526e54', onWheel: this.horizontalMouseWheel, onScroll: (e) => this.applyScroll('rgCol', e) }, hAsync("div", { key: 'af75428e845044c33eba2fecd1ec04a9177b9b5c', class: "inner-content-table", style: { width: `${physicalContentWidth}px` } }, hAsync("div", { key: 'a0149f597588371e1fafe69efc3bd4411379a017', class: "header-wrapper", ref: e => (this.header = e) }, hAsync("slot", { key: 'e5d2570bf93897cd97ef702141c83bb8c0e13ee2', name: HEADER_SLOT })), hAsync("div", { key: 'd1388ff0d721dd8ce925b934bb2128fddc1ac17b', class: "vertical-inner", ref: el => (this.verticalScroll = el), onWheel: this.verticalMouseWheel, onScroll: (e) => this.applyScroll('rgRow', e) }, hAsync("div", { key: 'a306ff56f62279402e2a881a081e3224341d5bdf', class: "content-wrapper", style: { height: `${physicalContentHeight}px` } }, hAsync("slot", { key: '898bda8e9429da06c9ff2bd41626ac27f3cde3cc', name: CONTENT_SLOT }))), hAsync("div", { key: '5e9eba1edd5fca07a964971054a7900e4dd84099', class: "footer-wrapper", ref: e => (this.footer = e) }, hAsync("slot", { key: 'f233ad1c23b3f692c45e1db235cfef4704a80726', name: FOOTER_SLOT })))));
21857
21893
  }
21858
21894
  /**
21859
21895
  * Extra layer for scroll event monitoring, where MouseWheel event is not passing
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@revolist/revogrid",
3
- "version": "4.23.6",
3
+ "version": "4.23.8",
4
4
  "type": "module",
5
5
  "description": "Virtual reactive data grid spreadsheet component - RevoGrid.",
6
6
  "license": "MIT",
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * Built by Revolist OU ❤️
3
3
  */
4
- import{setMode as _}from"@stencil/core/internal/client";export{getAssetPath,h,render,setAssetPath,setNonce,setPlatformOptions}from"@stencil/core/internal/client";import{g as O,B as L}from"./revo-grid.js";export{A as AutoSizeColumnPlugin,o as BEFORE_COLUMN_DRAG_END_EVENT,n as COLUMN_DRAG_END_EVENT,m as COLUMN_DRAG_MOVE_EVENT,p as COLUMN_DRAG_START_EVENT,C as ColumnAutoSizeMode,q as ColumnMovePlugin,D as DimensionStore,b as ExportCsv,E as ExportFilePlugin,c as FILTER_CONFIG_CHANGED_EVENT,F as FILTER_TRIMMED_TYPE,d as FILTE_PANEL,e as FilterPlugin,G as GroupingRowPlugin,RevoGrid,S as SelectionStore,s as SortingPlugin,a as StretchColumn,w as defaultCellCompare,defineCustomElement as defineCustomElementRevoGrid,x as descCellCompare,k as doCollapse,l as doExpand,f as filterCoreFunctionsIndexedByType,j as filterNames,h as filterTypes,z as getComparer,r as getLeftRelative,y as getNextOrder,u as getSortingIndex,t as hasActiveSorting,i as isStretchPlugin,v as sortIndexByItems}from"./revo-grid.js";export{o as GROUPING_ROW_TYPE,j as GROUP_COLUMN_PROP,G as GROUP_DEPTH,h as GROUP_EXPANDED,l as GROUP_EXPAND_BTN,m as GROUP_EXPAND_EVENT,k as GROUP_ORIGINAL_INDEX,f as PSEUDO_GROUP_COLUMN,P as PSEUDO_GROUP_ITEM,d as PSEUDO_GROUP_ITEM_ID,e as PSEUDO_GROUP_ITEM_VALUE,c as columnTypes,a as cropCellToMax,H as gatherGroup,s as gatherGrouping,z as getCellData,B as getCellDataParsed,A as getCellRaw,I as getColumnByProp,D as getColumnSizes,C as getColumnType,F as getColumns,q as getExpanded,t as getGroupingName,x as getParsedGroup,g as getRange,p as getSource,E as isColGrouping,u as isGrouping,v as isGroupingColumn,b as isRangeSingleCell,i as isRowType,y as isSameGroup,w as measureEqualDepth,n as nextCell,r as rowTypes}from"./column.service.js";export{S as SortingSign,d as dispatch,a as dispatchByEvent}from"./revogr-header2.js";export{a as applyMixins,f as findPositionInArray,g as getScrollbarSize,m as mergeSortedArray,p as pushSorted,r as range,s as scaleValue,t as timeout}from"./index2.js";export{C as CellRenderer,G as GroupingRowRenderer,e as expandEvent,a as expandSvgIconVNode}from"./revogr-data2.js";export{T as TextEditor,k as isAll,c as isClear,h as isCopy,a as isCtrlKey,b as isCtrlMetaKey,g as isCut,m as isEditInput,n as isEditorCtrConstructible,f as isEnterKeyValue,i as isMetaKey,j as isPaste,l as isShortcutModifier,d as isTab,e as isTabKeyValue}from"./revogr-edit2.js";export{RevogrAttribution,defineCustomElement as defineCustomElementRevogrAttribution}from"./revogr-attribution.js";export{RevogrClipboard,defineCustomElement as defineCustomElementRevogrClipboard}from"./revogr-clipboard.js";export{RevogrData,defineCustomElement as defineCustomElementRevogrData}from"./revogr-data.js";export{RevogrEdit,defineCustomElement as defineCustomElementRevogrEdit}from"./revogr-edit.js";export{RevogrExtra,defineCustomElement as defineCustomElementRevogrExtra}from"./revogr-extra.js";export{RevogrFilterPanel,defineCustomElement as defineCustomElementRevogrFilterPanel}from"./revogr-filter-panel.js";export{RevogrFocus,defineCustomElement as defineCustomElementRevogrFocus}from"./revogr-focus.js";export{RevogrHeader,defineCustomElement as defineCustomElementRevogrHeader}from"./revogr-header.js";export{RevogrOrderEditor,defineCustomElement as defineCustomElementRevogrOrderEditor}from"./revogr-order-editor.js";export{RevogrOverlaySelection,defineCustomElement as defineCustomElementRevogrOverlaySelection}from"./revogr-overlay-selection.js";export{RevogrRowHeaders,defineCustomElement as defineCustomElementRevogrRowHeaders}from"./revogr-row-headers.js";export{RevogrScrollVirtual,defineCustomElement as defineCustomElementRevogrScrollVirtual}from"./revogr-scroll-virtual.js";export{RevogrTempRange,defineCustomElement as defineCustomElementRevogrTempRange}from"./revogr-temp-range.js";export{RevogrViewportScroll,defineCustomElement as defineCustomElementRevogrViewportScroll}from"./revogr-viewport-scroll.js";export{VnodeHtml,defineCustomElement as defineCustomElementVnodeHtml}from"./vnode-html.js";export{D as DataStore,h as gatherTrimmedItems,g as getPhysical,b as getSourceItem,f as getSourceItemVirtualIndexByProp,c as getSourcePhysicalIndex,a as getVisibleSourceItem,p as proxyPlugin,e as setItems,d as setSourceByPhysicalIndex,s as setSourceByVirtualIndex,i as setStore,t as trimmedPlugin}from"./data.store.js";export{c as calculateDimensionData,a as getItemByIndex,g as getItemByPosition}from"./dimension.helpers.js";export{V as ViewportStore,b as addMissingItems,j as calculateRowHeaderSize,c as clampViewportCoordinate,f as getFirstItem,d as getItems,h as getLastItem,a as getUpdatedItemsByPosition,g as getViewportMaxCoordinate,i as isActiveRange,e as isActiveRangeOutsideLastItem,r as recombineByOffset,s as setItemSizes,u as updateMissingAndRange}from"./revogr-row-headers2.js";export{A as AND_OR_BUTTON,e as AndOrButton,a as FILTER_BUTTON_ACTIVE,F as FILTER_BUTTON_CLASS,b as FILTER_PROP,c as FilterButton,T as TRASH_BUTTON,d as TrashButton,i as isFilterBtn}from"./filter.button.js";export{C as CELL_CLASS,j as CELL_HANDLER_CLASS,D as DATA_COL,a as DATA_ROW,b as DISABLED_CLASS,h as DRAGGABLE_CLASS,k as DRAGG_TEXT,g as DRAG_ICON_CLASS,E as EDIT_INPUT_WR,F as FOCUS_CLASS,G as GRID_INTERNALS,f as HEADER_ACTUAL_ROW_CLASS,H as HEADER_CLASS,e as HEADER_ROW_CLASS,d as HEADER_SORTABLE_CLASS,M as MIN_COL_SIZE,i as MOBILE_CLASS,R as RESIZE_INTERVAL,l as ROW_FOCUSED_CLASS,c as ROW_HEADER_TYPE,S as SELECTION_BORDER_CLASS,T as TMP_SELECTION_BG_CLASS}from"./consts.js";export{c as codesLetter,k as keyValues}from"./platform.js";const N=function(){_((e=>{let r=e.theme||e.getAttribute("theme");"string"==typeof r&&(r=r.trim());const o=O(r);return o!==r&&e.setAttribute("theme",o),o}))}||(()=>{}),U=new Map([["contentsizechanged","contentsizechanged"],["beforeedit","beforeedit"],["beforerangeedit","beforerangeedit"],["afteredit","afteredit"],["beforeautofill","beforeautofill"],["beforerange","beforerange"],["afterfocus","afterfocus"],["roworderchanged","roworderchanged"],["beforesorting","beforesorting"],["beforesourcesortingapply","beforesourcesortingapply"],["beforesortingapply","beforesortingapply"],["rowdragstart","rowdragstart"],["headerclick","headerclick"],["beforecellfocus","beforecellfocus"],["beforefocuslost","beforefocuslost"],["beforesourceset","beforesourceset"],["beforeanysource","beforeanysource"],["aftersourceset","aftersourceset"],["afteranysource","afteranysource"],["beforecolumnsgather","beforecolumnsgather"],["beforecolumnsset","beforecolumnsset"],["beforecolumnapplied","beforecolumnapplied"],["aftercolumnsset","aftercolumnsset"],["beforefilterapply","beforefilterapply"],["beforefiltertrimmed","beforefiltertrimmed"],["beforetrimmed","beforetrimmed"],["aftertrimmed","aftertrimmed"],["viewportscroll","viewportscroll"],["beforeexport","beforeexport"],["beforeeditstart","beforeeditstart"],["aftercolumnresize","aftercolumnresize"],["beforerowdefinition","beforerowdefinition"],["filterconfigchanged","filterconfigchanged"],["sortingconfigchanged","sortingconfigchanged"],["rowheaderschanged","rowheaderschanged"],["beforegridrender","beforegridrender"],["aftergridrender","aftergridrender"],["aftergridinit","aftergridinit"],["additionaldatachanged","additionaldatachanged"],["afterthemechanged","afterthemechanged"],["created","created"],["beforepaste","beforepaste"],["beforepasteapply","beforepasteapply"],["pasteregion","pasteregion"],["afterpasteapply","afterpasteapply"],["beforecut","beforecut"],["clearregion","clearregion"],["beforecopy","beforecopy"],["beforecopyapply","beforecopyapply"],["copyregion","copyregion"],["beforerowrender","beforerowrender"],["afterrender","afterrender"],["beforecellrender","beforecellrender"],["beforedatarender","beforedatarender"],["dragstartcell","dragstartcell"],["celleditinit","celleditinit"],["closeedit","closeedit"],["filterChange","filterChange"],["resetChange","resetChange"],["beforefocusrender","beforefocusrender"],["beforescrollintoview","beforescrollintoview"],["afterfocus","afterfocus"],["beforeheaderclick","beforeheaderclick"],["headerresize","headerresize"],["beforeheaderresize","beforeheaderresize"],["headerdblclick","headerdblclick"],["beforeheaderrender","beforeheaderrender"],["beforegroupheaderrender","beforegroupheaderrender"],["afterheaderrender","afterheaderrender"],["columndragstart","columndragstart"],["columndragmousemove","columndragmousemove"],["beforecolumndragend","beforecolumndragend"],["columndragend","columndragend"],["rowdragstartinit","rowdragstartinit"],["rowdragendinit","rowdragendinit"],["rowdragmoveinit","rowdragmoveinit"],["rowdragmousemove","rowdragmousemove"],["rowdropinit","rowdropinit"],["roworderchange","roworderchange"],["beforecopyregion","beforecopyregion"],["beforepasteregion","beforepasteregion"],["celleditapply","celleditapply"],["beforecellfocusinit","beforecellfocusinit"],["beforenextvpfocus","beforenextvpfocus"],["setedit","setedit"],["beforeapplyrange","beforeapplyrange"],["beforesetrange","beforesetrange"],["setrange","setrange"],["beforeeditrender","beforeeditrender"],["selectall","selectall"],["canceledit","canceledit"],["settemprange","settemprange"],["beforesettemprange","beforesettemprange"],["applyfocus","applyfocus"],["focuscell","focuscell"],["beforerangedataapply","beforerangedataapply"],["selectionchangeinit","selectionchangeinit"],["beforerangecopyapply","beforerangecopyapply"],["rangeeditapply","rangeeditapply"],["clipboardrangecopy","clipboardrangecopy"],["clipboardrangepaste","clipboardrangepaste"],["beforekeydown","beforekeydown"],["beforekeyup","beforekeyup"],["beforecellsave","beforecellsave"],["celledit","celledit"],["scrollview","scrollview"],["ref","ref"],["scrollvirtual","scrollvirtual"],["scrollviewport","scrollviewport"],["resizeviewport","resizeviewport"],["scrollchange","scrollchange"],["scrollviewportsilent","scrollviewportsilent"],["html","html"]]);class W extends L{constructor(e,r){super(e,r),this.addEventListener("beforepasteapply",(e=>this.handleBeforePasteApply(e)))}handleBeforePasteApply(e){const r=this.providers.selection.focused;if(!r||null!=this.providers.selection.edit)return;const o=this.providers.data.stores.rgRow.store.get("items").length,t=r.y+e.detail.parsed.length;if(o<t){const e=Array.from({length:t-o},((e,r)=>({index:o+r,data:{}}))),r=this.emit("newRows",{newRows:e});if(r.defaultPrevented)return;const a=[...this.providers.data.stores.rgRow.store.get("source"),...r.detail.newRows.map((e=>e.data))];this.providers.data.setData(a)}}}N();export{W as AutoAddRowsPlugin,L as BasePlugin,U as REVOGRID_EVENTS}
4
+ import{setMode as _}from"@stencil/core/internal/client";export{getAssetPath,h,render,setAssetPath,setNonce,setPlatformOptions}from"@stencil/core/internal/client";import{g as O,B as L}from"./revo-grid.js";export{A as AutoSizeColumnPlugin,o as BEFORE_COLUMN_DRAG_END_EVENT,n as COLUMN_DRAG_END_EVENT,m as COLUMN_DRAG_MOVE_EVENT,p as COLUMN_DRAG_START_EVENT,C as ColumnAutoSizeMode,q as ColumnMovePlugin,D as DimensionStore,b as ExportCsv,E as ExportFilePlugin,c as FILTER_CONFIG_CHANGED_EVENT,F as FILTER_TRIMMED_TYPE,d as FILTE_PANEL,e as FilterPlugin,G as GroupingRowPlugin,RevoGrid,S as SelectionStore,t as SortingPlugin,a as StretchColumn,x as defaultCellCompare,defineCustomElement as defineCustomElementRevoGrid,y as descCellCompare,k as doCollapse,l as doExpand,f as filterCoreFunctionsIndexedByType,j as filterNames,h as filterTypes,s as getColumnDragPosition,H as getComparer,r as getLeftRelative,z as getNextOrder,v as getSortingIndex,u as hasActiveSorting,i as isStretchPlugin,w as sortIndexByItems}from"./revo-grid.js";export{o as GROUPING_ROW_TYPE,j as GROUP_COLUMN_PROP,G as GROUP_DEPTH,h as GROUP_EXPANDED,l as GROUP_EXPAND_BTN,m as GROUP_EXPAND_EVENT,k as GROUP_ORIGINAL_INDEX,f as PSEUDO_GROUP_COLUMN,P as PSEUDO_GROUP_ITEM,d as PSEUDO_GROUP_ITEM_ID,e as PSEUDO_GROUP_ITEM_VALUE,c as columnTypes,a as cropCellToMax,H as gatherGroup,s as gatherGrouping,z as getCellData,B as getCellDataParsed,A as getCellRaw,I as getColumnByProp,D as getColumnSizes,C as getColumnType,F as getColumns,q as getExpanded,t as getGroupingName,x as getParsedGroup,g as getRange,p as getSource,E as isColGrouping,u as isGrouping,v as isGroupingColumn,b as isRangeSingleCell,i as isRowType,y as isSameGroup,w as measureEqualDepth,n as nextCell,r as rowTypes}from"./column.service.js";export{S as SortingSign,d as dispatch,a as dispatchByEvent}from"./revogr-header2.js";export{a as applyMixins,f as findPositionInArray,g as getScrollbarSize,m as mergeSortedArray,p as pushSorted,r as range,s as scaleValue,t as timeout}from"./index2.js";export{C as CellRenderer,G as GroupingRowRenderer,e as expandEvent,a as expandSvgIconVNode}from"./revogr-data2.js";export{T as TextEditor,k as isAll,c as isClear,h as isCopy,a as isCtrlKey,b as isCtrlMetaKey,g as isCut,m as isEditInput,n as isEditorCtrConstructible,f as isEnterKeyValue,i as isMetaKey,j as isPaste,l as isShortcutModifier,d as isTab,e as isTabKeyValue}from"./revogr-edit2.js";export{RevogrAttribution,defineCustomElement as defineCustomElementRevogrAttribution}from"./revogr-attribution.js";export{RevogrClipboard,defineCustomElement as defineCustomElementRevogrClipboard}from"./revogr-clipboard.js";export{RevogrData,defineCustomElement as defineCustomElementRevogrData}from"./revogr-data.js";export{RevogrEdit,defineCustomElement as defineCustomElementRevogrEdit}from"./revogr-edit.js";export{RevogrExtra,defineCustomElement as defineCustomElementRevogrExtra}from"./revogr-extra.js";export{RevogrFilterPanel,defineCustomElement as defineCustomElementRevogrFilterPanel}from"./revogr-filter-panel.js";export{RevogrFocus,defineCustomElement as defineCustomElementRevogrFocus}from"./revogr-focus.js";export{RevogrHeader,defineCustomElement as defineCustomElementRevogrHeader}from"./revogr-header.js";export{RevogrOrderEditor,defineCustomElement as defineCustomElementRevogrOrderEditor}from"./revogr-order-editor.js";export{RevogrOverlaySelection,defineCustomElement as defineCustomElementRevogrOverlaySelection}from"./revogr-overlay-selection.js";export{RevogrRowHeaders,defineCustomElement as defineCustomElementRevogrRowHeaders}from"./revogr-row-headers.js";export{RevogrScrollVirtual,defineCustomElement as defineCustomElementRevogrScrollVirtual}from"./revogr-scroll-virtual.js";export{RevogrTempRange,defineCustomElement as defineCustomElementRevogrTempRange}from"./revogr-temp-range.js";export{RevogrViewportScroll,defineCustomElement as defineCustomElementRevogrViewportScroll}from"./revogr-viewport-scroll.js";export{VnodeHtml,defineCustomElement as defineCustomElementVnodeHtml}from"./vnode-html.js";export{D as DataStore,h as gatherTrimmedItems,g as getPhysical,b as getSourceItem,f as getSourceItemVirtualIndexByProp,c as getSourcePhysicalIndex,a as getVisibleSourceItem,p as proxyPlugin,e as setItems,d as setSourceByPhysicalIndex,s as setSourceByVirtualIndex,i as setStore,t as trimmedPlugin}from"./data.store.js";export{c as calculateDimensionData,a as getItemByIndex,g as getItemByPosition}from"./dimension.helpers.js";export{V as ViewportStore,b as addMissingItems,j as calculateRowHeaderSize,c as clampViewportCoordinate,f as getFirstItem,d as getItems,h as getLastItem,a as getUpdatedItemsByPosition,g as getViewportMaxCoordinate,i as isActiveRange,e as isActiveRangeOutsideLastItem,r as recombineByOffset,s as setItemSizes,u as updateMissingAndRange}from"./revogr-row-headers2.js";export{A as AND_OR_BUTTON,e as AndOrButton,a as FILTER_BUTTON_ACTIVE,F as FILTER_BUTTON_CLASS,b as FILTER_PROP,c as FilterButton,T as TRASH_BUTTON,d as TrashButton,i as isFilterBtn}from"./filter.button.js";export{C as CELL_CLASS,j as CELL_HANDLER_CLASS,D as DATA_COL,a as DATA_ROW,b as DISABLED_CLASS,h as DRAGGABLE_CLASS,k as DRAGG_TEXT,g as DRAG_ICON_CLASS,E as EDIT_INPUT_WR,F as FOCUS_CLASS,G as GRID_INTERNALS,f as HEADER_ACTUAL_ROW_CLASS,H as HEADER_CLASS,e as HEADER_ROW_CLASS,d as HEADER_SORTABLE_CLASS,M as MIN_COL_SIZE,i as MOBILE_CLASS,R as RESIZE_INTERVAL,l as ROW_FOCUSED_CLASS,c as ROW_HEADER_TYPE,S as SELECTION_BORDER_CLASS,T as TMP_SELECTION_BG_CLASS}from"./consts.js";export{c as codesLetter,k as keyValues}from"./platform.js";const N=function(){_((e=>{let r=e.theme||e.getAttribute("theme");"string"==typeof r&&(r=r.trim());const o=O(r);return o!==r&&e.setAttribute("theme",o),o}))}||(()=>{}),U=new Map([["contentsizechanged","contentsizechanged"],["beforeedit","beforeedit"],["beforerangeedit","beforerangeedit"],["afteredit","afteredit"],["beforeautofill","beforeautofill"],["beforerange","beforerange"],["afterfocus","afterfocus"],["roworderchanged","roworderchanged"],["beforesorting","beforesorting"],["beforesourcesortingapply","beforesourcesortingapply"],["beforesortingapply","beforesortingapply"],["rowdragstart","rowdragstart"],["headerclick","headerclick"],["beforecellfocus","beforecellfocus"],["beforefocuslost","beforefocuslost"],["beforesourceset","beforesourceset"],["beforeanysource","beforeanysource"],["aftersourceset","aftersourceset"],["afteranysource","afteranysource"],["beforecolumnsgather","beforecolumnsgather"],["beforecolumnsset","beforecolumnsset"],["beforecolumnapplied","beforecolumnapplied"],["aftercolumnsset","aftercolumnsset"],["beforefilterapply","beforefilterapply"],["beforefiltertrimmed","beforefiltertrimmed"],["beforetrimmed","beforetrimmed"],["aftertrimmed","aftertrimmed"],["viewportscroll","viewportscroll"],["beforeexport","beforeexport"],["beforeeditstart","beforeeditstart"],["aftercolumnresize","aftercolumnresize"],["beforerowdefinition","beforerowdefinition"],["filterconfigchanged","filterconfigchanged"],["sortingconfigchanged","sortingconfigchanged"],["rowheaderschanged","rowheaderschanged"],["beforegridrender","beforegridrender"],["aftergridrender","aftergridrender"],["aftergridinit","aftergridinit"],["additionaldatachanged","additionaldatachanged"],["afterthemechanged","afterthemechanged"],["created","created"],["beforepaste","beforepaste"],["beforepasteapply","beforepasteapply"],["pasteregion","pasteregion"],["afterpasteapply","afterpasteapply"],["beforecut","beforecut"],["clearregion","clearregion"],["beforecopy","beforecopy"],["beforecopyapply","beforecopyapply"],["copyregion","copyregion"],["beforerowrender","beforerowrender"],["afterrender","afterrender"],["beforecellrender","beforecellrender"],["beforedatarender","beforedatarender"],["dragstartcell","dragstartcell"],["celleditinit","celleditinit"],["closeedit","closeedit"],["filterChange","filterChange"],["resetChange","resetChange"],["beforefocusrender","beforefocusrender"],["beforescrollintoview","beforescrollintoview"],["afterfocus","afterfocus"],["beforeheaderclick","beforeheaderclick"],["headerresize","headerresize"],["beforeheaderresize","beforeheaderresize"],["headerdblclick","headerdblclick"],["beforeheaderrender","beforeheaderrender"],["beforegroupheaderrender","beforegroupheaderrender"],["afterheaderrender","afterheaderrender"],["columndragstart","columndragstart"],["columndragmousemove","columndragmousemove"],["beforecolumndragend","beforecolumndragend"],["columndragend","columndragend"],["rowdragstartinit","rowdragstartinit"],["rowdragendinit","rowdragendinit"],["rowdragmoveinit","rowdragmoveinit"],["rowdragmousemove","rowdragmousemove"],["rowdropinit","rowdropinit"],["roworderchange","roworderchange"],["beforecopyregion","beforecopyregion"],["beforepasteregion","beforepasteregion"],["celleditapply","celleditapply"],["beforecellfocusinit","beforecellfocusinit"],["beforenextvpfocus","beforenextvpfocus"],["setedit","setedit"],["beforeapplyrange","beforeapplyrange"],["beforesetrange","beforesetrange"],["setrange","setrange"],["beforeeditrender","beforeeditrender"],["selectall","selectall"],["canceledit","canceledit"],["settemprange","settemprange"],["beforesettemprange","beforesettemprange"],["applyfocus","applyfocus"],["focuscell","focuscell"],["beforerangedataapply","beforerangedataapply"],["selectionchangeinit","selectionchangeinit"],["beforerangecopyapply","beforerangecopyapply"],["rangeeditapply","rangeeditapply"],["clipboardrangecopy","clipboardrangecopy"],["clipboardrangepaste","clipboardrangepaste"],["beforekeydown","beforekeydown"],["beforekeyup","beforekeyup"],["beforecellsave","beforecellsave"],["celledit","celledit"],["scrollview","scrollview"],["ref","ref"],["scrollvirtual","scrollvirtual"],["scrollviewport","scrollviewport"],["resizeviewport","resizeviewport"],["scrollchange","scrollchange"],["scrollviewportsilent","scrollviewportsilent"],["html","html"]]);class W extends L{constructor(e,r){super(e,r),this.addEventListener("beforepasteapply",(e=>this.handleBeforePasteApply(e)))}handleBeforePasteApply(e){const r=this.providers.selection.focused;if(!r||null!=this.providers.selection.edit)return;const o=this.providers.data.stores.rgRow.store.get("items").length,t=r.y+e.detail.parsed.length;if(o<t){const e=Array.from({length:t-o},((e,r)=>({index:o+r,data:{}}))),r=this.emit("newRows",{newRows:e});if(r.defaultPrevented)return;const a=[...this.providers.data.stores.rgRow.store.get("source"),...r.detail.newRows.map((e=>e.data))];this.providers.data.setData(a)}}}N();export{W as AutoAddRowsPlugin,L as BasePlugin,U as REVOGRID_EVENTS}