WaterfallChart
visual폭포 차트. 양수/음수 델타를 누적 바 차트로 시각화합니다.
100%
Revenue waterfall
isTotal draws the closing bar from zero (850)
Cumulative below zero
running balance crosses the axis
테스트 커버리지
2026년 7월 9일생성된 테스트 결과를 찾지 못했습니다.
WaterfallChart 항목이 문서 메타에 연결되어 있지만 현재 생성 파일에는 없습니다.
테스트를 추가한 뒤 `bun run generate:test-results`를 실행하거나 `testDescribe` 매핑을 다시 확인하세요.
WaterfallChart Props
| Prop | 타입 | 기본값 | 설명 |
|---|---|---|---|
data* | WaterfallDataPoint[] | — | { name, value, isTotal? } 배열. isTotal 행은 누적합을 0부터 다시 그리고 누적합을 늘리지 않으며 totalColor로 칠해집니다 (플래그가 하나도 없으면 종전대로 마지막 행이 총합 색을 받습니다) |
positiveColor | string | "#22c55e" | 양수 막대 색상 |
negativeColor | string | "#ef4444" | 음수 막대 색상 |
totalColor | string | "#3b82f6" | 총합 막대 색상 |
height | ChartContainerSize | 300 | 차트 높이 |
className | string | — | 루트 요소에 붙는 CSS 클래스 |
showGrid | boolean | true | 그리드 표시 여부 |
showTooltip | boolean | true | 툴팁 표시 여부 |
animate | boolean | true | 진입 애니메이션 사용 여부 |
margin | ChartMargin | { top: 20, right: 20, bottom: 20, left: 0 } | 차트 여백 (top/right/bottom/left) |
tooltipOptions | ChartTooltipContentProps | — | ChartTooltipContent에 그대로 넘길 옵션 |
aria-label | string | — | 스크린 리더용 레이블 |
Import
tsx
import { WaterfallChart } from "@reopt-ai/opt-ui";