@opendata-ai/openchart-core 8.5.2 → 8.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +123 -3
- package/dist/index.js +44 -3
- package/dist/index.js.map +1 -1
- package/dist/styles.css.map +1 -1
- package/package.json +1 -1
- package/schema/chart.schema.json +1486 -71
- package/schema/vizspec.schema.json +6342 -3475
package/schema/chart.schema.json
CHANGED
|
@@ -144,6 +144,30 @@
|
|
|
144
144
|
"type": "number",
|
|
145
145
|
"description": "Default opacity (0-1)."
|
|
146
146
|
},
|
|
147
|
+
"fillOpacity": {
|
|
148
|
+
"type": "number",
|
|
149
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
150
|
+
},
|
|
151
|
+
"binCount": {
|
|
152
|
+
"type": "number",
|
|
153
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
154
|
+
},
|
|
155
|
+
"normalize": {
|
|
156
|
+
"type": "boolean",
|
|
157
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
158
|
+
},
|
|
159
|
+
"bandwidth": {
|
|
160
|
+
"type": "number",
|
|
161
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
162
|
+
},
|
|
163
|
+
"cumulative": {
|
|
164
|
+
"type": "boolean",
|
|
165
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
166
|
+
},
|
|
167
|
+
"steps": {
|
|
168
|
+
"type": "number",
|
|
169
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
170
|
+
},
|
|
147
171
|
"fill": {
|
|
148
172
|
"anyOf": [
|
|
149
173
|
{
|
|
@@ -466,6 +490,30 @@
|
|
|
466
490
|
"type": "number",
|
|
467
491
|
"description": "Default opacity (0-1)."
|
|
468
492
|
},
|
|
493
|
+
"fillOpacity": {
|
|
494
|
+
"type": "number",
|
|
495
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
496
|
+
},
|
|
497
|
+
"binCount": {
|
|
498
|
+
"type": "number",
|
|
499
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
500
|
+
},
|
|
501
|
+
"normalize": {
|
|
502
|
+
"type": "boolean",
|
|
503
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
504
|
+
},
|
|
505
|
+
"bandwidth": {
|
|
506
|
+
"type": "number",
|
|
507
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
508
|
+
},
|
|
509
|
+
"cumulative": {
|
|
510
|
+
"type": "boolean",
|
|
511
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
512
|
+
},
|
|
513
|
+
"steps": {
|
|
514
|
+
"type": "number",
|
|
515
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
516
|
+
},
|
|
469
517
|
"fill": {
|
|
470
518
|
"anyOf": [
|
|
471
519
|
{
|
|
@@ -788,6 +836,30 @@
|
|
|
788
836
|
"type": "number",
|
|
789
837
|
"description": "Default opacity (0-1)."
|
|
790
838
|
},
|
|
839
|
+
"fillOpacity": {
|
|
840
|
+
"type": "number",
|
|
841
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
842
|
+
},
|
|
843
|
+
"binCount": {
|
|
844
|
+
"type": "number",
|
|
845
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
846
|
+
},
|
|
847
|
+
"normalize": {
|
|
848
|
+
"type": "boolean",
|
|
849
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
850
|
+
},
|
|
851
|
+
"bandwidth": {
|
|
852
|
+
"type": "number",
|
|
853
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
854
|
+
},
|
|
855
|
+
"cumulative": {
|
|
856
|
+
"type": "boolean",
|
|
857
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
858
|
+
},
|
|
859
|
+
"steps": {
|
|
860
|
+
"type": "number",
|
|
861
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
862
|
+
},
|
|
791
863
|
"fill": {
|
|
792
864
|
"anyOf": [
|
|
793
865
|
{
|
|
@@ -1110,6 +1182,30 @@
|
|
|
1110
1182
|
"type": "number",
|
|
1111
1183
|
"description": "Default opacity (0-1)."
|
|
1112
1184
|
},
|
|
1185
|
+
"fillOpacity": {
|
|
1186
|
+
"type": "number",
|
|
1187
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
1188
|
+
},
|
|
1189
|
+
"binCount": {
|
|
1190
|
+
"type": "number",
|
|
1191
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
1192
|
+
},
|
|
1193
|
+
"normalize": {
|
|
1194
|
+
"type": "boolean",
|
|
1195
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
1196
|
+
},
|
|
1197
|
+
"bandwidth": {
|
|
1198
|
+
"type": "number",
|
|
1199
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
1200
|
+
},
|
|
1201
|
+
"cumulative": {
|
|
1202
|
+
"type": "boolean",
|
|
1203
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
1204
|
+
},
|
|
1205
|
+
"steps": {
|
|
1206
|
+
"type": "number",
|
|
1207
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
1208
|
+
},
|
|
1113
1209
|
"fill": {
|
|
1114
1210
|
"anyOf": [
|
|
1115
1211
|
{
|
|
@@ -1432,6 +1528,30 @@
|
|
|
1432
1528
|
"type": "number",
|
|
1433
1529
|
"description": "Default opacity (0-1)."
|
|
1434
1530
|
},
|
|
1531
|
+
"fillOpacity": {
|
|
1532
|
+
"type": "number",
|
|
1533
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
1534
|
+
},
|
|
1535
|
+
"binCount": {
|
|
1536
|
+
"type": "number",
|
|
1537
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
1538
|
+
},
|
|
1539
|
+
"normalize": {
|
|
1540
|
+
"type": "boolean",
|
|
1541
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
1542
|
+
},
|
|
1543
|
+
"bandwidth": {
|
|
1544
|
+
"type": "number",
|
|
1545
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
1546
|
+
},
|
|
1547
|
+
"cumulative": {
|
|
1548
|
+
"type": "boolean",
|
|
1549
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
1550
|
+
},
|
|
1551
|
+
"steps": {
|
|
1552
|
+
"type": "number",
|
|
1553
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
1554
|
+
},
|
|
1435
1555
|
"fill": {
|
|
1436
1556
|
"anyOf": [
|
|
1437
1557
|
{
|
|
@@ -1754,6 +1874,30 @@
|
|
|
1754
1874
|
"type": "number",
|
|
1755
1875
|
"description": "Default opacity (0-1)."
|
|
1756
1876
|
},
|
|
1877
|
+
"fillOpacity": {
|
|
1878
|
+
"type": "number",
|
|
1879
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
1880
|
+
},
|
|
1881
|
+
"binCount": {
|
|
1882
|
+
"type": "number",
|
|
1883
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
1884
|
+
},
|
|
1885
|
+
"normalize": {
|
|
1886
|
+
"type": "boolean",
|
|
1887
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
1888
|
+
},
|
|
1889
|
+
"bandwidth": {
|
|
1890
|
+
"type": "number",
|
|
1891
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
1892
|
+
},
|
|
1893
|
+
"cumulative": {
|
|
1894
|
+
"type": "boolean",
|
|
1895
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
1896
|
+
},
|
|
1897
|
+
"steps": {
|
|
1898
|
+
"type": "number",
|
|
1899
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
1900
|
+
},
|
|
1757
1901
|
"fill": {
|
|
1758
1902
|
"anyOf": [
|
|
1759
1903
|
{
|
|
@@ -2076,6 +2220,30 @@
|
|
|
2076
2220
|
"type": "number",
|
|
2077
2221
|
"description": "Default opacity (0-1)."
|
|
2078
2222
|
},
|
|
2223
|
+
"fillOpacity": {
|
|
2224
|
+
"type": "number",
|
|
2225
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
2226
|
+
},
|
|
2227
|
+
"binCount": {
|
|
2228
|
+
"type": "number",
|
|
2229
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
2230
|
+
},
|
|
2231
|
+
"normalize": {
|
|
2232
|
+
"type": "boolean",
|
|
2233
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
2234
|
+
},
|
|
2235
|
+
"bandwidth": {
|
|
2236
|
+
"type": "number",
|
|
2237
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
2238
|
+
},
|
|
2239
|
+
"cumulative": {
|
|
2240
|
+
"type": "boolean",
|
|
2241
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
2242
|
+
},
|
|
2243
|
+
"steps": {
|
|
2244
|
+
"type": "number",
|
|
2245
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
2246
|
+
},
|
|
2079
2247
|
"fill": {
|
|
2080
2248
|
"anyOf": [
|
|
2081
2249
|
{
|
|
@@ -2398,6 +2566,30 @@
|
|
|
2398
2566
|
"type": "number",
|
|
2399
2567
|
"description": "Default opacity (0-1)."
|
|
2400
2568
|
},
|
|
2569
|
+
"fillOpacity": {
|
|
2570
|
+
"type": "number",
|
|
2571
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
2572
|
+
},
|
|
2573
|
+
"binCount": {
|
|
2574
|
+
"type": "number",
|
|
2575
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
2576
|
+
},
|
|
2577
|
+
"normalize": {
|
|
2578
|
+
"type": "boolean",
|
|
2579
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
2580
|
+
},
|
|
2581
|
+
"bandwidth": {
|
|
2582
|
+
"type": "number",
|
|
2583
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
2584
|
+
},
|
|
2585
|
+
"cumulative": {
|
|
2586
|
+
"type": "boolean",
|
|
2587
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
2588
|
+
},
|
|
2589
|
+
"steps": {
|
|
2590
|
+
"type": "number",
|
|
2591
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
2592
|
+
},
|
|
2401
2593
|
"fill": {
|
|
2402
2594
|
"anyOf": [
|
|
2403
2595
|
{
|
|
@@ -2720,6 +2912,30 @@
|
|
|
2720
2912
|
"type": "number",
|
|
2721
2913
|
"description": "Default opacity (0-1)."
|
|
2722
2914
|
},
|
|
2915
|
+
"fillOpacity": {
|
|
2916
|
+
"type": "number",
|
|
2917
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
2918
|
+
},
|
|
2919
|
+
"binCount": {
|
|
2920
|
+
"type": "number",
|
|
2921
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
2922
|
+
},
|
|
2923
|
+
"normalize": {
|
|
2924
|
+
"type": "boolean",
|
|
2925
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
2926
|
+
},
|
|
2927
|
+
"bandwidth": {
|
|
2928
|
+
"type": "number",
|
|
2929
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
2930
|
+
},
|
|
2931
|
+
"cumulative": {
|
|
2932
|
+
"type": "boolean",
|
|
2933
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
2934
|
+
},
|
|
2935
|
+
"steps": {
|
|
2936
|
+
"type": "number",
|
|
2937
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
2938
|
+
},
|
|
2723
2939
|
"fill": {
|
|
2724
2940
|
"anyOf": [
|
|
2725
2941
|
{
|
|
@@ -3042,6 +3258,30 @@
|
|
|
3042
3258
|
"type": "number",
|
|
3043
3259
|
"description": "Default opacity (0-1)."
|
|
3044
3260
|
},
|
|
3261
|
+
"fillOpacity": {
|
|
3262
|
+
"type": "number",
|
|
3263
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
3264
|
+
},
|
|
3265
|
+
"binCount": {
|
|
3266
|
+
"type": "number",
|
|
3267
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
3268
|
+
},
|
|
3269
|
+
"normalize": {
|
|
3270
|
+
"type": "boolean",
|
|
3271
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
3272
|
+
},
|
|
3273
|
+
"bandwidth": {
|
|
3274
|
+
"type": "number",
|
|
3275
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
3276
|
+
},
|
|
3277
|
+
"cumulative": {
|
|
3278
|
+
"type": "boolean",
|
|
3279
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
3280
|
+
},
|
|
3281
|
+
"steps": {
|
|
3282
|
+
"type": "number",
|
|
3283
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
3284
|
+
},
|
|
3045
3285
|
"fill": {
|
|
3046
3286
|
"anyOf": [
|
|
3047
3287
|
{
|
|
@@ -3364,6 +3604,30 @@
|
|
|
3364
3604
|
"type": "number",
|
|
3365
3605
|
"description": "Default opacity (0-1)."
|
|
3366
3606
|
},
|
|
3607
|
+
"fillOpacity": {
|
|
3608
|
+
"type": "number",
|
|
3609
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
3610
|
+
},
|
|
3611
|
+
"binCount": {
|
|
3612
|
+
"type": "number",
|
|
3613
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
3614
|
+
},
|
|
3615
|
+
"normalize": {
|
|
3616
|
+
"type": "boolean",
|
|
3617
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
3618
|
+
},
|
|
3619
|
+
"bandwidth": {
|
|
3620
|
+
"type": "number",
|
|
3621
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
3622
|
+
},
|
|
3623
|
+
"cumulative": {
|
|
3624
|
+
"type": "boolean",
|
|
3625
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
3626
|
+
},
|
|
3627
|
+
"steps": {
|
|
3628
|
+
"type": "number",
|
|
3629
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
3630
|
+
},
|
|
3367
3631
|
"fill": {
|
|
3368
3632
|
"anyOf": [
|
|
3369
3633
|
{
|
|
@@ -3686,6 +3950,30 @@
|
|
|
3686
3950
|
"type": "number",
|
|
3687
3951
|
"description": "Default opacity (0-1)."
|
|
3688
3952
|
},
|
|
3953
|
+
"fillOpacity": {
|
|
3954
|
+
"type": "number",
|
|
3955
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
3956
|
+
},
|
|
3957
|
+
"binCount": {
|
|
3958
|
+
"type": "number",
|
|
3959
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
3960
|
+
},
|
|
3961
|
+
"normalize": {
|
|
3962
|
+
"type": "boolean",
|
|
3963
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
3964
|
+
},
|
|
3965
|
+
"bandwidth": {
|
|
3966
|
+
"type": "number",
|
|
3967
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
3968
|
+
},
|
|
3969
|
+
"cumulative": {
|
|
3970
|
+
"type": "boolean",
|
|
3971
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
3972
|
+
},
|
|
3973
|
+
"steps": {
|
|
3974
|
+
"type": "number",
|
|
3975
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
3976
|
+
},
|
|
3689
3977
|
"fill": {
|
|
3690
3978
|
"anyOf": [
|
|
3691
3979
|
{
|
|
@@ -4008,6 +4296,30 @@
|
|
|
4008
4296
|
"type": "number",
|
|
4009
4297
|
"description": "Default opacity (0-1)."
|
|
4010
4298
|
},
|
|
4299
|
+
"fillOpacity": {
|
|
4300
|
+
"type": "number",
|
|
4301
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
4302
|
+
},
|
|
4303
|
+
"binCount": {
|
|
4304
|
+
"type": "number",
|
|
4305
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
4306
|
+
},
|
|
4307
|
+
"normalize": {
|
|
4308
|
+
"type": "boolean",
|
|
4309
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
4310
|
+
},
|
|
4311
|
+
"bandwidth": {
|
|
4312
|
+
"type": "number",
|
|
4313
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
4314
|
+
},
|
|
4315
|
+
"cumulative": {
|
|
4316
|
+
"type": "boolean",
|
|
4317
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
4318
|
+
},
|
|
4319
|
+
"steps": {
|
|
4320
|
+
"type": "number",
|
|
4321
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
4322
|
+
},
|
|
4011
4323
|
"fill": {
|
|
4012
4324
|
"anyOf": [
|
|
4013
4325
|
{
|
|
@@ -4330,6 +4642,30 @@
|
|
|
4330
4642
|
"type": "number",
|
|
4331
4643
|
"description": "Default opacity (0-1)."
|
|
4332
4644
|
},
|
|
4645
|
+
"fillOpacity": {
|
|
4646
|
+
"type": "number",
|
|
4647
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
4648
|
+
},
|
|
4649
|
+
"binCount": {
|
|
4650
|
+
"type": "number",
|
|
4651
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
4652
|
+
},
|
|
4653
|
+
"normalize": {
|
|
4654
|
+
"type": "boolean",
|
|
4655
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
4656
|
+
},
|
|
4657
|
+
"bandwidth": {
|
|
4658
|
+
"type": "number",
|
|
4659
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
4660
|
+
},
|
|
4661
|
+
"cumulative": {
|
|
4662
|
+
"type": "boolean",
|
|
4663
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
4664
|
+
},
|
|
4665
|
+
"steps": {
|
|
4666
|
+
"type": "number",
|
|
4667
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
4668
|
+
},
|
|
4333
4669
|
"fill": {
|
|
4334
4670
|
"anyOf": [
|
|
4335
4671
|
{
|
|
@@ -4652,6 +4988,30 @@
|
|
|
4652
4988
|
"type": "number",
|
|
4653
4989
|
"description": "Default opacity (0-1)."
|
|
4654
4990
|
},
|
|
4991
|
+
"fillOpacity": {
|
|
4992
|
+
"type": "number",
|
|
4993
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
4994
|
+
},
|
|
4995
|
+
"binCount": {
|
|
4996
|
+
"type": "number",
|
|
4997
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
4998
|
+
},
|
|
4999
|
+
"normalize": {
|
|
5000
|
+
"type": "boolean",
|
|
5001
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
5002
|
+
},
|
|
5003
|
+
"bandwidth": {
|
|
5004
|
+
"type": "number",
|
|
5005
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
5006
|
+
},
|
|
5007
|
+
"cumulative": {
|
|
5008
|
+
"type": "boolean",
|
|
5009
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
5010
|
+
},
|
|
5011
|
+
"steps": {
|
|
5012
|
+
"type": "number",
|
|
5013
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
5014
|
+
},
|
|
4655
5015
|
"fill": {
|
|
4656
5016
|
"anyOf": [
|
|
4657
5017
|
{
|
|
@@ -4974,6 +5334,30 @@
|
|
|
4974
5334
|
"type": "number",
|
|
4975
5335
|
"description": "Default opacity (0-1)."
|
|
4976
5336
|
},
|
|
5337
|
+
"fillOpacity": {
|
|
5338
|
+
"type": "number",
|
|
5339
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
5340
|
+
},
|
|
5341
|
+
"binCount": {
|
|
5342
|
+
"type": "number",
|
|
5343
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
5344
|
+
},
|
|
5345
|
+
"normalize": {
|
|
5346
|
+
"type": "boolean",
|
|
5347
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
5348
|
+
},
|
|
5349
|
+
"bandwidth": {
|
|
5350
|
+
"type": "number",
|
|
5351
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
5352
|
+
},
|
|
5353
|
+
"cumulative": {
|
|
5354
|
+
"type": "boolean",
|
|
5355
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
5356
|
+
},
|
|
5357
|
+
"steps": {
|
|
5358
|
+
"type": "number",
|
|
5359
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
5360
|
+
},
|
|
4977
5361
|
"fill": {
|
|
4978
5362
|
"anyOf": [
|
|
4979
5363
|
{
|
|
@@ -5159,74 +5543,768 @@
|
|
|
5159
5543
|
}
|
|
5160
5544
|
}
|
|
5161
5545
|
]
|
|
5162
|
-
}
|
|
5163
|
-
],
|
|
5164
|
-
"description": "Chart specification: the primary input for standard chart types.\n\nUses the Vega-Lite `mark` property instead of `type` to specify the visualization mark. The mark can be a string shorthand or an object with additional properties (interpolation, point markers, etc.).\n\nThis is a discriminated union — the `mark` value determines which encoding channels are required. TypeScript enforces required channels at compile time, matching the runtime rules in `MARK_ENCODING_RULES`."
|
|
5165
|
-
},
|
|
5166
|
-
"MarkType": {
|
|
5167
|
-
"type": "string",
|
|
5168
|
-
"enum": [
|
|
5169
|
-
"bar",
|
|
5170
|
-
"line",
|
|
5171
|
-
"area",
|
|
5172
|
-
"point",
|
|
5173
|
-
"circle",
|
|
5174
|
-
"arc",
|
|
5175
|
-
"text",
|
|
5176
|
-
"rule",
|
|
5177
|
-
"tick",
|
|
5178
|
-
"rect",
|
|
5179
|
-
"lollipop",
|
|
5180
|
-
"beeswarm",
|
|
5181
|
-
"range",
|
|
5182
|
-
"waffle",
|
|
5183
|
-
"calendar",
|
|
5184
|
-
"parliament"
|
|
5185
|
-
],
|
|
5186
|
-
"description": "Supported mark types, following Vega-Lite conventions.\n\nMapping from previous OpenChart chart types:\n- 'bar' covers both horizontal bars (old 'bar') and vertical columns (old 'column')\n- 'arc' covers both pie (old 'pie') and donut (old 'donut')\n- 'point' replaces old 'scatter'\n- 'circle' replaces old 'dot'\n- 'line' and 'area' unchanged\n\nNew mark types not in previous OpenChart:\n- 'text': data-positioned text labels\n- 'rule': reference lines as data marks\n- 'tick': strip/rug plot marks\n- 'rect': heatmaps and 2D binned plots\n- 'range': dumbbell / arrow / range-bar plots spanning two values per category\n- 'waffle': unit grids (\"x of 100\") for part-to-whole counts\n- 'calendar': GitHub-style calendar heatmap (weeks x weekdays, daily dates)\n- 'parliament': hemicycle seat-dot chart for election/legislature results"
|
|
5187
|
-
},
|
|
5188
|
-
"GradientDef": {
|
|
5189
|
-
"anyOf": [
|
|
5190
|
-
{
|
|
5191
|
-
"$ref": "#/definitions/LinearGradient"
|
|
5192
5546
|
},
|
|
5193
5547
|
{
|
|
5194
|
-
"
|
|
5195
|
-
|
|
5196
|
-
|
|
5197
|
-
|
|
5198
|
-
|
|
5199
|
-
|
|
5200
|
-
|
|
5201
|
-
|
|
5202
|
-
|
|
5203
|
-
|
|
5204
|
-
|
|
5205
|
-
|
|
5206
|
-
|
|
5207
|
-
|
|
5208
|
-
|
|
5209
|
-
|
|
5210
|
-
|
|
5211
|
-
|
|
5212
|
-
|
|
5213
|
-
|
|
5214
|
-
|
|
5215
|
-
|
|
5216
|
-
|
|
5217
|
-
|
|
5218
|
-
|
|
5219
|
-
|
|
5220
|
-
|
|
5221
|
-
|
|
5222
|
-
|
|
5223
|
-
|
|
5224
|
-
|
|
5225
|
-
|
|
5226
|
-
|
|
5227
|
-
|
|
5228
|
-
|
|
5229
|
-
|
|
5548
|
+
"allOf": [
|
|
5549
|
+
{
|
|
5550
|
+
"$ref": "#/definitions/ChartSpecBase"
|
|
5551
|
+
},
|
|
5552
|
+
{
|
|
5553
|
+
"type": "object",
|
|
5554
|
+
"required": [
|
|
5555
|
+
"data",
|
|
5556
|
+
"encoding",
|
|
5557
|
+
"mark"
|
|
5558
|
+
],
|
|
5559
|
+
"properties": {
|
|
5560
|
+
"mark": {
|
|
5561
|
+
"anyOf": [
|
|
5562
|
+
{
|
|
5563
|
+
"type": "string",
|
|
5564
|
+
"const": "histogram"
|
|
5565
|
+
},
|
|
5566
|
+
{
|
|
5567
|
+
"type": "object",
|
|
5568
|
+
"additionalProperties": false,
|
|
5569
|
+
"properties": {
|
|
5570
|
+
"type": {
|
|
5571
|
+
"$ref": "#/definitions/MarkType",
|
|
5572
|
+
"description": "The mark type."
|
|
5573
|
+
},
|
|
5574
|
+
"point": {
|
|
5575
|
+
"anyOf": [
|
|
5576
|
+
{
|
|
5577
|
+
"type": "boolean"
|
|
5578
|
+
},
|
|
5579
|
+
{
|
|
5580
|
+
"type": "string",
|
|
5581
|
+
"const": "transparent"
|
|
5582
|
+
},
|
|
5583
|
+
{
|
|
5584
|
+
"type": "string",
|
|
5585
|
+
"const": "endpoints"
|
|
5586
|
+
},
|
|
5587
|
+
{
|
|
5588
|
+
"type": "string",
|
|
5589
|
+
"const": "last"
|
|
5590
|
+
},
|
|
5591
|
+
{
|
|
5592
|
+
"type": "string",
|
|
5593
|
+
"const": "first"
|
|
5594
|
+
}
|
|
5595
|
+
],
|
|
5596
|
+
"description": "Show point markers on line/area marks.\n- true: filled circles at each data point\n- 'transparent': invisible hover targets (legacy behavior)\n- 'endpoints': show only first and last point per series (hollow dots)\n- 'last' / 'first': show only the last (or first) point — filled dot, no white halo. Useful for highlighting the latest reading on a line chart and the default for sparkline mode.\n- false: no point marks (default; uses voronoi overlay for tooltips)"
|
|
5597
|
+
},
|
|
5598
|
+
"interpolate": {
|
|
5599
|
+
"type": "string",
|
|
5600
|
+
"enum": [
|
|
5601
|
+
"linear",
|
|
5602
|
+
"monotone",
|
|
5603
|
+
"step",
|
|
5604
|
+
"step-before",
|
|
5605
|
+
"step-after",
|
|
5606
|
+
"basis",
|
|
5607
|
+
"cardinal",
|
|
5608
|
+
"natural"
|
|
5609
|
+
],
|
|
5610
|
+
"description": "Curve interpolation for line/area marks. Maps to d3-shape curve factories."
|
|
5611
|
+
},
|
|
5612
|
+
"orient": {
|
|
5613
|
+
"type": "string",
|
|
5614
|
+
"enum": [
|
|
5615
|
+
"horizontal",
|
|
5616
|
+
"vertical"
|
|
5617
|
+
],
|
|
5618
|
+
"description": "Explicit orientation override for bar marks."
|
|
5619
|
+
},
|
|
5620
|
+
"innerRadius": {
|
|
5621
|
+
"type": "number",
|
|
5622
|
+
"description": "Inner radius for arc marks. >0 produces a donut, 0 or omitted produces a pie."
|
|
5623
|
+
},
|
|
5624
|
+
"outerRadius": {
|
|
5625
|
+
"type": "number",
|
|
5626
|
+
"description": "Outer radius for arc marks."
|
|
5627
|
+
},
|
|
5628
|
+
"startAngle": {
|
|
5629
|
+
"type": "number",
|
|
5630
|
+
"description": "Start angle in radians for arc marks. Defaults to 0 (full pie/donut). Combined with `endAngle`, restricts the pie/donut to a partial sweep, e.g. `startAngle: -Math.PI / 2, endAngle: Math.PI / 2` for a half-donut (election-style results donut). Angles follow d3's convention: 0 is straight up, increasing clockwise. Only meaningful when `type` is `'arc'`."
|
|
5631
|
+
},
|
|
5632
|
+
"endAngle": {
|
|
5633
|
+
"type": "number",
|
|
5634
|
+
"description": "End angle in radians for arc marks. Defaults to 2*Math.PI (full pie/donut). See `startAngle`. Only meaningful when `type` is `'arc'`."
|
|
5635
|
+
},
|
|
5636
|
+
"centerLabel": {
|
|
5637
|
+
"anyOf": [
|
|
5638
|
+
{
|
|
5639
|
+
"type": "string"
|
|
5640
|
+
},
|
|
5641
|
+
{
|
|
5642
|
+
"type": "object",
|
|
5643
|
+
"properties": {
|
|
5644
|
+
"text": {
|
|
5645
|
+
"type": "string"
|
|
5646
|
+
},
|
|
5647
|
+
"subtitle": {
|
|
5648
|
+
"type": "string"
|
|
5649
|
+
}
|
|
5650
|
+
},
|
|
5651
|
+
"required": [
|
|
5652
|
+
"text"
|
|
5653
|
+
],
|
|
5654
|
+
"additionalProperties": false
|
|
5655
|
+
}
|
|
5656
|
+
],
|
|
5657
|
+
"description": "Donut center stat. A string renders one line; the object form adds a caption under it. Decorative (the number is already in the slices), and only meaningful when `type` is `'arc'` with an inner radius."
|
|
5658
|
+
},
|
|
5659
|
+
"cornerRadius": {
|
|
5660
|
+
"anyOf": [
|
|
5661
|
+
{
|
|
5662
|
+
"type": "number"
|
|
5663
|
+
},
|
|
5664
|
+
{
|
|
5665
|
+
"type": "string",
|
|
5666
|
+
"const": "pill"
|
|
5667
|
+
}
|
|
5668
|
+
],
|
|
5669
|
+
"description": "Corner radius for rect/bar marks. 'pill' sets rx to half the bar thickness."
|
|
5670
|
+
},
|
|
5671
|
+
"size": {
|
|
5672
|
+
"type": "number",
|
|
5673
|
+
"description": "Bar/column marks: fixed bar thickness in pixels. When set, bars are this height (horizontal) or width (vertical), centered within the band.\n\nPoint marks: the dot RADIUS in pixels (default 5, typical 2-12). This is NOT Vega-Lite's point `size`, which is an area in px^2 -- a VL size of 110 corresponds to `size: 6` here (r = sqrt(area / pi)). Validation rejects values above 50 with the conversion."
|
|
5674
|
+
},
|
|
5675
|
+
"filled": {
|
|
5676
|
+
"type": "boolean",
|
|
5677
|
+
"description": "Whether the mark is filled (vs stroked only)."
|
|
5678
|
+
},
|
|
5679
|
+
"opacity": {
|
|
5680
|
+
"type": "number",
|
|
5681
|
+
"description": "Default opacity (0-1)."
|
|
5682
|
+
},
|
|
5683
|
+
"fillOpacity": {
|
|
5684
|
+
"type": "number",
|
|
5685
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
5686
|
+
},
|
|
5687
|
+
"binCount": {
|
|
5688
|
+
"type": "number",
|
|
5689
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
5690
|
+
},
|
|
5691
|
+
"normalize": {
|
|
5692
|
+
"type": "boolean",
|
|
5693
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
5694
|
+
},
|
|
5695
|
+
"bandwidth": {
|
|
5696
|
+
"type": "number",
|
|
5697
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
5698
|
+
},
|
|
5699
|
+
"cumulative": {
|
|
5700
|
+
"type": "boolean",
|
|
5701
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
5702
|
+
},
|
|
5703
|
+
"steps": {
|
|
5704
|
+
"type": "number",
|
|
5705
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
5706
|
+
},
|
|
5707
|
+
"fill": {
|
|
5708
|
+
"anyOf": [
|
|
5709
|
+
{
|
|
5710
|
+
"type": "string"
|
|
5711
|
+
},
|
|
5712
|
+
{
|
|
5713
|
+
"$ref": "#/definitions/GradientDef"
|
|
5714
|
+
}
|
|
5715
|
+
],
|
|
5716
|
+
"description": "Default fill color or gradient."
|
|
5717
|
+
},
|
|
5718
|
+
"stroke": {
|
|
5719
|
+
"type": "string",
|
|
5720
|
+
"description": "Default stroke color."
|
|
5721
|
+
},
|
|
5722
|
+
"strokeWidth": {
|
|
5723
|
+
"type": "number",
|
|
5724
|
+
"description": "Default stroke width."
|
|
5725
|
+
},
|
|
5726
|
+
"tooltip": {
|
|
5727
|
+
"type": [
|
|
5728
|
+
"boolean",
|
|
5729
|
+
"null"
|
|
5730
|
+
],
|
|
5731
|
+
"description": "Tooltip behavior. null disables tooltips."
|
|
5732
|
+
},
|
|
5733
|
+
"clip": {
|
|
5734
|
+
"type": "boolean",
|
|
5735
|
+
"description": "Clip marks to the chart area."
|
|
5736
|
+
},
|
|
5737
|
+
"trendline": {
|
|
5738
|
+
"anyOf": [
|
|
5739
|
+
{
|
|
5740
|
+
"type": "boolean"
|
|
5741
|
+
},
|
|
5742
|
+
{
|
|
5743
|
+
"$ref": "#/definitions/TrendlineConfig"
|
|
5744
|
+
}
|
|
5745
|
+
],
|
|
5746
|
+
"description": "Overlay a least-squares regression line on scatter (point) marks. Defaults to true. Set `mark: { type: 'point', trendline: false }` to suppress it when the chart already carries its own reference line (e.g. a manual x=y diagonal in a separate layer), which would otherwise produce two competing diagonals.\n\nPass an object to control stacking order: the line renders `below` the points by default, but a dense scatter (thousands of overlapping dots) fully occludes a line drawn underneath, so `{ layer: 'above' }` lifts the reference line over the cloud."
|
|
5747
|
+
},
|
|
5748
|
+
"dx": {
|
|
5749
|
+
"type": "number",
|
|
5750
|
+
"description": "Horizontal pixel offset from the data anchor. Only meaningful when `type` is `'text'`. Use it to lift a label clear of the mark it annotates instead of shifting the underlying data value."
|
|
5751
|
+
},
|
|
5752
|
+
"dy": {
|
|
5753
|
+
"type": "number",
|
|
5754
|
+
"description": "Vertical pixel offset from the data anchor (negative = up). Only meaningful when `type` is `'text'`. `{ type: 'text', dy: -10 }` floats each label ten pixels above its point."
|
|
5755
|
+
},
|
|
5756
|
+
"align": {
|
|
5757
|
+
"type": "string",
|
|
5758
|
+
"enum": [
|
|
5759
|
+
"left",
|
|
5760
|
+
"center",
|
|
5761
|
+
"right"
|
|
5762
|
+
],
|
|
5763
|
+
"description": "Horizontal alignment of text marks relative to their anchor. Defaults to `'center'`."
|
|
5764
|
+
},
|
|
5765
|
+
"baseline": {
|
|
5766
|
+
"type": "string",
|
|
5767
|
+
"enum": [
|
|
5768
|
+
"top",
|
|
5769
|
+
"middle",
|
|
5770
|
+
"bottom"
|
|
5771
|
+
],
|
|
5772
|
+
"description": "Vertical alignment of text marks relative to their anchor. Defaults to `'middle'`."
|
|
5773
|
+
},
|
|
5774
|
+
"fontSize": {
|
|
5775
|
+
"type": "number",
|
|
5776
|
+
"description": "Font size in pixels for text marks. Ignored when the `size` encoding channel is present (which scales font size from a data field). `size` is already taken by bar thickness, hence the distinct name."
|
|
5777
|
+
},
|
|
5778
|
+
"fillPattern": {
|
|
5779
|
+
"type": "string",
|
|
5780
|
+
"enum": [
|
|
5781
|
+
"auto",
|
|
5782
|
+
"none"
|
|
5783
|
+
],
|
|
5784
|
+
"description": "Pattern-fill reinforcement for filled marks (bar, area, arc).\n\n- `'auto'`: assign a per-series SVG pattern (diagonal hatch, dots, crosshatch, vertical lines) layered over each series color so series remain distinguishable without color vision. Marks too small to show a legible pattern keep their solid fill.\n- `'none'` (default): solid fills only."
|
|
5785
|
+
},
|
|
5786
|
+
"style": {
|
|
5787
|
+
"type": "string",
|
|
5788
|
+
"enum": [
|
|
5789
|
+
"dumbbell",
|
|
5790
|
+
"arrow",
|
|
5791
|
+
"bar"
|
|
5792
|
+
],
|
|
5793
|
+
"description": "Visual style for range marks. Only meaningful when `type` is `'range'`.\n- 'dumbbell' (default): a dot at each end joined by a connector line. The start dot is muted, the end dot carries the accent color.\n- 'arrow': a line with an arrowhead at the x2/y2 end, the strongest \"change between two points in time\" form.\n- 'bar': a plain floating range bar spanning start to end."
|
|
5794
|
+
},
|
|
5795
|
+
"colorByDirection": {
|
|
5796
|
+
"type": "boolean",
|
|
5797
|
+
"description": "Color range marks by direction of change. Only meaningful when `type` is `'range'`. When true, increases (x2 > x, or y2 > y) use the theme's `positive` semantic color and decreases use `negative`. A field-based `encoding.color` takes precedence over direction coloring."
|
|
5798
|
+
},
|
|
5799
|
+
"units": {
|
|
5800
|
+
"type": "number",
|
|
5801
|
+
"description": "Total number of cells in a waffle grid. Only meaningful when `type` is `'waffle'`. Category values normalize to this many cells via largest-remainder rounding so the grid always sums exactly. Default 100."
|
|
5802
|
+
},
|
|
5803
|
+
"columns": {
|
|
5804
|
+
"type": "number",
|
|
5805
|
+
"description": "Number of columns in a waffle grid. Only meaningful when `type` is `'waffle'`. Rows derive from `units / columns`. Default 10."
|
|
5806
|
+
},
|
|
5807
|
+
"other": {
|
|
5808
|
+
"anyOf": [
|
|
5809
|
+
{
|
|
5810
|
+
"type": "number"
|
|
5811
|
+
},
|
|
5812
|
+
{
|
|
5813
|
+
"type": "object",
|
|
5814
|
+
"properties": {
|
|
5815
|
+
"threshold": {
|
|
5816
|
+
"type": "number"
|
|
5817
|
+
},
|
|
5818
|
+
"label": {
|
|
5819
|
+
"type": "string"
|
|
5820
|
+
}
|
|
5821
|
+
},
|
|
5822
|
+
"required": [
|
|
5823
|
+
"threshold"
|
|
5824
|
+
],
|
|
5825
|
+
"additionalProperties": false
|
|
5826
|
+
}
|
|
5827
|
+
],
|
|
5828
|
+
"description": "Opt-in \"Other\" bucketing for waffle grids. Only meaningful when `type` is `'waffle'`. Categories whose share of the total falls below `threshold` (a fraction, so `0.05` is 5%) merge into one trailing category. Off by default: bucketing is an editorial decision, not a layout default. Same shape as `SankeySpec.other`."
|
|
5829
|
+
},
|
|
5830
|
+
"weekStart": {
|
|
5831
|
+
"type": "string",
|
|
5832
|
+
"enum": [
|
|
5833
|
+
"monday",
|
|
5834
|
+
"sunday"
|
|
5835
|
+
],
|
|
5836
|
+
"description": "First day of the week for calendar marks. Only meaningful when `type` is `'calendar'`. Controls which weekday occupies the top row of each band. Defaults to 'monday' (ISO week convention)."
|
|
5837
|
+
},
|
|
5838
|
+
"cellRadius": {
|
|
5839
|
+
"type": "number",
|
|
5840
|
+
"description": "Corner radius in pixels for calendar day cells. Only meaningful when `type` is `'calendar'`. Defaults to 2."
|
|
5841
|
+
},
|
|
5842
|
+
"shape": {
|
|
5843
|
+
"type": "string",
|
|
5844
|
+
"const": "hemicycle",
|
|
5845
|
+
"description": "Seat layout shape for parliament marks. Only meaningful when `type` is `'parliament'`. `'hemicycle'` (default, and currently the only shape) packs seats into concentric semicircular arcs, party-grouped left to right."
|
|
5846
|
+
},
|
|
5847
|
+
"seatRadius": {
|
|
5848
|
+
"anyOf": [
|
|
5849
|
+
{
|
|
5850
|
+
"type": "number"
|
|
5851
|
+
},
|
|
5852
|
+
{
|
|
5853
|
+
"type": "string",
|
|
5854
|
+
"const": "auto"
|
|
5855
|
+
}
|
|
5856
|
+
],
|
|
5857
|
+
"description": "Seat dot radius in pixels for parliament marks. `'auto'` (default) sizes dots to fill the available hemicycle rings for the given seat count. Only meaningful when `type` is `'parliament'`."
|
|
5858
|
+
},
|
|
5859
|
+
"majorityLine": {
|
|
5860
|
+
"anyOf": [
|
|
5861
|
+
{
|
|
5862
|
+
"type": "boolean"
|
|
5863
|
+
},
|
|
5864
|
+
{
|
|
5865
|
+
"type": "object",
|
|
5866
|
+
"properties": {
|
|
5867
|
+
"seats": {
|
|
5868
|
+
"type": "number"
|
|
5869
|
+
},
|
|
5870
|
+
"label": {
|
|
5871
|
+
"type": "string"
|
|
5872
|
+
}
|
|
5873
|
+
},
|
|
5874
|
+
"additionalProperties": false
|
|
5875
|
+
}
|
|
5876
|
+
],
|
|
5877
|
+
"description": "The majority-threshold line and \"N to win\" label on parliament marks. Only meaningful when `type` is `'parliament'`. `true` (default) draws the line at a simple majority (half the seats plus one); `false` hides it. The object form overrides the threshold and label: `{ seats }` sets a custom seat count (e.g. a two-thirds supermajority) and `{ label }` overrides the default \"N to win\" text. A `seats` value outside `1..totalSeats` warns and falls back to the simple-majority default."
|
|
5878
|
+
}
|
|
5879
|
+
},
|
|
5880
|
+
"required": [
|
|
5881
|
+
"type"
|
|
5882
|
+
]
|
|
5883
|
+
}
|
|
5884
|
+
]
|
|
5885
|
+
},
|
|
5886
|
+
"encoding": {
|
|
5887
|
+
"$ref": "#/definitions/HistogramEncoding%3CDataRow%3E"
|
|
5888
|
+
}
|
|
5889
|
+
}
|
|
5890
|
+
}
|
|
5891
|
+
]
|
|
5892
|
+
},
|
|
5893
|
+
{
|
|
5894
|
+
"allOf": [
|
|
5895
|
+
{
|
|
5896
|
+
"$ref": "#/definitions/ChartSpecBase"
|
|
5897
|
+
},
|
|
5898
|
+
{
|
|
5899
|
+
"type": "object",
|
|
5900
|
+
"required": [
|
|
5901
|
+
"data",
|
|
5902
|
+
"encoding",
|
|
5903
|
+
"mark"
|
|
5904
|
+
],
|
|
5905
|
+
"properties": {
|
|
5906
|
+
"mark": {
|
|
5907
|
+
"anyOf": [
|
|
5908
|
+
{
|
|
5909
|
+
"type": "string",
|
|
5910
|
+
"const": "density"
|
|
5911
|
+
},
|
|
5912
|
+
{
|
|
5913
|
+
"type": "object",
|
|
5914
|
+
"additionalProperties": false,
|
|
5915
|
+
"properties": {
|
|
5916
|
+
"type": {
|
|
5917
|
+
"$ref": "#/definitions/MarkType",
|
|
5918
|
+
"description": "The mark type."
|
|
5919
|
+
},
|
|
5920
|
+
"point": {
|
|
5921
|
+
"anyOf": [
|
|
5922
|
+
{
|
|
5923
|
+
"type": "boolean"
|
|
5924
|
+
},
|
|
5925
|
+
{
|
|
5926
|
+
"type": "string",
|
|
5927
|
+
"const": "transparent"
|
|
5928
|
+
},
|
|
5929
|
+
{
|
|
5930
|
+
"type": "string",
|
|
5931
|
+
"const": "endpoints"
|
|
5932
|
+
},
|
|
5933
|
+
{
|
|
5934
|
+
"type": "string",
|
|
5935
|
+
"const": "last"
|
|
5936
|
+
},
|
|
5937
|
+
{
|
|
5938
|
+
"type": "string",
|
|
5939
|
+
"const": "first"
|
|
5940
|
+
}
|
|
5941
|
+
],
|
|
5942
|
+
"description": "Show point markers on line/area marks.\n- true: filled circles at each data point\n- 'transparent': invisible hover targets (legacy behavior)\n- 'endpoints': show only first and last point per series (hollow dots)\n- 'last' / 'first': show only the last (or first) point — filled dot, no white halo. Useful for highlighting the latest reading on a line chart and the default for sparkline mode.\n- false: no point marks (default; uses voronoi overlay for tooltips)"
|
|
5943
|
+
},
|
|
5944
|
+
"interpolate": {
|
|
5945
|
+
"type": "string",
|
|
5946
|
+
"enum": [
|
|
5947
|
+
"linear",
|
|
5948
|
+
"monotone",
|
|
5949
|
+
"step",
|
|
5950
|
+
"step-before",
|
|
5951
|
+
"step-after",
|
|
5952
|
+
"basis",
|
|
5953
|
+
"cardinal",
|
|
5954
|
+
"natural"
|
|
5955
|
+
],
|
|
5956
|
+
"description": "Curve interpolation for line/area marks. Maps to d3-shape curve factories."
|
|
5957
|
+
},
|
|
5958
|
+
"orient": {
|
|
5959
|
+
"type": "string",
|
|
5960
|
+
"enum": [
|
|
5961
|
+
"horizontal",
|
|
5962
|
+
"vertical"
|
|
5963
|
+
],
|
|
5964
|
+
"description": "Explicit orientation override for bar marks."
|
|
5965
|
+
},
|
|
5966
|
+
"innerRadius": {
|
|
5967
|
+
"type": "number",
|
|
5968
|
+
"description": "Inner radius for arc marks. >0 produces a donut, 0 or omitted produces a pie."
|
|
5969
|
+
},
|
|
5970
|
+
"outerRadius": {
|
|
5971
|
+
"type": "number",
|
|
5972
|
+
"description": "Outer radius for arc marks."
|
|
5973
|
+
},
|
|
5974
|
+
"startAngle": {
|
|
5975
|
+
"type": "number",
|
|
5976
|
+
"description": "Start angle in radians for arc marks. Defaults to 0 (full pie/donut). Combined with `endAngle`, restricts the pie/donut to a partial sweep, e.g. `startAngle: -Math.PI / 2, endAngle: Math.PI / 2` for a half-donut (election-style results donut). Angles follow d3's convention: 0 is straight up, increasing clockwise. Only meaningful when `type` is `'arc'`."
|
|
5977
|
+
},
|
|
5978
|
+
"endAngle": {
|
|
5979
|
+
"type": "number",
|
|
5980
|
+
"description": "End angle in radians for arc marks. Defaults to 2*Math.PI (full pie/donut). See `startAngle`. Only meaningful when `type` is `'arc'`."
|
|
5981
|
+
},
|
|
5982
|
+
"centerLabel": {
|
|
5983
|
+
"anyOf": [
|
|
5984
|
+
{
|
|
5985
|
+
"type": "string"
|
|
5986
|
+
},
|
|
5987
|
+
{
|
|
5988
|
+
"type": "object",
|
|
5989
|
+
"properties": {
|
|
5990
|
+
"text": {
|
|
5991
|
+
"type": "string"
|
|
5992
|
+
},
|
|
5993
|
+
"subtitle": {
|
|
5994
|
+
"type": "string"
|
|
5995
|
+
}
|
|
5996
|
+
},
|
|
5997
|
+
"required": [
|
|
5998
|
+
"text"
|
|
5999
|
+
],
|
|
6000
|
+
"additionalProperties": false
|
|
6001
|
+
}
|
|
6002
|
+
],
|
|
6003
|
+
"description": "Donut center stat. A string renders one line; the object form adds a caption under it. Decorative (the number is already in the slices), and only meaningful when `type` is `'arc'` with an inner radius."
|
|
6004
|
+
},
|
|
6005
|
+
"cornerRadius": {
|
|
6006
|
+
"anyOf": [
|
|
6007
|
+
{
|
|
6008
|
+
"type": "number"
|
|
6009
|
+
},
|
|
6010
|
+
{
|
|
6011
|
+
"type": "string",
|
|
6012
|
+
"const": "pill"
|
|
6013
|
+
}
|
|
6014
|
+
],
|
|
6015
|
+
"description": "Corner radius for rect/bar marks. 'pill' sets rx to half the bar thickness."
|
|
6016
|
+
},
|
|
6017
|
+
"size": {
|
|
6018
|
+
"type": "number",
|
|
6019
|
+
"description": "Bar/column marks: fixed bar thickness in pixels. When set, bars are this height (horizontal) or width (vertical), centered within the band.\n\nPoint marks: the dot RADIUS in pixels (default 5, typical 2-12). This is NOT Vega-Lite's point `size`, which is an area in px^2 -- a VL size of 110 corresponds to `size: 6` here (r = sqrt(area / pi)). Validation rejects values above 50 with the conversion."
|
|
6020
|
+
},
|
|
6021
|
+
"filled": {
|
|
6022
|
+
"type": "boolean",
|
|
6023
|
+
"description": "Whether the mark is filled (vs stroked only)."
|
|
6024
|
+
},
|
|
6025
|
+
"opacity": {
|
|
6026
|
+
"type": "number",
|
|
6027
|
+
"description": "Default opacity (0-1)."
|
|
6028
|
+
},
|
|
6029
|
+
"fillOpacity": {
|
|
6030
|
+
"type": "number",
|
|
6031
|
+
"description": "Fill opacity (0-1), independent of stroke (Vega-Lite aligned).\n\nOn a binned bar with more than one color group this defaults to 0.55 so overlapping distributions stay readable; set it explicitly to override. On an area, setting it switches the fill from the default gradient to a flat translucent series color — gradients and overlapping fills don't mix."
|
|
6032
|
+
},
|
|
6033
|
+
"binCount": {
|
|
6034
|
+
"type": "number",
|
|
6035
|
+
"description": "Number of bins. Only meaningful when `type` is `'histogram'`; desugars to `x.bin.maxbins`. Defaults to 20. For a fixed bin width or a pinned extent, write `x.bin` directly — it is the canonical form and takes precedence over this shorthand."
|
|
6036
|
+
},
|
|
6037
|
+
"normalize": {
|
|
6038
|
+
"type": "boolean",
|
|
6039
|
+
"description": "Plot each group's share of its own total instead of a raw count. Only meaningful when `type` is `'histogram'`. Makes two distributions of very different size directly comparable."
|
|
6040
|
+
},
|
|
6041
|
+
"bandwidth": {
|
|
6042
|
+
"type": "number",
|
|
6043
|
+
"description": "Gaussian kernel bandwidth. Only meaningful when `type` is `'density'`. Omitted uses Silverman's rule of thumb."
|
|
6044
|
+
},
|
|
6045
|
+
"cumulative": {
|
|
6046
|
+
"type": "boolean",
|
|
6047
|
+
"description": "Draw the cumulative distribution instead of the density. Only meaningful when `type` is `'density'`."
|
|
6048
|
+
},
|
|
6049
|
+
"steps": {
|
|
6050
|
+
"type": "number",
|
|
6051
|
+
"description": "Number of points the density curve is evaluated at. Only meaningful when `type` is `'density'`. Defaults to 200."
|
|
6052
|
+
},
|
|
6053
|
+
"fill": {
|
|
6054
|
+
"anyOf": [
|
|
6055
|
+
{
|
|
6056
|
+
"type": "string"
|
|
6057
|
+
},
|
|
6058
|
+
{
|
|
6059
|
+
"$ref": "#/definitions/GradientDef"
|
|
6060
|
+
}
|
|
6061
|
+
],
|
|
6062
|
+
"description": "Default fill color or gradient."
|
|
6063
|
+
},
|
|
6064
|
+
"stroke": {
|
|
6065
|
+
"type": "string",
|
|
6066
|
+
"description": "Default stroke color."
|
|
6067
|
+
},
|
|
6068
|
+
"strokeWidth": {
|
|
6069
|
+
"type": "number",
|
|
6070
|
+
"description": "Default stroke width."
|
|
6071
|
+
},
|
|
6072
|
+
"tooltip": {
|
|
6073
|
+
"type": [
|
|
6074
|
+
"boolean",
|
|
6075
|
+
"null"
|
|
6076
|
+
],
|
|
6077
|
+
"description": "Tooltip behavior. null disables tooltips."
|
|
6078
|
+
},
|
|
6079
|
+
"clip": {
|
|
6080
|
+
"type": "boolean",
|
|
6081
|
+
"description": "Clip marks to the chart area."
|
|
6082
|
+
},
|
|
6083
|
+
"trendline": {
|
|
6084
|
+
"anyOf": [
|
|
6085
|
+
{
|
|
6086
|
+
"type": "boolean"
|
|
6087
|
+
},
|
|
6088
|
+
{
|
|
6089
|
+
"$ref": "#/definitions/TrendlineConfig"
|
|
6090
|
+
}
|
|
6091
|
+
],
|
|
6092
|
+
"description": "Overlay a least-squares regression line on scatter (point) marks. Defaults to true. Set `mark: { type: 'point', trendline: false }` to suppress it when the chart already carries its own reference line (e.g. a manual x=y diagonal in a separate layer), which would otherwise produce two competing diagonals.\n\nPass an object to control stacking order: the line renders `below` the points by default, but a dense scatter (thousands of overlapping dots) fully occludes a line drawn underneath, so `{ layer: 'above' }` lifts the reference line over the cloud."
|
|
6093
|
+
},
|
|
6094
|
+
"dx": {
|
|
6095
|
+
"type": "number",
|
|
6096
|
+
"description": "Horizontal pixel offset from the data anchor. Only meaningful when `type` is `'text'`. Use it to lift a label clear of the mark it annotates instead of shifting the underlying data value."
|
|
6097
|
+
},
|
|
6098
|
+
"dy": {
|
|
6099
|
+
"type": "number",
|
|
6100
|
+
"description": "Vertical pixel offset from the data anchor (negative = up). Only meaningful when `type` is `'text'`. `{ type: 'text', dy: -10 }` floats each label ten pixels above its point."
|
|
6101
|
+
},
|
|
6102
|
+
"align": {
|
|
6103
|
+
"type": "string",
|
|
6104
|
+
"enum": [
|
|
6105
|
+
"left",
|
|
6106
|
+
"center",
|
|
6107
|
+
"right"
|
|
6108
|
+
],
|
|
6109
|
+
"description": "Horizontal alignment of text marks relative to their anchor. Defaults to `'center'`."
|
|
6110
|
+
},
|
|
6111
|
+
"baseline": {
|
|
6112
|
+
"type": "string",
|
|
6113
|
+
"enum": [
|
|
6114
|
+
"top",
|
|
6115
|
+
"middle",
|
|
6116
|
+
"bottom"
|
|
6117
|
+
],
|
|
6118
|
+
"description": "Vertical alignment of text marks relative to their anchor. Defaults to `'middle'`."
|
|
6119
|
+
},
|
|
6120
|
+
"fontSize": {
|
|
6121
|
+
"type": "number",
|
|
6122
|
+
"description": "Font size in pixels for text marks. Ignored when the `size` encoding channel is present (which scales font size from a data field). `size` is already taken by bar thickness, hence the distinct name."
|
|
6123
|
+
},
|
|
6124
|
+
"fillPattern": {
|
|
6125
|
+
"type": "string",
|
|
6126
|
+
"enum": [
|
|
6127
|
+
"auto",
|
|
6128
|
+
"none"
|
|
6129
|
+
],
|
|
6130
|
+
"description": "Pattern-fill reinforcement for filled marks (bar, area, arc).\n\n- `'auto'`: assign a per-series SVG pattern (diagonal hatch, dots, crosshatch, vertical lines) layered over each series color so series remain distinguishable without color vision. Marks too small to show a legible pattern keep their solid fill.\n- `'none'` (default): solid fills only."
|
|
6131
|
+
},
|
|
6132
|
+
"style": {
|
|
6133
|
+
"type": "string",
|
|
6134
|
+
"enum": [
|
|
6135
|
+
"dumbbell",
|
|
6136
|
+
"arrow",
|
|
6137
|
+
"bar"
|
|
6138
|
+
],
|
|
6139
|
+
"description": "Visual style for range marks. Only meaningful when `type` is `'range'`.\n- 'dumbbell' (default): a dot at each end joined by a connector line. The start dot is muted, the end dot carries the accent color.\n- 'arrow': a line with an arrowhead at the x2/y2 end, the strongest \"change between two points in time\" form.\n- 'bar': a plain floating range bar spanning start to end."
|
|
6140
|
+
},
|
|
6141
|
+
"colorByDirection": {
|
|
6142
|
+
"type": "boolean",
|
|
6143
|
+
"description": "Color range marks by direction of change. Only meaningful when `type` is `'range'`. When true, increases (x2 > x, or y2 > y) use the theme's `positive` semantic color and decreases use `negative`. A field-based `encoding.color` takes precedence over direction coloring."
|
|
6144
|
+
},
|
|
6145
|
+
"units": {
|
|
6146
|
+
"type": "number",
|
|
6147
|
+
"description": "Total number of cells in a waffle grid. Only meaningful when `type` is `'waffle'`. Category values normalize to this many cells via largest-remainder rounding so the grid always sums exactly. Default 100."
|
|
6148
|
+
},
|
|
6149
|
+
"columns": {
|
|
6150
|
+
"type": "number",
|
|
6151
|
+
"description": "Number of columns in a waffle grid. Only meaningful when `type` is `'waffle'`. Rows derive from `units / columns`. Default 10."
|
|
6152
|
+
},
|
|
6153
|
+
"other": {
|
|
6154
|
+
"anyOf": [
|
|
6155
|
+
{
|
|
6156
|
+
"type": "number"
|
|
6157
|
+
},
|
|
6158
|
+
{
|
|
6159
|
+
"type": "object",
|
|
6160
|
+
"properties": {
|
|
6161
|
+
"threshold": {
|
|
6162
|
+
"type": "number"
|
|
6163
|
+
},
|
|
6164
|
+
"label": {
|
|
6165
|
+
"type": "string"
|
|
6166
|
+
}
|
|
6167
|
+
},
|
|
6168
|
+
"required": [
|
|
6169
|
+
"threshold"
|
|
6170
|
+
],
|
|
6171
|
+
"additionalProperties": false
|
|
6172
|
+
}
|
|
6173
|
+
],
|
|
6174
|
+
"description": "Opt-in \"Other\" bucketing for waffle grids. Only meaningful when `type` is `'waffle'`. Categories whose share of the total falls below `threshold` (a fraction, so `0.05` is 5%) merge into one trailing category. Off by default: bucketing is an editorial decision, not a layout default. Same shape as `SankeySpec.other`."
|
|
6175
|
+
},
|
|
6176
|
+
"weekStart": {
|
|
6177
|
+
"type": "string",
|
|
6178
|
+
"enum": [
|
|
6179
|
+
"monday",
|
|
6180
|
+
"sunday"
|
|
6181
|
+
],
|
|
6182
|
+
"description": "First day of the week for calendar marks. Only meaningful when `type` is `'calendar'`. Controls which weekday occupies the top row of each band. Defaults to 'monday' (ISO week convention)."
|
|
6183
|
+
},
|
|
6184
|
+
"cellRadius": {
|
|
6185
|
+
"type": "number",
|
|
6186
|
+
"description": "Corner radius in pixels for calendar day cells. Only meaningful when `type` is `'calendar'`. Defaults to 2."
|
|
6187
|
+
},
|
|
6188
|
+
"shape": {
|
|
6189
|
+
"type": "string",
|
|
6190
|
+
"const": "hemicycle",
|
|
6191
|
+
"description": "Seat layout shape for parliament marks. Only meaningful when `type` is `'parliament'`. `'hemicycle'` (default, and currently the only shape) packs seats into concentric semicircular arcs, party-grouped left to right."
|
|
6192
|
+
},
|
|
6193
|
+
"seatRadius": {
|
|
6194
|
+
"anyOf": [
|
|
6195
|
+
{
|
|
6196
|
+
"type": "number"
|
|
6197
|
+
},
|
|
6198
|
+
{
|
|
6199
|
+
"type": "string",
|
|
6200
|
+
"const": "auto"
|
|
6201
|
+
}
|
|
6202
|
+
],
|
|
6203
|
+
"description": "Seat dot radius in pixels for parliament marks. `'auto'` (default) sizes dots to fill the available hemicycle rings for the given seat count. Only meaningful when `type` is `'parliament'`."
|
|
6204
|
+
},
|
|
6205
|
+
"majorityLine": {
|
|
6206
|
+
"anyOf": [
|
|
6207
|
+
{
|
|
6208
|
+
"type": "boolean"
|
|
6209
|
+
},
|
|
6210
|
+
{
|
|
6211
|
+
"type": "object",
|
|
6212
|
+
"properties": {
|
|
6213
|
+
"seats": {
|
|
6214
|
+
"type": "number"
|
|
6215
|
+
},
|
|
6216
|
+
"label": {
|
|
6217
|
+
"type": "string"
|
|
6218
|
+
}
|
|
6219
|
+
},
|
|
6220
|
+
"additionalProperties": false
|
|
6221
|
+
}
|
|
6222
|
+
],
|
|
6223
|
+
"description": "The majority-threshold line and \"N to win\" label on parliament marks. Only meaningful when `type` is `'parliament'`. `true` (default) draws the line at a simple majority (half the seats plus one); `false` hides it. The object form overrides the threshold and label: `{ seats }` sets a custom seat count (e.g. a two-thirds supermajority) and `{ label }` overrides the default \"N to win\" text. A `seats` value outside `1..totalSeats` warns and falls back to the simple-majority default."
|
|
6224
|
+
}
|
|
6225
|
+
},
|
|
6226
|
+
"required": [
|
|
6227
|
+
"type"
|
|
6228
|
+
]
|
|
6229
|
+
}
|
|
6230
|
+
]
|
|
6231
|
+
},
|
|
6232
|
+
"encoding": {
|
|
6233
|
+
"$ref": "#/definitions/DensityEncoding%3CDataRow%3E"
|
|
6234
|
+
}
|
|
6235
|
+
}
|
|
6236
|
+
}
|
|
6237
|
+
]
|
|
6238
|
+
}
|
|
6239
|
+
],
|
|
6240
|
+
"description": "Chart specification: the primary input for standard chart types.\n\nUses the Vega-Lite `mark` property instead of `type` to specify the visualization mark. The mark can be a string shorthand or an object with additional properties (interpolation, point markers, etc.).\n\nThis is a discriminated union — the `mark` value determines which encoding channels are required. TypeScript enforces required channels at compile time, matching the runtime rules in `MARK_ENCODING_RULES`."
|
|
6241
|
+
},
|
|
6242
|
+
"MarkType": {
|
|
6243
|
+
"type": "string",
|
|
6244
|
+
"enum": [
|
|
6245
|
+
"bar",
|
|
6246
|
+
"line",
|
|
6247
|
+
"area",
|
|
6248
|
+
"point",
|
|
6249
|
+
"circle",
|
|
6250
|
+
"arc",
|
|
6251
|
+
"text",
|
|
6252
|
+
"rule",
|
|
6253
|
+
"tick",
|
|
6254
|
+
"rect",
|
|
6255
|
+
"lollipop",
|
|
6256
|
+
"beeswarm",
|
|
6257
|
+
"range",
|
|
6258
|
+
"waffle",
|
|
6259
|
+
"calendar",
|
|
6260
|
+
"parliament",
|
|
6261
|
+
"histogram",
|
|
6262
|
+
"density"
|
|
6263
|
+
],
|
|
6264
|
+
"description": "Supported mark types, following Vega-Lite conventions.\n\nMapping from previous OpenChart chart types:\n- 'bar' covers both horizontal bars (old 'bar') and vertical columns (old 'column')\n- 'arc' covers both pie (old 'pie') and donut (old 'donut')\n- 'point' replaces old 'scatter'\n- 'circle' replaces old 'dot'\n- 'line' and 'area' unchanged\n\nNew mark types not in previous OpenChart:\n- 'text': data-positioned text labels\n- 'rule': reference lines as data marks\n- 'tick': strip/rug plot marks\n- 'rect': heatmaps and 2D binned plots\n- 'range': dumbbell / arrow / range-bar plots spanning two values per category\n- 'waffle': unit grids (\"x of 100\") for part-to-whole counts\n- 'calendar': GitHub-style calendar heatmap (weeks x weekdays, daily dates)\n- 'parliament': hemicycle seat-dot chart for election/legislature results\n- 'histogram': binned bars over a continuous field; sugar for a bar with `x.bin` + `y: { aggregate: 'count' }`\n- 'density': kernel density estimate drawn as a filled curve; sugar for an area over a density transform"
|
|
6265
|
+
},
|
|
6266
|
+
"GradientDef": {
|
|
6267
|
+
"anyOf": [
|
|
6268
|
+
{
|
|
6269
|
+
"$ref": "#/definitions/LinearGradient"
|
|
6270
|
+
},
|
|
6271
|
+
{
|
|
6272
|
+
"$ref": "#/definitions/RadialGradient"
|
|
6273
|
+
}
|
|
6274
|
+
],
|
|
6275
|
+
"description": "A gradient definition, either linear or radial."
|
|
6276
|
+
},
|
|
6277
|
+
"LinearGradient": {
|
|
6278
|
+
"type": "object",
|
|
6279
|
+
"properties": {
|
|
6280
|
+
"gradient": {
|
|
6281
|
+
"type": "string",
|
|
6282
|
+
"const": "linear"
|
|
6283
|
+
},
|
|
6284
|
+
"stops": {
|
|
6285
|
+
"type": "array",
|
|
6286
|
+
"items": {
|
|
6287
|
+
"$ref": "#/definitions/GradientStop"
|
|
6288
|
+
},
|
|
6289
|
+
"description": "Color stops from start to end."
|
|
6290
|
+
},
|
|
6291
|
+
"x1": {
|
|
6292
|
+
"type": "number",
|
|
6293
|
+
"description": "Start x coordinate (0-1). Default: 0."
|
|
6294
|
+
},
|
|
6295
|
+
"y1": {
|
|
6296
|
+
"type": "number",
|
|
6297
|
+
"description": "Start y coordinate (0-1). Default: 0."
|
|
6298
|
+
},
|
|
6299
|
+
"x2": {
|
|
6300
|
+
"type": "number",
|
|
6301
|
+
"description": "End x coordinate (0-1). Default: 0."
|
|
6302
|
+
},
|
|
6303
|
+
"y2": {
|
|
6304
|
+
"type": "number",
|
|
6305
|
+
"description": "End y coordinate (0-1). Default: 1 (top-to-bottom)."
|
|
6306
|
+
}
|
|
6307
|
+
},
|
|
5230
6308
|
"required": [
|
|
5231
6309
|
"gradient",
|
|
5232
6310
|
"stops"
|
|
@@ -6322,6 +7400,12 @@
|
|
|
6322
7400
|
{
|
|
6323
7401
|
"$ref": "#/definitions/AggregateTransform"
|
|
6324
7402
|
},
|
|
7403
|
+
{
|
|
7404
|
+
"$ref": "#/definitions/JoinAggregateTransform"
|
|
7405
|
+
},
|
|
7406
|
+
{
|
|
7407
|
+
"$ref": "#/definitions/DensityTransform"
|
|
7408
|
+
},
|
|
6325
7409
|
{
|
|
6326
7410
|
"$ref": "#/definitions/FoldTransform"
|
|
6327
7411
|
},
|
|
@@ -6488,19 +7572,114 @@
|
|
|
6488
7572
|
"additionalProperties": false
|
|
6489
7573
|
}
|
|
6490
7574
|
},
|
|
6491
|
-
"groupby": {
|
|
7575
|
+
"groupby": {
|
|
7576
|
+
"type": "array",
|
|
7577
|
+
"items": {
|
|
7578
|
+
"type": "string"
|
|
7579
|
+
}
|
|
7580
|
+
}
|
|
7581
|
+
},
|
|
7582
|
+
"required": [
|
|
7583
|
+
"aggregate",
|
|
7584
|
+
"groupby"
|
|
7585
|
+
],
|
|
7586
|
+
"additionalProperties": false,
|
|
7587
|
+
"description": "Aggregate transform: group rows and compute summary statistics (VL aligned). Produces one row per group with the groupby fields and computed aggregates."
|
|
7588
|
+
},
|
|
7589
|
+
"JoinAggregateTransform": {
|
|
7590
|
+
"type": "object",
|
|
7591
|
+
"properties": {
|
|
7592
|
+
"joinaggregate": {
|
|
7593
|
+
"type": "array",
|
|
7594
|
+
"items": {
|
|
7595
|
+
"type": "object",
|
|
7596
|
+
"properties": {
|
|
7597
|
+
"op": {
|
|
7598
|
+
"$ref": "#/definitions/AggregateOp"
|
|
7599
|
+
},
|
|
7600
|
+
"field": {
|
|
7601
|
+
"type": "string"
|
|
7602
|
+
},
|
|
7603
|
+
"as": {
|
|
7604
|
+
"type": "string"
|
|
7605
|
+
}
|
|
7606
|
+
},
|
|
7607
|
+
"required": [
|
|
7608
|
+
"op",
|
|
7609
|
+
"field",
|
|
7610
|
+
"as"
|
|
7611
|
+
],
|
|
7612
|
+
"additionalProperties": false
|
|
7613
|
+
}
|
|
7614
|
+
},
|
|
7615
|
+
"groupby": {
|
|
7616
|
+
"type": "array",
|
|
7617
|
+
"items": {
|
|
7618
|
+
"type": "string"
|
|
7619
|
+
},
|
|
7620
|
+
"description": "Fields to group by. Omitted or empty treats all rows as one group."
|
|
7621
|
+
}
|
|
7622
|
+
},
|
|
7623
|
+
"required": [
|
|
7624
|
+
"joinaggregate"
|
|
7625
|
+
],
|
|
7626
|
+
"additionalProperties": false,
|
|
7627
|
+
"description": "Join-aggregate transform: compute group summaries and write them back onto every row of the group (VL aligned).\n\nThe difference from `AggregateTransform` is the row count: `aggregate` collapses a group to one row, `joinaggregate` keeps every row and adds the group's summary as a new field. That is what makes \"this row's value as a share of its group's total\" expressible — compute the total, then divide."
|
|
7628
|
+
},
|
|
7629
|
+
"DensityTransform": {
|
|
7630
|
+
"type": "object",
|
|
7631
|
+
"properties": {
|
|
7632
|
+
"density": {
|
|
7633
|
+
"type": "string",
|
|
7634
|
+
"description": "Field of raw values to estimate the density of."
|
|
7635
|
+
},
|
|
7636
|
+
"groupby": {
|
|
7637
|
+
"type": "array",
|
|
7638
|
+
"items": {
|
|
7639
|
+
"type": "string"
|
|
7640
|
+
},
|
|
7641
|
+
"description": "Group the estimate by these fields; one curve per group."
|
|
7642
|
+
},
|
|
7643
|
+
"bandwidth": {
|
|
7644
|
+
"type": "number",
|
|
7645
|
+
"description": "Gaussian kernel bandwidth. Omitted or 0 uses Silverman's rule of thumb."
|
|
7646
|
+
},
|
|
7647
|
+
"extent": {
|
|
7648
|
+
"type": "array",
|
|
7649
|
+
"items": {
|
|
7650
|
+
"type": "number"
|
|
7651
|
+
},
|
|
7652
|
+
"minItems": 2,
|
|
7653
|
+
"maxItems": 2,
|
|
7654
|
+
"description": "[min, max] to evaluate over. Defaults to the data extent, padded to close the tails."
|
|
7655
|
+
},
|
|
7656
|
+
"cumulative": {
|
|
7657
|
+
"type": "boolean",
|
|
7658
|
+
"description": "Emit the cumulative distribution instead of the density."
|
|
7659
|
+
},
|
|
7660
|
+
"counts": {
|
|
7661
|
+
"type": "boolean",
|
|
7662
|
+
"description": "Scale the curve by the group's row count instead of integrating to 1."
|
|
7663
|
+
},
|
|
7664
|
+
"steps": {
|
|
7665
|
+
"type": "number",
|
|
7666
|
+
"description": "Number of evaluation points. Default 200."
|
|
7667
|
+
},
|
|
7668
|
+
"as": {
|
|
6492
7669
|
"type": "array",
|
|
6493
7670
|
"items": {
|
|
6494
7671
|
"type": "string"
|
|
6495
|
-
}
|
|
7672
|
+
},
|
|
7673
|
+
"minItems": 2,
|
|
7674
|
+
"maxItems": 2,
|
|
7675
|
+
"description": "Output field names. Default ['value', 'density']."
|
|
6496
7676
|
}
|
|
6497
7677
|
},
|
|
6498
7678
|
"required": [
|
|
6499
|
-
"
|
|
6500
|
-
"groupby"
|
|
7679
|
+
"density"
|
|
6501
7680
|
],
|
|
6502
7681
|
"additionalProperties": false,
|
|
6503
|
-
"description": "
|
|
7682
|
+
"description": "Density transform: kernel density estimate over a quantitative field (Vega-Lite aligned).\n\nProduces a new dataset — one row per evaluation point, per group — rather than adding fields to the input rows. The output is what an area mark plots."
|
|
6504
7683
|
},
|
|
6505
7684
|
"FoldTransform": {
|
|
6506
7685
|
"type": "object",
|
|
@@ -9824,6 +11003,242 @@
|
|
|
9824
11003
|
"additionalProperties": false,
|
|
9825
11004
|
"description": "Encoding for parliament marks (hemicycle seat-dot charts).\n- `color`: required (nominal/ordinal, the party)\n- `theta`: the canonical quantitative seat count, the same part-to-whole value channel arc/waffle marks use. `y` is a deprecated alias, accepted for backward compatibility."
|
|
9826
11005
|
},
|
|
11006
|
+
"HistogramEncoding<DataRow>": {
|
|
11007
|
+
"type": "object",
|
|
11008
|
+
"properties": {
|
|
11009
|
+
"x": {
|
|
11010
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11011
|
+
"description": "Horizontal position channel. Required for: bar, line, area, point, tick, rect, lollipop. Maps a field to the x-axis. Use `type: 'temporal'` for dates, `'nominal'` for categories, `'quantitative'` for numbers."
|
|
11012
|
+
},
|
|
11013
|
+
"y": {
|
|
11014
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11015
|
+
"description": "Vertical position channel. Required for: bar, line, area, point, tick, rect, arc, lollipop. For arc marks, this is the value field (slice size). For all others it's the y-axis position."
|
|
11016
|
+
},
|
|
11017
|
+
"color": {
|
|
11018
|
+
"anyOf": [
|
|
11019
|
+
{
|
|
11020
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
|
|
11021
|
+
},
|
|
11022
|
+
{
|
|
11023
|
+
"$ref": "#/definitions/ConditionalValueDef%3CDataRow%3E"
|
|
11024
|
+
},
|
|
11025
|
+
{
|
|
11026
|
+
"$ref": "#/definitions/ValueDef"
|
|
11027
|
+
}
|
|
11028
|
+
],
|
|
11029
|
+
"description": "Color channel. Required for arc marks (determines pie/donut slice coloring). Optional for all other marks -- used for series differentiation on multi-series charts, or heatmap intensity. Accepts a conditional definition to apply colors based on data predicates, or a bare `{ value }` constant (VL aligned; expanded to the mark-level fill/stroke)."
|
|
11030
|
+
},
|
|
11031
|
+
"size": {
|
|
11032
|
+
"anyOf": [
|
|
11033
|
+
{
|
|
11034
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
|
|
11035
|
+
},
|
|
11036
|
+
{
|
|
11037
|
+
"$ref": "#/definitions/ConditionalValueDef%3CDataRow%3E"
|
|
11038
|
+
},
|
|
11039
|
+
{
|
|
11040
|
+
"$ref": "#/definitions/ValueDef"
|
|
11041
|
+
}
|
|
11042
|
+
],
|
|
11043
|
+
"description": "Size channel. Used by point/bubble charts to scale dots by a quantitative field, area-proportionally (sqrt curve). The units are dot RADII in px: `scale.range` defaults to [3, 30] for scatter, and a bare `{ value }` constant expands to `mark.size`, also a radius. This differs from Vega-Lite, where point size is an area in px^2 -- VL-scale values (60-900) are rejected by validation with the conversion. Accepts a conditional definition to vary size based on data predicates."
|
|
11044
|
+
},
|
|
11045
|
+
"detail": {
|
|
11046
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11047
|
+
"description": "Detail channel. Groups data into multiple series without mapping to a visual property. Useful when you want separate lines per category but don't need the color to differ."
|
|
11048
|
+
},
|
|
11049
|
+
"key": {
|
|
11050
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11051
|
+
"description": "Identity channel for data-update transitions. Maps a field whose value uniquely identifies each datum across updates. Mirrors Vega-Lite's key channel. Not visually encoded. Optional: charts derive sensible default keys."
|
|
11052
|
+
},
|
|
11053
|
+
"x2": {
|
|
11054
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11055
|
+
"description": "Secondary x position. Used with `x` to define a horizontal span (rect marks, error bars). Both `x` and `x2` must be quantitative."
|
|
11056
|
+
},
|
|
11057
|
+
"y2": {
|
|
11058
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11059
|
+
"description": "Secondary y position. Used with `y` to define a vertical span (rect marks, error bands). Both `y` and `y2` must be quantitative."
|
|
11060
|
+
},
|
|
11061
|
+
"opacity": {
|
|
11062
|
+
"anyOf": [
|
|
11063
|
+
{
|
|
11064
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
|
|
11065
|
+
},
|
|
11066
|
+
{
|
|
11067
|
+
"$ref": "#/definitions/ConditionalValueDef%3CDataRow%3E"
|
|
11068
|
+
},
|
|
11069
|
+
{
|
|
11070
|
+
"$ref": "#/definitions/ValueDef"
|
|
11071
|
+
}
|
|
11072
|
+
],
|
|
11073
|
+
"description": "Data-driven opacity (0-1 range). Accepts a conditional definition to vary opacity based on data predicates (e.g., highlight selected points), or a bare `{ value }` constant (VL aligned; expanded to `mark.opacity`)."
|
|
11074
|
+
},
|
|
11075
|
+
"strokeDash": {
|
|
11076
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11077
|
+
"description": "Stroke dash pattern encoding. Maps a nominal/ordinal field to different dash patterns on line and rule marks. Useful when color alone doesn't distinguish series well."
|
|
11078
|
+
},
|
|
11079
|
+
"angle": {
|
|
11080
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11081
|
+
"description": "Rotation angle encoding for point marks. Maps a quantitative field to 0-360 degrees."
|
|
11082
|
+
},
|
|
11083
|
+
"text": {
|
|
11084
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11085
|
+
"description": "Text content for `text` marks. Required when mark is `'text'`. Not meaningful for other mark types."
|
|
11086
|
+
},
|
|
11087
|
+
"tooltip": {
|
|
11088
|
+
"anyOf": [
|
|
11089
|
+
{
|
|
11090
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
|
|
11091
|
+
},
|
|
11092
|
+
{
|
|
11093
|
+
"type": "array",
|
|
11094
|
+
"items": {
|
|
11095
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
|
|
11096
|
+
}
|
|
11097
|
+
}
|
|
11098
|
+
],
|
|
11099
|
+
"description": "Tooltip field(s). Shown on hover. Can be a single channel or an array for multi-field tooltips. Independent of the x/y/color encoding."
|
|
11100
|
+
},
|
|
11101
|
+
"theta": {
|
|
11102
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11103
|
+
"description": "Angular position (slice value) for arc marks (pie/donut), the canonical value channel in v8. Waffle and parliament marks accept it too (the same part-to-whole value channel). `y` is still accepted on these marks as a deprecated alias for backward compatibility (a compile warning is emitted and `y` is populated from `theta` internally). Not used by any other mark type."
|
|
11104
|
+
},
|
|
11105
|
+
"facet": {
|
|
11106
|
+
"$ref": "#/definitions/FacetChannel%3CDataRow%3E",
|
|
11107
|
+
"description": "Facet channel: partitions data into a grid of small-multiple panels. Each unique value of the facet field produces one panel. Panels share scales by default; use `resolve: { scale: { y: 'independent' } }` for per-panel axes."
|
|
11108
|
+
},
|
|
11109
|
+
"row": {
|
|
11110
|
+
"$ref": "#/definitions/FacetChannel%3CDataRow%3E",
|
|
11111
|
+
"description": "Row facet channel: partitions data into vertically-stacked panels. Each unique value of the row field produces one panel, arranged in a single column. Shares the x-axis scale by default; y-axis is independent. Mutually exclusive with `facet` and `column`."
|
|
11112
|
+
},
|
|
11113
|
+
"column": {
|
|
11114
|
+
"$ref": "#/definitions/FacetChannel%3CDataRow%3E",
|
|
11115
|
+
"description": "Column facet channel: partitions data into side-by-side panels. Each unique value of the column field produces one panel, arranged in a single row. Shares the y-axis scale by default; x-axis is independent. Mutually exclusive with `facet` and `row`."
|
|
11116
|
+
}
|
|
11117
|
+
},
|
|
11118
|
+
"required": [
|
|
11119
|
+
"x"
|
|
11120
|
+
],
|
|
11121
|
+
"additionalProperties": false,
|
|
11122
|
+
"description": "Encoding for histogram marks (binned bars over a continuous field).\n- `x`: required quantitative, the raw values to bin (not pre-binned)\n- `y`: optional; defaults to the per-bin count\n- `color`: optional grouping. Groups overlap at the same bins rather than dodging or stacking, so two distributions can be compared by shape."
|
|
11123
|
+
},
|
|
11124
|
+
"DensityEncoding<DataRow>": {
|
|
11125
|
+
"type": "object",
|
|
11126
|
+
"properties": {
|
|
11127
|
+
"x": {
|
|
11128
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11129
|
+
"description": "Horizontal position channel. Required for: bar, line, area, point, tick, rect, lollipop. Maps a field to the x-axis. Use `type: 'temporal'` for dates, `'nominal'` for categories, `'quantitative'` for numbers."
|
|
11130
|
+
},
|
|
11131
|
+
"y": {
|
|
11132
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11133
|
+
"description": "Vertical position channel. Required for: bar, line, area, point, tick, rect, arc, lollipop. For arc marks, this is the value field (slice size). For all others it's the y-axis position."
|
|
11134
|
+
},
|
|
11135
|
+
"color": {
|
|
11136
|
+
"anyOf": [
|
|
11137
|
+
{
|
|
11138
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
|
|
11139
|
+
},
|
|
11140
|
+
{
|
|
11141
|
+
"$ref": "#/definitions/ConditionalValueDef%3CDataRow%3E"
|
|
11142
|
+
},
|
|
11143
|
+
{
|
|
11144
|
+
"$ref": "#/definitions/ValueDef"
|
|
11145
|
+
}
|
|
11146
|
+
],
|
|
11147
|
+
"description": "Color channel. Required for arc marks (determines pie/donut slice coloring). Optional for all other marks -- used for series differentiation on multi-series charts, or heatmap intensity. Accepts a conditional definition to apply colors based on data predicates, or a bare `{ value }` constant (VL aligned; expanded to the mark-level fill/stroke)."
|
|
11148
|
+
},
|
|
11149
|
+
"size": {
|
|
11150
|
+
"anyOf": [
|
|
11151
|
+
{
|
|
11152
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
|
|
11153
|
+
},
|
|
11154
|
+
{
|
|
11155
|
+
"$ref": "#/definitions/ConditionalValueDef%3CDataRow%3E"
|
|
11156
|
+
},
|
|
11157
|
+
{
|
|
11158
|
+
"$ref": "#/definitions/ValueDef"
|
|
11159
|
+
}
|
|
11160
|
+
],
|
|
11161
|
+
"description": "Size channel. Used by point/bubble charts to scale dots by a quantitative field, area-proportionally (sqrt curve). The units are dot RADII in px: `scale.range` defaults to [3, 30] for scatter, and a bare `{ value }` constant expands to `mark.size`, also a radius. This differs from Vega-Lite, where point size is an area in px^2 -- VL-scale values (60-900) are rejected by validation with the conversion. Accepts a conditional definition to vary size based on data predicates."
|
|
11162
|
+
},
|
|
11163
|
+
"detail": {
|
|
11164
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11165
|
+
"description": "Detail channel. Groups data into multiple series without mapping to a visual property. Useful when you want separate lines per category but don't need the color to differ."
|
|
11166
|
+
},
|
|
11167
|
+
"key": {
|
|
11168
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11169
|
+
"description": "Identity channel for data-update transitions. Maps a field whose value uniquely identifies each datum across updates. Mirrors Vega-Lite's key channel. Not visually encoded. Optional: charts derive sensible default keys."
|
|
11170
|
+
},
|
|
11171
|
+
"x2": {
|
|
11172
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11173
|
+
"description": "Secondary x position. Used with `x` to define a horizontal span (rect marks, error bars). Both `x` and `x2` must be quantitative."
|
|
11174
|
+
},
|
|
11175
|
+
"y2": {
|
|
11176
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11177
|
+
"description": "Secondary y position. Used with `y` to define a vertical span (rect marks, error bands). Both `y` and `y2` must be quantitative."
|
|
11178
|
+
},
|
|
11179
|
+
"opacity": {
|
|
11180
|
+
"anyOf": [
|
|
11181
|
+
{
|
|
11182
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
|
|
11183
|
+
},
|
|
11184
|
+
{
|
|
11185
|
+
"$ref": "#/definitions/ConditionalValueDef%3CDataRow%3E"
|
|
11186
|
+
},
|
|
11187
|
+
{
|
|
11188
|
+
"$ref": "#/definitions/ValueDef"
|
|
11189
|
+
}
|
|
11190
|
+
],
|
|
11191
|
+
"description": "Data-driven opacity (0-1 range). Accepts a conditional definition to vary opacity based on data predicates (e.g., highlight selected points), or a bare `{ value }` constant (VL aligned; expanded to `mark.opacity`)."
|
|
11192
|
+
},
|
|
11193
|
+
"strokeDash": {
|
|
11194
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11195
|
+
"description": "Stroke dash pattern encoding. Maps a nominal/ordinal field to different dash patterns on line and rule marks. Useful when color alone doesn't distinguish series well."
|
|
11196
|
+
},
|
|
11197
|
+
"angle": {
|
|
11198
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11199
|
+
"description": "Rotation angle encoding for point marks. Maps a quantitative field to 0-360 degrees."
|
|
11200
|
+
},
|
|
11201
|
+
"text": {
|
|
11202
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11203
|
+
"description": "Text content for `text` marks. Required when mark is `'text'`. Not meaningful for other mark types."
|
|
11204
|
+
},
|
|
11205
|
+
"tooltip": {
|
|
11206
|
+
"anyOf": [
|
|
11207
|
+
{
|
|
11208
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
|
|
11209
|
+
},
|
|
11210
|
+
{
|
|
11211
|
+
"type": "array",
|
|
11212
|
+
"items": {
|
|
11213
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
|
|
11214
|
+
}
|
|
11215
|
+
}
|
|
11216
|
+
],
|
|
11217
|
+
"description": "Tooltip field(s). Shown on hover. Can be a single channel or an array for multi-field tooltips. Independent of the x/y/color encoding."
|
|
11218
|
+
},
|
|
11219
|
+
"theta": {
|
|
11220
|
+
"$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
|
|
11221
|
+
"description": "Angular position (slice value) for arc marks (pie/donut), the canonical value channel in v8. Waffle and parliament marks accept it too (the same part-to-whole value channel). `y` is still accepted on these marks as a deprecated alias for backward compatibility (a compile warning is emitted and `y` is populated from `theta` internally). Not used by any other mark type."
|
|
11222
|
+
},
|
|
11223
|
+
"facet": {
|
|
11224
|
+
"$ref": "#/definitions/FacetChannel%3CDataRow%3E",
|
|
11225
|
+
"description": "Facet channel: partitions data into a grid of small-multiple panels. Each unique value of the facet field produces one panel. Panels share scales by default; use `resolve: { scale: { y: 'independent' } }` for per-panel axes."
|
|
11226
|
+
},
|
|
11227
|
+
"row": {
|
|
11228
|
+
"$ref": "#/definitions/FacetChannel%3CDataRow%3E",
|
|
11229
|
+
"description": "Row facet channel: partitions data into vertically-stacked panels. Each unique value of the row field produces one panel, arranged in a single column. Shares the x-axis scale by default; y-axis is independent. Mutually exclusive with `facet` and `column`."
|
|
11230
|
+
},
|
|
11231
|
+
"column": {
|
|
11232
|
+
"$ref": "#/definitions/FacetChannel%3CDataRow%3E",
|
|
11233
|
+
"description": "Column facet channel: partitions data into side-by-side panels. Each unique value of the column field produces one panel, arranged in a single row. Shares the y-axis scale by default; x-axis is independent. Mutually exclusive with `facet` and `row`."
|
|
11234
|
+
}
|
|
11235
|
+
},
|
|
11236
|
+
"required": [
|
|
11237
|
+
"x"
|
|
11238
|
+
],
|
|
11239
|
+
"additionalProperties": false,
|
|
11240
|
+
"description": "Encoding for density marks (kernel density estimates).\n- `x`: required quantitative, the raw values to estimate over\n- `y`: computed by the density transform, not authored\n- `color`: optional grouping, one translucent curve per group"
|
|
11241
|
+
},
|
|
9827
11242
|
"ChartSpecBase": {
|
|
9828
11243
|
"type": "object",
|
|
9829
11244
|
"additionalProperties": false,
|