1.2.0 • Published 2 years ago

@piksl/box v1.2.0

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

@piksl/box

  • <Box /> is a Styled Component that wraps the <div> HTML-element and provides properties to change the styling of the element. More information about the available properties can be found in the API description below.

API

Box

PropDescriptionTypeDefault
displayMinimum height of the <Container />inline, block, flex-
justifySets the distribution of space between and around <Box /> children items.flex-start, flex-end, center, space-between, space-around, space-evenly-
alignSets the destribution of space between and around <Box /> children items.flex-start, flex-end, center-
wrapDefines whether the flex items are inside <Box /> are forced in a single line or can be flowed into multiple lines.nowrap, wrap, wrap-reversenowrap
positionSets how the <Box /> is positionedstatic, relative, fixed, absolute, sticky-
marginSets the margin area on sides of the <Box />OffsetShorthandType-
paddingSets the padding area on sides of the <Box />OffsetShorthandType-
topDetermine the top location of positioned <Box />string-
rightDetermine the right location of positioned <Box />string-
bottomDetermine the bottom location of positioned <Box />string-
leftDetermine the left location of positioned <Box />string-
classnameThe classname of the <Box />string-

Types

OffsetType

number | "auto"

OffsetShorthandType

[OffsetType, OffsetType, OffsetType, OffsetType] | [OffsetType, OffsetType, OffsetType] | [OffsetType, OffsetType] | [OffsetType]