@progress/kendo-react-layout 8.1.0-develop.22 → 8.1.0-develop.24
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/bottomnavigation/BottomNavigation.js +1 -1
- package/bottomnavigation/BottomNavigation.mjs +36 -37
- package/bottomnavigation/BottomNavigationItem.js +1 -1
- package/bottomnavigation/BottomNavigationItem.mjs +33 -34
- package/breadcrumb/Breadcrumb.js +1 -1
- package/breadcrumb/Breadcrumb.mjs +34 -35
- package/card/Card.js +1 -1
- package/card/Card.mjs +28 -20
- package/dist/cdn/js/kendo-react-layout.js +1 -1
- package/drawer/Drawer.js +1 -1
- package/drawer/Drawer.mjs +65 -65
- package/gridlayout/GridLayout.js +1 -1
- package/gridlayout/GridLayout.mjs +11 -12
- package/package-metadata.mjs +1 -1
- package/package.json +6 -6
- package/stacklayout/StackLayout.js +1 -1
- package/stacklayout/StackLayout.mjs +13 -14
- package/stepper/Step.js +1 -1
- package/stepper/Step.mjs +43 -44
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 client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const R=require("react"),e=require("prop-types"),I=require("./context/DrawerContext.js"),M=require("./DrawerNavigation.js"),u=require("@progress/kendo-react-common"),T=require("../package-metadata.js");function W(a){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(a){for(const t in a)if(t!=="default"){const i=Object.getOwnPropertyDescriptor(a,t);Object.defineProperty(o,t,i.get?i:{enumerable:!0,get:()=>a[t]})}}return o.default=a,Object.freeze(o)}const n=W(R),m=n.forwardRef((a,o)=>{u.validatePackage(T.packageMetadata);const{expanded:t=r.expanded,mode:i=r.mode,position:v=r.position,className:b,children:w,style:y,animation:g=r.animation,mini:p=r.mini,width:h=r.width,miniWidth:k=r.miniWidth,dir:D=r.dir,items:s,item:x,tabIndex:N,onOverlayClick:C,onSelect:l}=a,c=n.useRef(null),O=n.useCallback(()=>{c.current&&c.current.focus()},[]);n.useImperativeHandle(o,()=>({element:c.current,focus:O}));const S=n.useCallback((P,j,d)=>{if(s&&l){const q={itemTarget:P,itemIndex:j,syntheticEvent:d,nativeEvent:d&&d.nativeEvent,target:void 0};l.call(void 0,q)}},[s,l]),f=u.useDir(c,D),E=u.classNames({"k-drawer-container":!0,"k-drawer-expanded":t,"k-drawer-overlay":i==="overlay","k-drawer-push":i==="push","k-drawer-mini":p&&!t},b);return n.createElement(I.DrawerContext.Provider,{value:{animation:g,expanded:t,mode:i,position:v,mini:p,dir:f,items:s,item:x,width:h,miniWidth:k,onOverlayClick:C,onSelect:S}},n.createElement("div",{className:E,ref:c,dir:f,style:y,tabIndex:N},s&&n.createElement(M.DrawerNavigation,null),w))});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 r={animation:!0,expanded:!1,mode:"overlay",position:"start",mini:!1,dir:"ltr",width:240,miniWidth:48};m.displayName="KendoDrawer";exports.Drawer=m;
|
package/drawer/Drawer.mjs
CHANGED
|
@@ -8,95 +8,96 @@
|
|
|
8
8
|
"use client";
|
|
9
9
|
import * as t from "react";
|
|
10
10
|
import e from "prop-types";
|
|
11
|
-
import { DrawerContext as
|
|
12
|
-
import { DrawerNavigation as
|
|
13
|
-
import { validatePackage as
|
|
14
|
-
import { packageMetadata as
|
|
15
|
-
const
|
|
16
|
-
|
|
11
|
+
import { DrawerContext as W } from "./context/DrawerContext.mjs";
|
|
12
|
+
import { DrawerNavigation as O } from "./DrawerNavigation.mjs";
|
|
13
|
+
import { validatePackage as T, useDir as j, classNames as H } from "@progress/kendo-react-common";
|
|
14
|
+
import { packageMetadata as K } from "../package-metadata.mjs";
|
|
15
|
+
const c = t.forwardRef((p, u) => {
|
|
16
|
+
T(K);
|
|
17
17
|
const {
|
|
18
|
-
expanded:
|
|
19
|
-
mode: i,
|
|
20
|
-
position:
|
|
21
|
-
className:
|
|
22
|
-
children:
|
|
23
|
-
style:
|
|
24
|
-
animation: y,
|
|
25
|
-
mini:
|
|
26
|
-
width:
|
|
27
|
-
miniWidth:
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
18
|
+
expanded: a = i.expanded,
|
|
19
|
+
mode: o = i.mode,
|
|
20
|
+
position: f = i.position,
|
|
21
|
+
className: v,
|
|
22
|
+
children: w,
|
|
23
|
+
style: h,
|
|
24
|
+
animation: y = i.animation,
|
|
25
|
+
mini: l = i.mini,
|
|
26
|
+
width: b = i.width,
|
|
27
|
+
miniWidth: k = i.miniWidth,
|
|
28
|
+
dir: x = i.dir,
|
|
29
|
+
items: r,
|
|
30
|
+
item: g,
|
|
31
|
+
tabIndex: E,
|
|
32
|
+
onOverlayClick: N,
|
|
33
|
+
onSelect: s
|
|
34
|
+
} = p, n = t.useRef(null), C = t.useCallback(
|
|
34
35
|
() => {
|
|
35
|
-
|
|
36
|
+
n.current && n.current.focus();
|
|
36
37
|
},
|
|
37
38
|
[]
|
|
38
39
|
);
|
|
39
40
|
t.useImperativeHandle(u, () => ({
|
|
40
|
-
element:
|
|
41
|
-
focus:
|
|
41
|
+
element: n.current,
|
|
42
|
+
focus: C
|
|
42
43
|
}));
|
|
43
|
-
const
|
|
44
|
-
(
|
|
45
|
-
if (
|
|
46
|
-
const
|
|
47
|
-
itemTarget:
|
|
48
|
-
itemIndex:
|
|
49
|
-
syntheticEvent:
|
|
50
|
-
nativeEvent:
|
|
44
|
+
const D = t.useCallback(
|
|
45
|
+
(P, R, d) => {
|
|
46
|
+
if (r && s) {
|
|
47
|
+
const S = {
|
|
48
|
+
itemTarget: P,
|
|
49
|
+
itemIndex: R,
|
|
50
|
+
syntheticEvent: d,
|
|
51
|
+
nativeEvent: d && d.nativeEvent,
|
|
51
52
|
target: void 0
|
|
52
53
|
};
|
|
53
|
-
|
|
54
|
+
s.call(void 0, S);
|
|
54
55
|
}
|
|
55
56
|
},
|
|
56
|
-
[
|
|
57
|
-
),
|
|
57
|
+
[r, s]
|
|
58
|
+
), m = j(n, x), I = H(
|
|
58
59
|
{
|
|
59
60
|
"k-drawer-container": !0,
|
|
60
|
-
"k-drawer-expanded":
|
|
61
|
-
"k-drawer-overlay":
|
|
62
|
-
"k-drawer-push":
|
|
63
|
-
"k-drawer-mini":
|
|
61
|
+
"k-drawer-expanded": a,
|
|
62
|
+
"k-drawer-overlay": o === "overlay",
|
|
63
|
+
"k-drawer-push": o === "push",
|
|
64
|
+
"k-drawer-mini": l && !a
|
|
64
65
|
},
|
|
65
|
-
|
|
66
|
+
v
|
|
66
67
|
);
|
|
67
68
|
return /* @__PURE__ */ t.createElement(
|
|
68
|
-
|
|
69
|
+
W.Provider,
|
|
69
70
|
{
|
|
70
71
|
value: {
|
|
71
72
|
animation: y,
|
|
72
|
-
expanded:
|
|
73
|
-
mode:
|
|
74
|
-
position:
|
|
75
|
-
mini:
|
|
76
|
-
dir:
|
|
77
|
-
items:
|
|
78
|
-
item:
|
|
79
|
-
width:
|
|
80
|
-
miniWidth:
|
|
81
|
-
onOverlayClick:
|
|
82
|
-
onSelect:
|
|
73
|
+
expanded: a,
|
|
74
|
+
mode: o,
|
|
75
|
+
position: f,
|
|
76
|
+
mini: l,
|
|
77
|
+
dir: m,
|
|
78
|
+
items: r,
|
|
79
|
+
item: g,
|
|
80
|
+
width: b,
|
|
81
|
+
miniWidth: k,
|
|
82
|
+
onOverlayClick: N,
|
|
83
|
+
onSelect: D
|
|
83
84
|
}
|
|
84
85
|
},
|
|
85
86
|
/* @__PURE__ */ t.createElement(
|
|
86
87
|
"div",
|
|
87
88
|
{
|
|
88
|
-
className:
|
|
89
|
-
ref:
|
|
90
|
-
dir:
|
|
91
|
-
style:
|
|
92
|
-
tabIndex:
|
|
89
|
+
className: I,
|
|
90
|
+
ref: n,
|
|
91
|
+
dir: m,
|
|
92
|
+
style: h,
|
|
93
|
+
tabIndex: E
|
|
93
94
|
},
|
|
94
|
-
|
|
95
|
-
|
|
95
|
+
r && /* @__PURE__ */ t.createElement(O, null),
|
|
96
|
+
w
|
|
96
97
|
)
|
|
97
98
|
);
|
|
98
99
|
});
|
|
99
|
-
|
|
100
|
+
c.propTypes = {
|
|
100
101
|
animation: e.any,
|
|
101
102
|
expanded: e.bool,
|
|
102
103
|
children: e.any,
|
|
@@ -113,7 +114,7 @@ l.propTypes = {
|
|
|
113
114
|
onSelect: e.func,
|
|
114
115
|
onOverlayClick: e.func
|
|
115
116
|
};
|
|
116
|
-
const
|
|
117
|
+
const i = {
|
|
117
118
|
animation: !0,
|
|
118
119
|
expanded: !1,
|
|
119
120
|
mode: "overlay",
|
|
@@ -123,8 +124,7 @@ const H = {
|
|
|
123
124
|
width: 240,
|
|
124
125
|
miniWidth: 48
|
|
125
126
|
};
|
|
126
|
-
|
|
127
|
-
l.displayName = "KendoDrawer";
|
|
127
|
+
c.displayName = "KendoDrawer";
|
|
128
128
|
export {
|
|
129
|
-
|
|
129
|
+
c as Drawer
|
|
130
130
|
};
|
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 client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const O=require("react"),t=require("prop-types"),T=require("../package-metadata.js"),
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const O=require("react"),t=require("prop-types"),T=require("../package-metadata.js"),g=require("@progress/kendo-react-common");function R(e){const l=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const a in e)if(a!=="default"){const c=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(l,a,c.get?c:{enumerable:!0,get:()=>e[a]})}}return l.default=e,Object.freeze(l)}const n=R(O),d=n.forwardRef((e,l)=>{g.validatePackage(T.packageMetadata);const a=n.useRef(null),c=n.useCallback(()=>({element:a.current}),[]);n.useImperativeHandle(l,c);const{className:m,style:y,id:f,children:h,gap:i=u.gap}=e,p=g.useId(),o=n.useMemo(()=>e.align&&e.align.horizontal?e.align.horizontal:u.hAlign,[e.align]),r=n.useMemo(()=>e.align&&e.align.vertical?e.align.vertical:u.vAlign,[e.align]),b=n.useMemo(()=>g.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"},m),[o,r,m]),k=i?`${typeof i.rows=="number"?i.rows+"px":i.rows} ${typeof i.cols=="number"?i.cols+"px":i.cols}`:void 0,v=e.rows&&e.rows.map(s=>`${typeof s.height=="number"?s.height+"px":s.height}`).join(" "),j=e.cols&&e.cols.map(s=>`${typeof s.width=="number"?s.width+"px":s.width}`).join(" "),w={gap:k,gridTemplateColumns:j,gridTemplateRows:v,...y};return n.createElement("div",{ref:a,className:b,style:w,id:f||p},h)}),u={hAlign:"stretch",vAlign:"stretch",gap:void 0};d.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"])})};d.displayName="KendoReactGridLayout";exports.GridLayout=d;
|
|
@@ -10,16 +10,16 @@ import * as i from "react";
|
|
|
10
10
|
import e from "prop-types";
|
|
11
11
|
import { packageMetadata as T } from "../package-metadata.mjs";
|
|
12
12
|
import { validatePackage as j, useId as R, classNames as A } from "@progress/kendo-react-common";
|
|
13
|
-
const
|
|
13
|
+
const c = i.forwardRef((t, g) => {
|
|
14
14
|
j(T);
|
|
15
|
-
const
|
|
15
|
+
const r = i.useRef(null), d = i.useCallback(
|
|
16
16
|
() => ({
|
|
17
|
-
element:
|
|
17
|
+
element: r.current
|
|
18
18
|
}),
|
|
19
19
|
[]
|
|
20
20
|
);
|
|
21
21
|
i.useImperativeHandle(g, d);
|
|
22
|
-
const { className:
|
|
22
|
+
const { className: m, style: u, id: h, children: y, gap: a = o.gap } = t, f = R(), n = i.useMemo(
|
|
23
23
|
() => t.align && t.align.horizontal ? t.align.horizontal : o.hAlign,
|
|
24
24
|
[t.align]
|
|
25
25
|
), l = i.useMemo(
|
|
@@ -38,10 +38,10 @@ const r = i.forwardRef((t, g) => {
|
|
|
38
38
|
"k-align-items-end": l === "bottom",
|
|
39
39
|
"k-align-items-stretch": l === "stretch"
|
|
40
40
|
},
|
|
41
|
-
|
|
41
|
+
m
|
|
42
42
|
),
|
|
43
|
-
[n, l,
|
|
44
|
-
), k =
|
|
43
|
+
[n, l, m]
|
|
44
|
+
), k = a ? `${typeof a.rows == "number" ? a.rows + "px" : a.rows} ${typeof a.cols == "number" ? a.cols + "px" : a.cols}` : void 0, v = t.rows && t.rows.map((s) => `${typeof s.height == "number" ? s.height + "px" : s.height}`).join(" "), b = t.cols && t.cols.map((s) => `${typeof s.width == "number" ? s.width + "px" : s.width}`).join(" "), w = {
|
|
45
45
|
gap: k,
|
|
46
46
|
gridTemplateColumns: b,
|
|
47
47
|
gridTemplateRows: v,
|
|
@@ -50,7 +50,7 @@ const r = i.forwardRef((t, g) => {
|
|
|
50
50
|
return /* @__PURE__ */ i.createElement(
|
|
51
51
|
"div",
|
|
52
52
|
{
|
|
53
|
-
ref:
|
|
53
|
+
ref: r,
|
|
54
54
|
className: p,
|
|
55
55
|
style: w,
|
|
56
56
|
id: h || f
|
|
@@ -62,7 +62,7 @@ const r = i.forwardRef((t, g) => {
|
|
|
62
62
|
vAlign: "stretch",
|
|
63
63
|
gap: void 0
|
|
64
64
|
};
|
|
65
|
-
|
|
65
|
+
c.propTypes = {
|
|
66
66
|
className: e.string,
|
|
67
67
|
style: e.object,
|
|
68
68
|
children: e.any,
|
|
@@ -76,8 +76,7 @@ r.propTypes = {
|
|
|
76
76
|
horizontal: e.oneOf(["start", "center", "end", "stretch"])
|
|
77
77
|
})
|
|
78
78
|
};
|
|
79
|
-
|
|
80
|
-
r.displayName = "KendoReactGridLayout";
|
|
79
|
+
c.displayName = "KendoReactGridLayout";
|
|
81
80
|
export {
|
|
82
|
-
|
|
81
|
+
c as GridLayout
|
|
83
82
|
};
|
package/package-metadata.mjs
CHANGED
|
@@ -10,7 +10,7 @@ const e = {
|
|
|
10
10
|
name: "@progress/kendo-react-layout",
|
|
11
11
|
productName: "KendoReact",
|
|
12
12
|
productCodes: ["KENDOUIREACT", "KENDOUICOMPLETE"],
|
|
13
|
-
publishDate:
|
|
13
|
+
publishDate: 1719231009,
|
|
14
14
|
version: "",
|
|
15
15
|
licensingDocsUrl: "https://www.telerik.com/kendo-react-ui/components/my-license/"
|
|
16
16
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@progress/kendo-react-layout",
|
|
3
|
-
"version": "8.1.0-develop.
|
|
3
|
+
"version": "8.1.0-develop.24",
|
|
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",
|
|
@@ -23,11 +23,11 @@
|
|
|
23
23
|
"sideEffects": false,
|
|
24
24
|
"peerDependencies": {
|
|
25
25
|
"@progress/kendo-licensing": "^1.3.4",
|
|
26
|
-
"@progress/kendo-react-animation": "8.1.0-develop.
|
|
27
|
-
"@progress/kendo-react-common": "8.1.0-develop.
|
|
28
|
-
"@progress/kendo-react-intl": "8.1.0-develop.
|
|
29
|
-
"@progress/kendo-react-popup": "8.1.0-develop.
|
|
30
|
-
"@progress/kendo-react-progressbars": "8.1.0-develop.
|
|
26
|
+
"@progress/kendo-react-animation": "8.1.0-develop.24",
|
|
27
|
+
"@progress/kendo-react-common": "8.1.0-develop.24",
|
|
28
|
+
"@progress/kendo-react-intl": "8.1.0-develop.24",
|
|
29
|
+
"@progress/kendo-react-popup": "8.1.0-develop.24",
|
|
30
|
+
"@progress/kendo-react-progressbars": "8.1.0-develop.24",
|
|
31
31
|
"@progress/kendo-svg-icons": "^3.0.0",
|
|
32
32
|
"react": "^16.8.2 || ^17.0.0 || ^18.0.0",
|
|
33
33
|
"react-dom": "^16.8.2 || ^17.0.0 || ^18.0.0"
|
|
@@ -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 client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const j=require("react"),n=require("prop-types"),O=require("../package-metadata.js"),
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const j=require("react"),n=require("prop-types"),O=require("../package-metadata.js"),u=require("@progress/kendo-react-common");function z(t){const s=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const c in t)if(c!=="default"){const l=Object.getOwnPropertyDescriptor(t,c);Object.defineProperty(s,c,l.get?l:{enumerable:!0,get:()=>t[c]})}}return s.default=t,Object.freeze(s)}const i=z(j),d=i.forwardRef((t,s)=>{u.validatePackage(O.packageMetadata);const c=i.useRef(null),l=i.useCallback(()=>({element:c.current}),[]);i.useImperativeHandle(s,l);const{className:m,style:y,id:f,children:k}=t,h=u.useId(),r=i.useMemo(()=>t.orientation||g.orientation,[t.orientation]),e=r==="horizontal",a=i.useMemo(()=>t.align&&t.align.horizontal?t.align.horizontal:g.hAlign,[t.align]),o=i.useMemo(()=>t.align&&t.align.vertical?t.align.vertical:g.vAlign,[t.align]),b=i.useMemo(()=>u.classNames("k-stack-layout",{"k-hstack":r==="horizontal","k-vstack":r==="vertical","k-justify-content-start":e&&a==="start"||!e&&o==="top","k-justify-content-center":e&&a==="center"||!e&&o==="middle","k-justify-content-end":e&&a==="end"||!e&&o==="bottom","k-justify-content-stretch":e&&a==="stretch"||!e&&o==="stretch","k-align-items-start":!e&&a==="start"||e&&o==="top","k-align-items-center":!e&&a==="center"||e&&o==="middle","k-align-items-end":!e&&a==="end"||e&&o==="bottom","k-align-items-stretch":!e&&a==="stretch"||e&&o==="stretch"},m),[r,e,a,o,m]),v={gap:`${typeof t.gap=="number"?t.gap+"px":t.gap}`,...y};return i.createElement("div",{ref:c,className:b,style:v,id:f||h},k)}),g={orientation:"horizontal",hAlign:"stretch",vAlign:"stretch"};d.propTypes={className:n.string,style:n.object,children:n.any,id:n.string,orientation:n.oneOf(["horizontal","vertical"]),gap:n.oneOfType([n.string,n.number]),align:n.shape({vertical:n.oneOf(["top","middle","bottom","stretch"]),horizontal:n.oneOf(["start","center","end","stretch"])})};d.displayName="KendoReactStackLayout";exports.StackLayout=d;
|
|
@@ -10,16 +10,16 @@ import * as o from "react";
|
|
|
10
10
|
import n from "prop-types";
|
|
11
11
|
import { packageMetadata as z } from "../package-metadata.mjs";
|
|
12
12
|
import { validatePackage as b, useId as A, classNames as j } from "@progress/kendo-react-common";
|
|
13
|
-
const
|
|
13
|
+
const m = o.forwardRef((e, g) => {
|
|
14
14
|
b(z);
|
|
15
|
-
const
|
|
15
|
+
const c = o.useRef(null), d = o.useCallback(
|
|
16
16
|
() => ({
|
|
17
|
-
element:
|
|
17
|
+
element: c.current
|
|
18
18
|
}),
|
|
19
19
|
[]
|
|
20
20
|
);
|
|
21
21
|
o.useImperativeHandle(g, d);
|
|
22
|
-
const { className:
|
|
22
|
+
const { className: r, style: u, id: h, children: k } = e, y = A(), s = o.useMemo(
|
|
23
23
|
() => e.orientation || l.orientation,
|
|
24
24
|
[e.orientation]
|
|
25
25
|
), t = s === "horizontal", a = o.useMemo(
|
|
@@ -28,7 +28,7 @@ const c = o.forwardRef((e, g) => {
|
|
|
28
28
|
), i = o.useMemo(
|
|
29
29
|
() => e.align && e.align.vertical ? e.align.vertical : l.vAlign,
|
|
30
30
|
[e.align]
|
|
31
|
-
),
|
|
31
|
+
), f = o.useMemo(
|
|
32
32
|
() => j(
|
|
33
33
|
"k-stack-layout",
|
|
34
34
|
{
|
|
@@ -43,9 +43,9 @@ const c = o.forwardRef((e, g) => {
|
|
|
43
43
|
"k-align-items-end": !t && a === "end" || t && i === "bottom",
|
|
44
44
|
"k-align-items-stretch": !t && a === "stretch" || t && i === "stretch"
|
|
45
45
|
},
|
|
46
|
-
|
|
46
|
+
r
|
|
47
47
|
),
|
|
48
|
-
[s, t, a, i,
|
|
48
|
+
[s, t, a, i, r]
|
|
49
49
|
), v = {
|
|
50
50
|
gap: `${typeof e.gap == "number" ? e.gap + "px" : e.gap}`,
|
|
51
51
|
...u
|
|
@@ -53,10 +53,10 @@ const c = o.forwardRef((e, g) => {
|
|
|
53
53
|
return /* @__PURE__ */ o.createElement(
|
|
54
54
|
"div",
|
|
55
55
|
{
|
|
56
|
-
ref:
|
|
57
|
-
className:
|
|
56
|
+
ref: c,
|
|
57
|
+
className: f,
|
|
58
58
|
style: v,
|
|
59
|
-
id: h ||
|
|
59
|
+
id: h || y
|
|
60
60
|
},
|
|
61
61
|
k
|
|
62
62
|
);
|
|
@@ -65,7 +65,7 @@ const c = o.forwardRef((e, g) => {
|
|
|
65
65
|
hAlign: "stretch",
|
|
66
66
|
vAlign: "stretch"
|
|
67
67
|
};
|
|
68
|
-
|
|
68
|
+
m.propTypes = {
|
|
69
69
|
className: n.string,
|
|
70
70
|
style: n.object,
|
|
71
71
|
children: n.any,
|
|
@@ -77,8 +77,7 @@ c.propTypes = {
|
|
|
77
77
|
horizontal: n.oneOf(["start", "center", "end", "stretch"])
|
|
78
78
|
})
|
|
79
79
|
};
|
|
80
|
-
|
|
81
|
-
c.displayName = "KendoReactStackLayout";
|
|
80
|
+
m.displayName = "KendoReactStackLayout";
|
|
82
81
|
export {
|
|
83
|
-
|
|
82
|
+
m as StackLayout
|
|
84
83
|
};
|
package/stepper/Step.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 client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const ee=require("react"),n=require("prop-types"),te=require("./context/StepperContext.js"),c=require("@progress/kendo-react-common"),ne=require("@progress/kendo-react-intl"),j=require("@progress/kendo-svg-icons"),D=require("./contants.js"),L=require("./messages/index.js");function ae(s){const p=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(s){for(const
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const ee=require("react"),n=require("prop-types"),te=require("./context/StepperContext.js"),c=require("@progress/kendo-react-common"),ne=require("@progress/kendo-react-intl"),j=require("@progress/kendo-svg-icons"),D=require("./contants.js"),L=require("./messages/index.js");function ae(s){const p=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(s){for(const i in s)if(i!=="default"){const m=Object.getOwnPropertyDescriptor(s,i);Object.defineProperty(p,i,m.get?m:{enumerable:!0,get:()=>s[i]})}}return p.default=s,Object.freeze(p)}const e=ae(ee),y=e.forwardRef((s,p)=>{const{children:i,className:m,current:v,disabled:o,focused:O,icon:b,svgIcon:M,index:a,isValid:t,label:l,optional:k,style:T,tabIndex:oe=se.tabIndex,text:q,..._}=s,{animationDuration:I,isVertical:g,item:z,linear:P,mode:F,numOfSteps:r,value:d,onChange:N,onFocus:x,successIcon:V,errorIcon:w,successSVGIcon:H,errorSVGIcon:W}=e.useContext(te.StepperContext),f=e.useRef(null),R=e.useCallback(()=>{f.current&&c.focusFirstFocusableChild(f.current)},[]),E=e.useCallback(()=>({element:f.current,focus:R}),[R]);e.useImperativeHandle(p,E);const C=!P||a===d-1||a===d||a===d+1,S=F==="labels"||!!b&&!!l,$=ne.useLocalization(),B=(u=>$.toLanguageString(u,L.messages[u]))(L.optionalText),G=typeof I=="number"?I:I!==!1?D.DEFAULT_ANIMATION_DURATION:D.NO_ANIMATION,U=e.useCallback(u=>{N&&!o&&c.dispatchEvent(N,u,E(),{value:a})},[N,d,o]),K=e.useCallback(u=>{x&&!o&&c.dispatchEvent(x,u,E(),void 0)},[x,o]),J=e.useMemo(()=>c.classNames("k-step",{"k-step-first":a===0,"k-step-last":r&&a===r-1,"k-step-done":a<d,"k-step-current":v,"k-step-optional":k,"k-step-error":t!==void 0&&!t,"k-step-success":t,"k-disabled":o,"k-focus":O},m),[a,r,d,v,k,o,O,t,m]),Q=e.useMemo(()=>({maxWidth:g?void 0:`calc(100% / ${r})`,maxHeight:g?`calc(100% / ${r})`:void 0,pointerEvents:C?void 0:"none",...T}),[g,r,T,C]),A=t?V:w,h=A?e.createElement("span",{className:"k-step-indicator-icon "+A,"aria-hidden":"true"}):e.createElement(c.IconWrap,{className:"k-step-indicator-icon",name:t?"check-circle":"exclamation-circle",icon:t?H||j.checkOutlineIcon:W||j.exclamationCircleIcon}),X=e.createElement(e.Fragment,null,F!=="labels"?e.createElement("span",{className:"k-step-indicator","aria-hidden":!0,style:{transitionDuration:G+"ms"}},b||M?!S&&t!==void 0?h:e.createElement(c.IconWrap,{className:"k-step-indicator-icon",name:b&&c.toIconName(b),icon:M}):t!==void 0?h:e.createElement("span",{className:"k-step-indicator-text"},q||a+1)):null),Y=(l||S||k)&&e.createElement("span",{className:"k-step-label"},l&&e.createElement("span",{className:"k-step-text"},l),S&&t!==void 0&&h,k&&e.createElement("span",{className:"k-step-label-optional"},B)),Z=e.createElement(e.Fragment,null,X,Y);return e.createElement("li",{ref:f,className:J,style:Q,..._},e.createElement("a",{className:"k-step-link",title:l||void 0,onClick:U,onFocus:K,"aria-current":v?"step":void 0,"aria-disabled":o||!C||void 0,"aria-invalid":t!==void 0&&!t||void 0},z?i:Z))});y.propTypes={children:n.any,className:n.string,current:n.bool,disabled:n.bool,icon:n.string,index:n.number,isValid:n.bool,label:n.string,optional:n.bool,style:n.object,tabIndex:n.number,text:n.string};const se={tabIndex:0};y.displayName="KendoStep";exports.Step=y;
|
package/stepper/Step.mjs
CHANGED
|
@@ -9,44 +9,44 @@
|
|
|
9
9
|
import * as e from "react";
|
|
10
10
|
import a from "prop-types";
|
|
11
11
|
import { StepperContext as Y } from "./context/StepperContext.mjs";
|
|
12
|
-
import { focusFirstFocusableChild as Z, dispatchEvent as
|
|
12
|
+
import { focusFirstFocusableChild as Z, dispatchEvent as M, classNames as ee, IconWrap as T, toIconName as te } from "@progress/kendo-react-common";
|
|
13
13
|
import { useLocalization as ae } from "@progress/kendo-react-intl";
|
|
14
|
-
import { checkOutlineIcon as se, exclamationCircleIcon as
|
|
15
|
-
import { DEFAULT_ANIMATION_DURATION as
|
|
14
|
+
import { checkOutlineIcon as se, exclamationCircleIcon as ne } from "@progress/kendo-svg-icons";
|
|
15
|
+
import { DEFAULT_ANIMATION_DURATION as oe, NO_ANIMATION as ce } from "./contants.mjs";
|
|
16
16
|
import { messages as le, optionalText as ie } from "./messages/index.mjs";
|
|
17
|
-
const
|
|
17
|
+
const L = e.forwardRef((O, R) => {
|
|
18
18
|
const {
|
|
19
19
|
// content
|
|
20
20
|
children: V,
|
|
21
|
-
className:
|
|
21
|
+
className: g,
|
|
22
22
|
current: d,
|
|
23
|
-
disabled:
|
|
24
|
-
focused:
|
|
23
|
+
disabled: n,
|
|
24
|
+
focused: E,
|
|
25
25
|
icon: r,
|
|
26
|
-
svgIcon:
|
|
26
|
+
svgIcon: h,
|
|
27
27
|
index: s,
|
|
28
28
|
isValid: t,
|
|
29
|
-
label:
|
|
29
|
+
label: o,
|
|
30
30
|
optional: m,
|
|
31
|
-
style:
|
|
32
|
-
tabIndex: me,
|
|
33
|
-
text:
|
|
31
|
+
style: C,
|
|
32
|
+
tabIndex: me = re.tabIndex,
|
|
33
|
+
text: y,
|
|
34
34
|
...z
|
|
35
35
|
} = O, {
|
|
36
36
|
animationDuration: u,
|
|
37
37
|
isVertical: k,
|
|
38
38
|
item: D,
|
|
39
39
|
linear: H,
|
|
40
|
-
mode:
|
|
40
|
+
mode: S,
|
|
41
41
|
numOfSteps: c,
|
|
42
42
|
value: l,
|
|
43
43
|
onChange: b,
|
|
44
44
|
onFocus: f,
|
|
45
|
-
successIcon:
|
|
46
|
-
errorIcon:
|
|
47
|
-
successSVGIcon:
|
|
48
|
-
errorSVGIcon:
|
|
49
|
-
} = e.useContext(Y), p = e.useRef(null),
|
|
45
|
+
successIcon: _,
|
|
46
|
+
errorIcon: w,
|
|
47
|
+
successSVGIcon: B,
|
|
48
|
+
errorSVGIcon: G
|
|
49
|
+
} = e.useContext(Y), p = e.useRef(null), F = e.useCallback(
|
|
50
50
|
() => {
|
|
51
51
|
p.current && Z(p.current);
|
|
52
52
|
},
|
|
@@ -54,31 +54,31 @@ const x = e.forwardRef((O, R) => {
|
|
|
54
54
|
), v = e.useCallback(
|
|
55
55
|
() => ({
|
|
56
56
|
element: p.current,
|
|
57
|
-
focus:
|
|
57
|
+
focus: F
|
|
58
58
|
}),
|
|
59
|
-
[
|
|
59
|
+
[F]
|
|
60
60
|
);
|
|
61
61
|
e.useImperativeHandle(R, v);
|
|
62
|
-
const I = !H || s === l - 1 || s === l || s === l + 1, N =
|
|
62
|
+
const I = !H || s === l - 1 || s === l || s === l + 1, N = S === "labels" || !!r && !!o, P = ae(), U = ((i) => P.toLanguageString(i, le[i]))(ie), W = typeof u == "number" ? u : u !== !1 ? oe : ce, $ = e.useCallback(
|
|
63
63
|
(i) => {
|
|
64
|
-
b && !
|
|
64
|
+
b && !n && M(
|
|
65
65
|
b,
|
|
66
66
|
i,
|
|
67
67
|
v(),
|
|
68
68
|
{ value: s }
|
|
69
69
|
);
|
|
70
70
|
},
|
|
71
|
-
[b, l,
|
|
71
|
+
[b, l, n]
|
|
72
72
|
), j = e.useCallback(
|
|
73
73
|
(i) => {
|
|
74
|
-
f && !
|
|
74
|
+
f && !n && M(
|
|
75
75
|
f,
|
|
76
76
|
i,
|
|
77
77
|
v(),
|
|
78
78
|
void 0
|
|
79
79
|
);
|
|
80
80
|
},
|
|
81
|
-
[f,
|
|
81
|
+
[f, n]
|
|
82
82
|
), K = e.useMemo(
|
|
83
83
|
() => ee(
|
|
84
84
|
"k-step",
|
|
@@ -90,42 +90,42 @@ const x = e.forwardRef((O, R) => {
|
|
|
90
90
|
"k-step-optional": m,
|
|
91
91
|
"k-step-error": t !== void 0 && !t,
|
|
92
92
|
"k-step-success": t,
|
|
93
|
-
"k-disabled":
|
|
94
|
-
"k-focus":
|
|
93
|
+
"k-disabled": n,
|
|
94
|
+
"k-focus": E
|
|
95
95
|
},
|
|
96
|
-
|
|
96
|
+
g
|
|
97
97
|
),
|
|
98
|
-
[s, c, l, d, m,
|
|
98
|
+
[s, c, l, d, m, n, E, t, g]
|
|
99
99
|
), q = e.useMemo(
|
|
100
100
|
() => ({
|
|
101
101
|
maxWidth: k ? void 0 : `calc(100% / ${c})`,
|
|
102
102
|
maxHeight: k ? `calc(100% / ${c})` : void 0,
|
|
103
103
|
pointerEvents: I ? void 0 : "none",
|
|
104
|
-
...
|
|
104
|
+
...C
|
|
105
105
|
}),
|
|
106
|
-
[k, c,
|
|
107
|
-
),
|
|
106
|
+
[k, c, C, I]
|
|
107
|
+
), A = t ? _ : w, x = A ? /* @__PURE__ */ e.createElement(
|
|
108
108
|
"span",
|
|
109
109
|
{
|
|
110
|
-
className: "k-step-indicator-icon " +
|
|
110
|
+
className: "k-step-indicator-icon " + A,
|
|
111
111
|
"aria-hidden": "true"
|
|
112
112
|
}
|
|
113
113
|
) : /* @__PURE__ */ e.createElement(
|
|
114
|
-
|
|
114
|
+
T,
|
|
115
115
|
{
|
|
116
116
|
className: "k-step-indicator-icon",
|
|
117
117
|
name: t ? "check-circle" : "exclamation-circle",
|
|
118
|
-
icon: t ?
|
|
118
|
+
icon: t ? B || se : G || ne
|
|
119
119
|
}
|
|
120
|
-
), J = /* @__PURE__ */ e.createElement(e.Fragment, null,
|
|
120
|
+
), J = /* @__PURE__ */ e.createElement(e.Fragment, null, S !== "labels" ? /* @__PURE__ */ e.createElement(
|
|
121
121
|
"span",
|
|
122
122
|
{
|
|
123
123
|
className: "k-step-indicator",
|
|
124
124
|
"aria-hidden": !0,
|
|
125
125
|
style: { transitionDuration: W + "ms" }
|
|
126
126
|
},
|
|
127
|
-
r ||
|
|
128
|
-
) : null), Q = (
|
|
127
|
+
r || h ? !N && t !== void 0 ? x : /* @__PURE__ */ e.createElement(T, { className: "k-step-indicator-icon", name: r && te(r), icon: h }) : t !== void 0 ? x : /* @__PURE__ */ e.createElement("span", { className: "k-step-indicator-text" }, y || s + 1)
|
|
128
|
+
) : null), Q = (o || N || m) && /* @__PURE__ */ e.createElement("span", { className: "k-step-label" }, o && /* @__PURE__ */ e.createElement("span", { className: "k-step-text" }, o), N && t !== void 0 && x, m && /* @__PURE__ */ e.createElement("span", { className: "k-step-label-optional" }, U)), X = /* @__PURE__ */ e.createElement(e.Fragment, null, J, Q);
|
|
129
129
|
return /* @__PURE__ */ e.createElement(
|
|
130
130
|
"li",
|
|
131
131
|
{
|
|
@@ -138,18 +138,18 @@ const x = e.forwardRef((O, R) => {
|
|
|
138
138
|
"a",
|
|
139
139
|
{
|
|
140
140
|
className: "k-step-link",
|
|
141
|
-
title:
|
|
141
|
+
title: o || void 0,
|
|
142
142
|
onClick: $,
|
|
143
143
|
onFocus: j,
|
|
144
144
|
"aria-current": d ? "step" : void 0,
|
|
145
|
-
"aria-disabled":
|
|
145
|
+
"aria-disabled": n || !I || void 0,
|
|
146
146
|
"aria-invalid": t !== void 0 && !t || void 0
|
|
147
147
|
},
|
|
148
148
|
D ? V : X
|
|
149
149
|
)
|
|
150
150
|
);
|
|
151
151
|
});
|
|
152
|
-
|
|
152
|
+
L.propTypes = {
|
|
153
153
|
children: a.any,
|
|
154
154
|
className: a.string,
|
|
155
155
|
// content: PropTypes.any,
|
|
@@ -167,8 +167,7 @@ x.propTypes = {
|
|
|
167
167
|
const re = {
|
|
168
168
|
tabIndex: 0
|
|
169
169
|
};
|
|
170
|
-
|
|
171
|
-
x.displayName = "KendoStep";
|
|
170
|
+
L.displayName = "KendoStep";
|
|
172
171
|
export {
|
|
173
|
-
|
|
172
|
+
L as Step
|
|
174
173
|
};
|