@progress/kendo-react-layout 9.4.0-develop.19 → 9.4.0-develop.2
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/NOTICE.txt +51 -40
- package/actionsheet/ActionSheet.js +1 -1
- package/actionsheet/ActionSheet.mjs +1 -0
- package/actionsheet/ActionSheetContent.js +1 -1
- package/actionsheet/ActionSheetContent.mjs +6 -5
- package/actionsheet/ActionSheetFooter.js +1 -1
- package/actionsheet/ActionSheetFooter.mjs +1 -0
- package/actionsheet/ActionSheetHeader.js +1 -1
- package/actionsheet/ActionSheetHeader.mjs +8 -7
- package/actionsheet/ActionSheetItem.js +1 -1
- package/actionsheet/ActionSheetItem.mjs +1 -0
- package/appbar/AppBar.js +1 -1
- package/appbar/AppBar.mjs +11 -10
- package/appbar/AppBarSection.js +1 -1
- package/appbar/AppBarSection.mjs +12 -11
- package/appbar/AppBarSpacer.js +1 -1
- package/appbar/AppBarSpacer.mjs +4 -3
- package/bottomnavigation/BottomNavigation.js +1 -1
- package/bottomnavigation/BottomNavigation.mjs +24 -23
- package/bottomnavigation/BottomNavigationItem.js +1 -1
- package/bottomnavigation/BottomNavigationItem.mjs +12 -11
- package/bottomnavigation/models/utils.js +1 -1
- package/bottomnavigation/models/utils.mjs +5 -4
- package/breadcrumb/Breadcrumb.js +1 -1
- package/breadcrumb/Breadcrumb.mjs +1 -0
- package/breadcrumb/BreadcrumbDelimiter.js +1 -1
- package/breadcrumb/BreadcrumbDelimiter.mjs +1 -0
- package/breadcrumb/BreadcrumbLink.js +1 -1
- package/breadcrumb/BreadcrumbLink.mjs +1 -0
- package/breadcrumb/BreadcrumbListItem.js +1 -1
- package/breadcrumb/BreadcrumbListItem.mjs +1 -0
- package/breadcrumb/BreadcrumbOrderedList.js +1 -1
- package/breadcrumb/BreadcrumbOrderedList.mjs +7 -6
- package/card/Avatar.js +1 -1
- package/card/Avatar.mjs +1 -0
- package/card/Card.js +1 -1
- package/card/Card.mjs +1 -0
- package/card/CardActions.js +1 -1
- package/card/CardActions.mjs +5 -4
- package/card/CardBody.js +1 -1
- package/card/CardBody.mjs +5 -4
- package/card/CardFooter.js +1 -1
- package/card/CardFooter.mjs +1 -0
- package/card/CardHeader.js +1 -1
- package/card/CardHeader.mjs +1 -0
- package/card/CardImage.js +1 -1
- package/card/CardImage.mjs +4 -3
- package/card/CardSubtitle.js +1 -1
- package/card/CardSubtitle.mjs +1 -0
- package/card/CardTitle.js +1 -1
- package/card/CardTitle.mjs +5 -4
- package/card/interfaces/Enums.js +1 -1
- package/card/interfaces/Enums.mjs +5 -4
- package/contextmenu/ContextMenu.js +1 -1
- package/contextmenu/ContextMenu.mjs +1 -0
- package/dist/cdn/js/kendo-react-layout.js +1 -8
- package/drawer/Drawer.js +1 -1
- package/drawer/Drawer.mjs +7 -6
- package/drawer/DrawerContent.js +1 -1
- package/drawer/DrawerContent.mjs +1 -0
- package/drawer/DrawerItem.js +1 -1
- package/drawer/DrawerItem.mjs +5 -4
- package/drawer/DrawerNavigation.js +1 -1
- package/drawer/DrawerNavigation.mjs +1 -0
- package/drawer/context/DrawerContext.js +1 -1
- package/drawer/context/DrawerContext.mjs +3 -2
- package/expansionpanel/ExpansionPanel.js +1 -1
- package/expansionpanel/ExpansionPanel.mjs +22 -21
- package/expansionpanel/ExpansionPanelContent.js +1 -1
- package/expansionpanel/ExpansionPanelContent.mjs +1 -0
- package/gridlayout/GridLayout.js +1 -1
- package/gridlayout/GridLayout.mjs +10 -9
- package/gridlayout/GridLayoutItem.js +1 -1
- package/gridlayout/GridLayoutItem.mjs +1 -0
- package/index.d.mts +16 -92
- package/index.d.ts +16 -92
- package/index.js +1 -2
- package/menu/components/Menu.js +1 -1
- package/menu/components/Menu.mjs +1 -0
- package/menu/components/MenuItem.js +1 -1
- package/menu/components/MenuItem.mjs +3 -2
- package/menu/components/MenuItemArrow.js +1 -1
- package/menu/components/MenuItemArrow.mjs +1 -0
- package/menu/components/MenuItemInternal.js +1 -1
- package/menu/components/MenuItemInternal.mjs +18 -24
- package/menu/components/MenuItemLink.js +1 -1
- package/menu/components/MenuItemLink.mjs +1 -0
- package/menu/consts.js +1 -1
- package/menu/consts.mjs +1 -0
- package/menu/utils/DirectionHolder.js +1 -1
- package/menu/utils/DirectionHolder.mjs +1 -0
- package/menu/utils/MouseOverHandler.js +1 -1
- package/menu/utils/MouseOverHandler.mjs +1 -0
- package/menu/utils/getNewItemIdUponKeyboardNavigation.js +1 -1
- package/menu/utils/getNewItemIdUponKeyboardNavigation.mjs +1 -0
- package/menu/utils/hoverDelay.js +1 -1
- package/menu/utils/hoverDelay.mjs +1 -0
- package/menu/utils/itemsIdsUtils.js +1 -1
- package/menu/utils/itemsIdsUtils.mjs +1 -0
- package/menu/utils/misc.js +1 -1
- package/menu/utils/misc.mjs +12 -11
- package/menu/utils/prepareInputItemsForInternalWork.js +1 -1
- package/menu/utils/prepareInputItemsForInternalWork.mjs +4 -3
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +3 -2
- package/package.json +7 -7
- package/panelbar/PanelBar.js +1 -1
- package/panelbar/PanelBar.mjs +34 -33
- package/panelbar/PanelBarItem.js +1 -1
- package/panelbar/PanelBarItem.mjs +1 -0
- package/panelbar/interfaces/NavigationAction.js +1 -1
- package/panelbar/interfaces/NavigationAction.mjs +1 -0
- package/panelbar/util.js +1 -1
- package/panelbar/util.mjs +19 -18
- package/splitter/Splitter.js +1 -1
- package/splitter/Splitter.mjs +1 -0
- package/splitter/SplitterBar.js +1 -1
- package/splitter/SplitterBar.mjs +1 -0
- package/splitter/SplitterPane.js +1 -1
- package/splitter/SplitterPane.mjs +10 -9
- package/splitter/messages/index.js +1 -1
- package/splitter/messages/index.mjs +3 -2
- package/stacklayout/StackLayout.js +1 -1
- package/stacklayout/StackLayout.mjs +4 -3
- package/stepper/Step.js +1 -1
- package/stepper/Step.mjs +16 -15
- package/stepper/Stepper.js +1 -1
- package/stepper/Stepper.mjs +1 -0
- package/stepper/contants.js +1 -1
- package/stepper/contants.mjs +1 -0
- package/stepper/context/StepperContext.js +1 -1
- package/stepper/context/StepperContext.mjs +1 -0
- package/stepper/messages/index.js +1 -1
- package/stepper/messages/index.mjs +1 -0
- package/tabstrip/TabStrip.js +1 -1
- package/tabstrip/TabStrip.mjs +79 -110
- package/tabstrip/TabStripContent.js +1 -1
- package/tabstrip/TabStripContent.mjs +1 -0
- package/tabstrip/TabStripNavigation.js +1 -1
- package/tabstrip/TabStripNavigation.mjs +117 -110
- package/tabstrip/TabStripNavigationItem.js +1 -1
- package/tabstrip/TabStripNavigationItem.mjs +8 -7
- package/tabstrip/TabStripTab.js +1 -1
- package/tabstrip/TabStripTab.mjs +5 -4
- package/tabstrip/messages/index.js +1 -1
- package/tabstrip/messages/index.mjs +1 -0
- package/tilelayout/InternalTile.js +1 -1
- package/tilelayout/InternalTile.mjs +1 -0
- package/tilelayout/ResizeHandlers.js +1 -1
- package/tilelayout/ResizeHandlers.mjs +11 -10
- package/tilelayout/TileLayout.js +1 -1
- package/tilelayout/TileLayout.mjs +1 -0
- package/timeline/Timeline.js +1 -1
- package/timeline/Timeline.mjs +18 -17
- package/timeline/TimelineCard.js +1 -1
- package/timeline/TimelineCard.mjs +5 -4
- package/timeline/TimelineHorizontal.js +1 -1
- package/timeline/TimelineHorizontal.mjs +1 -0
- package/timeline/TimelineVertical.js +1 -1
- package/timeline/TimelineVertical.mjs +1 -0
- package/timeline/utils.js +1 -1
- package/timeline/utils.mjs +7 -6
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
import * as s from "react";
|
|
9
10
|
import { getActiveElement as a, IconWrap as l, classNames as p } from "@progress/kendo-react-common";
|
|
10
11
|
import { Popup as u } from "@progress/kendo-react-popup";
|
|
@@ -12,7 +13,7 @@ import { shouldOpenItem as h, isFirstItemFromSiblings as c } from "../utils/item
|
|
|
12
13
|
import { getDOMElementId as r, convertBoolDirectionToString as m, getPopupSettings as I } from "../utils/misc.mjs";
|
|
13
14
|
import { MenuItemLink as M } from "./MenuItemLink.mjs";
|
|
14
15
|
import { MenuItemArrow as g } from "./MenuItemArrow.mjs";
|
|
15
|
-
class
|
|
16
|
+
class v extends s.Component {
|
|
16
17
|
constructor() {
|
|
17
18
|
super(...arguments), this.onMouseOver = (e) => {
|
|
18
19
|
this.props.onMouseOver(this.props.parentItemId), e.stopPropagation();
|
|
@@ -37,7 +38,7 @@ class f extends s.Component {
|
|
|
37
38
|
}
|
|
38
39
|
renderChildItems() {
|
|
39
40
|
return this.props.items.length > 0 ? this.props.items.map((e, t) => /* @__PURE__ */ s.createElement(
|
|
40
|
-
|
|
41
|
+
f,
|
|
41
42
|
{
|
|
42
43
|
item: e,
|
|
43
44
|
isMenuVertical: this.props.isMenuVertical,
|
|
@@ -60,7 +61,7 @@ class f extends s.Component {
|
|
|
60
61
|
)) : null;
|
|
61
62
|
}
|
|
62
63
|
}
|
|
63
|
-
class
|
|
64
|
+
class f extends s.Component {
|
|
64
65
|
constructor(e) {
|
|
65
66
|
super(e), this.isFirstRender = !0, this.onMouseOver = (t) => {
|
|
66
67
|
this.props.onMouseOver(this.props.item.id), t.stopPropagation();
|
|
@@ -84,15 +85,7 @@ class v extends s.Component {
|
|
|
84
85
|
}
|
|
85
86
|
render() {
|
|
86
87
|
const e = this.props.item, t = e.id, o = r(this.props.menuGuid, t), n = e.separator;
|
|
87
|
-
return /* @__PURE__ */ s.createElement(s.Fragment, null, n ? /* @__PURE__ */ s.createElement(
|
|
88
|
-
"li",
|
|
89
|
-
{
|
|
90
|
-
className: "k-separator k-item",
|
|
91
|
-
"aria-hidden": !0,
|
|
92
|
-
key: o,
|
|
93
|
-
ref: (i) => this.itemElement = i
|
|
94
|
-
}
|
|
95
|
-
) : /* @__PURE__ */ s.createElement(
|
|
88
|
+
return /* @__PURE__ */ s.createElement(s.Fragment, null, n ? /* @__PURE__ */ s.createElement("li", { className: "k-separator k-item", "aria-hidden": !0, key: o, ref: (i) => this.itemElement = i }) : /* @__PURE__ */ s.createElement(
|
|
96
89
|
"li",
|
|
97
90
|
{
|
|
98
91
|
id: r(this.props.menuGuid, t),
|
|
@@ -115,7 +108,7 @@ class v extends s.Component {
|
|
|
115
108
|
key: o
|
|
116
109
|
},
|
|
117
110
|
this.contentRender ? this.renderContent() : this.renderMenuItemLink()
|
|
118
|
-
), this.renderPopupIfOpened());
|
|
111
|
+
), this.renderPopupIfOpened(this.itemElement));
|
|
119
112
|
}
|
|
120
113
|
renderContent() {
|
|
121
114
|
const e = this.props.item.contentParentItemId;
|
|
@@ -136,10 +129,10 @@ class v extends s.Component {
|
|
|
136
129
|
const t = this.itemRender ? /* @__PURE__ */ s.createElement(this.itemRender, { item: this.props.onOriginalItemNeeded(e.id), itemId: e.id, key: "1" }) : /* @__PURE__ */ s.createElement("span", { className: "k-menu-link-text" }, e.text);
|
|
137
130
|
return /* @__PURE__ */ s.createElement(M, { url: e.url, opened: this.Opened }, this.renderMenuIconIfApplicable(), t, this.renderArrowIfApplicable());
|
|
138
131
|
}
|
|
139
|
-
renderPopupIfOpened() {
|
|
132
|
+
renderPopupIfOpened(e) {
|
|
140
133
|
if (this.Opened) {
|
|
141
|
-
const
|
|
142
|
-
|
|
134
|
+
const t = this.props.item.id, { anchorAlign: o, popupAlign: n, collision: i } = I(
|
|
135
|
+
t,
|
|
143
136
|
this.props.isMenuVertical,
|
|
144
137
|
this.props.isDirectionRightToLeft
|
|
145
138
|
);
|
|
@@ -147,18 +140,19 @@ class v extends s.Component {
|
|
|
147
140
|
u,
|
|
148
141
|
{
|
|
149
142
|
anchor: this.itemElement,
|
|
143
|
+
appendTo: e,
|
|
150
144
|
show: !0,
|
|
151
145
|
popupClass: this.getPopupClassName(),
|
|
152
|
-
anchorAlign:
|
|
153
|
-
popupAlign:
|
|
154
|
-
collision:
|
|
146
|
+
anchorAlign: o,
|
|
147
|
+
popupAlign: n,
|
|
148
|
+
collision: i,
|
|
155
149
|
animate: !1,
|
|
156
150
|
key: "1"
|
|
157
151
|
},
|
|
158
152
|
/* @__PURE__ */ s.createElement(
|
|
159
|
-
|
|
153
|
+
v,
|
|
160
154
|
{
|
|
161
|
-
parentItemId:
|
|
155
|
+
parentItemId: t,
|
|
162
156
|
items: this.props.item.items,
|
|
163
157
|
menuGuid: this.props.menuGuid,
|
|
164
158
|
focusedItemId: this.props.focusedItemId,
|
|
@@ -213,7 +207,7 @@ class v extends s.Component {
|
|
|
213
207
|
!this.isFirstRender;
|
|
214
208
|
}
|
|
215
209
|
getPopupClassName() {
|
|
216
|
-
return p("k-menu-popup", { "k-rtl": this.props.isDirectionRightToLeft });
|
|
210
|
+
return p("k-menu-popup k-overflow-visible", { "k-rtl": this.props.isDirectionRightToLeft });
|
|
217
211
|
}
|
|
218
212
|
getMenuItemClassName(e) {
|
|
219
213
|
return p(
|
|
@@ -229,6 +223,6 @@ class v extends s.Component {
|
|
|
229
223
|
}
|
|
230
224
|
}
|
|
231
225
|
export {
|
|
232
|
-
|
|
233
|
-
|
|
226
|
+
f as MenuItemInternal,
|
|
227
|
+
v as MenuItemInternalsList
|
|
234
228
|
};
|
|
@@ -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 client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("react"),i=require("prop-types"),l=require("@progress/kendo-react-common");function p(e){const s=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(s,t,a.get?a:{enumerable:!0,get:()=>e[t]})}}return s.default=e,Object.freeze(s)}const r=p(c),o=class o extends r.Component{render(){return this.props.url?r.createElement("a",{className:this.getMenuItemClassName(),role:"presentation",href:this.props.url,tabIndex:-1},this.props.children):r.createElement("span",{id:this.props.id,className:l.classNames(this.getMenuItemClassName(),this.props.className),style:this.props.style,role:"presentation"},this.props.children)}getMenuItemClassName(){return l.classNames("k-link","k-menu-link",{"k-active":this.props.opened})}};o.propTypes={opened:i.bool,url:i.string};let n=o;exports.MenuItemLink=n;
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
import * as e from "react";
|
|
9
10
|
import t from "prop-types";
|
|
10
11
|
import { classNames as r } from "@progress/kendo-react-common";
|
package/menu/consts.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={vertical:"top",horizontal:"left"},t={vertical:"top",horizontal:"right"},i={vertical:"flip",horizontal:"fit"},l={vertical:"fit",horizontal:"flip"},n={downward:{anchorAlign:{vertical:"bottom",horizontal:"right"},popupAlign:t,collision:i},leftward:{anchorAlign:{vertical:"top",horizontal:"left"},popupAlign:t,collision:l}},r={downward:{anchorAlign:{vertical:"bottom",horizontal:"left"},popupAlign:o,collision:i},rightward:{anchorAlign:{vertical:"top",horizontal:"right"},popupAlign:o,collision:l}};exports.POPUP_SETTINGS=r;exports.POPUP_SETTINGS_RTL=n;
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o={vertical:"top",horizontal:"left"},t={vertical:"top",horizontal:"right"},i={vertical:"flip",horizontal:"fit"},l={vertical:"fit",horizontal:"flip"},n={downward:{anchorAlign:{vertical:"bottom",horizontal:"right"},popupAlign:t,collision:i},leftward:{anchorAlign:{vertical:"top",horizontal:"left"},popupAlign:t,collision:l}},r={downward:{anchorAlign:{vertical:"bottom",horizontal:"left"},popupAlign:o,collision:i},rightward:{anchorAlign:{vertical:"top",horizontal:"right"},popupAlign:o,collision:l}};exports.POPUP_SETTINGS=r;exports.POPUP_SETTINGS_RTL=n;
|
package/menu/consts.mjs
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"});class e{constructor(){this.phase="Initialized"}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=e;
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});class e{constructor(){this.phase="Initialized"}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=e;
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
class e {
|
|
9
10
|
constructor() {
|
|
10
11
|
this.phase = "Initialized";
|
|
@@ -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 i{constructor(e,s,t){this.openOnClick=e,this.resetMenu=s,this.openItem=t,this.mouseDown=!1,this.openOnClick=e,this.isMouseOverEnabled=!e}set OpenOnClick(e){!!e!=!!this.openOnClick&&(this.mouseDown=!1,this.isMouseOverEnabled=!e),this.openOnClick=e}handleItemSelectedViaKeyboard(){this.openOnClick&&(this.isMouseOverEnabled=!1,this.resetMenu())}get IsMouseOverEnabled(){return this.isMouseOverEnabled}handleItemMouseDown(){this.mouseDown=!0}handleItemFocus(){this.openOnClick&&!this.mouseDown&&(this.isMouseOverEnabled=!0),this.mouseDown=!1}handleItemClick(e,s){this.openOnClick&&(this.isMouseOverEnabled?s&&(this.isMouseOverEnabled=!1,this.resetMenu()):(this.isMouseOverEnabled=!0,this.openItem(e)))}}exports.MouseOverHandler=i;
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});class i{constructor(e,s,t){this.openOnClick=e,this.resetMenu=s,this.openItem=t,this.mouseDown=!1,this.openOnClick=e,this.isMouseOverEnabled=!e}set OpenOnClick(e){!!e!=!!this.openOnClick&&(this.mouseDown=!1,this.isMouseOverEnabled=!e),this.openOnClick=e}handleItemSelectedViaKeyboard(){this.openOnClick&&(this.isMouseOverEnabled=!1,this.resetMenu())}get IsMouseOverEnabled(){return this.isMouseOverEnabled}handleItemMouseDown(){this.mouseDown=!0}handleItemFocus(){this.openOnClick&&!this.mouseDown&&(this.isMouseOverEnabled=!0),this.mouseDown=!1}handleItemClick(e,s){this.openOnClick&&(this.isMouseOverEnabled?s&&(this.isMouseOverEnabled=!1,this.resetMenu()):(this.isMouseOverEnabled=!0,this.openItem(e)))}}exports.MouseOverHandler=i;
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
class n {
|
|
9
10
|
constructor(e, s, i) {
|
|
10
11
|
this.openOnClick = e, this.resetMenu = s, this.openItem = i, this.mouseDown = !1, this.openOnClick = e, this.isMouseOverEnabled = !e;
|
|
@@ -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 i=require("@progress/kendo-react-common"),n=require("./itemsIdsUtils.js"),A=/\S/;function M(u,e,P,y,l,d){const Z=g();switch(P){case i.Keys.left:return E();case i.Keys.right:return w();case i.Keys.up:return O();case i.Keys.down:return N();case i.Keys.enter:case i.Keys.space:return R();case i.Keys.home:return D();case i.Keys.end:return G();case i.Keys.esc:return H();default:return q()?B():e}function E(){return l?d?v():S():d?p():b()}function w(){return l?d?S():v():d?b():p()}function N(){return l?a():n.isIdZeroLevel(e)?s():a()}function O(){return l?c():n.isIdZeroLevel(e)?L():c()}function R(){return Z.disabled?e:f()?n.getFirstChildId(e):n.getRootParentId(e)}function D(){return K()[0].id}function G(){const t=K();return t[t.length-1].id}function H(){return n.isIdZeroLevel(e)?e:n.getDirectParentId(e)}function B(){const t=y.toLowerCase(),r=K(),o=Number(n.getShortId(e)),h=r.slice(o+1).concat(r.slice(0,o+1)).find(z=>(z.text||"").toLowerCase().startsWith(t));return h?h.id:e}function b(){return n.isIdZeroLevel(e)?c():n.isIdFirstLevel(e)?s(c(n.getRootParentId(e))):n.getDirectParentId(e)}function S(){return n.isIdZeroLevel(e)?L():n.getDirectParentId(e)}function p(){return n.isIdZeroLevel(e)?a():s(f()?e:a(n.getRootParentId(e)))}function v(){return s(n.isIdZeroLevel(e)||f()?e:a(n.getRootParentId(e)))}function s(t){return U(!0,t)}function L(t){return U(!1,t)}function q(){return y.length===1&&A.test(y)}function g(t,r){return t===void 0&&(t=e),r===void 0&&(r=u),n.getItemById(t,r)}function f(t){return g(t).items.length>0}function c(t){return C(!1,t)}function a(t){return C(!0,t)}function x(t){const r=g(t).items;return r[r.length-1].id}function K(){return n.isIdZeroLevel(e)?u:g(n.getDirectParentId(e),u).items}function U(t,r){r===void 0&&(r=e);const o=g(r);return f(r)&&!o.disabled?t?n.getFirstChildId(r):x(r):r}function C(t,r){if(r===void 0&&(r=e),n.isIdZeroLevel(r))return n.getDirectSiblingIdForLevelZero(t,r,u.length);const o=n.getDirectParentId(r),F=n.getShortId(r),h=g(o).items.length;return n.createId(n.getDirectSiblingIdForLevelZero(t,F,h),o)}}exports.getNewItemIdUponKeyboardNavigation=M;
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("@progress/kendo-react-common"),n=require("./itemsIdsUtils.js"),A=/\S/;function M(u,e,P,y,l,d){const Z=g();switch(P){case i.Keys.left:return E();case i.Keys.right:return w();case i.Keys.up:return O();case i.Keys.down:return N();case i.Keys.enter:case i.Keys.space:return R();case i.Keys.home:return D();case i.Keys.end:return G();case i.Keys.esc:return H();default:return q()?B():e}function E(){return l?d?v():S():d?p():b()}function w(){return l?d?S():v():d?b():p()}function N(){return l?a():n.isIdZeroLevel(e)?s():a()}function O(){return l?c():n.isIdZeroLevel(e)?L():c()}function R(){return Z.disabled?e:f()?n.getFirstChildId(e):n.getRootParentId(e)}function D(){return K()[0].id}function G(){const t=K();return t[t.length-1].id}function H(){return n.isIdZeroLevel(e)?e:n.getDirectParentId(e)}function B(){const t=y.toLowerCase(),r=K(),o=Number(n.getShortId(e)),h=r.slice(o+1).concat(r.slice(0,o+1)).find(z=>(z.text||"").toLowerCase().startsWith(t));return h?h.id:e}function b(){return n.isIdZeroLevel(e)?c():n.isIdFirstLevel(e)?s(c(n.getRootParentId(e))):n.getDirectParentId(e)}function S(){return n.isIdZeroLevel(e)?L():n.getDirectParentId(e)}function p(){return n.isIdZeroLevel(e)?a():s(f()?e:a(n.getRootParentId(e)))}function v(){return s(n.isIdZeroLevel(e)||f()?e:a(n.getRootParentId(e)))}function s(t){return U(!0,t)}function L(t){return U(!1,t)}function q(){return y.length===1&&A.test(y)}function g(t,r){return t===void 0&&(t=e),r===void 0&&(r=u),n.getItemById(t,r)}function f(t){return g(t).items.length>0}function c(t){return C(!1,t)}function a(t){return C(!0,t)}function x(t){const r=g(t).items;return r[r.length-1].id}function K(){return n.isIdZeroLevel(e)?u:g(n.getDirectParentId(e),u).items}function U(t,r){r===void 0&&(r=e);const o=g(r);return f(r)&&!o.disabled?t?n.getFirstChildId(r):x(r):r}function C(t,r){if(r===void 0&&(r=e),n.isIdZeroLevel(r))return n.getDirectSiblingIdForLevelZero(t,r,u.length);const o=n.getDirectParentId(r),F=n.getShortId(r),h=g(o).items.length;return n.createId(n.getDirectSiblingIdForLevelZero(t,F,h),o)}}exports.getNewItemIdUponKeyboardNavigation=M;
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
import { Keys as e } from "@progress/kendo-react-common";
|
|
9
10
|
import { isIdZeroLevel as i, getFirstChildId as N, getRootParentId as b, getDirectParentId as a, getShortId as O, isIdFirstLevel as q, getItemById as D, getDirectSiblingIdForLevelZero as P, createId as J } from "./itemsIdsUtils.mjs";
|
|
10
11
|
const Q = /\S/;
|
package/menu/utils/hoverDelay.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"});function o(e){return e.hoverOpenDelay!==void 0?e.hoverOpenDelay:e.openOnClick?0:100}function l(e){return e.hoverCloseDelay!==void 0?e.hoverCloseDelay:100}exports.getHoverCloseDelay=l;exports.getHoverOpenDelay=o;
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function o(e){return e.hoverOpenDelay!==void 0?e.hoverOpenDelay:e.openOnClick?0:100}function l(e){return e.hoverCloseDelay!==void 0?e.hoverCloseDelay:100}exports.getHoverCloseDelay=l;exports.getHoverOpenDelay=o;
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
function n(e) {
|
|
9
10
|
return e.hoverOpenDelay !== void 0 ? e.hoverOpenDelay : e.openOnClick ? 0 : 100;
|
|
10
11
|
}
|
|
@@ -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="",s="0",e="_";function c(t,r){if(u(t))return r[Number(t)];const n=r[Number(g(t))];return n.items?c(f(t),n.items):void 0}function g(t){return i(t)?t:t.split(e)[0]}function f(t){if(i(t))return t;const r=t.indexOf(e);return t.substring(r+1)}function S(t){return l("0",t)}function E(t,r){return r.indexOf(t)===0?r.length===t.length||r.charAt(t.length)===e:!1}function l(t,r){return r?r+e+t:t}function O(t){const r=t.lastIndexOf(e);return r<0?o:t.substring(0,r)}function i(t){return t===o||t.indexOf(e)<0}function u(t){return t!==o&&t.indexOf(e)<0}function b(t){return P(t)===1}function d(t){return a(t)===s}function a(t){const r=t.lastIndexOf(e);return r<0?t:t.substring(r+1)}function L(t,r,n){return u(r)?t?Number(r)<n-1?(Number(r)+1).toString():"0":Number(r)>0?(Number(r)-1).toString():(n-1).toString():r}function P(t){return t.split(e).length-1}exports.EMPTY_ID=o;exports.SEPARATOR=e;exports.ZERO_LEVEL_ZERO_ITEM_ID=s;exports.createId=l;exports.getDirectParentId=O;exports.getDirectSiblingIdForLevelZero=L;exports.getFirstChildId=S;exports.getIdWithoutRootParentId=f;exports.getItemById=c;exports.getRootParentId=g;exports.getShortId=a;exports.isFirstItemFromSiblings=d;exports.isIdEmptyOrZeroLevel=i;exports.isIdFirstLevel=b;exports.isIdZeroLevel=u;exports.shouldOpenItem=E;
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o="",s="0",e="_";function c(t,r){if(u(t))return r[Number(t)];const n=r[Number(g(t))];return n.items?c(f(t),n.items):void 0}function g(t){return i(t)?t:t.split(e)[0]}function f(t){if(i(t))return t;const r=t.indexOf(e);return t.substring(r+1)}function S(t){return l("0",t)}function E(t,r){return r.indexOf(t)===0?r.length===t.length||r.charAt(t.length)===e:!1}function l(t,r){return r?r+e+t:t}function O(t){const r=t.lastIndexOf(e);return r<0?o:t.substring(0,r)}function i(t){return t===o||t.indexOf(e)<0}function u(t){return t!==o&&t.indexOf(e)<0}function b(t){return P(t)===1}function d(t){return a(t)===s}function a(t){const r=t.lastIndexOf(e);return r<0?t:t.substring(r+1)}function L(t,r,n){return u(r)?t?Number(r)<n-1?(Number(r)+1).toString():"0":Number(r)>0?(Number(r)-1).toString():(n-1).toString():r}function P(t){return t.split(e).length-1}exports.EMPTY_ID=o;exports.SEPARATOR=e;exports.ZERO_LEVEL_ZERO_ITEM_ID=s;exports.createId=l;exports.getDirectParentId=O;exports.getDirectSiblingIdForLevelZero=L;exports.getFirstChildId=S;exports.getIdWithoutRootParentId=f;exports.getItemById=c;exports.getRootParentId=g;exports.getShortId=a;exports.isFirstItemFromSiblings=d;exports.isIdEmptyOrZeroLevel=i;exports.isIdFirstLevel=b;exports.isIdZeroLevel=u;exports.shouldOpenItem=E;
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
const u = "", c = "0", t = "_";
|
|
9
10
|
function f(n, r) {
|
|
10
11
|
if (i(n))
|
package/menu/utils/misc.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 n=require("../consts.js"),d=require("./itemsIdsUtils.js");function u(r,
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("../consts.js"),d=require("./itemsIdsUtils.js");function u(t,r,e){const o=i(t,r,e);return e?o==="downward"?n.POPUP_SETTINGS_RTL.downward:n.POPUP_SETTINGS_RTL.leftward:o==="downward"?n.POPUP_SETTINGS.downward:n.POPUP_SETTINGS.rightward}function i(t,r,e){return d.isIdZeroLevel(t)?r?e?"leftward":"rightward":"downward":e?"leftward":"rightward"}function l(t){return t?"rtl":"ltr"}function P(t,r){return`${t}_${r}`}exports.convertBoolDirectionToString=l;exports.getChildrenPosition=i;exports.getDOMElementId=P;exports.getPopupSettings=u;
|
package/menu/utils/misc.mjs
CHANGED
|
@@ -5,24 +5,25 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
|
|
9
|
-
import {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
8
|
+
"use client";
|
|
9
|
+
import { POPUP_SETTINGS_RTL as o, POPUP_SETTINGS as d } from "../consts.mjs";
|
|
10
|
+
import { isIdZeroLevel as i } from "./itemsIdsUtils.mjs";
|
|
11
|
+
function l(r, n, t) {
|
|
12
|
+
const e = w(r, n, t);
|
|
13
|
+
return t ? e === "downward" ? o.downward : o.leftward : e === "downward" ? d.downward : d.rightward;
|
|
13
14
|
}
|
|
14
|
-
function
|
|
15
|
-
return
|
|
15
|
+
function w(r, n, t) {
|
|
16
|
+
return i(r) ? n ? t ? "leftward" : "rightward" : "downward" : t ? "leftward" : "rightward";
|
|
16
17
|
}
|
|
17
|
-
function
|
|
18
|
+
function f(r) {
|
|
18
19
|
return r ? "rtl" : "ltr";
|
|
19
20
|
}
|
|
20
21
|
function P(r, n) {
|
|
21
22
|
return `${r}_${n}`;
|
|
22
23
|
}
|
|
23
24
|
export {
|
|
24
|
-
|
|
25
|
-
|
|
25
|
+
f as convertBoolDirectionToString,
|
|
26
|
+
w as getChildrenPosition,
|
|
26
27
|
P as getDOMElementId,
|
|
27
|
-
|
|
28
|
+
l as getPopupSettings
|
|
28
29
|
};
|
|
@@ -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 y=require("react"),s=require("./itemsIdsUtils.js"),R=require("../components/MenuItem.js");function O(t){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const r=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(n,e,r.get?r:{enumerable:!0,get:()=>t[e]})}}return n.default=t,Object.freeze(n)}const S=O(y);function C(t,n){if(t&&t.length>0)return{items:u(t),inputItems:t};if(c(n).length>0){const e=h(c(n));return{items:u(e),inputItems:e}}return{items:[],inputItems:[]}}function b(t,n){const e={},{text:r,url:o,icon:i,svgIcon:a,disabled:d,cssClass:l,cssStyle:f,render:p,linkRender:I,contentRender:m,data:g,separator:v}=t||n.props;return r!==void 0&&(e.text=r),o!==void 0&&(e.url=o),i!==void 0&&(e.icon=i),a!==void 0&&(e.svgIcon=a),d!==void 0&&(e.disabled=d),l!==void 0&&(e.cssClass=l),f!==void 0&&(e.cssStyle=f),p!==void 0&&(e.render=p),I!==void 0&&(e.linkRender=I),m!==void 0&&(e.contentRender=m),g!==void 0&&(e.data=g),v!==void 0&&(e.separator=v),e}function c(t){return S.Children.toArray(t).filter(n=>n&&n.type===R.MenuItem)}function h(t){const n=[];for(let e=0;e<t.length;e++){const r=t[e],o=b(void 0,r),i=h(c(r.props.children));i.length>0&&(o.items=i),n.push(o)}return n}function u(t,n){const e=[];for(let r=0;r<t.length;r++){const o=t[r],i=b(o);i.id=s.createId(r.toString(),n),i.isLastFromSiblings=r===t.length-1,i.separator=o.separator===!0,i.items=_(o,i),e.push(i)}return e}function _(t,n){return t.contentRender?[{contentParentItemId:n.id,id:s.createId(s.ZERO_LEVEL_ZERO_ITEM_ID,n.id),isLastFromSiblings:!0,separator:!1,contentRender:t.contentRender,items:[]}]:t.items?u(t.items,n.id):[]}exports.prepareInputItemsForInternalWork=C;
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const y=require("react"),s=require("./itemsIdsUtils.js"),R=require("../components/MenuItem.js");function O(t){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const r=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(n,e,r.get?r:{enumerable:!0,get:()=>t[e]})}}return n.default=t,Object.freeze(n)}const S=O(y);function C(t,n){if(t&&t.length>0)return{items:u(t),inputItems:t};if(c(n).length>0){const e=h(c(n));return{items:u(e),inputItems:e}}return{items:[],inputItems:[]}}function b(t,n){const e={},{text:r,url:o,icon:i,svgIcon:a,disabled:d,cssClass:l,cssStyle:f,render:p,linkRender:I,contentRender:m,data:g,separator:v}=t||n.props;return r!==void 0&&(e.text=r),o!==void 0&&(e.url=o),i!==void 0&&(e.icon=i),a!==void 0&&(e.svgIcon=a),d!==void 0&&(e.disabled=d),l!==void 0&&(e.cssClass=l),f!==void 0&&(e.cssStyle=f),p!==void 0&&(e.render=p),I!==void 0&&(e.linkRender=I),m!==void 0&&(e.contentRender=m),g!==void 0&&(e.data=g),v!==void 0&&(e.separator=v),e}function c(t){return S.Children.toArray(t).filter(n=>n&&n.type===R.MenuItem)}function h(t){const n=[];for(let e=0;e<t.length;e++){const r=t[e],o=b(void 0,r),i=h(c(r.props.children));i.length>0&&(o.items=i),n.push(o)}return n}function u(t,n){const e=[];for(let r=0;r<t.length;r++){const o=t[r],i=b(o);i.id=s.createId(r.toString(),n),i.isLastFromSiblings=r===t.length-1,i.separator=o.separator===!0,i.items=_(o,i),e.push(i)}return e}function _(t,n){return t.contentRender?[{contentParentItemId:n.id,id:s.createId(s.ZERO_LEVEL_ZERO_ITEM_ID,n.id),isLastFromSiblings:!0,separator:!1,contentRender:t.contentRender,items:[]}]:t.items?u(t.items,n.id):[]}exports.prepareInputItemsForInternalWork=C;
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
import * as C from "react";
|
|
9
10
|
import { createId as g, ZERO_LEVEL_ZERO_ITEM_ID as y } from "./itemsIdsUtils.mjs";
|
|
10
11
|
import { MenuItem as x } from "../components/MenuItem.mjs";
|
|
@@ -28,14 +29,14 @@ function h(e, n) {
|
|
|
28
29
|
svgIcon: d,
|
|
29
30
|
disabled: u,
|
|
30
31
|
cssClass: f,
|
|
31
|
-
cssStyle:
|
|
32
|
-
render:
|
|
32
|
+
cssStyle: l,
|
|
33
|
+
render: a,
|
|
33
34
|
linkRender: p,
|
|
34
35
|
contentRender: m,
|
|
35
36
|
data: I,
|
|
36
37
|
separator: v
|
|
37
38
|
} = e || n.props;
|
|
38
|
-
return i !== void 0 && (t.text = i), o !== void 0 && (t.url = o), r !== void 0 && (t.icon = r), d !== void 0 && (t.svgIcon = d), u !== void 0 && (t.disabled = u), f !== void 0 && (t.cssClass = f),
|
|
39
|
+
return i !== void 0 && (t.text = i), o !== void 0 && (t.url = o), r !== void 0 && (t.icon = r), d !== void 0 && (t.svgIcon = d), u !== void 0 && (t.disabled = u), f !== void 0 && (t.cssClass = f), l !== void 0 && (t.cssStyle = l), a !== void 0 && (t.render = a), p !== void 0 && (t.linkRender = p), m !== void 0 && (t.contentRender = m), I !== void 0 && (t.data = I), v !== void 0 && (t.separator = v), t;
|
|
39
40
|
}
|
|
40
41
|
function s(e) {
|
|
41
42
|
return C.Children.toArray(e).filter((n) => n && n.type === x);
|
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={name:"@progress/kendo-react-layout",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate:
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={name:"@progress/kendo-react-layout",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate: 1737713745,version:"9.4.0-develop.2",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};exports.packageMetadata=e;
|
package/package-metadata.mjs
CHANGED
|
@@ -5,13 +5,14 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
const e = {
|
|
9
10
|
name: "@progress/kendo-react-layout",
|
|
10
11
|
productName: "KendoReact",
|
|
11
12
|
productCode: "KENDOUIREACT",
|
|
12
13
|
productCodes: ["KENDOUIREACT"],
|
|
13
|
-
publishDate:
|
|
14
|
-
version: "9.4.0-develop.
|
|
14
|
+
publishDate: 1737713745,
|
|
15
|
+
version: "9.4.0-develop.2",
|
|
15
16
|
licensingDocsUrl: "https://www.telerik.com/kendo-react-ui/components/my-license/"
|
|
16
17
|
};
|
|
17
18
|
export {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@progress/kendo-react-layout",
|
|
3
|
-
"version": "9.4.0-develop.
|
|
3
|
+
"version": "9.4.0-develop.2",
|
|
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,11 +26,11 @@
|
|
|
26
26
|
"sideEffects": false,
|
|
27
27
|
"peerDependencies": {
|
|
28
28
|
"@progress/kendo-licensing": "^1.3.4",
|
|
29
|
-
"@progress/kendo-react-animation": "9.4.0-develop.
|
|
30
|
-
"@progress/kendo-react-common": "9.4.0-develop.
|
|
31
|
-
"@progress/kendo-react-intl": "9.4.0-develop.
|
|
32
|
-
"@progress/kendo-react-popup": "9.4.0-develop.
|
|
33
|
-
"@progress/kendo-react-progressbars": "9.4.0-develop.
|
|
29
|
+
"@progress/kendo-react-animation": "9.4.0-develop.2",
|
|
30
|
+
"@progress/kendo-react-common": "9.4.0-develop.2",
|
|
31
|
+
"@progress/kendo-react-intl": "9.4.0-develop.2",
|
|
32
|
+
"@progress/kendo-react-popup": "9.4.0-develop.2",
|
|
33
|
+
"@progress/kendo-react-progressbars": "9.4.0-develop.2",
|
|
34
34
|
"@progress/kendo-svg-icons": "^4.0.0",
|
|
35
35
|
"react": "^16.8.2 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc",
|
|
36
36
|
"react-dom": "^16.8.2 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc"
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"package": {
|
|
61
61
|
"productName": "KendoReact",
|
|
62
62
|
"productCode": "KENDOUIREACT",
|
|
63
|
-
"publishDate":
|
|
63
|
+
"publishDate": 1737713745,
|
|
64
64
|
"licensingDocsUrl": "https://www.telerik.com/kendo-react-ui/components/my-license/"
|
|
65
65
|
}
|
|
66
66
|
},
|
package/panelbar/PanelBar.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("prop-types"),v=require("./PanelBarItem.js"),p=require("./util.js"),o=require("@progress/kendo-react-common"),k=require("../package-metadata.js"),a=require("./interfaces/NavigationAction.js");function P(d){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(d){for(const r in d)if(r!=="default"){const e=Object.getOwnPropertyDescriptor(d,r);Object.defineProperty(n,r,e.get?e:{enumerable:!0,get:()=>d[r]})}}return n.default=d,Object.freeze(n)}const u=P(b),g=class g extends u.Component{constructor(n){super(n),this._element=null,this.showLicenseWatermark=!1,this.handleSelect=e=>{this.onSelect(e),this.onFocus(e)},this.onSelect=e=>{const c=p.flatChildren(u.Children.toArray(this.children));let i,s;switch(c.forEach(t=>{t.props.uniquePrivateKey===(e.uniquePrivateKey||this.state.focused)&&(i=t)}),this.expandMode){case"single":s=[...i.props.parentUniquePrivateKey,i.props.uniquePrivateKey],p.isArrayEqual(this.expandedItems,s)&&(i.props.parentUniquePrivateKey?s=[...i.props.parentUniquePrivateKey]:s=[]);break;case"multiple":{s=this.expandedItems.slice();const t=s.indexOf(i.props.uniquePrivateKey);t===-1?s.push(i.props.uniquePrivateKey):s.splice(t,1);break}default:s=this.expandedItems.slice();break}this.setState({selected:i.props.uniquePrivateKey,expanded:s}),this.props.onSelect&&this.props.onSelect.call(void 0,{target:i,expandedItems:s})},this.onFocus=(e,c=0,i)=>{const s=p.flatVisibleChildren(u.Children.toArray(this.children)),t=p.getFocusedChild(s,c,e,this.state.focused,i);if(t){const h=this.expandedItems.slice();if(i===a.NavigationAction.Right&&t&&t.props&&t.props.children&&t.props.children.length>0){if(h.push(t.props.uniquePrivateKey),this.setState({expanded:[...new Set(h)]}),t.props.expanded){const f=t.props.children[0].props.uniquePrivateKey;this.setState({focused:f})}}else if(i===a.NavigationAction.Left&&(t&&t.props&&t.props.parentUniquePrivateKey&&t.props.parentUniquePrivateKey.length>0||t&&t.props&&!t.props.disabled&&t.props.children&&t.props.children.length>0)){const f=t.props.parentUniquePrivateKey;if(t.props.expanded){const m=t.props.uniquePrivateKey,x=h.indexOf(m);h.splice(x,1),this.setState({expanded:h})}else if(t.props.level>0){const m=t.props.parentUniquePrivateKey[f.length-1];this.setState({focused:m})}}else this.activeDescendant=t.props.id,this.setState({focused:t.props.uniquePrivateKey})}},this.onNavigate=(e,c)=>{let i;switch(c){case a.NavigationAction.First:this.onFocus(e,i,a.NavigationAction.First);break;case a.NavigationAction.Last:this.onFocus(e,i,a.NavigationAction.Last);break;case a.NavigationAction.Left:this.onFocus(e,i,a.NavigationAction.Left);break;case a.NavigationAction.Right:this.onFocus(e,i,a.NavigationAction.Right);break;case a.NavigationAction.Previous:i=-1,this.onFocus(e,i);break;case a.NavigationAction.Next:i=1,this.onFocus(e,i);break;case a.NavigationAction.Toggle:this.onSelect(e);break}},this.handleWrapperFocus=()=>{clearTimeout(this.nextTickId),this.state.wrapperFocused||this.setState({wrapperFocused:!0})},this.handleWrapperBlur=()=>{this.nextTick(()=>{this.setState({wrapperFocused:!1})})},this.handleKeyDown=e=>{const c=this._element&&getComputedStyle(this._element).direction==="rtl"||!1;if(e.target===e.currentTarget){const i=e.keyCode;let s;switch(i){case o.Keys.left:s=c?a.NavigationAction.Right:a.NavigationAction.Left;break;case o.Keys.up:s=a.NavigationAction.Previous;break;case o.Keys.right:s=c?a.NavigationAction.Left:a.NavigationAction.Right;break;case o.Keys.down:s=a.NavigationAction.Next;break;case o.Keys.home:s=a.NavigationAction.First;break;case o.Keys.end:s=a.NavigationAction.Last;break;case o.Keys.space:case o.Keys.enter:s=a.NavigationAction.Toggle;break;default:s=null;break}s!==null&&(e.preventDefault(),this.onNavigate(e,s))}},o.validatePackage(k.packageMetadata),this.showLicenseWatermark=o.shouldShowValidationUI(k.packageMetadata);const r=p.getInitialState(n,this.expandMode);r.focused||(r.focused=p.getFirstId(n)),this.state=r}get expandMode(){return this.props.expandMode||"multiple"}get selectedItem(){const{selected:n=this.state.selected}=this.props;return n}get expandedItems(){return this.props.isControlled?this.props.expanded||[]:this.state.expanded}get children(){const n={...this.state,selected:this.selectedItem},r={animation:this.props.animation,keepItemsMounted:this.props.keepItemsMounted,state:n,expanded:this.expandedItems,handleSelect:this.handleSelect,children:this.props.children};return p.renderChildren(r)}render(){const n={"aria-activedescendant":this.activeDescendant},r=o.classNames("k-panelbar",this.props.className);return u.createElement("ul",{ref:e=>{this._element=e},dir:this.props.dir,role:"tree",tabIndex:0,onKeyDown:this.handleKeyDown,onFocus:this.handleWrapperFocus,onBlur:this.handleWrapperBlur,className:r,style:this.props.style,...n},this.children,this.showLicenseWatermark&&u.createElement(o.WatermarkOverlay,null))}nextTick(n){this.nextTickId=window.setTimeout(()=>n())}};g.propTypes={animation:l.bool,children:function(n,r){const e=n[r];if(e){if(Array.isArray(e)){for(const c of e)if(!c.type||c.type!==v.PanelBarItem)return new Error("PanelBar children should be either PanelBarItem or Array of PanelBarItem.")}else if(e.type!==v.PanelBarItem)return new Error("PanelBar child should be either PanelBarItem or Array of PanelBarItem.");return null}return null},dir:l.string,selected:l.string,expanded:l.arrayOf(l.string),focused:l.string,expandMode:l.oneOf(["single","multiple"]),className:l.string,keepItemsMounted:l.bool,onSelect:l.func,style:l.object},g.defaultProps={expandMode:"multiple",animation:!0,keepItemsMounted:!1};let y=g;exports.PanelBar=y;
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const b=require("react"),l=require("prop-types"),v=require("./PanelBarItem.js"),p=require("./util.js"),o=require("@progress/kendo-react-common"),k=require("../package-metadata.js"),a=require("./interfaces/NavigationAction.js");function P(d){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(d){for(const r in d)if(r!=="default"){const e=Object.getOwnPropertyDescriptor(d,r);Object.defineProperty(n,r,e.get?e:{enumerable:!0,get:()=>d[r]})}}return n.default=d,Object.freeze(n)}const u=P(b),g=class g extends u.Component{constructor(n){super(n),this._element=null,this.showLicenseWatermark=!1,this.handleSelect=e=>{this.onSelect(e),this.onFocus(e)},this.onSelect=e=>{const c=p.flatChildren(u.Children.toArray(this.children));let i,s;switch(c.forEach(t=>{t.props.uniquePrivateKey===(e.uniquePrivateKey||this.state.focused)&&(i=t)}),this.expandMode){case"single":s=[...i.props.parentUniquePrivateKey,i.props.uniquePrivateKey],p.isArrayEqual(this.expandedItems,s)&&(i.props.parentUniquePrivateKey?s=[...i.props.parentUniquePrivateKey]:s=[]);break;case"multiple":{s=this.expandedItems.slice();const t=s.indexOf(i.props.uniquePrivateKey);t===-1?s.push(i.props.uniquePrivateKey):s.splice(t,1);break}default:s=this.expandedItems.slice();break}this.setState({selected:i.props.uniquePrivateKey,expanded:s}),this.props.onSelect&&this.props.onSelect.call(void 0,{target:i,expandedItems:s})},this.onFocus=(e,c=0,i)=>{const s=p.flatVisibleChildren(u.Children.toArray(this.children)),t=p.getFocusedChild(s,c,e,this.state.focused,i);if(t){const h=this.expandedItems.slice();if(i===a.NavigationAction.Right&&t&&t.props&&t.props.children&&t.props.children.length>0){if(h.push(t.props.uniquePrivateKey),this.setState({expanded:[...new Set(h)]}),t.props.expanded){const f=t.props.children[0].props.uniquePrivateKey;this.setState({focused:f})}}else if(i===a.NavigationAction.Left&&(t&&t.props&&t.props.parentUniquePrivateKey&&t.props.parentUniquePrivateKey.length>0||t&&t.props&&!t.props.disabled&&t.props.children&&t.props.children.length>0)){const f=t.props.parentUniquePrivateKey;if(t.props.expanded){const m=t.props.uniquePrivateKey,x=h.indexOf(m);h.splice(x,1),this.setState({expanded:h})}else if(t.props.level>0){const m=t.props.parentUniquePrivateKey[f.length-1];this.setState({focused:m})}}else this.activeDescendant=t.props.id,this.setState({focused:t.props.uniquePrivateKey})}},this.onNavigate=(e,c)=>{let i;switch(c){case a.NavigationAction.First:this.onFocus(e,i,a.NavigationAction.First);break;case a.NavigationAction.Last:this.onFocus(e,i,a.NavigationAction.Last);break;case a.NavigationAction.Left:this.onFocus(e,i,a.NavigationAction.Left);break;case a.NavigationAction.Right:this.onFocus(e,i,a.NavigationAction.Right);break;case a.NavigationAction.Previous:i=-1,this.onFocus(e,i);break;case a.NavigationAction.Next:i=1,this.onFocus(e,i);break;case a.NavigationAction.Toggle:this.onSelect(e);break}},this.handleWrapperFocus=()=>{clearTimeout(this.nextTickId),this.state.wrapperFocused||this.setState({wrapperFocused:!0})},this.handleWrapperBlur=()=>{this.nextTick(()=>{this.setState({wrapperFocused:!1})})},this.handleKeyDown=e=>{const c=this._element&&getComputedStyle(this._element).direction==="rtl"||!1;if(e.target===e.currentTarget){const i=e.keyCode;let s;switch(i){case o.Keys.left:s=c?a.NavigationAction.Right:a.NavigationAction.Left;break;case o.Keys.up:s=a.NavigationAction.Previous;break;case o.Keys.right:s=c?a.NavigationAction.Left:a.NavigationAction.Right;break;case o.Keys.down:s=a.NavigationAction.Next;break;case o.Keys.home:s=a.NavigationAction.First;break;case o.Keys.end:s=a.NavigationAction.Last;break;case o.Keys.space:case o.Keys.enter:s=a.NavigationAction.Toggle;break;default:s=null;break}s!==null&&(e.preventDefault(),this.onNavigate(e,s))}},o.validatePackage(k.packageMetadata),this.showLicenseWatermark=o.shouldShowValidationUI(k.packageMetadata);const r=p.getInitialState(n,this.expandMode);r.focused||(r.focused=p.getFirstId(n)),this.state=r}get expandMode(){return this.props.expandMode||"multiple"}get selectedItem(){const{selected:n=this.state.selected}=this.props;return n}get expandedItems(){return this.props.isControlled?this.props.expanded||[]:this.state.expanded}get children(){const n={...this.state,selected:this.selectedItem},r={animation:this.props.animation,keepItemsMounted:this.props.keepItemsMounted,state:n,expanded:this.expandedItems,handleSelect:this.handleSelect,children:this.props.children};return p.renderChildren(r)}render(){const n={"aria-activedescendant":this.activeDescendant},r=o.classNames("k-panelbar",this.props.className);return u.createElement("ul",{ref:e=>{this._element=e},dir:this.props.dir,role:"tree",tabIndex:0,onKeyDown:this.handleKeyDown,onFocus:this.handleWrapperFocus,onBlur:this.handleWrapperBlur,className:r,style:this.props.style,...n},this.children,this.showLicenseWatermark&&u.createElement(o.WatermarkOverlay,null))}nextTick(n){this.nextTickId=window.setTimeout(()=>n())}};g.propTypes={animation:l.bool,children:function(n,r){const e=n[r];if(e){if(Array.isArray(e)){for(const c of e)if(!c.type||c.type!==v.PanelBarItem)return new Error("PanelBar children should be either PanelBarItem or Array of PanelBarItem.")}else if(e.type!==v.PanelBarItem)return new Error("PanelBar child should be either PanelBarItem or Array of PanelBarItem.");return null}return null},dir:l.string,selected:l.string,expanded:l.arrayOf(l.string),focused:l.string,expandMode:l.oneOf(["single","multiple"]),className:l.string,keepItemsMounted:l.bool,onSelect:l.func,style:l.object},g.defaultProps={expandMode:"multiple",animation:!0,keepItemsMounted:!1};let y=g;exports.PanelBar=y;
|
package/panelbar/PanelBar.mjs
CHANGED
|
@@ -5,50 +5,51 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
import * as c from "react";
|
|
9
10
|
import o from "prop-types";
|
|
10
11
|
import { PanelBarItem as m } from "./PanelBarItem.mjs";
|
|
11
12
|
import { flatChildren as k, isArrayEqual as P, flatVisibleChildren as b, getFocusedChild as I, getInitialState as S, getFirstId as K, renderChildren as v } from "./util.mjs";
|
|
12
13
|
import { Keys as l, validatePackage as w, shouldShowValidationUI as F, classNames as q, WatermarkOverlay as C } from "@progress/kendo-react-common";
|
|
13
14
|
import { packageMetadata as y } from "../package-metadata.mjs";
|
|
14
|
-
import { NavigationAction as
|
|
15
|
+
import { NavigationAction as r } from "./interfaces/NavigationAction.mjs";
|
|
15
16
|
const h = class h extends c.Component {
|
|
16
17
|
constructor(a) {
|
|
17
18
|
super(a), this._element = null, this.showLicenseWatermark = !1, this.handleSelect = (t) => {
|
|
18
19
|
this.onSelect(t), this.onFocus(t);
|
|
19
20
|
}, this.onSelect = (t) => {
|
|
20
21
|
const n = k(c.Children.toArray(this.children));
|
|
21
|
-
let s,
|
|
22
|
+
let s, i;
|
|
22
23
|
switch (n.forEach((e) => {
|
|
23
24
|
e.props.uniquePrivateKey === (t.uniquePrivateKey || this.state.focused) && (s = e);
|
|
24
25
|
}), this.expandMode) {
|
|
25
26
|
case "single":
|
|
26
|
-
|
|
27
|
+
i = [...s.props.parentUniquePrivateKey, s.props.uniquePrivateKey], P(this.expandedItems, i) && (s.props.parentUniquePrivateKey ? i = [...s.props.parentUniquePrivateKey] : i = []);
|
|
27
28
|
break;
|
|
28
29
|
case "multiple": {
|
|
29
|
-
|
|
30
|
-
const e =
|
|
31
|
-
e === -1 ?
|
|
30
|
+
i = this.expandedItems.slice();
|
|
31
|
+
const e = i.indexOf(s.props.uniquePrivateKey);
|
|
32
|
+
e === -1 ? i.push(s.props.uniquePrivateKey) : i.splice(e, 1);
|
|
32
33
|
break;
|
|
33
34
|
}
|
|
34
35
|
default:
|
|
35
|
-
|
|
36
|
+
i = this.expandedItems.slice();
|
|
36
37
|
break;
|
|
37
38
|
}
|
|
38
|
-
this.setState({ selected: s.props.uniquePrivateKey, expanded:
|
|
39
|
+
this.setState({ selected: s.props.uniquePrivateKey, expanded: i }), this.props.onSelect && this.props.onSelect.call(void 0, {
|
|
39
40
|
target: s,
|
|
40
|
-
expandedItems:
|
|
41
|
+
expandedItems: i
|
|
41
42
|
});
|
|
42
43
|
}, this.onFocus = (t, n = 0, s) => {
|
|
43
|
-
const
|
|
44
|
+
const i = b(c.Children.toArray(this.children)), e = I(i, n, t, this.state.focused, s);
|
|
44
45
|
if (e) {
|
|
45
46
|
const d = this.expandedItems.slice();
|
|
46
|
-
if (s ===
|
|
47
|
+
if (s === r.Right && e && e.props && e.props.children && e.props.children.length > 0) {
|
|
47
48
|
if (d.push(e.props.uniquePrivateKey), this.setState({ expanded: [...new Set(d)] }), e.props.expanded) {
|
|
48
49
|
const u = e.props.children[0].props.uniquePrivateKey;
|
|
49
50
|
this.setState({ focused: u });
|
|
50
51
|
}
|
|
51
|
-
} else if (s ===
|
|
52
|
+
} else if (s === r.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)) {
|
|
52
53
|
const u = e.props.parentUniquePrivateKey;
|
|
53
54
|
if (e.props.expanded) {
|
|
54
55
|
const f = e.props.uniquePrivateKey, g = d.indexOf(f);
|
|
@@ -63,25 +64,25 @@ const h = class h extends c.Component {
|
|
|
63
64
|
}, this.onNavigate = (t, n) => {
|
|
64
65
|
let s;
|
|
65
66
|
switch (n) {
|
|
66
|
-
case
|
|
67
|
-
this.onFocus(t, s,
|
|
67
|
+
case r.First:
|
|
68
|
+
this.onFocus(t, s, r.First);
|
|
68
69
|
break;
|
|
69
|
-
case
|
|
70
|
-
this.onFocus(t, s,
|
|
70
|
+
case r.Last:
|
|
71
|
+
this.onFocus(t, s, r.Last);
|
|
71
72
|
break;
|
|
72
|
-
case
|
|
73
|
-
this.onFocus(t, s,
|
|
73
|
+
case r.Left:
|
|
74
|
+
this.onFocus(t, s, r.Left);
|
|
74
75
|
break;
|
|
75
|
-
case
|
|
76
|
-
this.onFocus(t, s,
|
|
76
|
+
case r.Right:
|
|
77
|
+
this.onFocus(t, s, r.Right);
|
|
77
78
|
break;
|
|
78
|
-
case
|
|
79
|
+
case r.Previous:
|
|
79
80
|
s = -1, this.onFocus(t, s);
|
|
80
81
|
break;
|
|
81
|
-
case
|
|
82
|
+
case r.Next:
|
|
82
83
|
s = 1, this.onFocus(t, s);
|
|
83
84
|
break;
|
|
84
|
-
case
|
|
85
|
+
case r.Toggle:
|
|
85
86
|
this.onSelect(t);
|
|
86
87
|
break;
|
|
87
88
|
}
|
|
@@ -95,35 +96,35 @@ const h = class h extends c.Component {
|
|
|
95
96
|
const n = this._element && getComputedStyle(this._element).direction === "rtl" || !1;
|
|
96
97
|
if (t.target === t.currentTarget) {
|
|
97
98
|
const s = t.keyCode;
|
|
98
|
-
let
|
|
99
|
+
let i;
|
|
99
100
|
switch (s) {
|
|
100
101
|
case l.left:
|
|
101
|
-
|
|
102
|
+
i = n ? r.Right : r.Left;
|
|
102
103
|
break;
|
|
103
104
|
case l.up:
|
|
104
|
-
|
|
105
|
+
i = r.Previous;
|
|
105
106
|
break;
|
|
106
107
|
case l.right:
|
|
107
|
-
|
|
108
|
+
i = n ? r.Left : r.Right;
|
|
108
109
|
break;
|
|
109
110
|
case l.down:
|
|
110
|
-
|
|
111
|
+
i = r.Next;
|
|
111
112
|
break;
|
|
112
113
|
case l.home:
|
|
113
|
-
|
|
114
|
+
i = r.First;
|
|
114
115
|
break;
|
|
115
116
|
case l.end:
|
|
116
|
-
|
|
117
|
+
i = r.Last;
|
|
117
118
|
break;
|
|
118
119
|
case l.space:
|
|
119
120
|
case l.enter:
|
|
120
|
-
|
|
121
|
+
i = r.Toggle;
|
|
121
122
|
break;
|
|
122
123
|
default:
|
|
123
|
-
|
|
124
|
+
i = null;
|
|
124
125
|
break;
|
|
125
126
|
}
|
|
126
|
-
|
|
127
|
+
i !== null && (t.preventDefault(), this.onNavigate(t, i));
|
|
127
128
|
}
|
|
128
129
|
}, w(y), this.showLicenseWatermark = F(y);
|
|
129
130
|
const p = S(a, this.expandMode);
|
package/panelbar/PanelBarItem.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 P=require("react"),t=require("prop-types"),c=require("@progress/kendo-react-common"),y=require("@progress/kendo-svg-icons"),T=require("@progress/kendo-react-animation");function A(i){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(i){for(const e in i)if(e!=="default"){const s=Object.getOwnPropertyDescriptor(i,e);Object.defineProperty(n,e,s.get?s:{enumerable:!0,get:()=>i[e]})}}return n.default=i,Object.freeze(n)}const a=A(P);function j({imageUrl:i,icon:n,svgIcon:e,iconClass:s}){return i?a.createElement("img",{role:"presentation",className:"k-panelbar-item-icon k-image",src:i}):n||e?a.createElement(c.IconWrap,{className:"k-panelbar-item-icon",name:n,icon:e}):s?a.createElement("span",{role:"presentation",className:"k-panelbar-item-icon "+s}):null}const d=class d extends a.PureComponent{constructor(n){super(n),this.handleItemClick=()=>{const{onSelect:e,disabled:s,id:p}=this.props;e&&!s&&e.call(void 0,{uniquePrivateKey:this.props.uniquePrivateKey,id:p,target:this})},this.childFactory=e=>this.props.keepItemsMounted?a.cloneElement(e,{...e.props,in:this.props.expanded}):e,this.state={show:n.expanded||!1}}render(){const{id:n,children:e,title:s,uniquePrivateKey:p,disabled:r,selected:m,focused:g,expanded:o,className:v,level:h,headerClassName:N,animation:b,keepItemsMounted:l}=this.props,E={role:"treeitem","aria-disabled":r,"aria-hidden":!r&&!o,"aria-selected":!r&&m,"aria-expanded":!r&&o&&!!e},x=c.classNames("k-panelbar-item",{"k-panelbar-header":h===0,"k-expanded":o&&!!e,"k-disabled":r},`k-level-${h}`,v),I=c.classNames("k-link",{"k-selected":!r&&m,"k-focus":g},N),S={display:"block"},C=j(this.props),O=!r&&e?a.createElement(c.IconWrap,{name:o?"chevron-up":"chevron-down",icon:o?y.chevronUpIcon:y.chevronDownIcon,className:c.classNames("k-panelbar-toggle",o?"k-panelbar-collapse":"k-panelbar-expand")}):null;let k=!1;e&&e[0]&&Array.isArray(e)&&(k=e[0].type===d);const q=k?a.createElement("ul",{role:"group","aria-expanded":o,"aria-hidden":!o,className:"k-panelbar-group",style:{display:l?this.state.show?"block":"none":"block"}},e):e,f=!r&&o||l?q:null,w=(b===void 0||b)&&!r&&e?a.createElement(T.Reveal,{transitionEnterDuration:200,transitionExitDuration:200,key:p+"_animation",style:S,children:f,childFactory:l&&this.childFactory,unmountOnExit:!l,onBeforeEnter:()=>l&&this.setState({show:!0}),onAfterExited:()=>l&&this.setState({show:!1})}):f;return a.createElement("li",{id:n,className:x,...E},a.createElement("span",{className:I,onClick:this.handleItemClick},C,a.createElement("span",{className:"k-panelbar-item-text"},s),O),w)}};d.propTypes={animation:t.bool,children:t.any,className:t.string,icon:t.string,iconClass:t.string,imageUrl:t.string,svgIcon:c.svgIconPropType,expanded:t.bool,disabled:t.bool,onSelect:t.func,selected:t.bool,level:t.number,title:t.oneOfType([t.string,t.element]),id:t.oneOfType([t.string,t.number]),focused:t.bool,keepItemsMounted:t.bool},d.defaultProps={title:"Untitled"};let u=d;exports.PanelBarItem=u;
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const P=require("react"),t=require("prop-types"),c=require("@progress/kendo-react-common"),y=require("@progress/kendo-svg-icons"),T=require("@progress/kendo-react-animation");function A(i){const n=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(i){for(const e in i)if(e!=="default"){const s=Object.getOwnPropertyDescriptor(i,e);Object.defineProperty(n,e,s.get?s:{enumerable:!0,get:()=>i[e]})}}return n.default=i,Object.freeze(n)}const a=A(P);function j({imageUrl:i,icon:n,svgIcon:e,iconClass:s}){return i?a.createElement("img",{role:"presentation",className:"k-panelbar-item-icon k-image",src:i}):n||e?a.createElement(c.IconWrap,{className:"k-panelbar-item-icon",name:n,icon:e}):s?a.createElement("span",{role:"presentation",className:"k-panelbar-item-icon "+s}):null}const d=class d extends a.PureComponent{constructor(n){super(n),this.handleItemClick=()=>{const{onSelect:e,disabled:s,id:p}=this.props;e&&!s&&e.call(void 0,{uniquePrivateKey:this.props.uniquePrivateKey,id:p,target:this})},this.childFactory=e=>this.props.keepItemsMounted?a.cloneElement(e,{...e.props,in:this.props.expanded}):e,this.state={show:n.expanded||!1}}render(){const{id:n,children:e,title:s,uniquePrivateKey:p,disabled:r,selected:m,focused:g,expanded:o,className:v,level:h,headerClassName:N,animation:b,keepItemsMounted:l}=this.props,E={role:"treeitem","aria-disabled":r,"aria-hidden":!r&&!o,"aria-selected":!r&&m,"aria-expanded":!r&&o&&!!e},x=c.classNames("k-panelbar-item",{"k-panelbar-header":h===0,"k-expanded":o&&!!e,"k-disabled":r},`k-level-${h}`,v),I=c.classNames("k-link",{"k-selected":!r&&m,"k-focus":g},N),S={display:"block"},C=j(this.props),O=!r&&e?a.createElement(c.IconWrap,{name:o?"chevron-up":"chevron-down",icon:o?y.chevronUpIcon:y.chevronDownIcon,className:c.classNames("k-panelbar-toggle",o?"k-panelbar-collapse":"k-panelbar-expand")}):null;let k=!1;e&&e[0]&&Array.isArray(e)&&(k=e[0].type===d);const q=k?a.createElement("ul",{role:"group","aria-expanded":o,"aria-hidden":!o,className:"k-panelbar-group",style:{display:l?this.state.show?"block":"none":"block"}},e):e,f=!r&&o||l?q:null,w=(b===void 0||b)&&!r&&e?a.createElement(T.Reveal,{transitionEnterDuration:200,transitionExitDuration:200,key:p+"_animation",style:S,children:f,childFactory:l&&this.childFactory,unmountOnExit:!l,onBeforeEnter:()=>l&&this.setState({show:!0}),onAfterExited:()=>l&&this.setState({show:!1})}):f;return a.createElement("li",{id:n,className:x,...E},a.createElement("span",{className:I,onClick:this.handleItemClick},C,a.createElement("span",{className:"k-panelbar-item-text"},s),O),w)}};d.propTypes={animation:t.bool,children:t.any,className:t.string,icon:t.string,iconClass:t.string,imageUrl:t.string,svgIcon:c.svgIconPropType,expanded:t.bool,disabled:t.bool,onSelect:t.func,selected:t.bool,level:t.number,title:t.oneOfType([t.string,t.element]),id:t.oneOfType([t.string,t.number]),focused:t.bool,keepItemsMounted:t.bool},d.defaultProps={title:"Untitled"};let u=d;exports.PanelBarItem=u;
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
+
"use client";
|
|
8
9
|
import * as n from "react";
|
|
9
10
|
import t from "prop-types";
|
|
10
11
|
import { svgIconPropType as P, classNames as p, IconWrap as y } from "@progress/kendo-react-common";
|