UNPKG

@intility/bifrost-react

Version:

React library for Intility's design system, Bifrost.

55 lines (54 loc) 1.86 kB
import { type NavTopProps } from "./Nav.Top.js"; import { type NavSideProps } from "./Nav.Side.js"; import { type NavMobileProps } from "./Nav.Mobile.js"; import type { PropsFor } from "../../types.js"; export type NavProps = PropsFor<"main", { /** Top nav content */ top?: React.ReactNode; /** Top bar props */ topProps?: Partial<Omit<NavTopProps, "children">>; /** Side nav content */ side?: React.ReactNode; /** Side nav props */ sideProps?: Partial<Omit<NavSideProps, "children">>; /** Mobile fullscreen nav content (optional, defaults to side content) */ mobile?: React.ReactNode; /** Mobile nav props */ mobileProps?: Omit<NavMobileProps, "children">; /** * Custom logo, overrides `appName`, `logoHref`, and `logoOnClick` * @example * logo="App Name" * @example * logo={ * <a href="/" className="bf-neutral-link"> * <Nav.Logo logo="logo.svg"> * App Name * </Nav.Logo> * </a> * } */ logo: React.ReactNode; /** @deprecated since 6.2 */ hideBranding?: boolean; /** * Wrap content in a generic `<div>` instead of `<main>` (default). Only * useful if you wrap your app content in landmark elements like `<header>`, * `<main>`, and `<footer>`. ALso note that `top` content is placed inside a * `<header>`. * @example * <Nav noMain top={...} side={...}> * <main>[the rest of your app here]</main> * <footer>...</footer> * </Nav> * @example * <Nav noMain side={...}> * <header>...</header> * <main>[the rest of your app here]</main> * <footer>...</footer> * </Nav> */ noMain?: boolean; }>; declare const Nav: import("react").ForwardRefExoticComponent<NavProps & import("react").RefAttributes<HTMLElement>>; export default Nav;