@progress/kendo-react-layout 14.5.0-develop.14 → 14.5.0-develop.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (55) hide show
  1. package/actionsheet/ActionSheet.js +1 -1
  2. package/actionsheet/ActionSheet.mjs +18 -19
  3. package/actionsheet/ActionSheetItem.js +1 -1
  4. package/actionsheet/ActionSheetItem.mjs +1 -3
  5. package/bottomnavigation/BottomNavigation.js +1 -1
  6. package/bottomnavigation/BottomNavigation.mjs +85 -69
  7. package/bottomnavigation/BottomNavigationItem.js +1 -1
  8. package/bottomnavigation/BottomNavigationItem.mjs +34 -33
  9. package/bottomnavigation/messages/index.d.ts +17 -0
  10. package/bottomnavigation/messages/index.js +8 -0
  11. package/bottomnavigation/messages/index.mjs +14 -0
  12. package/breadcrumb/Breadcrumb.js +1 -1
  13. package/breadcrumb/Breadcrumb.mjs +30 -28
  14. package/breadcrumb/BreadcrumbLink.js +1 -1
  15. package/breadcrumb/BreadcrumbLink.mjs +26 -26
  16. package/breadcrumb/messages/index.d.ts +17 -0
  17. package/breadcrumb/messages/index.js +8 -0
  18. package/breadcrumb/messages/index.mjs +14 -0
  19. package/dist/cdn/js/kendo-react-layout.js +1 -1
  20. package/drawer/DrawerItem.js +1 -1
  21. package/drawer/DrawerItem.mjs +22 -23
  22. package/expansionpanel/ExpansionPanel.js +1 -1
  23. package/expansionpanel/ExpansionPanel.mjs +50 -50
  24. package/expansionpanel/ExpansionPanelContent.js +1 -1
  25. package/expansionpanel/ExpansionPanelContent.mjs +7 -4
  26. package/package-metadata.js +1 -1
  27. package/package-metadata.mjs +2 -2
  28. package/package.json +8 -8
  29. package/panelbar/PanelBar.js +1 -1
  30. package/panelbar/PanelBar.mjs +5 -4
  31. package/panelbar/PanelBarItem.js +1 -1
  32. package/panelbar/PanelBarItem.mjs +13 -15
  33. package/panelbar/interfaces/RenderPanelBarItem.d.ts +1 -0
  34. package/panelbar/util.d.ts +1 -1
  35. package/panelbar/util.js +1 -1
  36. package/panelbar/util.mjs +62 -59
  37. package/splitter/SplitterBar.d.ts +1 -0
  38. package/splitter/SplitterBar.js +1 -1
  39. package/splitter/SplitterBar.mjs +64 -56
  40. package/stepper/Step.js +1 -1
  41. package/stepper/Step.mjs +79 -85
  42. package/stepper/Stepper.js +1 -1
  43. package/stepper/Stepper.mjs +103 -104
  44. package/stepper/messages/index.d.ts +12 -2
  45. package/stepper/messages/index.js +1 -1
  46. package/stepper/messages/index.mjs +8 -4
  47. package/tilelayout/InternalTile.js +1 -1
  48. package/tilelayout/InternalTile.mjs +119 -115
  49. package/tilelayout/TileLayout.js +1 -1
  50. package/tilelayout/TileLayout.mjs +58 -58
  51. package/timeline/TimelineCard.d.ts +2 -0
  52. package/timeline/TimelineCard.js +1 -1
  53. package/timeline/TimelineCard.mjs +16 -15
  54. package/timeline/TimelineHorizontal.js +1 -1
  55. package/timeline/TimelineHorizontal.mjs +105 -101
@@ -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=require("react"),r=require("prop-types"),c=require("@progress/kendo-react-common"),O=require("./context/DrawerContext.js");function R(t){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const a in t)if(a!=="default"){const l=Object.getOwnPropertyDescriptor(t,a);Object.defineProperty(n,a,l.get?l:{enumerable:!0,get:()=>t[a]})}}return n.default=t,Object.freeze(n)}const e=R(E),d=e.forwardRef((t,n)=>{const{className:a,style:l,text:u,icon:i,svgIcon:b,separator:g,disabled:o,selected:I,onSelect:m,index:f,tabIndex:k,children:y,...w}=t,{expanded:T,mini:P,item:x}=e.useContext(O.DrawerContext),s=e.useRef(null),p=e.useCallback(()=>{s.current&&s.current.focus()},[]);e.useImperativeHandle(n,()=>({element:s.current,focus:p,props:t}));const C=c.classNames("k-drawer-item",{"k-selected":I,"k-disabled":o},a),N=e.useCallback(j=>{if(m&&!o){const v={element:s.current,focus:p,props:t};m(v,f,j)}},[m,f,o]),D=e.createElement(e.Fragment,null,(i||b)&&e.createElement(c.IconWrap,{name:i&&c.toIconName(i),icon:b}),e.createElement("span",{className:"k-item-text"},u));return g?e.createElement("li",{className:"k-drawer-item k-drawer-separator",role:"separator"}):e.createElement("li",{ref:s,className:C,style:l,role:"menuitem","aria-label":u,"aria-disabled":o,onClick:N,tabIndex:c.getTabIndex(k,o),...w},x?y:D)});d.propTypes={className:r.string,style:r.object,text:r.string,icon:r.string,svgIcon:c.svgIconPropType,separator:r.bool,selected:r.bool,disabled:r.bool,targetItem:r.any};d.displayName="KendoDrawerItem";exports.DrawerItem=d;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const E=require("react"),r=require("prop-types"),c=require("@progress/kendo-react-common"),O=require("./context/DrawerContext.js");function R(t){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const l=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(a,n,l.get?l:{enumerable:!0,get:()=>t[n]})}}return a.default=t,Object.freeze(a)}const e=R(E),d=e.forwardRef((t,a)=>{const{className:n,style:l,text:p,icon:i,svgIcon:u,separator:g,disabled:o,selected:I,onSelect:m,index:b,tabIndex:k,children:y,...w}=t,{expanded:T,mini:P,item:x}=e.useContext(O.DrawerContext),s=e.useRef(null),f=e.useCallback(()=>{s.current&&s.current.focus()},[]);e.useImperativeHandle(a,()=>({element:s.current,focus:f,props:t}));const C=c.classNames("k-drawer-item",{"k-selected":I,"k-disabled":o},n),N=e.useCallback(D=>{if(m&&!o){const j={element:s.current,focus:f,props:t};m(j,b,D)}},[m,b,o]),v=e.createElement(e.Fragment,null,(i||u)&&e.createElement(c.IconWrap,{name:i&&c.toIconName(i),icon:u}),e.createElement("span",{className:"k-item-text"},p));return g?e.createElement("li",{className:"k-drawer-item k-drawer-separator",role:"separator"}):e.createElement("li",{ref:s,className:C,style:l,role:"menuitem","aria-disabled":o||void 0,onClick:N,tabIndex:c.getTabIndex(k,o),...w},x?y:v)});d.propTypes={className:r.string,style:r.object,text:r.string,icon:r.string,svgIcon:c.svgIconPropType,separator:r.bool,selected:r.bool,disabled:r.bool,targetItem:r.any};d.displayName="KendoDrawerItem";exports.DrawerItem=d;
@@ -7,63 +7,62 @@
7
7
  */
8
8
  import * as e from "react";
9
9
  import t from "prop-types";
10
- import { classNames as v, IconWrap as R, toIconName as T, getTabIndex as D, svgIconPropType as P } from "@progress/kendo-react-common";
10
+ import { classNames as h, IconWrap as R, toIconName as T, getTabIndex as D, svgIconPropType as P } from "@progress/kendo-react-common";
11
11
  import { DrawerContext as j } from "./context/DrawerContext.mjs";
12
- const d = e.forwardRef((s, p) => {
12
+ const i = e.forwardRef((s, d) => {
13
13
  const {
14
- className: u,
15
- style: f,
16
- text: l,
14
+ className: p,
15
+ style: u,
16
+ text: f,
17
17
  icon: n,
18
- svgIcon: c,
18
+ svgIcon: l,
19
19
  separator: b,
20
20
  disabled: a,
21
21
  selected: I,
22
22
  onSelect: o,
23
- index: m,
23
+ index: c,
24
24
  tabIndex: x,
25
25
  children: k,
26
26
  ...g
27
- } = s, { expanded: F, mini: H, item: N } = e.useContext(j), r = e.useRef(null), i = e.useCallback(() => {
27
+ } = s, { expanded: F, mini: H, item: N } = e.useContext(j), r = e.useRef(null), m = e.useCallback(() => {
28
28
  r.current && r.current.focus();
29
29
  }, []);
30
30
  e.useImperativeHandle(
31
- p,
31
+ d,
32
32
  () => ({
33
33
  element: r.current,
34
- focus: i,
34
+ focus: m,
35
35
  props: s
36
36
  })
37
37
  );
38
- const w = v(
38
+ const w = h(
39
39
  "k-drawer-item",
40
40
  {
41
41
  "k-selected": I,
42
42
  "k-disabled": a
43
43
  },
44
- u
44
+ p
45
45
  ), C = e.useCallback(
46
46
  (E) => {
47
47
  if (o && !a) {
48
- const h = {
48
+ const v = {
49
49
  element: r.current,
50
- focus: i,
50
+ focus: m,
51
51
  props: s
52
52
  };
53
- o(h, m, E);
53
+ o(v, c, E);
54
54
  }
55
55
  },
56
- [o, m, a]
57
- ), y = /* @__PURE__ */ e.createElement(e.Fragment, null, (n || c) && /* @__PURE__ */ e.createElement(R, { name: n && T(n), icon: c }), /* @__PURE__ */ e.createElement("span", { className: "k-item-text" }, l));
56
+ [o, c, a]
57
+ ), y = /* @__PURE__ */ e.createElement(e.Fragment, null, (n || l) && /* @__PURE__ */ e.createElement(R, { name: n && T(n), icon: l }), /* @__PURE__ */ e.createElement("span", { className: "k-item-text" }, f));
58
58
  return b ? /* @__PURE__ */ e.createElement("li", { className: "k-drawer-item k-drawer-separator", role: "separator" }) : /* @__PURE__ */ e.createElement(
59
59
  "li",
60
60
  {
61
61
  ref: r,
62
62
  className: w,
63
- style: f,
63
+ style: u,
64
64
  role: "menuitem",
65
- "aria-label": l,
66
- "aria-disabled": a,
65
+ "aria-disabled": a || void 0,
67
66
  onClick: C,
68
67
  tabIndex: D(x, a),
69
68
  ...g
@@ -71,7 +70,7 @@ const d = e.forwardRef((s, p) => {
71
70
  N ? k : y
72
71
  );
73
72
  });
74
- d.propTypes = {
73
+ i.propTypes = {
75
74
  className: t.string,
76
75
  style: t.object,
77
76
  text: t.string,
@@ -82,7 +81,7 @@ d.propTypes = {
82
81
  disabled: t.bool,
83
82
  targetItem: t.any
84
83
  };
85
- d.displayName = "KendoDrawerItem";
84
+ i.displayName = "KendoDrawerItem";
86
85
  export {
87
- d as DrawerItem
86
+ i as DrawerItem
88
87
  };
@@ -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 R=require("react"),a=require("prop-types"),t=require("@progress/kendo-react-common"),g=require("@progress/kendo-svg-icons");function P(e){const d=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const c in e)if(c!=="default"){const i=Object.getOwnPropertyDescriptor(e,c);Object.defineProperty(d,c,i.get?i:{enumerable:!0,get:()=>e[c]})}}return d.default=e,Object.freeze(d)}const n=P(R),f=n.forwardRef((e,d)=>{const c=n.useRef(null),[i,k]=n.useState(!1),m=n.useCallback(()=>({element:c.current}),[]);n.useImperativeHandle(d,m);const{expanded:o=!1,disabled:s,title:p,subtitle:v,onAction:r,expandIcon:u,collapseIcon:b,expandSVGIcon:x,collapseSVGIcon:y}=e,I=n.useCallback(l=>{t.dispatchEvent(r,l,m(),{expanded:o})},[r,o]),N=n.useCallback(l=>{(l.keyCode===t.Keys.enter||l.keyCode===t.Keys.space)&&(l.preventDefault(),t.dispatchEvent(r,l,m(),{expanded:o}))},[r,o]),E=n.useCallback(()=>{e.disabled||k(!0)},[e.disabled]),h=n.useCallback(()=>{e.disabled||k(!1)},[e.disabled]),{onFocus:C,onBlur:S}=t.useAsyncFocusBlur({onFocus:E,onBlur:h});return n.createElement("div",{ref:c,className:t.classNames("k-expander",e.className,{"k-expanded":o,"k-focus":i&&!s,"k-disabled":s}),onFocus:C,onBlur:S,style:e.style,id:e.id,dir:t.useRtl(c,e.dir),onKeyDown:s?void 0:N},n.createElement("div",{role:"button","aria-controls":e.ariaControls,"aria-expanded":o,"aria-disabled":s,tabIndex:t.getTabIndex(e.tabIndex,s),className:"k-expander-header",onClick:s?void 0:I},p!==void 0?n.createElement("div",{className:"k-expander-title"},p):void 0,n.createElement("span",{className:"k-spacer"}),v!==void 0?n.createElement("div",{className:"k-expander-sub-title"},v):void 0,n.createElement("span",{className:"k-expander-indicator"},n.createElement(t.IconWrap,{name:o?b?void 0:"chevron-up":u?void 0:"chevron-down",icon:o?!y&&!b?g.chevronUpIcon:y:!x&&!u?g.chevronDownIcon:x,className:t.classNames(o?{[String(b)]:!!b}:{[String(u)]:!!u})}))),e.children)});f.propTypes={children:a.node,className:a.string,style:a.object,dir:a.string,id:a.string,tabIndex:a.number,title:a.node,subtitle:a.node,expandIcon:a.string,collapseIcon:a.string,expanded:a.bool,disabled:a.bool,onAction:a.func};f.displayName="KendoReactExpansionPanel";exports.ExpansionPanel=f;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const w=require("react"),a=require("prop-types"),t=require("@progress/kendo-react-common"),g=require("@progress/kendo-svg-icons");function P(e){const d=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const s in e)if(s!=="default"){const i=Object.getOwnPropertyDescriptor(e,s);Object.defineProperty(d,s,i.get?i:{enumerable:!0,get:()=>e[s]})}}return d.default=e,Object.freeze(d)}const n=P(w),f=n.forwardRef((e,d)=>{const s=n.useRef(null),[i,p]=n.useState(!1),k=t.useId(),b=n.useCallback(()=>({element:s.current}),[]);n.useImperativeHandle(d,b);const{expanded:o=!1,disabled:c,title:v,subtitle:x,onAction:r,expandIcon:u,collapseIcon:m,expandSVGIcon:y,collapseSVGIcon:I}=e,N=n.useCallback(l=>{t.dispatchEvent(r,l,b(),{expanded:o})},[r,o]),E=n.useCallback(l=>{(l.keyCode===t.Keys.enter||l.keyCode===t.Keys.space)&&(l.preventDefault(),t.dispatchEvent(r,l,b(),{expanded:o}))},[r,o]),h=n.useCallback(()=>{e.disabled||p(!0)},[e.disabled]),C=n.useCallback(()=>{e.disabled||p(!1)},[e.disabled]),{onFocus:S,onBlur:R}=t.useAsyncFocusBlur({onFocus:h,onBlur:C});return n.createElement("div",{ref:s,className:t.classNames("k-expander",e.className,{"k-expanded":o,"k-focus":i&&!c,"k-disabled":c}),onFocus:S,onBlur:R,style:e.style,id:e.id,dir:t.useRtl(s,e.dir),onKeyDown:c?void 0:E},n.createElement("div",{role:"button","aria-controls":e.ariaControls||k,"aria-expanded":o,"aria-disabled":c||void 0,tabIndex:t.getTabIndex(e.tabIndex,c),className:"k-expander-header",onClick:c?void 0:N},v!==void 0?n.createElement("div",{className:"k-expander-title"},v):void 0,n.createElement("span",{className:"k-spacer"}),x!==void 0?n.createElement("div",{className:"k-expander-sub-title"},x):void 0,n.createElement("span",{className:"k-expander-indicator"},n.createElement(t.IconWrap,{name:o?m?void 0:"chevron-up":u?void 0:"chevron-down",icon:o?!I&&!m?g.chevronUpIcon:I:!y&&!u?g.chevronDownIcon:y,className:t.classNames(o?{[String(m)]:!!m}:{[String(u)]:!!u})}))),n.createElement("div",{id:k,className:t.classNames("k-expander-content-wrapper",{"k-hidden":!o})},e.children))});f.propTypes={children:a.node,className:a.string,style:a.object,dir:a.string,id:a.string,tabIndex:a.number,title:a.node,subtitle:a.node,expandIcon:a.string,collapseIcon:a.string,expanded:a.bool,disabled:a.bool,onAction:a.func};f.displayName="KendoReactExpansionPanel";exports.ExpansionPanel=f;
@@ -7,89 +7,89 @@
7
7
  */
8
8
  import * as e from "react";
9
9
  import n from "prop-types";
10
- import { dispatchEvent as k, Keys as p, useAsyncFocusBlur as w, useRtl as F, classNames as v, getTabIndex as S, IconWrap as D } from "@progress/kendo-react-common";
11
- import { chevronDownIcon as K, chevronUpIcon as A } from "@progress/kendo-svg-icons";
12
- const I = e.forwardRef((a, y) => {
13
- const i = e.useRef(null), [N, u] = e.useState(!1), r = e.useCallback(() => ({ element: i.current }), []);
14
- e.useImperativeHandle(y, r);
10
+ import { useId as F, dispatchEvent as v, Keys as I, useAsyncFocusBlur as S, useRtl as D, classNames as u, getTabIndex as K, IconWrap as A } from "@progress/kendo-react-common";
11
+ import { chevronDownIcon as P, chevronUpIcon as T } from "@progress/kendo-svg-icons";
12
+ const y = e.forwardRef((a, N) => {
13
+ const i = e.useRef(null), [h, m] = e.useState(!1), b = F(), r = e.useCallback(() => ({ element: i.current }), []);
14
+ e.useImperativeHandle(N, r);
15
15
  const {
16
- expanded: o = !1,
17
- disabled: l,
18
- title: m,
19
- subtitle: b,
20
- onAction: s,
21
- expandIcon: d,
16
+ expanded: t = !1,
17
+ disabled: o,
18
+ title: k,
19
+ subtitle: p,
20
+ onAction: d,
21
+ expandIcon: s,
22
22
  collapseIcon: c,
23
- expandSVGIcon: f,
24
- collapseSVGIcon: x
25
- } = a, h = e.useCallback(
26
- (t) => {
27
- k(s, t, r(), {
28
- expanded: o
23
+ expandSVGIcon: x,
24
+ collapseSVGIcon: f
25
+ } = a, E = e.useCallback(
26
+ (l) => {
27
+ v(d, l, r(), {
28
+ expanded: t
29
29
  });
30
30
  },
31
- [s, o]
31
+ [d, t]
32
32
  ), C = e.useCallback(
33
- (t) => {
34
- (t.keyCode === p.enter || t.keyCode === p.space) && (t.preventDefault(), k(s, t, r(), {
35
- expanded: o
33
+ (l) => {
34
+ (l.keyCode === I.enter || l.keyCode === I.space) && (l.preventDefault(), v(d, l, r(), {
35
+ expanded: t
36
36
  }));
37
37
  },
38
- [s, o]
39
- ), E = e.useCallback(() => {
40
- a.disabled || u(!0);
41
- }, [a.disabled]), g = e.useCallback(() => {
42
- a.disabled || u(!1);
43
- }, [a.disabled]), { onFocus: B, onBlur: R } = w({ onFocus: E, onBlur: g });
38
+ [d, t]
39
+ ), g = e.useCallback(() => {
40
+ a.disabled || m(!0);
41
+ }, [a.disabled]), w = e.useCallback(() => {
42
+ a.disabled || m(!1);
43
+ }, [a.disabled]), { onFocus: B, onBlur: R } = S({ onFocus: g, onBlur: w });
44
44
  return /* @__PURE__ */ e.createElement(
45
45
  "div",
46
46
  {
47
47
  ref: i,
48
- className: v("k-expander", a.className, {
49
- "k-expanded": o,
50
- "k-focus": N && !l,
51
- "k-disabled": l
48
+ className: u("k-expander", a.className, {
49
+ "k-expanded": t,
50
+ "k-focus": h && !o,
51
+ "k-disabled": o
52
52
  }),
53
53
  onFocus: B,
54
54
  onBlur: R,
55
55
  style: a.style,
56
56
  id: a.id,
57
- dir: F(i, a.dir),
58
- onKeyDown: l ? void 0 : C
57
+ dir: D(i, a.dir),
58
+ onKeyDown: o ? void 0 : C
59
59
  },
60
60
  /* @__PURE__ */ e.createElement(
61
61
  "div",
62
62
  {
63
63
  role: "button",
64
- "aria-controls": a.ariaControls,
65
- "aria-expanded": o,
66
- "aria-disabled": l,
67
- tabIndex: S(a.tabIndex, l),
64
+ "aria-controls": a.ariaControls || b,
65
+ "aria-expanded": t,
66
+ "aria-disabled": o || void 0,
67
+ tabIndex: K(a.tabIndex, o),
68
68
  className: "k-expander-header",
69
- onClick: l ? void 0 : h
69
+ onClick: o ? void 0 : E
70
70
  },
71
- m !== void 0 ? /* @__PURE__ */ e.createElement("div", { className: "k-expander-title" }, m) : void 0,
71
+ k !== void 0 ? /* @__PURE__ */ e.createElement("div", { className: "k-expander-title" }, k) : void 0,
72
72
  /* @__PURE__ */ e.createElement("span", { className: "k-spacer" }),
73
- b !== void 0 ? /* @__PURE__ */ e.createElement("div", { className: "k-expander-sub-title" }, b) : void 0,
73
+ p !== void 0 ? /* @__PURE__ */ e.createElement("div", { className: "k-expander-sub-title" }, p) : void 0,
74
74
  /* @__PURE__ */ e.createElement("span", { className: "k-expander-indicator" }, /* @__PURE__ */ e.createElement(
75
- D,
75
+ A,
76
76
  {
77
- name: o ? c ? void 0 : "chevron-up" : d ? void 0 : "chevron-down",
78
- icon: o ? !x && !c ? A : x : !f && !d ? K : f,
79
- className: v(
80
- o ? {
77
+ name: t ? c ? void 0 : "chevron-up" : s ? void 0 : "chevron-down",
78
+ icon: t ? !f && !c ? T : f : !x && !s ? P : x,
79
+ className: u(
80
+ t ? {
81
81
  [String(c)]: !!c
82
82
  } : {
83
- [String(d)]: !!d
83
+ [String(s)]: !!s
84
84
  }
85
85
  )
86
86
  }
87
87
  ))
88
88
  ),
89
- a.children
89
+ /* @__PURE__ */ e.createElement("div", { id: b, className: u("k-expander-content-wrapper", { "k-hidden": !t }) }, a.children)
90
90
  );
91
91
  });
92
- I.propTypes = {
92
+ y.propTypes = {
93
93
  children: n.node,
94
94
  className: n.string,
95
95
  style: n.object,
@@ -104,7 +104,7 @@ I.propTypes = {
104
104
  disabled: n.bool,
105
105
  onAction: n.func
106
106
  };
107
- I.displayName = "KendoReactExpansionPanel";
107
+ y.displayName = "KendoReactExpansionPanel";
108
108
  export {
109
- I as ExpansionPanel
109
+ y as ExpansionPanel
110
110
  };
@@ -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 o=require("@progress/kendo-react-common"),l=require("react");function s(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const a=s(l),c=a.forwardRef((e,t)=>a.createElement("div",{ref:t,...e,className:o.classNames("k-expander-content-wrapper",e.className)},a.createElement("div",{className:"k-expander-content"},e.children)));c.displayName="KendoReactExpansionPanelContent";exports.ExpansionPanelContent=c;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("@progress/kendo-react-common"),s=require("react");function l(e){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const a=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,a.get?a:{enumerable:!0,get:()=>e[t]})}}return n.default=e,Object.freeze(n)}const o=l(s),r=o.forwardRef((e,n)=>{const{children:t,...a}=e;return o.createElement("div",{ref:n,...a,className:c.classNames("k-expander-content",a.className)},t)});r.displayName="KendoReactExpansionPanelContent";exports.ExpansionPanelContent=r;
@@ -5,10 +5,13 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import { classNames as t } from "@progress/kendo-react-common";
9
- import * as a from "react";
10
- const r = a.forwardRef(
11
- (e, n) => /* @__PURE__ */ a.createElement("div", { ref: n, ...e, className: t("k-expander-content-wrapper", e.className) }, /* @__PURE__ */ a.createElement("div", { className: "k-expander-content" }, e.children))
8
+ import { classNames as s } from "@progress/kendo-react-common";
9
+ import * as n from "react";
10
+ const r = n.forwardRef(
11
+ (a, t) => {
12
+ const { children: o, ...e } = a;
13
+ return /* @__PURE__ */ n.createElement("div", { ref: t, ...e, className: s("k-expander-content", e.className) }, o);
14
+ }
12
15
  );
13
16
  r.displayName = "KendoReactExpansionPanelContent";
14
17
  export {
@@ -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-layout",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate: 1778745569,version:"14.5.0-develop.14",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-layout",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate: 1778773184,version:"14.5.0-develop.15",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: 1778745569,
11
- version: '14.5.0-develop.14',
10
+ publishDate: 1778773184,
11
+ version: '14.5.0-develop.15',
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-layout",
3
- "version": "14.5.0-develop.14",
3
+ "version": "14.5.0-develop.15",
4
4
  "description": "React Layout components enable you to create a perceptive and intuitive layout of web projects. KendoReact Layout package",
5
5
  "author": "Progress",
6
6
  "license": "SEE LICENSE IN LICENSE.md",
@@ -26,12 +26,12 @@
26
26
  "sideEffects": false,
27
27
  "peerDependencies": {
28
28
  "@progress/kendo-licensing": "^1.7.2",
29
- "@progress/kendo-react-animation": "14.5.0-develop.14",
30
- "@progress/kendo-react-buttons": "14.5.0-develop.14",
31
- "@progress/kendo-react-common": "14.5.0-develop.14",
32
- "@progress/kendo-react-intl": "14.5.0-develop.14",
33
- "@progress/kendo-react-popup": "14.5.0-develop.14",
34
- "@progress/kendo-react-progressbars": "14.5.0-develop.14",
29
+ "@progress/kendo-react-animation": "14.5.0-develop.15",
30
+ "@progress/kendo-react-buttons": "14.5.0-develop.15",
31
+ "@progress/kendo-react-common": "14.5.0-develop.15",
32
+ "@progress/kendo-react-intl": "14.5.0-develop.15",
33
+ "@progress/kendo-react-popup": "14.5.0-develop.15",
34
+ "@progress/kendo-react-progressbars": "14.5.0-develop.15",
35
35
  "@progress/kendo-svg-icons": "^4.9.0 || ^5.0.0",
36
36
  "react": "^18.0.0 || ^19.0.0",
37
37
  "react-dom": "^18.0.0 || ^19.0.0"
@@ -76,7 +76,7 @@
76
76
  "package": {
77
77
  "productName": "KendoReact",
78
78
  "productCode": "KENDOUIREACT",
79
- "publishDate": 1778745569,
79
+ "publishDate": 1778773184,
80
80
  "licensingDocsUrl": "https://www.telerik.com/kendo-react-ui/components/my-license/"
81
81
  }
82
82
  },
@@ -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 Q=require("react"),m=require("prop-types"),L=require("./PanelBarItem.js"),b=require("./util.js"),d=require("@progress/kendo-react-common"),a=require("./interfaces/NavigationAction.js");function X(o){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const r in o)if(r!=="default"){const k=Object.getOwnPropertyDescriptor(o,r);Object.defineProperty(c,r,k.get?k:{enumerable:!0,get:()=>o[r]})}}return c.default=o,Object.freeze(c)}const i=X(Q),w=o=>{const{animation:c=!0,children:r,dir:k,selected:I,expanded:U,expandMode:R="multiple",className:D,keepItemsMounted:S=!1,onSelect:x,style:j,isControlled:W}=o,K=i.useRef(null),_=i.useRef(null),T=i.useRef(void 0),N=i.useRef(null);d.useWebMcpRegister("panelbar",_,o,o.webMcp);const[p,g]=i.useState(()=>{const t=R||"multiple",u=b.getInitialState(o,t);return u.focused||(u.focused=b.getFirstId(o)),u}),B=R||"multiple",M=I!==void 0?I:p.selected,h=W?U||[]:p.expanded,F=i.useCallback(t=>{N.current=window.setTimeout(()=>t())},[]),C=i.useCallback(t=>{const u=A,s=b.flatChildren(i.Children.toArray(u));let n,l;switch(s.forEach(e=>{e.props.uniquePrivateKey===(t.uniquePrivateKey||p.focused)&&(n=e)}),B){case"single":l=[...n.props.parentUniquePrivateKey,n.props.uniquePrivateKey],b.isArrayEqual(h,l)&&(n.props.parentUniquePrivateKey?l=[...n.props.parentUniquePrivateKey]:l=[]);break;case"multiple":{l=h.slice();const e=l.indexOf(n.props.uniquePrivateKey);e===-1?l.push(n.props.uniquePrivateKey):l.splice(e,1);break}default:l=h.slice();break}g(e=>({...e,selected:n.props.uniquePrivateKey,expanded:l})),x&&x({target:n,expandedItems:l})},[r,p.focused,B,h,x]),f=i.useCallback((t,u=0,s)=>{const n=A,l=b.flatVisibleChildren(i.Children.toArray(n)),e=b.getFocusedChild(l,u,t,p.focused,s);if(e){const v=h.slice();if(s===a.NavigationAction.Right&&e&&e.props&&e.props.children&&e.props.children.length>0){if(v.push(e.props.uniquePrivateKey),g(y=>({...y,expanded:[...new Set(v)]})),e.props.expanded){const y=e.props.children[0].props.uniquePrivateKey;g(P=>({...P,focused:y}))}}else if(s===a.NavigationAction.Left&&(e&&e.props&&e.props.parentUniquePrivateKey&&e.props.parentUniquePrivateKey.length>0||e&&e.props&&!e.props.disabled&&e.props.children&&e.props.children.length>0)){const y=e.props.parentUniquePrivateKey;if(e.props.expanded){const P=e.props.uniquePrivateKey,q=v.indexOf(P);v.splice(q,1),g(J=>({...J,expanded:v}))}else if(e.props.level>0){const P=e.props.parentUniquePrivateKey[y.length-1];g(q=>({...q,focused:P}))}}else T.current=e.props.id,g(y=>({...y,focused:e.props.uniquePrivateKey}))}},[r,p.focused,h]),E=i.useCallback(t=>{C(t),f(t)},[C,f]),A=i.useMemo(()=>b.renderChildren({animation:c,keepItemsMounted:S,state:{...p,selected:M},expanded:h,handleSelect:E,children:r}),[c,S,p,M,h,r,E]),O=i.useCallback((t,u)=>{let s;switch(u){case a.NavigationAction.First:f(t,s,a.NavigationAction.First);break;case a.NavigationAction.Last:f(t,s,a.NavigationAction.Last);break;case a.NavigationAction.Left:f(t,s,a.NavigationAction.Left);break;case a.NavigationAction.Right:f(t,s,a.NavigationAction.Right);break;case a.NavigationAction.Previous:s=-1,f(t,s);break;case a.NavigationAction.Next:s=1,f(t,s);break;case a.NavigationAction.Toggle:C(t);break}},[f,C]),$=i.useCallback(()=>{clearTimeout(N.current),p.wrapperFocused||g(t=>({...t,wrapperFocused:!0}))},[p.wrapperFocused]),z=i.useCallback(()=>{F(()=>{g(t=>({...t,wrapperFocused:!1}))})},[F]),H=i.useCallback(t=>{const u=K.current&&getComputedStyle(K.current).direction==="rtl"||!1;if(t.target===t.currentTarget){const s=t.keyCode;let n;switch(s){case d.Keys.left:n=u?a.NavigationAction.Right:a.NavigationAction.Left;break;case d.Keys.up:n=a.NavigationAction.Previous;break;case d.Keys.right:n=u?a.NavigationAction.Left:a.NavigationAction.Right;break;case d.Keys.down:n=a.NavigationAction.Next;break;case d.Keys.home:n=a.NavigationAction.First;break;case d.Keys.end:n=a.NavigationAction.Last;break;case d.Keys.space:case d.Keys.enter:n=a.NavigationAction.Toggle;break;default:n=null;break}n!==null&&(t.preventDefault(),O(t,n))}},[O]);i.useEffect(()=>()=>{N.current&&clearTimeout(N.current)},[]);const V={"aria-activedescendant":T.current},G=d.classNames("k-panelbar",D);return i.createElement("ul",{ref:K,dir:k,role:"tree",tabIndex:0,onKeyDown:H,onFocus:$,onBlur:z,className:G,style:j,...V},A)};w.propTypes={children:m.oneOfType([m.arrayOf(function(o,c){return o[c].type!==L.PanelBarItem?new Error("PanelBar children should be either PanelBarItem or an array of PanelBarItem."):null}),function(o,c){const r=o[c];return r&&r.type!==L.PanelBarItem?new Error("PanelBar children should be either PanelBarItem or an array of PanelBarItem."):null}]),selected:m.string,expandMode(o,c){const r=o[c];return r!=="single"&&r!=="multiple"&&r!=="default"?new Error(`Invalid value '${r}' given to '${c}'. It must be either 'single', 'multiple' or 'default'.`):null},animation:m.bool,keepItemsMounted:m.bool,onSelect:m.func};w.defaultProps={expandMode:"multiple",animation:!0,keepItemsMounted:!1};exports.PanelBar=w;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Q=require("react"),m=require("prop-types"),L=require("./PanelBarItem.js"),b=require("./util.js"),d=require("@progress/kendo-react-common"),a=require("./interfaces/NavigationAction.js");function X(o){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const r in o)if(r!=="default"){const k=Object.getOwnPropertyDescriptor(o,r);Object.defineProperty(c,r,k.get?k:{enumerable:!0,get:()=>o[r]})}}return c.default=o,Object.freeze(c)}const i=X(Q),w=o=>{const{animation:c=!0,children:r,dir:k,selected:I,expanded:U,expandMode:R="multiple",className:D,keepItemsMounted:S=!1,onSelect:x,style:j,isControlled:W}=o,K=i.useRef(null),_=i.useRef(null),T=i.useRef(void 0),N=i.useRef(null);d.useWebMcpRegister("panelbar",_,o,o.webMcp);const[p,g]=i.useState(()=>{const t=R||"multiple",u=b.getInitialState(o,t);return u.focused||(u.focused=b.getFirstId(o)),u}),B=R||"multiple",M=I!==void 0?I:p.selected,h=W?U||[]:p.expanded,F=i.useCallback(t=>{N.current=window.setTimeout(()=>t())},[]),C=i.useCallback(t=>{const u=A,s=b.flatChildren(i.Children.toArray(u));let n,l;switch(s.forEach(e=>{e.props.uniquePrivateKey===(t.uniquePrivateKey||p.focused)&&(n=e)}),B){case"single":l=[...n.props.parentUniquePrivateKey,n.props.uniquePrivateKey],b.isArrayEqual(h,l)&&(n.props.parentUniquePrivateKey?l=[...n.props.parentUniquePrivateKey]:l=[]);break;case"multiple":{l=h.slice();const e=l.indexOf(n.props.uniquePrivateKey);e===-1?l.push(n.props.uniquePrivateKey):l.splice(e,1);break}default:l=h.slice();break}g(e=>({...e,selected:n.props.uniquePrivateKey,expanded:l})),x&&x({target:n,expandedItems:l})},[r,p.focused,B,h,x]),f=i.useCallback((t,u=0,s)=>{const n=A,l=b.flatVisibleChildren(i.Children.toArray(n)),e=b.getFocusedChild(l,u,t,p.focused,s);if(e){const v=h.slice();if(s===a.NavigationAction.Right&&e&&e.props&&e.props.children&&e.props.children.length>0){if(v.push(e.props.uniquePrivateKey),g(y=>({...y,expanded:[...new Set(v)]})),e.props.expanded){const y=e.props.children[0];g(P=>({...P,focused:y.props.uniquePrivateKey}))}}else if(s===a.NavigationAction.Left&&(e&&e.props&&e.props.parentUniquePrivateKey&&e.props.parentUniquePrivateKey.length>0||e&&e.props&&!e.props.disabled&&e.props.children&&e.props.children.length>0)){const y=e.props.parentUniquePrivateKey;if(e.props.expanded){const P=e.props.uniquePrivateKey,q=v.indexOf(P);v.splice(q,1),g(J=>({...J,expanded:v}))}else if(e.props.level>0){const P=e.props.parentUniquePrivateKey[y.length-1];g(q=>({...q,focused:P}))}}else g(y=>({...y,focused:e.props.uniquePrivateKey}))}},[r,p.focused,h]),E=i.useCallback(t=>{C(t),f(t)},[C,f]),A=i.useMemo(()=>b.renderChildren({animation:c,keepItemsMounted:S,state:{...p,selected:M},expanded:h,handleSelect:E,children:r,activeDescendantRef:T}),[c,S,p,M,h,r,E]),O=i.useCallback((t,u)=>{let s;switch(u){case a.NavigationAction.First:f(t,s,a.NavigationAction.First);break;case a.NavigationAction.Last:f(t,s,a.NavigationAction.Last);break;case a.NavigationAction.Left:f(t,s,a.NavigationAction.Left);break;case a.NavigationAction.Right:f(t,s,a.NavigationAction.Right);break;case a.NavigationAction.Previous:s=-1,f(t,s);break;case a.NavigationAction.Next:s=1,f(t,s);break;case a.NavigationAction.Toggle:C(t);break}},[f,C]),$=i.useCallback(()=>{clearTimeout(N.current),p.wrapperFocused||g(t=>({...t,wrapperFocused:!0}))},[p.wrapperFocused]),z=i.useCallback(()=>{F(()=>{g(t=>({...t,wrapperFocused:!1}))})},[F]),H=i.useCallback(t=>{const u=K.current&&getComputedStyle(K.current).direction==="rtl"||!1;if(t.target===t.currentTarget){const s=t.keyCode;let n;switch(s){case d.Keys.left:n=u?a.NavigationAction.Right:a.NavigationAction.Left;break;case d.Keys.up:n=a.NavigationAction.Previous;break;case d.Keys.right:n=u?a.NavigationAction.Left:a.NavigationAction.Right;break;case d.Keys.down:n=a.NavigationAction.Next;break;case d.Keys.home:n=a.NavigationAction.First;break;case d.Keys.end:n=a.NavigationAction.Last;break;case d.Keys.space:case d.Keys.enter:n=a.NavigationAction.Toggle;break;default:n=null;break}n!==null&&(t.preventDefault(),O(t,n))}},[O]);i.useEffect(()=>()=>{N.current&&clearTimeout(N.current)},[]);const V={"aria-activedescendant":T.current},G=d.classNames("k-panelbar",D);return i.createElement("ul",{ref:K,dir:k,role:"tree",tabIndex:0,onKeyDown:H,onFocus:$,onBlur:z,className:G,style:j,...V},A)};w.propTypes={children:m.oneOfType([m.arrayOf(function(o,c){return o[c].type!==L.PanelBarItem?new Error("PanelBar children should be either PanelBarItem or an array of PanelBarItem."):null}),function(o,c){const r=o[c];return r&&r.type!==L.PanelBarItem?new Error("PanelBar children should be either PanelBarItem or an array of PanelBarItem."):null}]),selected:m.string,expandMode(o,c){const r=o[c];return r!=="single"&&r!=="multiple"&&r!=="default"?new Error(`Invalid value '${r}' given to '${c}'. It must be either 'single', 'multiple' or 'default'.`):null},animation:m.bool,keepItemsMounted:m.bool,onSelect:m.func};w.defaultProps={expandMode:"multiple",animation:!0,keepItemsMounted:!1};exports.PanelBar=w;
@@ -64,8 +64,8 @@ const U = (c) => {
64
64
  const k = h.slice();
65
65
  if (s === n.Right && e && e.props && e.props.children && e.props.children.length > 0) {
66
66
  if (k.push(e.props.uniquePrivateKey), f((b) => ({ ...b, expanded: [...new Set(k)] })), e.props.expanded) {
67
- const b = e.props.children[0].props.uniquePrivateKey;
68
- f((P) => ({ ...P, focused: b }));
67
+ const b = e.props.children[0];
68
+ f((P) => ({ ...P, focused: b.props.uniquePrivateKey }));
69
69
  }
70
70
  } else if (s === n.Left && (e && e.props && e.props.parentUniquePrivateKey && e.props.parentUniquePrivateKey.length > 0 || e && e.props && !e.props.disabled && e.props.children && e.props.children.length > 0)) {
71
71
  const b = e.props.parentUniquePrivateKey;
@@ -77,7 +77,7 @@ const U = (c) => {
77
77
  f((q) => ({ ...q, focused: P }));
78
78
  }
79
79
  } else
80
- T.current = e.props.id, f((b) => ({ ...b, focused: e.props.uniquePrivateKey }));
80
+ f((b) => ({ ...b, focused: e.props.uniquePrivateKey }));
81
81
  }
82
82
  },
83
83
  [o, p.focused, h]
@@ -92,7 +92,8 @@ const U = (c) => {
92
92
  state: { ...p, selected: F },
93
93
  expanded: h,
94
94
  handleSelect: B,
95
- children: o
95
+ children: o,
96
+ activeDescendantRef: T
96
97
  }), [u, R, p, F, h, o, B]), S = a.useCallback(
97
98
  (t, i) => {
98
99
  let s;
@@ -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 z=require("react"),n=require("prop-types"),i=require("@progress/kendo-react-common"),N=require("@progress/kendo-svg-icons"),G=require("@progress/kendo-react-animation");function $(a){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(a){for(const r in a)if(r!=="default"){const t=Object.getOwnPropertyDescriptor(a,r);Object.defineProperty(c,r,t.get?t:{enumerable:!0,get:()=>a[r]})}}return c.default=a,Object.freeze(c)}const e=$(z);function J({imageUrl:a,icon:c,svgIcon:r,iconClass:t}){return a?e.createElement("img",{role:"presentation",className:"k-panelbar-item-icon k-image",src:a}):c||r?e.createElement(i.IconWrap,{className:"k-panelbar-item-icon",name:c,icon:r}):t?e.createElement("span",{role:"presentation",className:"k-panelbar-item-icon "+t}):null}const d=e.forwardRef((a,c)=>{const{id:r,children:t,title:E=h.title,uniquePrivateKey:u,disabled:l,selected:b,focused:C,expanded:o,className:P,level:k,headerClassName:R,animation:y,keepItemsMounted:s,onSelect:m,imageUrl:S,icon:B,svgIcon:x,iconClass:O}=a,p=e.useRef({props:a}),D=e.useRef(null);e.useImperativeHandle(p,()=>({props:a})),e.useImperativeHandle(c,()=>p.current);const[w,g]=e.useState(o||!1),T=e.useCallback(()=>{m&&!l&&m({uniquePrivateKey:u,id:r,target:p.current})},[m,l,u,r]),q=e.useCallback(f=>s?e.cloneElement(f,{...f.props,in:o}):f,[s,o]),A=e.useCallback(()=>{s&&g(!0)},[s]),j=e.useCallback(()=>{s&&g(!1)},[s]),U={role:"treeitem","aria-disabled":l,"aria-hidden":!l&&!o?"true":"false","aria-selected":!l&&b,"aria-expanded":!l&&o&&!!t},M=i.classNames("k-panelbar-item",{"k-panelbar-header":k===0,"k-expanded":o&&!!t,"k-disabled":l},`k-level-${k}`,P),_=i.classNames("k-link",{"k-selected":!l&&b,"k-focus":C},R),H={display:"block"},L=J({imageUrl:S,icon:B,svgIcon:x,iconClass:O}),F=!l&&t?e.createElement(i.IconWrap,{name:o?"chevron-up":"chevron-down",icon:o?N.chevronUpIcon:N.chevronDownIcon,className:i.classNames("k-panelbar-toggle",o?"k-panelbar-collapse":"k-panelbar-expand")}):null;let I=!1;t&&t[0]&&Array.isArray(t)&&(I=t[0].type===d);const K=s&&!w?"none":"block",v=!l&&o||s?I?e.createElement("ul",{role:"group","aria-hidden":o?"false":"true",className:"k-panelbar-group",style:{display:K}},t):t:null,W=(y===void 0||y)&&!l&&t?e.createElement(G.Reveal,{transitionEnterDuration:200,transitionExitDuration:200,key:u+"_animation",style:H,children:v,childFactory:s?q:void 0,unmountOnExit:!s,onBeforeEnter:A,onAfterExited:j}):v;return e.createElement("li",{ref:D,id:r,className:M,...U},e.createElement("span",{className:_,onClick:T},L,e.createElement("span",{className:"k-panelbar-item-text"},E),F),W)}),h={title:"Untitled"};d.propTypes={animation:n.bool,children:n.any,className:n.string,icon:n.string,iconClass:n.string,imageUrl:n.string,svgIcon:i.svgIconPropType,expanded:n.bool,disabled:n.bool,onSelect:n.func,selected:n.bool,level:n.number,title:n.oneOfType([n.string,n.element]),id:n.oneOfType([n.string,n.number]),focused:n.bool,keepItemsMounted:n.bool};d.displayName="KendoReactPanelBarItem";exports.PanelBarItem=d;exports.panelBarItemDefaultProps=h;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const z=require("react"),n=require("prop-types"),i=require("@progress/kendo-react-common"),N=require("@progress/kendo-svg-icons"),G=require("@progress/kendo-react-animation");function $(a){const c=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(a){for(const r in a)if(r!=="default"){const t=Object.getOwnPropertyDescriptor(a,r);Object.defineProperty(c,r,t.get?t:{enumerable:!0,get:()=>a[r]})}}return c.default=a,Object.freeze(c)}const e=$(z);function J({imageUrl:a,icon:c,svgIcon:r,iconClass:t}){return a?e.createElement("img",{role:"presentation",className:"k-panelbar-item-icon k-image",src:a}):c||r?e.createElement(i.IconWrap,{className:"k-panelbar-item-icon",name:c,icon:r}):t?e.createElement("span",{role:"presentation",className:"k-panelbar-item-icon "+t}):null}const d=e.forwardRef((a,c)=>{const{id:r,children:t,title:h=E.title,uniquePrivateKey:m,disabled:l,selected:b,focused:C,expanded:s,className:P,level:k,headerClassName:R,animation:y,keepItemsMounted:o,onSelect:u,imageUrl:S,icon:B,svgIcon:x,iconClass:O}=a,p=e.useRef({props:a}),D=e.useRef(null);e.useImperativeHandle(p,()=>({props:a})),e.useImperativeHandle(c,()=>p.current);const[w,g]=e.useState(s||!1),T=e.useCallback(()=>{u&&!l&&u({uniquePrivateKey:m,id:r,target:p.current})},[u,l,m,r]),q=e.useCallback(f=>o?e.cloneElement(f,{...f.props,in:s}):f,[o,s]),A=e.useCallback(()=>{o&&g(!0)},[o]),j=e.useCallback(()=>{o&&g(!1)},[o]),U={role:"treeitem","aria-disabled":l,"aria-selected":!l&&b,"aria-expanded":t?!l&&s:void 0},M=i.classNames("k-panelbar-item",{"k-panelbar-header":k===0,"k-expanded":s&&!!t,"k-disabled":l},`k-level-${k}`,P),_=i.classNames("k-link",{"k-selected":!l&&b,"k-focus":C},R),H={display:"block"},L=J({imageUrl:S,icon:B,svgIcon:x,iconClass:O}),F=!l&&t?e.createElement(i.IconWrap,{name:s?"chevron-up":"chevron-down",icon:s?N.chevronUpIcon:N.chevronDownIcon,className:i.classNames("k-panelbar-toggle",s?"k-panelbar-collapse":"k-panelbar-expand")}):null;let I=!1;t&&t[0]&&Array.isArray(t)&&(I=t[0].type===d);const K=o&&!w?"none":"block",v=!l&&s||o?I?e.createElement("ul",{role:"group",className:"k-panelbar-group",style:{display:K}},t):t:null,W=(y===void 0||y)&&!l&&t?e.createElement(G.Reveal,{transitionEnterDuration:200,transitionExitDuration:200,key:m+"_animation",style:H,children:v,childFactory:o?q:void 0,unmountOnExit:!o,onBeforeEnter:A,onAfterExited:j}):v;return e.createElement("li",{ref:D,id:r,className:M,...U},e.createElement("span",{className:_,onClick:T},L,e.createElement("span",{className:"k-panelbar-item-text"},h),F),W)}),E={title:"Untitled"};d.propTypes={animation:n.bool,children:n.any,className:n.string,icon:n.string,iconClass:n.string,imageUrl:n.string,svgIcon:i.svgIconPropType,expanded:n.bool,disabled:n.bool,onSelect:n.func,selected:n.bool,level:n.number,title:n.oneOfType([n.string,n.element]),id:n.oneOfType([n.string,n.number]),focused:n.bool,keepItemsMounted:n.bool};d.displayName="KendoReactPanelBarItem";exports.PanelBarItem=d;exports.panelBarItemDefaultProps=E;
@@ -7,21 +7,21 @@
7
7
  */
8
8
  import * as e from "react";
9
9
  import n from "prop-types";
10
- import { classNames as u, IconWrap as v, svgIconPropType as _ } from "@progress/kendo-react-common";
10
+ import { classNames as u, IconWrap as E, svgIconPropType as _ } from "@progress/kendo-react-common";
11
11
  import { chevronUpIcon as $, chevronDownIcon as j } from "@progress/kendo-svg-icons";
12
12
  import { Reveal as z } from "@progress/kendo-react-animation";
13
13
  function J({ imageUrl: o, icon: i, svgIcon: s, iconClass: a }) {
14
- return o ? /* @__PURE__ */ e.createElement("img", { role: "presentation", className: "k-panelbar-item-icon k-image", src: o }) : i || s ? /* @__PURE__ */ e.createElement(v, { className: "k-panelbar-item-icon", name: i, icon: s }) : a ? /* @__PURE__ */ e.createElement("span", { role: "presentation", className: "k-panelbar-item-icon " + a }) : null;
14
+ return o ? /* @__PURE__ */ e.createElement("img", { role: "presentation", className: "k-panelbar-item-icon k-image", src: o }) : i || s ? /* @__PURE__ */ e.createElement(E, { className: "k-panelbar-item-icon", name: i, icon: s }) : a ? /* @__PURE__ */ e.createElement("span", { role: "presentation", className: "k-panelbar-item-icon " + a }) : null;
15
15
  }
16
16
  const f = e.forwardRef((o, i) => {
17
17
  const {
18
18
  id: s,
19
19
  children: a,
20
- title: E = Q.title,
20
+ title: N = Q.title,
21
21
  uniquePrivateKey: c,
22
22
  disabled: t,
23
23
  selected: k,
24
- focused: N,
24
+ focused: h,
25
25
  expanded: r,
26
26
  className: C,
27
27
  level: b,
@@ -57,9 +57,8 @@ const f = e.forwardRef((o, i) => {
57
57
  }, [l]), L = {
58
58
  role: "treeitem",
59
59
  "aria-disabled": t,
60
- "aria-hidden": !t && !r ? "true" : "false",
61
60
  "aria-selected": !t && k,
62
- "aria-expanded": !t && r && !!a
61
+ "aria-expanded": a ? !t && r : void 0
63
62
  }, O = u(
64
63
  "k-panelbar-item",
65
64
  {
@@ -73,24 +72,23 @@ const f = e.forwardRef((o, i) => {
73
72
  "k-link",
74
73
  {
75
74
  "k-selected": !t && k,
76
- "k-focus": N
75
+ "k-focus": h
77
76
  },
78
77
  x
79
78
  ), K = { display: "block" }, M = J({ imageUrl: B, icon: R, svgIcon: w, iconClass: P }), q = !t && a ? /* @__PURE__ */ e.createElement(
80
- v,
79
+ E,
81
80
  {
82
81
  name: r ? "chevron-up" : "chevron-down",
83
82
  icon: r ? $ : j,
84
83
  className: u("k-panelbar-toggle", r ? "k-panelbar-collapse" : "k-panelbar-expand")
85
84
  }
86
85
  ) : null;
87
- let I = !1;
88
- a && a[0] && Array.isArray(a) && (I = a[0].type === f);
89
- const G = l && !A ? "none" : "block", h = !t && r || l ? I ? /* @__PURE__ */ e.createElement(
86
+ let v = !1;
87
+ a && a[0] && Array.isArray(a) && (v = a[0].type === f);
88
+ const G = l && !A ? "none" : "block", I = !t && r || l ? v ? /* @__PURE__ */ e.createElement(
90
89
  "ul",
91
90
  {
92
91
  role: "group",
93
- "aria-hidden": r ? "false" : "true",
94
92
  className: "k-panelbar-group",
95
93
  style: { display: G }
96
94
  },
@@ -102,14 +100,14 @@ const f = e.forwardRef((o, i) => {
102
100
  transitionExitDuration: 200,
103
101
  key: c + "_animation",
104
102
  style: K,
105
- children: h,
103
+ children: I,
106
104
  childFactory: l ? T : void 0,
107
105
  unmountOnExit: !l,
108
106
  onBeforeEnter: U,
109
107
  onAfterExited: H
110
108
  }
111
- ) : h;
112
- return /* @__PURE__ */ e.createElement("li", { ref: S, id: s, className: O, ...L }, /* @__PURE__ */ e.createElement("span", { className: F, onClick: D }, M, /* @__PURE__ */ e.createElement("span", { className: "k-panelbar-item-text" }, E), q), W);
109
+ ) : I;
110
+ return /* @__PURE__ */ e.createElement("li", { ref: S, id: s, className: O, ...L }, /* @__PURE__ */ e.createElement("span", { className: F, onClick: D }, M, /* @__PURE__ */ e.createElement("span", { className: "k-panelbar-item-text" }, N), q), W);
113
111
  }), Q = {
114
112
  title: "Untitled"
115
113
  };
@@ -19,4 +19,5 @@ export interface RenderPanelBarItem {
19
19
  parentExpanded?: boolean;
20
20
  level?: number;
21
21
  parentPrivateKey?: string[];
22
+ activeDescendantRef?: React.MutableRefObject<string | undefined>;
22
23
  }
@@ -14,7 +14,7 @@ import * as React from 'react';
14
14
  /**
15
15
  * @hidden
16
16
  */
17
- export declare const renderChildren: ({ animation, keepItemsMounted, state, expanded, handleSelect, children, parentExpanded, level, parentPrivateKey }: RenderPanelBarItem) => React.ReactNode;
17
+ export declare const renderChildren: ({ animation, keepItemsMounted, state, expanded, handleSelect, children, parentExpanded, level, parentPrivateKey, activeDescendantRef }: RenderPanelBarItem) => React.ReactNode;
18
18
  /**
19
19
  * @hidden
20
20
  */
package/panelbar/util.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 B=require("react"),l=require("./PanelBarItem.js"),d=require("./interfaces/NavigationAction.js");function F(n){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const e in n)if(e!=="default"){const o=Object.getOwnPropertyDescriptor(n,e);Object.defineProperty(r,e,o.get?o:{enumerable:!0,get:()=>n[e]})}}return r.default=n,Object.freeze(r)}const i=F(B),O=n=>typeof n!="object"||!("type"in n)||n.type!==l.PanelBarItem,y=({animation:n=!0,keepItemsMounted:r=!1,state:e,expanded:o,handleSelect:a,children:t,parentExpanded:c=!0,level:s=0,parentPrivateKey:f=[]})=>{const b=i.Children.toArray(t).filter(O),q=b.length?b:t;return i.Children.map(q,(p,C)=>{if(p&&p.type===l.PanelBarItem){let m;const u=g(p,f,C);if(p.props.children){const A={animation:n,keepItemsMounted:r,state:e,expanded:o,handleSelect:a,children:p.props.children,parentExpanded:(o||[]).indexOf(u)>-1,level:s+1,parentPrivateKey:[...f,u]};m=y(A)}return i.cloneElement(p,{...p.props,animation:p.props.animation!==void 0?p.props.animation:n,keepItemsMounted:r,id:p.props.id||`k-panelbar-item-default-${u}`,uniquePrivateKey:u,parentUniquePrivateKey:f,parentExpanded:c,level:s,expanded:(o||[]).indexOf(u)>-1,focused:e.focused===u&&e.wrapperFocused,selected:e.selected===u,children:m,onSelect:a})}return i.createElement("div",{className:"k-panelbar-content"},p)})},x=n=>{const r=i.Children.toArray(n.children)[0];return r?g(r,[],0):""},I=(n,r,e={expanded:n.expanded||[],selected:n.selected||"",focused:n.focused||"",wrapperFocused:!1},o=!0,a=[])=>(i.Children.map(n.children,(t,c)=>{if(t&&t.type===l.PanelBarItem){const s=g(t,a,c);!t.props.disabled&&o&&(t.props.selected&&(e.selected=s),t.props.focused&&(e.focused=s),t.props.expanded&&(r==="multiple"?e.expanded.push(s):r==="single"&&(e.expanded=[s])),t.props.children&&(e=I(t.props,r,e,!!t.props.expanded,[...a,s])))}}),e),g=(n,r,e)=>n&&n.props&&n.props.id?n.props.id:r.length?r[r.length-1]+`.${e}`:`.${e}`;function P(n,r=[]){return(n||[]).forEach(e=>{e.disabled||(r.push(e),e.expanded&&e.children&&P(e.children,r))}),r}function v(n,r=[]){return i.Children.forEach(n,e=>{e&&e.props&&!e.props.disabled&&(r.push(e),e.props.children&&v(e.props.children,r))}),r}function E(n,r=[]){return i.Children.forEach(n,e=>{e&&e.props&&(e.props.expanded||e.props.parentExpanded)&&(r.push(e),e.props.children&&E(e.props.children,r))}),r}const N=n=>n!=null;exports.PanelBarUtils=void 0;(n=>{function r(e){return e.map((o,a)=>{let t;return o.content&&(t=o.content),o.children&&(t=r(o.children)),i.createElement(l.PanelBarItem,{...o,children:t,key:o.id||a})})}n.mapItemsToComponents=r})(exports.PanelBarUtils||(exports.PanelBarUtils={}));const S=(n,r)=>n.length!==r.length?!1:n.every((e,o)=>e===r[o]),j=(n,r,e,o,a)=>{let t;if(a===d.NavigationAction.First||a===d.NavigationAction.Last)switch(a){case d.NavigationAction.First:t=n[0];break;case d.NavigationAction.Last:t=n[n.length-1];break}else n.forEach((c,s)=>{if(c.props.uniquePrivateKey===(e.uniquePrivateKey||o)){const f=s+r<0?n.length-1:s+r>n.length-1?0:s+r;t=n[f]}});return t};exports.flatChildren=v;exports.flatVisibleChildren=E;exports.flatVisibleItems=P;exports.getFirstId=x;exports.getFocusedChild=j;exports.getInitialState=I;exports.isArrayEqual=S;exports.isPresent=N;exports.renderChildren=y;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const O=require("react"),l=require("./PanelBarItem.js"),d=require("./interfaces/NavigationAction.js");function N(r){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(r){for(const e in r)if(e!=="default"){const o=Object.getOwnPropertyDescriptor(r,e);Object.defineProperty(n,e,o.get?o:{enumerable:!0,get:()=>r[e]})}}return n.default=r,Object.freeze(n)}const a=N(O),S=r=>typeof r!="object"||!("type"in r)||r.type!==l.PanelBarItem,P=({animation:r=!0,keepItemsMounted:n=!1,state:e,expanded:o,handleSelect:p,children:t,parentExpanded:c=!0,level:s=0,parentPrivateKey:f=[],activeDescendantRef:g})=>{const m=a.Children.toArray(t).filter(S),F=m.length?m:t;return a.Children.map(F,(i,A)=>{if(i&&i.type===l.PanelBarItem){let y;const u=b(i,f,A);if(i.props.children){const B={animation:r,keepItemsMounted:n,state:e,expanded:o,handleSelect:p,children:i.props.children,parentExpanded:(o||[]).indexOf(u)>-1,level:s+1,parentPrivateKey:[...f,u],activeDescendantRef:g};y=P(B)}const I=i.props.id||`k-panelbar-item-default-${u}`;return g&&e.wrapperFocused&&e.focused===u&&(g.current=I),a.cloneElement(i,{...i.props,animation:i.props.animation!==void 0?i.props.animation:r,keepItemsMounted:n,id:I,uniquePrivateKey:u,parentUniquePrivateKey:f,parentExpanded:c,level:s,expanded:(o||[]).indexOf(u)>-1,focused:e.focused===u&&e.wrapperFocused,selected:e.selected===u,children:y,onSelect:p})}return a.createElement("div",{className:"k-panelbar-content","aria-hidden":c?void 0:"true"},i)})},j=r=>{const n=a.Children.toArray(r.children)[0];return n?b(n,[],0):""},v=(r,n,e={expanded:r.expanded||[],selected:r.selected||"",focused:r.focused||"",wrapperFocused:!1},o=!0,p=[])=>(a.Children.map(r.children,(t,c)=>{if(t&&t.type===l.PanelBarItem){const s=b(t,p,c);!t.props.disabled&&o&&(t.props.selected&&(e.selected=s),t.props.focused&&(e.focused=s),t.props.expanded&&(n==="multiple"?e.expanded.push(s):n==="single"&&(e.expanded=[s])),t.props.children&&(e=v(t.props,n,e,!!t.props.expanded,[...p,s])))}}),e),b=(r,n,e)=>r&&r.props&&r.props.id?r.props.id:n.length?n[n.length-1]+`.${e}`:`.${e}`;function E(r,n=[]){return(r||[]).forEach(e=>{e.disabled||(n.push(e),e.expanded&&e.children&&E(e.children,n))}),n}function q(r,n=[]){return a.Children.forEach(r,e=>{e&&e.props&&!e.props.disabled&&(n.push(e),e.props.children&&q(e.props.children,n))}),n}function C(r,n=[]){return a.Children.forEach(r,e=>{e&&e.props&&(e.props.expanded||e.props.parentExpanded)&&(n.push(e),e.props.children&&C(e.props.children,n))}),n}const x=r=>r!=null;exports.PanelBarUtils=void 0;(r=>{function n(e){return e.map((o,p)=>{let t;return o.content&&(t=o.content),o.children&&(t=n(o.children)),a.createElement(l.PanelBarItem,{...o,children:t,key:o.id||p})})}r.mapItemsToComponents=n})(exports.PanelBarUtils||(exports.PanelBarUtils={}));const h=(r,n)=>r.length!==n.length?!1:r.every((e,o)=>e===n[o]),k=(r,n,e,o,p)=>{let t;if(p===d.NavigationAction.First||p===d.NavigationAction.Last)switch(p){case d.NavigationAction.First:t=r[0];break;case d.NavigationAction.Last:t=r[r.length-1];break}else r.forEach((c,s)=>{if(c.props.uniquePrivateKey===(e.uniquePrivateKey||o)){const f=s+n<0?r.length-1:s+n>r.length-1?0:s+n;t=r[f]}});return t};exports.flatChildren=q;exports.flatVisibleChildren=C;exports.flatVisibleItems=E;exports.getFirstId=j;exports.getFocusedChild=k;exports.getInitialState=v;exports.isArrayEqual=h;exports.isPresent=x;exports.renderChildren=P;