@slotted/react 0.1.0-beta.42 → 0.1.0-beta.44
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/action-sheet-q1UXXruJ.js +360 -0
- package/dist/action-sheet.js +1 -1
- package/dist/{app-shell-D54YkU7E.js → app-shell-BBPY0_KK.js} +217 -195
- package/dist/app-shell.js +1 -1
- package/dist/attachment-DJDXJrCx.js +300 -0
- package/dist/attachment.js +2 -2
- package/dist/{avatar-group-bJaZE1_C.js → avatar-group-Bzmmj2HI.js} +2 -1
- package/dist/avatar-group.js +1 -1
- package/dist/{button-BMRInd-t.js → button-DS_HpPy0.js} +1 -1
- package/dist/button.js +2 -2
- package/dist/{calendar-YQ784o4d.js → calendar-BO5teotM.js} +1 -1
- package/dist/calendar.js +1 -1
- package/dist/{carousel-B9nMK7Yf.js → carousel-CRNz-T3g.js} +1 -1
- package/dist/carousel.js +1 -1
- package/dist/{cascader-fq8fNWSr.js → cascader-BbhADVGt.js} +134 -131
- package/dist/cascader.js +1 -1
- package/dist/{chart-vedR0BDN.js → chart-C4uPgUW8.js} +2 -2
- package/dist/chart.js +1 -1
- package/dist/{checkbox-DsJhlB5c.js → checkbox-D8HZG0be.js} +3 -3
- package/dist/{checkbox-group-pvX9R_yS.js → checkbox-group-5zuE2Kd1.js} +2 -2
- package/dist/checkbox-group.js +1 -1
- package/dist/checkbox.js +1 -1
- package/dist/{clock-DzkQa57Q.js → clock-DeJgwYbZ.js} +1 -1
- package/dist/clock.js +1 -1
- package/dist/{code-block-Cy548yk7.js → code-block-H0lmVVnY.js} +1 -1
- package/dist/code-block.js +1 -1
- package/dist/{color-picker-i-MJ5VVs.js → color-picker-fiLSUBjj.js} +23 -18
- package/dist/color-picker.js +1 -1
- package/dist/{column-manager-D028QbfO.js → column-manager-Cc72e1j-.js} +143 -143
- package/dist/column-manager.js +1 -1
- package/dist/{combobox-599heRN_.js → combobox-DMtXrMYE.js} +1 -1
- package/dist/combobox.js +1 -1
- package/dist/{command-palette-C90CzfQi.js → command-palette-DwjkexvN.js} +174 -162
- package/dist/command-palette.js +1 -1
- package/dist/{context-menu-WM_tT9hz.js → context-menu-CRRp-PhP.js} +12 -6
- package/dist/context-menu.js +1 -1
- package/dist/{currency-field-rS36pjCO.js → currency-field-Cxr8MT75.js} +1 -1
- package/dist/currency-field.js +1 -1
- package/dist/{dashboard-grid-Dh2Q3IQv.js → dashboard-grid-_3H4G0dP.js} +339 -333
- package/dist/dashboard-grid.js +1 -1
- package/dist/{data-grid-D106baPp.js → data-grid-BlElqHOU.js} +19 -19
- package/dist/data-grid.js +1 -1
- package/dist/{data-list-BA0xrySM.js → data-list-5zvM-DUz.js} +19 -18
- package/dist/data-list.js +1 -1
- package/dist/{date-field-BZ5JcvXJ.js → date-field-CjlOWVRA.js} +1 -1
- package/dist/date-field.js +1 -1
- package/dist/{date-picker-BvEbsbJC.js → date-picker-BoIHK8_U.js} +4 -4
- package/dist/date-picker.js +2 -2
- package/dist/{date-range-picker-uIr-yReE.js → date-range-picker-DzuuvudX.js} +5 -5
- package/dist/date-range-picker.js +1 -1
- package/dist/{datetime-field-DDs3mV9Z.js → datetime-field-PSEOgzfN.js} +1 -1
- package/dist/datetime-field.js +1 -1
- package/dist/{datetime-picker-DDYXqrjm.js → datetime-picker-BUhSr8yp.js} +7 -7
- package/dist/datetime-picker.js +1 -1
- package/dist/{datetime-range-picker-CFTHW771.js → datetime-range-picker-DXllehEN.js} +7 -7
- package/dist/datetime-range-picker.js +1 -1
- package/dist/{description-list-D8iTzgC0.js → description-list-1USVlDj3.js} +5 -1
- package/dist/description-list.js +1 -1
- package/dist/detail-panel-Czs05E_D.js +344 -0
- package/dist/detail-panel.js +2 -2
- package/dist/docs/action-bar.examples.md +768 -0
- package/dist/docs/action-bar.json +74 -50
- package/dist/docs/action-bar.md +49 -311
- package/dist/docs/action-sheet.examples.md +1 -1
- package/dist/docs/action-sheet.json +3 -3
- package/dist/docs/action-sheet.md +2 -2
- package/dist/docs/app-shell.examples.md +1273 -64
- package/dist/docs/app-shell.json +93 -60
- package/dist/docs/app-shell.md +98 -58
- package/dist/docs/attachment.examples.md +689 -0
- package/dist/docs/attachment.json +69 -37
- package/dist/docs/attachment.md +44 -203
- package/dist/docs/avatar-group.examples.md +790 -0
- package/dist/docs/avatar-group.json +111 -23
- package/dist/docs/avatar-group.md +46 -86
- package/dist/docs/avatar.json +6 -6
- package/dist/docs/avatar.md +43 -10
- package/dist/docs/badge.json +1 -1
- package/dist/docs/badge.md +15 -3
- package/dist/docs/button-group.json +98 -2
- package/dist/docs/button-group.md +411 -8
- package/dist/docs/button.json +2 -0
- package/dist/docs/button.md +1 -1
- package/dist/docs/calendar.examples.md +512 -0
- package/dist/docs/calendar.json +72 -25
- package/dist/docs/calendar.md +19 -148
- package/dist/docs/carousel.examples.md +868 -0
- package/dist/docs/carousel.json +60 -50
- package/dist/docs/carousel.md +67 -301
- package/dist/docs/cascader.examples.md +1269 -0
- package/dist/docs/cascader.json +72 -16
- package/dist/docs/cascader.md +78 -154
- package/dist/docs/chart.examples.md +734 -24
- package/dist/docs/chart.json +93 -13
- package/dist/docs/chart.md +28 -7
- package/dist/docs/clock.json +75 -19
- package/dist/docs/clock.md +328 -23
- package/dist/docs/code-block.json +79 -55
- package/dist/docs/code-block.md +417 -74
- package/dist/docs/collapsible.json +10 -1
- package/dist/docs/collapsible.md +1 -1
- package/dist/docs/color-picker.json +74 -13
- package/dist/docs/color-picker.md +247 -23
- package/dist/docs/column-manager.examples.md +764 -0
- package/dist/docs/column-manager.json +68 -12
- package/dist/docs/column-manager.md +44 -203
- package/dist/docs/command-palette.examples.md +747 -0
- package/dist/docs/command-palette.json +48 -24
- package/dist/docs/command-palette.md +60 -339
- package/dist/docs/currency-field.examples.md +355 -73
- package/dist/docs/currency-field.json +96 -64
- package/dist/docs/currency-field.md +57 -50
- package/dist/docs/dashboard-grid.examples.md +629 -0
- package/dist/docs/dashboard-grid.json +64 -16
- package/dist/docs/dashboard-grid.md +34 -152
- package/dist/docs/data-list.examples.md +1556 -0
- package/dist/docs/data-list.json +58 -18
- package/dist/docs/data-list.md +139 -224
- package/dist/docs/date-field.examples.md +543 -0
- package/dist/docs/date-field.json +64 -24
- package/dist/docs/date-field.md +22 -168
- package/dist/docs/datetime-field.examples.md +699 -0
- package/dist/docs/datetime-field.json +79 -31
- package/dist/docs/datetime-field.md +24 -269
- package/dist/docs/datetime-range-picker.examples.md +682 -0
- package/dist/docs/datetime-range-picker.json +117 -61
- package/dist/docs/datetime-range-picker.md +59 -224
- package/dist/docs/description-list.examples.md +652 -0
- package/dist/docs/description-list.json +56 -25
- package/dist/docs/description-list.md +34 -188
- package/dist/docs/detail-panel.examples.md +1177 -0
- package/dist/docs/detail-panel.json +69 -53
- package/dist/docs/detail-panel.md +114 -324
- package/dist/docs/drawer.examples.md +1 -1
- package/dist/docs/drawer.json +4 -4
- package/dist/docs/entity-picker.examples.md +1160 -0
- package/dist/docs/entity-picker.json +66 -18
- package/dist/docs/entity-picker.md +72 -247
- package/dist/docs/event-calendar.examples.md +749 -49
- package/dist/docs/event-calendar.json +53 -22
- package/dist/docs/event-calendar.md +82 -11
- package/dist/docs/field-group.examples.md +554 -0
- package/dist/docs/field-group.json +98 -34
- package/dist/docs/field-group.md +55 -133
- package/dist/docs/filter-bar.examples.md +772 -0
- package/dist/docs/filter-bar.json +42 -25
- package/dist/docs/filter-bar.md +43 -247
- package/dist/docs/floating-panel.json +7 -3
- package/dist/docs/floating-panel.md +23 -5
- package/dist/docs/form.examples.md +579 -0
- package/dist/docs/form.json +87 -39
- package/dist/docs/form.md +53 -177
- package/dist/docs/fullscreen.examples.md +558 -0
- package/dist/docs/fullscreen.json +58 -18
- package/dist/docs/fullscreen.md +50 -169
- package/dist/docs/highlight.json +57 -25
- package/dist/docs/highlight.md +402 -50
- package/dist/docs/hover-card.json +8 -1
- package/dist/docs/hover-card.md +5 -1
- package/dist/docs/icon.json +85 -5
- package/dist/docs/icon.md +401 -10
- package/dist/docs/image.examples.md +670 -0
- package/dist/docs/image.json +44 -28
- package/dist/docs/image.md +24 -176
- package/dist/docs/import-export-center.examples.md +1280 -0
- package/dist/docs/import-export-center.json +69 -39
- package/dist/docs/import-export-center.md +123 -229
- package/dist/docs/inline-message.json +8 -8
- package/dist/docs/inline-message.md +37 -31
- package/dist/docs/inline.json +1 -1
- package/dist/docs/inline.md +4 -1
- package/dist/docs/list-item.examples.md +769 -0
- package/dist/docs/list-item.json +113 -38
- package/dist/docs/list-item.md +85 -202
- package/dist/docs/listbox.examples.md +858 -0
- package/dist/docs/listbox.json +76 -28
- package/dist/docs/listbox.md +41 -263
- package/dist/docs/markdown.json +79 -55
- package/dist/docs/markdown.md +585 -85
- package/dist/docs/media-viewer.examples.md +1038 -0
- package/dist/docs/media-viewer.json +70 -15
- package/dist/docs/media-viewer.md +84 -135
- package/dist/docs/menu.examples.md +14 -2
- package/dist/docs/menu.json +1 -1
- package/dist/docs/message-scroller.examples.md +1359 -0
- package/dist/docs/message-scroller.json +41 -17
- package/dist/docs/message-scroller.md +93 -134
- package/dist/docs/message.examples.md +954 -0
- package/dist/docs/message.json +68 -18
- package/dist/docs/message.md +39 -327
- package/dist/docs/meter.json +58 -26
- package/dist/docs/meter.md +312 -32
- package/dist/docs/navigation-menu.examples.md +1116 -0
- package/dist/docs/navigation-menu.json +57 -41
- package/dist/docs/navigation-menu.md +105 -298
- package/dist/docs/notification-center.examples.md +1045 -0
- package/dist/docs/notification-center.json +71 -15
- package/dist/docs/notification-center.md +76 -266
- package/dist/docs/otp-input.examples.md +490 -0
- package/dist/docs/otp-input.json +65 -25
- package/dist/docs/otp-input.md +20 -191
- package/dist/docs/page-header.examples.md +1062 -0
- package/dist/docs/page-header.json +83 -43
- package/dist/docs/page-header.md +80 -292
- package/dist/docs/page.examples.md +651 -0
- package/dist/docs/page.json +48 -16
- package/dist/docs/page.md +62 -129
- package/dist/docs/popover.json +17 -2
- package/dist/docs/popover.md +2 -0
- package/dist/docs/progress-indicator.json +10 -1
- package/dist/docs/progress-indicator.md +2 -1
- package/dist/docs/prompt-composer.examples.md +630 -0
- package/dist/docs/prompt-composer.json +66 -18
- package/dist/docs/prompt-composer.md +35 -161
- package/dist/docs/prose.json +69 -37
- package/dist/docs/prose.md +393 -75
- package/dist/docs/rating.examples.md +525 -0
- package/dist/docs/rating.json +92 -28
- package/dist/docs/rating.md +27 -241
- package/dist/docs/saved-views.examples.md +1097 -0
- package/dist/docs/saved-views.json +53 -21
- package/dist/docs/saved-views.md +85 -171
- package/dist/docs/scroll-area.examples.md +837 -0
- package/dist/docs/scroll-area.json +64 -24
- package/dist/docs/scroll-area.md +57 -140
- package/dist/docs/section.examples.md +679 -0
- package/dist/docs/section.json +68 -20
- package/dist/docs/section.md +39 -162
- package/dist/docs/segmented-control.examples.md +480 -0
- package/dist/docs/segmented-control.json +78 -28
- package/dist/docs/segmented-control.md +21 -192
- package/dist/docs/side-navigation.examples.md +1473 -0
- package/dist/docs/side-navigation.json +53 -53
- package/dist/docs/side-navigation.md +79 -354
- package/dist/docs/skeleton.json +2 -2
- package/dist/docs/skeleton.md +2 -2
- package/dist/docs/slider.examples.md +505 -0
- package/dist/docs/slider.json +91 -51
- package/dist/docs/slider.md +47 -212
- package/dist/docs/sparkline.json +60 -36
- package/dist/docs/sparkline.md +447 -71
- package/dist/docs/split-button.examples.md +509 -0
- package/dist/docs/split-button.json +73 -41
- package/dist/docs/split-button.md +64 -194
- package/dist/docs/splitter.examples.md +921 -0
- package/dist/docs/splitter.json +94 -46
- package/dist/docs/splitter.md +75 -182
- package/dist/docs/stat-card.examples.md +725 -0
- package/dist/docs/stat-card.json +89 -41
- package/dist/docs/stat-card.md +55 -227
- package/dist/docs/status-indicator.json +80 -33
- package/dist/docs/status-indicator.md +410 -66
- package/dist/docs/stepper.json +53 -21
- package/dist/docs/stepper.md +363 -48
- package/dist/docs/table-of-contents.examples.md +550 -0
- package/dist/docs/table-of-contents.json +60 -28
- package/dist/docs/table-of-contents.md +70 -205
- package/dist/docs/table.json +2 -1
- package/dist/docs/table.md +2 -2
- package/dist/docs/tabs.examples.md +6 -4
- package/dist/docs/tabs.json +7 -5
- package/dist/docs/tabs.md +2 -2
- package/dist/docs/tags-input.examples.md +541 -0
- package/dist/docs/tags-input.json +64 -16
- package/dist/docs/tags-input.md +15 -262
- package/dist/docs/time-field.examples.md +587 -0
- package/dist/docs/time-field.json +69 -29
- package/dist/docs/time-field.md +21 -223
- package/dist/docs/time-picker.json +117 -53
- package/dist/docs/time-picker.md +499 -54
- package/dist/docs/time-range-picker.examples.md +750 -0
- package/dist/docs/time-range-picker.json +139 -75
- package/dist/docs/time-range-picker.md +63 -225
- package/dist/docs/timeline.examples.md +622 -0
- package/dist/docs/timeline.json +44 -28
- package/dist/docs/timeline.md +34 -208
- package/dist/docs/toggle-group.json +2 -0
- package/dist/docs/toggle-group.md +1 -1
- package/dist/docs/toggle.json +2 -0
- package/dist/docs/toggle.md +1 -1
- package/dist/docs/tokens.md +8 -0
- package/dist/docs/toolbar.examples.md +529 -0
- package/dist/docs/toolbar.json +58 -18
- package/dist/docs/toolbar.md +36 -171
- package/dist/docs/tooltip.examples.md +46 -0
- package/dist/docs/tooltip.json +23 -0
- package/dist/docs/tooltip.md +2 -0
- package/dist/docs/top-navigation.examples.md +1308 -140
- package/dist/docs/top-navigation.json +49 -33
- package/dist/docs/top-navigation.md +92 -36
- package/dist/docs/tour.examples.md +960 -0
- package/dist/docs/tour.json +57 -25
- package/dist/docs/tour.md +60 -244
- package/dist/docs/transfer.examples.md +631 -0
- package/dist/docs/transfer.json +80 -16
- package/dist/docs/transfer.md +41 -170
- package/dist/docs/tree.examples.md +5 -2
- package/dist/docs/tree.json +2 -2
- package/dist/docs/typography.json +96 -0
- package/dist/docs/typography.md +365 -4
- package/dist/docs/upload.examples.md +555 -53
- package/dist/docs/upload.json +62 -30
- package/dist/docs/upload.md +46 -11
- package/dist/docs/visually-hidden.json +3 -3
- package/dist/docs/visually-hidden.md +68 -41
- package/dist/docs/wizard.examples.md +1389 -0
- package/dist/docs/wizard.json +90 -49
- package/dist/docs/wizard.md +123 -264
- package/dist/drawer-JP3p-QZB.js +879 -0
- package/dist/drawer.js +1 -1
- package/dist/{entity-picker-CC4VoC3p.js → entity-picker-BWpuo-mp.js} +341 -334
- package/dist/entity-picker.js +1 -1
- package/dist/{event-calendar-CjmF_e0H.js → event-calendar-Bxx8eoGK.js} +10 -6
- package/dist/event-calendar.js +1 -1
- package/dist/{field-C-HRhke0.js → field-N0TiMbaI.js} +2 -2
- package/dist/{field-group-CU0PasvW.js → field-group-BrnE6FvP.js} +1 -1
- package/dist/field-group.js +1 -1
- package/dist/field.js +1 -1
- package/dist/{filter-bar-B3QJD7SZ.js → filter-bar-nQH58RVl.js} +361 -347
- package/dist/filter-bar.js +1 -1
- package/dist/{hover-card-CTItbEfH.js → hover-card-D9-rb9ts.js} +67 -63
- package/dist/hover-card.js +1 -1
- package/dist/{icon-button-N8Madx6i.js → icon-button-DzPkQamc.js} +0 -1
- package/dist/import-export-center-BpGga5jr.js +869 -0
- package/dist/import-export-center.js +1 -1
- package/dist/index.js +105 -105
- package/dist/{listbox-ZqiJ2yer.js → listbox-3XVusnCr.js} +1 -1
- package/dist/listbox.js +1 -1
- package/dist/{loading-overlay-BxIktMtQ.js → loading-overlay-BzycGqQA.js} +1 -1
- package/dist/loading-overlay.js +1 -1
- package/dist/{markdown-BdskE4-L.js → markdown-BMda5ino.js} +15 -15
- package/dist/markdown.js +1 -1
- package/dist/{media-viewer-zEXcwfEY.js → media-viewer-C_cbuAq-.js} +64 -60
- package/dist/media-viewer.js +2 -2
- package/dist/message-P91bEGyV.js +455 -0
- package/dist/message.js +2 -2
- package/dist/{multi-select-Dc2d6dDB.js → multi-select-IpsZvoQ2.js} +1 -1
- package/dist/multi-select.js +1 -1
- package/dist/{navigation-menu-parts-CRLmigjy.js → navigation-menu-parts-D-vsDdEF.js} +5 -1
- package/dist/navigation-menu.js +1 -1
- package/dist/{notification-center-BngAw_kt.js → notification-center-CTSfrh9K.js} +3 -3
- package/dist/notification-center.js +1 -1
- package/dist/{number-field-BQ54hXmk.js → number-field-Cp33JMGB.js} +1 -1
- package/dist/number-field.js +1 -1
- package/dist/{otp-input-DRooqa3f.js → otp-input-CEP60HOi.js} +1 -1
- package/dist/otp-input.js +1 -1
- package/dist/{page-header-DmwBGwlm.js → page-header-DK896DGD.js} +105 -110
- package/dist/page-header.js +1 -1
- package/dist/{picker-frame-B6sPCP5Y.js → picker-frame-C3Fhjfaj.js} +1 -1
- package/dist/popover-DED1MTi-.js +615 -0
- package/dist/popover.js +1 -1
- package/dist/{progress-indicator-DRr0Gj6w.js → progress-indicator-Co8e7M5K.js} +6 -3
- package/dist/progress-indicator.js +1 -1
- package/dist/{prompt-composer-tYIs39rn.js → prompt-composer-CwjvdgBR.js} +1 -1
- package/dist/prompt-composer.js +1 -1
- package/dist/{radio-group-AW3xcYYh.js → radio-group-D6bOV_ea.js} +2 -2
- package/dist/radio-group.js +1 -1
- package/dist/{rating-h3qdHLNi.js → rating-D8BvDdjM.js} +1 -1
- package/dist/rating.js +1 -1
- package/dist/{saved-views-nqn0SDXn.js → saved-views-D-CP7JIE.js} +8 -5
- package/dist/saved-views.js +1 -1
- package/dist/section-CVTQdWBl.js +216 -0
- package/dist/section.js +2 -2
- package/dist/{segmented-control-CbK7SurB.js → segmented-control-BLcGhQ4J.js} +3 -3
- package/dist/segmented-control.js +1 -1
- package/dist/{select-d448Wkzb.js → select-Dbc3ng0M.js} +2 -2
- package/dist/{select-tags-3792weoq.js → select-tags-D0SMDPBX.js} +25 -24
- package/dist/select.js +1 -1
- package/dist/{side-navigation-CKRETc8E.js → side-navigation-Dw3-P12f.js} +181 -181
- package/dist/side-navigation.js +1 -1
- package/dist/{skeleton-DeEOmm1y.js → skeleton-DTqt2GEv.js} +27 -20
- package/dist/skeleton.js +1 -1
- package/dist/{slider-DQ2CnxTO.js → slider-COLWTaxi.js} +1 -1
- package/dist/slider.js +1 -1
- package/dist/{split-button-D4MPKSB2.js → split-button-Czr2D3HP.js} +1 -1
- package/dist/split-button.js +1 -1
- package/dist/{stat-card-CL3Xe6pV.js → stat-card-D6NMjkZM.js} +13 -15
- package/dist/stat-card.js +1 -1
- package/dist/{stepper-DHdrANZI.js → stepper-Cxb_tHnA.js} +130 -127
- package/dist/stepper.js +2 -2
- package/dist/styles/accordion.css +1 -1
- package/dist/styles/action-bar.css +2 -2
- package/dist/styles/action-sheet.css +5 -3
- package/dist/styles/app-shell.css +3 -3
- package/dist/styles/attachment.css +3 -3
- package/dist/styles/avatar-group.css +1 -1
- package/dist/styles/badge.css +1 -1
- package/dist/styles/breadcrumb.css +1 -1
- package/dist/styles/button.css +2 -2
- package/dist/styles/calendar.css +1 -1
- package/dist/styles/card.css +1 -1
- package/dist/styles/carousel.css +1 -1
- package/dist/styles/cascader.css +7 -7
- package/dist/styles/chart.css +6 -4
- package/dist/styles/checkbox-group.css +6 -2
- package/dist/styles/checkbox.css +7 -3
- package/dist/styles/clock.css +1 -1
- package/dist/styles/code-block.css +2 -2
- package/dist/styles/collapsible.css +2 -2
- package/dist/styles/color-picker.css +9 -5
- package/dist/styles/column-manager.css +9 -9
- package/dist/styles/combobox.css +7 -3
- package/dist/styles/command-palette.css +5 -5
- package/dist/styles/context-menu.css +1 -1
- package/dist/styles/currency-field.css +7 -3
- package/dist/styles/dashboard-grid.css +6 -6
- package/dist/styles/data-grid.css +19 -19
- package/dist/styles/data-list.css +9 -9
- package/dist/styles/date-field.css +7 -3
- package/dist/styles/date-picker.css +8 -4
- package/dist/styles/date-range-picker.css +8 -4
- package/dist/styles/datetime-field.css +7 -3
- package/dist/styles/datetime-picker.css +10 -6
- package/dist/styles/datetime-range-picker.css +9 -5
- package/dist/styles/description-list.css +1 -1
- package/dist/styles/detail-panel.css +7 -7
- package/dist/styles/dialog.css +1 -1
- package/dist/styles/divider.css +1 -1
- package/dist/styles/drawer.css +5 -1
- package/dist/styles/entity-picker.css +10 -8
- package/dist/styles/event-calendar.css +12 -8
- package/dist/styles/field-group.css +6 -2
- package/dist/styles/field.css +6 -2
- package/dist/styles/filter-bar.css +20 -20
- package/dist/styles/floating-panel.css +1 -1
- package/dist/styles/hover-card.css +5 -1
- package/dist/styles/import-export-center.css +24 -24
- package/dist/styles/index.css +87 -85
- package/dist/styles/inline.css +1 -1
- package/dist/styles/kbd.css +1 -1
- package/dist/styles/list-item.css +1 -1
- package/dist/styles/listbox.css +7 -3
- package/dist/styles/loading-overlay.css +3 -3
- package/dist/styles/markdown.css +8 -8
- package/dist/styles/media-viewer.css +2 -2
- package/dist/styles/menu.css +1 -1
- package/dist/styles/menubar.css +2 -2
- package/dist/styles/message-scroller.css +1 -1
- package/dist/styles/message.css +1 -1
- package/dist/styles/multi-select.css +9 -7
- package/dist/styles/navigation-menu.css +1 -1
- package/dist/styles/notification-center.css +5 -5
- package/dist/styles/number-field.css +7 -3
- package/dist/styles/otp-input.css +7 -3
- package/dist/styles/page-header.css +4 -4
- package/dist/styles/pagination.css +1 -1
- package/dist/styles/popover.css +5 -1
- package/dist/styles/progress-indicator.css +2 -2
- package/dist/styles/prompt-composer.css +6 -4
- package/dist/styles/radio-group.css +7 -3
- package/dist/styles/rating.css +7 -3
- package/dist/styles/saved-views.css +8 -6
- package/dist/styles/section.css +1 -1
- package/dist/styles/segmented-control.css +7 -3
- package/dist/styles/select.css +8 -4
- package/dist/styles/side-navigation.css +4 -4
- package/dist/styles/skeleton.css +1 -1
- package/dist/styles/slider.css +6 -2
- package/dist/styles/split-button.css +3 -3
- package/dist/styles/stat-card.css +1 -1
- package/dist/styles/status-indicator.css +1 -1
- package/dist/styles/stepper.css +1 -1
- package/dist/styles/switch.css +6 -6
- package/dist/styles/table-of-contents.css +1 -1
- package/dist/styles/table.css +18 -18
- package/dist/styles/tabs.css +1 -1
- package/dist/styles/tag.css +1 -1
- package/dist/styles/tags-input.css +8 -4
- package/dist/styles/text-field.css +7 -3
- package/dist/styles/textarea.css +7 -3
- package/dist/styles/time-field.css +7 -3
- package/dist/styles/time-picker.css +8 -4
- package/dist/styles/time-range-picker.css +8 -4
- package/dist/styles/timeline.css +2 -2
- package/dist/styles/toast.css +3 -3
- package/dist/styles/toggle-group.css +7 -3
- package/dist/styles/toggle.css +1 -1
- package/dist/styles/toolbar.css +2 -2
- package/dist/styles/top-navigation.css +5 -5
- package/dist/styles/tour.css +3 -3
- package/dist/styles/transfer.css +9 -9
- package/dist/styles/tree.css +1 -1
- package/dist/styles/upload.css +10 -6
- package/dist/styles/wizard.css +8 -8
- package/dist/styles.css +1 -1
- package/dist/{switch-DxMukg7F.js → switch-CEbZkLlX.js} +2 -2
- package/dist/switch.js +1 -1
- package/dist/{table-BecApjeD.js → table-BU7XsbQX.js} +169 -162
- package/dist/{table-of-contents-kFr_3Dzs.js → table-of-contents-C410GoEC.js} +1 -1
- package/dist/table-of-contents.js +1 -1
- package/dist/table.js +1 -1
- package/dist/{tags-input-CqCeLtk-.js → tags-input-BdjkB19P.js} +260 -257
- package/dist/tags-input.js +1 -1
- package/dist/{text-field-CMOkJ9Z6.js → text-field-QJnu-rln.js} +1 -1
- package/dist/text-field.js +1 -1
- package/dist/{textarea-DfqPfXTr.js → textarea-DsrXI3xB.js} +1 -1
- package/dist/textarea.js +1 -1
- package/dist/{time-field-GyLQsxcc.js → time-field-DlZdMsNw.js} +1 -1
- package/dist/time-field.js +1 -1
- package/dist/{time-picker-CGHPnust.js → time-picker-WmeCIySv.js} +5 -5
- package/dist/time-picker.js +1 -1
- package/dist/{time-range-picker-BMRtAqPy.js → time-range-picker-CwSbsJPt.js} +6 -6
- package/dist/time-range-picker.js +1 -1
- package/dist/{timeline-BiL2CXfn.js → timeline-ZngK6zLC.js} +9 -6
- package/dist/timeline.js +1 -1
- package/dist/{toast-aM_ga1mc.js → toast-C3xLEFDE.js} +1 -1
- package/dist/toast.js +1 -1
- package/dist/{toggle-group-DZEWkVRo.js → toggle-group-SP_W-yeh.js} +1 -1
- package/dist/toggle-group.js +1 -1
- package/dist/toolbar-BniP4i1C.js +249 -0
- package/dist/toolbar.js +1 -1
- package/dist/tooltip-UPICnTij.js +418 -0
- package/dist/tooltip.js +1 -1
- package/dist/top-navigation--OcOpGCy.js +744 -0
- package/dist/top-navigation.js +2 -2
- package/dist/{tour-ALH5CYMY.js → tour-7-TXdrMv.js} +2 -2
- package/dist/tour.js +1 -1
- package/dist/{transfer-sKUvmEKe.js → transfer-DX6umI2M.js} +6 -6
- package/dist/transfer.js +1 -1
- package/dist/types/action-sheet/action-sheet-parts.d.ts.map +1 -1
- package/dist/types/app-shell/app-shell.d.ts.map +1 -1
- package/dist/types/attachment/attachment-parts.d.ts +24 -11
- package/dist/types/attachment/attachment-parts.d.ts.map +1 -1
- package/dist/types/attachment/attachment.d.ts +3 -3
- package/dist/types/attachment/attachment.d.ts.map +1 -1
- package/dist/types/avatar-group/avatar-group.d.ts.map +1 -1
- package/dist/types/carousel/carousel-parts.d.ts +2 -2
- package/dist/types/cascader/cascader-surface.d.ts +6 -1
- package/dist/types/cascader/cascader-surface.d.ts.map +1 -1
- package/dist/types/cascader/cascader.d.ts.map +1 -1
- package/dist/types/clock/clock.types.d.ts +5 -2
- package/dist/types/clock/clock.types.d.ts.map +1 -1
- package/dist/types/color-picker/color-picker.d.ts.map +1 -1
- package/dist/types/column-manager/column-manager.d.ts.map +1 -1
- package/dist/types/command-palette/command-palette.d.ts.map +1 -1
- package/dist/types/context-menu/context-menu.d.ts.map +1 -1
- package/dist/types/dashboard-grid/dashboard-grid.types.d.ts +2 -1
- package/dist/types/dashboard-grid/dashboard-grid.types.d.ts.map +1 -1
- package/dist/types/dashboard-grid/dashboard-widget.d.ts.map +1 -1
- package/dist/types/data-list/data-list.d.ts.map +1 -1
- package/dist/types/description-list/description-list-parts.d.ts.map +1 -1
- package/dist/types/detail-panel/detail-panel-parts.d.ts +10 -3
- package/dist/types/detail-panel/detail-panel-parts.d.ts.map +1 -1
- package/dist/types/detail-panel/detail-panel.d.ts.map +1 -1
- package/dist/types/detail-panel/detail-panel.types.d.ts +7 -0
- package/dist/types/detail-panel/detail-panel.types.d.ts.map +1 -1
- package/dist/types/drawer/drawer-parts.d.ts +8 -3
- package/dist/types/drawer/drawer-parts.d.ts.map +1 -1
- package/dist/types/drawer/drawer.types.d.ts +2 -1
- package/dist/types/drawer/drawer.types.d.ts.map +1 -1
- package/dist/types/entity-picker/entity-picker.d.ts.map +1 -1
- package/dist/types/event-calendar/event-calendar.d.ts.map +1 -1
- package/dist/types/filter-bar/filter-bar-rules.d.ts.map +1 -1
- package/dist/types/hover-card/hover-card.d.ts.map +1 -1
- package/dist/types/import-export-center/import-export-center.d.ts.map +1 -1
- package/dist/types/media-viewer/index.d.ts +2 -2
- package/dist/types/media-viewer/index.d.ts.map +1 -1
- package/dist/types/media-viewer/media-viewer-bar.d.ts +3 -1
- package/dist/types/media-viewer/media-viewer-bar.d.ts.map +1 -1
- package/dist/types/media-viewer/media-viewer.types.d.ts +1 -0
- package/dist/types/media-viewer/media-viewer.types.d.ts.map +1 -1
- package/dist/types/message/message-parts.d.ts +7 -0
- package/dist/types/message/message-parts.d.ts.map +1 -1
- package/dist/types/message/message.d.ts.map +1 -1
- package/dist/types/navigation-menu/navigation-menu-parts.d.ts.map +1 -1
- package/dist/types/page-header/page-header-parts.d.ts.map +1 -1
- package/dist/types/popover/index.d.ts +1 -1
- package/dist/types/popover/index.d.ts.map +1 -1
- package/dist/types/popover/popover-defaults.d.ts.map +1 -1
- package/dist/types/popover/popover-parts.d.ts +2 -1
- package/dist/types/popover/popover-parts.d.ts.map +1 -1
- package/dist/types/popover/popover.d.ts +1 -1
- package/dist/types/popover/popover.d.ts.map +1 -1
- package/dist/types/popover/popover.types.d.ts +20 -0
- package/dist/types/popover/popover.types.d.ts.map +1 -1
- package/dist/types/progress-indicator/progress-bar.d.ts.map +1 -1
- package/dist/types/saved-views/saved-views.d.ts +1 -0
- package/dist/types/saved-views/saved-views.d.ts.map +1 -1
- package/dist/types/section/section-parts.d.ts +16 -8
- package/dist/types/section/section-parts.d.ts.map +1 -1
- package/dist/types/section/section.d.ts.map +1 -1
- package/dist/types/segmented-control/segmented-control-parts.d.ts.map +1 -1
- package/dist/types/select/select-tags.d.ts.map +1 -1
- package/dist/types/side-navigation/side-navigation-parts.d.ts.map +1 -1
- package/dist/types/skeleton/skeleton-region-context.d.ts +2 -0
- package/dist/types/skeleton/skeleton-region-context.d.ts.map +1 -1
- package/dist/types/skeleton/skeleton-region.d.ts.map +1 -1
- package/dist/types/skeleton/skeleton-text.d.ts.map +1 -1
- package/dist/types/skeleton/skeleton.d.ts.map +1 -1
- package/dist/types/stat-card/stat-card-delta.d.ts.map +1 -1
- package/dist/types/stat-card/stat-card-parts.d.ts +3 -3
- package/dist/types/stat-card/stat-card-parts.d.ts.map +1 -1
- package/dist/types/stepper/stepper-parts.d.ts +11 -2
- package/dist/types/stepper/stepper-parts.d.ts.map +1 -1
- package/dist/types/stepper/stepper.d.ts.map +1 -1
- package/dist/types/table/table-parts.d.ts.map +1 -1
- package/dist/types/tags-input/tags-input.d.ts.map +1 -1
- package/dist/types/time-picker/time-picker.d.ts.map +1 -1
- package/dist/types/time-range-picker/time-range-picker.d.ts.map +1 -1
- package/dist/types/timeline/timeline-parts.d.ts.map +1 -1
- package/dist/types/toolbar/toolbar.d.ts.map +1 -1
- package/dist/types/toolbar/toolbar.types.d.ts +1 -1
- package/dist/types/toolbar/toolbar.types.d.ts.map +1 -1
- package/dist/types/tooltip/tooltip-defaults.d.ts.map +1 -1
- package/dist/types/tooltip/tooltip-parts.d.ts.map +1 -1
- package/dist/types/tooltip/tooltip.d.ts +1 -1
- package/dist/types/tooltip/tooltip.d.ts.map +1 -1
- package/dist/types/tooltip/tooltip.types.d.ts +17 -0
- package/dist/types/tooltip/tooltip.types.d.ts.map +1 -1
- package/dist/types/top-navigation/top-navigation.d.ts.map +1 -1
- package/dist/types/tour/tour.d.ts.map +1 -1
- package/dist/{upload-CuMOaPK3.js → upload-BtD1nLHa.js} +2 -2
- package/dist/upload.js +1 -1
- package/dist/{use-date-picker-DdSX3RE4.js → use-date-picker-CwH791Jm.js} +2 -2
- package/dist/{use-picker-draft-I_pxqYsc.js → use-picker-draft-BnLS4lDY.js} +1 -1
- package/dist/wizard-6PTtBoi4.js +838 -0
- package/dist/wizard.js +1 -1
- package/package.json +6 -6
- package/dist/action-sheet-BouG2qh_.js +0 -360
- package/dist/attachment-MqczA38F.js +0 -292
- package/dist/detail-panel-EImAtksY.js +0 -327
- package/dist/drawer-CQagePr_.js +0 -830
- package/dist/import-export-center-CW8YVZev.js +0 -867
- package/dist/message-D1Dd6Y2k.js +0 -452
- package/dist/popover-1DlOu95x.js +0 -576
- package/dist/section-D_qOfdxR.js +0 -213
- package/dist/toolbar-BP7ka6lN.js +0 -243
- package/dist/tooltip-DrFiRlH8.js +0 -411
- package/dist/top-navigation-D8IHPOmm.js +0 -744
- package/dist/wizard-4c0X7Bx_.js +0 -838
|
@@ -5,6 +5,47 @@
|
|
|
5
5
|
|
|
6
6
|
## Examples
|
|
7
7
|
|
|
8
|
+
### The bar of a freight operator
|
|
9
|
+
|
|
10
|
+
Aurora Logistics’ bar with every region filled, in a desktop room. The room scrolls sideways where the page is narrower; the steps the bar folds at are the next demonstration.
|
|
11
|
+
|
|
12
|
+
Excerpt — not a complete module
|
|
13
|
+
|
|
14
|
+
```tsx
|
|
15
|
+
<TopNavigation defaultValue="dashboard" skipTo="content">
|
|
16
|
+
<TopNavigationBrand>
|
|
17
|
+
<TopNavigationHome href="/">
|
|
18
|
+
<TopNavigationMark>
|
|
19
|
+
<AuroraMark />
|
|
20
|
+
</TopNavigationMark>
|
|
21
|
+
<TopNavigationName>Aurora Logistics</TopNavigationName>
|
|
22
|
+
</TopNavigationHome>
|
|
23
|
+
</TopNavigationBrand>
|
|
24
|
+
<TopNavigationNav>
|
|
25
|
+
<TopNavigationList>
|
|
26
|
+
<TopNavigationItem priority="high" value="dashboard">
|
|
27
|
+
<TopNavigationLink href="/dashboard">Dashboard</TopNavigationLink>
|
|
28
|
+
</TopNavigationItem>
|
|
29
|
+
<TopNavigationItem priority="low" value="reports">
|
|
30
|
+
<TopNavigationLink href="/reports">Reports</TopNavigationLink>
|
|
31
|
+
</TopNavigationItem>
|
|
32
|
+
</TopNavigationList>
|
|
33
|
+
</TopNavigationNav>
|
|
34
|
+
<TopNavigationSearch>
|
|
35
|
+
<TextField placeholder="Search loads, customers, routes…" type="search" />
|
|
36
|
+
</TopNavigationSearch>
|
|
37
|
+
<TopNavigationActions>
|
|
38
|
+
<TopNavigationHelp href="/help" />
|
|
39
|
+
<TopNavigationNotifications>
|
|
40
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
41
|
+
</TopNavigationNotifications>
|
|
42
|
+
<TopNavigationAccount>
|
|
43
|
+
<Avatar size="xs">AB</Avatar>
|
|
44
|
+
</TopNavigationAccount>
|
|
45
|
+
</TopNavigationActions>
|
|
46
|
+
</TopNavigation>;
|
|
47
|
+
```
|
|
48
|
+
|
|
8
49
|
### Every part, named
|
|
9
50
|
|
|
10
51
|
The bar with each part labelled by its data-part: the brand, the context, the destinations with a section trigger, the search, and the four global controls. The panel and its list stand in the DOM after the nav, closed.
|
|
@@ -45,202 +86,1070 @@ Excerpt — not a complete module
|
|
|
45
86
|
|
|
46
87
|
The same bar in four rooms of a stated width. On a desktop everything shows; on a laptop (under 1024) the low items have folded into more; a tablet at 640 folds the same low items and keeps the rest; on a phone the medium ones fold under 600, where the search becomes a magnifier and the context moves to the panel, and the high ones and the help fold under 480, where the name leaves the eye.
|
|
47
88
|
|
|
48
|
-
|
|
89
|
+
Example
|
|
49
90
|
|
|
50
91
|
```tsx
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
92
|
+
import { useState } from 'react';
|
|
93
|
+
|
|
94
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
95
|
+
import { Container } from '@slotted/react/container';
|
|
96
|
+
import { Page, PageBody } from '@slotted/react/page';
|
|
97
|
+
import { Stack } from '@slotted/react/stack';
|
|
98
|
+
import {
|
|
99
|
+
TopNavigation,
|
|
100
|
+
TopNavigationAccount,
|
|
101
|
+
TopNavigationActions,
|
|
102
|
+
TopNavigationBrand,
|
|
103
|
+
TopNavigationCount,
|
|
104
|
+
TopNavigationHome,
|
|
105
|
+
TopNavigationItem,
|
|
106
|
+
TopNavigationLink,
|
|
107
|
+
TopNavigationList,
|
|
108
|
+
TopNavigationMark,
|
|
109
|
+
TopNavigationName,
|
|
110
|
+
TopNavigationNav,
|
|
111
|
+
TopNavigationNotifications,
|
|
112
|
+
} from '@slotted/react/top-navigation';
|
|
113
|
+
import { Text } from '@slotted/react/typography';
|
|
114
|
+
|
|
115
|
+
export default function TopNavigationPriority() {
|
|
116
|
+
const [folded, setFolded] = useState<readonly string[]>([]);
|
|
117
|
+
|
|
118
|
+
return (
|
|
119
|
+
<Stack gap={0}>
|
|
120
|
+
<Container size="measure">
|
|
121
|
+
<TopNavigation defaultValue="dashboard" onCollapseChange={setFolded}>
|
|
122
|
+
<TopNavigationBrand>
|
|
123
|
+
<TopNavigationHome href="#home">
|
|
124
|
+
<TopNavigationMark>
|
|
125
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
126
|
+
<rect
|
|
127
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
128
|
+
height="18"
|
|
129
|
+
rx="5"
|
|
130
|
+
width="18"
|
|
131
|
+
x="3"
|
|
132
|
+
y="3"
|
|
133
|
+
/>
|
|
134
|
+
<path
|
|
135
|
+
d="M7 15.5 12 7l5 8.5"
|
|
136
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
137
|
+
strokeLinecap="round"
|
|
138
|
+
strokeLinejoin="round"
|
|
139
|
+
strokeWidth="2.2"
|
|
140
|
+
/>
|
|
141
|
+
</svg>
|
|
142
|
+
</TopNavigationMark>
|
|
143
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
144
|
+
</TopNavigationHome>
|
|
145
|
+
</TopNavigationBrand>
|
|
146
|
+
<TopNavigationNav>
|
|
147
|
+
<TopNavigationList>
|
|
148
|
+
<TopNavigationItem priority="high" value="dashboard">
|
|
149
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
150
|
+
</TopNavigationItem>
|
|
151
|
+
<TopNavigationItem priority="high" value="orders">
|
|
152
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
153
|
+
</TopNavigationItem>
|
|
154
|
+
<TopNavigationItem value="inventory">
|
|
155
|
+
<TopNavigationLink href="#inventory">Inventory</TopNavigationLink>
|
|
156
|
+
</TopNavigationItem>
|
|
157
|
+
<TopNavigationItem priority="medium" value="suppliers">
|
|
158
|
+
<TopNavigationLink href="#suppliers">Suppliers</TopNavigationLink>
|
|
159
|
+
</TopNavigationItem>
|
|
160
|
+
<TopNavigationItem priority="low" value="reports">
|
|
161
|
+
<TopNavigationLink href="#reports">Reports</TopNavigationLink>
|
|
162
|
+
</TopNavigationItem>
|
|
163
|
+
<TopNavigationItem priority="low" value="billing">
|
|
164
|
+
<TopNavigationLink href="#billing">Billing</TopNavigationLink>
|
|
165
|
+
</TopNavigationItem>
|
|
166
|
+
</TopNavigationList>
|
|
167
|
+
</TopNavigationNav>
|
|
168
|
+
<TopNavigationActions>
|
|
169
|
+
<TopNavigationNotifications>
|
|
170
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
171
|
+
</TopNavigationNotifications>
|
|
172
|
+
<TopNavigationAccount>
|
|
173
|
+
<Avatar
|
|
174
|
+
decorative
|
|
175
|
+
name="Maria Chen"
|
|
176
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
177
|
+
size="xs"
|
|
178
|
+
/>
|
|
179
|
+
</TopNavigationAccount>
|
|
180
|
+
</TopNavigationActions>
|
|
181
|
+
</TopNavigation>
|
|
182
|
+
</Container>
|
|
183
|
+
<Page ground="surface" landmark="none">
|
|
184
|
+
<PageBody>
|
|
185
|
+
<Text size="sm" tone="muted">
|
|
186
|
+
{folded.length === 0
|
|
187
|
+
? 'Nothing folded.'
|
|
188
|
+
: 'Folded into More: ' + folded.join(', ') + '.'}
|
|
189
|
+
</Text>
|
|
190
|
+
</PageBody>
|
|
191
|
+
</Page>
|
|
192
|
+
</Stack>
|
|
193
|
+
);
|
|
194
|
+
}
|
|
62
195
|
```
|
|
63
196
|
|
|
64
197
|
### What folded, under the bar
|
|
65
198
|
|
|
66
199
|
Press more: on a phone the panel takes the bar’s whole width, on a tablet it stands under the bar’s end. The folded destinations are rows, the workspace at the top and help at the bottom. A press on a row closes it with the reason select; Escape returns focus to more; a press outside closes it too.
|
|
67
200
|
|
|
68
|
-
|
|
201
|
+
Example
|
|
69
202
|
|
|
70
203
|
```tsx
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
204
|
+
import { useState } from 'react';
|
|
205
|
+
|
|
206
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
207
|
+
import { Button } from '@slotted/react/button';
|
|
208
|
+
import { Container } from '@slotted/react/container';
|
|
209
|
+
import { Inline } from '@slotted/react/inline';
|
|
210
|
+
import { Page, PageBody } from '@slotted/react/page';
|
|
211
|
+
import { Stack } from '@slotted/react/stack';
|
|
212
|
+
import {
|
|
213
|
+
TopNavigation,
|
|
214
|
+
TopNavigationAccount,
|
|
215
|
+
TopNavigationActions,
|
|
216
|
+
TopNavigationBrand,
|
|
217
|
+
TopNavigationCount,
|
|
218
|
+
TopNavigationHome,
|
|
219
|
+
TopNavigationItem,
|
|
220
|
+
TopNavigationLink,
|
|
221
|
+
TopNavigationList,
|
|
222
|
+
TopNavigationMark,
|
|
223
|
+
TopNavigationName,
|
|
224
|
+
TopNavigationNav,
|
|
225
|
+
TopNavigationNotifications,
|
|
226
|
+
} from '@slotted/react/top-navigation';
|
|
227
|
+
import { Text } from '@slotted/react/typography';
|
|
228
|
+
|
|
229
|
+
export default function TopNavigationPanel() {
|
|
230
|
+
const [open, setOpen] = useState(false);
|
|
231
|
+
const [reason, setReason] = useState('none');
|
|
232
|
+
|
|
233
|
+
return (
|
|
234
|
+
<Stack gap={0}>
|
|
235
|
+
<Container size="measure">
|
|
236
|
+
<TopNavigation
|
|
237
|
+
defaultValue="dashboard"
|
|
238
|
+
moreOpen={open}
|
|
239
|
+
onMoreOpenChange={(next, request) => {
|
|
240
|
+
setOpen(next);
|
|
241
|
+
setReason(request.reason);
|
|
242
|
+
}}
|
|
243
|
+
>
|
|
244
|
+
<TopNavigationBrand>
|
|
245
|
+
<TopNavigationHome href="#home">
|
|
246
|
+
<TopNavigationMark>
|
|
247
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
248
|
+
<rect
|
|
249
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
250
|
+
height="18"
|
|
251
|
+
rx="5"
|
|
252
|
+
width="18"
|
|
253
|
+
x="3"
|
|
254
|
+
y="3"
|
|
255
|
+
/>
|
|
256
|
+
<path
|
|
257
|
+
d="M7 15.5 12 7l5 8.5"
|
|
258
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
259
|
+
strokeLinecap="round"
|
|
260
|
+
strokeLinejoin="round"
|
|
261
|
+
strokeWidth="2.2"
|
|
262
|
+
/>
|
|
263
|
+
</svg>
|
|
264
|
+
</TopNavigationMark>
|
|
265
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
266
|
+
</TopNavigationHome>
|
|
267
|
+
</TopNavigationBrand>
|
|
268
|
+
<TopNavigationNav>
|
|
269
|
+
<TopNavigationList>
|
|
270
|
+
<TopNavigationItem priority="high" value="dashboard">
|
|
271
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
272
|
+
</TopNavigationItem>
|
|
273
|
+
<TopNavigationItem value="orders">
|
|
274
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
275
|
+
</TopNavigationItem>
|
|
276
|
+
<TopNavigationItem value="inventory">
|
|
277
|
+
<TopNavigationLink href="#inventory">Inventory</TopNavigationLink>
|
|
278
|
+
</TopNavigationItem>
|
|
279
|
+
<TopNavigationItem priority="low" value="reports">
|
|
280
|
+
<TopNavigationLink href="#reports">Reports</TopNavigationLink>
|
|
281
|
+
</TopNavigationItem>
|
|
282
|
+
</TopNavigationList>
|
|
283
|
+
</TopNavigationNav>
|
|
284
|
+
<TopNavigationActions>
|
|
285
|
+
<TopNavigationNotifications>
|
|
286
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
287
|
+
</TopNavigationNotifications>
|
|
288
|
+
<TopNavigationAccount>
|
|
289
|
+
<Avatar
|
|
290
|
+
decorative
|
|
291
|
+
name="Maria Chen"
|
|
292
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
293
|
+
size="xs"
|
|
294
|
+
/>
|
|
295
|
+
</TopNavigationAccount>
|
|
296
|
+
</TopNavigationActions>
|
|
297
|
+
</TopNavigation>
|
|
298
|
+
</Container>
|
|
299
|
+
<Page ground="surface" landmark="none">
|
|
300
|
+
<PageBody>
|
|
301
|
+
<Inline align="center" gap={3}>
|
|
302
|
+
<Button
|
|
303
|
+
onClick={() => {
|
|
304
|
+
setOpen(true);
|
|
305
|
+
}}
|
|
306
|
+
tone="secondary"
|
|
307
|
+
variant="outline"
|
|
308
|
+
>
|
|
309
|
+
Open the panel
|
|
310
|
+
</Button>
|
|
311
|
+
<Text size="sm" tone="muted">
|
|
312
|
+
Panel {open ? 'open' : 'closed'}, last reason: {reason}
|
|
313
|
+
</Text>
|
|
314
|
+
</Inline>
|
|
315
|
+
</PageBody>
|
|
316
|
+
</Page>
|
|
317
|
+
</Stack>
|
|
318
|
+
);
|
|
319
|
+
}
|
|
76
320
|
```
|
|
77
321
|
|
|
78
322
|
### The search gives way to a magnifier
|
|
79
323
|
|
|
80
324
|
On a laptop the field stands at the start of the middle of the bar, after the brand and the destinations. On a phone it is a magnifier in the actions; pressing it opens the field over the whole bar with focus inside, and Escape, the cross or focus leaving it hand the bar back.
|
|
81
325
|
|
|
82
|
-
|
|
326
|
+
Example
|
|
83
327
|
|
|
84
328
|
```tsx
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
329
|
+
import { useState } from 'react';
|
|
330
|
+
|
|
331
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
332
|
+
import { Button } from '@slotted/react/button';
|
|
333
|
+
import { Container } from '@slotted/react/container';
|
|
334
|
+
import { Glyph, Icon } from '@slotted/react/icon';
|
|
335
|
+
import { Inline } from '@slotted/react/inline';
|
|
336
|
+
import { Page, PageBody } from '@slotted/react/page';
|
|
337
|
+
import { Stack } from '@slotted/react/stack';
|
|
338
|
+
import { TextField } from '@slotted/react/text-field';
|
|
339
|
+
import {
|
|
340
|
+
TopNavigation,
|
|
341
|
+
TopNavigationAccount,
|
|
342
|
+
TopNavigationActions,
|
|
343
|
+
TopNavigationBrand,
|
|
344
|
+
TopNavigationCount,
|
|
345
|
+
TopNavigationHome,
|
|
346
|
+
TopNavigationMark,
|
|
347
|
+
TopNavigationName,
|
|
348
|
+
TopNavigationNotifications,
|
|
349
|
+
TopNavigationSearch,
|
|
350
|
+
} from '@slotted/react/top-navigation';
|
|
351
|
+
import { Text } from '@slotted/react/typography';
|
|
352
|
+
|
|
353
|
+
export default function TopNavigationSearchExample() {
|
|
354
|
+
const [open, setOpen] = useState(false);
|
|
355
|
+
|
|
356
|
+
return (
|
|
357
|
+
<Stack gap={0}>
|
|
358
|
+
<Container size="measure">
|
|
359
|
+
<TopNavigation onSearchOpenChange={setOpen} searchOpen={open}>
|
|
360
|
+
<TopNavigationBrand>
|
|
361
|
+
<TopNavigationHome href="#home">
|
|
362
|
+
<TopNavigationMark>
|
|
363
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
364
|
+
<rect
|
|
365
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
366
|
+
height="18"
|
|
367
|
+
rx="5"
|
|
368
|
+
width="18"
|
|
369
|
+
x="3"
|
|
370
|
+
y="3"
|
|
371
|
+
/>
|
|
372
|
+
<path
|
|
373
|
+
d="M7 15.5 12 7l5 8.5"
|
|
374
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
375
|
+
strokeLinecap="round"
|
|
376
|
+
strokeLinejoin="round"
|
|
377
|
+
strokeWidth="2.2"
|
|
378
|
+
/>
|
|
379
|
+
</svg>
|
|
380
|
+
</TopNavigationMark>
|
|
381
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
382
|
+
</TopNavigationHome>
|
|
383
|
+
</TopNavigationBrand>
|
|
384
|
+
<TopNavigationSearch>
|
|
385
|
+
<TextField
|
|
386
|
+
aria-label="Search"
|
|
387
|
+
placeholder="Search orders, products, suppliers…"
|
|
388
|
+
start={
|
|
389
|
+
<Icon>
|
|
390
|
+
<Glyph name="search" />
|
|
391
|
+
</Icon>
|
|
392
|
+
}
|
|
393
|
+
type="search"
|
|
394
|
+
variant="subtle"
|
|
395
|
+
/>
|
|
396
|
+
</TopNavigationSearch>
|
|
397
|
+
<TopNavigationActions>
|
|
398
|
+
<TopNavigationNotifications>
|
|
399
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
400
|
+
</TopNavigationNotifications>
|
|
401
|
+
<TopNavigationAccount>
|
|
402
|
+
<Avatar
|
|
403
|
+
decorative
|
|
404
|
+
name="Maria Chen"
|
|
405
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
406
|
+
size="xs"
|
|
407
|
+
/>
|
|
408
|
+
</TopNavigationAccount>
|
|
409
|
+
</TopNavigationActions>
|
|
410
|
+
</TopNavigation>
|
|
411
|
+
</Container>
|
|
412
|
+
<Page ground="surface" landmark="none">
|
|
413
|
+
<PageBody>
|
|
414
|
+
<Inline align="center" gap={3}>
|
|
415
|
+
<Button
|
|
416
|
+
onClick={() => {
|
|
417
|
+
setOpen(true);
|
|
418
|
+
}}
|
|
419
|
+
tone="secondary"
|
|
420
|
+
variant="outline"
|
|
421
|
+
>
|
|
422
|
+
Open the search
|
|
423
|
+
</Button>
|
|
424
|
+
<Text size="sm" tone="muted">
|
|
425
|
+
Search {open ? 'open' : 'closed'}
|
|
426
|
+
</Text>
|
|
427
|
+
</Inline>
|
|
428
|
+
</PageBody>
|
|
429
|
+
</Page>
|
|
430
|
+
</Stack>
|
|
431
|
+
);
|
|
432
|
+
}
|
|
95
433
|
```
|
|
96
434
|
|
|
97
435
|
### A section that opens a panel of destinations
|
|
98
436
|
|
|
99
|
-
|
|
437
|
+
A section of the navigation menu the nav part already is: its panel opens on the shared surface under the bar, a resting pointer opens it after a delay, and a second section switches without one. Folded into the panel, the section opens its links in line.
|
|
100
438
|
|
|
101
|
-
|
|
439
|
+
Example
|
|
102
440
|
|
|
103
441
|
```tsx
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
442
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
443
|
+
import {
|
|
444
|
+
NavigationMenuContent,
|
|
445
|
+
NavigationMenuLink,
|
|
446
|
+
NavigationMenuLinks,
|
|
447
|
+
} from '@slotted/react/navigation-menu';
|
|
448
|
+
import {
|
|
449
|
+
TopNavigation,
|
|
450
|
+
TopNavigationAccount,
|
|
451
|
+
TopNavigationActions,
|
|
452
|
+
TopNavigationBrand,
|
|
453
|
+
TopNavigationCount,
|
|
454
|
+
TopNavigationHome,
|
|
455
|
+
TopNavigationItem,
|
|
456
|
+
TopNavigationLink,
|
|
457
|
+
TopNavigationList,
|
|
458
|
+
TopNavigationMark,
|
|
459
|
+
TopNavigationName,
|
|
460
|
+
TopNavigationNav,
|
|
461
|
+
TopNavigationNotifications,
|
|
462
|
+
TopNavigationTrigger,
|
|
463
|
+
} from '@slotted/react/top-navigation';
|
|
464
|
+
|
|
465
|
+
export default function TopNavigationSections() {
|
|
466
|
+
return (
|
|
467
|
+
<TopNavigation defaultValue="dashboard">
|
|
468
|
+
<TopNavigationBrand>
|
|
469
|
+
<TopNavigationHome href="#home">
|
|
470
|
+
<TopNavigationMark>
|
|
471
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
472
|
+
<rect
|
|
473
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
474
|
+
height="18"
|
|
475
|
+
rx="5"
|
|
476
|
+
width="18"
|
|
477
|
+
x="3"
|
|
478
|
+
y="3"
|
|
479
|
+
/>
|
|
480
|
+
<path
|
|
481
|
+
d="M7 15.5 12 7l5 8.5"
|
|
482
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
483
|
+
strokeLinecap="round"
|
|
484
|
+
strokeLinejoin="round"
|
|
485
|
+
strokeWidth="2.2"
|
|
486
|
+
/>
|
|
487
|
+
</svg>
|
|
488
|
+
</TopNavigationMark>
|
|
489
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
490
|
+
</TopNavigationHome>
|
|
491
|
+
</TopNavigationBrand>
|
|
492
|
+
<TopNavigationNav>
|
|
493
|
+
<TopNavigationList>
|
|
494
|
+
<TopNavigationItem value="dashboard">
|
|
495
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
496
|
+
</TopNavigationItem>
|
|
497
|
+
<TopNavigationItem value="catalog">
|
|
498
|
+
<TopNavigationTrigger>Catalog</TopNavigationTrigger>
|
|
499
|
+
<NavigationMenuContent>
|
|
500
|
+
<NavigationMenuLinks>
|
|
501
|
+
<li>
|
|
502
|
+
<NavigationMenuLink href="#products">Products</NavigationMenuLink>
|
|
503
|
+
</li>
|
|
504
|
+
<li>
|
|
505
|
+
<NavigationMenuLink href="#categories">Categories</NavigationMenuLink>
|
|
506
|
+
</li>
|
|
507
|
+
<li>
|
|
508
|
+
<NavigationMenuLink href="#suppliers">Suppliers</NavigationMenuLink>
|
|
509
|
+
</li>
|
|
510
|
+
</NavigationMenuLinks>
|
|
511
|
+
</NavigationMenuContent>
|
|
512
|
+
</TopNavigationItem>
|
|
513
|
+
<TopNavigationItem value="orders">
|
|
514
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
515
|
+
</TopNavigationItem>
|
|
516
|
+
</TopNavigationList>
|
|
517
|
+
</TopNavigationNav>
|
|
518
|
+
<TopNavigationActions>
|
|
519
|
+
<TopNavigationNotifications>
|
|
520
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
521
|
+
</TopNavigationNotifications>
|
|
522
|
+
<TopNavigationAccount>
|
|
523
|
+
<Avatar
|
|
524
|
+
decorative
|
|
525
|
+
name="Maria Chen"
|
|
526
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
527
|
+
size="xs"
|
|
528
|
+
/>
|
|
529
|
+
</TopNavigationAccount>
|
|
530
|
+
</TopNavigationActions>
|
|
531
|
+
</TopNavigation>
|
|
532
|
+
);
|
|
533
|
+
}
|
|
114
534
|
```
|
|
115
535
|
|
|
116
536
|
### Where the reader is
|
|
117
537
|
|
|
118
538
|
value on the root names the destination and a press asks it to move with the device’s reason; a link that states current itself wins. Where the current destination has folded, more carries the mark in its place. With a router, usePressSelection paints the press before the route renders: the item is current at once, and the navigation runs after the frame that shows it. A click carrying a modifier key is left to the browser.
|
|
119
539
|
|
|
120
|
-
|
|
540
|
+
Example
|
|
121
541
|
|
|
122
542
|
```tsx
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
543
|
+
import { useState } from 'react';
|
|
544
|
+
|
|
545
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
546
|
+
import { Page, PageBody } from '@slotted/react/page';
|
|
547
|
+
import { Stack } from '@slotted/react/stack';
|
|
548
|
+
import {
|
|
549
|
+
TopNavigation,
|
|
550
|
+
TopNavigationAccount,
|
|
551
|
+
TopNavigationActions,
|
|
552
|
+
TopNavigationBrand,
|
|
553
|
+
TopNavigationCount,
|
|
554
|
+
TopNavigationHome,
|
|
555
|
+
TopNavigationItem,
|
|
556
|
+
TopNavigationLink,
|
|
557
|
+
TopNavigationList,
|
|
558
|
+
TopNavigationMark,
|
|
559
|
+
TopNavigationName,
|
|
560
|
+
TopNavigationNav,
|
|
561
|
+
TopNavigationNotifications,
|
|
562
|
+
} from '@slotted/react/top-navigation';
|
|
563
|
+
import { Text } from '@slotted/react/typography';
|
|
564
|
+
|
|
565
|
+
export default function TopNavigationCurrent() {
|
|
566
|
+
const [value, setValue] = useState<string | null>('orders');
|
|
567
|
+
|
|
568
|
+
return (
|
|
569
|
+
<Stack gap={0}>
|
|
570
|
+
<TopNavigation onValueChange={setValue} value={value}>
|
|
571
|
+
<TopNavigationBrand>
|
|
572
|
+
<TopNavigationHome href="#home">
|
|
573
|
+
<TopNavigationMark>
|
|
574
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
575
|
+
<rect
|
|
576
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
577
|
+
height="18"
|
|
578
|
+
rx="5"
|
|
579
|
+
width="18"
|
|
580
|
+
x="3"
|
|
581
|
+
y="3"
|
|
582
|
+
/>
|
|
583
|
+
<path
|
|
584
|
+
d="M7 15.5 12 7l5 8.5"
|
|
585
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
586
|
+
strokeLinecap="round"
|
|
587
|
+
strokeLinejoin="round"
|
|
588
|
+
strokeWidth="2.2"
|
|
589
|
+
/>
|
|
590
|
+
</svg>
|
|
591
|
+
</TopNavigationMark>
|
|
592
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
593
|
+
</TopNavigationHome>
|
|
594
|
+
</TopNavigationBrand>
|
|
595
|
+
<TopNavigationNav>
|
|
596
|
+
<TopNavigationList>
|
|
597
|
+
<TopNavigationItem value="dashboard">
|
|
598
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
599
|
+
</TopNavigationItem>
|
|
600
|
+
<TopNavigationItem value="orders">
|
|
601
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
602
|
+
</TopNavigationItem>
|
|
603
|
+
<TopNavigationItem value="inventory">
|
|
604
|
+
<TopNavigationLink href="#inventory">Inventory</TopNavigationLink>
|
|
605
|
+
</TopNavigationItem>
|
|
606
|
+
<TopNavigationItem value="suppliers">
|
|
607
|
+
<TopNavigationLink href="#suppliers">Suppliers</TopNavigationLink>
|
|
608
|
+
</TopNavigationItem>
|
|
609
|
+
</TopNavigationList>
|
|
610
|
+
</TopNavigationNav>
|
|
611
|
+
<TopNavigationActions>
|
|
612
|
+
<TopNavigationNotifications>
|
|
613
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
614
|
+
</TopNavigationNotifications>
|
|
615
|
+
<TopNavigationAccount>
|
|
616
|
+
<Avatar
|
|
617
|
+
decorative
|
|
618
|
+
name="Maria Chen"
|
|
619
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
620
|
+
size="xs"
|
|
621
|
+
/>
|
|
622
|
+
</TopNavigationAccount>
|
|
623
|
+
</TopNavigationActions>
|
|
624
|
+
</TopNavigation>
|
|
625
|
+
<Page ground="surface" landmark="none">
|
|
626
|
+
<PageBody>
|
|
627
|
+
<Text size="sm" tone="muted">
|
|
628
|
+
Current destination: {value}
|
|
629
|
+
</Text>
|
|
630
|
+
</PageBody>
|
|
631
|
+
</Page>
|
|
632
|
+
</Stack>
|
|
633
|
+
);
|
|
634
|
+
}
|
|
146
635
|
```
|
|
147
636
|
|
|
148
637
|
### The global controls
|
|
149
638
|
|
|
150
639
|
Help as a link to a help center or as the trigger of a popover; the bell with a count over its corner that grows to a pill away from it; the account as a menu’s trigger; a control of the product’s own — approvals — in the same square, with its own glyph and the same count. Each carries its name for a reader and repeats it in a tooltip.
|
|
151
640
|
|
|
152
|
-
|
|
641
|
+
Example
|
|
153
642
|
|
|
154
643
|
```tsx
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
644
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
645
|
+
import { Glyph } from '@slotted/react/icon';
|
|
646
|
+
import { Menu, MenuContent, MenuItem, MenuSeparator, MenuTrigger } from '@slotted/react/menu';
|
|
647
|
+
import {
|
|
648
|
+
Popover,
|
|
649
|
+
PopoverBody,
|
|
650
|
+
PopoverContent,
|
|
651
|
+
PopoverDescription,
|
|
652
|
+
PopoverHeader,
|
|
653
|
+
PopoverLayer,
|
|
654
|
+
PopoverTitle,
|
|
655
|
+
PopoverTrigger,
|
|
656
|
+
} from '@slotted/react/popover';
|
|
657
|
+
import {
|
|
658
|
+
TopNavigation,
|
|
659
|
+
TopNavigationAccount,
|
|
660
|
+
TopNavigationAction,
|
|
661
|
+
TopNavigationActions,
|
|
662
|
+
TopNavigationBrand,
|
|
663
|
+
TopNavigationCount,
|
|
664
|
+
TopNavigationHelp,
|
|
665
|
+
TopNavigationHome,
|
|
666
|
+
TopNavigationItem,
|
|
667
|
+
TopNavigationLink,
|
|
668
|
+
TopNavigationList,
|
|
669
|
+
TopNavigationMark,
|
|
670
|
+
TopNavigationName,
|
|
671
|
+
TopNavigationNav,
|
|
672
|
+
TopNavigationNotifications,
|
|
673
|
+
} from '@slotted/react/top-navigation';
|
|
674
|
+
|
|
675
|
+
export default function TopNavigationActionsExample() {
|
|
676
|
+
return (
|
|
677
|
+
<TopNavigation defaultValue="dashboard">
|
|
678
|
+
<TopNavigationBrand>
|
|
679
|
+
<TopNavigationHome href="#home">
|
|
680
|
+
<TopNavigationMark>
|
|
681
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
682
|
+
<rect
|
|
683
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
684
|
+
height="18"
|
|
685
|
+
rx="5"
|
|
686
|
+
width="18"
|
|
687
|
+
x="3"
|
|
688
|
+
y="3"
|
|
689
|
+
/>
|
|
690
|
+
<path
|
|
691
|
+
d="M7 15.5 12 7l5 8.5"
|
|
692
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
693
|
+
strokeLinecap="round"
|
|
694
|
+
strokeLinejoin="round"
|
|
695
|
+
strokeWidth="2.2"
|
|
696
|
+
/>
|
|
697
|
+
</svg>
|
|
698
|
+
</TopNavigationMark>
|
|
699
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
700
|
+
</TopNavigationHome>
|
|
701
|
+
</TopNavigationBrand>
|
|
702
|
+
<TopNavigationNav>
|
|
703
|
+
<TopNavigationList>
|
|
704
|
+
<TopNavigationItem value="dashboard">
|
|
705
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
706
|
+
</TopNavigationItem>
|
|
707
|
+
<TopNavigationItem value="orders">
|
|
708
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
709
|
+
</TopNavigationItem>
|
|
710
|
+
</TopNavigationList>
|
|
711
|
+
</TopNavigationNav>
|
|
712
|
+
<TopNavigationActions>
|
|
713
|
+
<TopNavigationHelp href="#help" />
|
|
714
|
+
<Popover align="end">
|
|
715
|
+
<PopoverTrigger
|
|
716
|
+
render={(props) => (
|
|
717
|
+
<TopNavigationAction {...props} aria-label="Approvals, 7 pending">
|
|
718
|
+
<Glyph name="circle-check" />
|
|
719
|
+
<TopNavigationCount>7</TopNavigationCount>
|
|
720
|
+
</TopNavigationAction>
|
|
721
|
+
)}
|
|
722
|
+
/>
|
|
723
|
+
<PopoverLayer>
|
|
724
|
+
<PopoverContent>
|
|
725
|
+
<PopoverHeader>
|
|
726
|
+
<PopoverTitle>Approvals</PopoverTitle>
|
|
727
|
+
</PopoverHeader>
|
|
728
|
+
<PopoverBody>
|
|
729
|
+
<PopoverDescription>
|
|
730
|
+
Purchase order 10248 and credit note 88 are waiting for approval.
|
|
731
|
+
</PopoverDescription>
|
|
732
|
+
</PopoverBody>
|
|
733
|
+
</PopoverContent>
|
|
734
|
+
</PopoverLayer>
|
|
735
|
+
</Popover>
|
|
736
|
+
<Popover align="end">
|
|
737
|
+
<PopoverTrigger
|
|
738
|
+
render={(props) => (
|
|
739
|
+
<TopNavigationNotifications {...props}>
|
|
740
|
+
<TopNavigationCount>128</TopNavigationCount>
|
|
741
|
+
</TopNavigationNotifications>
|
|
742
|
+
)}
|
|
743
|
+
/>
|
|
744
|
+
<PopoverLayer>
|
|
745
|
+
<PopoverContent>
|
|
746
|
+
<PopoverHeader>
|
|
747
|
+
<PopoverTitle>Notifications</PopoverTitle>
|
|
748
|
+
</PopoverHeader>
|
|
749
|
+
<PopoverBody>
|
|
750
|
+
<PopoverDescription>Order 10251 shipped late to Lyon.</PopoverDescription>
|
|
751
|
+
</PopoverBody>
|
|
752
|
+
</PopoverContent>
|
|
753
|
+
</PopoverLayer>
|
|
754
|
+
</Popover>
|
|
755
|
+
<Menu align="end">
|
|
756
|
+
<MenuTrigger
|
|
757
|
+
render={(props) => (
|
|
758
|
+
<TopNavigationAccount {...props}>
|
|
759
|
+
<Avatar
|
|
760
|
+
decorative
|
|
761
|
+
name="Maria Chen"
|
|
762
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
763
|
+
size="xs"
|
|
764
|
+
/>
|
|
765
|
+
<span>Maria Chen</span>
|
|
766
|
+
</TopNavigationAccount>
|
|
767
|
+
)}
|
|
768
|
+
/>
|
|
769
|
+
<MenuContent>
|
|
770
|
+
<MenuItem>Profile</MenuItem>
|
|
771
|
+
<MenuItem>Preferences</MenuItem>
|
|
772
|
+
<MenuSeparator />
|
|
773
|
+
<MenuItem>Sign out</MenuItem>
|
|
774
|
+
</MenuContent>
|
|
775
|
+
</Menu>
|
|
776
|
+
</TopNavigationActions>
|
|
777
|
+
</TopNavigation>
|
|
778
|
+
);
|
|
779
|
+
}
|
|
189
780
|
```
|
|
190
781
|
|
|
191
782
|
### What the application is right now
|
|
192
783
|
|
|
193
784
|
A workspace switcher and an environment badge after the brand. On a phone the whole region moves to the top of the panel — the same elements, so the switcher still opens its menu there.
|
|
194
785
|
|
|
195
|
-
|
|
786
|
+
Example
|
|
196
787
|
|
|
197
788
|
```tsx
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
789
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
790
|
+
import { Badge } from '@slotted/react/badge';
|
|
791
|
+
import { Button } from '@slotted/react/button';
|
|
792
|
+
import { Menu, MenuContent, MenuItem, MenuTrigger } from '@slotted/react/menu';
|
|
793
|
+
import {
|
|
794
|
+
TopNavigation,
|
|
795
|
+
TopNavigationAccount,
|
|
796
|
+
TopNavigationActions,
|
|
797
|
+
TopNavigationBrand,
|
|
798
|
+
TopNavigationContext,
|
|
799
|
+
TopNavigationCount,
|
|
800
|
+
TopNavigationHome,
|
|
801
|
+
TopNavigationItem,
|
|
802
|
+
TopNavigationLink,
|
|
803
|
+
TopNavigationList,
|
|
804
|
+
TopNavigationMark,
|
|
805
|
+
TopNavigationName,
|
|
806
|
+
TopNavigationNav,
|
|
807
|
+
TopNavigationNotifications,
|
|
808
|
+
} from '@slotted/react/top-navigation';
|
|
809
|
+
|
|
810
|
+
export default function TopNavigationContextExample() {
|
|
811
|
+
return (
|
|
812
|
+
<TopNavigation defaultValue="dashboard">
|
|
813
|
+
<TopNavigationBrand>
|
|
814
|
+
<TopNavigationHome href="#home">
|
|
815
|
+
<TopNavigationMark>
|
|
816
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
817
|
+
<rect
|
|
818
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
819
|
+
height="18"
|
|
820
|
+
rx="5"
|
|
821
|
+
width="18"
|
|
822
|
+
x="3"
|
|
823
|
+
y="3"
|
|
824
|
+
/>
|
|
825
|
+
<path
|
|
826
|
+
d="M7 15.5 12 7l5 8.5"
|
|
827
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
828
|
+
strokeLinecap="round"
|
|
829
|
+
strokeLinejoin="round"
|
|
830
|
+
strokeWidth="2.2"
|
|
831
|
+
/>
|
|
832
|
+
</svg>
|
|
833
|
+
</TopNavigationMark>
|
|
834
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
835
|
+
</TopNavigationHome>
|
|
836
|
+
</TopNavigationBrand>
|
|
837
|
+
<TopNavigationContext>
|
|
838
|
+
<Menu align="start">
|
|
839
|
+
<MenuTrigger
|
|
840
|
+
render={(props) => (
|
|
841
|
+
<Button {...props} size="sm" tone="secondary" variant="ghost">
|
|
842
|
+
Seattle · Operations
|
|
843
|
+
</Button>
|
|
844
|
+
)}
|
|
845
|
+
/>
|
|
846
|
+
<MenuContent>
|
|
847
|
+
<MenuItem>Seattle · Operations</MenuItem>
|
|
848
|
+
<MenuItem>Lyon · Distribution</MenuItem>
|
|
849
|
+
<MenuItem>Osaka · Wholesale</MenuItem>
|
|
850
|
+
</MenuContent>
|
|
851
|
+
</Menu>
|
|
852
|
+
<Badge size="sm" tone="warning" variant="soft">
|
|
853
|
+
Staging
|
|
854
|
+
</Badge>
|
|
855
|
+
</TopNavigationContext>
|
|
856
|
+
<TopNavigationNav>
|
|
857
|
+
<TopNavigationList>
|
|
858
|
+
<TopNavigationItem value="dashboard">
|
|
859
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
860
|
+
</TopNavigationItem>
|
|
861
|
+
<TopNavigationItem value="orders">
|
|
862
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
863
|
+
</TopNavigationItem>
|
|
864
|
+
<TopNavigationItem value="inventory">
|
|
865
|
+
<TopNavigationLink href="#inventory">Inventory</TopNavigationLink>
|
|
866
|
+
</TopNavigationItem>
|
|
867
|
+
</TopNavigationList>
|
|
868
|
+
</TopNavigationNav>
|
|
869
|
+
<TopNavigationActions>
|
|
870
|
+
<TopNavigationNotifications>
|
|
871
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
872
|
+
</TopNavigationNotifications>
|
|
873
|
+
<TopNavigationAccount>
|
|
874
|
+
<Avatar
|
|
875
|
+
decorative
|
|
876
|
+
name="Maria Chen"
|
|
877
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
878
|
+
size="xs"
|
|
879
|
+
/>
|
|
880
|
+
</TopNavigationAccount>
|
|
881
|
+
</TopNavigationActions>
|
|
882
|
+
</TopNavigation>
|
|
883
|
+
);
|
|
884
|
+
}
|
|
219
885
|
```
|
|
220
886
|
|
|
221
887
|
### Three control heights
|
|
222
888
|
|
|
223
889
|
sm, md and lg move every control in the bar together — the mark, the destinations, the four global controls — and the bar’s own height with them. All three move again with density.
|
|
224
890
|
|
|
225
|
-
|
|
891
|
+
Example
|
|
226
892
|
|
|
227
893
|
```tsx
|
|
228
|
-
|
|
894
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
895
|
+
import { Stack } from '@slotted/react/stack';
|
|
896
|
+
import {
|
|
897
|
+
TopNavigation,
|
|
898
|
+
TopNavigationAccount,
|
|
899
|
+
TopNavigationActions,
|
|
900
|
+
TopNavigationBrand,
|
|
901
|
+
TopNavigationCount,
|
|
902
|
+
TopNavigationHome,
|
|
903
|
+
TopNavigationItem,
|
|
904
|
+
TopNavigationLink,
|
|
905
|
+
TopNavigationList,
|
|
906
|
+
TopNavigationMark,
|
|
907
|
+
TopNavigationName,
|
|
908
|
+
TopNavigationNav,
|
|
909
|
+
TopNavigationNotifications,
|
|
910
|
+
} from '@slotted/react/top-navigation';
|
|
911
|
+
|
|
912
|
+
export default function TopNavigationSize() {
|
|
913
|
+
return (
|
|
914
|
+
<Stack gap={4}>
|
|
915
|
+
<TopNavigation defaultValue="dashboard" size="sm">
|
|
916
|
+
<TopNavigationBrand>
|
|
917
|
+
<TopNavigationHome href="#home">
|
|
918
|
+
<TopNavigationMark>
|
|
919
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
920
|
+
<rect
|
|
921
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
922
|
+
height="18"
|
|
923
|
+
rx="5"
|
|
924
|
+
width="18"
|
|
925
|
+
x="3"
|
|
926
|
+
y="3"
|
|
927
|
+
/>
|
|
928
|
+
<path
|
|
929
|
+
d="M7 15.5 12 7l5 8.5"
|
|
930
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
931
|
+
strokeLinecap="round"
|
|
932
|
+
strokeLinejoin="round"
|
|
933
|
+
strokeWidth="2.2"
|
|
934
|
+
/>
|
|
935
|
+
</svg>
|
|
936
|
+
</TopNavigationMark>
|
|
937
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
938
|
+
</TopNavigationHome>
|
|
939
|
+
</TopNavigationBrand>
|
|
940
|
+
<TopNavigationNav>
|
|
941
|
+
<TopNavigationList>
|
|
942
|
+
<TopNavigationItem value="dashboard">
|
|
943
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
944
|
+
</TopNavigationItem>
|
|
945
|
+
<TopNavigationItem value="orders">
|
|
946
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
947
|
+
</TopNavigationItem>
|
|
948
|
+
</TopNavigationList>
|
|
949
|
+
</TopNavigationNav>
|
|
950
|
+
<TopNavigationActions>
|
|
951
|
+
<TopNavigationNotifications>
|
|
952
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
953
|
+
</TopNavigationNotifications>
|
|
954
|
+
<TopNavigationAccount>
|
|
955
|
+
<Avatar
|
|
956
|
+
decorative
|
|
957
|
+
name="Maria Chen"
|
|
958
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
959
|
+
size="xs"
|
|
960
|
+
/>
|
|
961
|
+
</TopNavigationAccount>
|
|
962
|
+
</TopNavigationActions>
|
|
963
|
+
</TopNavigation>
|
|
964
|
+
<TopNavigation defaultValue="dashboard" size="md">
|
|
965
|
+
<TopNavigationBrand>
|
|
966
|
+
<TopNavigationHome href="#home">
|
|
967
|
+
<TopNavigationMark>
|
|
968
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
969
|
+
<rect
|
|
970
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
971
|
+
height="18"
|
|
972
|
+
rx="5"
|
|
973
|
+
width="18"
|
|
974
|
+
x="3"
|
|
975
|
+
y="3"
|
|
976
|
+
/>
|
|
977
|
+
<path
|
|
978
|
+
d="M7 15.5 12 7l5 8.5"
|
|
979
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
980
|
+
strokeLinecap="round"
|
|
981
|
+
strokeLinejoin="round"
|
|
982
|
+
strokeWidth="2.2"
|
|
983
|
+
/>
|
|
984
|
+
</svg>
|
|
985
|
+
</TopNavigationMark>
|
|
986
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
987
|
+
</TopNavigationHome>
|
|
988
|
+
</TopNavigationBrand>
|
|
989
|
+
<TopNavigationNav>
|
|
990
|
+
<TopNavigationList>
|
|
991
|
+
<TopNavigationItem value="dashboard">
|
|
992
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
993
|
+
</TopNavigationItem>
|
|
994
|
+
<TopNavigationItem value="orders">
|
|
995
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
996
|
+
</TopNavigationItem>
|
|
997
|
+
</TopNavigationList>
|
|
998
|
+
</TopNavigationNav>
|
|
999
|
+
<TopNavigationActions>
|
|
1000
|
+
<TopNavigationNotifications>
|
|
1001
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
1002
|
+
</TopNavigationNotifications>
|
|
1003
|
+
<TopNavigationAccount>
|
|
1004
|
+
<Avatar
|
|
1005
|
+
decorative
|
|
1006
|
+
name="Maria Chen"
|
|
1007
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
1008
|
+
size="xs"
|
|
1009
|
+
/>
|
|
1010
|
+
</TopNavigationAccount>
|
|
1011
|
+
</TopNavigationActions>
|
|
1012
|
+
</TopNavigation>
|
|
1013
|
+
<TopNavigation defaultValue="dashboard" size="lg">
|
|
1014
|
+
<TopNavigationBrand>
|
|
1015
|
+
<TopNavigationHome href="#home">
|
|
1016
|
+
<TopNavigationMark>
|
|
1017
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
1018
|
+
<rect
|
|
1019
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
1020
|
+
height="18"
|
|
1021
|
+
rx="5"
|
|
1022
|
+
width="18"
|
|
1023
|
+
x="3"
|
|
1024
|
+
y="3"
|
|
1025
|
+
/>
|
|
1026
|
+
<path
|
|
1027
|
+
d="M7 15.5 12 7l5 8.5"
|
|
1028
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
1029
|
+
strokeLinecap="round"
|
|
1030
|
+
strokeLinejoin="round"
|
|
1031
|
+
strokeWidth="2.2"
|
|
1032
|
+
/>
|
|
1033
|
+
</svg>
|
|
1034
|
+
</TopNavigationMark>
|
|
1035
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
1036
|
+
</TopNavigationHome>
|
|
1037
|
+
</TopNavigationBrand>
|
|
1038
|
+
<TopNavigationNav>
|
|
1039
|
+
<TopNavigationList>
|
|
1040
|
+
<TopNavigationItem value="dashboard">
|
|
1041
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
1042
|
+
</TopNavigationItem>
|
|
1043
|
+
<TopNavigationItem value="orders">
|
|
1044
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
1045
|
+
</TopNavigationItem>
|
|
1046
|
+
</TopNavigationList>
|
|
1047
|
+
</TopNavigationNav>
|
|
1048
|
+
<TopNavigationActions>
|
|
1049
|
+
<TopNavigationNotifications>
|
|
1050
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
1051
|
+
</TopNavigationNotifications>
|
|
1052
|
+
<TopNavigationAccount>
|
|
1053
|
+
<Avatar
|
|
1054
|
+
decorative
|
|
1055
|
+
name="Maria Chen"
|
|
1056
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
1057
|
+
size="xs"
|
|
1058
|
+
/>
|
|
1059
|
+
</TopNavigationAccount>
|
|
1060
|
+
</TopNavigationActions>
|
|
1061
|
+
</TopNavigation>
|
|
1062
|
+
</Stack>
|
|
1063
|
+
);
|
|
1064
|
+
}
|
|
229
1065
|
```
|
|
230
1066
|
|
|
231
1067
|
### The states a destination can be in
|
|
232
1068
|
|
|
233
1069
|
Current, a section open, disabled — a disabled destination keeps its href and its name and refuses the press — and the hover, press and focus every control answers. Help and the account with their layers open hold the pointer’s ground.
|
|
234
1070
|
|
|
235
|
-
|
|
1071
|
+
Example
|
|
236
1072
|
|
|
237
1073
|
```tsx
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
1074
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
1075
|
+
import {
|
|
1076
|
+
TopNavigation,
|
|
1077
|
+
TopNavigationAccount,
|
|
1078
|
+
TopNavigationActions,
|
|
1079
|
+
TopNavigationBrand,
|
|
1080
|
+
TopNavigationCount,
|
|
1081
|
+
TopNavigationHome,
|
|
1082
|
+
TopNavigationItem,
|
|
1083
|
+
TopNavigationLink,
|
|
1084
|
+
TopNavigationList,
|
|
1085
|
+
TopNavigationMark,
|
|
1086
|
+
TopNavigationName,
|
|
1087
|
+
TopNavigationNav,
|
|
1088
|
+
TopNavigationNotifications,
|
|
1089
|
+
} from '@slotted/react/top-navigation';
|
|
1090
|
+
|
|
1091
|
+
export default function TopNavigationStates() {
|
|
1092
|
+
return (
|
|
1093
|
+
<TopNavigation defaultValue="orders">
|
|
1094
|
+
<TopNavigationBrand>
|
|
1095
|
+
<TopNavigationHome href="#home">
|
|
1096
|
+
<TopNavigationMark>
|
|
1097
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
1098
|
+
<rect
|
|
1099
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
1100
|
+
height="18"
|
|
1101
|
+
rx="5"
|
|
1102
|
+
width="18"
|
|
1103
|
+
x="3"
|
|
1104
|
+
y="3"
|
|
1105
|
+
/>
|
|
1106
|
+
<path
|
|
1107
|
+
d="M7 15.5 12 7l5 8.5"
|
|
1108
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
1109
|
+
strokeLinecap="round"
|
|
1110
|
+
strokeLinejoin="round"
|
|
1111
|
+
strokeWidth="2.2"
|
|
1112
|
+
/>
|
|
1113
|
+
</svg>
|
|
1114
|
+
</TopNavigationMark>
|
|
1115
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
1116
|
+
</TopNavigationHome>
|
|
1117
|
+
</TopNavigationBrand>
|
|
1118
|
+
<TopNavigationNav>
|
|
1119
|
+
<TopNavigationList>
|
|
1120
|
+
<TopNavigationItem value="dashboard">
|
|
1121
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
1122
|
+
</TopNavigationItem>
|
|
1123
|
+
<TopNavigationItem value="orders">
|
|
1124
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
1125
|
+
</TopNavigationItem>
|
|
1126
|
+
<TopNavigationItem disabled value="inventory">
|
|
1127
|
+
<TopNavigationLink href="#inventory">Inventory</TopNavigationLink>
|
|
1128
|
+
</TopNavigationItem>
|
|
1129
|
+
<TopNavigationItem value="suppliers">
|
|
1130
|
+
<TopNavigationLink href="#suppliers">Suppliers</TopNavigationLink>
|
|
1131
|
+
</TopNavigationItem>
|
|
1132
|
+
</TopNavigationList>
|
|
1133
|
+
</TopNavigationNav>
|
|
1134
|
+
<TopNavigationActions>
|
|
1135
|
+
<TopNavigationNotifications>
|
|
1136
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
1137
|
+
</TopNavigationNotifications>
|
|
1138
|
+
<TopNavigationAccount>
|
|
1139
|
+
<Avatar
|
|
1140
|
+
decorative
|
|
1141
|
+
name="Maria Chen"
|
|
1142
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
1143
|
+
size="xs"
|
|
1144
|
+
/>
|
|
1145
|
+
</TopNavigationAccount>
|
|
1146
|
+
</TopNavigationActions>
|
|
1147
|
+
</TopNavigation>
|
|
1148
|
+
);
|
|
1149
|
+
}
|
|
241
1150
|
```
|
|
242
1151
|
|
|
243
|
-
### Content the
|
|
1152
|
+
### Content the bar does not choose
|
|
244
1153
|
|
|
245
1154
|
A product name of nine words, cut with an ellipsis and, when the room runs out, given up before any control; destinations of four words each; a count of three characters; the account with a name beside the avatar; and the same bar in a right-to-left document.
|
|
246
1155
|
|
|
@@ -283,8 +1192,8 @@ Excerpt — not a complete module
|
|
|
283
1192
|
|
|
284
1193
|
```tsx
|
|
285
1194
|
<>
|
|
286
|
-
<TopNavigation skipTo="
|
|
287
|
-
<main id="
|
|
1195
|
+
<TopNavigation skipTo="content">…</TopNavigation>
|
|
1196
|
+
<main id="content" tabIndex={-1}>
|
|
288
1197
|
…
|
|
289
1198
|
</main>
|
|
290
1199
|
</>;
|
|
@@ -294,12 +1203,134 @@ Excerpt — not a complete module
|
|
|
294
1203
|
|
|
295
1204
|
The provider carries the size and the frame for every bar under it — an application at the large step — and a bar that states one itself still wins. The words on the icon-only controls come from the language in force.
|
|
296
1205
|
|
|
297
|
-
|
|
1206
|
+
Example
|
|
298
1207
|
|
|
299
1208
|
```tsx
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
1209
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
1210
|
+
import { Stack } from '@slotted/react/stack';
|
|
1211
|
+
import {
|
|
1212
|
+
TopNavigation,
|
|
1213
|
+
TopNavigationAccount,
|
|
1214
|
+
TopNavigationActions,
|
|
1215
|
+
TopNavigationBrand,
|
|
1216
|
+
TopNavigationCount,
|
|
1217
|
+
TopNavigationDefaultsProvider,
|
|
1218
|
+
TopNavigationHome,
|
|
1219
|
+
TopNavigationItem,
|
|
1220
|
+
TopNavigationLink,
|
|
1221
|
+
TopNavigationList,
|
|
1222
|
+
TopNavigationMark,
|
|
1223
|
+
TopNavigationName,
|
|
1224
|
+
TopNavigationNav,
|
|
1225
|
+
TopNavigationNotifications,
|
|
1226
|
+
} from '@slotted/react/top-navigation';
|
|
1227
|
+
|
|
1228
|
+
export default function TopNavigationDefaults() {
|
|
1229
|
+
return (
|
|
1230
|
+
<TopNavigationDefaultsProvider size="lg">
|
|
1231
|
+
<Stack gap={4}>
|
|
1232
|
+
<TopNavigation defaultValue="dashboard">
|
|
1233
|
+
<TopNavigationBrand>
|
|
1234
|
+
<TopNavigationHome href="#home">
|
|
1235
|
+
<TopNavigationMark>
|
|
1236
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
1237
|
+
<rect
|
|
1238
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
1239
|
+
height="18"
|
|
1240
|
+
rx="5"
|
|
1241
|
+
width="18"
|
|
1242
|
+
x="3"
|
|
1243
|
+
y="3"
|
|
1244
|
+
/>
|
|
1245
|
+
<path
|
|
1246
|
+
d="M7 15.5 12 7l5 8.5"
|
|
1247
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
1248
|
+
strokeLinecap="round"
|
|
1249
|
+
strokeLinejoin="round"
|
|
1250
|
+
strokeWidth="2.2"
|
|
1251
|
+
/>
|
|
1252
|
+
</svg>
|
|
1253
|
+
</TopNavigationMark>
|
|
1254
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
1255
|
+
</TopNavigationHome>
|
|
1256
|
+
</TopNavigationBrand>
|
|
1257
|
+
<TopNavigationNav>
|
|
1258
|
+
<TopNavigationList>
|
|
1259
|
+
<TopNavigationItem value="dashboard">
|
|
1260
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
1261
|
+
</TopNavigationItem>
|
|
1262
|
+
<TopNavigationItem value="orders">
|
|
1263
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
1264
|
+
</TopNavigationItem>
|
|
1265
|
+
</TopNavigationList>
|
|
1266
|
+
</TopNavigationNav>
|
|
1267
|
+
<TopNavigationActions>
|
|
1268
|
+
<TopNavigationNotifications>
|
|
1269
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
1270
|
+
</TopNavigationNotifications>
|
|
1271
|
+
<TopNavigationAccount>
|
|
1272
|
+
<Avatar
|
|
1273
|
+
decorative
|
|
1274
|
+
name="Maria Chen"
|
|
1275
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
1276
|
+
size="xs"
|
|
1277
|
+
/>
|
|
1278
|
+
</TopNavigationAccount>
|
|
1279
|
+
</TopNavigationActions>
|
|
1280
|
+
</TopNavigation>
|
|
1281
|
+
<TopNavigation defaultValue="dashboard" size="sm">
|
|
1282
|
+
<TopNavigationBrand>
|
|
1283
|
+
<TopNavigationHome href="#home">
|
|
1284
|
+
<TopNavigationMark>
|
|
1285
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
1286
|
+
<rect
|
|
1287
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
1288
|
+
height="18"
|
|
1289
|
+
rx="5"
|
|
1290
|
+
width="18"
|
|
1291
|
+
x="3"
|
|
1292
|
+
y="3"
|
|
1293
|
+
/>
|
|
1294
|
+
<path
|
|
1295
|
+
d="M7 15.5 12 7l5 8.5"
|
|
1296
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
1297
|
+
strokeLinecap="round"
|
|
1298
|
+
strokeLinejoin="round"
|
|
1299
|
+
strokeWidth="2.2"
|
|
1300
|
+
/>
|
|
1301
|
+
</svg>
|
|
1302
|
+
</TopNavigationMark>
|
|
1303
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
1304
|
+
</TopNavigationHome>
|
|
1305
|
+
</TopNavigationBrand>
|
|
1306
|
+
<TopNavigationNav>
|
|
1307
|
+
<TopNavigationList>
|
|
1308
|
+
<TopNavigationItem value="dashboard">
|
|
1309
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
1310
|
+
</TopNavigationItem>
|
|
1311
|
+
<TopNavigationItem value="orders">
|
|
1312
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
1313
|
+
</TopNavigationItem>
|
|
1314
|
+
</TopNavigationList>
|
|
1315
|
+
</TopNavigationNav>
|
|
1316
|
+
<TopNavigationActions>
|
|
1317
|
+
<TopNavigationNotifications>
|
|
1318
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
1319
|
+
</TopNavigationNotifications>
|
|
1320
|
+
<TopNavigationAccount>
|
|
1321
|
+
<Avatar
|
|
1322
|
+
decorative
|
|
1323
|
+
name="Maria Chen"
|
|
1324
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
1325
|
+
size="xs"
|
|
1326
|
+
/>
|
|
1327
|
+
</TopNavigationAccount>
|
|
1328
|
+
</TopNavigationActions>
|
|
1329
|
+
</TopNavigation>
|
|
1330
|
+
</Stack>
|
|
1331
|
+
</TopNavigationDefaultsProvider>
|
|
1332
|
+
);
|
|
1333
|
+
}
|
|
303
1334
|
```
|
|
304
1335
|
|
|
305
1336
|
### Composed with what sits beside it
|
|
@@ -309,9 +1340,9 @@ A router’s link as the destination through render, which is where aria-current
|
|
|
309
1340
|
Excerpt — not a complete module
|
|
310
1341
|
|
|
311
1342
|
```tsx
|
|
312
|
-
<TopNavigationItem value="
|
|
313
|
-
<TopNavigationLink render={(props) => <NavLink {...props} to="/
|
|
314
|
-
|
|
1343
|
+
<TopNavigationItem value="orders">
|
|
1344
|
+
<TopNavigationLink render={(props) => <NavLink {...props} to="/orders" />}>
|
|
1345
|
+
Orders
|
|
315
1346
|
</TopNavigationLink>
|
|
316
1347
|
</TopNavigationItem>;
|
|
317
1348
|
```
|
|
@@ -334,12 +1365,149 @@ Excerpt — not a complete module
|
|
|
334
1365
|
|
|
335
1366
|
### What a reader hears
|
|
336
1367
|
|
|
337
|
-
A banner landmark holding a navigation landmark with a list of links, one of them current; a button named
|
|
1368
|
+
A banner landmark holding a navigation landmark with a list of links, one of them current; a button named More that expands a panel; a search; and three buttons named for what they open. Nothing is a menubar and nothing writes tabindex.
|
|
338
1369
|
|
|
339
1370
|
Excerpt — not a complete module
|
|
340
1371
|
|
|
341
1372
|
```tsx
|
|
342
1373
|
<TopNavigation aria-label="Aurora">
|
|
343
|
-
<TopNavigationNav aria-label="
|
|
1374
|
+
<TopNavigationNav aria-label="Main">…</TopNavigationNav>
|
|
344
1375
|
</TopNavigation>;
|
|
345
1376
|
```
|
|
1377
|
+
|
|
1378
|
+
### frame.tsx
|
|
1379
|
+
|
|
1380
|
+
Example
|
|
1381
|
+
|
|
1382
|
+
```tsx
|
|
1383
|
+
import { Avatar } from '@slotted/react/avatar';
|
|
1384
|
+
import { Card } from '@slotted/react/card';
|
|
1385
|
+
import { Page, PageBody } from '@slotted/react/page';
|
|
1386
|
+
import { Stack } from '@slotted/react/stack';
|
|
1387
|
+
import {
|
|
1388
|
+
TopNavigation,
|
|
1389
|
+
TopNavigationAccount,
|
|
1390
|
+
TopNavigationActions,
|
|
1391
|
+
TopNavigationBrand,
|
|
1392
|
+
TopNavigationCount,
|
|
1393
|
+
TopNavigationHome,
|
|
1394
|
+
TopNavigationItem,
|
|
1395
|
+
TopNavigationLink,
|
|
1396
|
+
TopNavigationList,
|
|
1397
|
+
TopNavigationMark,
|
|
1398
|
+
TopNavigationName,
|
|
1399
|
+
TopNavigationNav,
|
|
1400
|
+
TopNavigationNotifications,
|
|
1401
|
+
} from '@slotted/react/top-navigation';
|
|
1402
|
+
|
|
1403
|
+
export default function TopNavigationFrame() {
|
|
1404
|
+
return (
|
|
1405
|
+
<Stack gap={0}>
|
|
1406
|
+
<TopNavigation defaultValue="dashboard">
|
|
1407
|
+
<TopNavigationBrand>
|
|
1408
|
+
<TopNavigationHome href="#home">
|
|
1409
|
+
<TopNavigationMark>
|
|
1410
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
1411
|
+
<rect
|
|
1412
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
1413
|
+
height="18"
|
|
1414
|
+
rx="5"
|
|
1415
|
+
width="18"
|
|
1416
|
+
x="3"
|
|
1417
|
+
y="3"
|
|
1418
|
+
/>
|
|
1419
|
+
<path
|
|
1420
|
+
d="M7 15.5 12 7l5 8.5"
|
|
1421
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
1422
|
+
strokeLinecap="round"
|
|
1423
|
+
strokeLinejoin="round"
|
|
1424
|
+
strokeWidth="2.2"
|
|
1425
|
+
/>
|
|
1426
|
+
</svg>
|
|
1427
|
+
</TopNavigationMark>
|
|
1428
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
1429
|
+
</TopNavigationHome>
|
|
1430
|
+
</TopNavigationBrand>
|
|
1431
|
+
<TopNavigationNav>
|
|
1432
|
+
<TopNavigationList>
|
|
1433
|
+
<TopNavigationItem value="dashboard">
|
|
1434
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
1435
|
+
</TopNavigationItem>
|
|
1436
|
+
<TopNavigationItem value="orders">
|
|
1437
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
1438
|
+
</TopNavigationItem>
|
|
1439
|
+
</TopNavigationList>
|
|
1440
|
+
</TopNavigationNav>
|
|
1441
|
+
<TopNavigationActions>
|
|
1442
|
+
<TopNavigationNotifications>
|
|
1443
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
1444
|
+
</TopNavigationNotifications>
|
|
1445
|
+
<TopNavigationAccount>
|
|
1446
|
+
<Avatar
|
|
1447
|
+
decorative
|
|
1448
|
+
name="Maria Chen"
|
|
1449
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
1450
|
+
size="xs"
|
|
1451
|
+
/>
|
|
1452
|
+
</TopNavigationAccount>
|
|
1453
|
+
</TopNavigationActions>
|
|
1454
|
+
</TopNavigation>
|
|
1455
|
+
<Page ground="surface" landmark="none">
|
|
1456
|
+
<PageBody>
|
|
1457
|
+
<Card>
|
|
1458
|
+
<TopNavigation defaultValue="dashboard" frame={false} landmark={false}>
|
|
1459
|
+
<TopNavigationBrand>
|
|
1460
|
+
<TopNavigationHome href="#home">
|
|
1461
|
+
<TopNavigationMark>
|
|
1462
|
+
<svg aria-hidden="true" fill="none" viewBox="0 0 24 24">
|
|
1463
|
+
<rect
|
|
1464
|
+
fill="var(--slotted-tone-accent-solid)"
|
|
1465
|
+
height="18"
|
|
1466
|
+
rx="5"
|
|
1467
|
+
width="18"
|
|
1468
|
+
x="3"
|
|
1469
|
+
y="3"
|
|
1470
|
+
/>
|
|
1471
|
+
<path
|
|
1472
|
+
d="M7 15.5 12 7l5 8.5"
|
|
1473
|
+
stroke="var(--slotted-tone-accent-on-solid)"
|
|
1474
|
+
strokeLinecap="round"
|
|
1475
|
+
strokeLinejoin="round"
|
|
1476
|
+
strokeWidth="2.2"
|
|
1477
|
+
/>
|
|
1478
|
+
</svg>
|
|
1479
|
+
</TopNavigationMark>
|
|
1480
|
+
<TopNavigationName>Northwind Traders</TopNavigationName>
|
|
1481
|
+
</TopNavigationHome>
|
|
1482
|
+
</TopNavigationBrand>
|
|
1483
|
+
<TopNavigationNav>
|
|
1484
|
+
<TopNavigationList>
|
|
1485
|
+
<TopNavigationItem value="dashboard">
|
|
1486
|
+
<TopNavigationLink href="#dashboard">Dashboard</TopNavigationLink>
|
|
1487
|
+
</TopNavigationItem>
|
|
1488
|
+
<TopNavigationItem value="orders">
|
|
1489
|
+
<TopNavigationLink href="#orders">Orders</TopNavigationLink>
|
|
1490
|
+
</TopNavigationItem>
|
|
1491
|
+
</TopNavigationList>
|
|
1492
|
+
</TopNavigationNav>
|
|
1493
|
+
<TopNavigationActions>
|
|
1494
|
+
<TopNavigationNotifications>
|
|
1495
|
+
<TopNavigationCount>3</TopNavigationCount>
|
|
1496
|
+
</TopNavigationNotifications>
|
|
1497
|
+
<TopNavigationAccount>
|
|
1498
|
+
<Avatar
|
|
1499
|
+
decorative
|
|
1500
|
+
name="Maria Chen"
|
|
1501
|
+
src="https://api.dicebear.com/11.x/lorelei/svg?seed=Maria%20Chen&backgroundColor=b6e3f4,c0aede,d1d4f9,ffd5dc,ffdfbf"
|
|
1502
|
+
size="xs"
|
|
1503
|
+
/>
|
|
1504
|
+
</TopNavigationAccount>
|
|
1505
|
+
</TopNavigationActions>
|
|
1506
|
+
</TopNavigation>
|
|
1507
|
+
</Card>
|
|
1508
|
+
</PageBody>
|
|
1509
|
+
</Page>
|
|
1510
|
+
</Stack>
|
|
1511
|
+
);
|
|
1512
|
+
}
|
|
1513
|
+
```
|