Skip to main content

White Space horizontal blank component

White Space component is a layout component that allows you to add vertical spacing between other components or elements in your user interface.

Effect demonstration

1. Default effect

<View style={{ height: 50, backgroundColor: 'red' }} />
<WhiteSpace />
<View style={{ height: 50, backgroundColor: 'gold' }} />
whiteSpace-ios1.png

2. Designation backgroundColor and size

<View style={{ height: 50, backgroundColor: 'red' }} />
<WhiteSpace size="x6" backgroundColor="green" />
<View style={{ height: 50, backgroundColor: 'gold' }} />
whiteSpace-ios2.png

API

PropertiesRequiredDescriptionTypeDefault Value
sizefalseSize of horizontal whitespacexxs | xs | s | m | l | xl | xxlm
backgroundColorfalseHorizontal blank background colorstringtransparent

The specific size corresponding to the value of _size is defined in spacing of the theme file. _