@ahoo-wang/wow-view-engine 9.2.0 → 9.2.2

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 (492) hide show
  1. package/README.md +12 -2
  2. package/README.zh-CN.md +12 -2
  3. package/dist/{actions-DK1yfiI8.js → actions-HgK33Jzg.js} +4333 -4645
  4. package/dist/actions-HgK33Jzg.js.map +1 -0
  5. package/dist/analysis/additive.d.ts +20 -0
  6. package/dist/analysis/additive.d.ts.map +1 -0
  7. package/dist/analysis/boxplot.d.ts +0 -7
  8. package/dist/analysis/boxplot.d.ts.map +1 -1
  9. package/dist/analysis/buckets.d.ts +31 -0
  10. package/dist/analysis/buckets.d.ts.map +1 -0
  11. package/dist/analysis/budget.d.ts +1 -1
  12. package/dist/analysis/budget.d.ts.map +1 -1
  13. package/dist/analysis/chart.d.ts.map +1 -1
  14. package/dist/analysis/chartShapes.d.ts +32 -0
  15. package/dist/analysis/chartShapes.d.ts.map +1 -0
  16. package/dist/analysis/chartSlots.d.ts +0 -24
  17. package/dist/analysis/chartSlots.d.ts.map +1 -1
  18. package/dist/analysis/chartSwitch.d.ts.map +1 -1
  19. package/dist/analysis/currency.d.ts +2 -1
  20. package/dist/analysis/currency.d.ts.map +1 -1
  21. package/dist/analysis/dangling.d.ts +3 -3
  22. package/dist/analysis/dangling.d.ts.map +1 -1
  23. package/dist/analysis/defaults.d.ts +1 -35
  24. package/dist/analysis/defaults.d.ts.map +1 -1
  25. package/dist/analysis/drill.d.ts +2 -43
  26. package/dist/analysis/drill.d.ts.map +1 -1
  27. package/dist/analysis/familyRules.d.ts +820 -0
  28. package/dist/analysis/familyRules.d.ts.map +1 -0
  29. package/dist/analysis/familySlots.d.ts +139 -0
  30. package/dist/analysis/familySlots.d.ts.map +1 -0
  31. package/dist/analysis/freeAlias.d.ts +9 -0
  32. package/dist/analysis/freeAlias.d.ts.map +1 -0
  33. package/dist/analysis/index.d.ts +7 -2
  34. package/dist/analysis/index.d.ts.map +1 -1
  35. package/dist/analysis/limitBounds.d.ts +28 -0
  36. package/dist/analysis/limitBounds.d.ts.map +1 -0
  37. package/dist/analysis/metricWindow.d.ts +2 -1
  38. package/dist/analysis/metricWindow.d.ts.map +1 -1
  39. package/dist/analysis/queryFilter.d.ts +3 -2
  40. package/dist/analysis/queryFilter.d.ts.map +1 -1
  41. package/dist/analysis/splitOther.d.ts +0 -21
  42. package/dist/analysis/splitOther.d.ts.map +1 -1
  43. package/dist/analysis/timeAxis.d.ts +3 -2
  44. package/dist/analysis/timeAxis.d.ts.map +1 -1
  45. package/dist/analysis/validateChart.d.ts +1 -21
  46. package/dist/analysis/validateChart.d.ts.map +1 -1
  47. package/dist/analysis/validateFamilies.d.ts +35 -0
  48. package/dist/analysis/validateFamilies.d.ts.map +1 -0
  49. package/dist/analysis/validateMetrics.d.ts.map +1 -1
  50. package/dist/capabilities/fields.d.ts +2 -1
  51. package/dist/capabilities/fields.d.ts.map +1 -1
  52. package/dist/capabilities/open.d.ts +2 -3
  53. package/dist/capabilities/open.d.ts.map +1 -1
  54. package/dist/cartesianBrush-HLU12ig5.js.map +1 -1
  55. package/dist/{clickDraft-DQDQn4x-.js → clickDraft-CLkSgQNG.js} +12 -12
  56. package/dist/{clickDraft-DQDQn4x-.js.map → clickDraft-CLkSgQNG.js.map} +1 -1
  57. package/dist/dashboard/panelFieldNames.d.ts +3 -2
  58. package/dist/dashboard/panelFieldNames.d.ts.map +1 -1
  59. package/dist/filter/compile.d.ts.map +1 -1
  60. package/dist/filter/describe.d.ts.map +1 -1
  61. package/dist/filter/fieldKind.d.ts +10 -0
  62. package/dist/filter/fieldKind.d.ts.map +1 -1
  63. package/dist/filter/index.d.ts +1 -0
  64. package/dist/filter/index.d.ts.map +1 -1
  65. package/dist/filter/kinds/enum.d.ts.map +1 -1
  66. package/dist/filter/kinds/options.d.ts +2 -4
  67. package/dist/filter/kinds/options.d.ts.map +1 -1
  68. package/dist/filter/read.d.ts +17 -0
  69. package/dist/filter/read.d.ts.map +1 -0
  70. package/dist/filter/validate.d.ts.map +1 -1
  71. package/dist/index.d.ts +11 -5
  72. package/dist/index.d.ts.map +1 -1
  73. package/dist/index.js +44 -44
  74. package/dist/index.js.map +1 -1
  75. package/dist/model/issue.d.ts +1 -1
  76. package/dist/model/issue.d.ts.map +1 -1
  77. package/dist/react/actionRunner.d.ts +2 -1
  78. package/dist/react/actionRunner.d.ts.map +1 -1
  79. package/dist/react/index.d.ts +1 -1
  80. package/dist/react/index.d.ts.map +1 -1
  81. package/dist/react/issues.d.ts +1 -1
  82. package/dist/react/issues.d.ts.map +1 -1
  83. package/dist/react/manager/order.d.ts +2 -1
  84. package/dist/react/manager/order.d.ts.map +1 -1
  85. package/dist/react/manager/queue.d.ts +2 -1
  86. package/dist/react/manager/queue.d.ts.map +1 -1
  87. package/dist/react/manager/useCommandRunner.d.ts +3 -3
  88. package/dist/react/manager/useCommandRunner.d.ts.map +1 -1
  89. package/dist/react/recordSelection.d.ts +1 -1
  90. package/dist/react/recordSelection.d.ts.map +1 -1
  91. package/dist/react/useAnalysisResult.d.ts.map +1 -1
  92. package/dist/react/useAutoRefresh.d.ts.map +1 -1
  93. package/dist/react/useDashboard.d.ts.map +1 -1
  94. package/dist/react/useFilterEditor.d.ts +2 -1
  95. package/dist/react/useFilterEditor.d.ts.map +1 -1
  96. package/dist/react/useReshape.d.ts +2 -1
  97. package/dist/react/useReshape.d.ts.map +1 -1
  98. package/dist/react/useViewEngine.d.ts.map +1 -1
  99. package/dist/react/useViewManager.d.ts.map +1 -1
  100. package/dist/react/workbench/handOver.d.ts.map +1 -1
  101. package/dist/react/workbench/newView.d.ts +2 -1
  102. package/dist/react/workbench/newView.d.ts.map +1 -1
  103. package/dist/react-2oicrdUx.js +3672 -0
  104. package/dist/react-2oicrdUx.js.map +1 -0
  105. package/dist/react.js +2 -2
  106. package/dist/record/compile.d.ts +1 -3
  107. package/dist/record/compile.d.ts.map +1 -1
  108. package/dist/record/index.d.ts +1 -0
  109. package/dist/record/index.d.ts.map +1 -1
  110. package/dist/record/summaryAlias.d.ts +4 -0
  111. package/dist/record/summaryAlias.d.ts.map +1 -0
  112. package/dist/runtime/actionReads.d.ts +20 -0
  113. package/dist/runtime/actionReads.d.ts.map +1 -0
  114. package/dist/runtime/actions.d.ts +4 -9
  115. package/dist/runtime/actions.d.ts.map +1 -1
  116. package/dist/runtime/admission.d.ts +13 -5
  117. package/dist/runtime/admission.d.ts.map +1 -1
  118. package/dist/runtime/autoApply.d.ts +2 -1
  119. package/dist/runtime/autoApply.d.ts.map +1 -1
  120. package/dist/runtime/capabilities.d.ts +3 -2
  121. package/dist/runtime/capabilities.d.ts.map +1 -1
  122. package/dist/runtime/dashboard/commands.d.ts +2 -1
  123. package/dist/runtime/dashboard/commands.d.ts.map +1 -1
  124. package/dist/runtime/dashboard/editing.d.ts +2 -1
  125. package/dist/runtime/dashboard/editing.d.ts.map +1 -1
  126. package/dist/runtime/dashboard/filterCandidates.d.ts +2 -1
  127. package/dist/runtime/dashboard/filterCandidates.d.ts.map +1 -1
  128. package/dist/runtime/dashboard/filterValues.d.ts +2 -1
  129. package/dist/runtime/dashboard/filterValues.d.ts.map +1 -1
  130. package/dist/runtime/dashboard/history.d.ts +2 -1
  131. package/dist/runtime/dashboard/history.d.ts.map +1 -1
  132. package/dist/runtime/dashboard/owned.d.ts +2 -1
  133. package/dist/runtime/dashboard/owned.d.ts.map +1 -1
  134. package/dist/runtime/dashboard/panelRun.d.ts +4 -3
  135. package/dist/runtime/dashboard/panelRun.d.ts.map +1 -1
  136. package/dist/runtime/dashboard/press.d.ts +2 -1
  137. package/dist/runtime/dashboard/press.d.ts.map +1 -1
  138. package/dist/runtime/define/fields.d.ts +2 -1
  139. package/dist/runtime/define/fields.d.ts.map +1 -1
  140. package/dist/runtime/execute.d.ts +1 -1
  141. package/dist/runtime/execute.d.ts.map +1 -1
  142. package/dist/runtime/{failures.d.ts → failure/failures.d.ts} +5 -4
  143. package/dist/runtime/failure/failures.d.ts.map +1 -0
  144. package/dist/runtime/{issueReport.d.ts → failure/issueReport.d.ts} +3 -1
  145. package/dist/runtime/failure/issueReport.d.ts.map +1 -0
  146. package/dist/runtime/{issues.d.ts → failure/issues.d.ts} +1 -9
  147. package/dist/runtime/failure/issues.d.ts.map +1 -0
  148. package/dist/runtime/{queryFailure.d.ts → failure/queryFailure.d.ts} +2 -2
  149. package/dist/runtime/failure/queryFailure.d.ts.map +1 -0
  150. package/dist/runtime/failure/sourceReason.d.ts.map +1 -0
  151. package/dist/runtime/{unavailable.d.ts → failure/unavailable.d.ts} +8 -1
  152. package/dist/runtime/failure/unavailable.d.ts.map +1 -0
  153. package/dist/runtime/listeners.d.ts +2 -1
  154. package/dist/runtime/listeners.d.ts.map +1 -1
  155. package/dist/runtime/panelViews.d.ts +3 -2
  156. package/dist/runtime/panelViews.d.ts.map +1 -1
  157. package/dist/runtime/permissions.d.ts +2 -1
  158. package/dist/runtime/permissions.d.ts.map +1 -1
  159. package/dist/runtime/recordRuntime.d.ts +1 -1
  160. package/dist/runtime/recordRuntime.d.ts.map +1 -1
  161. package/dist/runtime/requestRunner.d.ts +3 -2
  162. package/dist/runtime/requestRunner.d.ts.map +1 -1
  163. package/dist/runtime/resources.d.ts +14 -0
  164. package/dist/runtime/resources.d.ts.map +1 -1
  165. package/dist/runtime/runtimeFactory.d.ts +15 -2
  166. package/dist/runtime/runtimeFactory.d.ts.map +1 -1
  167. package/dist/runtime/runtimeStore.d.ts +2 -1
  168. package/dist/runtime/runtimeStore.d.ts.map +1 -1
  169. package/dist/runtime/storedViews.d.ts +0 -7
  170. package/dist/runtime/storedViews.d.ts.map +1 -1
  171. package/dist/runtime/tabMemory.d.ts +2 -1
  172. package/dist/runtime/tabMemory.d.ts.map +1 -1
  173. package/dist/runtime/viewEngine.d.ts.map +1 -1
  174. package/dist/runtime/viewRuntime.d.ts +2 -2
  175. package/dist/runtime/viewRuntime.d.ts.map +1 -1
  176. package/dist/runtime/writeLedger.d.ts +2 -1
  177. package/dist/runtime/writeLedger.d.ts.map +1 -1
  178. package/dist/store/ViewStore.d.ts +6 -5
  179. package/dist/store/ViewStore.d.ts.map +1 -1
  180. package/dist/testing.js +49 -42
  181. package/dist/testing.js.map +1 -1
  182. package/dist/ui/DashboardWorkbench.d.ts +8 -1
  183. package/dist/ui/DashboardWorkbench.d.ts.map +1 -1
  184. package/dist/ui/DataWorkbench.d.ts +2 -3
  185. package/dist/ui/DataWorkbench.d.ts.map +1 -1
  186. package/dist/ui/actions/ActionButtons.d.ts +2 -2
  187. package/dist/ui/actions/ActionButtons.d.ts.map +1 -1
  188. package/dist/ui/actions/ActionDialog.d.ts +2 -1
  189. package/dist/ui/actions/ActionDialog.d.ts.map +1 -1
  190. package/dist/ui/actions/ActionSurface.d.ts +3 -2
  191. package/dist/ui/actions/ActionSurface.d.ts.map +1 -1
  192. package/dist/ui/actions/BulkStatus.d.ts +2 -1
  193. package/dist/ui/actions/BulkStatus.d.ts.map +1 -1
  194. package/dist/ui/analysis/AnalysisChart.d.ts.map +1 -1
  195. package/dist/ui/analysis/AnalysisToolbar.d.ts +2 -1
  196. package/dist/ui/analysis/AnalysisToolbar.d.ts.map +1 -1
  197. package/dist/ui/analysis/ChartOptions.d.ts +2 -1
  198. package/dist/ui/analysis/ChartOptions.d.ts.map +1 -1
  199. package/dist/ui/analysis/ChartPicker.d.ts +2 -2
  200. package/dist/ui/analysis/ChartPicker.d.ts.map +1 -1
  201. package/dist/ui/analysis/DataTab.d.ts.map +1 -1
  202. package/dist/ui/analysis/DisplayTab.d.ts.map +1 -1
  203. package/dist/ui/analysis/DrillMenu.d.ts +2 -1
  204. package/dist/ui/analysis/DrillMenu.d.ts.map +1 -1
  205. package/dist/ui/analysis/DroppedNotice.d.ts +1 -8
  206. package/dist/ui/analysis/DroppedNotice.d.ts.map +1 -1
  207. package/dist/ui/analysis/EmptyResult.d.ts +2 -1
  208. package/dist/ui/analysis/EmptyResult.d.ts.map +1 -1
  209. package/dist/ui/analysis/HavingRows.d.ts +2 -1
  210. package/dist/ui/analysis/HavingRows.d.ts.map +1 -1
  211. package/dist/ui/analysis/OrderedCards.d.ts +3 -2
  212. package/dist/ui/analysis/OrderedCards.d.ts.map +1 -1
  213. package/dist/ui/analysis/SeriesList.d.ts +2 -1
  214. package/dist/ui/analysis/SeriesList.d.ts.map +1 -1
  215. package/dist/ui/analysis/SkeletonResult.d.ts +2 -1
  216. package/dist/ui/analysis/SkeletonResult.d.ts.map +1 -1
  217. package/dist/ui/analysis/Tray.d.ts +2 -1
  218. package/dist/ui/analysis/Tray.d.ts.map +1 -1
  219. package/dist/ui/analysis/VisualizationPanel.d.ts +3 -2
  220. package/dist/ui/analysis/VisualizationPanel.d.ts.map +1 -1
  221. package/dist/ui/analysis/drag.d.ts +2 -1
  222. package/dist/ui/analysis/drag.d.ts.map +1 -1
  223. package/dist/ui/analysis/exportOffer.d.ts +2 -1
  224. package/dist/ui/analysis/exportOffer.d.ts.map +1 -1
  225. package/dist/ui/analysis/listFocus.d.ts +3 -2
  226. package/dist/ui/analysis/listFocus.d.ts.map +1 -1
  227. package/dist/ui/analysis/virtualRows.d.ts +3 -2
  228. package/dist/ui/analysis/virtualRows.d.ts.map +1 -1
  229. package/dist/ui/charts/EChart.d.ts +3 -10
  230. package/dist/ui/charts/EChart.d.ts.map +1 -1
  231. package/dist/ui/charts/PieSlices.d.ts +0 -6
  232. package/dist/ui/charts/PieSlices.d.ts.map +1 -1
  233. package/dist/ui/charts/boxplotOption.d.ts +3 -2
  234. package/dist/ui/charts/boxplotOption.d.ts.map +1 -1
  235. package/dist/ui/charts/candlestickOption.d.ts +3 -2
  236. package/dist/ui/charts/candlestickOption.d.ts.map +1 -1
  237. package/dist/ui/charts/cartesianBrush.d.ts +2 -1
  238. package/dist/ui/charts/cartesianBrush.d.ts.map +1 -1
  239. package/dist/ui/charts/cartesianFit.d.ts +0 -5
  240. package/dist/ui/charts/cartesianFit.d.ts.map +1 -1
  241. package/dist/ui/charts/cartesianMarks.d.ts +1 -3
  242. package/dist/ui/charts/cartesianMarks.d.ts.map +1 -1
  243. package/dist/ui/charts/cartesianOption.d.ts +0 -5
  244. package/dist/ui/charts/cartesianOption.d.ts.map +1 -1
  245. package/dist/ui/charts/cartesianPlan.d.ts +2 -7
  246. package/dist/ui/charts/cartesianPlan.d.ts.map +1 -1
  247. package/dist/ui/charts/cartesianSeries.d.ts +42 -3
  248. package/dist/ui/charts/cartesianSeries.d.ts.map +1 -1
  249. package/dist/ui/charts/categoryFrame.d.ts +2 -1
  250. package/dist/ui/charts/categoryFrame.d.ts.map +1 -1
  251. package/dist/ui/charts/family.d.ts +2 -1
  252. package/dist/ui/charts/family.d.ts.map +1 -1
  253. package/dist/ui/charts/familyViews.d.ts +176 -0
  254. package/dist/ui/charts/familyViews.d.ts.map +1 -0
  255. package/dist/ui/charts/funnelFit.d.ts +1 -6
  256. package/dist/ui/charts/funnelFit.d.ts.map +1 -1
  257. package/dist/ui/charts/funnelOption.d.ts +2 -1
  258. package/dist/ui/charts/funnelOption.d.ts.map +1 -1
  259. package/dist/ui/charts/gaugeOption.d.ts +2 -1
  260. package/dist/ui/charts/gaugeOption.d.ts.map +1 -1
  261. package/dist/ui/charts/heatmapOption.d.ts +2 -1
  262. package/dist/ui/charts/heatmapOption.d.ts.map +1 -1
  263. package/dist/ui/charts/hierarchyOption.d.ts +4 -3
  264. package/dist/ui/charts/hierarchyOption.d.ts.map +1 -1
  265. package/dist/ui/charts/image.d.ts +2 -1
  266. package/dist/ui/charts/image.d.ts.map +1 -1
  267. package/dist/ui/charts/mapOption.d.ts +3 -2
  268. package/dist/ui/charts/mapOption.d.ts.map +1 -1
  269. package/dist/ui/charts/maps.d.ts +8 -1
  270. package/dist/ui/charts/maps.d.ts.map +1 -1
  271. package/dist/ui/charts/palette.d.ts +0 -2
  272. package/dist/ui/charts/palette.d.ts.map +1 -1
  273. package/dist/ui/charts/pieOption.d.ts +2 -1
  274. package/dist/ui/charts/pieOption.d.ts.map +1 -1
  275. package/dist/ui/charts/profileOption.d.ts +3 -2
  276. package/dist/ui/charts/profileOption.d.ts.map +1 -1
  277. package/dist/ui/charts/reading.d.ts +1 -15
  278. package/dist/ui/charts/reading.d.ts.map +1 -1
  279. package/dist/ui/charts/readingBasics.d.ts +44 -0
  280. package/dist/ui/charts/readingBasics.d.ts.map +1 -0
  281. package/dist/ui/charts/readingParts.d.ts +17 -0
  282. package/dist/ui/charts/readingParts.d.ts.map +1 -0
  283. package/dist/ui/charts/readingStatistics.d.ts.map +1 -1
  284. package/dist/ui/charts/scale.d.ts +2 -1
  285. package/dist/ui/charts/scale.d.ts.map +1 -1
  286. package/dist/ui/charts/sentence.d.ts +88 -13
  287. package/dist/ui/charts/sentence.d.ts.map +1 -1
  288. package/dist/ui/charts/sizes.d.ts +3 -2
  289. package/dist/ui/charts/sizes.d.ts.map +1 -1
  290. package/dist/ui/charts/sparklineOption.d.ts +2 -1
  291. package/dist/ui/charts/sparklineOption.d.ts.map +1 -1
  292. package/dist/ui/charts/theme.d.ts +0 -8
  293. package/dist/ui/charts/theme.d.ts.map +1 -1
  294. package/dist/ui/charts/timeOption.d.ts +3 -2
  295. package/dist/ui/charts/timeOption.d.ts.map +1 -1
  296. package/dist/ui/charts/treemapOption.d.ts +3 -2
  297. package/dist/ui/charts/treemapOption.d.ts.map +1 -1
  298. package/dist/ui/charts/waterfallOption.d.ts +3 -2
  299. package/dist/ui/charts/waterfallOption.d.ts.map +1 -1
  300. package/dist/ui/colorMode.d.ts +2 -1
  301. package/dist/ui/colorMode.d.ts.map +1 -1
  302. package/dist/ui/columns/ColumnRow.d.ts +2 -1
  303. package/dist/ui/columns/ColumnRow.d.ts.map +1 -1
  304. package/dist/ui/columns/ColumnSettings.d.ts.map +1 -1
  305. package/dist/ui/columns/WidthInput.d.ts +2 -1
  306. package/dist/ui/columns/WidthInput.d.ts.map +1 -1
  307. package/dist/ui/columns/rows.d.ts +2 -1
  308. package/dist/ui/columns/rows.d.ts.map +1 -1
  309. package/dist/ui/columns/sections.d.ts +2 -1
  310. package/dist/ui/columns/sections.d.ts.map +1 -1
  311. package/dist/ui/components/badge.d.ts +1 -1
  312. package/dist/ui/components/button.d.ts +1 -1
  313. package/dist/ui/components/item.d.ts +1 -1
  314. package/dist/ui/dashboard/Board.d.ts +2 -1
  315. package/dist/ui/dashboard/Board.d.ts.map +1 -1
  316. package/dist/ui/dashboard/BoardFilters.d.ts +2 -19
  317. package/dist/ui/dashboard/BoardFilters.d.ts.map +1 -1
  318. package/dist/ui/dashboard/ClickSettings.d.ts +2 -1
  319. package/dist/ui/dashboard/ClickSettings.d.ts.map +1 -1
  320. package/dist/ui/dashboard/ContentEditor.d.ts +2 -1
  321. package/dist/ui/dashboard/ContentEditor.d.ts.map +1 -1
  322. package/dist/ui/dashboard/EditBar.d.ts +2 -1
  323. package/dist/ui/dashboard/EditBar.d.ts.map +1 -1
  324. package/dist/ui/dashboard/FilterBar.d.ts +2 -1
  325. package/dist/ui/dashboard/FilterBar.d.ts.map +1 -1
  326. package/dist/ui/dashboard/FilterSettings.d.ts +2 -1
  327. package/dist/ui/dashboard/FilterSettings.d.ts.map +1 -1
  328. package/dist/ui/dashboard/PanelMarks.d.ts +0 -2
  329. package/dist/ui/dashboard/PanelMarks.d.ts.map +1 -1
  330. package/dist/ui/dashboard/PanelMenu.d.ts +3 -2
  331. package/dist/ui/dashboard/PanelMenu.d.ts.map +1 -1
  332. package/dist/ui/dashboard/PanelUnavailable.d.ts +2 -1
  333. package/dist/ui/dashboard/PanelUnavailable.d.ts.map +1 -1
  334. package/dist/ui/dashboard/ViewPicker.d.ts +3 -2
  335. package/dist/ui/dashboard/ViewPicker.d.ts.map +1 -1
  336. package/dist/ui/dashboard/buildShell.d.ts +3 -2
  337. package/dist/ui/dashboard/buildShell.d.ts.map +1 -1
  338. package/dist/ui/dashboard/building.d.ts.map +1 -1
  339. package/dist/ui/dashboard/commands.d.ts +2 -1
  340. package/dist/ui/dashboard/commands.d.ts.map +1 -1
  341. package/dist/ui/dashboard/gridBlocks.d.ts +3 -2
  342. package/dist/ui/dashboard/gridBlocks.d.ts.map +1 -1
  343. package/dist/ui/dashboard/gridPlacement.d.ts +2 -1
  344. package/dist/ui/dashboard/gridPlacement.d.ts.map +1 -1
  345. package/dist/ui/dashboard/history.d.ts +2 -1
  346. package/dist/ui/dashboard/history.d.ts.map +1 -1
  347. package/dist/ui/dashboard/press.d.ts +2 -1
  348. package/dist/ui/dashboard/press.d.ts.map +1 -1
  349. package/dist/ui/dashboard/scrollMore.d.ts +3 -2
  350. package/dist/ui/dashboard/scrollMore.d.ts.map +1 -1
  351. package/dist/ui/filter/ConditionPill.d.ts +10 -1
  352. package/dist/ui/filter/ConditionPill.d.ts.map +1 -1
  353. package/dist/ui/filter/GroupBlock.d.ts.map +1 -1
  354. package/dist/ui/filter/conditionFocus.d.ts +2 -1
  355. package/dist/ui/filter/conditionFocus.d.ts.map +1 -1
  356. package/dist/ui/filter/inputs/candidates.d.ts +2 -1
  357. package/dist/ui/filter/inputs/candidates.d.ts.map +1 -1
  358. package/dist/ui/filter/inputs/timeOfDay.d.ts +2 -1
  359. package/dist/ui/filter/inputs/timeOfDay.d.ts.map +1 -1
  360. package/dist/ui/index.d.ts +2 -1
  361. package/dist/ui/index.d.ts.map +1 -1
  362. package/dist/ui/kit/Announcer.d.ts +2 -1
  363. package/dist/ui/kit/Announcer.d.ts.map +1 -1
  364. package/dist/ui/kit/CopyButton.d.ts +2 -1
  365. package/dist/ui/kit/CopyButton.d.ts.map +1 -1
  366. package/dist/ui/kit/DragHandle.d.ts +2 -1
  367. package/dist/ui/kit/DragHandle.d.ts.map +1 -1
  368. package/dist/ui/kit/IconButton.d.ts +4 -3
  369. package/dist/ui/kit/IconButton.d.ts.map +1 -1
  370. package/dist/ui/kit/OutcomeActions.d.ts +4 -3
  371. package/dist/ui/kit/OutcomeActions.d.ts.map +1 -1
  372. package/dist/ui/kit/RenameInput.d.ts +2 -1
  373. package/dist/ui/kit/RenameInput.d.ts.map +1 -1
  374. package/dist/ui/kit/RowItem.d.ts +1 -1
  375. package/dist/ui/kit/RowItem.d.ts.map +1 -1
  376. package/dist/ui/kit/Truncated.d.ts +1 -1
  377. package/dist/ui/kit/Truncated.d.ts.map +1 -1
  378. package/dist/ui/kit/ViewSurface.d.ts +0 -17
  379. package/dist/ui/kit/ViewSurface.d.ts.map +1 -1
  380. package/dist/ui/kit/chartFailure.d.ts +2 -1
  381. package/dist/ui/kit/chartFailure.d.ts.map +1 -1
  382. package/dist/ui/kit/download.d.ts +2 -1
  383. package/dist/ui/kit/download.d.ts.map +1 -1
  384. package/dist/ui/kit/focus.d.ts +36 -1
  385. package/dist/ui/kit/focus.d.ts.map +1 -1
  386. package/dist/ui/kit/popups.d.ts +11 -3
  387. package/dist/ui/kit/popups.d.ts.map +1 -1
  388. package/dist/ui/kit/surfaceContext.d.ts +89 -0
  389. package/dist/ui/kit/surfaceContext.d.ts.map +1 -0
  390. package/dist/ui/kit/toolbar.d.ts +2 -1
  391. package/dist/ui/kit/toolbar.d.ts.map +1 -1
  392. package/dist/ui/kit/variants.d.ts +3 -3
  393. package/dist/ui/kit/variants.d.ts.map +1 -1
  394. package/dist/ui/manage/ViewManagerRow.d.ts +2 -1
  395. package/dist/ui/manage/ViewManagerRow.d.ts.map +1 -1
  396. package/dist/ui/messages/actions.d.ts +1 -0
  397. package/dist/ui/messages/actions.d.ts.map +1 -1
  398. package/dist/ui/messages/definition.d.ts +1 -0
  399. package/dist/ui/messages/definition.d.ts.map +1 -1
  400. package/dist/ui/messages/en.d.ts +2 -0
  401. package/dist/ui/messages/en.d.ts.map +1 -1
  402. package/dist/ui/messages/zh-CN.d.ts.map +1 -1
  403. package/dist/ui/record/CardSettings.d.ts +2 -1
  404. package/dist/ui/record/CardSettings.d.ts.map +1 -1
  405. package/dist/ui/record/ColumnResizer.d.ts +2 -1
  406. package/dist/ui/record/ColumnResizer.d.ts.map +1 -1
  407. package/dist/ui/record/DetailStructure.d.ts +2 -1
  408. package/dist/ui/record/DetailStructure.d.ts.map +1 -1
  409. package/dist/ui/record/EmptyResult.d.ts +2 -1
  410. package/dist/ui/record/EmptyResult.d.ts.map +1 -1
  411. package/dist/ui/record/OffscreenSummary.d.ts +2 -1
  412. package/dist/ui/record/OffscreenSummary.d.ts.map +1 -1
  413. package/dist/ui/record/RecordDetail.d.ts +2 -1
  414. package/dist/ui/record/RecordDetail.d.ts.map +1 -1
  415. package/dist/ui/record/RowCheckbox.d.ts +2 -1
  416. package/dist/ui/record/RowCheckbox.d.ts.map +1 -1
  417. package/dist/ui/record/SkeletonRows.d.ts +2 -1
  418. package/dist/ui/record/SkeletonRows.d.ts.map +1 -1
  419. package/dist/ui/record/SortableHeader.d.ts +2 -1
  420. package/dist/ui/record/SortableHeader.d.ts.map +1 -1
  421. package/dist/ui/record/SummaryRows.d.ts +2 -1
  422. package/dist/ui/record/SummaryRows.d.ts.map +1 -1
  423. package/dist/ui/record/columns.d.ts +2 -1
  424. package/dist/ui/record/columns.d.ts.map +1 -1
  425. package/dist/ui/record/detailPlacement.d.ts +2 -1
  426. package/dist/ui/record/detailPlacement.d.ts.map +1 -1
  427. package/dist/ui/record/emptyWayOut.d.ts +2 -1
  428. package/dist/ui/record/emptyWayOut.d.ts.map +1 -1
  429. package/dist/ui/record/headerRoving.d.ts +2 -2
  430. package/dist/ui/record/headerRoving.d.ts.map +1 -1
  431. package/dist/ui/record/openRows.d.ts +3 -2
  432. package/dist/ui/record/openRows.d.ts.map +1 -1
  433. package/dist/ui/record/overflow.d.ts +2 -3
  434. package/dist/ui/record/overflow.d.ts.map +1 -1
  435. package/dist/ui/record/pinCap.d.ts +0 -7
  436. package/dist/ui/record/pinCap.d.ts.map +1 -1
  437. package/dist/ui/record/sticky.d.ts +5 -4
  438. package/dist/ui/record/sticky.d.ts.map +1 -1
  439. package/dist/ui/record/useOffscreenColumns.d.ts +0 -6
  440. package/dist/ui/record/useOffscreenColumns.d.ts.map +1 -1
  441. package/dist/ui/sort/drag.d.ts +2 -1
  442. package/dist/ui/sort/drag.d.ts.map +1 -1
  443. package/dist/ui/theme/pairs.d.ts +3 -2
  444. package/dist/ui/theme/pairs.d.ts.map +1 -1
  445. package/dist/ui/theme/tokens.d.ts +10 -9
  446. package/dist/ui/theme/tokens.d.ts.map +1 -1
  447. package/dist/ui/workbench/ConditionBlock.d.ts +2 -1
  448. package/dist/ui/workbench/ConditionBlock.d.ts.map +1 -1
  449. package/dist/ui/workbench/OpeningSkeleton.d.ts +2 -1
  450. package/dist/ui/workbench/OpeningSkeleton.d.ts.map +1 -1
  451. package/dist/ui/workbench/ResultBlock.d.ts +3 -2
  452. package/dist/ui/workbench/ResultBlock.d.ts.map +1 -1
  453. package/dist/ui/workbench/Sidebar.d.ts +3 -2
  454. package/dist/ui/workbench/Sidebar.d.ts.map +1 -1
  455. package/dist/ui/workbench/StatusLine.d.ts +2 -1
  456. package/dist/ui/workbench/StatusLine.d.ts.map +1 -1
  457. package/dist/ui/workbench/TitleBar.d.ts +2 -1
  458. package/dist/ui/workbench/TitleBar.d.ts.map +1 -1
  459. package/dist/ui/workbench/ViewEngineProvider.d.ts +2 -1
  460. package/dist/ui/workbench/ViewEngineProvider.d.ts.map +1 -1
  461. package/dist/ui/workbench/address.d.ts +3 -12
  462. package/dist/ui/workbench/address.d.ts.map +1 -1
  463. package/dist/ui/workbench/configRemedy.d.ts +2 -1
  464. package/dist/ui/workbench/configRemedy.d.ts.map +1 -1
  465. package/dist/ui/workbench/useSidebarFold.d.ts +0 -9
  466. package/dist/ui/workbench/useSidebarFold.d.ts.map +1 -1
  467. package/dist/ui/workbench/useWorkbenchFolds.d.ts +3 -2
  468. package/dist/ui/workbench/useWorkbenchFolds.d.ts.map +1 -1
  469. package/dist/ui.js +13094 -12919
  470. package/dist/ui.js.map +1 -1
  471. package/dist/{viewRuntimeTypes-yK2rlUjK.js → viewRuntimeTypes-JEPw0nsg.js} +1787 -1197
  472. package/dist/viewRuntimeTypes-JEPw0nsg.js.map +1 -0
  473. package/package.json +16 -15
  474. package/dist/actions-DK1yfiI8.js.map +0 -1
  475. package/dist/react-DzstAsWB.js +0 -3648
  476. package/dist/react-DzstAsWB.js.map +0 -1
  477. package/dist/runtime/failures.d.ts.map +0 -1
  478. package/dist/runtime/issueReport.d.ts.map +0 -1
  479. package/dist/runtime/issues.d.ts.map +0 -1
  480. package/dist/runtime/queryFailure.d.ts.map +0 -1
  481. package/dist/runtime/sourceReason.d.ts.map +0 -1
  482. package/dist/runtime/unavailable.d.ts.map +0 -1
  483. package/dist/ui/theme/brandDocs.d.ts +0 -15
  484. package/dist/ui/theme/brandDocs.d.ts.map +0 -1
  485. package/dist/ui/theme/densityDocs.d.ts +0 -9
  486. package/dist/ui/theme/densityDocs.d.ts.map +0 -1
  487. package/dist/ui/theme/stateDocs.d.ts +0 -149
  488. package/dist/ui/theme/stateDocs.d.ts.map +0 -1
  489. package/dist/ui/theme/tokenDocs.d.ts +0 -25
  490. package/dist/ui/theme/tokenDocs.d.ts.map +0 -1
  491. package/dist/viewRuntimeTypes-yK2rlUjK.js.map +0 -1
  492. /package/dist/runtime/{sourceReason.d.ts → failure/sourceReason.d.ts} +0 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"familyRules.d.ts","sourceRoot":"","sources":["../../src/analysis/familyRules.ts"],"names":[],"mappings":"AAaA,OAAO,EAIL,KAAK,kBAAkB,EACvB,KAAK,WAAW,EAChB,KAAK,SAAS,EACd,KAAK,SAAS,EACd,KAAK,KAAK,EACV,KAAK,UAAU,EAChB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,KAAK,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAUnD,OAAO,EAiBL,KAAK,SAAS,EACf,MAAM,kBAAkB,CAAC;AAU1B,OAAO,EACL,aAAa,EACb,UAAU,EACV,eAAe,EACf,YAAY,EACZ,WAAW,EACX,aAAa,EACb,S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AAS;qBAEtD,SAAS,SAAS,SAAS,KAAG,SAAS;;;;;uBAiBhC,SAAS;sBAzBf,SAAS,KAAG,MAAM,GAAG,SAAS;uBAM7B,SAAS,QAAQ,SAAS,QAAQ,MAAM,KAAG,SAAS;qBAEtD,SAAS,SAAS,SAAS,KAAG,SAAS;;;;;uBAiBhC,SAAS;sBAzBf,SAAS,KAAG,MAAM,GAAG,SAAS;uBAM7B,SAAS,QAAQ,SAAS,QAAQ,MAAM,KAAG,SAAS;qBAEtD,SAAS,SAAS,SAAS,KAAG,SAAS;;;;;uBAiBhC,SAAS;sBAzBf,SAAS,KAAG,MAAM,GAAG,SAAS;uBAM7B,SAAS,QAAQ,SAAS,QAAQ,MAAM,KAAG,SAAS;qBAEtD,SAAS,SAAS,SAAS,KAAG,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uBAiBhC,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uBAAT,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA2WsB,CAAC;AAEpD;;;;GAIG;AACH,wBAAgB,WAAW,CACzB,IAAI,EAAE,SAAS,GACd,WAAW,CAAC,WAAW,CAAC,GAAG,SAAS,CAItC"}
@@ -0,0 +1,139 @@
1
+ import { BoxplotSpec, CalendarSpec, CandlestickSpec, CartesianSpec, ChartType, FunnelSpec, GaugeSpec, HeatmapSpec, HierarchySpec, MapSpec, MetricCardSpec, ParallelSpec, PieSpec, RadarSpec, SankeySpec, ScatterSpec, ThemeRiverSpec, TreemapSpec, WaterfallSpec } from '../model/index.js';
2
+ import { FiveNumbers } from './boxplot.js';
3
+ import { Ohlc } from './candlestick.js';
4
+ /**
5
+ * Each family's slots, filled from the shape in force: the rules
6
+ * `fitChartSlots` runs through the family's row of `FAMILY_RULES`
7
+ * (`familyRules.ts`). A slot the user chose is kept while the shape still
8
+ * has it; everything else is filled again.
9
+ */
10
+ /**
11
+ * What a card's headline may be: any metric over no dimension; over the one
12
+ * date dimension only one read off sums (`readsOffSums`, D38) — the first
13
+ * of those, when the one chosen is not.
14
+ */
15
+ export declare function headlines(shape: SlotShape): string[];
16
+ /** The aliases a chart may reference, and the facts a slot rule asks. */
17
+ export interface SlotShape {
18
+ /** What each metric is a quantity of (`metricMeasure`), by alias. */
19
+ measures: ReadonlyMap<string, string>;
20
+ groups: string[];
21
+ metrics: string[];
22
+ /** The metrics a mark can measure: every one that is not a moment. */
23
+ quantities: string[];
24
+ /** Each field's five numbers the quantities hold (`fiveNumberSets`). */
25
+ fiveNumbers: FiveNumbers[];
26
+ /** Each field's four numbers of a candle the quantities hold (`ohlcSets`). */
27
+ ohlc: Ohlc[];
28
+ /** Metrics the projection may add up across rows (a pie's merged tail). */
29
+ additive: Set<string>;
30
+ /**
31
+ * Metrics a card's trend can headline (`readsOffSums`): those that add,
32
+ * and the ratios of their sums (D38).
33
+ */
34
+ trendable: Set<string>;
35
+ dateGroups: string[];
36
+ /** The date groups bucketed by day: what a calendar lays out. */
37
+ dayGroups: string[];
38
+ }
39
+ /**
40
+ * The alias in this slot, or the one the shape offers for it.
41
+ *
42
+ * An empty string is what a slot with nothing to hold reads as — no group is
43
+ * named that — so the chart keeps a complete sub-object and validation names
44
+ * the slot instead of the family.
45
+ */
46
+ export declare function slot(chosen: string | undefined, available: readonly string[], at?: number): string;
47
+ /**
48
+ * A cartesian chart consumes every group: one on the horizontal axis, a second
49
+ * pivoted into a series per value. A pivot draws exactly one metric, so the
50
+ * series list narrows to one the moment a second group appears and opens back
51
+ * up to every metric when it goes.
52
+ *
53
+ * Between those two moments the series list is the analyst's (D20 屏 J): a
54
+ * list that still names metrics the shape has is kept exactly as it stands,
55
+ * because this function runs again on every redraw and a list re-derived
56
+ * there is a series the options panel cannot remove — pressed, it came
57
+ * straight back.
58
+ */
59
+ export declare function cartesianSlots(spec: CartesianSpec | undefined, shape: SlotShape, type: ChartType): CartesianSpec;
60
+ /**
61
+ * The mark a combo gives the series at `index` when nobody has chosen one:
62
+ * the first metric as bars, every other as a line — Metabase's combo, and
63
+ * the only reading of 「组合图」 that is not a bar chart under another name.
64
+ * Picking it used to draw every series as bars, and the analyst who asked
65
+ * for bars with a line saw nothing change (2026-09-23 audit P1-8). A mark
66
+ * the analyst picked on the options page is kept.
67
+ */
68
+ export declare function comboMark(index: number): 'bar' | 'line';
69
+ /**
70
+ * The axis a combo gives `metric` when nobody has chosen one: the first
71
+ * series' side (`leadSide`) when it measures the same kind of thing as the
72
+ * first series (`lead`), the other side when it does not.
73
+ *
74
+ * Decided by what the metrics are, not by their values, which this layer
75
+ * never sees (`metricMeasure`): a count beside an amount, an amount beside
76
+ * an average, a percent beside a count are two scales, and drawn on one the
77
+ * smaller lies flat along zero — the combo's second metric always sat on the
78
+ * left axis, and a count beside money read as nothing. Two metrics of one
79
+ * measure stay together even when their values are far apart: nothing says
80
+ * they differ, and one scale is what lets them be compared. An axis the
81
+ * analyst picked on the options page is theirs and is kept.
82
+ */
83
+ export declare function comboAxis(measures: ReadonlyMap<string, string>, lead: string | undefined, metric: string, leadSide?: 'left' | 'right'): 'left' | 'right';
84
+ /**
85
+ * A pie's slices are shares of a whole, so it measures what adds up (D33
86
+ * Q56), as the families below do (`summed`).
87
+ */
88
+ export declare function pieSlots(spec: PieSpec | undefined, shape: SlotShape): PieSpec;
89
+ export declare function heatmapSlots(spec: HeatmapSpec | undefined, shape: SlotShape): HeatmapSpec;
90
+ export declare function scatterSlots(spec: ScatterSpec | undefined, shape: SlotShape): ScatterSpec;
91
+ /**
92
+ * Stages come from metrics when there is nothing to group by, and otherwise
93
+ * from the values of the one group, whose business order is data this layer
94
+ * has never seen, so an order already written down is kept and an absent one
95
+ * stays absent for the editor to ask about. Either way a stage measures only
96
+ * what adds up — a record count or a sum.
97
+ */
98
+ export declare function funnelSlots(spec: FunnelSpec | undefined, shape: SlotShape): FunnelSpec;
99
+ /**
100
+ * The metrics a family that adds its numbers up may measure: the quantities
101
+ * that add (a record count or a sum), so a lead that does not — an average
102
+ * carried in from a bar chart — gives way to the first that does.
103
+ */
104
+ export declare function summed(shape: SlotShape): string[];
105
+ /** A waterfall steps along its one dimension and adds up one metric. */
106
+ export declare function waterfallSlots(spec: WaterfallSpec | undefined, shape: SlotShape): WaterfallSpec;
107
+ /**
108
+ * A treemap tiles one dimension; a second, when there is one, is the outer
109
+ * level the tiles nest in (`parent`), and goes when it does.
110
+ */
111
+ export declare function treemapSlots(spec: TreemapSpec | undefined, shape: SlotShape): TreemapSpec;
112
+ /**
113
+ * A card is one number, so it groups by nothing — unless it draws a sparkline,
114
+ * which needs exactly one date grouping and a headline read off sums, since
115
+ * that headline is the buckets summed whenever the totals query did not run
116
+ * — or, for a ratio of sums, their sums divided (D38).
117
+ */
118
+ export declare function cardSlots(spec: MetricCardSpec | undefined, shape: SlotShape): MetricCardSpec;
119
+ /** A box: one dimension, and a field's five numbers kept or found again. */
120
+ export declare function boxplotSlots(spec: BoxplotSpec | undefined, shape: SlotShape): BoxplotSpec;
121
+ /** A candle: one date dimension, and a field's four numbers. */
122
+ export declare function candlestickSlots(spec: CandlestickSpec | undefined, shape: SlotShape): CandlestickSpec;
123
+ /** Its scale and target are the analyst's, whichever metric it reads. */
124
+ export declare function gaugeSlots(spec: GaugeSpec | undefined, shape: SlotShape): GaugeSpec;
125
+ /** The map is the host's, and stays whichever region it shades. */
126
+ export declare function mapSlots(spec: MapSpec | undefined, shape: SlotShape): MapSpec;
127
+ /** A calendar lays out one dimension by day. */
128
+ export declare function calendarSlots(spec: CalendarSpec | undefined, shape: SlotShape): CalendarSpec;
129
+ /** The river runs along the date; the other dimension is its streams. */
130
+ export declare function riverSlots(spec: ThemeRiverSpec | undefined, shape: SlotShape): ThemeRiverSpec;
131
+ /**
132
+ * A sunburst, a tree or a sankey: every dimension is a level, in the
133
+ * analyst's order; the parts are sizes of a whole, so only what adds up
134
+ * measures them.
135
+ */
136
+ export declare function levelSlots(spec: HierarchySpec | SankeySpec | undefined, shape: SlotShape): HierarchySpec;
137
+ /** A radar or parallel axes: one dimension, and an axis per quantity. */
138
+ export declare function profileSlots(spec: RadarSpec | ParallelSpec | undefined, shape: SlotShape): RadarSpec;
139
+ //# sourceMappingURL=familySlots.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"familySlots.d.ts","sourceRoot":"","sources":["../../src/analysis/familySlots.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EACV,WAAW,EACX,YAAY,EACZ,eAAe,EAEf,aAAa,EACb,SAAS,EACT,UAAU,EACV,SAAS,EACT,WAAW,EACX,aAAa,EACb,OAAO,EACP,cAAc,EACd,YAAY,EACZ,OAAO,EACP,SAAS,EACT,UAAU,EACV,WAAW,EACX,cAAc,EACd,WAAW,EACX,aAAa,EACd,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAU,KAAK,WAAW,EAAE,MAAM,cAAc,CAAC;AACxD,OAAO,EAAW,KAAK,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAItD;;;;;GAKG;AAEH;;;;GAIG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,SAAS,GAAG,MAAM,EAAE,CAIpD;AAED,yEAAyE;AACzE,MAAM,WAAW,SAAS;IACxB,qEAAqE;IACrE,QAAQ,EAAE,WAAW,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACtC,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,sEAAsE;IACtE,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,wEAAwE;IACxE,WAAW,EAAE,WAAW,EAAE,CAAC;IAC3B,8EAA8E;IAC9E,IAAI,EAAE,IAAI,EAAE,CAAC;IACb,2EAA2E;IAC3E,QAAQ,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;IACtB;;;OAGG;IACH,SAAS,EAAE,GAAG,CAAC,MAAM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AC1C,KAAK,EAAE,SAAS,GACf,SAAS,CAKX"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * A name no group or metric is using: `base`'s stem plus the first free
3
+ * number. Numbering by the row count collided as soon as a row was removed,
4
+ * so the first free number it is, however rows were added and removed.
5
+ * Aliases are single-segment in Wow, so a field path becomes one token, and
6
+ * a copy of `amount_2` is `amount_<next>` rather than `amount_2_1`.
7
+ */
8
+ export declare function freeAlias(base: string, taken: readonly string[]): string;
9
+ //# sourceMappingURL=freeAlias.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"freeAlias.d.ts","sourceRoot":"","sources":["../../src/analysis/freeAlias.ts"],"names":[],"mappings":"AAaA;;;;;;GAMG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,SAAS,MAAM,EAAE,GAAG,MAAM,CAOxE"}
@@ -3,7 +3,9 @@
3
3
  * protocol, so compilation is a mapping and the interesting work is admission
4
4
  * and the shaping each chart family needs.
5
5
  */
6
+ export { isAdditiveMetric } from './additive.js';
6
7
  export * from './bucketChange.js';
8
+ export { bucketRange, wallClockAt, type BucketRange } from './buckets.js';
7
9
  export * from './candidates.js';
8
10
  export * from './capability.js';
9
11
  export * from './chart.js';
@@ -11,12 +13,15 @@ export * from './chartFamilies.js';
11
13
  export * from './chartOptions.js';
12
14
  export * from './chartSlots.js';
13
15
  export * from './chartSwitch.js';
16
+ export { comboAxis, comboMark } from './familySlots.js';
14
17
  export * from './compile.js';
15
18
  export * from './defaults.js';
16
- export { bucketRange, drillConditions, drillGroups, focusOn, groupFor, splitBy, wallClockAt, type BucketRange, type DrillContext, type DrilledGroup, } from './drill.js';
19
+ export { drillConditions, drillGroups, focusOn, groupFor, splitBy, type DrillContext, type DrilledGroup, } from './drill.js';
17
20
  export { drillFilter, narrowsTo } from './drillFilter.js';
18
21
  export * from './fitCharts.js';
19
22
  export * from './formula.js';
23
+ export * from './freeAlias.js';
24
+ export { limitBounds, type AnalysisLimitBounds } from './limitBounds.js';
20
25
  export * from './expand.js';
21
26
  export * from './granularity.js';
22
27
  export * from './having.js';
@@ -25,5 +30,5 @@ export { columnsAfterMove, moveMetric, type MetricMove, type MetricMoveStop, } f
25
30
  export { formulaFormat, metricFieldOf, metricFormat, metricFunctionOf, metricMeasure, metricMeasures, momentMetrics, readsAsItsField, type MetricFunction, } from './metricFormat.js';
26
31
  export * from './project.js';
27
32
  export * from './validate.js';
28
- export { isAdditiveMetric, isChartColor, validateChart, } from './validateChart.js';
33
+ export { isChartColor, validateChart } from './validateChart.js';
29
34
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/analysis/index.ts"],"names":[],"mappings":"AAaA;;;;GAIG;AACH,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,YAAY,CAAC;AAC3B,cAAc,oBAAoB,CAAC;AACnC,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC;AACjC,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAG9B,OAAO,EACL,WAAW,EACX,eAAe,EACf,WAAW,EACX,OAAO,EACP,QAAQ,EACR,OAAO,EACP,WAAW,EACX,KAAK,WAAW,EAChB,KAAK,YAAY,EACjB,KAAK,YAAY,GAClB,MAAM,YAAY,CAAC;AACpB,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAC1D,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,kBAAkB,CAAC;AACjC,cAAc,aAAa,CAAC;AAC5B,cAAc,sBAAsB,CAAC;AACrC,OAAO,EACL,gBAAgB,EAChB,UAAU,EACV,KAAK,UAAU,EACf,KAAK,cAAc,GACpB,MAAM,kBAAkB,CAAC;AAG1B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B,cAAc,sBAAsB,CAAC;AACrC,OAAO,EACL,gBAAgB,EAChB,UAAU,EACV,KAAK,UAAU,EACf,KAAK,cAAc,GACpB,MAAM,kBAAkB,CAAC;AAG1B,OAAO,EACL,aAAa,EACb,aAAa,EACb,YAAY,EACZ,gBAAgB,EAChB,aAAa,EACb,cAAc,EACd,aAAa,EACb,eAAe,EACf,KAAK,cAAc,GACpB,MAAM,mBAAmB,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC"}
@@ -0,0 +1,28 @@
1
+ import { AnalysisCapability, RuntimeLimits } from '../model/index.js';
2
+ /**
3
+ * The range 「前 N 组」 may take, and the N it stands for when nobody said one.
4
+ *
5
+ * `max` is the lowest of three ceilings — the capability's `maxLimit`, the
6
+ * runtime's `maxAnalysisRows` and Wow's own `AGGREGATION_LIMITS.MAX_LIMIT` —
7
+ * because a declaration may only lower what the layers under it allow; the
8
+ * least is 1, since Wow refuses a limit under it. It is also the most rows
9
+ * any query the engine compiles asks for — the probe row
10
+ * (`analysisProbeLimit`) and the split's whole (`splitWholeConfig`)
11
+ * included — since `maxAnalysisRows` is what the server admits: a Wow
12
+ * server's HTTP guard refuses more than 1,000 by default (D42).
13
+ *
14
+ * `fallback` is where a new view starts, and what an emptied 「前 N 组」
15
+ * field means: the model has no "no limit" (Wow answers at most `MAX_LIMIT`
16
+ * rows whatever is asked), so the honest reading of a blank is the number a
17
+ * view would have started at.
18
+ *
19
+ * One function for the three readers — the default config, the admission
20
+ * rule and the tray's field — so the bounds a field says out loud are the
21
+ * ones Apply is refused by, never a second copy of them.
22
+ */
23
+ export interface AnalysisLimitBounds {
24
+ max: number;
25
+ fallback: number;
26
+ }
27
+ export declare function limitBounds(capability: Pick<AnalysisCapability, 'limits'> | undefined, limits?: Pick<RuntimeLimits, 'maxAnalysisRows'>): AnalysisLimitBounds;
28
+ //# sourceMappingURL=limitBounds.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"limitBounds.d.ts","sourceRoot":"","sources":["../../src/analysis/limitBounds.ts"],"names":[],"mappings":"AAcA,OAAO,EAEL,KAAK,kBAAkB,EACvB,KAAK,aAAa,EACnB,MAAM,mBAAmB,CAAC;AAI3B;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,WAAW,mBAAmB;IAClC,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,wBAAgB,WAAW,CACzB,UAAU,EAAE,IAAI,CAAC,kBAAkB,EAAE,QAAQ,CAAC,GAAG,SAAS,EAC1D,MAAM,GAAE,IAAI,CAAC,aAAa,EAAE,iBAAiB,CAA0B,GACtE,mBAAmB,CAUrB"}
@@ -6,7 +6,7 @@ import { AnalysisViewConfig, RecordData } from '../model/index.js';
6
6
  * `clipped` where the question's dates cut the metric's short, so it
7
7
  * counts only part of the span its name says.
8
8
  */
9
- export type MetricReach = 'out' | 'clipped';
9
+ type MetricReach = 'out' | 'clipped';
10
10
  /**
11
11
  * Each metric whose own conditions pin a date the question's conditions
12
12
  * narrow (`appliedWindow` on both, at the moment the question was asked),
@@ -25,4 +25,5 @@ export declare function metricReach(config: AnalysisViewConfig, context: {
25
25
  * number of the period it names.
26
26
  */
27
27
  export declare function withoutOutOfReach(rows: readonly RecordData[], reach: ReadonlyMap<string, MetricReach>): RecordData[];
28
+ export {};
28
29
  //# sourceMappingURL=metricWindow.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"metricWindow.d.ts","sourceRoot":"","sources":["../../src/analysis/metricWindow.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAGV,kBAAkB,EAClB,UAAU,EACX,MAAM,mBAAmB,CAAC;AAI3B;;;;;;GAMG;AACH,MAAM,MAAM,WAAW,GAAG,KAAK,GAAG,SAAS,CAAC;AAE5C;;;;;;;GAOG;AACH,wBAAgB,WAAW,CACzB,MAAM,EAAE,kBAAkB,EAC1B,OAAO,EAAE;IAAE,GAAG,CAAC,EAAE,IAAI,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,GACxC,GAAG,CAAC,MAAM,EAAE,WAAW,CAAC,CA8B1B;AAED;;;;GAIG;AACH,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,SAAS,UAAU,EAAE,EAC3B,KAAK,EAAE,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,GACtC,UAAU,EAAE,CAQd"}
1
+ {"version":3,"file":"metricWindow.d.ts","sourceRoot":"","sources":["../../src/analysis/metricWindow.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAGV,kBAAkB,EAClB,UAAU,EACX,MAAM,mBAAmB,CAAC;AAI3B;;;;;;GAMG;AACH,KAAK,WAAW,GAAG,KAAK,GAAG,SAAS,CAAC;AAErC;;;;;;;GAOG;AACH,wBAAgB,WAAW,CACzB,MAAM,EAAE,kBAAkB,EAC1B,OAAO,EAAE;IAAE,GAAG,CAAC,EAAE,IAAI,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,GACxC,GAAG,CAAC,MAAM,EAAE,WAAW,CAAC,CA8B1B;AAED;;;;GAIG;AACH,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,SAAS,UAAU,EAAE,EAC3B,KAAK,EAAE,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,GACtC,UAAU,EAAE,CAQd"}
@@ -10,8 +10,8 @@ import { FieldKindRegistry } from '../filter/index.js';
10
10
  * root.
11
11
  */
12
12
  /** Where a filter sits, which decides what it may say and how it is reported. */
13
- export type QueryFilterPosition = 'metric' | 'element';
14
- export interface QueryFilterCheck {
13
+ type QueryFilterPosition = 'metric' | 'element';
14
+ interface QueryFilterCheck {
15
15
  tree: FilterTree;
16
16
  /**
17
17
  * The fields this filter may name, plus the ones it may not but that exist
@@ -29,4 +29,5 @@ export interface QueryFilterCheck {
29
29
  path: IssuePath;
30
30
  }
31
31
  export declare function queryFilterIssues(check: QueryFilterCheck): Issue[];
32
+ export {};
32
33
  //# sourceMappingURL=queryFilter.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"queryFilter.d.ts","sourceRoot":"","sources":["../../src/analysis/queryFilter.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EACV,eAAe,EAEf,UAAU,EACV,KAAK,EACL,SAAS,EACT,aAAa,EACd,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAQL,KAAK,iBAAiB,EACvB,MAAM,oBAAoB,CAAC;AAE5B;;;;;;;;GAQG;AACH,iFAAiF;AACjF,MAAM,MAAM,mBAAmB,GAAG,QAAQ,GAAG,SAAS,CAAC;AAavD,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,UAAU,CAAC;IACjB;;;;;;OAMG;IACH,MAAM,EAAE,SAAS,eAAe,EAAE,CAAC;IACnC,6DAA6D;IAC7D,UAAU,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACjC,KAAK,EAAE,iBAAiB,CAAC;IACzB,MAAM,EAAE,aAAa,CAAC;IACtB,QAAQ,EAAE,mBAAmB,CAAC;IAC9B,IAAI,EAAE,SAAS,CAAC;CACjB;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,gBAAgB,GAAG,KAAK,EAAE,CAclE"}
1
+ {"version":3,"file":"queryFilter.d.ts","sourceRoot":"","sources":["../../src/analysis/queryFilter.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EACV,eAAe,EAEf,UAAU,EACV,KAAK,EACL,SAAS,EACT,aAAa,EACd,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EASL,KAAK,iBAAiB,EACvB,MAAM,oBAAoB,CAAC;AAE5B;;;;;;;;GAQG;AACH,iFAAiF;AACjF,KAAK,mBAAmB,GAAG,QAAQ,GAAG,SAAS,CAAC;AAahD,UAAU,gBAAgB;IACxB,IAAI,EAAE,UAAU,CAAC;IACjB;;;;;;OAMG;IACH,MAAM,EAAE,SAAS,eAAe,EAAE,CAAC;IACnC,6DAA6D;IAC7D,UAAU,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACjC,KAAK,EAAE,iBAAiB,CAAC;IACzB,MAAM,EAAE,aAAa,CAAC;IACtB,QAAQ,EAAE,mBAAmB,CAAC;IAC9B,IAAI,EAAE,SAAS,CAAC;CACjB;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,gBAAgB,GAAG,KAAK,EAAE,CAclE"}
@@ -39,27 +39,6 @@ export declare function foldsSplit(config: AnalysisViewConfig, rows: readonly Re
39
39
  * since it is read by key.
40
40
  */
41
41
  export declare function splitWholeConfig(definition: DataViewDefinition, config: AnalysisViewConfig, limits?: Pick<RuntimeLimits, 'maxAnalysisRows'>): AnalysisViewConfig;
42
- /**
43
- * How big each of `data`'s series is (`data.series`' order), the one measure
44
- * a split's series are ranked by — for the order a legend reads and a stack
45
- * builds in (`bySize`), and for which seven a fold keeps (`foldOther`):
46
- *
47
- * - the series' own metric: a split draws exactly one
48
- * (`chart.splitBy.needs-one-series`), so every series of it measures the
49
- * same thing and the sizes compare;
50
- * - the numbers it measured — a value the kernel filled in (`filled`) is a
51
- * known 0 or nothing, never a size — each by its absolute value: a bar
52
- * under the axis is as big as one over it, and a channel that lost ¥1M is
53
- * not smaller than one that broke even (a profit, a net change);
54
- * - added up where the metric adds up (`additive`): a total is how much of
55
- * the whole the series holds; otherwise their mean, since a total of
56
- * averages grows with how many categories a series turns up in, not with
57
- * how big its numbers are.
58
- *
59
- * Computed from the drawn points, so the order is the engine's own and does
60
- * not rest on the order a source answers groups in.
61
- */
62
- export declare function seriesSizes(data: Pick<CartesianData, 'points' | 'series'>, additive: boolean): number[];
63
42
  /**
64
43
  * A split's series, the largest first (`seriesSizes`): what a reader looks
65
44
  * for first is the biggest, and a stack reads from the bottom up, so the
@@ -1 +1 @@
1
- {"version":3,"file":"splitOther.d.ts","sourceRoot":"","sources":["../../src/analysis/splitOther.ts"],"names":[],"mappings":"AAa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Aa,EACnB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAKpD;;;;;;;;;;;;;;GAcG;AAEH;;;;;;;;GAQG;AACH,wBAAgB,aAAa,CAAC,MAAM,EAAE,kBAAkB,GAAG,OAAO,CAYjE;AAED;;;GAGG;AACH,wBAAgB,UAAU,CACxB,MAAM,EAAE,kBAAkB,EAC1B,IAAI,EAAE,SAAS,UAAU,EAAE,GAC1B,OAAO,CAKT;AAED;;;;;;;GAOG;AACH,wBAAgB,gBAAgB,CAC9B,UAAU,EAAE,kBAAkB,EAC9B,MAAM,EAAE,kBAAkB,EAC1B,MAAM,CAAC,EAAE,IAAI,CAAC,aAAa,EAAE,iBAAiB,CAAC,GAC9C,kBAAkB,CAYpB;AAwCD;;;;;GAKG;AACH,wBAAgB,MAAM,CACpB,IAAI,EAAE,IAAI,CAAC,aAAa,EAAE,QAAQ,GAAG,QAAQ,CAAC,EAC9C,QAAQ,EAAE,OAAO,GAChB,aAAa,CAAC,QAAQ,CAAC,CAMzB;AAED;;;;;;;;GAQG;AACH,wBAAgB,SAAS,CACvB,IAAI,EAAE,aAAa,EACnB,MAAM,EAAE,kBAAkB,EAC1B,KAAK,EAAE,SAAS,UAAU,EAAE,GAC3B,aAAa,CA4Df"}
@@ -13,7 +13,7 @@ export type DateGroup = Extract<AnalysisGroup, {
13
13
  * came from, if it names one.
14
14
  */
15
15
  export declare function timeGroup(config: AnalysisViewConfig, alias: string | undefined): DateGroup | undefined;
16
- export type PartGroup = Extract<AnalysisGroup, {
16
+ type PartGroup = Extract<AnalysisGroup, {
17
17
  type: 'DATE_PART';
18
18
  }>;
19
19
  /** The calendar part dimension — the weekday, the hour — `alias` names, if it names one. */
@@ -84,7 +84,7 @@ export declare function forwardInTime<T>(items: readonly T[], at: (item: T) => u
84
84
  */
85
85
  export declare function withoutHoles<T>(items: readonly T[], at: (item: T) => unknown, group: DateGroup, timeZone: string, hole: (key: unknown) => T, window?: TimeWindow): T[];
86
86
  /** Instants `[from, to)` in epoch milliseconds: what a question was over. */
87
- export interface TimeWindow {
87
+ interface TimeWindow {
88
88
  from: number;
89
89
  to: number;
90
90
  }
@@ -170,4 +170,5 @@ export declare function consecutive<T>(items: readonly T[], at: (item: T) => unk
170
170
  * (`runtime/environment.ts`); a caller that knows the engine's passes it.
171
171
  */
172
172
  export declare function hostTimeZone(): string;
173
+ export {};
173
174
  //# sourceMappingURL=timeAxis.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"timeAxis.d.ts","sourceRoot":"","sources":["../../src/analysis/timeAxis.ts"],"names":[],"mappings":"AAeA,OAAO,KAAK,EACV,aAAa,EACb,kBAAkB,EAElB,UAAU,EACX,MAAM,mBAAmB,CAAC;AAU3B;;;;;GAKG;AAEH,MAAM,MAAM,SAAS,GAAG,OAAO,CAAC,aAAa,EAAE;IAAE,IAAI,EAAE,gBAAgB,CAAA;CAAE,CAAC,CAAC;AAE3E;;;GAGG;AACH,wBAAgB,SAAS,CACvB,MAAM,EAAE,kBAAkB,EAC1B,KAAK,EAAE,MAAM,GAAG,SAAS,GACxB,SAAS,GAAG,SAAS,CAKvB;AAED,MAAM,MAAM,SAAS,GAAG,OAAO,CAAC,aAAa,EAAE;IAAE,IAAI,EAAE,WAAW,CAAA;CAAE,CAAC,CAAC;AAEtE,4FAA4F;AAC5F,wBAAgB,SAAS,CACvB,MAAM,EAAE,kBAAkB,EAC1B,KAAK,EAAE,MAAM,GAAG,SAAS,GACxB,SAAS,GAAG,SAAS,CAKvB;AAED;;;;;;;;;GASG;AACH,wBAAgB,SAAS,CAAC,CAAC,EACzB,KAAK,EAAE,SAAS,CAAC,EAAE,EACnB,EAAE,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,OAAO,EACxB,KAAK,EAAE,SAAS,EAChB,IAAI,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,CAAC,GACvB,CAAC,EAAE,CAqBL;AAED;;;;;GAKG;AACH,wB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AAQ,EAAE,MAAM,EAChB,GAAG,EAAE,IAAI,GAAG,SAAS,GACpB;IAAE,EAAE,EAAE,OAAO,CAAA;CAAE,GAAG,SAAS,CAS7B;AAED;;;;;;;GAOG;AACH,wBAAgB,WAAW,CAAC,CAAC,EAC3B,KAAK,EAAE,SAAS,CAAC,EAAE,EACnB,EAAE,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,OAAO,EACxB,KAAK,EAAE,SAAS,EAChB,QAAQ,EAAE,MAAM,GACf,OAAO,CAST;AAuBD;;;GAGG;AACH,wBAAgB,YAAY,IAAI,MAAM,CAErC"}
@@ -1,24 +1,4 @@
1
- import { AnalysisDerivedExpression, AnalysisMetric, AnalysisViewConfig, Issue } from '../model/index.js';
2
- /**
3
- * Metrics the projection may add up across rows: a pie's "other" slice and a
4
- * metric card's trend headline are both sums of queried buckets, which only
5
- * means something for a metric that adds. AVG, MIN, MAX, DISTINCT_COUNT and a
6
- * percentile cannot be re-aggregated from their parts. A funnel's stages are
7
- * counts of what entered and remained, so they are these too.
8
- */
9
- export declare function isAdditiveMetric(metric: AnalysisMetric | undefined): boolean;
10
- /**
11
- * Whether a metric's number over any span is read off sums over that span
12
- * (D38): one that adds, or a derived metric computed from such metrics and
13
- * numbers alone — 客单价 = GMV ÷ 订单数. The source computes a derived metric
14
- * from each row's own operands, so a bucket's is its own sums divided and
15
- * the whole's the whole's sums divided — which is what a metric card's
16
- * trend and its whole need, though the ratios themselves never add.
17
- * `metricOf` finds an operand by alias.
18
- */
19
- export declare function readsOffSums(metric: AnalysisMetric | undefined, metricOf: (alias: string) => AnalysisMetric | undefined, through?: ReadonlySet<string>): boolean;
20
- /** Every metric a derived expression names, left to right. */
21
- export declare function derivedOperands(expression: AnalysisDerivedExpression): string[];
1
+ import { AnalysisViewConfig, Issue } from '../model/index.js';
22
2
  /**
23
3
  * Whether a saved colour is one the renderer may pass on. A chart colour
24
4
  * reaches the page as a colour — the drawing is handed it made concrete, the
@@ -1 +1 @@
1
- {"version":3,"file":"validateChart.d.ts","sourceRoot":"","sources":["../../src/analysis/validateChart.ts"],"names":[],"mappings":"AA0BA,OAAO,EAEL,KAAK,yBAAyB,EAC9B,KAAK,cAAc,EACnB,KAAK,kBAAkB,EAGvB,KAAK,KAAK,EAEX,MAAM,mBAAmB,CAAC;AAmB3B;;;;;;GAMG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,cAAc,GAAG,SAAS,GAAG,OAAO,CAI5E;AAED;;;;;;;;GAQG;AACH,wBAAgB,YAAY,CAC1B,MAAM,EAAE,cAAc,GAAG,SAAS,EAClC,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,cAAc,GAAG,SAAS,EACvD,OAAO,GAAE,WAAW,CAAC,MAAM,CAAa,GACvC,OAAO,CAOT;AAED,8DAA8D;AAC9D,wBAAgB,eAAe,CAC7B,UAAU,EAAE,yBAAyB,GACpC,MAAM,EAAE,CAYV;AAmBD;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,MAAM,CAI5D;AAkBD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,aAAa,CAC3B,MAAM,EAAE,kBAAkB,EAC1B,OAAO,GAAE,WAAW,CAAC,MAAM,CAAa,GACvC,KAAK,EAAE,CAqBT"}
1
+ {"version":3,"file":"validateChart.d.ts","sourceRoot":"","sources":["../../src/analysis/validateChart.ts"],"names":[],"mappings":"AA0BA,OAAO,EAEL,KAAK,kBAAkB,EAEvB,KAAK,KAAK,EAEX,MAAM,mBAAmB,CAAC;AAsB3B;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,MAAM,CAI5D;AAkBD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,aAAa,CAC3B,MAAM,EAAE,kBAAkB,EAC1B,OAAO,GAAE,WAAW,CAAC,MAAM,CAAa,GACvC,KAAK,EAAE,CAwBT"}
@@ -0,0 +1,35 @@
1
+ import { AnalysisViewConfig, Issue } from '../model/index.js';
2
+ import { ChartContext } from './chartRefs.js';
3
+ /**
4
+ * The rules of each family the D41 levels and time charts do not cover
5
+ * (those are `validateLevels.ts`): what `validateChart` runs through the
6
+ * family's row of `FAMILY_RULES` (`familyRules.ts`), once the chart names a
7
+ * known type and carries its family's sub-object.
8
+ */
9
+ /**
10
+ * A box is five numbers of one field: its lowest, three percentiles rising
11
+ * and its highest, under one condition (`isFiveNumberSet`). Each is a
12
+ * quantity the result has; together they must be such a set, or the box
13
+ * would draw a shape that says nothing.
14
+ */
15
+ export declare function boxplotIssues(context: ChartContext): Issue[];
16
+ /**
17
+ * A gauge is one number on a scale: it groups by nothing, as a card
18
+ * without a trend does, and its scale runs from a lower end to a higher.
19
+ */
20
+ export declare function gaugeIssues(context: ChartContext, config: AnalysisViewConfig): Issue[];
21
+ /**
22
+ * A radar or parallel axes: one axis per metric, three at least, each a
23
+ * quantity the result has and named once — two axes of one metric are one
24
+ * number drawn twice.
25
+ */
26
+ export declare function profileIssues(context: ChartContext): Issue[];
27
+ export declare function cartesianIssues(context: ChartContext, config: AnalysisViewConfig): Issue[];
28
+ export declare function pieIssues(context: ChartContext): Issue[];
29
+ export declare function heatmapIssues(context: ChartContext): Issue[];
30
+ export declare function scatterIssues(context: ChartContext): Issue[];
31
+ export declare function waterfallIssues(context: ChartContext): Issue[];
32
+ export declare function treemapIssues(context: ChartContext): Issue[];
33
+ export declare function funnelIssues(context: ChartContext, config: AnalysisViewConfig): Issue[];
34
+ export declare function cardIssues(context: ChartContext, config: AnalysisViewConfig): Issue[];
35
+ //# sourceMappingURL=validateFamilies.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validateFamilies.d.ts","sourceRoot":"","sources":["../../src/analysis/validateFamilies.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EACV,kBAAkB,EAElB,KAAK,EAEN,MAAM,mBAAmB,CAA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K,iBAAiB,EACvB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAIL,KAAK,aAAa,EACnB,MAAM,iBAAiB,CAAC;AAgBzB,wBAAgB,eAAe,CAC7B,MAAM,EAAE,kBAAkB,EAC1B,UAAU,EAAE,WAAW,CAAC,kBAAkB,CAAC,UAAU,CAAC,CAAC,EACvD,KAAK,EAAE,aAAa,EACpB,KAAK,EAAE,iBAAiB,EACxB,MAAM,EAAE,aAAa,GACpB,KAAK,EAAE,CAkOT"}
1
+ {"version":3,"file":"validateMetrics.d.ts","sourceRoot":"","sources":["../../src/analysis/validateMetrics.ts"],"names":[],"mappings":"AAaA,OAAO,EAOL,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EAEvB,KAAK,KAAK,EAEV,KAAK,aAAa,EACnB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAGL,KAAK,iBAAiB,EACvB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAIL,KAAK,aAAa,EACnB,MAAM,iBAAiB,CAAC;AAgBzB,wBAAgB,eAAe,CAC7B,MAAM,EAAE,kBAAkB,EAC1B,UAAU,EAAE,WAAW,CAAC,kBAAkB,CAAC,UAAU,CAAC,CAAC,EACvD,KAAK,EAAE,aAAa,EACpB,KAAK,EAAE,iBAAiB,EACxB,MAAM,EAAE,aAAa,GACpB,KAAK,EAAE,CA8CT"}
@@ -2,7 +2,7 @@ import { QueryModelDescriptor, QuerySemanticType } from '@ahoo-wang/wow-client';
2
2
  import { FieldDefinition, FieldNumeric, Issue, PagingMode } from '../model/index.js';
3
3
  import { FieldKindRegistry } from '../filter/index.js';
4
4
  /** What narrowing the fields reads, and where it puts what it finds. */
5
- export interface FieldContext {
5
+ interface FieldContext {
6
6
  descriptor: QueryModelDescriptor;
7
7
  kinds: FieldKindRegistry;
8
8
  /** The paging the definition's record view declares, which picks the sort. */
@@ -47,4 +47,5 @@ export declare function semanticText(semantic: QuerySemanticType): string;
47
47
  export declare function numericOf(semantic: QuerySemanticType | undefined): FieldNumeric | undefined;
48
48
  /** A capability the deployment lacks: said, never blocking. */
49
49
  export declare function warn(found: Issue): Issue;
50
+ export {};
50
51
  //# sourceMappingURL=fields.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"fields.d.ts","sourceRoot":"","sources":["../../src/capabilities/fields.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EACV,oBAAoB,EACpB,iBAAiB,EAClB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EASL,KAAK,eAAe,EACpB,KAAK,YAAY,EAGjB,KAAK,KAAK,EAEV,KAAK,UAAU,EAEhB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAIL,KAAK,iBAAiB,EACvB,MAAM,oBAAoB,CAAC;AAG5B,wEAAwE;AACxE,MAAM,WAAW,YAAY;IAC3B,UAAU,EAAE,oBAAoB,CAAC;IACjC,KAAK,EAAE,iBAAiB,CAAC;IACzB,8EAA8E;IAC9E,MAAM,EAAE,UAAU,GAAG,SAAS,CAAC;IAC/B,uEAAuE;IACvE,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC;;;OAGG;IACH,cAAc,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACpC;;;;;OAKG;IACH,aAAa,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACnC,QAAQ,EAAE,KAAK,EAAE,CAAC;CACnB;AAKD;;;;;;;GAOG;AACH,wBAAgB,YAAY,CAC1B,MAAM,EAAE,SAAS,eAAe,EAAE,EAClC,OAAO,EAAE,YAAY,GACpB,eAAe,EAAE,CAInB;AAoVD;;;GAGG;AACH,wBAAgB,YAAY,CAAC,QAAQ,EAAE,iBAAiB,GAAG,MAAM,CAiBhE;AAED;;;;;;GAMG;AACH,wBAAgB,SAAS,CACvB,QAAQ,EAAE,iBAAiB,GAAG,SAAS,GACtC,YAAY,GAAG,SAAS,CAe1B;AAkID,+DAA+D;AAC/D,wBAAgB,IAAI,CAAC,KAAK,EAAE,KAAK,GAAG,KAAK,CAExC"}
1
+ {"version":3,"file":"fields.d.ts","sourceRoot":"","sources":["../../src/capabilities/fields.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EACV,oBAAoB,EACpB,iBAAiB,EAClB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EASL,KAAK,eAAe,EACpB,KAAK,YAAY,EAGjB,KAAK,KAAK,EAEV,KAAK,UAAU,EAEhB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAIL,KAAK,iBAAiB,EACvB,MAAM,oBAAoB,CAAC;AAG5B,wEAAwE;AACxE,UAAU,YAAY;IACpB,UAAU,EAAE,oBAAoB,CAAC;IACjC,KAAK,EAAE,iBAAiB,CAAC;IACzB,8EAA8E;IAC9E,MAAM,EAAE,UAAU,GAAG,SAAS,CAAC;IAC/B,uEAAuE;IACvE,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAChC;;;OAGG;IACH,cAAc,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACpC;;;;;OAKG;IACH,aAAa,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;IACnC,QAAQ,EAAE,KAAK,EAAE,CAAC;CACnB;AAKD;;;;;;;GAOG;AACH,wBAAgB,YAAY,CAC1B,MAAM,EAAE,SAAS,eAAe,EAAE,EAClC,OAAO,EAAE,YAAY,GACpB,eAAe,EAAE,CAInB;AAoVD;;;GAGG;AACH,wBAAgB,YAAY,CAAC,QAAQ,EAAE,iBAAiB,GAAG,MAAM,CAiBhE;AAED;;;;;;GAMG;AACH,wBAAgB,SAAS,CACvB,QAAQ,EAAE,iBAAiB,GAAG,SAAS,GACtC,YAAY,GAAG,SAAS,CAe1B;AAkID,+DAA+D;AAC/D,wBAAgB,IAAI,CAAC,KAAK,EAAE,KAAK,GAAG,KAAK,CAExC"}
@@ -4,11 +4,9 @@ import { AnalysisCapability, DataViewDefinition, FieldDefinition, OpenCapabiliti
4
4
  * Where a narrowing asks for more than the descriptor grants: the field
5
5
  * (`null` for the analyses as a whole) and what.
6
6
  */
7
- export type Wider = (field: string | null, what: string) => void;
7
+ type Wider = (field: string | null, what: string) => void;
8
8
  /** The analyses the plan offers over `descriptor`; `undefined` for none. */
9
9
  export declare function describedAnalysis(plan: NonNullable<OpenCapabilities['analysis']>, fields: readonly FieldDefinition[], descriptor: QueryModelDescriptor, wider?: Wider): AnalysisCapability;
10
- /** Whether a root path sorts at the source, by the paging in force. */
11
- export declare function sortsAt(descriptor: QueryModelDescriptor, path: string, paging: 'paged' | 'cursor'): boolean;
12
10
  /**
13
11
  * A `defineView` definition with what it leaves to its source read from
14
12
  * `descriptor` rather than the snapshot it was built from, for the
@@ -22,4 +20,5 @@ export declare function sortsAt(descriptor: QueryModelDescriptor, path: string,
22
20
  * definition written by hand — as it is.
23
21
  */
24
22
  export declare function reopened(definition: DataViewDefinition, descriptor: QueryModelDescriptor): DataViewDefinition;
23
+ export {};
25
24
  //# sourceMappingURL=open.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"open.d.ts","sourceRoot":"","sources":["../../src/capabilities/open.ts"],"names":[],"mappings":"AAaA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAKL,KAAK,oBAAoB,EAC1B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAIL,KAAK,kBAAkB,EAGvB,KAAK,kBAAkB,EAEvB,KAAK,eAAe,EACpB,KAAK,gBAAgB,EACtB,MAAM,mBAAmB,CAAC;AAkC3B;;;GAGG;AACH,MAAM,MAAM,KAAK,GAAG,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;AAEjE,4EAA4E;AAC5E,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,WAAW,CAAC,gBAAgB,CAAC,UAAU,CAAC,CAAC,EAC/C,MAAM,EAAE,SAAS,eAAe,EAAE,EAClC,UAAU,EAAE,oBAAoB,EAChC,KAAK,GAAE,KAAgB,GACtB,kBAAkB,CAsDpB;AAgFD,uEAAuE;AACvE,wBAAgB,OAAO,CACrB,UAAU,EAAE,oBAAoB,EAChC,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,OAAO,GAAG,QAAQ,GACzB,OAAO,CAIT;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,QAAQ,CACtB,UAAU,EAAE,kBAAkB,EAC9B,UAAU,EAAE,oBAAoB,GAC/B,kBAAkB,CAiCpB"}
1
+ {"version":3,"file":"open.d.ts","sourceRoot":"","sources":["../../src/capabilities/open.ts"],"names":[],"mappings":"AAaA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAKL,KAAK,oBAAoB,EAC1B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAIL,KAAK,kBAAkB,EAGvB,KAAK,kBAAkB,EAEvB,KAAK,eAAe,EACpB,KAAK,gBAAgB,EACtB,MAAM,mBAAmB,CAAC;AAkC3B;;;GAGG;AACH,KAAK,KAAK,GAAG,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,EAAE,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;AAE1D,4EAA4E;AAC5E,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,WAAW,CAAC,gBAAgB,CAAC,UAAU,CAAC,CAAC,EAC/C,MAAM,EAAE,SAAS,eAAe,EAAE,EAClC,UAAU,EAAE,oBAAoB,EAChC,KAAK,GAAE,KAAgB,GACtB,kBAAkB,CAsDpB;AA2FD;;;;;;;;;;;GAWG;AACH,wBAAgB,QAAQ,CACtB,UAAU,EAAE,kBAAkB,EAC9B,UAAU,EAAE,oBAAoB,GAC/B,kBAAkB,CAiCpB"}
@@ -1 +1 @@
1
- {"version":3,"file":"cartesianBrush-HLU12ig5.js","names":["EChartsCoreOption","FADED_OPACITY","Lit","series","datum","faded","option","lit","Array","isArray","marks","flatMap","entry","Record","position","index","markIndex","data","count","length","any","some","from","_","at","map","fade","ONE_SERIES","Set","type","has","id","exec","Number","style","itemStyle","opacity","value","useSyncExternalStore","CartesianPlan","FADED_OPACITY","ChartTheme","brushes","plan","horizontal","context","pickable","data","points","length","BRUSH_ID","brushOption","theme","undefined","id","xAxisIndex","brushLink","brushType","brushMode","transformable","removeOnClick","toolbox","brushStyle","color","muted","borderColor","borderWidth","opacity","inBrush","outOfBrush","colorAlpha","withoutBrushToolbox","option","Record","toolboxRegistered","brush","list","Array","isArray","some","entry","BRUSH_CURSOR","type","key","const","BRUSH_CLEAR","areas","BrushedSpan","from","to","brushedSpan","said","count","area","range","coordRange","a","b","Number","isFinite","low","Math","max","round","min","high","useCoarsePointer","subscribe","coarse","_temp","COARSE","media","MediaQueryList","window","matchMedia","matches","change","addEventListener","removeEventListener","FADED_OPACITY","faded","series","option","lit","index","markIndex","entry","position","count","at","datum","fade","ONE_SERIES","id","style","brushes","plan","BRUSH_ID","brushOption","theme","withoutBrushToolbox","toolboxRegistered","BRUSH_CURSOR","BRUSH_CLEAR","brushedSpan","areas","said","range","a","b","low","high","useCoarsePointer","useSyncExternalStore","subscribe","coarse","_temp","COARSE","media","list","change"],"sources":["../src/ui/charts/highlight.ts","../src/ui/charts/cartesianBrush.ts"],"sourcesContent":["/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { EChartsCoreOption } from 'echarts/core';\n\n/**\n * How faint a mark that is not the group pressed is drawn: a dashboard panel\n * that set the board's filter keeps every group and marks the one pressed\n * (D22 I). Faded rather than hidden — the others are still the panel's\n * answer — and by opacity alone, so the palette and the marks' own colours\n * stay the theme's.\n */\nexport const FADED_OPACITY = 0.5;\n\n/**\n * Which of a series' data are the group pressed: `lit(series, datum)` is\n * asked for each drawn datum, `series` the index the family's option names\n * its marks by (`s{index}`, or the one series of a pie, a scatter or a\n * heatmap).\n */\nexport type Lit = (series: number, datum: number) => boolean;\n\n/**\n * The option with every datum that is not lit faded. Only the family's own\n * marks are touched — a series whose id is `s{n}` (the cartesian marks), or\n * the one series of a pie, a scatter or a heatmap — never a stack's totals or a reference line, which\n * stand for no group. Without `lit`, or with no datum it lights, the option\n * is handed back as it is, so a chart nothing was pressed on draws exactly\n * what it drew before.\n */\nexport function faded(\n option: EChartsCoreOption,\n lit: Lit | undefined,\n): EChartsCoreOption {\n const series = option.series;\n if (!lit || !Array.isArray(series)) return option;\n const marks = series.flatMap((entry: Record<string, unknown>, position) => {\n const index = markIndex(entry, position);\n return index === null || !Array.isArray(entry.data)\n ? []\n : [{ index, count: entry.data.length }];\n });\n // Nothing pressed on this chart — the value came from elsewhere, or its\n // group is not among the ones drawn — marks nothing, and fades nothing.\n const any = marks.some(({ index, count }) =>\n Array.from({ length: count }, (_, at) => at).some(at => lit(index, at)),\n );\n if (!any) return option;\n return {\n ...option,\n series: series.map((entry: Record<string, unknown>, position) => {\n const index = markIndex(entry, position);\n if (index === null || !Array.isArray(entry.data)) return entry;\n return {\n ...entry,\n data: entry.data.map((datum: unknown, at: number) =>\n lit(index, at) ? datum : fade(datum),\n ),\n };\n }),\n };\n}\n\n/** The families drawn as one series whose every datum is a group. */\nconst ONE_SERIES = new Set(['pie', 'scatter', 'heatmap']);\n\n/** The index a series stands for among the marks, or `null` for none. */\nfunction markIndex(entry: Record<string, unknown>, position: number) {\n if (typeof entry.type === 'string' && ONE_SERIES.has(entry.type))\n return position;\n const id = typeof entry.id === 'string' ? /^s(\\d+)$/.exec(entry.id) : null;\n return id ? Number(id[1]) : null;\n}\n\nfunction fade(datum: unknown): unknown {\n if (typeof datum === 'object' && datum !== null && 'value' in datum) {\n const style = (datum as { itemStyle?: object }).itemStyle ?? {};\n return {\n ...datum,\n itemStyle: { ...style, opacity: FADED_OPACITY },\n };\n }\n return { value: datum, itemStyle: { opacity: FADED_OPACITY } };\n}\n","/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { useSyncExternalStore } from 'react';\nimport type { CartesianPlan } from './cartesianPlan.js';\nimport { FADED_OPACITY } from './highlight.js';\nimport type { ChartTheme } from './theme.js';\n\n/**\n * Brushing a stretch of a time axis (D33 batch C, Q52): a drag along the\n * plot selects the buckets under it, and the follow-up menu a press on one\n * group opens is asked about all of them at once — 「这几天怎么了」. The\n * brush only chooses; what the stretch means as a condition is the\n * kernel's (`drillSpan`), and nothing here edits the view.\n *\n * Only along the axis (`lineX`), only one stretch at a time, and never\n * saved: the cover goes when the menu over it closes.\n */\n\n/** Whether a chart of this plan is brushed: upright, over time, pressable. */\nexport function brushes(plan: CartesianPlan): boolean {\n return (\n !plan.horizontal &&\n plan.context.brushes === true &&\n plan.context.pickable &&\n plan.data.points.length > 1\n );\n}\n\n/**\n * The id the brush component of this package's charts wears, by which the\n * toolbox the library injects for it is recognised (`withoutBrushToolbox`).\n */\nexport const BRUSH_ID = 'fve-brush';\n\n/**\n * The brush component a brushed chart carries, or nothing.\n *\n * Its cover is a quiet band in the muted ink, and the marks outside it fade as a pressed\n * group's neighbours do on a board (`FADED_OPACITY`), so what the stretch\n * holds reads while the drag is under way. No toolbox: the drag is always\n * on (`BRUSH_CURSOR`), and a press still presses — a drag shorter than the\n * library's threshold draws no cover, and a click is only a click when the\n * pointer barely moved.\n */\nexport function brushOption(\n plan: CartesianPlan,\n theme: ChartTheme,\n): object | undefined {\n if (!brushes(plan)) return undefined;\n return {\n id: BRUSH_ID,\n xAxisIndex: 0,\n brushLink: 'none',\n brushType: 'lineX',\n brushMode: 'single',\n transformable: false,\n removeOnClick: true,\n toolbox: [],\n brushStyle: {\n color: theme.muted,\n borderColor: theme.muted,\n borderWidth: 1,\n opacity: 0.18,\n },\n inBrush: {},\n outOfBrush: { colorAlpha: FADED_OPACITY },\n };\n}\n\n/**\n * The option without the toolbox the library's brush preprocessor put into\n * it for this package's brush — an option preprocessor, registered after the\n * brush (`echarts.ts`), so it runs before the library checks what the option\n * uses. The preprocessor adds a `toolbox` for the buttons it would draw; the\n * toolbox is not registered (analysis-echarts.md 2.4: +15.1KB for buttons\n * this package draws itself), so nothing was drawn, but a development build\n * logged 「Component toolbox is used but not imported」 in every host's\n * console. Only an option carrying this package's brush (`BRUSH_ID`) is\n * touched, and only while no toolbox is registered: a host drawing its own\n * charts with the same library, toolbox and all, keeps its toolbox.\n */\nexport function withoutBrushToolbox(\n option: Record<string, unknown> | undefined,\n toolboxRegistered: boolean,\n): void {\n if (!option || toolboxRegistered || !('toolbox' in option)) return;\n const brushes = option.brush;\n const list: unknown[] = Array.isArray(brushes) ? brushes : [brushes];\n if (list.some(entry => (entry as { id?: unknown } | null)?.id === BRUSH_ID))\n delete option.toolbox;\n}\n\n/**\n * What turns the brush on without a toolbox button: taken when a mouse or a\n * pen goes down on the plot, before the library sees the press, and again\n * after a whole new option has reset the component (`EChart`).\n */\nexport const BRUSH_CURSOR = {\n type: 'takeGlobalCursor',\n key: 'brush',\n brushOption: { brushType: 'lineX', brushMode: 'single' },\n} as const;\n\n/** What clears the cover once the menu over it has gone. */\nexport const BRUSH_CLEAR = { type: 'brush', areas: [] } as const;\n\n/** The first and the last category a brush covers, by index. */\nexport interface BrushedSpan {\n from: number;\n to: number;\n}\n\n/**\n * The categories a finished brush covers, read off the library's `brushEnd`\n * event — its one area's range along the category axis, which it gives in\n * category indexes — clamped to the `count` there are; `null` for a brush\n * that covers none (one taken away by a click, or dragged off the plot).\n */\nexport function brushedSpan(said: unknown, count: number): BrushedSpan | null {\n const areas = (said as { areas?: unknown } | null)?.areas;\n const area: unknown = Array.isArray(areas) ? areas[0] : undefined;\n const range = (area as { coordRange?: unknown } | undefined)?.coordRange;\n if (!Array.isArray(range) || range.length !== 2 || count === 0) return null;\n const [a, b] = range as unknown[];\n if (typeof a !== 'number' || typeof b !== 'number') return null;\n if (!Number.isFinite(a) || !Number.isFinite(b)) return null;\n // The library gives whole indexes on a category axis; were one to come\n // between two, it belongs to the nearer category.\n const low = Math.max(0, Math.round(Math.min(a, b)));\n const high = Math.min(count - 1, Math.round(Math.max(a, b)));\n return low <= high ? { from: low, to: high } : null;\n}\n\n/**\n * Whether the reader's main pointer is a finger (`pointer: coarse`): a\n * phone or a tablet, where a chart is brushed not at all. The library takes\n * a touch on the plot as the start of a drag and holds the page still under\n * it, so a finger that landed on a chart to scroll past it would brush it\n * instead; there the first tap reads a mark and the second opens its menu\n * (`EChart`), and the table layout picks a span with Shift where a keyboard\n * is. Read live; where the platform cannot say, a desktop is assumed.\n */\nexport function useCoarsePointer(): boolean {\n return useSyncExternalStore(subscribe, coarse, () => false);\n}\n\nconst COARSE = '(pointer: coarse)';\n\nfunction media(): MediaQueryList | null {\n return typeof window !== 'undefined' &&\n typeof window.matchMedia === 'function'\n ? window.matchMedia(COARSE)\n : null;\n}\n\nfunction coarse(): boolean {\n return media()?.matches ?? false;\n}\n\nfunction subscribe(change: () => void): () => void {\n const list = media();\n list?.addEventListener('change', change);\n return () => list?.removeEventListener('change', change);\n}\n"],"mappings":";;AAsBA,IAAaC,IAAgB;AAkB7B,SAAgBI,EACdC,GACAC,GACmB;CACnB,IAAMJ,IAASG,EAAOH;CActB,OAbI,CAACI,KAAO,CAACC,MAAMC,QAAQN,CAAM,KAY7B,CAXUA,EAAOQ,SAASC,GAAgCE,MAAa;EACzE,IAAMC,IAAQC,EAAUJ,GAAOE,CA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,KAAM,YACtC,CAACC,OAAOC,SAASH,CAAC,KAAK,CAACE,OAAOC,SAASF,CAAC,GAAG,OAAO;CAGvD,IAAMG,IAAMC,KAAKC,IAAI,GAAGD,KAAKE,MAAMF,KAAKG,IAAIR,GAAGC,CAAC,CAAC,CAAC,GAC5CQ,IAAOJ,KAAKG,IAAIZ,IAAQ,GAAGS,KAAKE,MAAMF,KAAKC,IAAIN,GAAGC,CAAC,CAAC,CAAC;CAC3D,OAAOG,KAAOK,IAAO;EAAEjB,MAAMY;EAAKX,IAAIgB;CAAK,IAAI;AACjD;AAWA,SAAOC,IAAA;CAAA,OACEpE,EAAqBqE,GAAWC,GAAQC,CAAW;AAAC;AADtD,SAAAA,IAAA;CAAA,OACgD;AAAK;AAG5D,IAAMC,IAAS;AAEf,SAASC,IAA+B;CACtC,OAAO,OAAOE,SAAW,OACvB,OAAOA,OAAOC,cAAe,aAC3BD,OAAOC,WAAWJ,CAAM,IACxB;AACN;AAEA,SAASF,IAAkB;CACzB,OAAOG,EAAM,CAAC,EAAEI,WAAW;AAC7B;AAEA,SAASR,EAAUS,GAAgC;CACjD,IAAMxC,IAAOmC,EAAM;CAEnB,OADAnC,GAAMyC,iBAAiB,UAAUD,CAAM,SAC1BxC,GAAM0C,oBAAoB,UAAUF,CAAM;AACzD"}
1
+ {"version":3,"file":"cartesianBrush-HLU12ig5.js","names":["EChartsCoreOption","FADED_OPACITY","Lit","series","datum","faded","option","lit","Array","isArray","marks","flatMap","entry","Record","position","index","markIndex","data","count","length","any","some","from","_","at","map","fade","ONE_SERIES","Set","type","has","id","exec","Number","style","itemStyle","opacity","value","useSyncExternalStore","CartesianPlan","FADED_OPACITY","ChartTheme","brushes","plan","horizontal","context","pickable","data","points","length","BRUSH_ID","brushOption","theme","undefined","id","xAxisIndex","brushLink","brushType","brushMode","transformable","removeOnClick","toolbox","brushStyle","color","muted","borderColor","borderWidth","opacity","inBrush","outOfBrush","colorAlpha","withoutBrushToolbox","option","Record","toolboxRegistered","brush","list","Array","isArray","some","entry","BRUSH_CURSOR","type","key","const","BRUSH_CLEAR","areas","BrushedSpan","from","to","brushedSpan","said","count","area","range","coordRange","a","b","Number","isFinite","low","Math","max","round","min","high","useCoarsePointer","subscribe","coarse","_temp","COARSE","media","MediaQueryList","window","matchMedia","matches","change","addEventListener","removeEventListener","FADED_OPACITY","faded","series","option","lit","index","markIndex","entry","position","count","at","datum","fade","ONE_SERIES","id","style","brushes","plan","BRUSH_ID","brushOption","theme","withoutBrushToolbox","toolboxRegistered","BRUSH_CURSOR","BRUSH_CLEAR","brushedSpan","areas","said","range","a","b","low","high","useCoarsePointer","useSyncExternalStore","subscribe","coarse","_temp","COARSE","media","list","change"],"sources":["../src/ui/charts/highlight.ts","../src/ui/charts/cartesianBrush.ts"],"sourcesContent":["/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { EChartsCoreOption } from 'echarts/core';\n\n/**\n * How faint a mark that is not the group pressed is drawn: a dashboard panel\n * that set the board's filter keeps every group and marks the one pressed\n * (D22 I). Faded rather than hidden — the others are still the panel's\n * answer — and by opacity alone, so the palette and the marks' own colours\n * stay the theme's.\n */\nexport const FADED_OPACITY = 0.5;\n\n/**\n * Which of a series' data are the group pressed: `lit(series, datum)` is\n * asked for each drawn datum, `series` the index the family's option names\n * its marks by (`s{index}`, or the one series of a pie, a scatter or a\n * heatmap).\n */\nexport type Lit = (series: number, datum: number) => boolean;\n\n/**\n * The option with every datum that is not lit faded. Only the family's own\n * marks are touched — a series whose id is `s{n}` (the cartesian marks), or\n * the one series of a pie, a scatter or a heatmap — never a stack's totals or a reference line, which\n * stand for no group. Without `lit`, or with no datum it lights, the option\n * is handed back as it is, so a chart nothing was pressed on draws exactly\n * what it drew before.\n */\nexport function faded(\n option: EChartsCoreOption,\n lit: Lit | undefined,\n): EChartsCoreOption {\n const series = option.series;\n if (!lit || !Array.isArray(series)) return option;\n const marks = series.flatMap((entry: Record<string, unknown>, position) => {\n const index = markIndex(entry, position);\n return index === null || !Array.isArray(entry.data)\n ? []\n : [{ index, count: entry.data.length }];\n });\n // Nothing pressed on this chart — the value came from elsewhere, or its\n // group is not among the ones drawn — marks nothing, and fades nothing.\n const any = marks.some(({ index, count }) =>\n Array.from({ length: count }, (_, at) => at).some(at => lit(index, at)),\n );\n if (!any) return option;\n return {\n ...option,\n series: series.map((entry: Record<string, unknown>, position) => {\n const index = markIndex(entry, position);\n if (index === null || !Array.isArray(entry.data)) return entry;\n return {\n ...entry,\n data: entry.data.map((datum: unknown, at: number) =>\n lit(index, at) ? datum : fade(datum),\n ),\n };\n }),\n };\n}\n\n/** The families drawn as one series whose every datum is a group. */\nconst ONE_SERIES = new Set(['pie', 'scatter', 'heatmap']);\n\n/** The index a series stands for among the marks, or `null` for none. */\nfunction markIndex(entry: Record<string, unknown>, position: number) {\n if (typeof entry.type === 'string' && ONE_SERIES.has(entry.type))\n return position;\n const id = typeof entry.id === 'string' ? /^s(\\d+)$/.exec(entry.id) : null;\n return id ? Number(id[1]) : null;\n}\n\nfunction fade(datum: unknown): unknown {\n if (typeof datum === 'object' && datum !== null && 'value' in datum) {\n const style = (datum as { itemStyle?: object }).itemStyle ?? {};\n return {\n ...datum,\n itemStyle: { ...style, opacity: FADED_OPACITY },\n };\n }\n return { value: datum, itemStyle: { opacity: FADED_OPACITY } };\n}\n","/*\n * Copyright [2021-present] [ahoo wang <ahoowang@qq.com> (https://github.com/Ahoo-Wang)].\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n * http://www.apache.org/licenses/LICENSE-2.0\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { useSyncExternalStore } from 'react';\nimport type { CartesianPlan } from './cartesianPlan.js';\nimport { FADED_OPACITY } from './highlight.js';\nimport type { ChartTheme } from './theme.js';\n\n/**\n * Brushing a stretch of a time axis (D33 batch C, Q52): a drag along the\n * plot selects the buckets under it, and the follow-up menu a press on one\n * group opens is asked about all of them at once — 「这几天怎么了」. The\n * brush only chooses; what the stretch means as a condition is the\n * kernel's (`drillSpan`), and nothing here edits the view.\n *\n * Only along the axis (`lineX`), only one stretch at a time, and never\n * saved: the cover goes when the menu over it closes.\n */\n\n/** Whether a chart of this plan is brushed: upright, over time, pressable. */\nexport function brushes(plan: CartesianPlan): boolean {\n return (\n !plan.horizontal &&\n plan.context.brushes === true &&\n plan.context.pickable &&\n plan.data.points.length > 1\n );\n}\n\n/**\n * The id the brush component of this package's charts wears, by which the\n * toolbox the library injects for it is recognised (`withoutBrushToolbox`).\n */\nexport const BRUSH_ID = 'fve-brush';\n\n/**\n * The brush component a brushed chart carries, or nothing.\n *\n * Its cover is a quiet band in the muted ink, and the marks outside it fade as a pressed\n * group's neighbours do on a board (`FADED_OPACITY`), so what the stretch\n * holds reads while the drag is under way. No toolbox: the drag is always\n * on (`BRUSH_CURSOR`), and a press still presses — a drag shorter than the\n * library's threshold draws no cover, and a click is only a click when the\n * pointer barely moved.\n */\nexport function brushOption(\n plan: CartesianPlan,\n theme: ChartTheme,\n): object | undefined {\n if (!brushes(plan)) return undefined;\n return {\n id: BRUSH_ID,\n xAxisIndex: 0,\n brushLink: 'none',\n brushType: 'lineX',\n brushMode: 'single',\n transformable: false,\n removeOnClick: true,\n toolbox: [],\n brushStyle: {\n color: theme.muted,\n borderColor: theme.muted,\n borderWidth: 1,\n opacity: 0.18,\n },\n inBrush: {},\n outOfBrush: { colorAlpha: FADED_OPACITY },\n };\n}\n\n/**\n * The option without the toolbox the library's brush preprocessor put into\n * it for this package's brush — an option preprocessor, registered after the\n * brush (`echarts.ts`), so it runs before the library checks what the option\n * uses. The preprocessor adds a `toolbox` for the buttons it would draw; the\n * toolbox is not registered (analysis-echarts.md 2.4: +15.1KB for buttons\n * this package draws itself), so nothing was drawn, but a development build\n * logged 「Component toolbox is used but not imported」 in every host's\n * console. Only an option carrying this package's brush (`BRUSH_ID`) is\n * touched, and only while no toolbox is registered: a host drawing its own\n * charts with the same library, toolbox and all, keeps its toolbox.\n */\nexport function withoutBrushToolbox(\n option: Record<string, unknown> | undefined,\n toolboxRegistered: boolean,\n): void {\n if (!option || toolboxRegistered || !('toolbox' in option)) return;\n const brushes = option.brush;\n const list: unknown[] = Array.isArray(brushes) ? brushes : [brushes];\n if (list.some(entry => (entry as { id?: unknown } | null)?.id === BRUSH_ID))\n delete option.toolbox;\n}\n\n/**\n * What turns the brush on without a toolbox button: taken when a mouse or a\n * pen goes down on the plot, before the library sees the press, and again\n * after a whole new option has reset the component (`EChart`).\n */\nexport const BRUSH_CURSOR = {\n type: 'takeGlobalCursor',\n key: 'brush',\n brushOption: { brushType: 'lineX', brushMode: 'single' },\n} as const;\n\n/** What clears the cover once the menu over it has gone. */\nexport const BRUSH_CLEAR = { type: 'brush', areas: [] } as const;\n\n/** The first and the last category a brush covers, by index. */\ninterface BrushedSpan {\n from: number;\n to: number;\n}\n\n/**\n * The categories a finished brush covers, read off the library's `brushEnd`\n * event — its one area's range along the category axis, which it gives in\n * category indexes — clamped to the `count` there are; `null` for a brush\n * that covers none (one taken away by a click, or dragged off the plot).\n */\nexport function brushedSpan(said: unknown, count: number): BrushedSpan | null {\n const areas = (said as { areas?: unknown } | null)?.areas;\n const area: unknown = Array.isArray(areas) ? areas[0] : undefined;\n const range = (area as { coordRange?: unknown } | undefined)?.coordRange;\n if (!Array.isArray(range) || range.length !== 2 || count === 0) return null;\n const [a, b] = range as unknown[];\n if (typeof a !== 'number' || typeof b !== 'number') return null;\n if (!Number.isFinite(a) || !Number.isFinite(b)) return null;\n // The library gives whole indexes on a category axis; were one to come\n // between two, it belongs to the nearer category.\n const low = Math.max(0, Math.round(Math.min(a, b)));\n const high = Math.min(count - 1, Math.round(Math.max(a, b)));\n return low <= high ? { from: low, to: high } : null;\n}\n\n/**\n * Whether the reader's main pointer is a finger (`pointer: coarse`): a\n * phone or a tablet, where a chart is brushed not at all. The library takes\n * a touch on the plot as the start of a drag and holds the page still under\n * it, so a finger that landed on a chart to scroll past it would brush it\n * instead; there the first tap reads a mark and the second opens its menu\n * (`EChart`), and the table layout picks a span with Shift where a keyboard\n * is. Read live; where the platform cannot say, a desktop is assumed.\n */\nexport function useCoarsePointer(): boolean {\n return useSyncExternalStore(subscribe, coarse, () => false);\n}\n\nconst COARSE = '(pointer: coarse)';\n\nfunction media(): MediaQueryList | null {\n return typeof window !== 'undefined' &&\n typeof window.matchMedia === 'function'\n ? window.matchMedia(COARSE)\n : null;\n}\n\nfunction coarse(): boolean {\n return media()?.matches ?? false;\n}\n\nfunction subscribe(change: () => void): () => void {\n const list = media();\n list?.addEventListener('change', change);\n return () => list?.removeEventListener('change', change);\n}\n"],"mappings":";;AAsBA,IAAaC,IAAgB;AAkB7B,SAAgBI,EACdC,GACAC,GACmB;CACnB,IAAMJ,IAASG,EAAOH;CActB,OAbI,CAACI,KAAO,CAACC,MAAMC,QAAQN,CAAM,KAY7B,CAXUA,EAAOQ,SAASC,GAAgCE,MAAa;EACzE,IAAMC,IAAQC,EAAUJ,GAAOE,CAAQ;EACvC,OAAOC,MAAU,QAAQ,CAACP,MAAMC,QAAQG,EAAMK,IAAI,IAC9C,CAAA,IACA,CAAC;GAAEF;GAAOG,OAAON,EAAMK,KAAKE;EAAO,CAAC;CAC1C,CAGYT,CAAAA,CAAMW,MAAM,EAAEN,UAAOG,eAC/BV,MAAMc,KAAK,EAAEH,QAAQD,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