@nxgt/material 3.79.1 → 3.80.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +48 -0
- package/README.md +45 -6
- package/dist/{alert-dialog-653apk3f.js → alert-dialog-DgHtXZuB.js} +1 -1
- package/dist/{async-slice-CXLbQuOc.js → async-slice-YBQsGtQT.js} +1 -1
- package/dist/{button-3op3rtZh.js → button-_vm-xSBU.js} +1 -1
- package/dist/{calculator-KqIMBXSh.js → calculator-CTd_S23A.js} +10 -10
- package/dist/calculator-field.js +6 -6
- package/dist/{calculator-segment-BlJE1LaS.js → calculator-segment-OI1BT3bA.js} +1 -1
- package/dist/calculator.js +1 -1
- package/dist/charts.js +3 -3
- package/dist/{chip-MuKDwtkG.js → chip-DumcVzUO.js} +2 -2
- package/dist/{code-editor-Bp2RrdNx.js → code-editor-CiwgfSOK.js} +4 -4
- package/dist/code-editor.js +4 -4
- package/dist/{code-language-items-B7WR5ua_.js → code-language-items-Dip0xnmc.js} +2 -2
- package/dist/components/components.css +3 -0
- package/dist/components/ui/actions/fab/fab-dock.css +19 -6
- package/dist/components/ui/layout/app-search/app-search.css +62 -0
- package/dist/components/ui/layout/app-shell/activity-backdrop.css +10 -2
- package/dist/components/ui/layout/app-shell/app-header.css +108 -0
- package/dist/components/ui/layout/navigation-toolbar/navigation-toolbar.css +43 -0
- package/dist/{components-CTyNC_zW.js → components-CJFHhkZv.js} +21798 -17784
- package/dist/components.js +37 -37
- package/dist/{conversion-variant-BDFAxqe9.js → conversion-variant-CqrPwPjC.js} +3 -3
- package/dist/{currency-field-DWHB5oms.js → currency-field-CMFvctye.js} +4 -4
- package/dist/{dialog-Bm5LvVlB.js → dialog-B0iU3fmh.js} +3 -3
- package/dist/dnd.js +2 -2
- package/dist/{dropdown-menu-xlZ6NYUA.js → dropdown-menu-CPOgcajv.js} +1 -1
- package/dist/editor.js +7 -7
- package/dist/{empty-state-C0kviQdW.js → empty-state-D3Jggupu.js} +1 -1
- package/dist/{financial-variant-CggTpad2.js → financial-variant-BdyfYhnp.js} +5 -5
- package/dist/{hooks-Dg94jPRq.js → hooks-Z7KKbv4G.js} +2 -2
- package/dist/hooks.js +2 -2
- package/dist/{hover-card-B1g55Hi6.js → hover-card-CFGIX6kg.js} +1 -1
- package/dist/i18n.js +3 -3
- package/dist/{icon-badge-BcW66bRk.js → icon-badge-kxGWUvcO.js} +1 -1
- package/dist/{icon-button-Cogxy1cy.js → icon-button-BamxMwZs.js} +1 -1
- package/dist/lib/components/ui/fields/contacts/placeholders.d.ts +1 -1
- package/dist/lib/components/ui/layout/app-bar/top-app-bar.d.ts +18 -3
- package/dist/lib/components/ui/layout/app-search/app-search-bar.d.ts +11 -0
- package/dist/lib/components/ui/layout/app-search/app-search.types.d.ts +47 -0
- package/dist/lib/components/ui/layout/app-search/index.d.ts +3 -0
- package/dist/lib/components/ui/layout/app-search/partials/on-phone.d.ts +2 -0
- package/dist/lib/components/ui/layout/app-search/partials/phone-search.d.ts +3 -0
- package/dist/lib/components/ui/layout/app-search/partials/pill-search.d.ts +3 -0
- package/dist/lib/components/ui/layout/app-search/pill-form.d.ts +18 -0
- package/dist/lib/components/ui/layout/app-search/search-panel.d.ts +24 -0
- package/dist/lib/components/ui/layout/app-search/search-results.d.ts +14 -0
- package/dist/lib/components/ui/layout/app-search/search-shortcut.d.ts +15 -0
- package/dist/lib/components/ui/layout/app-search/search-view.d.ts +22 -0
- package/dist/lib/components/ui/layout/app-search/use-pill-panel.d.ts +22 -0
- package/dist/lib/components/ui/layout/app-search/use-search-text.d.ts +8 -0
- package/dist/lib/components/ui/layout/app-shell/activity-app-bar.d.ts +35 -0
- package/dist/lib/components/ui/layout/app-shell/activity-chrome.d.ts +26 -3
- package/dist/lib/components/ui/layout/app-shell/activity-column-props.d.ts +22 -0
- package/dist/lib/components/ui/layout/app-shell/activity-column.d.ts +10 -2
- package/dist/lib/components/ui/layout/app-shell/activity-layout-navigation.types.d.ts +94 -0
- package/dist/lib/components/ui/layout/app-shell/activity-layout.d.ts +8 -1
- package/dist/lib/components/ui/layout/app-shell/activity-layout.types.d.ts +2 -1
- package/dist/lib/components/ui/layout/app-shell/activity-rails.d.ts +16 -0
- package/dist/lib/components/ui/layout/app-shell/activity-sidebar-lane.d.ts +22 -0
- package/dist/lib/components/ui/layout/app-shell/activity-top-nav.d.ts +11 -0
- package/dist/lib/components/ui/layout/app-shell/activity-two-level-lane.d.ts +14 -0
- package/dist/lib/components/ui/layout/app-shell/app-back.d.ts +22 -0
- package/dist/lib/components/ui/layout/app-shell/app-header-row.d.ts +3 -0
- package/dist/lib/components/ui/layout/app-shell/app-header.d.ts +33 -1
- package/dist/lib/components/ui/layout/app-shell/app-shell.utils.d.ts +8 -0
- package/dist/lib/components/ui/layout/app-shell/app-sidebar-entries.d.ts +13 -0
- package/dist/lib/components/ui/layout/app-shell/app-sidebar-label-item.d.ts +3 -1
- package/dist/lib/components/ui/layout/app-shell/bottom-chrome.d.ts +13 -0
- package/dist/lib/components/ui/layout/app-shell/header-title.d.ts +18 -2
- package/dist/lib/components/ui/layout/app-shell/header.utils.d.ts +37 -0
- package/dist/lib/components/ui/layout/app-shell/index.d.ts +3 -0
- package/dist/lib/components/ui/layout/app-shell/navigation-parts.d.ts +38 -0
- package/dist/lib/components/ui/layout/app-shell/navigation.utils.d.ts +36 -0
- package/dist/lib/components/ui/layout/app-shell/page-title-scope.d.ts +14 -0
- package/dist/lib/components/ui/layout/app-shell/page-title.d.ts +12 -1
- package/dist/lib/components/ui/layout/app-shell/shell-scroll.d.ts +32 -0
- package/dist/lib/components/ui/layout/app-shell/sticky-offset.d.ts +8 -0
- package/dist/lib/components/ui/layout/app-shell/types.d.ts +14 -0
- package/dist/lib/components/ui/layout/app-shell/use-focus-while-hidden.d.ts +9 -0
- package/dist/lib/components/ui/layout/app-shell/use-header-height.d.ts +12 -0
- package/dist/lib/components/ui/layout/app-shell/use-header-scroll.d.ts +19 -0
- package/dist/lib/components/ui/layout/app-shell/use-shell-header.d.ts +20 -0
- package/dist/lib/components/ui/layout/auth-card/auth-card-split.d.ts +14 -0
- package/dist/lib/components/ui/layout/auth-card/auth-card.d.ts +13 -1
- package/dist/lib/components/ui/layout/dashboard-grid/dashboard-grid-context.d.ts +21 -0
- package/dist/lib/components/ui/layout/dashboard-grid/dashboard-grid.d.ts +9 -0
- package/dist/lib/components/ui/layout/dashboard-grid/dashboard-grid.state.d.ts +30 -0
- package/dist/lib/components/ui/layout/dashboard-grid/dashboard-grid.tiles.d.ts +8 -0
- package/dist/lib/components/ui/layout/dashboard-grid/dashboard-grid.types.d.ts +50 -0
- package/dist/lib/components/ui/layout/dashboard-grid/dashboard-grid.utils.d.ts +70 -0
- package/dist/lib/components/ui/layout/dashboard-grid/dashboard-tile.d.ts +7 -0
- package/dist/lib/components/ui/layout/dashboard-grid/index.d.ts +4 -0
- package/dist/lib/components/ui/layout/dashboard-grid/partials/dashboard-announcer.d.ts +6 -0
- package/dist/lib/components/ui/layout/dashboard-grid/partials/dashboard-edit-bar.d.ts +11 -0
- package/dist/lib/components/ui/layout/dashboard-grid/partials/dashboard-move-buttons.d.ts +9 -0
- package/dist/lib/components/ui/layout/dashboard-grid/partials/dashboard-toolbar.d.ts +7 -0
- package/dist/lib/components/ui/layout/dashboard-grid/use-dashboard-grid.d.ts +21 -0
- package/dist/lib/components/ui/layout/dashboard-grid/use-dashboard-moves.d.ts +22 -0
- package/dist/lib/components/ui/layout/doc/doc-context.d.ts +2 -0
- package/dist/lib/components/ui/layout/doc/doc.d.ts +5 -0
- package/dist/lib/components/ui/layout/doc/index.d.ts +1 -1
- package/dist/lib/components/ui/layout/doc/partials/doc-embedded-bar.d.ts +9 -0
- package/dist/lib/components/ui/layout/doc/partials/doc-embedded.d.ts +8 -0
- package/dist/lib/components/ui/layout/doc/use-doc.d.ts +9 -1
- package/dist/lib/components/ui/layout/editor-layout/editor-layout.d.ts +14 -0
- package/dist/lib/components/ui/layout/editor-layout/editor-layout.types.d.ts +31 -0
- package/dist/lib/components/ui/layout/editor-layout/index.d.ts +4 -0
- package/dist/lib/components/ui/layout/editor-layout/partials/editor-layout-body.d.ts +11 -0
- package/dist/lib/components/ui/layout/editor-layout/partials/editor-layout-canvas.d.ts +8 -0
- package/dist/lib/components/ui/layout/editor-layout/partials/editor-layout-context.d.ts +12 -0
- package/dist/lib/components/ui/layout/editor-layout/partials/editor-layout-start.d.ts +8 -0
- package/dist/lib/components/ui/layout/editor-layout/partials/editor-layout-triggers.d.ts +10 -0
- package/dist/lib/components/ui/layout/editor-layout/partials/use-editor-layout-names.d.ts +8 -0
- package/dist/lib/components/ui/layout/editor-layout/partials/use-editor-layout-state.d.ts +21 -0
- package/dist/lib/components/ui/layout/index.d.ts +9 -0
- package/dist/lib/components/ui/layout/landing/index.d.ts +6 -0
- package/dist/lib/components/ui/layout/landing/landing-layout.d.ts +15 -0
- package/dist/lib/components/ui/layout/landing/landing-layout.types.d.ts +27 -0
- package/dist/lib/components/ui/layout/landing/landing-section.d.ts +12 -0
- package/dist/lib/components/ui/layout/landing/landing-section.types.d.ts +32 -0
- package/dist/lib/components/ui/layout/landing/landing.classes.d.ts +20 -0
- package/dist/lib/components/ui/layout/landing/partials/landing-header.d.ts +11 -0
- package/dist/lib/components/ui/layout/landing/partials/landing-section-intro.d.ts +13 -0
- package/dist/lib/components/ui/layout/landing/partials/site-footer-group.d.ts +8 -0
- package/dist/lib/components/ui/layout/landing/site-footer.d.ts +13 -0
- package/dist/lib/components/ui/layout/landing/site-footer.types.d.ts +29 -0
- package/dist/lib/components/ui/layout/list-details-layout/internal.d.ts +2 -0
- package/dist/lib/components/ui/layout/list-details-layout/list-details-layout.d.ts +9 -17
- package/dist/lib/components/ui/layout/list-details-layout/partials/history-mark.d.ts +2 -0
- package/dist/lib/components/ui/layout/list-details-layout/partials/list-details-context.d.ts +17 -1
- package/dist/lib/components/ui/layout/list-details-layout/partials/list-details-history.d.ts +8 -0
- package/dist/lib/components/ui/layout/list-details-layout/partials/list-details-inspector.d.ts +21 -0
- package/dist/lib/components/ui/layout/list-details-layout/partials/list-details-layout.types.d.ts +47 -0
- package/dist/lib/components/ui/layout/list-details-layout/partials/list-details-resizer.d.ts +9 -0
- package/dist/lib/components/ui/layout/list-details-layout/partials/list-details-root.d.ts +3 -0
- package/dist/lib/components/ui/layout/list-details-layout/partials/list-details-trigger.d.ts +13 -4
- package/dist/lib/components/ui/layout/list-details-layout/partials/use-inspector-focus.d.ts +8 -0
- package/dist/lib/components/ui/layout/list-details-layout/partials/use-list-details-param.d.ts +26 -0
- package/dist/lib/components/ui/layout/list-details-layout/partials/use-list-details-state.d.ts +15 -0
- package/dist/lib/components/ui/layout/list-details-layout/partials/use-list-width.d.ts +16 -0
- package/dist/lib/components/ui/layout/list-details-layout/partials/use-pane-focus.d.ts +6 -4
- package/dist/lib/components/ui/layout/navigation-bar/index.d.ts +3 -0
- package/dist/lib/components/ui/layout/navigation-bar/internal.d.ts +4 -0
- package/dist/lib/components/ui/layout/navigation-bar/navigation-bar.classes.d.ts +14 -0
- package/dist/lib/components/ui/layout/navigation-bar/navigation-bar.d.ts +35 -0
- package/dist/lib/components/ui/layout/navigation-bar/navigation-bar.utils.d.ts +19 -0
- package/dist/lib/components/ui/layout/navigation-bar/partials/bar-badge.d.ts +5 -0
- package/dist/lib/components/ui/layout/navigation-bar/partials/bar-entry.d.ts +12 -0
- package/dist/lib/components/ui/layout/navigation-bar/partials/navigation-bar-item.d.ts +22 -0
- package/dist/lib/components/ui/layout/navigation-bar/partials/navigation-bar-more.d.ts +24 -0
- package/dist/lib/components/ui/layout/navigation-bar/use-nav-bar-inset.d.ts +12 -0
- package/dist/lib/components/ui/layout/navigation-drawer/index.d.ts +5 -0
- package/dist/lib/components/ui/layout/navigation-drawer/navigation-drawer.classes.d.ts +9 -0
- package/dist/lib/components/ui/layout/navigation-drawer/navigation-drawer.d.ts +45 -0
- package/dist/lib/components/ui/layout/navigation-drawer/navigation-drawer.utils.d.ts +14 -0
- package/dist/lib/components/ui/layout/navigation-drawer/partials/navigation-drawer-body.d.ts +3 -0
- package/dist/lib/components/ui/layout/navigation-drawer/partials/navigation-drawer-item.d.ts +20 -0
- package/dist/lib/components/ui/layout/navigation-drawer/partials/navigation-drawer-modal.d.ts +17 -0
- package/dist/lib/components/ui/layout/navigation-drawer/partials/navigation-drawer-section.d.ts +15 -0
- package/dist/lib/components/ui/layout/navigation-rail/index.d.ts +3 -0
- package/dist/lib/components/ui/layout/navigation-rail/navigation-rail-panel.d.ts +26 -0
- package/dist/lib/components/ui/layout/navigation-rail/navigation-rail.classes.d.ts +23 -0
- package/dist/lib/components/ui/layout/navigation-rail/navigation-rail.d.ts +42 -1
- package/dist/lib/components/ui/layout/navigation-rail/navigation-rail.utils.d.ts +4 -0
- package/dist/lib/components/ui/layout/navigation-rail/partials/navigation-rail-body.d.ts +3 -0
- package/dist/lib/components/ui/layout/navigation-rail/partials/navigation-rail-item.d.ts +20 -0
- package/dist/lib/components/ui/layout/navigation-rail/partials/navigation-rail-panel-item.d.ts +7 -0
- package/dist/lib/components/ui/layout/navigation-rail/partials/navigation-rail-toggle.d.ts +7 -0
- package/dist/lib/components/ui/layout/navigation-rail/use-rail-expanded.d.ts +13 -0
- package/dist/lib/components/ui/layout/navigation-toolbar/index.d.ts +2 -0
- package/dist/lib/components/ui/layout/navigation-toolbar/navigation-toolbar.classes.d.ts +20 -0
- package/dist/lib/components/ui/layout/navigation-toolbar/navigation-toolbar.d.ts +51 -0
- package/dist/lib/components/ui/layout/navigation-toolbar/partials/navigation-toolbar-item.d.ts +25 -0
- package/dist/lib/components/ui/layout/navigation-toolbar/partials/navigation-toolbar-more.d.ts +3 -0
- package/dist/lib/components/ui/layout/pane-layout/internal.d.ts +3 -0
- package/dist/lib/components/ui/layout/pane-layout/pane-layout.d.ts +16 -2
- package/dist/lib/components/ui/layout/pane-layout/partials/pane-layout-classes.d.ts +7 -0
- package/dist/lib/components/ui/layout/pane-layout/partials/pane-layout-context.d.ts +13 -0
- package/dist/lib/components/ui/layout/pane-layout/partials/use-pane-layout-state.d.ts +16 -0
- package/dist/lib/components/ui/layout/pane-layout/partials/use-pane-narrow.d.ts +6 -0
- package/dist/lib/components/ui/layout/responsive-grid/index.d.ts +4 -1
- package/dist/lib/components/ui/layout/responsive-grid/responsive-grid-item.d.ts +19 -0
- package/dist/lib/components/ui/layout/responsive-grid/responsive-grid-spans.d.ts +19 -0
- package/dist/lib/components/ui/layout/responsive-grid/responsive-grid.d.ts +24 -2
- package/dist/lib/components/ui/layout/responsive-grid/responsive-grid.utils.d.ts +12 -0
- package/dist/lib/components/ui/layout/settings-layout/index.d.ts +2 -0
- package/dist/lib/components/ui/layout/settings-layout/partials/settings-link.d.ts +7 -0
- package/dist/lib/components/ui/layout/settings-layout/partials/settings-list.d.ts +11 -0
- package/dist/lib/components/ui/layout/settings-layout/partials/settings-page.d.ts +5 -0
- package/dist/lib/components/ui/layout/settings-layout/settings-layout.d.ts +10 -0
- package/dist/lib/components/ui/layout/settings-layout/settings-layout.types.d.ts +33 -0
- package/dist/lib/components/ui/layout/settings-layout/settings-layout.utils.d.ts +13 -0
- package/dist/lib/components/ui/layout/thread-layout/thread-layout-classes.d.ts +17 -0
- package/dist/lib/components/ui/layout/thread-layout/thread-layout-parts.d.ts +14 -0
- package/dist/lib/components/ui/layout/thread-layout/thread-layout-stepper.d.ts +11 -0
- package/dist/lib/components/ui/layout/thread-layout/thread-layout.d.ts +30 -3
- package/dist/lib/components/ui/layout/top-nav/index.d.ts +5 -0
- package/dist/lib/components/ui/layout/top-nav/partials/top-nav-item.d.ts +23 -0
- package/dist/lib/components/ui/layout/top-nav/partials/top-nav-menu.d.ts +22 -0
- package/dist/lib/components/ui/layout/top-nav/top-nav.classes.d.ts +10 -0
- package/dist/lib/components/ui/layout/top-nav/top-nav.d.ts +34 -0
- package/dist/lib/components/ui/layout/top-nav/top-nav.utils.d.ts +10 -0
- package/dist/lib/components/ui/widgets/kanban/index.d.ts +1 -1
- package/dist/lib/components/ui/widgets/kanban/kanban-context.d.ts +5 -2
- package/dist/lib/components/ui/widgets/kanban/kanban.d.ts +11 -2
- package/dist/lib/components/ui/widgets/kanban/kanban.slice.d.ts +32 -0
- package/dist/lib/components/ui/widgets/kanban/kanban.utils.d.ts +9 -0
- package/dist/lib/components/ui/widgets/kanban/partials/kanban-card-preview.d.ts +3 -1
- package/dist/lib/components/ui/widgets/kanban/partials/kanban-column.d.ts +6 -0
- package/dist/lib/components/ui/widgets/kanban/partials/kanban-move-to.d.ts +13 -0
- package/dist/lib/components/ui/widgets/kanban/partials/kanban-phone-tabs.d.ts +10 -0
- package/dist/lib/components/ui/widgets/kanban/types.d.ts +7 -0
- package/dist/lib/components/ui/widgets/kanban/use-kanban-board-keys.d.ts +7 -0
- package/dist/lib/components/ui/widgets/kanban/use-kanban-item-actions.d.ts +5 -0
- package/dist/lib/components/ui/widgets/kanban/use-kanban-phone-column.d.ts +18 -0
- package/dist/lib/components/ui/widgets/kanban/use-kanban.d.ts +6 -1
- package/dist/lib/i18n/resources/en/en.d.ts +50 -0
- package/dist/lib/i18n/resources/en/material.json.d.ts +52 -2
- package/dist/lib/i18n/resources/fr/fr.d.ts +50 -0
- package/dist/lib/i18n/resources/fr/material.json.d.ts +52 -2
- package/dist/lib/i18n/resources/resources.d.ts +100 -0
- package/dist/lib/i18n/translator.d.ts +1 -1
- package/dist/lib.js +1 -1
- package/dist/main.js +52 -52
- package/dist/map.js +7 -7
- package/dist/material.css +1 -1
- package/dist/pdf-reader.js +1 -1
- package/dist/{percent-field--WIXV5dX.js → percent-field-C2LNr8NA.js} +1 -1
- package/dist/{picker-surface-CV09H7Nb.js → picker-surface-BUCFMoAZ.js} +4 -4
- package/dist/{popover-Cd7DkND4.js → popover-DFRwQF12.js} +1 -1
- package/dist/{pos-types-DKCkOTYy.js → pos-types-CXnEdjdy.js} +1 -1
- package/dist/{pos-variant-GrUfbTTP.js → pos-variant-DMwn_7is.js} +4 -4
- package/dist/print.js +1 -1
- package/dist/{programmer-variant-eKJNKENL.js → programmer-variant-Bo4eiDFi.js} +2 -2
- package/dist/{public-y6g4ddxd.js → public-CyQPkkSR.js} +9 -9
- package/dist/{rich-code-block-CRQ0iyLb.js → rich-code-block-iK7UcZdc.js} +5 -5
- package/dist/{scientific-variant-2y3UxAAU.js → scientific-variant-B9ScTgfx.js} +2 -2
- package/dist/{sortable-provider-DdiI3Fwk.js → sortable-provider-BZwVjSVU.js} +3 -3
- package/dist/{spinner-C1QIewWv.js → spinner-RITOxvpH.js} +2 -2
- package/dist/{tabs-KGKvve3y.js → tabs-DSo4eCUn.js} +1 -1
- package/dist/theme-picker.js +2 -2
- package/dist/{theme-toggle-C_VeiiCm.js → theme-toggle-3gbzQX0x.js} +1 -1
- package/dist/{toolbar-items-D310xDuM.js → toolbar-items-Bt5RK-Nx.js} +4 -4
- package/dist/{translate-material-BypJJ1l5.js → translate-material-CZTGqgen.js} +1 -1
- package/dist/{translator-DJkf4J7t.js → translator-DTlOlIoq.js} +108 -4
- package/dist/{use-chat-composer-BFhRMHcX.js → use-chat-composer-DBY01IpX.js} +16 -16
- package/dist/{use-heading-spy-DJR8YYm6.js → use-heading-spy-Dt48bBts.js} +4 -4
- package/dist/{use-material-translation-CD6QoVal.js → use-material-translation-BJucC_xe.js} +1 -1
- package/dist/{use-return-focus-Cevw_6yq.js → use-return-focus-BS1JLcnq.js} +1 -1
- package/docs/README.md +1 -0
- package/docs/components/data-display.md +4 -0
- package/docs/components/navigation-and-layout.md +944 -27
- package/docs/components/rich-widgets.md +26 -0
- package/docs/guides/app-shell.md +641 -2
- package/docs/guides/i18n.md +13 -1
- package/docs/guides/layouts.md +215 -0
- package/docs/guides/ssr.md +1 -1
- package/docs/previews/navigation-layout-appshell-page-ground.webp +0 -0
- package/docs/previews/navigation-layout-appshell.webp +0 -0
- package/docs/previews/navigation-layout-authcard-split.webp +0 -0
- package/docs/previews/navigation-layout-authcard.webp +0 -0
- package/docs/previews/navigation-layout-dashboardgrid.webp +0 -0
- package/docs/previews/navigation-layout-editorlayout.webp +0 -0
- package/docs/previews/navigation-layout-landinglayout.webp +0 -0
- package/docs/previews/navigation-layout-panelayout.webp +0 -0
- package/docs/previews/navigation-layout-settingslayout.webp +0 -0
- package/docs/previews/navigation-layout-threadlayout-pages.webp +0 -0
- package/docs/previews/navigation-layout-threadlayout.webp +0 -0
- package/docs/roadmap.md +10 -2
- package/lib/components/components.css +3 -0
- package/lib/components/ui/actions/fab/fab-dock.css +19 -6
- package/lib/components/ui/layout/app-search/app-search.css +62 -0
- package/lib/components/ui/layout/app-shell/activity-backdrop.css +10 -2
- package/lib/components/ui/layout/app-shell/app-header.css +108 -0
- package/lib/components/ui/layout/navigation-toolbar/navigation-toolbar.css +43 -0
- package/package.json +1 -1
|
@@ -1,3 +1,18 @@
|
|
|
1
|
-
import { ComponentProps } from 'react';
|
|
2
|
-
export type TopAppBarProps = {
|
|
3
|
-
|
|
1
|
+
import { ComponentProps, ReactNode } from 'react';
|
|
2
|
+
export type TopAppBarProps = {
|
|
3
|
+
/**
|
|
4
|
+
* The bar's look. `'small'` (the default): one row of `children`.
|
|
5
|
+
* `'center'`: the row's content centred. `'medium'` and `'large'`: the
|
|
6
|
+
* `headline` on a second row, in display type (`'large'` a taller row and a
|
|
7
|
+
* bigger step); without a `headline` they draw as `'small'`.
|
|
8
|
+
*/
|
|
9
|
+
variant?: 'small' | 'center' | 'medium' | 'large';
|
|
10
|
+
/** The title of a `medium` or `large` bar: its second row. Make it the page's heading with an element of your own, `<h1>`. */
|
|
11
|
+
headline?: ReactNode;
|
|
12
|
+
} & ComponentProps<'div'>;
|
|
13
|
+
/**
|
|
14
|
+
* A top app bar: a row of actions and a title, in the Material 3 sizes. It
|
|
15
|
+
* does not scroll itself; `ActivityLayout`'s `header` collapses and hides the
|
|
16
|
+
* shell's own bar.
|
|
17
|
+
*/
|
|
18
|
+
export declare function TopAppBar({ variant, headline, className, children, ...props }: TopAppBarProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { AppSearchBarProps } from './app-search.types.js';
|
|
2
|
+
/**
|
|
3
|
+
* The search of the app bar. From 768px a pill (a filled, fully rounded
|
|
4
|
+
* search field) with the `results` in a panel docked under it while it is
|
|
5
|
+
* focused or typed in; on a phone a search button that opens the full-screen
|
|
6
|
+
* {@link SearchView}. The text is shared by the two, so a resize keeps it.
|
|
7
|
+
*
|
|
8
|
+
* Draw it in the shell with `ActivityLayout`'s `header={{ variant, search }}`
|
|
9
|
+
* (or a route's `handle.header`), or put it in your own bar.
|
|
10
|
+
*/
|
|
11
|
+
export declare function AppSearchBar({ value: valueProp, defaultValue, onValueChange, ...props }: AppSearchBarProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
/** What a `results` function receives. */
|
|
3
|
+
export type SearchResultsState = {
|
|
4
|
+
/** The text typed so far. */
|
|
5
|
+
value: string;
|
|
6
|
+
/** Closes the panel (desktop) or the full-screen view (phone): call it when a result is chosen. */
|
|
7
|
+
close: () => void;
|
|
8
|
+
};
|
|
9
|
+
/** What the search bar and the full-screen view share. */
|
|
10
|
+
export type AppSearchSlots = {
|
|
11
|
+
/** The field's placeholder. @default 'Search' (`material.search-field.placeholder`) */
|
|
12
|
+
placeholder?: string;
|
|
13
|
+
/** The search's accessible name: the field's, the phone button's and the view's. @default 'Search' (`material.app-header.search`) */
|
|
14
|
+
label?: string;
|
|
15
|
+
/** Enter in the field. The phone's view closes after it; the desktop's panel too. */
|
|
16
|
+
onSubmit?: (value: string) => void;
|
|
17
|
+
/**
|
|
18
|
+
* The results, drawn below the field: in a docked panel under the pill from
|
|
19
|
+
* 768px, in the full-screen view below it. A node, or a function of the
|
|
20
|
+
* text and a `close`. Unset: no panel on desktop, an empty view on a phone.
|
|
21
|
+
*/
|
|
22
|
+
results?: ReactNode | ((state: SearchResultsState) => ReactNode);
|
|
23
|
+
/** How many results there are: announced politely ("3 results") whenever it changes. Unset: nothing is announced. */
|
|
24
|
+
resultCount?: number;
|
|
25
|
+
/** A spinner in the field instead of the clear button. @default false */
|
|
26
|
+
loading?: boolean;
|
|
27
|
+
/** Controls after the field: a filters button, in the bar beside the pill and in the phone's view. */
|
|
28
|
+
trailing?: ReactNode;
|
|
29
|
+
};
|
|
30
|
+
export type AppSearchBarProps = AppSearchSlots & {
|
|
31
|
+
/** Controls the text. */
|
|
32
|
+
value?: string;
|
|
33
|
+
/** The text to start from when `value` is unset. @default '' */
|
|
34
|
+
defaultValue?: string;
|
|
35
|
+
/** Asked for every change of the text, controlled or not. */
|
|
36
|
+
onValueChange?: (value: string) => void;
|
|
37
|
+
/**
|
|
38
|
+
* A hint for the key that focuses the pill (opens the view on a phone), such
|
|
39
|
+
* as `"/"` or `"Ctrl+K"`: shown as a `Kbd` while the field is empty and set
|
|
40
|
+
* as `aria-keyshortcuts`, and bound on the document (ignored while typing in
|
|
41
|
+
* another field).
|
|
42
|
+
*/
|
|
43
|
+
shortcut?: string;
|
|
44
|
+
/** Controls before the pill (desktop only). */
|
|
45
|
+
leading?: ReactNode;
|
|
46
|
+
className?: string;
|
|
47
|
+
};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { AppSearchBarProps } from '../app-search.types.js';
|
|
2
|
+
/** The phone half of the search: a button (hidden from 768px) that opens the full-screen view. */
|
|
3
|
+
export declare function PhoneSearch({ value: valueProp, defaultValue, onValueChange, shortcut, leading: _leading, className, ...slots }: AppSearchBarProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { AppSearchBarProps } from '../app-search.types.js';
|
|
2
|
+
/** The tablet and desktop half of the search: the pill and its results panel (hidden below 768px). */
|
|
3
|
+
export declare function PillSearch({ value: valueProp, defaultValue, onValueChange, shortcut, leading, trailing, className, placeholder, label, onSubmit, results, resultCount, loading, }: AppSearchBarProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { KeyboardEvent } from 'react';
|
|
2
|
+
import { AppSearchBarProps } from './app-search.types.js';
|
|
3
|
+
/**
|
|
4
|
+
* The pill's field in a named search landmark. `onActivate` hears a click or
|
|
5
|
+
* a focus inside it (`true` for a focus), which is what opens the panel.
|
|
6
|
+
*/
|
|
7
|
+
export declare function PillForm({ name, value, onValueChange, placeholder, shortcut, loading, onSubmit, onKeyDown, onActivate, panelId, panelOpen, hasPanel, }: Pick<AppSearchBarProps, 'placeholder' | 'shortcut' | 'loading'> & {
|
|
8
|
+
name: string;
|
|
9
|
+
value: string;
|
|
10
|
+
onValueChange: (value: string) => void;
|
|
11
|
+
onSubmit: () => void;
|
|
12
|
+
onKeyDown: (event: KeyboardEvent<HTMLFormElement>) => void;
|
|
13
|
+
onActivate: (byFocus: boolean) => void;
|
|
14
|
+
/** The results panel's id, and whether there is one and it is open: the field announces it. */
|
|
15
|
+
panelId: string;
|
|
16
|
+
panelOpen: boolean;
|
|
17
|
+
hasPanel: boolean;
|
|
18
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { ReactNode, RefObject } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* The pill's docked results panel: a non-modal popover under the pill, as wide
|
|
4
|
+
* as it. Focus stays in the field; ArrowDown moves into the panel and Escape
|
|
5
|
+
* brings it back to the field (the panel renders in a portal, which Tab does
|
|
6
|
+
* not reach from the field).
|
|
7
|
+
*/
|
|
8
|
+
export declare function SearchPanel({ open, onOpenChange, anchor, barRef, barClassName, focusField, panelId, children, panelRef, }: {
|
|
9
|
+
open: boolean;
|
|
10
|
+
onOpenChange: (open: boolean) => void;
|
|
11
|
+
/** The pill: the panel opens under it, and a pointer or focus inside it does not dismiss the panel. */
|
|
12
|
+
anchor: ReactNode;
|
|
13
|
+
/** The element the panel hangs from (the bar around the pill). */
|
|
14
|
+
barRef: RefObject<HTMLDivElement | null>;
|
|
15
|
+
barClassName?: string;
|
|
16
|
+
/** Puts the focus back in the field, without opening the panel again. */
|
|
17
|
+
focusField: () => void;
|
|
18
|
+
/** The panel's id, for the field's `aria-controls`. */
|
|
19
|
+
panelId: string;
|
|
20
|
+
children: ReactNode;
|
|
21
|
+
panelRef: RefObject<HTMLDivElement | null>;
|
|
22
|
+
}): import("react").JSX.Element;
|
|
23
|
+
/** Focuses the first control in the panel; whether there was one. */
|
|
24
|
+
export declare function focusPanel(panel: HTMLElement | null): boolean;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { AppSearchSlots } from './app-search.types.js';
|
|
3
|
+
/** The `results` slot drawn: a node as it is, a function called with the text and `close`. */
|
|
4
|
+
export declare function drawResults(results: AppSearchSlots['results'], state: {
|
|
5
|
+
value: string;
|
|
6
|
+
close: () => void;
|
|
7
|
+
}): ReactNode;
|
|
8
|
+
/**
|
|
9
|
+
* The polite announcement of how many results there are. Always in the tree
|
|
10
|
+
* with the results, so a screen reader hears the change, not an insertion.
|
|
11
|
+
*/
|
|
12
|
+
export declare function ResultCount({ count }: {
|
|
13
|
+
count?: number;
|
|
14
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
type KeyLike = Pick<KeyboardEvent, 'key' | 'ctrlKey' | 'metaKey' | 'altKey' | 'shiftKey'>;
|
|
2
|
+
/**
|
|
3
|
+
* Whether a key event is the `shortcut` ("/", "Ctrl+K", "Alt+S", "mod+k":
|
|
4
|
+
* `mod` is Ctrl or Cmd). A bare character ignores Shift, which typing it may
|
|
5
|
+
* need; the named modifiers must match exactly.
|
|
6
|
+
*/
|
|
7
|
+
export declare function matchesShortcut(event: KeyLike, shortcut?: string): boolean;
|
|
8
|
+
/**
|
|
9
|
+
* Runs `onKey` when the document gets the `shortcut`. A bare key does nothing
|
|
10
|
+
* while the focus is in a field; one with Ctrl, Cmd or Alt works anywhere.
|
|
11
|
+
* `when` is asked first: a bar drawn twice (the phone's button and the pill,
|
|
12
|
+
* one hidden by CSS) lets only the visible one take the key.
|
|
13
|
+
*/
|
|
14
|
+
export declare function useSearchShortcut(shortcut: string | undefined, onKey: () => void, when?: () => boolean): void;
|
|
15
|
+
export {};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { AppSearchSlots } from './app-search.types.js';
|
|
2
|
+
export type SearchViewProps = AppSearchSlots & {
|
|
3
|
+
/** Whether the view is open. It mounts only while open, so the server draws nothing. */
|
|
4
|
+
open: boolean;
|
|
5
|
+
/** Asked for every change: Escape, the back arrow, Enter in the field. */
|
|
6
|
+
onOpenChange: (open: boolean) => void;
|
|
7
|
+
/** Controls the text. */
|
|
8
|
+
value?: string;
|
|
9
|
+
/** The text to start from when `value` is unset. @default '' */
|
|
10
|
+
defaultValue?: string;
|
|
11
|
+
/** Asked for every change of the text, controlled or not. */
|
|
12
|
+
onValueChange?: (value: string) => void;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* The phone's search: a full-screen modal dialog named by `label`, with a
|
|
16
|
+
* back arrow, the search field and the `results` below it. Focus goes to the
|
|
17
|
+
* field when it opens and returns to the element that opened it when it
|
|
18
|
+
* closes; Escape (after the clear, if the field holds text) and the back
|
|
19
|
+
* arrow close it. `AppSearchBar` opens it from a phone; use it on its own
|
|
20
|
+
* for a search button of your own.
|
|
21
|
+
*/
|
|
22
|
+
export declare function SearchView({ open, onOpenChange, value: valueProp, defaultValue, onValueChange, placeholder, label, onSubmit, results, resultCount, loading, trailing, }: SearchViewProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { KeyboardEvent } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* The state of the pill's results panel: open or not, the refs it hangs from,
|
|
4
|
+
* and the keyboard (ArrowDown opens it, then moves into it). Focus the code
|
|
5
|
+
* gives the field (`focusField`, the shortcut) is not a reason to open it.
|
|
6
|
+
*/
|
|
7
|
+
export declare function usePillPanel(hasResults: boolean): {
|
|
8
|
+
panel: boolean;
|
|
9
|
+
setPanel: import('react').Dispatch<import('react').SetStateAction<boolean>>;
|
|
10
|
+
bar: import('react').RefObject<HTMLDivElement | null>;
|
|
11
|
+
panelRef: import('react').RefObject<HTMLDivElement | null>;
|
|
12
|
+
panelId: string;
|
|
13
|
+
open: () => void;
|
|
14
|
+
close: () => void;
|
|
15
|
+
/** Puts the focus back in the field, without opening the panel. */
|
|
16
|
+
focusField(): void;
|
|
17
|
+
/** Focuses the field as the shortcut does: it does open nothing. */
|
|
18
|
+
focusFromShortcut(): void;
|
|
19
|
+
/** A click, or a focus unless the code gave it. */
|
|
20
|
+
activate(byFocus: boolean): void;
|
|
21
|
+
onKeyDown(event: KeyboardEvent<HTMLElement>): void;
|
|
22
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
type Options = {
|
|
2
|
+
value?: string;
|
|
3
|
+
defaultValue?: string;
|
|
4
|
+
onValueChange?: (value: string) => void;
|
|
5
|
+
};
|
|
6
|
+
/** The text of a search, controlled (`value`) or not, reporting every change. */
|
|
7
|
+
export declare function useSearchText({ value, defaultValue, onValueChange, }: Options): readonly [string, (next: string) => void];
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { ComponentProps, ReactNode, RefObject } from 'react';
|
|
2
|
+
import { ShellBack } from './activity-layout-navigation.types.js';
|
|
3
|
+
import { AppHeader } from './app-header.js';
|
|
4
|
+
import { ResolvedHeader } from './navigation.utils.js';
|
|
5
|
+
import { usePageTitleScope } from './page-title-scope.js';
|
|
6
|
+
type BarProps = ReturnType<typeof usePageTitleScope>;
|
|
7
|
+
/** Whether the header has a headline row: a medium or large one, with a page title to put in it. */
|
|
8
|
+
export declare const hasHeadline: (header: ResolvedHeader, pageTitle: ReactNode) => boolean;
|
|
9
|
+
/** Whether the shell's scroll has to be tracked: a bar that collapses or hides. */
|
|
10
|
+
export declare const scrollsHeader: (header: ResolvedHeader, pageTitle: ReactNode) => boolean;
|
|
11
|
+
/**
|
|
12
|
+
* Provides the scroll of the window, or of the content region (`region`), to
|
|
13
|
+
* the bar below. The provider is always in the tree, so a route that changes
|
|
14
|
+
* the header never remounts the content; with `on` false it tracks nothing
|
|
15
|
+
* (no listener, no frame), so a plain shell adds no scroll work.
|
|
16
|
+
*/
|
|
17
|
+
export declare function ActivityScroll({ on, region, children, }: {
|
|
18
|
+
on: boolean;
|
|
19
|
+
region: RefObject<HTMLElement | null> | null;
|
|
20
|
+
children: ReactNode;
|
|
21
|
+
}): import("react").JSX.Element;
|
|
22
|
+
/**
|
|
23
|
+
* The app bar of {@link ActivityLayout}, in the header variant the route
|
|
24
|
+
* resolved: a headline row carries the page's `h1` for `medium` and `large`
|
|
25
|
+
* (the small row then holds a faded copy of it), the other variants keep it in
|
|
26
|
+
* the bar.
|
|
27
|
+
*/
|
|
28
|
+
export declare function ActivityAppBar({ header, back, bar, headerTitle, hasBackdrop, ...props }: {
|
|
29
|
+
header: ResolvedHeader;
|
|
30
|
+
back?: ShellBack;
|
|
31
|
+
bar: BarProps;
|
|
32
|
+
headerTitle?: ReactNode;
|
|
33
|
+
hasBackdrop: boolean;
|
|
34
|
+
} & Omit<ComponentProps<typeof AppHeader>, 'children' | 'variant' | 'headline'>): import("react").JSX.Element | null;
|
|
35
|
+
export {};
|
|
@@ -1,10 +1,17 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
+
import { NavigationRailProps } from '../navigation-rail/navigation-rail.js';
|
|
2
3
|
import { AppSidebarProps } from './app-sidebar.js';
|
|
3
4
|
/** Under a `backdrop`: the chrome's fill, from a token (activity-backdrop.css). */
|
|
4
5
|
export declare const CHROME_FILL = "bg-(--nxgt-backdrop-fill-chrome)";
|
|
5
6
|
/** The app bar: that fill, frosted (the blur is 0 when the user asks for less
|
|
6
7
|
* transparency). */
|
|
7
8
|
export declare const CHROME_FROSTED = "bg-(--nxgt-backdrop-fill-chrome) backdrop-blur-(--nxgt-backdrop-blur)";
|
|
9
|
+
/**
|
|
10
|
+
* The sticky app bar's classes: translucent under a `backdrop` (the fill is a
|
|
11
|
+
* token, activity-backdrop.css), flat like the sidebar (no radius, no shadow,
|
|
12
|
+
* near --background).
|
|
13
|
+
*/
|
|
14
|
+
export declare const appBarClass: (hasBackdrop: boolean) => string;
|
|
8
15
|
/** The sidebar: a little more opaque than the app bar, for its text's contrast. */
|
|
9
16
|
export declare const NAV_FROSTED = "bg-(--nxgt-backdrop-fill-nav) backdrop-blur-(--nxgt-backdrop-blur)";
|
|
10
17
|
/**
|
|
@@ -13,7 +20,7 @@ export declare const NAV_FROSTED = "bg-(--nxgt-backdrop-fill-nav) backdrop-blur-
|
|
|
13
20
|
* media dock at the bottom) with a negative margin and gives it to itself as
|
|
14
21
|
* padding, so the sticky sidebar rests where it always did.
|
|
15
22
|
*/
|
|
16
|
-
export declare const RAIL_BLEED = "-mt-[max(0.5rem,env(safe-area-inset-top))] pt-[max(0.5rem,env(safe-area-inset-top))] -mb-[
|
|
23
|
+
export declare const RAIL_BLEED = "-mt-[max(0.5rem,env(safe-area-inset-top))] pt-[max(0.5rem,env(safe-area-inset-top))] -mb-[max(max(0.5rem,env(safe-area-inset-bottom)),calc(0.5rem+var(--nxgt-media-dock,0px)))] pb-[max(max(0.5rem,env(safe-area-inset-bottom)),calc(0.5rem+var(--nxgt-media-dock,0px)))] -ml-[max(0.5rem,env(safe-area-inset-left))] pl-[max(0.5rem,env(safe-area-inset-left))]";
|
|
17
24
|
/**
|
|
18
25
|
* The top gutter, above the sticky app bar, stays in the viewport and hides
|
|
19
26
|
* what the page scrolls under it: the app bar's own fill, so nothing shows in
|
|
@@ -24,18 +31,34 @@ export declare const RAIL_BLEED = "-mt-[max(0.5rem,env(safe-area-inset-top))] pt
|
|
|
24
31
|
export declare function ActivityGutterMask({ hasBackdrop }: {
|
|
25
32
|
hasBackdrop: boolean;
|
|
26
33
|
}): import("react").JSX.Element;
|
|
34
|
+
/** A lane sticks below the notch and is as tall as the viewport, clear of the home indicator and a docked player. A whole literal, so Tailwind sees it. */
|
|
35
|
+
export declare const LANE_STICKY = "sticky top-[max(0.5rem,env(safe-area-inset-top))] h-[calc(100dvh-max(0.5rem,env(safe-area-inset-top))-max(max(0.5rem,env(safe-area-inset-bottom)),calc(0.5rem+var(--nxgt-media-dock,0px))))] self-start";
|
|
27
36
|
/**
|
|
28
37
|
* The rail's lane: the fill runs the whole height of the page (the sidebar
|
|
29
38
|
* itself is sticky and only as tall as the viewport), out to the frame's edges.
|
|
30
39
|
* Translucent under a `backdrop`: the fill is a token (activity-backdrop.css).
|
|
31
40
|
* Flat, on the page's own colour: no radius, no shadow.
|
|
32
41
|
*/
|
|
33
|
-
export declare function ActivityRail({ hasBackdrop, ...sidebar }: {
|
|
42
|
+
export declare function ActivityRail({ hasBackdrop, hide, ...sidebar }: {
|
|
34
43
|
hasBackdrop: boolean;
|
|
44
|
+
/** The classes hiding the rail at the sizes it does not show. */
|
|
45
|
+
hide?: string;
|
|
35
46
|
} & Pick<AppSidebarProps, 'items' | 'brand' | 'logo' | 'name' | 'linkComponent' | 'align'>): import("react").JSX.Element;
|
|
47
|
+
/**
|
|
48
|
+
* The lane of the wide navigation rail (`navigation="rail-expanded"`), filled
|
|
49
|
+
* and bled to the frame's edges like {@link ActivityRail}'s. The rail itself
|
|
50
|
+
* sticks below the notch and is as tall as the viewport.
|
|
51
|
+
*/
|
|
52
|
+
export declare function ActivityNavRail({ hasBackdrop, hide, ...rail }: {
|
|
53
|
+
hasBackdrop: boolean;
|
|
54
|
+
/** The classes hiding the rail at the sizes it does not show. */
|
|
55
|
+
hide?: string;
|
|
56
|
+
} & Pick<NavigationRailProps, 'items' | 'linkComponent' | 'fab' | 'defaultExpanded' | 'persistKey' | 'onExpandedChange'>): import("react").JSX.Element;
|
|
36
57
|
/** The frame around the rail and the column, under the gutter mask (a page that scrolls itself needs one). */
|
|
37
|
-
export declare function ActivityFrame({ contained, hasBackdrop, children, }: {
|
|
58
|
+
export declare function ActivityFrame({ contained, hasBackdrop, bar, children, }: {
|
|
38
59
|
contained: boolean;
|
|
39
60
|
hasBackdrop: boolean;
|
|
61
|
+
/** Whether a bottom navigation bar is configured. */
|
|
62
|
+
bar?: boolean;
|
|
40
63
|
children: ReactNode;
|
|
41
64
|
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ActivityLayoutProps } from './activity-layout.types.js';
|
|
2
|
+
declare const COLUMN_KEYS: readonly ["context", "headerTitle", "titleAfter", "headerContext", "breadcrumb", "breadcrumbRoot", "headerActions", "avatar", "menuOpen", "onMenuOpenChange", "keepClear"];
|
|
3
|
+
type ColumnKey = (typeof COLUMN_KEYS)[number];
|
|
4
|
+
export type ColumnOwnProps = Pick<ActivityLayoutProps, ColumnKey>;
|
|
5
|
+
/**
|
|
6
|
+
* The props only the content column reads (its header, breadcrumb and
|
|
7
|
+
* clearing), apart from the rest: `ActivityLayout` hands them on without
|
|
8
|
+
* naming each, and the rest goes to the root element.
|
|
9
|
+
*/
|
|
10
|
+
export declare function splitColumnProps<P extends Partial<ColumnOwnProps>>(props: P): {
|
|
11
|
+
column: Partial<ColumnOwnProps>;
|
|
12
|
+
rest: Omit<P, ColumnKey>;
|
|
13
|
+
};
|
|
14
|
+
declare const RAIL_KEYS: readonly ["navigationFab", "sidebarExpanded", "defaultSidebarExpanded", "onSidebarExpandedChange"];
|
|
15
|
+
type RailKey = (typeof RAIL_KEYS)[number];
|
|
16
|
+
export type RailOwnProps = Pick<ActivityLayoutProps, RailKey>;
|
|
17
|
+
/** The props only the navigation lanes read (the FAB, the sidebar's state), apart from the rest. */
|
|
18
|
+
export declare function splitRailProps<P extends Partial<RailOwnProps>>(props: P): {
|
|
19
|
+
rails: RailOwnProps;
|
|
20
|
+
rest: Omit<P, RailKey>;
|
|
21
|
+
};
|
|
22
|
+
export {};
|
|
@@ -1,17 +1,25 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import { ActivityLayoutProps } from './activity-layout.types.js';
|
|
3
|
-
type ColumnProps = Pick<ActivityLayoutProps, 'items' | 'brand' | 'logo' | 'name' | 'context' | 'headerTitle' | 'titleAfter' | 'headerContext' | 'breadcrumb' | 'breadcrumbRoot' | 'headerActions' | 'avatar' | 'linkComponent' | 'menuOpen' | 'onMenuOpenChange' | 'routeTransition' | 'backdrop' | 'keepClear'> & {
|
|
3
|
+
type ColumnProps = Pick<ActivityLayoutProps, 'items' | 'brand' | 'logo' | 'name' | 'context' | 'headerTitle' | 'titleAfter' | 'headerContext' | 'breadcrumb' | 'breadcrumbRoot' | 'headerActions' | 'avatar' | 'linkComponent' | 'menuOpen' | 'onMenuOpenChange' | 'routeTransition' | 'backdrop' | 'keepClear' | 'header'> & {
|
|
4
4
|
/** The element of the content region. */
|
|
5
5
|
as: 'main' | 'div';
|
|
6
6
|
contained: boolean;
|
|
7
7
|
/** Whether a backdrop is drawn, and whether it is the theme's. */
|
|
8
8
|
hasBackdrop: boolean;
|
|
9
9
|
themeBackdrop: boolean;
|
|
10
|
+
/** Whether the app bar has the phone's menu button. */
|
|
11
|
+
showMenu?: boolean;
|
|
12
|
+
/** The classes hiding the top navigation where it does not show; undefined: none in the header. */
|
|
13
|
+
topNav?: string;
|
|
14
|
+
/** The floating navigation toolbar, inside the scroll's provider so it reads the shell's scroll; it is fixed to the viewport. */
|
|
15
|
+
floating?: ReactNode;
|
|
16
|
+
/** Whether the shell's scroll is tracked for it (it hides on scroll). */
|
|
17
|
+
trackScroll?: boolean;
|
|
10
18
|
children?: ReactNode;
|
|
11
19
|
};
|
|
12
20
|
/**
|
|
13
21
|
* The content column of {@link ActivityLayout}: the backdrop layer behind, the
|
|
14
22
|
* app bar, the breadcrumb and the routed content region.
|
|
15
23
|
*/
|
|
16
|
-
export declare function ActivityColumn({ as, contained, hasBackdrop, themeBackdrop,
|
|
24
|
+
export declare function ActivityColumn({ as, contained, hasBackdrop, themeBackdrop, headerTitle, titleAfter, headerContext, breadcrumb, breadcrumbRoot, headerActions, avatar, routeTransition, backdrop, keepClear, showMenu, topNav, floating, trackScroll, header, children, ...menu }: ColumnProps): import("react").JSX.Element;
|
|
17
25
|
export {};
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { AppSearchBarProps } from '../app-search/app-search.types.js';
|
|
3
|
+
/**
|
|
4
|
+
* How the shell's navigation is drawn at one window size.
|
|
5
|
+
*
|
|
6
|
+
* The shell draws `'modal-drawer'` (the phone's menu sheet), `'rail'` (the
|
|
7
|
+
* collapsed sidebar rail), `'rail-expanded'` (the navigation rail, wide, with a
|
|
8
|
+
* menu button to narrow it; neither rail is drawn on a phone, which keeps its
|
|
9
|
+
* menu sheet), `'drawer'` (the permanent navigation drawer),
|
|
10
|
+
* `'sidebar'` (the sidebar, with a chevron button that expands and collapses it),
|
|
11
|
+
* `'top'` (the navigation bar in the app header, with dropdowns; not on a
|
|
12
|
+
* phone, which keeps its menu sheet and nests the children there),
|
|
13
|
+
* `'two-level'` (the navigation rail of the top-level entries and, beside it, a
|
|
14
|
+
* panel listing the current entry's children; not on a phone either),
|
|
15
|
+
* `'floating'` (the navigation toolbar: a pill of icon links at the bottom
|
|
16
|
+
* centre, over the content; unlike those it is drawn on a phone too, as the
|
|
17
|
+
* bar is), `'bar'` (the bottom bar: a name alone draws it on a phone only, and from
|
|
18
|
+
* 768px the default rail shows) and `'none'`.
|
|
19
|
+
*/
|
|
20
|
+
export type ShellNavigation = 'modal-drawer' | 'rail' | 'rail-expanded' | 'drawer' | 'sidebar' | 'bar' | 'top' | 'two-level' | 'floating' | 'none';
|
|
21
|
+
/** The navigation per window size: phone below `md` (768px), tablet from `md` to `xl` (1280px), desktop from `xl`. */
|
|
22
|
+
export type ShellNavigationOptions = {
|
|
23
|
+
/** Below 768px. @default 'modal-drawer' */
|
|
24
|
+
phone?: ShellNavigation;
|
|
25
|
+
/** From 768px to 1279px. @default 'rail' */
|
|
26
|
+
tablet?: ShellNavigation;
|
|
27
|
+
/** From 1280px. @default 'rail' */
|
|
28
|
+
desktop?: ShellNavigation;
|
|
29
|
+
/** Whether the `'floating'` toolbar slides away while scrolling down and comes back on the way up. No other preset reads it. @default false */
|
|
30
|
+
hideOnScroll?: boolean;
|
|
31
|
+
/** Keeps the `'rail-expanded'` rail's, the `'sidebar'`'s and the `'two-level'` panel's open or narrow state in the browser under this key (read after hydration). Unset: the rail starts expanded, the sidebar collapsed and the panel open every time. */
|
|
32
|
+
persistKey?: string;
|
|
33
|
+
};
|
|
34
|
+
/** The shell header's look. */
|
|
35
|
+
export type ShellHeaderVariant = 'small' | 'center' | 'medium' | 'large' | 'none';
|
|
36
|
+
/**
|
|
37
|
+
* A route's back arrow (`handle.back`): `{ to, label }` links to `to` and is
|
|
38
|
+
* named "Back to <label>" ("Back" without one); `true` goes back in the
|
|
39
|
+
* history, or up one level when the route is the first page of the visit.
|
|
40
|
+
*/
|
|
41
|
+
export type ShellBack = true | {
|
|
42
|
+
to: string;
|
|
43
|
+
label?: string;
|
|
44
|
+
};
|
|
45
|
+
/** The header, with its options. */
|
|
46
|
+
export type ShellHeaderOptions = {
|
|
47
|
+
variant: ShellHeaderVariant;
|
|
48
|
+
/** Whether a `medium` or `large` header collapses to the small one while scrolling. @default true for 'medium' and 'large' */
|
|
49
|
+
collapse?: boolean;
|
|
50
|
+
/** Whether the header slides away while scrolling down. @default false */
|
|
51
|
+
hideOnScroll?: boolean;
|
|
52
|
+
/**
|
|
53
|
+
* Tabs under the header: a `TabsNav` (route links). The row is stuck to the
|
|
54
|
+
* bar: it stays under a `medium` or `large` one as it collapses, and stays
|
|
55
|
+
* pinned at the top of the window when `hideOnScroll` slides the bar away.
|
|
56
|
+
* A route's `handle.header.tabs` replaces the layout's; `tabs: null` drops
|
|
57
|
+
* them for that route. A header of `'none'` draws none.
|
|
58
|
+
* @default undefined (no tabs)
|
|
59
|
+
*/
|
|
60
|
+
tabs?: ReactNode;
|
|
61
|
+
/**
|
|
62
|
+
* A search in the app bar: a pill from 768px, a button opening a full-screen
|
|
63
|
+
* view on a phone (`AppSearchBar`). `true`: an uncontrolled one with no
|
|
64
|
+
* results; an object sets its props (`value`, `onSubmit`, `results`…).
|
|
65
|
+
* @default undefined (no search)
|
|
66
|
+
*/
|
|
67
|
+
search?: boolean | AppSearchBarProps;
|
|
68
|
+
};
|
|
69
|
+
/** The props `ActivityLayout` takes to choose its navigation and its header. */
|
|
70
|
+
export type ActivityLayoutNavigationProps = {
|
|
71
|
+
/**
|
|
72
|
+
* The navigation: one preset for every window size, or one per size.
|
|
73
|
+
* Unset: the phone's menu sheet (`'modal-drawer'`), the rail from 768px.
|
|
74
|
+
*/
|
|
75
|
+
navigation?: ShellNavigation | ShellNavigationOptions;
|
|
76
|
+
/**
|
|
77
|
+
* The header: a variant, or the variant with its options. Unset: `'small'`.
|
|
78
|
+
*/
|
|
79
|
+
header?: ShellHeaderVariant | ShellHeaderOptions;
|
|
80
|
+
/**
|
|
81
|
+
* The screen's primary action, drawn at the top of the `'rail-expanded'`
|
|
82
|
+
* rail: a `Fab`, or a function that receives `{ expanded }` to pass an
|
|
83
|
+
* extended one. Not drawn by the other presets.
|
|
84
|
+
*/
|
|
85
|
+
navigationFab?: ReactNode | ((state: {
|
|
86
|
+
expanded: boolean;
|
|
87
|
+
}) => ReactNode);
|
|
88
|
+
/** Controls the `'sidebar'`: expanded (labels beside the icons) while true. */
|
|
89
|
+
sidebarExpanded?: boolean;
|
|
90
|
+
/** The `'sidebar'`'s state to start from, before a saved choice (`navigation.persistKey`) is read. @default false */
|
|
91
|
+
defaultSidebarExpanded?: boolean;
|
|
92
|
+
/** Asked for every change of the `'sidebar'`'s state, controlled or not. */
|
|
93
|
+
onSidebarExpandedChange?: (expanded: boolean) => void;
|
|
94
|
+
};
|
|
@@ -14,5 +14,12 @@ export type { ActivityLayoutProps } from './activity-layout.types.js';
|
|
|
14
14
|
* scrollbar (a page a few pixels too wide) and `100lvh` the height behind a
|
|
15
15
|
* phone's toolbar (the bottom of the screen hidden). The bottom keeps clear
|
|
16
16
|
* of a `MediaPlayerHost`'s docked bar (`--nxgt-media-dock`).
|
|
17
|
+
*
|
|
18
|
+
* `navigation` is resolved by resolveNavigation(): the presets drawn so far are
|
|
19
|
+
* the modal drawer, the rail, the wide rail, the sidebar, the drawer, the top
|
|
20
|
+
* bar, the two-level navigation, the floating toolbar, the bar and none; the others draw what their size has by default.
|
|
21
|
+
* `header` is resolved in the column, with the route's `handle.header`: its
|
|
22
|
+
* variants and its `search` and `tabs` are drawn; the route's `handle.back` draws a back
|
|
23
|
+
* arrow.
|
|
17
24
|
*/
|
|
18
|
-
export declare function ActivityLayout({ items, brand, logo, name,
|
|
25
|
+
export declare function ActivityLayout({ items, brand, logo, name, linkComponent, contentAs: Content, scroll, align, routeTransition, backdrop, navigation, header, children, className, ...others }: ActivityLayoutProps): import("react").JSX.Element;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ComponentProps, ReactNode } from 'react';
|
|
2
|
+
import { ActivityLayoutNavigationProps } from './activity-layout-navigation.types.js';
|
|
2
3
|
import { AppBreadcrumbRoot } from './app-breadcrumb.js';
|
|
3
4
|
import { RouteTransition } from './route-transition.js';
|
|
4
5
|
import { AppLogo, AppShellLinkComponent, MenuItem } from './types.js';
|
|
@@ -141,4 +142,4 @@ export type ActivityLayoutProps = {
|
|
|
141
142
|
* See the app shell guide, "Keep the backdrop clear of the content".
|
|
142
143
|
*/
|
|
143
144
|
keepClear?: boolean | 'gaps';
|
|
144
|
-
} & ComponentProps<'div'>;
|
|
145
|
+
} & ActivityLayoutNavigationProps & ComponentProps<'div'>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { RailOwnProps } from './activity-column-props.js';
|
|
2
|
+
import { ActivityLayoutProps } from './activity-layout.types.js';
|
|
3
|
+
import { ShellParts } from './navigation-parts.js';
|
|
4
|
+
/**
|
|
5
|
+
* The navigation lanes before the column: the collapsed sidebar rail
|
|
6
|
+
* (`'rail'`), the collapsible sidebar (`'sidebar'`), the permanent drawer
|
|
7
|
+
* (`'drawer'`), the two-level rail and panel (`'two-level'`) and the wide
|
|
8
|
+
* navigation rail (`'rail-expanded'`), each hidden by breakpoint classes where its size has
|
|
9
|
+
* another preset.
|
|
10
|
+
*/
|
|
11
|
+
export declare function ActivityRails({ parts, items, brand, logo, name, linkComponent, hasBackdrop, align, rails, }: Pick<ActivityLayoutProps, 'items' | 'brand' | 'logo' | 'name' | 'linkComponent' | 'align'> & {
|
|
12
|
+
/** The FAB and the `'sidebar'` lane's state props. */
|
|
13
|
+
rails: RailOwnProps;
|
|
14
|
+
parts: ShellParts;
|
|
15
|
+
hasBackdrop: boolean;
|
|
16
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ActivityLayoutProps } from './activity-layout.types.js';
|
|
2
|
+
import { AppSidebarProps } from './app-sidebar.js';
|
|
3
|
+
/** The key the sidebar's state is kept under, beside the rail's. */
|
|
4
|
+
export declare const SIDEBAR_STORAGE_PREFIX = "nxgt-sidebar:";
|
|
5
|
+
type LaneProps = {
|
|
6
|
+
hasBackdrop: boolean;
|
|
7
|
+
/** The classes hiding the lane at the sizes it does not show. */
|
|
8
|
+
hide?: string;
|
|
9
|
+
};
|
|
10
|
+
/** The lane of the permanent navigation drawer (`navigation="drawer"`), filled and bled to the frame's edges like the rail's. */
|
|
11
|
+
export declare function ActivityDrawerLane({ hasBackdrop, hide, ...drawer }: LaneProps & Pick<ActivityLayoutProps, 'items' | 'linkComponent'> & Pick<AppSidebarProps, 'brand'>): import("react").JSX.Element;
|
|
12
|
+
/**
|
|
13
|
+
* The lane of the collapsible sidebar (`navigation="sidebar"`): the app's
|
|
14
|
+
* sidebar, with a chevron button on its end edge that collapses it to icons and expands
|
|
15
|
+
* it again. The state is `sidebarExpanded` (controlled) or
|
|
16
|
+
* `defaultSidebarExpanded` (collapsed), and with a `persistKey` the last choice is read
|
|
17
|
+
* after hydration.
|
|
18
|
+
*/
|
|
19
|
+
export declare function ActivitySidebarLane({ hasBackdrop, hide, persistKey, sidebarExpanded, defaultSidebarExpanded, onSidebarExpandedChange, align, ...sidebar }: LaneProps & Pick<ActivityLayoutProps, 'sidebarExpanded' | 'defaultSidebarExpanded' | 'onSidebarExpandedChange'> & Pick<AppSidebarProps, 'items' | 'brand' | 'logo' | 'name' | 'linkComponent' | 'align'> & {
|
|
20
|
+
persistKey?: string;
|
|
21
|
+
}): import("react").JSX.Element;
|
|
22
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ActivityLayoutProps } from './activity-layout.types.js';
|
|
2
|
+
/**
|
|
3
|
+
* The top navigation in the app header (`navigation="top"`): the app's brand,
|
|
4
|
+
* which no rail carries then, and the bar of destinations. Hidden by
|
|
5
|
+
* breakpoint classes at the sizes that have another preset, so the server and
|
|
6
|
+
* the browser draw the same markup.
|
|
7
|
+
*/
|
|
8
|
+
export declare function ActivityTopNav({ items, brand, logo, name, linkComponent, hide, }: Pick<ActivityLayoutProps, 'items' | 'brand' | 'logo' | 'name' | 'linkComponent'> & {
|
|
9
|
+
/** The classes hiding the bar at the sizes it does not show; undefined: no top navigation. */
|
|
10
|
+
hide?: string;
|
|
11
|
+
}): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ActivityLayoutProps } from './activity-layout.types.js';
|
|
2
|
+
/**
|
|
3
|
+
* The lane of the two-level navigation (`navigation="two-level"`): the
|
|
4
|
+
* navigation rail with the top-level entries, then the section panel listing
|
|
5
|
+
* the current entry's children, filled and bled to the frame's edges like the
|
|
6
|
+
* other lanes. The panel is open by default and folds to a button; with a
|
|
7
|
+
* `persistKey` its state is remembered under `nxgt-panel:<key>`.
|
|
8
|
+
*/
|
|
9
|
+
export declare function ActivityTwoLevelLane({ items, brand, logo, name, linkComponent, hasBackdrop, hide, persistKey, }: Pick<ActivityLayoutProps, 'items' | 'brand' | 'logo' | 'name' | 'linkComponent'> & {
|
|
10
|
+
hasBackdrop: boolean;
|
|
11
|
+
/** The classes hiding the lane at the sizes it does not show. */
|
|
12
|
+
hide?: string;
|
|
13
|
+
persistKey?: string;
|
|
14
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { ShellBack } from './activity-layout-navigation.types.js';
|
|
2
|
+
import { AppShellLinkComponent } from './types.js';
|
|
3
|
+
/**
|
|
4
|
+
* The path one level up: `/projects/atlas` is `/projects`, `/projects` is
|
|
5
|
+
* `/`.
|
|
6
|
+
*/
|
|
7
|
+
export declare const parentPath: (pathname: string) => string;
|
|
8
|
+
/**
|
|
9
|
+
* The route's back arrow (`handle.back`), at the start of the app bar: a 48px
|
|
10
|
+
* target named "Back" or "Back to <label>".
|
|
11
|
+
*
|
|
12
|
+
* `{ to }` is a link, drawn with the shell's link component (React Router's by
|
|
13
|
+
* default), so it can be opened in a new tab. `true` is a button: the
|
|
14
|
+
* history's previous entry when the visit has one (`location.key` is not
|
|
15
|
+
* `'default'`), the parent path (`parentPath`: the URL minus its last
|
|
16
|
+
* segment) when this page opened the visit, so the arrow never leaves the
|
|
17
|
+
* app.
|
|
18
|
+
*/
|
|
19
|
+
export declare function AppBack({ back, linkComponent, }: {
|
|
20
|
+
back: ShellBack;
|
|
21
|
+
linkComponent?: AppShellLinkComponent;
|
|
22
|
+
}): import("react").JSX.Element;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { AppHeaderProps } from './app-header.js';
|
|
2
|
+
/** The bar's one row: the menu, the top navigation, the titles, the actions and the account. */
|
|
3
|
+
export declare function AppHeaderRow({ items, linkComponent, children, topNav, actions, avatar, search, back, brand, logo, name, context, menuOpen, onMenuOpenChange, showMenuIcon, }: Omit<AppHeaderProps, 'className' | 'variant' | 'collapse' | 'hideOnScroll' | 'headline' | 'tabs'>): import("react").JSX.Element;
|