You are currently viewing outdated (<=3.x) Chameleon documentation on our old website. For version >=4.x, check out our new website.

Current release: 3.5.0 | hub

components

List (code)

Lists allow a visual representation of the start of a new area of content.

  • Do the dishes
  • Hang the laundy
  • Cuddle with the cats
import { List } from '@mediahuis/chameleon-react'

Props

List

NameTypeDefaultRequiredDescription
as'ul''ol''ul'-Sets the List's html element. And visual appearance.
childrenNode--Contents displayed within the List (Typically ListItem).

System Props

System Props

Next to the properties listed in the propstable, a collection of system props can be added to any component for further general styling and layouting purposes. These props vary per component.

To read more about the system, click here to check out its dedicated page.

ListItem

NameTypeDefaultRequiredDescription
accessibilityLabelString''-Accessible friendly label. Will not be shown
childrenNode--The content rendered within the ListItem
iconFunctionNodeObject--The icon from the system.
iconColorString--The color of the icon, based on tokens of the system.

System Props

This component does not allow any system props.

System Props

Next to the properties listed in the propstable, a collection of system props can be added to any component for further general styling and layouting purposes. These props vary per component.

To read more about the system, click here to check out its dedicated page.

As

default: ul

Lists come in both unordered and ordered variants. Changing the as prop will switch functionality.

  • Do the dishes
  • Hang the laundy
  • Cuddle with the cats
  1. Do the dishes
  2. Hang the laundy
  3. Cuddle with the cats

Icon

default: Bullet

Icons of a ListItem can be variated throughout a single list.

  • Do the dishes
  • Hang the laundy
  • Cuddle with the cats

IconColor

default: undefined

To further emphasize an icon's meaning, you can convey further information by changing its color.

  • Do the dishes
  • Hang the laundy
  • Cuddle with the cats

© Copyright 2020 Mediahuis NV. All rights Reserved