Skip to main content

WideList: React

WideLists represent a set of items displayed in a way to organize related information.

Installation

Before you can start using the @mediahuis/chameleon-react component, you’ll need to install it, for more information check: Getting started for developers.

With that done, you’re now ready to implement the component in your application.

import { WideList, WideListItem } from '@mediahuis/chameleon-react';

export default function Example() {
return (
<WideList>
<WideListItem title="Item 1" />
<WideListItem title="Item 2" />
</WideList>
);
}

WideList Properties

PropertyTypeDefaultRequiredDescription
childrenReactNode-NoChildren displayed within the WideList (WideListItem).

WideListItem Properties

PropertyTypeDefaultRequiredDescription
actionReactNode-NoContents displayed on the right. Will not be shown when clickable is also true.
avatarString-NoControls the Avatar's src prop.
clickableBoolean-NoIf clickable is set to true, the WideListItem will show a hover state.
descriptionReactNode-NoThe text written under the title.
iconLeftElementType-NoControls the as prop of the Icon on the left side.
iconRightElementType-NoControls the as prop of the Icon on the right side.
loadingBoolean-NoShow a loading state (e.g. while fetching data).
titleReactNode-NoThe text written at the top of the component.