@progress/kendo-react-grid 15.0.1-develop.1 → 15.0.1-develop.10

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.
@@ -6,4 +6,4 @@
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
8
  "use client";
9
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const b=require("react"),P=require("../drag/GroupingIndicator.js"),C=require("@progress/kendo-react-intl"),c=require("../messages/index.js"),G=require("../utils/GridContext.js");function v(t){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const a in t)if(a!=="default"){const s=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(n,a,s.get?s:{enumerable:!0,get:()=>t[a]})}}return n.default=t,Object.freeze(n)}const l=v(b),R=t=>{const n=l.useContext(G.GridContext),a=(o,e)=>{const r=t.group.slice();r.splice(e,1),n.groupChange(r,o)},s=(o,e,r,i)=>{const f=Object.assign({},r,{dir:i}),d=t.group.slice();d.splice(e,1,f),n.groupChange(d,o)},u=C.useLocalization(),p=t.group||[],m=o=>{const e=t.columns.find(i=>i.field===o),r=e&&(e.title||e.field);return r===void 0?o:r},g=p.map((o,e)=>l.createElement(P.GroupingIndicator,{key:e,index:e,dir:o.dir||"asc",title:m(o.field),onRemove:r=>{a(r,e)},onSortChange:(r,i)=>{s(r,e,o,i)},onPress:n.dragLogicRef.current.pressHandler,onDrag:n.dragLogicRef.current.dragHandler,onRelease:n.dragLogicRef.current.releaseHandler,onContextMenu:n.onContextMenu}));return l.createElement("div",{ref:n.dragLogicRef.current.refGroupPanelDiv,className:"k-grouping-header",role:"toolbar","aria-label":u.toLanguageString(c.groupPanelAriaLabel,c.messages[c.groupPanelAriaLabel]),"aria-controls":t.ariaControls||""},l.createElement("div",{className:"k-chip-list",role:"none"},g),l.createElement("div",{className:"k-grouping-drop-container"},!g.length&&u.toLanguageString(c.groupPanelEmpty,c.messages[c.groupPanelEmpty])," "))};exports.GroupPanel=R;
9
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const b=require("react"),P=require("../drag/GroupingIndicator.js"),C=require("@progress/kendo-react-intl"),i=require("../messages/index.js"),G=require("../utils/GridContext.js");function v(t){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const a in t)if(a!=="default"){const s=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(n,a,s.get?s:{enumerable:!0,get:()=>t[a]})}}return n.default=t,Object.freeze(n)}const l=v(b),R=t=>{const n=l.useContext(G.GridContext),a=(o,e)=>{const r=t.group.slice();r.splice(e,1),n.groupChange(r,o)},s=(o,e,r,c)=>{const f=Object.assign({},r,{dir:c}),d=t.group.slice();d.splice(e,1,f),n.groupChange(d,o)},u=C.useLocalization(),p=t.group||[],m=o=>{const e=t.columns.find(c=>c.field===o&&c.isAccessible!==!1),r=e&&(e.title||e.field);return r===void 0?o:r},g=p.map((o,e)=>l.createElement(P.GroupingIndicator,{key:e,index:e,dir:o.dir||"asc",title:m(o.field),onRemove:r=>{a(r,e)},onSortChange:(r,c)=>{s(r,e,o,c)},onPress:n.dragLogicRef.current.pressHandler,onDrag:n.dragLogicRef.current.dragHandler,onRelease:n.dragLogicRef.current.releaseHandler,onContextMenu:n.onContextMenu}));return l.createElement("div",{ref:n.dragLogicRef.current.refGroupPanelDiv,className:"k-grouping-header",role:"toolbar","aria-label":u.toLanguageString(i.groupPanelAriaLabel,i.messages[i.groupPanelAriaLabel]),"aria-controls":t.ariaControls||""},l.createElement("div",{className:"k-chip-list",role:"none"},g),l.createElement("div",{className:"k-grouping-drop-container"},!g.length&&u.toLanguageString(i.groupPanelEmpty,i.messages[i.groupPanelEmpty])," "))};exports.GroupPanel=R;
@@ -11,17 +11,17 @@ import { GroupingIndicator as G } from "../drag/GroupingIndicator.mjs";
11
11
  import { useLocalization as L } from "@progress/kendo-react-intl";
12
12
  import { groupPanelAriaLabel as g, messages as u, groupPanelEmpty as m } from "../messages/index.mjs";
13
13
  import { GridContext as R } from "../utils/GridContext.mjs";
14
- const k = (t) => {
14
+ const k = (a) => {
15
15
  const n = i.useContext(R), p = (r, e) => {
16
- const o = t.group.slice();
16
+ const o = a.group.slice();
17
17
  o.splice(e, 1), n.groupChange(o, r);
18
- }, d = (r, e, o, a) => {
19
- const v = Object.assign({}, o, { dir: a }), s = t.group.slice();
20
- s.splice(e, 1, v), n.groupChange(s, r);
21
- }, l = L(), f = t.group || [], C = (r) => {
22
- const e = t.columns.find((a) => a.field === r), o = e && (e.title || e.field);
18
+ }, d = (r, e, o, t) => {
19
+ const v = Object.assign({}, o, { dir: t }), c = a.group.slice();
20
+ c.splice(e, 1, v), n.groupChange(c, r);
21
+ }, s = L(), f = a.group || [], C = (r) => {
22
+ const e = a.columns.find((t) => t.field === r && t.isAccessible !== !1), o = e && (e.title || e.field);
23
23
  return o === void 0 ? r : o;
24
- }, c = f.map((r, e) => /* @__PURE__ */ i.createElement(
24
+ }, l = f.map((r, e) => /* @__PURE__ */ i.createElement(
25
25
  G,
26
26
  {
27
27
  key: e,
@@ -31,8 +31,8 @@ const k = (t) => {
31
31
  onRemove: (o) => {
32
32
  p(o, e);
33
33
  },
34
- onSortChange: (o, a) => {
35
- d(o, e, r, a);
34
+ onSortChange: (o, t) => {
35
+ d(o, e, r, t);
36
36
  },
37
37
  onPress: n.dragLogicRef.current.pressHandler,
38
38
  onDrag: n.dragLogicRef.current.dragHandler,
@@ -46,11 +46,11 @@ const k = (t) => {
46
46
  ref: n.dragLogicRef.current.refGroupPanelDiv,
47
47
  className: "k-grouping-header",
48
48
  role: "toolbar",
49
- "aria-label": l.toLanguageString(g, u[g]),
50
- "aria-controls": t.ariaControls || ""
49
+ "aria-label": s.toLanguageString(g, u[g]),
50
+ "aria-controls": a.ariaControls || ""
51
51
  },
52
- /* @__PURE__ */ i.createElement("div", { className: "k-chip-list", role: "none" }, c),
53
- /* @__PURE__ */ i.createElement("div", { className: "k-grouping-drop-container" }, !c.length && l.toLanguageString(m, u[m]), " ")
52
+ /* @__PURE__ */ i.createElement("div", { className: "k-chip-list", role: "none" }, l),
53
+ /* @__PURE__ */ i.createElement("div", { className: "k-grouping-drop-container" }, !l.length && s.toLanguageString(m, u[m]), " ")
54
54
  );
55
55
  };
56
56
  export {
@@ -49,4 +49,8 @@ export interface GridColumnState {
49
49
  * Sets the maximum width of the column (in pixels).
50
50
  */
51
51
  maxWidth?: number;
52
+ /**
53
+ * @hidden
54
+ */
55
+ isAccessible?: boolean;
52
56
  }
@@ -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: 1779805552,version:"15.0.1-develop.1",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: 1780565101,version:"15.0.1-develop.10",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: 1779805552,
11
- version: '15.0.1-develop.1',
10
+ publishDate: 1780565101,
11
+ version: '15.0.1-develop.10',
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": "15.0.1-develop.1",
3
+ "version": "15.0.1-develop.10",
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.21.2",
31
31
  "@progress/kendo-file-saver": "^1.1.1",
32
32
  "@progress/kendo-licensing": "^1.7.2",
33
- "@progress/kendo-react-animation": "15.0.1-develop.1",
34
- "@progress/kendo-react-buttons": "15.0.1-develop.1",
35
- "@progress/kendo-react-common": "15.0.1-develop.1",
36
- "@progress/kendo-react-data-tools": "15.0.1-develop.1",
37
- "@progress/kendo-react-dateinputs": "15.0.1-develop.1",
38
- "@progress/kendo-react-indicators": "15.0.1-develop.1",
39
- "@progress/kendo-react-form": "15.0.1-develop.1",
40
- "@progress/kendo-react-labels": "15.0.1-develop.1",
41
- "@progress/kendo-react-dialogs": "15.0.1-develop.1",
42
- "@progress/kendo-react-dropdowns": "15.0.1-develop.1",
43
- "@progress/kendo-react-inputs": "15.0.1-develop.1",
44
- "@progress/kendo-react-intl": "15.0.1-develop.1",
45
- "@progress/kendo-react-popup": "15.0.1-develop.1",
46
- "@progress/kendo-react-layout": "15.0.1-develop.1",
47
- "@progress/kendo-react-conversational-ui": "15.0.1-develop.1",
33
+ "@progress/kendo-react-animation": "15.0.1-develop.10",
34
+ "@progress/kendo-react-buttons": "15.0.1-develop.10",
35
+ "@progress/kendo-react-common": "15.0.1-develop.10",
36
+ "@progress/kendo-react-data-tools": "15.0.1-develop.10",
37
+ "@progress/kendo-react-dateinputs": "15.0.1-develop.10",
38
+ "@progress/kendo-react-indicators": "15.0.1-develop.10",
39
+ "@progress/kendo-react-form": "15.0.1-develop.10",
40
+ "@progress/kendo-react-labels": "15.0.1-develop.10",
41
+ "@progress/kendo-react-dialogs": "15.0.1-develop.10",
42
+ "@progress/kendo-react-dropdowns": "15.0.1-develop.10",
43
+ "@progress/kendo-react-inputs": "15.0.1-develop.10",
44
+ "@progress/kendo-react-intl": "15.0.1-develop.10",
45
+ "@progress/kendo-react-popup": "15.0.1-develop.10",
46
+ "@progress/kendo-react-layout": "15.0.1-develop.10",
47
+ "@progress/kendo-react-conversational-ui": "15.0.1-develop.10",
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"
@@ -148,7 +148,7 @@
148
148
  "package": {
149
149
  "productName": "KendoReact",
150
150
  "productCode": "KENDOUIREACT",
151
- "publishDate": 1779805552,
151
+ "publishDate": 1780565101,
152
152
  "licensingDocsUrl": "https://www.telerik.com/kendo-react-ui/components/my-license/"
153
153
  }
154
154
  },
@@ -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 B=require("react"),L=require("../cells/groupcell/GridGroupCellToggle.js"),V=require("../rows/GridRow.js"),z=require("./GridStackedRow.js");function H(e){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const s in e)if(s!=="default"){const u=Object.getOwnPropertyDescriptor(e,s);Object.defineProperty(c,s,u.get?u:{enumerable:!0,get:()=>e[s]})}}return c.default=e,Object.freeze(c)}const t=H(B),U=({item:e,rowId:c,dataIndex:s,idPrefix:u,ariaRowIndex:f,absoluteRowIndex:y,isAltRow:k,isHidden:h,isRowReorderable:j,rowHeight:O,rows:R,leafColumns:p,groupLevelCount:b,stackedLayoutSettings:w,cells:F,editMode:x,isSelected:S,isHighlighted:D,isInEdit:v,preparedCells:M,showDetailToggle:_,isDetailExpanded:q,detailExpandField:A,isPinned:I})=>{var C,G,$;if(e.rowType==="data")return t.createElement(z.GridStackedRow,{key:c,dataItem:e.dataItem,columns:p,stackedLayoutSettings:w,isAltRow:k,isSelected:S,isInEdit:v,cells:F,dataIndex:s,idPrefix:u,ariaRowIndex:f,absoluteRowIndex:y,groupLevel:b,preparedCells:M,editMode:x,showDetailToggle:_,isDetailExpanded:q,detailExpandField:A,isPinned:I});const P=b+1,E=e.level||0,T=Math.max(1,P-E),N=Array.from({length:E},(d,r)=>t.createElement("td",{key:`group-cell-${c}-${r}`,className:"k-table-group-td k-group-cell k-table-td"}));let m;if(e.rowType==="groupHeader"){const d=(C=e.dataItem)==null?void 0:C.field,r=(G=e.dataItem)==null?void 0:G.value,g=d!==void 0?(()=>{const l=String(d),n=p.find(o=>o.field===l),i=n==null?void 0:n.title;return typeof i=="string"&&i.length?i:l})():void 0;let a="";if(d!==void 0){let l;r instanceof Date?l=r.toString():l=String(r),a=`${g}: ${l}`}else r instanceof Date?a=r.toString():r!==void 0&&(a=String(r));m=t.createElement(t.Fragment,null,N,t.createElement("td",{className:"k-table-td",colSpan:T,role:"gridcell","aria-expanded":e.expanded},t.createElement("p",{className:"k-reset"},t.createElement(L.GridGroupCellToggle,{id:"",dataItem:e.dataItem,dataIndex:e.dataIndex,field:"value",expanded:e.expanded,group:e.group,columnPosition:{},ariaColumnIndex:1,isSelected:!1}),t.createElement("span",{className:"k-value"},a))))}else{const d=p.filter(a=>{const l=!!a._type,n=a.isAccessible===!1;return!a.hidden&&!l&&!n&&(a.columnType==="data"||a.columnType===void 0)}),r=($=e.dataItem)==null?void 0:$.aggregates,g=d.map(a=>{const l=a.field;if(!l||!r)return null;const n=r[l];if(!n||typeof n!="object")return null;const i=Object.keys(n).filter(o=>n[o]!==void 0&&n[o]!==null).map(o=>`${o.length?`${o.charAt(0).toUpperCase()}${o.slice(1)}`:o}: ${String(n[o])}`);return i.length===0?null:t.createElement("div",{key:`agg-${c}-${l}`,className:"k-grid-template-column"},t.createElement("p",{className:"k-grid-template-column-header"},a.title||l),t.createElement("p",{className:"k-reset"},i.join(", ")))}).filter(Boolean);if(e.rowType==="groupFooter"&&g.length===0)return t.createElement(t.Fragment,{key:c});m=t.createElement(t.Fragment,null,N,t.createElement("td",{className:"k-table-td",colSpan:T},t.createElement("div",{className:"k-grid-column-template"},g)))}return t.createElement(V.GridRow,{key:c,dataItem:e.dataItem,isAltRow:k,isInEdit:v,rowType:e.rowType,isRowReorderable:j,isHidden:h,onClick:null,onDoubleClick:null,rowHeight:O,ariaRowIndex:f,absoluteRowIndex:y,dataIndex:s,isSelected:S,isHighlighted:D,rows:R},m)};exports.StackedModeRow=U;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const B=require("react"),L=require("../cells/groupcell/GridGroupCellToggle.js"),V=require("../rows/GridRow.js"),z=require("./GridStackedRow.js");function H(e){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const s in e)if(s!=="default"){const u=Object.getOwnPropertyDescriptor(e,s);Object.defineProperty(c,s,u.get?u:{enumerable:!0,get:()=>e[s]})}}return c.default=e,Object.freeze(c)}const t=H(B),U=({item:e,rowId:c,dataIndex:s,idPrefix:u,ariaRowIndex:f,absoluteRowIndex:y,isAltRow:k,isHidden:h,isRowReorderable:j,rowHeight:O,rows:R,leafColumns:p,groupLevelCount:b,stackedLayoutSettings:w,cells:F,editMode:x,isSelected:S,isHighlighted:A,isInEdit:v,preparedCells:D,showDetailToggle:M,isDetailExpanded:_,detailExpandField:q,isPinned:I})=>{var C,G,$;if(e.rowType==="data")return t.createElement(z.GridStackedRow,{key:c,dataItem:e.dataItem,columns:p,stackedLayoutSettings:w,isAltRow:k,isSelected:S,isInEdit:v,cells:F,dataIndex:s,idPrefix:u,ariaRowIndex:f,absoluteRowIndex:y,groupLevel:b,preparedCells:D,editMode:x,showDetailToggle:M,isDetailExpanded:_,detailExpandField:q,isPinned:I});const P=b+1,E=e.level||0,T=Math.max(1,P-E),N=Array.from({length:E},(d,r)=>t.createElement("td",{key:`group-cell-${c}-${r}`,className:"k-table-group-td k-group-cell k-table-td"}));let m;if(e.rowType==="groupHeader"){const d=(C=e.dataItem)==null?void 0:C.field,r=(G=e.dataItem)==null?void 0:G.value,g=d!==void 0?(()=>{const l=String(d),n=p.find(o=>o.field===l&&o.isAccessible!==!1),i=n==null?void 0:n.title;return typeof i=="string"&&i.length?i:l})():void 0;let a="";if(d!==void 0){let l;r instanceof Date?l=r.toString():l=String(r),a=`${g}: ${l}`}else r instanceof Date?a=r.toString():r!==void 0&&(a=String(r));m=t.createElement(t.Fragment,null,N,t.createElement("td",{className:"k-table-td",colSpan:T,role:"gridcell","aria-expanded":e.expanded},t.createElement("p",{className:"k-reset"},t.createElement(L.GridGroupCellToggle,{id:"",dataItem:e.dataItem,dataIndex:e.dataIndex,field:"value",expanded:e.expanded,group:e.group,columnPosition:{},ariaColumnIndex:1,isSelected:!1}),t.createElement("span",{className:"k-value"},a))))}else{const d=p.filter(a=>{const l=!!a._type,n=a.isAccessible===!1;return!a.hidden&&!l&&!n&&(a.columnType==="data"||a.columnType===void 0)}),r=($=e.dataItem)==null?void 0:$.aggregates,g=d.map(a=>{const l=a.field;if(!l||!r)return null;const n=r[l];if(!n||typeof n!="object")return null;const i=Object.keys(n).filter(o=>n[o]!==void 0&&n[o]!==null).map(o=>`${o.length?`${o.charAt(0).toUpperCase()}${o.slice(1)}`:o}: ${String(n[o])}`);return i.length===0?null:t.createElement("div",{key:`agg-${c}-${l}`,className:"k-grid-template-column"},t.createElement("p",{className:"k-grid-template-column-header"},a.title||l),t.createElement("p",{className:"k-reset"},i.join(", ")))}).filter(Boolean);if(e.rowType==="groupFooter"&&g.length===0)return t.createElement(t.Fragment,{key:c});m=t.createElement(t.Fragment,null,N,t.createElement("td",{className:"k-table-td",colSpan:T},t.createElement("div",{className:"k-grid-column-template"},g)))}return t.createElement(V.GridRow,{key:c,dataItem:e.dataItem,isAltRow:k,isInEdit:v,rowType:e.rowType,isRowReorderable:j,isHidden:h,onClick:null,onDoubleClick:null,rowHeight:O,ariaRowIndex:f,absoluteRowIndex:y,dataIndex:s,isSelected:S,isHighlighted:A,rows:R},m)};exports.StackedModeRow=U;
@@ -61,15 +61,15 @@ const K = ({
61
61
  isPinned: V
62
62
  }
63
63
  );
64
- const _ = y + 1, S = t.level || 0, b = Math.max(1, _ - S), N = Array.from({ length: S }, (c, r) => /* @__PURE__ */ e.createElement("td", { key: `group-cell-${d}-${r}`, className: "k-table-group-td k-group-cell k-table-td" }));
64
+ const _ = y + 1, S = t.level || 0, b = Math.max(1, _ - S), N = Array.from({ length: S }, (s, r) => /* @__PURE__ */ e.createElement("td", { key: `group-cell-${d}-${r}`, className: "k-table-group-td k-group-cell k-table-td" }));
65
65
  let g;
66
66
  if (t.rowType === "groupHeader") {
67
- const c = (T = t.dataItem) == null ? void 0 : T.field, r = ($ = t.dataItem) == null ? void 0 : $.value, i = c !== void 0 ? (() => {
68
- const l = String(c), n = p.find((o) => o.field === l), s = n == null ? void 0 : n.title;
69
- return typeof s == "string" && s.length ? s : l;
67
+ const s = (T = t.dataItem) == null ? void 0 : T.field, r = ($ = t.dataItem) == null ? void 0 : $.value, i = s !== void 0 ? (() => {
68
+ const l = String(s), n = p.find((o) => o.field === l && o.isAccessible !== !1), c = n == null ? void 0 : n.title;
69
+ return typeof c == "string" && c.length ? c : l;
70
70
  })() : void 0;
71
71
  let a = "";
72
- if (c !== void 0) {
72
+ if (s !== void 0) {
73
73
  let l;
74
74
  r instanceof Date ? l = r.toString() : l = String(r), a = `${i}: ${l}`;
75
75
  } else r instanceof Date ? a = r.toString() : r !== void 0 && (a = String(r));
@@ -88,18 +88,18 @@ const K = ({
88
88
  }
89
89
  ), /* @__PURE__ */ e.createElement("span", { className: "k-value" }, a))));
90
90
  } else {
91
- const c = p.filter((a) => {
91
+ const s = p.filter((a) => {
92
92
  const l = !!a._type, n = a.isAccessible === !1;
93
93
  return !a.hidden && !l && !n && (a.columnType === "data" || a.columnType === void 0);
94
- }), r = (C = t.dataItem) == null ? void 0 : C.aggregates, i = c.map((a) => {
94
+ }), r = (C = t.dataItem) == null ? void 0 : C.aggregates, i = s.map((a) => {
95
95
  const l = a.field;
96
96
  if (!l || !r)
97
97
  return null;
98
98
  const n = r[l];
99
99
  if (!n || typeof n != "object")
100
100
  return null;
101
- const s = Object.keys(n).filter((o) => n[o] !== void 0 && n[o] !== null).map((o) => `${o.length ? `${o.charAt(0).toUpperCase()}${o.slice(1)}` : o}: ${String(n[o])}`);
102
- return s.length === 0 ? null : /* @__PURE__ */ e.createElement("div", { key: `agg-${d}-${l}`, className: "k-grid-template-column" }, /* @__PURE__ */ e.createElement("p", { className: "k-grid-template-column-header" }, a.title || l), /* @__PURE__ */ e.createElement("p", { className: "k-reset" }, s.join(", ")));
101
+ const c = Object.keys(n).filter((o) => n[o] !== void 0 && n[o] !== null).map((o) => `${o.length ? `${o.charAt(0).toUpperCase()}${o.slice(1)}` : o}: ${String(n[o])}`);
102
+ return c.length === 0 ? null : /* @__PURE__ */ e.createElement("div", { key: `agg-${d}-${l}`, className: "k-grid-template-column" }, /* @__PURE__ */ e.createElement("p", { className: "k-grid-template-column-header" }, a.title || l), /* @__PURE__ */ e.createElement("p", { className: "k-reset" }, c.join(", ")));
103
103
  }).filter(Boolean);
104
104
  if (t.rowType === "groupFooter" && i.length === 0)
105
105
  return /* @__PURE__ */ e.createElement(e.Fragment, { key: d });
@@ -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 te=require("react"),oe=require("react-dom"),y=require("@progress/kendo-react-buttons"),h=require("@progress/kendo-react-common"),k=require("@progress/kendo-react-inputs"),F=require("@progress/kendo-svg-icons"),ne=require("../columnMenu/GridColumnMenuItemContent.js"),n=require("../messages/index.js"),le=require("../utils/GridContext.js"),re=require("@progress/kendo-react-intl"),se=require("./adaptiveContent/GridAdaptiveToolbarColumnChooser.js"),ce=require("@progress/kendo-react-popup"),K=require("@progress/kendo-react-indicators"),ae=require("./adaptiveContext/GridToolbarAdaptiveContext.js");function ue(l){const s=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(l){for(const r in l)if(r!=="default"){const u=Object.getOwnPropertyDescriptor(l,r);Object.defineProperty(s,r,u.get?u:{enumerable:!0,get:()=>l[r]})}}return s.default=l,Object.freeze(s)}const t=ue(te),_=l=>{var L,P;const s=t.useContext(le.GridContext),r=s.columnsState,u=s.onColumnsStateChange,[S,f]=t.useState(!1),[d,V]=t.useState(""),[H,b]=t.useState(!1),B=r.reduce((e,o)=>({...e,[o.id||""]:!o.hidden}),{}),[c,p]=t.useState(B),i=t.useRef(null),v=t.useRef(null),R=t.useRef(null),M=t.useRef(0),m=re.useLocalization(),W=h.useDocument(i),A=t.useMemo(()=>(r==null?void 0:r.filter(e=>{var o;return(o=e.title||e.field)==null?void 0:o.toLowerCase().includes(d.toLowerCase())}))||[],[r,d]),g=t.useMemo(()=>Object.values(c).filter(e=>e).length,[c]),C=t.useMemo(()=>g===(r==null?void 0:r.length),[r,g]),I=t.useCallback(e=>{var z;e.preventDefault();const a=(w=>(w==null?void 0:w.map(j=>({...j,hidden:!c[j.id||""]})))||[])(r);u&&u(a),(z=l.onCloseMenu)==null||z.call(void 0),f(!1),b(!1)},[r,u,l.onCloseMenu,c]),T=e=>{e.preventDefault(),p(B),b(!1)},q=t.useCallback(()=>{const e={...c};Object.keys(e).forEach((o,a)=>e[o]=C&&a===0?!0:!C),p(e),b(!0)},[c,C]),D=t.useCallback((e,o)=>{const a={...c};a[o||""]=e,p(a),b(!0)},[c]),x=e=>{V(String(e.target.value))},J=e=>{e.preventDefault(),f(!S)},E=t.useMemo(()=>l.show!==void 0?l.show:S,[l.show,S]),N=()=>{var e;l.onCloseMenu&&l.onCloseMenu(),f(!1),i.current&&((e=i.current.element)==null||e.focus())},Q=e=>{const o=h.getActiveElement(document);clearTimeout(M.current),M.current=window.setTimeout(()=>{!s.mobileMode&&o&&e.relatedTarget!==i.current&&v.current&&!v.current.contains(o)&&N()})},U=()=>{clearTimeout(M.current)},{onFocus:X,onBlur:Y}=h.useAsyncFocusBlur({onFocus:e=>U(),onBlur:e=>Q(e)}),Z=e=>{var o;(o=R.current)==null||o.triggerMouseEvent(e)},$=e=>{var o;(o=R.current)==null||o.triggerKeyboardEvent(e)},ee=e=>{!e.isAnchorClicked&&f(!1)},G=t.createElement(ne.GridColumnMenuItemContent,{show:!0},t.createElement("form",{onSubmit:I,onReset:T,className:"k-filter-menu"},t.createElement("div",{className:"k-filter-menu-container"},t.createElement(k.TextBox,{className:"k-searchbox",value:d,onChange:x,size:s.mobileMode?"large":"medium",prefix:()=>t.createElement(k.InputPrefix,null,t.createElement(h.IconWrap,{name:"search",icon:F.searchIcon}))}),t.createElement("ul",{className:"k-reset k-multicheck-wrap"},!d&&t.createElement("li",{className:"k-item k-check-all-wrap"},t.createElement(k.Checkbox,{checked:C,onChange:q,label:m.toLanguageString(n.filterSelectAll,n.messages[n.filterSelectAll]),size:s.mobileMode?"large":"medium"})),A.map(e=>t.createElement("li",{key:e.id,className:"k-item"},t.createElement(k.Checkbox,{disabled:c[e.id||""]&&g===1,checked:c[e.id||""],onChange:o=>{var a;return D(!!((a=o.target.element)!=null&&a.checked),e.id)},label:e.title||e.field,size:s.mobileMode?"large":"medium"})))),t.createElement("div",{className:"k-filter-selected-items"},g," ",m.toLanguageString(n.columnMenuColumnChooserSelectedItems,n.messages[n.columnMenuColumnChooserSelectedItems])),t.createElement("div",{className:"k-actions k-actions-start k-actions-horizontal"},t.createElement(y.Button,{type:"submit",themeColor:"primary"},m.toLanguageString(n.filterApplyButton,n.messages[n.filterApplyButton])),t.createElement(y.Button,{type:"reset"},m.toLanguageString(n.filterResetButton,n.messages[n.filterResetButton])))))),O=t.createElement(y.Button,{ref:i,togglable:!0,selected:E,svgIcon:l.svgIcon?l.svgIcon:l.icon?void 0:F.columnsIcon,icon:l.icon,size:s.mobileMode?"large":"medium",className:h.classNames("k-toolbar-button",{"k-icon-button":s.mobileMode}),title:m.toLanguageString(n.toolbarColumnsChooser,n.messages[n.toolbarColumnsChooser]),onClick:J},!s.mobileMode&&m.toLanguageString(n.toolbarColumnsChooser,n.messages[n.toolbarColumnsChooser]));return t.createElement(t.Fragment,null,H?t.createElement(K.BadgeContainer,null,O,t.createElement(K.Badge,{themeColor:"primary"})):O,s.mobileMode?t.createElement(ae.GridToolbarAdaptiveProvider,null,oe.createPortal(t.createElement(se.GridAdaptiveToolbarColumnChooser,{computedShow:E,filter:d,filtered:A,selectedColumns:c,allSelected:C,checkedCount:g,onClose:N,onApply:I,onReset:T,onFilter:x,onCheckChange:D,onSelectAll:q},G),(L=W())==null?void 0:L.body)):t.createElement(ce.Popup,{anchor:(P=i.current)==null?void 0:P.element,show:E,popupClass:"k-grid-columnmenu-popup",onMouseDownOutside:ee},t.createElement("div",{ref:v,onBlur:Y,onFocus:X,onMouseDown:Z,onKeyDown:$,className:"k-column-menu k-column-menu-md"},G)))};_.displayName="KendoReactGridToolbarColumnsChooser";exports.GridToolbarColumnsChooser=_;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const le=require("react"),re=require("react-dom"),T=require("@progress/kendo-react-buttons"),f=require("@progress/kendo-react-common"),E=require("@progress/kendo-react-inputs"),_=require("@progress/kendo-svg-icons"),se=require("../columnMenu/GridColumnMenuItemContent.js"),l=require("../messages/index.js"),ce=require("../utils/GridContext.js"),ae=require("@progress/kendo-react-intl"),ue=require("./adaptiveContent/GridAdaptiveToolbarColumnChooser.js"),ie=require("@progress/kendo-react-popup"),H=require("@progress/kendo-react-indicators"),me=require("./adaptiveContext/GridToolbarAdaptiveContext.js");function de(r){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const n in r)if(n!=="default"){const s=Object.getOwnPropertyDescriptor(r,n);Object.defineProperty(c,n,s.get?s:{enumerable:!0,get:()=>r[n]})}}return c.default=r,Object.freeze(c)}const e=de(le),V=r=>{const c={};for(const n of r)c[n.id||""]=!n.hidden;return c},$=r=>{var F,K;const{onCloseMenu:c}=r,n=e.useContext(ce.GridContext),s=n.columnsState,M=n.onColumnsStateChange,b=s||[],[y,k]=e.useState(!1),[d,W]=e.useState(""),[w,p]=e.useState(!1),[a,S]=e.useState(()=>V(b)),J=e.useMemo(()=>b.map(t=>`${t.id}:${!!t.hidden}`).join(","),[b]),B=e.useMemo(()=>V(b),[J]);e.useEffect(()=>{w||S(B)},[w,B]);const i=e.useRef(null),R=e.useRef(null),q=e.useRef(null),A=e.useRef(0),m=ae.useLocalization(),Q=f.useDocument(i),x=e.useMemo(()=>(s==null?void 0:s.filter(t=>{var o;return(o=t.title||t.field)==null?void 0:o.toLowerCase().includes(d.toLowerCase())}))||[],[s,d]),g=e.useMemo(()=>Object.values(a).filter(t=>t).length,[a]),C=e.useMemo(()=>g===(s==null?void 0:s.length),[s,g]),D=e.useCallback(t=>{t.preventDefault();const u=(h=>(h==null?void 0:h.map(v=>({...v,hidden:!a[v.id||""]})))||[])(s);M&&M(u),c==null||c(),k(!1),p(!1)},[s,M,c,a]),N=t=>{t.preventDefault(),S(B),p(!1)},G=e.useCallback(()=>{S(t=>{const o={...t};return Object.keys(o).forEach((h,v)=>o[h]=C&&v===0?!0:!C),o}),p(!0)},[C]),O=e.useCallback((t,o)=>{S(u=>({...u,[o||""]:t})),p(!0)},[]),L=t=>{W(String(t.target.value))},U=t=>{t.preventDefault(),k(!y)},I=e.useMemo(()=>r.show!==void 0?r.show:y,[r.show,y]),P=()=>{var t;c&&c(),k(!1),i.current&&((t=i.current.element)==null||t.focus())},X=t=>{const o=f.getActiveElement(document);clearTimeout(A.current),A.current=window.setTimeout(()=>{!n.mobileMode&&o&&t.relatedTarget!==i.current&&R.current&&!R.current.contains(o)&&P()})},Y=()=>{clearTimeout(A.current)},{onFocus:Z,onBlur:ee}=f.useAsyncFocusBlur({onFocus:t=>Y(),onBlur:t=>X(t)}),te=t=>{var o;(o=q.current)==null||o.triggerMouseEvent(t)},oe=t=>{var o;(o=q.current)==null||o.triggerKeyboardEvent(t)},ne=t=>{!t.isAnchorClicked&&k(!1)},j=e.createElement(se.GridColumnMenuItemContent,{show:!0},e.createElement("form",{onSubmit:D,onReset:N,className:"k-filter-menu"},e.createElement("div",{className:"k-filter-menu-container"},e.createElement(E.TextBox,{className:"k-searchbox",value:d,onChange:L,size:n.mobileMode?"large":"medium",prefix:()=>e.createElement(E.InputPrefix,null,e.createElement(f.IconWrap,{name:"search",icon:_.searchIcon}))}),e.createElement("ul",{className:"k-reset k-multicheck-wrap"},!d&&e.createElement("li",{className:"k-item k-check-all-wrap"},e.createElement(E.Checkbox,{checked:C,onChange:G,label:m.toLanguageString(l.filterSelectAll,l.messages[l.filterSelectAll]),size:n.mobileMode?"large":"medium"})),x.map(t=>e.createElement("li",{key:t.id,className:"k-item"},e.createElement(E.Checkbox,{disabled:a[t.id||""]&&g===1,checked:a[t.id||""],onChange:o=>{var u;return O(!!((u=o.target.element)!=null&&u.checked),t.id)},label:t.title||t.field,size:n.mobileMode?"large":"medium"})))),e.createElement("div",{className:"k-filter-selected-items"},g," ",m.toLanguageString(l.columnMenuColumnChooserSelectedItems,l.messages[l.columnMenuColumnChooserSelectedItems])),e.createElement("div",{className:"k-actions k-actions-start k-actions-horizontal"},e.createElement(T.Button,{type:"submit",themeColor:"primary"},m.toLanguageString(l.filterApplyButton,l.messages[l.filterApplyButton])),e.createElement(T.Button,{type:"reset"},m.toLanguageString(l.filterResetButton,l.messages[l.filterResetButton])))))),z=e.createElement(T.Button,{ref:i,togglable:!0,selected:I,svgIcon:r.svgIcon?r.svgIcon:r.icon?void 0:_.columnsIcon,icon:r.icon,size:n.mobileMode?"large":"medium",className:f.classNames("k-toolbar-button",{"k-icon-button":n.mobileMode}),title:m.toLanguageString(l.toolbarColumnsChooser,l.messages[l.toolbarColumnsChooser]),onClick:U},!n.mobileMode&&m.toLanguageString(l.toolbarColumnsChooser,l.messages[l.toolbarColumnsChooser]));return e.createElement(e.Fragment,null,w?e.createElement(H.BadgeContainer,null,z,e.createElement(H.Badge,{themeColor:"primary"})):z,n.mobileMode?e.createElement(me.GridToolbarAdaptiveProvider,null,re.createPortal(e.createElement(ue.GridAdaptiveToolbarColumnChooser,{computedShow:I,filter:d,filtered:x,selectedColumns:a,allSelected:C,checkedCount:g,onClose:P,onApply:D,onReset:N,onFilter:L,onCheckChange:O,onSelectAll:G},j),(F=Q())==null?void 0:F.body)):e.createElement(ie.Popup,{anchor:(K=i.current)==null?void 0:K.element,show:I,popupClass:"k-grid-columnmenu-popup",onMouseDownOutside:ne},e.createElement("div",{ref:R,onBlur:ee,onFocus:Z,onMouseDown:te,onKeyDown:oe,className:"k-column-menu k-column-menu-md"},j)))};$.displayName="KendoReactGridToolbarColumnsChooser";exports.GridToolbarColumnsChooser=$;
@@ -5,174 +5,185 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import * as t from "react";
9
- import oe from "react-dom";
10
- import { Button as w } from "@progress/kendo-react-buttons";
11
- import { useDocument as ne, useAsyncFocusBlur as le, IconWrap as re, classNames as ae, getActiveElement as ce } from "@progress/kendo-react-common";
12
- import { TextBox as se, InputPrefix as ie, Checkbox as K } from "@progress/kendo-react-inputs";
13
- import { searchIcon as ue, columnsIcon as me } from "@progress/kendo-svg-icons";
14
- import { GridColumnMenuItemContent as de } from "../columnMenu/GridColumnMenuItemContent.mjs";
15
- import { filterSelectAll as j, messages as u, columnMenuColumnChooserSelectedItems as V, filterApplyButton as H, filterResetButton as W, toolbarColumnsChooser as C } from "../messages/index.mjs";
16
- import { GridContext as ge } from "../utils/GridContext.mjs";
17
- import { useLocalization as fe } from "@progress/kendo-react-intl";
18
- import { GridAdaptiveToolbarColumnChooser as he } from "./adaptiveContent/GridAdaptiveToolbarColumnChooser.mjs";
19
- import { Popup as Ce } from "@progress/kendo-react-popup";
20
- import { BadgeContainer as be, Badge as ke } from "@progress/kendo-react-indicators";
21
- import { GridToolbarAdaptiveProvider as pe } from "./adaptiveContext/GridToolbarAdaptiveContext.mjs";
22
- const Ee = (n) => {
23
- var F, G;
24
- const a = t.useContext(ge), l = a.columnsState, b = a.onColumnsStateChange, [k, f] = t.useState(!1), [m, _] = t.useState(""), [q, h] = t.useState(!1), y = l.reduce((e, o) => ({ ...e, [o.id || ""]: !o.hidden }), {}), [r, p] = t.useState(y), s = t.useRef(null), E = t.useRef(null), B = t.useRef(null), M = t.useRef(0), i = fe(), J = ne(s), D = t.useMemo(
8
+ import * as e from "react";
9
+ import re from "react-dom";
10
+ import { Button as x } from "@progress/kendo-react-buttons";
11
+ import { useDocument as ae, useAsyncFocusBlur as se, IconWrap as ce, classNames as me, getActiveElement as ue } from "@progress/kendo-react-common";
12
+ import { TextBox as ie, InputPrefix as de, Checkbox as H } from "@progress/kendo-react-inputs";
13
+ import { searchIcon as fe, columnsIcon as ge } from "@progress/kendo-svg-icons";
14
+ import { GridColumnMenuItemContent as he } from "../columnMenu/GridColumnMenuItemContent.mjs";
15
+ import { filterSelectAll as V, messages as i, columnMenuColumnChooserSelectedItems as $, filterApplyButton as W, filterResetButton as _, toolbarColumnsChooser as v } from "../messages/index.mjs";
16
+ import { GridContext as Ce } from "../utils/GridContext.mjs";
17
+ import { useLocalization as pe } from "@progress/kendo-react-intl";
18
+ import { GridAdaptiveToolbarColumnChooser as ke } from "./adaptiveContent/GridAdaptiveToolbarColumnChooser.mjs";
19
+ import { Popup as be } from "@progress/kendo-react-popup";
20
+ import { BadgeContainer as Ee, Badge as ve } from "@progress/kendo-react-indicators";
21
+ import { GridToolbarAdaptiveProvider as Se } from "./adaptiveContext/GridToolbarAdaptiveContext.mjs";
22
+ const q = (r) => {
23
+ const a = {};
24
+ for (const n of r)
25
+ a[n.id || ""] = !n.hidden;
26
+ return a;
27
+ }, Me = (r) => {
28
+ var P, j;
29
+ const { onCloseMenu: a } = r, n = e.useContext(Ce), l = n.columnsState, S = n.onColumnsStateChange, C = l || [], [M, p] = e.useState(!1), [d, J] = e.useState(""), [w, k] = e.useState(!1), [s, b] = e.useState(() => q(C)), Q = e.useMemo(
30
+ () => C.map((t) => `${t.id}:${!!t.hidden}`).join(","),
31
+ [C]
32
+ ), y = e.useMemo(
33
+ () => q(C),
34
+ // eslint-disable-next-line react-hooks/exhaustive-deps
35
+ [Q]
36
+ );
37
+ e.useEffect(() => {
38
+ w || b(y);
39
+ }, [w, y]);
40
+ const m = e.useRef(null), B = e.useRef(null), A = e.useRef(null), D = e.useRef(0), u = pe(), U = ae(m), T = e.useMemo(
25
41
  () => (l == null ? void 0 : l.filter(
26
- (e) => {
42
+ (t) => {
27
43
  var o;
28
- return (o = e.title || e.field) == null ? void 0 : o.toLowerCase().includes(m.toLowerCase());
44
+ return (o = t.title || t.field) == null ? void 0 : o.toLowerCase().includes(d.toLowerCase());
29
45
  }
30
46
  )) || [],
31
- [l, m]
32
- ), d = t.useMemo(
33
- () => Object.values(r).filter((e) => e).length,
34
- [r]
35
- ), g = t.useMemo(() => d === (l == null ? void 0 : l.length), [l, d]), N = t.useCallback(
36
- (e) => {
37
- var O;
38
- e.preventDefault();
39
- const c = ((v) => (v == null ? void 0 : v.map((P) => ({
40
- ...P,
41
- hidden: !r[P.id || ""]
47
+ [l, d]
48
+ ), f = e.useMemo(
49
+ () => Object.values(s).filter((t) => t).length,
50
+ [s]
51
+ ), g = e.useMemo(() => f === (l == null ? void 0 : l.length), [l, f]), I = e.useCallback(
52
+ (t) => {
53
+ t.preventDefault();
54
+ const c = ((h) => (h == null ? void 0 : h.map((E) => ({
55
+ ...E,
56
+ hidden: !s[E.id || ""]
42
57
  }))) || [])(l);
43
- b && b(c), (O = n.onCloseMenu) == null || O.call(void 0), f(!1), h(!1);
44
- },
45
- [l, b, n.onCloseMenu, r]
46
- ), A = (e) => {
47
- e.preventDefault(), p(y), h(!1);
48
- }, x = t.useCallback(() => {
49
- const e = { ...r };
50
- Object.keys(e).forEach(
51
- (o, c) => e[o] = g && c === 0 ? !0 : !g
52
- ), p(e), h(!0);
53
- }, [r, g]), T = t.useCallback(
54
- (e, o) => {
55
- const c = { ...r };
56
- c[o || ""] = e, p(c), h(!0);
58
+ S && S(c), a == null || a(), p(!1), k(!1);
57
59
  },
58
- [r]
59
- ), I = (e) => {
60
- _(String(e.target.value));
61
- }, Q = (e) => {
62
- e.preventDefault(), f(!k);
63
- }, S = t.useMemo(() => n.show !== void 0 ? n.show : k, [n.show, k]), L = () => {
64
- var e;
65
- n.onCloseMenu && n.onCloseMenu(), f(!1), s.current && ((e = s.current.element) == null || e.focus());
66
- }, U = (e) => {
67
- const o = ce(document);
68
- clearTimeout(M.current), M.current = window.setTimeout(() => {
69
- !a.mobileMode && o && e.relatedTarget !== s.current && E.current && !E.current.contains(o) && L();
60
+ [l, S, a, s]
61
+ ), L = (t) => {
62
+ t.preventDefault(), b(y), k(!1);
63
+ }, R = e.useCallback(() => {
64
+ b((t) => {
65
+ const o = { ...t };
66
+ return Object.keys(o).forEach((h, E) => o[h] = g && E === 0 ? !0 : !g), o;
67
+ }), k(!0);
68
+ }, [g]), z = e.useCallback((t, o) => {
69
+ b((c) => ({ ...c, [o || ""]: t })), k(!0);
70
+ }, []), F = (t) => {
71
+ J(String(t.target.value));
72
+ }, X = (t) => {
73
+ t.preventDefault(), p(!M);
74
+ }, N = e.useMemo(() => r.show !== void 0 ? r.show : M, [r.show, M]), G = () => {
75
+ var t;
76
+ a && a(), p(!1), m.current && ((t = m.current.element) == null || t.focus());
77
+ }, Y = (t) => {
78
+ const o = ue(document);
79
+ clearTimeout(D.current), D.current = window.setTimeout(() => {
80
+ !n.mobileMode && o && t.relatedTarget !== m.current && B.current && !B.current.contains(o) && G();
70
81
  });
71
- }, X = () => {
72
- clearTimeout(M.current);
73
- }, { onFocus: Y, onBlur: Z } = le({
74
- onFocus: (e) => X(),
75
- onBlur: (e) => U(e)
76
- }), $ = (e) => {
82
+ }, Z = () => {
83
+ clearTimeout(D.current);
84
+ }, { onFocus: ee, onBlur: te } = se({
85
+ onFocus: (t) => Z(),
86
+ onBlur: (t) => Y(t)
87
+ }), oe = (t) => {
77
88
  var o;
78
- (o = B.current) == null || o.triggerMouseEvent(e);
79
- }, ee = (e) => {
89
+ (o = A.current) == null || o.triggerMouseEvent(t);
90
+ }, ne = (t) => {
80
91
  var o;
81
- (o = B.current) == null || o.triggerKeyboardEvent(e);
82
- }, te = (e) => {
83
- !e.isAnchorClicked && f(!1);
84
- }, R = /* @__PURE__ */ t.createElement(de, { show: !0 }, /* @__PURE__ */ t.createElement("form", { onSubmit: N, onReset: A, className: "k-filter-menu" }, /* @__PURE__ */ t.createElement("div", { className: "k-filter-menu-container" }, /* @__PURE__ */ t.createElement(
85
- se,
92
+ (o = A.current) == null || o.triggerKeyboardEvent(t);
93
+ }, le = (t) => {
94
+ !t.isAnchorClicked && p(!1);
95
+ }, K = /* @__PURE__ */ e.createElement(he, { show: !0 }, /* @__PURE__ */ e.createElement("form", { onSubmit: I, onReset: L, className: "k-filter-menu" }, /* @__PURE__ */ e.createElement("div", { className: "k-filter-menu-container" }, /* @__PURE__ */ e.createElement(
96
+ ie,
86
97
  {
87
98
  className: "k-searchbox",
88
- value: m,
89
- onChange: I,
90
- size: a.mobileMode ? "large" : "medium",
91
- prefix: () => /* @__PURE__ */ t.createElement(ie, null, /* @__PURE__ */ t.createElement(re, { name: "search", icon: ue }))
99
+ value: d,
100
+ onChange: F,
101
+ size: n.mobileMode ? "large" : "medium",
102
+ prefix: () => /* @__PURE__ */ e.createElement(de, null, /* @__PURE__ */ e.createElement(ce, { name: "search", icon: fe }))
92
103
  }
93
- ), /* @__PURE__ */ t.createElement("ul", { className: "k-reset k-multicheck-wrap" }, !m && /* @__PURE__ */ t.createElement("li", { className: "k-item k-check-all-wrap" }, /* @__PURE__ */ t.createElement(
94
- K,
104
+ ), /* @__PURE__ */ e.createElement("ul", { className: "k-reset k-multicheck-wrap" }, !d && /* @__PURE__ */ e.createElement("li", { className: "k-item k-check-all-wrap" }, /* @__PURE__ */ e.createElement(
105
+ H,
95
106
  {
96
107
  checked: g,
97
- onChange: x,
98
- label: i.toLanguageString(j, u[j]),
99
- size: a.mobileMode ? "large" : "medium"
108
+ onChange: R,
109
+ label: u.toLanguageString(V, i[V]),
110
+ size: n.mobileMode ? "large" : "medium"
100
111
  }
101
- )), D.map((e) => /* @__PURE__ */ t.createElement("li", { key: e.id, className: "k-item" }, /* @__PURE__ */ t.createElement(
102
- K,
112
+ )), T.map((t) => /* @__PURE__ */ e.createElement("li", { key: t.id, className: "k-item" }, /* @__PURE__ */ e.createElement(
113
+ H,
103
114
  {
104
- disabled: r[e.id || ""] && d === 1,
105
- checked: r[e.id || ""],
115
+ disabled: s[t.id || ""] && f === 1,
116
+ checked: s[t.id || ""],
106
117
  onChange: (o) => {
107
118
  var c;
108
- return T(!!((c = o.target.element) != null && c.checked), e.id);
119
+ return z(!!((c = o.target.element) != null && c.checked), t.id);
109
120
  },
110
- label: e.title || e.field,
111
- size: a.mobileMode ? "large" : "medium"
121
+ label: t.title || t.field,
122
+ size: n.mobileMode ? "large" : "medium"
112
123
  }
113
- )))), /* @__PURE__ */ t.createElement("div", { className: "k-filter-selected-items" }, d, " ", i.toLanguageString(
114
- V,
115
- u[V]
116
- )), /* @__PURE__ */ t.createElement("div", { className: "k-actions k-actions-start k-actions-horizontal" }, /* @__PURE__ */ t.createElement(w, { type: "submit", themeColor: "primary" }, i.toLanguageString(H, u[H])), /* @__PURE__ */ t.createElement(w, { type: "reset" }, i.toLanguageString(W, u[W])))))), z = /* @__PURE__ */ t.createElement(
117
- w,
124
+ )))), /* @__PURE__ */ e.createElement("div", { className: "k-filter-selected-items" }, f, " ", u.toLanguageString(
125
+ $,
126
+ i[$]
127
+ )), /* @__PURE__ */ e.createElement("div", { className: "k-actions k-actions-start k-actions-horizontal" }, /* @__PURE__ */ e.createElement(x, { type: "submit", themeColor: "primary" }, u.toLanguageString(W, i[W])), /* @__PURE__ */ e.createElement(x, { type: "reset" }, u.toLanguageString(_, i[_])))))), O = /* @__PURE__ */ e.createElement(
128
+ x,
118
129
  {
119
- ref: s,
130
+ ref: m,
120
131
  togglable: !0,
121
- selected: S,
122
- svgIcon: n.svgIcon ? n.svgIcon : n.icon ? void 0 : me,
123
- icon: n.icon,
124
- size: a.mobileMode ? "large" : "medium",
125
- className: ae("k-toolbar-button", {
126
- "k-icon-button": a.mobileMode
132
+ selected: N,
133
+ svgIcon: r.svgIcon ? r.svgIcon : r.icon ? void 0 : ge,
134
+ icon: r.icon,
135
+ size: n.mobileMode ? "large" : "medium",
136
+ className: me("k-toolbar-button", {
137
+ "k-icon-button": n.mobileMode
127
138
  }),
128
- title: i.toLanguageString(C, u[C]),
129
- onClick: Q
139
+ title: u.toLanguageString(v, i[v]),
140
+ onClick: X
130
141
  },
131
- !a.mobileMode && i.toLanguageString(C, u[C])
142
+ !n.mobileMode && u.toLanguageString(v, i[v])
132
143
  );
133
- return /* @__PURE__ */ t.createElement(t.Fragment, null, q ? /* @__PURE__ */ t.createElement(be, null, z, /* @__PURE__ */ t.createElement(ke, { themeColor: "primary" })) : z, a.mobileMode ? /* @__PURE__ */ t.createElement(pe, null, oe.createPortal(
134
- /* @__PURE__ */ t.createElement(
135
- he,
144
+ return /* @__PURE__ */ e.createElement(e.Fragment, null, w ? /* @__PURE__ */ e.createElement(Ee, null, O, /* @__PURE__ */ e.createElement(ve, { themeColor: "primary" })) : O, n.mobileMode ? /* @__PURE__ */ e.createElement(Se, null, re.createPortal(
145
+ /* @__PURE__ */ e.createElement(
146
+ ke,
136
147
  {
137
- computedShow: S,
138
- filter: m,
139
- filtered: D,
140
- selectedColumns: r,
148
+ computedShow: N,
149
+ filter: d,
150
+ filtered: T,
151
+ selectedColumns: s,
141
152
  allSelected: g,
142
- checkedCount: d,
143
- onClose: L,
144
- onApply: N,
145
- onReset: A,
146
- onFilter: I,
147
- onCheckChange: T,
148
- onSelectAll: x
153
+ checkedCount: f,
154
+ onClose: G,
155
+ onApply: I,
156
+ onReset: L,
157
+ onFilter: F,
158
+ onCheckChange: z,
159
+ onSelectAll: R
149
160
  },
150
- R
161
+ K
151
162
  ),
152
- (F = J()) == null ? void 0 : F.body
153
- )) : /* @__PURE__ */ t.createElement(
154
- Ce,
163
+ (P = U()) == null ? void 0 : P.body
164
+ )) : /* @__PURE__ */ e.createElement(
165
+ be,
155
166
  {
156
- anchor: (G = s.current) == null ? void 0 : G.element,
157
- show: S,
167
+ anchor: (j = m.current) == null ? void 0 : j.element,
168
+ show: N,
158
169
  popupClass: "k-grid-columnmenu-popup",
159
- onMouseDownOutside: te
170
+ onMouseDownOutside: le
160
171
  },
161
- /* @__PURE__ */ t.createElement(
172
+ /* @__PURE__ */ e.createElement(
162
173
  "div",
163
174
  {
164
- ref: E,
165
- onBlur: Z,
166
- onFocus: Y,
167
- onMouseDown: $,
168
- onKeyDown: ee,
175
+ ref: B,
176
+ onBlur: te,
177
+ onFocus: ee,
178
+ onMouseDown: oe,
179
+ onKeyDown: ne,
169
180
  className: "k-column-menu k-column-menu-md"
170
181
  },
171
- R
182
+ K
172
183
  )
173
184
  ));
174
185
  };
175
- Ee.displayName = "KendoReactGridToolbarColumnsChooser";
186
+ Me.displayName = "KendoReactGridToolbarColumnsChooser";
176
187
  export {
177
- Ee as GridToolbarColumnsChooser
188
+ Me as GridToolbarColumnsChooser
178
189
  };