Progress Stepper
Progress stepper는 여러 단계로 이루어진 작업의 현재 진행 위치를 보여주는 컴포넌트예요. 기본 아이콘은 variant 속성에 연결되고, icon 속성으로 원하는 아이콘으로 바꿔 커스텀할 수도 있어요.
출처: 문서
본문
예제 (Examples)
Progress stepper는 variant 속성과 연결된 기본 아이콘을 가지며, icon 속성을 사용해 덮어쓰고 커스텀할 수 있어요.
기본 (Basic)
First step
Second step
Third step
단계 설명과 함께 (With step descriptions)
First step
This is the first thing to happen
Second step
This is the second thing to happen
Third step
This is the last thing to happen
정렬과 함께 (With alignment)
세로 정렬 (Vertical alignment)
가운데 정렬 (Center alignment)
First step
This is the first thing to happen
Second step
This is the second thing to happen
Third step
This is the last thing to happen
컴팩트 (Compact)
컴팩트 progress stepper는 현재 단계의 title만 표시하고, 어떤 단계의 description 텍스트도 표시하지 않아요.
세로 정렬 (Vertical alignment)
가운데 정렬 (Center alignment)
First step
Second step
Third step
문제가 있을 때 (With an issue)
First step
Second step
Third step
Fourth step
Fifth step
실패가 있을 때 (With a failure)
First step
Second step
Third step
Fourth step
Fifth step
커스텀 아이콘과 함께 (With custom icons)
Successful completion
In process
Pending
도움말 팝오버와 함께 (With help popover)
진행 단계에 팝오버를 추가하려면 ProgressStep 컴포넌트에 popoverRender 속성을 설정해요.
Fourth step
속성 (Props)
ProgressStepper
| 이름 (Name) | 타입 (Type) | 기본값 (Default) | 설명 (Description) |
|---|---|---|---|
aria-label |
string |
progress stepper에 접근 가능한 라벨을 추가해요. | |
children |
React.ReactNode |
progress stepper 안에 렌더링되는 내용이에요. | |
className |
string |
progress stepper 컨테이너에 적용되는 추가 클래스예요. | |
isCenterAligned |
boolean |
progress stepper를 가운데 정렬해야 한다는 플래그예요. | |
isCompact |
boolean |
progress stepper를 컴팩트하게 렌더링해야 한다는 플래그예요. | |
isVertical |
boolean |
progress stepper가 세로 레이아웃이라는 플래그예요. |
ProgressStep
| 이름 (Name) | 타입 (Type) | 기본값 (Default) | 설명 (Description) |
|---|---|---|---|
aria-label |
string |
progress step의 접근 가능한 라벨이에요. 진행 단계 아이콘이 전달하는 모든 정보(variant와 완료 상태 포함)를 전달해야 해요. | |
children |
React.ReactNode |
progress step 안에 렌더링되는 내용이에요. | |
className |
string |
progress step 컨테이너에 적용되는 추가 클래스예요. | |
description |
React.ReactNode |
progress step의 설명 텍스트예요. | |
icon |
React.ReactNode |
progress step의 커스텀 아이콘이에요. variant가 제공하는 기본 아이콘을 덮어써요. | |
isCurrent |
boolean |
progress step이 현재 단계라는 플래그예요. | |
popoverRender |
(stepRef: React.RefObject<any>) => React.ReactNode |
step ref를 렌더링 함수에 전달해요. 이 속성을 사용해 단계에 팝오버를 추가할 수 있어요. | |
titleId |
string |
progress step 제목의 ID예요. | |
variant |
'default' | 'success' | 'info' | 'pending' | 'warning' | 'danger' |
progress step의 variant예요. 각 variant에는 기본 아이콘이 있어요. |