@siemens/element-ng 49.14.0 → 51.0.0-rc.5
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/README.md +1 -1
- package/fesm2022/siemens-element-ng-about.mjs +41 -25
- package/fesm2022/siemens-element-ng-about.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-accordion.mjs +58 -40
- package/fesm2022/siemens-element-ng-accordion.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-action-modal.mjs +83 -53
- package/fesm2022/siemens-element-ng-action-modal.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-ag-grid.mjs +15 -12
- package/fesm2022/siemens-element-ng-ag-grid.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-application-header.mjs +176 -166
- package/fesm2022/siemens-element-ng-application-header.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-auto-collapsable-list.mjs +34 -28
- package/fesm2022/siemens-element-ng-auto-collapsable-list.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-autocomplete.mjs +27 -22
- package/fesm2022/siemens-element-ng-autocomplete.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-avatar.mjs +31 -21
- package/fesm2022/siemens-element-ng-avatar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-badge.mjs +9 -8
- package/fesm2022/siemens-element-ng-badge.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-breadcrumb-router.mjs +17 -14
- package/fesm2022/siemens-element-ng-breadcrumb-router.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-breadcrumb.mjs +21 -17
- package/fesm2022/siemens-element-ng-breadcrumb.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-card.mjs +71 -46
- package/fesm2022/siemens-element-ng-card.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-carousel.mjs +57 -33
- package/fesm2022/siemens-element-ng-carousel.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-chat-messages.mjs +181 -117
- package/fesm2022/siemens-element-ng-chat-messages.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-circle-status.mjs +39 -25
- package/fesm2022/siemens-element-ng-circle-status.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-color-picker.mjs +26 -17
- package/fesm2022/siemens-element-ng-color-picker.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-column-selection-dialog.mjs +56 -35
- package/fesm2022/siemens-element-ng-column-selection-dialog.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-common.mjs +12 -12
- package/fesm2022/siemens-element-ng-connection-strength.mjs +14 -12
- package/fesm2022/siemens-element-ng-connection-strength.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-content-action-bar.mjs +36 -27
- package/fesm2022/siemens-element-ng-content-action-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-copyright-notice.mjs +19 -14
- package/fesm2022/siemens-element-ng-copyright-notice.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-dashboard.mjs +335 -221
- package/fesm2022/siemens-element-ng-dashboard.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-datatable.mjs +8 -8
- package/fesm2022/siemens-element-ng-datatable.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-date-range-filter.mjs +119 -72
- package/fesm2022/siemens-element-ng-date-range-filter.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-datepicker.mjs +376 -244
- package/fesm2022/siemens-element-ng-datepicker.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-electron-titlebar.mjs +22 -17
- package/fesm2022/siemens-element-ng-electron-titlebar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-empty-state.mjs +15 -12
- package/fesm2022/siemens-element-ng-empty-state.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-file-uploader.mjs +105 -91
- package/fesm2022/siemens-element-ng-file-uploader.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-filter-bar.mjs +32 -24
- package/fesm2022/siemens-element-ng-filter-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-filtered-search.mjs +251 -153
- package/fesm2022/siemens-element-ng-filtered-search.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-footer.mjs +12 -10
- package/fesm2022/siemens-element-ng-footer.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-form.mjs +345 -113
- package/fesm2022/siemens-element-ng-form.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-formly-legacy.mjs +99 -0
- package/fesm2022/siemens-element-ng-formly-legacy.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-formly.mjs +222 -316
- package/fesm2022/siemens-element-ng-formly.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-header-dropdown.mjs +40 -30
- package/fesm2022/siemens-element-ng-header-dropdown.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-help-button.mjs +5 -5
- package/fesm2022/siemens-element-ng-help-button.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-icon.mjs +46 -47
- package/fesm2022/siemens-element-ng-icon.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-info-page.mjs +17 -11
- package/fesm2022/siemens-element-ng-info-page.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-inline-notification.mjs +19 -14
- package/fesm2022/siemens-element-ng-inline-notification.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-ip-input.mjs +25 -25
- package/fesm2022/siemens-element-ng-ip-input.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-landing-page.mjs +120 -74
- package/fesm2022/siemens-element-ng-landing-page.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-language-switcher.mjs +16 -12
- package/fesm2022/siemens-element-ng-language-switcher.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-link.mjs +31 -21
- package/fesm2022/siemens-element-ng-link.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-list-details.mjs +76 -56
- package/fesm2022/siemens-element-ng-list-details.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-loading-spinner.mjs +46 -63
- package/fesm2022/siemens-element-ng-loading-spinner.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-localization.mjs +14 -12
- package/fesm2022/siemens-element-ng-localization.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-main-detail-container.mjs +47 -30
- package/fesm2022/siemens-element-ng-main-detail-container.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-maplibre.mjs +42 -0
- package/fesm2022/siemens-element-ng-maplibre.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-markdown-renderer.mjs +6 -5
- package/fesm2022/siemens-element-ng-markdown-renderer.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-menu.mjs +56 -48
- package/fesm2022/siemens-element-ng-menu.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-modal.mjs +14 -11
- package/fesm2022/siemens-element-ng-modal.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-navbar-vertical-next.mjs +249 -204
- package/fesm2022/siemens-element-ng-navbar-vertical-next.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-navbar-vertical.mjs +120 -83
- package/fesm2022/siemens-element-ng-navbar-vertical.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-navbar.mjs +72 -45
- package/fesm2022/siemens-element-ng-navbar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-notification-item.mjs +19 -11
- package/fesm2022/siemens-element-ng-notification-item.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-number-input.mjs +40 -28
- package/fesm2022/siemens-element-ng-number-input.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-pagination.mjs +31 -20
- package/fesm2022/siemens-element-ng-pagination.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-password-strength.mjs +32 -23
- package/fesm2022/siemens-element-ng-password-strength.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-password-toggle.mjs +18 -13
- package/fesm2022/siemens-element-ng-password-toggle.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-phone-number.mjs +123 -139
- package/fesm2022/siemens-element-ng-phone-number.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-photo-upload.mjs +84 -51
- package/fesm2022/siemens-element-ng-photo-upload.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-pills-input.mjs +63 -58
- package/fesm2022/siemens-element-ng-pills-input.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-popover-legacy.mjs +43 -28
- package/fesm2022/siemens-element-ng-popover-legacy.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-popover.mjs +35 -27
- package/fesm2022/siemens-element-ng-popover.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-progressbar.mjs +23 -16
- package/fesm2022/siemens-element-ng-progressbar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-resize-observer.mjs +32 -43
- package/fesm2022/siemens-element-ng-resize-observer.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-result-details-list.mjs +12 -10
- package/fesm2022/siemens-element-ng-result-details-list.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-search-bar.mjs +38 -31
- package/fesm2022/siemens-element-ng-search-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-select.mjs +218 -163
- 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-side-panel.mjs +128 -86
- package/fesm2022/siemens-element-ng-side-panel.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-skip-links.mjs +21 -24
- package/fesm2022/siemens-element-ng-skip-links.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-slider.mjs +44 -29
- package/fesm2022/siemens-element-ng-slider.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-split.mjs +273 -293
- package/fesm2022/siemens-element-ng-split.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-status-bar.mjs +65 -51
- package/fesm2022/siemens-element-ng-status-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-status-counter.mjs +15 -11
- package/fesm2022/siemens-element-ng-status-counter.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-status-toggle.mjs +26 -16
- package/fesm2022/siemens-element-ng-status-toggle.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-summary-chip.mjs +25 -16
- package/fesm2022/siemens-element-ng-summary-chip.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-summary-widget.mjs +27 -17
- package/fesm2022/siemens-element-ng-summary-widget.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-system-banner.mjs +11 -8
- package/fesm2022/siemens-element-ng-system-banner.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tabs-legacy.mjs +20 -17
- package/fesm2022/siemens-element-ng-tabs-legacy.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tabs.mjs +73 -70
- package/fesm2022/siemens-element-ng-tabs.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-theme.mjs +29 -6
- package/fesm2022/siemens-element-ng-theme.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-threshold.mjs +60 -41
- package/fesm2022/siemens-element-ng-threshold.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-toast-notification.mjs +45 -40
- package/fesm2022/siemens-element-ng-toast-notification.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tooltip.mjs +105 -82
- package/fesm2022/siemens-element-ng-tooltip.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tour.mjs +24 -18
- package/fesm2022/siemens-element-ng-tour.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-translate.mjs +0 -1
- package/fesm2022/siemens-element-ng-translate.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tree-view.mjs +96 -75
- package/fesm2022/siemens-element-ng-tree-view.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-typeahead.mjs +76 -70
- package/fesm2022/siemens-element-ng-typeahead.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-wizard.mjs +72 -48
- package/fesm2022/siemens-element-ng-wizard.mjs.map +1 -1
- package/formly-legacy/package.json +4 -0
- package/maplibre/package.json +4 -0
- package/maplibre/styles/_index.scss +1 -0
- package/maplibre/styles/maplibre-gl.scss +715 -0
- package/package.json +37 -23
- package/schematics/migration.json +4 -4
- package/schematics/migrations/data/class-member-replacement.js +1 -19
- package/schematics/migrations/data/component-property-names.js +1 -25
- package/schematics/migrations/data/element-class-changes.js +1 -28
- package/schematics/migrations/data/element-migration-data.js +2 -0
- package/schematics/migrations/data/element-selectors.js +1 -11
- package/schematics/migrations/data/index.js +0 -4
- package/schematics/migrations/data/migration-test-data.js +9 -6
- package/schematics/migrations/data/provider-function-removals.js +7 -0
- package/schematics/migrations/data/symbol-removals.js +7 -7
- package/schematics/migrations/data/symbol-renaming.js +1 -48
- package/schematics/migrations/element-migration/element-migration.js +3 -6
- package/schematics/migrations/utilities/import-removal.js +39 -0
- package/schematics/migrations/utilities/index.js +2 -0
- package/schematics/migrations/utilities/provider-function-removal.migration.js +116 -0
- package/schematics/ng-update/index.js +1 -1
- package/schematics/ng-update/migrate-split-sizes.js +105 -0
- package/schematics/ng-update/{migrate-to-v49.js → migrate-to-v51.js} +5 -3
- package/template-i18n.json +45 -47
- package/types/siemens-element-ng-application-header.d.ts +8 -28
- package/types/siemens-element-ng-breadcrumb.d.ts +1 -1
- package/types/siemens-element-ng-chat-messages.d.ts +11 -9
- package/types/siemens-element-ng-circle-status.d.ts +1 -1
- package/types/siemens-element-ng-content-action-bar.d.ts +1 -1
- package/types/siemens-element-ng-dashboard.d.ts +2 -2
- package/types/siemens-element-ng-date-range-filter.d.ts +1 -1
- package/types/siemens-element-ng-datepicker.d.ts +3 -14
- package/types/siemens-element-ng-electron-titlebar.d.ts +1 -1
- package/types/siemens-element-ng-file-uploader.d.ts +13 -31
- package/types/siemens-element-ng-filter-bar.d.ts +1 -1
- package/types/siemens-element-ng-filtered-search.d.ts +4 -4
- package/types/siemens-element-ng-form.d.ts +180 -44
- package/types/siemens-element-ng-formly-legacy.d.ts +40 -0
- package/types/siemens-element-ng-formly.d.ts +34 -167
- package/types/siemens-element-ng-icon.d.ts +2 -19
- package/types/siemens-element-ng-ip-input.d.ts +1 -1
- package/types/siemens-element-ng-landing-page.d.ts +2 -2
- package/types/siemens-element-ng-loading-spinner.d.ts +7 -17
- package/types/siemens-element-ng-maplibre.d.ts +26 -0
- package/types/siemens-element-ng-navbar-vertical-next.d.ts +86 -38
- package/types/siemens-element-ng-navbar-vertical.d.ts +1 -1
- package/types/siemens-element-ng-navbar.d.ts +3 -3
- package/types/siemens-element-ng-notification-item.d.ts +12 -0
- package/types/siemens-element-ng-phone-number.d.ts +5 -8
- package/types/siemens-element-ng-photo-upload.d.ts +4 -4
- package/types/siemens-element-ng-resize-observer.d.ts +0 -17
- package/types/siemens-element-ng-search-bar.d.ts +1 -1
- package/types/siemens-element-ng-select.d.ts +1 -1
- package/types/siemens-element-ng-side-panel.d.ts +3 -3
- package/types/siemens-element-ng-split.d.ts +99 -70
- package/types/siemens-element-ng-status-bar.d.ts +5 -13
- package/types/siemens-element-ng-status-counter.d.ts +1 -1
- package/types/siemens-element-ng-tabs.d.ts +1 -2
- package/types/siemens-element-ng-theme.d.ts +12 -2
- package/types/siemens-element-ng-threshold.d.ts +1 -1
- package/types/siemens-element-ng-toast-notification.d.ts +0 -1
- package/types/siemens-element-ng-tooltip.d.ts +7 -7
- package/types/siemens-element-ng-translate.d.ts +2 -5
- package/fesm2022/siemens-element-ng-icon-status.mjs +0 -46
- package/fesm2022/siemens-element-ng-icon-status.mjs.map +0 -1
- package/fesm2022/siemens-element-ng-sort-bar.mjs +0 -99
- package/fesm2022/siemens-element-ng-sort-bar.mjs.map +0 -1
- package/icon-status/package.json +0 -4
- package/schematics/vitest-setup.js +0 -5
- package/sort-bar/package.json +0 -4
- package/types/siemens-element-ng-icon-status.d.ts +0 -25
- package/types/siemens-element-ng-sort-bar.d.ts +0 -59
- /package/{LICENSE.md → LICENSE} +0 -0
|
@@ -52,10 +52,10 @@ class SiDashboardService {
|
|
|
52
52
|
this.cards.next(nextCards);
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
56
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
55
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
56
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardService });
|
|
57
57
|
}
|
|
58
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
58
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardService, decorators: [{
|
|
59
59
|
type: Injectable
|
|
60
60
|
}] });
|
|
61
61
|
|
|
@@ -72,7 +72,8 @@ class SiDashboardCardComponent extends SiCardComponent {
|
|
|
72
72
|
* t(() => $localize`:@@SI_DASHBOARD.RESTORE:Restore`)
|
|
73
73
|
* ```
|
|
74
74
|
*/
|
|
75
|
-
restoreText = input(t(() => $localize `:@@SI_DASHBOARD.RESTORE:Restore`),
|
|
75
|
+
restoreText = input(t(() => $localize `:@@SI_DASHBOARD.RESTORE:Restore`), /* @ts-ignore */
|
|
76
|
+
...(ngDevMode ? [{ debugName: "restoreText" }] : /* istanbul ignore next */ []));
|
|
76
77
|
/**
|
|
77
78
|
* Description of expand button & action.
|
|
78
79
|
*
|
|
@@ -81,7 +82,8 @@ class SiDashboardCardComponent extends SiCardComponent {
|
|
|
81
82
|
* t(() => $localize`:@@SI_DASHBOARD.EXPAND:Expand`)
|
|
82
83
|
* ```
|
|
83
84
|
*/
|
|
84
|
-
expandText = input(t(() => $localize `:@@SI_DASHBOARD.EXPAND:Expand`),
|
|
85
|
+
expandText = input(t(() => $localize `:@@SI_DASHBOARD.EXPAND:Expand`), /* @ts-ignore */
|
|
86
|
+
...(ngDevMode ? [{ debugName: "expandText" }] : /* istanbul ignore next */ []));
|
|
85
87
|
/**
|
|
86
88
|
* Option to enable and show the UI controls for card expand functionality.
|
|
87
89
|
* `Expand` and `restore` action items will be added to the content action bar.
|
|
@@ -89,13 +91,13 @@ class SiDashboardCardComponent extends SiCardComponent {
|
|
|
89
91
|
*
|
|
90
92
|
* @defaultValue false
|
|
91
93
|
*/
|
|
92
|
-
enableExpandInteraction = input(false, { ...(ngDevMode ? { debugName: "enableExpandInteraction" } : {}), transform: booleanAttribute });
|
|
94
|
+
enableExpandInteraction = input(false, { ...(ngDevMode ? { debugName: "enableExpandInteraction" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
93
95
|
/**
|
|
94
96
|
* Used in combination with si-dashboard to show filters when a card is expanded or not.
|
|
95
97
|
*
|
|
96
98
|
* @defaultValue true
|
|
97
99
|
*/
|
|
98
|
-
showMenubar = input(true, { ...(ngDevMode ? { debugName: "showMenubar" } : {}), transform: booleanAttribute });
|
|
100
|
+
showMenubar = input(true, { ...(ngDevMode ? { debugName: "showMenubar" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
99
101
|
/**
|
|
100
102
|
* Emitter for size state change
|
|
101
103
|
*/
|
|
@@ -105,15 +107,20 @@ class SiDashboardCardComponent extends SiCardComponent {
|
|
|
105
107
|
*
|
|
106
108
|
* @defaultValue false
|
|
107
109
|
*/
|
|
108
|
-
isExpanded = signal(false,
|
|
110
|
+
isExpanded = signal(false, /* @ts-ignore */
|
|
111
|
+
...(ngDevMode ? [{ debugName: "isExpanded" }] : /* istanbul ignore next */ []));
|
|
109
112
|
/** @internal */
|
|
110
|
-
hide = signal(false,
|
|
113
|
+
hide = signal(false, /* @ts-ignore */
|
|
114
|
+
...(ngDevMode ? [{ debugName: "hide" }] : /* istanbul ignore next */ []));
|
|
111
115
|
/** @internal */
|
|
112
|
-
enableExpandInteractionInternal = signal(false,
|
|
113
|
-
|
|
116
|
+
enableExpandInteractionInternal = signal(false, /* @ts-ignore */
|
|
117
|
+
...(ngDevMode ? [{ debugName: "enableExpandInteractionInternal" }] : /* istanbul ignore next */ []));
|
|
118
|
+
enableExpandInteractionComputed = computed(() => this.enableExpandInteraction() || this.enableExpandInteractionInternal(), /* @ts-ignore */
|
|
119
|
+
...(ngDevMode ? [{ debugName: "enableExpandInteractionComputed" }] : /* istanbul ignore next */ []));
|
|
114
120
|
/** @internal */
|
|
115
121
|
element = inject(ElementRef);
|
|
116
|
-
displayContentActionBar = computed(() => this.primaryActionsComputed()?.length > 0 || this.secondaryActions()?.length > 0,
|
|
122
|
+
displayContentActionBar = computed(() => this.primaryActionsComputed()?.length > 0 || this.secondaryActions()?.length > 0, /* @ts-ignore */
|
|
123
|
+
...(ngDevMode ? [{ debugName: "displayContentActionBar" }] : /* istanbul ignore next */ []));
|
|
117
124
|
actionBarViewTypeComputed = computed(() => {
|
|
118
125
|
if (!this.hasContentBarActions()) {
|
|
119
126
|
if (this.enableExpandInteractionComputed()) {
|
|
@@ -126,7 +133,8 @@ class SiDashboardCardComponent extends SiCardComponent {
|
|
|
126
133
|
else {
|
|
127
134
|
return this.actionBarViewType();
|
|
128
135
|
}
|
|
129
|
-
},
|
|
136
|
+
}, /* @ts-ignore */
|
|
137
|
+
...(ngDevMode ? [{ debugName: "actionBarViewTypeComputed" }] : /* istanbul ignore next */ []));
|
|
130
138
|
actionBarTitleComputed = computed(() => {
|
|
131
139
|
if (!this.hasContentBarActions()) {
|
|
132
140
|
if (this.enableExpandInteractionComputed()) {
|
|
@@ -139,7 +147,8 @@ class SiDashboardCardComponent extends SiCardComponent {
|
|
|
139
147
|
else {
|
|
140
148
|
return this.actionBarTitle();
|
|
141
149
|
}
|
|
142
|
-
},
|
|
150
|
+
}, /* @ts-ignore */
|
|
151
|
+
...(ngDevMode ? [{ debugName: "actionBarTitleComputed" }] : /* istanbul ignore next */ []));
|
|
143
152
|
primaryActionsComputed = computed(() => {
|
|
144
153
|
const expandRestoreButtonActions = [
|
|
145
154
|
{
|
|
@@ -172,14 +181,16 @@ class SiDashboardCardComponent extends SiCardComponent {
|
|
|
172
181
|
}
|
|
173
182
|
}
|
|
174
183
|
}
|
|
175
|
-
},
|
|
184
|
+
}, /* @ts-ignore */
|
|
185
|
+
...(ngDevMode ? [{ debugName: "primaryActionsComputed" }] : /* istanbul ignore next */ []));
|
|
176
186
|
icons = addIcons({
|
|
177
187
|
elementPinch,
|
|
178
188
|
elementZoom
|
|
179
189
|
});
|
|
180
190
|
expandRestoreIconTooltip = computed(() => {
|
|
181
191
|
return this.isExpanded() ? this.restoreText() : this.expandText();
|
|
182
|
-
},
|
|
192
|
+
}, /* @ts-ignore */
|
|
193
|
+
...(ngDevMode ? [{ debugName: "expandRestoreIconTooltip" }] : /* istanbul ignore next */ []));
|
|
183
194
|
expandActionItem = computed(() => {
|
|
184
195
|
return {
|
|
185
196
|
type: 'action',
|
|
@@ -188,7 +199,8 @@ class SiDashboardCardComponent extends SiCardComponent {
|
|
|
188
199
|
iconOnly: true,
|
|
189
200
|
action: () => this.expandCard(true)
|
|
190
201
|
};
|
|
191
|
-
},
|
|
202
|
+
}, /* @ts-ignore */
|
|
203
|
+
...(ngDevMode ? [{ debugName: "expandActionItem" }] : /* istanbul ignore next */ []));
|
|
192
204
|
restoreActionItem = computed(() => {
|
|
193
205
|
return {
|
|
194
206
|
type: 'action',
|
|
@@ -197,10 +209,12 @@ class SiDashboardCardComponent extends SiCardComponent {
|
|
|
197
209
|
iconOnly: true,
|
|
198
210
|
action: () => this.expandCard(false)
|
|
199
211
|
};
|
|
200
|
-
},
|
|
212
|
+
}, /* @ts-ignore */
|
|
213
|
+
...(ngDevMode ? [{ debugName: "restoreActionItem" }] : /* istanbul ignore next */ []));
|
|
201
214
|
hasContentBarActions = computed(() => {
|
|
202
215
|
return this.primaryActions()?.length > 0 || this.secondaryActions()?.length > 0;
|
|
203
|
-
},
|
|
216
|
+
}, /* @ts-ignore */
|
|
217
|
+
...(ngDevMode ? [{ debugName: "hasContentBarActions" }] : /* istanbul ignore next */ []));
|
|
204
218
|
dashboardService = inject(SiDashboardService, { optional: true });
|
|
205
219
|
constructor() {
|
|
206
220
|
super();
|
|
@@ -225,12 +239,12 @@ class SiDashboardCardComponent extends SiCardComponent {
|
|
|
225
239
|
this.isExpanded.set(expand);
|
|
226
240
|
this.expandChange.emit(expand);
|
|
227
241
|
}
|
|
228
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
229
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
242
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardCardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
243
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiDashboardCardComponent, isStandalone: true, selector: "si-dashboard-card", inputs: { restoreText: { classPropertyName: "restoreText", publicName: "restoreText", isSignal: true, isRequired: false, transformFunction: null }, expandText: { classPropertyName: "expandText", publicName: "expandText", isSignal: true, isRequired: false, transformFunction: null }, enableExpandInteraction: { classPropertyName: "enableExpandInteraction", publicName: "enableExpandInteraction", isSignal: true, isRequired: false, transformFunction: null }, showMenubar: { classPropertyName: "showMenubar", publicName: "showMenubar", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { expandChange: "expandChange" }, host: { properties: { "class.elevation-2": "isExpanded()", "class.expanded": "isExpanded()", "class.d-none": "hide()" } }, usesInheritance: true, ngImport: i0, template: "@if (imgSrc()) {\n <img\n class=\"card-content-split\"\n [class.card-img-top]=\"imgDir() !== 'horizontal'\"\n [class.card-img-start]=\"imgDir() === 'horizontal'\"\n [attr.src]=\"imgSrc()\"\n [attr.alt]=\"imgAlt() | translate\"\n />\n}\n\n<div class=\"content-container\" [class.card-content-split]=\"imgSrc()\">\n @if (heading() || displayContentActionBar()) {\n <si-card-header\n [heading]=\"heading()\"\n [subHeading]=\"subHeading()\"\n [primaryActions]=\"primaryActionsComputed()\"\n [secondaryActions]=\"secondaryActions()\"\n [actionParam]=\"actionParam()\"\n [actionBarViewType]=\"actionBarViewTypeComputed()\"\n [actionBarTitle]=\"actionBarTitleComputed()\"\n >\n <ng-content select=\"[headerIcon]\" ngProjectAs=\"[headerIcon]\" />\n </si-card-header>\n }\n <ng-content #cardBody select=\"[body]\" />\n <ng-content #cardFooter select=\"[footer]\" />\n</div>\n", styles: [":host.card-horizontal{flex-direction:row}:host{block-size:100%}:host.expanded{position:absolute;inset:0}.card-img-top{block-size:50%;inline-size:auto;object-fit:var(--si-card-img-object-fit, scale-down);object-position:var(--si-card-img-object-position, center top)}.card-img-start{block-size:auto;inline-size:50%;object-fit:var(--si-card-img-object-fit, scale-down);object-position:var(--si-card-img-object-position, left center)}.card-content-split{flex:0 0 50%}.content-container{overflow:hidden;position:relative;display:flex;flex-direction:column;flex:1 1 auto;min-inline-size:0;word-wrap:break-word;border-radius:inherit}\n"], dependencies: [{ kind: "component", type: SiCardHeaderComponent, selector: "si-card-header", inputs: ["heading", "subHeading", "headingId", "subHeadingId", "primaryActions", "secondaryActions", "actionParam", "actionBarViewType", "actionBarTitle"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
230
244
|
}
|
|
231
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
245
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardCardComponent, decorators: [{
|
|
232
246
|
type: Component,
|
|
233
|
-
args: [{ selector: 'si-dashboard-card', imports: [SiCardHeaderComponent, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.
|
|
247
|
+
args: [{ selector: 'si-dashboard-card', imports: [SiCardHeaderComponent, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.Eager, host: {
|
|
234
248
|
'[class.elevation-2]': 'isExpanded()',
|
|
235
249
|
'[class.expanded]': 'isExpanded()',
|
|
236
250
|
'[class.d-none]': 'hide()'
|
|
@@ -247,25 +261,26 @@ class SiDashboardComponent {
|
|
|
247
261
|
/**
|
|
248
262
|
* Heading for the dashboard page.
|
|
249
263
|
*/
|
|
250
|
-
heading = input(
|
|
264
|
+
heading = input(/* @ts-ignore */
|
|
265
|
+
...(ngDevMode ? [undefined, { debugName: "heading" }] : /* istanbul ignore next */ []));
|
|
251
266
|
/**
|
|
252
267
|
* Opt-in to enable expand interaction for all cards.
|
|
253
268
|
*
|
|
254
269
|
* @defaultValue false
|
|
255
270
|
*/
|
|
256
|
-
enableExpandInteractions = input(false, { ...(ngDevMode ? { debugName: "enableExpandInteractions" } : {}), transform: booleanAttribute });
|
|
271
|
+
enableExpandInteractions = input(false, { ...(ngDevMode ? { debugName: "enableExpandInteractions" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
257
272
|
/**
|
|
258
273
|
* Option to turn off the sticky behavior of the heading and menu bar.
|
|
259
274
|
*
|
|
260
275
|
* @defaultValue true
|
|
261
276
|
*/
|
|
262
|
-
sticky = input(true, { ...(ngDevMode ? { debugName: "sticky" } : {}), transform: booleanAttribute });
|
|
277
|
+
sticky = input(true, { ...(ngDevMode ? { debugName: "sticky" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
263
278
|
/**
|
|
264
279
|
* Option to hide the menu bar.
|
|
265
280
|
*
|
|
266
281
|
* @defaultValue false
|
|
267
282
|
*/
|
|
268
|
-
hideMenubar = input(false, { ...(ngDevMode ? { debugName: "hideMenubar" } : {}), transform: booleanAttribute });
|
|
283
|
+
hideMenubar = input(false, { ...(ngDevMode ? { debugName: "hideMenubar" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
269
284
|
/**
|
|
270
285
|
* Is `true` if a card is expanded.
|
|
271
286
|
* @defaultref {@link isExpandedSignal}
|
|
@@ -273,17 +288,20 @@ class SiDashboardComponent {
|
|
|
273
288
|
get isExpanded() {
|
|
274
289
|
return this.isExpandedSignal();
|
|
275
290
|
}
|
|
276
|
-
dashboardFrameEndPadding = signal(null,
|
|
277
|
-
|
|
278
|
-
|
|
291
|
+
dashboardFrameEndPadding = signal(null, /* @ts-ignore */
|
|
292
|
+
...(ngDevMode ? [{ debugName: "dashboardFrameEndPadding" }] : /* istanbul ignore next */ []));
|
|
293
|
+
hideMenubarComputed = computed(() => this.hideMenubar() || this.hideMenubarInternal(), /* @ts-ignore */
|
|
294
|
+
...(ngDevMode ? [{ debugName: "hideMenubarComputed" }] : /* istanbul ignore next */ []));
|
|
295
|
+
isExpandedSignal = signal(false, /* @ts-ignore */
|
|
296
|
+
...(ngDevMode ? [{ debugName: "isExpandedSignal" }] : /* istanbul ignore next */ []));
|
|
279
297
|
scrollPosition = [0, 0];
|
|
280
298
|
reinitCards$ = new Subject();
|
|
281
299
|
cards = [];
|
|
282
|
-
expandedPortalOutlet = viewChild.required('expandedPortalOutlet', {
|
|
283
|
-
|
|
284
|
-
});
|
|
285
|
-
|
|
286
|
-
dashboard
|
|
300
|
+
expandedPortalOutlet = viewChild.required('expandedPortalOutlet', { ...(ngDevMode ? { debugName: "expandedPortalOutlet" } : /* istanbul ignore next */ {}), read: CdkPortalOutlet });
|
|
301
|
+
dashboardFrame = viewChild.required('dashboardFrame', /* @ts-ignore */
|
|
302
|
+
...(ngDevMode ? [{ debugName: "dashboardFrame" }] : /* istanbul ignore next */ []));
|
|
303
|
+
dashboard = viewChild.required('dashboard', /* @ts-ignore */
|
|
304
|
+
...(ngDevMode ? [{ debugName: "dashboard" }] : /* istanbul ignore next */ []));
|
|
287
305
|
dashboardFrameDimensions;
|
|
288
306
|
dashboardDimensions;
|
|
289
307
|
scroller = inject(ViewportScroller);
|
|
@@ -292,7 +310,8 @@ class SiDashboardComponent {
|
|
|
292
310
|
scrollbarHelper = inject(ScrollbarHelper);
|
|
293
311
|
cdRef = inject(ChangeDetectorRef);
|
|
294
312
|
document = inject(DOCUMENT);
|
|
295
|
-
hideMenubarInternal = signal(false,
|
|
313
|
+
hideMenubarInternal = signal(false, /* @ts-ignore */
|
|
314
|
+
...(ngDevMode ? [{ debugName: "hideMenubarInternal" }] : /* istanbul ignore next */ []));
|
|
296
315
|
constructor() {
|
|
297
316
|
this.dashboardService.cards$
|
|
298
317
|
.pipe(takeUntilDestroyed())
|
|
@@ -434,12 +453,12 @@ class SiDashboardComponent {
|
|
|
434
453
|
}
|
|
435
454
|
this.dashboardFrameEndPadding.set(padding);
|
|
436
455
|
}
|
|
437
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
438
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
456
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
457
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiDashboardComponent, isStandalone: true, selector: "si-dashboard", inputs: { heading: { classPropertyName: "heading", publicName: "heading", isSignal: true, isRequired: false, transformFunction: null }, enableExpandInteractions: { classPropertyName: "enableExpandInteractions", publicName: "enableExpandInteractions", isSignal: true, isRequired: false, transformFunction: null }, sticky: { classPropertyName: "sticky", publicName: "sticky", isSignal: true, isRequired: false, transformFunction: null }, hideMenubar: { classPropertyName: "hideMenubar", publicName: "hideMenubar", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "si-layout-fixed-height" }, providers: [SiDashboardService], viewQueries: [{ propertyName: "expandedPortalOutlet", first: true, predicate: ["expandedPortalOutlet"], descendants: true, read: CdkPortalOutlet, isSignal: true }, { propertyName: "dashboardFrame", first: true, predicate: ["dashboardFrame"], descendants: true, isSignal: true }, { propertyName: "dashboard", first: true, predicate: ["dashboard"], descendants: true, isSignal: true }], usesOnChanges: true, ngImport: i0, template: "<div\n class=\"si-layout-fixed-height si-dashboard si-layout-main-padding py-6\"\n [class.sticky]=\"sticky()\"\n>\n <div class=\"si-dashboard-header\" [class.sticky]=\"sticky()\">\n @if (heading()) {\n <div class=\"si-layout-header\">\n <h2 class=\"si-layout-title si-layout-top-element\">{{ heading() | translate }}</h2>\n </div>\n }\n @if (!hideMenubarComputed()) {\n <div class=\"mb-6\" [class.si-layout-top-element]=\"!heading()\">\n <ng-content select=\"[menubar]\" />\n </div>\n }\n </div>\n <div\n #dashboardFrame\n class=\"si-layout-fixed-height si-dashboard-content ps-2 pt-2 ms-n2 mt-n2\"\n [class.sticky]=\"sticky()\"\n [style.padding-inline-end.px]=\"dashboardFrameEndPadding()\"\n >\n <div class=\"si-layout-fixed-height\" [class.d-none]=\"isExpandedSignal()\">\n <div #dashboard class=\"si-layout-fixed-height fix-si-layout-fixed-height\">\n <ng-content select=\"[dashboard]\" />\n </div>\n </div>\n <div\n class=\"position-relative flex-grow-1 flex-shrink-1 mb-6\"\n [class.d-none]=\"!isExpandedSignal()\"\n >\n <ng-container #expandedPortalOutlet cdkPortalOutlet />\n </div>\n </div>\n</div>\n", styles: [".si-dashboard.sticky{padding-inline-end:0;overflow-x:hidden}.si-dashboard .si-dashboard-header.sticky{padding-inline-end:16px}@media(min-width:768px){.si-dashboard .si-dashboard-header.sticky{padding-inline-end:32px}}.si-dashboard .si-dashboard-content.sticky{overflow-y:auto;overflow-x:hidden}.si-dashboard .fix-si-layout-fixed-height{min-block-size:auto}\n"], dependencies: [{ kind: "ngmodule", type: PortalModule }, { kind: "directive", type: i1.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
439
458
|
}
|
|
440
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
459
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardComponent, decorators: [{
|
|
441
460
|
type: Component,
|
|
442
|
-
args: [{ selector: 'si-dashboard', imports: [PortalModule, SiTranslatePipe], providers: [SiDashboardService], changeDetection: ChangeDetectionStrategy.
|
|
461
|
+
args: [{ selector: 'si-dashboard', imports: [PortalModule, SiTranslatePipe], providers: [SiDashboardService], changeDetection: ChangeDetectionStrategy.Eager, host: { class: 'si-layout-fixed-height' }, template: "<div\n class=\"si-layout-fixed-height si-dashboard si-layout-main-padding py-6\"\n [class.sticky]=\"sticky()\"\n>\n <div class=\"si-dashboard-header\" [class.sticky]=\"sticky()\">\n @if (heading()) {\n <div class=\"si-layout-header\">\n <h2 class=\"si-layout-title si-layout-top-element\">{{ heading() | translate }}</h2>\n </div>\n }\n @if (!hideMenubarComputed()) {\n <div class=\"mb-6\" [class.si-layout-top-element]=\"!heading()\">\n <ng-content select=\"[menubar]\" />\n </div>\n }\n </div>\n <div\n #dashboardFrame\n class=\"si-layout-fixed-height si-dashboard-content ps-2 pt-2 ms-n2 mt-n2\"\n [class.sticky]=\"sticky()\"\n [style.padding-inline-end.px]=\"dashboardFrameEndPadding()\"\n >\n <div class=\"si-layout-fixed-height\" [class.d-none]=\"isExpandedSignal()\">\n <div #dashboard class=\"si-layout-fixed-height fix-si-layout-fixed-height\">\n <ng-content select=\"[dashboard]\" />\n </div>\n </div>\n <div\n class=\"position-relative flex-grow-1 flex-shrink-1 mb-6\"\n [class.d-none]=\"!isExpandedSignal()\"\n >\n <ng-container #expandedPortalOutlet cdkPortalOutlet />\n </div>\n </div>\n</div>\n", styles: [".si-dashboard.sticky{padding-inline-end:0;overflow-x:hidden}.si-dashboard .si-dashboard-header.sticky{padding-inline-end:16px}@media(min-width:768px){.si-dashboard .si-dashboard-header.sticky{padding-inline-end:32px}}.si-dashboard .si-dashboard-content.sticky{overflow-y:auto;overflow-x:hidden}.si-dashboard .fix-si-layout-fixed-height{min-block-size:auto}\n"] }]
|
|
443
462
|
}], ctorParameters: () => [], propDecorators: { heading: [{ type: i0.Input, args: [{ isSignal: true, alias: "heading", required: false }] }], enableExpandInteractions: [{ type: i0.Input, args: [{ isSignal: true, alias: "enableExpandInteractions", required: false }] }], sticky: [{ type: i0.Input, args: [{ isSignal: true, alias: "sticky", required: false }] }], hideMenubar: [{ type: i0.Input, args: [{ isSignal: true, alias: "hideMenubar", required: false }] }], expandedPortalOutlet: [{ type: i0.ViewChild, args: ['expandedPortalOutlet', { ...{
|
|
444
463
|
read: CdkPortalOutlet
|
|
445
464
|
}, isSignal: true }] }], dashboardFrame: [{ type: i0.ViewChild, args: ['dashboardFrame', { isSignal: true }] }], dashboard: [{ type: i0.ViewChild, args: ['dashboard', { isSignal: true }] }] } });
|
|
@@ -449,11 +468,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
449
468
|
* SPDX-License-Identifier: MIT
|
|
450
469
|
*/
|
|
451
470
|
class SiDashboardModule {
|
|
452
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
453
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "
|
|
454
|
-
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
471
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
472
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardModule, imports: [SiDashboardCardComponent, SiDashboardComponent], exports: [SiDashboardCardComponent, SiDashboardComponent] });
|
|
473
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardModule, imports: [SiDashboardCardComponent, SiDashboardComponent] });
|
|
455
474
|
}
|
|
456
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
475
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDashboardModule, decorators: [{
|
|
457
476
|
type: NgModule,
|
|
458
477
|
args: [{
|
|
459
478
|
imports: [SiDashboardCardComponent, SiDashboardComponent],
|
|
@@ -478,33 +497,37 @@ class SiWidgetBaseDirective {
|
|
|
478
497
|
* the skeleton indicates the loading of the value. Disable
|
|
479
498
|
* the automatic loading mechanism by setting `SiWidgetBodyBaseComponent.disableAutoLoadingIndicator`.
|
|
480
499
|
*/
|
|
481
|
-
value = input.required(
|
|
500
|
+
value = input.required(/* @ts-ignore */
|
|
501
|
+
...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
|
|
482
502
|
/**
|
|
483
503
|
* Option to disable automatic start of skeleton loading indication.
|
|
484
504
|
*
|
|
485
505
|
* @defaultValue false
|
|
486
506
|
*/
|
|
487
|
-
disableAutoLoadingIndicator = input(false, { ...(ngDevMode ? { debugName: "disableAutoLoadingIndicator" } : {}), transform: booleanAttribute });
|
|
507
|
+
disableAutoLoadingIndicator = input(false, { ...(ngDevMode ? { debugName: "disableAutoLoadingIndicator" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
488
508
|
/**
|
|
489
509
|
* Input to start and stop the skeleton loading indication.
|
|
490
510
|
*
|
|
491
511
|
* @defaultValue false
|
|
492
512
|
*/
|
|
493
|
-
showLoadingIndicatorInput = input(false, { ...(ngDevMode ? { debugName: "showLoadingIndicatorInput" } : {}),
|
|
513
|
+
showLoadingIndicatorInput = input(false, { ...(ngDevMode ? { debugName: "showLoadingIndicatorInput" } : /* istanbul ignore next */ {}),
|
|
494
514
|
// eslint-disable-next-line @angular-eslint/no-input-rename
|
|
495
515
|
alias: 'showLoadingIndicator',
|
|
496
516
|
transform: booleanAttribute });
|
|
497
|
-
showLoadingIndicatorInternal = signal(undefined,
|
|
517
|
+
showLoadingIndicatorInternal = signal(undefined, /* @ts-ignore */
|
|
518
|
+
...(ngDevMode ? [{ debugName: "showLoadingIndicatorInternal" }] : /* istanbul ignore next */ []));
|
|
498
519
|
showLoadingIndicator = computed(() => {
|
|
499
520
|
return this.showLoadingIndicatorInternal() ?? this.showLoadingIndicatorInput();
|
|
500
|
-
},
|
|
521
|
+
}, /* @ts-ignore */
|
|
522
|
+
...(ngDevMode ? [{ debugName: "showLoadingIndicator" }] : /* istanbul ignore next */ []));
|
|
501
523
|
/**
|
|
502
524
|
* Initial delay time in milliseconds before enabling loading indicator.
|
|
503
525
|
* Only used once initially during construction.
|
|
504
526
|
*
|
|
505
527
|
* @defaultValue 300
|
|
506
528
|
*/
|
|
507
|
-
initialLoadingIndicatorDebounceTime = input(300,
|
|
529
|
+
initialLoadingIndicatorDebounceTime = input(300, /* @ts-ignore */
|
|
530
|
+
...(ngDevMode ? [{ debugName: "initialLoadingIndicatorDebounceTime" }] : /* istanbul ignore next */ []));
|
|
508
531
|
loadingTimer;
|
|
509
532
|
ngOnChanges() {
|
|
510
533
|
if (this.disableAutoLoadingIndicator()) {
|
|
@@ -530,10 +553,10 @@ class SiWidgetBaseDirective {
|
|
|
530
553
|
}, this.initialLoadingIndicatorDebounceTime());
|
|
531
554
|
}
|
|
532
555
|
}
|
|
533
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
534
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "
|
|
556
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWidgetBaseDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
557
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.7", type: SiWidgetBaseDirective, isStandalone: true, inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: true, transformFunction: null }, disableAutoLoadingIndicator: { classPropertyName: "disableAutoLoadingIndicator", publicName: "disableAutoLoadingIndicator", isSignal: true, isRequired: false, transformFunction: null }, showLoadingIndicatorInput: { classPropertyName: "showLoadingIndicatorInput", publicName: "showLoadingIndicator", isSignal: true, isRequired: false, transformFunction: null }, initialLoadingIndicatorDebounceTime: { classPropertyName: "initialLoadingIndicatorDebounceTime", publicName: "initialLoadingIndicatorDebounceTime", isSignal: true, isRequired: false, transformFunction: null } }, usesOnChanges: true, ngImport: i0 });
|
|
535
558
|
}
|
|
536
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
559
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWidgetBaseDirective, decorators: [{
|
|
537
560
|
type: Directive
|
|
538
561
|
}], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: true }] }], disableAutoLoadingIndicator: [{ type: i0.Input, args: [{ isSignal: true, alias: "disableAutoLoadingIndicator", required: false }] }], showLoadingIndicatorInput: [{ type: i0.Input, args: [{ isSignal: true, alias: "showLoadingIndicator", required: false }] }], initialLoadingIndicatorDebounceTime: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialLoadingIndicatorDebounceTime", required: false }] }] } });
|
|
539
562
|
|
|
@@ -551,21 +574,23 @@ class SiLinkWidgetComponent extends SiWidgetBaseDirective {
|
|
|
551
574
|
*
|
|
552
575
|
* @defaultValue false
|
|
553
576
|
*/
|
|
554
|
-
showLinkIcons = input(false, { ...(ngDevMode ? { debugName: "showLinkIcons" } : {}), transform: booleanAttribute });
|
|
577
|
+
showLinkIcons = input(false, { ...(ngDevMode ? { debugName: "showLinkIcons" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
555
578
|
/**
|
|
556
579
|
* The number of skeleton progress indication rows.
|
|
557
580
|
*
|
|
558
581
|
* @defaultValue 3
|
|
559
582
|
*/
|
|
560
|
-
numberOfLinks = input(3,
|
|
561
|
-
|
|
583
|
+
numberOfLinks = input(3, /* @ts-ignore */
|
|
584
|
+
...(ngDevMode ? [{ debugName: "numberOfLinks" }] : /* istanbul ignore next */ []));
|
|
585
|
+
ghosts = computed(() => new Array(this.numberOfLinks() ?? 3), /* @ts-ignore */
|
|
586
|
+
...(ngDevMode ? [{ debugName: "ghosts" }] : /* istanbul ignore next */ []));
|
|
562
587
|
icons = addIcons({ elementRight2 });
|
|
563
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
564
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
588
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiLinkWidgetComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
589
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiLinkWidgetComponent, isStandalone: true, selector: "si-link-widget", inputs: { showLinkIcons: { classPropertyName: "showLinkIcons", publicName: "showLinkIcons", isSignal: true, isRequired: false, transformFunction: null }, numberOfLinks: { classPropertyName: "numberOfLinks", publicName: "numberOfLinks", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "si-link-widget" }, usesInheritance: true, ngImport: i0, template: "@if (!showLoadingIndicator() && value()) {\n @for (link of value(); track link) {\n @if (link.action) {\n <button type=\"button\" class=\"btn btn-link\" [siLink]=\"link\">{{\n link.title | translate\n }}</button>\n } @else {\n <a [siLink]=\"link\">\n {{ link.title | translate }}\n @if (showLinkIcons()) {\n <si-icon class=\"link-icon link-end flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n </a>\n }\n }\n} @else {\n @for (some of ghosts(); track $index) {\n <div class=\"si-link-widget-skeleton\"></div>\n }\n}\n", dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "directive", type: SiLinkDirective, selector: "[siLink]", inputs: ["siLink", "siLinkDefaultTarget", "actionParam", "activeClass", "exactMatch", "ariaCurrent"], outputs: ["activeChange"], exportAs: ["siLink"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
565
590
|
}
|
|
566
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
591
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiLinkWidgetComponent, decorators: [{
|
|
567
592
|
type: Component,
|
|
568
|
-
args: [{ selector: 'si-link-widget', imports: [SiIconComponent, SiLinkDirective, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.
|
|
593
|
+
args: [{ selector: 'si-link-widget', imports: [SiIconComponent, SiLinkDirective, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.Eager, host: { class: 'si-link-widget' }, template: "@if (!showLoadingIndicator() && value()) {\n @for (link of value(); track link) {\n @if (link.action) {\n <button type=\"button\" class=\"btn btn-link\" [siLink]=\"link\">{{\n link.title | translate\n }}</button>\n } @else {\n <a [siLink]=\"link\">\n {{ link.title | translate }}\n @if (showLinkIcons()) {\n <si-icon class=\"link-icon link-end flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n </a>\n }\n }\n} @else {\n @for (some of ghosts(); track $index) {\n <div class=\"si-link-widget-skeleton\"></div>\n }\n}\n" }]
|
|
569
594
|
}], propDecorators: { showLinkIcons: [{ type: i0.Input, args: [{ isSignal: true, alias: "showLinkIcons", required: false }] }], numberOfLinks: [{ type: i0.Input, args: [{ isSignal: true, alias: "numberOfLinks", required: false }] }] } });
|
|
570
595
|
|
|
571
596
|
/**
|
|
@@ -579,23 +604,27 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
579
604
|
class SiListWidgetItemComponent extends SiWidgetBaseDirective {
|
|
580
605
|
isLink = computed(() => {
|
|
581
606
|
return typeof this.value()?.label === 'object';
|
|
582
|
-
},
|
|
607
|
+
}, /* @ts-ignore */
|
|
608
|
+
...(ngDevMode ? [{ debugName: "isLink" }] : /* istanbul ignore next */ []));
|
|
583
609
|
badgeColor = computed(() => {
|
|
584
610
|
return this.value()?.badgeColor ? 'bg-' + this.value()?.badgeColor : 'bg-default';
|
|
585
|
-
},
|
|
611
|
+
}, /* @ts-ignore */
|
|
612
|
+
...(ngDevMode ? [{ debugName: "badgeColor" }] : /* istanbul ignore next */ []));
|
|
586
613
|
link = computed(() => {
|
|
587
614
|
return this.value()?.label;
|
|
588
|
-
},
|
|
615
|
+
}, /* @ts-ignore */
|
|
616
|
+
...(ngDevMode ? [{ debugName: "link" }] : /* istanbul ignore next */ []));
|
|
589
617
|
label = computed(() => {
|
|
590
618
|
return this.value()?.label;
|
|
591
|
-
},
|
|
619
|
+
}, /* @ts-ignore */
|
|
620
|
+
...(ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ []));
|
|
592
621
|
icons = addIcons({ elementRight2 });
|
|
593
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
594
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
622
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiListWidgetItemComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
623
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiListWidgetItemComponent, isStandalone: true, selector: "si-list-widget-item", host: { attributes: { "role": "listitem" }, classAttribute: "list-group-item d-flex align-items-center" }, usesInheritance: true, ngImport: i0, template: "@let valueObject = value();\n@if (!showLoadingIndicator() && valueObject) {\n @if (valueObject.badge) {\n <span class=\"mx-0 badge me-4\" [class]=\"badgeColor()\">{{ valueObject.badge | translate }}</span>\n }\n <span class=\"me-auto\">\n @if (!isLink()) {\n <span class=\"si-h5\">{{ label() | translate }}</span>\n } @else {\n <a class=\"\" [siLink]=\"link()\"\n >{{ link().title | translate\n }}<si-icon class=\"link-icon link-start flip-rtl\" [icon]=\"icons.elementRight2\" />\n </a>\n }\n @if (valueObject.description) {\n <div class=\"mt-1 si-body text-secondary\">{{ valueObject.description | translate }}</div>\n }\n </span>\n <span>{{ valueObject.text | translate }}</span>\n @if (valueObject.action) {\n @if (valueObject.action.action) {\n <button\n type=\"button\"\n class=\"btn btn-icon btn-tertiary ms-4 p-2\"\n [attr.aria-label]=\"valueObject.action.title | translate\"\n [siLink]=\"valueObject.action\"\n >\n @if (valueObject.actionIcon) {\n <si-icon class=\"icon\" [icon]=\"valueObject.actionIcon\" />\n }\n </button>\n } @else {\n <a\n class=\"ms-4 p-2\"\n [siLink]=\"valueObject.action\"\n [attr.aria-label]=\"valueObject.action.title | translate\"\n >\n @if (valueObject.actionIcon) {\n <si-icon class=\"icon\" [icon]=\"valueObject.actionIcon\" />\n }\n </a>\n }\n }\n} @else {\n <div class=\"si-link-widget-skeleton my-4\"></div>\n}\n", dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "directive", type: SiLinkDirective, selector: "[siLink]", inputs: ["siLink", "siLinkDefaultTarget", "actionParam", "activeClass", "exactMatch", "ariaCurrent"], outputs: ["activeChange"], exportAs: ["siLink"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
595
624
|
}
|
|
596
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
625
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiListWidgetItemComponent, decorators: [{
|
|
597
626
|
type: Component,
|
|
598
|
-
args: [{ selector: 'si-list-widget-item', imports: [SiIconComponent, SiLinkDirective, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.
|
|
627
|
+
args: [{ selector: 'si-list-widget-item', imports: [SiIconComponent, SiLinkDirective, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.Eager, host: {
|
|
599
628
|
class: 'list-group-item d-flex align-items-center',
|
|
600
629
|
role: 'listitem'
|
|
601
630
|
}, template: "@let valueObject = value();\n@if (!showLoadingIndicator() && valueObject) {\n @if (valueObject.badge) {\n <span class=\"mx-0 badge me-4\" [class]=\"badgeColor()\">{{ valueObject.badge | translate }}</span>\n }\n <span class=\"me-auto\">\n @if (!isLink()) {\n <span class=\"si-h5\">{{ label() | translate }}</span>\n } @else {\n <a class=\"\" [siLink]=\"link()\"\n >{{ link().title | translate\n }}<si-icon class=\"link-icon link-start flip-rtl\" [icon]=\"icons.elementRight2\" />\n </a>\n }\n @if (valueObject.description) {\n <div class=\"mt-1 si-body text-secondary\">{{ valueObject.description | translate }}</div>\n }\n </span>\n <span>{{ valueObject.text | translate }}</span>\n @if (valueObject.action) {\n @if (valueObject.action.action) {\n <button\n type=\"button\"\n class=\"btn btn-icon btn-tertiary ms-4 p-2\"\n [attr.aria-label]=\"valueObject.action.title | translate\"\n [siLink]=\"valueObject.action\"\n >\n @if (valueObject.actionIcon) {\n <si-icon class=\"icon\" [icon]=\"valueObject.actionIcon\" />\n }\n </button>\n } @else {\n <a\n class=\"ms-4 p-2\"\n [siLink]=\"valueObject.action\"\n [attr.aria-label]=\"valueObject.action.title | translate\"\n >\n @if (valueObject.actionIcon) {\n <si-icon class=\"icon\" [icon]=\"valueObject.actionIcon\" />\n }\n </a>\n }\n }\n} @else {\n <div class=\"si-link-widget-skeleton my-4\"></div>\n}\n" }]
|
|
@@ -612,27 +641,30 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
612
641
|
class SiListWidgetBodyComponent extends SiWidgetBaseDirective {
|
|
613
642
|
translateService = injectSiTranslateService();
|
|
614
643
|
/** Optional footer link for the list widget */
|
|
615
|
-
link = input(
|
|
644
|
+
link = input(/* @ts-ignore */
|
|
645
|
+
...(ngDevMode ? [undefined, { debugName: "link" }] : /* istanbul ignore next */ []));
|
|
616
646
|
/**
|
|
617
647
|
* label for the "search placeholder" name
|
|
618
648
|
*
|
|
619
649
|
* @defaultValue
|
|
620
650
|
* ```
|
|
621
|
-
* t(() => $localize`:@@SI_LIST_WIDGET.SEARCH_PLACEHOLDER:Search
|
|
651
|
+
* t(() => $localize`:@@SI_LIST_WIDGET.SEARCH_PLACEHOLDER:Search…`)
|
|
622
652
|
* ```
|
|
623
653
|
*/
|
|
624
|
-
searchPlaceholderLabel = input(t(() => $localize `:@@SI_LIST_WIDGET.SEARCH_PLACEHOLDER:Search
|
|
654
|
+
searchPlaceholderLabel = input(t(() => $localize `:@@SI_LIST_WIDGET.SEARCH_PLACEHOLDER:Search…`), /* @ts-ignore */
|
|
655
|
+
...(ngDevMode ? [{ debugName: "searchPlaceholderLabel" }] : /* istanbul ignore next */ []));
|
|
625
656
|
/**
|
|
626
657
|
* Enable ascending and descending SiListWidgetItem sorting. If enabled,
|
|
627
658
|
* items are initially ascending sorted.
|
|
628
659
|
*/
|
|
629
|
-
sort = input(
|
|
660
|
+
sort = input(/* @ts-ignore */
|
|
661
|
+
...(ngDevMode ? [undefined, { debugName: "sort" }] : /* istanbul ignore next */ []));
|
|
630
662
|
/**
|
|
631
663
|
* Enables the search functionality.
|
|
632
664
|
*
|
|
633
665
|
* @defaultValue false
|
|
634
666
|
*/
|
|
635
|
-
search = input(false, { ...(ngDevMode ? { debugName: "search" } : {}), transform: booleanAttribute });
|
|
667
|
+
search = input(false, { ...(ngDevMode ? { debugName: "search" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
636
668
|
/**
|
|
637
669
|
* Compare function of for two `SiListWidgetItem`s that is used to sort
|
|
638
670
|
* the array of items. The default compares the item labels by using the
|
|
@@ -660,7 +692,8 @@ class SiListWidgetBodyComponent extends SiWidgetBaseDirective {
|
|
|
660
692
|
const aLabel = typeof a.label === 'object' ? a.label.title : a.label;
|
|
661
693
|
const bLabel = typeof b.label === 'object' ? b.label.title : b.label;
|
|
662
694
|
return aLabel.localeCompare(bLabel);
|
|
663
|
-
},
|
|
695
|
+
}, /* @ts-ignore */
|
|
696
|
+
...(ngDevMode ? [{ debugName: "compareFn" }] : /* istanbul ignore next */ []));
|
|
664
697
|
/**
|
|
665
698
|
* Filter function that is used to filter down the list items when the user enters
|
|
666
699
|
* a term in the search bar. Default function.
|
|
@@ -685,15 +718,18 @@ class SiListWidgetBodyComponent extends SiWidgetBaseDirective {
|
|
|
685
718
|
filterFn = input((item, searchTerm) => {
|
|
686
719
|
const aLabel = typeof item.label === 'object' ? item.label.title : item.label;
|
|
687
720
|
return aLabel.toLowerCase().includes(searchTerm.toLowerCase());
|
|
688
|
-
},
|
|
721
|
+
}, /* @ts-ignore */
|
|
722
|
+
...(ngDevMode ? [{ debugName: "filterFn" }] : /* istanbul ignore next */ []));
|
|
689
723
|
/**
|
|
690
724
|
* The number of skeleton progress indication rows.
|
|
691
725
|
*
|
|
692
726
|
* @defaultValue 6
|
|
693
727
|
*/
|
|
694
|
-
numberOfLinks = input(6,
|
|
728
|
+
numberOfLinks = input(6, /* @ts-ignore */
|
|
729
|
+
...(ngDevMode ? [{ debugName: "numberOfLinks" }] : /* istanbul ignore next */ []));
|
|
695
730
|
/** Used to display the defined number of ghost items */
|
|
696
|
-
ghosts = computed(() => new Array(this.numberOfLinks() ?? 6),
|
|
731
|
+
ghosts = computed(() => new Array(this.numberOfLinks() ?? 6), /* @ts-ignore */
|
|
732
|
+
...(ngDevMode ? [{ debugName: "ghosts" }] : /* istanbul ignore next */ []));
|
|
697
733
|
/** Replica of value with pre-translated labels, recomputed when value or language changes. */
|
|
698
734
|
translatedItems = toSignal(toObservable(this.value).pipe(switchMap(items => {
|
|
699
735
|
if (!items) {
|
|
@@ -728,14 +764,16 @@ class SiListWidgetBodyComponent extends SiWidgetBaseDirective {
|
|
|
728
764
|
filteredListWidgetItems = filteredListWidgetItems?.sort((a, b) => (this.compareFn()(a, b) ?? 0) * factor);
|
|
729
765
|
}
|
|
730
766
|
return filteredListWidgetItems;
|
|
731
|
-
},
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
767
|
+
}, /* @ts-ignore */
|
|
768
|
+
...(ngDevMode ? [{ debugName: "filteredListWidgetItems" }] : /* istanbul ignore next */ []));
|
|
769
|
+
searchText = model('', /* @ts-ignore */
|
|
770
|
+
...(ngDevMode ? [{ debugName: "searchText" }] : /* istanbul ignore next */ []));
|
|
771
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiListWidgetBodyComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
772
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiListWidgetBodyComponent, isStandalone: true, selector: "si-list-widget-body", inputs: { link: { classPropertyName: "link", publicName: "link", isSignal: true, isRequired: false, transformFunction: null }, searchPlaceholderLabel: { classPropertyName: "searchPlaceholderLabel", publicName: "searchPlaceholderLabel", isSignal: true, isRequired: false, transformFunction: null }, sort: { classPropertyName: "sort", publicName: "sort", isSignal: true, isRequired: false, transformFunction: null }, search: { classPropertyName: "search", publicName: "search", isSignal: true, isRequired: false, transformFunction: null }, compareFn: { classPropertyName: "compareFn", publicName: "compareFn", isSignal: true, isRequired: false, transformFunction: null }, filterFn: { classPropertyName: "filterFn", publicName: "filterFn", isSignal: true, isRequired: false, transformFunction: null }, numberOfLinks: { classPropertyName: "numberOfLinks", publicName: "numberOfLinks", isSignal: true, isRequired: false, transformFunction: null }, searchText: { classPropertyName: "searchText", publicName: "searchText", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { searchText: "searchTextChange" }, usesInheritance: true, ngImport: i0, template: "@if (search()) {\n <si-search-bar\n class=\"px-6 py-4\"\n showIcon\n colorVariant=\"base-0\"\n [debounceTime]=\"400\"\n [placeholder]=\"searchPlaceholderLabel() | translate\"\n [(ngModel)]=\"searchText\"\n />\n}\n@let filteredListWidgetItemsList = filteredListWidgetItems();\n@if (!showLoadingIndicator() && filteredListWidgetItemsList) {\n @if (filteredListWidgetItemsList.length > 0) {\n <div class=\"list-group list-group-lg\" role=\"list\">\n @for (item of filteredListWidgetItemsList; track $index) {\n <si-list-widget-item [value]=\"item\" />\n }\n </div>\n } @else {\n <ng-content select=\"[empty-state]\" />\n }\n} @else {\n <div class=\"list-group list-group-lg\" role=\"list\">\n @for (some of ghosts(); track $index) {\n <si-list-widget-item [value]=\"undefined\" />\n }\n </div>\n}\n", styles: [":host{background-color:var(--element-base-1);border-radius:var(--element-radius-3);display:flex;flex-direction:column;flex:1 1 auto;overflow:hidden}:host:has(si-search-bar){padding-block-start:8px}:host-context(si-card,si-dashboard-card){padding-block-start:unset!important}.list-group{border-radius:inherit;overflow-y:auto;overflow-x:hidden}\n"], dependencies: [{ kind: "component", type: SiListWidgetItemComponent, selector: "si-list-widget-item" }, { kind: "component", type: SiSearchBarComponent, selector: "si-search-bar", inputs: ["debounceTime", "prohibitedCharacters", "placeholder", "showIcon", "tabbable", "value", "readonly", "colorVariant", "disabled", "maxlength", "clearButtonAriaLabel"], outputs: ["searchChange"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
735
773
|
}
|
|
736
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
774
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiListWidgetBodyComponent, decorators: [{
|
|
737
775
|
type: Component,
|
|
738
|
-
args: [{ selector: 'si-list-widget-body', imports: [SiListWidgetItemComponent, SiSearchBarComponent, SiTranslatePipe, FormsModule], changeDetection: ChangeDetectionStrategy.
|
|
776
|
+
args: [{ selector: 'si-list-widget-body', imports: [SiListWidgetItemComponent, SiSearchBarComponent, SiTranslatePipe, FormsModule], changeDetection: ChangeDetectionStrategy.Eager, host: { class: '' }, template: "@if (search()) {\n <si-search-bar\n class=\"px-6 py-4\"\n showIcon\n colorVariant=\"base-0\"\n [debounceTime]=\"400\"\n [placeholder]=\"searchPlaceholderLabel() | translate\"\n [(ngModel)]=\"searchText\"\n />\n}\n@let filteredListWidgetItemsList = filteredListWidgetItems();\n@if (!showLoadingIndicator() && filteredListWidgetItemsList) {\n @if (filteredListWidgetItemsList.length > 0) {\n <div class=\"list-group list-group-lg\" role=\"list\">\n @for (item of filteredListWidgetItemsList; track $index) {\n <si-list-widget-item [value]=\"item\" />\n }\n </div>\n } @else {\n <ng-content select=\"[empty-state]\" />\n }\n} @else {\n <div class=\"list-group list-group-lg\" role=\"list\">\n @for (some of ghosts(); track $index) {\n <si-list-widget-item [value]=\"undefined\" />\n }\n </div>\n}\n", styles: [":host{background-color:var(--element-base-1);border-radius:var(--element-radius-3);display:flex;flex-direction:column;flex:1 1 auto;overflow:hidden}:host:has(si-search-bar){padding-block-start:8px}:host-context(si-card,si-dashboard-card){padding-block-start:unset!important}.list-group{border-radius:inherit;overflow-y:auto;overflow-x:hidden}\n"] }]
|
|
739
777
|
}], propDecorators: { link: [{ type: i0.Input, args: [{ isSignal: true, alias: "link", required: false }] }], searchPlaceholderLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchPlaceholderLabel", required: false }] }], sort: [{ type: i0.Input, args: [{ isSignal: true, alias: "sort", required: false }] }], search: [{ type: i0.Input, args: [{ isSignal: true, alias: "search", required: false }] }], compareFn: [{ type: i0.Input, args: [{ isSignal: true, alias: "compareFn", required: false }] }], filterFn: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterFn", required: false }] }], numberOfLinks: [{ type: i0.Input, args: [{ isSignal: true, alias: "numberOfLinks", required: false }] }], searchText: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchText", required: false }] }, { type: i0.Output, args: ["searchTextChange"] }] } });
|
|
740
778
|
|
|
741
779
|
/**
|
|
@@ -749,42 +787,48 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
749
787
|
class SiListWidgetComponent extends SiWidgetBaseDirective {
|
|
750
788
|
icons = addIcons({ elementRight2, elementSortDown, elementSortUp });
|
|
751
789
|
/** List widget heading. */
|
|
752
|
-
heading = input(
|
|
790
|
+
heading = input(/* @ts-ignore */
|
|
791
|
+
...(ngDevMode ? [undefined, { debugName: "heading" }] : /* istanbul ignore next */ []));
|
|
753
792
|
/** Optional footer link for the list widget */
|
|
754
|
-
link = input(
|
|
793
|
+
link = input(/* @ts-ignore */
|
|
794
|
+
...(ngDevMode ? [undefined, { debugName: "link" }] : /* istanbul ignore next */ []));
|
|
755
795
|
/**
|
|
756
796
|
* label for the "search placeholder" name
|
|
757
797
|
*
|
|
758
798
|
* @defaultValue
|
|
759
799
|
* ```
|
|
760
|
-
* t(() => $localize`:@@SI_LIST_WIDGET.SEARCH_PLACEHOLDER:Search
|
|
800
|
+
* t(() => $localize`:@@SI_LIST_WIDGET.SEARCH_PLACEHOLDER:Search…`)
|
|
761
801
|
* ```
|
|
762
802
|
*/
|
|
763
|
-
searchPlaceholderLabel = input(t(() => $localize `:@@SI_LIST_WIDGET.SEARCH_PLACEHOLDER:Search
|
|
803
|
+
searchPlaceholderLabel = input(t(() => $localize `:@@SI_LIST_WIDGET.SEARCH_PLACEHOLDER:Search…`), /* @ts-ignore */
|
|
804
|
+
...(ngDevMode ? [{ debugName: "searchPlaceholderLabel" }] : /* istanbul ignore next */ []));
|
|
764
805
|
/**
|
|
765
806
|
* @defaultValue
|
|
766
807
|
* ```
|
|
767
808
|
* t(() => $localize`:@@SI_LIST_WIDGET.SORT_ASCENDING:Sort ascending`)
|
|
768
809
|
* ```
|
|
769
810
|
*/
|
|
770
|
-
sortAscendingLabel = input(t(() => $localize `:@@SI_LIST_WIDGET.SORT_ASCENDING:Sort ascending`),
|
|
811
|
+
sortAscendingLabel = input(t(() => $localize `:@@SI_LIST_WIDGET.SORT_ASCENDING:Sort ascending`), /* @ts-ignore */
|
|
812
|
+
...(ngDevMode ? [{ debugName: "sortAscendingLabel" }] : /* istanbul ignore next */ []));
|
|
771
813
|
/**
|
|
772
814
|
* @defaultValue
|
|
773
815
|
* ```
|
|
774
816
|
* t(() => $localize`:@@SI_LIST_WIDGET.SORT_DESCENDING:Sort descending`)
|
|
775
817
|
* ```
|
|
776
818
|
*/
|
|
777
|
-
sortDescendingLabel = input(t(() => $localize `:@@SI_LIST_WIDGET.SORT_DESCENDING:Sort descending`),
|
|
819
|
+
sortDescendingLabel = input(t(() => $localize `:@@SI_LIST_WIDGET.SORT_DESCENDING:Sort descending`), /* @ts-ignore */
|
|
820
|
+
...(ngDevMode ? [{ debugName: "sortDescendingLabel" }] : /* istanbul ignore next */ []));
|
|
778
821
|
/**
|
|
779
822
|
* Set `ASC` of ascending sorting, `DSC` for descending sorting and `undefined` for no sorting.
|
|
780
823
|
*/
|
|
781
|
-
sort = model(
|
|
824
|
+
sort = model(/* @ts-ignore */
|
|
825
|
+
...(ngDevMode ? [undefined, { debugName: "sort" }] : /* istanbul ignore next */ []));
|
|
782
826
|
/**
|
|
783
827
|
* Enables the search functionality.
|
|
784
828
|
*
|
|
785
829
|
* @defaultValue false
|
|
786
830
|
*/
|
|
787
|
-
search = input(false, { ...(ngDevMode ? { debugName: "search" } : {}), transform: booleanAttribute });
|
|
831
|
+
search = input(false, { ...(ngDevMode ? { debugName: "search" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
788
832
|
/**
|
|
789
833
|
* Compare function of for two `SiListWidgetItem`s that is used to sort
|
|
790
834
|
* the array of items. The default compares the item labels by using the
|
|
@@ -812,7 +856,8 @@ class SiListWidgetComponent extends SiWidgetBaseDirective {
|
|
|
812
856
|
const aLabel = typeof a.label === 'object' ? a.label.title : a.label;
|
|
813
857
|
const bLabel = typeof b.label === 'object' ? b.label.title : b.label;
|
|
814
858
|
return aLabel.localeCompare(bLabel);
|
|
815
|
-
},
|
|
859
|
+
}, /* @ts-ignore */
|
|
860
|
+
...(ngDevMode ? [{ debugName: "compareFn" }] : /* istanbul ignore next */ []));
|
|
816
861
|
/**
|
|
817
862
|
* Filter function that is used to filter down the list items when the user enters
|
|
818
863
|
* a term in the search bar. Default function.
|
|
@@ -837,21 +882,25 @@ class SiListWidgetComponent extends SiWidgetBaseDirective {
|
|
|
837
882
|
filterFn = input((item, searchTerm) => {
|
|
838
883
|
const aLabel = typeof item.label === 'object' ? item.label.title : item.label;
|
|
839
884
|
return aLabel.toLowerCase().includes(searchTerm.toLowerCase());
|
|
840
|
-
},
|
|
885
|
+
}, /* @ts-ignore */
|
|
886
|
+
...(ngDevMode ? [{ debugName: "filterFn" }] : /* istanbul ignore next */ []));
|
|
841
887
|
/**
|
|
842
888
|
* The number of skeleton progress indication rows.
|
|
843
889
|
*
|
|
844
890
|
* @defaultValue 6
|
|
845
891
|
*/
|
|
846
|
-
numberOfLinks = input(6,
|
|
892
|
+
numberOfLinks = input(6, /* @ts-ignore */
|
|
893
|
+
...(ngDevMode ? [{ debugName: "numberOfLinks" }] : /* istanbul ignore next */ []));
|
|
847
894
|
/**
|
|
848
895
|
* Optional accent line
|
|
849
896
|
*/
|
|
850
|
-
accentLine = input(
|
|
897
|
+
accentLine = input(/* @ts-ignore */
|
|
898
|
+
...(ngDevMode ? [undefined, { debugName: "accentLine" }] : /* istanbul ignore next */ []));
|
|
851
899
|
accentClass = computed(() => {
|
|
852
900
|
const accentLine = this.accentLine();
|
|
853
901
|
return accentLine ? 'accent-' + accentLine : '';
|
|
854
|
-
},
|
|
902
|
+
}, /* @ts-ignore */
|
|
903
|
+
...(ngDevMode ? [{ debugName: "accentClass" }] : /* istanbul ignore next */ []));
|
|
855
904
|
/** The menu item array used to display the sort button. */
|
|
856
905
|
sortAction = computed(() => {
|
|
857
906
|
const sortAction = [
|
|
@@ -872,7 +921,8 @@ class SiListWidgetComponent extends SiWidgetBaseDirective {
|
|
|
872
921
|
sortAction[0].icon = this.icons.elementSortDown;
|
|
873
922
|
}
|
|
874
923
|
return sortAction;
|
|
875
|
-
},
|
|
924
|
+
}, /* @ts-ignore */
|
|
925
|
+
...(ngDevMode ? [{ debugName: "sortAction" }] : /* istanbul ignore next */ []));
|
|
876
926
|
doSort() {
|
|
877
927
|
if (this.sort() === 'ASC') {
|
|
878
928
|
this.sort.set('DSC');
|
|
@@ -881,10 +931,10 @@ class SiListWidgetComponent extends SiWidgetBaseDirective {
|
|
|
881
931
|
this.sort.set('ASC');
|
|
882
932
|
}
|
|
883
933
|
}
|
|
884
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
885
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
934
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiListWidgetComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
935
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiListWidgetComponent, isStandalone: true, selector: "si-list-widget", inputs: { heading: { classPropertyName: "heading", publicName: "heading", isSignal: true, isRequired: false, transformFunction: null }, link: { classPropertyName: "link", publicName: "link", isSignal: true, isRequired: false, transformFunction: null }, searchPlaceholderLabel: { classPropertyName: "searchPlaceholderLabel", publicName: "searchPlaceholderLabel", isSignal: true, isRequired: false, transformFunction: null }, sortAscendingLabel: { classPropertyName: "sortAscendingLabel", publicName: "sortAscendingLabel", isSignal: true, isRequired: false, transformFunction: null }, sortDescendingLabel: { classPropertyName: "sortDescendingLabel", publicName: "sortDescendingLabel", isSignal: true, isRequired: false, transformFunction: null }, sort: { classPropertyName: "sort", publicName: "sort", isSignal: true, isRequired: false, transformFunction: null }, search: { classPropertyName: "search", publicName: "search", isSignal: true, isRequired: false, transformFunction: null }, compareFn: { classPropertyName: "compareFn", publicName: "compareFn", isSignal: true, isRequired: false, transformFunction: null }, filterFn: { classPropertyName: "filterFn", publicName: "filterFn", isSignal: true, isRequired: false, transformFunction: null }, numberOfLinks: { classPropertyName: "numberOfLinks", publicName: "numberOfLinks", isSignal: true, isRequired: false, transformFunction: null }, accentLine: { classPropertyName: "accentLine", publicName: "accentLine", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { sort: "sortChange" }, host: { classAttribute: "si-list-widget" }, usesInheritance: true, ngImport: i0, template: "<si-card\n actionBarViewType=\"expanded\"\n class=\"h-100\"\n [class]=\"accentClass()\"\n [heading]=\"heading()\"\n [primaryActions]=\"sort() ? sortAction() : []\"\n>\n <si-list-widget-body\n body\n [compareFn]=\"compareFn()\"\n [filterFn]=\"filterFn()\"\n [numberOfLinks]=\"numberOfLinks()\"\n [searchPlaceholderLabel]=\"searchPlaceholderLabel()\"\n [search]=\"search()\"\n [sort]=\"sort()\"\n [value]=\"value()\"\n [showLoadingIndicator]=\"showLoadingIndicator()\"\n >\n <ng-content select=\"[empty-state]\" empty-state />\n </si-list-widget-body>\n\n @let linkValue = link();\n @if (linkValue) {\n <div class=\"card-footer\" footer>\n @if (!linkValue.action) {\n <a [siLink]=\"linkValue\">\n {{ linkValue.title | translate }}\n <si-icon class=\"link-icon link-end flip-rtl\" [icon]=\"icons.elementRight2\" />\n </a>\n } @else {\n <button type=\"button\" class=\"btn btn-link\" [siLink]=\"linkValue\"\n >{{ linkValue.title | translate }}\n </button>\n }\n </div>\n }\n</si-card>\n", dependencies: [{ kind: "component", type: SiCardComponent, selector: "si-card", inputs: ["primaryActions", "secondaryActions", "actionParam", "actionBarViewType", "actionBarTitle"] }, { kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "directive", type: SiLinkDirective, selector: "[siLink]", inputs: ["siLink", "siLinkDefaultTarget", "actionParam", "activeClass", "exactMatch", "ariaCurrent"], outputs: ["activeChange"], exportAs: ["siLink"] }, { kind: "component", type: SiListWidgetBodyComponent, selector: "si-list-widget-body", inputs: ["link", "searchPlaceholderLabel", "sort", "search", "compareFn", "filterFn", "numberOfLinks", "searchText"], outputs: ["searchTextChange"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
886
936
|
}
|
|
887
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
937
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiListWidgetComponent, decorators: [{
|
|
888
938
|
type: Component,
|
|
889
939
|
args: [{ selector: 'si-list-widget', imports: [
|
|
890
940
|
SiCardComponent,
|
|
@@ -892,7 +942,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
892
942
|
SiLinkDirective,
|
|
893
943
|
SiListWidgetBodyComponent,
|
|
894
944
|
SiTranslatePipe
|
|
895
|
-
], changeDetection: ChangeDetectionStrategy.
|
|
945
|
+
], changeDetection: ChangeDetectionStrategy.Eager, host: { class: 'si-list-widget' }, template: "<si-card\n actionBarViewType=\"expanded\"\n class=\"h-100\"\n [class]=\"accentClass()\"\n [heading]=\"heading()\"\n [primaryActions]=\"sort() ? sortAction() : []\"\n>\n <si-list-widget-body\n body\n [compareFn]=\"compareFn()\"\n [filterFn]=\"filterFn()\"\n [numberOfLinks]=\"numberOfLinks()\"\n [searchPlaceholderLabel]=\"searchPlaceholderLabel()\"\n [search]=\"search()\"\n [sort]=\"sort()\"\n [value]=\"value()\"\n [showLoadingIndicator]=\"showLoadingIndicator()\"\n >\n <ng-content select=\"[empty-state]\" empty-state />\n </si-list-widget-body>\n\n @let linkValue = link();\n @if (linkValue) {\n <div class=\"card-footer\" footer>\n @if (!linkValue.action) {\n <a [siLink]=\"linkValue\">\n {{ linkValue.title | translate }}\n <si-icon class=\"link-icon link-end flip-rtl\" [icon]=\"icons.elementRight2\" />\n </a>\n } @else {\n <button type=\"button\" class=\"btn btn-link\" [siLink]=\"linkValue\"\n >{{ linkValue.title | translate }}\n </button>\n }\n </div>\n }\n</si-card>\n" }]
|
|
896
946
|
}], propDecorators: { heading: [{ type: i0.Input, args: [{ isSignal: true, alias: "heading", required: false }] }], link: [{ type: i0.Input, args: [{ isSignal: true, alias: "link", required: false }] }], searchPlaceholderLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchPlaceholderLabel", required: false }] }], sortAscendingLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "sortAscendingLabel", required: false }] }], sortDescendingLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "sortDescendingLabel", required: false }] }], sort: [{ type: i0.Input, args: [{ isSignal: true, alias: "sort", required: false }] }, { type: i0.Output, args: ["sortChange"] }], search: [{ type: i0.Input, args: [{ isSignal: true, alias: "search", required: false }] }], compareFn: [{ type: i0.Input, args: [{ isSignal: true, alias: "compareFn", required: false }] }], filterFn: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterFn", required: false }] }], numberOfLinks: [{ type: i0.Input, args: [{ isSignal: true, alias: "numberOfLinks", required: false }] }], accentLine: [{ type: i0.Input, args: [{ isSignal: true, alias: "accentLine", required: false }] }] } });
|
|
897
947
|
|
|
898
948
|
/**
|
|
@@ -908,18 +958,19 @@ class SiTimelineWidgetItemComponent extends SiWidgetBaseDirective {
|
|
|
908
958
|
*
|
|
909
959
|
* @defaultValue `true`
|
|
910
960
|
*/
|
|
911
|
-
showDescription = input(true,
|
|
961
|
+
showDescription = input(true, /* @ts-ignore */
|
|
962
|
+
...(ngDevMode ? [{ debugName: "showDescription" }] : /* istanbul ignore next */ []));
|
|
912
963
|
/**
|
|
913
964
|
* Aria label text for actions button dropdown.
|
|
914
965
|
*/
|
|
915
|
-
ariaLabelDropdown = t(() => $localize `:@@SI_DASHBOARD.EXPAND_WIDGET_ACTIONS:
|
|
966
|
+
ariaLabelDropdown = t(() => $localize `:@@SI_DASHBOARD.EXPAND_WIDGET_ACTIONS:Show actions`);
|
|
916
967
|
activatedRoute = inject(ActivatedRoute, { optional: true });
|
|
917
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
918
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
968
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiTimelineWidgetItemComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
969
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiTimelineWidgetItemComponent, isStandalone: true, selector: "si-timeline-widget-item", inputs: { showDescription: { classPropertyName: "showDescription", publicName: "showDescription", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "listitem" } }, usesInheritance: true, ngImport: i0, template: "@let valueObject = value();\n@if (!showLoadingIndicator() && valueObject) {\n <div class=\"d-flex flex-row gap-4\" [class.pe-4]=\"!valueObject.action\">\n <div class=\"d-flex flex-column align-items-center gap-1 pt-4\">\n <span class=\"icon icon-stack\">\n <si-icon [class]=\"valueObject.iconColor\" [icon]=\"valueObject.icon\" />\n @if (valueObject.stackedIcon) {\n <si-icon [class]=\"valueObject.stackedIconColor\" [icon]=\"valueObject.stackedIcon\" />\n }\n </span>\n @if (valueObject.iconAlt) {\n <span class=\"visually-hidden\">{{ valueObject.iconAlt | translate }}</span>\n }\n <div class=\"si-timeline-widget-item-lower-line\"></div>\n </div>\n <div class=\"d-flex flex-column gap-1 py-4 flex-grow-1\">\n <span class=\"si-caption text-secondary\">{{ valueObject.timeStamp | translate }}</span>\n <span class=\"si-h5\">{{ valueObject.title | translate }}</span>\n @if (valueObject.description) {\n <span class=\"si-body text-secondary\">{{ valueObject.description | translate }}</span>\n }\n </div>\n @if (valueObject.action) {\n @let action = valueObject.action;\n <div class=\"si-timeline-widget-item-action align-self-center\">\n @if (action.type === 'action') {\n <button\n type=\"button\"\n class=\"d-flex btn\"\n [class]=\"action.customClass ?? 'btn-tertiary'\"\n [class.btn-icon]=\"action.iconOnly\"\n (click)=\"action.action(action)\"\n >\n @if (action.icon) {\n <si-icon class=\"icon\" [icon]=\"action.icon\" />\n }\n <span [class.visually-hidden]=\"action.iconOnly\">\n {{ action.label | translate }}\n </span>\n </button>\n } @else if (action.type === 'router-link') {\n <a\n class=\"d-flex btn btn-tertiary-ghost\"\n [routerLink]=\"action.routerLink\"\n [queryParams]=\"action.extras?.queryParams\"\n [queryParamsHandling]=\"action.extras?.queryParamsHandling\"\n [fragment]=\"action.extras?.fragment\"\n [state]=\"action.extras?.state\"\n [relativeTo]=\"action.extras?.relativeTo ?? activatedRoute\"\n [preserveFragment]=\"action.extras?.preserveFragment\"\n [skipLocationChange]=\"action.extras?.skipLocationChange\"\n [replaceUrl]=\"action.extras?.replaceUrl\"\n [attr.aria-label]=\"action.label | translate\"\n [class.btn-icon]=\"action.iconOnly\"\n >\n @if (action.icon) {\n <si-icon class=\"icon\" [icon]=\"action.icon\" />\n }\n <span [class.visually-hidden]=\"action.iconOnly\">\n {{ action.label | translate }}\n </span></a\n >\n } @else if (action.type === 'link') {\n <a\n class=\"d-flex btn btn-tertiary-ghost\"\n [href]=\"action.href\"\n [target]=\"action.target\"\n [attr.aria-label]=\"action.label | translate\"\n [class.btn-icon]=\"action.iconOnly\"\n >\n @if (action.icon) {\n <si-icon class=\"icon\" [icon]=\"action.icon\" />\n }\n <span [class.visually-hidden]=\"action.iconOnly\">\n {{ action.label | translate }}\n </span></a\n >\n } @else if (action.type === 'menu') {\n <button\n type=\"button\"\n class=\"btn btn-icon btn-tertiary element-options-vertical\"\n [attr.aria-label]=\"ariaLabelDropdown | translate\"\n [cdkMenuTriggerFor]=\"actionMenu\"\n ></button>\n\n <ng-template #actionMenu>\n <si-menu-factory [items]=\"action.menuItems\" />\n </ng-template>\n }\n </div>\n }\n </div>\n} @else {\n <div class=\"d-flex flex-row\">\n <div class=\"d-flex flex-column align-items-center gap-1 pt-4 pe-4\">\n <div class=\"p-5 si-skeleton\"></div>\n </div>\n <div class=\"d-flex flex-column flex-grow-1 gap-1 py-4\">\n <span class=\"si-link-widget-skeleton\"></span>\n <span class=\"si-link-widget-skeleton\" [class.w-50]=\"!showDescription()\"></span>\n @if (showDescription()) {\n <span class=\"si-link-widget-skeleton w-50\"></span>\n }\n </div>\n </div>\n}\n", styles: [":host(:last-child) .si-timeline-widget-item-lower-line{display:none}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "ngmodule", type: A11yModule }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "browserUrl", "routerLink"] }, { kind: "ngmodule", type: SiMenuModule }, { kind: "component", type: i1$2.SiMenuFactoryComponent, selector: "si-menu-factory", inputs: ["items", "actionParam"] }, { kind: "directive", type: CdkMenuTrigger, selector: "[cdkMenuTriggerFor]", inputs: ["cdkMenuTriggerFor", "cdkMenuPosition", "cdkMenuTriggerData", "cdkMenuTriggerTransformOriginOn"], outputs: ["cdkMenuOpened", "cdkMenuClosed"], exportAs: ["cdkMenuTriggerFor"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
919
970
|
}
|
|
920
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
971
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiTimelineWidgetItemComponent, decorators: [{
|
|
921
972
|
type: Component,
|
|
922
|
-
args: [{ selector: 'si-timeline-widget-item', imports: [SiIconComponent, SiTranslatePipe, A11yModule, RouterLink, SiMenuModule, CdkMenuTrigger], changeDetection: ChangeDetectionStrategy.
|
|
973
|
+
args: [{ selector: 'si-timeline-widget-item', imports: [SiIconComponent, SiTranslatePipe, A11yModule, RouterLink, SiMenuModule, CdkMenuTrigger], changeDetection: ChangeDetectionStrategy.Eager, host: {
|
|
923
974
|
role: 'listitem'
|
|
924
975
|
}, template: "@let valueObject = value();\n@if (!showLoadingIndicator() && valueObject) {\n <div class=\"d-flex flex-row gap-4\" [class.pe-4]=\"!valueObject.action\">\n <div class=\"d-flex flex-column align-items-center gap-1 pt-4\">\n <span class=\"icon icon-stack\">\n <si-icon [class]=\"valueObject.iconColor\" [icon]=\"valueObject.icon\" />\n @if (valueObject.stackedIcon) {\n <si-icon [class]=\"valueObject.stackedIconColor\" [icon]=\"valueObject.stackedIcon\" />\n }\n </span>\n @if (valueObject.iconAlt) {\n <span class=\"visually-hidden\">{{ valueObject.iconAlt | translate }}</span>\n }\n <div class=\"si-timeline-widget-item-lower-line\"></div>\n </div>\n <div class=\"d-flex flex-column gap-1 py-4 flex-grow-1\">\n <span class=\"si-caption text-secondary\">{{ valueObject.timeStamp | translate }}</span>\n <span class=\"si-h5\">{{ valueObject.title | translate }}</span>\n @if (valueObject.description) {\n <span class=\"si-body text-secondary\">{{ valueObject.description | translate }}</span>\n }\n </div>\n @if (valueObject.action) {\n @let action = valueObject.action;\n <div class=\"si-timeline-widget-item-action align-self-center\">\n @if (action.type === 'action') {\n <button\n type=\"button\"\n class=\"d-flex btn\"\n [class]=\"action.customClass ?? 'btn-tertiary'\"\n [class.btn-icon]=\"action.iconOnly\"\n (click)=\"action.action(action)\"\n >\n @if (action.icon) {\n <si-icon class=\"icon\" [icon]=\"action.icon\" />\n }\n <span [class.visually-hidden]=\"action.iconOnly\">\n {{ action.label | translate }}\n </span>\n </button>\n } @else if (action.type === 'router-link') {\n <a\n class=\"d-flex btn btn-tertiary-ghost\"\n [routerLink]=\"action.routerLink\"\n [queryParams]=\"action.extras?.queryParams\"\n [queryParamsHandling]=\"action.extras?.queryParamsHandling\"\n [fragment]=\"action.extras?.fragment\"\n [state]=\"action.extras?.state\"\n [relativeTo]=\"action.extras?.relativeTo ?? activatedRoute\"\n [preserveFragment]=\"action.extras?.preserveFragment\"\n [skipLocationChange]=\"action.extras?.skipLocationChange\"\n [replaceUrl]=\"action.extras?.replaceUrl\"\n [attr.aria-label]=\"action.label | translate\"\n [class.btn-icon]=\"action.iconOnly\"\n >\n @if (action.icon) {\n <si-icon class=\"icon\" [icon]=\"action.icon\" />\n }\n <span [class.visually-hidden]=\"action.iconOnly\">\n {{ action.label | translate }}\n </span></a\n >\n } @else if (action.type === 'link') {\n <a\n class=\"d-flex btn btn-tertiary-ghost\"\n [href]=\"action.href\"\n [target]=\"action.target\"\n [attr.aria-label]=\"action.label | translate\"\n [class.btn-icon]=\"action.iconOnly\"\n >\n @if (action.icon) {\n <si-icon class=\"icon\" [icon]=\"action.icon\" />\n }\n <span [class.visually-hidden]=\"action.iconOnly\">\n {{ action.label | translate }}\n </span></a\n >\n } @else if (action.type === 'menu') {\n <button\n type=\"button\"\n class=\"btn btn-icon btn-tertiary element-options-vertical\"\n [attr.aria-label]=\"ariaLabelDropdown | translate\"\n [cdkMenuTriggerFor]=\"actionMenu\"\n ></button>\n\n <ng-template #actionMenu>\n <si-menu-factory [items]=\"action.menuItems\" />\n </ng-template>\n }\n </div>\n }\n </div>\n} @else {\n <div class=\"d-flex flex-row\">\n <div class=\"d-flex flex-column align-items-center gap-1 pt-4 pe-4\">\n <div class=\"p-5 si-skeleton\"></div>\n </div>\n <div class=\"d-flex flex-column flex-grow-1 gap-1 py-4\">\n <span class=\"si-link-widget-skeleton\"></span>\n <span class=\"si-link-widget-skeleton\" [class.w-50]=\"!showDescription()\"></span>\n @if (showDescription()) {\n <span class=\"si-link-widget-skeleton w-50\"></span>\n }\n </div>\n </div>\n}\n", styles: [":host(:last-child) .si-timeline-widget-item-lower-line{display:none}\n"] }]
|
|
925
976
|
}], propDecorators: { showDescription: [{ type: i0.Input, args: [{ isSignal: true, alias: "showDescription", required: false }] }] } });
|
|
@@ -934,23 +985,26 @@ class SiTimelineWidgetBodyComponent extends SiWidgetBaseDirective {
|
|
|
934
985
|
*
|
|
935
986
|
* @defaultValue 4
|
|
936
987
|
*/
|
|
937
|
-
numberOfItems = input(4,
|
|
988
|
+
numberOfItems = input(4, /* @ts-ignore */
|
|
989
|
+
...(ngDevMode ? [{ debugName: "numberOfItems" }] : /* istanbul ignore next */ []));
|
|
938
990
|
/**
|
|
939
991
|
* Whether to show or hide the description row during skeleton progress indication.
|
|
940
992
|
*
|
|
941
993
|
* @defaultValue `true`
|
|
942
994
|
*/
|
|
943
|
-
showDescription = input(true,
|
|
995
|
+
showDescription = input(true, /* @ts-ignore */
|
|
996
|
+
...(ngDevMode ? [{ debugName: "showDescription" }] : /* istanbul ignore next */ []));
|
|
944
997
|
/** Used to display the defined number of ghost items */
|
|
945
998
|
ghosts = computed(() => {
|
|
946
999
|
return new Array(this.numberOfItems() ?? 4);
|
|
947
|
-
},
|
|
948
|
-
|
|
949
|
-
static
|
|
1000
|
+
}, /* @ts-ignore */
|
|
1001
|
+
...(ngDevMode ? [{ debugName: "ghosts" }] : /* istanbul ignore next */ []));
|
|
1002
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiTimelineWidgetBodyComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1003
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiTimelineWidgetBodyComponent, isStandalone: true, selector: "si-timeline-widget-body", inputs: { numberOfItems: { classPropertyName: "numberOfItems", publicName: "numberOfItems", isSignal: true, isRequired: false, transformFunction: null }, showDescription: { classPropertyName: "showDescription", publicName: "showDescription", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: "@let valueObject = value();\n<div\n class=\"focus-inside\"\n tabindex=\"0\"\n [attr.role]=\"\n (!showLoadingIndicator() && valueObject && valueObject.length > 0) || showLoadingIndicator()\n ? 'list'\n : null\n \"\n>\n @if (!showLoadingIndicator() && valueObject) {\n @if (valueObject && valueObject.length > 0) {\n @for (item of valueObject; track $index) {\n <si-timeline-widget-item [value]=\"item\" />\n }\n } @else {\n <ng-content select=\"[empty-state]\" />\n }\n } @else {\n @for (some of ghosts(); track $index) {\n <si-timeline-widget-item [value]=\"undefined\" [showDescription]=\"showDescription()\" />\n }\n }\n</div>\n", styles: [":host{background-color:var(--element-base-1);flex:auto;overflow:hidden}div{block-size:100%;padding-inline:16px 8px;overflow-y:auto;overflow-x:hidden}\n"], dependencies: [{ kind: "component", type: SiTimelineWidgetItemComponent, selector: "si-timeline-widget-item", inputs: ["showDescription"] }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
950
1004
|
}
|
|
951
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1005
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiTimelineWidgetBodyComponent, decorators: [{
|
|
952
1006
|
type: Component,
|
|
953
|
-
args: [{ selector: 'si-timeline-widget-body', imports: [SiTimelineWidgetItemComponent], changeDetection: ChangeDetectionStrategy.
|
|
1007
|
+
args: [{ selector: 'si-timeline-widget-body', imports: [SiTimelineWidgetItemComponent], changeDetection: ChangeDetectionStrategy.Eager, template: "@let valueObject = value();\n<div\n class=\"focus-inside\"\n tabindex=\"0\"\n [attr.role]=\"\n (!showLoadingIndicator() && valueObject && valueObject.length > 0) || showLoadingIndicator()\n ? 'list'\n : null\n \"\n>\n @if (!showLoadingIndicator() && valueObject) {\n @if (valueObject && valueObject.length > 0) {\n @for (item of valueObject; track $index) {\n <si-timeline-widget-item [value]=\"item\" />\n }\n } @else {\n <ng-content select=\"[empty-state]\" />\n }\n } @else {\n @for (some of ghosts(); track $index) {\n <si-timeline-widget-item [value]=\"undefined\" [showDescription]=\"showDescription()\" />\n }\n }\n</div>\n", styles: [":host{background-color:var(--element-base-1);flex:auto;overflow:hidden}div{block-size:100%;padding-inline:16px 8px;overflow-y:auto;overflow-x:hidden}\n"] }]
|
|
954
1008
|
}], propDecorators: { numberOfItems: [{ type: i0.Input, args: [{ isSignal: true, alias: "numberOfItems", required: false }] }], showDescription: [{ type: i0.Input, args: [{ isSignal: true, alias: "showDescription", required: false }] }] } });
|
|
955
1009
|
|
|
956
1010
|
/**
|
|
@@ -961,50 +1015,58 @@ class SiTimelineWidgetComponent extends SiWidgetBaseDirective {
|
|
|
961
1015
|
/**
|
|
962
1016
|
* Timeline widget header text.
|
|
963
1017
|
*/
|
|
964
|
-
heading = input(
|
|
1018
|
+
heading = input(/* @ts-ignore */
|
|
1019
|
+
...(ngDevMode ? [undefined, { debugName: "heading" }] : /* istanbul ignore next */ []));
|
|
965
1020
|
/**
|
|
966
1021
|
* Input list of primary action items. Supports up to **4** actions and omits additional ones.
|
|
967
1022
|
*
|
|
968
1023
|
* @defaultValue []
|
|
969
1024
|
*/
|
|
970
|
-
primaryActions = input([],
|
|
1025
|
+
primaryActions = input([], /* @ts-ignore */
|
|
1026
|
+
...(ngDevMode ? [{ debugName: "primaryActions" }] : /* istanbul ignore next */ []));
|
|
971
1027
|
/**
|
|
972
1028
|
* Input list of secondary action items.
|
|
973
1029
|
*
|
|
974
1030
|
* @defaultValue []
|
|
975
1031
|
*/
|
|
976
|
-
secondaryActions = input([],
|
|
1032
|
+
secondaryActions = input([], /* @ts-ignore */
|
|
1033
|
+
...(ngDevMode ? [{ debugName: "secondaryActions" }] : /* istanbul ignore next */ []));
|
|
977
1034
|
/**
|
|
978
1035
|
* Link that leads the user to more information
|
|
979
1036
|
* or triggers and action. The `link.title` is displayed.
|
|
980
1037
|
* The title will be translated.
|
|
981
1038
|
*/
|
|
982
|
-
link = input(
|
|
1039
|
+
link = input(/* @ts-ignore */
|
|
1040
|
+
...(ngDevMode ? [undefined, { debugName: "link" }] : /* istanbul ignore next */ []));
|
|
983
1041
|
/**
|
|
984
1042
|
* Number of skeleton progress indication items.
|
|
985
1043
|
*
|
|
986
1044
|
* @defaultValue 4
|
|
987
1045
|
*/
|
|
988
|
-
numberOfItems = input(4,
|
|
1046
|
+
numberOfItems = input(4, /* @ts-ignore */
|
|
1047
|
+
...(ngDevMode ? [{ debugName: "numberOfItems" }] : /* istanbul ignore next */ []));
|
|
989
1048
|
/**
|
|
990
1049
|
* Whether to show or hide the description row during skeleton progress indication.
|
|
991
1050
|
*
|
|
992
1051
|
* @defaultValue `true`
|
|
993
1052
|
*/
|
|
994
|
-
showDescription = input(true,
|
|
1053
|
+
showDescription = input(true, /* @ts-ignore */
|
|
1054
|
+
...(ngDevMode ? [{ debugName: "showDescription" }] : /* istanbul ignore next */ []));
|
|
995
1055
|
/**
|
|
996
1056
|
* Optional accent line
|
|
997
1057
|
*/
|
|
998
|
-
accentLine = input(
|
|
1058
|
+
accentLine = input(/* @ts-ignore */
|
|
1059
|
+
...(ngDevMode ? [undefined, { debugName: "accentLine" }] : /* istanbul ignore next */ []));
|
|
999
1060
|
accentClass = computed(() => {
|
|
1000
1061
|
const accentLine = this.accentLine();
|
|
1001
1062
|
return accentLine ? 'accent-' + accentLine : '';
|
|
1002
|
-
},
|
|
1063
|
+
}, /* @ts-ignore */
|
|
1064
|
+
...(ngDevMode ? [{ debugName: "accentClass" }] : /* istanbul ignore next */ []));
|
|
1003
1065
|
icons = addIcons({ elementRight2 });
|
|
1004
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1005
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "
|
|
1066
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiTimelineWidgetComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1067
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiTimelineWidgetComponent, isStandalone: true, selector: "si-timeline-widget", inputs: { heading: { classPropertyName: "heading", publicName: "heading", isSignal: true, isRequired: false, transformFunction: null }, primaryActions: { classPropertyName: "primaryActions", publicName: "primaryActions", isSignal: true, isRequired: false, transformFunction: null }, secondaryActions: { classPropertyName: "secondaryActions", publicName: "secondaryActions", isSignal: true, isRequired: false, transformFunction: null }, link: { classPropertyName: "link", publicName: "link", isSignal: true, isRequired: false, transformFunction: null }, numberOfItems: { classPropertyName: "numberOfItems", publicName: "numberOfItems", isSignal: true, isRequired: false, transformFunction: null }, showDescription: { classPropertyName: "showDescription", publicName: "showDescription", isSignal: true, isRequired: false, transformFunction: null }, accentLine: { classPropertyName: "accentLine", publicName: "accentLine", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: "<si-card\n class=\"h-100\"\n [class]=\"accentClass()\"\n [heading]=\"heading()\"\n [primaryActions]=\"primaryActions()\"\n [secondaryActions]=\"secondaryActions()\"\n>\n <si-timeline-widget-body\n body\n [value]=\"value()\"\n [showDescription]=\"showDescription()\"\n [numberOfItems]=\"numberOfItems()\"\n [class.pb-6]=\"!link()\"\n [showLoadingIndicator]=\"showLoadingIndicator()\"\n >\n <ng-content select=\"[empty-state]\" empty-state />\n </si-timeline-widget-body>\n @let linkValue = link();\n @if (linkValue) {\n <div class=\"card-footer\" footer>\n @if (!linkValue.action) {\n <a [siLink]=\"linkValue\">\n {{ linkValue.title | translate }}\n <si-icon class=\"link-icon link-end flip-rtl\" [icon]=\"icons.elementRight2\" />\n </a>\n } @else {\n <button type=\"button\" class=\"btn btn-link\" [siLink]=\"linkValue\">{{\n linkValue.title | translate\n }}</button>\n }\n </div>\n }\n</si-card>\n", dependencies: [{ kind: "directive", type: SiLinkDirective, selector: "[siLink]", inputs: ["siLink", "siLinkDefaultTarget", "actionParam", "activeClass", "exactMatch", "ariaCurrent"], outputs: ["activeChange"], exportAs: ["siLink"] }, { kind: "component", type: SiCardComponent, selector: "si-card", inputs: ["primaryActions", "secondaryActions", "actionParam", "actionBarViewType", "actionBarTitle"] }, { kind: "component", type: SiTimelineWidgetBodyComponent, selector: "si-timeline-widget-body", inputs: ["numberOfItems", "showDescription"] }, { kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
1006
1068
|
}
|
|
1007
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1069
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiTimelineWidgetComponent, decorators: [{
|
|
1008
1070
|
type: Component,
|
|
1009
1071
|
args: [{ selector: 'si-timeline-widget', imports: [
|
|
1010
1072
|
SiLinkDirective,
|
|
@@ -1012,7 +1074,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
1012
1074
|
SiTimelineWidgetBodyComponent,
|
|
1013
1075
|
SiTranslatePipe,
|
|
1014
1076
|
SiIconComponent
|
|
1015
|
-
], changeDetection: ChangeDetectionStrategy.
|
|
1077
|
+
], changeDetection: ChangeDetectionStrategy.Eager, template: "<si-card\n class=\"h-100\"\n [class]=\"accentClass()\"\n [heading]=\"heading()\"\n [primaryActions]=\"primaryActions()\"\n [secondaryActions]=\"secondaryActions()\"\n>\n <si-timeline-widget-body\n body\n [value]=\"value()\"\n [showDescription]=\"showDescription()\"\n [numberOfItems]=\"numberOfItems()\"\n [class.pb-6]=\"!link()\"\n [showLoadingIndicator]=\"showLoadingIndicator()\"\n >\n <ng-content select=\"[empty-state]\" empty-state />\n </si-timeline-widget-body>\n @let linkValue = link();\n @if (linkValue) {\n <div class=\"card-footer\" footer>\n @if (!linkValue.action) {\n <a [siLink]=\"linkValue\">\n {{ linkValue.title | translate }}\n <si-icon class=\"link-icon link-end flip-rtl\" [icon]=\"icons.elementRight2\" />\n </a>\n } @else {\n <button type=\"button\" class=\"btn btn-link\" [siLink]=\"linkValue\">{{\n linkValue.title | translate\n }}</button>\n }\n </div>\n }\n</si-card>\n" }]
|
|
1016
1078
|
}], propDecorators: { heading: [{ type: i0.Input, args: [{ isSignal: true, alias: "heading", required: false }] }], primaryActions: [{ type: i0.Input, args: [{ isSignal: true, alias: "primaryActions", required: false }] }], secondaryActions: [{ type: i0.Input, args: [{ isSignal: true, alias: "secondaryActions", required: false }] }], link: [{ type: i0.Input, args: [{ isSignal: true, alias: "link", required: false }] }], numberOfItems: [{ type: i0.Input, args: [{ isSignal: true, alias: "numberOfItems", required: false }] }], showDescription: [{ type: i0.Input, args: [{ isSignal: true, alias: "showDescription", required: false }] }], accentLine: [{ type: i0.Input, args: [{ isSignal: true, alias: "accentLine", required: false }] }] } });
|
|
1017
1079
|
|
|
1018
1080
|
/**
|
|
@@ -1026,26 +1088,30 @@ class SiValueWidgetBodyComponent extends SiWidgetBaseDirective {
|
|
|
1026
1088
|
/**
|
|
1027
1089
|
* The unit of the value (e.g. kWh or users). Only visible if `value` is available.
|
|
1028
1090
|
*/
|
|
1029
|
-
unit = input(
|
|
1091
|
+
unit = input(/* @ts-ignore */
|
|
1092
|
+
...(ngDevMode ? [undefined, { debugName: "unit" }] : /* istanbul ignore next */ []));
|
|
1030
1093
|
/**
|
|
1031
1094
|
* The element icon name. Only visible if `value` is available.
|
|
1032
1095
|
*/
|
|
1033
|
-
icon = input(
|
|
1096
|
+
icon = input(/* @ts-ignore */
|
|
1097
|
+
...(ngDevMode ? [undefined, { debugName: "icon" }] : /* istanbul ignore next */ []));
|
|
1034
1098
|
/**
|
|
1035
1099
|
* Show a status icon instead of the {@link icon}.
|
|
1036
1100
|
*/
|
|
1037
|
-
status = input(
|
|
1101
|
+
status = input(/* @ts-ignore */
|
|
1102
|
+
...(ngDevMode ? [undefined, { debugName: "status" }] : /* istanbul ignore next */ []));
|
|
1038
1103
|
/**
|
|
1039
1104
|
* Short description of the value. A description is mandatory
|
|
1040
1105
|
* to show an icon. Only visible if `value` is available.
|
|
1041
1106
|
*/
|
|
1042
|
-
description = input(
|
|
1043
|
-
|
|
1044
|
-
static
|
|
1107
|
+
description = input(/* @ts-ignore */
|
|
1108
|
+
...(ngDevMode ? [undefined, { debugName: "description" }] : /* istanbul ignore next */ []));
|
|
1109
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiValueWidgetBodyComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1110
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiValueWidgetBodyComponent, isStandalone: true, selector: "si-value-widget-body", inputs: { unit: { classPropertyName: "unit", publicName: "unit", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: "@if (!showLoadingIndicator()) {\n @if (value()) {\n <span class=\"si-value-widget-value\">{{ value() | translate }}</span>\n <span class=\"si-value-widget-unit\">{{ unit() | translate }}</span>\n @if (description()) {\n <div class=\"si-value-widget-description\">\n @let statusValue = status();\n @let iconValue = icon();\n @if (statusValue) {\n <si-status-icon class=\"icon\" [status]=\"statusValue\" />\n } @else if (iconValue) {\n <si-icon class=\"icon\" [icon]=\"iconValue\" />\n }\n <span>{{ description() | translate }}</span>\n </div>\n }\n }\n} @else {\n <span class=\"si-value-widget-value w-100\">\n <div class=\"si-value-widget-value-skeleton\"></div>\n </span>\n <div class=\"si-value-widget-description si-skeleton w-100\"></div>\n}\n", dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "component", type: SiStatusIconComponent, selector: "si-status-icon", inputs: ["status"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
1045
1111
|
}
|
|
1046
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1112
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiValueWidgetBodyComponent, decorators: [{
|
|
1047
1113
|
type: Component,
|
|
1048
|
-
args: [{ selector: 'si-value-widget-body', imports: [SiIconComponent, SiStatusIconComponent, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.
|
|
1114
|
+
args: [{ selector: 'si-value-widget-body', imports: [SiIconComponent, SiStatusIconComponent, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.Eager, template: "@if (!showLoadingIndicator()) {\n @if (value()) {\n <span class=\"si-value-widget-value\">{{ value() | translate }}</span>\n <span class=\"si-value-widget-unit\">{{ unit() | translate }}</span>\n @if (description()) {\n <div class=\"si-value-widget-description\">\n @let statusValue = status();\n @let iconValue = icon();\n @if (statusValue) {\n <si-status-icon class=\"icon\" [status]=\"statusValue\" />\n } @else if (iconValue) {\n <si-icon class=\"icon\" [icon]=\"iconValue\" />\n }\n <span>{{ description() | translate }}</span>\n </div>\n }\n }\n} @else {\n <span class=\"si-value-widget-value w-100\">\n <div class=\"si-value-widget-value-skeleton\"></div>\n </span>\n <div class=\"si-value-widget-description si-skeleton w-100\"></div>\n}\n" }]
|
|
1049
1115
|
}], propDecorators: { unit: [{ type: i0.Input, args: [{ isSignal: true, alias: "unit", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], status: [{ type: i0.Input, args: [{ isSignal: true, alias: "status", required: false }] }], description: [{ type: i0.Input, args: [{ isSignal: true, alias: "description", required: false }] }] } });
|
|
1050
1116
|
|
|
1051
1117
|
/**
|
|
@@ -1068,105 +1134,122 @@ class SiValueWidgetComponent {
|
|
|
1068
1134
|
/**
|
|
1069
1135
|
* Value widget header text.
|
|
1070
1136
|
*/
|
|
1071
|
-
heading = input(
|
|
1137
|
+
heading = input(/* @ts-ignore */
|
|
1138
|
+
...(ngDevMode ? [undefined, { debugName: "heading" }] : /* istanbul ignore next */ []));
|
|
1072
1139
|
/**
|
|
1073
1140
|
* Input list of primary action items. Supports up to **4** actions and omits additional ones.
|
|
1074
1141
|
*
|
|
1075
1142
|
* @defaultValue []
|
|
1076
1143
|
*/
|
|
1077
|
-
primaryActions = input([],
|
|
1144
|
+
primaryActions = input([], /* @ts-ignore */
|
|
1145
|
+
...(ngDevMode ? [{ debugName: "primaryActions" }] : /* istanbul ignore next */ []));
|
|
1078
1146
|
/**
|
|
1079
1147
|
* Input list of secondary action items.
|
|
1080
1148
|
*
|
|
1081
1149
|
* @defaultValue []
|
|
1082
1150
|
*/
|
|
1083
|
-
secondaryActions = input([],
|
|
1151
|
+
secondaryActions = input([], /* @ts-ignore */
|
|
1152
|
+
...(ngDevMode ? [{ debugName: "secondaryActions" }] : /* istanbul ignore next */ []));
|
|
1084
1153
|
/**
|
|
1085
1154
|
* The main value to be displayed. If no value is set,
|
|
1086
1155
|
* the skeleton indicates the loading of the value. Disable
|
|
1087
1156
|
* the automatic loading mechanism by setting `SiValueWidgetComponent.disableAutoLoadingIndicator`.
|
|
1088
1157
|
*/
|
|
1089
|
-
value = input(
|
|
1158
|
+
value = input(/* @ts-ignore */
|
|
1159
|
+
...(ngDevMode ? [undefined, { debugName: "value" }] : /* istanbul ignore next */ []));
|
|
1090
1160
|
/**
|
|
1091
1161
|
* The unit of the value (e.g. kWh or users). Only visible if `value` is available.
|
|
1092
1162
|
*/
|
|
1093
|
-
unit = input(
|
|
1163
|
+
unit = input(/* @ts-ignore */
|
|
1164
|
+
...(ngDevMode ? [undefined, { debugName: "unit" }] : /* istanbul ignore next */ []));
|
|
1094
1165
|
/**
|
|
1095
1166
|
* The element icon name. Only visible if `value` is available.
|
|
1096
1167
|
*/
|
|
1097
|
-
icon = input(
|
|
1168
|
+
icon = input(/* @ts-ignore */
|
|
1169
|
+
...(ngDevMode ? [undefined, { debugName: "icon" }] : /* istanbul ignore next */ []));
|
|
1098
1170
|
/**
|
|
1099
1171
|
* Show a status icon instead of the {@link icon}.
|
|
1100
1172
|
*/
|
|
1101
|
-
status = input(
|
|
1173
|
+
status = input(/* @ts-ignore */
|
|
1174
|
+
...(ngDevMode ? [undefined, { debugName: "status" }] : /* istanbul ignore next */ []));
|
|
1102
1175
|
/**
|
|
1103
1176
|
* Short description of the value. A description is mandatory
|
|
1104
1177
|
* to show an icon. Only visible if `value` is available.
|
|
1105
1178
|
*/
|
|
1106
|
-
description = input(
|
|
1179
|
+
description = input(/* @ts-ignore */
|
|
1180
|
+
...(ngDevMode ? [undefined, { debugName: "description" }] : /* istanbul ignore next */ []));
|
|
1107
1181
|
/**
|
|
1108
1182
|
* Link that leads the user to more information
|
|
1109
1183
|
* or triggers and action. The `link.title` is displayed.
|
|
1110
1184
|
* The title will be translated.
|
|
1111
1185
|
*/
|
|
1112
|
-
link = input(
|
|
1186
|
+
link = input(/* @ts-ignore */
|
|
1187
|
+
...(ngDevMode ? [undefined, { debugName: "link" }] : /* istanbul ignore next */ []));
|
|
1113
1188
|
/**
|
|
1114
1189
|
* Option to disable automatic start of skeleton loading indication.
|
|
1115
1190
|
*
|
|
1116
1191
|
* @defaultValue false
|
|
1117
1192
|
*/
|
|
1118
|
-
disableAutoLoadingIndicator = input(false, { ...(ngDevMode ? { debugName: "disableAutoLoadingIndicator" } : {}), transform: booleanAttribute });
|
|
1193
|
+
disableAutoLoadingIndicator = input(false, { ...(ngDevMode ? { debugName: "disableAutoLoadingIndicator" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
1119
1194
|
/**
|
|
1120
1195
|
* Input to start and stop the skeleton loading indication.
|
|
1121
1196
|
*
|
|
1122
1197
|
* @defaultValue false
|
|
1123
1198
|
*/
|
|
1124
|
-
showLoadingIndicator = input(false, { ...(ngDevMode ? { debugName: "showLoadingIndicator" } : {}), transform: booleanAttribute });
|
|
1199
|
+
showLoadingIndicator = input(false, { ...(ngDevMode ? { debugName: "showLoadingIndicator" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
1125
1200
|
/**
|
|
1126
1201
|
* Initial delay time in milliseconds before enabling loading indicator.
|
|
1127
1202
|
* Only used once initially during construction.
|
|
1128
1203
|
*
|
|
1129
1204
|
* @defaultValue 300
|
|
1130
1205
|
*/
|
|
1131
|
-
initialLoadingIndicatorDebounceTime = input(300,
|
|
1206
|
+
initialLoadingIndicatorDebounceTime = input(300, /* @ts-ignore */
|
|
1207
|
+
...(ngDevMode ? [{ debugName: "initialLoadingIndicatorDebounceTime" }] : /* istanbul ignore next */ []));
|
|
1132
1208
|
/**
|
|
1133
1209
|
* Image source for the card.
|
|
1134
1210
|
*/
|
|
1135
|
-
imgSrc = input(
|
|
1211
|
+
imgSrc = input(/* @ts-ignore */
|
|
1212
|
+
...(ngDevMode ? [undefined, { debugName: "imgSrc" }] : /* istanbul ignore next */ []));
|
|
1136
1213
|
/**
|
|
1137
1214
|
* Alt text for a provided image.
|
|
1138
1215
|
*/
|
|
1139
|
-
imgAlt = input(
|
|
1216
|
+
imgAlt = input(/* @ts-ignore */
|
|
1217
|
+
...(ngDevMode ? [undefined, { debugName: "imgAlt" }] : /* istanbul ignore next */ []));
|
|
1140
1218
|
/**
|
|
1141
1219
|
* Defines if an image is placed on top or start (left) of the card.
|
|
1142
1220
|
*
|
|
1143
1221
|
* @defaultValue 'vertical'
|
|
1144
1222
|
*/
|
|
1145
|
-
imgDir = input('vertical',
|
|
1223
|
+
imgDir = input('vertical', /* @ts-ignore */
|
|
1224
|
+
...(ngDevMode ? [{ debugName: "imgDir" }] : /* istanbul ignore next */ []));
|
|
1146
1225
|
/**
|
|
1147
1226
|
* Sets the image [object-fit](https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit) CSS property.
|
|
1148
1227
|
*
|
|
1149
1228
|
* @defaultValue 'scale-down'
|
|
1150
1229
|
*/
|
|
1151
|
-
imgObjectFit = input('scale-down',
|
|
1230
|
+
imgObjectFit = input('scale-down', /* @ts-ignore */
|
|
1231
|
+
...(ngDevMode ? [{ debugName: "imgObjectFit" }] : /* istanbul ignore next */ []));
|
|
1152
1232
|
/**
|
|
1153
1233
|
* Sets the image [object-position](https://developer.mozilla.org/en-US/docs/Web/CSS/object-position) CSS property.
|
|
1154
1234
|
*/
|
|
1155
|
-
imgObjectPosition = input(
|
|
1235
|
+
imgObjectPosition = input(/* @ts-ignore */
|
|
1236
|
+
...(ngDevMode ? [undefined, { debugName: "imgObjectPosition" }] : /* istanbul ignore next */ []));
|
|
1156
1237
|
/**
|
|
1157
1238
|
* Optional accent line
|
|
1158
1239
|
*/
|
|
1159
|
-
accentLine = input(
|
|
1240
|
+
accentLine = input(/* @ts-ignore */
|
|
1241
|
+
...(ngDevMode ? [undefined, { debugName: "accentLine" }] : /* istanbul ignore next */ []));
|
|
1160
1242
|
accentClass = computed(() => {
|
|
1161
1243
|
const accentLine = this.accentLine();
|
|
1162
1244
|
return accentLine ? 'accent-' + accentLine : '';
|
|
1163
|
-
},
|
|
1164
|
-
|
|
1165
|
-
static
|
|
1245
|
+
}, /* @ts-ignore */
|
|
1246
|
+
...(ngDevMode ? [{ debugName: "accentClass" }] : /* istanbul ignore next */ []));
|
|
1247
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiValueWidgetComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1248
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiValueWidgetComponent, isStandalone: true, selector: "si-value-widget", inputs: { heading: { classPropertyName: "heading", publicName: "heading", isSignal: true, isRequired: false, transformFunction: null }, primaryActions: { classPropertyName: "primaryActions", publicName: "primaryActions", isSignal: true, isRequired: false, transformFunction: null }, secondaryActions: { classPropertyName: "secondaryActions", publicName: "secondaryActions", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, unit: { classPropertyName: "unit", publicName: "unit", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null }, link: { classPropertyName: "link", publicName: "link", isSignal: true, isRequired: false, transformFunction: null }, disableAutoLoadingIndicator: { classPropertyName: "disableAutoLoadingIndicator", publicName: "disableAutoLoadingIndicator", isSignal: true, isRequired: false, transformFunction: null }, showLoadingIndicator: { classPropertyName: "showLoadingIndicator", publicName: "showLoadingIndicator", isSignal: true, isRequired: false, transformFunction: null }, initialLoadingIndicatorDebounceTime: { classPropertyName: "initialLoadingIndicatorDebounceTime", publicName: "initialLoadingIndicatorDebounceTime", isSignal: true, isRequired: false, transformFunction: null }, imgSrc: { classPropertyName: "imgSrc", publicName: "imgSrc", isSignal: true, isRequired: false, transformFunction: null }, imgAlt: { classPropertyName: "imgAlt", publicName: "imgAlt", isSignal: true, isRequired: false, transformFunction: null }, imgDir: { classPropertyName: "imgDir", publicName: "imgDir", isSignal: true, isRequired: false, transformFunction: null }, imgObjectFit: { classPropertyName: "imgObjectFit", publicName: "imgObjectFit", isSignal: true, isRequired: false, transformFunction: null }, imgObjectPosition: { classPropertyName: "imgObjectPosition", publicName: "imgObjectPosition", isSignal: true, isRequired: false, transformFunction: null }, accentLine: { classPropertyName: "accentLine", publicName: "accentLine", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<si-card\n class=\"h-100\"\n [class]=\"accentClass()\"\n [heading]=\"heading()\"\n [primaryActions]=\"primaryActions()\"\n [secondaryActions]=\"secondaryActions()\"\n [imgSrc]=\"imgSrc()\"\n [imgDir]=\"imgDir()\"\n [imgAlt]=\"imgAlt()\"\n [imgObjectFit]=\"imgObjectFit()\"\n [imgObjectPosition]=\"imgObjectPosition()\"\n>\n <div class=\"card-body\" body>\n <si-value-widget-body\n [value]=\"value()\"\n [unit]=\"unit()\"\n [icon]=\"icon()\"\n [status]=\"status()\"\n [description]=\"description()\"\n [disableAutoLoadingIndicator]=\"disableAutoLoadingIndicator()\"\n [showLoadingIndicator]=\"showLoadingIndicator()\"\n [initialLoadingIndicatorDebounceTime]=\"initialLoadingIndicatorDebounceTime()\"\n />\n </div>\n @let linkObject = link();\n @if (linkObject) {\n <div class=\"card-footer\" footer>\n <a [siLink]=\"linkObject\">{{ linkObject.title | translate }}</a>\n </div>\n }\n</si-card>\n", dependencies: [{ kind: "component", type: SiCardComponent, selector: "si-card", inputs: ["primaryActions", "secondaryActions", "actionParam", "actionBarViewType", "actionBarTitle"] }, { kind: "directive", type: SiLinkDirective, selector: "[siLink]", inputs: ["siLink", "siLinkDefaultTarget", "actionParam", "activeClass", "exactMatch", "ariaCurrent"], outputs: ["activeChange"], exportAs: ["siLink"] }, { kind: "component", type: SiValueWidgetBodyComponent, selector: "si-value-widget-body", inputs: ["unit", "icon", "status", "description"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
1166
1249
|
}
|
|
1167
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1250
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiValueWidgetComponent, decorators: [{
|
|
1168
1251
|
type: Component,
|
|
1169
|
-
args: [{ selector: 'si-value-widget', imports: [SiCardComponent, SiLinkDirective, SiTranslatePipe, SiValueWidgetBodyComponent], changeDetection: ChangeDetectionStrategy.
|
|
1252
|
+
args: [{ selector: 'si-value-widget', imports: [SiCardComponent, SiLinkDirective, SiTranslatePipe, SiValueWidgetBodyComponent], changeDetection: ChangeDetectionStrategy.Eager, template: "<si-card\n class=\"h-100\"\n [class]=\"accentClass()\"\n [heading]=\"heading()\"\n [primaryActions]=\"primaryActions()\"\n [secondaryActions]=\"secondaryActions()\"\n [imgSrc]=\"imgSrc()\"\n [imgDir]=\"imgDir()\"\n [imgAlt]=\"imgAlt()\"\n [imgObjectFit]=\"imgObjectFit()\"\n [imgObjectPosition]=\"imgObjectPosition()\"\n>\n <div class=\"card-body\" body>\n <si-value-widget-body\n [value]=\"value()\"\n [unit]=\"unit()\"\n [icon]=\"icon()\"\n [status]=\"status()\"\n [description]=\"description()\"\n [disableAutoLoadingIndicator]=\"disableAutoLoadingIndicator()\"\n [showLoadingIndicator]=\"showLoadingIndicator()\"\n [initialLoadingIndicatorDebounceTime]=\"initialLoadingIndicatorDebounceTime()\"\n />\n </div>\n @let linkObject = link();\n @if (linkObject) {\n <div class=\"card-footer\" footer>\n <a [siLink]=\"linkObject\">{{ linkObject.title | translate }}</a>\n </div>\n }\n</si-card>\n" }]
|
|
1170
1253
|
}], propDecorators: { heading: [{ type: i0.Input, args: [{ isSignal: true, alias: "heading", required: false }] }], primaryActions: [{ type: i0.Input, args: [{ isSignal: true, alias: "primaryActions", required: false }] }], secondaryActions: [{ type: i0.Input, args: [{ isSignal: true, alias: "secondaryActions", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }], unit: [{ type: i0.Input, args: [{ isSignal: true, alias: "unit", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], status: [{ type: i0.Input, args: [{ isSignal: true, alias: "status", required: false }] }], description: [{ type: i0.Input, args: [{ isSignal: true, alias: "description", required: false }] }], link: [{ type: i0.Input, args: [{ isSignal: true, alias: "link", required: false }] }], disableAutoLoadingIndicator: [{ type: i0.Input, args: [{ isSignal: true, alias: "disableAutoLoadingIndicator", required: false }] }], showLoadingIndicator: [{ type: i0.Input, args: [{ isSignal: true, alias: "showLoadingIndicator", required: false }] }], initialLoadingIndicatorDebounceTime: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialLoadingIndicatorDebounceTime", required: false }] }], imgSrc: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgSrc", required: false }] }], imgAlt: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgAlt", required: false }] }], imgDir: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgDir", required: false }] }], imgObjectFit: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgObjectFit", required: false }] }], imgObjectPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgObjectPosition", required: false }] }], accentLine: [{ type: i0.Input, args: [{ isSignal: true, alias: "accentLine", required: false }] }] } });
|
|
1171
1254
|
|
|
1172
1255
|
/**
|
|
@@ -1195,10 +1278,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
1195
1278
|
* widget can skip the illustration.
|
|
1196
1279
|
*/
|
|
1197
1280
|
class SiWeatherIconResolver {
|
|
1198
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1199
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
1281
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherIconResolver, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1282
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherIconResolver, providedIn: 'root', useFactory: () => inject(SiDefaultWeatherIconResolver) });
|
|
1200
1283
|
}
|
|
1201
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1284
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherIconResolver, decorators: [{
|
|
1202
1285
|
type: Injectable,
|
|
1203
1286
|
args: [{
|
|
1204
1287
|
providedIn: 'root',
|
|
@@ -1238,10 +1321,10 @@ class SiDefaultWeatherIconResolver extends SiWeatherIconResolver {
|
|
|
1238
1321
|
}
|
|
1239
1322
|
return { icon: mapped, alt: icon.alt };
|
|
1240
1323
|
}
|
|
1241
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1242
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
1324
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDefaultWeatherIconResolver, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
|
|
1325
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDefaultWeatherIconResolver, providedIn: 'root' });
|
|
1243
1326
|
}
|
|
1244
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1327
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiDefaultWeatherIconResolver, decorators: [{
|
|
1245
1328
|
type: Injectable,
|
|
1246
1329
|
args: [{ providedIn: 'root' }]
|
|
1247
1330
|
}] });
|
|
@@ -1259,11 +1342,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
1259
1342
|
* @internal
|
|
1260
1343
|
*/
|
|
1261
1344
|
class SiWeatherWidgetIllustrationComponent {
|
|
1262
|
-
illustration = input(
|
|
1263
|
-
|
|
1264
|
-
|
|
1345
|
+
illustration = input(/* @ts-ignore */
|
|
1346
|
+
...(ngDevMode ? [undefined, { debugName: "illustration" }] : /* istanbul ignore next */ []));
|
|
1347
|
+
condition = input(/* @ts-ignore */
|
|
1348
|
+
...(ngDevMode ? [undefined, { debugName: "condition" }] : /* istanbul ignore next */ []));
|
|
1349
|
+
altFallback = input(/* @ts-ignore */
|
|
1350
|
+
...(ngDevMode ? [undefined, { debugName: "altFallback" }] : /* istanbul ignore next */ []));
|
|
1265
1351
|
/** @defaultValue 'lg' */
|
|
1266
|
-
size = input('lg',
|
|
1352
|
+
size = input('lg', /* @ts-ignore */
|
|
1353
|
+
...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
1267
1354
|
resolver = inject(SiWeatherIconResolver);
|
|
1268
1355
|
defaultAlt = t(() => $localize `:@@SI_WEATHER_WIDGET.ILLUSTRATION_ALT:Weather illustration`);
|
|
1269
1356
|
resolved = computed(() => {
|
|
@@ -1287,9 +1374,10 @@ class SiWeatherWidgetIllustrationComponent {
|
|
|
1287
1374
|
src: resolution.icon ? undefined : resolution.src,
|
|
1288
1375
|
alt: resolution.alt ?? icon.alt ?? this.condition() ?? this.altFallback() ?? this.defaultAlt
|
|
1289
1376
|
};
|
|
1290
|
-
},
|
|
1291
|
-
|
|
1292
|
-
static
|
|
1377
|
+
}, /* @ts-ignore */
|
|
1378
|
+
...(ngDevMode ? [{ debugName: "resolved" }] : /* istanbul ignore next */ []));
|
|
1379
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherWidgetIllustrationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1380
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiWeatherWidgetIllustrationComponent, isStandalone: true, selector: "si-weather-widget-illustration", inputs: { illustration: { classPropertyName: "illustration", publicName: "illustration", isSignal: true, isRequired: false, transformFunction: null }, condition: { classPropertyName: "condition", publicName: "condition", isSignal: true, isRequired: false, transformFunction: null }, altFallback: { classPropertyName: "altFallback", publicName: "altFallback", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.si-weather-widget-illustration-sm": "size() === 'sm'", "class.si-weather-widget-illustration-md": "size() === 'md'", "class.si-weather-widget-illustration-lg": "size() === 'lg'" } }, ngImport: i0, template: `
|
|
1293
1381
|
@let res = resolved();
|
|
1294
1382
|
@if (res) {
|
|
1295
1383
|
@if (res.icon) {
|
|
@@ -1303,9 +1391,9 @@ class SiWeatherWidgetIllustrationComponent {
|
|
|
1303
1391
|
<img class="si-weather-widget-illustration" [src]="res.src" [alt]="res.alt | translate" />
|
|
1304
1392
|
}
|
|
1305
1393
|
}
|
|
1306
|
-
`, isInline: true, styles: [":host{display:contents}:host img{flex:0 0 auto;object-fit:contain}:host(.si-weather-widget-illustration-sm) img,:host(.si-weather-widget-illustration-sm) si-icon{inline-size:1.25rem;block-size:1.25rem}:host(.si-weather-widget-illustration-sm) si-icon{font-size:1.25rem;line-height:1;inline-size:auto;block-size:auto}:host(.si-weather-widget-illustration-md) img,:host(.si-weather-widget-illustration-md) si-icon{inline-size:1.5rem;block-size:1.5rem}:host(.si-weather-widget-illustration-md) si-icon{font-size:1.5rem;line-height:1;inline-size:auto;block-size:auto}:host(.si-weather-widget-illustration-lg) img,:host(.si-weather-widget-illustration-lg) si-icon{inline-size:2.5rem;block-size:2.5rem}:host(.si-weather-widget-illustration-lg) si-icon{font-size:2.5rem;line-height:1;inline-size:auto;block-size:auto}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }]
|
|
1394
|
+
`, isInline: true, styles: [":host{display:contents}:host img{flex:0 0 auto;object-fit:contain}:host(.si-weather-widget-illustration-sm) img,:host(.si-weather-widget-illustration-sm) si-icon{inline-size:1.25rem;block-size:1.25rem}:host(.si-weather-widget-illustration-sm) si-icon{font-size:1.25rem;line-height:1;inline-size:auto;block-size:auto}:host(.si-weather-widget-illustration-md) img,:host(.si-weather-widget-illustration-md) si-icon{inline-size:1.5rem;block-size:1.5rem}:host(.si-weather-widget-illustration-md) si-icon{font-size:1.5rem;line-height:1;inline-size:auto;block-size:auto}:host(.si-weather-widget-illustration-lg) img,:host(.si-weather-widget-illustration-lg) si-icon{inline-size:2.5rem;block-size:2.5rem}:host(.si-weather-widget-illustration-lg) si-icon{font-size:2.5rem;line-height:1;inline-size:auto;block-size:auto}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }] });
|
|
1307
1395
|
}
|
|
1308
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1396
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherWidgetIllustrationComponent, decorators: [{
|
|
1309
1397
|
type: Component,
|
|
1310
1398
|
args: [{ selector: 'si-weather-widget-illustration', imports: [SiIconComponent, SiTranslatePipe], template: `
|
|
1311
1399
|
@let res = resolved();
|
|
@@ -1321,7 +1409,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
1321
1409
|
<img class="si-weather-widget-illustration" [src]="res.src" [alt]="res.alt | translate" />
|
|
1322
1410
|
}
|
|
1323
1411
|
}
|
|
1324
|
-
`,
|
|
1412
|
+
`, host: {
|
|
1325
1413
|
'[class.si-weather-widget-illustration-sm]': "size() === 'sm'",
|
|
1326
1414
|
'[class.si-weather-widget-illustration-md]': "size() === 'md'",
|
|
1327
1415
|
'[class.si-weather-widget-illustration-lg]': "size() === 'lg'"
|
|
@@ -1340,10 +1428,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
1340
1428
|
* @internal
|
|
1341
1429
|
*/
|
|
1342
1430
|
class SiWeatherWidgetForecastComponent {
|
|
1343
|
-
forecast = input.required(
|
|
1431
|
+
forecast = input.required(/* @ts-ignore */
|
|
1432
|
+
...(ngDevMode ? [{ debugName: "forecast" }] : /* istanbul ignore next */ []));
|
|
1344
1433
|
/** @defaultValue 'vertical' */
|
|
1345
|
-
layout = input('vertical',
|
|
1346
|
-
|
|
1434
|
+
layout = input('vertical', /* @ts-ignore */
|
|
1435
|
+
...(ngDevMode ? [{ debugName: "layout" }] : /* istanbul ignore next */ []));
|
|
1436
|
+
forecastLabel = input(/* @ts-ignore */
|
|
1437
|
+
...(ngDevMode ? [undefined, { debugName: "forecastLabel" }] : /* istanbul ignore next */ []));
|
|
1347
1438
|
columns = computed(() => {
|
|
1348
1439
|
const cols = this.forecast().columns;
|
|
1349
1440
|
if (!cols) {
|
|
@@ -1353,16 +1444,17 @@ class SiWeatherWidgetForecastComponent {
|
|
|
1353
1444
|
// the stylesheet. Authors should pass at most 5 columns and pick the most
|
|
1354
1445
|
// important ones — the row will become unreadable beyond that.
|
|
1355
1446
|
return cols.slice(0, 5);
|
|
1356
|
-
},
|
|
1447
|
+
}, /* @ts-ignore */
|
|
1448
|
+
...(ngDevMode ? [{ debugName: "columns" }] : /* istanbul ignore next */ []));
|
|
1357
1449
|
columnValue(column, index) {
|
|
1358
1450
|
return column.values?.[index];
|
|
1359
1451
|
}
|
|
1360
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1361
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiWeatherWidgetForecastComponent, isStandalone: true, selector: "si-weather-widget-forecast", inputs: { forecast: { classPropertyName: "forecast", publicName: "forecast", isSignal: true, isRequired: true, transformFunction: null }, layout: { classPropertyName: "layout", publicName: "layout", isSignal: true, isRequired: false, transformFunction: null }, forecastLabel: { classPropertyName: "forecastLabel", publicName: "forecastLabel", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@let days = forecast().days;\n@let cols = columns();\n@let illustrationSize = layout() === 'vertical' ? 'sm' : 'md';\n\n<div\n class=\"si-weather-widget-forecast\"\n [class.si-weather-widget-vertical]=\"layout() === 'vertical'\"\n [class.si-weather-widget-horizontal]=\"layout() === 'horizontal'\"\n [attr.aria-label]=\"forecastLabel() | translate\"\n>\n @if (layout() === 'horizontal') {\n @for (day of days; track $index) {\n <div\n class=\"si-weather-widget-forecast-day\"\n [class.si-weather-widget-forecast-day-2]=\"$index === 1\"\n [class.si-weather-widget-forecast-day-3]=\"$index === 2\"\n [class.si-weather-widget-forecast-day-4]=\"$index === 3\"\n [class.si-weather-widget-forecast-day-5]=\"$index === 4\"\n >\n <div class=\"si-weather-widget-forecast-day-label\">{{ day.label | translate }}</div>\n <si-weather-widget-illustration\n [size]=\"illustrationSize\"\n [illustration]=\"day.illustration\"\n [altFallback]=\"day.label\"\n />\n <div class=\"si-weather-widget-forecast-day-range\">\n <span class=\"si-weather-widget-forecast-range-min\">{{ day.minTemperature }}</span>\n <span class=\"si-weather-widget-forecast-range-max\">{{ day.maxTemperature }}</span>\n </div>\n </div>\n }\n } @else {\n <ul\n class=\"si-weather-widget-forecast-list\"\n role=\"list\"\n [style.--si-weather-forecast-extras]=\"cols.length\"\n >\n @for (day of days; track $index; let i = $index) {\n <li class=\"si-weather-widget-forecast-row\">\n <span class=\"si-weather-widget-forecast-day-label\">\n {{ day.label | translate }}\n </span>\n <span class=\"si-weather-widget-forecast-illustration-cell\">\n <si-weather-widget-illustration\n [size]=\"illustrationSize\"\n [illustration]=\"day.illustration\"\n [altFallback]=\"day.label\"\n />\n </span>\n @for (col of cols; track $index; let extraIdx = $index) {\n <span\n class=\"si-weather-widget-forecast-extra\"\n role=\"img\"\n [class.si-weather-widget-forecast-extra-1]=\"extraIdx === 0\"\n [class.si-weather-widget-forecast-extra-2]=\"extraIdx === 1\"\n [class.si-weather-widget-forecast-extra-3]=\"extraIdx === 2\"\n [class.si-weather-widget-forecast-extra-4]=\"extraIdx === 3\"\n [class.si-weather-widget-forecast-extra-5]=\"extraIdx === 4\"\n [attr.aria-label]=\"(col.label | translate) + ': ' + (columnValue(col, i) ?? '')\"\n >\n @if (col.icon) {\n <si-icon\n class=\"icon si-weather-widget-forecast-extra-icon\"\n aria-hidden=\"true\"\n [icon]=\"col.icon\"\n />\n }\n <span aria-hidden=\"true\">{{ columnValue(col, i) ?? '' }}</span>\n </span>\n }\n <span class=\"si-weather-widget-forecast-range-cell\">\n <span class=\"si-weather-widget-forecast-range\">\n <span class=\"si-weather-widget-forecast-range-min\">{{ day.minTemperature }}</span>\n <span class=\"si-weather-widget-forecast-range-max\">{{ day.maxTemperature }}</span>\n </span>\n </span>\n </li>\n }\n </ul>\n }\n</div>\n", styles: [".si-weather-widget-forecast-range,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-range{font-size:1rem;font-weight:400;line-height:1.25}.si-weather-widget-forecast-day-range{display:flex;gap:4px}.si-weather-widget-forecast-range-min{color:var(--element-text-secondary)}.si-weather-widget-forecast-range-max{color:var(--element-text-primary);font-weight:600}@property --si-weather-forecast-extras{syntax: \"<integer>\"; inherits: true; initial-value: 0;}@property --si-weather-forecast-extras-cap{syntax: \"<integer>\"; inherits: true; initial-value: 5;}.si-weather-widget-forecast-list{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:max-content 1.25rem repeat(min(var(--si-weather-forecast-extras),var(--si-weather-forecast-extras-cap)),1fr auto) 1fr auto;row-gap:8px;align-items:center;inline-size:100%;container-type:inline-size}@container (max-width: 635px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 4}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 539px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 3}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 443px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 2}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-3,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 347px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 1}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-2,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-3,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 251px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 0}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-1,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-2,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-3,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}.si-weather-widget-forecast-row{display:contents}.si-weather-widget-forecast-day-label{color:var(--element-text-secondary);margin-block:8px;white-space:nowrap}.si-weather-widget-forecast.si-weather-widget-vertical .si-weather-widget-forecast-day-label{padding-inline-end:16px;grid-column-start:1}.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-label{text-align:center}.si-weather-widget-forecast-illustration-cell{display:inline-flex;align-items:center;justify-content:center;margin-block:6px;grid-column-start:2}.si-weather-widget-forecast-extra{display:inline-flex;align-items:center;gap:2px;white-space:nowrap}.si-weather-widget-forecast-extra-1{grid-column-start:4}.si-weather-widget-forecast-extra-2{grid-column-start:6}.si-weather-widget-forecast-extra-3{grid-column-start:8}.si-weather-widget-forecast-extra-4{grid-column-start:10}.si-weather-widget-forecast-extra-5{grid-column-start:12}.si-weather-widget-forecast-range-cell{white-space:nowrap;grid-column-end:-1}.si-weather-widget-forecast-range{display:inline-flex;align-items:baseline;justify-content:flex-end;gap:4px;margin-block:6px}:host{display:contents}.si-weather-widget-forecast{display:flex;flex-wrap:wrap;gap:8px}.si-weather-widget-forecast.si-weather-widget-vertical{display:block}.si-weather-widget-forecast.si-weather-widget-horizontal{flex-wrap:nowrap;overflow:hidden;container-type:inline-size}@container (max-width: 351px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}@container (max-width: 279px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-4,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}@container (max-width: 207px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-3,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-4,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}@container (max-width: 135px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-2,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-3,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-4,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}.si-weather-widget-forecast-day{flex:1 1 0;min-inline-size:64px;display:flex;flex-direction:column;align-items:center;gap:2px;text-align:center}.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day{padding-block:2px}.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-label{margin-block:0}.si-weather-widget-forecast-extra-icon{display:inline-flex;vertical-align:middle;margin-inline-end:2px;color:var(--element-text-secondary);margin-block:6px}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "component", type: SiWeatherWidgetIllustrationComponent, selector: "si-weather-widget-illustration", inputs: ["illustration", "condition", "altFallback", "size"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1452
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherWidgetForecastComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1453
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiWeatherWidgetForecastComponent, isStandalone: true, selector: "si-weather-widget-forecast", inputs: { forecast: { classPropertyName: "forecast", publicName: "forecast", isSignal: true, isRequired: true, transformFunction: null }, layout: { classPropertyName: "layout", publicName: "layout", isSignal: true, isRequired: false, transformFunction: null }, forecastLabel: { classPropertyName: "forecastLabel", publicName: "forecastLabel", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@let days = forecast().days;\n@let cols = columns();\n@let illustrationSize = layout() === 'vertical' ? 'sm' : 'md';\n\n<div\n class=\"si-weather-widget-forecast\"\n [class.si-weather-widget-vertical]=\"layout() === 'vertical'\"\n [class.si-weather-widget-horizontal]=\"layout() === 'horizontal'\"\n [attr.aria-label]=\"forecastLabel() | translate\"\n>\n @if (layout() === 'horizontal') {\n @for (day of days; track $index) {\n <div\n class=\"si-weather-widget-forecast-day\"\n [class.si-weather-widget-forecast-day-2]=\"$index === 1\"\n [class.si-weather-widget-forecast-day-3]=\"$index === 2\"\n [class.si-weather-widget-forecast-day-4]=\"$index === 3\"\n [class.si-weather-widget-forecast-day-5]=\"$index === 4\"\n >\n <div class=\"si-weather-widget-forecast-day-label\">{{ day.label | translate }}</div>\n <si-weather-widget-illustration\n [size]=\"illustrationSize\"\n [illustration]=\"day.illustration\"\n [altFallback]=\"day.label\"\n />\n <div class=\"si-weather-widget-forecast-day-range\">\n <span class=\"si-weather-widget-forecast-range-min\">{{ day.minTemperature }}</span>\n <span class=\"si-weather-widget-forecast-range-max\">{{ day.maxTemperature }}</span>\n </div>\n </div>\n }\n } @else {\n <ul\n class=\"si-weather-widget-forecast-list\"\n role=\"list\"\n [style.--si-weather-forecast-extras]=\"cols.length\"\n >\n @for (day of days; track $index; let i = $index) {\n <li class=\"si-weather-widget-forecast-row\">\n <span class=\"si-weather-widget-forecast-day-label\">\n {{ day.label | translate }}\n </span>\n <span class=\"si-weather-widget-forecast-illustration-cell\">\n <si-weather-widget-illustration\n [size]=\"illustrationSize\"\n [illustration]=\"day.illustration\"\n [altFallback]=\"day.label\"\n />\n </span>\n @for (col of cols; track $index; let extraIdx = $index) {\n <span\n class=\"si-weather-widget-forecast-extra\"\n role=\"img\"\n [class.si-weather-widget-forecast-extra-1]=\"extraIdx === 0\"\n [class.si-weather-widget-forecast-extra-2]=\"extraIdx === 1\"\n [class.si-weather-widget-forecast-extra-3]=\"extraIdx === 2\"\n [class.si-weather-widget-forecast-extra-4]=\"extraIdx === 3\"\n [class.si-weather-widget-forecast-extra-5]=\"extraIdx === 4\"\n [attr.aria-label]=\"(col.label | translate) + ': ' + (columnValue(col, i) ?? '')\"\n >\n @if (col.icon) {\n <si-icon\n class=\"icon si-weather-widget-forecast-extra-icon\"\n aria-hidden=\"true\"\n [icon]=\"col.icon\"\n />\n }\n <span aria-hidden=\"true\">{{ columnValue(col, i) ?? '' }}</span>\n </span>\n }\n <span class=\"si-weather-widget-forecast-range-cell\">\n <span class=\"si-weather-widget-forecast-range\">\n <span class=\"si-weather-widget-forecast-range-min\">{{ day.minTemperature }}</span>\n <span class=\"si-weather-widget-forecast-range-max\">{{ day.maxTemperature }}</span>\n </span>\n </span>\n </li>\n }\n </ul>\n }\n</div>\n", styles: [".si-weather-widget-forecast-range,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-range{font-size:1rem;font-weight:400;line-height:1.25}.si-weather-widget-forecast-day-range{display:flex;gap:4px}.si-weather-widget-forecast-range-min{color:var(--element-text-secondary)}.si-weather-widget-forecast-range-max{color:var(--element-text-primary);font-weight:600}@property --si-weather-forecast-extras{syntax: \"<integer>\"; inherits: true; initial-value: 0;}@property --si-weather-forecast-extras-cap{syntax: \"<integer>\"; inherits: true; initial-value: 5;}.si-weather-widget-forecast-list{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:max-content 1.25rem repeat(min(var(--si-weather-forecast-extras),var(--si-weather-forecast-extras-cap)),1fr auto) 1fr auto;row-gap:8px;align-items:center;inline-size:100%;container-type:inline-size}@container (max-width: 635px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 4}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 539px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 3}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 443px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 2}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-3,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 347px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 1}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-2,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-3,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 251px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 0}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-1,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-2,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-3,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}.si-weather-widget-forecast-row{display:contents}.si-weather-widget-forecast-day-label{color:var(--element-text-secondary);margin-block:8px;white-space:nowrap}.si-weather-widget-forecast.si-weather-widget-vertical .si-weather-widget-forecast-day-label{padding-inline-end:16px;grid-column-start:1}.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-label{text-align:center}.si-weather-widget-forecast-illustration-cell{display:inline-flex;align-items:center;justify-content:center;margin-block:6px;grid-column-start:2}.si-weather-widget-forecast-extra{display:inline-flex;align-items:center;gap:2px;white-space:nowrap}.si-weather-widget-forecast-extra-1{grid-column-start:4}.si-weather-widget-forecast-extra-2{grid-column-start:6}.si-weather-widget-forecast-extra-3{grid-column-start:8}.si-weather-widget-forecast-extra-4{grid-column-start:10}.si-weather-widget-forecast-extra-5{grid-column-start:12}.si-weather-widget-forecast-range-cell{white-space:nowrap;grid-column-end:-1}.si-weather-widget-forecast-range{display:inline-flex;align-items:baseline;justify-content:flex-end;gap:4px;margin-block:6px}:host{display:contents}.si-weather-widget-forecast{display:flex;flex-wrap:wrap;gap:8px}.si-weather-widget-forecast.si-weather-widget-vertical{display:block}.si-weather-widget-forecast.si-weather-widget-horizontal{flex-wrap:nowrap;overflow:hidden;container-type:inline-size}@container (max-width: 351px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}@container (max-width: 279px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-4,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}@container (max-width: 207px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-3,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-4,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}@container (max-width: 135px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-2,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-3,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-4,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}.si-weather-widget-forecast-day{flex:1 1 0;min-inline-size:64px;display:flex;flex-direction:column;align-items:center;gap:2px;text-align:center}.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day{padding-block:2px}.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-label{margin-block:0}.si-weather-widget-forecast-extra-icon{display:inline-flex;vertical-align:middle;margin-inline-end:2px;color:var(--element-text-secondary);margin-block:6px}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "component", type: SiWeatherWidgetIllustrationComponent, selector: "si-weather-widget-illustration", inputs: ["illustration", "condition", "altFallback", "size"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }] });
|
|
1362
1454
|
}
|
|
1363
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1455
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherWidgetForecastComponent, decorators: [{
|
|
1364
1456
|
type: Component,
|
|
1365
|
-
args: [{ selector: 'si-weather-widget-forecast', imports: [SiIconComponent, SiTranslatePipe, SiWeatherWidgetIllustrationComponent],
|
|
1457
|
+
args: [{ selector: 'si-weather-widget-forecast', imports: [SiIconComponent, SiTranslatePipe, SiWeatherWidgetIllustrationComponent], template: "@let days = forecast().days;\n@let cols = columns();\n@let illustrationSize = layout() === 'vertical' ? 'sm' : 'md';\n\n<div\n class=\"si-weather-widget-forecast\"\n [class.si-weather-widget-vertical]=\"layout() === 'vertical'\"\n [class.si-weather-widget-horizontal]=\"layout() === 'horizontal'\"\n [attr.aria-label]=\"forecastLabel() | translate\"\n>\n @if (layout() === 'horizontal') {\n @for (day of days; track $index) {\n <div\n class=\"si-weather-widget-forecast-day\"\n [class.si-weather-widget-forecast-day-2]=\"$index === 1\"\n [class.si-weather-widget-forecast-day-3]=\"$index === 2\"\n [class.si-weather-widget-forecast-day-4]=\"$index === 3\"\n [class.si-weather-widget-forecast-day-5]=\"$index === 4\"\n >\n <div class=\"si-weather-widget-forecast-day-label\">{{ day.label | translate }}</div>\n <si-weather-widget-illustration\n [size]=\"illustrationSize\"\n [illustration]=\"day.illustration\"\n [altFallback]=\"day.label\"\n />\n <div class=\"si-weather-widget-forecast-day-range\">\n <span class=\"si-weather-widget-forecast-range-min\">{{ day.minTemperature }}</span>\n <span class=\"si-weather-widget-forecast-range-max\">{{ day.maxTemperature }}</span>\n </div>\n </div>\n }\n } @else {\n <ul\n class=\"si-weather-widget-forecast-list\"\n role=\"list\"\n [style.--si-weather-forecast-extras]=\"cols.length\"\n >\n @for (day of days; track $index; let i = $index) {\n <li class=\"si-weather-widget-forecast-row\">\n <span class=\"si-weather-widget-forecast-day-label\">\n {{ day.label | translate }}\n </span>\n <span class=\"si-weather-widget-forecast-illustration-cell\">\n <si-weather-widget-illustration\n [size]=\"illustrationSize\"\n [illustration]=\"day.illustration\"\n [altFallback]=\"day.label\"\n />\n </span>\n @for (col of cols; track $index; let extraIdx = $index) {\n <span\n class=\"si-weather-widget-forecast-extra\"\n role=\"img\"\n [class.si-weather-widget-forecast-extra-1]=\"extraIdx === 0\"\n [class.si-weather-widget-forecast-extra-2]=\"extraIdx === 1\"\n [class.si-weather-widget-forecast-extra-3]=\"extraIdx === 2\"\n [class.si-weather-widget-forecast-extra-4]=\"extraIdx === 3\"\n [class.si-weather-widget-forecast-extra-5]=\"extraIdx === 4\"\n [attr.aria-label]=\"(col.label | translate) + ': ' + (columnValue(col, i) ?? '')\"\n >\n @if (col.icon) {\n <si-icon\n class=\"icon si-weather-widget-forecast-extra-icon\"\n aria-hidden=\"true\"\n [icon]=\"col.icon\"\n />\n }\n <span aria-hidden=\"true\">{{ columnValue(col, i) ?? '' }}</span>\n </span>\n }\n <span class=\"si-weather-widget-forecast-range-cell\">\n <span class=\"si-weather-widget-forecast-range\">\n <span class=\"si-weather-widget-forecast-range-min\">{{ day.minTemperature }}</span>\n <span class=\"si-weather-widget-forecast-range-max\">{{ day.maxTemperature }}</span>\n </span>\n </span>\n </li>\n }\n </ul>\n }\n</div>\n", styles: [".si-weather-widget-forecast-range,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-range{font-size:1rem;font-weight:400;line-height:1.25}.si-weather-widget-forecast-day-range{display:flex;gap:4px}.si-weather-widget-forecast-range-min{color:var(--element-text-secondary)}.si-weather-widget-forecast-range-max{color:var(--element-text-primary);font-weight:600}@property --si-weather-forecast-extras{syntax: \"<integer>\"; inherits: true; initial-value: 0;}@property --si-weather-forecast-extras-cap{syntax: \"<integer>\"; inherits: true; initial-value: 5;}.si-weather-widget-forecast-list{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:max-content 1.25rem repeat(min(var(--si-weather-forecast-extras),var(--si-weather-forecast-extras-cap)),1fr auto) 1fr auto;row-gap:8px;align-items:center;inline-size:100%;container-type:inline-size}@container (max-width: 635px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 4}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 539px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 3}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 443px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 2}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-3,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 347px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 1}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-2,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-3,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}@container (max-width: 251px){.si-weather-widget-forecast-list{--si-weather-forecast-extras-cap: 0}.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-1,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-2,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-3,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-4,.si-weather-widget-forecast-list .si-weather-widget-forecast-extra-5{display:none}}.si-weather-widget-forecast-row{display:contents}.si-weather-widget-forecast-day-label{color:var(--element-text-secondary);margin-block:8px;white-space:nowrap}.si-weather-widget-forecast.si-weather-widget-vertical .si-weather-widget-forecast-day-label{padding-inline-end:16px;grid-column-start:1}.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-label{text-align:center}.si-weather-widget-forecast-illustration-cell{display:inline-flex;align-items:center;justify-content:center;margin-block:6px;grid-column-start:2}.si-weather-widget-forecast-extra{display:inline-flex;align-items:center;gap:2px;white-space:nowrap}.si-weather-widget-forecast-extra-1{grid-column-start:4}.si-weather-widget-forecast-extra-2{grid-column-start:6}.si-weather-widget-forecast-extra-3{grid-column-start:8}.si-weather-widget-forecast-extra-4{grid-column-start:10}.si-weather-widget-forecast-extra-5{grid-column-start:12}.si-weather-widget-forecast-range-cell{white-space:nowrap;grid-column-end:-1}.si-weather-widget-forecast-range{display:inline-flex;align-items:baseline;justify-content:flex-end;gap:4px;margin-block:6px}:host{display:contents}.si-weather-widget-forecast{display:flex;flex-wrap:wrap;gap:8px}.si-weather-widget-forecast.si-weather-widget-vertical{display:block}.si-weather-widget-forecast.si-weather-widget-horizontal{flex-wrap:nowrap;overflow:hidden;container-type:inline-size}@container (max-width: 351px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}@container (max-width: 279px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-4,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}@container (max-width: 207px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-3,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-4,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}@container (max-width: 135px){.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-2,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-3,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-4,.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-5{display:none}}.si-weather-widget-forecast-day{flex:1 1 0;min-inline-size:64px;display:flex;flex-direction:column;align-items:center;gap:2px;text-align:center}.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day{padding-block:2px}.si-weather-widget-forecast.si-weather-widget-horizontal .si-weather-widget-forecast-day-label{margin-block:0}.si-weather-widget-forecast-extra-icon{display:inline-flex;vertical-align:middle;margin-inline-end:2px;color:var(--element-text-secondary);margin-block:6px}\n"] }]
|
|
1366
1458
|
}], propDecorators: { forecast: [{ type: i0.Input, args: [{ isSignal: true, alias: "forecast", required: true }] }], layout: [{ type: i0.Input, args: [{ isSignal: true, alias: "layout", required: false }] }], forecastLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "forecastLabel", required: false }] }] } });
|
|
1367
1459
|
|
|
1368
1460
|
/**
|
|
@@ -1376,8 +1468,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
1376
1468
|
* @internal
|
|
1377
1469
|
*/
|
|
1378
1470
|
class SiWeatherWidgetSkeletonComponent {
|
|
1379
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1380
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "
|
|
1471
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherWidgetSkeletonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1472
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.7", type: SiWeatherWidgetSkeletonComponent, isStandalone: true, selector: "si-weather-widget-skeleton", ngImport: i0, template: `
|
|
1381
1473
|
<div class="si-weather-widget-skeleton-row">
|
|
1382
1474
|
<div class="si-weather-widget-skeleton-value si-skeleton"></div>
|
|
1383
1475
|
<div class="si-weather-widget-skeleton-col">
|
|
@@ -1386,9 +1478,9 @@ class SiWeatherWidgetSkeletonComponent {
|
|
|
1386
1478
|
<div class="si-weather-widget-skeleton-line si-skeleton"></div>
|
|
1387
1479
|
</div>
|
|
1388
1480
|
</div>
|
|
1389
|
-
`, isInline: true, styles: [":host{display:flex;flex-direction:column;gap:6px}.si-weather-widget-skeleton-row{display:flex;align-items:stretch;justify-content:space-between;gap:8px}.si-weather-widget-skeleton-col{display:flex;flex:0 0 auto;flex-direction:column;align-items:flex-end;gap:6px}.si-weather-widget-skeleton-illustration{flex:0 0 auto;inline-size:40px;block-size:40px;border-radius:50%}.si-weather-widget-skeleton-value{flex:0 0 auto;align-self:stretch;inline-size:5.3125rem;block-size:auto}.si-weather-widget-skeleton-line{block-size:.875rem;inline-size:7.5rem}.si-weather-widget-skeleton-line:last-child{inline-size:5rem}\n"]
|
|
1481
|
+
`, isInline: true, styles: [":host{display:flex;flex-direction:column;gap:6px}.si-weather-widget-skeleton-row{display:flex;align-items:stretch;justify-content:space-between;gap:8px}.si-weather-widget-skeleton-col{display:flex;flex:0 0 auto;flex-direction:column;align-items:flex-end;gap:6px}.si-weather-widget-skeleton-illustration{flex:0 0 auto;inline-size:40px;block-size:40px;border-radius:50%}.si-weather-widget-skeleton-value{flex:0 0 auto;align-self:stretch;inline-size:5.3125rem;block-size:auto}.si-weather-widget-skeleton-line{block-size:.875rem;inline-size:7.5rem}.si-weather-widget-skeleton-line:last-child{inline-size:5rem}\n"] });
|
|
1390
1482
|
}
|
|
1391
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1483
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherWidgetSkeletonComponent, decorators: [{
|
|
1392
1484
|
type: Component,
|
|
1393
1485
|
args: [{ selector: 'si-weather-widget-skeleton', template: `
|
|
1394
1486
|
<div class="si-weather-widget-skeleton-row">
|
|
@@ -1399,7 +1491,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
1399
1491
|
<div class="si-weather-widget-skeleton-line si-skeleton"></div>
|
|
1400
1492
|
</div>
|
|
1401
1493
|
</div>
|
|
1402
|
-
`,
|
|
1494
|
+
`, styles: [":host{display:flex;flex-direction:column;gap:6px}.si-weather-widget-skeleton-row{display:flex;align-items:stretch;justify-content:space-between;gap:8px}.si-weather-widget-skeleton-col{display:flex;flex:0 0 auto;flex-direction:column;align-items:flex-end;gap:6px}.si-weather-widget-skeleton-illustration{flex:0 0 auto;inline-size:40px;block-size:40px;border-radius:50%}.si-weather-widget-skeleton-value{flex:0 0 auto;align-self:stretch;inline-size:5.3125rem;block-size:auto}.si-weather-widget-skeleton-line{block-size:.875rem;inline-size:7.5rem}.si-weather-widget-skeleton-line:last-child{inline-size:5rem}\n"] }]
|
|
1403
1495
|
}] });
|
|
1404
1496
|
|
|
1405
1497
|
/**
|
|
@@ -1421,10 +1513,10 @@ class SiWeatherRangeDefDirective {
|
|
|
1421
1513
|
static ngTemplateContextGuard(_dir, ctx) {
|
|
1422
1514
|
return true;
|
|
1423
1515
|
}
|
|
1424
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1425
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "
|
|
1516
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherRangeDefDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1517
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.7", type: SiWeatherRangeDefDirective, isStandalone: true, selector: "[siWeatherRangeDef]", ngImport: i0 });
|
|
1426
1518
|
}
|
|
1427
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1519
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherRangeDefDirective, decorators: [{
|
|
1428
1520
|
type: Directive,
|
|
1429
1521
|
args: [{ selector: '[siWeatherRangeDef]' }]
|
|
1430
1522
|
}] });
|
|
@@ -1451,13 +1543,15 @@ class SiWeatherWidgetBodyComponent extends SiWidgetBaseDirective {
|
|
|
1451
1543
|
*
|
|
1452
1544
|
* @defaultValue 'vertical'
|
|
1453
1545
|
*/
|
|
1454
|
-
layout = input('vertical',
|
|
1546
|
+
layout = input('vertical', /* @ts-ignore */
|
|
1547
|
+
...(ngDevMode ? [{ debugName: "layout" }] : /* istanbul ignore next */ []));
|
|
1455
1548
|
/**
|
|
1456
1549
|
* Optional location label, shown inside the body in the compact layout only.
|
|
1457
1550
|
* The non-compact layouts render the location via the `<si-card>` heading
|
|
1458
1551
|
* managed by `SiWeatherWidgetComponent`.
|
|
1459
1552
|
*/
|
|
1460
|
-
location = input(
|
|
1553
|
+
location = input(/* @ts-ignore */
|
|
1554
|
+
...(ngDevMode ? [undefined, { debugName: "location" }] : /* istanbul ignore next */ []));
|
|
1461
1555
|
/**
|
|
1462
1556
|
* Accessible label for the additional data list.
|
|
1463
1557
|
*
|
|
@@ -1466,7 +1560,8 @@ class SiWeatherWidgetBodyComponent extends SiWidgetBaseDirective {
|
|
|
1466
1560
|
* t(() => $localize`:@@SI_WEATHER_WIDGET.METRICS_LABEL:Additional weather data`)
|
|
1467
1561
|
* ```
|
|
1468
1562
|
*/
|
|
1469
|
-
metricsLabel = input(t(() => $localize `:@@SI_WEATHER_WIDGET.METRICS_LABEL:Additional weather data`),
|
|
1563
|
+
metricsLabel = input(t(() => $localize `:@@SI_WEATHER_WIDGET.METRICS_LABEL:Additional weather data`), /* @ts-ignore */
|
|
1564
|
+
...(ngDevMode ? [{ debugName: "metricsLabel" }] : /* istanbul ignore next */ []));
|
|
1470
1565
|
/**
|
|
1471
1566
|
* Accessible label for the forecast section.
|
|
1472
1567
|
*
|
|
@@ -1475,13 +1570,16 @@ class SiWeatherWidgetBodyComponent extends SiWidgetBaseDirective {
|
|
|
1475
1570
|
* t(() => $localize`:@@SI_WEATHER_WIDGET.FORECAST_LABEL:Weather forecast`)
|
|
1476
1571
|
* ```
|
|
1477
1572
|
*/
|
|
1478
|
-
forecastLabel = input(t(() => $localize `:@@SI_WEATHER_WIDGET.FORECAST_LABEL:Weather forecast`),
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1573
|
+
forecastLabel = input(t(() => $localize `:@@SI_WEATHER_WIDGET.FORECAST_LABEL:Weather forecast`), /* @ts-ignore */
|
|
1574
|
+
...(ngDevMode ? [{ debugName: "forecastLabel" }] : /* istanbul ignore next */ []));
|
|
1575
|
+
layoutClass = computed(() => LAYOUT_CLASS[this.layout()], /* @ts-ignore */
|
|
1576
|
+
...(ngDevMode ? [{ debugName: "layoutClass" }] : /* istanbul ignore next */ []));
|
|
1577
|
+
isCompact = computed(() => this.layout() === 'compact', /* @ts-ignore */
|
|
1578
|
+
...(ngDevMode ? [{ debugName: "isCompact" }] : /* istanbul ignore next */ []));
|
|
1579
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherWidgetBodyComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
1580
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.7", type: SiWeatherWidgetBodyComponent, isStandalone: true, selector: "si-weather-widget-body", inputs: { layout: { classPropertyName: "layout", publicName: "layout", isSignal: true, isRequired: false, transformFunction: null }, location: { classPropertyName: "location", publicName: "location", isSignal: true, isRequired: false, transformFunction: null }, metricsLabel: { classPropertyName: "metricsLabel", publicName: "metricsLabel", isSignal: true, isRequired: false, transformFunction: null }, forecastLabel: { classPropertyName: "forecastLabel", publicName: "forecastLabel", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "layoutClass()" } }, usesInheritance: true, ngImport: i0, template: "@let data = value();\n@let current = data?.current;\n@let metrics = data?.metrics;\n@let forecast = data?.forecast;\n@let loading = showLoadingIndicator();\n\n@if (loading) {\n <si-weather-widget-skeleton />\n} @else if (current) {\n @if (isCompact()) {\n <div class=\"si-weather-widget-today\">\n <si-weather-widget-illustration\n size=\"sm\"\n [illustration]=\"current.illustration\"\n [condition]=\"current.condition\"\n [altFallback]=\"current.illustrationAlt\"\n />\n <div class=\"si-weather-widget-today-info\">\n @if (location()) {\n <div class=\"si-weather-widget-location\">{{ location() | translate }}</div>\n }\n <ng-container *ngTemplateOutlet=\"rangeTpl; context: { $implicit: current }\" />\n </div>\n </div>\n } @else {\n <div class=\"si-weather-widget-today\">\n <div class=\"si-weather-widget-temperature\">{{ current.temperature }}</div>\n <div class=\"si-weather-widget-today-info\">\n <si-weather-widget-illustration\n size=\"lg\"\n [illustration]=\"current.illustration\"\n [condition]=\"current.condition\"\n [altFallback]=\"current.illustrationAlt\"\n />\n @if (current.condition) {\n <div class=\"si-weather-widget-condition\">{{ current.condition | translate }}</div>\n }\n <ng-container *ngTemplateOutlet=\"rangeTpl; context: { $implicit: current }\" />\n </div>\n </div>\n }\n\n @if (metrics?.length) {\n <ul class=\"si-weather-widget-metrics\" [attr.aria-label]=\"metricsLabel() | translate\">\n @for (metric of metrics; track $index) {\n <li class=\"si-weather-widget-metric\">\n <span class=\"si-weather-widget-metric-label\">{{ metric.label | translate }}</span>\n <span class=\"si-weather-widget-metric-value\">{{ metric.value }}</span>\n </li>\n }\n </ul>\n }\n\n @if (!isCompact() && forecast && forecast.days.length) {\n <si-weather-widget-forecast\n [forecast]=\"forecast\"\n [layout]=\"layout() === 'horizontal' ? 'horizontal' : 'vertical'\"\n [forecastLabel]=\"forecastLabel()\"\n />\n }\n}\n\n<ng-template #rangeTpl let-c siWeatherRangeDef>\n @if (c.minTemperature !== undefined || c.maxTemperature !== undefined) {\n <div class=\"si-weather-widget-range\">\n @if (c.minTemperature !== undefined) {\n <span class=\"si-weather-widget-range-min\">{{ c.minTemperature }}</span>\n }\n @if (c.maxTemperature !== undefined) {\n <span class=\"si-weather-widget-range-max\">{{ c.maxTemperature }}</span>\n }\n </div>\n }\n</ng-template>\n", styles: [":host{display:flex;flex-direction:column;gap:32px;block-size:100%}.si-weather-widget-condition,:host.si-weather-widget-vertical .si-weather-widget-range,:host.si-weather-widget-horizontal .si-weather-widget-range{font-size:1rem;font-weight:400;line-height:1.25}.si-weather-widget-today{display:flex;align-items:start;gap:8px}:host.si-weather-widget-vertical .si-weather-widget-today,:host.si-weather-widget-horizontal .si-weather-widget-today{justify-content:space-between}:host.si-weather-widget-vertical .si-weather-widget-today-info,:host.si-weather-widget-horizontal .si-weather-widget-today-info{align-items:flex-end;text-align:end}.si-weather-widget-today-info{display:flex;flex-direction:column;gap:2px;min-inline-size:0}.si-weather-widget-temperature{font-size:3.5rem;font-weight:400;line-height:1.2857142857;color:var(--element-text-primary)}.si-weather-widget-condition{color:var(--element-text-primary)}.si-weather-widget-location{font-weight:600;color:var(--element-text-primary)}.si-weather-widget-range{display:flex;gap:4px}.si-weather-widget-range-min{color:var(--element-text-secondary)}.si-weather-widget-range-max{color:var(--element-text-primary);font-weight:600}.si-weather-widget-metrics{list-style:none;padding:0;display:flex;flex-direction:column;gap:8px;margin-block:0;inline-size:100%}.si-weather-widget-metric{display:flex;align-items:baseline;justify-content:space-between;gap:8px}.si-weather-widget-metric-label{color:var(--element-text-secondary)}.si-weather-widget-metric-value{color:var(--element-text-primary);font-weight:600;text-align:end}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: SiWeatherRangeDefDirective, selector: "[siWeatherRangeDef]" }, { kind: "component", type: SiWeatherWidgetForecastComponent, selector: "si-weather-widget-forecast", inputs: ["forecast", "layout", "forecastLabel"] }, { kind: "component", type: SiWeatherWidgetIllustrationComponent, selector: "si-weather-widget-illustration", inputs: ["illustration", "condition", "altFallback", "size"] }, { kind: "component", type: SiWeatherWidgetSkeletonComponent, selector: "si-weather-widget-skeleton" }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }] });
|
|
1483
1581
|
}
|
|
1484
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1582
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherWidgetBodyComponent, decorators: [{
|
|
1485
1583
|
type: Component,
|
|
1486
1584
|
args: [{ selector: 'si-weather-widget-body', imports: [
|
|
1487
1585
|
NgTemplateOutlet,
|
|
@@ -1490,7 +1588,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
|
|
|
1490
1588
|
SiWeatherWidgetForecastComponent,
|
|
1491
1589
|
SiWeatherWidgetIllustrationComponent,
|
|
1492
1590
|
SiWeatherWidgetSkeletonComponent
|
|
1493
|
-
],
|
|
1591
|
+
], host: { '[class]': 'layoutClass()' }, template: "@let data = value();\n@let current = data?.current;\n@let metrics = data?.metrics;\n@let forecast = data?.forecast;\n@let loading = showLoadingIndicator();\n\n@if (loading) {\n <si-weather-widget-skeleton />\n} @else if (current) {\n @if (isCompact()) {\n <div class=\"si-weather-widget-today\">\n <si-weather-widget-illustration\n size=\"sm\"\n [illustration]=\"current.illustration\"\n [condition]=\"current.condition\"\n [altFallback]=\"current.illustrationAlt\"\n />\n <div class=\"si-weather-widget-today-info\">\n @if (location()) {\n <div class=\"si-weather-widget-location\">{{ location() | translate }}</div>\n }\n <ng-container *ngTemplateOutlet=\"rangeTpl; context: { $implicit: current }\" />\n </div>\n </div>\n } @else {\n <div class=\"si-weather-widget-today\">\n <div class=\"si-weather-widget-temperature\">{{ current.temperature }}</div>\n <div class=\"si-weather-widget-today-info\">\n <si-weather-widget-illustration\n size=\"lg\"\n [illustration]=\"current.illustration\"\n [condition]=\"current.condition\"\n [altFallback]=\"current.illustrationAlt\"\n />\n @if (current.condition) {\n <div class=\"si-weather-widget-condition\">{{ current.condition | translate }}</div>\n }\n <ng-container *ngTemplateOutlet=\"rangeTpl; context: { $implicit: current }\" />\n </div>\n </div>\n }\n\n @if (metrics?.length) {\n <ul class=\"si-weather-widget-metrics\" [attr.aria-label]=\"metricsLabel() | translate\">\n @for (metric of metrics; track $index) {\n <li class=\"si-weather-widget-metric\">\n <span class=\"si-weather-widget-metric-label\">{{ metric.label | translate }}</span>\n <span class=\"si-weather-widget-metric-value\">{{ metric.value }}</span>\n </li>\n }\n </ul>\n }\n\n @if (!isCompact() && forecast && forecast.days.length) {\n <si-weather-widget-forecast\n [forecast]=\"forecast\"\n [layout]=\"layout() === 'horizontal' ? 'horizontal' : 'vertical'\"\n [forecastLabel]=\"forecastLabel()\"\n />\n }\n}\n\n<ng-template #rangeTpl let-c siWeatherRangeDef>\n @if (c.minTemperature !== undefined || c.maxTemperature !== undefined) {\n <div class=\"si-weather-widget-range\">\n @if (c.minTemperature !== undefined) {\n <span class=\"si-weather-widget-range-min\">{{ c.minTemperature }}</span>\n }\n @if (c.maxTemperature !== undefined) {\n <span class=\"si-weather-widget-range-max\">{{ c.maxTemperature }}</span>\n }\n </div>\n }\n</ng-template>\n", styles: [":host{display:flex;flex-direction:column;gap:32px;block-size:100%}.si-weather-widget-condition,:host.si-weather-widget-vertical .si-weather-widget-range,:host.si-weather-widget-horizontal .si-weather-widget-range{font-size:1rem;font-weight:400;line-height:1.25}.si-weather-widget-today{display:flex;align-items:start;gap:8px}:host.si-weather-widget-vertical .si-weather-widget-today,:host.si-weather-widget-horizontal .si-weather-widget-today{justify-content:space-between}:host.si-weather-widget-vertical .si-weather-widget-today-info,:host.si-weather-widget-horizontal .si-weather-widget-today-info{align-items:flex-end;text-align:end}.si-weather-widget-today-info{display:flex;flex-direction:column;gap:2px;min-inline-size:0}.si-weather-widget-temperature{font-size:3.5rem;font-weight:400;line-height:1.2857142857;color:var(--element-text-primary)}.si-weather-widget-condition{color:var(--element-text-primary)}.si-weather-widget-location{font-weight:600;color:var(--element-text-primary)}.si-weather-widget-range{display:flex;gap:4px}.si-weather-widget-range-min{color:var(--element-text-secondary)}.si-weather-widget-range-max{color:var(--element-text-primary);font-weight:600}.si-weather-widget-metrics{list-style:none;padding:0;display:flex;flex-direction:column;gap:8px;margin-block:0;inline-size:100%}.si-weather-widget-metric{display:flex;align-items:baseline;justify-content:space-between;gap:8px}.si-weather-widget-metric-label{color:var(--element-text-secondary)}.si-weather-widget-metric-value{color:var(--element-text-primary);font-weight:600;text-align:end}\n"] }]
|
|
1494
1592
|
}], propDecorators: { layout: [{ type: i0.Input, args: [{ isSignal: true, alias: "layout", required: false }] }], location: [{ type: i0.Input, args: [{ isSignal: true, alias: "location", required: false }] }], metricsLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "metricsLabel", required: false }] }], forecastLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "forecastLabel", required: false }] }] } });
|
|
1495
1593
|
|
|
1496
1594
|
/**
|
|
@@ -1525,93 +1623,109 @@ class SiWeatherWidgetComponent {
|
|
|
1525
1623
|
* layouts. In the `compact` layout, the location is rendered inside the body
|
|
1526
1624
|
* instead and this input is ignored.
|
|
1527
1625
|
*/
|
|
1528
|
-
heading = input(
|
|
1626
|
+
heading = input(/* @ts-ignore */
|
|
1627
|
+
...(ngDevMode ? [undefined, { debugName: "heading" }] : /* istanbul ignore next */ []));
|
|
1529
1628
|
/**
|
|
1530
1629
|
* Location displayed next to the illustration in the `compact` layout. Has
|
|
1531
1630
|
* no effect in `vertical` or `horizontal` layouts; use {@link heading} there.
|
|
1532
1631
|
*/
|
|
1533
|
-
location = input(
|
|
1632
|
+
location = input(/* @ts-ignore */
|
|
1633
|
+
...(ngDevMode ? [undefined, { debugName: "location" }] : /* istanbul ignore next */ []));
|
|
1534
1634
|
/**
|
|
1535
1635
|
* Visual layout. {@link SiWeatherWidgetLayout}.
|
|
1536
1636
|
*
|
|
1537
1637
|
* @defaultValue 'vertical'
|
|
1538
1638
|
*/
|
|
1539
|
-
layout = input('vertical',
|
|
1639
|
+
layout = input('vertical', /* @ts-ignore */
|
|
1640
|
+
...(ngDevMode ? [{ debugName: "layout" }] : /* istanbul ignore next */ []));
|
|
1540
1641
|
/**
|
|
1541
1642
|
* Composite weather payload of type {@link SiWeatherWidgetData}.
|
|
1542
1643
|
*/
|
|
1543
|
-
value = input(
|
|
1644
|
+
value = input(/* @ts-ignore */
|
|
1645
|
+
...(ngDevMode ? [undefined, { debugName: "value" }] : /* istanbul ignore next */ []));
|
|
1544
1646
|
/**
|
|
1545
1647
|
* Input list of primary action items. Supports up to **4** actions and omits additional ones.
|
|
1546
1648
|
*
|
|
1547
1649
|
* @defaultValue []
|
|
1548
1650
|
*/
|
|
1549
|
-
primaryActions = input([],
|
|
1651
|
+
primaryActions = input([], /* @ts-ignore */
|
|
1652
|
+
...(ngDevMode ? [{ debugName: "primaryActions" }] : /* istanbul ignore next */ []));
|
|
1550
1653
|
/**
|
|
1551
1654
|
* Input list of secondary action items.
|
|
1552
1655
|
*
|
|
1553
1656
|
* @defaultValue []
|
|
1554
1657
|
*/
|
|
1555
|
-
secondaryActions = input([],
|
|
1658
|
+
secondaryActions = input([], /* @ts-ignore */
|
|
1659
|
+
...(ngDevMode ? [{ debugName: "secondaryActions" }] : /* istanbul ignore next */ []));
|
|
1556
1660
|
/**
|
|
1557
1661
|
* Option to disable automatic start of skeleton loading indication.
|
|
1558
1662
|
*
|
|
1559
1663
|
* @defaultValue false
|
|
1560
1664
|
*/
|
|
1561
|
-
disableAutoLoadingIndicator = input(false, { ...(ngDevMode ? { debugName: "disableAutoLoadingIndicator" } : {}), transform: booleanAttribute });
|
|
1665
|
+
disableAutoLoadingIndicator = input(false, { ...(ngDevMode ? { debugName: "disableAutoLoadingIndicator" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
1562
1666
|
/**
|
|
1563
1667
|
* Input to start and stop the skeleton loading indication.
|
|
1564
1668
|
*
|
|
1565
1669
|
* @defaultValue false
|
|
1566
1670
|
*/
|
|
1567
|
-
showLoadingIndicator = input(false, { ...(ngDevMode ? { debugName: "showLoadingIndicator" } : {}), transform: booleanAttribute });
|
|
1671
|
+
showLoadingIndicator = input(false, { ...(ngDevMode ? { debugName: "showLoadingIndicator" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
1568
1672
|
/**
|
|
1569
1673
|
* Initial delay time in milliseconds before enabling loading indicator.
|
|
1570
1674
|
* Only used once initially during construction.
|
|
1571
1675
|
*
|
|
1572
1676
|
* @defaultValue 300
|
|
1573
1677
|
*/
|
|
1574
|
-
initialLoadingIndicatorDebounceTime = input(300,
|
|
1678
|
+
initialLoadingIndicatorDebounceTime = input(300, /* @ts-ignore */
|
|
1679
|
+
...(ngDevMode ? [{ debugName: "initialLoadingIndicatorDebounceTime" }] : /* istanbul ignore next */ []));
|
|
1575
1680
|
/**
|
|
1576
1681
|
* Image source for the card.
|
|
1577
1682
|
*/
|
|
1578
|
-
imgSrc = input(
|
|
1683
|
+
imgSrc = input(/* @ts-ignore */
|
|
1684
|
+
...(ngDevMode ? [undefined, { debugName: "imgSrc" }] : /* istanbul ignore next */ []));
|
|
1579
1685
|
/**
|
|
1580
1686
|
* Alt text for a provided image.
|
|
1581
1687
|
*/
|
|
1582
|
-
imgAlt = input(
|
|
1688
|
+
imgAlt = input(/* @ts-ignore */
|
|
1689
|
+
...(ngDevMode ? [undefined, { debugName: "imgAlt" }] : /* istanbul ignore next */ []));
|
|
1583
1690
|
/**
|
|
1584
1691
|
* Defines if an image is placed on top or start (left) of the card.
|
|
1585
1692
|
*
|
|
1586
1693
|
* @defaultValue 'vertical'
|
|
1587
1694
|
*/
|
|
1588
|
-
imgDir = input('vertical',
|
|
1695
|
+
imgDir = input('vertical', /* @ts-ignore */
|
|
1696
|
+
...(ngDevMode ? [{ debugName: "imgDir" }] : /* istanbul ignore next */ []));
|
|
1589
1697
|
/**
|
|
1590
1698
|
* Sets the image [object-fit](https://developer.mozilla.org/en-US/docs/Web/CSS/object-fit) CSS property.
|
|
1591
1699
|
*
|
|
1592
1700
|
* @defaultValue 'scale-down'
|
|
1593
1701
|
*/
|
|
1594
|
-
imgObjectFit = input('scale-down',
|
|
1702
|
+
imgObjectFit = input('scale-down', /* @ts-ignore */
|
|
1703
|
+
...(ngDevMode ? [{ debugName: "imgObjectFit" }] : /* istanbul ignore next */ []));
|
|
1595
1704
|
/**
|
|
1596
1705
|
* Sets the image [object-position](https://developer.mozilla.org/en-US/docs/Web/CSS/object-position) CSS property.
|
|
1597
1706
|
*/
|
|
1598
|
-
imgObjectPosition = input(
|
|
1707
|
+
imgObjectPosition = input(/* @ts-ignore */
|
|
1708
|
+
...(ngDevMode ? [undefined, { debugName: "imgObjectPosition" }] : /* istanbul ignore next */ []));
|
|
1599
1709
|
/**
|
|
1600
1710
|
* Optional accent line.
|
|
1601
1711
|
*/
|
|
1602
|
-
accentLine = input(
|
|
1712
|
+
accentLine = input(/* @ts-ignore */
|
|
1713
|
+
...(ngDevMode ? [undefined, { debugName: "accentLine" }] : /* istanbul ignore next */ []));
|
|
1603
1714
|
accentClass = computed(() => {
|
|
1604
1715
|
const accentLine = this.accentLine();
|
|
1605
1716
|
return accentLine ? 'accent-' + accentLine : '';
|
|
1606
|
-
},
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1717
|
+
}, /* @ts-ignore */
|
|
1718
|
+
...(ngDevMode ? [{ debugName: "accentClass" }] : /* istanbul ignore next */ []));
|
|
1719
|
+
cardHeading = computed(() => this.layout() === 'compact' ? undefined : this.heading(), /* @ts-ignore */
|
|
1720
|
+
...(ngDevMode ? [{ debugName: "cardHeading" }] : /* istanbul ignore next */ []));
|
|
1721
|
+
bodyLocation = computed(() => this.layout() === 'compact' ? this.location() : undefined, /* @ts-ignore */
|
|
1722
|
+
...(ngDevMode ? [{ debugName: "bodyLocation" }] : /* istanbul ignore next */ []));
|
|
1723
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherWidgetComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1724
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.0.7", type: SiWeatherWidgetComponent, isStandalone: true, selector: "si-weather-widget", inputs: { heading: { classPropertyName: "heading", publicName: "heading", isSignal: true, isRequired: false, transformFunction: null }, location: { classPropertyName: "location", publicName: "location", isSignal: true, isRequired: false, transformFunction: null }, layout: { classPropertyName: "layout", publicName: "layout", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, primaryActions: { classPropertyName: "primaryActions", publicName: "primaryActions", isSignal: true, isRequired: false, transformFunction: null }, secondaryActions: { classPropertyName: "secondaryActions", publicName: "secondaryActions", isSignal: true, isRequired: false, transformFunction: null }, disableAutoLoadingIndicator: { classPropertyName: "disableAutoLoadingIndicator", publicName: "disableAutoLoadingIndicator", isSignal: true, isRequired: false, transformFunction: null }, showLoadingIndicator: { classPropertyName: "showLoadingIndicator", publicName: "showLoadingIndicator", isSignal: true, isRequired: false, transformFunction: null }, initialLoadingIndicatorDebounceTime: { classPropertyName: "initialLoadingIndicatorDebounceTime", publicName: "initialLoadingIndicatorDebounceTime", isSignal: true, isRequired: false, transformFunction: null }, imgSrc: { classPropertyName: "imgSrc", publicName: "imgSrc", isSignal: true, isRequired: false, transformFunction: null }, imgAlt: { classPropertyName: "imgAlt", publicName: "imgAlt", isSignal: true, isRequired: false, transformFunction: null }, imgDir: { classPropertyName: "imgDir", publicName: "imgDir", isSignal: true, isRequired: false, transformFunction: null }, imgObjectFit: { classPropertyName: "imgObjectFit", publicName: "imgObjectFit", isSignal: true, isRequired: false, transformFunction: null }, imgObjectPosition: { classPropertyName: "imgObjectPosition", publicName: "imgObjectPosition", isSignal: true, isRequired: false, transformFunction: null }, accentLine: { classPropertyName: "accentLine", publicName: "accentLine", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "si-weather-widget" }, ngImport: i0, template: "<si-card\n class=\"h-100\"\n [class]=\"accentClass()\"\n [heading]=\"cardHeading()\"\n [primaryActions]=\"primaryActions()\"\n [secondaryActions]=\"secondaryActions()\"\n [imgSrc]=\"imgSrc()\"\n [imgDir]=\"imgDir()\"\n [imgAlt]=\"imgAlt()\"\n [imgObjectFit]=\"imgObjectFit()\"\n [imgObjectPosition]=\"imgObjectPosition()\"\n>\n <div class=\"card-body\" body>\n <si-weather-widget-body\n [layout]=\"layout()\"\n [value]=\"value()\"\n [location]=\"bodyLocation()\"\n [disableAutoLoadingIndicator]=\"disableAutoLoadingIndicator()\"\n [showLoadingIndicator]=\"showLoadingIndicator()\"\n [initialLoadingIndicatorDebounceTime]=\"initialLoadingIndicatorDebounceTime()\"\n />\n </div>\n</si-card>\n", dependencies: [{ kind: "component", type: SiCardComponent, selector: "si-card", inputs: ["primaryActions", "secondaryActions", "actionParam", "actionBarViewType", "actionBarTitle"] }, { kind: "component", type: SiWeatherWidgetBodyComponent, selector: "si-weather-widget-body", inputs: ["layout", "location", "metricsLabel", "forecastLabel"] }] });
|
|
1611
1725
|
}
|
|
1612
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1726
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.7", ngImport: i0, type: SiWeatherWidgetComponent, decorators: [{
|
|
1613
1727
|
type: Component,
|
|
1614
|
-
args: [{ selector: 'si-weather-widget', imports: [SiCardComponent, SiWeatherWidgetBodyComponent],
|
|
1728
|
+
args: [{ selector: 'si-weather-widget', imports: [SiCardComponent, SiWeatherWidgetBodyComponent], host: { class: 'si-weather-widget' }, template: "<si-card\n class=\"h-100\"\n [class]=\"accentClass()\"\n [heading]=\"cardHeading()\"\n [primaryActions]=\"primaryActions()\"\n [secondaryActions]=\"secondaryActions()\"\n [imgSrc]=\"imgSrc()\"\n [imgDir]=\"imgDir()\"\n [imgAlt]=\"imgAlt()\"\n [imgObjectFit]=\"imgObjectFit()\"\n [imgObjectPosition]=\"imgObjectPosition()\"\n>\n <div class=\"card-body\" body>\n <si-weather-widget-body\n [layout]=\"layout()\"\n [value]=\"value()\"\n [location]=\"bodyLocation()\"\n [disableAutoLoadingIndicator]=\"disableAutoLoadingIndicator()\"\n [showLoadingIndicator]=\"showLoadingIndicator()\"\n [initialLoadingIndicatorDebounceTime]=\"initialLoadingIndicatorDebounceTime()\"\n />\n </div>\n</si-card>\n" }]
|
|
1615
1729
|
}], propDecorators: { heading: [{ type: i0.Input, args: [{ isSignal: true, alias: "heading", required: false }] }], location: [{ type: i0.Input, args: [{ isSignal: true, alias: "location", required: false }] }], layout: [{ type: i0.Input, args: [{ isSignal: true, alias: "layout", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }], primaryActions: [{ type: i0.Input, args: [{ isSignal: true, alias: "primaryActions", required: false }] }], secondaryActions: [{ type: i0.Input, args: [{ isSignal: true, alias: "secondaryActions", required: false }] }], disableAutoLoadingIndicator: [{ type: i0.Input, args: [{ isSignal: true, alias: "disableAutoLoadingIndicator", required: false }] }], showLoadingIndicator: [{ type: i0.Input, args: [{ isSignal: true, alias: "showLoadingIndicator", required: false }] }], initialLoadingIndicatorDebounceTime: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialLoadingIndicatorDebounceTime", required: false }] }], imgSrc: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgSrc", required: false }] }], imgAlt: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgAlt", required: false }] }], imgDir: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgDir", required: false }] }], imgObjectFit: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgObjectFit", required: false }] }], imgObjectPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgObjectPosition", required: false }] }], accentLine: [{ type: i0.Input, args: [{ isSignal: true, alias: "accentLine", required: false }] }] } });
|
|
1616
1730
|
|
|
1617
1731
|
/**
|