@progress/kendo-vue-grid 7.1.0-develop.7 → 8.0.0-develop.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@progress/kendo-vue-grid",
3
- "version": "7.1.0-develop.7",
3
+ "version": "8.0.0-develop.2",
4
4
  "description": "TODO",
5
5
  "author": "Progress",
6
6
  "license": "SEE LICENSE IN LICENSE.md",
@@ -21,16 +21,16 @@
21
21
  "@progress/kendo-data-query": "^1.7.0",
22
22
  "@progress/kendo-drawing": "^1.21.1",
23
23
  "@progress/kendo-licensing": "^1.7.2",
24
- "@progress/kendo-vue-animation": "7.1.0-develop.7",
25
- "@progress/kendo-vue-buttons": "7.1.0-develop.7",
26
- "@progress/kendo-vue-common": "7.1.0-develop.7",
27
- "@progress/kendo-vue-data-tools": "7.1.0-develop.7",
28
- "@progress/kendo-vue-dateinputs": "7.1.0-develop.7",
29
- "@progress/kendo-vue-indicators": "7.1.0-develop.7",
30
- "@progress/kendo-vue-dropdowns": "7.1.0-develop.7",
31
- "@progress/kendo-vue-inputs": "7.1.0-develop.7",
32
- "@progress/kendo-vue-intl": "7.1.0-develop.7",
33
- "@progress/kendo-vue-popup": "7.1.0-develop.7",
24
+ "@progress/kendo-vue-animation": "8.0.0-develop.2",
25
+ "@progress/kendo-vue-buttons": "8.0.0-develop.2",
26
+ "@progress/kendo-vue-common": "8.0.0-develop.2",
27
+ "@progress/kendo-vue-data-tools": "8.0.0-develop.2",
28
+ "@progress/kendo-vue-dateinputs": "8.0.0-develop.2",
29
+ "@progress/kendo-vue-indicators": "8.0.0-develop.2",
30
+ "@progress/kendo-vue-dropdowns": "8.0.0-develop.2",
31
+ "@progress/kendo-vue-inputs": "8.0.0-develop.2",
32
+ "@progress/kendo-vue-intl": "8.0.0-develop.2",
33
+ "@progress/kendo-vue-popup": "8.0.0-develop.2",
34
34
  "@progress/kendo-svg-icons": "^4.4.0",
35
35
  "vue": "^3.0.2"
36
36
  },
@@ -51,7 +51,7 @@
51
51
  "package": {
52
52
  "productName": "Kendo UI for Vue",
53
53
  "productCode": "KENDOUIVUE",
54
- "publishDate": 1770355607,
54
+ "publishDate": 1770620929,
55
55
  "licensingDocsUrl": "https://www.telerik.com/kendo-vue-ui/my-license/"
56
56
  }
57
57
  },
package/rows/GridRow.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"),i=require("@progress/kendo-vue-common"),s=t.defineComponent({name:"KendoGridRow",props:{rowType:String,item:Object,isAltRow:Boolean,isHidden:Boolean,isHighlighted:Boolean,onClick:Function,isInEdit:Boolean,isSelected:Boolean,selectedField:String,rowHeight:Number,ariaRowIndex:Number,absoluteRowIndex:Number,dataIndex:Number,render:[String,Function,Object],onRowclick:Function,onRowdblclick:Function},methods:{handleClick(e){this.$emit("rowclick",e)},handleDoubleClick(e){this.$emit("rowdblclick",e)}},computed:{trClass(){const{rowType:e,isAltRow:o,isInEdit:r,isHighlighted:l,isSelected:n}=this.$props;return{"k-table-row":!0,"k-selected":n,"k-highlighted":l,"k-table-group-row":e==="groupHeader","k-grouping-row":e==="groupHeader","k-group-footer":e==="groupFooter","k-master-row":e!=="groupHeader"&&e!=="groupFooter","k-table-alt-row":o,"k-edit-row":r}}},render(){const e=i.getDefaultSlots(this),o=t.createVNode("tr",{onClick:this.handleClick,onDblclick:this.handleDoubleClick,class:this.trClass,style:{height:this.$props.rowHeight?this.$props.rowHeight+"px":"",visibility:this.$props.isHidden?"hidden":""},role:"row","aria-rowindex":this.$props.ariaRowIndex,"absolute-row-index":this.$props.absoluteRowIndex,"data-grid-row-index":this.$props.rowType==="data"?this.$props.dataIndex:void 0},[e]);return i.getTemplate.call(this,{h:t.h,template:this.$props.render,defaultRendering:o,additionalProps:this.$props,additionalListeners:{click:this.handleClick},defaultSlots:e,swapDefaultSlots:!0})}});exports.GridRow=s;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),i=require("@progress/kendo-vue-common"),n=o.defineComponent({name:"KendoGridRow",props:{rowType:String,item:Object,isAltRow:Boolean,isHidden:Boolean,isHighlighted:Boolean,onClick:Function,isInEdit:Boolean,isSelected:Boolean,selectedField:String,rowHeight:Number,ariaRowIndex:Number,absoluteRowIndex:Number,dataIndex:Number,render:[String,Function,Object],onRowclick:Function,onRowdblclick:Function},methods:{handleClick(e){this.$emit("rowclick",e)},handleDoubleClick(e){this.$emit("rowdblclick",e)}},computed:{trClass(){const{rowType:e,isAltRow:t,isInEdit:r,isHighlighted:s,isSelected:l}=this.$props;return{"k-table-row":!0,"k-selected":l,"k-highlighted":s,"k-table-group-row":e==="groupHeader","k-grouping-row":e==="groupHeader","k-group-footer":e==="groupFooter","k-master-row":e!=="groupHeader"&&e!=="groupFooter","k-table-alt-row":t,"k-edit-row":r}}},render(){const e=i.getDefaultSlots(this),t=o.createVNode("tr",{onClick:this.handleClick,onDblclick:this.handleDoubleClick,class:this.trClass,style:{height:this.$props.rowHeight?this.$props.rowHeight+"px":"",visibility:this.$props.isHidden?"hidden":""},role:"row","aria-rowindex":this.$props.ariaRowIndex,"absolute-row-index":this.$props.absoluteRowIndex,"data-grid-row-index":this.$props.rowType==="data"?this.$props.dataIndex:void 0},[e]);return i.getTemplate.call(this,{h:o.h,template:this.$props.render,defaultRendering:t,additionalProps:{...this.$props,dataItem:this.$props.item.dataItem},additionalListeners:{click:this.handleClick},defaultSlots:e,swapDefaultSlots:!0})}});exports.GridRow=n;
package/rows/GridRow.mjs CHANGED
@@ -5,8 +5,8 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import { defineComponent as l, createVNode as s, h as n } from "vue";
9
- import { getDefaultSlots as d, getTemplate as a } from "@progress/kendo-vue-common";
8
+ import { defineComponent as l, createVNode as s, h as d } from "vue";
9
+ import { getDefaultSlots as n, getTemplate as a } from "@progress/kendo-vue-common";
10
10
  const c = /* @__PURE__ */ l({
11
11
  name: "KendoGridRow",
12
12
  props: {
@@ -39,8 +39,8 @@ const c = /* @__PURE__ */ l({
39
39
  trClass() {
40
40
  const {
41
41
  rowType: e,
42
- isAltRow: o,
43
- isInEdit: t,
42
+ isAltRow: t,
43
+ isInEdit: o,
44
44
  isHighlighted: i,
45
45
  isSelected: r
46
46
  } = this.$props;
@@ -52,13 +52,13 @@ const c = /* @__PURE__ */ l({
52
52
  "k-grouping-row": e === "groupHeader",
53
53
  "k-group-footer": e === "groupFooter",
54
54
  "k-master-row": e !== "groupHeader" && e !== "groupFooter",
55
- "k-table-alt-row": o,
56
- "k-edit-row": t
55
+ "k-table-alt-row": t,
56
+ "k-edit-row": o
57
57
  };
58
58
  }
59
59
  },
60
60
  render() {
61
- const e = d(this), o = s("tr", {
61
+ const e = n(this), t = s("tr", {
62
62
  onClick: this.handleClick,
63
63
  onDblclick: this.handleDoubleClick,
64
64
  class: this.trClass,
@@ -72,10 +72,13 @@ const c = /* @__PURE__ */ l({
72
72
  "data-grid-row-index": this.$props.rowType === "data" ? this.$props.dataIndex : void 0
73
73
  }, [e]);
74
74
  return a.call(this, {
75
- h: n,
75
+ h: d,
76
76
  template: this.$props.render,
77
- defaultRendering: o,
78
- additionalProps: this.$props,
77
+ defaultRendering: t,
78
+ additionalProps: {
79
+ ...this.$props,
80
+ dataItem: this.$props.item.dataItem
81
+ },
79
82
  additionalListeners: {
80
83
  click: this.handleClick
81
84
  },
package/utils/main.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 x=require("@progress/kendo-vue-data-tools"),w=require("@progress/kendo-vue-common"),v=require("../GridColumn.js"),y="string";function I(e,t){const n=e.split(".");let r=t;return n.forEach(a=>{r=r?r[a]:void 0}),r}function M(e,t,n,r,a,l,i,o,d,s,c=0,f){let g=c;for(let h=0;h<t.length;h++){let u;if(!a||t[h].value===void 0||t[h].items===void 0){const p=d?!!(l!=null&&l[w.getter(d)(t[h])]):!1;e[e.length]={dataIndex:r.index,dataItem:t[h],rowType:"data",level:c,group:f,expanded:s!==void 0?I(s,t[h]):p!=null?p:!1},r.index++;continue}else{let p;f!=null&&f.parents?p=[{field:f.field,value:f.value},...f.parents]:f?p=[f]:p=[],u={field:t[h].field,value:t[h].value,parents:p}}g=Math.max(g,c+1);let C=!1;const m=x.findGroupExpand(i||[],u);s?C=s===void 0||I(s,t[h])===void 0||I(s,t[h]):C=m?m.expanded!==!1:o!==!1,e[e.length]={dataIndex:-1,dataItem:t[h],level:c,group:u,rowType:"groupHeader",expanded:C},C&&(u.expanded=C,g=Math.max(M(e,t[h].items,n,r,a,l,i,o,d,s,c+1,u),g)),(n==="always"||C&&n==="visible")&&(e[e.length]={dataIndex:-1,dataItem:t[h],rowType:"groupFooter",level:c,expanded:C})}return g}function F(e){return e&&getComputedStyle(e).direction==="rtl"||!1}function A(e,t){if(!t||!e||!e.originalEvent||!w.canUseDOM)return-1;let n=document.elementFromPoint(e.clientX,e.originalEvent.clientY);for(;n&&n.parentElement!==t;)n=n.parentElement;const r=t.children;for(let a=0;a<r.length;a++)if(r[a]===n)return a;return-1}const E=["sortChange","filterChange","groupChange","pageChange","expandChange","selectionChange","headerSelectionChange","rowClick","itemChange","dataStateChange","columnResize","columnReorder"],k=(e,t)=>`The ${e} event handler property is deprecated, use https://www.telerik.com/kendo-vue-ui/components/grid/api/GridProps/#toc-${t} instead`;function N(e){for(let t=0;t<E.length;t++){const n=E[t];if(e[n]!==void 0){const r="on"+n.charAt(0).toUpperCase()+n.slice(1);console.warn(k(n,r))}}}function H(e,t){const n=[[]];let r=0;for(let i=e.length-1;i>=0;i--)r=Math.max(r,e[i].depth),e[i].headerColSpan=e[i].headerColSpan||1,e[i].children.length>0&&(e[i].headerColSpan=e[i].children.reduce((o,d)=>d.hidden?o:o+d.headerColSpan,0));const a=[];let l=1;return e.forEach((i,o)=>{n[i.depth]=n[i.depth]||[];let d=!1;n[i.depth].length===0&&(l<=1?l=1+(i.children.length>0?0:r-i.depth):(l--,d=!0)),i.rowSpan=1+(i.children.length>0?0:r-i.depth),i.kFirst=d,i.index=n[i.depth].length,n[i.depth].push(o),i.ariaColumnIndex=a[i.depth]?a[i.depth]+1:1;for(let s=i.depth;s<i.depth+i.rowSpan;s++)a[s]=(a[s]||0)+i.headerColSpan}),x.updateLeft(n,e,t),x.updateRight(n,e,t),n}function R(e,t,n,r=0,a=!1){const l=[];if(!e)return[];e&&e.length===void 0&&(e=[e]),e.forEach((o,d)=>{o=o;const s=o.id?o.id:x.tableKeyboardNavigationTools.generateNavigatableId(`${n.prevId++}`,n.idPrefix,"column"),c=w.canUseDOM&&o.media&&window.matchMedia?!window.matchMedia(o.media).matches:!1,f=a||c||o.hidden,g=t==null?void 0:t.find(u=>u.id===s),h=R(o.children,(g==null?void 0:g.children)||[],n,r+1,f);l.push({depth:r,...v.gridDefaultProps,...h.length?{cell:()=>null,filterCell:()=>null}:{},...o,id:s,declarationIndex:l.length,children:h,headerColSpan:0,rowSpan:0,columnType:o.columnType||"data",colSpan:o.colSpan||1,isAccessible:!0,hidden:f,left:null,right:null,rowSpannable:o.rowSpannable,...g?{width:g.width,orderIndex:g.orderIndex}:{}})});const i=(o,d)=>o.orderIndex===d.orderIndex?o.declarationIndex-d.declarationIndex:(o.orderIndex||0)-(d.orderIndex||0);if(l.sort(i),r===0){const o=[],d=(s,c)=>s.forEach(f=>{f.parentIndex=c,d(f.children,o.push(f)-1)});return d(l,-1),o}return l}const b=e=>Array.isArray(e)?e:e?e.data:[];function L(e,t,n,r){const a=b(e),l=[];if(a.length>0){let i=a[0];if(t)for(let d=0;d<t.length;d++)i=i.items&&i.items[0];Object.getOwnPropertyNames(i).forEach(d=>{d!==n.column&&l.push({id:x.tableKeyboardNavigationTools.generateNavigatableId(`${r.prevId++}`,r.idPrefix,"column"),declarationIndex:-1,parentIndex:-1,depth:0,colSpan:0,headerColSpan:0,rowSpan:0,index:0,columnType:"data",left:0,right:0,rightBorder:!1,children:[],ariaColumnIndex:0,isAccessible:!0,...v.gridDefaultProps,field:d})})}return l}const O=(e,t)=>{let n=e[t.parentIndex];for(;n;){if(n.footerCell)return!0;n=e[n.parentIndex]}return!1},V=e=>e.filter(t=>O(e,t)?!1:!!t.footerCell||!(t.children&&t.children.length>0)),j={number:function(e,t,n){return typeof e===y&&e.toLowerCase()==="null"?null:t.parseNumber(e,n)},date:function(e,t,n){return typeof e===y&&e.toLowerCase()==="null"?null:t.parseDate(e,n)},boolean:function(e){return typeof e===y?e.toLowerCase()==="null"?null:e.toLowerCase()==="true":e!=null?!!e:e},string:function(e){return typeof e===y&&e.toLowerCase()==="null"?null:e!=null?e+"":e},default:function(e){return e}};function T(e,t,n,r){return e.forEach(a=>{a.expanded=t[r]&&!t[r].includes(S(a,n)),a.items&&a.items.length&&(a.items=T(a.items,t,n,r+1))}),e}function K(e,t,n){return t&&t.length&&e.data.forEach(r=>{r.expanded=r.expanded!==void 0?r.expanded:t[0]&&!t[0].includes(S(r,n)),r.items&&r.items.length&&(r.items=T(r.items,t,n,1))}),e}function S(e,t){let n=e;for(;n.items&&n.items.length;)n=n.items[0];return t?n[t]:e.value}const $=e=>{const t=[],n=r=>r==null?void 0:r.forEach(a=>{t.push(a),n(a.children)});return n(e),t},z=typeof window!="undefined"&&/Firefox/.test(window.navigator.userAgent),B=17895697,U=e=>e.width!==void 0?Math.floor(parseFloat(e.width.toString()))+"px":void 0,q=(e,t)=>t&&t.filter(n=>n.field===e).length>0,D=e=>(e.sort((t,n)=>t.declarationIndex-n.declarationIndex),e.map(t=>{const{declarationIndex:n,parentIndex:r,depth:a,headerColSpan:l,rowSpan:i,index:o,kFirst:d,children:s,...c}=t;return s.length?{children:D(s),...c}:c})),W=(e,t)=>typeof e.colSpan=="function"?e.colSpan({dataItem:t,column:e}):e.colSpan||1,X=e=>{var r,a;const t=typeof e=="object"?(r=e.enabled)!=null?r:!0:e!=null?e:!1,n=typeof e=="object"?(a=e.valueGetter)!=null?a:(l,i)=>w.getter(i)(l):(l,i)=>w.getter(i)(l);return{enabled:t,valueGetter:n}},Y=e=>{let t=0;if(e){const n=e.insertRow(0),r=n.insertCell(0);r.textContent="&nbsp;",t=n.getBoundingClientRect().height,e.deleteRow(0)}return t};exports.applyExpandedState=K;exports.autoGenerateColumns=L;exports.calcRowHeight=Y;exports.checkPropCompatibility=N;exports.firefox=z;exports.firefoxMaxHeight=B;exports.flatData=M;exports.footerColumns=V;exports.getColSpan=W;exports.getColumnWidth=U;exports.getDataAsArray=b;exports.getFlatColumnsState=$;exports.getIndex=A;exports.getNestedValue=I;exports.getRowSpanOptions=X;exports.groupedFirstItemValue=S;exports.isRtl=F;exports.isSorted=q;exports.mapColumns=H;exports.parsers=j;exports.readColumns=R;exports.sanitizeColumns=D;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const w=require("@progress/kendo-vue-data-tools"),I=require("@progress/kendo-vue-common"),D=require("../GridColumn.js"),y="string";function v(e,t){const n=e.split(".");let i=t;return n.forEach(a=>{i=i?i[a]:void 0}),i}function R(e,t,n,i,a,s,r,o,d,h,p=0,f){let c=p;for(let g=0;g<t.length;g++){let l;if(!a||t[g].value===void 0||t[g].items===void 0){const C=d?!!(s!=null&&s[I.getter(d)(t[g])]):!1;e[e.length]={dataIndex:i.index,dataItem:t[g],rowType:"data",level:p,group:f,expanded:h!==void 0?v(h,t[g]):C!=null?C:!1},i.index++;continue}else{let C;f!=null&&f.parents?C=[{field:f.field,value:f.value},...f.parents]:f?C=[f]:C=[],l={field:t[g].field,value:t[g].value,parents:C}}c=Math.max(c,p+1);let x=!1;const u=w.findGroupExpand(r||[],l);h?x=h===void 0||v(h,t[g])===void 0||v(h,t[g]):x=u?u.expanded!==!1:o!==!1,e[e.length]={dataIndex:-1,dataItem:t[g],level:p,group:l,rowType:"groupHeader",expanded:x},x&&(l.expanded=x,c=Math.max(R(e,t[g].items,n,i,a,s,r,o,d,h,p+1,l),c)),(n==="always"||x&&n==="visible")&&(e[e.length]={dataIndex:-1,dataItem:t[g],rowType:"groupFooter",level:p,expanded:x})}return c}function O(e){return e&&getComputedStyle(e).direction==="rtl"||!1}function N(e,t){if(!t||!e||!e.originalEvent||!I.canUseDOM)return-1;let n=document.elementFromPoint(e.clientX,e.originalEvent.clientY);for(;n&&n.parentElement!==t;)n=n.parentElement;const i=t.children;for(let a=0;a<i.length;a++)if(i[a]===n)return a;return-1}const A=["sortChange","filterChange","groupChange","pageChange","expandChange","selectionChange","headerSelectionChange","rowClick","itemChange","dataStateChange","columnResize","columnReorder"],H=(e,t)=>`The ${e} event handler property is deprecated, use https://www.telerik.com/kendo-vue-ui/components/grid/api/GridProps/#toc-${t} instead`;function L(e){for(let t=0;t<A.length;t++){const n=A[t];if(e[n]!==void 0){const i="on"+n.charAt(0).toUpperCase()+n.slice(1);console.warn(H(n,i))}}}function V(e,t){const n=[[]];let i=0;for(let r=e.length-1;r>=0;r--)i=Math.max(i,e[r].depth),e[r].headerColSpan=e[r].headerColSpan||1,e[r].children.length>0&&(e[r].headerColSpan=e[r].children.reduce((o,d)=>d.hidden?o:o+d.headerColSpan,0));const a=[];let s=1;return e.forEach((r,o)=>{n[r.depth]=n[r.depth]||[];let d=!1;n[r.depth].length===0&&(s<=1?s=1+(r.children.length>0?0:i-r.depth):(s--,d=!0)),r.rowSpan=1+(r.children.length>0?0:i-r.depth),r.kFirst=d,r.index=n[r.depth].length,r.ariaColumnIndex=a[r.depth]?a[r.depth]+1:1;let h=0;const p=[],f=new Set;let c=r.parentIndex;for(;c>=0&&!f.has(c);)f.add(c),p.unshift(c),c=e[c].parentIndex;for(let l=0;l<p.length;l++){const x=p[l],u=e[x],C=n[u.depth],E=C.indexOf(x);for(let S=0;S<E;S++){const m=C[S];h+=e[m].headerColSpan}}for(let l=0;l<r.depth;l++){const x=n[l]||[];for(const u of x){const C=e[u];C.depth+C.rowSpan-1>=r.depth&&(p.includes(u)||(h+=C.headerColSpan))}}const g=n[r.depth];for(const l of g){const x=e[l];x.parentIndex===r.parentIndex&&(h+=x.headerColSpan)}r.virtualColumnOffset=h,n[r.depth].push(o);for(let l=r.depth;l<r.depth+r.rowSpan;l++)a[l]=(a[l]||0)+r.headerColSpan}),w.updateLeft(n,e,t),w.updateRight(n,e,t),n}function M(e,t,n,i=0,a=!1){const s=[];if(!e)return[];e&&e.length===void 0&&(e=[e]),e.forEach((o,d)=>{o=o;const h=o.id?o.id:w.tableKeyboardNavigationTools.generateNavigatableId(`${n.prevId++}`,n.idPrefix,"column"),p=I.canUseDOM&&o.media&&window.matchMedia?!window.matchMedia(o.media).matches:!1,f=a||p||o.hidden,c=t==null?void 0:t.find(l=>l.id===h),g=M(o.children,(c==null?void 0:c.children)||[],n,i+1,f);s.push({depth:i,...D.gridDefaultProps,...g.length?{cell:()=>null,filterCell:()=>null}:{},...o,id:h,declarationIndex:s.length,children:g,headerColSpan:0,rowSpan:0,columnType:o.columnType||"data",colSpan:o.colSpan||1,isAccessible:!0,hidden:f,left:null,right:null,rowSpannable:o.rowSpannable,...c?{width:c.width,orderIndex:c.orderIndex}:{}})});const r=(o,d)=>o.orderIndex===d.orderIndex?o.declarationIndex-d.declarationIndex:(o.orderIndex||0)-(d.orderIndex||0);if(s.sort(r),i===0){const o=[],d=(h,p)=>h.forEach(f=>{f.parentIndex=p,d(f.children,o.push(f)-1)});return d(s,-1),o}return s}const T=e=>Array.isArray(e)?e:e?e.data:[];function j(e,t,n,i){const a=T(e),s=[];if(a.length>0){let r=a[0];if(t)for(let d=0;d<t.length;d++)r=r.items&&r.items[0];Object.getOwnPropertyNames(r).forEach(d=>{d!==n.column&&s.push({id:w.tableKeyboardNavigationTools.generateNavigatableId(`${i.prevId++}`,i.idPrefix,"column"),declarationIndex:-1,parentIndex:-1,depth:0,colSpan:0,headerColSpan:0,rowSpan:0,index:0,columnType:"data",left:0,right:0,rightBorder:!1,children:[],ariaColumnIndex:0,isAccessible:!0,...D.gridDefaultProps,field:d})})}return s}const K=(e,t)=>{let n=e[t.parentIndex];for(;n;){if(n.footerCell)return!0;n=e[n.parentIndex]}return!1},P=e=>e.filter(t=>K(e,t)?!1:!!t.footerCell||!(t.children&&t.children.length>0)),$={number:function(e,t,n){return typeof e===y&&e.toLowerCase()==="null"?null:t.parseNumber(e,n)},date:function(e,t,n){return typeof e===y&&e.toLowerCase()==="null"?null:t.parseDate(e,n)},boolean:function(e){return typeof e===y?e.toLowerCase()==="null"?null:e.toLowerCase()==="true":e!=null?!!e:e},string:function(e){return typeof e===y&&e.toLowerCase()==="null"?null:e!=null?e+"":e},default:function(e){return e}};function F(e,t,n,i){return e.forEach(a=>{a.expanded=t[i]&&!t[i].includes(b(a,n)),a.items&&a.items.length&&(a.items=F(a.items,t,n,i+1))}),e}function z(e,t,n){return t&&t.length&&e.data.forEach(i=>{i.expanded=i.expanded!==void 0?i.expanded:t[0]&&!t[0].includes(b(i,n)),i.items&&i.items.length&&(i.items=F(i.items,t,n,1))}),e}function b(e,t){let n=e;for(;n.items&&n.items.length;)n=n.items[0];return t?n[t]:e.value}const B=e=>{const t=[],n=i=>i==null?void 0:i.forEach(a=>{t.push(a),n(a.children)});return n(e),t},U=typeof window!="undefined"&&/Firefox/.test(window.navigator.userAgent),q=17895697,W=e=>e.width!==void 0?Math.floor(parseFloat(e.width.toString()))+"px":void 0,X=(e,t)=>t&&t.filter(n=>n.field===e).length>0,k=e=>(e.sort((t,n)=>t.declarationIndex-n.declarationIndex),e.map(t=>{const{declarationIndex:n,parentIndex:i,depth:a,headerColSpan:s,rowSpan:r,index:o,kFirst:d,children:h,...p}=t;return h.length?{children:k(h),...p}:p})),Y=(e,t)=>typeof e.colSpan=="function"?e.colSpan({dataItem:t,column:e}):e.colSpan||1,J=e=>{var i,a;const t=typeof e=="object"?(i=e.enabled)!=null?i:!0:e!=null?e:!1,n=typeof e=="object"?(a=e.valueGetter)!=null?a:(s,r)=>I.getter(r)(s):(s,r)=>I.getter(r)(s);return{enabled:t,valueGetter:n}},Q=e=>{let t=0;if(e){const n=e.insertRow(0),i=n.insertCell(0);i.textContent="&nbsp;",t=n.getBoundingClientRect().height,e.deleteRow(0)}return t};exports.applyExpandedState=z;exports.autoGenerateColumns=j;exports.calcRowHeight=Q;exports.checkPropCompatibility=L;exports.firefox=U;exports.firefoxMaxHeight=q;exports.flatData=R;exports.footerColumns=P;exports.getColSpan=Y;exports.getColumnWidth=W;exports.getDataAsArray=T;exports.getFlatColumnsState=B;exports.getIndex=N;exports.getNestedValue=v;exports.getRowSpanOptions=J;exports.groupedFirstItemValue=b;exports.isRtl=O;exports.isSorted=X;exports.mapColumns=V;exports.parsers=$;exports.readColumns=M;exports.sanitizeColumns=k;
package/utils/main.mjs CHANGED
@@ -5,93 +5,93 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import { findGroupExpand as F, updateLeft as T, updateRight as A, tableKeyboardNavigationTools as E } from "@progress/kendo-vue-data-tools";
9
- import { getter as I, canUseDOM as m } from "@progress/kendo-vue-common";
10
- import { gridDefaultProps as v } from "../GridColumn.mjs";
11
- const w = "string";
12
- function u(e, t) {
8
+ import { findGroupExpand as T, updateLeft as k, updateRight as L, tableKeyboardNavigationTools as A } from "@progress/kendo-vue-data-tools";
9
+ import { getter as S, canUseDOM as b } from "@progress/kendo-vue-common";
10
+ import { gridDefaultProps as R } from "../GridColumn.mjs";
11
+ const u = "string";
12
+ function y(e, t) {
13
13
  const n = e.split(".");
14
- let r = t;
14
+ let i = t;
15
15
  return n.forEach((a) => {
16
- r = r ? r[a] : void 0;
17
- }), r;
16
+ i = i ? i[a] : void 0;
17
+ }), i;
18
18
  }
19
- function b(e, t, n, r, a, l, i, d, o, s, c = 0, f) {
20
- let g = c;
21
- for (let h = 0; h < t.length; h++) {
22
- let x;
23
- if (!a || t[h].value === void 0 || t[h].items === void 0) {
24
- const p = o ? !!(l != null && l[I(o)(t[h])]) : !1;
19
+ function N(e, t, n, i, a, s, r, d, o, h, p = 0, f) {
20
+ let c = p;
21
+ for (let g = 0; g < t.length; g++) {
22
+ let l;
23
+ if (!a || t[g].value === void 0 || t[g].items === void 0) {
24
+ const C = o ? !!(s != null && s[S(o)(t[g])]) : !1;
25
25
  e[e.length] = {
26
- dataIndex: r.index,
27
- dataItem: t[h],
26
+ dataIndex: i.index,
27
+ dataItem: t[g],
28
28
  rowType: "data",
29
- level: c,
29
+ level: p,
30
30
  group: f,
31
31
  // This is related to detail-row expansion
32
- expanded: s !== void 0 ? u(s, t[h]) : p != null ? p : !1
33
- }, r.index++;
32
+ expanded: h !== void 0 ? y(h, t[g]) : C != null ? C : !1
33
+ }, i.index++;
34
34
  continue;
35
35
  } else {
36
- let p;
37
- f != null && f.parents ? p = [{ field: f.field, value: f.value }, ...f.parents] : f ? p = [f] : p = [], x = {
38
- field: t[h].field,
39
- value: t[h].value,
40
- parents: p
36
+ let C;
37
+ f != null && f.parents ? C = [{ field: f.field, value: f.value }, ...f.parents] : f ? C = [f] : C = [], l = {
38
+ field: t[g].field,
39
+ value: t[g].value,
40
+ parents: C
41
41
  };
42
42
  }
43
- g = Math.max(g, c + 1);
44
- let C = !1;
45
- const y = F(i || [], x);
46
- s ? C = s === void 0 || u(s, t[h]) === void 0 || u(s, t[h]) : C = y ? y.expanded !== !1 : d !== !1, e[e.length] = {
43
+ c = Math.max(c, p + 1);
44
+ let x = !1;
45
+ const w = T(r || [], l);
46
+ h ? x = h === void 0 || y(h, t[g]) === void 0 || y(h, t[g]) : x = w ? w.expanded !== !1 : d !== !1, e[e.length] = {
47
47
  dataIndex: -1,
48
- dataItem: t[h],
49
- level: c,
50
- group: x,
48
+ dataItem: t[g],
49
+ level: p,
50
+ group: l,
51
51
  rowType: "groupHeader",
52
- expanded: C
53
- }, C && (x.expanded = C, g = Math.max(
54
- b(
52
+ expanded: x
53
+ }, x && (l.expanded = x, c = Math.max(
54
+ N(
55
55
  e,
56
- t[h].items,
56
+ t[g].items,
57
57
  n,
58
- r,
59
- a,
60
- l,
61
58
  i,
59
+ a,
60
+ s,
61
+ r,
62
62
  d,
63
63
  o,
64
- s,
65
- c + 1,
66
- x
64
+ h,
65
+ p + 1,
66
+ l
67
67
  ),
68
- g
69
- )), (n === "always" || C && n === "visible") && (e[e.length] = {
68
+ c
69
+ )), (n === "always" || x && n === "visible") && (e[e.length] = {
70
70
  dataIndex: -1,
71
- dataItem: t[h],
71
+ dataItem: t[g],
72
72
  rowType: "groupFooter",
73
- level: c,
74
- expanded: C
73
+ level: p,
74
+ expanded: x
75
75
  });
76
76
  }
77
- return g;
77
+ return c;
78
78
  }
79
- function B(e) {
79
+ function U(e) {
80
80
  return e && getComputedStyle(e).direction === "rtl" || !1;
81
81
  }
82
- function K(e, t) {
83
- if (!t || !e || !e.originalEvent || !m)
82
+ function V(e, t) {
83
+ if (!t || !e || !e.originalEvent || !b)
84
84
  return -1;
85
85
  let n = document.elementFromPoint(e.clientX, e.originalEvent.clientY);
86
86
  for (; n && n.parentElement !== t; )
87
87
  n = n.parentElement;
88
- const r = t.children;
89
- for (let a = 0; a < r.length; a++)
90
- if (r[a] === n)
88
+ const i = t.children;
89
+ for (let a = 0; a < i.length; a++)
90
+ if (i[a] === n)
91
91
  return a;
92
92
  return -1;
93
93
  }
94
- const S = [
94
+ const E = [
95
95
  "sortChange",
96
96
  "filterChange",
97
97
  "groupChange",
@@ -104,50 +104,75 @@ const S = [
104
104
  "dataStateChange",
105
105
  "columnResize",
106
106
  "columnReorder"
107
- ], L = (e, t) => `The ${e} event handler property is deprecated, use https://www.telerik.com/kendo-vue-ui/components/grid/api/GridProps/#toc-${t} instead`;
108
- function z(e) {
109
- for (let t = 0; t < S.length; t++) {
110
- const n = S[t];
107
+ ], O = (e, t) => `The ${e} event handler property is deprecated, use https://www.telerik.com/kendo-vue-ui/components/grid/api/GridProps/#toc-${t} instead`;
108
+ function P(e) {
109
+ for (let t = 0; t < E.length; t++) {
110
+ const n = E[t];
111
111
  if (e[n] !== void 0) {
112
- const r = "on" + n.charAt(0).toUpperCase() + n.slice(1);
113
- console.warn(L(n, r));
112
+ const i = "on" + n.charAt(0).toUpperCase() + n.slice(1);
113
+ console.warn(O(n, i));
114
114
  }
115
115
  }
116
116
  }
117
- function U(e, t) {
117
+ function W(e, t) {
118
118
  const n = [[]];
119
- let r = 0;
120
- for (let i = e.length - 1; i >= 0; i--)
121
- r = Math.max(r, e[i].depth), e[i].headerColSpan = e[i].headerColSpan || 1, e[i].children.length > 0 && (e[i].headerColSpan = e[i].children.reduce(
119
+ let i = 0;
120
+ for (let r = e.length - 1; r >= 0; r--)
121
+ i = Math.max(i, e[r].depth), e[r].headerColSpan = e[r].headerColSpan || 1, e[r].children.length > 0 && (e[r].headerColSpan = e[r].children.reduce(
122
122
  (d, o) => o.hidden ? d : d + o.headerColSpan,
123
123
  0
124
124
  ));
125
125
  const a = [];
126
- let l = 1;
127
- return e.forEach((i, d) => {
128
- n[i.depth] = n[i.depth] || [];
126
+ let s = 1;
127
+ return e.forEach((r, d) => {
128
+ n[r.depth] = n[r.depth] || [];
129
129
  let o = !1;
130
- n[i.depth].length === 0 && (l <= 1 ? l = 1 + (i.children.length > 0 ? 0 : r - i.depth) : (l--, o = !0)), i.rowSpan = 1 + (i.children.length > 0 ? 0 : r - i.depth), i.kFirst = o, i.index = n[i.depth].length, n[i.depth].push(d), i.ariaColumnIndex = a[i.depth] ? a[i.depth] + 1 : 1;
131
- for (let s = i.depth; s < i.depth + i.rowSpan; s++)
132
- a[s] = (a[s] || 0) + i.headerColSpan;
133
- }), T(n, e, t), A(n, e, t), n;
130
+ n[r.depth].length === 0 && (s <= 1 ? s = 1 + (r.children.length > 0 ? 0 : i - r.depth) : (s--, o = !0)), r.rowSpan = 1 + (r.children.length > 0 ? 0 : i - r.depth), r.kFirst = o, r.index = n[r.depth].length, r.ariaColumnIndex = a[r.depth] ? a[r.depth] + 1 : 1;
131
+ let h = 0;
132
+ const p = [], f = /* @__PURE__ */ new Set();
133
+ let c = r.parentIndex;
134
+ for (; c >= 0 && !f.has(c); )
135
+ f.add(c), p.unshift(c), c = e[c].parentIndex;
136
+ for (let l = 0; l < p.length; l++) {
137
+ const x = p[l], w = e[x], C = n[w.depth], v = C.indexOf(x);
138
+ for (let I = 0; I < v; I++) {
139
+ const F = C[I];
140
+ h += e[F].headerColSpan;
141
+ }
142
+ }
143
+ for (let l = 0; l < r.depth; l++) {
144
+ const x = n[l] || [];
145
+ for (const w of x) {
146
+ const C = e[w];
147
+ C.depth + C.rowSpan - 1 >= r.depth && (p.includes(w) || (h += C.headerColSpan));
148
+ }
149
+ }
150
+ const g = n[r.depth];
151
+ for (const l of g) {
152
+ const x = e[l];
153
+ x.parentIndex === r.parentIndex && (h += x.headerColSpan);
154
+ }
155
+ r.virtualColumnOffset = h, n[r.depth].push(d);
156
+ for (let l = r.depth; l < r.depth + r.rowSpan; l++)
157
+ a[l] = (a[l] || 0) + r.headerColSpan;
158
+ }), k(n, e, t), L(n, e, t), n;
134
159
  }
135
- function N(e, t, n, r = 0, a = !1) {
136
- const l = [];
160
+ function H(e, t, n, i = 0, a = !1) {
161
+ const s = [];
137
162
  if (!e)
138
163
  return [];
139
164
  e && e.length === void 0 && (e = [e]), e.forEach((d, o) => {
140
165
  d = d;
141
- const s = d.id ? d.id : E.generateNavigatableId(`${n.prevId++}`, n.idPrefix, "column"), c = m && d.media && window.matchMedia ? !window.matchMedia(d.media).matches : !1, f = a || c || d.hidden, g = t == null ? void 0 : t.find((x) => x.id === s), h = N(d.children, (g == null ? void 0 : g.children) || [], n, r + 1, f);
142
- l.push(
166
+ const h = d.id ? d.id : A.generateNavigatableId(`${n.prevId++}`, n.idPrefix, "column"), p = b && d.media && window.matchMedia ? !window.matchMedia(d.media).matches : !1, f = a || p || d.hidden, c = t == null ? void 0 : t.find((l) => l.id === h), g = H(d.children, (c == null ? void 0 : c.children) || [], n, i + 1, f);
167
+ s.push(
143
168
  {
144
- depth: r,
145
- ...v,
146
- ...h.length ? { cell: () => null, filterCell: () => null } : {},
169
+ depth: i,
170
+ ...R,
171
+ ...g.length ? { cell: () => null, filterCell: () => null } : {},
147
172
  ...d,
148
- id: s,
149
- declarationIndex: l.length,
150
- children: h,
173
+ id: h,
174
+ declarationIndex: s.length,
175
+ children: g,
151
176
  headerColSpan: 0,
152
177
  rowSpan: 0,
153
178
  columnType: d.columnType || "data",
@@ -157,31 +182,31 @@ function N(e, t, n, r = 0, a = !1) {
157
182
  left: null,
158
183
  right: null,
159
184
  rowSpannable: d.rowSpannable,
160
- ...g ? { width: g.width, orderIndex: g.orderIndex } : {}
185
+ ...c ? { width: c.width, orderIndex: c.orderIndex } : {}
161
186
  }
162
187
  );
163
188
  });
164
- const i = (d, o) => d.orderIndex === o.orderIndex ? d.declarationIndex - o.declarationIndex : (d.orderIndex || 0) - (o.orderIndex || 0);
165
- if (l.sort(i), r === 0) {
166
- const d = [], o = (s, c) => s.forEach((f) => {
167
- f.parentIndex = c, o(f.children, d.push(f) - 1);
189
+ const r = (d, o) => d.orderIndex === o.orderIndex ? d.declarationIndex - o.declarationIndex : (d.orderIndex || 0) - (o.orderIndex || 0);
190
+ if (s.sort(r), i === 0) {
191
+ const d = [], o = (h, p) => h.forEach((f) => {
192
+ f.parentIndex = p, o(f.children, d.push(f) - 1);
168
193
  });
169
- return o(l, -1), d;
194
+ return o(s, -1), d;
170
195
  }
171
- return l;
196
+ return s;
172
197
  }
173
- const k = (e) => Array.isArray(e) ? e : e ? e.data : [];
174
- function V(e, t, n, r) {
175
- const a = k(e), l = [];
198
+ const j = (e) => Array.isArray(e) ? e : e ? e.data : [];
199
+ function X(e, t, n, i) {
200
+ const a = j(e), s = [];
176
201
  if (a.length > 0) {
177
- let i = a[0];
202
+ let r = a[0];
178
203
  if (t)
179
204
  for (let o = 0; o < t.length; o++)
180
- i = i.items && i.items[0];
181
- Object.getOwnPropertyNames(i).forEach((o) => {
182
- o !== n.column && l.push(
205
+ r = r.items && r.items[0];
206
+ Object.getOwnPropertyNames(r).forEach((o) => {
207
+ o !== n.column && s.push(
183
208
  {
184
- id: E.generateNavigatableId(`${r.prevId++}`, r.idPrefix, "column"),
209
+ id: A.generateNavigatableId(`${i.prevId++}`, i.idPrefix, "column"),
185
210
  declarationIndex: -1,
186
211
  parentIndex: -1,
187
212
  depth: 0,
@@ -196,15 +221,15 @@ function V(e, t, n, r) {
196
221
  children: [],
197
222
  ariaColumnIndex: 0,
198
223
  isAccessible: !0,
199
- ...v,
224
+ ...R,
200
225
  field: o
201
226
  }
202
227
  );
203
228
  });
204
229
  }
205
- return l;
230
+ return s;
206
231
  }
207
- const D = (e, t) => {
232
+ const $ = (e, t) => {
208
233
  let n = e[t.parentIndex];
209
234
  for (; n; ) {
210
235
  if (n.footerCell)
@@ -212,83 +237,83 @@ const D = (e, t) => {
212
237
  n = e[n.parentIndex];
213
238
  }
214
239
  return !1;
215
- }, W = (e) => e.filter((t) => D(e, t) ? !1 : !!t.footerCell || !(t.children && t.children.length > 0)), X = {
240
+ }, Y = (e) => e.filter((t) => $(e, t) ? !1 : !!t.footerCell || !(t.children && t.children.length > 0)), J = {
216
241
  number: function(e, t, n) {
217
- return typeof e === w && e.toLowerCase() === "null" ? null : t.parseNumber(e, n);
242
+ return typeof e === u && e.toLowerCase() === "null" ? null : t.parseNumber(e, n);
218
243
  },
219
244
  date: function(e, t, n) {
220
- return typeof e === w && e.toLowerCase() === "null" ? null : t.parseDate(e, n);
245
+ return typeof e === u && e.toLowerCase() === "null" ? null : t.parseDate(e, n);
221
246
  },
222
247
  boolean: function(e) {
223
- return typeof e === w ? e.toLowerCase() === "null" ? null : e.toLowerCase() === "true" : e != null ? !!e : e;
248
+ return typeof e === u ? e.toLowerCase() === "null" ? null : e.toLowerCase() === "true" : e != null ? !!e : e;
224
249
  },
225
250
  string: function(e) {
226
- return typeof e === w && e.toLowerCase() === "null" ? null : e != null ? e + "" : e;
251
+ return typeof e === u && e.toLowerCase() === "null" ? null : e != null ? e + "" : e;
227
252
  },
228
253
  default: function(e) {
229
254
  return e;
230
255
  }
231
256
  };
232
- function M(e, t, n, r) {
257
+ function M(e, t, n, i) {
233
258
  return e.forEach((a) => {
234
- a.expanded = t[r] && !t[r].includes(R(a, n)), a.items && a.items.length && (a.items = M(a.items, t, n, r + 1));
259
+ a.expanded = t[i] && !t[i].includes(D(a, n)), a.items && a.items.length && (a.items = M(a.items, t, n, i + 1));
235
260
  }), e;
236
261
  }
237
- function Y(e, t, n) {
238
- return t && t.length && e.data.forEach((r) => {
239
- r.expanded = r.expanded !== void 0 ? r.expanded : t[0] && !t[0].includes(R(r, n)), r.items && r.items.length && (r.items = M(r.items, t, n, 1));
262
+ function Q(e, t, n) {
263
+ return t && t.length && e.data.forEach((i) => {
264
+ i.expanded = i.expanded !== void 0 ? i.expanded : t[0] && !t[0].includes(D(i, n)), i.items && i.items.length && (i.items = M(i.items, t, n, 1));
240
265
  }), e;
241
266
  }
242
- function R(e, t) {
267
+ function D(e, t) {
243
268
  let n = e;
244
269
  for (; n.items && n.items.length; )
245
270
  n = n.items[0];
246
271
  return t ? n[t] : e.value;
247
272
  }
248
- const J = (e) => {
249
- const t = [], n = (r) => r == null ? void 0 : r.forEach((a) => {
273
+ const Z = (e) => {
274
+ const t = [], n = (i) => i == null ? void 0 : i.forEach((a) => {
250
275
  t.push(a), n(a.children);
251
276
  });
252
277
  return n(e), t;
253
- }, Q = typeof window != "undefined" && /Firefox/.test(window.navigator.userAgent), Z = 17895697, _ = (e) => e.width !== void 0 ? Math.floor(parseFloat(e.width.toString())) + "px" : void 0, q = (e, t) => t && t.filter((n) => n.field === e).length > 0, H = (e) => (e.sort((t, n) => t.declarationIndex - n.declarationIndex), e.map((t) => {
254
- const { declarationIndex: n, parentIndex: r, depth: a, headerColSpan: l, rowSpan: i, index: d, kFirst: o, children: s, ...c } = t;
255
- return s.length ? {
256
- children: H(s),
257
- ...c
258
- } : c;
259
- })), P = (e, t) => typeof e.colSpan == "function" ? e.colSpan({ dataItem: t, column: e }) : e.colSpan || 1, G = (e) => {
260
- var r, a;
261
- const t = typeof e == "object" ? (r = e.enabled) != null ? r : !0 : e != null ? e : !1, n = typeof e == "object" ? (a = e.valueGetter) != null ? a : (l, i) => I(i)(l) : (l, i) => I(i)(l);
278
+ }, _ = typeof window != "undefined" && /Firefox/.test(window.navigator.userAgent), q = 17895697, G = (e) => e.width !== void 0 ? Math.floor(parseFloat(e.width.toString())) + "px" : void 0, ee = (e, t) => t && t.filter((n) => n.field === e).length > 0, B = (e) => (e.sort((t, n) => t.declarationIndex - n.declarationIndex), e.map((t) => {
279
+ const { declarationIndex: n, parentIndex: i, depth: a, headerColSpan: s, rowSpan: r, index: d, kFirst: o, children: h, ...p } = t;
280
+ return h.length ? {
281
+ children: B(h),
282
+ ...p
283
+ } : p;
284
+ })), te = (e, t) => typeof e.colSpan == "function" ? e.colSpan({ dataItem: t, column: e }) : e.colSpan || 1, ne = (e) => {
285
+ var i, a;
286
+ const t = typeof e == "object" ? (i = e.enabled) != null ? i : !0 : e != null ? e : !1, n = typeof e == "object" ? (a = e.valueGetter) != null ? a : (s, r) => S(r)(s) : (s, r) => S(r)(s);
262
287
  return { enabled: t, valueGetter: n };
263
- }, ee = (e) => {
288
+ }, re = (e) => {
264
289
  let t = 0;
265
290
  if (e) {
266
- const n = e.insertRow(0), r = n.insertCell(0);
267
- r.textContent = "&nbsp;", t = n.getBoundingClientRect().height, e.deleteRow(0);
291
+ const n = e.insertRow(0), i = n.insertCell(0);
292
+ i.textContent = "&nbsp;", t = n.getBoundingClientRect().height, e.deleteRow(0);
268
293
  }
269
294
  return t;
270
295
  };
271
296
  export {
272
- Y as applyExpandedState,
273
- V as autoGenerateColumns,
274
- ee as calcRowHeight,
275
- z as checkPropCompatibility,
276
- Q as firefox,
277
- Z as firefoxMaxHeight,
278
- b as flatData,
279
- W as footerColumns,
280
- P as getColSpan,
281
- _ as getColumnWidth,
282
- k as getDataAsArray,
283
- J as getFlatColumnsState,
284
- K as getIndex,
285
- u as getNestedValue,
286
- G as getRowSpanOptions,
287
- R as groupedFirstItemValue,
288
- B as isRtl,
289
- q as isSorted,
290
- U as mapColumns,
291
- X as parsers,
292
- N as readColumns,
293
- H as sanitizeColumns
297
+ Q as applyExpandedState,
298
+ X as autoGenerateColumns,
299
+ re as calcRowHeight,
300
+ P as checkPropCompatibility,
301
+ _ as firefox,
302
+ q as firefoxMaxHeight,
303
+ N as flatData,
304
+ Y as footerColumns,
305
+ te as getColSpan,
306
+ G as getColumnWidth,
307
+ j as getDataAsArray,
308
+ Z as getFlatColumnsState,
309
+ V as getIndex,
310
+ y as getNestedValue,
311
+ ne as getRowSpanOptions,
312
+ D as groupedFirstItemValue,
313
+ U as isRtl,
314
+ ee as isSorted,
315
+ W as mapColumns,
316
+ J as parsers,
317
+ H as readColumns,
318
+ B as sanitizeColumns
294
319
  };
@@ -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 g(u){const{cellModels:l,columns:o=[],tableViewPortWidth:f,scrollLeft:c}=u;let n=0,t=l.length-1,i=0,d=0;for(let e=0;e<l.length;e++)if(!o[l[e].columnIndex].locked&&(i=d,d+=l[e].width||10,d>=c)){n=e;break}for(let e=n;e<l.length;e++)if(!o[l[e].columnIndex].locked)if(i<f+c)i+=l[e].width||10,t=e;else break;n>0&&n--,t<l.length-1&&t++;let r=0,s=0;for(let e=0;e<n;e++)o[l[e].columnIndex].locked||(r+=l[e].colSpan);for(let e=t+1;e<l.length;e++)o[l[e].columnIndex].locked||(s+=l[e].colSpan);l[n].colSpan+=r,l[t].colSpan+=s;const a=l.slice(0,n).filter(e=>o[e.columnIndex].locked),h=l.slice(t+1).filter(e=>o[e.columnIndex].locked);return[...a,...l.slice(n,t+1),...h]}exports.getVirtualCellsToRender=g;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function m(u){const{cellsToRender:n,columns:i,rowIndex:a,enableVirtualization:s}=u;if(!s||a!==0||!n||n.length===0)return{columnsToRender:[],colSpans:[]};const t=[],o=[];let c=-1,d=-1;for(let l=0;l<n.length;l++)i[n[l].columnIndex].locked||(c===-1&&(c=l),d=l);return n.forEach((l,r)=>{if(t.push(l.columnIndex),r===c)o.push(l.colSpan);else if(r===d)o.push(l.colSpan);else{const f=i[l.columnIndex];o.push(f.headerColSpan||1)}}),{columnsToRender:t,colSpans:o}}function p(u){const{cellModels:n,columns:i=[],tableViewPortWidth:a,scrollLeft:s}=u;let t=0,o=n.length-1,c=0,d=0;for(let e=0;e<n.length;e++)if(!i[n[e].columnIndex].locked&&(c=d,d+=n[e].width||10,d>=s)){t=e;break}for(let e=t;e<n.length;e++)if(!i[n[e].columnIndex].locked)if(c<a+s)c+=n[e].width||10,o=e;else break;t>0&&t--,o<n.length-1&&o++;let l=0,r=0;for(let e=0;e<t;e++)i[n[e].columnIndex].locked||(l+=n[e].colSpan);for(let e=o+1;e<n.length;e++)i[n[e].columnIndex].locked||(r+=n[e].colSpan);n[t].colSpan+=l,n[o].colSpan+=r;const f=n.slice(0,t).filter(e=>i[e.columnIndex].locked),h=n.slice(o+1).filter(e=>i[e.columnIndex].locked);return[...f,...n.slice(t,o+1),...h]}exports.getVirtualCellsToRender=p;exports.getVirtualHeaderCellsToRender=m;