@progress/kendo-react-buttons 10.0.0 → 10.1.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/ListButton/DropDownButton.js +1 -1
- package/ListButton/DropDownButton.mjs +100 -92
- package/dist/cdn/js/kendo-react-buttons.js +1 -1
- package/index.d.mts +115 -90
- package/index.d.ts +115 -90
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +2 -2
- package/package.json +13 -4
|
@@ -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 F=require("react"),o=require("prop-types"),N=require("../Button.js"),e=require("@progress/kendo-react-common"),R=require("./utils/navigation.js"),A=require("./DropDownButtonItem.js"),M=require("./ButtonItem.js"),T=require("@progress/kendo-react-popup"),m=require("./utils/popup.js"),q=require("../package-metadata.js");function j(d){const i=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(d){for(const t in d)if(t!=="default"){const s=Object.getOwnPropertyDescriptor(d,t);Object.defineProperty(i,t,s.get?s:{enumerable:!0,get:()=>d[t]})}}return i.default=d,Object.freeze(i)}const u=j(F),z=12e3,L=2e3,l=class l extends u.Component{constructor(i){super(i),this.state={opened:!1,focused:!1,focusedIndex:-1},this.mainButton=null,this.list=null,this.skipFocus=!1,this.showLicenseWatermark=!1,this.buttonsData=[],this.onKeyDown=t=>{const{focusedIndex:s}=this.state;if(t.altKey){!this.opened&&t.keyCode===e.Keys.down?(t.preventDefault(),this.setOpen(!0,t),this.setState({focusedIndex:0})):this.opened&&t.keyCode===e.Keys.up&&(t.preventDefault(),this.setState({focusedIndex:-1}),this.setOpen(!1,t));return}const n={...this.state};if(t.keyCode===e.Keys.enter||t.keyCode===e.Keys.space){t.preventDefault(),s>=0&&this.dispatchClickEvent(t,s);const a=!this.opened;this.setState({focused:!0,focusedIndex:a?0:-1}),this.setOpen(a,t);return}if(this.opened&&t.keyCode===e.Keys.esc){this.setState({focusedIndex:-1}),this.setOpen(!1,t);return}if(this.opened){const a=R.navigate(s,t.keyCode,t.altKey,this.buttonsData.length);n.focusedIndex=a;const p=t.keyCode===e.Keys.up||t.keyCode===e.Keys.down||t.keyCode===e.Keys.left||t.keyCode===e.Keys.right;!t.altKey&&(p||t.keyCode===e.Keys.home||t.keyCode===e.Keys.end)&&t.preventDefault()}this.setState(n)},this.switchFocus=t=>{this.skipFocus=!0,t(),window.setTimeout(()=>this.skipFocus=!1,0)},this.handleFocus=t=>{this.skipFocus||(this.setState({focused:!0,focusedIndex:this.opened?0:-1}),e.dispatchEvent(this.props.onFocus,t,this,void 0))},this.handleButtonBlur=t=>{this.opened||(this.setState({focused:!1}),e.dispatchEvent(this.props.onBlur,t,this,void 0))},this.handleMenuBlur=t=>{this.skipFocus||(this.setState({focused:!1,focusedIndex:-1}),e.dispatchEvent(this.props.onBlur,t,this,void 0),setTimeout(()=>{this.setOpen(!1,t)},0))},this.setOpen=(t,s)=>{this.opened!==t&&(this.openedDuringOnChange=t,this.setState({opened:t}),s?this.dispatchPopupEvent(s,t):this.openedDuringOnChange=void 0)},this.onItemClick=(t,s)=>{this.setState({focusedIndex:-1}),this.dispatchClickEvent(t,s),this.setOpen(!1,t)},this.onItemDown=t=>{e.getActiveElement(document)===this.list&&t.preventDefault()},this.mouseDown=t=>{t.preventDefault();const s=e.getActiveElement(document);this.element&&s!==this.element&&s!==this.list&&this.element.focus()},this.onPopupClose=t=>{var n;const s=e.getActiveElement(document);this.element&&this.element.removeAttribute("tabindex"),(s===this.list||(n=this.list)!=null&&n.contains(s))&&this.switchFocus(()=>{this.element&&this.element.focus({preventScroll:!0})}),this.props.popupSettings&&this.props.popupSettings.onClose&&this.props.popupSettings.onClose.call(void 0,t)},this.listRef=t=>{this.list=t,t&&this.state.focused&&this.switchFocus(()=>{t.focus({preventScroll:!0}),this.element&&(this.element.tabIndex=-1)})},this.onClickMainButton=t=>{if(!this.buttonsData.length)return;const s=!this.opened;this.setState({focused:!0,focusedIndex:s?0:-1}),this.setOpen(s,t)},this.dispatchPopupEvent=(t,s)=>{e.dispatchEvent(s?this.props.onOpen:this.props.onClose,t,this,void 0),this.openedDuringOnChange=void 0},this.showLicenseWatermark=!e.validatePackage(q.packageMetadata,{component:"DropDownButton"})}get guid(){return this.props.id+"-accessibility-id"}get opened(){return this.openedDuringOnChange!==void 0?this.openedDuringOnChange:this.props.opened===void 0?this.state.opened:this.props.opened}render(){const i=this.isRtl(),t=this.props.unstyled&&this.props.unstyled.uDropDownButton,s=i?"rtl":void 0,{id:n,style:a,tabIndex:p,disabled:r,size:g,rounded:y,fillMode:C,themeColor:b,ariaLabel:w,title:I,accessKey:k,icon:B,svgIcon:O,iconClass:E,buttonClass:v,className:S,imageUrl:x,startIcon:P,endIcon:K}=this.props;return this.buttonsData=this.props.items||u.Children.toArray(this.props.children).filter(c=>c&&c.type===A.DropDownButtonItem).map(c=>c.props),u.createElement(u.Fragment,null,u.createElement(N.Button,{id:n,size:g,style:a,rounded:y,fillMode:C,themeColor:b,onClick:this.onClickMainButton,onMouseDown:this.mouseDown,onKeyDown:this.onKeyDown,onFocus:this.handleFocus,onBlur:this.handleButtonBlur,"aria-disabled":r?"true":void 0,tabIndex:p,accessKey:k,icon:B,svgIcon:O,iconClass:E,className:e.classNames(v,S,e.uDropDownButton.wrapper({c:t,focused:this.state.focused,disabled:r})),imageUrl:x,dir:s,ref:c=>this.mainButton=c&&c.element,type:"button","aria-expanded":this.opened?"true":"false","aria-label":w,"aria-controls":this.opened?this.guid:void 0,title:I,startIcon:P,endIcon:K},this.props.text),this.showLicenseWatermark&&u.createElement(e.WatermarkOverlay,null),this.renderPopup(i))}componentDidMount(){(this.props.dir===void 0&&this.isRtl()||this.opened)&&this.forceUpdate()}get element(){return this.mainButton}dispatchClickEvent(i,t){this.isItemDisabled(t)||e.dispatchEvent(this.props.onItemClick,i,this,{item:this.buttonsData[t],itemIndex:t})}renderPopup(i){const{popupSettings:t={},_zIndex:s,unstyled:n}=this.props,a=s?s+L:z,p=n&&n.uDropDownButton,{focusedIndex:r}=this.state;return u.createElement(e.ZIndexContext.Provider,{value:a},u.createElement(T.Popup,{anchor:this.mainButton,show:this.opened,animate:t.animate,popupClass:e.classNames(e.uDropDownButton.popup({c:p}),t.popupClass),anchorAlign:t.anchorAlign||m.getAnchorAlign(i),popupAlign:t.popupAlign||m.getPopupAlign(i),style:i?{direction:"rtl"}:void 0,onClose:this.onPopupClose},u.createElement("ul",{role:"list",id:this.guid,tabIndex:-1,"aria-activedescendant":r>=0?`${this.guid}-${r}`:void 0,ref:this.listRef,onKeyDown:this.onKeyDown,onBlur:this.handleMenuBlur,className:e.classNames(e.uDropDownButton.ul({c:p,size:this.props.size}))},this.renderChildItems())))}renderChildItems(){const{item:i,itemRender:t,textField:s,unstyled:n}=this.props,a=n&&n.uDropDownButton;return this.buttonsData.length>0?this.buttonsData.map((p,r)=>u.createElement(M.ButtonItem,{className:e.classNames(e.uDropDownButton.item({c:a}),p.className,{"k-first":r===0},{"k-last":r===this.buttonsData.length-1}),dataItem:p,textField:s,focused:this.state.focusedIndex===r,onClick:this.onItemClick,onDown:this.onItemDown,render:t,item:i,index:r,key:r,id:`${this.guid}-${r}`})):null}isItemDisabled(i){return this.buttonsData[i]?this.buttonsData[i].disabled:this.props.disabled}isRtl(){return this.props.dir!==void 0?this.props.dir==="rtl":!!this.mainButton&&getComputedStyle(this.mainButton).direction==="rtl"}};l.propTypes={accessKey:o.string,ariaLabel:o.string,title:o.string,onFocus:o.func,onBlur:o.func,onItemClick:o.func,onOpen:o.func,onClose:o.func,items:o.arrayOf(o.any),textField:o.string,tabIndex:o.number,disabled:o.bool,icon:o.string,svgIcon:e.svgIconPropType,iconClass:o.string,imageUrl:o.string,popupSettings:o.object,itemRender:o.func,item:o.func,className:o.string,buttonClass:o.string,dir:o.string},l.defaultProps={size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let h=l;const f=e.createPropsContext(),D=e.withIdHOC(e.withPropsContext(f,e.withUnstyledHOC(e.withZIndexContext(h))));D.displayName="KendoReactDropDownButton";exports.DropDownButton=D;exports.DropDownButtonPropsContext=f;exports.DropDownButtonWithoutContext=h;
|
|
@@ -5,17 +5,17 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import * as
|
|
8
|
+
import * as p from "react";
|
|
9
9
|
import s from "prop-types";
|
|
10
|
-
import { Button as
|
|
11
|
-
import { Keys as r, dispatchEvent as
|
|
12
|
-
import { navigate as
|
|
13
|
-
import { DropDownButtonItem as
|
|
14
|
-
import { ButtonItem as
|
|
15
|
-
import { Popup as
|
|
16
|
-
import { getAnchorAlign as
|
|
17
|
-
import { packageMetadata as
|
|
18
|
-
const
|
|
10
|
+
import { Button as N } from "../Button.mjs";
|
|
11
|
+
import { Keys as r, dispatchEvent as l, getActiveElement as f, validatePackage as K, svgIconPropType as A, classNames as u, uDropDownButton as c, WatermarkOverlay as R, ZIndexContext as M, createPropsContext as T, withIdHOC as L, withPropsContext as z, withUnstyledHOC as U, withZIndexContext as Z } from "@progress/kendo-react-common";
|
|
12
|
+
import { navigate as $ } from "./utils/navigation.mjs";
|
|
13
|
+
import { DropDownButtonItem as W } from "./DropDownButtonItem.mjs";
|
|
14
|
+
import { ButtonItem as _ } from "./ButtonItem.mjs";
|
|
15
|
+
import { Popup as H } from "@progress/kendo-react-popup";
|
|
16
|
+
import { getAnchorAlign as X, getPopupAlign as j } from "./utils/popup.mjs";
|
|
17
|
+
import { packageMetadata as q } from "../package-metadata.mjs";
|
|
18
|
+
const G = 12e3, J = 2e3, m = class m extends p.Component {
|
|
19
19
|
constructor(i) {
|
|
20
20
|
super(i), this.state = {
|
|
21
21
|
opened: !1,
|
|
@@ -30,11 +30,11 @@ const c = class c extends h.Component {
|
|
|
30
30
|
const o = { ...this.state };
|
|
31
31
|
if (t.keyCode === r.enter || t.keyCode === r.space) {
|
|
32
32
|
t.preventDefault(), e >= 0 && this.dispatchClickEvent(t, e);
|
|
33
|
-
const
|
|
33
|
+
const a = !this.opened;
|
|
34
34
|
this.setState({
|
|
35
35
|
focused: !0,
|
|
36
|
-
focusedIndex:
|
|
37
|
-
}), this.setOpen(
|
|
36
|
+
focusedIndex: a ? 0 : -1
|
|
37
|
+
}), this.setOpen(a, t);
|
|
38
38
|
return;
|
|
39
39
|
}
|
|
40
40
|
if (this.opened && t.keyCode === r.esc) {
|
|
@@ -42,20 +42,20 @@ const c = class c extends h.Component {
|
|
|
42
42
|
return;
|
|
43
43
|
}
|
|
44
44
|
if (this.opened) {
|
|
45
|
-
const
|
|
46
|
-
o.focusedIndex =
|
|
47
|
-
const
|
|
48
|
-
!t.altKey && (
|
|
45
|
+
const a = $(e, t.keyCode, t.altKey, this.buttonsData.length);
|
|
46
|
+
o.focusedIndex = a;
|
|
47
|
+
const h = t.keyCode === r.up || t.keyCode === r.down || t.keyCode === r.left || t.keyCode === r.right;
|
|
48
|
+
!t.altKey && (h || t.keyCode === r.home || t.keyCode === r.end) && t.preventDefault();
|
|
49
49
|
}
|
|
50
50
|
this.setState(o);
|
|
51
51
|
}, this.switchFocus = (t) => {
|
|
52
52
|
this.skipFocus = !0, t(), window.setTimeout(() => this.skipFocus = !1, 0);
|
|
53
53
|
}, this.handleFocus = (t) => {
|
|
54
|
-
this.skipFocus || (this.setState({ focused: !0, focusedIndex: this.opened ? 0 : -1 }),
|
|
54
|
+
this.skipFocus || (this.setState({ focused: !0, focusedIndex: this.opened ? 0 : -1 }), l(this.props.onFocus, t, this, void 0));
|
|
55
55
|
}, this.handleButtonBlur = (t) => {
|
|
56
|
-
this.opened || (this.setState({ focused: !1 }),
|
|
56
|
+
this.opened || (this.setState({ focused: !1 }), l(this.props.onBlur, t, this, void 0));
|
|
57
57
|
}, this.handleMenuBlur = (t) => {
|
|
58
|
-
this.skipFocus || (this.setState({ focused: !1, focusedIndex: -1 }),
|
|
58
|
+
this.skipFocus || (this.setState({ focused: !1, focusedIndex: -1 }), l(this.props.onBlur, t, this, void 0), setTimeout(() => {
|
|
59
59
|
this.setOpen(!1, t);
|
|
60
60
|
}, 0));
|
|
61
61
|
}, this.setOpen = (t, e) => {
|
|
@@ -63,14 +63,14 @@ const c = class c extends h.Component {
|
|
|
63
63
|
}, this.onItemClick = (t, e) => {
|
|
64
64
|
this.setState({ focusedIndex: -1 }), this.dispatchClickEvent(t, e), this.setOpen(!1, t);
|
|
65
65
|
}, this.onItemDown = (t) => {
|
|
66
|
-
|
|
66
|
+
f(document) === this.list && t.preventDefault();
|
|
67
67
|
}, this.mouseDown = (t) => {
|
|
68
68
|
t.preventDefault();
|
|
69
|
-
const e =
|
|
69
|
+
const e = f(document);
|
|
70
70
|
this.element && e !== this.element && e !== this.list && this.element.focus();
|
|
71
71
|
}, this.onPopupClose = (t) => {
|
|
72
72
|
var o;
|
|
73
|
-
const e =
|
|
73
|
+
const e = f(document);
|
|
74
74
|
this.element && this.element.removeAttribute("tabindex"), (e === this.list || (o = this.list) != null && o.contains(e)) && this.switchFocus(() => {
|
|
75
75
|
this.element && this.element.focus({ preventScroll: !0 });
|
|
76
76
|
}), this.props.popupSettings && this.props.popupSettings.onClose && this.props.popupSettings.onClose.call(void 0, t);
|
|
@@ -87,8 +87,8 @@ const c = class c extends h.Component {
|
|
|
87
87
|
focusedIndex: e ? 0 : -1
|
|
88
88
|
}), this.setOpen(e, t);
|
|
89
89
|
}, this.dispatchPopupEvent = (t, e) => {
|
|
90
|
-
|
|
91
|
-
}, this.showLicenseWatermark = !
|
|
90
|
+
l(e ? this.props.onOpen : this.props.onClose, t, this, void 0), this.openedDuringOnChange = void 0;
|
|
91
|
+
}, this.showLicenseWatermark = !K(q, { component: "DropDownButton" });
|
|
92
92
|
}
|
|
93
93
|
get guid() {
|
|
94
94
|
return this.props.id + "-accessibility-id";
|
|
@@ -100,69 +100,69 @@ const c = class c extends h.Component {
|
|
|
100
100
|
* @hidden
|
|
101
101
|
*/
|
|
102
102
|
render() {
|
|
103
|
-
const i = this.isRtl(), t = this.
|
|
103
|
+
const i = this.isRtl(), t = this.props.unstyled && this.props.unstyled.uDropDownButton, e = i ? "rtl" : void 0, {
|
|
104
104
|
id: o,
|
|
105
|
-
style:
|
|
106
|
-
tabIndex:
|
|
107
|
-
disabled:
|
|
105
|
+
style: a,
|
|
106
|
+
tabIndex: h,
|
|
107
|
+
disabled: n,
|
|
108
108
|
size: C,
|
|
109
109
|
rounded: D,
|
|
110
110
|
fillMode: y,
|
|
111
|
-
themeColor:
|
|
112
|
-
ariaLabel:
|
|
113
|
-
title:
|
|
111
|
+
themeColor: I,
|
|
112
|
+
ariaLabel: k,
|
|
113
|
+
title: b,
|
|
114
114
|
accessKey: w,
|
|
115
|
-
icon:
|
|
116
|
-
svgIcon:
|
|
117
|
-
iconClass:
|
|
118
|
-
buttonClass:
|
|
119
|
-
className:
|
|
120
|
-
imageUrl:
|
|
121
|
-
startIcon:
|
|
122
|
-
endIcon:
|
|
115
|
+
icon: B,
|
|
116
|
+
svgIcon: O,
|
|
117
|
+
iconClass: x,
|
|
118
|
+
buttonClass: E,
|
|
119
|
+
className: S,
|
|
120
|
+
imageUrl: P,
|
|
121
|
+
startIcon: F,
|
|
122
|
+
endIcon: v
|
|
123
123
|
} = this.props;
|
|
124
|
-
return this.buttonsData = this.props.items ||
|
|
125
|
-
|
|
124
|
+
return this.buttonsData = this.props.items || p.Children.toArray(this.props.children).filter((d) => d && d.type === W).map((d) => d.props), /* @__PURE__ */ p.createElement(p.Fragment, null, /* @__PURE__ */ p.createElement(
|
|
125
|
+
N,
|
|
126
126
|
{
|
|
127
127
|
id: o,
|
|
128
128
|
size: C,
|
|
129
|
-
style:
|
|
129
|
+
style: a,
|
|
130
130
|
rounded: D,
|
|
131
131
|
fillMode: y,
|
|
132
|
-
themeColor:
|
|
132
|
+
themeColor: I,
|
|
133
133
|
onClick: this.onClickMainButton,
|
|
134
134
|
onMouseDown: this.mouseDown,
|
|
135
135
|
onKeyDown: this.onKeyDown,
|
|
136
136
|
onFocus: this.handleFocus,
|
|
137
137
|
onBlur: this.handleButtonBlur,
|
|
138
|
-
"aria-disabled":
|
|
139
|
-
tabIndex:
|
|
138
|
+
"aria-disabled": n ? "true" : void 0,
|
|
139
|
+
tabIndex: h,
|
|
140
140
|
accessKey: w,
|
|
141
|
-
icon:
|
|
142
|
-
svgIcon:
|
|
143
|
-
iconClass:
|
|
144
|
-
className:
|
|
145
|
-
O,
|
|
141
|
+
icon: B,
|
|
142
|
+
svgIcon: O,
|
|
143
|
+
iconClass: x,
|
|
144
|
+
className: u(
|
|
146
145
|
E,
|
|
147
|
-
|
|
146
|
+
S,
|
|
147
|
+
c.wrapper({
|
|
148
148
|
c: t,
|
|
149
149
|
focused: this.state.focused,
|
|
150
|
-
disabled:
|
|
150
|
+
disabled: n
|
|
151
151
|
})
|
|
152
152
|
),
|
|
153
|
-
imageUrl:
|
|
153
|
+
imageUrl: P,
|
|
154
154
|
dir: e,
|
|
155
|
-
ref: (
|
|
155
|
+
ref: (d) => this.mainButton = d && d.element,
|
|
156
156
|
type: "button",
|
|
157
157
|
"aria-expanded": this.opened ? "true" : "false",
|
|
158
|
-
"aria-label":
|
|
158
|
+
"aria-label": k,
|
|
159
159
|
"aria-controls": this.opened ? this.guid : void 0,
|
|
160
|
-
title:
|
|
161
|
-
startIcon:
|
|
162
|
-
endIcon:
|
|
160
|
+
title: b,
|
|
161
|
+
startIcon: F,
|
|
162
|
+
endIcon: v
|
|
163
163
|
},
|
|
164
164
|
this.props.text
|
|
165
|
-
), this.showLicenseWatermark && /* @__PURE__ */
|
|
165
|
+
), this.showLicenseWatermark && /* @__PURE__ */ p.createElement(R, null), this.renderPopup(i));
|
|
166
166
|
}
|
|
167
167
|
/**
|
|
168
168
|
* @hidden
|
|
@@ -177,26 +177,26 @@ const c = class c extends h.Component {
|
|
|
177
177
|
return this.mainButton;
|
|
178
178
|
}
|
|
179
179
|
dispatchClickEvent(i, t) {
|
|
180
|
-
this.isItemDisabled(t) ||
|
|
180
|
+
this.isItemDisabled(t) || l(this.props.onItemClick, i, this, {
|
|
181
181
|
item: this.buttonsData[t],
|
|
182
182
|
itemIndex: t
|
|
183
183
|
});
|
|
184
184
|
}
|
|
185
185
|
renderPopup(i) {
|
|
186
|
-
const { popupSettings: t = {},
|
|
187
|
-
return /* @__PURE__ */
|
|
188
|
-
|
|
186
|
+
const { popupSettings: t = {}, _zIndex: e, unstyled: o } = this.props, a = e ? e + J : G, h = o && o.uDropDownButton, { focusedIndex: n } = this.state;
|
|
187
|
+
return /* @__PURE__ */ p.createElement(M.Provider, { value: a }, /* @__PURE__ */ p.createElement(
|
|
188
|
+
H,
|
|
189
189
|
{
|
|
190
190
|
anchor: this.mainButton,
|
|
191
191
|
show: this.opened,
|
|
192
192
|
animate: t.animate,
|
|
193
|
-
popupClass:
|
|
194
|
-
anchorAlign: t.anchorAlign ||
|
|
195
|
-
popupAlign: t.popupAlign ||
|
|
193
|
+
popupClass: u(c.popup({ c: h }), t.popupClass),
|
|
194
|
+
anchorAlign: t.anchorAlign || X(i),
|
|
195
|
+
popupAlign: t.popupAlign || j(i),
|
|
196
196
|
style: i ? { direction: "rtl" } : void 0,
|
|
197
197
|
onClose: this.onPopupClose
|
|
198
198
|
},
|
|
199
|
-
/* @__PURE__ */
|
|
199
|
+
/* @__PURE__ */ p.createElement(
|
|
200
200
|
"ul",
|
|
201
201
|
{
|
|
202
202
|
role: "list",
|
|
@@ -206,40 +206,40 @@ const c = class c extends h.Component {
|
|
|
206
206
|
ref: this.listRef,
|
|
207
207
|
onKeyDown: this.onKeyDown,
|
|
208
208
|
onBlur: this.handleMenuBlur,
|
|
209
|
-
className:
|
|
210
|
-
|
|
211
|
-
c:
|
|
209
|
+
className: u(
|
|
210
|
+
c.ul({
|
|
211
|
+
c: h,
|
|
212
212
|
size: this.props.size
|
|
213
213
|
})
|
|
214
214
|
)
|
|
215
215
|
},
|
|
216
216
|
this.renderChildItems()
|
|
217
217
|
)
|
|
218
|
-
);
|
|
218
|
+
));
|
|
219
219
|
}
|
|
220
220
|
renderChildItems() {
|
|
221
|
-
const { item: i, itemRender: t, textField: e } = this.props,
|
|
222
|
-
return this.buttonsData.length > 0 ? this.buttonsData.map((
|
|
223
|
-
|
|
221
|
+
const { item: i, itemRender: t, textField: e, unstyled: o } = this.props, a = o && o.uDropDownButton;
|
|
222
|
+
return this.buttonsData.length > 0 ? this.buttonsData.map((h, n) => /* @__PURE__ */ p.createElement(
|
|
223
|
+
_,
|
|
224
224
|
{
|
|
225
|
-
className:
|
|
226
|
-
|
|
227
|
-
c:
|
|
225
|
+
className: u(
|
|
226
|
+
c.item({
|
|
227
|
+
c: a
|
|
228
228
|
}),
|
|
229
|
-
|
|
230
|
-
{ "k-first":
|
|
231
|
-
{ "k-last":
|
|
229
|
+
h.className,
|
|
230
|
+
{ "k-first": n === 0 },
|
|
231
|
+
{ "k-last": n === this.buttonsData.length - 1 }
|
|
232
232
|
),
|
|
233
|
-
dataItem:
|
|
233
|
+
dataItem: h,
|
|
234
234
|
textField: e,
|
|
235
|
-
focused: this.state.focusedIndex ===
|
|
235
|
+
focused: this.state.focusedIndex === n,
|
|
236
236
|
onClick: this.onItemClick,
|
|
237
237
|
onDown: this.onItemDown,
|
|
238
238
|
render: t,
|
|
239
239
|
item: i,
|
|
240
|
-
index:
|
|
241
|
-
key:
|
|
242
|
-
id: `${this.guid}-${
|
|
240
|
+
index: n,
|
|
241
|
+
key: n,
|
|
242
|
+
id: `${this.guid}-${n}`
|
|
243
243
|
}
|
|
244
244
|
)) : null;
|
|
245
245
|
}
|
|
@@ -250,7 +250,7 @@ const c = class c extends h.Component {
|
|
|
250
250
|
return this.props.dir !== void 0 ? this.props.dir === "rtl" : !!this.mainButton && getComputedStyle(this.mainButton).direction === "rtl";
|
|
251
251
|
}
|
|
252
252
|
};
|
|
253
|
-
|
|
253
|
+
m.propTypes = {
|
|
254
254
|
accessKey: s.string,
|
|
255
255
|
ariaLabel: s.string,
|
|
256
256
|
title: s.string,
|
|
@@ -264,7 +264,7 @@ c.propTypes = {
|
|
|
264
264
|
tabIndex: s.number,
|
|
265
265
|
disabled: s.bool,
|
|
266
266
|
icon: s.string,
|
|
267
|
-
svgIcon:
|
|
267
|
+
svgIcon: A,
|
|
268
268
|
iconClass: s.string,
|
|
269
269
|
imageUrl: s.string,
|
|
270
270
|
popupSettings: s.object,
|
|
@@ -273,14 +273,22 @@ c.propTypes = {
|
|
|
273
273
|
className: s.string,
|
|
274
274
|
buttonClass: s.string,
|
|
275
275
|
dir: s.string
|
|
276
|
-
},
|
|
276
|
+
}, m.defaultProps = {
|
|
277
277
|
size: "medium",
|
|
278
278
|
rounded: "medium",
|
|
279
279
|
fillMode: "solid",
|
|
280
280
|
themeColor: "base"
|
|
281
281
|
};
|
|
282
|
-
let
|
|
283
|
-
|
|
282
|
+
let g = m;
|
|
283
|
+
const Q = T(), V = L(
|
|
284
|
+
z(
|
|
285
|
+
Q,
|
|
286
|
+
U(Z(g))
|
|
287
|
+
)
|
|
288
|
+
);
|
|
289
|
+
V.displayName = "KendoReactDropDownButton";
|
|
284
290
|
export {
|
|
285
|
-
|
|
291
|
+
V as DropDownButton,
|
|
292
|
+
Q as DropDownButtonPropsContext,
|
|
293
|
+
g as DropDownButtonWithoutContext
|
|
286
294
|
};
|
|
@@ -12,4 +12,4 @@
|
|
|
12
12
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
13
13
|
*-------------------------------------------------------------------------------------------
|
|
14
14
|
*/
|
|
15
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("react"),require("prop-types"),require("@progress/kendo-react-common"),require("@progress/kendo-react-popup"),require("@progress/kendo-svg-icons"),require("@progress/kendo-react-intl")):"function"==typeof define&&define.amd?define(["exports","react","prop-types","@progress/kendo-react-common","@progress/kendo-react-popup","@progress/kendo-svg-icons","@progress/kendo-react-intl"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).KendoReactButtons={},e.React,e.PropTypes,e.KendoReactCommon,e.KendoReactPopup,e.KendoSvgIcons,e.KendoReactIntl)}(this,(function(e,t,s,n,o,r,a){"use strict";function i(e){var t=Object.create(null);return e&&Object.keys(e).forEach((function(s){if("default"!==s){var n=Object.getOwnPropertyDescriptor(e,s);Object.defineProperty(t,s,n.get?n:{enumerable:!0,get:function(){return e[s]}})}})),t.default=e,Object.freeze(t)}var l=i(t);const c=l.forwardRef(((e,t)=>{const{children:s,togglable:o,dir:r,disabled:a,selected:i,icon:c,iconClass:u,svgIcon:p,imageUrl:m,imageAlt:h,className:f,startIcon:v,endIcon:b,onClick:g,size:y=d.size,rounded:k=d.rounded,fillMode:C=d.fillMode,themeColor:I=d.themeColor,...x}=e,E=l.useRef(),D=l.useRef(null),[w,N]=l.useState(!0===o&&!0===i),B=void 0!==p||void 0!==c||void 0!==u||void 0!==m,S=void 0!==s,K=n.useUnstyled(),R=e.unstyled||K,O=R&&R.uButton;l.useImperativeHandle(t,(()=>({element:D.current,selected:void 0!==E.current?E.current:w}))),l.useMemo((()=>{o&&void 0!==i&&i!==w&&N(i)}),[o,i]),l.useEffect((()=>{E.current=void 0}),[w]);const M=function({imageUrl:e,name:t,iconClass:s,svgIcon:o,imageAlt:r,buttonClasses:a}){return e?l.createElement("img",{role:"presentation",className:n.classNames(n.uButton.icon({c:a})),alt:r,src:e}):t||o?l.createElement(n.IconWrap,{className:n.classNames(n.uButton.icon({c:a})),name:t,icon:o}):s?l.createElement("span",{role:"presentation",className:n.classNames(n.uButton.icon({c:a}),s)}):null}({name:c,svgIcon:p,iconClass:u,imageUrl:m,imageAlt:h,buttonClasses:O}),z=e=>l.cloneElement(e,{className:n.classNames(n.uButton.icon({c:O}))});return l.createElement("button",{ref:D,"aria-pressed":o?w:void 0,...x,dir:r,disabled:a,onClick:e=>{o&&void 0===i&&(E.current=!w,N(!w)),g&&g.call(void 0,e)},className:n.classNames(n.uButton.wrapper({c:O,isRtl:"rtl"===r,selected:w,disabled:a,size:y,fillMode:C,rounded:k,themeColor:I,iconButton:!S&&B}),f)},v&&z(v),M,s&&l.createElement("span",{className:n.classNames(n.uButton.text({c:O}))},s),b&&z(b))})),d={togglable:!1,size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};c.displayName="KendoReactButton",c.propTypes={children:s.node,selected:s.bool,togglable:s.bool,icon:s.string,svgIcon:n.svgIconPropType,iconClass:s.string,imageUrl:s.string,imageAlt:s.string,size:s.oneOf([null,"small","medium","large"]),rounded:s.oneOf([null,"small","medium","large","full"]),fillMode:s.oneOf([null,"flat","link","outline","solid","clear"]),themeColor:s.oneOf([null,"base","primary","secondary","tertiary","info","success","warning","error","dark","light","inverse"])};const u=e=>{const{children:t,className:s,dir:o,disabled:r,width:a}=e,i=n.useUnstyled(),c=e.unstyled||i,d=c&&c.uButtonGroup,u=(e,t)=>{const s={...a?{width:a}:{},...e.props.style||{}},n=r||e.props.disabled,o={...e.props,...t?{className:t}:{},...Object.keys(s).length?{style:s}:{},...void 0!==n?{disabled:n}:{}};return l.Children.count(e.props.children)>0?l.cloneElement(e,o,e.props.children):l.cloneElement(e,o)},p=l.useRef(null),m=(e=>{const t=l.Children.count(e),s=void 0!==o?"rtl"===o:p.current&&"rtl"===getComputedStyle(p.current).direction||!1;return l.Children.map(e,((e,o)=>{if(l.isValidElement(e)){const r=o===t-1,a=s,i=n.classNames(e.props.className,n.uButtonGroup.position({c:d,start:a?r:0===o,end:a?0===o:r}));return u(e,i)}return e}))})(t),h=n.classNames(n.uButtonGroup.wrapper({c:d,stretched:!!a,disabled:r}),s),f={className:h,style:{width:`${a}`},dir:o,role:"group","aria-disabled":r};return l.createElement("div",{ref:p,...f,className:h},m)};u.propTypes={children:s.oneOfType([s.arrayOf(s.element),s.element]),className:s.string,disabled:s.bool,width:s.string,dir:s.string};const p=e=>{const t=n.useUnstyled(),s=e.unstyled||t,o=s&&s.uDropDownButton,r=l.useCallback((t=>{e.onClick(t,e.index)}),[e]),a=e.dataItem.render||e.item||(void 0===e.item?e.render:null),i=void 0!==e.dataItem.text?e.dataItem.text:e.textField?e.dataItem[e.textField]:e.dataItem,c=l.createElement("li",{id:e.id,className:n.classNames(n.uDropDownButton.li({c:o,focused:e.focused}),e.className),tabIndex:-1,onClick:r,onMouseDown:e.onDown,onPointerDown:e.onDown,role:"menuitem","aria-disabled":e.dataItem.disabled||void 0},l.createElement("span",{tabIndex:-1,className:n.classNames(n.uDropDownButton.link({c:o,selected:e.dataItem.selected,disabled:e.dataItem.disabled})),key:"icon"},a?l.createElement(a,{item:e.dataItem,itemIndex:e.index}):l.createElement(l.Fragment,null,(e.dataItem.icon||e.dataItem.iconClass||e.dataItem.svgIcon)&&l.createElement(n.IconWrap,{className:e.dataItem.iconClass,name:e.dataItem.icon,icon:e.dataItem.svgIcon}),e.dataItem.imageUrl&&l.createElement("img",{role:"presentation",alt:"",src:e.dataItem.imageUrl,className:"k-icon"}),i&&l.createElement("span",{className:"k-menu-link-text"},i))));return void 0!==e.item&&void 0!==e.render?e.render.call(void 0,c,e):c};p.displayName="KendoReactButtonItem";const m=class extends l.Component{render(){return null}};m.propTypes={text:s.string,icon:s.string,iconClass:s.string,imageUrl:s.string,disabled:s.bool,render:s.any};let h=m;const f=(e,t,s,o)=>{if(s)return e;const r=Math.min(o-1,Math.max(0,e));switch(t){case n.Keys.enter:case n.Keys.space:case n.Keys.esc:return-1;case n.Keys.up:case n.Keys.left:return r-1<0?o-1:r-1;case n.Keys.down:case n.Keys.right:return r+1>=o?0:r+1;case n.Keys.home:return 0;case n.Keys.end:return o-1;default:return e}};function v(e){const t={horizontal:"left",vertical:"bottom"};return e&&(t.horizontal="right"),t}function b(e){const t={horizontal:"left",vertical:"top"};return e&&(t.horizontal="right"),t}const g={name:"@progress/kendo-react-buttons",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate:0,version:"$VERSION",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"},y=class extends l.Component{constructor(e){super(e),this.state={focused:!1,focusedIndex:-1,opened:!1},this.wrapper=null,this.mainButton=null,this.list=null,this.skipFocus=!1,this.buttonsData=[],this.showLicenseWatermark=!1,this.onKeyDown=e=>{const{focusedIndex:t}=this.state;if(e.altKey)return void(this.opened||e.keyCode!==n.Keys.down?this.opened&&e.keyCode===n.Keys.up&&(e.preventDefault(),this.setState({focusedIndex:-1}),this.setOpen(!1,e)):(e.preventDefault(),this.setState({focusedIndex:0}),this.setOpen(!0,e)));let s;if(e.keyCode===n.Keys.enter||e.keyCode===n.Keys.space){if(e.preventDefault(),this.dispatchClickEvent(e,t),t>=0){s={focusedIndex:this.opened?-1:0};const t=!this.opened;this.setOpen(t,e)}}else if(this.opened&&e.keyCode===n.Keys.esc)return this.setState({focusedIndex:-1}),void this.setOpen(!1,e);if(this.opened){const o=f(t,e.keyCode,e.altKey,this.buttonsData.length);o!==t&&(s=s||{},s.focusedIndex=o);const r=e.keyCode===n.Keys.up||e.keyCode===n.Keys.down||e.keyCode===n.Keys.left||e.keyCode===n.Keys.right;!e.altKey&&(r||e.keyCode===n.Keys.home||e.keyCode===n.Keys.end)&&e.preventDefault()}s&&this.setState(s)},this.switchFocus=e=>{this.skipFocus=!0,e(),window.setTimeout((()=>this.skipFocus=!1),0)},this.onFocus=e=>{this.skipFocus||(n.dispatchEvent(this.props.onFocus,e,this,void 0),this.setState({focused:!0}))},this.setOpen=(e,t)=>{this.opened!==e&&(this.openedDuringOnChange=e,this.setState({opened:e}),t?this.dispatchPopupEvent(t,e):this.openedDuringOnChange=void 0)},this.onItemClick=(e,t)=>{this.opened&&this.setState({focusedIndex:0}),this.dispatchClickEvent(e,t),this.setOpen(!1,e)},this.onBlur=e=>{this.skipFocus||(this.setState({focused:!1,focusedIndex:-1}),n.dispatchEvent(this.props.onBlur,e,this,void 0),setTimeout((()=>{this.setOpen(!1,e)}),0))},this.onPopupClose=e=>{var t;const s=n.getActiveElement(document);this.element&&this.element.removeAttribute("tabindex"),(s===this.list||null!=(t=this.list)&&t.contains(s))&&this.switchFocus((()=>{this.element&&this.element.focus({preventScroll:!0})})),this.props.popupSettings&&this.props.popupSettings.onClose&&this.props.popupSettings.onClose.call(void 0,e)},this.listRef=e=>{this.list=e,e&&this.state.focused&&this.switchFocus((()=>{e.focus({preventScroll:!0}),this.element&&(this.element.tabIndex=-1)}))},this.onSplitPartClick=e=>{if(this.buttonsData.length){const t=!this.opened;this.setState({focusedIndex:t?0:-1,focused:!0}),this.setOpen(t,e)}},this.onDownSplitPart=e=>{e.preventDefault();const t=n.getActiveElement(document);this.element&&t!==this.element&&t!==this.list&&this.element.focus()},this.onItemDown=e=>{n.getActiveElement(document)===this.list&&e.preventDefault()},this.dispatchPopupEvent=(e,t)=>{n.dispatchEvent(t?this.props.onOpen:this.props.onClose,e,this,void 0),this.openedDuringOnChange=void 0},this.showLicenseWatermark=!n.validatePackage(g,{component:"SplitButton"})}get guid(){return this.props.id?this.props.id+"-accessibility-id":this.props.id}get opened(){return void 0!==this.openedDuringOnChange?this.openedDuringOnChange:void 0===this.props.opened?this.state.opened:this.props.opened}render(){this.buttonsData=this.props.items||l.Children.toArray(this.props.children).filter((e=>e&&e.type===h)).map((e=>e.props));const e=this.isRtl(),t=e?"rtl":void 0,{id:s,style:o,tabIndex:a,disabled:i}=this.props;return l.createElement(l.Fragment,null,l.createElement("div",{id:s,style:o,className:n.classNames("k-split-button","k-button-group",{"k-focus":this.state.focused},`k-rounded-${n.kendoThemeMaps.roundedMap[this.props.rounded||"medium"]}`,this.props.className),onKeyDown:this.onKeyDown,onFocus:this.onFocus,onBlur:this.onBlur,dir:t,ref:e=>this.wrapper=e},l.createElement(c,{ref:e=>this.mainButton=e&&e.element,type:"button",size:this.props.size,rounded:this.props.rounded,fillMode:this.props.fillMode,themeColor:this.props.themeColor,onClick:e=>this.onItemClick(e,-1),disabled:i||void 0,tabIndex:a,accessKey:this.props.accessKey,className:this.props.buttonClass,icon:this.props.icon,svgIcon:this.props.svgIcon,iconClass:this.props.iconClass,startIcon:this.props.startIcon,endIcon:this.props.endIcon,imageUrl:this.props.imageUrl,dir:t,"aria-disabled":i,"aria-haspopup":!0,"aria-expanded":this.opened||void 0,"aria-label":this.props.ariaLabel,"aria-controls":this.opened?this.guid:void 0,id:"button-"+this.guid,title:this.props.title},this.props.text),l.createElement(c,{type:"button",size:this.props.size,rounded:this.props.rounded,fillMode:this.props.fillMode,themeColor:this.props.themeColor,icon:"caret-alt-down",svgIcon:r.caretAltDownIcon,className:"k-split-button-arrow",disabled:i||void 0,tabIndex:-1,onClick:this.onSplitPartClick,onMouseDown:this.onDownSplitPart,onPointerDown:this.onDownSplitPart,dir:t,"aria-label":"menu toggling button"}),this.renderPopup(e)),this.showLicenseWatermark&&l.createElement(n.WatermarkOverlay,null))}componentDidMount(){(void 0===this.props.dir&&this.isRtl()||this.opened)&&this.forceUpdate()}get element(){return this.mainButton}dispatchClickEvent(e,t){this.isItemDisabled(t)||(-1===t?n.dispatchEvent(this.props.onButtonClick,e,this,void 0):n.dispatchEvent(this.props.onItemClick,e,this,{item:this.buttonsData[t],itemIndex:t}))}renderPopup(e){const{popupSettings:t={}}=this.props,{focusedIndex:s}=this.state;return l.createElement(o.Popup,{anchor:this.wrapper,show:this.opened,animate:t.animate,popupClass:n.classNames("k-menu-popup",t.popupClass),anchorAlign:t.anchorAlign||v(e),popupAlign:t.popupAlign||b(e),style:e?{direction:"rtl"}:void 0,onClose:this.onPopupClose},l.createElement("ul",{role:"menu",id:this.guid,"aria-labelledby":"button-"+this.guid,tabIndex:-1,ref:this.listRef,"aria-activedescendant":s>=0?`${this.guid}-${s}`:void 0,className:n.classNames("k-menu-group",{[`k-menu-group-${n.kendoThemeMaps.sizeMap[this.props.size]||this.props.size}`]:this.props.size})},this.renderChildItems()))}renderChildItems(){const{item:e,itemRender:t,textField:s}=this.props;return this.buttonsData.length>0?this.buttonsData.map(((o,r)=>l.createElement(p,{className:n.classNames("k-menu-item",{"k-first":0===r},{"k-last":r===this.buttonsData.length-1}),dataItem:o,textField:s,focused:this.state.focusedIndex===r,onClick:this.onItemClick,onDown:this.onItemDown,render:t,item:e,key:r,index:r,id:`${this.guid}-${r}`}))):null}isItemDisabled(e){return this.buttonsData[e]?this.buttonsData[e].disabled:this.props.disabled}isRtl(){return void 0!==this.props.dir?"rtl"===this.props.dir:!!this.wrapper&&"rtl"===getComputedStyle(this.wrapper).direction}};y.propTypes={accessKey:s.string,ariaLabel:s.string,title:s.string,onButtonClick:s.func,onFocus:s.func,onBlur:s.func,onItemClick:s.func,onOpen:s.func,onClose:s.func,text:s.string,items:s.arrayOf(s.any),textField:s.string,tabIndex:s.number,disabled:s.bool,icon:s.string,svgIcon:n.svgIconPropType,iconClass:s.string,imageUrl:s.string,popupSettings:s.object,itemRender:s.any,item:s.func,className:s.string,buttonClass:s.string,dir:s.string},y.defaultProps={size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let k=y;const C=class extends l.Component{render(){return null}};C.propTypes={text:s.string,icon:s.string,iconClass:s.string,imageUrl:s.string,selected:s.bool,disabled:s.bool,render:s.any};let I=C;const x=class extends l.Component{constructor(e){super(e),this.state={opened:!1,focused:!1,focusedIndex:-1},this.mainButton=null,this.list=null,this.skipFocus=!1,this.showLicenseWatermark=!1,this.buttonsData=[],this.onKeyDown=e=>{const{focusedIndex:t}=this.state;if(e.altKey)return void(this.opened||e.keyCode!==n.Keys.down?this.opened&&e.keyCode===n.Keys.up&&(e.preventDefault(),this.setState({focusedIndex:-1}),this.setOpen(!1,e)):(e.preventDefault(),this.setOpen(!0,e),this.setState({focusedIndex:0})));const s={...this.state};if(e.keyCode===n.Keys.enter||e.keyCode===n.Keys.space){e.preventDefault(),t>=0&&this.dispatchClickEvent(e,t);const s=!this.opened;return this.setState({focused:!0,focusedIndex:s?0:-1}),void this.setOpen(s,e)}if(this.opened&&e.keyCode===n.Keys.esc)return this.setState({focusedIndex:-1}),void this.setOpen(!1,e);if(this.opened){const o=f(t,e.keyCode,e.altKey,this.buttonsData.length);s.focusedIndex=o;const r=e.keyCode===n.Keys.up||e.keyCode===n.Keys.down||e.keyCode===n.Keys.left||e.keyCode===n.Keys.right;!e.altKey&&(r||e.keyCode===n.Keys.home||e.keyCode===n.Keys.end)&&e.preventDefault()}this.setState(s)},this.switchFocus=e=>{this.skipFocus=!0,e(),window.setTimeout((()=>this.skipFocus=!1),0)},this.handleFocus=e=>{this.skipFocus||(this.setState({focused:!0,focusedIndex:this.opened?0:-1}),n.dispatchEvent(this.props.onFocus,e,this,void 0))},this.handleButtonBlur=e=>{this.opened||(this.setState({focused:!1}),n.dispatchEvent(this.props.onBlur,e,this,void 0))},this.handleMenuBlur=e=>{this.skipFocus||(this.setState({focused:!1,focusedIndex:-1}),n.dispatchEvent(this.props.onBlur,e,this,void 0),setTimeout((()=>{this.setOpen(!1,e)}),0))},this.setOpen=(e,t)=>{this.opened!==e&&(this.openedDuringOnChange=e,this.setState({opened:e}),t?this.dispatchPopupEvent(t,e):this.openedDuringOnChange=void 0)},this.onItemClick=(e,t)=>{this.setState({focusedIndex:-1}),this.dispatchClickEvent(e,t),this.setOpen(!1,e)},this.onItemDown=e=>{n.getActiveElement(document)===this.list&&e.preventDefault()},this.mouseDown=e=>{e.preventDefault();const t=n.getActiveElement(document);this.element&&t!==this.element&&t!==this.list&&this.element.focus()},this.onPopupClose=e=>{var t;const s=n.getActiveElement(document);this.element&&this.element.removeAttribute("tabindex"),(s===this.list||null!=(t=this.list)&&t.contains(s))&&this.switchFocus((()=>{this.element&&this.element.focus({preventScroll:!0})})),this.props.popupSettings&&this.props.popupSettings.onClose&&this.props.popupSettings.onClose.call(void 0,e)},this.listRef=e=>{this.list=e,e&&this.state.focused&&this.switchFocus((()=>{e.focus({preventScroll:!0}),this.element&&(this.element.tabIndex=-1)}))},this.onClickMainButton=e=>{if(!this.buttonsData.length)return;const t=!this.opened;this.setState({focused:!0,focusedIndex:t?0:-1}),this.setOpen(t,e)},this.dispatchPopupEvent=(e,t)=>{n.dispatchEvent(t?this.props.onOpen:this.props.onClose,e,this,void 0),this.openedDuringOnChange=void 0},this.showLicenseWatermark=!n.validatePackage(g,{component:"DropDownButton"})}get guid(){return this.props.id+"-accessibility-id"}get opened(){return void 0!==this.openedDuringOnChange?this.openedDuringOnChange:void 0===this.props.opened?this.state.opened:this.props.opened}render(){const e=this.isRtl(),t=this.context&&this.context.uDropDownButton,s=e?"rtl":void 0,{id:o,style:r,tabIndex:a,disabled:i,size:d,rounded:u,fillMode:p,themeColor:m,ariaLabel:h,title:f,accessKey:v,icon:b,svgIcon:g,iconClass:y,buttonClass:k,className:C,imageUrl:x,startIcon:E,endIcon:D}=this.props;return this.buttonsData=this.props.items||l.Children.toArray(this.props.children).filter((e=>e&&e.type===I)).map((e=>e.props)),l.createElement(l.Fragment,null,l.createElement(c,{id:o,size:d,style:r,rounded:u,fillMode:p,themeColor:m,onClick:this.onClickMainButton,onMouseDown:this.mouseDown,onKeyDown:this.onKeyDown,onFocus:this.handleFocus,onBlur:this.handleButtonBlur,"aria-disabled":i?"true":void 0,tabIndex:a,accessKey:v,icon:b,svgIcon:g,iconClass:y,className:n.classNames(k,C,n.uDropDownButton.wrapper({c:t,focused:this.state.focused,disabled:i})),imageUrl:x,dir:s,ref:e=>this.mainButton=e&&e.element,type:"button","aria-expanded":this.opened?"true":"false","aria-label":h,"aria-controls":this.opened?this.guid:void 0,title:f,startIcon:E,endIcon:D},this.props.text),this.showLicenseWatermark&&l.createElement(n.WatermarkOverlay,null),this.renderPopup(e))}componentDidMount(){(void 0===this.props.dir&&this.isRtl()||this.opened)&&this.forceUpdate()}get element(){return this.mainButton}dispatchClickEvent(e,t){this.isItemDisabled(t)||n.dispatchEvent(this.props.onItemClick,e,this,{item:this.buttonsData[t],itemIndex:t})}renderPopup(e){const{popupSettings:t={},id:s}=this.props,r=this.context&&this.context.uDropDownButton,{focusedIndex:a}=this.state;return l.createElement(o.Popup,{anchor:this.mainButton,show:this.opened,animate:t.animate,popupClass:n.classNames(n.uDropDownButton.popup({c:r}),t.popupClass),anchorAlign:t.anchorAlign||v(e),popupAlign:t.popupAlign||b(e),style:e?{direction:"rtl"}:void 0,onClose:this.onPopupClose},l.createElement("ul",{role:"list",id:this.guid,tabIndex:-1,"aria-activedescendant":a>=0?`${this.guid}-${a}`:void 0,ref:this.listRef,onKeyDown:this.onKeyDown,onBlur:this.handleMenuBlur,className:n.classNames(n.uDropDownButton.ul({c:r,size:this.props.size}))},this.renderChildItems()))}renderChildItems(){const{item:e,itemRender:t,textField:s}=this.props,o=this.context&&this.context.uDropDownButton;return this.buttonsData.length>0?this.buttonsData.map(((r,a)=>l.createElement(p,{className:n.classNames(n.uDropDownButton.item({c:o}),r.className,{"k-first":0===a},{"k-last":a===this.buttonsData.length-1}),dataItem:r,textField:s,focused:this.state.focusedIndex===a,onClick:this.onItemClick,onDown:this.onItemDown,render:t,item:e,index:a,key:a,id:`${this.guid}-${a}`}))):null}isItemDisabled(e){return this.buttonsData[e]?this.buttonsData[e].disabled:this.props.disabled}isRtl(){return void 0!==this.props.dir?"rtl"===this.props.dir:!!this.mainButton&&"rtl"===getComputedStyle(this.mainButton).direction}};x.propTypes={accessKey:s.string,ariaLabel:s.string,title:s.string,onFocus:s.func,onBlur:s.func,onItemClick:s.func,onOpen:s.func,onClose:s.func,items:s.arrayOf(s.any),textField:s.string,tabIndex:s.number,disabled:s.bool,icon:s.string,svgIcon:n.svgIconPropType,iconClass:s.string,imageUrl:s.string,popupSettings:s.object,itemRender:s.func,item:s.func,className:s.string,buttonClass:s.string,dir:s.string},x.defaultProps={size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let E=x;E.contextType=n.UnstyledContext;const D=":not(.k-dropdownlist button):not(.k-colorpicker button):not(.k-split-button .k-split-button-arrow)",w=["button"+D,".k-button-group > button"+D,".k-colorpicker",".k-dropdownlist"],N=e=>l.createElement("div",{ref:e._ref,className:n.classNames("k-toolbar-separator k-separator",e.className)}),B="prevArrow.title",S="nextArrow.title",K="moreButtonTitle.title",R={[B]:"Previous scroll button",[S]:"Next scroll button",[K]:"More button"},O=e=>{const t=a.useLocalization(),{disabled:s,type:o,scrollContentRef:i,buttonScrollSpeed:c,prevButton:d,nextButton:u}=e,p="prev"===o?d||"span":u||"span";return l.createElement(p,{className:n.classNames("k-button","k-button-md","k-button-solid","k-button-solid-base","k-rounded-md","k-icon-button",`k-toolbar-${o}`,{"k-disabled":s}),title:`${"prev"===o?t.toLanguageString(B,R[B]):t.toLanguageString(S,R[S])}`,"aria-hidden":!0,tabIndex:s?-1:void 0,onClick:e=>{i&&i.current&&c&&i.current.scrollBy({left:"next"===o?c:-c,behavior:"smooth"})}},l.createElement(n.SvgIcon,{icon:"prev"===o?r.caretAltLeftIcon:r.caretAltRightIcon,className:"k-button-icon"}))},M=e=>{const{scrollButtons:t,scrollButtonsPosition:s,isOverflowing:n,scrollContentRef:o,buttonScrollSpeed:r,dir:a,isScrollStartPosition:i,isScrollEndPosition:c,prevButton:d,nextButton:u,children:p}=e,m=(e,t)=>l.createElement(O,{type:e,disabled:t,scrollContentRef:o,buttonScrollSpeed:r,prevButton:d,nextButton:u}),h="visible"===t||"auto"===t&&n;return l.createElement(l.Fragment,null,h&&"split"===s&&l.createElement(l.Fragment,null,m("rtl"!==a?"prev":"next",i),l.createElement(N,{className:"k-toolbar-button-separator"})),h&&"start"===s&&l.createElement(l.Fragment,null,m("rtl"!==a?"prev":"next",i),m("rtl"!==a?"next":"prev",c),l.createElement(N,{className:"k-toolbar-button-separator"})),l.createElement("span",{className:"k-toolbar-items k-toolbar-items-scroll",ref:o},p),h&&"split"===s&&l.createElement(l.Fragment,null,l.createElement(N,{className:"k-toolbar-button-separator"}),m("rtl"!==a?"next":"prev",c)),h&&"end"===s&&l.createElement(l.Fragment,null,l.createElement(N,{className:"k-toolbar-button-separator"}),m("rtl"!==a?"prev":"next",i),m("rtl"!==a?"next":"prev",c)))},z=e=>{var t;const{toolbarRef:s,children:i,fillMode:d,size:u}=e,[p,m]=l.useState(!1),h=l.useRef(l.Children.toArray(i).filter((e=>l.isValidElement(e))).map(((e,t)=>l.cloneElement(e,{key:e.key||t})))),f=l.useRef([]),v=l.useRef(0),b=l.useRef(null),g=l.useRef(null),y=a.useLocalization(),[k,C]=l.useReducer((e=>e+1),0),I=()=>{if(!s.current)return;let e=0;const t=s.current.clientWidth,n=parseInt(window.getComputedStyle(s.current).gap||"0",10),o=Array.from(s.current.children).reduce(((e,t,s)=>e+=Math.ceil(t.clientWidth)),0),r=Array.from(s.current.children).length;if(e=o+r*n+2*n,e>t){const e=[...h.current],s=e.pop();v.current=t,h.current=e,s&&(f.current=[s,...f.current])}else if(t>v.current+n*r){const e=[...f.current],s=e.shift();f.current=e,s&&(h.current=[...h.current,s]),v.current=t}C()};l.useEffect((()=>{I();const e=new ResizeObserver(I),t=s.current;return t&&e.observe(t),()=>{t&&e.unobserve(t)}}),[]);return l.createElement(l.Fragment,null,h.current.length>0&&h.current,f.current.length>0&&l.createElement(l.Fragment,null,l.createElement(N,{_ref:g,className:"k-toolbar-button-separator"}),l.createElement(c,{ref:b,className:"k-toolbar-overflow-button",fillMode:"flat",svgIcon:r.moreHorizontalIcon,title:y.toLanguageString(K,R[K]),onClick:()=>{m(!p)}}),l.createElement(o.Popup,{anchor:s.current,show:p,popupClass:"k-toolbar-popup",style:{width:null==(t=s.current)?void 0:t.offsetWidth}},l.createElement("span",{className:`k-toolbar-items-list k-toolbar-items-list-${n.kendoThemeMaps.sizeMap[u]} k-toolbar-items-list-${d}`},f.current.length>0&&f.current))))},F=l.forwardRef(((e,t)=>{const{children:s,className:o,id:r,ariaLabel:a,keyboardNavigation:i,role:c,onResize:d,style:u,tabIndex:p=P.tabIndex,size:m=P.size,fillMode:h=P.fillMode,overflow:f,scrollButtons:v=P.scrollButtons,scrollButtonsPosition:b=P.scrollButtonsPosition,buttonScrollSpeed:g=P.buttonScrollSpeed,prevButton:y,nextButton:k}=e,C=l.useRef(!1),I=l.useRef(null),x=l.useRef(null),E=l.useRef(0),D=l.useRef(0),N=l.useRef([]),B=l.useRef({element:null,props:e}),[S,K]=l.useState(!1),[R,O]=l.useState(!0),[F,A]=l.useState(!1),T=n.useDir(I,e.dir),$=l.useMemo((()=>e.buttons||w),[e.buttons]),L=l.useMemo((()=>$.map((e=>e+":focus")).join(",")),[$]),W=()=>{const e=I.current&&I.current.querySelector(L);return Math.max(0,N.current.findIndex((t=>t===e)))};l.useImperativeHandle(B,(()=>({element:I.current,props:e}))),l.useImperativeHandle(t,(()=>B.current)),l.useEffect((()=>(window.addEventListener("resize",j),I.current&&(D.current=I.current.offsetWidth,E.current=I.current.offsetHeight,!1!==i&&(N.current=Array.from(I.current.querySelectorAll($.join(","))),U(0))),()=>{window.removeEventListener("resize",j),N.current.length=0})),[]),l.useEffect((()=>{if(C.current){if(!I.current||!1===i)return;N.current=Array.from(I.current.querySelectorAll($.join(","))),U(W()),q()}else C.current=!0}));const U=e=>{N.current.forEach(((t,s)=>{t.tabIndex=s===e?p:-1}))},H=(e,t)=>{const s=N.current[t];if(s){s.tabIndex=p,s.focus();const t=N.current[e];t&&(t.tabIndex=-1)}},j=e=>{if(!I.current)return;const t=I.current.offsetWidth,s=I.current.offsetHeight;if(D.current!==t||E.current!==s){D.current=t,E.current=s;const n={offsetWidth:D.current,offsetHeight:E.current};d&&d.call(void 0,{target:B.current,...n,nativeEvent:e})}q()},q=l.useCallback((()=>{const e=x.current;e&&K(e.scrollWidth>e.clientWidth||e.scrollHeight>e.clientHeight)}),[]),V=l.useCallback((()=>{const e=x.current;if(e){const t=0===e.scrollLeft,s="rtl"!==T?e.scrollLeft+e.clientWidth===e.scrollWidth:e.clientWidth-e.scrollLeft===e.scrollWidth;t&&O(!0),s&&A(!0),!t&&!s&&(O(!1),A(!1))}}),[T]);return l.useEffect((()=>{const e=x.current;if(e)return e.addEventListener("scroll",V),()=>{e.removeEventListener("scroll",V)}}),[V]),l.createElement("div",{id:r,"aria-label":a,className:n.classNames("k-toolbar",{[`k-toolbar-${n.kendoThemeMaps.sizeMap[m]||m}`]:m,[`k-toolbar-${h}`]:h,"k-toolbar-scrollable":"scroll"===f,"k-toolbar-scrollable-overlay":"scroll"===f&&("hidden"===v||void 0===v),"k-toolbar-scrollable-start":"scroll"===f&&"hidden"===v&&R,"k-toolbar-scrollable-end":"scroll"===f&&"hidden"===v&&F,"k-toolbar-section":e.overflow&&"section"===f},o),style:u,role:void 0!==c?c||void 0:"toolbar",dir:T,ref:I,onKeyDown:!1!==i?e=>{const t=e.keyCode===n.Keys.left||e.keyCode===n.Keys.right||e.keyCode===n.Keys.home||e.keyCode===n.Keys.end,s=W();!t||e.defaultPrevented||-1===N.current.findIndex((t=>t===e.target))||(e.keyCode===n.Keys.left?H(s,0===s?N.current.length-1:s-1):H(s,s===N.current.length-1?0:s+1),e.keyCode===n.Keys.home&&H(s,0),e.keyCode===n.Keys.end&&H(s,N.current.length-1))}:void 0},"scroll"===f&&l.createElement(M,{scrollButtons:v,scrollButtonsPosition:b,prevButton:y,nextButton:k,isOverflowing:S,scrollContentRef:x,buttonScrollSpeed:g,dir:T,isScrollStartPosition:R,isScrollEndPosition:F,children:s}),"section"===f&&l.createElement(z,{toolbarRef:I,fillMode:h,size:m},s),("none"===f||void 0===f)&&s)})),P={tabIndex:0,size:"medium",fillMode:"solid",scrollButtons:"auto",scrollButtonsPosition:"split",buttonScrollSpeed:100};F.displayName="KendoReactToolbar",F.propTypes={tabIndex:s.number,dir:s.string,keyboardNavigation:s.bool,style:s.object,className:s.string,role:s.string,onResize:s.func,buttons:s.arrayOf(s.string.isRequired),size:s.oneOf([null,"small","medium","large"]),fillMode:s.oneOf([null,"solid","flat","outline"]),overflow:s.oneOf(["none","section","scroll"]),scrollButtons:s.oneOf(["hidden","visible","auto"]),scrollButtonsPosition:s.oneOf(["start","end","split"]),buttonScrollSpeed:s.number};const A=l.forwardRef(((e,t)=>{const{id:s,className:o,style:r,children:a}=e,i=l.useRef(null);return l.useImperativeHandle(t,(()=>({element:i.current}))),l.createElement("div",{id:s,className:n.classNames("k-toolbar-item",o),style:r,ref:i},a)}));A.displayName="KendoReactToolbarItem",A.propTypes={className:s.string};const T=l.forwardRef(((e,t)=>{const s=l.useRef(null),o=l.useRef(null);l.useImperativeHandle(o,(()=>({element:s.current}))),l.useImperativeHandle(t,(()=>({element:s.current})));const r=l.useMemo((()=>n.classNames("k-spacer",e.className)),[e.className]);return l.createElement("span",{ref:s,className:r})}));T.displayName="KendoReactToolbarSpacer",T.propTypes={className:s.string};const $=t.createContext([null,e=>{}]),L=t.createContext([null,e=>{}]),W=t.createContext([null,e=>{}]);var U=(e=>(e.next="next",e.prev="prev",e.current="current",e.reset="reset",e))(U||{});var H=(e=>(e.remove="remove",e.add="add",e.reorder="reorder",e))(H||{});var j=(e=>(e.toggle="toggle",e.remove="remove",e))(j||{});const q=l.forwardRef(((e,t)=>{const s=l.useRef(null),o=l.useRef(null),{disabled:a=G.disabled,fillMode:i=G.fillMode,themeColor:c=G.themeColor,size:d=G.size,rounded:u=G.rounded,dir:p=G.dir,removeIcon:m=G.removeIcon,removeSvgIcon:h=G.removeSvgIcon,removable:f=G.removable}=e,v=n.useDir(o,p);l.useImperativeHandle(s,(()=>({element:o.current,props:e}))),l.useImperativeHandle(t,(()=>s.current));const[b,g]=l.useContext($),[y,k]=l.useContext(L),[,C]=l.useContext(W),I=l.useMemo((()=>e.selected||(Array.isArray(b)?b.some((t=>t===e.value)):b===e.value)),[e.selected,e.value,b]),x=l.useMemo((()=>y===e.value),[e.value,y]);l.useEffect((()=>{x&&o.current&&o.current.focus()}),[x]);const E=l.useCallback((t=>{g({type:j.toggle,payload:e.value,event:t})}),[g,e.value]),D=l.useCallback((t=>{f&&(C({type:H.remove,payload:e.value,event:t}),k({type:U.reset,payload:e.value,event:t}),g({type:j.remove,payload:e.value,event:t}),e.onRemove&&e.onRemove.call(void 0,{target:s.current,syntheticEvent:t}))}),[e.onRemove,e.value,f,C,k,g]),w=l.useCallback((t=>{switch(t.keyCode){case n.Keys.left:k({type:U.prev,payload:e.value,event:t});break;case n.Keys.right:k({type:U.next,payload:e.value,event:t});break;case n.Keys.enter:g({type:j.toggle,payload:e.value,event:t});break;case n.Keys.delete:D(t)}e.onKeyDown&&e.onKeyDown.call(void 0,{target:s.current,syntheticEvent:t})}),[e.onKeyDown,e.value,k,g,D]),N=l.useCallback((t=>{k({payload:e.value,type:U.current,event:t}),e.onFocus&&e.onFocus.call(void 0,{target:s.current,syntheticEvent:t})}),[e.onFocus,e.value,k]),B=l.useCallback((t=>{e.onBlur&&e.onBlur.call(void 0,{target:s.current,syntheticEvent:t})}),[e.onBlur]),S=n.useMouse(e,s,{onClick:E});return l.createElement("div",{...S,role:e.role||"button",id:e.value,style:e.style,ref:o,dir:v,tabIndex:n.getTabIndex(e.tabIndex,a,void 0),className:n.classNames("k-chip",{"k-rtl":"rtl"===v,"k-disabled":a,"k-selected":I,"k-focus":x,[`k-chip-${n.kendoThemeMaps.sizeMap[d]||d}`]:d,[`k-rounded-${n.kendoThemeMaps.roundedMap[u]||u}`]:u,[`k-chip-${i}`]:i,[`k-chip-${i}-${c}`]:!(!i||!c)},e.className),"aria-pressed":e.role?void 0:I,"aria-disabled":a,"aria-describedby":e.ariaDescribedBy,"aria-keyshortcuts":f?"Enter Delete":void 0,onFocus:N,onBlur:B,onKeyDown:w},I&&(e.selectedIcon||e.selectedSvgIcon)&&l.createElement(n.IconWrap,{className:"k-chip-icon",name:e.selectedIcon?n.toIconName(e.selectedIcon):void 0,icon:e.selectedSvgIcon,size:"small"}),(e.icon||e.svgIcon)&&l.createElement(n.IconWrap,{className:"k-chip-icon",name:e.icon?n.toIconName(e.icon):void 0,icon:e.svgIcon,size:"small"}),e.avatar&&l.createElement("div",{className:`k-chip-avatar k-avatar k-rounded-${e.avatar.rounded} k-avatar-md k-avatar-solid k-avatar-solid-primary`,style:e.avatar.style},l.createElement("span",{className:"k-avatar-image"},l.createElement("img",{src:e.avatar.image,alt:e.avatar.imageAlt}))),l.createElement("span",{className:"k-chip-content"},void 0!==e.children?e.children:e.text&&l.createElement("span",{"aria-label":e.ariaLabel||e.text,className:"k-chip-label"},e.text)),f&&l.createElement("span",{className:"k-chip-actions"},l.createElement("span",{className:n.classNames("k-chip-action","k-chip-remove-action"),onClick:D},l.createElement(n.IconWrap,{name:m?n.toIconName(m):void 0,icon:h||r.xCircleIcon,size:"small"}))))})),V={id:s.string,text:s.string,value:s.any,dir:s.oneOf(["ltr","rtl"]),removable:s.bool,removeIcon:s.string,removeIconSvg:n.svgIconPropType,disabled:s.bool,icon:s.string,svgIcon:n.svgIconPropType,selectedIcon:s.string,selectedIconSvg:n.svgIconPropType,onRemove:s.func,dataItem:s.any,selected:s.bool,ariaDescribedBy:s.string,size:s.oneOf([null,"small","medium","large"]),rounded:s.oneOf([null,"small","medium","large","full"]),fillMode:s.oneOf([null,"outline","solid"]),themeColor:s.oneOf([null,"base","info","success","warning","error"])},G={disabled:!1,removable:!1,removeIcon:"k-i-x-circle",removeSvgIcon:r.xCircleIcon,dir:"ltr",size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};q.displayName="KendoReactChip",q.propTypes=V;const Z=(e,t,s)=>{"multiple"===t.selection?Array.isArray(e)||(e=e?[e]:null):"single"===t.selection&&Array.isArray(e)&&(e=e?e.join(""):null);const[n,o]=l.useState(e);return[n,e=>{const r=((e,t)=>{switch(t.selection){case"single":switch(t.type){case"toggle":if(!Array.isArray(e)||null===e)return t.payload===e?null:t.payload;throw new Error("State cannot be an array in single selection");case"remove":return t.payload===e?null:e;default:return e}case"multiple":switch(t.type){case"toggle":if(Array.isArray(e))return e.some((e=>e===t.payload))?e.filter((e=>e!==t.payload)):[...e,t.payload];if(null===e)return[t.payload];throw new Error("State cannot be non-array in multiple selection");case"remove":return Array.isArray(e)?e.some((e=>e===t.payload))?e.filter((e=>e!==t.payload)):[...e,t.payload]:e;default:return e}case"none":return null;default:return e}})(t.state||n,{...e,...t});s&&s(r,e.event),"none"!==t.selection&&o(r)}]},_=l.forwardRef(((e,t)=>{const s=l.useRef(null),o=l.useRef(null),{id:r,style:a,tabIndex:i,className:c,ariaDescribedBy:d,ariaLabelledBy:u,ariaLabel:p,value:m,defaultData:h=Q.defaultData,chip:f=Q.chip,disabled:v=Q.disabled,size:b=Q.size,defaultValue:g=Q.defaultValue,selection:y=Q.selection,valueField:k=Q.valueField,textField:C=Q.textField,dir:I=Q.dir,onChange:x,onDataChange:E}=e,D=n.useDir(o,I),w=l.useMemo((()=>f||q),[f,q]);l.useImperativeHandle(s,(()=>({element:o.current,props:e}))),l.useImperativeHandle(t,(()=>s.current));const N=l.useCallback(((e,t)=>{x&&s.current&&x.call(void 0,{value:e,target:s.current,syntheticEvent:t})}),[x]),[B,S]=Z(m||g,{selection:y,state:m},N),K=l.useCallback(((e,t)=>{E&&s.current&&E.call(void 0,{value:e,target:s.current,syntheticEvent:t})}),[E]),[R,O]=((e,t,s)=>{const[n,o]=l.useState(e);return[n,e=>{const r=((e,t)=>{switch(t.type){case"add":case"reorder":break;case"remove":return e.filter((e=>e[t.valueField]!==t.payload));default:return e}})(t.state||n,{...e,...t});s&&s(r,e.event),o(r)}]})(e.data||h,{state:e.data,valueField:k},K),M=l.useCallback(((e,t)=>(e.push(t[k]),e)),[k]),z=l.useMemo((()=>e.data||R),[e.data,R]),F=l.useMemo((()=>m||B),[m,B]),P=l.useMemo((()=>z.reduce(M,[])),[z,M]),A=l.useCallback((e=>n.getter(k)(e)),[k]),T=l.useCallback((e=>n.getter(C)(e)),[C]),[U,H]=(e=>{const[t,s]=l.useState(null);return[t,t=>{const n=((e,t)=>{const s=t.items.findIndex((t=>t===e));switch(t.type){case"next":return s===t.items.length-1?e:t.items[s+1];case"prev":return 0===s?e:t.items[s-1];case"current":return t.payload;case"reset":return null;default:return e}})(t.payload,{...t,...e});s(n)}]})({items:P}),j=n.useMouse(e,s);return l.createElement($.Provider,{value:[F,S]},l.createElement(L.Provider,{value:[U,H]},l.createElement(W.Provider,{value:[z,O]},l.createElement("div",{ref:o,...j,role:v?void 0:"listbox",id:r,dir:D,style:a,tabIndex:n.getTabIndex(i,v,void 0),className:n.classNames("k-chip-list",{"k-rtl":"rtl"===D,"k-disabled":v,[`k-chip-list-${n.kendoThemeMaps.sizeMap[b]||b}`]:b},c),"aria-label":p,"aria-labelledby":u,"aria-describedby":d,"aria-orientation":"horizontal","aria-multiselectable":"multiple"===y},z.map(((e,t)=>l.createElement(w,{role:"option",dataItem:e,size:b,key:[A(e),t].join("-"),text:T(e),value:A(e),ariaLabel:e.ariaLabel,svgIcon:e.svgIcon||void 0})))))))})),J={id:s.string,className:s.string,tabIndex:s.number,data:s.any,defaultData:s.arrayOf(s.any),onDataChange:s.func,value:s.oneOfType([s.any,s.arrayOf(s.any)]),defaultValue:s.oneOfType([s.any,s.arrayOf(s.any)]),onChange:s.func,selection:s.oneOf(["single","none","multiple"]),textField:s.string,valueField:s.string,disabled:s.bool,dir:s.oneOf(["ltr","rtl"]),ariaLabelledBy:s.string,ariaDescribedBy:s.string,size:s.oneOf([null,"small","medium","large"])},Q={chip:q,size:"medium",disabled:!1,defaultValue:null,defaultData:[],dir:"ltr",selection:"none",textField:"text",valueField:"value",removable:"removable"};_.displayName="KendoReactChipList",_.propTypes=J;const X=l.forwardRef(((e,t)=>{const{className:s,disabled:o,text:r,icon:a,style:i,id:c,focused:d,tabIndex:u,index:p,dataItem:m,item:h,svgIcon:f,onDown:v,onClick:b,...g}=e,y=l.useRef(null),k=l.useCallback((()=>{y.current&&y.current.focus()}),[]),C=l.useCallback((()=>({element:y.current,focus:k})),[k]);l.useImperativeHandle(t,C);const I=l.useCallback((e=>{b&&void 0!==p&&!o&&b(e,p)}),[b,p]),x=l.useMemo((()=>n.classNames("k-fab-item",{"k-focus":d,"k-disabled":o},s)),[s,o,d]),E=h;return l.createElement("li",{ref:y,id:c,className:x,style:i,role:"menuitem",tabIndex:n.getTabIndex(u,o),"aria-disabled":o,"aria-label":`${r||""} floatingactionbutton item`,onClick:I,onMouseDown:v,onPointerDown:v,...g},E?l.createElement(E,{itemIndex:p,item:m}):l.createElement(l.Fragment,null,r&&l.createElement("span",{className:"k-fab-item-text"},r),a||f?l.createElement(n.IconWrap,{className:"k-fab-item-icon",name:a,icon:f}):null))}));X.propTypes={className:s.string,style:s.object,children:s.any,disabled:s.bool,focused:s.bool,index:s.number,icon:s.string,svgIcon:n.svgIconPropType,text:s.string,tabIndex:s.number,customProp:s.any},X.displayName="KendoFloatingActionButtonItem";const Y="16px",ee=e=>"number"==typeof e?e+"px":e,te=(e,t)=>{const s={horizontal:t?"right":"left",vertical:"bottom"};return"end"===e.horizontal&&(s.horizontal=t?"left":"right"),s},se=(e,t)=>{const s={horizontal:t?"right":"left",vertical:"top"};return"end"===e.horizontal&&(s.horizontal=t?"left":"right"),s},ne=(e,t)=>({rtl:{end:"k-text-left",start:"k-text-right"},ltr:{start:"k-text-left",end:"k-text-right"}}[e]["end"===t?"end":"start"]),oe=(e,t,s,n)=>{const o=t.horizontal,r=t.vertical;if(e.current){const a=s&&void 0!==s.x?ee(s.x):Y,i=s&&void 0!==s.x?`calc(50% + ${ee(s.x)})`:"50%",l=s&&void 0!==s.y?ee(s.y):Y,c=s&&void 0!==s.y?`calc(50% + ${ee(s.y)})`:"50%";e.current.style.setProperty(re(t,n),"center"===o?i:a),e.current.style.setProperty(ae(t),"middle"===r?c:l),n&&(("top"===r||"bottom"===r)&&"start"===o&&e.current.style.setProperty("left","unset"),"middle"===r&&"end"===o&&e.current.style.setProperty("right","unset"),"middle"===r&&"start"===o&&e.current.style.setProperty("left","unset"))}},re=(e,t)=>{const{horizontal:s}=e;return{end:t?"left":"right",center:"left",start:t?"right":"left"}[s||"end"]},ae=e=>({top:"top",middle:"top",bottom:"bottom"}[e.vertical||"bottom"]),ie=l.forwardRef(((e,t)=>{const{align:s=le.align,alignOffset:r,className:a,disabled:i,icon:c,svgIcon:d,iconClass:u,id:p,items:m,item:h,text:f,positionMode:v=le.positionMode,size:b=le.size,style:g,rounded:y=le.rounded,themeColor:k=le.themeColor,overlayStyle:C,tabIndex:I,accessKey:x,popupSettings:E={},modal:D,onClick:w,onItemClick:N,onFocus:B,onBlur:S,onKeyDown:K,onOpen:R,onClose:O,...M}=e,z=n.useZIndexContext(),F=z?z+2:100,P=l.useRef(null),A=l.useRef(null),T=l.useRef(null),$=l.useRef(null),L=l.useCallback((()=>{A.current&&A.current.focus()}),[]),W=l.useCallback((()=>({element:A.current,focus:L})),[L]);l.useImperativeHandle(P,W),l.useImperativeHandle(t,(()=>P.current));const[U,H]=l.useState(!1),[j,q]=l.useState(!1),[V,G]=l.useState(-1),Z=n.useId()+"-button-id",_=n.useDir(A,e.dir),J="rtl"===_,Q=n.useId()+"-list-id";l.useEffect((()=>{oe(A,s,r,J)}),[A,s,r,J]),l.useEffect((()=>{j&&A&&A.current&&A.current.focus()}),[j,A]);const Y=l.useCallback(((e,t)=>{m&&n.dispatchEvent(t?R:O,e,W(),void 0)}),[R,O,m]),ee=l.useCallback((e=>{!e.target||i||(!m&&w?n.dispatchEvent(w,e,W(),void 0):(H(!U),q(!0),G(U?-1:0),Y(e,!U)))}),[H,q,G,w,Y,U,m,i]),re=l.useCallback((e=>{q(!0),G(U?0:-1),B&&n.dispatchEvent(B,e,W(),void 0)}),[B,q,G]),ae=l.useCallback((e=>{q(!1),H(!1),G(-1),n.dispatchEvent(S,e,W(),void 0),U&&Y(e,!1)}),[S,q,H,G,Y]),ie=l.useCallback((e=>{e.preventDefault()}),[]),ce=l.useCallback(((e,t)=>{m&&(m[t].disabled||n.dispatchEvent(N,e,W(),{itemProps:m[t],itemIndex:t}))}),[N]),de=l.useCallback(((e,t)=>{!e.target||!m||(G(t),H(!1),ce(e,t),Y(e,!1))}),[G,H,ce,Y]),ue=l.useCallback((e=>{n.getActiveElement(document)===A.current&&e.preventDefault()}),[A]),pe=l.useCallback((e=>{const t=V,s=m?m.length:-1;if(e.altKey)return!U&&e.keyCode===n.Keys.down&&(e.preventDefault(),H(!0),G(0)),void(U&&e.keyCode===n.Keys.up&&(e.preventDefault(),H(!1),G(-1)));switch(e.keyCode){case n.Keys.enter:case n.Keys.space:t>=0&&ce(e,t),m||ee(e),e.preventDefault(),H(!U),G(U?-1:0);break;case n.Keys.esc:e.preventDefault(),H(!1),G(-1);break;case n.Keys.home:e.preventDefault(),G(0);break;case n.Keys.end:e.preventDefault(),G(s-1);break;case n.Keys.down:case n.Keys.right:e.preventDefault(),G(t+1>=s?0:t+1);break;case n.Keys.up:case n.Keys.left:e.preventDefault(),G(t-1<0?s-1:t-1)}n.dispatchEvent(K,e,W(),void 0)}),[K,V,G,J,H]),me=l.useMemo((()=>n.classNames("k-fab k-fab-solid",{"k-fab-sm":"small"===b,"k-fab-md":"medium"===b,"k-fab-lg":"large"===b,"k-disabled":i,"k-pos-absolute":"absolute"===v,"k-pos-fixed":"fixed"===v,"k-focus":j,[`k-rounded-${n.kendoThemeMaps.roundedMap[y]||y}`]:y,[`k-fab-solid-${k}`]:k},`k-${s.vertical}-${s.horizontal}`,a)),[k,b,y,i,v,s,j,a]),he=m&&m.map(((e,t)=>l.createElement(X,{...e,key:t,index:t,id:`${Q}-${t}`,disabled:i||e.disabled,focused:V===t,dataItem:e,item:h,className:n.classNames(e.className,ne(_||"ltr",s.horizontal)),onClick:de,onDown:ue}))),fe=!(!c&&!d||f),ve=(A.current?A.current.offsetWidth:0)/2-16;return l.createElement(n.ZIndexContext.Provider,{value:F},l.createElement(l.Fragment,null,l.createElement("button",{ref:A,id:p||Z,role:"button",type:"button","aria-disabled":i,"aria-expanded":m?U:void 0,"aria-haspopup":!!m,"aria-label":`${f||""} floatingactionbutton`,"aria-owns":m?Q:void 0,"aria-activedescendant":V>=0&&m?`${Q}-${V}`:void 0,tabIndex:n.getTabIndex(I,i),accessKey:x,dir:_,disabled:i,className:me,style:g,onClick:ee,onMouseDown:ie,onFocus:re,onBlur:ae,onKeyDown:pe,...M},c||d?l.createElement(n.IconWrap,{className:"k-fab-icon",name:c,icon:d}):u?l.createElement("span",{role:"presentation",className:u}):null,f&&l.createElement("span",{className:"k-fab-text"},f)),D&&U&&l.createElement("div",{className:"k-overlay",style:{zIndex:F,...C}}),l.createElement(o.Popup,{ref:$,anchor:A.current,show:U,animate:E.animate,popupClass:n.classNames("k-popup-transparent k-fab-popup",E.popupClass),anchorAlign:E.anchorAlign||te(s,J),popupAlign:E.popupAlign||se(s,J),style:{boxShadow:"none"}},l.createElement("ul",{ref:T,role:"menu","aria-labelledby":p,id:Q,className:n.classNames("k-fab-items",{"k-fab-items-bottom":"bottom"!==s.vertical,"k-fab-items-top":"bottom"===s.vertical}),style:{paddingLeft:fe?ve:void 0,paddingRight:fe?ve:void 0}},he))))}));ie.propTypes={className:s.string,style:s.object,id:s.string,dir:s.string,tabIndex:s.number,accessKey:s.string,disabled:s.bool,icon:s.string,svgIcon:n.svgIconPropType,iconClass:s.string,text:s.string,alignOffset:s.shape({x:s.oneOfType([s.number,s.string]).isRequired,y:s.oneOfType([s.number,s.string]).isRequired}),align:s.shape({vertical:s.oneOf(["top","middle","bottom"]).isRequired,horizontal:s.oneOf(["start","center","end"]).isRequired}),positionMode:s.oneOf(["absolute","fixed"]),size:s.oneOf([null,"small","medium","large"]),rounded:s.oneOf([null,"small","medium","large","full"]),themeColor:s.oneOf([null,"primary","secondary","tertiary","info","success","warning","error","dark","light","inverse"]),modal:s.bool,overlayStyle:s.object};const le={align:{vertical:"bottom",horizontal:"end"},size:"medium",rounded:"full",themeColor:"primary",positionMode:"fixed"};ie.displayName="KendoFloatingActionButton";const ce=n.withIdHOC(E);ce.displayName="KendoReactDropDownButton";const de=n.withIdHOC(k);de.displayName="KendoReactSplitButton",e.Button=c,e.ButtonGroup=u,e.Chip=q,e.ChipList=_,e.DropDownButton=ce,e.DropDownButtonClassComponent=E,e.DropDownButtonItem=I,e.FloatingActionButton=ie,e.FloatingActionButtonItem=X,e.SplitButton=de,e.SplitButtonClassComponent=k,e.SplitButtonItem=h,e.Toolbar=F,e.ToolbarItem=A,e.ToolbarSeparator=N,e.ToolbarSpacer=T,e.toolbarButtons=w}));
|
|
15
|
+
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("react"),require("prop-types"),require("@progress/kendo-react-common"),require("@progress/kendo-react-popup"),require("@progress/kendo-svg-icons"),require("@progress/kendo-react-intl")):"function"==typeof define&&define.amd?define(["exports","react","prop-types","@progress/kendo-react-common","@progress/kendo-react-popup","@progress/kendo-svg-icons","@progress/kendo-react-intl"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).KendoReactButtons={},e.React,e.PropTypes,e.KendoReactCommon,e.KendoReactPopup,e.KendoSvgIcons,e.KendoReactIntl)}(this,(function(e,t,s,n,o,r,a){"use strict";function i(e){var t=Object.create(null);return e&&Object.keys(e).forEach((function(s){if("default"!==s){var n=Object.getOwnPropertyDescriptor(e,s);Object.defineProperty(t,s,n.get?n:{enumerable:!0,get:function(){return e[s]}})}})),t.default=e,Object.freeze(t)}var l=i(t);const c=l.forwardRef(((e,t)=>{const{children:s,togglable:o,dir:r,disabled:a,selected:i,icon:c,iconClass:u,svgIcon:p,imageUrl:m,imageAlt:h,className:f,startIcon:v,endIcon:b,onClick:g,size:y=d.size,rounded:k=d.rounded,fillMode:C=d.fillMode,themeColor:I=d.themeColor,...x}=e,E=l.useRef(),w=l.useRef(null),[D,N]=l.useState(!0===o&&!0===i),B=void 0!==p||void 0!==c||void 0!==u||void 0!==m,S=void 0!==s,K=n.useUnstyled(),R=e.unstyled||K,O=R&&R.uButton;l.useImperativeHandle(t,(()=>({element:w.current,selected:void 0!==E.current?E.current:D}))),l.useMemo((()=>{o&&void 0!==i&&i!==D&&N(i)}),[o,i]),l.useEffect((()=>{E.current=void 0}),[D]);const M=function({imageUrl:e,name:t,iconClass:s,svgIcon:o,imageAlt:r,buttonClasses:a}){return e?l.createElement("img",{role:"presentation",className:n.classNames(n.uButton.icon({c:a})),alt:r,src:e}):t||o?l.createElement(n.IconWrap,{className:n.classNames(n.uButton.icon({c:a})),name:t,icon:o}):s?l.createElement("span",{role:"presentation",className:n.classNames(n.uButton.icon({c:a}),s)}):null}({name:c,svgIcon:p,iconClass:u,imageUrl:m,imageAlt:h,buttonClasses:O}),z=e=>l.cloneElement(e,{className:n.classNames(n.uButton.icon({c:O}))});return l.createElement("button",{ref:w,"aria-pressed":o?D:void 0,...x,dir:r,disabled:a,onClick:e=>{o&&void 0===i&&(E.current=!D,N(!D)),g&&g.call(void 0,e)},className:n.classNames(n.uButton.wrapper({c:O,isRtl:"rtl"===r,selected:D,disabled:a,size:y,fillMode:C,rounded:k,themeColor:I,iconButton:!S&&B}),f)},v&&z(v),M,s&&l.createElement("span",{className:n.classNames(n.uButton.text({c:O}))},s),b&&z(b))})),d={togglable:!1,size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};c.displayName="KendoReactButton",c.propTypes={children:s.node,selected:s.bool,togglable:s.bool,icon:s.string,svgIcon:n.svgIconPropType,iconClass:s.string,imageUrl:s.string,imageAlt:s.string,size:s.oneOf([null,"small","medium","large"]),rounded:s.oneOf([null,"small","medium","large","full"]),fillMode:s.oneOf([null,"flat","link","outline","solid","clear"]),themeColor:s.oneOf([null,"base","primary","secondary","tertiary","info","success","warning","error","dark","light","inverse"])};const u=e=>{const{children:t,className:s,dir:o,disabled:r,width:a}=e,i=n.useUnstyled(),c=e.unstyled||i,d=c&&c.uButtonGroup,u=(e,t)=>{const s={...a?{width:a}:{},...e.props.style||{}},n=r||e.props.disabled,o={...e.props,...t?{className:t}:{},...Object.keys(s).length?{style:s}:{},...void 0!==n?{disabled:n}:{}};return l.Children.count(e.props.children)>0?l.cloneElement(e,o,e.props.children):l.cloneElement(e,o)},p=l.useRef(null),m=(e=>{const t=l.Children.count(e),s=void 0!==o?"rtl"===o:p.current&&"rtl"===getComputedStyle(p.current).direction||!1;return l.Children.map(e,((e,o)=>{if(l.isValidElement(e)){const r=o===t-1,a=s,i=n.classNames(e.props.className,n.uButtonGroup.position({c:d,start:a?r:0===o,end:a?0===o:r}));return u(e,i)}return e}))})(t),h=n.classNames(n.uButtonGroup.wrapper({c:d,stretched:!!a,disabled:r}),s),f={className:h,style:{width:`${a}`},dir:o,role:"group","aria-disabled":r};return l.createElement("div",{ref:p,...f,className:h},m)};u.propTypes={children:s.oneOfType([s.arrayOf(s.element),s.element]),className:s.string,disabled:s.bool,width:s.string,dir:s.string};const p=e=>{const t=n.useUnstyled(),s=e.unstyled||t,o=s&&s.uDropDownButton,r=l.useCallback((t=>{e.onClick(t,e.index)}),[e]),a=e.dataItem.render||e.item||(void 0===e.item?e.render:null),i=void 0!==e.dataItem.text?e.dataItem.text:e.textField?e.dataItem[e.textField]:e.dataItem,c=l.createElement("li",{id:e.id,className:n.classNames(n.uDropDownButton.li({c:o,focused:e.focused}),e.className),tabIndex:-1,onClick:r,onMouseDown:e.onDown,onPointerDown:e.onDown,role:"menuitem","aria-disabled":e.dataItem.disabled||void 0},l.createElement("span",{tabIndex:-1,className:n.classNames(n.uDropDownButton.link({c:o,selected:e.dataItem.selected,disabled:e.dataItem.disabled})),key:"icon"},a?l.createElement(a,{item:e.dataItem,itemIndex:e.index}):l.createElement(l.Fragment,null,(e.dataItem.icon||e.dataItem.iconClass||e.dataItem.svgIcon)&&l.createElement(n.IconWrap,{className:e.dataItem.iconClass,name:e.dataItem.icon,icon:e.dataItem.svgIcon}),e.dataItem.imageUrl&&l.createElement("img",{role:"presentation",alt:"",src:e.dataItem.imageUrl,className:"k-icon"}),i&&l.createElement("span",{className:"k-menu-link-text"},i))));return void 0!==e.item&&void 0!==e.render?e.render.call(void 0,c,e):c};p.displayName="KendoReactButtonItem";const m=class extends l.Component{render(){return null}};m.propTypes={text:s.string,icon:s.string,iconClass:s.string,imageUrl:s.string,disabled:s.bool,render:s.any};let h=m;const f=(e,t,s,o)=>{if(s)return e;const r=Math.min(o-1,Math.max(0,e));switch(t){case n.Keys.enter:case n.Keys.space:case n.Keys.esc:return-1;case n.Keys.up:case n.Keys.left:return r-1<0?o-1:r-1;case n.Keys.down:case n.Keys.right:return r+1>=o?0:r+1;case n.Keys.home:return 0;case n.Keys.end:return o-1;default:return e}};function v(e){const t={horizontal:"left",vertical:"bottom"};return e&&(t.horizontal="right"),t}function b(e){const t={horizontal:"left",vertical:"top"};return e&&(t.horizontal="right"),t}const g={name:"@progress/kendo-react-buttons",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate:0,version:"$VERSION",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"},y=class extends l.Component{constructor(e){super(e),this.state={focused:!1,focusedIndex:-1,opened:!1},this.wrapper=null,this.mainButton=null,this.list=null,this.skipFocus=!1,this.buttonsData=[],this.showLicenseWatermark=!1,this.onKeyDown=e=>{const{focusedIndex:t}=this.state;if(e.altKey)return void(this.opened||e.keyCode!==n.Keys.down?this.opened&&e.keyCode===n.Keys.up&&(e.preventDefault(),this.setState({focusedIndex:-1}),this.setOpen(!1,e)):(e.preventDefault(),this.setState({focusedIndex:0}),this.setOpen(!0,e)));let s;if(e.keyCode===n.Keys.enter||e.keyCode===n.Keys.space){if(e.preventDefault(),this.dispatchClickEvent(e,t),t>=0){s={focusedIndex:this.opened?-1:0};const t=!this.opened;this.setOpen(t,e)}}else if(this.opened&&e.keyCode===n.Keys.esc)return this.setState({focusedIndex:-1}),void this.setOpen(!1,e);if(this.opened){const o=f(t,e.keyCode,e.altKey,this.buttonsData.length);o!==t&&(s=s||{},s.focusedIndex=o);const r=e.keyCode===n.Keys.up||e.keyCode===n.Keys.down||e.keyCode===n.Keys.left||e.keyCode===n.Keys.right;!e.altKey&&(r||e.keyCode===n.Keys.home||e.keyCode===n.Keys.end)&&e.preventDefault()}s&&this.setState(s)},this.switchFocus=e=>{this.skipFocus=!0,e(),window.setTimeout((()=>this.skipFocus=!1),0)},this.onFocus=e=>{this.skipFocus||(n.dispatchEvent(this.props.onFocus,e,this,void 0),this.setState({focused:!0}))},this.setOpen=(e,t)=>{this.opened!==e&&(this.openedDuringOnChange=e,this.setState({opened:e}),t?this.dispatchPopupEvent(t,e):this.openedDuringOnChange=void 0)},this.onItemClick=(e,t)=>{this.opened&&this.setState({focusedIndex:0}),this.dispatchClickEvent(e,t),this.setOpen(!1,e)},this.onBlur=e=>{this.skipFocus||(this.setState({focused:!1,focusedIndex:-1}),n.dispatchEvent(this.props.onBlur,e,this,void 0),setTimeout((()=>{this.setOpen(!1,e)}),0))},this.onPopupClose=e=>{var t;const s=n.getActiveElement(document);this.element&&this.element.removeAttribute("tabindex"),(s===this.list||null!=(t=this.list)&&t.contains(s))&&this.switchFocus((()=>{this.element&&this.element.focus({preventScroll:!0})})),this.props.popupSettings&&this.props.popupSettings.onClose&&this.props.popupSettings.onClose.call(void 0,e)},this.listRef=e=>{this.list=e,e&&this.state.focused&&this.switchFocus((()=>{e.focus({preventScroll:!0}),this.element&&(this.element.tabIndex=-1)}))},this.onSplitPartClick=e=>{if(this.buttonsData.length){const t=!this.opened;this.setState({focusedIndex:t?0:-1,focused:!0}),this.setOpen(t,e)}},this.onDownSplitPart=e=>{e.preventDefault();const t=n.getActiveElement(document);this.element&&t!==this.element&&t!==this.list&&this.element.focus()},this.onItemDown=e=>{n.getActiveElement(document)===this.list&&e.preventDefault()},this.dispatchPopupEvent=(e,t)=>{n.dispatchEvent(t?this.props.onOpen:this.props.onClose,e,this,void 0),this.openedDuringOnChange=void 0},this.showLicenseWatermark=!n.validatePackage(g,{component:"SplitButton"})}get guid(){return this.props.id?this.props.id+"-accessibility-id":this.props.id}get opened(){return void 0!==this.openedDuringOnChange?this.openedDuringOnChange:void 0===this.props.opened?this.state.opened:this.props.opened}render(){this.buttonsData=this.props.items||l.Children.toArray(this.props.children).filter((e=>e&&e.type===h)).map((e=>e.props));const e=this.isRtl(),t=e?"rtl":void 0,{id:s,style:o,tabIndex:a,disabled:i}=this.props;return l.createElement(l.Fragment,null,l.createElement("div",{id:s,style:o,className:n.classNames("k-split-button","k-button-group",{"k-focus":this.state.focused},`k-rounded-${n.kendoThemeMaps.roundedMap[this.props.rounded||"medium"]}`,this.props.className),onKeyDown:this.onKeyDown,onFocus:this.onFocus,onBlur:this.onBlur,dir:t,ref:e=>this.wrapper=e},l.createElement(c,{ref:e=>this.mainButton=e&&e.element,type:"button",size:this.props.size,rounded:this.props.rounded,fillMode:this.props.fillMode,themeColor:this.props.themeColor,onClick:e=>this.onItemClick(e,-1),disabled:i||void 0,tabIndex:a,accessKey:this.props.accessKey,className:this.props.buttonClass,icon:this.props.icon,svgIcon:this.props.svgIcon,iconClass:this.props.iconClass,startIcon:this.props.startIcon,endIcon:this.props.endIcon,imageUrl:this.props.imageUrl,dir:t,"aria-disabled":i,"aria-haspopup":!0,"aria-expanded":this.opened||void 0,"aria-label":this.props.ariaLabel,"aria-controls":this.opened?this.guid:void 0,id:"button-"+this.guid,title:this.props.title},this.props.text),l.createElement(c,{type:"button",size:this.props.size,rounded:this.props.rounded,fillMode:this.props.fillMode,themeColor:this.props.themeColor,icon:"caret-alt-down",svgIcon:r.caretAltDownIcon,className:"k-split-button-arrow",disabled:i||void 0,tabIndex:-1,onClick:this.onSplitPartClick,onMouseDown:this.onDownSplitPart,onPointerDown:this.onDownSplitPart,dir:t,"aria-label":"menu toggling button"}),this.renderPopup(e)),this.showLicenseWatermark&&l.createElement(n.WatermarkOverlay,null))}componentDidMount(){(void 0===this.props.dir&&this.isRtl()||this.opened)&&this.forceUpdate()}get element(){return this.mainButton}dispatchClickEvent(e,t){this.isItemDisabled(t)||(-1===t?n.dispatchEvent(this.props.onButtonClick,e,this,void 0):n.dispatchEvent(this.props.onItemClick,e,this,{item:this.buttonsData[t],itemIndex:t}))}renderPopup(e){const{popupSettings:t={}}=this.props,{focusedIndex:s}=this.state;return l.createElement(o.Popup,{anchor:this.wrapper,show:this.opened,animate:t.animate,popupClass:n.classNames("k-menu-popup",t.popupClass),anchorAlign:t.anchorAlign||v(e),popupAlign:t.popupAlign||b(e),style:e?{direction:"rtl"}:void 0,onClose:this.onPopupClose},l.createElement("ul",{role:"menu",id:this.guid,"aria-labelledby":"button-"+this.guid,tabIndex:-1,ref:this.listRef,"aria-activedescendant":s>=0?`${this.guid}-${s}`:void 0,className:n.classNames("k-menu-group",{[`k-menu-group-${n.kendoThemeMaps.sizeMap[this.props.size]||this.props.size}`]:this.props.size})},this.renderChildItems()))}renderChildItems(){const{item:e,itemRender:t,textField:s}=this.props;return this.buttonsData.length>0?this.buttonsData.map(((o,r)=>l.createElement(p,{className:n.classNames("k-menu-item",{"k-first":0===r},{"k-last":r===this.buttonsData.length-1}),dataItem:o,textField:s,focused:this.state.focusedIndex===r,onClick:this.onItemClick,onDown:this.onItemDown,render:t,item:e,key:r,index:r,id:`${this.guid}-${r}`}))):null}isItemDisabled(e){return this.buttonsData[e]?this.buttonsData[e].disabled:this.props.disabled}isRtl(){return void 0!==this.props.dir?"rtl"===this.props.dir:!!this.wrapper&&"rtl"===getComputedStyle(this.wrapper).direction}};y.propTypes={accessKey:s.string,ariaLabel:s.string,title:s.string,onButtonClick:s.func,onFocus:s.func,onBlur:s.func,onItemClick:s.func,onOpen:s.func,onClose:s.func,text:s.string,items:s.arrayOf(s.any),textField:s.string,tabIndex:s.number,disabled:s.bool,icon:s.string,svgIcon:n.svgIconPropType,iconClass:s.string,imageUrl:s.string,popupSettings:s.object,itemRender:s.any,item:s.func,className:s.string,buttonClass:s.string,dir:s.string},y.defaultProps={size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let k=y;const C=class extends l.Component{render(){return null}};C.propTypes={text:s.string,icon:s.string,iconClass:s.string,imageUrl:s.string,selected:s.bool,disabled:s.bool,render:s.any};let I=C;const x=class extends l.Component{constructor(e){super(e),this.state={opened:!1,focused:!1,focusedIndex:-1},this.mainButton=null,this.list=null,this.skipFocus=!1,this.showLicenseWatermark=!1,this.buttonsData=[],this.onKeyDown=e=>{const{focusedIndex:t}=this.state;if(e.altKey)return void(this.opened||e.keyCode!==n.Keys.down?this.opened&&e.keyCode===n.Keys.up&&(e.preventDefault(),this.setState({focusedIndex:-1}),this.setOpen(!1,e)):(e.preventDefault(),this.setOpen(!0,e),this.setState({focusedIndex:0})));const s={...this.state};if(e.keyCode===n.Keys.enter||e.keyCode===n.Keys.space){e.preventDefault(),t>=0&&this.dispatchClickEvent(e,t);const s=!this.opened;return this.setState({focused:!0,focusedIndex:s?0:-1}),void this.setOpen(s,e)}if(this.opened&&e.keyCode===n.Keys.esc)return this.setState({focusedIndex:-1}),void this.setOpen(!1,e);if(this.opened){const o=f(t,e.keyCode,e.altKey,this.buttonsData.length);s.focusedIndex=o;const r=e.keyCode===n.Keys.up||e.keyCode===n.Keys.down||e.keyCode===n.Keys.left||e.keyCode===n.Keys.right;!e.altKey&&(r||e.keyCode===n.Keys.home||e.keyCode===n.Keys.end)&&e.preventDefault()}this.setState(s)},this.switchFocus=e=>{this.skipFocus=!0,e(),window.setTimeout((()=>this.skipFocus=!1),0)},this.handleFocus=e=>{this.skipFocus||(this.setState({focused:!0,focusedIndex:this.opened?0:-1}),n.dispatchEvent(this.props.onFocus,e,this,void 0))},this.handleButtonBlur=e=>{this.opened||(this.setState({focused:!1}),n.dispatchEvent(this.props.onBlur,e,this,void 0))},this.handleMenuBlur=e=>{this.skipFocus||(this.setState({focused:!1,focusedIndex:-1}),n.dispatchEvent(this.props.onBlur,e,this,void 0),setTimeout((()=>{this.setOpen(!1,e)}),0))},this.setOpen=(e,t)=>{this.opened!==e&&(this.openedDuringOnChange=e,this.setState({opened:e}),t?this.dispatchPopupEvent(t,e):this.openedDuringOnChange=void 0)},this.onItemClick=(e,t)=>{this.setState({focusedIndex:-1}),this.dispatchClickEvent(e,t),this.setOpen(!1,e)},this.onItemDown=e=>{n.getActiveElement(document)===this.list&&e.preventDefault()},this.mouseDown=e=>{e.preventDefault();const t=n.getActiveElement(document);this.element&&t!==this.element&&t!==this.list&&this.element.focus()},this.onPopupClose=e=>{var t;const s=n.getActiveElement(document);this.element&&this.element.removeAttribute("tabindex"),(s===this.list||null!=(t=this.list)&&t.contains(s))&&this.switchFocus((()=>{this.element&&this.element.focus({preventScroll:!0})})),this.props.popupSettings&&this.props.popupSettings.onClose&&this.props.popupSettings.onClose.call(void 0,e)},this.listRef=e=>{this.list=e,e&&this.state.focused&&this.switchFocus((()=>{e.focus({preventScroll:!0}),this.element&&(this.element.tabIndex=-1)}))},this.onClickMainButton=e=>{if(!this.buttonsData.length)return;const t=!this.opened;this.setState({focused:!0,focusedIndex:t?0:-1}),this.setOpen(t,e)},this.dispatchPopupEvent=(e,t)=>{n.dispatchEvent(t?this.props.onOpen:this.props.onClose,e,this,void 0),this.openedDuringOnChange=void 0},this.showLicenseWatermark=!n.validatePackage(g,{component:"DropDownButton"})}get guid(){return this.props.id+"-accessibility-id"}get opened(){return void 0!==this.openedDuringOnChange?this.openedDuringOnChange:void 0===this.props.opened?this.state.opened:this.props.opened}render(){const e=this.isRtl(),t=this.props.unstyled&&this.props.unstyled.uDropDownButton,s=e?"rtl":void 0,{id:o,style:r,tabIndex:a,disabled:i,size:d,rounded:u,fillMode:p,themeColor:m,ariaLabel:h,title:f,accessKey:v,icon:b,svgIcon:g,iconClass:y,buttonClass:k,className:C,imageUrl:x,startIcon:E,endIcon:w}=this.props;return this.buttonsData=this.props.items||l.Children.toArray(this.props.children).filter((e=>e&&e.type===I)).map((e=>e.props)),l.createElement(l.Fragment,null,l.createElement(c,{id:o,size:d,style:r,rounded:u,fillMode:p,themeColor:m,onClick:this.onClickMainButton,onMouseDown:this.mouseDown,onKeyDown:this.onKeyDown,onFocus:this.handleFocus,onBlur:this.handleButtonBlur,"aria-disabled":i?"true":void 0,tabIndex:a,accessKey:v,icon:b,svgIcon:g,iconClass:y,className:n.classNames(k,C,n.uDropDownButton.wrapper({c:t,focused:this.state.focused,disabled:i})),imageUrl:x,dir:s,ref:e=>this.mainButton=e&&e.element,type:"button","aria-expanded":this.opened?"true":"false","aria-label":h,"aria-controls":this.opened?this.guid:void 0,title:f,startIcon:E,endIcon:w},this.props.text),this.showLicenseWatermark&&l.createElement(n.WatermarkOverlay,null),this.renderPopup(e))}componentDidMount(){(void 0===this.props.dir&&this.isRtl()||this.opened)&&this.forceUpdate()}get element(){return this.mainButton}dispatchClickEvent(e,t){this.isItemDisabled(t)||n.dispatchEvent(this.props.onItemClick,e,this,{item:this.buttonsData[t],itemIndex:t})}renderPopup(e){const{popupSettings:t={},_zIndex:s,unstyled:r}=this.props,a=s?s+2e3:12e3,i=r&&r.uDropDownButton,{focusedIndex:c}=this.state;return l.createElement(n.ZIndexContext.Provider,{value:a},l.createElement(o.Popup,{anchor:this.mainButton,show:this.opened,animate:t.animate,popupClass:n.classNames(n.uDropDownButton.popup({c:i}),t.popupClass),anchorAlign:t.anchorAlign||v(e),popupAlign:t.popupAlign||b(e),style:e?{direction:"rtl"}:void 0,onClose:this.onPopupClose},l.createElement("ul",{role:"list",id:this.guid,tabIndex:-1,"aria-activedescendant":c>=0?`${this.guid}-${c}`:void 0,ref:this.listRef,onKeyDown:this.onKeyDown,onBlur:this.handleMenuBlur,className:n.classNames(n.uDropDownButton.ul({c:i,size:this.props.size}))},this.renderChildItems())))}renderChildItems(){const{item:e,itemRender:t,textField:s,unstyled:o}=this.props,r=o&&o.uDropDownButton;return this.buttonsData.length>0?this.buttonsData.map(((o,a)=>l.createElement(p,{className:n.classNames(n.uDropDownButton.item({c:r}),o.className,{"k-first":0===a},{"k-last":a===this.buttonsData.length-1}),dataItem:o,textField:s,focused:this.state.focusedIndex===a,onClick:this.onItemClick,onDown:this.onItemDown,render:t,item:e,index:a,key:a,id:`${this.guid}-${a}`}))):null}isItemDisabled(e){return this.buttonsData[e]?this.buttonsData[e].disabled:this.props.disabled}isRtl(){return void 0!==this.props.dir?"rtl"===this.props.dir:!!this.mainButton&&"rtl"===getComputedStyle(this.mainButton).direction}};x.propTypes={accessKey:s.string,ariaLabel:s.string,title:s.string,onFocus:s.func,onBlur:s.func,onItemClick:s.func,onOpen:s.func,onClose:s.func,items:s.arrayOf(s.any),textField:s.string,tabIndex:s.number,disabled:s.bool,icon:s.string,svgIcon:n.svgIconPropType,iconClass:s.string,imageUrl:s.string,popupSettings:s.object,itemRender:s.func,item:s.func,className:s.string,buttonClass:s.string,dir:s.string},x.defaultProps={size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};let E=x;const w=n.createPropsContext(),D=n.withIdHOC(n.withPropsContext(w,n.withUnstyledHOC(n.withZIndexContext(E))));D.displayName="KendoReactDropDownButton";const N=":not(.k-dropdownlist button):not(.k-colorpicker button):not(.k-split-button .k-split-button-arrow)",B=["button"+N,".k-button-group > button"+N,".k-colorpicker",".k-dropdownlist"],S=e=>l.createElement("div",{ref:e._ref,className:n.classNames("k-toolbar-separator k-separator",e.className)}),K="prevArrow.title",R="nextArrow.title",O="moreButtonTitle.title",M={[K]:"Previous scroll button",[R]:"Next scroll button",[O]:"More button"},z=e=>{const t=a.useLocalization(),{disabled:s,type:o,scrollContentRef:i,buttonScrollSpeed:c,prevButton:d,nextButton:u}=e,p="prev"===o?d||"span":u||"span";return l.createElement(p,{className:n.classNames("k-button","k-button-md","k-button-solid","k-button-solid-base","k-rounded-md","k-icon-button",`k-toolbar-${o}`,{"k-disabled":s}),title:`${"prev"===o?t.toLanguageString(K,M[K]):t.toLanguageString(R,M[R])}`,"aria-hidden":!0,tabIndex:s?-1:void 0,onClick:e=>{i&&i.current&&c&&i.current.scrollBy({left:"next"===o?c:-c,behavior:"smooth"})}},l.createElement(n.SvgIcon,{icon:"prev"===o?r.caretAltLeftIcon:r.caretAltRightIcon,className:"k-button-icon"}))},F=e=>{const{scrollButtons:t,scrollButtonsPosition:s,isOverflowing:n,scrollContentRef:o,buttonScrollSpeed:r,dir:a,isScrollStartPosition:i,isScrollEndPosition:c,prevButton:d,nextButton:u,children:p}=e,m=(e,t)=>l.createElement(z,{type:e,disabled:t,scrollContentRef:o,buttonScrollSpeed:r,prevButton:d,nextButton:u}),h="visible"===t||"auto"===t&&n;return l.createElement(l.Fragment,null,h&&"split"===s&&l.createElement(l.Fragment,null,m("rtl"!==a?"prev":"next",i),l.createElement(S,{className:"k-toolbar-button-separator"})),h&&"start"===s&&l.createElement(l.Fragment,null,m("rtl"!==a?"prev":"next",i),m("rtl"!==a?"next":"prev",c),l.createElement(S,{className:"k-toolbar-button-separator"})),l.createElement("span",{className:"k-toolbar-items k-toolbar-items-scroll",ref:o},p),h&&"split"===s&&l.createElement(l.Fragment,null,l.createElement(S,{className:"k-toolbar-button-separator"}),m("rtl"!==a?"next":"prev",c)),h&&"end"===s&&l.createElement(l.Fragment,null,l.createElement(S,{className:"k-toolbar-button-separator"}),m("rtl"!==a?"prev":"next",i),m("rtl"!==a?"next":"prev",c)))},P=e=>{var t;const{toolbarRef:s,children:i,fillMode:d,size:u}=e,[p,m]=l.useState(!1),h=l.useRef(l.Children.toArray(i).filter((e=>l.isValidElement(e))).map(((e,t)=>l.cloneElement(e,{key:e.key||t})))),f=l.useRef([]),v=l.useRef(0),b=l.useRef(null),g=l.useRef(null),y=a.useLocalization(),[k,C]=l.useReducer((e=>e+1),0),I=()=>{if(!s.current)return;let e=0;const t=s.current.clientWidth,n=parseInt(window.getComputedStyle(s.current).gap||"0",10),o=Array.from(s.current.children).reduce(((e,t,s)=>e+=Math.ceil(t.clientWidth)),0),r=Array.from(s.current.children).length;if(e=o+r*n+2*n,e>t){const e=[...h.current],s=e.pop();v.current=t,h.current=e,s&&(f.current=[s,...f.current])}else if(t>v.current+n*r){const e=[...f.current],s=e.shift();f.current=e,s&&(h.current=[...h.current,s]),v.current=t}C()};l.useEffect((()=>{I();const e=new ResizeObserver(I),t=s.current;return t&&e.observe(t),()=>{t&&e.unobserve(t)}}),[]);return l.createElement(l.Fragment,null,h.current.length>0&&h.current,f.current.length>0&&l.createElement(l.Fragment,null,l.createElement(S,{_ref:g,className:"k-toolbar-button-separator"}),l.createElement(c,{ref:b,className:"k-toolbar-overflow-button",fillMode:"flat",svgIcon:r.moreHorizontalIcon,title:y.toLanguageString(O,M[O]),onClick:()=>{m(!p)}}),l.createElement(o.Popup,{anchor:s.current,show:p,popupClass:"k-toolbar-popup",style:{width:null==(t=s.current)?void 0:t.offsetWidth}},l.createElement("span",{className:`k-toolbar-items-list k-toolbar-items-list-${n.kendoThemeMaps.sizeMap[u]} k-toolbar-items-list-${d}`},f.current.length>0&&f.current))))},A=l.forwardRef(((e,t)=>{const{children:s,className:o,id:r,ariaLabel:a,keyboardNavigation:i,role:c,onResize:d,style:u,tabIndex:p=T.tabIndex,size:m=T.size,fillMode:h=T.fillMode,overflow:f,scrollButtons:v=T.scrollButtons,scrollButtonsPosition:b=T.scrollButtonsPosition,buttonScrollSpeed:g=T.buttonScrollSpeed,prevButton:y,nextButton:k}=e,C=l.useRef(!1),I=l.useRef(null),x=l.useRef(null),E=l.useRef(0),w=l.useRef(0),D=l.useRef([]),N=l.useRef({element:null,props:e}),[S,K]=l.useState(!1),[R,O]=l.useState(!0),[M,z]=l.useState(!1),A=n.useDir(I,e.dir),$=l.useMemo((()=>e.buttons||B),[e.buttons]),L=l.useMemo((()=>$.map((e=>e+":focus")).join(",")),[$]),W=()=>{const e=I.current&&I.current.querySelector(L);return Math.max(0,D.current.findIndex((t=>t===e)))};l.useImperativeHandle(N,(()=>({element:I.current,props:e}))),l.useImperativeHandle(t,(()=>N.current)),l.useEffect((()=>(window.addEventListener("resize",j),I.current&&(w.current=I.current.offsetWidth,E.current=I.current.offsetHeight,!1!==i&&(D.current=Array.from(I.current.querySelectorAll($.join(","))),H(0))),()=>{window.removeEventListener("resize",j),D.current.length=0})),[]),l.useEffect((()=>{if(C.current){if(!I.current||!1===i)return;D.current=Array.from(I.current.querySelectorAll($.join(","))),H(W()),q()}else C.current=!0}));const H=e=>{D.current.forEach(((t,s)=>{t.tabIndex=s===e?p:-1}))},U=(e,t)=>{const s=D.current[t];if(s){s.tabIndex=p,s.focus();const t=D.current[e];t&&(t.tabIndex=-1)}},j=e=>{if(!I.current)return;const t=I.current.offsetWidth,s=I.current.offsetHeight;if(w.current!==t||E.current!==s){w.current=t,E.current=s;const n={offsetWidth:w.current,offsetHeight:E.current};d&&d.call(void 0,{target:N.current,...n,nativeEvent:e})}q()},q=l.useCallback((()=>{const e=x.current;e&&K(e.scrollWidth>e.clientWidth||e.scrollHeight>e.clientHeight)}),[]),V=l.useCallback((()=>{const e=x.current;if(e){const t=0===e.scrollLeft,s="rtl"!==A?e.scrollLeft+e.clientWidth===e.scrollWidth:e.clientWidth-e.scrollLeft===e.scrollWidth;t&&O(!0),s&&z(!0),!t&&!s&&(O(!1),z(!1))}}),[A]);return l.useEffect((()=>{const e=x.current;if(e)return e.addEventListener("scroll",V),()=>{e.removeEventListener("scroll",V)}}),[V]),l.createElement("div",{id:r,"aria-label":a,className:n.classNames("k-toolbar",{[`k-toolbar-${n.kendoThemeMaps.sizeMap[m]||m}`]:m,[`k-toolbar-${h}`]:h,"k-toolbar-scrollable":"scroll"===f,"k-toolbar-scrollable-overlay":"scroll"===f&&("hidden"===v||void 0===v),"k-toolbar-scrollable-start":"scroll"===f&&"hidden"===v&&R,"k-toolbar-scrollable-end":"scroll"===f&&"hidden"===v&&M,"k-toolbar-section":e.overflow&&"section"===f},o),style:u,role:void 0!==c?c||void 0:"toolbar",dir:A,ref:I,onKeyDown:!1!==i?e=>{const t=e.keyCode===n.Keys.left||e.keyCode===n.Keys.right||e.keyCode===n.Keys.home||e.keyCode===n.Keys.end,s=W();!t||e.defaultPrevented||-1===D.current.findIndex((t=>t===e.target))||(e.keyCode===n.Keys.left?U(s,0===s?D.current.length-1:s-1):U(s,s===D.current.length-1?0:s+1),e.keyCode===n.Keys.home&&U(s,0),e.keyCode===n.Keys.end&&U(s,D.current.length-1))}:void 0},"scroll"===f&&l.createElement(F,{scrollButtons:v,scrollButtonsPosition:b,prevButton:y,nextButton:k,isOverflowing:S,scrollContentRef:x,buttonScrollSpeed:g,dir:A,isScrollStartPosition:R,isScrollEndPosition:M,children:s}),"section"===f&&l.createElement(P,{toolbarRef:I,fillMode:h,size:m},s),("none"===f||void 0===f)&&s)})),T={tabIndex:0,size:"medium",fillMode:"solid",scrollButtons:"auto",scrollButtonsPosition:"split",buttonScrollSpeed:100};A.displayName="KendoReactToolbar",A.propTypes={tabIndex:s.number,dir:s.string,keyboardNavigation:s.bool,style:s.object,className:s.string,role:s.string,onResize:s.func,buttons:s.arrayOf(s.string.isRequired),size:s.oneOf([null,"small","medium","large"]),fillMode:s.oneOf([null,"solid","flat","outline"]),overflow:s.oneOf(["none","section","scroll"]),scrollButtons:s.oneOf(["hidden","visible","auto"]),scrollButtonsPosition:s.oneOf(["start","end","split"]),buttonScrollSpeed:s.number};const $=l.forwardRef(((e,t)=>{const{id:s,className:o,style:r,children:a}=e,i=l.useRef(null);return l.useImperativeHandle(t,(()=>({element:i.current}))),l.createElement("div",{id:s,className:n.classNames("k-toolbar-item",o),style:r,ref:i},a)}));$.displayName="KendoReactToolbarItem",$.propTypes={className:s.string};const L=l.forwardRef(((e,t)=>{const s=l.useRef(null),o=l.useRef(null);l.useImperativeHandle(o,(()=>({element:s.current}))),l.useImperativeHandle(t,(()=>({element:s.current})));const r=l.useMemo((()=>n.classNames("k-spacer",e.className)),[e.className]);return l.createElement("span",{ref:s,className:r})}));L.displayName="KendoReactToolbarSpacer",L.propTypes={className:s.string};const W=t.createContext([null,e=>{}]),H=t.createContext([null,e=>{}]),U=t.createContext([null,e=>{}]);var j=(e=>(e.next="next",e.prev="prev",e.current="current",e.reset="reset",e))(j||{});var q=(e=>(e.remove="remove",e.add="add",e.reorder="reorder",e))(q||{});var V=(e=>(e.toggle="toggle",e.remove="remove",e))(V||{});const G=l.forwardRef(((e,t)=>{const s=l.useRef(null),o=l.useRef(null),{disabled:a=_.disabled,fillMode:i=_.fillMode,themeColor:c=_.themeColor,size:d=_.size,rounded:u=_.rounded,dir:p=_.dir,removeIcon:m=_.removeIcon,removeSvgIcon:h=_.removeSvgIcon,removable:f=_.removable}=e,v=n.useDir(o,p);l.useImperativeHandle(s,(()=>({element:o.current,props:e}))),l.useImperativeHandle(t,(()=>s.current));const[b,g]=l.useContext(W),[y,k]=l.useContext(H),[,C]=l.useContext(U),I=l.useMemo((()=>e.selected||(Array.isArray(b)?b.some((t=>t===e.value)):b===e.value)),[e.selected,e.value,b]),x=l.useMemo((()=>y===e.value),[e.value,y]);l.useEffect((()=>{x&&o.current&&o.current.focus()}),[x]);const E=l.useCallback((t=>{g({type:V.toggle,payload:e.value,event:t})}),[g,e.value]),w=l.useCallback((t=>{f&&(C({type:q.remove,payload:e.value,event:t}),k({type:j.reset,payload:e.value,event:t}),g({type:V.remove,payload:e.value,event:t}),e.onRemove&&e.onRemove.call(void 0,{target:s.current,syntheticEvent:t}))}),[e.onRemove,e.value,f,C,k,g]),D=l.useCallback((t=>{switch(t.keyCode){case n.Keys.left:k({type:j.prev,payload:e.value,event:t});break;case n.Keys.right:k({type:j.next,payload:e.value,event:t});break;case n.Keys.enter:g({type:V.toggle,payload:e.value,event:t});break;case n.Keys.delete:w(t)}e.onKeyDown&&e.onKeyDown.call(void 0,{target:s.current,syntheticEvent:t})}),[e.onKeyDown,e.value,k,g,w]),N=l.useCallback((t=>{k({payload:e.value,type:j.current,event:t}),e.onFocus&&e.onFocus.call(void 0,{target:s.current,syntheticEvent:t})}),[e.onFocus,e.value,k]),B=l.useCallback((t=>{e.onBlur&&e.onBlur.call(void 0,{target:s.current,syntheticEvent:t})}),[e.onBlur]),S=n.useMouse(e,s,{onClick:E});return l.createElement("div",{...S,role:e.role||"button",id:e.value,style:e.style,ref:o,dir:v,tabIndex:n.getTabIndex(e.tabIndex,a,void 0),className:n.classNames("k-chip",{"k-rtl":"rtl"===v,"k-disabled":a,"k-selected":I,"k-focus":x,[`k-chip-${n.kendoThemeMaps.sizeMap[d]||d}`]:d,[`k-rounded-${n.kendoThemeMaps.roundedMap[u]||u}`]:u,[`k-chip-${i}`]:i,[`k-chip-${i}-${c}`]:!(!i||!c)},e.className),"aria-pressed":e.role?void 0:I,"aria-disabled":a,"aria-describedby":e.ariaDescribedBy,"aria-keyshortcuts":f?"Enter Delete":void 0,onFocus:N,onBlur:B,onKeyDown:D},I&&(e.selectedIcon||e.selectedSvgIcon)&&l.createElement(n.IconWrap,{className:"k-chip-icon",name:e.selectedIcon?n.toIconName(e.selectedIcon):void 0,icon:e.selectedSvgIcon,size:"small"}),(e.icon||e.svgIcon)&&l.createElement(n.IconWrap,{className:"k-chip-icon",name:e.icon?n.toIconName(e.icon):void 0,icon:e.svgIcon,size:"small"}),e.avatar&&l.createElement("div",{className:`k-chip-avatar k-avatar k-rounded-${e.avatar.rounded} k-avatar-md k-avatar-solid k-avatar-solid-primary`,style:e.avatar.style},l.createElement("span",{className:"k-avatar-image"},l.createElement("img",{src:e.avatar.image,alt:e.avatar.imageAlt}))),l.createElement("span",{className:"k-chip-content"},void 0!==e.children?e.children:e.text&&l.createElement("span",{"aria-label":e.ariaLabel||e.text,className:"k-chip-label"},e.text)),f&&l.createElement("span",{className:"k-chip-actions"},l.createElement("span",{className:n.classNames("k-chip-action","k-chip-remove-action"),onClick:w},l.createElement(n.IconWrap,{name:m?n.toIconName(m):void 0,icon:h||r.xCircleIcon,size:"small"}))))})),Z={id:s.string,text:s.string,value:s.any,dir:s.oneOf(["ltr","rtl"]),removable:s.bool,removeIcon:s.string,removeIconSvg:n.svgIconPropType,disabled:s.bool,icon:s.string,svgIcon:n.svgIconPropType,selectedIcon:s.string,selectedIconSvg:n.svgIconPropType,onRemove:s.func,dataItem:s.any,selected:s.bool,ariaDescribedBy:s.string,size:s.oneOf([null,"small","medium","large"]),rounded:s.oneOf([null,"small","medium","large","full"]),fillMode:s.oneOf([null,"outline","solid"]),themeColor:s.oneOf([null,"base","info","success","warning","error"])},_={disabled:!1,removable:!1,removeIcon:"k-i-x-circle",removeSvgIcon:r.xCircleIcon,dir:"ltr",size:"medium",rounded:"medium",fillMode:"solid",themeColor:"base"};G.displayName="KendoReactChip",G.propTypes=Z;const J=(e,t,s)=>{"multiple"===t.selection?Array.isArray(e)||(e=e?[e]:null):"single"===t.selection&&Array.isArray(e)&&(e=e?e.join(""):null);const[n,o]=l.useState(e);return[n,e=>{const r=((e,t)=>{switch(t.selection){case"single":switch(t.type){case"toggle":if(!Array.isArray(e)||null===e)return t.payload===e?null:t.payload;throw new Error("State cannot be an array in single selection");case"remove":return t.payload===e?null:e;default:return e}case"multiple":switch(t.type){case"toggle":if(Array.isArray(e))return e.some((e=>e===t.payload))?e.filter((e=>e!==t.payload)):[...e,t.payload];if(null===e)return[t.payload];throw new Error("State cannot be non-array in multiple selection");case"remove":return Array.isArray(e)?e.some((e=>e===t.payload))?e.filter((e=>e!==t.payload)):[...e,t.payload]:e;default:return e}case"none":return null;default:return e}})(t.state||n,{...e,...t});s&&s(r,e.event),"none"!==t.selection&&o(r)}]},Q=l.forwardRef(((e,t)=>{const s=l.useRef(null),o=l.useRef(null),{id:r,style:a,tabIndex:i,className:c,ariaDescribedBy:d,ariaLabelledBy:u,ariaLabel:p,value:m,defaultData:h=Y.defaultData,chip:f=Y.chip,disabled:v=Y.disabled,size:b=Y.size,defaultValue:g=Y.defaultValue,selection:y=Y.selection,valueField:k=Y.valueField,textField:C=Y.textField,dir:I=Y.dir,onChange:x,onDataChange:E}=e,w=n.useDir(o,I),D=l.useMemo((()=>f||G),[f,G]);l.useImperativeHandle(s,(()=>({element:o.current,props:e}))),l.useImperativeHandle(t,(()=>s.current));const N=l.useCallback(((e,t)=>{x&&s.current&&x.call(void 0,{value:e,target:s.current,syntheticEvent:t})}),[x]),[B,S]=J(m||g,{selection:y,state:m},N),K=l.useCallback(((e,t)=>{E&&s.current&&E.call(void 0,{value:e,target:s.current,syntheticEvent:t})}),[E]),[R,O]=((e,t,s)=>{const[n,o]=l.useState(e);return[n,e=>{const r=((e,t)=>{switch(t.type){case"add":case"reorder":break;case"remove":return e.filter((e=>e[t.valueField]!==t.payload));default:return e}})(t.state||n,{...e,...t});s&&s(r,e.event),o(r)}]})(e.data||h,{state:e.data,valueField:k},K),M=l.useCallback(((e,t)=>(e.push(t[k]),e)),[k]),z=l.useMemo((()=>e.data||R),[e.data,R]),F=l.useMemo((()=>m||B),[m,B]),P=l.useMemo((()=>z.reduce(M,[])),[z,M]),A=l.useCallback((e=>n.getter(k)(e)),[k]),T=l.useCallback((e=>n.getter(C)(e)),[C]),[$,L]=(e=>{const[t,s]=l.useState(null);return[t,t=>{const n=((e,t)=>{const s=t.items.findIndex((t=>t===e));switch(t.type){case"next":return s===t.items.length-1?e:t.items[s+1];case"prev":return 0===s?e:t.items[s-1];case"current":return t.payload;case"reset":return null;default:return e}})(t.payload,{...t,...e});s(n)}]})({items:P}),j=n.useMouse(e,s);return l.createElement(W.Provider,{value:[F,S]},l.createElement(H.Provider,{value:[$,L]},l.createElement(U.Provider,{value:[z,O]},l.createElement("div",{ref:o,...j,role:v?void 0:"listbox",id:r,dir:w,style:a,tabIndex:n.getTabIndex(i,v,void 0),className:n.classNames("k-chip-list",{"k-rtl":"rtl"===w,"k-disabled":v,[`k-chip-list-${n.kendoThemeMaps.sizeMap[b]||b}`]:b},c),"aria-label":p,"aria-labelledby":u,"aria-describedby":d,"aria-orientation":"horizontal","aria-multiselectable":"multiple"===y},z.map(((e,t)=>l.createElement(D,{role:"option",dataItem:e,size:b,key:[A(e),t].join("-"),text:T(e),value:A(e),ariaLabel:e.ariaLabel,svgIcon:e.svgIcon||void 0})))))))})),X={id:s.string,className:s.string,tabIndex:s.number,data:s.any,defaultData:s.arrayOf(s.any),onDataChange:s.func,value:s.oneOfType([s.any,s.arrayOf(s.any)]),defaultValue:s.oneOfType([s.any,s.arrayOf(s.any)]),onChange:s.func,selection:s.oneOf(["single","none","multiple"]),textField:s.string,valueField:s.string,disabled:s.bool,dir:s.oneOf(["ltr","rtl"]),ariaLabelledBy:s.string,ariaDescribedBy:s.string,size:s.oneOf([null,"small","medium","large"])},Y={chip:G,size:"medium",disabled:!1,defaultValue:null,defaultData:[],dir:"ltr",selection:"none",textField:"text",valueField:"value",removable:"removable"};Q.displayName="KendoReactChipList",Q.propTypes=X;const ee=l.forwardRef(((e,t)=>{const{className:s,disabled:o,text:r,icon:a,style:i,id:c,focused:d,tabIndex:u,index:p,dataItem:m,item:h,svgIcon:f,onDown:v,onClick:b,...g}=e,y=l.useRef(null),k=l.useCallback((()=>{y.current&&y.current.focus()}),[]),C=l.useCallback((()=>({element:y.current,focus:k})),[k]);l.useImperativeHandle(t,C);const I=l.useCallback((e=>{b&&void 0!==p&&!o&&b(e,p)}),[b,p]),x=l.useMemo((()=>n.classNames("k-fab-item",{"k-focus":d,"k-disabled":o},s)),[s,o,d]),E=h;return l.createElement("li",{ref:y,id:c,className:x,style:i,role:"menuitem",tabIndex:n.getTabIndex(u,o),"aria-disabled":o,"aria-label":`${r||""} floatingactionbutton item`,onClick:I,onMouseDown:v,onPointerDown:v,...g},E?l.createElement(E,{itemIndex:p,item:m}):l.createElement(l.Fragment,null,r&&l.createElement("span",{className:"k-fab-item-text"},r),a||f?l.createElement(n.IconWrap,{className:"k-fab-item-icon",name:a,icon:f}):null))}));ee.propTypes={className:s.string,style:s.object,children:s.any,disabled:s.bool,focused:s.bool,index:s.number,icon:s.string,svgIcon:n.svgIconPropType,text:s.string,tabIndex:s.number,customProp:s.any},ee.displayName="KendoFloatingActionButtonItem";const te="16px",se=e=>"number"==typeof e?e+"px":e,ne=(e,t)=>{const s={horizontal:t?"right":"left",vertical:"bottom"};return"end"===e.horizontal&&(s.horizontal=t?"left":"right"),s},oe=(e,t)=>{const s={horizontal:t?"right":"left",vertical:"top"};return"end"===e.horizontal&&(s.horizontal=t?"left":"right"),s},re=(e,t)=>({rtl:{end:"k-text-left",start:"k-text-right"},ltr:{start:"k-text-left",end:"k-text-right"}}[e]["end"===t?"end":"start"]),ae=(e,t,s,n)=>{const o=t.horizontal,r=t.vertical;if(e.current){const a=s&&void 0!==s.x?se(s.x):te,i=s&&void 0!==s.x?`calc(50% + ${se(s.x)})`:"50%",l=s&&void 0!==s.y?se(s.y):te,c=s&&void 0!==s.y?`calc(50% + ${se(s.y)})`:"50%";e.current.style.setProperty(ie(t,n),"center"===o?i:a),e.current.style.setProperty(le(t),"middle"===r?c:l),n&&(("top"===r||"bottom"===r)&&"start"===o&&e.current.style.setProperty("left","unset"),"middle"===r&&"end"===o&&e.current.style.setProperty("right","unset"),"middle"===r&&"start"===o&&e.current.style.setProperty("left","unset"))}},ie=(e,t)=>{const{horizontal:s}=e;return{end:t?"left":"right",center:"left",start:t?"right":"left"}[s||"end"]},le=e=>({top:"top",middle:"top",bottom:"bottom"}[e.vertical||"bottom"]),ce=l.forwardRef(((e,t)=>{const{align:s=de.align,alignOffset:r,className:a,disabled:i,icon:c,svgIcon:d,iconClass:u,id:p,items:m,item:h,text:f,positionMode:v=de.positionMode,size:b=de.size,style:g,rounded:y=de.rounded,themeColor:k=de.themeColor,overlayStyle:C,tabIndex:I,accessKey:x,popupSettings:E={},modal:w,onClick:D,onItemClick:N,onFocus:B,onBlur:S,onKeyDown:K,onOpen:R,onClose:O,...M}=e,z=n.useZIndexContext(),F=z?z+2:100,P=l.useRef(null),A=l.useRef(null),T=l.useRef(null),$=l.useRef(null),L=l.useCallback((()=>{A.current&&A.current.focus()}),[]),W=l.useCallback((()=>({element:A.current,focus:L})),[L]);l.useImperativeHandle(P,W),l.useImperativeHandle(t,(()=>P.current));const[H,U]=l.useState(!1),[j,q]=l.useState(!1),[V,G]=l.useState(-1),Z=n.useId()+"-button-id",_=n.useDir(A,e.dir),J="rtl"===_,Q=n.useId()+"-list-id";l.useEffect((()=>{ae(A,s,r,J)}),[A,s,r,J]),l.useEffect((()=>{j&&A&&A.current&&A.current.focus()}),[j,A]);const X=l.useCallback(((e,t)=>{m&&n.dispatchEvent(t?R:O,e,W(),void 0)}),[R,O,m]),Y=l.useCallback((e=>{!e.target||i||(!m&&D?n.dispatchEvent(D,e,W(),void 0):(U(!H),q(!0),G(H?-1:0),X(e,!H)))}),[U,q,G,D,X,H,m,i]),te=l.useCallback((e=>{q(!0),G(H?0:-1),B&&n.dispatchEvent(B,e,W(),void 0)}),[B,q,G]),se=l.useCallback((e=>{q(!1),U(!1),G(-1),n.dispatchEvent(S,e,W(),void 0),H&&X(e,!1)}),[S,q,U,G,X]),ie=l.useCallback((e=>{e.preventDefault()}),[]),le=l.useCallback(((e,t)=>{m&&(m[t].disabled||n.dispatchEvent(N,e,W(),{itemProps:m[t],itemIndex:t}))}),[N]),ce=l.useCallback(((e,t)=>{!e.target||!m||(G(t),U(!1),le(e,t),X(e,!1))}),[G,U,le,X]),ue=l.useCallback((e=>{n.getActiveElement(document)===A.current&&e.preventDefault()}),[A]),pe=l.useCallback((e=>{const t=V,s=m?m.length:-1;if(e.altKey)return!H&&e.keyCode===n.Keys.down&&(e.preventDefault(),U(!0),G(0)),void(H&&e.keyCode===n.Keys.up&&(e.preventDefault(),U(!1),G(-1)));switch(e.keyCode){case n.Keys.enter:case n.Keys.space:t>=0&&le(e,t),m||Y(e),e.preventDefault(),U(!H),G(H?-1:0);break;case n.Keys.esc:e.preventDefault(),U(!1),G(-1);break;case n.Keys.home:e.preventDefault(),G(0);break;case n.Keys.end:e.preventDefault(),G(s-1);break;case n.Keys.down:case n.Keys.right:e.preventDefault(),G(t+1>=s?0:t+1);break;case n.Keys.up:case n.Keys.left:e.preventDefault(),G(t-1<0?s-1:t-1)}n.dispatchEvent(K,e,W(),void 0)}),[K,V,G,J,U]),me=l.useMemo((()=>n.classNames("k-fab k-fab-solid",{"k-fab-sm":"small"===b,"k-fab-md":"medium"===b,"k-fab-lg":"large"===b,"k-disabled":i,"k-pos-absolute":"absolute"===v,"k-pos-fixed":"fixed"===v,"k-focus":j,[`k-rounded-${n.kendoThemeMaps.roundedMap[y]||y}`]:y,[`k-fab-solid-${k}`]:k},`k-${s.vertical}-${s.horizontal}`,a)),[k,b,y,i,v,s,j,a]),he=m&&m.map(((e,t)=>l.createElement(ee,{...e,key:t,index:t,id:`${Q}-${t}`,disabled:i||e.disabled,focused:V===t,dataItem:e,item:h,className:n.classNames(e.className,re(_||"ltr",s.horizontal)),onClick:ce,onDown:ue}))),fe=!(!c&&!d||f),ve=(A.current?A.current.offsetWidth:0)/2-16;return l.createElement(n.ZIndexContext.Provider,{value:F},l.createElement(l.Fragment,null,l.createElement("button",{ref:A,id:p||Z,role:"button",type:"button","aria-disabled":i,"aria-expanded":m?H:void 0,"aria-haspopup":!!m,"aria-label":`${f||""} floatingactionbutton`,"aria-owns":m?Q:void 0,"aria-activedescendant":V>=0&&m?`${Q}-${V}`:void 0,tabIndex:n.getTabIndex(I,i),accessKey:x,dir:_,disabled:i,className:me,style:g,onClick:Y,onMouseDown:ie,onFocus:te,onBlur:se,onKeyDown:pe,...M},c||d?l.createElement(n.IconWrap,{className:"k-fab-icon",name:c,icon:d}):u?l.createElement("span",{role:"presentation",className:u}):null,f&&l.createElement("span",{className:"k-fab-text"},f)),w&&H&&l.createElement("div",{className:"k-overlay",style:{zIndex:F,...C}}),l.createElement(o.Popup,{ref:$,anchor:A.current,show:H,animate:E.animate,popupClass:n.classNames("k-popup-transparent k-fab-popup",E.popupClass),anchorAlign:E.anchorAlign||ne(s,J),popupAlign:E.popupAlign||oe(s,J),style:{boxShadow:"none"}},l.createElement("ul",{ref:T,role:"menu","aria-labelledby":p,id:Q,className:n.classNames("k-fab-items",{"k-fab-items-bottom":"bottom"!==s.vertical,"k-fab-items-top":"bottom"===s.vertical}),style:{paddingLeft:fe?ve:void 0,paddingRight:fe?ve:void 0}},he))))}));ce.propTypes={className:s.string,style:s.object,id:s.string,dir:s.string,tabIndex:s.number,accessKey:s.string,disabled:s.bool,icon:s.string,svgIcon:n.svgIconPropType,iconClass:s.string,text:s.string,alignOffset:s.shape({x:s.oneOfType([s.number,s.string]).isRequired,y:s.oneOfType([s.number,s.string]).isRequired}),align:s.shape({vertical:s.oneOf(["top","middle","bottom"]).isRequired,horizontal:s.oneOf(["start","center","end"]).isRequired}),positionMode:s.oneOf(["absolute","fixed"]),size:s.oneOf([null,"small","medium","large"]),rounded:s.oneOf([null,"small","medium","large","full"]),themeColor:s.oneOf([null,"primary","secondary","tertiary","info","success","warning","error","dark","light","inverse"]),modal:s.bool,overlayStyle:s.object};const de={align:{vertical:"bottom",horizontal:"end"},size:"medium",rounded:"full",themeColor:"primary",positionMode:"fixed"};ce.displayName="KendoFloatingActionButton";const ue=n.withIdHOC(D);ue.displayName="KendoReactDropDownButton";const pe=n.withIdHOC(k);pe.displayName="KendoReactSplitButton",e.Button=c,e.ButtonGroup=u,e.Chip=G,e.ChipList=Q,e.DropDownButton=ue,e.DropDownButtonClassComponent=D,e.DropDownButtonItem=I,e.FloatingActionButton=ce,e.FloatingActionButtonItem=ee,e.SplitButton=pe,e.SplitButtonClassComponent=k,e.SplitButtonItem=h,e.Toolbar=A,e.ToolbarItem=$,e.ToolbarSeparator=S,e.ToolbarSpacer=L,e.toolbarButtons=B}));
|
package/index.d.mts
CHANGED
|
@@ -753,6 +753,9 @@ export declare const DropDownButton: ForwardRefExoticComponent<DropDownButtonPro
|
|
|
753
753
|
export declare interface DropDownButtonBlurEvent extends BaseEvent<DropDownButtonClassComponent> {
|
|
754
754
|
}
|
|
755
755
|
|
|
756
|
+
/** @hidden */
|
|
757
|
+
export declare type DropDownButtonClassComponent = DropDownButtonHandle;
|
|
758
|
+
|
|
756
759
|
/**
|
|
757
760
|
* Represents the [KendoReact DropDownButton component]({% slug overview_dropdownbutton %}).
|
|
758
761
|
*
|
|
@@ -770,95 +773,7 @@ export declare interface DropDownButtonBlurEvent extends BaseEvent<DropDownButto
|
|
|
770
773
|
* ReactDOM.render(<App />, document.querySelector('my-app'));
|
|
771
774
|
* ```
|
|
772
775
|
*/
|
|
773
|
-
export declare
|
|
774
|
-
/**
|
|
775
|
-
* @hidden
|
|
776
|
-
*/
|
|
777
|
-
static propTypes: {
|
|
778
|
-
accessKey: default_2.Requireable<string>;
|
|
779
|
-
ariaLabel: default_2.Requireable<string>;
|
|
780
|
-
title: default_2.Requireable<string>;
|
|
781
|
-
onFocus: default_2.Requireable<(...args: any[]) => any>;
|
|
782
|
-
onBlur: default_2.Requireable<(...args: any[]) => any>;
|
|
783
|
-
onItemClick: default_2.Requireable<(...args: any[]) => any>;
|
|
784
|
-
onOpen: default_2.Requireable<(...args: any[]) => any>;
|
|
785
|
-
onClose: default_2.Requireable<(...args: any[]) => any>;
|
|
786
|
-
items: default_2.Requireable<any[]>;
|
|
787
|
-
textField: default_2.Requireable<string>;
|
|
788
|
-
tabIndex: default_2.Requireable<number>;
|
|
789
|
-
disabled: default_2.Requireable<boolean>;
|
|
790
|
-
icon: default_2.Requireable<string>;
|
|
791
|
-
svgIcon: default_2.Requireable<default_2.InferProps<{
|
|
792
|
-
name: default_2.Validator<string>;
|
|
793
|
-
content: default_2.Validator<string>;
|
|
794
|
-
viewBox: default_2.Validator<string>;
|
|
795
|
-
}>>;
|
|
796
|
-
iconClass: default_2.Requireable<string>;
|
|
797
|
-
imageUrl: default_2.Requireable<string>;
|
|
798
|
-
popupSettings: default_2.Requireable<object>;
|
|
799
|
-
itemRender: default_2.Requireable<(...args: any[]) => any>;
|
|
800
|
-
item: default_2.Requireable<(...args: any[]) => any>;
|
|
801
|
-
className: default_2.Requireable<string>;
|
|
802
|
-
buttonClass: default_2.Requireable<string>;
|
|
803
|
-
dir: default_2.Requireable<string>;
|
|
804
|
-
};
|
|
805
|
-
/**
|
|
806
|
-
* @hidden
|
|
807
|
-
*/
|
|
808
|
-
static defaultProps: {
|
|
809
|
-
size: string;
|
|
810
|
-
rounded: string;
|
|
811
|
-
fillMode: string;
|
|
812
|
-
themeColor: string;
|
|
813
|
-
};
|
|
814
|
-
/**
|
|
815
|
-
* @hidden
|
|
816
|
-
*/
|
|
817
|
-
readonly state: {
|
|
818
|
-
opened: boolean;
|
|
819
|
-
focused: boolean;
|
|
820
|
-
focusedIndex: number;
|
|
821
|
-
};
|
|
822
|
-
private mainButton;
|
|
823
|
-
private list;
|
|
824
|
-
private skipFocus;
|
|
825
|
-
private get guid();
|
|
826
|
-
private readonly showLicenseWatermark;
|
|
827
|
-
private buttonsData;
|
|
828
|
-
private openedDuringOnChange?;
|
|
829
|
-
private get opened();
|
|
830
|
-
constructor(props: DropDownButtonProps);
|
|
831
|
-
/**
|
|
832
|
-
* @hidden
|
|
833
|
-
*/
|
|
834
|
-
render(): JSX_2.Element;
|
|
835
|
-
/**
|
|
836
|
-
* @hidden
|
|
837
|
-
*/
|
|
838
|
-
componentDidMount(): void;
|
|
839
|
-
/**
|
|
840
|
-
* The DOM element of main button.
|
|
841
|
-
*/
|
|
842
|
-
get element(): HTMLButtonElement | null;
|
|
843
|
-
private onKeyDown;
|
|
844
|
-
private switchFocus;
|
|
845
|
-
private handleFocus;
|
|
846
|
-
private handleButtonBlur;
|
|
847
|
-
private handleMenuBlur;
|
|
848
|
-
private setOpen;
|
|
849
|
-
private onItemClick;
|
|
850
|
-
private onItemDown;
|
|
851
|
-
private mouseDown;
|
|
852
|
-
private dispatchClickEvent;
|
|
853
|
-
private renderPopup;
|
|
854
|
-
private onPopupClose;
|
|
855
|
-
private listRef;
|
|
856
|
-
private renderChildItems;
|
|
857
|
-
private onClickMainButton;
|
|
858
|
-
private dispatchPopupEvent;
|
|
859
|
-
private isItemDisabled;
|
|
860
|
-
private isRtl;
|
|
861
|
-
}
|
|
776
|
+
export declare const DropDownButtonClassComponent: React_2.ForwardRefExoticComponent<DropDownButtonProps & React_2.RefAttributes<any>>;
|
|
862
777
|
|
|
863
778
|
export declare interface DropDownButtonCloseEvent extends BaseEvent<DropDownButtonClassComponent> {
|
|
864
779
|
}
|
|
@@ -869,7 +784,15 @@ export declare interface DropDownButtonFocusEvent extends BaseEvent<DropDownButt
|
|
|
869
784
|
/**
|
|
870
785
|
* Represent the `ref` of the DropDownButton component.
|
|
871
786
|
*/
|
|
872
|
-
export declare interface DropDownButtonHandle extends Pick<
|
|
787
|
+
export declare interface DropDownButtonHandle extends Pick<DropDownButtonWithoutContext, keyof DropDownButtonWithoutContext> {
|
|
788
|
+
/**
|
|
789
|
+
* The DOM element of main button.
|
|
790
|
+
*/
|
|
791
|
+
element: HTMLButtonElement | null;
|
|
792
|
+
/**
|
|
793
|
+
* The props of the DropDownButtonHandle component.
|
|
794
|
+
*/
|
|
795
|
+
props: Readonly<DropDownButtonProps>;
|
|
873
796
|
}
|
|
874
797
|
|
|
875
798
|
export declare class DropDownButtonItem extends React_2.Component<DropDownButtonItemProps, {}> {
|
|
@@ -976,6 +899,15 @@ export declare interface DropDownButtonProps extends KendoReactComponentBaseProp
|
|
|
976
899
|
* ([see example]({% slug customization_dropdownbutton %}#toc-popup-behavior)).
|
|
977
900
|
*/
|
|
978
901
|
popupSettings?: ButtonsPopupSettings;
|
|
902
|
+
/**
|
|
903
|
+
* @hidden
|
|
904
|
+
*/
|
|
905
|
+
unstyled?: ButtonsClassStructure;
|
|
906
|
+
/**
|
|
907
|
+
* @hidden
|
|
908
|
+
* This prop is provided by the withZIndexContext HOC to subscribe to ZIndexContext.
|
|
909
|
+
*/
|
|
910
|
+
_zIndex?: number;
|
|
979
911
|
/**
|
|
980
912
|
* A React functional or class component which is used for rendering items ([see example]({% slug customization_dropdownbutton %}#toc-items-rendering)). The default rendering includes an icon, an image, and text.
|
|
981
913
|
*/
|
|
@@ -1102,6 +1034,99 @@ declare interface DropDownButtonState {
|
|
|
1102
1034
|
opened: boolean;
|
|
1103
1035
|
}
|
|
1104
1036
|
|
|
1037
|
+
/**
|
|
1038
|
+
* @hidden
|
|
1039
|
+
*/
|
|
1040
|
+
declare class DropDownButtonWithoutContext extends React_2.Component<DropDownButtonProps, DropDownButtonState> {
|
|
1041
|
+
/**
|
|
1042
|
+
* @hidden
|
|
1043
|
+
*/
|
|
1044
|
+
static propTypes: {
|
|
1045
|
+
accessKey: default_2.Requireable<string>;
|
|
1046
|
+
ariaLabel: default_2.Requireable<string>;
|
|
1047
|
+
title: default_2.Requireable<string>;
|
|
1048
|
+
onFocus: default_2.Requireable<(...args: any[]) => any>;
|
|
1049
|
+
onBlur: default_2.Requireable<(...args: any[]) => any>;
|
|
1050
|
+
onItemClick: default_2.Requireable<(...args: any[]) => any>;
|
|
1051
|
+
onOpen: default_2.Requireable<(...args: any[]) => any>;
|
|
1052
|
+
onClose: default_2.Requireable<(...args: any[]) => any>;
|
|
1053
|
+
items: default_2.Requireable<any[]>;
|
|
1054
|
+
textField: default_2.Requireable<string>;
|
|
1055
|
+
tabIndex: default_2.Requireable<number>;
|
|
1056
|
+
disabled: default_2.Requireable<boolean>;
|
|
1057
|
+
icon: default_2.Requireable<string>;
|
|
1058
|
+
svgIcon: default_2.Requireable<default_2.InferProps<{
|
|
1059
|
+
name: default_2.Validator<string>;
|
|
1060
|
+
content: default_2.Validator<string>;
|
|
1061
|
+
viewBox: default_2.Validator<string>;
|
|
1062
|
+
}>>;
|
|
1063
|
+
iconClass: default_2.Requireable<string>;
|
|
1064
|
+
imageUrl: default_2.Requireable<string>;
|
|
1065
|
+
popupSettings: default_2.Requireable<object>;
|
|
1066
|
+
itemRender: default_2.Requireable<(...args: any[]) => any>;
|
|
1067
|
+
item: default_2.Requireable<(...args: any[]) => any>;
|
|
1068
|
+
className: default_2.Requireable<string>;
|
|
1069
|
+
buttonClass: default_2.Requireable<string>;
|
|
1070
|
+
dir: default_2.Requireable<string>;
|
|
1071
|
+
};
|
|
1072
|
+
/**
|
|
1073
|
+
* @hidden
|
|
1074
|
+
*/
|
|
1075
|
+
static defaultProps: {
|
|
1076
|
+
size: string;
|
|
1077
|
+
rounded: string;
|
|
1078
|
+
fillMode: string;
|
|
1079
|
+
themeColor: string;
|
|
1080
|
+
};
|
|
1081
|
+
/**
|
|
1082
|
+
* @hidden
|
|
1083
|
+
*/
|
|
1084
|
+
readonly state: {
|
|
1085
|
+
opened: boolean;
|
|
1086
|
+
focused: boolean;
|
|
1087
|
+
focusedIndex: number;
|
|
1088
|
+
};
|
|
1089
|
+
private mainButton;
|
|
1090
|
+
private list;
|
|
1091
|
+
private skipFocus;
|
|
1092
|
+
private get guid();
|
|
1093
|
+
private readonly showLicenseWatermark;
|
|
1094
|
+
private buttonsData;
|
|
1095
|
+
private openedDuringOnChange?;
|
|
1096
|
+
private get opened();
|
|
1097
|
+
constructor(props: DropDownButtonProps);
|
|
1098
|
+
/**
|
|
1099
|
+
* @hidden
|
|
1100
|
+
*/
|
|
1101
|
+
render(): JSX_2.Element;
|
|
1102
|
+
/**
|
|
1103
|
+
* @hidden
|
|
1104
|
+
*/
|
|
1105
|
+
componentDidMount(): void;
|
|
1106
|
+
/**
|
|
1107
|
+
* The DOM element of main button.
|
|
1108
|
+
*/
|
|
1109
|
+
get element(): HTMLButtonElement | null;
|
|
1110
|
+
private onKeyDown;
|
|
1111
|
+
private switchFocus;
|
|
1112
|
+
private handleFocus;
|
|
1113
|
+
private handleButtonBlur;
|
|
1114
|
+
private handleMenuBlur;
|
|
1115
|
+
private setOpen;
|
|
1116
|
+
private onItemClick;
|
|
1117
|
+
private onItemDown;
|
|
1118
|
+
private mouseDown;
|
|
1119
|
+
private dispatchClickEvent;
|
|
1120
|
+
private renderPopup;
|
|
1121
|
+
private onPopupClose;
|
|
1122
|
+
private listRef;
|
|
1123
|
+
private renderChildItems;
|
|
1124
|
+
private onClickMainButton;
|
|
1125
|
+
private dispatchPopupEvent;
|
|
1126
|
+
private isItemDisabled;
|
|
1127
|
+
private isRtl;
|
|
1128
|
+
}
|
|
1129
|
+
|
|
1105
1130
|
/**
|
|
1106
1131
|
* Represents the [KendoReact FloatingActionButton component]({% slug overview_floatingactionbutton %}).
|
|
1107
1132
|
*
|
package/index.d.ts
CHANGED
|
@@ -753,6 +753,9 @@ export declare const DropDownButton: ForwardRefExoticComponent<DropDownButtonPro
|
|
|
753
753
|
export declare interface DropDownButtonBlurEvent extends BaseEvent<DropDownButtonClassComponent> {
|
|
754
754
|
}
|
|
755
755
|
|
|
756
|
+
/** @hidden */
|
|
757
|
+
export declare type DropDownButtonClassComponent = DropDownButtonHandle;
|
|
758
|
+
|
|
756
759
|
/**
|
|
757
760
|
* Represents the [KendoReact DropDownButton component]({% slug overview_dropdownbutton %}).
|
|
758
761
|
*
|
|
@@ -770,95 +773,7 @@ export declare interface DropDownButtonBlurEvent extends BaseEvent<DropDownButto
|
|
|
770
773
|
* ReactDOM.render(<App />, document.querySelector('my-app'));
|
|
771
774
|
* ```
|
|
772
775
|
*/
|
|
773
|
-
export declare
|
|
774
|
-
/**
|
|
775
|
-
* @hidden
|
|
776
|
-
*/
|
|
777
|
-
static propTypes: {
|
|
778
|
-
accessKey: default_2.Requireable<string>;
|
|
779
|
-
ariaLabel: default_2.Requireable<string>;
|
|
780
|
-
title: default_2.Requireable<string>;
|
|
781
|
-
onFocus: default_2.Requireable<(...args: any[]) => any>;
|
|
782
|
-
onBlur: default_2.Requireable<(...args: any[]) => any>;
|
|
783
|
-
onItemClick: default_2.Requireable<(...args: any[]) => any>;
|
|
784
|
-
onOpen: default_2.Requireable<(...args: any[]) => any>;
|
|
785
|
-
onClose: default_2.Requireable<(...args: any[]) => any>;
|
|
786
|
-
items: default_2.Requireable<any[]>;
|
|
787
|
-
textField: default_2.Requireable<string>;
|
|
788
|
-
tabIndex: default_2.Requireable<number>;
|
|
789
|
-
disabled: default_2.Requireable<boolean>;
|
|
790
|
-
icon: default_2.Requireable<string>;
|
|
791
|
-
svgIcon: default_2.Requireable<default_2.InferProps<{
|
|
792
|
-
name: default_2.Validator<string>;
|
|
793
|
-
content: default_2.Validator<string>;
|
|
794
|
-
viewBox: default_2.Validator<string>;
|
|
795
|
-
}>>;
|
|
796
|
-
iconClass: default_2.Requireable<string>;
|
|
797
|
-
imageUrl: default_2.Requireable<string>;
|
|
798
|
-
popupSettings: default_2.Requireable<object>;
|
|
799
|
-
itemRender: default_2.Requireable<(...args: any[]) => any>;
|
|
800
|
-
item: default_2.Requireable<(...args: any[]) => any>;
|
|
801
|
-
className: default_2.Requireable<string>;
|
|
802
|
-
buttonClass: default_2.Requireable<string>;
|
|
803
|
-
dir: default_2.Requireable<string>;
|
|
804
|
-
};
|
|
805
|
-
/**
|
|
806
|
-
* @hidden
|
|
807
|
-
*/
|
|
808
|
-
static defaultProps: {
|
|
809
|
-
size: string;
|
|
810
|
-
rounded: string;
|
|
811
|
-
fillMode: string;
|
|
812
|
-
themeColor: string;
|
|
813
|
-
};
|
|
814
|
-
/**
|
|
815
|
-
* @hidden
|
|
816
|
-
*/
|
|
817
|
-
readonly state: {
|
|
818
|
-
opened: boolean;
|
|
819
|
-
focused: boolean;
|
|
820
|
-
focusedIndex: number;
|
|
821
|
-
};
|
|
822
|
-
private mainButton;
|
|
823
|
-
private list;
|
|
824
|
-
private skipFocus;
|
|
825
|
-
private get guid();
|
|
826
|
-
private readonly showLicenseWatermark;
|
|
827
|
-
private buttonsData;
|
|
828
|
-
private openedDuringOnChange?;
|
|
829
|
-
private get opened();
|
|
830
|
-
constructor(props: DropDownButtonProps);
|
|
831
|
-
/**
|
|
832
|
-
* @hidden
|
|
833
|
-
*/
|
|
834
|
-
render(): JSX_2.Element;
|
|
835
|
-
/**
|
|
836
|
-
* @hidden
|
|
837
|
-
*/
|
|
838
|
-
componentDidMount(): void;
|
|
839
|
-
/**
|
|
840
|
-
* The DOM element of main button.
|
|
841
|
-
*/
|
|
842
|
-
get element(): HTMLButtonElement | null;
|
|
843
|
-
private onKeyDown;
|
|
844
|
-
private switchFocus;
|
|
845
|
-
private handleFocus;
|
|
846
|
-
private handleButtonBlur;
|
|
847
|
-
private handleMenuBlur;
|
|
848
|
-
private setOpen;
|
|
849
|
-
private onItemClick;
|
|
850
|
-
private onItemDown;
|
|
851
|
-
private mouseDown;
|
|
852
|
-
private dispatchClickEvent;
|
|
853
|
-
private renderPopup;
|
|
854
|
-
private onPopupClose;
|
|
855
|
-
private listRef;
|
|
856
|
-
private renderChildItems;
|
|
857
|
-
private onClickMainButton;
|
|
858
|
-
private dispatchPopupEvent;
|
|
859
|
-
private isItemDisabled;
|
|
860
|
-
private isRtl;
|
|
861
|
-
}
|
|
776
|
+
export declare const DropDownButtonClassComponent: React_2.ForwardRefExoticComponent<DropDownButtonProps & React_2.RefAttributes<any>>;
|
|
862
777
|
|
|
863
778
|
export declare interface DropDownButtonCloseEvent extends BaseEvent<DropDownButtonClassComponent> {
|
|
864
779
|
}
|
|
@@ -869,7 +784,15 @@ export declare interface DropDownButtonFocusEvent extends BaseEvent<DropDownButt
|
|
|
869
784
|
/**
|
|
870
785
|
* Represent the `ref` of the DropDownButton component.
|
|
871
786
|
*/
|
|
872
|
-
export declare interface DropDownButtonHandle extends Pick<
|
|
787
|
+
export declare interface DropDownButtonHandle extends Pick<DropDownButtonWithoutContext, keyof DropDownButtonWithoutContext> {
|
|
788
|
+
/**
|
|
789
|
+
* The DOM element of main button.
|
|
790
|
+
*/
|
|
791
|
+
element: HTMLButtonElement | null;
|
|
792
|
+
/**
|
|
793
|
+
* The props of the DropDownButtonHandle component.
|
|
794
|
+
*/
|
|
795
|
+
props: Readonly<DropDownButtonProps>;
|
|
873
796
|
}
|
|
874
797
|
|
|
875
798
|
export declare class DropDownButtonItem extends React_2.Component<DropDownButtonItemProps, {}> {
|
|
@@ -976,6 +899,15 @@ export declare interface DropDownButtonProps extends KendoReactComponentBaseProp
|
|
|
976
899
|
* ([see example]({% slug customization_dropdownbutton %}#toc-popup-behavior)).
|
|
977
900
|
*/
|
|
978
901
|
popupSettings?: ButtonsPopupSettings;
|
|
902
|
+
/**
|
|
903
|
+
* @hidden
|
|
904
|
+
*/
|
|
905
|
+
unstyled?: ButtonsClassStructure;
|
|
906
|
+
/**
|
|
907
|
+
* @hidden
|
|
908
|
+
* This prop is provided by the withZIndexContext HOC to subscribe to ZIndexContext.
|
|
909
|
+
*/
|
|
910
|
+
_zIndex?: number;
|
|
979
911
|
/**
|
|
980
912
|
* A React functional or class component which is used for rendering items ([see example]({% slug customization_dropdownbutton %}#toc-items-rendering)). The default rendering includes an icon, an image, and text.
|
|
981
913
|
*/
|
|
@@ -1102,6 +1034,99 @@ declare interface DropDownButtonState {
|
|
|
1102
1034
|
opened: boolean;
|
|
1103
1035
|
}
|
|
1104
1036
|
|
|
1037
|
+
/**
|
|
1038
|
+
* @hidden
|
|
1039
|
+
*/
|
|
1040
|
+
declare class DropDownButtonWithoutContext extends React_2.Component<DropDownButtonProps, DropDownButtonState> {
|
|
1041
|
+
/**
|
|
1042
|
+
* @hidden
|
|
1043
|
+
*/
|
|
1044
|
+
static propTypes: {
|
|
1045
|
+
accessKey: default_2.Requireable<string>;
|
|
1046
|
+
ariaLabel: default_2.Requireable<string>;
|
|
1047
|
+
title: default_2.Requireable<string>;
|
|
1048
|
+
onFocus: default_2.Requireable<(...args: any[]) => any>;
|
|
1049
|
+
onBlur: default_2.Requireable<(...args: any[]) => any>;
|
|
1050
|
+
onItemClick: default_2.Requireable<(...args: any[]) => any>;
|
|
1051
|
+
onOpen: default_2.Requireable<(...args: any[]) => any>;
|
|
1052
|
+
onClose: default_2.Requireable<(...args: any[]) => any>;
|
|
1053
|
+
items: default_2.Requireable<any[]>;
|
|
1054
|
+
textField: default_2.Requireable<string>;
|
|
1055
|
+
tabIndex: default_2.Requireable<number>;
|
|
1056
|
+
disabled: default_2.Requireable<boolean>;
|
|
1057
|
+
icon: default_2.Requireable<string>;
|
|
1058
|
+
svgIcon: default_2.Requireable<default_2.InferProps<{
|
|
1059
|
+
name: default_2.Validator<string>;
|
|
1060
|
+
content: default_2.Validator<string>;
|
|
1061
|
+
viewBox: default_2.Validator<string>;
|
|
1062
|
+
}>>;
|
|
1063
|
+
iconClass: default_2.Requireable<string>;
|
|
1064
|
+
imageUrl: default_2.Requireable<string>;
|
|
1065
|
+
popupSettings: default_2.Requireable<object>;
|
|
1066
|
+
itemRender: default_2.Requireable<(...args: any[]) => any>;
|
|
1067
|
+
item: default_2.Requireable<(...args: any[]) => any>;
|
|
1068
|
+
className: default_2.Requireable<string>;
|
|
1069
|
+
buttonClass: default_2.Requireable<string>;
|
|
1070
|
+
dir: default_2.Requireable<string>;
|
|
1071
|
+
};
|
|
1072
|
+
/**
|
|
1073
|
+
* @hidden
|
|
1074
|
+
*/
|
|
1075
|
+
static defaultProps: {
|
|
1076
|
+
size: string;
|
|
1077
|
+
rounded: string;
|
|
1078
|
+
fillMode: string;
|
|
1079
|
+
themeColor: string;
|
|
1080
|
+
};
|
|
1081
|
+
/**
|
|
1082
|
+
* @hidden
|
|
1083
|
+
*/
|
|
1084
|
+
readonly state: {
|
|
1085
|
+
opened: boolean;
|
|
1086
|
+
focused: boolean;
|
|
1087
|
+
focusedIndex: number;
|
|
1088
|
+
};
|
|
1089
|
+
private mainButton;
|
|
1090
|
+
private list;
|
|
1091
|
+
private skipFocus;
|
|
1092
|
+
private get guid();
|
|
1093
|
+
private readonly showLicenseWatermark;
|
|
1094
|
+
private buttonsData;
|
|
1095
|
+
private openedDuringOnChange?;
|
|
1096
|
+
private get opened();
|
|
1097
|
+
constructor(props: DropDownButtonProps);
|
|
1098
|
+
/**
|
|
1099
|
+
* @hidden
|
|
1100
|
+
*/
|
|
1101
|
+
render(): JSX_2.Element;
|
|
1102
|
+
/**
|
|
1103
|
+
* @hidden
|
|
1104
|
+
*/
|
|
1105
|
+
componentDidMount(): void;
|
|
1106
|
+
/**
|
|
1107
|
+
* The DOM element of main button.
|
|
1108
|
+
*/
|
|
1109
|
+
get element(): HTMLButtonElement | null;
|
|
1110
|
+
private onKeyDown;
|
|
1111
|
+
private switchFocus;
|
|
1112
|
+
private handleFocus;
|
|
1113
|
+
private handleButtonBlur;
|
|
1114
|
+
private handleMenuBlur;
|
|
1115
|
+
private setOpen;
|
|
1116
|
+
private onItemClick;
|
|
1117
|
+
private onItemDown;
|
|
1118
|
+
private mouseDown;
|
|
1119
|
+
private dispatchClickEvent;
|
|
1120
|
+
private renderPopup;
|
|
1121
|
+
private onPopupClose;
|
|
1122
|
+
private listRef;
|
|
1123
|
+
private renderChildItems;
|
|
1124
|
+
private onClickMainButton;
|
|
1125
|
+
private dispatchPopupEvent;
|
|
1126
|
+
private isItemDisabled;
|
|
1127
|
+
private isRtl;
|
|
1128
|
+
}
|
|
1129
|
+
|
|
1105
1130
|
/**
|
|
1106
1131
|
* Represents the [KendoReact FloatingActionButton component]({% slug overview_floatingactionbutton %}).
|
|
1107
1132
|
*
|
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-buttons",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate:
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e={name:"@progress/kendo-react-buttons",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate: 1741875543,version:"10.1.0-develop.2",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"};exports.packageMetadata=e;
|
package/package-metadata.mjs
CHANGED
|
@@ -10,8 +10,8 @@ const e = {
|
|
|
10
10
|
productName: "KendoReact",
|
|
11
11
|
productCode: "KENDOUIREACT",
|
|
12
12
|
productCodes: ["KENDOUIREACT"],
|
|
13
|
-
publishDate:
|
|
14
|
-
version: "10.0.
|
|
13
|
+
publishDate: 1741875543,
|
|
14
|
+
version: "10.1.0-develop.2",
|
|
15
15
|
licensingDocsUrl: "https://www.telerik.com/kendo-react-ui/components/my-license/"
|
|
16
16
|
};
|
|
17
17
|
export {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@progress/kendo-react-buttons",
|
|
3
|
-
"version": "10.0.
|
|
3
|
+
"version": "10.1.0-develop.2",
|
|
4
4
|
"description": "All you need in React Button in one package: disabled/enabled states, built-in styles and more. KendoReact Buttons package",
|
|
5
5
|
"author": "Progress",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
"sideEffects": false,
|
|
27
27
|
"peerDependencies": {
|
|
28
28
|
"@progress/kendo-licensing": "^1.5.1",
|
|
29
|
-
"@progress/kendo-react-common": "10.0.
|
|
30
|
-
"@progress/kendo-react-popup": "10.0.
|
|
29
|
+
"@progress/kendo-react-common": "10.1.0-develop.2",
|
|
30
|
+
"@progress/kendo-react-popup": "10.1.0-develop.2",
|
|
31
31
|
"@progress/kendo-svg-icons": "^4.0.0",
|
|
32
32
|
"react": "^16.8.2 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc",
|
|
33
33
|
"react-dom": "^16.8.2 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc"
|
|
@@ -41,10 +41,19 @@
|
|
|
41
41
|
"Progress",
|
|
42
42
|
"Buttons",
|
|
43
43
|
"KendoReact",
|
|
44
|
+
"KendoReact Free",
|
|
44
45
|
"reactjs",
|
|
45
46
|
"UI",
|
|
46
47
|
"components",
|
|
47
48
|
"React component",
|
|
49
|
+
"free React component",
|
|
50
|
+
"button group",
|
|
51
|
+
"chip",
|
|
52
|
+
"chip list",
|
|
53
|
+
"dropdown button",
|
|
54
|
+
"floating action button",
|
|
55
|
+
"split button",
|
|
56
|
+
"toolbar",
|
|
48
57
|
"Telerik"
|
|
49
58
|
],
|
|
50
59
|
"@progress": {
|
|
@@ -53,7 +62,7 @@
|
|
|
53
62
|
"package": {
|
|
54
63
|
"productName": "KendoReact",
|
|
55
64
|
"productCode": "KENDOUIREACT",
|
|
56
|
-
"publishDate":
|
|
65
|
+
"publishDate": 1741875543,
|
|
57
66
|
"licensingDocsUrl": "https://www.telerik.com/kendo-react-ui/components/my-license/"
|
|
58
67
|
}
|
|
59
68
|
},
|