blob: 38969de86e88a9a68ec9210540317aa85d11e460 (
plain)
| 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
 | import {
  type ForwardRefRenderFunction,
  type HTMLAttributes,
  type ReactNode,
  forwardRef,
} from 'react';
export type NavProps = HTMLAttributes<HTMLElement> & {
  /**
   * The nav contents.
   */
  children: ReactNode;
};
const NavWithRef: ForwardRefRenderFunction<HTMLElement, NavProps> = (
  props,
  ref
) => <nav {...props} ref={ref} />;
/**
 * Nav component.
 */
export const Nav = forwardRef(NavWithRef);
 |