@altertable/data-app 0.65.0 → 0.67.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 (202) hide show
  1. package/AGENTS.md +38 -1
  2. package/CONTRIBUTING.md +54 -14
  3. package/README.md +1 -1
  4. package/dist/chunks/index-23dktynd.js +80 -0
  5. package/dist/chunks/index-23dktynd.js.map +10 -0
  6. package/dist/chunks/index-8qfxv0h5.js +14160 -0
  7. package/dist/chunks/index-8qfxv0h5.js.map +108 -0
  8. package/dist/chunks/index-ag0cgnvq.js +639 -0
  9. package/dist/chunks/index-ag0cgnvq.js.map +13 -0
  10. package/dist/chunks/index-dq7b35fn.js +307 -0
  11. package/dist/chunks/index-dq7b35fn.js.map +13 -0
  12. package/dist/chunks/{contract-a061yj6r.js → index-ev2b5aaf.js} +41 -72
  13. package/dist/chunks/index-ev2b5aaf.js.map +12 -0
  14. package/dist/chunks/{contract-awa2d5b1.js → index-f5cnbrjz.js} +19 -2
  15. package/dist/chunks/{contract-awa2d5b1.js.map → index-f5cnbrjz.js.map} +4 -3
  16. package/dist/chunks/{contract-sm7j7k95.js → index-ktmvs916.js} +9 -150
  17. package/dist/chunks/index-ktmvs916.js.map +13 -0
  18. package/dist/chunks/{contract-txjy0en2.js → index-m6n8ctfc.js} +64 -72
  19. package/dist/chunks/index-m6n8ctfc.js.map +10 -0
  20. package/dist/chunks/index-mt93ff2b.js +28 -0
  21. package/dist/chunks/index-mt93ff2b.js.map +10 -0
  22. package/dist/chunks/{contract-tf8c3qpv.js → index-qd5xgx6y.js} +46 -5
  23. package/dist/chunks/index-qd5xgx6y.js.map +13 -0
  24. package/dist/chunks/index-x69p7cv7.js +149 -0
  25. package/dist/chunks/index-x69p7cv7.js.map +10 -0
  26. package/dist/client/index.js +12 -7
  27. package/dist/client/index.js.map +1 -1
  28. package/dist/core/appearance.js +1 -1
  29. package/dist/core/config.js +7 -3
  30. package/dist/core/config.js.map +1 -1
  31. package/dist/core/contract.js +24 -6
  32. package/dist/core/contract.js.map +1 -1
  33. package/dist/core/format.js +1 -1
  34. package/dist/embed/index.js +16 -12
  35. package/dist/embed/index.js.map +4 -4
  36. package/dist/index.js +12 -0
  37. package/dist/index.js.map +9 -0
  38. package/dist/local.js +20 -30
  39. package/dist/local.js.map +7 -8
  40. package/dist/react/embed/index.js +1 -1
  41. package/dist/react/embed/index.js.map +2 -2
  42. package/dist/react/index.js +2567 -11542
  43. package/dist/react/index.js.map +16 -91
  44. package/dist/react/ui/index.js +2272 -0
  45. package/dist/react/ui/index.js.map +28 -0
  46. package/dist/server.js +13 -26
  47. package/dist/server.js.map +6 -7
  48. package/dist/types/client/annotations.d.ts +27 -0
  49. package/dist/types/client/data-client.d.ts +1 -2
  50. package/dist/types/client/iframe.d.ts +4 -2
  51. package/dist/types/client/index.d.ts +1 -0
  52. package/dist/types/core/annotations.d.ts +94 -0
  53. package/dist/types/core/appearance.d.ts +2 -2
  54. package/dist/types/core/config.d.ts +48 -4
  55. package/dist/types/core/contract.d.ts +21 -11
  56. package/dist/types/core/dimension.d.ts +6 -4
  57. package/dist/types/core/filters.d.ts +44 -0
  58. package/dist/types/core/messages.d.ts +2 -0
  59. package/dist/types/core/operation-types.d.ts +5 -2
  60. package/dist/types/core/operation.d.ts +3 -4
  61. package/dist/types/core/presentation.d.ts +2 -0
  62. package/dist/types/core/queries.d.ts +16 -0
  63. package/dist/types/core/uuid.d.ts +2 -0
  64. package/dist/types/core/variables.d.ts +34 -18
  65. package/dist/types/embed/runtime-html.d.ts +2 -0
  66. package/dist/types/embed/source.d.ts +2 -1
  67. package/dist/types/index.d.ts +3 -0
  68. package/dist/types/react/annotations/AnnotationBar.d.ts +30 -0
  69. package/dist/types/react/annotations/AnnotationControls.d.ts +10 -0
  70. package/dist/types/react/annotations/AnnotationEditor.d.ts +16 -0
  71. package/dist/types/react/annotations/AnnotationMarkers.d.ts +19 -0
  72. package/dist/types/react/annotations/AnnotationSelectionLayer.d.ts +12 -0
  73. package/dist/types/react/annotations/AnnotationTarget.d.ts +9 -0
  74. package/dist/types/react/annotations/AnnotationTooltip.d.ts +9 -0
  75. package/dist/types/react/annotations/AnnotationTrigger.d.ts +10 -0
  76. package/dist/types/react/annotations/annotation-editor-state.d.ts +56 -0
  77. package/dist/types/react/annotations/annotation-screenshot.d.ts +4 -0
  78. package/dist/types/react/annotations/annotation-targets.d.ts +33 -0
  79. package/dist/types/react/annotations/getAnnotationProps.d.ts +15 -0
  80. package/dist/types/react/annotations/styles.d.ts +3 -0
  81. package/dist/types/react/annotations/useAnnotationGeometry.d.ts +22 -0
  82. package/dist/types/react/annotations/useDataAppAnnotations.d.ts +22 -0
  83. package/dist/types/react/app-context.d.ts +3 -0
  84. package/dist/types/react/bindings.d.ts +110 -0
  85. package/dist/types/react/content.d.ts +24 -11
  86. package/dist/types/react/hooks.d.ts +29 -787
  87. package/dist/types/react/index.d.ts +31 -106
  88. package/dist/types/react/mount.d.ts +6 -4
  89. package/dist/types/react/source-owner.d.ts +2 -0
  90. package/dist/types/react/style-contract.d.ts +80 -0
  91. package/dist/types/react/style-validation.d.ts +2 -0
  92. package/dist/types/react/ui/AboutData.d.ts +9 -1
  93. package/dist/types/react/ui/AppHeader.d.ts +1 -2
  94. package/dist/types/react/ui/AppLayout.d.ts +3 -9
  95. package/dist/types/react/ui/AppToolbar.d.ts +5 -8
  96. package/dist/types/react/ui/AreaChart.d.ts +7 -0
  97. package/dist/types/react/ui/BarChart.d.ts +6 -0
  98. package/dist/types/react/ui/Button.d.ts +3 -3
  99. package/dist/types/react/ui/ChartLegend.d.ts +31 -0
  100. package/dist/types/react/ui/Checkbox.d.ts +15 -4
  101. package/dist/types/react/ui/CheckboxGroup.d.ts +7 -0
  102. package/dist/types/react/ui/{Combobox.d.ts → ChoicePicker.d.ts} +10 -15
  103. package/dist/types/react/ui/{ComparisonVisual.d.ts → Comparison.d.ts} +3 -3
  104. package/dist/types/react/ui/ComposedChart.d.ts +41 -0
  105. package/dist/types/react/ui/ComposedChartLegend.d.ts +8 -0
  106. package/dist/types/react/ui/ContentSkeleton.d.ts +2 -0
  107. package/dist/types/react/ui/DataApp.d.ts +17 -58
  108. package/dist/types/react/ui/DataAppFrame.d.ts +41 -0
  109. package/dist/types/react/ui/DataBoundary.d.ts +4 -5
  110. package/dist/types/react/ui/DataSection.d.ts +6 -18
  111. package/dist/types/react/ui/DataSectionBoundary.d.ts +30 -0
  112. package/dist/types/react/ui/DataValue.d.ts +9 -0
  113. package/dist/types/react/ui/DataWidget.d.ts +2 -1
  114. package/dist/types/react/ui/DateTimeTooltip.d.ts +1 -1
  115. package/dist/types/react/ui/DimensionPicker.d.ts +1 -1
  116. package/dist/types/react/ui/ExportControl.d.ts +1 -1
  117. package/dist/types/react/ui/FilterActions.d.ts +10 -0
  118. package/dist/types/react/ui/FilterBar.d.ts +3 -0
  119. package/dist/types/react/ui/GettingStarted.d.ts +2 -4
  120. package/dist/types/react/ui/HelpPopover.d.ts +3 -4
  121. package/dist/types/react/ui/InspectionContext.d.ts +2 -0
  122. package/dist/types/react/ui/InspectionProvider.d.ts +29 -0
  123. package/dist/types/react/ui/LineChart.d.ts +7 -0
  124. package/dist/types/react/ui/Menu.d.ts +12 -0
  125. package/dist/types/react/ui/MetricWidget.d.ts +4 -3
  126. package/dist/types/react/ui/NumberField.d.ts +27 -0
  127. package/dist/types/react/ui/NumberFilterPicker.d.ts +9 -0
  128. package/dist/types/react/ui/PieChart.d.ts +11 -0
  129. package/dist/types/react/ui/PresentStory.d.ts +2 -5
  130. package/dist/types/react/ui/RadioGroup.d.ts +18 -0
  131. package/dist/types/react/ui/RefreshControl.d.ts +1 -2
  132. package/dist/types/react/ui/ScatterChart.d.ts +17 -0
  133. package/dist/types/react/ui/SearchField.d.ts +1 -2
  134. package/dist/types/react/ui/SearchInput.d.ts +3 -1
  135. package/dist/types/react/ui/Select.d.ts +14 -0
  136. package/dist/types/react/ui/SelectionMark.d.ts +2 -1
  137. package/dist/types/react/ui/Sheet.d.ts +2 -1
  138. package/dist/types/react/ui/Skeleton.d.ts +5 -2
  139. package/dist/types/react/ui/StaticDataApp.d.ts +4 -0
  140. package/dist/types/react/ui/TableWidget.d.ts +19 -16
  141. package/dist/types/react/ui/Tabs.d.ts +6 -2
  142. package/dist/types/react/ui/TextWidget.d.ts +2 -1
  143. package/dist/types/react/ui/Tooltip.d.ts +4 -3
  144. package/dist/types/react/ui/TooltipSurface.d.ts +3 -0
  145. package/dist/types/react/ui/TrendChart.d.ts +5 -0
  146. package/dist/types/react/ui/UpdatedAt.d.ts +1 -1
  147. package/dist/types/react/ui/VisualizationWidget.d.ts +12 -13
  148. package/dist/types/react/ui/WidgetViewTabs.d.ts +1 -1
  149. package/dist/types/react/ui/chart-data.d.ts +25 -0
  150. package/dist/types/react/ui/chart-primitives.d.ts +20 -0
  151. package/dist/types/react/ui/data-context.d.ts +18 -7
  152. package/dist/types/react/ui/icons.d.ts +2 -0
  153. package/dist/types/react/ui/index.d.ts +98 -0
  154. package/dist/types/react/ui/keyboard.d.ts +6 -0
  155. package/dist/types/react/ui/metric.d.ts +1 -1
  156. package/dist/types/react/ui/presentation.d.ts +5 -1
  157. package/dist/types/react/ui/shortcuts.d.ts +14 -1
  158. package/dist/types/react/ui/useAppAppearance.d.ts +1 -1
  159. package/dist/types/react/ui/variables.d.ts +4 -2
  160. package/dist/types/react/view-controls.d.ts +3 -1
  161. package/dist/types/react/view-runtime.d.ts +29 -0
  162. package/dist/types/react/view.d.ts +21 -4
  163. package/dist/types/react/widgets.d.ts +79 -0
  164. package/dist/types/server/handler.d.ts +4 -4
  165. package/dist/worker.js +20 -737
  166. package/docs/app-authoring.md +72 -50
  167. package/docs/client.md +8 -8
  168. package/docs/contract.md +42 -20
  169. package/docs/data-context.md +91 -0
  170. package/docs/embed.md +10 -2
  171. package/docs/formatting-and-appearance.md +68 -0
  172. package/docs/hosted-apps.md +9 -15
  173. package/docs/layout.md +5 -3
  174. package/docs/react-embed.md +5 -4
  175. package/docs/react.md +22 -317
  176. package/docs/server-bun.md +1 -1
  177. package/docs/server.md +4 -4
  178. package/docs/stories-and-export.md +52 -0
  179. package/docs/styling.md +62 -0
  180. package/docs/ui-quality.md +20 -0
  181. package/docs/ui.md +196 -0
  182. package/docs/variables.md +171 -0
  183. package/docs/views.md +123 -0
  184. package/docs/widgets.md +145 -0
  185. package/examples/starter-data-app/index.tsx +115 -86
  186. package/package.json +25 -12
  187. package/dist/chunks/contract-a061yj6r.js.map +0 -12
  188. package/dist/chunks/contract-g6hky7x6.js +0 -282
  189. package/dist/chunks/contract-g6hky7x6.js.map +0 -12
  190. package/dist/chunks/contract-sm7j7k95.js.map +0 -14
  191. package/dist/chunks/contract-tf8c3qpv.js.map +0 -11
  192. package/dist/chunks/contract-txjy0en2.js.map +0 -10
  193. package/dist/chunks/contract-wz59z8pq.js +0 -8
  194. package/dist/chunks/contract-wz59z8pq.js.map +0 -10
  195. package/dist/chunks/contract-yxbjea23.js +0 -328
  196. package/dist/chunks/contract-yxbjea23.js.map +0 -12
  197. package/dist/types/react/ui/RefreshRegion.d.ts +0 -9
  198. package/dist/types/react/ui/SelectableBarChart.d.ts +0 -15
  199. package/docs/releasing.md +0 -79
  200. /package/dist/chunks/{contract-mev09s5v.js → index-mev09s5v.js} +0 -0
  201. /package/dist/chunks/{contract-mev09s5v.js.map → index-mev09s5v.js.map} +0 -0
  202. /package/dist/types/react/ui/{comparison.d.ts → metric-comparison.d.ts} +0 -0
@@ -1,34 +1,13 @@
1
- /**
2
- * React bindings and UI; inject styles explicitly in the browser entry.
3
- * @module @altertable/data-app/react
4
- * @see https://github.com/altertable-ai/data-app/blob/main/docs/react.md
5
- */
1
+ /** Declared views, bound widgets, and layouts for data-app authoring. */
2
+ export type { DatasetColumn, DatasetDeclaration as DatasetDefinition, } from './bindings.js';
6
3
  export { injectDataAppStyles } from './styles.js';
7
- export { injectDataAppShellStyles } from './shellStyles.js';
8
4
  export type { DataAppStylesOptions } from './styles.js';
9
- export { mountDataApp, DataAppProvider } from './mount.js';
5
+ export type { DataAppStyle, DataAppStyleToken, DataAppStyleHooks, } from './style-contract.js';
6
+ export { mountDataApp } from './mount.js';
10
7
  export { createDataHooks } from './hooks.js';
11
- export { defineDataContent } from './content.js';
12
- export type { DataContentState } from './content.js';
13
- export type { DataViewDefinition, ResolvedVariables, ViewBindings, } from './view.js';
14
- export type { CsvCell, CsvTable, CsvExport } from './ui/csv-export.js';
8
+ export type { CsvCell } from './ui/csv-export.js';
15
9
  export { DataApp } from './ui/DataApp.js';
16
- export type { DataAppProps, DataAppRequest } from './ui/DataApp.js';
17
- export { GettingStarted } from './ui/GettingStarted.js';
18
- export { AppLayout } from './ui/AppLayout.js';
19
- export type { AppLayoutProps } from './ui/AppLayout.js';
20
- export { AppHeader } from './ui/AppHeader.js';
21
- export type { AppHeaderProps } from './ui/AppHeader.js';
22
- export { AppScope } from './ui/AppScope.js';
23
- export type { AppScopeProps } from './ui/AppScope.js';
24
- export { AppToolbar } from './ui/AppToolbar.js';
25
- export type { AppToolbarProps } from './ui/AppToolbar.js';
26
- export { VariableBar } from './ui/VariableBar.js';
27
- export type { VariableBarProps } from './ui/VariableBar.js';
28
- export { AppFooter } from './ui/AppFooter.js';
29
- export type { AppFooterProps } from './ui/AppFooter.js';
30
- export { ThemeSelector, ThemeToggle } from './ui/ThemeSelector.js';
31
- export type { ThemeSelectorProps } from './ui/ThemeSelector.js';
10
+ export type { DataAppProps } from './ui/DataApp.js';
32
11
  export { Stack } from './ui/Stack.js';
33
12
  export type { StackProps } from './ui/Stack.js';
34
13
  export { Grid } from './ui/Grid.js';
@@ -36,110 +15,56 @@ export type { GridProps } from './ui/Grid.js';
36
15
  export { GridItem } from './ui/GridItem.js';
37
16
  export type { GridItemProps } from './ui/GridItem.js';
38
17
  export type { WidgetEvidence } from './ui/WidgetEvidence.js';
39
- export { DataWidget } from './ui/DataWidget.js';
40
- export type { WidgetStatus } from './ui/RequestHint.js';
41
- export type { DataWidgetProps } from './ui/DataWidget.js';
42
18
  export { TextContent } from './ui/TextContent.js';
43
19
  export type { TextContentProps } from './ui/TextContent.js';
44
- export { TextWidget } from './ui/TextWidget.js';
45
- export type { TextWidgetProps } from './ui/TextWidget.js';
46
- export { VisualizationWidget } from './ui/VisualizationWidget.js';
47
- export type { VisualizationWidgetProps, VisualizationWidgetView, } from './ui/VisualizationWidget.js';
48
- export { TableWidget } from './ui/TableWidget.js';
49
- export type { TableWidgetColumn, TableWidgetProps, TableWidgetSearch, } from './ui/TableWidget.js';
20
+ export { DataValue } from './widgets.js';
21
+ export type { DataValueProps } from './widgets.js';
22
+ export { TextWidget } from './widgets.js';
23
+ export type { TextWidgetProps } from './widgets.js';
24
+ export { VisualizationWidget } from './widgets.js';
25
+ export type { VisualizationWidgetProps } from './widgets.js';
26
+ export type { VisualizationWidgetView } from './widgets.js';
27
+ export { TableWidget } from './widgets.js';
28
+ export type { TableWidgetProps } from './widgets.js';
29
+ export type { TableWidgetSearch } from './ui/TableWidget.js';
50
30
  export { chartColor } from './ui/chartColor.js';
51
31
  export { Breakdown } from './ui/Breakdown.js';
52
32
  export type { BreakdownItem, BreakdownProps } from './ui/Breakdown.js';
53
33
  export { Ranking } from './ui/Ranking.js';
54
34
  export type { RankingItem, RankingProps } from './ui/Ranking.js';
55
- export { WidgetDisclosure } from './ui/WidgetDisclosure.js';
56
- export type { WidgetDisclosureProps } from './ui/WidgetDisclosure.js';
57
- export { WidgetViewTabs } from './ui/WidgetViewTabs.js';
58
- export type { WidgetView, WidgetViewTabsProps, } from './ui/WidgetViewTabs.js';
59
- export { ComparisonVisual } from './ui/ComparisonVisual.js';
60
- export type { ComparisonVisualProps } from './ui/ComparisonVisual.js';
61
- export { calendarMetricComparison } from './ui/comparison.js';
62
- export type { MetricComparison } from './ui/comparison.js';
63
- export { DataTable, DataTableEmptyRow, DataTableTimestamp, DataTableShare, } from './ui/DataTable.js';
64
- export type { DataTableProps, DataTableSearch, DataTableEmptyRowProps, DataTableTimestampProps, } from './ui/DataTable.js';
65
- export { MetricWidget } from './ui/MetricWidget.js';
66
- export type { MetricWidgetProps } from './ui/MetricWidget.js';
67
- export { SelectableBarChart } from './ui/SelectableBarChart.js';
68
- export type { SelectableBarChartProps, SelectableBarItem, } from './ui/SelectableBarChart.js';
69
- export { DimensionPicker } from './ui/DimensionPicker.js';
35
+ export { Comparison } from './ui/Comparison.js';
36
+ export type { ComparisonProps } from './ui/Comparison.js';
37
+ export { MetricWidget } from './widgets.js';
38
+ export type { MetricWidgetProps } from './widgets.js';
70
39
  export { EmptyState } from './ui/EmptyState.js';
71
40
  export type { EmptyStateProps } from './ui/EmptyState.js';
72
41
  export { Skeleton } from './ui/Skeleton.js';
73
42
  export type { SkeletonProps } from './ui/Skeleton.js';
74
- export { DataAppSkeleton } from './ui/DataAppSkeleton.js';
75
- export type { DataAppSkeletonProps } from './ui/DataAppSkeleton.js';
76
- export { DataBoundary } from './ui/DataBoundary.js';
77
- export { resolveDataView } from '../core/data-view.js';
78
- export { displayedSnapshot } from '../core/data-view.js';
79
- export type { DataView, DataSnapshot, DisplayedSnapshot, } from '../core/data-view.js';
80
- export type { DataBoundaryProps } from './ui/DataBoundary.js';
81
- export { RefreshRegion } from './ui/RefreshRegion.js';
82
- export type { RefreshRegionProps } from './ui/RefreshRegion.js';
83
43
  export { DataSection } from './ui/DataSection.js';
84
- export type { DataSectionProps, SectionResult, } from './ui/DataSection.js';
85
- export { StatusPanel } from './ui/StatusPanel.js';
86
- export type { StatusPanelProps } from './ui/StatusPanel.js';
87
- export { ContentSkeleton } from './ui/ContentSkeleton.js';
88
- export type { ContentSkeletonProps } from './ui/ContentSkeleton.js';
89
- export { DataViewToast } from './ui/DataViewToast.js';
90
- export type { DataViewToastProps } from './ui/DataViewToast.js';
44
+ export type { DataSectionProps } from './ui/DataSection.js';
91
45
  export { UpdatedAt } from './ui/UpdatedAt.js';
92
46
  export type { UpdatedAtProps } from './ui/UpdatedAt.js';
93
47
  export { DateTimeTooltip } from './ui/DateTimeTooltip.js';
94
48
  export type { DateTimeTooltipProps } from './ui/DateTimeTooltip.js';
95
- export { LiveControl } from './ui/LiveControl.js';
96
- export type { LiveControlProps, LiveIntervalSeconds, } from './ui/LiveControl.js';
97
- export { DateRangePicker } from './ui/DateRangePicker.js';
98
- export type { DatePresetId, DateRange, DateRangePickerProps, } from './ui/DateRangePicker.js';
99
- export { defineAppVariables, textVariable, selectVariable, dateRangeVariable, dateRangeControl, useAppVariables, } from './ui/variables.js';
100
- export type { AppVariable, AppVariableValues, DateRangeSelection, DateRangeVariable, DateRangeVariableOptions, } from './ui/variables.js';
49
+ export { searchVariable, choiceVariable, multiChoiceVariable, dateRangeVariable, } from './ui/variables.js';
50
+ export type { AppVariable, AppVariableValues, ChoiceOption, ChoiceVariable, MultiChoiceVariable, SearchVariable, DateRangeSelection, DateRangeVariable, DateRangeVariableOptions, } from './ui/variables.js';
101
51
  export { PeriodSummary } from './ui/PeriodSummary.js';
102
52
  export type { ReportingPeriod, PeriodComparison, PeriodSummaryProps, } from './ui/PeriodSummary.js';
103
- export { SearchField } from './ui/SearchField.js';
104
- export type { SearchFieldProps } from './ui/SearchField.js';
105
- export { searchItems } from './ui/searchItems.js';
106
- export type { SearchAttribute, SearchHit, SearchItemsOptions, SearchMatchValue, SearchRange, } from './ui/searchItems.js';
107
- export { SearchMatch } from './ui/SearchMatch.js';
108
- export type { SearchMatchProps } from './ui/SearchMatch.js';
109
- export { Combobox } from './ui/Combobox.js';
110
- export type { ComboboxOption, ComboboxProps } from './ui/Combobox.js';
111
- export { GradientScroll } from './ui/GradientScroll.js';
112
- export type { GradientScrollProps } from './ui/GradientScroll.js';
113
- export { searchParams, subscribeSearch, writeSearch, } from './ui/search.js';
114
- export { Tabs, TabList, Tab, TabPanels, TabPanel, useViewTab, } from './ui/Tabs.js';
115
- export { createDataContext, defineDataContext, evidenceFor, } from './ui/data-context.js';
53
+ export { createDataContext } from './ui/data-context.js';
116
54
  export type { DataContext, GlossaryEntry } from './ui/data-context.js';
117
55
  export { defineDataIdentifiers } from './ui/data-identifiers.js';
118
56
  export type { DataIdentifierDefinition, TableIdentifier, ColumnIdentifier, } from './ui/data-identifiers.js';
119
- export { GlossaryExplanation } from './ui/GlossaryExplanation.js';
120
- export type { GlossaryExplanationProps } from './ui/GlossaryExplanation.js';
121
- export { GlossaryDefinition } from './ui/GlossaryDefinition.js';
122
- export type { GlossaryDefinitionProps } from './ui/GlossaryDefinition.js';
123
- export { AboutData } from './ui/AboutData.js';
124
- export type { AboutDataProps, AboutEmpty, AboutSubject, AboutTab, } from './ui/AboutData.js';
125
- export { PresentStory } from './ui/PresentStory.js';
126
- export type { PresentStoryProps } from './ui/PresentStory.js';
127
- export type { StoryFinding, BoundStory } from './ui/story.js';
128
- export { Checkbox } from './ui/Checkbox.js';
129
- export type { CheckboxProps } from './ui/Checkbox.js';
130
- export { AppIcon } from './ui/icons.js';
131
- export type { AppIconName, AppIconProps } from './ui/icons.js';
132
57
  export { IconButton } from './ui/IconButton.js';
133
58
  export type { IconButtonProps } from './ui/IconButton.js';
134
- export { Kbd } from './ui/Kbd.js';
135
- export type { KbdProps } from './ui/Kbd.js';
136
- export { Sheet } from './ui/Sheet.js';
137
- export type { SheetDialogProps, SheetProps } from './ui/Sheet.js';
138
59
  export { Tooltip, TooltipProvider } from './ui/Tooltip.js';
139
60
  export type { TooltipProps, TooltipProviderProps, } from './ui/Tooltip.js';
140
61
  export { Button } from './ui/Button.js';
141
62
  export type { ButtonProps } from './ui/Button.js';
142
- export { HelpPopover } from './ui/HelpPopover.js';
143
- export type { HelpPopoverPanelProps, HelpPopoverProps, HelpPopoverTriggerProps, } from './ui/HelpPopover.js';
144
63
  export type { MetricDefinition } from './ui/metric.js';
145
- export type { DataReading, MetricReading, MetricValues, } from '../core/reading.js';
64
+ export type { MetricValues } from '../core/reading.js';
65
+ export { AnnotationTarget } from './annotations/AnnotationTarget.js';
66
+ export type { AnnotationTargetProps } from './annotations/AnnotationTarget.js';
67
+ export { useDataAppAnnotations } from './annotations/useDataAppAnnotations.js';
68
+ export { AnnotationBar } from './annotations/AnnotationBar.js';
69
+ export type { AnnotationBarHandle, AnnotationBarProps, } from './annotations/AnnotationBar.js';
70
+ export { injectDataAppAnnotationStyles } from './annotations/styles.js';
@@ -1,11 +1,13 @@
1
1
  import { type ComponentType, type ReactNode } from 'react';
2
- import { type DataAppConfig } from '../core/config.js';
2
+ import { type DataAppDefinition, type QueryDefinitions } from '../core/config.js';
3
3
  /** Mount once per document; installs document identity and the shared request provider. */
4
- export declare function mountDataApp({ config, component: Component, root, }: {
5
- config: DataAppConfig;
4
+ export declare function mountDataApp<const Queries extends QueryDefinitions>({ app, component: Component, root, }: {
5
+ app: DataAppDefinition<Queries>;
6
6
  component: ComponentType;
7
7
  root?: HTMLElement | null;
8
8
  }): void;
9
- export declare function DataAppProvider({ children }: {
9
+ /** Provide one app identity and shared requests to a custom React root. */
10
+ export declare function DataAppProvider<const Queries extends QueryDefinitions>({ app, children, }: {
11
+ app: DataAppDefinition<Queries>;
10
12
  children: ReactNode;
11
13
  }): import("react").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export declare function ownedSource<Source extends object>(owner: object, source: Source): Source;
2
+ export declare function assertSourceOwner(owner: object, source: object): void;
@@ -0,0 +1,80 @@
1
+ import type { CSSProperties } from 'react';
2
+ /** Public custom-property names for authoring types and validation. CSS owns their defaults. */
3
+ export declare const dataAppStyleTokens: readonly ['--atbl-control-text-size', '--atbl-annotation-accent', '--atbl-annotation-accent-hover', '--atbl-annotation-on-accent', '--atbl-annotation-highlight', '--atbl-background', '--atbl-surface', '--atbl-subtle', '--atbl-text', '--atbl-muted', '--atbl-border', '--atbl-accent', '--atbl-accent-subtle', '--atbl-on-accent', '--atbl-positive', '--atbl-negative', '--atbl-danger', '--atbl-danger-subtle', '--atbl-backdrop', '--atbl-code-surface', '--atbl-code-text', '--atbl-code-keyword', '--atbl-chart-fill', '--atbl-control-hover-border', '--atbl-focus-color', '--atbl-focus-outline', '--atbl-focus-ring-offset', '--atbl-focus-ring-inset', '--atbl-font', '--atbl-font-heading', '--atbl-mono-font', '--atbl-space-xs', '--atbl-space-sm', '--atbl-space-md', '--atbl-space-lg', '--atbl-space-xl', '--atbl-layout-gap', '--atbl-content-width', '--atbl-control-height', '--atbl-radius-control', '--atbl-radius-surface', '--atbl-radius-overlay', '--atbl-shadow-surface', '--atbl-shadow-overlay', '--atbl-shadow-control', '--atbl-cursor-action', '--atbl-cursor-disabled', '--atbl-cursor-help', '--atbl-duration-fast', '--atbl-duration-normal', '--atbl-duration-slow', '--atbl-ease-standard', '--atbl-ease-enter', '--atbl-chart-1', '--atbl-chart-2', '--atbl-chart-3', '--atbl-chart-4', '--atbl-chart-5', '--atbl-chart-6', '--atbl-chart-7', '--atbl-chart-8', '--atbl-type-emphasis-weight', '--atbl-type-meta-weight', '--atbl-type-page-size', '--atbl-type-section-size', '--atbl-type-widget-size', '--atbl-type-body-size', '--atbl-type-label-size', '--atbl-type-meta-size', '--atbl-type-metric-size', '--atbl-type-heading-weight', '--atbl-type-label-weight', '--atbl-type-body-leading', '--atbl-type-label-leading', '--atbl-type-heading-leading', '--atbl-type-metric-leading', '--atbl-text-measure', '--atbl-control-compact-height', '--atbl-control-icon-size', '--atbl-control-padding-inline', '--atbl-control-padding-block', '--atbl-control-gap', '--atbl-control-disabled-opacity', '--atbl-cursor-busy', '--atbl-control-hover-surface', '--atbl-control-pressed-surface', '--atbl-control-selected-surface', '--atbl-control-selected-text'];
4
+ /** Stable component roots for CSS customization; only utilities may be placed on native markup. */
5
+ export declare const dataAppStyleClasses: {
6
+ readonly 'altertable-app-layout': {
7
+ readonly component: 'AppLayout';
8
+ readonly kind: 'root';
9
+ };
10
+ readonly 'altertable-stack': {
11
+ readonly component: 'Stack';
12
+ readonly kind: 'root';
13
+ };
14
+ readonly 'altertable-grid': {
15
+ readonly component: 'Grid';
16
+ readonly kind: 'root';
17
+ };
18
+ readonly 'altertable-grid-item': {
19
+ readonly component: 'GridItem';
20
+ readonly kind: 'root';
21
+ };
22
+ readonly 'altertable-text-content': {
23
+ readonly component: 'TextContent';
24
+ readonly kind: 'root';
25
+ };
26
+ readonly 'altertable-button': {
27
+ readonly component: 'Button';
28
+ readonly kind: 'root';
29
+ };
30
+ readonly 'altertable-tabs': {
31
+ readonly component: 'Tabs';
32
+ readonly kind: 'root';
33
+ };
34
+ readonly 'altertable-data-widget': {
35
+ readonly component: 'DataWidget';
36
+ readonly kind: 'root';
37
+ };
38
+ readonly 'altertable-metric-widget': {
39
+ readonly component: 'MetricWidget';
40
+ readonly kind: 'root';
41
+ };
42
+ readonly 'altertable-data-app-skeleton': {
43
+ readonly component: 'DataAppSkeleton';
44
+ readonly kind: 'root';
45
+ };
46
+ readonly 'altertable-chart-legend': {
47
+ readonly component: 'ChartLegend';
48
+ readonly kind: 'root';
49
+ };
50
+ readonly 'altertable-chart-legend-item': {
51
+ readonly component: 'ChartLegend.Item';
52
+ readonly kind: 'root';
53
+ };
54
+ readonly 'altertable-chart-legend-marker': {
55
+ readonly component: 'ChartLegend.Marker';
56
+ readonly kind: 'root';
57
+ };
58
+ readonly 'altertable-chart-legend-label': {
59
+ readonly component: 'ChartLegend.Label';
60
+ readonly kind: 'root';
61
+ };
62
+ readonly 'altertable-composed-chart': {
63
+ readonly component: 'ComposedChart';
64
+ readonly kind: 'root';
65
+ };
66
+ readonly 'altertable-sr-only': {
67
+ readonly component: null;
68
+ readonly kind: 'utility';
69
+ };
70
+ };
71
+ export declare const dataAppStyleHooks: {
72
+ readonly 'data-atbl-focus': readonly ['ring', 'inset', 'group'];
73
+ readonly 'data-atbl-control': readonly ['default', 'action', 'help', 'text'];
74
+ };
75
+ export type DataAppStyleToken = (typeof dataAppStyleTokens)[number];
76
+ /** React style properties with checked public Altertable custom properties. */
77
+ export type DataAppStyle = CSSProperties & Partial<Record<DataAppStyleToken, string | number>>;
78
+ export type DataAppStyleHooks = {
79
+ [Name in keyof typeof dataAppStyleHooks]?: (typeof dataAppStyleHooks)[Name][number];
80
+ };
@@ -0,0 +1,2 @@
1
+ /** Static authoring checks; app-owned names are allowed, package implementation names are not. */
2
+ export declare function validateAuthoredStyles(source: string, kind: 'css' | 'markup'): string[];
@@ -4,6 +4,7 @@ import type { DataContext, GlossaryEntry } from './data-context.js';
4
4
  import { type ButtonProps } from './Button.js';
5
5
  import { type SheetDialogProps } from './Sheet.js';
6
6
  export type AboutTab = 'glossary' | 'queries';
7
+ export declare function resolveAboutTab(tab: string | null | undefined): AboutTab;
7
8
  export type AboutEmpty = {
8
9
  glossary: {
9
10
  title: string;
@@ -57,4 +58,11 @@ export type AboutDataProps = AboutSubject & {
57
58
  * Open state uses `?about=`; tab selection uses `?tab=`. Enable the global shortcut only on the
58
59
  * page-level trigger.
59
60
  */
60
- export declare function AboutData({ id, title, description, visual, visualKind, variant, dataContext, references, queries, empty, iconOnly, shortcut, tooltip, children, footer, portalRoot, sheetProps, headerActions, open: openProp, onOpenChange, tab, trigger, className, onClick, ref, ...props }: AboutDataProps): import("react").JSX.Element;
61
+ export declare function InspectionSheet({ id, title, description, visual, visualKind, dataContext, references, queries, empty, footer, sheetProps, headerActions, open, onOpenChange, tab, onTabChange, returnFocus, }: AboutDataProps & {
62
+ open: boolean;
63
+ onOpenChange: (open: boolean) => void;
64
+ tab: AboutTab;
65
+ onTabChange: (tab: AboutTab) => void;
66
+ returnFocus: RefObject<HTMLButtonElement | null>;
67
+ }): import("react").JSX.Element;
68
+ export declare function AboutData(props: AboutDataProps): import("react").JSX.Element;
@@ -5,7 +5,6 @@ export type AppHeaderProps = {
5
5
  description?: ReactNode;
6
6
  toolbar?: ReactNode;
7
7
  children?: ReactNode;
8
- headingProps?: Omit<ComponentPropsWithRef<'div'>, 'children'>;
9
8
  } & Omit<ComponentPropsWithRef<'header'>, 'children' | 'title'>;
10
9
  /** Page identity and actions; on narrow screens the scope shares a row with actions. */
11
- export declare function AppHeader({ scope, title, description, toolbar, children, headingProps, className, ...props }: AppHeaderProps): import("react").JSX.Element;
10
+ export declare function AppHeader({ scope, title, description, toolbar, children, className, ...props }: AppHeaderProps): import("react").JSX.Element;
@@ -1,16 +1,10 @@
1
- import type { ComponentProps, ComponentPropsWithRef, ReactNode } from 'react';
2
- import { AppFooter } from './AppFooter.js';
3
- import { type TooltipProviderProps } from './Tooltip.js';
1
+ import type { ComponentPropsWithRef, ReactNode } from 'react';
4
2
  export type AppLayoutProps = {
5
3
  children: ReactNode;
6
4
  footerActions?: ReactNode;
7
5
  footer?: ReactNode;
8
- footerProps?: Omit<ComponentProps<typeof AppFooter>, 'children'>;
9
- layoutProps?: Omit<ComponentPropsWithRef<'div'>, 'children'>;
10
- tooltipProviderProps?: Omit<TooltipProviderProps, 'children'>;
11
6
  } & Omit<ComponentPropsWithRef<'main'>, 'children'>;
12
7
  /**
13
- * Native props target `<main>`. `layoutProps` targets the outer wrapper; `footer` replaces the
14
- * default footer, while `footerActions` fills it.
8
+ * Native props target `<main>`. The shell owns its wrapper and tooltip defaults.
15
9
  */
16
- export declare function AppLayout({ children, footerActions, footer, footerProps, layoutProps, tooltipProviderProps, className, ...props }: AppLayoutProps): import("react").JSX.Element;
10
+ export declare function AppLayout({ children, footerActions, footer, className, ...props }: AppLayoutProps): import("react").JSX.Element;
@@ -3,13 +3,10 @@ import type { DataView } from '../../core/data-view.js';
3
3
  import type { CsvExport } from './csv-export.js';
4
4
  import { type LiveControlProps } from './LiveControl.js';
5
5
  import { PresentStory } from './PresentStory.js';
6
- import { RefreshControl } from './RefreshControl.js';
7
6
  export type AppToolbarProps = {
8
7
  children?: ReactNode;
9
8
  end?: ReactNode;
10
- controlsProps?: Omit<ComponentPropsWithRef<'div'>, 'children'>;
11
9
  updatedAt?: ReactNode;
12
- initialLoading?: boolean;
13
10
  requestState?: DataView<unknown, unknown>['kind'];
14
11
  refresh?: {
15
12
  refreshing: boolean;
@@ -17,17 +14,17 @@ export type AppToolbarProps = {
17
14
  onCancel?: () => void;
18
15
  label?: string;
19
16
  tooltip?: ReactNode;
20
- buttonProps?: Omit<ComponentPropsWithRef<'button'>, 'children' | 'onClick'>;
21
- statusProps?: ComponentProps<typeof RefreshControl>['statusProps'];
22
17
  };
23
18
  live?: LiveControlProps;
24
19
  aboutData?: ReactNode;
25
- story?: ComponentProps<typeof PresentStory>;
26
- csvExport?: CsvExport;
20
+ /** Null reserves a disabled story action while its findings are unavailable. */
21
+ story?: ComponentProps<typeof PresentStory> | null;
22
+ /** Null reserves a disabled export action while its data is unavailable. */
23
+ csvExport?: CsvExport | null;
27
24
  } & Omit<ComponentPropsWithRef<'div'>, 'children'>;
28
25
  /** Header actions only. Put reader-controlled inputs in DataApp.variables below the header.
29
26
  * Observation time, or an initial loading status, sits before Refresh. Children prepend app controls in the right
30
27
  * cluster; end follows the built-in actions. Live sits beside Refresh when supplied. Refresh also
31
28
  * answers Alt/Option+R and uses the button to cancel a running request when onCancel is provided;
32
29
  * refresh.tooltip overrides its static label. All built-in controls are optional. */
33
- export declare function AppToolbar({ children, updatedAt, initialLoading, requestState, refresh, live, aboutData, story, csvExport, end, controlsProps, className, role, 'aria-label': ariaLabel, ...props }: AppToolbarProps): import("react").JSX.Element;
30
+ export declare function AppToolbar({ children, updatedAt, requestState, refresh, live, aboutData, story, csvExport, end, className, role, 'aria-label': ariaLabel, ...props }: AppToolbarProps): import("react").JSX.Element;
@@ -0,0 +1,7 @@
1
+ import type { ChartItem, ValueChartProps } from './chart-data.js';
2
+ export type AreaChartItem = ChartItem;
3
+ export type AreaChartProps = ValueChartProps;
4
+ /** Ordered finite samples filled to a zero baseline, including negative values.
5
+ * Samples are equally spaced; supply missing periods explicitly.
6
+ * Compose inside VisualizationWidget; hover/touch tooltips need no caller state. */
7
+ export declare function AreaChart(props: AreaChartProps): import("react").JSX.Element;
@@ -0,0 +1,6 @@
1
+ import { type ChartItem, type ValueChartProps } from './chart-data.js';
2
+ export type BarChartItem = ChartItem;
3
+ export type BarChartProps = ValueChartProps;
4
+ /** Nonnegative category values. Compose inside VisualizationWidget for a titled panel.
5
+ * Owns hover/touch tooltips; no selection state or keyboard navigation. */
6
+ export declare function BarChart({ items, unit, ariaLabel, formatValue, }: BarChartProps): import("react").JSX.Element;
@@ -1,11 +1,11 @@
1
1
  import type { ComponentPropsWithRef } from 'react';
2
- import { type ButtonProps as AriaButtonProps } from 'react-aria-components';
2
+ import { Button as AriaButton } from 'react-aria-components';
3
3
  export type ButtonProps = ComponentPropsWithRef<'button'> & {
4
- variant?: 'elevated' | 'outline' | 'ghost';
4
+ variant?: 'primary' | 'elevated' | 'outline' | 'ghost';
5
5
  size?: 'default' | 'compact' | 'icon' | 'icon-compact';
6
6
  };
7
7
  export declare function Button({ className, type, variant, size, disabled, ...props }: ButtonProps): import("react").JSX.Element;
8
8
  /** React Aria trigger behavior with the same presentation as the native Button. */
9
- export declare function PressButton({ variant, size, className, ...props }: Omit<AriaButtonProps, 'className'> & Pick<ButtonProps, 'variant' | 'size'> & {
9
+ export declare function PressButton({ variant, size, className, ...props }: Omit<ComponentPropsWithRef<typeof AriaButton>, 'className'> & Pick<ButtonProps, 'variant' | 'size'> & {
10
10
  className?: string;
11
11
  }): import("react").JSX.Element;
@@ -0,0 +1,31 @@
1
+ import { type ComponentPropsWithRef, type ReactNode } from 'react';
2
+ export type ChartLegendProps = {
3
+ children: ReactNode;
4
+ layout?: 'horizontal' | 'vertical';
5
+ align?: 'start' | 'center' | 'end';
6
+ /** Maximum visible cells, including the expansion control; defaults to six. */
7
+ maxVisibleItems?: number;
8
+ } & Omit<ComponentPropsWithRef<'ul'>, 'children'>;
9
+ /** Optional chart key, placed beside any chart with the app's layout components.
10
+ * Items describe displayed series or categories; the caller owns series visibility and interactions. */
11
+ declare function ChartLegendRoot({ children, layout, align, maxVisibleItems, className, 'aria-label': ariaLabel, ...props }: ChartLegendProps): import("react").JSX.Element;
12
+ export type ChartLegendItemProps = ComponentPropsWithRef<'li'> & {
13
+ inactive?: boolean;
14
+ };
15
+ /** Descriptive by default; compose a button inside the item for an authored series toggle. */
16
+ declare function ChartLegendItem({ inactive, className, ...props }: ChartLegendItemProps): import("react").JSX.Element;
17
+ export type ChartLegendMarkerKind = 'bar' | 'line' | 'area' | 'point' | 'slice';
18
+ export type ChartLegendMarkerProps = Omit<ComponentPropsWithRef<'svg'>, 'children'> & {
19
+ kind: ChartLegendMarkerKind;
20
+ };
21
+ /** Decorative mark; color accepts public palette tokens or any CSS color.
22
+ * Defaults match the shared bar or accent-colored series primitives. */
23
+ declare function ChartLegendMarker({ kind, color, className, style, ...props }: ChartLegendMarkerProps): import("react").JSX.Element;
24
+ export type ChartLegendLabelProps = ComponentPropsWithRef<'span'>;
25
+ declare function ChartLegendLabel({ className, children, title, ...props }: ChartLegendLabelProps): import("react").JSX.Element;
26
+ export declare const ChartLegend: typeof ChartLegendRoot & {
27
+ Item: typeof ChartLegendItem;
28
+ Marker: typeof ChartLegendMarker;
29
+ Label: typeof ChartLegendLabel;
30
+ };
31
+ export {};
@@ -1,10 +1,21 @@
1
1
  import { type ReactNode } from 'react';
2
+ export declare const CheckboxGroupContext: import("react").Context<{
3
+ values: readonly string[];
4
+ disabled?: boolean;
5
+ onChange: (value: string, checked: boolean) => void;
6
+ } | null>;
2
7
  export type CheckboxProps = {
3
8
  label: string;
4
9
  description?: ReactNode;
5
- checked: boolean;
6
- onChange: (checked: boolean) => void;
7
10
  disabled?: boolean;
8
11
  className?: string;
9
- };
10
- export declare function Checkbox({ label, description, checked, onChange, disabled, className, }: CheckboxProps): import("react").JSX.Element;
12
+ } & ({
13
+ value: string;
14
+ checked?: never;
15
+ onChange?: never;
16
+ } | {
17
+ value?: never;
18
+ checked: boolean;
19
+ onChange: (checked: boolean) => void;
20
+ });
21
+ export declare function Checkbox({ label, description, checked, value, onChange, disabled, className, }: CheckboxProps): import("react").JSX.Element;
@@ -0,0 +1,7 @@
1
+ import type { ComponentPropsWithRef } from 'react';
2
+ export type CheckboxGroupProps = Omit<ComponentPropsWithRef<'fieldset'>, 'onChange'> & {
3
+ label: string;
4
+ values: readonly string[];
5
+ onChange: (values: string[]) => void;
6
+ };
7
+ export declare function CheckboxGroup({ label, values, onChange, className, children, disabled, ...props }: CheckboxGroupProps): import("react").JSX.Element;
@@ -1,14 +1,10 @@
1
- /** IDs are nonempty and unique across ordinary and missing options. */
2
- export type ComboboxOption = {
3
- id: string;
4
- label: string;
5
- description?: string;
6
- };
1
+ import type { ChoiceOption } from '../../core/variables.js';
2
+ export type { ChoiceOption } from '../../core/variables.js';
7
3
  type SharedProps = {
8
4
  label: string;
9
- options: ComboboxOption[];
5
+ options: readonly ChoiceOption[];
10
6
  /** Separate source state, rendered last with a divider and the shared option component. */
11
- missingOption?: ComboboxOption;
7
+ missingOption?: ChoiceOption;
12
8
  disabled?: boolean;
13
9
  placeholder?: string;
14
10
  emptyMessage?: string;
@@ -18,15 +14,16 @@ type SharedProps = {
18
14
  error?: boolean;
19
15
  onRetry?: () => void;
20
16
  };
21
- export type SingleComboboxProps = SharedProps & {
17
+ export type SingleChoicePickerProps = SharedProps & {
18
+ selectionMode: 'single';
22
19
  value: string;
23
20
  onChange: (value: string) => void;
24
- resetValue?: string;
25
21
  values?: never;
26
22
  maxSelected?: never;
27
23
  emptySelectionLabel?: never;
28
24
  };
29
- export type MultiComboboxProps = SharedProps & {
25
+ export type MultiChoicePickerProps = SharedProps & {
26
+ selectionMode: 'multiple';
30
27
  values: readonly string[];
31
28
  onChange: (values: string[]) => void;
32
29
  /** Positive integer; at capacity, only unselected options are disabled. */
@@ -34,9 +31,7 @@ export type MultiComboboxProps = SharedProps & {
34
31
  /** Meaning of an empty selection belongs to the caller, e.g. All or Select a value. */
35
32
  emptySelectionLabel: string;
36
33
  value?: never;
37
- resetValue?: never;
38
34
  };
39
- export type ComboboxProps = SingleComboboxProps | MultiComboboxProps;
35
+ export type ChoicePickerProps = SingleChoicePickerProps | MultiChoicePickerProps;
40
36
  /** Searchable selection picker with one focus and popup model for single and multiple values. */
41
- export declare function Combobox(props: ComboboxProps): import("react").JSX.Element;
42
- export {};
37
+ export declare function ChoicePicker(props: ChoicePickerProps): import("react").JSX.Element;
@@ -1,14 +1,14 @@
1
- import { type MetricComparison } from './comparison.js';
1
+ import { type MetricComparison } from './metric-comparison.js';
2
2
  import type { MetricDefinition } from './metric.js';
3
3
  import type { MetricReading } from '../../core/reading.js';
4
4
  type UnboundComparisonProps = MetricComparison & {
5
5
  label: string;
6
6
  emphasis?: 'standard' | 'story';
7
7
  };
8
- export type ComparisonVisualProps = UnboundComparisonProps | {
8
+ export type ComparisonProps = UnboundComparisonProps | {
9
9
  metric: MetricDefinition;
10
10
  reading: MetricReading;
11
11
  emphasis?: 'standard' | 'story';
12
12
  };
13
- export declare function ComparisonVisual(props: ComparisonVisualProps): import("react").JSX.Element | null;
13
+ export declare function Comparison(props: ComparisonProps): import("react").JSX.Element | null;
14
14
  export {};
@@ -0,0 +1,41 @@
1
+ import type { ComponentProps } from 'react';
2
+ import { ComposedChartLegend as Legend } from './ComposedChartLegend.js';
3
+ import { ComposedChart as RechartsComposedChart, ZAxis, ReferenceLine, ReferenceArea, ReferenceDot, Brush, Label, LabelList, ErrorBar } from 'recharts';
4
+ import { ChartBar as Bar, ChartDot as Dot, ChartLine as Line, ChartArea as Area, ChartScatter as Scatter, ChartXAxis as XAxis, ChartYAxis as YAxis, ChartGrid as CartesianGrid, ChartTooltip as Tooltip } from './chart-primitives.js';
5
+ export type ComposedChartProps<Row = unknown> = Omit<ComponentProps<typeof RechartsComposedChart<Row>>, 'data' | 'title'> & {
6
+ /** Displayed rows; series and axes select fields with Recharts dataKey props. */
7
+ data: readonly Row[];
8
+ /** Describes the measures and scope for assistive technology. */
9
+ ariaLabel: string;
10
+ };
11
+ /** Compose Cartesian series inside VisualizationWidget. Defaults to responsive
12
+ * full width and 300px height. Children retain native Recharts props and behavior,
13
+ * including stacking, numeric/time axes, missing values, tooltips, and keyboard
14
+ * navigation. Match yAxisId on axes and series for different units; use stackId
15
+ * for stacks. Preserve missing measures as null and choose connectNulls deliberately.
16
+ * Use public chart tokens for series colors. Dataset bindings own
17
+ * loading, empty results, evidence, and CSV; this primitive owns only the plot. */
18
+ declare function ComposedChartRoot<Row>({ data, ariaLabel, width, height, responsive, className, ...props }: ComposedChartProps<Row>): import("react").JSX.Element;
19
+ /** Shared themed series and controls; other children retain native Recharts defaults. */
20
+ export declare const ComposedChart: typeof ComposedChartRoot & {
21
+ Dot: typeof Dot;
22
+ Area: typeof Area;
23
+ Bar: typeof Bar;
24
+ Line: typeof Line;
25
+ Scatter: typeof Scatter;
26
+ XAxis: typeof XAxis;
27
+ YAxis: typeof YAxis;
28
+ ZAxis: typeof ZAxis;
29
+ CartesianGrid: typeof CartesianGrid;
30
+ Tooltip: typeof Tooltip;
31
+ Legend: typeof Legend;
32
+ ReferenceLine: typeof ReferenceLine;
33
+ ReferenceArea: typeof ReferenceArea;
34
+ ReferenceDot: typeof ReferenceDot;
35
+ Brush: typeof Brush;
36
+ Cell: import("react").FunctionComponent<import("recharts").CellProps>;
37
+ Label: typeof Label;
38
+ LabelList: typeof LabelList;
39
+ ErrorBar: typeof ErrorBar;
40
+ };
41
+ export {};
@@ -0,0 +1,8 @@
1
+ import type { ComponentProps } from 'react';
2
+ import { Legend } from 'recharts';
3
+ export type ComposedChartLegendProps = ComponentProps<typeof Legend> & {
4
+ maxVisibleItems?: number;
5
+ };
6
+ /** Opt in inside ComposedChart to derive the shared legend from its displayed series.
7
+ * Native positioning, sorting, formatters, callbacks, and custom content remain available. */
8
+ export declare function ComposedChartLegend({ maxVisibleItems, ...props }: ComposedChartLegendProps): import("react").JSX.Element;
@@ -3,3 +3,5 @@ import type { SkeletonContent } from './presentation.js';
3
3
  export type ContentSkeletonProps = SkeletonContent & Omit<ComponentPropsWithRef<'div'>, 'children'>;
4
4
  /** A metric, panel, or ranking placeholder to compose in the same layout as live content. */
5
5
  export declare function ContentSkeleton({ variant, rows, className, ...props }: ContentSkeletonProps): import("react").JSX.Element;
6
+ /** Placeholder for a widget body; static headings stay outside it. */
7
+ export declare function ContentSkeletonBody({ variant, rows }: SkeletonContent): import("react").JSX.Element;