A custom implementation for the main AppBar
within the Layout
that will
be used instead of the default LayoutAppBar
if it is not undefined
.
This means that if you don't want to use an AppBar
at all in your
application, set this value to null
.
Using this prop will make the following props do nothing:
appBarProps
customTitle
title
titleProps
Any additional props to provide to the default LayoutAppBar
A custom implementation for the button that closes the toggleable layouts.
If this is not undefined
, it will be used instead of the default
implementation.
The default implementation for this component will be to only render for toggleable layouts and close the navigation panel once clicked.
Using this prop will make the closeNavProps
do nothing.
Any additional props to provide to the default
LayoutCloseNavigationButton
component.
A custom implementation for the main AppBarTitle
within the Layout
that
will be used instead of the default LayoutAppBarTitle
if it is not
undefined
. This means that if you don't want to have a title within the
main AppBar
, set this value to null
.
Using this prop will make the following props do nothing:
title
titleProps
A custom implementation for the main mini navigation component within the
Layout
. If this is not undefined
, it will be used instead of the
default implementation.
Using this prop will make the following props do nothing for the mini nav:
navProps
navHeader
navHeaderProps
navHeaderTitle
navHeaderTitleProps
closeNav
closeNavProps
treeProps
A custom implementation for the main navigation component within the
Layout
. If this is not undefined
, it will be used instead of the
default implementation.
Using this prop will make the following props do nothing:
navProps
navHeader
navHeaderProps
navHeaderTitle
navHeaderTitleProps
closeNav
closeNavProps
treeProps
A custom implementation for the main navigation component's header element
within the Layout
. If this is not undefined
, it will be used instead of
the default implementation.
Using this prop will make the following props do nothing:
navHeaderProps
navHeaderTitle
navHeaderTitleProps
closeNav
closeNavProps
Any additional props to provide to the default LayoutNavigation
component.
An optional title to display within the LayoutNavigation
's header
component. This will be defaulted to being wrapped with an AppBarTitle
component for additional styling.
Any additional props to provide to the AppBarTitle
surrounding the
navHeaderTitle
.
Any additional props to provide to the default LayoutNavigation
.
An optional custom nav toggle to use within the Layout
or LayoutAppBar
instead of the default implementation.
Any optional props to provide to the default LayoutNavToggle
implementation.
An optional main title to display in the Layout
. This should normally be
something like the page title since it will be rendered in the default
AppBar
for the Layout
.
Any additional props that should be applied to the layout's default
AppBarTitle
.
This is the most important prop within the Layout
if you want to have a
navigation tree. This prop should normally be created by using the
useLayoutNavigation
hook but you can always provide any additional props
that are required to style or customize your tree.
Example:
<Layout
treeProps={useLayoutNavigation(navItems, window.location.pathname)}
{...props}
/>
or with additional props:
<Layout
treeProps={{
...useLayoutNavigation(navItems, window.location.pathname),
...otherTreeProps
}}
{...props}
/>
Please see the useLayoutNavigation
hook for additional documentation.
Generated using TypeDoc
Since the layout is a combination of multiple nested configurable components, it can be annoying to have to apply multiple levels of prop configurations to this root component. The main
Layout
flattens some of these props and components if this is preferable.Example: