semiotic 3.0.0 → 3.0.1

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 (181) hide show
  1. package/CLAUDE.md +23 -10
  2. package/README.md +66 -63
  3. package/ai/cli.js +34 -21
  4. package/ai/dist/componentRegistry.js +2 -0
  5. package/ai/dist/mcp-server.js +54 -0
  6. package/ai/examples.md +75 -0
  7. package/ai/schema.json +71 -0
  8. package/ai/system-prompt.md +3 -0
  9. package/dist/{ChartGrid.d.ts → components/ChartGrid.d.ts} +9 -7
  10. package/dist/{LinkedCharts.d.ts → components/LinkedCharts.d.ts} +34 -1
  11. package/dist/{Tooltip → components/Tooltip}/Tooltip.d.ts +9 -2
  12. package/dist/{charts → components/charts}/index.d.ts +2 -0
  13. package/dist/{charts → components/charts}/network/ChordDiagram.d.ts +2 -0
  14. package/dist/{charts → components/charts}/network/CirclePack.d.ts +2 -0
  15. package/dist/{charts → components/charts}/network/ForceDirectedGraph.d.ts +2 -0
  16. package/dist/components/charts/network/OrbitDiagram.d.ts +78 -0
  17. package/dist/{charts → components/charts}/network/SankeyDiagram.d.ts +2 -0
  18. package/dist/{charts → components/charts}/network/TreeDiagram.d.ts +2 -0
  19. package/dist/{charts → components/charts}/network/Treemap.d.ts +2 -0
  20. package/dist/{charts → components/charts}/ordinal/BarChart.d.ts +2 -0
  21. package/dist/{charts → components/charts}/ordinal/BoxPlot.d.ts +2 -0
  22. package/dist/{charts → components/charts}/ordinal/DonutChart.d.ts +2 -0
  23. package/dist/{charts → components/charts}/ordinal/DotPlot.d.ts +2 -0
  24. package/dist/{charts → components/charts}/ordinal/GroupedBarChart.d.ts +2 -0
  25. package/dist/{charts → components/charts}/ordinal/PieChart.d.ts +2 -0
  26. package/dist/{charts → components/charts}/ordinal/StackedBarChart.d.ts +2 -0
  27. package/dist/{charts → components/charts}/ordinal/SwarmPlot.d.ts +2 -0
  28. package/dist/components/charts/shared/diagnoseConfig.d.ts +23 -0
  29. package/dist/{charts → components/charts}/shared/hooks.d.ts +23 -1
  30. package/dist/components/charts/shared/stringDistance.d.ts +11 -0
  31. package/dist/{charts → components/charts}/shared/tooltipUtils.d.ts +1 -1
  32. package/dist/{charts → components/charts}/shared/types.d.ts +6 -0
  33. package/dist/{charts → components/charts}/shared/withChartWrapper.d.ts +10 -0
  34. package/dist/{charts → components/charts}/xy/AreaChart.d.ts +8 -0
  35. package/dist/{charts → components/charts}/xy/BubbleChart.d.ts +8 -0
  36. package/dist/{charts → components/charts}/xy/ConnectedScatterplot.d.ts +3 -0
  37. package/dist/{charts → components/charts}/xy/Heatmap.d.ts +8 -0
  38. package/dist/{charts → components/charts}/xy/LineChart.d.ts +26 -0
  39. package/dist/{charts → components/charts}/xy/Scatterplot.d.ts +3 -0
  40. package/dist/{charts → components/charts}/xy/StackedAreaChart.d.ts +8 -0
  41. package/dist/{export → components/export}/exportChart.d.ts +6 -1
  42. package/dist/components/semiotic-ai.d.ts +61 -0
  43. package/dist/components/semiotic-data.d.ts +7 -0
  44. package/dist/components/semiotic-network.d.ts +14 -0
  45. package/dist/components/semiotic-ordinal.d.ts +18 -0
  46. package/dist/components/semiotic-realtime.d.ts +22 -0
  47. package/dist/components/semiotic-server.d.ts +1 -0
  48. package/dist/components/semiotic-xy.d.ts +16 -0
  49. package/dist/components/semiotic.d.ts +57 -0
  50. package/dist/{server → components/server}/renderToStaticSVG.d.ts +7 -0
  51. package/dist/{stream → components/stream}/NetworkSVGOverlay.d.ts +20 -0
  52. package/dist/{stream → components/stream}/OrdinalSVGOverlay.d.ts +8 -0
  53. package/dist/{stream → components/stream}/PipelineStore.d.ts +7 -0
  54. package/dist/{stream → components/stream}/SVGOverlay.d.ts +15 -0
  55. package/dist/components/stream/SceneToSVG.d.ts +20 -0
  56. package/dist/components/stream/hitTestUtils.d.ts +23 -0
  57. package/dist/{stream → components/stream}/networkTypes.d.ts +10 -2
  58. package/dist/{stream → components/stream}/ordinalTypes.d.ts +16 -10
  59. package/dist/components/stream/renderers/areaCanvasRenderer.d.ts +2 -0
  60. package/dist/{stream → components/stream}/types.d.ts +12 -0
  61. package/dist/components/stream/useStalenessCheck.d.ts +16 -0
  62. package/dist/{types → components/types}/legendTypes.d.ts +5 -0
  63. package/dist/network.min.js +1 -1
  64. package/dist/network.module.min.js +1 -1
  65. package/dist/ordinal.min.js +1 -1
  66. package/dist/ordinal.module.min.js +1 -1
  67. package/dist/realtime.min.js +1 -1
  68. package/dist/realtime.module.min.js +1 -1
  69. package/dist/semiotic-ai.d.ts +3 -0
  70. package/dist/semiotic-ai.min.js +1 -1
  71. package/dist/semiotic-ai.module.min.js +1 -1
  72. package/dist/semiotic-network.d.ts +1 -0
  73. package/dist/semiotic-ordinal.d.ts +1 -0
  74. package/dist/semiotic.d.ts +3 -3
  75. package/dist/semiotic.min.js +1 -1
  76. package/dist/semiotic.module.min.js +1 -1
  77. package/dist/server.min.js +1 -1
  78. package/dist/server.module.min.js +1 -1
  79. package/dist/test/canvasMock.d.ts +2 -0
  80. package/dist/test-utils/canvasMock.d.ts +20 -0
  81. package/dist/test-utils/frameMock.d.ts +78 -0
  82. package/dist/xy.min.js +1 -1
  83. package/dist/xy.module.min.js +1 -1
  84. package/package.json +7 -15
  85. package/dist/stream/renderers/areaCanvasRenderer.d.ts +0 -7
  86. /package/dist/{Annotation.d.ts → components/Annotation.d.ts} +0 -0
  87. /package/dist/{CategoryColors.d.ts → components/CategoryColors.d.ts} +0 -0
  88. /package/dist/{ChartContainer.d.ts → components/ChartContainer.d.ts} +0 -0
  89. /package/dist/{ChartErrorBoundary.d.ts → components/ChartErrorBoundary.d.ts} +0 -0
  90. /package/dist/{ContextLayout.d.ts → components/ContextLayout.d.ts} +0 -0
  91. /package/dist/{DetailsPanel.d.ts → components/DetailsPanel.d.ts} +0 -0
  92. /package/dist/{Legend.d.ts → components/Legend.d.ts} +0 -0
  93. /package/dist/{ThemeProvider.d.ts → components/ThemeProvider.d.ts} +0 -0
  94. /package/dist/{charts → components/charts}/ordinal/Histogram.d.ts +0 -0
  95. /package/dist/{charts → components/charts}/ordinal/RidgelinePlot.d.ts +0 -0
  96. /package/dist/{charts → components/charts}/ordinal/ViolinPlot.d.ts +0 -0
  97. /package/dist/{charts → components/charts}/realtime/RealtimeHeatmap.d.ts +0 -0
  98. /package/dist/{charts → components/charts}/realtime/RealtimeHistogram.d.ts +0 -0
  99. /package/dist/{charts → components/charts}/realtime/RealtimeLineChart.d.ts +0 -0
  100. /package/dist/{charts → components/charts}/realtime/RealtimeSwarmChart.d.ts +0 -0
  101. /package/dist/{charts → components/charts}/realtime/RealtimeWaterfallChart.d.ts +0 -0
  102. /package/dist/{charts → components/charts}/shared/ChartError.d.ts +0 -0
  103. /package/dist/{charts → components/charts}/shared/annotationRules.d.ts +0 -0
  104. /package/dist/{charts → components/charts}/shared/colorUtils.d.ts +0 -0
  105. /package/dist/{charts → components/charts}/shared/formatUtils.d.ts +0 -0
  106. /package/dist/{charts → components/charts}/shared/legendUtils.d.ts +0 -0
  107. /package/dist/{charts → components/charts}/shared/loess.d.ts +0 -0
  108. /package/dist/{charts → components/charts}/shared/networkUtils.d.ts +0 -0
  109. /package/dist/{charts → components/charts}/shared/selectionUtils.d.ts +0 -0
  110. /package/dist/{charts → components/charts}/shared/statisticalOverlays.d.ts +0 -0
  111. /package/dist/{charts → components/charts}/shared/validateChartData.d.ts +0 -0
  112. /package/dist/{charts → components/charts}/shared/validateProps.d.ts +0 -0
  113. /package/dist/{charts → components/charts}/xy/MinimapChart.d.ts +0 -0
  114. /package/dist/{charts → components/charts}/xy/ScatterplotMatrix.d.ts +0 -0
  115. /package/dist/{data → components/data}/fromVegaLite.d.ts +0 -0
  116. /package/dist/{data → components/data}/transforms.d.ts +0 -0
  117. /package/dist/{export → components/export}/chartConfig.d.ts +0 -0
  118. /package/dist/{export → components/export}/selectionSerializer.d.ts +0 -0
  119. /package/dist/{geometry → components/geometry}/sankeyLinks.d.ts +0 -0
  120. /package/dist/{realtime → components/realtime}/BinAccumulator.d.ts +0 -0
  121. /package/dist/{realtime → components/realtime}/IncrementalExtent.d.ts +0 -0
  122. /package/dist/{realtime → components/realtime}/RingBuffer.d.ts +0 -0
  123. /package/dist/{realtime → components/realtime}/renderers/types.d.ts +0 -0
  124. /package/dist/{realtime → components/realtime}/renderers/waterfallRenderer.d.ts +0 -0
  125. /package/dist/{realtime → components/realtime}/types.d.ts +0 -0
  126. /package/dist/{store → components/store}/ObservationStore.d.ts +0 -0
  127. /package/dist/{store → components/store}/SelectionStore.d.ts +0 -0
  128. /package/dist/{store → components/store}/ThemeStore.d.ts +0 -0
  129. /package/dist/{store → components/store}/TooltipStore.d.ts +0 -0
  130. /package/dist/{store → components/store}/createStore.d.ts +0 -0
  131. /package/dist/{store → components/store}/useObservation.d.ts +0 -0
  132. /package/dist/{store → components/store}/useSelection.d.ts +0 -0
  133. /package/dist/{stream → components/stream}/CanvasHitTester.d.ts +0 -0
  134. /package/dist/{stream → components/stream}/DataSourceAdapter.d.ts +0 -0
  135. /package/dist/{stream → components/stream}/MarginalGraphics.d.ts +0 -0
  136. /package/dist/{stream → components/stream}/NetworkCanvasHitTester.d.ts +0 -0
  137. /package/dist/{stream → components/stream}/NetworkPipelineStore.d.ts +0 -0
  138. /package/dist/{stream → components/stream}/OrdinalCanvasHitTester.d.ts +0 -0
  139. /package/dist/{stream → components/stream}/OrdinalPipelineStore.d.ts +0 -0
  140. /package/dist/{stream → components/stream}/ParticlePool.d.ts +0 -0
  141. /package/dist/{stream → components/stream}/SceneGraph.d.ts +0 -0
  142. /package/dist/{stream → components/stream}/StreamNetworkFrame.d.ts +0 -0
  143. /package/dist/{stream → components/stream}/StreamOrdinalFrame.d.ts +0 -0
  144. /package/dist/{stream → components/stream}/StreamXYFrame.d.ts +0 -0
  145. /package/dist/{stream → components/stream}/accessorUtils.d.ts +0 -0
  146. /package/dist/{stream → components/stream}/keyboardNav.d.ts +0 -0
  147. /package/dist/{stream → components/stream}/layouts/chordLayoutPlugin.d.ts +0 -0
  148. /package/dist/{stream → components/stream}/layouts/forceLayoutPlugin.d.ts +0 -0
  149. /package/dist/{stream → components/stream}/layouts/hierarchyLayoutPlugin.d.ts +0 -0
  150. /package/dist/{stream → components/stream}/layouts/index.d.ts +0 -0
  151. /package/dist/{stream → components/stream}/layouts/sankeyLayoutPlugin.d.ts +0 -0
  152. /package/dist/{stream → components/stream}/ordinalSceneBuilders/barScene.d.ts +0 -0
  153. /package/dist/{stream → components/stream}/ordinalSceneBuilders/connectorScene.d.ts +0 -0
  154. /package/dist/{stream → components/stream}/ordinalSceneBuilders/pieScene.d.ts +0 -0
  155. /package/dist/{stream → components/stream}/ordinalSceneBuilders/pointScene.d.ts +0 -0
  156. /package/dist/{stream → components/stream}/ordinalSceneBuilders/statisticalScene.d.ts +0 -0
  157. /package/dist/{stream → components/stream}/ordinalSceneBuilders/timelineScene.d.ts +0 -0
  158. /package/dist/{stream → components/stream}/ordinalSceneBuilders/types.d.ts +0 -0
  159. /package/dist/{stream → components/stream}/renderers/barCanvasRenderer.d.ts +0 -0
  160. /package/dist/{stream → components/stream}/renderers/boxplotCanvasRenderer.d.ts +0 -0
  161. /package/dist/{stream → components/stream}/renderers/candlestickCanvasRenderer.d.ts +0 -0
  162. /package/dist/{stream → components/stream}/renderers/connectorCanvasRenderer.d.ts +0 -0
  163. /package/dist/{stream → components/stream}/renderers/heatmapCanvasRenderer.d.ts +0 -0
  164. /package/dist/{stream → components/stream}/renderers/lineCanvasRenderer.d.ts +0 -0
  165. /package/dist/{stream → components/stream}/renderers/networkArcRenderer.d.ts +0 -0
  166. /package/dist/{stream → components/stream}/renderers/networkCircleRenderer.d.ts +0 -0
  167. /package/dist/{stream → components/stream}/renderers/networkEdgeRenderer.d.ts +0 -0
  168. /package/dist/{stream → components/stream}/renderers/networkParticleRenderer.d.ts +0 -0
  169. /package/dist/{stream → components/stream}/renderers/networkRectRenderer.d.ts +0 -0
  170. /package/dist/{stream → components/stream}/renderers/pointCanvasRenderer.d.ts +0 -0
  171. /package/dist/{stream → components/stream}/renderers/swarmCanvasRenderer.d.ts +0 -0
  172. /package/dist/{stream → components/stream}/renderers/types.d.ts +0 -0
  173. /package/dist/{stream → components/stream}/renderers/violinCanvasRenderer.d.ts +0 -0
  174. /package/dist/{stream → components/stream}/renderers/waterfallCanvasRenderer.d.ts +0 -0
  175. /package/dist/{stream → components/stream}/renderers/wedgeCanvasRenderer.d.ts +0 -0
  176. /package/dist/{stream → components/stream}/useResponsiveSize.d.ts +0 -0
  177. /package/dist/{types → components/types}/annotationTypes.d.ts +0 -0
  178. /package/dist/{types → components/types}/generalTypes.d.ts +0 -0
  179. /package/dist/{types → components/types}/interactionTypes.d.ts +0 -0
  180. /package/dist/{types → components/types}/networkTypes.d.ts +0 -0
  181. /package/dist/{types → components/types}/ordinalTypes.d.ts +0 -0
@@ -1,5 +1,6 @@
1
1
  import * as React from "react";
2
2
  import type { StreamXYFrameProps } from "../../stream/types";
3
+ import type { LegendInteractionMode } from "../shared/hooks";
3
4
  import type { BaseChartProps, AxisConfig, ChartAccessor } from "../shared/types";
4
5
  import { type TooltipProp } from "../../Tooltip/Tooltip";
5
6
  import type { AnomalyConfig, ForecastConfig } from "../shared/statisticalOverlays";
@@ -106,6 +107,13 @@ export interface LineChartProps<TDatum extends Record<string, any> = Record<stri
106
107
  * @default true (when multiple lines)
107
108
  */
108
109
  showLegend?: boolean;
110
+ /**
111
+ * Legend interaction mode.
112
+ * - "highlight": hover dims non-hovered categories to 30% opacity
113
+ * - "isolate": click toggles category visibility with checkmark indicators
114
+ * - "none": static legend (default)
115
+ */
116
+ legendInteraction?: LegendInteractionMode;
109
117
  /**
110
118
  * Tooltip configuration
111
119
  */
@@ -116,6 +124,24 @@ export interface LineChartProps<TDatum extends Record<string, any> = Record<stri
116
124
  * Annotation objects to render on the chart
117
125
  */
118
126
  annotations?: Record<string, any>[];
127
+ /**
128
+ * Place category labels directly at line endpoints instead of using a separate legend.
129
+ * When true, auto-hides the legend (override with `showLegend: true`).
130
+ * Pass an object for fine-grained control.
131
+ */
132
+ directLabel?: boolean | {
133
+ /** Where to place labels relative to the line. @default "end" */
134
+ position?: "end" | "start";
135
+ /** Font size for labels. @default 11 */
136
+ fontSize?: number;
137
+ };
138
+ /**
139
+ * How to handle null/undefined/NaN values in the data.
140
+ * - "break": break the line at gaps (default)
141
+ * - "interpolate": connect across gaps (skip missing points)
142
+ * - "zero": drop to zero at gap boundaries
143
+ */
144
+ gapStrategy?: "break" | "interpolate" | "zero";
119
145
  /**
120
146
  * Anomaly detection configuration. Highlights outlier points and shows
121
147
  * a shaded band representing the expected range (mean +/- threshold * stddev).
@@ -2,6 +2,7 @@ import * as React from "react";
2
2
  import type { StreamXYFrameProps, MarginalGraphicsConfig } from "../../stream/types";
3
3
  import type { BaseChartProps, AxisConfig, ChartAccessor } from "../shared/types";
4
4
  import { type TooltipProp } from "../../Tooltip/Tooltip";
5
+ import type { LegendInteractionMode } from "../shared/hooks";
5
6
  /**
6
7
  * Scatterplot component props
7
8
  */
@@ -36,6 +37,8 @@ export interface ScatterplotProps<TDatum extends Record<string, any> = Record<st
36
37
  marginalGraphics?: MarginalGraphicsConfig;
37
38
  /** Accessor for unique point IDs, used by point-anchored annotations */
38
39
  pointIdAccessor?: ChartAccessor<TDatum, string>;
40
+ /** Legend interaction mode */
41
+ legendInteraction?: LegendInteractionMode;
39
42
  /** Annotation objects to render on the chart */
40
43
  annotations?: Record<string, any>[];
41
44
  /** Additional StreamXYFrame props for advanced customization */
@@ -1,5 +1,6 @@
1
1
  import * as React from "react";
2
2
  import type { StreamXYFrameProps } from "../../stream/types";
3
+ import type { LegendInteractionMode } from "../shared/hooks";
3
4
  import type { BaseChartProps, AxisConfig, ChartAccessor } from "../shared/types";
4
5
  import { type TooltipProp } from "../../Tooltip/Tooltip";
5
6
  /**
@@ -93,6 +94,13 @@ export interface StackedAreaChartProps<TDatum extends Record<string, any> = Reco
93
94
  * @default true (when multiple areas)
94
95
  */
95
96
  showLegend?: boolean;
97
+ /**
98
+ * Legend interaction mode.
99
+ * - "highlight": hover dims non-hovered categories to 30% opacity
100
+ * - "isolate": click toggles category visibility with checkmark indicators
101
+ * - "none": static legend (default)
102
+ */
103
+ legendInteraction?: LegendInteractionMode;
96
104
  /**
97
105
  * Tooltip configuration
98
106
  */
@@ -1,5 +1,10 @@
1
1
  /**
2
- * Export a semiotic chart to SVG or PNG from the browser.
2
+ * Export a semiotic chart to PNG (default) or SVG from the browser.
3
+ *
4
+ * PNG export composites the canvas data layer underneath the SVG overlay,
5
+ * producing a complete image. SVG export captures only the SVG overlay
6
+ * (axes, labels, annotations) since canvas content cannot be represented
7
+ * as SVG.
3
8
  *
4
9
  * @example
5
10
  * ```tsx
@@ -0,0 +1,61 @@
1
+ export { LineChart } from "./charts/xy/LineChart";
2
+ export { AreaChart } from "./charts/xy/AreaChart";
3
+ export { StackedAreaChart } from "./charts/xy/StackedAreaChart";
4
+ export { Scatterplot } from "./charts/xy/Scatterplot";
5
+ export { ConnectedScatterplot } from "./charts/xy/ConnectedScatterplot";
6
+ export { BubbleChart } from "./charts/xy/BubbleChart";
7
+ export { Heatmap } from "./charts/xy/Heatmap";
8
+ export { ScatterplotMatrix } from "./charts/xy/ScatterplotMatrix";
9
+ export { LinkedCharts } from "./LinkedCharts";
10
+ export { useSelection, useLinkedHover, useBrushSelection, useFilteredData } from "./LinkedCharts";
11
+ export { BarChart } from "./charts/ordinal/BarChart";
12
+ export { StackedBarChart } from "./charts/ordinal/StackedBarChart";
13
+ export { GroupedBarChart } from "./charts/ordinal/GroupedBarChart";
14
+ export { SwarmPlot } from "./charts/ordinal/SwarmPlot";
15
+ export { BoxPlot } from "./charts/ordinal/BoxPlot";
16
+ export { Histogram } from "./charts/ordinal/Histogram";
17
+ export { ViolinPlot } from "./charts/ordinal/ViolinPlot";
18
+ export { DotPlot } from "./charts/ordinal/DotPlot";
19
+ export { RidgelinePlot } from "./charts/ordinal/RidgelinePlot";
20
+ export { PieChart } from "./charts/ordinal/PieChart";
21
+ export { DonutChart } from "./charts/ordinal/DonutChart";
22
+ export { ForceDirectedGraph } from "./charts/network/ForceDirectedGraph";
23
+ export { ChordDiagram } from "./charts/network/ChordDiagram";
24
+ export { SankeyDiagram } from "./charts/network/SankeyDiagram";
25
+ export { TreeDiagram } from "./charts/network/TreeDiagram";
26
+ export { Treemap } from "./charts/network/Treemap";
27
+ export { CirclePack } from "./charts/network/CirclePack";
28
+ export { OrbitDiagram } from "./charts/network/OrbitDiagram";
29
+ export { RealtimeLineChart } from "./charts/realtime/RealtimeLineChart";
30
+ export { RealtimeHistogram } from "./charts/realtime/RealtimeHistogram";
31
+ export { RealtimeSwarmChart } from "./charts/realtime/RealtimeSwarmChart";
32
+ export { RealtimeWaterfallChart } from "./charts/realtime/RealtimeWaterfallChart";
33
+ export { RealtimeHeatmap } from "./charts/realtime/RealtimeHeatmap";
34
+ export { TooltipProvider } from "./store/TooltipStore";
35
+ export { MultiLineTooltip } from "./Tooltip/Tooltip";
36
+ export { ThemeProvider, useTheme } from "./ThemeProvider";
37
+ export { exportChart } from "./export/exportChart";
38
+ export { ChartContainer } from "./ChartContainer";
39
+ export type { ChartContainerProps, ChartContainerHandle } from "./ChartContainer";
40
+ export { ChartGrid } from "./ChartGrid";
41
+ export type { ChartGridProps } from "./ChartGrid";
42
+ export { ContextLayout } from "./ContextLayout";
43
+ export type { ContextLayoutProps } from "./ContextLayout";
44
+ export { CategoryColorProvider, useCategoryColors } from "./CategoryColors";
45
+ export type { CategoryColorMap, CategoryColorProviderProps } from "./CategoryColors";
46
+ export { DetailsPanel } from "./DetailsPanel";
47
+ export type { DetailsPanelProps } from "./DetailsPanel";
48
+ export { validateProps } from "./charts/shared/validateProps";
49
+ export type { ValidationResult } from "./charts/shared/validateProps";
50
+ export { diagnoseConfig } from "./charts/shared/diagnoseConfig";
51
+ export type { Diagnosis, DiagnosisResult } from "./charts/shared/diagnoseConfig";
52
+ export type { AnomalyConfig, ForecastConfig } from "./charts/shared/statisticalOverlays";
53
+ export { toConfig, fromConfig, toURL, fromURL, copyConfig, configToJSX } from "./export/chartConfig";
54
+ export type { ChartConfig, ToConfigOptions, CopyFormat } from "./export/chartConfig";
55
+ export { serializeSelections, deserializeSelections } from "./export/selectionSerializer";
56
+ export type { SerializedSelections, SerializedSelection, SerializedFieldSelection } from "./export/selectionSerializer";
57
+ export { fromVegaLite } from "./data/fromVegaLite";
58
+ export type { VegaLiteSpec, VegaLiteEncoding } from "./data/fromVegaLite";
59
+ export { useChartObserver } from "./store/useObservation";
60
+ export type { UseChartObserverOptions, UseChartObserverResult } from "./store/useObservation";
61
+ export type { ChartObservation, OnObservationCallback, HoverObservation, HoverEndObservation, BrushObservation, BrushEndObservation, SelectionObservation, SelectionEndObservation, ClickObservation, ClickEndObservation } from "./store/ObservationStore";
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Semiotic data transform utilities.
3
+ * Import from "semiotic/data"
4
+ */
5
+ export { bin, rollup, groupBy, pivot } from "./data/transforms";
6
+ export { fromVegaLite } from "./data/fromVegaLite";
7
+ export type { VegaLiteSpec, VegaLiteEncoding } from "./data/fromVegaLite";
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Network entry point — force graphs, sankey, chord, trees, treemaps, circle packing.
3
+ * Import from "semiotic/network" instead of the full bundle to reduce bundle size.
4
+ */
5
+ import StreamNetworkFrame from "./stream/StreamNetworkFrame";
6
+ export { StreamNetworkFrame };
7
+ export { ForceDirectedGraph } from "./charts/network/ForceDirectedGraph";
8
+ export { SankeyDiagram } from "./charts/network/SankeyDiagram";
9
+ export { ChordDiagram } from "./charts/network/ChordDiagram";
10
+ export { TreeDiagram } from "./charts/network/TreeDiagram";
11
+ export { Treemap } from "./charts/network/Treemap";
12
+ export { CirclePack } from "./charts/network/CirclePack";
13
+ export { OrbitDiagram } from "./charts/network/OrbitDiagram";
14
+ export type { StreamNetworkFrameProps, StreamNetworkFrameHandle, NetworkChartType, NetworkSceneNode, NetworkSceneEdge, NetworkLabel, ThresholdAlertConfig } from "./stream/networkTypes";
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Ordinal entry point — bar charts, pie charts, distribution charts.
3
+ * Import from "semiotic/ordinal" instead of the full bundle to reduce bundle size.
4
+ */
5
+ import StreamOrdinalFrame from "./stream/StreamOrdinalFrame";
6
+ export { StreamOrdinalFrame };
7
+ export { BarChart } from "./charts/ordinal/BarChart";
8
+ export { StackedBarChart } from "./charts/ordinal/StackedBarChart";
9
+ export { GroupedBarChart } from "./charts/ordinal/GroupedBarChart";
10
+ export { SwarmPlot } from "./charts/ordinal/SwarmPlot";
11
+ export { BoxPlot } from "./charts/ordinal/BoxPlot";
12
+ export { Histogram } from "./charts/ordinal/Histogram";
13
+ export { ViolinPlot } from "./charts/ordinal/ViolinPlot";
14
+ export { DotPlot } from "./charts/ordinal/DotPlot";
15
+ export { PieChart } from "./charts/ordinal/PieChart";
16
+ export { DonutChart } from "./charts/ordinal/DonutChart";
17
+ export { RidgelinePlot } from "./charts/ordinal/RidgelinePlot";
18
+ export type { StreamOrdinalFrameProps, StreamOrdinalFrameHandle, OrdinalChartType, OrdinalScales, OrdinalSceneNode } from "./stream/ordinalTypes";
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Realtime entry point — for streaming/realtime canvas-first visualizations.
3
+ * Import from "semiotic/realtime" instead of the full bundle to reduce bundle size.
4
+ */
5
+ import StreamXYFrame from "./stream/StreamXYFrame";
6
+ import StreamNetworkFrame from "./stream/StreamNetworkFrame";
7
+ import { RingBuffer } from "./realtime/RingBuffer";
8
+ import { IncrementalExtent } from "./realtime/IncrementalExtent";
9
+ import { RealtimeLineChart } from "./charts/realtime/RealtimeLineChart";
10
+ import { RealtimeHistogram } from "./charts/realtime/RealtimeHistogram";
11
+ import { RealtimeSwarmChart } from "./charts/realtime/RealtimeSwarmChart";
12
+ import { RealtimeWaterfallChart } from "./charts/realtime/RealtimeWaterfallChart";
13
+ import { RealtimeHeatmap } from "./charts/realtime/RealtimeHeatmap";
14
+ export { StreamXYFrame, StreamNetworkFrame, RingBuffer, IncrementalExtent, RealtimeLineChart, RealtimeHistogram, RealtimeSwarmChart, RealtimeWaterfallChart, RealtimeHeatmap };
15
+ export type { RealtimeLineChartProps } from "./charts/realtime/RealtimeLineChart";
16
+ export type { RealtimeHistogramProps } from "./charts/realtime/RealtimeHistogram";
17
+ export type { RealtimeSwarmChartProps } from "./charts/realtime/RealtimeSwarmChart";
18
+ export type { RealtimeWaterfallChartProps } from "./charts/realtime/RealtimeWaterfallChart";
19
+ export type { RealtimeHeatmapProps } from "./charts/realtime/RealtimeHeatmap";
20
+ export type { ArrowOfTime, WindowMode, ThresholdType, LineStyle, BarStyle, WaterfallStyle, SwarmStyle, AnnotationContext, CrosshairStyle, HoverAnnotationConfig, HoverData } from "./realtime/types";
21
+ export type { StreamXYFrameProps, StreamXYFrameHandle, StreamChartType } from "./stream/types";
22
+ export type { StreamNetworkFrameProps, StreamNetworkFrameHandle, NetworkChartType } from "./stream/networkTypes";
@@ -0,0 +1 @@
1
+ export { renderToStaticSVG, renderXYToStaticSVG, renderOrdinalToStaticSVG, renderNetworkToStaticSVG } from "./server/renderToStaticSVG";
@@ -0,0 +1,16 @@
1
+ /**
2
+ * XY entry point — line, area, scatter, heatmap, and bubble charts.
3
+ * Import from "semiotic/xy" instead of the full bundle to reduce bundle size.
4
+ */
5
+ import StreamXYFrame from "./stream/StreamXYFrame";
6
+ export { StreamXYFrame };
7
+ export { LineChart } from "./charts/xy/LineChart";
8
+ export { AreaChart } from "./charts/xy/AreaChart";
9
+ export { StackedAreaChart } from "./charts/xy/StackedAreaChart";
10
+ export { Scatterplot } from "./charts/xy/Scatterplot";
11
+ export { ConnectedScatterplot } from "./charts/xy/ConnectedScatterplot";
12
+ export { BubbleChart } from "./charts/xy/BubbleChart";
13
+ export { Heatmap } from "./charts/xy/Heatmap";
14
+ export { ScatterplotMatrix } from "./charts/xy/ScatterplotMatrix";
15
+ export { MinimapChart } from "./charts/xy/MinimapChart";
16
+ export type { StreamXYFrameProps, StreamXYFrameHandle } from "./stream/types";
@@ -0,0 +1,57 @@
1
+ import StreamXYFrame from "./stream/StreamXYFrame";
2
+ import StreamOrdinalFrame from "./stream/StreamOrdinalFrame";
3
+ import StreamNetworkFrame from "./stream/StreamNetworkFrame";
4
+ import { Scatterplot, ConnectedScatterplot, LineChart, AreaChart, StackedAreaChart, Heatmap, BubbleChart, BarChart, StackedBarChart, SwarmPlot, BoxPlot, Histogram, ViolinPlot, RidgelinePlot, DotPlot, PieChart, DonutChart, GroupedBarChart, ForceDirectedGraph, ChordDiagram, SankeyDiagram, TreeDiagram, Treemap, CirclePack, OrbitDiagram, ScatterplotMatrix, MinimapChart } from "./charts";
5
+ import { LinkedCharts } from "./LinkedCharts";
6
+ import { ThemeProvider, useTheme } from "./ThemeProvider";
7
+ import { exportChart } from "./export/exportChart";
8
+ import { toConfig, fromConfig, toURL, fromURL, copyConfig, configToJSX } from "./export/chartConfig";
9
+ import { serializeSelections, deserializeSelections } from "./export/selectionSerializer";
10
+ import { fromVegaLite } from "./data/fromVegaLite";
11
+ import { ChartErrorBoundary } from "./ChartErrorBoundary";
12
+ import { ChartContainer } from "./ChartContainer";
13
+ import { ChartGrid } from "./ChartGrid";
14
+ import { CategoryColorProvider, useCategoryColors } from "./CategoryColors";
15
+ import { ContextLayout } from "./ContextLayout";
16
+ import { DetailsPanel } from "./DetailsPanel";
17
+ import { Tooltip, MultiLineTooltip, normalizeTooltip } from "./Tooltip/Tooltip";
18
+ import { RingBuffer } from "./realtime/RingBuffer";
19
+ import { IncrementalExtent } from "./realtime/IncrementalExtent";
20
+ import { RealtimeLineChart } from "./charts/realtime/RealtimeLineChart";
21
+ import { RealtimeTemporalHistogram, RealtimeHistogram } from "./charts/realtime/RealtimeHistogram";
22
+ import { RealtimeSwarmChart } from "./charts/realtime/RealtimeSwarmChart";
23
+ import { RealtimeWaterfallChart } from "./charts/realtime/RealtimeWaterfallChart";
24
+ import { RealtimeHeatmap } from "./charts/realtime/RealtimeHeatmap";
25
+ export { StreamXYFrame, StreamOrdinalFrame, StreamNetworkFrame, Scatterplot, ConnectedScatterplot, LineChart, AreaChart, StackedAreaChart, Heatmap, BubbleChart, BarChart, StackedBarChart, SwarmPlot, BoxPlot, Histogram, ViolinPlot, RidgelinePlot, DotPlot, ForceDirectedGraph, ChordDiagram, SankeyDiagram, TreeDiagram, PieChart, DonutChart, GroupedBarChart, Treemap, CirclePack, OrbitDiagram, ScatterplotMatrix, MinimapChart, LinkedCharts, ThemeProvider, useTheme, exportChart, toConfig, fromConfig, toURL, fromURL, copyConfig, configToJSX, serializeSelections, deserializeSelections, fromVegaLite, ChartErrorBoundary, ChartContainer, ChartGrid, CategoryColorProvider, useCategoryColors, ContextLayout, DetailsPanel, Tooltip, MultiLineTooltip, normalizeTooltip, RingBuffer, IncrementalExtent, RealtimeLineChart, RealtimeTemporalHistogram, RealtimeHistogram, RealtimeSwarmChart, RealtimeWaterfallChart, RealtimeHeatmap };
26
+ export { ScatterplotProps, ConnectedScatterplotProps, LineChartProps, AreaChartProps, StackedAreaChartProps, HeatmapProps, BubbleChartProps, BarChartProps, StackedBarChartProps, SwarmPlotProps, BoxPlotProps, HistogramProps, ViolinPlotProps, DotPlotProps, PieChartProps, DonutChartProps, GroupedBarChartProps, RidgelinePlotProps, OrbitDiagramProps, OrbitNode, ForceDirectedGraphProps, ChordDiagramProps, SankeyDiagramProps, TreeDiagramProps, TreemapProps, CirclePackProps, ScatterplotMatrixProps, MinimapChartProps, MinimapConfig, BaseChartProps, AxisConfig, Accessor, ChartAccessor, ChartMode } from "./charts";
27
+ export type { StreamXYFrameProps, StreamXYFrameHandle, StreamChartType, RuntimeMode, SceneNode, Changeset, StreamScales, StreamLayout, CurveType, CanvasRendererFn } from "./stream/types";
28
+ export type { StreamRendererFn } from "./stream/renderers/types";
29
+ export type { StreamOrdinalFrameProps, StreamOrdinalFrameHandle, OrdinalChartType, OrdinalScales, OrdinalSceneNode } from "./stream/ordinalTypes";
30
+ export type { StreamNetworkFrameProps, StreamNetworkFrameHandle, NetworkChartType, NetworkSceneNode, NetworkSceneEdge, NetworkLabel, ThresholdAlertConfig } from "./stream/networkTypes";
31
+ export type { SelectionConfig, LinkedHoverProp, LinkedBrushProp } from "./charts/shared/types";
32
+ export type { LinkedChartsProps } from "./LinkedCharts";
33
+ export { useSelection, useLinkedHover, useBrushSelection, useFilteredData } from "./LinkedCharts";
34
+ export type { UseSelectionOptions, UseSelectionResult, UseLinkedHoverOptions, UseLinkedHoverResult, UseBrushSelectionOptions, UseBrushSelectionResult } from "./LinkedCharts";
35
+ export { useChartObserver } from "./LinkedCharts";
36
+ export type { UseChartObserverOptions, UseChartObserverResult } from "./LinkedCharts";
37
+ export type { ChartObservation, OnObservationCallback } from "./store/ObservationStore";
38
+ export type { ResolutionMode, SelectionClause, Selection } from "./store/SelectionStore";
39
+ export type { SemioticTheme } from "./ThemeProvider";
40
+ export { LIGHT_THEME, DARK_THEME } from "./ThemeProvider";
41
+ export type { ChartErrorBoundaryProps } from "./ChartErrorBoundary";
42
+ export type { ChartContainerProps, ChartContainerHandle } from "./ChartContainer";
43
+ export type { ChartGridProps } from "./ChartGrid";
44
+ export type { CategoryColorMap, CategoryColorProviderProps } from "./CategoryColors";
45
+ export type { ContextLayoutProps } from "./ContextLayout";
46
+ export type { DetailsPanelProps } from "./DetailsPanel";
47
+ export type { ChartConfig, ToConfigOptions, CopyFormat } from "./export/chartConfig";
48
+ export type { VegaLiteSpec, VegaLiteEncoding } from "./data/fromVegaLite";
49
+ export type { SerializedSelections, SerializedSelection, SerializedFieldSelection } from "./export/selectionSerializer";
50
+ export { smartTickFormat } from "./charts/shared/formatUtils";
51
+ export type { TooltipProp, TooltipConfig, TooltipField, MultiLineTooltipConfig } from "./Tooltip/Tooltip";
52
+ export type { ArrowOfTime, WindowMode, ThresholdType, LineStyle, BarStyle, WaterfallStyle, SwarmStyle, AnnotationContext, CrosshairStyle, HoverAnnotationConfig, HoverData } from "./realtime/types";
53
+ export type { RealtimeLineChartProps } from "./charts/realtime/RealtimeLineChart";
54
+ export type { RealtimeTemporalHistogramProps, RealtimeHistogramProps } from "./charts/realtime/RealtimeHistogram";
55
+ export type { RealtimeSwarmChartProps } from "./charts/realtime/RealtimeSwarmChart";
56
+ export type { RealtimeWaterfallChartProps } from "./charts/realtime/RealtimeWaterfallChart";
57
+ export type { RealtimeHeatmapProps } from "./charts/realtime/RealtimeHeatmap";
@@ -1,3 +1,10 @@
1
+ /**
2
+ * Server-side rendering of Semiotic charts to standalone SVG strings.
3
+ *
4
+ * Uses the shared SceneToSVG converters (same code used by Stream Frames
5
+ * for SSR) plus PipelineStore / OrdinalPipelineStore / NetworkPipelineStore
6
+ * for scene graph computation.
7
+ */
1
8
  import type { StreamXYFrameProps } from "../stream/types";
2
9
  import type { StreamNetworkFrameProps } from "../stream/networkTypes";
3
10
  import type { StreamOrdinalFrameProps } from "../stream/ordinalTypes";
@@ -21,8 +21,28 @@ export interface NetworkSVGOverlayProps {
21
21
  legend?: ReactNode | {
22
22
  legendGroups: LegendGroup[];
23
23
  };
24
+ legendHoverBehavior?: (item: {
25
+ label: string;
26
+ } | null) => void;
27
+ legendClickBehavior?: (item: {
28
+ label: string;
29
+ }) => void;
30
+ legendHighlightedCategory?: string | null;
31
+ legendIsolatedCategories?: Set<string>;
24
32
  /** User-provided SVG elements on top */
25
33
  foregroundGraphics?: ReactNode;
34
+ /** Scene nodes for annotation positioning */
35
+ sceneNodes?: Array<{
36
+ type: string;
37
+ datum: any;
38
+ id?: string;
39
+ x?: number;
40
+ y?: number;
41
+ cx?: number;
42
+ cy?: number;
43
+ w?: number;
44
+ h?: number;
45
+ }>;
26
46
  /** Annotations */
27
47
  annotations?: Record<string, any>[];
28
48
  svgAnnotationRules?: (annotation: Record<string, any>, index: number, context: any) => ReactNode;
@@ -25,6 +25,14 @@ interface OrdinalSVGOverlayProps {
25
25
  legend?: ReactNode | {
26
26
  legendGroups: LegendGroup[];
27
27
  };
28
+ legendHoverBehavior?: (item: {
29
+ label: string;
30
+ } | null) => void;
31
+ legendClickBehavior?: (item: {
32
+ label: string;
33
+ }) => void;
34
+ legendHighlightedCategory?: string | null;
35
+ legendIsolatedCategories?: Set<string>;
28
36
  foregroundGraphics?: ReactNode;
29
37
  annotations?: Record<string, any>[];
30
38
  svgAnnotationRules?: (annotation: Record<string, any>, index: number, context: AnnotationContext) => ReactNode;
@@ -92,6 +92,8 @@ export declare class PipelineStore {
92
92
  } | null;
93
93
  private prevPositionMap;
94
94
  lastIngestTime: number;
95
+ private needsFullRebuild;
96
+ private lastLayout;
95
97
  scales: StreamScales | null;
96
98
  scene: SceneNode[];
97
99
  version: number;
@@ -105,6 +107,11 @@ export declare class PipelineStore {
105
107
  * Recompute scales and scene graph for the current buffer contents.
106
108
  */
107
109
  computeScene(layout: StreamLayout): void;
110
+ /**
111
+ * Remap existing scene node coordinates for a new layout size.
112
+ * Proportionally scales all pixel coordinates without rebuilding from data.
113
+ */
114
+ private remapScene;
108
115
  private buildSceneNodes;
109
116
  private buildLineScene;
110
117
  private buildAreaScene;
@@ -10,6 +10,9 @@ export interface AxisConfig {
10
10
  tickFormat?: (d: any) => string;
11
11
  baseline?: boolean | "under";
12
12
  jaggedBase?: boolean;
13
+ /** Highlight ticks at time boundaries (new month, year, etc.) with semibold text.
14
+ * `true` auto-detects Date boundaries. A function receives (value, index) and returns true for landmark ticks. */
15
+ landmarkTicks?: boolean | ((value: any, index: number) => boolean);
13
16
  }
14
17
  interface SVGOverlayProps {
15
18
  width: number;
@@ -34,6 +37,18 @@ interface SVGOverlayProps {
34
37
  legend?: ReactNode | {
35
38
  legendGroups: LegendGroup[];
36
39
  };
40
+ /** Callback when hovering a legend item */
41
+ legendHoverBehavior?: (item: {
42
+ label: string;
43
+ } | null) => void;
44
+ /** Callback when clicking a legend item */
45
+ legendClickBehavior?: (item: {
46
+ label: string;
47
+ }) => void;
48
+ /** Currently highlighted category label (for hover dimming) */
49
+ legendHighlightedCategory?: string | null;
50
+ /** Set of isolated category labels (for click isolation) */
51
+ legendIsolatedCategories?: Set<string>;
37
52
  foregroundGraphics?: ReactNode;
38
53
  marginalGraphics?: MarginalGraphicsConfig;
39
54
  xValues?: number[];
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Scene graph → SVG element converters.
3
+ *
4
+ * Shared module used by Stream Frames for SSR rendering and
5
+ * by semiotic/server for static SVG export.
6
+ */
7
+ import * as React from "react";
8
+ import type { SceneNode } from "./types";
9
+ import type { NetworkSceneNode, NetworkSceneEdge, NetworkLabel } from "./networkTypes";
10
+ import type { OrdinalSceneNode } from "./ordinalTypes";
11
+ export declare function xySceneNodeToSVG(node: SceneNode, i: number): React.ReactNode;
12
+ export declare function networkSceneNodeToSVG(node: NetworkSceneNode, i: number): React.ReactNode;
13
+ export declare function networkSceneEdgeToSVG(edge: NetworkSceneEdge, i: number): React.ReactNode;
14
+ export declare function networkLabelToSVG(label: NetworkLabel, i: number): React.ReactNode;
15
+ export declare function ordinalSceneNodeToSVG(node: OrdinalSceneNode, i: number): React.ReactNode;
16
+ /**
17
+ * Returns true when running in a true server/Node.js context where
18
+ * window and document are not available.
19
+ */
20
+ export declare const isServerEnvironment: boolean;
@@ -0,0 +1,23 @@
1
+ /**
2
+ * Shared hit-testing utilities used by CanvasHitTester, OrdinalCanvasHitTester,
3
+ * and NetworkCanvasHitTester.
4
+ */
5
+ export interface RectHitResult {
6
+ hit: boolean;
7
+ cx: number;
8
+ cy: number;
9
+ }
10
+ /**
11
+ * Test whether a point (px, py) falls within a rectangle defined by
12
+ * { x, y, w, h } and return the rectangle's center coordinates.
13
+ */
14
+ export declare function hitTestRect(px: number, py: number, node: {
15
+ x: number;
16
+ y: number;
17
+ w: number;
18
+ h: number;
19
+ }): RectHitResult;
20
+ /**
21
+ * Normalize an angle to the [0, 2π) range.
22
+ */
23
+ export declare function normalizeAngle(angle: number): number;
@@ -284,7 +284,7 @@ export interface NetworkPipelineConfig {
284
284
  edgeStyle?: (d: any) => Record<string, any>;
285
285
  nodeLabel?: string | ((d: any) => string);
286
286
  showLabels?: boolean;
287
- colorBy?: string | ((d: any) => string);
287
+ colorBy?: string | ((d: any) => string | number);
288
288
  colorScheme?: string | string[];
289
289
  edgeColorBy?: "source" | "target" | "gradient" | ((d: any) => string);
290
290
  edgeOpacity?: number;
@@ -328,7 +328,7 @@ export interface StreamNetworkFrameProps<T = Record<string, any>> {
328
328
  particleStyle?: ParticleStyle;
329
329
  nodeStyle?: (d: any) => Record<string, any>;
330
330
  edgeStyle?: (d: any) => Record<string, any>;
331
- colorBy?: string | ((d: any) => string);
331
+ colorBy?: string | ((d: any) => string | number);
332
332
  colorScheme?: string | string[];
333
333
  edgeColorBy?: "source" | "target" | "gradient" | ((d: any) => string);
334
334
  edgeOpacity?: number;
@@ -377,6 +377,14 @@ export interface StreamNetworkFrameProps<T = Record<string, any>> {
377
377
  legend?: ReactNode | {
378
378
  legendGroups: LegendGroup[];
379
379
  };
380
+ legendHoverBehavior?: (item: {
381
+ label: string;
382
+ } | null) => void;
383
+ legendClickBehavior?: (item: {
384
+ label: string;
385
+ }) => void;
386
+ legendHighlightedCategory?: string | null;
387
+ legendIsolatedCategories?: Set<string>;
380
388
  title?: string | ReactNode;
381
389
  foregroundGraphics?: ReactNode;
382
390
  backgroundGraphics?: ReactNode;
@@ -20,6 +20,10 @@ export interface WedgeSceneNode {
20
20
  style: Style;
21
21
  datum: any;
22
22
  category?: string;
23
+ /** Pulse intensity 0–1 (set when aggregated category value changes) */
24
+ _pulseIntensity?: number;
25
+ /** Pulse color */
26
+ _pulseColor?: string;
23
27
  }
24
28
  export interface BoxplotSceneNode {
25
29
  type: "boxplot";
@@ -35,13 +39,7 @@ export interface BoxplotSceneNode {
35
39
  medianPos: number;
36
40
  q3Pos: number;
37
41
  maxPos: number;
38
- stats: {
39
- min: number;
40
- q1: number;
41
- median: number;
42
- q3: number;
43
- max: number;
44
- };
42
+ stats: DistributionStats;
45
43
  style: Style;
46
44
  datum: any;
47
45
  category?: string;
@@ -141,7 +139,7 @@ export interface OrdinalPipelineConfig {
141
139
  showOutliers?: boolean;
142
140
  showIQR?: boolean;
143
141
  amplitude?: number;
144
- oSort?: ((a: string, b: string) => number) | boolean | "asc" | "desc";
142
+ oSort?: ((a: any, b: any) => number) | boolean | "asc" | "desc";
145
143
  connectorAccessor?: string | ((d: any) => string);
146
144
  connectorStyle?: Style | ((d: any) => Style);
147
145
  dynamicColumnWidth?: string | ((data: any[]) => number);
@@ -189,7 +187,7 @@ export interface StreamOrdinalFrameProps<T = Record<string, any>> {
189
187
  rExtent?: [number?, number?];
190
188
  oExtent?: string[];
191
189
  extentPadding?: number;
192
- oSort?: ((a: string, b: string) => number) | boolean | "asc" | "desc";
190
+ oSort?: ((a: any, b: any) => number) | boolean | "asc" | "desc";
193
191
  arrowOfTime?: ArrowOfTime;
194
192
  windowMode?: WindowMode;
195
193
  windowSize?: number;
@@ -203,7 +201,7 @@ export interface StreamOrdinalFrameProps<T = Record<string, any>> {
203
201
  oLabel?: string;
204
202
  rLabel?: string;
205
203
  oFormat?: (d: string) => string;
206
- rFormat?: (d: number) => string;
204
+ rFormat?: (d: number | string) => string;
207
205
  enableHover?: boolean;
208
206
  hoverAnnotation?: boolean | HoverAnnotationConfig;
209
207
  tooltipContent?: (d: HoverData) => ReactNode;
@@ -214,6 +212,14 @@ export interface StreamOrdinalFrameProps<T = Record<string, any>> {
214
212
  legend?: ReactNode | {
215
213
  legendGroups: LegendGroup[];
216
214
  };
215
+ legendHoverBehavior?: (item: {
216
+ label: string;
217
+ } | null) => void;
218
+ legendClickBehavior?: (item: {
219
+ label: string;
220
+ }) => void;
221
+ legendHighlightedCategory?: string | null;
222
+ legendIsolatedCategories?: Set<string>;
217
223
  backgroundGraphics?: ReactNode;
218
224
  foregroundGraphics?: ReactNode;
219
225
  title?: string | ReactNode;
@@ -0,0 +1,2 @@
1
+ import type { StreamRendererFn } from "./types";
2
+ export declare const areaCanvasRenderer: StreamRendererFn;
@@ -99,6 +99,10 @@ export interface AreaSceneNode {
99
99
  };
100
100
  /** When false, skip hit testing (used for decorative bounds areas) */
101
101
  interactive?: boolean;
102
+ /** Pulse intensity 0–1 (set when aggregated group value changes) */
103
+ _pulseIntensity?: number;
104
+ /** Pulse color */
105
+ _pulseColor?: string;
102
106
  }
103
107
  export interface PointSceneNode {
104
108
  type: "point";
@@ -307,6 +311,14 @@ export interface StreamXYFrameProps<T = Record<string, any>> {
307
311
  legend?: ReactNode | {
308
312
  legendGroups: any[];
309
313
  };
314
+ legendHoverBehavior?: (item: {
315
+ label: string;
316
+ } | null) => void;
317
+ legendClickBehavior?: (item: {
318
+ label: string;
319
+ }) => void;
320
+ legendHighlightedCategory?: string | null;
321
+ legendIsolatedCategories?: Set<string>;
310
322
  /** SVG elements rendered behind the canvas (in pixel space) */
311
323
  backgroundGraphics?: ReactNode;
312
324
  /** SVG elements rendered on top of everything (in SVG overlay) */
@@ -0,0 +1,16 @@
1
+ import type { StalenessConfig } from "./types";
2
+ interface StoreWithIngestTime {
3
+ lastIngestTime: number;
4
+ }
5
+ /**
6
+ * Shared hook that polls a store's `lastIngestTime` on a 1-second interval
7
+ * and manages staleness state. When staleness changes it sets
8
+ * `dirtyRef.current = true` and calls `scheduleRender()` so the canvas
9
+ * repaints with the appropriate dimming.
10
+ *
11
+ * Call this hook after `storeRef`, `dirtyRef`, and `scheduleRender` are
12
+ * declared. The `isStale` / `setIsStale` state must live in the caller
13
+ * so that the `useState` call order stays unchanged.
14
+ */
15
+ export declare function useStalenessCheck(staleness: StalenessConfig | undefined, storeRef: React.RefObject<StoreWithIngestTime | null>, dirtyRef: React.MutableRefObject<boolean>, scheduleRender: () => void, isStale: boolean, setIsStale: (stale: boolean) => void): void;
16
+ export {};
@@ -12,6 +12,11 @@ export interface LegendGroup {
12
12
  export interface LegendProps {
13
13
  legendGroups?: LegendGroup[];
14
14
  customClickBehavior?: Function;
15
+ customHoverBehavior?: (item: LegendItem | null) => void;
16
+ /** Set of currently isolated category labels (shown with checkmarks) */
17
+ isolatedCategories?: Set<string>;
18
+ /** Whether hover-highlighting is active (dims non-hovered items) */
19
+ highlightedCategory?: string | null;
15
20
  title?: string;
16
21
  width?: number;
17
22
  height?: number;