Grid 网格布局容器
#
使用场景#
示例#
基本示例inline
#
预设响应式inline
#
自动响应式inline
#
间距inline
#
不同列宽inline
#
自定义用法inline
#
布局偏移inline
#
API#
Grid字段 | 描述 |
---|---|
columns | ResponsiveType 列数 |
spacing | StringOrNumber 间距 |
spacingX | StringOrNumber 水平方向间距 |
spacingY | StringOrNumber 垂直方向间距 |
minChildWidth | StringOrNumber 子元素最小宽度 |
templateColumns | GridTemplateColumns<0 | (string & {})> 定义每一列的宽度 |
templateRows | GridTemplateRows<0 | (string & {})> 定义每一行的高度 |
templateArea | GridTemplateAreas |
area | GridArea |
as | any |
style | CSSProperties |
className | string |
m | StringOrNumber |
margin | StringOrNumber |
mt | StringOrNumber |
marginTop | StringOrNumber |
mr | StringOrNumber |
marginRight | StringOrNumber |
mb | StringOrNumber |
marginBottom | StringOrNumber |
ml | StringOrNumber |
marginLeft | StringOrNumber |
mx | StringOrNumber |
marginX | StringOrNumber |
my | StringOrNumber |
marginY | StringOrNumber |
p | StringOrNumber |
padding | StringOrNumber |
pt | StringOrNumber |
paddingTop | StringOrNumber |
pr | StringOrNumber |
paddingRight | StringOrNumber |
pb | StringOrNumber |
paddingBottom | StringOrNumber |
pl | StringOrNumber |
paddingLeft | StringOrNumber |
px | StringOrNumber |
paddingX | StringOrNumber |
py | StringOrNumber |
paddingY | StringOrNumber |
color | Color |
bg | Color |
backgroundColor | Color |
opacity | Opacity |
width | StringOrNumber |
minWidth | StringOrNumber |
maxWidth | StringOrNumber |
height | StringOrNumber |
minHeight | StringOrNumber |
maxHeight | StringOrNumber |
size | StringOrNumber |
display | Display |
verticalAlign | VerticalAlign<0 | (string & {})> |
overflow | Overflow |
overflowX | OverflowX |
overflowY | OverflowY |
fontFamily | FontFamily |
fontStyle | FontStyle |
letterSpacing | LetterSpacing<0 | (string & {})> |
textAlign | TextAlign |
fontSize | string |
fontWeight | FontWeight |
lineHeight | StringOrNumber |
alignItems | AlignItems |
alignContent | AlignContent |
justifyItems | JustifyItems |
justifyContent | JustifyContent |
flexWrap | FlexWrap |
flexDirection | FlexDirection |
flex | Flex<Length> |
flexGrow | FlexGrow |
flexShrink | FlexShrink |
flexBasis | FlexBasis<Length> |
justifySelf | JustifySelf |
alignSelf | AlignSelf |
order | Order |
gridGap | GridGap<Length> |
gridRowGap | GridRowGap<Length> |
gridColumnGap | GridColumnGap<Length> |
gridColumn | GridColumn |
gridColumnStart | GridColumnStart |
gridColumnEnd | GridColumnEnd |
gridRow | GridRow |
gridRowStart | GridRowStart |
gridRowEnd | GridRowEnd |
gridArea | GridArea |
gridTemplateRows | GridTemplateRows<0 | (string & {})> |
gridTemplateColumns | GridTemplateColumns<0 | (string & {})> |
gridTemplateAreas | GridTemplateAreas |
border | string |
borderTop | string |
borderRight | string |
borderBottom | string |
borderLeft | string |
borderWidth | StringOrNumber |
borderColor | Color |
borderTopColor | Color |
borderRightColor | Color |
borderBottomColor | Color |
borderLeftColor | Color |
borderRadius | string |
position | Position |
zIndex | ZIndex |
top | string |
right | string |
bottom | string |
left | string |
boxShadow | BoxShadow |
textShadow | TextShadow |
#
GridItem字段 | 描述 |
---|---|
colSpan | StringOrNumber |
colStart | GridColumnStart |
colEnd | GridColumnEnd |
rowSpan | StringOrNumber |
rowStart | GridRowEnd |
rowEnd | GridRowEnd |
as | any |
style | CSSProperties |
className | string |
m | StringOrNumber |
margin | StringOrNumber |
mt | StringOrNumber |
marginTop | StringOrNumber |
mr | StringOrNumber |
marginRight | StringOrNumber |
mb | StringOrNumber |
marginBottom | StringOrNumber |
ml | StringOrNumber |
marginLeft | StringOrNumber |
mx | StringOrNumber |
marginX | StringOrNumber |
my | StringOrNumber |
marginY | StringOrNumber |
p | StringOrNumber |
padding | StringOrNumber |
pt | StringOrNumber |
paddingTop | StringOrNumber |
pr | StringOrNumber |
paddingRight | StringOrNumber |
pb | StringOrNumber |
paddingBottom | StringOrNumber |
pl | StringOrNumber |
paddingLeft | StringOrNumber |
px | StringOrNumber |
paddingX | StringOrNumber |
py | StringOrNumber |
paddingY | StringOrNumber |
color | Color |
bg | Color |
backgroundColor | Color |
opacity | Opacity |
width | StringOrNumber |
minWidth | StringOrNumber |
maxWidth | StringOrNumber |
height | StringOrNumber |
minHeight | StringOrNumber |
maxHeight | StringOrNumber |
size | StringOrNumber |
display | Display |
verticalAlign | VerticalAlign<0 | (string & {})> |
overflow | Overflow |
overflowX | OverflowX |
overflowY | OverflowY |
fontFamily | FontFamily |
fontStyle | FontStyle |
letterSpacing | LetterSpacing<0 | (string & {})> |
textAlign | TextAlign |
fontSize | string |
fontWeight | FontWeight |
lineHeight | StringOrNumber |
alignItems | AlignItems |
alignContent | AlignContent |
justifyItems | JustifyItems |
justifyContent | JustifyContent |
flexWrap | FlexWrap |
flexDirection | FlexDirection |
flex | Flex<Length> |
flexGrow | FlexGrow |
flexShrink | FlexShrink |
flexBasis | FlexBasis<Length> |
justifySelf | JustifySelf |
alignSelf | AlignSelf |
order | Order |
gridGap | GridGap<Length> |
gridRowGap | GridRowGap<Length> |
gridColumnGap | GridColumnGap<Length> |
gridColumn | GridColumn |
gridColumnStart | GridColumnStart |
gridColumnEnd | GridColumnEnd |
gridRow | GridRow |
gridRowStart | GridRowStart |
gridRowEnd | GridRowEnd |
gridArea | GridArea |
gridTemplateRows | GridTemplateRows<0 | (string & {})> |
gridTemplateColumns | GridTemplateColumns<0 | (string & {})> |
gridTemplateAreas | GridTemplateAreas |
border | string |
borderTop | string |
borderRight | string |
borderBottom | string |
borderLeft | string |
borderWidth | StringOrNumber |
borderColor | Color |
borderTopColor | Color |
borderRightColor | Color |
borderBottomColor | Color |
borderLeftColor | Color |
borderRadius | string |
position | Position |
zIndex | ZIndex |
top | string |
right | string |
bottom | string |
left | string |
boxShadow | BoxShadow |
textShadow | TextShadow |