@progress/kendo-react-inputs 9.0.0-develop.9 → 9.0.0

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/index.d.mts CHANGED
@@ -1238,21 +1238,18 @@ declare interface HSVA {
1238
1238
  a?: number;
1239
1239
  }
1240
1240
 
1241
- /** @hidden */
1242
- export declare type Input = InputHandle;
1243
-
1244
1241
  /**
1245
1242
  * Represents the [KendoReact Input component]({% slug overview_textbox %}).
1246
1243
  *
1247
1244
  * Accepts properties of type [InputProps]({% slug api_inputs_inputprops %}).
1248
1245
  * Obtaining the `ref` returns an object of type [InputHandle]({% slug api_inputs_inputhandle %}).
1249
1246
  */
1250
- export declare const Input: React_2.ForwardRefExoticComponent<InputProps & React_2.RefAttributes<any>>;
1247
+ export declare const Input: React_2.ForwardRefExoticComponent<InputProps & React_2.RefAttributes<InputHandle | null>>;
1251
1248
 
1252
1249
  /**
1253
1250
  * The arguments for the `change` event of the Input.
1254
1251
  */
1255
- export declare interface InputChangeEvent extends BaseEvent<Input> {
1252
+ export declare interface InputChangeEvent extends BaseEvent<InputHandle> {
1256
1253
  /**
1257
1254
  * The current value of the Input.
1258
1255
  */
@@ -1282,9 +1279,9 @@ export declare interface InputClearValueProps extends React_2.HTMLAttributes<HTM
1282
1279
  }
1283
1280
 
1284
1281
  /**
1285
- * Represent the `ref` of the Input component.
1282
+ * Represent the `ref` target of the Input component.
1286
1283
  */
1287
- export declare interface InputHandle extends Pick<InputWithoutContext, keyof InputWithoutContext> {
1284
+ export declare interface InputHandle {
1288
1285
  /**
1289
1286
  * Gets the native input element of the Input component.
1290
1287
  */
@@ -1293,6 +1290,10 @@ export declare interface InputHandle extends Pick<InputWithoutContext, keyof Inp
1293
1290
  * Gets the `name` property of the Input.
1294
1291
  */
1295
1292
  name: string | undefined;
1293
+ /**
1294
+ *The props of the InputHandle component.
1295
+ */
1296
+ props: InputProps;
1296
1297
  /**
1297
1298
  * Represents the validity state into which the Input is set.
1298
1299
  */
@@ -1376,6 +1377,18 @@ export declare interface InputProps extends Omit_2<React_2.InputHTMLAttributes<H
1376
1377
  * @hidden
1377
1378
  */
1378
1379
  unstyled?: InputsClassStructure;
1380
+ /**
1381
+ * @hidden
1382
+ */
1383
+ visited?: boolean;
1384
+ /**
1385
+ * @hidden
1386
+ */
1387
+ touched?: boolean;
1388
+ /**
1389
+ * @hidden
1390
+ */
1391
+ modified?: boolean;
1379
1392
  }
1380
1393
 
1381
1394
  /**
@@ -1500,85 +1513,6 @@ export declare type InputValidationIconHandle = IconHandle & SvgIconHandle;
1500
1513
  */
1501
1514
  export declare type InputValidationIconProps = IconProps & SvgIconProps;
1502
1515
 
1503
- /** @hidden */
1504
- export declare class InputWithoutContext extends React_2.Component<InputProps, InputState> implements FormComponent {
1505
- static displayName: string;
1506
- /**
1507
- * @hidden
1508
- */
1509
- static propTypes: {
1510
- label: PropTypes.Requireable<string>;
1511
- labelClassName: PropTypes.Requireable<string>;
1512
- validationMessage: PropTypes.Requireable<string>;
1513
- required: PropTypes.Requireable<boolean>;
1514
- validate: PropTypes.Requireable<boolean>;
1515
- id: PropTypes.Requireable<string>;
1516
- ariaLabelledBy: PropTypes.Requireable<string>;
1517
- ariaDescribedBy: PropTypes.Requireable<string>;
1518
- ariaLabel: PropTypes.Requireable<string>;
1519
- autoFocus: PropTypes.Requireable<boolean>;
1520
- };
1521
- /**
1522
- * @hidden
1523
- */
1524
- static defaultProps: {
1525
- defaultValue: string;
1526
- required: boolean;
1527
- validityStyles: boolean;
1528
- autoFocus: boolean;
1529
- };
1530
- private _input;
1531
- private get _inputId();
1532
- private valueDuringOnChange?;
1533
- constructor(props: InputProps);
1534
- /**
1535
- * @hidden
1536
- */
1537
- focus: () => void;
1538
- /**
1539
- * Gets the native input element of the Input component.
1540
- */
1541
- get element(): HTMLInputElement | null;
1542
- /**
1543
- * Gets the value of the Input.
1544
- */
1545
- get value(): string | string[] | number | undefined;
1546
- /**
1547
- * Gets the `name` property of the Input.
1548
- */
1549
- get name(): string | undefined;
1550
- /**
1551
- * Represents the validity state into which the Input is set.
1552
- */
1553
- get validity(): FormComponentValidity;
1554
- /**
1555
- * @hidden
1556
- */
1557
- protected get validityStyles(): boolean;
1558
- /**
1559
- * @hidden
1560
- */
1561
- componentDidMount(): void;
1562
- /**
1563
- * @hidden
1564
- */
1565
- componentDidUpdate(): void;
1566
- /**
1567
- * @hidden
1568
- */
1569
- render(): JSX_2.Element;
1570
- protected isInvalid: (state: Object) => boolean;
1571
- /**
1572
- * @hidden
1573
- */
1574
- protected setValidity: () => void;
1575
- private handleChange;
1576
- /**
1577
- * @hidden
1578
- */
1579
- private handleAutoFill;
1580
- }
1581
-
1582
1516
  /**
1583
1517
  * @hidden
1584
1518
  */
package/index.d.ts CHANGED
@@ -1238,21 +1238,18 @@ declare interface HSVA {
1238
1238
  a?: number;
1239
1239
  }
1240
1240
 
1241
- /** @hidden */
1242
- export declare type Input = InputHandle;
1243
-
1244
1241
  /**
1245
1242
  * Represents the [KendoReact Input component]({% slug overview_textbox %}).
1246
1243
  *
1247
1244
  * Accepts properties of type [InputProps]({% slug api_inputs_inputprops %}).
1248
1245
  * Obtaining the `ref` returns an object of type [InputHandle]({% slug api_inputs_inputhandle %}).
1249
1246
  */
1250
- export declare const Input: React_2.ForwardRefExoticComponent<InputProps & React_2.RefAttributes<any>>;
1247
+ export declare const Input: React_2.ForwardRefExoticComponent<InputProps & React_2.RefAttributes<InputHandle | null>>;
1251
1248
 
1252
1249
  /**
1253
1250
  * The arguments for the `change` event of the Input.
1254
1251
  */
1255
- export declare interface InputChangeEvent extends BaseEvent<Input> {
1252
+ export declare interface InputChangeEvent extends BaseEvent<InputHandle> {
1256
1253
  /**
1257
1254
  * The current value of the Input.
1258
1255
  */
@@ -1282,9 +1279,9 @@ export declare interface InputClearValueProps extends React_2.HTMLAttributes<HTM
1282
1279
  }
1283
1280
 
1284
1281
  /**
1285
- * Represent the `ref` of the Input component.
1282
+ * Represent the `ref` target of the Input component.
1286
1283
  */
1287
- export declare interface InputHandle extends Pick<InputWithoutContext, keyof InputWithoutContext> {
1284
+ export declare interface InputHandle {
1288
1285
  /**
1289
1286
  * Gets the native input element of the Input component.
1290
1287
  */
@@ -1293,6 +1290,10 @@ export declare interface InputHandle extends Pick<InputWithoutContext, keyof Inp
1293
1290
  * Gets the `name` property of the Input.
1294
1291
  */
1295
1292
  name: string | undefined;
1293
+ /**
1294
+ *The props of the InputHandle component.
1295
+ */
1296
+ props: InputProps;
1296
1297
  /**
1297
1298
  * Represents the validity state into which the Input is set.
1298
1299
  */
@@ -1376,6 +1377,18 @@ export declare interface InputProps extends Omit_2<React_2.InputHTMLAttributes<H
1376
1377
  * @hidden
1377
1378
  */
1378
1379
  unstyled?: InputsClassStructure;
1380
+ /**
1381
+ * @hidden
1382
+ */
1383
+ visited?: boolean;
1384
+ /**
1385
+ * @hidden
1386
+ */
1387
+ touched?: boolean;
1388
+ /**
1389
+ * @hidden
1390
+ */
1391
+ modified?: boolean;
1379
1392
  }
1380
1393
 
1381
1394
  /**
@@ -1500,85 +1513,6 @@ export declare type InputValidationIconHandle = IconHandle & SvgIconHandle;
1500
1513
  */
1501
1514
  export declare type InputValidationIconProps = IconProps & SvgIconProps;
1502
1515
 
1503
- /** @hidden */
1504
- export declare class InputWithoutContext extends React_2.Component<InputProps, InputState> implements FormComponent {
1505
- static displayName: string;
1506
- /**
1507
- * @hidden
1508
- */
1509
- static propTypes: {
1510
- label: PropTypes.Requireable<string>;
1511
- labelClassName: PropTypes.Requireable<string>;
1512
- validationMessage: PropTypes.Requireable<string>;
1513
- required: PropTypes.Requireable<boolean>;
1514
- validate: PropTypes.Requireable<boolean>;
1515
- id: PropTypes.Requireable<string>;
1516
- ariaLabelledBy: PropTypes.Requireable<string>;
1517
- ariaDescribedBy: PropTypes.Requireable<string>;
1518
- ariaLabel: PropTypes.Requireable<string>;
1519
- autoFocus: PropTypes.Requireable<boolean>;
1520
- };
1521
- /**
1522
- * @hidden
1523
- */
1524
- static defaultProps: {
1525
- defaultValue: string;
1526
- required: boolean;
1527
- validityStyles: boolean;
1528
- autoFocus: boolean;
1529
- };
1530
- private _input;
1531
- private get _inputId();
1532
- private valueDuringOnChange?;
1533
- constructor(props: InputProps);
1534
- /**
1535
- * @hidden
1536
- */
1537
- focus: () => void;
1538
- /**
1539
- * Gets the native input element of the Input component.
1540
- */
1541
- get element(): HTMLInputElement | null;
1542
- /**
1543
- * Gets the value of the Input.
1544
- */
1545
- get value(): string | string[] | number | undefined;
1546
- /**
1547
- * Gets the `name` property of the Input.
1548
- */
1549
- get name(): string | undefined;
1550
- /**
1551
- * Represents the validity state into which the Input is set.
1552
- */
1553
- get validity(): FormComponentValidity;
1554
- /**
1555
- * @hidden
1556
- */
1557
- protected get validityStyles(): boolean;
1558
- /**
1559
- * @hidden
1560
- */
1561
- componentDidMount(): void;
1562
- /**
1563
- * @hidden
1564
- */
1565
- componentDidUpdate(): void;
1566
- /**
1567
- * @hidden
1568
- */
1569
- render(): JSX_2.Element;
1570
- protected isInvalid: (state: Object) => boolean;
1571
- /**
1572
- * @hidden
1573
- */
1574
- protected setValidity: () => void;
1575
- private handleChange;
1576
- /**
1577
- * @hidden
1578
- */
1579
- private handleAutoFill;
1580
- }
1581
-
1582
1516
  /**
1583
1517
  * @hidden
1584
1518
  */
package/index.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 client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const g=require("./colors/ColorInput.js"),t=require("./messages/index.js"),o=require("./colors/ColorGradient.js"),r=require("./colors/ColorPalette.js"),q=require("./colors/models/palette-presets.js"),i=require("./colors/ColorPicker.js"),h=require("./colors/FlatColorPicker.js"),n=require("./input/Input.js"),u=require("./maskedtextbox/MaskedTextBox.js"),B=require("./maskedtextbox/utils.js"),a=require("./numerictextbox/NumericTextBox.js"),s=require("./slider/Slider.js"),x=require("./slider/SliderLabel.js"),k=require("./numerictextbox/utils/index.js"),c=require("./range-slider/range-raducer.js"),C=require("./range-slider/RangeSlider.js"),l=require("./switch/Switch.js"),p=require("./checkbox/Checkbox.js"),d=require("./radiobutton/RadioGroup.js"),P=require("./radiobutton/RadioButton.js"),I=require("./textarea/TextArea.js"),R=require("./rating/Rating.js"),A=require("./rating/RatingItem.js"),S=require("./rating/rating-reducer.js"),e=require("./rating/utils/index.js"),T=require("./signature/Signature.js"),m=require("./textbox/Textbox.js"),E=require("./input/InputClearValue.js"),G=require("./input/InputPrefix.js"),N=require("./input/InputSeparator.js"),b=require("./input/InputSuffix.js"),f=require("./input/InputValidationIcon.js");exports.ColorInput=g;exports.inputsMessages=t.messages;exports.numericDecreaseValue=t.numericDecreaseValue;exports.numericIncreaseValue=t.numericIncreaseValue;exports.ColorGradient=o.ColorGradient;exports.ColorGradientPropsContext=o.ColorGradientPropsContext;exports.ColorGradientWithoutContext=o.ColorGradientWithoutContext;exports.ColorPalette=r.ColorPalette;exports.ColorPalettePropsContext=r.ColorPalettePropsContext;exports.ColorPaletteWithoutContext=r.ColorPaletteWithoutContext;exports.PALETTEPRESETS=q.PALETTEPRESETS;exports.ColorPicker=i.ColorPicker;exports.ColorPickerPropsContext=i.ColorPickerPropsContext;exports.FlatColorPicker=h.FlatColorPicker;exports.Input=n.Input;exports.InputPropsContext=n.InputPropsContext;exports.InputWithoutContext=n.InputWithoutContext;exports.MaskedTextBox=u.MaskedTextBox;exports.MaskedTextBoxWithoutContext=u.MaskedTextBoxWithoutContext;exports.maskingChanged=B.maskingChanged;exports.NumericTextBox=a.NumericTextBox;exports.NumericTextBoxPropsContext=a.NumericTextBoxPropsContext;exports.Slider=s.Slider;exports.SliderWithoutContext=s.SliderWithoutContext;exports.SLIDER_LABEL_ATTRIBUTE=x.SLIDER_LABEL_ATTRIBUTE;exports.SliderLabel=x.SliderLabel;exports.sanitizeNumber=k.sanitizeNumber;exports.RANGE_ACTION=c.RANGE_ACTION;exports.rangeReducer=c.rangeReducer;exports.RangeSlider=C.RangeSlider;exports.RangeSliderPropsContext=C.RangeSliderPropsContext;exports.Switch=l.Switch;exports.SwitchWithoutContext=l.SwitchWithoutContext;exports.Checkbox=p.Checkbox;exports.CheckboxPropsContext=p.CheckboxPropsContext;exports.RadioGroup=d.RadioGroup;exports.RadioGroupPropsContext=d.RadioGroupPropsContext;exports.RadioButton=P.RadioButton;exports.RadioButtonPropsContext=P.RadioButtonPropsContext;exports.TextArea=I.TextArea;exports.TextAreaPropsContext=I.TextAreaPropsContext;exports.Rating=R.Rating;exports.RatingPropsContext=R.RatingPropsContext;exports.RatingItem=A.RatingItem;exports.RATING_ACTION=S.RATING_ACTION;exports.ratingReducer=S.ratingReducer;exports.isCorrectValue=e.isCorrectValue;exports.isHalf=e.isHalf;exports.isSelected=e.isSelected;exports.toRound=e.toRound;exports.Signature=T.Signature;exports.SignaturePropsContext=T.SignaturePropsContext;exports.TextBox=m.TextBox;exports.InputClearValue=E.InputClearValue;exports.InputPrefix=G.InputPrefix;exports.InputSeparator=N.InputSeparator;exports.InputSuffix=b.InputSuffix;exports.InputValidationIcon=f.InputValidationIcon;
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const g=require("./colors/ColorInput.js"),t=require("./messages/index.js"),o=require("./colors/ColorGradient.js"),r=require("./colors/ColorPalette.js"),q=require("./colors/models/palette-presets.js"),n=require("./colors/ColorPicker.js"),h=require("./colors/FlatColorPicker.js"),i=require("./input/Input.js"),u=require("./maskedtextbox/MaskedTextBox.js"),B=require("./maskedtextbox/utils.js"),a=require("./numerictextbox/NumericTextBox.js"),s=require("./slider/Slider.js"),c=require("./slider/SliderLabel.js"),k=require("./numerictextbox/utils/index.js"),x=require("./range-slider/range-raducer.js"),l=require("./range-slider/RangeSlider.js"),C=require("./switch/Switch.js"),p=require("./checkbox/Checkbox.js"),d=require("./radiobutton/RadioGroup.js"),P=require("./radiobutton/RadioButton.js"),R=require("./textarea/TextArea.js"),I=require("./rating/Rating.js"),A=require("./rating/RatingItem.js"),S=require("./rating/rating-reducer.js"),e=require("./rating/utils/index.js"),T=require("./signature/Signature.js"),m=require("./textbox/Textbox.js"),E=require("./input/InputClearValue.js"),G=require("./input/InputPrefix.js"),N=require("./input/InputSeparator.js"),b=require("./input/InputSuffix.js"),f=require("./input/InputValidationIcon.js");exports.ColorInput=g;exports.inputsMessages=t.messages;exports.numericDecreaseValue=t.numericDecreaseValue;exports.numericIncreaseValue=t.numericIncreaseValue;exports.ColorGradient=o.ColorGradient;exports.ColorGradientPropsContext=o.ColorGradientPropsContext;exports.ColorGradientWithoutContext=o.ColorGradientWithoutContext;exports.ColorPalette=r.ColorPalette;exports.ColorPalettePropsContext=r.ColorPalettePropsContext;exports.ColorPaletteWithoutContext=r.ColorPaletteWithoutContext;exports.PALETTEPRESETS=q.PALETTEPRESETS;exports.ColorPicker=n.ColorPicker;exports.ColorPickerPropsContext=n.ColorPickerPropsContext;exports.FlatColorPicker=h.FlatColorPicker;exports.Input=i.Input;exports.InputPropsContext=i.InputPropsContext;exports.MaskedTextBox=u.MaskedTextBox;exports.MaskedTextBoxWithoutContext=u.MaskedTextBoxWithoutContext;exports.maskingChanged=B.maskingChanged;exports.NumericTextBox=a.NumericTextBox;exports.NumericTextBoxPropsContext=a.NumericTextBoxPropsContext;exports.Slider=s.Slider;exports.SliderWithoutContext=s.SliderWithoutContext;exports.SLIDER_LABEL_ATTRIBUTE=c.SLIDER_LABEL_ATTRIBUTE;exports.SliderLabel=c.SliderLabel;exports.sanitizeNumber=k.sanitizeNumber;exports.RANGE_ACTION=x.RANGE_ACTION;exports.rangeReducer=x.rangeReducer;exports.RangeSlider=l.RangeSlider;exports.RangeSliderPropsContext=l.RangeSliderPropsContext;exports.Switch=C.Switch;exports.SwitchWithoutContext=C.SwitchWithoutContext;exports.Checkbox=p.Checkbox;exports.CheckboxPropsContext=p.CheckboxPropsContext;exports.RadioGroup=d.RadioGroup;exports.RadioGroupPropsContext=d.RadioGroupPropsContext;exports.RadioButton=P.RadioButton;exports.RadioButtonPropsContext=P.RadioButtonPropsContext;exports.TextArea=R.TextArea;exports.TextAreaPropsContext=R.TextAreaPropsContext;exports.Rating=I.Rating;exports.RatingPropsContext=I.RatingPropsContext;exports.RatingItem=A.RatingItem;exports.RATING_ACTION=S.RATING_ACTION;exports.ratingReducer=S.ratingReducer;exports.isCorrectValue=e.isCorrectValue;exports.isHalf=e.isHalf;exports.isSelected=e.isSelected;exports.toRound=e.toRound;exports.Signature=T.Signature;exports.SignaturePropsContext=T.SignaturePropsContext;exports.TextBox=m.TextBox;exports.InputClearValue=E.InputClearValue;exports.InputPrefix=G.InputPrefix;exports.InputSeparator=N.InputSeparator;exports.InputSuffix=b.InputSuffix;exports.InputValidationIcon=f.InputValidationIcon;
package/index.mjs CHANGED
@@ -11,36 +11,36 @@ import { messages as x, numericDecreaseValue as p, numericIncreaseValue as n } f
11
11
  import { ColorGradient as i, ColorGradientPropsContext as m, ColorGradientWithoutContext as f } from "./colors/ColorGradient.mjs";
12
12
  import { ColorPalette as C, ColorPalettePropsContext as s, ColorPaletteWithoutContext as l } from "./colors/ColorPalette.mjs";
13
13
  import { PALETTEPRESETS as P } from "./colors/models/palette-presets.mjs";
14
- import { ColorPicker as I, ColorPickerPropsContext as R } from "./colors/ColorPicker.mjs";
14
+ import { ColorPicker as R, ColorPickerPropsContext as I } from "./colors/ColorPicker.mjs";
15
15
  import { FlatColorPicker as S } from "./colors/FlatColorPicker.mjs";
16
- import { Input as h, InputPropsContext as A, InputWithoutContext as B } from "./input/Input.mjs";
17
- import { MaskedTextBox as E, MaskedTextBoxWithoutContext as G } from "./maskedtextbox/MaskedTextBox.mjs";
18
- import { maskingChanged as W } from "./maskedtextbox/utils.mjs";
19
- import { NumericTextBox as V, NumericTextBoxPropsContext as b } from "./numerictextbox/NumericTextBox.mjs";
20
- import { Slider as M, SliderWithoutContext as w } from "./slider/Slider.mjs";
21
- import { SLIDER_LABEL_ATTRIBUTE as O, SliderLabel as z } from "./slider/SliderLabel.mjs";
22
- import { sanitizeNumber as H } from "./numerictextbox/utils/index.mjs";
23
- import { RANGE_ACTION as j, rangeReducer as q } from "./range-slider/range-raducer.mjs";
24
- import { RangeSlider as y, RangeSliderPropsContext as J } from "./range-slider/RangeSlider.mjs";
25
- import { Switch as Q, SwitchWithoutContext as X } from "./switch/Switch.mjs";
26
- import { Checkbox as Z, CheckboxPropsContext as $ } from "./checkbox/Checkbox.mjs";
27
- import { RadioGroup as to, RadioGroupPropsContext as eo } from "./radiobutton/RadioGroup.mjs";
28
- import { RadioButton as xo, RadioButtonPropsContext as po } from "./radiobutton/RadioButton.mjs";
29
- import { TextArea as ao, TextAreaPropsContext as io } from "./textarea/TextArea.mjs";
30
- import { Rating as fo, RatingPropsContext as uo } from "./rating/Rating.mjs";
31
- import { RatingItem as so } from "./rating/RatingItem.mjs";
32
- import { RATING_ACTION as Po, ratingReducer as co } from "./rating/rating-reducer.mjs";
33
- import { isCorrectValue as Ro, isHalf as To, isSelected as So, toRound as go } from "./rating/utils/index.mjs";
34
- import { Signature as Ao, SignaturePropsContext as Bo } from "./signature/Signature.mjs";
35
- import { TextBox as Eo } from "./textbox/Textbox.mjs";
36
- import { InputClearValue as No } from "./input/InputClearValue.mjs";
16
+ import { Input as h, InputPropsContext as A } from "./input/Input.mjs";
17
+ import { MaskedTextBox as k, MaskedTextBoxWithoutContext as E } from "./maskedtextbox/MaskedTextBox.mjs";
18
+ import { maskingChanged as N } from "./maskedtextbox/utils.mjs";
19
+ import { NumericTextBox as V, NumericTextBoxPropsContext as W } from "./numerictextbox/NumericTextBox.mjs";
20
+ import { Slider as _, SliderWithoutContext as M } from "./slider/Slider.mjs";
21
+ import { SLIDER_LABEL_ATTRIBUTE as D, SliderLabel as O } from "./slider/SliderLabel.mjs";
22
+ import { sanitizeNumber as F } from "./numerictextbox/utils/index.mjs";
23
+ import { RANGE_ACTION as U, rangeReducer as j } from "./range-slider/range-raducer.mjs";
24
+ import { RangeSlider as v, RangeSliderPropsContext as y } from "./range-slider/RangeSlider.mjs";
25
+ import { Switch as K, SwitchWithoutContext as Q } from "./switch/Switch.mjs";
26
+ import { Checkbox as Y, CheckboxPropsContext as Z } from "./checkbox/Checkbox.mjs";
27
+ import { RadioGroup as oo, RadioGroupPropsContext as to } from "./radiobutton/RadioGroup.mjs";
28
+ import { RadioButton as ro, RadioButtonPropsContext as xo } from "./radiobutton/RadioButton.mjs";
29
+ import { TextArea as no, TextAreaPropsContext as ao } from "./textarea/TextArea.mjs";
30
+ import { Rating as mo, RatingPropsContext as fo } from "./rating/Rating.mjs";
31
+ import { RatingItem as Co } from "./rating/RatingItem.mjs";
32
+ import { RATING_ACTION as lo, ratingReducer as Po } from "./rating/rating-reducer.mjs";
33
+ import { isCorrectValue as Ro, isHalf as Io, isSelected as To, toRound as So } from "./rating/utils/index.mjs";
34
+ import { Signature as ho, SignaturePropsContext as Ao } from "./signature/Signature.mjs";
35
+ import { TextBox as ko } from "./textbox/Textbox.mjs";
36
+ import { InputClearValue as Go } from "./input/InputClearValue.mjs";
37
37
  import { InputPrefix as Lo } from "./input/InputPrefix.mjs";
38
- import { InputSeparator as bo } from "./input/InputSeparator.mjs";
39
- import { InputSuffix as Mo } from "./input/InputSuffix.mjs";
40
- import { InputValidationIcon as Do } from "./input/InputValidationIcon.mjs";
38
+ import { InputSeparator as Wo } from "./input/InputSeparator.mjs";
39
+ import { InputSuffix as _o } from "./input/InputSuffix.mjs";
40
+ import { InputValidationIcon as wo } from "./input/InputValidationIcon.mjs";
41
41
  export {
42
- Z as Checkbox,
43
- $ as CheckboxPropsContext,
42
+ Y as Checkbox,
43
+ Z as CheckboxPropsContext,
44
44
  i as ColorGradient,
45
45
  m as ColorGradientPropsContext,
46
46
  f as ColorGradientWithoutContext,
@@ -48,53 +48,52 @@ export {
48
48
  C as ColorPalette,
49
49
  s as ColorPalettePropsContext,
50
50
  l as ColorPaletteWithoutContext,
51
- I as ColorPicker,
52
- R as ColorPickerPropsContext,
51
+ R as ColorPicker,
52
+ I as ColorPickerPropsContext,
53
53
  S as FlatColorPicker,
54
54
  h as Input,
55
- No as InputClearValue,
55
+ Go as InputClearValue,
56
56
  Lo as InputPrefix,
57
57
  A as InputPropsContext,
58
- bo as InputSeparator,
59
- Mo as InputSuffix,
60
- Do as InputValidationIcon,
61
- B as InputWithoutContext,
62
- E as MaskedTextBox,
63
- G as MaskedTextBoxWithoutContext,
58
+ Wo as InputSeparator,
59
+ _o as InputSuffix,
60
+ wo as InputValidationIcon,
61
+ k as MaskedTextBox,
62
+ E as MaskedTextBoxWithoutContext,
64
63
  V as NumericTextBox,
65
- b as NumericTextBoxPropsContext,
64
+ W as NumericTextBoxPropsContext,
66
65
  P as PALETTEPRESETS,
67
- j as RANGE_ACTION,
68
- Po as RATING_ACTION,
69
- xo as RadioButton,
70
- po as RadioButtonPropsContext,
71
- to as RadioGroup,
72
- eo as RadioGroupPropsContext,
73
- y as RangeSlider,
74
- J as RangeSliderPropsContext,
75
- fo as Rating,
76
- so as RatingItem,
77
- uo as RatingPropsContext,
78
- O as SLIDER_LABEL_ATTRIBUTE,
79
- Ao as Signature,
80
- Bo as SignaturePropsContext,
81
- M as Slider,
82
- z as SliderLabel,
83
- w as SliderWithoutContext,
84
- Q as Switch,
85
- X as SwitchWithoutContext,
86
- ao as TextArea,
87
- io as TextAreaPropsContext,
88
- Eo as TextBox,
66
+ U as RANGE_ACTION,
67
+ lo as RATING_ACTION,
68
+ ro as RadioButton,
69
+ xo as RadioButtonPropsContext,
70
+ oo as RadioGroup,
71
+ to as RadioGroupPropsContext,
72
+ v as RangeSlider,
73
+ y as RangeSliderPropsContext,
74
+ mo as Rating,
75
+ Co as RatingItem,
76
+ fo as RatingPropsContext,
77
+ D as SLIDER_LABEL_ATTRIBUTE,
78
+ ho as Signature,
79
+ Ao as SignaturePropsContext,
80
+ _ as Slider,
81
+ O as SliderLabel,
82
+ M as SliderWithoutContext,
83
+ K as Switch,
84
+ Q as SwitchWithoutContext,
85
+ no as TextArea,
86
+ ao as TextAreaPropsContext,
87
+ ko as TextBox,
89
88
  x as inputsMessages,
90
89
  Ro as isCorrectValue,
91
- To as isHalf,
92
- So as isSelected,
93
- W as maskingChanged,
90
+ Io as isHalf,
91
+ To as isSelected,
92
+ N as maskingChanged,
94
93
  p as numericDecreaseValue,
95
94
  n as numericIncreaseValue,
96
- q as rangeReducer,
97
- co as ratingReducer,
98
- H as sanitizeNumber,
99
- go as toRound
95
+ j as rangeReducer,
96
+ Po as ratingReducer,
97
+ F as sanitizeNumber,
98
+ So as toRound
100
99
  };
package/input/Input.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 client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const I=require("react"),a=require("prop-types"),l=require("@progress/kendo-react-common"),P=require("@progress/kendo-react-labels"),L=require("../package-metadata.js");function D(n){const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(n){for(const t in n)if(t!=="default"){const i=Object.getOwnPropertyDescriptor(n,t);Object.defineProperty(e,t,i.get?i:{enumerable:!0,get:()=>n[t]})}}return e.default=n,Object.freeze(e)}const h=D(I),s=class s extends h.Component{constructor(e){super(e),this._input=null,this.focus=()=>{this._input&&this._input.focus()},this.isInvalid=t=>{let i=!1;for(const r in t)t.hasOwnProperty(r)&&(i=i||!!t[r]);return i},this.setValidity=()=>{this._input&&this._input.setCustomValidity&&(this.validity.valid||!this.validityStyles?this._input.classList.remove("k-invalid"):this._input.classList.add("k-invalid"),this._input.setCustomValidity(this.validity.valid?"":this.props.validationMessage||""))},this.handleChange=t=>{this.setState({value:t.target.value}),this.valueDuringOnChange=t.target.value,this.props.onChange&&this.props.onChange.call(void 0,{syntheticEvent:t,nativeEvent:t.nativeEvent,value:t.target.value,target:this}),this.valueDuringOnChange=void 0},this.handleAutoFill=t=>{if(t.animationName==="autoFillStart"){const i=t.target.parentNode;i&&i.classList.contains("k-empty")&&i.classList.remove("k-empty")}},l.validatePackage(L.packageMetadata),this.state={value:this.props.defaultValue||s.defaultProps.defaultValue}}get _inputId(){return this.props.id}get element(){return this._input}get value(){return this.valueDuringOnChange!==void 0?this.valueDuringOnChange:this.props.value!==void 0?this.props.value:this.state.value}get name(){return this.props.name}get validity(){const e={badInput:this._input?this._input.validity.badInput:!1,patternMismatch:this._input?this._input.validity.patternMismatch:!1,rangeOverflow:this._input?this._input.validity.rangeOverflow:!1,rangeUnderflow:this._input?this._input.validity.rangeUnderflow:!1,stepMismatch:this._input?this._input.validity.stepMismatch:!1,tooLong:this._input?this._input.validity.tooLong:!1,typeMismatch:this._input?this._input.validity.typeMismatch:!1,valueMissing:this._input?this._input.validity.valueMissing:!1};return{...e,customError:this.props.validationMessage!==void 0,valid:this.props.valid!==void 0?this.props.valid:this._input?!this.isInvalid(e):!0}}get validityStyles(){return this.props.validityStyles!==void 0?this.props.validityStyles:s.defaultProps.validityStyles}componentDidMount(){this.forceUpdate()}componentDidUpdate(){this.setValidity()}render(){const{className:e,label:t,labelClassName:i,id:r,validationMessage:N,defaultValue:V,valid:k,unstyled:u,visited:w,touched:q,modified:F,autoFocus:m,ariaLabelledBy:b,ariaDescribedBy:_,validityStyles:E,style:c,ariaLabel:C,...o}=this.props,v=r||this._inputId,p=!this.validityStyles||this.validity.valid,M=u&&u.uInput,S=l.classNames(e,l.uInput.input({c:M,invalid:!p,disabled:this.props.disabled})),y=h.createElement("input",{"aria-labelledby":b,"aria-describedby":_,"aria-disabled":this.props.disabled||void 0,"aria-invalid":!p||void 0,"aria-label":C||void 0,...o,style:t?void 0:c,value:this.value,id:v,autoFocus:m,className:S,onChange:this.handleChange,onAnimationStart:this.handleAutoFill,ref:O=>{this._input=O}});return t?h.createElement(P.FloatingLabel,{label:t,labelClassName:i,editorId:v,editorValue:String(this.value),editorValid:p,editorDisabled:o.disabled,editorPlaceholder:o.placeholder,children:y,style:c,dir:o.dir,unstyled:u}):y}};s.displayName="Input",s.propTypes={label:a.string,labelClassName:a.string,validationMessage:a.string,required:a.bool,validate:a.bool,id:a.string,ariaLabelledBy:a.string,ariaDescribedBy:a.string,ariaLabel:a.string,autoFocus:a.bool},s.defaultProps={defaultValue:"",required:!1,validityStyles:!0,autoFocus:!1};let d=s;const g=l.createPropsContext(),f=l.withIdHOC(l.withPropsContext(g,l.withUnstyledHOC(d)));f.displayName="KendoReactInput";exports.Input=f;exports.InputPropsContext=g;exports.InputWithoutContext=d;
8
+ "use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const W=require("react"),a=require("prop-types"),l=require("@progress/kendo-react-common"),X=require("@progress/kendo-react-labels"),Y=require("../package-metadata.js");function Z(i){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(i){for(const u in i)if(u!=="default"){const c=Object.getOwnPropertyDescriptor(i,u);Object.defineProperty(o,u,c.get?c:{enumerable:!0,get:()=>i[u]})}}return o.default=i,Object.freeze(o)}const r=Z(W),b=r.forwardRef((i,o)=>{const c=r.useContext(R).call(void 0,i);l.validatePackage(Y.packageMetadata);const[,N]=r.useReducer(t=>t,!0),n=l.applyDefaultProps(c,$),{className:x,label:p,labelClassName:E,id:S,validationMessage:m,defaultValue:V,valid:h,unstyled:C,visited:ee,touched:te,modified:ae,autoFocus:q,ariaLabelledBy:w,ariaDescribedBy:D,validityStyles:I,style:P,ariaLabel:F,...U}=n,j=l.useUnstyled(),M=C||j,B=M&&M.uInput,T=l.useId(),[_,A]=r.useState({value:V}),k=S||T,e=r.useRef(null),d=r.useRef(void 0),f=r.useRef(null),G=()=>{e.current&&e.current.focus()},y=()=>d.current!==void 0?d.current:n.value!==void 0?n.value:_.value,v=()=>{const t={badInput:e.current?e.current.validity.badInput:!1,patternMismatch:e.current?e.current.validity.patternMismatch:!1,rangeOverflow:e.current?e.current.validity.rangeOverflow:!1,rangeUnderflow:e.current?e.current.validity.rangeUnderflow:!1,stepMismatch:e.current?e.current.validity.stepMismatch:!1,tooLong:e.current?e.current.validity.tooLong:!1,typeMismatch:e.current?e.current.validity.typeMismatch:!1,valueMissing:e.current?e.current.validity.valueMissing:!1};return{...t,customError:m!==void 0,valid:h!==void 0?h:e.current?!H(t):!0}};r.useImperativeHandle(f,()=>({element:e.current,props:n,get value(){return y()},name:n.name,get validity(){return v()},focus:G})),r.useImperativeHandle(o,()=>f.current);const H=t=>{let s=!1;for(const O in t)t.hasOwnProperty(O)&&(s=s||!!t[O]);return s},g=!I||v().valid,z=l.classNames(x,l.uInput.input({c:B,invalid:!g,disabled:n.disabled})),K=()=>{e.current&&e.current.setCustomValidity&&(v().valid||!I?e.current.classList.remove("k-invalid"):e.current.classList.add("k-invalid"),e.current.setCustomValidity(v().valid?"":m||""))},J=t=>{A({value:t.target.value}),d.current=t.target.value,n.onChange&&n.onChange.call(void 0,{syntheticEvent:t,nativeEvent:t.nativeEvent,value:t.target.value,target:f.current}),d.current=void 0},Q=t=>{if(t.animationName==="autoFillStart"){const s=t.target.parentNode;s&&s.classList.contains("k-empty")&&s.classList.remove("k-empty")}};r.useEffect(()=>{N()},[]),r.useEffect(()=>{K()});const L=r.createElement("input",{"aria-labelledby":w,"aria-describedby":D,"aria-disabled":n.disabled||void 0,"aria-invalid":!g||void 0,"aria-label":F||void 0,...U,style:p?void 0:P,value:y(),id:k,autoFocus:q,className:z,onChange:J,onAnimationStart:Q,ref:e});return p?r.createElement(X.FloatingLabel,{label:p,labelClassName:E,editorId:k,editorValue:String(y()),editorValid:g,editorDisabled:n.disabled,editorPlaceholder:n.placeholder,children:L,style:P,dir:n.dir,unstyled:C}):L}),R=l.createPropsContext(),$={defaultValue:"",required:!1,validityStyles:!0,autoFocus:!1};b.displayName="KendoReactInput";b.propTypes={label:a.string,labelClassName:a.string,validationMessage:a.string,required:a.bool,validate:a.bool,id:a.string,ariaLabelledBy:a.string,ariaDescribedBy:a.string,ariaLabel:a.string,autoFocus:a.bool,value:a.oneOfType([a.string,a.number,a.array])};exports.Input=b;exports.InputPropsContext=R;