@astrato-io/visualizations 0.6.4 → 0.7.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.
Files changed (220) hide show
  1. package/CHANGELOG.md +0 -0
  2. package/README.md +32 -2
  3. package/THIRD_PARTY_NOTICES.md +68 -205
  4. package/VISUALIZATION_DEFINITIONS.md +68 -114
  5. package/chunks/Button-BrGKp9Nm.js +110 -0
  6. package/chunks/DefaultPropsProvider-BsfB7QTn.js +257 -0
  7. package/chunks/FieldTypeIcon-Drs6hSJF.js +22 -0
  8. package/chunks/{LinearProgress-CUZ0D8_t.js → LinearProgress-VtfFx2vJ.js} +51 -51
  9. package/chunks/MenuOption-ByRqhRdX.js +3934 -0
  10. package/chunks/Title-CO5dP1ma.js +1691 -0
  11. package/chunks/ToggleButton-KOBAimC1.js +112 -0
  12. package/chunks/app-filter-bar.compiler-TwVTeoj5.js +64 -0
  13. package/chunks/bar.compiler-DuQg8EUb.js +374 -0
  14. package/chunks/builder-DEDvNq1k.js +201 -0
  15. package/chunks/{color-settings-ZIvgNTq1.js → color-rules-CN7TcGrC.js} +2 -6
  16. package/chunks/color-settings-3VRlf_Vw.js +6 -0
  17. package/chunks/colorManipulator-D8Pjy1pf.js +45 -0
  18. package/chunks/coloring-CncX_JRX.js +278 -0
  19. package/chunks/{src-BC7cGcJ-.js → definitions-BPJQTx16.js} +650 -464
  20. package/chunks/{escobar-BGqT1EsE.js → escobar-DRhRMYRE.js} +6282 -4931
  21. package/chunks/event-bus-CrLB-Y8z.js +3 -0
  22. package/chunks/extend-preset-CUFNpmPe.js +4398 -0
  23. package/chunks/filter.compiler-w27dlv0C.js +70 -0
  24. package/chunks/filtering-cc7WqWpg.js +1153 -0
  25. package/chunks/handlers-TOT-7INo.js +12871 -0
  26. package/chunks/icon-picker-styles-CoJmwTRi.js +2246 -0
  27. package/chunks/isEqual-B8loyPsC.js +12 -0
  28. package/chunks/label-format-type-weq1XfcX.js +8 -0
  29. package/chunks/line.compiler-Ct1WhN2p.js +198 -0
  30. package/chunks/logger-DpQtYQnX.js +1163 -0
  31. package/chunks/lookup-BWllin0q.js +36 -0
  32. package/chunks/{metadata-CPXdYoln.js → metadata-WABZrt7Y.js} +1 -1
  33. package/chunks/number.compiler-D8TPly-4.js +53 -0
  34. package/chunks/{src-C0LgoUWY.js → operations-Dh4v1Ovt.js} +7716 -7541
  35. package/chunks/{range-DrzdfBX4.js → range-Bi-7zT0k.js} +2 -2
  36. package/chunks/registry-KervaxqJ.js +31 -0
  37. package/chunks/render-wrappers-OEmtaM8g.js +2 -0
  38. package/chunks/{registry-CExpGJ1N.js → requirements-PAoRaJyb.js} +294 -326
  39. package/chunks/responsive.styles-DSiOGD7u.js +82 -0
  40. package/chunks/shared-Bn4N5QcZ.js +1218 -0
  41. package/chunks/src-77e3mC7i.js +391 -0
  42. package/chunks/standalone-B55oyW6c.js +689 -0
  43. package/chunks/{standalone-CY57qwZ-.js → standalone-BDhPQtzQ.js} +386 -352
  44. package/chunks/{standalone-BDCwI6Hn.js → standalone-BGkmozIb.js} +1108 -953
  45. package/chunks/standalone-BMTCb10X.js +179 -0
  46. package/chunks/standalone-BXKRE_Se.js +468 -0
  47. package/chunks/standalone-Bes8srx1.js +354 -0
  48. package/chunks/standalone-BjZp0QMe.js +2 -0
  49. package/chunks/{standalone-BH5NqDwp.js → standalone-BlMIwpEe.js} +687 -573
  50. package/chunks/{standalone-CCNtaJ7s.js → standalone-C8ZAEutO.js} +44 -43
  51. package/chunks/standalone-C8qAelL4.js +2 -0
  52. package/chunks/standalone-CJvIXsQE.js +743 -0
  53. package/chunks/standalone-CLmGb7nn2.js +355 -0
  54. package/chunks/{ui-D1HQNIBy.js → standalone-CM5XcAN5.js} +15946 -17658
  55. package/chunks/standalone-CXNP6-xD.js +420 -0
  56. package/chunks/{standalone-BYm1UjLr.js → standalone-D5Q5ngsD.js} +59 -57
  57. package/chunks/standalone-DLlyRIE6.js +287 -0
  58. package/chunks/standalone-DMcI1afI.js +396 -0
  59. package/chunks/{standalone-jiz0L2Dg.js → standalone-DN4S1MjT.js} +1113 -1094
  60. package/chunks/{standalone-QJ1kKMnO.js → standalone-DT0wKji7.js} +2 -2
  61. package/chunks/{standalone-D5vnf-9y.js → standalone-DVTJwsTY.js} +1110 -1035
  62. package/chunks/standalone-DW6NT205.js +518 -0
  63. package/chunks/standalone-DYQIQH4c.js +2095 -0
  64. package/chunks/standalone-D__XCp-h.js +1003 -0
  65. package/chunks/standalone-XTgSsTAa.js +354 -0
  66. package/chunks/standalone-XuGksArp.js +68 -0
  67. package/chunks/{standalone-CNyNHKVx.js → standalone-we5D5MIn.js} +176 -172
  68. package/chunks/table.compiler-DMeeHxb6.js +222 -0
  69. package/chunks/useFieldName-Cjn9KCVp.js +7 -0
  70. package/chunks/useSlotProps-DLbQp4lc.js +166 -0
  71. package/chunks/{utils-Ba9T0TqC.js → utils-vdmi_2PK.js} +6266 -6517
  72. package/chunks/{src-DvX5LU9T.js → view-BuwQugKb.js} +2893 -5956
  73. package/chunks/visualization-filters-Cc4KU-l-.js +7455 -0
  74. package/chunks/web-components-DqClFkgO.js +1185 -0
  75. package/chunks/with-html-element-D0uY2zjI.js +7328 -0
  76. package/definitions.js +3 -3
  77. package/docs/operations/astrato-app-filter-bar.md +17 -17
  78. package/docs/operations/bar.md +1006 -1071
  79. package/docs/operations/combo.md +717 -738
  80. package/docs/operations/date-picker.md +27 -27
  81. package/docs/operations/distribution-gauge.md +471 -607
  82. package/docs/operations/dot.md +787 -879
  83. package/docs/operations/filter.md +139 -163
  84. package/docs/operations/gauge.md +491 -627
  85. package/docs/operations/heatMap.md +834 -916
  86. package/docs/operations/histogram.md +166 -180
  87. package/docs/operations/iframe.md +5 -5
  88. package/docs/operations/image.md +16 -16
  89. package/docs/operations/index.md +12 -12
  90. package/docs/operations/line.md +811 -888
  91. package/docs/operations/number.md +470 -536
  92. package/docs/operations/pie.md +825 -958
  93. package/docs/operations/radar.md +599 -679
  94. package/docs/operations/sankey.md +462 -584
  95. package/docs/operations/scatter.md +823 -929
  96. package/docs/operations/shape.md +34 -34
  97. package/docs/operations/simpleTextObject.md +18 -25
  98. package/docs/operations/slider.md +33 -43
  99. package/docs/operations/table.md +1177 -1150
  100. package/docs/operations/tree.md +404 -397
  101. package/docs/operations/treemap.md +595 -673
  102. package/docs/operations/waterfall.md +369 -379
  103. package/docs/operations/word-cloud.md +512 -583
  104. package/getters.js +7 -7
  105. package/index.js +3 -1183
  106. package/metadata.js +18 -18
  107. package/operations.js +13 -13
  108. package/package.json +133 -88
  109. package/render.js +10 -0
  110. package/src/charts/bar.d.ts +1 -0
  111. package/src/charts/combo.d.ts +1 -0
  112. package/src/charts/dot.d.ts +1 -0
  113. package/src/charts/gauge-distribution.d.ts +1 -0
  114. package/src/charts/gauge.d.ts +1 -0
  115. package/src/charts/heat-map.d.ts +1 -0
  116. package/src/charts/histogram.d.ts +1 -0
  117. package/src/charts/line.d.ts +1 -0
  118. package/src/charts/pie.d.ts +1 -0
  119. package/src/charts/radar.d.ts +1 -0
  120. package/src/charts/sankey.d.ts +1 -0
  121. package/src/charts/scatter.d.ts +1 -0
  122. package/src/charts/table.d.ts +1 -0
  123. package/src/charts/tree.d.ts +1 -0
  124. package/src/charts/treemap.d.ts +1 -0
  125. package/src/charts/waterfall.d.ts +1 -0
  126. package/src/charts/word-cloud.d.ts +1 -0
  127. package/src/definitions/index.d.ts +2 -2
  128. package/src/definitions/{shared/lib → model/definitions}/available-fields.d.ts +0 -1
  129. package/src/definitions/{shared/lib/compilers/index.d.ts → model/definitions/compilers/compile.d.ts} +1 -1
  130. package/src/definitions/model/definitions/data-item-resolution.d.ts +19 -0
  131. package/src/definitions/model/definitions/descriptors/descriptor-metadata.d.ts +1364 -0
  132. package/src/definitions/model/definitions/descriptors/json-schema.d.ts +2 -0
  133. package/src/definitions/model/definitions/diagnostics.d.ts +5 -0
  134. package/src/definitions/model/definitions/field-suggestions.d.ts +2 -0
  135. package/src/definitions/model/definitions/index.d.ts +23 -0
  136. package/src/definitions/{shared/lib → model/definitions}/registry/compile.d.ts +1 -1
  137. package/src/definitions/model/definitions/registry/descriptor-registry.d.ts +3 -0
  138. package/src/definitions/model/definitions/schema-registry.d.ts +660 -0
  139. package/src/definitions/{shared/lib → model/definitions}/schemas/broad-chart.schema.d.ts +1 -1
  140. package/src/definitions/{shared/lib → model/definitions}/schemas/common.schema.d.ts +0 -1
  141. package/src/definitions/model/definitions/schemas/index.d.ts +9 -0
  142. package/src/definitions/{shared/lib → model/definitions}/schemas/object.schema.d.ts +8 -8
  143. package/src/definitions/{shared/lib → model/definitions}/types/compilation.types.d.ts +10 -0
  144. package/src/definitions/{shared/lib → model/definitions}/types/definition.types.d.ts +1 -1
  145. package/src/definitions/model/definitions/types/index.d.ts +3 -0
  146. package/src/definitions/{shared/lib/registry → model/definitions}/validation.d.ts +1 -1
  147. package/src/getters/index.d.ts +3 -3
  148. package/src/index.d.ts +1 -1
  149. package/src/objects/app-filter-bar.d.ts +1 -0
  150. package/src/objects/date-picker.d.ts +1 -0
  151. package/src/objects/filter.d.ts +1 -0
  152. package/src/objects/iframe.d.ts +1 -0
  153. package/src/objects/image.d.ts +1 -0
  154. package/src/objects/number.d.ts +1 -0
  155. package/src/objects/shape.d.ts +1 -0
  156. package/src/objects/slider.d.ts +1 -0
  157. package/src/objects/text.d.ts +1 -0
  158. package/src/operations/index.d.ts +3 -3
  159. package/src/registry/create-visualization-registry.d.ts +5 -0
  160. package/src/render/index.d.ts +34 -0
  161. package/src/runtime/index.d.ts +2 -2
  162. package/src/types.d.ts +9 -4
  163. package/src/web-components/index.d.ts +3 -3
  164. package/chunks/Radio-Ciu-F4CU.js +0 -957
  165. package/chunks/ToggleButton-BCJc3Jlc.js +0 -153
  166. package/chunks/_baseFlatten-DPXPOrea.js +0 -7076
  167. package/chunks/app-filter-bar.compiler-j_CVoWTa.js +0 -55
  168. package/chunks/bar.compiler-oqaPzIut.js +0 -370
  169. package/chunks/coloring-C16AUZEi.js +0 -663
  170. package/chunks/data-item-resolution-1lvYB5ln.js +0 -53
  171. package/chunks/event-bus-KiSiCJrC.js +0 -2683
  172. package/chunks/events-WZut5Ow6.js +0 -4
  173. package/chunks/filter.compiler-CuLtc_02.js +0 -60
  174. package/chunks/filtering-Yq4DEa0t.js +0 -953
  175. package/chunks/gauge-target-type-BkKXAqkX.js +0 -4
  176. package/chunks/grouping-type-BX_9Ix5q.js +0 -3
  177. package/chunks/interfaces-VUY4_yVO.js +0 -8742
  178. package/chunks/line-settings-DfYTUyPz.js +0 -4
  179. package/chunks/line.compiler-BpA_6Tc7.js +0 -188
  180. package/chunks/number.compiler-DbkWcG4S.js +0 -44
  181. package/chunks/pie-uv42Eqal.js +0 -10
  182. package/chunks/requirements-DNhuShLS.js +0 -6
  183. package/chunks/shared-CKDL4hx9.js +0 -1171
  184. package/chunks/src-Cum_2NLV.js +0 -12145
  185. package/chunks/src-Dun_jXtz.js +0 -10295
  186. package/chunks/standalone-87YV_m9n.js +0 -687
  187. package/chunks/standalone-BLVAWLNJ.js +0 -385
  188. package/chunks/standalone-BPomtAVs.js +0 -2
  189. package/chunks/standalone-BXyBcUOQ.js +0 -2
  190. package/chunks/standalone-BllF4rDp.js +0 -383
  191. package/chunks/standalone-BmfMt74U.js +0 -726
  192. package/chunks/standalone-BqWyrnZI.js +0 -281
  193. package/chunks/standalone-C85u7U6I.js +0 -340
  194. package/chunks/standalone-CDQnr6qT.js +0 -345
  195. package/chunks/standalone-CZynjFG7.js +0 -12979
  196. package/chunks/standalone-DFPva_ku.js +0 -299
  197. package/chunks/standalone-DQxxNwF8.js +0 -675
  198. package/chunks/standalone-DS9T0FZ-.js +0 -830
  199. package/chunks/standalone-Dx3MLlrO.js +0 -512
  200. package/chunks/standalone-DzixzZAL.js +0 -411
  201. package/chunks/standalone-lBm9hQ-q.js +0 -179
  202. package/chunks/standalone-rJ45Zfl1.js +0 -68
  203. package/chunks/table.compiler-BrXkm4Fz.js +0 -213
  204. package/chunks/toInteger-DVZr-D1j.js +0 -11
  205. package/chunks/treemap-x_zmJoG7.js +0 -23
  206. package/chunks/types-dVVCsDWD.js +0 -4
  207. package/chunks/useFieldName-oqQ3bvnO.js +0 -7
  208. package/chunks/view-CLqWMV7Z.js +0 -156
  209. package/src/definitions/shared/index.d.ts +0 -5
  210. package/src/definitions/shared/lib/registry/descriptor-registry.d.ts +0 -587
  211. package/src/definitions/shared/lib/registry/index.d.ts +0 -3
  212. package/src/definitions/shared/lib/schemas/index.d.ts +0 -9
  213. package/src/definitions/shared/lib/types/index.d.ts +0 -3
  214. package/src/definitions/{shared/lib → model/definitions}/schemas/app-filter-bar.schema.d.ts +0 -0
  215. package/src/definitions/{shared/lib → model/definitions}/schemas/bar.schema.d.ts +0 -0
  216. package/src/definitions/{shared/lib → model/definitions}/schemas/filter.schema.d.ts +0 -0
  217. package/src/definitions/{shared/lib → model/definitions}/schemas/line.schema.d.ts +0 -0
  218. package/src/definitions/{shared/lib → model/definitions}/schemas/number.schema.d.ts +0 -0
  219. package/src/definitions/{shared/lib → model/definitions}/schemas/table.schema.d.ts +4 -4
  220. /package/src/definitions/{shared/lib → model/definitions}/types/descriptor.types.d.ts +0 -0
@@ -10,8 +10,10 @@ The reference and the public per-type descriptors share the same metadata catalo
10
10
  - Use exact, opaque engine `fieldKey` values. Never parse, reconstruct, or replace them with view/name pairs.
11
11
  - Definition-local `ref` values let sorting, Top N, and similar settings refer to data items before internal identities exist.
12
12
  - Raw fields used as measures require `aggregation`. Semantic dimensions, predefined measures, and calculations retain their engine semantics.
13
+ - Omit `format` on a dimension unless it needs a specific format. A date field then shows readable dates; `none` or `inherit` on a date field shows raw timestamp numbers. To choose a date format, use a date format type such as `ddmmmyyyy`.
14
+ - Each static filter in `filterGroup` takes the value keys of its operator: `inList` and `excludedFromList` take a `values` array, `isBetween` and `isNotBetween` take `valueFrom` and `valueTo`, `isNull` and `notNull` take none, and every other operator, such as `contains`, takes one string in `value`.
13
15
  - Unsupported sections and properties are rejected instead of ignored.
14
- - The compiler returns one complete vSpec or structured issues; it never returns partial state.
16
+ - The compiler returns one complete vSpec or structured issues; it never returns partial state. A successful result can also carry `warnings` about settings that are likely to display poorly.
15
17
  - Settings a definition cannot express are applied with `applyOperations` on the compiled vSpec before mounting. See "Finishing A Chart Before Mounting".
16
18
 
17
19
  ## Integrating With AI
@@ -27,7 +29,7 @@ After selecting the type, give the model only:
27
29
 
28
30
  Do not send schemas for every visualization or ask the model to generate a raw vSpec. That would give the model unrelated information and require it to understand internal vSpec properties and generated data-item IDs.
29
31
 
30
- After the model returns a definition, pass it to `compileVisualizationDefinition()`. On success, use the returned vSpec. On failure, give the structured issues back to the model so it can correct the definition and try again.
32
+ After the model returns a definition, pass it to `compileVisualizationDefinition()`. On success, use the returned vSpec. On failure, give the structured issues back to the model so it can correct the definition and try again. When a successful result has `warnings`, the vSpec is complete but is likely to display poorly, so give the warnings back to the model as well.
31
33
 
32
34
  Use `getVisualizationDefinitionDescriptor(type, 1)` to get the descriptor for one selected type. Use `listVisualizationDefinitionDescriptors()` to discover the available visualization types and compare their `supportedFeatures`.
33
35
 
@@ -149,7 +151,7 @@ Categorical comparison chart with sorting, limiting, per-measure axes, labels, a
149
151
  - Every dimension and measure must resolve to an available field with a compatible role.
150
152
  - Set axis per measure to plot it against the primary or the secondary measure axis.
151
153
  - presentation.axes.primaryMeasure.bands shades the plot between two primary measure axis values; start and end are measure values, and the bands replace any on the base vSpec.
152
- - Set range on a measure axis to fix its min, max, or both, for example to give several charts one shared scale; leave both unset and set startsAtZero to keep an auto-fitted axis anchored at zero. Set inverted on a measure axis to reverse its values, for example to put rank 1 at the top.
154
+ - Set range on a measure axis to fix its min, max, or both, for example to give several charts one shared scale. To keep an auto-fitted axis anchored at zero, leave both unset and put startsAtZero inside range, not on the axis itself: "primaryMeasure": { "range": { "startsAtZero": true } }. Set inverted on a measure axis to reverse its values, for example to put rank 1 at the top.
153
155
  - Set scale to log on a measure axis to draw it logarithmically, with gridlines at powers of ten. Zero and negative values are drawn at the floor of a log axis.
154
156
 
155
157
  **Canonical example**
@@ -160,9 +162,6 @@ Categorical comparison chart with sorting, limiting, per-measure axes, labels, a
160
162
  "dimensions": [
161
163
  {
162
164
  "fieldKey": "[Cars].[Manufacturer]",
163
- "format": {
164
- "formatType": "none"
165
- },
166
165
  "ref": "manufacturer",
167
166
  "showNullValues": false
168
167
  }
@@ -256,9 +255,6 @@ Categorical comparison chart with sorting, limiting, per-measure axes, labels, a
256
255
  "dimensions": [
257
256
  {
258
257
  "fieldKey": "[Cars].[Manufacturer]",
259
- "format": {
260
- "formatType": "none"
261
- },
262
258
  "ref": "manufacturer"
263
259
  }
264
260
  ],
@@ -323,7 +319,7 @@ Combined categorical chart supporting multiple measures, per-measure axes, sorti
323
319
  - Sorting refers to definition-local refs, not generated data-item IDs.
324
320
  - Set axis per measure to plot it against the primary or the secondary measure axis. Bar series share one axis: state it on any bar measure, and every bar measure that states one must state the same axis.
325
321
  - presentation.axes.primaryMeasure.bands shades the plot between two primary measure axis values; start and end are measure values, and the bands replace any on the base vSpec.
326
- - Set range on a measure axis to fix its min, max, or both, for example to give several charts one shared scale; leave both unset and set startsAtZero to keep an auto-fitted axis anchored at zero. Set inverted on a measure axis to reverse its values, for example to put rank 1 at the top.
322
+ - Set range on a measure axis to fix its min, max, or both, for example to give several charts one shared scale. To keep an auto-fitted axis anchored at zero, leave both unset and put startsAtZero inside range, not on the axis itself: "primaryMeasure": { "range": { "startsAtZero": true } }. Set inverted on a measure axis to reverse its values, for example to put rank 1 at the top.
327
323
  - Set scale to log on a measure axis to draw it logarithmically, with gridlines at powers of ten. Zero and negative values are drawn at the floor of a log axis.
328
324
 
329
325
  **Canonical example**
@@ -334,9 +330,6 @@ Combined categorical chart supporting multiple measures, per-measure axes, sorti
334
330
  "dimensions": [
335
331
  {
336
332
  "fieldKey": "[Cars].[Manufacturer]",
337
- "format": {
338
- "formatType": "none"
339
- },
340
333
  "ref": "manufacturer"
341
334
  }
342
335
  ],
@@ -440,9 +433,6 @@ Gauge distribution across one or more values, optionally grouped by a dimension.
440
433
  "dimensions": [
441
434
  {
442
435
  "fieldKey": "[Cars].[Manufacturer]",
443
- "format": {
444
- "formatType": "none"
445
- },
446
436
  "ref": "manufacturer"
447
437
  }
448
438
  ],
@@ -506,7 +496,7 @@ Dot comparison using two categorical dimensions and one measure.
506
496
  **Constraints and semantics**
507
497
 
508
498
  - Dimension order is significant and maps to the two dot-chart dimension roles.
509
- - Set range on the primary measure axis to fix its min, max, or both, for example to give several charts one shared scale; leave both unset and set startsAtZero to keep an auto-fitted axis anchored at zero. Set inverted on the primary measure axis to reverse its values.
499
+ - Set range on the primary measure axis to fix its min, max, or both, for example to give several charts one shared scale. To keep an auto-fitted axis anchored at zero, leave both unset and put startsAtZero inside range, not on the axis itself: "primaryMeasure": { "range": { "startsAtZero": true } }. Set inverted on the primary measure axis to reverse its values.
510
500
 
511
501
  **Canonical example**
512
502
 
@@ -516,16 +506,10 @@ Dot comparison using two categorical dimensions and one measure.
516
506
  "dimensions": [
517
507
  {
518
508
  "fieldKey": "[Cars].[Manufacturer]",
519
- "format": {
520
- "formatType": "none"
521
- },
522
509
  "ref": "manufacturer"
523
510
  },
524
511
  {
525
512
  "fieldKey": "[Cars].[Model]",
526
- "format": {
527
- "formatType": "none"
528
- },
529
513
  "ref": "model"
530
514
  }
531
515
  ],
@@ -603,9 +587,6 @@ Gauge values with an optional grouping dimension and optional data target.
603
587
  "dimensions": [
604
588
  {
605
589
  "fieldKey": "[Cars].[Manufacturer]",
606
- "format": {
607
- "formatType": "none"
608
- },
609
590
  "ref": "manufacturer"
610
591
  }
611
592
  ],
@@ -679,16 +660,10 @@ Two-dimensional matrix colored and optionally sized by measures.
679
660
  "dimensions": [
680
661
  {
681
662
  "fieldKey": "[Cars].[Manufacturer]",
682
- "format": {
683
- "formatType": "none"
684
- },
685
663
  "ref": "manufacturer"
686
664
  },
687
665
  {
688
666
  "fieldKey": "[Cars].[Model]",
689
- "format": {
690
- "formatType": "none"
691
- },
692
667
  "ref": "model"
693
668
  }
694
669
  ],
@@ -778,7 +753,7 @@ Distribution of a numeric field into generated bins and counts.
778
753
 
779
754
  - The compiler creates the canonical generated count measure; callers do not provide measures.
780
755
  - presentation.axes.primaryMeasure.bands shades the plot between two primary measure axis values; start and end are measure values, and the bands replace any on the base vSpec.
781
- - Set range on the primary measure axis to fix its min, max, or both, for example to give several charts one shared scale; leave both unset and set startsAtZero to keep an auto-fitted axis anchored at zero. Set inverted on the primary measure axis to reverse its values.
756
+ - Set range on the primary measure axis to fix its min, max, or both, for example to give several charts one shared scale. To keep an auto-fitted axis anchored at zero, leave both unset and put startsAtZero inside range, not on the axis itself: "primaryMeasure": { "range": { "startsAtZero": true } }. Set inverted on the primary measure axis to reverse its values.
782
757
 
783
758
  **Canonical example**
784
759
 
@@ -788,9 +763,6 @@ Distribution of a numeric field into generated bins and counts.
788
763
  "dimensions": [
789
764
  {
790
765
  "fieldKey": "[Cars].[Horsepower]",
791
- "format": {
792
- "formatType": "none"
793
- },
794
766
  "ref": "horsepower"
795
767
  }
796
768
  ]
@@ -848,9 +820,10 @@ Trend chart with sorting, query limiting, dual measure axes, labels, legend, and
848
820
  - Each measure may select the primary or secondary axis using its axis property.
849
821
  - Visible data labels require dataPointShape on every measure.
850
822
  - presentation.axes.primaryMeasure.bands shades the plot between two primary measure axis values; start and end are measure values, and the bands replace any on the base vSpec.
851
- - Set range on a measure axis to fix its min, max, or both, for example to give several charts one shared scale; leave both unset and set startsAtZero to keep an auto-fitted axis anchored at zero. Set inverted on a measure axis to reverse its values, for example to put rank 1 at the top.
823
+ - Set range on a measure axis to fix its min, max, or both, for example to give several charts one shared scale. To keep an auto-fitted axis anchored at zero, leave both unset and put startsAtZero inside range, not on the axis itself: "primaryMeasure": { "range": { "startsAtZero": true } }. Set inverted on a measure axis to reverse its values, for example to put rank 1 at the top.
852
824
  - Set scale to log on a measure axis to draw it logarithmically, with gridlines at powers of ten. Zero and negative values are drawn at the floor of a log axis.
853
825
  - Value colors in presentation.coloring require at least two dimensions; measure color rules are not supported.
826
+ - For a trend over time, use a date field as the dimension with temporalGrouping, such as month, and sort by its ref in ascending order. Omit its format to show readable dates.
854
827
 
855
828
  **Canonical example**
856
829
 
@@ -859,11 +832,12 @@ Trend chart with sorting, query limiting, dual measure axes, labels, legend, and
859
832
  "data": {
860
833
  "dimensions": [
861
834
  {
862
- "fieldKey": "[Cars].[Manufacturer]",
863
- "format": {
864
- "formatType": "none"
865
- },
866
- "ref": "manufacturer"
835
+ "fieldKey": "[Cars].[Latest Launch]",
836
+ "ref": "launchMonth",
837
+ "temporalGrouping": {
838
+ "dateLevel": "month",
839
+ "mode": "level"
840
+ }
867
841
  }
868
842
  ],
869
843
  "measures": [
@@ -908,7 +882,7 @@ Trend chart with sorting, query limiting, dual measure axes, labels, legend, and
908
882
  "axes": {
909
883
  "dimension": {
910
884
  "labelsVisible": true,
911
- "title": "Manufacturer",
885
+ "title": "Launch month",
912
886
  "titleVisible": true
913
887
  },
914
888
  "primaryMeasure": {
@@ -935,8 +909,8 @@ Trend chart with sorting, query limiting, dual measure axes, labels, legend, and
935
909
  },
936
910
  "sorting": [
937
911
  {
938
- "by": "sales",
939
- "direction": "desc"
912
+ "by": "launchMonth",
913
+ "direction": "asc"
940
914
  }
941
915
  ],
942
916
  "type": "line",
@@ -954,9 +928,6 @@ Trend chart with sorting, query limiting, dual measure axes, labels, legend, and
954
928
  "dimensions": [
955
929
  {
956
930
  "fieldKey": "[Cars].[Manufacturer]",
957
- "format": {
958
- "formatType": "none"
959
- },
960
931
  "ref": "manufacturer"
961
932
  }
962
933
  ],
@@ -998,16 +969,10 @@ Trend chart with sorting, query limiting, dual measure axes, labels, legend, and
998
969
  "dimensions": [
999
970
  {
1000
971
  "fieldKey": "[Cars].[Manufacturer]",
1001
- "format": {
1002
- "formatType": "none"
1003
- },
1004
972
  "ref": "manufacturer"
1005
973
  },
1006
974
  {
1007
975
  "fieldKey": "[Cars].[Model]",
1008
- "format": {
1009
- "formatType": "none"
1010
- },
1011
976
  "ref": "model"
1012
977
  }
1013
978
  ],
@@ -1067,9 +1032,6 @@ Radial comparison chart for one or more measures with optional categorical dimen
1067
1032
  "dimensions": [
1068
1033
  {
1069
1034
  "fieldKey": "[Cars].[Manufacturer]",
1070
- "format": {
1071
- "formatType": "none"
1072
- },
1073
1035
  "ref": "manufacturer"
1074
1036
  }
1075
1037
  ],
@@ -1132,9 +1094,6 @@ Part-to-whole chart with optional secondary radial measure.
1132
1094
  "dimensions": [
1133
1095
  {
1134
1096
  "fieldKey": "[Cars].[Manufacturer]",
1135
- "format": {
1136
- "formatType": "none"
1137
- },
1138
1097
  "ref": "manufacturer"
1139
1098
  }
1140
1099
  ],
@@ -1191,9 +1150,6 @@ Part-to-whole chart with optional secondary radial measure.
1191
1150
  "dimensions": [
1192
1151
  {
1193
1152
  "fieldKey": "[Cars].[Manufacturer]",
1194
- "format": {
1195
- "formatType": "none"
1196
- },
1197
1153
  "ref": "manufacturer"
1198
1154
  }
1199
1155
  ],
@@ -1258,16 +1214,10 @@ Hierarchical tree built from dimensions, measures, or both.
1258
1214
  "dimensions": [
1259
1215
  {
1260
1216
  "fieldKey": "[Cars].[Manufacturer]",
1261
- "format": {
1262
- "formatType": "none"
1263
- },
1264
1217
  "ref": "manufacturer"
1265
1218
  },
1266
1219
  {
1267
1220
  "fieldKey": "[Cars].[Model]",
1268
- "format": {
1269
- "formatType": "none"
1270
- },
1271
1221
  "ref": "model"
1272
1222
  }
1273
1223
  ],
@@ -1340,16 +1290,10 @@ Hierarchical area chart using ordered dimensions and one size measure.
1340
1290
  "dimensions": [
1341
1291
  {
1342
1292
  "fieldKey": "[Cars].[Manufacturer]",
1343
- "format": {
1344
- "formatType": "none"
1345
- },
1346
1293
  "ref": "manufacturer"
1347
1294
  },
1348
1295
  {
1349
1296
  "fieldKey": "[Cars].[Model]",
1350
- "format": {
1351
- "formatType": "none"
1352
- },
1353
1297
  "ref": "model"
1354
1298
  }
1355
1299
  ],
@@ -1413,16 +1357,10 @@ Flow chart across an ordered sequence of categorical dimensions.
1413
1357
  "dimensions": [
1414
1358
  {
1415
1359
  "fieldKey": "[Cars].[Manufacturer]",
1416
- "format": {
1417
- "formatType": "none"
1418
- },
1419
1360
  "ref": "manufacturer"
1420
1361
  },
1421
1362
  {
1422
1363
  "fieldKey": "[Cars].[Model]",
1423
- "format": {
1424
- "formatType": "none"
1425
- },
1426
1364
  "ref": "model"
1427
1365
  }
1428
1366
  ],
@@ -1463,16 +1401,10 @@ Flow chart across an ordered sequence of categorical dimensions.
1463
1401
  "dimensions": [
1464
1402
  {
1465
1403
  "fieldKey": "[Cars].[Manufacturer]",
1466
- "format": {
1467
- "formatType": "none"
1468
- },
1469
1404
  "ref": "manufacturer"
1470
1405
  },
1471
1406
  {
1472
1407
  "fieldKey": "[Cars].[Model]",
1473
- "format": {
1474
- "formatType": "none"
1475
- },
1476
1408
  "ref": "model"
1477
1409
  }
1478
1410
  ],
@@ -1523,7 +1455,7 @@ Relationship chart using horizontal and vertical measures with optional size and
1523
1455
  - The optional second dimension receives the image role.
1524
1456
  - Roles come from item order only; a ref is a label and does not select a role.
1525
1457
  - With a size measure, points scale between the setPointSize and setMaxPointSize operation values.
1526
- - Set range on a measure axis to fix its min, max, or both, for example to give several charts one shared scale; leave both unset and set startsAtZero to keep an auto-fitted axis anchored at zero. Set inverted on a measure axis to reverse its values, for example to put rank 1 at the top.
1458
+ - Set range on a measure axis to fix its min, max, or both, for example to give several charts one shared scale. To keep an auto-fitted axis anchored at zero, leave both unset and put startsAtZero inside range, not on the axis itself: "primaryMeasure": { "range": { "startsAtZero": true } }. Set inverted on a measure axis to reverse its values, for example to put rank 1 at the top.
1527
1459
 
1528
1460
  **Canonical example**
1529
1461
 
@@ -1533,9 +1465,6 @@ Relationship chart using horizontal and vertical measures with optional size and
1533
1465
  "dimensions": [
1534
1466
  {
1535
1467
  "fieldKey": "[Cars].[Manufacturer]",
1536
- "format": {
1537
- "formatType": "none"
1538
- },
1539
1468
  "ref": "manufacturer"
1540
1469
  }
1541
1470
  ],
@@ -1634,18 +1563,20 @@ Normal, expandable, or pivot tabular output with formatting, filtering, sorting,
1634
1563
  "columns": [
1635
1564
  {
1636
1565
  "fieldKey": "[Cars].[Manufacturer]",
1637
- "format": {
1638
- "formatType": "none"
1639
- },
1640
1566
  "ref": "manufacturer",
1641
1567
  "role": "dimension"
1642
1568
  },
1643
1569
  {
1644
1570
  "fieldKey": "[Cars].[Model]",
1571
+ "ref": "model",
1572
+ "role": "dimension"
1573
+ },
1574
+ {
1575
+ "fieldKey": "[Cars].[Latest Launch]",
1576
+ "ref": "latestLaunch",
1645
1577
  "format": {
1646
- "formatType": "none"
1578
+ "formatType": "ddmmmyyyy"
1647
1579
  },
1648
- "ref": "model",
1649
1580
  "role": "dimension"
1650
1581
  },
1651
1582
  {
@@ -1746,16 +1677,10 @@ Normal, expandable, or pivot tabular output with formatting, filtering, sorting,
1746
1677
  "dimensions": [
1747
1678
  {
1748
1679
  "fieldKey": "[Cars].[Manufacturer]",
1749
- "format": {
1750
- "formatType": "none"
1751
- },
1752
1680
  "ref": "manufacturer"
1753
1681
  },
1754
1682
  {
1755
1683
  "fieldKey": "[Cars].[Model]",
1756
- "format": {
1757
- "formatType": "none"
1758
- },
1759
1684
  "ref": "model"
1760
1685
  }
1761
1686
  ],
@@ -1804,9 +1729,6 @@ Normal, expandable, or pivot tabular output with formatting, filtering, sorting,
1804
1729
  "columnDimensions": [
1805
1730
  {
1806
1731
  "fieldKey": "[Cars].[Model]",
1807
- "format": {
1808
- "formatType": "none"
1809
- },
1810
1732
  "ref": "model"
1811
1733
  }
1812
1734
  ],
@@ -1824,9 +1746,6 @@ Normal, expandable, or pivot tabular output with formatting, filtering, sorting,
1824
1746
  "rowDimensions": [
1825
1747
  {
1826
1748
  "fieldKey": "[Cars].[Manufacturer]",
1827
- "format": {
1828
- "formatType": "none"
1829
- },
1830
1749
  "ref": "manufacturer"
1831
1750
  }
1832
1751
  ],
@@ -1871,7 +1790,7 @@ Sequential contribution chart composed from one or more measures.
1871
1790
  **Constraints and semantics**
1872
1791
 
1873
1792
  - Dimensions are not supported. Measure order defines the waterfall sequence.
1874
- - Set range on the primary measure axis to fix its min, max, or both, for example to give several charts one shared scale; leave both unset and set startsAtZero to keep an auto-fitted axis anchored at zero. Set inverted on the primary measure axis to reverse its values.
1793
+ - Set range on the primary measure axis to fix its min, max, or both, for example to give several charts one shared scale. To keep an auto-fitted axis anchored at zero, leave both unset and put startsAtZero inside range, not on the axis itself: "primaryMeasure": { "range": { "startsAtZero": true } }. Set inverted on the primary measure axis to reverse its values.
1875
1794
  - presentation.axes.primaryMeasure.bands shades the plot between two primary measure axis values; start and end are measure values, and the bands replace any on the base vSpec.
1876
1795
 
1877
1796
  **Canonical example**
@@ -1964,9 +1883,6 @@ Weighted word display using one label dimension and one measure.
1964
1883
  "dimensions": [
1965
1884
  {
1966
1885
  "fieldKey": "[Cars].[Manufacturer]",
1967
- "format": {
1968
- "formatType": "none"
1969
- },
1970
1886
  "ref": "manufacturer"
1971
1887
  }
1972
1888
  ],
@@ -2012,6 +1928,7 @@ Date selection control with single/range modes, labels, quick select, and respon
2012
1928
  **Constraints and semantics**
2013
1929
 
2014
1930
  - The selected field must be date- or timestamp-compatible.
1931
+ - A `range` picker always shows its calendar, so `pickerState: "collapsed"` is refused on it. Use `inputRange` for a compact picker.
2015
1932
 
2016
1933
  **Canonical example**
2017
1934
 
@@ -2028,7 +1945,6 @@ Date selection control with single/range modes, labels, quick select, and respon
2028
1945
  "pickerState": "expanded",
2029
1946
  "pickerType": "range",
2030
1947
  "quickSelect": true,
2031
- "responsive": true,
2032
1948
  "startDateLabel": "From",
2033
1949
  "timePickerVisibility": "never",
2034
1950
  "weekStart": "1"
@@ -2067,7 +1983,6 @@ Interactive field filter with list/dropdown presentation and search/quick-select
2067
1983
  "presentation": {
2068
1984
  "mode": "listbox",
2069
1985
  "quickSelect": true,
2070
- "responsive": true,
2071
1986
  "searchable": true,
2072
1987
  "showProgressBar": false
2073
1988
  },
@@ -2155,6 +2070,8 @@ Single aggregated or semantic value with value formatting and static filters.
2155
2070
  **Constraints and semantics**
2156
2071
 
2157
2072
  - A raw field measure requires aggregation; semantic measures and calculations omit it.
2073
+ - Each static filter takes the value keys of its operator: inList and excludedFromList take a values array, isBetween and isNotBetween take valueFrom and valueTo, isNull and notNull take none, and every other operator, such as contains, takes one string in value.
2074
+ - A measure with no value draws nothing rather than 0, and thresholds and comparisons do not apply to it.
2158
2075
 
2159
2076
  **Canonical example**
2160
2077
 
@@ -2186,6 +2103,43 @@ Single aggregated or semantic value with value formatting and static filters.
2186
2103
  }
2187
2104
  ```
2188
2105
 
2106
+ **Additional scenarios**
2107
+
2108
+ ### Value filtered by single-value conditions
2109
+
2110
+ ```json
2111
+ {
2112
+ "data": {
2113
+ "measure": {
2114
+ "aggregation": "SUM",
2115
+ "fieldKey": "[Cars].[Sales In Thousands]",
2116
+ "format": {
2117
+ "formatType": "number2Decimal",
2118
+ "negativeType": "parenthesis"
2119
+ },
2120
+ "ref": "sales"
2121
+ }
2122
+ },
2123
+ "filterGroup": {
2124
+ "filters": [
2125
+ {
2126
+ "fieldKey": "[Cars].[Model]",
2127
+ "operator": "contains",
2128
+ "value": "Sport"
2129
+ },
2130
+ {
2131
+ "fieldKey": "[Cars].[Horsepower]",
2132
+ "operator": "greaterThanOrEqualTo",
2133
+ "value": "200"
2134
+ }
2135
+ ],
2136
+ "operator": "and"
2137
+ },
2138
+ "type": "number",
2139
+ "version": 1
2140
+ }
2141
+ ```
2142
+
2189
2143
  ## `shape`: Shape
2190
2144
 
2191
2145
  Decorative shape with fill, stroke, sizing, rotation, and border controls.
@@ -0,0 +1,110 @@
1
+ import { o as e } from "./rolldown-runtime-DleVn1XH.js";
2
+ import { Hi as t } from "./visualization-filters-Cc4KU-l-.js";
3
+ import { An as n, Ei as r, Ti as i, W as a, ri as o } from "./utils-vdmi_2PK.js";
4
+ import { i as s, u as c } from "./responsive.styles-DSiOGD7u.js";
5
+ var l = /* @__PURE__ */ e(r()), u = o(), d = a({
6
+ container: {
7
+ display: "flex",
8
+ fontSize: "14px"
9
+ },
10
+ button: ({ responsive: e, withoutWrapper: t }) => ({
11
+ ...i.normal14,
12
+ display: "flex",
13
+ flexDirection: "row",
14
+ justifyContent: "center",
15
+ alignItems: "center",
16
+ boxSizing: "border-box",
17
+ gap: "4px",
18
+ background: "var(--bgColor)",
19
+ border: "1px solid var(--borderColor)",
20
+ color: "var(--fontColor)",
21
+ padding: "var(--padding, 0px 8px)",
22
+ borderRadius: 4,
23
+ cursor: "pointer",
24
+ "&:not(:disabled, .disabled):hover": {
25
+ background: "var(--bgColorHover)",
26
+ border: "1px solid var(--borderColorHover)",
27
+ boxShadow: "0px 2px 4px rgba(0, 0, 0, 0.1)"
28
+ },
29
+ "&:disabled, &.disabled": {
30
+ color: "var(--fontColorDisabled)",
31
+ background: "var(--bgColorDisabled)",
32
+ border: "1px solid var(--borderColorDisabled)"
33
+ },
34
+ "& > svg": { display: "block" },
35
+ ...!t || e ? c(e) : {}
36
+ }),
37
+ primary: {
38
+ "--bgColor": t.mainBrightPink,
39
+ "--bgColorHover": t.hover.mainBrightPink,
40
+ "--bgColorDisabled": t.disabled.mainBrightPink,
41
+ "--borderColor": "var(--bgColor)",
42
+ "--borderColorHover": "var(--bgColorHover)",
43
+ "--borderColorDisabled": "var(--bgColorDisabled)",
44
+ "--fontColor": t.white,
45
+ "--fontColorDisabled": "var(--fontColor)"
46
+ },
47
+ secondary: {
48
+ "--bgColor": t.mainDarkNavy,
49
+ "--bgColorHover": t.hover.mainDarkNavy,
50
+ "--bgColorDisabled": t.disabled.mainDarkNavy,
51
+ "--borderColor": "var(--bgColor)",
52
+ "--borderColorHover": "var(--bgColorHover)",
53
+ "--borderColorDisabled": "var(--bgColorDisabled)",
54
+ "--fontColor": t.white,
55
+ "--fontColorDisabled": "var(--fontColor)"
56
+ },
57
+ tertiary: {
58
+ "--bgColor": t.white,
59
+ "--bgColorHover": "var(--bgColor)",
60
+ "--bgColorDisabled": t.grey5,
61
+ "--borderColor": t.grey3,
62
+ "--borderColorHover": "var(--borderColor)",
63
+ "--borderColorDisabled": "var(--borderColor)",
64
+ "--fontColor": t.mainDarkNavy,
65
+ "--fontColorDisabled": t.grey3
66
+ },
67
+ transparent: {
68
+ "--bgColor": "transparent",
69
+ "--bgColorHover": "var(--bgColor)",
70
+ "--bgColorDisabled": "transparent",
71
+ "--borderColor": "transparent",
72
+ "--borderColorHover": "var(--borderColor)",
73
+ "--borderColorDisabled": "var(--borderColor)",
74
+ "--fontColor": t.mainDarkNavy,
75
+ "--fontColorDisabled": t.grey3,
76
+ "&:not(:disabled):hover": { boxShadow: "0px 0px" }
77
+ },
78
+ xsmall: ({ responsive: e }) => ({ ...s(24, e) }),
79
+ small: ({ responsive: e }) => ({ ...s(32, e) }),
80
+ medium: ({ responsive: e }) => ({ ...s(40, e) }),
81
+ large: ({ responsive: e }) => ({ ...s(48, e) }),
82
+ fullWidth: { width: "100%" },
83
+ showFullLabel: { flexShrink: 0 }
84
+ }), f = (0, l.forwardRef)(function({ children: e, className: t, color: r = "tertiary", size: i = "xsmall", fullWidth: a, responsive: o, showFullLabel: s, withoutWrapper: c = !1, ...l }, f) {
85
+ let p = d({
86
+ responsive: o,
87
+ withoutWrapper: c
88
+ }), m = /* @__PURE__ */ (0, u.jsx)("button", {
89
+ ...l,
90
+ className: n({
91
+ [t]: !!t,
92
+ [p.button]: !0,
93
+ [p[r]]: !0,
94
+ [p[i]]: !0,
95
+ [p.fullWidth]: a,
96
+ [p.showFullLabel]: c && s
97
+ }),
98
+ ref: f,
99
+ children: e
100
+ });
101
+ return c ? m : /* @__PURE__ */ (0, u.jsx)("div", {
102
+ className: n({
103
+ [p.container]: !0,
104
+ [p.fullWidth]: a,
105
+ [p.showFullLabel]: s
106
+ }),
107
+ children: m
108
+ });
109
+ });
110
+ export { f as t };