common-intellisense
Version:
102 lines (101 loc) • 3.5 kB
JSON
{
"props": [
{
"Attribute": "children",
"Type": "`ReactNode[]`",
"Description": "The children to render. Usually navbar elements such as `NavbarBrand`, `NavbarContent` and `NavbarItem`",
"Default": "-"
},
{
"Attribute": "height",
"Type": "`string` | `number`",
"Description": "The height of the navbar.",
"Default": "`4rem` (64px)"
},
{
"Attribute": "position",
"Type": "`static` | `sticky`",
"Description": "The position of the navbar.",
"Default": "`sticky`"
},
{
"Attribute": "maxWidth",
"Type": "`sm` | `md` | `lg` | `xl` | `2xl` | `full`",
"Description": "The max width of the navbar wrapper.",
"Default": "`lg`"
},
{
"Attribute": "parentRef",
"Type": "`React.RefObject<HTMLElement>`",
"Description": "The parent element where the navbar is placed within. This is used to determine the scroll position and whether the navbar should be hidden or not.",
"Default": "`window`"
},
{
"Attribute": "isBordered",
"Type": "`boolean`",
"Description": "Whether the navbar should have a bottom border or not.",
"Default": "`false`"
},
{
"Attribute": "isBlurred",
"Type": "`boolean`",
"Description": "Whether the navbar should have a blur effect or not.",
"Default": "`true`"
},
{
"Attribute": "isMenuOpen",
"Type": "`boolean`",
"Description": "Indicates if the navbar menu is open. (controlled)",
"Default": "`false`"
},
{
"Attribute": "isMenuDefaultOpen",
"Type": "`boolean`",
"Description": "Indicates if the navbar menu is open by default. (uncontrolled)",
"Default": "`false`"
},
{
"Attribute": "shouldHideOnScroll",
"Type": "`boolean`",
"Description": "Indicates if the navbar should hide on scroll.",
"Default": "`false`"
},
{
"Attribute": "motionProps",
"Type": "[MotionProps](#motion-props)",
"Description": "The motion props to controle the `visible` / `hidden` animation. This motion is only available if the `shouldHideOnScroll` prop is set to `true`.",
"Default": "-"
},
{
"Attribute": "disableScrollHandler",
"Type": "`boolean`",
"Description": "Whether the navbar parent scroll event should be listened to or not.",
"Default": "`false`"
},
{
"Attribute": "disableAnimation",
"Type": "`boolean`",
"Description": "Whether the navbar menu animation should be disabled or not.",
"Default": "`false`"
},
{
"Attribute": "classNames",
"Type": "`Record<\"base\"| \"wrapper\"| \"brand\"| \"content\"| \"item\"| \"toggle\"| \"toggleIcon\"| \"menu\"| \"menuItem\", string>`",
"Description": "Allows to set custom class names for the navbar slots.",
"Default": "-"
}
],
"link": "https://nextui.org/docs/components/navbar",
"events": [
{
"Attribute": "onMenuOpenChange",
"Type": "`(isOpen: boolean) => void`",
"Description": "Handler that is called when the navbar menu open state changes."
},
{
"Attribute": "onScrollPositionChange",
"Type": "`(position: number) => void`",
"Description": "Handler that is called when the navbar parent element is scrolled. This event is only dispatched if `disableScrollHandler` is set to `false` or `shouldHideOnScroll` is set to `true`."
}
]
}