@progress/kendo-react-layout 14.4.1 → 14.5.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/dist/cdn/js/kendo-react-layout.js +1 -1
- package/menu/components/Menu.d.ts +14 -93
- package/menu/components/Menu.js +1 -1
- package/menu/components/Menu.mjs +223 -212
- package/menu/components/MenuItem.d.ts +4 -24
- package/menu/components/MenuItem.js +1 -1
- package/menu/components/MenuItem.mjs +16 -24
- package/menu/components/MenuItemArrow.d.ts +1 -16
- package/menu/components/MenuItemArrow.js +1 -1
- package/menu/components/MenuItemArrow.mjs +26 -35
- package/menu/components/MenuItemInternal.d.ts +2 -35
- package/menu/components/MenuItemInternal.js +1 -1
- package/menu/components/MenuItemInternal.mjs +174 -219
- package/menu/components/MenuItemLink.d.ts +1 -15
- package/menu/components/MenuItemLink.js +1 -1
- package/menu/components/MenuItemLink.mjs +17 -30
- package/menu/events.d.ts +4 -4
- package/menu/utils/DirectionHolder.js +1 -1
- package/menu/utils/DirectionHolder.mjs +1 -1
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +2 -2
- package/package.json +8 -8
|
@@ -5,240 +5,195 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import * as
|
|
9
|
-
import { getActiveElement as
|
|
10
|
-
import { Popup as
|
|
11
|
-
import { shouldOpenItem as
|
|
12
|
-
import { getDOMElementId as
|
|
13
|
-
import { MenuItemLink as
|
|
14
|
-
import { MenuItemArrow as
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
8
|
+
import * as i from "react";
|
|
9
|
+
import { getActiveElement as F, classNames as v, IconWrap as B } from "@progress/kendo-react-common";
|
|
10
|
+
import { Popup as y } from "@progress/kendo-react-popup";
|
|
11
|
+
import { shouldOpenItem as x, isFirstItemFromSiblings as S } from "../utils/itemsIdsUtils.mjs";
|
|
12
|
+
import { getDOMElementId as M, convertBoolDirectionToString as R, getPopupSettings as G } from "../utils/misc.mjs";
|
|
13
|
+
import { MenuItemLink as V } from "./MenuItemLink.mjs";
|
|
14
|
+
import { MenuItemArrow as w } from "./MenuItemArrow.mjs";
|
|
15
|
+
const A = (e) => {
|
|
16
|
+
const { parentItemId: a } = e, c = a !== void 0 ? (o) => {
|
|
17
|
+
e.onMouseOver(a), o.stopPropagation();
|
|
18
|
+
} : void 0, I = a !== void 0 ? (o) => {
|
|
19
|
+
e.onMouseLeave(a), o.stopPropagation();
|
|
20
|
+
} : void 0;
|
|
21
|
+
let t;
|
|
22
|
+
return e.role ? t = e.role : a !== void 0 ? t = "menu" : t = "menubar", /* @__PURE__ */ i.createElement(
|
|
23
|
+
"ul",
|
|
24
|
+
{
|
|
25
|
+
className: e.className,
|
|
26
|
+
role: t,
|
|
27
|
+
id: a !== void 0 ? M(e.menuGuid, a) : void 0,
|
|
28
|
+
onMouseOver: c,
|
|
29
|
+
onMouseLeave: I,
|
|
30
|
+
"aria-orientation": e["aria-orientation"]
|
|
31
|
+
},
|
|
32
|
+
e.items.length > 0 ? e.items.map((o, l) => /* @__PURE__ */ i.createElement(
|
|
33
|
+
W,
|
|
27
34
|
{
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
focusedItemId: this.props.focusedItemId,
|
|
47
|
-
lastItemIdToBeOpened: this.props.lastItemIdToBeOpened,
|
|
48
|
-
tabbableItemId: this.props.tabbableItemId,
|
|
49
|
-
itemRender: this.props.itemRender,
|
|
50
|
-
linkRender: this.props.linkRender,
|
|
51
|
-
menuGuid: this.props.menuGuid,
|
|
52
|
-
onMouseOver: this.props.onMouseOver,
|
|
53
|
-
onMouseLeave: this.props.onMouseLeave,
|
|
54
|
-
onBlur: this.props.onBlur,
|
|
55
|
-
onFocus: this.props.onFocus,
|
|
56
|
-
onClick: this.props.onClick,
|
|
57
|
-
onOriginalItemNeeded: this.props.onOriginalItemNeeded,
|
|
58
|
-
onPopupClose: this.props.onPopupClose,
|
|
59
|
-
key: t
|
|
35
|
+
item: o,
|
|
36
|
+
animate: e.animate,
|
|
37
|
+
isMenuVertical: e.isMenuVertical,
|
|
38
|
+
isDirectionRightToLeft: e.isDirectionRightToLeft,
|
|
39
|
+
focusedItemId: e.focusedItemId,
|
|
40
|
+
lastItemIdToBeOpened: e.lastItemIdToBeOpened,
|
|
41
|
+
tabbableItemId: e.tabbableItemId,
|
|
42
|
+
itemRender: e.itemRender,
|
|
43
|
+
linkRender: e.linkRender,
|
|
44
|
+
menuGuid: e.menuGuid,
|
|
45
|
+
onMouseOver: e.onMouseOver,
|
|
46
|
+
onMouseLeave: e.onMouseLeave,
|
|
47
|
+
onBlur: e.onBlur,
|
|
48
|
+
onFocus: e.onFocus,
|
|
49
|
+
onClick: e.onClick,
|
|
50
|
+
onOriginalItemNeeded: e.onOriginalItemNeeded,
|
|
51
|
+
onPopupClose: e.onPopupClose,
|
|
52
|
+
key: l
|
|
60
53
|
}
|
|
61
|
-
)) : null
|
|
62
|
-
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
}
|
|
74
|
-
componentDidMount() {
|
|
75
|
-
const e = this.props.focusedItemId, t = this.props.item.id;
|
|
76
|
-
e && e === t && this.itemElement.focus({ preventScroll: !0 }), this.isFirstRender = !1;
|
|
77
|
-
}
|
|
78
|
-
componentDidUpdate(e) {
|
|
79
|
-
const t = this.props.focusedItemId, i = this.props.item.id;
|
|
80
|
-
if (t) {
|
|
81
|
-
const n = u(document);
|
|
82
|
-
e.focusedItemId !== t && t === i && // https://github.com/telerik/kendo-react/issues/216 :
|
|
54
|
+
)) : null
|
|
55
|
+
);
|
|
56
|
+
}, W = (e) => {
|
|
57
|
+
const a = i.useRef(null), c = i.useRef(!0), I = i.useRef(void 0), t = e.item, o = t.id, l = M(e.menuGuid, o), b = t.separator, O = t.render || e.itemRender, k = t.linkRender || e.linkRender, g = t.contentParentItemId ? t.contentRender : null, d = t.items.length > 0 && x(o, e.lastItemIdToBeOpened) && !c.current;
|
|
58
|
+
i.useEffect(() => {
|
|
59
|
+
var f, s, m;
|
|
60
|
+
const n = e.focusedItemId, r = e.item.id, u = I.current;
|
|
61
|
+
if (c.current)
|
|
62
|
+
n && n === r && ((f = a.current) == null || f.focus({ preventScroll: !0 })), c.current = !1;
|
|
63
|
+
else if (n) {
|
|
64
|
+
const T = F(document);
|
|
65
|
+
u !== n && n === r && // https://github.com/telerik/kendo-react/issues/216 :
|
|
83
66
|
// No need to focus the wrapping menu item DOM element
|
|
84
67
|
// when a child DOM element was clicked.
|
|
85
|
-
!
|
|
68
|
+
!((s = a.current) != null && s.contains(T)) && ((m = a.current) == null || m.focus({ preventScroll: !0 }));
|
|
86
69
|
}
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
{
|
|
104
|
-
id: i,
|
|
105
|
-
className: this.getMenuItemClassName(e),
|
|
106
|
-
style: e.cssStyle,
|
|
107
|
-
tabIndex: t === this.props.tabbableItemId ? 0 : -1,
|
|
108
|
-
onMouseOver: this.onMouseOver,
|
|
109
|
-
onMouseLeave: this.onMouseLeave,
|
|
110
|
-
onBlur: (o) => this.props.onBlur(t, o),
|
|
111
|
-
onFocus: () => this.props.onFocus(t),
|
|
112
|
-
onClick: (o) => this.props.onClick(o, t),
|
|
113
|
-
role: "menuitem",
|
|
114
|
-
"aria-disabled": e.disabled ? !0 : void 0,
|
|
115
|
-
"aria-haspopup": e.items.length > 0 ? !0 : void 0,
|
|
116
|
-
"aria-expanded": e.items.length > 0 ? this.Opened : void 0,
|
|
117
|
-
"aria-label": e.text,
|
|
118
|
-
"aria-owns": this.Opened ? i : void 0,
|
|
119
|
-
ref: (o) => {
|
|
120
|
-
this.itemElement = o;
|
|
121
|
-
},
|
|
122
|
-
key: i
|
|
123
|
-
},
|
|
124
|
-
this.contentRender ? this.renderContent() : this.renderMenuItemLink()
|
|
125
|
-
), this.renderPopupIfOpened());
|
|
126
|
-
}
|
|
127
|
-
renderContent() {
|
|
128
|
-
const e = this.props.item.contentParentItemId;
|
|
129
|
-
return /* @__PURE__ */ s.createElement("div", { className: "k-content", role: "presentation" }, /* @__PURE__ */ s.createElement(this.contentRender, { item: this.props.onOriginalItemNeeded(e), itemId: e }));
|
|
130
|
-
}
|
|
131
|
-
renderMenuItemLink() {
|
|
132
|
-
const e = this.props.item;
|
|
133
|
-
if (this.linkRender)
|
|
134
|
-
return /* @__PURE__ */ s.createElement(
|
|
135
|
-
this.linkRender,
|
|
70
|
+
I.current = n;
|
|
71
|
+
});
|
|
72
|
+
const E = (n) => {
|
|
73
|
+
e.onMouseOver(o), n.stopPropagation();
|
|
74
|
+
}, L = (n) => {
|
|
75
|
+
e.onMouseLeave(o), n.stopPropagation();
|
|
76
|
+
}, h = (n) => {
|
|
77
|
+
e.onPopupClose(o, n);
|
|
78
|
+
}, C = () => {
|
|
79
|
+
const n = t.contentParentItemId, r = g;
|
|
80
|
+
return /* @__PURE__ */ i.createElement("div", { className: "k-content", role: "presentation" }, /* @__PURE__ */ i.createElement(r, { item: e.onOriginalItemNeeded(n), itemId: n }));
|
|
81
|
+
}, D = () => {
|
|
82
|
+
if (k) {
|
|
83
|
+
const u = k;
|
|
84
|
+
return /* @__PURE__ */ i.createElement(
|
|
85
|
+
u,
|
|
136
86
|
{
|
|
137
|
-
item:
|
|
138
|
-
itemId:
|
|
139
|
-
opened:
|
|
140
|
-
dir:
|
|
87
|
+
item: e.onOriginalItemNeeded(t.id),
|
|
88
|
+
itemId: t.id,
|
|
89
|
+
opened: d,
|
|
90
|
+
dir: R(e.isDirectionRightToLeft)
|
|
141
91
|
}
|
|
142
92
|
);
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
const e = this.props.item.id, t = this.props.animate, { anchorAlign: i, popupAlign: n, collision: o, animationDirection: r } = f(
|
|
148
|
-
e,
|
|
149
|
-
this.props.isMenuVertical,
|
|
150
|
-
this.props.isDirectionRightToLeft
|
|
151
|
-
), l = t === !0 ? { openDuration: 300, closeDuration: 300, direction: r } : t === !1 ? !1 : {
|
|
152
|
-
openDuration: (t == null ? void 0 : t.openDuration) || 300,
|
|
153
|
-
closeDuration: (t == null ? void 0 : t.closeDuration) || 300,
|
|
154
|
-
direction: (t == null ? void 0 : t.direction) || r
|
|
155
|
-
};
|
|
156
|
-
return /* @__PURE__ */ s.createElement(
|
|
157
|
-
c,
|
|
93
|
+
}
|
|
94
|
+
const n = O, r = n ? /* @__PURE__ */ i.createElement(n, { item: e.onOriginalItemNeeded(t.id), itemId: t.id, key: "1" }) : /* @__PURE__ */ i.createElement("span", { className: "k-menu-link-text" }, t.text);
|
|
95
|
+
return /* @__PURE__ */ i.createElement(V, { url: t.url, opened: d }, t.icon || t.svgIcon ? /* @__PURE__ */ i.createElement(B, { name: t.icon, icon: t.svgIcon, key: "0" }) : null, r, t.items.length > 0 ? /* @__PURE__ */ i.createElement("span", { className: "k-menu-expand-arrow", "aria-hidden": !0 }, /* @__PURE__ */ i.createElement(
|
|
96
|
+
w,
|
|
158
97
|
{
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
98
|
+
itemId: t.id,
|
|
99
|
+
verticalMenu: e.isMenuVertical,
|
|
100
|
+
dir: R(e.isDirectionRightToLeft),
|
|
101
|
+
key: "2"
|
|
102
|
+
}
|
|
103
|
+
)) : null);
|
|
104
|
+
}, N = () => {
|
|
105
|
+
const n = e.animate, { anchorAlign: r, popupAlign: u, collision: f, animationDirection: s } = G(
|
|
106
|
+
o,
|
|
107
|
+
e.isMenuVertical,
|
|
108
|
+
e.isDirectionRightToLeft
|
|
109
|
+
);
|
|
110
|
+
let m;
|
|
111
|
+
return n === !0 ? m = { openDuration: 300, closeDuration: 300, direction: s } : n === !1 ? m = !1 : m = {
|
|
112
|
+
openDuration: (n == null ? void 0 : n.openDuration) || 300,
|
|
113
|
+
closeDuration: (n == null ? void 0 : n.closeDuration) || 300,
|
|
114
|
+
direction: (n == null ? void 0 : n.direction) || s
|
|
115
|
+
}, /* @__PURE__ */ i.createElement(
|
|
116
|
+
y,
|
|
117
|
+
{
|
|
118
|
+
anchor: a.current,
|
|
119
|
+
show: d,
|
|
120
|
+
popupClass: v("k-menu-popup", { "k-rtl": e.isDirectionRightToLeft }),
|
|
121
|
+
anchorAlign: r,
|
|
122
|
+
popupAlign: u,
|
|
123
|
+
collision: f,
|
|
124
|
+
animate: m,
|
|
125
|
+
onClose: h,
|
|
167
126
|
key: "1"
|
|
168
127
|
},
|
|
169
|
-
/* @__PURE__ */
|
|
170
|
-
|
|
128
|
+
/* @__PURE__ */ i.createElement(
|
|
129
|
+
A,
|
|
171
130
|
{
|
|
172
|
-
parentItemId:
|
|
173
|
-
animate:
|
|
174
|
-
items:
|
|
175
|
-
menuGuid:
|
|
176
|
-
focusedItemId:
|
|
177
|
-
lastItemIdToBeOpened:
|
|
178
|
-
tabbableItemId:
|
|
179
|
-
itemRender:
|
|
180
|
-
linkRender:
|
|
181
|
-
isMenuVertical:
|
|
182
|
-
isDirectionRightToLeft:
|
|
131
|
+
parentItemId: o,
|
|
132
|
+
animate: e.animate,
|
|
133
|
+
items: t.items,
|
|
134
|
+
menuGuid: e.menuGuid,
|
|
135
|
+
focusedItemId: e.focusedItemId,
|
|
136
|
+
lastItemIdToBeOpened: e.lastItemIdToBeOpened,
|
|
137
|
+
tabbableItemId: e.tabbableItemId,
|
|
138
|
+
itemRender: e.itemRender,
|
|
139
|
+
linkRender: e.linkRender,
|
|
140
|
+
isMenuVertical: e.isMenuVertical,
|
|
141
|
+
isDirectionRightToLeft: e.isDirectionRightToLeft,
|
|
183
142
|
className: "k-group k-menu-group k-reset k-menu-group-md",
|
|
184
|
-
onMouseOver:
|
|
185
|
-
onMouseLeave:
|
|
186
|
-
onBlur:
|
|
187
|
-
onFocus:
|
|
188
|
-
onClick:
|
|
189
|
-
onOriginalItemNeeded:
|
|
190
|
-
onPopupClose:
|
|
143
|
+
onMouseOver: e.onMouseOver,
|
|
144
|
+
onMouseLeave: e.onMouseLeave,
|
|
145
|
+
onBlur: e.onBlur,
|
|
146
|
+
onFocus: e.onFocus,
|
|
147
|
+
onClick: e.onClick,
|
|
148
|
+
onOriginalItemNeeded: e.onOriginalItemNeeded,
|
|
149
|
+
onPopupClose: e.onPopupClose
|
|
191
150
|
}
|
|
192
151
|
)
|
|
193
152
|
);
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
"
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
e.cssClass
|
|
238
|
-
);
|
|
239
|
-
}
|
|
240
|
-
}
|
|
153
|
+
}, P = v(
|
|
154
|
+
"k-item",
|
|
155
|
+
"k-menu-item",
|
|
156
|
+
{
|
|
157
|
+
"k-first": S(o),
|
|
158
|
+
"k-last": t.isLastFromSiblings,
|
|
159
|
+
"k-disabled": t.disabled
|
|
160
|
+
},
|
|
161
|
+
t.cssClass
|
|
162
|
+
);
|
|
163
|
+
return /* @__PURE__ */ i.createElement(i.Fragment, null, b ? /* @__PURE__ */ i.createElement(
|
|
164
|
+
"li",
|
|
165
|
+
{
|
|
166
|
+
className: "k-separator k-item",
|
|
167
|
+
"aria-hidden": !0,
|
|
168
|
+
key: l,
|
|
169
|
+
id: l,
|
|
170
|
+
ref: a
|
|
171
|
+
}
|
|
172
|
+
) : /* @__PURE__ */ i.createElement(
|
|
173
|
+
"li",
|
|
174
|
+
{
|
|
175
|
+
id: l,
|
|
176
|
+
className: P,
|
|
177
|
+
style: t.cssStyle,
|
|
178
|
+
tabIndex: o === e.tabbableItemId ? 0 : -1,
|
|
179
|
+
onMouseOver: E,
|
|
180
|
+
onMouseLeave: L,
|
|
181
|
+
onBlur: (n) => e.onBlur(o, n),
|
|
182
|
+
onFocus: () => e.onFocus(o),
|
|
183
|
+
onClick: (n) => e.onClick(n, o),
|
|
184
|
+
role: "menuitem",
|
|
185
|
+
"aria-disabled": t.disabled ? !0 : void 0,
|
|
186
|
+
"aria-haspopup": t.items.length > 0 ? !0 : void 0,
|
|
187
|
+
"aria-expanded": t.items.length > 0 ? d : void 0,
|
|
188
|
+
"aria-label": t.text,
|
|
189
|
+
"aria-owns": d ? l : void 0,
|
|
190
|
+
ref: a,
|
|
191
|
+
key: l
|
|
192
|
+
},
|
|
193
|
+
g ? C() : D()
|
|
194
|
+
), N());
|
|
195
|
+
};
|
|
241
196
|
export {
|
|
242
|
-
|
|
243
|
-
|
|
197
|
+
W as MenuItemInternal,
|
|
198
|
+
A as MenuItemInternalsList
|
|
244
199
|
};
|
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import { default as PropTypes } from 'prop-types';
|
|
9
8
|
import { KendoReactComponentBaseProps } from '@progress/kendo-react-common';
|
|
10
9
|
import * as React from 'react';
|
|
11
10
|
/**
|
|
@@ -21,17 +20,4 @@ export interface MenuItemLinkProps extends KendoReactComponentBaseProps {
|
|
|
21
20
|
*/
|
|
22
21
|
url?: string;
|
|
23
22
|
}
|
|
24
|
-
export declare
|
|
25
|
-
/**
|
|
26
|
-
* @hidden
|
|
27
|
-
*/
|
|
28
|
-
static propTypes: {
|
|
29
|
-
opened: PropTypes.Requireable<boolean>;
|
|
30
|
-
url: PropTypes.Requireable<string>;
|
|
31
|
-
};
|
|
32
|
-
/**
|
|
33
|
-
* @hidden
|
|
34
|
-
*/
|
|
35
|
-
render(): React.JSX.Element;
|
|
36
|
-
private getMenuItemClassName;
|
|
37
|
-
}
|
|
23
|
+
export declare const MenuItemLink: (props: MenuItemLinkProps) => React.JSX.Element;
|
|
@@ -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 o=require("react"),r=require("prop-types"),s=require("@progress/kendo-react-common");function u(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 c=u(o),l=e=>s.classNames("k-link","k-menu-link",{"k-active":e}),i=e=>e.url?c.createElement("a",{className:l(e.opened),href:e.url,tabIndex:-1},e.children):c.createElement("span",{id:e.id,className:s.classNames(l(e.opened),e.className),style:e.style,role:"presentation"},e.children);i.propTypes={opened:r.bool,url:r.string};exports.MenuItemLink=i;
|
|
@@ -5,36 +5,23 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import * as
|
|
9
|
-
import
|
|
10
|
-
import { classNames as
|
|
11
|
-
const
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
this.props.children
|
|
25
|
-
);
|
|
26
|
-
}
|
|
27
|
-
getMenuItemClassName() {
|
|
28
|
-
return r("k-link", "k-menu-link", {
|
|
29
|
-
"k-active": this.props.opened
|
|
30
|
-
});
|
|
31
|
-
}
|
|
8
|
+
import * as t from "react";
|
|
9
|
+
import n from "prop-types";
|
|
10
|
+
import { classNames as l } from "@progress/kendo-react-common";
|
|
11
|
+
const a = (e) => l("k-link", "k-menu-link", { "k-active": e }), m = (e) => e.url ? /* @__PURE__ */ t.createElement("a", { className: a(e.opened), href: e.url, tabIndex: -1 }, e.children) : /* @__PURE__ */ t.createElement(
|
|
12
|
+
"span",
|
|
13
|
+
{
|
|
14
|
+
id: e.id,
|
|
15
|
+
className: l(a(e.opened), e.className),
|
|
16
|
+
style: e.style,
|
|
17
|
+
role: "presentation"
|
|
18
|
+
},
|
|
19
|
+
e.children
|
|
20
|
+
);
|
|
21
|
+
m.propTypes = {
|
|
22
|
+
opened: n.bool,
|
|
23
|
+
url: n.string
|
|
32
24
|
};
|
|
33
|
-
s.propTypes = {
|
|
34
|
-
opened: t.bool,
|
|
35
|
-
url: t.string
|
|
36
|
-
};
|
|
37
|
-
let p = s;
|
|
38
25
|
export {
|
|
39
|
-
|
|
26
|
+
m as MenuItemLink
|
|
40
27
|
};
|
package/menu/events.d.ts
CHANGED
|
@@ -5,14 +5,14 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import {
|
|
8
|
+
import { MenuHandle } from './components/Menu.js';
|
|
9
9
|
import { MenuItemModel } from './models/MenuItemModel';
|
|
10
10
|
import { BaseEvent } from '@progress/kendo-react-common';
|
|
11
11
|
import { PopupCloseEvent } from '@progress/kendo-react-popup';
|
|
12
12
|
/**
|
|
13
13
|
* The arguments for the `select` event of the Menu. If the item has a URL and the event is prevented, navigation to the URL does not occur.
|
|
14
14
|
*/
|
|
15
|
-
export interface MenuSelectEvent extends BaseEvent<
|
|
15
|
+
export interface MenuSelectEvent extends BaseEvent<MenuHandle> {
|
|
16
16
|
/**
|
|
17
17
|
* The id of selected item. The ids are hierarchical and zero-based. The first root item has a `0` id. If the first root item has children, the first child acquires a `0_0` id and the second acquires a `0_1` id.
|
|
18
18
|
*/
|
|
@@ -27,9 +27,9 @@ export interface MenuSelectEvent extends BaseEvent<Menu> {
|
|
|
27
27
|
*/
|
|
28
28
|
export interface MenuCloseEvent {
|
|
29
29
|
/**
|
|
30
|
-
* The Menu component
|
|
30
|
+
* The Menu component handle.
|
|
31
31
|
*/
|
|
32
|
-
target:
|
|
32
|
+
target: MenuHandle;
|
|
33
33
|
/**
|
|
34
34
|
* The id of the item whose popup was closed. The ids are hierarchical and zero-based. The first root item has a `0` id. If the first root item has children, the first child acquires a `0_0` id and the second acquires a `0_1` id.
|
|
35
35
|
*/
|
|
@@ -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"});class
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});class t{constructor(){this.phase="NotInitialized"}getIsDirectionRightToLeft(){return this.isDirectionRightToLeft}setIsDirectionRightToLeft(i){this.phase=this.phase==="NotInitialized"?"Initialized":"NewValueReceived",this.previousIsDirectionRightToLeft=this.isDirectionRightToLeft,this.isDirectionRightToLeft=i}hasDirectionChanged(){return this.phase==="NewValueReceived"?this.previousIsDirectionRightToLeft!==this.isDirectionRightToLeft:!1}}exports.DirectionHolder=t;
|
package/package-metadata.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 e=Object.freeze({name:"@progress/kendo-react-layout",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate:
|
|
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: 1777909861,version:"14.5.0-develop.1",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"});exports.packageMetadata=e;
|
package/package-metadata.mjs
CHANGED
|
@@ -7,7 +7,7 @@ export const packageMetadata = Object.freeze({
|
|
|
7
7
|
productName: 'KendoReact',
|
|
8
8
|
productCode: 'KENDOUIREACT',
|
|
9
9
|
productCodes: ['KENDOUIREACT'],
|
|
10
|
-
publishDate:
|
|
11
|
-
version: '14.
|
|
10
|
+
publishDate: 1777909861,
|
|
11
|
+
version: '14.5.0-develop.1',
|
|
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.
|
|
3
|
+
"version": "14.5.0-develop.1",
|
|
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.
|
|
30
|
-
"@progress/kendo-react-buttons": "14.
|
|
31
|
-
"@progress/kendo-react-common": "14.
|
|
32
|
-
"@progress/kendo-react-intl": "14.
|
|
33
|
-
"@progress/kendo-react-popup": "14.
|
|
34
|
-
"@progress/kendo-react-progressbars": "14.
|
|
29
|
+
"@progress/kendo-react-animation": "14.5.0-develop.1",
|
|
30
|
+
"@progress/kendo-react-buttons": "14.5.0-develop.1",
|
|
31
|
+
"@progress/kendo-react-common": "14.5.0-develop.1",
|
|
32
|
+
"@progress/kendo-react-intl": "14.5.0-develop.1",
|
|
33
|
+
"@progress/kendo-react-popup": "14.5.0-develop.1",
|
|
34
|
+
"@progress/kendo-react-progressbars": "14.5.0-develop.1",
|
|
35
35
|
"@progress/kendo-svg-icons": "^4.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":
|
|
79
|
+
"publishDate": 1777909861,
|
|
80
80
|
"licensingDocsUrl": "https://www.telerik.com/kendo-react-ui/components/my-license/"
|
|
81
81
|
}
|
|
82
82
|
},
|