@progress/kendo-angular-dateinputs 6.0.3 → 7.0.0-next.202203231050
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-dateinputs.umd.js +5 -0
- package/calendar/calendar-common.module.d.ts +24 -0
- package/{dist/es2015/calendar → calendar}/calendar.component.d.ts +40 -21
- package/{dist/es2015/calendar → calendar}/calendar.module.d.ts +16 -0
- package/{dist/es2015/calendar → calendar}/calendars.module.d.ts +6 -0
- package/{dist/es2015/calendar → calendar}/for.directive.d.ts +8 -5
- package/{dist/es2015/calendar → calendar}/header.component.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/horizontal-view-list.component.d.ts +9 -5
- package/{dist/es2015/calendar → calendar}/localization/calendar-custom-messages.component.d.ts +4 -1
- package/{dist/es2015/calendar → calendar}/localization/calendar-localized-messages.directive.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/localization/calendar-messages.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/localization/multiview-calendar-custom-messages.component.d.ts +4 -1
- package/{dist/es2015/calendar → calendar}/localization/multiview-calendar-localized-messages.directive.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/localization/multiview-calendar-messages.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/models/cell-context.interface.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/keydown.interface.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/navigation-action.enum.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/row-length-options.interface.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/scrollable.interface.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/selection-range-end.type.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/selection-range.interface.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/selection.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/type.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/view-service.interface.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/view.enum.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/models/view.type.d.ts +0 -0
- package/{dist/es2015/calendar → calendar}/multiview-calendar.component.d.ts +38 -24
- package/{dist/es2015/calendar → calendar}/multiview-calendar.module.d.ts +14 -0
- package/{dist/es2015/calendar → calendar}/navigation.component.d.ts +4 -1
- package/{dist/es2015/calendar → calendar}/services/bus-view.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/services/century-view.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/services/decade-view.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/services/disabled-dates.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/services/dom.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/services/month-view.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/services/navigation.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/services/scroll-sync.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/services/selection.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/services/weeknames.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/services/year-view.service.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/templates/cell-template.directive.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/templates/century-cell-template.directive.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/templates/decade-cell-template.directive.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/templates/header-title-template.directive.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/templates/month-cell-template.directive.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/templates/navigation-item-template.directive.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/templates/weeknumber-cell-template.directive.d.ts +3 -0
- package/{dist/es2015/calendar → calendar}/templates/year-cell-template.directive.d.ts +3 -0
- package/calendar/templates.module.d.ts +33 -0
- package/{dist/es2015/calendar → calendar}/view-list.component.d.ts +9 -5
- package/{dist/es2015/calendar → calendar}/view.component.d.ts +5 -1
- package/{dist/es2015/common → common}/dom-queries.d.ts +0 -0
- package/{dist/es2015/common → common}/models/fillmode.d.ts +0 -0
- package/{dist/es2015/common → common}/models/rounded.d.ts +0 -0
- package/{dist/es2015/common → common}/models/size.d.ts +0 -0
- package/{dist/es2015/common → common}/picker.service.d.ts +0 -0
- package/{dist/es2015/common → common}/utils.d.ts +0 -0
- package/{dist/es2015/dateinput → dateinput}/arrow.enum.d.ts +0 -0
- package/{dist/es2015/dateinput → dateinput}/dateinput.component.d.ts +21 -12
- package/dateinput/dateinput.module.d.ts +20 -0
- package/{dist/es2015/dateinput → dateinput}/localization/dateinput-custom-messages.component.d.ts +4 -1
- package/{dist/es2015/dateinput → dateinput}/localization/dateinput-localized-messages.directive.d.ts +3 -0
- package/{dist/es2015/dateinput → dateinput}/localization/messages.d.ts +3 -0
- package/{dist/es2015/dateinput → dateinput}/models/format-placeholder.model.d.ts +0 -0
- package/{dist/es2015/dateinput → dateinput}/models/format-settings.model.d.ts +0 -0
- package/{dist/es2015/dateinput → dateinput}/models/incremental-steps.model.d.ts +0 -0
- package/{dist/es2015/dateinputs.module.d.ts → dateinputs.module.d.ts} +10 -0
- package/{dist/es2015/datepicker → datepicker}/datepicker.component.d.ts +36 -24
- package/datepicker/datepicker.module.d.ts +24 -0
- package/{dist/es2015/datepicker → datepicker}/localization/datepicker-custom-messages.component.d.ts +4 -1
- package/{dist/es2015/datepicker → datepicker}/localization/datepicker-localized-messages.directive.d.ts +3 -0
- package/{dist/es2015/datepicker → datepicker}/localization/messages.d.ts +3 -0
- package/{dist/es2015/daterange → daterange}/auto-correct-on.type.d.ts +0 -0
- package/{dist/es2015/daterange → daterange}/date-range-end-input.directive.d.ts +5 -1
- package/{dist/es2015/daterange → daterange}/date-range-input.d.ts +5 -3
- package/{dist/es2015/daterange → daterange}/date-range-popup-template.directive.d.ts +3 -0
- package/{dist/es2015/daterange → daterange}/date-range-popup.component.d.ts +12 -5
- package/daterange/date-range-popup.service.d.ts +52 -0
- package/{dist/es2015/daterange → daterange}/date-range-selection.directive.d.ts +8 -3
- package/{dist/es2015/daterange → daterange}/date-range-start-input.directive.d.ts +5 -1
- package/{dist/es2015/daterange → daterange}/date-range.component.d.ts +4 -1
- package/{dist/es2015/daterange → daterange}/date-range.module.d.ts +15 -1
- package/{dist/es2015/daterange → daterange}/date-range.service.d.ts +8 -38
- package/{dist/es2015/datetimepicker → datetimepicker}/datetimepicker.component.d.ts +38 -23
- package/datetimepicker/datetimepicker.module.d.ts +25 -0
- package/{dist/es2015/datetimepicker → datetimepicker}/localization/datetimepicker-custom-messages.component.d.ts +4 -1
- package/{dist/es2015/datetimepicker → datetimepicker}/localization/localized-messages.directive.d.ts +3 -0
- package/{dist/es2015/datetimepicker → datetimepicker}/localization/messages.d.ts +3 -0
- package/{dist/es2015/datetimepicker → datetimepicker}/models/active-tab.type.d.ts +0 -0
- package/{dist/es2015/defaults.d.ts → defaults.d.ts} +0 -0
- package/esm2015/calendar/calendar-common.module.js +45 -0
- package/{dist/es2015 → esm2015}/calendar/calendar.component.js +277 -246
- package/{dist/es2015 → esm2015}/calendar/calendar.module.js +71 -34
- package/{dist/es2015 → esm2015}/calendar/calendars.module.js +23 -14
- package/{dist/es2015 → esm2015}/calendar/for.directive.js +16 -25
- package/{dist/es2015 → esm2015}/calendar/header.component.js +97 -73
- package/{dist/es2015 → esm2015}/calendar/horizontal-view-list.component.js +155 -130
- package/esm2015/calendar/localization/calendar-custom-messages.component.js +40 -0
- package/esm2015/calendar/localization/calendar-localized-messages.directive.js +36 -0
- package/esm2015/calendar/localization/calendar-messages.js +26 -0
- package/esm2015/calendar/localization/multiview-calendar-custom-messages.component.js +40 -0
- package/esm2015/calendar/localization/multiview-calendar-localized-messages.directive.js +36 -0
- package/esm2015/calendar/localization/multiview-calendar-messages.js +26 -0
- package/{dist/es → esm2015}/calendar/models/cell-context.interface.js +1 -0
- package/{dist/es2015 → esm2015}/calendar/models/keydown.interface.js +1 -0
- package/{dist/es → esm2015}/calendar/models/navigation-action.enum.js +0 -0
- package/{dist/es2015 → esm2015}/calendar/models/row-length-options.interface.js +1 -0
- package/{dist/es/virtualization → esm2015/calendar}/models/scrollable.interface.js +1 -0
- package/{dist/es → esm2015}/calendar/models/selection-range-end.type.js +1 -0
- package/{dist/es2015 → esm2015}/calendar/models/selection-range.interface.js +0 -0
- package/{dist/es → esm2015}/calendar/models/selection.js +1 -0
- package/{dist/es → esm2015}/calendar/models/type.js +1 -0
- package/{dist/es → esm2015}/calendar/models/view-service.interface.js +1 -0
- package/{dist/es → esm2015}/calendar/models/view.enum.js +0 -0
- package/{dist/es → esm2015}/calendar/models/view.type.js +1 -0
- package/{dist/es2015 → esm2015}/calendar/multiview-calendar.component.js +246 -298
- package/{dist/es2015 → esm2015}/calendar/multiview-calendar.module.js +63 -32
- package/{dist/es2015 → esm2015}/calendar/navigation.component.js +71 -62
- package/{dist/es2015 → esm2015}/calendar/services/bus-view.service.js +9 -11
- package/{dist/es2015 → esm2015}/calendar/services/century-view.service.js +8 -11
- package/{dist/es2015 → esm2015}/calendar/services/decade-view.service.js +8 -11
- package/{dist/es2015 → esm2015}/calendar/services/disabled-dates.service.js +8 -12
- package/{dist/es2015 → esm2015}/calendar/services/dom.service.js +10 -26
- package/{dist/es2015 → esm2015}/calendar/services/month-view.service.js +9 -10
- package/{dist/es2015 → esm2015}/calendar/services/navigation.service.js +9 -9
- package/{dist/es2015 → esm2015}/calendar/services/scroll-sync.service.js +10 -13
- package/{dist/es2015 → esm2015}/calendar/services/selection.service.js +9 -9
- package/{dist/es2015 → esm2015}/calendar/services/weeknames.service.js +9 -9
- package/{dist/es2015 → esm2015}/calendar/services/year-view.service.js +9 -13
- package/{dist/es2015 → esm2015}/calendar/templates/cell-template.directive.js +12 -11
- package/{dist/es2015 → esm2015}/calendar/templates/century-cell-template.directive.js +12 -11
- package/{dist/es2015 → esm2015}/calendar/templates/decade-cell-template.directive.js +12 -11
- package/{dist/es2015 → esm2015}/calendar/templates/header-title-template.directive.js +12 -11
- package/{dist/es2015 → esm2015}/calendar/templates/month-cell-template.directive.js +12 -11
- package/{dist/es2015 → esm2015}/calendar/templates/navigation-item-template.directive.js +12 -11
- package/{dist/es2015 → esm2015}/calendar/templates/weeknumber-cell-template.directive.js +12 -11
- package/{dist/es2015 → esm2015}/calendar/templates/year-cell-template.directive.js +12 -11
- package/esm2015/calendar/templates.module.js +73 -0
- package/{dist/es2015 → esm2015}/calendar/view-list.component.js +135 -120
- package/{dist/es2015 → esm2015}/calendar/view.component.js +104 -98
- package/{dist/es2015 → esm2015}/common/dom-queries.js +0 -0
- 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/es2015 → esm2015}/common/picker.service.js +0 -0
- package/{dist/es2015 → esm2015}/common/utils.js +0 -0
- package/{dist/es → esm2015}/dateinput/arrow.enum.js +0 -0
- package/{dist/es2015 → esm2015}/dateinput/dateinput.component.js +179 -183
- package/esm2015/dateinput/dateinput.module.js +41 -0
- package/esm2015/dateinput/localization/dateinput-custom-messages.component.js +40 -0
- package/esm2015/dateinput/localization/dateinput-localized-messages.directive.js +36 -0
- package/esm2015/dateinput/localization/messages.js +24 -0
- package/{dist/es → esm2015}/dateinput/models/format-placeholder.model.js +1 -0
- package/{dist/es → esm2015}/dateinput/models/format-settings.model.js +1 -0
- package/{dist/es → esm2015}/dateinput/models/incremental-steps.model.js +1 -0
- package/{dist/es2015 → esm2015}/dateinputs.module.js +28 -10
- package/{dist/es2015 → esm2015}/datepicker/datepicker.component.js +285 -285
- package/esm2015/datepicker/datepicker.module.js +72 -0
- package/esm2015/datepicker/localization/datepicker-custom-messages.component.js +40 -0
- package/esm2015/datepicker/localization/datepicker-localized-messages.directive.js +36 -0
- package/esm2015/datepicker/localization/messages.js +28 -0
- package/{dist/es → esm2015}/daterange/auto-correct-on.type.js +1 -0
- package/{dist/es2015 → esm2015}/daterange/date-range-end-input.directive.js +21 -27
- package/{dist/es2015 → esm2015}/daterange/date-range-input.js +11 -8
- package/esm2015/daterange/date-range-popup-template.directive.js +23 -0
- package/{dist/es2015 → esm2015}/daterange/date-range-popup.component.js +75 -91
- package/esm2015/daterange/date-range-popup.service.js +87 -0
- package/{dist/es2015 → esm2015}/daterange/date-range-selection.directive.js +26 -39
- package/{dist/es2015 → esm2015}/daterange/date-range-start-input.directive.js +21 -27
- package/esm2015/daterange/date-range.component.js +74 -0
- package/{dist/es2015 → esm2015}/daterange/date-range.module.js +27 -12
- package/{dist/es2015 → esm2015}/daterange/date-range.service.js +8 -75
- package/{dist/es2015 → esm2015}/datetimepicker/datetimepicker.component.js +398 -227
- package/esm2015/datetimepicker/datetimepicker.module.js +80 -0
- package/esm2015/datetimepicker/localization/datetimepicker-custom-messages.component.js +40 -0
- package/esm2015/datetimepicker/localization/localized-messages.directive.js +36 -0
- package/esm2015/datetimepicker/localization/messages.js +48 -0
- package/{dist/es → esm2015}/datetimepicker/models/active-tab.type.js +1 -0
- package/{dist/es2015 → esm2015}/defaults.js +0 -0
- package/esm2015/kendo-angular-dateinputs.js +8 -0
- package/{dist/es → esm2015}/main.js +25 -0
- package/{dist/es2015 → esm2015}/package-metadata.js +1 -1
- package/{dist/es → esm2015}/popup-settings.model.js +1 -0
- package/{dist/es2015 → esm2015}/preventable-event.js +0 -0
- package/esm2015/timepicker/localization/messages.js +34 -0
- package/esm2015/timepicker/localization/timepicker-custom-messages.component.js +40 -0
- package/esm2015/timepicker/localization/timepicker-localized-messages.directive.js +36 -0
- package/esm2015/timepicker/localization/timeselector-custom-messages.component.js +42 -0
- package/esm2015/timepicker/localization/timeselector-localized-messages.directive.js +36 -0
- package/{dist/es → esm2015}/timepicker/models/incremental-steps.model.js +1 -0
- package/{dist/es → esm2015}/timepicker/models/list-item.interface.js +1 -0
- package/{dist/es → esm2015}/timepicker/models/list-service-settings.js +1 -0
- package/{dist/es → esm2015}/timepicker/models/list-service.interface.js +1 -0
- package/{dist/es2015 → esm2015}/timepicker/models/time-part.default.js +0 -0
- package/{dist/es2015 → esm2015}/timepicker/services/dayperiod.service.js +9 -15
- package/{dist/es2015 → esm2015}/timepicker/services/dom.service.js +8 -13
- package/{dist/es2015 → esm2015}/timepicker/services/hours.service.js +9 -14
- package/{dist/es2015 → esm2015}/timepicker/services/milliseconds.service.js +9 -14
- package/{dist/es2015 → esm2015}/timepicker/services/minutes.service.js +9 -14
- package/{dist/es2015 → esm2015}/timepicker/services/seconds.service.js +9 -14
- package/{dist/es2015 → esm2015}/timepicker/timelist.component.js +66 -61
- package/{dist/es2015 → esm2015}/timepicker/timepicker.component.js +219 -179
- package/{dist/es2015 → esm2015}/timepicker/timepicker.module.js +32 -15
- package/{dist/es2015 → esm2015}/timepicker/timeselector.component.js +181 -104
- package/{dist/es2015 → esm2015}/timepicker/util.js +8 -20
- package/{dist/es2015 → esm2015}/touch-enabled.js +0 -0
- package/{dist/es2015 → esm2015}/util.js +1 -6
- package/{dist/es2015 → esm2015}/validators/disabled-date.validator.js +0 -0
- package/{dist/es2015 → esm2015}/validators/disabled-dates-range.validator.js +0 -2
- package/{dist/es2015 → esm2015}/validators/incomplete-date.validator.js +0 -0
- package/{dist/es2015 → esm2015}/validators/max.validator.js +0 -0
- package/{dist/es2015 → esm2015}/validators/min.validator.js +0 -0
- package/{dist/es2015 → esm2015}/validators/time-range.validator.js +0 -0
- package/{dist/es2015/calendar → esm2015/virtualization}/models/scrollable.interface.js +1 -0
- package/{dist/es2015 → esm2015}/virtualization/services/row-height.service.js +1 -3
- package/{dist/es2015 → esm2015}/virtualization/services/scroller.service.js +0 -2
- package/{dist/es2015 → esm2015}/virtualization/virtualization.component.js +75 -90
- package/esm2015/virtualization/virtualization.module.js +30 -0
- package/{dist/fesm2015/index.js → fesm2015/kendo-angular-dateinputs.js} +9630 -9048
- package/{dist/es/calendar/models/selection-range.interface.js → kendo-angular-dateinputs.d.ts} +3 -2
- package/{dist/es2015/main.d.ts → main.d.ts} +25 -0
- package/{dist/es2015/package-metadata.d.ts → package-metadata.d.ts} +0 -0
- package/package.json +44 -115
- package/{dist/es2015/popup-settings.model.d.ts → popup-settings.model.d.ts} +0 -0
- package/{dist/es2015/preventable-event.d.ts → preventable-event.d.ts} +0 -0
- package/schematics/ngAdd/index.js +5 -2
- package/schematics/ngAdd/index.js.map +1 -1
- package/{dist/es2015/timepicker → timepicker}/localization/messages.d.ts +3 -0
- package/{dist/es2015/timepicker → timepicker}/localization/timepicker-custom-messages.component.d.ts +4 -1
- package/{dist/es2015/timepicker → timepicker}/localization/timepicker-localized-messages.directive.d.ts +3 -0
- package/{dist/es2015/timepicker → timepicker}/localization/timeselector-custom-messages.component.d.ts +4 -1
- package/{dist/es2015/timepicker → timepicker}/localization/timeselector-localized-messages.directive.d.ts +3 -0
- package/{dist/es2015/timepicker → timepicker}/models/incremental-steps.model.d.ts +0 -0
- package/{dist/es2015/timepicker → timepicker}/models/list-item.interface.d.ts +0 -0
- package/{dist/es2015/timepicker → timepicker}/models/list-service-settings.d.ts +0 -0
- package/{dist/es2015/timepicker → timepicker}/models/list-service.interface.d.ts +0 -0
- package/{dist/es2015/timepicker → timepicker}/models/time-part.default.d.ts +0 -0
- package/{dist/es2015/timepicker → timepicker}/services/dayperiod.service.d.ts +3 -0
- package/{dist/es2015/timepicker → timepicker}/services/dom.service.d.ts +3 -0
- package/{dist/es2015/timepicker → timepicker}/services/hours.service.d.ts +3 -0
- package/{dist/es2015/timepicker → timepicker}/services/milliseconds.service.d.ts +3 -0
- package/{dist/es2015/timepicker → timepicker}/services/minutes.service.d.ts +3 -0
- package/{dist/es2015/timepicker → timepicker}/services/seconds.service.d.ts +3 -0
- package/{dist/es2015/timepicker → timepicker}/timelist.component.d.ts +4 -1
- package/{dist/es2015/timepicker → timepicker}/timepicker.component.d.ts +32 -18
- package/timepicker/timepicker.module.d.ts +27 -0
- package/{dist/es2015/timepicker → timepicker}/timeselector.component.d.ts +10 -4
- package/{dist/es2015/timepicker → timepicker}/util.d.ts +0 -0
- package/{dist/es2015/touch-enabled.d.ts → touch-enabled.d.ts} +0 -0
- package/{dist/es2015/util.d.ts → util.d.ts} +0 -0
- package/{dist/es2015/validators → validators}/disabled-date.validator.d.ts +0 -0
- package/{dist/es2015/validators → validators}/disabled-dates-range.validator.d.ts +0 -0
- package/{dist/es2015/validators → validators}/incomplete-date.validator.d.ts +0 -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/es2015/validators → validators}/time-range.validator.d.ts +0 -0
- package/{dist/es2015/virtualization → virtualization}/models/scrollable.interface.d.ts +0 -0
- package/{dist/es2015/virtualization → virtualization}/services/row-height.service.d.ts +0 -0
- package/{dist/es2015/virtualization → virtualization}/services/scroller.service.d.ts +0 -0
- package/{dist/es2015/virtualization → virtualization}/virtualization.component.d.ts +8 -5
- package/{dist/es2015/virtualization → virtualization}/virtualization.module.d.ts +6 -0
- package/dist/cdn/js/kendo-angular-dateinputs.js +0 -20
- package/dist/cdn/main.js +0 -5
- package/dist/es/calendar/calendar-common.module.js +0 -41
- package/dist/es/calendar/calendar.component.js +0 -1189
- package/dist/es/calendar/calendar.module.js +0 -108
- package/dist/es/calendar/calendars.module.js +0 -60
- package/dist/es/calendar/for.directive.js +0 -135
- package/dist/es/calendar/header.component.js +0 -170
- package/dist/es/calendar/horizontal-view-list.component.js +0 -363
- package/dist/es/calendar/localization/calendar-custom-messages.component.js +0 -43
- package/dist/es/calendar/localization/calendar-localized-messages.directive.js +0 -35
- package/dist/es/calendar/localization/calendar-messages.js +0 -30
- package/dist/es/calendar/localization/multiview-calendar-custom-messages.component.js +0 -43
- package/dist/es/calendar/localization/multiview-calendar-localized-messages.directive.js +0 -35
- package/dist/es/calendar/localization/multiview-calendar-messages.js +0 -30
- package/dist/es/calendar/models/keydown.interface.js +0 -4
- package/dist/es/calendar/models/row-length-options.interface.js +0 -4
- package/dist/es/calendar/models/scrollable.interface.js +0 -4
- package/dist/es/calendar/multiview-calendar.component.js +0 -1122
- package/dist/es/calendar/multiview-calendar.module.js +0 -97
- package/dist/es/calendar/navigation.component.js +0 -173
- package/dist/es/calendar/services/bus-view.service.js +0 -83
- package/dist/es/calendar/services/century-view.service.js +0 -180
- package/dist/es/calendar/services/decade-view.service.js +0 -179
- package/dist/es/calendar/services/disabled-dates.service.js +0 -70
- package/dist/es/calendar/services/dom.service.js +0 -195
- package/dist/es/calendar/services/month-view.service.js +0 -203
- package/dist/es/calendar/services/navigation.service.js +0 -53
- package/dist/es/calendar/services/scroll-sync.service.js +0 -85
- package/dist/es/calendar/services/selection.service.js +0 -55
- package/dist/es/calendar/services/weeknames.service.js +0 -27
- package/dist/es/calendar/services/year-view.service.js +0 -204
- package/dist/es/calendar/templates/cell-template.directive.js +0 -46
- package/dist/es/calendar/templates/century-cell-template.directive.js +0 -45
- package/dist/es/calendar/templates/decade-cell-template.directive.js +0 -45
- package/dist/es/calendar/templates/header-title-template.directive.js +0 -44
- package/dist/es/calendar/templates/month-cell-template.directive.js +0 -43
- package/dist/es/calendar/templates/navigation-item-template.directive.js +0 -44
- package/dist/es/calendar/templates/weeknumber-cell-template.directive.js +0 -43
- package/dist/es/calendar/templates/year-cell-template.directive.js +0 -46
- package/dist/es/calendar/templates.module.js +0 -59
- package/dist/es/calendar/view-list.component.js +0 -301
- package/dist/es/calendar/view.component.js +0 -318
- package/dist/es/common/dom-queries.js +0 -24
- package/dist/es/common/picker.service.js +0 -18
- package/dist/es/common/utils.js +0 -35
- package/dist/es/dateinput/dateinput.component.js +0 -1617
- package/dist/es/dateinput/dateinput.module.js +0 -37
- package/dist/es/dateinput/localization/dateinput-custom-messages.component.js +0 -43
- package/dist/es/dateinput/localization/dateinput-localized-messages.directive.js +0 -35
- package/dist/es/dateinput/localization/messages.js +0 -26
- package/dist/es/dateinputs.module.js +0 -63
- package/dist/es/datepicker/datepicker.component.js +0 -1256
- package/dist/es/datepicker/datepicker.module.js +0 -55
- package/dist/es/datepicker/localization/datepicker-custom-messages.component.js +0 -43
- package/dist/es/datepicker/localization/datepicker-localized-messages.directive.js +0 -35
- package/dist/es/datepicker/localization/messages.js +0 -34
- package/dist/es/daterange/date-range-end-input.directive.js +0 -97
- package/dist/es/daterange/date-range-input.js +0 -131
- package/dist/es/daterange/date-range-popup-template.directive.js +0 -23
- package/dist/es/daterange/date-range-popup.component.js +0 -403
- package/dist/es/daterange/date-range-selection.directive.js +0 -230
- package/dist/es/daterange/date-range-start-input.directive.js +0 -97
- package/dist/es/daterange/date-range.component.js +0 -71
- package/dist/es/daterange/date-range.module.js +0 -83
- package/dist/es/daterange/date-range.service.js +0 -208
- package/dist/es/datetimepicker/datetimepicker.component.js +0 -1309
- package/dist/es/datetimepicker/datetimepicker.module.js +0 -57
- package/dist/es/datetimepicker/localization/datetimepicker-custom-messages.component.js +0 -43
- package/dist/es/datetimepicker/localization/localized-messages.directive.js +0 -35
- package/dist/es/datetimepicker/localization/messages.js +0 -74
- package/dist/es/defaults.js +0 -24
- package/dist/es/index.js +0 -63
- package/dist/es/package-metadata.js +0 -15
- package/dist/es/preventable-event.js +0 -29
- package/dist/es/timepicker/localization/messages.js +0 -46
- package/dist/es/timepicker/localization/timepicker-custom-messages.component.js +0 -43
- package/dist/es/timepicker/localization/timepicker-localized-messages.directive.js +0 -35
- package/dist/es/timepicker/localization/timeselector-custom-messages.component.js +0 -45
- package/dist/es/timepicker/localization/timeselector-localized-messages.directive.js +0 -35
- package/dist/es/timepicker/models/time-part.default.js +0 -14
- package/dist/es/timepicker/services/dayperiod.service.js +0 -130
- package/dist/es/timepicker/services/dom.service.js +0 -64
- package/dist/es/timepicker/services/hours.service.js +0 -129
- package/dist/es/timepicker/services/milliseconds.service.js +0 -130
- package/dist/es/timepicker/services/minutes.service.js +0 -127
- package/dist/es/timepicker/services/seconds.service.js +0 -127
- package/dist/es/timepicker/timelist.component.js +0 -297
- package/dist/es/timepicker/timepicker.component.js +0 -1044
- package/dist/es/timepicker/timepicker.module.js +0 -75
- package/dist/es/timepicker/timeselector.component.js +0 -486
- package/dist/es/timepicker/util.js +0 -82
- package/dist/es/touch-enabled.js +0 -9
- package/dist/es/util.js +0 -395
- package/dist/es/validators/disabled-date.validator.js +0 -18
- package/dist/es/validators/disabled-dates-range.validator.js +0 -28
- package/dist/es/validators/incomplete-date.validator.js +0 -18
- package/dist/es/validators/max.validator.js +0 -21
- package/dist/es/validators/min.validator.js +0 -21
- package/dist/es/validators/time-range.validator.js +0 -23
- package/dist/es/virtualization/services/row-height.service.js +0 -72
- package/dist/es/virtualization/services/scroller.service.js +0 -111
- package/dist/es/virtualization/virtualization.component.js +0 -343
- package/dist/es/virtualization/virtualization.module.js +0 -30
- package/dist/es2015/calendar/calendar-common.module.d.ts +0 -15
- package/dist/es2015/calendar/calendar-common.module.js +0 -38
- package/dist/es2015/calendar/localization/calendar-custom-messages.component.js +0 -35
- package/dist/es2015/calendar/localization/calendar-localized-messages.directive.js +0 -31
- package/dist/es2015/calendar/localization/calendar-messages.js +0 -24
- package/dist/es2015/calendar/localization/multiview-calendar-custom-messages.component.js +0 -35
- package/dist/es2015/calendar/localization/multiview-calendar-localized-messages.directive.js +0 -31
- package/dist/es2015/calendar/localization/multiview-calendar-messages.js +0 -24
- package/dist/es2015/calendar/models/cell-context.interface.js +0 -4
- package/dist/es2015/calendar/models/navigation-action.enum.js +0 -20
- package/dist/es2015/calendar/models/selection-range-end.type.js +0 -4
- package/dist/es2015/calendar/models/selection.js +0 -4
- package/dist/es2015/calendar/models/type.js +0 -4
- package/dist/es2015/calendar/models/view-service.interface.js +0 -4
- package/dist/es2015/calendar/models/view.enum.js +0 -16
- package/dist/es2015/calendar/models/view.type.js +0 -4
- package/dist/es2015/calendar/templates.module.d.ts +0 -21
- package/dist/es2015/calendar/templates.module.js +0 -56
- 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/dateinput/arrow.enum.js +0 -13
- package/dist/es2015/dateinput/dateinput.module.d.ts +0 -10
- package/dist/es2015/dateinput/dateinput.module.js +0 -34
- package/dist/es2015/dateinput/localization/dateinput-custom-messages.component.js +0 -35
- package/dist/es2015/dateinput/localization/dateinput-localized-messages.directive.js +0 -31
- package/dist/es2015/dateinput/localization/messages.js +0 -20
- package/dist/es2015/dateinput/models/format-placeholder.model.js +0 -4
- package/dist/es2015/dateinput/models/format-settings.model.js +0 -4
- package/dist/es2015/dateinput/models/incremental-steps.model.js +0 -4
- package/dist/es2015/datepicker/datepicker.module.d.ts +0 -10
- package/dist/es2015/datepicker/datepicker.module.js +0 -52
- package/dist/es2015/datepicker/localization/datepicker-custom-messages.component.js +0 -35
- package/dist/es2015/datepicker/localization/datepicker-localized-messages.directive.js +0 -31
- package/dist/es2015/datepicker/localization/messages.js +0 -28
- package/dist/es2015/daterange/auto-correct-on.type.js +0 -4
- package/dist/es2015/daterange/date-range-popup-template.directive.js +0 -22
- package/dist/es2015/daterange/date-range.component.js +0 -68
- package/dist/es2015/datetimepicker/datetimepicker.module.d.ts +0 -10
- package/dist/es2015/datetimepicker/datetimepicker.module.js +0 -57
- package/dist/es2015/datetimepicker/localization/datetimepicker-custom-messages.component.js +0 -35
- package/dist/es2015/datetimepicker/localization/localized-messages.directive.js +0 -31
- package/dist/es2015/datetimepicker/localization/messages.js +0 -68
- package/dist/es2015/datetimepicker/models/active-tab.type.js +0 -4
- package/dist/es2015/index.d.ts +0 -63
- package/dist/es2015/index.js +0 -63
- package/dist/es2015/index.metadata.json +0 -1
- package/dist/es2015/main.js +0 -35
- package/dist/es2015/popup-settings.model.js +0 -4
- package/dist/es2015/timepicker/localization/messages.js +0 -40
- package/dist/es2015/timepicker/localization/timepicker-custom-messages.component.js +0 -35
- package/dist/es2015/timepicker/localization/timepicker-localized-messages.directive.js +0 -31
- package/dist/es2015/timepicker/localization/timeselector-custom-messages.component.js +0 -37
- package/dist/es2015/timepicker/localization/timeselector-localized-messages.directive.js +0 -31
- package/dist/es2015/timepicker/models/incremental-steps.model.js +0 -4
- package/dist/es2015/timepicker/models/list-item.interface.js +0 -4
- package/dist/es2015/timepicker/models/list-service-settings.js +0 -4
- package/dist/es2015/timepicker/models/list-service.interface.js +0 -4
- package/dist/es2015/timepicker/timepicker.module.d.ts +0 -10
- package/dist/es2015/virtualization/models/scrollable.interface.js +0 -4
- package/dist/es2015/virtualization/virtualization.module.js +0 -27
- package/dist/fesm5/index.js +0 -15216
- package/dist/npm/calendar/calendar-common.module.js +0 -43
- package/dist/npm/calendar/calendar.component.js +0 -1191
- package/dist/npm/calendar/calendar.module.js +0 -110
- package/dist/npm/calendar/calendars.module.js +0 -62
- package/dist/npm/calendar/for.directive.js +0 -138
- package/dist/npm/calendar/header.component.js +0 -172
- package/dist/npm/calendar/horizontal-view-list.component.js +0 -365
- package/dist/npm/calendar/localization/calendar-custom-messages.component.js +0 -45
- package/dist/npm/calendar/localization/calendar-localized-messages.directive.js +0 -37
- package/dist/npm/calendar/localization/calendar-messages.js +0 -32
- package/dist/npm/calendar/localization/multiview-calendar-custom-messages.component.js +0 -45
- package/dist/npm/calendar/localization/multiview-calendar-localized-messages.directive.js +0 -37
- package/dist/npm/calendar/localization/multiview-calendar-messages.js +0 -32
- package/dist/npm/calendar/models/cell-context.interface.js +0 -6
- package/dist/npm/calendar/models/keydown.interface.js +0 -6
- package/dist/npm/calendar/models/navigation-action.enum.js +0 -22
- package/dist/npm/calendar/models/row-length-options.interface.js +0 -6
- package/dist/npm/calendar/models/scrollable.interface.js +0 -6
- package/dist/npm/calendar/models/selection-range-end.type.js +0 -6
- package/dist/npm/calendar/models/selection-range.interface.js +0 -10
- package/dist/npm/calendar/models/selection.js +0 -6
- package/dist/npm/calendar/models/type.js +0 -6
- package/dist/npm/calendar/models/view-service.interface.js +0 -6
- package/dist/npm/calendar/models/view.enum.js +0 -18
- package/dist/npm/calendar/models/view.type.js +0 -6
- package/dist/npm/calendar/multiview-calendar.component.js +0 -1124
- package/dist/npm/calendar/multiview-calendar.module.js +0 -99
- package/dist/npm/calendar/navigation.component.js +0 -175
- package/dist/npm/calendar/services/bus-view.service.js +0 -85
- package/dist/npm/calendar/services/century-view.service.js +0 -182
- package/dist/npm/calendar/services/decade-view.service.js +0 -181
- package/dist/npm/calendar/services/disabled-dates.service.js +0 -72
- package/dist/npm/calendar/services/dom.service.js +0 -212
- package/dist/npm/calendar/services/month-view.service.js +0 -205
- package/dist/npm/calendar/services/navigation.service.js +0 -55
- package/dist/npm/calendar/services/scroll-sync.service.js +0 -88
- package/dist/npm/calendar/services/selection.service.js +0 -57
- package/dist/npm/calendar/services/weeknames.service.js +0 -29
- package/dist/npm/calendar/services/year-view.service.js +0 -207
- package/dist/npm/calendar/templates/cell-template.directive.js +0 -48
- package/dist/npm/calendar/templates/century-cell-template.directive.js +0 -47
- package/dist/npm/calendar/templates/decade-cell-template.directive.js +0 -47
- package/dist/npm/calendar/templates/header-title-template.directive.js +0 -46
- package/dist/npm/calendar/templates/month-cell-template.directive.js +0 -45
- package/dist/npm/calendar/templates/navigation-item-template.directive.js +0 -46
- package/dist/npm/calendar/templates/weeknumber-cell-template.directive.js +0 -45
- package/dist/npm/calendar/templates/year-cell-template.directive.js +0 -48
- package/dist/npm/calendar/templates.module.js +0 -61
- package/dist/npm/calendar/view-list.component.js +0 -303
- package/dist/npm/calendar/view.component.js +0 -320
- package/dist/npm/common/dom-queries.js +0 -26
- 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/picker.service.js +0 -20
- package/dist/npm/common/utils.js +0 -37
- package/dist/npm/dateinput/arrow.enum.js +0 -15
- package/dist/npm/dateinput/dateinput.component.js +0 -1620
- package/dist/npm/dateinput/dateinput.module.js +0 -39
- package/dist/npm/dateinput/localization/dateinput-custom-messages.component.js +0 -45
- package/dist/npm/dateinput/localization/dateinput-localized-messages.directive.js +0 -37
- package/dist/npm/dateinput/localization/messages.js +0 -28
- package/dist/npm/dateinput/models/format-placeholder.model.js +0 -6
- package/dist/npm/dateinput/models/format-settings.model.js +0 -6
- package/dist/npm/dateinput/models/incremental-steps.model.js +0 -6
- package/dist/npm/dateinputs.module.js +0 -65
- package/dist/npm/datepicker/datepicker.component.js +0 -1258
- package/dist/npm/datepicker/datepicker.module.js +0 -57
- package/dist/npm/datepicker/localization/datepicker-custom-messages.component.js +0 -45
- package/dist/npm/datepicker/localization/datepicker-localized-messages.directive.js +0 -37
- package/dist/npm/datepicker/localization/messages.js +0 -36
- package/dist/npm/daterange/auto-correct-on.type.js +0 -6
- package/dist/npm/daterange/date-range-end-input.directive.js +0 -99
- package/dist/npm/daterange/date-range-input.js +0 -133
- package/dist/npm/daterange/date-range-popup-template.directive.js +0 -25
- package/dist/npm/daterange/date-range-popup.component.js +0 -405
- package/dist/npm/daterange/date-range-selection.directive.js +0 -232
- package/dist/npm/daterange/date-range-start-input.directive.js +0 -99
- package/dist/npm/daterange/date-range.component.js +0 -73
- package/dist/npm/daterange/date-range.module.js +0 -85
- package/dist/npm/daterange/date-range.service.js +0 -211
- package/dist/npm/datetimepicker/datetimepicker.component.js +0 -1311
- package/dist/npm/datetimepicker/datetimepicker.module.js +0 -59
- package/dist/npm/datetimepicker/localization/datetimepicker-custom-messages.component.js +0 -45
- package/dist/npm/datetimepicker/localization/localized-messages.directive.js +0 -37
- package/dist/npm/datetimepicker/localization/messages.js +0 -76
- package/dist/npm/datetimepicker/models/active-tab.type.js +0 -6
- package/dist/npm/defaults.js +0 -26
- package/dist/npm/index.js +0 -127
- package/dist/npm/main.js +0 -68
- package/dist/npm/package-metadata.js +0 -17
- package/dist/npm/popup-settings.model.js +0 -6
- package/dist/npm/preventable-event.js +0 -31
- package/dist/npm/timepicker/localization/messages.js +0 -48
- package/dist/npm/timepicker/localization/timepicker-custom-messages.component.js +0 -45
- package/dist/npm/timepicker/localization/timepicker-localized-messages.directive.js +0 -37
- package/dist/npm/timepicker/localization/timeselector-custom-messages.component.js +0 -47
- package/dist/npm/timepicker/localization/timeselector-localized-messages.directive.js +0 -37
- package/dist/npm/timepicker/models/incremental-steps.model.js +0 -6
- package/dist/npm/timepicker/models/list-item.interface.js +0 -6
- package/dist/npm/timepicker/models/list-service-settings.js +0 -6
- package/dist/npm/timepicker/models/list-service.interface.js +0 -6
- package/dist/npm/timepicker/models/time-part.default.js +0 -16
- package/dist/npm/timepicker/services/dayperiod.service.js +0 -136
- package/dist/npm/timepicker/services/dom.service.js +0 -70
- package/dist/npm/timepicker/services/hours.service.js +0 -134
- package/dist/npm/timepicker/services/milliseconds.service.js +0 -135
- package/dist/npm/timepicker/services/minutes.service.js +0 -132
- package/dist/npm/timepicker/services/seconds.service.js +0 -132
- package/dist/npm/timepicker/timelist.component.js +0 -299
- package/dist/npm/timepicker/timepicker.component.js +0 -1046
- package/dist/npm/timepicker/timepicker.module.js +0 -77
- package/dist/npm/timepicker/timeselector.component.js +0 -488
- package/dist/npm/timepicker/util.js +0 -101
- package/dist/npm/touch-enabled.js +0 -11
- package/dist/npm/util.js +0 -399
- package/dist/npm/validators/disabled-date.validator.js +0 -20
- package/dist/npm/validators/disabled-dates-range.validator.js +0 -30
- package/dist/npm/validators/incomplete-date.validator.js +0 -20
- package/dist/npm/validators/max.validator.js +0 -23
- package/dist/npm/validators/min.validator.js +0 -23
- package/dist/npm/validators/time-range.validator.js +0 -25
- package/dist/npm/virtualization/models/scrollable.interface.js +0 -6
- package/dist/npm/virtualization/services/row-height.service.js +0 -74
- package/dist/npm/virtualization/services/scroller.service.js +0 -113
- package/dist/npm/virtualization/virtualization.component.js +0 -346
- package/dist/npm/virtualization/virtualization.module.js +0 -32
- package/dist/systemjs/kendo-angular-dateinputs.js +0 -5
package/dist/npm/util.js
DELETED
|
@@ -1,399 +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
|
-
/* tslint:disable:no-bitwise max-line-length */
|
|
8
|
-
var kendo_date_math_1 = require("@progress/kendo-date-math");
|
|
9
|
-
var defaults_1 = require("./defaults");
|
|
10
|
-
var selection_range_interface_1 = require("./calendar/models/selection-range.interface");
|
|
11
|
-
var utils_1 = require("./common/utils");
|
|
12
|
-
var isSet = function (value) { return value !== null && value !== undefined; };
|
|
13
|
-
var ɵ0 = isSet;
|
|
14
|
-
exports.ɵ0 = ɵ0;
|
|
15
|
-
var setter = function (method) { return function (date, value) {
|
|
16
|
-
var clone = kendo_date_math_1.cloneDate(date);
|
|
17
|
-
clone[method](value);
|
|
18
|
-
return clone;
|
|
19
|
-
}; };
|
|
20
|
-
var ɵ1 = setter;
|
|
21
|
-
exports.ɵ1 = ɵ1;
|
|
22
|
-
/**
|
|
23
|
-
* @hidden
|
|
24
|
-
*/
|
|
25
|
-
exports.setTime = function (origin, candidate) {
|
|
26
|
-
var date = kendo_date_math_1.cloneDate(origin);
|
|
27
|
-
date.setHours(candidate.getHours(), candidate.getMinutes(), candidate.getSeconds(), candidate.getMilliseconds());
|
|
28
|
-
return date;
|
|
29
|
-
};
|
|
30
|
-
var normalizeTimes = function (candidate, min, max) { return ({
|
|
31
|
-
candidateValue: exports.setTime(defaults_1.MIDNIGHT_DATE, candidate),
|
|
32
|
-
maxValue: kendo_date_math_1.addDays(exports.setTime(defaults_1.MIDNIGHT_DATE, max), min.getHours() < max.getHours() ||
|
|
33
|
-
(min.getHours() === max.getHours() && min.getMinutes() < max.getMinutes()) ? 0 : 1),
|
|
34
|
-
minValue: exports.setTime(defaults_1.MIDNIGHT_DATE, min)
|
|
35
|
-
}); };
|
|
36
|
-
var ɵ2 = normalizeTimes;
|
|
37
|
-
exports.ɵ2 = ɵ2;
|
|
38
|
-
/**
|
|
39
|
-
* @hidden
|
|
40
|
-
*/
|
|
41
|
-
exports.setYears = setter('setFullYear');
|
|
42
|
-
/**
|
|
43
|
-
* @hidden
|
|
44
|
-
*/
|
|
45
|
-
exports.setHours = setter('setHours');
|
|
46
|
-
/**
|
|
47
|
-
* @hidden
|
|
48
|
-
*/
|
|
49
|
-
exports.setMinutes = setter('setMinutes');
|
|
50
|
-
/**
|
|
51
|
-
* @hidden
|
|
52
|
-
*/
|
|
53
|
-
exports.setSeconds = setter('setSeconds');
|
|
54
|
-
/**
|
|
55
|
-
* @hidden
|
|
56
|
-
*/
|
|
57
|
-
exports.setMilliseconds = setter('setMilliseconds');
|
|
58
|
-
/**
|
|
59
|
-
* @hidden
|
|
60
|
-
*/
|
|
61
|
-
exports.range = function (start, end, step) {
|
|
62
|
-
if (step === void 0) { step = 1; }
|
|
63
|
-
var result = [];
|
|
64
|
-
for (var i = start; i < end; i = i + step) {
|
|
65
|
-
result.push(i);
|
|
66
|
-
}
|
|
67
|
-
return result;
|
|
68
|
-
};
|
|
69
|
-
/**
|
|
70
|
-
* @hidden
|
|
71
|
-
*/
|
|
72
|
-
exports.isInRange = function (candidate, min, max) { return (!candidate || !((min && min > candidate) || (max && max < candidate))); };
|
|
73
|
-
/**
|
|
74
|
-
* @hidden
|
|
75
|
-
*/
|
|
76
|
-
exports.isInTimeRange = function (candidate, min, max) {
|
|
77
|
-
if (!candidate || !min || !max) {
|
|
78
|
-
return true;
|
|
79
|
-
}
|
|
80
|
-
var _a = normalizeTimes(candidate, min, max), candidateValue = _a.candidateValue, minValue = _a.minValue, maxValue = _a.maxValue;
|
|
81
|
-
return minValue <= candidateValue && candidateValue <= maxValue;
|
|
82
|
-
};
|
|
83
|
-
/**
|
|
84
|
-
* @hidden
|
|
85
|
-
*/
|
|
86
|
-
exports.isValidRange = function (min, max) { return (!isSet(min) || !isSet(max) || min <= max); };
|
|
87
|
-
/**
|
|
88
|
-
* @hidden
|
|
89
|
-
*/
|
|
90
|
-
exports.dateInRange = function (candidate, min, max) {
|
|
91
|
-
if (!candidate) {
|
|
92
|
-
return candidate;
|
|
93
|
-
}
|
|
94
|
-
if (min && candidate < min) {
|
|
95
|
-
return kendo_date_math_1.cloneDate(min);
|
|
96
|
-
}
|
|
97
|
-
if (max && candidate > max) {
|
|
98
|
-
return kendo_date_math_1.cloneDate(max);
|
|
99
|
-
}
|
|
100
|
-
return candidate;
|
|
101
|
-
};
|
|
102
|
-
/**
|
|
103
|
-
* @hidden
|
|
104
|
-
*/
|
|
105
|
-
exports.timeInRange = function (candidate, min, max) {
|
|
106
|
-
if (!candidate || !min || !max) {
|
|
107
|
-
return candidate;
|
|
108
|
-
}
|
|
109
|
-
var _a = normalizeTimes(candidate, min, max), candidateValue = _a.candidateValue, minValue = _a.minValue, maxValue = _a.maxValue;
|
|
110
|
-
if (candidateValue < minValue) {
|
|
111
|
-
return exports.setTime(candidate, min);
|
|
112
|
-
}
|
|
113
|
-
if (candidateValue > maxValue) {
|
|
114
|
-
return exports.setTime(candidate, max);
|
|
115
|
-
}
|
|
116
|
-
return candidate;
|
|
117
|
-
};
|
|
118
|
-
/**
|
|
119
|
-
* @hidden
|
|
120
|
-
*/
|
|
121
|
-
exports.getNow = function () { return new Date(); };
|
|
122
|
-
/**
|
|
123
|
-
* @hidden
|
|
124
|
-
*/
|
|
125
|
-
exports.getToday = function () { return kendo_date_math_1.getDate(new Date()); };
|
|
126
|
-
/**
|
|
127
|
-
* @hidden
|
|
128
|
-
*/
|
|
129
|
-
exports.noop = function (_) { }; // tslint:disable-line:no-empty
|
|
130
|
-
/**
|
|
131
|
-
* @hidden
|
|
132
|
-
*/
|
|
133
|
-
exports.isWindowAvailable = function () {
|
|
134
|
-
return typeof window !== 'undefined';
|
|
135
|
-
};
|
|
136
|
-
/**
|
|
137
|
-
* @hidden
|
|
138
|
-
*/
|
|
139
|
-
exports.stringifyClassObject = function (classes) {
|
|
140
|
-
var pushToAcc = function (acc, cls) { return classes[cls] ? acc.concat(cls) : acc; };
|
|
141
|
-
return Object.keys(classes).reduce(pushToAcc, []).join(' ');
|
|
142
|
-
};
|
|
143
|
-
/**
|
|
144
|
-
* @hidden
|
|
145
|
-
*/
|
|
146
|
-
exports.shiftWeekNames = function (names, offset) { return (names.slice(offset).concat(names.slice(0, offset))); };
|
|
147
|
-
/**
|
|
148
|
-
* @hidden
|
|
149
|
-
*/
|
|
150
|
-
exports.approximateStringMatching = function (oldTextOrigin, oldFormat, newTextOrigin, caret) {
|
|
151
|
-
// Remove the right part of the cursor.
|
|
152
|
-
//oldFormat = oldFormat.substring(0, caret + oldText.length - newText.length);
|
|
153
|
-
var oldIndex = caret + oldTextOrigin.length - newTextOrigin.length;
|
|
154
|
-
var oldTextSeparator = oldTextOrigin[oldIndex];
|
|
155
|
-
var oldText = oldTextOrigin.substring(0, caret + oldTextOrigin.length - newTextOrigin.length);
|
|
156
|
-
var newText = newTextOrigin.substring(0, caret);
|
|
157
|
-
var diff = [];
|
|
158
|
-
// Handle typing a single character over the same selection.
|
|
159
|
-
if (oldText === newText && caret > 0) {
|
|
160
|
-
diff.push([oldFormat[caret - 1], newText[caret - 1]]);
|
|
161
|
-
return diff;
|
|
162
|
-
}
|
|
163
|
-
if (oldText.indexOf(newText) === 0 && (newText.length === 0 || oldFormat[newText.length - 1] !== oldFormat[newText.length])) {
|
|
164
|
-
// Handle Delete/Backspace.
|
|
165
|
-
var deletedSymbol = "";
|
|
166
|
-
//XXX:
|
|
167
|
-
// Whole text is replaced with a same char
|
|
168
|
-
// Nasty patch required to keep the selection in the first segment
|
|
169
|
-
if (newText.length === 1) {
|
|
170
|
-
diff.push([oldFormat[0], newText[0]]);
|
|
171
|
-
}
|
|
172
|
-
for (var i = newText.length; i < oldText.length; i++) {
|
|
173
|
-
if (oldFormat[i] !== deletedSymbol && oldFormat[i] !== "_") {
|
|
174
|
-
deletedSymbol = oldFormat[i];
|
|
175
|
-
diff.push([deletedSymbol, ""]);
|
|
176
|
-
}
|
|
177
|
-
}
|
|
178
|
-
return diff;
|
|
179
|
-
}
|
|
180
|
-
// Handle inserting text (the new text is longer than the previous one).
|
|
181
|
-
// Handle typing over a literal as well.
|
|
182
|
-
if (newText.indexOf(oldText) === 0 || oldFormat[caret - 1] === "_") {
|
|
183
|
-
var symbol = oldFormat[0];
|
|
184
|
-
for (var i = Math.max(0, oldText.length - 1); i < oldFormat.length; i++) {
|
|
185
|
-
if (oldFormat[i] !== "_") {
|
|
186
|
-
symbol = oldFormat[i];
|
|
187
|
-
break;
|
|
188
|
-
}
|
|
189
|
-
}
|
|
190
|
-
return [[symbol, newText[caret - 1]]];
|
|
191
|
-
}
|
|
192
|
-
// Handle entering a space or a separator, for navigation to the next item.
|
|
193
|
-
if (newText[newText.length - 1] === " " || (newText[newText.length - 1] === oldTextSeparator && oldFormat[oldIndex] === '_')) {
|
|
194
|
-
return [[oldFormat[caret - 1], "_"]];
|
|
195
|
-
}
|
|
196
|
-
// Handle typing over a correctly selected part.
|
|
197
|
-
return [[oldFormat[caret - 1], newText[caret - 1]]];
|
|
198
|
-
};
|
|
199
|
-
/**
|
|
200
|
-
* @hidden
|
|
201
|
-
*/
|
|
202
|
-
exports.domContainerFactory = function (type) { return function (children, classes, styles) {
|
|
203
|
-
if (classes === void 0) { classes = ""; }
|
|
204
|
-
if (styles === void 0) { styles = {}; }
|
|
205
|
-
var container = document.createElement(type);
|
|
206
|
-
container.className = classes;
|
|
207
|
-
Object.keys(styles).map(function (key) { return container.style[key] = styles[key]; });
|
|
208
|
-
if (typeof children === 'string') {
|
|
209
|
-
container.innerHTML = children || '';
|
|
210
|
-
}
|
|
211
|
-
else {
|
|
212
|
-
(children || []).forEach(function (child) { return child && container.appendChild(child); });
|
|
213
|
-
}
|
|
214
|
-
return container;
|
|
215
|
-
}; };
|
|
216
|
-
/**
|
|
217
|
-
* @hidden
|
|
218
|
-
*/
|
|
219
|
-
exports.hasChange = function (changes, field) { return changes[field] !== undefined; };
|
|
220
|
-
/**
|
|
221
|
-
* @hidden
|
|
222
|
-
*/
|
|
223
|
-
exports.hasExistingValue = function (changes, field) { return changes[field] && changes[field].currentValue !== undefined && changes[field].currentValue !== null; };
|
|
224
|
-
/**
|
|
225
|
-
* @hidden
|
|
226
|
-
*/
|
|
227
|
-
exports.last = function (list) {
|
|
228
|
-
if (list === void 0) { list = []; }
|
|
229
|
-
return list && list[list.length - 1];
|
|
230
|
-
};
|
|
231
|
-
/**
|
|
232
|
-
* @hidden
|
|
233
|
-
*/
|
|
234
|
-
exports.isInSelectionRange = function (value, selectionRange) {
|
|
235
|
-
var _a = selectionRange || selection_range_interface_1.EMPTY_SELECTIONRANGE, start = _a.start, end = _a.end;
|
|
236
|
-
if (!start || !end) {
|
|
237
|
-
return false;
|
|
238
|
-
}
|
|
239
|
-
return start < value && value < end;
|
|
240
|
-
};
|
|
241
|
-
/**
|
|
242
|
-
* @hidden
|
|
243
|
-
*/
|
|
244
|
-
exports.either = function (value1, value2) { return value1 || value2; };
|
|
245
|
-
/**
|
|
246
|
-
* @hidden
|
|
247
|
-
*/
|
|
248
|
-
exports.clampRange = function (value) { return ({ start: value, end: value }); };
|
|
249
|
-
/**
|
|
250
|
-
* @hidden
|
|
251
|
-
*/
|
|
252
|
-
exports.isEqualRange = function (initial, updated) {
|
|
253
|
-
var _a = initial || selection_range_interface_1.EMPTY_SELECTIONRANGE, initialStart = _a.start, initialEnd = _a.end;
|
|
254
|
-
var _b = updated || selection_range_interface_1.EMPTY_SELECTIONRANGE, updatedStart = _b.start, updatedEnd = _b.end;
|
|
255
|
-
return kendo_date_math_1.isEqual(initialStart, updatedStart) && kendo_date_math_1.isEqual(initialEnd, updatedEnd);
|
|
256
|
-
};
|
|
257
|
-
/**
|
|
258
|
-
* @hidden
|
|
259
|
-
*/
|
|
260
|
-
exports.areDatesEqual = function (first, second) {
|
|
261
|
-
first = first || [];
|
|
262
|
-
second = second || [];
|
|
263
|
-
return first.length === second.length && first.every(function (date, index) { return kendo_date_math_1.isEqual(date, second[index]); });
|
|
264
|
-
};
|
|
265
|
-
/**
|
|
266
|
-
* @hidden
|
|
267
|
-
*/
|
|
268
|
-
exports.sortDates = function (dates) {
|
|
269
|
-
return dates.filter(function (date) { return utils_1.isPresent(date); }).sort(function (a, b) { return a.getTime() - b.getTime(); });
|
|
270
|
-
};
|
|
271
|
-
/**
|
|
272
|
-
* @hidden
|
|
273
|
-
*
|
|
274
|
-
* Creates a new date based on the date information from the specified date portion
|
|
275
|
-
* and the time information from the time portion.
|
|
276
|
-
* If a parameter is not provided, returns `null`.
|
|
277
|
-
*/
|
|
278
|
-
exports.mergeDateAndTime = function (date, time) {
|
|
279
|
-
if (!(date && time)) {
|
|
280
|
-
return null;
|
|
281
|
-
}
|
|
282
|
-
return new Date(date.getFullYear(), date.getMonth(), date.getDate(), time.getHours(), time.getMinutes(), time.getSeconds(), time.getMilliseconds());
|
|
283
|
-
};
|
|
284
|
-
/**
|
|
285
|
-
* @hidden
|
|
286
|
-
*/
|
|
287
|
-
exports.lastMillisecondOfDate = function (date) {
|
|
288
|
-
if (!date) {
|
|
289
|
-
return null;
|
|
290
|
-
}
|
|
291
|
-
return new Date(date.getFullYear(), date.getMonth(), date.getDate(), 23, 59, 59, 999);
|
|
292
|
-
};
|
|
293
|
-
/**
|
|
294
|
-
* @hidden
|
|
295
|
-
*
|
|
296
|
-
* Returns an array with dates ranging between and including the specified start and
|
|
297
|
-
* end dates that are evaluated as disabled.
|
|
298
|
-
*/
|
|
299
|
-
exports.disabledDatesInRange = function (start, end, isDateDisabled) {
|
|
300
|
-
if (!(start && end && isDateDisabled) || (start > end)) {
|
|
301
|
-
return [];
|
|
302
|
-
}
|
|
303
|
-
var dates = [];
|
|
304
|
-
var current = start;
|
|
305
|
-
while (current <= end) {
|
|
306
|
-
if (isDateDisabled(current)) {
|
|
307
|
-
dates.push(current);
|
|
308
|
-
}
|
|
309
|
-
current = kendo_date_math_1.addDays(current, 1);
|
|
310
|
-
}
|
|
311
|
-
return dates;
|
|
312
|
-
};
|
|
313
|
-
/**
|
|
314
|
-
* @hidden
|
|
315
|
-
*
|
|
316
|
-
* Crops the last two digits from the year of the provided date value.
|
|
317
|
-
*/
|
|
318
|
-
exports.cropTwoDigitYear = function (date) {
|
|
319
|
-
if (!utils_1.isPresent(date) || isNaN(date.getTime())) {
|
|
320
|
-
return 0;
|
|
321
|
-
}
|
|
322
|
-
return Number(date
|
|
323
|
-
.getFullYear()
|
|
324
|
-
.toString()
|
|
325
|
-
.slice(-2));
|
|
326
|
-
};
|
|
327
|
-
/**
|
|
328
|
-
* @hidden
|
|
329
|
-
*
|
|
330
|
-
* Used when resetting millisecond segment value in the DateInput
|
|
331
|
-
*/
|
|
332
|
-
exports.msPaddingFromFormat = function (format) {
|
|
333
|
-
return Array(format.match(/S+(\1)/)[0].length).join("0");
|
|
334
|
-
};
|
|
335
|
-
/**
|
|
336
|
-
* @hidden
|
|
337
|
-
*/
|
|
338
|
-
exports.millisecondDigitsInFormat = function (format) {
|
|
339
|
-
var result = format && format.match(/S+(\1)/);
|
|
340
|
-
return result ? result[0].length : 0;
|
|
341
|
-
};
|
|
342
|
-
/**
|
|
343
|
-
* @hidden
|
|
344
|
-
*/
|
|
345
|
-
exports.millisecondStepFor = function (digits) {
|
|
346
|
-
return Math.pow(10, 3 - digits);
|
|
347
|
-
};
|
|
348
|
-
/**
|
|
349
|
-
* @hidden
|
|
350
|
-
*
|
|
351
|
-
* Checks if a tab keydown would would move the focus outside of the calendar.
|
|
352
|
-
*/
|
|
353
|
-
exports.isTabExitingCalendar = function (calendarType, focusedElement, shiftKey) {
|
|
354
|
-
if (!utils_1.isPresent(focusedElement)) {
|
|
355
|
-
return false;
|
|
356
|
-
}
|
|
357
|
-
return calendarType === 'infinite' || ( // infinte calendar is always exited on first tab keydown
|
|
358
|
-
calendarType === 'classic' &&
|
|
359
|
-
(shiftKey && focusedElement.classList.contains('k-calendar')) || // exited on main calendar element focused and back-tab
|
|
360
|
-
(!shiftKey && focusedElement.classList.contains('k-next-view')) // exited on next button focused and regular tab
|
|
361
|
-
);
|
|
362
|
-
};
|
|
363
|
-
/**
|
|
364
|
-
* @hidden
|
|
365
|
-
* Returns the size class based on the component and size input.
|
|
366
|
-
*/
|
|
367
|
-
exports.getSizeClass = function (component, size) {
|
|
368
|
-
var SIZE_CLASSES = {
|
|
369
|
-
'small': "k-" + component + "-sm",
|
|
370
|
-
'medium': "k-" + component + "-md",
|
|
371
|
-
'large': "k-" + component + "-lg"
|
|
372
|
-
};
|
|
373
|
-
return SIZE_CLASSES[size];
|
|
374
|
-
};
|
|
375
|
-
/**
|
|
376
|
-
* @hidden
|
|
377
|
-
* Returns the rounded class based on the rounded input.
|
|
378
|
-
*/
|
|
379
|
-
exports.getRoundedClass = function (rounded) {
|
|
380
|
-
var ROUNDED_CLASSES = {
|
|
381
|
-
'small': 'k-rounded-sm',
|
|
382
|
-
'medium': 'k-rounded-md',
|
|
383
|
-
'large': 'k-rounded-lg',
|
|
384
|
-
'full': 'k-rounded-full'
|
|
385
|
-
};
|
|
386
|
-
return ROUNDED_CLASSES[rounded];
|
|
387
|
-
};
|
|
388
|
-
/**
|
|
389
|
-
* @hidden
|
|
390
|
-
* Return the fillMode class based on the component and fillMode input.
|
|
391
|
-
*/
|
|
392
|
-
exports.getFillModeClass = function (component, fillMode) {
|
|
393
|
-
var FILLMODE_CLASSES = {
|
|
394
|
-
'solid': "k-" + component + "-solid",
|
|
395
|
-
'flat': "k-" + component + "-flat",
|
|
396
|
-
'outline': "k-" + component + "-outline"
|
|
397
|
-
};
|
|
398
|
-
return FILLMODE_CLASSES[fillMode];
|
|
399
|
-
};
|
|
@@ -1,20 +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
|
-
/**
|
|
8
|
-
* @hidden
|
|
9
|
-
*/
|
|
10
|
-
exports.disabledDatesValidator = function (isDateDisabled) {
|
|
11
|
-
return function (control) {
|
|
12
|
-
if (!isDateDisabled || !control.value) {
|
|
13
|
-
return null;
|
|
14
|
-
}
|
|
15
|
-
var error = {
|
|
16
|
-
disabledDate: true
|
|
17
|
-
};
|
|
18
|
-
return isDateDisabled(control.value) ? error : null;
|
|
19
|
-
};
|
|
20
|
-
};
|
|
@@ -1,30 +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 util_1 = require("../util");
|
|
8
|
-
var utils_1 = require("../common/utils");
|
|
9
|
-
var noop = function () { return null; };
|
|
10
|
-
var ɵ0 = noop;
|
|
11
|
-
exports.ɵ0 = ɵ0;
|
|
12
|
-
/**
|
|
13
|
-
* @hidden
|
|
14
|
-
*/
|
|
15
|
-
exports.disabledDatesRangeValidator = function (isDateDisabled) {
|
|
16
|
-
if (!utils_1.isPresent(isDateDisabled)) {
|
|
17
|
-
return noop;
|
|
18
|
-
}
|
|
19
|
-
return function (selectedRange) {
|
|
20
|
-
var isRangeComplete = utils_1.isPresent(selectedRange) && utils_1.isPresent(selectedRange.start) && utils_1.isPresent(selectedRange.end);
|
|
21
|
-
if (!isRangeComplete || selectedRange.start > selectedRange.end) {
|
|
22
|
-
return null;
|
|
23
|
-
}
|
|
24
|
-
var disabledDates = util_1.disabledDatesInRange(selectedRange.start, selectedRange.end, isDateDisabled);
|
|
25
|
-
var error = {
|
|
26
|
-
disabledDatesInRange: disabledDates
|
|
27
|
-
};
|
|
28
|
-
return disabledDates.length ? error : null;
|
|
29
|
-
};
|
|
30
|
-
};
|
|
@@ -1,20 +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 utils_1 = require("../common/utils");
|
|
8
|
-
/**
|
|
9
|
-
* @hidden
|
|
10
|
-
*/
|
|
11
|
-
exports.incompleteDateValidator = function () {
|
|
12
|
-
return function (control, incomplete) {
|
|
13
|
-
if (!utils_1.isPresent(control.value) && incomplete) {
|
|
14
|
-
return { incompleteDate: true };
|
|
15
|
-
}
|
|
16
|
-
else {
|
|
17
|
-
return null;
|
|
18
|
-
}
|
|
19
|
-
};
|
|
20
|
-
};
|
|
@@ -1,23 +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
|
-
/**
|
|
8
|
-
* @hidden
|
|
9
|
-
*/
|
|
10
|
-
exports.maxValidator = function (maxValue) {
|
|
11
|
-
return function (control) {
|
|
12
|
-
var err = {
|
|
13
|
-
maxError: {
|
|
14
|
-
maxValue: maxValue,
|
|
15
|
-
value: control.value
|
|
16
|
-
}
|
|
17
|
-
};
|
|
18
|
-
if (!maxValue || !control.value) {
|
|
19
|
-
return null;
|
|
20
|
-
}
|
|
21
|
-
return control.value > maxValue ? err : null;
|
|
22
|
-
};
|
|
23
|
-
};
|
|
@@ -1,23 +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
|
-
/**
|
|
8
|
-
* @hidden
|
|
9
|
-
*/
|
|
10
|
-
exports.minValidator = function (minValue) {
|
|
11
|
-
return function (control) {
|
|
12
|
-
var err = {
|
|
13
|
-
minError: {
|
|
14
|
-
minValue: minValue,
|
|
15
|
-
value: control.value
|
|
16
|
-
}
|
|
17
|
-
};
|
|
18
|
-
if (!minValue || !control.value) {
|
|
19
|
-
return null;
|
|
20
|
-
}
|
|
21
|
-
return control.value < minValue ? err : null;
|
|
22
|
-
};
|
|
23
|
-
};
|
|
@@ -1,25 +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 util_1 = require("../util");
|
|
8
|
-
/**
|
|
9
|
-
* @hidden
|
|
10
|
-
*/
|
|
11
|
-
exports.timeRangeValidator = function (min, max) {
|
|
12
|
-
return function (control) {
|
|
13
|
-
if (!min || !max || !control.value) {
|
|
14
|
-
return null;
|
|
15
|
-
}
|
|
16
|
-
var err = {
|
|
17
|
-
timeRangeError: {
|
|
18
|
-
maxValue: max,
|
|
19
|
-
minValue: min,
|
|
20
|
-
value: control.value
|
|
21
|
-
}
|
|
22
|
-
};
|
|
23
|
-
return util_1.isInTimeRange(control.value, min, max) ? null : err;
|
|
24
|
-
};
|
|
25
|
-
};
|
|
@@ -1,6 +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 });
|
|
@@ -1,74 +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
|
-
/**
|
|
8
|
-
* @hidden
|
|
9
|
-
*/
|
|
10
|
-
var update = function (arr, idx, value) { return (arr.slice(0, idx + 1).concat((arr.slice(idx + 1).map(function (x) { return x + value; })))); };
|
|
11
|
-
var ɵ0 = update;
|
|
12
|
-
exports.ɵ0 = ɵ0;
|
|
13
|
-
/**
|
|
14
|
-
* @hidden
|
|
15
|
-
*/
|
|
16
|
-
var RowHeightService = /** @class */ (function () {
|
|
17
|
-
function RowHeightService(total, rowHeight, detailRowHeight) {
|
|
18
|
-
if (total === void 0) { total = 0; }
|
|
19
|
-
this.total = total;
|
|
20
|
-
this.rowHeight = rowHeight;
|
|
21
|
-
this.detailRowHeight = detailRowHeight;
|
|
22
|
-
this.offsets = [];
|
|
23
|
-
this.heights = [];
|
|
24
|
-
var agg = 0;
|
|
25
|
-
for (var idx = 0; idx < total; idx++) {
|
|
26
|
-
this.offsets.push(agg);
|
|
27
|
-
agg += rowHeight;
|
|
28
|
-
this.heights.push(rowHeight);
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
RowHeightService.prototype.height = function (rowIndex) {
|
|
32
|
-
return this.heights[rowIndex];
|
|
33
|
-
};
|
|
34
|
-
RowHeightService.prototype.expandDetail = function (rowIndex) {
|
|
35
|
-
if (this.height(rowIndex) === this.rowHeight) {
|
|
36
|
-
this.updateRowHeight(rowIndex, this.detailRowHeight);
|
|
37
|
-
}
|
|
38
|
-
};
|
|
39
|
-
RowHeightService.prototype.collapseDetail = function (rowIndex) {
|
|
40
|
-
if (this.height(rowIndex) > this.rowHeight) {
|
|
41
|
-
this.updateRowHeight(rowIndex, this.detailRowHeight * -1);
|
|
42
|
-
}
|
|
43
|
-
};
|
|
44
|
-
RowHeightService.prototype.index = function (position) {
|
|
45
|
-
if (position < 0) {
|
|
46
|
-
return undefined;
|
|
47
|
-
}
|
|
48
|
-
var result = this.offsets.reduce(function (prev, current, idx) {
|
|
49
|
-
if (prev !== undefined) {
|
|
50
|
-
return prev;
|
|
51
|
-
}
|
|
52
|
-
else if (current === position) {
|
|
53
|
-
return idx;
|
|
54
|
-
}
|
|
55
|
-
else if (current > position) {
|
|
56
|
-
return idx - 1;
|
|
57
|
-
}
|
|
58
|
-
return undefined;
|
|
59
|
-
}, undefined); // tslint:disable-line:align
|
|
60
|
-
return result === undefined ? this.total - 1 : result;
|
|
61
|
-
};
|
|
62
|
-
RowHeightService.prototype.offset = function (rowIndex) {
|
|
63
|
-
return this.offsets[rowIndex];
|
|
64
|
-
};
|
|
65
|
-
RowHeightService.prototype.totalHeight = function () {
|
|
66
|
-
return this.heights.reduce(function (prev, curr) { return prev + curr; }, 0);
|
|
67
|
-
};
|
|
68
|
-
RowHeightService.prototype.updateRowHeight = function (rowIndex, value) {
|
|
69
|
-
this.heights[rowIndex] += value;
|
|
70
|
-
this.offsets = update(this.offsets, rowIndex, value);
|
|
71
|
-
};
|
|
72
|
-
return RowHeightService;
|
|
73
|
-
}());
|
|
74
|
-
exports.RowHeightService = RowHeightService;
|