@slotted/angular 0.1.0-beta.3 → 0.1.0-beta.31
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/docs/AGENTS.snippet.md +3 -1
- package/docs/accordion.json +5 -5
- package/docs/accordion.md +12 -12
- package/docs/action-bar.json +23 -22
- package/docs/action-bar.md +30 -30
- package/docs/action-sheet.json +391 -64
- package/docs/action-sheet.md +259 -0
- package/docs/alert.json +31 -14
- package/docs/alert.md +29 -18
- package/docs/app-shell.examples.md +8 -8
- package/docs/app-shell.json +38 -21
- package/docs/app-shell.md +9 -7
- package/docs/avatar-group.json +1 -1
- package/docs/avatar-group.md +1 -1
- package/docs/avatar.json +32 -11
- package/docs/avatar.md +13 -11
- package/docs/badge.json +10 -4
- package/docs/badge.md +5 -5
- package/docs/breadcrumb.json +2 -2
- package/docs/breadcrumb.md +2 -2
- package/docs/button-group.json +2 -1
- package/docs/button-group.md +2 -2
- package/docs/button.examples.md +15 -0
- package/docs/button.json +134 -14
- package/docs/button.md +32 -8
- package/docs/calendar.json +31 -6
- package/docs/calendar.md +9 -6
- package/docs/card.json +3 -2
- package/docs/card.md +3 -3
- package/docs/carousel.json +10 -10
- package/docs/carousel.md +11 -11
- package/docs/cascader.json +2 -0
- package/docs/cascader.md +1 -1
- package/docs/chart.examples.md +45 -31
- package/docs/chart.json +40 -35
- package/docs/chart.md +7 -7
- package/docs/checkbox-group.examples.md +13 -13
- package/docs/checkbox-group.json +7 -7
- package/docs/checkbox-group.md +2 -2
- package/docs/checkbox.examples.md +7 -7
- package/docs/checkbox.json +6 -6
- package/docs/checkbox.md +3 -3
- package/docs/code-block.json +93 -93
- package/docs/code-block.md +70 -70
- package/docs/collapsible.json +12 -11
- package/docs/collapsible.md +20 -20
- package/docs/color-picker.json +26 -26
- package/docs/color-picker.md +16 -16
- package/docs/combobox.json +6 -2
- package/docs/combobox.md +3 -3
- package/docs/command-palette.json +2 -0
- package/docs/command-palette.md +1 -1
- package/docs/context-menu.json +1 -1
- package/docs/context-menu.md +1 -1
- package/docs/currency-field.examples.md +3 -3
- package/docs/currency-field.json +14 -6
- package/docs/currency-field.md +6 -5
- package/docs/dashboard-grid.json +53 -10
- package/docs/dashboard-grid.md +18 -6
- package/docs/data-grid.examples.md +3 -3
- package/docs/data-grid.json +37 -11
- package/docs/data-grid.md +2 -1
- package/docs/data-grid.props.md +7 -5
- package/docs/data-list.json +2 -1
- package/docs/data-list.md +1 -1
- package/docs/date-field.json +12 -4
- package/docs/date-field.md +8 -7
- package/docs/date-picker.examples.md +36 -0
- package/docs/date-picker.json +32 -5
- package/docs/date-picker.md +7 -5
- package/docs/date-range-picker.json +11 -0
- package/docs/date-range-picker.md +2 -1
- package/docs/datetime-field.json +5 -4
- package/docs/datetime-field.md +10 -10
- package/docs/datetime-picker.json +11 -1
- package/docs/datetime-picker.md +2 -1
- package/docs/datetime-range-picker.examples.md +3 -3
- package/docs/datetime-range-picker.json +14 -3
- package/docs/datetime-range-picker.md +4 -3
- package/docs/description-list.json +16 -7
- package/docs/description-list.md +8 -7
- package/docs/detail-panel.json +14 -12
- package/docs/detail-panel.md +20 -15
- package/docs/dialog.examples.md +143 -141
- package/docs/dialog.json +58 -24
- package/docs/dialog.md +6 -4
- package/docs/dialog.props.md +9 -7
- package/docs/drawer.examples.md +14 -14
- package/docs/drawer.json +44 -17
- package/docs/drawer.md +10 -8
- package/docs/entity-picker.json +22 -4
- package/docs/entity-picker.md +8 -6
- package/docs/event-calendar.examples.md +3 -3
- package/docs/event-calendar.json +5 -5
- package/docs/event-calendar.md +4 -4
- package/docs/field-group.json +21 -6
- package/docs/field-group.md +14 -12
- package/docs/field.examples.md +3 -3
- package/docs/field.json +20 -5
- package/docs/field.md +4 -2
- package/docs/filter-bar.json +118 -118
- package/docs/filter-bar.md +79 -79
- package/docs/form.json +24 -12
- package/docs/form.md +15 -13
- package/docs/fullscreen.json +4 -4
- package/docs/fullscreen.md +7 -7
- package/docs/guidelines/README.md +2 -2
- package/docs/guidelines/async-feedback.md +25 -4
- package/docs/guidelines/builders.md +1 -1
- package/docs/guidelines/composition.md +37 -11
- package/docs/guidelines/conversations.md +1 -1
- package/docs/guidelines/errors-and-conflicts.md +7 -6
- package/docs/guidelines/forms.md +111 -1
- package/docs/guidelines/index.md +27 -7
- package/docs/guidelines/layout-alignment.md +24 -14
- package/docs/guidelines/list-pages.md +44 -3
- package/docs/guidelines/overviews.md +39 -9
- package/docs/guidelines/own-elements.md +8 -8
- package/docs/guidelines/reading-permissions.md +2 -2
- package/docs/guidelines/record-pages.md +1 -1
- package/docs/guidelines/reports.md +1 -1
- package/docs/highlight.json +9 -9
- package/docs/highlight.md +14 -14
- package/docs/icon.json +5 -3
- package/docs/icon.md +4 -4
- package/docs/image.json +3 -3
- package/docs/image.md +3 -3
- package/docs/import-export-center.json +24 -23
- package/docs/import-export-center.md +18 -18
- package/docs/index.md +3 -2
- package/docs/inline-message.json +34 -21
- package/docs/inline-message.md +32 -30
- package/docs/inline.json +1 -1
- package/docs/inline.md +1 -1
- package/docs/kbd.json +5 -2
- package/docs/kbd.md +3 -3
- package/docs/link.json +22 -6
- package/docs/link.md +9 -7
- package/docs/list-item.json +20 -4
- package/docs/list-item.md +20 -17
- package/docs/list.examples.md +907 -0
- package/docs/list.json +121 -33
- package/docs/list.md +73 -137
- package/docs/listbox.json +1 -2
- package/docs/listbox.md +2 -2
- package/docs/loading-overlay.json +3 -3
- package/docs/loading-overlay.md +3 -3
- package/docs/markdown.json +86 -79
- package/docs/markdown.md +66 -65
- package/docs/media-viewer.json +521 -0
- package/docs/media-viewer.md +188 -0
- package/docs/menu.json +15 -1
- package/docs/menu.md +3 -1
- package/docs/message-scroller.json +2 -2
- package/docs/message-scroller.md +1 -1
- package/docs/message.json +18 -12
- package/docs/message.md +20 -20
- package/docs/multi-select.json +4 -1
- package/docs/multi-select.md +1 -1
- package/docs/navigation-menu.json +1 -0
- package/docs/navigation-menu.md +1 -1
- package/docs/notification-center.json +21 -16
- package/docs/notification-center.md +20 -24
- package/docs/number-field.examples.md +3 -3
- package/docs/number-field.json +4 -3
- package/docs/number-field.md +1 -1
- package/docs/otp-input.json +11 -10
- package/docs/otp-input.md +14 -14
- package/docs/page-header.json +31 -14
- package/docs/page-header.md +25 -25
- package/docs/page.json +4 -2
- package/docs/page.md +3 -2
- package/docs/pagination.json +2 -2
- package/docs/pagination.md +1 -1
- package/docs/popover.examples.md +1 -1
- package/docs/popover.json +5 -3
- package/docs/popover.md +2 -2
- package/docs/progress-indicator.json +7 -5
- package/docs/progress-indicator.md +7 -7
- package/docs/prompt-composer.json +53 -6
- package/docs/prompt-composer.md +12 -6
- package/docs/prose.json +1 -1
- package/docs/prose.md +1 -1
- package/docs/radio-group.examples.md +19 -19
- package/docs/radio-group.json +12 -12
- package/docs/radio-group.md +3 -3
- package/docs/rating.json +28 -26
- package/docs/rating.md +28 -37
- package/docs/result-state.json +13 -12
- package/docs/result-state.md +18 -18
- package/docs/saved-views.json +1 -1
- package/docs/scroll-area.json +266 -64
- package/docs/scroll-area.md +188 -0
- package/docs/section.json +44 -22
- package/docs/section.md +34 -31
- package/docs/segmented-control.json +21 -25
- package/docs/segmented-control.md +33 -33
- package/docs/select.json +4 -0
- package/docs/select.md +1 -1
- package/docs/side-navigation.json +1 -0
- package/docs/side-navigation.md +1 -1
- package/docs/skeleton.json +1 -1
- package/docs/skeleton.md +1 -1
- package/docs/skills/build-own-element/SKILL.md +9 -9
- package/docs/skills/compose-screen/SKILL.md +59 -18
- package/docs/skills/index.md +2 -2
- package/docs/skills/review-screen/SKILL.md +29 -17
- package/docs/skills/theme-app/SKILL.md +66 -20
- package/docs/skills/waiting-states/SKILL.md +15 -11
- package/docs/slider.json +8 -8
- package/docs/slider.md +12 -12
- package/docs/sparkline.json +12 -9
- package/docs/sparkline.md +9 -9
- package/docs/split-button.json +14 -12
- package/docs/split-button.md +28 -30
- package/docs/splitter.json +279 -64
- package/docs/splitter.md +215 -0
- package/docs/stack.json +1 -1
- package/docs/stack.md +1 -1
- package/docs/stat-card.json +36 -9
- package/docs/stat-card.md +11 -8
- package/docs/status-indicator.json +22 -11
- package/docs/status-indicator.md +8 -6
- package/docs/stepper.json +4 -4
- package/docs/stepper.md +4 -4
- package/docs/switch.json +5 -5
- package/docs/switch.md +7 -7
- package/docs/table-of-contents.json +13 -12
- package/docs/table-of-contents.md +14 -14
- package/docs/table.examples.md +3 -3
- package/docs/table.json +17 -3
- package/docs/table.md +3 -1
- package/docs/tabs.json +16 -3
- package/docs/tabs.md +3 -2
- package/docs/tag.json +38 -26
- package/docs/tag.md +17 -17
- package/docs/tags-input.json +30 -3
- package/docs/tags-input.md +5 -2
- package/docs/text-field.examples.md +6 -6
- package/docs/text-field.json +6 -5
- package/docs/text-field.md +2 -2
- package/docs/textarea.examples.md +7 -7
- package/docs/textarea.json +4 -3
- package/docs/textarea.md +1 -1
- package/docs/time-field.json +4 -3
- package/docs/time-field.md +7 -7
- package/docs/time-picker.json +15 -5
- package/docs/time-picker.md +8 -7
- package/docs/time-range-picker.examples.md +5 -5
- package/docs/time-range-picker.json +15 -4
- package/docs/time-range-picker.md +3 -2
- package/docs/timeline.json +138 -132
- package/docs/timeline.md +125 -125
- package/docs/toast.json +15 -7
- package/docs/toast.md +8 -8
- package/docs/toggle-group.json +12 -12
- package/docs/toggle-group.md +28 -28
- package/docs/toggle.json +8 -8
- package/docs/toggle.md +7 -7
- package/docs/tokens.md +53 -26
- package/docs/toolbar.json +11 -11
- package/docs/toolbar.md +23 -23
- package/docs/tooltip.json +4 -3
- package/docs/tooltip.md +4 -4
- package/docs/top-navigation.examples.md +11 -15
- package/docs/top-navigation.json +9 -9
- package/docs/top-navigation.md +7 -7
- package/docs/tour.json +10 -9
- package/docs/tour.md +7 -7
- package/docs/typography.json +6 -4
- package/docs/typography.md +5 -5
- package/docs/upload.examples.md +3 -3
- package/docs/upload.json +9 -9
- package/docs/upload.md +4 -4
- package/fesm2022/slotted-angular-accordion.mjs +4 -2
- package/fesm2022/slotted-angular-accordion.mjs.map +1 -1
- package/fesm2022/slotted-angular-action-bar.mjs +27 -12
- package/fesm2022/slotted-angular-action-bar.mjs.map +1 -1
- package/fesm2022/slotted-angular-action-sheet.mjs +48 -29
- package/fesm2022/slotted-angular-action-sheet.mjs.map +1 -1
- package/fesm2022/slotted-angular-alert.mjs +56 -18
- package/fesm2022/slotted-angular-alert.mjs.map +1 -1
- package/fesm2022/slotted-angular-app-shell.mjs +85 -56
- package/fesm2022/slotted-angular-app-shell.mjs.map +1 -1
- package/fesm2022/slotted-angular-aspect-ratio.mjs +4 -2
- package/fesm2022/slotted-angular-aspect-ratio.mjs.map +1 -1
- package/fesm2022/slotted-angular-attachment.mjs +33 -22
- package/fesm2022/slotted-angular-attachment.mjs.map +1 -1
- package/fesm2022/slotted-angular-avatar-group.mjs +13 -10
- package/fesm2022/slotted-angular-avatar-group.mjs.map +1 -1
- package/fesm2022/slotted-angular-avatar.mjs +17 -10
- package/fesm2022/slotted-angular-avatar.mjs.map +1 -1
- package/fesm2022/slotted-angular-badge.mjs +15 -11
- package/fesm2022/slotted-angular-badge.mjs.map +1 -1
- package/fesm2022/slotted-angular-breadcrumb.mjs +27 -19
- package/fesm2022/slotted-angular-breadcrumb.mjs.map +1 -1
- package/fesm2022/slotted-angular-button-group.mjs +8 -5
- package/fesm2022/slotted-angular-button-group.mjs.map +1 -1
- package/fesm2022/slotted-angular-button.mjs +163 -28
- package/fesm2022/slotted-angular-button.mjs.map +1 -1
- package/fesm2022/slotted-angular-calendar.mjs +263 -65
- package/fesm2022/slotted-angular-calendar.mjs.map +1 -1
- package/fesm2022/slotted-angular-card.mjs +19 -17
- package/fesm2022/slotted-angular-card.mjs.map +1 -1
- package/fesm2022/slotted-angular-carousel.mjs +22 -11
- package/fesm2022/slotted-angular-carousel.mjs.map +1 -1
- package/fesm2022/slotted-angular-cascader.mjs +179 -65
- package/fesm2022/slotted-angular-cascader.mjs.map +1 -1
- package/fesm2022/slotted-angular-chart.mjs +26 -5
- package/fesm2022/slotted-angular-chart.mjs.map +1 -1
- package/fesm2022/slotted-angular-checkbox-group.mjs +5 -3
- package/fesm2022/slotted-angular-checkbox-group.mjs.map +1 -1
- package/fesm2022/slotted-angular-checkbox.mjs +14 -9
- package/fesm2022/slotted-angular-checkbox.mjs.map +1 -1
- package/fesm2022/slotted-angular-code-block.mjs +30 -16
- package/fesm2022/slotted-angular-code-block.mjs.map +1 -1
- package/fesm2022/slotted-angular-collapsible.mjs +21 -16
- package/fesm2022/slotted-angular-collapsible.mjs.map +1 -1
- package/fesm2022/slotted-angular-color-picker.mjs +83 -28
- package/fesm2022/slotted-angular-color-picker.mjs.map +1 -1
- package/fesm2022/slotted-angular-column-manager.mjs +71 -32
- package/fesm2022/slotted-angular-column-manager.mjs.map +1 -1
- package/fesm2022/slotted-angular-combobox.mjs +108 -35
- package/fesm2022/slotted-angular-combobox.mjs.map +1 -1
- package/fesm2022/slotted-angular-command-palette.mjs +162 -54
- package/fesm2022/slotted-angular-command-palette.mjs.map +1 -1
- package/fesm2022/slotted-angular-container.mjs +6 -4
- package/fesm2022/slotted-angular-container.mjs.map +1 -1
- package/fesm2022/slotted-angular-context-menu.mjs +5 -4
- package/fesm2022/slotted-angular-context-menu.mjs.map +1 -1
- package/fesm2022/slotted-angular-currency-field.mjs +100 -34
- package/fesm2022/slotted-angular-currency-field.mjs.map +1 -1
- package/fesm2022/slotted-angular-dashboard-grid.mjs +384 -88
- package/fesm2022/slotted-angular-dashboard-grid.mjs.map +1 -1
- package/fesm2022/slotted-angular-data-grid.mjs +461 -129
- package/fesm2022/slotted-angular-data-grid.mjs.map +1 -1
- package/fesm2022/slotted-angular-data-list.mjs +83 -50
- package/fesm2022/slotted-angular-data-list.mjs.map +1 -1
- package/fesm2022/slotted-angular-date-field.mjs +78 -27
- package/fesm2022/slotted-angular-date-field.mjs.map +1 -1
- package/fesm2022/slotted-angular-date-picker.mjs +135 -40
- package/fesm2022/slotted-angular-date-picker.mjs.map +1 -1
- package/fesm2022/slotted-angular-date-range-picker.mjs +68 -22
- package/fesm2022/slotted-angular-date-range-picker.mjs.map +1 -1
- package/fesm2022/slotted-angular-datetime-field.mjs +49 -17
- package/fesm2022/slotted-angular-datetime-field.mjs.map +1 -1
- package/fesm2022/slotted-angular-datetime-picker.mjs +64 -29
- package/fesm2022/slotted-angular-datetime-picker.mjs.map +1 -1
- package/fesm2022/slotted-angular-datetime-range-picker.mjs +144 -54
- package/fesm2022/slotted-angular-datetime-range-picker.mjs.map +1 -1
- package/fesm2022/slotted-angular-description-list.mjs +47 -24
- package/fesm2022/slotted-angular-description-list.mjs.map +1 -1
- package/fesm2022/slotted-angular-detail-panel.mjs +48 -30
- package/fesm2022/slotted-angular-detail-panel.mjs.map +1 -1
- package/fesm2022/slotted-angular-dialog.mjs +81 -39
- package/fesm2022/slotted-angular-dialog.mjs.map +1 -1
- package/fesm2022/slotted-angular-divider.mjs +7 -5
- package/fesm2022/slotted-angular-divider.mjs.map +1 -1
- package/fesm2022/slotted-angular-drawer.mjs +236 -105
- package/fesm2022/slotted-angular-drawer.mjs.map +1 -1
- package/fesm2022/slotted-angular-entity-picker.mjs +474 -75
- package/fesm2022/slotted-angular-entity-picker.mjs.map +1 -1
- package/fesm2022/slotted-angular-event-calendar.mjs +262 -105
- package/fesm2022/slotted-angular-event-calendar.mjs.map +1 -1
- package/fesm2022/slotted-angular-field-group.mjs +30 -9
- package/fesm2022/slotted-angular-field-group.mjs.map +1 -1
- package/fesm2022/slotted-angular-field.mjs +49 -18
- package/fesm2022/slotted-angular-field.mjs.map +1 -1
- package/fesm2022/slotted-angular-filter-bar.mjs +111 -44
- package/fesm2022/slotted-angular-filter-bar.mjs.map +1 -1
- package/fesm2022/slotted-angular-form.mjs +48 -17
- package/fesm2022/slotted-angular-form.mjs.map +1 -1
- package/fesm2022/slotted-angular-fullscreen.mjs +14 -8
- package/fesm2022/slotted-angular-fullscreen.mjs.map +1 -1
- package/fesm2022/slotted-angular-grid.mjs +6 -4
- package/fesm2022/slotted-angular-grid.mjs.map +1 -1
- package/fesm2022/slotted-angular-highlight.mjs +6 -4
- package/fesm2022/slotted-angular-highlight.mjs.map +1 -1
- package/fesm2022/slotted-angular-hover-card.mjs +5 -4
- package/fesm2022/slotted-angular-hover-card.mjs.map +1 -1
- package/fesm2022/slotted-angular-icon.mjs +191 -90
- package/fesm2022/slotted-angular-icon.mjs.map +1 -1
- package/fesm2022/slotted-angular-image.mjs +13 -10
- package/fesm2022/slotted-angular-image.mjs.map +1 -1
- package/fesm2022/slotted-angular-import-export-center.mjs +185 -109
- package/fesm2022/slotted-angular-import-export-center.mjs.map +1 -1
- package/fesm2022/slotted-angular-inline-message.mjs +98 -23
- package/fesm2022/slotted-angular-inline-message.mjs.map +1 -1
- package/fesm2022/slotted-angular-inline.mjs +7 -5
- package/fesm2022/slotted-angular-inline.mjs.map +1 -1
- package/fesm2022/slotted-angular-kbd.mjs +11 -7
- package/fesm2022/slotted-angular-kbd.mjs.map +1 -1
- package/fesm2022/slotted-angular-link.mjs +13 -4
- package/fesm2022/slotted-angular-link.mjs.map +1 -1
- package/fesm2022/slotted-angular-list-item.mjs +63 -23
- package/fesm2022/slotted-angular-list-item.mjs.map +1 -1
- package/fesm2022/slotted-angular-list.mjs +15 -11
- package/fesm2022/slotted-angular-list.mjs.map +1 -1
- package/fesm2022/slotted-angular-listbox.mjs +41 -23
- package/fesm2022/slotted-angular-listbox.mjs.map +1 -1
- package/fesm2022/slotted-angular-loading-overlay.mjs +62 -25
- package/fesm2022/slotted-angular-loading-overlay.mjs.map +1 -1
- package/fesm2022/slotted-angular-markdown.mjs +57 -31
- package/fesm2022/slotted-angular-markdown.mjs.map +1 -1
- package/fesm2022/slotted-angular-media-viewer.mjs +962 -0
- package/fesm2022/slotted-angular-media-viewer.mjs.map +1 -0
- package/fesm2022/slotted-angular-menu.mjs +62 -39
- package/fesm2022/slotted-angular-menu.mjs.map +1 -1
- package/fesm2022/slotted-angular-menubar.mjs +6 -3
- package/fesm2022/slotted-angular-menubar.mjs.map +1 -1
- package/fesm2022/slotted-angular-message-scroller.mjs +35 -16
- package/fesm2022/slotted-angular-message-scroller.mjs.map +1 -1
- package/fesm2022/slotted-angular-message.mjs +119 -51
- package/fesm2022/slotted-angular-message.mjs.map +1 -1
- package/fesm2022/slotted-angular-multi-select.mjs +163 -60
- package/fesm2022/slotted-angular-multi-select.mjs.map +1 -1
- package/fesm2022/slotted-angular-navigation-menu.mjs +34 -26
- package/fesm2022/slotted-angular-navigation-menu.mjs.map +1 -1
- package/fesm2022/slotted-angular-notification-center.mjs +111 -68
- package/fesm2022/slotted-angular-notification-center.mjs.map +1 -1
- package/fesm2022/slotted-angular-number-field.mjs +24 -12
- package/fesm2022/slotted-angular-number-field.mjs.map +1 -1
- package/fesm2022/slotted-angular-otp-input.mjs +14 -9
- package/fesm2022/slotted-angular-otp-input.mjs.map +1 -1
- package/fesm2022/slotted-angular-page-header.mjs +90 -48
- package/fesm2022/slotted-angular-page-header.mjs.map +1 -1
- package/fesm2022/slotted-angular-page.mjs +60 -12
- package/fesm2022/slotted-angular-page.mjs.map +1 -1
- package/fesm2022/slotted-angular-pagination.mjs +35 -22
- package/fesm2022/slotted-angular-pagination.mjs.map +1 -1
- package/fesm2022/slotted-angular-popover.mjs +34 -21
- package/fesm2022/slotted-angular-popover.mjs.map +1 -1
- package/fesm2022/slotted-angular-progress-indicator.mjs +238 -54
- package/fesm2022/slotted-angular-progress-indicator.mjs.map +1 -1
- package/fesm2022/slotted-angular-prompt-composer.mjs +132 -22
- package/fesm2022/slotted-angular-prompt-composer.mjs.map +1 -1
- package/fesm2022/slotted-angular-prose.mjs +14 -11
- package/fesm2022/slotted-angular-prose.mjs.map +1 -1
- package/fesm2022/slotted-angular-radio-group.mjs +17 -11
- package/fesm2022/slotted-angular-radio-group.mjs.map +1 -1
- package/fesm2022/slotted-angular-rating.mjs +143 -87
- package/fesm2022/slotted-angular-rating.mjs.map +1 -1
- package/fesm2022/slotted-angular-result-state.mjs +16 -12
- package/fesm2022/slotted-angular-result-state.mjs.map +1 -1
- package/fesm2022/slotted-angular-saved-views.mjs +43 -16
- package/fesm2022/slotted-angular-saved-views.mjs.map +1 -1
- package/fesm2022/slotted-angular-scroll-area.mjs +13 -5
- package/fesm2022/slotted-angular-scroll-area.mjs.map +1 -1
- package/fesm2022/slotted-angular-section.mjs +81 -19
- package/fesm2022/slotted-angular-section.mjs.map +1 -1
- package/fesm2022/slotted-angular-segmented-control.mjs +16 -10
- package/fesm2022/slotted-angular-segmented-control.mjs.map +1 -1
- package/fesm2022/slotted-angular-select.mjs +189 -69
- package/fesm2022/slotted-angular-select.mjs.map +1 -1
- package/fesm2022/slotted-angular-side-navigation.mjs +46 -35
- package/fesm2022/slotted-angular-side-navigation.mjs.map +1 -1
- package/fesm2022/slotted-angular-skeleton.mjs +32 -16
- package/fesm2022/slotted-angular-skeleton.mjs.map +1 -1
- package/fesm2022/slotted-angular-slider.mjs +34 -14
- package/fesm2022/slotted-angular-slider.mjs.map +1 -1
- package/fesm2022/slotted-angular-sparkline.mjs +41 -14
- package/fesm2022/slotted-angular-sparkline.mjs.map +1 -1
- package/fesm2022/slotted-angular-split-button.mjs +37 -11
- package/fesm2022/slotted-angular-split-button.mjs.map +1 -1
- package/fesm2022/slotted-angular-splitter.mjs +11 -9
- package/fesm2022/slotted-angular-splitter.mjs.map +1 -1
- package/fesm2022/slotted-angular-stack.mjs +6 -4
- package/fesm2022/slotted-angular-stack.mjs.map +1 -1
- package/fesm2022/slotted-angular-stat-card.mjs +120 -41
- package/fesm2022/slotted-angular-stat-card.mjs.map +1 -1
- package/fesm2022/slotted-angular-status-indicator.mjs +51 -20
- package/fesm2022/slotted-angular-status-indicator.mjs.map +1 -1
- package/fesm2022/slotted-angular-stepper.mjs +40 -15
- package/fesm2022/slotted-angular-stepper.mjs.map +1 -1
- package/fesm2022/slotted-angular-switch.mjs +15 -10
- package/fesm2022/slotted-angular-switch.mjs.map +1 -1
- package/fesm2022/slotted-angular-table-of-contents.mjs +29 -21
- package/fesm2022/slotted-angular-table-of-contents.mjs.map +1 -1
- package/fesm2022/slotted-angular-table.mjs +162 -79
- package/fesm2022/slotted-angular-table.mjs.map +1 -1
- package/fesm2022/slotted-angular-tabs.mjs +42 -18
- package/fesm2022/slotted-angular-tabs.mjs.map +1 -1
- package/fesm2022/slotted-angular-tag.mjs +20 -13
- package/fesm2022/slotted-angular-tag.mjs.map +1 -1
- package/fesm2022/slotted-angular-tags-input.mjs +254 -29
- package/fesm2022/slotted-angular-tags-input.mjs.map +1 -1
- package/fesm2022/slotted-angular-text-field.mjs +55 -15
- package/fesm2022/slotted-angular-text-field.mjs.map +1 -1
- package/fesm2022/slotted-angular-textarea.mjs +5 -3
- package/fesm2022/slotted-angular-textarea.mjs.map +1 -1
- package/fesm2022/slotted-angular-theme.mjs +6 -3
- package/fesm2022/slotted-angular-theme.mjs.map +1 -1
- package/fesm2022/slotted-angular-time-field.mjs +48 -14
- package/fesm2022/slotted-angular-time-field.mjs.map +1 -1
- package/fesm2022/slotted-angular-time-picker.mjs +55 -20
- package/fesm2022/slotted-angular-time-picker.mjs.map +1 -1
- package/fesm2022/slotted-angular-time-range-picker.mjs +142 -52
- package/fesm2022/slotted-angular-time-range-picker.mjs.map +1 -1
- package/fesm2022/slotted-angular-timeline.mjs +147 -64
- package/fesm2022/slotted-angular-timeline.mjs.map +1 -1
- package/fesm2022/slotted-angular-toast.mjs +50 -38
- package/fesm2022/slotted-angular-toast.mjs.map +1 -1
- package/fesm2022/slotted-angular-toggle-group.mjs +10 -6
- package/fesm2022/slotted-angular-toggle-group.mjs.map +1 -1
- package/fesm2022/slotted-angular-toggle.mjs +9 -4
- package/fesm2022/slotted-angular-toggle.mjs.map +1 -1
- package/fesm2022/slotted-angular-toolbar.mjs +27 -12
- package/fesm2022/slotted-angular-toolbar.mjs.map +1 -1
- package/fesm2022/slotted-angular-tooltip.mjs +15 -6
- package/fesm2022/slotted-angular-tooltip.mjs.map +1 -1
- package/fesm2022/slotted-angular-top-navigation.mjs +64 -44
- package/fesm2022/slotted-angular-top-navigation.mjs.map +1 -1
- package/fesm2022/slotted-angular-tour.mjs +49 -24
- package/fesm2022/slotted-angular-tour.mjs.map +1 -1
- package/fesm2022/slotted-angular-transfer.mjs +69 -30
- package/fesm2022/slotted-angular-transfer.mjs.map +1 -1
- package/fesm2022/slotted-angular-tree.mjs +80 -26
- package/fesm2022/slotted-angular-tree.mjs.map +1 -1
- package/fesm2022/slotted-angular-typography.mjs +9 -5
- package/fesm2022/slotted-angular-typography.mjs.map +1 -1
- package/fesm2022/slotted-angular-upload.mjs +127 -59
- package/fesm2022/slotted-angular-upload.mjs.map +1 -1
- package/fesm2022/slotted-angular-visually-hidden.mjs +4 -2
- package/fesm2022/slotted-angular-visually-hidden.mjs.map +1 -1
- package/fesm2022/slotted-angular-wizard.mjs +169 -71
- package/fesm2022/slotted-angular-wizard.mjs.map +1 -1
- package/package.json +19 -3
- package/types/slotted-angular-accordion.d.ts.map +1 -1
- package/types/slotted-angular-action-bar.d.ts +2 -0
- package/types/slotted-angular-action-bar.d.ts.map +1 -1
- package/types/slotted-angular-action-sheet.d.ts.map +1 -1
- package/types/slotted-angular-alert.d.ts +17 -8
- package/types/slotted-angular-alert.d.ts.map +1 -1
- package/types/slotted-angular-app-shell.d.ts +10 -8
- package/types/slotted-angular-app-shell.d.ts.map +1 -1
- package/types/slotted-angular-aspect-ratio.d.ts.map +1 -1
- package/types/slotted-angular-attachment.d.ts +2 -1
- package/types/slotted-angular-attachment.d.ts.map +1 -1
- package/types/slotted-angular-avatar-group.d.ts +3 -3
- package/types/slotted-angular-avatar-group.d.ts.map +1 -1
- package/types/slotted-angular-avatar.d.ts +17 -9
- package/types/slotted-angular-avatar.d.ts.map +1 -1
- package/types/slotted-angular-badge.d.ts +4 -4
- package/types/slotted-angular-badge.d.ts.map +1 -1
- package/types/slotted-angular-breadcrumb.d.ts +1 -1
- package/types/slotted-angular-breadcrumb.d.ts.map +1 -1
- package/types/slotted-angular-button-group.d.ts +2 -2
- package/types/slotted-angular-button-group.d.ts.map +1 -1
- package/types/slotted-angular-button.d.ts +45 -12
- package/types/slotted-angular-button.d.ts.map +1 -1
- package/types/slotted-angular-calendar.d.ts +43 -2
- package/types/slotted-angular-calendar.d.ts.map +1 -1
- package/types/slotted-angular-card.d.ts +1 -1
- package/types/slotted-angular-card.d.ts.map +1 -1
- package/types/slotted-angular-carousel.d.ts.map +1 -1
- package/types/slotted-angular-cascader.d.ts.map +1 -1
- package/types/slotted-angular-chart.d.ts +14 -11
- package/types/slotted-angular-chart.d.ts.map +1 -1
- package/types/slotted-angular-checkbox-group.d.ts.map +1 -1
- package/types/slotted-angular-checkbox.d.ts +1 -1
- package/types/slotted-angular-checkbox.d.ts.map +1 -1
- package/types/slotted-angular-code-block.d.ts +3 -2
- package/types/slotted-angular-code-block.d.ts.map +1 -1
- package/types/slotted-angular-collapsible.d.ts +3 -2
- package/types/slotted-angular-collapsible.d.ts.map +1 -1
- package/types/slotted-angular-color-picker.d.ts +6 -6
- package/types/slotted-angular-color-picker.d.ts.map +1 -1
- package/types/slotted-angular-column-manager.d.ts +1 -1
- package/types/slotted-angular-column-manager.d.ts.map +1 -1
- package/types/slotted-angular-combobox.d.ts +6 -1
- package/types/slotted-angular-combobox.d.ts.map +1 -1
- package/types/slotted-angular-command-palette.d.ts +10 -1
- package/types/slotted-angular-command-palette.d.ts.map +1 -1
- package/types/slotted-angular-container.d.ts.map +1 -1
- package/types/slotted-angular-context-menu.d.ts.map +1 -1
- package/types/slotted-angular-currency-field.d.ts +40 -14
- package/types/slotted-angular-currency-field.d.ts.map +1 -1
- package/types/slotted-angular-dashboard-grid.d.ts +65 -7
- package/types/slotted-angular-dashboard-grid.d.ts.map +1 -1
- package/types/slotted-angular-data-grid.d.ts +63 -5
- package/types/slotted-angular-data-grid.d.ts.map +1 -1
- package/types/slotted-angular-data-list.d.ts.map +1 -1
- package/types/slotted-angular-date-field.d.ts +12 -1
- package/types/slotted-angular-date-field.d.ts.map +1 -1
- package/types/slotted-angular-date-picker.d.ts +39 -12
- package/types/slotted-angular-date-picker.d.ts.map +1 -1
- package/types/slotted-angular-date-range-picker.d.ts +1 -1
- package/types/slotted-angular-date-range-picker.d.ts.map +1 -1
- package/types/slotted-angular-datetime-field.d.ts.map +1 -1
- package/types/slotted-angular-datetime-picker.d.ts +1 -1
- package/types/slotted-angular-datetime-picker.d.ts.map +1 -1
- package/types/slotted-angular-datetime-range-picker.d.ts +2 -2
- package/types/slotted-angular-datetime-range-picker.d.ts.map +1 -1
- package/types/slotted-angular-description-list.d.ts +12 -4
- package/types/slotted-angular-description-list.d.ts.map +1 -1
- package/types/slotted-angular-detail-panel.d.ts.map +1 -1
- package/types/slotted-angular-dialog.d.ts +11 -3
- package/types/slotted-angular-dialog.d.ts.map +1 -1
- package/types/slotted-angular-divider.d.ts.map +1 -1
- package/types/slotted-angular-drawer.d.ts +29 -3
- package/types/slotted-angular-drawer.d.ts.map +1 -1
- package/types/slotted-angular-entity-picker.d.ts +63 -15
- package/types/slotted-angular-entity-picker.d.ts.map +1 -1
- package/types/slotted-angular-event-calendar.d.ts.map +1 -1
- package/types/slotted-angular-field-group.d.ts +10 -2
- package/types/slotted-angular-field-group.d.ts.map +1 -1
- package/types/slotted-angular-field.d.ts +12 -4
- package/types/slotted-angular-field.d.ts.map +1 -1
- package/types/slotted-angular-filter-bar.d.ts.map +1 -1
- package/types/slotted-angular-form.d.ts +11 -2
- package/types/slotted-angular-form.d.ts.map +1 -1
- package/types/slotted-angular-fullscreen.d.ts.map +1 -1
- package/types/slotted-angular-grid.d.ts.map +1 -1
- package/types/slotted-angular-highlight.d.ts +1 -1
- package/types/slotted-angular-highlight.d.ts.map +1 -1
- package/types/slotted-angular-hover-card.d.ts.map +1 -1
- package/types/slotted-angular-icon.d.ts +15 -5
- package/types/slotted-angular-icon.d.ts.map +1 -1
- package/types/slotted-angular-image.d.ts.map +1 -1
- package/types/slotted-angular-import-export-center.d.ts +9 -9
- package/types/slotted-angular-import-export-center.d.ts.map +1 -1
- package/types/slotted-angular-inline-message.d.ts +32 -31
- package/types/slotted-angular-inline-message.d.ts.map +1 -1
- package/types/slotted-angular-inline.d.ts +1 -1
- package/types/slotted-angular-inline.d.ts.map +1 -1
- package/types/slotted-angular-kbd.d.ts +1 -1
- package/types/slotted-angular-kbd.d.ts.map +1 -1
- package/types/slotted-angular-link.d.ts +8 -2
- package/types/slotted-angular-link.d.ts.map +1 -1
- package/types/slotted-angular-list-item.d.ts +5 -1
- package/types/slotted-angular-list-item.d.ts.map +1 -1
- package/types/slotted-angular-list.d.ts +1 -1
- package/types/slotted-angular-list.d.ts.map +1 -1
- package/types/slotted-angular-listbox.d.ts +2 -2
- package/types/slotted-angular-listbox.d.ts.map +1 -1
- package/types/slotted-angular-loading-overlay.d.ts +3 -3
- package/types/slotted-angular-loading-overlay.d.ts.map +1 -1
- package/types/slotted-angular-markdown.d.ts +6 -1
- package/types/slotted-angular-markdown.d.ts.map +1 -1
- package/types/slotted-angular-media-viewer.d.ts +140 -0
- package/types/slotted-angular-media-viewer.d.ts.map +1 -0
- package/types/slotted-angular-menu.d.ts +17 -3
- package/types/slotted-angular-menu.d.ts.map +1 -1
- package/types/slotted-angular-menubar.d.ts +5 -4
- package/types/slotted-angular-menubar.d.ts.map +1 -1
- package/types/slotted-angular-message-scroller.d.ts +1 -1
- package/types/slotted-angular-message-scroller.d.ts.map +1 -1
- package/types/slotted-angular-message.d.ts +1 -1
- package/types/slotted-angular-message.d.ts.map +1 -1
- package/types/slotted-angular-multi-select.d.ts +6 -1
- package/types/slotted-angular-multi-select.d.ts.map +1 -1
- package/types/slotted-angular-navigation-menu.d.ts.map +1 -1
- package/types/slotted-angular-notification-center.d.ts +5 -5
- package/types/slotted-angular-notification-center.d.ts.map +1 -1
- package/types/slotted-angular-number-field.d.ts.map +1 -1
- package/types/slotted-angular-otp-input.d.ts +1 -1
- package/types/slotted-angular-otp-input.d.ts.map +1 -1
- package/types/slotted-angular-page-header.d.ts +15 -6
- package/types/slotted-angular-page-header.d.ts.map +1 -1
- package/types/slotted-angular-page.d.ts +7 -1
- package/types/slotted-angular-page.d.ts.map +1 -1
- package/types/slotted-angular-pagination.d.ts.map +1 -1
- package/types/slotted-angular-popover.d.ts.map +1 -1
- package/types/slotted-angular-progress-indicator.d.ts +10 -3
- package/types/slotted-angular-progress-indicator.d.ts.map +1 -1
- package/types/slotted-angular-prompt-composer.d.ts +35 -3
- package/types/slotted-angular-prompt-composer.d.ts.map +1 -1
- package/types/slotted-angular-prose.d.ts.map +1 -1
- package/types/slotted-angular-radio-group.d.ts +2 -2
- package/types/slotted-angular-radio-group.d.ts.map +1 -1
- package/types/slotted-angular-rating.d.ts +3 -3
- package/types/slotted-angular-rating.d.ts.map +1 -1
- package/types/slotted-angular-result-state.d.ts +1 -1
- package/types/slotted-angular-result-state.d.ts.map +1 -1
- package/types/slotted-angular-saved-views.d.ts.map +1 -1
- package/types/slotted-angular-scroll-area.d.ts.map +1 -1
- package/types/slotted-angular-section.d.ts +14 -4
- package/types/slotted-angular-section.d.ts.map +1 -1
- package/types/slotted-angular-segmented-control.d.ts +2 -2
- package/types/slotted-angular-segmented-control.d.ts.map +1 -1
- package/types/slotted-angular-select.d.ts +13 -2
- package/types/slotted-angular-select.d.ts.map +1 -1
- package/types/slotted-angular-side-navigation.d.ts.map +1 -1
- package/types/slotted-angular-skeleton.d.ts.map +1 -1
- package/types/slotted-angular-slider.d.ts.map +1 -1
- package/types/slotted-angular-sparkline.d.ts +7 -1
- package/types/slotted-angular-sparkline.d.ts.map +1 -1
- package/types/slotted-angular-split-button.d.ts +2 -2
- package/types/slotted-angular-split-button.d.ts.map +1 -1
- package/types/slotted-angular-splitter.d.ts.map +1 -1
- package/types/slotted-angular-stack.d.ts.map +1 -1
- package/types/slotted-angular-stat-card.d.ts +31 -7
- package/types/slotted-angular-stat-card.d.ts.map +1 -1
- package/types/slotted-angular-status-indicator.d.ts +15 -5
- package/types/slotted-angular-status-indicator.d.ts.map +1 -1
- package/types/slotted-angular-stepper.d.ts +2 -1
- package/types/slotted-angular-stepper.d.ts.map +1 -1
- package/types/slotted-angular-switch.d.ts +1 -1
- package/types/slotted-angular-switch.d.ts.map +1 -1
- package/types/slotted-angular-table-of-contents.d.ts.map +1 -1
- package/types/slotted-angular-table.d.ts +21 -4
- package/types/slotted-angular-table.d.ts.map +1 -1
- package/types/slotted-angular-tabs.d.ts +4 -5
- package/types/slotted-angular-tabs.d.ts.map +1 -1
- package/types/slotted-angular-tag.d.ts +5 -5
- package/types/slotted-angular-tag.d.ts.map +1 -1
- package/types/slotted-angular-tags-input.d.ts +34 -2
- package/types/slotted-angular-tags-input.d.ts.map +1 -1
- package/types/slotted-angular-text-field.d.ts.map +1 -1
- package/types/slotted-angular-textarea.d.ts.map +1 -1
- package/types/slotted-angular-theme.d.ts +8 -6
- package/types/slotted-angular-theme.d.ts.map +1 -1
- package/types/slotted-angular-time-field.d.ts.map +1 -1
- package/types/slotted-angular-time-picker.d.ts +1 -1
- package/types/slotted-angular-time-picker.d.ts.map +1 -1
- package/types/slotted-angular-time-range-picker.d.ts +2 -2
- package/types/slotted-angular-time-range-picker.d.ts.map +1 -1
- package/types/slotted-angular-timeline.d.ts +1 -1
- package/types/slotted-angular-timeline.d.ts.map +1 -1
- package/types/slotted-angular-toast.d.ts +9 -7
- package/types/slotted-angular-toast.d.ts.map +1 -1
- package/types/slotted-angular-toggle-group.d.ts +1 -1
- package/types/slotted-angular-toggle-group.d.ts.map +1 -1
- package/types/slotted-angular-toggle.d.ts +1 -1
- package/types/slotted-angular-toggle.d.ts.map +1 -1
- package/types/slotted-angular-toolbar.d.ts +2 -0
- package/types/slotted-angular-toolbar.d.ts.map +1 -1
- package/types/slotted-angular-tooltip.d.ts.map +1 -1
- package/types/slotted-angular-top-navigation.d.ts.map +1 -1
- package/types/slotted-angular-tour.d.ts +2 -2
- package/types/slotted-angular-tour.d.ts.map +1 -1
- package/types/slotted-angular-transfer.d.ts.map +1 -1
- package/types/slotted-angular-tree.d.ts.map +1 -1
- package/types/slotted-angular-typography.d.ts +1 -1
- package/types/slotted-angular-typography.d.ts.map +1 -1
- package/types/slotted-angular-upload.d.ts +4 -2
- package/types/slotted-angular-upload.d.ts.map +1 -1
- package/types/slotted-angular-visually-hidden.d.ts.map +1 -1
- package/types/slotted-angular-wizard.d.ts +1 -1
- package/types/slotted-angular-wizard.d.ts.map +1 -1
package/docs/dialog.examples.md
CHANGED
|
@@ -117,7 +117,7 @@ export class DialogSizes {
|
|
|
117
117
|
|
|
118
118
|
### Where the panel sits in the layer
|
|
119
119
|
|
|
120
|
-
center is right for a panel whose height is settled; top is right for one that grows as the reader types, because a
|
|
120
|
+
center is right for a panel whose height is settled; top is right for one that grows as the reader types, because a centerd panel moves under the cursor every time a line is added.
|
|
121
121
|
|
|
122
122
|
Example
|
|
123
123
|
|
|
@@ -604,7 +604,7 @@ export class DialogNested {
|
|
|
604
604
|
|
|
605
605
|
### Content the family did not choose
|
|
606
606
|
|
|
607
|
-
A ninety-character unbroken token in the title would widen a
|
|
607
|
+
A ninety-character unbroken token in the title would widen a centerd panel past both edges of the layer at once; overflow-wrap and a zero minimum are the pair that answer it. Long German and right-to-left strings are in the same scene.
|
|
608
608
|
|
|
609
609
|
Excerpt — not a complete module
|
|
610
610
|
|
|
@@ -642,6 +642,144 @@ Excerpt — not a complete module
|
|
|
642
642
|
padding-inline: var(--slotted-dialog-inset-inline); } -->
|
|
643
643
|
```
|
|
644
644
|
|
|
645
|
+
### A dialog that is a form
|
|
646
|
+
|
|
647
|
+
A dialog that edits a record submits with Enter from any field and with the footer’s submit. A form written around the header, the body and the footer draws no box of its own, so the parts stay the panel’s rows and keep its inset.
|
|
648
|
+
|
|
649
|
+
Example
|
|
650
|
+
|
|
651
|
+
```ts
|
|
652
|
+
import { Component, computed, signal } from '@angular/core';
|
|
653
|
+
import { SlButton } from '@slotted/angular/button';
|
|
654
|
+
import {
|
|
655
|
+
SlDialog,
|
|
656
|
+
SlDialogBody,
|
|
657
|
+
SlDialogClose,
|
|
658
|
+
SlDialogDescription,
|
|
659
|
+
SlDialogFooter,
|
|
660
|
+
SlDialogHeader,
|
|
661
|
+
SlDialogTitle,
|
|
662
|
+
SlDialogTrigger,
|
|
663
|
+
} from '@slotted/angular/dialog';
|
|
664
|
+
import { SlField, SlFieldError, SlFieldLabel } from '@slotted/angular/field';
|
|
665
|
+
import { SlInline } from '@slotted/angular/inline';
|
|
666
|
+
import { SlStack } from '@slotted/angular/stack';
|
|
667
|
+
import { SlTextField, SlTextFieldInput } from '@slotted/angular/text-field';
|
|
668
|
+
import { SlText } from '@slotted/angular/typography';
|
|
669
|
+
|
|
670
|
+
function nameError(value: string): string {
|
|
671
|
+
return value.trim() === '' ? 'Enter the contact’s full name.' : '';
|
|
672
|
+
}
|
|
673
|
+
|
|
674
|
+
function emailError(value: string): string {
|
|
675
|
+
if (value.trim() === '') return 'Enter the address the contact reads.';
|
|
676
|
+
if (!/^\S+@\S+\.\S+$/.test(value)) return 'Enter an address like ana@contoso.com.';
|
|
677
|
+
return '';
|
|
678
|
+
}
|
|
679
|
+
|
|
680
|
+
@Component({
|
|
681
|
+
selector: 'app-dialog-form',
|
|
682
|
+
imports: [
|
|
683
|
+
SlButton,
|
|
684
|
+
SlDialog,
|
|
685
|
+
SlDialogBody,
|
|
686
|
+
SlDialogClose,
|
|
687
|
+
SlDialogDescription,
|
|
688
|
+
SlDialogFooter,
|
|
689
|
+
SlDialogHeader,
|
|
690
|
+
SlDialogTitle,
|
|
691
|
+
SlDialogTrigger,
|
|
692
|
+
SlField,
|
|
693
|
+
SlFieldError,
|
|
694
|
+
SlFieldLabel,
|
|
695
|
+
SlInline,
|
|
696
|
+
SlStack,
|
|
697
|
+
SlText,
|
|
698
|
+
SlTextField,
|
|
699
|
+
SlTextFieldInput,
|
|
700
|
+
],
|
|
701
|
+
template: `
|
|
702
|
+
<div slInline align="center" [gap]="3">
|
|
703
|
+
<button slButton [slDialogTrigger]="dialog">Add contact</button>
|
|
704
|
+
<sl-dialog #dialog="slDialog" [open]="open()" (openChange)="toggle($event)">
|
|
705
|
+
<header slDialogHeader>
|
|
706
|
+
<h2 slDialogTitle>New contact</h2>
|
|
707
|
+
<p slDialogDescription>Contoso Foods, Seattle.</p>
|
|
708
|
+
<button slDialogClose></button>
|
|
709
|
+
</header>
|
|
710
|
+
<div slDialogBody>
|
|
711
|
+
<form id="new-contact" novalidate (submit)="submit($event)">
|
|
712
|
+
<div slStack [gap]="4">
|
|
713
|
+
<div slField required [invalid]="errors()?.name ? true : undefined">
|
|
714
|
+
<label slFieldLabel>Full name</label>
|
|
715
|
+
<div slTextField>
|
|
716
|
+
<input
|
|
717
|
+
slTextFieldInput
|
|
718
|
+
autocomplete="name"
|
|
719
|
+
[value]="name()"
|
|
720
|
+
(valueChange)="name.set($event.value)"
|
|
721
|
+
/>
|
|
722
|
+
</div>
|
|
723
|
+
<span slFieldError live="polite" reserve>{{ errors()?.name }}</span>
|
|
724
|
+
</div>
|
|
725
|
+
<div slField required [invalid]="errors()?.email ? true : undefined">
|
|
726
|
+
<label slFieldLabel>Email</label>
|
|
727
|
+
<div slTextField>
|
|
728
|
+
<input
|
|
729
|
+
slTextFieldInput
|
|
730
|
+
autocomplete="email"
|
|
731
|
+
type="email"
|
|
732
|
+
[value]="email()"
|
|
733
|
+
(valueChange)="email.set($event.value)"
|
|
734
|
+
/>
|
|
735
|
+
</div>
|
|
736
|
+
<span slFieldError live="polite" reserve>{{ errors()?.email }}</span>
|
|
737
|
+
</div>
|
|
738
|
+
</div>
|
|
739
|
+
</form>
|
|
740
|
+
</div>
|
|
741
|
+
<footer slDialogFooter>
|
|
742
|
+
<button slButton variant="ghost" tone="secondary" (click)="open.set(false)">
|
|
743
|
+
Cancel
|
|
744
|
+
</button>
|
|
745
|
+
<button slButton type="submit" form="new-contact">Add contact</button>
|
|
746
|
+
</footer>
|
|
747
|
+
</sl-dialog>
|
|
748
|
+
@if (added(); as message) {
|
|
749
|
+
<span slText role="status" size="sm" tone="muted">{{ message }}</span>
|
|
750
|
+
}
|
|
751
|
+
</div>
|
|
752
|
+
`,
|
|
753
|
+
})
|
|
754
|
+
export class DialogForm {
|
|
755
|
+
readonly open = signal(false);
|
|
756
|
+
readonly name = signal('');
|
|
757
|
+
readonly email = signal('');
|
|
758
|
+
readonly submitted = signal(false);
|
|
759
|
+
readonly added = signal<string | null>(null);
|
|
760
|
+
readonly errors = computed(() =>
|
|
761
|
+
this.submitted() ? { name: nameError(this.name()), email: emailError(this.email()) } : null,
|
|
762
|
+
);
|
|
763
|
+
|
|
764
|
+
toggle(next: boolean): void {
|
|
765
|
+
if (next) {
|
|
766
|
+
this.name.set('');
|
|
767
|
+
this.email.set('');
|
|
768
|
+
this.submitted.set(false);
|
|
769
|
+
}
|
|
770
|
+
this.open.set(next);
|
|
771
|
+
}
|
|
772
|
+
|
|
773
|
+
submit(event: Event): void {
|
|
774
|
+
event.preventDefault();
|
|
775
|
+
this.submitted.set(true);
|
|
776
|
+
if (nameError(this.name()) !== '' || emailError(this.email()) !== '') return;
|
|
777
|
+
this.added.set(`${this.name().trim()} was added to Contoso Foods.`);
|
|
778
|
+
this.open.set(false);
|
|
779
|
+
}
|
|
780
|
+
}
|
|
781
|
+
```
|
|
782
|
+
|
|
645
783
|
### Deciding once for the application
|
|
646
784
|
|
|
647
785
|
Eight decisions an application takes once instead of eight props on every dialog in a product. Angular Material is the only surveyed library with an equivalent, and a dialog that states one itself still wins.
|
|
@@ -746,7 +884,7 @@ Excerpt — not a complete module
|
|
|
746
884
|
|
|
747
885
|
### What kind of decision this is
|
|
748
886
|
|
|
749
|
-
Each tone carries its own mark, so the register survives a reader who cannot tell the
|
|
887
|
+
Each tone carries its own mark, so the register survives a reader who cannot tell the colors apart and forced colors, where every tone ground becomes one system color and the silhouette is all that is left.
|
|
750
888
|
|
|
751
889
|
Excerpt — not a complete module
|
|
752
890
|
|
|
@@ -756,7 +894,7 @@ Excerpt — not a complete module
|
|
|
756
894
|
|
|
757
895
|
### Two controls, each saying what it does
|
|
758
896
|
|
|
759
|
-
Labels name the action rather than answering a question — “
|
|
897
|
+
Labels name the action rather than answering a question — “Delete project”, not “Yes”. The action closes with submit and the cancel with dismiss, so a consumer reading the reason knows which one the reader chose.
|
|
760
898
|
|
|
761
899
|
Excerpt — not a complete module
|
|
762
900
|
|
|
@@ -803,7 +941,7 @@ Excerpt — not a complete module
|
|
|
803
941
|
|
|
804
942
|
### The actions are the consumer’s own buttons
|
|
805
943
|
|
|
806
|
-
render hands each control every attribute the family wrote, so the danger button is the library’s Button with the family’s
|
|
944
|
+
render hands each control every attribute the family wrote, so the danger button is the library’s Button with the family’s behavior on it — nothing is reimplemented and nothing is wrapped.
|
|
807
945
|
|
|
808
946
|
Excerpt — not a complete module
|
|
809
947
|
|
|
@@ -1639,142 +1777,6 @@ export class DialogDismiss {
|
|
|
1639
1777
|
}
|
|
1640
1778
|
```
|
|
1641
1779
|
|
|
1642
|
-
### form.ts
|
|
1643
|
-
|
|
1644
|
-
Example
|
|
1645
|
-
|
|
1646
|
-
```ts
|
|
1647
|
-
import { Component, computed, signal } from '@angular/core';
|
|
1648
|
-
import { SlButton } from '@slotted/angular/button';
|
|
1649
|
-
import {
|
|
1650
|
-
SlDialog,
|
|
1651
|
-
SlDialogBody,
|
|
1652
|
-
SlDialogClose,
|
|
1653
|
-
SlDialogDescription,
|
|
1654
|
-
SlDialogFooter,
|
|
1655
|
-
SlDialogHeader,
|
|
1656
|
-
SlDialogTitle,
|
|
1657
|
-
SlDialogTrigger,
|
|
1658
|
-
} from '@slotted/angular/dialog';
|
|
1659
|
-
import { SlField, SlFieldError, SlFieldLabel } from '@slotted/angular/field';
|
|
1660
|
-
import { SlInline } from '@slotted/angular/inline';
|
|
1661
|
-
import { SlStack } from '@slotted/angular/stack';
|
|
1662
|
-
import { SlTextField, SlTextFieldInput } from '@slotted/angular/text-field';
|
|
1663
|
-
import { SlText } from '@slotted/angular/typography';
|
|
1664
|
-
|
|
1665
|
-
function nameError(value: string): string {
|
|
1666
|
-
return value.trim() === '' ? 'Enter the contact’s full name.' : '';
|
|
1667
|
-
}
|
|
1668
|
-
|
|
1669
|
-
function emailError(value: string): string {
|
|
1670
|
-
if (value.trim() === '') return 'Enter the address the contact reads.';
|
|
1671
|
-
if (!/^\S+@\S+\.\S+$/.test(value)) return 'Enter an address like ana@contoso.com.';
|
|
1672
|
-
return '';
|
|
1673
|
-
}
|
|
1674
|
-
|
|
1675
|
-
@Component({
|
|
1676
|
-
selector: 'app-dialog-form',
|
|
1677
|
-
imports: [
|
|
1678
|
-
SlButton,
|
|
1679
|
-
SlDialog,
|
|
1680
|
-
SlDialogBody,
|
|
1681
|
-
SlDialogClose,
|
|
1682
|
-
SlDialogDescription,
|
|
1683
|
-
SlDialogFooter,
|
|
1684
|
-
SlDialogHeader,
|
|
1685
|
-
SlDialogTitle,
|
|
1686
|
-
SlDialogTrigger,
|
|
1687
|
-
SlField,
|
|
1688
|
-
SlFieldError,
|
|
1689
|
-
SlFieldLabel,
|
|
1690
|
-
SlInline,
|
|
1691
|
-
SlStack,
|
|
1692
|
-
SlText,
|
|
1693
|
-
SlTextField,
|
|
1694
|
-
SlTextFieldInput,
|
|
1695
|
-
],
|
|
1696
|
-
template: `
|
|
1697
|
-
<div slInline align="center" [gap]="3">
|
|
1698
|
-
<button slButton [slDialogTrigger]="dialog">Add contact</button>
|
|
1699
|
-
<sl-dialog #dialog="slDialog" [open]="open()" (openChange)="toggle($event)">
|
|
1700
|
-
<header slDialogHeader>
|
|
1701
|
-
<h2 slDialogTitle>New contact</h2>
|
|
1702
|
-
<p slDialogDescription>Contoso Foods, Seattle.</p>
|
|
1703
|
-
<button slDialogClose></button>
|
|
1704
|
-
</header>
|
|
1705
|
-
<div slDialogBody>
|
|
1706
|
-
<form id="new-contact" novalidate (submit)="submit($event)">
|
|
1707
|
-
<div slStack [gap]="4">
|
|
1708
|
-
<div slField required [invalid]="errors()?.name ? true : undefined">
|
|
1709
|
-
<label slFieldLabel>Full name</label>
|
|
1710
|
-
<div slTextField>
|
|
1711
|
-
<input
|
|
1712
|
-
slTextFieldInput
|
|
1713
|
-
autocomplete="name"
|
|
1714
|
-
[value]="name()"
|
|
1715
|
-
(valueChange)="name.set($event.value)"
|
|
1716
|
-
/>
|
|
1717
|
-
</div>
|
|
1718
|
-
<span slFieldError live="polite" reserve>{{ errors()?.name }}</span>
|
|
1719
|
-
</div>
|
|
1720
|
-
<div slField required [invalid]="errors()?.email ? true : undefined">
|
|
1721
|
-
<label slFieldLabel>Email</label>
|
|
1722
|
-
<div slTextField>
|
|
1723
|
-
<input
|
|
1724
|
-
slTextFieldInput
|
|
1725
|
-
autocomplete="email"
|
|
1726
|
-
type="email"
|
|
1727
|
-
[value]="email()"
|
|
1728
|
-
(valueChange)="email.set($event.value)"
|
|
1729
|
-
/>
|
|
1730
|
-
</div>
|
|
1731
|
-
<span slFieldError live="polite" reserve>{{ errors()?.email }}</span>
|
|
1732
|
-
</div>
|
|
1733
|
-
</div>
|
|
1734
|
-
</form>
|
|
1735
|
-
</div>
|
|
1736
|
-
<footer slDialogFooter>
|
|
1737
|
-
<button slButton variant="ghost" tone="secondary" (click)="open.set(false)">
|
|
1738
|
-
Cancel
|
|
1739
|
-
</button>
|
|
1740
|
-
<button slButton type="submit" form="new-contact">Add contact</button>
|
|
1741
|
-
</footer>
|
|
1742
|
-
</sl-dialog>
|
|
1743
|
-
@if (added(); as message) {
|
|
1744
|
-
<span slText role="status" size="sm" tone="muted">{{ message }}</span>
|
|
1745
|
-
}
|
|
1746
|
-
</div>
|
|
1747
|
-
`,
|
|
1748
|
-
})
|
|
1749
|
-
export class DialogForm {
|
|
1750
|
-
readonly open = signal(false);
|
|
1751
|
-
readonly name = signal('');
|
|
1752
|
-
readonly email = signal('');
|
|
1753
|
-
readonly submitted = signal(false);
|
|
1754
|
-
readonly added = signal<string | null>(null);
|
|
1755
|
-
readonly errors = computed(() =>
|
|
1756
|
-
this.submitted() ? { name: nameError(this.name()), email: emailError(this.email()) } : null,
|
|
1757
|
-
);
|
|
1758
|
-
|
|
1759
|
-
toggle(next: boolean): void {
|
|
1760
|
-
if (next) {
|
|
1761
|
-
this.name.set('');
|
|
1762
|
-
this.email.set('');
|
|
1763
|
-
this.submitted.set(false);
|
|
1764
|
-
}
|
|
1765
|
-
this.open.set(next);
|
|
1766
|
-
}
|
|
1767
|
-
|
|
1768
|
-
submit(event: Event): void {
|
|
1769
|
-
event.preventDefault();
|
|
1770
|
-
this.submitted.set(true);
|
|
1771
|
-
if (nameError(this.name()) !== '' || emailError(this.email()) !== '') return;
|
|
1772
|
-
this.added.set(`${this.name().trim()} was added to Contoso Foods.`);
|
|
1773
|
-
this.open.set(false);
|
|
1774
|
-
}
|
|
1775
|
-
}
|
|
1776
|
-
```
|
|
1777
|
-
|
|
1778
1780
|
### full-screen.ts
|
|
1779
1781
|
|
|
1780
1782
|
Example
|
package/docs/dialog.json
CHANGED
|
@@ -55,6 +55,7 @@
|
|
|
55
55
|
"tone": [
|
|
56
56
|
"accent",
|
|
57
57
|
"secondary",
|
|
58
|
+
"info",
|
|
58
59
|
"success",
|
|
59
60
|
"warning",
|
|
60
61
|
"danger"
|
|
@@ -266,7 +267,7 @@
|
|
|
266
267
|
"type": "'sm' | 'md' | 'lg' | 'xl' | 'full'",
|
|
267
268
|
"defaultValue": "md",
|
|
268
269
|
"appliesTo": "sl-dialog, provideDialogDefaults",
|
|
269
|
-
"description": "The maximum width of the panel:
|
|
270
|
+
"description": "The maximum width of the panel: 32rem, the form measure plus the panel padding (43rem by default), 48rem, 56rem, or the whole layer less its padding. For another width, set --slotted-dialog-measure, or --slotted-dialog-measure-sm, -md, -lg or -xl for one step."
|
|
270
271
|
},
|
|
271
272
|
{
|
|
272
273
|
"name": "placement",
|
|
@@ -350,7 +351,7 @@
|
|
|
350
351
|
"type": "'close' | 'none'",
|
|
351
352
|
"defaultValue": "close",
|
|
352
353
|
"appliesTo": "sl-dialog, provideDialogDefaults",
|
|
353
|
-
"description": "Whether the browser’s way back, a back button or a phone’s back gesture, closes a modal dialog instead of leaving the page. Each open modal dialog adds one history entry
|
|
354
|
+
"description": "Whether the browser’s way back, a back button or a phone’s back gesture, closes a modal dialog instead of leaving the page. Each open modal dialog holds one close watcher where the browser has CloseWatcher, and adds one history entry elsewhere; the close request carries the reason back. A dialog opened without a press shares the way back with the layer opened before it."
|
|
354
355
|
},
|
|
355
356
|
{
|
|
356
357
|
"name": "surface",
|
|
@@ -408,7 +409,14 @@
|
|
|
408
409
|
"type": "length",
|
|
409
410
|
"defaultValue": "from size",
|
|
410
411
|
"appliesTo": "the root part",
|
|
411
|
-
"description": "The maximum width of the panel, for a width the five sizes do not hold, such as a two-column form at 46rem. Set it with a style attribute on one dialog, with a rule for a region, or once in the theme. It takes precedence over size."
|
|
412
|
+
"description": "The maximum width of the panel, for a width the five sizes do not hold, such as a two-column form at 46rem. Set it with a style attribute on one dialog, with a rule for a region, or once in the theme. It takes precedence over size, and a step token takes precedence over it."
|
|
413
|
+
},
|
|
414
|
+
{
|
|
415
|
+
"name": "--slotted-dialog-measure-sm, -md, -lg, -xl",
|
|
416
|
+
"type": "length",
|
|
417
|
+
"defaultValue": "from size",
|
|
418
|
+
"appliesTo": "the root part",
|
|
419
|
+
"description": "The maximum width of one size step, read before --slotted-dialog-measure, so a theme widens one step and keeps the others."
|
|
412
420
|
},
|
|
413
421
|
{
|
|
414
422
|
"name": "container",
|
|
@@ -431,6 +439,11 @@
|
|
|
431
439
|
"payload": "DialogChangeRequest",
|
|
432
440
|
"when": "Before the dialog opens or closes, whatever caused it. The request carries the new value, the previous value, the reason (pointer, keyboard, dismiss, escape, outsidePress, back, submit or programmatic), the result of the close, the originating event, and cancel(), which keeps the dialog as it is. One handler therefore guards the ✕, Escape, a press outside, the way back and close() together."
|
|
433
441
|
},
|
|
442
|
+
{
|
|
443
|
+
"name": "(openChangeComplete)",
|
|
444
|
+
"payload": "boolean",
|
|
445
|
+
"when": "After the entrance or the exit has ended: true once the layer is settled open, false once it has left — the moment an application that renders the layer conditionally removes it, so the exit runs."
|
|
446
|
+
},
|
|
434
447
|
{
|
|
435
448
|
"name": "(openChange)",
|
|
436
449
|
"payload": "boolean",
|
|
@@ -459,7 +472,7 @@
|
|
|
459
472
|
"When the dialog opens, focus moves to its first focusable element, to the element initialFocus names, or to the panel itself with initialFocus=\"container\", for content that is read before it is used. When it closes, focus returns to the element that had it when the dialog opened, or to the element finalFocus names. If that element has left the document, focus goes to its nearest ancestor still in the document.",
|
|
460
473
|
"Containment, inertness and Escape are implemented in JavaScript rather than with the native dialog element, so every overlay of the library shares one stacking order: a select opened inside a dialog paints above it. Without JavaScript, there is no dialog.",
|
|
461
474
|
"The close button’s target is at least 24 by 24 pixels, and its mark is drawn from a glyph, not a character.",
|
|
462
|
-
"The panel has a border as well as a shadow, so its edge stays visible under forced
|
|
475
|
+
"The panel has a border as well as a shadow, so its edge stays visible under forced colors, where shadows are removed and the scrim becomes opaque."
|
|
463
476
|
]
|
|
464
477
|
},
|
|
465
478
|
"alertDialog": {
|
|
@@ -533,7 +546,7 @@
|
|
|
533
546
|
"part": "icon",
|
|
534
547
|
"element": "your own element, with slAlertDialogIcon on it",
|
|
535
548
|
"required": false,
|
|
536
|
-
"purpose": "The mark of the tone, drawn from a glyph, so the kind of decision does not depend on
|
|
549
|
+
"purpose": "The mark of the tone, drawn from a glyph, so the kind of decision does not depend on color alone. Under forced colors it is the only signal of the tone."
|
|
537
550
|
},
|
|
538
551
|
{
|
|
539
552
|
"part": "cancel",
|
|
@@ -561,7 +574,7 @@
|
|
|
561
574
|
"type": "'sm' | 'md' | 'lg' | 'xl' | 'full'",
|
|
562
575
|
"defaultValue": "sm",
|
|
563
576
|
"appliesTo": "sl-alert-dialog",
|
|
564
|
-
"description": "The maximum width of the panel. sl-alert-dialog defaults to sm,
|
|
577
|
+
"description": "The maximum width of the panel. sl-alert-dialog defaults to sm, 32rem."
|
|
565
578
|
},
|
|
566
579
|
{
|
|
567
580
|
"name": "placement",
|
|
@@ -628,10 +641,10 @@
|
|
|
628
641
|
},
|
|
629
642
|
{
|
|
630
643
|
"name": "tone",
|
|
631
|
-
"type": "'accent' | 'secondary' | 'success' | 'warning' | 'danger'",
|
|
644
|
+
"type": "'accent' | 'secondary' | 'info' | 'success' | 'warning' | 'danger'",
|
|
632
645
|
"defaultValue": "danger",
|
|
633
646
|
"appliesTo": "sl-alert-dialog",
|
|
634
|
-
"description": "The kind of decision. It sets the mark slAlertDialogIcon draws and its
|
|
647
|
+
"description": "The kind of decision. It sets the mark slAlertDialogIcon draws and its color."
|
|
635
648
|
},
|
|
636
649
|
{
|
|
637
650
|
"name": "modal",
|
|
@@ -659,7 +672,7 @@
|
|
|
659
672
|
"type": "'panel' | 'plain'",
|
|
660
673
|
"defaultValue": "panel",
|
|
661
674
|
"appliesTo": "sl-alert-dialog",
|
|
662
|
-
"description": "Whether sl-alert-dialog paints the panel. plain removes the paint and keeps the
|
|
675
|
+
"description": "Whether sl-alert-dialog paints the panel. plain removes the paint and keeps the behavior."
|
|
663
676
|
},
|
|
664
677
|
{
|
|
665
678
|
"name": "fullScreen",
|
|
@@ -696,7 +709,14 @@
|
|
|
696
709
|
"type": "length",
|
|
697
710
|
"defaultValue": "from size",
|
|
698
711
|
"appliesTo": "the root part",
|
|
699
|
-
"description": "The maximum width of the panel, for a width the five sizes do not hold, such as a two-column form at 46rem. Set it with a style attribute on one dialog, with a rule for a region, or once in the theme. It takes precedence over size."
|
|
712
|
+
"description": "The maximum width of the panel, for a width the five sizes do not hold, such as a two-column form at 46rem. Set it with a style attribute on one dialog, with a rule for a region, or once in the theme. It takes precedence over size, and a step token takes precedence over it."
|
|
713
|
+
},
|
|
714
|
+
{
|
|
715
|
+
"name": "--slotted-dialog-measure-sm, -md, -lg, -xl",
|
|
716
|
+
"type": "length",
|
|
717
|
+
"defaultValue": "from size",
|
|
718
|
+
"appliesTo": "the root part",
|
|
719
|
+
"description": "The maximum width of one size step, read before --slotted-dialog-measure, so a theme widens one step and keeps the others."
|
|
700
720
|
},
|
|
701
721
|
{
|
|
702
722
|
"name": "container",
|
|
@@ -719,6 +739,11 @@
|
|
|
719
739
|
"payload": "DialogChangeRequest",
|
|
720
740
|
"when": "Before the dialog opens or closes, whatever caused it. The request carries the new value, the previous value, the reason (pointer, keyboard, dismiss, escape, outsidePress, back, submit or programmatic), the result of the close, the originating event, and cancel(), which keeps the dialog as it is. One handler therefore guards the ✕, Escape, a press outside, the way back and close() together."
|
|
721
741
|
},
|
|
742
|
+
{
|
|
743
|
+
"name": "(openChangeComplete)",
|
|
744
|
+
"payload": "boolean",
|
|
745
|
+
"when": "After the entrance or the exit has ended: true once the layer is settled open, false once it has left — the moment an application that renders the layer conditionally removes it, so the exit runs."
|
|
746
|
+
},
|
|
722
747
|
{
|
|
723
748
|
"name": "(openChange)",
|
|
724
749
|
"payload": "boolean",
|
|
@@ -746,11 +771,12 @@
|
|
|
746
771
|
"Focus starts on slAlertDialogCancel, the least destructive answer, as the pattern advises for a step that cannot be undone easily.",
|
|
747
772
|
"A press outside never closes an alert dialog, and it is always modal. Escape closes it, which answers with the cancel; set escape=\"none\" when cancelling is not safe either.",
|
|
748
773
|
"There is no close part: the reader answers with the cancel or the action. slDialogClose inside sl-alert-dialog throws an error.",
|
|
749
|
-
"The tone is carried by the icon’s shape as well as by its
|
|
774
|
+
"The tone is carried by the icon’s shape as well as by its color, so it survives forced colors and readers who cannot tell the colors apart."
|
|
750
775
|
]
|
|
751
776
|
}
|
|
752
777
|
},
|
|
753
778
|
"tokens": [
|
|
779
|
+
"--slotted-action-gap",
|
|
754
780
|
"--slotted-border-subtle",
|
|
755
781
|
"--slotted-border-width-thick",
|
|
756
782
|
"--slotted-border-width-thin",
|
|
@@ -760,6 +786,7 @@
|
|
|
760
786
|
"--slotted-control-radius",
|
|
761
787
|
"--slotted-control-transition-duration",
|
|
762
788
|
"--slotted-control-transition-easing",
|
|
789
|
+
"--slotted-dialog-backdrop-filter",
|
|
763
790
|
"--slotted-dialog-body-color",
|
|
764
791
|
"--slotted-dialog-border-color",
|
|
765
792
|
"--slotted-dialog-close-active-background",
|
|
@@ -767,8 +794,13 @@
|
|
|
767
794
|
"--slotted-dialog-close-hover-background",
|
|
768
795
|
"--slotted-dialog-color",
|
|
769
796
|
"--slotted-dialog-description-color",
|
|
797
|
+
"--slotted-dialog-footer-gap",
|
|
770
798
|
"--slotted-dialog-footer-surface",
|
|
771
799
|
"--slotted-dialog-measure",
|
|
800
|
+
"--slotted-dialog-measure-lg",
|
|
801
|
+
"--slotted-dialog-measure-md",
|
|
802
|
+
"--slotted-dialog-measure-sm",
|
|
803
|
+
"--slotted-dialog-measure-xl",
|
|
772
804
|
"--slotted-dialog-padding-block",
|
|
773
805
|
"--slotted-dialog-padding-block-sm",
|
|
774
806
|
"--slotted-dialog-padding-inline",
|
|
@@ -793,6 +825,7 @@
|
|
|
793
825
|
"--slotted-font-size-md",
|
|
794
826
|
"--slotted-font-size-xl",
|
|
795
827
|
"--slotted-font-weight-semibold",
|
|
828
|
+
"--slotted-form-measure",
|
|
796
829
|
"--slotted-line-height-md",
|
|
797
830
|
"--slotted-radius-lg",
|
|
798
831
|
"--slotted-radius-sm",
|
|
@@ -813,6 +846,7 @@
|
|
|
813
846
|
"--slotted-text-muted",
|
|
814
847
|
"--slotted-tone-accent-text",
|
|
815
848
|
"--slotted-tone-danger-text",
|
|
849
|
+
"--slotted-tone-info-text",
|
|
816
850
|
"--slotted-tone-secondary-subtle-active",
|
|
817
851
|
"--slotted-tone-secondary-subtle-hover",
|
|
818
852
|
"--slotted-tone-secondary-text",
|
|
@@ -840,7 +874,7 @@
|
|
|
840
874
|
{
|
|
841
875
|
"id": "placement",
|
|
842
876
|
"title": "Where the panel sits in the layer",
|
|
843
|
-
"note": "center is right for a panel whose height is settled; top is right for one that grows as the reader types, because a
|
|
877
|
+
"note": "center is right for a panel whose height is settled; top is right for one that grows as the reader types, because a centerd panel moves under the cursor every time a line is added.",
|
|
844
878
|
"language": "ts",
|
|
845
879
|
"source": "import { Component, signal } from '@angular/core';\nimport { SlButton } from '@slotted/angular/button';\nimport {\n SlDialog,\n SlDialogBody,\n SlDialogClose,\n SlDialogDescription,\n SlDialogFooter,\n SlDialogHeader,\n SlDialogTitle,\n SlDialogTrigger,\n} from '@slotted/angular/dialog';\nimport { SlField, SlFieldLabel } from '@slotted/angular/field';\nimport { SlTextarea } from '@slotted/angular/textarea';\n\n@Component({\n selector: 'app-dialog-placement',\n imports: [\n SlButton,\n SlDialog,\n SlDialogBody,\n SlDialogClose,\n SlDialogDescription,\n SlDialogFooter,\n SlDialogHeader,\n SlDialogTitle,\n SlDialogTrigger,\n SlField,\n SlFieldLabel,\n SlTextarea,\n ],\n template: `\n <button slButton tone=\"secondary\" variant=\"outline\" [slDialogTrigger]=\"dialog\">\n Add a note\n </button>\n <sl-dialog #dialog=\"slDialog\" placement=\"top\" [(open)]=\"open\">\n <header slDialogHeader>\n <h2 slDialogTitle>Note on order SO-1182</h2>\n <p slDialogDescription>The warehouse team sees the note on the pick list.</p>\n <button slDialogClose></button>\n </header>\n <div slDialogBody>\n <div slField>\n <label slFieldLabel>Note</label>\n <textarea\n slTextarea\n [rows]=\"3\"\n [maxRows]=\"12\"\n placeholder=\"Leave at the loading dock after 2 pm.\"\n ></textarea>\n </div>\n </div>\n <footer slDialogFooter>\n <button slButton variant=\"ghost\" tone=\"secondary\" (click)=\"open.set(false)\">Cancel</button>\n <button slButton (click)=\"open.set(false)\">Add note</button>\n </footer>\n </sl-dialog>\n `,\n})\nexport class DialogPlacement {\n readonly open = signal(false);\n}\n",
|
|
846
880
|
"verdict": "example"
|
|
@@ -912,7 +946,7 @@
|
|
|
912
946
|
{
|
|
913
947
|
"id": "content",
|
|
914
948
|
"title": "Content the family did not choose",
|
|
915
|
-
"note": "A ninety-character unbroken token in the title would widen a
|
|
949
|
+
"note": "A ninety-character unbroken token in the title would widen a centerd panel past both edges of the layer at once; overflow-wrap and a zero minimum are the pair that answer it. Long German and right-to-left strings are in the same scene.",
|
|
916
950
|
"language": "html",
|
|
917
951
|
"source": "<h2 slDialogTitle>deployment-pipeline-eu-west-1-production-rollback-2026-09-04T01</h2>\n",
|
|
918
952
|
"verdict": "excerpt"
|
|
@@ -933,6 +967,14 @@
|
|
|
933
967
|
"source": "<sl-dialog #d=\"slDialog\">\n <div class=\"rename\">\n <h2 slDialogTitle>Rename file</h2>\n <input slTextField aria-label=\"Name\" value=\"report-q3.pdf\" />\n <img alt=\"First page of report-q3.pdf\" [src]=\"preview\" />\n </div>\n <footer slDialogFooter><button slButton size=\"sm\">Rename</button></footer>\n</sl-dialog>\n<!-- .rename { display: grid; gap: var(--slotted-space-5);\n padding-block: var(--slotted-dialog-inset-block);\n padding-inline: var(--slotted-dialog-inset-inline); } -->\n",
|
|
934
968
|
"verdict": "excerpt"
|
|
935
969
|
},
|
|
970
|
+
{
|
|
971
|
+
"id": "form",
|
|
972
|
+
"title": "A dialog that is a form",
|
|
973
|
+
"note": "A dialog that edits a record submits with Enter from any field and with the footer’s submit. A form written around the header, the body and the footer draws no box of its own, so the parts stay the panel’s rows and keep its inset.",
|
|
974
|
+
"language": "ts",
|
|
975
|
+
"source": "import { Component, computed, signal } from '@angular/core';\nimport { SlButton } from '@slotted/angular/button';\nimport {\n SlDialog,\n SlDialogBody,\n SlDialogClose,\n SlDialogDescription,\n SlDialogFooter,\n SlDialogHeader,\n SlDialogTitle,\n SlDialogTrigger,\n} from '@slotted/angular/dialog';\nimport { SlField, SlFieldError, SlFieldLabel } from '@slotted/angular/field';\nimport { SlInline } from '@slotted/angular/inline';\nimport { SlStack } from '@slotted/angular/stack';\nimport { SlTextField, SlTextFieldInput } from '@slotted/angular/text-field';\nimport { SlText } from '@slotted/angular/typography';\n\nfunction nameError(value: string): string {\n return value.trim() === '' ? 'Enter the contact’s full name.' : '';\n}\n\nfunction emailError(value: string): string {\n if (value.trim() === '') return 'Enter the address the contact reads.';\n if (!/^\\S+@\\S+\\.\\S+$/.test(value)) return 'Enter an address like ana@contoso.com.';\n return '';\n}\n\n@Component({\n selector: 'app-dialog-form',\n imports: [\n SlButton,\n SlDialog,\n SlDialogBody,\n SlDialogClose,\n SlDialogDescription,\n SlDialogFooter,\n SlDialogHeader,\n SlDialogTitle,\n SlDialogTrigger,\n SlField,\n SlFieldError,\n SlFieldLabel,\n SlInline,\n SlStack,\n SlText,\n SlTextField,\n SlTextFieldInput,\n ],\n template: `\n <div slInline align=\"center\" [gap]=\"3\">\n <button slButton [slDialogTrigger]=\"dialog\">Add contact</button>\n <sl-dialog #dialog=\"slDialog\" [open]=\"open()\" (openChange)=\"toggle($event)\">\n <header slDialogHeader>\n <h2 slDialogTitle>New contact</h2>\n <p slDialogDescription>Contoso Foods, Seattle.</p>\n <button slDialogClose></button>\n </header>\n <div slDialogBody>\n <form id=\"new-contact\" novalidate (submit)=\"submit($event)\">\n <div slStack [gap]=\"4\">\n <div slField required [invalid]=\"errors()?.name ? true : undefined\">\n <label slFieldLabel>Full name</label>\n <div slTextField>\n <input\n slTextFieldInput\n autocomplete=\"name\"\n [value]=\"name()\"\n (valueChange)=\"name.set($event.value)\"\n />\n </div>\n <span slFieldError live=\"polite\" reserve>{{ errors()?.name }}</span>\n </div>\n <div slField required [invalid]=\"errors()?.email ? true : undefined\">\n <label slFieldLabel>Email</label>\n <div slTextField>\n <input\n slTextFieldInput\n autocomplete=\"email\"\n type=\"email\"\n [value]=\"email()\"\n (valueChange)=\"email.set($event.value)\"\n />\n </div>\n <span slFieldError live=\"polite\" reserve>{{ errors()?.email }}</span>\n </div>\n </div>\n </form>\n </div>\n <footer slDialogFooter>\n <button slButton variant=\"ghost\" tone=\"secondary\" (click)=\"open.set(false)\">\n Cancel\n </button>\n <button slButton type=\"submit\" form=\"new-contact\">Add contact</button>\n </footer>\n </sl-dialog>\n @if (added(); as message) {\n <span slText role=\"status\" size=\"sm\" tone=\"muted\">{{ message }}</span>\n }\n </div>\n `,\n})\nexport class DialogForm {\n readonly open = signal(false);\n readonly name = signal('');\n readonly email = signal('');\n readonly submitted = signal(false);\n readonly added = signal<string | null>(null);\n readonly errors = computed(() =>\n this.submitted() ? { name: nameError(this.name()), email: emailError(this.email()) } : null,\n );\n\n toggle(next: boolean): void {\n if (next) {\n this.name.set('');\n this.email.set('');\n this.submitted.set(false);\n }\n this.open.set(next);\n }\n\n submit(event: Event): void {\n event.preventDefault();\n this.submitted.set(true);\n if (nameError(this.name()) !== '' || emailError(this.email()) !== '') return;\n this.added.set(`${this.name().trim()} was added to Contoso Foods.`);\n this.open.set(false);\n }\n}\n",
|
|
976
|
+
"verdict": "example"
|
|
977
|
+
},
|
|
936
978
|
{
|
|
937
979
|
"id": "defaults",
|
|
938
980
|
"title": "Deciding once for the application",
|
|
@@ -960,7 +1002,7 @@
|
|
|
960
1002
|
{
|
|
961
1003
|
"id": "tones",
|
|
962
1004
|
"title": "What kind of decision this is",
|
|
963
|
-
"note": "Each tone carries its own mark, so the register survives a reader who cannot tell the
|
|
1005
|
+
"note": "Each tone carries its own mark, so the register survives a reader who cannot tell the colors apart and forced colors, where every tone ground becomes one system color and the silhouette is all that is left.",
|
|
964
1006
|
"language": "html",
|
|
965
1007
|
"source": "<sl-alert-dialog tone=\"warning\" [(open)]=\"open\">…</sl-alert-dialog>\n",
|
|
966
1008
|
"verdict": "excerpt"
|
|
@@ -968,7 +1010,7 @@
|
|
|
968
1010
|
{
|
|
969
1011
|
"id": "actions",
|
|
970
1012
|
"title": "Two controls, each saying what it does",
|
|
971
|
-
"note": "Labels name the action rather than answering a question — “
|
|
1013
|
+
"note": "Labels name the action rather than answering a question — “Delete project”, not “Yes”. The action closes with submit and the cancel with dismiss, so a consumer reading the reason knows which one the reader chose.",
|
|
972
1014
|
"language": "html",
|
|
973
1015
|
"source": "<footer slDialogFooter>\n <button slButton slAlertDialogCancel>Keep project</button>\n <button slButton slAlertDialogAction value=\"deleted\">Delete project</button>\n</footer>\n",
|
|
974
1016
|
"verdict": "excerpt"
|
|
@@ -1000,7 +1042,7 @@
|
|
|
1000
1042
|
{
|
|
1001
1043
|
"id": "composition",
|
|
1002
1044
|
"title": "The actions are the consumer’s own buttons",
|
|
1003
|
-
"note": "render hands each control every attribute the family wrote, so the danger button is the library’s Button with the family’s
|
|
1045
|
+
"note": "render hands each control every attribute the family wrote, so the danger button is the library’s Button with the family’s behavior on it — nothing is reimplemented and nothing is wrapped.",
|
|
1004
1046
|
"language": "html",
|
|
1005
1047
|
"source": "<button slButton tone=\"danger\" slAlertDialogAction>Delete project</button>\n",
|
|
1006
1048
|
"verdict": "excerpt"
|
|
@@ -1077,14 +1119,6 @@
|
|
|
1077
1119
|
"source": "import { Component, signal } from '@angular/core';\nimport { SlButton } from '@slotted/angular/button';\nimport {\n SlDialog,\n SlDialogBody,\n SlDialogDescription,\n SlDialogFooter,\n SlDialogHeader,\n SlDialogTitle,\n SlDialogTrigger,\n} from '@slotted/angular/dialog';\nimport { SlText } from '@slotted/angular/typography';\n\n@Component({\n selector: 'app-dialog-dismiss',\n imports: [\n SlButton,\n SlDialog,\n SlDialogBody,\n SlDialogDescription,\n SlDialogFooter,\n SlDialogHeader,\n SlDialogTitle,\n SlDialogTrigger,\n SlText,\n ],\n template: `\n <button slButton [slDialogTrigger]=\"dialog\">Import products</button>\n <sl-dialog #dialog=\"slDialog\" escape=\"none\" outsidePress=\"none\" [(open)]=\"open\">\n <header slDialogHeader>\n <h2 slDialogTitle>Import 1,240 products</h2>\n <p slDialogDescription>From spring-catalogue.csv into the Northwind price list.</p>\n </header>\n <div slDialogBody>\n <span slText size=\"sm\">\n 38 rows update existing products and 1,202 add new ones. Escape and a press outside the\n panel leave this dialog open; choose one of the actions.\n </span>\n </div>\n <footer slDialogFooter>\n <button slButton variant=\"ghost\" tone=\"secondary\" (click)=\"open.set(false)\">\n Cancel import\n </button>\n <button slButton (click)=\"open.set(false)\">Start import</button>\n </footer>\n </sl-dialog>\n `,\n})\nexport class DialogDismiss {\n readonly open = signal(false);\n}\n",
|
|
1078
1120
|
"verdict": "example"
|
|
1079
1121
|
},
|
|
1080
|
-
{
|
|
1081
|
-
"id": "form",
|
|
1082
|
-
"title": "form.ts",
|
|
1083
|
-
"note": null,
|
|
1084
|
-
"language": "ts",
|
|
1085
|
-
"source": "import { Component, computed, signal } from '@angular/core';\nimport { SlButton } from '@slotted/angular/button';\nimport {\n SlDialog,\n SlDialogBody,\n SlDialogClose,\n SlDialogDescription,\n SlDialogFooter,\n SlDialogHeader,\n SlDialogTitle,\n SlDialogTrigger,\n} from '@slotted/angular/dialog';\nimport { SlField, SlFieldError, SlFieldLabel } from '@slotted/angular/field';\nimport { SlInline } from '@slotted/angular/inline';\nimport { SlStack } from '@slotted/angular/stack';\nimport { SlTextField, SlTextFieldInput } from '@slotted/angular/text-field';\nimport { SlText } from '@slotted/angular/typography';\n\nfunction nameError(value: string): string {\n return value.trim() === '' ? 'Enter the contact’s full name.' : '';\n}\n\nfunction emailError(value: string): string {\n if (value.trim() === '') return 'Enter the address the contact reads.';\n if (!/^\\S+@\\S+\\.\\S+$/.test(value)) return 'Enter an address like ana@contoso.com.';\n return '';\n}\n\n@Component({\n selector: 'app-dialog-form',\n imports: [\n SlButton,\n SlDialog,\n SlDialogBody,\n SlDialogClose,\n SlDialogDescription,\n SlDialogFooter,\n SlDialogHeader,\n SlDialogTitle,\n SlDialogTrigger,\n SlField,\n SlFieldError,\n SlFieldLabel,\n SlInline,\n SlStack,\n SlText,\n SlTextField,\n SlTextFieldInput,\n ],\n template: `\n <div slInline align=\"center\" [gap]=\"3\">\n <button slButton [slDialogTrigger]=\"dialog\">Add contact</button>\n <sl-dialog #dialog=\"slDialog\" [open]=\"open()\" (openChange)=\"toggle($event)\">\n <header slDialogHeader>\n <h2 slDialogTitle>New contact</h2>\n <p slDialogDescription>Contoso Foods, Seattle.</p>\n <button slDialogClose></button>\n </header>\n <div slDialogBody>\n <form id=\"new-contact\" novalidate (submit)=\"submit($event)\">\n <div slStack [gap]=\"4\">\n <div slField required [invalid]=\"errors()?.name ? true : undefined\">\n <label slFieldLabel>Full name</label>\n <div slTextField>\n <input\n slTextFieldInput\n autocomplete=\"name\"\n [value]=\"name()\"\n (valueChange)=\"name.set($event.value)\"\n />\n </div>\n <span slFieldError live=\"polite\" reserve>{{ errors()?.name }}</span>\n </div>\n <div slField required [invalid]=\"errors()?.email ? true : undefined\">\n <label slFieldLabel>Email</label>\n <div slTextField>\n <input\n slTextFieldInput\n autocomplete=\"email\"\n type=\"email\"\n [value]=\"email()\"\n (valueChange)=\"email.set($event.value)\"\n />\n </div>\n <span slFieldError live=\"polite\" reserve>{{ errors()?.email }}</span>\n </div>\n </div>\n </form>\n </div>\n <footer slDialogFooter>\n <button slButton variant=\"ghost\" tone=\"secondary\" (click)=\"open.set(false)\">\n Cancel\n </button>\n <button slButton type=\"submit\" form=\"new-contact\">Add contact</button>\n </footer>\n </sl-dialog>\n @if (added(); as message) {\n <span slText role=\"status\" size=\"sm\" tone=\"muted\">{{ message }}</span>\n }\n </div>\n `,\n})\nexport class DialogForm {\n readonly open = signal(false);\n readonly name = signal('');\n readonly email = signal('');\n readonly submitted = signal(false);\n readonly added = signal<string | null>(null);\n readonly errors = computed(() =>\n this.submitted() ? { name: nameError(this.name()), email: emailError(this.email()) } : null,\n );\n\n toggle(next: boolean): void {\n if (next) {\n this.name.set('');\n this.email.set('');\n this.submitted.set(false);\n }\n this.open.set(next);\n }\n\n submit(event: Event): void {\n event.preventDefault();\n this.submitted.set(true);\n if (nameError(this.name()) !== '' || emailError(this.email()) !== '') return;\n this.added.set(`${this.name().trim()} was added to Contoso Foods.`);\n this.open.set(false);\n }\n}\n",
|
|
1086
|
-
"verdict": "example"
|
|
1087
|
-
},
|
|
1088
1122
|
{
|
|
1089
1123
|
"id": "full-screen",
|
|
1090
1124
|
"title": "full-screen.ts",
|