CandlestickChart
OHLC candlestick chart — green for up, red for down, with wick and body.
Basic usage
Data is passed in via props and rendered as plain SVG — no third-party charting library.
Colors come from the --viz-1..8 tokens and are color-blind friendly.
Demo source
<CfCandlestickChart ... /> <CfCandlestickChart ... /> Up / down trends
The up-vs-down color is chosen automatically by close >= open; wick and body share the same color.
↑ 上行
↓ 下行
Demo source
<CfCandlestickChart :data="ohlc" /> <CfCandlestickChart data={ohlc} /> API
| Prop | Type | Default | Description |
|---|---|---|---|
data | Candle[] | — | { open, high, low, close, label? }[] |
反馈与讨论
CandlestickChart · Discussion