@ggts-sh/svelte 0.43.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (656) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +97 -0
  3. package/bin/ggts-codemod.js +47 -0
  4. package/dist/GGPlot.svelte +491 -0
  5. package/dist/GGPlot.svelte.d.ts +67 -0
  6. package/dist/a11y/CanvasA11y.svelte +115 -0
  7. package/dist/a11y/CanvasA11y.svelte.d.ts +15 -0
  8. package/dist/a11y/canvas-a11y.d.ts +1 -0
  9. package/dist/a11y/canvas-a11y.js +2 -0
  10. package/dist/assembly/assemble.d.ts +1 -0
  11. package/dist/assembly/assemble.js +1 -0
  12. package/dist/assembly/labels.d.ts +43 -0
  13. package/dist/assembly/labels.js +126 -0
  14. package/dist/assembly/layout.d.ts +158 -0
  15. package/dist/assembly/layout.js +175 -0
  16. package/dist/chrome/StatusChrome.svelte +125 -0
  17. package/dist/chrome/StatusChrome.svelte.d.ts +16 -0
  18. package/dist/chrome/ToolRail.svelte +293 -0
  19. package/dist/chrome/ToolRail.svelte.d.ts +26 -0
  20. package/dist/chrome/chrome-state.svelte.d.ts +63 -0
  21. package/dist/chrome/chrome-state.svelte.js +158 -0
  22. package/dist/chrome/theme-css.d.ts +16 -0
  23. package/dist/chrome/theme-css.js +16 -0
  24. package/dist/codemod/cli.d.ts +16 -0
  25. package/dist/codemod/cli.js +150 -0
  26. package/dist/codemod/edits.d.ts +28 -0
  27. package/dist/codemod/edits.js +36 -0
  28. package/dist/codemod/index.d.ts +10 -0
  29. package/dist/codemod/index.js +10 -0
  30. package/dist/codemod/migrate-plot-props-rewrite.d.ts +86 -0
  31. package/dist/codemod/migrate-plot-props-rewrite.js +228 -0
  32. package/dist/codemod/migrate-plot-props.d.ts +38 -0
  33. package/dist/codemod/migrate-plot-props.js +159 -0
  34. package/dist/coord/Coord.svelte +21 -0
  35. package/dist/coord/Coord.svelte.d.ts +16 -0
  36. package/dist/coord/CoordCartesian.svelte +11 -0
  37. package/dist/coord/CoordCartesian.svelte.d.ts +18 -0
  38. package/dist/coord/CoordFixed.svelte +17 -0
  39. package/dist/coord/CoordFixed.svelte.d.ts +10 -0
  40. package/dist/coord/CoordFlip.svelte +11 -0
  41. package/dist/coord/CoordFlip.svelte.d.ts +18 -0
  42. package/dist/coord/CoordPolar.svelte +16 -0
  43. package/dist/coord/CoordPolar.svelte.d.ts +9 -0
  44. package/dist/coord/CoordRadial.svelte +16 -0
  45. package/dist/coord/CoordRadial.svelte.d.ts +9 -0
  46. package/dist/coord/CoordSf.svelte +16 -0
  47. package/dist/coord/CoordSf.svelte.d.ts +9 -0
  48. package/dist/coord/CoordTransform.svelte +16 -0
  49. package/dist/coord/CoordTransform.svelte.d.ts +9 -0
  50. package/dist/data/index.d.ts +1 -0
  51. package/dist/data/index.js +2 -0
  52. package/dist/diagnostics/composition.d.ts +112 -0
  53. package/dist/diagnostics/composition.js +203 -0
  54. package/dist/diagnostics/deprecation.d.ts +58 -0
  55. package/dist/diagnostics/deprecation.js +27 -0
  56. package/dist/diagnostics/plot-engine-diagnostics.svelte.d.ts +44 -0
  57. package/dist/diagnostics/plot-engine-diagnostics.svelte.js +193 -0
  58. package/dist/facet/Facet.svelte +23 -0
  59. package/dist/facet/Facet.svelte.d.ts +16 -0
  60. package/dist/facet/FacetGrid.svelte +32 -0
  61. package/dist/facet/FacetGrid.svelte.d.ts +16 -0
  62. package/dist/facet/FacetWrap.svelte +32 -0
  63. package/dist/facet/FacetWrap.svelte.d.ts +16 -0
  64. package/dist/fonts/RobotoCondensed-Bold.ttf +0 -0
  65. package/dist/fonts/RobotoCondensed-Light.ttf +0 -0
  66. package/dist/fonts/RobotoCondensed-Regular.ttf +0 -0
  67. package/dist/fonts/THIRD_PARTY_NOTICES.txt +416 -0
  68. package/dist/geoms/GeomAbline.svelte +25 -0
  69. package/dist/geoms/GeomAbline.svelte.d.ts +7 -0
  70. package/dist/geoms/GeomArea.svelte +12 -0
  71. package/dist/geoms/GeomArea.svelte.d.ts +7 -0
  72. package/dist/geoms/GeomBar.svelte +12 -0
  73. package/dist/geoms/GeomBar.svelte.d.ts +7 -0
  74. package/dist/geoms/GeomBin2d.svelte +21 -0
  75. package/dist/geoms/GeomBin2d.svelte.d.ts +7 -0
  76. package/dist/geoms/GeomBlank.svelte +12 -0
  77. package/dist/geoms/GeomBlank.svelte.d.ts +7 -0
  78. package/dist/geoms/GeomBoxplot.svelte +25 -0
  79. package/dist/geoms/GeomBoxplot.svelte.d.ts +7 -0
  80. package/dist/geoms/GeomCol.svelte +12 -0
  81. package/dist/geoms/GeomCol.svelte.d.ts +7 -0
  82. package/dist/geoms/GeomContour.svelte +25 -0
  83. package/dist/geoms/GeomContour.svelte.d.ts +7 -0
  84. package/dist/geoms/GeomCount.svelte +12 -0
  85. package/dist/geoms/GeomCount.svelte.d.ts +7 -0
  86. package/dist/geoms/GeomCrossbar.svelte +25 -0
  87. package/dist/geoms/GeomCrossbar.svelte.d.ts +7 -0
  88. package/dist/geoms/GeomCurve.svelte +21 -0
  89. package/dist/geoms/GeomCurve.svelte.d.ts +7 -0
  90. package/dist/geoms/GeomDensity.svelte +25 -0
  91. package/dist/geoms/GeomDensity.svelte.d.ts +7 -0
  92. package/dist/geoms/GeomDensity2d.svelte +25 -0
  93. package/dist/geoms/GeomDensity2d.svelte.d.ts +7 -0
  94. package/dist/geoms/GeomDensity2dFilled.svelte +25 -0
  95. package/dist/geoms/GeomDensity2dFilled.svelte.d.ts +7 -0
  96. package/dist/geoms/GeomDotplot.svelte +25 -0
  97. package/dist/geoms/GeomDotplot.svelte.d.ts +7 -0
  98. package/dist/geoms/GeomErrorbar.svelte +25 -0
  99. package/dist/geoms/GeomErrorbar.svelte.d.ts +7 -0
  100. package/dist/geoms/GeomFreqpoly.svelte +25 -0
  101. package/dist/geoms/GeomFreqpoly.svelte.d.ts +7 -0
  102. package/dist/geoms/GeomFunction.svelte +25 -0
  103. package/dist/geoms/GeomFunction.svelte.d.ts +7 -0
  104. package/dist/geoms/GeomHex.svelte +21 -0
  105. package/dist/geoms/GeomHex.svelte.d.ts +7 -0
  106. package/dist/geoms/GeomHistogram.svelte +25 -0
  107. package/dist/geoms/GeomHistogram.svelte.d.ts +7 -0
  108. package/dist/geoms/GeomHline.svelte +12 -0
  109. package/dist/geoms/GeomHline.svelte.d.ts +7 -0
  110. package/dist/geoms/GeomJitter.svelte +35 -0
  111. package/dist/geoms/GeomJitter.svelte.d.ts +13 -0
  112. package/dist/geoms/GeomLabel.svelte +12 -0
  113. package/dist/geoms/GeomLabel.svelte.d.ts +7 -0
  114. package/dist/geoms/GeomLine.svelte +12 -0
  115. package/dist/geoms/GeomLine.svelte.d.ts +7 -0
  116. package/dist/geoms/GeomLinerange.svelte +25 -0
  117. package/dist/geoms/GeomLinerange.svelte.d.ts +7 -0
  118. package/dist/geoms/GeomMap.svelte +21 -0
  119. package/dist/geoms/GeomMap.svelte.d.ts +7 -0
  120. package/dist/geoms/GeomPath.svelte +12 -0
  121. package/dist/geoms/GeomPath.svelte.d.ts +7 -0
  122. package/dist/geoms/GeomPoint.svelte +12 -0
  123. package/dist/geoms/GeomPoint.svelte.d.ts +7 -0
  124. package/dist/geoms/GeomPointrange.svelte +25 -0
  125. package/dist/geoms/GeomPointrange.svelte.d.ts +7 -0
  126. package/dist/geoms/GeomPolygon.svelte +25 -0
  127. package/dist/geoms/GeomPolygon.svelte.d.ts +7 -0
  128. package/dist/geoms/GeomQq.svelte +21 -0
  129. package/dist/geoms/GeomQq.svelte.d.ts +7 -0
  130. package/dist/geoms/GeomQqLine.svelte +25 -0
  131. package/dist/geoms/GeomQqLine.svelte.d.ts +7 -0
  132. package/dist/geoms/GeomQuantile.svelte +25 -0
  133. package/dist/geoms/GeomQuantile.svelte.d.ts +7 -0
  134. package/dist/geoms/GeomRaster.svelte +25 -0
  135. package/dist/geoms/GeomRaster.svelte.d.ts +7 -0
  136. package/dist/geoms/GeomRect.svelte +12 -0
  137. package/dist/geoms/GeomRect.svelte.d.ts +7 -0
  138. package/dist/geoms/GeomRibbon.svelte +16 -0
  139. package/dist/geoms/GeomRibbon.svelte.d.ts +7 -0
  140. package/dist/geoms/GeomRug.svelte +21 -0
  141. package/dist/geoms/GeomRug.svelte.d.ts +7 -0
  142. package/dist/geoms/GeomRule.svelte +12 -0
  143. package/dist/geoms/GeomRule.svelte.d.ts +7 -0
  144. package/dist/geoms/GeomSegment.svelte +16 -0
  145. package/dist/geoms/GeomSegment.svelte.d.ts +7 -0
  146. package/dist/geoms/GeomSf.svelte +21 -0
  147. package/dist/geoms/GeomSf.svelte.d.ts +7 -0
  148. package/dist/geoms/GeomSfLabel.svelte +25 -0
  149. package/dist/geoms/GeomSfLabel.svelte.d.ts +7 -0
  150. package/dist/geoms/GeomSfText.svelte +25 -0
  151. package/dist/geoms/GeomSfText.svelte.d.ts +7 -0
  152. package/dist/geoms/GeomSmooth.svelte +25 -0
  153. package/dist/geoms/GeomSmooth.svelte.d.ts +7 -0
  154. package/dist/geoms/GeomSpoke.svelte +21 -0
  155. package/dist/geoms/GeomSpoke.svelte.d.ts +7 -0
  156. package/dist/geoms/GeomStep.svelte +12 -0
  157. package/dist/geoms/GeomStep.svelte.d.ts +7 -0
  158. package/dist/geoms/GeomText.svelte +12 -0
  159. package/dist/geoms/GeomText.svelte.d.ts +7 -0
  160. package/dist/geoms/GeomTile.svelte +21 -0
  161. package/dist/geoms/GeomTile.svelte.d.ts +7 -0
  162. package/dist/geoms/GeomViolin.svelte +25 -0
  163. package/dist/geoms/GeomViolin.svelte.d.ts +7 -0
  164. package/dist/geoms/GeomVline.svelte +12 -0
  165. package/dist/geoms/GeomVline.svelte.d.ts +7 -0
  166. package/dist/geoms/factory.svelte.d.ts +41 -0
  167. package/dist/geoms/factory.svelte.js +60 -0
  168. package/dist/geoms/registry.svelte.d.ts +71 -0
  169. package/dist/geoms/registry.svelte.js +177 -0
  170. package/dist/guides/GuideAxis.svelte +20 -0
  171. package/dist/guides/GuideAxis.svelte.d.ts +14 -0
  172. package/dist/guides/GuideColorbar.svelte +22 -0
  173. package/dist/guides/GuideColorbar.svelte.d.ts +13 -0
  174. package/dist/guides/GuideColorsteps.svelte +22 -0
  175. package/dist/guides/GuideColorsteps.svelte.d.ts +13 -0
  176. package/dist/guides/GuideLegend.svelte +90 -0
  177. package/dist/guides/GuideLegend.svelte.d.ts +37 -0
  178. package/dist/guides/GuideNone.svelte +19 -0
  179. package/dist/guides/GuideNone.svelte.d.ts +7 -0
  180. package/dist/guides/Guides.svelte +14 -0
  181. package/dist/guides/Guides.svelte.d.ts +13 -0
  182. package/dist/guides/factory.svelte.d.ts +36 -0
  183. package/dist/guides/factory.svelte.js +15 -0
  184. package/dist/index.d.ts +418 -0
  185. package/dist/index.js +376 -0
  186. package/dist/inspection/Inspect.svelte +71 -0
  187. package/dist/inspection/Inspect.svelte.d.ts +36 -0
  188. package/dist/inspection/Tooltip.svelte +439 -0
  189. package/dist/inspection/Tooltip.svelte.d.ts +32 -0
  190. package/dist/inspection/apply.d.ts +120 -0
  191. package/dist/inspection/apply.js +99 -0
  192. package/dist/inspection/coordinator.d.ts +51 -0
  193. package/dist/inspection/coordinator.js +354 -0
  194. package/dist/inspection/display-members.d.ts +1 -0
  195. package/dist/inspection/display-members.js +2 -0
  196. package/dist/inspection/frame.d.ts +90 -0
  197. package/dist/inspection/frame.js +76 -0
  198. package/dist/inspection/group-total.d.ts +1 -0
  199. package/dist/inspection/group-total.js +2 -0
  200. package/dist/inspection/inspect-guide-axes.d.ts +10 -0
  201. package/dist/inspection/inspect-guide-axes.js +24 -0
  202. package/dist/inspection/inspection-reconcile.svelte.d.ts +37 -0
  203. package/dist/inspection/inspection-reconcile.svelte.js +33 -0
  204. package/dist/inspection/inspection-state.svelte.d.ts +86 -0
  205. package/dist/inspection/inspection-state.svelte.js +347 -0
  206. package/dist/inspection/inspection-traversal.svelte.d.ts +29 -0
  207. package/dist/inspection/inspection-traversal.svelte.js +52 -0
  208. package/dist/inspection/pointer-inspect.d.ts +74 -0
  209. package/dist/inspection/pointer-inspect.js +158 -0
  210. package/dist/inspection/resolver.d.ts +3 -0
  211. package/dist/inspection/resolver.js +4 -0
  212. package/dist/inspection/teardown.d.ts +199 -0
  213. package/dist/inspection/teardown.js +181 -0
  214. package/dist/inspection/tooltip-chrome.d.ts +19 -0
  215. package/dist/inspection/tooltip-chrome.js +17 -0
  216. package/dist/inspection/tooltip-motion.d.ts +25 -0
  217. package/dist/inspection/tooltip-motion.js +32 -0
  218. package/dist/inspection/tooltip-presence.svelte.d.ts +49 -0
  219. package/dist/inspection/tooltip-presence.svelte.js +110 -0
  220. package/dist/inspection/tooltip-total.d.ts +1 -0
  221. package/dist/inspection/tooltip-total.js +2 -0
  222. package/dist/interaction/capability-resolution.svelte.d.ts +42 -0
  223. package/dist/interaction/capability-resolution.svelte.js +40 -0
  224. package/dist/interaction/capability.d.ts +129 -0
  225. package/dist/interaction/capability.js +134 -0
  226. package/dist/interaction/controller.svelte.d.ts +4 -0
  227. package/dist/interaction/controller.svelte.js +43 -0
  228. package/dist/interaction/inspect-geom-advisories.d.ts +10 -0
  229. package/dist/interaction/inspect-geom-advisories.js +10 -0
  230. package/dist/interaction/interaction-context.svelte.d.ts +57 -0
  231. package/dist/interaction/interaction-context.svelte.js +4 -0
  232. package/dist/interaction/interaction-diagnostics.d.ts +11 -0
  233. package/dist/interaction/interaction-diagnostics.js +173 -0
  234. package/dist/interaction/interaction-states.svelte.d.ts +84 -0
  235. package/dist/interaction/interaction-states.svelte.js +55 -0
  236. package/dist/interaction/interaction.d.ts +304 -0
  237. package/dist/interaction/interaction.js +7 -0
  238. package/dist/interaction/normalize-interaction-config.d.ts +9 -0
  239. package/dist/interaction/normalize-interaction-config.js +112 -0
  240. package/dist/interaction/reducer.d.ts +97 -0
  241. package/dist/interaction/reducer.js +117 -0
  242. package/dist/interaction/resolve-inspect-capability.d.ts +40 -0
  243. package/dist/interaction/resolve-inspect-capability.js +50 -0
  244. package/dist/interaction/scoped-store.svelte.d.ts +73 -0
  245. package/dist/interaction/scoped-store.svelte.js +93 -0
  246. package/dist/interaction/target.d.ts +91 -0
  247. package/dist/interaction/target.js +68 -0
  248. package/dist/interaction/transition-owner.d.ts +19 -0
  249. package/dist/interaction/transition-owner.js +10 -0
  250. package/dist/interaction/wiring-advisories.d.ts +33 -0
  251. package/dist/interaction/wiring-advisories.js +46 -0
  252. package/dist/interval/BoundsEditor.svelte +332 -0
  253. package/dist/interval/BoundsEditor.svelte.d.ts +10 -0
  254. package/dist/interval/bounds-editor.d.ts +1 -0
  255. package/dist/interval/bounds-editor.js +2 -0
  256. package/dist/interval/consumption.d.ts +1 -0
  257. package/dist/interval/consumption.js +2 -0
  258. package/dist/interval/interval-bounds-state.svelte.d.ts +53 -0
  259. package/dist/interval/interval-bounds-state.svelte.js +117 -0
  260. package/dist/interval/interval-state-helpers.d.ts +10 -0
  261. package/dist/interval/interval-state-helpers.js +34 -0
  262. package/dist/interval/interval-state.svelte.d.ts +60 -0
  263. package/dist/interval/interval-state.svelte.js +360 -0
  264. package/dist/interval/interval.d.ts +1 -0
  265. package/dist/interval/interval.js +2 -0
  266. package/dist/interval/precise-bounds.d.ts +1 -0
  267. package/dist/interval/precise-bounds.js +2 -0
  268. package/dist/interval/query.d.ts +1 -0
  269. package/dist/interval/query.js +2 -0
  270. package/dist/labs/Labs.svelte +29 -0
  271. package/dist/labs/Labs.svelte.d.ts +16 -0
  272. package/dist/layers/fold.d.ts +2 -0
  273. package/dist/layers/fold.js +1 -0
  274. package/dist/layers/grammar-families.d.ts +2 -0
  275. package/dist/layers/grammar-families.js +1 -0
  276. package/dist/layers/plot-layer-contract.d.ts +1 -0
  277. package/dist/layers/plot-layer-contract.js +29 -0
  278. package/dist/layers/plot-layer.svelte.d.ts +42 -0
  279. package/dist/layers/plot-layer.svelte.js +34 -0
  280. package/dist/layers/types.d.ts +2 -0
  281. package/dist/layers/types.js +1 -0
  282. package/dist/legend/Legend.svelte +24 -0
  283. package/dist/legend/Legend.svelte.d.ts +5 -0
  284. package/dist/legend/LegendFilters.svelte +196 -0
  285. package/dist/legend/LegendFilters.svelte.d.ts +8 -0
  286. package/dist/legend/LegendTargets.svelte +393 -0
  287. package/dist/legend/LegendTargets.svelte.d.ts +31 -0
  288. package/dist/legend/entry-key-index.d.ts +1 -0
  289. package/dist/legend/entry-key-index.js +2 -0
  290. package/dist/legend/entry-key-index.svelte.d.ts +34 -0
  291. package/dist/legend/entry-key-index.svelte.js +35 -0
  292. package/dist/legend/filter-state.svelte.d.ts +66 -0
  293. package/dist/legend/filter-state.svelte.js +284 -0
  294. package/dist/legend/filter.d.ts +1 -0
  295. package/dist/legend/filter.js +2 -0
  296. package/dist/legend/focus-emphasis.d.ts +72 -0
  297. package/dist/legend/focus-emphasis.js +91 -0
  298. package/dist/legend/focus-plans.d.ts +89 -0
  299. package/dist/legend/focus-plans.js +72 -0
  300. package/dist/legend/focus-reconcile.svelte.d.ts +53 -0
  301. package/dist/legend/focus-reconcile.svelte.js +113 -0
  302. package/dist/legend/focus-state.svelte.d.ts +73 -0
  303. package/dist/legend/focus-state.svelte.js +338 -0
  304. package/dist/legend/focus.d.ts +1 -0
  305. package/dist/legend/focus.js +2 -0
  306. package/dist/legend/resolve-legend-capability.d.ts +52 -0
  307. package/dist/legend/resolve-legend-capability.js +68 -0
  308. package/dist/legend/resolve-legend-filter.d.ts +65 -0
  309. package/dist/legend/resolve-legend-filter.js +54 -0
  310. package/dist/legend/resolve-legend-focus.d.ts +58 -0
  311. package/dist/legend/resolve-legend-focus.js +36 -0
  312. package/dist/legend/surface.d.ts +190 -0
  313. package/dist/legend/surface.js +158 -0
  314. package/dist/plot-engine-deriveds.svelte.d.ts +75 -0
  315. package/dist/plot-engine-deriveds.svelte.js +166 -0
  316. package/dist/plot-engine.svelte.d.ts +116 -0
  317. package/dist/plot-engine.svelte.js +316 -0
  318. package/dist/plot-props.d.ts +144 -0
  319. package/dist/plot-props.js +81 -0
  320. package/dist/runtime/announcer.svelte.d.ts +17 -0
  321. package/dist/runtime/announcer.svelte.js +28 -0
  322. package/dist/runtime/paint.d.ts +38 -0
  323. package/dist/runtime/paint.js +45 -0
  324. package/dist/runtime/resolve-datum-key.d.ts +53 -0
  325. package/dist/runtime/resolve-datum-key.js +73 -0
  326. package/dist/runtime/runtime.svelte.d.ts +37 -0
  327. package/dist/runtime/runtime.svelte.js +233 -0
  328. package/dist/runtime/semantic-candidate-projection.svelte.d.ts +29 -0
  329. package/dist/runtime/semantic-candidate-projection.svelte.js +137 -0
  330. package/dist/runtime/semantic-data-identity.d.ts +64 -0
  331. package/dist/runtime/semantic-data-identity.js +153 -0
  332. package/dist/runtime/semantic-keys-projection.d.ts +22 -0
  333. package/dist/runtime/semantic-keys-projection.js +40 -0
  334. package/dist/runtime/semantic-keys-resolve.d.ts +69 -0
  335. package/dist/runtime/semantic-keys-resolve.js +122 -0
  336. package/dist/runtime/semantic-keys.svelte.d.ts +30 -0
  337. package/dist/runtime/semantic-keys.svelte.js +69 -0
  338. package/dist/runtime/semantic-source-identity.d.ts +9 -0
  339. package/dist/runtime/semantic-source-identity.js +16 -0
  340. package/dist/scale/Scale.svelte +26 -0
  341. package/dist/scale/Scale.svelte.d.ts +21 -0
  342. package/dist/scale/ScaleAlphaBinned.svelte +14 -0
  343. package/dist/scale/ScaleAlphaBinned.svelte.d.ts +4 -0
  344. package/dist/scale/ScaleAlphaContinuous.svelte +14 -0
  345. package/dist/scale/ScaleAlphaContinuous.svelte.d.ts +4 -0
  346. package/dist/scale/ScaleAlphaDate.svelte +15 -0
  347. package/dist/scale/ScaleAlphaDate.svelte.d.ts +5 -0
  348. package/dist/scale/ScaleAlphaDatetime.svelte +15 -0
  349. package/dist/scale/ScaleAlphaDatetime.svelte.d.ts +5 -0
  350. package/dist/scale/ScaleAlphaDiscrete.svelte +14 -0
  351. package/dist/scale/ScaleAlphaDiscrete.svelte.d.ts +4 -0
  352. package/dist/scale/ScaleAlphaIdentity.svelte +14 -0
  353. package/dist/scale/ScaleAlphaIdentity.svelte.d.ts +4 -0
  354. package/dist/scale/ScaleAlphaManual.svelte +14 -0
  355. package/dist/scale/ScaleAlphaManual.svelte.d.ts +4 -0
  356. package/dist/scale/ScaleColorBinned.svelte +14 -0
  357. package/dist/scale/ScaleColorBinned.svelte.d.ts +3 -0
  358. package/dist/scale/ScaleColorBrewer.svelte +14 -0
  359. package/dist/scale/ScaleColorBrewer.svelte.d.ts +4 -0
  360. package/dist/scale/ScaleColorContinuous.svelte +14 -0
  361. package/dist/scale/ScaleColorContinuous.svelte.d.ts +4 -0
  362. package/dist/scale/ScaleColorDate.svelte +15 -0
  363. package/dist/scale/ScaleColorDate.svelte.d.ts +5 -0
  364. package/dist/scale/ScaleColorDatetime.svelte +15 -0
  365. package/dist/scale/ScaleColorDatetime.svelte.d.ts +5 -0
  366. package/dist/scale/ScaleColorDiscrete.svelte +14 -0
  367. package/dist/scale/ScaleColorDiscrete.svelte.d.ts +4 -0
  368. package/dist/scale/ScaleColorDistiller.svelte +14 -0
  369. package/dist/scale/ScaleColorDistiller.svelte.d.ts +4 -0
  370. package/dist/scale/ScaleColorFermenter.svelte +14 -0
  371. package/dist/scale/ScaleColorFermenter.svelte.d.ts +4 -0
  372. package/dist/scale/ScaleColorGradient.svelte +11 -0
  373. package/dist/scale/ScaleColorGradient.svelte.d.ts +4 -0
  374. package/dist/scale/ScaleColorGradient2.svelte +14 -0
  375. package/dist/scale/ScaleColorGradient2.svelte.d.ts +4 -0
  376. package/dist/scale/ScaleColorGradientn.svelte +14 -0
  377. package/dist/scale/ScaleColorGradientn.svelte.d.ts +4 -0
  378. package/dist/scale/ScaleColorGrey.svelte +11 -0
  379. package/dist/scale/ScaleColorGrey.svelte.d.ts +4 -0
  380. package/dist/scale/ScaleColorHue.svelte +11 -0
  381. package/dist/scale/ScaleColorHue.svelte.d.ts +4 -0
  382. package/dist/scale/ScaleColorIdentity.svelte +14 -0
  383. package/dist/scale/ScaleColorIdentity.svelte.d.ts +4 -0
  384. package/dist/scale/ScaleColorLog10.svelte +14 -0
  385. package/dist/scale/ScaleColorLog10.svelte.d.ts +4 -0
  386. package/dist/scale/ScaleColorManual.svelte +14 -0
  387. package/dist/scale/ScaleColorManual.svelte.d.ts +4 -0
  388. package/dist/scale/ScaleColorOrdinal.svelte +14 -0
  389. package/dist/scale/ScaleColorOrdinal.svelte.d.ts +3 -0
  390. package/dist/scale/ScaleColorSqrt.svelte +14 -0
  391. package/dist/scale/ScaleColorSqrt.svelte.d.ts +4 -0
  392. package/dist/scale/ScaleColorSteps.svelte +11 -0
  393. package/dist/scale/ScaleColorSteps.svelte.d.ts +4 -0
  394. package/dist/scale/ScaleColorSteps2.svelte +11 -0
  395. package/dist/scale/ScaleColorSteps2.svelte.d.ts +4 -0
  396. package/dist/scale/ScaleColorStepsn.svelte +11 -0
  397. package/dist/scale/ScaleColorStepsn.svelte.d.ts +4 -0
  398. package/dist/scale/ScaleColorViridisB.svelte +11 -0
  399. package/dist/scale/ScaleColorViridisB.svelte.d.ts +4 -0
  400. package/dist/scale/ScaleColorViridisC.svelte +11 -0
  401. package/dist/scale/ScaleColorViridisC.svelte.d.ts +4 -0
  402. package/dist/scale/ScaleColorViridisD.svelte +11 -0
  403. package/dist/scale/ScaleColorViridisD.svelte.d.ts +4 -0
  404. package/dist/scale/ScaleFillBinned.svelte +11 -0
  405. package/dist/scale/ScaleFillBinned.svelte.d.ts +3 -0
  406. package/dist/scale/ScaleFillBrewer.svelte +11 -0
  407. package/dist/scale/ScaleFillBrewer.svelte.d.ts +4 -0
  408. package/dist/scale/ScaleFillContinuous.svelte +14 -0
  409. package/dist/scale/ScaleFillContinuous.svelte.d.ts +4 -0
  410. package/dist/scale/ScaleFillDate.svelte +12 -0
  411. package/dist/scale/ScaleFillDate.svelte.d.ts +5 -0
  412. package/dist/scale/ScaleFillDatetime.svelte +15 -0
  413. package/dist/scale/ScaleFillDatetime.svelte.d.ts +5 -0
  414. package/dist/scale/ScaleFillDiscrete.svelte +14 -0
  415. package/dist/scale/ScaleFillDiscrete.svelte.d.ts +4 -0
  416. package/dist/scale/ScaleFillDistiller.svelte +14 -0
  417. package/dist/scale/ScaleFillDistiller.svelte.d.ts +4 -0
  418. package/dist/scale/ScaleFillFermenter.svelte +14 -0
  419. package/dist/scale/ScaleFillFermenter.svelte.d.ts +4 -0
  420. package/dist/scale/ScaleFillGradient.svelte +11 -0
  421. package/dist/scale/ScaleFillGradient.svelte.d.ts +4 -0
  422. package/dist/scale/ScaleFillGradient2.svelte +14 -0
  423. package/dist/scale/ScaleFillGradient2.svelte.d.ts +4 -0
  424. package/dist/scale/ScaleFillGradientn.svelte +14 -0
  425. package/dist/scale/ScaleFillGradientn.svelte.d.ts +4 -0
  426. package/dist/scale/ScaleFillGrey.svelte +11 -0
  427. package/dist/scale/ScaleFillGrey.svelte.d.ts +4 -0
  428. package/dist/scale/ScaleFillHue.svelte +11 -0
  429. package/dist/scale/ScaleFillHue.svelte.d.ts +4 -0
  430. package/dist/scale/ScaleFillIdentity.svelte +14 -0
  431. package/dist/scale/ScaleFillIdentity.svelte.d.ts +4 -0
  432. package/dist/scale/ScaleFillLog10.svelte +14 -0
  433. package/dist/scale/ScaleFillLog10.svelte.d.ts +4 -0
  434. package/dist/scale/ScaleFillManual.svelte +11 -0
  435. package/dist/scale/ScaleFillManual.svelte.d.ts +4 -0
  436. package/dist/scale/ScaleFillOrdinal.svelte +14 -0
  437. package/dist/scale/ScaleFillOrdinal.svelte.d.ts +3 -0
  438. package/dist/scale/ScaleFillSqrt.svelte +14 -0
  439. package/dist/scale/ScaleFillSqrt.svelte.d.ts +4 -0
  440. package/dist/scale/ScaleFillSteps.svelte +11 -0
  441. package/dist/scale/ScaleFillSteps.svelte.d.ts +4 -0
  442. package/dist/scale/ScaleFillSteps2.svelte +11 -0
  443. package/dist/scale/ScaleFillSteps2.svelte.d.ts +4 -0
  444. package/dist/scale/ScaleFillStepsn.svelte +11 -0
  445. package/dist/scale/ScaleFillStepsn.svelte.d.ts +4 -0
  446. package/dist/scale/ScaleFillViridisB.svelte +11 -0
  447. package/dist/scale/ScaleFillViridisB.svelte.d.ts +4 -0
  448. package/dist/scale/ScaleFillViridisC.svelte +11 -0
  449. package/dist/scale/ScaleFillViridisC.svelte.d.ts +4 -0
  450. package/dist/scale/ScaleFillViridisD.svelte +11 -0
  451. package/dist/scale/ScaleFillViridisD.svelte.d.ts +4 -0
  452. package/dist/scale/ScaleLinetypeBinned.svelte +15 -0
  453. package/dist/scale/ScaleLinetypeBinned.svelte.d.ts +4 -0
  454. package/dist/scale/ScaleLinetypeDiscrete.svelte +15 -0
  455. package/dist/scale/ScaleLinetypeDiscrete.svelte.d.ts +4 -0
  456. package/dist/scale/ScaleLinetypeIdentity.svelte +15 -0
  457. package/dist/scale/ScaleLinetypeIdentity.svelte.d.ts +4 -0
  458. package/dist/scale/ScaleLinetypeManual.svelte +15 -0
  459. package/dist/scale/ScaleLinetypeManual.svelte.d.ts +4 -0
  460. package/dist/scale/ScaleLinewidthBinned.svelte +14 -0
  461. package/dist/scale/ScaleLinewidthBinned.svelte.d.ts +4 -0
  462. package/dist/scale/ScaleLinewidthContinuous.svelte +14 -0
  463. package/dist/scale/ScaleLinewidthContinuous.svelte.d.ts +4 -0
  464. package/dist/scale/ScaleLinewidthDate.svelte +15 -0
  465. package/dist/scale/ScaleLinewidthDate.svelte.d.ts +5 -0
  466. package/dist/scale/ScaleLinewidthDatetime.svelte +15 -0
  467. package/dist/scale/ScaleLinewidthDatetime.svelte.d.ts +5 -0
  468. package/dist/scale/ScaleLinewidthDiscrete.svelte +14 -0
  469. package/dist/scale/ScaleLinewidthDiscrete.svelte.d.ts +4 -0
  470. package/dist/scale/ScaleLinewidthIdentity.svelte +14 -0
  471. package/dist/scale/ScaleLinewidthIdentity.svelte.d.ts +4 -0
  472. package/dist/scale/ScaleLinewidthManual.svelte +14 -0
  473. package/dist/scale/ScaleLinewidthManual.svelte.d.ts +4 -0
  474. package/dist/scale/ScaleRadius.svelte +11 -0
  475. package/dist/scale/ScaleRadius.svelte.d.ts +4 -0
  476. package/dist/scale/ScaleShapeBinned.svelte +15 -0
  477. package/dist/scale/ScaleShapeBinned.svelte.d.ts +4 -0
  478. package/dist/scale/ScaleShapeDiscrete.svelte +15 -0
  479. package/dist/scale/ScaleShapeDiscrete.svelte.d.ts +4 -0
  480. package/dist/scale/ScaleShapeIdentity.svelte +15 -0
  481. package/dist/scale/ScaleShapeIdentity.svelte.d.ts +4 -0
  482. package/dist/scale/ScaleShapeManual.svelte +15 -0
  483. package/dist/scale/ScaleShapeManual.svelte.d.ts +4 -0
  484. package/dist/scale/ScaleSizeArea.svelte +11 -0
  485. package/dist/scale/ScaleSizeArea.svelte.d.ts +4 -0
  486. package/dist/scale/ScaleSizeBinned.svelte +14 -0
  487. package/dist/scale/ScaleSizeBinned.svelte.d.ts +4 -0
  488. package/dist/scale/ScaleSizeBinnedArea.svelte +14 -0
  489. package/dist/scale/ScaleSizeBinnedArea.svelte.d.ts +4 -0
  490. package/dist/scale/ScaleSizeContinuous.svelte +14 -0
  491. package/dist/scale/ScaleSizeContinuous.svelte.d.ts +4 -0
  492. package/dist/scale/ScaleSizeDate.svelte +15 -0
  493. package/dist/scale/ScaleSizeDate.svelte.d.ts +5 -0
  494. package/dist/scale/ScaleSizeDatetime.svelte +15 -0
  495. package/dist/scale/ScaleSizeDatetime.svelte.d.ts +5 -0
  496. package/dist/scale/ScaleSizeDiscrete.svelte +14 -0
  497. package/dist/scale/ScaleSizeDiscrete.svelte.d.ts +4 -0
  498. package/dist/scale/ScaleSizeIdentity.svelte +14 -0
  499. package/dist/scale/ScaleSizeIdentity.svelte.d.ts +4 -0
  500. package/dist/scale/ScaleSizeManual.svelte +14 -0
  501. package/dist/scale/ScaleSizeManual.svelte.d.ts +4 -0
  502. package/dist/scale/ScaleXBinned.svelte +14 -0
  503. package/dist/scale/ScaleXBinned.svelte.d.ts +4 -0
  504. package/dist/scale/ScaleXContinuous.svelte +14 -0
  505. package/dist/scale/ScaleXContinuous.svelte.d.ts +4 -0
  506. package/dist/scale/ScaleXDate.svelte +12 -0
  507. package/dist/scale/ScaleXDate.svelte.d.ts +5 -0
  508. package/dist/scale/ScaleXDatetime.svelte +12 -0
  509. package/dist/scale/ScaleXDatetime.svelte.d.ts +5 -0
  510. package/dist/scale/ScaleXDiscrete.svelte +14 -0
  511. package/dist/scale/ScaleXDiscrete.svelte.d.ts +4 -0
  512. package/dist/scale/ScaleXLog10.svelte +14 -0
  513. package/dist/scale/ScaleXLog10.svelte.d.ts +4 -0
  514. package/dist/scale/ScaleXMonthDay.svelte +12 -0
  515. package/dist/scale/ScaleXMonthDay.svelte.d.ts +5 -0
  516. package/dist/scale/ScaleXReverse.svelte +15 -0
  517. package/dist/scale/ScaleXReverse.svelte.d.ts +4 -0
  518. package/dist/scale/ScaleXSqrt.svelte +14 -0
  519. package/dist/scale/ScaleXSqrt.svelte.d.ts +4 -0
  520. package/dist/scale/ScaleXTime.svelte +12 -0
  521. package/dist/scale/ScaleXTime.svelte.d.ts +5 -0
  522. package/dist/scale/ScaleYBinned.svelte +14 -0
  523. package/dist/scale/ScaleYBinned.svelte.d.ts +4 -0
  524. package/dist/scale/ScaleYContinuous.svelte +14 -0
  525. package/dist/scale/ScaleYContinuous.svelte.d.ts +4 -0
  526. package/dist/scale/ScaleYDate.svelte +12 -0
  527. package/dist/scale/ScaleYDate.svelte.d.ts +5 -0
  528. package/dist/scale/ScaleYDatetime.svelte +12 -0
  529. package/dist/scale/ScaleYDatetime.svelte.d.ts +5 -0
  530. package/dist/scale/ScaleYDiscrete.svelte +14 -0
  531. package/dist/scale/ScaleYDiscrete.svelte.d.ts +4 -0
  532. package/dist/scale/ScaleYLog10.svelte +14 -0
  533. package/dist/scale/ScaleYLog10.svelte.d.ts +4 -0
  534. package/dist/scale/ScaleYMonthDay.svelte +12 -0
  535. package/dist/scale/ScaleYMonthDay.svelte.d.ts +5 -0
  536. package/dist/scale/ScaleYReverse.svelte +15 -0
  537. package/dist/scale/ScaleYReverse.svelte.d.ts +4 -0
  538. package/dist/scale/ScaleYSqrt.svelte +14 -0
  539. package/dist/scale/ScaleYSqrt.svelte.d.ts +4 -0
  540. package/dist/scale/ScaleYTime.svelte +12 -0
  541. package/dist/scale/ScaleYTime.svelte.d.ts +5 -0
  542. package/dist/scene/Axis.svelte +159 -0
  543. package/dist/scene/Axis.svelte.d.ts +12 -0
  544. package/dist/scene/Batch.svelte +252 -0
  545. package/dist/scene/Batch.svelte.d.ts +23 -0
  546. package/dist/scene/InteractionOverlay.svelte +402 -0
  547. package/dist/scene/InteractionOverlay.svelte.d.ts +44 -0
  548. package/dist/scene/Legend.svelte +278 -0
  549. package/dist/scene/Legend.svelte.d.ts +8 -0
  550. package/dist/scene/MarkStrata.svelte +129 -0
  551. package/dist/scene/MarkStrata.svelte.d.ts +15 -0
  552. package/dist/scene/SceneOverlays.svelte +118 -0
  553. package/dist/scene/SceneOverlays.svelte.d.ts +49 -0
  554. package/dist/scene/SceneView.svelte +478 -0
  555. package/dist/scene/SceneView.svelte.d.ts +32 -0
  556. package/dist/scene/batch-presentation.svelte.d.ts +111 -0
  557. package/dist/scene/batch-presentation.svelte.js +207 -0
  558. package/dist/scene/geometry.d.ts +2 -0
  559. package/dist/scene/geometry.js +3 -0
  560. package/dist/scene/stratum-paint.d.ts +25 -0
  561. package/dist/scene/stratum-paint.js +40 -0
  562. package/dist/selection/selection-state.svelte.d.ts +23 -0
  563. package/dist/selection/selection-state.svelte.js +73 -0
  564. package/dist/selection/selection.d.ts +1 -0
  565. package/dist/selection/selection.js +2 -0
  566. package/dist/surface/CaptureSurface.svelte +109 -0
  567. package/dist/surface/CaptureSurface.svelte.d.ts +27 -0
  568. package/dist/surface/area-brush.d.ts +48 -0
  569. package/dist/surface/area-brush.js +44 -0
  570. package/dist/surface/brush-finish.d.ts +49 -0
  571. package/dist/surface/brush-finish.js +44 -0
  572. package/dist/surface/keyboard.d.ts +97 -0
  573. package/dist/surface/keyboard.js +105 -0
  574. package/dist/surface/pointer.d.ts +241 -0
  575. package/dist/surface/pointer.js +179 -0
  576. package/dist/surface/surface-description.d.ts +10 -0
  577. package/dist/surface/surface-description.js +11 -0
  578. package/dist/surface/surface-handlers.svelte.d.ts +53 -0
  579. package/dist/surface/surface-handlers.svelte.js +418 -0
  580. package/dist/surface/surface-state.svelte.d.ts +90 -0
  581. package/dist/surface/surface-state.svelte.js +161 -0
  582. package/dist/theme/Theme.svelte +27 -0
  583. package/dist/theme/Theme.svelte.d.ts +23 -0
  584. package/dist/theme/ThemeBase.svelte +13 -0
  585. package/dist/theme/ThemeBase.svelte.d.ts +8 -0
  586. package/dist/theme/ThemeBw.svelte +13 -0
  587. package/dist/theme/ThemeBw.svelte.d.ts +8 -0
  588. package/dist/theme/ThemeClassic.svelte +13 -0
  589. package/dist/theme/ThemeClassic.svelte.d.ts +8 -0
  590. package/dist/theme/ThemeClean.svelte +13 -0
  591. package/dist/theme/ThemeClean.svelte.d.ts +8 -0
  592. package/dist/theme/ThemeDark.svelte +13 -0
  593. package/dist/theme/ThemeDark.svelte.d.ts +8 -0
  594. package/dist/theme/ThemeDefault.svelte +13 -0
  595. package/dist/theme/ThemeDefault.svelte.d.ts +8 -0
  596. package/dist/theme/ThemeEconomist.svelte +13 -0
  597. package/dist/theme/ThemeEconomist.svelte.d.ts +8 -0
  598. package/dist/theme/ThemeEconomistwhite.svelte +13 -0
  599. package/dist/theme/ThemeEconomistwhite.svelte.d.ts +8 -0
  600. package/dist/theme/ThemeFew.svelte +13 -0
  601. package/dist/theme/ThemeFew.svelte.d.ts +8 -0
  602. package/dist/theme/ThemeFivethirtyeight.svelte +14 -0
  603. package/dist/theme/ThemeFivethirtyeight.svelte.d.ts +9 -0
  604. package/dist/theme/ThemeGgplot2.svelte +13 -0
  605. package/dist/theme/ThemeGgplot2.svelte.d.ts +8 -0
  606. package/dist/theme/ThemeGray.svelte +13 -0
  607. package/dist/theme/ThemeGray.svelte.d.ts +8 -0
  608. package/dist/theme/ThemeGrey.svelte +13 -0
  609. package/dist/theme/ThemeGrey.svelte.d.ts +8 -0
  610. package/dist/theme/ThemeHc.svelte +13 -0
  611. package/dist/theme/ThemeHc.svelte.d.ts +8 -0
  612. package/dist/theme/ThemeHcdark.svelte +13 -0
  613. package/dist/theme/ThemeHcdark.svelte.d.ts +8 -0
  614. package/dist/theme/ThemeHrbr.svelte +13 -0
  615. package/dist/theme/ThemeHrbr.svelte.d.ts +8 -0
  616. package/dist/theme/ThemeIgray.svelte +13 -0
  617. package/dist/theme/ThemeIgray.svelte.d.ts +8 -0
  618. package/dist/theme/ThemeLight.svelte +13 -0
  619. package/dist/theme/ThemeLight.svelte.d.ts +8 -0
  620. package/dist/theme/ThemeLinedraw.svelte +13 -0
  621. package/dist/theme/ThemeLinedraw.svelte.d.ts +8 -0
  622. package/dist/theme/ThemeMap.svelte +13 -0
  623. package/dist/theme/ThemeMap.svelte.d.ts +8 -0
  624. package/dist/theme/ThemeMinimal.svelte +13 -0
  625. package/dist/theme/ThemeMinimal.svelte.d.ts +8 -0
  626. package/dist/theme/ThemePander.svelte +13 -0
  627. package/dist/theme/ThemePander.svelte.d.ts +8 -0
  628. package/dist/theme/ThemeSolarized.svelte +13 -0
  629. package/dist/theme/ThemeSolarized.svelte.d.ts +8 -0
  630. package/dist/theme/ThemeSolarized2.svelte +13 -0
  631. package/dist/theme/ThemeSolarized2.svelte.d.ts +8 -0
  632. package/dist/theme/ThemeSolarized2dark.svelte +13 -0
  633. package/dist/theme/ThemeSolarized2dark.svelte.d.ts +8 -0
  634. package/dist/theme/ThemeSolarizeddark.svelte +14 -0
  635. package/dist/theme/ThemeSolarizeddark.svelte.d.ts +9 -0
  636. package/dist/theme/ThemeSolid.svelte +13 -0
  637. package/dist/theme/ThemeSolid.svelte.d.ts +8 -0
  638. package/dist/theme/ThemeStata.svelte +13 -0
  639. package/dist/theme/ThemeStata.svelte.d.ts +8 -0
  640. package/dist/theme/ThemeStatas1color.svelte +13 -0
  641. package/dist/theme/ThemeStatas1color.svelte.d.ts +8 -0
  642. package/dist/theme/ThemeTest.svelte +14 -0
  643. package/dist/theme/ThemeTest.svelte.d.ts +9 -0
  644. package/dist/theme/ThemeTufte.svelte +13 -0
  645. package/dist/theme/ThemeTufte.svelte.d.ts +8 -0
  646. package/dist/theme/ThemeVoid.svelte +14 -0
  647. package/dist/theme/ThemeVoid.svelte.d.ts +9 -0
  648. package/dist/theme/ThemeWsj.svelte +13 -0
  649. package/dist/theme/ThemeWsj.svelte.d.ts +8 -0
  650. package/dist/theme/factory.svelte.d.ts +36 -0
  651. package/dist/theme/factory.svelte.js +100 -0
  652. package/dist/zoom/zoom-state.svelte.d.ts +44 -0
  653. package/dist/zoom/zoom-state.svelte.js +121 -0
  654. package/dist/zoom/zoom.d.ts +1 -0
  655. package/dist/zoom/zoom.js +2 -0
  656. package/package.json +83 -0
@@ -0,0 +1,117 @@
1
+ import { boundsEditorInputForScale } from "./precise-bounds.js";
2
+ function temporalKindForAxis(model, axis) {
3
+ for (const plan of model.guidePlans) {
4
+ if (plan.type === "axis" && plan.aesthetic === axis)
5
+ return plan.temporalKind;
6
+ }
7
+ return null;
8
+ }
9
+ function zoomBoundsEditorInput(deps, model, editor, temporalKind) {
10
+ const viewportPanel = model.viewport.panels[0];
11
+ if (viewportPanel === undefined)
12
+ return null;
13
+ const scale = viewportPanel.axisEditModel(editor.axis);
14
+ if (scale.kind === "band")
15
+ return null;
16
+ const bounds = deps.effectiveZoomDomains()?.[editor.axis] ?? scale.domain;
17
+ return boundsEditorInputForScale({
18
+ axis: editor.axis,
19
+ action: "zoom",
20
+ scale,
21
+ bounds,
22
+ temporalKind,
23
+ });
24
+ }
25
+ function selectionBoundsEditorInput(deps, model, editor, temporalKind) {
26
+ const record = deps.currentIntervalRecord();
27
+ const targetPanelId = record?.panelId ?? editor.panelId;
28
+ if (targetPanelId === undefined)
29
+ return null;
30
+ const viewportPanel = model.viewport.panel(targetPanelId);
31
+ if (viewportPanel === null)
32
+ return null;
33
+ const scale = viewportPanel.axisEditModel(editor.axis);
34
+ const semantic = record?.domains[editor.axis];
35
+ const bounds = semantic?.kind === "band"
36
+ ? [semantic.values[0] ?? "", semantic.values.at(-1) ?? ""]
37
+ : semantic?.domain;
38
+ return boundsEditorInputForScale({
39
+ axis: editor.axis,
40
+ action: "select",
41
+ scale,
42
+ temporalKind,
43
+ ...(bounds !== undefined && { bounds }),
44
+ });
45
+ }
46
+ function resolveBoundsEditorInput(deps, editor) {
47
+ const model = deps.model();
48
+ if (editor === null || model === null)
49
+ return null;
50
+ const temporalKind = temporalKindForAxis(model, editor.axis);
51
+ return editor.action === "zoom"
52
+ ? zoomBoundsEditorInput(deps, model, editor, temporalKind)
53
+ : selectionBoundsEditorInput(deps, model, editor, temporalKind);
54
+ }
55
+ // ---------------------------------------------------------------------------
56
+ // Factory
57
+ // ---------------------------------------------------------------------------
58
+ export function createIntervalBoundsEditor(deps) {
59
+ let boundsEditor = $state(null);
60
+ let boundsReturnFocus = $state(null);
61
+ const boundsEditorInput = $derived.by(() => resolveBoundsEditorInput(deps, boundsEditor));
62
+ $effect(() => {
63
+ if (boundsEditor === null || boundsEditorInput !== null)
64
+ return;
65
+ const target = boundsEditor.panelLabel ?? "the target panel";
66
+ boundsEditor = null;
67
+ boundsReturnFocus = null;
68
+ // The original button may have been reused for a different panel. The
69
+ // capture surface is the stable recovery target for reactive cancellation;
70
+ // explicit Apply/Cancel still restores the initiating button.
71
+ queueMicrotask(() => {
72
+ deps.captureSurface()?.focus();
73
+ deps.announce(`Bounds editing cancelled because ${target} is no longer available.`);
74
+ });
75
+ });
76
+ function openBoundsEditor(action, axis, trigger) {
77
+ boundsReturnFocus = trigger;
78
+ if (action === "select") {
79
+ const model = deps.model();
80
+ const panel = deps.currentIntervalRecord() === null
81
+ ? (() => {
82
+ const inspectionTarget = deps.inspectionPanel();
83
+ if (inspectionTarget !== null && model !== null) {
84
+ return model.scene.panels.find((candidate) => candidate.id === inspectionTarget.id);
85
+ }
86
+ return model?.scene.panels[0];
87
+ })()
88
+ : deps.currentIntervalPanel();
89
+ if (panel === undefined || panel === null)
90
+ return;
91
+ boundsEditor = {
92
+ action,
93
+ axis,
94
+ panelId: panel.id,
95
+ panelLabel: deps.intervalPanelLabel(panel),
96
+ };
97
+ return;
98
+ }
99
+ boundsEditor = { action, axis };
100
+ }
101
+ function cancel() {
102
+ boundsEditor = null;
103
+ }
104
+ return {
105
+ get boundsEditor() {
106
+ return boundsEditor;
107
+ },
108
+ get boundsEditorInput() {
109
+ return boundsEditorInput;
110
+ },
111
+ get boundsReturnFocus() {
112
+ return boundsReturnFocus;
113
+ },
114
+ openBoundsEditor,
115
+ cancel,
116
+ };
117
+ }
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Pure helpers extracted from interval-state for S5.
3
+ *
4
+ * No factory capture: every function takes its inputs as arguments and reads
5
+ * no reactive state. Consumed by interval-state.svelte.ts.
6
+ */
7
+ import { type SemanticViewportSelection } from "@ggts-sh/core";
8
+ import type { ReadonlyIntervalDomains } from "../interaction/interaction.js";
9
+ export declare function facetIdentityValueLabel(encodedValue: string): string;
10
+ export declare function viewportSelection(domains: ReadonlyIntervalDomains): SemanticViewportSelection;
@@ -0,0 +1,34 @@
1
+ /**
2
+ * Pure helpers extracted from interval-state for S5.
3
+ *
4
+ * No factory capture: every function takes its inputs as arguments and reads
5
+ * no reactive state. Consumed by interval-state.svelte.ts.
6
+ */
7
+ import { decodeKey } from "@ggts-sh/core";
8
+ export function facetIdentityValueLabel(encodedValue) {
9
+ const value = decodeKey(encodedValue);
10
+ const kind = value instanceof Date
11
+ ? "date"
12
+ : value === null
13
+ ? "null"
14
+ : typeof value === "string"
15
+ ? "text"
16
+ : typeof value;
17
+ const display = value instanceof Date ? value.toISOString() : String(value);
18
+ return `${kind} ${display}`;
19
+ }
20
+ function semanticViewportAxisSelection(semantic) {
21
+ return semantic === undefined
22
+ ? undefined
23
+ : semantic.kind === "band"
24
+ ? { kind: "band", keys: semantic.values }
25
+ : { kind: "continuous", domain: semantic.domain };
26
+ }
27
+ export function viewportSelection(domains) {
28
+ const x = semanticViewportAxisSelection(domains.x);
29
+ const y = semanticViewportAxisSelection(domains.y);
30
+ return {
31
+ ...(x !== undefined && { x }),
32
+ ...(y !== undefined && { y }),
33
+ };
34
+ }
@@ -0,0 +1,60 @@
1
+ import type { InteractionContext } from "../interaction/interaction-context.svelte.js";
2
+ import type { InteractionSource, IntervalSelection, PlotInteractionInterval, PlotSelection } from "../interaction/interaction.js";
3
+ import type { BoundsEditorInput, PreciseBoundsApplyEvent } from "./bounds-editor.js";
4
+ import { type ContinuousZoomDomains } from "../scene/geometry.js";
5
+ import { type IntervalConsumptionCandidate } from "./consumption.js";
6
+ /**
7
+ * Interval-specific ports beyond the shared InteractionContext. Sibling
8
+ * controllers are wired by the assembly (interaction-states.svelte.ts).
9
+ */
10
+ export type IntervalStateOptions = {
11
+ /** Alias over the zoom controller (construction-safe). */
12
+ readonly effectiveZoomDomains: () => ContinuousZoomDomains | null;
13
+ /** Zoom controller write path for the bounds-editor zoom branch (stable fn). */
14
+ readonly commitZoom: (domains: ContinuousZoomDomains | null, source: InteractionSource) => void;
15
+ /**
16
+ * Deferred semantic Candidate view for non-union interval consumption.
17
+ * Projection ownership stays outside interval behavior.
18
+ */
19
+ readonly consumptionCandidates: () => readonly IntervalConsumptionCandidate<PropertyKey>[];
20
+ /**
21
+ * Handler-only: `openBoundsEditor` select branch reads the inspection
22
+ * controller's panel id as its fallback target.
23
+ */
24
+ readonly inspectionPanel: () => Readonly<{
25
+ id: string;
26
+ }> | null;
27
+ /** Selection controller write path (stable fn). */
28
+ readonly emitSelection: (event: PlotSelection) => void;
29
+ };
30
+ export type IntervalState = {
31
+ readonly committedInterval: IntervalSelection | null;
32
+ readonly effectiveIntervals: readonly PlotInteractionInterval<PropertyKey>[];
33
+ readonly effectiveIntervalKeys: readonly PropertyKey[];
34
+ readonly currentIntervalTargetLabel: string | undefined;
35
+ readonly boundsEditorInput: BoundsEditorInput | null;
36
+ readonly boundsReturnFocus: HTMLElement | null;
37
+ /**
38
+ * Narrow boolean for ToolRail `canSetIntervalBounds` — equivalent to
39
+ * `currentIntervalRecord === null || currentIntervalPanel !== undefined`.
40
+ * Does NOT expose the private record/panel deriveds.
41
+ */
42
+ readonly intervalBoundsTargetAvailable: boolean;
43
+ clearIntervalSelection(source: InteractionSource): void;
44
+ clearCurrentPanelInterval(source: InteractionSource): void;
45
+ /**
46
+ * Brush select-end: commit writes (committedInterval + conditional record)
47
+ * then emit. Snapshots `selectConfig()?.persistent` once. Always emits the
48
+ * end event (including non-persistent) so callers need no post-hook emit.
49
+ */
50
+ finishBrushSelect(eventValue: IntervalSelection, source: InteractionSource): void;
51
+ openBoundsEditor(action: "select" | "zoom", axis: "x" | "y", trigger: HTMLElement): void;
52
+ applyPreciseBounds(event: PreciseBoundsApplyEvent): void;
53
+ cancelBoundsEditor(): void;
54
+ };
55
+ /**
56
+ * Create the interval-selection controller. Both effects register at
57
+ * construction (original host positions relative to the runtime model effects
58
+ * and the later semantic-key diagnostics effects).
59
+ */
60
+ export declare function createIntervalState(context: InteractionContext, options: IntervalStateOptions): IntervalState;
@@ -0,0 +1,360 @@
1
+ /**
2
+ * Interval-selection controller extracted from GGPlot for S5.
3
+ *
4
+ * Owns committedInterval / committedIntervalRecord, the interval ScopedStore
5
+ * (local vs controller records), construction-time deriveds
6
+ * (effectiveIntervals, effectiveIntervalKeys, currentInterval* family,
7
+ * intervalBoundsTargetAvailable), the interval-reconcile effect, private
8
+ * helpers, and the public clear/commit/bounds methods. The bounds-editor
9
+ * state machine (boundsEditor, boundsReturnFocus, boundsEditorInput, cancel
10
+ * effect, open/cancel actions) lives in interval-bounds-state.svelte.ts;
11
+ * pure helpers live in interval-state-helpers.ts.
12
+ *
13
+ * Construction-time deriveds may legitimately read model / effectiveZoomDomains
14
+ * (factory sits after the runtime). Armed later-declared / handler-only deps
15
+ * for the construction guard: emitSelection, commitZoom, announce,
16
+ * inspectionPanel, candidateSemanticKeys.
17
+ *
18
+ * The host constructs semantic-key resolution before this factory
19
+ * (construction-order convention; deriveds are lazy at the 5.33.1 floor, so
20
+ * interval projection evaluates on first read, not at construction).
21
+ * Semantic diagnostics retain their later effect-registration position
22
+ * through the service's phased `registerEffects()` API (#165).
23
+ */
24
+ import { encodeKey } from "@ggts-sh/core";
25
+ import { createIntervalScopedStore } from "../interaction/scoped-store.svelte.js";
26
+ import { frozenZoomDomains } from "../scene/geometry.js";
27
+ import { buildIntervalSelection, clearIntervalSelectionEvent, persistentSelectionOrNull, } from "./interval.js";
28
+ import { consumeIntervalKeys, recomputePanelIntervalFromLookup, sameIntervalRecord, } from "./consumption.js";
29
+ import { semanticAxisFromBounds } from "./precise-bounds.js";
30
+ import { facetIdentityValueLabel, viewportSelection } from "./interval-state-helpers.js";
31
+ import { createIntervalBoundsEditor } from "./interval-bounds-state.svelte.js";
32
+ // ---------------------------------------------------------------------------
33
+ // Factory
34
+ // ---------------------------------------------------------------------------
35
+ /**
36
+ * Create the interval-selection controller. Both effects register at
37
+ * construction (original host positions relative to the runtime model effects
38
+ * and the later semantic-key diagnostics effects).
39
+ */
40
+ export function createIntervalState(context, options) {
41
+ let committedInterval = $state(null);
42
+ // Semantic snapshot of the record backing `committedInterval`, so external
43
+ // same-panel replacements are detected by content, not just presence.
44
+ let committedIntervalRecord = $state(null);
45
+ const committedIntervals = createIntervalScopedStore({
46
+ controller: context.interaction,
47
+ scope: context.resolvedInteractionScope,
48
+ });
49
+ const effectiveIntervals = $derived(committedIntervals.value);
50
+ const effectiveIntervalKeys = $derived.by(() => {
51
+ const model = context.model();
52
+ if (model === null || effectiveIntervals.length === 0)
53
+ return [];
54
+ // Union consumes only stored record keys, and this derived re-runs on
55
+ // every controller revision — skip the O(candidates) semantic projection
56
+ // whenever the preset never reads it.
57
+ const preset = effectiveIntervals[0]?.preset;
58
+ if (preset === "union")
59
+ return consumeIntervalKeys({
60
+ records: effectiveIntervals,
61
+ panels: model.scene.panels,
62
+ candidates: [],
63
+ });
64
+ return consumeIntervalKeys({
65
+ records: effectiveIntervals,
66
+ panels: model.scene.panels,
67
+ candidates: options.consumptionCandidates(),
68
+ });
69
+ });
70
+ const currentIntervalRecord = $derived.by(() => {
71
+ const intervalPanelId = committedInterval?.panelId;
72
+ return ((intervalPanelId === null || intervalPanelId === undefined
73
+ ? undefined
74
+ : effectiveIntervals.find((record) => record.panelId === intervalPanelId)) ??
75
+ effectiveIntervals[0] ??
76
+ null);
77
+ });
78
+ const currentIntervalPanel = $derived.by(() => {
79
+ const model = context.model();
80
+ if (currentIntervalRecord === null || model === null) {
81
+ // Explicit undefined keeps consistent-return happy on the .ts surface
82
+ // (host .svelte used bare `return`; type-aware lint only runs on .ts).
83
+ return undefined;
84
+ }
85
+ return model.scene.panels.find((candidate) => candidate.id === currentIntervalRecord.panelId);
86
+ });
87
+ // A shared controller can clear or replace this chart's interval from
88
+ // outside (a linked plot, programmatic reconcile). The local pixel
89
+ // rectangle must not outlive its semantic record — including a same-panel
90
+ // record whose domains or keys were replaced under it.
91
+ $effect(() => {
92
+ const current = committedInterval;
93
+ if (current === null)
94
+ return;
95
+ const record = effectiveIntervals.find((candidate) => candidate.panelId === current.panelId);
96
+ if (record !== undefined &&
97
+ (committedIntervalRecord === null || sameIntervalRecord(committedIntervalRecord, record)))
98
+ return;
99
+ committedInterval = null;
100
+ committedIntervalRecord = null;
101
+ });
102
+ function intervalPanelLabel(panel) {
103
+ const display = panel.strip.trim() || "panel";
104
+ const model = context.model();
105
+ if (model === null ||
106
+ model.scene.panels.filter((candidate) => candidate.strip.trim() === panel.strip.trim())
107
+ .length < 2)
108
+ return display;
109
+ const identity = panel.identity.values
110
+ .map((value) => `${value.field}: ${facetIdentityValueLabel(value.encodedValue)}`)
111
+ .join(", ");
112
+ return identity.length > 0 ? `${display} (${identity})` : display;
113
+ }
114
+ const currentIntervalTargetLabel = $derived.by(() => {
115
+ if (currentIntervalRecord === null || context.model() === null) {
116
+ return undefined;
117
+ }
118
+ if (currentIntervalPanel === undefined)
119
+ return "unavailable panel";
120
+ if (currentIntervalPanel.strip.trim().length === 0 &&
121
+ currentIntervalPanel.identity.values.length === 0) {
122
+ return undefined;
123
+ }
124
+ return intervalPanelLabel(currentIntervalPanel);
125
+ });
126
+ const intervalBoundsTargetAvailable = $derived(currentIntervalRecord === null || currentIntervalPanel !== undefined);
127
+ const bounds = createIntervalBoundsEditor({
128
+ model: context.model,
129
+ captureSurface: context.captureSurface,
130
+ announce: context.announce,
131
+ effectiveZoomDomains: options.effectiveZoomDomains,
132
+ currentIntervalRecord: () => currentIntervalRecord,
133
+ currentIntervalPanel: () => currentIntervalPanel,
134
+ inspectionPanel: options.inspectionPanel,
135
+ intervalPanelLabel,
136
+ });
137
+ function clearIntervalSelection(source) {
138
+ const current = committedInterval;
139
+ if (current === null && effectiveIntervals.length === 0)
140
+ return;
141
+ committedIntervals.clear(source);
142
+ const event = clearIntervalSelectionEvent(current ?? {
143
+ mode: context.selectConfig()?.mode ?? "xy",
144
+ panelId: null,
145
+ pixels: { x0: 0, y0: 0, x1: 0, y1: 0 },
146
+ }, source);
147
+ committedInterval = null;
148
+ committedIntervalRecord = null;
149
+ options.emitSelection(event);
150
+ }
151
+ function clearCurrentPanelInterval(source) {
152
+ const intervalPanelId = committedInterval?.panelId ?? currentIntervalRecord?.panelId;
153
+ if (intervalPanelId === null || intervalPanelId === undefined)
154
+ return;
155
+ committedIntervals.remove(intervalPanelId, source);
156
+ const event = clearIntervalSelectionEvent(committedInterval ?? {
157
+ mode: context.selectConfig()?.mode ?? "xy",
158
+ panelId: intervalPanelId,
159
+ pixels: { x0: 0, y0: 0, x1: 0, y1: 0 },
160
+ }, source);
161
+ committedInterval = null;
162
+ committedIntervalRecord = null;
163
+ options.emitSelection(event);
164
+ }
165
+ function semanticAxis(panelId, axis, axisBounds) {
166
+ if (axisBounds === undefined || context.model() === null)
167
+ return undefined;
168
+ const viewportPanel = context.model().viewport.panel(panelId);
169
+ if (viewportPanel === null)
170
+ return undefined;
171
+ const scale = viewportPanel.axisEditModel(axis);
172
+ if (scale.kind === "band") {
173
+ const values = scale.slice(axisBounds);
174
+ if (values === undefined)
175
+ return undefined;
176
+ return Object.freeze({
177
+ kind: "band",
178
+ values: Object.freeze(values.map((value) => encodeKey(value))),
179
+ });
180
+ }
181
+ return semanticAxisFromBounds(scale.type, scale.transform, [
182
+ Number(axisBounds[0]),
183
+ Number(axisBounds[1]),
184
+ ]);
185
+ }
186
+ /**
187
+ * One full-store pass for precise-bounds apply: semantic keys + lineage row
188
+ * count for the target panel/domains. Domain-filters before lineage
189
+ * expansion and expands each lineage id once among matches (shared smooth /
190
+ * aggregate bags — not once per mark).
191
+ */
192
+ function recomputePanelIntervalSelection(targetPanelId, domains) {
193
+ const model = context.model();
194
+ if (model === null)
195
+ return { keys: Object.freeze([]), lineageCount: 0 };
196
+ return recomputePanelIntervalFromLookup({
197
+ panelId: targetPanelId,
198
+ domains,
199
+ size: model.candidates.size,
200
+ candidate: (id) => {
201
+ const candidate = model.candidates.candidate(id);
202
+ if (candidate === null)
203
+ return null;
204
+ return {
205
+ panelId: candidate.panelId,
206
+ xValue: candidate.xValue,
207
+ yValue: candidate.yValue,
208
+ lineage: candidate.lineage,
209
+ rowIndex: candidate.rowIndex,
210
+ // Lazy: pay key resolution only after domain membership passes.
211
+ get keys() {
212
+ return context.candidateSemanticKeys(candidate);
213
+ },
214
+ };
215
+ },
216
+ lineageKeys: (lineageId) => model.lineage.keys(lineageId),
217
+ });
218
+ }
219
+ /** Private — no remaining external consumer (codex P2-7). */
220
+ function commitIntervalSelection(event, source) {
221
+ const targetPanelId = event.panelId;
222
+ if (targetPanelId === null || context.model() === null)
223
+ return;
224
+ const model = context.model();
225
+ if (model.viewport.panel(targetPanelId) === null)
226
+ return;
227
+ const x = semanticAxis(targetPanelId, "x", event.domain.x);
228
+ const y = semanticAxis(targetPanelId, "y", event.domain.y);
229
+ // An empty facet panel trains no band domain, so no semantic axis
230
+ // survives the selection mode. The controller rejects axis-less
231
+ // intervals (TypeError) — treat the brush as an empty selection.
232
+ if (x === undefined && y === undefined)
233
+ return;
234
+ const record = Object.freeze({
235
+ panelId: targetPanelId,
236
+ preset: context.selectConfig()?.preset ?? "independent",
237
+ domains: Object.freeze({
238
+ ...(x !== undefined && { x }),
239
+ ...(y !== undefined && { y }),
240
+ }),
241
+ keys: Object.freeze([...event.keys]),
242
+ });
243
+ committedIntervalRecord = record;
244
+ committedIntervals.upsert(record, source);
245
+ }
246
+ function finishBrushSelect(eventValue, source) {
247
+ // Snapshot once (drift-safe under reactive selectConfig replacement).
248
+ const persistent = context.selectConfig()?.persistent;
249
+ committedInterval = persistentSelectionOrNull(persistent, eventValue);
250
+ // TRUTHY guard — untyped JS consumers may pass truthy non-boolean
251
+ // `persistent` values, which the config normalizer forwards unchanged.
252
+ // `?? false` only maps nullish (already falsy) values, so runtime
253
+ // truthiness is identical.
254
+ if (persistent ?? false)
255
+ commitIntervalSelection(eventValue, source);
256
+ // Emit after writes so listeners observe committed state (load-bearing).
257
+ options.emitSelection(eventValue);
258
+ }
259
+ function applyPreciseZoomBounds(event) {
260
+ if (event.scale === "band")
261
+ return;
262
+ options.commitZoom(frozenZoomDomains({
263
+ ...options.effectiveZoomDomains(),
264
+ [event.axis]: [...event.bounds],
265
+ }), event.inputSource);
266
+ bounds.cancel();
267
+ }
268
+ function applyPreciseSelectionBounds(event) {
269
+ const prior = currentIntervalRecord;
270
+ const targetPanelId = prior?.panelId ?? bounds.boundsEditor?.panelId;
271
+ if (targetPanelId === null || targetPanelId === undefined || context.model() === null)
272
+ return;
273
+ const model = context.model();
274
+ if (model.viewport.panel(targetPanelId) === null)
275
+ return;
276
+ const axis = semanticAxis(targetPanelId, event.axis, event.bounds);
277
+ if (axis === undefined)
278
+ return;
279
+ const domains = Object.freeze({
280
+ ...prior?.domains,
281
+ [event.axis]: axis,
282
+ });
283
+ // Keys + lineageCount from one candidate-store pass (not consumption then
284
+ // a second lineage scan).
285
+ const { keys, lineageCount } = recomputePanelIntervalSelection(targetPanelId, domains);
286
+ const next = Object.freeze({
287
+ panelId: targetPanelId,
288
+ preset: prior?.preset ?? context.selectConfig()?.preset ?? "independent",
289
+ domains,
290
+ keys,
291
+ });
292
+ // Precise bounds persist exactly like the brush path: with
293
+ // `persistent: false` the end event still fires, but no durable record,
294
+ // committed rectangle, or clear-selection controls appear.
295
+ const persistent = context.selectConfig()?.persistent === true;
296
+ if (persistent) {
297
+ committedIntervalRecord = next;
298
+ committedIntervals.upsert(next, event.inputSource);
299
+ }
300
+ const viewportPanel = model.viewport.panel(targetPanelId);
301
+ if (viewportPanel === null)
302
+ return;
303
+ const selection = viewportSelection(domains);
304
+ const eventValue = buildIntervalSelection({
305
+ phase: "end",
306
+ mode: context.selectConfig()?.mode ?? "xy",
307
+ panelId: targetPanelId,
308
+ domain: viewportPanel.resolve(selection),
309
+ // The overlay must depict the interval that was actually applied, so
310
+ // project the edited domains back into pixels rather than reusing the
311
+ // pre-edit rectangle (or defaulting to the whole panel).
312
+ pixels: viewportPanel.project(selection),
313
+ keys,
314
+ lineageCount,
315
+ source: event.inputSource,
316
+ });
317
+ committedInterval = persistentSelectionOrNull(context.selectConfig()?.persistent, eventValue);
318
+ options.emitSelection(eventValue);
319
+ bounds.cancel();
320
+ }
321
+ function applyPreciseBounds(event) {
322
+ if (event.action === "zoom")
323
+ applyPreciseZoomBounds(event);
324
+ else
325
+ applyPreciseSelectionBounds(event);
326
+ }
327
+ return {
328
+ get committedInterval() {
329
+ return committedInterval;
330
+ },
331
+ get effectiveIntervals() {
332
+ return effectiveIntervals;
333
+ },
334
+ get effectiveIntervalKeys() {
335
+ return effectiveIntervalKeys;
336
+ },
337
+ get currentIntervalTargetLabel() {
338
+ return currentIntervalTargetLabel;
339
+ },
340
+ get boundsEditorInput() {
341
+ return bounds.boundsEditorInput;
342
+ },
343
+ get boundsReturnFocus() {
344
+ return bounds.boundsReturnFocus;
345
+ },
346
+ get intervalBoundsTargetAvailable() {
347
+ return intervalBoundsTargetAvailable;
348
+ },
349
+ clearIntervalSelection,
350
+ clearCurrentPanelInterval,
351
+ finishBrushSelect,
352
+ openBoundsEditor: (...args) => {
353
+ bounds.openBoundsEditor(...args);
354
+ },
355
+ applyPreciseBounds,
356
+ cancelBoundsEditor: () => {
357
+ bounds.cancel();
358
+ },
359
+ };
360
+ }
@@ -0,0 +1 @@
1
+ export { BRUSH_MIN_SPAN_PX, persistentSelectionOrNull, isBrushTooSmall, filterDomainBySelectMode, freezeIntervalDomain, buildIntervalSelection, clearIntervalSelectionEvent, lineageRowIndexesFromCandidates, intervalSelectionFromRows, } from "@ggts-sh/core/interaction";
@@ -0,0 +1,2 @@
1
+ // Shared pure behavior used by React and Svelte.
2
+ export { BRUSH_MIN_SPAN_PX, persistentSelectionOrNull, isBrushTooSmall, filterDomainBySelectMode, freezeIntervalDomain, buildIntervalSelection, clearIntervalSelectionEvent, lineageRowIndexesFromCandidates, intervalSelectionFromRows, } from "@ggts-sh/core/interaction";
@@ -0,0 +1 @@
1
+ export { boundsEditorInputForScale, semanticAxisFromBounds } from "@ggts-sh/core/interaction";
@@ -0,0 +1,2 @@
1
+ // Shared pure behavior used by React and Svelte.
2
+ export { boundsEditorInputForScale, semanticAxisFromBounds } from "@ggts-sh/core/interaction";
@@ -0,0 +1 @@
1
+ export { type IntervalQueryScene, intervalQuerySceneFromModel, resolveIntervalQueryParts, buildIntervalSelectionFromScene, } from "@ggts-sh/core/interaction";
@@ -0,0 +1,2 @@
1
+ // Shared pure behavior used by React and Svelte.
2
+ export { intervalQuerySceneFromModel, resolveIntervalQueryParts, buildIntervalSelectionFromScene, } from "@ggts-sh/core/interaction";
@@ -0,0 +1,29 @@
1
+ <script lang="ts">
2
+ /**
3
+ * <Labs> — declaration-only labels layer for <GGPlot> (#659 slice 6).
4
+ * The whole Labs surface: title, subtitle, caption, and the per-aesthetic
5
+ * titles (x, y, color, fill, size, linewidth, alpha, shape, linetype).
6
+ *
7
+ * No separate escape hatch: Labs is a flat bag of strings, so
8
+ * `<Labs {...computed} />` already covers the computed case.
9
+ *
10
+ * labs is a keyed-MERGE family — two <Labs> children merge key-by-key rather
11
+ * than the second replacing the first. Two children setting the SAME key
12
+ * emit a DUPLICATE_MERGE_KEY advisory (the later one still wins).
13
+ *
14
+ * Emits NO markup; registers a live labs layer during component init and
15
+ * unregisters on destroy. Inert without a <GGPlot> ancestor.
16
+ */
17
+ // Aliased deliberately: svelte-package emits `declare const Labs` for this
18
+ // component into Labs.svelte.d.ts, so a bare `import type { Labs }` here
19
+ // collides with it in every consumer's svelte-check.
20
+ import type { Labs as LabsSpec } from "@ggts-sh/spec";
21
+
22
+ import {
23
+ createPlotLayer,
24
+ definedProps,
25
+ } from "../layers/plot-layer.svelte.js";
26
+
27
+ const props: LabsSpec = $props();
28
+ createPlotLayer("labs", () => definedProps(props));
29
+ </script>
@@ -0,0 +1,16 @@
1
+ declare const Labs: import("svelte").Component<{
2
+ x?: string;
3
+ y?: string;
4
+ color?: string;
5
+ fill?: string;
6
+ size?: string;
7
+ linewidth?: string;
8
+ alpha?: string;
9
+ shape?: string;
10
+ linetype?: string;
11
+ caption?: string;
12
+ title?: string;
13
+ subtitle?: string;
14
+ }, {}, "">;
15
+ type Labs = ReturnType<typeof Labs>;
16
+ export default Labs;
@@ -0,0 +1,2 @@
1
+ export { foldPlotLayer } from "@ggts-sh/compose";
2
+ export type { AssembleDraft } from "@ggts-sh/compose";
@@ -0,0 +1 @@
1
+ export { foldPlotLayer } from "@ggts-sh/compose";
@@ -0,0 +1,2 @@
1
+ export { GGPLOT_PROP_ORDER, GRAMMAR_DOC_URLS, GRAMMAR_FAMILIES, GRAMMAR_PROP_NAMES, MERGE_KEY_EMIT_ORDER, REPLACE_EMIT_ORDER, deprecatedGrammarPropPattern, grammarCodemodRules, grammarDocUrl, } from "@ggts-sh/compose";
2
+ export type { GrammarCodemodForm, MergeByKeyKind, ReplaceKind } from "@ggts-sh/compose";
@@ -0,0 +1 @@
1
+ export { GGPLOT_PROP_ORDER, GRAMMAR_DOC_URLS, GRAMMAR_FAMILIES, GRAMMAR_PROP_NAMES, MERGE_KEY_EMIT_ORDER, REPLACE_EMIT_ORDER, deprecatedGrammarPropPattern, grammarCodemodRules, grammarDocUrl, } from "@ggts-sh/compose";
@@ -0,0 +1 @@
1
+ export {};