@opendata-ai/openchart-core 9.0.0-rc.1 → 9.0.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.
@@ -37,6 +37,105 @@
37
37
  },
38
38
  "ChartSpec": {
39
39
  "anyOf": [
40
+ {
41
+ "allOf": [
42
+ {
43
+ "$ref": "#/definitions/ChartSpecBase"
44
+ },
45
+ {
46
+ "type": "object",
47
+ "required": [
48
+ "data",
49
+ "encoding",
50
+ "mark"
51
+ ],
52
+ "properties": {
53
+ "mark": {
54
+ "anyOf": [
55
+ {
56
+ "type": "string",
57
+ "const": "errorbar"
58
+ },
59
+ {
60
+ "type": "object",
61
+ "additionalProperties": false,
62
+ "properties": {
63
+ "ticks": {
64
+ "type": "boolean",
65
+ "description": "Draw decorative end caps on an explicit interval; default false."
66
+ },
67
+ "type": {
68
+ "type": "string",
69
+ "const": "errorbar"
70
+ },
71
+ "size": {
72
+ "type": "number",
73
+ "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."
74
+ },
75
+ "filled": {
76
+ "type": "boolean",
77
+ "description": "Whether the mark is filled (vs stroked only)."
78
+ },
79
+ "opacity": {
80
+ "type": "number",
81
+ "description": "Default opacity (0-1)."
82
+ },
83
+ "fillOpacity": {
84
+ "type": "number",
85
+ "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."
86
+ },
87
+ "fill": {
88
+ "anyOf": [
89
+ {
90
+ "type": "string"
91
+ },
92
+ {
93
+ "$ref": "#/definitions/GradientDef"
94
+ }
95
+ ],
96
+ "description": "Default fill color or gradient."
97
+ },
98
+ "stroke": {
99
+ "type": "string",
100
+ "description": "Default stroke color."
101
+ },
102
+ "strokeWidth": {
103
+ "type": "number",
104
+ "description": "Default stroke width."
105
+ },
106
+ "tooltip": {
107
+ "type": [
108
+ "boolean",
109
+ "null"
110
+ ],
111
+ "description": "Tooltip behavior. null disables tooltips."
112
+ },
113
+ "clip": {
114
+ "type": "boolean",
115
+ "description": "Clip marks to the chart area."
116
+ },
117
+ "fillPattern": {
118
+ "type": "string",
119
+ "enum": [
120
+ "auto",
121
+ "none"
122
+ ],
123
+ "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."
124
+ }
125
+ },
126
+ "required": [
127
+ "type"
128
+ ]
129
+ }
130
+ ]
131
+ },
132
+ "encoding": {
133
+ "$ref": "#/definitions/ErrorbarEncoding%3CDataRow%3E"
134
+ }
135
+ }
136
+ }
137
+ ]
138
+ },
40
139
  {
41
140
  "allOf": [
42
141
  {
@@ -2239,9 +2338,13 @@
2239
2338
  "additionalProperties": false,
2240
2339
  "description": "Radial gradient definition. Coordinates are in [0,1] normalized space relative to the mark's bounding box."
2241
2340
  },
2242
- "ArcEncoding<DataRow>": {
2341
+ "ErrorbarEncoding<DataRow>": {
2243
2342
  "type": "object",
2244
2343
  "properties": {
2344
+ "description": {
2345
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
2346
+ "description": "Accessible mark description; static output exposes it as a native title."
2347
+ },
2245
2348
  "x": {
2246
2349
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
2247
2350
  "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."
@@ -2257,6 +2360,9 @@
2257
2360
  },
2258
2361
  {
2259
2362
  "$ref": "#/definitions/ConditionalValueDef%3CDataRow%3E"
2363
+ },
2364
+ {
2365
+ "$ref": "#/definitions/ValueDef"
2260
2366
  }
2261
2367
  ],
2262
2368
  "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)."
@@ -2333,7 +2439,7 @@
2333
2439
  },
2334
2440
  "theta": {
2335
2441
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
2336
- "description": "Canonical value channel for arc marks (quantitative — the slice value)."
2442
+ "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). The compiler populates internal `y` from `theta`; authored `y` aliases are rejected. Not used by any other mark type."
2337
2443
  },
2338
2444
  "facet": {
2339
2445
  "$ref": "#/definitions/FacetChannel%3CDataRow%3E",
@@ -2349,11 +2455,59 @@
2349
2455
  }
2350
2456
  },
2351
2457
  "required": [
2352
- "theta",
2353
- "color"
2458
+ "x",
2459
+ "y"
2354
2460
  ],
2355
2461
  "additionalProperties": false,
2356
- "description": "Encoding for arc marks (pie/donut charts).\n- `theta`: required (quantitative — the canonical slice value channel)\n- `color`: required (nominal/ordinal — the category)"
2462
+ "description": "Explicit interval bounds; runtime validation requires exactly one of x2/y2."
2463
+ },
2464
+ "DescriptionEncoding<DataRow>": {
2465
+ "anyOf": [
2466
+ {
2467
+ "type": "object",
2468
+ "additionalProperties": false,
2469
+ "properties": {
2470
+ "type": {
2471
+ "$ref": "#/definitions/FieldType",
2472
+ "description": "How to interpret the field values.\n- quantitative: continuous numbers (scale: linear)\n- temporal: dates/times (scale: time)\n- nominal: unordered categories (scale: ordinal)\n- ordinal: ordered categories (scale: ordinal)"
2473
+ },
2474
+ "format": {
2475
+ "type": "string",
2476
+ "description": "Format string for values (Vega-Lite aligned). For quantitative fields: d3-format string (e.g. \",.0f\", \"$,.2f\"), or semantic keyword `'percent'` / `'currency'`. For temporal fields: d3-time-format string (e.g. \"%Y\", \"%b %d\"). Used in tooltips; `axis.format` takes precedence for axis tick labels."
2477
+ },
2478
+ "field": {
2479
+ "type": "string",
2480
+ "description": "Data field name (column in the data array).\n\nWhen using `ChartSpec<TData>` with a typed data array, this is constrained to the actual column names of `TData`. Typos fail at compile time and IDEs autocomplete your column names."
2481
+ }
2482
+ },
2483
+ "required": [
2484
+ "field"
2485
+ ]
2486
+ },
2487
+ {
2488
+ "type": "object",
2489
+ "properties": {
2490
+ "value": {
2491
+ "type": "string"
2492
+ }
2493
+ },
2494
+ "required": [
2495
+ "value"
2496
+ ],
2497
+ "additionalProperties": false
2498
+ }
2499
+ ],
2500
+ "description": "Authored mark text, kept verbatim for strings and formatted for numeric fields."
2501
+ },
2502
+ "FieldType": {
2503
+ "type": "string",
2504
+ "enum": [
2505
+ "quantitative",
2506
+ "temporal",
2507
+ "nominal",
2508
+ "ordinal"
2509
+ ],
2510
+ "description": "Data field type, following Vega-Lite conventions."
2357
2511
  },
2358
2512
  "EncodingChannel<DataRow>": {
2359
2513
  "type": "object",
@@ -2366,6 +2520,34 @@
2366
2520
  "$ref": "#/definitions/FieldType",
2367
2521
  "description": "How to interpret the field values.\n- quantitative: continuous numbers (scale: linear)\n- temporal: dates/times (scale: time)\n- nominal: unordered categories (scale: ordinal)\n- ordinal: ordered categories (scale: ordinal)"
2368
2522
  },
2523
+ "interval": {
2524
+ "anyOf": [
2525
+ {
2526
+ "type": "string",
2527
+ "const": "day"
2528
+ },
2529
+ {
2530
+ "type": "string",
2531
+ "const": "week"
2532
+ },
2533
+ {
2534
+ "type": "string",
2535
+ "const": "month"
2536
+ },
2537
+ {
2538
+ "type": "string",
2539
+ "const": "quarter"
2540
+ },
2541
+ {
2542
+ "type": "string",
2543
+ "const": "year"
2544
+ },
2545
+ {
2546
+ "type": "number"
2547
+ }
2548
+ ],
2549
+ "description": "Temporal bar position interval; numbers are milliseconds. Bar marks only."
2550
+ },
2369
2551
  "aggregate": {
2370
2552
  "$ref": "#/definitions/AggregateOp",
2371
2553
  "description": "Optional aggregate to apply before encoding."
@@ -2509,16 +2691,6 @@
2509
2691
  "additionalProperties": false,
2510
2692
  "description": "A single encoding channel mapping a data field to a visual property.\n\nFollows the Vega-Lite encoding model: field identifies the column, type determines how the engine interprets values, aggregate applies a transformation before encoding."
2511
2693
  },
2512
- "FieldType": {
2513
- "type": "string",
2514
- "enum": [
2515
- "quantitative",
2516
- "temporal",
2517
- "nominal",
2518
- "ordinal"
2519
- ],
2520
- "description": "Data field type, following Vega-Lite conventions."
2521
- },
2522
2694
  "AggregateOp": {
2523
2695
  "type": "string",
2524
2696
  "enum": [
@@ -3234,6 +3406,19 @@
3234
3406
  "additionalProperties": false,
3235
3407
  "description": "Facet channel definition: partitions data into small-multiple panels.\n\nUnlike positional channels, facet only needs a field, a categorical type, and optional layout hints (columns, sort). It does not carry scale/axis config because it produces a grid, not a visual encoding."
3236
3408
  },
3409
+ "FrameConfig": {
3410
+ "type": "object",
3411
+ "properties": {
3412
+ "left": {
3413
+ "type": "number"
3414
+ },
3415
+ "right": {
3416
+ "type": "number"
3417
+ }
3418
+ },
3419
+ "additionalProperties": false,
3420
+ "description": "Fixed horizontal figure gutters in CSS pixels."
3421
+ },
3237
3422
  "FieldMetadata": {
3238
3423
  "type": "object",
3239
3424
  "properties": {
@@ -3852,6 +4037,10 @@
3852
4037
  "type": "string",
3853
4038
  "description": "Alt text announced by screen readers for the chart as a whole. Replaces the auto-generated description. Also settable via the top-level `description` field (Vega-Lite convention); this field wins when both are present."
3854
4039
  },
4040
+ "table": {
4041
+ "type": "boolean",
4042
+ "description": "Render the hidden screen-reader data table. Defaults to true; navigation stays enabled."
4043
+ },
3855
4044
  "hidden": {
3856
4045
  "type": "boolean",
3857
4046
  "description": "Hide the chart from assistive technology entirely (`aria-hidden`). Use only when the chart is decorative or the surrounding content already conveys the same information. Also suppresses the hidden screen-reader data table and keyboard mark navigation."
@@ -4331,6 +4520,10 @@
4331
4520
  "LabelConfig": {
4332
4521
  "type": "object",
4333
4522
  "properties": {
4523
+ "content": {
4524
+ "$ref": "#/definitions/EndpointLabelContent",
4525
+ "description": "Compose category/series names and formatted values; default value only."
4526
+ },
4334
4527
  "placement": {
4335
4528
  "type": "string",
4336
4529
  "enum": [
@@ -4369,6 +4562,15 @@
4369
4562
  "additionalProperties": false,
4370
4563
  "description": "Label display configuration for chart data labels."
4371
4564
  },
4565
+ "EndpointLabelContent": {
4566
+ "type": "string",
4567
+ "enum": [
4568
+ "label",
4569
+ "value",
4570
+ "label value"
4571
+ ],
4572
+ "description": "Content composition for an endpoint-label entry: the series name, the formatted value, or both joined on one line. See {@link EndpointLabelsConfig.content } ."
4573
+ },
4372
4574
  "LabelDensity": {
4373
4575
  "type": "string",
4374
4576
  "enum": [
@@ -4477,15 +4679,6 @@
4477
4679
  "additionalProperties": false,
4478
4680
  "description": "Configuration for the endpoint labels column rendered at the chart's right edge for multi-series line/area charts. Each entry pairs the series name with its last formatted value, optionally anchored to the line by an open-circle marker.\n\nThe column and traditional legend are independent identification surfaces. For multi-series line/area charts:\n\n| `legend.show` | `endpointLabels` | Traditional legend | Endpoint column | |--|--|--|--| | unset | unset | hidden | shown | | true | unset | shown | shown | | unset | false | shown | hidden | | false | false | hidden (accessibility warning) | hidden | | true | false | shown | hidden | | false | true | hidden | shown | | true | true | shown | shown |\n\nSingle-series charts: column is hidden by default (nothing to identify).\n\nThe implementation is in `packages/engine/src/legend/suppression.ts` — `resolveSuppression` is the single source of truth. The table above is a user-facing mirror; if the two ever diverge, the engine wins. Tests in `legend/__tests__/suppression.test.ts` enforce every cell."
4479
4681
  },
4480
- "EndpointLabelContent": {
4481
- "type": "string",
4482
- "enum": [
4483
- "label",
4484
- "value",
4485
- "label value"
4486
- ],
4487
- "description": "Content composition for an endpoint-label entry: the series name, the formatted value, or both joined on one line. See {@link EndpointLabelsConfig.content } ."
4488
- },
4489
4682
  "ResponsiveConfig": {
4490
4683
  "type": "object",
4491
4684
  "properties": {
@@ -4529,14 +4722,14 @@
4529
4722
  "categorical": {
4530
4723
  "type": "array",
4531
4724
  "items": {
4532
- "type": "string"
4725
+ "$ref": "#/definitions/TokenValue"
4533
4726
  },
4534
- "description": "Categorical stroke palette for nominal data (array of CSS color strings)."
4727
+ "description": "Categorical stroke palette: CSS colors or explicit light/dark pairs."
4535
4728
  },
4536
4729
  "categoricalFill": {
4537
4730
  "type": "array",
4538
4731
  "items": {
4539
- "type": "string"
4732
+ "$ref": "#/definitions/TokenValue"
4540
4733
  },
4541
4734
  "description": "Categorical palette for area-filling marks (bar, area, arc, waffle, calendar, rect). Defaults to `categorical` when only that is set."
4542
4735
  },
@@ -4926,52 +5119,415 @@
4926
5119
  "ChartSpecOverride": {
4927
5120
  "type": "object",
4928
5121
  "properties": {
4929
- "chrome": {
4930
- "$ref": "#/definitions/Chrome",
4931
- "description": "Override editorial chrome at this breakpoint."
4932
- },
4933
- "labels": {
4934
- "$ref": "#/definitions/LabelSpec",
4935
- "description": "Override label configuration at this breakpoint."
4936
- },
4937
- "endpointLabels": {
4938
- "anyOf": [
4939
- {
4940
- "type": "boolean"
4941
- },
4942
- {
4943
- "$ref": "#/definitions/EndpointLabelsConfig"
4944
- }
4945
- ],
4946
- "description": "Override endpoint labels at this breakpoint, including migrated v8 line labels."
4947
- },
4948
- "legend": {
4949
- "$ref": "#/definitions/LegendConfig",
4950
- "description": "Override legend configuration at this breakpoint."
4951
- },
4952
- "annotations": {
4953
- "type": "array",
4954
- "items": {
4955
- "$ref": "#/definitions/Annotation"
4956
- },
4957
- "description": "Override annotations at this breakpoint."
4958
- },
4959
- "animation": {
4960
- "$ref": "#/definitions/AnimationSpec",
4961
- "description": "Override animation at this breakpoint."
4962
- },
4963
- "display": {
4964
- "$ref": "#/definitions/Display",
4965
- "description": "Override display mode (`'full'` or `'sparkline'`) at this breakpoint."
4966
- },
4967
- "watermark": {
4968
- "type": "boolean",
4969
- "description": "Override watermark visibility at this breakpoint."
4970
- },
4971
- "crosshair": {
4972
- "type": "boolean",
4973
- "description": "Override crosshair behavior at this breakpoint."
4974
- }
5122
+ "encoding": {
5123
+ "type": "object",
5124
+ "properties": {
5125
+ "x": {
5126
+ "type": "object",
5127
+ "properties": {
5128
+ "axis": {
5129
+ "anyOf": [
5130
+ {
5131
+ "$ref": "#/definitions/AxisConfig"
5132
+ },
5133
+ {
5134
+ "type": "boolean",
5135
+ "const": false
5136
+ }
5137
+ ]
5138
+ },
5139
+ "scale": {
5140
+ "type": "object",
5141
+ "properties": {
5142
+ "domain": {
5143
+ "anyOf": [
5144
+ {
5145
+ "type": "array",
5146
+ "items": {
5147
+ "type": "number"
5148
+ }
5149
+ },
5150
+ {
5151
+ "type": "array",
5152
+ "items": {
5153
+ "type": "string"
5154
+ }
5155
+ }
5156
+ ],
5157
+ "description": "Explicit domain override. Auto-derived from data if omitted. Continuous scales take `[min, max]`; threshold scales take the full list of class break values; categorical scales take the value list."
5158
+ },
5159
+ "type": {
5160
+ "$ref": "#/definitions/ScaleType",
5161
+ "description": "Scale type override. Usually inferred from field type."
5162
+ },
5163
+ "nice": {
5164
+ "type": "boolean",
5165
+ "description": "Whether to nice-ify the domain for clean tick values. Defaults to true."
5166
+ },
5167
+ "zero": {
5168
+ "type": "boolean",
5169
+ "description": "Whether the domain should include zero. Defaults to true for quantitative."
5170
+ },
5171
+ "clip": {
5172
+ "type": "boolean",
5173
+ "description": "When true and domain is set, filter out data rows with values outside the domain range."
5174
+ },
5175
+ "range": {
5176
+ "type": "array",
5177
+ "items": {},
5178
+ "description": "Explicit range override."
5179
+ },
5180
+ "clamp": {
5181
+ "type": "boolean",
5182
+ "description": "Clamp output to the range."
5183
+ },
5184
+ "padding": {
5185
+ "type": "number",
5186
+ "description": "Padding for band/point scales. Point-scale default (a categorical x/y on a line/area/point mark) is 0 for line and area marks (the trend runs flush to the plot edges) and 0.5 for other marks (e.g. scatter, so points don't collide with the axis). `paddingOuter` is accepted as an alias here since point scales have no inner bands."
5187
+ },
5188
+ "paddingInner": {
5189
+ "type": "number",
5190
+ "description": "Inner padding for band scales."
5191
+ },
5192
+ "paddingOuter": {
5193
+ "type": "number",
5194
+ "description": "Outer padding for band scales."
5195
+ },
5196
+ "exponent": {
5197
+ "type": "number",
5198
+ "description": "Exponent for pow scales."
5199
+ },
5200
+ "base": {
5201
+ "type": "number",
5202
+ "description": "Base for log scales (default 10)."
5203
+ },
5204
+ "constant": {
5205
+ "type": "number",
5206
+ "description": "Constant for symlog scales."
5207
+ }
5208
+ },
5209
+ "additionalProperties": false
5210
+ }
5211
+ },
5212
+ "additionalProperties": false
5213
+ },
5214
+ "y": {
5215
+ "type": "object",
5216
+ "properties": {
5217
+ "axis": {
5218
+ "anyOf": [
5219
+ {
5220
+ "$ref": "#/definitions/AxisConfig"
5221
+ },
5222
+ {
5223
+ "type": "boolean",
5224
+ "const": false
5225
+ }
5226
+ ]
5227
+ },
5228
+ "scale": {
5229
+ "type": "object",
5230
+ "properties": {
5231
+ "domain": {
5232
+ "anyOf": [
5233
+ {
5234
+ "type": "array",
5235
+ "items": {
5236
+ "type": "number"
5237
+ }
5238
+ },
5239
+ {
5240
+ "type": "array",
5241
+ "items": {
5242
+ "type": "string"
5243
+ }
5244
+ }
5245
+ ],
5246
+ "description": "Explicit domain override. Auto-derived from data if omitted. Continuous scales take `[min, max]`; threshold scales take the full list of class break values; categorical scales take the value list."
5247
+ },
5248
+ "type": {
5249
+ "$ref": "#/definitions/ScaleType",
5250
+ "description": "Scale type override. Usually inferred from field type."
5251
+ },
5252
+ "nice": {
5253
+ "type": "boolean",
5254
+ "description": "Whether to nice-ify the domain for clean tick values. Defaults to true."
5255
+ },
5256
+ "zero": {
5257
+ "type": "boolean",
5258
+ "description": "Whether the domain should include zero. Defaults to true for quantitative."
5259
+ },
5260
+ "clip": {
5261
+ "type": "boolean",
5262
+ "description": "When true and domain is set, filter out data rows with values outside the domain range."
5263
+ },
5264
+ "range": {
5265
+ "type": "array",
5266
+ "items": {},
5267
+ "description": "Explicit range override."
5268
+ },
5269
+ "clamp": {
5270
+ "type": "boolean",
5271
+ "description": "Clamp output to the range."
5272
+ },
5273
+ "padding": {
5274
+ "type": "number",
5275
+ "description": "Padding for band/point scales. Point-scale default (a categorical x/y on a line/area/point mark) is 0 for line and area marks (the trend runs flush to the plot edges) and 0.5 for other marks (e.g. scatter, so points don't collide with the axis). `paddingOuter` is accepted as an alias here since point scales have no inner bands."
5276
+ },
5277
+ "paddingInner": {
5278
+ "type": "number",
5279
+ "description": "Inner padding for band scales."
5280
+ },
5281
+ "paddingOuter": {
5282
+ "type": "number",
5283
+ "description": "Outer padding for band scales."
5284
+ },
5285
+ "exponent": {
5286
+ "type": "number",
5287
+ "description": "Exponent for pow scales."
5288
+ },
5289
+ "base": {
5290
+ "type": "number",
5291
+ "description": "Base for log scales (default 10)."
5292
+ },
5293
+ "constant": {
5294
+ "type": "number",
5295
+ "description": "Constant for symlog scales."
5296
+ }
5297
+ },
5298
+ "additionalProperties": false
5299
+ }
5300
+ },
5301
+ "additionalProperties": false
5302
+ },
5303
+ "color": {
5304
+ "type": "object",
5305
+ "properties": {
5306
+ "axis": {
5307
+ "anyOf": [
5308
+ {
5309
+ "$ref": "#/definitions/AxisConfig"
5310
+ },
5311
+ {
5312
+ "type": "boolean",
5313
+ "const": false
5314
+ }
5315
+ ]
5316
+ },
5317
+ "scale": {
5318
+ "type": "object",
5319
+ "properties": {
5320
+ "domain": {
5321
+ "anyOf": [
5322
+ {
5323
+ "type": "array",
5324
+ "items": {
5325
+ "type": "number"
5326
+ }
5327
+ },
5328
+ {
5329
+ "type": "array",
5330
+ "items": {
5331
+ "type": "string"
5332
+ }
5333
+ }
5334
+ ],
5335
+ "description": "Explicit domain override. Auto-derived from data if omitted. Continuous scales take `[min, max]`; threshold scales take the full list of class break values; categorical scales take the value list."
5336
+ },
5337
+ "type": {
5338
+ "$ref": "#/definitions/ScaleType",
5339
+ "description": "Scale type override. Usually inferred from field type."
5340
+ },
5341
+ "nice": {
5342
+ "type": "boolean",
5343
+ "description": "Whether to nice-ify the domain for clean tick values. Defaults to true."
5344
+ },
5345
+ "zero": {
5346
+ "type": "boolean",
5347
+ "description": "Whether the domain should include zero. Defaults to true for quantitative."
5348
+ },
5349
+ "clip": {
5350
+ "type": "boolean",
5351
+ "description": "When true and domain is set, filter out data rows with values outside the domain range."
5352
+ },
5353
+ "range": {
5354
+ "type": "array",
5355
+ "items": {},
5356
+ "description": "Explicit range override."
5357
+ },
5358
+ "clamp": {
5359
+ "type": "boolean",
5360
+ "description": "Clamp output to the range."
5361
+ },
5362
+ "padding": {
5363
+ "type": "number",
5364
+ "description": "Padding for band/point scales. Point-scale default (a categorical x/y on a line/area/point mark) is 0 for line and area marks (the trend runs flush to the plot edges) and 0.5 for other marks (e.g. scatter, so points don't collide with the axis). `paddingOuter` is accepted as an alias here since point scales have no inner bands."
5365
+ },
5366
+ "paddingInner": {
5367
+ "type": "number",
5368
+ "description": "Inner padding for band scales."
5369
+ },
5370
+ "paddingOuter": {
5371
+ "type": "number",
5372
+ "description": "Outer padding for band scales."
5373
+ },
5374
+ "exponent": {
5375
+ "type": "number",
5376
+ "description": "Exponent for pow scales."
5377
+ },
5378
+ "base": {
5379
+ "type": "number",
5380
+ "description": "Base for log scales (default 10)."
5381
+ },
5382
+ "constant": {
5383
+ "type": "number",
5384
+ "description": "Constant for symlog scales."
5385
+ }
5386
+ },
5387
+ "additionalProperties": false
5388
+ }
5389
+ },
5390
+ "additionalProperties": false
5391
+ },
5392
+ "size": {
5393
+ "type": "object",
5394
+ "properties": {
5395
+ "axis": {
5396
+ "anyOf": [
5397
+ {
5398
+ "$ref": "#/definitions/AxisConfig"
5399
+ },
5400
+ {
5401
+ "type": "boolean",
5402
+ "const": false
5403
+ }
5404
+ ]
5405
+ },
5406
+ "scale": {
5407
+ "type": "object",
5408
+ "properties": {
5409
+ "domain": {
5410
+ "anyOf": [
5411
+ {
5412
+ "type": "array",
5413
+ "items": {
5414
+ "type": "number"
5415
+ }
5416
+ },
5417
+ {
5418
+ "type": "array",
5419
+ "items": {
5420
+ "type": "string"
5421
+ }
5422
+ }
5423
+ ],
5424
+ "description": "Explicit domain override. Auto-derived from data if omitted. Continuous scales take `[min, max]`; threshold scales take the full list of class break values; categorical scales take the value list."
5425
+ },
5426
+ "type": {
5427
+ "$ref": "#/definitions/ScaleType",
5428
+ "description": "Scale type override. Usually inferred from field type."
5429
+ },
5430
+ "nice": {
5431
+ "type": "boolean",
5432
+ "description": "Whether to nice-ify the domain for clean tick values. Defaults to true."
5433
+ },
5434
+ "zero": {
5435
+ "type": "boolean",
5436
+ "description": "Whether the domain should include zero. Defaults to true for quantitative."
5437
+ },
5438
+ "clip": {
5439
+ "type": "boolean",
5440
+ "description": "When true and domain is set, filter out data rows with values outside the domain range."
5441
+ },
5442
+ "range": {
5443
+ "type": "array",
5444
+ "items": {},
5445
+ "description": "Explicit range override."
5446
+ },
5447
+ "clamp": {
5448
+ "type": "boolean",
5449
+ "description": "Clamp output to the range."
5450
+ },
5451
+ "padding": {
5452
+ "type": "number",
5453
+ "description": "Padding for band/point scales. Point-scale default (a categorical x/y on a line/area/point mark) is 0 for line and area marks (the trend runs flush to the plot edges) and 0.5 for other marks (e.g. scatter, so points don't collide with the axis). `paddingOuter` is accepted as an alias here since point scales have no inner bands."
5454
+ },
5455
+ "paddingInner": {
5456
+ "type": "number",
5457
+ "description": "Inner padding for band scales."
5458
+ },
5459
+ "paddingOuter": {
5460
+ "type": "number",
5461
+ "description": "Outer padding for band scales."
5462
+ },
5463
+ "exponent": {
5464
+ "type": "number",
5465
+ "description": "Exponent for pow scales."
5466
+ },
5467
+ "base": {
5468
+ "type": "number",
5469
+ "description": "Base for log scales (default 10)."
5470
+ },
5471
+ "constant": {
5472
+ "type": "number",
5473
+ "description": "Constant for symlog scales."
5474
+ }
5475
+ },
5476
+ "additionalProperties": false
5477
+ }
5478
+ },
5479
+ "additionalProperties": false
5480
+ }
5481
+ },
5482
+ "additionalProperties": false,
5483
+ "description": "Patch axis and scale settings on existing scale-bearing channels; nested properties merge with the base."
5484
+ },
5485
+ "chrome": {
5486
+ "$ref": "#/definitions/Chrome",
5487
+ "description": "Override editorial chrome at this breakpoint."
5488
+ },
5489
+ "labels": {
5490
+ "$ref": "#/definitions/LabelSpec",
5491
+ "description": "Override label configuration at this breakpoint."
5492
+ },
5493
+ "endpointLabels": {
5494
+ "anyOf": [
5495
+ {
5496
+ "type": "boolean"
5497
+ },
5498
+ {
5499
+ "$ref": "#/definitions/EndpointLabelsConfig"
5500
+ }
5501
+ ],
5502
+ "description": "Override endpoint labels at this breakpoint, including migrated v8 line labels."
5503
+ },
5504
+ "legend": {
5505
+ "$ref": "#/definitions/LegendConfig",
5506
+ "description": "Override legend configuration at this breakpoint."
5507
+ },
5508
+ "annotations": {
5509
+ "type": "array",
5510
+ "items": {
5511
+ "$ref": "#/definitions/Annotation"
5512
+ },
5513
+ "description": "Override annotations at this breakpoint."
5514
+ },
5515
+ "animation": {
5516
+ "$ref": "#/definitions/AnimationSpec",
5517
+ "description": "Override animation at this breakpoint."
5518
+ },
5519
+ "display": {
5520
+ "$ref": "#/definitions/Display",
5521
+ "description": "Override display mode (`'full'` or `'sparkline'`) at this breakpoint."
5522
+ },
5523
+ "watermark": {
5524
+ "type": "boolean",
5525
+ "description": "Override watermark visibility at this breakpoint."
5526
+ },
5527
+ "crosshair": {
5528
+ "type": "boolean",
5529
+ "description": "Override crosshair behavior at this breakpoint."
5530
+ }
4975
5531
  },
4976
5532
  "additionalProperties": false,
4977
5533
  "description": "Breakpoint-conditional overrides for chart specs.\n\nAllows specifying different chrome, labels, legend, or annotations per breakpoint. Merged shallowly into the base spec at compile time when the container matches the breakpoint."
@@ -5282,9 +5838,133 @@
5282
5838
  ],
5283
5839
  "description": "Resolution strategy for shared resources across layers. 'shared' (default): union domains, single axis/legend. 'independent': each layer gets its own scale/axis/legend."
5284
5840
  },
5841
+ "ArcEncoding<DataRow>": {
5842
+ "type": "object",
5843
+ "properties": {
5844
+ "description": {
5845
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
5846
+ "description": "Accessible mark description; static output exposes it as a native title."
5847
+ },
5848
+ "x": {
5849
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5850
+ "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."
5851
+ },
5852
+ "y": {
5853
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5854
+ "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."
5855
+ },
5856
+ "color": {
5857
+ "anyOf": [
5858
+ {
5859
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
5860
+ },
5861
+ {
5862
+ "$ref": "#/definitions/ConditionalValueDef%3CDataRow%3E"
5863
+ }
5864
+ ],
5865
+ "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)."
5866
+ },
5867
+ "size": {
5868
+ "anyOf": [
5869
+ {
5870
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
5871
+ },
5872
+ {
5873
+ "$ref": "#/definitions/ConditionalValueDef%3CDataRow%3E"
5874
+ },
5875
+ {
5876
+ "$ref": "#/definitions/ValueDef"
5877
+ }
5878
+ ],
5879
+ "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."
5880
+ },
5881
+ "detail": {
5882
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5883
+ "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."
5884
+ },
5885
+ "key": {
5886
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5887
+ "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."
5888
+ },
5889
+ "x2": {
5890
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5891
+ "description": "Secondary x position. Used with `x` to define a horizontal span (rect marks, error bars). Both `x` and `x2` must be quantitative."
5892
+ },
5893
+ "y2": {
5894
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5895
+ "description": "Secondary y position. Used with `y` to define a vertical span (rect marks, error bands). Both `y` and `y2` must be quantitative."
5896
+ },
5897
+ "opacity": {
5898
+ "anyOf": [
5899
+ {
5900
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
5901
+ },
5902
+ {
5903
+ "$ref": "#/definitions/ConditionalValueDef%3CDataRow%3E"
5904
+ },
5905
+ {
5906
+ "$ref": "#/definitions/ValueDef"
5907
+ }
5908
+ ],
5909
+ "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`)."
5910
+ },
5911
+ "strokeDash": {
5912
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5913
+ "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."
5914
+ },
5915
+ "angle": {
5916
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5917
+ "description": "Rotation angle encoding for point marks. Maps a quantitative field to 0-360 degrees."
5918
+ },
5919
+ "text": {
5920
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5921
+ "description": "Text content for `text` marks. Required when mark is `'text'`. Not meaningful for other mark types."
5922
+ },
5923
+ "tooltip": {
5924
+ "anyOf": [
5925
+ {
5926
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
5927
+ },
5928
+ {
5929
+ "type": "array",
5930
+ "items": {
5931
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E"
5932
+ }
5933
+ }
5934
+ ],
5935
+ "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."
5936
+ },
5937
+ "theta": {
5938
+ "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5939
+ "description": "Canonical value channel for arc marks (quantitative — the slice value)."
5940
+ },
5941
+ "facet": {
5942
+ "$ref": "#/definitions/FacetChannel%3CDataRow%3E",
5943
+ "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."
5944
+ },
5945
+ "row": {
5946
+ "$ref": "#/definitions/FacetChannel%3CDataRow%3E",
5947
+ "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`."
5948
+ },
5949
+ "column": {
5950
+ "$ref": "#/definitions/FacetChannel%3CDataRow%3E",
5951
+ "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`."
5952
+ }
5953
+ },
5954
+ "required": [
5955
+ "theta",
5956
+ "color"
5957
+ ],
5958
+ "additionalProperties": false,
5959
+ "description": "Encoding for arc marks (pie/donut charts).\n- `theta`: required (quantitative — the canonical slice value channel)\n- `color`: required (nominal/ordinal — the category)"
5960
+ },
5285
5961
  "LineEncoding<DataRow>": {
5286
5962
  "type": "object",
5287
5963
  "properties": {
5964
+ "description": {
5965
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
5966
+ "description": "Accessible mark description; static output exposes it as a native title."
5967
+ },
5288
5968
  "x": {
5289
5969
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5290
5970
  "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."
@@ -5404,6 +6084,10 @@
5404
6084
  "BarEncoding<DataRow>": {
5405
6085
  "type": "object",
5406
6086
  "properties": {
6087
+ "description": {
6088
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
6089
+ "description": "Accessible mark description; static output exposes it as a native title."
6090
+ },
5407
6091
  "x": {
5408
6092
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5409
6093
  "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."
@@ -5523,6 +6207,10 @@
5523
6207
  "AreaEncoding<DataRow>": {
5524
6208
  "type": "object",
5525
6209
  "properties": {
6210
+ "description": {
6211
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
6212
+ "description": "Accessible mark description; static output exposes it as a native title."
6213
+ },
5526
6214
  "x": {
5527
6215
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5528
6216
  "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."
@@ -5665,6 +6353,10 @@
5665
6353
  "PointEncoding<DataRow>": {
5666
6354
  "type": "object",
5667
6355
  "properties": {
6356
+ "description": {
6357
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
6358
+ "description": "Accessible mark description; static output exposes it as a native title."
6359
+ },
5668
6360
  "x": {
5669
6361
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5670
6362
  "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."
@@ -5784,6 +6476,10 @@
5784
6476
  "CircleEncoding<DataRow>": {
5785
6477
  "type": "object",
5786
6478
  "properties": {
6479
+ "description": {
6480
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
6481
+ "description": "Accessible mark description; static output exposes it as a native title."
6482
+ },
5787
6483
  "x": {
5788
6484
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5789
6485
  "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."
@@ -5903,6 +6599,10 @@
5903
6599
  "LollipopEncoding<DataRow>": {
5904
6600
  "type": "object",
5905
6601
  "properties": {
6602
+ "description": {
6603
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
6604
+ "description": "Accessible mark description; static output exposes it as a native title."
6605
+ },
5906
6606
  "x": {
5907
6607
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
5908
6608
  "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."
@@ -6022,6 +6722,10 @@
6022
6722
  "BeeswarmEncoding<DataRow>": {
6023
6723
  "type": "object",
6024
6724
  "properties": {
6725
+ "description": {
6726
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
6727
+ "description": "Accessible mark description; static output exposes it as a native title."
6728
+ },
6025
6729
  "x": {
6026
6730
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
6027
6731
  "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."
@@ -6137,6 +6841,10 @@
6137
6841
  "RangeEncoding<DataRow>": {
6138
6842
  "type": "object",
6139
6843
  "properties": {
6844
+ "description": {
6845
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
6846
+ "description": "Accessible mark description; static output exposes it as a native title."
6847
+ },
6140
6848
  "x": {
6141
6849
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
6142
6850
  "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."
@@ -6250,12 +6958,15 @@
6250
6958
  "x",
6251
6959
  "y"
6252
6960
  ],
6253
- "additionalProperties": false,
6254
- "description": "Encoding for range marks (dumbbell / arrow / range-bar plots).\n- Horizontal (the common editorial form): `y` nominal/ordinal category, `x` quantitative start, `x2` quantitative end.\n- Vertical: `x` nominal/ordinal category, `y` quantitative start, `y2` quantitative end."
6961
+ "additionalProperties": false
6255
6962
  },
6256
6963
  "WaffleEncoding<DataRow>": {
6257
6964
  "type": "object",
6258
6965
  "properties": {
6966
+ "description": {
6967
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
6968
+ "description": "Accessible mark description; static output exposes it as a native title."
6969
+ },
6259
6970
  "x": {
6260
6971
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
6261
6972
  "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."
@@ -6371,6 +7082,10 @@
6371
7082
  "TextEncoding<DataRow>": {
6372
7083
  "type": "object",
6373
7084
  "properties": {
7085
+ "description": {
7086
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
7087
+ "description": "Accessible mark description; static output exposes it as a native title."
7088
+ },
6374
7089
  "x": {
6375
7090
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
6376
7091
  "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."
@@ -6489,6 +7204,10 @@
6489
7204
  "TickEncoding<DataRow>": {
6490
7205
  "type": "object",
6491
7206
  "properties": {
7207
+ "description": {
7208
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
7209
+ "description": "Accessible mark description; static output exposes it as a native title."
7210
+ },
6492
7211
  "x": {
6493
7212
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
6494
7213
  "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."
@@ -6608,6 +7327,10 @@
6608
7327
  "RectEncoding<DataRow>": {
6609
7328
  "type": "object",
6610
7329
  "properties": {
7330
+ "description": {
7331
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
7332
+ "description": "Accessible mark description; static output exposes it as a native title."
7333
+ },
6611
7334
  "x": {
6612
7335
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
6613
7336
  "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."
@@ -6727,6 +7450,10 @@
6727
7450
  "Encoding<DataRow>": {
6728
7451
  "type": "object",
6729
7452
  "properties": {
7453
+ "description": {
7454
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
7455
+ "description": "Accessible mark description; static output exposes it as a native title."
7456
+ },
6730
7457
  "x": {
6731
7458
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
6732
7459
  "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."
@@ -6836,12 +7563,15 @@
6836
7563
  "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`."
6837
7564
  }
6838
7565
  },
6839
- "additionalProperties": false,
6840
- "description": "Encoding object mapping visual channels to data fields. Which channels are required depends on the mark type — see the per-mark encoding interfaces (ArcEncoding, LineEncoding, etc.) and MARK_ENCODING_RULES in encoding.ts for the full requirements table."
7566
+ "additionalProperties": false
6841
7567
  },
6842
7568
  "CalendarEncoding<DataRow>": {
6843
7569
  "type": "object",
6844
7570
  "properties": {
7571
+ "description": {
7572
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
7573
+ "description": "Accessible mark description; static output exposes it as a native title."
7574
+ },
6845
7575
  "x": {
6846
7576
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
6847
7577
  "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."
@@ -6951,6 +7681,10 @@
6951
7681
  "ParliamentEncoding<DataRow>": {
6952
7682
  "type": "object",
6953
7683
  "properties": {
7684
+ "description": {
7685
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
7686
+ "description": "Accessible mark description; static output exposes it as a native title."
7687
+ },
6954
7688
  "x": {
6955
7689
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
6956
7690
  "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."
@@ -7066,6 +7800,10 @@
7066
7800
  "HistogramEncoding<DataRow>": {
7067
7801
  "type": "object",
7068
7802
  "properties": {
7803
+ "description": {
7804
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
7805
+ "description": "Accessible mark description; static output exposes it as a native title."
7806
+ },
7069
7807
  "x": {
7070
7808
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
7071
7809
  "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."
@@ -7184,6 +7922,10 @@
7184
7922
  "DensityEncoding<DataRow>": {
7185
7923
  "type": "object",
7186
7924
  "properties": {
7925
+ "description": {
7926
+ "$ref": "#/definitions/DescriptionEncoding%3CDataRow%3E",
7927
+ "description": "Accessible mark description; static output exposes it as a native title."
7928
+ },
7187
7929
  "x": {
7188
7930
  "$ref": "#/definitions/EncodingChannel%3CDataRow%3E",
7189
7931
  "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."
@@ -7302,6 +8044,18 @@
7302
8044
  "LayerSpec": {
7303
8045
  "type": "object",
7304
8046
  "properties": {
8047
+ "display": {
8048
+ "$ref": "#/definitions/Display",
8049
+ "description": "Display defaults shared by every leaf."
8050
+ },
8051
+ "a11y": {
8052
+ "$ref": "#/definitions/A11yConfig",
8053
+ "description": "Figure accessibility; hidden cells omit the image role."
8054
+ },
8055
+ "frame": {
8056
+ "$ref": "#/definitions/FrameConfig",
8057
+ "description": "Fixed horizontal plot gutters shared by the figure."
8058
+ },
7305
8059
  "layer": {
7306
8060
  "type": "array",
7307
8061
  "items": {
@@ -7356,96 +8110,390 @@
7356
8110
  "required": [
7357
8111
  "text"
7358
8112
  ],
7359
- "additionalProperties": false
7360
- }
7361
- ],
7362
- "description": "Top-level title sugar (VL aligned). Expanded into `chrome.title`; `chrome.title` wins."
7363
- },
7364
- "subtitle": {
7365
- "type": "string",
7366
- "description": "Top-level subtitle sugar. Expanded into `chrome.subtitle`; `chrome.subtitle` wins."
7367
- },
7368
- "width": {
7369
- "type": "number",
7370
- "description": "Fixed render width in pixels (VL aligned). Overrides the container-derived width."
7371
- },
7372
- "height": {
7373
- "type": "number",
7374
- "description": "Fixed render height in pixels (VL aligned). Overrides the container-derived height."
7375
- },
7376
- "$schema": {
7377
- "type": "string",
7378
- "description": "Accepted for Vega-Lite compatibility and ignored (with a compile warning)."
7379
- },
7380
- "annotations": {
7381
- "type": "array",
7382
- "items": {
7383
- "$ref": "#/definitions/Annotation"
7384
- },
7385
- "description": "Annotations for the layered chart. When present, these are the annotations rendered and available for editing. When absent, falls back to the first leaf layer's annotations. Annotations on second and later leaf layers are not rendered.\n\nFor edit persistence: the `data-annotation-index` stamped on each rendered annotation maps to this array (or the first leaf's if this is unset). Place annotations here for reliable index-based edit matching."
7386
- },
7387
- "labels": {
7388
- "$ref": "#/definitions/LabelSpec",
7389
- "description": "Label display configuration. `false` disables all labels, `true` uses defaults."
7390
- },
7391
- "legend": {
7392
- "$ref": "#/definitions/LegendConfig",
7393
- "description": "Legend display configuration."
7394
- },
7395
- "responsive": {
7396
- "anyOf": [
7397
- {
7398
- "type": "boolean"
8113
+ "additionalProperties": false
8114
+ }
8115
+ ],
8116
+ "description": "Top-level title sugar (VL aligned). Expanded into `chrome.title`; `chrome.title` wins."
8117
+ },
8118
+ "subtitle": {
8119
+ "type": "string",
8120
+ "description": "Top-level subtitle sugar. Expanded into `chrome.subtitle`; `chrome.subtitle` wins."
8121
+ },
8122
+ "width": {
8123
+ "type": "number",
8124
+ "description": "Fixed render width in pixels (VL aligned). Overrides the container-derived width."
8125
+ },
8126
+ "height": {
8127
+ "type": "number",
8128
+ "description": "Fixed render height in pixels (VL aligned). Overrides the container-derived height."
8129
+ },
8130
+ "$schema": {
8131
+ "type": "string",
8132
+ "description": "Accepted for Vega-Lite compatibility and ignored (with a compile warning)."
8133
+ },
8134
+ "annotations": {
8135
+ "type": "array",
8136
+ "items": {
8137
+ "$ref": "#/definitions/Annotation"
8138
+ },
8139
+ "description": "Annotations for the layered chart. When present, these are the annotations rendered and available for editing. When absent, falls back to the first leaf layer's annotations. Annotations on second and later leaf layers are not rendered.\n\nFor edit persistence: the `data-annotation-index` stamped on each rendered annotation maps to this array (or the first leaf's if this is unset). Place annotations here for reliable index-based edit matching."
8140
+ },
8141
+ "labels": {
8142
+ "$ref": "#/definitions/LabelSpec",
8143
+ "description": "Label display configuration. `false` disables all labels, `true` uses defaults."
8144
+ },
8145
+ "legend": {
8146
+ "$ref": "#/definitions/LegendConfig",
8147
+ "description": "Legend display configuration."
8148
+ },
8149
+ "responsive": {
8150
+ "anyOf": [
8151
+ {
8152
+ "type": "boolean"
8153
+ },
8154
+ {
8155
+ "$ref": "#/definitions/ResponsiveConfig"
8156
+ }
8157
+ ],
8158
+ "description": "Responsive behavior for the composed chart, with the same meaning as `ChartSpec.responsive`: `true`/`false` enables/disables container-width adaptation, and a `ResponsiveConfig` object gives fine-grained control (e.g. `{ compactAnnotationLimit: null }`). When omitted, the first leaf layer's `responsive` applies."
8159
+ },
8160
+ "theme": {
8161
+ "$ref": "#/definitions/ThemeConfig",
8162
+ "description": "Theme configuration overrides."
8163
+ },
8164
+ "watermark": {
8165
+ "type": "boolean",
8166
+ "description": "Whether to show the OpenData watermark. Defaults to true."
8167
+ },
8168
+ "resolve": {
8169
+ "$ref": "#/definitions/ResolveConfig",
8170
+ "description": "Resolution strategy for shared scales/axes/legends."
8171
+ },
8172
+ "hiddenSeries": {
8173
+ "type": "array",
8174
+ "items": {
8175
+ "type": "string"
8176
+ },
8177
+ "description": "Series names to hide from rendering by default. This is the authored persistence target for legend visibility. Runtime legend toggles (legend-toggle edit events) layer on top of this via ephemeral runtime sets but never modify it."
8178
+ },
8179
+ "endpointLabels": {
8180
+ "anyOf": [
8181
+ {
8182
+ "type": "boolean"
8183
+ },
8184
+ {
8185
+ "$ref": "#/definitions/EndpointLabelsConfig"
8186
+ }
8187
+ ],
8188
+ "description": "Endpoint labels column, inherited by child layers that don't set their own."
8189
+ },
8190
+ "animation": {
8191
+ "$ref": "#/definitions/AnimationSpec",
8192
+ "description": "Animation configuration."
8193
+ }
8194
+ },
8195
+ "required": [
8196
+ "layer"
8197
+ ],
8198
+ "additionalProperties": false,
8199
+ "description": "Layer specification: composites multiple chart layers into a single view.\n\nEach element in `layer` is either a ChartSpec or another LayerSpec (nested). Shared data, encoding, and transforms at the LayerSpec level are inherited by children that don't define their own."
8200
+ },
8201
+ "ChartSpec<DataRow>": {
8202
+ "anyOf": [
8203
+ {
8204
+ "type": "object",
8205
+ "additionalProperties": false,
8206
+ "properties": {
8207
+ "mark": {
8208
+ "anyOf": [
8209
+ {
8210
+ "type": "string",
8211
+ "const": "errorbar"
8212
+ },
8213
+ {
8214
+ "type": "object",
8215
+ "additionalProperties": false,
8216
+ "properties": {
8217
+ "ticks": {
8218
+ "type": "boolean",
8219
+ "description": "Draw decorative end caps on an explicit interval; default false."
8220
+ },
8221
+ "type": {
8222
+ "type": "string",
8223
+ "const": "errorbar"
8224
+ },
8225
+ "size": {
8226
+ "type": "number",
8227
+ "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."
8228
+ },
8229
+ "filled": {
8230
+ "type": "boolean",
8231
+ "description": "Whether the mark is filled (vs stroked only)."
8232
+ },
8233
+ "opacity": {
8234
+ "type": "number",
8235
+ "description": "Default opacity (0-1)."
8236
+ },
8237
+ "fillOpacity": {
8238
+ "type": "number",
8239
+ "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."
8240
+ },
8241
+ "fill": {
8242
+ "anyOf": [
8243
+ {
8244
+ "type": "string"
8245
+ },
8246
+ {
8247
+ "$ref": "#/definitions/GradientDef"
8248
+ }
8249
+ ],
8250
+ "description": "Default fill color or gradient."
8251
+ },
8252
+ "stroke": {
8253
+ "type": "string",
8254
+ "description": "Default stroke color."
8255
+ },
8256
+ "strokeWidth": {
8257
+ "type": "number",
8258
+ "description": "Default stroke width."
8259
+ },
8260
+ "tooltip": {
8261
+ "type": [
8262
+ "boolean",
8263
+ "null"
8264
+ ],
8265
+ "description": "Tooltip behavior. null disables tooltips."
8266
+ },
8267
+ "clip": {
8268
+ "type": "boolean",
8269
+ "description": "Clip marks to the chart area."
8270
+ },
8271
+ "fillPattern": {
8272
+ "type": "string",
8273
+ "enum": [
8274
+ "auto",
8275
+ "none"
8276
+ ],
8277
+ "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."
8278
+ }
8279
+ },
8280
+ "required": [
8281
+ "type"
8282
+ ]
8283
+ }
8284
+ ]
8285
+ },
8286
+ "encoding": {
8287
+ "$ref": "#/definitions/ErrorbarEncoding%3CDataRow%3E"
8288
+ },
8289
+ "frame": {
8290
+ "$ref": "#/definitions/FrameConfig",
8291
+ "description": "Fixed horizontal plot gutters."
8292
+ },
8293
+ "fields": {
8294
+ "type": "object",
8295
+ "additionalProperties": {
8296
+ "$ref": "#/definitions/FieldMetadata"
8297
+ },
8298
+ "description": "Optional authored measure, unit, provenance, and supplied interval metadata."
8299
+ },
8300
+ "data": {
8301
+ "type": "array",
8302
+ "items": {
8303
+ "$ref": "#/definitions/DataRow"
8304
+ },
8305
+ "description": "Data array: each element is a row with field values. The Vega-Lite object form `{ values: [...] }` is also accepted at runtime and unwrapped during the pre-validation sugar expansion. `{ url }` is not supported (openchart does not fetch data)."
8306
+ },
8307
+ "transform": {
8308
+ "type": "array",
8309
+ "items": {
8310
+ "$ref": "#/definitions/Transform"
8311
+ },
8312
+ "description": "Data transforms applied in order before encoding (filter, bin, calculate, timeUnit)."
8313
+ },
8314
+ "chrome": {
8315
+ "$ref": "#/definitions/Chrome",
8316
+ "description": "Editorial chrome (title, subtitle, source, etc.)."
8317
+ },
8318
+ "chromeLayout": {
8319
+ "type": "string",
8320
+ "enum": [
8321
+ "subtract",
8322
+ "grow"
8323
+ ],
8324
+ "description": "How chrome height interacts with the container height budget.\n\n- omitted: only notes and the series summary grow the figure; title, subtitle, and source subtract from the height budget.\n- `'subtract'`: the container height is fixed and chrome text (title/subtitle/source) is subtracted from it, shrinking the plot. This is the historical behavior.\n- `'grow'`: the container height is treated as the *plot* budget, and the rendered SVG grows taller by the measured chrome height. The plot keeps its full budget (minus axis/padding overhead) regardless of how many lines the title wraps to.\n\nFacets and layers report engine-owned growth once."
8325
+ },
8326
+ "title": {
8327
+ "anyOf": [
8328
+ {
8329
+ "type": "string"
8330
+ },
8331
+ {
8332
+ "type": "object",
8333
+ "properties": {
8334
+ "text": {
8335
+ "type": "string"
8336
+ },
8337
+ "subtitle": {
8338
+ "type": "string"
8339
+ }
8340
+ },
8341
+ "required": [
8342
+ "text"
8343
+ ],
8344
+ "additionalProperties": false
8345
+ }
8346
+ ],
8347
+ "description": "Top-level title sugar (Vega-Lite aligned). Expanded into `chrome.title` (and `chrome.subtitle` for the object form). `chrome.title` wins when both are set."
8348
+ },
8349
+ "subtitle": {
8350
+ "type": "string",
8351
+ "description": "Top-level subtitle sugar. Expanded into `chrome.subtitle`; `chrome.subtitle` wins."
8352
+ },
8353
+ "description": {
8354
+ "type": "string",
8355
+ "description": "Alt text for the rendered chart (Vega-Lite aligned). Sugar for `a11y.description`; `a11y.description` wins when both are set. When absent, alt text is auto-generated from the spec and data."
8356
+ },
8357
+ "a11y": {
8358
+ "$ref": "#/definitions/A11yConfig",
8359
+ "description": "Accessibility overrides. See {@link A11yConfig } ."
8360
+ },
8361
+ "width": {
8362
+ "type": "number",
8363
+ "description": "Fixed render width in pixels (Vega-Lite aligned). Overrides the container-derived width. When both `width` and `height` are set, `responsive: false` is implied unless `responsive` is set explicitly. Omit for the default container-driven sizing."
8364
+ },
8365
+ "height": {
8366
+ "type": "number",
8367
+ "description": "Fixed render height in pixels (Vega-Lite aligned). See `width`."
8368
+ },
8369
+ "$schema": {
8370
+ "type": "string",
8371
+ "description": "Accepted for Vega-Lite compatibility and ignored (with a compile warning)."
8372
+ },
8373
+ "metrics": {
8374
+ "type": "array",
8375
+ "items": {
8376
+ "$ref": "#/definitions/Metric"
8377
+ },
8378
+ "description": "KPI/metric cells rendered as a horizontal row between subtitle and chart area. Each cell shows a label/value pair with optional delta and secondary value. Hidden in sparkline mode and auto-stripped when the container is too narrow or short, or when value text would overflow its cell."
8379
+ },
8380
+ "annotations": {
8381
+ "type": "array",
8382
+ "items": {
8383
+ "$ref": "#/definitions/Annotation"
8384
+ },
8385
+ "description": "Data annotations (text callouts, highlighted ranges, reference lines)."
8386
+ },
8387
+ "labels": {
8388
+ "$ref": "#/definitions/LabelSpec",
8389
+ "description": "Label display configuration. `false` disables all labels, `true` uses defaults."
8390
+ },
8391
+ "legend": {
8392
+ "$ref": "#/definitions/LegendConfig",
8393
+ "description": "Legend display configuration (position override)."
8394
+ },
8395
+ "endpointLabels": {
8396
+ "anyOf": [
8397
+ {
8398
+ "type": "boolean"
8399
+ },
8400
+ {
8401
+ "$ref": "#/definitions/EndpointLabelsConfig"
8402
+ }
8403
+ ],
8404
+ "description": "Right-side endpoint labels column for multi-series line/area charts.\n\n- `true` or `EndpointLabelsConfig`: render the column.\n- `false`: hide the column.\n- omitted: auto-enable for multi-series line/area charts, hide otherwise.\n\nSee {@link EndpointLabelsConfig } for the full suppression truth table that relates this flag to `legend.show`."
8405
+ },
8406
+ "responsive": {
8407
+ "anyOf": [
8408
+ {
8409
+ "type": "boolean"
8410
+ },
8411
+ {
8412
+ "$ref": "#/definitions/ResponsiveConfig"
8413
+ }
8414
+ ],
8415
+ "description": "Responsive behavior. `true`/`false` enables/disables container-width adaptation. Pass a `ResponsiveConfig` object for fine-grained control (e.g. `{ autoThin: false }` to disable automatic annotation thinning)."
8416
+ },
8417
+ "theme": {
8418
+ "$ref": "#/definitions/ThemeConfig",
8419
+ "description": "Theme configuration overrides."
8420
+ },
8421
+ "watermark": {
8422
+ "type": "boolean",
8423
+ "description": "Whether to show the OpenData watermark. Defaults to true; auto-hides when the container is under 200px tall (the cramped height class) unless explicitly set."
8424
+ },
8425
+ "hiddenSeries": {
8426
+ "type": "array",
8427
+ "items": {
8428
+ "type": "string"
8429
+ },
8430
+ "description": "Series names to hide from rendering by default. This is the authored persistence target for legend visibility. Runtime legend toggles (legend-toggle edit events) layer on top of this via ephemeral runtime sets but never modify it."
8431
+ },
8432
+ "seriesStyles": {
8433
+ "type": "object",
8434
+ "additionalProperties": {
8435
+ "$ref": "#/definitions/SeriesStyle"
8436
+ },
8437
+ "description": "Per-series visual overrides, keyed by series name (the color field value)."
8438
+ },
8439
+ "overrides": {
8440
+ "type": "object",
8441
+ "properties": {
8442
+ "compact": {
8443
+ "$ref": "#/definitions/ChartSpecOverride"
8444
+ },
8445
+ "medium": {
8446
+ "$ref": "#/definitions/ChartSpecOverride"
8447
+ },
8448
+ "full": {
8449
+ "$ref": "#/definitions/ChartSpecOverride"
8450
+ }
8451
+ },
8452
+ "additionalProperties": false,
8453
+ "description": "Breakpoint-conditional overrides. Keys are breakpoint names. At compile time, if the container matches a breakpoint, its overrides are shallow-merged into the spec before layout computation."
8454
+ },
8455
+ "animation": {
8456
+ "$ref": "#/definitions/AnimationSpec",
8457
+ "description": "Animation configuration.\n- true: enable entrance animation with sensible defaults\n- false/omitted: no animation (current behavior)\n- AnimationConfig: full control via enter/update/exit phases"
8458
+ },
8459
+ "crosshair": {
8460
+ "type": "boolean",
8461
+ "description": "Show a vertical crosshair line that tracks the nearest data point on line and area charts. Only active when a voronoi overlay is present. Defaults to false. In sparkline display mode, defaults to false unless explicitly set."
8462
+ },
8463
+ "seriesSearch": {
8464
+ "anyOf": [
8465
+ {
8466
+ "type": "boolean"
8467
+ },
8468
+ {
8469
+ "$ref": "#/definitions/SeriesSearchConfig"
8470
+ }
8471
+ ],
8472
+ "description": "Searchable series highlight (\"find your country\"). Renders a compact search input above the chart with typeahead over the color channel's distinct values. Selecting a value adds it to the highlight set (multi-select chips, removable); clearing restores the authored `encoding.color.highlight` baseline. Requires a categorical color encoding. Mutually exclusive with edit mode (search wins)."
7399
8473
  },
7400
- {
7401
- "$ref": "#/definitions/ResponsiveConfig"
7402
- }
7403
- ],
7404
- "description": "Responsive behavior for the composed chart, with the same meaning as `ChartSpec.responsive`: `true`/`false` enables/disables container-width adaptation, and a `ResponsiveConfig` object gives fine-grained control (e.g. `{ compactAnnotationLimit: null }`). When omitted, the first leaf layer's `responsive` applies."
7405
- },
7406
- "theme": {
7407
- "$ref": "#/definitions/ThemeConfig",
7408
- "description": "Theme configuration overrides."
7409
- },
7410
- "watermark": {
7411
- "type": "boolean",
7412
- "description": "Whether to show the OpenData watermark. Defaults to true."
7413
- },
7414
- "resolve": {
7415
- "$ref": "#/definitions/ResolveConfig",
7416
- "description": "Resolution strategy for shared scales/axes/legends."
7417
- },
7418
- "hiddenSeries": {
7419
- "type": "array",
7420
- "items": {
7421
- "type": "string"
7422
- },
7423
- "description": "Series names to hide from rendering by default. This is the authored persistence target for legend visibility. Runtime legend toggles (legend-toggle edit events) layer on top of this via ephemeral runtime sets but never modify it."
7424
- },
7425
- "endpointLabels": {
7426
- "anyOf": [
7427
- {
7428
- "type": "boolean"
8474
+ "youDrawIt": {
8475
+ "$ref": "#/definitions/YouDrawItConfig",
8476
+ "description": "\"You draw it\" interactive engagement format: the reader draws their guess of the trend before the real line reveals. Line marks only, single-series only. Mutually exclusive with edit mode (validation warning if both are enabled; youDrawIt is disabled)."
7429
8477
  },
7430
- {
7431
- "$ref": "#/definitions/EndpointLabelsConfig"
8478
+ "display": {
8479
+ "$ref": "#/definitions/Display",
8480
+ "description": "Display mode controlling how much chart chrome is rendered.\n\n- `'full'` (default): full publication chart with chrome, axes, legend, padding.\n- `'sparkline'`: inline mini-chart for dashboards/KPI cards. Strips chrome, axes, legend, watermark, animation, and crosshair. The mark fills the container edge-to-edge with a small safety margin. Best with `mark: 'line' | 'area' | 'bar' | 'point'`.\n\n**Override precedence:** explicit user fields always win, even in sparkline mode. Setting `chrome.title` on a sparkline still renders the title. Setting `legend: { show: true }` still renders the legend. This applies at top-level and per-breakpoint overrides."
8481
+ },
8482
+ "resolve": {
8483
+ "$ref": "#/definitions/ResolveConfig",
8484
+ "description": "Resolution strategy for shared/independent scales and axes across facet panels. Only meaningful when `encoding.facet` is present. Shared scales (the default) let readers compare across panels; independent scales give each panel its own domain."
8485
+ },
8486
+ "zIndex": {
8487
+ "type": "number",
8488
+ "description": "Render order within a LayerSpec. Higher values render on top. When omitted, layers render in array order (later layers paint on top). Axis assignment (left/right y) is always determined by array position, not zIndex."
7432
8489
  }
7433
- ],
7434
- "description": "Endpoint labels column, inherited by child layers that don't set their own."
8490
+ },
8491
+ "required": [
8492
+ "data",
8493
+ "encoding",
8494
+ "mark"
8495
+ ]
7435
8496
  },
7436
- "animation": {
7437
- "$ref": "#/definitions/AnimationSpec",
7438
- "description": "Animation configuration."
7439
- }
7440
- },
7441
- "required": [
7442
- "layer"
7443
- ],
7444
- "additionalProperties": false,
7445
- "description": "Layer specification: composites multiple chart layers into a single view.\n\nEach element in `layer` is either a ChartSpec or another LayerSpec (nested). Shared data, encoding, and transforms at the LayerSpec level are inherited by children that don't define their own."
7446
- },
7447
- "ChartSpec<DataRow>": {
7448
- "anyOf": [
7449
8497
  {
7450
8498
  "type": "object",
7451
8499
  "additionalProperties": false,
@@ -7567,6 +8615,10 @@
7567
8615
  "encoding": {
7568
8616
  "$ref": "#/definitions/ArcEncoding%3CDataRow%3E"
7569
8617
  },
8618
+ "frame": {
8619
+ "$ref": "#/definitions/FrameConfig",
8620
+ "description": "Fixed horizontal plot gutters."
8621
+ },
7570
8622
  "fields": {
7571
8623
  "type": "object",
7572
8624
  "additionalProperties": {
@@ -7891,6 +8943,10 @@
7891
8943
  "encoding": {
7892
8944
  "$ref": "#/definitions/LineEncoding%3CDataRow%3E"
7893
8945
  },
8946
+ "frame": {
8947
+ "$ref": "#/definitions/FrameConfig",
8948
+ "description": "Fixed horizontal plot gutters."
8949
+ },
7894
8950
  "fields": {
7895
8951
  "type": "object",
7896
8952
  "additionalProperties": {
@@ -8197,6 +9253,10 @@
8197
9253
  "encoding": {
8198
9254
  "$ref": "#/definitions/BarEncoding%3CDataRow%3E"
8199
9255
  },
9256
+ "frame": {
9257
+ "$ref": "#/definitions/FrameConfig",
9258
+ "description": "Fixed horizontal plot gutters."
9259
+ },
8200
9260
  "fields": {
8201
9261
  "type": "object",
8202
9262
  "additionalProperties": {
@@ -8521,6 +9581,10 @@
8521
9581
  "encoding": {
8522
9582
  "$ref": "#/definitions/AreaEncoding%3CDataRow%3E"
8523
9583
  },
9584
+ "frame": {
9585
+ "$ref": "#/definitions/FrameConfig",
9586
+ "description": "Fixed horizontal plot gutters."
9587
+ },
8524
9588
  "fields": {
8525
9589
  "type": "object",
8526
9590
  "additionalProperties": {
@@ -8818,6 +9882,10 @@
8818
9882
  "encoding": {
8819
9883
  "$ref": "#/definitions/PointEncoding%3CDataRow%3E"
8820
9884
  },
9885
+ "frame": {
9886
+ "$ref": "#/definitions/FrameConfig",
9887
+ "description": "Fixed horizontal plot gutters."
9888
+ },
8821
9889
  "fields": {
8822
9890
  "type": "object",
8823
9891
  "additionalProperties": {
@@ -9104,6 +10172,10 @@
9104
10172
  "encoding": {
9105
10173
  "$ref": "#/definitions/CircleEncoding%3CDataRow%3E"
9106
10174
  },
10175
+ "frame": {
10176
+ "$ref": "#/definitions/FrameConfig",
10177
+ "description": "Fixed horizontal plot gutters."
10178
+ },
9107
10179
  "fields": {
9108
10180
  "type": "object",
9109
10181
  "additionalProperties": {
@@ -9390,6 +10462,10 @@
9390
10462
  "encoding": {
9391
10463
  "$ref": "#/definitions/LollipopEncoding%3CDataRow%3E"
9392
10464
  },
10465
+ "frame": {
10466
+ "$ref": "#/definitions/FrameConfig",
10467
+ "description": "Fixed horizontal plot gutters."
10468
+ },
9393
10469
  "fields": {
9394
10470
  "type": "object",
9395
10471
  "additionalProperties": {
@@ -9676,6 +10752,10 @@
9676
10752
  "encoding": {
9677
10753
  "$ref": "#/definitions/BeeswarmEncoding%3CDataRow%3E"
9678
10754
  },
10755
+ "frame": {
10756
+ "$ref": "#/definitions/FrameConfig",
10757
+ "description": "Fixed horizontal plot gutters."
10758
+ },
9679
10759
  "fields": {
9680
10760
  "type": "object",
9681
10761
  "additionalProperties": {
@@ -9975,6 +11055,10 @@
9975
11055
  "encoding": {
9976
11056
  "$ref": "#/definitions/RangeEncoding%3CDataRow%3E"
9977
11057
  },
11058
+ "frame": {
11059
+ "$ref": "#/definitions/FrameConfig",
11060
+ "description": "Fixed horizontal plot gutters."
11061
+ },
9978
11062
  "fields": {
9979
11063
  "type": "object",
9980
11064
  "additionalProperties": {
@@ -10304,6 +11388,10 @@
10304
11388
  "encoding": {
10305
11389
  "$ref": "#/definitions/WaffleEncoding%3CDataRow%3E"
10306
11390
  },
11391
+ "frame": {
11392
+ "$ref": "#/definitions/FrameConfig",
11393
+ "description": "Fixed horizontal plot gutters."
11394
+ },
10307
11395
  "fields": {
10308
11396
  "type": "object",
10309
11397
  "additionalProperties": {
@@ -10620,6 +11708,10 @@
10620
11708
  "encoding": {
10621
11709
  "$ref": "#/definitions/TextEncoding%3CDataRow%3E"
10622
11710
  },
11711
+ "frame": {
11712
+ "$ref": "#/definitions/FrameConfig",
11713
+ "description": "Fixed horizontal plot gutters."
11714
+ },
10623
11715
  "fields": {
10624
11716
  "type": "object",
10625
11717
  "additionalProperties": {
@@ -10906,6 +11998,10 @@
10906
11998
  "encoding": {
10907
11999
  "$ref": "#/definitions/TickEncoding%3CDataRow%3E"
10908
12000
  },
12001
+ "frame": {
12002
+ "$ref": "#/definitions/FrameConfig",
12003
+ "description": "Fixed horizontal plot gutters."
12004
+ },
10909
12005
  "fields": {
10910
12006
  "type": "object",
10911
12007
  "additionalProperties": {
@@ -11204,6 +12300,10 @@
11204
12300
  "encoding": {
11205
12301
  "$ref": "#/definitions/RectEncoding%3CDataRow%3E"
11206
12302
  },
12303
+ "frame": {
12304
+ "$ref": "#/definitions/FrameConfig",
12305
+ "description": "Fixed horizontal plot gutters."
12306
+ },
11207
12307
  "fields": {
11208
12308
  "type": "object",
11209
12309
  "additionalProperties": {
@@ -11490,6 +12590,10 @@
11490
12590
  "encoding": {
11491
12591
  "$ref": "#/definitions/Encoding%3CDataRow%3E"
11492
12592
  },
12593
+ "frame": {
12594
+ "$ref": "#/definitions/FrameConfig",
12595
+ "description": "Fixed horizontal plot gutters."
12596
+ },
11493
12597
  "fields": {
11494
12598
  "type": "object",
11495
12599
  "additionalProperties": {
@@ -11788,6 +12892,10 @@
11788
12892
  "encoding": {
11789
12893
  "$ref": "#/definitions/CalendarEncoding%3CDataRow%3E"
11790
12894
  },
12895
+ "frame": {
12896
+ "$ref": "#/definitions/FrameConfig",
12897
+ "description": "Fixed horizontal plot gutters."
12898
+ },
11791
12899
  "fields": {
11792
12900
  "type": "object",
11793
12901
  "additionalProperties": {
@@ -12111,6 +13219,10 @@
12111
13219
  "encoding": {
12112
13220
  "$ref": "#/definitions/ParliamentEncoding%3CDataRow%3E"
12113
13221
  },
13222
+ "frame": {
13223
+ "$ref": "#/definitions/FrameConfig",
13224
+ "description": "Fixed horizontal plot gutters."
13225
+ },
12114
13226
  "fields": {
12115
13227
  "type": "object",
12116
13228
  "additionalProperties": {
@@ -12425,6 +13537,10 @@
12425
13537
  "encoding": {
12426
13538
  "$ref": "#/definitions/HistogramEncoding%3CDataRow%3E"
12427
13539
  },
13540
+ "frame": {
13541
+ "$ref": "#/definitions/FrameConfig",
13542
+ "description": "Fixed horizontal plot gutters."
13543
+ },
12428
13544
  "fields": {
12429
13545
  "type": "object",
12430
13546
  "additionalProperties": {
@@ -12761,6 +13877,10 @@
12761
13877
  "encoding": {
12762
13878
  "$ref": "#/definitions/DensityEncoding%3CDataRow%3E"
12763
13879
  },
13880
+ "frame": {
13881
+ "$ref": "#/definitions/FrameConfig",
13882
+ "description": "Fixed horizontal plot gutters."
13883
+ },
12764
13884
  "fields": {
12765
13885
  "type": "object",
12766
13886
  "additionalProperties": {
@@ -12971,6 +14091,18 @@
12971
14091
  "LayerSpec<DataRow>": {
12972
14092
  "type": "object",
12973
14093
  "properties": {
14094
+ "display": {
14095
+ "$ref": "#/definitions/Display",
14096
+ "description": "Display defaults shared by every leaf."
14097
+ },
14098
+ "a11y": {
14099
+ "$ref": "#/definitions/A11yConfig",
14100
+ "description": "Figure accessibility; hidden cells omit the image role."
14101
+ },
14102
+ "frame": {
14103
+ "$ref": "#/definitions/FrameConfig",
14104
+ "description": "Fixed horizontal plot gutters shared by the figure."
14105
+ },
12974
14106
  "layer": {
12975
14107
  "type": "array",
12976
14108
  "items": {
@@ -14185,6 +15317,34 @@
14185
15317
  "$ref": "#/definitions/FieldType",
14186
15318
  "description": "How to interpret the field values.\n- quantitative: continuous numbers (scale: linear)\n- temporal: dates/times (scale: time)\n- nominal: unordered categories (scale: ordinal)\n- ordinal: ordered categories (scale: ordinal)"
14187
15319
  },
15320
+ "interval": {
15321
+ "anyOf": [
15322
+ {
15323
+ "type": "string",
15324
+ "const": "day"
15325
+ },
15326
+ {
15327
+ "type": "string",
15328
+ "const": "week"
15329
+ },
15330
+ {
15331
+ "type": "string",
15332
+ "const": "month"
15333
+ },
15334
+ {
15335
+ "type": "string",
15336
+ "const": "quarter"
15337
+ },
15338
+ {
15339
+ "type": "string",
15340
+ "const": "year"
15341
+ },
15342
+ {
15343
+ "type": "number"
15344
+ }
15345
+ ],
15346
+ "description": "Temporal bar position interval; numbers are milliseconds. Bar marks only."
15347
+ },
14188
15348
  "aggregate": {
14189
15349
  "$ref": "#/definitions/AggregateOp",
14190
15350
  "description": "Optional aggregate to apply before encoding."
@@ -15089,6 +16249,149 @@
15089
16249
  "$ref": "#/definitions/BarListEncoding",
15090
16250
  "description": "Encoding channels mapping data fields to visual properties."
15091
16251
  },
16252
+ "sort": {
16253
+ "type": [
16254
+ "string",
16255
+ "null"
16256
+ ],
16257
+ "enum": [
16258
+ "descending",
16259
+ "ascending",
16260
+ null
16261
+ ],
16262
+ "description": "Ordering within each first-seen group. Default descending; null preserves input order."
16263
+ },
16264
+ "height": {
16265
+ "anyOf": [
16266
+ {
16267
+ "type": "number"
16268
+ },
16269
+ {
16270
+ "type": "string",
16271
+ "const": "auto"
16272
+ }
16273
+ ],
16274
+ "description": "Auto height fits every admitted row and its group headers."
16275
+ },
16276
+ "annotations": {
16277
+ "type": "array",
16278
+ "items": {
16279
+ "type": "object",
16280
+ "additionalProperties": false,
16281
+ "properties": {
16282
+ "x": {
16283
+ "type": "number"
16284
+ },
16285
+ "type": {
16286
+ "type": "string",
16287
+ "const": "refline",
16288
+ "description": "Reference-line annotation discriminant. Older rule aliases require migrateSpecV8."
16289
+ },
16290
+ "label": {
16291
+ "type": "string",
16292
+ "description": "Text drawn with the reference line."
16293
+ },
16294
+ "style": {
16295
+ "type": "string",
16296
+ "enum": [
16297
+ "solid",
16298
+ "dashed",
16299
+ "dotted"
16300
+ ],
16301
+ "description": "Line style."
16302
+ },
16303
+ "strokeDash": {
16304
+ "type": "array",
16305
+ "items": {
16306
+ "type": "number"
16307
+ },
16308
+ "description": "Raw SVG dash pattern override, e.g. [4, 4]. Takes precedence over style."
16309
+ },
16310
+ "strokeWidth": {
16311
+ "type": "number",
16312
+ "description": "Line width in pixels."
16313
+ },
16314
+ "labelOffset": {
16315
+ "$ref": "#/definitions/AnnotationOffset",
16316
+ "description": "Pixel offset for the reference line label."
16317
+ },
16318
+ "labelPlacement": {
16319
+ "type": "string",
16320
+ "enum": [
16321
+ "auto",
16322
+ "start",
16323
+ "end",
16324
+ "outside"
16325
+ ],
16326
+ "description": "Screen-space label placement. Outside reserves a right gutter or top lane; omission uses auto unless labelAnchor is authored."
16327
+ },
16328
+ "labelAnchor": {
16329
+ "$ref": "#/definitions/AnnotationAnchor",
16330
+ "description": "Anchor direction for the reference line label."
16331
+ },
16332
+ "fontSize": {
16333
+ "type": "number",
16334
+ "description": "Label font size in pixels. Default: theme small (12px)."
16335
+ },
16336
+ "fontWeight": {
16337
+ "type": "number",
16338
+ "description": "Label font weight. Default: 400."
16339
+ },
16340
+ "id": {
16341
+ "type": "string",
16342
+ "description": "Stable identifier for selection and edit callbacks. When provided, edit events include this ID for reliable element matching."
16343
+ },
16344
+ "fill": {
16345
+ "type": "string",
16346
+ "description": "Fill color for the annotation element."
16347
+ },
16348
+ "stroke": {
16349
+ "type": "string",
16350
+ "description": "Stroke color for the annotation element."
16351
+ },
16352
+ "opacity": {
16353
+ "type": "number",
16354
+ "description": "Opacity from 0 to 1."
16355
+ },
16356
+ "zIndex": {
16357
+ "type": "number",
16358
+ "description": "Z-index for render ordering. Higher values render on top."
16359
+ },
16360
+ "responsive": {
16361
+ "type": "boolean",
16362
+ "description": "When false, the annotation is always shown even at compact breakpoints. Default true."
16363
+ }
16364
+ },
16365
+ "required": [
16366
+ "type",
16367
+ "x"
16368
+ ]
16369
+ },
16370
+ "description": "Vertical value reference lines."
16371
+ },
16372
+ "labels": {
16373
+ "type": "object",
16374
+ "properties": {
16375
+ "format": {
16376
+ "type": "string",
16377
+ "description": "Number format override for label values (d3-format string, e.g. \",.0f\")."
16378
+ },
16379
+ "prefix": {
16380
+ "type": "string",
16381
+ "description": "Literal string prepended to each formatted label value (e.g. \"-\" or \"$\")."
16382
+ },
16383
+ "suffix": {
16384
+ "type": "string",
16385
+ "description": "Literal string appended to each formatted label value (e.g. \"%\" or \"x\")."
16386
+ }
16387
+ },
16388
+ "additionalProperties": false,
16389
+ "description": "Value label formatting."
16390
+ },
16391
+ "a11y": {
16392
+ "$ref": "#/definitions/A11yConfig",
16393
+ "description": "Accessible figure name and visibility."
16394
+ },
15092
16395
  "barHeight": {
15093
16396
  "type": "number",
15094
16397
  "description": "Bar height in pixels. Defaults to 6."
@@ -15136,6 +16439,14 @@
15136
16439
  "BarListEncoding": {
15137
16440
  "type": "object",
15138
16441
  "properties": {
16442
+ "description": {
16443
+ "$ref": "#/definitions/DescriptionEncoding",
16444
+ "description": "Authored row description."
16445
+ },
16446
+ "group": {
16447
+ "$ref": "#/definitions/EncodingChannel",
16448
+ "description": "Nominal group labels, retained in first-seen order."
16449
+ },
15139
16450
  "label": {
15140
16451
  "$ref": "#/definitions/EncodingChannel",
15141
16452
  "description": "Label field (required, nominal). The category name for each row."
@@ -15174,6 +16485,44 @@
15174
16485
  "additionalProperties": false,
15175
16486
  "description": "Encoding channels for a barlist visualization."
15176
16487
  },
16488
+ "DescriptionEncoding": {
16489
+ "anyOf": [
16490
+ {
16491
+ "type": "object",
16492
+ "additionalProperties": false,
16493
+ "properties": {
16494
+ "type": {
16495
+ "$ref": "#/definitions/FieldType",
16496
+ "description": "How to interpret the field values.\n- quantitative: continuous numbers (scale: linear)\n- temporal: dates/times (scale: time)\n- nominal: unordered categories (scale: ordinal)\n- ordinal: ordered categories (scale: ordinal)"
16497
+ },
16498
+ "format": {
16499
+ "type": "string",
16500
+ "description": "Format string for values (Vega-Lite aligned). For quantitative fields: d3-format string (e.g. \",.0f\", \"$,.2f\"), or semantic keyword `'percent'` / `'currency'`. For temporal fields: d3-time-format string (e.g. \"%Y\", \"%b %d\"). Used in tooltips; `axis.format` takes precedence for axis tick labels."
16501
+ },
16502
+ "field": {
16503
+ "type": "string",
16504
+ "description": "Data field name (column in the data array).\n\nWhen using `ChartSpec<TData>` with a typed data array, this is constrained to the actual column names of `TData`. Typos fail at compile time and IDEs autocomplete your column names."
16505
+ }
16506
+ },
16507
+ "required": [
16508
+ "field"
16509
+ ]
16510
+ },
16511
+ {
16512
+ "type": "object",
16513
+ "properties": {
16514
+ "value": {
16515
+ "type": "string"
16516
+ }
16517
+ },
16518
+ "required": [
16519
+ "value"
16520
+ ],
16521
+ "additionalProperties": false
16522
+ }
16523
+ ],
16524
+ "description": "Authored mark text, kept verbatim for strings and formatted for numeric fields."
16525
+ },
15177
16526
  "ChartSpecBase": {
15178
16527
  "type": "object",
15179
16528
  "additionalProperties": false,
@@ -15184,6 +16533,10 @@
15184
16533
  "encoding": {
15185
16534
  "description": "Encoding channel map."
15186
16535
  },
16536
+ "frame": {
16537
+ "$ref": "#/definitions/FrameConfig",
16538
+ "description": "Fixed horizontal plot gutters."
16539
+ },
15187
16540
  "fields": {
15188
16541
  "type": "object",
15189
16542
  "additionalProperties": {