Last active
March 23, 2018 16:29
-
-
Save d-asensio/ce5c071adab601616d7fb5e89ef89b4e to your computer and use it in GitHub Desktop.
DescriptionList component interface implemented with styled-system
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const PrimaryDescriptionList = () => ( | |
<DescriptionList | |
flexDirection={['column', 'row']} | |
> | |
<DescriptionList.Item | |
mr={[0, 4]} | |
> | |
<DescriptionList.Label>Label 1</DescriptionList.Label> | |
<DescriptionList.Detail>Detail 1</DescriptionList.Detail> | |
</DescriptionList.Item> | |
<DescriptionList.Item | |
mr={[0, 4]} | |
> | |
<DescriptionList.Label>Label 2</DescriptionList.Label> | |
<DescriptionList.Detail>Detail 2</DescriptionList.Detail> | |
</DescriptionList.Item> | |
<DescriptionList.Item | |
mr={[0, 4]} | |
> | |
<DescriptionList.Label>Label 3</DescriptionList.Label> | |
<DescriptionList.Detail>Detail 3</DescriptionList.Detail> | |
</DescriptionList.Item> | |
</DescriptionList> | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const SecondaryDescriptionList = () => ( | |
<DescriptionList | |
flexDirection={['column', 'row', 'column']} | |
justifyContent={'space-between'} | |
> | |
<DescriptionList.Item | |
justifyContent={['space-between', 'flex-start', 'space-between']} | |
mr={[0, 4, 0]} | |
> | |
<DescriptionList.Label>Label 1</DescriptionList.Label> | |
<DescriptionList.Detail>Detail 1</DescriptionList.Detail> | |
</DescriptionList.Item> | |
<DescriptionList.Item | |
justifyContent={['space-between', 'flex-start', 'space-between']} | |
mr={[0, 4, 0]} | |
> | |
<DescriptionList.Label>Label 2</DescriptionList.Label> | |
<DescriptionList.Detail>Detail 2</DescriptionList.Detail> | |
</DescriptionList.Item> | |
</DescriptionList> | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment