@progress/kendo-react-inputs 15.2.0-develop.1 → 15.2.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/checkbox/Checkbox.js +1 -1
- package/checkbox/Checkbox.mjs +79 -77
- package/colors/ColorContrastLabels.js +1 -1
- package/colors/ColorContrastLabels.mjs +2 -2
- package/colors/ColorGradient.js +1 -1
- package/colors/ColorGradient.mjs +51 -52
- package/colors/ColorPalette.js +1 -1
- package/colors/ColorPalette.mjs +71 -72
- package/colors/ColorPicker.js +1 -1
- package/colors/ColorPicker.mjs +247 -239
- package/colors/FlatColorPicker.d.ts +4 -4
- package/colors/FlatColorPicker.js +1 -1
- package/colors/FlatColorPicker.mjs +104 -100
- package/colors/interfaces/ColorPaletteProps.d.ts +7 -0
- package/colors/interfaces/ColorPickerPaletteSettings.d.ts +5 -0
- package/dist/cdn/js/kendo-react-inputs.js +1 -1
- package/maskedtextbox/MaskedTextBox.d.ts +1 -0
- package/maskedtextbox/MaskedTextBox.js +1 -1
- package/maskedtextbox/MaskedTextBox.mjs +26 -23
- package/maskedtextbox/MaskedTextBoxProps.d.ts +7 -0
- package/numerictextbox/NumericTextBox.js +1 -1
- package/numerictextbox/NumericTextBox.mjs +2 -2
- package/otpinput/OTPInput.js +1 -1
- package/otpinput/OTPInput.mjs +141 -143
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +2 -2
- package/package.json +10 -10
- package/radiobutton/RadioButton.js +1 -1
- package/radiobutton/RadioButton.mjs +32 -30
- package/range-slider/RangeSlider.js +11 -11
- package/range-slider/RangeSlider.mjs +54 -54
- package/rating/Rating.d.ts +12 -0
- package/rating/Rating.js +2 -2
- package/rating/Rating.mjs +91 -92
- package/slider/Slider.d.ts +12 -0
- package/slider/Slider.js +1 -1
- package/slider/Slider.mjs +61 -56
- package/switch/Switch.d.ts +15 -0
- package/switch/Switch.js +1 -1
- package/switch/Switch.mjs +82 -79
- package/textarea/TextArea.js +1 -1
- package/textarea/TextArea.mjs +11 -12
package/otpinput/OTPInput.mjs
CHANGED
|
@@ -5,25 +5,23 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import * as
|
|
9
|
-
import { useAsyncFocusBlur as
|
|
10
|
-
import { OTPInputCell as
|
|
11
|
-
import { OTPInputSeparator as
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
const C = d.reduce((_, w) => _ + w, 0);
|
|
18
|
-
return C !== f && console.warn(`[OTPInput] The sum of groupLength values (${C}) must equal length (${f}).`), d;
|
|
8
|
+
import * as a from "react";
|
|
9
|
+
import { useAsyncFocusBlur as pe, useWebMcpRegister as de, classNames as fe, kendoThemeMaps as me } from "@progress/kendo-react-common";
|
|
10
|
+
import { OTPInputCell as he } from "./OTPInputCell.mjs";
|
|
11
|
+
import { OTPInputSeparator as be } from "./OTPInputSeparator.mjs";
|
|
12
|
+
const Ce = 4;
|
|
13
|
+
function ve(d, f) {
|
|
14
|
+
if (Array.isArray(f)) {
|
|
15
|
+
const C = f.reduce((_, w) => _ + w, 0);
|
|
16
|
+
return C !== d && console.warn(`[OTPInput] The sum of groupLength values (${C}) must equal length (${d}).`), f;
|
|
19
17
|
}
|
|
20
18
|
const y = [];
|
|
21
|
-
let m =
|
|
19
|
+
let m = d;
|
|
22
20
|
for (; m > 0; )
|
|
23
|
-
y.push(Math.min(
|
|
21
|
+
y.push(Math.min(f, m)), m -= f;
|
|
24
22
|
return y;
|
|
25
23
|
}
|
|
26
|
-
const
|
|
24
|
+
const ge = a.forwardRef((d, f) => {
|
|
27
25
|
const {
|
|
28
26
|
value: y,
|
|
29
27
|
defaultValue: m,
|
|
@@ -32,100 +30,100 @@ const _e = r.forwardRef((f, d) => {
|
|
|
32
30
|
separator: w,
|
|
33
31
|
type: h,
|
|
34
32
|
placeholder: H,
|
|
35
|
-
spacing:
|
|
36
|
-
disabled:
|
|
33
|
+
spacing: N,
|
|
34
|
+
disabled: P,
|
|
37
35
|
readOnly: E,
|
|
38
|
-
inputAttributes:
|
|
36
|
+
inputAttributes: S,
|
|
39
37
|
name: R,
|
|
40
|
-
required:
|
|
38
|
+
required: q,
|
|
41
39
|
valid: A,
|
|
42
40
|
size: D,
|
|
43
|
-
fillMode:
|
|
44
|
-
rounded:
|
|
41
|
+
fillMode: G,
|
|
42
|
+
rounded: U,
|
|
45
43
|
onChange: M,
|
|
46
44
|
onFocus: B,
|
|
47
|
-
onBlur:
|
|
48
|
-
ariaLabel:
|
|
49
|
-
ariaLabelledBy:
|
|
50
|
-
ariaDescribedBy:
|
|
51
|
-
id:
|
|
52
|
-
style:
|
|
53
|
-
dir:
|
|
54
|
-
className:
|
|
45
|
+
onBlur: K,
|
|
46
|
+
ariaLabel: W,
|
|
47
|
+
ariaLabelledBy: J,
|
|
48
|
+
ariaDescribedBy: Q,
|
|
49
|
+
id: V,
|
|
50
|
+
style: X,
|
|
51
|
+
dir: F,
|
|
52
|
+
className: Y,
|
|
55
53
|
// Form
|
|
56
|
-
touched:
|
|
57
|
-
visited:
|
|
58
|
-
modified:
|
|
59
|
-
validationMessage:
|
|
60
|
-
...
|
|
61
|
-
} =
|
|
54
|
+
touched: ke,
|
|
55
|
+
visited: ye,
|
|
56
|
+
modified: Ee,
|
|
57
|
+
validationMessage: _e,
|
|
58
|
+
...Z
|
|
59
|
+
} = d, u = C != null ? C : Ce, I = y !== void 0, [x, ee] = a.useState(() => (m != null ? m : "").padEnd(u, " ").slice(0, u)), n = (I ? y : x).padEnd(u, " ").slice(0, u), O = a.useRef(n);
|
|
62
60
|
O.current = n;
|
|
63
|
-
const [
|
|
64
|
-
|
|
65
|
-
|
|
61
|
+
const [te, j] = a.useState(null), v = a.useRef(null), g = a.useCallback((e) => {
|
|
62
|
+
v.current !== null && clearTimeout(v.current), j(e), v.current = setTimeout(() => {
|
|
63
|
+
j(null), v.current = null;
|
|
66
64
|
}, 300);
|
|
67
65
|
}, []);
|
|
68
|
-
|
|
69
|
-
|
|
66
|
+
a.useEffect(() => () => {
|
|
67
|
+
v.current !== null && clearTimeout(v.current);
|
|
70
68
|
}, []);
|
|
71
|
-
const
|
|
69
|
+
const z = a.useRef(null), T = a.useRef([]), k = a.useRef(null), o = a.useCallback(
|
|
72
70
|
(e) => {
|
|
73
71
|
var l;
|
|
74
|
-
const t = Math.max(0, Math.min(e,
|
|
72
|
+
const t = Math.max(0, Math.min(e, u - 1));
|
|
75
73
|
(l = T.current[t]) == null || l.focus();
|
|
76
74
|
},
|
|
77
|
-
[
|
|
78
|
-
), p =
|
|
75
|
+
[u]
|
|
76
|
+
), p = a.useCallback(
|
|
79
77
|
(e, t) => {
|
|
80
|
-
const l = e.padEnd(
|
|
81
|
-
l !== n && (O.current = l,
|
|
78
|
+
const l = e.padEnd(u, " ").slice(0, u);
|
|
79
|
+
l !== n && (O.current = l, I || ee(l), M && M({
|
|
82
80
|
syntheticEvent: t,
|
|
83
81
|
nativeEvent: t.nativeEvent,
|
|
84
82
|
target: k.current,
|
|
85
83
|
value: l
|
|
86
84
|
}));
|
|
87
85
|
},
|
|
88
|
-
[
|
|
89
|
-
), re =
|
|
86
|
+
[I, u, M, n]
|
|
87
|
+
), re = a.useCallback(
|
|
90
88
|
(e, t, l) => {
|
|
91
|
-
const
|
|
92
|
-
if (!
|
|
89
|
+
const r = l.target.value.slice(-1);
|
|
90
|
+
if (!r)
|
|
93
91
|
return;
|
|
94
|
-
if (h === "number" && !/^\d$/.test(
|
|
95
|
-
|
|
92
|
+
if (h === "number" && !/^\d$/.test(r)) {
|
|
93
|
+
g(e);
|
|
96
94
|
const b = n[e] === " " ? "" : n[e];
|
|
97
95
|
l.target.value = b, l.target.select();
|
|
98
96
|
return;
|
|
99
97
|
}
|
|
100
98
|
const i = O.current.split("");
|
|
101
|
-
i[e] =
|
|
99
|
+
i[e] = r;
|
|
102
100
|
const s = i.join("");
|
|
103
|
-
p(s, l),
|
|
101
|
+
p(s, l), o(e + 1);
|
|
104
102
|
},
|
|
105
|
-
[n, p,
|
|
106
|
-
),
|
|
103
|
+
[n, p, o, h, g]
|
|
104
|
+
), L = a.useCallback(
|
|
107
105
|
(e, t, l) => {
|
|
108
106
|
if (l.preventDefault(), h === "number" && !/^\d$/.test(t)) {
|
|
109
|
-
|
|
107
|
+
g(e), l.target.select();
|
|
110
108
|
return;
|
|
111
109
|
}
|
|
112
|
-
const
|
|
113
|
-
|
|
110
|
+
const c = n.split("");
|
|
111
|
+
c[e] = t, p(c.join(""), l), o(e + 1);
|
|
114
112
|
},
|
|
115
|
-
[h,
|
|
116
|
-
),
|
|
113
|
+
[h, g, n, p, o]
|
|
114
|
+
), ae = a.useCallback(
|
|
117
115
|
(e, t) => {
|
|
118
|
-
var
|
|
116
|
+
var c;
|
|
119
117
|
if (E)
|
|
120
118
|
return;
|
|
121
|
-
const l =
|
|
119
|
+
const l = F === "rtl";
|
|
122
120
|
switch (t.key) {
|
|
123
121
|
case "ArrowLeft": {
|
|
124
|
-
t.preventDefault(),
|
|
122
|
+
t.preventDefault(), o(l ? e + 1 : e - 1);
|
|
125
123
|
break;
|
|
126
124
|
}
|
|
127
125
|
case "ArrowRight": {
|
|
128
|
-
t.preventDefault(),
|
|
126
|
+
t.preventDefault(), o(l ? e - 1 : e + 1);
|
|
129
127
|
break;
|
|
130
128
|
}
|
|
131
129
|
case "ArrowUp":
|
|
@@ -135,25 +133,25 @@ const _e = r.forwardRef((f, d) => {
|
|
|
135
133
|
}
|
|
136
134
|
case "Backspace": {
|
|
137
135
|
t.preventDefault();
|
|
138
|
-
const
|
|
139
|
-
|
|
136
|
+
const r = n.split("");
|
|
137
|
+
r[e] = " ", p(r.join(""), t), o(e - 1);
|
|
140
138
|
break;
|
|
141
139
|
}
|
|
142
140
|
case "Delete": {
|
|
143
141
|
t.preventDefault();
|
|
144
|
-
const
|
|
145
|
-
|
|
142
|
+
const r = n.split("");
|
|
143
|
+
r[e] = " ", p(r.join(""), t);
|
|
146
144
|
break;
|
|
147
145
|
}
|
|
148
146
|
default: {
|
|
149
|
-
const { key:
|
|
150
|
-
|
|
147
|
+
const { key: r, ctrlKey: i, altKey: s, metaKey: b } = t, $ = (c = n[e]) != null ? c : " ";
|
|
148
|
+
r.length === 1 && !i && !s && !b && $ !== " " && L(e, r, t);
|
|
151
149
|
break;
|
|
152
150
|
}
|
|
153
151
|
}
|
|
154
152
|
},
|
|
155
|
-
[n, p,
|
|
156
|
-
),
|
|
153
|
+
[n, p, o, F, E, L]
|
|
154
|
+
), le = a.useCallback(
|
|
157
155
|
(e, t) => {
|
|
158
156
|
B && B({
|
|
159
157
|
syntheticEvent: t,
|
|
@@ -163,139 +161,139 @@ const _e = r.forwardRef((f, d) => {
|
|
|
163
161
|
});
|
|
164
162
|
},
|
|
165
163
|
[B]
|
|
166
|
-
),
|
|
167
|
-
}, []), { onFocus:
|
|
164
|
+
), ne = a.useCallback((e, t) => {
|
|
165
|
+
}, []), { onFocus: se, onBlur: ue } = pe({
|
|
168
166
|
onFocus: (e) => {
|
|
169
167
|
},
|
|
170
168
|
onBlur: (e) => {
|
|
171
|
-
|
|
169
|
+
K && K({
|
|
172
170
|
syntheticEvent: e,
|
|
173
171
|
nativeEvent: e.nativeEvent,
|
|
174
172
|
target: k.current
|
|
175
173
|
});
|
|
176
174
|
}
|
|
177
|
-
}), ce =
|
|
175
|
+
}), ce = a.useCallback(
|
|
178
176
|
(e) => {
|
|
179
177
|
if (e.preventDefault(), E)
|
|
180
178
|
return;
|
|
181
179
|
const t = e.clipboardData.getData("text");
|
|
182
180
|
if (!t)
|
|
183
181
|
return;
|
|
184
|
-
const l = T.current.findIndex((s) => s === document.activeElement),
|
|
182
|
+
const l = T.current.findIndex((s) => s === document.activeElement), c = l >= 0 ? l : 0;
|
|
185
183
|
if (h === "number" && !/^\d+$/.test(t.trim())) {
|
|
186
|
-
|
|
184
|
+
g(c);
|
|
187
185
|
return;
|
|
188
186
|
}
|
|
189
|
-
const
|
|
190
|
-
for (let s = 0; s < t.length &&
|
|
191
|
-
|
|
192
|
-
p(
|
|
193
|
-
const i = Math.min(
|
|
194
|
-
|
|
187
|
+
const r = n.split("");
|
|
188
|
+
for (let s = 0; s < t.length && c + s < u; s++)
|
|
189
|
+
r[c + s] = t[s];
|
|
190
|
+
p(r.join(""), e);
|
|
191
|
+
const i = Math.min(c + t.length, u - 1);
|
|
192
|
+
o(i);
|
|
195
193
|
},
|
|
196
|
-
[n, p,
|
|
194
|
+
[n, p, o, u, h, g, E]
|
|
197
195
|
);
|
|
198
|
-
|
|
196
|
+
a.useImperativeHandle(k, () => ({
|
|
199
197
|
get element() {
|
|
200
|
-
return
|
|
198
|
+
return z.current;
|
|
201
199
|
},
|
|
202
200
|
get value() {
|
|
203
201
|
return n;
|
|
204
202
|
},
|
|
205
203
|
focus(e) {
|
|
206
204
|
if (e !== void 0)
|
|
207
|
-
|
|
205
|
+
o(e);
|
|
208
206
|
else {
|
|
209
207
|
const t = n.indexOf(" ");
|
|
210
|
-
|
|
208
|
+
o(t >= 0 ? t : u - 1);
|
|
211
209
|
}
|
|
212
210
|
},
|
|
213
211
|
blur() {
|
|
214
212
|
T.current.forEach((e) => e == null ? void 0 : e.blur());
|
|
215
213
|
}
|
|
216
|
-
})),
|
|
217
|
-
const
|
|
218
|
-
const e = (
|
|
214
|
+
})), a.useImperativeHandle(f, () => k.current), de("otpinput", k, d, d.webMcp);
|
|
215
|
+
const oe = () => {
|
|
216
|
+
const e = (r) => {
|
|
219
217
|
var i;
|
|
220
|
-
return /* @__PURE__ */
|
|
221
|
-
|
|
218
|
+
return /* @__PURE__ */ a.createElement(
|
|
219
|
+
he,
|
|
222
220
|
{
|
|
223
|
-
key:
|
|
221
|
+
key: r,
|
|
224
222
|
ref: (s) => {
|
|
225
|
-
T.current[
|
|
223
|
+
T.current[r] = s;
|
|
226
224
|
},
|
|
227
|
-
index:
|
|
228
|
-
totalLength:
|
|
229
|
-
char: (i = n[
|
|
225
|
+
index: r,
|
|
226
|
+
totalLength: u,
|
|
227
|
+
char: (i = n[r]) != null ? i : " ",
|
|
230
228
|
type: h,
|
|
231
229
|
placeholder: H,
|
|
232
|
-
disabled:
|
|
230
|
+
disabled: P,
|
|
233
231
|
readOnly: E,
|
|
234
|
-
required:
|
|
232
|
+
required: q,
|
|
235
233
|
size: D,
|
|
236
|
-
fillMode:
|
|
237
|
-
rounded:
|
|
238
|
-
inputAttributes:
|
|
239
|
-
valid: A === !1 ||
|
|
234
|
+
fillMode: G,
|
|
235
|
+
rounded: U,
|
|
236
|
+
inputAttributes: S,
|
|
237
|
+
valid: A === !1 || te === r ? !1 : A,
|
|
240
238
|
onCellChange: re,
|
|
241
|
-
onCellKeyDown:
|
|
242
|
-
onCellFocus:
|
|
243
|
-
onCellBlur:
|
|
244
|
-
name: R ? `${R}-cell-${
|
|
245
|
-
id:
|
|
239
|
+
onCellKeyDown: ae,
|
|
240
|
+
onCellFocus: le,
|
|
241
|
+
onCellBlur: ne,
|
|
242
|
+
name: R ? `${R}-cell-${r}` : `otp-cell-${r}`,
|
|
243
|
+
id: V ? `${V}-cell-${r}` : `otp-cell-${r}`
|
|
246
244
|
}
|
|
247
245
|
);
|
|
248
246
|
};
|
|
249
247
|
if (!_) {
|
|
250
|
-
const
|
|
251
|
-
return
|
|
252
|
-
/* @__PURE__ */
|
|
253
|
-
] :
|
|
248
|
+
const r = Array.from({ length: u }, (i, s) => e(s));
|
|
249
|
+
return N === !1 ? [
|
|
250
|
+
/* @__PURE__ */ a.createElement("div", { key: "group", className: "k-input-group" }, r)
|
|
251
|
+
] : r;
|
|
254
252
|
}
|
|
255
|
-
const t =
|
|
253
|
+
const t = ve(u, _);
|
|
256
254
|
let l = 0;
|
|
257
|
-
const
|
|
258
|
-
return t.forEach((
|
|
255
|
+
const c = [];
|
|
256
|
+
return t.forEach((r, i) => {
|
|
259
257
|
const s = l;
|
|
260
|
-
i > 0 && w !== void 0 &&
|
|
258
|
+
i > 0 && w !== void 0 && c.push(/* @__PURE__ */ a.createElement(be, { key: `sep-${s}`, separator: w }));
|
|
261
259
|
const b = [];
|
|
262
|
-
for (let $ = 0; $ <
|
|
260
|
+
for (let $ = 0; $ < r; $++)
|
|
263
261
|
b.push(e(l++));
|
|
264
|
-
|
|
265
|
-
/* @__PURE__ */
|
|
266
|
-
) :
|
|
267
|
-
}),
|
|
268
|
-
},
|
|
262
|
+
N === !1 ? c.push(
|
|
263
|
+
/* @__PURE__ */ a.createElement("div", { key: `group-${s}`, className: "k-input-group" }, b)
|
|
264
|
+
) : c.push(...b);
|
|
265
|
+
}), c;
|
|
266
|
+
}, ie = fe(
|
|
269
267
|
"k-otp",
|
|
270
268
|
{
|
|
271
|
-
"k-disabled":
|
|
269
|
+
"k-disabled": P,
|
|
272
270
|
"k-invalid": A === !1,
|
|
273
|
-
[`k-otp-${
|
|
271
|
+
[`k-otp-${me.sizeMap[D] || D}`]: D
|
|
274
272
|
},
|
|
275
|
-
|
|
276
|
-
)
|
|
277
|
-
return /* @__PURE__ */
|
|
273
|
+
Y
|
|
274
|
+
);
|
|
275
|
+
return /* @__PURE__ */ a.createElement(
|
|
278
276
|
"div",
|
|
279
277
|
{
|
|
280
|
-
ref:
|
|
281
|
-
className:
|
|
278
|
+
ref: z,
|
|
279
|
+
className: ie,
|
|
282
280
|
role: "group",
|
|
283
|
-
"aria-label":
|
|
284
|
-
"aria-labelledby":
|
|
285
|
-
"aria-describedby":
|
|
286
|
-
id:
|
|
287
|
-
style:
|
|
288
|
-
dir:
|
|
289
|
-
onFocus:
|
|
281
|
+
"aria-label": W,
|
|
282
|
+
"aria-labelledby": J,
|
|
283
|
+
"aria-describedby": Q,
|
|
284
|
+
id: V,
|
|
285
|
+
style: X,
|
|
286
|
+
dir: F,
|
|
287
|
+
onFocus: se,
|
|
290
288
|
onBlur: ue,
|
|
291
289
|
onPaste: ce,
|
|
292
|
-
...
|
|
290
|
+
...Z
|
|
293
291
|
},
|
|
294
|
-
R && /* @__PURE__ */
|
|
295
|
-
|
|
292
|
+
R && /* @__PURE__ */ a.createElement("input", { "aria-hidden": !0, type: "hidden", name: R, value: n.replace(/ /g, "") }),
|
|
293
|
+
oe()
|
|
296
294
|
);
|
|
297
295
|
});
|
|
298
|
-
|
|
296
|
+
ge.displayName = "KendoReactOTPInput";
|
|
299
297
|
export {
|
|
300
|
-
|
|
298
|
+
ge as OTPInput
|
|
301
299
|
};
|
package/package-metadata.js
CHANGED
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=Object.freeze({name:"@progress/kendo-react-inputs",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate:
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=Object.freeze({name:"@progress/kendo-react-inputs",productName:"KendoReact",productCode:"KENDOUIREACT",productCodes:["KENDOUIREACT"],publishDate: 1785412073,version:"15.2.0-develop.2",licensingDocsUrl:"https://www.telerik.com/kendo-react-ui/components/my-license/"});exports.packageMetadata=e;
|
package/package-metadata.mjs
CHANGED
|
@@ -7,7 +7,7 @@ export const packageMetadata = Object.freeze({
|
|
|
7
7
|
productName: 'KendoReact',
|
|
8
8
|
productCode: 'KENDOUIREACT',
|
|
9
9
|
productCodes: ['KENDOUIREACT'],
|
|
10
|
-
publishDate:
|
|
11
|
-
version: '15.2.0-develop.
|
|
10
|
+
publishDate: 1785412073,
|
|
11
|
+
version: '15.2.0-develop.2',
|
|
12
12
|
licensingDocsUrl: 'https://www.telerik.com/kendo-react-ui/components/my-license/'
|
|
13
13
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@progress/kendo-react-inputs",
|
|
3
|
-
"version": "15.2.0-develop.
|
|
3
|
+
"version": "15.2.0-develop.2",
|
|
4
4
|
"description": "React Inputs offer a customizable interface for users to enter and pick different information. KendoReact Input package",
|
|
5
5
|
"author": "Progress",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
@@ -28,14 +28,14 @@
|
|
|
28
28
|
"@progress/kendo-drawing": "^1.21.2",
|
|
29
29
|
"@progress/kendo-inputs-common": "^3.1.0",
|
|
30
30
|
"@progress/kendo-licensing": "^1.7.2",
|
|
31
|
-
"@progress/kendo-react-animation": "15.2.0-develop.
|
|
32
|
-
"@progress/kendo-react-buttons": "15.2.0-develop.
|
|
33
|
-
"@progress/kendo-react-common": "15.2.0-develop.
|
|
34
|
-
"@progress/kendo-react-dialogs": "15.2.0-develop.
|
|
35
|
-
"@progress/kendo-react-layout": "15.2.0-develop.
|
|
36
|
-
"@progress/kendo-react-intl": "15.2.0-develop.
|
|
37
|
-
"@progress/kendo-react-labels": "15.2.0-develop.
|
|
38
|
-
"@progress/kendo-react-popup": "15.2.0-develop.
|
|
31
|
+
"@progress/kendo-react-animation": "15.2.0-develop.2",
|
|
32
|
+
"@progress/kendo-react-buttons": "15.2.0-develop.2",
|
|
33
|
+
"@progress/kendo-react-common": "15.2.0-develop.2",
|
|
34
|
+
"@progress/kendo-react-dialogs": "15.2.0-develop.2",
|
|
35
|
+
"@progress/kendo-react-layout": "15.2.0-develop.2",
|
|
36
|
+
"@progress/kendo-react-intl": "15.2.0-develop.2",
|
|
37
|
+
"@progress/kendo-react-labels": "15.2.0-develop.2",
|
|
38
|
+
"@progress/kendo-react-popup": "15.2.0-develop.2",
|
|
39
39
|
"@progress/kendo-svg-icons": "^4.9.0 || ^5.0.0",
|
|
40
40
|
"react": "^18.0.0 || ^19.0.0",
|
|
41
41
|
"react-dom": "^18.0.0 || ^19.0.0"
|
|
@@ -82,7 +82,7 @@
|
|
|
82
82
|
"package": {
|
|
83
83
|
"productName": "KendoReact",
|
|
84
84
|
"productCode": "KENDOUIREACT",
|
|
85
|
-
"publishDate":
|
|
85
|
+
"publishDate": 1785412073,
|
|
86
86
|
"licensingDocsUrl": "https://www.telerik.com/kendo-react-ui/components/my-license/"
|
|
87
87
|
}
|
|
88
88
|
},
|
|
@@ -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 M=require("react"),e=require("prop-types"),a=require("@progress/kendo-react-common");function K(
|
|
8
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const M=require("react"),e=require("prop-types"),a=require("@progress/kendo-react-common");function K(o){const s=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const l in o)if(l!=="default"){const c=Object.getOwnPropertyDescriptor(o,l);Object.defineProperty(s,l,c.get?c:{enumerable:!0,get:()=>o[l]})}}return s.default=o,Object.freeze(s)}const t=K(M),x=a.createPropsContext(),g=t.forwardRef((o,s)=>{const l=a.usePropsContext(x,o),{ariaDescribedBy:c,ariaLabel:F,checked:v,children:y,className:I,disabled:n,id:B,size:O=U.size,label:d,labelPlacement:j,name:q,style:z,tabIndex:S,value:b,valid:h,onChange:C,onFocus:m,onBlur:p,required:T,...D}=l,R=a.useUnstyled(),f=R&&R.uRadioButton,i=t.useRef(null),P=t.useCallback(()=>{i.current&&i.current.focus()},[]),u=t.useCallback(()=>({element:i.current,focus:P}),[P]);t.useImperativeHandle(s,u);const E=a.useId(),w=t.useCallback(r=>{a.dispatchEvent(C,r,u(),{value:b})},[C,b,n]),L=t.useCallback(r=>{m&&!n&&a.dispatchEvent(m,r,u(),void 0)},[m,n]),_=t.useCallback(r=>{p&&!n&&a.dispatchEvent(p,r,u(),void 0)},[p,n]),H={type:"radio",id:B||E,name:q,className:a.classNames(a.uRadioButton.input({c:f,size:O,disabled:n,invalid:h===!1,checked:v}),I),ref:i,disabled:n,tabIndex:a.getTabIndex(S,n),checked:v,style:z,"aria-describedby":c,"aria-label":F,"aria-required":T,"aria-invalid":h===!1?"true":void 0,value:b,onChange:w,onFocus:L,onBlur:_,...D},N=t.createElement(t.Fragment,null,d!==void 0?t.createElement("label",{className:a.classNames(a.uRadioButton.label({c:f})),htmlFor:B||E,style:{userSelect:"none"},"aria-label":d},d):null),k=t.createElement("span",{className:a.classNames(a.uRadioButton.wrap({c:f}))},t.createElement("input",{...H}));return j==="before"?t.createElement(t.Fragment,null,N,k,y):t.createElement(t.Fragment,null,k,N,y)});g.propTypes={ariaDescribedBy:e.string,ariaLabel:e.string,checked:e.bool,className:e.string,disabled:e.bool,id:e.string,size:e.oneOf(["small","medium","large"]),label:e.string,labelPlacement:e.string,name:e.string,style:e.object,tabIndex:e.number,value:e.any,valid:e.bool,onChange:e.func,onFocus:e.func,onBlur:e.func};const U={size:void 0};g.displayName="KendoRadioButton";exports.RadioButton=g;exports.RadioButtonPropsContext=x;
|
|
@@ -8,29 +8,29 @@
|
|
|
8
8
|
import * as e from "react";
|
|
9
9
|
import a from "prop-types";
|
|
10
10
|
import { usePropsContext as A, useUnstyled as G, useId as J, dispatchEvent as d, getTabIndex as M, classNames as m, uRadioButton as b, createPropsContext as Q } from "@progress/kendo-react-common";
|
|
11
|
-
const V = Q(),
|
|
12
|
-
const
|
|
13
|
-
ariaDescribedBy:
|
|
14
|
-
ariaLabel:
|
|
11
|
+
const V = Q(), E = e.forwardRef((F, I) => {
|
|
12
|
+
const P = A(V, F), {
|
|
13
|
+
ariaDescribedBy: k,
|
|
14
|
+
ariaLabel: N,
|
|
15
15
|
checked: p,
|
|
16
16
|
children: f,
|
|
17
|
-
className:
|
|
17
|
+
className: z,
|
|
18
18
|
disabled: n,
|
|
19
19
|
id: g,
|
|
20
|
-
size:
|
|
20
|
+
size: L = W.size,
|
|
21
21
|
label: o,
|
|
22
|
-
labelPlacement:
|
|
23
|
-
name:
|
|
24
|
-
style:
|
|
25
|
-
tabIndex:
|
|
22
|
+
labelPlacement: T,
|
|
23
|
+
name: q,
|
|
24
|
+
style: w,
|
|
25
|
+
tabIndex: D,
|
|
26
26
|
value: r,
|
|
27
|
-
valid:
|
|
27
|
+
valid: v,
|
|
28
28
|
onChange: h,
|
|
29
29
|
onFocus: c,
|
|
30
30
|
onBlur: i,
|
|
31
31
|
required: H,
|
|
32
32
|
...j
|
|
33
|
-
} =
|
|
33
|
+
} = P, y = G(), u = y && y.uRadioButton, l = e.useRef(null), C = e.useCallback(() => {
|
|
34
34
|
l.current && l.current.focus();
|
|
35
35
|
}, []), s = e.useCallback(
|
|
36
36
|
() => ({
|
|
@@ -39,8 +39,8 @@ const V = Q(), x = e.forwardRef((E, F) => {
|
|
|
39
39
|
}),
|
|
40
40
|
[C]
|
|
41
41
|
);
|
|
42
|
-
e.useImperativeHandle(
|
|
43
|
-
const
|
|
42
|
+
e.useImperativeHandle(I, s);
|
|
43
|
+
const B = J(), K = e.useCallback(
|
|
44
44
|
(t) => {
|
|
45
45
|
d(h, t, s(), {
|
|
46
46
|
value: r
|
|
@@ -64,43 +64,45 @@ const V = Q(), x = e.forwardRef((E, F) => {
|
|
|
64
64
|
[i, n]
|
|
65
65
|
), U = {
|
|
66
66
|
type: "radio",
|
|
67
|
-
id: g ||
|
|
68
|
-
name:
|
|
67
|
+
id: g || B,
|
|
68
|
+
name: q,
|
|
69
69
|
className: m(
|
|
70
70
|
b.input({
|
|
71
71
|
c: u,
|
|
72
|
-
size:
|
|
73
|
-
|
|
72
|
+
size: L,
|
|
73
|
+
disabled: n,
|
|
74
|
+
invalid: v === !1,
|
|
74
75
|
checked: p
|
|
75
76
|
}),
|
|
76
|
-
|
|
77
|
+
z
|
|
77
78
|
),
|
|
78
79
|
ref: l,
|
|
79
80
|
disabled: n,
|
|
80
|
-
tabIndex: M(
|
|
81
|
+
tabIndex: M(D, n),
|
|
81
82
|
checked: p,
|
|
82
|
-
style:
|
|
83
|
-
"aria-describedby":
|
|
84
|
-
"aria-label":
|
|
83
|
+
style: w,
|
|
84
|
+
"aria-describedby": k,
|
|
85
|
+
"aria-label": N,
|
|
85
86
|
"aria-required": H,
|
|
87
|
+
"aria-invalid": v === !1 ? "true" : void 0,
|
|
86
88
|
value: r,
|
|
87
89
|
onChange: K,
|
|
88
90
|
onFocus: O,
|
|
89
91
|
onBlur: S,
|
|
90
92
|
...j
|
|
91
|
-
},
|
|
93
|
+
}, R = /* @__PURE__ */ e.createElement(e.Fragment, null, o !== void 0 ? /* @__PURE__ */ e.createElement(
|
|
92
94
|
"label",
|
|
93
95
|
{
|
|
94
96
|
className: m(b.label({ c: u })),
|
|
95
|
-
htmlFor: g ||
|
|
97
|
+
htmlFor: g || B,
|
|
96
98
|
style: { userSelect: "none" },
|
|
97
99
|
"aria-label": o
|
|
98
100
|
},
|
|
99
101
|
o
|
|
100
|
-
) : null),
|
|
101
|
-
return
|
|
102
|
+
) : null), x = /* @__PURE__ */ e.createElement("span", { className: m(b.wrap({ c: u })) }, /* @__PURE__ */ e.createElement("input", { ...U }));
|
|
103
|
+
return T === "before" ? /* @__PURE__ */ e.createElement(e.Fragment, null, R, x, f) : /* @__PURE__ */ e.createElement(e.Fragment, null, x, R, f);
|
|
102
104
|
});
|
|
103
|
-
|
|
105
|
+
E.propTypes = {
|
|
104
106
|
ariaDescribedBy: a.string,
|
|
105
107
|
ariaLabel: a.string,
|
|
106
108
|
checked: a.bool,
|
|
@@ -122,8 +124,8 @@ x.propTypes = {
|
|
|
122
124
|
const W = {
|
|
123
125
|
size: void 0
|
|
124
126
|
};
|
|
125
|
-
|
|
127
|
+
E.displayName = "KendoRadioButton";
|
|
126
128
|
export {
|
|
127
|
-
|
|
129
|
+
E as RadioButton,
|
|
128
130
|
V as RadioButtonPropsContext
|
|
129
131
|
};
|