@lucca-front/ng 22.0.0-rc.5 → 22.0.0
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/lucca-front-ng-a11y.mjs +10 -10
- package/fesm2022/lucca-front-ng-a11y.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-activity-feed.mjs +14 -14
- package/fesm2022/lucca-front-ng-activity-feed.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-api.mjs +44 -42
- package/fesm2022/lucca-front-ng-api.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-app-layout.mjs +7 -6
- package/fesm2022/lucca-front-ng-app-layout.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-approbation-inbox.mjs +517 -0
- package/fesm2022/lucca-front-ng-approbation-inbox.mjs.map +1 -0
- package/fesm2022/lucca-front-ng-box.mjs +12 -12
- package/fesm2022/lucca-front-ng-box.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-breadcrumbs.mjs +9 -9
- package/fesm2022/lucca-front-ng-breadcrumbs.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-bubble-icon.mjs +4 -4
- package/fesm2022/lucca-front-ng-bubble-icon.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-bubble-illustration.mjs +7 -6
- package/fesm2022/lucca-front-ng-bubble-illustration.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-callout.mjs +38 -38
- package/fesm2022/lucca-front-ng-callout.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-chip.mjs +10 -10
- package/fesm2022/lucca-front-ng-chip.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-clear.mjs +7 -7
- package/fesm2022/lucca-front-ng-clear.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-code.mjs +6 -5
- package/fesm2022/lucca-front-ng-code.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-color.mjs +7 -6
- package/fesm2022/lucca-front-ng-color.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-comment.mjs +18 -17
- package/fesm2022/lucca-front-ng-comment.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-container.mjs +8 -7
- package/fesm2022/lucca-front-ng-container.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-core-select-api.mjs +17 -40
- package/fesm2022/lucca-front-ng-core-select-api.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-core-select-department.mjs +18 -20
- package/fesm2022/lucca-front-ng-core-select-department.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-core-select-establishment.mjs +28 -16
- package/fesm2022/lucca-front-ng-core-select-establishment.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-core-select-job-qualification.mjs +19 -9
- package/fesm2022/lucca-front-ng-core-select-job-qualification.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-core-select-legal-units.mjs +34 -21
- package/fesm2022/lucca-front-ng-core-select-legal-units.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-core-select-occupation-category.mjs +16 -6
- package/fesm2022/lucca-front-ng-core-select-occupation-category.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-core-select-user.mjs +41 -36
- package/fesm2022/lucca-front-ng-core-select-user.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-core-select.mjs +204 -118
- package/fesm2022/lucca-front-ng-core-select.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-core.mjs +113 -38
- package/fesm2022/lucca-front-ng-core.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-data-table.mjs +50 -50
- package/fesm2022/lucca-front-ng-data-table.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-date.mjs +44 -44
- package/fesm2022/lucca-front-ng-date.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-date2.mjs +50 -48
- package/fesm2022/lucca-front-ng-date2.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-department.mjs +28 -27
- package/fesm2022/lucca-front-ng-department.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-dialog.mjs +87 -60
- package/fesm2022/lucca-front-ng-dialog.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-divider.mjs +9 -9
- package/fesm2022/lucca-front-ng-divider.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-dropdown.mjs +46 -46
- package/fesm2022/lucca-front-ng-dropdown.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-empty-state.mjs +56 -31
- package/fesm2022/lucca-front-ng-empty-state.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-error-page.mjs +4 -4
- package/fesm2022/lucca-front-ng-error-page.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-establishment.mjs +38 -37
- package/fesm2022/lucca-front-ng-establishment.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-fancy-box.mjs +4 -4
- package/fesm2022/lucca-front-ng-fancy-box.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-file-upload.mjs +86 -48
- package/fesm2022/lucca-front-ng-file-upload.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-filter-pills.mjs +150 -27
- package/fesm2022/lucca-front-ng-filter-pills.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-footer.mjs +10 -9
- package/fesm2022/lucca-front-ng-footer.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-form-field.mjs +35 -36
- package/fesm2022/lucca-front-ng-form-field.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-form-header.mjs +5 -5
- package/fesm2022/lucca-front-ng-form-header.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-form-label.mjs +19 -52
- package/fesm2022/lucca-front-ng-form-label.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-form.mjs +9 -8
- package/fesm2022/lucca-front-ng-form.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-formly.mjs +64 -64
- package/fesm2022/lucca-front-ng-formly.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-forms-phone-number-input.mjs +8 -8
- package/fesm2022/lucca-front-ng-forms-phone-number-input.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-forms-rich-text-input-formatters-html.mjs +3 -3
- package/fesm2022/lucca-front-ng-forms-rich-text-input-formatters-markdown.mjs +6 -6
- package/fesm2022/lucca-front-ng-forms-rich-text-input-formatters-plain-text.mjs +3 -3
- package/fesm2022/lucca-front-ng-forms-rich-text-input.mjs +72 -58
- package/fesm2022/lucca-front-ng-forms-rich-text-input.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-forms.mjs +129 -114
- package/fesm2022/lucca-front-ng-forms.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-gauge.mjs +11 -11
- package/fesm2022/lucca-front-ng-gauge.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-grid.mjs +18 -17
- package/fesm2022/lucca-front-ng-grid.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-highlight-data.mjs +11 -18
- package/fesm2022/lucca-front-ng-highlight-data.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-highlight-section.mjs +85 -0
- package/fesm2022/lucca-front-ng-highlight-section.mjs.map +1 -0
- package/fesm2022/lucca-front-ng-highlight-text.mjs +3 -3
- package/fesm2022/lucca-front-ng-horizontal-navigation.mjs +17 -17
- package/fesm2022/lucca-front-ng-horizontal-navigation.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-impersonation.mjs +7 -7
- package/fesm2022/lucca-front-ng-impersonation.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-index-table.mjs +50 -50
- package/fesm2022/lucca-front-ng-index-table.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-inline-message.mjs +6 -6
- package/fesm2022/lucca-front-ng-inline-message.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-input.mjs +22 -22
- package/fesm2022/lucca-front-ng-input.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-link.mjs +24 -16
- package/fesm2022/lucca-front-ng-link.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-listbox.mjs +45 -35
- package/fesm2022/lucca-front-ng-listbox.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-listing.mjs +17 -16
- package/fesm2022/lucca-front-ng-listing.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-loading.mjs +8 -8
- package/fesm2022/lucca-front-ng-loading.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-main-layout.mjs +131 -15
- package/fesm2022/lucca-front-ng-main-layout.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-mobile-push.mjs +3 -3
- package/fesm2022/lucca-front-ng-mobile-push.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-modal.mjs +29 -29
- package/fesm2022/lucca-front-ng-modal.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-multi-select.mjs +197 -127
- package/fesm2022/lucca-front-ng-multi-select.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-new-badge.mjs +3 -3
- package/fesm2022/lucca-front-ng-number-format.mjs +6 -6
- package/fesm2022/lucca-front-ng-number.mjs +7 -7
- package/fesm2022/lucca-front-ng-numeric-badge.mjs +1 -84
- package/fesm2022/lucca-front-ng-numeric-badge.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-option.mjs +147 -140
- package/fesm2022/lucca-front-ng-option.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-page-header.mjs +8 -8
- package/fesm2022/lucca-front-ng-page-header.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-pagination.mjs +13 -16
- package/fesm2022/lucca-front-ng-pagination.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-plg-push.mjs +6 -6
- package/fesm2022/lucca-front-ng-plg-push.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-popover.mjs +17 -17
- package/fesm2022/lucca-front-ng-popover2.mjs +15 -16
- package/fesm2022/lucca-front-ng-popover2.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-popup.mjs +10 -10
- package/fesm2022/lucca-front-ng-progress-bar.mjs +8 -7
- package/fesm2022/lucca-front-ng-progress-bar.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-progress-stepper.mjs +9 -9
- package/fesm2022/lucca-front-ng-progress-stepper.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-read-more.mjs +17 -12
- package/fesm2022/lucca-front-ng-read-more.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-resource-card.mjs +21 -20
- package/fesm2022/lucca-front-ng-resource-card.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-safe-content.mjs +10 -10
- package/fesm2022/lucca-front-ng-scroll-box.mjs +6 -5
- package/fesm2022/lucca-front-ng-scroll-box.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-scroll.mjs +9 -9
- package/fesm2022/lucca-front-ng-scroll.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-segmented-control-tabs.mjs +12 -12
- package/fesm2022/lucca-front-ng-segmented-control-tabs.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-segmented-control.mjs +17 -14
- package/fesm2022/lucca-front-ng-segmented-control.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-select.mjs +22 -22
- package/fesm2022/lucca-front-ng-select.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-sidepanel.mjs +7 -7
- package/fesm2022/lucca-front-ng-simple-select.mjs +38 -34
- package/fesm2022/lucca-front-ng-simple-select.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-skeleton.mjs +1 -237
- package/fesm2022/lucca-front-ng-skeleton.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-software-icon-wrapper.mjs +11 -11
- package/fesm2022/lucca-front-ng-software-icon-wrapper.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-software-icon.mjs +8 -7
- package/fesm2022/lucca-front-ng-software-icon.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-sortable-list.mjs +13 -13
- package/fesm2022/lucca-front-ng-sortable-list.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-status-badge.mjs +6 -6
- package/fesm2022/lucca-front-ng-status-badge.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-table-of-content.mjs +6 -6
- package/fesm2022/lucca-front-ng-tag.mjs +1 -72
- package/fesm2022/lucca-front-ng-tag.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-text-flow.mjs +4 -4
- package/fesm2022/lucca-front-ng-text-flow.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-time.mjs +46 -47
- package/fesm2022/lucca-front-ng-time.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-title.mjs +24 -14
- package/fesm2022/lucca-front-ng-title.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-toast.mjs +13 -14
- package/fesm2022/lucca-front-ng-toast.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-tooltip.mjs +1 -556
- package/fesm2022/lucca-front-ng-tooltip.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-tree-select.mjs +51 -37
- package/fesm2022/lucca-front-ng-tree-select.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-user-popover.mjs +22 -19
- package/fesm2022/lucca-front-ng-user-popover.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-user.mjs +75 -73
- package/fesm2022/lucca-front-ng-user.mjs.map +1 -1
- package/fesm2022/lucca-front-ng-vertical-navigation.mjs +21 -22
- package/fesm2022/lucca-front-ng-vertical-navigation.mjs.map +1 -1
- package/package.json +12 -4
- package/schematics/action-icon/migration.spec.js +2 -2
- package/schematics/alignment-utilities/migration.spec.js +2 -2
- package/schematics/cdn-urls/migration.spec.js +2 -2
- package/schematics/class-prefix/migration.spec.js +2 -2
- package/schematics/color-text/migration.spec.js +2 -2
- package/schematics/component-path/migration.spec.js +2 -2
- package/schematics/deprecated-resolver/migration.spec.js +1 -1
- package/schematics/empty-state-title/migration.spec.js +1 -1
- package/schematics/lib/migration-test.js +6 -1
- package/schematics/lu-button/migration.spec.js +1 -1
- package/schematics/lu-container/migration.spec.js +1 -1
- package/schematics/lu-grid/migration.js +24 -16
- package/schematics/lu-grid/migration.spec.js +1 -1
- package/schematics/lu-icon/migration.spec.js +1 -1
- package/schematics/lu-loading/migration.spec.js +1 -1
- package/schematics/lu-select/migration.spec.js +1 -1
- package/schematics/lu-text-input/migration.spec.js +1 -1
- package/schematics/new-icons/migration.spec.js +2 -2
- package/schematics/palettes/index.js +28 -8
- package/schematics/palettes/migration.spec.js +2 -2
- package/schematics/tokens-radius/migration.spec.js +2 -2
- package/schematics/tokens-spacing/migration.spec.js +2 -2
- package/schematics/tokens-typo/migration.spec.js +2 -2
- package/src/_components.scss +1 -0
- package/src/components/_listbox.scss +8 -0
- package/src/components/_popover.scss +1 -1
- package/src/components/_popup.scss +6 -6
- package/src/components/_sidepanel.scss +1 -1
- package/src/definitions/option/_option-item.scss +0 -7
- package/title/README.md +22 -7
- package/types/lucca-front-ng-app-layout.d.ts +1 -1
- package/types/lucca-front-ng-approbation-inbox.d.ts +142 -0
- package/types/lucca-front-ng-box.d.ts +4 -4
- package/types/lucca-front-ng-breadcrumbs.d.ts +1 -1
- package/types/lucca-front-ng-bubble-icon.d.ts +1 -1
- package/types/lucca-front-ng-bubble-illustration.d.ts +1 -1
- package/types/lucca-front-ng-callout.d.ts +9 -9
- package/types/lucca-front-ng-chip.d.ts +3 -3
- package/types/lucca-front-ng-clear.d.ts +2 -2
- package/types/lucca-front-ng-code.d.ts +1 -1
- package/types/lucca-front-ng-color.d.ts +1 -1
- package/types/lucca-front-ng-comment.d.ts +6 -5
- package/types/lucca-front-ng-container.d.ts +2 -2
- package/types/lucca-front-ng-core-select-api.d.ts +10 -4
- package/types/lucca-front-ng-core-select-department.d.ts +2 -2
- package/types/lucca-front-ng-core-select-establishment.d.ts +3 -1
- package/types/lucca-front-ng-core-select-job-qualification.d.ts +2 -0
- package/types/lucca-front-ng-core-select-legal-units.d.ts +3 -1
- package/types/lucca-front-ng-core-select-occupation-category.d.ts +2 -0
- package/types/lucca-front-ng-core-select-user.d.ts +4 -3
- package/types/lucca-front-ng-core-select.d.ts +52 -15
- package/types/lucca-front-ng-core.d.ts +77 -3
- package/types/lucca-front-ng-data-table.d.ts +14 -14
- package/types/lucca-front-ng-date.d.ts +1 -1
- package/types/lucca-front-ng-date2.d.ts +19 -19
- package/types/lucca-front-ng-department.d.ts +2 -2
- package/types/lucca-front-ng-dialog.d.ts +7 -6
- package/types/lucca-front-ng-divider.d.ts +3 -3
- package/types/lucca-front-ng-dropdown.d.ts +2 -2
- package/types/lucca-front-ng-empty-state.d.ts +15 -6
- package/types/lucca-front-ng-establishment.d.ts +2 -2
- package/types/lucca-front-ng-file-upload.d.ts +22 -11
- package/types/lucca-front-ng-filter-pills.d.ts +43 -3
- package/types/lucca-front-ng-footer.d.ts +4 -4
- package/types/lucca-front-ng-form-field.d.ts +10 -10
- package/types/lucca-front-ng-form-header.d.ts +1 -1
- package/types/lucca-front-ng-form-label.d.ts +5 -9
- package/types/lucca-front-ng-form.d.ts +2 -2
- package/types/lucca-front-ng-forms-phone-number-input.d.ts +2 -2
- package/types/lucca-front-ng-forms-rich-text-input.d.ts +9 -5
- package/types/lucca-front-ng-forms.d.ts +50 -37
- package/types/lucca-front-ng-gauge.d.ts +6 -6
- package/types/lucca-front-ng-grid.d.ts +8 -8
- package/types/lucca-front-ng-highlight-data.d.ts +3 -5
- package/types/lucca-front-ng-highlight-section.d.ts +44 -0
- package/types/lucca-front-ng-horizontal-navigation.d.ts +4 -4
- package/types/lucca-front-ng-impersonation.d.ts +1 -1
- package/types/lucca-front-ng-index-table.d.ts +12 -12
- package/types/lucca-front-ng-inline-message.d.ts +1 -1
- package/types/lucca-front-ng-link.d.ts +4 -4
- package/types/lucca-front-ng-listbox.d.ts +20 -17
- package/types/lucca-front-ng-listing.d.ts +9 -9
- package/types/lucca-front-ng-loading.d.ts +3 -3
- package/types/lucca-front-ng-main-layout.d.ts +40 -9
- package/types/lucca-front-ng-modal.d.ts +1 -1
- package/types/lucca-front-ng-multi-select.d.ts +33 -7
- package/types/lucca-front-ng-numeric-badge.d.ts +1 -46
- package/types/lucca-front-ng-option.d.ts +2 -0
- package/types/lucca-front-ng-page-header.d.ts +2 -2
- package/types/lucca-front-ng-pagination.d.ts +5 -5
- package/types/lucca-front-ng-plg-push.d.ts +1 -1
- package/types/lucca-front-ng-popover2.d.ts +14 -14
- package/types/lucca-front-ng-progress-bar.d.ts +2 -2
- package/types/lucca-front-ng-progress-stepper.d.ts +1 -1
- package/types/lucca-front-ng-read-more.d.ts +9 -4
- package/types/lucca-front-ng-resource-card.d.ts +6 -6
- package/types/lucca-front-ng-scroll-box.d.ts +1 -1
- package/types/lucca-front-ng-scroll.d.ts +1 -1
- package/types/lucca-front-ng-segmented-control-tabs.d.ts +2 -2
- package/types/lucca-front-ng-segmented-control.d.ts +5 -3
- package/types/lucca-front-ng-select.d.ts +2 -1
- package/types/lucca-front-ng-simple-select.d.ts +5 -6
- package/types/lucca-front-ng-skeleton.d.ts +1 -158
- package/types/lucca-front-ng-software-icon-wrapper.d.ts +3 -3
- package/types/lucca-front-ng-software-icon.d.ts +2 -2
- package/types/lucca-front-ng-sortable-list.d.ts +5 -5
- package/types/lucca-front-ng-status-badge.d.ts +1 -1
- package/types/lucca-front-ng-tag.d.ts +1 -53
- package/types/lucca-front-ng-time.d.ts +17 -17
- package/types/lucca-front-ng-title.d.ts +4 -4
- package/types/lucca-front-ng-toast.d.ts +1 -1
- package/types/lucca-front-ng-tooltip.d.ts +1 -80
- package/types/lucca-front-ng-tree-select.d.ts +1 -1
- package/types/lucca-front-ng-user.d.ts +8 -6
- package/types/lucca-front-ng-vertical-navigation.d.ts +4 -4
|
@@ -1,17 +1,16 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { InjectionToken, inject, Pipe, signal, Injector, computed, afterNextRender, forwardRef, ChangeDetectionStrategy, Component, ChangeDetectorRef,
|
|
2
|
+
import { InjectionToken, inject, Pipe, signal, ElementRef, Injector, computed, afterNextRender, forwardRef, ChangeDetectionStrategy, Component, ChangeDetectorRef, Injectable, input, model, viewChild, ViewContainerRef, LOCALE_ID, ViewEncapsulation, DestroyRef, Directive, effect } from '@angular/core';
|
|
3
3
|
import { toSignal, takeUntilDestroyed, outputToObservable } from '@angular/core/rxjs-interop';
|
|
4
|
-
import { isNotNil, PortalDirective, getPushPanelViewportMargin, intlInputOptions, ɵeffectWithDeps as _effectWithDeps, isNil, syncInputSignal } from '@lucca-front/ng/core';
|
|
5
|
-
import * as i1$
|
|
6
|
-
import { LuSelectPanelRef, ɵIsSelectedStrategy as _IsSelectedStrategy, SELECT_ID, CoreSelectKeyManager, ɵgetGroupTemplateLocation as _getGroupTemplateLocation, LuSelectPanelLayoutComponent, ɵLuOptionComponent as _LuOptionComponent, ɵCoreSelectPanelElement as _CoreSelectPanelElement, LuIsOptionSelectedPipe, ɵLuOptionGroupPipe as _LuOptionGroupPipe, TreeDisplayPipe, SELECT_PANEL_INSTANCE, SELECT_LABEL_ID, addAttributesOnCdkContainer, ALuSelectInputComponent, LU_CORE_SELECT_TRANSLATIONS, ɵLuOptionOutletDirective as _LuOptionOutletDirective, provideLuSelectLabelsAndIds, LU_OPTION_CONTEXT, CORE_SELECT_API_TOTAL_COUNT_PROVIDER } from '@lucca-front/ng/core-select';
|
|
7
|
-
import * as i1 from '@angular/common';
|
|
4
|
+
import { isNotNil, PortalDirective, getPushPanelViewportMargin, intlInputOptions, luNumberAttribute, luBooleanAttribute, LOCALE_PLURAL_RULES, getIntlPluralLabel, ɵeffectWithDeps as _effectWithDeps, isNil, syncInputSignal } from '@lucca-front/ng/core';
|
|
5
|
+
import * as i1$1 from '@lucca-front/ng/core-select';
|
|
6
|
+
import { LuSelectPanelRef, ɵIsSelectedStrategy as _IsSelectedStrategy, SELECT_ID, ɵinjectPointerNavigation as _injectPointerNavigation, CoreSelectKeyManager, ɵgetGroupTemplateLocation as _getGroupTemplateLocation, LuSelectPanelLayoutComponent, ɵLuOptionComponent as _LuOptionComponent, ɵCoreSelectPanelElement as _CoreSelectPanelElement, LuIsOptionSelectedPipe, ɵLuOptionGroupPipe as _LuOptionGroupPipe, TreeDisplayPipe, SELECT_PANEL_INSTANCE, SELECT_LABEL_ID, addAttributesOnCdkContainer, ALuSelectInputComponent, LU_CORE_SELECT_TRANSLATIONS, ɵLuOptionOutletDirective as _LuOptionOutletDirective, provideLuSelectLabelsAndIds, LU_OPTION_CONTEXT, ɵscrollIntoViewOnceReady as _scrollIntoViewOnceReady, CORE_SELECT_API_TOTAL_COUNT_PROVIDER } from '@lucca-front/ng/core-select';
|
|
8
7
|
import { NgTemplateOutlet, CommonModule, AsyncPipe } from '@angular/common';
|
|
9
8
|
import * as i2 from '@angular/forms';
|
|
10
9
|
import { FormsModule, NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
11
10
|
import { ClearComponent } from '@lucca-front/ng/clear';
|
|
12
11
|
import { FilterPillDisplayerDirective, FilterPillLabelDirective, FILTER_PILL_INPUT_COMPONENT } from '@lucca-front/ng/filter-pills';
|
|
13
|
-
import * as i1
|
|
14
|
-
import { ɵPresentationDisplayDefaultDirective as _PresentationDisplayDefaultDirective,
|
|
12
|
+
import * as i1 from '@lucca-front/ng/form-field';
|
|
13
|
+
import { ɵPresentationDisplayDefaultDirective as _PresentationDisplayDefaultDirective, InputDirective, FormFieldComponent } from '@lucca-front/ng/form-field';
|
|
15
14
|
import { LuTooltipModule } from '@lucca-front/ng/tooltip';
|
|
16
15
|
import { IconComponent } from '@lucca/prisme/icon';
|
|
17
16
|
import { firstValueFrom, EMPTY, takeUntil, Subject, BehaviorSubject } from 'rxjs';
|
|
@@ -145,17 +144,17 @@ const Translations$1 = {
|
|
|
145
144
|
selectCountOptions: 'Select all results ({{optionsCount}})',
|
|
146
145
|
},
|
|
147
146
|
pl: {
|
|
148
|
-
placeholder: 'Wybierz
|
|
149
|
-
search: '
|
|
147
|
+
placeholder: 'Wybierz…',
|
|
148
|
+
search: 'Szukaj',
|
|
150
149
|
clear: 'Wyczyść zaznaczenie',
|
|
151
|
-
clearSearch: '
|
|
150
|
+
clearSearch: 'Wyczyść wyszukiwanie',
|
|
152
151
|
emptyResults: 'Wyszukiwanie nie przyniosło żadnych rezultatów.',
|
|
153
152
|
emptySelection: 'Wybierz elementy z listy po lewej stronie, aby rozpocząć',
|
|
154
153
|
expand: 'Rozwiń',
|
|
155
154
|
reduce: 'Zmniejsz',
|
|
156
155
|
selectAll: 'Zaznacz wszystko',
|
|
157
156
|
unselectAll: 'Odznacz wszystko',
|
|
158
|
-
loading: 'Trwa ładowanie
|
|
157
|
+
loading: 'Trwa ładowanie…',
|
|
159
158
|
emptyOptions: 'Brak dostępnych wartości. Aby uzyskać więcej informacji, skontaktuj się z administratorem.',
|
|
160
159
|
selectCountOptions: 'Zaznacz wszystkie wyniki ({{optionsCount}})',
|
|
161
160
|
},
|
|
@@ -166,6 +165,53 @@ const LU_MULTI_SELECT_TRANSLATIONS = new InjectionToken('LuMultiSelectTranslatio
|
|
|
166
165
|
});
|
|
167
166
|
const luMultiSelectTranslations = Translations$1;
|
|
168
167
|
|
|
168
|
+
/**
|
|
169
|
+
* Returns the `itemCount - 1` separators `Intl.ListFormat` puts between `itemCount` items, so they can be
|
|
170
|
+
* interleaved with values rendered by a template rather than by `format()`.
|
|
171
|
+
*
|
|
172
|
+
* @example
|
|
173
|
+
* ```ts
|
|
174
|
+
* listSeparators(new Intl.ListFormat('fr-FR'), 3); // [', ', ' et ']
|
|
175
|
+
* ```
|
|
176
|
+
*/
|
|
177
|
+
function listSeparators(listFormat, itemCount) {
|
|
178
|
+
return listFormat
|
|
179
|
+
.formatToParts(Array.from({ length: itemCount }, (_, index) => `${index}`))
|
|
180
|
+
.filter(({ type }) => type === 'literal')
|
|
181
|
+
.map(({ value }) => value);
|
|
182
|
+
}
|
|
183
|
+
function selectionToQueryParams(key, value, selector) {
|
|
184
|
+
if (value.mode === 'all' || value.mode === 'none') {
|
|
185
|
+
return {};
|
|
186
|
+
}
|
|
187
|
+
return { [value.mode === 'include' ? key : `-${key}`]: value.values.map(selector).join(',') };
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* Transforms a selection from withSelectAll, the complete list of options and a getKey function to a list of options.
|
|
191
|
+
*
|
|
192
|
+
* @example
|
|
193
|
+
* ```ts
|
|
194
|
+
* const selection = { mode: 'exclude', values: [{ id: 1, name: 'foo' }] };
|
|
195
|
+
* const allOptions = [{ id: 1, name: 'foo' }, { id: 2, name: 'bar' }, { id: 3, name: 'baz' }];
|
|
196
|
+
*
|
|
197
|
+
* const selectedOptions = selectionToOptions(selection, allOptions, (o) => o.id);
|
|
198
|
+
* ```
|
|
199
|
+
*/
|
|
200
|
+
function selectionToOptions(selection, options, getKeyFn) {
|
|
201
|
+
switch (selection.mode) {
|
|
202
|
+
case 'include':
|
|
203
|
+
return selection.values;
|
|
204
|
+
case 'exclude': {
|
|
205
|
+
const excludedKeys = new Set(selection.values.map(getKeyFn));
|
|
206
|
+
return options.filter((o) => !excludedKeys.has(getKeyFn(o)));
|
|
207
|
+
}
|
|
208
|
+
case 'all':
|
|
209
|
+
return options;
|
|
210
|
+
case 'none':
|
|
211
|
+
return [];
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
|
|
169
215
|
class LuMultiSelectPanelRef extends LuSelectPanelRef {
|
|
170
216
|
}
|
|
171
217
|
|
|
@@ -180,10 +226,10 @@ class LuOptionsGroupContextPipe {
|
|
|
180
226
|
isGroupSelected: this.#selectionStrategy.isGroupSelected(groupOptions, notSelectedOptions),
|
|
181
227
|
};
|
|
182
228
|
}
|
|
183
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
184
|
-
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "22.0.
|
|
229
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuOptionsGroupContextPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
230
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "22.0.8", ngImport: i0, type: LuOptionsGroupContextPipe, isStandalone: true, name: "luOptionsGroupContext" }); }
|
|
185
231
|
}
|
|
186
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
232
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuOptionsGroupContextPipe, decorators: [{
|
|
187
233
|
type: Pipe,
|
|
188
234
|
args: [{
|
|
189
235
|
name: 'luOptionsGroupContext',
|
|
@@ -208,8 +254,7 @@ class LuMultiSelectPanelComponent {
|
|
|
208
254
|
this.optionTpl = this.selectInput.optionTpl;
|
|
209
255
|
this.options = signal([], /* @ts-ignore */
|
|
210
256
|
...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ []));
|
|
211
|
-
this.pointerNavigation =
|
|
212
|
-
...(ngDevMode ? [{ debugName: "pointerNavigation" }] : /* istanbul ignore next */ []));
|
|
257
|
+
this.pointerNavigation = _injectPointerNavigation(inject(ElementRef).nativeElement);
|
|
213
258
|
this.keyManager = inject(CoreSelectKeyManager);
|
|
214
259
|
this.#injector = inject(Injector);
|
|
215
260
|
this.someGroupOptionEnabled = computed(() => {
|
|
@@ -229,7 +274,7 @@ class LuMultiSelectPanelComponent {
|
|
|
229
274
|
...(ngDevMode ? [{ debugName: "hasGrouping" }] : /* istanbul ignore next */ []));
|
|
230
275
|
this.clue = toSignal(this.selectInput.clue$.pipe(map((clue) => clue ?? '')), { initialValue: '' });
|
|
231
276
|
this.shouldDisplayAddOption = this.selectInput.shouldDisplayAddOption;
|
|
232
|
-
this.groupTemplateLocation = _getGroupTemplateLocation(this.hasGrouping, this.clue, this.searchable);
|
|
277
|
+
this.groupTemplateLocation = _getGroupTemplateLocation(this.hasGrouping, this.clue, this.dataSourceOptions, this.searchable);
|
|
233
278
|
// Loading takes precedence over empty so the "no result" message never flashes during a fetch
|
|
234
279
|
this.listboxState = computed(() => (this.loading() ? 'loading' : this.dataSourceOptions().length === 0 ? 'empty' : null), /* @ts-ignore */
|
|
235
280
|
...(ngDevMode ? [{ debugName: "listboxState" }] : /* istanbul ignore next */ []));
|
|
@@ -242,12 +287,6 @@ class LuMultiSelectPanelComponent {
|
|
|
242
287
|
...(ngDevMode ? [{ debugName: "listboxStatusMsg" }] : /* istanbul ignore next */ []));
|
|
243
288
|
}
|
|
244
289
|
#injector;
|
|
245
|
-
onKeydown() {
|
|
246
|
-
this.pointerNavigation.set(false);
|
|
247
|
-
}
|
|
248
|
-
onMousemove() {
|
|
249
|
-
this.pointerNavigation.set(true);
|
|
250
|
-
}
|
|
251
290
|
onScroll(evt) {
|
|
252
291
|
if (!(evt.target instanceof HTMLElement)) {
|
|
253
292
|
return;
|
|
@@ -329,20 +368,20 @@ class LuMultiSelectPanelComponent {
|
|
|
329
368
|
}
|
|
330
369
|
}
|
|
331
370
|
}
|
|
332
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
333
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.
|
|
371
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectPanelComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
372
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: LuMultiSelectPanelComponent, isStandalone: true, selector: "lu-select-panel", host: { properties: { "class.is-pointerNavigation": "pointerNavigation()" }, classAttribute: "selectPanel" }, providers: [
|
|
334
373
|
CoreSelectKeyManager,
|
|
335
374
|
{
|
|
336
375
|
provide: SELECT_PANEL_INSTANCE,
|
|
337
376
|
useExisting: forwardRef(() => LuMultiSelectPanelComponent),
|
|
338
377
|
},
|
|
339
|
-
], ngImport: i0, template: "<lu-select-panel-layout\n\tclass=\"lu-option-picker-panel mod-multiple\"\n\tdata-testid=\"dialog-panel\"\n\t[loading]=\"loading()\"\n\t[contentTabIndex]=\"0\"\n\t(scrolled)=\"onScroll($event)\"\n>\n\t<lu-listbox multiple [tree]=\"!!treeGenerator\" [state]=\"listboxState()\" [statusMsg]=\"listboxStatusMsg()\">\n\t\t<!-- The header is projected inside the listbox because it can contain selectable elements\n\t\t(e.g. the select-all checkbox) that are referenced by aria-activedescendant -->\n\t\t<ng-container ngProjectAs=\"[listbox-header]\">\n\t\t\t@if (selectInput.panelHeaderTpl(); as tpl) {\n\t\t\t\t<div>\n\t\t\t\t\t<ng-container *luPortal=\"tpl\" />\n\t\t\t\t</div>\n\t\t\t}\n\t\t</ng-container>\n\t\t@if (grouping() && groupTemplateLocation() === \"group-header\") {\n\t\t\t@for (group of dataSourceOptions() | luOptionGroup: grouping().selector; track group.key; let groupIndex = $index) {\n\t\t\t\t<lu-listbox-option group [groupId]=\"selectId + '-group-' + group.key\">\n\t\t\t\t\t<span #groupingTitleRef>\n\t\t\t\t\t\t<ng-container *luPortal=\"grouping().content; context: { $implicit: group }\" />\n\t\t\t\t\t</span>\n\t\t\t\t\t@if (someGroupOptionEnabled()(group.options)) {\n\t\t\t\t\t\t@let groupCtx = group.options | luOptionsGroupContext: selectedOptions : optionComparer();\n\t\t\t\t\t\t<
|
|
378
|
+
], ngImport: i0, template: "<lu-select-panel-layout\n\tclass=\"lu-option-picker-panel mod-multiple\"\n\tdata-testid=\"dialog-panel\"\n\t[loading]=\"loading()\"\n\t[contentTabIndex]=\"0\"\n\t(scrolled)=\"onScroll($event)\"\n>\n\t<lu-listbox multiple [tree]=\"!!treeGenerator\" [state]=\"listboxState()\" [statusMsg]=\"listboxStatusMsg()\">\n\t\t<!-- The header is projected inside the listbox because it can contain selectable elements\n\t\t(e.g. the select-all checkbox) that are referenced by aria-activedescendant -->\n\t\t<ng-container ngProjectAs=\"[listbox-header]\">\n\t\t\t@if (selectInput.panelHeaderTpl(); as tpl) {\n\t\t\t\t<div>\n\t\t\t\t\t<ng-container *luPortal=\"tpl\" />\n\t\t\t\t</div>\n\t\t\t}\n\t\t</ng-container>\n\t\t@if (grouping() && groupTemplateLocation() === \"group-header\") {\n\t\t\t@for (group of dataSourceOptions() | luOptionGroup: grouping().selector; track group.key; let groupIndex = $index) {\n\t\t\t\t<lu-listbox-option group [groupId]=\"selectId + '-group-' + group.key\" [elementId]=\"selectId + '-group-' + group.key\">\n\t\t\t\t\t<span #groupingTitleRef>\n\t\t\t\t\t\t<ng-container *luPortal=\"grouping().content; context: { $implicit: group }\" />\n\t\t\t\t\t</span>\n\t\t\t\t\t@if (someGroupOptionEnabled()(group.options)) {\n\t\t\t\t\t\t@let groupCtx = group.options | luOptionsGroupContext: selectedOptions : optionComparer();\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tgroup-action\n\t\t\t\t\t\t\tclass=\"link\"\n\t\t\t\t\t\t\tluCoreSelectPanelElement\n\t\t\t\t\t\t\t[elementId]=\"selectId + '-group-' + group.key + '-action'\"\n\t\t\t\t\t\t\t(selected)=\"toggleOptions(groupCtx.notSelectedOptions, group.options, group.key)\"\n\t\t\t\t\t\t\t[disabled]=\"groupLoadingKeys().has(group.key)\"\n\t\t\t\t\t\t\t(click)=\"toggleOptions(groupCtx.notSelectedOptions, group.options, group.key)\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t@if (groupLoadingKeys().has(group.key)) {\n\t\t\t\t\t\t\t\t<span class=\"loading\"></span>\n\t\t\t\t\t\t\t} @else {\n\t\t\t\t\t\t\t\t<span class=\"pr-u-mask\">{{ groupingTitleRef.innerText }} \u2013 </span\n\t\t\t\t\t\t\t\t>{{ groupCtx.isGroupSelected ? intl().unselectAll : intl().selectAll }}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t</div>\n\t\t\t\t\t}\n\t\t\t\t\t<div optgroup class=\"listboxOptionWrapper\">\n\t\t\t\t\t\t<ng-template\n\t\t\t\t\t\t\t[ngTemplateOutlet]=\"optionsList\"\n\t\t\t\t\t\t\t[ngTemplateOutletContext]=\"{ $implicit: group.options, groupIndex: groupIndex }\"\n\t\t\t\t\t\t/>\n\t\t\t\t\t</div>\n\t\t\t\t</lu-listbox-option>\n\t\t\t}\n\t\t}\n\t\t@if (!grouping() || groupTemplateLocation() !== \"group-header\") {\n\t\t\t<ng-template [ngTemplateOutlet]=\"optionsList\" [ngTemplateOutletContext]=\"{ $implicit: dataSourceOptions() }\" />\n\t\t}\n\t\t<ng-template #optionsList let-options let-groupIndex=\"groupIndex\">\n\t\t\t@if (treeGenerator) {\n\t\t\t\t@for (branch of options | luTreeDisplay: treeGenerator; let index = $index; track optionKey()(branch.node)) {\n\t\t\t\t\t<lu-tree-branch\n\t\t\t\t\t\t[branch]=\"branch\"\n\t\t\t\t\t\t[optionTpl]=\"optionTpl()\"\n\t\t\t\t\t\t[selectedOptions]=\"selectedOptions\"\n\t\t\t\t\t\t[optionComparer]=\"optionComparer()\"\n\t\t\t\t\t\t[optionIndex]=\"index\"\n\t\t\t\t\t\t(toggleOne)=\"toggleOption($event)\"\n\t\t\t\t\t\t(selectMany)=\"toggleOptions($event, [])\"\n\t\t\t\t\t\t(unselectMany)=\"toggleOptions([], $event)\"\n\t\t\t\t\t/>\n\t\t\t\t}\n\t\t\t} @else {\n\t\t\t\t@for (option of options; track optionKey()(option); let index = $index) {\n\t\t\t\t\t<lu-select-option\n\t\t\t\t\t\tluCoreSelectPanelElement\n\t\t\t\t\t\t[option]=\"option\"\n\t\t\t\t\t\t[optionTpl]=\"optionTpl()\"\n\t\t\t\t\t\t[optionIndex]=\"index\"\n\t\t\t\t\t\t[grouping]=\"groupTemplateLocation() === 'option' ? grouping() : undefined\"\n\t\t\t\t\t\t[groupIndex]=\"groupIndex\"\n\t\t\t\t\t\t[groupTemplateLocation]=\"groupTemplateLocation()\"\n\t\t\t\t\t\t[scrollIntoViewOptions]=\"{ block: 'nearest' }\"\n\t\t\t\t\t\t[isSelected]=\"option | luIsOptionSelected: optionComparer() : selectedOptions\"\n\t\t\t\t\t\t(selected)=\"toggleOption(option)\"\n\t\t\t\t\t\t(click)=\"toggleOption(option)\"\n\t\t\t\t\t\t[class.withAddOption]=\"shouldDisplayAddOption()\"\n\t\t\t\t\t/>\n\t\t\t\t}\n\t\t\t}\n\t\t</ng-template>\n\t</lu-listbox>\n\t@if (shouldDisplayAddOption()) {\n\t\t<lu-listbox-option\n\t\t\tadd\n\t\t\tclass=\"palette-product\"\n\t\t\tluCoreSelectPanelElement\n\t\t\t#addOptionElement=\"luCoreSelectPanelElement\"\n\t\t\telementId=\"picker-content-add\"\n\t\t\t[hovered]=\"addOptionElement.isHighlighted()\"\n\t\t\t(click)=\"selectInput.emitAddOption()\"\n\t\t\t(selected)=\"selectInput.emitAddOption()\"\n\t\t>\n\t\t\t<ng-container *luPortal=\"selectInput.addOptionLabel\" />\n\t\t</lu-listbox-option>\n\t}\n</lu-select-panel-layout>\n", styles: [""], dependencies: [{ kind: "component", type: LuSelectPanelLayoutComponent, selector: "lu-select-panel-layout", inputs: ["loading", "trapFocus", "contentTabIndex"], outputs: ["scrolled"] }, { kind: "ngmodule", type: FormsModule }, { kind: "component", type: _LuOptionComponent, selector: "lu-select-option", inputs: ["intl", "optionTpl", "option", "grouping", "hasChildren", "groupIndex", "optionIndex", "scrollIntoViewOptions", "groupTemplateLocation"], outputs: ["onlyParent", "onlyChildren"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: PortalDirective, selector: "[luPortal]", inputs: ["luPortal", "luPortalContext"] }, { kind: "directive", type: _CoreSelectPanelElement, selector: "[luCoreSelectPanelElement]", inputs: ["elementId", "isSelected", "option", "disabled"], outputs: ["isSelectedChange", "selected"], exportAs: ["luCoreSelectPanelElement"] }, { kind: "component", type: ListboxComponent, selector: "lu-listbox", inputs: ["multiple", "tree", "state", "statusMsg"] }, { kind: "component", type: OptionComponent, selector: "lu-listbox-option", inputs: ["elementId", "checked", "mixed", "disabled", "hovered", "add", "group", "groupId", "select", "selectAll", "treeitemLevel"] }, { kind: "component", type: TreeBranchComponent, selector: "lu-tree-branch", inputs: ["branch", "optionTpl", "optionIndex", "optionComparer", "selectedOptions", "simpleMode"], outputs: ["toggleOne", "selectMany", "unselectMany"] }, { kind: "pipe", type: LuIsOptionSelectedPipe, name: "luIsOptionSelected" }, { kind: "pipe", type: _LuOptionGroupPipe, name: "luOptionGroup" }, { kind: "pipe", type: LuOptionsGroupContextPipe, name: "luOptionsGroupContext" }, { kind: "pipe", type: TreeDisplayPipe, name: "luTreeDisplay" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
340
379
|
}
|
|
341
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
380
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectPanelComponent, decorators: [{
|
|
342
381
|
type: Component,
|
|
343
382
|
args: [{ selector: 'lu-select-panel', changeDetection: ChangeDetectionStrategy.OnPush, host: {
|
|
344
|
-
|
|
345
|
-
'
|
|
383
|
+
class: 'selectPanel',
|
|
384
|
+
'[class.is-pointerNavigation]': 'pointerNavigation()',
|
|
346
385
|
}, imports: [
|
|
347
386
|
LuSelectPanelLayoutComponent,
|
|
348
387
|
FormsModule,
|
|
@@ -363,7 +402,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
363
402
|
provide: SELECT_PANEL_INSTANCE,
|
|
364
403
|
useExisting: forwardRef(() => LuMultiSelectPanelComponent),
|
|
365
404
|
},
|
|
366
|
-
], template: "<lu-select-panel-layout\n\tclass=\"lu-option-picker-panel mod-multiple\"\n\tdata-testid=\"dialog-panel\"\n\t[loading]=\"loading()\"\n\t[contentTabIndex]=\"0\"\n\t(scrolled)=\"onScroll($event)\"\n>\n\t<lu-listbox multiple [tree]=\"!!treeGenerator\" [state]=\"listboxState()\" [statusMsg]=\"listboxStatusMsg()\">\n\t\t<!-- The header is projected inside the listbox because it can contain selectable elements\n\t\t(e.g. the select-all checkbox) that are referenced by aria-activedescendant -->\n\t\t<ng-container ngProjectAs=\"[listbox-header]\">\n\t\t\t@if (selectInput.panelHeaderTpl(); as tpl) {\n\t\t\t\t<div>\n\t\t\t\t\t<ng-container *luPortal=\"tpl\" />\n\t\t\t\t</div>\n\t\t\t}\n\t\t</ng-container>\n\t\t@if (grouping() && groupTemplateLocation() === \"group-header\") {\n\t\t\t@for (group of dataSourceOptions() | luOptionGroup: grouping().selector; track group.key; let groupIndex = $index) {\n\t\t\t\t<lu-listbox-option group [groupId]=\"selectId + '-group-' + group.key\">\n\t\t\t\t\t<span #groupingTitleRef>\n\t\t\t\t\t\t<ng-container *luPortal=\"grouping().content; context: { $implicit: group }\" />\n\t\t\t\t\t</span>\n\t\t\t\t\t@if (someGroupOptionEnabled()(group.options)) {\n\t\t\t\t\t\t@let groupCtx = group.options | luOptionsGroupContext: selectedOptions : optionComparer();\n\t\t\t\t\t\t<
|
|
405
|
+
], template: "<lu-select-panel-layout\n\tclass=\"lu-option-picker-panel mod-multiple\"\n\tdata-testid=\"dialog-panel\"\n\t[loading]=\"loading()\"\n\t[contentTabIndex]=\"0\"\n\t(scrolled)=\"onScroll($event)\"\n>\n\t<lu-listbox multiple [tree]=\"!!treeGenerator\" [state]=\"listboxState()\" [statusMsg]=\"listboxStatusMsg()\">\n\t\t<!-- The header is projected inside the listbox because it can contain selectable elements\n\t\t(e.g. the select-all checkbox) that are referenced by aria-activedescendant -->\n\t\t<ng-container ngProjectAs=\"[listbox-header]\">\n\t\t\t@if (selectInput.panelHeaderTpl(); as tpl) {\n\t\t\t\t<div>\n\t\t\t\t\t<ng-container *luPortal=\"tpl\" />\n\t\t\t\t</div>\n\t\t\t}\n\t\t</ng-container>\n\t\t@if (grouping() && groupTemplateLocation() === \"group-header\") {\n\t\t\t@for (group of dataSourceOptions() | luOptionGroup: grouping().selector; track group.key; let groupIndex = $index) {\n\t\t\t\t<lu-listbox-option group [groupId]=\"selectId + '-group-' + group.key\" [elementId]=\"selectId + '-group-' + group.key\">\n\t\t\t\t\t<span #groupingTitleRef>\n\t\t\t\t\t\t<ng-container *luPortal=\"grouping().content; context: { $implicit: group }\" />\n\t\t\t\t\t</span>\n\t\t\t\t\t@if (someGroupOptionEnabled()(group.options)) {\n\t\t\t\t\t\t@let groupCtx = group.options | luOptionsGroupContext: selectedOptions : optionComparer();\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tgroup-action\n\t\t\t\t\t\t\tclass=\"link\"\n\t\t\t\t\t\t\tluCoreSelectPanelElement\n\t\t\t\t\t\t\t[elementId]=\"selectId + '-group-' + group.key + '-action'\"\n\t\t\t\t\t\t\t(selected)=\"toggleOptions(groupCtx.notSelectedOptions, group.options, group.key)\"\n\t\t\t\t\t\t\t[disabled]=\"groupLoadingKeys().has(group.key)\"\n\t\t\t\t\t\t\t(click)=\"toggleOptions(groupCtx.notSelectedOptions, group.options, group.key)\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t@if (groupLoadingKeys().has(group.key)) {\n\t\t\t\t\t\t\t\t<span class=\"loading\"></span>\n\t\t\t\t\t\t\t} @else {\n\t\t\t\t\t\t\t\t<span class=\"pr-u-mask\">{{ groupingTitleRef.innerText }} \u2013 </span\n\t\t\t\t\t\t\t\t>{{ groupCtx.isGroupSelected ? intl().unselectAll : intl().selectAll }}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t</div>\n\t\t\t\t\t}\n\t\t\t\t\t<div optgroup class=\"listboxOptionWrapper\">\n\t\t\t\t\t\t<ng-template\n\t\t\t\t\t\t\t[ngTemplateOutlet]=\"optionsList\"\n\t\t\t\t\t\t\t[ngTemplateOutletContext]=\"{ $implicit: group.options, groupIndex: groupIndex }\"\n\t\t\t\t\t\t/>\n\t\t\t\t\t</div>\n\t\t\t\t</lu-listbox-option>\n\t\t\t}\n\t\t}\n\t\t@if (!grouping() || groupTemplateLocation() !== \"group-header\") {\n\t\t\t<ng-template [ngTemplateOutlet]=\"optionsList\" [ngTemplateOutletContext]=\"{ $implicit: dataSourceOptions() }\" />\n\t\t}\n\t\t<ng-template #optionsList let-options let-groupIndex=\"groupIndex\">\n\t\t\t@if (treeGenerator) {\n\t\t\t\t@for (branch of options | luTreeDisplay: treeGenerator; let index = $index; track optionKey()(branch.node)) {\n\t\t\t\t\t<lu-tree-branch\n\t\t\t\t\t\t[branch]=\"branch\"\n\t\t\t\t\t\t[optionTpl]=\"optionTpl()\"\n\t\t\t\t\t\t[selectedOptions]=\"selectedOptions\"\n\t\t\t\t\t\t[optionComparer]=\"optionComparer()\"\n\t\t\t\t\t\t[optionIndex]=\"index\"\n\t\t\t\t\t\t(toggleOne)=\"toggleOption($event)\"\n\t\t\t\t\t\t(selectMany)=\"toggleOptions($event, [])\"\n\t\t\t\t\t\t(unselectMany)=\"toggleOptions([], $event)\"\n\t\t\t\t\t/>\n\t\t\t\t}\n\t\t\t} @else {\n\t\t\t\t@for (option of options; track optionKey()(option); let index = $index) {\n\t\t\t\t\t<lu-select-option\n\t\t\t\t\t\tluCoreSelectPanelElement\n\t\t\t\t\t\t[option]=\"option\"\n\t\t\t\t\t\t[optionTpl]=\"optionTpl()\"\n\t\t\t\t\t\t[optionIndex]=\"index\"\n\t\t\t\t\t\t[grouping]=\"groupTemplateLocation() === 'option' ? grouping() : undefined\"\n\t\t\t\t\t\t[groupIndex]=\"groupIndex\"\n\t\t\t\t\t\t[groupTemplateLocation]=\"groupTemplateLocation()\"\n\t\t\t\t\t\t[scrollIntoViewOptions]=\"{ block: 'nearest' }\"\n\t\t\t\t\t\t[isSelected]=\"option | luIsOptionSelected: optionComparer() : selectedOptions\"\n\t\t\t\t\t\t(selected)=\"toggleOption(option)\"\n\t\t\t\t\t\t(click)=\"toggleOption(option)\"\n\t\t\t\t\t\t[class.withAddOption]=\"shouldDisplayAddOption()\"\n\t\t\t\t\t/>\n\t\t\t\t}\n\t\t\t}\n\t\t</ng-template>\n\t</lu-listbox>\n\t@if (shouldDisplayAddOption()) {\n\t\t<lu-listbox-option\n\t\t\tadd\n\t\t\tclass=\"palette-product\"\n\t\t\tluCoreSelectPanelElement\n\t\t\t#addOptionElement=\"luCoreSelectPanelElement\"\n\t\t\telementId=\"picker-content-add\"\n\t\t\t[hovered]=\"addOptionElement.isHighlighted()\"\n\t\t\t(click)=\"selectInput.emitAddOption()\"\n\t\t\t(selected)=\"selectInput.emitAddOption()\"\n\t\t>\n\t\t\t<ng-container *luPortal=\"selectInput.addOptionLabel\" />\n\t\t</lu-listbox-option>\n\t}\n</lu-select-panel-layout>\n" }]
|
|
367
406
|
}] });
|
|
368
407
|
|
|
369
408
|
class BaseMultiSelectPanelRef extends LuMultiSelectPanelRef {
|
|
@@ -496,10 +535,10 @@ class LuMultiSelectPanelRefFactory {
|
|
|
496
535
|
...(config.offsetY ? { offsetY: yDirection === 'bottom' ? config.offsetY : -config.offsetY } : {}),
|
|
497
536
|
};
|
|
498
537
|
}
|
|
499
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
500
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.
|
|
538
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectPanelRefFactory, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
539
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectPanelRefFactory }); }
|
|
501
540
|
}
|
|
502
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
541
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectPanelRefFactory, decorators: [{
|
|
503
542
|
type: Injectable
|
|
504
543
|
}] });
|
|
505
544
|
|
|
@@ -510,10 +549,26 @@ class LuMultiSelectInputComponent extends ALuSelectInputComponent {
|
|
|
510
549
|
...(ngDevMode ? [{ debugName: "intl" }] : /* istanbul ignore next */ []));
|
|
511
550
|
this.valuesTpl = model(LuMultiSelectDefaultDisplayerComponent, /* @ts-ignore */
|
|
512
551
|
...(ngDevMode ? [{ debugName: "valuesTpl" }] : /* istanbul ignore next */ []));
|
|
513
|
-
this.maxValuesShown = input(500, { ...(ngDevMode ? { debugName: "maxValuesShown" } : /* istanbul ignore next */ {}), transform:
|
|
514
|
-
this.keepSearchAfterSelection = input(false, { ...(ngDevMode ? { debugName: "keepSearchAfterSelection" } : /* istanbul ignore next */ {}), transform:
|
|
552
|
+
this.maxValuesShown = input(500, { ...(ngDevMode ? { debugName: "maxValuesShown" } : /* istanbul ignore next */ {}), transform: luNumberAttribute });
|
|
553
|
+
this.keepSearchAfterSelection = input(false, { ...(ngDevMode ? { debugName: "keepSearchAfterSelection" } : /* istanbul ignore next */ {}), transform: luBooleanAttribute });
|
|
554
|
+
this.pluralRules = inject(LOCALE_PLURAL_RULES);
|
|
555
|
+
/**
|
|
556
|
+
* @deprecated use filterPillLabelPluralFn
|
|
557
|
+
*/
|
|
515
558
|
this.filterPillLabelPlural = input(/* @ts-ignore */
|
|
516
559
|
...(ngDevMode ? [undefined, { debugName: "filterPillLabelPlural" }] : /* istanbul ignore next */ []));
|
|
560
|
+
this.filterPillLabelPluralFn = input(/* @ts-ignore */
|
|
561
|
+
...(ngDevMode ? [undefined, { debugName: "filterPillLabelPluralFn" }] : /* istanbul ignore next */ []));
|
|
562
|
+
this.filterPillLabelPluralValue = computed(() => {
|
|
563
|
+
const label = this.filterPillLabelPluralFn();
|
|
564
|
+
const count = this.valueLength();
|
|
565
|
+
if (label) {
|
|
566
|
+
const result = label(count);
|
|
567
|
+
return typeof result === 'string' ? result : getIntlPluralLabel(this.pluralRules, result, count);
|
|
568
|
+
}
|
|
569
|
+
return `${count} ${this.filterPillLabelPlural()}`;
|
|
570
|
+
}, /* @ts-ignore */
|
|
571
|
+
...(ngDevMode ? [{ debugName: "filterPillLabelPluralValue" }] : /* istanbul ignore next */ []));
|
|
517
572
|
this.selectParent$ = new Subject();
|
|
518
573
|
this.selectChildren$ = new Subject();
|
|
519
574
|
this.hideCombobox = computed(() => (this.valueSignal()?.length ?? 0) > 1, /* @ts-ignore */
|
|
@@ -531,7 +586,12 @@ class LuMultiSelectInputComponent extends ALuSelectInputComponent {
|
|
|
531
586
|
// eslint-disable-next-line @angular-eslint/prefer-signals
|
|
532
587
|
this.useSingleOptionDisplayer = signal(true, /* @ts-ignore */
|
|
533
588
|
...(ngDevMode ? [{ debugName: "useSingleOptionDisplayer" }] : /* istanbul ignore next */ []));
|
|
589
|
+
this.singleOptionForDisplay = computed(() => this.valueSignal()?.[0], /* @ts-ignore */
|
|
590
|
+
...(ngDevMode ? [{ debugName: "singleOptionForDisplay" }] : /* istanbul ignore next */ []));
|
|
534
591
|
this._value = [];
|
|
592
|
+
this.#listFormat = new Intl.ListFormat(inject(LOCALE_ID));
|
|
593
|
+
this.presentationSeparators = computed(() => listSeparators(this.#listFormat, this.valueSignal()?.length ?? 0), /* @ts-ignore */
|
|
594
|
+
...(ngDevMode ? [{ debugName: "presentationSeparators" }] : /* istanbul ignore next */ []));
|
|
535
595
|
this.panelRefFactory = inject(LuMultiSelectPanelRefFactory);
|
|
536
596
|
/**
|
|
537
597
|
* This is used to tell the displayer to focus on the input element
|
|
@@ -544,6 +604,7 @@ class LuMultiSelectInputComponent extends ALuSelectInputComponent {
|
|
|
544
604
|
get filterPillClass() {
|
|
545
605
|
return this.filterPillMode;
|
|
546
606
|
}
|
|
607
|
+
#listFormat;
|
|
547
608
|
get panelRef() {
|
|
548
609
|
return this._panelRef;
|
|
549
610
|
}
|
|
@@ -602,8 +663,8 @@ class LuMultiSelectInputComponent extends ALuSelectInputComponent {
|
|
|
602
663
|
super.ngOnDestroy();
|
|
603
664
|
this.focusInput$.complete();
|
|
604
665
|
}
|
|
605
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
606
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.
|
|
666
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectInputComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
667
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: LuMultiSelectInputComponent, isStandalone: true, selector: "lu-multi-select", inputs: { intl: { classPropertyName: "intl", publicName: "intl", isSignal: true, isRequired: false, transformFunction: null }, valuesTpl: { classPropertyName: "valuesTpl", publicName: "valuesTpl", isSignal: true, isRequired: false, transformFunction: null }, maxValuesShown: { classPropertyName: "maxValuesShown", publicName: "maxValuesShown", isSignal: true, isRequired: false, transformFunction: null }, keepSearchAfterSelection: { classPropertyName: "keepSearchAfterSelection", publicName: "keepSearchAfterSelection", isSignal: true, isRequired: false, transformFunction: null }, filterPillLabelPlural: { classPropertyName: "filterPillLabelPlural", publicName: "filterPillLabelPlural", isSignal: true, isRequired: false, transformFunction: null }, filterPillLabelPluralFn: { classPropertyName: "filterPillLabelPluralFn", publicName: "filterPillLabelPluralFn", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { valuesTpl: "valuesTplChange" }, host: { listeners: { "keydown.control.enter": "selectParentOnly()", "keydown.shift.enter": "selectChildrenOnly()" }, properties: { "class.mod-filterPill": "filterPillClass" }, classAttribute: "multiSelect" }, providers: [
|
|
607
668
|
{
|
|
608
669
|
provide: NG_VALUE_ACCESSOR,
|
|
609
670
|
useExisting: forwardRef(() => LuMultiSelectInputComponent),
|
|
@@ -619,9 +680,9 @@ class LuMultiSelectInputComponent extends ALuSelectInputComponent {
|
|
|
619
680
|
provide: FILTER_PILL_INPUT_COMPONENT,
|
|
620
681
|
useExisting: forwardRef(() => LuMultiSelectInputComponent),
|
|
621
682
|
},
|
|
622
|
-
], viewQueries: [{ propertyName: "filterPillPanelAnchorRef", first: true, predicate: ["filterPillPanelAnchor"], descendants: true, read: ViewContainerRef, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<ng-container *luOptionOutlet=\"valuesTpl(); value: value || []\" />\n\n@if (!filterPillMode) {\n\t@if (hasValue() && clearable() && (disabled$ | async) === false) {\n\t\t<lu-clear class=\"multipleSelect-clear\" (onClear)=\"clearValue($event)\">{{ intl().clear }}</lu-clear>\n\t}\n\n\t<lu-icon icon=\"arrowChevronBottom\" class=\"multipleSelect-arrow\" />\n\t<lu-icon icon=\"searchMagnifyingGlass\" class=\"multipleSelect-searchIcon\" />\n}\n\n<ng-container #filterPillPanelAnchor />\n<ng-container *luFilterPillDisplayer>\n\t<div class=\"multipleSelect-displayer-filter\">\n\t\t@if (useSingleOptionDisplayer() && valueLength() === 1) {\n\t\t\t<div class=\"multipleSelect-pill-displayer-chip\">\n\t\t\t\t<ng-container *luOptionOutlet=\"displayerTpl(); value: value[0]\" />\n\t\t\t</div>\n\t\t}\n\t</div>\n</ng-container>\n<ng-container *luFilterPillLabel=\"let label = label; let colon = colon\">\n\t@let minCount = useSingleOptionDisplayer() ? 1 : 0;\n\t@if (valueLength() > minCount) {\n\t\t<span class=\"multipleSelect-pill-displayer-label\">{{ valueLength() }} {{ filterPillLabelPlural() }}</span>\n\t} @else {\n\t\t{{ label }}\n\t\t@if (valueLength() === 1) {\n\t\t\t{{ colon }}\n\t\t}\n\t}\n</ng-container>\n@if (!ignorePresentation()) {\n\t<ng-container *luPresentationDisplayDefault>\n\t\t@for (v of value; track $index) {\n\t\t\t@if ($last) {\n\t\t\t\t<ng-container *ngTemplateOutlet=\"noComma; context: { $implicit: v }\" />\n\t\t\t} @else {\n\t\t\t\t<ng-container *ngTemplateOutlet=\"comma; context: { $implicit: v }\" />\n\t\t\t}\n\t\t} @empty {\n\t\t\t<span aria-hidden=\"true\" data-content-before=\"\u2013\"></span>\n\t\t}\n\t</ng-container>\n}\n\n<ng-template #comma let-value><ng-container *luOptionOutlet=\"displayerTpl(); value: value\" />, </ng-template>\n\n<ng-template #noComma let-value>\n\t<ng-container *luOptionOutlet=\"displayerTpl(); value: value\" />\n</ng-template>\n", styles: ["@layer components{.multiSelect{--components-multiSelect-font: var(--pr-t-font-body-M);--components-multiSelect-padding: var(--pr-t-spacings-100);--components-multiSelect-gap: var(--pr-t-spacings-100);--components-multiSelect-background: var(--pr-t-color-input-background);--components-multiSelect-border-color: var(--pr-t-color-input-border);--components-multiSelect-placeholder: var(--pr-t-color-input-text-placeholder);--components-multiSelect-arrow-color: var(--pr-t-color-input-icon);--components-multiSelect-displayer-suffix-display: contents;display:flex;box-shadow:0 0 0 1px var(--components-multiSelect-border-color);background-color:var(--components-multiSelect-background);border-radius:var(--pr-t-border-radius-input);padding:var(--components-multiSelect-padding);align-items:flex-end;gap:var(--components-multiSelect-gap);cursor:pointer}.multiSelect:hover{--components-multiSelect-border-color: var(--pr-t-color-input-border-hover)}.multiSelect:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multipleSelect-displayer{display:flex;gap:var(--pr-t-spacings-50);flex-wrap:wrap;flex:1}.multipleSelect-displayer-suffix{display:var(--components-multiSelect-displayer-suffix-display);gap:var(--pr-t-spacings-50);flex:1;order:1}.multipleSelect-displayer-chip.chip{min-inline-size:0;--components-chip-backgroundColor: var(--palettes-100, var(--palettes-product-100));--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-product-800));--components-chip-color: var(--palettes-800, var(--palettes-product-800))}.multipleSelect-displayer-chip-value{max-inline-size:8.75rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.multipleSelect-displayer-search{display:block;min-inline-size:2rem;inline-size:auto;flex:1;order:1;border:0;padding:0;outline:none;color:var(--pr-t-color-input-text);font:var(--components-multiSelect-font);background-color:transparent;cursor:pointer}.multipleSelect-displayer-search::placeholder{color:var(--components-multiSelect-placeholder)}.multipleSelect-displayer-label{font:var(--components-multiSelect-font)}.multipleSelect-clear{margin-block-end:var(--pr-t-spacings-50)}.multipleSelect-arrow,.multipleSelect-searchIcon{--icon-size: 1.5rem;color:var(--components-multiSelect-arrow-color);transition-property:transform;transition-duration:var(--commons-animations-durations-standard)}.multipleSelect-searchIcon{display:none}.multipleSelect-pill-displayer-chip{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.multipleSelect-pill-displayer-label{font-weight:var(--pr-t-font-fontWeight-semibold)}.multiSelect-field-icon{order:1}}@layer mods{.multiSelect.mod-S{--components-multiSelect-font: var(--pr-t-font-body-S);--components-multiSelect-padding: var(--pr-t-spacings-75);--components-multiSelect-gap: var(--pr-t-spacings-75)}.multiSelect.mod-S .multipleSelect-arrow,.multiSelect.mod-S .multipleSelect-searchIcon{--icon-size: 1.25rem}.multiSelect.mod-S .multipleSelect-clear.clear,.multiSelect.mod-S .multipleSelect-clear:not(.clear){--components-clear-size: .75rem;--icon-size: .75rem}.multiSelect.mod-S .multipleSelect-displayer-chip.chip,.multiSelect.mod-S .multipleSelect-displayer-chip:not(.chip){--components-chip-font: var(--pr-t-font-body-XS);--components-chip-borderRadius: var(--pr-t-border-radius-small)}.multiSelect.mod-S .multipleSelect-displayer-chip.chip .lucca-icon,.multiSelect.mod-S .multipleSelect-displayer-chip:not(.chip) .lucca-icon{--icon-size: .75rem}.multiSelect.mod-filterPill{--components-multiSelect-displayer-suffix-display: flex;flex-direction:column;align-items:stretch;box-shadow:none;padding:0;gap:0;inline-size:26.5rem;max-inline-size:calc(100vw - 2.5rem)}.multiSelect.mod-filterPill .multipleSelect-displayer{box-shadow:0 0 0 1px var(--components-multiSelect-border-color);border-radius:var(--pr-t-border-radius-input);padding:var(--components-multiSelect-padding);z-index:1;position:relative;max-block-size:min(14rem,80vh);overflow:auto}.multiSelect.mod-filterPill .lu-picker-content{animation:none;box-shadow:none;border-radius:0;background-color:transparent;padding:var(--pr-t-spacings-50);margin:var(--pr-t-spacings-75) calc(var(--pr-t-spacings-100) * -1) calc(var(--pr-t-spacings-100) * -1)}.multiSelect.mod-filterPill .lu-picker-content lu-simple-select-default-option.pr-u-ellipsis{white-space:normal!important}.multiSelect.mod-filterPill:has(.multipleSelect-displayer-search:focus-visible){outline:none}.multiSelect.mod-filterPill .multipleSelect-displayer:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multiSelect.mod-filterPill.is-selected .multipleSelect-displayer-search[readonly]{border:0;clip-path:rect(1px 1px 1px 1px);margin:-1px;overflow:hidden;padding:0;position:absolute;block-size:1px;inline-size:1px;white-space:nowrap;contain:paint}.multiSelect:not(.mod-filterPill).is-selected .multipleSelect-displayer-search:not(:focus),.multiSelect:not(.mod-filterPill).is-selected .multipleSelect-displayer-search[readonly]{border:0;clip-path:rect(1px 1px 1px 1px);margin:-1px;overflow:hidden;padding:0;position:absolute;block-size:1px;inline-size:1px;white-space:nowrap;contain:paint}.multiSelect:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multiSelect:has(.multipleSelect-displayer-search[aria-invalid=true]){--components-multiSelect-border-color: var(--pr-t-color-input-border-critical);--components-multiSelect-background: var(--pr-t-color-input-background-critical);--components-multiSelect-placeholder: var(--pr-t-color-input-text-placeholder-critical)}.multiSelect:has(.multipleSelect-displayer-search:disabled){--components-multiSelect-background: var(--commons-disabled-background);--components-multiSelect-placeholder: var(--commons-disabled-placeholder);--components-multiSelect-arrow-color: var(--pr-t-color-input-icon-disabled);pointer-events:none}.multiSelect:has(.multipleSelect-displayer-search:disabled) .multipleSelect-displayer-chip{--components-chip-backgroundColor: var(--palettes-neutral-200);--components-chip-color: var(--pr-t-color-text-subtle)}.multiSelect:has(.multipleSelect-displayer-search:disabled) .multipleSelect-displayer-chip .chip-kill{display:none}.multiSelect:has([aria-expanded=true]) .multipleSelect-arrow{transform:rotate(180deg)}.multiSelect:not(.mod-noClueIcon):has(.multipleSelect-displayer-search:focus-visible):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-arrow,.multiSelect:not(.mod-noClueIcon):has([aria-expanded=true]):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-arrow{display:none}.multiSelect:not(.mod-noClueIcon):has(.multipleSelect-displayer-search:focus-visible):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-searchIcon,.multiSelect:not(.mod-noClueIcon):has([aria-expanded=true]):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-searchIcon{display:inline-flex;transform:none}}@layer components{.multipleSelect-displayer-filter{min-inline-size:0;display:flex;gap:.5ch}.multipleSelect-displayer-filter:empty{display:none}}@layer components{.clear{--components-clear-display: grid;--components-clear-size: 1rem;--components-clear-background: var(--palettes-800, var(--palettes-neutral-800));--components-clear-cross-color: var(--palettes-0, var(--palettes-neutral-0));--components-clear-background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='16' width='16' fill='none'%3E%3Cpath d='M5.80473 4.86192C5.54438 4.60157 5.12227 4.60157 4.86192 4.86192C4.60157 5.12227 4.60157 5.54438 4.86192 5.80473L7.05718 7.99999L4.86192 10.1953C4.60157 10.4556 4.60157 10.8777 4.86192 11.1381C5.12227 11.3984 5.54438 11.3984 5.80473 11.1381L7.99999 8.9428L10.1953 11.1381C10.4556 11.3984 10.8777 11.3984 11.1381 11.1381C11.3984 10.8777 11.3984 10.4556 11.1381 10.1953L8.9428 7.99999L11.1381 5.80473C11.3984 5.54438 11.3984 5.12227 11.1381 4.86192C10.8777 4.60157 10.4556 4.60157 10.1953 4.86192L7.99999 7.05718L5.80473 4.86192Z' fill='currentColor'/%3E%3C/svg%3E\");padding:0;border:0;inline-size:100%;background-color:transparent;color:inherit;text-align:start;display:block;font:inherit;cursor:pointer;display:var(--components-clear-display);grid-template-columns:1fr;grid-template-rows:1fr;grid-template-areas:\"main\";align-items:normal;flex-shrink:0;inline-size:var(--components-clear-size);block-size:var(--components-clear-size);border-radius:var(--pr-t-border-radius-full)}.clear:before,.clear:after{content:\"\";grid-area:main}.clear:before{border-radius:var(--pr-t-border-radius-full);background-color:var(--components-clear-background)}.clear:after{-webkit-mask-image:var(--components-clear-background-image);mask-image:var(--components-clear-background-image);-webkit-mask-size:var(--components-clear-size);mask-size:var(--components-clear-size);-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--components-clear-cross-color)}.clear:hover{--components-clear-cross-color: var(--palettes-0, var(--palettes-neutral-0));--components-clear-background: var(--palettes-700, var(--palettes-neutral-700))}.clear:focus-visible{outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:2px;border-radius:50%}.clear:active{--components-clear-background: var(--palettes-900, var(--palettes-neutral-900))}.clear .lucca-icon{display:none}}@layer mods{.clear.mod-S{--components-clear-size: .75rem;--icon-size: .75rem}.clear.mod-inverted{--components-clear-cross-color: var(--palettes-800, var(--palettes-neutral-800));--components-clear-background: var(--palettes-0, var(--palettes-neutral-0))}.clear.mod-inverted:hover{--components-clear-background: var(--palettes-50, var(--palettes-neutral-50))}.clear.mod-inverted:active{--components-clear-background: var(--palettes-100, var(--palettes-neutral-100))}.clear[disabled]{cursor:default;--components-clear-cross-color: var(--palettes-neutral-500)}.clear[disabled],.clear[disabled]:hover,.clear[disabled]:active{--components-clear-background: var(--palettes-neutral-300)}.clear[hidden],.filterPill[disabled] .clear,.filterPill:not(.is-filled) .clear,.textfield-input[disabled] .clear,.textfield-input:not(.is-filled) .clear{--components-clear-display: none}.multiSelect.is-selected:has(.multipleSelect-clear) .clear{--components-clear-display: grid}}@layer components{.chip{--components-chip-font: var(--pr-t-font-body-S);--components-chip-backgroundColor: var(--palettes-100, var(--palettes-neutral-100));--components-chip-color: var(--palettes-800, var(--pr-t-color-text));--components-chip-borderRadius: var(--pr-t-border-radius-default);--components-chip-kill-size: .75rem;--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-neutral-800));--components-chip-kill-cross-color: var(--palettes-text, var(--palettes-neutral-text));--components-chip-kill-background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='16' width='16' fill='none'%3E%3Cpath d='M5.80473 4.86192C5.54438 4.60157 5.12227 4.60157 4.86192 4.86192C4.60157 5.12227 4.60157 5.54438 4.86192 5.80473L7.05718 7.99999L4.86192 10.1953C4.60157 10.4556 4.60157 10.8777 4.86192 11.1381C5.12227 11.3984 5.54438 11.3984 5.80473 11.1381L7.99999 8.9428L10.1953 11.1381C10.4556 11.3984 10.8777 11.3984 11.1381 11.1381C11.3984 10.8777 11.3984 10.4556 11.1381 10.1953L8.9428 7.99999L11.1381 5.80473C11.3984 5.54438 11.3984 5.12227 11.1381 4.86192C10.8777 4.60157 10.4556 4.60157 10.1953 4.86192L7.99999 7.05718L5.80473 4.86192Z' fill='currentColor'/%3E%3C/svg%3E\");--components-chip-fontSize: var(--pr-t-font-body-S-fontSize);--components-chip-lineHeight: var(--pr-t-font-body-S-lineHeight);background-color:var(--components-chip-backgroundColor);border:none;border-radius:var(--components-chip-borderRadius);color:var(--components-chip-color);display:inline-flex;align-items:center;position:relative;vertical-align:middle;padding-block:calc(var(--pr-t-spacings-50) / 2);padding-inline:var(--pr-t-spacings-100);font:var(--components-chip-font);max-inline-size:100%}.chip .lucca-icon{--icon-size: 1rem;margin-inline-end:var(--pr-t-spacings-50)}.chip-content{outline:none}.chip-kill{padding:0;border:0;inline-size:100%;background-color:transparent;color:inherit;text-align:start;display:block;font:inherit;display:grid;grid-template-columns:1fr;grid-template-rows:1fr;grid-template-areas:\"main\";place-items:center;inline-size:var(--pr-t-spacings-300);block-size:var(--pr-t-spacings-300);margin:calc(var(--pr-t-spacings-75) * -1);margin-inline-start:var(--pr-t-spacings-25);flex-shrink:0;cursor:pointer}.chip-kill:before,.chip-kill:after{content:\"\";grid-area:main;inline-size:var(--components-chip-kill-size);block-size:var(--components-chip-kill-size)}.chip-kill:before{border-radius:var(--pr-t-border-radius-full);background-color:var(--components-chip-kill-disk-color)}.chip-kill:after{-webkit-mask-image:var(--components-chip-kill-background-image);mask-image:var(--components-chip-kill-background-image);-webkit-mask-size:var(--components-chip-kill-size);mask-size:var(--components-chip-kill-size);-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--components-chip-kill-cross-color)}.chip-kill:hover{--components-chip-kill-disk-color: var(--palettes-700, var(--palettes-neutral-700))}.chip-kill:focus-visible{outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:-4px;border-radius:var(--pr-t-border-radius-full)}.chip-kill:active{--components-chip-kill-disk-color: var(--palettes-900, var(--palettes-neutral-900))}}@layer mods{.chip.mod-S{--components-chip-font: var(--pr-t-font-body-XS);--components-chip-borderRadius: var(--pr-t-border-radius-small)}.chip.mod-S .lucca-icon{--icon-size: .75rem}.chip.mod-unkillable .chip-kill{display:none}.chip.mod-clickable{cursor:pointer;text-decoration:none}.chip.is-disabled{--components-chip-backgroundColor: var(--palettes-neutral-200);--components-chip-color: var(--pr-t-color-text-subtle)}.chip.is-disabled .chip-kill{display:none}.chip:has(.chip-content:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:2px}.chip.mod-product{--components-chip-backgroundColor: var(--palettes-100, var(--palettes-product-100));--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-product-800));--components-chip-color: var(--palettes-800, var(--palettes-product-800))}}\n"], dependencies: [{ kind: "ngmodule", type: LuTooltipModule }, { kind: "directive", type: _LuOptionOutletDirective, selector: "[luOptionOutlet]", inputs: ["luOptionOutlet", "luOptionOutletValue", "luOptionShowNull"] }, { kind: "directive", type: FilterPillDisplayerDirective, selector: "[luFilterPillDisplayer]" }, { kind: "directive", type: FilterPillLabelDirective, selector: "[luFilterPillLabel]" }, { kind: "component", type: ClearComponent, selector: "lu-clear", inputs: ["intl", "size", "disabled", "palette", "inverted"], outputs: ["onClear"], exportAs: ["luClearer"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: _PresentationDisplayDefaultDirective, selector: "[luPresentationDisplayDefault]" }, { kind: "component", type: IconComponent, selector: "lu-icon, pr-icon", inputs: ["icon", "alt", "size", "color", "AI"] }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
683
|
+
], viewQueries: [{ propertyName: "filterPillPanelAnchorRef", first: true, predicate: ["filterPillPanelAnchor"], descendants: true, read: ViewContainerRef, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<ng-container *luOptionOutlet=\"valuesTpl(); value: value || []\" />\n\n@if (!filterPillMode) {\n\t@if (hasValue() && clearable() && (disabled$ | async) === false) {\n\t\t<lu-clear class=\"multipleSelect-clear\" (onClear)=\"clearValue($event)\">{{ intl().clear }}</lu-clear>\n\t}\n\n\t<lu-icon icon=\"arrowChevronBottom\" class=\"multipleSelect-arrow\" />\n\t<lu-icon icon=\"searchMagnifyingGlass\" class=\"multipleSelect-searchIcon\" />\n}\n\n<ng-container #filterPillPanelAnchor />\n<ng-container *luFilterPillDisplayer>\n\t<div class=\"multipleSelect-displayer-filter\">\n\t\t@if (useSingleOptionDisplayer() && valueLength() === 1 && singleOptionForDisplay() !== undefined) {\n\t\t\t<div class=\"multipleSelect-pill-displayer-chip\">\n\t\t\t\t<ng-container *luOptionOutlet=\"displayerTpl(); value: singleOptionForDisplay()\" />\n\t\t\t</div>\n\t\t}\n\t</div>\n</ng-container>\n<ng-container *luFilterPillLabel=\"let label = label; let colon = colon\">\n\t@let minCount = useSingleOptionDisplayer() ? 1 : 0;\n\t@if (valueLength() > minCount) {\n\t\t<span class=\"multipleSelect-pill-displayer-label\">{{ filterPillLabelPluralValue() }}</span>\n\t} @else {\n\t\t{{ label }}{{ valueLength() === 1 ? colon : \"\" }}\n\t}\n</ng-container>\n@if (!ignorePresentation()) {\n\t<ng-container *luPresentationDisplayDefault>\n\t\t@for (v of value; track $index) {\n\t\t\t<ng-container *luOptionOutlet=\"displayerTpl(); value: v\" />\n\n\t\t\t@let separator = presentationSeparators()[$index];\n\n\t\t\t@if (separator) {\n\t\t\t\t<ng-container>{{ separator }}</ng-container>\n\t\t\t}\n\t\t} @empty {\n\t\t\t<span aria-hidden=\"true\" data-content-before=\"\u2013\"></span>\n\t\t}\n\t</ng-container>\n}\n", styles: ["@layer components{.multiSelect{--components-multiSelect-font: var(--pr-t-font-body-M);--components-multiSelect-padding: var(--pr-t-spacings-100);--components-multiSelect-gap: var(--pr-t-spacings-100);--components-multiSelect-background: var(--pr-t-color-input-background);--components-multiSelect-border-color: var(--pr-t-color-input-border);--components-multiSelect-placeholder: var(--pr-t-color-input-text-placeholder);--components-multiSelect-arrow-color: var(--pr-t-color-input-icon);--components-multiSelect-displayer-suffix-display: contents;display:flex;box-shadow:0 0 0 1px var(--components-multiSelect-border-color);background-color:var(--components-multiSelect-background);border-radius:var(--pr-t-border-radius-input);padding:var(--components-multiSelect-padding);align-items:flex-end;gap:var(--components-multiSelect-gap);cursor:pointer}.multiSelect:hover{--components-multiSelect-border-color: var(--pr-t-color-input-border-hover)}.multiSelect:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multipleSelect-displayer{display:flex;gap:var(--pr-t-spacings-50);flex-wrap:wrap;flex:1}.multipleSelect-displayer-suffix{display:var(--components-multiSelect-displayer-suffix-display);gap:var(--pr-t-spacings-50);flex:1;order:1}.multipleSelect-displayer-chip.chip{min-inline-size:0;--components-chip-backgroundColor: var(--palettes-100, var(--palettes-product-100));--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-product-800));--components-chip-color: var(--palettes-800, var(--palettes-product-800))}.multipleSelect-displayer-chip-value{max-inline-size:8.75rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.multipleSelect-displayer-search{display:block;min-inline-size:2rem;inline-size:auto;flex:1;order:1;border:0;padding:0;outline:none;color:var(--pr-t-color-input-text);font:var(--components-multiSelect-font);background-color:transparent;cursor:pointer}.multipleSelect-displayer-search::placeholder{color:var(--components-multiSelect-placeholder)}.multipleSelect-displayer-label{font:var(--components-multiSelect-font)}.multipleSelect-clear{margin-block-end:var(--pr-t-spacings-50)}.multipleSelect-arrow,.multipleSelect-searchIcon{--icon-size: 1.5rem;color:var(--components-multiSelect-arrow-color);transition-property:transform;transition-duration:var(--commons-animations-durations-standard)}.multipleSelect-searchIcon{display:none}.multipleSelect-pill-displayer-chip{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.multipleSelect-pill-displayer-label{font-weight:var(--pr-t-font-fontWeight-semibold)}.multiSelect-field-icon{order:1}}@layer mods{.multiSelect.mod-S{--components-multiSelect-font: var(--pr-t-font-body-S);--components-multiSelect-padding: var(--pr-t-spacings-75);--components-multiSelect-gap: var(--pr-t-spacings-75)}.multiSelect.mod-S .multipleSelect-arrow,.multiSelect.mod-S .multipleSelect-searchIcon{--icon-size: 1.25rem}.multiSelect.mod-S .multipleSelect-clear.clear,.multiSelect.mod-S .multipleSelect-clear:not(.clear){--components-clear-size: .75rem;--icon-size: .75rem}.multiSelect.mod-S .multipleSelect-displayer-chip.chip,.multiSelect.mod-S .multipleSelect-displayer-chip:not(.chip){--components-chip-font: var(--pr-t-font-body-XS);--components-chip-borderRadius: var(--pr-t-border-radius-small)}.multiSelect.mod-S .multipleSelect-displayer-chip.chip .lucca-icon,.multiSelect.mod-S .multipleSelect-displayer-chip:not(.chip) .lucca-icon{--icon-size: .75rem}.multiSelect.mod-filterPill{--components-multiSelect-displayer-suffix-display: flex;flex-direction:column;align-items:stretch;box-shadow:none;padding:0;gap:0;inline-size:26.5rem;max-inline-size:calc(100vi - 2.5rem)}.multiSelect.mod-filterPill .multipleSelect-displayer{box-shadow:0 0 0 1px var(--components-multiSelect-border-color);border-radius:var(--pr-t-border-radius-input);padding:var(--components-multiSelect-padding);z-index:1;position:relative;max-block-size:min(14rem,80vb);overflow:auto}.multiSelect.mod-filterPill .lu-picker-content{animation:none;box-shadow:none;border-radius:0;background-color:transparent;padding:var(--pr-t-spacings-50);margin:var(--pr-t-spacings-75) calc(var(--pr-t-spacings-100) * -1) calc(var(--pr-t-spacings-100) * -1)}.multiSelect.mod-filterPill .lu-picker-content lu-simple-select-default-option.pr-u-ellipsis{white-space:normal!important}.multiSelect.mod-filterPill:has(.multipleSelect-displayer-search:focus-visible){outline:none}.multiSelect.mod-filterPill .multipleSelect-displayer:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multiSelect.mod-filterPill.is-selected .multipleSelect-displayer-search[readonly]{border:0;clip-path:rect(1px 1px 1px 1px);margin:-1px;overflow:hidden;padding:0;position:absolute;block-size:1px;inline-size:1px;white-space:nowrap;contain:paint}.multiSelect:not(.mod-filterPill).is-selected .multipleSelect-displayer-search:not(:focus),.multiSelect:not(.mod-filterPill).is-selected .multipleSelect-displayer-search[readonly]{border:0;clip-path:rect(1px 1px 1px 1px);margin:-1px;overflow:hidden;padding:0;position:absolute;block-size:1px;inline-size:1px;white-space:nowrap;contain:paint}.multiSelect:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multiSelect:has(.multipleSelect-displayer-search[aria-invalid=true]){--components-multiSelect-border-color: var(--pr-t-color-input-border-critical);--components-multiSelect-background: var(--pr-t-color-input-background-critical);--components-multiSelect-placeholder: var(--pr-t-color-input-text-placeholder-critical)}.multiSelect:has(.multipleSelect-displayer-search:disabled){--components-multiSelect-background: var(--pr-t-color-input-background-disabled);--components-multiSelect-placeholder: var(--commons-disabled-placeholder);--components-multiSelect-arrow-color: var(--pr-t-color-input-icon-disabled);pointer-events:none}.multiSelect:has(.multipleSelect-displayer-search:disabled) .multipleSelect-displayer-chip{--components-chip-backgroundColor: var(--palettes-neutral-200);--components-chip-color: var(--pr-t-color-text-subtle)}.multiSelect:has(.multipleSelect-displayer-search:disabled) .multipleSelect-displayer-chip .chip-kill{display:none}.multiSelect:has([aria-expanded=true]) .multipleSelect-arrow{transform:rotate(180deg)}.multiSelect:not(.mod-noClueIcon):has(.multipleSelect-displayer-search:focus-visible):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-arrow,.multiSelect:not(.mod-noClueIcon):has([aria-expanded=true]):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-arrow{display:none}.multiSelect:not(.mod-noClueIcon):has(.multipleSelect-displayer-search:focus-visible):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-searchIcon,.multiSelect:not(.mod-noClueIcon):has([aria-expanded=true]):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-searchIcon{display:inline-flex;transform:none}}@layer components{.multipleSelect-displayer-filter{min-inline-size:0;display:flex;gap:.5ch}.multipleSelect-displayer-filter:empty{display:none}}@layer components{.clear{--components-clear-display: grid;--components-clear-size: 1rem;--components-clear-background: var(--palettes-800, var(--palettes-neutral-800));--components-clear-cross-color: var(--palettes-0, var(--palettes-neutral-0));--components-clear-background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='16' width='16' fill='none'%3E%3Cpath d='M5.80473 4.86192C5.54438 4.60157 5.12227 4.60157 4.86192 4.86192C4.60157 5.12227 4.60157 5.54438 4.86192 5.80473L7.05718 7.99999L4.86192 10.1953C4.60157 10.4556 4.60157 10.8777 4.86192 11.1381C5.12227 11.3984 5.54438 11.3984 5.80473 11.1381L7.99999 8.9428L10.1953 11.1381C10.4556 11.3984 10.8777 11.3984 11.1381 11.1381C11.3984 10.8777 11.3984 10.4556 11.1381 10.1953L8.9428 7.99999L11.1381 5.80473C11.3984 5.54438 11.3984 5.12227 11.1381 4.86192C10.8777 4.60157 10.4556 4.60157 10.1953 4.86192L7.99999 7.05718L5.80473 4.86192Z' fill='currentColor'/%3E%3C/svg%3E\");padding:0;border:0;inline-size:100%;background-color:transparent;color:inherit;text-align:start;display:block;font:inherit;cursor:pointer;display:var(--components-clear-display);grid-template-columns:1fr;grid-template-rows:1fr;grid-template-areas:\"main\";align-items:normal;flex-shrink:0;inline-size:var(--components-clear-size);block-size:var(--components-clear-size);border-radius:var(--pr-t-border-radius-full)}.clear:before,.clear:after{content:\"\";grid-area:main}.clear:before{border-radius:var(--pr-t-border-radius-full);background-color:var(--components-clear-background)}.clear:after{-webkit-mask-image:var(--components-clear-background-image);mask-image:var(--components-clear-background-image);-webkit-mask-size:var(--components-clear-size);mask-size:var(--components-clear-size);-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--components-clear-cross-color)}.clear:hover{--components-clear-cross-color: var(--palettes-0, var(--palettes-neutral-0));--components-clear-background: var(--palettes-700, var(--palettes-neutral-700))}.clear:focus-visible{outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:2px;border-radius:50%}.clear:active{--components-clear-background: var(--palettes-900, var(--palettes-neutral-900))}.clear .lucca-icon{display:none}}@layer mods{.clear.mod-S{--components-clear-size: .75rem;--icon-size: .75rem}.clear.mod-inverted{--components-clear-cross-color: var(--palettes-800, var(--palettes-neutral-800));--components-clear-background: var(--palettes-0, var(--palettes-neutral-0))}.clear.mod-inverted:hover{--components-clear-background: var(--palettes-50, var(--palettes-neutral-50))}.clear.mod-inverted:active{--components-clear-background: var(--palettes-100, var(--palettes-neutral-100))}.clear[disabled]{cursor:default;--components-clear-cross-color: var(--palettes-neutral-500)}.clear[disabled],.clear[disabled]:hover,.clear[disabled]:active{--components-clear-background: var(--palettes-neutral-300)}.clear[hidden],.filterPill[disabled] .clear,.filterPill:not(.is-filled) .clear,.textfield-input[disabled] .clear,.textfield-input:not(.is-filled) .clear{--components-clear-display: none}.multiSelect.is-selected:has(.multipleSelect-clear) .clear{--components-clear-display: grid}}@layer components{.chip{--components-chip-font: var(--pr-t-font-body-S);--components-chip-backgroundColor: var(--palettes-100, var(--palettes-neutral-100));--components-chip-color: var(--palettes-800, var(--pr-t-color-text));--components-chip-borderRadius: var(--pr-t-border-radius-default);--components-chip-kill-size: .75rem;--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-neutral-800));--components-chip-kill-cross-color: var(--palettes-text, var(--palettes-neutral-text));--components-chip-kill-background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='16' width='16' fill='none'%3E%3Cpath d='M5.80473 4.86192C5.54438 4.60157 5.12227 4.60157 4.86192 4.86192C4.60157 5.12227 4.60157 5.54438 4.86192 5.80473L7.05718 7.99999L4.86192 10.1953C4.60157 10.4556 4.60157 10.8777 4.86192 11.1381C5.12227 11.3984 5.54438 11.3984 5.80473 11.1381L7.99999 8.9428L10.1953 11.1381C10.4556 11.3984 10.8777 11.3984 11.1381 11.1381C11.3984 10.8777 11.3984 10.4556 11.1381 10.1953L8.9428 7.99999L11.1381 5.80473C11.3984 5.54438 11.3984 5.12227 11.1381 4.86192C10.8777 4.60157 10.4556 4.60157 10.1953 4.86192L7.99999 7.05718L5.80473 4.86192Z' fill='currentColor'/%3E%3C/svg%3E\");--components-chip-fontSize: var(--pr-t-font-body-S-fontSize);--components-chip-lineHeight: var(--pr-t-font-body-S-lineHeight);background-color:var(--components-chip-backgroundColor);border:none;border-radius:var(--components-chip-borderRadius);color:var(--components-chip-color);display:inline-flex;align-items:center;position:relative;vertical-align:middle;padding-block:calc(var(--pr-t-spacings-50) / 2);padding-inline:var(--pr-t-spacings-100);font:var(--components-chip-font);max-inline-size:100%}.chip .lucca-icon{--icon-size: 1rem;margin-inline-end:var(--pr-t-spacings-50)}.chip-content{outline:none}.chip-kill{padding:0;border:0;inline-size:100%;background-color:transparent;color:inherit;text-align:start;display:block;font:inherit;display:grid;grid-template-columns:1fr;grid-template-rows:1fr;grid-template-areas:\"main\";place-items:center;inline-size:var(--pr-t-spacings-300);block-size:var(--pr-t-spacings-300);margin:calc(var(--pr-t-spacings-75) * -1);margin-inline-start:var(--pr-t-spacings-25);flex-shrink:0;cursor:pointer}.chip-kill:before,.chip-kill:after{content:\"\";grid-area:main;inline-size:var(--components-chip-kill-size);block-size:var(--components-chip-kill-size)}.chip-kill:before{border-radius:var(--pr-t-border-radius-full);background-color:var(--components-chip-kill-disk-color)}.chip-kill:after{-webkit-mask-image:var(--components-chip-kill-background-image);mask-image:var(--components-chip-kill-background-image);-webkit-mask-size:var(--components-chip-kill-size);mask-size:var(--components-chip-kill-size);-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--components-chip-kill-cross-color)}.chip-kill:hover{--components-chip-kill-disk-color: var(--palettes-700, var(--palettes-neutral-700))}.chip-kill:focus-visible{outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:-4px;border-radius:var(--pr-t-border-radius-full)}.chip-kill:active{--components-chip-kill-disk-color: var(--palettes-900, var(--palettes-neutral-900))}}@layer mods{.chip.mod-S{--components-chip-font: var(--pr-t-font-body-XS);--components-chip-borderRadius: var(--pr-t-border-radius-small)}.chip.mod-S .lucca-icon{--icon-size: .75rem}.chip.mod-unkillable .chip-kill{display:none}.chip.mod-clickable{cursor:pointer;text-decoration:none}.chip.is-disabled{--components-chip-backgroundColor: var(--palettes-neutral-200);--components-chip-color: var(--pr-t-color-text-subtle)}.chip.is-disabled .chip-kill{display:none}.chip:has(.chip-content:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:2px}.chip.mod-product{--components-chip-backgroundColor: var(--palettes-100, var(--palettes-product-100));--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-product-800));--components-chip-color: var(--palettes-800, var(--palettes-product-800))}}\n"], dependencies: [{ kind: "ngmodule", type: LuTooltipModule }, { kind: "directive", type: _LuOptionOutletDirective, selector: "[luOptionOutlet]", inputs: ["luOptionOutlet", "luOptionOutletValue", "luOptionShowNull"] }, { kind: "directive", type: FilterPillDisplayerDirective, selector: "[luFilterPillDisplayer]" }, { kind: "directive", type: FilterPillLabelDirective, selector: "[luFilterPillLabel]" }, { kind: "component", type: ClearComponent, selector: "lu-clear", inputs: ["intl", "size", "disabled", "palette", "inverted"], outputs: ["onClear"], exportAs: ["luClearer"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: _PresentationDisplayDefaultDirective, selector: "[luPresentationDisplayDefault]" }, { kind: "component", type: IconComponent, selector: "lu-icon, pr-icon", inputs: ["icon", "alt", "size", "color", "AI"] }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
623
684
|
}
|
|
624
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
685
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectInputComponent, decorators: [{
|
|
625
686
|
type: Component,
|
|
626
687
|
args: [{ selector: 'lu-multi-select', changeDetection: ChangeDetectionStrategy.OnPush, imports: [
|
|
627
688
|
AsyncPipe,
|
|
@@ -630,7 +691,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
630
691
|
FilterPillDisplayerDirective,
|
|
631
692
|
FilterPillLabelDirective,
|
|
632
693
|
ClearComponent,
|
|
633
|
-
PresentationDisplayDirective,
|
|
634
694
|
CommonModule,
|
|
635
695
|
_PresentationDisplayDefaultDirective,
|
|
636
696
|
IconComponent,
|
|
@@ -655,8 +715,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
655
715
|
'[class.mod-filterPill]': 'filterPillClass',
|
|
656
716
|
'(keydown.control.enter)': 'selectParentOnly()',
|
|
657
717
|
'(keydown.shift.enter)': 'selectChildrenOnly()',
|
|
658
|
-
}, encapsulation: ViewEncapsulation.None, template: "<ng-container *luOptionOutlet=\"valuesTpl(); value: value || []\" />\n\n@if (!filterPillMode) {\n\t@if (hasValue() && clearable() && (disabled$ | async) === false) {\n\t\t<lu-clear class=\"multipleSelect-clear\" (onClear)=\"clearValue($event)\">{{ intl().clear }}</lu-clear>\n\t}\n\n\t<lu-icon icon=\"arrowChevronBottom\" class=\"multipleSelect-arrow\" />\n\t<lu-icon icon=\"searchMagnifyingGlass\" class=\"multipleSelect-searchIcon\" />\n}\n\n<ng-container #filterPillPanelAnchor />\n<ng-container *luFilterPillDisplayer>\n\t<div class=\"multipleSelect-displayer-filter\">\n\t\t@if (useSingleOptionDisplayer() && valueLength() === 1) {\n\t\t\t<div class=\"multipleSelect-pill-displayer-chip\">\n\t\t\t\t<ng-container *luOptionOutlet=\"displayerTpl(); value: value[0]\" />\n\t\t\t</div>\n\t\t}\n\t</div>\n</ng-container>\n<ng-container *luFilterPillLabel=\"let label = label; let colon = colon\">\n\t@let minCount = useSingleOptionDisplayer() ? 1 : 0;\n\t@if (valueLength() > minCount) {\n\t\t<span class=\"multipleSelect-pill-displayer-label\">{{ valueLength() }} {{ filterPillLabelPlural() }}</span>\n\t} @else {\n\t\t{{ label }}\n\t\t@if (valueLength() === 1) {\n\t\t\t{{ colon }}\n\t\t}\n\t}\n</ng-container>\n@if (!ignorePresentation()) {\n\t<ng-container *luPresentationDisplayDefault>\n\t\t@for (v of value; track $index) {\n\t\t\t@if ($last) {\n\t\t\t\t<ng-container *ngTemplateOutlet=\"noComma; context: { $implicit: v }\" />\n\t\t\t} @else {\n\t\t\t\t<ng-container *ngTemplateOutlet=\"comma; context: { $implicit: v }\" />\n\t\t\t}\n\t\t} @empty {\n\t\t\t<span aria-hidden=\"true\" data-content-before=\"\u2013\"></span>\n\t\t}\n\t</ng-container>\n}\n\n<ng-template #comma let-value><ng-container *luOptionOutlet=\"displayerTpl(); value: value\" />, </ng-template>\n\n<ng-template #noComma let-value>\n\t<ng-container *luOptionOutlet=\"displayerTpl(); value: value\" />\n</ng-template>\n", styles: ["@layer components{.multiSelect{--components-multiSelect-font: var(--pr-t-font-body-M);--components-multiSelect-padding: var(--pr-t-spacings-100);--components-multiSelect-gap: var(--pr-t-spacings-100);--components-multiSelect-background: var(--pr-t-color-input-background);--components-multiSelect-border-color: var(--pr-t-color-input-border);--components-multiSelect-placeholder: var(--pr-t-color-input-text-placeholder);--components-multiSelect-arrow-color: var(--pr-t-color-input-icon);--components-multiSelect-displayer-suffix-display: contents;display:flex;box-shadow:0 0 0 1px var(--components-multiSelect-border-color);background-color:var(--components-multiSelect-background);border-radius:var(--pr-t-border-radius-input);padding:var(--components-multiSelect-padding);align-items:flex-end;gap:var(--components-multiSelect-gap);cursor:pointer}.multiSelect:hover{--components-multiSelect-border-color: var(--pr-t-color-input-border-hover)}.multiSelect:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multipleSelect-displayer{display:flex;gap:var(--pr-t-spacings-50);flex-wrap:wrap;flex:1}.multipleSelect-displayer-suffix{display:var(--components-multiSelect-displayer-suffix-display);gap:var(--pr-t-spacings-50);flex:1;order:1}.multipleSelect-displayer-chip.chip{min-inline-size:0;--components-chip-backgroundColor: var(--palettes-100, var(--palettes-product-100));--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-product-800));--components-chip-color: var(--palettes-800, var(--palettes-product-800))}.multipleSelect-displayer-chip-value{max-inline-size:8.75rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.multipleSelect-displayer-search{display:block;min-inline-size:2rem;inline-size:auto;flex:1;order:1;border:0;padding:0;outline:none;color:var(--pr-t-color-input-text);font:var(--components-multiSelect-font);background-color:transparent;cursor:pointer}.multipleSelect-displayer-search::placeholder{color:var(--components-multiSelect-placeholder)}.multipleSelect-displayer-label{font:var(--components-multiSelect-font)}.multipleSelect-clear{margin-block-end:var(--pr-t-spacings-50)}.multipleSelect-arrow,.multipleSelect-searchIcon{--icon-size: 1.5rem;color:var(--components-multiSelect-arrow-color);transition-property:transform;transition-duration:var(--commons-animations-durations-standard)}.multipleSelect-searchIcon{display:none}.multipleSelect-pill-displayer-chip{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.multipleSelect-pill-displayer-label{font-weight:var(--pr-t-font-fontWeight-semibold)}.multiSelect-field-icon{order:1}}@layer mods{.multiSelect.mod-S{--components-multiSelect-font: var(--pr-t-font-body-S);--components-multiSelect-padding: var(--pr-t-spacings-75);--components-multiSelect-gap: var(--pr-t-spacings-75)}.multiSelect.mod-S .multipleSelect-arrow,.multiSelect.mod-S .multipleSelect-searchIcon{--icon-size: 1.25rem}.multiSelect.mod-S .multipleSelect-clear.clear,.multiSelect.mod-S .multipleSelect-clear:not(.clear){--components-clear-size: .75rem;--icon-size: .75rem}.multiSelect.mod-S .multipleSelect-displayer-chip.chip,.multiSelect.mod-S .multipleSelect-displayer-chip:not(.chip){--components-chip-font: var(--pr-t-font-body-XS);--components-chip-borderRadius: var(--pr-t-border-radius-small)}.multiSelect.mod-S .multipleSelect-displayer-chip.chip .lucca-icon,.multiSelect.mod-S .multipleSelect-displayer-chip:not(.chip) .lucca-icon{--icon-size: .75rem}.multiSelect.mod-filterPill{--components-multiSelect-displayer-suffix-display: flex;flex-direction:column;align-items:stretch;box-shadow:none;padding:0;gap:0;inline-size:26.5rem;max-inline-size:calc(100vw - 2.5rem)}.multiSelect.mod-filterPill .multipleSelect-displayer{box-shadow:0 0 0 1px var(--components-multiSelect-border-color);border-radius:var(--pr-t-border-radius-input);padding:var(--components-multiSelect-padding);z-index:1;position:relative;max-block-size:min(14rem,80vh);overflow:auto}.multiSelect.mod-filterPill .lu-picker-content{animation:none;box-shadow:none;border-radius:0;background-color:transparent;padding:var(--pr-t-spacings-50);margin:var(--pr-t-spacings-75) calc(var(--pr-t-spacings-100) * -1) calc(var(--pr-t-spacings-100) * -1)}.multiSelect.mod-filterPill .lu-picker-content lu-simple-select-default-option.pr-u-ellipsis{white-space:normal!important}.multiSelect.mod-filterPill:has(.multipleSelect-displayer-search:focus-visible){outline:none}.multiSelect.mod-filterPill .multipleSelect-displayer:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multiSelect.mod-filterPill.is-selected .multipleSelect-displayer-search[readonly]{border:0;clip-path:rect(1px 1px 1px 1px);margin:-1px;overflow:hidden;padding:0;position:absolute;block-size:1px;inline-size:1px;white-space:nowrap;contain:paint}.multiSelect:not(.mod-filterPill).is-selected .multipleSelect-displayer-search:not(:focus),.multiSelect:not(.mod-filterPill).is-selected .multipleSelect-displayer-search[readonly]{border:0;clip-path:rect(1px 1px 1px 1px);margin:-1px;overflow:hidden;padding:0;position:absolute;block-size:1px;inline-size:1px;white-space:nowrap;contain:paint}.multiSelect:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multiSelect:has(.multipleSelect-displayer-search[aria-invalid=true]){--components-multiSelect-border-color: var(--pr-t-color-input-border-critical);--components-multiSelect-background: var(--pr-t-color-input-background-critical);--components-multiSelect-placeholder: var(--pr-t-color-input-text-placeholder-critical)}.multiSelect:has(.multipleSelect-displayer-search:disabled){--components-multiSelect-background: var(--commons-disabled-background);--components-multiSelect-placeholder: var(--commons-disabled-placeholder);--components-multiSelect-arrow-color: var(--pr-t-color-input-icon-disabled);pointer-events:none}.multiSelect:has(.multipleSelect-displayer-search:disabled) .multipleSelect-displayer-chip{--components-chip-backgroundColor: var(--palettes-neutral-200);--components-chip-color: var(--pr-t-color-text-subtle)}.multiSelect:has(.multipleSelect-displayer-search:disabled) .multipleSelect-displayer-chip .chip-kill{display:none}.multiSelect:has([aria-expanded=true]) .multipleSelect-arrow{transform:rotate(180deg)}.multiSelect:not(.mod-noClueIcon):has(.multipleSelect-displayer-search:focus-visible):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-arrow,.multiSelect:not(.mod-noClueIcon):has([aria-expanded=true]):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-arrow{display:none}.multiSelect:not(.mod-noClueIcon):has(.multipleSelect-displayer-search:focus-visible):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-searchIcon,.multiSelect:not(.mod-noClueIcon):has([aria-expanded=true]):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-searchIcon{display:inline-flex;transform:none}}@layer components{.multipleSelect-displayer-filter{min-inline-size:0;display:flex;gap:.5ch}.multipleSelect-displayer-filter:empty{display:none}}@layer components{.clear{--components-clear-display: grid;--components-clear-size: 1rem;--components-clear-background: var(--palettes-800, var(--palettes-neutral-800));--components-clear-cross-color: var(--palettes-0, var(--palettes-neutral-0));--components-clear-background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='16' width='16' fill='none'%3E%3Cpath d='M5.80473 4.86192C5.54438 4.60157 5.12227 4.60157 4.86192 4.86192C4.60157 5.12227 4.60157 5.54438 4.86192 5.80473L7.05718 7.99999L4.86192 10.1953C4.60157 10.4556 4.60157 10.8777 4.86192 11.1381C5.12227 11.3984 5.54438 11.3984 5.80473 11.1381L7.99999 8.9428L10.1953 11.1381C10.4556 11.3984 10.8777 11.3984 11.1381 11.1381C11.3984 10.8777 11.3984 10.4556 11.1381 10.1953L8.9428 7.99999L11.1381 5.80473C11.3984 5.54438 11.3984 5.12227 11.1381 4.86192C10.8777 4.60157 10.4556 4.60157 10.1953 4.86192L7.99999 7.05718L5.80473 4.86192Z' fill='currentColor'/%3E%3C/svg%3E\");padding:0;border:0;inline-size:100%;background-color:transparent;color:inherit;text-align:start;display:block;font:inherit;cursor:pointer;display:var(--components-clear-display);grid-template-columns:1fr;grid-template-rows:1fr;grid-template-areas:\"main\";align-items:normal;flex-shrink:0;inline-size:var(--components-clear-size);block-size:var(--components-clear-size);border-radius:var(--pr-t-border-radius-full)}.clear:before,.clear:after{content:\"\";grid-area:main}.clear:before{border-radius:var(--pr-t-border-radius-full);background-color:var(--components-clear-background)}.clear:after{-webkit-mask-image:var(--components-clear-background-image);mask-image:var(--components-clear-background-image);-webkit-mask-size:var(--components-clear-size);mask-size:var(--components-clear-size);-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--components-clear-cross-color)}.clear:hover{--components-clear-cross-color: var(--palettes-0, var(--palettes-neutral-0));--components-clear-background: var(--palettes-700, var(--palettes-neutral-700))}.clear:focus-visible{outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:2px;border-radius:50%}.clear:active{--components-clear-background: var(--palettes-900, var(--palettes-neutral-900))}.clear .lucca-icon{display:none}}@layer mods{.clear.mod-S{--components-clear-size: .75rem;--icon-size: .75rem}.clear.mod-inverted{--components-clear-cross-color: var(--palettes-800, var(--palettes-neutral-800));--components-clear-background: var(--palettes-0, var(--palettes-neutral-0))}.clear.mod-inverted:hover{--components-clear-background: var(--palettes-50, var(--palettes-neutral-50))}.clear.mod-inverted:active{--components-clear-background: var(--palettes-100, var(--palettes-neutral-100))}.clear[disabled]{cursor:default;--components-clear-cross-color: var(--palettes-neutral-500)}.clear[disabled],.clear[disabled]:hover,.clear[disabled]:active{--components-clear-background: var(--palettes-neutral-300)}.clear[hidden],.filterPill[disabled] .clear,.filterPill:not(.is-filled) .clear,.textfield-input[disabled] .clear,.textfield-input:not(.is-filled) .clear{--components-clear-display: none}.multiSelect.is-selected:has(.multipleSelect-clear) .clear{--components-clear-display: grid}}@layer components{.chip{--components-chip-font: var(--pr-t-font-body-S);--components-chip-backgroundColor: var(--palettes-100, var(--palettes-neutral-100));--components-chip-color: var(--palettes-800, var(--pr-t-color-text));--components-chip-borderRadius: var(--pr-t-border-radius-default);--components-chip-kill-size: .75rem;--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-neutral-800));--components-chip-kill-cross-color: var(--palettes-text, var(--palettes-neutral-text));--components-chip-kill-background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='16' width='16' fill='none'%3E%3Cpath d='M5.80473 4.86192C5.54438 4.60157 5.12227 4.60157 4.86192 4.86192C4.60157 5.12227 4.60157 5.54438 4.86192 5.80473L7.05718 7.99999L4.86192 10.1953C4.60157 10.4556 4.60157 10.8777 4.86192 11.1381C5.12227 11.3984 5.54438 11.3984 5.80473 11.1381L7.99999 8.9428L10.1953 11.1381C10.4556 11.3984 10.8777 11.3984 11.1381 11.1381C11.3984 10.8777 11.3984 10.4556 11.1381 10.1953L8.9428 7.99999L11.1381 5.80473C11.3984 5.54438 11.3984 5.12227 11.1381 4.86192C10.8777 4.60157 10.4556 4.60157 10.1953 4.86192L7.99999 7.05718L5.80473 4.86192Z' fill='currentColor'/%3E%3C/svg%3E\");--components-chip-fontSize: var(--pr-t-font-body-S-fontSize);--components-chip-lineHeight: var(--pr-t-font-body-S-lineHeight);background-color:var(--components-chip-backgroundColor);border:none;border-radius:var(--components-chip-borderRadius);color:var(--components-chip-color);display:inline-flex;align-items:center;position:relative;vertical-align:middle;padding-block:calc(var(--pr-t-spacings-50) / 2);padding-inline:var(--pr-t-spacings-100);font:var(--components-chip-font);max-inline-size:100%}.chip .lucca-icon{--icon-size: 1rem;margin-inline-end:var(--pr-t-spacings-50)}.chip-content{outline:none}.chip-kill{padding:0;border:0;inline-size:100%;background-color:transparent;color:inherit;text-align:start;display:block;font:inherit;display:grid;grid-template-columns:1fr;grid-template-rows:1fr;grid-template-areas:\"main\";place-items:center;inline-size:var(--pr-t-spacings-300);block-size:var(--pr-t-spacings-300);margin:calc(var(--pr-t-spacings-75) * -1);margin-inline-start:var(--pr-t-spacings-25);flex-shrink:0;cursor:pointer}.chip-kill:before,.chip-kill:after{content:\"\";grid-area:main;inline-size:var(--components-chip-kill-size);block-size:var(--components-chip-kill-size)}.chip-kill:before{border-radius:var(--pr-t-border-radius-full);background-color:var(--components-chip-kill-disk-color)}.chip-kill:after{-webkit-mask-image:var(--components-chip-kill-background-image);mask-image:var(--components-chip-kill-background-image);-webkit-mask-size:var(--components-chip-kill-size);mask-size:var(--components-chip-kill-size);-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--components-chip-kill-cross-color)}.chip-kill:hover{--components-chip-kill-disk-color: var(--palettes-700, var(--palettes-neutral-700))}.chip-kill:focus-visible{outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:-4px;border-radius:var(--pr-t-border-radius-full)}.chip-kill:active{--components-chip-kill-disk-color: var(--palettes-900, var(--palettes-neutral-900))}}@layer mods{.chip.mod-S{--components-chip-font: var(--pr-t-font-body-XS);--components-chip-borderRadius: var(--pr-t-border-radius-small)}.chip.mod-S .lucca-icon{--icon-size: .75rem}.chip.mod-unkillable .chip-kill{display:none}.chip.mod-clickable{cursor:pointer;text-decoration:none}.chip.is-disabled{--components-chip-backgroundColor: var(--palettes-neutral-200);--components-chip-color: var(--pr-t-color-text-subtle)}.chip.is-disabled .chip-kill{display:none}.chip:has(.chip-content:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:2px}.chip.mod-product{--components-chip-backgroundColor: var(--palettes-100, var(--palettes-product-100));--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-product-800));--components-chip-color: var(--palettes-800, var(--palettes-product-800))}}\n"] }]
|
|
659
|
-
}], propDecorators: { intl: [{ type: i0.Input, args: [{ isSignal: true, alias: "intl", required: false }] }], valuesTpl: [{ type: i0.Input, args: [{ isSignal: true, alias: "valuesTpl", required: false }] }, { type: i0.Output, args: ["valuesTplChange"] }], maxValuesShown: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxValuesShown", required: false }] }], keepSearchAfterSelection: [{ type: i0.Input, args: [{ isSignal: true, alias: "keepSearchAfterSelection", required: false }] }], filterPillLabelPlural: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterPillLabelPlural", required: false }] }], filterPillPanelAnchorRef: [{ type: i0.ViewChild, args: ['filterPillPanelAnchor', { ...{ read: ViewContainerRef }, isSignal: true }] }] } });
|
|
718
|
+
}, encapsulation: ViewEncapsulation.None, template: "<ng-container *luOptionOutlet=\"valuesTpl(); value: value || []\" />\n\n@if (!filterPillMode) {\n\t@if (hasValue() && clearable() && (disabled$ | async) === false) {\n\t\t<lu-clear class=\"multipleSelect-clear\" (onClear)=\"clearValue($event)\">{{ intl().clear }}</lu-clear>\n\t}\n\n\t<lu-icon icon=\"arrowChevronBottom\" class=\"multipleSelect-arrow\" />\n\t<lu-icon icon=\"searchMagnifyingGlass\" class=\"multipleSelect-searchIcon\" />\n}\n\n<ng-container #filterPillPanelAnchor />\n<ng-container *luFilterPillDisplayer>\n\t<div class=\"multipleSelect-displayer-filter\">\n\t\t@if (useSingleOptionDisplayer() && valueLength() === 1 && singleOptionForDisplay() !== undefined) {\n\t\t\t<div class=\"multipleSelect-pill-displayer-chip\">\n\t\t\t\t<ng-container *luOptionOutlet=\"displayerTpl(); value: singleOptionForDisplay()\" />\n\t\t\t</div>\n\t\t}\n\t</div>\n</ng-container>\n<ng-container *luFilterPillLabel=\"let label = label; let colon = colon\">\n\t@let minCount = useSingleOptionDisplayer() ? 1 : 0;\n\t@if (valueLength() > minCount) {\n\t\t<span class=\"multipleSelect-pill-displayer-label\">{{ filterPillLabelPluralValue() }}</span>\n\t} @else {\n\t\t{{ label }}{{ valueLength() === 1 ? colon : \"\" }}\n\t}\n</ng-container>\n@if (!ignorePresentation()) {\n\t<ng-container *luPresentationDisplayDefault>\n\t\t@for (v of value; track $index) {\n\t\t\t<ng-container *luOptionOutlet=\"displayerTpl(); value: v\" />\n\n\t\t\t@let separator = presentationSeparators()[$index];\n\n\t\t\t@if (separator) {\n\t\t\t\t<ng-container>{{ separator }}</ng-container>\n\t\t\t}\n\t\t} @empty {\n\t\t\t<span aria-hidden=\"true\" data-content-before=\"\u2013\"></span>\n\t\t}\n\t</ng-container>\n}\n", styles: ["@layer components{.multiSelect{--components-multiSelect-font: var(--pr-t-font-body-M);--components-multiSelect-padding: var(--pr-t-spacings-100);--components-multiSelect-gap: var(--pr-t-spacings-100);--components-multiSelect-background: var(--pr-t-color-input-background);--components-multiSelect-border-color: var(--pr-t-color-input-border);--components-multiSelect-placeholder: var(--pr-t-color-input-text-placeholder);--components-multiSelect-arrow-color: var(--pr-t-color-input-icon);--components-multiSelect-displayer-suffix-display: contents;display:flex;box-shadow:0 0 0 1px var(--components-multiSelect-border-color);background-color:var(--components-multiSelect-background);border-radius:var(--pr-t-border-radius-input);padding:var(--components-multiSelect-padding);align-items:flex-end;gap:var(--components-multiSelect-gap);cursor:pointer}.multiSelect:hover{--components-multiSelect-border-color: var(--pr-t-color-input-border-hover)}.multiSelect:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multipleSelect-displayer{display:flex;gap:var(--pr-t-spacings-50);flex-wrap:wrap;flex:1}.multipleSelect-displayer-suffix{display:var(--components-multiSelect-displayer-suffix-display);gap:var(--pr-t-spacings-50);flex:1;order:1}.multipleSelect-displayer-chip.chip{min-inline-size:0;--components-chip-backgroundColor: var(--palettes-100, var(--palettes-product-100));--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-product-800));--components-chip-color: var(--palettes-800, var(--palettes-product-800))}.multipleSelect-displayer-chip-value{max-inline-size:8.75rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.multipleSelect-displayer-search{display:block;min-inline-size:2rem;inline-size:auto;flex:1;order:1;border:0;padding:0;outline:none;color:var(--pr-t-color-input-text);font:var(--components-multiSelect-font);background-color:transparent;cursor:pointer}.multipleSelect-displayer-search::placeholder{color:var(--components-multiSelect-placeholder)}.multipleSelect-displayer-label{font:var(--components-multiSelect-font)}.multipleSelect-clear{margin-block-end:var(--pr-t-spacings-50)}.multipleSelect-arrow,.multipleSelect-searchIcon{--icon-size: 1.5rem;color:var(--components-multiSelect-arrow-color);transition-property:transform;transition-duration:var(--commons-animations-durations-standard)}.multipleSelect-searchIcon{display:none}.multipleSelect-pill-displayer-chip{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.multipleSelect-pill-displayer-label{font-weight:var(--pr-t-font-fontWeight-semibold)}.multiSelect-field-icon{order:1}}@layer mods{.multiSelect.mod-S{--components-multiSelect-font: var(--pr-t-font-body-S);--components-multiSelect-padding: var(--pr-t-spacings-75);--components-multiSelect-gap: var(--pr-t-spacings-75)}.multiSelect.mod-S .multipleSelect-arrow,.multiSelect.mod-S .multipleSelect-searchIcon{--icon-size: 1.25rem}.multiSelect.mod-S .multipleSelect-clear.clear,.multiSelect.mod-S .multipleSelect-clear:not(.clear){--components-clear-size: .75rem;--icon-size: .75rem}.multiSelect.mod-S .multipleSelect-displayer-chip.chip,.multiSelect.mod-S .multipleSelect-displayer-chip:not(.chip){--components-chip-font: var(--pr-t-font-body-XS);--components-chip-borderRadius: var(--pr-t-border-radius-small)}.multiSelect.mod-S .multipleSelect-displayer-chip.chip .lucca-icon,.multiSelect.mod-S .multipleSelect-displayer-chip:not(.chip) .lucca-icon{--icon-size: .75rem}.multiSelect.mod-filterPill{--components-multiSelect-displayer-suffix-display: flex;flex-direction:column;align-items:stretch;box-shadow:none;padding:0;gap:0;inline-size:26.5rem;max-inline-size:calc(100vi - 2.5rem)}.multiSelect.mod-filterPill .multipleSelect-displayer{box-shadow:0 0 0 1px var(--components-multiSelect-border-color);border-radius:var(--pr-t-border-radius-input);padding:var(--components-multiSelect-padding);z-index:1;position:relative;max-block-size:min(14rem,80vb);overflow:auto}.multiSelect.mod-filterPill .lu-picker-content{animation:none;box-shadow:none;border-radius:0;background-color:transparent;padding:var(--pr-t-spacings-50);margin:var(--pr-t-spacings-75) calc(var(--pr-t-spacings-100) * -1) calc(var(--pr-t-spacings-100) * -1)}.multiSelect.mod-filterPill .lu-picker-content lu-simple-select-default-option.pr-u-ellipsis{white-space:normal!important}.multiSelect.mod-filterPill:has(.multipleSelect-displayer-search:focus-visible){outline:none}.multiSelect.mod-filterPill .multipleSelect-displayer:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multiSelect.mod-filterPill.is-selected .multipleSelect-displayer-search[readonly]{border:0;clip-path:rect(1px 1px 1px 1px);margin:-1px;overflow:hidden;padding:0;position:absolute;block-size:1px;inline-size:1px;white-space:nowrap;contain:paint}.multiSelect:not(.mod-filterPill).is-selected .multipleSelect-displayer-search:not(:focus),.multiSelect:not(.mod-filterPill).is-selected .multipleSelect-displayer-search[readonly]{border:0;clip-path:rect(1px 1px 1px 1px);margin:-1px;overflow:hidden;padding:0;position:absolute;block-size:1px;inline-size:1px;white-space:nowrap;contain:paint}.multiSelect:has(.multipleSelect-displayer-search:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:3px}.multiSelect:has(.multipleSelect-displayer-search[aria-invalid=true]){--components-multiSelect-border-color: var(--pr-t-color-input-border-critical);--components-multiSelect-background: var(--pr-t-color-input-background-critical);--components-multiSelect-placeholder: var(--pr-t-color-input-text-placeholder-critical)}.multiSelect:has(.multipleSelect-displayer-search:disabled){--components-multiSelect-background: var(--pr-t-color-input-background-disabled);--components-multiSelect-placeholder: var(--commons-disabled-placeholder);--components-multiSelect-arrow-color: var(--pr-t-color-input-icon-disabled);pointer-events:none}.multiSelect:has(.multipleSelect-displayer-search:disabled) .multipleSelect-displayer-chip{--components-chip-backgroundColor: var(--palettes-neutral-200);--components-chip-color: var(--pr-t-color-text-subtle)}.multiSelect:has(.multipleSelect-displayer-search:disabled) .multipleSelect-displayer-chip .chip-kill{display:none}.multiSelect:has([aria-expanded=true]) .multipleSelect-arrow{transform:rotate(180deg)}.multiSelect:not(.mod-noClueIcon):has(.multipleSelect-displayer-search:focus-visible):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-arrow,.multiSelect:not(.mod-noClueIcon):has([aria-expanded=true]):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-arrow{display:none}.multiSelect:not(.mod-noClueIcon):has(.multipleSelect-displayer-search:focus-visible):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-searchIcon,.multiSelect:not(.mod-noClueIcon):has([aria-expanded=true]):not(:has(.multipleSelect-displayer-search:read-only)) .multipleSelect-searchIcon{display:inline-flex;transform:none}}@layer components{.multipleSelect-displayer-filter{min-inline-size:0;display:flex;gap:.5ch}.multipleSelect-displayer-filter:empty{display:none}}@layer components{.clear{--components-clear-display: grid;--components-clear-size: 1rem;--components-clear-background: var(--palettes-800, var(--palettes-neutral-800));--components-clear-cross-color: var(--palettes-0, var(--palettes-neutral-0));--components-clear-background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='16' width='16' fill='none'%3E%3Cpath d='M5.80473 4.86192C5.54438 4.60157 5.12227 4.60157 4.86192 4.86192C4.60157 5.12227 4.60157 5.54438 4.86192 5.80473L7.05718 7.99999L4.86192 10.1953C4.60157 10.4556 4.60157 10.8777 4.86192 11.1381C5.12227 11.3984 5.54438 11.3984 5.80473 11.1381L7.99999 8.9428L10.1953 11.1381C10.4556 11.3984 10.8777 11.3984 11.1381 11.1381C11.3984 10.8777 11.3984 10.4556 11.1381 10.1953L8.9428 7.99999L11.1381 5.80473C11.3984 5.54438 11.3984 5.12227 11.1381 4.86192C10.8777 4.60157 10.4556 4.60157 10.1953 4.86192L7.99999 7.05718L5.80473 4.86192Z' fill='currentColor'/%3E%3C/svg%3E\");padding:0;border:0;inline-size:100%;background-color:transparent;color:inherit;text-align:start;display:block;font:inherit;cursor:pointer;display:var(--components-clear-display);grid-template-columns:1fr;grid-template-rows:1fr;grid-template-areas:\"main\";align-items:normal;flex-shrink:0;inline-size:var(--components-clear-size);block-size:var(--components-clear-size);border-radius:var(--pr-t-border-radius-full)}.clear:before,.clear:after{content:\"\";grid-area:main}.clear:before{border-radius:var(--pr-t-border-radius-full);background-color:var(--components-clear-background)}.clear:after{-webkit-mask-image:var(--components-clear-background-image);mask-image:var(--components-clear-background-image);-webkit-mask-size:var(--components-clear-size);mask-size:var(--components-clear-size);-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--components-clear-cross-color)}.clear:hover{--components-clear-cross-color: var(--palettes-0, var(--palettes-neutral-0));--components-clear-background: var(--palettes-700, var(--palettes-neutral-700))}.clear:focus-visible{outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:2px;border-radius:50%}.clear:active{--components-clear-background: var(--palettes-900, var(--palettes-neutral-900))}.clear .lucca-icon{display:none}}@layer mods{.clear.mod-S{--components-clear-size: .75rem;--icon-size: .75rem}.clear.mod-inverted{--components-clear-cross-color: var(--palettes-800, var(--palettes-neutral-800));--components-clear-background: var(--palettes-0, var(--palettes-neutral-0))}.clear.mod-inverted:hover{--components-clear-background: var(--palettes-50, var(--palettes-neutral-50))}.clear.mod-inverted:active{--components-clear-background: var(--palettes-100, var(--palettes-neutral-100))}.clear[disabled]{cursor:default;--components-clear-cross-color: var(--palettes-neutral-500)}.clear[disabled],.clear[disabled]:hover,.clear[disabled]:active{--components-clear-background: var(--palettes-neutral-300)}.clear[hidden],.filterPill[disabled] .clear,.filterPill:not(.is-filled) .clear,.textfield-input[disabled] .clear,.textfield-input:not(.is-filled) .clear{--components-clear-display: none}.multiSelect.is-selected:has(.multipleSelect-clear) .clear{--components-clear-display: grid}}@layer components{.chip{--components-chip-font: var(--pr-t-font-body-S);--components-chip-backgroundColor: var(--palettes-100, var(--palettes-neutral-100));--components-chip-color: var(--palettes-800, var(--pr-t-color-text));--components-chip-borderRadius: var(--pr-t-border-radius-default);--components-chip-kill-size: .75rem;--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-neutral-800));--components-chip-kill-cross-color: var(--palettes-text, var(--palettes-neutral-text));--components-chip-kill-background-image: url(\"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='16' width='16' fill='none'%3E%3Cpath d='M5.80473 4.86192C5.54438 4.60157 5.12227 4.60157 4.86192 4.86192C4.60157 5.12227 4.60157 5.54438 4.86192 5.80473L7.05718 7.99999L4.86192 10.1953C4.60157 10.4556 4.60157 10.8777 4.86192 11.1381C5.12227 11.3984 5.54438 11.3984 5.80473 11.1381L7.99999 8.9428L10.1953 11.1381C10.4556 11.3984 10.8777 11.3984 11.1381 11.1381C11.3984 10.8777 11.3984 10.4556 11.1381 10.1953L8.9428 7.99999L11.1381 5.80473C11.3984 5.54438 11.3984 5.12227 11.1381 4.86192C10.8777 4.60157 10.4556 4.60157 10.1953 4.86192L7.99999 7.05718L5.80473 4.86192Z' fill='currentColor'/%3E%3C/svg%3E\");--components-chip-fontSize: var(--pr-t-font-body-S-fontSize);--components-chip-lineHeight: var(--pr-t-font-body-S-lineHeight);background-color:var(--components-chip-backgroundColor);border:none;border-radius:var(--components-chip-borderRadius);color:var(--components-chip-color);display:inline-flex;align-items:center;position:relative;vertical-align:middle;padding-block:calc(var(--pr-t-spacings-50) / 2);padding-inline:var(--pr-t-spacings-100);font:var(--components-chip-font);max-inline-size:100%}.chip .lucca-icon{--icon-size: 1rem;margin-inline-end:var(--pr-t-spacings-50)}.chip-content{outline:none}.chip-kill{padding:0;border:0;inline-size:100%;background-color:transparent;color:inherit;text-align:start;display:block;font:inherit;display:grid;grid-template-columns:1fr;grid-template-rows:1fr;grid-template-areas:\"main\";place-items:center;inline-size:var(--pr-t-spacings-300);block-size:var(--pr-t-spacings-300);margin:calc(var(--pr-t-spacings-75) * -1);margin-inline-start:var(--pr-t-spacings-25);flex-shrink:0;cursor:pointer}.chip-kill:before,.chip-kill:after{content:\"\";grid-area:main;inline-size:var(--components-chip-kill-size);block-size:var(--components-chip-kill-size)}.chip-kill:before{border-radius:var(--pr-t-border-radius-full);background-color:var(--components-chip-kill-disk-color)}.chip-kill:after{-webkit-mask-image:var(--components-chip-kill-background-image);mask-image:var(--components-chip-kill-background-image);-webkit-mask-size:var(--components-chip-kill-size);mask-size:var(--components-chip-kill-size);-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;background-color:var(--components-chip-kill-cross-color)}.chip-kill:hover{--components-chip-kill-disk-color: var(--palettes-700, var(--palettes-neutral-700))}.chip-kill:focus-visible{outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:-4px;border-radius:var(--pr-t-border-radius-full)}.chip-kill:active{--components-chip-kill-disk-color: var(--palettes-900, var(--palettes-neutral-900))}}@layer mods{.chip.mod-S{--components-chip-font: var(--pr-t-font-body-XS);--components-chip-borderRadius: var(--pr-t-border-radius-small)}.chip.mod-S .lucca-icon{--icon-size: .75rem}.chip.mod-unkillable .chip-kill{display:none}.chip.mod-clickable{cursor:pointer;text-decoration:none}.chip.is-disabled{--components-chip-backgroundColor: var(--palettes-neutral-200);--components-chip-color: var(--pr-t-color-text-subtle)}.chip.is-disabled .chip-kill{display:none}.chip:has(.chip-content:focus-visible){outline:2px solid var(--palettes-700, var(--palettes-product-700));outline-offset:2px}.chip.mod-product{--components-chip-backgroundColor: var(--palettes-100, var(--palettes-product-100));--components-chip-kill-disk-color: var(--palettes-800, var(--palettes-product-800));--components-chip-color: var(--palettes-800, var(--palettes-product-800))}}\n"] }]
|
|
719
|
+
}], propDecorators: { intl: [{ type: i0.Input, args: [{ isSignal: true, alias: "intl", required: false }] }], valuesTpl: [{ type: i0.Input, args: [{ isSignal: true, alias: "valuesTpl", required: false }] }, { type: i0.Output, args: ["valuesTplChange"] }], maxValuesShown: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxValuesShown", required: false }] }], keepSearchAfterSelection: [{ type: i0.Input, args: [{ isSignal: true, alias: "keepSearchAfterSelection", required: false }] }], filterPillLabelPlural: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterPillLabelPlural", required: false }] }], filterPillLabelPluralFn: [{ type: i0.Input, args: [{ isSignal: true, alias: "filterPillLabelPluralFn", required: false }] }], filterPillPanelAnchorRef: [{ type: i0.ViewChild, args: ['filterPillPanelAnchor', { ...{ read: ViewContainerRef }, isSignal: true }] }] } });
|
|
660
720
|
|
|
661
721
|
const Translations = {
|
|
662
722
|
'nl-BE': {
|
|
@@ -723,6 +783,7 @@ const luMultiSelectDisplayerTranslations = Translations;
|
|
|
723
783
|
const MULTI_SELECT_WITH_SELECT_ALL_CONTEXT = new InjectionToken('LuMultiSelectWithSelectAllContext');
|
|
724
784
|
|
|
725
785
|
class LuMultiSelectDisplayerInputDirective {
|
|
786
|
+
#injector;
|
|
726
787
|
get panelOpen() {
|
|
727
788
|
return this.#panelOpen();
|
|
728
789
|
}
|
|
@@ -756,6 +817,7 @@ class LuMultiSelectDisplayerInputDirective {
|
|
|
756
817
|
this.context = inject(LU_OPTION_CONTEXT);
|
|
757
818
|
this.elementRef = inject(ElementRef);
|
|
758
819
|
this.destroyRef = inject(DestroyRef);
|
|
820
|
+
this.#injector = inject(Injector);
|
|
759
821
|
this.#panelOpen = toSignal(this.select.isPanelOpen$);
|
|
760
822
|
this.#activeDescendant = toSignal(this.select.activeDescendant$);
|
|
761
823
|
this.#disabled = toSignal(this.select.disabled$);
|
|
@@ -778,6 +840,14 @@ class LuMultiSelectDisplayerInputDirective {
|
|
|
778
840
|
}
|
|
779
841
|
}
|
|
780
842
|
ngOnInit() {
|
|
843
|
+
// When the displayer swaps variants while the panel is open (e.g. the content-displayer
|
|
844
|
+
// gives way to the default displayer on the first selection), the previously focused input
|
|
845
|
+
// is destroyed. focusInput$ is a plain Subject, so its emission fires before this new input
|
|
846
|
+
// has subscribed and is lost — focus falls back to <body> and keyboard navigation dies.
|
|
847
|
+
// A freshly mounted displayer input owns focus whenever the panel is open.
|
|
848
|
+
if (this.select.isPanelOpen) {
|
|
849
|
+
afterNextRender(() => this.elementRef.nativeElement.focus(), { injector: this.#injector });
|
|
850
|
+
}
|
|
781
851
|
this.select.focusInput$.pipe(takeUntilDestroyed(this.destroyRef)).subscribe((data) => {
|
|
782
852
|
if (!data?.keepClue) {
|
|
783
853
|
this.#clearText();
|
|
@@ -794,10 +864,10 @@ class LuMultiSelectDisplayerInputDirective {
|
|
|
794
864
|
this.select.clueChanged('');
|
|
795
865
|
}
|
|
796
866
|
}
|
|
797
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
798
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.
|
|
867
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectDisplayerInputDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
868
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.0.8", type: LuMultiSelectDisplayerInputDirective, isStandalone: true, selector: "[luMultiSelectDisplayerInput]", host: { attributes: { "aria-haspopup": "listbox", "role": "combobox", "type": "text" }, listeners: { "input": "onInput()" }, properties: { "attr.aria-expanded": "panelOpen", "attr.aria-activedescendant": "activeDescendant", "attr.aria-controls": "controls", "attr.disabled": "disabled", "attr.placeholder": "placeholder", "attr.readonly": "readonly" }, classAttribute: "multipleSelect-displayer-search" }, hostDirectives: [{ directive: i1.InputDirective }], ngImport: i0 }); }
|
|
799
869
|
}
|
|
800
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
870
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectDisplayerInputDirective, decorators: [{
|
|
801
871
|
type: Directive,
|
|
802
872
|
args: [{
|
|
803
873
|
selector: '[luMultiSelectDisplayerInput]',
|
|
@@ -826,44 +896,45 @@ class LuMultiSelectAllDisplayerComponent {
|
|
|
826
896
|
...(ngDevMode ? [{ debugName: "isFilled" }] : /* istanbul ignore next */ []));
|
|
827
897
|
this.isIncludeMode = computed(() => this.selectAllContext.mode() === 'include', /* @ts-ignore */
|
|
828
898
|
...(ngDevMode ? [{ debugName: "isIncludeMode" }] : /* istanbul ignore next */ []));
|
|
829
|
-
this.
|
|
899
|
+
this.displayerLabelValue = this.selectAllContext.displayerLabelValue;
|
|
830
900
|
this.displayerCount = this.selectAllContext.displayerCount;
|
|
901
|
+
this.displayedSingleOption = this.select.singleOptionForDisplay;
|
|
831
902
|
this.intl = input(...intlInputOptions(LU_MULTI_SELECT_DISPLAYER_TRANSLATIONS), /* @ts-ignore */
|
|
832
903
|
...(ngDevMode ? [{ debugName: "intl" }] : /* istanbul ignore next */ []));
|
|
833
904
|
this.disabled = toSignal(this.select.disabled$);
|
|
834
|
-
this.inputElementRef = viewChild.required(LuMultiSelectDisplayerInputDirective, { read: ElementRef });
|
|
905
|
+
this.inputElementRef = viewChild.required(LuMultiSelectDisplayerInputDirective, { ...(ngDevMode ? { debugName: "inputElementRef" } : /* istanbul ignore next */ {}), read: ElementRef });
|
|
835
906
|
this.#injector = inject(Injector);
|
|
836
907
|
}
|
|
837
908
|
#injector;
|
|
838
909
|
unselectOption(option, $event) {
|
|
839
910
|
$event.stopPropagation();
|
|
840
911
|
$event.preventDefault();
|
|
841
|
-
this.select.updateValue(this.select.value?.filter((o) => o !== option) ?? [], true);
|
|
912
|
+
this.select.updateValue(this.isIncludeMode() ? (this.select.value?.filter((o) => o !== option) ?? []) : [...(this.select.value ?? []), option], true);
|
|
842
913
|
afterNextRender(() => {
|
|
843
914
|
this.select.panelRef?.updatePosition();
|
|
844
915
|
this.inputElementRef().nativeElement.focus();
|
|
845
916
|
}, { injector: this.#injector });
|
|
846
917
|
}
|
|
847
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
848
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.
|
|
918
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectAllDisplayerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
919
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: LuMultiSelectAllDisplayerComponent, isStandalone: true, selector: "lu-multi-select-all-displayer", inputs: { intl: { classPropertyName: "intl", publicName: "intl", isSignal: true, isRequired: false, transformFunction: null } }, viewQueries: [{ propertyName: "inputElementRef", first: true, predicate: LuMultiSelectDisplayerInputDirective, descendants: true, read: ElementRef, isSignal: true }], ngImport: i0, template: `
|
|
849
920
|
<div class="multipleSelect-displayer mod-filter" [class.is-filled]="isFilled()">
|
|
850
921
|
<input type="text" luMultiSelectDisplayerInput />
|
|
851
922
|
|
|
852
923
|
@if (displayerCount() !== null) {
|
|
853
924
|
<div class="multipleSelect-displayer-filter">
|
|
854
|
-
@if (
|
|
855
|
-
<lu-chip withEllipsis (kill)="unselectOption(
|
|
856
|
-
<ng-template *luOptionOutlet="select.displayerTpl(); value:
|
|
925
|
+
@if (displayedSingleOption(); as singleOption) {
|
|
926
|
+
<lu-chip withEllipsis (kill)="unselectOption(singleOption, $event)" class="multipleSelect-displayer-chip" [unkillable]="disabled() ?? false">
|
|
927
|
+
<ng-template *luOptionOutlet="select.displayerTpl(); value: singleOption" />
|
|
857
928
|
</lu-chip>
|
|
858
929
|
} @else {
|
|
859
|
-
<lu-chip class="multipleSelect-displayer-chip" unkillable>{{
|
|
930
|
+
<lu-chip class="multipleSelect-displayer-chip" unkillable>{{ displayerLabelValue() }}</lu-chip>
|
|
860
931
|
}
|
|
861
932
|
</div>
|
|
862
933
|
}
|
|
863
934
|
</div>
|
|
864
935
|
`, isInline: true, styles: [":host{display:block;inline-size:100%}\n"], dependencies: [{ kind: "directive", type: LuMultiSelectDisplayerInputDirective, selector: "[luMultiSelectDisplayerInput]" }, { kind: "directive", type: _LuOptionOutletDirective, selector: "[luOptionOutlet]", inputs: ["luOptionOutlet", "luOptionOutletValue", "luOptionShowNull"] }, { kind: "component", type: ChipComponent, selector: "lu-chip, button[luChip], a[luChip]", inputs: ["intl", "withEllipsis", "unkillable", "palette", "disabled", "size", "state", "icon"], outputs: ["kill"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
865
936
|
}
|
|
866
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
937
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectAllDisplayerComponent, decorators: [{
|
|
867
938
|
type: Component,
|
|
868
939
|
args: [{ selector: 'lu-multi-select-all-displayer', imports: [LuMultiSelectDisplayerInputDirective, _LuOptionOutletDirective, ChipComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: `
|
|
869
940
|
<div class="multipleSelect-displayer mod-filter" [class.is-filled]="isFilled()">
|
|
@@ -871,12 +942,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
871
942
|
|
|
872
943
|
@if (displayerCount() !== null) {
|
|
873
944
|
<div class="multipleSelect-displayer-filter">
|
|
874
|
-
@if (
|
|
875
|
-
<lu-chip withEllipsis (kill)="unselectOption(
|
|
876
|
-
<ng-template *luOptionOutlet="select.displayerTpl(); value:
|
|
945
|
+
@if (displayedSingleOption(); as singleOption) {
|
|
946
|
+
<lu-chip withEllipsis (kill)="unselectOption(singleOption, $event)" class="multipleSelect-displayer-chip" [unkillable]="disabled() ?? false">
|
|
947
|
+
<ng-template *luOptionOutlet="select.displayerTpl(); value: singleOption" />
|
|
877
948
|
</lu-chip>
|
|
878
949
|
} @else {
|
|
879
|
-
<lu-chip class="multipleSelect-displayer-chip" unkillable>{{
|
|
950
|
+
<lu-chip class="multipleSelect-displayer-chip" unkillable>{{ displayerLabelValue() }}</lu-chip>
|
|
880
951
|
}
|
|
881
952
|
</div>
|
|
882
953
|
}
|
|
@@ -887,6 +958,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
887
958
|
class LuMultiSelectAllHeaderComponent {
|
|
888
959
|
#selectableItem;
|
|
889
960
|
#elementRef;
|
|
961
|
+
#injector;
|
|
890
962
|
constructor() {
|
|
891
963
|
this.selectAllContext = inject(MULTI_SELECT_WITH_SELECT_ALL_CONTEXT);
|
|
892
964
|
this.intl = this.selectAllContext.intl;
|
|
@@ -896,12 +968,13 @@ class LuMultiSelectAllHeaderComponent {
|
|
|
896
968
|
...(ngDevMode ? [{ debugName: "isSelected" }] : /* istanbul ignore next */ []));
|
|
897
969
|
this.#selectableItem = inject(_CoreSelectPanelElement);
|
|
898
970
|
this.#elementRef = inject(ElementRef);
|
|
971
|
+
this.#injector = inject(Injector);
|
|
899
972
|
this.#selectableItem.id.set(`multi-select-select-all`);
|
|
900
|
-
effect(() => {
|
|
973
|
+
effect((onCleanup) => {
|
|
901
974
|
if (this.#selectableItem.isHighlighted()) {
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
975
|
+
// Wait for the panel layout to settle (opening animation) before scrolling,
|
|
976
|
+
// otherwise the browser computes a bogus scroll position.
|
|
977
|
+
onCleanup(_scrollIntoViewOnceReady(this.#elementRef.nativeElement, this.#injector));
|
|
905
978
|
}
|
|
906
979
|
if (this.isSelected()) {
|
|
907
980
|
this.#selectableItem.isSelected.set(true);
|
|
@@ -913,9 +986,9 @@ class LuMultiSelectAllHeaderComponent {
|
|
|
913
986
|
this.selectAllContext.setSelectAll(!this.isSelected());
|
|
914
987
|
});
|
|
915
988
|
}
|
|
916
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
917
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.
|
|
918
|
-
<div class="multiSelectAllDisplayer">
|
|
989
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectAllHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
990
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.8", type: LuMultiSelectAllHeaderComponent, isStandalone: true, selector: "lu-multi-select-all-header", hostDirectives: [{ directive: i1$1.ɵCoreSelectPanelElement }], ngImport: i0, template: `
|
|
991
|
+
<div class="multiSelectAllDisplayer" role="option">
|
|
919
992
|
<lu-form-field [label]="intl().selectAll">
|
|
920
993
|
<lu-checkbox-input
|
|
921
994
|
class="multiSelectAllDisplayer-checkbox"
|
|
@@ -926,12 +999,12 @@ class LuMultiSelectAllHeaderComponent {
|
|
|
926
999
|
/>
|
|
927
1000
|
</lu-form-field>
|
|
928
1001
|
</div>
|
|
929
|
-
`, isInline: true, styles: ["@layer components{:host{display:block;background-color:var(--palettes-neutral-0);border-block-end:1px solid var(--commons-border-200);padding-block:0 var(--pr-t-spacings-50);padding-inline:var(--components-options-item-padding-vertical);margin-inline:calc(-1 * var(--pr-t-spacings-50));scroll-margin-block-start:var(--pr-t-spacings-50)}}@layer components{.multiSelectAllDisplayer{border-radius:var(--pr-t-border-radius-default);cursor:pointer}.multiSelectAllDisplayer ::ng-deep .formLabel{inline-size:100%;padding-block:var(--components-options-item-padding-vertical);padding-inline:0}}@layer mods{.multiSelectAllDisplayer:hover,:host
|
|
1002
|
+
`, isInline: true, styles: ["@layer components{:host{display:block;background-color:var(--palettes-neutral-0);border-block-end:1px solid var(--commons-border-200);padding-block:0 var(--pr-t-spacings-50);padding-inline:var(--components-options-item-padding-vertical);margin-inline:calc(-1 * var(--pr-t-spacings-50));scroll-margin-block-start:var(--pr-t-spacings-50)}}@layer components{.multiSelectAllDisplayer{border-radius:var(--pr-t-border-radius-default);cursor:pointer}.multiSelectAllDisplayer ::ng-deep .formLabel{inline-size:100%;padding-block:var(--components-options-item-padding-vertical);padding-inline:0}}@layer mods{.multiSelectAllDisplayer:hover,:host(.is-highlighted) .multiSelectAllDisplayer{background-color:var(--palettes-neutral-50)}.multiSelectAllDisplayer:has(.checkboxField-input:checked){background-color:var(--palettes-50, var(--palettes-product-50))}.multiSelectAllDisplayer:has(.checkboxField-input:checked):hover,:host(.is-highlighted) .multiSelectAllDisplayer:has(.checkboxField-input:checked){background-color:var(--palettes-100, var(--palettes-product-100))}}@layer components{.multiSelectAllDisplayer-checkbox{margin-block:var(--components-options-item-padding-vertical) 0;margin-inline:var(--components-options-item-padding-horizontal) 0}}\n"], dependencies: [{ kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: CheckboxInputComponent, selector: "lu-checkbox-input", inputs: ["checklist", "mixed"] }, { kind: "component", type: FormFieldComponent, selector: "lu-form-field", inputs: ["intl", "label", "hiddenLabel", "rolePresentationLabel", "inline", "statusControl", "tooltip", "tag", "AI", "iconAItooltip", "iconAIalt", "width", "invalid", "inlineMessage", "errorInlineMessage", "inlineMessageState", "size", "extraDescribedBy", "layout", "counter", "presentation"], outputs: ["rolePresentationLabelChange", "layoutChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
930
1003
|
}
|
|
931
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
1004
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectAllHeaderComponent, decorators: [{
|
|
932
1005
|
type: Component,
|
|
933
1006
|
args: [{ selector: 'lu-multi-select-all-header', imports: [FormsModule, CheckboxInputComponent, FormFieldComponent], changeDetection: ChangeDetectionStrategy.OnPush, hostDirectives: [_CoreSelectPanelElement], template: `
|
|
934
|
-
<div class="multiSelectAllDisplayer">
|
|
1007
|
+
<div class="multiSelectAllDisplayer" role="option">
|
|
935
1008
|
<lu-form-field [label]="intl().selectAll">
|
|
936
1009
|
<lu-checkbox-input
|
|
937
1010
|
class="multiSelectAllDisplayer-checkbox"
|
|
@@ -942,12 +1015,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
942
1015
|
/>
|
|
943
1016
|
</lu-form-field>
|
|
944
1017
|
</div>
|
|
945
|
-
`, styles: ["@layer components{:host{display:block;background-color:var(--palettes-neutral-0);border-block-end:1px solid var(--commons-border-200);padding-block:0 var(--pr-t-spacings-50);padding-inline:var(--components-options-item-padding-vertical);margin-inline:calc(-1 * var(--pr-t-spacings-50));scroll-margin-block-start:var(--pr-t-spacings-50)}}@layer components{.multiSelectAllDisplayer{border-radius:var(--pr-t-border-radius-default);cursor:pointer}.multiSelectAllDisplayer ::ng-deep .formLabel{inline-size:100%;padding-block:var(--components-options-item-padding-vertical);padding-inline:0}}@layer mods{.multiSelectAllDisplayer:hover,:host
|
|
1018
|
+
`, styles: ["@layer components{:host{display:block;background-color:var(--palettes-neutral-0);border-block-end:1px solid var(--commons-border-200);padding-block:0 var(--pr-t-spacings-50);padding-inline:var(--components-options-item-padding-vertical);margin-inline:calc(-1 * var(--pr-t-spacings-50));scroll-margin-block-start:var(--pr-t-spacings-50)}}@layer components{.multiSelectAllDisplayer{border-radius:var(--pr-t-border-radius-default);cursor:pointer}.multiSelectAllDisplayer ::ng-deep .formLabel{inline-size:100%;padding-block:var(--components-options-item-padding-vertical);padding-inline:0}}@layer mods{.multiSelectAllDisplayer:hover,:host(.is-highlighted) .multiSelectAllDisplayer{background-color:var(--palettes-neutral-50)}.multiSelectAllDisplayer:has(.checkboxField-input:checked){background-color:var(--palettes-50, var(--palettes-product-50))}.multiSelectAllDisplayer:has(.checkboxField-input:checked):hover,:host(.is-highlighted) .multiSelectAllDisplayer:has(.checkboxField-input:checked){background-color:var(--palettes-100, var(--palettes-product-100))}}@layer components{.multiSelectAllDisplayer-checkbox{margin-block:var(--components-options-item-padding-vertical) 0;margin-inline:var(--components-options-item-padding-horizontal) 0}}\n"] }]
|
|
946
1019
|
}], ctorParameters: () => [] });
|
|
947
1020
|
|
|
948
1021
|
class LuMultiSelectWithSelectAllDirective extends _IsSelectedStrategy {
|
|
949
1022
|
#mode;
|
|
950
1023
|
#values;
|
|
1024
|
+
#options;
|
|
951
1025
|
// only show panel header when no clue && values not empty
|
|
952
1026
|
#showPanelHeader;
|
|
953
1027
|
#hasValue;
|
|
@@ -962,7 +1036,22 @@ class LuMultiSelectWithSelectAllDirective extends _IsSelectedStrategy {
|
|
|
962
1036
|
super();
|
|
963
1037
|
this.select = inject(LuMultiSelectInputComponent);
|
|
964
1038
|
this.intl = this.select.intl;
|
|
965
|
-
this.
|
|
1039
|
+
this.pluralRules = inject(LOCALE_PLURAL_RULES);
|
|
1040
|
+
/**
|
|
1041
|
+
* @deprecated use withSelectAllDisplayerLabelFn
|
|
1042
|
+
*/
|
|
1043
|
+
this.displayerLabel = input(undefined, { ...(ngDevMode ? { debugName: "displayerLabel" } : /* istanbul ignore next */ {}), alias: 'withSelectAllDisplayerLabel' });
|
|
1044
|
+
this.displayerLabelFn = input(undefined, { ...(ngDevMode ? { debugName: "displayerLabelFn" } : /* istanbul ignore next */ {}), alias: 'withSelectAllDisplayerLabelFn' });
|
|
1045
|
+
this.displayerLabelValue = computed(() => {
|
|
1046
|
+
const label = this.displayerLabelFn();
|
|
1047
|
+
const count = this.displayerCount();
|
|
1048
|
+
if (label) {
|
|
1049
|
+
const result = label(count);
|
|
1050
|
+
return typeof result === 'string' ? result : getIntlPluralLabel(this.pluralRules, result, count ?? 0);
|
|
1051
|
+
}
|
|
1052
|
+
return `${count} ${this.displayerLabel()}`;
|
|
1053
|
+
}, /* @ts-ignore */
|
|
1054
|
+
...(ngDevMode ? [{ debugName: "displayerLabelValue" }] : /* istanbul ignore next */ []));
|
|
966
1055
|
this.#mode = signal('none', /* @ts-ignore */
|
|
967
1056
|
...(ngDevMode ? [{ debugName: "#mode" }] : /* istanbul ignore next */ []));
|
|
968
1057
|
this.#values = signal([], /* @ts-ignore */
|
|
@@ -971,6 +1060,17 @@ class LuMultiSelectWithSelectAllDirective extends _IsSelectedStrategy {
|
|
|
971
1060
|
this.values = this.#values.asReadonly();
|
|
972
1061
|
this.totalCount = toSignal(inject(CORE_SELECT_API_TOTAL_COUNT_PROVIDER).totalCount$, { initialValue: 0 });
|
|
973
1062
|
this.clueChange = toSignal(this.select.clueChange$);
|
|
1063
|
+
this.#options = computed(() => this.select.options() ?? [], /* @ts-ignore */
|
|
1064
|
+
...(ngDevMode ? [{ debugName: "#options" }] : /* istanbul ignore next */ []));
|
|
1065
|
+
this.singleRemainingOption = computed(() => {
|
|
1066
|
+
const options = this.#options();
|
|
1067
|
+
const excludedValues = this.#values();
|
|
1068
|
+
if (this.#mode() !== 'exclude' || options.length !== this.totalCount() || options.length - excludedValues.length !== 1) {
|
|
1069
|
+
return undefined;
|
|
1070
|
+
}
|
|
1071
|
+
return options.find((option) => !excludedValues.some((excluded) => this.select.optionComparer()(excluded, option)));
|
|
1072
|
+
}, /* @ts-ignore */
|
|
1073
|
+
...(ngDevMode ? [{ debugName: "singleRemainingOption" }] : /* istanbul ignore next */ []));
|
|
974
1074
|
// only show panel header when no clue && values not empty
|
|
975
1075
|
this.#showPanelHeader = computed(() => isNil(this.clueChange()) || (this.clueChange()?.length === 0 && this.totalCount() !== 0), /* @ts-ignore */
|
|
976
1076
|
...(ngDevMode ? [{ debugName: "#showPanelHeader" }] : /* istanbul ignore next */ []));
|
|
@@ -1016,8 +1116,10 @@ class LuMultiSelectWithSelectAllDirective extends _IsSelectedStrategy {
|
|
|
1016
1116
|
this.select.hasValue = () => this.#hasValue();
|
|
1017
1117
|
this.select.isFilterPillEmpty = computed(() => !this.#hasValue(), /* @ts-ignore */
|
|
1018
1118
|
...(ngDevMode ? [{ debugName: "isFilterPillEmpty" }] : /* istanbul ignore next */ []));
|
|
1019
|
-
this.select.useSingleOptionDisplayer = computed(() => this.#mode() === 'include', /* @ts-ignore */
|
|
1119
|
+
this.select.useSingleOptionDisplayer = computed(() => this.#mode() === 'include' || this.singleRemainingOption() !== undefined, /* @ts-ignore */
|
|
1020
1120
|
...(ngDevMode ? [{ debugName: "useSingleOptionDisplayer" }] : /* istanbul ignore next */ []));
|
|
1121
|
+
this.select.singleOptionForDisplay = computed(() => (this.#mode() === 'include' && this.#valuesCount() === 1 ? this.select.valueSignal()?.[0] : this.singleRemainingOption()), /* @ts-ignore */
|
|
1122
|
+
...(ngDevMode ? [{ debugName: "singleOptionForDisplay" }] : /* istanbul ignore next */ []));
|
|
1021
1123
|
this.select.valueLength = computed(() => this.displayerCount() ?? 0, /* @ts-ignore */
|
|
1022
1124
|
...(ngDevMode ? [{ debugName: "valueLength" }] : /* istanbul ignore next */ []));
|
|
1023
1125
|
}
|
|
@@ -1112,8 +1214,8 @@ class LuMultiSelectWithSelectAllDirective extends _IsSelectedStrategy {
|
|
|
1112
1214
|
// No match, keep the same mode
|
|
1113
1215
|
return fromMode;
|
|
1114
1216
|
}
|
|
1115
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
1116
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.
|
|
1217
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectWithSelectAllDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1218
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.8", type: LuMultiSelectWithSelectAllDirective, isStandalone: true, selector: "lu-multi-select[withSelectAll]", inputs: { displayerLabel: { classPropertyName: "displayerLabel", publicName: "withSelectAllDisplayerLabel", isSignal: true, isRequired: false, transformFunction: null }, displayerLabelFn: { classPropertyName: "displayerLabelFn", publicName: "withSelectAllDisplayerLabelFn", isSignal: true, isRequired: false, transformFunction: null } }, providers: [
|
|
1117
1219
|
{
|
|
1118
1220
|
provide: _IsSelectedStrategy,
|
|
1119
1221
|
useExisting: forwardRef(() => LuMultiSelectWithSelectAllDirective),
|
|
@@ -1124,7 +1226,7 @@ class LuMultiSelectWithSelectAllDirective extends _IsSelectedStrategy {
|
|
|
1124
1226
|
},
|
|
1125
1227
|
], usesInheritance: true, ngImport: i0 }); }
|
|
1126
1228
|
}
|
|
1127
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
1229
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectWithSelectAllDirective, decorators: [{
|
|
1128
1230
|
type: Directive,
|
|
1129
1231
|
args: [{
|
|
1130
1232
|
// eslint-disable-next-line @angular-eslint/directive-selector
|
|
@@ -1140,14 +1242,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
1140
1242
|
},
|
|
1141
1243
|
],
|
|
1142
1244
|
}]
|
|
1143
|
-
}], ctorParameters: () => [], propDecorators: { displayerLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "withSelectAllDisplayerLabel", required: true }] }] } });
|
|
1245
|
+
}], ctorParameters: () => [], propDecorators: { displayerLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "withSelectAllDisplayerLabel", required: false }] }], displayerLabelFn: [{ type: i0.Input, args: [{ isSignal: true, alias: "withSelectAllDisplayerLabelFn", required: false }] }] } });
|
|
1144
1246
|
|
|
1145
1247
|
class LuMultiSelectContentDisplayerComponent {
|
|
1146
1248
|
constructor() {
|
|
1147
1249
|
this.select = inject(LuMultiSelectInputComponent);
|
|
1148
1250
|
}
|
|
1149
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
1150
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.
|
|
1251
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectContentDisplayerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1252
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.8", type: LuMultiSelectContentDisplayerComponent, isStandalone: true, selector: "lu-multi-select-content-displayer", ngImport: i0, template: `
|
|
1151
1253
|
<div class="multipleSelect-displayer mod-filter">
|
|
1152
1254
|
<input type="text" autocomplete="off" #inputElement luMultiSelectDisplayerInput />
|
|
1153
1255
|
<div class="multipleSelect-displayer-filter">
|
|
@@ -1156,7 +1258,7 @@ class LuMultiSelectContentDisplayerComponent {
|
|
|
1156
1258
|
</div>
|
|
1157
1259
|
`, isInline: true, styles: ["@layer components{:host{display:block;inline-size:100%}}\n"], dependencies: [{ kind: "directive", type: LuMultiSelectDisplayerInputDirective, selector: "[luMultiSelectDisplayerInput]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1158
1260
|
}
|
|
1159
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
1261
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectContentDisplayerComponent, decorators: [{
|
|
1160
1262
|
type: Component,
|
|
1161
1263
|
args: [{ selector: 'lu-multi-select-content-displayer', imports: [LuMultiSelectDisplayerInputDirective], template: `
|
|
1162
1264
|
<div class="multipleSelect-displayer mod-filter">
|
|
@@ -1208,9 +1310,9 @@ class LuMultiSelectCounterDisplayerComponent {
|
|
|
1208
1310
|
}
|
|
1209
1311
|
});
|
|
1210
1312
|
}
|
|
1211
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
1212
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.
|
|
1213
|
-
<div class="multipleSelect-displayer mod-filter" [class.is-filled]="(selectedOptions$ | async)?.length > 0">
|
|
1313
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectCounterDisplayerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1314
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: LuMultiSelectCounterDisplayerComponent, isStandalone: true, selector: "lu-multi-select-counter-displayer", inputs: { selected: { classPropertyName: "selected", publicName: "selected", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null } }, viewQueries: [{ propertyName: "inputElementRef", first: true, predicate: ["inputElement"], descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
1315
|
+
<div class="multipleSelect-displayer mod-filter" [class.is-filled]="((selectedOptions$ | async)?.length ?? 0) > 0">
|
|
1214
1316
|
<input type="text" autocomplete="off" #inputElement luMultiSelectDisplayerInput />
|
|
1215
1317
|
@if (selectedOptions$ | async; as selectedOptions) {
|
|
1216
1318
|
<div class="multipleSelect-displayer-filter">
|
|
@@ -1219,7 +1321,7 @@ class LuMultiSelectCounterDisplayerComponent {
|
|
|
1219
1321
|
<ng-container *luOptionOutlet="select.displayerTpl(); value: selectedOptions[0]" />
|
|
1220
1322
|
</lu-chip>
|
|
1221
1323
|
}
|
|
1222
|
-
@if (selectedOptions?.length > 1) {
|
|
1324
|
+
@if ((selectedOptions?.length ?? 0) > 1) {
|
|
1223
1325
|
<lu-chip class="multipleSelect-displayer-chip" unkillable>{{ selectedOptions?.length }} {{ label() }}</lu-chip>
|
|
1224
1326
|
}
|
|
1225
1327
|
</div>
|
|
@@ -1227,10 +1329,10 @@ class LuMultiSelectCounterDisplayerComponent {
|
|
|
1227
1329
|
</div>
|
|
1228
1330
|
`, isInline: true, styles: ["@layer components{:host{display:block;inline-size:100%;min-inline-size:0}}\n"], dependencies: [{ kind: "ngmodule", type: LuTooltipModule }, { kind: "component", type: ChipComponent, selector: "lu-chip, button[luChip], a[luChip]", inputs: ["intl", "withEllipsis", "unkillable", "palette", "disabled", "size", "state", "icon"], outputs: ["kill"] }, { kind: "directive", type: _LuOptionOutletDirective, selector: "[luOptionOutlet]", inputs: ["luOptionOutlet", "luOptionOutletValue", "luOptionShowNull"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: LuMultiSelectDisplayerInputDirective, selector: "[luMultiSelectDisplayerInput]" }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1229
1331
|
}
|
|
1230
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
1332
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectCounterDisplayerComponent, decorators: [{
|
|
1231
1333
|
type: Component,
|
|
1232
1334
|
args: [{ selector: 'lu-multi-select-counter-displayer', imports: [AsyncPipe, LuTooltipModule, ChipComponent, _LuOptionOutletDirective, FormsModule, LuMultiSelectDisplayerInputDirective], template: `
|
|
1233
|
-
<div class="multipleSelect-displayer mod-filter" [class.is-filled]="(selectedOptions$ | async)?.length > 0">
|
|
1335
|
+
<div class="multipleSelect-displayer mod-filter" [class.is-filled]="((selectedOptions$ | async)?.length ?? 0) > 0">
|
|
1234
1336
|
<input type="text" autocomplete="off" #inputElement luMultiSelectDisplayerInput />
|
|
1235
1337
|
@if (selectedOptions$ | async; as selectedOptions) {
|
|
1236
1338
|
<div class="multipleSelect-displayer-filter">
|
|
@@ -1239,7 +1341,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
1239
1341
|
<ng-container *luOptionOutlet="select.displayerTpl(); value: selectedOptions[0]" />
|
|
1240
1342
|
</lu-chip>
|
|
1241
1343
|
}
|
|
1242
|
-
@if (selectedOptions?.length > 1) {
|
|
1344
|
+
@if ((selectedOptions?.length ?? 0) > 1) {
|
|
1243
1345
|
<lu-chip class="multipleSelect-displayer-chip" unkillable>{{ selectedOptions?.length }} {{ label() }}</lu-chip>
|
|
1244
1346
|
}
|
|
1245
1347
|
</div>
|
|
@@ -1316,8 +1418,8 @@ class LuMultiSelectDefaultDisplayerComponent {
|
|
|
1316
1418
|
}
|
|
1317
1419
|
});
|
|
1318
1420
|
}
|
|
1319
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
1320
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.
|
|
1421
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectDefaultDisplayerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
1422
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: LuMultiSelectDefaultDisplayerComponent, isStandalone: true, selector: "lu-multi-select-default-displayer", inputs: { intl: { classPropertyName: "intl", publicName: "intl", isSignal: true, isRequired: false, transformFunction: null } }, viewQueries: [{ propertyName: "inputElementRef", first: true, predicate: ["inputElement"], descendants: true, isSignal: true }], ngImport: i0, template: `
|
|
1321
1423
|
<div class="multipleSelect-displayer">
|
|
1322
1424
|
<div class="multipleSelect-displayer-suffix">
|
|
1323
1425
|
<input [attr.aria-labelledby]="valueID" autocomplete="off" #inputElement (keydown.backspace)="inputBackspace()" (keydown.space)="inputSpace($event)" luMultiSelectDisplayerInput />
|
|
@@ -1335,7 +1437,7 @@ class LuMultiSelectDefaultDisplayerComponent {
|
|
|
1335
1437
|
</div>
|
|
1336
1438
|
|
|
1337
1439
|
@for (option of displayedOptions$ | async; track option; let index = $index) {
|
|
1338
|
-
<lu-chip aria-hidden="true" class="multipleSelect-displayer-chip" withEllipsis (kill)="unselectOption(option, $event)" [unkillable]="select.disabled$ | async">
|
|
1440
|
+
<lu-chip aria-hidden="true" class="multipleSelect-displayer-chip" withEllipsis (kill)="unselectOption(option, $event)" [unkillable]="(select.disabled$ | async) ?? false">
|
|
1339
1441
|
<ng-container *luOptionOutlet="select.displayerTpl(); value: option" />
|
|
1340
1442
|
</lu-chip>
|
|
1341
1443
|
}
|
|
@@ -1345,7 +1447,7 @@ class LuMultiSelectDefaultDisplayerComponent {
|
|
|
1345
1447
|
</div>
|
|
1346
1448
|
`, isInline: true, styles: ["@layer components{:host{display:block;inline-size:100%;min-inline-size:0}}\n"], dependencies: [{ kind: "ngmodule", type: LuTooltipModule }, { kind: "directive", type: _LuOptionOutletDirective, selector: "[luOptionOutlet]", inputs: ["luOptionOutlet", "luOptionOutletValue", "luOptionShowNull"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: LuMultiSelectDisplayerInputDirective, selector: "[luMultiSelectDisplayerInput]" }, { kind: "component", type: ChipComponent, selector: "lu-chip, button[luChip], a[luChip]", inputs: ["intl", "withEllipsis", "unkillable", "palette", "disabled", "size", "state", "icon"], outputs: ["kill"] }, { kind: "component", type: IconComponent, selector: "lu-icon, pr-icon", inputs: ["icon", "alt", "size", "color", "AI"] }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
1347
1449
|
}
|
|
1348
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
1450
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiSelectDefaultDisplayerComponent, decorators: [{
|
|
1349
1451
|
type: Component,
|
|
1350
1452
|
args: [{ selector: 'lu-multi-select-default-displayer', imports: [AsyncPipe, LuTooltipModule, _LuOptionOutletDirective, FormsModule, LuMultiSelectDisplayerInputDirective, ChipComponent, IconComponent], template: `
|
|
1351
1453
|
<div class="multipleSelect-displayer">
|
|
@@ -1365,7 +1467,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.4", ngImpor
|
|
|
1365
1467
|
</div>
|
|
1366
1468
|
|
|
1367
1469
|
@for (option of displayedOptions$ | async; track option; let index = $index) {
|
|
1368
|
-
<lu-chip aria-hidden="true" class="multipleSelect-displayer-chip" withEllipsis (kill)="unselectOption(option, $event)" [unkillable]="select.disabled$ | async">
|
|
1470
|
+
<lu-chip aria-hidden="true" class="multipleSelect-displayer-chip" withEllipsis (kill)="unselectOption(option, $event)" [unkillable]="(select.disabled$ | async) ?? false">
|
|
1369
1471
|
<ng-container *luOptionOutlet="select.displayerTpl(); value: option" />
|
|
1370
1472
|
</lu-chip>
|
|
1371
1473
|
}
|
|
@@ -1387,48 +1489,16 @@ class LuMultiDisplayerDirective {
|
|
|
1387
1489
|
static ngTemplateContextGuard(_dir, _ctx) {
|
|
1388
1490
|
return true;
|
|
1389
1491
|
}
|
|
1390
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
1391
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.
|
|
1492
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiDisplayerDirective, deps: [{ token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive }); }
|
|
1493
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.8", type: LuMultiDisplayerDirective, isStandalone: true, selector: "[luMultiDisplayer]", inputs: { select: { classPropertyName: "select", publicName: "luMultiDisplayerSelect", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0 }); }
|
|
1392
1494
|
}
|
|
1393
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
1495
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: LuMultiDisplayerDirective, decorators: [{
|
|
1394
1496
|
type: Directive,
|
|
1395
1497
|
args: [{
|
|
1396
1498
|
selector: '[luMultiDisplayer]',
|
|
1397
1499
|
}]
|
|
1398
1500
|
}], ctorParameters: () => [{ type: i0.TemplateRef }], propDecorators: { select: [{ type: i0.Input, args: [{ isSignal: true, alias: "luMultiDisplayerSelect", required: false }] }] } });
|
|
1399
1501
|
|
|
1400
|
-
function selectionToQueryParams(key, value, selector) {
|
|
1401
|
-
if (value.mode === 'all' || value.mode === 'none') {
|
|
1402
|
-
return {};
|
|
1403
|
-
}
|
|
1404
|
-
return { [value.mode === 'include' ? key : `-${key}`]: value.values.map(selector).join(',') };
|
|
1405
|
-
}
|
|
1406
|
-
/**
|
|
1407
|
-
* Transforms a selection from withSelectAll, the complete list of options and a getKey function to a list of options.
|
|
1408
|
-
*
|
|
1409
|
-
* @example
|
|
1410
|
-
* ```ts
|
|
1411
|
-
* const selection = { mode: 'exclude', values: [{ id: 1, name: 'foo' }] };
|
|
1412
|
-
* const allOptions = [{ id: 1, name: 'foo' }, { id: 2, name: 'bar' }, { id: 3, name: 'baz' }];
|
|
1413
|
-
*
|
|
1414
|
-
* const selectedOptions = selectionToOptions(selection, allOptions, (o) => o.id);
|
|
1415
|
-
* ```
|
|
1416
|
-
*/
|
|
1417
|
-
function selectionToOptions(selection, options, getKeyFn) {
|
|
1418
|
-
switch (selection.mode) {
|
|
1419
|
-
case 'include':
|
|
1420
|
-
return selection.values;
|
|
1421
|
-
case 'exclude': {
|
|
1422
|
-
const excludedKeys = new Set(selection.values.map(getKeyFn));
|
|
1423
|
-
return options.filter((o) => !excludedKeys.has(getKeyFn(o)));
|
|
1424
|
-
}
|
|
1425
|
-
case 'all':
|
|
1426
|
-
return options;
|
|
1427
|
-
case 'none':
|
|
1428
|
-
return [];
|
|
1429
|
-
}
|
|
1430
|
-
}
|
|
1431
|
-
|
|
1432
1502
|
const required = (control) => {
|
|
1433
1503
|
if (!control.value || control.value.mode === 'none') {
|
|
1434
1504
|
return { required: true };
|
|
@@ -1443,5 +1513,5 @@ const LuMultiSelectionValidators = {
|
|
|
1443
1513
|
* Generated bundle index. Do not edit.
|
|
1444
1514
|
*/
|
|
1445
1515
|
|
|
1446
|
-
export { LU_MULTI_SELECT_DISPLAYER_TRANSLATIONS, LU_MULTI_SELECT_TRANSLATIONS, LuMultiDisplayerDirective, LuMultiSelectContentDisplayerComponent, LuMultiSelectCounterDisplayerComponent, LuMultiSelectDefaultDisplayerComponent, LuMultiSelectDisplayerInputDirective, LuMultiSelectInputComponent, LuMultiSelectWithSelectAllDirective, LuMultiSelectionValidators, luMultiSelectDisplayerTranslations, luMultiSelectTranslations, selectionToOptions, selectionToQueryParams };
|
|
1516
|
+
export { LU_MULTI_SELECT_DISPLAYER_TRANSLATIONS, LU_MULTI_SELECT_TRANSLATIONS, LuMultiDisplayerDirective, LuMultiSelectContentDisplayerComponent, LuMultiSelectCounterDisplayerComponent, LuMultiSelectDefaultDisplayerComponent, LuMultiSelectDisplayerInputDirective, LuMultiSelectInputComponent, LuMultiSelectWithSelectAllDirective, LuMultiSelectionValidators, listSeparators, luMultiSelectDisplayerTranslations, luMultiSelectTranslations, selectionToOptions, selectionToQueryParams };
|
|
1447
1517
|
//# sourceMappingURL=lucca-front-ng-multi-select.mjs.map
|