@bedrock-layout/inline-cluster

bedrock-layout inline-cluster

Usage no npm install needed!

<script type="module">
  import bedrockLayoutInlineCluster from 'https://cdn.skypack.dev/@bedrock-layout/inline-cluster';
</script>

README

@bedrock-layout/inline-cluster

InlineCluster is a layout helper component that displays items in a row.

Full docs at: bedrock-layout.dev


When to Use

The InclineCluster component can be used to create inline-cluster layouts where items are displayed in a single row. If the number of items is too large, then they are displayed in a cluster with respect to the container's width and the cluster's justification (start, end, or center).


How to install

npm install @bedrock-layout/inline-cluster

or

yarn add @bedrock-layout/inline-cluster


Usage

import { InlineCluster } from '@bedrock-layout/inline-cluster';

<InlineCLuster gutter='lg' justify='start' align='start'>
  <span>Lorem ipsum dolor</span>
  <span>sit amet consectetur</span>
  <span>adipisicing elit.</span>
</InlineCLuster>;

data-attribute

For styling purposes, you can select data-bedrock-inline-cluster.


API

* required

Property Description Type Default
gutter* Sets the space between each child element one of Spacing** -
justify Sets the inline justification of the children One of: start, end, center start
align Sets the block alignment of the children One of: start, end, center start

** By default, Spacing is one of spacing-constants values, but this can be overwritten using the ThemeProvider from styled-components