@opendata-ai/openchart-core 9.3.0 → 9.5.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.
@@ -132,7 +132,7 @@
132
132
  "properties": {
133
133
  "innerRadius": {
134
134
  "type": "number",
135
- "description": "Inner radius for arc marks. >0 produces a donut, 0 or omitted produces a pie."
135
+ "description": "Inner radius for arc marks: 0 for a pie; a value below 1 is a fraction of the outer radius (0.6 = 60%); 1 or more is pixels."
136
136
  },
137
137
  "outerRadius": {
138
138
  "type": "number",
@@ -2623,7 +2623,7 @@
2623
2623
  "$ref": "#/definitions/SortByField"
2624
2624
  }
2625
2625
  ],
2626
- "description": "Sort order for categorical (nominal/ordinal) scale domains (Vega-Lite aligned).\n- 'ascending': sort domain values ascending (default VL behavior)\n- 'descending': sort domain values descending\n- null: use data order (no sorting)\n- undefined: ascending (VL default)\n- 'x' | '-x' | 'y' | '-y': sort by another channel's values ('-' prefix for descending). The VL ranked-bar idiom: `sort: '-y'` orders categories by value, largest first. Resolved into an explicit domain during the pre-validation sugar expansion.\n- string[]: explicit value order. Listed values come first (in the given order); unlisted data values follow in data order.\n- SortByField: sort by the aggregated values of another field."
2626
+ "description": "Sort order for categorical (nominal/ordinal) scale domains (Vega-Lite aligned).\n- 'ascending': sort domain values ascending (default VL behavior)\n- 'descending': sort domain values descending\n- null: use data order (no sorting)\n- undefined: keep data order\n- 'x' | '-x' | 'y' | '-y': sort by another channel's values ('-' prefix for descending). The VL ranked-bar idiom: `sort: '-y'` orders categories by value, largest first. Resolved into an explicit domain during the pre-validation sugar expansion.\n- string[]: explicit value order. Listed values come first (in the given order); unlisted data values follow in data order.\n- SortByField: sort by the aggregated values of another field. On a categorical (band or point) `y`, the first domain value is drawn at the top, so data order and `sort: '-x'` (largest first) read top to bottom. `scale.reverse` flips it."
2627
2627
  },
2628
2628
  "legend": {
2629
2629
  "anyOf": [
@@ -2698,6 +2698,17 @@
2698
2698
  "type": "number",
2699
2699
  "description": "Override tick count. Engine picks a sensible default if omitted."
2700
2700
  },
2701
+ "tickStep": {
2702
+ "anyOf": [
2703
+ {
2704
+ "type": "number"
2705
+ },
2706
+ {
2707
+ "$ref": "#/definitions/TimeTickStep"
2708
+ }
2709
+ ],
2710
+ "description": "Distance between ticks: a number in data units on a quantitative axis, a `TimeTickStep` on a temporal axis. `values` wins over `tickStep`, which wins over `tickCount`."
2711
+ },
2701
2712
  "grid": {
2702
2713
  "type": "boolean",
2703
2714
  "description": "Whether to show gridlines for this axis."
@@ -2778,9 +2789,13 @@
2778
2789
  "type": "string",
2779
2790
  "description": "Color override for axis tick labels and title. Useful in dual-axis charts to match axis color to its series."
2780
2791
  },
2792
+ "labelPrefix": {
2793
+ "type": "string",
2794
+ "description": "Text before every tick label, e.g. \"$\". Also shown before this channel's values in tooltips."
2795
+ },
2781
2796
  "labelSuffix": {
2782
2797
  "type": "string",
2783
- "description": "Literal string appended to every formatted tick label. e.g. \"B\" gives \"$4.5B\" when format is \"$,.1~f\"."
2798
+ "description": "Literal string appended to every formatted tick label. e.g. \"B\" gives \"$4.5B\" when format is \"$,.1~f\". Also shown after this channel's values in tooltips."
2784
2799
  },
2785
2800
  "labelField": {
2786
2801
  "type": "string",
@@ -2798,6 +2813,35 @@
2798
2813
  "additionalProperties": false,
2799
2814
  "description": "Axis configuration for an encoding channel."
2800
2815
  },
2816
+ "TimeTickStep": {
2817
+ "type": "object",
2818
+ "properties": {
2819
+ "interval": {
2820
+ "$ref": "#/definitions/TimeTickInterval"
2821
+ },
2822
+ "step": {
2823
+ "type": "number"
2824
+ }
2825
+ },
2826
+ "required": [
2827
+ "interval"
2828
+ ],
2829
+ "additionalProperties": false,
2830
+ "description": "A tick every `step` intervals, e.g. `{ interval: 'month', step: 3 }`. `step` defaults to 1."
2831
+ },
2832
+ "TimeTickInterval": {
2833
+ "type": "string",
2834
+ "enum": [
2835
+ "year",
2836
+ "quarter",
2837
+ "month",
2838
+ "week",
2839
+ "day",
2840
+ "hour",
2841
+ "minute"
2842
+ ],
2843
+ "description": "A time interval for temporal axis ticks. `quarter` is three months."
2844
+ },
2801
2845
  "ScaleConfig": {
2802
2846
  "type": "object",
2803
2847
  "properties": {
@@ -2818,6 +2862,14 @@
2818
2862
  ],
2819
2863
  "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."
2820
2864
  },
2865
+ "domainMin": {
2866
+ "type": "number",
2867
+ "description": "Fixed lower end of a quantitative scale. The upper end still fits the data (with `zero` and `nice` applied to it). Ignored when `domain` is set; validation rejects both together."
2868
+ },
2869
+ "domainMax": {
2870
+ "type": "number",
2871
+ "description": "Fixed upper end of a quantitative scale; the lower end still fits the data."
2872
+ },
2821
2873
  "type": {
2822
2874
  "$ref": "#/definitions/ScaleType",
2823
2875
  "description": "Scale type override. Usually inferred from field type."
@@ -3959,6 +4011,10 @@
3959
4011
  "ChromeText": {
3960
4012
  "type": "object",
3961
4013
  "properties": {
4014
+ "href": {
4015
+ "type": "string",
4016
+ "description": "Makes the text a link. http, https and mailto only; opens in a new tab."
4017
+ },
3962
4018
  "text": {
3963
4019
  "type": "string",
3964
4020
  "description": "The text content to display."
@@ -4097,8 +4153,16 @@
4097
4153
  "description": "Z-index for render ordering. Higher values render on top."
4098
4154
  },
4099
4155
  "responsive": {
4100
- "type": "boolean",
4101
- "description": "When false, the annotation is always shown even at compact breakpoints. Default true."
4156
+ "anyOf": [
4157
+ {
4158
+ "type": "boolean"
4159
+ },
4160
+ {
4161
+ "type": "string",
4162
+ "const": "hide"
4163
+ }
4164
+ ],
4165
+ "description": "At compact widths (below 400 px): true (default) thins or demotes the note to a footnote, false always shows it, 'hide' leaves it out entirely."
4102
4166
  },
4103
4167
  "type": {
4104
4168
  "type": "string",
@@ -4312,8 +4376,16 @@
4312
4376
  "description": "Z-index for render ordering. Higher values render on top."
4313
4377
  },
4314
4378
  "responsive": {
4315
- "type": "boolean",
4316
- "description": "When false, the annotation is always shown even at compact breakpoints. Default true."
4379
+ "anyOf": [
4380
+ {
4381
+ "type": "boolean"
4382
+ },
4383
+ {
4384
+ "type": "string",
4385
+ "const": "hide"
4386
+ }
4387
+ ],
4388
+ "description": "At compact widths (below 400 px): true (default) thins or demotes the note to a footnote, false always shows it, 'hide' leaves it out entirely."
4317
4389
  },
4318
4390
  "type": {
4319
4391
  "type": "string",
@@ -4402,8 +4474,16 @@
4402
4474
  "description": "Z-index for render ordering. Higher values render on top."
4403
4475
  },
4404
4476
  "responsive": {
4405
- "type": "boolean",
4406
- "description": "When false, the annotation is always shown even at compact breakpoints. Default true."
4477
+ "anyOf": [
4478
+ {
4479
+ "type": "boolean"
4480
+ },
4481
+ {
4482
+ "type": "string",
4483
+ "const": "hide"
4484
+ }
4485
+ ],
4486
+ "description": "At compact widths (below 400 px): true (default) thins or demotes the note to a footnote, false always shows it, 'hide' leaves it out entirely."
4407
4487
  },
4408
4488
  "type": {
4409
4489
  "type": "string",
@@ -4519,11 +4599,15 @@
4519
4599
  },
4520
4600
  "prefix": {
4521
4601
  "type": "string",
4522
- "description": "Literal string prepended to each formatted label value (e.g. \"-\" or \"$\")."
4602
+ "description": "Literal string prepended to each formatted label value (e.g. \"-\" or \"$\"). Applies to bar, column and arc (pie, donut) labels."
4523
4603
  },
4524
4604
  "suffix": {
4525
4605
  "type": "string",
4526
- "description": "Literal string appended to each formatted label value (e.g. \"%\" or \"x\")."
4606
+ "description": "Literal string appended to each formatted label value (e.g. \"%\" or \"x\"). Applies to bar, column and arc (pie, donut) labels."
4607
+ },
4608
+ "highlightedOnly": {
4609
+ "type": "boolean",
4610
+ "description": "Label only the series or values named in `encoding.color.highlight`: bar and column value labels, and the endpoint labels of line and area charts, which otherwise also name muted series in a quieter ink."
4527
4611
  },
4528
4612
  "color": {
4529
4613
  "type": "string",
@@ -4619,6 +4703,14 @@
4619
4703
  "type": "string",
4620
4704
  "description": "d3-format string for the value. Defaults to `encoding.y.axis.format`."
4621
4705
  },
4706
+ "prefix": {
4707
+ "type": "string",
4708
+ "description": "Text before the formatted value, e.g. \"$\"."
4709
+ },
4710
+ "suffix": {
4711
+ "type": "string",
4712
+ "description": "Text after the formatted value, e.g. \"bn\"."
4713
+ },
4622
4714
  "width": {
4623
4715
  "type": "number",
4624
4716
  "description": "Max wrap width in pixels for long series names. Default 96."
@@ -4764,6 +4856,10 @@
4764
4856
  "$ref": "#/definitions/TokenValue",
4765
4857
  "description": "Annotation muted color. Accepts a TokenValue light/dark pair."
4766
4858
  },
4859
+ "muted": {
4860
+ "$ref": "#/definitions/TokenValue",
4861
+ "description": "Color for values that highlight mutes. Accepts a TokenValue for light/dark pairs."
4862
+ },
4767
4863
  "annotationLeader": {
4768
4864
  "$ref": "#/definitions/TokenValue",
4769
4865
  "description": "Annotation leader color. Accepts a TokenValue light/dark pair."
@@ -5131,6 +5227,14 @@
5131
5227
  ],
5132
5228
  "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."
5133
5229
  },
5230
+ "domainMin": {
5231
+ "type": "number",
5232
+ "description": "Fixed lower end of a quantitative scale. The upper end still fits the data (with `zero` and `nice` applied to it). Ignored when `domain` is set; validation rejects both together."
5233
+ },
5234
+ "domainMax": {
5235
+ "type": "number",
5236
+ "description": "Fixed upper end of a quantitative scale; the lower end still fits the data."
5237
+ },
5134
5238
  "type": {
5135
5239
  "$ref": "#/definitions/ScaleType",
5136
5240
  "description": "Scale type override. Usually inferred from field type."
@@ -5220,6 +5324,14 @@
5220
5324
  ],
5221
5325
  "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."
5222
5326
  },
5327
+ "domainMin": {
5328
+ "type": "number",
5329
+ "description": "Fixed lower end of a quantitative scale. The upper end still fits the data (with `zero` and `nice` applied to it). Ignored when `domain` is set; validation rejects both together."
5330
+ },
5331
+ "domainMax": {
5332
+ "type": "number",
5333
+ "description": "Fixed upper end of a quantitative scale; the lower end still fits the data."
5334
+ },
5223
5335
  "type": {
5224
5336
  "$ref": "#/definitions/ScaleType",
5225
5337
  "description": "Scale type override. Usually inferred from field type."
@@ -5309,6 +5421,14 @@
5309
5421
  ],
5310
5422
  "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."
5311
5423
  },
5424
+ "domainMin": {
5425
+ "type": "number",
5426
+ "description": "Fixed lower end of a quantitative scale. The upper end still fits the data (with `zero` and `nice` applied to it). Ignored when `domain` is set; validation rejects both together."
5427
+ },
5428
+ "domainMax": {
5429
+ "type": "number",
5430
+ "description": "Fixed upper end of a quantitative scale; the lower end still fits the data."
5431
+ },
5312
5432
  "type": {
5313
5433
  "$ref": "#/definitions/ScaleType",
5314
5434
  "description": "Scale type override. Usually inferred from field type."
@@ -5398,6 +5518,14 @@
5398
5518
  ],
5399
5519
  "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."
5400
5520
  },
5521
+ "domainMin": {
5522
+ "type": "number",
5523
+ "description": "Fixed lower end of a quantitative scale. The upper end still fits the data (with `zero` and `nice` applied to it). Ignored when `domain` is set; validation rejects both together."
5524
+ },
5525
+ "domainMax": {
5526
+ "type": "number",
5527
+ "description": "Fixed upper end of a quantitative scale; the lower end still fits the data."
5528
+ },
5401
5529
  "type": {
5402
5530
  "$ref": "#/definitions/ScaleType",
5403
5531
  "description": "Scale type override. Usually inferred from field type."
@@ -9,6 +9,10 @@
9
9
  "TableSpec": {
10
10
  "type": "object",
11
11
  "properties": {
12
+ "a11y": {
13
+ "$ref": "#/definitions/A11yDescriptionConfig",
14
+ "description": "An author-written description for assistive technology."
15
+ },
12
16
  "mobileLayout": {
13
17
  "type": "string",
14
18
  "enum": [
@@ -134,6 +138,17 @@
134
138
  "additionalProperties": false,
135
139
  "description": "Table specification: input for data table visualizations.\n\nTables are a visualization type, not just an HTML grid. They support heatmap coloring, inline sparklines, sorted columns, search, and pagination."
136
140
  },
141
+ "A11yDescriptionConfig": {
142
+ "type": "object",
143
+ "properties": {
144
+ "description": {
145
+ "type": "string",
146
+ "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."
147
+ }
148
+ },
149
+ "additionalProperties": false,
150
+ "description": "An author-written description for assistive technology."
151
+ },
137
152
  "FieldMetadata": {
138
153
  "type": "object",
139
154
  "properties": {
@@ -519,6 +534,10 @@
519
534
  "ChromeText": {
520
535
  "type": "object",
521
536
  "properties": {
537
+ "href": {
538
+ "type": "string",
539
+ "description": "Makes the text a link. http, https and mailto only; opens in a new tab."
540
+ },
522
541
  "text": {
523
542
  "type": "string",
524
543
  "description": "The text content to display."
@@ -664,6 +683,10 @@
664
683
  "$ref": "#/definitions/TokenValue",
665
684
  "description": "Annotation muted color. Accepts a TokenValue light/dark pair."
666
685
  },
686
+ "muted": {
687
+ "$ref": "#/definitions/TokenValue",
688
+ "description": "Color for values that highlight mutes. Accepts a TokenValue for light/dark pairs."
689
+ },
667
690
  "annotationLeader": {
668
691
  "$ref": "#/definitions/TokenValue",
669
692
  "description": "Annotation leader color. Accepts a TokenValue light/dark pair."