@progress/kendo-vue-inputs 3.3.4 → 3.3.5-dev.202206141337

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.
Files changed (100) hide show
  1. package/dist/cdn/js/kendo-vue-inputs.js +1 -1
  2. package/dist/es/additionalTypes.ts +11 -0
  3. package/dist/es/checkbox/Checkbox.d.ts +7 -1
  4. package/dist/es/checkbox/Checkbox.js +8 -0
  5. package/dist/es/colors/ColorPalette.d.ts +6 -0
  6. package/dist/es/colors/ColorPalette.js +8 -1
  7. package/dist/es/colors/ColorPicker.d.ts +6 -0
  8. package/dist/es/colors/ColorPicker.js +8 -1
  9. package/dist/es/colors/Picker.d.ts +6 -0
  10. package/dist/es/colors/Picker.js +8 -1
  11. package/dist/es/colors/interfaces/ColorPaletteChangeEvent.d.ts +3 -0
  12. package/dist/es/colors/interfaces/ColorPaletteProps.d.ts +4 -13
  13. package/dist/es/colors/interfaces/ColorPickerActiveColorClick.d.ts +3 -0
  14. package/dist/es/colors/interfaces/ColorPickerBlurEvent.d.ts +3 -0
  15. package/dist/es/colors/interfaces/ColorPickerChangeEvent.d.ts +3 -0
  16. package/dist/es/colors/interfaces/ColorPickerFocusEvent.d.ts +3 -0
  17. package/dist/es/colors/interfaces/ColorPickerPaletteSettings.d.ts +3 -0
  18. package/dist/es/colors/interfaces/ColorPickerPopupSettings.d.ts +3 -0
  19. package/dist/es/colors/interfaces/ColorPickerProps.d.ts +5 -2
  20. package/dist/es/colors/interfaces/ColorPickerView.d.ts +3 -0
  21. package/dist/es/input/Input.d.ts +19 -9
  22. package/dist/es/input/Input.js +19 -3
  23. package/dist/es/input-separator/InputSeparator.d.ts +19 -0
  24. package/dist/es/input-separator/InputSeparator.js +35 -0
  25. package/dist/es/main.d.ts +1 -0
  26. package/dist/es/main.js +1 -0
  27. package/dist/es/maskedtextbox/MaskedTextBox.d.ts +4 -1
  28. package/dist/es/maskedtextbox/MaskedTextBox.js +95 -20
  29. package/dist/es/maskedtextbox/MaskedTextBoxProps.d.ts +32 -0
  30. package/dist/es/numerictextbox/NumericTextBox.d.ts +6 -0
  31. package/dist/es/numerictextbox/NumericTextBox.js +101 -8
  32. package/dist/es/numerictextbox/interfaces/NumericTextBoxProps.d.ts +43 -3
  33. package/dist/es/package-metadata.js +1 -1
  34. package/dist/es/radiobutton/RadioButton.d.ts +7 -1
  35. package/dist/es/radiobutton/RadioButton.js +8 -0
  36. package/dist/es/radiobutton/RadioGroup.d.ts +7 -1
  37. package/dist/es/radiobutton/RadioGroup.js +8 -0
  38. package/dist/es/range-slider/RangeSlider.d.ts +8 -0
  39. package/dist/es/range-slider/RangeSlider.js +10 -0
  40. package/dist/es/slider/Slider.d.ts +8 -2
  41. package/dist/es/slider/Slider.js +8 -0
  42. package/dist/es/slider/SliderLabel.d.ts +8 -0
  43. package/dist/es/slider/SliderLabel.js +10 -1
  44. package/dist/es/switch/Switch.d.ts +8 -0
  45. package/dist/es/switch/Switch.js +10 -1
  46. package/dist/es/textarea/TextArea.d.ts +36 -0
  47. package/dist/es/textarea/TextArea.js +113 -28
  48. package/dist/es/textarea/interfaces/TextAreaProps.d.ts +39 -0
  49. package/dist/npm/additionalTypes.ts +11 -0
  50. package/dist/npm/checkbox/Checkbox.d.ts +7 -1
  51. package/dist/npm/checkbox/Checkbox.js +8 -0
  52. package/dist/npm/colors/ColorPalette.d.ts +6 -0
  53. package/dist/npm/colors/ColorPalette.js +8 -1
  54. package/dist/npm/colors/ColorPicker.d.ts +6 -0
  55. package/dist/npm/colors/ColorPicker.js +8 -1
  56. package/dist/npm/colors/Picker.d.ts +6 -0
  57. package/dist/npm/colors/Picker.js +8 -1
  58. package/dist/npm/colors/interfaces/ColorPaletteChangeEvent.d.ts +3 -0
  59. package/dist/npm/colors/interfaces/ColorPaletteProps.d.ts +4 -13
  60. package/dist/npm/colors/interfaces/ColorPickerActiveColorClick.d.ts +3 -0
  61. package/dist/npm/colors/interfaces/ColorPickerBlurEvent.d.ts +3 -0
  62. package/dist/npm/colors/interfaces/ColorPickerChangeEvent.d.ts +3 -0
  63. package/dist/npm/colors/interfaces/ColorPickerFocusEvent.d.ts +3 -0
  64. package/dist/npm/colors/interfaces/ColorPickerPaletteSettings.d.ts +3 -0
  65. package/dist/npm/colors/interfaces/ColorPickerPopupSettings.d.ts +3 -0
  66. package/dist/npm/colors/interfaces/ColorPickerProps.d.ts +5 -2
  67. package/dist/npm/colors/interfaces/ColorPickerView.d.ts +3 -0
  68. package/dist/npm/input/Input.d.ts +19 -9
  69. package/dist/npm/input/Input.js +19 -3
  70. package/dist/npm/input-separator/InputSeparator.d.ts +19 -0
  71. package/dist/npm/input-separator/InputSeparator.js +46 -0
  72. package/dist/npm/main.d.ts +1 -0
  73. package/dist/npm/main.js +1 -0
  74. package/dist/npm/maskedtextbox/MaskedTextBox.d.ts +4 -1
  75. package/dist/npm/maskedtextbox/MaskedTextBox.js +94 -19
  76. package/dist/npm/maskedtextbox/MaskedTextBoxProps.d.ts +32 -0
  77. package/dist/npm/numerictextbox/NumericTextBox.d.ts +6 -0
  78. package/dist/npm/numerictextbox/NumericTextBox.js +100 -7
  79. package/dist/npm/numerictextbox/interfaces/NumericTextBoxProps.d.ts +43 -3
  80. package/dist/npm/package-metadata.js +1 -1
  81. package/dist/npm/radiobutton/RadioButton.d.ts +7 -1
  82. package/dist/npm/radiobutton/RadioButton.js +8 -0
  83. package/dist/npm/radiobutton/RadioGroup.d.ts +7 -1
  84. package/dist/npm/radiobutton/RadioGroup.js +8 -0
  85. package/dist/npm/range-slider/RangeSlider.d.ts +8 -0
  86. package/dist/npm/range-slider/RangeSlider.js +10 -0
  87. package/dist/npm/slider/Slider.d.ts +8 -2
  88. package/dist/npm/slider/Slider.js +8 -0
  89. package/dist/npm/slider/SliderLabel.d.ts +8 -0
  90. package/dist/npm/slider/SliderLabel.js +10 -1
  91. package/dist/npm/switch/Switch.d.ts +8 -0
  92. package/dist/npm/switch/Switch.js +10 -1
  93. package/dist/npm/textarea/TextArea.d.ts +36 -0
  94. package/dist/npm/textarea/TextArea.js +112 -27
  95. package/dist/npm/textarea/interfaces/TextAreaProps.d.ts +39 -0
  96. package/package.json +10 -10
  97. package/dist/es/numerictextbox/interfaces/NumericTextBoxHandle.d.ts +0 -39
  98. package/dist/es/numerictextbox/interfaces/NumericTextBoxHandle.js +0 -0
  99. package/dist/npm/numerictextbox/interfaces/NumericTextBoxHandle.d.ts +0 -39
  100. package/dist/npm/numerictextbox/interfaces/NumericTextBoxHandle.js +0 -5
@@ -1,6 +1,9 @@
1
1
  /**
2
2
  * The arguments for the `onBlur` ColorPicker event.
3
3
  */
4
+ /**
5
+ * @hidden
6
+ */
4
7
  export interface ColorPickerBlurEvent {
5
8
  /**
6
9
  * A native DOM event.
@@ -1,6 +1,9 @@
1
1
  /**
2
2
  * The arguments for the `onChange` ColorPicker event.
3
3
  */
4
+ /**
5
+ * @hidden
6
+ */
4
7
  export interface ColorPickerChangeEvent {
5
8
  /**
6
9
  * The current value of the ColorPicker.
@@ -1,6 +1,9 @@
1
1
  /**
2
2
  * The arguments for the `onFocus` ColorPicker event.
3
3
  */
4
+ /**
5
+ * @hidden
6
+ */
4
7
  export interface ColorPickerFocusEvent {
5
8
  /**
6
9
  * A native DOM event.
@@ -3,6 +3,9 @@ import { TileSize } from '../models/tile-size';
3
3
  * The settings of the ColorPalette that is nested inside the popup of the ColorPicker
4
4
  * ([see example]({% slug customizecolorpicker_colorpicker %}#toc-customizing-the-palette-popup)).
5
5
  */
6
+ /**
7
+ * @hidden
8
+ */
6
9
  export interface ColorPickerPaletteSettings {
7
10
  /**
8
11
  * Specifies the set of colors.
@@ -2,6 +2,9 @@ import { PopupAnimation } from '@progress/kendo-vue-popup';
2
2
  /**
3
3
  * The settings of the popup container of the ColorPicker.
4
4
  */
5
+ /**
6
+ * @hidden
7
+ */
5
8
  export interface ColorPickerPopupSettings {
6
9
  /**
7
10
  * Controls the popup animation. By default, the open and close animations are enabled.
@@ -6,7 +6,10 @@ import { ColorPickerPopupSettings } from './ColorPickerPopupSettings';
6
6
  import { ColorPickerPaletteSettings } from './ColorPickerPaletteSettings';
7
7
  import { ColorPickerView } from './ColorPickerView';
8
8
  /**
9
- * Represents the props of the [KendoReact ColorPicker component]({% slug overview_colorpicker %}).
9
+ * Represents the props of the [Kendo UI for Vue ColorPicker component]({% slug overview_colorpicker %}).
10
+ */
11
+ /**
12
+ * @hidden
10
13
  */
11
14
  export interface ColorPickerProps {
12
15
  /**
@@ -49,7 +52,7 @@ export interface ColorPickerProps {
49
52
  */
50
53
  dir?: string;
51
54
  /**
52
- * Defines the name of an [existing icon in the KendoReact theme]({% slug icons %}).
55
+ * Defines the name of an [existing icon in the Kendo UI for Vue theme]({% slug icons %}).
53
56
  * You have to provide only the name of the icon without the `k-icon` or the `k-i-` prefixes.
54
57
  * For example, `edit-tools` will be parsed to `k-icon k-i-edit-tools`
55
58
  * ([see example]({% slug customizecolorpicker_colorpicker %}#toc-displaying-kendo-ui-icons)).
@@ -7,4 +7,7 @@
7
7
  * * `gradient`
8
8
  * * `combo`
9
9
  */
10
+ /**
11
+ * @hidden
12
+ */
10
13
  export declare type ColorPickerView = 'gradient' | 'palette' | 'combo';
@@ -5,7 +5,7 @@ declare type DefaultMethods<V> = {
5
5
  [key: string]: (this: V, ...args: any[]) => any;
6
6
  };
7
7
  /**
8
- * Represents the props of the [KendoVue Input component]({% slug overview_textbox_native %}).
8
+ * Represents the props of the [KendoVue Input component]({% slug overview_textbox %}).
9
9
  * Extends the [native input props](https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement).
10
10
  */
11
11
  export interface InputProps extends FormComponentProps {
@@ -92,31 +92,35 @@ export interface InputProps extends FormComponentProps {
92
92
  /**
93
93
  * Defines a string prop that controls the input icon.
94
94
  */
95
- iconName: String;
95
+ iconName?: String;
96
96
  /**
97
97
  * Defines if the inputPrefix will be shown. Accepts a slot name, a `render` function, or a Vue component.
98
98
  */
99
- inputPrefix: Boolean | String | Object | Function;
99
+ inputPrefix?: Boolean | String | Object | Function;
100
100
  /**
101
101
  * Defines if the inputSuffix will be shown. Accepts a slot name, a `render` function, or a Vue component.
102
102
  */
103
- inputSuffix: Boolean | String | Object | Function;
103
+ inputSuffix?: Boolean | String | Object | Function;
104
104
  /**
105
105
  * Defines a boolean prop that controls whether to show the validation icon. Defaults to 'false'.
106
106
  */
107
- showValidationIcon: Boolean;
107
+ showValidationIcon?: Boolean;
108
108
  /**
109
109
  * Defines a boolean prop that controls whether to show the loading icon. Defaults to 'false'.
110
110
  */
111
- showLoadingIcon: Boolean;
111
+ showLoadingIcon?: Boolean;
112
112
  /**
113
113
  * Defines a boolean prop that controls whether to show the clear icon. Defaults to 'false'.
114
114
  */
115
- showClearButton: Boolean;
115
+ showClearButton?: Boolean;
116
116
  /**
117
- * Defines additional class to the inner input element.
117
+ * Defines additional class to the wrapper element.
118
118
  */
119
- inputClass: String;
119
+ wrapperClass?: String;
120
+ /**
121
+ * Defines additional class to the input element.
122
+ */
123
+ inputClass?: String;
120
124
  }
121
125
  /**
122
126
  * @hidden
@@ -170,6 +174,12 @@ export interface InputComputed {
170
174
  */
171
175
  export interface InputAllMethods extends Vue2type, InputMethods, InputComputed, InputState {
172
176
  }
177
+ /**
178
+ * @hidden
179
+ */
173
180
  declare let InputVue2: ComponentOptions<InputAllMethods, DefaultData<InputData>, DefaultMethods<InputAllMethods>, InputComputed, RecordPropsDefinition<InputProps>>;
181
+ /**
182
+ * @hidden
183
+ */
174
184
  declare const Input: DefineComponent<InputProps, any, InputData, InputComputed, InputMethods, {}, {}, {}, string, InputProps, InputProps, {}>;
175
185
  export { Input, InputVue2 };
@@ -32,6 +32,10 @@ var kendo_vue_common_1 = require("@progress/kendo-vue-common");
32
32
  var package_metadata_1 = require("../package-metadata");
33
33
 
34
34
  var kendo_vue_labels_1 = require("@progress/kendo-vue-labels");
35
+ /**
36
+ * @hidden
37
+ */
38
+
35
39
 
36
40
  var InputVue2 = {
37
41
  model: {
@@ -117,7 +121,8 @@ var InputVue2 = {
117
121
  showValidationIcon: Boolean,
118
122
  showLoadingIcon: Boolean,
119
123
  showClearButton: Boolean,
120
- inputClass: String
124
+ inputClass: String,
125
+ wrapperClass: String
121
126
  },
122
127
  data: function data() {
123
128
  return {
@@ -179,7 +184,7 @@ var InputVue2 = {
179
184
  id: inputId,
180
185
  required: required,
181
186
  value: this.computedValue,
182
- class: 'k-input-inner',
187
+ class: this.inputInnerClass,
183
188
  ref: this.v3 ? function (el) {
184
189
  _this.inputRef = el;
185
190
  } : 'input',
@@ -387,7 +392,7 @@ var InputVue2 = {
387
392
  return _a = {
388
393
  'k-textbox': true,
389
394
  'k-input': true
390
- }, _a["k-input-" + (kendo_vue_common_1.kendoThemeMaps.sizeMap[size] || size)] = size, _a["k-input-" + fillMode] = fillMode, _a["k-rounded-" + (kendo_vue_common_1.kendoThemeMaps.roundedMap[rounded] || rounded)] = rounded, _a['k-invalid'] = !isValid, _a['k-required'] = this.required, _a['k-disabled'] = this.$props.disabled, _a[this.inputClass] = this.inputClass, _a;
395
+ }, _a["k-input-" + (kendo_vue_common_1.kendoThemeMaps.sizeMap[size] || size)] = size, _a["k-input-" + fillMode] = fillMode, _a["k-rounded-" + (kendo_vue_common_1.kendoThemeMaps.roundedMap[rounded] || rounded)] = rounded, _a['k-invalid'] = !isValid, _a['k-required'] = this.required, _a['k-disabled'] = this.$props.disabled, _a[this.wrapperClass] = this.wrapperClass, _a;
391
396
  }
392
397
  },
393
398
  computed: {
@@ -404,6 +409,13 @@ var InputVue2 = {
404
409
  };
405
410
  }
406
411
  },
412
+ inputInnerClass: function inputInnerClass() {
413
+ var _a;
414
+
415
+ return _a = {
416
+ 'k-input-inner': true
417
+ }, _a[this.inputClass] = this.inputClass, _a;
418
+ },
407
419
  computedValue: {
408
420
  get: function get() {
409
421
  return this.$data.valueDuringOnChange !== undefined ? this.$data.valueDuringOnChange : this.$props.value !== undefined ? this.$props.value : this.$props.modelValue !== undefined ? this.$props.modelValue : this.$data.currentValue;
@@ -412,5 +424,9 @@ var InputVue2 = {
412
424
  }
413
425
  };
414
426
  exports.InputVue2 = InputVue2;
427
+ /**
428
+ * @hidden
429
+ */
430
+
415
431
  var Input = InputVue2;
416
432
  exports.Input = Input;
@@ -0,0 +1,19 @@
1
+ import { DefineComponent, RecordPropsDefinition, ComponentOptions, Vue2type } from '../additionalTypes';
2
+ declare type DefaultData<V> = object | ((this: V) => {});
3
+ declare type DefaultMethods<V> = {
4
+ [key: string]: (this: V, ...args: any[]) => any;
5
+ };
6
+ /**
7
+ * @hidden
8
+ */
9
+ export interface InputSeparatorAllMethods extends Vue2type {
10
+ }
11
+ /**
12
+ * @hidden
13
+ */
14
+ declare let InputSeparatorVue2: ComponentOptions<InputSeparatorAllMethods, DefaultData<{}>, DefaultMethods<InputSeparatorAllMethods>, {}, RecordPropsDefinition<{}>>;
15
+ /**
16
+ * @hidden
17
+ */
18
+ declare const InputSeparator: DefineComponent<{}, any, {}, {}, {}, {}, {}, {}, string, {}, {}, {}>;
19
+ export { InputSeparator, InputSeparatorVue2 };
@@ -0,0 +1,46 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.InputSeparatorVue2 = exports.InputSeparator = void 0; // @ts-ignore
7
+
8
+ var kendo_licensing_1 = require("@progress/kendo-licensing");
9
+
10
+ var Vue = require("vue");
11
+
12
+ var allVue = Vue;
13
+ var gh = allVue.h;
14
+ var ref = allVue.ref;
15
+
16
+ var package_metadata_1 = require("../package-metadata");
17
+ /**
18
+ * @hidden
19
+ */
20
+
21
+
22
+ var InputSeparatorVue2 = {
23
+ created: function created() {
24
+ kendo_licensing_1.validatePackage(package_metadata_1.packageMetadata);
25
+ },
26
+ // @ts-ignore
27
+ setup: !gh ? undefined : function () {
28
+ var v3 = !!gh;
29
+ return {
30
+ v3: v3
31
+ };
32
+ },
33
+ render: function render(createElement) {
34
+ var h = gh || createElement;
35
+ return h("span", {
36
+ "class": 'k-input-separator'
37
+ });
38
+ }
39
+ };
40
+ exports.InputSeparatorVue2 = InputSeparatorVue2;
41
+ /**
42
+ * @hidden
43
+ */
44
+
45
+ var InputSeparator = InputSeparatorVue2;
46
+ exports.InputSeparator = InputSeparator;
@@ -11,6 +11,7 @@ export * from './colors/interfaces/ColorPickerPaletteSettings';
11
11
  export * from './colors/interfaces/ColorPickerPopupSettings';
12
12
  export * from './colors/interfaces/ColorPickerProps';
13
13
  export { Switch, SwitchVue2, SwitchProps, SwitchState, SwitchChangeEvent } from './switch/Switch';
14
+ export * from './input-separator/InputSeparator';
14
15
  export * from './input/Input';
15
16
  export * from './numerictextbox/NumericTextBox';
16
17
  export * from './maskedtextbox/MaskedTextBox';
package/dist/npm/main.js CHANGED
@@ -24,6 +24,7 @@ __exportStar(require("./colors/interfaces/ColorPickerProps"), exports);
24
24
  var Switch_1 = require("./switch/Switch");
25
25
  Object.defineProperty(exports, "Switch", { enumerable: true, get: function () { return Switch_1.Switch; } });
26
26
  Object.defineProperty(exports, "SwitchVue2", { enumerable: true, get: function () { return Switch_1.SwitchVue2; } });
27
+ __exportStar(require("./input-separator/InputSeparator"), exports);
27
28
  __exportStar(require("./input/Input"), exports);
28
29
  __exportStar(require("./numerictextbox/NumericTextBox"), exports);
29
30
  __exportStar(require("./maskedtextbox/MaskedTextBox"), exports);
@@ -66,8 +66,11 @@ export interface MaskedTextBoxComputed {
66
66
  export interface MaskedTextBoxAll extends MaskedTextBoxMethods, MaskedTextBoxState, MaskedTextBoxData, MaskedTextBoxComputed {
67
67
  }
68
68
  /**
69
- * Represents the default `MaskedTextBox` component.
69
+ * @hidden
70
70
  */
71
71
  declare let MaskedTextBoxVue2: ComponentOptions<Vue2type, DefaultData<MaskedTextBoxData>, DefaultMethods<MaskedTextBoxAll>, MaskedTextBoxComputed, RecordPropsDefinition<MaskedTextBoxProps>>;
72
+ /**
73
+ * @hidden
74
+ */
72
75
  declare const MaskedTextBox: DefineComponent<MaskedTextBoxProps, any, MaskedTextBoxData, MaskedTextBoxComputed, MaskedTextBoxMethods, {}, {}, {}, string, MaskedTextBoxProps, MaskedTextBoxProps, {}>;
73
76
  export { MaskedTextBox, MaskedTextBoxVue2 };
@@ -19,7 +19,7 @@ var kendo_vue_common_1 = require("@progress/kendo-vue-common");
19
19
 
20
20
  var package_metadata_1 = require("../package-metadata");
21
21
  /**
22
- * Represents the default `MaskedTextBox` component.
22
+ * @hidden
23
23
  */
24
24
 
25
25
 
@@ -105,7 +105,15 @@ var MaskedTextBoxVue2 = {
105
105
  validityStyles: {
106
106
  type: Boolean,
107
107
  default: true
108
- }
108
+ },
109
+ iconName: String,
110
+ inputPrefix: kendo_vue_common_1.templateDefinition,
111
+ inputSuffix: kendo_vue_common_1.templateDefinition,
112
+ showValidationIcon: Boolean,
113
+ showLoadingIcon: Boolean,
114
+ showClearButton: Boolean,
115
+ inputClass: String,
116
+ wrapperClass: String
109
117
  },
110
118
  data: function data() {
111
119
  return {
@@ -203,15 +211,38 @@ var MaskedTextBoxVue2 = {
203
211
  },
204
212
  spanClassNames: {
205
213
  get: function get() {
214
+ var _a;
215
+
206
216
  var isValid = !this.hasMounted || !this.$props.validityStyles || this.validity().valid;
207
- return {
217
+ return _a = {
208
218
  'k-floating-label-container': true,
209
219
  'k-focus': this.currentFocused,
210
220
  'k-empty': !this.computedValue(),
211
221
  'k-invalid': !isValid && isValid !== undefined,
212
- 'k-rtl': this.$props.dir === 'rtl'
213
- };
222
+ 'k-rtl': this.$props.dir === 'rtl',
223
+ 'k-loading': this.showLoadingIcon
224
+ }, _a[this.wrapperClass] = this.wrapperClass, _a;
214
225
  }
226
+ },
227
+ wrapperSpanClass: function wrapperSpanClass() {
228
+ var _a;
229
+
230
+ var _b = this.$props,
231
+ size = _b.size,
232
+ fillMode = _b.fillMode,
233
+ rounded = _b.rounded;
234
+ var isValid = !this.$props.validityStyles || this.validity().valid;
235
+ return _a = {
236
+ 'k-maskedtextbox': true,
237
+ 'k-input': true
238
+ }, _a["k-input-" + (kendo_vue_common_1.kendoThemeMaps.sizeMap[size] || size)] = size, _a["k-input-" + fillMode] = fillMode, _a["k-rounded-" + (kendo_vue_common_1.kendoThemeMaps.roundedMap[rounded] || rounded)] = rounded, _a['k-invalid'] = !isValid, _a['k-required'] = this.required, _a['k-disabled'] = this.$props.disabled, _a['k-loading'] = this.showLoadingIcon, _a[this.wrapperClass] = this.wrapperClass, _a;
239
+ },
240
+ inputInnerClass: function inputInnerClass() {
241
+ var _a;
242
+
243
+ return _a = {
244
+ 'k-input-inner': true
245
+ }, _a[this.inputClass] = this.inputClass, _a;
215
246
  }
216
247
  },
217
248
  methods: {
@@ -263,6 +294,9 @@ var MaskedTextBoxVue2 = {
263
294
  this.isPasted = true;
264
295
  this.currentSelection = [selectionStart || 0, selectionEnd || 0];
265
296
  },
297
+ clearClick: function clearClick(event) {
298
+ this.triggerOnChange('', event);
299
+ },
266
300
  onChangeHandler: function onChangeHandler(event) {
267
301
  var input = event.currentTarget;
268
302
  var value = this.inputValue = input.value;
@@ -350,29 +384,50 @@ var MaskedTextBoxVue2 = {
350
384
  },
351
385
  // @ts-ignore
352
386
  render: function render(createElement) {
353
- var _a;
354
-
355
387
  var _this = this;
356
388
 
357
389
  var h = gh || createElement;
358
390
  var inputId = this.$props.id || this.inputId;
359
- var _b = this.$props,
360
- size = _b.size,
361
- fillMode = _b.fillMode,
362
- rounded = _b.rounded;
363
- var isValid = !this.hasMounted || !this.$props.validityStyles || this.validity().valid;
391
+ var _a = this.$props,
392
+ iconName = _a.iconName,
393
+ showValidationIcon = _a.showValidationIcon,
394
+ showLoadingIcon = _a.showLoadingIcon,
395
+ showClearButton = _a.showClearButton;
396
+ var isValid = !this.$props.validityStyles || this.validity().valid;
364
397
  var newValue = this.computedValue();
365
398
  var inputValue = this.inputValue;
366
- var component = h("span", {
399
+ var inputPrefixTemplate = kendo_vue_common_1.templateRendering.call(this, this.$props.inputPrefix, kendo_vue_common_1.getListeners.call(this));
400
+ var inputSuffixTemplate = kendo_vue_common_1.templateRendering.call(this, this.$props.inputSuffix, kendo_vue_common_1.getListeners.call(this));
401
+ var inputPrefix = kendo_vue_common_1.getTemplate.call(this, {
402
+ h: h,
403
+ template: inputPrefixTemplate,
404
+ additionalProps: {
405
+ value: newValue,
406
+ valid: isValid
407
+ }
408
+ });
409
+ var inputSuffix = kendo_vue_common_1.getTemplate.call(this, {
410
+ h: h,
411
+ template: inputSuffixTemplate,
412
+ additionalProps: {
413
+ value: newValue,
414
+ valid: isValid
415
+ }
416
+ });
417
+ var wrapper = h("span", {
367
418
  dir: this.$props.dir,
368
419
  attrs: this.v3 ? undefined : {
369
420
  dir: this.$props.dir
370
421
  },
371
- "class": kendo_vue_common_1.classNames('k-maskedtextbox k-input', (_a = {}, _a["k-input-" + (kendo_vue_common_1.kendoThemeMaps.sizeMap[size] || size)] = size, _a["k-input-" + fillMode] = fillMode, _a["k-rounded-" + (kendo_vue_common_1.kendoThemeMaps.roundedMap[rounded] || rounded)] = rounded, _a['k-invalid'] = !isValid, _a['k-required'] = this.required, _a['k-disabled'] = this.$props.disabled, _a)),
422
+ "class": this.wrapperSpanClass,
372
423
  style: !this.$props.label ? {
373
424
  width: this.$props.width
374
425
  } : undefined
375
- }, [h("input", {
426
+ }, [iconName && h("span", {
427
+ "class": "k-input-icon k-icon k-i-" + iconName
428
+ }), this.$props.inputPrefix && h("span", {
429
+ "class": "k-input-prefix"
430
+ }, [inputPrefix]), h("input", {
376
431
  type: this.$props.type,
377
432
  attrs: this.v3 ? undefined : {
378
433
  type: this.$props.type,
@@ -396,7 +451,7 @@ var MaskedTextBoxVue2 = {
396
451
  autoCorrect: "off",
397
452
  autoCapitalize: "off",
398
453
  spellCheck: false,
399
- "class": "k-input-inner",
454
+ "class": this.inputInnerClass,
400
455
  value: this.v3 ? newValue : null,
401
456
  domProps: this.v3 ? undefined : {
402
457
  "value": newValue
@@ -429,14 +484,30 @@ var MaskedTextBoxVue2 = {
429
484
  onBlur: this.blurHandler,
430
485
  onDragStart: utils_1.returnFalse,
431
486
  onDrop: utils_1.returnFalse
432
- })]);
487
+ }), this.$props.inputSuffix && h("span", {
488
+ "class": "k-input-suffix"
489
+ }, [inputSuffix]), showValidationIcon && isValid && h("span", {
490
+ "class": "k-input-validation-icon k-icon k-i-check"
491
+ }), showValidationIcon && !isValid && h("span", {
492
+ "class": "k-input-validation-icon k-icon k-i-warning"
493
+ }), showLoadingIcon && h("span", {
494
+ "class": "k-input-loading-icon k-icon k-i-loading"
495
+ }), showClearButton && newValue && h("span", {
496
+ onClick: this.clearClick,
497
+ on: this.v3 ? undefined : {
498
+ "click": this.clearClick
499
+ },
500
+ "class": "k-clear-value"
501
+ }, [h("span", {
502
+ "class": "k-icon k-i-x"
503
+ })])]);
433
504
  return this.$props.label ? h("span", {
434
505
  "class": this.spanClassNames,
435
506
  dir: this.$props.dir,
436
507
  attrs: this.v3 ? undefined : {
437
508
  dir: this.$props.dir
438
509
  }
439
- }, [component, this.$props.label ? inputId ? h("label", {
510
+ }, [wrapper, this.$props.label ? inputId ? h("label", {
440
511
  "for": inputId,
441
512
  attrs: this.v3 ? undefined : {
442
513
  "for": inputId
@@ -444,9 +515,13 @@ var MaskedTextBoxVue2 = {
444
515
  "class": "k-label"
445
516
  }, [this.$props.label]) : h("span", {
446
517
  "class": "k-label"
447
- }, [this.$props.label]) : null]) : component;
518
+ }, [this.$props.label]) : null]) : wrapper;
448
519
  }
449
520
  };
450
521
  exports.MaskedTextBoxVue2 = MaskedTextBoxVue2;
522
+ /**
523
+ * @hidden
524
+ */
525
+
451
526
  var MaskedTextBox = MaskedTextBoxVue2;
452
527
  exports.MaskedTextBox = MaskedTextBox;
@@ -184,4 +184,36 @@ export interface MaskedTextBoxProps extends FormComponentProps {
184
184
  * The type of the input - 'text' by default
185
185
  */
186
186
  type?: string;
187
+ /**
188
+ * Defines a string prop that controls the input icon.
189
+ */
190
+ iconName?: String;
191
+ /**
192
+ * Defines if the inputPrefix will be shown. Accepts a slot name, a `render` function, or a Vue component.
193
+ */
194
+ inputPrefix?: Boolean | String | Object | Function;
195
+ /**
196
+ * Defines if the inputSuffix will be shown. Accepts a slot name, a `render` function, or a Vue component.
197
+ */
198
+ inputSuffix?: Boolean | String | Object | Function;
199
+ /**
200
+ * Defines a boolean prop that controls whether to show the validation icon. Defaults to 'false'.
201
+ */
202
+ showValidationIcon?: Boolean;
203
+ /**
204
+ * Defines a boolean prop that controls whether to show the loading icon. Defaults to 'false'.
205
+ */
206
+ showLoadingIcon?: Boolean;
207
+ /**
208
+ * Defines a boolean prop that controls whether to show the clear icon. Defaults to 'false'.
209
+ */
210
+ showClearButton?: Boolean;
211
+ /**
212
+ * Defines additional class to the inner input element.
213
+ */
214
+ inputClass?: String;
215
+ /**
216
+ * Defines additional class to the wrapper element.
217
+ */
218
+ wrapperClass?: String;
187
219
  }
@@ -72,6 +72,12 @@ export interface NumericTextBoxComputed {
72
72
  */
73
73
  export interface NumericTextBoxAll extends Vue2type, NumericTextBoxMethods, NumericTextBoxComputed, NumericTextBoxState {
74
74
  }
75
+ /**
76
+ * @hidden
77
+ */
75
78
  declare let NumericTextBoxVue2: ComponentOptions<NumericTextBoxAll, DefaultData<NumericTextBoxData>, DefaultMethods<NumericTextBoxAll>, NumericTextBoxComputed, RecordPropsDefinition<NumericTextBoxProps>>;
79
+ /**
80
+ * @hidden
81
+ */
76
82
  declare const NumericTextBox: DefineComponent<NumericTextBoxProps, any, NumericTextBoxData, NumericTextBoxComputed, NumericTextBoxMethods, {}, {}, {}, string, NumericTextBoxProps, NumericTextBoxProps, {}>;
77
83
  export { NumericTextBox, NumericTextBoxVue2 };