OGE logoOGE

Charts

Data visualization on a dependency-free SVG kernel — no D3, no Chart.js, no canvas library. Eleven cartesian series types (line/spline/area/spline-area/stacked-area/bar/stacked/full-stacked/ scatter/range-area/candlestick) plus pie and doughnut share pure engines for 1-2-5 nice-tick scales, calendar-true time axes, log axes, stacking with separate negative branches and single-path rendering that stays fluid at 10k+ points. Wheel and drag-select zoom (cursor-centered, Escape resets), crosshair, shared tooltips, an interactive legend and point/series selection are built in. No WAI-ARIA APG chart pattern exists, so the widget composes: role="img" with a generated label, a screen-reader-only data table, real legend buttons, and keyboard point inspection — arrows walk arguments and series with polite live-region announcements.

@oge-ui/charts is a commercial package — free for evaluation and development, with no watermark and no runtime license checks. See licensing for the terms.

11 series types time & log axes zoom & pan crosshair dependency-free SVG

Getting started

One element, a working chart: the category axis auto-detects from the string arguments, the value axis picks nice ticks, the legend toggles series, and hovering shows the crosshair and tooltip.

auto axes legend tooltip crosshair
Quarterly revenue
Q1 Q2 Q3 Q4 0 50 100 150
Chart data
ArgumentProductServices
Q112060
Q215074
Q313890
Q4190105

Series types

Sixteen series types share one kernel — line/spline/step lines, five area flavors, four bar flavors (incl. rangeBar spanning value1..value2), scatter, bubble (sizeField drives each bubble's area), rangeArea and candlestick. showLabels prints values next to small series, null values become gaps, and hovering a legend item spotlights its series.

stepLine bubble rangeBar showLabels
5 10 0 20 40 60 80
Chart data
ArgumentBandStepsBubbles
122 – 426080
227.753 – 47.75374.38374.647
332.098 – 52.09885.24460.881
433.97 – 53.9789.92544.596
532.912 – 52.91287.27932.767
629.182 – 49.18277.95430.458
723.693 – 43.69364.23438.659
817.791 – 37.79149.47753.857
912.918 – 32.91837.29669.545
1010.27 – 30.2730.67479.004
1110.493 – 30.49331.23278.184
1213.534 – 33.53438.83467.436
1318.647 – 38.64751.61851.362
1424.581 – 44.58166.45436.847

Time axis & strip lines

Date arguments auto-detect the time axis: ticks are calendar-true (real month boundaries, DST-safe) and labels format through Intl in your locale. stripLines mark a deadline (line) or a window (band).

time axis Intl labels stripLines
Campaign Release Jan 5 Jan 19 Feb 2 Feb 16 Mar 2 Mar 16 Mar 30 Apr 13 Apr 27 0 200 400 600
Chart data
ArgumentVisitors
Jan 1, 2026400
Jan 2, 2026424.632
Jan 3, 2026449.06
Jan 4, 2026473.079
Jan 5, 2026496.493
Jan 6, 2026519.112
Jan 7, 2026540.755
Jan 8, 2026561.255
Jan 9, 2026580.456
Jan 10, 2026598.221
Jan 11, 2026614.429
Jan 12, 2026628.979
Jan 13, 2026641.791
Jan 14, 2026652.804
Jan 15, 2026661.983
Jan 16, 2026669.311
Jan 17, 2026674.798
Jan 18, 2026542.475
Jan 19, 2026544.395
Jan 20, 2026544.632
Jan 21, 2026543.283
Jan 22, 2026540.463
Jan 23, 2026536.305
Jan 24, 2026530.96
Jan 25, 2026524.591
Jan 26, 2026517.376
Jan 27, 2026509.503
Jan 28, 2026501.168
Jan 29, 2026492.572
Jan 30, 2026483.919
Jan 31, 2026475.415
Feb 1, 2026467.263
Feb 2, 2026459.664
Feb 3, 2026452.808
Feb 4, 2026310.88
Feb 5, 2026306.051
Feb 6, 2026302.48
Feb 7, 2026300.308
Feb 8, 2026299.662
Feb 9, 2026300.648
Feb 10, 2026303.352
Feb 11, 2026307.841
Feb 12, 2026314.157
Feb 13, 2026322.321
Feb 14, 2026332.33
Feb 15, 2026344.161
Feb 16, 2026357.766
Feb 17, 2026373.076
Feb 18, 2026390.001
Feb 19, 2026408.43

Stacked series

stackedBar accumulates per argument with negatives stacking downward separately; fullStackedBar normalizes each argument to 100%; the stack option splits independent groups.

stackedBar negative stacks stack groups
Jan Feb Mar Apr 0 20 40 60 80
Chart data
ArgumentOnlineRetailRefunds
Jan4024-6
Feb5228-4
Mar4735-9
Apr6131-5

Zoom, pan & tooltips

50,000 points per series stay fluid: paths auto-downsample with LTTB (Largest-Triangle-Three-Buckets — peaks survive) to roughly one point per pixel, while hit-testing stays a binary search over the full data. Wheel zooms around the cursor, dragging selects a range, Shift+drag pans, Escape resets — [(visualRange)] is two-way and shared tooltips list every series.

50k points LTTB downsampling wheel zoom drag-select
Jan 26 Apr 26 Jul 26 Oct 26 Jan 27 Apr 27 20 40 60 80
Chart data
ArgumentCPUMemory
Jan 1, 20264073
Jan 1, 202641.41773.999
Jan 1, 202642.83374.996
Jan 1, 202644.24975.99
Jan 1, 202645.66576.982
Jan 1, 202647.08177.972
Jan 1, 202648.49678.96
Jan 1, 202649.9172.946
Jan 1, 202651.32373.929
Jan 1, 202652.73674.91
Jan 1, 202654.14775.889
Jan 1, 202655.55876.866
Jan 1, 202656.96777.84
Jan 1, 202645.37478.813
Jan 1, 202646.78172.783
Jan 1, 202648.18573.751
Jan 1, 202649.58874.716
Jan 1, 202650.98975.68
Jan 1, 202652.38876.641
Jan 1, 202653.78577.6
Jan 1, 202655.1878.557
Jan 1, 202656.57272.512
Jan 1, 202657.96373.465
Jan 1, 202659.3574.415
Jan 1, 202660.73575.364
Jan 1, 202662.11876.31
Jan 1, 202650.49777.254
Jan 1, 202651.87478.196
Jan 1, 202653.24872.136
Jan 1, 202654.61873.074
Jan 1, 202655.98674.009
Jan 1, 202657.3574.943
Jan 1, 202658.7175.874
Jan 1, 202660.06776.803
Jan 1, 202661.42177.731
Jan 1, 202662.7771.656
Jan 1, 202664.11672.579
Jan 1, 202665.45873.5
Jan 1, 202666.79674.419
Jan 1, 202655.1375.336
Jan 1, 202656.45976.251
Jan 1, 202657.78577.164
Jan 1, 202659.10571.075
Jan 1, 202660.42271.984
Jan 1, 202661.73472.891
Jan 1, 202663.04173.796
Jan 1, 202664.34374.7
Jan 1, 202665.64175.601
Jan 1, 202666.93476.5
Jan 1, 202668.22270.397

Candlestick & multi-axis

Candlesticks read OHLC fields; a second value axis (position: 'end') carries the volume bars so the two scales stay independent. Rising/falling bodies color via the theme tokens.

candlestick OHLC multi value axes
Jul 6 Jul 13 Jul 20 Jul 27 80 90 100 110 120 Price 0 500 1,000 1,500 Volume
Chart data
ArgumentOGEVolume
Jul 1, 2026O 100 H 104 L 94 C 98800
Jul 2, 2026O 103.969 H 108.845 L 99.969 C 104.845920
Jul 3, 2026O 107.753 H 114.802 L 103.753 C 110.8021,040
Jul 4, 2026O 111.18 H 119.165 L 107.18 C 115.1651,160
Jul 5, 2026O 114.098 H 121.553 L 110.098 C 117.5531,280
Jul 6, 2026O 111.388 H 116.979 L 107.388 C 112.9791,400
Jul 7, 2026O 112.97 H 116.97 L 107.817 C 111.8171,520
Jul 8, 2026O 113.808 H 117.808 L 105.703 C 109.7031,640
Jul 9, 2026O 113.912 H 117.912 L 103.371 C 107.3711,760
Jul 10, 2026O 113.337 H 117.337 L 101.472 C 105.472800
Jul 11, 2026O 107.182 H 111.182 L 95.428 C 99.428920
Jul 12, 2026O 105.58 H 109.58 L 95.347 C 99.3471,040
Jul 13, 2026O 103.693 H 107.693 L 96.017 C 100.0171,160
Jul 14, 2026O 101.702 H 105.702 L 96.992 C 100.9921,280
Jul 15, 2026O 99.791 H 105.733 L 95.791 C 101.7331,400
Jul 16, 2026O 93.141 H 100.769 L 89.141 C 96.7691,520
Jul 17, 2026O 91.918 H 99.855 L 87.918 C 95.8551,640
Jul 18, 2026O 91.26 H 98.051 L 87.26 C 94.0511,760
Jul 19, 2026O 91.27 H 95.742 L 87.27 C 91.742800
Jul 20, 2026O 92.008 H 96.008 L 85.558 C 89.558920
Jul 21, 2026O 88.493 H 92.493 L 79.229 C 83.2291,040
Jul 22, 2026O 90.693 H 94.693 L 79.415 C 83.4151,160
Jul 23, 2026O 93.534 H 97.534 L 81.534 C 85.5341,280
Jul 24, 2026O 96.901 H 100.901 L 85.648 C 89.6481,400
Jul 25, 2026O 100.647 H 104.647 L 91.428 C 95.4281,520
Jul 26, 2026O 99.602 H 103.602 L 93.204 C 97.2041,640
Jul 27, 2026O 103.581 H 108.102 L 99.581 C 104.1021,760
Jul 28, 2026O 107.401 H 114.223 L 103.401 C 110.223800
Jul 29, 2026O 110.884 H 118.827 L 106.884 C 114.827920
Jul 30, 2026O 113.877 H 121.486 L 109.877 C 117.4861,040

Pie & doughnut

Pie and doughnut share the kernel: outside labels with connector lines, small-value grouping folds the tail into an "Others" slice, and clicking a slice (or its legend button) selects and explodes it.

doughnut smallValuesGrouping explode
Browser share
Chrome Others Firefox Edge Safari
Chart data
Chrome62 (62%)
Safari20 (20%)
Edge6 (6%)
Firefox5 (5%)
Others7 (7%)

Polar & radar

Radar/polar on the same kernel: categories slot around the circle, values map radially with nice-tick rings. line/area draw closed radar loops (a null value breaks the loop into a gap), scatter renders markers, bar renders sectors — and spider swaps circular rings for polygons.

radar spider grid polar bar
Team skills
TypeScript CSS SQL Rust Go Testing 5
Chart data
ArgumentAdaGrace
TypeScript97
CSS68
SQL75
Rust46
Go59
Testing87

Annotations

Annotations anchor on the plot: point draws a marker dot with a connector into a label box at (argument, value); text places the label alone. *ogeChartAnnotationTemplate swaps in arbitrary HTML.

point annotations text annotations template
All-time high Correction Q1 guidance 10 20 30 40 70 80 90 100 110 120
Chart data
ArgumentPrice
180
284.473
388.788
492.793
596.347
699.329
7101.641
8103.209
9103.991
10103.977
11103.186
12101.67
1399.509
1496.81
1593.7
1690.322
1786.833
1883.389
1980.15
2077.263
2174.864
2273.068
2371.968
2471.626
2572.077
2673.322
2775.331
2878.045
2981.375
3085.208
3189.412
3293.838
3398.331
34102.731
35106.882
36110.64
37113.873
38116.474
39118.358
40119.471

Range selector

The overview strip: a mini background chart with a draggable window and two WAI-ARIA slider handles (arrows adjust, Home/End jump, Escape mid-drag restores). Bound to the chart's [(visualRange)], the two stay in lockstep — drag the window and the chart zooms.

overview strip [(value)] slider handles
Jan 26 Apr 26 Jul 26 Oct 26 150 200 250 300 350
Chart data
ArgumentSales
Jan 1, 2026200
Jan 2, 2026209.998
Jan 3, 2026219.987
Jan 4, 2026229.955
Jan 5, 2026239.894
Jan 6, 2026249.792
Jan 7, 2026259.642
Jan 8, 2026269.432
Jan 9, 2026279.153
Jan 10, 2026288.797
Jan 11, 2026298.354
Jan 12, 2026241.815
Jan 13, 2026251.171
Jan 14, 2026260.415
Jan 15, 2026269.537
Jan 16, 2026278.531
Jan 17, 2026287.388
Jan 18, 2026296.102
Jan 19, 2026304.666
Jan 20, 2026313.073
Jan 21, 2026321.318
Jan 22, 2026329.394
Jan 23, 2026271.297
Jan 24, 2026279.021
Jan 25, 2026286.563
Jan 26, 2026293.919
Jan 27, 2026301.085
Jan 28, 2026308.058
Jan 29, 2026314.836
Jan 30, 2026321.417
Jan 31, 2026327.8
Feb 1, 2026333.983
Feb 2, 2026339.966
Feb 3, 2026279.749
Feb 4, 2026285.333
Feb 5, 2026290.719
Feb 6, 2026295.908
Feb 7, 2026300.902
Feb 8, 2026305.704
Feb 9, 2026310.317
Feb 10, 2026314.744
Feb 11, 2026318.989
Feb 12, 2026323.057
Feb 13, 2026326.952
Feb 14, 2026264.68
Feb 15, 2026268.246
Feb 16, 2026271.656
Feb 17, 2026274.918
Feb 18, 2026278.037
Feb 19, 2026281.021
Jan 26 Apr 26 Jul 26 Oct 26

Selection, i18n & export

selectionMode="point" rings clicked points (Ctrl adds to the set). Every user-facing string, aria labels included, lives in OgeChartsMessages (provideOgeChartsConfig(), locale). The dependency-free @oge-ui/charts/export-image entry serializes the live SVG with inlined styles — PNG via canvas rasterization, or the standalone .svg itself.

selectionMode locale export-image PNG/SVG
Jan Feb Mar Apr 0 10 20 30 40
Chart data
ArgumentValue
Jan12
Feb31
Mar24
Apr42