@progress/kendo-angular-inputs 8.0.9-dev.202203231216 → 9.0.0-dev.202204191046
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/bundles/kendo-angular-inputs.umd.js +5 -0
- package/{dist/es2015/checkbox → checkbox}/checkbox.directive.d.ts +15 -10
- package/{dist/es2015/checkbox.module.d.ts → checkbox.module.d.ts} +6 -0
- package/{dist/es2015/colorpicker → colorpicker}/color-contrast-svg.component.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/color-gradient.component.d.ts +23 -17
- package/{dist/es2015/colorpicker → colorpicker}/color-input.component.d.ts +6 -3
- package/{dist/es2015/colorpicker → colorpicker}/color-palette.component.d.ts +17 -10
- package/{dist/es2015/colorpicker → colorpicker}/colorpicker.component.d.ts +43 -31
- package/{dist/es2015/colorpicker → colorpicker}/constants.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/contrast-validation.component.d.ts +6 -3
- package/{dist/es2015/colorpicker → colorpicker}/contrast.component.d.ts +8 -5
- package/{dist/es2015/colorpicker → colorpicker}/events/active-color-click-event.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/events/cancel-event.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/events/close-event.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/events/kendo-drag-event.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/events/open-event.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/events.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/flatcolorpicker-actions.component.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/flatcolorpicker-header.component.d.ts +5 -2
- package/{dist/es2015/colorpicker → colorpicker}/flatcolorpicker.component.d.ts +15 -8
- package/{dist/es2015/colorpicker → colorpicker}/focus-on-dom-ready.directive.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/localization/colorgradient-localization.service.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/localization/colorpalette-localization.service.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/localization/colorpicker-localization.service.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/localization/custom-messages.component.d.ts +4 -1
- package/{dist/es2015/colorpicker → colorpicker}/localization/flatcolorpicker-localization.service.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/localization/localized-colorpicker-messages.directive.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/localization/messages.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/actions-layout.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/colorpicker-view.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/gradient-settings.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/hsva.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/output-format.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/palette-presets.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/palette-settings.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/popup-settings.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/rgb.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/rgba.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/table-cell.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/models/tile-size.d.ts +2 -2
- package/{dist/es2015/colorpicker → colorpicker}/models.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/services/color-palette.service.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/services/flatcolorpicker.service.d.ts +3 -0
- package/{dist/es2015/colorpicker → colorpicker}/utils/color-parser.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/utils/contrast-curve.d.ts +0 -0
- package/{dist/es2015/colorpicker → colorpicker}/utils.d.ts +0 -0
- package/colorpicker.module.d.ts +32 -0
- package/{dist/es2015/common → common}/dom-utils.d.ts +0 -0
- package/{dist/es2015/common → common}/math.d.ts +0 -0
- package/{dist/es2015/common → common}/models/fillmode.d.ts +2 -6
- package/{dist/es2015/common → common}/models/rounded.d.ts +4 -13
- package/{dist/es2015/common → common}/models/size.d.ts +2 -7
- package/{dist/es2015/common → common}/models/styling-classes.d.ts +0 -0
- package/{dist/es2015/common → common}/models.d.ts +0 -0
- package/{dist/es2015/common → common}/utils.d.ts +0 -0
- package/{dist/es2015 → esm2015}/checkbox/checkbox.directive.js +35 -38
- package/{dist/es2015 → esm2015}/checkbox.module.js +14 -11
- package/{dist/es2015 → esm2015}/colorpicker/color-contrast-svg.component.js +25 -30
- package/{dist/es2015 → esm2015}/colorpicker/color-gradient.component.js +231 -137
- package/{dist/es2015 → esm2015}/colorpicker/color-input.component.js +143 -65
- package/{dist/es2015 → esm2015}/colorpicker/color-palette.component.js +139 -132
- package/{dist/es2015 → esm2015}/colorpicker/colorpicker.component.js +249 -231
- package/{dist/es2015 → esm2015}/colorpicker/constants.js +0 -0
- package/esm2015/colorpicker/contrast-validation.component.js +67 -0
- package/esm2015/colorpicker/contrast.component.js +95 -0
- package/{dist/es2015 → esm2015}/colorpicker/events/active-color-click-event.js +0 -0
- package/{dist/es2015 → esm2015}/colorpicker/events/cancel-event.js +0 -0
- package/{dist/es2015 → esm2015}/colorpicker/events/close-event.js +0 -0
- package/{dist/es2015 → esm2015}/colorpicker/events/kendo-drag-event.js +1 -0
- package/{dist/es2015 → esm2015}/colorpicker/events/open-event.js +0 -0
- package/{dist/es → esm2015}/colorpicker/events.js +0 -0
- package/esm2015/colorpicker/flatcolorpicker-actions.component.js +77 -0
- package/esm2015/colorpicker/flatcolorpicker-header.component.js +161 -0
- package/{dist/es2015 → esm2015}/colorpicker/flatcolorpicker.component.js +207 -153
- package/esm2015/colorpicker/focus-on-dom-ready.directive.js +29 -0
- package/esm2015/colorpicker/localization/colorgradient-localization.service.js +45 -0
- package/esm2015/colorpicker/localization/colorpalette-localization.service.js +45 -0
- package/esm2015/colorpicker/localization/colorpicker-localization.service.js +31 -0
- package/esm2015/colorpicker/localization/custom-messages.component.js +40 -0
- package/esm2015/colorpicker/localization/flatcolorpicker-localization.service.js +45 -0
- package/esm2015/colorpicker/localization/localized-colorpicker-messages.directive.js +36 -0
- package/esm2015/colorpicker/localization/messages.js +67 -0
- package/{dist/es2015 → esm2015}/colorpicker/models/actions-layout.js +1 -0
- package/{dist/es → esm2015}/colorpicker/models/colorpicker-view.js +1 -0
- package/{dist/es2015 → esm2015}/colorpicker/models/gradient-settings.js +1 -0
- package/{dist/es → esm2015}/colorpicker/models/hsva.js +1 -0
- package/{dist/es → esm2015}/colorpicker/models/output-format.js +1 -0
- package/{dist/es2015 → esm2015}/colorpicker/models/palette-presets.js +1 -1
- package/{dist/es → esm2015}/colorpicker/models/palette-settings.js +1 -0
- package/{dist/es → esm2015}/colorpicker/models/popup-settings.js +1 -0
- package/{dist/es → esm2015}/colorpicker/models/rgb.js +1 -0
- package/{dist/es → esm2015}/colorpicker/models/rgba.js +1 -0
- package/{dist/es → esm2015}/colorpicker/models/table-cell.js +1 -0
- package/{dist/es → esm2015}/colorpicker/models/tile-size.js +2 -0
- package/esm2015/colorpicker/models.js +16 -0
- package/{dist/es2015 → esm2015}/colorpicker/services/color-palette.service.js +8 -10
- package/{dist/es2015 → esm2015}/colorpicker/services/flatcolorpicker.service.js +8 -7
- package/{dist/es2015 → esm2015}/colorpicker/utils/color-parser.js +0 -0
- package/{dist/es2015 → esm2015}/colorpicker/utils/contrast-curve.js +0 -0
- package/{dist/es → esm2015}/colorpicker/utils.js +0 -0
- package/{dist/es2015 → esm2015}/colorpicker.module.js +44 -15
- package/{dist/es2015 → esm2015}/common/dom-utils.js +0 -2
- package/{dist/es2015 → esm2015}/common/math.js +0 -2
- package/{dist/es → esm2015}/common/models/fillmode.js +1 -0
- package/{dist/es → esm2015}/common/models/rounded.js +1 -0
- package/{dist/es → esm2015}/common/models/size.js +1 -0
- package/{dist/es → esm2015}/common/models/styling-classes.js +1 -0
- package/{dist/es → esm2015}/common/models.js +4 -0
- package/{dist/es2015 → esm2015}/common/utils.js +3 -3
- package/esm2015/formfield/error.component.js +68 -0
- package/{dist/es2015 → esm2015}/formfield/formfield.component.js +68 -72
- package/esm2015/formfield/hint.component.js +63 -0
- package/{dist/es → esm2015}/formfield/models/message-align.js +1 -0
- package/{dist/es → esm2015}/formfield/models/orientation.js +1 -0
- package/{dist/es → esm2015}/formfield/models/show-options.js +1 -0
- package/{dist/es2015 → esm2015}/formfield.module.js +14 -11
- package/{dist/es2015 → esm2015}/inputs.module.js +45 -22
- package/{dist/es2015/sliders-common/sliders-common.module.d.ts → esm2015/kendo-angular-inputs.js} +2 -3
- package/{dist/es2015 → esm2015}/main.js +6 -0
- package/{dist/es2015 → esm2015}/maskedtextbox/maskedtextbox.component.js +163 -171
- package/{dist/es2015 → esm2015}/maskedtextbox/masking.service.js +8 -10
- package/{dist/es2015 → esm2015}/maskedtextbox/parsing/combinators.js +0 -3
- package/{dist/es2015 → esm2015}/maskedtextbox/parsing/parsers.js +0 -2
- package/{dist/es2015 → esm2015}/maskedtextbox/parsing/result.js +1 -0
- package/{dist/es2015 → esm2015}/maskedtextbox/parsing/stream.js +0 -0
- package/{dist/es → esm2015}/maskedtextbox.module.js +14 -14
- package/{dist/es → esm2015}/numerictextbox/arrow-direction.js +0 -0
- package/{dist/es2015 → esm2015}/numerictextbox/constants.js +0 -0
- package/esm2015/numerictextbox/localization/custom-messages.component.js +40 -0
- package/esm2015/numerictextbox/localization/localized-numerictextbox-messages.directive.js +36 -0
- package/esm2015/numerictextbox/localization/messages.js +25 -0
- package/{dist/es2015 → esm2015}/numerictextbox/numerictextbox.component.js +185 -169
- package/{dist/es2015 → esm2015}/numerictextbox/utils.js +1 -1
- package/{dist/es2015 → esm2015}/numerictextbox.module.js +24 -18
- package/{dist/es2015 → esm2015}/package-metadata.js +1 -1
- package/{dist/es2015 → esm2015}/radiobutton/radiobutton.directive.js +25 -26
- package/{dist/es2015 → esm2015}/radiobutton.module.js +14 -11
- package/esm2015/rangeslider/localization/custom-messages.component.js +40 -0
- package/esm2015/rangeslider/localization/localized-rangeslider-messages.directive.js +36 -0
- package/esm2015/rangeslider/localization/messages.js +25 -0
- package/{dist/es2015 → esm2015}/rangeslider/rangeslider-model.js +0 -0
- package/{dist/es → esm2015}/rangeslider/rangeslider-value.type.js +1 -0
- package/{dist/es2015 → esm2015}/rangeslider/rangeslider.component.js +114 -38
- package/{dist/es2015 → esm2015}/rangeslider.module.js +28 -20
- package/esm2015/shared/input-separator.component.js +41 -0
- package/{dist/es2015 → esm2015}/shared/textarea.directive.js +58 -52
- package/{dist/es2015 → esm2015}/shared/utils.js +0 -0
- package/esm2015/shared.module.js +32 -0
- package/esm2015/slider/localization/custom-messages.component.js +40 -0
- package/esm2015/slider/localization/localized-slider-messages.directive.js +36 -0
- package/esm2015/slider/localization/messages.js +27 -0
- package/{dist/es2015 → esm2015}/slider/slider-model.js +0 -0
- package/{dist/es2015 → esm2015}/slider/slider.component.js +132 -70
- package/{dist/es → esm2015}/slider.module.js +28 -23
- package/{dist/es2015 → esm2015}/sliders-common/label-template.directive.js +14 -12
- package/{dist/es2015 → esm2015}/sliders-common/slider-base.js +77 -112
- package/{dist/es2015 → esm2015}/sliders-common/slider-model.base.js +0 -0
- package/esm2015/sliders-common/slider-ticks.component.js +125 -0
- package/esm2015/sliders-common/sliders-common.module.js +42 -0
- package/{dist/es2015 → esm2015}/sliders-common/sliders-util.js +0 -0
- package/{dist/es/colorpicker/events/kendo-drag-event.js → esm2015/sliders-common/title-callback.js} +1 -0
- package/esm2015/switch/localization/custom-messages.component.js +40 -0
- package/esm2015/switch/localization/localized-switch-messages.directive.js +36 -0
- package/esm2015/switch/localization/messages.js +25 -0
- package/{dist/es2015 → esm2015}/switch/switch.component.js +166 -154
- package/{dist/es2015 → esm2015}/switch.module.js +26 -19
- package/{dist/es2015 → esm2015}/text-fields-common/text-fields-base.js +37 -47
- package/{dist/es → esm2015}/textarea/models/flow.js +1 -0
- package/{dist/es → esm2015}/textarea/models/resize.js +1 -0
- package/esm2015/textarea/textarea-suffix.component.js +40 -0
- package/{dist/es2015 → esm2015}/textarea/textarea.component.js +126 -122
- package/{dist/es → esm2015}/textarea.module.js +27 -22
- package/esm2015/textbox/localization/custom-messages.component.js +40 -0
- package/esm2015/textbox/localization/localized-textbox-messages.directive.js +36 -0
- package/esm2015/textbox/localization/messages.js +23 -0
- package/{dist/es → esm2015}/textbox/models/icon-show-options.js +1 -0
- package/esm2015/textbox/textbox-prefix.directive.js +38 -0
- package/esm2015/textbox/textbox-suffix.directive.js +37 -0
- package/{dist/es2015 → esm2015}/textbox/textbox.component.js +180 -174
- package/{dist/es2015 → esm2015}/textbox/textbox.directive.js +36 -31
- package/esm2015/textbox.module.js +88 -0
- package/{dist/es2015 → esm2015}/validators/max.validator.js +0 -0
- package/{dist/es2015 → esm2015}/validators/min.validator.js +0 -0
- package/{dist/fesm2015/index.js → fesm2015/kendo-angular-inputs.js} +4205 -3515
- package/{dist/es2015/formfield → formfield}/error.component.d.ts +6 -3
- package/{dist/es2015/formfield → formfield}/formfield.component.d.ts +9 -6
- package/{dist/es2015/formfield → formfield}/hint.component.d.ts +6 -3
- package/{dist/es2015/formfield → formfield}/models/message-align.d.ts +0 -0
- package/{dist/es2015/formfield → formfield}/models/orientation.d.ts +1 -5
- package/{dist/es2015/formfield → formfield}/models/show-options.d.ts +0 -0
- package/{dist/es2015/formfield.module.d.ts → formfield.module.d.ts} +8 -0
- package/{dist/es2015/inputs.module.d.ts → inputs.module.d.ts} +16 -0
- package/kendo-angular-inputs.d.ts +9 -0
- package/{dist/es2015/main.d.ts → main.d.ts} +6 -0
- package/{dist/es2015/maskedtextbox → maskedtextbox}/maskedtextbox.component.d.ts +28 -17
- package/{dist/es2015/maskedtextbox → maskedtextbox}/masking.service.d.ts +7 -4
- package/{dist/es2015/maskedtextbox → maskedtextbox}/parsing/combinators.d.ts +0 -0
- package/{dist/es2015/maskedtextbox → maskedtextbox}/parsing/parsers.d.ts +0 -0
- package/{dist/es2015/maskedtextbox → maskedtextbox}/parsing/result.d.ts +0 -0
- package/{dist/es2015/maskedtextbox → maskedtextbox}/parsing/stream.d.ts +0 -0
- package/{dist/es2015/maskedtextbox.module.d.ts → maskedtextbox.module.d.ts} +7 -0
- package/{dist/es2015/numerictextbox → numerictextbox}/arrow-direction.d.ts +0 -0
- package/{dist/es2015/numerictextbox → numerictextbox}/constants.d.ts +0 -0
- package/{dist/es2015/numerictextbox → numerictextbox}/localization/custom-messages.component.d.ts +4 -1
- package/{dist/es2015/numerictextbox → numerictextbox}/localization/localized-numerictextbox-messages.directive.d.ts +3 -0
- package/{dist/es2015/numerictextbox → numerictextbox}/localization/messages.d.ts +3 -0
- package/{dist/es2015/numerictextbox → numerictextbox}/numerictextbox.component.d.ts +35 -25
- package/{dist/es2015/numerictextbox → numerictextbox}/utils.d.ts +0 -0
- package/{dist/es2015/numerictextbox.module.d.ts → numerictextbox.module.d.ts} +9 -0
- package/{dist/es2015/package-metadata.d.ts → package-metadata.d.ts} +0 -0
- package/package.json +40 -114
- package/{dist/es2015/radiobutton → radiobutton}/radiobutton.directive.d.ts +9 -5
- package/{dist/es2015/radiobutton.module.d.ts → radiobutton.module.d.ts} +6 -0
- package/{dist/es2015/rangeslider → rangeslider}/localization/custom-messages.component.d.ts +4 -1
- package/{dist/es2015/rangeslider → rangeslider}/localization/localized-rangeslider-messages.directive.d.ts +3 -0
- package/{dist/es2015/rangeslider → rangeslider}/localization/messages.d.ts +3 -0
- package/{dist/es2015/rangeslider → rangeslider}/rangeslider-model.d.ts +0 -0
- package/{dist/es2015/rangeslider → rangeslider}/rangeslider-value.type.d.ts +0 -0
- package/{dist/es2015/rangeslider → rangeslider}/rangeslider.component.d.ts +7 -4
- package/{dist/es2015/rangeslider.module.d.ts → rangeslider.module.d.ts} +10 -0
- package/schematics/ngAdd/index.js +5 -2
- package/schematics/ngAdd/index.js.map +1 -1
- package/{dist/es2015/shared → shared}/input-separator.component.d.ts +3 -0
- package/{dist/es2015/shared → shared}/textarea.directive.d.ts +7 -2
- package/{dist/es2015/shared → shared}/utils.d.ts +0 -0
- package/{dist/es2015/shared.module.d.ts → shared.module.d.ts} +6 -0
- package/{dist/es2015/slider → slider}/localization/custom-messages.component.d.ts +4 -1
- package/{dist/es2015/slider → slider}/localization/localized-slider-messages.directive.d.ts +3 -0
- package/{dist/es2015/slider → slider}/localization/messages.d.ts +3 -0
- package/{dist/es2015/slider → slider}/slider-model.d.ts +0 -0
- package/{dist/es2015/slider → slider}/slider.component.d.ts +11 -7
- package/{dist/es2015/slider.module.d.ts → slider.module.d.ts} +10 -0
- package/{dist/es2015/sliders-common → sliders-common}/label-template.directive.d.ts +3 -0
- package/{dist/es2015/sliders-common → sliders-common}/slider-base.d.ts +11 -8
- package/{dist/es2015/sliders-common → sliders-common}/slider-model.base.d.ts +0 -0
- package/{dist/es2015/sliders-common → sliders-common}/slider-ticks.component.d.ts +3 -0
- package/sliders-common/sliders-common.module.d.ts +17 -0
- package/{dist/es2015/sliders-common → sliders-common}/sliders-util.d.ts +3 -2
- package/sliders-common/title-callback.d.ts +10 -0
- package/{dist/es2015/switch → switch}/localization/custom-messages.component.d.ts +4 -1
- package/{dist/es2015/switch → switch}/localization/localized-switch-messages.directive.d.ts +3 -0
- package/{dist/es2015/switch → switch}/localization/messages.d.ts +3 -0
- package/{dist/es2015/switch → switch}/switch.component.d.ts +35 -27
- package/{dist/es2015/switch.module.d.ts → switch.module.d.ts} +9 -0
- package/{dist/es2015/text-fields-common → text-fields-common}/text-fields-base.d.ts +4 -1
- package/{dist/es2015/textarea → textarea}/models/flow.d.ts +0 -0
- package/{dist/es2015/textarea → textarea}/models/resize.d.ts +0 -0
- package/{dist/es2015/textarea → textarea}/textarea-suffix.component.d.ts +3 -0
- package/{dist/es2015/textarea → textarea}/textarea.component.d.ts +28 -20
- package/{dist/es2015/textarea.module.d.ts → textarea.module.d.ts} +11 -0
- package/{dist/es2015/textbox → textbox}/localization/custom-messages.component.d.ts +4 -1
- package/{dist/es2015/textbox → textbox}/localization/localized-textbox-messages.directive.d.ts +3 -0
- package/{dist/es2015/textbox → textbox}/localization/messages.d.ts +3 -0
- package/{dist/es2015/textbox → textbox}/models/icon-show-options.d.ts +0 -0
- package/{dist/es2015/textbox → textbox}/textbox-prefix.directive.d.ts +3 -0
- package/{dist/es2015/textbox → textbox}/textbox-suffix.directive.d.ts +3 -0
- package/{dist/es2015/textbox → textbox}/textbox.component.d.ts +32 -24
- package/{dist/es2015/textbox → textbox}/textbox.directive.d.ts +9 -4
- package/textbox.module.d.ts +52 -0
- package/{dist/es2015/validators → validators}/max.validator.d.ts +0 -0
- package/{dist/es2015/validators → validators}/min.validator.d.ts +0 -0
- package/dist/cdn/js/kendo-angular-inputs.js +0 -20
- package/dist/cdn/main.js +0 -5
- package/dist/es/checkbox/checkbox.directive.js +0 -107
- package/dist/es/checkbox.module.js +0 -52
- package/dist/es/colorpicker/color-contrast-svg.component.js +0 -95
- package/dist/es/colorpicker/color-gradient.component.js +0 -697
- package/dist/es/colorpicker/color-input.component.js +0 -193
- package/dist/es/colorpicker/color-palette.component.js +0 -523
- package/dist/es/colorpicker/colorpicker.component.js +0 -958
- package/dist/es/colorpicker/constants.js +0 -36
- package/dist/es/colorpicker/contrast-validation.component.js +0 -59
- package/dist/es/colorpicker/contrast.component.js +0 -70
- package/dist/es/colorpicker/events/active-color-click-event.js +0 -60
- package/dist/es/colorpicker/events/cancel-event.js +0 -19
- package/dist/es/colorpicker/events/close-event.js +0 -17
- package/dist/es/colorpicker/events/open-event.js +0 -17
- package/dist/es/colorpicker/flatcolorpicker-actions.component.js +0 -50
- package/dist/es/colorpicker/flatcolorpicker-header.component.js +0 -94
- package/dist/es/colorpicker/flatcolorpicker.component.js +0 -549
- package/dist/es/colorpicker/focus-on-dom-ready.directive.js +0 -31
- package/dist/es/colorpicker/localization/colorgradient-localization.service.js +0 -34
- package/dist/es/colorpicker/localization/colorpalette-localization.service.js +0 -34
- package/dist/es/colorpicker/localization/colorpicker-localization.service.js +0 -24
- package/dist/es/colorpicker/localization/custom-messages.component.js +0 -43
- package/dist/es/colorpicker/localization/flatcolorpicker-localization.service.js +0 -34
- package/dist/es/colorpicker/localization/localized-colorpicker-messages.directive.js +0 -35
- package/dist/es/colorpicker/localization/messages.js +0 -110
- package/dist/es/colorpicker/models/actions-layout.js +0 -4
- package/dist/es/colorpicker/models/gradient-settings.js +0 -4
- package/dist/es/colorpicker/models/palette-presets.js +0 -62
- package/dist/es/colorpicker/models.js +0 -5
- package/dist/es/colorpicker/services/color-palette.service.js +0 -67
- package/dist/es/colorpicker/services/flatcolorpicker.service.js +0 -41
- package/dist/es/colorpicker/utils/color-parser.js +0 -170
- package/dist/es/colorpicker/utils/contrast-curve.js +0 -91
- package/dist/es/colorpicker.module.js +0 -67
- package/dist/es/common/dom-utils.js +0 -47
- package/dist/es/common/math.js +0 -67
- package/dist/es/common/utils.js +0 -73
- package/dist/es/formfield/error.component.js +0 -85
- package/dist/es/formfield/formfield.component.js +0 -296
- package/dist/es/formfield/hint.component.js +0 -79
- package/dist/es/formfield.module.js +0 -54
- package/dist/es/index.js +0 -37
- package/dist/es/inputs.module.js +0 -74
- package/dist/es/main.js +0 -53
- package/dist/es/maskedtextbox/maskedtextbox.component.js +0 -729
- package/dist/es/maskedtextbox/masking.service.js +0 -215
- package/dist/es/maskedtextbox/parsing/combinators.js +0 -31
- package/dist/es/maskedtextbox/parsing/parsers.js +0 -160
- package/dist/es/maskedtextbox/parsing/result.js +0 -43
- package/dist/es/maskedtextbox/parsing/stream.js +0 -45
- package/dist/es/numerictextbox/constants.js +0 -28
- package/dist/es/numerictextbox/localization/custom-messages.component.js +0 -43
- package/dist/es/numerictextbox/localization/localized-numerictextbox-messages.directive.js +0 -35
- package/dist/es/numerictextbox/localization/messages.js +0 -26
- package/dist/es/numerictextbox/numerictextbox.component.js +0 -1049
- package/dist/es/numerictextbox/utils.js +0 -91
- package/dist/es/numerictextbox.module.js +0 -62
- package/dist/es/package-metadata.js +0 -15
- package/dist/es/radiobutton/radiobutton.directive.js +0 -83
- package/dist/es/radiobutton.module.js +0 -52
- package/dist/es/rangeslider/localization/custom-messages.component.js +0 -43
- package/dist/es/rangeslider/localization/localized-rangeslider-messages.directive.js +0 -35
- package/dist/es/rangeslider/localization/messages.js +0 -26
- package/dist/es/rangeslider/rangeslider-model.js +0 -59
- package/dist/es/rangeslider/rangeslider.component.js +0 -471
- package/dist/es/rangeslider.module.js +0 -66
- package/dist/es/shared/input-separator.component.js +0 -41
- package/dist/es/shared/textarea.directive.js +0 -269
- package/dist/es/shared/utils.js +0 -24
- package/dist/es/shared.module.js +0 -30
- package/dist/es/slider/localization/custom-messages.component.js +0 -43
- package/dist/es/slider/localization/localized-slider-messages.directive.js +0 -35
- package/dist/es/slider/localization/messages.js +0 -30
- package/dist/es/slider/slider-model.js +0 -41
- package/dist/es/slider/slider.component.js +0 -482
- package/dist/es/sliders-common/label-template.directive.js +0 -44
- package/dist/es/sliders-common/slider-base.js +0 -326
- package/dist/es/sliders-common/slider-model.base.js +0 -96
- package/dist/es/sliders-common/slider-ticks.component.js +0 -104
- package/dist/es/sliders-common/sliders-common.module.js +0 -35
- package/dist/es/sliders-common/sliders-util.js +0 -234
- package/dist/es/switch/localization/custom-messages.component.js +0 -43
- package/dist/es/switch/localization/localized-switch-messages.directive.js +0 -35
- package/dist/es/switch/localization/messages.js +0 -26
- package/dist/es/switch/switch.component.js +0 -570
- package/dist/es/switch.module.js +0 -64
- package/dist/es/text-fields-common/text-fields-base.js +0 -144
- package/dist/es/textarea/textarea-suffix.component.js +0 -40
- package/dist/es/textarea/textarea.component.js +0 -600
- package/dist/es/textbox/localization/custom-messages.component.js +0 -43
- package/dist/es/textbox/localization/localized-textbox-messages.directive.js +0 -35
- package/dist/es/textbox/localization/messages.js +0 -22
- package/dist/es/textbox/textbox-prefix.directive.js +0 -37
- package/dist/es/textbox/textbox-suffix.directive.js +0 -36
- package/dist/es/textbox/textbox.component.js +0 -763
- package/dist/es/textbox/textbox.directive.js +0 -127
- package/dist/es/textbox.module.js +0 -75
- package/dist/es/validators/max.validator.js +0 -21
- package/dist/es/validators/min.validator.js +0 -21
- package/dist/es2015/colorpicker/contrast-validation.component.js +0 -58
- package/dist/es2015/colorpicker/contrast.component.js +0 -72
- package/dist/es2015/colorpicker/events.js +0 -8
- package/dist/es2015/colorpicker/flatcolorpicker-actions.component.js +0 -62
- package/dist/es2015/colorpicker/flatcolorpicker-header.component.js +0 -133
- package/dist/es2015/colorpicker/focus-on-dom-ready.directive.js +0 -29
- package/dist/es2015/colorpicker/localization/colorgradient-localization.service.js +0 -31
- package/dist/es2015/colorpicker/localization/colorpalette-localization.service.js +0 -31
- package/dist/es2015/colorpicker/localization/colorpicker-localization.service.js +0 -22
- package/dist/es2015/colorpicker/localization/custom-messages.component.js +0 -35
- package/dist/es2015/colorpicker/localization/flatcolorpicker-localization.service.js +0 -31
- package/dist/es2015/colorpicker/localization/localized-colorpicker-messages.directive.js +0 -31
- package/dist/es2015/colorpicker/localization/messages.js +0 -104
- package/dist/es2015/colorpicker/models/colorpicker-view.js +0 -4
- package/dist/es2015/colorpicker/models/hsva.js +0 -4
- package/dist/es2015/colorpicker/models/output-format.js +0 -4
- package/dist/es2015/colorpicker/models/palette-settings.js +0 -4
- package/dist/es2015/colorpicker/models/popup-settings.js +0 -4
- package/dist/es2015/colorpicker/models/rgb.js +0 -4
- package/dist/es2015/colorpicker/models/rgba.js +0 -4
- package/dist/es2015/colorpicker/models/table-cell.js +0 -4
- package/dist/es2015/colorpicker/models/tile-size.js +0 -4
- package/dist/es2015/colorpicker/models.js +0 -5
- package/dist/es2015/colorpicker/utils.js +0 -6
- package/dist/es2015/colorpicker.module.d.ts +0 -10
- package/dist/es2015/common/models/fillmode.js +0 -4
- package/dist/es2015/common/models/rounded.js +0 -4
- package/dist/es2015/common/models/size.js +0 -4
- package/dist/es2015/common/models/styling-classes.js +0 -4
- package/dist/es2015/common/models.js +0 -4
- package/dist/es2015/formfield/error.component.js +0 -78
- package/dist/es2015/formfield/hint.component.js +0 -71
- package/dist/es2015/formfield/models/message-align.js +0 -4
- package/dist/es2015/formfield/models/orientation.js +0 -4
- package/dist/es2015/formfield/models/show-options.js +0 -4
- package/dist/es2015/index.d.ts +0 -37
- package/dist/es2015/index.js +0 -37
- package/dist/es2015/index.metadata.json +0 -1
- package/dist/es2015/maskedtextbox.module.js +0 -50
- package/dist/es2015/numerictextbox/arrow-direction.js +0 -13
- package/dist/es2015/numerictextbox/localization/custom-messages.component.js +0 -35
- package/dist/es2015/numerictextbox/localization/localized-numerictextbox-messages.directive.js +0 -31
- package/dist/es2015/numerictextbox/localization/messages.js +0 -20
- package/dist/es2015/rangeslider/localization/custom-messages.component.js +0 -35
- package/dist/es2015/rangeslider/localization/localized-rangeslider-messages.directive.js +0 -31
- package/dist/es2015/rangeslider/localization/messages.js +0 -20
- package/dist/es2015/rangeslider/rangeslider-value.type.js +0 -4
- package/dist/es2015/shared/input-separator.component.js +0 -58
- package/dist/es2015/shared.module.js +0 -27
- package/dist/es2015/slider/localization/custom-messages.component.js +0 -35
- package/dist/es2015/slider/localization/localized-slider-messages.directive.js +0 -31
- package/dist/es2015/slider/localization/messages.js +0 -24
- package/dist/es2015/slider.module.js +0 -63
- package/dist/es2015/sliders-common/slider-ticks.component.js +0 -123
- package/dist/es2015/sliders-common/sliders-common.module.js +0 -32
- package/dist/es2015/switch/localization/custom-messages.component.js +0 -35
- package/dist/es2015/switch/localization/localized-switch-messages.directive.js +0 -31
- package/dist/es2015/switch/localization/messages.js +0 -20
- package/dist/es2015/textarea/models/flow.js +0 -4
- package/dist/es2015/textarea/models/resize.js +0 -4
- package/dist/es2015/textarea/textarea-suffix.component.js +0 -55
- package/dist/es2015/textarea.module.js +0 -60
- package/dist/es2015/textbox/localization/custom-messages.component.js +0 -35
- package/dist/es2015/textbox/localization/localized-textbox-messages.directive.js +0 -31
- package/dist/es2015/textbox/localization/messages.js +0 -16
- package/dist/es2015/textbox/models/icon-show-options.js +0 -4
- package/dist/es2015/textbox/textbox-prefix.directive.js +0 -36
- package/dist/es2015/textbox/textbox-suffix.directive.js +0 -35
- package/dist/es2015/textbox.module.d.ts +0 -37
- package/dist/es2015/textbox.module.js +0 -72
- package/dist/fesm5/index.js +0 -12461
- package/dist/npm/checkbox/checkbox.directive.js +0 -109
- package/dist/npm/checkbox.module.js +0 -54
- package/dist/npm/colorpicker/color-contrast-svg.component.js +0 -97
- package/dist/npm/colorpicker/color-gradient.component.js +0 -699
- package/dist/npm/colorpicker/color-input.component.js +0 -195
- package/dist/npm/colorpicker/color-palette.component.js +0 -525
- package/dist/npm/colorpicker/colorpicker.component.js +0 -960
- package/dist/npm/colorpicker/constants.js +0 -38
- package/dist/npm/colorpicker/contrast-validation.component.js +0 -61
- package/dist/npm/colorpicker/contrast.component.js +0 -72
- package/dist/npm/colorpicker/events/active-color-click-event.js +0 -62
- package/dist/npm/colorpicker/events/cancel-event.js +0 -21
- package/dist/npm/colorpicker/events/close-event.js +0 -19
- package/dist/npm/colorpicker/events/kendo-drag-event.js +0 -6
- package/dist/npm/colorpicker/events/open-event.js +0 -19
- package/dist/npm/colorpicker/events.js +0 -11
- package/dist/npm/colorpicker/flatcolorpicker-actions.component.js +0 -52
- package/dist/npm/colorpicker/flatcolorpicker-header.component.js +0 -96
- package/dist/npm/colorpicker/flatcolorpicker.component.js +0 -551
- package/dist/npm/colorpicker/focus-on-dom-ready.directive.js +0 -33
- package/dist/npm/colorpicker/localization/colorgradient-localization.service.js +0 -36
- package/dist/npm/colorpicker/localization/colorpalette-localization.service.js +0 -36
- package/dist/npm/colorpicker/localization/colorpicker-localization.service.js +0 -26
- package/dist/npm/colorpicker/localization/custom-messages.component.js +0 -45
- package/dist/npm/colorpicker/localization/flatcolorpicker-localization.service.js +0 -36
- package/dist/npm/colorpicker/localization/localized-colorpicker-messages.directive.js +0 -37
- package/dist/npm/colorpicker/localization/messages.js +0 -112
- package/dist/npm/colorpicker/models/actions-layout.js +0 -6
- package/dist/npm/colorpicker/models/colorpicker-view.js +0 -6
- package/dist/npm/colorpicker/models/gradient-settings.js +0 -6
- package/dist/npm/colorpicker/models/hsva.js +0 -6
- package/dist/npm/colorpicker/models/output-format.js +0 -6
- package/dist/npm/colorpicker/models/palette-presets.js +0 -64
- package/dist/npm/colorpicker/models/palette-settings.js +0 -6
- package/dist/npm/colorpicker/models/popup-settings.js +0 -6
- package/dist/npm/colorpicker/models/rgb.js +0 -6
- package/dist/npm/colorpicker/models/rgba.js +0 -6
- package/dist/npm/colorpicker/models/table-cell.js +0 -6
- package/dist/npm/colorpicker/models/tile-size.js +0 -6
- package/dist/npm/colorpicker/models.js +0 -8
- package/dist/npm/colorpicker/services/color-palette.service.js +0 -69
- package/dist/npm/colorpicker/services/flatcolorpicker.service.js +0 -43
- package/dist/npm/colorpicker/utils/color-parser.js +0 -173
- package/dist/npm/colorpicker/utils/contrast-curve.js +0 -93
- package/dist/npm/colorpicker/utils.js +0 -9
- package/dist/npm/colorpicker.module.js +0 -69
- package/dist/npm/common/dom-utils.js +0 -50
- package/dist/npm/common/math.js +0 -69
- package/dist/npm/common/models/fillmode.js +0 -6
- package/dist/npm/common/models/rounded.js +0 -6
- package/dist/npm/common/models/size.js +0 -6
- package/dist/npm/common/models/styling-classes.js +0 -6
- package/dist/npm/common/models.js +0 -6
- package/dist/npm/common/utils.js +0 -75
- package/dist/npm/formfield/error.component.js +0 -87
- package/dist/npm/formfield/formfield.component.js +0 -298
- package/dist/npm/formfield/hint.component.js +0 -81
- package/dist/npm/formfield/models/message-align.js +0 -6
- package/dist/npm/formfield/models/orientation.js +0 -6
- package/dist/npm/formfield/models/show-options.js +0 -6
- package/dist/npm/formfield.module.js +0 -56
- package/dist/npm/index.js +0 -69
- package/dist/npm/inputs.module.js +0 -76
- package/dist/npm/main.js +0 -100
- package/dist/npm/maskedtextbox/maskedtextbox.component.js +0 -731
- package/dist/npm/maskedtextbox/masking.service.js +0 -217
- package/dist/npm/maskedtextbox/parsing/combinators.js +0 -34
- package/dist/npm/maskedtextbox/parsing/parsers.js +0 -162
- package/dist/npm/maskedtextbox/parsing/result.js +0 -45
- package/dist/npm/maskedtextbox/parsing/stream.js +0 -47
- package/dist/npm/maskedtextbox.module.js +0 -55
- package/dist/npm/numerictextbox/arrow-direction.js +0 -15
- package/dist/npm/numerictextbox/constants.js +0 -30
- package/dist/npm/numerictextbox/localization/custom-messages.component.js +0 -45
- package/dist/npm/numerictextbox/localization/localized-numerictextbox-messages.directive.js +0 -37
- package/dist/npm/numerictextbox/localization/messages.js +0 -28
- package/dist/npm/numerictextbox/numerictextbox.component.js +0 -1051
- package/dist/npm/numerictextbox/utils.js +0 -94
- package/dist/npm/numerictextbox.module.js +0 -64
- package/dist/npm/package-metadata.js +0 -17
- package/dist/npm/radiobutton/radiobutton.directive.js +0 -85
- package/dist/npm/radiobutton.module.js +0 -54
- package/dist/npm/rangeslider/localization/custom-messages.component.js +0 -45
- package/dist/npm/rangeslider/localization/localized-rangeslider-messages.directive.js +0 -37
- package/dist/npm/rangeslider/localization/messages.js +0 -28
- package/dist/npm/rangeslider/rangeslider-model.js +0 -61
- package/dist/npm/rangeslider/rangeslider-value.type.js +0 -6
- package/dist/npm/rangeslider/rangeslider.component.js +0 -473
- package/dist/npm/rangeslider.module.js +0 -68
- package/dist/npm/shared/input-separator.component.js +0 -43
- package/dist/npm/shared/textarea.directive.js +0 -271
- package/dist/npm/shared/utils.js +0 -26
- package/dist/npm/shared.module.js +0 -32
- package/dist/npm/slider/localization/custom-messages.component.js +0 -45
- package/dist/npm/slider/localization/localized-slider-messages.directive.js +0 -37
- package/dist/npm/slider/localization/messages.js +0 -32
- package/dist/npm/slider/slider-model.js +0 -43
- package/dist/npm/slider/slider.component.js +0 -484
- package/dist/npm/slider.module.js +0 -68
- package/dist/npm/sliders-common/label-template.directive.js +0 -46
- package/dist/npm/sliders-common/slider-base.js +0 -328
- package/dist/npm/sliders-common/slider-model.base.js +0 -98
- package/dist/npm/sliders-common/slider-ticks.component.js +0 -106
- package/dist/npm/sliders-common/sliders-common.module.js +0 -37
- package/dist/npm/sliders-common/sliders-util.js +0 -236
- package/dist/npm/switch/localization/custom-messages.component.js +0 -45
- package/dist/npm/switch/localization/localized-switch-messages.directive.js +0 -37
- package/dist/npm/switch/localization/messages.js +0 -28
- package/dist/npm/switch/switch.component.js +0 -572
- package/dist/npm/switch.module.js +0 -66
- package/dist/npm/text-fields-common/text-fields-base.js +0 -146
- package/dist/npm/textarea/models/flow.js +0 -6
- package/dist/npm/textarea/models/resize.js +0 -6
- package/dist/npm/textarea/textarea-suffix.component.js +0 -42
- package/dist/npm/textarea/textarea.component.js +0 -602
- package/dist/npm/textarea.module.js +0 -65
- package/dist/npm/textbox/localization/custom-messages.component.js +0 -45
- package/dist/npm/textbox/localization/localized-textbox-messages.directive.js +0 -37
- package/dist/npm/textbox/localization/messages.js +0 -24
- package/dist/npm/textbox/models/icon-show-options.js +0 -6
- package/dist/npm/textbox/textbox-prefix.directive.js +0 -39
- package/dist/npm/textbox/textbox-suffix.directive.js +0 -38
- package/dist/npm/textbox/textbox.component.js +0 -765
- package/dist/npm/textbox/textbox.directive.js +0 -129
- package/dist/npm/textbox.module.js +0 -77
- package/dist/npm/validators/max.validator.js +0 -23
- package/dist/npm/validators/min.validator.js +0 -23
- package/dist/systemjs/kendo-angular-inputs.js +0 -5
|
@@ -1,1051 +0,0 @@
|
|
|
1
|
-
/**-----------------------------------------------------------------------------------------
|
|
2
|
-
* Copyright © 2021 Progress Software Corporation. All rights reserved.
|
|
3
|
-
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
|
-
*-------------------------------------------------------------------------------------------*/
|
|
5
|
-
"use strict";
|
|
6
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
-
var tslib_1 = require("tslib");
|
|
8
|
-
var core_1 = require("@angular/core");
|
|
9
|
-
var kendo_angular_common_1 = require("@progress/kendo-angular-common");
|
|
10
|
-
var utils_1 = require("../common/utils");
|
|
11
|
-
var dom_utils_1 = require("../common/dom-utils");
|
|
12
|
-
var math_1 = require("../common/math");
|
|
13
|
-
var max_validator_1 = require("../validators/max.validator");
|
|
14
|
-
var min_validator_1 = require("../validators/min.validator");
|
|
15
|
-
var forms_1 = require("@angular/forms");
|
|
16
|
-
var kendo_angular_intl_1 = require("@progress/kendo-angular-intl");
|
|
17
|
-
var kendo_angular_l10n_1 = require("@progress/kendo-angular-l10n");
|
|
18
|
-
var kendo_licensing_1 = require("@progress/kendo-licensing");
|
|
19
|
-
var package_metadata_1 = require("../package-metadata");
|
|
20
|
-
var constants_1 = require("./constants");
|
|
21
|
-
var utils_2 = require("./utils");
|
|
22
|
-
var arrow_direction_1 = require("./arrow-direction");
|
|
23
|
-
var kendo_common_1 = require("@progress/kendo-common");
|
|
24
|
-
var PARSABLE_OPTIONS = ['min', 'max', 'step', 'decimals'];
|
|
25
|
-
var PARSABLE_DEFAULTS = {
|
|
26
|
-
decimals: null,
|
|
27
|
-
max: null,
|
|
28
|
-
min: null,
|
|
29
|
-
step: 1
|
|
30
|
-
};
|
|
31
|
-
var FOCUSED = 'k-focus';
|
|
32
|
-
/**
|
|
33
|
-
* Represents the [Kendo UI NumericTextBox component for Angular]({% slug overview_numerictextbox %}).
|
|
34
|
-
*/
|
|
35
|
-
var NumericTextBoxComponent = /** @class */ (function () {
|
|
36
|
-
function NumericTextBoxComponent(intl, renderer, localizationService, injector, ngZone, changeDetector, hostElement) {
|
|
37
|
-
var _this = this;
|
|
38
|
-
this.intl = intl;
|
|
39
|
-
this.renderer = renderer;
|
|
40
|
-
this.localizationService = localizationService;
|
|
41
|
-
this.injector = injector;
|
|
42
|
-
this.ngZone = ngZone;
|
|
43
|
-
this.changeDetector = changeDetector;
|
|
44
|
-
this.hostElement = hostElement;
|
|
45
|
-
/**
|
|
46
|
-
* @hidden
|
|
47
|
-
*/
|
|
48
|
-
this.focusableId = "k-" + kendo_angular_common_1.guid();
|
|
49
|
-
/**
|
|
50
|
-
* Determines whether the NumericTextBox is disabled ([see example]({% slug disabled_numerictextbox %})).
|
|
51
|
-
*/
|
|
52
|
-
this.disabled = false;
|
|
53
|
-
/**
|
|
54
|
-
* Determines whether the NumericTextBox is in its read-only state ([see example]({% slug readonly_numerictextbox %})).
|
|
55
|
-
*/
|
|
56
|
-
this.readonly = false;
|
|
57
|
-
/**
|
|
58
|
-
* Sets the title of the `input` element of the NumericTextBox.
|
|
59
|
-
*/
|
|
60
|
-
this.title = '';
|
|
61
|
-
/**
|
|
62
|
-
* Specifies whether the value will be auto-corrected based on the minimum and maximum values
|
|
63
|
-
* ([see example]({% slug precision_numerictextbox %})).
|
|
64
|
-
*/
|
|
65
|
-
this.autoCorrect = false;
|
|
66
|
-
/**
|
|
67
|
-
* Specifies the number of decimals that the user can enter when the input is focused
|
|
68
|
-
* ([see example]({% slug precision_numerictextbox %})).
|
|
69
|
-
*/
|
|
70
|
-
this.decimals = null;
|
|
71
|
-
/**
|
|
72
|
-
* Specifies the value that is used to increment or decrement the component value
|
|
73
|
-
* ([see example]({% slug predefinedsteps_numerictextbox %})).
|
|
74
|
-
*/
|
|
75
|
-
this.step = 1;
|
|
76
|
-
/**
|
|
77
|
-
* Specifies whether the **Up** and **Down** spin buttons will be rendered
|
|
78
|
-
* ([see example]({% slug spinbuttons_numerictextbox %})).
|
|
79
|
-
*/
|
|
80
|
-
this.spinners = true;
|
|
81
|
-
/**
|
|
82
|
-
* Determines whether the built-in minimum or maximum validators are enforced when a form is validated.
|
|
83
|
-
*
|
|
84
|
-
* > The 4.2.0 Angular version introduces the `min` and `max` validation directives. As a result, even if you set `rangeValidation`
|
|
85
|
-
* to `false`, the built-in Angular validators will be executed.
|
|
86
|
-
*/
|
|
87
|
-
this.rangeValidation = true;
|
|
88
|
-
/**
|
|
89
|
-
* Specifies the [tabindex](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/tabindex) of the component.
|
|
90
|
-
*/
|
|
91
|
-
this.tabindex = 0;
|
|
92
|
-
/**
|
|
93
|
-
* Determines whether the value of the NumericTextBox will be changed via scrolling. Defaults to `true`.
|
|
94
|
-
*
|
|
95
|
-
* @default true
|
|
96
|
-
*/
|
|
97
|
-
this.changeValueOnScroll = true;
|
|
98
|
-
/**
|
|
99
|
-
* Determines whether the whole value will be selected when the NumericTextBox is clicked. Defaults to `true`.
|
|
100
|
-
*/
|
|
101
|
-
this.selectOnFocus = true;
|
|
102
|
-
/**
|
|
103
|
-
* Specifies the value of the NumericTextBox
|
|
104
|
-
* ([see example]({% slug formats_numerictextbox %})).
|
|
105
|
-
*/
|
|
106
|
-
this.value = null;
|
|
107
|
-
/**
|
|
108
|
-
* Fires each time the user selects a new value ([see example]({% slug overview_numerictextbox %}#toc-events)).
|
|
109
|
-
*/
|
|
110
|
-
this.valueChange = new core_1.EventEmitter();
|
|
111
|
-
/**
|
|
112
|
-
* Fires each time the user focuses the `input` element ([see example]({% slug overview_numerictextbox %}#toc-events)).
|
|
113
|
-
*/
|
|
114
|
-
this.onFocus = new core_1.EventEmitter();
|
|
115
|
-
/**
|
|
116
|
-
* Fires each time the `input` element gets blurred ([see example]({% slug overview_numerictextbox %}#toc-events)).
|
|
117
|
-
*/
|
|
118
|
-
this.onBlur = new core_1.EventEmitter();
|
|
119
|
-
/**
|
|
120
|
-
* @hidden
|
|
121
|
-
*/
|
|
122
|
-
this.ArrowDirection = arrow_direction_1.ArrowDirection;
|
|
123
|
-
/**
|
|
124
|
-
* @hidden
|
|
125
|
-
*/
|
|
126
|
-
this.arrowDirection = arrow_direction_1.ArrowDirection.None;
|
|
127
|
-
this.hostClasses = true;
|
|
128
|
-
this.inputValue = '';
|
|
129
|
-
this.minValidateFn = utils_2.noop;
|
|
130
|
-
this.maxValidateFn = utils_2.noop;
|
|
131
|
-
this._format = "n2";
|
|
132
|
-
this.isPasted = false;
|
|
133
|
-
this.mouseDown = false;
|
|
134
|
-
this._size = 'medium';
|
|
135
|
-
this._rounded = 'medium';
|
|
136
|
-
this._fillMode = 'solid';
|
|
137
|
-
this.ngChange = utils_2.noop;
|
|
138
|
-
this.ngTouched = utils_2.noop;
|
|
139
|
-
this.ngValidatorChange = utils_2.noop;
|
|
140
|
-
this.domEvents = [];
|
|
141
|
-
/**
|
|
142
|
-
* @hidden
|
|
143
|
-
*/
|
|
144
|
-
this.increasePress = function (e) {
|
|
145
|
-
_this.arrowPress(arrow_direction_1.ArrowDirection.Up, e);
|
|
146
|
-
};
|
|
147
|
-
/**
|
|
148
|
-
* @hidden
|
|
149
|
-
*/
|
|
150
|
-
this.decreasePress = function (e) {
|
|
151
|
-
_this.arrowPress(arrow_direction_1.ArrowDirection.Down, e);
|
|
152
|
-
};
|
|
153
|
-
/**
|
|
154
|
-
* @hidden
|
|
155
|
-
*/
|
|
156
|
-
this.releaseArrow = function () {
|
|
157
|
-
clearTimeout(_this.spinTimeout);
|
|
158
|
-
if (_this.arrowDirection !== arrow_direction_1.ArrowDirection.None) {
|
|
159
|
-
_this.arrowDirection = arrow_direction_1.ArrowDirection.None;
|
|
160
|
-
_this.changeDetector.detectChanges();
|
|
161
|
-
}
|
|
162
|
-
};
|
|
163
|
-
/**
|
|
164
|
-
* @hidden
|
|
165
|
-
*/
|
|
166
|
-
this.handlePaste = function () {
|
|
167
|
-
_this.isPasted = true;
|
|
168
|
-
};
|
|
169
|
-
/**
|
|
170
|
-
* @hidden
|
|
171
|
-
*/
|
|
172
|
-
this.handleInput = function () {
|
|
173
|
-
var input = _this.numericInput.nativeElement;
|
|
174
|
-
var selectionStart = input.selectionStart, selectionEnd = input.selectionEnd, inputValue = input.value;
|
|
175
|
-
if (_this.pressedKey === kendo_angular_common_1.Keys.NumpadDecimal) {
|
|
176
|
-
inputValue = _this.replaceNumpadDotValue();
|
|
177
|
-
}
|
|
178
|
-
if (_this.isPasted) {
|
|
179
|
-
inputValue = _this.formatInputValue(_this.intl.parseNumber(inputValue));
|
|
180
|
-
}
|
|
181
|
-
if (!_this.isValid(inputValue)) {
|
|
182
|
-
input.value = _this.inputValue;
|
|
183
|
-
_this.setSelection(selectionStart - 1, selectionEnd - 1);
|
|
184
|
-
return;
|
|
185
|
-
}
|
|
186
|
-
var parsedValue = _this.intl.parseNumber(inputValue);
|
|
187
|
-
var value = _this.restrictDecimals(parsedValue);
|
|
188
|
-
if (_this.autoCorrect) {
|
|
189
|
-
var limited = _this.limitInputValue(value);
|
|
190
|
-
value = limited.value;
|
|
191
|
-
selectionStart = limited.selectionStart;
|
|
192
|
-
selectionEnd = limited.selectionEnd;
|
|
193
|
-
}
|
|
194
|
-
if (parsedValue !== value || _this.hasTrailingZeros(inputValue) || !_this.focused) {
|
|
195
|
-
_this.setInputValue(value);
|
|
196
|
-
_this.setSelection(selectionStart, selectionEnd);
|
|
197
|
-
}
|
|
198
|
-
else {
|
|
199
|
-
_this.inputValue = inputValue;
|
|
200
|
-
}
|
|
201
|
-
if (_this.isPasted) {
|
|
202
|
-
input.value = _this.inputValue;
|
|
203
|
-
}
|
|
204
|
-
_this.updateValue(value);
|
|
205
|
-
_this.previousSelection = null;
|
|
206
|
-
_this.isPasted = false;
|
|
207
|
-
};
|
|
208
|
-
/**
|
|
209
|
-
* @hidden
|
|
210
|
-
*/
|
|
211
|
-
this.handleDragEnter = function () {
|
|
212
|
-
if (!_this.focused && !_this.isDisabled) {
|
|
213
|
-
_this.setInputValue(_this.value, true);
|
|
214
|
-
}
|
|
215
|
-
};
|
|
216
|
-
/**
|
|
217
|
-
* @hidden
|
|
218
|
-
*/
|
|
219
|
-
this.handleMouseDown = function () {
|
|
220
|
-
_this.mouseDown = true;
|
|
221
|
-
};
|
|
222
|
-
/**
|
|
223
|
-
* @hidden
|
|
224
|
-
*/
|
|
225
|
-
this.handleFocus = function () {
|
|
226
|
-
if (!_this.focused) {
|
|
227
|
-
_this.focused = true;
|
|
228
|
-
if (!_this.isDisabled) {
|
|
229
|
-
var shouldSelectAll_1 = _this.selectOnFocus || !_this.mouseDown;
|
|
230
|
-
_this.ngZone.runOutsideAngular(function () {
|
|
231
|
-
setTimeout(function () {
|
|
232
|
-
if (shouldSelectAll_1) {
|
|
233
|
-
_this.selectAll();
|
|
234
|
-
}
|
|
235
|
-
else {
|
|
236
|
-
_this.selectCaret();
|
|
237
|
-
}
|
|
238
|
-
}, 0);
|
|
239
|
-
});
|
|
240
|
-
}
|
|
241
|
-
}
|
|
242
|
-
_this.mouseDown = false;
|
|
243
|
-
if (kendo_angular_common_1.hasObservers(_this.onFocus)) {
|
|
244
|
-
_this.ngZone.run(function () {
|
|
245
|
-
_this.onFocus.emit();
|
|
246
|
-
});
|
|
247
|
-
}
|
|
248
|
-
};
|
|
249
|
-
/**
|
|
250
|
-
* @hidden
|
|
251
|
-
*/
|
|
252
|
-
this.handleBlur = function () {
|
|
253
|
-
_this.changeDetector.markForCheck();
|
|
254
|
-
_this.focused = false;
|
|
255
|
-
//blur is thrown before input when dragging the input text in IE
|
|
256
|
-
if (_this.inputValue !== _this.elementValue) {
|
|
257
|
-
_this.handleInput();
|
|
258
|
-
}
|
|
259
|
-
_this.setInputValue();
|
|
260
|
-
if (kendo_angular_common_1.hasObservers(_this.onBlur) || utils_1.requiresZoneOnBlur(_this.control)) {
|
|
261
|
-
_this.ngZone.run(function () {
|
|
262
|
-
_this.ngTouched();
|
|
263
|
-
_this.onBlur.emit();
|
|
264
|
-
});
|
|
265
|
-
}
|
|
266
|
-
};
|
|
267
|
-
/**
|
|
268
|
-
* @hidden
|
|
269
|
-
*/
|
|
270
|
-
this.handleKeyDown = function (e) {
|
|
271
|
-
if (_this.isDisabled) {
|
|
272
|
-
return;
|
|
273
|
-
}
|
|
274
|
-
var step;
|
|
275
|
-
if (e.keyCode === kendo_angular_common_1.Keys.ArrowDown) {
|
|
276
|
-
step = -1;
|
|
277
|
-
}
|
|
278
|
-
else if (e.keyCode === kendo_angular_common_1.Keys.ArrowUp) {
|
|
279
|
-
step = 1;
|
|
280
|
-
}
|
|
281
|
-
if (step && _this.step) {
|
|
282
|
-
e.preventDefault();
|
|
283
|
-
_this.addStep(step);
|
|
284
|
-
}
|
|
285
|
-
var input = _this.numericInput.nativeElement;
|
|
286
|
-
_this.previousSelection = {
|
|
287
|
-
end: input.selectionEnd,
|
|
288
|
-
start: input.selectionStart
|
|
289
|
-
};
|
|
290
|
-
_this.pressedKey = e.keyCode;
|
|
291
|
-
};
|
|
292
|
-
/**
|
|
293
|
-
* @hidden
|
|
294
|
-
*/
|
|
295
|
-
this.handleWheel = function (e) {
|
|
296
|
-
if (_this.focused && !_this.isDisabled && _this.changeValueOnScroll) {
|
|
297
|
-
e.preventDefault();
|
|
298
|
-
var delta = utils_2.getDeltaFromMouseWheel(e);
|
|
299
|
-
_this.addStep(delta);
|
|
300
|
-
}
|
|
301
|
-
};
|
|
302
|
-
kendo_licensing_1.validatePackage(package_metadata_1.packageMetadata);
|
|
303
|
-
this.direction = localizationService.rtl ? 'rtl' : 'ltr';
|
|
304
|
-
}
|
|
305
|
-
NumericTextBoxComponent_1 = NumericTextBoxComponent;
|
|
306
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "format", {
|
|
307
|
-
/**
|
|
308
|
-
* Specifies the number format which is used when the NumericTextBox is not focused
|
|
309
|
-
* ([see example]({% slug formats_numerictextbox %})).
|
|
310
|
-
* If `format` is set to `null` or `undefined`, the default format will be used.
|
|
311
|
-
*/
|
|
312
|
-
get: function () {
|
|
313
|
-
var format = this._format;
|
|
314
|
-
return format !== null && format !== undefined ? format : 'n2';
|
|
315
|
-
},
|
|
316
|
-
set: function (value) {
|
|
317
|
-
this._format = value;
|
|
318
|
-
},
|
|
319
|
-
enumerable: true,
|
|
320
|
-
configurable: true
|
|
321
|
-
});
|
|
322
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "tabIndex", {
|
|
323
|
-
get: function () {
|
|
324
|
-
return this.tabindex;
|
|
325
|
-
},
|
|
326
|
-
/**
|
|
327
|
-
* @hidden
|
|
328
|
-
*/
|
|
329
|
-
set: function (tabIndex) {
|
|
330
|
-
this.tabindex = tabIndex;
|
|
331
|
-
},
|
|
332
|
-
enumerable: true,
|
|
333
|
-
configurable: true
|
|
334
|
-
});
|
|
335
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "size", {
|
|
336
|
-
get: function () {
|
|
337
|
-
return this._size;
|
|
338
|
-
},
|
|
339
|
-
/**
|
|
340
|
-
* The size property specifies padding of the NumericTextBox internal input element
|
|
341
|
-
* ([see example]({% slug appearance_numerictextbox %}#toc-size)).
|
|
342
|
-
* The possible values are:
|
|
343
|
-
* * `'small'`
|
|
344
|
-
* * `'medium'` (default)
|
|
345
|
-
* * `'large'`
|
|
346
|
-
* * `null`
|
|
347
|
-
*/
|
|
348
|
-
set: function (size) {
|
|
349
|
-
this.handleClasses(size, 'size');
|
|
350
|
-
this._size = size;
|
|
351
|
-
},
|
|
352
|
-
enumerable: true,
|
|
353
|
-
configurable: true
|
|
354
|
-
});
|
|
355
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "rounded", {
|
|
356
|
-
get: function () {
|
|
357
|
-
return this._rounded;
|
|
358
|
-
},
|
|
359
|
-
/**
|
|
360
|
-
* The rounded property specifies the border radius of the NumericTextBox
|
|
361
|
-
* ([see example]({% slug appearance_numerictextbox %}#toc-rounded)).
|
|
362
|
-
* The possible values are:
|
|
363
|
-
* * `'small'`
|
|
364
|
-
* * `'medium'` (default)
|
|
365
|
-
* * `'large'`
|
|
366
|
-
* * `null`
|
|
367
|
-
*/
|
|
368
|
-
set: function (rounded) {
|
|
369
|
-
this.handleClasses(rounded, 'rounded');
|
|
370
|
-
this._rounded = rounded;
|
|
371
|
-
},
|
|
372
|
-
enumerable: true,
|
|
373
|
-
configurable: true
|
|
374
|
-
});
|
|
375
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "fillMode", {
|
|
376
|
-
get: function () {
|
|
377
|
-
return this._fillMode;
|
|
378
|
-
},
|
|
379
|
-
/**
|
|
380
|
-
* The fillMode property specifies the background and border styles of the NumericTextBox
|
|
381
|
-
* ([see example]({% slug appearance_numerictextbox %}#toc-fillMode)).
|
|
382
|
-
* The possible values are:
|
|
383
|
-
* * `'flat'`
|
|
384
|
-
* * `'solid'` (default)
|
|
385
|
-
* * `'outline'`
|
|
386
|
-
* * `null`
|
|
387
|
-
*/
|
|
388
|
-
set: function (fillMode) {
|
|
389
|
-
this.handleClasses(fillMode, 'fillMode');
|
|
390
|
-
this._fillMode = fillMode;
|
|
391
|
-
},
|
|
392
|
-
enumerable: true,
|
|
393
|
-
configurable: true
|
|
394
|
-
});
|
|
395
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "disableClass", {
|
|
396
|
-
get: function () {
|
|
397
|
-
return this.disabled;
|
|
398
|
-
},
|
|
399
|
-
enumerable: true,
|
|
400
|
-
configurable: true
|
|
401
|
-
});
|
|
402
|
-
NumericTextBoxComponent.prototype.ngOnInit = function () {
|
|
403
|
-
var _this = this;
|
|
404
|
-
this.subscriptions = this.localizationService
|
|
405
|
-
.changes
|
|
406
|
-
.subscribe(function (_a) {
|
|
407
|
-
var rtl = _a.rtl;
|
|
408
|
-
_this.direction = rtl ? 'rtl' : 'ltr';
|
|
409
|
-
});
|
|
410
|
-
this.subscriptions.add(this.intl.changes.subscribe(this.intlChange.bind(this)));
|
|
411
|
-
if (this.hostElement) {
|
|
412
|
-
this.renderer.removeAttribute(this.hostElement.nativeElement, "tabindex");
|
|
413
|
-
}
|
|
414
|
-
this.control = this.injector.get(forms_1.NgControl, null);
|
|
415
|
-
this.ngZone.runOutsideAngular(function () {
|
|
416
|
-
_this.domEvents.push(_this.renderer.listen(_this.hostElement.nativeElement, 'mousewheel', _this.handleWheel.bind(_this)));
|
|
417
|
-
_this.domEvents.push(_this.renderer.listen(_this.hostElement.nativeElement, 'DOMMouseScroll', _this.handleWheel.bind(_this)));
|
|
418
|
-
});
|
|
419
|
-
};
|
|
420
|
-
NumericTextBoxComponent.prototype.ngAfterViewInit = function () {
|
|
421
|
-
var _this = this;
|
|
422
|
-
var stylingInputs = ['size', 'rounded', 'fillMode'];
|
|
423
|
-
stylingInputs.forEach(function (input) {
|
|
424
|
-
_this.handleClasses(_this[input], input);
|
|
425
|
-
});
|
|
426
|
-
};
|
|
427
|
-
/**
|
|
428
|
-
* @hidden
|
|
429
|
-
*/
|
|
430
|
-
NumericTextBoxComponent.prototype.ngOnChanges = function (changes) {
|
|
431
|
-
if (kendo_angular_common_1.anyChanged(PARSABLE_OPTIONS, changes, false)) {
|
|
432
|
-
this.parseOptions(PARSABLE_OPTIONS.filter(function (option) { return changes[option]; }));
|
|
433
|
-
}
|
|
434
|
-
this.verifySettings();
|
|
435
|
-
if (kendo_angular_common_1.anyChanged(['min', 'max', 'rangeValidation'], changes, false)) {
|
|
436
|
-
this.minValidateFn = this.rangeValidation ? min_validator_1.createMinValidator(this.min) : utils_2.noop;
|
|
437
|
-
this.maxValidateFn = this.rangeValidation ? max_validator_1.createMaxValidator(this.max) : utils_2.noop;
|
|
438
|
-
this.ngValidatorChange();
|
|
439
|
-
}
|
|
440
|
-
if (kendo_angular_common_1.anyChanged(['autoCorrect', 'decimals', 'min'], changes)) {
|
|
441
|
-
delete this.numericRegex;
|
|
442
|
-
}
|
|
443
|
-
if (kendo_angular_common_1.anyChanged(['value', 'format'], changes, false)) {
|
|
444
|
-
this.verifyValue(this.value);
|
|
445
|
-
this.value = this.restrictModelValue(this.value);
|
|
446
|
-
if (!this.focused || (this.intl.parseNumber(this.elementValue) !== this.value)) {
|
|
447
|
-
this.setInputValue();
|
|
448
|
-
}
|
|
449
|
-
}
|
|
450
|
-
};
|
|
451
|
-
/**
|
|
452
|
-
* @hidden
|
|
453
|
-
*/
|
|
454
|
-
NumericTextBoxComponent.prototype.ngOnDestroy = function () {
|
|
455
|
-
if (this.subscriptions) {
|
|
456
|
-
this.subscriptions.unsubscribe();
|
|
457
|
-
}
|
|
458
|
-
clearTimeout(this.spinTimeout);
|
|
459
|
-
this.domEvents.forEach(function (unbindHandler) { return unbindHandler(); });
|
|
460
|
-
};
|
|
461
|
-
/**
|
|
462
|
-
* @hidden
|
|
463
|
-
*/
|
|
464
|
-
NumericTextBoxComponent.prototype.validate = function (control) {
|
|
465
|
-
return this.minValidateFn(control) || this.maxValidateFn(control);
|
|
466
|
-
};
|
|
467
|
-
/**
|
|
468
|
-
* @hidden
|
|
469
|
-
*/
|
|
470
|
-
NumericTextBoxComponent.prototype.registerOnValidatorChange = function (fn) {
|
|
471
|
-
this.ngValidatorChange = fn;
|
|
472
|
-
};
|
|
473
|
-
/**
|
|
474
|
-
* @hidden
|
|
475
|
-
*/
|
|
476
|
-
NumericTextBoxComponent.prototype.writeValue = function (value) {
|
|
477
|
-
this.verifyValue(value);
|
|
478
|
-
var restrictedValue = this.restrictModelValue(value);
|
|
479
|
-
this.value = restrictedValue;
|
|
480
|
-
this.setInputValue();
|
|
481
|
-
};
|
|
482
|
-
/**
|
|
483
|
-
* @hidden
|
|
484
|
-
*/
|
|
485
|
-
NumericTextBoxComponent.prototype.registerOnChange = function (fn) {
|
|
486
|
-
this.ngChange = fn;
|
|
487
|
-
};
|
|
488
|
-
/**
|
|
489
|
-
* @hidden
|
|
490
|
-
*/
|
|
491
|
-
NumericTextBoxComponent.prototype.registerOnTouched = function (fn) {
|
|
492
|
-
this.ngTouched = fn;
|
|
493
|
-
};
|
|
494
|
-
/**
|
|
495
|
-
* @hidden
|
|
496
|
-
* Called when the status of the component changes to or from `disabled`.
|
|
497
|
-
* Depending on the value, it enables or disables the appropriate DOM element.
|
|
498
|
-
*
|
|
499
|
-
* @param isDisabled
|
|
500
|
-
*/
|
|
501
|
-
NumericTextBoxComponent.prototype.setDisabledState = function (isDisabled) {
|
|
502
|
-
this.changeDetector.markForCheck();
|
|
503
|
-
this.disabled = isDisabled;
|
|
504
|
-
};
|
|
505
|
-
/**
|
|
506
|
-
* Focuses the NumericTextBox.
|
|
507
|
-
*
|
|
508
|
-
* @example
|
|
509
|
-
* ```ts-no-run
|
|
510
|
-
* _@Component({
|
|
511
|
-
* selector: 'my-app',
|
|
512
|
-
* template: `
|
|
513
|
-
* <button (click)="numerictextbox.focus()">Focus NumericTextBox</button>
|
|
514
|
-
* <kendo-numerictextbox #numerictextbox></kendo-numerictextbox>
|
|
515
|
-
* `
|
|
516
|
-
* })
|
|
517
|
-
* class AppComponent { }
|
|
518
|
-
* ```
|
|
519
|
-
*/
|
|
520
|
-
NumericTextBoxComponent.prototype.focus = function () {
|
|
521
|
-
dom_utils_1.invokeElementMethod(this.numericInput, 'focus');
|
|
522
|
-
};
|
|
523
|
-
/**
|
|
524
|
-
* Blurs the NumericTextBox.
|
|
525
|
-
*/
|
|
526
|
-
NumericTextBoxComponent.prototype.blur = function () {
|
|
527
|
-
dom_utils_1.invokeElementMethod(this.numericInput, 'blur');
|
|
528
|
-
};
|
|
529
|
-
/**
|
|
530
|
-
* Notifies the `NumericTextBoxComponent` that the input value should be changed.
|
|
531
|
-
* Can be used to update the input after setting the component properties directly.
|
|
532
|
-
*/
|
|
533
|
-
NumericTextBoxComponent.prototype.notifyValueChange = function () {
|
|
534
|
-
this.setInputValue();
|
|
535
|
-
};
|
|
536
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "incrementTitle", {
|
|
537
|
-
/**
|
|
538
|
-
* @hidden
|
|
539
|
-
*/
|
|
540
|
-
get: function () {
|
|
541
|
-
return this.localizationService.get('increment');
|
|
542
|
-
},
|
|
543
|
-
enumerable: true,
|
|
544
|
-
configurable: true
|
|
545
|
-
});
|
|
546
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "decrementTitle", {
|
|
547
|
-
/**
|
|
548
|
-
* @hidden
|
|
549
|
-
*/
|
|
550
|
-
get: function () {
|
|
551
|
-
return this.localizationService.get('decrement');
|
|
552
|
-
},
|
|
553
|
-
enumerable: true,
|
|
554
|
-
configurable: true
|
|
555
|
-
});
|
|
556
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "decimalSeparator", {
|
|
557
|
-
get: function () {
|
|
558
|
-
var numberSymbols = this.intl.numberSymbols();
|
|
559
|
-
return numberSymbols.decimal;
|
|
560
|
-
},
|
|
561
|
-
enumerable: true,
|
|
562
|
-
configurable: true
|
|
563
|
-
});
|
|
564
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "elementValue", {
|
|
565
|
-
get: function () {
|
|
566
|
-
return this.numericInput.nativeElement.value;
|
|
567
|
-
},
|
|
568
|
-
set: function (value) {
|
|
569
|
-
this.renderer.setProperty(this.numericInput.nativeElement, 'value', value);
|
|
570
|
-
},
|
|
571
|
-
enumerable: true,
|
|
572
|
-
configurable: true
|
|
573
|
-
});
|
|
574
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "focused", {
|
|
575
|
-
get: function () {
|
|
576
|
-
return this.isFocused;
|
|
577
|
-
},
|
|
578
|
-
set: function (value) {
|
|
579
|
-
if (this.isFocused !== value && this.hostElement) {
|
|
580
|
-
var wrap = this.hostElement.nativeElement;
|
|
581
|
-
if (value) {
|
|
582
|
-
this.renderer.addClass(wrap, FOCUSED);
|
|
583
|
-
}
|
|
584
|
-
else {
|
|
585
|
-
this.renderer.removeClass(wrap, FOCUSED);
|
|
586
|
-
}
|
|
587
|
-
this.isFocused = value;
|
|
588
|
-
}
|
|
589
|
-
},
|
|
590
|
-
enumerable: true,
|
|
591
|
-
configurable: true
|
|
592
|
-
});
|
|
593
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "hasDecimals", {
|
|
594
|
-
get: function () {
|
|
595
|
-
return this.decimals !== null && this.decimals >= 0;
|
|
596
|
-
},
|
|
597
|
-
enumerable: true,
|
|
598
|
-
configurable: true
|
|
599
|
-
});
|
|
600
|
-
Object.defineProperty(NumericTextBoxComponent.prototype, "isDisabled", {
|
|
601
|
-
get: function () {
|
|
602
|
-
return this.disabled || this.readonly;
|
|
603
|
-
},
|
|
604
|
-
enumerable: true,
|
|
605
|
-
configurable: true
|
|
606
|
-
});
|
|
607
|
-
NumericTextBoxComponent.prototype.arrowPress = function (direction, e) {
|
|
608
|
-
e.preventDefault();
|
|
609
|
-
if (this.isDisabled || utils_2.isRightClick(e)) {
|
|
610
|
-
return;
|
|
611
|
-
}
|
|
612
|
-
if (!kendo_common_1.mobileOS) {
|
|
613
|
-
this.focused = true;
|
|
614
|
-
this.focus();
|
|
615
|
-
}
|
|
616
|
-
if (this.arrowDirection !== direction) {
|
|
617
|
-
this.arrowDirection = direction;
|
|
618
|
-
this.changeDetector.detectChanges();
|
|
619
|
-
}
|
|
620
|
-
if (this.step) {
|
|
621
|
-
this.spin(direction, constants_1.INITIAL_SPIN_DELAY);
|
|
622
|
-
}
|
|
623
|
-
else {
|
|
624
|
-
this.setInputValue();
|
|
625
|
-
}
|
|
626
|
-
};
|
|
627
|
-
NumericTextBoxComponent.prototype.updateValue = function (value) {
|
|
628
|
-
var _this = this;
|
|
629
|
-
if (!utils_1.areSame(this.value, value)) {
|
|
630
|
-
this.ngZone.run(function () {
|
|
631
|
-
_this.value = value;
|
|
632
|
-
_this.ngChange(value);
|
|
633
|
-
_this.valueChange.emit(value);
|
|
634
|
-
_this.changeDetector.markForCheck();
|
|
635
|
-
});
|
|
636
|
-
}
|
|
637
|
-
};
|
|
638
|
-
NumericTextBoxComponent.prototype.replaceNumpadDotValue = function () {
|
|
639
|
-
var value = this.inputValue || "";
|
|
640
|
-
if (this.previousSelection) {
|
|
641
|
-
var input = this.numericInput.nativeElement;
|
|
642
|
-
var selectionStart = input.selectionStart, selectionEnd = input.selectionEnd;
|
|
643
|
-
var _a = this.previousSelection, start = _a.start, end = _a.end;
|
|
644
|
-
input.value = value = value.substring(0, start) + this.decimalSeparator + value.substring(end);
|
|
645
|
-
this.setSelection(selectionStart, selectionEnd);
|
|
646
|
-
}
|
|
647
|
-
return value;
|
|
648
|
-
};
|
|
649
|
-
NumericTextBoxComponent.prototype.isValid = function (value) {
|
|
650
|
-
if (!this.numericRegex) {
|
|
651
|
-
this.numericRegex = utils_2.numericRegex({
|
|
652
|
-
autoCorrect: this.autoCorrect,
|
|
653
|
-
decimals: this.decimals,
|
|
654
|
-
min: this.min,
|
|
655
|
-
separator: this.decimalSeparator
|
|
656
|
-
});
|
|
657
|
-
}
|
|
658
|
-
return this.numericRegex.test(value);
|
|
659
|
-
};
|
|
660
|
-
NumericTextBoxComponent.prototype.spin = function (step, timeout) {
|
|
661
|
-
var _this = this;
|
|
662
|
-
clearTimeout(this.spinTimeout);
|
|
663
|
-
this.spinTimeout = window.setTimeout(function () {
|
|
664
|
-
_this.spin(step, constants_1.SPIN_DELAY);
|
|
665
|
-
}, timeout);
|
|
666
|
-
this.addStep(step);
|
|
667
|
-
};
|
|
668
|
-
NumericTextBoxComponent.prototype.addStep = function (step) {
|
|
669
|
-
var value = math_1.add(this.value || 0, this.step * step);
|
|
670
|
-
value = this.limitValue(value);
|
|
671
|
-
value = this.restrictDecimals(value);
|
|
672
|
-
this.setInputValue(value);
|
|
673
|
-
this.updateValue(value);
|
|
674
|
-
};
|
|
675
|
-
NumericTextBoxComponent.prototype.setSelection = function (start, end) {
|
|
676
|
-
if (this.focused) {
|
|
677
|
-
dom_utils_1.invokeElementMethod(this.numericInput, 'setSelectionRange', start, end);
|
|
678
|
-
}
|
|
679
|
-
};
|
|
680
|
-
NumericTextBoxComponent.prototype.limitValue = function (value) {
|
|
681
|
-
var result = value;
|
|
682
|
-
if (!this.isInRange(value)) {
|
|
683
|
-
if (utils_2.isNumber(this.max) && value > this.max) {
|
|
684
|
-
result = this.max;
|
|
685
|
-
}
|
|
686
|
-
if (utils_2.isNumber(this.min) && value < this.min) {
|
|
687
|
-
result = this.min;
|
|
688
|
-
}
|
|
689
|
-
}
|
|
690
|
-
return result;
|
|
691
|
-
};
|
|
692
|
-
NumericTextBoxComponent.prototype.limitInputValue = function (value) {
|
|
693
|
-
var _a = this.numericInput.nativeElement, selectionStart = _a.selectionStart, selectionEnd = _a.selectionEnd, enteredValue = _a.value;
|
|
694
|
-
var limitedValue = value;
|
|
695
|
-
var selectToEnd = false;
|
|
696
|
-
if (!this.isInRange(value)) {
|
|
697
|
-
var lengthChange = enteredValue.length - String(this.inputValue).length;
|
|
698
|
-
var _b = this, min = _b.min, max = _b.max;
|
|
699
|
-
var hasMax = utils_2.isNumber(max);
|
|
700
|
-
var hasMin = utils_2.isNumber(min);
|
|
701
|
-
var padLimit = void 0, replaceNext = void 0;
|
|
702
|
-
var correctedValue = value;
|
|
703
|
-
if (selectionStart === 0 && this.inputValue.substr(1) === enteredValue) {
|
|
704
|
-
return {
|
|
705
|
-
selectionEnd: selectionEnd,
|
|
706
|
-
selectionStart: selectionStart,
|
|
707
|
-
value: null
|
|
708
|
-
};
|
|
709
|
-
}
|
|
710
|
-
if (hasMax && value > max) {
|
|
711
|
-
if (value > 0) {
|
|
712
|
-
replaceNext = true;
|
|
713
|
-
}
|
|
714
|
-
else {
|
|
715
|
-
padLimit = max;
|
|
716
|
-
}
|
|
717
|
-
}
|
|
718
|
-
else if (hasMin && value < min) {
|
|
719
|
-
if (value > 0) {
|
|
720
|
-
padLimit = min;
|
|
721
|
-
}
|
|
722
|
-
else {
|
|
723
|
-
replaceNext = true;
|
|
724
|
-
}
|
|
725
|
-
}
|
|
726
|
-
if (padLimit) {
|
|
727
|
-
var paddedValue = this.tryPadValue(value, padLimit);
|
|
728
|
-
if (paddedValue && utils_2.decimalPart(value) !== utils_2.decimalPart(padLimit)) {
|
|
729
|
-
correctedValue = paddedValue;
|
|
730
|
-
selectToEnd = true;
|
|
731
|
-
}
|
|
732
|
-
}
|
|
733
|
-
else if (replaceNext) {
|
|
734
|
-
if (this.inputValue && selectionStart !== enteredValue.length) {
|
|
735
|
-
correctedValue = parseFloat(enteredValue.substr(0, selectionStart) +
|
|
736
|
-
enteredValue.substr(selectionStart + lengthChange));
|
|
737
|
-
}
|
|
738
|
-
}
|
|
739
|
-
limitedValue = this.limitValue(correctedValue);
|
|
740
|
-
selectToEnd = (selectToEnd || limitedValue !== correctedValue) && this.previousSelection &&
|
|
741
|
-
(this.previousSelection.end - this.previousSelection.start + lengthChange) > 0;
|
|
742
|
-
}
|
|
743
|
-
return {
|
|
744
|
-
selectionEnd: selectToEnd ? String(limitedValue).length : selectionEnd,
|
|
745
|
-
selectionStart: selectionStart,
|
|
746
|
-
value: limitedValue
|
|
747
|
-
};
|
|
748
|
-
};
|
|
749
|
-
NumericTextBoxComponent.prototype.tryPadValue = function (value, limit) {
|
|
750
|
-
var limitLength = String(Math.floor(limit)).length;
|
|
751
|
-
var zeroPadded = utils_2.pad(value, limitLength);
|
|
752
|
-
var zeroPaddedNext = utils_2.pad(value, limitLength + 1);
|
|
753
|
-
var result;
|
|
754
|
-
if (this.isInRange(zeroPadded)) {
|
|
755
|
-
result = zeroPadded;
|
|
756
|
-
}
|
|
757
|
-
else if (this.isInRange(zeroPaddedNext)) {
|
|
758
|
-
result = zeroPaddedNext;
|
|
759
|
-
}
|
|
760
|
-
return result;
|
|
761
|
-
};
|
|
762
|
-
NumericTextBoxComponent.prototype.isInRange = function (value) {
|
|
763
|
-
return !utils_2.isNumber(value) || ((!utils_2.isNumber(this.min) || this.min <= value) && (!utils_2.isNumber(this.max) || value <= this.max));
|
|
764
|
-
};
|
|
765
|
-
NumericTextBoxComponent.prototype.restrictModelValue = function (value) {
|
|
766
|
-
var result = this.restrictDecimals(value, true);
|
|
767
|
-
if (this.autoCorrect && this.limitValue(result) !== result) {
|
|
768
|
-
result = null;
|
|
769
|
-
}
|
|
770
|
-
return result;
|
|
771
|
-
};
|
|
772
|
-
NumericTextBoxComponent.prototype.restrictDecimals = function (value, round) {
|
|
773
|
-
var result = value;
|
|
774
|
-
if (value && this.hasDecimals) {
|
|
775
|
-
var decimals = this.decimals;
|
|
776
|
-
var stringValue = String(value);
|
|
777
|
-
if (round || constants_1.EXPONENT_REGEX.test(stringValue)) {
|
|
778
|
-
result = math_1.toFixedPrecision(value, decimals);
|
|
779
|
-
}
|
|
780
|
-
else {
|
|
781
|
-
var parts = stringValue.split(constants_1.POINT);
|
|
782
|
-
var fraction = parts[1];
|
|
783
|
-
if (fraction && fraction.length > decimals) {
|
|
784
|
-
fraction = fraction.substr(0, decimals);
|
|
785
|
-
result = parseFloat("" + parts[0] + constants_1.POINT + fraction);
|
|
786
|
-
}
|
|
787
|
-
}
|
|
788
|
-
}
|
|
789
|
-
return result;
|
|
790
|
-
};
|
|
791
|
-
NumericTextBoxComponent.prototype.formatInputValue = function (value) {
|
|
792
|
-
var stringValue = String(value);
|
|
793
|
-
var exponentMatch = constants_1.EXPONENT_REGEX.exec(stringValue);
|
|
794
|
-
if (exponentMatch) {
|
|
795
|
-
stringValue = value.toFixed(math_1.limitPrecision(parseInt(exponentMatch[1], 10)));
|
|
796
|
-
}
|
|
797
|
-
return stringValue.replace(constants_1.POINT, this.decimalSeparator);
|
|
798
|
-
};
|
|
799
|
-
NumericTextBoxComponent.prototype.formatValue = function (value, focused) {
|
|
800
|
-
var formattedValue;
|
|
801
|
-
if (value === null || !utils_2.defined(value) || value === '') {
|
|
802
|
-
formattedValue = '';
|
|
803
|
-
}
|
|
804
|
-
else if (focused && !this.readonly) {
|
|
805
|
-
formattedValue = this.formatInputValue(value);
|
|
806
|
-
}
|
|
807
|
-
else {
|
|
808
|
-
formattedValue = this.intl.formatNumber(value, this.format);
|
|
809
|
-
}
|
|
810
|
-
return formattedValue;
|
|
811
|
-
};
|
|
812
|
-
NumericTextBoxComponent.prototype.setInputValue = function (value, focused) {
|
|
813
|
-
if (value === void 0) { value = this.value; }
|
|
814
|
-
if (focused === void 0) { focused = this.focused; }
|
|
815
|
-
var formattedValue = this.formatValue(value, focused);
|
|
816
|
-
this.elementValue = formattedValue;
|
|
817
|
-
this.inputValue = formattedValue;
|
|
818
|
-
};
|
|
819
|
-
NumericTextBoxComponent.prototype.verifySettings = function () {
|
|
820
|
-
if (!core_1.isDevMode()) {
|
|
821
|
-
return;
|
|
822
|
-
}
|
|
823
|
-
if (this.min !== null && this.max !== null && this.min > this.max) {
|
|
824
|
-
throw new Error("The max value should be bigger than the min. See " + constants_1.MIN_DOC_LINK + " and " + constants_1.MAX_DOC_LINK + ".");
|
|
825
|
-
}
|
|
826
|
-
};
|
|
827
|
-
NumericTextBoxComponent.prototype.verifyValue = function (value) {
|
|
828
|
-
if (core_1.isDevMode() && value && typeof value !== 'number') {
|
|
829
|
-
throw new Error("The NumericTextBox component requires value of type Number and " + JSON.stringify(value) + " was set.");
|
|
830
|
-
}
|
|
831
|
-
};
|
|
832
|
-
NumericTextBoxComponent.prototype.parseOptions = function (options) {
|
|
833
|
-
for (var idx = 0; idx < options.length; idx++) {
|
|
834
|
-
var name_1 = options[idx];
|
|
835
|
-
var value = this[name_1];
|
|
836
|
-
if (typeof value === 'string') {
|
|
837
|
-
var parsed = parseFloat(value);
|
|
838
|
-
var valid = !isNaN(parsed);
|
|
839
|
-
if (core_1.isDevMode() && !valid && value !== '') {
|
|
840
|
-
throw new Error('The NumericTextBox component requires value of type Number or a String representing ' +
|
|
841
|
-
("a number for the " + name_1 + " property and " + JSON.stringify(value) + " was set."));
|
|
842
|
-
}
|
|
843
|
-
this[name_1] = valid ? parsed : PARSABLE_DEFAULTS[name_1];
|
|
844
|
-
}
|
|
845
|
-
}
|
|
846
|
-
};
|
|
847
|
-
NumericTextBoxComponent.prototype.intlChange = function () {
|
|
848
|
-
delete this.numericRegex;
|
|
849
|
-
if (this.numericInput && (!this.focused || !this.isValid(this.elementValue))) {
|
|
850
|
-
this.setInputValue();
|
|
851
|
-
}
|
|
852
|
-
};
|
|
853
|
-
NumericTextBoxComponent.prototype.hasTrailingZeros = function (inputValue) {
|
|
854
|
-
if (this.hasDecimals && this.focused) {
|
|
855
|
-
var fraction = inputValue.split(this.decimalSeparator)[1];
|
|
856
|
-
return fraction && fraction.length > this.decimals && fraction.lastIndexOf('0') === fraction.length - 1;
|
|
857
|
-
}
|
|
858
|
-
};
|
|
859
|
-
NumericTextBoxComponent.prototype.selectAll = function () {
|
|
860
|
-
this.setInputValue();
|
|
861
|
-
this.setSelection(0, this.inputValue.length);
|
|
862
|
-
};
|
|
863
|
-
NumericTextBoxComponent.prototype.selectCaret = function () {
|
|
864
|
-
var caretPosition = utils_2.getCaretPosition(this.numericInput.nativeElement);
|
|
865
|
-
var formattedValue = this.elementValue;
|
|
866
|
-
var partialValue = formattedValue.substring(0, caretPosition);
|
|
867
|
-
this.setInputValue();
|
|
868
|
-
if (partialValue.length) {
|
|
869
|
-
var significantCharsInFormattedValue = utils_2.extractSignificantNumericChars(partialValue, this.decimalSeparator);
|
|
870
|
-
var adjustedSignificantChars = this.adjustSignificantChars(formattedValue, significantCharsInFormattedValue);
|
|
871
|
-
this.setSelection(adjustedSignificantChars, adjustedSignificantChars);
|
|
872
|
-
}
|
|
873
|
-
else {
|
|
874
|
-
this.setSelection(0, 0);
|
|
875
|
-
}
|
|
876
|
-
};
|
|
877
|
-
NumericTextBoxComponent.prototype.numberOfLeadingZeroes = function (formattedValue) {
|
|
878
|
-
var separatorIndex = formattedValue.indexOf(this.decimalSeparator);
|
|
879
|
-
var matchedLeadingZeroes = formattedValue.match(/^[^1-9]*?(0+)/);
|
|
880
|
-
if (matchedLeadingZeroes) {
|
|
881
|
-
var lengthOfMatch = matchedLeadingZeroes[0].length;
|
|
882
|
-
var lengthOfLeadingZeroesMatch = matchedLeadingZeroes[1].length;
|
|
883
|
-
return lengthOfMatch === separatorIndex ? lengthOfLeadingZeroesMatch - 1 : lengthOfLeadingZeroesMatch;
|
|
884
|
-
}
|
|
885
|
-
return 0;
|
|
886
|
-
};
|
|
887
|
-
NumericTextBoxComponent.prototype.adjustSignificantChars = function (formattedValue, significantChars) {
|
|
888
|
-
var leadingZeroes = this.numberOfLeadingZeroes(formattedValue);
|
|
889
|
-
if (leadingZeroes > 0) {
|
|
890
|
-
return Math.max(0, significantChars - leadingZeroes);
|
|
891
|
-
}
|
|
892
|
-
return significantChars;
|
|
893
|
-
};
|
|
894
|
-
NumericTextBoxComponent.prototype.handleClasses = function (value, input) {
|
|
895
|
-
var elem = this.hostElement.nativeElement;
|
|
896
|
-
var classes = utils_1.getStylingClasses('input', input, this[input], value);
|
|
897
|
-
if (classes.toRemove) {
|
|
898
|
-
this.renderer.removeClass(elem, classes.toRemove);
|
|
899
|
-
}
|
|
900
|
-
if (classes.toAdd) {
|
|
901
|
-
this.renderer.addClass(elem, classes.toAdd);
|
|
902
|
-
}
|
|
903
|
-
};
|
|
904
|
-
var NumericTextBoxComponent_1;
|
|
905
|
-
tslib_1.__decorate([
|
|
906
|
-
core_1.Input(),
|
|
907
|
-
tslib_1.__metadata("design:type", String)
|
|
908
|
-
], NumericTextBoxComponent.prototype, "focusableId", void 0);
|
|
909
|
-
tslib_1.__decorate([
|
|
910
|
-
core_1.Input(),
|
|
911
|
-
tslib_1.__metadata("design:type", Boolean)
|
|
912
|
-
], NumericTextBoxComponent.prototype, "disabled", void 0);
|
|
913
|
-
tslib_1.__decorate([
|
|
914
|
-
core_1.Input(),
|
|
915
|
-
tslib_1.__metadata("design:type", Boolean)
|
|
916
|
-
], NumericTextBoxComponent.prototype, "readonly", void 0);
|
|
917
|
-
tslib_1.__decorate([
|
|
918
|
-
core_1.Input(),
|
|
919
|
-
tslib_1.__metadata("design:type", String)
|
|
920
|
-
], NumericTextBoxComponent.prototype, "title", void 0);
|
|
921
|
-
tslib_1.__decorate([
|
|
922
|
-
core_1.Input(),
|
|
923
|
-
tslib_1.__metadata("design:type", Boolean)
|
|
924
|
-
], NumericTextBoxComponent.prototype, "autoCorrect", void 0);
|
|
925
|
-
tslib_1.__decorate([
|
|
926
|
-
core_1.Input(),
|
|
927
|
-
tslib_1.__metadata("design:type", Object),
|
|
928
|
-
tslib_1.__metadata("design:paramtypes", [Object])
|
|
929
|
-
], NumericTextBoxComponent.prototype, "format", null);
|
|
930
|
-
tslib_1.__decorate([
|
|
931
|
-
core_1.Input(),
|
|
932
|
-
tslib_1.__metadata("design:type", Number)
|
|
933
|
-
], NumericTextBoxComponent.prototype, "max", void 0);
|
|
934
|
-
tslib_1.__decorate([
|
|
935
|
-
core_1.Input(),
|
|
936
|
-
tslib_1.__metadata("design:type", Number)
|
|
937
|
-
], NumericTextBoxComponent.prototype, "min", void 0);
|
|
938
|
-
tslib_1.__decorate([
|
|
939
|
-
core_1.Input(),
|
|
940
|
-
tslib_1.__metadata("design:type", Number)
|
|
941
|
-
], NumericTextBoxComponent.prototype, "decimals", void 0);
|
|
942
|
-
tslib_1.__decorate([
|
|
943
|
-
core_1.Input(),
|
|
944
|
-
tslib_1.__metadata("design:type", String)
|
|
945
|
-
], NumericTextBoxComponent.prototype, "placeholder", void 0);
|
|
946
|
-
tslib_1.__decorate([
|
|
947
|
-
core_1.Input(),
|
|
948
|
-
tslib_1.__metadata("design:type", Number)
|
|
949
|
-
], NumericTextBoxComponent.prototype, "step", void 0);
|
|
950
|
-
tslib_1.__decorate([
|
|
951
|
-
core_1.Input(),
|
|
952
|
-
tslib_1.__metadata("design:type", Boolean)
|
|
953
|
-
], NumericTextBoxComponent.prototype, "spinners", void 0);
|
|
954
|
-
tslib_1.__decorate([
|
|
955
|
-
core_1.Input(),
|
|
956
|
-
tslib_1.__metadata("design:type", Boolean)
|
|
957
|
-
], NumericTextBoxComponent.prototype, "rangeValidation", void 0);
|
|
958
|
-
tslib_1.__decorate([
|
|
959
|
-
core_1.Input(),
|
|
960
|
-
tslib_1.__metadata("design:type", Number)
|
|
961
|
-
], NumericTextBoxComponent.prototype, "tabindex", void 0);
|
|
962
|
-
tslib_1.__decorate([
|
|
963
|
-
core_1.Input(),
|
|
964
|
-
tslib_1.__metadata("design:type", Number),
|
|
965
|
-
tslib_1.__metadata("design:paramtypes", [Number])
|
|
966
|
-
], NumericTextBoxComponent.prototype, "tabIndex", null);
|
|
967
|
-
tslib_1.__decorate([
|
|
968
|
-
core_1.Input(),
|
|
969
|
-
tslib_1.__metadata("design:type", Boolean)
|
|
970
|
-
], NumericTextBoxComponent.prototype, "changeValueOnScroll", void 0);
|
|
971
|
-
tslib_1.__decorate([
|
|
972
|
-
core_1.Input(),
|
|
973
|
-
tslib_1.__metadata("design:type", Boolean)
|
|
974
|
-
], NumericTextBoxComponent.prototype, "selectOnFocus", void 0);
|
|
975
|
-
tslib_1.__decorate([
|
|
976
|
-
core_1.Input(),
|
|
977
|
-
tslib_1.__metadata("design:type", Number)
|
|
978
|
-
], NumericTextBoxComponent.prototype, "value", void 0);
|
|
979
|
-
tslib_1.__decorate([
|
|
980
|
-
core_1.Input(),
|
|
981
|
-
tslib_1.__metadata("design:type", Number)
|
|
982
|
-
], NumericTextBoxComponent.prototype, "maxlength", void 0);
|
|
983
|
-
tslib_1.__decorate([
|
|
984
|
-
core_1.Input(),
|
|
985
|
-
tslib_1.__metadata("design:type", String),
|
|
986
|
-
tslib_1.__metadata("design:paramtypes", [String])
|
|
987
|
-
], NumericTextBoxComponent.prototype, "size", null);
|
|
988
|
-
tslib_1.__decorate([
|
|
989
|
-
core_1.Input(),
|
|
990
|
-
tslib_1.__metadata("design:type", String),
|
|
991
|
-
tslib_1.__metadata("design:paramtypes", [String])
|
|
992
|
-
], NumericTextBoxComponent.prototype, "rounded", null);
|
|
993
|
-
tslib_1.__decorate([
|
|
994
|
-
core_1.Input(),
|
|
995
|
-
tslib_1.__metadata("design:type", String),
|
|
996
|
-
tslib_1.__metadata("design:paramtypes", [String])
|
|
997
|
-
], NumericTextBoxComponent.prototype, "fillMode", null);
|
|
998
|
-
tslib_1.__decorate([
|
|
999
|
-
core_1.Output(),
|
|
1000
|
-
tslib_1.__metadata("design:type", core_1.EventEmitter)
|
|
1001
|
-
], NumericTextBoxComponent.prototype, "valueChange", void 0);
|
|
1002
|
-
tslib_1.__decorate([
|
|
1003
|
-
core_1.Output('focus'),
|
|
1004
|
-
tslib_1.__metadata("design:type", core_1.EventEmitter)
|
|
1005
|
-
], NumericTextBoxComponent.prototype, "onFocus", void 0);
|
|
1006
|
-
tslib_1.__decorate([
|
|
1007
|
-
core_1.Output('blur'),
|
|
1008
|
-
tslib_1.__metadata("design:type", core_1.EventEmitter)
|
|
1009
|
-
], NumericTextBoxComponent.prototype, "onBlur", void 0);
|
|
1010
|
-
tslib_1.__decorate([
|
|
1011
|
-
core_1.ViewChild('numericInput', { static: true }),
|
|
1012
|
-
tslib_1.__metadata("design:type", core_1.ElementRef)
|
|
1013
|
-
], NumericTextBoxComponent.prototype, "numericInput", void 0);
|
|
1014
|
-
tslib_1.__decorate([
|
|
1015
|
-
core_1.HostBinding('attr.dir'),
|
|
1016
|
-
tslib_1.__metadata("design:type", String)
|
|
1017
|
-
], NumericTextBoxComponent.prototype, "direction", void 0);
|
|
1018
|
-
tslib_1.__decorate([
|
|
1019
|
-
core_1.HostBinding('class.k-disabled'),
|
|
1020
|
-
tslib_1.__metadata("design:type", Boolean),
|
|
1021
|
-
tslib_1.__metadata("design:paramtypes", [])
|
|
1022
|
-
], NumericTextBoxComponent.prototype, "disableClass", null);
|
|
1023
|
-
tslib_1.__decorate([
|
|
1024
|
-
core_1.HostBinding('class.k-input'),
|
|
1025
|
-
core_1.HostBinding('class.k-numerictextbox'),
|
|
1026
|
-
tslib_1.__metadata("design:type", Boolean)
|
|
1027
|
-
], NumericTextBoxComponent.prototype, "hostClasses", void 0);
|
|
1028
|
-
NumericTextBoxComponent = NumericTextBoxComponent_1 = tslib_1.__decorate([
|
|
1029
|
-
core_1.Component({
|
|
1030
|
-
exportAs: 'kendoNumericTextBox',
|
|
1031
|
-
providers: [
|
|
1032
|
-
kendo_angular_l10n_1.LocalizationService,
|
|
1033
|
-
{ provide: kendo_angular_l10n_1.L10N_PREFIX, useValue: 'kendo.numerictextbox' },
|
|
1034
|
-
{ provide: forms_1.NG_VALUE_ACCESSOR, useExisting: core_1.forwardRef(function () { return NumericTextBoxComponent_1; }), multi: true },
|
|
1035
|
-
{ provide: forms_1.NG_VALIDATORS, useExisting: core_1.forwardRef(function () { return NumericTextBoxComponent_1; }), multi: true },
|
|
1036
|
-
{ provide: kendo_angular_common_1.KendoInput, useExisting: core_1.forwardRef(function () { return NumericTextBoxComponent_1; }) }
|
|
1037
|
-
],
|
|
1038
|
-
selector: 'kendo-numerictextbox',
|
|
1039
|
-
template: "\n <ng-container kendoNumericTextBoxLocalizedMessages\n i18n-increment=\"kendo.numerictextbox.increment|The title for the **Increment** button in the NumericTextBox\"\n increment=\"Increase value\"\n i18n-decrement=\"kendo.numerictextbox.decrement|The title for the **Decrement** button in the NumericTextBox\"\n decrement=\"Decrease value\"\n >\n </ng-container>\n <input\n role=\"spinbutton\"\n class=\"k-input-inner\"\n autocomplete=\"off\"\n autocorrect=\"off\"\n [id]=\"focusableId\"\n [attr.aria-valuemin]=\"min\"\n [attr.aria-valuemax]=\"max\"\n [attr.aria-valuenow]=\"value\"\n [attr.title]=\"title\"\n [attr.placeholder]=\"placeholder\"\n [attr.maxLength]=\"maxlength\"\n [tabindex]=\"tabIndex\"\n [disabled]=\"disabled\"\n [readonly]=\"readonly\"\n [kendoEventsOutsideAngular]=\"{\n mousedown: handleMouseDown,\n dragenter: handleDragEnter,\n keydown: handleKeyDown,\n input: handleInput,\n focus: handleFocus,\n blur: handleBlur,\n paste: handlePaste\n }\"\n #numericInput />\n <span\n class=\"k-input-spinner k-spin-button\" *ngIf=\"spinners\"\n [kendoEventsOutsideAngular]=\"{ mouseup: releaseArrow, mouseleave: releaseArrow }\"\n >\n <button\n type=\"button\"\n [kendoEventsOutsideAngular]=\"{ mousedown: increasePress }\"\n [attr.aria-hidden]=\"true\"\n [attr.aria-label]=\"incrementTitle\"\n [title]=\"incrementTitle\"\n [class.k-active]=\"arrowDirection === ArrowDirection.Up\"\n class=\"k-spinner-increase k-button k-icon-button k-button-solid k-button-solid-base\"\n tabindex=\"-1\"\n >\n <span class=\"k-button-icon k-icon k-i-arrow-n\"></span>\n </button>\n <button\n type=\"button\"\n [kendoEventsOutsideAngular]=\"{ mousedown: decreasePress }\"\n [attr.aria-hidden]=\"true\"\n [attr.aria-label]=\"decrementTitle\"\n [title]=\"decrementTitle\"\n [class.k-active]=\"arrowDirection === ArrowDirection.Down\"\n class=\"k-spinner-decrease k-button k-icon-button k-button-solid k-button-solid-base\"\n tabindex=\"-1\"\n >\n <span class=\"k-button-icon k-icon k-i-arrow-s\"></span>\n </button>\n </span>\n "
|
|
1040
|
-
}),
|
|
1041
|
-
tslib_1.__metadata("design:paramtypes", [kendo_angular_intl_1.IntlService,
|
|
1042
|
-
core_1.Renderer2,
|
|
1043
|
-
kendo_angular_l10n_1.LocalizationService,
|
|
1044
|
-
core_1.Injector,
|
|
1045
|
-
core_1.NgZone,
|
|
1046
|
-
core_1.ChangeDetectorRef,
|
|
1047
|
-
core_1.ElementRef])
|
|
1048
|
-
], NumericTextBoxComponent);
|
|
1049
|
-
return NumericTextBoxComponent;
|
|
1050
|
-
}());
|
|
1051
|
-
exports.NumericTextBoxComponent = NumericTextBoxComponent;
|