Components/Candlestick Chart
Candlestick Chart
Dependency-free OHLC candles with bullish/bearish coloring, wicks, gridlines and axis labels - the same lightweight-SVG philosophy as Chart.
Installation
npx @ajax-ui/cli add candlestick-chartProps
data-{ label, open, high, low, close }per candle, oldest first.upColor/downColor- bullish/bearish fills (default emerald/red).showGrid/showAxis(defaulttrue) - dashed gridlines, compact y-labels, thinned x-labels.height(default 240) - width is fluid viaviewBox.- Each candle body carries a
<title>with its OHLC values - native hover tooltip and screen-reader text. - Doji candles (open = close) keep a visible 1px body.
When to reach for a library
This is a presentation chart: static series, no zoom/pan/crosshair. For a live trading terminal with thousands of candles and streaming updates, layer a dedicated charting engine and keep this for summaries, reports, and cards.