@primeui/chart-core 0.0.1-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +23 -0
- package/README.md +1 -0
- package/dist/animations/index.d.mts +136 -0
- package/dist/animations/index.mjs +18 -0
- package/dist/annotation.utils-Bm0lOO1o.d.mts +290 -0
- package/dist/borderRadius.utils-Cz73LLR_.d.mts +54 -0
- package/dist/canvas-D4vigq47.d.mts +34 -0
- package/dist/canvas.utils-D2WHi2gL.d.mts +167 -0
- package/dist/cartesian/index.d.mts +94 -0
- package/dist/cartesian/index.mjs +93 -0
- package/dist/chunk-22ST6YPP.mjs +304 -0
- package/dist/chunk-2QK2KOBN.mjs +10 -0
- package/dist/chunk-2QRS4YQ5.mjs +18 -0
- package/dist/chunk-3FFJEX4A.mjs +261 -0
- package/dist/chunk-3IYSJ2U7.mjs +567 -0
- package/dist/chunk-3OZLP4I4.mjs +190 -0
- package/dist/chunk-3WEMHXZI.mjs +198 -0
- package/dist/chunk-3Z62EUJN.mjs +138 -0
- package/dist/chunk-4C6EVJ54.mjs +362 -0
- package/dist/chunk-53HW45JB.mjs +102 -0
- package/dist/chunk-55Y3WI6S.mjs +186 -0
- package/dist/chunk-5JCI2DEB.mjs +97 -0
- package/dist/chunk-66T4MRC5.mjs +113 -0
- package/dist/chunk-6HSEJLSR.mjs +376 -0
- package/dist/chunk-6STOLMCA.mjs +187 -0
- package/dist/chunk-7CMVDIOU.mjs +54 -0
- package/dist/chunk-7QQ6ETB4.mjs +228 -0
- package/dist/chunk-A6ZQZFL2.mjs +272 -0
- package/dist/chunk-ADKLH73T.mjs +1 -0
- package/dist/chunk-AGU3NG6D.mjs +22 -0
- package/dist/chunk-AHYIS6EB.mjs +230 -0
- package/dist/chunk-AP3UYWYT.mjs +4 -0
- package/dist/chunk-ARB5T6MP.mjs +326 -0
- package/dist/chunk-ARRGOEFX.mjs +585 -0
- package/dist/chunk-AUF4CHDP.mjs +422 -0
- package/dist/chunk-B4FTADAZ.mjs +561 -0
- package/dist/chunk-BABQKA6K.mjs +339 -0
- package/dist/chunk-BETFQBM2.mjs +197 -0
- package/dist/chunk-BKP26M4K.mjs +413 -0
- package/dist/chunk-BZN2QHGP.mjs +200 -0
- package/dist/chunk-C36VWQ7A.mjs +86 -0
- package/dist/chunk-CHW4RKY3.mjs +16 -0
- package/dist/chunk-CINXJIRR.mjs +120 -0
- package/dist/chunk-DN6AXQYZ.mjs +667 -0
- package/dist/chunk-DP2IZNN3.mjs +92 -0
- package/dist/chunk-DTWTCFRG.mjs +119 -0
- package/dist/chunk-EAMUNLRU.mjs +172 -0
- package/dist/chunk-EDAKJLNA.mjs +17 -0
- package/dist/chunk-ERVQB2VZ.mjs +59 -0
- package/dist/chunk-FFMT6OCO.mjs +92 -0
- package/dist/chunk-FHTC2YDB.mjs +102 -0
- package/dist/chunk-FRST55HY.mjs +16 -0
- package/dist/chunk-HDFGCN2F.mjs +132 -0
- package/dist/chunk-IEGLX7VL.mjs +42 -0
- package/dist/chunk-ILUWFYGY.mjs +220 -0
- package/dist/chunk-IXOWSEHO.mjs +114 -0
- package/dist/chunk-J4RI2C2G.mjs +172 -0
- package/dist/chunk-J65DBT4R.mjs +13 -0
- package/dist/chunk-JGOVWSKH.mjs +179 -0
- package/dist/chunk-JO7VACY2.mjs +25 -0
- package/dist/chunk-JWFBOPM6.mjs +122 -0
- package/dist/chunk-KNDZP446.mjs +895 -0
- package/dist/chunk-KP2TWD4Z.mjs +90 -0
- package/dist/chunk-KQIFO5I3.mjs +225 -0
- package/dist/chunk-KVDEROP6.mjs +59 -0
- package/dist/chunk-LKC7MZKK.mjs +87 -0
- package/dist/chunk-LVMDQ4OJ.mjs +305 -0
- package/dist/chunk-M7B3JF43.mjs +90 -0
- package/dist/chunk-MTGMXRNF.mjs +136 -0
- package/dist/chunk-N3TIT3OH.mjs +1040 -0
- package/dist/chunk-NHRK5KU2.mjs +890 -0
- package/dist/chunk-NKUYIWAP.mjs +243 -0
- package/dist/chunk-NPDZLYIF.mjs +238 -0
- package/dist/chunk-O2X6FF45.mjs +499 -0
- package/dist/chunk-OGJ6IIBW.mjs +176 -0
- package/dist/chunk-OHGCZZPZ.mjs +403 -0
- package/dist/chunk-OWW3K55O.mjs +351 -0
- package/dist/chunk-OXTFAWSK.mjs +60 -0
- package/dist/chunk-PLSDU3C2.mjs +890 -0
- package/dist/chunk-PRDVPOZX.mjs +223 -0
- package/dist/chunk-Q6PPVIHU.mjs +21 -0
- package/dist/chunk-QQBXUDM4.mjs +885 -0
- package/dist/chunk-QS76E3TD.mjs +111 -0
- package/dist/chunk-QWQ6HY4I.mjs +209 -0
- package/dist/chunk-R6Y3R7EW.mjs +135 -0
- package/dist/chunk-RBLZRT5K.mjs +190 -0
- package/dist/chunk-RO4N6YFS.mjs +167 -0
- package/dist/chunk-RQ3CKQOX.mjs +984 -0
- package/dist/chunk-SALTGZFR.mjs +208 -0
- package/dist/chunk-SANZPAJ4.mjs +14 -0
- package/dist/chunk-SDBPQ5CF.mjs +624 -0
- package/dist/chunk-SSLTFJ3U.mjs +364 -0
- package/dist/chunk-SXHVDJGF.mjs +77 -0
- package/dist/chunk-TA4MVAEX.mjs +243 -0
- package/dist/chunk-TAHCOZHF.mjs +1772 -0
- package/dist/chunk-TQ6S34QZ.mjs +152 -0
- package/dist/chunk-UPRXABX5.mjs +90 -0
- package/dist/chunk-VGLSBZDN.mjs +71 -0
- package/dist/chunk-VN7CKCSE.mjs +364 -0
- package/dist/chunk-VVI3OBPJ.mjs +524 -0
- package/dist/chunk-VWF57TS3.mjs +62 -0
- package/dist/chunk-WA3OVISZ.mjs +179 -0
- package/dist/chunk-WCG35U6M.mjs +964 -0
- package/dist/chunk-WFTX4AQJ.mjs +194 -0
- package/dist/chunk-WFVOQ2QZ.mjs +18 -0
- package/dist/chunk-WH3C3Y7P.mjs +149 -0
- package/dist/chunk-WPFUV7K3.mjs +488 -0
- package/dist/chunk-WRULPWHD.mjs +492 -0
- package/dist/chunk-WS64BZXT.mjs +1 -0
- package/dist/chunk-WY4AURRE.mjs +2419 -0
- package/dist/chunk-WYLILAOO.mjs +167 -0
- package/dist/chunk-X4D7FKUS.mjs +62 -0
- package/dist/chunk-X7T34OLW.mjs +139 -0
- package/dist/chunk-XIHBK5D3.mjs +68 -0
- package/dist/chunk-XQQCGFYB.mjs +50 -0
- package/dist/chunk-XTVE4P3L.mjs +214 -0
- package/dist/chunk-XUAASRXW.mjs +579 -0
- package/dist/chunk-Y3L3D4GQ.mjs +685 -0
- package/dist/chunk-YBJ56XJS.mjs +132 -0
- package/dist/chunk-ZQFK6CAE.mjs +1 -0
- package/dist/chunk-ZT2Z7ERM.mjs +874 -0
- package/dist/chunk-ZTL2FQEW.mjs +714 -0
- package/dist/circular/arc/index.d.mts +8 -0
- package/dist/circular/arc/index.mjs +3 -0
- package/dist/circular/index.d.mts +44 -0
- package/dist/circular/index.mjs +13 -0
- package/dist/collect.utils-DiKB4ciO.d.mts +12 -0
- package/dist/computeChartState-BTVIqwyO.d.mts +304 -0
- package/dist/controller-BJE1AZ3q.d.mts +82 -0
- package/dist/controller-BoNigQJr.d.mts +63 -0
- package/dist/controllers/index.d.mts +16 -0
- package/dist/controllers/index.mjs +110 -0
- package/dist/datalabel.utils-CkjGeB8S.d.mts +122 -0
- package/dist/decimation.utils-CcvJVhI4.d.mts +244 -0
- package/dist/geometry-DUUQJXVM.d.mts +60 -0
- package/dist/index-DseIZa1j.d.mts +167 -0
- package/dist/index.d.mts +88 -0
- package/dist/index.mjs +110 -0
- package/dist/orchestrator/index.d.mts +264 -0
- package/dist/orchestrator/index.mjs +33 -0
- package/dist/plugins/index.d.mts +18 -0
- package/dist/plugins/index.mjs +1 -0
- package/dist/property-animations-D433wXzz.d.mts +580 -0
- package/dist/property-store-NORUWFND.d.mts +17 -0
- package/dist/radial/index.d.mts +14 -0
- package/dist/radial/index.mjs +37 -0
- package/dist/renderers/axis/index.d.mts +39 -0
- package/dist/renderers/axis/index.mjs +8 -0
- package/dist/renderers/circular/index.d.mts +13 -0
- package/dist/renderers/circular/index.mjs +13 -0
- package/dist/renderers/index.d.mts +83 -0
- package/dist/renderers/index.mjs +75 -0
- package/dist/renderers/navigator/index.d.mts +103 -0
- package/dist/renderers/navigator/index.mjs +8 -0
- package/dist/resize.utils-D_2qm6rv.d.mts +142 -0
- package/dist/ring.utils-DXvrxMkU.d.mts +138 -0
- package/dist/scale-KFv30jqZ.d.mts +307 -0
- package/dist/scales-Drf8AIhL.d.mts +75 -0
- package/dist/series/bar/canvas/index.d.mts +8 -0
- package/dist/series/bar/canvas/index.mjs +10 -0
- package/dist/series/bar/controller/index.d.mts +105 -0
- package/dist/series/bar/controller/index.mjs +44 -0
- package/dist/series/bar/controller-canvas/index.d.mts +7 -0
- package/dist/series/bar/controller-canvas/index.mjs +49 -0
- package/dist/series/bar/controller-svg/index.d.mts +7 -0
- package/dist/series/bar/controller-svg/index.mjs +49 -0
- package/dist/series/bar/index.d.mts +60 -0
- package/dist/series/bar/index.mjs +13 -0
- package/dist/series/bar/svg/index.d.mts +8 -0
- package/dist/series/bar/svg/index.mjs +11 -0
- package/dist/series/candlestick/canvas/index.d.mts +8 -0
- package/dist/series/candlestick/canvas/index.mjs +8 -0
- package/dist/series/candlestick/controller/index.d.mts +123 -0
- package/dist/series/candlestick/controller/index.mjs +40 -0
- package/dist/series/candlestick/controller-canvas/index.d.mts +7 -0
- package/dist/series/candlestick/controller-canvas/index.mjs +45 -0
- package/dist/series/candlestick/controller-svg/index.d.mts +7 -0
- package/dist/series/candlestick/controller-svg/index.mjs +45 -0
- package/dist/series/candlestick/index.d.mts +11 -0
- package/dist/series/candlestick/index.mjs +10 -0
- package/dist/series/candlestick/svg/index.d.mts +8 -0
- package/dist/series/candlestick/svg/index.mjs +8 -0
- package/dist/series/heatmap/canvas/index.d.mts +16 -0
- package/dist/series/heatmap/canvas/index.mjs +9 -0
- package/dist/series/heatmap/controller/index.d.mts +110 -0
- package/dist/series/heatmap/controller/index.mjs +23 -0
- package/dist/series/heatmap/controller-canvas/index.d.mts +7 -0
- package/dist/series/heatmap/controller-canvas/index.mjs +28 -0
- package/dist/series/heatmap/controller-svg/index.d.mts +7 -0
- package/dist/series/heatmap/controller-svg/index.mjs +28 -0
- package/dist/series/heatmap/index.d.mts +34 -0
- package/dist/series/heatmap/index.mjs +13 -0
- package/dist/series/heatmap/svg/index.d.mts +15 -0
- package/dist/series/heatmap/svg/index.mjs +10 -0
- package/dist/series/line/canvas/index.d.mts +6 -0
- package/dist/series/line/canvas/index.mjs +9 -0
- package/dist/series/line/controller/index.d.mts +111 -0
- package/dist/series/line/controller/index.mjs +47 -0
- package/dist/series/line/controller-canvas/index.d.mts +7 -0
- package/dist/series/line/controller-canvas/index.mjs +54 -0
- package/dist/series/line/controller-svg/index.d.mts +7 -0
- package/dist/series/line/controller-svg/index.mjs +54 -0
- package/dist/series/line/index.d.mts +49 -0
- package/dist/series/line/index.mjs +13 -0
- package/dist/series/line/svg/index.d.mts +6 -0
- package/dist/series/line/svg/index.mjs +9 -0
- package/dist/series/pie/canvas/index.d.mts +8 -0
- package/dist/series/pie/canvas/index.mjs +10 -0
- package/dist/series/pie/controller/index.d.mts +174 -0
- package/dist/series/pie/controller/index.mjs +110 -0
- package/dist/series/pie/controller-canvas/index.d.mts +8 -0
- package/dist/series/pie/controller-canvas/index.mjs +119 -0
- package/dist/series/pie/controller-svg/index.d.mts +8 -0
- package/dist/series/pie/controller-svg/index.mjs +118 -0
- package/dist/series/pie/index.d.mts +59 -0
- package/dist/series/pie/index.mjs +15 -0
- package/dist/series/pie/svg/index.d.mts +6 -0
- package/dist/series/pie/svg/index.mjs +11 -0
- package/dist/series/polar/canvas/index.d.mts +6 -0
- package/dist/series/polar/canvas/index.mjs +7 -0
- package/dist/series/polar/controller/index.d.mts +102 -0
- package/dist/series/polar/controller/index.mjs +46 -0
- package/dist/series/polar/controller-canvas/index.d.mts +8 -0
- package/dist/series/polar/controller-canvas/index.mjs +52 -0
- package/dist/series/polar/controller-svg/index.d.mts +8 -0
- package/dist/series/polar/controller-svg/index.mjs +52 -0
- package/dist/series/polar/index.d.mts +25 -0
- package/dist/series/polar/index.mjs +16 -0
- package/dist/series/polar/svg/index.d.mts +10 -0
- package/dist/series/polar/svg/index.mjs +8 -0
- package/dist/series/radar/canvas/index.d.mts +6 -0
- package/dist/series/radar/canvas/index.mjs +8 -0
- package/dist/series/radar/controller/index.d.mts +121 -0
- package/dist/series/radar/controller/index.mjs +43 -0
- package/dist/series/radar/controller-canvas/index.d.mts +8 -0
- package/dist/series/radar/controller-canvas/index.mjs +51 -0
- package/dist/series/radar/controller-svg/index.d.mts +8 -0
- package/dist/series/radar/controller-svg/index.mjs +51 -0
- package/dist/series/radar/index.d.mts +40 -0
- package/dist/series/radar/index.mjs +13 -0
- package/dist/series/radar/svg/index.d.mts +12 -0
- package/dist/series/radar/svg/index.mjs +9 -0
- package/dist/series/scatter/canvas/index.d.mts +8 -0
- package/dist/series/scatter/canvas/index.mjs +11 -0
- package/dist/series/scatter/controller/index.d.mts +124 -0
- package/dist/series/scatter/controller/index.mjs +44 -0
- package/dist/series/scatter/controller-canvas/index.d.mts +7 -0
- package/dist/series/scatter/controller-canvas/index.mjs +51 -0
- package/dist/series/scatter/controller-svg/index.d.mts +7 -0
- package/dist/series/scatter/controller-svg/index.mjs +51 -0
- package/dist/series/scatter/index.d.mts +25 -0
- package/dist/series/scatter/index.mjs +14 -0
- package/dist/series/scatter/svg/index.d.mts +8 -0
- package/dist/series/scatter/svg/index.mjs +12 -0
- package/dist/series/treemap/canvas/index.d.mts +50 -0
- package/dist/series/treemap/canvas/index.mjs +10 -0
- package/dist/series/treemap/controller/index.d.mts +130 -0
- package/dist/series/treemap/controller/index.mjs +20 -0
- package/dist/series/treemap/controller-canvas/index.d.mts +7 -0
- package/dist/series/treemap/controller-canvas/index.mjs +25 -0
- package/dist/series/treemap/controller-svg/index.d.mts +7 -0
- package/dist/series/treemap/controller-svg/index.mjs +25 -0
- package/dist/series/treemap/index.d.mts +15 -0
- package/dist/series/treemap/index.mjs +12 -0
- package/dist/series/treemap/svg/index.d.mts +15 -0
- package/dist/series/treemap/svg/index.mjs +9 -0
- package/dist/slices-DtewiwJx.d.mts +72 -0
- package/dist/spatialIndex.utils-B_GJkotZ.d.mts +5 -0
- package/dist/squarify.utils-B9CQBpa1.d.mts +50 -0
- package/dist/stacking-CChuAcLN.d.mts +319 -0
- package/dist/streaming.utils-DH-g1gNP.d.mts +49 -0
- package/dist/sync/index.d.mts +130 -0
- package/dist/sync/index.mjs +5 -0
- package/dist/tooltip.renderer-D5wpSlBa.d.mts +210 -0
- package/dist/utils/color/index.d.mts +58 -0
- package/dist/utils/color/index.mjs +4 -0
- package/dist/utils/data/index.d.mts +180 -0
- package/dist/utils/data/index.mjs +7 -0
- package/dist/utils/export/index.d.mts +14 -0
- package/dist/utils/export/index.mjs +6 -0
- package/dist/utils/index.d.mts +49 -0
- package/dist/utils/index.mjs +29 -0
- package/dist/utils/interaction/index.d.mts +255 -0
- package/dist/utils/interaction/index.mjs +9 -0
- package/dist/utils/layout/index.d.mts +3 -0
- package/dist/utils/layout/index.mjs +10 -0
- package/dist/utils/math/index.d.mts +162 -0
- package/dist/utils/math/index.mjs +1 -0
- package/dist/utils/render/index.d.mts +19 -0
- package/dist/utils/render/index.mjs +3 -0
- package/dist/utils/specialized/index.d.mts +37 -0
- package/dist/utils/specialized/index.mjs +66 -0
- package/dist/utils/text/index.d.mts +39 -0
- package/dist/utils/text/index.mjs +8 -0
- package/dist/utils/theme/index.d.mts +295 -0
- package/dist/utils/theme/index.mjs +5 -0
- package/dist/utils/zoom/index.d.mts +90 -0
- package/dist/utils/zoom/index.mjs +3 -0
- package/package.json +56 -0
|
@@ -0,0 +1,580 @@
|
|
|
1
|
+
import { EasingFunction, AnimatableBar, AxisOpacity, AxisLayoutInfo as AxisLayoutInfo$1, ComputedTick, AnimationRegistryLike, AnimationEntryConfig, AnimationSnapshot, BoxArea, ZoomTransform, HeatmapRenderData, CandlestickRenderData, LineRenderData, LineUpdateKind, AnimatedElementLike, AnimatableRegistry, PerGroupOptions, CanvasCompositorLike, CanvasLayer, CanvasPainter, NamedAnimationSpec, PropertyAnimationConfig, AnimatedPropertyStoreLike } from '@primeui/chart-types';
|
|
2
|
+
import { LinearScale, BandScale } from '@primeui/chart-types/axes';
|
|
3
|
+
import { AxisLayoutInfo } from '@primeui/chart-types/layout';
|
|
4
|
+
import { PolarRenderData } from '@primeui/chart-types/polar';
|
|
5
|
+
import { RadarRenderData, RadialGridConfig } from '@primeui/chart-types/radar';
|
|
6
|
+
|
|
7
|
+
/** Linear - no acceleration */
|
|
8
|
+
declare const linear: EasingFunction;
|
|
9
|
+
/** Ease out quad - light deceleration */
|
|
10
|
+
declare const easeOutQuad: EasingFunction;
|
|
11
|
+
/** Ease out cubic - moderate deceleration */
|
|
12
|
+
declare const easeOutCubic: EasingFunction;
|
|
13
|
+
/** Ease out quart - strong deceleration */
|
|
14
|
+
declare const easeOutQuart: EasingFunction;
|
|
15
|
+
/** Ease out quint - very strong deceleration */
|
|
16
|
+
declare const easeOutQuint: EasingFunction;
|
|
17
|
+
/** Ease out expo - exponential deceleration */
|
|
18
|
+
declare const easeOutExpo: EasingFunction;
|
|
19
|
+
/** Ease in out cubic - acceleration then deceleration */
|
|
20
|
+
declare const easeInOutCubic: EasingFunction;
|
|
21
|
+
/** Ease in out quart */
|
|
22
|
+
declare const easeInOutQuart: EasingFunction;
|
|
23
|
+
/**
|
|
24
|
+
* Ease out back - subtle overshoot then settle
|
|
25
|
+
*/
|
|
26
|
+
declare const easeOutBack: EasingFunction;
|
|
27
|
+
/**
|
|
28
|
+
* Ease out elastic - spring/bounce effect
|
|
29
|
+
*/
|
|
30
|
+
declare const easeOutElastic: EasingFunction;
|
|
31
|
+
/**
|
|
32
|
+
* Ease out bounce - ball-drop bounce effect
|
|
33
|
+
*/
|
|
34
|
+
declare const easeOutBounce: EasingFunction;
|
|
35
|
+
/**
|
|
36
|
+
* Ease in bounce
|
|
37
|
+
*/
|
|
38
|
+
declare const easeInBounce: EasingFunction;
|
|
39
|
+
/**
|
|
40
|
+
* Ease in out bounce
|
|
41
|
+
*/
|
|
42
|
+
declare const easeInOutBounce: EasingFunction;
|
|
43
|
+
/**
|
|
44
|
+
* Register a custom easing function
|
|
45
|
+
* @param name - Unique name for the easing
|
|
46
|
+
* @param fn - Easing function
|
|
47
|
+
*/
|
|
48
|
+
declare function registerEasing(name: string, fn: EasingFunction): void;
|
|
49
|
+
/**
|
|
50
|
+
* Get easing function by name
|
|
51
|
+
* @param name - Easing function name
|
|
52
|
+
* @returns Easing function (defaults to easeOutQuart if not found)
|
|
53
|
+
*/
|
|
54
|
+
declare function getEasing(name: string): EasingFunction;
|
|
55
|
+
/**
|
|
56
|
+
* Check if easing exists
|
|
57
|
+
*/
|
|
58
|
+
declare function hasEasing(name: string): boolean;
|
|
59
|
+
/**
|
|
60
|
+
* Get all registered easing names
|
|
61
|
+
*/
|
|
62
|
+
declare function getEasingNames(): string[];
|
|
63
|
+
/**
|
|
64
|
+
* Convenience object for accessing all built-in easings
|
|
65
|
+
*/
|
|
66
|
+
declare const easings: {
|
|
67
|
+
readonly linear: EasingFunction;
|
|
68
|
+
readonly easeOutQuad: EasingFunction;
|
|
69
|
+
readonly easeOutCubic: EasingFunction;
|
|
70
|
+
readonly easeOutQuart: EasingFunction;
|
|
71
|
+
readonly easeOutQuint: EasingFunction;
|
|
72
|
+
readonly easeOutExpo: EasingFunction;
|
|
73
|
+
readonly easeInOutCubic: EasingFunction;
|
|
74
|
+
readonly easeInOutQuart: EasingFunction;
|
|
75
|
+
readonly easeOutBack: EasingFunction;
|
|
76
|
+
readonly easeOutElastic: EasingFunction;
|
|
77
|
+
readonly easeOutBounce: EasingFunction;
|
|
78
|
+
readonly easeInBounce: EasingFunction;
|
|
79
|
+
readonly easeInOutBounce: EasingFunction;
|
|
80
|
+
};
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* Linear interpolation between two values
|
|
84
|
+
* @param start - Starting value
|
|
85
|
+
* @param end - Ending value
|
|
86
|
+
* @param t - Progress (0-1)
|
|
87
|
+
*/
|
|
88
|
+
declare function lerp(start: number, end: number, t: number): number;
|
|
89
|
+
/**
|
|
90
|
+
* Element-wise linear interpolation between two number arrays.
|
|
91
|
+
*
|
|
92
|
+
* Handles mismatched lengths by defaulting missing elements to the other side
|
|
93
|
+
* (or 0 if both are missing). Used by value-series controllers for snapshot-
|
|
94
|
+
* and-lerp animations (interrupt-safe: reconcile captures the lerped snapshot
|
|
95
|
+
* and writes it back as the new start).
|
|
96
|
+
*/
|
|
97
|
+
declare function lerpValues(start: number[], target: number[], progress: number): number[];
|
|
98
|
+
/**
|
|
99
|
+
* Interpolate between two colors.
|
|
100
|
+
* Uses the shared parseColorToRGB from color.utils (single canvas singleton).
|
|
101
|
+
*
|
|
102
|
+
* @param startColor - Starting color (hex or CSS color)
|
|
103
|
+
* @param endColor - Ending color (hex or CSS color)
|
|
104
|
+
* @param t - Progress (0-1)
|
|
105
|
+
* @returns Hex color string
|
|
106
|
+
*/
|
|
107
|
+
declare function lerpColor(startColor: string, endColor: string, t: number): string;
|
|
108
|
+
/**
|
|
109
|
+
* Interpolate the radial grid between two domain states.
|
|
110
|
+
*
|
|
111
|
+
* Keeps the TARGET's tick VALUES fixed (so the count and labels stay stable —
|
|
112
|
+
* no per-frame re-nicing) and only slides their RADII through the interpolated
|
|
113
|
+
* domain. The rings glide continuously from their previous-scale positions to
|
|
114
|
+
* the target ones — a smooth zoom. The target tick set is domain-aligned
|
|
115
|
+
* (largest tick maps to the domain max), so the outer perimeter stays pinned at
|
|
116
|
+
* `radius` at rest; mid-flight radii are clamped to `[0, radius]`.
|
|
117
|
+
*/
|
|
118
|
+
declare function interpolateRadialGrid(prevDomain: [number, number], targetDomain: [number, number], target: RadialGridConfig, radius: number, progress: number): RadialGridConfig;
|
|
119
|
+
/**
|
|
120
|
+
* Re-map a settled axis layout's tick positions through an intermediate scale,
|
|
121
|
+
* without regenerating the tick set. Used during time-domain lerps to preserve
|
|
122
|
+
* tick stability — the label set is frozen at the settled state; only pixel
|
|
123
|
+
* positions tween between frames.
|
|
124
|
+
*
|
|
125
|
+
* Mirrors `interpolateRadialGrid` above: the tick VALUES and LABELS stay fixed
|
|
126
|
+
* (no per-frame re-nicing, no formatter re-runs, no density/collision/rotation
|
|
127
|
+
* cascade), only their pixel positions slide through the interpolated scale.
|
|
128
|
+
*
|
|
129
|
+
* Ticks whose `rawValue` falls outside the intermediate scale's pixel range are
|
|
130
|
+
* filtered out (they would render outside the plot area). Ticks without a
|
|
131
|
+
* `rawValue` (band/categorical) pass through unchanged — they have no numeric
|
|
132
|
+
* value to re-map.
|
|
133
|
+
*
|
|
134
|
+
* @param settledLayout - the axis layout produced at the timed animation's settled state
|
|
135
|
+
* @param intermediateScale - the scale at the current lerp frame (interpolated from prev to current)
|
|
136
|
+
* @returns an AxisLayoutInfo with the same ticks + labels, at new pixel positions
|
|
137
|
+
*/
|
|
138
|
+
declare function interpolateCartesianAxisLayout(settledLayout: AxisLayoutInfo, intermediateScale: LinearScale | BandScale): AxisLayoutInfo;
|
|
139
|
+
/**
|
|
140
|
+
* Create a "zero" radar layout for entrance animation — all points at center.
|
|
141
|
+
*/
|
|
142
|
+
declare function createRadarEntranceLayout(target: RadarRenderData): RadarRenderData;
|
|
143
|
+
/**
|
|
144
|
+
* Interpolate polar layout between two states (entrance or update animation).
|
|
145
|
+
* Matches bars by dataKey (from keyField) when available, otherwise by datasetId + category label.
|
|
146
|
+
*/
|
|
147
|
+
declare function interpolatePolarLayout(prev: PolarRenderData, target: PolarRenderData, progress: number): PolarRenderData;
|
|
148
|
+
/**
|
|
149
|
+
* Create a "zero" polar layout for entrance animation — all bars have zero height.
|
|
150
|
+
*/
|
|
151
|
+
declare function createPolarEntranceLayout(target: PolarRenderData): PolarRenderData;
|
|
152
|
+
|
|
153
|
+
/**
|
|
154
|
+
* Convert an AnimatableBar to the format expected by bar renderers (ComputedBar).
|
|
155
|
+
*/
|
|
156
|
+
declare function animatableBarToComputedBar(bar: AnimatableBar): {
|
|
157
|
+
dataIndex: number;
|
|
158
|
+
x: number;
|
|
159
|
+
y: number;
|
|
160
|
+
width: number;
|
|
161
|
+
height: number;
|
|
162
|
+
value: number;
|
|
163
|
+
category: string;
|
|
164
|
+
visible: boolean;
|
|
165
|
+
isNegative: boolean;
|
|
166
|
+
};
|
|
167
|
+
|
|
168
|
+
/**
|
|
169
|
+
* Exponential decay factor for axis opacity tweens.
|
|
170
|
+
*
|
|
171
|
+
* Tuned for 1 tick per frame (Step 9). Each tick advances opacity by
|
|
172
|
+
* `current += (target - current) * AXIS_SMOOTHING`.
|
|
173
|
+
*
|
|
174
|
+
* Visual fade speed equivalence:
|
|
175
|
+
* 1 tick at 0.225 ≈ 2 ticks at 0.12 (pre-Step-9 double-tick regime)
|
|
176
|
+
*
|
|
177
|
+
* Derivation: `(1 - 0.12)² = 0.7744` per frame → `1 - 0.7744 = 0.2256`,
|
|
178
|
+
* rounded to 0.225 for clean numerics. See Step 9 plan for context.
|
|
179
|
+
*/
|
|
180
|
+
declare const AXIS_SMOOTHING = 0.225;
|
|
181
|
+
/** Below this threshold, opacity is considered fully settled */
|
|
182
|
+
declare const AXIS_SETTLED_THRESHOLD = 0.005;
|
|
183
|
+
/**
|
|
184
|
+
* Manages smooth opacity transitions for axis show/hide.
|
|
185
|
+
*
|
|
186
|
+
* One plain {current, target} value per axis key. When an axis becomes hidden,
|
|
187
|
+
* opacity decays toward 0; when visible, toward 1.
|
|
188
|
+
*
|
|
189
|
+
* During fade-out (opacity > threshold but axis hidden), the visibleLayout
|
|
190
|
+
* is swapped in so ticks/line remain visible while fading.
|
|
191
|
+
*
|
|
192
|
+
* Framework wrappers hold this as a ref and delegate directly.
|
|
193
|
+
*/
|
|
194
|
+
declare class AxisTransitionState {
|
|
195
|
+
readonly opacities: Map<string, AxisOpacity>;
|
|
196
|
+
/**
|
|
197
|
+
* Per-axis per-tick opacities. Keyed by axisId, then by tick value
|
|
198
|
+
* (numeric `rawValue` for value axes, string `value` for category axes).
|
|
199
|
+
*
|
|
200
|
+
* Step 11 extension. Populated by `setTickTargets`, advanced by `tick`,
|
|
201
|
+
* read by `applyTicks`. When no entry exists for an axis, `applyTicks`
|
|
202
|
+
* passes ticks through unchanged so existing axes (no per-tick lerp)
|
|
203
|
+
* keep their current behavior.
|
|
204
|
+
*/
|
|
205
|
+
readonly tickOpacities: Map<string, Map<string | number, AxisOpacity>>;
|
|
206
|
+
/**
|
|
207
|
+
* Per-axis rotation interpolation state. Populated by `setRotationTargets`,
|
|
208
|
+
* advanced by `tick`, read by `applyRotations`.
|
|
209
|
+
*
|
|
210
|
+
* Step 11 extension. Reuses `AxisOpacity` shape (`{ current, target }`)
|
|
211
|
+
* since the math is identical — exponential decay at `AXIS_SMOOTHING`.
|
|
212
|
+
*/
|
|
213
|
+
readonly rotations: Map<string, AxisOpacity>;
|
|
214
|
+
/**
|
|
215
|
+
* Set opacity targets from axis layout isHidden flags.
|
|
216
|
+
* Call this whenever layoutData changes.
|
|
217
|
+
*/
|
|
218
|
+
setTargets(axisLayouts: Map<string, AxisLayoutInfo$1>): void;
|
|
219
|
+
/**
|
|
220
|
+
* Advance all opacity values by one frame using exponential decay.
|
|
221
|
+
* Covers axis-level opacities, per-tick opacities, and per-axis rotations.
|
|
222
|
+
* Returns true if any value is still animating.
|
|
223
|
+
*
|
|
224
|
+
* Per-tick cleanup: an exiting tick (target = 0) that has settled is
|
|
225
|
+
* REMOVED from the per-axis map. This keeps the map size bounded across
|
|
226
|
+
* many domain lerps. Continuing/entering ticks (target = 1) simply snap.
|
|
227
|
+
*/
|
|
228
|
+
tick(): boolean;
|
|
229
|
+
/**
|
|
230
|
+
* Apply animated opacity to axis layouts.
|
|
231
|
+
*
|
|
232
|
+
* - Hidden axis with opacity > threshold: swap in visibleLayout with opacity (fade-out in progress)
|
|
233
|
+
* - Hidden axis settled at 0: use hidden layout as-is (fully invisible)
|
|
234
|
+
* - Visible axis: use layout with current opacity (handles fade-in)
|
|
235
|
+
*/
|
|
236
|
+
apply(axisLayouts: Map<string, AxisLayoutInfo$1>): Map<string, AxisLayoutInfo$1>;
|
|
237
|
+
/**
|
|
238
|
+
* Set per-tick opacity targets for one axis from an enter/exit/continuing
|
|
239
|
+
* categorization. Idempotent within a frame — call once per domain lerp init.
|
|
240
|
+
*
|
|
241
|
+
* - Entering tick (new): target = 1, current = 0 if no prior entry exists
|
|
242
|
+
* (animates IN). If a prior entry exists, keep current as-is to handle
|
|
243
|
+
* rapid toggling without snapping.
|
|
244
|
+
* - Exiting tick (removed): target = 0, current = whatever it was last
|
|
245
|
+
* (animates OUT). If no prior entry exists, assume it was visible —
|
|
246
|
+
* start at 1.
|
|
247
|
+
* - Continuing tick (in both start + target): snap to current = target = 1.
|
|
248
|
+
* No animation needed; position lerp via `interpolateCartesianAxisLayout`
|
|
249
|
+
* covers the visible motion.
|
|
250
|
+
*
|
|
251
|
+
* Any tick previously tracked for this axis but NOT in the new `ticks`
|
|
252
|
+
* list is snapped to target 0 (cleanup — no longer part of the lerp).
|
|
253
|
+
* `tick()` will drop it once it settles.
|
|
254
|
+
*/
|
|
255
|
+
setTickTargets(axisId: string, ticks: {
|
|
256
|
+
value: number | string;
|
|
257
|
+
isEntering: boolean;
|
|
258
|
+
isExiting: boolean;
|
|
259
|
+
}[]): void;
|
|
260
|
+
/**
|
|
261
|
+
* Apply animated per-tick opacities to a tick array. Returns the same
|
|
262
|
+
* array with each tick's `opacity` field set from the internal state.
|
|
263
|
+
*
|
|
264
|
+
* - Axis has no per-tick lerp entry: return ticks unchanged (preserves
|
|
265
|
+
* existing behavior for axes that don't participate in tick fade).
|
|
266
|
+
* - Tick value not in the per-axis map: pass through with opacity 1.
|
|
267
|
+
*/
|
|
268
|
+
applyTicks(axisId: string, ticks: ComputedTick[]): ComputedTick[];
|
|
269
|
+
/**
|
|
270
|
+
* Probe: does this axis still have a per-tick entry for `value`? Returns
|
|
271
|
+
* false once `tick()` has cleaned up a settled exiting entry. Callers
|
|
272
|
+
* (e.g. `advanceDomainLerp`'s exiting-tick merge) use it to decide
|
|
273
|
+
* whether to keep synthesizing a faded-out tick or drop it entirely.
|
|
274
|
+
*/
|
|
275
|
+
hasTickEntry(axisId: string, value: number | string): boolean;
|
|
276
|
+
/**
|
|
277
|
+
* Set the target rotation angle (radians or degrees — caller-defined) for
|
|
278
|
+
* one axis. Step 11 extension.
|
|
279
|
+
*
|
|
280
|
+
* - First call for an axis with no `currentAngle`: snap current to target
|
|
281
|
+
* (no initial animation — there's nothing to animate FROM).
|
|
282
|
+
* - First call with `currentAngle` provided: initialize current to that
|
|
283
|
+
* angle so the first lerp animates from layout-resolved rotation to
|
|
284
|
+
* the new target.
|
|
285
|
+
* - Subsequent calls: leave `current` alone (state machine already knows
|
|
286
|
+
* where the visible angle is); only re-target.
|
|
287
|
+
*/
|
|
288
|
+
setRotationTargets(axisId: string, targetAngle: number, currentAngle?: number): void;
|
|
289
|
+
/**
|
|
290
|
+
* Return the interpolated rotation angle for an axis, or `fallback` when
|
|
291
|
+
* no entry exists. Use the renderer-resolved rotation as the fallback so
|
|
292
|
+
* axes with no active rotation lerp stay at whatever `calculateAxisLayout`
|
|
293
|
+
* resolved for them.
|
|
294
|
+
*/
|
|
295
|
+
applyRotations(axisId: string, fallback: number): number;
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
declare class AnimationRegistry implements AnimationRegistryLike {
|
|
299
|
+
private entries;
|
|
300
|
+
private rafId;
|
|
301
|
+
private onRepaint;
|
|
302
|
+
private ticking;
|
|
303
|
+
/** True when the scheduler calls tick synchronously (detected on first raf call). Tests only. */
|
|
304
|
+
private _isSyncScheduler;
|
|
305
|
+
/** Set to true just before calling raf(); if tick fires while this is true, scheduler is sync. */
|
|
306
|
+
private _detectingSync;
|
|
307
|
+
/**
|
|
308
|
+
* Set the repaint callback. Called after all entries are ticked each frame.
|
|
309
|
+
* Typically triggers a full canvas clear + redraw.
|
|
310
|
+
*/
|
|
311
|
+
setRepaintCallback(callback: () => void): void;
|
|
312
|
+
/**
|
|
313
|
+
* Register a new animation. If an animation with the same ID exists,
|
|
314
|
+
* it is replaced (restarted). Returns an unregister function.
|
|
315
|
+
*/
|
|
316
|
+
register(config: AnimationEntryConfig): () => void;
|
|
317
|
+
/**
|
|
318
|
+
* Unregister an animation by ID.
|
|
319
|
+
*/
|
|
320
|
+
unregister(id: string): void;
|
|
321
|
+
/**
|
|
322
|
+
* Check if an animation with the given ID is active.
|
|
323
|
+
*/
|
|
324
|
+
has(id: string): boolean;
|
|
325
|
+
/**
|
|
326
|
+
* Get the current interpolated value for an animation.
|
|
327
|
+
* Returns undefined if the animation is not registered.
|
|
328
|
+
*/
|
|
329
|
+
getValue(id: string): number | undefined;
|
|
330
|
+
/**
|
|
331
|
+
* Get snapshots of all active animations.
|
|
332
|
+
*/
|
|
333
|
+
getSnapshots(): AnimationSnapshot[];
|
|
334
|
+
/**
|
|
335
|
+
* Number of active animations.
|
|
336
|
+
*/
|
|
337
|
+
get size(): number;
|
|
338
|
+
/**
|
|
339
|
+
* Stop all animations and cancel the RAF loop.
|
|
340
|
+
*/
|
|
341
|
+
clear(): void;
|
|
342
|
+
/**
|
|
343
|
+
* Full cleanup — clear all animations and remove the repaint callback.
|
|
344
|
+
*/
|
|
345
|
+
destroy(): void;
|
|
346
|
+
/**
|
|
347
|
+
* Persistent bound tick function. Using a class arrow ensures the same
|
|
348
|
+
* reference is passed to every raf() call, which enables auto-rescheduling
|
|
349
|
+
* from within the tick body for async (browser) schedulers.
|
|
350
|
+
*/
|
|
351
|
+
private boundTick;
|
|
352
|
+
private ensureLoop;
|
|
353
|
+
private stopLoop;
|
|
354
|
+
}
|
|
355
|
+
|
|
356
|
+
/**
|
|
357
|
+
* Compute a 2D transform that interpolates content from one rect to another.
|
|
358
|
+
*
|
|
359
|
+
* The content is laid out in `target` coordinates. At progress=0 it appears
|
|
360
|
+
* squeezed into `origin`; at progress=1 it fills `target` at identity scale.
|
|
361
|
+
*
|
|
362
|
+
* @param origin - The starting rect (e.g. clicked cell bounds)
|
|
363
|
+
* @param target - The destination rect (e.g. full chart area)
|
|
364
|
+
* @param progress - Animation progress 0→1
|
|
365
|
+
*/
|
|
366
|
+
declare function computeZoomTransform(origin: BoxArea, target: BoxArea, progress: number): ZoomTransform;
|
|
367
|
+
/**
|
|
368
|
+
* Compute a centered shrink rect for drill-out animation.
|
|
369
|
+
* Returns a rect inset by `ratio` from each side of the given area.
|
|
370
|
+
*
|
|
371
|
+
* @param area - The chart area to shrink from
|
|
372
|
+
* @param ratio - How much to shrink (0.25 = 25% inset from each side → 50% size)
|
|
373
|
+
*/
|
|
374
|
+
declare function computeDrillOutOrigin(area: BoxArea, ratio?: number): BoxArea;
|
|
375
|
+
|
|
376
|
+
/**
|
|
377
|
+
* Build a stable fingerprint of the heatmap layouts (non-empty cells, keyed by
|
|
378
|
+
* xLabel|yLabel:value) so the controller can detect data changes between updates.
|
|
379
|
+
*/
|
|
380
|
+
declare function buildHeatmapFingerprint(layouts: Map<string, HeatmapRenderData>): string;
|
|
381
|
+
|
|
382
|
+
/**
|
|
383
|
+
* Build a fingerprint string from candlestick layouts for phase detection.
|
|
384
|
+
* Trades precision for speed — see spec Risks for the known limitation
|
|
385
|
+
* (a middle-candle OHLC change with stable count / edges / y-extremes won't fire).
|
|
386
|
+
*/
|
|
387
|
+
declare function buildCandlestickFingerprint(layouts: Map<string, CandlestickRenderData>): string;
|
|
388
|
+
|
|
389
|
+
/**
|
|
390
|
+
* Detect the type of data change for a single series.
|
|
391
|
+
*
|
|
392
|
+
* - `'append'`: one new point added at the end, existing values unchanged
|
|
393
|
+
* - `'scroll'`: rolling shift — same length, values shifted by one position
|
|
394
|
+
* - `'update'`: general value change (needs full value lerp)
|
|
395
|
+
*
|
|
396
|
+
* Used to choose the right animation strategy:
|
|
397
|
+
* - append → extend clip path to reveal new point
|
|
398
|
+
* - scroll → tip-extension + time-domain lerp together
|
|
399
|
+
* - update → per-point value interpolation
|
|
400
|
+
*/
|
|
401
|
+
declare function detectLineUpdateKind(startVals: number[] | undefined, targetVals: number[]): LineUpdateKind;
|
|
402
|
+
/**
|
|
403
|
+
* Build a fingerprint from line layouts for animation phase detection.
|
|
404
|
+
* Includes dataset IDs + point values to detect data changes.
|
|
405
|
+
*
|
|
406
|
+
* Used by the orchestrator's `detect(fingerprint)` to classify:
|
|
407
|
+
* same fingerprint → static (skip animation), different → update.
|
|
408
|
+
*/
|
|
409
|
+
declare function buildLineFingerprint(layouts: Map<string, LineRenderData>): string;
|
|
410
|
+
|
|
411
|
+
type Phase = 'idle' | 'enter' | 'update' | 'exit';
|
|
412
|
+
declare class AnimatedElement<T> implements AnimatedElementLike<T> {
|
|
413
|
+
readonly id: string;
|
|
414
|
+
current: T;
|
|
415
|
+
target: T;
|
|
416
|
+
phase: Phase;
|
|
417
|
+
private readonly tweens;
|
|
418
|
+
private readonly overrides;
|
|
419
|
+
private readonly registry;
|
|
420
|
+
/** Most recent PerGroupOptions — retained so releaseOverride can restart tweens. */
|
|
421
|
+
private _lastOpts;
|
|
422
|
+
/** Set to true when exit() completes, signalling scene to remove this element. */
|
|
423
|
+
private _readyForRemoval;
|
|
424
|
+
constructor(id: string, initial: T, registry: AnimatableRegistry);
|
|
425
|
+
/**
|
|
426
|
+
* Target-write path. For each changed field in newTarget:
|
|
427
|
+
* - if overridden: target is updated but no tween starts
|
|
428
|
+
* - otherwise: tween captures current[field] as start, animates over the group's duration
|
|
429
|
+
*/
|
|
430
|
+
setTarget(newTarget: Partial<T>, opts: PerGroupOptions): void;
|
|
431
|
+
/** Direct-write path for explicit looping animations. */
|
|
432
|
+
overrideCurrent<K extends keyof T>(prop: K, value: T[K]): void;
|
|
433
|
+
/** Release the override; tween (if any) resumes toward latest target. */
|
|
434
|
+
releaseOverride<K extends keyof T>(prop: K): void;
|
|
435
|
+
/** Enter animation: emptyState → target. */
|
|
436
|
+
enter(target: T, emptyState: T, opts: PerGroupOptions): void;
|
|
437
|
+
/** Exit animation: current → emptyState. After tick completes, marks ready for removal. */
|
|
438
|
+
exit(emptyState: T, opts: PerGroupOptions): void;
|
|
439
|
+
/** Advance one frame. Returns true if any property is still tweening. */
|
|
440
|
+
tick(now: number): boolean;
|
|
441
|
+
/** True if exit() has completed and this element should be removed from the scene. */
|
|
442
|
+
isReadyForRemoval(): boolean;
|
|
443
|
+
/**
|
|
444
|
+
* Cancel an in-progress exit. Called by AnimatedScene when an exit-phase element
|
|
445
|
+
* reappears in targets (e.g. quick legend toggle off → on).
|
|
446
|
+
*/
|
|
447
|
+
resurrect(): void;
|
|
448
|
+
private _groupOptsFor;
|
|
449
|
+
}
|
|
450
|
+
|
|
451
|
+
interface AnimatedSceneOptions<T> {
|
|
452
|
+
emptyState: (target: T) => T;
|
|
453
|
+
/**
|
|
454
|
+
* Optional separate state used for exit animations. When provided, exiting elements
|
|
455
|
+
* animate toward this state instead of `emptyState`. Useful when enter and exit
|
|
456
|
+
* should behave differently — e.g. pie slices enter from the chart start angle but
|
|
457
|
+
* exit by shrinking to zero span at their own position.
|
|
458
|
+
*/
|
|
459
|
+
exitEmptyState?: (target: T) => T;
|
|
460
|
+
registry: AnimatableRegistry;
|
|
461
|
+
/** Default: true. When OS sets prefers-reduced-motion, snap to target instead of tweening. */
|
|
462
|
+
respectReducedMotion?: boolean;
|
|
463
|
+
}
|
|
464
|
+
declare class AnimatedScene<T> {
|
|
465
|
+
private readonly elements;
|
|
466
|
+
private readonly activeElements;
|
|
467
|
+
private readonly emptyState;
|
|
468
|
+
private readonly exitEmptyState;
|
|
469
|
+
private readonly registry;
|
|
470
|
+
private readonly reducedMotion;
|
|
471
|
+
constructor(opts: AnimatedSceneOptions<T>);
|
|
472
|
+
/**
|
|
473
|
+
* D3-style data join. For each id in `targets`:
|
|
474
|
+
* - not in scene → create element, enter from emptyState
|
|
475
|
+
* - already in scene → setTarget (interrupts any in-flight tween)
|
|
476
|
+
* For each id in scene but not in targets:
|
|
477
|
+
* - exit toward emptyState; pruned by tick() after completion
|
|
478
|
+
*/
|
|
479
|
+
diff(targets: Map<string, T>, opts: PerGroupOptions): void;
|
|
480
|
+
/**
|
|
481
|
+
* Advance all active elements one frame. Auto-removes elements whose
|
|
482
|
+
* exit animation has completed.
|
|
483
|
+
*/
|
|
484
|
+
tick(now: number): {
|
|
485
|
+
allIdle: boolean;
|
|
486
|
+
};
|
|
487
|
+
getElements(): ReadonlyArray<AnimatedElement<T>>;
|
|
488
|
+
getElement(id: string): AnimatedElement<T> | undefined;
|
|
489
|
+
/** Clear all elements. Used by StrictMode reset / unmount. */
|
|
490
|
+
reset(): void;
|
|
491
|
+
private _zeroDurationOpts;
|
|
492
|
+
}
|
|
493
|
+
|
|
494
|
+
declare class CanvasCompositor implements CanvasCompositorLike {
|
|
495
|
+
private _layers;
|
|
496
|
+
private _sortedLayers;
|
|
497
|
+
private _sortDirty;
|
|
498
|
+
private _bgPainter;
|
|
499
|
+
private _fgPainter;
|
|
500
|
+
/**
|
|
501
|
+
* Register a canvas paint layer (e.g., bar, line, scatter).
|
|
502
|
+
* Layers are painted in `order` between background and foreground.
|
|
503
|
+
* Safe to call multiple times — replaces previous layer with same id.
|
|
504
|
+
*/
|
|
505
|
+
registerLayer(layer: CanvasLayer): void;
|
|
506
|
+
/** Remove a canvas paint layer by id. */
|
|
507
|
+
removeLayer(id: string): void;
|
|
508
|
+
/**
|
|
509
|
+
* Remove all canvas paint layers whose id starts with the given prefix.
|
|
510
|
+
* Used for per-dataset cleanup (e.g., removeLayersByPrefix('bar:')).
|
|
511
|
+
*/
|
|
512
|
+
removeLayersByPrefix(prefix: string): void;
|
|
513
|
+
/** Check if a layer is registered. */
|
|
514
|
+
hasLayer(id: string): boolean;
|
|
515
|
+
/** Check if compositor has any layers registered. */
|
|
516
|
+
hasLayers(): boolean;
|
|
517
|
+
/** Set the background painter (grid, fills, beforeData references, zoom clip). */
|
|
518
|
+
setBackground(painter: CanvasPainter | null): void;
|
|
519
|
+
/** Set the foreground painter (afterData references, axes, brackets, annotations). */
|
|
520
|
+
setForeground(painter: CanvasPainter | null): void;
|
|
521
|
+
/**
|
|
522
|
+
* Repaint the entire canvas in correct z-order:
|
|
523
|
+
* 1. Clear
|
|
524
|
+
* 2. Background
|
|
525
|
+
* 3. Data layers sorted by order
|
|
526
|
+
* 4. Foreground
|
|
527
|
+
* All painting is synchronous within this call (no interleaved repaints).
|
|
528
|
+
*/
|
|
529
|
+
repaint(ctx: CanvasRenderingContext2D): void;
|
|
530
|
+
}
|
|
531
|
+
|
|
532
|
+
interface FrameSchedulerAPI {
|
|
533
|
+
raf(callback: FrameRequestCallback): number;
|
|
534
|
+
cancelRaf(id: number): void;
|
|
535
|
+
}
|
|
536
|
+
/**
|
|
537
|
+
* Override the RAF scheduler.
|
|
538
|
+
* Call this to inject a no-op for SSR, a synchronous scheduler for tests,
|
|
539
|
+
* or a priority-aware scheduler for framework integration.
|
|
540
|
+
*
|
|
541
|
+
* @example
|
|
542
|
+
* // SSR / Node: no-op animations
|
|
543
|
+
* setFrameScheduler({ raf: () => 0, cancelRaf: () => {} });
|
|
544
|
+
*
|
|
545
|
+
* // Tests: synchronous, deterministic frames
|
|
546
|
+
* setFrameScheduler({ raf: (cb) => { cb(0); return 0; }, cancelRaf: () => {} });
|
|
547
|
+
*
|
|
548
|
+
* // Reset to browser default
|
|
549
|
+
* setFrameScheduler(null);
|
|
550
|
+
*/
|
|
551
|
+
declare function setFrameScheduler(api: FrameSchedulerAPI | null): void;
|
|
552
|
+
|
|
553
|
+
declare const LINE_ANIMATABLE_PROPS: AnimatableRegistry;
|
|
554
|
+
declare const BAR_ANIMATABLE_PROPS: AnimatableRegistry;
|
|
555
|
+
declare function setupPropertyAnimations(configs: PropertyAnimationConfig[], registry: AnimationRegistry, store: AnimatedPropertyStoreLike,
|
|
556
|
+
/**
|
|
557
|
+
* Called when a non-looping property animation completes. The store entry
|
|
558
|
+
* is already deleted before this fires. Framework wrappers use this to
|
|
559
|
+
* trigger `renderFrameCycle()` on each controller, restoring base SVG
|
|
560
|
+
* attribute values that drifted during in-place property patching.
|
|
561
|
+
*/
|
|
562
|
+
onPropertyComplete?: (storeKey: string) => void): () => void;
|
|
563
|
+
declare function resolveAnimatedProps(store: AnimatedPropertyStoreLike, chartType: string, datasetId: string, registry: AnimatableRegistry | readonly string[]): Record<string, number>;
|
|
564
|
+
/**
|
|
565
|
+
* Flatten the public `animations: { name: { properties: [...], ... } }` map shape
|
|
566
|
+
* into the existing internal `PropertyAnimationConfig[]` array.
|
|
567
|
+
*
|
|
568
|
+
* Each entry in `properties` produces one config row, sharing the entry's
|
|
569
|
+
* timing/from/to/loop/alternate/easing/delay values.
|
|
570
|
+
*
|
|
571
|
+
* `scope` attaches `datasetId` (for per-dataset entries) or `chartType` (when
|
|
572
|
+
* the caller wants to scope a chart-level entry to a chart kind, though
|
|
573
|
+
* Phase 1a does not use the chartType path).
|
|
574
|
+
*/
|
|
575
|
+
declare function normalizeAnimationsMap(map: Record<string, NamedAnimationSpec> | undefined, scope?: {
|
|
576
|
+
datasetId?: string;
|
|
577
|
+
chartType?: 'line' | 'bar';
|
|
578
|
+
}): PropertyAnimationConfig[];
|
|
579
|
+
|
|
580
|
+
export { AXIS_SETTLED_THRESHOLD as A, BAR_ANIMATABLE_PROPS as B, CanvasCompositor as C, easings as D, getEasing as E, type FrameSchedulerAPI as F, getEasingNames as G, hasEasing as H, interpolateCartesianAxisLayout as I, interpolatePolarLayout as J, interpolateRadialGrid as K, LINE_ANIMATABLE_PROPS as L, lerp as M, lerpColor as N, lerpValues as O, linear as P, normalizeAnimationsMap as Q, registerEasing as R, resolveAnimatedProps as S, setFrameScheduler as T, setupPropertyAnimations as U, AXIS_SMOOTHING as a, AnimatedElement as b, AnimatedScene as c, AnimationRegistry as d, AxisTransitionState as e, animatableBarToComputedBar as f, buildCandlestickFingerprint as g, buildHeatmapFingerprint as h, buildLineFingerprint as i, computeDrillOutOrigin as j, computeZoomTransform as k, createPolarEntranceLayout as l, createRadarEntranceLayout as m, detectLineUpdateKind as n, easeInBounce as o, easeInOutBounce as p, easeInOutCubic as q, easeInOutQuart as r, easeOutBack as s, easeOutBounce as t, easeOutCubic as u, easeOutElastic as v, easeOutExpo as w, easeOutQuad as x, easeOutQuart as y, easeOutQuint as z };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { AnimatedPropertyStoreLike } from '@primeui/chart-types';
|
|
2
|
+
|
|
3
|
+
declare class AnimatedPropertyStore implements AnimatedPropertyStoreLike {
|
|
4
|
+
private values;
|
|
5
|
+
set(key: string, value: number): void;
|
|
6
|
+
get(key: string): number | undefined;
|
|
7
|
+
/**
|
|
8
|
+
* Remove a single key. Called by `setupPropertyAnimations`' `onComplete`
|
|
9
|
+
* hook so a finished animation stops contributing an override value.
|
|
10
|
+
* Returns true if the key existed.
|
|
11
|
+
*/
|
|
12
|
+
delete(key: string): boolean;
|
|
13
|
+
clear(): void;
|
|
14
|
+
destroy(): void;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export { AnimatedPropertyStore as A };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { PolarBarData, Point, DataLabelConfig, ResolvedLabel, RadarPoint } from '@primeui/chart-types';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Resolve data labels for polar bar segments.
|
|
5
|
+
* Labels are positioned radially outward from the bar's outer edge at its mid-angle.
|
|
6
|
+
*/
|
|
7
|
+
declare function resolvePolarLabels(bars: PolarBarData[], datasetTotal: number, center: Point, config: DataLabelConfig, data?: unknown[]): ResolvedLabel[];
|
|
8
|
+
/**
|
|
9
|
+
* Resolve data labels for radar vertex points.
|
|
10
|
+
* Labels are positioned slightly outward from each data point along the spoke direction.
|
|
11
|
+
*/
|
|
12
|
+
declare function resolveRadarLabels(points: RadarPoint[], categories: string[], seriesColor: string, datasetTotal: number, center: Point, config: DataLabelConfig, data?: unknown[]): ResolvedLabel[];
|
|
13
|
+
|
|
14
|
+
export { resolvePolarLabels, resolveRadarLabels };
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import '../chunk-WS64BZXT.mjs';
|
|
2
|
+
export { resolvePolarLabels, resolveRadarLabels } from '../chunk-UPRXABX5.mjs';
|
|
3
|
+
import '../chunk-66T4MRC5.mjs';
|
|
4
|
+
import '../chunk-7QQ6ETB4.mjs';
|
|
5
|
+
import '../chunk-X7T34OLW.mjs';
|
|
6
|
+
import '../chunk-SALTGZFR.mjs';
|
|
7
|
+
import '../chunk-AUF4CHDP.mjs';
|
|
8
|
+
import '../chunk-VGLSBZDN.mjs';
|
|
9
|
+
import '../chunk-ZT2Z7ERM.mjs';
|
|
10
|
+
import '../chunk-KP2TWD4Z.mjs';
|
|
11
|
+
import '../chunk-3WEMHXZI.mjs';
|
|
12
|
+
import '../chunk-KVDEROP6.mjs';
|
|
13
|
+
import '../chunk-YBJ56XJS.mjs';
|
|
14
|
+
import '../chunk-NPDZLYIF.mjs';
|
|
15
|
+
import '../chunk-EDAKJLNA.mjs';
|
|
16
|
+
import '../chunk-JWFBOPM6.mjs';
|
|
17
|
+
import '../chunk-5JCI2DEB.mjs';
|
|
18
|
+
import '../chunk-BZN2QHGP.mjs';
|
|
19
|
+
import '../chunk-OGJ6IIBW.mjs';
|
|
20
|
+
import '../chunk-ARRGOEFX.mjs';
|
|
21
|
+
import '../chunk-22ST6YPP.mjs';
|
|
22
|
+
import '../chunk-FFMT6OCO.mjs';
|
|
23
|
+
import '../chunk-7CMVDIOU.mjs';
|
|
24
|
+
import '../chunk-ADKLH73T.mjs';
|
|
25
|
+
import '../chunk-OXTFAWSK.mjs';
|
|
26
|
+
import '../chunk-R6Y3R7EW.mjs';
|
|
27
|
+
import '../chunk-XTVE4P3L.mjs';
|
|
28
|
+
import '../chunk-NKUYIWAP.mjs';
|
|
29
|
+
import '../chunk-OWW3K55O.mjs';
|
|
30
|
+
import '../chunk-WA3OVISZ.mjs';
|
|
31
|
+
import '../chunk-C36VWQ7A.mjs';
|
|
32
|
+
import '../chunk-BETFQBM2.mjs';
|
|
33
|
+
import '../chunk-WRULPWHD.mjs';
|
|
34
|
+
import '../chunk-QS76E3TD.mjs';
|
|
35
|
+
import '../chunk-O2X6FF45.mjs';
|
|
36
|
+
import '../chunk-SSLTFJ3U.mjs';
|
|
37
|
+
import '../chunk-RQ3CKQOX.mjs';
|