List Style Type

Utilities for controlling the style of a list.

React propsCSS Properties
listStyleType={type}list-style-type: {type};

Usage

To create custom lists, use the listStyleType={type} utilities.

{/* inline styles required to override smooth-doc */} <x.ul listStyleType="disc" style="list-style-type: disc"> <li>Lorem ipsum ...</li> </x.ul> <x.ul listStyleType="decimal" style="list-style-type: decimal"> <li>Lorem ipsum ...</li> </x.ul> <x.ul listStyleType="circle" style="list-style-type: circle"> <li>Lorem ipsum ...</li> </x.ul> <x.ul listStyleType="square" style="list-style-type: circle"> <li>Lorem ipsum ...</li> </x.ul> <x.ul listStyleType="none" style="list-style-type: none"> <li>Lorem ipsum ...</li> </x.ul>

Responsive

To control the space between elements at a specific breakpoint, use responsive object notation. For example, adding the property listStyleType={{ md: "disc" }} to an element would apply the listStyleType="disc" utility at medium screen sizes and above.

<x.div listStyleType={{ md: 'disc' }}>{/* ... */}</x.div>

For more information about xstyled's responsive design features, check out Responsive Design documentation.

Edit this page on GitHub