콘텐츠로 이동
RefineUI

Grid

동일 열 또는 Foundation min-item 자동 맞춤 CSS 그리드.

Grid는 자식을 열로 배치합니다. 고정 columns를 쓰거나, Foundation 크기와 함께 minItem으로 유동 auto-fit 그리드를 만드세요.

1
2
3
4
5
6

Overview

Machine-readable contract from Component Spec.

component: gridexport: Gridversion: 1attributes: data-refineui=grid

Anatomy

Partdata-refineui
rootgrid
itemgrid-item

Layout

PropertyValue
directionlogical
rtltrue
npm install @refineui/react @refineui/tokens
import { Grid, GridItem } from "@refineui/react";
<Grid columns={3} gap="sizeMedium">
<div>1</div>
<div>2</div>
<div>3</div>
</Grid>
<Grid minItem="foundationSize2560" gap="sizeLarge">
<GridItem>Card</GridItem>
<GridItem>Card</GridItem>
</Grid>
PropDefaultTypeDescription
as"div"ElementType루트 요소.
columns1number동일 열 개수(`minItem` 설정 시 무시).
minItemFoundation size nameauto-fit 최소 트랙 크기.
gap"sizeNone"Spacing token행·열 gap.
columnGapSpacing token열 gap 재정의.
rowGapSpacing token행 gap 재정의.
alignAlign token아이템 정렬.
justifyJustify token콘텐츠 justify.
PropDefaultTypeDescription
span1number열 span.
rowSpannumber행 span.