@sqlrooms/mosaic 0.29.0-rc.1 → 0.29.0-rc.3

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 (398) hide show
  1. package/README.md +161 -2
  2. package/dist/MosaicChart.d.ts +20 -0
  3. package/dist/MosaicChart.d.ts.map +1 -0
  4. package/dist/MosaicChart.js +25 -0
  5. package/dist/MosaicChart.js.map +1 -0
  6. package/dist/MosaicChartBuilder.d.ts +67 -0
  7. package/dist/MosaicChartBuilder.d.ts.map +1 -0
  8. package/dist/MosaicChartBuilder.js +33 -0
  9. package/dist/MosaicChartBuilder.js.map +1 -0
  10. package/dist/MosaicColorLegend.d.ts +18 -0
  11. package/dist/MosaicColorLegend.d.ts.map +1 -0
  12. package/dist/MosaicColorLegend.js +117 -0
  13. package/dist/MosaicColorLegend.js.map +1 -0
  14. package/dist/MosaicSlice.d.ts +27 -13
  15. package/dist/MosaicSlice.d.ts.map +1 -1
  16. package/dist/MosaicSlice.js +140 -42
  17. package/dist/MosaicSlice.js.map +1 -1
  18. package/dist/ResponsivePlot.d.ts +23 -0
  19. package/dist/ResponsivePlot.d.ts.map +1 -0
  20. package/dist/ResponsivePlot.js +43 -0
  21. package/dist/ResponsivePlot.js.map +1 -0
  22. package/dist/VgPlotChart.d.ts +24 -0
  23. package/dist/VgPlotChart.d.ts.map +1 -1
  24. package/dist/VgPlotChart.js +127 -21
  25. package/dist/VgPlotChart.js.map +1 -1
  26. package/dist/chart-builders/ChartBuilderActions.d.ts +6 -0
  27. package/dist/chart-builders/ChartBuilderActions.d.ts.map +1 -0
  28. package/dist/chart-builders/ChartBuilderActions.js +28 -0
  29. package/dist/chart-builders/ChartBuilderActions.js.map +1 -0
  30. package/dist/chart-builders/ChartBuilderContent.d.ts +28 -0
  31. package/dist/chart-builders/ChartBuilderContent.d.ts.map +1 -0
  32. package/dist/chart-builders/ChartBuilderContent.js +28 -0
  33. package/dist/chart-builders/ChartBuilderContent.js.map +1 -0
  34. package/dist/chart-builders/ChartBuilderContext.d.ts +16 -0
  35. package/dist/chart-builders/ChartBuilderContext.d.ts.map +1 -0
  36. package/dist/chart-builders/ChartBuilderContext.js +15 -0
  37. package/dist/chart-builders/ChartBuilderContext.js.map +1 -0
  38. package/dist/chart-builders/ChartBuilderDialog.d.ts +48 -0
  39. package/dist/chart-builders/ChartBuilderDialog.d.ts.map +1 -0
  40. package/dist/chart-builders/ChartBuilderDialog.js +30 -0
  41. package/dist/chart-builders/ChartBuilderDialog.js.map +1 -0
  42. package/dist/chart-builders/ChartBuilderFields.d.ts +6 -0
  43. package/dist/chart-builders/ChartBuilderFields.d.ts.map +1 -0
  44. package/dist/chart-builders/ChartBuilderFields.js +25 -0
  45. package/dist/chart-builders/ChartBuilderFields.js.map +1 -0
  46. package/dist/chart-builders/ChartBuilderRoot.d.ts +27 -0
  47. package/dist/chart-builders/ChartBuilderRoot.d.ts.map +1 -0
  48. package/dist/chart-builders/ChartBuilderRoot.js +61 -0
  49. package/dist/chart-builders/ChartBuilderRoot.js.map +1 -0
  50. package/dist/chart-builders/ChartBuilderTypeGrid.d.ts +7 -0
  51. package/dist/chart-builders/ChartBuilderTypeGrid.d.ts.map +1 -0
  52. package/dist/chart-builders/ChartBuilderTypeGrid.js +23 -0
  53. package/dist/chart-builders/ChartBuilderTypeGrid.js.map +1 -0
  54. package/dist/chart-builders/FieldSelectorInput.d.ts +13 -0
  55. package/dist/chart-builders/FieldSelectorInput.d.ts.map +1 -0
  56. package/dist/chart-builders/FieldSelectorInput.js +19 -0
  57. package/dist/chart-builders/FieldSelectorInput.js.map +1 -0
  58. package/dist/chart-builders/builders.d.ts +34 -0
  59. package/dist/chart-builders/builders.d.ts.map +1 -0
  60. package/dist/chart-builders/builders.js +51 -0
  61. package/dist/chart-builders/builders.js.map +1 -0
  62. package/dist/chart-builders/chartSpecTitle.d.ts +6 -0
  63. package/dist/chart-builders/chartSpecTitle.d.ts.map +1 -0
  64. package/dist/chart-builders/chartSpecTitle.js +8 -0
  65. package/dist/chart-builders/chartSpecTitle.js.map +1 -0
  66. package/dist/chart-builders/chartTypeUtils.d.ts +17 -0
  67. package/dist/chart-builders/chartTypeUtils.d.ts.map +1 -0
  68. package/dist/chart-builders/chartTypeUtils.js +55 -0
  69. package/dist/chart-builders/chartTypeUtils.js.map +1 -0
  70. package/dist/chart-builders/constants.d.ts +7 -0
  71. package/dist/chart-builders/constants.d.ts.map +1 -0
  72. package/dist/chart-builders/constants.js +34 -0
  73. package/dist/chart-builders/constants.js.map +1 -0
  74. package/dist/chart-builders/createChartBuilderStore.d.ts +11 -0
  75. package/dist/chart-builders/createChartBuilderStore.d.ts.map +1 -0
  76. package/dist/chart-builders/createChartBuilderStore.js +26 -0
  77. package/dist/chart-builders/createChartBuilderStore.js.map +1 -0
  78. package/dist/chart-builders/describeChartSpecs.d.ts +9 -0
  79. package/dist/chart-builders/describeChartSpecs.d.ts.map +1 -0
  80. package/dist/chart-builders/describeChartSpecs.js +41 -0
  81. package/dist/chart-builders/describeChartSpecs.js.map +1 -0
  82. package/dist/chart-builders/hooks/useChartFieldForm.d.ts +13 -0
  83. package/dist/chart-builders/hooks/useChartFieldForm.d.ts.map +1 -0
  84. package/dist/chart-builders/hooks/useChartFieldForm.js +12 -0
  85. package/dist/chart-builders/hooks/useChartFieldForm.js.map +1 -0
  86. package/dist/chart-builders/types.d.ts +23 -0
  87. package/dist/chart-builders/types.d.ts.map +1 -0
  88. package/dist/chart-builders/types.js +17 -0
  89. package/dist/chart-builders/types.js.map +1 -0
  90. package/dist/chart-types/base-types.d.ts +54 -0
  91. package/dist/chart-types/base-types.d.ts.map +1 -0
  92. package/dist/chart-types/base-types.js +6 -0
  93. package/dist/chart-types/base-types.js.map +1 -0
  94. package/dist/chart-types/box-plot/definition.d.ts +4 -0
  95. package/dist/chart-types/box-plot/definition.d.ts.map +1 -0
  96. package/dist/chart-types/box-plot/definition.js +45 -0
  97. package/dist/chart-types/box-plot/definition.js.map +1 -0
  98. package/dist/chart-types/box-plot/index.d.ts +3 -0
  99. package/dist/chart-types/box-plot/index.d.ts.map +1 -0
  100. package/dist/chart-types/box-plot/index.js +3 -0
  101. package/dist/chart-types/box-plot/index.js.map +1 -0
  102. package/dist/chart-types/box-plot/schema.d.ts +17 -0
  103. package/dist/chart-types/box-plot/schema.d.ts.map +1 -0
  104. package/dist/chart-types/box-plot/schema.js +12 -0
  105. package/dist/chart-types/box-plot/schema.js.map +1 -0
  106. package/dist/chart-types/bubble-chart/definition.d.ts +4 -0
  107. package/dist/chart-types/bubble-chart/definition.d.ts.map +1 -0
  108. package/dist/chart-types/bubble-chart/definition.js +48 -0
  109. package/dist/chart-types/bubble-chart/definition.js.map +1 -0
  110. package/dist/chart-types/bubble-chart/index.d.ts +3 -0
  111. package/dist/chart-types/bubble-chart/index.d.ts.map +1 -0
  112. package/dist/chart-types/bubble-chart/index.js +3 -0
  113. package/dist/chart-types/bubble-chart/index.js.map +1 -0
  114. package/dist/chart-types/bubble-chart/schema.d.ts +17 -0
  115. package/dist/chart-types/bubble-chart/schema.d.ts.map +1 -0
  116. package/dist/chart-types/bubble-chart/schema.js +12 -0
  117. package/dist/chart-types/bubble-chart/schema.js.map +1 -0
  118. package/dist/chart-types/count-plot/definition.d.ts +4 -0
  119. package/dist/chart-types/count-plot/definition.d.ts.map +1 -0
  120. package/dist/chart-types/count-plot/definition.js +50 -0
  121. package/dist/chart-types/count-plot/definition.js.map +1 -0
  122. package/dist/chart-types/count-plot/index.d.ts +3 -0
  123. package/dist/chart-types/count-plot/index.d.ts.map +1 -0
  124. package/dist/chart-types/count-plot/index.js +3 -0
  125. package/dist/chart-types/count-plot/index.js.map +1 -0
  126. package/dist/chart-types/count-plot/schema.d.ts +15 -0
  127. package/dist/chart-types/count-plot/schema.d.ts.map +1 -0
  128. package/dist/chart-types/count-plot/schema.js +11 -0
  129. package/dist/chart-types/count-plot/schema.js.map +1 -0
  130. package/dist/chart-types/custom-spec/definition.d.ts +4 -0
  131. package/dist/chart-types/custom-spec/definition.d.ts.map +1 -0
  132. package/dist/chart-types/custom-spec/definition.js +28 -0
  133. package/dist/chart-types/custom-spec/definition.js.map +1 -0
  134. package/dist/chart-types/custom-spec/index.d.ts +3 -0
  135. package/dist/chart-types/custom-spec/index.d.ts.map +1 -0
  136. package/dist/chart-types/custom-spec/index.js +3 -0
  137. package/dist/chart-types/custom-spec/index.js.map +1 -0
  138. package/dist/chart-types/custom-spec/schema.d.ts +11 -0
  139. package/dist/chart-types/custom-spec/schema.d.ts.map +1 -0
  140. package/dist/chart-types/custom-spec/schema.js +9 -0
  141. package/dist/chart-types/custom-spec/schema.js.map +1 -0
  142. package/dist/chart-types/ecdf/definition.d.ts +4 -0
  143. package/dist/chart-types/ecdf/definition.d.ts.map +1 -0
  144. package/dist/chart-types/ecdf/definition.js +47 -0
  145. package/dist/chart-types/ecdf/definition.js.map +1 -0
  146. package/dist/chart-types/ecdf/index.d.ts +3 -0
  147. package/dist/chart-types/ecdf/index.d.ts.map +1 -0
  148. package/dist/chart-types/ecdf/index.js +3 -0
  149. package/dist/chart-types/ecdf/index.js.map +1 -0
  150. package/dist/chart-types/ecdf/schema.d.ts +15 -0
  151. package/dist/chart-types/ecdf/schema.d.ts.map +1 -0
  152. package/dist/chart-types/ecdf/schema.js +11 -0
  153. package/dist/chart-types/ecdf/schema.js.map +1 -0
  154. package/dist/chart-types/heatmap/definition.d.ts +4 -0
  155. package/dist/chart-types/heatmap/definition.d.ts.map +1 -0
  156. package/dist/chart-types/heatmap/definition.js +49 -0
  157. package/dist/chart-types/heatmap/definition.js.map +1 -0
  158. package/dist/chart-types/heatmap/index.d.ts +3 -0
  159. package/dist/chart-types/heatmap/index.d.ts.map +1 -0
  160. package/dist/chart-types/heatmap/index.js +3 -0
  161. package/dist/chart-types/heatmap/index.js.map +1 -0
  162. package/dist/chart-types/heatmap/schema.d.ts +17 -0
  163. package/dist/chart-types/heatmap/schema.d.ts.map +1 -0
  164. package/dist/chart-types/heatmap/schema.js +12 -0
  165. package/dist/chart-types/heatmap/schema.js.map +1 -0
  166. package/dist/chart-types/histogram/definition.d.ts +4 -0
  167. package/dist/chart-types/histogram/definition.d.ts.map +1 -0
  168. package/dist/chart-types/histogram/definition.js +49 -0
  169. package/dist/chart-types/histogram/definition.js.map +1 -0
  170. package/dist/chart-types/histogram/index.d.ts +3 -0
  171. package/dist/chart-types/histogram/index.d.ts.map +1 -0
  172. package/dist/chart-types/histogram/index.js +3 -0
  173. package/dist/chart-types/histogram/index.js.map +1 -0
  174. package/dist/chart-types/histogram/schema.d.ts +15 -0
  175. package/dist/chart-types/histogram/schema.d.ts.map +1 -0
  176. package/dist/chart-types/histogram/schema.js +11 -0
  177. package/dist/chart-types/histogram/schema.js.map +1 -0
  178. package/dist/chart-types/index.d.ts +109 -0
  179. package/dist/chart-types/index.d.ts.map +1 -0
  180. package/dist/chart-types/index.js +70 -0
  181. package/dist/chart-types/index.js.map +1 -0
  182. package/dist/chart-types/line-chart/definition.d.ts +4 -0
  183. package/dist/chart-types/line-chart/definition.d.ts.map +1 -0
  184. package/dist/chart-types/line-chart/definition.js +46 -0
  185. package/dist/chart-types/line-chart/definition.js.map +1 -0
  186. package/dist/chart-types/line-chart/index.d.ts +3 -0
  187. package/dist/chart-types/line-chart/index.d.ts.map +1 -0
  188. package/dist/chart-types/line-chart/index.js +3 -0
  189. package/dist/chart-types/line-chart/index.js.map +1 -0
  190. package/dist/chart-types/line-chart/schema.d.ts +17 -0
  191. package/dist/chart-types/line-chart/schema.d.ts.map +1 -0
  192. package/dist/chart-types/line-chart/schema.js +12 -0
  193. package/dist/chart-types/line-chart/schema.js.map +1 -0
  194. package/dist/chart-types/registry.d.ts +5 -0
  195. package/dist/chart-types/registry.d.ts.map +1 -0
  196. package/dist/chart-types/registry.js +28 -0
  197. package/dist/chart-types/registry.js.map +1 -0
  198. package/dist/dashboard/DashboardPanelErrorBoundary.d.ts +17 -0
  199. package/dist/dashboard/DashboardPanelErrorBoundary.d.ts.map +1 -0
  200. package/dist/dashboard/DashboardPanelErrorBoundary.js +21 -0
  201. package/dist/dashboard/DashboardPanelErrorBoundary.js.map +1 -0
  202. package/dist/dashboard/MosaicDashboard.d.ts +18 -0
  203. package/dist/dashboard/MosaicDashboard.d.ts.map +1 -0
  204. package/dist/dashboard/MosaicDashboard.js +91 -0
  205. package/dist/dashboard/MosaicDashboard.js.map +1 -0
  206. package/dist/dashboard/MosaicDashboardContext.d.ts +12 -0
  207. package/dist/dashboard/MosaicDashboardContext.d.ts.map +1 -0
  208. package/dist/dashboard/MosaicDashboardContext.js +10 -0
  209. package/dist/dashboard/MosaicDashboardContext.js.map +1 -0
  210. package/dist/dashboard/MosaicDashboardPanel.d.ts +3 -0
  211. package/dist/dashboard/MosaicDashboardPanel.d.ts.map +1 -0
  212. package/dist/dashboard/MosaicDashboardPanel.js +26 -0
  213. package/dist/dashboard/MosaicDashboardPanel.js.map +1 -0
  214. package/dist/dashboard/MosaicDashboardPanelDragOverlay.d.ts +8 -0
  215. package/dist/dashboard/MosaicDashboardPanelDragOverlay.d.ts.map +1 -0
  216. package/dist/dashboard/MosaicDashboardPanelDragOverlay.js +17 -0
  217. package/dist/dashboard/MosaicDashboardPanelDragOverlay.js.map +1 -0
  218. package/dist/dashboard/MosaicDashboardPanelHeader.d.ts +13 -0
  219. package/dist/dashboard/MosaicDashboardPanelHeader.d.ts.map +1 -0
  220. package/dist/dashboard/MosaicDashboardPanelHeader.js +30 -0
  221. package/dist/dashboard/MosaicDashboardPanelHeader.js.map +1 -0
  222. package/dist/dashboard/MosaicDashboardPanelLayout.d.ts +10 -0
  223. package/dist/dashboard/MosaicDashboardPanelLayout.d.ts.map +1 -0
  224. package/dist/dashboard/MosaicDashboardPanelLayout.js +25 -0
  225. package/dist/dashboard/MosaicDashboardPanelLayout.js.map +1 -0
  226. package/dist/dashboard/MosaicDashboardPanels.d.ts +2 -0
  227. package/dist/dashboard/MosaicDashboardPanels.d.ts.map +1 -0
  228. package/dist/dashboard/MosaicDashboardPanels.js +52 -0
  229. package/dist/dashboard/MosaicDashboardPanels.js.map +1 -0
  230. package/dist/dashboard/MosaicDashboardProfilerPanelRenderer.d.ts +3 -0
  231. package/dist/dashboard/MosaicDashboardProfilerPanelRenderer.d.ts.map +1 -0
  232. package/dist/dashboard/MosaicDashboardProfilerPanelRenderer.js +32 -0
  233. package/dist/dashboard/MosaicDashboardProfilerPanelRenderer.js.map +1 -0
  234. package/dist/dashboard/MosaicDashboardSlice.d.ts +523 -0
  235. package/dist/dashboard/MosaicDashboardSlice.d.ts.map +1 -0
  236. package/dist/dashboard/MosaicDashboardSlice.js +615 -0
  237. package/dist/dashboard/MosaicDashboardSlice.js.map +1 -0
  238. package/dist/dashboard/MosaicDashboardToolbar.d.ts +3 -0
  239. package/dist/dashboard/MosaicDashboardToolbar.d.ts.map +1 -0
  240. package/dist/dashboard/MosaicDashboardToolbar.js +81 -0
  241. package/dist/dashboard/MosaicDashboardToolbar.js.map +1 -0
  242. package/dist/dashboard/MosaicDashboardVgPlotHeaderActions.d.ts +4 -0
  243. package/dist/dashboard/MosaicDashboardVgPlotHeaderActions.d.ts.map +1 -0
  244. package/dist/dashboard/MosaicDashboardVgPlotHeaderActions.js +29 -0
  245. package/dist/dashboard/MosaicDashboardVgPlotHeaderActions.js.map +1 -0
  246. package/dist/dashboard/MosaicDashboardVgPlotPanelRenderer.d.ts +3 -0
  247. package/dist/dashboard/MosaicDashboardVgPlotPanelRenderer.d.ts.map +1 -0
  248. package/dist/dashboard/MosaicDashboardVgPlotPanelRenderer.js +68 -0
  249. package/dist/dashboard/MosaicDashboardVgPlotPanelRenderer.js.map +1 -0
  250. package/dist/dashboard/VgPlotSpecPopoverEditor.d.ts +8 -0
  251. package/dist/dashboard/VgPlotSpecPopoverEditor.d.ts.map +1 -0
  252. package/dist/dashboard/VgPlotSpecPopoverEditor.js +40 -0
  253. package/dist/dashboard/VgPlotSpecPopoverEditor.js.map +1 -0
  254. package/dist/dashboard/chart-settings/ChartSettings.d.ts +39 -0
  255. package/dist/dashboard/chart-settings/ChartSettings.d.ts.map +1 -0
  256. package/dist/dashboard/chart-settings/ChartSettings.js +90 -0
  257. package/dist/dashboard/chart-settings/ChartSettings.js.map +1 -0
  258. package/dist/dashboard/chart-settings/ChartSettingsContext.d.ts +20 -0
  259. package/dist/dashboard/chart-settings/ChartSettingsContext.d.ts.map +1 -0
  260. package/dist/dashboard/chart-settings/ChartSettingsContext.js +14 -0
  261. package/dist/dashboard/chart-settings/ChartSettingsContext.js.map +1 -0
  262. package/dist/dashboard/chart-settings/ChartSettingsPanel.d.ts +11 -0
  263. package/dist/dashboard/chart-settings/ChartSettingsPanel.d.ts.map +1 -0
  264. package/dist/dashboard/chart-settings/ChartSettingsPanel.js +8 -0
  265. package/dist/dashboard/chart-settings/ChartSettingsPanel.js.map +1 -0
  266. package/dist/dashboard/chart-settings/ChartTypeSelector.d.ts +11 -0
  267. package/dist/dashboard/chart-settings/ChartTypeSelector.d.ts.map +1 -0
  268. package/dist/dashboard/chart-settings/ChartTypeSelector.js +17 -0
  269. package/dist/dashboard/chart-settings/ChartTypeSelector.js.map +1 -0
  270. package/dist/dashboard/chart-settings/DynamicChartSettings.d.ts +11 -0
  271. package/dist/dashboard/chart-settings/DynamicChartSettings.d.ts.map +1 -0
  272. package/dist/dashboard/chart-settings/DynamicChartSettings.js +19 -0
  273. package/dist/dashboard/chart-settings/DynamicChartSettings.js.map +1 -0
  274. package/dist/dashboard/chart-settings/index.d.ts +6 -0
  275. package/dist/dashboard/chart-settings/index.d.ts.map +1 -0
  276. package/dist/dashboard/chart-settings/index.js +6 -0
  277. package/dist/dashboard/chart-settings/index.js.map +1 -0
  278. package/dist/dashboard/chart-settings/useTableColumns.d.ts +3 -0
  279. package/dist/dashboard/chart-settings/useTableColumns.d.ts.map +1 -0
  280. package/dist/dashboard/chart-settings/useTableColumns.js +12 -0
  281. package/dist/dashboard/chart-settings/useTableColumns.js.map +1 -0
  282. package/dist/dashboard/defaultPanelRenderers.d.ts +3 -0
  283. package/dist/dashboard/defaultPanelRenderers.d.ts.map +1 -0
  284. package/dist/dashboard/defaultPanelRenderers.js +11 -0
  285. package/dist/dashboard/defaultPanelRenderers.js.map +1 -0
  286. package/dist/dashboard/generateMosaicChartSpec.d.ts +15 -0
  287. package/dist/dashboard/generateMosaicChartSpec.d.ts.map +1 -0
  288. package/dist/dashboard/generateMosaicChartSpec.js +30 -0
  289. package/dist/dashboard/generateMosaicChartSpec.js.map +1 -0
  290. package/dist/editor/MosaicChartContainer.d.ts +51 -0
  291. package/dist/editor/MosaicChartContainer.d.ts.map +1 -0
  292. package/dist/editor/MosaicChartContainer.js +39 -0
  293. package/dist/editor/MosaicChartContainer.js.map +1 -0
  294. package/dist/editor/MosaicChartDisplay.d.ts +18 -0
  295. package/dist/editor/MosaicChartDisplay.d.ts.map +1 -0
  296. package/dist/editor/MosaicChartDisplay.js +26 -0
  297. package/dist/editor/MosaicChartDisplay.js.map +1 -0
  298. package/dist/editor/MosaicChartEditorActions.d.ts +20 -0
  299. package/dist/editor/MosaicChartEditorActions.d.ts.map +1 -0
  300. package/dist/editor/MosaicChartEditorActions.js +18 -0
  301. package/dist/editor/MosaicChartEditorActions.js.map +1 -0
  302. package/dist/editor/MosaicCodeMirrorEditor.d.ts +15 -0
  303. package/dist/editor/MosaicCodeMirrorEditor.d.ts.map +1 -0
  304. package/dist/editor/MosaicCodeMirrorEditor.js +26 -0
  305. package/dist/editor/MosaicCodeMirrorEditor.js.map +1 -0
  306. package/dist/editor/MosaicEditorContext.d.ts +8 -0
  307. package/dist/editor/MosaicEditorContext.d.ts.map +1 -0
  308. package/dist/editor/MosaicEditorContext.js +14 -0
  309. package/dist/editor/MosaicEditorContext.js.map +1 -0
  310. package/dist/editor/MosaicSpecEditorPanel.d.ts +20 -0
  311. package/dist/editor/MosaicSpecEditorPanel.d.ts.map +1 -0
  312. package/dist/editor/MosaicSpecEditorPanel.js +25 -0
  313. package/dist/editor/MosaicSpecEditorPanel.js.map +1 -0
  314. package/dist/editor/mosaicSchema.d.ts +20 -0
  315. package/dist/editor/mosaicSchema.d.ts.map +1 -0
  316. package/dist/editor/mosaicSchema.js +57 -0
  317. package/dist/editor/mosaicSchema.js.map +1 -0
  318. package/dist/editor/types.d.ts +72 -0
  319. package/dist/editor/types.d.ts.map +1 -0
  320. package/dist/editor/types.js +2 -0
  321. package/dist/editor/types.js.map +1 -0
  322. package/dist/editor/useMosaicChartEditor.d.ts +9 -0
  323. package/dist/editor/useMosaicChartEditor.d.ts.map +1 -0
  324. package/dist/editor/useMosaicChartEditor.js +199 -0
  325. package/dist/editor/useMosaicChartEditor.js.map +1 -0
  326. package/dist/index.d.ts +53 -2
  327. package/dist/index.d.ts.map +1 -1
  328. package/dist/index.js +37 -1
  329. package/dist/index.js.map +1 -1
  330. package/dist/profiler/MosaicProfiler.d.ts +32 -0
  331. package/dist/profiler/MosaicProfiler.d.ts.map +1 -0
  332. package/dist/profiler/MosaicProfiler.js +57 -0
  333. package/dist/profiler/MosaicProfiler.js.map +1 -0
  334. package/dist/profiler/MosaicProfilerHeader.d.ts +7 -0
  335. package/dist/profiler/MosaicProfilerHeader.d.ts.map +1 -0
  336. package/dist/profiler/MosaicProfilerHeader.js +196 -0
  337. package/dist/profiler/MosaicProfilerHeader.js.map +1 -0
  338. package/dist/profiler/MosaicProfilerRows.d.ts +9 -0
  339. package/dist/profiler/MosaicProfilerRows.d.ts.map +1 -0
  340. package/dist/profiler/MosaicProfilerRows.js +65 -0
  341. package/dist/profiler/MosaicProfilerRows.js.map +1 -0
  342. package/dist/profiler/MosaicProfilerStatusBar.d.ts +9 -0
  343. package/dist/profiler/MosaicProfilerStatusBar.d.ts.map +1 -0
  344. package/dist/profiler/MosaicProfilerStatusBar.js +28 -0
  345. package/dist/profiler/MosaicProfilerStatusBar.js.map +1 -0
  346. package/dist/profiler/ProfilerCategoryClient.d.ts +50 -0
  347. package/dist/profiler/ProfilerCategoryClient.d.ts.map +1 -0
  348. package/dist/profiler/ProfilerCategoryClient.js +121 -0
  349. package/dist/profiler/ProfilerCategoryClient.js.map +1 -0
  350. package/dist/profiler/ProfilerCountClient.d.ts +28 -0
  351. package/dist/profiler/ProfilerCountClient.d.ts.map +1 -0
  352. package/dist/profiler/ProfilerCountClient.js +51 -0
  353. package/dist/profiler/ProfilerCountClient.js.map +1 -0
  354. package/dist/profiler/ProfilerHistogramClient.d.ts +69 -0
  355. package/dist/profiler/ProfilerHistogramClient.d.ts.map +1 -0
  356. package/dist/profiler/ProfilerHistogramClient.js +179 -0
  357. package/dist/profiler/ProfilerHistogramClient.js.map +1 -0
  358. package/dist/profiler/ProfilerPageClient.d.ts +37 -0
  359. package/dist/profiler/ProfilerPageClient.d.ts.map +1 -0
  360. package/dist/profiler/ProfilerPageClient.js +65 -0
  361. package/dist/profiler/ProfilerPageClient.js.map +1 -0
  362. package/dist/profiler/ProfilerUnsupportedSummaryClient.d.ts +24 -0
  363. package/dist/profiler/ProfilerUnsupportedSummaryClient.d.ts.map +1 -0
  364. package/dist/profiler/ProfilerUnsupportedSummaryClient.js +51 -0
  365. package/dist/profiler/ProfilerUnsupportedSummaryClient.js.map +1 -0
  366. package/dist/profiler/createProfilerStore.d.ts +45 -0
  367. package/dist/profiler/createProfilerStore.d.ts.map +1 -0
  368. package/dist/profiler/createProfilerStore.js +120 -0
  369. package/dist/profiler/createProfilerStore.js.map +1 -0
  370. package/dist/profiler/layout.d.ts +7 -0
  371. package/dist/profiler/layout.d.ts.map +1 -0
  372. package/dist/profiler/layout.js +13 -0
  373. package/dist/profiler/layout.js.map +1 -0
  374. package/dist/profiler/profilerController.d.ts +64 -0
  375. package/dist/profiler/profilerController.d.ts.map +1 -0
  376. package/dist/profiler/profilerController.js +123 -0
  377. package/dist/profiler/profilerController.js.map +1 -0
  378. package/dist/profiler/types.d.ts +86 -0
  379. package/dist/profiler/types.d.ts.map +1 -0
  380. package/dist/profiler/types.js +2 -0
  381. package/dist/profiler/types.js.map +1 -0
  382. package/dist/profiler/useMosaicProfiler.d.ts +7 -0
  383. package/dist/profiler/useMosaicProfiler.d.ts.map +1 -0
  384. package/dist/profiler/useMosaicProfiler.js +339 -0
  385. package/dist/profiler/useMosaicProfiler.js.map +1 -0
  386. package/dist/profiler/utils.d.ts +61 -0
  387. package/dist/profiler/utils.d.ts.map +1 -0
  388. package/dist/profiler/utils.js +347 -0
  389. package/dist/profiler/utils.js.map +1 -0
  390. package/dist/tableInterop.d.ts +30 -0
  391. package/dist/tableInterop.d.ts.map +1 -0
  392. package/dist/tableInterop.js +85 -0
  393. package/dist/tableInterop.js.map +1 -0
  394. package/dist/useMosaicClient.d.ts +5 -15
  395. package/dist/useMosaicClient.d.ts.map +1 -1
  396. package/dist/useMosaicClient.js +22 -6
  397. package/dist/useMosaicClient.js.map +1 -1
  398. package/package.json +30 -6
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/chart-builders/types.ts"],"names":[],"mappings":"AAyBA,2EAA2E;AAC3E,MAAM,UAAU,qBAAqB,CACnC,QAA8B;IAE9B,MAAM,EACJ,EAAE,EACF,KAAK,EACL,WAAW,EACX,MAAM,EACN,UAAU,EACV,UAAU,EACV,WAAW,EACX,aAAa,GACd,GAAG,QAAQ,CAAC;IACb,OAAO;QACL,EAAE;QACF,KAAK;QACL,WAAW;QACX,MAAM;QACN,UAAU;QACV,UAAU;QACV,WAAW;QACX,aAAa;KACd,CAAC;AACJ,CAAC;AAED,yDAAyD;AACzD,MAAM,CAAC,MAAM,WAAW,GAAG,qBAAqB,CAAC","sourcesContent":["import type {ComponentType} from 'react';\nimport type {\n ChartTypeDefinition,\n ChartBuilderField,\n ChartBuilderColumn,\n} from '../chart-types/base-types';\n\n// Re-export for backward compatibility\nexport type {ChartTypeDefinition, ChartBuilderField, ChartBuilderColumn};\n\n/**\n * Describes a chart builder template that generates Mosaic JSON specs\n * (includes an icon for the chart-type grid).\n */\nexport interface ChartBuilderTemplate extends ChartTypeDefinition {\n /** Icon component */\n icon: ComponentType<{className?: string}>;\n}\n\n/**\n * Backward-compatible alias for earlier chart-builder helper APIs.\n * Prefer {@link ChartTypeDefinition} for new code.\n */\nexport type ChartSpec = ChartTypeDefinition;\n\n/** Strip UI-only fields from a template for non-UI chart-type contexts. */\nexport function toChartTypeDefinition(\n template: ChartBuilderTemplate,\n): ChartTypeDefinition {\n const {\n id,\n label,\n description,\n fields,\n createSpec,\n buildTitle,\n isAvailable,\n aiDescription,\n } = template;\n return {\n id,\n label,\n description,\n fields,\n createSpec,\n buildTitle,\n isAvailable,\n aiDescription,\n };\n}\n\n/** Backward-compatible alias for earlier helper APIs. */\nexport const toChartSpec = toChartTypeDefinition;\n"]}
@@ -0,0 +1,54 @@
1
+ /**
2
+ * Base types for chart configurations.
3
+ * Separated to avoid circular dependencies.
4
+ */
5
+ import type { Spec } from '@uwdata/mosaic-spec';
6
+ /**
7
+ * Supported chart type identifiers
8
+ */
9
+ export type VgPlotChartType = 'histogram' | 'count-plot' | 'ecdf' | 'line-chart' | 'bubble-chart' | 'heatmap' | 'box-plot' | 'custom-spec';
10
+ /**
11
+ * Describes a field selector in a chart builder UI
12
+ */
13
+ export interface ChartBuilderField {
14
+ /** Unique key for this field */
15
+ key: string;
16
+ /** Display label */
17
+ label: string;
18
+ /** Whether the field is required */
19
+ required?: boolean;
20
+ /** Filter columns by DuckDB type (e.g. 'INTEGER', 'VARCHAR', 'DOUBLE') */
21
+ types?: string[];
22
+ /** Optional helper text for AI or custom UIs */
23
+ description?: string;
24
+ }
25
+ /**
26
+ * Column info passed to chart builder UI
27
+ */
28
+ export interface ChartBuilderColumn {
29
+ name: string;
30
+ type: string;
31
+ }
32
+ /**
33
+ * Shared chart-type definition used by both the chart-builder UI and
34
+ * assistant-driven chart creation.
35
+ */
36
+ export interface ChartTypeDefinition<TSettings = any> {
37
+ /** Unique identifier */
38
+ id: VgPlotChartType;
39
+ /** Short human-friendly name used in chart-type grids and prompts */
40
+ label?: string;
41
+ /** Short description of what this builder creates */
42
+ description: string;
43
+ /** Field selectors the user must fill in */
44
+ fields: ChartBuilderField[];
45
+ /** Generate a Mosaic spec from table name and selected field values */
46
+ createSpec: (tableName: string, values: TSettings) => Spec;
47
+ /** Generate a chart title from selected field values */
48
+ buildTitle?: (fieldValues: Record<string, string>) => string;
49
+ /** Optional availability override for a given table schema */
50
+ isAvailable?: (columns: ChartBuilderColumn[]) => boolean;
51
+ /** Optional extra assistant-facing description */
52
+ aiDescription?: string;
53
+ }
54
+ //# sourceMappingURL=base-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"base-types.d.ts","sourceRoot":"","sources":["../../src/chart-types/base-types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAC,IAAI,EAAC,MAAM,qBAAqB,CAAC;AAE9C;;GAEG;AACH,MAAM,MAAM,eAAe,GACvB,WAAW,GACX,YAAY,GACZ,MAAM,GACN,YAAY,GACZ,cAAc,GACd,SAAS,GACT,UAAU,GACV,aAAa,CAAC;AAElB;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,gCAAgC;IAChC,GAAG,EAAE,MAAM,CAAC;IACZ,oBAAoB;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,oCAAoC;IACpC,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,0EAA0E;IAC1E,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB,gDAAgD;IAChD,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;CACd;AAED;;;GAGG;AACH,MAAM,WAAW,mBAAmB,CAAC,SAAS,GAAG,GAAG;IAClD,wBAAwB;IACxB,EAAE,EAAE,eAAe,CAAC;IACpB,qEAAqE;IACrE,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,qDAAqD;IACrD,WAAW,EAAE,MAAM,CAAC;IACpB,4CAA4C;IAC5C,MAAM,EAAE,iBAAiB,EAAE,CAAC;IAC5B,uEAAuE;IACvE,UAAU,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,KAAK,IAAI,CAAC;IAC3D,wDAAwD;IACxD,UAAU,CAAC,EAAE,CAAC,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KAAK,MAAM,CAAC;IAC7D,8DAA8D;IAC9D,WAAW,CAAC,EAAE,CAAC,OAAO,EAAE,kBAAkB,EAAE,KAAK,OAAO,CAAC;IACzD,kDAAkD;IAClD,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB"}
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Base types for chart configurations.
3
+ * Separated to avoid circular dependencies.
4
+ */
5
+ export {};
6
+ //# sourceMappingURL=base-types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"base-types.js","sourceRoot":"","sources":["../../src/chart-types/base-types.ts"],"names":[],"mappings":"AAAA;;;GAGG","sourcesContent":["/**\n * Base types for chart configurations.\n * Separated to avoid circular dependencies.\n */\n\nimport type {Spec} from '@uwdata/mosaic-spec';\n\n/**\n * Supported chart type identifiers\n */\nexport type VgPlotChartType =\n | 'histogram'\n | 'count-plot'\n | 'ecdf'\n | 'line-chart'\n | 'bubble-chart'\n | 'heatmap'\n | 'box-plot'\n | 'custom-spec';\n\n/**\n * Describes a field selector in a chart builder UI\n */\nexport interface ChartBuilderField {\n /** Unique key for this field */\n key: string;\n /** Display label */\n label: string;\n /** Whether the field is required */\n required?: boolean;\n /** Filter columns by DuckDB type (e.g. 'INTEGER', 'VARCHAR', 'DOUBLE') */\n types?: string[];\n /** Optional helper text for AI or custom UIs */\n description?: string;\n}\n\n/**\n * Column info passed to chart builder UI\n */\nexport interface ChartBuilderColumn {\n name: string;\n type: string;\n}\n\n/**\n * Shared chart-type definition used by both the chart-builder UI and\n * assistant-driven chart creation.\n */\nexport interface ChartTypeDefinition<TSettings = any> {\n /** Unique identifier */\n id: VgPlotChartType;\n /** Short human-friendly name used in chart-type grids and prompts */\n label?: string;\n /** Short description of what this builder creates */\n description: string;\n /** Field selectors the user must fill in */\n fields: ChartBuilderField[];\n /** Generate a Mosaic spec from table name and selected field values */\n createSpec: (tableName: string, values: TSettings) => Spec;\n /** Generate a chart title from selected field values */\n buildTitle?: (fieldValues: Record<string, string>) => string;\n /** Optional availability override for a given table schema */\n isAvailable?: (columns: ChartBuilderColumn[]) => boolean;\n /** Optional extra assistant-facing description */\n aiDescription?: string;\n}\n"]}
@@ -0,0 +1,4 @@
1
+ import type { ChartTypeDefinition } from '../base-types';
2
+ import type { BoxPlotChartSettings } from './schema';
3
+ export declare const boxPlotChartType: ChartTypeDefinition<BoxPlotChartSettings>;
4
+ //# sourceMappingURL=definition.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"definition.d.ts","sourceRoot":"","sources":["../../../src/chart-types/box-plot/definition.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,mBAAmB,EAAC,MAAM,eAAe,CAAC;AACvD,OAAO,KAAK,EAAC,oBAAoB,EAAC,MAAM,UAAU,CAAC;AAOnD,eAAO,MAAM,gBAAgB,EAAE,mBAAmB,CAAC,oBAAoB,CAyCtE,CAAC"}
@@ -0,0 +1,45 @@
1
+ import { NUMERIC_COLUMN_TYPES } from '../../chart-builders/constants';
2
+ import { titleFromDescription } from '../../chart-builders/chartTypeUtils';
3
+ const FG_COLOR = 'var(--color-chart-1)';
4
+ const DESCRIPTION = 'Create a box plot';
5
+ export const boxPlotChartType = {
6
+ id: 'box-plot',
7
+ label: 'Box Plot',
8
+ description: DESCRIPTION,
9
+ aiDescription: 'Use for comparing the distribution of a numeric measure across categories.',
10
+ fields: [
11
+ {
12
+ key: 'x',
13
+ label: 'X Field (categorical)',
14
+ required: true,
15
+ description: 'Grouping field that defines the categories.',
16
+ },
17
+ {
18
+ key: 'y',
19
+ label: 'Y Field (numeric)',
20
+ required: true,
21
+ types: [...NUMERIC_COLUMN_TYPES],
22
+ description: 'Numeric measure summarized within each category.',
23
+ },
24
+ ],
25
+ buildTitle: titleFromDescription(DESCRIPTION),
26
+ createSpec: (tableName, { x, y }) => ({
27
+ plot: [
28
+ {
29
+ mark: 'boxY',
30
+ data: { from: tableName, filterBy: '$brush' },
31
+ x,
32
+ y,
33
+ fill: FG_COLOR,
34
+ },
35
+ { select: 'intervalX', as: '$brush' },
36
+ ],
37
+ xLabel: x,
38
+ yLabel: y,
39
+ height: 250,
40
+ width: 380,
41
+ margins: { left: 50, right: 20, top: 20, bottom: 50 },
42
+ params: { brush: { select: 'crossfilter' } },
43
+ }),
44
+ };
45
+ //# sourceMappingURL=definition.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"definition.js","sourceRoot":"","sources":["../../../src/chart-types/box-plot/definition.ts"],"names":[],"mappings":"AAGA,OAAO,EAAC,oBAAoB,EAAC,MAAM,gCAAgC,CAAC;AACpE,OAAO,EAAC,oBAAoB,EAAC,MAAM,qCAAqC,CAAC;AAEzE,MAAM,QAAQ,GAAG,sBAAsB,CAAC;AACxC,MAAM,WAAW,GAAG,mBAAmB,CAAC;AAExC,MAAM,CAAC,MAAM,gBAAgB,GAA8C;IACzE,EAAE,EAAE,UAAU;IACd,KAAK,EAAE,UAAU;IACjB,WAAW,EAAE,WAAW;IACxB,aAAa,EACX,4EAA4E;IAC9E,MAAM,EAAE;QACN;YACE,GAAG,EAAE,GAAG;YACR,KAAK,EAAE,uBAAuB;YAC9B,QAAQ,EAAE,IAAI;YACd,WAAW,EAAE,6CAA6C;SAC3D;QACD;YACE,GAAG,EAAE,GAAG;YACR,KAAK,EAAE,mBAAmB;YAC1B,QAAQ,EAAE,IAAI;YACd,KAAK,EAAE,CAAC,GAAG,oBAAoB,CAAC;YAChC,WAAW,EAAE,kDAAkD;SAChE;KACF;IACD,UAAU,EAAE,oBAAoB,CAAC,WAAW,CAAC;IAC7C,UAAU,EAAE,CAAC,SAAS,EAAE,EAAC,CAAC,EAAE,CAAC,EAAC,EAAQ,EAAE,CACtC,CAAC;QACC,IAAI,EAAE;YACJ;gBACE,IAAI,EAAE,MAAM;gBACZ,IAAI,EAAE,EAAC,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,QAAQ,EAAC;gBAC3C,CAAC;gBACD,CAAC;gBACD,IAAI,EAAE,QAAQ;aACf;YACD,EAAC,MAAM,EAAE,WAAW,EAAE,EAAE,EAAE,QAAQ,EAAC;SACpC;QACD,MAAM,EAAE,CAAC;QACT,MAAM,EAAE,CAAC;QACT,MAAM,EAAE,GAAG;QACX,KAAK,EAAE,GAAG;QACV,OAAO,EAAE,EAAC,IAAI,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE,EAAE,GAAG,EAAE,EAAE,EAAE,MAAM,EAAE,EAAE,EAAC;QACnD,MAAM,EAAE,EAAC,KAAK,EAAE,EAAC,MAAM,EAAE,aAAa,EAAC,EAAC;KACzC,CAAS;CACb,CAAC","sourcesContent":["import type {Spec} from '@uwdata/mosaic-spec';\nimport type {ChartTypeDefinition} from '../base-types';\nimport type {BoxPlotChartSettings} from './schema';\nimport {NUMERIC_COLUMN_TYPES} from '../../chart-builders/constants';\nimport {titleFromDescription} from '../../chart-builders/chartTypeUtils';\n\nconst FG_COLOR = 'var(--color-chart-1)';\nconst DESCRIPTION = 'Create a box plot';\n\nexport const boxPlotChartType: ChartTypeDefinition<BoxPlotChartSettings> = {\n id: 'box-plot',\n label: 'Box Plot',\n description: DESCRIPTION,\n aiDescription:\n 'Use for comparing the distribution of a numeric measure across categories.',\n fields: [\n {\n key: 'x',\n label: 'X Field (categorical)',\n required: true,\n description: 'Grouping field that defines the categories.',\n },\n {\n key: 'y',\n label: 'Y Field (numeric)',\n required: true,\n types: [...NUMERIC_COLUMN_TYPES],\n description: 'Numeric measure summarized within each category.',\n },\n ],\n buildTitle: titleFromDescription(DESCRIPTION),\n createSpec: (tableName, {x, y}): Spec =>\n ({\n plot: [\n {\n mark: 'boxY',\n data: {from: tableName, filterBy: '$brush'},\n x,\n y,\n fill: FG_COLOR,\n },\n {select: 'intervalX', as: '$brush'},\n ],\n xLabel: x,\n yLabel: y,\n height: 250,\n width: 380,\n margins: {left: 50, right: 20, top: 20, bottom: 50},\n params: {brush: {select: 'crossfilter'}},\n }) as Spec,\n};\n"]}
@@ -0,0 +1,3 @@
1
+ export * from './schema';
2
+ export * from './definition';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/chart-types/box-plot/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from './schema';
2
+ export * from './definition';
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/chart-types/box-plot/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC","sourcesContent":["export * from './schema';\nexport * from './definition';\n"]}
@@ -0,0 +1,17 @@
1
+ import { z } from 'zod';
2
+ export declare const BoxPlotChartSettings: z.ZodObject<{
3
+ x: z.ZodOptional<z.ZodString>;
4
+ y: z.ZodOptional<z.ZodString>;
5
+ }, z.core.$strip>;
6
+ export type BoxPlotChartSettings = z.infer<typeof BoxPlotChartSettings>;
7
+ export declare const BoxPlotChartConfig: z.ZodObject<{
8
+ chartType: z.ZodLiteral<"box-plot">;
9
+ settings: z.ZodObject<{
10
+ x: z.ZodOptional<z.ZodString>;
11
+ y: z.ZodOptional<z.ZodString>;
12
+ }, z.core.$strip>;
13
+ vgplot: z.ZodUnknown;
14
+ settingsOpen: z.ZodOptional<z.ZodBoolean>;
15
+ }, z.core.$strip>;
16
+ export type BoxPlotChartConfig = z.infer<typeof BoxPlotChartConfig>;
17
+ //# sourceMappingURL=schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/chart-types/box-plot/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,eAAO,MAAM,oBAAoB;;;iBAG/B,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAExE,eAAO,MAAM,kBAAkB;;;;;;;;iBAK7B,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { z } from 'zod';
2
+ export const BoxPlotChartSettings = z.object({
3
+ x: z.string().optional(),
4
+ y: z.string().optional(),
5
+ });
6
+ export const BoxPlotChartConfig = z.object({
7
+ chartType: z.literal('box-plot'),
8
+ settings: BoxPlotChartSettings,
9
+ vgplot: z.unknown(),
10
+ settingsOpen: z.boolean().optional(),
11
+ });
12
+ //# sourceMappingURL=schema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/chart-types/box-plot/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC3C,CAAC,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACxB,CAAC,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACzB,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,CAAC,MAAM,CAAC;IACzC,SAAS,EAAE,CAAC,CAAC,OAAO,CAAC,UAAU,CAAC;IAChC,QAAQ,EAAE,oBAAoB;IAC9B,MAAM,EAAE,CAAC,CAAC,OAAO,EAAE;IACnB,YAAY,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CACrC,CAAC,CAAC","sourcesContent":["import {z} from 'zod';\n\nexport const BoxPlotChartSettings = z.object({\n x: z.string().optional(),\n y: z.string().optional(),\n});\n\nexport type BoxPlotChartSettings = z.infer<typeof BoxPlotChartSettings>;\n\nexport const BoxPlotChartConfig = z.object({\n chartType: z.literal('box-plot'),\n settings: BoxPlotChartSettings,\n vgplot: z.unknown(),\n settingsOpen: z.boolean().optional(),\n});\n\nexport type BoxPlotChartConfig = z.infer<typeof BoxPlotChartConfig>;\n"]}
@@ -0,0 +1,4 @@
1
+ import type { ChartTypeDefinition } from '../base-types';
2
+ import type { BubbleChartSettings } from './schema';
3
+ export declare const bubbleChartChartType: ChartTypeDefinition<BubbleChartSettings>;
4
+ //# sourceMappingURL=definition.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"definition.d.ts","sourceRoot":"","sources":["../../../src/chart-types/bubble-chart/definition.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,mBAAmB,EAAC,MAAM,eAAe,CAAC;AACvD,OAAO,KAAK,EAAC,mBAAmB,EAAC,MAAM,UAAU,CAAC;AAOlD,eAAO,MAAM,oBAAoB,EAAE,mBAAmB,CAAC,mBAAmB,CA2CzE,CAAC"}
@@ -0,0 +1,48 @@
1
+ import { NUMERIC_COLUMN_TYPES } from '../../chart-builders/constants';
2
+ import { titleFromDescription } from '../../chart-builders/chartTypeUtils';
3
+ const FG_COLOR = 'var(--color-chart-1)';
4
+ const DESCRIPTION = 'Create a bubble chart';
5
+ export const bubbleChartChartType = {
6
+ id: 'bubble-chart',
7
+ label: 'Bubble Chart',
8
+ description: DESCRIPTION,
9
+ aiDescription: 'Use for a simple scatterplot of two numeric columns.',
10
+ fields: [
11
+ {
12
+ key: 'x',
13
+ label: 'X Field',
14
+ required: true,
15
+ types: [...NUMERIC_COLUMN_TYPES],
16
+ description: 'Numeric column used on the x-axis.',
17
+ },
18
+ {
19
+ key: 'y',
20
+ label: 'Y Field',
21
+ required: true,
22
+ types: [...NUMERIC_COLUMN_TYPES],
23
+ description: 'Numeric column used on the y-axis.',
24
+ },
25
+ ],
26
+ buildTitle: titleFromDescription(DESCRIPTION),
27
+ createSpec: (tableName, { x, y }) => ({
28
+ plot: [
29
+ {
30
+ mark: 'dot',
31
+ data: { from: tableName, filterBy: '$brush' },
32
+ x,
33
+ y,
34
+ fill: FG_COLOR,
35
+ fillOpacity: 0.5,
36
+ r: 3,
37
+ },
38
+ { select: 'intervalXY', as: '$brush' },
39
+ ],
40
+ xLabel: x,
41
+ yLabel: y,
42
+ height: 250,
43
+ width: 380,
44
+ margins: { left: 50, right: 20, top: 20, bottom: 50 },
45
+ params: { brush: { select: 'crossfilter' } },
46
+ }),
47
+ };
48
+ //# sourceMappingURL=definition.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"definition.js","sourceRoot":"","sources":["../../../src/chart-types/bubble-chart/definition.ts"],"names":[],"mappings":"AAGA,OAAO,EAAC,oBAAoB,EAAC,MAAM,gCAAgC,CAAC;AACpE,OAAO,EAAC,oBAAoB,EAAC,MAAM,qCAAqC,CAAC;AAEzE,MAAM,QAAQ,GAAG,sBAAsB,CAAC;AACxC,MAAM,WAAW,GAAG,uBAAuB,CAAC;AAE5C,MAAM,CAAC,MAAM,oBAAoB,GAA6C;IAC5E,EAAE,EAAE,cAAc;IAClB,KAAK,EAAE,cAAc;IACrB,WAAW,EAAE,WAAW;IACxB,aAAa,EAAE,sDAAsD;IACrE,MAAM,EAAE;QACN;YACE,GAAG,EAAE,GAAG;YACR,KAAK,EAAE,SAAS;YAChB,QAAQ,EAAE,IAAI;YACd,KAAK,EAAE,CAAC,GAAG,oBAAoB,CAAC;YAChC,WAAW,EAAE,oCAAoC;SAClD;QACD;YACE,GAAG,EAAE,GAAG;YACR,KAAK,EAAE,SAAS;YAChB,QAAQ,EAAE,IAAI;YACd,KAAK,EAAE,CAAC,GAAG,oBAAoB,CAAC;YAChC,WAAW,EAAE,oCAAoC;SAClD;KACF;IACD,UAAU,EAAE,oBAAoB,CAAC,WAAW,CAAC;IAC7C,UAAU,EAAE,CAAC,SAAS,EAAE,EAAC,CAAC,EAAE,CAAC,EAAC,EAAQ,EAAE,CACtC,CAAC;QACC,IAAI,EAAE;YACJ;gBACE,IAAI,EAAE,KAAK;gBACX,IAAI,EAAE,EAAC,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,QAAQ,EAAC;gBAC3C,CAAC;gBACD,CAAC;gBACD,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,GAAG;gBAChB,CAAC,EAAE,CAAC;aACL;YACD,EAAC,MAAM,EAAE,YAAY,EAAE,EAAE,EAAE,QAAQ,EAAC;SACrC;QACD,MAAM,EAAE,CAAC;QACT,MAAM,EAAE,CAAC;QACT,MAAM,EAAE,GAAG;QACX,KAAK,EAAE,GAAG;QACV,OAAO,EAAE,EAAC,IAAI,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE,EAAE,GAAG,EAAE,EAAE,EAAE,MAAM,EAAE,EAAE,EAAC;QACnD,MAAM,EAAE,EAAC,KAAK,EAAE,EAAC,MAAM,EAAE,aAAa,EAAC,EAAC;KACzC,CAAS;CACb,CAAC","sourcesContent":["import type {Spec} from '@uwdata/mosaic-spec';\nimport type {ChartTypeDefinition} from '../base-types';\nimport type {BubbleChartSettings} from './schema';\nimport {NUMERIC_COLUMN_TYPES} from '../../chart-builders/constants';\nimport {titleFromDescription} from '../../chart-builders/chartTypeUtils';\n\nconst FG_COLOR = 'var(--color-chart-1)';\nconst DESCRIPTION = 'Create a bubble chart';\n\nexport const bubbleChartChartType: ChartTypeDefinition<BubbleChartSettings> = {\n id: 'bubble-chart',\n label: 'Bubble Chart',\n description: DESCRIPTION,\n aiDescription: 'Use for a simple scatterplot of two numeric columns.',\n fields: [\n {\n key: 'x',\n label: 'X Field',\n required: true,\n types: [...NUMERIC_COLUMN_TYPES],\n description: 'Numeric column used on the x-axis.',\n },\n {\n key: 'y',\n label: 'Y Field',\n required: true,\n types: [...NUMERIC_COLUMN_TYPES],\n description: 'Numeric column used on the y-axis.',\n },\n ],\n buildTitle: titleFromDescription(DESCRIPTION),\n createSpec: (tableName, {x, y}): Spec =>\n ({\n plot: [\n {\n mark: 'dot',\n data: {from: tableName, filterBy: '$brush'},\n x,\n y,\n fill: FG_COLOR,\n fillOpacity: 0.5,\n r: 3,\n },\n {select: 'intervalXY', as: '$brush'},\n ],\n xLabel: x,\n yLabel: y,\n height: 250,\n width: 380,\n margins: {left: 50, right: 20, top: 20, bottom: 50},\n params: {brush: {select: 'crossfilter'}},\n }) as Spec,\n};\n"]}
@@ -0,0 +1,3 @@
1
+ export * from './schema';
2
+ export * from './definition';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/chart-types/bubble-chart/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from './schema';
2
+ export * from './definition';
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/chart-types/bubble-chart/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC","sourcesContent":["export * from './schema';\nexport * from './definition';\n"]}
@@ -0,0 +1,17 @@
1
+ import { z } from 'zod';
2
+ export declare const BubbleChartSettings: z.ZodObject<{
3
+ x: z.ZodOptional<z.ZodString>;
4
+ y: z.ZodOptional<z.ZodString>;
5
+ }, z.core.$strip>;
6
+ export type BubbleChartSettings = z.infer<typeof BubbleChartSettings>;
7
+ export declare const BubbleChartConfig: z.ZodObject<{
8
+ chartType: z.ZodLiteral<"bubble-chart">;
9
+ settings: z.ZodObject<{
10
+ x: z.ZodOptional<z.ZodString>;
11
+ y: z.ZodOptional<z.ZodString>;
12
+ }, z.core.$strip>;
13
+ vgplot: z.ZodUnknown;
14
+ settingsOpen: z.ZodOptional<z.ZodBoolean>;
15
+ }, z.core.$strip>;
16
+ export type BubbleChartConfig = z.infer<typeof BubbleChartConfig>;
17
+ //# sourceMappingURL=schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/chart-types/bubble-chart/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,eAAO,MAAM,mBAAmB;;;iBAG9B,CAAC;AAEH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEtE,eAAO,MAAM,iBAAiB;;;;;;;;iBAK5B,CAAC;AAEH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { z } from 'zod';
2
+ export const BubbleChartSettings = z.object({
3
+ x: z.string().optional(),
4
+ y: z.string().optional(),
5
+ });
6
+ export const BubbleChartConfig = z.object({
7
+ chartType: z.literal('bubble-chart'),
8
+ settings: BubbleChartSettings,
9
+ vgplot: z.unknown(),
10
+ settingsOpen: z.boolean().optional(),
11
+ });
12
+ //# sourceMappingURL=schema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/chart-types/bubble-chart/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,MAAM,CAAC,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,CAAC,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACxB,CAAC,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACzB,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,CAAC,MAAM,CAAC;IACxC,SAAS,EAAE,CAAC,CAAC,OAAO,CAAC,cAAc,CAAC;IACpC,QAAQ,EAAE,mBAAmB;IAC7B,MAAM,EAAE,CAAC,CAAC,OAAO,EAAE;IACnB,YAAY,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CACrC,CAAC,CAAC","sourcesContent":["import {z} from 'zod';\n\nexport const BubbleChartSettings = z.object({\n x: z.string().optional(),\n y: z.string().optional(),\n});\n\nexport type BubbleChartSettings = z.infer<typeof BubbleChartSettings>;\n\nexport const BubbleChartConfig = z.object({\n chartType: z.literal('bubble-chart'),\n settings: BubbleChartSettings,\n vgplot: z.unknown(),\n settingsOpen: z.boolean().optional(),\n});\n\nexport type BubbleChartConfig = z.infer<typeof BubbleChartConfig>;\n"]}
@@ -0,0 +1,4 @@
1
+ import type { ChartTypeDefinition } from '../base-types';
2
+ import type { CountPlotChartSettings } from './schema';
3
+ export declare const countPlotChartType: ChartTypeDefinition<CountPlotChartSettings>;
4
+ //# sourceMappingURL=definition.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"definition.d.ts","sourceRoot":"","sources":["../../../src/chart-types/count-plot/definition.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,mBAAmB,EAAC,MAAM,eAAe,CAAC;AACvD,OAAO,KAAK,EAAC,sBAAsB,EAAC,MAAM,UAAU,CAAC;AAQrD,eAAO,MAAM,kBAAkB,EAAE,mBAAmB,CAAC,sBAAsB,CA6C1E,CAAC"}
@@ -0,0 +1,50 @@
1
+ import { QUANTITATIVE_COLUMN_TYPES } from '../../chart-builders/constants';
2
+ import { titleFromDescription } from '../../chart-builders/chartTypeUtils';
3
+ const BG_COLOR = 'var(--color-chart-overlay)';
4
+ const FG_COLOR = 'var(--color-chart-1)';
5
+ const DESCRIPTION = 'Create a count plot of a field';
6
+ export const countPlotChartType = {
7
+ id: 'count-plot',
8
+ label: 'Count Plot',
9
+ description: DESCRIPTION,
10
+ aiDescription: 'Use for a quick binned distribution of one numeric or temporal column.',
11
+ fields: [
12
+ {
13
+ key: 'field',
14
+ label: 'Field',
15
+ required: true,
16
+ types: [...QUANTITATIVE_COLUMN_TYPES],
17
+ description: 'Numeric or temporal column to bin along the x-axis.',
18
+ },
19
+ ],
20
+ buildTitle: titleFromDescription(DESCRIPTION),
21
+ createSpec: (tableName, { field }) => ({
22
+ plot: [
23
+ {
24
+ mark: 'rectY',
25
+ data: { from: tableName },
26
+ x: { bin: field, maxbins: 25 },
27
+ y: { count: null },
28
+ fill: BG_COLOR,
29
+ inset: 0.5,
30
+ },
31
+ {
32
+ mark: 'rectY',
33
+ data: { from: tableName, filterBy: '$brush' },
34
+ x: { bin: field, maxbins: 25 },
35
+ y: { count: null },
36
+ fill: FG_COLOR,
37
+ inset: 0.5,
38
+ },
39
+ { select: 'intervalX', as: '$brush' },
40
+ ],
41
+ xLabel: field,
42
+ yLabel: null,
43
+ yAxis: null,
44
+ height: 200,
45
+ width: 380,
46
+ margins: { left: 50, right: 20, top: 20, bottom: 50 },
47
+ params: { brush: { select: 'crossfilter' } },
48
+ }),
49
+ };
50
+ //# sourceMappingURL=definition.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"definition.js","sourceRoot":"","sources":["../../../src/chart-types/count-plot/definition.ts"],"names":[],"mappings":"AAGA,OAAO,EAAC,yBAAyB,EAAC,MAAM,gCAAgC,CAAC;AACzE,OAAO,EAAC,oBAAoB,EAAC,MAAM,qCAAqC,CAAC;AAEzE,MAAM,QAAQ,GAAG,4BAA4B,CAAC;AAC9C,MAAM,QAAQ,GAAG,sBAAsB,CAAC;AACxC,MAAM,WAAW,GAAG,gCAAgC,CAAC;AAErD,MAAM,CAAC,MAAM,kBAAkB,GAAgD;IAC7E,EAAE,EAAE,YAAY;IAChB,KAAK,EAAE,YAAY;IACnB,WAAW,EAAE,WAAW;IACxB,aAAa,EACX,wEAAwE;IAC1E,MAAM,EAAE;QACN;YACE,GAAG,EAAE,OAAO;YACZ,KAAK,EAAE,OAAO;YACd,QAAQ,EAAE,IAAI;YACd,KAAK,EAAE,CAAC,GAAG,yBAAyB,CAAC;YACrC,WAAW,EAAE,qDAAqD;SACnE;KACF;IACD,UAAU,EAAE,oBAAoB,CAAC,WAAW,CAAC;IAC7C,UAAU,EAAE,CAAC,SAAS,EAAE,EAAC,KAAK,EAAC,EAAQ,EAAE,CACvC,CAAC;QACC,IAAI,EAAE;YACJ;gBACE,IAAI,EAAE,OAAO;gBACb,IAAI,EAAE,EAAC,IAAI,EAAE,SAAS,EAAC;gBACvB,CAAC,EAAE,EAAC,GAAG,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,EAAC;gBAC5B,CAAC,EAAE,EAAC,KAAK,EAAE,IAAI,EAAC;gBAChB,IAAI,EAAE,QAAQ;gBACd,KAAK,EAAE,GAAG;aACX;YACD;gBACE,IAAI,EAAE,OAAO;gBACb,IAAI,EAAE,EAAC,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,QAAQ,EAAC;gBAC3C,CAAC,EAAE,EAAC,GAAG,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,EAAC;gBAC5B,CAAC,EAAE,EAAC,KAAK,EAAE,IAAI,EAAC;gBAChB,IAAI,EAAE,QAAQ;gBACd,KAAK,EAAE,GAAG;aACX;YACD,EAAC,MAAM,EAAE,WAAW,EAAE,EAAE,EAAE,QAAQ,EAAC;SACpC;QACD,MAAM,EAAE,KAAK;QACb,MAAM,EAAE,IAAI;QACZ,KAAK,EAAE,IAAI;QACX,MAAM,EAAE,GAAG;QACX,KAAK,EAAE,GAAG;QACV,OAAO,EAAE,EAAC,IAAI,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE,EAAE,GAAG,EAAE,EAAE,EAAE,MAAM,EAAE,EAAE,EAAC;QACnD,MAAM,EAAE,EAAC,KAAK,EAAE,EAAC,MAAM,EAAE,aAAa,EAAC,EAAC;KACzC,CAAS;CACb,CAAC","sourcesContent":["import type {Spec} from '@uwdata/mosaic-spec';\nimport type {ChartTypeDefinition} from '../base-types';\nimport type {CountPlotChartSettings} from './schema';\nimport {QUANTITATIVE_COLUMN_TYPES} from '../../chart-builders/constants';\nimport {titleFromDescription} from '../../chart-builders/chartTypeUtils';\n\nconst BG_COLOR = 'var(--color-chart-overlay)';\nconst FG_COLOR = 'var(--color-chart-1)';\nconst DESCRIPTION = 'Create a count plot of a field';\n\nexport const countPlotChartType: ChartTypeDefinition<CountPlotChartSettings> = {\n id: 'count-plot',\n label: 'Count Plot',\n description: DESCRIPTION,\n aiDescription:\n 'Use for a quick binned distribution of one numeric or temporal column.',\n fields: [\n {\n key: 'field',\n label: 'Field',\n required: true,\n types: [...QUANTITATIVE_COLUMN_TYPES],\n description: 'Numeric or temporal column to bin along the x-axis.',\n },\n ],\n buildTitle: titleFromDescription(DESCRIPTION),\n createSpec: (tableName, {field}): Spec =>\n ({\n plot: [\n {\n mark: 'rectY',\n data: {from: tableName},\n x: {bin: field, maxbins: 25},\n y: {count: null},\n fill: BG_COLOR,\n inset: 0.5,\n },\n {\n mark: 'rectY',\n data: {from: tableName, filterBy: '$brush'},\n x: {bin: field, maxbins: 25},\n y: {count: null},\n fill: FG_COLOR,\n inset: 0.5,\n },\n {select: 'intervalX', as: '$brush'},\n ],\n xLabel: field,\n yLabel: null,\n yAxis: null,\n height: 200,\n width: 380,\n margins: {left: 50, right: 20, top: 20, bottom: 50},\n params: {brush: {select: 'crossfilter'}},\n }) as Spec,\n};\n"]}
@@ -0,0 +1,3 @@
1
+ export * from './schema';
2
+ export * from './definition';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/chart-types/count-plot/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from './schema';
2
+ export * from './definition';
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/chart-types/count-plot/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC","sourcesContent":["export * from './schema';\nexport * from './definition';\n"]}
@@ -0,0 +1,15 @@
1
+ import { z } from 'zod';
2
+ export declare const CountPlotChartSettings: z.ZodObject<{
3
+ field: z.ZodOptional<z.ZodString>;
4
+ }, z.core.$strip>;
5
+ export type CountPlotChartSettings = z.infer<typeof CountPlotChartSettings>;
6
+ export declare const CountPlotChartConfig: z.ZodObject<{
7
+ chartType: z.ZodLiteral<"count-plot">;
8
+ settings: z.ZodObject<{
9
+ field: z.ZodOptional<z.ZodString>;
10
+ }, z.core.$strip>;
11
+ vgplot: z.ZodUnknown;
12
+ settingsOpen: z.ZodOptional<z.ZodBoolean>;
13
+ }, z.core.$strip>;
14
+ export type CountPlotChartConfig = z.infer<typeof CountPlotChartConfig>;
15
+ //# sourceMappingURL=schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/chart-types/count-plot/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,eAAO,MAAM,sBAAsB;;iBAEjC,CAAC;AAEH,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAE5E,eAAO,MAAM,oBAAoB;;;;;;;iBAK/B,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC"}
@@ -0,0 +1,11 @@
1
+ import { z } from 'zod';
2
+ export const CountPlotChartSettings = z.object({
3
+ field: z.string().optional(),
4
+ });
5
+ export const CountPlotChartConfig = z.object({
6
+ chartType: z.literal('count-plot'),
7
+ settings: CountPlotChartSettings,
8
+ vgplot: z.unknown(),
9
+ settingsOpen: z.boolean().optional(),
10
+ });
11
+ //# sourceMappingURL=schema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/chart-types/count-plot/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC7C,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAC7B,CAAC,CAAC;AAIH,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC3C,SAAS,EAAE,CAAC,CAAC,OAAO,CAAC,YAAY,CAAC;IAClC,QAAQ,EAAE,sBAAsB;IAChC,MAAM,EAAE,CAAC,CAAC,OAAO,EAAE;IACnB,YAAY,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CACrC,CAAC,CAAC","sourcesContent":["import {z} from 'zod';\n\nexport const CountPlotChartSettings = z.object({\n field: z.string().optional(),\n});\n\nexport type CountPlotChartSettings = z.infer<typeof CountPlotChartSettings>;\n\nexport const CountPlotChartConfig = z.object({\n chartType: z.literal('count-plot'),\n settings: CountPlotChartSettings,\n vgplot: z.unknown(),\n settingsOpen: z.boolean().optional(),\n});\n\nexport type CountPlotChartConfig = z.infer<typeof CountPlotChartConfig>;\n"]}
@@ -0,0 +1,4 @@
1
+ import type { ChartTypeDefinition } from '../base-types';
2
+ import type { CustomSpecChartSettings } from './schema';
3
+ export declare const customSpecChartType: ChartTypeDefinition<CustomSpecChartSettings>;
4
+ //# sourceMappingURL=definition.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"definition.d.ts","sourceRoot":"","sources":["../../../src/chart-types/custom-spec/definition.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,mBAAmB,EAAC,MAAM,eAAe,CAAC;AACvD,OAAO,KAAK,EAAC,uBAAuB,EAAC,MAAM,UAAU,CAAC;AAKtD,eAAO,MAAM,mBAAmB,EAAE,mBAAmB,CAAC,uBAAuB,CA2B1E,CAAC"}
@@ -0,0 +1,28 @@
1
+ import { titleFromDescription } from '../../chart-builders/chartTypeUtils';
2
+ const DESCRIPTION = 'Create a chart with custom spec';
3
+ export const customSpecChartType = {
4
+ id: 'custom-spec',
5
+ label: 'Custom Spec',
6
+ description: DESCRIPTION,
7
+ aiDescription: 'Manual template for editing after creation. Prefer explicit chart templates for assistant-created charts.',
8
+ fields: [],
9
+ buildTitle: titleFromDescription(DESCRIPTION),
10
+ createSpec: (tableName) => ({
11
+ plot: [
12
+ {
13
+ mark: 'rectY',
14
+ data: { from: tableName, filterBy: '$brush' },
15
+ x: { bin: 'field_name', maxbins: 25 },
16
+ y: { count: null },
17
+ fill: 'steelblue',
18
+ inset: 0.5,
19
+ },
20
+ { select: 'intervalX', as: '$brush' },
21
+ ],
22
+ xLabel: 'field_name',
23
+ height: 200,
24
+ width: 380,
25
+ params: { brush: { select: 'crossfilter' } },
26
+ }),
27
+ };
28
+ //# sourceMappingURL=definition.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"definition.js","sourceRoot":"","sources":["../../../src/chart-types/custom-spec/definition.ts"],"names":[],"mappings":"AAGA,OAAO,EAAC,oBAAoB,EAAC,MAAM,qCAAqC,CAAC;AAEzE,MAAM,WAAW,GAAG,iCAAiC,CAAC;AAEtD,MAAM,CAAC,MAAM,mBAAmB,GAC9B;IACE,EAAE,EAAE,aAAa;IACjB,KAAK,EAAE,aAAa;IACpB,WAAW,EAAE,WAAW;IACxB,aAAa,EACX,2GAA2G;IAC7G,MAAM,EAAE,EAAE;IACV,UAAU,EAAE,oBAAoB,CAAC,WAAW,CAAC;IAC7C,UAAU,EAAE,CAAC,SAAS,EAAQ,EAAE,CAC9B,CAAC;QACC,IAAI,EAAE;YACJ;gBACE,IAAI,EAAE,OAAO;gBACb,IAAI,EAAE,EAAC,IAAI,EAAE,SAAS,EAAE,QAAQ,EAAE,QAAQ,EAAC;gBAC3C,CAAC,EAAE,EAAC,GAAG,EAAE,YAAY,EAAE,OAAO,EAAE,EAAE,EAAC;gBACnC,CAAC,EAAE,EAAC,KAAK,EAAE,IAAI,EAAC;gBAChB,IAAI,EAAE,WAAW;gBACjB,KAAK,EAAE,GAAG;aACX;YACD,EAAC,MAAM,EAAE,WAAW,EAAE,EAAE,EAAE,QAAQ,EAAC;SACpC;QACD,MAAM,EAAE,YAAY;QACpB,MAAM,EAAE,GAAG;QACX,KAAK,EAAE,GAAG;QACV,MAAM,EAAE,EAAC,KAAK,EAAE,EAAC,MAAM,EAAE,aAAa,EAAC,EAAC;KACzC,CAAS;CACb,CAAC","sourcesContent":["import type {Spec} from '@uwdata/mosaic-spec';\nimport type {ChartTypeDefinition} from '../base-types';\nimport type {CustomSpecChartSettings} from './schema';\nimport {titleFromDescription} from '../../chart-builders/chartTypeUtils';\n\nconst DESCRIPTION = 'Create a chart with custom spec';\n\nexport const customSpecChartType: ChartTypeDefinition<CustomSpecChartSettings> =\n {\n id: 'custom-spec',\n label: 'Custom Spec',\n description: DESCRIPTION,\n aiDescription:\n 'Manual template for editing after creation. Prefer explicit chart templates for assistant-created charts.',\n fields: [],\n buildTitle: titleFromDescription(DESCRIPTION),\n createSpec: (tableName): Spec =>\n ({\n plot: [\n {\n mark: 'rectY',\n data: {from: tableName, filterBy: '$brush'},\n x: {bin: 'field_name', maxbins: 25},\n y: {count: null},\n fill: 'steelblue',\n inset: 0.5,\n },\n {select: 'intervalX', as: '$brush'},\n ],\n xLabel: 'field_name',\n height: 200,\n width: 380,\n params: {brush: {select: 'crossfilter'}},\n }) as Spec,\n };\n"]}
@@ -0,0 +1,3 @@
1
+ export * from './schema';
2
+ export * from './definition';
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/chart-types/custom-spec/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC"}
@@ -0,0 +1,3 @@
1
+ export * from './schema';
2
+ export * from './definition';
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/chart-types/custom-spec/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC","sourcesContent":["export * from './schema';\nexport * from './definition';\n"]}
@@ -0,0 +1,11 @@
1
+ import { z } from 'zod';
2
+ export declare const CustomSpecChartSettings: z.ZodRecord<z.ZodString, z.ZodUnknown>;
3
+ export type CustomSpecChartSettings = z.infer<typeof CustomSpecChartSettings>;
4
+ export declare const CustomSpecChartConfig: z.ZodObject<{
5
+ chartType: z.ZodLiteral<"custom-spec">;
6
+ vgplot: z.ZodUnknown;
7
+ settingsOpen: z.ZodOptional<z.ZodBoolean>;
8
+ settings: z.ZodRecord<z.ZodString, z.ZodUnknown>;
9
+ }, z.core.$strip>;
10
+ export type CustomSpecChartConfig = z.infer<typeof CustomSpecChartConfig>;
11
+ //# sourceMappingURL=schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/chart-types/custom-spec/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,eAAO,MAAM,uBAAuB,wCAAoC,CAAC;AAEzE,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAE9E,eAAO,MAAM,qBAAqB;;;;;iBAKhC,CAAC;AAEH,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { z } from 'zod';
2
+ export const CustomSpecChartSettings = z.record(z.string(), z.unknown());
3
+ export const CustomSpecChartConfig = z.object({
4
+ chartType: z.literal('custom-spec'),
5
+ vgplot: z.unknown(),
6
+ settingsOpen: z.boolean().optional(),
7
+ settings: CustomSpecChartSettings,
8
+ });
9
+ //# sourceMappingURL=schema.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/chart-types/custom-spec/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;AAIzE,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC5C,SAAS,EAAE,CAAC,CAAC,OAAO,CAAC,aAAa,CAAC;IACnC,MAAM,EAAE,CAAC,CAAC,OAAO,EAAE;IACnB,YAAY,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IACpC,QAAQ,EAAE,uBAAuB;CAClC,CAAC,CAAC","sourcesContent":["import {z} from 'zod';\n\nexport const CustomSpecChartSettings = z.record(z.string(), z.unknown());\n\nexport type CustomSpecChartSettings = z.infer<typeof CustomSpecChartSettings>;\n\nexport const CustomSpecChartConfig = z.object({\n chartType: z.literal('custom-spec'),\n vgplot: z.unknown(),\n settingsOpen: z.boolean().optional(),\n settings: CustomSpecChartSettings,\n});\n\nexport type CustomSpecChartConfig = z.infer<typeof CustomSpecChartConfig>;\n"]}
@@ -0,0 +1,4 @@
1
+ import type { ChartTypeDefinition } from '../base-types';
2
+ import type { EcdfChartSettings } from './schema';
3
+ export declare const ecdfChartType: ChartTypeDefinition<EcdfChartSettings>;
4
+ //# sourceMappingURL=definition.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"definition.d.ts","sourceRoot":"","sources":["../../../src/chart-types/ecdf/definition.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAC,mBAAmB,EAAC,MAAM,eAAe,CAAC;AACvD,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,UAAU,CAAC;AAOhD,eAAO,MAAM,aAAa,EAAE,mBAAmB,CAAC,iBAAiB,CA4ChE,CAAC"}
@@ -0,0 +1,47 @@
1
+ import { QUANTITATIVE_COLUMN_TYPES } from '../../chart-builders/constants';
2
+ import { titleFromDescription } from '../../chart-builders/chartTypeUtils';
3
+ const FG_COLOR = 'var(--color-chart-1)';
4
+ const DESCRIPTION = 'Create an eCDF chart of a field';
5
+ export const ecdfChartType = {
6
+ id: 'ecdf',
7
+ label: 'eCDF',
8
+ description: DESCRIPTION,
9
+ aiDescription: 'Use for a cumulative distribution curve over one numeric or temporal column.',
10
+ fields: [
11
+ {
12
+ key: 'field',
13
+ label: 'Field',
14
+ required: true,
15
+ types: [...QUANTITATIVE_COLUMN_TYPES],
16
+ description: 'Numeric or temporal column used to build the cumulative distribution.',
17
+ },
18
+ ],
19
+ buildTitle: titleFromDescription(DESCRIPTION),
20
+ createSpec: (tableName, { field }) => ({
21
+ plot: [
22
+ {
23
+ mark: 'areaY',
24
+ data: { from: tableName, filterBy: '$brush' },
25
+ x: field,
26
+ y: { sum: field, cumulative: true },
27
+ fill: FG_COLOR,
28
+ fillOpacity: 0.3,
29
+ },
30
+ {
31
+ mark: 'lineY',
32
+ data: { from: tableName, filterBy: '$brush' },
33
+ x: field,
34
+ y: { sum: field, cumulative: true },
35
+ stroke: FG_COLOR,
36
+ },
37
+ { select: 'intervalX', as: '$brush' },
38
+ ],
39
+ xLabel: field,
40
+ yLabel: 'Cumulative',
41
+ height: 250,
42
+ width: 380,
43
+ margins: { left: 50, right: 20, top: 20, bottom: 50 },
44
+ params: { brush: { select: 'crossfilter' } },
45
+ }),
46
+ };
47
+ //# sourceMappingURL=definition.js.map