@revolist/revogrid 4.23.14 → 4.23.16

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 (81) hide show
  1. package/dist/cjs/{cell-renderer-Dcz022q7.js → cell-renderer-DfUCisis.js} +23 -5
  2. package/dist/cjs/{column.drag.plugin-BGLbi1zS.js → column.drag.plugin-ByDJ7Rk3.js} +35 -6
  3. package/dist/cjs/{column.service-C1Qvcf5l.js → column.service-BNWNiJW3.js} +62 -23
  4. package/dist/cjs/{filter.button-w6LWnyhi.js → filter.button-C4xpvyyE.js} +14 -4
  5. package/dist/cjs/{header-cell-renderer-vVr4IWNV.js → header-cell-renderer-DyjOxArm.js} +1 -1
  6. package/dist/cjs/index.cjs.js +8 -5
  7. package/dist/cjs/loader.cjs.js +1 -1
  8. package/dist/cjs/revo-grid.cjs.entry.js +6 -6
  9. package/dist/cjs/revo-grid.cjs.js +1 -1
  10. package/dist/cjs/revogr-attribution_7.cjs.entry.js +40 -4
  11. package/dist/cjs/revogr-clipboard_3.cjs.entry.js +1 -1
  12. package/dist/cjs/revogr-data_4.cjs.entry.js +14 -6
  13. package/dist/cjs/revogr-filter-panel.cjs.entry.js +177 -48
  14. package/dist/collection/components/clipboard/revogr-clipboard.js +1 -1
  15. package/dist/collection/components/data/column.service.js +62 -23
  16. package/dist/collection/components/data/row-renderer.js +15 -2
  17. package/dist/collection/components/overlay/clipboard.utils.js +26 -0
  18. package/dist/collection/components/overlay/revogr-overlay-selection.js +27 -7
  19. package/dist/collection/components/revoGrid/revo-grid.js +14 -7
  20. package/dist/collection/components/scroll/revogr-viewport-scroll.js +10 -2
  21. package/dist/collection/plugins/filter/filter.button.js +12 -4
  22. package/dist/collection/plugins/filter/filter.panel.js +138 -48
  23. package/dist/collection/plugins/filter/filter.plugin.js +1 -1
  24. package/dist/collection/plugins/filter/filter.reorder.js +44 -0
  25. package/dist/collection/plugins/filter/filter.style.css +96 -6
  26. package/dist/collection/plugins/groupingRow/grouping.row.renderer.js +7 -2
  27. package/dist/collection/plugins/moveColumn/column.drag.plugin.js +30 -2
  28. package/dist/collection/serve/controller.js +1 -0
  29. package/dist/esm/{cell-renderer-BtN-NGCk.js → cell-renderer-CLTRlCa5.js} +23 -5
  30. package/dist/esm/{column.drag.plugin-4Ixr4ijU.js → column.drag.plugin-BZacA8n_.js} +35 -7
  31. package/dist/esm/{column.service-CC_SD8W3.js → column.service-C6hByxPy.js} +62 -23
  32. package/dist/esm/filter.button-B-RBiF67.js +38 -0
  33. package/dist/esm/{header-cell-renderer-B-LX2sgu.js → header-cell-renderer-BMmXRsd_.js} +1 -1
  34. package/dist/esm/index.js +6 -6
  35. package/dist/esm/loader.js +1 -1
  36. package/dist/esm/revo-grid.entry.js +6 -6
  37. package/dist/esm/revo-grid.js +1 -1
  38. package/dist/esm/revogr-attribution_7.entry.js +40 -4
  39. package/dist/esm/revogr-clipboard_3.entry.js +1 -1
  40. package/dist/esm/revogr-data_4.entry.js +14 -6
  41. package/dist/esm/revogr-filter-panel.entry.js +177 -48
  42. package/dist/revo-grid/{cell-renderer-BtN-NGCk.js → cell-renderer-CLTRlCa5.js} +23 -5
  43. package/dist/revo-grid/{column.drag.plugin-4Ixr4ijU.js → column.drag.plugin-BZacA8n_.js} +35 -7
  44. package/dist/revo-grid/{column.service-CC_SD8W3.js → column.service-C6hByxPy.js} +62 -23
  45. package/dist/revo-grid/filter.button-B-RBiF67.js +38 -0
  46. package/dist/revo-grid/{header-cell-renderer-B-LX2sgu.js → header-cell-renderer-BMmXRsd_.js} +1 -1
  47. package/dist/revo-grid/index.esm.js +6 -6
  48. package/dist/revo-grid/revo-grid.entry.js +6 -6
  49. package/dist/revo-grid/revo-grid.esm.js +1 -1
  50. package/dist/revo-grid/revogr-attribution_7.entry.js +40 -4
  51. package/dist/revo-grid/revogr-clipboard_3.entry.js +1 -1
  52. package/dist/revo-grid/revogr-data_4.entry.js +14 -6
  53. package/dist/revo-grid/revogr-filter-panel.entry.js +177 -48
  54. package/dist/types/components/data/column.service.d.ts +10 -1
  55. package/dist/types/components/data/row-renderer.d.ts +1 -1
  56. package/dist/types/components/overlay/clipboard.utils.d.ts +3 -0
  57. package/dist/types/components/overlay/revogr-overlay-selection.d.ts +4 -3
  58. package/dist/types/components/revoGrid/revo-grid.d.ts +4 -4
  59. package/dist/types/components.d.ts +14 -14
  60. package/dist/types/plugins/filter/filter.button.d.ts +23 -2
  61. package/dist/types/plugins/filter/filter.panel.d.ts +8 -1
  62. package/dist/types/plugins/filter/filter.plugin.d.ts +1 -0
  63. package/dist/types/plugins/filter/filter.reorder.d.ts +4 -0
  64. package/dist/types/plugins/filter/filter.types.d.ts +8 -0
  65. package/dist/types/plugins/moveColumn/column.drag.plugin.d.ts +4 -0
  66. package/dist/types/types/interfaces.d.ts +8 -0
  67. package/hydrate/index.js +358 -90
  68. package/hydrate/index.mjs +358 -90
  69. package/package.json +1 -1
  70. package/readme.md +20 -1
  71. package/standalone/column.service.js +1 -1
  72. package/standalone/filter.button.js +1 -1
  73. package/standalone/index.js +1 -1
  74. package/standalone/revo-grid.js +1 -1
  75. package/standalone/revogr-clipboard2.js +1 -1
  76. package/standalone/revogr-data2.js +1 -1
  77. package/standalone/revogr-filter-panel.js +1 -1
  78. package/standalone/revogr-overlay-selection2.js +1 -1
  79. package/standalone/revogr-viewport-scroll2.js +1 -1
  80. package/dist/esm/filter.button-C8XTWPU2.js +0 -30
  81. package/dist/revo-grid/filter.button-C8XTWPU2.js +0 -30
@@ -1,14 +1,14 @@
1
1
  /*!
2
2
  * Built by Revolist OU ❤️
3
3
  */
4
- import { J as reduce, g as getRange, K as baseEach, C as getColumnType, c as columnTypes, L as toInteger, u as isGrouping, t as getGroupingName, r as rowTypes, B as getCellDataParsed, A as getCellRaw, j as GROUP_COLUMN_PROP, I as getColumnByProp, h as GROUP_EXPANDED, x as getParsedGroup, y as isSameGroup, G as GROUP_DEPTH, e as PSEUDO_GROUP_ITEM_VALUE, d as PSEUDO_GROUP_ITEM_ID, o as GROUPING_ROW_TYPE, p as getSource, f as PSEUDO_GROUP_COLUMN, s as gatherGrouping, m as GROUP_EXPAND_EVENT, v as isGroupingColumn, q as getExpanded, E as isColGrouping } from './column.service-CC_SD8W3.js';
4
+ import { J as reduce, g as getRange, K as baseEach, C as getColumnType, c as columnTypes, L as toInteger, u as isGrouping, t as getGroupingName, r as rowTypes, B as getCellDataParsed, A as getCellRaw, j as GROUP_COLUMN_PROP, I as getColumnByProp, h as GROUP_EXPANDED, x as getParsedGroup, y as isSameGroup, G as GROUP_DEPTH, e as PSEUDO_GROUP_ITEM_VALUE, d as PSEUDO_GROUP_ITEM_ID, o as GROUPING_ROW_TYPE, p as getSource, f as PSEUDO_GROUP_COLUMN, s as gatherGrouping, m as GROUP_EXPAND_EVENT, v as isGroupingColumn, q as getExpanded, E as isColGrouping } from './column.service-C6hByxPy.js';
5
5
  import { K as createStore, l as setStore, i as calculateDimensionData, L as identity, N as isArray, b as getSourceItem, g as getPhysical, e as setItems, j as getItemByPosition } from './dimension.helpers-CGKwSvw6.js';
6
6
  import { j as calculateRowHeaderSize } from './viewport.store-_c579YyM.js';
7
7
  import { g as getScrollbarSize, t as timeout } from './index-Db3qZoW5.js';
8
8
  import { h } from './index-Chp_81rd.js';
9
- import { b as FILTER_PROP, i as isFilterBtn } from './filter.button-C8XTWPU2.js';
9
+ import { b as FILTER_PROP, i as isFilterBtn } from './filter.button-B-RBiF67.js';
10
10
  import { d as debounce } from './debounce-PCRWZliA.js';
11
- import { O as ON_COLUMN_CLICK, d as dispatch } from './header-cell-renderer-B-LX2sgu.js';
11
+ import { O as ON_COLUMN_CLICK, d as dispatch } from './header-cell-renderer-BMmXRsd_.js';
12
12
 
13
13
  function calculateRealSize({ count, originItemSize, sizes, }) {
14
14
  const safeCount = Math.max(0, count);
@@ -1416,7 +1416,7 @@ class FilterPlugin extends BasePlugin {
1416
1416
  }
1417
1417
  // filter button clicked, open filter dialog
1418
1418
  const buttonPos = (filterButton instanceof HTMLElement ? filterButton : el).getBoundingClientRect();
1419
- const data = Object.assign(Object.assign(Object.assign({}, e.detail), this.filterCollection[prop]), { x: buttonPos.x, y: buttonPos.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, y: buttonPos.y + buttonPos.height, anchorY: buttonPos.y, 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 };
@@ -817,43 +817,82 @@ class ColumnService {
817
817
  mapping,
818
818
  };
819
819
  }
820
- getTransformedDataToApply(start, data) {
820
+ getTransformedDataToApply({ start, data, targetRange, }) {
821
821
  const changed = {};
822
822
  const copyRowLength = data.length;
823
+ if (!copyRowLength) {
824
+ return {
825
+ changed,
826
+ range: null,
827
+ };
828
+ }
823
829
  const colLength = this.columns.length;
824
830
  const rowLength = this.dataStore.get('items').length;
831
+ const bounds = this.getDataApplyBounds(start, targetRange, copyRowLength, rowLength, colLength);
832
+ if (!bounds) {
833
+ return {
834
+ changed,
835
+ range: null,
836
+ };
837
+ }
838
+ const { startRow, startCol, endRow } = bounds;
839
+ let maxCol = startCol - 1;
840
+ let lastRow = startRow - 1;
825
841
  // rows
826
- let rowIndex = start.y;
827
- let maxCol = 0;
828
- for (let i = 0; rowIndex < rowLength && i < copyRowLength; rowIndex++, i++) {
842
+ for (let rowIndex = startRow, i = 0; rowIndex <= endRow; rowIndex++, i++) {
829
843
  // copy original data link
830
844
  const copyRow = data[i % copyRowLength];
831
845
  const copyColLength = (copyRow === null || copyRow === void 0 ? void 0 : copyRow.length) || 0;
832
- // columns
833
- let colIndex = start.x;
834
- for (let j = 0; colIndex < colLength && j < copyColLength; colIndex++, j++) {
835
- const p = this.columns[colIndex].prop;
836
- const currentCol = j % colLength;
837
- /** if can write */
838
- if (!this.isReadOnly(rowIndex, colIndex)) {
839
- /** to show before save */
840
- if (!changed[rowIndex]) {
841
- changed[rowIndex] = {};
842
- }
843
- changed[rowIndex][p] = copyRow[currentCol];
844
- }
846
+ if (!copyColLength) {
847
+ continue;
845
848
  }
846
- maxCol = Math.max(maxCol, colIndex - 1);
849
+ maxCol = Math.max(maxCol, this.applyClipboardRow(changed, {
850
+ bounds,
851
+ copyColLength,
852
+ copyRow,
853
+ rowIndex,
854
+ start,
855
+ targetRange,
856
+ }));
857
+ lastRow = rowIndex;
847
858
  }
848
- const range = getRange(start, {
849
- y: rowIndex - 1,
850
- x: maxCol,
851
- });
852
859
  return {
853
860
  changed,
854
- range,
861
+ range: this.getAppliedRange(bounds, lastRow, maxCol),
855
862
  };
856
863
  }
864
+ getDataApplyBounds(start, targetRange, copyRowLength, rowLength, colLength) {
865
+ var _a, _b, _c;
866
+ const startRow = (_a = targetRange === null || targetRange === void 0 ? void 0 : targetRange.y) !== null && _a !== void 0 ? _a : start.y;
867
+ const startCol = (_b = targetRange === null || targetRange === void 0 ? void 0 : targetRange.x) !== null && _b !== void 0 ? _b : start.x;
868
+ const endRow = Math.min(rowLength - 1, (_c = targetRange === null || targetRange === void 0 ? void 0 : targetRange.y1) !== null && _c !== void 0 ? _c : start.y + copyRowLength - 1);
869
+ if (endRow < startRow || startCol >= colLength) {
870
+ return null;
871
+ }
872
+ return { startRow, startCol, endRow, colLength };
873
+ }
874
+ applyClipboardRow(changed, { bounds, copyColLength, copyRow, rowIndex, start, targetRange, }) {
875
+ var _a;
876
+ const endCol = Math.min(bounds.colLength - 1, (_a = targetRange === null || targetRange === void 0 ? void 0 : targetRange.x1) !== null && _a !== void 0 ? _a : start.x + copyColLength - 1);
877
+ for (let colIndex = bounds.startCol, j = 0; colIndex <= endCol; colIndex++, j++) {
878
+ if (this.isReadOnly(rowIndex, colIndex)) {
879
+ continue;
880
+ }
881
+ const prop = this.columns[colIndex].prop;
882
+ changed[rowIndex] = changed[rowIndex] || {};
883
+ changed[rowIndex][prop] = copyRow[j % copyColLength];
884
+ }
885
+ return endCol;
886
+ }
887
+ getAppliedRange({ startRow, startCol }, lastRow, maxCol) {
888
+ if (lastRow < startRow || maxCol < startCol) {
889
+ return null;
890
+ }
891
+ return getRange({ x: startCol, y: startRow }, {
892
+ y: lastRow,
893
+ x: maxCol,
894
+ });
895
+ }
857
896
  getRangeStaticData(d, value) {
858
897
  const changed = {};
859
898
  // rows
@@ -0,0 +1,38 @@
1
+ /*!
2
+ * Built by Revolist OU ❤️
3
+ */
4
+ import { h } from './index-Chp_81rd.js';
5
+
6
+ const FILTER_BUTTON_CLASS = 'rv-filter';
7
+ const FILTER_BUTTON_ACTIVE = 'active';
8
+ const FILTER_PROP = 'hasFilter';
9
+ const AND_OR_BUTTON = 'and-or-button';
10
+ const TRASH_BUTTON = 'trash-button';
11
+ const REORDER_BUTTON = 'reorder-button';
12
+ const FilterButton = ({ column }) => {
13
+ return (h("span", null, h("button", { class: {
14
+ [FILTER_BUTTON_CLASS]: true,
15
+ [FILTER_BUTTON_ACTIVE]: column && !!column[FILTER_PROP],
16
+ } }, h("svg", { class: "filter-img", viewBox: "0 0 64 64" }, h("g", { stroke: "none", "stroke-width": "1", fill: "none", "fill-rule": "evenodd" }, h("path", { d: "M43,48 L43,56 L21,56 L21,48 L43,48 Z M53,28 L53,36 L12,36 L12,28 L53,28 Z M64,8 L64,16 L0,16 L0,8 L64,8 Z", fill: "currentColor" }))))));
17
+ };
18
+ const TrashButton = ({ ariaLabel, onClick }) => {
19
+ return (h("button", { type: "button", class: { [TRASH_BUTTON]: true }, "aria-label": ariaLabel, onClick: onClick }, h("svg", { class: "trash-img", viewBox: "0 0 24 24" }, h("path", { fill: "currentColor", d: "M9,3V4H4V6H5V19A2,2 0 0,0 7,21H17A2,2 0 0,0 19,19V6H20V4H15V3H9M7,6H17V19H7V6M9,8V17H11V8H9M13,8V17H15V8H13Z" }))));
20
+ };
21
+ const AndOrButton = ({ text, onClick }) => {
22
+ return h("button", { type: "button", class: { [AND_OR_BUTTON]: true, 'light revo-button': true }, onClick: onClick }, text);
23
+ };
24
+ const ReorderButton = ({ ariaLabel, dragging, dragOver, onDragStart, onDragEnd, onDragOver, onDragLeave, onDrop, onKeyDown, }) => {
25
+ return (h("button", { type: "button", class: {
26
+ [REORDER_BUTTON]: true,
27
+ 'filter-row-dragging': !!dragging,
28
+ 'filter-row-drag-over': !!dragOver,
29
+ }, draggable: true, title: ariaLabel, "aria-label": ariaLabel, onDragStart: onDragStart, onDragEnd: onDragEnd, onDragOver: onDragOver, onDragLeave: onDragLeave, onDrop: onDrop, onKeyDown: onKeyDown }, "::"));
30
+ };
31
+ function isFilterBtn(e) {
32
+ if (e.classList.contains(FILTER_BUTTON_CLASS)) {
33
+ return true;
34
+ }
35
+ return e === null || e === void 0 ? void 0 : e.closest(`.${FILTER_BUTTON_CLASS}`);
36
+ }
37
+
38
+ export { AND_OR_BUTTON as A, FILTER_BUTTON_CLASS as F, REORDER_BUTTON as R, TRASH_BUTTON as T, FILTER_BUTTON_ACTIVE as a, FILTER_PROP as b, FilterButton as c, TrashButton as d, AndOrButton as e, ReorderButton as f, isFilterBtn as i };
@@ -2,7 +2,7 @@
2
2
  * Built by Revolist OU ❤️
3
3
  */
4
4
  import { h } from './index-Chp_81rd.js';
5
- import { Q as doPropMerge } from './column.service-CC_SD8W3.js';
5
+ import { Q as doPropMerge } from './column.service-C6hByxPy.js';
6
6
 
7
7
  /**
8
8
  * Dispatches a custom event to a specified target element.
@@ -1,18 +1,18 @@
1
1
  /*!
2
2
  * Built by Revolist OU ❤️
3
3
  */
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-4Ixr4ijU.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-4Ixr4ijU.js';
7
- export { d as dispatch, a as dispatchByEvent } from './header-cell-renderer-B-LX2sgu.js';
8
- export { C as CellRenderer, G as GroupingRowRenderer, S as SortingSign, e as expandEvent, a as expandSvgIconVNode } from './cell-renderer-BtN-NGCk.js';
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-C6hByxPy.js';
5
+ import { B as BasePlugin } from './column.drag.plugin-BZacA8n_.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-BZacA8n_.js';
7
+ export { d as dispatch, a as dispatchByEvent } from './header-cell-renderer-BMmXRsd_.js';
8
+ export { C as CellRenderer, G as GroupingRowRenderer, S as SortingSign, e as expandEvent, a as expandSvgIconVNode } from './cell-renderer-CLTRlCa5.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';
10
10
  export { T as TextEditor } from './text-editor-C3RUSwH5.js';
11
11
  export { 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 './edit.utils-Dnnbd0xG.js';
12
12
  export { h } from './index-Chp_81rd.js';
13
13
  export { C as CELL_CLASS, z as CELL_HANDLER_CLASS, m as DATA_COL, n as DATA_ROW, o as DISABLED_CLASS, x as DRAGGABLE_CLASS, A as DRAGG_TEXT, w as DRAG_ICON_CLASS, D as DataStore, E as EDIT_INPUT_WR, F as FOCUS_CLASS, G as GRID_INTERNALS, v as HEADER_ACTUAL_ROW_CLASS, H as HEADER_CLASS, u as HEADER_ROW_CLASS, r as HEADER_SORTABLE_CLASS, M as MIN_COL_SIZE, y as MOBILE_CLASS, R as RESIZE_INTERVAL, B as ROW_FOCUSED_CLASS, q as ROW_HEADER_TYPE, S as SELECTION_BORDER_CLASS, T as TMP_SELECTION_BG_CLASS, i as calculateDimensionData, I as codesLetter, h as gatherTrimmedItems, k as getItemByIndex, j as getItemByPosition, g as getPhysical, b as getSourceItem, f as getSourceItemVirtualIndexByProp, c as getSourcePhysicalIndex, a as getVisibleSourceItem, J as keyValues, p as proxyPlugin, e as setItems, d as setSourceByPhysicalIndex, s as setSourceByVirtualIndex, l as setStore, t as trimmedPlugin } from './dimension.helpers-CGKwSvw6.js';
14
14
  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 './viewport.store-_c579YyM.js';
15
- 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-C8XTWPU2.js';
15
+ 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, R as REORDER_BUTTON, f as ReorderButton, T as TRASH_BUTTON, d as TrashButton, i as isFilterBtn } from './filter.button-B-RBiF67.js';
16
16
  import './debounce-PCRWZliA.js';
17
17
 
18
18
  const REVOGRID_EVENTS = new Map([
@@ -2,17 +2,17 @@
2
2
  * Built by Revolist OU ❤️
3
3
  */
4
4
  import { h, r as registerInstance, d as createEvent, e as Host, g as getElement } from './index-Chp_81rd.js';
5
- import { c as columnTypes, J as reduce, C as getColumnType, r as rowTypes, i as isRowType, D as getColumnSizes, a as cropCellToMax, n as nextCell, I as getColumnByProp, F as getColumns } from './column.service-CC_SD8W3.js';
5
+ import { c as columnTypes, J as reduce, C as getColumnType, r as rowTypes, i as isRowType, D as getColumnSizes, a as cropCellToMax, n as nextCell, I as getColumnByProp, F as getColumns } from './column.service-C6hByxPy.js';
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-4Ixr4ijU.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-BZacA8n_.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';
13
13
  import { g as getPropertyFromEvent } from './events-BvSmBueA.js';
14
- import './filter.button-C8XTWPU2.js';
15
- import './header-cell-renderer-B-LX2sgu.js';
14
+ import './filter.button-B-RBiF67.js';
15
+ import './header-cell-renderer-BMmXRsd_.js';
16
16
 
17
17
  class ColumnDataProvider {
18
18
  get stores() {
@@ -1445,7 +1445,7 @@ const RevoGridComponent = class {
1445
1445
  this.rowSize = 0;
1446
1446
  /** Indicates default column size. */
1447
1447
  this.colSize = 100;
1448
- /** When true, user can range selection. */
1448
+ /** When true, user can select a cell range. Required for range-based clipboard fill. */
1449
1449
  this.range = false;
1450
1450
  /** When true, grid in read only mode. */
1451
1451
  this.readonly = false;
@@ -1457,7 +1457,7 @@ const RevoGridComponent = class {
1457
1457
  this.noHorizontalScrollTransfer = false;
1458
1458
  /** When true cell focus appear. */
1459
1459
  this.canFocus = true;
1460
- /** When true enable clipboard. */
1460
+ /** When true enable clipboard. Can be boolean or clipboard config. */
1461
1461
  this.useClipboard = true;
1462
1462
  /**
1463
1463
  * Columns - defines an array of grid columns.
@@ -48,5 +48,5 @@ var patchCloneNodeFix = (HTMLElementPrototype) => {
48
48
 
49
49
  patchBrowser().then(async (options) => {
50
50
  await globalScripts();
51
- return bootstrapLazy([["revo-grid",[[260,"revo-grid",{"rowHeaders":[4,"row-headers"],"frameSize":[2,"frame-size"],"rowSize":[2,"row-size"],"colSize":[2,"col-size"],"range":[4],"readonly":[4],"resize":[4],"noHorizontalScrollTransfer":[4,"no-horizontal-scroll-transfer"],"canFocus":[4,"can-focus"],"useClipboard":[4,"use-clipboard"],"columns":[16],"source":[16],"pinnedTopSource":[16],"pinnedBottomSource":[16],"rowDefinitions":[16],"editors":[16],"applyOnClose":[4,"apply-on-close"],"plugins":[16],"columnTypes":[16],"theme":[1537],"rowClass":[513,"row-class"],"autoSizeColumn":[4,"auto-size-column"],"filter":[4],"sorting":[16],"focusTemplate":[16],"canMoveColumns":[4,"can-move-columns"],"trimmedRows":[16],"exporting":[4],"grouping":[16],"stretch":[8],"additionalData":[16],"disableVirtualX":[4,"disable-virtual-x"],"disableVirtualY":[4,"disable-virtual-y"],"hideAttribution":[4,"hide-attribution"],"jobsBeforeRender":[16],"registerVNode":[16],"accessible":[4],"rtl":[4],"canDrag":[4,"can-drag"],"refresh":[64],"setDataAt":[64],"scrollToRow":[64],"scrollToColumnIndex":[64],"scrollToColumnProp":[64],"updateColumns":[64],"addTrimmed":[64],"scrollToCoordinate":[64],"setCellEdit":[64],"setCellsFocus":[64],"getSource":[64],"getVisibleSource":[64],"getSourceStore":[64],"getColumnStore":[64],"updateColumnSorting":[64],"clearSorting":[64],"getColumns":[64],"clearFocus":[64],"getPlugins":[64],"getFocused":[64],"getContentSize":[64],"getSelectedRange":[64],"refreshExtraElements":[64],"getProviders":[64]},[[5,"touchstart","mousedownHandle"],[5,"mousedown","mousedownHandle"],[5,"touchend","mouseupHandle"],[5,"mouseup","mouseupHandle"],[0,"rowdragstartinit","onRowDragStarted"],[0,"rowdragendinit","onRowDragEnd"],[0,"roworderchange","onRowOrderChange"],[0,"rowdragmoveinit","onRowDrag"],[0,"rowdragmousemove","onRowMouseMove"],[0,"celleditapply","onCellEdit"],[0,"rangeeditapply","onRangeEdit"],[0,"selectionchangeinit","onRangeChanged"],[0,"rowdropinit","onRowDropped"],[0,"beforeheaderclick","onHeaderClick"],[0,"beforecellfocusinit","onCellFocus"]],{"columnTypes":[{"columnTypesChanged":0}],"columns":[{"columnChanged":0}],"disableVirtualX":[{"disableVirtualXChanged":0}],"rowSize":[{"rowSizeChanged":0}],"theme":[{"themeChanged":0}],"source":[{"dataSourceChanged":0}],"pinnedBottomSource":[{"dataSourceChanged":0}],"pinnedTopSource":[{"dataSourceChanged":0}],"disableVirtualY":[{"disableVirtualYChanged":0}],"rowDefinitions":[{"rowDefChanged":0}],"trimmedRows":[{"trimmedRowsChanged":0}],"grouping":[{"groupingChanged":0}],"stretch":[{"applyStretch":0}],"filter":[{"applyFilter":0}],"sorting":[{"applySorting":0}],"rowHeaders":[{"rowHeadersChange":0}],"registerVNode":[{"registerOutsideVNodes":0}],"additionalData":[{"additionalDataChanged":0}],"rtl":[{"rtlChanged":0}],"plugins":[{"pluginsChanged":0}]}]]],["revogr-filter-panel",[[260,"revogr-filter-panel",{"filterNames":[16],"filterEntities":[16],"filterCaptions":[16],"disableDynamicFiltering":[4,"disable-dynamic-filtering"],"closeOnOutsideClick":[4,"close-on-outside-click"],"isFilterIdSet":[32],"filterId":[32],"currentFilterId":[32],"currentFilterType":[32],"changes":[32],"filterItems":[32],"show":[64],"getChanges":[64]},[[5,"mousedown","onMouseDown"]]]]],["revogr-clipboard_3",[[0,"revogr-clipboard",{"readonly":[4],"doCopy":[64]},[[4,"paste","onPaste"],[4,"copy","copyStarted"],[4,"cut","cutStarted"]]],[0,"revogr-edit",{"editCell":[16],"column":[16],"editor":[16],"saveOnClose":[4,"save-on-close"],"additionalData":[8,"additional-data"],"cancelChanges":[64],"beforeDisconnect":[64]}],[0,"revogr-order-editor",{"parent":[16],"dimensionRow":[16],"dimensionCol":[16],"dataStore":[16],"rowType":[1,"row-type"],"dragStart":[64],"endOrder":[64],"clearOrder":[64]}]]],["revogr-data_4",[[260,"revogr-data",{"readonly":[4],"range":[4],"rowClass":[1,"row-class"],"additionalData":[8,"additional-data"],"rowSelectionStore":[16],"viewportRow":[16],"viewportCol":[16],"dimensionRow":[16],"colData":[16],"dataStore":[16],"type":[513],"colType":[513,"col-type"],"jobsBeforeRender":[16],"providers":[32],"updateCell":[64]},null,{"dataStore":[{"onDataStoreChange":0}],"colData":[{"onColDataChange":0}]}],[0,"revogr-header",{"viewportCol":[16],"dimensionCol":[16],"selectionStore":[16],"groups":[16],"groupingDepth":[2,"grouping-depth"],"readonly":[4],"canResize":[4,"can-resize"],"resizeHandler":[16],"colData":[16],"columnFilter":[4,"column-filter"],"type":[1],"additionalData":[8,"additional-data"]}],[260,"revogr-viewport-scroll",{"rowHeader":[4,"row-header"],"contentWidth":[2,"content-width"],"contentHeight":[2,"content-height"],"colType":[1,"col-type"],"noHorizontalScrollTransfer":[4,"no-horizontal-scroll-transfer"],"setScroll":[64],"changeScroll":[64],"applyScroll":[64]},[[0,"mousewheel-vertical","mousewheelVertical"],[0,"mousewheel-horizontal","mousewheelHorizontal"],[0,"scroll-coordinate","scrollApply"]]],[0,"vnode-html",{"redraw":[16]}]]],["revogr-attribution_7",[[0,"revogr-row-headers",{"height":[2],"dataPorts":[16],"headerProp":[16],"rowClass":[1,"row-class"],"resize":[4],"rowHeaderColumn":[16],"additionalData":[8,"additional-data"],"jobsBeforeRender":[16]}],[260,"revogr-overlay-selection",{"readonly":[4],"range":[4],"canDrag":[4,"can-drag"],"useClipboard":[4,"use-clipboard"],"selectionStore":[16],"dimensionRow":[16],"dimensionCol":[16],"dataStore":[16],"colData":[16],"lastCell":[16],"editors":[16],"applyChangesOnClose":[4,"apply-changes-on-close"],"additionalData":[8,"additional-data"],"isMobileDevice":[4,"is-mobile-device"]},[[5,"touchmove","onMouseMove"],[5,"mousemove","onMouseMove"],[5,"touchend","onMouseUp"],[5,"mouseup","onMouseUp"],[5,"mouseleave","onMouseUp"],[0,"dragstartcell","onCellDrag"],[4,"keyup","onKeyUp"],[4,"keydown","onKeyDown"]],{"selectionStore":[{"selectionServiceSet":0}],"dimensionRow":[{"createAutoFillService":0}],"dimensionCol":[{"createAutoFillService":0}],"dataStore":[{"columnServiceSet":0}],"colData":[{"columnServiceSet":0}]}],[0,"revogr-attribution"],[260,"revogr-focus",{"colType":[1,"col-type"],"rowType":[1,"row-type"],"selectionStore":[16],"dimensionRow":[16],"dimensionCol":[16],"dataStore":[16],"colData":[16],"focusTemplate":[16]}],[0,"revogr-scroll-virtual",{"dimension":[1],"realSize":[2,"real-size"],"virtualSize":[2,"virtual-size"],"clientSize":[2,"client-size"],"setScroll":[64],"changeScroll":[64]}],[0,"revogr-temp-range",{"selectionStore":[16],"dimensionRow":[16],"dimensionCol":[16]}],[0,"revogr-extra",{"nodes":[16],"update":[32],"refresh":[64]}]]]], options);
51
+ return bootstrapLazy([["revo-grid",[[260,"revo-grid",{"rowHeaders":[4,"row-headers"],"frameSize":[2,"frame-size"],"rowSize":[2,"row-size"],"colSize":[2,"col-size"],"range":[4],"readonly":[4],"resize":[4],"noHorizontalScrollTransfer":[4,"no-horizontal-scroll-transfer"],"canFocus":[4,"can-focus"],"useClipboard":[4,"use-clipboard"],"columns":[16],"source":[16],"pinnedTopSource":[16],"pinnedBottomSource":[16],"rowDefinitions":[16],"editors":[16],"applyOnClose":[4,"apply-on-close"],"plugins":[16],"columnTypes":[16],"theme":[1537],"rowClass":[513,"row-class"],"autoSizeColumn":[4,"auto-size-column"],"filter":[4],"sorting":[16],"focusTemplate":[16],"canMoveColumns":[4,"can-move-columns"],"trimmedRows":[16],"exporting":[4],"grouping":[16],"stretch":[8],"additionalData":[16],"disableVirtualX":[4,"disable-virtual-x"],"disableVirtualY":[4,"disable-virtual-y"],"hideAttribution":[4,"hide-attribution"],"jobsBeforeRender":[16],"registerVNode":[16],"accessible":[4],"rtl":[4],"canDrag":[4,"can-drag"],"refresh":[64],"setDataAt":[64],"scrollToRow":[64],"scrollToColumnIndex":[64],"scrollToColumnProp":[64],"updateColumns":[64],"addTrimmed":[64],"scrollToCoordinate":[64],"setCellEdit":[64],"setCellsFocus":[64],"getSource":[64],"getVisibleSource":[64],"getSourceStore":[64],"getColumnStore":[64],"updateColumnSorting":[64],"clearSorting":[64],"getColumns":[64],"clearFocus":[64],"getPlugins":[64],"getFocused":[64],"getContentSize":[64],"getSelectedRange":[64],"refreshExtraElements":[64],"getProviders":[64]},[[5,"touchstart","mousedownHandle"],[5,"mousedown","mousedownHandle"],[5,"touchend","mouseupHandle"],[5,"mouseup","mouseupHandle"],[0,"rowdragstartinit","onRowDragStarted"],[0,"rowdragendinit","onRowDragEnd"],[0,"roworderchange","onRowOrderChange"],[0,"rowdragmoveinit","onRowDrag"],[0,"rowdragmousemove","onRowMouseMove"],[0,"celleditapply","onCellEdit"],[0,"rangeeditapply","onRangeEdit"],[0,"selectionchangeinit","onRangeChanged"],[0,"rowdropinit","onRowDropped"],[0,"beforeheaderclick","onHeaderClick"],[0,"beforecellfocusinit","onCellFocus"]],{"columnTypes":[{"columnTypesChanged":0}],"columns":[{"columnChanged":0}],"disableVirtualX":[{"disableVirtualXChanged":0}],"rowSize":[{"rowSizeChanged":0}],"theme":[{"themeChanged":0}],"source":[{"dataSourceChanged":0}],"pinnedBottomSource":[{"dataSourceChanged":0}],"pinnedTopSource":[{"dataSourceChanged":0}],"disableVirtualY":[{"disableVirtualYChanged":0}],"rowDefinitions":[{"rowDefChanged":0}],"trimmedRows":[{"trimmedRowsChanged":0}],"grouping":[{"groupingChanged":0}],"stretch":[{"applyStretch":0}],"filter":[{"applyFilter":0}],"sorting":[{"applySorting":0}],"rowHeaders":[{"rowHeadersChange":0}],"registerVNode":[{"registerOutsideVNodes":0}],"additionalData":[{"additionalDataChanged":0}],"rtl":[{"rtlChanged":0}],"plugins":[{"pluginsChanged":0}]}]]],["revogr-filter-panel",[[260,"revogr-filter-panel",{"filterNames":[16],"filterEntities":[16],"filterCaptions":[16],"disableDynamicFiltering":[4,"disable-dynamic-filtering"],"closeOnOutsideClick":[4,"close-on-outside-click"],"isFilterIdSet":[32],"filterId":[32],"currentFilterId":[32],"currentFilterType":[32],"changes":[32],"filterItems":[32],"draggedFilterId":[32],"dragOverFilterId":[32],"show":[64],"getChanges":[64]},[[5,"mousedown","onMouseDown"]]]]],["revogr-clipboard_3",[[0,"revogr-clipboard",{"readonly":[4],"doCopy":[64]},[[4,"paste","onPaste"],[4,"copy","copyStarted"],[4,"cut","cutStarted"]]],[0,"revogr-edit",{"editCell":[16],"column":[16],"editor":[16],"saveOnClose":[4,"save-on-close"],"additionalData":[8,"additional-data"],"cancelChanges":[64],"beforeDisconnect":[64]}],[0,"revogr-order-editor",{"parent":[16],"dimensionRow":[16],"dimensionCol":[16],"dataStore":[16],"rowType":[1,"row-type"],"dragStart":[64],"endOrder":[64],"clearOrder":[64]}]]],["revogr-data_4",[[260,"revogr-data",{"readonly":[4],"range":[4],"rowClass":[1,"row-class"],"additionalData":[8,"additional-data"],"rowSelectionStore":[16],"viewportRow":[16],"viewportCol":[16],"dimensionRow":[16],"colData":[16],"dataStore":[16],"type":[513],"colType":[513,"col-type"],"jobsBeforeRender":[16],"providers":[32],"updateCell":[64]},null,{"dataStore":[{"onDataStoreChange":0}],"colData":[{"onColDataChange":0}]}],[0,"revogr-header",{"viewportCol":[16],"dimensionCol":[16],"selectionStore":[16],"groups":[16],"groupingDepth":[2,"grouping-depth"],"readonly":[4],"canResize":[4,"can-resize"],"resizeHandler":[16],"colData":[16],"columnFilter":[4,"column-filter"],"type":[1],"additionalData":[8,"additional-data"]}],[260,"revogr-viewport-scroll",{"rowHeader":[4,"row-header"],"contentWidth":[2,"content-width"],"contentHeight":[2,"content-height"],"colType":[1,"col-type"],"noHorizontalScrollTransfer":[4,"no-horizontal-scroll-transfer"],"setScroll":[64],"changeScroll":[64],"applyScroll":[64]},[[0,"mousewheel-vertical","mousewheelVertical"],[0,"mousewheel-horizontal","mousewheelHorizontal"],[0,"scroll-coordinate","scrollApply"]]],[0,"vnode-html",{"redraw":[16]}]]],["revogr-attribution_7",[[0,"revogr-row-headers",{"height":[2],"dataPorts":[16],"headerProp":[16],"rowClass":[1,"row-class"],"resize":[4],"rowHeaderColumn":[16],"additionalData":[8,"additional-data"],"jobsBeforeRender":[16]}],[260,"revogr-overlay-selection",{"readonly":[4],"range":[4],"canDrag":[4,"can-drag"],"useClipboard":[4,"use-clipboard"],"selectionStore":[16],"dimensionRow":[16],"dimensionCol":[16],"dataStore":[16],"colData":[16],"lastCell":[16],"editors":[16],"applyChangesOnClose":[4,"apply-changes-on-close"],"additionalData":[8,"additional-data"],"isMobileDevice":[4,"is-mobile-device"]},[[5,"touchmove","onMouseMove"],[5,"mousemove","onMouseMove"],[5,"touchend","onMouseUp"],[5,"mouseup","onMouseUp"],[5,"mouseleave","onMouseUp"],[0,"dragstartcell","onCellDrag"],[4,"keyup","onKeyUp"],[4,"keydown","onKeyDown"]],{"selectionStore":[{"selectionServiceSet":0}],"dimensionRow":[{"createAutoFillService":0}],"dimensionCol":[{"createAutoFillService":0}],"dataStore":[{"columnServiceSet":0}],"colData":[{"columnServiceSet":0}]}],[0,"revogr-attribution"],[260,"revogr-focus",{"colType":[1,"col-type"],"rowType":[1,"row-type"],"selectionStore":[16],"dimensionRow":[16],"dimensionCol":[16],"dataStore":[16],"colData":[16],"focusTemplate":[16]}],[0,"revogr-scroll-virtual",{"dimension":[1],"realSize":[2,"real-size"],"virtualSize":[2,"virtual-size"],"clientSize":[2,"client-size"],"setScroll":[64],"changeScroll":[64]}],[0,"revogr-temp-range",{"selectionStore":[16],"dimensionRow":[16],"dimensionCol":[16]}],[0,"revogr-extra",{"nodes":[16],"update":[32],"refresh":[64]}]]]], options);
52
52
  });
@@ -4,7 +4,7 @@
4
4
  import { r as registerInstance, h, e as Host, d as createEvent, g as getElement } from './index-Chp_81rd.js';
5
5
  import { k as getItemByIndex, b as getSourceItem, j as getItemByPosition, F as FOCUS_CLASS, I as codesLetter, R as RESIZE_INTERVAL, y as MOBILE_CLASS, z as CELL_HANDLER_CLASS, S as SELECTION_BORDER_CLASS, D as DataStore, q as ROW_HEADER_TYPE, T as TMP_SELECTION_BG_CLASS } from './dimension.helpers-CGKwSvw6.js';
6
6
  import { g as getPropertyFromEvent, v as verifyTouchTarget } from './events-BvSmBueA.js';
7
- import { g as getRange, M as ColumnService, z as getCellData, N as getCellEditor, b as isRangeSingleCell } from './column.service-CC_SD8W3.js';
7
+ import { g as getRange, M as ColumnService, z as getCellData, N as getCellEditor, b as isRangeSingleCell } from './column.service-C6hByxPy.js';
8
8
  import { l as isShortcutModifier, m as isEditInput, c as isClear, d as isTab, f as isEnterKeyValue, h as isCopy, g as isCut, j as isPaste, k as isAll } from './edit.utils-Dnnbd0xG.js';
9
9
  import { t as timeout, g as getScrollbarSize } from './index-Db3qZoW5.js';
10
10
  import { d as debounce } from './debounce-PCRWZliA.js';
@@ -649,6 +649,30 @@ class AutoFillService {
649
649
  }
650
650
  }
651
651
 
652
+ function getRangeFillClipboardData(data, useClipboard) {
653
+ var _a;
654
+ if (!isClipboardRangeFillEnabled(useClipboard)) {
655
+ return null;
656
+ }
657
+ const normalized = trimTrailingEmptyClipboardRows(data);
658
+ return normalized.length === 1 && ((_a = normalized[0]) === null || _a === void 0 ? void 0 : _a.length) === 1
659
+ ? normalized
660
+ : null;
661
+ }
662
+ function isClipboardRangeFillEnabled(useClipboard) {
663
+ return (typeof useClipboard === 'object' && useClipboard.rangeFill === true);
664
+ }
665
+ function trimTrailingEmptyClipboardRows(data) {
666
+ const rows = [...data];
667
+ while (rows.length > 1 && isEmptyClipboardRow(rows[rows.length - 1])) {
668
+ rows.pop();
669
+ }
670
+ return rows;
671
+ }
672
+ function isEmptyClipboardRow(row) {
673
+ return !row || row.every(cell => cell === '');
674
+ }
675
+
652
676
  const revogrOverlayStyleCss = () => `revogr-overlay-selection{display:block;position:relative;width:100%}revogr-overlay-selection .autofill-handle{position:absolute;width:14px;height:14px;margin-left:-13px;margin-top:-13px;z-index:10;cursor:crosshair}revogr-overlay-selection .autofill-handle::before{content:"";position:absolute;right:0;bottom:0;width:10px;height:10px;background:#0d63e8;border:1px solid white;box-sizing:border-box}revogr-overlay-selection.mobile .autofill-handle{position:absolute;width:30px;height:30px;margin-left:-29px;margin-top:-29px;z-index:10;cursor:crosshair}revogr-overlay-selection.mobile .autofill-handle::before{content:"";position:absolute;right:0;bottom:0;width:12px;height:12px;background:#0d63e8;border:1px solid white;box-sizing:border-box}revogr-overlay-selection .selection-border-range{position:absolute;pointer-events:none;z-index:9;box-shadow:-1px 0 0 #0d63e8 inset, 1px 0 0 #0d63e8 inset, 0 -1px 0 #0d63e8 inset, 0 1px 0 #0d63e8 inset}revogr-overlay-selection .selection-border-range .range-handlers{height:100%;background-color:transparent;width:75%;max-width:50px;min-width:20px;left:50%;transform:translateX(-50%);position:absolute}revogr-overlay-selection .selection-border-range .range-handlers>span{pointer-events:auto;height:20px;width:20px;position:absolute;left:50%;transform:translateX(-50%)}revogr-overlay-selection .selection-border-range .range-handlers>span:before,revogr-overlay-selection .selection-border-range .range-handlers>span:after{position:absolute;border-radius:5px;width:15px;height:5px;left:50%;transform:translateX(-50%);background-color:rgba(0, 0, 0, 0.2)}revogr-overlay-selection .selection-border-range .range-handlers>span:first-child{top:-7px}revogr-overlay-selection .selection-border-range .range-handlers>span:first-child:before{content:"";top:0}revogr-overlay-selection .selection-border-range .range-handlers>span:last-child{bottom:-7px}revogr-overlay-selection .selection-border-range .range-handlers>span:last-child:after{content:"";bottom:0}revogr-overlay-selection revogr-edit{z-index:10}`;
653
677
 
654
678
  const OverlaySelection = class {
@@ -896,9 +920,9 @@ const OverlaySelection = class {
896
920
  nodes.push(h("revogr-order-editor", { ref: e => (this.orderEditor = e), dataStore: this.dataStore, dimensionRow: this.dimensionRow, dimensionCol: this.dimensionCol, parent: this.element, rowType: this.types.rowType, onRowdragstartinit: e => this.rowDragStart(e) }));
897
921
  }
898
922
  }
899
- return (h(Host, { key: 'd936e8452e84c7a25ecd6502e929f1a5af69467f', class: { mobile: this.isMobileDevice }, onDblClick: (e) => this.onElementDblClick(e), onMouseDown: (e) => this.onElementMouseDown(e), onTouchStart: (e) => this.onElementMouseDown(e, true), onCloseedit: (e) => this.closeEdit(e),
923
+ return (h(Host, { key: 'ff303c39d59e4ef217421fa11b9a80de07311b07', class: { mobile: this.isMobileDevice }, onDblClick: (e) => this.onElementDblClick(e), onMouseDown: (e) => this.onElementMouseDown(e), onTouchStart: (e) => this.onElementMouseDown(e, true), onCloseedit: (e) => this.closeEdit(e),
900
924
  // it's done to be able to throw events from different levels, not just from editor
901
- onCelledit: (e) => this.onEditCell(e) }, nodes, h("slot", { key: 'cd3525d404aa44fd8d06e7fc459777acb8a9d585', name: "data" })));
925
+ onCelledit: (e) => this.onEditCell(e) }, nodes, h("slot", { key: '3cbe4c3ad7d447f779e9e20f73eec2e3107275e0', name: "data" })));
902
926
  }
903
927
  /**
904
928
  * Executes the focus operation on the specified range of cells.
@@ -1063,13 +1087,25 @@ const OverlaySelection = class {
1063
1087
  if (!focus || isEditing) {
1064
1088
  return;
1065
1089
  }
1066
- let { changed, range } = this.columnService.getTransformedDataToApply(focus, data);
1090
+ const rangeFillData = getRangeFillClipboardData(data, this.useClipboard);
1091
+ const targetRange = rangeFillData
1092
+ ? this.getClipboardPasteTargetRange()
1093
+ : null;
1094
+ let { changed, range } = this.columnService.getTransformedDataToApply({
1095
+ start: focus,
1096
+ data: rangeFillData || data,
1097
+ targetRange,
1098
+ });
1067
1099
  const { defaultPrevented: canPaste } = this.rangeClipboardPaste.emit(Object.assign({ data: changed, models: collectModelsOfRange(changed, this.dataStore), range }, this.types));
1068
1100
  if (canPaste) {
1069
1101
  return;
1070
1102
  }
1071
1103
  (_a = this.autoFillService) === null || _a === void 0 ? void 0 : _a.onRangeApply(changed, range, range);
1072
1104
  }
1105
+ getClipboardPasteTargetRange() {
1106
+ const range = this.selectionStore.get('range');
1107
+ return range && !isRangeSingleCell(range) ? range : null;
1108
+ }
1073
1109
  async focusNext() {
1074
1110
  var _a;
1075
1111
  const canFocus = await ((_a = this.keyboardService) === null || _a === void 0 ? void 0 : _a.keyChangeSelection(new KeyboardEvent('keydown', {
@@ -143,7 +143,7 @@ const Clipboard = class {
143
143
  }
144
144
  getData(e) {
145
145
  return (e.clipboardData ||
146
- (window === null || window === void 0 ? void 0 : window.clipboardData));
146
+ (globalThis === null || globalThis === void 0 ? void 0 : globalThis.clipboardData));
147
147
  }
148
148
  };
149
149
 
@@ -2,11 +2,11 @@
2
2
  * Built by Revolist OU ❤️
3
3
  */
4
4
  import { r as registerInstance, d as createEvent, h, e as Host, g as getElement } from './index-Chp_81rd.js';
5
- import { M as ColumnService, u as isGrouping } from './column.service-CC_SD8W3.js';
5
+ import { M as ColumnService, u as isGrouping } from './column.service-C6hByxPy.js';
6
6
  import { B as ROW_FOCUSED_CLASS, b as getSourceItem, n as DATA_ROW, m as DATA_COL, M as MIN_COL_SIZE, r as HEADER_SORTABLE_CLASS, H as HEADER_CLASS, F as FOCUS_CLASS, k as getItemByIndex, u as HEADER_ROW_CLASS, v as HEADER_ACTUAL_ROW_CLASS } from './dimension.helpers-CGKwSvw6.js';
7
- import { G as GroupingRowRenderer, C as CellRenderer, R as RowRenderer, P as PADDING_DEPTH, S as SortingSign } from './cell-renderer-BtN-NGCk.js';
8
- import { c as FilterButton } from './filter.button-C8XTWPU2.js';
9
- import { H as HeaderCellRenderer } from './header-cell-renderer-B-LX2sgu.js';
7
+ import { G as GroupingRowRenderer, C as CellRenderer, R as RowRenderer, P as PADDING_DEPTH, S as SortingSign } from './cell-renderer-CLTRlCa5.js';
8
+ import { c as FilterButton } from './filter.button-B-RBiF67.js';
9
+ import { H as HeaderCellRenderer } from './header-cell-renderer-BMmXRsd_.js';
10
10
  import { t as throttle, L as LocalScrollTimer, a as LocalScrollService, g as getContentSize } from './throttle-CaUDyxyU.js';
11
11
  import { H as HEADER_SLOT, C as CONTENT_SLOT, F as FOOTER_SLOT } from './viewport.helpers-CoCAvmZs.js';
12
12
  import './debounce-PCRWZliA.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