@progress/kendo-react-layout 9.5.0 → 10.0.0-develop.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/actionsheet/ActionSheet.js +1 -1
- package/actionsheet/ActionSheet.mjs +8 -10
- package/appbar/AppBar.js +1 -1
- package/appbar/AppBar.mjs +12 -14
- package/bottomnavigation/BottomNavigation.js +1 -1
- package/bottomnavigation/BottomNavigation.mjs +30 -32
- package/bottomnavigation/BottomNavigationItem.js +1 -1
- package/bottomnavigation/BottomNavigationItem.mjs +28 -30
- package/breadcrumb/Breadcrumb.js +1 -1
- package/breadcrumb/Breadcrumb.mjs +25 -27
- package/breadcrumb/BreadcrumbDelimiter.js +1 -1
- package/breadcrumb/BreadcrumbDelimiter.mjs +14 -16
- package/breadcrumb/BreadcrumbLink.js +1 -1
- package/breadcrumb/BreadcrumbLink.mjs +25 -27
- package/breadcrumb/BreadcrumbListItem.js +1 -1
- package/breadcrumb/BreadcrumbListItem.mjs +12 -14
- package/breadcrumb/BreadcrumbOrderedList.js +1 -1
- package/breadcrumb/BreadcrumbOrderedList.mjs +25 -27
- package/card/Avatar.js +1 -1
- package/card/Avatar.mjs +16 -17
- package/card/Card.js +1 -1
- package/card/Card.mjs +7 -9
- package/dist/cdn/js/kendo-react-layout.js +1 -1
- package/drawer/Drawer.js +1 -1
- package/drawer/Drawer.mjs +34 -36
- package/drawer/DrawerNavigation.js +1 -1
- package/drawer/DrawerNavigation.mjs +60 -64
- package/expansionpanel/ExpansionPanel.js +1 -1
- package/expansionpanel/ExpansionPanel.mjs +45 -47
- package/gridlayout/GridLayout.js +1 -1
- package/gridlayout/GridLayout.mjs +19 -21
- package/gridlayout/GridLayoutItem.js +1 -1
- package/gridlayout/GridLayoutItem.mjs +6 -8
- package/index.d.mts +1 -4
- package/index.d.ts +1 -4
- package/menu/components/Menu.js +1 -1
- package/menu/components/Menu.mjs +25 -26
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +2 -2
- package/package.json +8 -8
- package/panelbar/PanelBar.js +1 -1
- package/panelbar/PanelBar.mjs +46 -48
- package/splitter/Splitter.js +1 -1
- package/splitter/Splitter.mjs +64 -63
- package/stacklayout/StackLayout.js +1 -1
- package/stacklayout/StackLayout.mjs +4 -6
- package/stepper/Stepper.js +1 -1
- package/stepper/Stepper.mjs +35 -37
- package/tabstrip/TabStrip.js +1 -1
- package/tabstrip/TabStrip.mjs +31 -33
- package/tilelayout/TileLayout.js +1 -1
- package/tilelayout/TileLayout.mjs +47 -48
- package/timeline/Timeline.js +1 -1
- package/timeline/Timeline.mjs +21 -19
package/drawer/Drawer.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
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const q=require("react"),e=require("prop-types"),T=require("./context/DrawerContext.js"),W=require("./DrawerNavigation.js"),p=require("@progress/kendo-react-common");function I(t){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(o,n,i.get?i:{enumerable:!0,get:()=>t[n]})}}return o.default=t,Object.freeze(o)}const r=I(q),m=r.forwardRef((t,o)=>{const{expanded:n=a.expanded,mode:i=a.mode,position:w=a.position,className:b,drawerClassName:v,children:y,style:g,animation:h=a.animation,mini:u=a.mini,width:k=a.width,miniWidth:N=a.miniWidth,items:c,item:D,tabIndex:x,onOverlayClick:C,onSelect:l}=t,s=r.useRef(null),O=r.useCallback(()=>{s.current&&s.current.focus()},[]);r.useImperativeHandle(o,()=>({element:s.current,focus:O}));const S=r.useCallback((j,P,d)=>{if(c&&l){const R={itemTarget:j,itemIndex:P,syntheticEvent:d,nativeEvent:d&&d.nativeEvent,target:void 0};l.call(void 0,R)}},[c,l]),f=p.useDir(s,t.dir),E=p.classNames({"k-drawer-container":!0,"k-drawer-expanded":n,"k-drawer-overlay":i==="overlay","k-drawer-push":i==="push","k-drawer-mini":u&&!n},b);return r.createElement(T.DrawerContext.Provider,{value:{animation:h,expanded:n,mode:i,position:w,mini:u,dir:f,items:c,item:D,width:k,miniWidth:N,onOverlayClick:C,onSelect:S}},r.createElement("div",{className:E,ref:s,dir:f,style:g,tabIndex:x},c&&r.createElement(W.DrawerNavigation,{className:v}),y))});m.propTypes={animation:e.any,expanded:e.bool,children:e.any,className:e.string,dir:e.string,mode:e.string,position:e.string,mini:e.bool,style:e.object,tabIndex:e.number,width:e.number,miniWidth:e.number,selected:e.number,onSelect:e.func,onOverlayClick:e.func};const a={animation:!0,expanded:!1,mode:"overlay",position:"start",mini:!1,width:240,miniWidth:48};m.displayName="KendoDrawer";exports.Drawer=m;
|
package/drawer/Drawer.mjs
CHANGED
|
@@ -5,16 +5,14 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import * as
|
|
8
|
+
import * as n from "react";
|
|
9
9
|
import e from "prop-types";
|
|
10
|
-
import { DrawerContext as
|
|
10
|
+
import { DrawerContext as P } from "./context/DrawerContext.mjs";
|
|
11
11
|
import { DrawerNavigation as O } from "./DrawerNavigation.mjs";
|
|
12
|
-
import {
|
|
13
|
-
|
|
14
|
-
const p = a.forwardRef((d, u) => {
|
|
15
|
-
T(K);
|
|
12
|
+
import { useDir as T, classNames as j } from "@progress/kendo-react-common";
|
|
13
|
+
const u = n.forwardRef((d, p) => {
|
|
16
14
|
const {
|
|
17
|
-
expanded:
|
|
15
|
+
expanded: a = t.expanded,
|
|
18
16
|
mode: o = t.mode,
|
|
19
17
|
position: f = t.position,
|
|
20
18
|
className: v,
|
|
@@ -25,67 +23,67 @@ const p = a.forwardRef((d, u) => {
|
|
|
25
23
|
mini: l = t.mini,
|
|
26
24
|
width: k = t.width,
|
|
27
25
|
miniWidth: x = t.miniWidth,
|
|
28
|
-
items:
|
|
26
|
+
items: i,
|
|
29
27
|
item: N,
|
|
30
|
-
tabIndex:
|
|
31
|
-
onOverlayClick:
|
|
28
|
+
tabIndex: C,
|
|
29
|
+
onOverlayClick: E,
|
|
32
30
|
onSelect: s
|
|
33
|
-
} = d,
|
|
34
|
-
|
|
31
|
+
} = d, r = n.useRef(null), g = n.useCallback(() => {
|
|
32
|
+
r.current && r.current.focus();
|
|
35
33
|
}, []);
|
|
36
|
-
|
|
37
|
-
|
|
34
|
+
n.useImperativeHandle(
|
|
35
|
+
p,
|
|
38
36
|
() => ({
|
|
39
|
-
element:
|
|
40
|
-
focus:
|
|
37
|
+
element: r.current,
|
|
38
|
+
focus: g
|
|
41
39
|
})
|
|
42
40
|
);
|
|
43
|
-
const D =
|
|
44
|
-
(
|
|
45
|
-
if (
|
|
46
|
-
const
|
|
47
|
-
itemTarget:
|
|
48
|
-
itemIndex:
|
|
41
|
+
const D = n.useCallback(
|
|
42
|
+
(S, W, m) => {
|
|
43
|
+
if (i && s) {
|
|
44
|
+
const I = {
|
|
45
|
+
itemTarget: S,
|
|
46
|
+
itemIndex: W,
|
|
49
47
|
syntheticEvent: m,
|
|
50
48
|
nativeEvent: m && m.nativeEvent,
|
|
51
49
|
target: void 0
|
|
52
50
|
};
|
|
53
|
-
s.call(void 0,
|
|
51
|
+
s.call(void 0, I);
|
|
54
52
|
}
|
|
55
53
|
},
|
|
56
|
-
[
|
|
57
|
-
), c =
|
|
54
|
+
[i, s]
|
|
55
|
+
), c = T(r, d.dir), R = j(
|
|
58
56
|
{
|
|
59
57
|
"k-drawer-container": !0,
|
|
60
|
-
"k-drawer-expanded":
|
|
58
|
+
"k-drawer-expanded": a,
|
|
61
59
|
"k-drawer-overlay": o === "overlay",
|
|
62
60
|
"k-drawer-push": o === "push",
|
|
63
|
-
"k-drawer-mini": l && !
|
|
61
|
+
"k-drawer-mini": l && !a
|
|
64
62
|
},
|
|
65
63
|
v
|
|
66
64
|
);
|
|
67
|
-
return /* @__PURE__ */
|
|
68
|
-
|
|
65
|
+
return /* @__PURE__ */ n.createElement(
|
|
66
|
+
P.Provider,
|
|
69
67
|
{
|
|
70
68
|
value: {
|
|
71
69
|
animation: b,
|
|
72
|
-
expanded:
|
|
70
|
+
expanded: a,
|
|
73
71
|
mode: o,
|
|
74
72
|
position: f,
|
|
75
73
|
mini: l,
|
|
76
74
|
dir: c,
|
|
77
|
-
items:
|
|
75
|
+
items: i,
|
|
78
76
|
item: N,
|
|
79
77
|
width: k,
|
|
80
78
|
miniWidth: x,
|
|
81
|
-
onOverlayClick:
|
|
79
|
+
onOverlayClick: E,
|
|
82
80
|
onSelect: D
|
|
83
81
|
}
|
|
84
82
|
},
|
|
85
|
-
/* @__PURE__ */
|
|
83
|
+
/* @__PURE__ */ n.createElement("div", { className: R, ref: r, dir: c, style: y, tabIndex: C }, i && /* @__PURE__ */ n.createElement(O, { className: w }), h)
|
|
86
84
|
);
|
|
87
85
|
});
|
|
88
|
-
|
|
86
|
+
u.propTypes = {
|
|
89
87
|
animation: e.any,
|
|
90
88
|
expanded: e.bool,
|
|
91
89
|
children: e.any,
|
|
@@ -111,7 +109,7 @@ const t = {
|
|
|
111
109
|
width: 240,
|
|
112
110
|
miniWidth: 48
|
|
113
111
|
};
|
|
114
|
-
|
|
112
|
+
u.displayName = "KendoDrawer";
|
|
115
113
|
export {
|
|
116
|
-
|
|
114
|
+
u as Drawer
|
|
117
115
|
};
|
|
@@ -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
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const $=require("react"),u=require("prop-types"),G=require("./context/DrawerContext.js"),J=require("./DrawerItem.js"),w=require("@progress/kendo-react-common");function Q(a){const l=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(a){for(const o in a)if(o!=="default"){const d=Object.getOwnPropertyDescriptor(a,o);Object.defineProperty(l,o,d.get?d:{enumerable:!0,get:()=>a[o]})}}return l.default=a,Object.freeze(l)}const t=Q($),V=240,Y=50,Z={type:"slide",duration:200},ee={type:"slide",duration:0},b=t.forwardRef((a,l)=>{const{children:o,className:d,style:k}=a,{animation:y,expanded:v,mode:p,position:c,onOverlayClick:C,mini:i,dir:N,width:D,miniWidth:g,items:T,item:A,onSelect:W}=t.useContext(G.DrawerContext),m=t.useRef(null),_=t.useCallback(()=>{m.current&&m.current.focus()},[]),e=typeof y!="boolean"?y:y===!1?ee:Z,I=D||V,E=g||Y;t.useImperativeHandle(l,()=>({element:m.current,focus:_}));const M=t.useMemo(()=>"k-drawer "+w.classNames({"k-drawer-start":c==="start","k-drawer-end":c==="end"},d),[c]),P={opacity:1,flexBasis:I,WebkitTransition:"all "+(e&&e.duration)+"ms",transition:"all "+(e&&e.duration)+"ms"},R={opacity:1,transform:"translateX(0px)",WebkitTransition:"all "+(e&&e.duration)+"ms",transition:"all "+(e&&e.duration)+"ms"},j={opacity:i?1:0,flexBasis:i?E:0,WebkitTransition:"all "+(e&&e.duration)+"ms",transition:"all "+(e&&e.duration)+"ms"},S={opacity:0,transform:"translateX(-100%)",WebkitTransition:"all "+(e&&e.duration)+"ms",transition:"all "+(e&&e.duration)+"ms"},q={opacity:0,transform:"translateX(100%)",WebkitTransition:"all "+(e&&e.duration)+"ms",transition:"all "+(e&&e.duration)+"ms"},O={transform:"translateX(0%)",WebkitTransitionDuration:(e&&e.duration)+"ms",transitionDuration:(e&&e.duration)+"ms"},X=v?p==="push"?P:R:p==="push"?j:N==="ltr"&&c==="start"||N==="rtl"&&c==="end"?i?O:S:i?O:q,h=t.useMemo(()=>new w.Navigation({root:m,selectors:["ul.k-drawer-items li.k-drawer-item:not(.k-drawer-separator)"],keyboardEvents:{keydown:{ArrowDown:(n,r,s)=>{s.preventDefault(),r.focusNext(n)},ArrowUp:(n,r,s)=>{s.preventDefault(),r.focusPrevious(n)},Enter:(n,r,s)=>{s.preventDefault(),n.click()}}},tabIndex:0,rovingTabIndex:!0}),[]),F=t.useCallback(h.triggerKeyboardEvent.bind(h),[]),L=T&&t.createElement("ul",{className:"k-drawer-items",role:"menubar","aria-orientation":"vertical",onKeyDown:F},T.map((n,r)=>{const{className:s,level:f,...U}=n,H=f!=null?f:0,K=w.classNames(s,i?"":`k-level-${H}`),B={index:r,className:K,...U,onSelect:W},z=A||J.DrawerItem;return t.createElement(z,{key:r,...B})})),x=t.createElement("div",{style:e?{...X,...k}:k,className:M,ref:m},t.createElement("div",{className:"k-drawer-wrapper",style:!v&&i&&p==="overlay"?{width:E}:{width:I}},L||o));return p==="overlay"?t.createElement(t.Fragment,null,v&&t.createElement("div",{className:"k-overlay",onClick:C}),x):x});b.propTypes={children:u.any,className:u.string,style:u.object,item:u.any,tabIndex:u.number};b.displayName="KendoDrawerNavigation";exports.DrawerNavigation=b;
|
|
@@ -5,41 +5,38 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import * as
|
|
8
|
+
import * as e from "react";
|
|
9
9
|
import l from "prop-types";
|
|
10
|
-
import { DrawerContext as
|
|
11
|
-
import { DrawerItem as
|
|
12
|
-
import {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
const { children: x, className: A, style: p } = g;
|
|
17
|
-
Q(E);
|
|
18
|
-
const C = Y(E), {
|
|
10
|
+
import { DrawerContext as z } from "./context/DrawerContext.mjs";
|
|
11
|
+
import { DrawerItem as G } from "./DrawerItem.mjs";
|
|
12
|
+
import { classNames as T, Navigation as J } from "@progress/kendo-react-common";
|
|
13
|
+
const Q = 240, V = 50, Y = { type: "slide", duration: 200 }, Z = { type: "slide", duration: 0 }, E = e.forwardRef(
|
|
14
|
+
(h, g) => {
|
|
15
|
+
const { children: x, className: A, style: p } = h, {
|
|
19
16
|
animation: m,
|
|
20
17
|
expanded: d,
|
|
21
18
|
mode: c,
|
|
22
19
|
position: o,
|
|
23
|
-
onOverlayClick:
|
|
20
|
+
onOverlayClick: W,
|
|
24
21
|
mini: s,
|
|
25
22
|
dir: v,
|
|
26
23
|
width: y,
|
|
27
|
-
miniWidth:
|
|
28
|
-
items:
|
|
29
|
-
item:
|
|
30
|
-
onSelect:
|
|
31
|
-
} =
|
|
24
|
+
miniWidth: f,
|
|
25
|
+
items: w,
|
|
26
|
+
item: C,
|
|
27
|
+
onSelect: O
|
|
28
|
+
} = e.useContext(z), i = e.useRef(null), M = e.useCallback(() => {
|
|
32
29
|
i.current && i.current.focus();
|
|
33
|
-
}, []),
|
|
34
|
-
|
|
35
|
-
|
|
30
|
+
}, []), t = typeof m != "boolean" ? m : m === !1 ? Z : Y, k = y || Q, N = f || V;
|
|
31
|
+
e.useImperativeHandle(
|
|
32
|
+
g,
|
|
36
33
|
() => ({
|
|
37
34
|
element: i.current,
|
|
38
|
-
focus:
|
|
35
|
+
focus: M
|
|
39
36
|
})
|
|
40
37
|
);
|
|
41
|
-
const
|
|
42
|
-
() => "k-drawer " +
|
|
38
|
+
const _ = e.useMemo(
|
|
39
|
+
() => "k-drawer " + T(
|
|
43
40
|
{
|
|
44
41
|
"k-drawer-start": o === "start",
|
|
45
42
|
"k-drawer-end": o === "end"
|
|
@@ -47,49 +44,49 @@ const te = 240, ae = 50, re = { type: "slide", duration: 200 }, ne = { type: "sl
|
|
|
47
44
|
A
|
|
48
45
|
),
|
|
49
46
|
[o]
|
|
50
|
-
),
|
|
47
|
+
), P = {
|
|
51
48
|
opacity: 1,
|
|
52
49
|
flexBasis: k,
|
|
53
|
-
WebkitTransition: "all " + (
|
|
54
|
-
transition: "all " + (
|
|
55
|
-
},
|
|
50
|
+
WebkitTransition: "all " + (t && t.duration) + "ms",
|
|
51
|
+
transition: "all " + (t && t.duration) + "ms"
|
|
52
|
+
}, R = {
|
|
56
53
|
opacity: 1,
|
|
57
54
|
transform: "translateX(0px)",
|
|
58
|
-
WebkitTransition: "all " + (
|
|
59
|
-
transition: "all " + (
|
|
55
|
+
WebkitTransition: "all " + (t && t.duration) + "ms",
|
|
56
|
+
transition: "all " + (t && t.duration) + "ms"
|
|
60
57
|
}, X = {
|
|
61
58
|
opacity: s ? 1 : 0,
|
|
62
59
|
flexBasis: s ? N : 0,
|
|
63
|
-
WebkitTransition: "all " + (
|
|
64
|
-
transition: "all " + (
|
|
60
|
+
WebkitTransition: "all " + (t && t.duration) + "ms",
|
|
61
|
+
transition: "all " + (t && t.duration) + "ms"
|
|
65
62
|
}, F = {
|
|
66
63
|
opacity: 0,
|
|
67
64
|
transform: "translateX(-100%)",
|
|
68
|
-
WebkitTransition: "all " + (
|
|
69
|
-
transition: "all " + (
|
|
70
|
-
},
|
|
65
|
+
WebkitTransition: "all " + (t && t.duration) + "ms",
|
|
66
|
+
transition: "all " + (t && t.duration) + "ms"
|
|
67
|
+
}, L = {
|
|
71
68
|
opacity: 0,
|
|
72
69
|
transform: "translateX(100%)",
|
|
73
|
-
WebkitTransition: "all " + (
|
|
74
|
-
transition: "all " + (
|
|
70
|
+
WebkitTransition: "all " + (t && t.duration) + "ms",
|
|
71
|
+
transition: "all " + (t && t.duration) + "ms"
|
|
75
72
|
}, b = {
|
|
76
73
|
transform: "translateX(0%)",
|
|
77
|
-
WebkitTransitionDuration: (
|
|
78
|
-
transitionDuration: (
|
|
79
|
-
},
|
|
80
|
-
() => new
|
|
74
|
+
WebkitTransitionDuration: (t && t.duration) + "ms",
|
|
75
|
+
transitionDuration: (t && t.duration) + "ms"
|
|
76
|
+
}, U = d ? c === "push" ? P : R : c === "push" ? X : v === "ltr" && o === "start" || v === "rtl" && o === "end" ? s ? b : F : s ? b : L, D = e.useMemo(
|
|
77
|
+
() => new J({
|
|
81
78
|
root: i,
|
|
82
79
|
selectors: ["ul.k-drawer-items li.k-drawer-item:not(.k-drawer-separator)"],
|
|
83
80
|
keyboardEvents: {
|
|
84
81
|
keydown: {
|
|
85
|
-
ArrowDown: (a,
|
|
86
|
-
|
|
82
|
+
ArrowDown: (a, n, r) => {
|
|
83
|
+
r.preventDefault(), n.focusNext(a);
|
|
87
84
|
},
|
|
88
|
-
ArrowUp: (a,
|
|
89
|
-
|
|
85
|
+
ArrowUp: (a, n, r) => {
|
|
86
|
+
r.preventDefault(), n.focusPrevious(a);
|
|
90
87
|
},
|
|
91
|
-
Enter: (a,
|
|
92
|
-
|
|
88
|
+
Enter: (a, n, r) => {
|
|
89
|
+
r.preventDefault(), a.click();
|
|
93
90
|
}
|
|
94
91
|
}
|
|
95
92
|
},
|
|
@@ -97,42 +94,41 @@ const te = 240, ae = 50, re = { type: "slide", duration: 200 }, ne = { type: "sl
|
|
|
97
94
|
rovingTabIndex: !0
|
|
98
95
|
}),
|
|
99
96
|
[]
|
|
100
|
-
),
|
|
101
|
-
const { className:
|
|
102
|
-
index:
|
|
103
|
-
className:
|
|
104
|
-
...
|
|
105
|
-
onSelect:
|
|
106
|
-
},
|
|
107
|
-
return /* @__PURE__ */
|
|
108
|
-
})), I = /* @__PURE__ */
|
|
97
|
+
), H = e.useCallback(D.triggerKeyboardEvent.bind(D), []), K = w && /* @__PURE__ */ e.createElement("ul", { className: "k-drawer-items", role: "menubar", "aria-orientation": "vertical", onKeyDown: H }, w.map((a, n) => {
|
|
98
|
+
const { className: r, level: u, ...B } = a, S = u != null ? u : 0, j = T(r, s ? "" : `k-level-${S}`), $ = {
|
|
99
|
+
index: n,
|
|
100
|
+
className: j,
|
|
101
|
+
...B,
|
|
102
|
+
onSelect: O
|
|
103
|
+
}, q = C || G;
|
|
104
|
+
return /* @__PURE__ */ e.createElement(q, { key: n, ...$ });
|
|
105
|
+
})), I = /* @__PURE__ */ e.createElement(
|
|
109
106
|
"div",
|
|
110
107
|
{
|
|
111
|
-
style:
|
|
112
|
-
className:
|
|
108
|
+
style: t ? { ...U, ...p } : p,
|
|
109
|
+
className: _,
|
|
113
110
|
ref: i
|
|
114
111
|
},
|
|
115
|
-
/* @__PURE__ */
|
|
112
|
+
/* @__PURE__ */ e.createElement(
|
|
116
113
|
"div",
|
|
117
114
|
{
|
|
118
115
|
className: "k-drawer-wrapper",
|
|
119
116
|
style: !d && s && c === "overlay" ? { width: N } : { width: k }
|
|
120
117
|
},
|
|
121
|
-
|
|
122
|
-
)
|
|
123
|
-
C && /* @__PURE__ */ t.createElement(ee, null)
|
|
118
|
+
K || x
|
|
119
|
+
)
|
|
124
120
|
);
|
|
125
|
-
return c === "overlay" ? /* @__PURE__ */
|
|
121
|
+
return c === "overlay" ? /* @__PURE__ */ e.createElement(e.Fragment, null, d && /* @__PURE__ */ e.createElement("div", { className: "k-overlay", onClick: W }), I) : I;
|
|
126
122
|
}
|
|
127
123
|
);
|
|
128
|
-
|
|
124
|
+
E.propTypes = {
|
|
129
125
|
children: l.any,
|
|
130
126
|
className: l.string,
|
|
131
127
|
style: l.object,
|
|
132
128
|
item: l.any,
|
|
133
129
|
tabIndex: l.number
|
|
134
130
|
};
|
|
135
|
-
|
|
131
|
+
E.displayName = "KendoDrawerNavigation";
|
|
136
132
|
export {
|
|
137
|
-
|
|
133
|
+
E as DrawerNavigation
|
|
138
134
|
};
|
|
@@ -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
|
|
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;
|
|
@@ -6,78 +6,76 @@
|
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
8
|
import * as e from "react";
|
|
9
|
-
import
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
|
|
13
|
-
const
|
|
14
|
-
w(P);
|
|
15
|
-
const i = e.useRef(null), [g, u] = e.useState(!1), r = e.useCallback(() => ({ element: i.current }), []);
|
|
9
|
+
import n from "prop-types";
|
|
10
|
+
import { dispatchEvent as k, Keys as p, useAsyncFocusBlur as w, classNames as v, useRtl as F, 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 }), []);
|
|
16
14
|
e.useImperativeHandle(y, r);
|
|
17
15
|
const {
|
|
18
16
|
expanded: o = !1,
|
|
19
|
-
disabled:
|
|
17
|
+
disabled: l,
|
|
20
18
|
title: m,
|
|
21
19
|
subtitle: b,
|
|
22
20
|
onAction: s,
|
|
23
21
|
expandIcon: d,
|
|
24
22
|
collapseIcon: c,
|
|
25
23
|
expandSVGIcon: f,
|
|
26
|
-
collapseSVGIcon:
|
|
27
|
-
} =
|
|
28
|
-
(
|
|
29
|
-
|
|
24
|
+
collapseSVGIcon: x
|
|
25
|
+
} = a, h = e.useCallback(
|
|
26
|
+
(t) => {
|
|
27
|
+
k(s, t, r(), {
|
|
30
28
|
expanded: o
|
|
31
29
|
});
|
|
32
30
|
},
|
|
33
31
|
[s, o]
|
|
34
|
-
),
|
|
35
|
-
(
|
|
36
|
-
(
|
|
32
|
+
), C = e.useCallback(
|
|
33
|
+
(t) => {
|
|
34
|
+
(t.keyCode === p.enter || t.keyCode === p.space) && (t.preventDefault(), k(s, t, r(), {
|
|
37
35
|
expanded: o
|
|
38
36
|
}));
|
|
39
37
|
},
|
|
40
38
|
[s, o]
|
|
41
|
-
),
|
|
42
|
-
|
|
43
|
-
}, [
|
|
44
|
-
|
|
45
|
-
}, [
|
|
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 });
|
|
46
44
|
return /* @__PURE__ */ e.createElement(
|
|
47
45
|
"div",
|
|
48
46
|
{
|
|
49
47
|
ref: i,
|
|
50
|
-
className: v("k-expander",
|
|
48
|
+
className: v("k-expander", a.className, {
|
|
51
49
|
"k-expanded": o,
|
|
52
|
-
"k-focus":
|
|
53
|
-
"k-disabled":
|
|
50
|
+
"k-focus": N && !l,
|
|
51
|
+
"k-disabled": l
|
|
54
52
|
}),
|
|
55
53
|
onFocus: B,
|
|
56
54
|
onBlur: R,
|
|
57
|
-
style:
|
|
58
|
-
id:
|
|
59
|
-
dir:
|
|
60
|
-
onKeyDown:
|
|
55
|
+
style: a.style,
|
|
56
|
+
id: a.id,
|
|
57
|
+
dir: F(i, a.dir),
|
|
58
|
+
onKeyDown: l ? void 0 : C
|
|
61
59
|
},
|
|
62
60
|
/* @__PURE__ */ e.createElement(
|
|
63
61
|
"div",
|
|
64
62
|
{
|
|
65
63
|
role: "button",
|
|
66
|
-
"aria-controls":
|
|
64
|
+
"aria-controls": a.ariaControls,
|
|
67
65
|
"aria-expanded": o,
|
|
68
|
-
"aria-disabled":
|
|
69
|
-
tabIndex:
|
|
66
|
+
"aria-disabled": l,
|
|
67
|
+
tabIndex: S(a.tabIndex, l),
|
|
70
68
|
className: "k-expander-header",
|
|
71
|
-
onClick:
|
|
69
|
+
onClick: l ? void 0 : h
|
|
72
70
|
},
|
|
73
71
|
m !== void 0 ? /* @__PURE__ */ e.createElement("div", { className: "k-expander-title" }, m) : void 0,
|
|
74
72
|
/* @__PURE__ */ e.createElement("span", { className: "k-spacer" }),
|
|
75
73
|
b !== void 0 ? /* @__PURE__ */ e.createElement("div", { className: "k-expander-sub-title" }, b) : void 0,
|
|
76
74
|
/* @__PURE__ */ e.createElement("span", { className: "k-expander-indicator" }, /* @__PURE__ */ e.createElement(
|
|
77
|
-
|
|
75
|
+
D,
|
|
78
76
|
{
|
|
79
77
|
name: o ? c ? void 0 : "chevron-up" : d ? void 0 : "chevron-down",
|
|
80
|
-
icon: o ? !
|
|
78
|
+
icon: o ? !x && !c ? A : x : !f && !d ? K : f,
|
|
81
79
|
className: v(
|
|
82
80
|
o ? {
|
|
83
81
|
[String(c)]: !!c
|
|
@@ -88,23 +86,23 @@ const I = e.forwardRef((n, y) => {
|
|
|
88
86
|
}
|
|
89
87
|
))
|
|
90
88
|
),
|
|
91
|
-
|
|
89
|
+
a.children
|
|
92
90
|
);
|
|
93
91
|
});
|
|
94
92
|
I.propTypes = {
|
|
95
|
-
children:
|
|
96
|
-
className:
|
|
97
|
-
style:
|
|
98
|
-
dir:
|
|
99
|
-
id:
|
|
100
|
-
tabIndex:
|
|
101
|
-
title:
|
|
102
|
-
subtitle:
|
|
103
|
-
expandIcon:
|
|
104
|
-
collapseIcon:
|
|
105
|
-
expanded:
|
|
106
|
-
disabled:
|
|
107
|
-
onAction:
|
|
93
|
+
children: n.node,
|
|
94
|
+
className: n.string,
|
|
95
|
+
style: n.object,
|
|
96
|
+
dir: n.string,
|
|
97
|
+
id: n.string,
|
|
98
|
+
tabIndex: n.number,
|
|
99
|
+
title: n.node,
|
|
100
|
+
subtitle: n.node,
|
|
101
|
+
expandIcon: n.string,
|
|
102
|
+
collapseIcon: n.string,
|
|
103
|
+
expanded: n.bool,
|
|
104
|
+
disabled: n.bool,
|
|
105
|
+
onAction: n.func
|
|
108
106
|
};
|
|
109
107
|
I.displayName = "KendoReactExpansionPanel";
|
|
110
108
|
export {
|
package/gridlayout/GridLayout.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 O=require("react"),t=require("prop-types"),
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const O=require("react"),t=require("prop-types"),d=require("@progress/kendo-react-common");function T(e){const l=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const i in e)if(i!=="default"){const c=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(l,i,c.get?c:{enumerable:!0,get:()=>e[i]})}}return l.default=e,Object.freeze(l)}const n=T(O),m=n.forwardRef((e,l)=>{const i=n.useRef(null),c=n.useCallback(()=>({element:i.current}),[]);n.useImperativeHandle(l,c);const{className:u,style:y,id:f,children:h,gap:s=g.gap}=e,b=d.useId(),o=n.useMemo(()=>e.align&&e.align.horizontal?e.align.horizontal:g.hAlign,[e.align]),r=n.useMemo(()=>e.align&&e.align.vertical?e.align.vertical:g.vAlign,[e.align]),p=n.useMemo(()=>d.classNames("k-grid-layout",{"k-justify-items-start":o==="start","k-justify-items-center":o==="center","k-justify-items-end":o==="end","k-justify-items-stretch":o==="stretch","k-align-items-start":r==="top","k-align-items-center":r==="middle","k-align-items-end":r==="bottom","k-align-items-stretch":r==="stretch"},u),[o,r,u]),v=s?`${typeof s.rows=="number"?s.rows+"px":s.rows} ${typeof s.cols=="number"?s.cols+"px":s.cols}`:void 0,j=e.rows&&e.rows.map(a=>`${typeof a.height=="number"?a.height+"px":a.height}`).join(" "),k=e.cols&&e.cols.map(a=>`${typeof a.width=="number"?a.width+"px":a.width}`).join(" "),w={gap:v,gridTemplateColumns:k,gridTemplateRows:j,...y};return n.createElement("div",{ref:i,className:p,style:w,id:f||b},h)}),g={hAlign:"stretch",vAlign:"stretch",gap:void 0};m.propTypes={className:t.string,style:t.object,children:t.any,id:t.string,gap:t.shape({rows:t.oneOfType([t.string,t.number]),columns:t.oneOfType([t.string,t.number])}),align:t.shape({vertical:t.oneOf(["top","middle","bottom","stretch"]),horizontal:t.oneOf(["start","center","end","stretch"])})};m.displayName="KendoReactGridLayout";exports.GridLayout=m;
|
|
@@ -5,33 +5,31 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import * as
|
|
8
|
+
import * as s from "react";
|
|
9
9
|
import e from "prop-types";
|
|
10
|
-
import {
|
|
11
|
-
|
|
12
|
-
const
|
|
13
|
-
j(T);
|
|
14
|
-
const r = a.useRef(null), d = a.useCallback(
|
|
10
|
+
import { useId as T, classNames as j } from "@progress/kendo-react-common";
|
|
11
|
+
const c = s.forwardRef((t, g) => {
|
|
12
|
+
const r = s.useRef(null), d = s.useCallback(
|
|
15
13
|
() => ({
|
|
16
14
|
element: r.current
|
|
17
15
|
}),
|
|
18
16
|
[]
|
|
19
17
|
);
|
|
20
|
-
|
|
21
|
-
const { className: m, style: u, id: h, children: y, gap: i = o.gap } = t, f =
|
|
18
|
+
s.useImperativeHandle(g, d);
|
|
19
|
+
const { className: m, style: u, id: h, children: y, gap: i = o.gap } = t, f = T(), a = s.useMemo(
|
|
22
20
|
() => t.align && t.align.horizontal ? t.align.horizontal : o.hAlign,
|
|
23
21
|
[t.align]
|
|
24
|
-
), l =
|
|
22
|
+
), l = s.useMemo(
|
|
25
23
|
() => t.align && t.align.vertical ? t.align.vertical : o.vAlign,
|
|
26
24
|
[t.align]
|
|
27
|
-
), p =
|
|
28
|
-
() =>
|
|
25
|
+
), p = s.useMemo(
|
|
26
|
+
() => j(
|
|
29
27
|
"k-grid-layout",
|
|
30
28
|
{
|
|
31
|
-
"k-justify-items-start":
|
|
32
|
-
"k-justify-items-center":
|
|
33
|
-
"k-justify-items-end":
|
|
34
|
-
"k-justify-items-stretch":
|
|
29
|
+
"k-justify-items-start": a === "start",
|
|
30
|
+
"k-justify-items-center": a === "center",
|
|
31
|
+
"k-justify-items-end": a === "end",
|
|
32
|
+
"k-justify-items-stretch": a === "stretch",
|
|
35
33
|
"k-align-items-start": l === "top",
|
|
36
34
|
"k-align-items-center": l === "middle",
|
|
37
35
|
"k-align-items-end": l === "bottom",
|
|
@@ -39,14 +37,14 @@ const c = a.forwardRef((t, g) => {
|
|
|
39
37
|
},
|
|
40
38
|
m
|
|
41
39
|
),
|
|
42
|
-
[
|
|
43
|
-
),
|
|
44
|
-
gap:
|
|
45
|
-
gridTemplateColumns:
|
|
46
|
-
gridTemplateRows:
|
|
40
|
+
[a, l, m]
|
|
41
|
+
), v = i ? `${typeof i.rows == "number" ? i.rows + "px" : i.rows} ${typeof i.cols == "number" ? i.cols + "px" : i.cols}` : void 0, b = t.rows && t.rows.map((n) => `${typeof n.height == "number" ? n.height + "px" : n.height}`).join(" "), k = t.cols && t.cols.map((n) => `${typeof n.width == "number" ? n.width + "px" : n.width}`).join(" "), w = {
|
|
42
|
+
gap: v,
|
|
43
|
+
gridTemplateColumns: k,
|
|
44
|
+
gridTemplateRows: b,
|
|
47
45
|
...u
|
|
48
46
|
};
|
|
49
|
-
return /* @__PURE__ */
|
|
47
|
+
return /* @__PURE__ */ s.createElement("div", { ref: r, className: p, style: w, id: h || f }, y);
|
|
50
48
|
}), o = {
|
|
51
49
|
hAlign: "stretch",
|
|
52
50
|
vAlign: "stretch",
|