@slotted/angular 0.0.0-stage → 0.1.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +51 -2
- package/docs/AGENTS.snippet.md +10 -0
- package/docs/accordion.json +345 -0
- package/docs/accordion.md +207 -0
- package/docs/action-bar.json +421 -0
- package/docs/action-bar.md +364 -0
- package/docs/action-sheet.json +210 -0
- package/docs/action-sheet.md +19 -0
- package/docs/alert.json +407 -0
- package/docs/alert.md +239 -0
- package/docs/app-shell.examples.md +349 -0
- package/docs/app-shell.json +835 -0
- package/docs/app-shell.md +214 -0
- package/docs/aspect-ratio.json +159 -0
- package/docs/aspect-ratio.md +134 -0
- package/docs/attachment.json +486 -0
- package/docs/attachment.md +253 -0
- package/docs/avatar-group.json +208 -0
- package/docs/avatar-group.md +130 -0
- package/docs/avatar.json +342 -0
- package/docs/avatar.md +142 -0
- package/docs/badge.json +334 -0
- package/docs/badge.md +138 -0
- package/docs/breadcrumb.json +368 -0
- package/docs/breadcrumb.md +237 -0
- package/docs/button-group.json +158 -0
- package/docs/button-group.md +72 -0
- package/docs/button.examples.md +621 -0
- package/docs/button.json +977 -0
- package/docs/button.md +200 -0
- package/docs/calendar.json +592 -0
- package/docs/calendar.md +242 -0
- package/docs/card.json +283 -0
- package/docs/card.md +130 -0
- package/docs/carousel.json +560 -0
- package/docs/carousel.md +357 -0
- package/docs/cascader.json +933 -0
- package/docs/cascader.md +379 -0
- package/docs/chart.examples.md +582 -0
- package/docs/chart.json +1359 -0
- package/docs/chart.md +187 -0
- package/docs/checkbox-group.examples.md +612 -0
- package/docs/checkbox-group.json +395 -0
- package/docs/checkbox-group.md +106 -0
- package/docs/checkbox.examples.md +546 -0
- package/docs/checkbox.json +506 -0
- package/docs/checkbox.md +104 -0
- package/docs/code-block.json +616 -0
- package/docs/code-block.md +303 -0
- package/docs/collapsible.json +456 -0
- package/docs/collapsible.md +261 -0
- package/docs/color-picker.json +523 -0
- package/docs/color-picker.md +201 -0
- package/docs/column-manager.json +486 -0
- package/docs/column-manager.md +277 -0
- package/docs/combobox.examples.md +1732 -0
- package/docs/combobox.json +1250 -0
- package/docs/combobox.md +209 -0
- package/docs/command-palette.json +800 -0
- package/docs/command-palette.md +419 -0
- package/docs/container.json +156 -0
- package/docs/container.md +92 -0
- package/docs/context-menu.json +231 -0
- package/docs/context-menu.md +176 -0
- package/docs/currency-field.examples.md +321 -0
- package/docs/currency-field.json +649 -0
- package/docs/currency-field.md +128 -0
- package/docs/dashboard-grid.json +680 -0
- package/docs/dashboard-grid.md +265 -0
- package/docs/data-grid.examples.md +3064 -0
- package/docs/data-grid.json +1577 -0
- package/docs/data-grid.md +237 -0
- package/docs/data-grid.props.md +81 -0
- package/docs/data-list.json +685 -0
- package/docs/data-list.md +327 -0
- package/docs/date-field.json +490 -0
- package/docs/date-field.md +235 -0
- package/docs/date-picker.examples.md +1226 -0
- package/docs/date-picker.json +696 -0
- package/docs/date-picker.md +121 -0
- package/docs/date-range-picker.examples.md +1300 -0
- package/docs/date-range-picker.json +903 -0
- package/docs/date-range-picker.md +142 -0
- package/docs/datetime-field.json +665 -0
- package/docs/datetime-field.md +337 -0
- package/docs/datetime-picker.examples.md +1269 -0
- package/docs/datetime-picker.json +928 -0
- package/docs/datetime-picker.md +150 -0
- package/docs/datetime-range-picker.examples.md +225 -0
- package/docs/datetime-range-picker.json +1015 -0
- package/docs/datetime-range-picker.md +162 -0
- package/docs/description-list.json +471 -0
- package/docs/description-list.md +268 -0
- package/docs/detail-panel.json +530 -0
- package/docs/detail-panel.md +361 -0
- package/docs/dialog.examples.md +2467 -0
- package/docs/dialog.json +1141 -0
- package/docs/dialog.md +217 -0
- package/docs/dialog.props.md +63 -0
- package/docs/divider.json +148 -0
- package/docs/divider.md +83 -0
- package/docs/drawer.examples.md +1929 -0
- package/docs/drawer.json +753 -0
- package/docs/drawer.md +199 -0
- package/docs/entity-picker.json +946 -0
- package/docs/entity-picker.md +365 -0
- package/docs/event-calendar.examples.md +308 -0
- package/docs/event-calendar.json +1202 -0
- package/docs/event-calendar.md +201 -0
- package/docs/field-group.json +333 -0
- package/docs/field-group.md +181 -0
- package/docs/field.examples.md +676 -0
- package/docs/field.json +528 -0
- package/docs/field.md +127 -0
- package/docs/filter-bar.json +817 -0
- package/docs/filter-bar.md +380 -0
- package/docs/form.json +378 -0
- package/docs/form.md +235 -0
- package/docs/fullscreen.json +395 -0
- package/docs/fullscreen.md +225 -0
- package/docs/grid.json +176 -0
- package/docs/grid.md +74 -0
- package/docs/highlight.json +279 -0
- package/docs/highlight.md +210 -0
- package/docs/hover-card.json +254 -0
- package/docs/hover-card.md +213 -0
- package/docs/icon.json +173 -0
- package/docs/icon.md +101 -0
- package/docs/image.json +476 -0
- package/docs/image.md +254 -0
- package/docs/import-export-center.json +836 -0
- package/docs/import-export-center.md +345 -0
- package/docs/index.md +141 -0
- package/docs/inline-message.json +312 -0
- package/docs/inline-message.md +191 -0
- package/docs/inline.json +149 -0
- package/docs/inline.md +72 -0
- package/docs/kbd.json +350 -0
- package/docs/kbd.md +210 -0
- package/docs/link.json +264 -0
- package/docs/link.md +167 -0
- package/docs/list-item.json +463 -0
- package/docs/list-item.md +236 -0
- package/docs/list.json +321 -0
- package/docs/list.md +185 -0
- package/docs/listbox.json +807 -0
- package/docs/listbox.md +413 -0
- package/docs/loading-overlay.json +440 -0
- package/docs/loading-overlay.md +248 -0
- package/docs/markdown.json +461 -0
- package/docs/markdown.md +266 -0
- package/docs/menu.examples.md +1651 -0
- package/docs/menu.json +922 -0
- package/docs/menu.md +155 -0
- package/docs/menubar.json +292 -0
- package/docs/menubar.md +173 -0
- package/docs/message-scroller.json +401 -0
- package/docs/message-scroller.md +212 -0
- package/docs/message.json +862 -0
- package/docs/message.md +473 -0
- package/docs/multi-select.examples.md +1922 -0
- package/docs/multi-select.json +1314 -0
- package/docs/multi-select.md +213 -0
- package/docs/navigation-menu.json +529 -0
- package/docs/navigation-menu.md +329 -0
- package/docs/notification-center.json +664 -0
- package/docs/notification-center.md +372 -0
- package/docs/number-field.examples.md +1078 -0
- package/docs/number-field.json +668 -0
- package/docs/number-field.md +137 -0
- package/docs/otp-input.json +479 -0
- package/docs/otp-input.md +291 -0
- package/docs/page-header.json +574 -0
- package/docs/page-header.md +338 -0
- package/docs/page.json +332 -0
- package/docs/page.md +184 -0
- package/docs/pagination.json +434 -0
- package/docs/pagination.md +238 -0
- package/docs/popover.examples.md +1235 -0
- package/docs/popover.json +656 -0
- package/docs/popover.md +199 -0
- package/docs/progress-indicator.json +501 -0
- package/docs/progress-indicator.md +329 -0
- package/docs/prompt-composer.json +498 -0
- package/docs/prompt-composer.md +278 -0
- package/docs/prose.json +357 -0
- package/docs/prose.md +226 -0
- package/docs/radio-group.examples.md +626 -0
- package/docs/radio-group.json +541 -0
- package/docs/radio-group.md +112 -0
- package/docs/rating.json +1053 -0
- package/docs/rating.md +435 -0
- package/docs/result-state.json +376 -0
- package/docs/result-state.md +286 -0
- package/docs/saved-views.json +384 -0
- package/docs/saved-views.md +242 -0
- package/docs/scroll-area.json +120 -0
- package/docs/scroll-area.md +8 -0
- package/docs/section.json +344 -0
- package/docs/section.md +208 -0
- package/docs/segmented-control.json +429 -0
- package/docs/segmented-control.md +240 -0
- package/docs/select.examples.md +1214 -0
- package/docs/select.json +1147 -0
- package/docs/select.md +199 -0
- package/docs/side-navigation.json +632 -0
- package/docs/side-navigation.md +430 -0
- package/docs/skeleton.json +358 -0
- package/docs/skeleton.md +223 -0
- package/docs/slider.json +522 -0
- package/docs/slider.md +261 -0
- package/docs/sparkline.json +426 -0
- package/docs/sparkline.md +206 -0
- package/docs/split-button.json +361 -0
- package/docs/split-button.md +275 -0
- package/docs/splitter.json +142 -0
- package/docs/splitter.md +14 -0
- package/docs/stack.json +135 -0
- package/docs/stack.md +74 -0
- package/docs/stat-card.json +529 -0
- package/docs/stat-card.md +270 -0
- package/docs/status-indicator.json +314 -0
- package/docs/status-indicator.md +197 -0
- package/docs/stepper.json +451 -0
- package/docs/stepper.md +250 -0
- package/docs/switch.json +451 -0
- package/docs/switch.md +508 -0
- package/docs/table-of-contents.json +553 -0
- package/docs/table-of-contents.md +289 -0
- package/docs/table.examples.md +1981 -0
- package/docs/table.json +1059 -0
- package/docs/table.md +290 -0
- package/docs/tabs.examples.md +1370 -0
- package/docs/tabs.json +661 -0
- package/docs/tabs.md +211 -0
- package/docs/tag.json +813 -0
- package/docs/tag.md +241 -0
- package/docs/tags-input.json +771 -0
- package/docs/tags-input.md +361 -0
- package/docs/text-field.examples.md +821 -0
- package/docs/text-field.json +604 -0
- package/docs/text-field.md +125 -0
- package/docs/textarea.examples.md +612 -0
- package/docs/textarea.json +440 -0
- package/docs/textarea.md +98 -0
- package/docs/time-field.json +584 -0
- package/docs/time-field.md +291 -0
- package/docs/time-picker.json +679 -0
- package/docs/time-picker.md +315 -0
- package/docs/time-range-picker.examples.md +191 -0
- package/docs/time-range-picker.json +924 -0
- package/docs/time-range-picker.md +152 -0
- package/docs/timeline.json +839 -0
- package/docs/timeline.md +401 -0
- package/docs/toast.json +642 -0
- package/docs/toast.md +311 -0
- package/docs/toggle-group.json +417 -0
- package/docs/toggle-group.md +255 -0
- package/docs/toggle.json +326 -0
- package/docs/toggle.md +222 -0
- package/docs/toolbar.json +380 -0
- package/docs/toolbar.md +240 -0
- package/docs/tooltip.examples.md +664 -0
- package/docs/tooltip.json +604 -0
- package/docs/tooltip.md +146 -0
- package/docs/top-navigation.examples.md +287 -0
- package/docs/top-navigation.json +648 -0
- package/docs/top-navigation.md +138 -0
- package/docs/tour.json +759 -0
- package/docs/tour.md +337 -0
- package/docs/transfer.json +746 -0
- package/docs/transfer.md +273 -0
- package/docs/tree.json +918 -0
- package/docs/tree.md +397 -0
- package/docs/typography.json +317 -0
- package/docs/typography.md +107 -0
- package/docs/upload.examples.md +358 -0
- package/docs/upload.json +1103 -0
- package/docs/upload.md +166 -0
- package/docs/visually-hidden.json +71 -0
- package/docs/visually-hidden.md +42 -0
- package/docs/wizard.json +724 -0
- package/docs/wizard.md +295 -0
- package/fesm2022/slotted-angular-accordion.mjs +247 -0
- package/fesm2022/slotted-angular-accordion.mjs.map +1 -0
- package/fesm2022/slotted-angular-action-bar.mjs +639 -0
- package/fesm2022/slotted-angular-action-bar.mjs.map +1 -0
- package/fesm2022/slotted-angular-action-sheet.mjs +749 -0
- package/fesm2022/slotted-angular-action-sheet.mjs.map +1 -0
- package/fesm2022/slotted-angular-alert.mjs +427 -0
- package/fesm2022/slotted-angular-alert.mjs.map +1 -0
- package/fesm2022/slotted-angular-app-shell.mjs +1334 -0
- package/fesm2022/slotted-angular-app-shell.mjs.map +1 -0
- package/fesm2022/slotted-angular-aspect-ratio.mjs +63 -0
- package/fesm2022/slotted-angular-aspect-ratio.mjs.map +1 -0
- package/fesm2022/slotted-angular-attachment.mjs +595 -0
- package/fesm2022/slotted-angular-attachment.mjs.map +1 -0
- package/fesm2022/slotted-angular-avatar-group.mjs +230 -0
- package/fesm2022/slotted-angular-avatar-group.mjs.map +1 -0
- package/fesm2022/slotted-angular-avatar.mjs +330 -0
- package/fesm2022/slotted-angular-avatar.mjs.map +1 -0
- package/fesm2022/slotted-angular-badge.mjs +255 -0
- package/fesm2022/slotted-angular-badge.mjs.map +1 -0
- package/fesm2022/slotted-angular-breadcrumb.mjs +544 -0
- package/fesm2022/slotted-angular-breadcrumb.mjs.map +1 -0
- package/fesm2022/slotted-angular-button-group.mjs +146 -0
- package/fesm2022/slotted-angular-button-group.mjs.map +1 -0
- package/fesm2022/slotted-angular-button.mjs +692 -0
- package/fesm2022/slotted-angular-button.mjs.map +1 -0
- package/fesm2022/slotted-angular-calendar.mjs +916 -0
- package/fesm2022/slotted-angular-calendar.mjs.map +1 -0
- package/fesm2022/slotted-angular-card.mjs +225 -0
- package/fesm2022/slotted-angular-card.mjs.map +1 -0
- package/fesm2022/slotted-angular-carousel.mjs +840 -0
- package/fesm2022/slotted-angular-carousel.mjs.map +1 -0
- package/fesm2022/slotted-angular-cascader.mjs +1839 -0
- package/fesm2022/slotted-angular-cascader.mjs.map +1 -0
- package/fesm2022/slotted-angular-chart.mjs +974 -0
- package/fesm2022/slotted-angular-chart.mjs.map +1 -0
- package/fesm2022/slotted-angular-checkbox-group.mjs +283 -0
- package/fesm2022/slotted-angular-checkbox-group.mjs.map +1 -0
- package/fesm2022/slotted-angular-checkbox.mjs +468 -0
- package/fesm2022/slotted-angular-checkbox.mjs.map +1 -0
- package/fesm2022/slotted-angular-code-block.mjs +476 -0
- package/fesm2022/slotted-angular-code-block.mjs.map +1 -0
- package/fesm2022/slotted-angular-collapsible.mjs +479 -0
- package/fesm2022/slotted-angular-collapsible.mjs.map +1 -0
- package/fesm2022/slotted-angular-color-picker.mjs +910 -0
- package/fesm2022/slotted-angular-color-picker.mjs.map +1 -0
- package/fesm2022/slotted-angular-column-manager.mjs +1037 -0
- package/fesm2022/slotted-angular-column-manager.mjs.map +1 -0
- package/fesm2022/slotted-angular-combobox.mjs +1480 -0
- package/fesm2022/slotted-angular-combobox.mjs.map +1 -0
- package/fesm2022/slotted-angular-command-palette.mjs +1283 -0
- package/fesm2022/slotted-angular-command-palette.mjs.map +1 -0
- package/fesm2022/slotted-angular-container.mjs +105 -0
- package/fesm2022/slotted-angular-container.mjs.map +1 -0
- package/fesm2022/slotted-angular-context-menu.mjs +221 -0
- package/fesm2022/slotted-angular-context-menu.mjs.map +1 -0
- package/fesm2022/slotted-angular-currency-field.mjs +1131 -0
- package/fesm2022/slotted-angular-currency-field.mjs.map +1 -0
- package/fesm2022/slotted-angular-dashboard-grid.mjs +1928 -0
- package/fesm2022/slotted-angular-dashboard-grid.mjs.map +1 -0
- package/fesm2022/slotted-angular-data-grid.mjs +6697 -0
- package/fesm2022/slotted-angular-data-grid.mjs.map +1 -0
- package/fesm2022/slotted-angular-data-list.mjs +1418 -0
- package/fesm2022/slotted-angular-data-list.mjs.map +1 -0
- package/fesm2022/slotted-angular-date-field.mjs +772 -0
- package/fesm2022/slotted-angular-date-field.mjs.map +1 -0
- package/fesm2022/slotted-angular-date-picker.mjs +690 -0
- package/fesm2022/slotted-angular-date-picker.mjs.map +1 -0
- package/fesm2022/slotted-angular-date-range-picker.mjs +1150 -0
- package/fesm2022/slotted-angular-date-range-picker.mjs.map +1 -0
- package/fesm2022/slotted-angular-datetime-field.mjs +1058 -0
- package/fesm2022/slotted-angular-datetime-field.mjs.map +1 -0
- package/fesm2022/slotted-angular-datetime-picker.mjs +1362 -0
- package/fesm2022/slotted-angular-datetime-picker.mjs.map +1 -0
- package/fesm2022/slotted-angular-datetime-range-picker.mjs +1872 -0
- package/fesm2022/slotted-angular-datetime-range-picker.mjs.map +1 -0
- package/fesm2022/slotted-angular-description-list.mjs +545 -0
- package/fesm2022/slotted-angular-description-list.mjs.map +1 -0
- package/fesm2022/slotted-angular-detail-panel.mjs +754 -0
- package/fesm2022/slotted-angular-detail-panel.mjs.map +1 -0
- package/fesm2022/slotted-angular-dialog.mjs +980 -0
- package/fesm2022/slotted-angular-dialog.mjs.map +1 -0
- package/fesm2022/slotted-angular-divider.mjs +76 -0
- package/fesm2022/slotted-angular-divider.mjs.map +1 -0
- package/fesm2022/slotted-angular-drawer.mjs +1397 -0
- package/fesm2022/slotted-angular-drawer.mjs.map +1 -0
- package/fesm2022/slotted-angular-entity-picker.mjs +1987 -0
- package/fesm2022/slotted-angular-entity-picker.mjs.map +1 -0
- package/fesm2022/slotted-angular-event-calendar.mjs +2934 -0
- package/fesm2022/slotted-angular-event-calendar.mjs.map +1 -0
- package/fesm2022/slotted-angular-field-group.mjs +301 -0
- package/fesm2022/slotted-angular-field-group.mjs.map +1 -0
- package/fesm2022/slotted-angular-field.mjs +928 -0
- package/fesm2022/slotted-angular-field.mjs.map +1 -0
- package/fesm2022/slotted-angular-filter-bar.mjs +3107 -0
- package/fesm2022/slotted-angular-filter-bar.mjs.map +1 -0
- package/fesm2022/slotted-angular-form.mjs +592 -0
- package/fesm2022/slotted-angular-form.mjs.map +1 -0
- package/fesm2022/slotted-angular-fullscreen.mjs +314 -0
- package/fesm2022/slotted-angular-fullscreen.mjs.map +1 -0
- package/fesm2022/slotted-angular-grid.mjs +58 -0
- package/fesm2022/slotted-angular-grid.mjs.map +1 -0
- package/fesm2022/slotted-angular-highlight.mjs +123 -0
- package/fesm2022/slotted-angular-highlight.mjs.map +1 -0
- package/fesm2022/slotted-angular-hover-card.mjs +326 -0
- package/fesm2022/slotted-angular-hover-card.mjs.map +1 -0
- package/fesm2022/slotted-angular-i18n.mjs +75 -0
- package/fesm2022/slotted-angular-i18n.mjs.map +1 -0
- package/fesm2022/slotted-angular-icon.mjs +232 -0
- package/fesm2022/slotted-angular-icon.mjs.map +1 -0
- package/fesm2022/slotted-angular-image.mjs +442 -0
- package/fesm2022/slotted-angular-image.mjs.map +1 -0
- package/fesm2022/slotted-angular-import-export-center.mjs +1792 -0
- package/fesm2022/slotted-angular-import-export-center.mjs.map +1 -0
- package/fesm2022/slotted-angular-inline-message.mjs +280 -0
- package/fesm2022/slotted-angular-inline-message.mjs.map +1 -0
- package/fesm2022/slotted-angular-inline.mjs +52 -0
- package/fesm2022/slotted-angular-inline.mjs.map +1 -0
- package/fesm2022/slotted-angular-kbd.mjs +284 -0
- package/fesm2022/slotted-angular-kbd.mjs.map +1 -0
- package/fesm2022/slotted-angular-link.mjs +182 -0
- package/fesm2022/slotted-angular-link.mjs.map +1 -0
- package/fesm2022/slotted-angular-list-item.mjs +367 -0
- package/fesm2022/slotted-angular-list-item.mjs.map +1 -0
- package/fesm2022/slotted-angular-list.mjs +256 -0
- package/fesm2022/slotted-angular-list.mjs.map +1 -0
- package/fesm2022/slotted-angular-listbox.mjs +1274 -0
- package/fesm2022/slotted-angular-listbox.mjs.map +1 -0
- package/fesm2022/slotted-angular-loading-overlay.mjs +451 -0
- package/fesm2022/slotted-angular-loading-overlay.mjs.map +1 -0
- package/fesm2022/slotted-angular-markdown.mjs +914 -0
- package/fesm2022/slotted-angular-markdown.mjs.map +1 -0
- package/fesm2022/slotted-angular-menu.mjs +1211 -0
- package/fesm2022/slotted-angular-menu.mjs.map +1 -0
- package/fesm2022/slotted-angular-menubar.mjs +230 -0
- package/fesm2022/slotted-angular-menubar.mjs.map +1 -0
- package/fesm2022/slotted-angular-message-scroller.mjs +378 -0
- package/fesm2022/slotted-angular-message-scroller.mjs.map +1 -0
- package/fesm2022/slotted-angular-message.mjs +866 -0
- package/fesm2022/slotted-angular-message.mjs.map +1 -0
- package/fesm2022/slotted-angular-multi-select.mjs +1939 -0
- package/fesm2022/slotted-angular-multi-select.mjs.map +1 -0
- package/fesm2022/slotted-angular-navigation-menu.mjs +770 -0
- package/fesm2022/slotted-angular-navigation-menu.mjs.map +1 -0
- package/fesm2022/slotted-angular-notification-center.mjs +1172 -0
- package/fesm2022/slotted-angular-notification-center.mjs.map +1 -0
- package/fesm2022/slotted-angular-number-field.mjs +966 -0
- package/fesm2022/slotted-angular-number-field.mjs.map +1 -0
- package/fesm2022/slotted-angular-otp-input.mjs +629 -0
- package/fesm2022/slotted-angular-otp-input.mjs.map +1 -0
- package/fesm2022/slotted-angular-page-header.mjs +788 -0
- package/fesm2022/slotted-angular-page-header.mjs.map +1 -0
- package/fesm2022/slotted-angular-page.mjs +255 -0
- package/fesm2022/slotted-angular-page.mjs.map +1 -0
- package/fesm2022/slotted-angular-pagination.mjs +562 -0
- package/fesm2022/slotted-angular-pagination.mjs.map +1 -0
- package/fesm2022/slotted-angular-popover.mjs +799 -0
- package/fesm2022/slotted-angular-popover.mjs.map +1 -0
- package/fesm2022/slotted-angular-progress-indicator.mjs +572 -0
- package/fesm2022/slotted-angular-progress-indicator.mjs.map +1 -0
- package/fesm2022/slotted-angular-prompt-composer.mjs +596 -0
- package/fesm2022/slotted-angular-prompt-composer.mjs.map +1 -0
- package/fesm2022/slotted-angular-prose.mjs +314 -0
- package/fesm2022/slotted-angular-prose.mjs.map +1 -0
- package/fesm2022/slotted-angular-radio-group.mjs +469 -0
- package/fesm2022/slotted-angular-radio-group.mjs.map +1 -0
- package/fesm2022/slotted-angular-rating.mjs +1174 -0
- package/fesm2022/slotted-angular-rating.mjs.map +1 -0
- package/fesm2022/slotted-angular-result-state.mjs +330 -0
- package/fesm2022/slotted-angular-result-state.mjs.map +1 -0
- package/fesm2022/slotted-angular-saved-views.mjs +877 -0
- package/fesm2022/slotted-angular-saved-views.mjs.map +1 -0
- package/fesm2022/slotted-angular-scroll-area.mjs +294 -0
- package/fesm2022/slotted-angular-scroll-area.mjs.map +1 -0
- package/fesm2022/slotted-angular-section.mjs +266 -0
- package/fesm2022/slotted-angular-section.mjs.map +1 -0
- package/fesm2022/slotted-angular-segmented-control.mjs +454 -0
- package/fesm2022/slotted-angular-segmented-control.mjs.map +1 -0
- package/fesm2022/slotted-angular-select.mjs +1899 -0
- package/fesm2022/slotted-angular-select.mjs.map +1 -0
- package/fesm2022/slotted-angular-side-navigation.mjs +1042 -0
- package/fesm2022/slotted-angular-side-navigation.mjs.map +1 -0
- package/fesm2022/slotted-angular-skeleton.mjs +316 -0
- package/fesm2022/slotted-angular-skeleton.mjs.map +1 -0
- package/fesm2022/slotted-angular-slider.mjs +586 -0
- package/fesm2022/slotted-angular-slider.mjs.map +1 -0
- package/fesm2022/slotted-angular-sparkline.mjs +235 -0
- package/fesm2022/slotted-angular-sparkline.mjs.map +1 -0
- package/fesm2022/slotted-angular-split-button.mjs +331 -0
- package/fesm2022/slotted-angular-split-button.mjs.map +1 -0
- package/fesm2022/slotted-angular-splitter.mjs +516 -0
- package/fesm2022/slotted-angular-splitter.mjs.map +1 -0
- package/fesm2022/slotted-angular-stack.mjs +48 -0
- package/fesm2022/slotted-angular-stack.mjs.map +1 -0
- package/fesm2022/slotted-angular-stat-card.mjs +478 -0
- package/fesm2022/slotted-angular-stat-card.mjs.map +1 -0
- package/fesm2022/slotted-angular-status-indicator.mjs +155 -0
- package/fesm2022/slotted-angular-status-indicator.mjs.map +1 -0
- package/fesm2022/slotted-angular-stepper.mjs +536 -0
- package/fesm2022/slotted-angular-stepper.mjs.map +1 -0
- package/fesm2022/slotted-angular-switch.mjs +447 -0
- package/fesm2022/slotted-angular-switch.mjs.map +1 -0
- package/fesm2022/slotted-angular-table-of-contents.mjs +750 -0
- package/fesm2022/slotted-angular-table-of-contents.mjs.map +1 -0
- package/fesm2022/slotted-angular-table.mjs +2518 -0
- package/fesm2022/slotted-angular-table.mjs.map +1 -0
- package/fesm2022/slotted-angular-tabs.mjs +829 -0
- package/fesm2022/slotted-angular-tabs.mjs.map +1 -0
- package/fesm2022/slotted-angular-tag.mjs +595 -0
- package/fesm2022/slotted-angular-tag.mjs.map +1 -0
- package/fesm2022/slotted-angular-tags-input.mjs +1211 -0
- package/fesm2022/slotted-angular-tags-input.mjs.map +1 -0
- package/fesm2022/slotted-angular-text-field.mjs +674 -0
- package/fesm2022/slotted-angular-text-field.mjs.map +1 -0
- package/fesm2022/slotted-angular-textarea.mjs +275 -0
- package/fesm2022/slotted-angular-textarea.mjs.map +1 -0
- package/fesm2022/slotted-angular-theme.mjs +45 -0
- package/fesm2022/slotted-angular-theme.mjs.map +1 -0
- package/fesm2022/slotted-angular-time-field.mjs +895 -0
- package/fesm2022/slotted-angular-time-field.mjs.map +1 -0
- package/fesm2022/slotted-angular-time-picker.mjs +856 -0
- package/fesm2022/slotted-angular-time-picker.mjs.map +1 -0
- package/fesm2022/slotted-angular-time-range-picker.mjs +1534 -0
- package/fesm2022/slotted-angular-time-range-picker.mjs.map +1 -0
- package/fesm2022/slotted-angular-timeline.mjs +928 -0
- package/fesm2022/slotted-angular-timeline.mjs.map +1 -0
- package/fesm2022/slotted-angular-toast.mjs +917 -0
- package/fesm2022/slotted-angular-toast.mjs.map +1 -0
- package/fesm2022/slotted-angular-toggle-group.mjs +311 -0
- package/fesm2022/slotted-angular-toggle-group.mjs.map +1 -0
- package/fesm2022/slotted-angular-toggle.mjs +162 -0
- package/fesm2022/slotted-angular-toggle.mjs.map +1 -0
- package/fesm2022/slotted-angular-toolbar.mjs +536 -0
- package/fesm2022/slotted-angular-toolbar.mjs.map +1 -0
- package/fesm2022/slotted-angular-tooltip.mjs +798 -0
- package/fesm2022/slotted-angular-tooltip.mjs.map +1 -0
- package/fesm2022/slotted-angular-top-navigation.mjs +1308 -0
- package/fesm2022/slotted-angular-top-navigation.mjs.map +1 -0
- package/fesm2022/slotted-angular-tour.mjs +1330 -0
- package/fesm2022/slotted-angular-tour.mjs.map +1 -0
- package/fesm2022/slotted-angular-transfer.mjs +1406 -0
- package/fesm2022/slotted-angular-transfer.mjs.map +1 -0
- package/fesm2022/slotted-angular-tree.mjs +1448 -0
- package/fesm2022/slotted-angular-tree.mjs.map +1 -0
- package/fesm2022/slotted-angular-typography.mjs +184 -0
- package/fesm2022/slotted-angular-typography.mjs.map +1 -0
- package/fesm2022/slotted-angular-upload.mjs +1523 -0
- package/fesm2022/slotted-angular-upload.mjs.map +1 -0
- package/fesm2022/slotted-angular-visually-hidden.mjs +32 -0
- package/fesm2022/slotted-angular-visually-hidden.mjs.map +1 -0
- package/fesm2022/slotted-angular-wizard.mjs +1715 -0
- package/fesm2022/slotted-angular-wizard.mjs.map +1 -0
- package/fesm2022/slotted-angular.mjs +4 -0
- package/fesm2022/slotted-angular.mjs.map +1 -0
- package/package.json +537 -3
- package/types/slotted-angular-accordion.d.ts +156 -0
- package/types/slotted-angular-accordion.d.ts.map +1 -0
- package/types/slotted-angular-action-bar.d.ts +291 -0
- package/types/slotted-angular-action-bar.d.ts.map +1 -0
- package/types/slotted-angular-action-sheet.d.ts +294 -0
- package/types/slotted-angular-action-sheet.d.ts.map +1 -0
- package/types/slotted-angular-alert.d.ts +214 -0
- package/types/slotted-angular-alert.d.ts.map +1 -0
- package/types/slotted-angular-app-shell.d.ts +549 -0
- package/types/slotted-angular-app-shell.d.ts.map +1 -0
- package/types/slotted-angular-aspect-ratio.d.ts +57 -0
- package/types/slotted-angular-aspect-ratio.d.ts.map +1 -0
- package/types/slotted-angular-attachment.d.ts +294 -0
- package/types/slotted-angular-attachment.d.ts.map +1 -0
- package/types/slotted-angular-avatar-group.d.ts +119 -0
- package/types/slotted-angular-avatar-group.d.ts.map +1 -0
- package/types/slotted-angular-avatar.d.ts +202 -0
- package/types/slotted-angular-avatar.d.ts.map +1 -0
- package/types/slotted-angular-badge.d.ts +166 -0
- package/types/slotted-angular-badge.d.ts.map +1 -0
- package/types/slotted-angular-breadcrumb.d.ts +251 -0
- package/types/slotted-angular-breadcrumb.d.ts.map +1 -0
- package/types/slotted-angular-button-group.d.ts +89 -0
- package/types/slotted-angular-button-group.d.ts.map +1 -0
- package/types/slotted-angular-button.d.ts +390 -0
- package/types/slotted-angular-button.d.ts.map +1 -0
- package/types/slotted-angular-calendar.d.ts +280 -0
- package/types/slotted-angular-calendar.d.ts.map +1 -0
- package/types/slotted-angular-card.d.ts +140 -0
- package/types/slotted-angular-card.d.ts.map +1 -0
- package/types/slotted-angular-carousel.d.ts +288 -0
- package/types/slotted-angular-carousel.d.ts.map +1 -0
- package/types/slotted-angular-cascader.d.ts +351 -0
- package/types/slotted-angular-cascader.d.ts.map +1 -0
- package/types/slotted-angular-chart.d.ts +319 -0
- package/types/slotted-angular-chart.d.ts.map +1 -0
- package/types/slotted-angular-checkbox-group.d.ts +156 -0
- package/types/slotted-angular-checkbox-group.d.ts.map +1 -0
- package/types/slotted-angular-checkbox.d.ts +197 -0
- package/types/slotted-angular-checkbox.d.ts.map +1 -0
- package/types/slotted-angular-code-block.d.ts +158 -0
- package/types/slotted-angular-code-block.d.ts.map +1 -0
- package/types/slotted-angular-collapsible.d.ts +272 -0
- package/types/slotted-angular-collapsible.d.ts.map +1 -0
- package/types/slotted-angular-color-picker.d.ts +181 -0
- package/types/slotted-angular-color-picker.d.ts.map +1 -0
- package/types/slotted-angular-column-manager.d.ts +200 -0
- package/types/slotted-angular-column-manager.d.ts.map +1 -0
- package/types/slotted-angular-combobox.d.ts +449 -0
- package/types/slotted-angular-combobox.d.ts.map +1 -0
- package/types/slotted-angular-command-palette.d.ts +256 -0
- package/types/slotted-angular-command-palette.d.ts.map +1 -0
- package/types/slotted-angular-container.d.ts +84 -0
- package/types/slotted-angular-container.d.ts.map +1 -0
- package/types/slotted-angular-context-menu.d.ts +84 -0
- package/types/slotted-angular-context-menu.d.ts.map +1 -0
- package/types/slotted-angular-currency-field.d.ts +480 -0
- package/types/slotted-angular-currency-field.d.ts.map +1 -0
- package/types/slotted-angular-dashboard-grid.d.ts +341 -0
- package/types/slotted-angular-dashboard-grid.d.ts.map +1 -0
- package/types/slotted-angular-data-grid.d.ts +1077 -0
- package/types/slotted-angular-data-grid.d.ts.map +1 -0
- package/types/slotted-angular-data-list.d.ts +272 -0
- package/types/slotted-angular-data-list.d.ts.map +1 -0
- package/types/slotted-angular-date-field.d.ts +320 -0
- package/types/slotted-angular-date-field.d.ts.map +1 -0
- package/types/slotted-angular-date-picker.d.ts +224 -0
- package/types/slotted-angular-date-picker.d.ts.map +1 -0
- package/types/slotted-angular-date-range-picker.d.ts +310 -0
- package/types/slotted-angular-date-range-picker.d.ts.map +1 -0
- package/types/slotted-angular-datetime-field.d.ts +362 -0
- package/types/slotted-angular-datetime-field.d.ts.map +1 -0
- package/types/slotted-angular-datetime-picker.d.ts +370 -0
- package/types/slotted-angular-datetime-picker.d.ts.map +1 -0
- package/types/slotted-angular-datetime-range-picker.d.ts +459 -0
- package/types/slotted-angular-datetime-range-picker.d.ts.map +1 -0
- package/types/slotted-angular-description-list.d.ts +281 -0
- package/types/slotted-angular-description-list.d.ts.map +1 -0
- package/types/slotted-angular-detail-panel.d.ts +240 -0
- package/types/slotted-angular-detail-panel.d.ts.map +1 -0
- package/types/slotted-angular-dialog.d.ts +497 -0
- package/types/slotted-angular-dialog.d.ts.map +1 -0
- package/types/slotted-angular-divider.d.ts +40 -0
- package/types/slotted-angular-divider.d.ts.map +1 -0
- package/types/slotted-angular-drawer.d.ts +532 -0
- package/types/slotted-angular-drawer.d.ts.map +1 -0
- package/types/slotted-angular-entity-picker.d.ts +338 -0
- package/types/slotted-angular-entity-picker.d.ts.map +1 -0
- package/types/slotted-angular-event-calendar.d.ts +574 -0
- package/types/slotted-angular-event-calendar.d.ts.map +1 -0
- package/types/slotted-angular-field-group.d.ts +152 -0
- package/types/slotted-angular-field-group.d.ts.map +1 -0
- package/types/slotted-angular-field.d.ts +535 -0
- package/types/slotted-angular-field.d.ts.map +1 -0
- package/types/slotted-angular-filter-bar.d.ts +573 -0
- package/types/slotted-angular-filter-bar.d.ts.map +1 -0
- package/types/slotted-angular-form.d.ts +298 -0
- package/types/slotted-angular-form.d.ts.map +1 -0
- package/types/slotted-angular-fullscreen.d.ts +145 -0
- package/types/slotted-angular-fullscreen.d.ts.map +1 -0
- package/types/slotted-angular-grid.d.ts +50 -0
- package/types/slotted-angular-grid.d.ts.map +1 -0
- package/types/slotted-angular-highlight.d.ts +93 -0
- package/types/slotted-angular-highlight.d.ts.map +1 -0
- package/types/slotted-angular-hover-card.d.ts +140 -0
- package/types/slotted-angular-hover-card.d.ts.map +1 -0
- package/types/slotted-angular-i18n.d.ts +46 -0
- package/types/slotted-angular-i18n.d.ts.map +1 -0
- package/types/slotted-angular-icon.d.ts +94 -0
- package/types/slotted-angular-icon.d.ts.map +1 -0
- package/types/slotted-angular-image.d.ts +251 -0
- package/types/slotted-angular-image.d.ts.map +1 -0
- package/types/slotted-angular-import-export-center.d.ts +351 -0
- package/types/slotted-angular-import-export-center.d.ts.map +1 -0
- package/types/slotted-angular-inline-message.d.ts +195 -0
- package/types/slotted-angular-inline-message.d.ts.map +1 -0
- package/types/slotted-angular-inline.d.ts +41 -0
- package/types/slotted-angular-inline.d.ts.map +1 -0
- package/types/slotted-angular-kbd.d.ts +174 -0
- package/types/slotted-angular-kbd.d.ts.map +1 -0
- package/types/slotted-angular-link.d.ts +94 -0
- package/types/slotted-angular-link.d.ts.map +1 -0
- package/types/slotted-angular-list-item.d.ts +210 -0
- package/types/slotted-angular-list-item.d.ts.map +1 -0
- package/types/slotted-angular-list.d.ts +176 -0
- package/types/slotted-angular-list.d.ts.map +1 -0
- package/types/slotted-angular-listbox.d.ts +470 -0
- package/types/slotted-angular-listbox.d.ts.map +1 -0
- package/types/slotted-angular-loading-overlay.d.ts +219 -0
- package/types/slotted-angular-loading-overlay.d.ts.map +1 -0
- package/types/slotted-angular-markdown.d.ts +172 -0
- package/types/slotted-angular-markdown.d.ts.map +1 -0
- package/types/slotted-angular-menu.d.ts +448 -0
- package/types/slotted-angular-menu.d.ts.map +1 -0
- package/types/slotted-angular-menubar.d.ts +90 -0
- package/types/slotted-angular-menubar.d.ts.map +1 -0
- package/types/slotted-angular-message-scroller.d.ts +151 -0
- package/types/slotted-angular-message-scroller.d.ts.map +1 -0
- package/types/slotted-angular-message.d.ts +348 -0
- package/types/slotted-angular-message.d.ts.map +1 -0
- package/types/slotted-angular-multi-select.d.ts +462 -0
- package/types/slotted-angular-multi-select.d.ts.map +1 -0
- package/types/slotted-angular-navigation-menu.d.ts +309 -0
- package/types/slotted-angular-navigation-menu.d.ts.map +1 -0
- package/types/slotted-angular-notification-center.d.ts +318 -0
- package/types/slotted-angular-notification-center.d.ts.map +1 -0
- package/types/slotted-angular-number-field.d.ts +402 -0
- package/types/slotted-angular-number-field.d.ts.map +1 -0
- package/types/slotted-angular-otp-input.d.ts +286 -0
- package/types/slotted-angular-otp-input.d.ts.map +1 -0
- package/types/slotted-angular-page-header.d.ts +334 -0
- package/types/slotted-angular-page-header.d.ts.map +1 -0
- package/types/slotted-angular-page.d.ts +141 -0
- package/types/slotted-angular-page.d.ts.map +1 -0
- package/types/slotted-angular-pagination.d.ts +213 -0
- package/types/slotted-angular-pagination.d.ts.map +1 -0
- package/types/slotted-angular-popover.d.ts +366 -0
- package/types/slotted-angular-popover.d.ts.map +1 -0
- package/types/slotted-angular-progress-indicator.d.ts +312 -0
- package/types/slotted-angular-progress-indicator.d.ts.map +1 -0
- package/types/slotted-angular-prompt-composer.d.ts +242 -0
- package/types/slotted-angular-prompt-composer.d.ts.map +1 -0
- package/types/slotted-angular-prose.d.ts +171 -0
- package/types/slotted-angular-prose.d.ts.map +1 -0
- package/types/slotted-angular-radio-group.d.ts +268 -0
- package/types/slotted-angular-radio-group.d.ts.map +1 -0
- package/types/slotted-angular-rating.d.ts +374 -0
- package/types/slotted-angular-rating.d.ts.map +1 -0
- package/types/slotted-angular-result-state.d.ts +217 -0
- package/types/slotted-angular-result-state.d.ts.map +1 -0
- package/types/slotted-angular-saved-views.d.ts +198 -0
- package/types/slotted-angular-saved-views.d.ts.map +1 -0
- package/types/slotted-angular-scroll-area.d.ts +186 -0
- package/types/slotted-angular-scroll-area.d.ts.map +1 -0
- package/types/slotted-angular-section.d.ts +143 -0
- package/types/slotted-angular-section.d.ts.map +1 -0
- package/types/slotted-angular-segmented-control.d.ts +251 -0
- package/types/slotted-angular-segmented-control.d.ts.map +1 -0
- package/types/slotted-angular-select.d.ts +507 -0
- package/types/slotted-angular-select.d.ts.map +1 -0
- package/types/slotted-angular-side-navigation.d.ts +373 -0
- package/types/slotted-angular-side-navigation.d.ts.map +1 -0
- package/types/slotted-angular-skeleton.d.ts +198 -0
- package/types/slotted-angular-skeleton.d.ts.map +1 -0
- package/types/slotted-angular-slider.d.ts +216 -0
- package/types/slotted-angular-slider.d.ts.map +1 -0
- package/types/slotted-angular-sparkline.d.ts +106 -0
- package/types/slotted-angular-sparkline.d.ts.map +1 -0
- package/types/slotted-angular-split-button.d.ts +180 -0
- package/types/slotted-angular-split-button.d.ts.map +1 -0
- package/types/slotted-angular-splitter.d.ts +206 -0
- package/types/slotted-angular-splitter.d.ts.map +1 -0
- package/types/slotted-angular-stack.d.ts +38 -0
- package/types/slotted-angular-stack.d.ts.map +1 -0
- package/types/slotted-angular-stat-card.d.ts +232 -0
- package/types/slotted-angular-stat-card.d.ts.map +1 -0
- package/types/slotted-angular-status-indicator.d.ts +106 -0
- package/types/slotted-angular-status-indicator.d.ts.map +1 -0
- package/types/slotted-angular-stepper.d.ts +198 -0
- package/types/slotted-angular-stepper.d.ts.map +1 -0
- package/types/slotted-angular-switch.d.ts +243 -0
- package/types/slotted-angular-switch.d.ts.map +1 -0
- package/types/slotted-angular-table-of-contents.d.ts +210 -0
- package/types/slotted-angular-table-of-contents.d.ts.map +1 -0
- package/types/slotted-angular-table.d.ts +888 -0
- package/types/slotted-angular-table.d.ts.map +1 -0
- package/types/slotted-angular-tabs.d.ts +340 -0
- package/types/slotted-angular-tabs.d.ts.map +1 -0
- package/types/slotted-angular-tag.d.ts +279 -0
- package/types/slotted-angular-tag.d.ts.map +1 -0
- package/types/slotted-angular-tags-input.d.ts +302 -0
- package/types/slotted-angular-tags-input.d.ts.map +1 -0
- package/types/slotted-angular-text-field.d.ts +334 -0
- package/types/slotted-angular-text-field.d.ts.map +1 -0
- package/types/slotted-angular-textarea.d.ts +150 -0
- package/types/slotted-angular-textarea.d.ts.map +1 -0
- package/types/slotted-angular-theme.d.ts +26 -0
- package/types/slotted-angular-theme.d.ts.map +1 -0
- package/types/slotted-angular-time-field.d.ts +300 -0
- package/types/slotted-angular-time-field.d.ts.map +1 -0
- package/types/slotted-angular-time-picker.d.ts +260 -0
- package/types/slotted-angular-time-picker.d.ts.map +1 -0
- package/types/slotted-angular-time-range-picker.d.ts +401 -0
- package/types/slotted-angular-time-range-picker.d.ts.map +1 -0
- package/types/slotted-angular-timeline.d.ts +329 -0
- package/types/slotted-angular-timeline.d.ts.map +1 -0
- package/types/slotted-angular-toast.d.ts +340 -0
- package/types/slotted-angular-toast.d.ts.map +1 -0
- package/types/slotted-angular-toggle-group.d.ts +167 -0
- package/types/slotted-angular-toggle-group.d.ts.map +1 -0
- package/types/slotted-angular-toggle.d.ts +106 -0
- package/types/slotted-angular-toggle.d.ts.map +1 -0
- package/types/slotted-angular-toolbar.d.ts +252 -0
- package/types/slotted-angular-toolbar.d.ts.map +1 -0
- package/types/slotted-angular-tooltip.d.ts +388 -0
- package/types/slotted-angular-tooltip.d.ts.map +1 -0
- package/types/slotted-angular-top-navigation.d.ts +442 -0
- package/types/slotted-angular-top-navigation.d.ts.map +1 -0
- package/types/slotted-angular-tour.d.ts +440 -0
- package/types/slotted-angular-tour.d.ts.map +1 -0
- package/types/slotted-angular-transfer.d.ts +296 -0
- package/types/slotted-angular-transfer.d.ts.map +1 -0
- package/types/slotted-angular-tree.d.ts +499 -0
- package/types/slotted-angular-tree.d.ts.map +1 -0
- package/types/slotted-angular-typography.d.ts +89 -0
- package/types/slotted-angular-typography.d.ts.map +1 -0
- package/types/slotted-angular-upload.d.ts +365 -0
- package/types/slotted-angular-upload.d.ts.map +1 -0
- package/types/slotted-angular-visually-hidden.d.ts +19 -0
- package/types/slotted-angular-visually-hidden.d.ts.map +1 -0
- package/types/slotted-angular-wizard.d.ts +441 -0
- package/types/slotted-angular-wizard.d.ts.map +1 -0
- package/types/slotted-angular.d.ts +3 -0
- package/types/slotted-angular.d.ts.map +1 -0
|
@@ -0,0 +1,1308 @@
|
|
|
1
|
+
import { createDismissableLayer } from '@slotted/core/dismissable-layer';
|
|
2
|
+
import { COMPACT_BELOW, createWidthGate } from '@slotted/core/measure';
|
|
3
|
+
import { createPresence } from '@slotted/core/presence';
|
|
4
|
+
import { createControllable } from '@slotted/core/state';
|
|
5
|
+
import { SlAppShellBanner } from '@slotted/angular/app-shell';
|
|
6
|
+
import { injectMessages } from '@slotted/angular/i18n';
|
|
7
|
+
import { topNavigationMessages } from '@slotted/core/i18n';
|
|
8
|
+
import * as i0 from '@angular/core';
|
|
9
|
+
import { InjectionToken, inject, Injectable, model, input, booleanAttribute, output, ElementRef, computed, signal, DestroyRef, effect, ViewEncapsulation, ChangeDetectionStrategy, Component, HostAttributeToken, Directive, afterNextRender, untracked, forwardRef } from '@angular/core';
|
|
10
|
+
import * as i2 from '@slotted/angular/tooltip';
|
|
11
|
+
import { SlTooltip, provideTooltipDefaults, SlTooltipLayer, SlTooltipContent } from '@slotted/angular/tooltip';
|
|
12
|
+
import { SlGlyph, SlIcon } from '@slotted/angular/icon';
|
|
13
|
+
import * as i1 from '@slotted/angular/navigation-menu';
|
|
14
|
+
import { SlNavigationMenu, SlNavigationMenuIdFactory, NAVIGATION_MENU_SECTION, SlNavigationMenuTriggerWiring } from '@slotted/angular/navigation-menu';
|
|
15
|
+
|
|
16
|
+
/** The contract's defaults. */
|
|
17
|
+
const TOP_NAVIGATION_FALLBACK = {
|
|
18
|
+
frame: true,
|
|
19
|
+
landmark: true,
|
|
20
|
+
size: 'md',
|
|
21
|
+
};
|
|
22
|
+
/**
|
|
23
|
+
* The three steps of the bar's width, in CSS pixels, under which each
|
|
24
|
+
* priority folds. The stylesheet reads the same three literals in its
|
|
25
|
+
* container conditions; this is the copy the script reads. `medium` is the
|
|
26
|
+
* compact size class's limit, where app-shell overlays its regions.
|
|
27
|
+
*/
|
|
28
|
+
const TOP_NAVIGATION_COLLAPSE_AT = {
|
|
29
|
+
high: 480,
|
|
30
|
+
low: 1024,
|
|
31
|
+
medium: COMPACT_BELOW,
|
|
32
|
+
};
|
|
33
|
+
const TOP_NAVIGATION_DEFAULTS = new InjectionToken('slotted top-navigation defaults', { providedIn: 'root', factory: () => TOP_NAVIGATION_FALLBACK });
|
|
34
|
+
/**
|
|
35
|
+
* An application decides once how its bars read — the size, the frame —
|
|
36
|
+
* rather than repeating it on every bar in a product. A bar that states any of
|
|
37
|
+
* them itself still wins. Its words come from the language in force
|
|
38
|
+
* (`provideSlotted`).
|
|
39
|
+
*/
|
|
40
|
+
function provideTopNavigationDefaults(defaults) {
|
|
41
|
+
return {
|
|
42
|
+
provide: TOP_NAVIGATION_DEFAULTS,
|
|
43
|
+
useFactory: () => ({ ...TOP_NAVIGATION_FALLBACK, ...defaults }),
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
/** What a bar renders as here, before it states anything of its own. */
|
|
47
|
+
function injectTopNavigationDefaults() {
|
|
48
|
+
return inject(TOP_NAVIGATION_DEFAULTS);
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Application-scoped rather than module-scoped, for the reason `field` records:
|
|
52
|
+
* a module-level counter produces colliding sequences when two applications
|
|
53
|
+
* render in one server process, and the server and the client sequences must
|
|
54
|
+
* match for hydration.
|
|
55
|
+
*/
|
|
56
|
+
class SlTopNavigationIdFactory {
|
|
57
|
+
count = 0;
|
|
58
|
+
next() {
|
|
59
|
+
this.count += 1;
|
|
60
|
+
return `slotted-top-navigation-${this.count}`;
|
|
61
|
+
}
|
|
62
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationIdFactory, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
63
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationIdFactory, providedIn: 'root' });
|
|
64
|
+
}
|
|
65
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationIdFactory, decorators: [{
|
|
66
|
+
type: Injectable,
|
|
67
|
+
args: [{ providedIn: 'root' }]
|
|
68
|
+
}] });
|
|
69
|
+
|
|
70
|
+
/** Every control a reader can land on in the bar, in DOM order. */
|
|
71
|
+
const TOP_NAVIGATION_CONTROL_SELECTOR = '[data-part="skip"], [data-part="home"][href], [data-part="link"], [data-part="trigger"], [data-part="more"], [data-part="search"] input, [data-part="search-toggle"], [data-part="help"], [data-part="notifications"], [data-part="account"]';
|
|
72
|
+
/**
|
|
73
|
+
* The bar across the top of an application: the mark, the context, the
|
|
74
|
+
* destinations, the search and the global actions, folding by priority as
|
|
75
|
+
* its own width goes.
|
|
76
|
+
*
|
|
77
|
+
* The directive goes on the consumer's own element — `<header slTopNavigation>`
|
|
78
|
+
* standing alone, `<div slTopNavigation>` inside `app-shell`'s banner, which
|
|
79
|
+
* is already the banner landmark and already paints the bar's ground.
|
|
80
|
+
*
|
|
81
|
+
* **Three values, three models.** `value` is the current destination,
|
|
82
|
+
* `moreOpen` the panel and `searchOpen` the search. Which items fold is not a
|
|
83
|
+
* fourth: it is read from the width and reported as a fact — `data-collapsed`
|
|
84
|
+
* on the item, the count on `more`, `collapseChange` when the set moves.
|
|
85
|
+
*
|
|
86
|
+
* **The panel is the same DOM.** A folded item, the context and the help are
|
|
87
|
+
* moved into the panel while it is present and moved back when it has left,
|
|
88
|
+
* which is what the CDK's `DomPortalOutlet` does with a template's nodes.
|
|
89
|
+
*/
|
|
90
|
+
class SlTopNavigation {
|
|
91
|
+
/** The current destination's value. Two-way, so a template may bind it directly. */
|
|
92
|
+
value = model(null, /* @ts-ignore */
|
|
93
|
+
...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
|
|
94
|
+
/** Whether the panel is shown. */
|
|
95
|
+
moreOpen = model(false, /* @ts-ignore */
|
|
96
|
+
...(ngDevMode ? [{ debugName: "moreOpen" }] : /* istanbul ignore next */ []));
|
|
97
|
+
/** Whether the search takes the bar, below the medium step. */
|
|
98
|
+
searchOpen = model(false, /* @ts-ignore */
|
|
99
|
+
...(ngDevMode ? [{ debugName: "searchOpen" }] : /* istanbul ignore next */ []));
|
|
100
|
+
size = input(undefined, /* @ts-ignore */
|
|
101
|
+
...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
102
|
+
/**
|
|
103
|
+
* Whether the root paints its own ground, rule and inset. Unstated, it does
|
|
104
|
+
* on its own and does not inside `app-shell`'s banner.
|
|
105
|
+
*/
|
|
106
|
+
frame = input(undefined, { ...(ngDevMode ? { debugName: "frame" } : /* istanbul ignore next */ {}), transform: (state) => (state === undefined ? undefined : booleanAttribute(state)) });
|
|
107
|
+
/**
|
|
108
|
+
* Whether the root is the banner landmark. Unstated, it is one on its own and
|
|
109
|
+
* not inside `app-shell`'s banner, which already is. The element is the
|
|
110
|
+
* consumer's — `header` or `div` — and `landmark` decides nothing about it
|
|
111
|
+
* here; it is read by the reference page and the tests as the intent.
|
|
112
|
+
*/
|
|
113
|
+
landmark = input(undefined, { ...(ngDevMode ? { debugName: "landmark" } : /* istanbul ignore next */ {}), transform: (state) => (state === undefined ? undefined : booleanAttribute(state)) });
|
|
114
|
+
/** The id of the element the skip link jumps to. Absent, no skip link is rendered. */
|
|
115
|
+
skipTo = input(undefined, /* @ts-ignore */
|
|
116
|
+
...(ngDevMode ? [{ debugName: "skipTo" }] : /* istanbul ignore next */ []));
|
|
117
|
+
/**
|
|
118
|
+
* Words laid over the catalog of the language in force, key by key: the
|
|
119
|
+
* landmark's name, the names of the controls with no visible text, and the
|
|
120
|
+
* skip link. A static `aria-label` on a part still wins.
|
|
121
|
+
*/
|
|
122
|
+
messages = input(undefined, /* @ts-ignore */
|
|
123
|
+
...(ngDevMode ? [{ debugName: "messages" }] : /* istanbul ignore next */ []));
|
|
124
|
+
/** One output for one transition, carrying the reason and the event. */
|
|
125
|
+
valueChangeRequest = output();
|
|
126
|
+
moreOpenChangeRequest = output();
|
|
127
|
+
searchOpenChangeRequest = output();
|
|
128
|
+
/** The folded set moved: the values, in DOM order. */
|
|
129
|
+
collapseChange = output();
|
|
130
|
+
defaults = injectTopNavigationDefaults();
|
|
131
|
+
shell = inject(SlAppShellBanner, { optional: true });
|
|
132
|
+
host = inject(ElementRef).nativeElement;
|
|
133
|
+
ids = (() => {
|
|
134
|
+
const id = inject(SlTopNavigationIdFactory).next();
|
|
135
|
+
return { moreId: `${id}-more`, panelId: `${id}-panel` };
|
|
136
|
+
})();
|
|
137
|
+
resolvedSize = computed(() => this.size() ?? this.defaults.size, /* @ts-ignore */
|
|
138
|
+
...(ngDevMode ? [{ debugName: "resolvedSize" }] : /* istanbul ignore next */ []));
|
|
139
|
+
resolvedFrame = computed(() => this.frame() ?? (this.shell === null ? this.defaults.frame : false), /* @ts-ignore */
|
|
140
|
+
...(ngDevMode ? [{ debugName: "resolvedFrame" }] : /* istanbul ignore next */ []));
|
|
141
|
+
resolvedLandmark = computed(() => this.landmark() ?? (this.shell === null ? this.defaults.landmark : false), /* @ts-ignore */
|
|
142
|
+
...(ngDevMode ? [{ debugName: "resolvedLandmark" }] : /* istanbul ignore next */ []));
|
|
143
|
+
/** The family's words in the language in force, with this bar's `messages` laid over them. */
|
|
144
|
+
t = injectMessages(topNavigationMessages, this.messages);
|
|
145
|
+
/** The three steps, measured: each gate reports once per crossing. */
|
|
146
|
+
underLow = signal(false, /* @ts-ignore */
|
|
147
|
+
...(ngDevMode ? [{ debugName: "underLow" }] : /* istanbul ignore next */ []));
|
|
148
|
+
underMedium = signal(false, /* @ts-ignore */
|
|
149
|
+
...(ngDevMode ? [{ debugName: "underMedium" }] : /* istanbul ignore next */ []));
|
|
150
|
+
underHigh = signal(false, /* @ts-ignore */
|
|
151
|
+
...(ngDevMode ? [{ debugName: "underHigh" }] : /* istanbul ignore next */ []));
|
|
152
|
+
/** Whether the width is under the medium step, where the search is its toggle and the context moves to the panel. */
|
|
153
|
+
narrow = this.underMedium.asReadonly();
|
|
154
|
+
/** Whether the width is under the high step, where help moves to the panel. */
|
|
155
|
+
narrowest = this.underHigh.asReadonly();
|
|
156
|
+
/** The priorities the width has folded. */
|
|
157
|
+
folded = computed(() => {
|
|
158
|
+
const set = new Set();
|
|
159
|
+
if (this.underLow())
|
|
160
|
+
set.add('low');
|
|
161
|
+
if (this.underMedium())
|
|
162
|
+
set.add('medium');
|
|
163
|
+
if (this.underHigh())
|
|
164
|
+
set.add('high');
|
|
165
|
+
return set;
|
|
166
|
+
}, /* @ts-ignore */
|
|
167
|
+
...(ngDevMode ? [{ debugName: "folded" }] : /* istanbul ignore next */ []));
|
|
168
|
+
items = signal(new Map(), /* @ts-ignore */
|
|
169
|
+
...(ngDevMode ? [{ debugName: "items" }] : /* istanbul ignore next */ []));
|
|
170
|
+
order = 0;
|
|
171
|
+
/** The values of the folded items, in DOM order. */
|
|
172
|
+
collapsed = computed(() => [...this.items().entries()]
|
|
173
|
+
.filter(([, record]) => this.folded().has(record.priority))
|
|
174
|
+
.sort(([, a], [, b]) => a.order - b.order)
|
|
175
|
+
.map(([value]) => value), /* @ts-ignore */
|
|
176
|
+
...(ngDevMode ? [{ debugName: "collapsed" }] : /* istanbul ignore next */ []));
|
|
177
|
+
/** Whether a folded item holds the current destination. */
|
|
178
|
+
currentFolded = computed(() => {
|
|
179
|
+
const current = this.value();
|
|
180
|
+
return [...this.items().entries()].some(([value, record]) => this.folded().has(record.priority) && (record.current || value === current));
|
|
181
|
+
}, /* @ts-ignore */
|
|
182
|
+
...(ngDevMode ? [{ debugName: "currentFolded" }] : /* istanbul ignore next */ []));
|
|
183
|
+
hasSearch = signal(false, /* @ts-ignore */
|
|
184
|
+
...(ngDevMode ? [{ debugName: "hasSearch" }] : /* istanbul ignore next */ []));
|
|
185
|
+
hasContext = signal(false, /* @ts-ignore */
|
|
186
|
+
...(ngDevMode ? [{ debugName: "hasContext" }] : /* istanbul ignore next */ []));
|
|
187
|
+
hasHelp = signal(false, /* @ts-ignore */
|
|
188
|
+
...(ngDevMode ? [{ debugName: "hasHelp" }] : /* istanbul ignore next */ []));
|
|
189
|
+
/** Whether the panel has anything to show. */
|
|
190
|
+
panelHolds = computed(() => this.collapsed().length > 0 ||
|
|
191
|
+
(this.narrow() && this.hasContext()) ||
|
|
192
|
+
(this.narrowest() && this.hasHelp()), /* @ts-ignore */
|
|
193
|
+
...(ngDevMode ? [{ debugName: "panelHolds" }] : /* istanbul ignore next */ []));
|
|
194
|
+
searchTakesBar = computed(() => this.narrow() && this.hasSearch() && this.searchOpen(), /* @ts-ignore */
|
|
195
|
+
...(ngDevMode ? [{ debugName: "searchTakesBar" }] : /* istanbul ignore next */ []));
|
|
196
|
+
/** The panel, its list and the button that opens it, once they are in the document. */
|
|
197
|
+
panelNode = signal(null, /* @ts-ignore */
|
|
198
|
+
...(ngDevMode ? [{ debugName: "panelNode" }] : /* istanbul ignore next */ []));
|
|
199
|
+
panelListNode = signal(null, /* @ts-ignore */
|
|
200
|
+
...(ngDevMode ? [{ debugName: "panelListNode" }] : /* istanbul ignore next */ []));
|
|
201
|
+
moreNode = signal(null, /* @ts-ignore */
|
|
202
|
+
...(ngDevMode ? [{ debugName: "moreNode" }] : /* istanbul ignore next */ []));
|
|
203
|
+
searchNode = signal(null, /* @ts-ignore */
|
|
204
|
+
...(ngDevMode ? [{ debugName: "searchNode" }] : /* istanbul ignore next */ []));
|
|
205
|
+
searchToggleNode = signal(null, /* @ts-ignore */
|
|
206
|
+
...(ngDevMode ? [{ debugName: "searchToggleNode" }] : /* istanbul ignore next */ []));
|
|
207
|
+
panelStatus = signal('unmounted', /* @ts-ignore */
|
|
208
|
+
...(ngDevMode ? [{ debugName: "panelStatus" }] : /* istanbul ignore next */ []));
|
|
209
|
+
/** Whether the panel is present: open, or on its way out. */
|
|
210
|
+
panelPresent = computed(() => this.panelStatus() !== 'unmounted', /* @ts-ignore */
|
|
211
|
+
...(ngDevMode ? [{ debugName: "panelPresent" }] : /* istanbul ignore next */ []));
|
|
212
|
+
presence = createPresence({
|
|
213
|
+
present: false,
|
|
214
|
+
onStatusChange: (next) => this.panelStatus.set(next),
|
|
215
|
+
});
|
|
216
|
+
dismissable = null;
|
|
217
|
+
constructor() {
|
|
218
|
+
const destroyRef = inject(DestroyRef);
|
|
219
|
+
/* The gate measures once on creation and again on every resize where a ResizeObserver exists. */
|
|
220
|
+
const gates = [
|
|
221
|
+
createWidthGate(this.host, {
|
|
222
|
+
at: TOP_NAVIGATION_COLLAPSE_AT.low,
|
|
223
|
+
onChange: (narrow) => this.underLow.set(narrow),
|
|
224
|
+
}),
|
|
225
|
+
createWidthGate(this.host, {
|
|
226
|
+
at: TOP_NAVIGATION_COLLAPSE_AT.medium,
|
|
227
|
+
onChange: (narrow) => this.underMedium.set(narrow),
|
|
228
|
+
}),
|
|
229
|
+
createWidthGate(this.host, {
|
|
230
|
+
at: TOP_NAVIGATION_COLLAPSE_AT.high,
|
|
231
|
+
onChange: (narrow) => this.underHigh.set(narrow),
|
|
232
|
+
}),
|
|
233
|
+
];
|
|
234
|
+
this.underLow.set(gates[0].narrow());
|
|
235
|
+
this.underMedium.set(gates[1].narrow());
|
|
236
|
+
this.underHigh.set(gates[2].narrow());
|
|
237
|
+
destroyRef.onDestroy(() => {
|
|
238
|
+
for (const gate of gates)
|
|
239
|
+
gate.destroy();
|
|
240
|
+
});
|
|
241
|
+
/* The folded set is a fact the consumer is told about when it moves. */
|
|
242
|
+
let reported = null;
|
|
243
|
+
effect(() => {
|
|
244
|
+
const collapsed = this.collapsed();
|
|
245
|
+
const key = collapsed.join('');
|
|
246
|
+
if (reported === key)
|
|
247
|
+
return;
|
|
248
|
+
const first = reported === null;
|
|
249
|
+
reported = key;
|
|
250
|
+
if (!first || collapsed.length > 0)
|
|
251
|
+
this.collapseChange.emit(collapsed);
|
|
252
|
+
});
|
|
253
|
+
/* Nothing folded takes the panel with it: a transition, not a state. */
|
|
254
|
+
let held = this.panelHolds();
|
|
255
|
+
effect(() => {
|
|
256
|
+
const holds = this.panelHolds();
|
|
257
|
+
const before = held;
|
|
258
|
+
held = holds;
|
|
259
|
+
if (before && !holds && this.moreOpen())
|
|
260
|
+
this.setMoreOpen(false, 'resize');
|
|
261
|
+
});
|
|
262
|
+
/* The width passing the medium step takes the open search back to its place. */
|
|
263
|
+
let wasNarrow = this.narrow();
|
|
264
|
+
effect(() => {
|
|
265
|
+
const narrow = this.narrow();
|
|
266
|
+
const before = wasNarrow;
|
|
267
|
+
wasNarrow = narrow;
|
|
268
|
+
if (before && !narrow && this.searchOpen())
|
|
269
|
+
this.setSearchOpen(false, 'resize');
|
|
270
|
+
});
|
|
271
|
+
effect(() => this.presence.sync(this.moreOpen()));
|
|
272
|
+
effect(() => this.presence.setNode(this.panelNode()));
|
|
273
|
+
effect(() => this.stack());
|
|
274
|
+
destroyRef.onDestroy(() => {
|
|
275
|
+
this.presence.destroy();
|
|
276
|
+
this.dismissable?.destroy();
|
|
277
|
+
this.dismissable = null;
|
|
278
|
+
});
|
|
279
|
+
}
|
|
280
|
+
/** An item says what it is. */
|
|
281
|
+
registerItem(value, priority, current) {
|
|
282
|
+
this.items.update((previous) => {
|
|
283
|
+
const next = new Map(previous);
|
|
284
|
+
next.set(value, {
|
|
285
|
+
current,
|
|
286
|
+
order: previous.get(value)?.order ?? (this.order += 1),
|
|
287
|
+
priority,
|
|
288
|
+
});
|
|
289
|
+
return next;
|
|
290
|
+
});
|
|
291
|
+
return () => {
|
|
292
|
+
this.items.update((previous) => {
|
|
293
|
+
if (!previous.has(value))
|
|
294
|
+
return previous;
|
|
295
|
+
const next = new Map(previous);
|
|
296
|
+
next.delete(value);
|
|
297
|
+
return next;
|
|
298
|
+
});
|
|
299
|
+
};
|
|
300
|
+
}
|
|
301
|
+
/** The order an item registered in, so the panel keeps the list's order. */
|
|
302
|
+
orderOf(value) {
|
|
303
|
+
return this.items().get(value)?.order ?? Number.MAX_SAFE_INTEGER;
|
|
304
|
+
}
|
|
305
|
+
/** Escape and a press outside close the panel; `more` is a branch, so a press on it toggles. */
|
|
306
|
+
stack() {
|
|
307
|
+
const open = this.moreOpen();
|
|
308
|
+
const panel = this.panelNode();
|
|
309
|
+
const more = this.moreNode();
|
|
310
|
+
this.dismissable?.destroy();
|
|
311
|
+
this.dismissable = null;
|
|
312
|
+
if (panel === null || !open)
|
|
313
|
+
return;
|
|
314
|
+
this.dismissable = createDismissableLayer(panel, {
|
|
315
|
+
escape: true,
|
|
316
|
+
focusOutside: false,
|
|
317
|
+
modal: false,
|
|
318
|
+
outsidePress: true,
|
|
319
|
+
scrollLock: false,
|
|
320
|
+
...(more ? { branches: [more] } : {}),
|
|
321
|
+
onDismiss: (request) => {
|
|
322
|
+
const reason = request.reason === 'escape' ? 'escape' : 'outsidePress';
|
|
323
|
+
this.setMoreOpen(false, reason, request.source);
|
|
324
|
+
if (reason === 'escape')
|
|
325
|
+
more?.focus();
|
|
326
|
+
},
|
|
327
|
+
});
|
|
328
|
+
}
|
|
329
|
+
/** Asks the panel to open or close. */
|
|
330
|
+
setMoreOpen(next, reason, source) {
|
|
331
|
+
const state = createControllable({
|
|
332
|
+
initial: this.moreOpen(),
|
|
333
|
+
onRequest: (request) => this.moreOpenChangeRequest.emit(request),
|
|
334
|
+
});
|
|
335
|
+
if (state.request(next, reason, source))
|
|
336
|
+
this.moreOpen.set(next);
|
|
337
|
+
}
|
|
338
|
+
/** Asks the search to open or close. */
|
|
339
|
+
setSearchOpen(next, reason, source) {
|
|
340
|
+
const state = createControllable({
|
|
341
|
+
initial: this.searchOpen(),
|
|
342
|
+
onRequest: (request) => this.searchOpenChangeRequest.emit(request),
|
|
343
|
+
});
|
|
344
|
+
if (state.request(next, reason, source))
|
|
345
|
+
this.searchOpen.set(next);
|
|
346
|
+
}
|
|
347
|
+
/** Asks the current destination to move. */
|
|
348
|
+
select(next, reason, source) {
|
|
349
|
+
const state = createControllable({
|
|
350
|
+
initial: this.value(),
|
|
351
|
+
onRequest: (request) => this.valueChangeRequest.emit(request),
|
|
352
|
+
});
|
|
353
|
+
if (state.request(next, reason, source))
|
|
354
|
+
this.value.set(next);
|
|
355
|
+
}
|
|
356
|
+
/** Opens the panel, with the reason `programmatic`. */
|
|
357
|
+
openMore() {
|
|
358
|
+
this.setMoreOpen(true, 'programmatic');
|
|
359
|
+
}
|
|
360
|
+
/** Closes the panel, with the reason `programmatic`. */
|
|
361
|
+
closeMore() {
|
|
362
|
+
this.setMoreOpen(false, 'programmatic');
|
|
363
|
+
}
|
|
364
|
+
/** Focuses the first control in the bar. */
|
|
365
|
+
focus() {
|
|
366
|
+
this.host.querySelector(TOP_NAVIGATION_CONTROL_SELECTOR)?.focus();
|
|
367
|
+
}
|
|
368
|
+
/** Opens the search where it is a toggle, and focuses the field either way. */
|
|
369
|
+
focusSearch() {
|
|
370
|
+
if (this.narrow() && this.hasSearch() && !this.searchOpen()) {
|
|
371
|
+
this.setSearchOpen(true, 'programmatic');
|
|
372
|
+
return;
|
|
373
|
+
}
|
|
374
|
+
this.searchNode()?.querySelector('input, [contenteditable]')?.focus();
|
|
375
|
+
}
|
|
376
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigation, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
377
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: SlTopNavigation, isStandalone: true, selector: "[slTopNavigation]", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, moreOpen: { classPropertyName: "moreOpen", publicName: "moreOpen", isSignal: true, isRequired: false, transformFunction: null }, searchOpen: { classPropertyName: "searchOpen", publicName: "searchOpen", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, frame: { classPropertyName: "frame", publicName: "frame", isSignal: true, isRequired: false, transformFunction: null }, landmark: { classPropertyName: "landmark", publicName: "landmark", isSignal: true, isRequired: false, transformFunction: null }, skipTo: { classPropertyName: "skipTo", publicName: "skipTo", isSignal: true, isRequired: false, transformFunction: null }, messages: { classPropertyName: "messages", publicName: "messages", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { value: "valueChange", moreOpen: "moreOpenChange", searchOpen: "searchOpenChange", valueChangeRequest: "valueChangeRequest", moreOpenChangeRequest: "moreOpenChangeRequest", searchOpenChangeRequest: "searchOpenChangeRequest", collapseChange: "collapseChange" }, host: { attributes: { "data-ui": "top-navigation", "data-part": "root" }, properties: { "attr.data-size": "resolvedSize()", "attr.data-frame": "resolvedFrame() ? '' : null", "attr.data-search-open": "searchTakesBar() ? '' : null" } }, exportAs: ["slTopNavigation"], ngImport: i0, template: `@if (skipTo()) {
|
|
378
|
+
<a data-part="skip" [attr.href]="'#' + skipTo()">{{ t('skip') }}</a>
|
|
379
|
+
}
|
|
380
|
+
<ng-content />`, isInline: true, styles: ["@layer slotted.components{[data-ui=top-navigation]{--_control-height: var(--slotted-control-height-md, 34px);--_control-padding: var(--slotted-control-padding-inline-md, 13px);--_control-font-size: var(--slotted-control-font-size-md, 13px);--_icon-size: var(--slotted-control-icon-size-md, 16px);--_gap: var(--slotted-control-gap-md, 8px);--_action-gap: var(--slotted-control-gap-sm, 6px);--_row-inset: var(--slotted-app-shell-row-inset, 0px);--_row-height: var(--slotted-app-shell-row-height, var(--slotted-control-height-md, 34px));--_row-font-size: var( --slotted-app-shell-row-font-size, var(--slotted-font-size-sm, .8125rem) );--_row-line-height: var( --slotted-app-shell-row-line-height, var(--slotted-line-height-sm, 1.45) );--_inset: var(--slotted-top-navigation-inset, var(--slotted-space-5, .75rem));--_block-size: var( --slotted-top-navigation-block-size, calc(var(--slotted-control-height-lg, 38px) + var(--slotted-space-5, .75rem) * 2) );--_radius: var(--slotted-top-navigation-radius, var(--slotted-control-radius, 4px));--_name-font-size: var( --slotted-top-navigation-name-font-size, var(--slotted-font-size-md, .875rem) );--_name-max: var(--slotted-top-navigation-name-max, 16rem);--_search-size: var(--slotted-top-navigation-search-size, 28rem);--_search-min: var(--slotted-top-navigation-search-min, 10rem);--_edge: 0px;--_panel-size: var(--slotted-top-navigation-panel-size, 20rem);--_mark-size: calc(var(--_control-height) - var(--slotted-space-2, .25rem) * 2);--_surface: var(--slotted-top-navigation-surface, var(--slotted-surface, Canvas));--_color: var(--slotted-top-navigation-color, var(--slotted-text, CanvasText));--_muted-color: var(--slotted-top-navigation-muted-color, var(--slotted-text-muted, GrayText));--_border-color: var( --slotted-top-navigation-border-color, var(--slotted-border-subtle, ButtonBorder) );--_hover-background: var( --slotted-top-navigation-hover-background, var(--slotted-tone-secondary-subtle-hover) );--_active-background: var( --slotted-top-navigation-active-background, var(--slotted-tone-secondary-subtle-active) );--_current-color: var(--slotted-top-navigation-current-color, var(--slotted-tone-accent-text));--_current-background: var( --slotted-top-navigation-current-background, var(--slotted-tone-accent-surface) );--_current-edge: var( --slotted-top-navigation-current-edge, var(--slotted-current-edge, transparent) );--_count-background: var( --slotted-top-navigation-count-background, var(--slotted-tone-accent-solid) );--_count-color: var(--slotted-top-navigation-count-color, var(--slotted-tone-accent-on-solid));--_panel-surface: var( --slotted-top-navigation-panel-surface, var(--slotted-surface-raised, Canvas) );--_panel-shadow: var(--slotted-top-navigation-panel-shadow, var(--slotted-shadow-md));--_panel-radius: var(--slotted-top-navigation-panel-radius, var(--slotted-radius-lg, 8px));--_disabled-color: var(--slotted-disabled-foreground, GrayText);--_rule-width: var(--slotted-border-width-thin, 1px);--_duration: var(--slotted-control-transition-duration, var(--slotted-duration-short));--_easing: var(--slotted-control-transition-easing, var(--slotted-easing-standard));align-items:center;box-sizing:border-box;color:var(--_color);container-name:slotted-top-navigation;container-type:inline-size;display:flex;font-family:var(--slotted-control-font-family, inherit);font-size:var(--_control-font-size);gap:var(--_gap);line-height:var(--slotted-control-line-height, 1);min-block-size:var(--_control-height);min-inline-size:0;flex:1 1 auto;position:relative}[data-ui=top-navigation][data-frame]{--_edge: var(--_inset);background-color:var(--_surface);border-block-end:var(--_rule-width) solid var(--_border-color);min-block-size:var(--_block-size)}[data-ui=top-navigation][data-size=sm]{--_control-height: var(--slotted-control-height-sm, 30px);--_control-padding: var(--slotted-control-padding-inline-sm, 10px);--_control-font-size: var(--slotted-control-font-size-sm, 12px);--_icon-size: var(--slotted-control-icon-size-sm, 14px);--_gap: var(--slotted-control-gap-sm, 6px);--_action-gap: var(--slotted-control-gap-sm, 6px);--_row-height: var(--slotted-control-height-sm, 30px);--_row-font-size: var(--slotted-font-size-xs, .75rem);--_row-line-height: var(--slotted-line-height-xs, 1.4);--_name-font-size: var( --slotted-top-navigation-name-font-size, var(--slotted-font-size-sm, .8125rem) );--_block-size: var( --slotted-top-navigation-block-size, calc(var(--slotted-control-height-md, 34px) + var(--slotted-space-4, .5rem) * 2) )}[data-ui=top-navigation][data-size=lg]{--_control-height: var(--slotted-control-height-lg, 38px);--_control-padding: var(--slotted-control-padding-inline-lg, 16px);--_control-font-size: var(--slotted-control-font-size-lg, 14px);--_icon-size: var(--slotted-control-icon-size-lg, 18px);--_gap: var(--slotted-control-gap-lg, 8px);--_action-gap: var(--slotted-control-gap-md, 8px);--_row-height: var(--slotted-control-height-lg, 38px);--_row-font-size: var(--slotted-font-size-md, .875rem);--_row-line-height: var(--slotted-line-height-md, 1.5);--_name-font-size: var( --slotted-top-navigation-name-font-size, var(--slotted-font-size-lg, 1rem) );--_block-size: var( --slotted-top-navigation-block-size, calc(var(--slotted-control-height-lg, 38px) + var(--slotted-space-6, 1rem) * 2) )}[data-ui=top-navigation]>[data-part=skip]{background-color:var(--_surface);block-size:var(--_control-height);border-radius:var(--_radius);box-sizing:border-box;clip-path:inset(50%);color:var(--_color);display:inline-flex;align-items:center;font-weight:var(--slotted-font-weight-semibold, 600);inset-block-start:50%;inset-inline-start:var(--_edge);padding-inline:var(--_control-padding);position:absolute;text-decoration:none;translate:0 -50%;white-space:nowrap;z-index:1}[data-ui=top-navigation]>[data-part=skip]:focus-visible{clip-path:none;outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:var(--slotted-focus-ring-offset, 2px)}[data-ui=top-navigation][data-part=root]>[data-part=brand]{align-items:center;display:flex;flex:0 1 auto;font-weight:inherit;gap:var(--_gap);padding-inline-start:calc(var(--_edge) + var(--_row-inset))}[data-ui=top-navigation][data-part=root]>[data-part=brand]>[data-part=home]{min-inline-size:var(--_control-height);overflow:visible;white-space:normal}[data-ui=top-navigation] [data-part=home]{align-items:center;border-radius:var(--_radius);color:var(--_color);display:inline-grid;flex:0 1 auto;gap:var(--_gap);grid-template-columns:auto minmax(0,1fr);min-block-size:var(--_control-height);min-inline-size:var(--_control-height);text-decoration:none}[data-ui=top-navigation] [data-part=home]:focus-visible{outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:var(--slotted-focus-ring-offset, 2px)}[data-ui=top-navigation] [data-part=mark]{align-items:center;block-size:var(--_control-height);display:inline-flex;flex:0 0 auto;inline-size:var(--_control-height);justify-content:center}[data-ui=top-navigation] [data-part=mark]>:is(svg,img){block-size:var(--_mark-size);inline-size:var(--_mark-size)}[data-ui=top-navigation] [data-part=name]{font-size:var(--_name-font-size);font-weight:var(--slotted-font-weight-semibold, 600);max-inline-size:var(--_name-max);min-inline-size:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}[data-ui=top-navigation] [data-part=context]{align-items:center;display:flex;flex:0 0 auto;gap:var(--_action-gap)}[data-ui=top-navigation] [data-part=nav]{--_control-height: inherit;--_control-padding: inherit;--_control-font-size: inherit;--_icon-size: inherit;--_gap: inherit;--_radius: inherit;--_color: inherit;--_muted-color: inherit;--_hover-background: inherit;--_active-background: inherit;--_current-color: inherit;--_current-background: inherit;--_current-edge: inherit;--_disabled-color: inherit;--_duration: inherit;--_easing: inherit;display:flex;flex:0 0 auto}[data-ui=top-navigation] [data-part=list]{align-items:center;display:flex;gap:var(--slotted-space-1, .125rem);list-style:none;margin:0;min-inline-size:0;padding:0}[data-ui=top-navigation] [data-part=item]{display:flex;flex:0 0 auto;min-inline-size:0}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>:is([data-part=link],[data-part=trigger]){align-items:center;appearance:none;background-color:transparent;border:0;border-radius:var(--_radius);box-sizing:border-box;color:var(--_color);cursor:pointer;display:inline-flex;font:inherit;font-weight:var(--slotted-font-weight-medium, 500);gap:var(--_action-gap);margin:0;min-block-size:var(--_control-height);padding-block:0;padding-inline:var(--_control-padding);text-decoration:none;transition:background-color var(--_duration) var(--_easing),color var(--_duration) var(--_easing);white-space:nowrap}[data-ui=top-navigation] [data-part=item]:not([data-disabled])>[data-part=link]:not([data-current],[aria-current=page]):hover,[data-ui=top-navigation] [data-part=item]:not([data-disabled])>[data-part=trigger]:enabled:hover{background-color:var(--_hover-background);color:var(--_color)}[data-ui=top-navigation] [data-part=item]:not([data-disabled])>[data-part=link]:not([data-current],[aria-current=page]):active,[data-ui=top-navigation] [data-part=item]:not([data-disabled])>[data-part=trigger]:enabled:active{background-color:var(--_active-background);color:var(--_color);transition-duration:var(--slotted-duration-instant)}[data-ui=top-navigation] [data-part=item]:not([data-disabled])>[data-part=trigger][data-open]:enabled{background-color:var(--_hover-background);color:var(--_color)}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=link]:is([data-current],[aria-current=page]){background-color:var(--_current-background);box-shadow:inset 0 0 0 var(--_rule-width) var(--_current-edge);color:var(--_current-color);font-weight:var(--slotted-font-weight-semibold, 600)}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item][data-disabled]>[data-part=link],[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=trigger]:disabled{color:var(--_disabled-color);cursor:not-allowed}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>:is([data-part=link],[data-part=trigger]):focus-visible{outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:var(--slotted-focus-ring-offset, 2px)}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=trigger]>[data-part=indicator]{--slotted-icon-size: var(--_icon-size);display:flex;flex:0 0 auto;margin-inline-end:calc(-1 * var(--slotted-space-2, .25rem))}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=trigger]>[data-part=indicator]>[data-ui=icon]{transition:rotate var(--slotted-duration-medium) var(--_easing)}[data-ui=top-navigation] [data-part=trigger][data-open]>[data-part=indicator]>[data-ui=icon]{rotate:.5turn}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=help],[data-part=notifications],[data-part=account],[data-part=action]){align-items:center;appearance:none;background-color:transparent;border:0;border-radius:var(--_radius);box-sizing:border-box;color:var(--_muted-color);cursor:pointer;display:inline-flex;flex:0 0 auto;font:inherit;font-weight:var(--slotted-font-weight-medium, 500);gap:var(--_action-gap);justify-content:center;margin:0;min-block-size:var(--_control-height);min-inline-size:var(--_control-height);padding:0;position:relative;text-decoration:none;transition:background-color var(--_duration) var(--_easing),color var(--_duration) var(--_easing);white-space:nowrap}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=help],[data-part=notifications]){--slotted-icon-size: var(--_icon-size)}[data-ui=top-navigation] [data-part=action]{--slotted-icon-size: var(--_icon-size)}[data-ui=top-navigation] [data-part=action]>:not([data-part=count]){block-size:var(--_icon-size);flex:0 0 auto;font-size:var(--_icon-size);inline-size:var(--_icon-size)}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=notifications],[data-part=account]):enabled:hover,[data-ui=top-navigation] a:is([data-part=help],[data-part=action]):not([data-disabled]):hover,[data-ui=top-navigation] button:is([data-part=help],[data-part=action]):enabled:hover{background-color:var(--_hover-background);color:var(--_color)}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=notifications],[data-part=account]):enabled:active,[data-ui=top-navigation] a:is([data-part=help],[data-part=action]):not([data-disabled]):active,[data-ui=top-navigation] button:is([data-part=help],[data-part=action]):enabled:active{background-color:var(--_active-background);color:var(--_color);transition-duration:var(--slotted-duration-instant)}[data-ui=top-navigation] :is([data-part=more],[data-part=notifications],[data-part=account],[data-part=help],[data-part=action])[data-open]{background-color:var(--_hover-background);color:var(--_color)}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=help],[data-part=notifications],[data-part=account],[data-part=action]):focus-visible{outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:var(--slotted-focus-ring-offset, 2px)}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=notifications],[data-part=account]):disabled,[data-ui=top-navigation] button:is([data-part=help],[data-part=action]):disabled{color:var(--_disabled-color);cursor:not-allowed}[data-ui=top-navigation] [data-part=more][data-current]{color:var(--_current-color)}[data-ui=top-navigation] [data-part=account]{border-radius:var(--slotted-radius-full, 9999px);gap:var(--slotted-space-3, .375rem);padding:var(--slotted-space-2, .25rem)}[data-ui=top-navigation] [data-part=account]>:not([data-ui=avatar]){padding-inline-end:var(--slotted-space-3, .375rem)}[data-ui=top-navigation] [data-part=count]{--_count-font: var(--slotted-control-font-size-sm, 12px);--_count-size: calc(var(--_count-font) * var(--slotted-line-height-xs, 1.4));--_count-inset: calc((var(--_control-height) - var(--_icon-size)) / 2);align-content:center;background-color:var(--_count-background);block-size:var(--_count-size);border-radius:var(--slotted-radius-full, 9999px);box-shadow:0 0 0 var(--slotted-border-width-thick, 2px) var(--_surface);box-sizing:border-box;color:var(--_count-color);display:block;font-size:var(--_count-font);font-variant-numeric:tabular-nums;font-weight:var(--slotted-font-weight-semibold, 600);inset-block-start:calc(var(--_count-inset) - var(--_count-size) / 2);inset-inline-start:calc(100% - var(--_count-inset) - var(--_count-size) / 2);line-height:1;min-inline-size:var(--_count-size);padding-inline:var(--slotted-space-2, .25rem);pointer-events:none;position:absolute;text-align:center;white-space:nowrap;z-index:1}@supports (text-box: trim-both cap alphabetic){[data-ui=top-navigation] [data-part=count]{text-box:trim-both cap alphabetic}}[data-ui=top-navigation] [data-part=search]{align-items:center;display:flex;flex:1 10000 var(--_search-size);gap:var(--_action-gap);margin-inline:0 auto;max-inline-size:var(--_search-size);min-inline-size:var(--_search-min)}[data-ui=top-navigation] [data-part=search]>:not([data-part=search-close]){flex:1 1 auto;min-inline-size:0}[data-ui=top-navigation] [data-part=search-toggle],[data-ui=top-navigation] [data-part=search-close]{display:none}[data-ui=top-navigation] [data-part=actions]{align-items:center;display:flex;flex:0 0 auto;gap:var(--_action-gap);margin-inline-start:auto;padding-inline-end:calc(var(--_edge) + var(--_row-inset))}[data-ui=top-navigation] [data-part=item]:has(>[data-part=more]){display:none}[data-ui=top-navigation] [data-part=item]:has(>[data-part=more][data-overflow]){display:flex}[data-ui=top-navigation] [data-part=panel]{--_enter-distance: var(--slotted-space-2, .25rem);background-color:var(--_panel-surface);border:var(--_rule-width) solid var(--_border-color);border-radius:var(--_panel-radius);box-shadow:var(--_panel-shadow);box-sizing:border-box;color:var(--_color);display:flex;flex-direction:column;gap:var(--slotted-space-2, .25rem);inline-size:var(--_panel-size);inset-block-start:calc(100% + var(--slotted-space-2, .25rem));inset-inline-end:var(--_edge);max-inline-size:100%;opacity:0;padding:var(--slotted-space-2, .25rem);position:absolute;transition:opacity var(--slotted-duration-short) var(--slotted-easing-exit),translate var(--slotted-duration-short) var(--slotted-easing-exit),visibility var(--slotted-duration-short) step-end;translate:0 calc(-1 * var(--_enter-distance));visibility:hidden;z-index:calc(var(--slotted-z-index-popover, 1100) + var(--slotted-layer-depth, 0))}[data-ui=top-navigation] [data-part=panel][data-open]{opacity:1;transition:opacity var(--slotted-duration-medium) var(--slotted-easing-enter),translate var(--slotted-duration-medium) var(--slotted-easing-enter),visibility var(--slotted-duration-medium) step-start;translate:0 0;visibility:visible}[data-ui=top-navigation] [data-part=panel-list]{display:flex;flex-direction:column;gap:var(--slotted-space-1, .125rem);list-style:none;margin:0;padding:0}[data-ui=top-navigation] [data-part=panel-list]:empty{display:none}[data-ui=top-navigation] [data-part=panel] [data-part=item]{display:flex;flex:0 0 auto}[data-ui=top-navigation] [data-part=panel-list]>[data-part=item]>:is([data-part=link],[data-part=trigger]),[data-ui=top-navigation] [data-part=panel]>[data-part=help]{flex:1 1 auto;font-size:var(--_row-font-size);justify-content:flex-start;line-height:var(--_row-line-height);min-block-size:var(--_row-height);padding-inline:var(--_control-padding);white-space:normal}[data-ui=top-navigation] [data-part=panel-list]>[data-part=item]>[data-part=trigger]>[data-part=indicator]{margin-inline-end:0;margin-inline-start:auto}[data-ui=top-navigation] [data-part=panel-list]>[data-part=item]:has(>[data-part=content]){align-items:stretch;flex-direction:column}[data-ui=top-navigation] [data-part=panel-list]>[data-part=item]>[data-part=content]{display:grid;gap:var(--slotted-space-1, .125rem);padding-block-end:var(--slotted-space-2, .25rem);padding-inline-start:var(--_control-padding)}[data-ui=top-navigation] [data-part=panel-list]>[data-part=item]>[data-part=content][hidden]{display:none}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=links]{display:grid;gap:var(--slotted-space-1, .125rem);list-style:none;margin:0;padding:0}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]{align-content:center;border-radius:var(--_radius);color:var(--_color);column-gap:var(--_action-gap);display:grid;font-size:var(--_row-font-size);grid-template-columns:auto minmax(0,1fr);line-height:var(--_row-line-height);min-block-size:var(--_row-height);padding-inline:var(--_control-padding);text-decoration:none;transition:background-color var(--_duration) var(--_easing)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]:not([data-disabled],[data-current],[aria-current=page]):hover{background-color:var(--_hover-background)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]:not([data-disabled],[data-current],[aria-current=page]):active{background-color:var(--_active-background);transition-duration:var(--slotted-duration-instant)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]:is([data-current],[aria-current=page]){background-color:var(--_current-background);box-shadow:inset 0 0 0 var(--_rule-width) var(--_current-edge);color:var(--_current-color)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link][data-disabled]{color:var(--_disabled-color);cursor:not-allowed}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]:focus-visible{outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:calc(var(--slotted-focus-ring-width, 2px) * -1)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]:not(:has(>[data-part=icon]))>*{grid-column:1 / -1}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=icon]{--slotted-icon-size: var(--_icon-size);color:var(--_muted-color);display:flex;grid-row:1 / span 2}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=description]{color:var(--_muted-color);font-size:var(--slotted-font-size-xs, .75rem);grid-column:2}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=group-label]{color:var(--_muted-color);font-size:var(--slotted-font-size-xs, .75rem);font-weight:var(--slotted-font-weight-semibold, 600);padding-block:var(--slotted-space-2, .25rem);padding-inline:var(--_control-padding)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=footer]{align-items:center;border-block-start:var(--_rule-width) solid var(--_border-color);display:flex;gap:var(--_action-gap);justify-content:space-between;padding-block-start:var(--slotted-space-2, .25rem);padding-inline:var(--_control-padding)}[data-ui=top-navigation] [data-part=actions]>[data-part=help]{gap:var(--_control-height);inline-size:var(--_control-height);justify-content:flex-start;overflow:hidden;padding-inline-start:calc((var(--_control-height) - var(--_icon-size)) / 2)}[data-ui=top-navigation] [data-part=panel]>[data-part=help]{gap:var(--_gap)}[data-ui=top-navigation] [data-part=panel]>[data-part=context]{padding:var(--slotted-space-2, .25rem) var(--slotted-space-3, .375rem)}[data-ui=top-navigation] [data-part=panel]>[data-part=context]{order:-1}[data-ui=top-navigation] [data-part=panel]>[data-part=help]{order:1}[data-ui=top-navigation] [data-part=panel]:has(>[data-part=context])>[data-part=panel-list]:not(:empty),[data-ui=top-navigation] [data-part=panel]:has(>[data-part=panel-list]:not(:empty),>[data-part=context])>[data-part=help]{border-block-start:var(--_rule-width) solid var(--_border-color);padding-block-start:var(--slotted-space-2, .25rem)}@container slotted-top-navigation (inline-size < 1024px){[data-ui=top-navigation] [data-part=list]>[data-part=item][data-priority=low]{display:none}[data-ui=top-navigation] [data-part=list]:has(>[data-part=item][data-priority=low])>[data-part=item]:has(>[data-part=more]){display:flex}}@container slotted-top-navigation (inline-size < 600px){[data-ui=top-navigation] [data-part=list]>[data-part=item]:not([data-priority=low]):not([data-priority=high]):not(:has(>[data-part=more])){display:none}[data-ui=top-navigation] [data-part=list]:has(>[data-part=item]:not([data-priority=low]):not([data-priority=high]):not(:has(>[data-part=more])))>[data-part=item]:has(>[data-part=more]){display:flex}[data-ui=top-navigation]:not([data-search-open]) [data-part=search]{display:none}[data-ui=top-navigation]:not([data-search-open]) [data-part=search-toggle]{display:inline-flex}[data-ui=top-navigation][data-search-open] [data-part=search]{max-inline-size:none;padding-inline:var(--_edge)}[data-ui=top-navigation][data-search-open] [data-part=search-close]{display:inline-flex}[data-ui=top-navigation][data-search-open]>:is([data-part=brand],[data-part=context],[data-part=nav],[data-part=actions]){display:none}[data-ui=top-navigation] [data-part=account]>:not([data-ui=avatar]){display:none}[data-ui=top-navigation]>[data-part=context]{display:none}[data-ui=top-navigation]:has(>[data-part=context]) [data-part=list]>[data-part=item]:has(>[data-part=more]){display:flex}}@container slotted-top-navigation (inline-size < 480px){[data-ui=top-navigation]{--_gap: var(--slotted-space-2, .25rem);--_action-gap: var(--slotted-space-2, .25rem)}[data-ui=top-navigation] [data-part=list]>[data-part=item][data-priority=high]{display:none}[data-ui=top-navigation] [data-part=list]:has(>[data-part=item][data-priority=high])>[data-part=item]:has(>[data-part=more]){display:flex}[data-ui=top-navigation] [data-part=count]{inset-inline-end:calc(var(--slotted-border-width-thick, 2px) - var(--_action-gap));inset-inline-start:auto}[data-ui=top-navigation] [data-part=name]{clip-path:inset(50%);inline-size:1px;margin:0;overflow:hidden;position:absolute;white-space:nowrap}[data-ui=top-navigation] [data-part=home]{grid-template-columns:auto}[data-ui=top-navigation] [data-part=actions]>[data-part=help]{display:none}[data-ui=top-navigation]:has([data-part=actions]>[data-part=help]) [data-part=list]>[data-part=item]:has(>[data-part=more]){display:flex}[data-ui=top-navigation] [data-part=panel]{inline-size:auto;inset-inline:var(--_edge)}}@media(prefers-reduced-motion:reduce){[data-ui=top-navigation] [data-part=panel],[data-ui=top-navigation] [data-part=panel][data-open]{translate:0 0}}@media(forced-colors:active){[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=link]:is([data-current],[aria-current=page]){background-color:Highlight;color:HighlightText;forced-color-adjust:none}[data-ui=top-navigation] [data-part=count]{background-color:Highlight;color:HighlightText;forced-color-adjust:none}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item][data-disabled]>[data-part=link],[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=trigger]:disabled{color:GrayText}[data-ui=top-navigation][data-frame],[data-ui=top-navigation] [data-part=panel]{border-color:CanvasText}}}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
381
|
+
}
|
|
382
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigation, decorators: [{
|
|
383
|
+
type: Component,
|
|
384
|
+
args: [{ selector: '[slTopNavigation]', standalone: true, exportAs: 'slTopNavigation', template: `@if (skipTo()) {
|
|
385
|
+
<a data-part="skip" [attr.href]="'#' + skipTo()">{{ t('skip') }}</a>
|
|
386
|
+
}
|
|
387
|
+
<ng-content />`, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
|
|
388
|
+
'data-ui': 'top-navigation',
|
|
389
|
+
'data-part': 'root',
|
|
390
|
+
'[attr.data-size]': 'resolvedSize()',
|
|
391
|
+
'[attr.data-frame]': "resolvedFrame() ? '' : null",
|
|
392
|
+
'[attr.data-search-open]': "searchTakesBar() ? '' : null",
|
|
393
|
+
}, styles: ["@layer slotted.components{[data-ui=top-navigation]{--_control-height: var(--slotted-control-height-md, 34px);--_control-padding: var(--slotted-control-padding-inline-md, 13px);--_control-font-size: var(--slotted-control-font-size-md, 13px);--_icon-size: var(--slotted-control-icon-size-md, 16px);--_gap: var(--slotted-control-gap-md, 8px);--_action-gap: var(--slotted-control-gap-sm, 6px);--_row-inset: var(--slotted-app-shell-row-inset, 0px);--_row-height: var(--slotted-app-shell-row-height, var(--slotted-control-height-md, 34px));--_row-font-size: var( --slotted-app-shell-row-font-size, var(--slotted-font-size-sm, .8125rem) );--_row-line-height: var( --slotted-app-shell-row-line-height, var(--slotted-line-height-sm, 1.45) );--_inset: var(--slotted-top-navigation-inset, var(--slotted-space-5, .75rem));--_block-size: var( --slotted-top-navigation-block-size, calc(var(--slotted-control-height-lg, 38px) + var(--slotted-space-5, .75rem) * 2) );--_radius: var(--slotted-top-navigation-radius, var(--slotted-control-radius, 4px));--_name-font-size: var( --slotted-top-navigation-name-font-size, var(--slotted-font-size-md, .875rem) );--_name-max: var(--slotted-top-navigation-name-max, 16rem);--_search-size: var(--slotted-top-navigation-search-size, 28rem);--_search-min: var(--slotted-top-navigation-search-min, 10rem);--_edge: 0px;--_panel-size: var(--slotted-top-navigation-panel-size, 20rem);--_mark-size: calc(var(--_control-height) - var(--slotted-space-2, .25rem) * 2);--_surface: var(--slotted-top-navigation-surface, var(--slotted-surface, Canvas));--_color: var(--slotted-top-navigation-color, var(--slotted-text, CanvasText));--_muted-color: var(--slotted-top-navigation-muted-color, var(--slotted-text-muted, GrayText));--_border-color: var( --slotted-top-navigation-border-color, var(--slotted-border-subtle, ButtonBorder) );--_hover-background: var( --slotted-top-navigation-hover-background, var(--slotted-tone-secondary-subtle-hover) );--_active-background: var( --slotted-top-navigation-active-background, var(--slotted-tone-secondary-subtle-active) );--_current-color: var(--slotted-top-navigation-current-color, var(--slotted-tone-accent-text));--_current-background: var( --slotted-top-navigation-current-background, var(--slotted-tone-accent-surface) );--_current-edge: var( --slotted-top-navigation-current-edge, var(--slotted-current-edge, transparent) );--_count-background: var( --slotted-top-navigation-count-background, var(--slotted-tone-accent-solid) );--_count-color: var(--slotted-top-navigation-count-color, var(--slotted-tone-accent-on-solid));--_panel-surface: var( --slotted-top-navigation-panel-surface, var(--slotted-surface-raised, Canvas) );--_panel-shadow: var(--slotted-top-navigation-panel-shadow, var(--slotted-shadow-md));--_panel-radius: var(--slotted-top-navigation-panel-radius, var(--slotted-radius-lg, 8px));--_disabled-color: var(--slotted-disabled-foreground, GrayText);--_rule-width: var(--slotted-border-width-thin, 1px);--_duration: var(--slotted-control-transition-duration, var(--slotted-duration-short));--_easing: var(--slotted-control-transition-easing, var(--slotted-easing-standard));align-items:center;box-sizing:border-box;color:var(--_color);container-name:slotted-top-navigation;container-type:inline-size;display:flex;font-family:var(--slotted-control-font-family, inherit);font-size:var(--_control-font-size);gap:var(--_gap);line-height:var(--slotted-control-line-height, 1);min-block-size:var(--_control-height);min-inline-size:0;flex:1 1 auto;position:relative}[data-ui=top-navigation][data-frame]{--_edge: var(--_inset);background-color:var(--_surface);border-block-end:var(--_rule-width) solid var(--_border-color);min-block-size:var(--_block-size)}[data-ui=top-navigation][data-size=sm]{--_control-height: var(--slotted-control-height-sm, 30px);--_control-padding: var(--slotted-control-padding-inline-sm, 10px);--_control-font-size: var(--slotted-control-font-size-sm, 12px);--_icon-size: var(--slotted-control-icon-size-sm, 14px);--_gap: var(--slotted-control-gap-sm, 6px);--_action-gap: var(--slotted-control-gap-sm, 6px);--_row-height: var(--slotted-control-height-sm, 30px);--_row-font-size: var(--slotted-font-size-xs, .75rem);--_row-line-height: var(--slotted-line-height-xs, 1.4);--_name-font-size: var( --slotted-top-navigation-name-font-size, var(--slotted-font-size-sm, .8125rem) );--_block-size: var( --slotted-top-navigation-block-size, calc(var(--slotted-control-height-md, 34px) + var(--slotted-space-4, .5rem) * 2) )}[data-ui=top-navigation][data-size=lg]{--_control-height: var(--slotted-control-height-lg, 38px);--_control-padding: var(--slotted-control-padding-inline-lg, 16px);--_control-font-size: var(--slotted-control-font-size-lg, 14px);--_icon-size: var(--slotted-control-icon-size-lg, 18px);--_gap: var(--slotted-control-gap-lg, 8px);--_action-gap: var(--slotted-control-gap-md, 8px);--_row-height: var(--slotted-control-height-lg, 38px);--_row-font-size: var(--slotted-font-size-md, .875rem);--_row-line-height: var(--slotted-line-height-md, 1.5);--_name-font-size: var( --slotted-top-navigation-name-font-size, var(--slotted-font-size-lg, 1rem) );--_block-size: var( --slotted-top-navigation-block-size, calc(var(--slotted-control-height-lg, 38px) + var(--slotted-space-6, 1rem) * 2) )}[data-ui=top-navigation]>[data-part=skip]{background-color:var(--_surface);block-size:var(--_control-height);border-radius:var(--_radius);box-sizing:border-box;clip-path:inset(50%);color:var(--_color);display:inline-flex;align-items:center;font-weight:var(--slotted-font-weight-semibold, 600);inset-block-start:50%;inset-inline-start:var(--_edge);padding-inline:var(--_control-padding);position:absolute;text-decoration:none;translate:0 -50%;white-space:nowrap;z-index:1}[data-ui=top-navigation]>[data-part=skip]:focus-visible{clip-path:none;outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:var(--slotted-focus-ring-offset, 2px)}[data-ui=top-navigation][data-part=root]>[data-part=brand]{align-items:center;display:flex;flex:0 1 auto;font-weight:inherit;gap:var(--_gap);padding-inline-start:calc(var(--_edge) + var(--_row-inset))}[data-ui=top-navigation][data-part=root]>[data-part=brand]>[data-part=home]{min-inline-size:var(--_control-height);overflow:visible;white-space:normal}[data-ui=top-navigation] [data-part=home]{align-items:center;border-radius:var(--_radius);color:var(--_color);display:inline-grid;flex:0 1 auto;gap:var(--_gap);grid-template-columns:auto minmax(0,1fr);min-block-size:var(--_control-height);min-inline-size:var(--_control-height);text-decoration:none}[data-ui=top-navigation] [data-part=home]:focus-visible{outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:var(--slotted-focus-ring-offset, 2px)}[data-ui=top-navigation] [data-part=mark]{align-items:center;block-size:var(--_control-height);display:inline-flex;flex:0 0 auto;inline-size:var(--_control-height);justify-content:center}[data-ui=top-navigation] [data-part=mark]>:is(svg,img){block-size:var(--_mark-size);inline-size:var(--_mark-size)}[data-ui=top-navigation] [data-part=name]{font-size:var(--_name-font-size);font-weight:var(--slotted-font-weight-semibold, 600);max-inline-size:var(--_name-max);min-inline-size:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}[data-ui=top-navigation] [data-part=context]{align-items:center;display:flex;flex:0 0 auto;gap:var(--_action-gap)}[data-ui=top-navigation] [data-part=nav]{--_control-height: inherit;--_control-padding: inherit;--_control-font-size: inherit;--_icon-size: inherit;--_gap: inherit;--_radius: inherit;--_color: inherit;--_muted-color: inherit;--_hover-background: inherit;--_active-background: inherit;--_current-color: inherit;--_current-background: inherit;--_current-edge: inherit;--_disabled-color: inherit;--_duration: inherit;--_easing: inherit;display:flex;flex:0 0 auto}[data-ui=top-navigation] [data-part=list]{align-items:center;display:flex;gap:var(--slotted-space-1, .125rem);list-style:none;margin:0;min-inline-size:0;padding:0}[data-ui=top-navigation] [data-part=item]{display:flex;flex:0 0 auto;min-inline-size:0}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>:is([data-part=link],[data-part=trigger]){align-items:center;appearance:none;background-color:transparent;border:0;border-radius:var(--_radius);box-sizing:border-box;color:var(--_color);cursor:pointer;display:inline-flex;font:inherit;font-weight:var(--slotted-font-weight-medium, 500);gap:var(--_action-gap);margin:0;min-block-size:var(--_control-height);padding-block:0;padding-inline:var(--_control-padding);text-decoration:none;transition:background-color var(--_duration) var(--_easing),color var(--_duration) var(--_easing);white-space:nowrap}[data-ui=top-navigation] [data-part=item]:not([data-disabled])>[data-part=link]:not([data-current],[aria-current=page]):hover,[data-ui=top-navigation] [data-part=item]:not([data-disabled])>[data-part=trigger]:enabled:hover{background-color:var(--_hover-background);color:var(--_color)}[data-ui=top-navigation] [data-part=item]:not([data-disabled])>[data-part=link]:not([data-current],[aria-current=page]):active,[data-ui=top-navigation] [data-part=item]:not([data-disabled])>[data-part=trigger]:enabled:active{background-color:var(--_active-background);color:var(--_color);transition-duration:var(--slotted-duration-instant)}[data-ui=top-navigation] [data-part=item]:not([data-disabled])>[data-part=trigger][data-open]:enabled{background-color:var(--_hover-background);color:var(--_color)}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=link]:is([data-current],[aria-current=page]){background-color:var(--_current-background);box-shadow:inset 0 0 0 var(--_rule-width) var(--_current-edge);color:var(--_current-color);font-weight:var(--slotted-font-weight-semibold, 600)}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item][data-disabled]>[data-part=link],[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=trigger]:disabled{color:var(--_disabled-color);cursor:not-allowed}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>:is([data-part=link],[data-part=trigger]):focus-visible{outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:var(--slotted-focus-ring-offset, 2px)}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=trigger]>[data-part=indicator]{--slotted-icon-size: var(--_icon-size);display:flex;flex:0 0 auto;margin-inline-end:calc(-1 * var(--slotted-space-2, .25rem))}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=trigger]>[data-part=indicator]>[data-ui=icon]{transition:rotate var(--slotted-duration-medium) var(--_easing)}[data-ui=top-navigation] [data-part=trigger][data-open]>[data-part=indicator]>[data-ui=icon]{rotate:.5turn}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=help],[data-part=notifications],[data-part=account],[data-part=action]){align-items:center;appearance:none;background-color:transparent;border:0;border-radius:var(--_radius);box-sizing:border-box;color:var(--_muted-color);cursor:pointer;display:inline-flex;flex:0 0 auto;font:inherit;font-weight:var(--slotted-font-weight-medium, 500);gap:var(--_action-gap);justify-content:center;margin:0;min-block-size:var(--_control-height);min-inline-size:var(--_control-height);padding:0;position:relative;text-decoration:none;transition:background-color var(--_duration) var(--_easing),color var(--_duration) var(--_easing);white-space:nowrap}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=help],[data-part=notifications]){--slotted-icon-size: var(--_icon-size)}[data-ui=top-navigation] [data-part=action]{--slotted-icon-size: var(--_icon-size)}[data-ui=top-navigation] [data-part=action]>:not([data-part=count]){block-size:var(--_icon-size);flex:0 0 auto;font-size:var(--_icon-size);inline-size:var(--_icon-size)}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=notifications],[data-part=account]):enabled:hover,[data-ui=top-navigation] a:is([data-part=help],[data-part=action]):not([data-disabled]):hover,[data-ui=top-navigation] button:is([data-part=help],[data-part=action]):enabled:hover{background-color:var(--_hover-background);color:var(--_color)}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=notifications],[data-part=account]):enabled:active,[data-ui=top-navigation] a:is([data-part=help],[data-part=action]):not([data-disabled]):active,[data-ui=top-navigation] button:is([data-part=help],[data-part=action]):enabled:active{background-color:var(--_active-background);color:var(--_color);transition-duration:var(--slotted-duration-instant)}[data-ui=top-navigation] :is([data-part=more],[data-part=notifications],[data-part=account],[data-part=help],[data-part=action])[data-open]{background-color:var(--_hover-background);color:var(--_color)}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=help],[data-part=notifications],[data-part=account],[data-part=action]):focus-visible{outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:var(--slotted-focus-ring-offset, 2px)}[data-ui=top-navigation] :is([data-part=more],[data-part=search-toggle],[data-part=search-close],[data-part=notifications],[data-part=account]):disabled,[data-ui=top-navigation] button:is([data-part=help],[data-part=action]):disabled{color:var(--_disabled-color);cursor:not-allowed}[data-ui=top-navigation] [data-part=more][data-current]{color:var(--_current-color)}[data-ui=top-navigation] [data-part=account]{border-radius:var(--slotted-radius-full, 9999px);gap:var(--slotted-space-3, .375rem);padding:var(--slotted-space-2, .25rem)}[data-ui=top-navigation] [data-part=account]>:not([data-ui=avatar]){padding-inline-end:var(--slotted-space-3, .375rem)}[data-ui=top-navigation] [data-part=count]{--_count-font: var(--slotted-control-font-size-sm, 12px);--_count-size: calc(var(--_count-font) * var(--slotted-line-height-xs, 1.4));--_count-inset: calc((var(--_control-height) - var(--_icon-size)) / 2);align-content:center;background-color:var(--_count-background);block-size:var(--_count-size);border-radius:var(--slotted-radius-full, 9999px);box-shadow:0 0 0 var(--slotted-border-width-thick, 2px) var(--_surface);box-sizing:border-box;color:var(--_count-color);display:block;font-size:var(--_count-font);font-variant-numeric:tabular-nums;font-weight:var(--slotted-font-weight-semibold, 600);inset-block-start:calc(var(--_count-inset) - var(--_count-size) / 2);inset-inline-start:calc(100% - var(--_count-inset) - var(--_count-size) / 2);line-height:1;min-inline-size:var(--_count-size);padding-inline:var(--slotted-space-2, .25rem);pointer-events:none;position:absolute;text-align:center;white-space:nowrap;z-index:1}@supports (text-box: trim-both cap alphabetic){[data-ui=top-navigation] [data-part=count]{text-box:trim-both cap alphabetic}}[data-ui=top-navigation] [data-part=search]{align-items:center;display:flex;flex:1 10000 var(--_search-size);gap:var(--_action-gap);margin-inline:0 auto;max-inline-size:var(--_search-size);min-inline-size:var(--_search-min)}[data-ui=top-navigation] [data-part=search]>:not([data-part=search-close]){flex:1 1 auto;min-inline-size:0}[data-ui=top-navigation] [data-part=search-toggle],[data-ui=top-navigation] [data-part=search-close]{display:none}[data-ui=top-navigation] [data-part=actions]{align-items:center;display:flex;flex:0 0 auto;gap:var(--_action-gap);margin-inline-start:auto;padding-inline-end:calc(var(--_edge) + var(--_row-inset))}[data-ui=top-navigation] [data-part=item]:has(>[data-part=more]){display:none}[data-ui=top-navigation] [data-part=item]:has(>[data-part=more][data-overflow]){display:flex}[data-ui=top-navigation] [data-part=panel]{--_enter-distance: var(--slotted-space-2, .25rem);background-color:var(--_panel-surface);border:var(--_rule-width) solid var(--_border-color);border-radius:var(--_panel-radius);box-shadow:var(--_panel-shadow);box-sizing:border-box;color:var(--_color);display:flex;flex-direction:column;gap:var(--slotted-space-2, .25rem);inline-size:var(--_panel-size);inset-block-start:calc(100% + var(--slotted-space-2, .25rem));inset-inline-end:var(--_edge);max-inline-size:100%;opacity:0;padding:var(--slotted-space-2, .25rem);position:absolute;transition:opacity var(--slotted-duration-short) var(--slotted-easing-exit),translate var(--slotted-duration-short) var(--slotted-easing-exit),visibility var(--slotted-duration-short) step-end;translate:0 calc(-1 * var(--_enter-distance));visibility:hidden;z-index:calc(var(--slotted-z-index-popover, 1100) + var(--slotted-layer-depth, 0))}[data-ui=top-navigation] [data-part=panel][data-open]{opacity:1;transition:opacity var(--slotted-duration-medium) var(--slotted-easing-enter),translate var(--slotted-duration-medium) var(--slotted-easing-enter),visibility var(--slotted-duration-medium) step-start;translate:0 0;visibility:visible}[data-ui=top-navigation] [data-part=panel-list]{display:flex;flex-direction:column;gap:var(--slotted-space-1, .125rem);list-style:none;margin:0;padding:0}[data-ui=top-navigation] [data-part=panel-list]:empty{display:none}[data-ui=top-navigation] [data-part=panel] [data-part=item]{display:flex;flex:0 0 auto}[data-ui=top-navigation] [data-part=panel-list]>[data-part=item]>:is([data-part=link],[data-part=trigger]),[data-ui=top-navigation] [data-part=panel]>[data-part=help]{flex:1 1 auto;font-size:var(--_row-font-size);justify-content:flex-start;line-height:var(--_row-line-height);min-block-size:var(--_row-height);padding-inline:var(--_control-padding);white-space:normal}[data-ui=top-navigation] [data-part=panel-list]>[data-part=item]>[data-part=trigger]>[data-part=indicator]{margin-inline-end:0;margin-inline-start:auto}[data-ui=top-navigation] [data-part=panel-list]>[data-part=item]:has(>[data-part=content]){align-items:stretch;flex-direction:column}[data-ui=top-navigation] [data-part=panel-list]>[data-part=item]>[data-part=content]{display:grid;gap:var(--slotted-space-1, .125rem);padding-block-end:var(--slotted-space-2, .25rem);padding-inline-start:var(--_control-padding)}[data-ui=top-navigation] [data-part=panel-list]>[data-part=item]>[data-part=content][hidden]{display:none}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=links]{display:grid;gap:var(--slotted-space-1, .125rem);list-style:none;margin:0;padding:0}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]{align-content:center;border-radius:var(--_radius);color:var(--_color);column-gap:var(--_action-gap);display:grid;font-size:var(--_row-font-size);grid-template-columns:auto minmax(0,1fr);line-height:var(--_row-line-height);min-block-size:var(--_row-height);padding-inline:var(--_control-padding);text-decoration:none;transition:background-color var(--_duration) var(--_easing)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]:not([data-disabled],[data-current],[aria-current=page]):hover{background-color:var(--_hover-background)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]:not([data-disabled],[data-current],[aria-current=page]):active{background-color:var(--_active-background);transition-duration:var(--slotted-duration-instant)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]:is([data-current],[aria-current=page]){background-color:var(--_current-background);box-shadow:inset 0 0 0 var(--_rule-width) var(--_current-edge);color:var(--_current-color)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link][data-disabled]{color:var(--_disabled-color);cursor:not-allowed}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]:focus-visible{outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:calc(var(--slotted-focus-ring-width, 2px) * -1)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=link]:not(:has(>[data-part=icon]))>*{grid-column:1 / -1}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=icon]{--slotted-icon-size: var(--_icon-size);color:var(--_muted-color);display:flex;grid-row:1 / span 2}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=description]{color:var(--_muted-color);font-size:var(--slotted-font-size-xs, .75rem);grid-column:2}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=group-label]{color:var(--_muted-color);font-size:var(--slotted-font-size-xs, .75rem);font-weight:var(--slotted-font-weight-semibold, 600);padding-block:var(--slotted-space-2, .25rem);padding-inline:var(--_control-padding)}[data-ui=top-navigation] [data-part=panel-list] [data-part=content] [data-part=footer]{align-items:center;border-block-start:var(--_rule-width) solid var(--_border-color);display:flex;gap:var(--_action-gap);justify-content:space-between;padding-block-start:var(--slotted-space-2, .25rem);padding-inline:var(--_control-padding)}[data-ui=top-navigation] [data-part=actions]>[data-part=help]{gap:var(--_control-height);inline-size:var(--_control-height);justify-content:flex-start;overflow:hidden;padding-inline-start:calc((var(--_control-height) - var(--_icon-size)) / 2)}[data-ui=top-navigation] [data-part=panel]>[data-part=help]{gap:var(--_gap)}[data-ui=top-navigation] [data-part=panel]>[data-part=context]{padding:var(--slotted-space-2, .25rem) var(--slotted-space-3, .375rem)}[data-ui=top-navigation] [data-part=panel]>[data-part=context]{order:-1}[data-ui=top-navigation] [data-part=panel]>[data-part=help]{order:1}[data-ui=top-navigation] [data-part=panel]:has(>[data-part=context])>[data-part=panel-list]:not(:empty),[data-ui=top-navigation] [data-part=panel]:has(>[data-part=panel-list]:not(:empty),>[data-part=context])>[data-part=help]{border-block-start:var(--_rule-width) solid var(--_border-color);padding-block-start:var(--slotted-space-2, .25rem)}@container slotted-top-navigation (inline-size < 1024px){[data-ui=top-navigation] [data-part=list]>[data-part=item][data-priority=low]{display:none}[data-ui=top-navigation] [data-part=list]:has(>[data-part=item][data-priority=low])>[data-part=item]:has(>[data-part=more]){display:flex}}@container slotted-top-navigation (inline-size < 600px){[data-ui=top-navigation] [data-part=list]>[data-part=item]:not([data-priority=low]):not([data-priority=high]):not(:has(>[data-part=more])){display:none}[data-ui=top-navigation] [data-part=list]:has(>[data-part=item]:not([data-priority=low]):not([data-priority=high]):not(:has(>[data-part=more])))>[data-part=item]:has(>[data-part=more]){display:flex}[data-ui=top-navigation]:not([data-search-open]) [data-part=search]{display:none}[data-ui=top-navigation]:not([data-search-open]) [data-part=search-toggle]{display:inline-flex}[data-ui=top-navigation][data-search-open] [data-part=search]{max-inline-size:none;padding-inline:var(--_edge)}[data-ui=top-navigation][data-search-open] [data-part=search-close]{display:inline-flex}[data-ui=top-navigation][data-search-open]>:is([data-part=brand],[data-part=context],[data-part=nav],[data-part=actions]){display:none}[data-ui=top-navigation] [data-part=account]>:not([data-ui=avatar]){display:none}[data-ui=top-navigation]>[data-part=context]{display:none}[data-ui=top-navigation]:has(>[data-part=context]) [data-part=list]>[data-part=item]:has(>[data-part=more]){display:flex}}@container slotted-top-navigation (inline-size < 480px){[data-ui=top-navigation]{--_gap: var(--slotted-space-2, .25rem);--_action-gap: var(--slotted-space-2, .25rem)}[data-ui=top-navigation] [data-part=list]>[data-part=item][data-priority=high]{display:none}[data-ui=top-navigation] [data-part=list]:has(>[data-part=item][data-priority=high])>[data-part=item]:has(>[data-part=more]){display:flex}[data-ui=top-navigation] [data-part=count]{inset-inline-end:calc(var(--slotted-border-width-thick, 2px) - var(--_action-gap));inset-inline-start:auto}[data-ui=top-navigation] [data-part=name]{clip-path:inset(50%);inline-size:1px;margin:0;overflow:hidden;position:absolute;white-space:nowrap}[data-ui=top-navigation] [data-part=home]{grid-template-columns:auto}[data-ui=top-navigation] [data-part=actions]>[data-part=help]{display:none}[data-ui=top-navigation]:has([data-part=actions]>[data-part=help]) [data-part=list]>[data-part=item]:has(>[data-part=more]){display:flex}[data-ui=top-navigation] [data-part=panel]{inline-size:auto;inset-inline:var(--_edge)}}@media(prefers-reduced-motion:reduce){[data-ui=top-navigation] [data-part=panel],[data-ui=top-navigation] [data-part=panel][data-open]{translate:0 0}}@media(forced-colors:active){[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=link]:is([data-current],[aria-current=page]){background-color:Highlight;color:HighlightText;forced-color-adjust:none}[data-ui=top-navigation] [data-part=count]{background-color:Highlight;color:HighlightText;forced-color-adjust:none}[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item][data-disabled]>[data-part=link],[data-ui=top-navigation] :is([data-part=nav]>[data-part=list],[data-part=panel-list])>[data-part=item]>[data-part=trigger]:disabled{color:GrayText}[data-ui=top-navigation][data-frame],[data-ui=top-navigation] [data-part=panel]{border-color:CanvasText}}}\n"] }]
|
|
394
|
+
}], ctorParameters: () => [], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }, { type: i0.Output, args: ["valueChange"] }], moreOpen: [{ type: i0.Input, args: [{ isSignal: true, alias: "moreOpen", required: false }] }, { type: i0.Output, args: ["moreOpenChange"] }], searchOpen: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchOpen", required: false }] }, { type: i0.Output, args: ["searchOpenChange"] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], frame: [{ type: i0.Input, args: [{ isSignal: true, alias: "frame", required: false }] }], landmark: [{ type: i0.Input, args: [{ isSignal: true, alias: "landmark", required: false }] }], skipTo: [{ type: i0.Input, args: [{ isSignal: true, alias: "skipTo", required: false }] }], messages: [{ type: i0.Input, args: [{ isSignal: true, alias: "messages", required: false }] }], valueChangeRequest: [{ type: i0.Output, args: ["valueChangeRequest"] }], moreOpenChangeRequest: [{ type: i0.Output, args: ["moreOpenChangeRequest"] }], searchOpenChangeRequest: [{ type: i0.Output, args: ["searchOpenChangeRequest"] }], collapseChange: [{ type: i0.Output, args: ["collapseChange"] }] } });
|
|
395
|
+
|
|
396
|
+
/** A click synthesised by the keyboard reports no detail; a real one reports the count. */
|
|
397
|
+
function activationReason(event) {
|
|
398
|
+
return event.detail === 0 ? 'keyboard' : 'pointer';
|
|
399
|
+
}
|
|
400
|
+
/**
|
|
401
|
+
* What a part that moves into the panel needs: where it came from, so it can
|
|
402
|
+
* go back when the panel has left. The move is the DOM's own `insertBefore`,
|
|
403
|
+
* the way the CDK's `DomPortalOutlet` moves a template's nodes; the element
|
|
404
|
+
* stays the same instance and every directive on it stays alive.
|
|
405
|
+
*/
|
|
406
|
+
class Home {
|
|
407
|
+
native;
|
|
408
|
+
home = null;
|
|
409
|
+
constructor(native) {
|
|
410
|
+
this.native = native;
|
|
411
|
+
}
|
|
412
|
+
moveTo(parent, before) {
|
|
413
|
+
if (this.home === null) {
|
|
414
|
+
this.home = { parent: this.native.parentNode, next: this.native.nextSibling };
|
|
415
|
+
}
|
|
416
|
+
if (this.native.parentNode === parent && this.native.nextSibling === before)
|
|
417
|
+
return;
|
|
418
|
+
parent.insertBefore(this.native, before);
|
|
419
|
+
}
|
|
420
|
+
moveBack() {
|
|
421
|
+
if (this.home === null)
|
|
422
|
+
return;
|
|
423
|
+
const { parent, next } = this.home;
|
|
424
|
+
this.home = null;
|
|
425
|
+
/* On teardown the sibling may already be gone from the parent; the end of it is then the place. */
|
|
426
|
+
parent.insertBefore(this.native, next !== null && next.parentNode === parent ? next : null);
|
|
427
|
+
}
|
|
428
|
+
}
|
|
429
|
+
/* ── The hint on a control with no words ────────────────────────────────── */
|
|
430
|
+
/**
|
|
431
|
+
* What every icon-only control shares: the tooltip that repeats its name.
|
|
432
|
+
* `SlTooltip` is a host directive holding the state and the delays; the
|
|
433
|
+
* control dispatches the pointer and the focus to it while a hint is due.
|
|
434
|
+
*/
|
|
435
|
+
class TopNavigationControl {
|
|
436
|
+
navigation = inject(SlTopNavigation);
|
|
437
|
+
tooltip = inject(SlTooltip);
|
|
438
|
+
native = inject(ElementRef).nativeElement;
|
|
439
|
+
/** The name the consumer wrote, kept over the family's own. */
|
|
440
|
+
writtenLabel = inject(new HostAttributeToken('aria-label'), {
|
|
441
|
+
optional: true,
|
|
442
|
+
});
|
|
443
|
+
/** Whether the hint is due at all: not while the words are visible. */
|
|
444
|
+
hint = signal(true, /* @ts-ignore */
|
|
445
|
+
...(ngDevMode ? [{ debugName: "hint" }] : /* istanbul ignore next */ []));
|
|
446
|
+
constructor() {
|
|
447
|
+
this.tooltip.triggerNode.set(this.native);
|
|
448
|
+
inject(DestroyRef).onDestroy(() => this.tooltip.triggerNode.set(null));
|
|
449
|
+
}
|
|
450
|
+
describedBy = computed(() => this.hint() && this.tooltip.isOpen() ? this.tooltip.contentId : null, /* @ts-ignore */
|
|
451
|
+
...(ngDevMode ? [{ debugName: "describedBy" }] : /* istanbul ignore next */ []));
|
|
452
|
+
onPointerEnter(event) {
|
|
453
|
+
if (!this.hint() || event.pointerType === 'touch')
|
|
454
|
+
return;
|
|
455
|
+
this.tooltip.openAfterDelay(event);
|
|
456
|
+
}
|
|
457
|
+
onPointerLeave(event) {
|
|
458
|
+
if (!this.hint())
|
|
459
|
+
return;
|
|
460
|
+
this.tooltip.closeAfterDelay(event);
|
|
461
|
+
}
|
|
462
|
+
onPointerDown(event) {
|
|
463
|
+
if (!this.hint())
|
|
464
|
+
return;
|
|
465
|
+
if (event.pointerType === 'touch')
|
|
466
|
+
this.tooltip.pressAndHold(event);
|
|
467
|
+
else if (this.tooltip.isOpen())
|
|
468
|
+
this.tooltip.toggle(false, 'pointer', event);
|
|
469
|
+
}
|
|
470
|
+
onPointerUp() {
|
|
471
|
+
this.tooltip.cancelPending();
|
|
472
|
+
}
|
|
473
|
+
onFocus(event) {
|
|
474
|
+
if (!this.hint() || !this.native.matches(':focus-visible'))
|
|
475
|
+
return;
|
|
476
|
+
this.tooltip.toggle(true, 'keyboard', event);
|
|
477
|
+
}
|
|
478
|
+
onBlur(event) {
|
|
479
|
+
if (this.tooltip.isOpen())
|
|
480
|
+
this.tooltip.toggle(false, 'blur', event);
|
|
481
|
+
}
|
|
482
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: TopNavigationControl, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
483
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.1.7", type: TopNavigationControl, isStandalone: true, ngImport: i0 });
|
|
484
|
+
}
|
|
485
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: TopNavigationControl, decorators: [{
|
|
486
|
+
type: Directive
|
|
487
|
+
}], ctorParameters: () => [] });
|
|
488
|
+
const HINT_TEMPLATE = `<ng-content />
|
|
489
|
+
@if (hint()) {
|
|
490
|
+
<ng-template slTooltipLayer>
|
|
491
|
+
<div slTooltipContent>{{ text() }}</div>
|
|
492
|
+
</ng-template>
|
|
493
|
+
}`;
|
|
494
|
+
/**
|
|
495
|
+
* The same, with the family's own mark before the content: a Glyph element in
|
|
496
|
+
* an icon box, which the control sizes. None of these marks points along the
|
|
497
|
+
* reading direction, so none of them is `directional`.
|
|
498
|
+
*/
|
|
499
|
+
function markedHintTemplate(glyph) {
|
|
500
|
+
return `<span slIcon><svg slGlyph name="${glyph}"></svg></span>${HINT_TEMPLATE}`;
|
|
501
|
+
}
|
|
502
|
+
const HINT_HOST = {
|
|
503
|
+
'[attr.aria-describedby]': 'describedBy()',
|
|
504
|
+
'(pointerenter)': 'onPointerEnter($event)',
|
|
505
|
+
'(pointerleave)': 'onPointerLeave($event)',
|
|
506
|
+
'(pointerdown)': 'onPointerDown($event)',
|
|
507
|
+
'(pointerup)': 'onPointerUp()',
|
|
508
|
+
'(pointercancel)': 'onPointerUp()',
|
|
509
|
+
'(focus)': 'onFocus($event)',
|
|
510
|
+
'(blur)': 'onBlur($event)',
|
|
511
|
+
};
|
|
512
|
+
const HINT_PROVIDERS = [provideTooltipDefaults({ openOn: 'hover', side: 'bottom' })];
|
|
513
|
+
/* ── Brand ──────────────────────────────────────────────────────────────── */
|
|
514
|
+
/** The start cluster: the shell's toggle when there is one, then the mark and the name. */
|
|
515
|
+
class SlTopNavigationBrand {
|
|
516
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationBrand, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
517
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.1.7", type: SlTopNavigationBrand, isStandalone: true, selector: "[slTopNavigationBrand]", host: { attributes: { "data-part": "brand" } }, ngImport: i0 });
|
|
518
|
+
}
|
|
519
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationBrand, decorators: [{
|
|
520
|
+
type: Directive,
|
|
521
|
+
args: [{
|
|
522
|
+
selector: '[slTopNavigationBrand]',
|
|
523
|
+
standalone: true,
|
|
524
|
+
host: { 'data-part': 'brand' },
|
|
525
|
+
}]
|
|
526
|
+
}] });
|
|
527
|
+
/**
|
|
528
|
+
* The mark and the name, linked to the start of the application on an `a`,
|
|
529
|
+
* or only the mark on a `span`. Below the high step the name leaves the eye
|
|
530
|
+
* and the element keeps its accessible name, because the name is still in it.
|
|
531
|
+
*/
|
|
532
|
+
class SlTopNavigationHome {
|
|
533
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationHome, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
534
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.1.7", type: SlTopNavigationHome, isStandalone: true, selector: "[slTopNavigationHome]", host: { attributes: { "data-part": "home" } }, ngImport: i0 });
|
|
535
|
+
}
|
|
536
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationHome, decorators: [{
|
|
537
|
+
type: Directive,
|
|
538
|
+
args: [{
|
|
539
|
+
selector: '[slTopNavigationHome]',
|
|
540
|
+
standalone: true,
|
|
541
|
+
host: { 'data-part': 'home' },
|
|
542
|
+
}]
|
|
543
|
+
}] });
|
|
544
|
+
/** The box the logo stands in: square, the height of the bar's controls. */
|
|
545
|
+
class SlTopNavigationMark {
|
|
546
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationMark, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
547
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.1.7", type: SlTopNavigationMark, isStandalone: true, selector: "[slTopNavigationMark]", host: { attributes: { "data-part": "mark", "aria-hidden": "true" } }, ngImport: i0 });
|
|
548
|
+
}
|
|
549
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationMark, decorators: [{
|
|
550
|
+
type: Directive,
|
|
551
|
+
args: [{
|
|
552
|
+
selector: '[slTopNavigationMark]',
|
|
553
|
+
standalone: true,
|
|
554
|
+
host: { 'data-part': 'mark', 'aria-hidden': 'true' },
|
|
555
|
+
}]
|
|
556
|
+
}] });
|
|
557
|
+
/** The product's name, one line. */
|
|
558
|
+
class SlTopNavigationName {
|
|
559
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationName, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
560
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.1.7", type: SlTopNavigationName, isStandalone: true, selector: "[slTopNavigationName]", host: { attributes: { "data-part": "name" } }, ngImport: i0 });
|
|
561
|
+
}
|
|
562
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationName, decorators: [{
|
|
563
|
+
type: Directive,
|
|
564
|
+
args: [{
|
|
565
|
+
selector: '[slTopNavigationName]',
|
|
566
|
+
standalone: true,
|
|
567
|
+
host: { 'data-part': 'name' },
|
|
568
|
+
}]
|
|
569
|
+
}] });
|
|
570
|
+
/* ── Context ────────────────────────────────────────────────────────────── */
|
|
571
|
+
/**
|
|
572
|
+
* What the application is at this moment, as the consumer's own content.
|
|
573
|
+
* Below the medium step it is moved to the top of the panel while the panel
|
|
574
|
+
* is present, and back to its place when the panel has left.
|
|
575
|
+
*/
|
|
576
|
+
class SlTopNavigationContext {
|
|
577
|
+
navigation = inject(SlTopNavigation);
|
|
578
|
+
home = new Home(inject(ElementRef).nativeElement);
|
|
579
|
+
constructor() {
|
|
580
|
+
this.navigation.hasContext.set(true);
|
|
581
|
+
effect(() => {
|
|
582
|
+
const panel = this.navigation.panelNode();
|
|
583
|
+
if (this.navigation.narrow() && this.navigation.panelPresent() && panel !== null) {
|
|
584
|
+
this.home.moveTo(panel, panel.firstChild);
|
|
585
|
+
}
|
|
586
|
+
else {
|
|
587
|
+
this.home.moveBack();
|
|
588
|
+
}
|
|
589
|
+
});
|
|
590
|
+
inject(DestroyRef).onDestroy(() => {
|
|
591
|
+
this.navigation.hasContext.set(false);
|
|
592
|
+
this.home.moveBack();
|
|
593
|
+
});
|
|
594
|
+
}
|
|
595
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationContext, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
596
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.1.7", type: SlTopNavigationContext, isStandalone: true, selector: "[slTopNavigationContext]", host: { attributes: { "data-part": "context" } }, ngImport: i0 });
|
|
597
|
+
}
|
|
598
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationContext, decorators: [{
|
|
599
|
+
type: Directive,
|
|
600
|
+
args: [{
|
|
601
|
+
selector: '[slTopNavigationContext]',
|
|
602
|
+
standalone: true,
|
|
603
|
+
host: { 'data-part': 'context' },
|
|
604
|
+
}]
|
|
605
|
+
}], ctorParameters: () => [] });
|
|
606
|
+
/* ── Navigation ─────────────────────────────────────────────────────────── */
|
|
607
|
+
/**
|
|
608
|
+
* The navigation landmark. It builds the panel right after itself in DOM
|
|
609
|
+
* order — so Tab from `more`, the last control in the list, lands in the
|
|
610
|
+
* panel, the way the disclosure pattern assumes — and hands the panel and
|
|
611
|
+
* its list to the root, which the folded parts move into. The panel stays in
|
|
612
|
+
* the DOM closed, out of sight and out of the tab order by the stylesheet's
|
|
613
|
+
* `visibility`.
|
|
614
|
+
*/
|
|
615
|
+
class SlTopNavigationNav {
|
|
616
|
+
navigation = inject(SlTopNavigation);
|
|
617
|
+
menu = inject(SlNavigationMenu);
|
|
618
|
+
native = inject(ElementRef).nativeElement;
|
|
619
|
+
writtenLabel = inject(new HostAttributeToken('aria-label'), { optional: true });
|
|
620
|
+
ariaLabel = computed(() => this.writtenLabel ?? this.navigation.t('navigation'), /* @ts-ignore */
|
|
621
|
+
...(ngDevMode ? [{ debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
|
|
622
|
+
constructor() {
|
|
623
|
+
const document = this.native.ownerDocument;
|
|
624
|
+
const panel = document.createElement('div');
|
|
625
|
+
panel.setAttribute('data-part', 'panel');
|
|
626
|
+
panel.id = this.navigation.ids.panelId;
|
|
627
|
+
const list = document.createElement('ul');
|
|
628
|
+
list.setAttribute('data-part', 'panel-list');
|
|
629
|
+
panel.appendChild(list);
|
|
630
|
+
afterNextRender(() => {
|
|
631
|
+
this.native.insertAdjacentElement('afterend', panel);
|
|
632
|
+
this.navigation.panelNode.set(panel);
|
|
633
|
+
this.navigation.panelListNode.set(list);
|
|
634
|
+
});
|
|
635
|
+
effect(() => {
|
|
636
|
+
if (this.navigation.moreOpen())
|
|
637
|
+
panel.setAttribute('data-open', '');
|
|
638
|
+
else
|
|
639
|
+
panel.removeAttribute('data-open');
|
|
640
|
+
});
|
|
641
|
+
/* A destination followed inside the overflow panel closes the panel too. */
|
|
642
|
+
const followed = this.menu.valueChangeRequest.subscribe((request) => {
|
|
643
|
+
if (request.reason === 'select' && !request.cancelled && this.navigation.moreOpen()) {
|
|
644
|
+
this.navigation.setMoreOpen(false, 'select', request.source);
|
|
645
|
+
}
|
|
646
|
+
});
|
|
647
|
+
inject(DestroyRef).onDestroy(() => followed.unsubscribe());
|
|
648
|
+
inject(DestroyRef).onDestroy(() => {
|
|
649
|
+
if (this.navigation.panelNode() === panel) {
|
|
650
|
+
this.navigation.panelNode.set(null);
|
|
651
|
+
this.navigation.panelListNode.set(null);
|
|
652
|
+
}
|
|
653
|
+
panel.remove();
|
|
654
|
+
});
|
|
655
|
+
}
|
|
656
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationNav, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
657
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.1.7", type: SlTopNavigationNav, isStandalone: true, selector: "nav[slTopNavigationNav]", host: { attributes: { "data-part": "nav" }, properties: { "attr.aria-label": "ariaLabel()" } }, exportAs: ["slTopNavigationNav"], hostDirectives: [{ directive: i1.SlNavigationMenu, inputs: ["value", "value", "arrow", "arrow", "openDelay", "openDelay", "closeDelay", "closeDelay", "closeOnSelect", "closeOnSelect"], outputs: ["valueChange", "valueChange", "valueChangeRequest", "valueChangeRequest"] }], ngImport: i0 });
|
|
658
|
+
}
|
|
659
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationNav, decorators: [{
|
|
660
|
+
type: Directive,
|
|
661
|
+
args: [{
|
|
662
|
+
selector: 'nav[slTopNavigationNav]',
|
|
663
|
+
standalone: true,
|
|
664
|
+
exportAs: 'slTopNavigationNav',
|
|
665
|
+
/**
|
|
666
|
+
* The nav is also a `navigation-menu` root: the open section, its request
|
|
667
|
+
* and the menu's own delays are bound here, on the element that holds the
|
|
668
|
+
* sections. Its `data-part` and its name are the bar's, written after the
|
|
669
|
+
* menu's by the host's own bindings.
|
|
670
|
+
*/
|
|
671
|
+
hostDirectives: [
|
|
672
|
+
{
|
|
673
|
+
directive: SlNavigationMenu,
|
|
674
|
+
inputs: ['value', 'arrow', 'openDelay', 'closeDelay', 'closeOnSelect'],
|
|
675
|
+
outputs: ['valueChange', 'valueChangeRequest'],
|
|
676
|
+
},
|
|
677
|
+
],
|
|
678
|
+
host: {
|
|
679
|
+
'data-part': 'nav',
|
|
680
|
+
'[attr.aria-label]': 'ariaLabel()',
|
|
681
|
+
},
|
|
682
|
+
}]
|
|
683
|
+
}], ctorParameters: () => [] });
|
|
684
|
+
/**
|
|
685
|
+
* The disclosure button of the panel: `data-overflow` holds the count of
|
|
686
|
+
* what folded, and the stylesheet shows the button by it — and by the
|
|
687
|
+
* container queries before the count exists. It carries `data-current` while
|
|
688
|
+
* the current destination is folded, the way a closed parent does.
|
|
689
|
+
*/
|
|
690
|
+
class SlTopNavigationMore extends TopNavigationControl {
|
|
691
|
+
text = computed(() => {
|
|
692
|
+
const folded = this.navigation.collapsed().length;
|
|
693
|
+
return folded > 0
|
|
694
|
+
? this.navigation.t('moreCount', { count: folded })
|
|
695
|
+
: this.navigation.t('more');
|
|
696
|
+
}, /* @ts-ignore */
|
|
697
|
+
...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
|
|
698
|
+
constructor() {
|
|
699
|
+
super();
|
|
700
|
+
this.navigation.moreNode.set(this.native);
|
|
701
|
+
inject(DestroyRef).onDestroy(() => this.navigation.moreNode.set(null));
|
|
702
|
+
}
|
|
703
|
+
onClick(event) {
|
|
704
|
+
if (event.defaultPrevented)
|
|
705
|
+
return;
|
|
706
|
+
this.navigation.setMoreOpen(!this.navigation.moreOpen(), activationReason(event), event);
|
|
707
|
+
}
|
|
708
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationMore, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
709
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: SlTopNavigationMore, isStandalone: true, selector: "button[slTopNavigationMore]", host: { attributes: { "data-part": "more", "type": "button" }, listeners: { "pointerenter": "onPointerEnter($event)", "pointerleave": "onPointerLeave($event)", "pointerdown": "onPointerDown($event)", "pointerup": "onPointerUp()", "pointercancel": "onPointerUp()", "focus": "onFocus($event)", "blur": "onBlur($event)", "click": "onClick($event)" }, properties: { "attr.aria-describedby": "describedBy()", "attr.id": "navigation.ids.moreId", "attr.aria-controls": "navigation.ids.panelId", "attr.aria-expanded": "navigation.moreOpen()", "attr.aria-label": "text()", "attr.data-overflow": "navigation.panelHolds() ? navigation.collapsed().length : null", "attr.data-current": "navigation.currentFolded() ? '' : null", "attr.data-open": "navigation.moreOpen() ? '' : null" } }, providers: HINT_PROVIDERS, exportAs: ["slTopNavigationMore"], usesInheritance: true, hostDirectives: [{ directive: i2.SlTooltip }], ngImport: i0, template: "<span slIcon><svg slGlyph name=\"ellipsis\"></svg></span><ng-content />\n@if (hint()) {\n <ng-template slTooltipLayer>\n <div slTooltipContent>{{ text() }}</div>\n </ng-template>\n}", isInline: true, dependencies: [{ kind: "component", type: SlGlyph, selector: "svg[slGlyph]", inputs: ["name", "solid"] }, { kind: "component", type: SlIcon, selector: "[slIcon]", inputs: ["directional", "label", "size", "tone"], exportAs: ["slIcon"] }, { kind: "directive", type: SlTooltipLayer, selector: "ng-template[slTooltipLayer]", exportAs: ["slTooltipLayer"] }, { kind: "component", type: SlTooltipContent, selector: "[slTooltipContent]", exportAs: ["slTooltipContent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
710
|
+
}
|
|
711
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationMore, decorators: [{
|
|
712
|
+
type: Component,
|
|
713
|
+
args: [{
|
|
714
|
+
selector: 'button[slTopNavigationMore]',
|
|
715
|
+
standalone: true,
|
|
716
|
+
exportAs: 'slTopNavigationMore',
|
|
717
|
+
imports: [SlGlyph, SlIcon, SlTooltipLayer, SlTooltipContent],
|
|
718
|
+
template: markedHintTemplate('ellipsis'),
|
|
719
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
720
|
+
encapsulation: ViewEncapsulation.None,
|
|
721
|
+
hostDirectives: [SlTooltip],
|
|
722
|
+
providers: HINT_PROVIDERS,
|
|
723
|
+
host: {
|
|
724
|
+
...HINT_HOST,
|
|
725
|
+
'data-part': 'more',
|
|
726
|
+
type: 'button',
|
|
727
|
+
'[attr.id]': 'navigation.ids.moreId',
|
|
728
|
+
'[attr.aria-controls]': 'navigation.ids.panelId',
|
|
729
|
+
'[attr.aria-expanded]': 'navigation.moreOpen()',
|
|
730
|
+
'[attr.aria-label]': 'text()',
|
|
731
|
+
'[attr.data-overflow]': 'navigation.panelHolds() ? navigation.collapsed().length : null',
|
|
732
|
+
'[attr.data-current]': "navigation.currentFolded() ? '' : null",
|
|
733
|
+
'[attr.data-open]': "navigation.moreOpen() ? '' : null",
|
|
734
|
+
'(click)': 'onClick($event)',
|
|
735
|
+
},
|
|
736
|
+
}]
|
|
737
|
+
}], ctorParameters: () => [] });
|
|
738
|
+
/** The destinations, and `more` at their end. */
|
|
739
|
+
class SlTopNavigationList {
|
|
740
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationList, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
741
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.7", type: SlTopNavigationList, isStandalone: true, selector: "ul[slTopNavigationList]", host: { attributes: { "data-part": "list" } }, exportAs: ["slTopNavigationList"], ngImport: i0, template: `<ng-content />
|
|
742
|
+
<li data-part="item"><button slTopNavigationMore type="button"></button></li>`, isInline: true, dependencies: [{ kind: "component", type: SlTopNavigationMore, selector: "button[slTopNavigationMore]", exportAs: ["slTopNavigationMore"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
743
|
+
}
|
|
744
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationList, decorators: [{
|
|
745
|
+
type: Component,
|
|
746
|
+
args: [{
|
|
747
|
+
selector: 'ul[slTopNavigationList]',
|
|
748
|
+
standalone: true,
|
|
749
|
+
exportAs: 'slTopNavigationList',
|
|
750
|
+
imports: [SlTopNavigationMore],
|
|
751
|
+
template: `<ng-content />
|
|
752
|
+
<li data-part="item"><button slTopNavigationMore type="button"></button></li>`,
|
|
753
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
754
|
+
encapsulation: ViewEncapsulation.None,
|
|
755
|
+
host: { 'data-part': 'list' },
|
|
756
|
+
}]
|
|
757
|
+
}] });
|
|
758
|
+
/* ── The item ───────────────────────────────────────────────────────────── */
|
|
759
|
+
/**
|
|
760
|
+
* One destination or one section. It says what it is to the root — its
|
|
761
|
+
* value, its priority, whether it is current — and, while the width has
|
|
762
|
+
* folded it and the panel is present, moves itself into the panel's list in
|
|
763
|
+
* the list's own order: the same `li`, with whatever the consumer put in it.
|
|
764
|
+
*/
|
|
765
|
+
class SlTopNavigationItem {
|
|
766
|
+
/** The item's identity: what `value` names it by. */
|
|
767
|
+
value = input.required(/* @ts-ignore */
|
|
768
|
+
...(ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []));
|
|
769
|
+
/** Which step of the width folds this item. Unstated, `medium`. */
|
|
770
|
+
priority = input(undefined, /* @ts-ignore */
|
|
771
|
+
...(ngDevMode ? [{ debugName: "priority" }] : /* istanbul ignore next */ []));
|
|
772
|
+
/** The row and everything in it refuse interaction. */
|
|
773
|
+
disabled = input(false, { ...(ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
774
|
+
navigation = inject(SlTopNavigation);
|
|
775
|
+
native = inject(ElementRef).nativeElement;
|
|
776
|
+
home = new Home(this.native);
|
|
777
|
+
/** Whether the link stated it is current, which wins over the root's value. */
|
|
778
|
+
explicitCurrent = signal(false, /* @ts-ignore */
|
|
779
|
+
...(ngDevMode ? [{ debugName: "explicitCurrent" }] : /* istanbul ignore next */ []));
|
|
780
|
+
resolvedPriority = computed(() => this.priority() ?? 'medium', /* @ts-ignore */
|
|
781
|
+
...(ngDevMode ? [{ debugName: "resolvedPriority" }] : /* istanbul ignore next */ []));
|
|
782
|
+
resolvedDisabled = computed(() => this.disabled(), /* @ts-ignore */
|
|
783
|
+
...(ngDevMode ? [{ debugName: "resolvedDisabled" }] : /* istanbul ignore next */ []));
|
|
784
|
+
collapsed = computed(() => this.navigation.folded().has(this.resolvedPriority()), /* @ts-ignore */
|
|
785
|
+
...(ngDevMode ? [{ debugName: "collapsed" }] : /* istanbul ignore next */ []));
|
|
786
|
+
current = computed(() => this.explicitCurrent() || this.navigation.value() === this.value(), /* @ts-ignore */
|
|
787
|
+
...(ngDevMode ? [{ debugName: "current" }] : /* istanbul ignore next */ []));
|
|
788
|
+
/* ── As a section of the navigation menu ─────────────────────────────── */
|
|
789
|
+
menu = inject(SlNavigationMenu);
|
|
790
|
+
contentId = `${inject(SlNavigationMenuIdFactory).next()}-content`;
|
|
791
|
+
open = computed(() => this.menu.value() === this.value(), /* @ts-ignore */
|
|
792
|
+
...(ngDevMode ? [{ debugName: "open" }] : /* istanbul ignore next */ []));
|
|
793
|
+
currents = signal(new Set(), /* @ts-ignore */
|
|
794
|
+
...(ngDevMode ? [{ debugName: "currents" }] : /* istanbul ignore next */ []));
|
|
795
|
+
hasCurrent = computed(() => this.currents().size > 0, /* @ts-ignore */
|
|
796
|
+
...(ngDevMode ? [{ debugName: "hasCurrent" }] : /* istanbul ignore next */ []));
|
|
797
|
+
reportCurrent(link, current) {
|
|
798
|
+
this.currents.update((set) => {
|
|
799
|
+
if (set.has(link) === current)
|
|
800
|
+
return set;
|
|
801
|
+
const next = new Set(set);
|
|
802
|
+
if (current)
|
|
803
|
+
next.add(link);
|
|
804
|
+
else
|
|
805
|
+
next.delete(link);
|
|
806
|
+
return next;
|
|
807
|
+
});
|
|
808
|
+
}
|
|
809
|
+
constructor() {
|
|
810
|
+
let section = null;
|
|
811
|
+
effect(() => {
|
|
812
|
+
section?.();
|
|
813
|
+
section = this.menu.register(this.value(), this.contentId);
|
|
814
|
+
});
|
|
815
|
+
inject(DestroyRef).onDestroy(() => section?.());
|
|
816
|
+
let release = null;
|
|
817
|
+
effect(() => {
|
|
818
|
+
release?.();
|
|
819
|
+
release = this.navigation.registerItem(this.value(), this.resolvedPriority(), this.explicitCurrent());
|
|
820
|
+
});
|
|
821
|
+
effect(() => {
|
|
822
|
+
const list = this.navigation.panelListNode();
|
|
823
|
+
if (this.collapsed() && this.navigation.panelPresent() && list !== null) {
|
|
824
|
+
const mine = untracked(() => this.navigation.orderOf(this.value()));
|
|
825
|
+
const after = [...list.children].find((sibling) => untracked(() => this.navigation.orderOf(sibling.getAttribute('data-value') ?? '')) >
|
|
826
|
+
mine);
|
|
827
|
+
this.home.moveTo(list, after ?? null);
|
|
828
|
+
}
|
|
829
|
+
else {
|
|
830
|
+
this.home.moveBack();
|
|
831
|
+
}
|
|
832
|
+
});
|
|
833
|
+
inject(DestroyRef).onDestroy(() => {
|
|
834
|
+
release?.();
|
|
835
|
+
this.home.moveBack();
|
|
836
|
+
});
|
|
837
|
+
}
|
|
838
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationItem, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
839
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.1.7", type: SlTopNavigationItem, isStandalone: true, selector: "li[slTopNavigationItem]", inputs: { value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: true, transformFunction: null }, priority: { classPropertyName: "priority", publicName: "priority", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-part": "item" }, properties: { "attr.data-open": "open() ? '' : null", "attr.data-value": "value()", "attr.data-priority": "resolvedPriority()", "attr.data-collapsed": "collapsed() ? '' : null", "attr.data-current": "current() ? '' : null", "attr.data-disabled": "resolvedDisabled() ? '' : null" } }, providers: [
|
|
840
|
+
{ provide: NAVIGATION_MENU_SECTION, useExisting: forwardRef(() => SlTopNavigationItem) },
|
|
841
|
+
], exportAs: ["slTopNavigationItem"], ngImport: i0 });
|
|
842
|
+
}
|
|
843
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationItem, decorators: [{
|
|
844
|
+
type: Directive,
|
|
845
|
+
args: [{
|
|
846
|
+
selector: 'li[slTopNavigationItem]',
|
|
847
|
+
standalone: true,
|
|
848
|
+
exportAs: 'slTopNavigationItem',
|
|
849
|
+
/** A section of the bar is a section of the navigation menu the nav is. */
|
|
850
|
+
providers: [
|
|
851
|
+
{ provide: NAVIGATION_MENU_SECTION, useExisting: forwardRef(() => SlTopNavigationItem) },
|
|
852
|
+
],
|
|
853
|
+
host: {
|
|
854
|
+
'data-part': 'item',
|
|
855
|
+
'[attr.data-open]': "open() ? '' : null",
|
|
856
|
+
'[attr.data-value]': 'value()',
|
|
857
|
+
'[attr.data-priority]': 'resolvedPriority()',
|
|
858
|
+
'[attr.data-collapsed]': "collapsed() ? '' : null",
|
|
859
|
+
'[attr.data-current]': "current() ? '' : null",
|
|
860
|
+
'[attr.data-disabled]': "resolvedDisabled() ? '' : null",
|
|
861
|
+
},
|
|
862
|
+
}]
|
|
863
|
+
}], ctorParameters: () => [], propDecorators: { value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: true }] }], priority: [{ type: i0.Input, args: [{ isSignal: true, alias: "priority", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }] } });
|
|
864
|
+
/**
|
|
865
|
+
* The destination. `current` stated on the row wins over the root's `value`;
|
|
866
|
+
* unstated, an `aria-current` the router wrote on the element is read
|
|
867
|
+
* instead. Pressed inside the panel, it asks the panel to close with `select`.
|
|
868
|
+
*/
|
|
869
|
+
class SlTopNavigationLink {
|
|
870
|
+
/** Whether this is the current destination, stated on the row itself. */
|
|
871
|
+
current = input(undefined, { ...(ngDevMode ? { debugName: "current" } : /* istanbul ignore next */ {}), transform: (state) => (state === undefined ? undefined : booleanAttribute(state)) });
|
|
872
|
+
item = inject(SlTopNavigationItem);
|
|
873
|
+
navigation = inject(SlTopNavigation);
|
|
874
|
+
writtenCurrent = inject(new HostAttributeToken('aria-current'), {
|
|
875
|
+
optional: true,
|
|
876
|
+
});
|
|
877
|
+
resolvedCurrent = computed(() => {
|
|
878
|
+
const stated = this.current();
|
|
879
|
+
if (stated !== undefined)
|
|
880
|
+
return stated;
|
|
881
|
+
if (this.writtenCurrent !== null)
|
|
882
|
+
return this.writtenCurrent !== 'false';
|
|
883
|
+
return this.item.current();
|
|
884
|
+
}, /* @ts-ignore */
|
|
885
|
+
...(ngDevMode ? [{ debugName: "resolvedCurrent" }] : /* istanbul ignore next */ []));
|
|
886
|
+
constructor() {
|
|
887
|
+
effect(() => {
|
|
888
|
+
const stated = this.current();
|
|
889
|
+
const written = this.writtenCurrent !== null && this.writtenCurrent !== 'false';
|
|
890
|
+
this.item.explicitCurrent.set(stated ?? written);
|
|
891
|
+
});
|
|
892
|
+
inject(DestroyRef).onDestroy(() => this.item.explicitCurrent.set(false));
|
|
893
|
+
}
|
|
894
|
+
onClick(event) {
|
|
895
|
+
if (this.item.resolvedDisabled()) {
|
|
896
|
+
event.preventDefault();
|
|
897
|
+
return;
|
|
898
|
+
}
|
|
899
|
+
if (event.defaultPrevented)
|
|
900
|
+
return;
|
|
901
|
+
const reason = activationReason(event);
|
|
902
|
+
this.navigation.select(this.item.value(), reason, event);
|
|
903
|
+
if (this.navigation.moreOpen() && this.item.collapsed()) {
|
|
904
|
+
this.navigation.setMoreOpen(false, 'select', event);
|
|
905
|
+
}
|
|
906
|
+
}
|
|
907
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationLink, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
908
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.1.7", type: SlTopNavigationLink, isStandalone: true, selector: "a[slTopNavigationLink]", inputs: { current: { classPropertyName: "current", publicName: "current", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-part": "link" }, listeners: { "click": "onClick($event)" }, properties: { "attr.aria-current": "resolvedCurrent() ? 'page' : null", "attr.aria-disabled": "item.resolvedDisabled() ? 'true' : null", "attr.data-current": "resolvedCurrent() ? '' : null" } }, exportAs: ["slTopNavigationLink"], ngImport: i0 });
|
|
909
|
+
}
|
|
910
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationLink, decorators: [{
|
|
911
|
+
type: Directive,
|
|
912
|
+
args: [{
|
|
913
|
+
selector: 'a[slTopNavigationLink]',
|
|
914
|
+
standalone: true,
|
|
915
|
+
exportAs: 'slTopNavigationLink',
|
|
916
|
+
host: {
|
|
917
|
+
'data-part': 'link',
|
|
918
|
+
'[attr.aria-current]': "resolvedCurrent() ? 'page' : null",
|
|
919
|
+
'[attr.aria-disabled]': "item.resolvedDisabled() ? 'true' : null",
|
|
920
|
+
'[attr.data-current]': "resolvedCurrent() ? '' : null",
|
|
921
|
+
'(click)': 'onClick($event)',
|
|
922
|
+
},
|
|
923
|
+
}]
|
|
924
|
+
}], ctorParameters: () => [], propDecorators: { current: [{ type: i0.Input, args: [{ isSignal: true, alias: "current", required: false }] }] } });
|
|
925
|
+
/**
|
|
926
|
+
* A section that opens: the `navigation-menu` trigger of the panel that
|
|
927
|
+
* follows it in the same item — `aria-expanded`, `aria-controls`, the
|
|
928
|
+
* chevron, a press and a resting pointer — in the bar's row.
|
|
929
|
+
*/
|
|
930
|
+
class SlTopNavigationTrigger {
|
|
931
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationTrigger, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
932
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.7", type: SlTopNavigationTrigger, isStandalone: true, selector: "button[slTopNavigationTrigger]", exportAs: ["slTopNavigationTrigger"], hostDirectives: [{ directive: i1.SlNavigationMenuTriggerWiring }], ngImport: i0, template: `<ng-content /><span data-part="indicator" aria-hidden="true"
|
|
933
|
+
><span slIcon><svg slGlyph name="chevron-down"></svg></span
|
|
934
|
+
></span>`, isInline: true, styles: ["@property --slotted-navigation-menu-viewport-inline-size{syntax: \"<length>\"; inherits: true; initial-value: 0px;}@property --slotted-navigation-menu-viewport-block-size{syntax: \"<length>\"; inherits: true; initial-value: 0px;}@property --slotted-navigation-menu-viewport-inline-start{syntax: \"<length>\"; inherits: true; initial-value: 0px;}@property --slotted-navigation-menu-viewport-block-start{syntax: \"<length>\"; inherits: true; initial-value: 0px;}@property --slotted-navigation-menu-arrow-offset{syntax: \"<length>\"; inherits: true; initial-value: 0px;}@layer slotted.components{[data-ui=navigation-menu]{--_control-height: var(--slotted-control-height-md, 34px);--_control-padding: var(--slotted-control-padding-inline-md, 13px);--_control-font-size: var(--slotted-control-font-size-md, 13px);--_icon-size: var(--slotted-control-icon-size-md, 16px);--_gap: var(--slotted-control-gap-sm, 6px);--_list-gap: var(--slotted-space-1, .125rem);--_radius: var(--slotted-navigation-menu-radius, var(--slotted-control-radius, 4px));--_surface: var(--slotted-navigation-menu-surface, var(--slotted-surface-raised, Canvas));--_border-color: var( --slotted-navigation-menu-border-color, var(--slotted-border-subtle, ButtonBorder) );--_border-width: var(--slotted-border-width-thin, 1px);--_shadow: var(--slotted-navigation-menu-shadow, var(--slotted-shadow-md));--_viewport-radius: var( --slotted-navigation-menu-viewport-radius, var(--slotted-radius-lg, 8px) );--_offset: var(--slotted-navigation-menu-offset, var(--slotted-space-2, .25rem));--_inset: var(--slotted-space-2, .25rem);--_column-size: var(--slotted-navigation-menu-column-size, 15rem);--_column-gap: var(--slotted-space-2, .25rem);--_group-min: 10rem;--_gutter: var(--slotted-space-4, .5rem);--_font-size: var(--slotted-control-font-size-md, 13px);--_secondary-font-size: var(--slotted-control-font-size-sm, 12px);--_leading: round(up, calc(var(--_font-size) * var(--slotted-line-height-md, 1.5)), 1px);--_secondary-leading: round( up, calc(var(--_secondary-font-size) * var(--slotted-line-height-sm, 1.45)), 1px );--_link-inset-inline: calc(var(--_control-padding) - var(--_border-width) - var(--_inset));--_link-inset-block: var(--slotted-space-4, .5rem);--_color: var(--slotted-navigation-menu-color, var(--slotted-text, CanvasText));--_muted-color: var(--slotted-navigation-menu-muted-color, var(--slotted-text-muted, GrayText));--_hover-background: var( --slotted-navigation-menu-hover-background, var(--slotted-tone-secondary-subtle-hover) );--_active-background: var( --slotted-navigation-menu-active-background, var(--slotted-tone-secondary-subtle-active) );--_current-color: var(--slotted-navigation-menu-current-color, var(--slotted-tone-accent-text));--_current-background: var( --slotted-navigation-menu-current-background, var(--slotted-tone-accent-surface) );--_current-edge: var( --slotted-navigation-menu-current-edge, var(--slotted-current-edge, transparent) );--_disabled-color: var(--slotted-disabled-foreground, GrayText);--_duration: var(--slotted-control-transition-duration, var(--slotted-duration-short));--_easing: var(--slotted-control-transition-easing, var(--slotted-easing-standard));--_enter-distance: var(--slotted-space-2, .25rem);--_slide-distance: var(--slotted-space-6, 1rem);--_inline-sign: 1;--_arrow-size: var(--slotted-space-4, .5rem);box-sizing:border-box;color:var(--_color);display:flex;font-family:var(--slotted-control-font-family, inherit);font-size:var(--_control-font-size);position:relative}[data-ui=navigation-menu]:dir(rtl){--_inline-sign: -1}[data-ui=navigation-menu]:has(>[data-part=list]>[data-part=item]>[data-part=content][data-open]){z-index:var(--slotted-z-index-popover, 1100)}[data-ui=navigation-menu]:has(>[data-part=viewport][data-open]){transition:--slotted-navigation-menu-viewport-inline-size var(--slotted-duration-medium) var(--slotted-easing-standard),--slotted-navigation-menu-viewport-block-size var(--slotted-duration-medium) var(--slotted-easing-standard),--slotted-navigation-menu-viewport-inline-start var(--slotted-duration-medium) var(--slotted-easing-standard),--slotted-navigation-menu-viewport-block-start var(--slotted-duration-medium) var(--slotted-easing-standard),--slotted-navigation-menu-arrow-offset var(--slotted-duration-medium) var(--slotted-easing-standard)}[data-ui=navigation-menu][data-size=sm]{--_control-height: var(--slotted-control-height-sm, 30px);--_control-padding: var(--slotted-control-padding-inline-sm, 10px);--_control-font-size: var(--slotted-control-font-size-sm, 12px);--_icon-size: var(--slotted-control-icon-size-sm, 14px);--_gap: var(--slotted-control-gap-sm, 6px)}[data-ui=navigation-menu][data-size=lg]{--_control-height: var(--slotted-control-height-lg, 38px);--_control-padding: var(--slotted-control-padding-inline-lg, 16px);--_control-font-size: var(--slotted-control-font-size-lg, 14px);--_icon-size: var(--slotted-control-icon-size-lg, 18px);--_gap: var(--slotted-control-gap-md, 8px)}[data-ui=navigation-menu]>[data-part=list]{align-items:center;display:flex;gap:var(--_list-gap);list-style:none;margin:0;padding:0}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]{display:flex}:where([data-ui=navigation-menu]>[data-part=list]>[data-part=item])>:is([data-part=trigger],[data-part=link]){align-items:center;appearance:none;background-color:transparent;border:0;border-radius:var(--_radius);box-sizing:border-box;color:var(--_color);cursor:pointer;display:inline-flex;font:inherit;font-weight:var(--slotted-font-weight-medium, 500);gap:var(--_gap);line-height:var(--slotted-control-line-height, 1);margin:0;min-block-size:var(--_control-height);padding-block:0;padding-inline:var(--_control-padding);text-decoration:none;transition:background-color var(--_duration) var(--_easing),color var(--_duration) var(--_easing);white-space:nowrap}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]:not([data-disabled])>[data-part=trigger]:enabled:hover,[data-ui=navigation-menu]>[data-part=list]>[data-part=item]:not([data-disabled])>[data-part=link]:not([data-disabled],[data-current],[aria-current=page]):hover{background-color:var(--_hover-background)}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]:not([data-disabled])>[data-part=trigger]:enabled:active,[data-ui=navigation-menu]>[data-part=list]>[data-part=item]:not([data-disabled])>[data-part=link]:not([data-disabled],[data-current],[aria-current=page]):active{background-color:var(--_active-background);transition-duration:var(--slotted-duration-instant)}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=trigger][data-open]:enabled{background-color:var(--_hover-background)}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=trigger][data-current]:enabled{color:var(--_current-color)}[data-ui=navigation-menu] [data-part=link]:is([data-current],[aria-current=page]){background-color:var(--_current-background);box-shadow:inset 0 0 0 var(--_border-width) var(--_current-edge);color:var(--_current-color)}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=link]:is([data-current],[aria-current=page]){font-weight:var(--slotted-font-weight-semibold, 600)}[data-ui=navigation-menu] [data-part=trigger]:disabled,[data-ui=navigation-menu] [data-part=link][data-disabled],[data-ui=navigation-menu] [data-part=content] [data-part=link][data-disabled]{color:var(--_disabled-color);cursor:not-allowed}[data-ui=navigation-menu] :is([data-part=trigger],[data-part=link]):focus-visible{outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:var(--slotted-focus-ring-offset, 2px)}[data-ui=navigation-menu] [data-part=indicator]{--slotted-icon-size: var(--_icon-size);display:flex;flex:0 0 auto;margin-inline-end:calc(-1 * var(--slotted-space-2, .25rem))}[data-ui=navigation-menu] [data-part=indicator]>[data-ui=icon]{transition:rotate var(--slotted-duration-medium) var(--slotted-easing-standard)}[data-ui=navigation-menu]:not([data-orientation=vertical])>[data-part=list]>[data-part=item]>[data-part=trigger][data-open]>[data-part=indicator]>[data-ui=icon]{rotate:.5turn}[data-ui=navigation-menu]>[data-part=viewport]{background-color:var(--_surface);border:var(--_border-width) solid var(--_border-color);border-radius:var(--_viewport-radius);box-shadow:var(--_shadow);box-sizing:border-box;display:none;block-size:var(--slotted-navigation-menu-viewport-block-size, 0px);inline-size:var(--slotted-navigation-menu-viewport-inline-size, 0px);inset-block-start:calc(100% + var(--_offset));inset-inline-start:var(--slotted-navigation-menu-viewport-inline-start, 0px);opacity:0;pointer-events:none;position:absolute;translate:0 calc(-1 * var(--_enter-distance));transition:opacity var(--slotted-duration-short) var(--slotted-easing-exit),translate var(--slotted-duration-short) var(--slotted-easing-exit)}[data-ui=navigation-menu]>[data-part=viewport][data-positioned]{display:block}[data-ui=navigation-menu]>[data-part=viewport][data-open]{opacity:1;pointer-events:auto;translate:0 0;transition:none}[data-ui=navigation-menu]>[data-part=viewport][data-open][data-positioned]{animation:slotted-navigation-menu-enter-down var(--slotted-duration-medium) var(--slotted-easing-enter)}[data-ui=navigation-menu]>[data-part=viewport]:before{content:\"\";inset-block-end:100%;inset-inline:0;block-size:calc(var(--_offset) + var(--_border-width));position:absolute}@keyframes slotted-navigation-menu-enter-down{0%{opacity:0;translate:0 calc(-1 * var(--_enter-distance))}}@keyframes slotted-navigation-menu-enter-from-start{0%{opacity:0;translate:calc(-1 * var(--_inline-sign) * var(--_enter-distance)) 0}}@keyframes slotted-navigation-menu-fade{0%{opacity:0}}[data-ui=navigation-menu]>[data-part=viewport]>[data-part=arrow]{background-color:var(--_surface);border-block-start:var(--_border-width) solid var(--_border-color);border-inline-start:var(--_border-width) solid var(--_border-color);border-start-start-radius:var(--slotted-radius-xs, 2px);box-sizing:border-box;block-size:var(--_arrow-size);inline-size:var(--_arrow-size);inset-block-start:calc(var(--_arrow-size) / -2 - var(--_border-width) / 2);inset-inline-start:calc(var(--slotted-navigation-menu-arrow-offset, 50%) - var(--_arrow-size) / 2);position:absolute;rotate:calc(var(--_inline-sign) * 45deg)}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=content]{--_columns: 1;--_content-size: calc( var(--_columns) * var(--_column-size) + (var(--_columns) - 1) * var(--_column-gap) + 2 * (var(--_inset) + var(--_border-width)) );border:var(--_border-width) solid transparent;border-radius:var(--_viewport-radius);box-sizing:border-box;color:var(--_color);column-gap:var(--_column-gap);container-name:slotted-navigation-menu-content;container-type:inline-size;display:grid;font-size:var(--_font-size);grid-template-columns:repeat(auto-fit,minmax(max(var(--_group-min),calc((100% - (var(--_columns) - 1) * var(--_column-gap)) / var(--_columns))),1fr));inline-size:min(var(--_content-size),var(--slotted-navigation-menu-available-inline-size, calc(100vw - 2 * var(--_gutter))));inset-block-start:calc(100% + var(--_offset));inset-inline-start:var(--slotted-navigation-menu-viewport-inline-start, 0px);line-height:var(--_leading);opacity:0;padding:var(--_inset);position:absolute;row-gap:var(--_inset);clip-path:inset(0 max(0px,calc(100% - var(--slotted-navigation-menu-viewport-inline-size))) max(0px,calc(100% - var(--slotted-navigation-menu-viewport-block-size))) 0 round var(--_viewport-radius));transition:opacity var(--slotted-duration-short) var(--slotted-easing-exit);z-index:1}[data-ui=navigation-menu]:dir(rtl)>[data-part=list]>[data-part=item]>[data-part=content]{clip-path:inset(0 0 max(0px,calc(100% - var(--slotted-navigation-menu-viewport-block-size))) max(0px,calc(100% - var(--slotted-navigation-menu-viewport-inline-size))) round var(--_viewport-radius))}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=content][data-columns=\"2\"]{--_columns: 2}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=content][data-columns=\"3\"]{--_columns: 3}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=content][hidden]{display:none}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=content][data-open]{opacity:1;transition:none}[data-ui=navigation-menu]:not([data-nested]):not(:has(>[data-part=viewport][data-positioned]))>[data-part=list]>[data-part=item]>[data-part=content]{background-color:var(--_surface);border-color:var(--_border-color);box-shadow:var(--_shadow);clip-path:none}[data-ui=navigation-menu] [data-part=content][data-motion=from-end]{animation:slotted-navigation-menu-from-end var(--slotted-duration-medium) var(--slotted-easing-enter) both}[data-ui=navigation-menu] [data-part=content][data-motion=from-start]{animation:slotted-navigation-menu-from-start var(--slotted-duration-medium) var(--slotted-easing-enter) both}[data-ui=navigation-menu] [data-part=content][data-motion=to-end]{animation:slotted-navigation-menu-to-end var(--slotted-duration-short) var(--slotted-easing-exit) both}[data-ui=navigation-menu] [data-part=content][data-motion=to-start]{animation:slotted-navigation-menu-to-start var(--slotted-duration-short) var(--slotted-easing-exit) both}@keyframes slotted-navigation-menu-from-end{0%{opacity:0;translate:calc(var(--_inline-sign) * var(--_slide-distance)) 0}}@keyframes slotted-navigation-menu-from-start{0%{opacity:0;translate:calc(-1 * var(--_inline-sign) * var(--_slide-distance)) 0}}@keyframes slotted-navigation-menu-to-end{to{opacity:0;translate:calc(var(--_inline-sign) * var(--_slide-distance)) 0}}@keyframes slotted-navigation-menu-to-start{to{opacity:0;translate:calc(-1 * var(--_inline-sign) * var(--_slide-distance)) 0}}[data-ui=navigation-menu] [data-part=content]>:is([data-part=links],[data-part=footer]){grid-column:1 / -1}[data-ui=navigation-menu] [data-part=links]{display:grid;gap:var(--_column-gap);grid-template-columns:repeat(var(--_columns, 1),minmax(0,1fr));list-style:none;margin:0;padding:0}[data-ui=navigation-menu] [data-part=group]>[data-part=links]{grid-template-columns:minmax(0,1fr)}@container slotted-navigation-menu-content (inline-size < 480px){[data-ui=navigation-menu] [data-part=links]{grid-template-columns:minmax(0,1fr)}}[data-ui=navigation-menu] [data-part=group]{display:flex;flex-direction:column;gap:var(--slotted-space-1, .125rem);min-inline-size:0}[data-ui=navigation-menu] [data-part=group-label]{color:var(--_muted-color);font-size:var(--_secondary-font-size);font-weight:var(--slotted-font-weight-semibold, 600);line-height:var(--_secondary-leading);padding-block:var(--slotted-space-3, .375rem) var(--slotted-space-2, .25rem);padding-inline:var(--_link-inset-inline)}[data-ui=navigation-menu] [data-part=content] [data-part=link]{border-radius:var(--_radius);box-sizing:border-box;color:var(--_color);display:grid;font-weight:var(--slotted-font-weight-regular, 400);grid-template-areas:\"icon label\" \"icon description\";grid-template-columns:auto minmax(0,1fr);grid-template-rows:auto auto;line-height:var(--_leading);min-block-size:var(--_control-height);outline-offset:0;padding-block:var(--_link-inset-block);padding-inline:var(--_link-inset-inline);row-gap:var(--slotted-space-1, .125rem);text-decoration:none;transition:background-color var(--_duration) var(--_easing),color var(--_duration) var(--_easing)}[data-ui=navigation-menu] [data-part=content] [data-part=link]:not(:has([data-part=label])){align-content:center;display:grid;grid-template-areas:none;grid-template-columns:minmax(0,1fr);padding-block:0}[data-ui=navigation-menu] [data-part=content] [data-part=link]:not([data-disabled],[data-current],[aria-current=page]):hover{background-color:var(--_hover-background)}[data-ui=navigation-menu] [data-part=content] [data-part=link]:not([data-disabled],[data-current],[aria-current=page]):active{background-color:var(--_active-background);transition-duration:var(--slotted-duration-instant)}[data-ui=navigation-menu] [data-part=content] [data-part=link]:is([data-current],[aria-current=page]){color:var(--_current-color)}[data-ui=navigation-menu] [data-part=content] [data-part=link]:is([data-current],[aria-current=page])>[data-part=description]{color:inherit}[data-ui=navigation-menu] [data-part=content] [data-part=link]:focus-visible{outline-offset:0}[data-ui=navigation-menu] [data-part=link]>[data-part=icon]{--slotted-icon-size: var(--_icon-size);color:var(--_muted-color);grid-area:icon;line-height:var(--_leading);margin-inline-end:var(--slotted-control-gap-md, 8px);transition:color var(--_duration) var(--_easing)}[data-ui=navigation-menu] [data-part=link]>[data-part=icon]>[data-ui=icon]{display:inline-block;vertical-align:calc((1cap + 1ex) / 4 - var(--_icon-size) / 2)}[data-ui=navigation-menu] [data-part=link]:not([data-disabled],[data-current],[aria-current=page]):hover>[data-part=icon]{color:var(--_color)}[data-ui=navigation-menu] [data-part=link]:is([data-current],[aria-current=page],[data-disabled])>[data-part=icon]{color:inherit}[data-ui=navigation-menu] [data-part=link]>[data-part=label]{font-weight:var(--slotted-font-weight-medium, 500);grid-area:label;min-inline-size:0}[data-ui=navigation-menu] [data-part=link]>[data-part=description]{-webkit-box-orient:vertical;-webkit-line-clamp:2;color:var(--_muted-color);display:-webkit-box;font-size:var(--_secondary-font-size);grid-area:description;line-clamp:2;line-height:var(--_secondary-leading);min-inline-size:0;overflow:hidden}[data-ui=navigation-menu] [data-part=link][data-disabled]>[data-part=description]{color:inherit}[data-ui=navigation-menu] [data-part=footer]{align-items:center;border-block-start:var(--_border-width) solid var(--_border-color);display:flex;gap:var(--slotted-control-gap-md, 8px);justify-content:space-between;margin-inline:calc(-1 * var(--_inset));padding-block:var(--_inset) 0;padding-inline:calc(var(--_inset) + var(--_link-inset-inline)) var(--_inset)}[data-ui=navigation-menu][data-orientation=vertical]>[data-part=list]{align-items:stretch;flex-direction:column;inline-size:100%}[data-ui=navigation-menu][data-orientation=vertical]>[data-part=list]>[data-part=item]>:is([data-part=trigger],[data-part=link]){flex:1 1 auto;justify-content:space-between}[data-ui=navigation-menu][data-orientation=vertical]>[data-part=viewport],[data-ui=navigation-menu][data-orientation=vertical]>[data-part=list]>[data-part=item]>[data-part=content]{inset-block-start:var(--slotted-navigation-menu-viewport-block-start, 0px);inset-inline-start:calc(var(--slotted-navigation-menu-viewport-inline-start, 100%) + var(--_offset))}[data-ui=navigation-menu][data-orientation=vertical]:not([data-nested]):not(:has(>[data-part=viewport][data-positioned]))>[data-part=list]>[data-part=item]>[data-part=content]{inset-inline-start:calc(100% + var(--_offset))}[data-ui=navigation-menu][data-orientation=vertical][data-placement=below]:not([data-nested])>[data-part=viewport],[data-ui=navigation-menu][data-orientation=vertical][data-placement=below]:not([data-nested])>[data-part=list]>[data-part=item]>[data-part=content]{inset-block-start:calc(var(--slotted-navigation-menu-viewport-block-start, 100%) + var(--_offset));inset-inline-start:var(--slotted-navigation-menu-viewport-inline-start, 0px)}[data-ui=navigation-menu][data-orientation=vertical]:not([data-placement=below])>[data-part=viewport]{translate:calc(-1 * var(--_inline-sign) * var(--_enter-distance)) 0}[data-ui=navigation-menu][data-orientation=vertical]:not([data-placement=below])>[data-part=viewport][data-open]{translate:0 0}[data-ui=navigation-menu][data-orientation=vertical]:not([data-placement=below])>[data-part=viewport][data-open][data-positioned]{animation-name:slotted-navigation-menu-enter-from-start}[data-ui=navigation-menu][data-orientation=vertical]:not([data-placement=below])>[data-part=viewport]:before{block-size:auto;inline-size:calc(var(--_offset) + var(--_border-width));inset-block:0;inset-inline:auto 100%}[data-ui=navigation-menu][data-orientation=vertical]:not([data-placement=below])>[data-part=viewport]>[data-part=arrow]{inset-block-start:calc(var(--slotted-navigation-menu-arrow-offset, 50%) - var(--_arrow-size) / 2);inset-inline-start:calc(var(--_arrow-size) / -2 - var(--_border-width) / 2);rotate:calc(var(--_inline-sign) * -45deg)}[data-ui=navigation-menu][data-orientation=vertical][data-placement=below]:not([data-nested])>[data-part=list]>[data-part=item]>[data-part=trigger][data-open]>[data-part=indicator]>[data-ui=icon]{rotate:calc(var(--_inline-sign) * .25turn)}[data-ui=navigation-menu][data-nested]{--_nested-list-size: var(--slotted-navigation-menu-nested-list-size, 11rem);grid-column:1 / -1;min-block-size:var(--slotted-navigation-menu-viewport-block-size, auto)}[data-ui=navigation-menu][data-nested]:before{background-color:var(--_border-color);content:\"\";inline-size:var(--_border-width);inset-block:0;inset-inline-start:calc(var(--_nested-list-size) + var(--_inset) / 2);position:absolute}[data-ui=navigation-menu][data-nested]>[data-part=list]{align-self:flex-start;inline-size:var(--_nested-list-size)}[data-ui=navigation-menu][data-nested]>[data-part=viewport]{display:none}[data-ui=navigation-menu][data-nested]>[data-part=list]>[data-part=item]>[data-part=content]{border:0;border-radius:0;clip-path:none;inline-size:calc(100% - var(--_nested-list-size) - var(--_inset));inset-block-start:0;inset-inline-start:calc(var(--_nested-list-size) + var(--_inset));padding-block:0;padding-inline:var(--_inset) 0}@media(prefers-reduced-motion:reduce){[data-ui=navigation-menu]>[data-part=viewport],[data-ui=navigation-menu][data-orientation=vertical]>[data-part=viewport]{translate:0 0;transition:opacity var(--slotted-duration-short) var(--slotted-easing-exit)}[data-ui=navigation-menu]>[data-part=viewport][data-open][data-positioned],[data-ui=navigation-menu][data-orientation=vertical]>[data-part=viewport][data-open][data-positioned]{animation-name:slotted-navigation-menu-fade}[data-ui=navigation-menu] [data-part=content]:is([data-motion=from-end],[data-motion=from-start]){animation-name:slotted-navigation-menu-fade}[data-ui=navigation-menu] [data-part=content]:is([data-motion=to-end],[data-motion=to-start]){animation:none;opacity:0}}}\n"], dependencies: [{ kind: "component", type: SlGlyph, selector: "svg[slGlyph]", inputs: ["name", "solid"] }, { kind: "component", type: SlIcon, selector: "[slIcon]", inputs: ["directional", "label", "size", "tone"], exportAs: ["slIcon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
935
|
+
}
|
|
936
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationTrigger, decorators: [{
|
|
937
|
+
type: Component,
|
|
938
|
+
args: [{ selector: 'button[slTopNavigationTrigger]', standalone: true, exportAs: 'slTopNavigationTrigger', imports: [SlGlyph, SlIcon], template: `<ng-content /><span data-part="indicator" aria-hidden="true"
|
|
939
|
+
><span slIcon><svg slGlyph name="chevron-down"></svg></span
|
|
940
|
+
></span>`, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, hostDirectives: [SlNavigationMenuTriggerWiring], styles: ["@property --slotted-navigation-menu-viewport-inline-size{syntax: \"<length>\"; inherits: true; initial-value: 0px;}@property --slotted-navigation-menu-viewport-block-size{syntax: \"<length>\"; inherits: true; initial-value: 0px;}@property --slotted-navigation-menu-viewport-inline-start{syntax: \"<length>\"; inherits: true; initial-value: 0px;}@property --slotted-navigation-menu-viewport-block-start{syntax: \"<length>\"; inherits: true; initial-value: 0px;}@property --slotted-navigation-menu-arrow-offset{syntax: \"<length>\"; inherits: true; initial-value: 0px;}@layer slotted.components{[data-ui=navigation-menu]{--_control-height: var(--slotted-control-height-md, 34px);--_control-padding: var(--slotted-control-padding-inline-md, 13px);--_control-font-size: var(--slotted-control-font-size-md, 13px);--_icon-size: var(--slotted-control-icon-size-md, 16px);--_gap: var(--slotted-control-gap-sm, 6px);--_list-gap: var(--slotted-space-1, .125rem);--_radius: var(--slotted-navigation-menu-radius, var(--slotted-control-radius, 4px));--_surface: var(--slotted-navigation-menu-surface, var(--slotted-surface-raised, Canvas));--_border-color: var( --slotted-navigation-menu-border-color, var(--slotted-border-subtle, ButtonBorder) );--_border-width: var(--slotted-border-width-thin, 1px);--_shadow: var(--slotted-navigation-menu-shadow, var(--slotted-shadow-md));--_viewport-radius: var( --slotted-navigation-menu-viewport-radius, var(--slotted-radius-lg, 8px) );--_offset: var(--slotted-navigation-menu-offset, var(--slotted-space-2, .25rem));--_inset: var(--slotted-space-2, .25rem);--_column-size: var(--slotted-navigation-menu-column-size, 15rem);--_column-gap: var(--slotted-space-2, .25rem);--_group-min: 10rem;--_gutter: var(--slotted-space-4, .5rem);--_font-size: var(--slotted-control-font-size-md, 13px);--_secondary-font-size: var(--slotted-control-font-size-sm, 12px);--_leading: round(up, calc(var(--_font-size) * var(--slotted-line-height-md, 1.5)), 1px);--_secondary-leading: round( up, calc(var(--_secondary-font-size) * var(--slotted-line-height-sm, 1.45)), 1px );--_link-inset-inline: calc(var(--_control-padding) - var(--_border-width) - var(--_inset));--_link-inset-block: var(--slotted-space-4, .5rem);--_color: var(--slotted-navigation-menu-color, var(--slotted-text, CanvasText));--_muted-color: var(--slotted-navigation-menu-muted-color, var(--slotted-text-muted, GrayText));--_hover-background: var( --slotted-navigation-menu-hover-background, var(--slotted-tone-secondary-subtle-hover) );--_active-background: var( --slotted-navigation-menu-active-background, var(--slotted-tone-secondary-subtle-active) );--_current-color: var(--slotted-navigation-menu-current-color, var(--slotted-tone-accent-text));--_current-background: var( --slotted-navigation-menu-current-background, var(--slotted-tone-accent-surface) );--_current-edge: var( --slotted-navigation-menu-current-edge, var(--slotted-current-edge, transparent) );--_disabled-color: var(--slotted-disabled-foreground, GrayText);--_duration: var(--slotted-control-transition-duration, var(--slotted-duration-short));--_easing: var(--slotted-control-transition-easing, var(--slotted-easing-standard));--_enter-distance: var(--slotted-space-2, .25rem);--_slide-distance: var(--slotted-space-6, 1rem);--_inline-sign: 1;--_arrow-size: var(--slotted-space-4, .5rem);box-sizing:border-box;color:var(--_color);display:flex;font-family:var(--slotted-control-font-family, inherit);font-size:var(--_control-font-size);position:relative}[data-ui=navigation-menu]:dir(rtl){--_inline-sign: -1}[data-ui=navigation-menu]:has(>[data-part=list]>[data-part=item]>[data-part=content][data-open]){z-index:var(--slotted-z-index-popover, 1100)}[data-ui=navigation-menu]:has(>[data-part=viewport][data-open]){transition:--slotted-navigation-menu-viewport-inline-size var(--slotted-duration-medium) var(--slotted-easing-standard),--slotted-navigation-menu-viewport-block-size var(--slotted-duration-medium) var(--slotted-easing-standard),--slotted-navigation-menu-viewport-inline-start var(--slotted-duration-medium) var(--slotted-easing-standard),--slotted-navigation-menu-viewport-block-start var(--slotted-duration-medium) var(--slotted-easing-standard),--slotted-navigation-menu-arrow-offset var(--slotted-duration-medium) var(--slotted-easing-standard)}[data-ui=navigation-menu][data-size=sm]{--_control-height: var(--slotted-control-height-sm, 30px);--_control-padding: var(--slotted-control-padding-inline-sm, 10px);--_control-font-size: var(--slotted-control-font-size-sm, 12px);--_icon-size: var(--slotted-control-icon-size-sm, 14px);--_gap: var(--slotted-control-gap-sm, 6px)}[data-ui=navigation-menu][data-size=lg]{--_control-height: var(--slotted-control-height-lg, 38px);--_control-padding: var(--slotted-control-padding-inline-lg, 16px);--_control-font-size: var(--slotted-control-font-size-lg, 14px);--_icon-size: var(--slotted-control-icon-size-lg, 18px);--_gap: var(--slotted-control-gap-md, 8px)}[data-ui=navigation-menu]>[data-part=list]{align-items:center;display:flex;gap:var(--_list-gap);list-style:none;margin:0;padding:0}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]{display:flex}:where([data-ui=navigation-menu]>[data-part=list]>[data-part=item])>:is([data-part=trigger],[data-part=link]){align-items:center;appearance:none;background-color:transparent;border:0;border-radius:var(--_radius);box-sizing:border-box;color:var(--_color);cursor:pointer;display:inline-flex;font:inherit;font-weight:var(--slotted-font-weight-medium, 500);gap:var(--_gap);line-height:var(--slotted-control-line-height, 1);margin:0;min-block-size:var(--_control-height);padding-block:0;padding-inline:var(--_control-padding);text-decoration:none;transition:background-color var(--_duration) var(--_easing),color var(--_duration) var(--_easing);white-space:nowrap}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]:not([data-disabled])>[data-part=trigger]:enabled:hover,[data-ui=navigation-menu]>[data-part=list]>[data-part=item]:not([data-disabled])>[data-part=link]:not([data-disabled],[data-current],[aria-current=page]):hover{background-color:var(--_hover-background)}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]:not([data-disabled])>[data-part=trigger]:enabled:active,[data-ui=navigation-menu]>[data-part=list]>[data-part=item]:not([data-disabled])>[data-part=link]:not([data-disabled],[data-current],[aria-current=page]):active{background-color:var(--_active-background);transition-duration:var(--slotted-duration-instant)}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=trigger][data-open]:enabled{background-color:var(--_hover-background)}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=trigger][data-current]:enabled{color:var(--_current-color)}[data-ui=navigation-menu] [data-part=link]:is([data-current],[aria-current=page]){background-color:var(--_current-background);box-shadow:inset 0 0 0 var(--_border-width) var(--_current-edge);color:var(--_current-color)}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=link]:is([data-current],[aria-current=page]){font-weight:var(--slotted-font-weight-semibold, 600)}[data-ui=navigation-menu] [data-part=trigger]:disabled,[data-ui=navigation-menu] [data-part=link][data-disabled],[data-ui=navigation-menu] [data-part=content] [data-part=link][data-disabled]{color:var(--_disabled-color);cursor:not-allowed}[data-ui=navigation-menu] :is([data-part=trigger],[data-part=link]):focus-visible{outline:var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);outline-offset:var(--slotted-focus-ring-offset, 2px)}[data-ui=navigation-menu] [data-part=indicator]{--slotted-icon-size: var(--_icon-size);display:flex;flex:0 0 auto;margin-inline-end:calc(-1 * var(--slotted-space-2, .25rem))}[data-ui=navigation-menu] [data-part=indicator]>[data-ui=icon]{transition:rotate var(--slotted-duration-medium) var(--slotted-easing-standard)}[data-ui=navigation-menu]:not([data-orientation=vertical])>[data-part=list]>[data-part=item]>[data-part=trigger][data-open]>[data-part=indicator]>[data-ui=icon]{rotate:.5turn}[data-ui=navigation-menu]>[data-part=viewport]{background-color:var(--_surface);border:var(--_border-width) solid var(--_border-color);border-radius:var(--_viewport-radius);box-shadow:var(--_shadow);box-sizing:border-box;display:none;block-size:var(--slotted-navigation-menu-viewport-block-size, 0px);inline-size:var(--slotted-navigation-menu-viewport-inline-size, 0px);inset-block-start:calc(100% + var(--_offset));inset-inline-start:var(--slotted-navigation-menu-viewport-inline-start, 0px);opacity:0;pointer-events:none;position:absolute;translate:0 calc(-1 * var(--_enter-distance));transition:opacity var(--slotted-duration-short) var(--slotted-easing-exit),translate var(--slotted-duration-short) var(--slotted-easing-exit)}[data-ui=navigation-menu]>[data-part=viewport][data-positioned]{display:block}[data-ui=navigation-menu]>[data-part=viewport][data-open]{opacity:1;pointer-events:auto;translate:0 0;transition:none}[data-ui=navigation-menu]>[data-part=viewport][data-open][data-positioned]{animation:slotted-navigation-menu-enter-down var(--slotted-duration-medium) var(--slotted-easing-enter)}[data-ui=navigation-menu]>[data-part=viewport]:before{content:\"\";inset-block-end:100%;inset-inline:0;block-size:calc(var(--_offset) + var(--_border-width));position:absolute}@keyframes slotted-navigation-menu-enter-down{0%{opacity:0;translate:0 calc(-1 * var(--_enter-distance))}}@keyframes slotted-navigation-menu-enter-from-start{0%{opacity:0;translate:calc(-1 * var(--_inline-sign) * var(--_enter-distance)) 0}}@keyframes slotted-navigation-menu-fade{0%{opacity:0}}[data-ui=navigation-menu]>[data-part=viewport]>[data-part=arrow]{background-color:var(--_surface);border-block-start:var(--_border-width) solid var(--_border-color);border-inline-start:var(--_border-width) solid var(--_border-color);border-start-start-radius:var(--slotted-radius-xs, 2px);box-sizing:border-box;block-size:var(--_arrow-size);inline-size:var(--_arrow-size);inset-block-start:calc(var(--_arrow-size) / -2 - var(--_border-width) / 2);inset-inline-start:calc(var(--slotted-navigation-menu-arrow-offset, 50%) - var(--_arrow-size) / 2);position:absolute;rotate:calc(var(--_inline-sign) * 45deg)}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=content]{--_columns: 1;--_content-size: calc( var(--_columns) * var(--_column-size) + (var(--_columns) - 1) * var(--_column-gap) + 2 * (var(--_inset) + var(--_border-width)) );border:var(--_border-width) solid transparent;border-radius:var(--_viewport-radius);box-sizing:border-box;color:var(--_color);column-gap:var(--_column-gap);container-name:slotted-navigation-menu-content;container-type:inline-size;display:grid;font-size:var(--_font-size);grid-template-columns:repeat(auto-fit,minmax(max(var(--_group-min),calc((100% - (var(--_columns) - 1) * var(--_column-gap)) / var(--_columns))),1fr));inline-size:min(var(--_content-size),var(--slotted-navigation-menu-available-inline-size, calc(100vw - 2 * var(--_gutter))));inset-block-start:calc(100% + var(--_offset));inset-inline-start:var(--slotted-navigation-menu-viewport-inline-start, 0px);line-height:var(--_leading);opacity:0;padding:var(--_inset);position:absolute;row-gap:var(--_inset);clip-path:inset(0 max(0px,calc(100% - var(--slotted-navigation-menu-viewport-inline-size))) max(0px,calc(100% - var(--slotted-navigation-menu-viewport-block-size))) 0 round var(--_viewport-radius));transition:opacity var(--slotted-duration-short) var(--slotted-easing-exit);z-index:1}[data-ui=navigation-menu]:dir(rtl)>[data-part=list]>[data-part=item]>[data-part=content]{clip-path:inset(0 0 max(0px,calc(100% - var(--slotted-navigation-menu-viewport-block-size))) max(0px,calc(100% - var(--slotted-navigation-menu-viewport-inline-size))) round var(--_viewport-radius))}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=content][data-columns=\"2\"]{--_columns: 2}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=content][data-columns=\"3\"]{--_columns: 3}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=content][hidden]{display:none}[data-ui=navigation-menu]>[data-part=list]>[data-part=item]>[data-part=content][data-open]{opacity:1;transition:none}[data-ui=navigation-menu]:not([data-nested]):not(:has(>[data-part=viewport][data-positioned]))>[data-part=list]>[data-part=item]>[data-part=content]{background-color:var(--_surface);border-color:var(--_border-color);box-shadow:var(--_shadow);clip-path:none}[data-ui=navigation-menu] [data-part=content][data-motion=from-end]{animation:slotted-navigation-menu-from-end var(--slotted-duration-medium) var(--slotted-easing-enter) both}[data-ui=navigation-menu] [data-part=content][data-motion=from-start]{animation:slotted-navigation-menu-from-start var(--slotted-duration-medium) var(--slotted-easing-enter) both}[data-ui=navigation-menu] [data-part=content][data-motion=to-end]{animation:slotted-navigation-menu-to-end var(--slotted-duration-short) var(--slotted-easing-exit) both}[data-ui=navigation-menu] [data-part=content][data-motion=to-start]{animation:slotted-navigation-menu-to-start var(--slotted-duration-short) var(--slotted-easing-exit) both}@keyframes slotted-navigation-menu-from-end{0%{opacity:0;translate:calc(var(--_inline-sign) * var(--_slide-distance)) 0}}@keyframes slotted-navigation-menu-from-start{0%{opacity:0;translate:calc(-1 * var(--_inline-sign) * var(--_slide-distance)) 0}}@keyframes slotted-navigation-menu-to-end{to{opacity:0;translate:calc(var(--_inline-sign) * var(--_slide-distance)) 0}}@keyframes slotted-navigation-menu-to-start{to{opacity:0;translate:calc(-1 * var(--_inline-sign) * var(--_slide-distance)) 0}}[data-ui=navigation-menu] [data-part=content]>:is([data-part=links],[data-part=footer]){grid-column:1 / -1}[data-ui=navigation-menu] [data-part=links]{display:grid;gap:var(--_column-gap);grid-template-columns:repeat(var(--_columns, 1),minmax(0,1fr));list-style:none;margin:0;padding:0}[data-ui=navigation-menu] [data-part=group]>[data-part=links]{grid-template-columns:minmax(0,1fr)}@container slotted-navigation-menu-content (inline-size < 480px){[data-ui=navigation-menu] [data-part=links]{grid-template-columns:minmax(0,1fr)}}[data-ui=navigation-menu] [data-part=group]{display:flex;flex-direction:column;gap:var(--slotted-space-1, .125rem);min-inline-size:0}[data-ui=navigation-menu] [data-part=group-label]{color:var(--_muted-color);font-size:var(--_secondary-font-size);font-weight:var(--slotted-font-weight-semibold, 600);line-height:var(--_secondary-leading);padding-block:var(--slotted-space-3, .375rem) var(--slotted-space-2, .25rem);padding-inline:var(--_link-inset-inline)}[data-ui=navigation-menu] [data-part=content] [data-part=link]{border-radius:var(--_radius);box-sizing:border-box;color:var(--_color);display:grid;font-weight:var(--slotted-font-weight-regular, 400);grid-template-areas:\"icon label\" \"icon description\";grid-template-columns:auto minmax(0,1fr);grid-template-rows:auto auto;line-height:var(--_leading);min-block-size:var(--_control-height);outline-offset:0;padding-block:var(--_link-inset-block);padding-inline:var(--_link-inset-inline);row-gap:var(--slotted-space-1, .125rem);text-decoration:none;transition:background-color var(--_duration) var(--_easing),color var(--_duration) var(--_easing)}[data-ui=navigation-menu] [data-part=content] [data-part=link]:not(:has([data-part=label])){align-content:center;display:grid;grid-template-areas:none;grid-template-columns:minmax(0,1fr);padding-block:0}[data-ui=navigation-menu] [data-part=content] [data-part=link]:not([data-disabled],[data-current],[aria-current=page]):hover{background-color:var(--_hover-background)}[data-ui=navigation-menu] [data-part=content] [data-part=link]:not([data-disabled],[data-current],[aria-current=page]):active{background-color:var(--_active-background);transition-duration:var(--slotted-duration-instant)}[data-ui=navigation-menu] [data-part=content] [data-part=link]:is([data-current],[aria-current=page]){color:var(--_current-color)}[data-ui=navigation-menu] [data-part=content] [data-part=link]:is([data-current],[aria-current=page])>[data-part=description]{color:inherit}[data-ui=navigation-menu] [data-part=content] [data-part=link]:focus-visible{outline-offset:0}[data-ui=navigation-menu] [data-part=link]>[data-part=icon]{--slotted-icon-size: var(--_icon-size);color:var(--_muted-color);grid-area:icon;line-height:var(--_leading);margin-inline-end:var(--slotted-control-gap-md, 8px);transition:color var(--_duration) var(--_easing)}[data-ui=navigation-menu] [data-part=link]>[data-part=icon]>[data-ui=icon]{display:inline-block;vertical-align:calc((1cap + 1ex) / 4 - var(--_icon-size) / 2)}[data-ui=navigation-menu] [data-part=link]:not([data-disabled],[data-current],[aria-current=page]):hover>[data-part=icon]{color:var(--_color)}[data-ui=navigation-menu] [data-part=link]:is([data-current],[aria-current=page],[data-disabled])>[data-part=icon]{color:inherit}[data-ui=navigation-menu] [data-part=link]>[data-part=label]{font-weight:var(--slotted-font-weight-medium, 500);grid-area:label;min-inline-size:0}[data-ui=navigation-menu] [data-part=link]>[data-part=description]{-webkit-box-orient:vertical;-webkit-line-clamp:2;color:var(--_muted-color);display:-webkit-box;font-size:var(--_secondary-font-size);grid-area:description;line-clamp:2;line-height:var(--_secondary-leading);min-inline-size:0;overflow:hidden}[data-ui=navigation-menu] [data-part=link][data-disabled]>[data-part=description]{color:inherit}[data-ui=navigation-menu] [data-part=footer]{align-items:center;border-block-start:var(--_border-width) solid var(--_border-color);display:flex;gap:var(--slotted-control-gap-md, 8px);justify-content:space-between;margin-inline:calc(-1 * var(--_inset));padding-block:var(--_inset) 0;padding-inline:calc(var(--_inset) + var(--_link-inset-inline)) var(--_inset)}[data-ui=navigation-menu][data-orientation=vertical]>[data-part=list]{align-items:stretch;flex-direction:column;inline-size:100%}[data-ui=navigation-menu][data-orientation=vertical]>[data-part=list]>[data-part=item]>:is([data-part=trigger],[data-part=link]){flex:1 1 auto;justify-content:space-between}[data-ui=navigation-menu][data-orientation=vertical]>[data-part=viewport],[data-ui=navigation-menu][data-orientation=vertical]>[data-part=list]>[data-part=item]>[data-part=content]{inset-block-start:var(--slotted-navigation-menu-viewport-block-start, 0px);inset-inline-start:calc(var(--slotted-navigation-menu-viewport-inline-start, 100%) + var(--_offset))}[data-ui=navigation-menu][data-orientation=vertical]:not([data-nested]):not(:has(>[data-part=viewport][data-positioned]))>[data-part=list]>[data-part=item]>[data-part=content]{inset-inline-start:calc(100% + var(--_offset))}[data-ui=navigation-menu][data-orientation=vertical][data-placement=below]:not([data-nested])>[data-part=viewport],[data-ui=navigation-menu][data-orientation=vertical][data-placement=below]:not([data-nested])>[data-part=list]>[data-part=item]>[data-part=content]{inset-block-start:calc(var(--slotted-navigation-menu-viewport-block-start, 100%) + var(--_offset));inset-inline-start:var(--slotted-navigation-menu-viewport-inline-start, 0px)}[data-ui=navigation-menu][data-orientation=vertical]:not([data-placement=below])>[data-part=viewport]{translate:calc(-1 * var(--_inline-sign) * var(--_enter-distance)) 0}[data-ui=navigation-menu][data-orientation=vertical]:not([data-placement=below])>[data-part=viewport][data-open]{translate:0 0}[data-ui=navigation-menu][data-orientation=vertical]:not([data-placement=below])>[data-part=viewport][data-open][data-positioned]{animation-name:slotted-navigation-menu-enter-from-start}[data-ui=navigation-menu][data-orientation=vertical]:not([data-placement=below])>[data-part=viewport]:before{block-size:auto;inline-size:calc(var(--_offset) + var(--_border-width));inset-block:0;inset-inline:auto 100%}[data-ui=navigation-menu][data-orientation=vertical]:not([data-placement=below])>[data-part=viewport]>[data-part=arrow]{inset-block-start:calc(var(--slotted-navigation-menu-arrow-offset, 50%) - var(--_arrow-size) / 2);inset-inline-start:calc(var(--_arrow-size) / -2 - var(--_border-width) / 2);rotate:calc(var(--_inline-sign) * -45deg)}[data-ui=navigation-menu][data-orientation=vertical][data-placement=below]:not([data-nested])>[data-part=list]>[data-part=item]>[data-part=trigger][data-open]>[data-part=indicator]>[data-ui=icon]{rotate:calc(var(--_inline-sign) * .25turn)}[data-ui=navigation-menu][data-nested]{--_nested-list-size: var(--slotted-navigation-menu-nested-list-size, 11rem);grid-column:1 / -1;min-block-size:var(--slotted-navigation-menu-viewport-block-size, auto)}[data-ui=navigation-menu][data-nested]:before{background-color:var(--_border-color);content:\"\";inline-size:var(--_border-width);inset-block:0;inset-inline-start:calc(var(--_nested-list-size) + var(--_inset) / 2);position:absolute}[data-ui=navigation-menu][data-nested]>[data-part=list]{align-self:flex-start;inline-size:var(--_nested-list-size)}[data-ui=navigation-menu][data-nested]>[data-part=viewport]{display:none}[data-ui=navigation-menu][data-nested]>[data-part=list]>[data-part=item]>[data-part=content]{border:0;border-radius:0;clip-path:none;inline-size:calc(100% - var(--_nested-list-size) - var(--_inset));inset-block-start:0;inset-inline-start:calc(var(--_nested-list-size) + var(--_inset));padding-block:0;padding-inline:var(--_inset) 0}@media(prefers-reduced-motion:reduce){[data-ui=navigation-menu]>[data-part=viewport],[data-ui=navigation-menu][data-orientation=vertical]>[data-part=viewport]{translate:0 0;transition:opacity var(--slotted-duration-short) var(--slotted-easing-exit)}[data-ui=navigation-menu]>[data-part=viewport][data-open][data-positioned],[data-ui=navigation-menu][data-orientation=vertical]>[data-part=viewport][data-open][data-positioned]{animation-name:slotted-navigation-menu-fade}[data-ui=navigation-menu] [data-part=content]:is([data-motion=from-end],[data-motion=from-start]){animation-name:slotted-navigation-menu-fade}[data-ui=navigation-menu] [data-part=content]:is([data-motion=to-end],[data-motion=to-start]){animation:none;opacity:0}}}\n"] }]
|
|
941
|
+
}] });
|
|
942
|
+
/* ── Search ─────────────────────────────────────────────────────────────── */
|
|
943
|
+
/** The button that closes the search where it has taken the bar. */
|
|
944
|
+
class SlTopNavigationSearchClose extends TopNavigationControl {
|
|
945
|
+
text = computed(() => this.navigation.t('closeSearch'), /* @ts-ignore */
|
|
946
|
+
...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
|
|
947
|
+
onClick(event) {
|
|
948
|
+
if (event.defaultPrevented)
|
|
949
|
+
return;
|
|
950
|
+
this.navigation.setSearchOpen(false, activationReason(event), event);
|
|
951
|
+
}
|
|
952
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationSearchClose, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
953
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: SlTopNavigationSearchClose, isStandalone: true, selector: "button[slTopNavigationSearchClose]", host: { attributes: { "data-part": "search-close", "type": "button" }, listeners: { "pointerenter": "onPointerEnter($event)", "pointerleave": "onPointerLeave($event)", "pointerdown": "onPointerDown($event)", "pointerup": "onPointerUp()", "pointercancel": "onPointerUp()", "focus": "onFocus($event)", "blur": "onBlur($event)", "click": "onClick($event)" }, properties: { "attr.aria-describedby": "describedBy()", "attr.aria-label": "text()" } }, providers: HINT_PROVIDERS, usesInheritance: true, hostDirectives: [{ directive: i2.SlTooltip }], ngImport: i0, template: "<span slIcon><svg slGlyph name=\"x\"></svg></span><ng-content />\n@if (hint()) {\n <ng-template slTooltipLayer>\n <div slTooltipContent>{{ text() }}</div>\n </ng-template>\n}", isInline: true, dependencies: [{ kind: "component", type: SlGlyph, selector: "svg[slGlyph]", inputs: ["name", "solid"] }, { kind: "component", type: SlIcon, selector: "[slIcon]", inputs: ["directional", "label", "size", "tone"], exportAs: ["slIcon"] }, { kind: "directive", type: SlTooltipLayer, selector: "ng-template[slTooltipLayer]", exportAs: ["slTooltipLayer"] }, { kind: "component", type: SlTooltipContent, selector: "[slTooltipContent]", exportAs: ["slTooltipContent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
954
|
+
}
|
|
955
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationSearchClose, decorators: [{
|
|
956
|
+
type: Component,
|
|
957
|
+
args: [{
|
|
958
|
+
selector: 'button[slTopNavigationSearchClose]',
|
|
959
|
+
standalone: true,
|
|
960
|
+
imports: [SlGlyph, SlIcon, SlTooltipLayer, SlTooltipContent],
|
|
961
|
+
template: markedHintTemplate('x'),
|
|
962
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
963
|
+
encapsulation: ViewEncapsulation.None,
|
|
964
|
+
hostDirectives: [SlTooltip],
|
|
965
|
+
providers: HINT_PROVIDERS,
|
|
966
|
+
host: {
|
|
967
|
+
...HINT_HOST,
|
|
968
|
+
'data-part': 'search-close',
|
|
969
|
+
type: 'button',
|
|
970
|
+
'[attr.aria-label]': 'text()',
|
|
971
|
+
'(click)': 'onClick($event)',
|
|
972
|
+
},
|
|
973
|
+
}]
|
|
974
|
+
}] });
|
|
975
|
+
/** The button that opens the search where the width has folded the field. */
|
|
976
|
+
class SlTopNavigationSearchToggle extends TopNavigationControl {
|
|
977
|
+
text = computed(() => this.navigation.t('search'), /* @ts-ignore */
|
|
978
|
+
...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
|
|
979
|
+
constructor() {
|
|
980
|
+
super();
|
|
981
|
+
this.navigation.searchToggleNode.set(this.native);
|
|
982
|
+
inject(DestroyRef).onDestroy(() => this.navigation.searchToggleNode.set(null));
|
|
983
|
+
}
|
|
984
|
+
onClick(event) {
|
|
985
|
+
if (event.defaultPrevented)
|
|
986
|
+
return;
|
|
987
|
+
this.navigation.setSearchOpen(true, activationReason(event), event);
|
|
988
|
+
}
|
|
989
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationSearchToggle, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
990
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: SlTopNavigationSearchToggle, isStandalone: true, selector: "button[slTopNavigationSearchToggle]", host: { attributes: { "data-part": "search-toggle", "type": "button" }, listeners: { "pointerenter": "onPointerEnter($event)", "pointerleave": "onPointerLeave($event)", "pointerdown": "onPointerDown($event)", "pointerup": "onPointerUp()", "pointercancel": "onPointerUp()", "focus": "onFocus($event)", "blur": "onBlur($event)", "click": "onClick($event)" }, properties: { "attr.aria-describedby": "describedBy()", "attr.aria-label": "text()" } }, providers: HINT_PROVIDERS, usesInheritance: true, hostDirectives: [{ directive: i2.SlTooltip }], ngImport: i0, template: "<span slIcon><svg slGlyph name=\"search\"></svg></span><ng-content />\n@if (hint()) {\n <ng-template slTooltipLayer>\n <div slTooltipContent>{{ text() }}</div>\n </ng-template>\n}", isInline: true, dependencies: [{ kind: "component", type: SlGlyph, selector: "svg[slGlyph]", inputs: ["name", "solid"] }, { kind: "component", type: SlIcon, selector: "[slIcon]", inputs: ["directional", "label", "size", "tone"], exportAs: ["slIcon"] }, { kind: "directive", type: SlTooltipLayer, selector: "ng-template[slTooltipLayer]", exportAs: ["slTooltipLayer"] }, { kind: "component", type: SlTooltipContent, selector: "[slTooltipContent]", exportAs: ["slTooltipContent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
991
|
+
}
|
|
992
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationSearchToggle, decorators: [{
|
|
993
|
+
type: Component,
|
|
994
|
+
args: [{
|
|
995
|
+
selector: 'button[slTopNavigationSearchToggle]',
|
|
996
|
+
standalone: true,
|
|
997
|
+
imports: [SlGlyph, SlIcon, SlTooltipLayer, SlTooltipContent],
|
|
998
|
+
template: markedHintTemplate('search'),
|
|
999
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1000
|
+
encapsulation: ViewEncapsulation.None,
|
|
1001
|
+
hostDirectives: [SlTooltip],
|
|
1002
|
+
providers: HINT_PROVIDERS,
|
|
1003
|
+
host: {
|
|
1004
|
+
...HINT_HOST,
|
|
1005
|
+
'data-part': 'search-toggle',
|
|
1006
|
+
type: 'button',
|
|
1007
|
+
'[attr.aria-label]': 'text()',
|
|
1008
|
+
'(click)': 'onClick($event)',
|
|
1009
|
+
},
|
|
1010
|
+
}]
|
|
1011
|
+
}], ctorParameters: () => [] });
|
|
1012
|
+
/**
|
|
1013
|
+
* The search region, with the consumer's field inside and the close at its
|
|
1014
|
+
* end. Below the medium step the region exists only while `searchOpen`, and
|
|
1015
|
+
* takes the whole bar: opening moves focus into the field, and Escape, focus
|
|
1016
|
+
* leaving the region, or the close hand the bar back and return focus to the
|
|
1017
|
+
* toggle.
|
|
1018
|
+
*/
|
|
1019
|
+
class SlTopNavigationSearch {
|
|
1020
|
+
navigation = inject(SlTopNavigation);
|
|
1021
|
+
native = inject(ElementRef).nativeElement;
|
|
1022
|
+
/** Whether the region has taken the bar. */
|
|
1023
|
+
active = computed(() => this.navigation.searchTakesBar(), /* @ts-ignore */
|
|
1024
|
+
...(ngDevMode ? [{ debugName: "active" }] : /* istanbul ignore next */ []));
|
|
1025
|
+
constructor() {
|
|
1026
|
+
this.navigation.hasSearch.set(true);
|
|
1027
|
+
this.navigation.searchNode.set(this.native);
|
|
1028
|
+
/* The field takes focus the moment it takes the bar; the toggle takes it back when the bar returns. */
|
|
1029
|
+
let wasActive = this.active();
|
|
1030
|
+
effect(() => {
|
|
1031
|
+
const active = this.active();
|
|
1032
|
+
const before = wasActive;
|
|
1033
|
+
wasActive = active;
|
|
1034
|
+
if (active) {
|
|
1035
|
+
this.native.querySelector('input, [contenteditable]')?.focus();
|
|
1036
|
+
return;
|
|
1037
|
+
}
|
|
1038
|
+
if (!before)
|
|
1039
|
+
return;
|
|
1040
|
+
const focused = this.native.ownerDocument.activeElement;
|
|
1041
|
+
if (focused === null ||
|
|
1042
|
+
focused === this.native.ownerDocument.body ||
|
|
1043
|
+
this.native.contains(focused)) {
|
|
1044
|
+
untracked(() => this.navigation.searchToggleNode())?.focus();
|
|
1045
|
+
}
|
|
1046
|
+
});
|
|
1047
|
+
inject(DestroyRef).onDestroy(() => {
|
|
1048
|
+
this.navigation.hasSearch.set(false);
|
|
1049
|
+
if (this.navigation.searchNode() === this.native)
|
|
1050
|
+
this.navigation.searchNode.set(null);
|
|
1051
|
+
});
|
|
1052
|
+
}
|
|
1053
|
+
onKeyDown(event) {
|
|
1054
|
+
if (event.defaultPrevented || !this.active() || event.key !== 'Escape')
|
|
1055
|
+
return;
|
|
1056
|
+
event.preventDefault();
|
|
1057
|
+
this.navigation.setSearchOpen(false, 'escape', event);
|
|
1058
|
+
}
|
|
1059
|
+
onFocusOut(event) {
|
|
1060
|
+
if (event.defaultPrevented || !this.active())
|
|
1061
|
+
return;
|
|
1062
|
+
const next = event.relatedTarget;
|
|
1063
|
+
if (next === null || this.native.contains(next))
|
|
1064
|
+
return;
|
|
1065
|
+
this.navigation.setSearchOpen(false, 'blur', event);
|
|
1066
|
+
}
|
|
1067
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationSearch, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1068
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.7", type: SlTopNavigationSearch, isStandalone: true, selector: "[slTopNavigationSearch]", host: { attributes: { "data-part": "search" }, listeners: { "keydown": "onKeyDown($event)", "focusout": "onFocusOut($event)" } }, exportAs: ["slTopNavigationSearch"], ngImport: i0, template: `<ng-content /><button slTopNavigationSearchClose type="button"></button>`, isInline: true, dependencies: [{ kind: "component", type: SlTopNavigationSearchClose, selector: "button[slTopNavigationSearchClose]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1069
|
+
}
|
|
1070
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationSearch, decorators: [{
|
|
1071
|
+
type: Component,
|
|
1072
|
+
args: [{
|
|
1073
|
+
selector: '[slTopNavigationSearch]',
|
|
1074
|
+
standalone: true,
|
|
1075
|
+
exportAs: 'slTopNavigationSearch',
|
|
1076
|
+
imports: [SlTopNavigationSearchClose],
|
|
1077
|
+
template: `<ng-content /><button slTopNavigationSearchClose type="button"></button>`,
|
|
1078
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1079
|
+
encapsulation: ViewEncapsulation.None,
|
|
1080
|
+
host: {
|
|
1081
|
+
'data-part': 'search',
|
|
1082
|
+
'(keydown)': 'onKeyDown($event)',
|
|
1083
|
+
'(focusout)': 'onFocusOut($event)',
|
|
1084
|
+
},
|
|
1085
|
+
}]
|
|
1086
|
+
}], ctorParameters: () => [] });
|
|
1087
|
+
/* ── Actions ────────────────────────────────────────────────────────────── */
|
|
1088
|
+
/** The end cluster. The search toggle stands first in it whenever the bar has a search. */
|
|
1089
|
+
class SlTopNavigationActions {
|
|
1090
|
+
navigation = inject(SlTopNavigation);
|
|
1091
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationActions, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1092
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: SlTopNavigationActions, isStandalone: true, selector: "[slTopNavigationActions]", host: { attributes: { "data-part": "actions" } }, exportAs: ["slTopNavigationActions"], ngImport: i0, template: `@if (navigation.hasSearch()) {
|
|
1093
|
+
<button slTopNavigationSearchToggle type="button"></button>
|
|
1094
|
+
}
|
|
1095
|
+
<ng-content />`, isInline: true, dependencies: [{ kind: "component", type: SlTopNavigationSearchToggle, selector: "button[slTopNavigationSearchToggle]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1096
|
+
}
|
|
1097
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationActions, decorators: [{
|
|
1098
|
+
type: Component,
|
|
1099
|
+
args: [{
|
|
1100
|
+
selector: '[slTopNavigationActions]',
|
|
1101
|
+
standalone: true,
|
|
1102
|
+
exportAs: 'slTopNavigationActions',
|
|
1103
|
+
imports: [SlTopNavigationSearchToggle],
|
|
1104
|
+
template: `@if (navigation.hasSearch()) {
|
|
1105
|
+
<button slTopNavigationSearchToggle type="button"></button>
|
|
1106
|
+
}
|
|
1107
|
+
<ng-content />`,
|
|
1108
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1109
|
+
encapsulation: ViewEncapsulation.None,
|
|
1110
|
+
host: { 'data-part': 'actions' },
|
|
1111
|
+
}]
|
|
1112
|
+
}] });
|
|
1113
|
+
/**
|
|
1114
|
+
* Help: a destination on an `a`, a trigger on a `button` the consumer puts
|
|
1115
|
+
* `slMenuTriggerFor` or a popover trigger on. Its projected content is its
|
|
1116
|
+
* label — the family's message when there is none — clipped from the eye in
|
|
1117
|
+
* the bar and shown as a row's words in the panel below the high step, where
|
|
1118
|
+
* it is moved while the panel is present.
|
|
1119
|
+
*/
|
|
1120
|
+
class SlTopNavigationHelp extends TopNavigationControl {
|
|
1121
|
+
home = new Home(this.native);
|
|
1122
|
+
text = computed(() => this.writtenLabel ?? this.navigation.t('help'), /* @ts-ignore */
|
|
1123
|
+
...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
|
|
1124
|
+
/** The words shown when the consumer projected none. */
|
|
1125
|
+
fallback = computed(() => this.writtenLabel === null ? this.navigation.t('help') : '', /* @ts-ignore */
|
|
1126
|
+
...(ngDevMode ? [{ debugName: "fallback" }] : /* istanbul ignore next */ []));
|
|
1127
|
+
inPanel = computed(() => this.navigation.narrowest() &&
|
|
1128
|
+
this.navigation.panelPresent() &&
|
|
1129
|
+
this.navigation.panelNode() !== null, /* @ts-ignore */
|
|
1130
|
+
...(ngDevMode ? [{ debugName: "inPanel" }] : /* istanbul ignore next */ []));
|
|
1131
|
+
hint = computed(() => !this.inPanel(), /* @ts-ignore */
|
|
1132
|
+
...(ngDevMode ? [{ debugName: "hint" }] : /* istanbul ignore next */ []));
|
|
1133
|
+
constructor() {
|
|
1134
|
+
super();
|
|
1135
|
+
this.navigation.hasHelp.set(true);
|
|
1136
|
+
afterNextRender(() => this.native.setAttribute('data-part', 'help'));
|
|
1137
|
+
effect(() => {
|
|
1138
|
+
const panel = this.navigation.panelNode();
|
|
1139
|
+
if (this.inPanel() && panel !== null)
|
|
1140
|
+
this.home.moveTo(panel, null);
|
|
1141
|
+
else
|
|
1142
|
+
this.home.moveBack();
|
|
1143
|
+
});
|
|
1144
|
+
inject(DestroyRef).onDestroy(() => {
|
|
1145
|
+
this.navigation.hasHelp.set(false);
|
|
1146
|
+
this.home.moveBack();
|
|
1147
|
+
});
|
|
1148
|
+
}
|
|
1149
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationHelp, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1150
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: SlTopNavigationHelp, isStandalone: true, selector: "a[slTopNavigationHelp], button[slTopNavigationHelp]", host: { attributes: { "data-part": "help" }, listeners: { "pointerenter": "onPointerEnter($event)", "pointerleave": "onPointerLeave($event)", "pointerdown": "onPointerDown($event)", "pointerup": "onPointerUp()", "pointercancel": "onPointerUp()", "focus": "onFocus($event)", "blur": "onBlur($event)" }, properties: { "attr.aria-describedby": "describedBy()" } }, providers: HINT_PROVIDERS, exportAs: ["slTopNavigationHelp"], usesInheritance: true, hostDirectives: [{ directive: i2.SlTooltip }], ngImport: i0, template: `<span slIcon><svg slGlyph name="circle-question"></svg></span
|
|
1151
|
+
><ng-content>{{ fallback() }}</ng-content>
|
|
1152
|
+
@if (hint()) {
|
|
1153
|
+
<ng-template slTooltipLayer>
|
|
1154
|
+
<div slTooltipContent>{{ text() }}</div>
|
|
1155
|
+
</ng-template>
|
|
1156
|
+
}`, isInline: true, dependencies: [{ kind: "component", type: SlGlyph, selector: "svg[slGlyph]", inputs: ["name", "solid"] }, { kind: "component", type: SlIcon, selector: "[slIcon]", inputs: ["directional", "label", "size", "tone"], exportAs: ["slIcon"] }, { kind: "directive", type: SlTooltipLayer, selector: "ng-template[slTooltipLayer]", exportAs: ["slTooltipLayer"] }, { kind: "component", type: SlTooltipContent, selector: "[slTooltipContent]", exportAs: ["slTooltipContent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1157
|
+
}
|
|
1158
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationHelp, decorators: [{
|
|
1159
|
+
type: Component,
|
|
1160
|
+
args: [{
|
|
1161
|
+
selector: 'a[slTopNavigationHelp], button[slTopNavigationHelp]',
|
|
1162
|
+
standalone: true,
|
|
1163
|
+
exportAs: 'slTopNavigationHelp',
|
|
1164
|
+
imports: [SlGlyph, SlIcon, SlTooltipLayer, SlTooltipContent],
|
|
1165
|
+
template: `<span slIcon><svg slGlyph name="circle-question"></svg></span
|
|
1166
|
+
><ng-content>{{ fallback() }}</ng-content>
|
|
1167
|
+
@if (hint()) {
|
|
1168
|
+
<ng-template slTooltipLayer>
|
|
1169
|
+
<div slTooltipContent>{{ text() }}</div>
|
|
1170
|
+
</ng-template>
|
|
1171
|
+
}`,
|
|
1172
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1173
|
+
encapsulation: ViewEncapsulation.None,
|
|
1174
|
+
hostDirectives: [SlTooltip],
|
|
1175
|
+
providers: HINT_PROVIDERS,
|
|
1176
|
+
host: {
|
|
1177
|
+
...HINT_HOST,
|
|
1178
|
+
'data-part': 'help',
|
|
1179
|
+
},
|
|
1180
|
+
}]
|
|
1181
|
+
}], ctorParameters: () => [] });
|
|
1182
|
+
/** Notifications: the bell, with the count in its corner. It never folds. */
|
|
1183
|
+
class SlTopNavigationNotifications extends TopNavigationControl {
|
|
1184
|
+
text = computed(() => this.writtenLabel ?? this.navigation.t('notifications'), /* @ts-ignore */
|
|
1185
|
+
...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
|
|
1186
|
+
constructor() {
|
|
1187
|
+
super();
|
|
1188
|
+
afterNextRender(() => this.native.setAttribute('data-part', 'notifications'));
|
|
1189
|
+
}
|
|
1190
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationNotifications, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1191
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: SlTopNavigationNotifications, isStandalone: true, selector: "button[slTopNavigationNotifications]", host: { attributes: { "data-part": "notifications", "type": "button" }, listeners: { "pointerenter": "onPointerEnter($event)", "pointerleave": "onPointerLeave($event)", "pointerdown": "onPointerDown($event)", "pointerup": "onPointerUp()", "pointercancel": "onPointerUp()", "focus": "onFocus($event)", "blur": "onBlur($event)" }, properties: { "attr.aria-describedby": "describedBy()", "attr.aria-label": "text()" } }, providers: HINT_PROVIDERS, exportAs: ["slTopNavigationNotifications"], usesInheritance: true, hostDirectives: [{ directive: i2.SlTooltip }], ngImport: i0, template: "<span slIcon><svg slGlyph name=\"bell\"></svg></span><ng-content />\n@if (hint()) {\n <ng-template slTooltipLayer>\n <div slTooltipContent>{{ text() }}</div>\n </ng-template>\n}", isInline: true, dependencies: [{ kind: "component", type: SlGlyph, selector: "svg[slGlyph]", inputs: ["name", "solid"] }, { kind: "component", type: SlIcon, selector: "[slIcon]", inputs: ["directional", "label", "size", "tone"], exportAs: ["slIcon"] }, { kind: "directive", type: SlTooltipLayer, selector: "ng-template[slTooltipLayer]", exportAs: ["slTooltipLayer"] }, { kind: "component", type: SlTooltipContent, selector: "[slTooltipContent]", exportAs: ["slTooltipContent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1192
|
+
}
|
|
1193
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationNotifications, decorators: [{
|
|
1194
|
+
type: Component,
|
|
1195
|
+
args: [{
|
|
1196
|
+
selector: 'button[slTopNavigationNotifications]',
|
|
1197
|
+
standalone: true,
|
|
1198
|
+
exportAs: 'slTopNavigationNotifications',
|
|
1199
|
+
imports: [SlGlyph, SlIcon, SlTooltipLayer, SlTooltipContent],
|
|
1200
|
+
template: markedHintTemplate('bell'),
|
|
1201
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1202
|
+
encapsulation: ViewEncapsulation.None,
|
|
1203
|
+
hostDirectives: [SlTooltip],
|
|
1204
|
+
providers: HINT_PROVIDERS,
|
|
1205
|
+
host: {
|
|
1206
|
+
...HINT_HOST,
|
|
1207
|
+
'data-part': 'notifications',
|
|
1208
|
+
type: 'button',
|
|
1209
|
+
'[attr.aria-label]': 'text()',
|
|
1210
|
+
},
|
|
1211
|
+
}]
|
|
1212
|
+
}], ctorParameters: () => [] });
|
|
1213
|
+
/**
|
|
1214
|
+
* A global control of the product's own — approvals, tasks — in the family's
|
|
1215
|
+
* square, with the family's ink, ground and hint. A destination on an `a`, a
|
|
1216
|
+
* trigger on a `button`. The consumer projects its own glyph and names the
|
|
1217
|
+
* control: `label` when the words change with a count, `aria-label` when
|
|
1218
|
+
* they do not. `slTopNavigationCount` inside it stands over its corner the
|
|
1219
|
+
* way it stands over the bell.
|
|
1220
|
+
*/
|
|
1221
|
+
class SlTopNavigationAction extends TopNavigationControl {
|
|
1222
|
+
/** The words the control is named by; over `aria-label`, which is read once. */
|
|
1223
|
+
label = input(undefined, /* @ts-ignore */
|
|
1224
|
+
...(ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ []));
|
|
1225
|
+
type = this.native.tagName === 'BUTTON' ? 'button' : null;
|
|
1226
|
+
text = computed(() => this.label() ?? this.writtenLabel ?? '', /* @ts-ignore */
|
|
1227
|
+
...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
|
|
1228
|
+
/** No words, no hint: a control with no name has nothing to repeat. */
|
|
1229
|
+
hint = computed(() => this.text() !== '', /* @ts-ignore */
|
|
1230
|
+
...(ngDevMode ? [{ debugName: "hint" }] : /* istanbul ignore next */ []));
|
|
1231
|
+
constructor() {
|
|
1232
|
+
super();
|
|
1233
|
+
afterNextRender(() => this.native.setAttribute('data-part', 'action'));
|
|
1234
|
+
}
|
|
1235
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationAction, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1236
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: SlTopNavigationAction, isStandalone: true, selector: "a[slTopNavigationAction], button[slTopNavigationAction]", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "data-part": "action" }, listeners: { "pointerenter": "onPointerEnter($event)", "pointerleave": "onPointerLeave($event)", "pointerdown": "onPointerDown($event)", "pointerup": "onPointerUp()", "pointercancel": "onPointerUp()", "focus": "onFocus($event)", "blur": "onBlur($event)" }, properties: { "attr.aria-describedby": "describedBy()", "attr.type": "type", "attr.aria-label": "text() || null" } }, providers: HINT_PROVIDERS, exportAs: ["slTopNavigationAction"], usesInheritance: true, hostDirectives: [{ directive: i2.SlTooltip }], ngImport: i0, template: "<ng-content />\n@if (hint()) {\n <ng-template slTooltipLayer>\n <div slTooltipContent>{{ text() }}</div>\n </ng-template>\n}", isInline: true, dependencies: [{ kind: "directive", type: SlTooltipLayer, selector: "ng-template[slTooltipLayer]", exportAs: ["slTooltipLayer"] }, { kind: "component", type: SlTooltipContent, selector: "[slTooltipContent]", exportAs: ["slTooltipContent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1237
|
+
}
|
|
1238
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationAction, decorators: [{
|
|
1239
|
+
type: Component,
|
|
1240
|
+
args: [{
|
|
1241
|
+
selector: 'a[slTopNavigationAction], button[slTopNavigationAction]',
|
|
1242
|
+
standalone: true,
|
|
1243
|
+
exportAs: 'slTopNavigationAction',
|
|
1244
|
+
imports: [SlTooltipLayer, SlTooltipContent],
|
|
1245
|
+
template: HINT_TEMPLATE,
|
|
1246
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1247
|
+
encapsulation: ViewEncapsulation.None,
|
|
1248
|
+
hostDirectives: [SlTooltip],
|
|
1249
|
+
providers: HINT_PROVIDERS,
|
|
1250
|
+
host: {
|
|
1251
|
+
...HINT_HOST,
|
|
1252
|
+
'data-part': 'action',
|
|
1253
|
+
'[attr.type]': 'type',
|
|
1254
|
+
'[attr.aria-label]': 'text() || null',
|
|
1255
|
+
},
|
|
1256
|
+
}]
|
|
1257
|
+
}], ctorParameters: () => [], propDecorators: { label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }] } });
|
|
1258
|
+
/** The number of what is waiting, inside the bell's button and so inside its name. */
|
|
1259
|
+
class SlTopNavigationCount {
|
|
1260
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationCount, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1261
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "22.1.7", type: SlTopNavigationCount, isStandalone: true, selector: "[slTopNavigationCount]", host: { attributes: { "data-part": "count" } }, ngImport: i0 });
|
|
1262
|
+
}
|
|
1263
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationCount, decorators: [{
|
|
1264
|
+
type: Directive,
|
|
1265
|
+
args: [{
|
|
1266
|
+
selector: '[slTopNavigationCount]',
|
|
1267
|
+
standalone: true,
|
|
1268
|
+
host: { 'data-part': 'count' },
|
|
1269
|
+
}]
|
|
1270
|
+
}] });
|
|
1271
|
+
/** The account: the consumer's avatar and, when there is room, the name. It never folds. */
|
|
1272
|
+
class SlTopNavigationAccount extends TopNavigationControl {
|
|
1273
|
+
text = computed(() => this.writtenLabel ?? this.navigation.t('account'), /* @ts-ignore */
|
|
1274
|
+
...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
|
|
1275
|
+
constructor() {
|
|
1276
|
+
super();
|
|
1277
|
+
afterNextRender(() => this.native.setAttribute('data-part', 'account'));
|
|
1278
|
+
}
|
|
1279
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationAccount, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1280
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.7", type: SlTopNavigationAccount, isStandalone: true, selector: "button[slTopNavigationAccount]", host: { attributes: { "data-part": "account", "type": "button" }, listeners: { "pointerenter": "onPointerEnter($event)", "pointerleave": "onPointerLeave($event)", "pointerdown": "onPointerDown($event)", "pointerup": "onPointerUp()", "pointercancel": "onPointerUp()", "focus": "onFocus($event)", "blur": "onBlur($event)" }, properties: { "attr.aria-describedby": "describedBy()", "attr.aria-label": "text()" } }, providers: HINT_PROVIDERS, exportAs: ["slTopNavigationAccount"], usesInheritance: true, hostDirectives: [{ directive: i2.SlTooltip }], ngImport: i0, template: "<ng-content />\n@if (hint()) {\n <ng-template slTooltipLayer>\n <div slTooltipContent>{{ text() }}</div>\n </ng-template>\n}", isInline: true, dependencies: [{ kind: "directive", type: SlTooltipLayer, selector: "ng-template[slTooltipLayer]", exportAs: ["slTooltipLayer"] }, { kind: "component", type: SlTooltipContent, selector: "[slTooltipContent]", exportAs: ["slTooltipContent"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1281
|
+
}
|
|
1282
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.7", ngImport: i0, type: SlTopNavigationAccount, decorators: [{
|
|
1283
|
+
type: Component,
|
|
1284
|
+
args: [{
|
|
1285
|
+
selector: 'button[slTopNavigationAccount]',
|
|
1286
|
+
standalone: true,
|
|
1287
|
+
exportAs: 'slTopNavigationAccount',
|
|
1288
|
+
imports: [SlTooltipLayer, SlTooltipContent],
|
|
1289
|
+
template: HINT_TEMPLATE,
|
|
1290
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
1291
|
+
encapsulation: ViewEncapsulation.None,
|
|
1292
|
+
hostDirectives: [SlTooltip],
|
|
1293
|
+
providers: HINT_PROVIDERS,
|
|
1294
|
+
host: {
|
|
1295
|
+
...HINT_HOST,
|
|
1296
|
+
'data-part': 'account',
|
|
1297
|
+
type: 'button',
|
|
1298
|
+
'[attr.aria-label]': 'text()',
|
|
1299
|
+
},
|
|
1300
|
+
}]
|
|
1301
|
+
}], ctorParameters: () => [] });
|
|
1302
|
+
|
|
1303
|
+
/**
|
|
1304
|
+
* Generated bundle index. Do not edit.
|
|
1305
|
+
*/
|
|
1306
|
+
|
|
1307
|
+
export { SlTopNavigation, SlTopNavigationAccount, SlTopNavigationAction, SlTopNavigationActions, SlTopNavigationBrand, SlTopNavigationContext, SlTopNavigationCount, SlTopNavigationHelp, SlTopNavigationHome, SlTopNavigationIdFactory, SlTopNavigationItem, SlTopNavigationLink, SlTopNavigationList, SlTopNavigationMark, SlTopNavigationMore, SlTopNavigationName, SlTopNavigationNav, SlTopNavigationNotifications, SlTopNavigationSearch, SlTopNavigationSearchClose, SlTopNavigationSearchToggle, SlTopNavigationTrigger, TOP_NAVIGATION_COLLAPSE_AT, TOP_NAVIGATION_CONTROL_SELECTOR, TOP_NAVIGATION_DEFAULTS, TOP_NAVIGATION_FALLBACK, injectTopNavigationDefaults, provideTopNavigationDefaults };
|
|
1308
|
+
//# sourceMappingURL=slotted-angular-top-navigation.mjs.map
|