@progress/kendo-angular-inputs 17.0.0-develop.9 → 17.0.1-develop.1

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 (237) hide show
  1. package/checkbox/checkbox.component.d.ts +1 -1
  2. package/checkbox/checkbox.directive.d.ts +1 -1
  3. package/checkbox/checked-state.d.ts +1 -1
  4. package/colorpicker/color-contrast-svg.component.d.ts +1 -1
  5. package/colorpicker/color-gradient-numeric-label.directive.d.ts +1 -1
  6. package/colorpicker/color-gradient.component.d.ts +1 -1
  7. package/colorpicker/color-input.component.d.ts +1 -1
  8. package/colorpicker/color-palette.component.d.ts +1 -1
  9. package/colorpicker/colorpicker.component.d.ts +1 -1
  10. package/colorpicker/contrast-validation.component.d.ts +1 -1
  11. package/colorpicker/contrast.component.d.ts +1 -1
  12. package/colorpicker/flatcolorpicker-actions.component.d.ts +1 -1
  13. package/colorpicker/flatcolorpicker-header.component.d.ts +1 -1
  14. package/colorpicker/flatcolorpicker.component.d.ts +1 -1
  15. package/colorpicker/localization/messages.d.ts +1 -1
  16. package/colorpicker/models/actions-layout.d.ts +1 -1
  17. package/colorpicker/models/colorpicker-view.d.ts +1 -1
  18. package/colorpicker/models/output-format.d.ts +1 -1
  19. package/common/models/fillmode.d.ts +1 -1
  20. package/common/models/rounded.d.ts +2 -2
  21. package/common/models/size.d.ts +1 -1
  22. package/common/models/type.d.ts +1 -1
  23. package/common/radio-checkbox.base.d.ts +1 -1
  24. package/common/utils.d.ts +1 -1
  25. package/{esm2020 → esm2022}/checkbox/checkbox.component.mjs +49 -44
  26. package/{esm2020 → esm2022}/checkbox/checkbox.directive.mjs +12 -10
  27. package/{esm2020 → esm2022}/checkbox.module.mjs +4 -4
  28. package/{esm2020 → esm2022}/colorpicker/color-contrast-svg.component.mjs +13 -7
  29. package/{esm2020 → esm2022}/colorpicker/color-gradient-numeric-label.directive.mjs +6 -3
  30. package/{esm2020 → esm2022}/colorpicker/color-gradient.component.mjs +142 -125
  31. package/{esm2020 → esm2022}/colorpicker/color-input.component.mjs +69 -49
  32. package/{esm2020 → esm2022}/colorpicker/color-palette.component.mjs +129 -98
  33. package/{esm2020 → esm2022}/colorpicker/colorpicker.component.mjs +211 -158
  34. package/{esm2020 → esm2022}/colorpicker/contrast-validation.component.mjs +10 -6
  35. package/{esm2020 → esm2022}/colorpicker/contrast.component.mjs +9 -6
  36. package/{esm2020 → esm2022}/colorpicker/events/active-color-click-event.mjs +2 -1
  37. package/{esm2020 → esm2022}/colorpicker/events/cancel-event.mjs +4 -0
  38. package/{esm2020 → esm2022}/colorpicker/flatcolorpicker-actions.component.mjs +11 -8
  39. package/{esm2020 → esm2022}/colorpicker/flatcolorpicker-header.component.mjs +23 -13
  40. package/{esm2020 → esm2022}/colorpicker/flatcolorpicker.component.mjs +155 -127
  41. package/{esm2020 → esm2022}/colorpicker/localization/colorgradient-localization.service.mjs +4 -3
  42. package/{esm2020 → esm2022}/colorpicker/localization/colorpalette-localization.service.mjs +4 -3
  43. package/{esm2020 → esm2022}/colorpicker/localization/colorpicker-localization.service.mjs +3 -3
  44. package/{esm2020 → esm2022}/colorpicker/localization/custom-messages.component.mjs +9 -8
  45. package/{esm2020 → esm2022}/colorpicker/localization/flatcolorpicker-localization.service.mjs +4 -3
  46. package/{esm2020 → esm2022}/colorpicker/localization/localized-colorpicker-messages.directive.mjs +9 -8
  47. package/esm2022/colorpicker/localization/messages.mjs +183 -0
  48. package/{esm2020 → esm2022}/colorpicker/services/color-palette.service.mjs +4 -6
  49. package/{esm2020 → esm2022}/colorpicker/services/flatcolorpicker.service.mjs +3 -3
  50. package/{esm2020 → esm2022}/colorpicker.module.mjs +4 -4
  51. package/{esm2020 → esm2022}/common/radio-checkbox.base.mjs +80 -56
  52. package/{esm2020 → esm2022}/formfield/error.component.mjs +18 -20
  53. package/{esm2020 → esm2022}/formfield/formfield.component.mjs +67 -55
  54. package/{esm2020 → esm2022}/formfield/hint.component.mjs +17 -19
  55. package/{esm2020 → esm2022}/formfield.module.mjs +4 -4
  56. package/{esm2020 → esm2022}/index.mjs +0 -1
  57. package/esm2022/inputs.module.mjs +96 -0
  58. package/{esm2020 → esm2022}/maskedtextbox/maskedtextbox.component.mjs +263 -223
  59. package/{esm2020 → esm2022}/maskedtextbox/masking.service.mjs +12 -14
  60. package/{esm2020 → esm2022}/maskedtextbox/parsing/parsers.mjs +1 -0
  61. package/{esm2020 → esm2022}/maskedtextbox/parsing/result.mjs +3 -0
  62. package/{esm2020 → esm2022}/maskedtextbox/parsing/stream.mjs +4 -2
  63. package/{esm2020 → esm2022}/maskedtextbox.module.mjs +7 -7
  64. package/{esm2020 → esm2022}/numerictextbox/localization/custom-messages.component.mjs +9 -8
  65. package/{esm2020 → esm2022}/numerictextbox/localization/localized-numerictextbox-messages.directive.mjs +9 -8
  66. package/{esm2020 → esm2022}/numerictextbox/localization/messages.mjs +11 -3
  67. package/{esm2020 → esm2022}/numerictextbox/numerictextbox.component.mjs +367 -319
  68. package/{esm2020 → esm2022}/numerictextbox.module.mjs +7 -7
  69. package/{esm2020 → esm2022}/package-metadata.mjs +2 -2
  70. package/{esm2020 → esm2022}/radiobutton/radiobutton.component.mjs +58 -51
  71. package/{esm2020 → esm2022}/radiobutton/radiobutton.directive.mjs +12 -10
  72. package/{esm2020 → esm2022}/radiobutton.module.mjs +4 -4
  73. package/{esm2020 → esm2022}/rangeslider/localization/custom-messages.component.mjs +9 -8
  74. package/{esm2020 → esm2022}/rangeslider/localization/localized-rangeslider-messages.directive.mjs +9 -8
  75. package/{esm2020 → esm2022}/rangeslider/localization/messages.mjs +11 -3
  76. package/{esm2020 → esm2022}/rangeslider/rangeslider-model.mjs +2 -0
  77. package/{esm2020 → esm2022}/rangeslider/rangeslider.component.mjs +117 -101
  78. package/{esm2020 → esm2022}/rangeslider.module.mjs +4 -4
  79. package/{esm2020 → esm2022}/rating/directives/rating-hovered-item.directive.mjs +4 -3
  80. package/{esm2020 → esm2022}/rating/directives/rating-item.directive.mjs +4 -3
  81. package/{esm2020 → esm2022}/rating/directives/rating-selected-item.directive.mjs +4 -3
  82. package/{esm2020 → esm2022}/rating/rating.component.mjs +96 -76
  83. package/{esm2020 → esm2022}/rating.module.mjs +4 -4
  84. package/{esm2020 → esm2022}/shared/input-separator.component.mjs +10 -12
  85. package/{esm2020 → esm2022}/shared/shared-events.directive.mjs +13 -7
  86. package/{esm2020 → esm2022}/shared/textarea.directive.mjs +66 -52
  87. package/{esm2020 → esm2022}/signature/localization/custom-messages.component.mjs +9 -8
  88. package/{esm2020 → esm2022}/signature/localization/localized-signature-messages.directive.mjs +9 -8
  89. package/{esm2020 → esm2022}/signature/localization/messages.mjs +19 -3
  90. package/{esm2020 → esm2022}/signature/signature.component.mjs +205 -151
  91. package/{esm2020 → esm2022}/signature.module.mjs +4 -4
  92. package/{esm2020 → esm2022}/slider/localization/custom-messages.component.mjs +9 -8
  93. package/{esm2020 → esm2022}/slider/localization/localized-slider-messages.directive.mjs +9 -8
  94. package/{esm2020 → esm2022}/slider/localization/messages.mjs +15 -3
  95. package/{esm2020 → esm2022}/slider/slider-model.mjs +1 -0
  96. package/{esm2020 → esm2022}/slider/slider.component.mjs +121 -99
  97. package/{esm2020 → esm2022}/slider.module.mjs +4 -4
  98. package/{esm2020 → esm2022}/sliders-common/label-template.directive.mjs +4 -3
  99. package/{esm2020 → esm2022}/sliders-common/slider-base.mjs +112 -90
  100. package/{esm2020 → esm2022}/sliders-common/slider-model.base.mjs +6 -0
  101. package/{esm2020 → esm2022}/sliders-common/slider-ticks.component.mjs +19 -11
  102. package/{esm2020 → esm2022}/switch/events/blur-event.mjs +4 -0
  103. package/{esm2020 → esm2022}/switch/events/focus-event.mjs +4 -0
  104. package/{esm2020 → esm2022}/switch/localization/custom-messages.component.mjs +9 -8
  105. package/{esm2020 → esm2022}/switch/localization/localized-switch-messages.directive.mjs +9 -8
  106. package/{esm2020 → esm2022}/switch/localization/messages.mjs +11 -3
  107. package/{esm2020 → esm2022}/switch/switch.component.mjs +125 -106
  108. package/{esm2020 → esm2022}/switch.module.mjs +4 -4
  109. package/esm2022/text-fields-common/text-fields-base.mjs +150 -0
  110. package/{esm2020 → esm2022}/textarea/textarea-prefix.component.mjs +12 -14
  111. package/{esm2020 → esm2022}/textarea/textarea-suffix.component.mjs +12 -14
  112. package/{esm2020 → esm2022}/textarea/textarea.component.mjs +173 -144
  113. package/{esm2020 → esm2022}/textarea.module.mjs +7 -7
  114. package/{esm2020 → esm2022}/textbox/localization/custom-messages.component.mjs +9 -8
  115. package/{esm2020 → esm2022}/textbox/localization/localized-textbox-messages.directive.mjs +9 -8
  116. package/{esm2020 → esm2022}/textbox/localization/messages.mjs +7 -3
  117. package/{esm2020 → esm2022}/textbox/textbox-prefix.directive.mjs +8 -7
  118. package/{esm2020 → esm2022}/textbox/textbox-suffix.directive.mjs +8 -7
  119. package/{esm2020 → esm2022}/textbox/textbox.component.mjs +286 -204
  120. package/{esm2020 → esm2022}/textbox/textbox.directive.mjs +36 -33
  121. package/{esm2020 → esm2022}/textbox.module.mjs +7 -7
  122. package/{fesm2020 → fesm2022}/progress-kendo-angular-inputs.mjs +3718 -2910
  123. package/formfield/error.component.d.ts +1 -1
  124. package/formfield/formfield.component.d.ts +1 -1
  125. package/formfield/hint.component.d.ts +1 -1
  126. package/formfield/models/message-align.d.ts +1 -1
  127. package/formfield/models/orientation.d.ts +1 -1
  128. package/formfield/models/show-options.d.ts +1 -1
  129. package/index.d.ts +0 -1
  130. package/inputs.module.d.ts +1 -1
  131. package/maskedtextbox/maskedtextbox.component.d.ts +1 -1
  132. package/maskedtextbox.module.d.ts +1 -1
  133. package/numerictextbox/localization/messages.d.ts +1 -1
  134. package/numerictextbox/numerictextbox.component.d.ts +1 -1
  135. package/numerictextbox.module.d.ts +1 -1
  136. package/package.json +20 -26
  137. package/radiobutton/radiobutton.component.d.ts +1 -1
  138. package/radiobutton/radiobutton.directive.d.ts +1 -1
  139. package/rangeslider/localization/messages.d.ts +1 -1
  140. package/rangeslider/rangeslider-model.d.ts +0 -1
  141. package/rangeslider/rangeslider-value.type.d.ts +1 -1
  142. package/rangeslider/rangeslider.component.d.ts +1 -1
  143. package/rating/models/precision.d.ts +1 -1
  144. package/rating/models/selection.d.ts +1 -1
  145. package/rating/rating.component.d.ts +1 -1
  146. package/schematics/ngAdd/index.js +1 -1
  147. package/shared/input-separator.component.d.ts +1 -1
  148. package/shared/shared-events.directive.d.ts +1 -1
  149. package/shared/textarea.directive.d.ts +1 -1
  150. package/signature/localization/messages.d.ts +1 -1
  151. package/signature/signature.component.d.ts +1 -1
  152. package/slider/localization/messages.d.ts +1 -1
  153. package/slider/slider-model.d.ts +0 -1
  154. package/slider/slider.component.d.ts +1 -1
  155. package/sliders-common/slider-base.d.ts +1 -1
  156. package/sliders-common/slider-ticks.component.d.ts +1 -1
  157. package/sliders-common/title-callback.d.ts +1 -1
  158. package/switch/localization/messages.d.ts +1 -1
  159. package/switch/switch.component.d.ts +1 -1
  160. package/text-fields-common/text-fields-base.d.ts +1 -1
  161. package/textarea/models/adornments-orientation.d.ts +1 -1
  162. package/textarea/models/flow.d.ts +1 -1
  163. package/textarea/models/resize.d.ts +1 -1
  164. package/textarea/textarea-prefix.component.d.ts +1 -1
  165. package/textarea/textarea-suffix.component.d.ts +1 -1
  166. package/textarea/textarea.component.d.ts +1 -1
  167. package/textarea.module.d.ts +1 -1
  168. package/textbox/localization/messages.d.ts +1 -1
  169. package/textbox/models/icon-show-options.d.ts +1 -1
  170. package/textbox/textbox-prefix.directive.d.ts +1 -1
  171. package/textbox/textbox-suffix.directive.d.ts +1 -1
  172. package/textbox/textbox.component.d.ts +1 -1
  173. package/textbox/textbox.directive.d.ts +1 -1
  174. package/textbox.module.d.ts +1 -1
  175. package/esm2020/colorpicker/localization/messages.mjs +0 -75
  176. package/esm2020/inputs.module.mjs +0 -96
  177. package/esm2020/shared.module.mjs +0 -32
  178. package/esm2020/text-fields-common/text-fields-base.mjs +0 -131
  179. package/fesm2015/progress-kendo-angular-inputs.mjs +0 -17268
  180. package/shared.module.d.ts +0 -19
  181. /package/{esm2020 → esm2022}/checkbox/checked-state.mjs +0 -0
  182. /package/{esm2020 → esm2022}/colorpicker/constants.mjs +0 -0
  183. /package/{esm2020 → esm2022}/colorpicker/events/close-event.mjs +0 -0
  184. /package/{esm2020 → esm2022}/colorpicker/events/kendo-drag-event.mjs +0 -0
  185. /package/{esm2020 → esm2022}/colorpicker/events/open-event.mjs +0 -0
  186. /package/{esm2020 → esm2022}/colorpicker/events.mjs +0 -0
  187. /package/{esm2020 → esm2022}/colorpicker/models/actions-layout.mjs +0 -0
  188. /package/{esm2020 → esm2022}/colorpicker/models/colorpicker-view.mjs +0 -0
  189. /package/{esm2020 → esm2022}/colorpicker/models/gradient-settings.mjs +0 -0
  190. /package/{esm2020 → esm2022}/colorpicker/models/hsva.mjs +0 -0
  191. /package/{esm2020 → esm2022}/colorpicker/models/output-format.mjs +0 -0
  192. /package/{esm2020 → esm2022}/colorpicker/models/palette-presets.mjs +0 -0
  193. /package/{esm2020 → esm2022}/colorpicker/models/palette-settings.mjs +0 -0
  194. /package/{esm2020 → esm2022}/colorpicker/models/popup-settings.mjs +0 -0
  195. /package/{esm2020 → esm2022}/colorpicker/models/rgb.mjs +0 -0
  196. /package/{esm2020 → esm2022}/colorpicker/models/rgba.mjs +0 -0
  197. /package/{esm2020 → esm2022}/colorpicker/models/table-cell.mjs +0 -0
  198. /package/{esm2020 → esm2022}/colorpicker/models/tile-size.mjs +0 -0
  199. /package/{esm2020 → esm2022}/colorpicker/models.mjs +0 -0
  200. /package/{esm2020 → esm2022}/colorpicker/utils/color-parser.mjs +0 -0
  201. /package/{esm2020 → esm2022}/colorpicker/utils/contrast-curve.mjs +0 -0
  202. /package/{esm2020 → esm2022}/colorpicker/utils.mjs +0 -0
  203. /package/{esm2020 → esm2022}/common/dom-utils.mjs +0 -0
  204. /package/{esm2020 → esm2022}/common/math.mjs +0 -0
  205. /package/{esm2020 → esm2022}/common/models/fillmode.mjs +0 -0
  206. /package/{esm2020 → esm2022}/common/models/rounded.mjs +0 -0
  207. /package/{esm2020 → esm2022}/common/models/size.mjs +0 -0
  208. /package/{esm2020 → esm2022}/common/models/styling-classes.mjs +0 -0
  209. /package/{esm2020 → esm2022}/common/models/type.mjs +0 -0
  210. /package/{esm2020 → esm2022}/common/models.mjs +0 -0
  211. /package/{esm2020 → esm2022}/common/utils.mjs +0 -0
  212. /package/{esm2020 → esm2022}/directives.mjs +0 -0
  213. /package/{esm2020 → esm2022}/formfield/models/message-align.mjs +0 -0
  214. /package/{esm2020 → esm2022}/formfield/models/orientation.mjs +0 -0
  215. /package/{esm2020 → esm2022}/formfield/models/show-options.mjs +0 -0
  216. /package/{esm2020 → esm2022}/maskedtextbox/parsing/combinators.mjs +0 -0
  217. /package/{esm2020 → esm2022}/numerictextbox/arrow-direction.mjs +0 -0
  218. /package/{esm2020 → esm2022}/numerictextbox/constants.mjs +0 -0
  219. /package/{esm2020 → esm2022}/numerictextbox/utils.mjs +0 -0
  220. /package/{esm2020 → esm2022}/progress-kendo-angular-inputs.mjs +0 -0
  221. /package/{esm2020 → esm2022}/rangeslider/rangeslider-value.type.mjs +0 -0
  222. /package/{esm2020 → esm2022}/rating/models/precision.mjs +0 -0
  223. /package/{esm2020 → esm2022}/rating/models/rating-item.interface.mjs +0 -0
  224. /package/{esm2020 → esm2022}/rating/models/selection.mjs +0 -0
  225. /package/{esm2020 → esm2022}/shared/utils.mjs +0 -0
  226. /package/{esm2020 → esm2022}/signature/events/close-event.mjs +0 -0
  227. /package/{esm2020 → esm2022}/signature/events/index.mjs +0 -0
  228. /package/{esm2020 → esm2022}/signature/events/open-event.mjs +0 -0
  229. /package/{esm2020 → esm2022}/signature/localization/index.mjs +0 -0
  230. /package/{esm2020 → esm2022}/sliders-common/sliders-util.mjs +0 -0
  231. /package/{esm2020 → esm2022}/sliders-common/title-callback.mjs +0 -0
  232. /package/{esm2020 → esm2022}/textarea/models/adornments-orientation.mjs +0 -0
  233. /package/{esm2020 → esm2022}/textarea/models/flow.mjs +0 -0
  234. /package/{esm2020 → esm2022}/textarea/models/resize.mjs +0 -0
  235. /package/{esm2020 → esm2022}/textbox/models/icon-show-options.mjs +0 -0
  236. /package/{esm2020 → esm2022}/validators/max.validator.mjs +0 -0
  237. /package/{esm2020 → esm2022}/validators/min.validator.mjs +0 -0
@@ -32,108 +32,13 @@ let serial = 0;
32
32
  * The ColorGradient is independently used by `kendo-colorpicker` and can be directly added to the page.
33
33
  */
34
34
  export class ColorGradientComponent {
35
- constructor(host, ngZone, renderer, cdr, localizationService, injector) {
36
- this.host = host;
37
- this.ngZone = ngZone;
38
- this.renderer = renderer;
39
- this.cdr = cdr;
40
- this.localizationService = localizationService;
41
- this.injector = injector;
42
- this.hostClasses = true;
43
- this.ariaRole = 'textbox';
44
- /**
45
- * @hidden
46
- */
47
- this.id = `k-colorgradient-${serial++}`;
48
- /**
49
- * Defines whether the alpha slider will be displayed.
50
- *
51
- * @default true
52
- */
53
- this.opacity = true;
54
- /**
55
- * Sets the disabled state of the ColorGradient. To learn how to disable the component in reactive forms, refer to the article on [Forms Support](slug:formssupport_colorgradient#toc-managing-the-colorgradient-disabled-state-in-reactive-forms).
56
- *
57
- * @default false
58
- */
59
- this.disabled = false;
60
- /**
61
- * Sets the read-only state of the ColorGradient.
62
- *
63
- * @default false
64
- */
65
- this.readonly = false;
66
- /**
67
- * Specifies whether the ColorGradient should display a 'Clear color' button.
68
- *
69
- * @default false
70
- */
71
- this.clearButton = false;
72
- /**
73
- * Determines the delay time (in milliseconds) before the value is changed on handle drag. A value of 0 indicates no delay.
74
- *
75
- * @default 0
76
- */
77
- this.delay = 0;
78
- /**
79
- * Specifies the output format of the ColorGradientComponent.
80
- * The input value may be in a different format, but it will be parsed into the output `format`
81
- * after the component processes it.
82
- *
83
- * The supported values are:
84
- * * (Default) `rgba`
85
- * * `hex`
86
- */
87
- this.format = DEFAULT_OUTPUT_FORMAT;
88
- /**
89
- * Fires each time the user selects a new color.
90
- */
91
- this.valueChange = new EventEmitter();
92
- /**
93
- * @hidden
94
- */
95
- this.backgroundColor = DEFAULT_GRADIENT_BACKGROUND_COLOR;
96
- /**
97
- * @hidden
98
- *
99
- * Represents the currently selected `hue`, `saturation`, `value`, and `alpha` values.
100
- * The values are initially set in `ngOnInit` or in `ngOnChanges` and are
101
- * updated on moving the drag handle or the sliders.
102
- */
103
- this.hsva = new BehaviorSubject({});
104
- /**
105
- * Determines the step (in pixels) when moving the gradient drag handle using the keyboard arrow keys.
106
- *
107
- * @default 5
108
- */
109
- this.gradientSliderStep = DRAGHANDLE_MOVE_SPEED;
110
- /**
111
- * Determines the step (in pixels) when moving the gradient drag handle using the keyboard arrow keys while holding the shift key.
112
- *
113
- * @default 2
114
- */
115
- this.gradientSliderSmallStep = DRAGHANDLE_MOVE_SPEED_SMALL_STEP;
116
- /**
117
- * @hidden
118
- */
119
- this.internalNavigation = false;
120
- /**
121
- * @hidden
122
- */
123
- this.dropletSlashIcon = dropletSlashIcon;
124
- this._tabindex = 0;
125
- this.listeners = [];
126
- this.hueSliderTouched = false;
127
- this.alphaSliderTouched = false;
128
- this.updateValues = new Subject();
129
- this.hsvHandleCoordinates = { x: 0, y: 0 };
130
- this.notifyNgChanged = () => { };
131
- this.notifyNgTouched = () => { };
132
- validatePackage(packageMetadata);
133
- this.dynamicRTLSubscription = localizationService.changes.subscribe(({ rtl }) => {
134
- this.direction = rtl ? 'rtl' : 'ltr';
135
- });
136
- }
35
+ host;
36
+ ngZone;
37
+ renderer;
38
+ cdr;
39
+ localizationService;
40
+ injector;
41
+ hostClasses = true;
137
42
  get readonlyAttribute() {
138
43
  return this.readonly;
139
44
  }
@@ -143,9 +48,11 @@ export class ColorGradientComponent {
143
48
  get gradientId() {
144
49
  return this.id;
145
50
  }
51
+ direction;
146
52
  get hostTabindex() {
147
53
  return this.tabindex?.toString() || '0';
148
54
  }
55
+ ariaRole = 'textbox';
149
56
  get isControlInvalid() {
150
57
  return (this.control?.invalid)?.toString();
151
58
  }
@@ -178,6 +85,40 @@ export class ColorGradientComponent {
178
85
  focusHandler(ev) {
179
86
  this.internalNavigation = ev.target !== this.host.nativeElement;
180
87
  }
88
+ /**
89
+ * @hidden
90
+ */
91
+ id = `k-colorgradient-${serial++}`;
92
+ /**
93
+ * Defines whether the alpha slider will be displayed.
94
+ *
95
+ * @default true
96
+ */
97
+ opacity = true;
98
+ /**
99
+ * Sets the disabled state of the ColorGradient. To learn how to disable the component in reactive forms, refer to the article on [Forms Support](slug:formssupport_colorgradient#toc-managing-the-colorgradient-disabled-state-in-reactive-forms).
100
+ *
101
+ * @default false
102
+ */
103
+ disabled = false;
104
+ /**
105
+ * Sets the read-only state of the ColorGradient.
106
+ *
107
+ * @default false
108
+ */
109
+ readonly = false;
110
+ /**
111
+ * Specifies whether the ColorGradient should display a 'Clear color' button.
112
+ *
113
+ * @default false
114
+ */
115
+ clearButton = false;
116
+ /**
117
+ * Determines the delay time (in milliseconds) before the value is changed on handle drag. A value of 0 indicates no delay.
118
+ *
119
+ * @default 0
120
+ */
121
+ delay = 0;
181
122
  /**
182
123
  * Specifies the value of the initially selected color.
183
124
  */
@@ -215,6 +156,32 @@ export class ColorGradientComponent {
215
156
  get tabindex() {
216
157
  return !this.disabled ? this._tabindex : undefined;
217
158
  }
159
+ /**
160
+ * Specifies the output format of the ColorGradientComponent.
161
+ * The input value may be in a different format, but it will be parsed into the output `format`
162
+ * after the component processes it.
163
+ *
164
+ * The supported values are:
165
+ * * (Default) `rgba`
166
+ * * `hex`
167
+ */
168
+ format = DEFAULT_OUTPUT_FORMAT;
169
+ /**
170
+ * Fires each time the user selects a new color.
171
+ */
172
+ valueChange = new EventEmitter();
173
+ /**
174
+ * @hidden
175
+ */
176
+ backgroundColor = DEFAULT_GRADIENT_BACKGROUND_COLOR;
177
+ /**
178
+ * @hidden
179
+ *
180
+ * Represents the currently selected `hue`, `saturation`, `value`, and `alpha` values.
181
+ * The values are initially set in `ngOnInit` or in `ngOnChanges` and are
182
+ * updated on moving the drag handle or the sliders.
183
+ */
184
+ hsva = new BehaviorSubject({});
218
185
  /**
219
186
  * Indicates whether the ColorGradient or any of its content is focused.
220
187
  */
@@ -234,6 +201,41 @@ export class ColorGradientComponent {
234
201
  }
235
202
  return this.hsva.value.a * 100;
236
203
  }
204
+ /**
205
+ * Determines the step (in pixels) when moving the gradient drag handle using the keyboard arrow keys.
206
+ *
207
+ * @default 5
208
+ */
209
+ gradientSliderStep = DRAGHANDLE_MOVE_SPEED;
210
+ /**
211
+ * Determines the step (in pixels) when moving the gradient drag handle using the keyboard arrow keys while holding the shift key.
212
+ *
213
+ * @default 2
214
+ */
215
+ gradientSliderSmallStep = DRAGHANDLE_MOVE_SPEED_SMALL_STEP;
216
+ gradientDragHandle;
217
+ inputs;
218
+ alphaSlider;
219
+ gradientWrapper;
220
+ hsvRectangle;
221
+ /**
222
+ * @hidden
223
+ */
224
+ internalNavigation = false;
225
+ /**
226
+ * @hidden
227
+ */
228
+ dropletSlashIcon = dropletSlashIcon;
229
+ _value;
230
+ _tabindex = 0;
231
+ _contrastTool;
232
+ listeners = [];
233
+ hueSliderTouched = false;
234
+ alphaSliderTouched = false;
235
+ updateValues = new Subject();
236
+ changeRequestsSubscription;
237
+ dynamicRTLSubscription;
238
+ hsvHandleCoordinates = { x: 0, y: 0 };
237
239
  get gradientRect() {
238
240
  return this.gradientWrapper.nativeElement.getBoundingClientRect();
239
241
  }
@@ -255,6 +257,19 @@ export class ColorGradientComponent {
255
257
  get innerTabIndex() {
256
258
  return this.internalNavigation ? 0 : -1;
257
259
  }
260
+ control;
261
+ constructor(host, ngZone, renderer, cdr, localizationService, injector) {
262
+ this.host = host;
263
+ this.ngZone = ngZone;
264
+ this.renderer = renderer;
265
+ this.cdr = cdr;
266
+ this.localizationService = localizationService;
267
+ this.injector = injector;
268
+ validatePackage(packageMetadata);
269
+ this.dynamicRTLSubscription = localizationService.changes.subscribe(({ rtl }) => {
270
+ this.direction = rtl ? 'rtl' : 'ltr';
271
+ });
272
+ }
258
273
  ngOnInit() {
259
274
  this.control = this.injector.get(NgControl, null);
260
275
  }
@@ -476,6 +491,8 @@ export class ColorGradientComponent {
476
491
  isEmpty() {
477
492
  return false;
478
493
  }
494
+ notifyNgChanged = () => { };
495
+ notifyNgTouched = () => { };
479
496
  moveDragHandle(positionX, positionY) {
480
497
  const gradientRect = this.gradientRect;
481
498
  const gradientRectWidth = gradientRect.width;
@@ -573,28 +590,27 @@ export class ColorGradientComponent {
573
590
  this.changeRequestsSubscription.unsubscribe();
574
591
  }
575
592
  }
576
- }
577
- ColorGradientComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ColorGradientComponent, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i1.LocalizationService }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
578
- ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ColorGradientComponent, isStandalone: true, selector: "kendo-colorgradient", inputs: { id: "id", opacity: "opacity", disabled: "disabled", readonly: "readonly", clearButton: "clearButton", delay: "delay", value: "value", contrastTool: "contrastTool", tabindex: "tabindex", format: "format", gradientSliderStep: "gradientSliderStep", gradientSliderSmallStep: "gradientSliderSmallStep" }, outputs: { valueChange: "valueChange" }, host: { listeners: { "keydown.enter": "enterHandler($event)", "keydown.escape": "escapeHandler($event)", "focusin": "focusHandler($event)" }, properties: { "class.k-colorgradient": "this.hostClasses", "attr.aria-readonly": "this.readonlyAttribute", "class.k-disabled": "this.disabledClass", "attr.id": "this.gradientId", "attr.dir": "this.direction", "attr.tabindex": "this.hostTabindex", "attr.role": "this.ariaRole", "attr.aria-invalid": "this.isControlInvalid", "attr.aria-disabled": "this.isDisabled", "class.k-readonly": "this.readonly" } }, providers: [
579
- {
580
- multi: true,
581
- provide: NG_VALUE_ACCESSOR,
582
- useExisting: forwardRef(() => ColorGradientComponent)
583
- },
584
- {
585
- provide: KendoInput,
586
- useExisting: forwardRef(() => ColorGradientComponent)
587
- },
588
- ColorGradientLocalizationService,
589
- {
590
- provide: LocalizationService,
591
- useExisting: ColorGradientLocalizationService
592
- },
593
- {
594
- provide: L10N_PREFIX,
595
- useValue: 'kendo.colorgradient'
596
- }
597
- ], viewQueries: [{ propertyName: "gradientDragHandle", first: true, predicate: ["gradientDragHandle"], descendants: true }, { propertyName: "inputs", first: true, predicate: ["inputs"], descendants: true }, { propertyName: "alphaSlider", first: true, predicate: ["alphaSlider"], descendants: true }, { propertyName: "gradientWrapper", first: true, predicate: ["gradientWrapper"], descendants: true }, { propertyName: "hsvRectangle", first: true, predicate: ["hsvRectangle"], descendants: true }], exportAs: ["kendoColorGradient"], usesOnChanges: true, ngImport: i0, template: `
593
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ColorGradientComponent, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i1.LocalizationService }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
594
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: ColorGradientComponent, isStandalone: true, selector: "kendo-colorgradient", inputs: { id: "id", opacity: "opacity", disabled: "disabled", readonly: "readonly", clearButton: "clearButton", delay: "delay", value: "value", contrastTool: "contrastTool", tabindex: "tabindex", format: "format", gradientSliderStep: "gradientSliderStep", gradientSliderSmallStep: "gradientSliderSmallStep" }, outputs: { valueChange: "valueChange" }, host: { listeners: { "keydown.enter": "enterHandler($event)", "keydown.escape": "escapeHandler($event)", "focusin": "focusHandler($event)" }, properties: { "class.k-colorgradient": "this.hostClasses", "attr.aria-readonly": "this.readonlyAttribute", "class.k-disabled": "this.disabledClass", "attr.id": "this.gradientId", "attr.dir": "this.direction", "attr.tabindex": "this.hostTabindex", "attr.role": "this.ariaRole", "attr.aria-invalid": "this.isControlInvalid", "attr.aria-disabled": "this.isDisabled", "class.k-readonly": "this.readonly" } }, providers: [
595
+ {
596
+ multi: true,
597
+ provide: NG_VALUE_ACCESSOR,
598
+ useExisting: forwardRef(() => ColorGradientComponent)
599
+ },
600
+ {
601
+ provide: KendoInput,
602
+ useExisting: forwardRef(() => ColorGradientComponent)
603
+ },
604
+ ColorGradientLocalizationService,
605
+ {
606
+ provide: LocalizationService,
607
+ useExisting: ColorGradientLocalizationService
608
+ },
609
+ {
610
+ provide: L10N_PREFIX,
611
+ useValue: 'kendo.colorgradient'
612
+ }
613
+ ], viewQueries: [{ propertyName: "gradientDragHandle", first: true, predicate: ["gradientDragHandle"], descendants: true }, { propertyName: "inputs", first: true, predicate: ["inputs"], descendants: true }, { propertyName: "alphaSlider", first: true, predicate: ["alphaSlider"], descendants: true }, { propertyName: "gradientWrapper", first: true, predicate: ["gradientWrapper"], descendants: true }, { propertyName: "hsvRectangle", first: true, predicate: ["hsvRectangle"], descendants: true }], exportAs: ["kendoColorGradient"], usesOnChanges: true, ngImport: i0, template: `
598
614
  <ng-container kendoColorGradientLocalizedMessages
599
615
  i18n-colorGradientNoColor="kendo.colorgradient.colorGradientNoColor|The aria-label applied to the ColorGradient component when the value is empty."
600
616
  colorGradientNoColor="Colorgradient no color chosen"
@@ -744,7 +760,8 @@ ColorGradientComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0",
744
760
  [ratio]="contrastTool">
745
761
  </div>
746
762
  `, isInline: true, dependencies: [{ kind: "directive", type: LocalizedColorPickerMessagesDirective, selector: "[kendoColorPickerLocalizedMessages], [kendoFlatColorPickerLocalizedMessages], [kendoColorGradientLocalizedMessages], [kendoColorPaletteLocalizedMessages]" }, { kind: "directive", type: DraggableDirective, selector: "[kendoDraggable]", inputs: ["enableDrag"], outputs: ["kendoPress", "kendoDrag", "kendoRelease"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: ColorContrastSvgComponent, selector: "[kendoColorContrastSvg]", inputs: ["wrapper", "hsva", "backgroundColor"] }, { kind: "component", type: ButtonComponent, selector: "button[kendoButton]", inputs: ["arrowIcon", "toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }, { kind: "component", type: SliderComponent, selector: "kendo-slider", inputs: ["focusableId", "dragHandleTitle", "incrementTitle", "animate", "decrementTitle", "showButtons", "value", "tabIndex"], exportAs: ["kendoSlider"] }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: ColorInputComponent, selector: "kendo-colorinput", inputs: ["focusableId", "formatView", "tabindex", "value", "opacity", "disabled", "readonly"], outputs: ["valueChange", "tabOut"] }, { kind: "component", type: ContrastComponent, selector: "[kendoContrastTool]", inputs: ["value", "ratio"] }] });
747
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ColorGradientComponent, decorators: [{
763
+ }
764
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ColorGradientComponent, decorators: [{
748
765
  type: Component,
749
766
  args: [{
750
767
  exportAs: 'kendoColorGradient',
@@ -20,51 +20,61 @@ import * as i1 from "@progress/kendo-angular-l10n";
20
20
  * @hidden
21
21
  */
22
22
  export class ColorInputComponent {
23
- constructor(host, renderer, localizationService) {
24
- this.host = host;
25
- this.renderer = renderer;
26
- this.localizationService = localizationService;
27
- /**
28
- * The id of the hex input.
29
- */
30
- this.focusableId = `k-${guid()}`;
31
- /**
32
- * The inputs tabindex.
33
- */
34
- this.tabindex = -1;
35
- /**
36
- * Sets whether the alpha slider will be shown.
37
- */
38
- this.opacity = true;
39
- /**
40
- * Sets the disabled state of the ColorInput.
41
- */
42
- this.disabled = false;
43
- /**
44
- * Sets the read-only state of the ColorInput.
45
- *
46
- * @default false
47
- */
48
- this.readonly = false;
49
- /**
50
- * Emits a parsed rgba string color.
51
- */
52
- this.valueChange = new EventEmitter();
53
- /**
54
- * Emits when the user tabs out of the last focusable input.
55
- */
56
- this.tabOut = new EventEmitter();
57
- this.colorInputClass = true;
58
- /**
59
- * The rgba inputs values.
60
- */
61
- this.rgba = {};
62
- /**
63
- * @hidden
64
- */
65
- this.caretAltExpandIcon = caretAltExpandIcon;
66
- this.subscriptions = new Subscription();
67
- }
23
+ host;
24
+ renderer;
25
+ localizationService;
26
+ /**
27
+ * The id of the hex input.
28
+ */
29
+ focusableId = `k-${guid()}`;
30
+ /**
31
+ * The color format view.
32
+ */
33
+ formatView;
34
+ /**
35
+ * The inputs tabindex.
36
+ */
37
+ tabindex = -1;
38
+ /**
39
+ * The color value that will be parsed and populate the hex & rgba inputs.
40
+ * Required input property.
41
+ */
42
+ value;
43
+ /**
44
+ * Sets whether the alpha slider will be shown.
45
+ */
46
+ opacity = true;
47
+ /**
48
+ * Sets the disabled state of the ColorInput.
49
+ */
50
+ disabled = false;
51
+ /**
52
+ * Sets the read-only state of the ColorInput.
53
+ *
54
+ * @default false
55
+ */
56
+ readonly = false;
57
+ /**
58
+ * Emits a parsed rgba string color.
59
+ */
60
+ valueChange = new EventEmitter();
61
+ /**
62
+ * Emits when the user tabs out of the last focusable input.
63
+ */
64
+ tabOut = new EventEmitter();
65
+ colorInputClass = true;
66
+ opacityInput;
67
+ hexInput;
68
+ blueInput;
69
+ toggleFormatButton;
70
+ /**
71
+ * The rgba inputs values.
72
+ */
73
+ rgba = {};
74
+ /*
75
+ * The hex input value.
76
+ */
77
+ hex;
68
78
  /**
69
79
  * Indicates whether any of the inputs are focused.
70
80
  */
@@ -81,6 +91,16 @@ export class ColorInputComponent {
81
91
  get rgbaInputValid() {
82
92
  return Object.keys(this.rgba).every(key => isPresent(this.rgba[key]));
83
93
  }
94
+ /**
95
+ * @hidden
96
+ */
97
+ caretAltExpandIcon = caretAltExpandIcon;
98
+ subscriptions = new Subscription();
99
+ constructor(host, renderer, localizationService) {
100
+ this.host = host;
101
+ this.renderer = renderer;
102
+ this.localizationService = localizationService;
103
+ }
84
104
  ngAfterViewInit() {
85
105
  this.initDomEvents();
86
106
  }
@@ -152,9 +172,8 @@ export class ColorInputComponent {
152
172
  lastInput() {
153
173
  return this.hexInput?.nativeElement || this.opacityInput || this.blueInput;
154
174
  }
155
- }
156
- ColorInputComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ColorInputComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i1.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
157
- ColorInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ColorInputComponent, isStandalone: true, selector: "kendo-colorinput", inputs: { focusableId: "focusableId", formatView: "formatView", tabindex: "tabindex", value: "value", opacity: "opacity", disabled: "disabled", readonly: "readonly" }, outputs: { valueChange: "valueChange", tabOut: "tabOut" }, host: { properties: { "class.k-colorgradient-inputs": "this.colorInputClass", "class.k-hstack": "this.colorInputClass" } }, viewQueries: [{ propertyName: "opacityInput", first: true, predicate: ["opacityInput"], descendants: true }, { propertyName: "hexInput", first: true, predicate: ["hexInput"], descendants: true }, { propertyName: "blueInput", first: true, predicate: ["blue"], descendants: true }, { propertyName: "toggleFormatButton", first: true, predicate: ["toggleFormatButton"], descendants: true, read: ElementRef }], usesOnChanges: true, ngImport: i0, template: `
175
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ColorInputComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i1.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
176
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: ColorInputComponent, isStandalone: true, selector: "kendo-colorinput", inputs: { focusableId: "focusableId", formatView: "formatView", tabindex: "tabindex", value: "value", opacity: "opacity", disabled: "disabled", readonly: "readonly" }, outputs: { valueChange: "valueChange", tabOut: "tabOut" }, host: { properties: { "class.k-colorgradient-inputs": "this.colorInputClass", "class.k-hstack": "this.colorInputClass" } }, viewQueries: [{ propertyName: "opacityInput", first: true, predicate: ["opacityInput"], descendants: true }, { propertyName: "hexInput", first: true, predicate: ["hexInput"], descendants: true }, { propertyName: "blueInput", first: true, predicate: ["blue"], descendants: true }, { propertyName: "toggleFormatButton", first: true, predicate: ["toggleFormatButton"], descendants: true, read: ElementRef }], usesOnChanges: true, ngImport: i0, template: `
158
177
  <div class="k-vstack">
159
178
  <button
160
179
  kendoButton
@@ -273,7 +292,8 @@ ColorInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", ve
273
292
  </div>
274
293
  </ng-container>
275
294
  `, isInline: true, dependencies: [{ kind: "component", type: ButtonComponent, selector: "button[kendoButton]", inputs: ["arrowIcon", "toggleable", "togglable", "selected", "tabIndex", "imageUrl", "iconClass", "icon", "disabled", "size", "rounded", "fillMode", "themeColor", "svgIcon", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: NumericTextBoxComponent, selector: "kendo-numerictextbox", inputs: ["focusableId", "disabled", "readonly", "title", "autoCorrect", "format", "max", "min", "decimals", "placeholder", "step", "spinners", "rangeValidation", "tabindex", "tabIndex", "changeValueOnScroll", "selectOnFocus", "value", "maxlength", "size", "rounded", "fillMode", "inputAttributes"], outputs: ["valueChange", "focus", "blur", "inputFocus", "inputBlur"], exportAs: ["kendoNumericTextBox"] }, { kind: "directive", type: NumericLabelDirective, selector: "[kendoAdditionalNumericLabel]", inputs: ["kendoAdditionalNumericLabel", "localizationService"] }] });
276
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ColorInputComponent, decorators: [{
295
+ }
296
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: ColorInputComponent, decorators: [{
277
297
  type: Component,
278
298
  args: [{
279
299
  selector: 'kendo-colorinput',