@navinc/base-react-components
Version:
Nav's Pattern Library
47 lines (28 loc) • 892 B
Markdown
# List
```
<List
element="ul"
>
<ListItem bold>First Li Child</ListItem>
<ListItem light>Second Li Child</ListItem>
<ListItem size="sm">Third Li Child</ListItem>
</List>
```
The List component for ordered or unordered lists.
## Props
### `element`
The `element` prop determines the list style type (e.g. a bullet or number). The default is an unordered list.
### `children`
It is recommended to use the `ListItem` component as the li child of `List`
# ListItem
```
<ListItem bold>First Li Child</ListItem>
```
The `ListItem` component uses the nav's styleguide for styling the html `li` element.
## Props
### `bold`
The `bold` is a boolean prop for adjusting the weight of the `li`
### `light`
The `light` is a boolean prop for adjusting the weight of the `li`
### `size`
The `size` adjusts the font-size of the `li` options are `md`, `sm`, `xs` and `xxs`