Skip to main content

Space

Lays out its children in a row or column with consistent gaps, optional wrapping, and separators.

import { Space, Tag } from '@jbpark/ui-kit';

<Space size="middle">
<Tag>One</Tag>
<Tag>Two</Tag>
</Space>;
OneTwoThree
OneTwoThree
One|Two|Three

Props

PropTypeDefault
orientation'horizontal' | 'vertical''horizontal'
size'small' | 'middle' | 'large' | number | number[]'middle'
align'start' | 'end' | 'center' | 'baseline''center'
wrapbooleanfalse
splitReactNode-
grid{ rows?: number; cols?: number }-
loadingbooleanfalse
loaderReactNode<Skeleton />
classNamestring-
childrenReactNode-

Space also accepts the rest of React.ComponentProps<'div'> (e.g. style, hidden).