@progress/kendo-vue-grid 9.1.0-develop.1 → 9.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -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 k=require("../utils/main.js"),F=1,S=20;class x{constructor(p){this.columns=[],this.columnsState=[],this.resizable=!1,this.isRtl=!1,this.setIsRtl=n=>{this.isRtl=n},this.initWidths=()=>{var a;const n=((a=this.colGroupMain)==null?void 0:a.children)||[],c=k.getFlatColumnsState(this.columnsState),r=this.columns.filter(o=>{var d;return!((d=o.children)!=null&&d.length)});for(let o=0;o<n.length;o++){const d=n[o],t=r[o];let e="";const h=c.find(i=>i.id===r[o].id);h&&(e=this.applyWidthConstraints(h,t)),d.width=e,this.colGroupHeader&&(this.colGroupHeader.children[o].width=e),this.colGroupFooter&&(this.colGroupFooter.children[o].width=e),this.colGroupStickyHeader&&(this.colGroupStickyHeader.children[o].width=e),this.colGroupStickyFooter&&(this.colGroupStickyFooter.children[o].width=e),this.colGroupPinnedTop&&(this.colGroupPinnedTop.children[o].width=e),this.colGroupPinnedBottom&&(this.colGroupPinnedBottom.children[o].width=e)}},this.dragHandler=(n,c,r,a)=>{const o=n.originalEvent;a||(o.preventDefault(),o.stopPropagation(),o.stopImmediatePropagation());const d=r.closest("th");if(!d)return;const t=d.clientWidth;let e=t;if(this.isRtl?e+=r.getBoundingClientRect().right-r.offsetWidth/2-n.clientX:e+=n.clientX-r.getBoundingClientRect().left-r.offsetWidth/2,!a&&Math.abs(e-t)<1)return;this.fixateInitialWidths(d.parentElement.clientWidth),this.setWidths(c,Math.floor(e)/t);const h=this.columns.filter(i=>!i.children.length).findIndex(i=>i.id===c.id);this.onResize(h,t,e,o,a,this.columnsState,c.id)},this.dblClickHandler=(n,c)=>{const r=this.columns.filter(l=>c.indexOf(l.id)>-1),a=k.getFlatColumnsState(this.columnsState);if(!this.colGroupMain||!r.length)return;const o={},d=r;for(;d.length>0;){const l=d.pop();if(!l)break;l.children.length?d.push(...l.children):o[l.id]=l}const t=this.columns.filter(l=>!l.children.length),e=[];t.forEach((l,s)=>{o[l.id]&&e.push(s)});const h=[this.colGroupMain.parentElement],i=[this.colGroupMain];this.colGroupHeader&&(h.push(this.colGroupHeader.parentElement),i.push(this.colGroupHeader)),this.colGroupFooter&&(h.push(this.colGroupFooter.parentElement),i.push(this.colGroupFooter)),this.colGroupStickyHeader&&(h.push(this.colGroupStickyHeader.parentElement),i.push(this.colGroupStickyHeader)),this.colGroupStickyFooter&&(h.push(this.colGroupStickyFooter.parentElement),i.push(this.colGroupStickyFooter)),this.colGroupPinnedTop&&(h.push(this.colGroupPinnedTop.parentElement),i.push(this.colGroupPinnedTop)),this.colGroupPinnedBottom&&(h.push(this.colGroupPinnedBottom.parentElement),i.push(this.colGroupPinnedBottom)),h.forEach(l=>l.classList.add("k-autofitting"));const f=[];i.forEach(l=>{e.forEach(s=>{l.children[s]&&(l.children[s].width="",f[s]=Math.max(f[s]||0,l.children[s].offsetWidth+F))})}),i.forEach(l=>{e.forEach(s=>{if(l.children[s]){l.children[s].width=f[s]+"px";const w=a.find(g=>g.id===t[s].id);w&&(w.width=f[s])}})}),h.forEach(l=>l.classList.remove("k-autofitting")),this.onResize(e[0],0,0,n,!0,this.columnsState,c[0])},this.updateColElements=n=>{var a,o,d,t,e,h,i;const c=this.columns.filter(f=>!f.hidden&&!f.children.length);let r=1e-10;for(let f=0;f<n.length;f++){const l=n[f],s=c.findIndex(u=>u.id===l.id),w=parseFloat((l.width||0).toString()),g=Math.floor(w);r+=w-g;const G=g+Math.floor(r);r-=Math.floor(r);const m=c.find(u=>u.id===l.id);if(!m)return;if((a=this.colGroupMain)!=null&&a.children[s]){const u=parseInt(this.colGroupMain.children[s].width,10);this.colGroupMain.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupMain.parentElement,m,u-G)}if((o=this.colGroupHeader)!=null&&o.children[s]){const u=parseInt(this.colGroupHeader.children[s].width,10);this.colGroupHeader.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupHeader.parentElement,m,u-G)}if((d=this.colGroupFooter)!=null&&d.children[s]){const u=parseInt(this.colGroupFooter.children[s].width,10);this.colGroupFooter.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupFooter.parentElement,m,u-G)}if((t=this.colGroupStickyHeader)!=null&&t.children[s]){const u=parseInt(this.colGroupStickyHeader.children[s].width,10);this.colGroupStickyHeader.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupStickyHeader.parentElement,m,u-G)}if((e=this.colGroupStickyFooter)!=null&&e.children[s]){const u=parseInt(this.colGroupStickyFooter.children[s].width,10);this.colGroupStickyFooter.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupStickyFooter.parentElement,m,u-G)}if((h=this.colGroupPinnedTop)!=null&&h.children[s]){const u=parseInt(this.colGroupPinnedTop.children[s].width,10);this.colGroupPinnedTop.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupPinnedTop.parentElement,m,u-G)}if((i=this.colGroupPinnedBottom)!=null&&i.children[s]){const u=parseInt(this.colGroupPinnedBottom.children[s].width,10);this.colGroupPinnedBottom.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupPinnedBottom.parentElement,m,u-G)}}},this.onResize=p}applyWidthConstraints(p,n,c=1){var i;if(!p.width)return p.width||"";const r=p.width.toString();if(r.includes("%")){const l=parseFloat(r)*c,s=Math.max(0,Math.min(100,l));return p.width=s+"%",p.width}let o=parseFloat(r)*c;const d=(i=n.minResizableWidth)!=null?i:10,t=n==null?void 0:n.minWidth,e=t!==void 0?Math.max(d,t):d,h=n==null?void 0:n.maxWidth;return o<e&&(o=e),h!==void 0&&o>h&&(o=h),p.width=o,o}fixateInitialWidths(p){var d;let n=0;const c=((d=this.colGroupMain)==null?void 0:d.children)||[];for(let t=0;t<c.length;t++)c[t].width?p-=c[t].clientWidth:n++;if(n===0)return;const r=Math.floor(p/n),a=k.getFlatColumnsState(this.columnsState),o=this.columns.filter(t=>!t.children.length);for(let t=0;t<c.length;t++){const e=c[t],h=e.width?e.clientWidth:r;e.width=h;const i=a.find(f=>f.id===o[t].id);i&&(i.width=h.toString()),this.colGroupHeader&&(this.colGroupHeader.children[t].width=h),this.colGroupFooter&&(this.colGroupFooter.children[t].width=h),this.colGroupStickyHeader&&(this.colGroupStickyHeader.children[t].width=h),this.colGroupStickyFooter&&(this.colGroupStickyFooter.children[t].width=h)}}setWidths(p,n){const c=k.getFlatColumnsState(this.columnsState),r=this.columns.findIndex(t=>t.id===p.id),a=[];let o=p.children.filter(t=>!t.hidden).length;for(let t=r+1;t<this.columns.length&&!(o<=0);t++){const e=this.columns[t];e.children.length?o+=e.children.filter(h=>!h.hidden).length:a.push(e),o--}a.length===0&&a.push(p);const d=[];a.forEach(t=>{const e=c.find(h=>h.id===t.id);e&&(this.applyWidthConstraints(e,t,n),d.push(e))}),this.updateColElements(d)}updateNextLockedCol(p,n,c){const r=n.index,a=this.colGroupMain.parentElement.closest(".k-grid"),o=a==null?void 0:a.clientWidth,d=this.columns.filter(t=>t.locked).map(t=>parseInt(t.width+"",10)).reduce((t,e)=>t+e,0);!n.locked||o<=d+S||this.columns.forEach(t=>{if(t!=null&&t.locked&&c){const e=p==null?void 0:p.querySelectorAll('[aria-colindex="'+t.ariaColumnIndex+'"]');e==null||e.forEach(h=>{const i=h.style;this.isRtl?(t.index>r&&(i!=null&&i.right)&&(i.right=parseInt(i.right,10)-c+"px"),t.index<r&&(i!=null&&i.left)&&(i.left=parseInt(i.left,10)-c+"px")):(t.index>r&&(i!=null&&i.left)&&(i.left=parseInt(i.left,10)-c+"px"),t.index<r&&(i!=null&&i.right)&&(i.right=parseInt(i.right,10)-c+"px"))})}})}}exports.ColumnResize=x;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const k=require("../utils/main.js"),F=1,S=20;class x{constructor(p){this.columns=[],this.columnsState=[],this.resizable=!1,this.isRtl=!1,this.setIsRtl=r=>{this.isRtl=r},this.initWidths=()=>{var a;const r=((a=this.colGroupMain)==null?void 0:a.children)||[],c=k.getFlatColumnsState(this.columnsState),h=this.columns.filter(o=>{var d;return!((d=o.children)!=null&&d.length)});for(let o=0;o<r.length;o++){const d=r[o],t=h[o];let e="";const n=c.find(i=>i.id===h[o].id);n&&(e=this.applyWidthConstraints(n,t)),d.width=e,this.colGroupHeader&&(this.colGroupHeader.children[o].width=e),this.colGroupFooter&&(this.colGroupFooter.children[o].width=e),this.colGroupStickyHeader&&(this.colGroupStickyHeader.children[o].width=e),this.colGroupStickyFooter&&(this.colGroupStickyFooter.children[o].width=e),this.colGroupPinnedTop&&(this.colGroupPinnedTop.children[o].width=e),this.colGroupPinnedBottom&&(this.colGroupPinnedBottom.children[o].width=e)}},this.dragHandler=(r,c,h,a)=>{const o=r.originalEvent;a||(o.preventDefault(),o.stopPropagation(),o.stopImmediatePropagation());const d=h.closest("th");if(!d)return;const t=d.clientWidth;let e=t;if(this.isRtl?e+=h.getBoundingClientRect().right-h.offsetWidth/2-r.clientX:e+=r.clientX-h.getBoundingClientRect().left-h.offsetWidth/2,!a&&Math.abs(e-t)<1)return;this.fixateInitialWidths(d.parentElement.clientWidth),this.setWidths(c,Math.floor(e)/t);const n=this.columns.filter(i=>!i.children.length).findIndex(i=>i.id===c.id);this.onResize(n,t,e,o,a,this.columnsState,c.id)},this.dblClickHandler=(r,c)=>{const h=this.columns.filter(l=>c.indexOf(l.id)>-1),a=k.getFlatColumnsState(this.columnsState);if(!this.colGroupMain||!h.length)return;const o={},d=h;for(;d.length>0;){const l=d.pop();if(!l)break;l.children.length?d.push(...l.children):o[l.id]=l}const t=this.columns.filter(l=>!l.children.length),e=[];t.forEach((l,s)=>{o[l.id]&&e.push(s)});const n=[this.colGroupMain.parentElement],i=[this.colGroupMain];this.colGroupHeader&&(n.push(this.colGroupHeader.parentElement),i.push(this.colGroupHeader)),this.colGroupFooter&&(n.push(this.colGroupFooter.parentElement),i.push(this.colGroupFooter)),this.colGroupStickyHeader&&(n.push(this.colGroupStickyHeader.parentElement),i.push(this.colGroupStickyHeader)),this.colGroupStickyFooter&&(n.push(this.colGroupStickyFooter.parentElement),i.push(this.colGroupStickyFooter)),this.colGroupPinnedTop&&(n.push(this.colGroupPinnedTop.parentElement),i.push(this.colGroupPinnedTop)),this.colGroupPinnedBottom&&(n.push(this.colGroupPinnedBottom.parentElement),i.push(this.colGroupPinnedBottom)),n.forEach(l=>l.classList.add("k-autofitting"));const f=[];i.forEach(l=>{e.forEach(s=>{l.children[s]&&(l.children[s].width="",f[s]=Math.max(f[s]||0,l.children[s].offsetWidth+F))})}),i.forEach(l=>{e.forEach(s=>{if(l.children[s]){l.children[s].width=f[s]+"px";const w=a.find(g=>g.id===t[s].id);w&&(w.width=f[s])}})}),n.forEach(l=>l.classList.remove("k-autofitting")),this.onResize(e[0],0,0,r,!0,this.columnsState,c[0])},this.updateColElements=r=>{var a,o,d,t,e,n,i;const c=this.columns.filter(f=>!f.hidden&&!f.children.length);let h=1e-10;for(let f=0;f<r.length;f++){const l=r[f],s=c.findIndex(u=>u.id===l.id),w=parseFloat((l.width||0).toString()),g=Math.floor(w);h+=w-g;const G=g+Math.floor(h);h-=Math.floor(h);const m=c.find(u=>u.id===l.id);if(!m)return;if((a=this.colGroupMain)!=null&&a.children[s]){const u=parseInt(this.colGroupMain.children[s].width,10);this.colGroupMain.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupMain.parentElement,m,u-G)}if((o=this.colGroupHeader)!=null&&o.children[s]){const u=parseInt(this.colGroupHeader.children[s].width,10);this.colGroupHeader.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupHeader.parentElement,m,u-G)}if((d=this.colGroupFooter)!=null&&d.children[s]){const u=parseInt(this.colGroupFooter.children[s].width,10);this.colGroupFooter.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupFooter.parentElement,m,u-G)}if((t=this.colGroupStickyHeader)!=null&&t.children[s]){const u=parseInt(this.colGroupStickyHeader.children[s].width,10);this.colGroupStickyHeader.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupStickyHeader.parentElement,m,u-G)}if((e=this.colGroupStickyFooter)!=null&&e.children[s]){const u=parseInt(this.colGroupStickyFooter.children[s].width,10);this.colGroupStickyFooter.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupStickyFooter.parentElement,m,u-G)}if((n=this.colGroupPinnedTop)!=null&&n.children[s]){const u=parseInt(this.colGroupPinnedTop.children[s].width,10);this.colGroupPinnedTop.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupPinnedTop.parentElement,m,u-G)}if((i=this.colGroupPinnedBottom)!=null&&i.children[s]){const u=parseInt(this.colGroupPinnedBottom.children[s].width,10);this.colGroupPinnedBottom.children[s].width=G+"px",this.updateNextLockedCol(this.colGroupPinnedBottom.parentElement,m,u-G)}}},this.onResize=p}applyWidthConstraints(p,r,c=1){var i;if(!p.width)return p.width||"";const h=p.width.toString();if(h.includes("%")){const l=parseFloat(h)*c,s=Math.max(0,Math.min(100,l));return p.width=s+"%",p.width}let o=parseFloat(h)*c;const d=(i=r.minResizableWidth)!=null?i:10,t=r.minWidth,e=t!==void 0?Math.max(d,t):d,n=r==null?void 0:r.maxWidth;return o<e&&(o=e),n!==void 0&&o>n&&(o=n),p.width=o,o}fixateInitialWidths(p){var d;let r=0;const c=((d=this.colGroupMain)==null?void 0:d.children)||[];for(let t=0;t<c.length;t++)c[t].width?p-=c[t].clientWidth:r++;if(r===0)return;const h=Math.floor(p/r),a=k.getFlatColumnsState(this.columnsState),o=this.columns.filter(t=>!t.children.length);for(let t=0;t<c.length;t++){const e=c[t],n=e.width?e.clientWidth:h;e.width=n;const i=a.find(f=>f.id===o[t].id);i&&(i.width=n.toString()),this.colGroupHeader&&(this.colGroupHeader.children[t].width=n),this.colGroupFooter&&(this.colGroupFooter.children[t].width=n),this.colGroupStickyHeader&&(this.colGroupStickyHeader.children[t].width=n),this.colGroupStickyFooter&&(this.colGroupStickyFooter.children[t].width=n)}}setWidths(p,r){const c=k.getFlatColumnsState(this.columnsState),h=this.columns.findIndex(t=>t.id===p.id),a=[];let o=p.children.filter(t=>!t.hidden).length;for(let t=h+1;t<this.columns.length&&!(o<=0);t++){const e=this.columns[t];e.children.length?o+=e.children.filter(n=>!n.hidden).length:a.push(e),o--}a.length===0&&a.push(p);const d=[];a.forEach(t=>{const e=c.find(n=>n.id===t.id);e&&(this.applyWidthConstraints(e,t,r),d.push(e))}),this.updateColElements(d)}updateNextLockedCol(p,r,c){const h=r.index,a=this.colGroupMain.parentElement.closest(".k-grid"),o=a==null?void 0:a.clientWidth,d=this.columns.filter(t=>t.locked).map(t=>parseInt(t.width+"",10)).reduce((t,e)=>t+e,0);!r.locked||o<=d+S||this.columns.forEach(t=>{if(t!=null&&t.locked&&c){const e=p==null?void 0:p.querySelectorAll('[aria-colindex="'+t.ariaColumnIndex+'"]');e==null||e.forEach(n=>{const i=n.style;this.isRtl?(t.index>h&&(i!=null&&i.right)&&(i.right=parseInt(i.right,10)-c+"px"),t.index<h&&(i!=null&&i.left)&&(i.left=parseInt(i.left,10)-c+"px")):(t.index>h&&(i!=null&&i.left)&&(i.left=parseInt(i.left,10)-c+"px"),t.index<h&&(i!=null&&i.right)&&(i.right=parseInt(i.right,10)-c+"px"))})}})}}exports.ColumnResize=x;
@@ -9,38 +9,38 @@ import { getFlatColumnsState as g } from "../utils/main.mjs";
9
9
  const x = 1, F = 20;
10
10
  class E {
11
11
  constructor(a) {
12
- this.columns = [], this.columnsState = [], this.resizable = !1, this.isRtl = !1, this.setIsRtl = (n) => {
13
- this.isRtl = n;
12
+ this.columns = [], this.columnsState = [], this.resizable = !1, this.isRtl = !1, this.setIsRtl = (r) => {
13
+ this.isRtl = r;
14
14
  }, this.initWidths = () => {
15
15
  var p;
16
- const n = ((p = this.colGroupMain) == null ? void 0 : p.children) || [], c = g(this.columnsState), r = this.columns.filter((e) => {
16
+ const r = ((p = this.colGroupMain) == null ? void 0 : p.children) || [], c = g(this.columnsState), n = this.columns.filter((e) => {
17
17
  var d;
18
18
  return !((d = e.children) != null && d.length);
19
19
  });
20
- for (let e = 0; e < n.length; e++) {
21
- const d = n[e], t = r[e];
20
+ for (let e = 0; e < r.length; e++) {
21
+ const d = r[e], t = n[e];
22
22
  let o = "";
23
- const h = c.find((i) => i.id === r[e].id);
23
+ const h = c.find((i) => i.id === n[e].id);
24
24
  h && (o = this.applyWidthConstraints(h, t)), d.width = o, this.colGroupHeader && (this.colGroupHeader.children[e].width = o), this.colGroupFooter && (this.colGroupFooter.children[e].width = o), this.colGroupStickyHeader && (this.colGroupStickyHeader.children[e].width = o), this.colGroupStickyFooter && (this.colGroupStickyFooter.children[e].width = o), this.colGroupPinnedTop && (this.colGroupPinnedTop.children[e].width = o), this.colGroupPinnedBottom && (this.colGroupPinnedBottom.children[e].width = o);
25
25
  }
26
- }, this.dragHandler = (n, c, r, p) => {
27
- const e = n.originalEvent;
26
+ }, this.dragHandler = (r, c, n, p) => {
27
+ const e = r.originalEvent;
28
28
  p || (e.preventDefault(), e.stopPropagation(), e.stopImmediatePropagation());
29
- const d = r.closest("th");
29
+ const d = n.closest("th");
30
30
  if (!d)
31
31
  return;
32
32
  const t = d.clientWidth;
33
33
  let o = t;
34
- if (this.isRtl ? o += r.getBoundingClientRect().right - r.offsetWidth / 2 - n.clientX : o += n.clientX - r.getBoundingClientRect().left - r.offsetWidth / 2, !p && Math.abs(o - t) < 1)
34
+ if (this.isRtl ? o += n.getBoundingClientRect().right - n.offsetWidth / 2 - r.clientX : o += r.clientX - n.getBoundingClientRect().left - n.offsetWidth / 2, !p && Math.abs(o - t) < 1)
35
35
  return;
36
36
  this.fixateInitialWidths(d.parentElement.clientWidth), this.setWidths(c, Math.floor(o) / t);
37
37
  const h = this.columns.filter((i) => !i.children.length).findIndex((i) => i.id === c.id);
38
38
  this.onResize(h, t, o, e, p, this.columnsState, c.id);
39
- }, this.dblClickHandler = (n, c) => {
40
- const r = this.columns.filter((l) => c.indexOf(l.id) > -1), p = g(this.columnsState);
41
- if (!this.colGroupMain || !r.length)
39
+ }, this.dblClickHandler = (r, c) => {
40
+ const n = this.columns.filter((l) => c.indexOf(l.id) > -1), p = g(this.columnsState);
41
+ if (!this.colGroupMain || !n.length)
42
42
  return;
43
- const e = {}, d = r;
43
+ const e = {}, d = n;
44
44
  for (; d.length > 0; ) {
45
45
  const l = d.pop();
46
46
  if (!l)
@@ -69,16 +69,16 @@ class E {
69
69
  w && (w.width = f[s]);
70
70
  }
71
71
  });
72
- }), h.forEach((l) => l.classList.remove("k-autofitting")), this.onResize(o[0], 0, 0, n, !0, this.columnsState, c[0]);
73
- }, this.updateColElements = (n) => {
72
+ }), h.forEach((l) => l.classList.remove("k-autofitting")), this.onResize(o[0], 0, 0, r, !0, this.columnsState, c[0]);
73
+ }, this.updateColElements = (r) => {
74
74
  var p, e, d, t, o, h, i;
75
75
  const c = this.columns.filter((f) => !f.hidden && !f.children.length);
76
- let r = 1e-10;
77
- for (let f = 0; f < n.length; f++) {
78
- const l = n[f], s = c.findIndex((u) => u.id === l.id), w = parseFloat((l.width || 0).toString()), k = Math.floor(w);
79
- r += w - k;
80
- const G = k + Math.floor(r);
81
- r -= Math.floor(r);
76
+ let n = 1e-10;
77
+ for (let f = 0; f < r.length; f++) {
78
+ const l = r[f], s = c.findIndex((u) => u.id === l.id), w = parseFloat((l.width || 0).toString()), k = Math.floor(w);
79
+ n += w - k;
80
+ const G = k + Math.floor(n);
81
+ n -= Math.floor(n);
82
82
  const m = c.find((u) => u.id === l.id);
83
83
  if (!m)
84
84
  return;
@@ -129,39 +129,39 @@ class E {
129
129
  }
130
130
  }, this.onResize = a;
131
131
  }
132
- applyWidthConstraints(a, n, c = 1) {
132
+ applyWidthConstraints(a, r, c = 1) {
133
133
  var i;
134
134
  if (!a.width)
135
135
  return a.width || "";
136
- const r = a.width.toString();
137
- if (r.includes("%")) {
138
- const l = parseFloat(r) * c, s = Math.max(0, Math.min(100, l));
136
+ const n = a.width.toString();
137
+ if (n.includes("%")) {
138
+ const l = parseFloat(n) * c, s = Math.max(0, Math.min(100, l));
139
139
  return a.width = s + "%", a.width;
140
140
  }
141
- let e = parseFloat(r) * c;
142
- const d = (i = n.minResizableWidth) != null ? i : 10, t = n == null ? void 0 : n.minWidth, o = t !== void 0 ? Math.max(d, t) : d, h = n == null ? void 0 : n.maxWidth;
141
+ let e = parseFloat(n) * c;
142
+ const d = (i = r.minResizableWidth) != null ? i : 10, t = r.minWidth, o = t !== void 0 ? Math.max(d, t) : d, h = r == null ? void 0 : r.maxWidth;
143
143
  return e < o && (e = o), h !== void 0 && e > h && (e = h), a.width = e, e;
144
144
  }
145
145
  fixateInitialWidths(a) {
146
146
  var d;
147
- let n = 0;
147
+ let r = 0;
148
148
  const c = ((d = this.colGroupMain) == null ? void 0 : d.children) || [];
149
149
  for (let t = 0; t < c.length; t++)
150
- c[t].width ? a -= c[t].clientWidth : n++;
151
- if (n === 0)
150
+ c[t].width ? a -= c[t].clientWidth : r++;
151
+ if (r === 0)
152
152
  return;
153
- const r = Math.floor(a / n), p = g(this.columnsState), e = this.columns.filter((t) => !t.children.length);
153
+ const n = Math.floor(a / r), p = g(this.columnsState), e = this.columns.filter((t) => !t.children.length);
154
154
  for (let t = 0; t < c.length; t++) {
155
- const o = c[t], h = o.width ? o.clientWidth : r;
155
+ const o = c[t], h = o.width ? o.clientWidth : n;
156
156
  o.width = h;
157
157
  const i = p.find((f) => f.id === e[t].id);
158
158
  i && (i.width = h.toString()), this.colGroupHeader && (this.colGroupHeader.children[t].width = h), this.colGroupFooter && (this.colGroupFooter.children[t].width = h), this.colGroupStickyHeader && (this.colGroupStickyHeader.children[t].width = h), this.colGroupStickyFooter && (this.colGroupStickyFooter.children[t].width = h);
159
159
  }
160
160
  }
161
- setWidths(a, n) {
162
- const c = g(this.columnsState), r = this.columns.findIndex((t) => t.id === a.id), p = [];
161
+ setWidths(a, r) {
162
+ const c = g(this.columnsState), n = this.columns.findIndex((t) => t.id === a.id), p = [];
163
163
  let e = a.children.filter((t) => !t.hidden).length;
164
- for (let t = r + 1; t < this.columns.length && !(e <= 0); t++) {
164
+ for (let t = n + 1; t < this.columns.length && !(e <= 0); t++) {
165
165
  const o = this.columns[t];
166
166
  o.children.length ? e += o.children.filter((h) => !h.hidden).length : p.push(o), e--;
167
167
  }
@@ -169,17 +169,17 @@ class E {
169
169
  const d = [];
170
170
  p.forEach((t) => {
171
171
  const o = c.find((h) => h.id === t.id);
172
- o && (this.applyWidthConstraints(o, t, n), d.push(o));
172
+ o && (this.applyWidthConstraints(o, t, r), d.push(o));
173
173
  }), this.updateColElements(d);
174
174
  }
175
- updateNextLockedCol(a, n, c) {
176
- const r = n.index, p = this.colGroupMain.parentElement.closest(".k-grid"), e = p == null ? void 0 : p.clientWidth, d = this.columns.filter((t) => t.locked).map((t) => parseInt(t.width + "", 10)).reduce((t, o) => t + o, 0);
177
- !n.locked || e <= d + F || this.columns.forEach((t) => {
175
+ updateNextLockedCol(a, r, c) {
176
+ const n = r.index, p = this.colGroupMain.parentElement.closest(".k-grid"), e = p == null ? void 0 : p.clientWidth, d = this.columns.filter((t) => t.locked).map((t) => parseInt(t.width + "", 10)).reduce((t, o) => t + o, 0);
177
+ !r.locked || e <= d + F || this.columns.forEach((t) => {
178
178
  if (t != null && t.locked && c) {
179
179
  const o = a == null ? void 0 : a.querySelectorAll('[aria-colindex="' + t.ariaColumnIndex + '"]');
180
180
  o == null || o.forEach((h) => {
181
181
  const i = h.style;
182
- this.isRtl ? (t.index > r && (i != null && i.right) && (i.right = parseInt(i.right, 10) - c + "px"), t.index < r && (i != null && i.left) && (i.left = parseInt(i.left, 10) - c + "px")) : (t.index > r && (i != null && i.left) && (i.left = parseInt(i.left, 10) - c + "px"), t.index < r && (i != null && i.right) && (i.right = parseInt(i.right, 10) - c + "px"));
182
+ this.isRtl ? (t.index > n && (i != null && i.right) && (i.right = parseInt(i.right, 10) - c + "px"), t.index < n && (i != null && i.left) && (i.left = parseInt(i.left, 10) - c + "px")) : (t.index > n && (i != null && i.left) && (i.left = parseInt(i.left, 10) - c + "px"), t.index < n && (i != null && i.right) && (i.right = parseInt(i.right, 10) - c + "px"));
183
183
  });
184
184
  }
185
185
  });
package/getRowContents.js CHANGED
@@ -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 T=require("vue"),re=require("./cells/GridCell.js"),ce=require("./cells/GridEditCell.js"),n=require("@progress/kendo-vue-common"),q=require("./utils/main.js"),ie=require("@progress/kendo-vue-data-tools"),R=({leafColumns:t,editField:l,item:o})=>{if(!l)return!1;for(const a of t)if(a.editable){const r=n.getNestedValue(l,o.dataItem);if(r===!0||r===a.field)return!0}return!1},G=({selectedField:t,dataItemKey:l,select:o,item:a})=>{if(t){const r=n.getNestedValue(t,a.dataItem);return typeof r=="boolean"&&r}if(o&&l&&n.getter(l)(a.dataItem)!==void 0){const r=o[n.getter(l)(a.dataItem)];return typeof r=="boolean"&&r}return!1},$=({highlight:t,dataItemKey:l,item:o})=>{if(t&&l&&n.getter(l)(o.dataItem)!==void 0){const a=t[n.getter(l)(o.dataItem)];return typeof a=="boolean"&&a}return!1},se=(t,l,o,a,r,i)=>{const{leafColumns:g,selectedField:p,dataItemKey:c,select:I,highlight:h,editField:y,cellRender:A,cells:D,itemChange:P,selectionChangeHandler:B,editHandler:O,removeHandler:_,saveHandler:j,cancelHandler:M,cellClickHandler:z,cellKeydownHandler:J,computedCollapsed:C,uniqueField:K,columnsRef:L,isRtl:N,idPrefix:Q}=t,U=I&&c&&n.getter(c)(l.dataItem)!==void 0?I[n.getter(c)(l.dataItem)]:void 0,v=p?n.getNestedValue(p,l.dataItem):U,S=h&&c&&n.getter(c)(l.dataItem)!==void 0?h[n.getter(c)(l.dataItem)]:void 0,W=R({leafColumns:g,editField:y,item:l}),X=G({selectedField:p,dataItemKey:c,select:I,item:l}),Y=$({highlight:h,dataItemKey:c,item:l});return{row:(t.hasDynamicColSpan?t.getCellsToRender(l.dataItem,g):t.cellsToRender).map(({columnIndex:u,colSpan:Z})=>{var H,x,E,w,F;const e=g[u];let f;if((H=e.rowSpannable)!=null&&H.enabled&&l.rowType==="data"&&e.field&&i){const d=e.field?(E=(x=e.rowSpannable).valueGetter)==null?void 0:E.call(x,l.dataItem,e.field):null;f={value:d,count:1},i[e.field]&&((w=i[e.field])==null?void 0:w.value)===d&&i[e.field]!==null?(i[e.field].count++,f.count=null):i[e.field]=f}const ee=`${e.className?e.className+" ":""}${e.locked?"k-grid-content-sticky":""}`,le=N?{left:e.right+"px",right:e.left+"px"}:{left:e.left+"px",right:e.right+"px"},te=e.locked&&(e.left!==void 0||e.right!==void 0)?le:void 0;let k=!1;if(e.editable&&y){const d=n.getNestedValue(y,l.dataItem);(d===!0||d===e.field)&&(k=!0)}const s=q.resolveCells(D,e.cells);let b;l.rowType==="groupFooter"?b=(s==null?void 0:s.groupFooter)||e.cell:(e.cell||s!=null&&s.data)&&(b=e.cell);const m=(F=C==null?void 0:C[l.level])==null?void 0:F.some(d=>d===q.groupedFirstItemValue(l.dataItem,K)),ne=e.id?e.id:u,ae=m?!m:l.expanded||l.dataItem.expanded,de=e._type==="expand",oe=ie.tableKeyboardNavigationTools.generateNavigatableId(`${o}-${String(u)}`,Q,de||l.rowType==="groupHeader"||l.rowType==="groupFooter"||e.field==="value"?"nodata":"cell"),V={locked:e.locked,key:ne,id:oe,colSpan:Z,dataItem:l.dataItem,field:e.field||"",editor:e.editor,format:e.format,readFormat:e.readFormat,type:e.type,columnType:e.columnType,className:ee,render:b||A,onChange:P,onSelectionchange:d=>B({event:d,dataItem:l.dataItem,dataIndex:a,columnIndex:u}),onCellclick:z,onCellkeydown:J,onEdit:O,onRemove:_,onSave:j,onCancel:M,cells:s,columnIndex:u,columnsCount:L.filter(d=>!d.children.length).length,rowType:l.rowType,level:l.level,expanded:ae,dataIndex:l.dataIndex,style:te,ariaColumnIndex:e.ariaColumnIndex,isRtl:N,isSelected:!!((e==null?void 0:e._type)==="edit"?v:Array.isArray(v)&&v.indexOf(u)>-1),isHighlighted:!!(typeof S!="boolean"&&S&&e.field&&S[e.field]===!0),group:l.group,rowSpan:f};return e.defaultCell?T.createVNode(e.defaultCell,V,null):k?T.createVNode(ce.GridEditCell,V,null):T.createVNode(re.GridCell,V,null)}),isInEdit:W,isSelected:X,isHighlighted:Y}};exports.calculateIsHighlighted=$;exports.calculateIsInEdit=R;exports.calculateIsSelected=G;exports.getRowContents=se;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const T=require("vue"),re=require("./cells/GridCell.js"),ie=require("./cells/GridEditCell.js"),a=require("@progress/kendo-vue-common"),q=require("./utils/main.js"),ce=require("@progress/kendo-vue-data-tools"),R=({leafColumns:t,editField:l,item:o})=>{if(!l)return!1;for(const n of t)if(n.editable){const r=a.getNestedValue(l,o.dataItem);if(r===!0||r===n.field)return!0}return!1},G=({selectedField:t,dataItemKey:l,select:o,item:n})=>{if(t){const r=a.getNestedValue(t,n.dataItem);return typeof r=="boolean"&&r}if(o&&l&&a.getter(l)(n.dataItem)!==void 0){const r=o[a.getter(l)(n.dataItem)];return typeof r=="boolean"&&r}return!1},$=({highlight:t,dataItemKey:l,item:o})=>{if(t&&l&&a.getter(l)(o.dataItem)!==void 0){const n=t[a.getter(l)(o.dataItem)];return typeof n=="boolean"&&n}return!1},se=(t,l,o,n,r,c)=>{const{leafColumns:g,selectedField:p,dataItemKey:i,select:I,highlight:h,editField:y,cellRender:A,cells:D,itemChange:P,selectionChangeHandler:B,editHandler:O,removeHandler:_,saveHandler:j,cancelHandler:M,cellClickHandler:z,cellKeydownHandler:J,computedCollapsed:C,uniqueField:K,columnsRef:L,isRtl:N,idPrefix:Q}=t,U=I&&i&&a.getter(i)(l.dataItem)!==void 0?I[a.getter(i)(l.dataItem)]:void 0,v=p?a.getNestedValue(p,l.dataItem):U,S=h&&i&&a.getter(i)(l.dataItem)!==void 0?h[a.getter(i)(l.dataItem)]:void 0,W=R({leafColumns:g,editField:y,item:l}),X=G({selectedField:p,dataItemKey:i,select:I,item:l}),Y=$({highlight:h,dataItemKey:i,item:l});return{row:(t.hasDynamicColSpan?t.getCellsToRender(l.dataItem,g):t.cellsToRender).map(({columnIndex:u,colSpan:Z})=>{var x,E,m,w,F;const e=g[u];let f;if((x=e.rowSpannable)!=null&&x.enabled&&l.rowType==="data"&&e.field&&c){const d=e.field?(m=(E=e.rowSpannable).valueGetter)==null?void 0:m.call(E,l.dataItem,e.field):null;f={value:d,count:1},c[e.field]&&((w=c[e.field])==null?void 0:w.value)===d&&c[e.field]!==null?(c[e.field].count++,f.count=null):c[e.field]=f}const ee=`${e.className?e.className+" ":""}${e.locked?"k-grid-content-sticky":""}`,le=N?{left:e.right+"px",right:e.left+"px"}:{left:e.left+"px",right:e.right+"px"},te=e.locked&&(e.left!==void 0||e.right!==void 0)?le:void 0;let k=!1;if(e.editable&&y){const d=a.getNestedValue(y,l.dataItem);(d===!0||d===e.field)&&(k=!0)}const s=q.resolveCells(D,e.cells);let b;l.rowType==="groupFooter"?b=(s==null?void 0:s.groupFooter)||e.cell:(e.cell||s!=null&&s.data)&&(b=e.cell);const H=(F=C==null?void 0:C[l.level])==null?void 0:F.some(d=>d===q.groupedFirstItemValue(l.dataItem,K)),ae=e.id?e.id:u,ne=H?!H:l.expanded||l.dataItem.expanded,de=e._type==="expand",oe=ce.tableKeyboardNavigationTools.generateNavigatableId(`${o}-${String(u)}`,Q,de||l.rowType==="groupHeader"||l.rowType==="groupFooter"||e.field==="value"?"nodata":"cell"),V={locked:e.locked,key:ae,id:oe,colSpan:Z,dataItem:l.dataItem,field:e.field||"",editor:e.editor,format:e.format,readFormat:e.readFormat,type:e.type,columnType:e.columnType,className:ee,render:b||A,onChange:P,onSelectionchange:d=>B({event:d,dataItem:l.dataItem,dataIndex:n,columnIndex:u}),onCellclick:z,onCellkeydown:J,onEdit:O,onRemove:_,onSave:j,onCancel:M,cells:s,columnIndex:u,columnsCount:L.filter(d=>!d.children.length).length,rowType:l.rowType,level:l.level,expanded:ne,dataIndex:l.dataIndex,style:te,ariaColumnIndex:e.ariaColumnIndex,isRtl:N,isSelected:!!((e==null?void 0:e._type)==="edit"?v:Array.isArray(v)&&v.indexOf(u)>-1),isHighlighted:!!(typeof S!="boolean"&&S&&(e!=null&&e.field)&&S[e.field]===!0),group:l.group,rowSpan:f};return e.defaultCell?T.createVNode(e.defaultCell,V,null):k?T.createVNode(ie.GridEditCell,V,null):T.createVNode(re.GridCell,V,null)}),isInEdit:W,isSelected:X,isHighlighted:Y}};exports.calculateIsHighlighted=$;exports.calculateIsInEdit=R;exports.calculateIsSelected=G;exports.getRowContents=se;
@@ -6,7 +6,7 @@
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
8
  import { createVNode as x } from "vue";
9
- import { GridCell as ae } from "./cells/GridCell.mjs";
9
+ import { GridCell as ne } from "./cells/GridCell.mjs";
10
10
  import { GridEditCell as oe } from "./cells/GridEditCell.mjs";
11
11
  import { getter as i, getNestedValue as p } from "@progress/kendo-vue-common";
12
12
  import { resolveCells as de, groupedFirstItemValue as re } from "./utils/main.mjs";
@@ -18,10 +18,10 @@ const ce = ({
18
18
  }) => {
19
19
  if (!l)
20
20
  return !1;
21
- for (const n of t)
22
- if (n.editable) {
21
+ for (const a of t)
22
+ if (a.editable) {
23
23
  const d = p(l, o.dataItem);
24
- if (d === !0 || d === n.field)
24
+ if (d === !0 || d === a.field)
25
25
  return !0;
26
26
  }
27
27
  return !1;
@@ -29,14 +29,14 @@ const ce = ({
29
29
  selectedField: t,
30
30
  dataItemKey: l,
31
31
  select: o,
32
- item: n
32
+ item: a
33
33
  }) => {
34
34
  if (t) {
35
- const d = p(t, n.dataItem);
35
+ const d = p(t, a.dataItem);
36
36
  return typeof d == "boolean" && d;
37
37
  }
38
- if (o && l && i(l)(n.dataItem) !== void 0) {
39
- const d = o[i(l)(n.dataItem)];
38
+ if (o && l && i(l)(a.dataItem) !== void 0) {
39
+ const d = o[i(l)(a.dataItem)];
40
40
  return typeof d == "boolean" && d;
41
41
  }
42
42
  return !1;
@@ -46,11 +46,11 @@ const ce = ({
46
46
  item: o
47
47
  }) => {
48
48
  if (t && l && i(l)(o.dataItem) !== void 0) {
49
- const n = t[i(l)(o.dataItem)];
50
- return typeof n == "boolean" && n;
49
+ const a = t[i(l)(o.dataItem)];
50
+ return typeof a == "boolean" && a;
51
51
  }
52
52
  return !1;
53
- }, ve = (t, l, o, n, d, c) => {
53
+ }, ve = (t, l, o, a, d, c) => {
54
54
  const {
55
55
  leafColumns: g,
56
56
  selectedField: I,
@@ -96,11 +96,11 @@ const ce = ({
96
96
  const e = g[f];
97
97
  let u;
98
98
  if ((E = e.rowSpannable) != null && E.enabled && l.rowType === "data" && e.field && c) {
99
- const a = e.field ? (F = (V = e.rowSpannable).valueGetter) == null ? void 0 : F.call(V, l.dataItem, e.field) : null;
99
+ const n = e.field ? (F = (V = e.rowSpannable).valueGetter) == null ? void 0 : F.call(V, l.dataItem, e.field) : null;
100
100
  u = {
101
- value: a,
101
+ value: n,
102
102
  count: 1
103
- }, c[e.field] && ((N = c[e.field]) == null ? void 0 : N.value) === a && c[e.field] !== null ? (c[e.field].count++, u.count = null) : c[e.field] = u;
103
+ }, c[e.field] && ((N = c[e.field]) == null ? void 0 : N.value) === n && c[e.field] !== null ? (c[e.field].count++, u.count = null) : c[e.field] = u;
104
104
  }
105
105
  const X = `${e.className ? e.className + " " : ""}${e.locked ? "k-grid-content-sticky" : ""}`, Y = H ? {
106
106
  left: e.right + "px",
@@ -111,16 +111,16 @@ const ce = ({
111
111
  }, Z = e.locked && (e.left !== void 0 || e.right !== void 0) ? Y : void 0;
112
112
  let k = !1;
113
113
  if (e.editable && m) {
114
- const a = p(m, l.dataItem);
115
- (a === !0 || a === e.field) && (k = !0);
114
+ const n = p(m, l.dataItem);
115
+ (n === !0 || n === e.field) && (k = !0);
116
116
  }
117
117
  const s = de(A, e.cells);
118
118
  let b;
119
119
  l.rowType === "groupFooter" ? b = (s == null ? void 0 : s.groupFooter) || e.cell : (e.cell || s != null && s.data) && (b = e.cell);
120
- const w = (R = C == null ? void 0 : C[l.level]) == null ? void 0 : R.some((a) => a === re(l.dataItem, z)), ee = e.id ? e.id : f, le = w ? !w : l.expanded || l.dataItem.expanded, te = e._type === "expand", ne = ie.generateNavigatableId(`${o}-${String(f)}`, K, te || l.rowType === "groupHeader" || l.rowType === "groupFooter" || e.field === "value" ? "nodata" : "cell"), T = {
120
+ const w = (R = C == null ? void 0 : C[l.level]) == null ? void 0 : R.some((n) => n === re(l.dataItem, z)), ee = e.id ? e.id : f, le = w ? !w : l.expanded || l.dataItem.expanded, te = e._type === "expand", ae = ie.generateNavigatableId(`${o}-${String(f)}`, K, te || l.rowType === "groupHeader" || l.rowType === "groupFooter" || e.field === "value" ? "nodata" : "cell"), T = {
121
121
  locked: e.locked,
122
122
  key: ee,
123
- id: ne,
123
+ id: ae,
124
124
  colSpan: W,
125
125
  dataItem: l.dataItem,
126
126
  field: e.field || "",
@@ -132,10 +132,10 @@ const ce = ({
132
132
  className: X,
133
133
  render: b || $,
134
134
  onChange: G,
135
- onSelectionchange: (a) => B({
136
- event: a,
135
+ onSelectionchange: (n) => B({
136
+ event: n,
137
137
  dataItem: l.dataItem,
138
- dataIndex: n,
138
+ dataIndex: a,
139
139
  columnIndex: f
140
140
  }),
141
141
  onCellclick: O,
@@ -146,7 +146,7 @@ const ce = ({
146
146
  onCancel: q,
147
147
  cells: s,
148
148
  columnIndex: f,
149
- columnsCount: J.filter((a) => !a.children.length).length,
149
+ columnsCount: J.filter((n) => !n.children.length).length,
150
150
  rowType: l.rowType,
151
151
  level: l.level,
152
152
  expanded: le,
@@ -155,11 +155,11 @@ const ce = ({
155
155
  ariaColumnIndex: e.ariaColumnIndex,
156
156
  isRtl: H,
157
157
  isSelected: !!((e == null ? void 0 : e._type) === "edit" ? v : Array.isArray(v) && v.indexOf(f) > -1),
158
- isHighlighted: !!(typeof S != "boolean" && S && e.field && S[e.field] === !0),
158
+ isHighlighted: !!(typeof S != "boolean" && S && (e != null && e.field) && S[e.field] === !0),
159
159
  group: l.group,
160
160
  rowSpan: u
161
161
  };
162
- return e.defaultCell ? x(e.defaultCell, T, null) : k ? x(oe, T, null) : x(ae, T, null);
162
+ return e.defaultCell ? x(e.defaultCell, T, null) : k ? x(oe, T, null) : x(ne, T, null);
163
163
  }),
164
164
  isInEdit: M,
165
165
  isSelected: Q,
@@ -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={name:"@progress/kendo-vue-grid",productName:"Kendo UI for Vue",productCode:"KENDOUIVUE",productCodes:["KENDOUIVUE"],publishDate: 1782316766,version:"9.1.0-develop.1",licensingDocsUrl:"https://www.telerik.com/kendo-vue-ui/my-license/"};exports.packageMetadata=e;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={name:"@progress/kendo-vue-grid",productName:"Kendo UI for Vue",productCode:"KENDOUIVUE",productCodes:["KENDOUIVUE"],publishDate: 1784546652,version:"9.1.0",licensingDocsUrl:"https://www.telerik.com/kendo-vue-ui/my-license/"};exports.packageMetadata=e;
@@ -10,8 +10,8 @@ const e = {
10
10
  productName: "Kendo UI for Vue",
11
11
  productCode: "KENDOUIVUE",
12
12
  productCodes: ["KENDOUIVUE"],
13
- publishDate: 1782316766,
14
- version: "9.1.0-develop.1",
13
+ publishDate: 1784546652,
14
+ version: "9.1.0",
15
15
  licensingDocsUrl: "https://www.telerik.com/kendo-vue-ui/my-license/"
16
16
  };
17
17
  export {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@progress/kendo-vue-grid",
3
- "version": "9.1.0-develop.1",
3
+ "version": "9.1.0",
4
4
  "description": "TODO",
5
5
  "author": "Progress",
6
6
  "license": "SEE LICENSE IN LICENSE.md",
@@ -29,17 +29,17 @@
29
29
  "@progress/kendo-drawing": "^1.21.1",
30
30
  "@progress/kendo-file-saver": "^1.1.2",
31
31
  "@progress/kendo-licensing": "^1.7.2",
32
- "@progress/kendo-vue-animation": "9.1.0-develop.1",
33
- "@progress/kendo-vue-buttons": "9.1.0-develop.1",
34
- "@progress/kendo-vue-common": "9.1.0-develop.1",
35
- "@progress/kendo-vue-data-tools": "9.1.0-develop.1",
36
- "@progress/kendo-vue-dateinputs": "9.1.0-develop.1",
37
- "@progress/kendo-vue-indicators": "9.1.0-develop.1",
38
- "@progress/kendo-vue-dropdowns": "9.1.0-develop.1",
39
- "@progress/kendo-vue-inputs": "9.1.0-develop.1",
40
- "@progress/kendo-vue-intl": "9.1.0-develop.1",
41
- "@progress/kendo-vue-popup": "9.1.0-develop.1",
42
- "@progress/kendo-vue-layout": "9.1.0-develop.1",
32
+ "@progress/kendo-vue-animation": "9.1.0",
33
+ "@progress/kendo-vue-buttons": "9.1.0",
34
+ "@progress/kendo-vue-common": "9.1.0",
35
+ "@progress/kendo-vue-data-tools": "9.1.0",
36
+ "@progress/kendo-vue-dateinputs": "9.1.0",
37
+ "@progress/kendo-vue-indicators": "9.1.0",
38
+ "@progress/kendo-vue-dropdowns": "9.1.0",
39
+ "@progress/kendo-vue-inputs": "9.1.0",
40
+ "@progress/kendo-vue-intl": "9.1.0",
41
+ "@progress/kendo-vue-popup": "9.1.0",
42
+ "@progress/kendo-vue-layout": "9.1.0",
43
43
  "@progress/kendo-svg-icons": "^4.9.0 || ^5.0.0",
44
44
  "vue": "^3.0.2"
45
45
  },
@@ -60,7 +60,7 @@
60
60
  "package": {
61
61
  "productName": "Kendo UI for Vue",
62
62
  "productCode": "KENDOUIVUE",
63
- "publishDate": 1782316766,
63
+ "publishDate": 1784546652,
64
64
  "licensingDocsUrl": "https://www.telerik.com/kendo-vue-ui/my-license/"
65
65
  }
66
66
  },
@@ -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"});function B(d,n,e){let s=0,p=!1;if(e>0&&n)for(let t=0;t<e;t++){const c=n[t]||[];for(let u=0;u<c.length;u++){const h=c[u],S=d[h];(S.rowSpan||1)>e-t&&(s+=S.headerColSpan||1,u===0&&(p=!0))}}return{emptyColSpan:s,skipOffset:p}}function w(d,n){const e=d[n];return!e||e.parentIndex<0?[]:[e.parentIndex,...w(d,e.parentIndex)]}function L(d,n,e){n.forEach(s=>{w(d,s).forEach(t=>e.add(t))})}function b(d,n,e){var p;const s=d[n];((p=s==null?void 0:s.children)==null?void 0:p.length)>0&&s.children.forEach(t=>{let c=typeof t=="number"?t:d.indexOf(t);c>=0&&!e.has(c)&&(e.add(c),b(d,c,e))})}function j(d){const{cellsToRender:n,columns:e,rowIndex:s,enableVirtualization:p,columnsMap:t}=d;if(!p||!n||n.length===0)return{columnsToRender:[],colSpans:[]};const c=[],u=[];let h=-1,S=-1;function I(o,r){let a=-1,i=-1;for(let f=0;f<r.length;f++)o[r[f]].locked||(a===-1&&(a=f),i=f);return{first:a,last:i}}const E=n.reduce((o,r)=>o+r.colSpan,0);let R=0;for(const o of n){const r=e[o.columnIndex];if(r!=null&&r.locked)R+=o.colSpan;else break}const l=E-R;let V=[],x=[];const P=e.filter(o=>o.children.length===0),A=new Map;e.forEach((o,r)=>{if(o.children.length===0){const a=P.findIndex(i=>i===o);a>=0&&A.set(a,r)}});const k=new Set;if(n.forEach(o=>{const r=A.get(o.columnIndex);if(r!==void 0){k.add(r);const a=w(e,r);a.forEach(i=>k.add(i)),L(e,a,k),b(e,r,k),a.forEach(i=>{b(e,i,k)})}}),t&&Array.isArray(t)){for(let o=0;o<t.length;o++)V[o]=t[o].filter(r=>k.has(r));x=V[s]||[]}const M=I(e,x);h=M.first,S=M.last;let U=0;for(let o=0;o<h;o++){const r=e[x[o]];r!=null&&r.locked&&(U+=r.headerColSpan||1)}let v=0,y=0,F=!1;return x.forEach((o,r)=>{c.push(o);const a=e[o],i=(a==null?void 0:a.headerColSpan)||1;let f;if(h===S)f=l;else if(r===h){const T=a.virtualColumnOffset?a.virtualColumnOffset:0,{emptyColSpan:C,skipOffset:g}=B(e,V,s);y+=C;const m=Math.max(0,T-U);g&&(y+=m,F=!0),m>0&&!g?f=i+m:f=i}else if(r===S){let T=r===x.length-1;if(t!=null&&t[s]){const C=t[s],g=o;let m=-1;for(let O=C.length-1;O>=0;O--)if(!e[C[O]].locked){m=C[O];break}T=g===m}if(T)f=i;else{const C=l-v-y;if(f=Math.max(C,i),i>C&&u.length>0){const g=i-C;u[0]-=g}}}else f=i;u.push(f),v+=f}),{columnsToRender:c,colSpans:u,skipOffset:F}}function D(d){const{cellModels:n,columns:e=[],tableViewPortWidth:s,scrollLeft:p}=d;let t=0,c=n.length-1,u=0,h=0;for(let l=0;l<n.length;l++)if(!e[n[l].columnIndex].locked&&(u=h,h+=n[l].width||10,h>=p)){t=l;break}for(let l=t;l<n.length;l++)if(!e[n[l].columnIndex].locked)if(u<s+p)u+=n[l].width||10,c=l;else break;t>0&&t--,c<n.length-1&&c++;let S=0,I=0;for(let l=0;l<t;l++)e[n[l].columnIndex].locked||(S+=n[l].colSpan);for(let l=c+1;l<n.length;l++)e[n[l].columnIndex].locked||(I+=n[l].colSpan);n[t].colSpan+=S,n[c].colSpan+=I;const E=n.slice(0,t).filter(l=>e[l.columnIndex].locked),R=n.slice(c+1).filter(l=>e[l.columnIndex].locked);return[...E,...n.slice(t,c+1),...R]}exports.addAllAncestors=L;exports.addDescendants=b;exports.getParentIndices=w;exports.getVirtualCellsToRender=D;exports.getVirtualHeaderCellsToRender=j;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function B(d,n,e){let a=0,u=!1;if(e>0&&n)for(let t=0;t<e;t++){const c=n[t]||[];for(let p=0;p<c.length;p++){const h=c[p],S=d[h];(S.rowSpan||1)>e-t&&(a+=S.headerColSpan||1,p===0&&(u=!0))}}return{emptyColSpan:a,skipOffset:u}}function E(d,n){const e=d[n];return!e||e.parentIndex<0?[]:[e.parentIndex,...E(d,e.parentIndex)]}function L(d,n,e){n.forEach(a=>{E(d,a).forEach(t=>e.add(t))})}function w(d,n,e){var u;const a=d[n];((u=a==null?void 0:a.children)==null?void 0:u.length)>0&&a.children.forEach(t=>{let c=typeof t=="number"?t:d.indexOf(t);c>=0&&!e.has(c)&&(e.add(c),w(d,c,e))})}function j(d){const{cellsToRender:n,columns:e,rowIndex:a,enableVirtualization:u,columnsMap:t}=d;if(!u||!n||n.length===0)return{columnsToRender:[],colSpans:[]};const c=[],p=[];let h=-1,S=-1;function m(o,r){let s=-1,i=-1;for(let f=0;f<r.length;f++)o[r[f]].locked||(s===-1&&(s=f),i=f);return{first:s,last:i}}const O=n.reduce((o,r)=>o+r.colSpan,0);let R=0;for(const o of n){const r=e[o.columnIndex];if(r!=null&&r.locked)R+=o.colSpan;else break}const l=O-R;let V=[],x=[];const P=e.filter(o=>o.children.length===0),A=new Map;e.forEach((o,r)=>{if(o.children.length===0){const s=P.findIndex(i=>i===o);s>=0&&A.set(s,r)}});const C=new Set;if(n.forEach(o=>{const r=A.get(o.columnIndex);if(r!==void 0){C.add(r);const s=E(e,r);s.forEach(i=>C.add(i)),L(e,s,C),w(e,r,C),s.forEach(i=>{w(e,i,C)})}}),t&&Array.isArray(t)){for(let o=0;o<t.length;o++)V[o]=t[o].filter(r=>C.has(r));x=V[a]||[]}const M=m(e,x);h=M.first,S=M.last;let U=0;for(let o=0;o<h;o++){const r=e[x[o]];r!=null&&r.locked&&(U+=r.headerColSpan||1)}let v=0,y=0,F=!1;return x.forEach((o,r)=>{c.push(o);const s=e[o],i=(s==null?void 0:s.headerColSpan)||1;let f;if(h===S)f=l;else if(r===h){const T=(s==null?void 0:s.virtualColumnOffset)||0,{emptyColSpan:k,skipOffset:g}=B(e,V,a);y+=k;const I=Math.max(0,T-U);g&&(y+=I,F=!0),I>0&&!g?f=i+I:f=i}else if(r===S){let T=r===x.length-1;if(t!=null&&t[a]){const k=t[a],g=o;let I=-1;for(let b=k.length-1;b>=0;b--)if(!e[k[b]].locked){I=k[b];break}T=g===I}if(T)f=i;else{const k=l-v-y;if(f=Math.max(k,i),i>k&&p.length>0){const g=i-k;p[0]-=g}}}else f=i;p.push(f),v+=f}),{columnsToRender:c,colSpans:p,skipOffset:F}}function D(d){const{cellModels:n,columns:e=[],tableViewPortWidth:a,scrollLeft:u}=d;let t=0,c=n.length-1,p=0,h=0;for(let l=0;l<n.length;l++)if(!e[n[l].columnIndex].locked&&(p=h,h+=n[l].width||10,h>=u)){t=l;break}for(let l=t;l<n.length;l++)if(!e[n[l].columnIndex].locked)if(p<a+u)p+=n[l].width||10,c=l;else break;t>0&&t--,c<n.length-1&&c++;let S=0,m=0;for(let l=0;l<t;l++)e[n[l].columnIndex].locked||(S+=n[l].colSpan);for(let l=c+1;l<n.length;l++)e[n[l].columnIndex].locked||(m+=n[l].colSpan);n[t].colSpan+=S,n[c].colSpan+=m;const O=n.slice(0,t).filter(l=>e[l.columnIndex].locked),R=n.slice(c+1).filter(l=>e[l.columnIndex].locked);return[...O,...n.slice(t,c+1),...R]}exports.addAllAncestors=L;exports.addDescendants=w;exports.getParentIndices=E;exports.getVirtualCellsToRender=D;exports.getVirtualHeaderCellsToRender=j;