@progress/kendo-react-grid 16.2.0-develop.6 → 16.2.0-develop.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.
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("../utils/index.js"),W=1,x=20;class S{constructor(a){this.columns=[],this.columnsState=[],this.resizable=!1,this.isRtl=!1,this.setIsRtl=c=>{this.isRtl=c},this.initWidths=()=>{var l;const c=((l=this.colGroupMain)==null?void 0:l.children)||[],o=p.getFlatColumnsState(this.columnsState),n=this.columns.filter(e=>{var r;return!((r=e.children)!=null&&r.length)});for(let e=0;e<c.length;e++){const r=n[e];let t="";const i=o.find(d=>d.id===n[e].id);i&&(t=this.applyWidthConstraints(i,r)),this.colGroups.forEach(d=>{d.children[e].width=t})}},this.dragHandler=(c,o,n,l)=>{const e=c.originalEvent;l||(e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation());const r=n.closest("th");if(!r)return;const t=r.clientWidth;let i=t;if(this.isRtl?i+=n.getBoundingClientRect().right-n.offsetWidth/2-c.clientX:i+=c.clientX-n.getBoundingClientRect().left-n.offsetWidth/2,!l&&Math.abs(i-t)<1)return;this.fixateInitialWidths(r.parentElement.clientWidth),this.setWidths(o,Math.floor(i)/t);const d=this.columns.filter(s=>!s.children.length).findIndex(s=>s.id===o.id);this.onResize(d,t,i,e,l,this.columnsState,o.id)},this.dblClickHandler=(c,o)=>{const n=this.columns.filter(h=>o.indexOf(h.id)>-1),l=p.getFlatColumnsState(this.columnsState);if(!this.colGroupMain||!n.length)return;const e={},r=n;for(;r.length>0;){const h=r.pop();if(!h)break;h.children.length?r.push(...h.children):e[h.id]=h}const t=this.columns.filter(h=>!h.children.length),i=[];t.forEach((h,u)=>{e[h.id]&&i.push(u)});const d=this.colGroups,s=d.map(h=>h.parentElement);s.forEach(h=>h.classList.add("k-autofitting"));const f=[];d.forEach(h=>{i.forEach(u=>{h.children[u]&&(h.children[u].width="",f[u]=Math.max(f[u]||0,h.children[u].offsetWidth+W))})}),d.forEach(h=>{i.forEach(u=>{if(h.children[u]){h.children[u].width=f[u]+"px";const g=l.find(m=>m.id===t[u].id);g&&(g.width=f[u])}})}),s.forEach(h=>h.classList.remove("k-autofitting")),this.onResize(i[0],0,0,c,!0,this.columnsState,o[0])},this.updateColElements=c=>{const o=this.columns.filter(l=>!l.hidden&&!l.children.length);let n=1e-10;for(let l=0;l<c.length;l++){const e=c[l],r=o.findIndex(f=>f.id===e.id),t=parseFloat((e.width||0).toString()),i=Math.floor(t);n+=t-i;const d=i+Math.floor(n);n-=Math.floor(n);const s=o.find(f=>f.id===e.id);if(!s)return;this.colGroups.forEach(f=>{if(f.children[r]){const h=parseInt(f.children[r].width,10);f.children[r].width=d+"px",this.updateNextLockedCol(f.parentElement,s,h-d)}})}},this.onResize=a}get colGroups(){return[this.colGroupMain,this.colGroupHeader,this.colGroupFooter,this.colGroupStickyHeader,this.colGroupStickyFooter,this.colGroupPinnedTop,this.colGroupPinnedBottom].filter(Boolean)}applyWidthConstraints(a,c,o=1){if(!a.width)return a.width||"";const n=a.width.toString();if(n.includes("%")){const f=parseFloat(n)*o,h=Math.max(0,Math.min(100,f));return a.width=h+"%",a.width}let e=parseFloat(n)*o;const r=c.minResizableWidth===void 0?10:c.minResizableWidth,t=c.minWidth,i=t!==void 0?Math.max(r,t):r,d=c.maxWidth;return e<i&&(e=i),d!==void 0&&e>d&&(e=d),a.width=e,e}fixateInitialWidths(a){var r;let c=0;const o=((r=this.colGroupMain)==null?void 0:r.children)||[];for(let t=0;t<o.length;t++)o[t].width?a-=o[t].clientWidth:c++;if(c===0)return;const n=Math.floor(a/c),l=p.getFlatColumnsState(this.columnsState),e=this.columns.filter(t=>!t.children.length);for(let t=0;t<o.length;t++){const i=o[t],d=i.width?i.clientWidth:n,s=l.find(f=>f.id===e[t].id);s&&(s.width=d.toString()),this.colGroups.forEach(f=>{f.children[t].width=d})}}setWidths(a,c){const o=p.getFlatColumnsState(this.columnsState),n=this.columns.findIndex(t=>t.id===a.id),l=[];let e=a.children.filter(t=>!t.hidden).length;for(let t=n+1;t<this.columns.length&&!(e<=0);t++){const i=this.columns[t];i.children.length?e+=i.children.filter(d=>!d.hidden).length:l.push(i),e--}l.length===0&&l.push(a);const r=[];l.forEach(t=>{const i=o.find(d=>d.id===t.id);i&&(this.applyWidthConstraints(i,t,c),r.push(i))}),this.updateColElements(r)}updateNextLockedCol(a,c,o){const n=c.index,l=this.colGroupMain.parentElement.closest(".k-grid"),e=l==null?void 0:l.clientWidth,r=this.columns.filter(t=>t.locked).map(t=>parseInt(t.width+"",10)).reduce((t,i)=>t+i,0);!c.locked||e<=r+x||this.columns.forEach(t=>{if(t!=null&&t.locked&&o){const i=a==null?void 0:a.querySelectorAll('[aria-colindex="'+t.ariaColumnIndex+'"]');i==null||i.forEach(d=>{const s=d.style;this.isRtl?(t.index>n&&s&&s.right&&(s.right=parseInt(s.right,10)-o+"px"),t.index<n&&s&&s.left&&(s.left=parseInt(s.left,10)-o+"px")):(t.index>n&&s&&s.left&&(s.left=parseInt(s.left,10)-o+"px"),t.index<n&&s&&s.right&&(s.right=parseInt(s.right,10)-o+"px"))})}})}}exports.ColumnResize=S;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("../utils/index.js"),W=1,w=20;class S{constructor(f){this.columns=[],this.columnsState=[],this.resizable=!1,this.isRtl=!1,this.setIsRtl=c=>{this.isRtl=c},this.initWidths=()=>{var l;const c=((l=this.colGroupMain)==null?void 0:l.children)||[],o=p.getFlatColumnsState(this.columnsState),s=this.columns.filter(e=>{var r;return!((r=e.children)!=null&&r.length)});for(let e=0;e<c.length;e++){const r=s[e];let t="";const i=o.find(d=>d.id===s[e].id);i&&(t=this.applyWidthConstraints(i,r)),this.colGroups.forEach(d=>{d.children[e].width=t})}},this.dragHandler=(c,o,s,l)=>{const e=c.originalEvent;l||(e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation());const r=s.closest("th");if(!r)return;const t=r.clientWidth;let i=t;if(this.isRtl?i+=s.getBoundingClientRect().right-s.offsetWidth/2-c.clientX:i+=c.clientX-s.getBoundingClientRect().left-s.offsetWidth/2,!l&&Math.abs(i-t)<1)return;this.fixateInitialWidths(r.parentElement.clientWidth),this.setWidths(o,Math.floor(i)/t);const d=this.columns.filter(n=>!n.children.length).findIndex(n=>n.id===o.id);this.onResize(d,t,i,e,l,this.columnsState,o.id)},this.dblClickHandler=(c,o)=>{const s=this.columns.filter(h=>o.indexOf(h.id)>-1),l=p.getFlatColumnsState(this.columnsState);if(!this.colGroupMain||!s.length)return;const e={},r=s;for(;r.length>0;){const h=r.pop();if(!h)break;h.children.length?r.push(...h.children):e[h.id]=h}const t=this.columns.filter(h=>!h.children.length),i=[];t.forEach((h,u)=>{e[h.id]&&i.push(u)});const d=this.colGroups,n=d.map(h=>h.parentElement);n.forEach(h=>h.classList.add("k-autofitting"));const a=[];d.forEach(h=>{i.forEach(u=>{h.children[u]&&(h.children[u].width="",a[u]=Math.max(a[u]||0,h.children[u].offsetWidth+W))})}),d.forEach(h=>{i.forEach(u=>{if(h.children[u]){h.children[u].width=a[u]+"px";const g=l.find(m=>m.id===t[u].id);g&&(g.width=a[u],t[u].width=a[u])}})}),n.forEach(h=>h.classList.remove("k-autofitting")),this.onResize(i[0],0,0,c,!0,this.columnsState,o[0])},this.updateColElements=c=>{const o=this.columns.filter(l=>!l.hidden&&!l.children.length);let s=1e-10;for(let l=0;l<c.length;l++){const e=c[l],r=o.findIndex(a=>a.id===e.id),t=parseFloat((e.width||0).toString()),i=Math.floor(t);s+=t-i;const d=i+Math.floor(s);s-=Math.floor(s);const n=o.find(a=>a.id===e.id);if(!n)return;this.colGroups.forEach(a=>{if(a.children[r]){const h=parseInt(a.children[r].width,10);a.children[r].width=d+"px",this.updateNextLockedCol(a.parentElement,n,h-d)}})}},this.onResize=f}get colGroups(){return[this.colGroupMain,this.colGroupHeader,this.colGroupFooter,this.colGroupStickyHeader,this.colGroupStickyFooter,this.colGroupPinnedTop,this.colGroupPinnedBottom].filter(Boolean)}applyWidthConstraints(f,c,o=1){if(!f.width)return f.width||"";const s=f.width.toString();if(s.includes("%")){const a=parseFloat(s)*o,h=Math.max(0,Math.min(100,a));return f.width=h+"%",f.width}let e=parseFloat(s)*o;const r=c.minResizableWidth===void 0?10:c.minResizableWidth,t=c.minWidth,i=t!==void 0?Math.max(r,t):r,d=c.maxWidth;return e<i&&(e=i),d!==void 0&&e>d&&(e=d),f.width=e,e}fixateInitialWidths(f){var r;let c=0;const o=((r=this.colGroupMain)==null?void 0:r.children)||[];for(let t=0;t<o.length;t++)o[t].width?f-=o[t].clientWidth:c++;if(c===0)return;const s=Math.floor(f/c),l=p.getFlatColumnsState(this.columnsState),e=this.columns.filter(t=>!t.children.length);for(let t=0;t<o.length;t++){const i=o[t],d=i.width?i.clientWidth:s,n=l.find(a=>a.id===e[t].id);n&&(n.width=d.toString(),e[t].width=n.width),this.colGroups.forEach(a=>{a.children[t].width=d})}}setWidths(f,c){const o=p.getFlatColumnsState(this.columnsState),s=this.columns.findIndex(t=>t.id===f.id),l=[];let e=f.children.filter(t=>!t.hidden).length;for(let t=s+1;t<this.columns.length&&!(e<=0);t++){const i=this.columns[t];i.children.length?e+=i.children.filter(d=>!d.hidden).length:l.push(i),e--}l.length===0&&l.push(s>=0?this.columns[s]:f);const r=[];l.forEach(t=>{const i=o.find(d=>d.id===t.id);i&&(this.applyWidthConstraints(i,t,c),t.width=i.width,r.push(i))}),this.updateColElements(r)}updateNextLockedCol(f,c,o){const s=c.index,l=this.colGroupMain.parentElement.closest(".k-grid"),e=l==null?void 0:l.clientWidth,r=this.columns.filter(t=>t.locked).map(t=>parseInt(t.width+"",10)).reduce((t,i)=>t+i,0);!c.locked||e<=r+w||this.columns.forEach(t=>{if(t!=null&&t.locked&&o){const i=f==null?void 0:f.querySelectorAll('[aria-colindex="'+t.ariaColumnIndex+'"]');i==null||i.forEach(d=>{const n=d.style;this.isRtl?(t.index>s&&n&&n.right&&(n.right=parseInt(n.right,10)-o+"px"),t.index<s&&n&&n.left&&(n.left=parseInt(n.left,10)-o+"px")):(t.index>s&&n&&n.left&&(n.left=parseInt(n.left,10)-o+"px"),t.index<s&&n&&n.right&&(n.right=parseInt(n.right,10)-o+"px"))})}})}}exports.ColumnResize=S;
@@ -5,44 +5,44 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import { getFlatColumnsState as p } from "../utils/index.mjs";
9
- const W = 1, x = 20;
8
+ import { getFlatColumnsState as u } from "../utils/index.mjs";
9
+ const W = 1, w = 20;
10
10
  class S {
11
- constructor(a) {
11
+ constructor(f) {
12
12
  this.columns = [], this.columnsState = [], this.resizable = !1, this.isRtl = !1, this.setIsRtl = (c) => {
13
13
  this.isRtl = c;
14
14
  }, this.initWidths = () => {
15
15
  var l;
16
- const c = ((l = this.colGroupMain) == null ? void 0 : l.children) || [], o = p(this.columnsState), n = this.columns.filter((e) => {
16
+ const c = ((l = this.colGroupMain) == null ? void 0 : l.children) || [], o = u(this.columnsState), s = this.columns.filter((e) => {
17
17
  var r;
18
18
  return !((r = e.children) != null && r.length);
19
19
  });
20
20
  for (let e = 0; e < c.length; e++) {
21
- const r = n[e];
21
+ const r = s[e];
22
22
  let t = "";
23
- const i = o.find((d) => d.id === n[e].id);
23
+ const i = o.find((d) => d.id === s[e].id);
24
24
  i && (t = this.applyWidthConstraints(i, r)), this.colGroups.forEach((d) => {
25
25
  d.children[e].width = t;
26
26
  });
27
27
  }
28
- }, this.dragHandler = (c, o, n, l) => {
28
+ }, this.dragHandler = (c, o, s, l) => {
29
29
  const e = c.originalEvent;
30
30
  l || (e.preventDefault(), e.stopPropagation(), e.stopImmediatePropagation());
31
- const r = n.closest("th");
31
+ const r = s.closest("th");
32
32
  if (!r)
33
33
  return;
34
34
  const t = r.clientWidth;
35
35
  let i = t;
36
- if (this.isRtl ? i += n.getBoundingClientRect().right - n.offsetWidth / 2 - c.clientX : i += c.clientX - n.getBoundingClientRect().left - n.offsetWidth / 2, !l && Math.abs(i - t) < 1)
36
+ if (this.isRtl ? i += s.getBoundingClientRect().right - s.offsetWidth / 2 - c.clientX : i += c.clientX - s.getBoundingClientRect().left - s.offsetWidth / 2, !l && Math.abs(i - t) < 1)
37
37
  return;
38
38
  this.fixateInitialWidths(r.parentElement.clientWidth), this.setWidths(o, Math.floor(i) / t);
39
- const d = this.columns.filter((s) => !s.children.length).findIndex((s) => s.id === o.id);
39
+ const d = this.columns.filter((n) => !n.children.length).findIndex((n) => n.id === o.id);
40
40
  this.onResize(d, t, i, e, l, this.columnsState, o.id);
41
41
  }, this.dblClickHandler = (c, o) => {
42
- const n = this.columns.filter((h) => o.indexOf(h.id) > -1), l = p(this.columnsState);
43
- if (!this.colGroupMain || !n.length)
42
+ const s = this.columns.filter((h) => o.indexOf(h.id) > -1), l = u(this.columnsState);
43
+ if (!this.colGroupMain || !s.length)
44
44
  return;
45
- const e = {}, r = n;
45
+ const e = {}, r = s;
46
46
  for (; r.length > 0; ) {
47
47
  const h = r.pop();
48
48
  if (!h)
@@ -50,47 +50,47 @@ class S {
50
50
  h.children.length ? r.push(...h.children) : e[h.id] = h;
51
51
  }
52
52
  const t = this.columns.filter((h) => !h.children.length), i = [];
53
- t.forEach((h, u) => {
54
- e[h.id] && i.push(u);
53
+ t.forEach((h, p) => {
54
+ e[h.id] && i.push(p);
55
55
  });
56
- const d = this.colGroups, s = d.map((h) => h.parentElement);
57
- s.forEach((h) => h.classList.add("k-autofitting"));
58
- const f = [];
56
+ const d = this.colGroups, n = d.map((h) => h.parentElement);
57
+ n.forEach((h) => h.classList.add("k-autofitting"));
58
+ const a = [];
59
59
  d.forEach((h) => {
60
- i.forEach((u) => {
61
- h.children[u] && (h.children[u].width = "", f[u] = Math.max(
62
- f[u] || 0,
63
- h.children[u].offsetWidth + W
60
+ i.forEach((p) => {
61
+ h.children[p] && (h.children[p].width = "", a[p] = Math.max(
62
+ a[p] || 0,
63
+ h.children[p].offsetWidth + W
64
64
  ));
65
65
  });
66
66
  }), d.forEach((h) => {
67
- i.forEach((u) => {
68
- if (h.children[u]) {
69
- h.children[u].width = f[u] + "px";
70
- const g = l.find((m) => m.id === t[u].id);
71
- g && (g.width = f[u]);
67
+ i.forEach((p) => {
68
+ if (h.children[p]) {
69
+ h.children[p].width = a[p] + "px";
70
+ const g = l.find((m) => m.id === t[p].id);
71
+ g && (g.width = a[p], t[p].width = a[p]);
72
72
  }
73
73
  });
74
- }), s.forEach((h) => h.classList.remove("k-autofitting")), this.onResize(i[0], 0, 0, c, !0, this.columnsState, o[0]);
74
+ }), n.forEach((h) => h.classList.remove("k-autofitting")), this.onResize(i[0], 0, 0, c, !0, this.columnsState, o[0]);
75
75
  }, this.updateColElements = (c) => {
76
76
  const o = this.columns.filter((l) => !l.hidden && !l.children.length);
77
- let n = 1e-10;
77
+ let s = 1e-10;
78
78
  for (let l = 0; l < c.length; l++) {
79
- const e = c[l], r = o.findIndex((f) => f.id === e.id), t = parseFloat((e.width || 0).toString()), i = Math.floor(t);
80
- n += t - i;
81
- const d = i + Math.floor(n);
82
- n -= Math.floor(n);
83
- const s = o.find((f) => f.id === e.id);
84
- if (!s)
79
+ const e = c[l], r = o.findIndex((a) => a.id === e.id), t = parseFloat((e.width || 0).toString()), i = Math.floor(t);
80
+ s += t - i;
81
+ const d = i + Math.floor(s);
82
+ s -= Math.floor(s);
83
+ const n = o.find((a) => a.id === e.id);
84
+ if (!n)
85
85
  return;
86
- this.colGroups.forEach((f) => {
87
- if (f.children[r]) {
88
- const h = parseInt(f.children[r].width, 10);
89
- f.children[r].width = d + "px", this.updateNextLockedCol(f.parentElement, s, h - d);
86
+ this.colGroups.forEach((a) => {
87
+ if (a.children[r]) {
88
+ const h = parseInt(a.children[r].width, 10);
89
+ a.children[r].width = d + "px", this.updateNextLockedCol(a.parentElement, n, h - d);
90
90
  }
91
91
  });
92
92
  }
93
- }, this.onResize = a;
93
+ }, this.onResize = f;
94
94
  }
95
95
  get colGroups() {
96
96
  return [
@@ -103,56 +103,56 @@ class S {
103
103
  this.colGroupPinnedBottom
104
104
  ].filter(Boolean);
105
105
  }
106
- applyWidthConstraints(a, c, o = 1) {
107
- if (!a.width)
108
- return a.width || "";
109
- const n = a.width.toString();
110
- if (n.includes("%")) {
111
- const f = parseFloat(n) * o, h = Math.max(0, Math.min(100, f));
112
- return a.width = h + "%", a.width;
106
+ applyWidthConstraints(f, c, o = 1) {
107
+ if (!f.width)
108
+ return f.width || "";
109
+ const s = f.width.toString();
110
+ if (s.includes("%")) {
111
+ const a = parseFloat(s) * o, h = Math.max(0, Math.min(100, a));
112
+ return f.width = h + "%", f.width;
113
113
  }
114
- let e = parseFloat(n) * o;
114
+ let e = parseFloat(s) * o;
115
115
  const r = c.minResizableWidth === void 0 ? 10 : c.minResizableWidth, t = c.minWidth, i = t !== void 0 ? Math.max(r, t) : r, d = c.maxWidth;
116
- return e < i && (e = i), d !== void 0 && e > d && (e = d), a.width = e, e;
116
+ return e < i && (e = i), d !== void 0 && e > d && (e = d), f.width = e, e;
117
117
  }
118
- fixateInitialWidths(a) {
118
+ fixateInitialWidths(f) {
119
119
  var r;
120
120
  let c = 0;
121
121
  const o = ((r = this.colGroupMain) == null ? void 0 : r.children) || [];
122
122
  for (let t = 0; t < o.length; t++)
123
- o[t].width ? a -= o[t].clientWidth : c++;
123
+ o[t].width ? f -= o[t].clientWidth : c++;
124
124
  if (c === 0)
125
125
  return;
126
- const n = Math.floor(a / c), l = p(this.columnsState), e = this.columns.filter((t) => !t.children.length);
126
+ const s = Math.floor(f / c), l = u(this.columnsState), e = this.columns.filter((t) => !t.children.length);
127
127
  for (let t = 0; t < o.length; t++) {
128
- const i = o[t], d = i.width ? i.clientWidth : n, s = l.find((f) => f.id === e[t].id);
129
- s && (s.width = d.toString()), this.colGroups.forEach((f) => {
130
- f.children[t].width = d;
128
+ const i = o[t], d = i.width ? i.clientWidth : s, n = l.find((a) => a.id === e[t].id);
129
+ n && (n.width = d.toString(), e[t].width = n.width), this.colGroups.forEach((a) => {
130
+ a.children[t].width = d;
131
131
  });
132
132
  }
133
133
  }
134
- setWidths(a, c) {
135
- const o = p(this.columnsState), n = this.columns.findIndex((t) => t.id === a.id), l = [];
136
- let e = a.children.filter((t) => !t.hidden).length;
137
- for (let t = n + 1; t < this.columns.length && !(e <= 0); t++) {
134
+ setWidths(f, c) {
135
+ const o = u(this.columnsState), s = this.columns.findIndex((t) => t.id === f.id), l = [];
136
+ let e = f.children.filter((t) => !t.hidden).length;
137
+ for (let t = s + 1; t < this.columns.length && !(e <= 0); t++) {
138
138
  const i = this.columns[t];
139
139
  i.children.length ? e += i.children.filter((d) => !d.hidden).length : l.push(i), e--;
140
140
  }
141
- l.length === 0 && l.push(a);
141
+ l.length === 0 && l.push(s >= 0 ? this.columns[s] : f);
142
142
  const r = [];
143
143
  l.forEach((t) => {
144
144
  const i = o.find((d) => d.id === t.id);
145
- i && (this.applyWidthConstraints(i, t, c), r.push(i));
145
+ i && (this.applyWidthConstraints(i, t, c), t.width = i.width, r.push(i));
146
146
  }), this.updateColElements(r);
147
147
  }
148
- updateNextLockedCol(a, c, o) {
149
- const n = c.index, l = this.colGroupMain.parentElement.closest(".k-grid"), e = l == null ? void 0 : l.clientWidth, r = this.columns.filter((t) => t.locked).map((t) => parseInt(t.width + "", 10)).reduce((t, i) => t + i, 0);
150
- !c.locked || e <= r + x || this.columns.forEach((t) => {
148
+ updateNextLockedCol(f, c, o) {
149
+ const s = c.index, l = this.colGroupMain.parentElement.closest(".k-grid"), e = l == null ? void 0 : l.clientWidth, r = this.columns.filter((t) => t.locked).map((t) => parseInt(t.width + "", 10)).reduce((t, i) => t + i, 0);
150
+ !c.locked || e <= r + w || this.columns.forEach((t) => {
151
151
  if (t != null && t.locked && o) {
152
- const i = a == null ? void 0 : a.querySelectorAll('[aria-colindex="' + t.ariaColumnIndex + '"]');
152
+ const i = f == null ? void 0 : f.querySelectorAll('[aria-colindex="' + t.ariaColumnIndex + '"]');
153
153
  i == null || i.forEach((d) => {
154
- const s = d.style;
155
- this.isRtl ? (t.index > n && s && s.right && (s.right = parseInt(s.right, 10) - o + "px"), t.index < n && s && s.left && (s.left = parseInt(s.left, 10) - o + "px")) : (t.index > n && s && s.left && (s.left = parseInt(s.left, 10) - o + "px"), t.index < n && s && s.right && (s.right = parseInt(s.right, 10) - o + "px"));
154
+ const n = d.style;
155
+ this.isRtl ? (t.index > s && n && n.right && (n.right = parseInt(n.right, 10) - o + "px"), t.index < s && n && n.left && (n.left = parseInt(n.left, 10) - o + "px")) : (t.index > s && n && n.left && (n.left = parseInt(n.left, 10) - o + "px"), t.index < s && n && n.right && (n.right = parseInt(n.right, 10) - o + "px"));
156
156
  });
157
157
  }
158
158
  });
@@ -23,11 +23,20 @@ export interface GridScrollableSettings {
23
23
  * Controls the scrollbar rendering style.
24
24
  *
25
25
  * - `default`&mdash;Uses the native browser scrollbar (default).
26
- * - `proxied`&mdash;Renders a custom overlay scrollbar on top of the content area.
27
- * The overlay appears on hover or scroll and hides when idle,
26
+ * - `proxied`&mdash;Renders a native scrollbar-based overlay on top of the content area,
28
27
  * eliminating the white-space flash during virtual scrolling jumps.
29
28
  *
30
29
  * @default 'default'
31
30
  */
32
31
  scrollbar?: 'default' | 'proxied';
32
+ /**
33
+ * Multiplies the scrolling distance reported by mouse-wheel and trackpad input.
34
+ * Applies to the `scrollable` and `virtual` modes with both scrollbar styles.
35
+ *
36
+ * Must be a positive, finite number. Values that are zero, negative, `NaN`, or `Infinity`
37
+ * fall back to the default.
38
+ *
39
+ * @default 1
40
+ */
41
+ wheelMultiplier?: number;
33
42
  }
@@ -6,7 +6,7 @@
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
8
  import { Page } from '../paging/Page';
9
- import { SyntheticEvent } from 'react';
9
+ import { RefObject, SyntheticEvent } from 'react';
10
10
  import { RowHeightService } from '@progress/kendo-react-common';
11
11
  /**
12
12
  * @hidden
@@ -24,6 +24,7 @@ export interface VirtualScrollInterface {
24
24
  tableTransform: string;
25
25
  rowHeightService?: RowHeightService;
26
26
  scrollbarOverlaySpacerElement: HTMLDivElement | null;
27
+ overlaySyncingRef: RefObject<boolean> | null;
27
28
  reset: () => void;
28
29
  scrollHandler(e: SyntheticEvent<HTMLDivElement>): void;
29
30
  scrollToPosition(scrollTop: number, e: SyntheticEvent<HTMLDivElement>, deferTranslate?: boolean): void;
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=Object.freeze({name:"@progress/kendo-react-grid",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate: 1789468825,version:"16.2.0-develop.6",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"});exports.packageMetadata=e;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=Object.freeze({name:"@progress/kendo-react-grid",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate: 1789735540,version:"16.2.0-develop.8",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"});exports.packageMetadata=e;
@@ -7,7 +7,7 @@ export const packageMetadata = Object.freeze({
7
7
  productName: 'KendoReact',
8
8
  productCode: 'KENDOUIREACT',
9
9
  productCodes: ['KENDOUIREACT'],
10
- publishDate: 1789468825,
11
- version: '16.2.0-develop.6',
10
+ publishDate: 1789735540,
11
+ version: '16.2.0-develop.8',
12
12
  licensingDocsUrl: 'https://www.telerik.com/kendo-react-ui/components/my-license/'
13
13
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@progress/kendo-react-grid",
3
- "version": "16.2.0-develop.6",
3
+ "version": "16.2.0-develop.8",
4
4
  "description": "React Data Grid (Table) provides 100+ ready-to-use data grid features. KendoReact Grid package",
5
5
  "author": "Progress",
6
6
  "license": "SEE LICENSE IN LICENSE.md",
@@ -30,21 +30,21 @@
30
30
  "@progress/kendo-drawing": "^1.25.5",
31
31
  "@progress/kendo-file-saver": "^1.1.1",
32
32
  "@progress/kendo-licensing": "^1.7.2",
33
- "@progress/kendo-react-animation": "16.2.0-develop.6",
34
- "@progress/kendo-react-buttons": "16.2.0-develop.6",
35
- "@progress/kendo-react-common": "16.2.0-develop.6",
36
- "@progress/kendo-react-data-tools": "16.2.0-develop.6",
37
- "@progress/kendo-react-dateinputs": "16.2.0-develop.6",
38
- "@progress/kendo-react-indicators": "16.2.0-develop.6",
39
- "@progress/kendo-react-form": "16.2.0-develop.6",
40
- "@progress/kendo-react-labels": "16.2.0-develop.6",
41
- "@progress/kendo-react-dialogs": "16.2.0-develop.6",
42
- "@progress/kendo-react-dropdowns": "16.2.0-develop.6",
43
- "@progress/kendo-react-inputs": "16.2.0-develop.6",
44
- "@progress/kendo-react-intl": "16.2.0-develop.6",
45
- "@progress/kendo-react-popup": "16.2.0-develop.6",
46
- "@progress/kendo-react-layout": "16.2.0-develop.6",
47
- "@progress/kendo-react-conversational-ui": "16.2.0-develop.6",
33
+ "@progress/kendo-react-animation": "16.2.0-develop.8",
34
+ "@progress/kendo-react-buttons": "16.2.0-develop.8",
35
+ "@progress/kendo-react-common": "16.2.0-develop.8",
36
+ "@progress/kendo-react-data-tools": "16.2.0-develop.8",
37
+ "@progress/kendo-react-dateinputs": "16.2.0-develop.8",
38
+ "@progress/kendo-react-indicators": "16.2.0-develop.8",
39
+ "@progress/kendo-react-form": "16.2.0-develop.8",
40
+ "@progress/kendo-react-labels": "16.2.0-develop.8",
41
+ "@progress/kendo-react-dialogs": "16.2.0-develop.8",
42
+ "@progress/kendo-react-dropdowns": "16.2.0-develop.8",
43
+ "@progress/kendo-react-inputs": "16.2.0-develop.8",
44
+ "@progress/kendo-react-intl": "16.2.0-develop.8",
45
+ "@progress/kendo-react-popup": "16.2.0-develop.8",
46
+ "@progress/kendo-react-layout": "16.2.0-develop.8",
47
+ "@progress/kendo-react-conversational-ui": "16.2.0-develop.8",
48
48
  "@progress/kendo-svg-icons": "^4.9.0 || ^5.0.0",
49
49
  "react": "^18.0.0 || ^19.0.0",
50
50
  "react-dom": "^18.0.0 || ^19.0.0"
@@ -155,7 +155,7 @@
155
155
  "package": {
156
156
  "productName": "KendoReact",
157
157
  "productCode": "KENDOUIREACT",
158
- "publishDate": 1789468825,
158
+ "publishDate": 1789735540,
159
159
  "licensingDocsUrl": "https://www.telerik.com/kendo-react-ui/components/my-license/"
160
160
  }
161
161
  },
@@ -0,0 +1,48 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ import { GridScrollableSettings } from '../interfaces/GridScrollableSettings';
9
+ import { ScrollMode } from '../ScrollMode';
10
+ /**
11
+ * @hidden
12
+ */
13
+ export interface ScrollableOverlaySettings {
14
+ overlayScrollbar: boolean;
15
+ wheelMultiplier: number;
16
+ }
17
+ /**
18
+ * @hidden
19
+ */
20
+ export declare function getScrollableOverlaySettings(scrollable: ScrollMode | GridScrollableSettings | undefined): ScrollableOverlaySettings;
21
+ /**
22
+ * @hidden
23
+ * Reports whether the proxied scrollbar overlay is currently scrolled to its bottom edge.
24
+ * Must be called BEFORE the overlay's spacer height is updated for a new page — its
25
+ * `scrollHeight` reflects the size from the PREVIOUS render, which is what "was it at the
26
+ * bottom" needs to check against. Only reports true when the page being applied is genuinely
27
+ * the last page — the overlay's own scrollTop can still read "at bottom" from a stale prior
28
+ * position (e.g. right after scrolling back up), which would otherwise incorrectly snap the
29
+ * content back down.
30
+ */
31
+ export declare function isOverlayAtBottom(scrollbarOverlaySpacerElement: HTMLDivElement | null, isLastPageLoad: boolean): boolean;
32
+ /**
33
+ * @hidden
34
+ */
35
+ export interface OverlayBottomPin {
36
+ scrollbarOverlay: HTMLDivElement;
37
+ overlayScrollTop: number;
38
+ contentScrollTop: number;
39
+ }
40
+ /**
41
+ * @hidden
42
+ * Computes the scrollTop values needed to keep the proxied scrollbar overlay pinned to the
43
+ * bottom, or `null` when there's no overlay/container to pin. Must be called AFTER the
44
+ * overlay's spacer height has been updated for the new page, so `scrollHeight` reflects the
45
+ * new size — pair with `isOverlayAtBottom()` (called before the resize) to decide whether to
46
+ * apply the result.
47
+ */
48
+ export declare function getOverlayBottomPin(scrollbarOverlaySpacerElement: HTMLDivElement | null, container: HTMLDivElement | null): OverlayBottomPin | null;
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function e(i){const o=typeof i=="object"?i:void 0,t=o==null?void 0:o.wheelMultiplier;return{overlayScrollbar:(o==null?void 0:o.scrollbar)==="proxied",wheelMultiplier:typeof t=="number"&&Number.isFinite(t)&&t>0?t:1}}function l(i,o){const t=i==null?void 0:i.parentElement;return o&&!!t&&t.scrollHeight-t.clientHeight-t.scrollTop<=1}function n(i,o){const t=i==null?void 0:i.parentElement;return!t||!o?null:{scrollbarOverlay:t,overlayScrollTop:t.scrollHeight-t.clientHeight,contentScrollTop:o.scrollHeight-o.clientHeight}}exports.getOverlayBottomPin=n;exports.getScrollableOverlaySettings=e;exports.isOverlayAtBottom=l;
@@ -0,0 +1,31 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ function n(i) {
9
+ const o = typeof i == "object" ? i : void 0, t = o == null ? void 0 : o.wheelMultiplier;
10
+ return {
11
+ overlayScrollbar: (o == null ? void 0 : o.scrollbar) === "proxied",
12
+ wheelMultiplier: typeof t == "number" && Number.isFinite(t) && t > 0 ? t : 1
13
+ };
14
+ }
15
+ function u(i, o) {
16
+ const t = i == null ? void 0 : i.parentElement;
17
+ return o && !!t && t.scrollHeight - t.clientHeight - t.scrollTop <= 1;
18
+ }
19
+ function l(i, o) {
20
+ const t = i == null ? void 0 : i.parentElement;
21
+ return !t || !o ? null : {
22
+ scrollbarOverlay: t,
23
+ overlayScrollTop: t.scrollHeight - t.clientHeight,
24
+ contentScrollTop: o.scrollHeight - o.clientHeight
25
+ };
26
+ }
27
+ export {
28
+ l as getOverlayBottomPin,
29
+ n as getScrollableOverlaySettings,
30
+ u as isOverlayAtBottom
31
+ };
@@ -0,0 +1,21 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ /**
9
+ * @hidden
10
+ */
11
+ export interface WheelTouchScrollOptions {
12
+ wheelMultiplier: number;
13
+ overlayRequiresCustomWheel: boolean;
14
+ }
15
+ /**
16
+ * @hidden
17
+ * Attaches native (non-React) wheel and touch listeners to `container` so the grid can apply a
18
+ * `wheelMultiplier` and/or restore scrolling when the proxied overlay hides native overflow.
19
+ * Returns a cleanup function that removes the listeners.
20
+ */
21
+ export declare function attachWheelTouchScroll(container: HTMLDivElement, options: WheelTouchScrollOptions): () => void;
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const A=16,X=1,W=2,I=.95,d=.1;function b(e,S){const{wheelMultiplier:m,overlayRequiresCustomWheel:M}=S;let f;const _=()=>{var t;if(f===void 0){const i=(t=e.ownerDocument.defaultView)==null?void 0:t.getComputedStyle(e).lineHeight;f=Number.parseFloat(i||"")||A}return f},L=t=>{if(t.ctrlKey||t.metaKey||!t.deltaY&&!t.deltaX)return;const i=e.scrollTop,h=e.scrollLeft;let l=t.deltaX,s=t.deltaY;if(t.shiftKey&&!l&&(l=s,s=0),t.deltaMode===X){const c=_();l*=c,s*=c}else t.deltaMode===W&&(l*=e.clientWidth,s*=e.clientHeight);e.scrollTop+=s*m,e.scrollLeft+=l*m,(e.scrollTop!==i||e.scrollLeft!==h)&&t.preventDefault()};e.addEventListener("wheel",L,{passive:!1});let r;if(M){let t=0,i=0,h=0,l=0,s=0,c;const T=()=>{c!==void 0&&(cancelAnimationFrame(c),c=void 0)},p=()=>{e.scrollTop+=s,e.scrollLeft+=l,s*=I,l*=I,Math.abs(s)>d||Math.abs(l)>d?c=requestAnimationFrame(p):c=void 0},E=o=>{o.touches.length===1&&(T(),l=0,s=0,t=o.touches[0].clientX,i=o.touches[0].clientY,h=o.timeStamp)},n=o=>{if(o.touches.length!==1)return;const a=o.touches[0],v=t-a.clientX,g=i-a.clientY,H=Math.min(Math.max(o.timeStamp-h,1),100),Y=e.scrollTop,y=e.scrollLeft;e.scrollTop+=g,e.scrollLeft+=v,s=g/H*(1e3/60),l=v/H*(1e3/60),t=a.clientX,i=a.clientY,h=o.timeStamp,(e.scrollTop!==Y||e.scrollLeft!==y)&&o.preventDefault()},u=o=>{o.touches.length>0||(Math.abs(s)>d||Math.abs(l)>d)&&(c=requestAnimationFrame(p))};e.addEventListener("touchstart",E,{passive:!0}),e.addEventListener("touchmove",n,{passive:!1}),e.addEventListener("touchend",u,{passive:!0}),e.addEventListener("touchcancel",u,{passive:!0}),r=()=>{T(),e.removeEventListener("touchstart",E),e.removeEventListener("touchmove",n),e.removeEventListener("touchend",u),e.removeEventListener("touchcancel",u)}}return()=>{e.removeEventListener("wheel",L),r==null||r()}}exports.attachWheelTouchScroll=b;
@@ -0,0 +1,57 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ function O(e, n) {
9
+ const { wheelMultiplier: L, overlayRequiresCustomWheel: N } = n;
10
+ let u;
11
+ const v = () => {
12
+ var t;
13
+ if (u === void 0) {
14
+ const i = (t = e.ownerDocument.defaultView) == null ? void 0 : t.getComputedStyle(e).lineHeight;
15
+ u = Number.parseFloat(i || "") || 16;
16
+ }
17
+ return u;
18
+ }, a = (t) => {
19
+ if (t.ctrlKey || t.metaKey || !t.deltaY && !t.deltaX)
20
+ return;
21
+ const i = e.scrollTop, h = e.scrollLeft;
22
+ let l = t.deltaX, s = t.deltaY;
23
+ if (t.shiftKey && !l && (l = s, s = 0), t.deltaMode === 1) {
24
+ const c = v();
25
+ l *= c, s *= c;
26
+ } else t.deltaMode === 2 && (l *= e.clientWidth, s *= e.clientHeight);
27
+ e.scrollTop += s * L, e.scrollLeft += l * L, (e.scrollTop !== i || e.scrollLeft !== h) && t.preventDefault();
28
+ };
29
+ e.addEventListener("wheel", a, { passive: !1 });
30
+ let E;
31
+ if (N) {
32
+ let t = 0, i = 0, h = 0, l = 0, s = 0, c;
33
+ const I = () => {
34
+ c !== void 0 && (cancelAnimationFrame(c), c = void 0);
35
+ }, d = () => {
36
+ e.scrollTop += s, e.scrollLeft += l, s *= 0.95, l *= 0.95, Math.abs(s) > 0.1 || Math.abs(l) > 0.1 ? c = requestAnimationFrame(d) : c = void 0;
37
+ }, _ = (o) => {
38
+ o.touches.length === 1 && (I(), l = 0, s = 0, t = o.touches[0].clientX, i = o.touches[0].clientY, h = o.timeStamp);
39
+ }, f = (o) => {
40
+ if (o.touches.length !== 1)
41
+ return;
42
+ const r = o.touches[0], m = t - r.clientX, p = i - r.clientY, H = Math.min(Math.max(o.timeStamp - h, 1), 100), A = e.scrollTop, C = e.scrollLeft;
43
+ e.scrollTop += p, e.scrollLeft += m, s = p / H * (1e3 / 60), l = m / H * (1e3 / 60), t = r.clientX, i = r.clientY, h = o.timeStamp, (e.scrollTop !== A || e.scrollLeft !== C) && o.preventDefault();
44
+ }, T = (o) => {
45
+ o.touches.length > 0 || (Math.abs(s) > 0.1 || Math.abs(l) > 0.1) && (c = requestAnimationFrame(d));
46
+ };
47
+ e.addEventListener("touchstart", _, { passive: !0 }), e.addEventListener("touchmove", f, { passive: !1 }), e.addEventListener("touchend", T, { passive: !0 }), e.addEventListener("touchcancel", T, { passive: !0 }), E = () => {
48
+ I(), e.removeEventListener("touchstart", _), e.removeEventListener("touchmove", f), e.removeEventListener("touchend", T), e.removeEventListener("touchcancel", T);
49
+ };
50
+ }
51
+ return () => {
52
+ e.removeEventListener("wheel", a), E == null || E();
53
+ };
54
+ }
55
+ export {
56
+ O as attachWheelTouchScroll
57
+ };