@salesforce/ui-bundle-template-app-angular-template-b2x 11.60.0 → 11.62.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/CHANGELOG.md +24 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/angular.json +2 -7
- package/dist/force-app/main/default/uiBundles/angularextapp/components.json +6 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/eslint.config.js +9 -1
- package/dist/force-app/main/default/uiBundles/angularextapp/package.json +16 -11
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/app.config.ts +4 -6
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/app.routes.ts +2 -2
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/alert/alert.html +9 -13
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/alert/alert.ts +16 -28
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/button/button.html +19 -10
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/button/button.ts +34 -25
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/card/card.ts +40 -50
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/collapsible/collapsible.html +38 -10
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/collapsible/collapsible.ts +6 -11
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/date-picker/date-picker.html +17 -22
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/date-picker/date-picker.ts +29 -21
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/date-range-picker/date-range-picker.html +16 -30
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/date-range-picker/date-range-picker.ts +39 -36
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/dialog/dialog.html +13 -30
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/dialog/dialog.ts +6 -21
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/dropdown-menu/dropdown-menu.html +20 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/dropdown-menu/dropdown-menu.ts +100 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/field/field.html +5 -11
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/field/field.ts +10 -18
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/field-appearance.ts +8 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/icon/icon.ts +62 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/input/input.html +32 -17
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/input/input.ts +57 -14
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/label/label.ts +8 -4
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/paginator/paginator.html +74 -10
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/paginator/paginator.ts +74 -18
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/paginator/types.ts +13 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/popover/popover.html +10 -38
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/popover/popover.ts +12 -15
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/select/select.html +34 -22
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/select/select.ts +25 -34
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/separator/separator.ts +11 -36
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/skeleton/skeleton.ts +5 -9
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/spinner/spinner.ts +14 -21
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/authentication/auth-form/auth-form.html +2 -3
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/authentication/menu/auth-menu/auth-menu.html +31 -21
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/authentication/menu/auth-menu/auth-menu.ts +6 -18
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/authentication/session/session.html +2 -2
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/authentication/submit-button/submit-button.html +8 -4
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/authentication/submit-button/submit-button.ts +4 -16
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/breadcrumb/breadcrumb.html +4 -24
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/breadcrumb/breadcrumb.ts +3 -16
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/date-filter.ts +1 -1
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/date-range-filter.html +2 -1
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/date-range-filter.ts +6 -15
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/filter-field-wrapper.html +2 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/filter-field-wrapper.ts +2 -17
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/multi-select-filter.html +2 -1
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/numeric-range-filter.ts +3 -21
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/search-filter.html +3 -3
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/search-filter.ts +9 -13
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/select-filter.html +2 -5
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/select-filter.ts +1 -15
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/text-filter.html +2 -5
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/filters/text-filter.ts +3 -17
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/pagination/pagination.ts +4 -20
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/search-bar/search-bar.html +10 -59
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/search-bar/search-bar.ts +13 -93
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/sort-control/sort-control.html +3 -29
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/object-search/sort-control/sort-control.ts +5 -12
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/pages/account-detail/account-detail-page.html +1 -23
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/pages/account-detail/account-detail-page.ts +3 -23
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/pages/account-search/account-search-page.html +1 -19
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/pages/account-search/account-search-page.ts +8 -36
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/pages/home/home.html +15 -4
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/pages/home/home.spec.ts +8 -6
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/pages/home/home.ts +56 -4
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/alert/hlm-alert-action.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/alert/hlm-alert-description.ts +17 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/alert/hlm-alert-title.ts +17 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/alert/hlm-alert.ts +35 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/alert/index.ts +16 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/button/hlm-button.token.ts +22 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/button/hlm-button.ts +72 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/button/index.ts +6 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/calendar/hlm-calendar-multi.ts +195 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/calendar/hlm-calendar-range.ts +194 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/calendar/hlm-calendar.ts +189 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/calendar/hlm-month-year-calendar.ts +119 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/calendar/index.ts +16 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/card/hlm-card-action.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/card/hlm-card-avatar.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/card/hlm-card-content.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/card/hlm-card-description.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/card/hlm-card-footer.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/card/hlm-card-header.ts +15 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/card/hlm-card-title.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/card/hlm-card.token.ts +19 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/card/hlm-card.ts +22 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/card/index.ts +28 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/collapsible/hlm-collapsible-content.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/collapsible/hlm-collapsible-trigger.ts +9 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/collapsible/hlm-collapsible.ts +15 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/collapsible/index.ts +13 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-multi-input.ts +104 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-picker-anchor.ts +23 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-picker-input.ts +118 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-picker-multi.token.ts +109 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-picker-multi.ts +220 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-picker-trigger.ts +104 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-picker.token.ts +69 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-picker.ts +203 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-range-input.ts +120 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-range-picker.token.ts +86 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-date-range-picker.ts +252 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-month-year-input.ts +105 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-month-year-picker.token.ts +89 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/hlm-month-year-picker.ts +196 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/date-picker/index.ts +38 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog-close.ts +9 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog-content.ts +74 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog-description.ts +17 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog-footer.ts +15 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog-header.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog-overlay.ts +27 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog-portal.ts +8 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog-title.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog-trigger.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog.service.ts +46 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/hlm-dialog.ts +24 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dialog/index.ts +35 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-checkbox-indicator.ts +21 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-checkbox.ts +54 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-focus-on-hover.ts +35 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-group.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-item-sub-indicator.ts +19 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-item.ts +42 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-label.ts +20 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-radio-indicator.ts +21 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-radio.ts +49 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-separator.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-shortcut.ts +15 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-sub-trigger.ts +52 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-sub.ts +53 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-token.ts +26 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu-trigger.ts +46 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/hlm-dropdown-menu.ts +57 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/dropdown-menu/index.ts +49 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/hlm-field-content.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/hlm-field-description.ts +53 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/hlm-field-error.ts +100 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/hlm-field-group.ts +15 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/hlm-field-label.ts +17 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/hlm-field-legend.ts +19 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/hlm-field-separator.ts +24 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/hlm-field-set.ts +15 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/hlm-field-title.ts +15 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/hlm-field.ts +47 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/field/index.ts +34 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/input/hlm-input.ts +21 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/input/index.ts +5 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/input-group/hlm-input-group-addon.ts +40 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/input-group/hlm-input-group-button.ts +47 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/input-group/hlm-input-group-input.ts +17 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/input-group/hlm-input-group-text.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/input-group/hlm-input-group.ts +18 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/input-group/index.ts +19 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/label/hlm-label.ts +17 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/label/index.ts +5 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/label/label.html +11 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/pagination/hlm-numbered-pagination-query-params.ts +191 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/pagination/hlm-numbered-pagination.ts +290 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/pagination/hlm-pagination-content.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/pagination/hlm-pagination-ellipsis.ts +27 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/pagination/hlm-pagination-item.ts +7 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/pagination/hlm-pagination-link.ts +51 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/pagination/hlm-pagination-next.ts +65 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/pagination/hlm-pagination-previous.ts +65 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/pagination/hlm-pagination.ts +19 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/pagination/index.ts +31 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/popover/hlm-popover-content.ts +25 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/popover/hlm-popover-description.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/popover/hlm-popover-header.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/popover/hlm-popover-portal.ts +8 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/popover/hlm-popover-title.ts +12 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/popover/hlm-popover-trigger.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/popover/hlm-popover.ts +23 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/popover/index.ts +25 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-content.ts +44 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-group.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-item.ts +36 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-label.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-multiple.ts +37 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-placeholder.ts +17 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-portal.ts +8 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-scroll-down.ts +22 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-scroll-up.ts +22 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-separator.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-trigger.ts +59 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-value-template.ts +5 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-value.ts +18 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-values-content.ts +9 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select-values.ts +5 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/hlm-select.ts +37 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/select/index.ts +52 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/separator/hlm-separator.ts +19 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/separator/index.ts +5 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/skeleton/hlm-skeleton.ts +14 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/skeleton/index.ts +5 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/spinner/hlm-spinner.ts +26 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/spinner/index.ts +5 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/utils/hlm.ts +313 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/utils/index.ts +2 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/shared/utils/provide-spartan-hlm.ts +34 -0
- package/dist/force-app/main/default/uiBundles/angularextapp/src/index.html +0 -1
- package/dist/force-app/main/default/uiBundles/angularextapp/src/{styles.scss → styles.css} +7 -38
- package/dist/force-app/main/default/uiBundles/angularextapp/tsconfig.json +4 -1
- package/dist/package-lock.json +2 -2
- package/dist/package.json +1 -1
- package/package.json +1 -1
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/_field-size.scss +0 -42
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/button/button.scss +0 -112
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/card/card.scss +0 -34
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/date-picker/date-picker.scss +0 -36
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/date-range-picker/date-range-picker.scss +0 -33
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/input/input.scss +0 -35
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/label/label.html +0 -3
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/select/select.scss +0 -35
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/separator/separator.html +0 -1
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/separator/separator.scss +0 -23
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/skeleton/skeleton.html +0 -1
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/skeleton/skeleton.scss +0 -28
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/features/authentication/submit-button/submit-button.scss +0 -17
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/pages/account-detail/account-detail-page.scss +0 -7
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/pages/home/home-page.html +0 -18
- package/dist/force-app/main/default/uiBundles/angularextapp/src/app/pages/home/home-page.ts +0 -47
- package/dist/force-app/main/default/uiBundles/angularextapp/src/theme.scss +0 -39
|
@@ -1,25 +1,20 @@
|
|
|
1
|
-
<
|
|
2
|
-
class="w-full"
|
|
3
|
-
[class]="'size-' + size()"
|
|
4
|
-
[appearance]="appearance()"
|
|
5
|
-
subscriptSizing="dynamic"
|
|
6
|
-
>
|
|
1
|
+
<div class="w-full" [ngClass]="wrapperClasses()">
|
|
7
2
|
@if (label()) {
|
|
8
|
-
<
|
|
3
|
+
<label [for]="labelId" class="text-sm leading-none font-medium select-none mb-1.5 block">
|
|
4
|
+
{{ label() }}
|
|
5
|
+
</label>
|
|
9
6
|
}
|
|
10
|
-
<
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
[min]="min()"
|
|
14
|
-
[max]="max()"
|
|
15
|
-
[placeholder]="placeholder()"
|
|
7
|
+
<hlm-date-picker
|
|
8
|
+
[date]="value() ?? undefined"
|
|
9
|
+
(dateChange)="value.set($event)"
|
|
16
10
|
[disabled]="disabled()"
|
|
17
|
-
[
|
|
18
|
-
[
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
</
|
|
11
|
+
[minDate]="min()"
|
|
12
|
+
[maxDate]="max()"
|
|
13
|
+
>
|
|
14
|
+
<hlm-date-picker-input
|
|
15
|
+
[inputId]="labelId"
|
|
16
|
+
[placeholder]="placeholder()"
|
|
17
|
+
[readonly]="readonly()"
|
|
18
|
+
/>
|
|
19
|
+
</hlm-date-picker>
|
|
20
|
+
</div>
|
|
@@ -3,39 +3,47 @@
|
|
|
3
3
|
* All rights reserved.
|
|
4
4
|
* For full license text, see the LICENSE.txt file
|
|
5
5
|
*/
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
6
|
+
import {
|
|
7
|
+
ChangeDetectionStrategy,
|
|
8
|
+
Component,
|
|
9
|
+
booleanAttribute,
|
|
10
|
+
computed,
|
|
11
|
+
input,
|
|
12
|
+
model,
|
|
13
|
+
} from '@angular/core';
|
|
14
|
+
import { NgClass } from '@angular/common';
|
|
15
|
+
import { HlmDatePickerImports } from '@spartan-ng/styles/date-picker';
|
|
11
16
|
import type { AppFieldSize } from '../field-size';
|
|
12
17
|
|
|
13
|
-
/**
|
|
14
|
-
* Thin wrapper over Material's `mat-form-field` + `matInput` + `mat-datepicker`.
|
|
15
|
-
* Relies on `provideNativeDateAdapter()`, so `value` is a plain `Date`.
|
|
16
|
-
*/
|
|
17
18
|
@Component({
|
|
18
19
|
selector: 'app-date-picker',
|
|
19
20
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
20
|
-
imports: [
|
|
21
|
+
imports: [HlmDatePickerImports, NgClass],
|
|
22
|
+
host: { class: 'block min-w-0' },
|
|
21
23
|
templateUrl: './date-picker.html',
|
|
22
|
-
styleUrl: './date-picker.scss',
|
|
23
24
|
})
|
|
24
25
|
export class DatePickerComponent {
|
|
25
|
-
|
|
26
|
-
readonly value = model<Date | null>(null);
|
|
27
|
-
|
|
26
|
+
readonly value = model<Date | null | undefined>(undefined);
|
|
28
27
|
readonly label = input<string>('');
|
|
29
28
|
readonly placeholder = input<string>('');
|
|
30
|
-
readonly disabled = input
|
|
31
|
-
readonly
|
|
32
|
-
/** Field height: `sm` = 24px, `default` = 32px, `lg` = 40px. */
|
|
29
|
+
readonly disabled = input(false, { transform: booleanAttribute });
|
|
30
|
+
readonly readonly = input(false, { transform: booleanAttribute });
|
|
33
31
|
readonly size = input<AppFieldSize>('default');
|
|
34
|
-
|
|
35
|
-
/** Earliest / latest selectable date; `null` leaves that bound open. */
|
|
36
32
|
readonly min = input<Date | null>(null);
|
|
37
33
|
readonly max = input<Date | null>(null);
|
|
38
34
|
|
|
39
|
-
|
|
40
|
-
|
|
35
|
+
private static _uid = 0;
|
|
36
|
+
protected readonly labelId = `app-date-picker-${DatePickerComponent._uid++}`;
|
|
37
|
+
|
|
38
|
+
protected readonly wrapperClasses = computed(() => {
|
|
39
|
+
const cls: string[] = [];
|
|
40
|
+
const s = this.size();
|
|
41
|
+
if (s === 'sm')
|
|
42
|
+
cls.push('[&_[data-slot=input-group]]:h-6', '[&_[data-slot=input-group]]:text-xs');
|
|
43
|
+
if (s === 'lg')
|
|
44
|
+
cls.push('[&_[data-slot=input-group]]:h-10', '[&_[data-slot=input-group]]:text-lg');
|
|
45
|
+
return cls;
|
|
46
|
+
});
|
|
41
47
|
}
|
|
48
|
+
|
|
49
|
+
export const DatePickerImports = [DatePickerComponent] as const;
|
|
@@ -1,34 +1,20 @@
|
|
|
1
|
-
<
|
|
2
|
-
class="w-full"
|
|
3
|
-
[class]="'size-' + size()"
|
|
4
|
-
[appearance]="appearance()"
|
|
5
|
-
subscriptSizing="dynamic"
|
|
6
|
-
>
|
|
1
|
+
<div class="w-full" [ngClass]="wrapperClasses()">
|
|
7
2
|
@if (label()) {
|
|
8
|
-
<
|
|
3
|
+
<label [for]="labelId" class="text-sm leading-none font-medium select-none mb-1.5 block">
|
|
4
|
+
{{ label() }}
|
|
5
|
+
</label>
|
|
9
6
|
}
|
|
10
|
-
<
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
7
|
+
<hlm-date-range-picker
|
|
8
|
+
[date]="dateRange()"
|
|
9
|
+
(dateChange)="onRangeChange($event)"
|
|
10
|
+
[disabled]="disabled()"
|
|
11
|
+
[minDate]="min()"
|
|
12
|
+
[maxDate]="max()"
|
|
13
|
+
>
|
|
14
|
+
<hlm-date-range-input
|
|
15
|
+
[inputId]="labelId"
|
|
16
|
+
[placeholder]="startPlaceholder() + ' — ' + endPlaceholder()"
|
|
15
17
|
[readonly]="readonly()"
|
|
16
|
-
(dateChange)="onStartChange($event.value)"
|
|
17
|
-
(click)="readonly() && picker.open()"
|
|
18
|
-
(keydown.enter)="readonly() && picker.open()"
|
|
19
|
-
(keydown.space)="readonly() && picker.open()"
|
|
20
18
|
/>
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
[placeholder]="endPlaceholder()"
|
|
24
|
-
[value]="value()?.end ?? null"
|
|
25
|
-
[readonly]="readonly()"
|
|
26
|
-
(dateChange)="onEndChange($event.value)"
|
|
27
|
-
(click)="readonly() && picker.open()"
|
|
28
|
-
(keydown.enter)="readonly() && picker.open()"
|
|
29
|
-
(keydown.space)="readonly() && picker.open()"
|
|
30
|
-
/>
|
|
31
|
-
</mat-date-range-input>
|
|
32
|
-
<mat-datepicker-toggle matIconSuffix [for]="picker" />
|
|
33
|
-
<mat-date-range-picker #picker />
|
|
34
|
-
</mat-form-field>
|
|
19
|
+
</hlm-date-range-picker>
|
|
20
|
+
</div>
|
|
@@ -3,64 +3,67 @@
|
|
|
3
3
|
* All rights reserved.
|
|
4
4
|
* For full license text, see the LICENSE.txt file
|
|
5
5
|
*/
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
6
|
+
import {
|
|
7
|
+
ChangeDetectionStrategy,
|
|
8
|
+
Component,
|
|
9
|
+
booleanAttribute,
|
|
10
|
+
computed,
|
|
11
|
+
input,
|
|
12
|
+
model,
|
|
13
|
+
} from '@angular/core';
|
|
14
|
+
import { NgClass } from '@angular/common';
|
|
15
|
+
import { HlmDatePickerImports } from '@spartan-ng/styles/date-picker';
|
|
11
16
|
import type { AppFieldSize } from '../field-size';
|
|
12
17
|
|
|
13
|
-
export
|
|
18
|
+
export interface DateRange<D> {
|
|
19
|
+
start: D | null;
|
|
20
|
+
end: D | null;
|
|
21
|
+
}
|
|
14
22
|
|
|
15
|
-
/**
|
|
16
|
-
* Thin wrapper over Material's `mat-form-field` + `mat-date-range-input` +
|
|
17
|
-
* `mat-date-range-picker`. Relies on `provideNativeDateAdapter()`, so the value
|
|
18
|
-
* is Material's `DateRange<Date>` (`{ start, end }`) of plain `Date`s.
|
|
19
|
-
*/
|
|
20
23
|
@Component({
|
|
21
24
|
selector: 'app-date-range-picker',
|
|
22
25
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
23
|
-
imports: [
|
|
26
|
+
imports: [HlmDatePickerImports, NgClass],
|
|
27
|
+
host: { class: 'block min-w-0' },
|
|
24
28
|
templateUrl: './date-range-picker.html',
|
|
25
|
-
styleUrl: './date-range-picker.scss',
|
|
26
29
|
})
|
|
27
30
|
export class DateRangePickerComponent {
|
|
28
|
-
/** Two-way bindable range value. `null` clears the field. Supports `[(value)]`. */
|
|
29
31
|
readonly value = model<DateRange<Date> | null>(null);
|
|
30
|
-
|
|
31
32
|
readonly label = input<string>('');
|
|
32
33
|
readonly startPlaceholder = input<string>('Start');
|
|
33
34
|
readonly endPlaceholder = input<string>('End');
|
|
34
|
-
readonly disabled = input
|
|
35
|
-
readonly
|
|
36
|
-
/** Field height: `sm` = 24px, `default` = 32px, `lg` = 40px. */
|
|
35
|
+
readonly disabled = input(false, { transform: booleanAttribute });
|
|
36
|
+
readonly readonly = input(false, { transform: booleanAttribute });
|
|
37
37
|
readonly size = input<AppFieldSize>('default');
|
|
38
|
-
|
|
39
|
-
/** Earliest / latest selectable date; `null` leaves that bound open. */
|
|
40
38
|
readonly min = input<Date | null>(null);
|
|
41
39
|
readonly max = input<Date | null>(null);
|
|
42
40
|
|
|
43
|
-
|
|
44
|
-
|
|
41
|
+
private static _uid = 0;
|
|
42
|
+
protected readonly labelId = `app-date-range-picker-${DateRangePickerComponent._uid++}`;
|
|
45
43
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
44
|
+
protected readonly wrapperClasses = computed(() => {
|
|
45
|
+
const cls: string[] = [];
|
|
46
|
+
const s = this.size();
|
|
47
|
+
if (s === 'sm')
|
|
48
|
+
cls.push('[&_[data-slot=input-group]]:h-6', '[&_[data-slot=input-group]]:text-xs');
|
|
49
|
+
if (s === 'lg')
|
|
50
|
+
cls.push('[&_[data-slot=input-group]]:h-10', '[&_[data-slot=input-group]]:text-lg');
|
|
51
|
+
return cls;
|
|
52
|
+
});
|
|
50
53
|
|
|
51
|
-
protected
|
|
52
|
-
this.
|
|
54
|
+
protected dateRange(): [Date, Date] | undefined {
|
|
55
|
+
const v = this.value();
|
|
56
|
+
if (v?.start && v?.end) return [v.start, v.end];
|
|
57
|
+
return undefined;
|
|
53
58
|
}
|
|
54
59
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
*/
|
|
59
|
-
private setRange(start: Date | null, end: Date | null): void {
|
|
60
|
-
if (start && end && start.getTime() > end.getTime()) {
|
|
61
|
-
this.value.set(new DateRange(end, start));
|
|
60
|
+
protected onRangeChange(range: [Date | null, Date | null] | null): void {
|
|
61
|
+
if (!range) {
|
|
62
|
+
this.value.set(null);
|
|
62
63
|
return;
|
|
63
64
|
}
|
|
64
|
-
this.value.set(
|
|
65
|
+
this.value.set({ start: range[0], end: range[1] });
|
|
65
66
|
}
|
|
66
67
|
}
|
|
68
|
+
|
|
69
|
+
export const DateRangePickerImports = [DateRangePickerComponent] as const;
|
package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/dialog/dialog.html
CHANGED
|
@@ -1,37 +1,20 @@
|
|
|
1
|
-
<
|
|
2
|
-
|
|
3
|
-
[
|
|
4
|
-
[
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
{
|
|
8
|
-
originX: 'center',
|
|
9
|
-
originY: 'center',
|
|
10
|
-
overlayX: 'center',
|
|
11
|
-
overlayY: 'center',
|
|
12
|
-
},
|
|
13
|
-
]"
|
|
14
|
-
(backdropClick)="onBackdropClick()"
|
|
15
|
-
(overlayKeydown)="$event.key === 'Escape' && close()"
|
|
16
|
-
(detach)="close()"
|
|
1
|
+
<hlm-dialog
|
|
2
|
+
[state]="open() ? 'open' : 'closed'"
|
|
3
|
+
[disableClose]="!closeOnBackdrop()"
|
|
4
|
+
[aria-label]="ariaLabel()"
|
|
5
|
+
[aria-labelledby]="ariaLabelledby()"
|
|
6
|
+
(stateChanged)="onStateChanged($event)"
|
|
17
7
|
>
|
|
18
|
-
<
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
[attr.aria-label]="ariaLabel()"
|
|
22
|
-
[attr.aria-labelledby]="ariaLabelledby()"
|
|
23
|
-
cdkTrapFocus
|
|
24
|
-
[cdkTrapFocusAutoCapture]="true"
|
|
25
|
-
class="bg-card text-card-foreground flex w-full max-w-md flex-col gap-4 rounded-xl p-6 shadow-lg ring-1 ring-black/10 outline-none"
|
|
26
|
-
>
|
|
27
|
-
<div data-slot="dialog-header" class="flex flex-col gap-1">
|
|
8
|
+
<button hlmDialogTrigger type="button" class="hidden" aria-label="Open dialog"></button>
|
|
9
|
+
<hlm-dialog-content *hlmDialogPortal>
|
|
10
|
+
<div hlmDialogHeader>
|
|
28
11
|
<ng-content select="[header]" />
|
|
29
12
|
</div>
|
|
30
|
-
<div
|
|
13
|
+
<div class="text-sm">
|
|
31
14
|
<ng-content />
|
|
32
15
|
</div>
|
|
33
|
-
<div
|
|
16
|
+
<div hlmDialogFooter>
|
|
34
17
|
<ng-content select="[footer]" />
|
|
35
18
|
</div>
|
|
36
|
-
</
|
|
37
|
-
</
|
|
19
|
+
</hlm-dialog-content>
|
|
20
|
+
</hlm-dialog>
|
package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/dialog/dialog.ts
CHANGED
|
@@ -3,43 +3,26 @@
|
|
|
3
3
|
* All rights reserved.
|
|
4
4
|
* For full license text, see the LICENSE.txt file
|
|
5
5
|
*/
|
|
6
|
-
import { CdkTrapFocus } from '@angular/cdk/a11y';
|
|
7
|
-
import { CdkConnectedOverlay } from '@angular/cdk/overlay';
|
|
8
6
|
import { ChangeDetectionStrategy, Component, input, model, output } from '@angular/core';
|
|
7
|
+
import { HlmDialogImports } from '@spartan-ng/styles/dialog';
|
|
9
8
|
|
|
10
|
-
/**
|
|
11
|
-
* Modal dialog backed by CDK Overlay. Slots: `[header]`, default (body),
|
|
12
|
-
* `[footer]`. `open` is a two-way model; a backdrop click or Escape closes it
|
|
13
|
-
* and emits `(closed)`. `cdkTrapFocus` keeps focus inside the panel while open.
|
|
14
|
-
*/
|
|
15
9
|
@Component({
|
|
16
10
|
selector: 'app-dialog',
|
|
17
11
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
18
|
-
imports: [
|
|
12
|
+
imports: [HlmDialogImports],
|
|
19
13
|
templateUrl: './dialog.html',
|
|
20
14
|
})
|
|
21
15
|
export class DialogComponent {
|
|
22
|
-
/** Two-way bindable open state. Supports `[(open)]`. */
|
|
23
16
|
readonly open = model<boolean>(false);
|
|
24
|
-
|
|
25
|
-
/** When true a backdrop click closes the dialog. */
|
|
26
17
|
readonly closeOnBackdrop = input<boolean>(true);
|
|
27
|
-
|
|
28
|
-
/** Accessible name for the dialog (or use `ariaLabelledby`). */
|
|
29
18
|
readonly ariaLabel = input<string | null>(null, { alias: 'aria-label' });
|
|
30
|
-
|
|
31
|
-
/** `id` of an element (e.g. the projected header) that names the dialog. */
|
|
32
19
|
readonly ariaLabelledby = input<string | null>(null, { alias: 'aria-labelledby' });
|
|
33
|
-
|
|
34
|
-
/** Emitted whenever the dialog transitions to closed. */
|
|
35
20
|
readonly closed = output<void>();
|
|
36
21
|
|
|
37
|
-
/** Imperatively open the dialog. */
|
|
38
22
|
show(): void {
|
|
39
23
|
this.open.set(true);
|
|
40
24
|
}
|
|
41
25
|
|
|
42
|
-
/** Imperatively close the dialog and notify listeners. */
|
|
43
26
|
close(): void {
|
|
44
27
|
if (this.open()) {
|
|
45
28
|
this.open.set(false);
|
|
@@ -47,9 +30,11 @@ export class DialogComponent {
|
|
|
47
30
|
}
|
|
48
31
|
}
|
|
49
32
|
|
|
50
|
-
protected
|
|
51
|
-
if (this.
|
|
33
|
+
protected onStateChanged(state: 'open' | 'closed'): void {
|
|
34
|
+
if (state === 'closed' && this.open()) {
|
|
52
35
|
this.close();
|
|
53
36
|
}
|
|
54
37
|
}
|
|
55
38
|
}
|
|
39
|
+
|
|
40
|
+
export const DialogImports = [DialogComponent] as const;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
<button
|
|
2
|
+
[hlmDropdownMenuTrigger]="menuTpl"
|
|
3
|
+
[align]="align()"
|
|
4
|
+
[side]="side()"
|
|
5
|
+
type="button"
|
|
6
|
+
[class]="triggerClass()"
|
|
7
|
+
[attr.aria-label]="ariaLabel()"
|
|
8
|
+
>
|
|
9
|
+
<ng-content select="[trigger]" />
|
|
10
|
+
</button>
|
|
11
|
+
<ng-template #menuTpl>
|
|
12
|
+
<div
|
|
13
|
+
hlmDropdownMenu
|
|
14
|
+
appDropdownMenuInjector
|
|
15
|
+
#menuInjector="appDropdownMenuInjector"
|
|
16
|
+
[sideOffset]="sideOffset()"
|
|
17
|
+
>
|
|
18
|
+
<ng-container *ngTemplateOutlet="content().templateRef; injector: menuInjector.injector" />
|
|
19
|
+
</div>
|
|
20
|
+
</ng-template>
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2026, Salesforce, Inc.,
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
* For full license text, see the LICENSE.txt file
|
|
5
|
+
*/
|
|
6
|
+
import { CdkMenuItem } from '@angular/cdk/menu';
|
|
7
|
+
import { NgTemplateOutlet } from '@angular/common';
|
|
8
|
+
import {
|
|
9
|
+
ChangeDetectionStrategy,
|
|
10
|
+
Component,
|
|
11
|
+
Directive,
|
|
12
|
+
inject,
|
|
13
|
+
Injector,
|
|
14
|
+
input,
|
|
15
|
+
TemplateRef,
|
|
16
|
+
contentChild,
|
|
17
|
+
} from '@angular/core';
|
|
18
|
+
import { outputFromObservable } from '@angular/core/rxjs-interop';
|
|
19
|
+
import type { MenuAlign, MenuSide } from '@spartan-ng/brain/core';
|
|
20
|
+
import {
|
|
21
|
+
HlmDropdownMenu,
|
|
22
|
+
HlmDropdownMenuItem,
|
|
23
|
+
HlmDropdownMenuLabel,
|
|
24
|
+
HlmDropdownMenuSeparator,
|
|
25
|
+
HlmDropdownMenuTrigger,
|
|
26
|
+
} from '@spartan-ng/styles/dropdown-menu';
|
|
27
|
+
|
|
28
|
+
// `appDropdownMenuItem` must be a directive (not a component) so it can be applied
|
|
29
|
+
// directly to the feature's own `<a>`/`<button>`, preserving native ENTER→click for
|
|
30
|
+
// `routerLink` and keyboard nav.
|
|
31
|
+
// Marker for the projected menu body. Consumers declare their items inside
|
|
32
|
+
// `<ng-template appDropdownMenuContent>` so the template can be rendered *inside*
|
|
33
|
+
// the `hlmDropdownMenu` (CdkMenu) with that element's injector — otherwise the
|
|
34
|
+
// items resolve DI at their declaration site and can't find `cdk-menu-stack`.
|
|
35
|
+
@Directive({ selector: '[appDropdownMenuContent]' })
|
|
36
|
+
export class DropdownMenuContentDirective {
|
|
37
|
+
readonly templateRef = inject<TemplateRef<unknown>>(TemplateRef);
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
// Captures the node injector of the `hlmDropdownMenu` element (which carries the
|
|
41
|
+
// `cdk-menu-stack` provider) so the projected content can inherit it.
|
|
42
|
+
@Directive({ selector: '[appDropdownMenuInjector]', exportAs: 'appDropdownMenuInjector' })
|
|
43
|
+
export class DropdownMenuInjectorDirective {
|
|
44
|
+
readonly injector = inject(Injector);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
@Component({
|
|
48
|
+
selector: 'app-dropdown-menu',
|
|
49
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
50
|
+
imports: [
|
|
51
|
+
HlmDropdownMenuTrigger,
|
|
52
|
+
HlmDropdownMenu,
|
|
53
|
+
NgTemplateOutlet,
|
|
54
|
+
DropdownMenuInjectorDirective,
|
|
55
|
+
],
|
|
56
|
+
templateUrl: './dropdown-menu.html',
|
|
57
|
+
})
|
|
58
|
+
export class DropdownMenuComponent {
|
|
59
|
+
readonly align = input<MenuAlign>('start');
|
|
60
|
+
readonly side = input<MenuSide>('bottom');
|
|
61
|
+
readonly sideOffset = input<number>(1);
|
|
62
|
+
readonly triggerClass = input<string>('');
|
|
63
|
+
readonly ariaLabel = input<string | null>(null, { alias: 'aria-label' });
|
|
64
|
+
|
|
65
|
+
protected readonly content = contentChild.required(DropdownMenuContentDirective);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
@Directive({
|
|
69
|
+
selector: 'a[appDropdownMenuItem], button[appDropdownMenuItem]',
|
|
70
|
+
hostDirectives: [{ directive: HlmDropdownMenuItem, inputs: ['disabled', 'variant', 'inset'] }],
|
|
71
|
+
})
|
|
72
|
+
export class DropdownMenuItemDirective {
|
|
73
|
+
// outputFromObservable workaround: a parent hostDirective can't re-export a host
|
|
74
|
+
// directive's output directly (raises NG2017), so bridge it via CdkMenuItem's observable.
|
|
75
|
+
readonly triggered = outputFromObservable(inject(CdkMenuItem).triggered);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
@Component({
|
|
79
|
+
selector: 'app-dropdown-menu-label',
|
|
80
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
81
|
+
hostDirectives: [{ directive: HlmDropdownMenuLabel, inputs: ['inset'] }],
|
|
82
|
+
template: '<ng-content />',
|
|
83
|
+
})
|
|
84
|
+
export class DropdownMenuLabelComponent {}
|
|
85
|
+
|
|
86
|
+
@Component({
|
|
87
|
+
selector: 'app-dropdown-menu-separator',
|
|
88
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
89
|
+
hostDirectives: [HlmDropdownMenuSeparator],
|
|
90
|
+
template: '',
|
|
91
|
+
})
|
|
92
|
+
export class DropdownMenuSeparatorComponent {}
|
|
93
|
+
|
|
94
|
+
export const DropdownMenuImports = [
|
|
95
|
+
DropdownMenuComponent,
|
|
96
|
+
DropdownMenuContentDirective,
|
|
97
|
+
DropdownMenuItemDirective,
|
|
98
|
+
DropdownMenuLabelComponent,
|
|
99
|
+
DropdownMenuSeparatorComponent,
|
|
100
|
+
] as const;
|
package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/field/field.html
CHANGED
|
@@ -1,21 +1,15 @@
|
|
|
1
1
|
@if (label()) {
|
|
2
|
-
<label [
|
|
2
|
+
<label hlmFieldLabel [for]="htmlFor() ?? undefined">
|
|
3
3
|
{{ label() }}
|
|
4
4
|
@if (required()) {
|
|
5
5
|
<span aria-hidden="true" class="text-destructive">*</span>
|
|
6
6
|
}
|
|
7
7
|
</label>
|
|
8
8
|
}
|
|
9
|
-
|
|
9
|
+
@if (description()) {
|
|
10
|
+
<p hlmFieldDescription>{{ description() }}</p>
|
|
11
|
+
}
|
|
10
12
|
<ng-content />
|
|
11
|
-
|
|
12
13
|
@if (error()) {
|
|
13
|
-
<
|
|
14
|
-
[id]="htmlFor() ? htmlFor() + '-error' : null"
|
|
15
|
-
data-slot="field-error"
|
|
16
|
-
role="alert"
|
|
17
|
-
class="text-destructive text-sm"
|
|
18
|
-
>
|
|
19
|
-
{{ error() }}
|
|
20
|
-
</p>
|
|
14
|
+
<hlm-field-error [forceShow]="true">{{ error() }}</hlm-field-error>
|
|
21
15
|
}
|
package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/field/field.ts
CHANGED
|
@@ -3,34 +3,26 @@
|
|
|
3
3
|
* All rights reserved.
|
|
4
4
|
* For full license text, see the LICENSE.txt file
|
|
5
5
|
*/
|
|
6
|
-
import { ChangeDetectionStrategy, Component, input } from '@angular/core';
|
|
6
|
+
import { booleanAttribute, ChangeDetectionStrategy, Component, input } from '@angular/core';
|
|
7
|
+
import { HlmField, HlmFieldImports } from '@spartan-ng/styles/field';
|
|
7
8
|
|
|
8
|
-
/**
|
|
9
|
-
* Form-field wrapper: renders a `<label>`, the projected control, and an error
|
|
10
|
-
* message when present. Composes around `app-input` and other controls.
|
|
11
|
-
*/
|
|
12
9
|
@Component({
|
|
13
10
|
selector: 'app-field',
|
|
14
11
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
15
|
-
|
|
12
|
+
imports: [HlmFieldImports],
|
|
13
|
+
hostDirectives: [HlmField],
|
|
16
14
|
host: {
|
|
17
15
|
'data-slot': 'field',
|
|
18
|
-
|
|
16
|
+
'[attr.data-invalid]': 'error() ? true : null',
|
|
19
17
|
},
|
|
18
|
+
templateUrl: './field.html',
|
|
20
19
|
})
|
|
21
20
|
export class FieldComponent {
|
|
22
|
-
/** Optional label text rendered above the control. */
|
|
23
21
|
readonly label = input<string>('');
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* Error message; renders in a `role="alert"` region. When `htmlFor` is set
|
|
27
|
-
* the region gets id `<htmlFor>-error` for the control's `aria-describedby`.
|
|
28
|
-
*/
|
|
22
|
+
readonly description = input<string>('');
|
|
29
23
|
readonly error = input<string | null>(null);
|
|
30
|
-
|
|
31
|
-
/** Marks the field required and renders an asterisk next to the label. */
|
|
32
|
-
readonly required = input<boolean>(false);
|
|
33
|
-
|
|
34
|
-
/** `id` of the projected control; forwarded to the label's `for`. */
|
|
24
|
+
readonly required = input(false, { transform: booleanAttribute });
|
|
35
25
|
readonly htmlFor = input<string | null>(null);
|
|
36
26
|
}
|
|
27
|
+
|
|
28
|
+
export const FieldImports = [FieldComponent] as const;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2026, Salesforce, Inc.,
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
* For full license text, see the LICENSE.txt file
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
/** Form-field visual treatment: `outline` = bordered (default), `fill` = borderless muted background. */
|
|
8
|
+
export type AppFieldAppearance = 'outline' | 'fill';
|
package/dist/force-app/main/default/uiBundles/angularextapp/src/app/components/ui/icon/icon.ts
ADDED
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2026, Salesforce, Inc.,
|
|
3
|
+
* All rights reserved.
|
|
4
|
+
* For full license text, see the LICENSE.txt file
|
|
5
|
+
*/
|
|
6
|
+
import { ChangeDetectionStrategy, Component, input } from '@angular/core';
|
|
7
|
+
import { NgIcon, provideIcons } from '@ng-icons/core';
|
|
8
|
+
import {
|
|
9
|
+
lucideArrowDown,
|
|
10
|
+
lucideArrowUp,
|
|
11
|
+
lucideChevronRight,
|
|
12
|
+
lucideCircleAlert,
|
|
13
|
+
lucideFileQuestion,
|
|
14
|
+
lucideListFilter,
|
|
15
|
+
lucideLogIn,
|
|
16
|
+
lucideLogOut,
|
|
17
|
+
lucideSearch,
|
|
18
|
+
lucideSearchX,
|
|
19
|
+
lucideUser,
|
|
20
|
+
lucideUserPen,
|
|
21
|
+
lucideUserPlus,
|
|
22
|
+
lucideX,
|
|
23
|
+
} from '@ng-icons/lucide';
|
|
24
|
+
|
|
25
|
+
export const APP_ICONS = {
|
|
26
|
+
error: lucideCircleAlert,
|
|
27
|
+
close: lucideX,
|
|
28
|
+
person: lucideUser,
|
|
29
|
+
login: lucideLogIn,
|
|
30
|
+
logout: lucideLogOut,
|
|
31
|
+
editProfile: lucideUserPen,
|
|
32
|
+
personAdd: lucideUserPlus,
|
|
33
|
+
search: lucideSearch,
|
|
34
|
+
filter: lucideListFilter,
|
|
35
|
+
chevronRight: lucideChevronRight,
|
|
36
|
+
arrowUp: lucideArrowUp,
|
|
37
|
+
arrowDown: lucideArrowDown,
|
|
38
|
+
noResults: lucideSearchX,
|
|
39
|
+
notFound: lucideFileQuestion,
|
|
40
|
+
} as const;
|
|
41
|
+
|
|
42
|
+
export type AppIconName = keyof typeof APP_ICONS;
|
|
43
|
+
|
|
44
|
+
@Component({
|
|
45
|
+
selector: 'app-icon',
|
|
46
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
47
|
+
imports: [NgIcon],
|
|
48
|
+
providers: [provideIcons(APP_ICONS)],
|
|
49
|
+
host: {
|
|
50
|
+
'[class]': 'classes()',
|
|
51
|
+
'[attr.aria-label]': 'ariaLabel()',
|
|
52
|
+
'[attr.aria-hidden]': 'ariaLabel() ? null : true',
|
|
53
|
+
},
|
|
54
|
+
template: '<ng-icon [name]="name()" [size]="size()" />',
|
|
55
|
+
})
|
|
56
|
+
export class IconComponent {
|
|
57
|
+
readonly name = input.required<AppIconName>();
|
|
58
|
+
readonly size = input<string>('1rem');
|
|
59
|
+
readonly ariaLabel = input<string | null>(null, { alias: 'aria-label' });
|
|
60
|
+
// Non-size utilities (color, margin) still pass through to the host.
|
|
61
|
+
readonly classes = input<string>('', { alias: 'class' });
|
|
62
|
+
}
|