@progress/kendo-react-dropdowns 13.4.0-develop.3 → 13.4.0-develop.5

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.
@@ -7,101 +7,101 @@
7
7
  */
8
8
  import * as s from "react";
9
9
  import C from "prop-types";
10
- import { createPropsContext as Jt, getLicenseMessage as Qt, usePropsContext as Xt, validatePackage as Zt, useUnstyled as Rt, useId as en, canUseDOM as tt, useAdaptiveModeContext as tn, classNames as L, uDropDownList as P, getTabIndex as nn, IconWrap as rn, Keys as I, WatermarkOverlay as on, sizeMap as sn, svgIconPropType as an } from "@progress/kendo-react-common";
11
- import { FloatingLabel as ln } from "@progress/kendo-react-labels";
12
- import { caretAltDownIcon as dn } from "@progress/kendo-svg-icons";
13
- import cn from "../common/ListContainer.mjs";
14
- import un from "../common/ListFilter.mjs";
15
- import nt from "../common/GroupStickyHeader.mjs";
16
- import pn from "../common/ListDefaultItem.mjs";
17
- import mn from "../common/List.mjs";
18
- import dt from "../common/DropDownBase.mjs";
19
- import { getFilteredData as E, areSame as F, getItemValue as te, isPresent as rt, itemIndexStartsWith as fn, sameCharsOnly as gn, shuffleData as vn, matchText as ot } from "../common/utils.mjs";
20
- import { packageMetadata as it } from "../package-metadata.mjs";
21
- import { Button as In } from "@progress/kendo-react-buttons";
22
- import { useLocalization as hn } from "@progress/kendo-react-intl";
23
- import { dropDownListArrowBtnAriaLabel as st, messages as at, dropDownListAdaptiveFilterPlaceholder as lt } from "../messages/index.mjs";
24
- import { ActionSheetContent as yn } from "@progress/kendo-react-layout";
25
- import { AdaptiveMode as wn } from "../common/AdaptiveMode.mjs";
26
- const Dn = "Please select a value from the list!", Me = s.forwardRef((ct, ut) => {
10
+ import { createPropsContext as Xt, getLicenseMessage as Zt, usePropsContext as Rt, validatePackage as en, useUnstyled as tn, useId as nn, useKendoPaste as rn, canUseDOM as nt, useAdaptiveModeContext as on, classNames as L, uDropDownList as P, getTabIndex as sn, IconWrap as an, Keys as I, WatermarkOverlay as ln, sizeMap as dn, svgIconPropType as cn } from "@progress/kendo-react-common";
11
+ import { FloatingLabel as un } from "@progress/kendo-react-labels";
12
+ import { caretAltDownIcon as pn } from "@progress/kendo-svg-icons";
13
+ import mn from "../common/ListContainer.mjs";
14
+ import fn from "../common/ListFilter.mjs";
15
+ import rt from "../common/GroupStickyHeader.mjs";
16
+ import gn from "../common/ListDefaultItem.mjs";
17
+ import vn from "../common/List.mjs";
18
+ import ct from "../common/DropDownBase.mjs";
19
+ import { getFilteredData as E, getItemIndexByText as In, areSame as F, getItemValue as ne, isPresent as ot, itemIndexStartsWith as hn, sameCharsOnly as yn, shuffleData as wn, matchText as it } from "../common/utils.mjs";
20
+ import { packageMetadata as st } from "../package-metadata.mjs";
21
+ import { Button as xn } from "@progress/kendo-react-buttons";
22
+ import { useLocalization as Dn } from "@progress/kendo-react-intl";
23
+ import { dropDownListArrowBtnAriaLabel as at, messages as lt, dropDownListAdaptiveFilterPlaceholder as dt } from "../messages/index.mjs";
24
+ import { ActionSheetContent as Sn } from "@progress/kendo-react-layout";
25
+ import { AdaptiveMode as Cn } from "../common/AdaptiveMode.mjs";
26
+ const kn = "Please select a value from the list!", Me = s.forwardRef((ut, pt) => {
27
27
  let Ke = !1;
28
- const pt = Qt(it), n = Xt(xn, ct), {
29
- delay: mt = z.delay,
30
- tabIndex: ft = z.tabIndex,
31
- ignoreCase: pe = z.ignoreCase,
28
+ const mt = Zt(st), n = Rt(En, ut), {
29
+ delay: ft = z.delay,
30
+ tabIndex: gt = z.tabIndex,
31
+ ignoreCase: J = z.ignoreCase,
32
32
  size: O = z.size,
33
33
  rounded: Ne = z.rounded,
34
34
  fillMode: me = z.fillMode
35
35
  } = n;
36
36
  if (n.filterable || n.virtual) {
37
37
  const e = [];
38
- n.filterable && e.push("filterable"), n.virtual && e.push("virtualization"), Ke = !Zt(it, {
38
+ n.filterable && e.push("filterable"), n.virtual && e.push("virtualization"), Ke = !en(st, {
39
39
  component: "DropDownList",
40
40
  features: e
41
41
  });
42
42
  }
43
- const M = Rt(), fe = en(n.id), ge = () => {
43
+ const K = tn(), fe = nn(n.id), ge = () => {
44
44
  var e;
45
- if (tt)
46
- return ((e = J.current) == null ? void 0 : e.ownerDocument) || window.document;
47
- }, gt = () => {
45
+ if (nt)
46
+ return ((e = A.current) == null ? void 0 : e.ownerDocument) || window.document;
47
+ }, vt = () => {
48
48
  var e, r;
49
49
  (e = t == null ? void 0 : t.current) != null && e.wrapper && ((r = t == null ? void 0 : t.current) == null || r.wrapper.focus({ preventScroll: !0 }));
50
50
  }, k = () => {
51
51
  let e;
52
- return H.current !== void 0 && H.current !== null ? e = H.current : n.value !== void 0 ? e = n.value : p.value !== void 0 && p.value !== null ? e = p.value : n.defaultValue !== void 0 && n.defaultValue !== null && (e = n.defaultValue), !rt(e) && n.defaultItem !== void 0 && n.defaultItem !== null && (e = n.defaultItem), e;
53
- }, vt = () => {
52
+ return B.current !== void 0 && B.current !== null ? e = B.current : n.value !== void 0 ? e = n.value : m.value !== void 0 && m.value !== null ? e = m.value : n.defaultValue !== void 0 && n.defaultValue !== null && (e = n.defaultValue), !ot(e) && n.defaultItem !== void 0 && n.defaultItem !== null && (e = n.defaultItem), e;
53
+ }, It = () => {
54
54
  const { dataItemKey: e } = n, r = E(n), o = k();
55
- return r.findIndex((l) => F(l, o, e));
55
+ return r.findIndex((d) => F(d, o, e));
56
56
  }, ve = () => n.required !== void 0 ? n.required : z.required, Ie = () => {
57
- const e = n.validationMessage !== void 0, r = k(), o = !ve() || r !== null && r !== "" && r !== void 0, l = n.valid !== void 0 ? n.valid : o;
57
+ const e = n.validationMessage !== void 0, r = k(), o = !ve() || r !== null && r !== "" && r !== void 0, d = n.valid !== void 0 ? n.valid : o;
58
58
  return {
59
59
  customError: e,
60
- valid: l,
60
+ valid: d,
61
61
  valueMissing: r === null
62
62
  };
63
- }, It = () => n.validityStyles !== void 0 ? n.validityStyles : z.validityStyles, ne = (e) => {
64
- re.current = !0, e.focus(), window.setTimeout(() => re.current = !1, 30);
63
+ }, ht = () => n.validityStyles !== void 0 ? n.validityStyles : z.validityStyles, re = (e) => {
64
+ oe.current = !0, e.focus(), window.setTimeout(() => oe.current = !1, 30);
65
65
  }, he = () => {
66
- Q.current && ne(Q.current), n.adaptive && setTimeout(() => {
67
- Q.current && ne(Q.current);
66
+ X.current && re(X.current), n.adaptive && setTimeout(() => {
67
+ X.current && re(X.current);
68
68
  }, 300);
69
- }, ht = s.useCallback((e) => {
69
+ }, yt = s.useCallback((e) => {
70
70
  for (const r of e)
71
- Ht(r.target.clientWidth);
71
+ At(r.target.clientWidth);
72
72
  }, []), Te = () => {
73
73
  var e;
74
- (e = xe.current) != null && e.setCustomValidity && xe.current.setCustomValidity(
75
- Ie().valid ? "" : n.validationMessage || Dn
74
+ (e = De.current) != null && e.setCustomValidity && De.current.setCustomValidity(
75
+ Ie().valid ? "" : n.validationMessage || kn
76
76
  );
77
- }, _ = (e, r) => {
77
+ }, V = (e, r) => {
78
78
  const o = k();
79
- F(o, e, n.dataItemKey) || (n.value === void 0 && (r.data.value = e), t.current.updateComponentArgs({ value: e }), H.current = e, r.events.push({ type: "onChange" }));
80
- }, K = (e) => {
79
+ F(o, e, n.dataItemKey) || (n.value === void 0 && (r.data.value = e), t.current.updateComponentArgs({ value: e }), B.current = e, r.events.push({ type: "onChange" }));
80
+ }, M = (e) => {
81
81
  var r;
82
- (r = t == null ? void 0 : t.current) == null || r.applyState(e), H.current = void 0;
83
- }, j = (e, r) => {
82
+ (r = t == null ? void 0 : t.current) == null || r.applyState(e), B.current = void 0;
83
+ }, Q = (e, r) => {
84
84
  var c;
85
- const { virtual: o, dataItemKey: l, defaultItem: d } = n, u = E(n), g = o ? o.skip : 0, m = k(), i = e === -1 && d !== void 0 ? d : u[e - g], f = !F(i, m, l);
86
- _(i, r), f && ((c = t == null ? void 0 : t.current) == null || c.triggerPageChangeCornerItems(i, r));
87
- }, V = (e, r, o) => {
88
- var x, h;
89
- const { defaultItem: l, dataItemKey: d, virtual: u = { skip: 0, total: 0, pageSize: 0 } } = n, g = k(), m = E(n), i = (x = t == null ? void 0 : t.current) == null ? void 0 : x.vs, f = m.findIndex((w) => F(w, g, d)), c = (h = t == null ? void 0 : t.current) == null ? void 0 : h.navigation.navigate({
90
- current: u.skip + f,
91
- max: (i != null && i.enabled ? u.total : m.length) - 1,
92
- min: l !== void 0 ? -1 : 0,
85
+ const { virtual: o, dataItemKey: d, defaultItem: l } = n, u = E(n), p = o ? o.skip : 0, f = k(), i = e === -1 && l !== void 0 ? l : u[e - p], g = !F(i, f, d);
86
+ V(i, r), g && ((c = t == null ? void 0 : t.current) == null || c.triggerPageChangeCornerItems(i, r));
87
+ }, H = (e, r, o) => {
88
+ var D, h;
89
+ const { defaultItem: d, dataItemKey: l, virtual: u = { skip: 0, total: 0, pageSize: 0 } } = n, p = k(), f = E(n), i = (D = t == null ? void 0 : t.current) == null ? void 0 : D.vs, g = f.findIndex((w) => F(w, p, l)), c = (h = t == null ? void 0 : t.current) == null ? void 0 : h.navigation.navigate({
90
+ current: u.skip + g,
91
+ max: (i != null && i.enabled ? u.total : f.length) - 1,
92
+ min: d !== void 0 ? -1 : 0,
93
93
  keyCode: r,
94
94
  skipItems: o || void 0
95
95
  });
96
- c !== void 0 && j(c, e), K(e);
97
- }, yt = (e) => {
98
- J.current = e, t.current.wrapper = e;
99
- }, wt = (e) => /* @__PURE__ */ s.createElement(
96
+ c !== void 0 && Q(c, e), M(e);
97
+ }, wt = (e) => {
98
+ A.current = e, t.current.wrapper = e;
99
+ }, xt = (e) => /* @__PURE__ */ s.createElement(
100
100
  "select",
101
101
  {
102
102
  name: n.name,
103
103
  ref: (r) => {
104
- xe.current = r;
104
+ De.current = r;
105
105
  },
106
106
  tabIndex: -1,
107
107
  "aria-hidden": !0,
@@ -114,53 +114,53 @@ const Dn = "Please select a value from the list!", Me = s.forwardRef((ct, ut) =>
114
114
  textField: e,
115
115
  dataItemKey: r,
116
116
  virtual: o = { skip: 0 },
117
- focusedItemIndex: l = fn,
118
- filterable: d,
117
+ focusedItemIndex: d = hn,
118
+ filterable: l,
119
119
  skipDisabledItems: u = !0
120
- } = n, g = k(), m = E(n), i = n.filter ? n.filter : p.text;
121
- return u && e && !i && !g ? m.findIndex((f) => !f.disabled && f[e]) : rt(g) && i === void 0 || d && i === "" ? m.findIndex((f) => F(f, g, r)) : i ? Se.current ? l(m, i, e) : m.findIndex((f) => F(f, g, r)) : o.skip === 0 ? 0 : -1;
120
+ } = n, p = k(), f = E(n), i = n.filter ? n.filter : m.text;
121
+ return u && e && !i && !p ? f.findIndex((g) => !g.disabled && g[e]) : ot(p) && i === void 0 || l && i === "" ? f.findIndex((g) => F(g, p, r)) : i ? Se.current ? d(f, i, e) : f.findIndex((g) => F(g, p, r)) : o.skip === 0 ? 0 : -1;
122
122
  }, ze = (e, r) => r !== void 0 && r !== -1 && e && e.length > 0 && e[r].disabled, we = () => {
123
123
  const e = E(n), r = t.current.initState(), o = ye();
124
- ze(e, o) && (_(null, r), K(r));
125
- }, De = (e) => {
124
+ ze(e, o) && (V(null, r), M(r));
125
+ }, xe = (e) => {
126
126
  if (e.isPropagationStopped())
127
127
  return;
128
128
  const r = t.current.initState();
129
- r.syntheticEvent = e, p.focused || (r.data.focused = !0), we(), t.current.togglePopup(r), K(r);
129
+ r.syntheticEvent = e, m.focused || (r.data.focused = !0), we(), t.current.togglePopup(r), M(r);
130
130
  }, Oe = (e) => {
131
- var T, ce, U, ue, Y, Re, et;
131
+ var T, ue, G, pe, j, et, tt;
132
132
  e && e.target instanceof Element && e.target.nodeName === "INPUT" && e.stopPropagation && e.stopPropagation();
133
133
  const {
134
134
  filterable: r,
135
135
  disabled: o,
136
- defaultItem: l,
137
- leftRightKeysNavigation: d = !0,
136
+ defaultItem: d,
137
+ leftRightKeysNavigation: l = !0,
138
138
  virtual: u = { skip: 0, total: 0, pageSize: 0 },
139
- dataItemKey: g,
140
- groupField: m = "",
139
+ dataItemKey: p,
140
+ groupField: f = "",
141
141
  textField: i,
142
- skipDisabledItems: f = !0
143
- } = n, c = E(n), x = k(), h = c.findIndex((S) => F(S, x, g)), w = n.opened !== void 0 ? n.opened : p.opened, a = e.keyCode, N = a === I.home || a === I.end, b = a === I.up || a === I.down, $ = !w && (e.altKey && a === I.down || a === I.enter || a === I.space), ee = w && (e.altKey && a === I.up || a === I.esc), le = d && (a === I.left || a === I.right), de = b || le && !r || N, D = t.current.initState();
144
- if (D.syntheticEvent = e, !o) {
142
+ skipDisabledItems: g = !0
143
+ } = n, c = E(n), D = k(), h = c.findIndex((S) => F(S, D, p)), w = n.opened !== void 0 ? n.opened : m.opened, a = e.keyCode, N = a === I.home || a === I.end, b = a === I.up || a === I.down, Y = !w && (e.altKey && a === I.down || a === I.enter || a === I.space), te = w && (e.altKey && a === I.up || a === I.esc), de = l && (a === I.left || a === I.right), ce = b || de && !r || N, x = t.current.initState();
144
+ if (x.syntheticEvent = e, !o) {
145
145
  if (N && ((T = t == null ? void 0 : t.current) != null && T.vs.enabled))
146
- a === I.home ? u.skip !== 0 ? ((ce = t == null ? void 0 : t.current) == null || ce.triggerOnPageChange(D, 0, u.pageSize), A.current = !0) : _(c[0], D) : u.skip < u.total - u.pageSize ? ((U = t == null ? void 0 : t.current) == null || U.triggerOnPageChange(
147
- D,
146
+ a === I.home ? u.skip !== 0 ? ((ue = t == null ? void 0 : t.current) == null || ue.triggerOnPageChange(x, 0, u.pageSize), W.current = !0) : V(c[0], x) : u.skip < u.total - u.pageSize ? ((G = t == null ? void 0 : t.current) == null || G.triggerOnPageChange(
147
+ x,
148
148
  u.total - u.pageSize,
149
149
  u.pageSize
150
- ), A.current = !0) : _(c[c.length - 1], D);
150
+ ), W.current = !0) : V(c[c.length - 1], x);
151
151
  else if (w && a === I.pageUp)
152
- e.preventDefault(), (ue = t == null ? void 0 : t.current) == null || ue.scrollPopupByPageSize(-1);
152
+ e.preventDefault(), (pe = t == null ? void 0 : t.current) == null || pe.scrollPopupByPageSize(-1);
153
153
  else if (w && a === I.pageDown)
154
- e.preventDefault(), (Y = t == null ? void 0 : t.current) == null || Y.scrollPopupByPageSize(1);
154
+ e.preventDefault(), (j = t == null ? void 0 : t.current) == null || j.scrollPopupByPageSize(1);
155
155
  else if (w && a === I.enter) {
156
156
  const S = ye();
157
- ze(c, S) ? (_(null, D), K(D)) : j(S, D), (Re = t == null ? void 0 : t.current) == null || Re.togglePopup(D), e.preventDefault();
158
- } else if ($ || ee)
159
- ee && we(), (et = t == null ? void 0 : t.current) == null || et.togglePopup(D), e.preventDefault();
160
- else if (de) {
161
- if (Se.current = !1, m !== "" && i)
162
- if (!f && w)
163
- V(D, a);
157
+ ze(c, S) ? (V(null, x), M(x)) : Q(S, x), (et = t == null ? void 0 : t.current) == null || et.togglePopup(x), e.preventDefault();
158
+ } else if (Y || te)
159
+ te && we(), (tt = t == null ? void 0 : t.current) == null || tt.togglePopup(x), e.preventDefault();
160
+ else if (ce) {
161
+ if (Se.current = !1, f !== "" && i)
162
+ if (!g && w)
163
+ H(x, a);
164
164
  else {
165
165
  let S;
166
166
  if (a === I.down || a === I.right) {
@@ -168,7 +168,7 @@ const Dn = "Please select a value from the list!", Me = s.forwardRef((ct, ut) =>
168
168
  S = y && c.findIndex((v) => v[i] === y[i]);
169
169
  } else if (a === I.up || a === I.left) {
170
170
  let y;
171
- if (h === 0 && l)
171
+ if (h === 0 && d)
172
172
  S = -1;
173
173
  else if (h === -1)
174
174
  y = c, S = c.findIndex((v) => !v.disabled && v[i]);
@@ -182,11 +182,11 @@ const Dn = "Please select a value from the list!", Me = s.forwardRef((ct, ut) =>
182
182
  }
183
183
  if (S !== void 0) {
184
184
  const y = S - h;
185
- V(D, a, y);
186
- } else S === void 0 && c.findIndex((y) => y[i] === x[i]) === c.length - 1 && V(D, a);
185
+ H(x, a, y);
186
+ } else S === void 0 && c.findIndex((y) => y[i] === D[i]) === c.length - 1 && H(x, a);
187
187
  }
188
- else if (!f && w || N)
189
- V(D, a);
188
+ else if (!g && w || N)
189
+ H(x, a);
190
190
  else if (i) {
191
191
  let S;
192
192
  if (a === I.down || a === I.right) {
@@ -194,7 +194,7 @@ const Dn = "Please select a value from the list!", Me = s.forwardRef((ct, ut) =>
194
194
  S = y && c.findIndex((v) => v[i] === y[i]);
195
195
  } else if (a === I.up || a === I.left) {
196
196
  let y;
197
- if (h === 0 && l)
197
+ if (h === 0 && d)
198
198
  S = -1;
199
199
  else if (h === -1)
200
200
  y = c, S = c.find((v) => !v.disabled && v[i]);
@@ -208,25 +208,25 @@ const Dn = "Please select a value from the list!", Me = s.forwardRef((ct, ut) =>
208
208
  }
209
209
  if (S !== void 0) {
210
210
  const y = S - h;
211
- V(D, a, y);
212
- } else S === void 0 && c.findIndex((y) => y[i] === x[i]) === c.length - 1 && V(D, a);
211
+ H(x, a, y);
212
+ } else S === void 0 && c.findIndex((y) => y[i] === D[i]) === c.length - 1 && H(x, a);
213
213
  } else
214
- V(D, a);
214
+ H(x, a);
215
215
  e.preventDefault();
216
216
  }
217
- K(D);
217
+ M(x);
218
218
  }
219
219
  }, Dt = (e) => {
220
220
  const r = t.current.initState();
221
- r.syntheticEvent = e.syntheticEvent, n.filter === void 0 && (r.data.text = e.target.value), t.current.filterChanged(e.target.value, r), Se.current = !0, K(r), Z({ group: void 0, text: String(e.target.value) });
221
+ r.syntheticEvent = e.syntheticEvent, n.filter === void 0 && (r.data.text = e.target.value), t.current.filterChanged(e.target.value, r), Se.current = !0, M(r), R({ group: void 0, text: String(e.target.value) });
222
222
  }, Ve = (e) => {
223
- const r = n.filter !== void 0 ? n.filter : p.text;
223
+ const r = n.filter !== void 0 ? n.filter : m.text;
224
224
  return n.filterable && /* @__PURE__ */ s.createElement(
225
- un,
225
+ fn,
226
226
  {
227
227
  value: r,
228
228
  ref: (o) => {
229
- Q.current = o && o.element;
229
+ X.current = o && o.element;
230
230
  },
231
231
  onChange: Dt,
232
232
  onKeyDown: Oe,
@@ -235,42 +235,42 @@ const Dn = "Please select a value from the list!", Me = s.forwardRef((ct, ut) =>
235
235
  fillMode: me,
236
236
  renderListFilterWrapper: !0,
237
237
  placeholder: Ue.toLanguageString(
238
- lt,
239
- at[lt]
238
+ dt,
239
+ lt[dt]
240
240
  )
241
241
  }
242
242
  );
243
- }, xt = (e) => {
243
+ }, St = (e) => {
244
244
  var o;
245
245
  const r = t.current.initState();
246
- r.syntheticEvent = e, (o = t == null ? void 0 : t.current) == null || o.togglePopup(r), _(n.defaultItem, r), K(r);
247
- }, St = () => {
248
- const { textField: e, defaultItem: r, dataItemKey: o } = n, l = k();
246
+ r.syntheticEvent = e, (o = t == null ? void 0 : t.current) == null || o.togglePopup(r), V(n.defaultItem, r), M(r);
247
+ }, Ct = () => {
248
+ const { textField: e, defaultItem: r, dataItemKey: o } = n, d = k();
249
249
  return r !== void 0 && /* @__PURE__ */ s.createElement(
250
- pn,
250
+ gn,
251
251
  {
252
252
  defaultItem: r,
253
253
  textField: e,
254
- selected: F(l, r, o),
254
+ selected: F(d, r, o),
255
255
  key: "defaultitemkey",
256
- onClick: xt
256
+ onClick: St
257
257
  }
258
258
  );
259
- }, Ct = (e, r) => {
259
+ }, kt = (e, r) => {
260
260
  var o;
261
- (o = t == null ? void 0 : t.current) == null || o.handleItemClick(e, r), H.current = void 0;
262
- }, kt = (e) => {
261
+ (o = t == null ? void 0 : t.current) == null || o.handleItemClick(e, r), B.current = void 0;
262
+ }, Et = (e) => {
263
263
  const { vs: r, list: o } = t.current;
264
264
  r.scrollHandler(e);
265
- const { groupField: l } = n;
266
- let d = E(n);
267
- if (!(!l || !d.length) && l) {
268
- const u = We.current = We.current || (r.enabled ? r.itemHeight : o ? o.children[0].offsetHeight : 0), m = e.target.scrollTop - r.skip * u;
269
- d = t.current.getGroupedDataModernMode(d, l);
270
- let i = d[0][l];
271
- for (let f = 1; f < d.length && !(u * f > m); f++)
272
- d[f] && d[f][l] && (i = d[f][l]);
273
- i !== p.group && Z({ group: i });
265
+ const { groupField: d } = n;
266
+ let l = E(n);
267
+ if (!(!d || !l.length) && d) {
268
+ const u = We.current = We.current || (r.enabled ? r.itemHeight : o ? o.children[0].offsetHeight : 0), f = e.target.scrollTop - r.skip * u;
269
+ l = t.current.getGroupedDataModernMode(l, d);
270
+ let i = l[0][d];
271
+ for (let g = 1; g < l.length && !(u * g > f); g++)
272
+ l[g] && l[g][d] && (i = l[g][d]);
273
+ i !== m.group && R({ group: i });
274
274
  }
275
275
  }, He = () => {
276
276
  var a;
@@ -278,158 +278,158 @@ const Dn = "Please select a value from the list!", Me = s.forwardRef((ct, ut) =>
278
278
  textField: e,
279
279
  dataItemKey: r,
280
280
  virtual: o = { skip: 0, total: void 0 },
281
- groupHeaderItemRender: l,
282
- listNoDataRender: d,
281
+ groupHeaderItemRender: d,
282
+ listNoDataRender: l,
283
283
  itemRender: u
284
- } = n, g = E(n), m = M && M.uDropDownList, i = t.current.vs, f = o.skip, c = n.opened !== void 0 ? n.opened : p.opened, x = t.current.getPopupSettings(), h = `translateY(${i.translate}px)`, w = k();
284
+ } = n, p = E(n), f = K && K.uDropDownList, i = t.current.vs, g = o.skip, c = n.opened !== void 0 ? n.opened : m.opened, D = t.current.getPopupSettings(), h = `translateY(${i.translate}px)`, w = k();
285
285
  return /* @__PURE__ */ s.createElement(
286
- mn,
286
+ vn,
287
287
  {
288
288
  id: Ee,
289
289
  show: c,
290
- data: g.slice(),
290
+ data: p.slice(),
291
291
  focusedIndex: ye(),
292
292
  value: w,
293
293
  textField: e,
294
294
  valueField: r,
295
- optionsGuid: Ge,
295
+ optionsGuid: $e,
296
296
  groupField: n.groupField,
297
297
  listRef: (N) => {
298
298
  i.list = t.current.list = N;
299
299
  },
300
- wrapperStyle: { maxHeight: q ? void 0 : x.height },
301
- wrapperCssClass: L(P.listContent({ c: m })),
300
+ wrapperStyle: { maxHeight: _ ? void 0 : D.height },
301
+ wrapperCssClass: L(P.listContent({ c: f })),
302
302
  listStyle: i.enabled ? { transform: h } : void 0,
303
303
  key: "listkey",
304
- skip: f,
305
- onClick: Ct,
304
+ skip: g,
305
+ onClick: kt,
306
306
  itemRender: u,
307
- groupHeaderItemRender: l,
308
- noDataRender: d,
309
- onScroll: kt,
307
+ groupHeaderItemRender: d,
308
+ noDataRender: l,
309
+ onScroll: Et,
310
310
  wrapperRef: i.scrollerRef,
311
311
  scroller: (a = t == null ? void 0 : t.current) == null ? void 0 : a.renderScrollElement(),
312
312
  ariaSetSize: o.total
313
313
  }
314
314
  );
315
- }, Et = () => {
316
- const { groupField: e } = n, r = E(n), o = n.opened !== void 0 ? n.opened : p.opened, l = M && M.uDropDownList, d = {
315
+ }, Lt = () => {
316
+ const { groupField: e } = n, r = E(n), o = n.opened !== void 0 ? n.opened : m.opened, d = K && K.uDropDownList, l = {
317
317
  title: n.adaptiveTitle || n.label,
318
318
  subTitle: n.adaptiveSubtitle,
319
319
  expand: o,
320
- onClose: (g) => De(g),
320
+ onClose: (p) => xe(p),
321
321
  windowWidth: ke,
322
322
  mobileFilter: Ve(!0)
323
323
  };
324
- let { group: u } = p;
325
- return u === void 0 && e !== void 0 && (u = te(r[0], e)), /* @__PURE__ */ s.createElement(wn, { ...d }, /* @__PURE__ */ s.createElement(yn, null, /* @__PURE__ */ s.createElement("div", { className: L(P.listContainer({ c: l, popup: !1 })) }, Ft())));
326
- }, Lt = () => {
327
- p.focused && window.setTimeout(() => {
328
- p.focused && t.current.wrapper && ne(t.current.wrapper);
324
+ let { group: u } = m;
325
+ return u === void 0 && e !== void 0 && (u = ne(r[0], e)), /* @__PURE__ */ s.createElement(Cn, { ...l }, /* @__PURE__ */ s.createElement(Sn, null, /* @__PURE__ */ s.createElement("div", { className: L(P.listContainer({ c: d, popup: !1 })) }, Mt())));
326
+ }, bt = () => {
327
+ m.focused && window.setTimeout(() => {
328
+ m.focused && t.current.wrapper && re(t.current.wrapper);
329
329
  });
330
- }, bt = (e) => {
330
+ }, Pt = (e) => {
331
331
  "onMouseDownOutside" in (n.popupSettings || {}) && n.popupSettings.onMouseDownOutside.call(void 0, e);
332
- }, Pt = () => {
333
- const { header: e, footer: r, dir: o, groupField: l, groupStickyHeaderItemRender: d, list: u } = n, g = E(n), m = t.current, i = m.getPopupSettings(), f = n.opened !== void 0 ? n.opened : p.opened, c = i.width !== void 0 ? i.width : m.popupWidth, x = M && M.uDropDownList, h = {
334
- dir: o !== void 0 ? o : m.dirCalculated,
332
+ }, Ft = () => {
333
+ const { header: e, footer: r, dir: o, groupField: d, groupStickyHeaderItemRender: l, list: u } = n, p = E(n), f = t.current, i = f.getPopupSettings(), g = n.opened !== void 0 ? n.opened : m.opened, c = i.width !== void 0 ? i.width : f.popupWidth, D = K && K.uDropDownList, h = {
334
+ dir: o !== void 0 ? o : f.dirCalculated,
335
335
  width: c,
336
336
  popupSettings: {
337
337
  ...i,
338
338
  popupClass: L(
339
339
  i.popupClass,
340
340
  P.listContainer({
341
- c: x,
341
+ c: D,
342
342
  popup: !0
343
343
  })
344
344
  ),
345
- anchor: i.anchor || J.current,
346
- show: f,
345
+ anchor: i.anchor || A.current,
346
+ show: g,
347
347
  onOpen: he,
348
- onClose: Lt,
349
- onMouseDownOutside: bt
348
+ onClose: bt,
349
+ onMouseDownOutside: Pt
350
350
  },
351
- itemsCount: [g.length]
351
+ itemsCount: [p.length]
352
352
  };
353
- let { group: w } = p;
354
- return w === void 0 && l !== void 0 && (w = te(g[0], l)), /* @__PURE__ */ s.createElement(cn, { ...h }, Ve(!1), e && /* @__PURE__ */ s.createElement("div", { className: L(P.listHeader({ c: x })) }, e), /* @__PURE__ */ s.createElement(
353
+ let { group: w } = m;
354
+ return w === void 0 && d !== void 0 && (w = ne(p[0], d)), /* @__PURE__ */ s.createElement(mn, { ...h }, Ve(!1), e && /* @__PURE__ */ s.createElement("div", { className: L(P.listHeader({ c: D })) }, e), /* @__PURE__ */ s.createElement(
355
355
  "div",
356
356
  {
357
357
  className: L(
358
358
  P.list({
359
- c: x,
359
+ c: D,
360
360
  size: O,
361
361
  virtual: t.current.vs.enabled
362
362
  })
363
363
  )
364
364
  },
365
- St(),
366
- !u && w && g.length !== 0 && /* @__PURE__ */ s.createElement(nt, { group: w, render: d }),
365
+ Ct(),
366
+ !u && w && p.length !== 0 && /* @__PURE__ */ s.createElement(rt, { group: w, render: l }),
367
367
  He()
368
- ), r && /* @__PURE__ */ s.createElement("div", { className: L(P.listFooter({ c: x })) }, r), Ke && /* @__PURE__ */ s.createElement(on, { message: pt }));
369
- }, Ft = () => {
370
- const { header: e, footer: r, groupStickyHeaderItemRender: o, groupField: l, list: d } = n, u = E(n), g = M && M.uDropDownList;
371
- let { group: m } = p;
372
- return m === void 0 && l !== void 0 && (m = te(u[0], l)), /* @__PURE__ */ s.createElement(s.Fragment, null, e && /* @__PURE__ */ s.createElement("div", { className: L(P.listHeader({ c: g })) }, e), /* @__PURE__ */ s.createElement(
368
+ ), r && /* @__PURE__ */ s.createElement("div", { className: L(P.listFooter({ c: D })) }, r), Ke && /* @__PURE__ */ s.createElement(ln, { message: mt }));
369
+ }, Mt = () => {
370
+ const { header: e, footer: r, groupStickyHeaderItemRender: o, groupField: d, list: l } = n, u = E(n), p = K && K.uDropDownList;
371
+ let { group: f } = m;
372
+ return f === void 0 && d !== void 0 && (f = ne(u[0], d)), /* @__PURE__ */ s.createElement(s.Fragment, null, e && /* @__PURE__ */ s.createElement("div", { className: L(P.listHeader({ c: p })) }, e), /* @__PURE__ */ s.createElement(
373
373
  "div",
374
374
  {
375
375
  className: L("k-list", {
376
- [`k-list-${q ? "lg" : sn[O] || O}`]: q || O
376
+ [`k-list-${_ ? "lg" : dn[O] || O}`]: _ || O
377
377
  })
378
378
  },
379
- !d && m && u.length !== 0 && /* @__PURE__ */ s.createElement(nt, { group: m, render: o }),
379
+ !l && f && u.length !== 0 && /* @__PURE__ */ s.createElement(rt, { group: f, render: o }),
380
380
  He()
381
381
  ), r && /* @__PURE__ */ s.createElement("div", { className: "k-list-footer" }, r));
382
- }, Mt = (e) => {
383
- const { dataItemKey: r } = n, o = E(n), l = k();
384
- let d = o.map((b, $) => ({ item: b, itemIndex: $ }));
385
- const u = G.current.word, g = G.current.last, m = gn(u, g);
386
- let i = d.length, f = Math.max(
382
+ }, Kt = (e) => {
383
+ const { dataItemKey: r } = n, o = E(n), d = k();
384
+ let l = o.map((b, Y) => ({ item: b, itemIndex: Y }));
385
+ const u = $.current.word, p = $.current.last, f = yn(u, p);
386
+ let i = l.length, g = Math.max(
387
387
  0,
388
- o.findIndex((b) => F(b, l, r))
388
+ o.findIndex((b) => F(b, d, r))
389
389
  ), c;
390
- n.defaultItem && (c = { item: n.defaultItem, itemIndex: -1 }, i += 1, f += 1), f += m ? 1 : 0, d = vn(d, f, c);
391
- let x, h, w, a = 0;
390
+ n.defaultItem && (c = { item: n.defaultItem, itemIndex: -1 }, i += 1, g += 1), g += f ? 1 : 0, l = wn(l, g, c);
391
+ let D, h, w, a = 0;
392
392
  const { textField: N } = n;
393
393
  for (; a < i; ) {
394
- if (x = te(d[a].item, N), h = m && ot(x, g, pe), w = ot(x, u, pe), h || w) {
395
- a = d[a].itemIndex;
394
+ if (D = ne(l[a].item, N), h = f && it(D, p, J), w = it(D, u, J), h || w) {
395
+ a = l[a].itemIndex;
396
396
  break;
397
397
  }
398
398
  a++;
399
399
  }
400
400
  if (a !== i) {
401
401
  const b = t.current.initState();
402
- b.syntheticEvent = e, j(a, b), K(b), H.current = void 0;
402
+ b.syntheticEvent = e, Q(a, b), M(b), B.current = void 0;
403
403
  }
404
- }, Kt = (e) => {
405
- clearTimeout(Be.current), n.filterable || (Be.current = window.setTimeout(() => G.current.word = "", mt), Mt(e));
406
404
  }, Nt = (e) => {
407
- re.current || t.current.handleFocus(e);
405
+ clearTimeout(Be.current), n.filterable || (Be.current = window.setTimeout(() => $.current.word = "", ft), Kt(e));
408
406
  }, Tt = (e) => {
409
- if (re.current || !p.focused)
410
- return;
411
- const r = n.opened !== void 0 ? n.opened : p.opened, o = t.current.initState();
412
- o.syntheticEvent = e, o.data.focused = !1, o.events.push({ type: "onBlur" }), r && we(), r && !q && t.current.togglePopup(o), K(o);
407
+ oe.current || t.current.handleFocus(e);
413
408
  }, zt = (e) => {
409
+ if (oe.current || !m.focused)
410
+ return;
411
+ const r = n.opened !== void 0 ? n.opened : m.opened, o = t.current.initState();
412
+ o.syntheticEvent = e, o.data.focused = !1, o.events.push({ type: "onBlur" }), r && we(), r && !_ && t.current.togglePopup(o), M(o);
413
+ }, Ot = (e) => {
414
414
  if (n.filterable || e.which === 0 || e.keyCode === I.enter)
415
415
  return;
416
416
  let r = String.fromCharCode(e.charCode || e.keyCode);
417
- pe && (r = r.toLowerCase()), r === " " && e.preventDefault(), G.current = {
418
- word: G.current.word + r,
419
- last: G.current.last + r
420
- }, Kt(e);
421
- }, Ot = () => {
417
+ J && (r = r.toLowerCase()), r === " " && e.preventDefault(), $.current = {
418
+ word: $.current.word + r,
419
+ last: $.current.last + r
420
+ }, Nt(e);
421
+ }, Vt = () => {
422
422
  const e = t.current.initState();
423
- e.data.opened = p.opened, t.current.togglePopup(e), K(e);
424
- }, Ae = s.useRef(null), J = s.useRef(null), xe = s.useRef(null), Q = s.useRef(null);
423
+ e.data.opened = m.opened, t.current.togglePopup(e), M(e);
424
+ }, Ae = s.useRef(null), A = s.useRef(null), De = s.useRef(null), X = s.useRef(null);
425
425
  s.useImperativeHandle(
426
426
  Ae,
427
427
  () => ({
428
428
  get element() {
429
- return J.current;
429
+ return A.current;
430
430
  },
431
431
  get index() {
432
- return vt();
432
+ return It();
433
433
  },
434
434
  get name() {
435
435
  return n.name;
@@ -441,21 +441,21 @@ const Dn = "Please select a value from the list!", Me = s.forwardRef((ct, ut) =>
441
441
  return k();
442
442
  },
443
443
  get focused() {
444
- return p.focused;
444
+ return m.focused;
445
445
  },
446
446
  get opened() {
447
- return p.opened;
447
+ return m.opened;
448
448
  },
449
- focus: gt,
449
+ focus: vt,
450
450
  props: n,
451
- togglePopup: Ot
451
+ togglePopup: Vt
452
452
  })
453
453
  ), s.useImperativeHandle(
454
- ut,
454
+ pt,
455
455
  () => Ae.current
456
456
  );
457
- const Be = s.useRef(null), G = s.useRef({ word: "", last: "" }), re = s.useRef(!1), H = s.useRef(null), A = s.useRef(!1), Se = s.useRef(!1), B = s.useRef({}), Ce = s.useRef({}), t = s.useRef(
458
- new dt({
457
+ const Be = s.useRef(null), $ = s.useRef({ word: "", last: "" }), oe = s.useRef(!1), B = s.useRef(null), W = s.useRef(!1), Se = s.useRef(!1), q = s.useRef({}), Ce = s.useRef({}), t = s.useRef(
458
+ new ct({
459
459
  props: n,
460
460
  setState: () => {
461
461
  },
@@ -467,143 +467,162 @@ const Dn = "Please select a value from the list!", Me = s.forwardRef((ct, ut) =>
467
467
  handleItemSelect: () => {
468
468
  }
469
469
  })
470
- ), We = s.useRef(0), X = s.useRef(null), [p, Vt] = s.useState({}), [ke, Ht] = s.useState(), [, qe] = s.useReducer((e) => e, !0), Ue = hn(), Z = (e) => {
471
- Vt({ ...p, ...e });
470
+ ), We = s.useRef(0), Z = s.useRef(null), [m, Ht] = s.useState({}), [ke, At] = s.useState(), [, qe] = s.useReducer((e) => e, !0), Ue = Dn(), _e = n.name || n.id, Bt = s.useCallback(
471
+ (e) => {
472
+ if (e == null || !t.current)
473
+ return;
474
+ const r = E(n), { textField: o } = n, d = String(e), l = In(r, d, o, !1, J), u = l !== -1 ? r[l] : void 0;
475
+ if (u !== void 0) {
476
+ const p = t.current.initState();
477
+ p.syntheticEvent = {
478
+ target: A.current
479
+ }, V(u, p), M(p);
480
+ }
481
+ },
482
+ [n, J]
483
+ );
484
+ rn(A, {
485
+ fieldName: _e,
486
+ onValueChange: Bt,
487
+ enabled: !!_e
488
+ });
489
+ const R = (e) => {
490
+ Ht({ ...m, ...e });
472
491
  };
473
492
  s.useEffect(() => {
474
493
  t.current.updateComponentArgs({
475
494
  props: n,
476
- setState: Z,
477
- state: p,
495
+ setState: R,
496
+ state: m,
478
497
  forceUpdate: qe,
479
- element: J.current,
480
- handleItemSelect: j,
498
+ element: A.current,
499
+ handleItemSelect: Q,
481
500
  value: k()
482
501
  });
483
- }, [Z, p, qe, j, k]), s.useEffect(() => {
484
- var f, c, x, h, w, a, N, b, $, ee, le, de, D;
485
- const { dataItemKey: e, virtual: r, groupField: o = "", textField: l } = n, d = E(n), u = B.current.virtual ? B.current.virtual.total : 0, g = n.opened !== void 0 ? n.opened : p.opened, m = B.current.opened !== void 0 ? B.current.opened : Ce.current.opened, i = !m && g;
486
- if ((f = t == null ? void 0 : t.current) == null || f.didUpdate(), (c = t == null ? void 0 : t.current) != null && c.getPopupSettings().animate || i && he(), r && r.total !== u)
487
- (x = t == null ? void 0 : t.current) == null || x.vs.calcScrollElementHeight(), (h = t == null ? void 0 : t.current) == null || h.vs.reset();
502
+ }, [R, m, qe, Q, k]), s.useEffect(() => {
503
+ var g, c, D, h, w, a, N, b, Y, te, de, ce, x;
504
+ const { dataItemKey: e, virtual: r, groupField: o = "", textField: d } = n, l = E(n), u = q.current.virtual ? q.current.virtual.total : 0, p = n.opened !== void 0 ? n.opened : m.opened, f = q.current.opened !== void 0 ? q.current.opened : Ce.current.opened, i = !f && p;
505
+ if ((g = t == null ? void 0 : t.current) == null || g.didUpdate(), (c = t == null ? void 0 : t.current) != null && c.getPopupSettings().animate || i && he(), r && r.total !== u)
506
+ (D = t == null ? void 0 : t.current) == null || D.vs.calcScrollElementHeight(), (h = t == null ? void 0 : t.current) == null || h.vs.reset();
488
507
  else {
489
- const T = k(), ce = B.current.value !== void 0 ? B.current.value : Ce.current.value;
490
- let U = d.findIndex((Y) => F(Y, T, e));
491
- o !== "" && T && l && (U = (a = (w = t == null ? void 0 : t.current) == null ? void 0 : w.getGroupedDataModernMode(d, o)) == null ? void 0 : a.map((Y) => Y[l]).indexOf(T[l]));
492
- const ue = !F(ce, T, e);
493
- i && r ? (N = t == null ? void 0 : t.current) == null || N.scrollToVirtualItem(r, U) : i && !r ? (he(), d && d.length !== 0 && ((b = t == null ? void 0 : t.current) == null || b.resetGroupStickyHeader(d[0][o], {
494
- setState: Z,
495
- group: p.group,
496
- state: p
497
- })), ($ = t == null ? void 0 : t.current) == null || $.scrollToItem(U)) : g && m && T && ue && !A.current ? (le = t == null ? void 0 : t.current) == null || le.scrollToItem(U, (ee = t == null ? void 0 : t.current) == null ? void 0 : ee.vs.enabled) : g && m && A.current && (A.current && r && r.skip === 0 ? (de = t == null ? void 0 : t.current) == null || de.vs.reset() : A.current && r && r.skip === r.total - r.pageSize && ((D = t == null ? void 0 : t.current) == null || D.vs.scrollToEnd()));
508
+ const T = k(), ue = q.current.value !== void 0 ? q.current.value : Ce.current.value;
509
+ let G = l.findIndex((j) => F(j, T, e));
510
+ o !== "" && T && d && (G = (a = (w = t == null ? void 0 : t.current) == null ? void 0 : w.getGroupedDataModernMode(l, o)) == null ? void 0 : a.map((j) => j[d]).indexOf(T[d]));
511
+ const pe = !F(ue, T, e);
512
+ i && r ? (N = t == null ? void 0 : t.current) == null || N.scrollToVirtualItem(r, G) : i && !r ? (he(), l && l.length !== 0 && ((b = t == null ? void 0 : t.current) == null || b.resetGroupStickyHeader(l[0][o], {
513
+ setState: R,
514
+ group: m.group,
515
+ state: m
516
+ })), (Y = t == null ? void 0 : t.current) == null || Y.scrollToItem(G)) : p && f && T && pe && !W.current ? (de = t == null ? void 0 : t.current) == null || de.scrollToItem(G, (te = t == null ? void 0 : t.current) == null ? void 0 : te.vs.enabled) : p && f && W.current && (W.current && r && r.skip === 0 ? (ce = t == null ? void 0 : t.current) == null || ce.vs.reset() : W.current && r && r.skip === r.total - r.pageSize && ((x = t == null ? void 0 : t.current) == null || x.vs.scrollToEnd()));
498
517
  }
499
- A.current = !1, Ce.current = p, B.current = n, Te();
518
+ W.current = !1, Ce.current = m, q.current = n, Te();
500
519
  }), s.useEffect(() => {
501
520
  var e, r;
502
- return X.current = tt && window.ResizeObserver && new window.ResizeObserver(ht.bind(void 0)), (e = t == null ? void 0 : t.current) == null || e.didMount(), Te(), (r = ge()) != null && r.body && X.current && X.current.observe(ge().body), () => {
521
+ return Z.current = nt && window.ResizeObserver && new window.ResizeObserver(yt.bind(void 0)), (e = t == null ? void 0 : t.current) == null || e.didMount(), Te(), (r = ge()) != null && r.body && Z.current && Z.current.observe(ge().body), () => {
503
522
  var o;
504
- (o = ge()) != null && o.body && X.current && X.current.disconnect();
523
+ (o = ge()) != null && o.body && Z.current && Z.current.disconnect();
505
524
  };
506
525
  }, []);
507
- const _e = fe + "-accessibility-id", Ee = fe + "-listbox-id", Ge = fe + "-guid", At = Ue.toLanguageString(
508
- st,
509
- at[st]
526
+ const Ge = fe + "-accessibility-id", Ee = fe + "-listbox-id", $e = fe + "-guid", Wt = Ue.toLanguageString(
527
+ at,
528
+ lt[at]
510
529
  ), {
511
- style: oe,
512
- className: Bt,
530
+ style: ie,
531
+ className: qt,
513
532
  label: Le,
514
- dir: Wt,
515
- virtual: W,
516
- adaptive: Sn,
517
- dataItemKey: qt,
518
- disabled: ie,
519
- loading: $e,
520
- iconClassName: Ye,
521
- svgIcon: Ut,
522
- valueRender: je
523
- } = n, be = n.opened !== void 0 ? n.opened : p.opened, se = k(), Pe = te(se, n.textField), Je = !It() || Ie().valid, ae = t.current, _t = ae.vs, R = M && M.uDropDownList;
524
- _t.enabled = W !== void 0;
525
- const Qe = tn(), q = !!(ke && Qe && ke <= Qe.medium && n.adaptive);
526
- W !== void 0 && (ae.vs.skip = W.skip, ae.vs.total = W.total, ae.vs.pageSize = W.pageSize);
527
- const Gt = E(n), { focused: $t } = p, Yt = Gt.findIndex((e) => F(e, se, qt)), Xe = /* @__PURE__ */ s.createElement("span", { id: _e, className: L(P.inputInner({ c: R })) }, Pe && /* @__PURE__ */ s.createElement("span", { className: L(P.inputText({ c: R })) }, Pe)), jt = je !== void 0 ? je.call(void 0, Xe, se) : Xe, Ze = /* @__PURE__ */ s.createElement(s.Fragment, null, /* @__PURE__ */ s.createElement(
533
+ dir: Ut,
534
+ virtual: U,
535
+ adaptive: Ln,
536
+ dataItemKey: _t,
537
+ disabled: se,
538
+ loading: Ye,
539
+ iconClassName: je,
540
+ svgIcon: Gt,
541
+ valueRender: Je
542
+ } = n, be = n.opened !== void 0 ? n.opened : m.opened, ae = k(), Pe = ne(ae, n.textField), Qe = !ht() || Ie().valid, le = t.current, $t = le.vs, ee = K && K.uDropDownList;
543
+ $t.enabled = U !== void 0;
544
+ const Xe = on(), _ = !!(ke && Xe && ke <= Xe.medium && n.adaptive);
545
+ U !== void 0 && (le.vs.skip = U.skip, le.vs.total = U.total, le.vs.pageSize = U.pageSize);
546
+ const Yt = E(n), { focused: jt } = m, Jt = Yt.findIndex((e) => F(e, ae, _t)), Ze = /* @__PURE__ */ s.createElement("span", { id: Ge, className: L(P.inputInner({ c: ee })) }, Pe && /* @__PURE__ */ s.createElement("span", { className: L(P.inputText({ c: ee })) }, Pe)), Qt = Je !== void 0 ? Je.call(void 0, Ze, ae) : Ze, Re = /* @__PURE__ */ s.createElement(s.Fragment, null, /* @__PURE__ */ s.createElement(
528
547
  "span",
529
548
  {
530
- ref: yt,
549
+ ref: wt,
531
550
  className: L(
532
551
  P.wrapper({
533
- c: R,
552
+ c: ee,
534
553
  size: O,
535
554
  rounded: Ne,
536
555
  fillMode: me,
537
- focused: $t,
538
- disabled: ie,
539
- invalid: !Je,
540
- loading: $e,
556
+ focused: jt,
557
+ disabled: se,
558
+ invalid: !Qe,
559
+ loading: Ye,
541
560
  required: ve()
542
561
  }),
543
- Bt
562
+ qt
544
563
  ),
545
- style: Le ? { ...oe, width: void 0 } : oe,
546
- dir: Wt,
564
+ style: Le ? { ...ie, width: void 0 } : ie,
565
+ dir: Ut,
547
566
  onMouseDown: be ? (e) => {
548
- e.target.nodeName !== "INPUT" && (ne(t.current.wrapper), e.preventDefault());
567
+ e.target.nodeName !== "INPUT" && (re(t.current.wrapper), e.preventDefault());
549
568
  } : void 0,
550
- onFocus: q ? (e) => De(e) : Nt,
551
- onBlur: Tt,
552
- tabIndex: nn(ft, ie),
569
+ onFocus: _ ? (e) => xe(e) : Tt,
570
+ onBlur: zt,
571
+ tabIndex: sn(gt, se),
553
572
  accessKey: n.accessKey,
554
573
  onKeyDown: Oe,
555
- onKeyPress: zt,
556
- onClick: ie ? void 0 : De,
574
+ onKeyPress: Ot,
575
+ onClick: se ? void 0 : xe,
557
576
  role: "combobox",
558
577
  "aria-required": ve(),
559
- "aria-disabled": ie || void 0,
578
+ "aria-disabled": se || void 0,
560
579
  "aria-haspopup": "listbox",
561
580
  "aria-expanded": be || !1,
562
581
  "aria-owns": Ee,
563
- "aria-activedescendant": be ? "option-" + Ge + "-" + (Yt + (W ? W.skip : 0)) : void 0,
582
+ "aria-activedescendant": be ? "option-" + $e + "-" + (Jt + (U ? U.skip : 0)) : void 0,
564
583
  "aria-label": n.ariaLabel || n.label,
565
584
  "aria-labelledby": n.ariaLabelledBy,
566
- "aria-describedby": n.ariaDescribedBy || _e,
585
+ "aria-describedby": n.ariaDescribedBy || Ge,
567
586
  "aria-controls": Ee,
568
587
  id: n.id,
569
588
  title: n.title
570
589
  },
571
- jt,
572
- $e && /* @__PURE__ */ s.createElement(rn, { className: L(P.loadingIcon({ c: R })), name: "loading" }),
590
+ Qt,
591
+ Ye && /* @__PURE__ */ s.createElement(an, { className: L(P.loadingIcon({ c: ee })), name: "loading" }),
573
592
  /* @__PURE__ */ s.createElement(
574
- In,
593
+ xn,
575
594
  {
576
595
  tabIndex: -1,
577
596
  type: "button",
578
- "aria-label": At,
597
+ "aria-label": Wt,
579
598
  size: O,
580
599
  fillMode: me,
581
- className: L(P.inputButton({ c: R })),
582
- iconClass: Ye,
583
- svgIcon: Ye ? void 0 : Ut || dn,
584
- onMouseDown: (e) => p.focused && e.preventDefault()
600
+ className: L(P.inputButton({ c: ee })),
601
+ iconClass: je,
602
+ svgIcon: je ? void 0 : Gt || pn,
603
+ onMouseDown: (e) => m.focused && e.preventDefault()
585
604
  }
586
605
  ),
587
- wt(se),
588
- !q && Pt()
589
- ), q && Et());
606
+ xt(ae),
607
+ !_ && Ft()
608
+ ), _ && Lt());
590
609
  return Le ? /* @__PURE__ */ s.createElement(
591
- ln,
610
+ un,
592
611
  {
593
612
  label: Le,
594
613
  editorValue: Pe,
595
- editorValid: Je,
614
+ editorValid: Qe,
596
615
  editorDisabled: n.disabled,
597
- style: { width: oe ? oe.width : void 0 },
598
- children: Ze
616
+ style: { width: ie ? ie.width : void 0 },
617
+ children: Re
599
618
  }
600
- ) : Ze;
619
+ ) : Re;
601
620
  });
602
621
  Me.propTypes = {
603
622
  delay: C.number,
604
623
  ignoreCase: C.bool,
605
624
  iconClassName: C.string,
606
- svgIcon: an,
625
+ svgIcon: cn,
607
626
  defaultItem: C.any,
608
627
  valueRender: C.func,
609
628
  valueMap: C.func,
@@ -623,17 +642,17 @@ const z = {
623
642
  delay: 500,
624
643
  tabIndex: 0,
625
644
  ignoreCase: !0,
626
- ...dt.defaultProps,
645
+ ...ct.defaultProps,
627
646
  required: !1,
628
647
  size: void 0,
629
648
  rounded: void 0,
630
649
  fillMode: void 0
631
650
  };
632
651
  Me.displayName = "KendoReactDropDownList";
633
- const xn = Jt();
652
+ const En = Xt();
634
653
  Me.displayName = "KendoReactDropDownList";
635
654
  export {
636
655
  Me as DropDownList,
637
- xn as DropDownListPropsContext,
656
+ En as DropDownListPropsContext,
638
657
  z as dropDownListDefaultProps
639
658
  };