@siemens/element-ng 48.10.0 → 49.0.0-rc.2
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/about/package.json +2 -1
- package/accordion/package.json +2 -1
- package/action-modal/package.json +2 -1
- package/ag-grid/package.json +2 -1
- package/application-header/package.json +2 -1
- package/auto-collapsable-list/package.json +2 -1
- package/autocomplete/package.json +2 -1
- package/avatar/package.json +2 -1
- package/badge/package.json +2 -1
- package/breadcrumb/package.json +2 -1
- package/breadcrumb-router/package.json +2 -1
- package/card/package.json +2 -1
- package/chat-messages/package.json +2 -1
- package/circle-status/package.json +2 -1
- package/color-picker/package.json +2 -1
- package/column-selection-dialog/package.json +2 -1
- package/common/package.json +2 -1
- package/connection-strength/package.json +2 -1
- package/content-action-bar/package.json +2 -1
- package/copyright-notice/package.json +2 -1
- package/dashboard/package.json +2 -1
- package/datatable/package.json +2 -1
- package/date-range-filter/package.json +2 -1
- package/datepicker/package.json +2 -1
- package/electron-titlebar/package.json +2 -1
- package/empty-state/package.json +2 -1
- package/fesm2022/siemens-element-ng-about.mjs +25 -24
- package/fesm2022/siemens-element-ng-about.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-accordion.mjs +49 -75
- package/fesm2022/siemens-element-ng-accordion.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-action-modal.mjs +59 -55
- package/fesm2022/siemens-element-ng-action-modal.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-ag-grid.mjs +33 -37
- package/fesm2022/siemens-element-ng-ag-grid.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-application-header.mjs +122 -150
- package/fesm2022/siemens-element-ng-application-header.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-auto-collapsable-list.mjs +30 -32
- package/fesm2022/siemens-element-ng-auto-collapsable-list.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-autocomplete.mjs +34 -48
- package/fesm2022/siemens-element-ng-autocomplete.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-avatar.mjs +23 -24
- package/fesm2022/siemens-element-ng-avatar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-badge.mjs +6 -6
- package/fesm2022/siemens-element-ng-badge.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-breadcrumb-router.mjs +16 -16
- package/fesm2022/siemens-element-ng-breadcrumb-router.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-breadcrumb.mjs +18 -17
- package/fesm2022/siemens-element-ng-breadcrumb.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-card.mjs +32 -34
- package/fesm2022/siemens-element-ng-card.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-chat-messages.mjs +204 -109
- package/fesm2022/siemens-element-ng-chat-messages.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-circle-status.mjs +26 -26
- package/fesm2022/siemens-element-ng-circle-status.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-color-picker.mjs +18 -17
- package/fesm2022/siemens-element-ng-color-picker.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-column-selection-dialog.mjs +36 -35
- package/fesm2022/siemens-element-ng-column-selection-dialog.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-common.mjs +13 -38
- package/fesm2022/siemens-element-ng-common.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-connection-strength.mjs +11 -11
- package/fesm2022/siemens-element-ng-connection-strength.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-content-action-bar.mjs +33 -30
- package/fesm2022/siemens-element-ng-content-action-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-copyright-notice.mjs +13 -13
- package/fesm2022/siemens-element-ng-copyright-notice.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-dashboard.mjs +161 -169
- package/fesm2022/siemens-element-ng-dashboard.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-datatable.mjs +9 -9
- package/fesm2022/siemens-element-ng-datatable.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-date-range-filter.mjs +128 -149
- package/fesm2022/siemens-element-ng-date-range-filter.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-datepicker.mjs +260 -271
- package/fesm2022/siemens-element-ng-datepicker.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-electron-titlebar.mjs +19 -18
- package/fesm2022/siemens-element-ng-electron-titlebar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-empty-state.mjs +11 -11
- package/fesm2022/siemens-element-ng-empty-state.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-file-uploader.mjs +66 -69
- package/fesm2022/siemens-element-ng-file-uploader.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-filter-bar.mjs +23 -23
- package/fesm2022/siemens-element-ng-filter-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-filtered-search.mjs +141 -159
- package/fesm2022/siemens-element-ng-filtered-search.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-footer.mjs +10 -10
- package/fesm2022/siemens-element-ng-footer.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-form.mjs +99 -85
- package/fesm2022/siemens-element-ng-form.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-formly.mjs +96 -94
- package/fesm2022/siemens-element-ng-formly.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-header-dropdown.mjs +33 -33
- package/fesm2022/siemens-element-ng-header-dropdown.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-help-button.mjs +7 -6
- package/fesm2022/siemens-element-ng-help-button.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-icon-status.mjs +4 -4
- package/fesm2022/siemens-element-ng-icon.mjs +53 -135
- package/fesm2022/siemens-element-ng-icon.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-info-page.mjs +11 -12
- package/fesm2022/siemens-element-ng-info-page.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-inline-notification.mjs +15 -16
- package/fesm2022/siemens-element-ng-inline-notification.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-ip-input.mjs +16 -16
- package/fesm2022/siemens-element-ng-ip-input.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-landing-page.mjs +71 -71
- package/fesm2022/siemens-element-ng-landing-page.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-language-switcher.mjs +13 -13
- package/fesm2022/siemens-element-ng-language-switcher.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-link.mjs +22 -23
- package/fesm2022/siemens-element-ng-link.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-list-details.mjs +68 -86
- package/fesm2022/siemens-element-ng-list-details.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-loading-spinner.mjs +38 -52
- package/fesm2022/siemens-element-ng-loading-spinner.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-localization.mjs +14 -11
- package/fesm2022/siemens-element-ng-localization.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-main-detail-container.mjs +30 -30
- package/fesm2022/siemens-element-ng-main-detail-container.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-markdown-renderer.mjs +5 -5
- package/fesm2022/siemens-element-ng-markdown-renderer.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-menu.mjs +55 -54
- package/fesm2022/siemens-element-ng-menu.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-modal.mjs +10 -13
- package/fesm2022/siemens-element-ng-modal.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-navbar-vertical.mjs +183 -298
- package/fesm2022/siemens-element-ng-navbar-vertical.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-navbar.mjs +43 -43
- package/fesm2022/siemens-element-ng-navbar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-notification-item.mjs +14 -13
- package/fesm2022/siemens-element-ng-notification-item.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-number-input.mjs +32 -32
- package/fesm2022/siemens-element-ng-number-input.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-pagination.mjs +21 -20
- package/fesm2022/siemens-element-ng-pagination.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-password-strength.mjs +21 -21
- package/fesm2022/siemens-element-ng-password-strength.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-password-toggle.mjs +19 -15
- package/fesm2022/siemens-element-ng-password-toggle.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-phone-number.mjs +56 -50
- package/fesm2022/siemens-element-ng-phone-number.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-photo-upload.mjs +48 -47
- package/fesm2022/siemens-element-ng-photo-upload.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-pills-input.mjs +45 -44
- package/fesm2022/siemens-element-ng-pills-input.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-popover-legacy.mjs +31 -31
- package/fesm2022/siemens-element-ng-popover-legacy.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-popover.mjs +29 -29
- package/fesm2022/siemens-element-ng-popover.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-progressbar.mjs +15 -15
- package/fesm2022/siemens-element-ng-progressbar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-resize-observer.mjs +25 -61
- package/fesm2022/siemens-element-ng-resize-observer.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-result-details-list.mjs +13 -12
- package/fesm2022/siemens-element-ng-result-details-list.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-search-bar.mjs +25 -24
- package/fesm2022/siemens-element-ng-search-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-select.mjs +204 -347
- package/fesm2022/siemens-element-ng-select.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-shadow-root.mjs +3 -3
- package/fesm2022/siemens-element-ng-shadow-root.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-side-panel.mjs +144 -69
- package/fesm2022/siemens-element-ng-side-panel.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-skip-links.mjs +13 -13
- package/fesm2022/siemens-element-ng-skip-links.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-slider.mjs +30 -29
- package/fesm2022/siemens-element-ng-slider.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-sort-bar.mjs +14 -13
- package/fesm2022/siemens-element-ng-sort-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-split.mjs +26 -28
- package/fesm2022/siemens-element-ng-split.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-status-bar.mjs +42 -43
- package/fesm2022/siemens-element-ng-status-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-status-counter.mjs +11 -12
- package/fesm2022/siemens-element-ng-status-counter.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-status-toggle.mjs +15 -16
- package/fesm2022/siemens-element-ng-status-toggle.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-summary-chip.mjs +16 -17
- package/fesm2022/siemens-element-ng-summary-chip.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-summary-widget.mjs +16 -16
- package/fesm2022/siemens-element-ng-summary-widget.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-system-banner.mjs +7 -7
- package/fesm2022/siemens-element-ng-system-banner.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tabs-legacy.mjs +16 -16
- package/fesm2022/siemens-element-ng-tabs-legacy.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tabs.mjs +44 -47
- package/fesm2022/siemens-element-ng-tabs.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-theme.mjs +4 -4
- package/fesm2022/siemens-element-ng-theme.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-threshold.mjs +51 -71
- package/fesm2022/siemens-element-ng-threshold.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-toast-notification.mjs +26 -52
- package/fesm2022/siemens-element-ng-toast-notification.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tooltip.mjs +60 -68
- package/fesm2022/siemens-element-ng-tooltip.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tour.mjs +20 -20
- package/fesm2022/siemens-element-ng-tour.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-translate.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tree-view.mjs +92 -117
- package/fesm2022/siemens-element-ng-tree-view.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-typeahead.mjs +46 -62
- package/fesm2022/siemens-element-ng-typeahead.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-wizard.mjs +49 -48
- package/fesm2022/siemens-element-ng-wizard.mjs.map +1 -1
- package/file-uploader/package.json +2 -1
- package/filter-bar/package.json +2 -1
- package/filtered-search/package.json +2 -1
- package/footer/package.json +2 -1
- package/form/package.json +2 -1
- package/formly/package.json +2 -1
- package/header-dropdown/package.json +2 -1
- package/help-button/package.json +2 -1
- package/icon/package.json +2 -1
- package/icon-status/package.json +2 -1
- package/info-page/package.json +2 -1
- package/inline-notification/package.json +2 -1
- package/ip-input/package.json +2 -1
- package/landing-page/package.json +2 -1
- package/language-switcher/package.json +2 -1
- package/link/package.json +2 -1
- package/list-details/package.json +2 -1
- package/loading-spinner/package.json +2 -1
- package/localization/package.json +2 -1
- package/main-detail-container/package.json +2 -1
- package/markdown-renderer/package.json +2 -1
- package/menu/package.json +2 -1
- package/modal/package.json +2 -1
- package/navbar/package.json +2 -1
- package/navbar-vertical/package.json +2 -1
- package/notification-item/package.json +2 -1
- package/number-input/package.json +2 -1
- package/package.json +115 -107
- package/pagination/package.json +2 -1
- package/password-strength/package.json +2 -1
- package/password-toggle/package.json +2 -1
- package/phone-number/package.json +2 -1
- package/photo-upload/package.json +2 -1
- package/pills-input/package.json +2 -1
- package/popover/package.json +2 -1
- package/popover-legacy/package.json +2 -1
- package/progressbar/package.json +2 -1
- package/resize-observer/package.json +2 -1
- package/result-details-list/package.json +2 -1
- package/schematics/collection.json +0 -12
- package/schematics/migration.json +15 -0
- package/schematics/migrations/data/attribute-selectors.js +1 -6
- package/schematics/migrations/data/component-names.js +9 -68
- package/schematics/migrations/data/element-selectors.js +9 -8
- package/schematics/migrations/data/index.js +0 -1
- package/schematics/migrations/data/migration-test-data.js +167 -0
- package/schematics/migrations/data/output-names.js +1 -7
- package/schematics/migrations/data/symbol-removals.js +4 -45
- package/schematics/migrations/element-migration/element-migration.js +1 -3
- package/schematics/migrations/index.js +15 -5
- package/schematics/migrations/ngx-translate/index.js +93 -0
- package/schematics/ng-update/index.js +17 -0
- package/schematics/ng-update/schema.json +15 -0
- package/schematics/simpl-siemens-migration/index.js +1 -5
- package/schematics/utils/ts-utils.js +135 -0
- package/search-bar/package.json +2 -1
- package/select/package.json +2 -1
- package/shadow-root/package.json +2 -1
- package/side-panel/package.json +2 -1
- package/skip-links/package.json +2 -1
- package/slider/package.json +2 -1
- package/sort-bar/package.json +2 -1
- package/split/package.json +2 -1
- package/status-bar/package.json +2 -1
- package/status-counter/package.json +2 -1
- package/status-toggle/package.json +2 -1
- package/summary-chip/package.json +2 -1
- package/summary-widget/package.json +2 -1
- package/system-banner/package.json +2 -1
- package/tabs/package.json +2 -1
- package/tabs-legacy/package.json +2 -1
- package/template-i18n.json +32 -25
- package/test-styles.scss +5 -0
- package/theme/package.json +2 -1
- package/threshold/package.json +2 -1
- package/toast-notification/package.json +2 -1
- package/tooltip/package.json +2 -1
- package/tour/package.json +2 -1
- package/translate/package.json +2 -1
- package/tree-view/package.json +2 -1
- package/typeahead/package.json +2 -1
- package/{accordion/index.d.ts → types/siemens-element-ng-accordion.d.ts} +2 -3
- package/{application-header/index.d.ts → types/siemens-element-ng-application-header.d.ts} +19 -18
- package/{autocomplete/index.d.ts → types/siemens-element-ng-autocomplete.d.ts} +1 -3
- package/{breadcrumb/index.d.ts → types/siemens-element-ng-breadcrumb.d.ts} +2 -2
- package/{chat-messages/index.d.ts → types/siemens-element-ng-chat-messages.d.ts} +72 -10
- package/{common/index.d.ts → types/siemens-element-ng-common.d.ts} +2 -30
- package/{content-action-bar/index.d.ts → types/siemens-element-ng-content-action-bar.d.ts} +2 -2
- package/{dashboard/index.d.ts → types/siemens-element-ng-dashboard.d.ts} +6 -6
- package/{date-range-filter/index.d.ts → types/siemens-element-ng-date-range-filter.d.ts} +28 -27
- package/{datepicker/index.d.ts → types/siemens-element-ng-datepicker.d.ts} +5 -6
- package/{electron-titlebar/index.d.ts → types/siemens-element-ng-electron-titlebar.d.ts} +4 -4
- package/{file-uploader/index.d.ts → types/siemens-element-ng-file-uploader.d.ts} +26 -26
- package/{filter-bar/index.d.ts → types/siemens-element-ng-filter-bar.d.ts} +4 -4
- package/{filtered-search/index.d.ts → types/siemens-element-ng-filtered-search.d.ts} +6 -21
- package/{form/index.d.ts → types/siemens-element-ng-form.d.ts} +4 -6
- package/{formly/index.d.ts → types/siemens-element-ng-formly.d.ts} +1 -1
- package/types/siemens-element-ng-icon.d.ts +203 -0
- package/{landing-page/index.d.ts → types/siemens-element-ng-landing-page.d.ts} +15 -15
- package/{language-switcher/index.d.ts → types/siemens-element-ng-language-switcher.d.ts} +1 -2
- package/{list-details/index.d.ts → types/siemens-element-ng-list-details.d.ts} +4 -11
- package/{loading-spinner/index.d.ts → types/siemens-element-ng-loading-spinner.d.ts} +2 -3
- package/{modal/index.d.ts → types/siemens-element-ng-modal.d.ts} +0 -6
- package/{navbar-vertical/index.d.ts → types/siemens-element-ng-navbar-vertical.d.ts} +12 -7
- package/{navbar/index.d.ts → types/siemens-element-ng-navbar.d.ts} +11 -11
- package/{notification-item/index.d.ts → types/siemens-element-ng-notification-item.d.ts} +15 -3
- package/{pagination/index.d.ts → types/siemens-element-ng-pagination.d.ts} +4 -4
- package/{password-toggle/index.d.ts → types/siemens-element-ng-password-toggle.d.ts} +6 -4
- package/{phone-number/index.d.ts → types/siemens-element-ng-phone-number.d.ts} +8 -11
- package/{pills-input/index.d.ts → types/siemens-element-ng-pills-input.d.ts} +3 -3
- package/{popover/index.d.ts → types/siemens-element-ng-popover.d.ts} +2 -2
- package/{resize-observer/index.d.ts → types/siemens-element-ng-resize-observer.d.ts} +0 -30
- package/{search-bar/index.d.ts → types/siemens-element-ng-search-bar.d.ts} +2 -2
- package/{select/index.d.ts → types/siemens-element-ng-select.d.ts} +18 -97
- package/{side-panel/index.d.ts → types/siemens-element-ng-side-panel.d.ts} +26 -5
- package/{slider/index.d.ts → types/siemens-element-ng-slider.d.ts} +4 -4
- package/{split/index.d.ts → types/siemens-element-ng-split.d.ts} +1 -3
- package/{status-bar/index.d.ts → types/siemens-element-ng-status-bar.d.ts} +6 -6
- package/{tabs-legacy/index.d.ts → types/siemens-element-ng-tabs-legacy.d.ts} +5 -0
- package/{threshold/index.d.ts → types/siemens-element-ng-threshold.d.ts} +7 -7
- package/{toast-notification/index.d.ts → types/siemens-element-ng-toast-notification.d.ts} +3 -4
- package/{tooltip/index.d.ts → types/siemens-element-ng-tooltip.d.ts} +3 -6
- package/{tour/index.d.ts → types/siemens-element-ng-tour.d.ts} +1 -10
- package/{translate/index.d.ts → types/siemens-element-ng-translate.d.ts} +8 -1
- package/{tree-view/index.d.ts → types/siemens-element-ng-tree-view.d.ts} +0 -1
- package/{typeahead/index.d.ts → types/siemens-element-ng-typeahead.d.ts} +0 -2
- package/{wizard/index.d.ts → types/siemens-element-ng-wizard.d.ts} +6 -6
- package/wizard/package.json +2 -1
- package/fesm2022/siemens-element-ng-unauthorized-page.mjs +0 -75
- package/fesm2022/siemens-element-ng-unauthorized-page.mjs.map +0 -1
- package/icon/index.d.ts +0 -285
- package/schematics/migrations/action-modal-migration/action-modal-migration.js +0 -162
- package/schematics/migrations/action-modal-migration/action-modal.mappings.js +0 -98
- package/schematics/migrations/action-modal-migration/index.js +0 -5
- package/schematics/migrations/wizard-migration/index.js +0 -80
- package/schematics/scss-import-to-siemens-migration/index.js +0 -101
- package/schematics/scss-import-to-siemens-migration/schema.json +0 -16
- package/schematics/scss-import-to-siemens-migration/style-mappings.js +0 -62
- package/schematics/ts-import-to-siemens-migration/index.js +0 -230
- package/schematics/ts-import-to-siemens-migration/mappings/charts-ng-mappings.js +0 -71
- package/schematics/ts-import-to-siemens-migration/mappings/dashboards-ng-mappings.js +0 -54
- package/schematics/ts-import-to-siemens-migration/mappings/element-ng-mappings.js +0 -705
- package/schematics/ts-import-to-siemens-migration/mappings/element-translate-ng-mappings.js +0 -21
- package/schematics/ts-import-to-siemens-migration/mappings/index.js +0 -10
- package/schematics/ts-import-to-siemens-migration/mappings/maps-ng-mappings.js +0 -47
- package/schematics/ts-import-to-siemens-migration/mappings/native-charts-ng-mappings.js +0 -33
- package/schematics/ts-import-to-siemens-migration/model.js +0 -4
- package/schematics/ts-import-to-siemens-migration/schema.json +0 -16
- package/unauthorized-page/index.d.ts +0 -44
- package/unauthorized-page/package.json +0 -3
- /package/{about/index.d.ts → types/siemens-element-ng-about.d.ts} +0 -0
- /package/{action-modal/index.d.ts → types/siemens-element-ng-action-modal.d.ts} +0 -0
- /package/{ag-grid/index.d.ts → types/siemens-element-ng-ag-grid.d.ts} +0 -0
- /package/{auto-collapsable-list/index.d.ts → types/siemens-element-ng-auto-collapsable-list.d.ts} +0 -0
- /package/{avatar/index.d.ts → types/siemens-element-ng-avatar.d.ts} +0 -0
- /package/{badge/index.d.ts → types/siemens-element-ng-badge.d.ts} +0 -0
- /package/{breadcrumb-router/index.d.ts → types/siemens-element-ng-breadcrumb-router.d.ts} +0 -0
- /package/{card/index.d.ts → types/siemens-element-ng-card.d.ts} +0 -0
- /package/{circle-status/index.d.ts → types/siemens-element-ng-circle-status.d.ts} +0 -0
- /package/{color-picker/index.d.ts → types/siemens-element-ng-color-picker.d.ts} +0 -0
- /package/{column-selection-dialog/index.d.ts → types/siemens-element-ng-column-selection-dialog.d.ts} +0 -0
- /package/{connection-strength/index.d.ts → types/siemens-element-ng-connection-strength.d.ts} +0 -0
- /package/{copyright-notice/index.d.ts → types/siemens-element-ng-copyright-notice.d.ts} +0 -0
- /package/{datatable/index.d.ts → types/siemens-element-ng-datatable.d.ts} +0 -0
- /package/{empty-state/index.d.ts → types/siemens-element-ng-empty-state.d.ts} +0 -0
- /package/{footer/index.d.ts → types/siemens-element-ng-footer.d.ts} +0 -0
- /package/{header-dropdown/index.d.ts → types/siemens-element-ng-header-dropdown.d.ts} +0 -0
- /package/{help-button/index.d.ts → types/siemens-element-ng-help-button.d.ts} +0 -0
- /package/{icon-status/index.d.ts → types/siemens-element-ng-icon-status.d.ts} +0 -0
- /package/{info-page/index.d.ts → types/siemens-element-ng-info-page.d.ts} +0 -0
- /package/{inline-notification/index.d.ts → types/siemens-element-ng-inline-notification.d.ts} +0 -0
- /package/{ip-input/index.d.ts → types/siemens-element-ng-ip-input.d.ts} +0 -0
- /package/{link/index.d.ts → types/siemens-element-ng-link.d.ts} +0 -0
- /package/{localization/index.d.ts → types/siemens-element-ng-localization.d.ts} +0 -0
- /package/{main-detail-container/index.d.ts → types/siemens-element-ng-main-detail-container.d.ts} +0 -0
- /package/{markdown-renderer/index.d.ts → types/siemens-element-ng-markdown-renderer.d.ts} +0 -0
- /package/{menu/index.d.ts → types/siemens-element-ng-menu.d.ts} +0 -0
- /package/{number-input/index.d.ts → types/siemens-element-ng-number-input.d.ts} +0 -0
- /package/{password-strength/index.d.ts → types/siemens-element-ng-password-strength.d.ts} +0 -0
- /package/{photo-upload/index.d.ts → types/siemens-element-ng-photo-upload.d.ts} +0 -0
- /package/{popover-legacy/index.d.ts → types/siemens-element-ng-popover-legacy.d.ts} +0 -0
- /package/{progressbar/index.d.ts → types/siemens-element-ng-progressbar.d.ts} +0 -0
- /package/{result-details-list/index.d.ts → types/siemens-element-ng-result-details-list.d.ts} +0 -0
- /package/{shadow-root/index.d.ts → types/siemens-element-ng-shadow-root.d.ts} +0 -0
- /package/{skip-links/index.d.ts → types/siemens-element-ng-skip-links.d.ts} +0 -0
- /package/{sort-bar/index.d.ts → types/siemens-element-ng-sort-bar.d.ts} +0 -0
- /package/{status-counter/index.d.ts → types/siemens-element-ng-status-counter.d.ts} +0 -0
- /package/{status-toggle/index.d.ts → types/siemens-element-ng-status-toggle.d.ts} +0 -0
- /package/{summary-chip/index.d.ts → types/siemens-element-ng-summary-chip.d.ts} +0 -0
- /package/{summary-widget/index.d.ts → types/siemens-element-ng-summary-widget.d.ts} +0 -0
- /package/{system-banner/index.d.ts → types/siemens-element-ng-system-banner.d.ts} +0 -0
- /package/{tabs/index.d.ts → types/siemens-element-ng-tabs.d.ts} +0 -0
- /package/{theme/index.d.ts → types/siemens-element-ng-theme.d.ts} +0 -0
- /package/{index.d.ts → types/siemens-element-ng.d.ts} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { getLocaleDayPeriods, FormStyle, TranslationWidth, getLocaleId, getLocaleDateTimeFormat, FormatWidth, getLocaleTimeFormat, getLocaleDateFormat, formatDate,
|
|
1
|
+
import { getLocaleDayPeriods, FormStyle, TranslationWidth, getLocaleId, getLocaleDateTimeFormat, FormatWidth, getLocaleTimeFormat, getLocaleDateFormat, formatDate, DatePipe, NgTemplateOutlet, getLocaleFirstDayOfWeek, WeekDay } from '@angular/common';
|
|
2
2
|
import * as i0 from '@angular/core';
|
|
3
3
|
import { input, model, output, booleanAttribute, computed, signal, inject, LOCALE_ID, HostListener, Directive, ElementRef, viewChildren, Component, ChangeDetectionStrategy, viewChild, HostAttributeToken, effect, ChangeDetectorRef, SimpleChange, DOCUMENT, DestroyRef, contentChild, NgModule } from '@angular/core';
|
|
4
4
|
import * as i2 from '@angular/forms';
|
|
@@ -15,7 +15,8 @@ import { takeUntil, skip, map, filter, tap } from 'rxjs/operators';
|
|
|
15
15
|
import * as i1 from '@angular/cdk/a11y';
|
|
16
16
|
import { A11yModule, FocusMonitor, ConfigurableFocusTrapFactory } from '@angular/cdk/a11y';
|
|
17
17
|
import { t, SiTranslatePipe } from '@siemens/element-translate-ng/translate';
|
|
18
|
-
import {
|
|
18
|
+
import { elementRight2, elementLeft2, elementCalendar } from '@siemens/element-icons';
|
|
19
|
+
import { addIcons, SiIconComponent } from '@siemens/element-ng/icon';
|
|
19
20
|
|
|
20
21
|
/**
|
|
21
22
|
* Copyright (c) Siemens 2016 - 2025
|
|
@@ -748,7 +749,7 @@ class SiDateInputDirective {
|
|
|
748
749
|
* `si-date-input-${SiDateInputDirective.idCounter++}`
|
|
749
750
|
* ```
|
|
750
751
|
*/
|
|
751
|
-
id = input(`si-date-input-${SiDateInputDirective.idCounter++}
|
|
752
|
+
id = input(`si-date-input-${SiDateInputDirective.idCounter++}`, ...(ngDevMode ? [{ debugName: "id" }] : []));
|
|
752
753
|
/**
|
|
753
754
|
* Configuration object for the datepicker.
|
|
754
755
|
*
|
|
@@ -757,7 +758,7 @@ class SiDateInputDirective {
|
|
|
757
758
|
* {}
|
|
758
759
|
* ```
|
|
759
760
|
*/
|
|
760
|
-
siDatepickerConfig = model({});
|
|
761
|
+
siDatepickerConfig = model({}, ...(ngDevMode ? [{ debugName: "siDatepickerConfig" }] : []));
|
|
761
762
|
/**
|
|
762
763
|
* Emits an event to notify about disabling the time from the datepicker.
|
|
763
764
|
* When time is disable, we construct a pure date object in UTC 00:00:00 time.
|
|
@@ -772,12 +773,12 @@ class SiDateInputDirective {
|
|
|
772
773
|
* @defaultValue false
|
|
773
774
|
*/
|
|
774
775
|
// eslint-disable-next-line @angular-eslint/no-input-rename
|
|
775
|
-
disabledInput = input(false, { alias: 'disabled' });
|
|
776
|
+
disabledInput = input(false, { ...(ngDevMode ? { debugName: "disabledInput" } : {}), alias: 'disabled' });
|
|
776
777
|
/**
|
|
777
778
|
* Whether the date range input is readonly.
|
|
778
779
|
* @defaultValue false
|
|
779
780
|
*/
|
|
780
|
-
readonly = input(false, { transform: booleanAttribute });
|
|
781
|
+
readonly = input(false, { ...(ngDevMode ? { debugName: "readonly" } : {}), transform: booleanAttribute });
|
|
781
782
|
/**
|
|
782
783
|
* This ID will be bound to the `aria-describedby` attribute of the date-input.
|
|
783
784
|
* Use this to reference the element containing the error message(s) for the date-input.
|
|
@@ -788,7 +789,7 @@ class SiDateInputDirective {
|
|
|
788
789
|
* `${this.id()}-errormessage`
|
|
789
790
|
* ```
|
|
790
791
|
*/
|
|
791
|
-
errormessageId = input(`${this.id()}-errormessage
|
|
792
|
+
errormessageId = input(`${this.id()}-errormessage`, ...(ngDevMode ? [{ debugName: "errormessageId" }] : []));
|
|
792
793
|
/** @internal */
|
|
793
794
|
validatorOnChange = () => { };
|
|
794
795
|
/**
|
|
@@ -805,11 +806,11 @@ class SiDateInputDirective {
|
|
|
805
806
|
*/
|
|
806
807
|
dateChange = output();
|
|
807
808
|
/** @internal */
|
|
808
|
-
disabled = computed(() => this.disabledInput() || this.disabledNgControl());
|
|
809
|
+
disabled = computed(() => this.disabledInput() || this.disabledNgControl(), ...(ngDevMode ? [{ debugName: "disabled" }] : []));
|
|
809
810
|
onTouched = () => { };
|
|
810
811
|
onModelChange = () => { };
|
|
811
|
-
dateString = signal('');
|
|
812
|
-
disabledNgControl = signal(false);
|
|
812
|
+
dateString = signal('', ...(ngDevMode ? [{ debugName: "dateString" }] : []));
|
|
813
|
+
disabledNgControl = signal(false, ...(ngDevMode ? [{ debugName: "disabledNgControl" }] : []));
|
|
813
814
|
locale = inject(LOCALE_ID).toString();
|
|
814
815
|
format = '';
|
|
815
816
|
ngOnChanges(changes) {
|
|
@@ -938,7 +939,13 @@ class SiDateInputDirective {
|
|
|
938
939
|
!isValid(controlValue) ||
|
|
939
940
|
(withTime ? controlValue >= min : compareDate(controlValue, min) >= 0)
|
|
940
941
|
? null
|
|
941
|
-
: {
|
|
942
|
+
: {
|
|
943
|
+
minDate: {
|
|
944
|
+
min,
|
|
945
|
+
actual: controlValue,
|
|
946
|
+
minString: formatDate(min, this.getFormat(), this.locale)
|
|
947
|
+
}
|
|
948
|
+
};
|
|
942
949
|
}
|
|
943
950
|
/** The form control validator for the min date. */
|
|
944
951
|
maxValidator() {
|
|
@@ -950,10 +957,16 @@ class SiDateInputDirective {
|
|
|
950
957
|
!isValid(controlValue) ||
|
|
951
958
|
(withTime ? controlValue <= max : compareDate(controlValue, max) <= 0)
|
|
952
959
|
? null
|
|
953
|
-
: {
|
|
960
|
+
: {
|
|
961
|
+
maxDate: {
|
|
962
|
+
max,
|
|
963
|
+
actual: controlValue,
|
|
964
|
+
maxString: formatDate(max, this.getFormat(), this.locale)
|
|
965
|
+
}
|
|
966
|
+
};
|
|
954
967
|
}
|
|
955
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
956
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
968
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDateInputDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
969
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.0.8", type: SiDateInputDirective, isStandalone: true, selector: "input[siDateInput]", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, siDatepickerConfig: { classPropertyName: "siDatepickerConfig", publicName: "siDatepickerConfig", isSignal: true, isRequired: false, transformFunction: null }, disabledInput: { classPropertyName: "disabledInput", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, errormessageId: { classPropertyName: "errormessageId", publicName: "errormessageId", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { siDatepickerConfig: "siDatepickerConfigChange", siDatepickerDisabledTime: "siDatepickerDisabledTime", stateChange: "stateChange", dateChange: "dateChange" }, host: { listeners: { "input": "onInput($event)", "blur": "onBlur($event)" }, properties: { "attr.id": "id()", "attr.disabled": "disabled() || null", "attr.readonly": "readonly() || null", "class.readonly": "readonly()", "attr.aria-describedby": "errormessageId()", "value": "dateString()" } }, providers: [
|
|
957
970
|
{
|
|
958
971
|
provide: NG_VALUE_ACCESSOR,
|
|
959
972
|
useExisting: SiDateInputDirective,
|
|
@@ -970,7 +983,7 @@ class SiDateInputDirective {
|
|
|
970
983
|
}
|
|
971
984
|
], exportAs: ["siDateInput"], usesOnChanges: true, ngImport: i0 });
|
|
972
985
|
}
|
|
973
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
986
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDateInputDirective, decorators: [{
|
|
974
987
|
type: Directive,
|
|
975
988
|
args: [{
|
|
976
989
|
selector: 'input[siDateInput]',
|
|
@@ -1000,7 +1013,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
|
|
|
1000
1013
|
},
|
|
1001
1014
|
exportAs: 'siDateInput'
|
|
1002
1015
|
}]
|
|
1003
|
-
}], propDecorators: { onInput: [{
|
|
1016
|
+
}], propDecorators: { id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], siDatepickerConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "siDatepickerConfig", required: false }] }, { type: i0.Output, args: ["siDatepickerConfigChange"] }], siDatepickerDisabledTime: [{ type: i0.Output, args: ["siDatepickerDisabledTime"] }], stateChange: [{ type: i0.Output, args: ["stateChange"] }], disabledInput: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], readonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], errormessageId: [{ type: i0.Input, args: [{ isSignal: true, alias: "errormessageId", required: false }] }], dateChange: [{ type: i0.Output, args: ["dateChange"] }], onInput: [{
|
|
1004
1017
|
type: HostListener,
|
|
1005
1018
|
args: ['input', ['$event']]
|
|
1006
1019
|
}], onBlur: [{
|
|
@@ -1013,14 +1026,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
|
|
|
1013
1026
|
* SPDX-License-Identifier: MIT
|
|
1014
1027
|
*/
|
|
1015
1028
|
class SiCalendarDateCellDirective {
|
|
1016
|
-
cell = input.required();
|
|
1017
|
-
compareAdapter = input.required();
|
|
1029
|
+
cell = input.required(...(ngDevMode ? [{ debugName: "cell" }] : []));
|
|
1030
|
+
compareAdapter = input.required(...(ngDevMode ? [{ debugName: "compareAdapter" }] : []));
|
|
1018
1031
|
/** @defaultValue inject(ElementRef) */
|
|
1019
1032
|
ref = inject(ElementRef);
|
|
1020
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1021
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
1033
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiCalendarDateCellDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1034
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.0.8", type: SiCalendarDateCellDirective, isStandalone: true, selector: "[siCalendarDateCell]", inputs: { cell: { classPropertyName: "cell", publicName: "cell", isSignal: true, isRequired: true, transformFunction: null }, compareAdapter: { classPropertyName: "compareAdapter", publicName: "compareAdapter", isSignal: true, isRequired: true, transformFunction: null } }, host: { properties: { "attr.aria-disabled": "cell().disabled", "class.disabled": "cell().disabled", "attr.aria-label": "cell().ariaLabel", "class.today": "this.cell().isToday", "attr.aria-current": "this.cell().isToday ? \"date\" : null" }, classAttribute: "si-calendar-date-cell" }, ngImport: i0 });
|
|
1022
1035
|
}
|
|
1023
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1036
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiCalendarDateCellDirective, decorators: [{
|
|
1024
1037
|
type: Directive,
|
|
1025
1038
|
args: [{
|
|
1026
1039
|
selector: '[siCalendarDateCell]',
|
|
@@ -1033,7 +1046,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
|
|
|
1033
1046
|
'[attr.aria-current]': 'this.cell().isToday ? "date" : null'
|
|
1034
1047
|
}
|
|
1035
1048
|
}]
|
|
1036
|
-
}] });
|
|
1049
|
+
}], propDecorators: { cell: [{ type: i0.Input, args: [{ isSignal: true, alias: "cell", required: true }] }], compareAdapter: [{ type: i0.Input, args: [{ isSignal: true, alias: "compareAdapter", required: true }] }] } });
|
|
1037
1050
|
|
|
1038
1051
|
/**
|
|
1039
1052
|
* Copyright (c) Siemens 2016 - 2025
|
|
@@ -1166,54 +1179,54 @@ class RangeSelectionStrategy extends SelectionStrategy {
|
|
|
1166
1179
|
}
|
|
1167
1180
|
class SiCalendarBodyComponent {
|
|
1168
1181
|
/** The active date, the cell which will receive the focus. */
|
|
1169
|
-
focusedDate = model.required();
|
|
1182
|
+
focusedDate = model.required(...(ngDevMode ? [{ debugName: "focusedDate" }] : []));
|
|
1170
1183
|
/** The date which shall be indicated as currently selected. */
|
|
1171
|
-
startDate = input();
|
|
1184
|
+
startDate = input(...(ngDevMode ? [undefined, { debugName: "startDate" }] : []));
|
|
1172
1185
|
/** Selected end value which is only considered with enableRangeSelection. */
|
|
1173
|
-
endDate = input();
|
|
1186
|
+
endDate = input(...(ngDevMode ? [undefined, { debugName: "endDate" }] : []));
|
|
1174
1187
|
/**
|
|
1175
1188
|
* The cells to display in the table.
|
|
1176
1189
|
*
|
|
1177
1190
|
* @defaultValue []
|
|
1178
1191
|
*/
|
|
1179
|
-
rows = input([]);
|
|
1192
|
+
rows = input([], ...(ngDevMode ? [{ debugName: "rows" }] : []));
|
|
1180
1193
|
/**
|
|
1181
1194
|
* Labels for each row, which can be used to display the week number.
|
|
1182
1195
|
* @defaultValue undefined
|
|
1183
1196
|
*/
|
|
1184
|
-
rowLabels = input(undefined);
|
|
1197
|
+
rowLabels = input(undefined, ...(ngDevMode ? [{ debugName: "rowLabels" }] : []));
|
|
1185
1198
|
/**
|
|
1186
1199
|
* Additional row label CSS class(es).
|
|
1187
1200
|
*
|
|
1188
1201
|
* @defaultValue []
|
|
1189
1202
|
*/
|
|
1190
|
-
rowLabelCssClasses = input([]);
|
|
1203
|
+
rowLabelCssClasses = input([], ...(ngDevMode ? [{ debugName: "rowLabelCssClasses" }] : []));
|
|
1191
1204
|
/**
|
|
1192
1205
|
* Choose the selection strategy between single or range selection.
|
|
1193
1206
|
* @defaultValue false
|
|
1194
1207
|
*/
|
|
1195
|
-
enableRangeSelection = input(false);
|
|
1208
|
+
enableRangeSelection = input(false, ...(ngDevMode ? [{ debugName: "enableRangeSelection" }] : []));
|
|
1196
1209
|
/**
|
|
1197
1210
|
* Indicate whether a range preview shall be displayed.
|
|
1198
1211
|
* It's necessary since to display a preview also datepicker has a valid endDate.
|
|
1199
1212
|
*
|
|
1200
1213
|
* @defaultValue true
|
|
1201
1214
|
*/
|
|
1202
|
-
previewRange = input(true, { transform: booleanAttribute });
|
|
1215
|
+
previewRange = input(true, { ...(ngDevMode ? { debugName: "previewRange" } : {}), transform: booleanAttribute });
|
|
1203
1216
|
/** The cell which which has the mouse hover. */
|
|
1204
|
-
activeHover = model();
|
|
1217
|
+
activeHover = model(...(ngDevMode ? [undefined, { debugName: "activeHover" }] : []));
|
|
1205
1218
|
/**
|
|
1206
1219
|
* Compare date functions which are necessary to compare a the dates according the current view.
|
|
1207
1220
|
*
|
|
1208
1221
|
* @defaultValue new DayCompareAdapter()
|
|
1209
1222
|
*/
|
|
1210
|
-
compareAdapter = input(new DayCompareAdapter());
|
|
1223
|
+
compareAdapter = input(new DayCompareAdapter(), ...(ngDevMode ? [{ debugName: "compareAdapter" }] : []));
|
|
1211
1224
|
/** Emits when a user select a cell via click, space or enter. */
|
|
1212
1225
|
selectedValueChange = output();
|
|
1213
|
-
calendarDateCells = viewChildren(SiCalendarDateCellDirective);
|
|
1226
|
+
calendarDateCells = viewChildren(SiCalendarDateCellDirective, ...(ngDevMode ? [{ debugName: "calendarDateCells" }] : []));
|
|
1214
1227
|
selection = computed(() => this.enableRangeSelection()
|
|
1215
1228
|
? new RangeSelectionStrategy(this.compareAdapter())
|
|
1216
|
-
: new SingleSelectionStrategy(this.compareAdapter()));
|
|
1229
|
+
: new SingleSelectionStrategy(this.compareAdapter()), ...(ngDevMode ? [{ debugName: "selection" }] : []));
|
|
1217
1230
|
/**
|
|
1218
1231
|
* Focus calendar cell which is marked as active cell.
|
|
1219
1232
|
*/
|
|
@@ -1247,67 +1260,42 @@ class SiCalendarBodyComponent {
|
|
|
1247
1260
|
this.focusedDate.set(cell.valueRaw);
|
|
1248
1261
|
}
|
|
1249
1262
|
}
|
|
1250
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1251
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
1263
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiCalendarBodyComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1264
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiCalendarBodyComponent, isStandalone: true, selector: "[si-calendar-body]", inputs: { focusedDate: { classPropertyName: "focusedDate", publicName: "focusedDate", isSignal: true, isRequired: true, transformFunction: null }, startDate: { classPropertyName: "startDate", publicName: "startDate", isSignal: true, isRequired: false, transformFunction: null }, endDate: { classPropertyName: "endDate", publicName: "endDate", isSignal: true, isRequired: false, transformFunction: null }, rows: { classPropertyName: "rows", publicName: "rows", isSignal: true, isRequired: false, transformFunction: null }, rowLabels: { classPropertyName: "rowLabels", publicName: "rowLabels", isSignal: true, isRequired: false, transformFunction: null }, rowLabelCssClasses: { classPropertyName: "rowLabelCssClasses", publicName: "rowLabelCssClasses", isSignal: true, isRequired: false, transformFunction: null }, enableRangeSelection: { classPropertyName: "enableRangeSelection", publicName: "enableRangeSelection", isSignal: true, isRequired: false, transformFunction: null }, previewRange: { classPropertyName: "previewRange", publicName: "previewRange", isSignal: true, isRequired: false, transformFunction: null }, activeHover: { classPropertyName: "activeHover", publicName: "activeHover", isSignal: true, isRequired: false, transformFunction: null }, compareAdapter: { classPropertyName: "compareAdapter", publicName: "compareAdapter", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { focusedDate: "focusedDateChange", activeHover: "activeHoverChange", selectedValueChange: "selectedValueChange" }, host: { classAttribute: "si-calendar-body" }, viewQueries: [{ propertyName: "calendarDateCells", predicate: SiCalendarDateCellDirective, descendants: true, isSignal: true }], exportAs: ["siCalendarBody"], ngImport: i0, template: "@for (row of rows(); track rowIndex; let rowIndex = $index) {\n <tr role=\"row\">\n <!-- Typically used for week numbers -->\n @if (rowLabels()) {\n <td [class]=\"`si-calendar-row-label ${rowLabelCssClasses()}`\" [attr.data-row]=\"rowIndex\">\n {{ rowLabels()?.at(rowIndex) ?? '' }}\n </td>\n }\n @for (col of row; track colIndex; let colIndex = $index) {\n <td\n role=\"gridcell\"\n class=\"si-calendar-cell\"\n [attr.data-row]=\"rowIndex\"\n [attr.data-col]=\"colIndex\"\n [class.range-hover]=\"\n previewRange() && selection().previewRangeHover(col, activeHover(), startDate())\n \"\n [class.range-hover-end]=\"\n previewRange() && selection().previewRangeHoverEnd(col, activeHover(), startDate())\n \"\n [class.range]=\"selection().inRange(col, startDate(), endDate())\"\n [class.range-start]=\"selection().isRangeSelected(col, startDate())\"\n [class.range-end]=\"selection().isRangeSelected(col, endDate())\"\n >\n <button\n siCalendarDateCell\n type=\"button\"\n [cell]=\"col\"\n [compareAdapter]=\"compareAdapter()\"\n [attr.cdkFocusInitial]=\"isActive(col) ? '' : null\"\n [class]=\"cellCss(col)\"\n [class.selected]=\"selection().isSelected(col, startDate(), endDate())\"\n [class.text-secondary]=\"\n col.isPreview &&\n !col.disabled &&\n !selection().isRangeSelected(col, startDate()) &&\n !selection().isRangeSelected(col, endDate()) &&\n !selection().inRange(col, startDate(), endDate())\n \"\n [tabindex]=\"isActive(col) ? '0' : '-1'\"\n (mouseover)=\"emitActiveHover(col)\"\n (click)=\"emitSelectCell(col)\"\n (focus)=\"emitActiveDateChange(col)\"\n >\n {{ col.displayValue }}\n </button>\n </td>\n }\n </tr>\n}\n", dependencies: [{ kind: "ngmodule", type: A11yModule }, { kind: "directive", type: SiCalendarDateCellDirective, selector: "[siCalendarDateCell]", inputs: ["cell", "compareAdapter"] }] });
|
|
1252
1265
|
}
|
|
1253
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1266
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiCalendarBodyComponent, decorators: [{
|
|
1254
1267
|
type: Component,
|
|
1255
|
-
args: [{ selector: '[si-calendar-body]', imports: [
|
|
1268
|
+
args: [{ selector: '[si-calendar-body]', imports: [A11yModule, SiCalendarDateCellDirective], host: {
|
|
1256
1269
|
class: 'si-calendar-body'
|
|
1257
|
-
}, exportAs: 'siCalendarBody', template: "@for (row of rows(); track rowIndex; let rowIndex = $index) {\n <tr role=\"row\">\n <!-- Typically used for week numbers -->\n @if (rowLabels()) {\n <td class=\"si-calendar-row-label
|
|
1258
|
-
}] });
|
|
1270
|
+
}, exportAs: 'siCalendarBody', template: "@for (row of rows(); track rowIndex; let rowIndex = $index) {\n <tr role=\"row\">\n <!-- Typically used for week numbers -->\n @if (rowLabels()) {\n <td [class]=\"`si-calendar-row-label ${rowLabelCssClasses()}`\" [attr.data-row]=\"rowIndex\">\n {{ rowLabels()?.at(rowIndex) ?? '' }}\n </td>\n }\n @for (col of row; track colIndex; let colIndex = $index) {\n <td\n role=\"gridcell\"\n class=\"si-calendar-cell\"\n [attr.data-row]=\"rowIndex\"\n [attr.data-col]=\"colIndex\"\n [class.range-hover]=\"\n previewRange() && selection().previewRangeHover(col, activeHover(), startDate())\n \"\n [class.range-hover-end]=\"\n previewRange() && selection().previewRangeHoverEnd(col, activeHover(), startDate())\n \"\n [class.range]=\"selection().inRange(col, startDate(), endDate())\"\n [class.range-start]=\"selection().isRangeSelected(col, startDate())\"\n [class.range-end]=\"selection().isRangeSelected(col, endDate())\"\n >\n <button\n siCalendarDateCell\n type=\"button\"\n [cell]=\"col\"\n [compareAdapter]=\"compareAdapter()\"\n [attr.cdkFocusInitial]=\"isActive(col) ? '' : null\"\n [class]=\"cellCss(col)\"\n [class.selected]=\"selection().isSelected(col, startDate(), endDate())\"\n [class.text-secondary]=\"\n col.isPreview &&\n !col.disabled &&\n !selection().isRangeSelected(col, startDate()) &&\n !selection().isRangeSelected(col, endDate()) &&\n !selection().inRange(col, startDate(), endDate())\n \"\n [tabindex]=\"isActive(col) ? '0' : '-1'\"\n (mouseover)=\"emitActiveHover(col)\"\n (click)=\"emitSelectCell(col)\"\n (focus)=\"emitActiveDateChange(col)\"\n >\n {{ col.displayValue }}\n </button>\n </td>\n }\n </tr>\n}\n" }]
|
|
1271
|
+
}], propDecorators: { focusedDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "focusedDate", required: true }] }, { type: i0.Output, args: ["focusedDateChange"] }], startDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "startDate", required: false }] }], endDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "endDate", required: false }] }], rows: [{ type: i0.Input, args: [{ isSignal: true, alias: "rows", required: false }] }], rowLabels: [{ type: i0.Input, args: [{ isSignal: true, alias: "rowLabels", required: false }] }], rowLabelCssClasses: [{ type: i0.Input, args: [{ isSignal: true, alias: "rowLabelCssClasses", required: false }] }], enableRangeSelection: [{ type: i0.Input, args: [{ isSignal: true, alias: "enableRangeSelection", required: false }] }], previewRange: [{ type: i0.Input, args: [{ isSignal: true, alias: "previewRange", required: false }] }], activeHover: [{ type: i0.Input, args: [{ isSignal: true, alias: "activeHover", required: false }] }, { type: i0.Output, args: ["activeHoverChange"] }], compareAdapter: [{ type: i0.Input, args: [{ isSignal: true, alias: "compareAdapter", required: false }] }], selectedValueChange: [{ type: i0.Output, args: ["selectedValueChange"] }], calendarDateCells: [{ type: i0.ViewChildren, args: [i0.forwardRef(() => SiCalendarDateCellDirective), { isSignal: true }] }] } });
|
|
1259
1272
|
|
|
1260
1273
|
/**
|
|
1261
1274
|
* Copyright (c) Siemens 2016 - 2025
|
|
1262
1275
|
* SPDX-License-Identifier: MIT
|
|
1263
1276
|
*/
|
|
1264
1277
|
class SiCalendarDirectionButtonComponent {
|
|
1265
|
-
ariaLabel = input.required();
|
|
1278
|
+
ariaLabel = input.required(...(ngDevMode ? [{ debugName: "ariaLabel" }] : []));
|
|
1266
1279
|
/** @defaultValue false */
|
|
1267
|
-
disabled = input(false, { transform: booleanAttribute });
|
|
1268
|
-
direction = input();
|
|
1280
|
+
disabled = input(false, { ...(ngDevMode ? { debugName: "disabled" } : {}), transform: booleanAttribute });
|
|
1281
|
+
direction = input(...(ngDevMode ? [undefined, { debugName: "direction" }] : []));
|
|
1269
1282
|
/**
|
|
1270
1283
|
* Emit on button click.
|
|
1271
1284
|
*/
|
|
1272
1285
|
clicked = output();
|
|
1273
|
-
icon = computed(() => this.direction() === 'left' ? this.icons.elementLeft2 : this.icons.elementRight2);
|
|
1274
|
-
buttonClass = computed(() => this.direction() === 'left' ? 'previous-button' : 'next-button');
|
|
1286
|
+
icon = computed(() => this.direction() === 'left' ? this.icons.elementLeft2 : this.icons.elementRight2, ...(ngDevMode ? [{ debugName: "icon" }] : []));
|
|
1287
|
+
buttonClass = computed(() => this.direction() === 'left' ? 'previous-button' : 'next-button', ...(ngDevMode ? [{ debugName: "buttonClass" }] : []));
|
|
1275
1288
|
icons = addIcons({ elementLeft2, elementRight2 });
|
|
1276
1289
|
onClick() {
|
|
1277
1290
|
this.clicked.emit();
|
|
1278
1291
|
}
|
|
1279
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1280
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "
|
|
1281
|
-
role="button"
|
|
1282
|
-
type="button"
|
|
1283
|
-
class="btn btn-circle btn-sm btn-tertiary"
|
|
1284
|
-
[ngClass]="buttonClass()"
|
|
1285
|
-
[disabled]="disabled() || null"
|
|
1286
|
-
[attr.aria-label]="ariaLabel()"
|
|
1287
|
-
(click)="onClick()"
|
|
1288
|
-
>
|
|
1289
|
-
<si-icon class="icon flip-rtl" [icon]="icon()" />
|
|
1290
|
-
</button>`, isInline: true, dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1292
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiCalendarDirectionButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1293
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.0.8", type: SiCalendarDirectionButtonComponent, isStandalone: true, selector: "si-calendar-direction-button", inputs: { ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: true, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, direction: { classPropertyName: "direction", publicName: "direction", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { clicked: "clicked" }, ngImport: i0, template: "<button\n role=\"button\"\n type=\"button\"\n [class]=\"`btn btn-circle btn-tertiary ${buttonClass()}`\"\n [disabled]=\"disabled() || null\"\n [attr.aria-label]=\"ariaLabel()\"\n (click)=\"onClick()\"\n>\n <si-icon class=\"icon flip-rtl\" [icon]=\"icon()\" />\n</button>\n", dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1291
1294
|
}
|
|
1292
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1295
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiCalendarDirectionButtonComponent, decorators: [{
|
|
1293
1296
|
type: Component,
|
|
1294
|
-
args: [{
|
|
1295
|
-
|
|
1296
|
-
imports: [NgClass, SiIconComponent],
|
|
1297
|
-
template: `<button
|
|
1298
|
-
role="button"
|
|
1299
|
-
type="button"
|
|
1300
|
-
class="btn btn-circle btn-sm btn-tertiary"
|
|
1301
|
-
[ngClass]="buttonClass()"
|
|
1302
|
-
[disabled]="disabled() || null"
|
|
1303
|
-
[attr.aria-label]="ariaLabel()"
|
|
1304
|
-
(click)="onClick()"
|
|
1305
|
-
>
|
|
1306
|
-
<si-icon class="icon flip-rtl" [icon]="icon()" />
|
|
1307
|
-
</button>`,
|
|
1308
|
-
changeDetection: ChangeDetectionStrategy.OnPush
|
|
1309
|
-
}]
|
|
1310
|
-
}] });
|
|
1297
|
+
args: [{ selector: 'si-calendar-direction-button', imports: [SiIconComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<button\n role=\"button\"\n type=\"button\"\n [class]=\"`btn btn-circle btn-tertiary ${buttonClass()}`\"\n [disabled]=\"disabled() || null\"\n [attr.aria-label]=\"ariaLabel()\"\n (click)=\"onClick()\"\n>\n <si-icon class=\"icon flip-rtl\" [icon]=\"icon()\" />\n</button>\n" }]
|
|
1298
|
+
}], propDecorators: { ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: true }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], direction: [{ type: i0.Input, args: [{ isSignal: true, alias: "direction", required: false }] }], clicked: [{ type: i0.Output, args: ["clicked"] }] } });
|
|
1311
1299
|
|
|
1312
1300
|
/**
|
|
1313
1301
|
* Copyright (c) Siemens 2016 - 2025
|
|
@@ -1318,52 +1306,52 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
|
|
|
1318
1306
|
*/
|
|
1319
1307
|
class SiInitialFocusComponent {
|
|
1320
1308
|
/** The cell which has the mouse hover. */
|
|
1321
|
-
activeHover = model();
|
|
1309
|
+
activeHover = model(...(ngDevMode ? [undefined, { debugName: "activeHover" }] : []));
|
|
1322
1310
|
/** The date which is displayed as selected. */
|
|
1323
|
-
startDate = input();
|
|
1311
|
+
startDate = input(...(ngDevMode ? [undefined, { debugName: "startDate" }] : []));
|
|
1324
1312
|
/** The date which is displayed as selected end. The value is only considered with enableRangeSelection. */
|
|
1325
|
-
endDate = input();
|
|
1313
|
+
endDate = input(...(ngDevMode ? [undefined, { debugName: "endDate" }] : []));
|
|
1326
1314
|
/**
|
|
1327
1315
|
* Guard to set the focus during ngAfterViewInit, we just set the focus after we first initialized the view
|
|
1328
1316
|
*
|
|
1329
1317
|
* @defaultValue true
|
|
1330
1318
|
*/
|
|
1331
|
-
initialFocus = input(true);
|
|
1319
|
+
initialFocus = input(true, ...(ngDevMode ? [{ debugName: "initialFocus" }] : []));
|
|
1332
1320
|
/** The minimum selectable date. */
|
|
1333
|
-
minDate = input();
|
|
1321
|
+
minDate = input(...(ngDevMode ? [undefined, { debugName: "minDate" }] : []));
|
|
1334
1322
|
/** The maximum selectable date. */
|
|
1335
|
-
maxDate = input();
|
|
1323
|
+
maxDate = input(...(ngDevMode ? [undefined, { debugName: "maxDate" }] : []));
|
|
1336
1324
|
/**
|
|
1337
1325
|
* Optional input to control the minimum month the datepicker can show and the user can navigate.
|
|
1338
1326
|
* The `minMonth` can be larger than the `minDate` This option enables the usage of multiple
|
|
1339
1327
|
* datepickers next to each other while the more left calendar always
|
|
1340
1328
|
* shows an earlier month the more right one.
|
|
1341
1329
|
*/
|
|
1342
|
-
minMonth = input();
|
|
1330
|
+
minMonth = input(...(ngDevMode ? [undefined, { debugName: "minMonth" }] : []));
|
|
1343
1331
|
/**
|
|
1344
1332
|
* Optional input to control the maximum month the datepicker can show and the user can navigate.
|
|
1345
1333
|
* The `maxMonth` can be smaller than the `maxDate` This option enables the usage of multiple
|
|
1346
1334
|
* datepickers next to each other while the more left calendar always
|
|
1347
1335
|
* shows an earlier month the more right one.
|
|
1348
1336
|
*/
|
|
1349
|
-
maxMonth = input();
|
|
1337
|
+
maxMonth = input(...(ngDevMode ? [undefined, { debugName: "maxMonth" }] : []));
|
|
1350
1338
|
/** Aria label for the next button. Needed for a11y. */
|
|
1351
|
-
previousLabel = input.required();
|
|
1339
|
+
previousLabel = input.required(...(ngDevMode ? [{ debugName: "previousLabel" }] : []));
|
|
1352
1340
|
/** Aria label for the next button. Needed for a11y. */
|
|
1353
|
-
nextLabel = input.required();
|
|
1341
|
+
nextLabel = input.required(...(ngDevMode ? [{ debugName: "nextLabel" }] : []));
|
|
1354
1342
|
/**
|
|
1355
1343
|
* Is range selection enabled, when enabled it shows a preview between the startDate and the focused date.
|
|
1356
1344
|
*
|
|
1357
1345
|
* @defaultValue false
|
|
1358
1346
|
*/
|
|
1359
|
-
isRangeSelection = input(false, { transform: booleanAttribute });
|
|
1347
|
+
isRangeSelection = input(false, { ...(ngDevMode ? { debugName: "isRangeSelection" } : {}), transform: booleanAttribute });
|
|
1360
1348
|
/**
|
|
1361
1349
|
* Indicate whether a range preview shall be displayed.
|
|
1362
1350
|
* When enabled a preview is visible between startDate and focusedDate.
|
|
1363
1351
|
*
|
|
1364
1352
|
* @defaultValue true
|
|
1365
1353
|
*/
|
|
1366
|
-
previewRange = input(true, { transform: booleanAttribute });
|
|
1354
|
+
previewRange = input(true, { ...(ngDevMode ? { debugName: "previewRange" } : {}), transform: booleanAttribute });
|
|
1367
1355
|
/**
|
|
1368
1356
|
* Emits when a new value is selected. In case where the value is null to
|
|
1369
1357
|
* user aborted the selection by Escape.
|
|
@@ -1385,15 +1373,15 @@ class SiInitialFocusComponent {
|
|
|
1385
1373
|
onActiveHoverChange(event) {
|
|
1386
1374
|
this.activeHover.set(event);
|
|
1387
1375
|
}
|
|
1388
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1389
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "
|
|
1376
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiInitialFocusComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1377
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "21.0.8", type: SiInitialFocusComponent, isStandalone: true, selector: "ng-component", inputs: { activeHover: { classPropertyName: "activeHover", publicName: "activeHover", isSignal: true, isRequired: false, transformFunction: null }, startDate: { classPropertyName: "startDate", publicName: "startDate", isSignal: true, isRequired: false, transformFunction: null }, endDate: { classPropertyName: "endDate", publicName: "endDate", isSignal: true, isRequired: false, transformFunction: null }, initialFocus: { classPropertyName: "initialFocus", publicName: "initialFocus", isSignal: true, isRequired: false, transformFunction: null }, minDate: { classPropertyName: "minDate", publicName: "minDate", isSignal: true, isRequired: false, transformFunction: null }, maxDate: { classPropertyName: "maxDate", publicName: "maxDate", isSignal: true, isRequired: false, transformFunction: null }, minMonth: { classPropertyName: "minMonth", publicName: "minMonth", isSignal: true, isRequired: false, transformFunction: null }, maxMonth: { classPropertyName: "maxMonth", publicName: "maxMonth", isSignal: true, isRequired: false, transformFunction: null }, previousLabel: { classPropertyName: "previousLabel", publicName: "previousLabel", isSignal: true, isRequired: true, transformFunction: null }, nextLabel: { classPropertyName: "nextLabel", publicName: "nextLabel", isSignal: true, isRequired: true, transformFunction: null }, isRangeSelection: { classPropertyName: "isRangeSelection", publicName: "isRangeSelection", isSignal: true, isRequired: false, transformFunction: null }, previewRange: { classPropertyName: "previewRange", publicName: "previewRange", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { activeHover: "activeHoverChange", selectedValueChange: "selectedValueChange" }, viewQueries: [{ propertyName: "calendarBody", first: true, predicate: SiCalendarBodyComponent, descendants: true, isSignal: true }], ngImport: i0, template: '', isInline: true });
|
|
1390
1378
|
}
|
|
1391
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1379
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiInitialFocusComponent, decorators: [{
|
|
1392
1380
|
type: Component,
|
|
1393
1381
|
args: [{
|
|
1394
1382
|
template: ''
|
|
1395
1383
|
}]
|
|
1396
|
-
}] });
|
|
1384
|
+
}], propDecorators: { activeHover: [{ type: i0.Input, args: [{ isSignal: true, alias: "activeHover", required: false }] }, { type: i0.Output, args: ["activeHoverChange"] }], startDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "startDate", required: false }] }], endDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "endDate", required: false }] }], initialFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialFocus", required: false }] }], minDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "minDate", required: false }] }], maxDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxDate", required: false }] }], minMonth: [{ type: i0.Input, args: [{ isSignal: true, alias: "minMonth", required: false }] }], maxMonth: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxMonth", required: false }] }], previousLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "previousLabel", required: true }] }], nextLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "nextLabel", required: true }] }], isRangeSelection: [{ type: i0.Input, args: [{ isSignal: true, alias: "isRangeSelection", required: false }] }], previewRange: [{ type: i0.Input, args: [{ isSignal: true, alias: "previewRange", required: false }] }], selectedValueChange: [{ type: i0.Output, args: ["selectedValueChange"] }], calendarBody: [{ type: i0.ViewChild, args: [i0.forwardRef(() => SiCalendarBodyComponent), { isSignal: true }] }] } });
|
|
1397
1385
|
|
|
1398
1386
|
/**
|
|
1399
1387
|
* Copyright (c) Siemens 2016 - 2025
|
|
@@ -1410,31 +1398,31 @@ class SiDaySelectionComponent extends SiInitialFocusComponent {
|
|
|
1410
1398
|
*
|
|
1411
1399
|
* @defaultValue false
|
|
1412
1400
|
*/
|
|
1413
|
-
hideWeekNumbers = input(false, { transform: booleanAttribute });
|
|
1401
|
+
hideWeekNumbers = input(false, { ...(ngDevMode ? { debugName: "hideWeekNumbers" } : {}), transform: booleanAttribute });
|
|
1414
1402
|
/**
|
|
1415
1403
|
* Defines the starting day of the week. Default is `monday`.
|
|
1416
1404
|
*
|
|
1417
1405
|
* @defaultValue 'monday'
|
|
1418
1406
|
*/
|
|
1419
|
-
weekStartDay = input('monday');
|
|
1407
|
+
weekStartDay = input('monday', ...(ngDevMode ? [{ debugName: "weekStartDay" }] : []));
|
|
1420
1408
|
/**
|
|
1421
1409
|
* The active date, the cell which will receive the focus.
|
|
1422
1410
|
* @defaultValue calendarUtils.today()
|
|
1423
1411
|
*/
|
|
1424
|
-
focusedDate = model.required();
|
|
1412
|
+
focusedDate = model.required(...(ngDevMode ? [{ debugName: "focusedDate" }] : []));
|
|
1425
1413
|
/** Today button text */
|
|
1426
|
-
todayLabel = input();
|
|
1414
|
+
todayLabel = input(...(ngDevMode ? [undefined, { debugName: "todayLabel" }] : []));
|
|
1427
1415
|
/** Aria label for calendar week column */
|
|
1428
|
-
calendarWeekLabel = input();
|
|
1416
|
+
calendarWeekLabel = input(...(ngDevMode ? [undefined, { debugName: "calendarWeekLabel" }] : []));
|
|
1429
1417
|
/** Emits when the active focused date changed to another month / year, typically during keyboard navigation */
|
|
1430
1418
|
activeMonthChange = output();
|
|
1431
1419
|
/** Emits when the user requests a different to show a different view */
|
|
1432
1420
|
viewChange = output();
|
|
1433
|
-
today = computed(() => this.todayLabel() ?? this.todayDefaultText);
|
|
1421
|
+
today = computed(() => this.todayLabel() ?? this.todayDefaultText, ...(ngDevMode ? [{ debugName: "today" }] : []));
|
|
1434
1422
|
/** The translated list of week days. */
|
|
1435
|
-
days = computed(() => getDayStrings(this.locale, this.weekStartDay()));
|
|
1423
|
+
days = computed(() => getDayStrings(this.locale, this.weekStartDay()), ...(ngDevMode ? [{ debugName: "days" }] : []));
|
|
1436
1424
|
/** The week numbers which are shown as row label */
|
|
1437
|
-
weekNumbers = computed(() => this.weeks().map(w => getWeekOfYear(w[0].valueRaw, this.weekStartDay()).toString()));
|
|
1425
|
+
weekNumbers = computed(() => this.weeks().map(w => getWeekOfYear(w[0].valueRaw, this.weekStartDay()).toString()), ...(ngDevMode ? [{ debugName: "weekNumbers" }] : []));
|
|
1438
1426
|
/**
|
|
1439
1427
|
* The current visible list of calendar days.
|
|
1440
1428
|
* Every time the focusedDate changes to either another month or year the list will be rebuild.
|
|
@@ -1471,11 +1459,11 @@ class SiDaySelectionComponent extends SiInitialFocusComponent {
|
|
|
1471
1459
|
});
|
|
1472
1460
|
}
|
|
1473
1461
|
return weeks;
|
|
1474
|
-
});
|
|
1462
|
+
}, ...(ngDevMode ? [{ debugName: "weeks" }] : []));
|
|
1475
1463
|
/** Compare date based on the current view */
|
|
1476
1464
|
compareAdapter = new DayCompareAdapter();
|
|
1477
1465
|
/** Disable today button if it is the same month */
|
|
1478
|
-
isTodayButtonDisabled = computed(() => isSameMonth(today(), this.focusedDate()));
|
|
1466
|
+
isTodayButtonDisabled = computed(() => isSameMonth(today(), this.focusedDate()), ...(ngDevMode ? [{ debugName: "isTodayButtonDisabled" }] : []));
|
|
1479
1467
|
/**
|
|
1480
1468
|
* Indicate the previous button shall be disabled.
|
|
1481
1469
|
* This happens when the focusedDate is equal or before the minDate.
|
|
@@ -1484,7 +1472,7 @@ class SiDaySelectionComponent extends SiInitialFocusComponent {
|
|
|
1484
1472
|
const minDate = this.minDate();
|
|
1485
1473
|
const focusedDate = this.focusedDate();
|
|
1486
1474
|
return minDate && (isSameMonth(focusedDate, minDate) || isAfterMonth(minDate, focusedDate));
|
|
1487
|
-
});
|
|
1475
|
+
}, ...(ngDevMode ? [{ debugName: "isPreviousButtonDisabled" }] : []));
|
|
1488
1476
|
/**
|
|
1489
1477
|
* Indicate the next button shall be disabled.
|
|
1490
1478
|
* This happens when the focusedDate is equal or after the maxDate.
|
|
@@ -1493,7 +1481,7 @@ class SiDaySelectionComponent extends SiInitialFocusComponent {
|
|
|
1493
1481
|
const maxDate = this.maxDate();
|
|
1494
1482
|
const focusedDate = this.focusedDate();
|
|
1495
1483
|
return maxDate && (isSameMonth(focusedDate, maxDate) || isAfterMonth(focusedDate, maxDate));
|
|
1496
|
-
});
|
|
1484
|
+
}, ...(ngDevMode ? [{ debugName: "isNextButtonDisabled" }] : []));
|
|
1497
1485
|
locale = inject(LOCALE_ID).toString();
|
|
1498
1486
|
calendarBodyKeyDown(event) {
|
|
1499
1487
|
const isRtl = isRTL();
|
|
@@ -1573,13 +1561,13 @@ class SiDaySelectionComponent extends SiInitialFocusComponent {
|
|
|
1573
1561
|
emitViewChange(view) {
|
|
1574
1562
|
this.viewChange.emit(view);
|
|
1575
1563
|
}
|
|
1576
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1577
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
1564
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDaySelectionComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1565
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiDaySelectionComponent, isStandalone: true, selector: "si-day-selection", inputs: { hideWeekNumbers: { classPropertyName: "hideWeekNumbers", publicName: "hideWeekNumbers", isSignal: true, isRequired: false, transformFunction: null }, weekStartDay: { classPropertyName: "weekStartDay", publicName: "weekStartDay", isSignal: true, isRequired: false, transformFunction: null }, focusedDate: { classPropertyName: "focusedDate", publicName: "focusedDate", isSignal: true, isRequired: true, transformFunction: null }, todayLabel: { classPropertyName: "todayLabel", publicName: "todayLabel", isSignal: true, isRequired: false, transformFunction: null }, calendarWeekLabel: { classPropertyName: "calendarWeekLabel", publicName: "calendarWeekLabel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { focusedDate: "focusedDateChange", activeMonthChange: "activeMonthChange", viewChange: "viewChange" }, usesInheritance: true, ngImport: i0, template: "<div class=\"header\">\n <si-calendar-direction-button\n direction=\"left\"\n [ariaLabel]=\"previousLabel() | translate\"\n [disabled]=\"isPreviousButtonDisabled()\"\n (clicked)=\"setMonthOffset(-1)\"\n />\n <div class=\"flex-fill\">\n <button\n type=\"button\"\n class=\"open-month-view flex-fill text-end px-2 btn btn-tertiary calendar-button\"\n tabindex=\"0\"\n (click)=\"emitViewChange('month')\"\n >\n {{ focusedDate() | date: 'MMMM' }}\n </button>\n <button\n type=\"button\"\n class=\"open-year-view flex-fill text-start px-2 btn btn-tertiary calendar-button\"\n tabindex=\"0\"\n (click)=\"emitViewChange('year')\"\n >\n {{ focusedDate() | date: 'yyyy' }}\n </button>\n </div>\n <si-calendar-direction-button\n direction=\"right\"\n [ariaLabel]=\"nextLabel() | translate\"\n [disabled]=\"isNextButtonDisabled()\"\n (clicked)=\"setMonthOffset(1)\"\n />\n</div>\n<table class=\"px-9 mt-6\" role=\"grid\">\n <thead class=\"si-calendar-table-header\">\n <tr>\n @if (!hideWeekNumbers()) {\n <th scope=\"col\" class=\"week-num\">\n <span class=\"visually-hidden\">{{ calendarWeekLabel() | translate }}</span>\n </th>\n }\n @for (day of days(); track $index) {\n <th scope=\"col\">\n <span class=\"si-hidden-xs si-hidden-sm\">{{ day }}</span>\n </th>\n }\n </tr>\n </thead>\n <tbody\n si-calendar-body\n rowLabelCssClasses=\"week-num\"\n [focusedDate]=\"focusedDate()\"\n [compareAdapter]=\"compareAdapter\"\n [startDate]=\"startDate()\"\n [endDate]=\"endDate()\"\n [enableRangeSelection]=\"isRangeSelection()\"\n [previewRange]=\"previewRange()\"\n [rows]=\"weeks()\"\n [rowLabels]=\"hideWeekNumbers() ? undefined : weekNumbers()\"\n [activeHover]=\"activeHover()\"\n (activeHoverChange)=\"onActiveHoverChange($event)\"\n (selectedValueChange)=\"emitSelectedValue($event)\"\n (focusedDateChange)=\"emitActiveDate($event!)\"\n (keydown)=\"calendarBodyKeyDown($event)\"\n >\n </tbody>\n</table>\n<div class=\"footer pt-2 ps-8 pe-8\">\n <button\n type=\"button\"\n class=\"today-button btn btn-tertiary flex-fill\"\n [disabled]=\"isTodayButtonDisabled()\"\n (click)=\"goToToday()\"\n >\n {{ today() | translate }}\n </button>\n</div>\n", dependencies: [{ kind: "component", type: SiCalendarBodyComponent, selector: "[si-calendar-body]", inputs: ["focusedDate", "startDate", "endDate", "rows", "rowLabels", "rowLabelCssClasses", "enableRangeSelection", "previewRange", "activeHover", "compareAdapter"], outputs: ["focusedDateChange", "activeHoverChange", "selectedValueChange"], exportAs: ["siCalendarBody"] }, { kind: "component", type: SiCalendarDirectionButtonComponent, selector: "si-calendar-direction-button", inputs: ["ariaLabel", "disabled", "direction"], outputs: ["clicked"] }, { kind: "pipe", type: DatePipe, name: "date" }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1578
1566
|
}
|
|
1579
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1567
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDaySelectionComponent, decorators: [{
|
|
1580
1568
|
type: Component,
|
|
1581
1569
|
args: [{ selector: 'si-day-selection', imports: [DatePipe, SiCalendarBodyComponent, SiCalendarDirectionButtonComponent, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"header\">\n <si-calendar-direction-button\n direction=\"left\"\n [ariaLabel]=\"previousLabel() | translate\"\n [disabled]=\"isPreviousButtonDisabled()\"\n (clicked)=\"setMonthOffset(-1)\"\n />\n <div class=\"flex-fill\">\n <button\n type=\"button\"\n class=\"open-month-view flex-fill text-end px-2 btn btn-tertiary calendar-button\"\n tabindex=\"0\"\n (click)=\"emitViewChange('month')\"\n >\n {{ focusedDate() | date: 'MMMM' }}\n </button>\n <button\n type=\"button\"\n class=\"open-year-view flex-fill text-start px-2 btn btn-tertiary calendar-button\"\n tabindex=\"0\"\n (click)=\"emitViewChange('year')\"\n >\n {{ focusedDate() | date: 'yyyy' }}\n </button>\n </div>\n <si-calendar-direction-button\n direction=\"right\"\n [ariaLabel]=\"nextLabel() | translate\"\n [disabled]=\"isNextButtonDisabled()\"\n (clicked)=\"setMonthOffset(1)\"\n />\n</div>\n<table class=\"px-9 mt-6\" role=\"grid\">\n <thead class=\"si-calendar-table-header\">\n <tr>\n @if (!hideWeekNumbers()) {\n <th scope=\"col\" class=\"week-num\">\n <span class=\"visually-hidden\">{{ calendarWeekLabel() | translate }}</span>\n </th>\n }\n @for (day of days(); track $index) {\n <th scope=\"col\">\n <span class=\"si-hidden-xs si-hidden-sm\">{{ day }}</span>\n </th>\n }\n </tr>\n </thead>\n <tbody\n si-calendar-body\n rowLabelCssClasses=\"week-num\"\n [focusedDate]=\"focusedDate()\"\n [compareAdapter]=\"compareAdapter\"\n [startDate]=\"startDate()\"\n [endDate]=\"endDate()\"\n [enableRangeSelection]=\"isRangeSelection()\"\n [previewRange]=\"previewRange()\"\n [rows]=\"weeks()\"\n [rowLabels]=\"hideWeekNumbers() ? undefined : weekNumbers()\"\n [activeHover]=\"activeHover()\"\n (activeHoverChange)=\"onActiveHoverChange($event)\"\n (selectedValueChange)=\"emitSelectedValue($event)\"\n (focusedDateChange)=\"emitActiveDate($event!)\"\n (keydown)=\"calendarBodyKeyDown($event)\"\n >\n </tbody>\n</table>\n<div class=\"footer pt-2 ps-8 pe-8\">\n <button\n type=\"button\"\n class=\"today-button btn btn-tertiary flex-fill\"\n [disabled]=\"isTodayButtonDisabled()\"\n (click)=\"goToToday()\"\n >\n {{ today() | translate }}\n </button>\n</div>\n" }]
|
|
1582
|
-
}] });
|
|
1570
|
+
}], propDecorators: { hideWeekNumbers: [{ type: i0.Input, args: [{ isSignal: true, alias: "hideWeekNumbers", required: false }] }], weekStartDay: [{ type: i0.Input, args: [{ isSignal: true, alias: "weekStartDay", required: false }] }], focusedDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "focusedDate", required: true }] }, { type: i0.Output, args: ["focusedDateChange"] }], todayLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "todayLabel", required: false }] }], calendarWeekLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "calendarWeekLabel", required: false }] }], activeMonthChange: [{ type: i0.Output, args: ["activeMonthChange"] }], viewChange: [{ type: i0.Output, args: ["viewChange"] }] } });
|
|
1583
1571
|
|
|
1584
1572
|
/**
|
|
1585
1573
|
* Copyright (c) Siemens 2016 - 2025
|
|
@@ -1595,11 +1583,11 @@ class SiMonthSelectionComponent extends SiInitialFocusComponent {
|
|
|
1595
1583
|
*
|
|
1596
1584
|
* @defaultValue []
|
|
1597
1585
|
*/
|
|
1598
|
-
months = input([]);
|
|
1586
|
+
months = input([], ...(ngDevMode ? [{ debugName: "months" }] : []));
|
|
1599
1587
|
/**
|
|
1600
1588
|
* The active date, the cell which will receive the focus.
|
|
1601
1589
|
*/
|
|
1602
|
-
focusedDate = model.required();
|
|
1590
|
+
focusedDate = model.required(...(ngDevMode ? [{ debugName: "focusedDate" }] : []));
|
|
1603
1591
|
/** Emits when the active focused date is changed to another month / year, typically during keyboard navigation. */
|
|
1604
1592
|
activeMonthChange = output();
|
|
1605
1593
|
/** Emits when the user requests a different to show a different view. */
|
|
@@ -1626,7 +1614,7 @@ class SiMonthSelectionComponent extends SiInitialFocusComponent {
|
|
|
1626
1614
|
const minDate = this.minDate();
|
|
1627
1615
|
const focusedDate = this.focusedDate();
|
|
1628
1616
|
return minDate && (isSameYear(focusedDate, minDate) || isAfterYear(minDate, focusedDate));
|
|
1629
|
-
});
|
|
1617
|
+
}, ...(ngDevMode ? [{ debugName: "isPreviousButtonDisabled" }] : []));
|
|
1630
1618
|
/**
|
|
1631
1619
|
* Indicate the next button shall be disabled.
|
|
1632
1620
|
* This happens when the focusedDate is equal or after the maxDate.
|
|
@@ -1635,7 +1623,7 @@ class SiMonthSelectionComponent extends SiInitialFocusComponent {
|
|
|
1635
1623
|
const maxDate = this.maxDate();
|
|
1636
1624
|
const focusedDate = this.focusedDate();
|
|
1637
1625
|
return maxDate && (isSameYear(focusedDate, maxDate) || isAfterYear(focusedDate, maxDate));
|
|
1638
|
-
});
|
|
1626
|
+
}, ...(ngDevMode ? [{ debugName: "isNextButtonDisabled" }] : []));
|
|
1639
1627
|
ngOnChanges(changes) {
|
|
1640
1628
|
if (changes.maxDate ||
|
|
1641
1629
|
changes.minDate ||
|
|
@@ -1744,13 +1732,13 @@ class SiMonthSelectionComponent extends SiInitialFocusComponent {
|
|
|
1744
1732
|
}
|
|
1745
1733
|
this.monthCells.push(row);
|
|
1746
1734
|
}
|
|
1747
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1748
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "
|
|
1735
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiMonthSelectionComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1736
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.0.8", type: SiMonthSelectionComponent, isStandalone: true, selector: "si-month-selection", inputs: { months: { classPropertyName: "months", publicName: "months", isSignal: true, isRequired: false, transformFunction: null }, focusedDate: { classPropertyName: "focusedDate", publicName: "focusedDate", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { focusedDate: "focusedDateChange", activeMonthChange: "activeMonthChange", viewChange: "viewChange" }, host: { listeners: { "keydown.Escape": "triggerEsc($event)" } }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div class=\"header\">\n <si-calendar-direction-button\n direction=\"left\"\n [ariaLabel]=\"previousLabel()\"\n [disabled]=\"isPreviousButtonDisabled()\"\n (clicked)=\"setYearOffset(-1)\"\n />\n <button\n type=\"button\"\n class=\"open-year-view flex-fill mx-4 btn btn-tertiary calendar-button\"\n tabindex=\"0\"\n (click)=\"emitViewChange()\"\n >\n {{ focusedDate() | date: 'yyyy' }}\n </button>\n <si-calendar-direction-button\n direction=\"right\"\n [ariaLabel]=\"nextLabel()\"\n [disabled]=\"isNextButtonDisabled()\"\n (clicked)=\"setYearOffset(1)\"\n />\n</div>\n<table class=\"px-9 mt-6\" role=\"grid\">\n <tbody\n si-calendar-body\n [focusedDate]=\"focusedDate()\"\n [compareAdapter]=\"compareAdapter\"\n [startDate]=\"startDate()\"\n [endDate]=\"endDate()\"\n [enableRangeSelection]=\"isRangeSelection()\"\n [previewRange]=\"previewRange()\"\n [rows]=\"monthCells\"\n [activeHover]=\"activeHover()\"\n (activeHoverChange)=\"onActiveHoverChange($event)\"\n (selectedValueChange)=\"emitSelectedValue($event)\"\n (focusedDateChange)=\"emitFocusedDate($event)\"\n (keydown)=\"calendarBodyKeyDown($event)\"\n >\n </tbody>\n</table>\n", dependencies: [{ kind: "component", type: SiCalendarDirectionButtonComponent, selector: "si-calendar-direction-button", inputs: ["ariaLabel", "disabled", "direction"], outputs: ["clicked"] }, { kind: "component", type: SiCalendarBodyComponent, selector: "[si-calendar-body]", inputs: ["focusedDate", "startDate", "endDate", "rows", "rowLabels", "rowLabelCssClasses", "enableRangeSelection", "previewRange", "activeHover", "compareAdapter"], outputs: ["focusedDateChange", "activeHoverChange", "selectedValueChange"], exportAs: ["siCalendarBody"] }, { kind: "pipe", type: DatePipe, name: "date" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1749
1737
|
}
|
|
1750
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1738
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiMonthSelectionComponent, decorators: [{
|
|
1751
1739
|
type: Component,
|
|
1752
1740
|
args: [{ selector: 'si-month-selection', imports: [SiCalendarDirectionButtonComponent, SiCalendarBodyComponent, DatePipe], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"header\">\n <si-calendar-direction-button\n direction=\"left\"\n [ariaLabel]=\"previousLabel()\"\n [disabled]=\"isPreviousButtonDisabled()\"\n (clicked)=\"setYearOffset(-1)\"\n />\n <button\n type=\"button\"\n class=\"open-year-view flex-fill mx-4 btn btn-tertiary calendar-button\"\n tabindex=\"0\"\n (click)=\"emitViewChange()\"\n >\n {{ focusedDate() | date: 'yyyy' }}\n </button>\n <si-calendar-direction-button\n direction=\"right\"\n [ariaLabel]=\"nextLabel()\"\n [disabled]=\"isNextButtonDisabled()\"\n (clicked)=\"setYearOffset(1)\"\n />\n</div>\n<table class=\"px-9 mt-6\" role=\"grid\">\n <tbody\n si-calendar-body\n [focusedDate]=\"focusedDate()\"\n [compareAdapter]=\"compareAdapter\"\n [startDate]=\"startDate()\"\n [endDate]=\"endDate()\"\n [enableRangeSelection]=\"isRangeSelection()\"\n [previewRange]=\"previewRange()\"\n [rows]=\"monthCells\"\n [activeHover]=\"activeHover()\"\n (activeHoverChange)=\"onActiveHoverChange($event)\"\n (selectedValueChange)=\"emitSelectedValue($event)\"\n (focusedDateChange)=\"emitFocusedDate($event)\"\n (keydown)=\"calendarBodyKeyDown($event)\"\n >\n </tbody>\n</table>\n" }]
|
|
1753
|
-
}], propDecorators: { triggerEsc: [{
|
|
1741
|
+
}], propDecorators: { months: [{ type: i0.Input, args: [{ isSignal: true, alias: "months", required: false }] }], focusedDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "focusedDate", required: true }] }, { type: i0.Output, args: ["focusedDateChange"] }], activeMonthChange: [{ type: i0.Output, args: ["activeMonthChange"] }], viewChange: [{ type: i0.Output, args: ["viewChange"] }], triggerEsc: [{
|
|
1754
1742
|
type: HostListener,
|
|
1755
1743
|
args: ['keydown.Escape', ['$event']]
|
|
1756
1744
|
}] } });
|
|
@@ -1767,7 +1755,7 @@ class SiYearSelectionComponent extends SiInitialFocusComponent {
|
|
|
1767
1755
|
/**
|
|
1768
1756
|
* The active date, the cell which will receive the focus.
|
|
1769
1757
|
*/
|
|
1770
|
-
focusedDate = model.required();
|
|
1758
|
+
focusedDate = model.required(...(ngDevMode ? [{ debugName: "focusedDate" }] : []));
|
|
1771
1759
|
/** Emits when the active focused date changed to another month / year, typically during keyboard navigation. */
|
|
1772
1760
|
yearRangeChange = output();
|
|
1773
1761
|
/** Listen Escape event to switch view back */
|
|
@@ -1781,9 +1769,9 @@ class SiYearSelectionComponent extends SiInitialFocusComponent {
|
|
|
1781
1769
|
/** The number of years which shall be displayed, this number should be even and dividable by columnCount */
|
|
1782
1770
|
yearsToDisplay = 18;
|
|
1783
1771
|
/** Lower windows bound for displayed year range */
|
|
1784
|
-
fromYear = signal(undefined);
|
|
1772
|
+
fromYear = signal(undefined, ...(ngDevMode ? [{ debugName: "fromYear" }] : []));
|
|
1785
1773
|
/** Upper windows bound for displayed year range */
|
|
1786
|
-
toYear = signal(undefined);
|
|
1774
|
+
toYear = signal(undefined, ...(ngDevMode ? [{ debugName: "toYear" }] : []));
|
|
1787
1775
|
/**
|
|
1788
1776
|
* The current visible list of calendar years.
|
|
1789
1777
|
* Every time the focusedDate changes to another year the list will be rebuilt.
|
|
@@ -1800,7 +1788,7 @@ class SiYearSelectionComponent extends SiInitialFocusComponent {
|
|
|
1800
1788
|
const min = minDate(minDate$1, minMonth);
|
|
1801
1789
|
return (this.compareAdapter.isEqual(this.fromYear(), min) ||
|
|
1802
1790
|
this.compareAdapter.isAfter(min, this.fromYear()));
|
|
1803
|
-
});
|
|
1791
|
+
}, ...(ngDevMode ? [{ debugName: "isPreviousButtonDisabled" }] : []));
|
|
1804
1792
|
/** Is next button disabled based on the maxDate */
|
|
1805
1793
|
isNextButtonDisabled = computed(() => {
|
|
1806
1794
|
const maxDate = this.maxDate();
|
|
@@ -1809,7 +1797,7 @@ class SiYearSelectionComponent extends SiInitialFocusComponent {
|
|
|
1809
1797
|
}
|
|
1810
1798
|
return (this.compareAdapter.isEqual(this.toYear(), maxDate) ||
|
|
1811
1799
|
this.compareAdapter.isAfter(this.toYear(), maxDate));
|
|
1812
|
-
});
|
|
1800
|
+
}, ...(ngDevMode ? [{ debugName: "isNextButtonDisabled" }] : []));
|
|
1813
1801
|
ngOnChanges(changes) {
|
|
1814
1802
|
if (changes.startDate || changes.focusedDate || changes.maxDate || changes.minDate) {
|
|
1815
1803
|
this.initView();
|
|
@@ -1953,13 +1941,13 @@ class SiYearSelectionComponent extends SiInitialFocusComponent {
|
|
|
1953
1941
|
this.initView();
|
|
1954
1942
|
}
|
|
1955
1943
|
}
|
|
1956
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1957
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "
|
|
1944
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiYearSelectionComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1945
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.0.8", type: SiYearSelectionComponent, isStandalone: true, selector: "si-year-selection", inputs: { focusedDate: { classPropertyName: "focusedDate", publicName: "focusedDate", isSignal: true, isRequired: true, transformFunction: null } }, outputs: { focusedDate: "focusedDateChange", yearRangeChange: "yearRangeChange" }, host: { listeners: { "keydown.Escape": "triggerEsc($event)" } }, usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<div class=\"header\">\n <si-calendar-direction-button\n direction=\"left\"\n [ariaLabel]=\"previousLabel()\"\n [disabled]=\"isPreviousButtonDisabled()\"\n (clicked)=\"changeVisibleYearRange(-1)\"\n />\n <span class=\"year-range-label flex-fill mx-4 si-h4 text-secondary calendar-button\">\n {{ fromYear() | date: 'yyyy' }} - {{ toYear() | date: 'yyyy' }}\n </span>\n <si-calendar-direction-button\n direction=\"right\"\n [ariaLabel]=\"nextLabel()\"\n [disabled]=\"isNextButtonDisabled()\"\n (clicked)=\"changeVisibleYearRange(1)\"\n />\n</div>\n<table class=\"px-9 mt-6\" role=\"grid\">\n <tbody\n si-calendar-body\n [focusedDate]=\"focusedDate()\"\n [compareAdapter]=\"compareAdapter\"\n [startDate]=\"startDate()\"\n [endDate]=\"endDate()\"\n [enableRangeSelection]=\"isRangeSelection()\"\n [previewRange]=\"previewRange()\"\n [rows]=\"yearCells\"\n (selectedValueChange)=\"emitSelectedValue($event)\"\n (keydown)=\"calendarBodyKeyDown($event)\"\n >\n </tbody>\n</table>\n", dependencies: [{ kind: "component", type: SiCalendarDirectionButtonComponent, selector: "si-calendar-direction-button", inputs: ["ariaLabel", "disabled", "direction"], outputs: ["clicked"] }, { kind: "component", type: SiCalendarBodyComponent, selector: "[si-calendar-body]", inputs: ["focusedDate", "startDate", "endDate", "rows", "rowLabels", "rowLabelCssClasses", "enableRangeSelection", "previewRange", "activeHover", "compareAdapter"], outputs: ["focusedDateChange", "activeHoverChange", "selectedValueChange"], exportAs: ["siCalendarBody"] }, { kind: "pipe", type: DatePipe, name: "date" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1958
1946
|
}
|
|
1959
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1947
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiYearSelectionComponent, decorators: [{
|
|
1960
1948
|
type: Component,
|
|
1961
1949
|
args: [{ selector: 'si-year-selection', imports: [SiCalendarDirectionButtonComponent, SiCalendarBodyComponent, DatePipe], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"header\">\n <si-calendar-direction-button\n direction=\"left\"\n [ariaLabel]=\"previousLabel()\"\n [disabled]=\"isPreviousButtonDisabled()\"\n (clicked)=\"changeVisibleYearRange(-1)\"\n />\n <span class=\"year-range-label flex-fill mx-4 si-h4 text-secondary calendar-button\">\n {{ fromYear() | date: 'yyyy' }} - {{ toYear() | date: 'yyyy' }}\n </span>\n <si-calendar-direction-button\n direction=\"right\"\n [ariaLabel]=\"nextLabel()\"\n [disabled]=\"isNextButtonDisabled()\"\n (clicked)=\"changeVisibleYearRange(1)\"\n />\n</div>\n<table class=\"px-9 mt-6\" role=\"grid\">\n <tbody\n si-calendar-body\n [focusedDate]=\"focusedDate()\"\n [compareAdapter]=\"compareAdapter\"\n [startDate]=\"startDate()\"\n [endDate]=\"endDate()\"\n [enableRangeSelection]=\"isRangeSelection()\"\n [previewRange]=\"previewRange()\"\n [rows]=\"yearCells\"\n (selectedValueChange)=\"emitSelectedValue($event)\"\n (keydown)=\"calendarBodyKeyDown($event)\"\n >\n </tbody>\n</table>\n" }]
|
|
1962
|
-
}], propDecorators: { triggerEsc: [{
|
|
1950
|
+
}], propDecorators: { focusedDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "focusedDate", required: true }] }, { type: i0.Output, args: ["focusedDateChange"] }], yearRangeChange: [{ type: i0.Output, args: ["yearRangeChange"] }], triggerEsc: [{
|
|
1963
1951
|
type: HostListener,
|
|
1964
1952
|
args: ['keydown.Escape', ['$event']]
|
|
1965
1953
|
}] } });
|
|
@@ -1979,7 +1967,7 @@ class SiTimepickerComponent {
|
|
|
1979
1967
|
* `__si-timepicker-${SiTimepickerComponent.idCounter++}`
|
|
1980
1968
|
* ```
|
|
1981
1969
|
*/
|
|
1982
|
-
id = input(`__si-timepicker-${SiTimepickerComponent.idCounter++}
|
|
1970
|
+
id = input(`__si-timepicker-${SiTimepickerComponent.idCounter++}`, ...(ngDevMode ? [{ debugName: "id" }] : []));
|
|
1983
1971
|
labelledby = inject(new HostAttributeToken('aria-labelledby'), {
|
|
1984
1972
|
optional: true
|
|
1985
1973
|
}) ?? `${this.id()}-label`;
|
|
@@ -1989,108 +1977,108 @@ class SiTimepickerComponent {
|
|
|
1989
1977
|
* @defaultValue false
|
|
1990
1978
|
*/
|
|
1991
1979
|
// eslint-disable-next-line @angular-eslint/no-input-rename
|
|
1992
|
-
disabledInput = input(false, { alias: 'disabled' });
|
|
1980
|
+
disabledInput = input(false, { ...(ngDevMode ? { debugName: "disabledInput" } : {}), alias: 'disabled' });
|
|
1993
1981
|
/**
|
|
1994
1982
|
* @defaultValue 'hh'
|
|
1995
1983
|
*/
|
|
1996
|
-
hoursLabel = input('hh');
|
|
1984
|
+
hoursLabel = input('hh', ...(ngDevMode ? [{ debugName: "hoursLabel" }] : []));
|
|
1997
1985
|
/**
|
|
1998
1986
|
* @defaultValue 'mm'
|
|
1999
1987
|
*/
|
|
2000
|
-
minutesLabel = input('mm');
|
|
1988
|
+
minutesLabel = input('mm', ...(ngDevMode ? [{ debugName: "minutesLabel" }] : []));
|
|
2001
1989
|
/**
|
|
2002
1990
|
* @defaultValue 'ss'
|
|
2003
1991
|
*/
|
|
2004
|
-
secondsLabel = input('ss');
|
|
1992
|
+
secondsLabel = input('ss', ...(ngDevMode ? [{ debugName: "secondsLabel" }] : []));
|
|
2005
1993
|
/**
|
|
2006
1994
|
* @defaultValue 'ms'
|
|
2007
1995
|
*/
|
|
2008
|
-
millisecondsLabel = input('ms');
|
|
1996
|
+
millisecondsLabel = input('ms', ...(ngDevMode ? [{ debugName: "millisecondsLabel" }] : []));
|
|
2009
1997
|
/**
|
|
2010
1998
|
* Hide the labels of the input fields.
|
|
2011
1999
|
* @defaultValue false
|
|
2012
2000
|
*/
|
|
2013
|
-
hideLabels = input(false, { transform: booleanAttribute });
|
|
2001
|
+
hideLabels = input(false, { ...(ngDevMode ? { debugName: "hideLabels" } : {}), transform: booleanAttribute });
|
|
2014
2002
|
/**
|
|
2015
2003
|
* @defaultValue
|
|
2016
2004
|
* ```
|
|
2017
2005
|
* t(() => $localize`:@@SI_DATEPICKER.HOURS:Hours`)
|
|
2018
2006
|
* ```
|
|
2019
2007
|
*/
|
|
2020
|
-
hoursAriaLabel = input(t(() => $localize `:@@SI_DATEPICKER.HOURS:Hours`));
|
|
2008
|
+
hoursAriaLabel = input(t(() => $localize `:@@SI_DATEPICKER.HOURS:Hours`), ...(ngDevMode ? [{ debugName: "hoursAriaLabel" }] : []));
|
|
2021
2009
|
/**
|
|
2022
2010
|
* @defaultValue
|
|
2023
2011
|
* ```
|
|
2024
2012
|
* t(() => $localize`:@@SI_DATEPICKER.MINUTES:Minutes`)
|
|
2025
2013
|
* ```
|
|
2026
2014
|
*/
|
|
2027
|
-
minutesAriaLabel = input(t(() => $localize `:@@SI_DATEPICKER.MINUTES:Minutes`));
|
|
2015
|
+
minutesAriaLabel = input(t(() => $localize `:@@SI_DATEPICKER.MINUTES:Minutes`), ...(ngDevMode ? [{ debugName: "minutesAriaLabel" }] : []));
|
|
2028
2016
|
/**
|
|
2029
2017
|
* @defaultValue
|
|
2030
2018
|
* ```
|
|
2031
2019
|
* t(() => $localize`:@@SI_DATEPICKER.SECONDS:Seconds`)
|
|
2032
2020
|
* ```
|
|
2033
2021
|
*/
|
|
2034
|
-
secondsAriaLabel = input(t(() => $localize `:@@SI_DATEPICKER.SECONDS:Seconds`));
|
|
2022
|
+
secondsAriaLabel = input(t(() => $localize `:@@SI_DATEPICKER.SECONDS:Seconds`), ...(ngDevMode ? [{ debugName: "secondsAriaLabel" }] : []));
|
|
2035
2023
|
/**
|
|
2036
2024
|
* @defaultValue
|
|
2037
2025
|
* ```
|
|
2038
2026
|
* t(() => $localize`:@@SI_DATEPICKER.MILLISECONDS:Milliseconds`)
|
|
2039
2027
|
* ```
|
|
2040
2028
|
*/
|
|
2041
|
-
millisecondsAriaLabel = input(t(() => $localize `:@@SI_DATEPICKER.MILLISECONDS:Milliseconds`));
|
|
2029
|
+
millisecondsAriaLabel = input(t(() => $localize `:@@SI_DATEPICKER.MILLISECONDS:Milliseconds`), ...(ngDevMode ? [{ debugName: "millisecondsAriaLabel" }] : []));
|
|
2042
2030
|
/**
|
|
2043
2031
|
* @defaultValue 'hh'
|
|
2044
2032
|
*/
|
|
2045
|
-
hoursPlaceholder = input('hh');
|
|
2033
|
+
hoursPlaceholder = input('hh', ...(ngDevMode ? [{ debugName: "hoursPlaceholder" }] : []));
|
|
2046
2034
|
/**
|
|
2047
2035
|
* @defaultValue 'mm'
|
|
2048
2036
|
*/
|
|
2049
|
-
minutesPlaceholder = input('mm');
|
|
2037
|
+
minutesPlaceholder = input('mm', ...(ngDevMode ? [{ debugName: "minutesPlaceholder" }] : []));
|
|
2050
2038
|
/**
|
|
2051
2039
|
* @defaultValue 'ss'
|
|
2052
2040
|
*/
|
|
2053
|
-
secondsPlaceholder = input('ss');
|
|
2041
|
+
secondsPlaceholder = input('ss', ...(ngDevMode ? [{ debugName: "secondsPlaceholder" }] : []));
|
|
2054
2042
|
/**
|
|
2055
2043
|
* @defaultValue 'ms'
|
|
2056
2044
|
*/
|
|
2057
|
-
millisecondsPlaceholder = input('ms');
|
|
2058
|
-
meridians = input();
|
|
2045
|
+
millisecondsPlaceholder = input('ms', ...(ngDevMode ? [{ debugName: "millisecondsPlaceholder" }] : []));
|
|
2046
|
+
meridians = input(...(ngDevMode ? [undefined, { debugName: "meridians" }] : []));
|
|
2059
2047
|
/**
|
|
2060
2048
|
* @defaultValue 'am/pm'
|
|
2061
2049
|
*/
|
|
2062
|
-
meridiansLabel = input('am/pm');
|
|
2050
|
+
meridiansLabel = input('am/pm', ...(ngDevMode ? [{ debugName: "meridiansLabel" }] : []));
|
|
2063
2051
|
/**
|
|
2064
2052
|
* @defaultValue
|
|
2065
2053
|
* ```
|
|
2066
2054
|
* t(() => $localize`:@@SI_DATEPICKER.PERIOD:Period`)
|
|
2067
2055
|
* ```
|
|
2068
2056
|
*/
|
|
2069
|
-
meridiansAriaLabel = input(t(() => $localize `:@@SI_DATEPICKER.PERIOD:Period`));
|
|
2057
|
+
meridiansAriaLabel = input(t(() => $localize `:@@SI_DATEPICKER.PERIOD:Period`), ...(ngDevMode ? [{ debugName: "meridiansAriaLabel" }] : []));
|
|
2070
2058
|
/** @defaultValue true */
|
|
2071
|
-
showMinutes = input(true, { transform: booleanAttribute });
|
|
2059
|
+
showMinutes = input(true, { ...(ngDevMode ? { debugName: "showMinutes" } : {}), transform: booleanAttribute });
|
|
2072
2060
|
/** @defaultValue false */
|
|
2073
|
-
showSeconds = input(false, { transform: booleanAttribute });
|
|
2061
|
+
showSeconds = input(false, { ...(ngDevMode ? { debugName: "showSeconds" } : {}), transform: booleanAttribute });
|
|
2074
2062
|
/** @defaultValue false */
|
|
2075
|
-
showMilliseconds = input(false, { transform: booleanAttribute });
|
|
2063
|
+
showMilliseconds = input(false, { ...(ngDevMode ? { debugName: "showMilliseconds" } : {}), transform: booleanAttribute });
|
|
2076
2064
|
/**
|
|
2077
2065
|
* Show time in 12-hour period including the select to toggle between AM/PM.
|
|
2078
2066
|
*/
|
|
2079
|
-
showMeridian = input();
|
|
2067
|
+
showMeridian = input(...(ngDevMode ? [undefined, { debugName: "showMeridian" }] : []));
|
|
2080
2068
|
/**
|
|
2081
2069
|
* A minimum time limit. The date part of the date object will be ignored.
|
|
2082
2070
|
*/
|
|
2083
|
-
min = input();
|
|
2071
|
+
min = input(...(ngDevMode ? [undefined, { debugName: "min" }] : []));
|
|
2084
2072
|
/**
|
|
2085
2073
|
* A maximum time limit. The date part of the date object will be ignored.
|
|
2086
2074
|
*/
|
|
2087
|
-
max = input();
|
|
2075
|
+
max = input(...(ngDevMode ? [undefined, { debugName: "max" }] : []));
|
|
2088
2076
|
/** @defaultValue false */
|
|
2089
|
-
readonly = input(false, { transform: booleanAttribute });
|
|
2077
|
+
readonly = input(false, { ...(ngDevMode ? { debugName: "readonly" } : {}), transform: booleanAttribute });
|
|
2090
2078
|
isValid = output();
|
|
2091
2079
|
meridianChange = output();
|
|
2092
2080
|
inputCompleted = output();
|
|
2093
|
-
inputParts = viewChildren('inputPart');
|
|
2081
|
+
inputParts = viewChildren('inputPart', ...(ngDevMode ? [{ debugName: "inputParts" }] : []));
|
|
2094
2082
|
/**
|
|
2095
2083
|
* This ID will be bound to the `aria-describedby` attribute of the timepicker.
|
|
2096
2084
|
* Use this to reference the element containing the error message(s) for the timepicker.
|
|
@@ -2101,17 +2089,17 @@ class SiTimepickerComponent {
|
|
|
2101
2089
|
* `${this.id()}-errormessage`
|
|
2102
2090
|
* ```
|
|
2103
2091
|
*/
|
|
2104
|
-
errormessageId = input(`${this.id()}-errormessage
|
|
2092
|
+
errormessageId = input(`${this.id()}-errormessage`, ...(ngDevMode ? [{ debugName: "errormessageId" }] : []));
|
|
2105
2093
|
onChange = () => { };
|
|
2106
2094
|
onTouched = () => { };
|
|
2107
2095
|
// The following are the time values for the ui.
|
|
2108
2096
|
periods = computed(() => {
|
|
2109
2097
|
const meridians = this.meridians();
|
|
2110
2098
|
return meridians?.length ? meridians : this.periodDefaults;
|
|
2111
|
-
});
|
|
2112
|
-
use12HourClock = computed(() => this.showMeridian() ?? getLocaleTimeFormat(this.locale, FormatWidth.Full).includes('a'));
|
|
2113
|
-
disabled = computed(() => this.disabledInput() || this.disabledNgControl());
|
|
2114
|
-
meridian = signal('');
|
|
2099
|
+
}, ...(ngDevMode ? [{ debugName: "periods" }] : []));
|
|
2100
|
+
use12HourClock = computed(() => this.showMeridian() ?? getLocaleTimeFormat(this.locale, FormatWidth.Full).includes('a'), ...(ngDevMode ? [{ debugName: "use12HourClock" }] : []));
|
|
2101
|
+
disabled = computed(() => this.disabledInput() || this.disabledNgControl(), ...(ngDevMode ? [{ debugName: "disabled" }] : []));
|
|
2102
|
+
meridian = signal('', ...(ngDevMode ? [{ debugName: "meridian" }] : []));
|
|
2115
2103
|
units = computed(() => {
|
|
2116
2104
|
const config = [
|
|
2117
2105
|
{
|
|
@@ -2155,7 +2143,7 @@ class SiTimepickerComponent {
|
|
|
2155
2143
|
});
|
|
2156
2144
|
}
|
|
2157
2145
|
return config;
|
|
2158
|
-
});
|
|
2146
|
+
}, ...(ngDevMode ? [{ debugName: "units" }] : []));
|
|
2159
2147
|
/* Input fields state */
|
|
2160
2148
|
timeControls = this.formBuilder.group({
|
|
2161
2149
|
hours: this.formBuilder.nonNullable.control('', [this.validateTime('hours')]),
|
|
@@ -2174,7 +2162,7 @@ class SiTimepickerComponent {
|
|
|
2174
2162
|
}
|
|
2175
2163
|
return false;
|
|
2176
2164
|
}
|
|
2177
|
-
disabledNgControl = signal(false);
|
|
2165
|
+
disabledNgControl = signal(false, ...(ngDevMode ? [{ debugName: "disabledNgControl" }] : []));
|
|
2178
2166
|
/**
|
|
2179
2167
|
* Holds the time as date object that is presented by this control.
|
|
2180
2168
|
*/
|
|
@@ -2483,13 +2471,23 @@ class SiTimepickerComponent {
|
|
|
2483
2471
|
this.onTouched();
|
|
2484
2472
|
}
|
|
2485
2473
|
}
|
|
2474
|
+
formatTime(time) {
|
|
2475
|
+
const options = {
|
|
2476
|
+
hour: '2-digit',
|
|
2477
|
+
minute: this.showMinutes() ? '2-digit' : undefined,
|
|
2478
|
+
second: this.showSeconds() ? '2-digit' : undefined,
|
|
2479
|
+
hour12: this.use12HourClock(),
|
|
2480
|
+
fractionalSecondDigits: this.showMilliseconds() ? 3 : undefined
|
|
2481
|
+
};
|
|
2482
|
+
return new Intl.DateTimeFormat(this.locale, options).format(time);
|
|
2483
|
+
}
|
|
2486
2484
|
validateMin(control) {
|
|
2487
2485
|
const current = control.value;
|
|
2488
2486
|
let min = this.min();
|
|
2489
2487
|
if (control.value instanceof Date && min) {
|
|
2490
2488
|
min = dateWithTime(current, min);
|
|
2491
2489
|
if (current < min) {
|
|
2492
|
-
return { minTime: { actual: current, min: min } };
|
|
2490
|
+
return { minTime: { actual: current, min: min, minString: this.formatTime(min) } };
|
|
2493
2491
|
}
|
|
2494
2492
|
}
|
|
2495
2493
|
return null;
|
|
@@ -2501,7 +2499,7 @@ class SiTimepickerComponent {
|
|
|
2501
2499
|
if (control.value instanceof Date && max) {
|
|
2502
2500
|
max = dateWithTime(current, max);
|
|
2503
2501
|
if (current > max) {
|
|
2504
|
-
error.maxTime = { actual: current, max: max };
|
|
2502
|
+
error.maxTime = { actual: current, max: max, maxString: this.formatTime(max) };
|
|
2505
2503
|
}
|
|
2506
2504
|
}
|
|
2507
2505
|
return Object.keys(error).length ? error : null;
|
|
@@ -2515,8 +2513,8 @@ class SiTimepickerComponent {
|
|
|
2515
2513
|
return null;
|
|
2516
2514
|
};
|
|
2517
2515
|
}
|
|
2518
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
2519
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
2516
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiTimepickerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2517
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiTimepickerComponent, isStandalone: true, selector: "si-timepicker", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, disabledInput: { classPropertyName: "disabledInput", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, hoursLabel: { classPropertyName: "hoursLabel", publicName: "hoursLabel", isSignal: true, isRequired: false, transformFunction: null }, minutesLabel: { classPropertyName: "minutesLabel", publicName: "minutesLabel", isSignal: true, isRequired: false, transformFunction: null }, secondsLabel: { classPropertyName: "secondsLabel", publicName: "secondsLabel", isSignal: true, isRequired: false, transformFunction: null }, millisecondsLabel: { classPropertyName: "millisecondsLabel", publicName: "millisecondsLabel", isSignal: true, isRequired: false, transformFunction: null }, hideLabels: { classPropertyName: "hideLabels", publicName: "hideLabels", isSignal: true, isRequired: false, transformFunction: null }, hoursAriaLabel: { classPropertyName: "hoursAriaLabel", publicName: "hoursAriaLabel", isSignal: true, isRequired: false, transformFunction: null }, minutesAriaLabel: { classPropertyName: "minutesAriaLabel", publicName: "minutesAriaLabel", isSignal: true, isRequired: false, transformFunction: null }, secondsAriaLabel: { classPropertyName: "secondsAriaLabel", publicName: "secondsAriaLabel", isSignal: true, isRequired: false, transformFunction: null }, millisecondsAriaLabel: { classPropertyName: "millisecondsAriaLabel", publicName: "millisecondsAriaLabel", isSignal: true, isRequired: false, transformFunction: null }, hoursPlaceholder: { classPropertyName: "hoursPlaceholder", publicName: "hoursPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, minutesPlaceholder: { classPropertyName: "minutesPlaceholder", publicName: "minutesPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, secondsPlaceholder: { classPropertyName: "secondsPlaceholder", publicName: "secondsPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, millisecondsPlaceholder: { classPropertyName: "millisecondsPlaceholder", publicName: "millisecondsPlaceholder", isSignal: true, isRequired: false, transformFunction: null }, meridians: { classPropertyName: "meridians", publicName: "meridians", isSignal: true, isRequired: false, transformFunction: null }, meridiansLabel: { classPropertyName: "meridiansLabel", publicName: "meridiansLabel", isSignal: true, isRequired: false, transformFunction: null }, meridiansAriaLabel: { classPropertyName: "meridiansAriaLabel", publicName: "meridiansAriaLabel", isSignal: true, isRequired: false, transformFunction: null }, showMinutes: { classPropertyName: "showMinutes", publicName: "showMinutes", isSignal: true, isRequired: false, transformFunction: null }, showSeconds: { classPropertyName: "showSeconds", publicName: "showSeconds", isSignal: true, isRequired: false, transformFunction: null }, showMilliseconds: { classPropertyName: "showMilliseconds", publicName: "showMilliseconds", isSignal: true, isRequired: false, transformFunction: null }, showMeridian: { classPropertyName: "showMeridian", publicName: "showMeridian", isSignal: true, isRequired: false, transformFunction: null }, min: { classPropertyName: "min", publicName: "min", isSignal: true, isRequired: false, transformFunction: null }, max: { classPropertyName: "max", publicName: "max", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, errormessageId: { classPropertyName: "errormessageId", publicName: "errormessageId", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { isValid: "isValid", meridianChange: "meridianChange", inputCompleted: "inputCompleted" }, host: { attributes: { "role": "group" }, properties: { "class.readonly": "readonly()", "attr.aria-labelledby": "labelledby" }, classAttribute: "form-custom-control" }, providers: [
|
|
2520
2518
|
{
|
|
2521
2519
|
provide: NG_VALUE_ACCESSOR,
|
|
2522
2520
|
useExisting: SiTimepickerComponent,
|
|
@@ -2533,7 +2531,7 @@ class SiTimepickerComponent {
|
|
|
2533
2531
|
}
|
|
2534
2532
|
], viewQueries: [{ propertyName: "inputParts", predicate: ["inputPart"], descendants: true, isSignal: true }], ngImport: i0, template: "<div\n class=\"d-flex flex-row flex-wrap\"\n cdkMonitorSubtreeFocus\n (cdkFocusChange)=\"focusChange($event)\"\n>\n @for (config of units(); track $index) {\n @if (!$first) {\n <ng-container *ngTemplateOutlet=\"separator; context: { separator: config.separator }\" />\n }\n <label class=\"min-width\">\n @if (!hideLabels()) {\n <span class=\"form-label\">{{ (config.label | translate) || ' ' }}</span>\n }\n <input\n #inputPart\n autocomplete=\"off\"\n class=\"form-control hide-feedback-icon\"\n type=\"text\"\n inputmode=\"numeric\"\n [attr.aria-label]=\"config.ariaLabel | translate\"\n [attr.aria-describedby]=\"errormessageId()\"\n [attr.maxlength]=\"config.maxLength\"\n [formControl]=\"timeControls.controls[config.name]\"\n [name]=\"config.name\"\n [placeholder]=\"config.placeholder\"\n [readonly]=\"readonly()\"\n (blur)=\"updateField(config.name, toHtmlInputElement($event.target).value)\"\n (keydown)=\"handleKeyPressEvent($event)\"\n />\n </label>\n }\n @if (use12HourClock()) {\n <label class=\"ms-2\">\n @if (!hideLabels()) {\n <span class=\"form-label\">{{ (meridiansLabel() | translate) || ' ' }}</span>\n }\n <select\n #inputPart\n class=\"form-control\"\n [attr.aria-label]=\"meridiansAriaLabel() | translate\"\n [attr.aria-describedby]=\"errormessageId()\"\n [class.readonly]=\"readonly()\"\n [disabled]=\"disabled()\"\n (change)=\"toggleMeridian()\"\n (keydown)=\"handleKeyPressEvent($event)\"\n >\n <option value=\"am\" [selected]=\"meridian() === 'am'\">{{ periods()[0] }}</option>\n <option value=\"pm\" [selected]=\"meridian() === 'pm'\">{{ periods()[1] }}</option>\n </select>\n </label>\n }\n</div>\n\n<ng-template #separator let-separator=\"separator\">\n <div class=\"align-self-end pb-3 px-1\" aria-hidden=\"true\">{{ separator ? separator : ':' }}</div>\n</ng-template>\n", styles: [":host{display:block}:host.ng-touched.ng-invalid:not(:has(.ng-touched.ng-invalid)) .form-control{--border-color: var(--element-status-danger)}.min-width{inline-size:100%;max-inline-size:45px;min-inline-size:35px}\n"], dependencies: [{ kind: "ngmodule", type: A11yModule }, { kind: "directive", type: i1.CdkMonitorFocus, selector: "[cdkMonitorElementFocus], [cdkMonitorSubtreeFocus]", outputs: ["cdkFocusChange"], exportAs: ["cdkMonitorFocus"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
2535
2533
|
}
|
|
2536
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
2534
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiTimepickerComponent, decorators: [{
|
|
2537
2535
|
type: Component,
|
|
2538
2536
|
args: [{ selector: 'si-timepicker', imports: [A11yModule, NgTemplateOutlet, ReactiveFormsModule, SiTranslatePipe], providers: [
|
|
2539
2537
|
{
|
|
@@ -2556,7 +2554,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
|
|
|
2556
2554
|
'[class.readonly]': 'readonly()',
|
|
2557
2555
|
'[attr.aria-labelledby]': 'labelledby'
|
|
2558
2556
|
}, template: "<div\n class=\"d-flex flex-row flex-wrap\"\n cdkMonitorSubtreeFocus\n (cdkFocusChange)=\"focusChange($event)\"\n>\n @for (config of units(); track $index) {\n @if (!$first) {\n <ng-container *ngTemplateOutlet=\"separator; context: { separator: config.separator }\" />\n }\n <label class=\"min-width\">\n @if (!hideLabels()) {\n <span class=\"form-label\">{{ (config.label | translate) || ' ' }}</span>\n }\n <input\n #inputPart\n autocomplete=\"off\"\n class=\"form-control hide-feedback-icon\"\n type=\"text\"\n inputmode=\"numeric\"\n [attr.aria-label]=\"config.ariaLabel | translate\"\n [attr.aria-describedby]=\"errormessageId()\"\n [attr.maxlength]=\"config.maxLength\"\n [formControl]=\"timeControls.controls[config.name]\"\n [name]=\"config.name\"\n [placeholder]=\"config.placeholder\"\n [readonly]=\"readonly()\"\n (blur)=\"updateField(config.name, toHtmlInputElement($event.target).value)\"\n (keydown)=\"handleKeyPressEvent($event)\"\n />\n </label>\n }\n @if (use12HourClock()) {\n <label class=\"ms-2\">\n @if (!hideLabels()) {\n <span class=\"form-label\">{{ (meridiansLabel() | translate) || ' ' }}</span>\n }\n <select\n #inputPart\n class=\"form-control\"\n [attr.aria-label]=\"meridiansAriaLabel() | translate\"\n [attr.aria-describedby]=\"errormessageId()\"\n [class.readonly]=\"readonly()\"\n [disabled]=\"disabled()\"\n (change)=\"toggleMeridian()\"\n (keydown)=\"handleKeyPressEvent($event)\"\n >\n <option value=\"am\" [selected]=\"meridian() === 'am'\">{{ periods()[0] }}</option>\n <option value=\"pm\" [selected]=\"meridian() === 'pm'\">{{ periods()[1] }}</option>\n </select>\n </label>\n }\n</div>\n\n<ng-template #separator let-separator=\"separator\">\n <div class=\"align-self-end pb-3 px-1\" aria-hidden=\"true\">{{ separator ? separator : ':' }}</div>\n</ng-template>\n", styles: [":host{display:block}:host.ng-touched.ng-invalid:not(:has(.ng-touched.ng-invalid)) .form-control{--border-color: var(--element-status-danger)}.min-width{inline-size:100%;max-inline-size:45px;min-inline-size:35px}\n"] }]
|
|
2559
|
-
}], ctorParameters: () => [] });
|
|
2557
|
+
}], ctorParameters: () => [], propDecorators: { id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], disabledInput: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], hoursLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "hoursLabel", required: false }] }], minutesLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "minutesLabel", required: false }] }], secondsLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "secondsLabel", required: false }] }], millisecondsLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "millisecondsLabel", required: false }] }], hideLabels: [{ type: i0.Input, args: [{ isSignal: true, alias: "hideLabels", required: false }] }], hoursAriaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "hoursAriaLabel", required: false }] }], minutesAriaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "minutesAriaLabel", required: false }] }], secondsAriaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "secondsAriaLabel", required: false }] }], millisecondsAriaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "millisecondsAriaLabel", required: false }] }], hoursPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "hoursPlaceholder", required: false }] }], minutesPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "minutesPlaceholder", required: false }] }], secondsPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "secondsPlaceholder", required: false }] }], millisecondsPlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "millisecondsPlaceholder", required: false }] }], meridians: [{ type: i0.Input, args: [{ isSignal: true, alias: "meridians", required: false }] }], meridiansLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "meridiansLabel", required: false }] }], meridiansAriaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "meridiansAriaLabel", required: false }] }], showMinutes: [{ type: i0.Input, args: [{ isSignal: true, alias: "showMinutes", required: false }] }], showSeconds: [{ type: i0.Input, args: [{ isSignal: true, alias: "showSeconds", required: false }] }], showMilliseconds: [{ type: i0.Input, args: [{ isSignal: true, alias: "showMilliseconds", required: false }] }], showMeridian: [{ type: i0.Input, args: [{ isSignal: true, alias: "showMeridian", required: false }] }], min: [{ type: i0.Input, args: [{ isSignal: true, alias: "min", required: false }] }], max: [{ type: i0.Input, args: [{ isSignal: true, alias: "max", required: false }] }], readonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], isValid: [{ type: i0.Output, args: ["isValid"] }], meridianChange: [{ type: i0.Output, args: ["meridianChange"] }], inputCompleted: [{ type: i0.Output, args: ["inputCompleted"] }], inputParts: [{ type: i0.ViewChildren, args: ['inputPart', { isSignal: true }] }], errormessageId: [{ type: i0.Input, args: [{ isSignal: true, alias: "errormessageId", required: false }] }] } });
|
|
2560
2558
|
|
|
2561
2559
|
/**
|
|
2562
2560
|
* Copyright (c) Siemens 2016 - 2025
|
|
@@ -2569,31 +2567,31 @@ class SiDatepickerComponent {
|
|
|
2569
2567
|
* The date which is currently focused
|
|
2570
2568
|
* Compare to the selected date or range the calendar requires to have one element to focus.
|
|
2571
2569
|
*/
|
|
2572
|
-
focusedDate = model();
|
|
2570
|
+
focusedDate = model(...(ngDevMode ? [undefined, { debugName: "focusedDate" }] : []));
|
|
2573
2571
|
/**
|
|
2574
2572
|
* The selected date of the datepicker. Use for
|
|
2575
2573
|
* initialization and for bidirectional binding.
|
|
2576
2574
|
*/
|
|
2577
|
-
date = model();
|
|
2575
|
+
date = model(...(ngDevMode ? [undefined, { debugName: "date" }] : []));
|
|
2578
2576
|
/**
|
|
2579
2577
|
* The selected date range of the datepicker. Use for
|
|
2580
2578
|
* initialization and for bidirectional binding.
|
|
2581
2579
|
*/
|
|
2582
|
-
dateRange = model();
|
|
2580
|
+
dateRange = model(...(ngDevMode ? [undefined, { debugName: "dateRange" }] : []));
|
|
2583
2581
|
/** @internal */
|
|
2584
|
-
dateRangeRole = input();
|
|
2582
|
+
dateRangeRole = input(...(ngDevMode ? [undefined, { debugName: "dateRangeRole" }] : []));
|
|
2585
2583
|
/**
|
|
2586
2584
|
* Set initial focus to calendar body.
|
|
2587
2585
|
*
|
|
2588
2586
|
* @defaultValue false
|
|
2589
2587
|
*/
|
|
2590
|
-
initialFocus = input(false);
|
|
2588
|
+
initialFocus = input(false, ...(ngDevMode ? [{ debugName: "initialFocus" }] : []));
|
|
2591
2589
|
/**
|
|
2592
2590
|
* Disabled the optional visible time picker.
|
|
2593
2591
|
*
|
|
2594
2592
|
* @defaultValue false
|
|
2595
2593
|
*/
|
|
2596
|
-
disabledTime = model(false);
|
|
2594
|
+
disabledTime = model(false, ...(ngDevMode ? [{ debugName: "disabledTime" }] : []));
|
|
2597
2595
|
/**
|
|
2598
2596
|
* Object to configure the datepicker.
|
|
2599
2597
|
*
|
|
@@ -2602,7 +2600,7 @@ class SiDatepickerComponent {
|
|
|
2602
2600
|
* {}
|
|
2603
2601
|
* ```
|
|
2604
2602
|
*/
|
|
2605
|
-
config = model({});
|
|
2603
|
+
config = model({}, ...(ngDevMode ? [{ debugName: "config" }] : []));
|
|
2606
2604
|
/**
|
|
2607
2605
|
* Aria label for the previous button. Needed for a11y.
|
|
2608
2606
|
*
|
|
@@ -2611,7 +2609,7 @@ class SiDatepickerComponent {
|
|
|
2611
2609
|
* t(() => $localize`:@@SI_DATEPICKER.PREVIOUS:Previous`)
|
|
2612
2610
|
* ```
|
|
2613
2611
|
*/
|
|
2614
|
-
previousLabel = input(t(() => $localize `:@@SI_DATEPICKER.PREVIOUS:Previous`));
|
|
2612
|
+
previousLabel = input(t(() => $localize `:@@SI_DATEPICKER.PREVIOUS:Previous`), ...(ngDevMode ? [{ debugName: "previousLabel" }] : []));
|
|
2615
2613
|
/**
|
|
2616
2614
|
* Aria label for the next button. Needed for a11y.
|
|
2617
2615
|
*
|
|
@@ -2620,7 +2618,7 @@ class SiDatepickerComponent {
|
|
|
2620
2618
|
* t(() => $localize`:@@SI_DATEPICKER.NEXT:Next`)
|
|
2621
2619
|
* ```
|
|
2622
2620
|
*/
|
|
2623
|
-
nextLabel = input(t(() => $localize `:@@SI_DATEPICKER.NEXT:Next`));
|
|
2621
|
+
nextLabel = input(t(() => $localize `:@@SI_DATEPICKER.NEXT:Next`), ...(ngDevMode ? [{ debugName: "nextLabel" }] : []));
|
|
2624
2622
|
/**
|
|
2625
2623
|
* Aria label for week number column
|
|
2626
2624
|
*
|
|
@@ -2630,7 +2628,7 @@ class SiDatepickerComponent {
|
|
|
2630
2628
|
* t(() => $localize`:@@SI_DATEPICKER.CALENDAR_WEEK_LABEL:Calendar week`)
|
|
2631
2629
|
* ```
|
|
2632
2630
|
*/
|
|
2633
|
-
calenderWeekLabel = input();
|
|
2631
|
+
calenderWeekLabel = input(...(ngDevMode ? [undefined, { debugName: "calenderWeekLabel" }] : []));
|
|
2634
2632
|
/**
|
|
2635
2633
|
* Aria label for week number column
|
|
2636
2634
|
*
|
|
@@ -2639,22 +2637,20 @@ class SiDatepickerComponent {
|
|
|
2639
2637
|
* t(() => $localize`:@@SI_DATEPICKER.CALENDAR_WEEK_LABEL:Calendar week`)
|
|
2640
2638
|
* ```
|
|
2641
2639
|
*/
|
|
2642
|
-
calendarWeekLabel = input(t(() => $localize `:@@SI_DATEPICKER.CALENDAR_WEEK_LABEL:Calendar week`));
|
|
2643
|
-
derivedWeekLabel = computed(() => this.calenderWeekLabel() ?? this.calendarWeekLabel());
|
|
2640
|
+
calendarWeekLabel = input(t(() => $localize `:@@SI_DATEPICKER.CALENDAR_WEEK_LABEL:Calendar week`), ...(ngDevMode ? [{ debugName: "calendarWeekLabel" }] : []));
|
|
2641
|
+
derivedWeekLabel = computed(() => this.calenderWeekLabel() ?? this.calendarWeekLabel(), ...(ngDevMode ? [{ debugName: "derivedWeekLabel" }] : []));
|
|
2644
2642
|
/**
|
|
2645
2643
|
* Enable/disable 12H mode in timepicker. Defaults to locale
|
|
2646
2644
|
*
|
|
2647
2645
|
* @defaultValue undefined
|
|
2648
2646
|
*/
|
|
2649
|
-
time12h = input(undefined, {
|
|
2650
|
-
transform: booleanAttribute
|
|
2651
|
-
});
|
|
2647
|
+
time12h = input(undefined, { ...(ngDevMode ? { debugName: "time12h" } : {}), transform: booleanAttribute });
|
|
2652
2648
|
/**
|
|
2653
2649
|
* Use this to force date range operation to select either start date or end date.
|
|
2654
2650
|
*
|
|
2655
2651
|
* @defaultValue 'START'
|
|
2656
2652
|
*/
|
|
2657
|
-
rangeType = model('START');
|
|
2653
|
+
rangeType = model('START', ...(ngDevMode ? [{ debugName: "rangeType" }] : []));
|
|
2658
2654
|
/**
|
|
2659
2655
|
* Optional input to control the minimum month the datepicker can show and the user can navigate.
|
|
2660
2656
|
* The `minMonth` can be larger than the `minDate` This option enables the usage of multiple
|
|
@@ -2662,7 +2658,7 @@ class SiDatepickerComponent {
|
|
|
2662
2658
|
* shows a earlier month the the more right one.
|
|
2663
2659
|
* @internal
|
|
2664
2660
|
*/
|
|
2665
|
-
minMonth = input();
|
|
2661
|
+
minMonth = input(...(ngDevMode ? [undefined, { debugName: "minMonth" }] : []));
|
|
2666
2662
|
/**
|
|
2667
2663
|
* Optional input to control the maximum month the datepicker can show and the user can navigate.
|
|
2668
2664
|
* The `maxMonth` can be smaller than the `maxDate` This option enables the usage of multiple
|
|
@@ -2670,19 +2666,19 @@ class SiDatepickerComponent {
|
|
|
2670
2666
|
* shows a earlier month the the more right one.
|
|
2671
2667
|
* @internal
|
|
2672
2668
|
*/
|
|
2673
|
-
maxMonth = input();
|
|
2669
|
+
maxMonth = input(...(ngDevMode ? [undefined, { debugName: "maxMonth" }] : []));
|
|
2674
2670
|
/**
|
|
2675
2671
|
* Option to hide the time switch.
|
|
2676
2672
|
*
|
|
2677
2673
|
* @defaultValue false
|
|
2678
2674
|
*/
|
|
2679
|
-
hideTimeToggle = input(false);
|
|
2675
|
+
hideTimeToggle = input(false, ...(ngDevMode ? [{ debugName: "hideTimeToggle" }] : []));
|
|
2680
2676
|
/** @internal */
|
|
2681
|
-
hideCalendar = input(false);
|
|
2677
|
+
hideCalendar = input(false, ...(ngDevMode ? [{ debugName: "hideCalendar" }] : []));
|
|
2682
2678
|
/**
|
|
2683
2679
|
* Optional timepicker label.
|
|
2684
2680
|
*/
|
|
2685
|
-
timepickerLabel = input();
|
|
2681
|
+
timepickerLabel = input(...(ngDevMode ? [undefined, { debugName: "timepickerLabel" }] : []));
|
|
2686
2682
|
get startDate() {
|
|
2687
2683
|
return this.config().enableDateRange ? this.dateRange()?.start : this.date();
|
|
2688
2684
|
}
|
|
@@ -2705,7 +2701,7 @@ class SiDatepickerComponent {
|
|
|
2705
2701
|
defaultEnableTimeText = t(() => $localize `:@@SI_DATEPICKER.ENABLED_TIME_TEXT:Consider time`);
|
|
2706
2702
|
includeTimeLabel = computed(() => this.disabledTime()
|
|
2707
2703
|
? (this.config().disabledTimeText ?? this.defaultDisabledTimeText)
|
|
2708
|
-
: (this.config().enabledTimeText ?? this.defaultEnableTimeText));
|
|
2704
|
+
: (this.config().enabledTimeText ?? this.defaultEnableTimeText), ...(ngDevMode ? [{ debugName: "includeTimeLabel" }] : []));
|
|
2709
2705
|
get weekStartDay() {
|
|
2710
2706
|
return this.config().weekStartDay ?? this.localeWeekStart;
|
|
2711
2707
|
}
|
|
@@ -2715,7 +2711,7 @@ class SiDatepickerComponent {
|
|
|
2715
2711
|
/**
|
|
2716
2712
|
* The active view
|
|
2717
2713
|
*/
|
|
2718
|
-
view = signal('week');
|
|
2714
|
+
view = signal('week', ...(ngDevMode ? [{ debugName: "view" }] : []));
|
|
2719
2715
|
/**
|
|
2720
2716
|
* Get the current shown view.
|
|
2721
2717
|
*/
|
|
@@ -2728,11 +2724,11 @@ class SiDatepickerComponent {
|
|
|
2728
2724
|
default:
|
|
2729
2725
|
return this.daySelection();
|
|
2730
2726
|
}
|
|
2731
|
-
});
|
|
2732
|
-
actualFocusedDate = computed(() => this.focusedDate() ?? today());
|
|
2733
|
-
requireFocus = signal(this.initialFocus());
|
|
2727
|
+
}, ...(ngDevMode ? [{ debugName: "activeView" }] : []));
|
|
2728
|
+
actualFocusedDate = computed(() => this.focusedDate() ?? today(), ...(ngDevMode ? [{ debugName: "actualFocusedDate" }] : []));
|
|
2729
|
+
requireFocus = signal(this.initialFocus(), ...(ngDevMode ? [{ debugName: "requireFocus" }] : []));
|
|
2734
2730
|
/** When the user switch from the year or month view via keyboard selection we force the focus. */
|
|
2735
|
-
forceFocus = computed(() => this.requireFocus() || this.initialFocus());
|
|
2731
|
+
forceFocus = computed(() => this.requireFocus() || this.initialFocus(), ...(ngDevMode ? [{ debugName: "forceFocus" }] : []));
|
|
2736
2732
|
months = [];
|
|
2737
2733
|
switchId = `__si-datepicker-switch-id-${idCounter++}`;
|
|
2738
2734
|
timepickerId = `__si-datepicker-timepicker-id-${idCounter++}`;
|
|
@@ -2759,16 +2755,16 @@ class SiDatepickerComponent {
|
|
|
2759
2755
|
*/
|
|
2760
2756
|
previousTime;
|
|
2761
2757
|
/** Reference to the current day selection component. Shown when view === 'week' */
|
|
2762
|
-
daySelection = viewChild(SiDaySelectionComponent);
|
|
2758
|
+
daySelection = viewChild(SiDaySelectionComponent, ...(ngDevMode ? [{ debugName: "daySelection" }] : []));
|
|
2763
2759
|
/** Reference to the current month selection component. Shown when view === 'month' */
|
|
2764
|
-
monthSelection = viewChild(SiMonthSelectionComponent);
|
|
2760
|
+
monthSelection = viewChild(SiMonthSelectionComponent, ...(ngDevMode ? [{ debugName: "monthSelection" }] : []));
|
|
2765
2761
|
/** Reference to the current year selection component. Shown when view === 'year' */
|
|
2766
|
-
yearSelection = viewChild(SiYearSelectionComponent);
|
|
2762
|
+
yearSelection = viewChild(SiYearSelectionComponent, ...(ngDevMode ? [{ debugName: "yearSelection" }] : []));
|
|
2767
2763
|
/**
|
|
2768
2764
|
* The cell which which has the mouse hover.
|
|
2769
2765
|
* @internal
|
|
2770
2766
|
*/
|
|
2771
|
-
activeHover = model();
|
|
2767
|
+
activeHover = model(...(ngDevMode ? [undefined, { debugName: "activeHover" }] : []));
|
|
2772
2768
|
constructor() {
|
|
2773
2769
|
this.initCalendarLabels();
|
|
2774
2770
|
const weekStart = getLocaleFirstDayOfWeek(this.locale);
|
|
@@ -3078,10 +3074,10 @@ class SiDatepickerComponent {
|
|
|
3078
3074
|
onActiveHoverChange(event) {
|
|
3079
3075
|
this.activeHover.set(event);
|
|
3080
3076
|
}
|
|
3081
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
3082
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.0.6", type: SiDatepickerComponent, isStandalone: true, selector: "si-datepicker", inputs: { focusedDate: { classPropertyName: "focusedDate", publicName: "focusedDate", isSignal: true, isRequired: false, transformFunction: null }, date: { classPropertyName: "date", publicName: "date", isSignal: true, isRequired: false, transformFunction: null }, dateRange: { classPropertyName: "dateRange", publicName: "dateRange", isSignal: true, isRequired: false, transformFunction: null }, dateRangeRole: { classPropertyName: "dateRangeRole", publicName: "dateRangeRole", isSignal: true, isRequired: false, transformFunction: null }, initialFocus: { classPropertyName: "initialFocus", publicName: "initialFocus", isSignal: true, isRequired: false, transformFunction: null }, disabledTime: { classPropertyName: "disabledTime", publicName: "disabledTime", isSignal: true, isRequired: false, transformFunction: null }, config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: false, transformFunction: null }, previousLabel: { classPropertyName: "previousLabel", publicName: "previousLabel", isSignal: true, isRequired: false, transformFunction: null }, nextLabel: { classPropertyName: "nextLabel", publicName: "nextLabel", isSignal: true, isRequired: false, transformFunction: null }, calenderWeekLabel: { classPropertyName: "calenderWeekLabel", publicName: "calenderWeekLabel", isSignal: true, isRequired: false, transformFunction: null }, calendarWeekLabel: { classPropertyName: "calendarWeekLabel", publicName: "calendarWeekLabel", isSignal: true, isRequired: false, transformFunction: null }, time12h: { classPropertyName: "time12h", publicName: "time12h", isSignal: true, isRequired: false, transformFunction: null }, rangeType: { classPropertyName: "rangeType", publicName: "rangeType", isSignal: true, isRequired: false, transformFunction: null }, minMonth: { classPropertyName: "minMonth", publicName: "minMonth", isSignal: true, isRequired: false, transformFunction: null }, maxMonth: { classPropertyName: "maxMonth", publicName: "maxMonth", isSignal: true, isRequired: false, transformFunction: null }, hideTimeToggle: { classPropertyName: "hideTimeToggle", publicName: "hideTimeToggle", isSignal: true, isRequired: false, transformFunction: null }, hideCalendar: { classPropertyName: "hideCalendar", publicName: "hideCalendar", isSignal: true, isRequired: false, transformFunction: null }, timepickerLabel: { classPropertyName: "timepickerLabel", publicName: "timepickerLabel", isSignal: true, isRequired: false, transformFunction: null }, activeHover: { classPropertyName: "activeHover", publicName: "activeHover", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { focusedDate: "focusedDateChange", date: "dateChange", dateRange: "dateRangeChange", disabledTime: "disabledTimeChange", config: "configChange", rangeType: "rangeTypeChange", activeHover: "activeHoverChange" }, viewQueries: [{ propertyName: "daySelection", first: true, predicate: SiDaySelectionComponent, descendants: true, isSignal: true }, { propertyName: "monthSelection", first: true, predicate: SiMonthSelectionComponent, descendants: true, isSignal: true }, { propertyName: "yearSelection", first: true, predicate: SiYearSelectionComponent, descendants: true, isSignal: true }], usesOnChanges: true, ngImport: i0, template: "@if (!hideCalendar()) {\n <div class=\"text-center pb-6 calendar\">\n @switch (view()) {\n @case ('year') {\n <si-year-selection\n [focusedDate]=\"actualFocusedDate()\"\n [startDate]=\"startDate\"\n [endDate]=\"endDate\"\n [minDate]=\"config().minDate\"\n [maxDate]=\"config().maxDate\"\n [minMonth]=\"minMonth()\"\n [maxMonth]=\"maxMonth()\"\n [isRangeSelection]=\"config().enableDateRange!\"\n [previousLabel]=\"previousLabel() | translate\"\n [nextLabel]=\"nextLabel() | translate\"\n (selectedValueChange)=\"activeYearChange($event)\"\n />\n }\n @case ('month') {\n <si-month-selection\n [startDate]=\"startDate\"\n [endDate]=\"endDate\"\n [months]=\"months\"\n [minDate]=\"config().minDate\"\n [maxDate]=\"config().maxDate\"\n [minMonth]=\"minMonth()\"\n [maxMonth]=\"maxMonth()\"\n [isRangeSelection]=\"config().enableDateRange!\"\n [previewRange]=\"rangeType() === 'END'\"\n [previousLabel]=\"previousLabel() | translate\"\n [nextLabel]=\"nextLabel() | translate\"\n [activeHover]=\"activeHover()\"\n [focusedDate]=\"actualFocusedDate()\"\n (activeHoverChange)=\"onActiveHoverChange($event)\"\n (focusedDateChange)=\"focusedDate.set($event)\"\n (selectedValueChange)=\"activeMonthChange($event)\"\n (viewChange)=\"view.set($event)\"\n />\n }\n @case ('week') {\n <si-day-selection\n [initialFocus]=\"forceFocus()\"\n [startDate]=\"startDate\"\n [endDate]=\"dateRange()?.end\"\n [isRangeSelection]=\"config().enableDateRange!\"\n [previewRange]=\"rangeType() === 'END'\"\n [hideWeekNumbers]=\"hideWeekNumbers\"\n [minDate]=\"config().minDate\"\n [maxDate]=\"config().maxDate\"\n [minMonth]=\"minMonth()\"\n [weekStartDay]=\"weekStartDay\"\n [calendarWeekLabel]=\"derivedWeekLabel()\"\n [previousLabel]=\"previousLabel() | translate\"\n [nextLabel]=\"nextLabel() | translate\"\n [todayLabel]=\"config().todayText\"\n [activeHover]=\"activeHover()\"\n [focusedDate]=\"actualFocusedDate()\"\n (activeHoverChange)=\"onActiveHoverChange($event)\"\n (focusedDateChange)=\"focusedDate.set($event)\"\n (selectedValueChange)=\"selectionChange($event!)\"\n (viewChange)=\"view.set($event)\"\n />\n }\n }\n </div>\n}\n@if (this.config().showTime) {\n <div\n class=\"timepicker-container px-9 pb-6\"\n [class.pt-6]=\"!hideCalendar()\"\n [class.border-top]=\"!hideCalendar()\"\n >\n @if (!config().mandatoryTime && !hideTimeToggle()) {\n <div class=\"mb-5 form-check form-switch\">\n <input\n type=\"checkbox\"\n class=\"form-check-input\"\n role=\"switch\"\n [id]=\"switchId\"\n [checked]=\"!disabledTime()\"\n (change)=\"toggleDisabledTime()\"\n />\n <label class=\"form-check-label\" [for]=\"switchId\">{{\n includeTimeLabel() | translate\n }}</label>\n </div>\n }\n <div class=\"mt-auto\">\n @if (timepickerLabel()) {\n <label class=\"form-label\" [for]=\"timepickerId\">{{ timepickerLabel() | translate }}</label>\n }\n <si-timepicker\n #timePicker\n [id]=\"timepickerId\"\n [formControl]=\"time\"\n [hoursLabel]=\"config().hoursLabel ?? timePicker.hoursLabel()\"\n [minutesLabel]=\"config().minutesLabel ?? timePicker.minutesLabel()\"\n [secondsLabel]=\"config().secondsLabel ?? timePicker.secondsLabel()\"\n [millisecondsLabel]=\"config().millisecondsLabel ?? timePicker.millisecondsLabel()\"\n [hideLabels]=\"config().hideLabels ?? timePicker.hideLabels()\"\n [hoursAriaLabel]=\"config().hoursAriaLabel ?? timePicker.hoursAriaLabel()\"\n [minutesAriaLabel]=\"config().minutesAriaLabel ?? timePicker.minutesAriaLabel()\"\n [secondsAriaLabel]=\"config().secondsAriaLabel ?? timePicker.secondsAriaLabel()\"\n [millisecondsAriaLabel]=\"\n config().millisecondsAriaLabel ?? timePicker.millisecondsAriaLabel()\n \"\n [hoursPlaceholder]=\"config().hoursPlaceholder ?? timePicker.hoursPlaceholder()\"\n [minutesPlaceholder]=\"config().minutesPlaceholder ?? timePicker.minutesPlaceholder()\"\n [secondsPlaceholder]=\"config().secondsPlaceholder ?? timePicker.secondsPlaceholder()\"\n [millisecondsPlaceholder]=\"\n config().millisecondsPlaceholder ?? timePicker.millisecondsPlaceholder()\n \"\n [meridians]=\"config().meridians ?? timePicker.meridians()\"\n [meridiansLabel]=\"config().meridiansLabel ?? timePicker.meridiansLabel()\"\n [meridiansAriaLabel]=\"config().meridiansAriaLabel ?? timePicker.meridiansAriaLabel()\"\n [showMinutes]=\"config().showMinutes ?? true\"\n [showSeconds]=\"config().showSeconds ?? false\"\n [showMilliseconds]=\"config().showMilliseconds ?? false\"\n [showMeridian]=\"time12h()\"\n />\n </div>\n </div>\n}\n", styles: [":host ::ng-deep .selection .month:not(.disabled):hover,:host ::ng-deep .selection .year:not(.disabled):hover,:host ::ng-deep .year:not(.disabled):not(.selected):hover,:host ::ng-deep .month:not(.disabled):not(.selected):hover,:host ::ng-deep .day:not(.disabled):not(.selected):hover{background:var(--element-base-1-hover);color:var(--element-ui-0)}:host ::ng-deep .year,:host ::ng-deep .month,:host ::ng-deep .day{block-size:32px;line-height:32px;inline-size:100%}:host ::ng-deep .day{inline-size:32px}:host ::ng-deep .year,:host ::ng-deep .month,:host ::ng-deep .day{margin-inline:auto;position:relative;border:unset;background-color:unset;padding:0;cursor:pointer;border-radius:var(--element-button-radius)}:host{background:var(--element-base-1);border-radius:var(--element-radius-2);display:flex;flex-direction:column;inline-size:348px}:host ::ng-deep .header,:host ::ng-deep .footer{display:flex;align-items:center}:host ::ng-deep .header{padding-block-start:12px;padding-block-end:16px;padding-inline:32px;border-block-end:1px solid var(--element-ui-4)}:host ::ng-deep .header a{text-decoration:none;cursor:pointer}:host ::ng-deep .footer{margin-block-start:4px;text-align:center}:host ::ng-deep table{inline-size:100%;border-collapse:separate;border-spacing:0 3px;table-layout:fixed;margin-block-end:-3px}:host ::ng-deep .day.selected{background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep .month.selected{background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep .year.selected{background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep td[role=gridcell]{text-align:center}:host ::ng-deep th{font-weight:400;text-align:center;block-size:32px}:host ::ng-deep .week-num,:host ::ng-deep th{font-size:.75rem;color:var(--element-text-secondary);inline-size:32px;cursor:default}:host ::ng-deep .today.selected:before{border-color:var(--element-ui-5)}:host ::ng-deep .today:before{position:absolute;content:\"\";inset:1px;border:1px solid var(--element-ui-1);border-radius:var(--element-radius-2);display:inline-block}:host ::ng-deep .selection .month,:host ::ng-deep .selection .year{block-size:30px;line-height:30px;cursor:pointer}:host ::ng-deep .selection .month{inline-size:50%}:host ::ng-deep .selection .year{inline-size:33.3%}:host ::ng-deep .disabled{color:var(--element-text-disabled);font-weight:400!important;cursor:default!important}:host ::ng-deep .range{background-color:var(--element-ui-4)}:host ::ng-deep .range:hover{background:var(--element-base-1-hover)}:host ::ng-deep .range:hover div.si-h4:hover{background:transparent}:host ::ng-deep .range-hover{background-color:var(--element-base-1-hover)}:host ::ng-deep .range-hover-end{border-start-end-radius:var(--element-button-radius);border-end-end-radius:var(--element-button-radius)}:host ::ng-deep td:is(.range-start,.range-end){background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep td:is(.range-start,.range-end) div.si-h4:hover,:host ::ng-deep td:is(.range-start,.range-end) div.si-body-lg:hover{background:transparent;color:var(--element-base-1)}:host ::ng-deep td:is(.range-start,.range-end) .today:before{border-color:var(--element-ui-5)}:host ::ng-deep td.range-start{border-start-start-radius:var(--element-button-radius);border-end-start-radius:var(--element-button-radius)}:host ::ng-deep td.range-end{border-start-end-radius:var(--element-button-radius);border-end-end-radius:var(--element-button-radius)}:host ::ng-deep .calendar-button{font-weight:600;font-size:.875rem;line-height:1.1428571429;color:var(--element-text-active);min-inline-size:0!important}:host ::ng-deep .calendar{block-size:28em}:host ::ng-deep .timepicker-container{display:flex;flex:1 1 auto;flex-direction:column}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: SiYearSelectionComponent, selector: "si-year-selection", inputs: ["focusedDate"], outputs: ["focusedDateChange", "yearRangeChange"] }, { kind: "component", type: SiMonthSelectionComponent, selector: "si-month-selection", inputs: ["months", "focusedDate"], outputs: ["focusedDateChange", "activeMonthChange", "viewChange"] }, { kind: "component", type: SiDaySelectionComponent, selector: "si-day-selection", inputs: ["hideWeekNumbers", "weekStartDay", "focusedDate", "todayLabel", "calendarWeekLabel"], outputs: ["focusedDateChange", "activeMonthChange", "viewChange"] }, { kind: "component", type: SiTimepickerComponent, selector: "si-timepicker", inputs: ["id", "disabled", "hoursLabel", "minutesLabel", "secondsLabel", "millisecondsLabel", "hideLabels", "hoursAriaLabel", "minutesAriaLabel", "secondsAriaLabel", "millisecondsAriaLabel", "hoursPlaceholder", "minutesPlaceholder", "secondsPlaceholder", "millisecondsPlaceholder", "meridians", "meridiansLabel", "meridiansAriaLabel", "showMinutes", "showSeconds", "showMilliseconds", "showMeridian", "min", "max", "readonly", "errormessageId"], outputs: ["isValid", "meridianChange", "inputCompleted"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }] });
|
|
3077
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3078
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiDatepickerComponent, isStandalone: true, selector: "si-datepicker", inputs: { focusedDate: { classPropertyName: "focusedDate", publicName: "focusedDate", isSignal: true, isRequired: false, transformFunction: null }, date: { classPropertyName: "date", publicName: "date", isSignal: true, isRequired: false, transformFunction: null }, dateRange: { classPropertyName: "dateRange", publicName: "dateRange", isSignal: true, isRequired: false, transformFunction: null }, dateRangeRole: { classPropertyName: "dateRangeRole", publicName: "dateRangeRole", isSignal: true, isRequired: false, transformFunction: null }, initialFocus: { classPropertyName: "initialFocus", publicName: "initialFocus", isSignal: true, isRequired: false, transformFunction: null }, disabledTime: { classPropertyName: "disabledTime", publicName: "disabledTime", isSignal: true, isRequired: false, transformFunction: null }, config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: false, transformFunction: null }, previousLabel: { classPropertyName: "previousLabel", publicName: "previousLabel", isSignal: true, isRequired: false, transformFunction: null }, nextLabel: { classPropertyName: "nextLabel", publicName: "nextLabel", isSignal: true, isRequired: false, transformFunction: null }, calenderWeekLabel: { classPropertyName: "calenderWeekLabel", publicName: "calenderWeekLabel", isSignal: true, isRequired: false, transformFunction: null }, calendarWeekLabel: { classPropertyName: "calendarWeekLabel", publicName: "calendarWeekLabel", isSignal: true, isRequired: false, transformFunction: null }, time12h: { classPropertyName: "time12h", publicName: "time12h", isSignal: true, isRequired: false, transformFunction: null }, rangeType: { classPropertyName: "rangeType", publicName: "rangeType", isSignal: true, isRequired: false, transformFunction: null }, minMonth: { classPropertyName: "minMonth", publicName: "minMonth", isSignal: true, isRequired: false, transformFunction: null }, maxMonth: { classPropertyName: "maxMonth", publicName: "maxMonth", isSignal: true, isRequired: false, transformFunction: null }, hideTimeToggle: { classPropertyName: "hideTimeToggle", publicName: "hideTimeToggle", isSignal: true, isRequired: false, transformFunction: null }, hideCalendar: { classPropertyName: "hideCalendar", publicName: "hideCalendar", isSignal: true, isRequired: false, transformFunction: null }, timepickerLabel: { classPropertyName: "timepickerLabel", publicName: "timepickerLabel", isSignal: true, isRequired: false, transformFunction: null }, activeHover: { classPropertyName: "activeHover", publicName: "activeHover", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { focusedDate: "focusedDateChange", date: "dateChange", dateRange: "dateRangeChange", disabledTime: "disabledTimeChange", config: "configChange", rangeType: "rangeTypeChange", activeHover: "activeHoverChange" }, viewQueries: [{ propertyName: "daySelection", first: true, predicate: SiDaySelectionComponent, descendants: true, isSignal: true }, { propertyName: "monthSelection", first: true, predicate: SiMonthSelectionComponent, descendants: true, isSignal: true }, { propertyName: "yearSelection", first: true, predicate: SiYearSelectionComponent, descendants: true, isSignal: true }], usesOnChanges: true, ngImport: i0, template: "@if (!hideCalendar()) {\n <div class=\"text-center pb-6 calendar\">\n @switch (view()) {\n @case ('year') {\n <si-year-selection\n [focusedDate]=\"actualFocusedDate()\"\n [startDate]=\"startDate\"\n [endDate]=\"endDate\"\n [minDate]=\"config().minDate\"\n [maxDate]=\"config().maxDate\"\n [minMonth]=\"minMonth()\"\n [maxMonth]=\"maxMonth()\"\n [isRangeSelection]=\"config().enableDateRange!\"\n [previousLabel]=\"previousLabel() | translate\"\n [nextLabel]=\"nextLabel() | translate\"\n (selectedValueChange)=\"activeYearChange($event)\"\n />\n }\n @case ('month') {\n <si-month-selection\n [startDate]=\"startDate\"\n [endDate]=\"endDate\"\n [months]=\"months\"\n [minDate]=\"config().minDate\"\n [maxDate]=\"config().maxDate\"\n [minMonth]=\"minMonth()\"\n [maxMonth]=\"maxMonth()\"\n [isRangeSelection]=\"config().enableDateRange!\"\n [previewRange]=\"rangeType() === 'END'\"\n [previousLabel]=\"previousLabel() | translate\"\n [nextLabel]=\"nextLabel() | translate\"\n [activeHover]=\"activeHover()\"\n [focusedDate]=\"actualFocusedDate()\"\n (activeHoverChange)=\"onActiveHoverChange($event)\"\n (focusedDateChange)=\"focusedDate.set($event)\"\n (selectedValueChange)=\"activeMonthChange($event)\"\n (viewChange)=\"view.set($event)\"\n />\n }\n @case ('week') {\n <si-day-selection\n [initialFocus]=\"forceFocus()\"\n [startDate]=\"startDate\"\n [endDate]=\"dateRange()?.end\"\n [isRangeSelection]=\"config().enableDateRange!\"\n [previewRange]=\"rangeType() === 'END'\"\n [hideWeekNumbers]=\"hideWeekNumbers\"\n [minDate]=\"config().minDate\"\n [maxDate]=\"config().maxDate\"\n [minMonth]=\"minMonth()\"\n [weekStartDay]=\"weekStartDay\"\n [calendarWeekLabel]=\"derivedWeekLabel()\"\n [previousLabel]=\"previousLabel() | translate\"\n [nextLabel]=\"nextLabel() | translate\"\n [todayLabel]=\"config().todayText\"\n [activeHover]=\"activeHover()\"\n [focusedDate]=\"actualFocusedDate()\"\n (activeHoverChange)=\"onActiveHoverChange($event)\"\n (focusedDateChange)=\"focusedDate.set($event)\"\n (selectedValueChange)=\"selectionChange($event!)\"\n (viewChange)=\"view.set($event)\"\n />\n }\n }\n </div>\n}\n@if (this.config().showTime) {\n <div\n class=\"timepicker-container px-9 pb-6\"\n [class.pt-6]=\"!hideCalendar()\"\n [class.border-top]=\"!hideCalendar()\"\n >\n @if (!config().mandatoryTime && !hideTimeToggle()) {\n <div class=\"mb-5 form-check form-switch\">\n <input\n type=\"checkbox\"\n class=\"form-check-input\"\n role=\"switch\"\n [id]=\"switchId\"\n [checked]=\"!disabledTime()\"\n (change)=\"toggleDisabledTime()\"\n />\n <label class=\"form-check-label\" [for]=\"switchId\">{{\n includeTimeLabel() | translate\n }}</label>\n </div>\n }\n <div class=\"mt-auto\">\n @if (timepickerLabel()) {\n <label class=\"form-label\" [for]=\"timepickerId\">{{ timepickerLabel() | translate }}</label>\n }\n <si-timepicker\n #timePicker\n [id]=\"timepickerId\"\n [formControl]=\"time\"\n [hoursLabel]=\"config().hoursLabel ?? timePicker.hoursLabel()\"\n [minutesLabel]=\"config().minutesLabel ?? timePicker.minutesLabel()\"\n [secondsLabel]=\"config().secondsLabel ?? timePicker.secondsLabel()\"\n [millisecondsLabel]=\"config().millisecondsLabel ?? timePicker.millisecondsLabel()\"\n [hideLabels]=\"config().hideLabels ?? timePicker.hideLabels()\"\n [hoursAriaLabel]=\"config().hoursAriaLabel ?? timePicker.hoursAriaLabel()\"\n [minutesAriaLabel]=\"config().minutesAriaLabel ?? timePicker.minutesAriaLabel()\"\n [secondsAriaLabel]=\"config().secondsAriaLabel ?? timePicker.secondsAriaLabel()\"\n [millisecondsAriaLabel]=\"\n config().millisecondsAriaLabel ?? timePicker.millisecondsAriaLabel()\n \"\n [hoursPlaceholder]=\"config().hoursPlaceholder ?? timePicker.hoursPlaceholder()\"\n [minutesPlaceholder]=\"config().minutesPlaceholder ?? timePicker.minutesPlaceholder()\"\n [secondsPlaceholder]=\"config().secondsPlaceholder ?? timePicker.secondsPlaceholder()\"\n [millisecondsPlaceholder]=\"\n config().millisecondsPlaceholder ?? timePicker.millisecondsPlaceholder()\n \"\n [meridians]=\"config().meridians ?? timePicker.meridians()\"\n [meridiansLabel]=\"config().meridiansLabel ?? timePicker.meridiansLabel()\"\n [meridiansAriaLabel]=\"config().meridiansAriaLabel ?? timePicker.meridiansAriaLabel()\"\n [showMinutes]=\"config().showMinutes ?? true\"\n [showSeconds]=\"config().showSeconds ?? false\"\n [showMilliseconds]=\"config().showMilliseconds ?? false\"\n [showMeridian]=\"time12h()\"\n />\n </div>\n </div>\n}\n", styles: [":host ::ng-deep .selection .month:not(.disabled):hover,:host ::ng-deep .selection .year:not(.disabled):hover,:host ::ng-deep .year:not(.disabled):not(.selected):hover,:host ::ng-deep .month:not(.disabled):not(.selected):hover,:host ::ng-deep .day:not(.disabled):not(.selected):hover{background:var(--element-base-1-hover);color:var(--element-ui-0)}:host ::ng-deep .year,:host ::ng-deep .month,:host ::ng-deep .day{block-size:32px;line-height:32px;inline-size:100%}:host ::ng-deep .day{inline-size:32px}:host ::ng-deep .year,:host ::ng-deep .month,:host ::ng-deep .day{margin-inline:auto;position:relative;border:unset;background-color:unset;padding:0;cursor:pointer;border-radius:var(--element-button-radius)}:host{background:var(--element-base-1);border-radius:var(--element-radius-2);display:flex;flex-direction:column;inline-size:348px}:host ::ng-deep .header,:host ::ng-deep .footer{display:flex;align-items:center}:host ::ng-deep .header{padding-block-start:12px;padding-block-end:16px;padding-inline:32px;border-block-end:1px solid var(--element-ui-4)}:host ::ng-deep .header a{text-decoration:none;cursor:pointer}:host ::ng-deep .footer{margin-block-start:4px;text-align:center}:host ::ng-deep table{inline-size:100%;border-collapse:separate;border-spacing:0 3px;table-layout:fixed;margin-block-end:-3px}:host ::ng-deep .day.selected{background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep .month.selected{background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep .year.selected{background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep td[role=gridcell]{text-align:center}:host ::ng-deep th{font-weight:400;text-align:center;block-size:32px}:host ::ng-deep .week-num,:host ::ng-deep th{font-size:.75rem;color:var(--element-text-secondary);inline-size:32px;cursor:default}:host ::ng-deep .today.selected:before{border-color:var(--element-ui-5)}:host ::ng-deep .today:before{position:absolute;content:\"\";inset:1px;border:1px solid var(--element-ui-1);border-radius:var(--element-radius-2);display:inline-block}:host ::ng-deep .selection .month,:host ::ng-deep .selection .year{block-size:30px;line-height:30px;cursor:pointer}:host ::ng-deep .selection .month{inline-size:50%}:host ::ng-deep .selection .year{inline-size:33.3%}:host ::ng-deep .disabled{color:var(--element-text-disabled);font-weight:400!important;cursor:default!important}:host ::ng-deep .range{background-color:var(--element-ui-4)}:host ::ng-deep .range:hover{background:var(--element-base-1-hover)}:host ::ng-deep .range:hover div.si-h4:hover{background:transparent}:host ::ng-deep .range-hover{background-color:var(--element-base-1-hover)}:host ::ng-deep .range-hover-end{border-start-end-radius:var(--element-button-radius);border-end-end-radius:var(--element-button-radius)}:host ::ng-deep td:is(.range-start,.range-end){background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep td:is(.range-start,.range-end) div.si-h4:hover,:host ::ng-deep td:is(.range-start,.range-end) div.si-body-lg:hover{background:transparent;color:var(--element-base-1)}:host ::ng-deep td:is(.range-start,.range-end) .today:before{border-color:var(--element-ui-5)}:host ::ng-deep td.range-start{border-start-start-radius:var(--element-button-radius);border-end-start-radius:var(--element-button-radius)}:host ::ng-deep td.range-end{border-start-end-radius:var(--element-button-radius);border-end-end-radius:var(--element-button-radius)}:host ::ng-deep .calendar-button{font-weight:600;font-size:.875rem;line-height:1.1428571429;color:var(--element-text-active);min-inline-size:0!important}:host ::ng-deep .calendar{block-size:28em}:host ::ng-deep .timepicker-container{display:flex;flex:1 1 auto;flex-direction:column}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: SiYearSelectionComponent, selector: "si-year-selection", inputs: ["focusedDate"], outputs: ["focusedDateChange", "yearRangeChange"] }, { kind: "component", type: SiMonthSelectionComponent, selector: "si-month-selection", inputs: ["months", "focusedDate"], outputs: ["focusedDateChange", "activeMonthChange", "viewChange"] }, { kind: "component", type: SiDaySelectionComponent, selector: "si-day-selection", inputs: ["hideWeekNumbers", "weekStartDay", "focusedDate", "todayLabel", "calendarWeekLabel"], outputs: ["focusedDateChange", "activeMonthChange", "viewChange"] }, { kind: "component", type: SiTimepickerComponent, selector: "si-timepicker", inputs: ["id", "disabled", "hoursLabel", "minutesLabel", "secondsLabel", "millisecondsLabel", "hideLabels", "hoursAriaLabel", "minutesAriaLabel", "secondsAriaLabel", "millisecondsAriaLabel", "hoursPlaceholder", "minutesPlaceholder", "secondsPlaceholder", "millisecondsPlaceholder", "meridians", "meridiansLabel", "meridiansAriaLabel", "showMinutes", "showSeconds", "showMilliseconds", "showMeridian", "min", "max", "readonly", "errormessageId"], outputs: ["isValid", "meridianChange", "inputCompleted"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }] });
|
|
3083
3079
|
}
|
|
3084
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
3080
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerComponent, decorators: [{
|
|
3085
3081
|
type: Component,
|
|
3086
3082
|
args: [{ selector: 'si-datepicker', imports: [
|
|
3087
3083
|
ReactiveFormsModule,
|
|
@@ -3091,21 +3087,21 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
|
|
|
3091
3087
|
SiTimepickerComponent,
|
|
3092
3088
|
SiTranslatePipe
|
|
3093
3089
|
], template: "@if (!hideCalendar()) {\n <div class=\"text-center pb-6 calendar\">\n @switch (view()) {\n @case ('year') {\n <si-year-selection\n [focusedDate]=\"actualFocusedDate()\"\n [startDate]=\"startDate\"\n [endDate]=\"endDate\"\n [minDate]=\"config().minDate\"\n [maxDate]=\"config().maxDate\"\n [minMonth]=\"minMonth()\"\n [maxMonth]=\"maxMonth()\"\n [isRangeSelection]=\"config().enableDateRange!\"\n [previousLabel]=\"previousLabel() | translate\"\n [nextLabel]=\"nextLabel() | translate\"\n (selectedValueChange)=\"activeYearChange($event)\"\n />\n }\n @case ('month') {\n <si-month-selection\n [startDate]=\"startDate\"\n [endDate]=\"endDate\"\n [months]=\"months\"\n [minDate]=\"config().minDate\"\n [maxDate]=\"config().maxDate\"\n [minMonth]=\"minMonth()\"\n [maxMonth]=\"maxMonth()\"\n [isRangeSelection]=\"config().enableDateRange!\"\n [previewRange]=\"rangeType() === 'END'\"\n [previousLabel]=\"previousLabel() | translate\"\n [nextLabel]=\"nextLabel() | translate\"\n [activeHover]=\"activeHover()\"\n [focusedDate]=\"actualFocusedDate()\"\n (activeHoverChange)=\"onActiveHoverChange($event)\"\n (focusedDateChange)=\"focusedDate.set($event)\"\n (selectedValueChange)=\"activeMonthChange($event)\"\n (viewChange)=\"view.set($event)\"\n />\n }\n @case ('week') {\n <si-day-selection\n [initialFocus]=\"forceFocus()\"\n [startDate]=\"startDate\"\n [endDate]=\"dateRange()?.end\"\n [isRangeSelection]=\"config().enableDateRange!\"\n [previewRange]=\"rangeType() === 'END'\"\n [hideWeekNumbers]=\"hideWeekNumbers\"\n [minDate]=\"config().minDate\"\n [maxDate]=\"config().maxDate\"\n [minMonth]=\"minMonth()\"\n [weekStartDay]=\"weekStartDay\"\n [calendarWeekLabel]=\"derivedWeekLabel()\"\n [previousLabel]=\"previousLabel() | translate\"\n [nextLabel]=\"nextLabel() | translate\"\n [todayLabel]=\"config().todayText\"\n [activeHover]=\"activeHover()\"\n [focusedDate]=\"actualFocusedDate()\"\n (activeHoverChange)=\"onActiveHoverChange($event)\"\n (focusedDateChange)=\"focusedDate.set($event)\"\n (selectedValueChange)=\"selectionChange($event!)\"\n (viewChange)=\"view.set($event)\"\n />\n }\n }\n </div>\n}\n@if (this.config().showTime) {\n <div\n class=\"timepicker-container px-9 pb-6\"\n [class.pt-6]=\"!hideCalendar()\"\n [class.border-top]=\"!hideCalendar()\"\n >\n @if (!config().mandatoryTime && !hideTimeToggle()) {\n <div class=\"mb-5 form-check form-switch\">\n <input\n type=\"checkbox\"\n class=\"form-check-input\"\n role=\"switch\"\n [id]=\"switchId\"\n [checked]=\"!disabledTime()\"\n (change)=\"toggleDisabledTime()\"\n />\n <label class=\"form-check-label\" [for]=\"switchId\">{{\n includeTimeLabel() | translate\n }}</label>\n </div>\n }\n <div class=\"mt-auto\">\n @if (timepickerLabel()) {\n <label class=\"form-label\" [for]=\"timepickerId\">{{ timepickerLabel() | translate }}</label>\n }\n <si-timepicker\n #timePicker\n [id]=\"timepickerId\"\n [formControl]=\"time\"\n [hoursLabel]=\"config().hoursLabel ?? timePicker.hoursLabel()\"\n [minutesLabel]=\"config().minutesLabel ?? timePicker.minutesLabel()\"\n [secondsLabel]=\"config().secondsLabel ?? timePicker.secondsLabel()\"\n [millisecondsLabel]=\"config().millisecondsLabel ?? timePicker.millisecondsLabel()\"\n [hideLabels]=\"config().hideLabels ?? timePicker.hideLabels()\"\n [hoursAriaLabel]=\"config().hoursAriaLabel ?? timePicker.hoursAriaLabel()\"\n [minutesAriaLabel]=\"config().minutesAriaLabel ?? timePicker.minutesAriaLabel()\"\n [secondsAriaLabel]=\"config().secondsAriaLabel ?? timePicker.secondsAriaLabel()\"\n [millisecondsAriaLabel]=\"\n config().millisecondsAriaLabel ?? timePicker.millisecondsAriaLabel()\n \"\n [hoursPlaceholder]=\"config().hoursPlaceholder ?? timePicker.hoursPlaceholder()\"\n [minutesPlaceholder]=\"config().minutesPlaceholder ?? timePicker.minutesPlaceholder()\"\n [secondsPlaceholder]=\"config().secondsPlaceholder ?? timePicker.secondsPlaceholder()\"\n [millisecondsPlaceholder]=\"\n config().millisecondsPlaceholder ?? timePicker.millisecondsPlaceholder()\n \"\n [meridians]=\"config().meridians ?? timePicker.meridians()\"\n [meridiansLabel]=\"config().meridiansLabel ?? timePicker.meridiansLabel()\"\n [meridiansAriaLabel]=\"config().meridiansAriaLabel ?? timePicker.meridiansAriaLabel()\"\n [showMinutes]=\"config().showMinutes ?? true\"\n [showSeconds]=\"config().showSeconds ?? false\"\n [showMilliseconds]=\"config().showMilliseconds ?? false\"\n [showMeridian]=\"time12h()\"\n />\n </div>\n </div>\n}\n", styles: [":host ::ng-deep .selection .month:not(.disabled):hover,:host ::ng-deep .selection .year:not(.disabled):hover,:host ::ng-deep .year:not(.disabled):not(.selected):hover,:host ::ng-deep .month:not(.disabled):not(.selected):hover,:host ::ng-deep .day:not(.disabled):not(.selected):hover{background:var(--element-base-1-hover);color:var(--element-ui-0)}:host ::ng-deep .year,:host ::ng-deep .month,:host ::ng-deep .day{block-size:32px;line-height:32px;inline-size:100%}:host ::ng-deep .day{inline-size:32px}:host ::ng-deep .year,:host ::ng-deep .month,:host ::ng-deep .day{margin-inline:auto;position:relative;border:unset;background-color:unset;padding:0;cursor:pointer;border-radius:var(--element-button-radius)}:host{background:var(--element-base-1);border-radius:var(--element-radius-2);display:flex;flex-direction:column;inline-size:348px}:host ::ng-deep .header,:host ::ng-deep .footer{display:flex;align-items:center}:host ::ng-deep .header{padding-block-start:12px;padding-block-end:16px;padding-inline:32px;border-block-end:1px solid var(--element-ui-4)}:host ::ng-deep .header a{text-decoration:none;cursor:pointer}:host ::ng-deep .footer{margin-block-start:4px;text-align:center}:host ::ng-deep table{inline-size:100%;border-collapse:separate;border-spacing:0 3px;table-layout:fixed;margin-block-end:-3px}:host ::ng-deep .day.selected{background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep .month.selected{background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep .year.selected{background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep td[role=gridcell]{text-align:center}:host ::ng-deep th{font-weight:400;text-align:center;block-size:32px}:host ::ng-deep .week-num,:host ::ng-deep th{font-size:.75rem;color:var(--element-text-secondary);inline-size:32px;cursor:default}:host ::ng-deep .today.selected:before{border-color:var(--element-ui-5)}:host ::ng-deep .today:before{position:absolute;content:\"\";inset:1px;border:1px solid var(--element-ui-1);border-radius:var(--element-radius-2);display:inline-block}:host ::ng-deep .selection .month,:host ::ng-deep .selection .year{block-size:30px;line-height:30px;cursor:pointer}:host ::ng-deep .selection .month{inline-size:50%}:host ::ng-deep .selection .year{inline-size:33.3%}:host ::ng-deep .disabled{color:var(--element-text-disabled);font-weight:400!important;cursor:default!important}:host ::ng-deep .range{background-color:var(--element-ui-4)}:host ::ng-deep .range:hover{background:var(--element-base-1-hover)}:host ::ng-deep .range:hover div.si-h4:hover{background:transparent}:host ::ng-deep .range-hover{background-color:var(--element-base-1-hover)}:host ::ng-deep .range-hover-end{border-start-end-radius:var(--element-button-radius);border-end-end-radius:var(--element-button-radius)}:host ::ng-deep td:is(.range-start,.range-end){background:var(--element-ui-0);color:var(--element-base-1)}:host ::ng-deep td:is(.range-start,.range-end) div.si-h4:hover,:host ::ng-deep td:is(.range-start,.range-end) div.si-body-lg:hover{background:transparent;color:var(--element-base-1)}:host ::ng-deep td:is(.range-start,.range-end) .today:before{border-color:var(--element-ui-5)}:host ::ng-deep td.range-start{border-start-start-radius:var(--element-button-radius);border-end-start-radius:var(--element-button-radius)}:host ::ng-deep td.range-end{border-start-end-radius:var(--element-button-radius);border-end-end-radius:var(--element-button-radius)}:host ::ng-deep .calendar-button{font-weight:600;font-size:.875rem;line-height:1.1428571429;color:var(--element-text-active);min-inline-size:0!important}:host ::ng-deep .calendar{block-size:28em}:host ::ng-deep .timepicker-container{display:flex;flex:1 1 auto;flex-direction:column}\n"] }]
|
|
3094
|
-
}], ctorParameters: () => [] });
|
|
3090
|
+
}], ctorParameters: () => [], propDecorators: { focusedDate: [{ type: i0.Input, args: [{ isSignal: true, alias: "focusedDate", required: false }] }, { type: i0.Output, args: ["focusedDateChange"] }], date: [{ type: i0.Input, args: [{ isSignal: true, alias: "date", required: false }] }, { type: i0.Output, args: ["dateChange"] }], dateRange: [{ type: i0.Input, args: [{ isSignal: true, alias: "dateRange", required: false }] }, { type: i0.Output, args: ["dateRangeChange"] }], dateRangeRole: [{ type: i0.Input, args: [{ isSignal: true, alias: "dateRangeRole", required: false }] }], initialFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialFocus", required: false }] }], disabledTime: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabledTime", required: false }] }, { type: i0.Output, args: ["disabledTimeChange"] }], config: [{ type: i0.Input, args: [{ isSignal: true, alias: "config", required: false }] }, { type: i0.Output, args: ["configChange"] }], previousLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "previousLabel", required: false }] }], nextLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "nextLabel", required: false }] }], calenderWeekLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "calenderWeekLabel", required: false }] }], calendarWeekLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "calendarWeekLabel", required: false }] }], time12h: [{ type: i0.Input, args: [{ isSignal: true, alias: "time12h", required: false }] }], rangeType: [{ type: i0.Input, args: [{ isSignal: true, alias: "rangeType", required: false }] }, { type: i0.Output, args: ["rangeTypeChange"] }], minMonth: [{ type: i0.Input, args: [{ isSignal: true, alias: "minMonth", required: false }] }], maxMonth: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxMonth", required: false }] }], hideTimeToggle: [{ type: i0.Input, args: [{ isSignal: true, alias: "hideTimeToggle", required: false }] }], hideCalendar: [{ type: i0.Input, args: [{ isSignal: true, alias: "hideCalendar", required: false }] }], timepickerLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "timepickerLabel", required: false }] }], daySelection: [{ type: i0.ViewChild, args: [i0.forwardRef(() => SiDaySelectionComponent), { isSignal: true }] }], monthSelection: [{ type: i0.ViewChild, args: [i0.forwardRef(() => SiMonthSelectionComponent), { isSignal: true }] }], yearSelection: [{ type: i0.ViewChild, args: [i0.forwardRef(() => SiYearSelectionComponent), { isSignal: true }] }], activeHover: [{ type: i0.Input, args: [{ isSignal: true, alias: "activeHover", required: false }] }, { type: i0.Output, args: ["activeHoverChange"] }] } });
|
|
3095
3091
|
|
|
3096
3092
|
/**
|
|
3097
3093
|
* Copyright (c) Siemens 2016 - 2025
|
|
3098
3094
|
* SPDX-License-Identifier: MIT
|
|
3099
3095
|
*/
|
|
3100
3096
|
class SiDatepickerOverlayComponent {
|
|
3101
|
-
minMonth = signal(undefined);
|
|
3102
|
-
maxMonth = signal(undefined);
|
|
3097
|
+
minMonth = signal(undefined, ...(ngDevMode ? [{ debugName: "minMonth" }] : []));
|
|
3098
|
+
maxMonth = signal(undefined, ...(ngDevMode ? [{ debugName: "maxMonth" }] : []));
|
|
3103
3099
|
datepicker = viewChild.required(SiDatepickerComponent);
|
|
3104
3100
|
/**
|
|
3105
3101
|
* {@inheritDoc SiDatepickerComponent#initialFocus}
|
|
3106
3102
|
* @defaultValue false
|
|
3107
3103
|
*/
|
|
3108
|
-
initialFocus = input(false, { transform: booleanAttribute });
|
|
3104
|
+
initialFocus = input(false, { ...(ngDevMode ? { debugName: "initialFocus" } : {}), transform: booleanAttribute });
|
|
3109
3105
|
/**
|
|
3110
3106
|
* {@inheritDoc SiDatepickerComponent#config}
|
|
3111
3107
|
* @defaultValue
|
|
@@ -3113,24 +3109,24 @@ class SiDatepickerOverlayComponent {
|
|
|
3113
3109
|
* {}
|
|
3114
3110
|
* ```
|
|
3115
3111
|
*/
|
|
3116
|
-
config = input({});
|
|
3112
|
+
config = input({}, ...(ngDevMode ? [{ debugName: "config" }] : []));
|
|
3117
3113
|
/**
|
|
3118
3114
|
* {@inheritDoc SiDatepickerComponent#date}
|
|
3119
3115
|
*/
|
|
3120
|
-
date = model();
|
|
3116
|
+
date = model(...(ngDevMode ? [undefined, { debugName: "date" }] : []));
|
|
3121
3117
|
/**
|
|
3122
3118
|
* {@inheritDoc SiDatepickerComponent#dateRange}
|
|
3123
3119
|
*/
|
|
3124
|
-
dateRange = model();
|
|
3120
|
+
dateRange = model(...(ngDevMode ? [undefined, { debugName: "dateRange" }] : []));
|
|
3125
3121
|
/**
|
|
3126
3122
|
* {@inheritDoc SiDatepickerComponent#rangeType}
|
|
3127
3123
|
*/
|
|
3128
|
-
rangeType = model();
|
|
3124
|
+
rangeType = model(...(ngDevMode ? [undefined, { debugName: "rangeType" }] : []));
|
|
3129
3125
|
/**
|
|
3130
3126
|
* {@inheritDoc SiDatepickerComponent#time12h}
|
|
3131
3127
|
* @defaultValue false
|
|
3132
3128
|
*/
|
|
3133
|
-
time12h = input(false, { transform: booleanAttribute });
|
|
3129
|
+
time12h = input(false, { ...(ngDevMode ? { debugName: "time12h" } : {}), transform: booleanAttribute });
|
|
3134
3130
|
/**
|
|
3135
3131
|
* Emits an event to notify about disabling the time from the datepicker.
|
|
3136
3132
|
* When time is disable, we construct a pure date object in UTC 00:00:00 time.
|
|
@@ -3145,17 +3141,17 @@ class SiDatepickerOverlayComponent {
|
|
|
3145
3141
|
disableTime = false;
|
|
3146
3142
|
activeHover;
|
|
3147
3143
|
isTwoMonthDateRange = computed(() => !!this.config().enableDateRange &&
|
|
3148
|
-
(!!this.config().enableTwoMonthDateRange || !!this.config().showTime));
|
|
3149
|
-
firstDatepickerConfig = signal({});
|
|
3150
|
-
secondDatepickerConfig = signal({});
|
|
3144
|
+
(!!this.config().enableTwoMonthDateRange || !!this.config().showTime), ...(ngDevMode ? [{ debugName: "isTwoMonthDateRange" }] : []));
|
|
3145
|
+
firstDatepickerConfig = signal({}, ...(ngDevMode ? [{ debugName: "firstDatepickerConfig" }] : []));
|
|
3146
|
+
secondDatepickerConfig = signal({}, ...(ngDevMode ? [{ debugName: "secondDatepickerConfig" }] : []));
|
|
3151
3147
|
/**
|
|
3152
3148
|
* Indicate that the overlay is opened in small screen.
|
|
3153
3149
|
* A modal dialog animation display when true and a wrapped two month calendar layout is displayed.
|
|
3154
3150
|
*
|
|
3155
3151
|
* @defaultValue false
|
|
3156
3152
|
*/
|
|
3157
|
-
isMobile = input(false);
|
|
3158
|
-
completeAnimation = signal(false);
|
|
3153
|
+
isMobile = input(false, ...(ngDevMode ? [{ debugName: "isMobile" }] : []));
|
|
3154
|
+
completeAnimation = signal(false, ...(ngDevMode ? [{ debugName: "completeAnimation" }] : []));
|
|
3159
3155
|
ngOnChanges(changes) {
|
|
3160
3156
|
if (changes.config) {
|
|
3161
3157
|
const config = this.config();
|
|
@@ -3214,8 +3210,8 @@ class SiDatepickerOverlayComponent {
|
|
|
3214
3210
|
}
|
|
3215
3211
|
}
|
|
3216
3212
|
}
|
|
3217
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
3218
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
3213
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerOverlayComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3214
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiDatepickerOverlayComponent, isStandalone: true, selector: "si-datepicker-overlay", inputs: { initialFocus: { classPropertyName: "initialFocus", publicName: "initialFocus", isSignal: true, isRequired: false, transformFunction: null }, config: { classPropertyName: "config", publicName: "config", isSignal: true, isRequired: false, transformFunction: null }, date: { classPropertyName: "date", publicName: "date", isSignal: true, isRequired: false, transformFunction: null }, dateRange: { classPropertyName: "dateRange", publicName: "dateRange", isSignal: true, isRequired: false, transformFunction: null }, rangeType: { classPropertyName: "rangeType", publicName: "rangeType", isSignal: true, isRequired: false, transformFunction: null }, time12h: { classPropertyName: "time12h", publicName: "time12h", isSignal: true, isRequired: false, transformFunction: null }, isMobile: { classPropertyName: "isMobile", publicName: "isMobile", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { date: "dateChange", dateRange: "dateRangeChange", rangeType: "rangeTypeChange", disabledTimeChange: "disabledTimeChange" }, host: { properties: { "class.flex-wrap": "isMobile()", "class.mobile-datepicker-overlay": "isMobile()", "class.fade": "isMobile()", "class.show": "completeAnimation()" }, classAttribute: "mt-md-1 d-flex elevation-2 rounded-2 overflow-auto align-items-stretch" }, viewQueries: [{ propertyName: "datepicker", first: true, predicate: SiDatepickerComponent, descendants: true, isSignal: true }], usesOnChanges: true, ngImport: i0, template: `
|
|
3219
3215
|
<si-datepicker
|
|
3220
3216
|
#datepicker
|
|
3221
3217
|
tabindex="-1"
|
|
@@ -3264,7 +3260,7 @@ class SiDatepickerOverlayComponent {
|
|
|
3264
3260
|
}
|
|
3265
3261
|
`, isInline: true, styles: [":host{max-block-size:max-content;max-inline-size:min-content}:host.fade{transition:transform calc(.3s * var(--element-animations-enabled, 1)) ease-out;transform:translateY(-50px)}:host.show{transform:none}.mobile-datepicker-overlay{max-inline-size:348px}.first-datepicker{border-inline-end:0;border-start-end-radius:0;border-end-end-radius:0}.second-datepicker{border-inline-start:0;border-start-start-radius:0;border-end-start-radius:0}.first-datepicker-mobile{border-block-end:0;border-end-start-radius:0;border-end-end-radius:0}.second-datepicker-mobile{border-block-start:0;border-start-start-radius:0;border-start-end-radius:0}\n"], dependencies: [{ kind: "component", type: SiDatepickerComponent, selector: "si-datepicker", inputs: ["focusedDate", "date", "dateRange", "dateRangeRole", "initialFocus", "disabledTime", "config", "previousLabel", "nextLabel", "calenderWeekLabel", "calendarWeekLabel", "time12h", "rangeType", "minMonth", "maxMonth", "hideTimeToggle", "hideCalendar", "timepickerLabel", "activeHover"], outputs: ["focusedDateChange", "dateChange", "dateRangeChange", "disabledTimeChange", "configChange", "rangeTypeChange", "activeHoverChange"] }, { kind: "ngmodule", type: A11yModule }], changeDetection: i0.ChangeDetectionStrategy.Default });
|
|
3266
3262
|
}
|
|
3267
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
3263
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerOverlayComponent, decorators: [{
|
|
3268
3264
|
type: Component,
|
|
3269
3265
|
args: [{ selector: 'si-datepicker-overlay', imports: [SiDatepickerComponent, A11yModule], template: `
|
|
3270
3266
|
<si-datepicker
|
|
@@ -3320,7 +3316,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
|
|
|
3320
3316
|
'[class.fade]': 'isMobile()',
|
|
3321
3317
|
'[class.show]': 'completeAnimation()'
|
|
3322
3318
|
}, styles: [":host{max-block-size:max-content;max-inline-size:min-content}:host.fade{transition:transform calc(.3s * var(--element-animations-enabled, 1)) ease-out;transform:translateY(-50px)}:host.show{transform:none}.mobile-datepicker-overlay{max-inline-size:348px}.first-datepicker{border-inline-end:0;border-start-end-radius:0;border-end-end-radius:0}.second-datepicker{border-inline-start:0;border-start-start-radius:0;border-end-start-radius:0}.first-datepicker-mobile{border-block-end:0;border-end-start-radius:0;border-end-end-radius:0}.second-datepicker-mobile{border-block-start:0;border-start-start-radius:0;border-start-end-radius:0}\n"] }]
|
|
3323
|
-
}] });
|
|
3319
|
+
}], propDecorators: { datepicker: [{ type: i0.ViewChild, args: [i0.forwardRef(() => SiDatepickerComponent), { isSignal: true }] }], initialFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialFocus", required: false }] }], config: [{ type: i0.Input, args: [{ isSignal: true, alias: "config", required: false }] }], date: [{ type: i0.Input, args: [{ isSignal: true, alias: "date", required: false }] }, { type: i0.Output, args: ["dateChange"] }], dateRange: [{ type: i0.Input, args: [{ isSignal: true, alias: "dateRange", required: false }] }, { type: i0.Output, args: ["dateRangeChange"] }], rangeType: [{ type: i0.Input, args: [{ isSignal: true, alias: "rangeType", required: false }] }, { type: i0.Output, args: ["rangeTypeChange"] }], time12h: [{ type: i0.Input, args: [{ isSignal: true, alias: "time12h", required: false }] }], disabledTimeChange: [{ type: i0.Output, args: ["disabledTimeChange"] }], isMobile: [{ type: i0.Input, args: [{ isSignal: true, alias: "isMobile", required: false }] }] } });
|
|
3324
3320
|
|
|
3325
3321
|
/**
|
|
3326
3322
|
* Copyright (c) Siemens 2016 - 2025
|
|
@@ -3358,7 +3354,7 @@ class SiDatepickerOverlayDirective {
|
|
|
3358
3354
|
originX: 'start',
|
|
3359
3355
|
originY: 'top'
|
|
3360
3356
|
}
|
|
3361
|
-
]);
|
|
3357
|
+
], ...(ngDevMode ? [{ debugName: "placement" }] : []));
|
|
3362
3358
|
/**
|
|
3363
3359
|
* Output event on closing datepicker e.g. by clicking backdrop or escape key.
|
|
3364
3360
|
*/
|
|
@@ -3513,16 +3509,16 @@ class SiDatepickerOverlayDirective {
|
|
|
3513
3509
|
return merge(this.autoCloseSelection.pipe(map(() => CloseCause.Select)), overlayRef.backdropClick().pipe(map(() => CloseCause.Backdrop)), overlayRef.detachments().pipe(map(() => CloseCause.Detach)), overlayRef.keydownEvents().pipe(filter(event => event.key === 'Escape'), tap(event => event.stopPropagation()), // ESC handled, prevent closing modal, etc.
|
|
3514
3510
|
map(() => CloseCause.Escape)));
|
|
3515
3511
|
}
|
|
3516
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
3517
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
3512
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerOverlayDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
3513
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.0.8", type: SiDatepickerOverlayDirective, isStandalone: true, selector: "[siDatepickerOverlay]", outputs: { siDatepickerClose: "siDatepickerClose" }, exportAs: ["siDatepickerOverlay"], ngImport: i0 });
|
|
3518
3514
|
}
|
|
3519
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
3515
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerOverlayDirective, decorators: [{
|
|
3520
3516
|
type: Directive,
|
|
3521
3517
|
args: [{
|
|
3522
3518
|
selector: '[siDatepickerOverlay]',
|
|
3523
3519
|
exportAs: 'siDatepickerOverlay'
|
|
3524
3520
|
}]
|
|
3525
|
-
}] });
|
|
3521
|
+
}], propDecorators: { siDatepickerClose: [{ type: i0.Output, args: ["siDatepickerClose"] }] } });
|
|
3526
3522
|
|
|
3527
3523
|
/**
|
|
3528
3524
|
* Copyright (c) Siemens 2016 - 2025
|
|
@@ -3536,7 +3532,7 @@ class SiDatepickerDirective extends SiDateInputDirective {
|
|
|
3536
3532
|
*
|
|
3537
3533
|
* @defaultValue false
|
|
3538
3534
|
*/
|
|
3539
|
-
autoClose = input(false, { transform: booleanAttribute });
|
|
3535
|
+
autoClose = input(false, { ...(ngDevMode ? { debugName: "autoClose" } : {}), transform: booleanAttribute });
|
|
3540
3536
|
/**
|
|
3541
3537
|
* During focus on close the datepicker will not show since we recover the focus on element.
|
|
3542
3538
|
* The focus on close is only relevant when the directive is configured without a calendar button.
|
|
@@ -3621,8 +3617,8 @@ class SiDatepickerDirective extends SiDateInputDirective {
|
|
|
3621
3617
|
setTimeout(() => this.overlayToggle.closeAfterSelection());
|
|
3622
3618
|
}
|
|
3623
3619
|
}
|
|
3624
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
3625
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
3620
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
3621
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.0.8", type: SiDatepickerDirective, isStandalone: true, selector: "[siDatepicker]", inputs: { autoClose: { classPropertyName: "autoClose", publicName: "autoClose", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "click": "onClick()", "keydown.tab": "onTab()", "focus": "focusChange()" } }, providers: [
|
|
3626
3622
|
{
|
|
3627
3623
|
provide: NG_VALUE_ACCESSOR,
|
|
3628
3624
|
useExisting: SiDatepickerDirective,
|
|
@@ -3639,7 +3635,7 @@ class SiDatepickerDirective extends SiDateInputDirective {
|
|
|
3639
3635
|
}
|
|
3640
3636
|
], exportAs: ["siDatepicker"], usesInheritance: true, hostDirectives: [{ directive: SiDatepickerOverlayDirective, outputs: ["siDatepickerClose", "siDatepickerClose"] }], ngImport: i0 });
|
|
3641
3637
|
}
|
|
3642
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
3638
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerDirective, decorators: [{
|
|
3643
3639
|
type: Directive,
|
|
3644
3640
|
args: [{
|
|
3645
3641
|
selector: '[siDatepicker]',
|
|
@@ -3667,7 +3663,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
|
|
|
3667
3663
|
],
|
|
3668
3664
|
exportAs: 'siDatepicker'
|
|
3669
3665
|
}]
|
|
3670
|
-
}], propDecorators: { onClick: [{
|
|
3666
|
+
}], propDecorators: { autoClose: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoClose", required: false }] }], onClick: [{
|
|
3671
3667
|
type: HostListener,
|
|
3672
3668
|
args: ['click']
|
|
3673
3669
|
}], onTab: [{
|
|
@@ -3684,7 +3680,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
|
|
|
3684
3680
|
*/
|
|
3685
3681
|
class SiDateRangeComponent {
|
|
3686
3682
|
static idCounter = 0;
|
|
3687
|
-
inputDirectives = viewChildren(SiDateInputDirective);
|
|
3683
|
+
inputDirectives = viewChildren(SiDateInputDirective, ...(ngDevMode ? [{ debugName: "inputDirectives" }] : []));
|
|
3688
3684
|
startInput = viewChild.required('startInput');
|
|
3689
3685
|
endInput = viewChild.required('endInput');
|
|
3690
3686
|
button = viewChild.required('button');
|
|
@@ -3694,7 +3690,7 @@ class SiDateRangeComponent {
|
|
|
3694
3690
|
* `__si-date-range-${SiDateRangeComponent.idCounter++}`
|
|
3695
3691
|
* ```
|
|
3696
3692
|
*/
|
|
3697
|
-
id = input(`__si-date-range-${SiDateRangeComponent.idCounter++}
|
|
3693
|
+
id = input(`__si-date-range-${SiDateRangeComponent.idCounter++}`, ...(ngDevMode ? [{ debugName: "id" }] : []));
|
|
3698
3694
|
labelledby = inject(new HostAttributeToken('aria-labelledby'), {
|
|
3699
3695
|
optional: true
|
|
3700
3696
|
}) ?? `${this.id()}-label`;
|
|
@@ -3706,7 +3702,7 @@ class SiDateRangeComponent {
|
|
|
3706
3702
|
* { enableDateRange: true }
|
|
3707
3703
|
* ```
|
|
3708
3704
|
*/
|
|
3709
|
-
siDatepickerConfig = model({ enableDateRange: true });
|
|
3705
|
+
siDatepickerConfig = model({ enableDateRange: true }, ...(ngDevMode ? [{ debugName: "siDatepickerConfig" }] : []));
|
|
3710
3706
|
/**
|
|
3711
3707
|
* Placeholder of the start date input.
|
|
3712
3708
|
*
|
|
@@ -3715,7 +3711,7 @@ class SiDateRangeComponent {
|
|
|
3715
3711
|
* t(() => $localize`:@@SI_DATEPICKER.START_DATE_PLACEHOLDER:Start date`)
|
|
3716
3712
|
* ```
|
|
3717
3713
|
*/
|
|
3718
|
-
startDatePlaceholder = input(t(() => $localize `:@@SI_DATEPICKER.START_DATE_PLACEHOLDER:Start date`));
|
|
3714
|
+
startDatePlaceholder = input(t(() => $localize `:@@SI_DATEPICKER.START_DATE_PLACEHOLDER:Start date`), ...(ngDevMode ? [{ debugName: "startDatePlaceholder" }] : []));
|
|
3719
3715
|
/**
|
|
3720
3716
|
* Placeholder of the end date input.
|
|
3721
3717
|
*
|
|
@@ -3724,7 +3720,7 @@ class SiDateRangeComponent {
|
|
|
3724
3720
|
* t(() => $localize`:@@SI_DATEPICKER.END_DATE_PLACEHOLDER:End date`)
|
|
3725
3721
|
* ```
|
|
3726
3722
|
*/
|
|
3727
|
-
endDatePlaceholder = input(t(() => $localize `:@@SI_DATEPICKER.END_DATE_PLACEHOLDER:End date`));
|
|
3723
|
+
endDatePlaceholder = input(t(() => $localize `:@@SI_DATEPICKER.END_DATE_PLACEHOLDER:End date`), ...(ngDevMode ? [{ debugName: "endDatePlaceholder" }] : []));
|
|
3728
3724
|
/**
|
|
3729
3725
|
* Aria label of the date-range calendar toggle button.
|
|
3730
3726
|
*
|
|
@@ -3733,7 +3729,7 @@ class SiDateRangeComponent {
|
|
|
3733
3729
|
* t(() => $localize`:@@SI_DATEPICKER.CALENDAR_TOGGLE_BUTTON:Open calendar`)
|
|
3734
3730
|
* ```
|
|
3735
3731
|
*/
|
|
3736
|
-
ariaLabelCalendarButton = input(t(() => $localize `:@@SI_DATEPICKER.CALENDAR_TOGGLE_BUTTON:Open calendar`));
|
|
3732
|
+
ariaLabelCalendarButton = input(t(() => $localize `:@@SI_DATEPICKER.CALENDAR_TOGGLE_BUTTON:Open calendar`), ...(ngDevMode ? [{ debugName: "ariaLabelCalendarButton" }] : []));
|
|
3737
3733
|
/**
|
|
3738
3734
|
* Form label of the start timepicker.
|
|
3739
3735
|
*
|
|
@@ -3742,7 +3738,7 @@ class SiDateRangeComponent {
|
|
|
3742
3738
|
* t(() => $localize`:@@SI_DATEPICKER.START_TIME_LABEL:from`)
|
|
3743
3739
|
* ```
|
|
3744
3740
|
*/
|
|
3745
|
-
startTimeLabel = input(t(() => $localize `:@@SI_DATEPICKER.START_TIME_LABEL:from`));
|
|
3741
|
+
startTimeLabel = input(t(() => $localize `:@@SI_DATEPICKER.START_TIME_LABEL:from`), ...(ngDevMode ? [{ debugName: "startTimeLabel" }] : []));
|
|
3746
3742
|
/**
|
|
3747
3743
|
* Form label of the start timepicker.
|
|
3748
3744
|
*
|
|
@@ -3751,13 +3747,13 @@ class SiDateRangeComponent {
|
|
|
3751
3747
|
* t(() => $localize`:@@SI_DATEPICKER.END_TIME_LABEL:to`)
|
|
3752
3748
|
* ```
|
|
3753
3749
|
*/
|
|
3754
|
-
endTimeLabel = input(t(() => $localize `:@@SI_DATEPICKER.END_TIME_LABEL:to`));
|
|
3750
|
+
endTimeLabel = input(t(() => $localize `:@@SI_DATEPICKER.END_TIME_LABEL:to`), ...(ngDevMode ? [{ debugName: "endTimeLabel" }] : []));
|
|
3755
3751
|
/**
|
|
3756
3752
|
* Automatically close overlay on date selection.
|
|
3757
3753
|
*
|
|
3758
3754
|
* @defaultValue false
|
|
3759
3755
|
*/
|
|
3760
|
-
autoClose = input(false, { transform: booleanAttribute });
|
|
3756
|
+
autoClose = input(false, { ...(ngDevMode ? { debugName: "autoClose" } : {}), transform: booleanAttribute });
|
|
3761
3757
|
/** Emits on the date range value changes. */
|
|
3762
3758
|
siDatepickerRangeChange = output();
|
|
3763
3759
|
/**
|
|
@@ -3771,18 +3767,18 @@ class SiDateRangeComponent {
|
|
|
3771
3767
|
* @defaultValue false
|
|
3772
3768
|
*/
|
|
3773
3769
|
// eslint-disable-next-line @angular-eslint/no-input-rename
|
|
3774
|
-
disabledInput = input(false, { alias: 'disabled' });
|
|
3770
|
+
disabledInput = input(false, { ...(ngDevMode ? { debugName: "disabledInput" } : {}), alias: 'disabled' });
|
|
3775
3771
|
/**
|
|
3776
3772
|
* Whether the date range input is readonly.
|
|
3777
3773
|
*
|
|
3778
3774
|
* @defaultValue false
|
|
3779
3775
|
*/
|
|
3780
|
-
readonly = input(false, { transform: booleanAttribute });
|
|
3776
|
+
readonly = input(false, { ...(ngDevMode ? { debugName: "readonly" } : {}), transform: booleanAttribute });
|
|
3781
3777
|
/**
|
|
3782
3778
|
* Set the date-range object displayed in the control.
|
|
3783
3779
|
* The input can be used if the control is used outside Angular forms.
|
|
3784
3780
|
*/
|
|
3785
|
-
value = model();
|
|
3781
|
+
value = model(...(ngDevMode ? [undefined, { debugName: "value" }] : []));
|
|
3786
3782
|
/**
|
|
3787
3783
|
* This ID will be bound to the `aria-describedby` attribute of the date-range.
|
|
3788
3784
|
* Use this to reference the element containing the error message(s) for the date-range.
|
|
@@ -3793,13 +3789,13 @@ class SiDateRangeComponent {
|
|
|
3793
3789
|
* `${this.id()}-errormessage`
|
|
3794
3790
|
* ```
|
|
3795
3791
|
*/
|
|
3796
|
-
errormessageId = input(`${this.id()}-errormessage
|
|
3792
|
+
errormessageId = input(`${this.id()}-errormessage`, ...(ngDevMode ? [{ debugName: "errormessageId" }] : []));
|
|
3797
3793
|
validator;
|
|
3798
3794
|
onChange = (val) => { };
|
|
3799
3795
|
onTouch = () => { };
|
|
3800
3796
|
icons = addIcons({ elementCalendar });
|
|
3801
|
-
disabled = computed(() => this.disabledInput() || this.disabledNgControl());
|
|
3802
|
-
disabledNgControl = signal(false);
|
|
3797
|
+
disabled = computed(() => this.disabledInput() || this.disabledNgControl(), ...(ngDevMode ? [{ debugName: "disabled" }] : []));
|
|
3798
|
+
disabledNgControl = signal(false, ...(ngDevMode ? [{ debugName: "disabledNgControl" }] : []));
|
|
3803
3799
|
cdRef = inject(ChangeDetectorRef);
|
|
3804
3800
|
locale = inject(LOCALE_ID).toString();
|
|
3805
3801
|
overlayToggle = inject(SiDatepickerOverlayDirective);
|
|
@@ -3940,10 +3936,10 @@ class SiDateRangeComponent {
|
|
|
3940
3936
|
errors[`invalid${type}DateFormat`] = formatError;
|
|
3941
3937
|
}
|
|
3942
3938
|
const minError = control.getError('minDate');
|
|
3943
|
-
const siDatepickerConfig = this.siDatepickerConfig();
|
|
3944
3939
|
if (minError) {
|
|
3945
3940
|
errors.rangeBeforeMinDate = {
|
|
3946
|
-
min:
|
|
3941
|
+
min: minError.min,
|
|
3942
|
+
minString: minError.minString,
|
|
3947
3943
|
start: this.startInput().value,
|
|
3948
3944
|
end: this.endInput().value
|
|
3949
3945
|
};
|
|
@@ -3951,7 +3947,8 @@ class SiDateRangeComponent {
|
|
|
3951
3947
|
const maxError = control.getError('maxDate');
|
|
3952
3948
|
if (maxError) {
|
|
3953
3949
|
errors.rangeAfterMaxDate = {
|
|
3954
|
-
max:
|
|
3950
|
+
max: maxError.max,
|
|
3951
|
+
maxString: maxError.maxString,
|
|
3955
3952
|
start: this.startInput().value,
|
|
3956
3953
|
end: this.endInput().value
|
|
3957
3954
|
};
|
|
@@ -3967,8 +3964,8 @@ class SiDateRangeComponent {
|
|
|
3967
3964
|
this.value.set(value);
|
|
3968
3965
|
}
|
|
3969
3966
|
}
|
|
3970
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
3971
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "
|
|
3967
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDateRangeComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
3968
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "21.0.8", type: SiDateRangeComponent, isStandalone: true, selector: "si-date-range", inputs: { id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, siDatepickerConfig: { classPropertyName: "siDatepickerConfig", publicName: "siDatepickerConfig", isSignal: true, isRequired: false, transformFunction: null }, startDatePlaceholder: { classPropertyName: "startDatePlaceholder", publicName: "startDatePlaceholder", isSignal: true, isRequired: false, transformFunction: null }, endDatePlaceholder: { classPropertyName: "endDatePlaceholder", publicName: "endDatePlaceholder", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelCalendarButton: { classPropertyName: "ariaLabelCalendarButton", publicName: "ariaLabelCalendarButton", isSignal: true, isRequired: false, transformFunction: null }, startTimeLabel: { classPropertyName: "startTimeLabel", publicName: "startTimeLabel", isSignal: true, isRequired: false, transformFunction: null }, endTimeLabel: { classPropertyName: "endTimeLabel", publicName: "endTimeLabel", isSignal: true, isRequired: false, transformFunction: null }, autoClose: { classPropertyName: "autoClose", publicName: "autoClose", isSignal: true, isRequired: false, transformFunction: null }, disabledInput: { classPropertyName: "disabledInput", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, errormessageId: { classPropertyName: "errormessageId", publicName: "errormessageId", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { siDatepickerConfig: "siDatepickerConfigChange", siDatepickerRangeChange: "siDatepickerRangeChange", disabledTimeChange: "disabledTimeChange", value: "valueChange" }, host: { attributes: { "role": "group" }, listeners: { "focusout": "onFocusOut($event)" }, properties: { "class.disabled": "disabled()", "class.readonly": "readonly()", "attr.aria-labelledby": "labelledby" }, classAttribute: "form-control d-flex align-items-center pe-2" }, providers: [
|
|
3972
3969
|
{
|
|
3973
3970
|
provide: NG_VALUE_ACCESSOR,
|
|
3974
3971
|
useExisting: SiDateRangeComponent,
|
|
@@ -3983,9 +3980,9 @@ class SiDateRangeComponent {
|
|
|
3983
3980
|
provide: SI_FORM_ITEM_CONTROL,
|
|
3984
3981
|
useExisting: SiDateRangeComponent
|
|
3985
3982
|
}
|
|
3986
|
-
], viewQueries: [{ propertyName: "inputDirectives", predicate: SiDateInputDirective, descendants: true, isSignal: true }, { propertyName: "startInput", first: true, predicate: ["startInput"], descendants: true, isSignal: true }, { propertyName: "endInput", first: true, predicate: ["endInput"], descendants: true, isSignal: true }, { propertyName: "button", first: true, predicate: ["button"], descendants: true, isSignal: true }], usesOnChanges: true, hostDirectives: [{ directive: SiDatepickerOverlayDirective, outputs: ["siDatepickerClose", "siDatepickerClose"] }], ngImport: i0, template: "<input\n #startInput=\"ngModel\"\n type=\"text\"\n class=\"border-0 p-0 focus-none\"\n siDateInput\n [ngModel]=\"value()?.start ?? null\"\n [siDatepickerConfig]=\"siDatepickerConfig()\"\n [placeholder]=\"startDatePlaceholder() | translate\"\n [attr.aria-label]=\"startDatePlaceholder() | translate\"\n [errormessageId]=\"errormessageId()\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n (ngModelChange)=\"onInputChanged({ start: $event, end: value()?.end })\"\n/>\n<span class=\"mx-3\">-</span>\n<input\n #endInput=\"ngModel\"\n type=\"text\"\n class=\"border-0 p-0 focus-none text-end\"\n siDateInput\n [ngModel]=\"value()?.end ?? null\"\n [siDatepickerConfig]=\"siDatepickerConfig()\"\n [placeholder]=\"endDatePlaceholder() | translate\"\n [attr.aria-label]=\"endDatePlaceholder() | translate\"\n [errormessageId]=\"errormessageId()\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n (ngModelChange)=\"onInputChanged({ start: value()?.start, end: $event })\"\n/>\n<button\n #button\n type=\"button\"\n class=\"btn btn-
|
|
3983
|
+
], viewQueries: [{ propertyName: "inputDirectives", predicate: SiDateInputDirective, descendants: true, isSignal: true }, { propertyName: "startInput", first: true, predicate: ["startInput"], descendants: true, isSignal: true }, { propertyName: "endInput", first: true, predicate: ["endInput"], descendants: true, isSignal: true }, { propertyName: "button", first: true, predicate: ["button"], descendants: true, isSignal: true }], usesOnChanges: true, hostDirectives: [{ directive: SiDatepickerOverlayDirective, outputs: ["siDatepickerClose", "siDatepickerClose"] }], ngImport: i0, template: "<input\n #startInput=\"ngModel\"\n type=\"text\"\n class=\"border-0 p-0 focus-none\"\n siDateInput\n [ngModel]=\"value()?.start ?? null\"\n [siDatepickerConfig]=\"siDatepickerConfig()\"\n [placeholder]=\"startDatePlaceholder() | translate\"\n [attr.aria-label]=\"startDatePlaceholder() | translate\"\n [errormessageId]=\"errormessageId()\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n (ngModelChange)=\"onInputChanged({ start: $event, end: value()?.end })\"\n/>\n<span class=\"mx-3\">-</span>\n<input\n #endInput=\"ngModel\"\n type=\"text\"\n class=\"border-0 p-0 focus-none text-end\"\n siDateInput\n [ngModel]=\"value()?.end ?? null\"\n [siDatepickerConfig]=\"siDatepickerConfig()\"\n [placeholder]=\"endDatePlaceholder() | translate\"\n [attr.aria-label]=\"endDatePlaceholder() | translate\"\n [errormessageId]=\"errormessageId()\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n (ngModelChange)=\"onInputChanged({ start: value()?.start, end: $event })\"\n/>\n<button\n #button\n type=\"button\"\n class=\"btn btn-icon btn-tertiary btn-sm\"\n [attr.aria-label]=\"ariaLabelCalendarButton() | translate\"\n [disabled]=\"disabled() || readonly()\"\n (click)=\"show()\"\n>\n <si-icon [icon]=\"icons.elementCalendar\" />\n</button>\n", styles: [":host{display:block;min-inline-size:237px;--si-action-icon-offset: 22px}:host(:focus-within){outline:var(--element-button-focus-width) solid var(--element-focus-default);outline-offset:var(--element-button-focus-overlay-width)}input{flex-grow:1;background-color:transparent;min-inline-size:80px}input::placeholder{opacity:1;color:var(--element-text-secondary)}input:disabled,input[readonly]{background-color:var(--element-base-1);opacity:1}input:disabled::placeholder{color:transparent}input:not([readonly]):focus::placeholder,input:focus:not([readonly]):focus::placeholder{color:transparent}.disabled,.disabled:hover,.disabled:focus{--border-color: var(--element-ui-3);color:var(--element-text-disabled)}.btn-icon{margin-inline-start:var(--si-feedback-icon-offset, 4px)}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: SiDateInputDirective, selector: "input[siDateInput]", inputs: ["id", "siDatepickerConfig", "disabled", "readonly", "errormessageId"], outputs: ["siDatepickerConfigChange", "siDatepickerDisabledTime", "stateChange", "dateChange"], exportAs: ["siDateInput"] }, { kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "ngmodule", type: A11yModule }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }] });
|
|
3987
3984
|
}
|
|
3988
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
3985
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDateRangeComponent, decorators: [{
|
|
3989
3986
|
type: Component,
|
|
3990
3987
|
args: [{ selector: 'si-date-range', imports: [FormsModule, SiDateInputDirective, SiIconComponent, SiTranslatePipe, A11yModule], providers: [
|
|
3991
3988
|
{
|
|
@@ -4013,8 +4010,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
|
|
|
4013
4010
|
directive: SiDatepickerOverlayDirective,
|
|
4014
4011
|
outputs: ['siDatepickerClose']
|
|
4015
4012
|
}
|
|
4016
|
-
], template: "<input\n #startInput=\"ngModel\"\n type=\"text\"\n class=\"border-0 p-0 focus-none\"\n siDateInput\n [ngModel]=\"value()?.start ?? null\"\n [siDatepickerConfig]=\"siDatepickerConfig()\"\n [placeholder]=\"startDatePlaceholder() | translate\"\n [attr.aria-label]=\"startDatePlaceholder() | translate\"\n [errormessageId]=\"errormessageId()\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n (ngModelChange)=\"onInputChanged({ start: $event, end: value()?.end })\"\n/>\n<span class=\"mx-3\">-</span>\n<input\n #endInput=\"ngModel\"\n type=\"text\"\n class=\"border-0 p-0 focus-none text-end\"\n siDateInput\n [ngModel]=\"value()?.end ?? null\"\n [siDatepickerConfig]=\"siDatepickerConfig()\"\n [placeholder]=\"endDatePlaceholder() | translate\"\n [attr.aria-label]=\"endDatePlaceholder() | translate\"\n [errormessageId]=\"errormessageId()\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n (ngModelChange)=\"onInputChanged({ start: value()?.start, end: $event })\"\n/>\n<button\n #button\n type=\"button\"\n class=\"btn btn-
|
|
4017
|
-
}], propDecorators: { onFocusOut: [{
|
|
4013
|
+
], template: "<input\n #startInput=\"ngModel\"\n type=\"text\"\n class=\"border-0 p-0 focus-none\"\n siDateInput\n [ngModel]=\"value()?.start ?? null\"\n [siDatepickerConfig]=\"siDatepickerConfig()\"\n [placeholder]=\"startDatePlaceholder() | translate\"\n [attr.aria-label]=\"startDatePlaceholder() | translate\"\n [errormessageId]=\"errormessageId()\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n (ngModelChange)=\"onInputChanged({ start: $event, end: value()?.end })\"\n/>\n<span class=\"mx-3\">-</span>\n<input\n #endInput=\"ngModel\"\n type=\"text\"\n class=\"border-0 p-0 focus-none text-end\"\n siDateInput\n [ngModel]=\"value()?.end ?? null\"\n [siDatepickerConfig]=\"siDatepickerConfig()\"\n [placeholder]=\"endDatePlaceholder() | translate\"\n [attr.aria-label]=\"endDatePlaceholder() | translate\"\n [errormessageId]=\"errormessageId()\"\n [disabled]=\"disabled()\"\n [readonly]=\"readonly()\"\n (ngModelChange)=\"onInputChanged({ start: value()?.start, end: $event })\"\n/>\n<button\n #button\n type=\"button\"\n class=\"btn btn-icon btn-tertiary btn-sm\"\n [attr.aria-label]=\"ariaLabelCalendarButton() | translate\"\n [disabled]=\"disabled() || readonly()\"\n (click)=\"show()\"\n>\n <si-icon [icon]=\"icons.elementCalendar\" />\n</button>\n", styles: [":host{display:block;min-inline-size:237px;--si-action-icon-offset: 22px}:host(:focus-within){outline:var(--element-button-focus-width) solid var(--element-focus-default);outline-offset:var(--element-button-focus-overlay-width)}input{flex-grow:1;background-color:transparent;min-inline-size:80px}input::placeholder{opacity:1;color:var(--element-text-secondary)}input:disabled,input[readonly]{background-color:var(--element-base-1);opacity:1}input:disabled::placeholder{color:transparent}input:not([readonly]):focus::placeholder,input:focus:not([readonly]):focus::placeholder{color:transparent}.disabled,.disabled:hover,.disabled:focus{--border-color: var(--element-ui-3);color:var(--element-text-disabled)}.btn-icon{margin-inline-start:var(--si-feedback-icon-offset, 4px)}\n"] }]
|
|
4014
|
+
}], propDecorators: { inputDirectives: [{ type: i0.ViewChildren, args: [i0.forwardRef(() => SiDateInputDirective), { isSignal: true }] }], startInput: [{ type: i0.ViewChild, args: ['startInput', { isSignal: true }] }], endInput: [{ type: i0.ViewChild, args: ['endInput', { isSignal: true }] }], button: [{ type: i0.ViewChild, args: ['button', { isSignal: true }] }], id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], siDatepickerConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "siDatepickerConfig", required: false }] }, { type: i0.Output, args: ["siDatepickerConfigChange"] }], startDatePlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "startDatePlaceholder", required: false }] }], endDatePlaceholder: [{ type: i0.Input, args: [{ isSignal: true, alias: "endDatePlaceholder", required: false }] }], ariaLabelCalendarButton: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabelCalendarButton", required: false }] }], startTimeLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "startTimeLabel", required: false }] }], endTimeLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "endTimeLabel", required: false }] }], autoClose: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoClose", required: false }] }], siDatepickerRangeChange: [{ type: i0.Output, args: ["siDatepickerRangeChange"] }], disabledTimeChange: [{ type: i0.Output, args: ["disabledTimeChange"] }], disabledInput: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], readonly: [{ type: i0.Input, args: [{ isSignal: true, alias: "readonly", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], errormessageId: [{ type: i0.Input, args: [{ isSignal: true, alias: "errormessageId", required: false }] }], onFocusOut: [{
|
|
4018
4015
|
type: HostListener,
|
|
4019
4016
|
args: ['focusout', ['$event']]
|
|
4020
4017
|
}] } });
|
|
@@ -4047,19 +4044,17 @@ class SiCalendarButtonComponent {
|
|
|
4047
4044
|
* t(() => $localize`:@@SI_DATEPICKER.CALENDAR_TOGGLE_BUTTON:Open calendar`)
|
|
4048
4045
|
* ```
|
|
4049
4046
|
*/
|
|
4050
|
-
ariaLabel = input(t(() => $localize `:@@SI_DATEPICKER.CALENDAR_TOGGLE_BUTTON:Open calendar`));
|
|
4047
|
+
ariaLabel = input(t(() => $localize `:@@SI_DATEPICKER.CALENDAR_TOGGLE_BUTTON:Open calendar`), ...(ngDevMode ? [{ debugName: "ariaLabel" }] : []));
|
|
4051
4048
|
button = viewChild.required('calendarButton');
|
|
4052
4049
|
/** Datepicker input directive instance used to watch for state changes and required to open the calendar. */
|
|
4053
4050
|
datepicker = contentChild.required(SiDatepickerDirective);
|
|
4054
4051
|
datepickerOverlay = contentChild.required(SiDatepickerOverlayDirective);
|
|
4055
|
-
ngControl = contentChild(NgControl);
|
|
4056
|
-
disabled = signal(false);
|
|
4052
|
+
ngControl = contentChild(NgControl, ...(ngDevMode ? [{ debugName: "ngControl" }] : []));
|
|
4053
|
+
disabled = signal(false, ...(ngDevMode ? [{ debugName: "disabled" }] : []));
|
|
4057
4054
|
icons = addIcons({ elementCalendar });
|
|
4058
4055
|
destroyerRef = inject(DestroyRef);
|
|
4059
4056
|
focusMonitor = inject(FocusMonitor);
|
|
4060
4057
|
elementRef = inject(ElementRef);
|
|
4061
|
-
// Add classes here to enable error messages in si-form-item
|
|
4062
|
-
showValidationMessages = signal(false);
|
|
4063
4058
|
ngOnInit() {
|
|
4064
4059
|
// Monitor input state changes and update the button accordingly
|
|
4065
4060
|
this.datepicker().stateChange.subscribe(() => this.updateState());
|
|
@@ -4074,10 +4069,6 @@ class SiCalendarButtonComponent {
|
|
|
4074
4069
|
});
|
|
4075
4070
|
});
|
|
4076
4071
|
}
|
|
4077
|
-
ngDoCheck() {
|
|
4078
|
-
const control = this.ngControl()?.control;
|
|
4079
|
-
this.showValidationMessages.set(!!control?.touched && !!control?.invalid);
|
|
4080
|
-
}
|
|
4081
4072
|
ngAfterContentInit() {
|
|
4082
4073
|
this.datepicker().useExternalTrigger(this.button());
|
|
4083
4074
|
this.updateState();
|
|
@@ -4089,13 +4080,13 @@ class SiCalendarButtonComponent {
|
|
|
4089
4080
|
const datepicker = this.datepicker();
|
|
4090
4081
|
this.disabled.set(datepicker.disabled() || datepicker.readonly());
|
|
4091
4082
|
}
|
|
4092
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
4093
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "
|
|
4083
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiCalendarButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
4084
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "21.0.8", type: SiCalendarButtonComponent, isStandalone: true, selector: "si-calendar-button", inputs: { ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "d-inline-block position-relative form-control-wrapper" }, queries: [{ propertyName: "datepicker", first: true, predicate: SiDatepickerDirective, descendants: true, isSignal: true }, { propertyName: "datepickerOverlay", first: true, predicate: SiDatepickerOverlayDirective, descendants: true, isSignal: true }, { propertyName: "ngControl", first: true, predicate: NgControl, descendants: true, isSignal: true }], viewQueries: [{ propertyName: "button", first: true, predicate: ["calendarButton"], descendants: true, isSignal: true }], ngImport: i0, template: `<ng-content />
|
|
4094
4085
|
<button
|
|
4095
4086
|
#calendarButton
|
|
4096
4087
|
name="open-calendar"
|
|
4097
4088
|
type="button"
|
|
4098
|
-
class="btn btn-
|
|
4089
|
+
class="btn btn-icon btn-tertiary btn-sm position-absolute end-0 top-0 me-2 mt-2"
|
|
4099
4090
|
[attr.aria-label]="ariaLabel() | translate"
|
|
4100
4091
|
[disabled]="disabled()"
|
|
4101
4092
|
(click)="show()"
|
|
@@ -4103,33 +4094,31 @@ class SiCalendarButtonComponent {
|
|
|
4103
4094
|
<si-icon [icon]="icons.elementCalendar" />
|
|
4104
4095
|
</button>`, isInline: true, styles: [":host{--si-action-icon-offset: 24px}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
4105
4096
|
}
|
|
4106
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
4097
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiCalendarButtonComponent, decorators: [{
|
|
4107
4098
|
type: Component,
|
|
4108
4099
|
args: [{ selector: 'si-calendar-button', imports: [SiIconComponent, SiTranslatePipe], template: `<ng-content />
|
|
4109
4100
|
<button
|
|
4110
4101
|
#calendarButton
|
|
4111
4102
|
name="open-calendar"
|
|
4112
4103
|
type="button"
|
|
4113
|
-
class="btn btn-
|
|
4104
|
+
class="btn btn-icon btn-tertiary btn-sm position-absolute end-0 top-0 me-2 mt-2"
|
|
4114
4105
|
[attr.aria-label]="ariaLabel() | translate"
|
|
4115
4106
|
[disabled]="disabled()"
|
|
4116
4107
|
(click)="show()"
|
|
4117
4108
|
>
|
|
4118
4109
|
<si-icon [icon]="icons.elementCalendar" />
|
|
4119
4110
|
</button>`, changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
|
4120
|
-
class: 'd-inline-block position-relative form-control-wrapper'
|
|
4121
|
-
'[class.ng-invalid]': 'showValidationMessages()',
|
|
4122
|
-
'[class.ng-touched]': 'showValidationMessages()'
|
|
4111
|
+
class: 'd-inline-block position-relative form-control-wrapper'
|
|
4123
4112
|
}, styles: [":host{--si-action-icon-offset: 24px}\n"] }]
|
|
4124
|
-
}] });
|
|
4113
|
+
}], propDecorators: { ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], button: [{ type: i0.ViewChild, args: ['calendarButton', { isSignal: true }] }], datepicker: [{ type: i0.ContentChild, args: [i0.forwardRef(() => SiDatepickerDirective), { isSignal: true }] }], datepickerOverlay: [{ type: i0.ContentChild, args: [i0.forwardRef(() => SiDatepickerOverlayDirective), { isSignal: true }] }], ngControl: [{ type: i0.ContentChild, args: [i0.forwardRef(() => NgControl), { isSignal: true }] }] } });
|
|
4125
4114
|
|
|
4126
4115
|
/**
|
|
4127
4116
|
* Copyright (c) Siemens 2016 - 2025
|
|
4128
4117
|
* SPDX-License-Identifier: MIT
|
|
4129
4118
|
*/
|
|
4130
4119
|
class SiDatepickerModule {
|
|
4131
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
4132
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
4120
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
4121
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerModule, imports: [SiCalendarButtonComponent,
|
|
4133
4122
|
SiDateInputDirective,
|
|
4134
4123
|
SiDatepickerComponent,
|
|
4135
4124
|
SiDatepickerDirective,
|
|
@@ -4140,12 +4129,12 @@ class SiDatepickerModule {
|
|
|
4140
4129
|
SiDatepickerDirective,
|
|
4141
4130
|
SiDateRangeComponent,
|
|
4142
4131
|
SiTimepickerComponent] });
|
|
4143
|
-
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
4132
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerModule, imports: [SiCalendarButtonComponent,
|
|
4144
4133
|
SiDatepickerComponent,
|
|
4145
4134
|
SiDateRangeComponent,
|
|
4146
4135
|
SiTimepickerComponent] });
|
|
4147
4136
|
}
|
|
4148
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
4137
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiDatepickerModule, decorators: [{
|
|
4149
4138
|
type: NgModule,
|
|
4150
4139
|
args: [{
|
|
4151
4140
|
imports: [
|