@tabler/charts 0.0.0-stage → 0.0.1-alpha.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 (324) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +248 -2
  3. package/dist/annotations-Bp7HwtF5.d.ts +86 -0
  4. package/dist/annotations-BszTTjf9.js +202 -0
  5. package/dist/annotations-BszTTjf9.js.map +1 -0
  6. package/dist/annotations-DpETO8dE.cjs +213 -0
  7. package/dist/annotations-DpETO8dE.cjs.map +1 -0
  8. package/dist/annotations-lyt0I3HU.d.cts +86 -0
  9. package/dist/annotations.cjs +14 -0
  10. package/dist/annotations.cjs.map +1 -0
  11. package/dist/annotations.d.cts +2 -0
  12. package/dist/annotations.d.ts +2 -0
  13. package/dist/annotations.js +12 -0
  14. package/dist/annotations.js.map +1 -0
  15. package/dist/area-BFvkc-ZM.d.cts +20 -0
  16. package/dist/area-DQsLERhx.js +26 -0
  17. package/dist/area-DQsLERhx.js.map +1 -0
  18. package/dist/area-DaO4MQl4.d.ts +20 -0
  19. package/dist/area-sHCE3pg5.cjs +31 -0
  20. package/dist/area-sHCE3pg5.cjs.map +1 -0
  21. package/dist/area.cjs +3 -0
  22. package/dist/area.d.cts +2 -0
  23. package/dist/area.d.ts +2 -0
  24. package/dist/area.js +2 -0
  25. package/dist/band-DTcNDAFO.d.cts +50 -0
  26. package/dist/band-DTcNDAFO.d.ts +50 -0
  27. package/dist/bar-C-7zR2qp.cjs +243 -0
  28. package/dist/bar-C-7zR2qp.cjs.map +1 -0
  29. package/dist/bar-DGuUN3nc.cjs +67 -0
  30. package/dist/bar-DGuUN3nc.cjs.map +1 -0
  31. package/dist/bar-DM16NUvV.js +56 -0
  32. package/dist/bar-DM16NUvV.js.map +1 -0
  33. package/dist/bar-DdsDxk3W.d.ts +43 -0
  34. package/dist/bar-a0h9KC8A.d.cts +43 -0
  35. package/dist/bar-jZEoao74.js +238 -0
  36. package/dist/bar-jZEoao74.js.map +1 -0
  37. package/dist/bar.cjs +3 -0
  38. package/dist/bar.d.cts +2 -0
  39. package/dist/bar.d.ts +2 -0
  40. package/dist/bar.js +2 -0
  41. package/dist/candlestick-B5r1w3kc.cjs +150 -0
  42. package/dist/candlestick-B5r1w3kc.cjs.map +1 -0
  43. package/dist/candlestick-BKdPyorY.d.cts +44 -0
  44. package/dist/candlestick-BnUG1SGi.d.ts +44 -0
  45. package/dist/candlestick-DuXwAFID.js +145 -0
  46. package/dist/candlestick-DuXwAFID.js.map +1 -0
  47. package/dist/candlestick.cjs +11 -0
  48. package/dist/candlestick.cjs.map +1 -0
  49. package/dist/candlestick.d.cts +2 -0
  50. package/dist/candlestick.d.ts +2 -0
  51. package/dist/candlestick.js +10 -0
  52. package/dist/candlestick.js.map +1 -0
  53. package/dist/cartesian-BoDfgBCV.cjs +900 -0
  54. package/dist/cartesian-BoDfgBCV.cjs.map +1 -0
  55. package/dist/cartesian-Cr0AF0nG.js +709 -0
  56. package/dist/cartesian-Cr0AF0nG.js.map +1 -0
  57. package/dist/chart-BF2CK9I_.js +790 -0
  58. package/dist/chart-BF2CK9I_.js.map +1 -0
  59. package/dist/chart-CowF_lWY.cjs +903 -0
  60. package/dist/chart-CowF_lWY.cjs.map +1 -0
  61. package/dist/chart-Qa417fJo.d.cts +927 -0
  62. package/dist/chart-iJGxMz9z.d.ts +927 -0
  63. package/dist/circle-BQMuAfls.cjs +12 -0
  64. package/dist/circle-BQMuAfls.cjs.map +1 -0
  65. package/dist/circle-Z7YfCoCM.js +7 -0
  66. package/dist/circle-Z7YfCoCM.js.map +1 -0
  67. package/dist/clean-Byl6kzf0.cjs +115 -0
  68. package/dist/clean-Byl6kzf0.cjs.map +1 -0
  69. package/dist/clean-o1vDEhFV.js +56 -0
  70. package/dist/clean-o1vDEhFV.js.map +1 -0
  71. package/dist/core-C7fPm6t7.cjs +976 -0
  72. package/dist/core-C7fPm6t7.cjs.map +1 -0
  73. package/dist/core-CjgbhS_v.d.ts +219 -0
  74. package/dist/core-CnGFKojH.d.cts +219 -0
  75. package/dist/core-plobgBC7.js +875 -0
  76. package/dist/core-plobgBC7.js.map +1 -0
  77. package/dist/core.cjs +113 -0
  78. package/dist/core.d.cts +20 -0
  79. package/dist/core.d.ts +20 -0
  80. package/dist/core.js +24 -0
  81. package/dist/dates-Btm7Zm6W.cjs +32 -0
  82. package/dist/dates-Btm7Zm6W.cjs.map +1 -0
  83. package/dist/dates-CG-FvioW.js +27 -0
  84. package/dist/dates-CG-FvioW.js.map +1 -0
  85. package/dist/decimate-BGg9XgF0.d.ts +17 -0
  86. package/dist/decimate-C87cl_Sp.js +84 -0
  87. package/dist/decimate-C87cl_Sp.js.map +1 -0
  88. package/dist/decimate-CNSpgGa5.d.cts +17 -0
  89. package/dist/decimate-tLhDk1ys.cjs +95 -0
  90. package/dist/decimate-tLhDk1ys.cjs.map +1 -0
  91. package/dist/decimate.cjs +14 -0
  92. package/dist/decimate.cjs.map +1 -0
  93. package/dist/decimate.d.cts +2 -0
  94. package/dist/decimate.d.ts +2 -0
  95. package/dist/decimate.js +12 -0
  96. package/dist/decimate.js.map +1 -0
  97. package/dist/dom-CLF868Qs.cjs +222 -0
  98. package/dist/dom-CLF868Qs.cjs.map +1 -0
  99. package/dist/dom-vP3IcMak.js +175 -0
  100. package/dist/dom-vP3IcMak.js.map +1 -0
  101. package/dist/export-chart-9w8t3rjZ.js +232 -0
  102. package/dist/export-chart-9w8t3rjZ.js.map +1 -0
  103. package/dist/export-chart-BhhYgksr.cjs +249 -0
  104. package/dist/export-chart-BhhYgksr.cjs.map +1 -0
  105. package/dist/export.cjs +18 -0
  106. package/dist/export.cjs.map +1 -0
  107. package/dist/export.d.cts +2 -0
  108. package/dist/export.d.ts +2 -0
  109. package/dist/export.js +15 -0
  110. package/dist/export.js.map +1 -0
  111. package/dist/extent-BAMZo0Nq.js +19 -0
  112. package/dist/extent-BAMZo0Nq.js.map +1 -0
  113. package/dist/extent-DsFWvAHJ.cjs +24 -0
  114. package/dist/extent-DsFWvAHJ.cjs.map +1 -0
  115. package/dist/fade-Cs74puQS.cjs +217 -0
  116. package/dist/fade-Cs74puQS.cjs.map +1 -0
  117. package/dist/fade-D3NxH5Qg.js +200 -0
  118. package/dist/fade-D3NxH5Qg.js.map +1 -0
  119. package/dist/features-BclHgg2W.cjs +48 -0
  120. package/dist/features-BclHgg2W.cjs.map +1 -0
  121. package/dist/features-wASyHGic.js +25 -0
  122. package/dist/features-wASyHGic.js.map +1 -0
  123. package/dist/format-B0yKXBTH.cjs +183 -0
  124. package/dist/format-B0yKXBTH.cjs.map +1 -0
  125. package/dist/format-lStwuc1L.js +142 -0
  126. package/dist/format-lStwuc1L.js.map +1 -0
  127. package/dist/gauge-CEfkWXSu.cjs +235 -0
  128. package/dist/gauge-CEfkWXSu.cjs.map +1 -0
  129. package/dist/gauge-Cu9jttC0.d.ts +65 -0
  130. package/dist/gauge-Cu_OFxBd.d.cts +65 -0
  131. package/dist/gauge-_ljQHrMN.js +230 -0
  132. package/dist/gauge-_ljQHrMN.js.map +1 -0
  133. package/dist/gauge.cjs +3 -0
  134. package/dist/gauge.d.cts +2 -0
  135. package/dist/gauge.d.ts +2 -0
  136. package/dist/gauge.js +2 -0
  137. package/dist/heatmap-BK18EBgJ.cjs +247 -0
  138. package/dist/heatmap-BK18EBgJ.cjs.map +1 -0
  139. package/dist/heatmap-BwS-y0c6.d.cts +81 -0
  140. package/dist/heatmap-DSZ2bVIa.js +242 -0
  141. package/dist/heatmap-DSZ2bVIa.js.map +1 -0
  142. package/dist/heatmap-PhLPXIg1.d.ts +81 -0
  143. package/dist/heatmap.cjs +3 -0
  144. package/dist/heatmap.d.cts +2 -0
  145. package/dist/heatmap.d.ts +2 -0
  146. package/dist/heatmap.js +2 -0
  147. package/dist/hydrate-CTTmQy0x.d.cts +10 -0
  148. package/dist/hydrate-CxwTXDqO.cjs +60 -0
  149. package/dist/hydrate-CxwTXDqO.cjs.map +1 -0
  150. package/dist/hydrate-CzfxLfTv.d.ts +10 -0
  151. package/dist/hydrate-DDNIHYv_.js +55 -0
  152. package/dist/hydrate-DDNIHYv_.js.map +1 -0
  153. package/dist/hydrate.cjs +13 -0
  154. package/dist/hydrate.cjs.map +1 -0
  155. package/dist/hydrate.d.cts +2 -0
  156. package/dist/hydrate.d.ts +2 -0
  157. package/dist/hydrate.js +12 -0
  158. package/dist/hydrate.js.map +1 -0
  159. package/dist/index.cjs +211 -0
  160. package/dist/index.cjs.map +1 -0
  161. package/dist/index.d.cts +45 -0
  162. package/dist/index.d.ts +45 -0
  163. package/dist/index.js +113 -0
  164. package/dist/index.js.map +1 -0
  165. package/dist/layout-B3hiqVEw.js +69 -0
  166. package/dist/layout-B3hiqVEw.js.map +1 -0
  167. package/dist/layout-CtMBhNd9.cjs +98 -0
  168. package/dist/layout-CtMBhNd9.cjs.map +1 -0
  169. package/dist/line-B3Ed6u7j.js +120 -0
  170. package/dist/line-B3Ed6u7j.js.map +1 -0
  171. package/dist/line-CMDGH6q5.d.cts +47 -0
  172. package/dist/line-D5kb8e6w.d.ts +47 -0
  173. package/dist/line-fQbtP_jL.cjs +131 -0
  174. package/dist/line-fQbtP_jL.cjs.map +1 -0
  175. package/dist/line.cjs +14 -0
  176. package/dist/line.cjs.map +1 -0
  177. package/dist/line.d.cts +2 -0
  178. package/dist/line.d.ts +2 -0
  179. package/dist/line.js +13 -0
  180. package/dist/line.js.map +1 -0
  181. package/dist/log-CaofN3-n.d.cts +48 -0
  182. package/dist/log-CaofN3-n.d.ts +48 -0
  183. package/dist/log-axis-83rSpvL5.cjs +130 -0
  184. package/dist/log-axis-83rSpvL5.cjs.map +1 -0
  185. package/dist/log-axis-B_uvvOFc.js +113 -0
  186. package/dist/log-axis-B_uvvOFc.js.map +1 -0
  187. package/dist/log.cjs +17 -0
  188. package/dist/log.cjs.map +1 -0
  189. package/dist/log.d.cts +2 -0
  190. package/dist/log.d.ts +2 -0
  191. package/dist/log.js +16 -0
  192. package/dist/log.js.map +1 -0
  193. package/dist/morph-BMxz3X2b.d.cts +10 -0
  194. package/dist/morph-BMxz3X2b.d.ts +10 -0
  195. package/dist/morph-Bgg-24l8.js +36 -0
  196. package/dist/morph-Bgg-24l8.js.map +1 -0
  197. package/dist/morph-CqYDu1bY.cjs +41 -0
  198. package/dist/morph-CqYDu1bY.cjs.map +1 -0
  199. package/dist/morph.cjs +14 -0
  200. package/dist/morph.cjs.map +1 -0
  201. package/dist/morph.d.cts +2 -0
  202. package/dist/morph.d.ts +2 -0
  203. package/dist/morph.js +13 -0
  204. package/dist/morph.js.map +1 -0
  205. package/dist/named-BWWb5LQJ.cjs +50 -0
  206. package/dist/named-BWWb5LQJ.cjs.map +1 -0
  207. package/dist/named-DE15TOgh.js +33 -0
  208. package/dist/named-DE15TOgh.js.map +1 -0
  209. package/dist/path-CwB28da0.d.cts +29 -0
  210. package/dist/path-CwB28da0.d.ts +29 -0
  211. package/dist/patterns-DtgcnA8o.js +85 -0
  212. package/dist/patterns-DtgcnA8o.js.map +1 -0
  213. package/dist/patterns-LfcQAWCy.cjs +102 -0
  214. package/dist/patterns-LfcQAWCy.cjs.map +1 -0
  215. package/dist/patterns.cjs +15 -0
  216. package/dist/patterns.cjs.map +1 -0
  217. package/dist/patterns.d.cts +2 -0
  218. package/dist/patterns.d.ts +2 -0
  219. package/dist/patterns.js +12 -0
  220. package/dist/patterns.js.map +1 -0
  221. package/dist/pie-B8UlOZiq.d.ts +58 -0
  222. package/dist/pie-C1Pa6W_l.cjs +211 -0
  223. package/dist/pie-C1Pa6W_l.cjs.map +1 -0
  224. package/dist/pie-DnQQmxkk.d.cts +58 -0
  225. package/dist/pie-RnMTQWMS.js +200 -0
  226. package/dist/pie-RnMTQWMS.js.map +1 -0
  227. package/dist/pie.cjs +4 -0
  228. package/dist/pie.d.cts +2 -0
  229. package/dist/pie.d.ts +2 -0
  230. package/dist/pie.js +2 -0
  231. package/dist/point-shapes-CGl4dugc.cjs +166 -0
  232. package/dist/point-shapes-CGl4dugc.cjs.map +1 -0
  233. package/dist/point-shapes-DI84NNpI.js +155 -0
  234. package/dist/point-shapes-DI84NNpI.js.map +1 -0
  235. package/dist/point-shapes.cjs +15 -0
  236. package/dist/point-shapes.cjs.map +1 -0
  237. package/dist/point-shapes.d.cts +2 -0
  238. package/dist/point-shapes.d.ts +2 -0
  239. package/dist/point-shapes.js +13 -0
  240. package/dist/point-shapes.js.map +1 -0
  241. package/dist/radar-BB13CGmq.d.cts +60 -0
  242. package/dist/radar-CYPab_I4.js +285 -0
  243. package/dist/radar-CYPab_I4.js.map +1 -0
  244. package/dist/radar-CoGUNNSb.cjs +290 -0
  245. package/dist/radar-CoGUNNSb.cjs.map +1 -0
  246. package/dist/radar-pFI6fvOq.d.ts +60 -0
  247. package/dist/radar.cjs +3 -0
  248. package/dist/radar.d.cts +2 -0
  249. package/dist/radar.d.ts +2 -0
  250. package/dist/radar.js +2 -0
  251. package/dist/sankey-B4PNKusJ.js +420 -0
  252. package/dist/sankey-B4PNKusJ.js.map +1 -0
  253. package/dist/sankey-B9JYnx7e.d.cts +67 -0
  254. package/dist/sankey-Bacx4fVe.cjs +425 -0
  255. package/dist/sankey-Bacx4fVe.cjs.map +1 -0
  256. package/dist/sankey-Bm518bqL.d.ts +67 -0
  257. package/dist/sankey.cjs +3 -0
  258. package/dist/sankey.d.cts +2 -0
  259. package/dist/sankey.d.ts +2 -0
  260. package/dist/sankey.js +2 -0
  261. package/dist/scatter-Bl7nasE6.d.ts +61 -0
  262. package/dist/scatter-DgMN9zRy.cjs +250 -0
  263. package/dist/scatter-DgMN9zRy.cjs.map +1 -0
  264. package/dist/scatter-DrJ8xYz4.d.cts +61 -0
  265. package/dist/scatter-kgtgR318.js +245 -0
  266. package/dist/scatter-kgtgR318.js.map +1 -0
  267. package/dist/scatter.cjs +3 -0
  268. package/dist/scatter.d.cts +2 -0
  269. package/dist/scatter.d.ts +2 -0
  270. package/dist/scatter.js +2 -0
  271. package/dist/sparkline-BG13V4Pz.d.cts +43 -0
  272. package/dist/sparkline-BQzt27Fr.js +171 -0
  273. package/dist/sparkline-BQzt27Fr.js.map +1 -0
  274. package/dist/sparkline-BS9-hltA.cjs +176 -0
  275. package/dist/sparkline-BS9-hltA.cjs.map +1 -0
  276. package/dist/sparkline-iWuXbKpd.d.ts +43 -0
  277. package/dist/sparkline.cjs +3 -0
  278. package/dist/sparkline.d.cts +2 -0
  279. package/dist/sparkline.d.ts +2 -0
  280. package/dist/sparkline.js +2 -0
  281. package/dist/stack-CpR6RGKd.d.cts +6 -0
  282. package/dist/stack-CpR6RGKd.d.ts +6 -0
  283. package/dist/stack-DRbwTeF3.js +66 -0
  284. package/dist/stack-DRbwTeF3.js.map +1 -0
  285. package/dist/stack-DVhJWaki.cjs +77 -0
  286. package/dist/stack-DVhJWaki.cjs.map +1 -0
  287. package/dist/style.css +2 -0
  288. package/dist/sweep-Duowaput.cjs +369 -0
  289. package/dist/sweep-Duowaput.cjs.map +1 -0
  290. package/dist/sweep-WSgn2etB.js +334 -0
  291. package/dist/sweep-WSgn2etB.js.map +1 -0
  292. package/dist/time-CHjiY9Q4.d.ts +112 -0
  293. package/dist/time-CNVnt-B2.d.cts +112 -0
  294. package/dist/time-axis-Bc9eHX1r.js +365 -0
  295. package/dist/time-axis-Bc9eHX1r.js.map +1 -0
  296. package/dist/time-axis-VSX34_Tb.cjs +382 -0
  297. package/dist/time-axis-VSX34_Tb.cjs.map +1 -0
  298. package/dist/time.cjs +22 -0
  299. package/dist/time.cjs.map +1 -0
  300. package/dist/time.d.cts +2 -0
  301. package/dist/time.d.ts +2 -0
  302. package/dist/time.js +20 -0
  303. package/dist/time.js.map +1 -0
  304. package/dist/tween-BCYd0RTY.js +40 -0
  305. package/dist/tween-BCYd0RTY.js.map +1 -0
  306. package/dist/tween-CIGBlryn.cjs +51 -0
  307. package/dist/tween-CIGBlryn.cjs.map +1 -0
  308. package/dist/value-labels-B0WJoJ7x.cjs +134 -0
  309. package/dist/value-labels-B0WJoJ7x.cjs.map +1 -0
  310. package/dist/value-labels-IZIQPhfk.js +123 -0
  311. package/dist/value-labels-IZIQPhfk.js.map +1 -0
  312. package/dist/value-labels.cjs +14 -0
  313. package/dist/value-labels.cjs.map +1 -0
  314. package/dist/value-labels.d.cts +2 -0
  315. package/dist/value-labels.d.ts +2 -0
  316. package/dist/value-labels.js +12 -0
  317. package/dist/value-labels.js.map +1 -0
  318. package/dist/vnode-BUflsBsa.d.cts +66 -0
  319. package/dist/vnode-BUflsBsa.d.ts +66 -0
  320. package/dist/vnode-CkQ27Cxe.cjs +110 -0
  321. package/dist/vnode-CkQ27Cxe.cjs.map +1 -0
  322. package/dist/vnode-tCWItoUH.js +93 -0
  323. package/dist/vnode-tCWItoUH.js.map +1 -0
  324. package/package.json +310 -3
@@ -0,0 +1,65 @@
1
+ import { a as InsetsInput } from "./annotations-Bp7HwtF5.js";
2
+ import { a as ClassValue } from "./vnode-BUflsBsa.js";
3
+ import { a as ChartType } from "./chart-iJGxMz9z.js";
4
+ import { c as NumberFormat } from "./time-CHjiY9Q4.js";
5
+ //#region src/charts/gauge.d.ts
6
+ /** One ring of a gauge. */
7
+ interface GaugeRing {
8
+ name: string;
9
+ /** Current value, clamped to `0…max`. */
10
+ value: number;
11
+ /** Full-ring value of this ring; overrides `GaugeOptions.max`. */
12
+ max?: number;
13
+ /** Stable identity for keyed updates and legend toggles. Defaults to `name`. */
14
+ id?: string;
15
+ /**
16
+ * Custom color; overrides the palette slot via `--tc-series-color`.
17
+ * Values that could inject CSS (`;`, quotes, `url()` …) are ignored, so colors from user data are safe.
18
+ */
19
+ color?: string;
20
+ /** Extra classes on the ring group. */
21
+ class?: ClassValue;
22
+ /** Start hidden (toggle it back from the legend). */
23
+ hidden?: boolean;
24
+ }
25
+ interface GaugeOptions {
26
+ /** A single value, one ring, or concentric rings (outermost first). */
27
+ data: number | GaugeRing | readonly GaugeRing[];
28
+ /** Full-ring value. Defaults to `100`. */
29
+ max?: number;
30
+ /** Where the arc starts, in degrees clockwise from 12 o'clock. Defaults to `0`. */
31
+ startAngle?: number;
32
+ /** Degrees the full ring spans, `0…360`. Defaults to `360`; use e.g. `270` for a dial. */
33
+ angle?: number;
34
+ /** Ring thickness in pixels. Defaults to `12`. */
35
+ thickness?: number;
36
+ /** Space between rings in pixels. Defaults to `4`. */
37
+ gap?: number;
38
+ /** Corner radius of the arcs. Defaults to half the thickness (round caps). */
39
+ cornerRadius?: number;
40
+ /** Format of the values (tooltip, table). */
41
+ format?: NumberFormat;
42
+ /**
43
+ * Text in the middle: the first ring's share of `max` and its name by
44
+ * default; `false` hides it, or give your own `value` / `label`.
45
+ */
46
+ center?: false | {
47
+ value?: string;
48
+ label?: string;
49
+ };
50
+ /** Extra space around the gauge, in pixels. */
51
+ padding?: InsetsInput;
52
+ }
53
+ /**
54
+ * Gauge (radial bar): progress towards a maximum as an arc on a track, with
55
+ * the share in the middle. Several rings nest from the outside in.
56
+ *
57
+ * ```ts
58
+ * new Chart('#el', { type: gauge, data: 58 })
59
+ * new Chart('#el', { type: gauge, data: { name: 'completed', value: 1392, max: 2400 } })
60
+ * ```
61
+ */
62
+ declare const gauge: ChartType<GaugeOptions>;
63
+ //#endregion
64
+ export { GaugeRing as n, gauge as r, GaugeOptions as t };
65
+ //# sourceMappingURL=gauge-Cu9jttC0.d.ts.map
@@ -0,0 +1,65 @@
1
+ import { a as InsetsInput } from "./annotations-lyt0I3HU.cjs";
2
+ import { a as ClassValue } from "./vnode-BUflsBsa.cjs";
3
+ import { a as ChartType } from "./chart-Qa417fJo.cjs";
4
+ import { c as NumberFormat } from "./time-CNVnt-B2.cjs";
5
+ //#region src/charts/gauge.d.ts
6
+ /** One ring of a gauge. */
7
+ interface GaugeRing {
8
+ name: string;
9
+ /** Current value, clamped to `0…max`. */
10
+ value: number;
11
+ /** Full-ring value of this ring; overrides `GaugeOptions.max`. */
12
+ max?: number;
13
+ /** Stable identity for keyed updates and legend toggles. Defaults to `name`. */
14
+ id?: string;
15
+ /**
16
+ * Custom color; overrides the palette slot via `--tc-series-color`.
17
+ * Values that could inject CSS (`;`, quotes, `url()` …) are ignored, so colors from user data are safe.
18
+ */
19
+ color?: string;
20
+ /** Extra classes on the ring group. */
21
+ class?: ClassValue;
22
+ /** Start hidden (toggle it back from the legend). */
23
+ hidden?: boolean;
24
+ }
25
+ interface GaugeOptions {
26
+ /** A single value, one ring, or concentric rings (outermost first). */
27
+ data: number | GaugeRing | readonly GaugeRing[];
28
+ /** Full-ring value. Defaults to `100`. */
29
+ max?: number;
30
+ /** Where the arc starts, in degrees clockwise from 12 o'clock. Defaults to `0`. */
31
+ startAngle?: number;
32
+ /** Degrees the full ring spans, `0…360`. Defaults to `360`; use e.g. `270` for a dial. */
33
+ angle?: number;
34
+ /** Ring thickness in pixels. Defaults to `12`. */
35
+ thickness?: number;
36
+ /** Space between rings in pixels. Defaults to `4`. */
37
+ gap?: number;
38
+ /** Corner radius of the arcs. Defaults to half the thickness (round caps). */
39
+ cornerRadius?: number;
40
+ /** Format of the values (tooltip, table). */
41
+ format?: NumberFormat;
42
+ /**
43
+ * Text in the middle: the first ring's share of `max` and its name by
44
+ * default; `false` hides it, or give your own `value` / `label`.
45
+ */
46
+ center?: false | {
47
+ value?: string;
48
+ label?: string;
49
+ };
50
+ /** Extra space around the gauge, in pixels. */
51
+ padding?: InsetsInput;
52
+ }
53
+ /**
54
+ * Gauge (radial bar): progress towards a maximum as an arc on a track, with
55
+ * the share in the middle. Several rings nest from the outside in.
56
+ *
57
+ * ```ts
58
+ * new Chart('#el', { type: gauge, data: 58 })
59
+ * new Chart('#el', { type: gauge, data: { name: 'completed', value: 1392, max: 2400 } })
60
+ * ```
61
+ */
62
+ declare const gauge: ChartType<GaugeOptions>;
63
+ //#endregion
64
+ export { GaugeRing as n, gauge as r, GaugeOptions as t };
65
+ //# sourceMappingURL=gauge-Cu_OFxBd.d.cts.map
@@ -0,0 +1,230 @@
1
+ import { i as insets, r as innerRect } from "./layout-B3hiqVEw.js";
2
+ import { t as h } from "./vnode-tCWItoUH.js";
3
+ import { o as getNumberFormat, r as formatNumber } from "./format-lStwuc1L.js";
4
+ import { r as features } from "./features-wASyHGic.js";
5
+ import { a as isRecord, n as cleanItems, t as cleanData } from "./clean-o1vDEhFV.js";
6
+ import { n as keyOf, r as legendItems, t as groupAttrs } from "./named-DE15TOgh.js";
7
+ import { a as arcPathStable, i as arcCentroid, n as sweep, r as DEG, t as arcNode } from "./sweep-WSgn2etB.js";
8
+ //#region src/charts/gauge.ts
9
+ /** Space kept around the gauge for the hover halo. */
10
+ const HALF_PI = Math.PI / 2;
11
+ function ringsOf(options) {
12
+ const { data } = options;
13
+ if (typeof data === "number") return [{
14
+ name: "",
15
+ value: data
16
+ }];
17
+ return Array.isArray(data) ? data : [data];
18
+ }
19
+ /** The visible rings with clamped values. */
20
+ function layoutRings(options, hidden) {
21
+ const max = options.max ?? 100;
22
+ return ringsOf(options).map((data, index) => ({
23
+ data,
24
+ index,
25
+ max: data.max ?? max
26
+ })).filter((ring) => !hidden.has(keyOf(ring.data))).map((ring, position) => ({
27
+ ...ring,
28
+ position,
29
+ value: Math.min(ring.max, Math.max(0, ring.data.value || 0))
30
+ }));
31
+ }
32
+ /**
33
+ * Radius and center that fit the swept ring (plus the text in the middle)
34
+ * into `area`: a dial or half ring is centered by its own outline, not by
35
+ * the full circle it is cut from.
36
+ */
37
+ function fitGauge(area, start, sweep, textTop, textBottom) {
38
+ const unit = [[0, 0]];
39
+ const end = start + sweep;
40
+ unit.push([Math.sin(start), -Math.cos(start)], [Math.sin(end), -Math.cos(end)]);
41
+ for (let a = Math.ceil(start / HALF_PI) * HALF_PI, n = 0; n < 5 && a <= end + 1e-9; n++) {
42
+ unit.push([Math.sin(a), -Math.cos(a)]);
43
+ a += HALF_PI;
44
+ }
45
+ let outer = Math.min(area.width, area.height) / 2;
46
+ let box = {
47
+ x0: 0,
48
+ y0: 0,
49
+ x1: 0,
50
+ y1: 0
51
+ };
52
+ for (let i = 0; i < 4; i++) {
53
+ box = {
54
+ x0: 0,
55
+ y0: textTop,
56
+ x1: 0,
57
+ y1: textBottom
58
+ };
59
+ for (const [x, y] of unit) {
60
+ box.x0 = Math.min(box.x0, x * outer);
61
+ box.x1 = Math.max(box.x1, x * outer);
62
+ box.y0 = Math.min(box.y0, y * outer);
63
+ box.y1 = Math.max(box.y1, y * outer);
64
+ }
65
+ const scale = Math.min(area.width / (box.x1 - box.x0), area.height / (box.y1 - box.y0));
66
+ if (Math.abs(scale - 1) < .001) break;
67
+ outer = Math.max(0, outer * scale);
68
+ }
69
+ return {
70
+ outer,
71
+ cx: area.x + (area.width - (box.x1 - box.x0)) / 2 - box.x0,
72
+ cy: area.y + (area.height - (box.y1 - box.y0)) / 2 - box.y0
73
+ };
74
+ }
75
+ function renderGauge(options, ctx) {
76
+ const { width, height, locale } = ctx;
77
+ const thickness = Math.max(1, options.thickness ?? 12);
78
+ const gap = Math.max(0, options.gap ?? 4);
79
+ const cornerRadius = options.cornerRadius ?? thickness / 2;
80
+ const pad = insets(options.padding, 0);
81
+ const area = innerRect(width, height, {
82
+ top: pad.top + 8,
83
+ right: pad.right + 8,
84
+ bottom: pad.bottom + 8,
85
+ left: pad.left + 8
86
+ });
87
+ const start = (options.startAngle ?? 0) * DEG;
88
+ const sweep = Math.min(360, Math.max(0, options.angle ?? 360)) * DEG;
89
+ const rings = layoutRings(options, ctx.hidden);
90
+ const center = options.center;
91
+ const first = rings[0];
92
+ const showCenter = center !== false && first !== void 0;
93
+ const centerLabel = showCenter ? center?.label ?? (first.data.name || void 0) : void 0;
94
+ const { outer, cx, cy } = fitGauge(area, start, sweep, showCenter ? -1.4 * ctx.fontSize : 0, showCenter ? (centerLabel ? 2 : .7) * ctx.fontSize : 0);
95
+ const value = formatNumber(options.format, locale);
96
+ const share = getNumberFormat(locale, {
97
+ style: "percent",
98
+ maximumFractionDigits: 1
99
+ });
100
+ const radii = (ring, grow = 0) => {
101
+ const r1 = Math.max(0, outer - ring.position * (thickness + gap));
102
+ return {
103
+ innerRadius: Math.max(0, r1 - thickness - grow),
104
+ outerRadius: r1 + grow
105
+ };
106
+ };
107
+ const fraction = (ring) => ring.max > 0 ? ring.value / ring.max : 0;
108
+ const geometry = (ring, grow = 0) => ({
109
+ ...radii(ring, grow),
110
+ startAngle: start,
111
+ endAngle: start + sweep * fraction(ring),
112
+ cornerRadius
113
+ });
114
+ const hitFor = (ring) => {
115
+ const [x, y] = arcCentroid(geometry(ring));
116
+ const item = {
117
+ name: ring.data.name,
118
+ seriesIndex: ring.index,
119
+ value: ring.value,
120
+ text: `${value(ring.value)} (${share.format(fraction(ring))})`,
121
+ x: cx + x,
122
+ y: cy + y
123
+ };
124
+ if (ring.data.color) item.color = ring.data.color;
125
+ return {
126
+ index: ring.position,
127
+ label: ring.data.name,
128
+ title: "",
129
+ x: cx + x,
130
+ area: {
131
+ x: cx - outer,
132
+ y: cy - outer,
133
+ width: outer * 2,
134
+ height: outer * 2
135
+ },
136
+ items: [item],
137
+ seriesIndex: ring.index,
138
+ mark: {
139
+ d: arcPathStable(geometry(ring, 2)),
140
+ x: cx,
141
+ y: cy
142
+ }
143
+ };
144
+ };
145
+ const interaction = {
146
+ count: rings.length,
147
+ hitIndex: (position) => {
148
+ const ring = rings[position];
149
+ return ring ? hitFor(ring) : null;
150
+ },
151
+ hitTest(px, py) {
152
+ const r = Math.hypot(px - cx, py - cy);
153
+ const ring = rings.find((ring) => {
154
+ const { innerRadius, outerRadius } = radii(ring, 2);
155
+ return r >= innerRadius && r <= outerRadius;
156
+ });
157
+ return ring ? hitFor(ring) : null;
158
+ }
159
+ };
160
+ ctx.onHitTest(interaction);
161
+ const groups = rings.map((ring) => h("g", groupAttrs(ring.data, ring.index), arcNode("tc-gauge-track", {
162
+ ...geometry(ring),
163
+ endAngle: start + sweep
164
+ }), arcNode("tc-gauge-arc", geometry(ring))));
165
+ const centerValue = showCenter ? center?.value ?? share.format(fraction(first)) : "";
166
+ return [h("g", {
167
+ class: "tc-gauge",
168
+ style: `transform:translate(${cx}px,${cy}px)`
169
+ }, h("g", { class: "tc-gauge-rings" }, groups)), showCenter && h("g", {
170
+ class: "tc-gauge-center",
171
+ "aria-hidden": "true"
172
+ }, h("text", {
173
+ class: "tc-gauge-value",
174
+ x: cx,
175
+ y: cy,
176
+ dy: centerLabel ? "0" : "0.35em",
177
+ "text-anchor": "middle"
178
+ }, centerValue), centerLabel && h("text", {
179
+ class: "tc-gauge-label",
180
+ x: cx,
181
+ y: cy,
182
+ dy: "1.6em",
183
+ "text-anchor": "middle"
184
+ }, centerLabel))];
185
+ }
186
+ function gaugeTable(options, ctx) {
187
+ const value = formatNumber(options.format, ctx.locale);
188
+ const share = getNumberFormat(ctx.locale, {
189
+ style: "percent",
190
+ maximumFractionDigits: 1
191
+ });
192
+ return {
193
+ columns: [
194
+ "",
195
+ "Value",
196
+ "Share"
197
+ ],
198
+ rows: layoutRings(options, ctx.hidden).map((ring) => [
199
+ ring.data.name,
200
+ value(ring.value),
201
+ share.format(ring.max > 0 ? ring.value / ring.max : 0)
202
+ ])
203
+ };
204
+ }
205
+ /**
206
+ * Gauge (radial bar): progress towards a maximum as an arc on a track, with
207
+ * the share in the middle. Several rings nest from the outside in.
208
+ *
209
+ * ```ts
210
+ * new Chart('#el', { type: gauge, data: 58 })
211
+ * new Chart('#el', { type: gauge, data: { name: 'completed', value: 1392, max: 2400 } })
212
+ * ```
213
+ */
214
+ const gauge = {
215
+ name: "gauge",
216
+ clean: cleanData((data) => cleanItems(typeof data === "number" ? [{
217
+ name: "",
218
+ value: data
219
+ }] : isRecord(data) ? [data] : data)),
220
+ render: (options, ctx) => {
221
+ features.sweep = sweep;
222
+ return renderGauge(options, ctx);
223
+ },
224
+ legend: (options) => legendItems(ringsOf(options)),
225
+ table: gaugeTable
226
+ };
227
+ //#endregion
228
+ export { gauge as t };
229
+
230
+ //# sourceMappingURL=gauge-_ljQHrMN.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gauge-_ljQHrMN.js","names":["sweepArcs"],"sources":["../src/charts/gauge.ts"],"sourcesContent":["import type { DataTable } from '../a11y.ts'\nimport type { ChartType, RenderContext } from '../chart.ts'\nimport { features } from '../features.ts'\nimport { formatNumber, getNumberFormat, type NumberFormat } from '../format.ts'\nimport type { Hit, HitItem, Interaction } from '../interaction.ts'\nimport { type InsetsInput, innerRect, insets } from '../layout.ts'\nimport { arcNode, sweep as sweepArcs } from '../render/sweep.ts'\nimport { arcCentroid, arcPathStable, DEG, HALO } from '../shapes/arc.ts'\nimport { type ChildInput, type ClassValue, h } from '../vnode.ts'\nimport { cleanData, cleanItems, isRecord } from './clean.ts'\nimport { groupAttrs, keyOf, legendItems } from './named.ts'\n\n/** One ring of a gauge. */\nexport interface GaugeRing {\n name: string\n /** Current value, clamped to `0…max`. */\n value: number\n /** Full-ring value of this ring; overrides `GaugeOptions.max`. */\n max?: number\n /** Stable identity for keyed updates and legend toggles. Defaults to `name`. */\n id?: string\n /**\n * Custom color; overrides the palette slot via `--tc-series-color`.\n * Values that could inject CSS (`;`, quotes, `url()` …) are ignored, so colors from user data are safe.\n */\n color?: string\n /** Extra classes on the ring group. */\n class?: ClassValue\n /** Start hidden (toggle it back from the legend). */\n hidden?: boolean\n}\n\nexport interface GaugeOptions {\n /** A single value, one ring, or concentric rings (outermost first). */\n data: number | GaugeRing | readonly GaugeRing[]\n /** Full-ring value. Defaults to `100`. */\n max?: number\n /** Where the arc starts, in degrees clockwise from 12 o'clock. Defaults to `0`. */\n startAngle?: number\n /** Degrees the full ring spans, `0…360`. Defaults to `360`; use e.g. `270` for a dial. */\n angle?: number\n /** Ring thickness in pixels. Defaults to `12`. */\n thickness?: number\n /** Space between rings in pixels. Defaults to `4`. */\n gap?: number\n /** Corner radius of the arcs. Defaults to half the thickness (round caps). */\n cornerRadius?: number\n /** Format of the values (tooltip, table). */\n format?: NumberFormat\n /**\n * Text in the middle: the first ring's share of `max` and its name by\n * default; `false` hides it, or give your own `value` / `label`.\n */\n center?: false | { value?: string; label?: string }\n /** Extra space around the gauge, in pixels. */\n padding?: InsetsInput\n}\n\n/** Space kept around the gauge for the hover halo. */\nconst HALF_PI = Math.PI / 2\n\ninterface Ring {\n data: GaugeRing\n index: number\n value: number\n max: number\n /** Slot among the visible rings, from the outside in. */\n position: number\n}\n\nfunction ringsOf(options: GaugeOptions): GaugeRing[] {\n const { data } = options\n if (typeof data === 'number') return [{ name: '', value: data }]\n return Array.isArray(data) ? (data as GaugeRing[]) : [data as GaugeRing]\n}\n\n/** The visible rings with clamped values. */\nfunction layoutRings(options: GaugeOptions, hidden: ReadonlySet<string>): Ring[] {\n const max = options.max ?? 100\n return ringsOf(options)\n .map((data, index) => ({ data, index, max: data.max ?? max }))\n .filter((ring) => !hidden.has(keyOf(ring.data)))\n .map((ring, position) => ({\n ...ring,\n position,\n value: Math.min(ring.max, Math.max(0, ring.data.value || 0)),\n }))\n}\n\n/**\n * Radius and center that fit the swept ring (plus the text in the middle)\n * into `area`: a dial or half ring is centered by its own outline, not by\n * the full circle it is cut from.\n */\nfunction fitGauge(\n area: { x: number; y: number; width: number; height: number },\n start: number,\n sweep: number,\n textTop: number,\n textBottom: number,\n): { outer: number; cx: number; cy: number } {\n // Points of the outline, in units of the outer radius: both ends of the arc\n // and every axis extreme it passes; the origin covers the inner edge.\n const unit: [number, number][] = [[0, 0]]\n const end = start + sweep\n unit.push([Math.sin(start), -Math.cos(start)], [Math.sin(end), -Math.cos(end)])\n // (At most a full turn of them: a huge start angle is beyond what adding a quarter turn changes.)\n for (let a = Math.ceil(start / HALF_PI) * HALF_PI, n = 0; n < 5 && a <= end + 1e-9; n++) {\n unit.push([Math.sin(a), -Math.cos(a)])\n a += HALF_PI\n }\n let outer = Math.min(area.width, area.height) / 2\n let box = { x0: 0, y0: 0, x1: 0, y1: 0 }\n // The text does not scale with the radius, so converge in a few rounds.\n for (let i = 0; i < 4; i++) {\n box = { x0: 0, y0: textTop, x1: 0, y1: textBottom }\n for (const [x, y] of unit) {\n box.x0 = Math.min(box.x0, x * outer)\n box.x1 = Math.max(box.x1, x * outer)\n box.y0 = Math.min(box.y0, y * outer)\n box.y1 = Math.max(box.y1, y * outer)\n }\n const scale = Math.min(area.width / (box.x1 - box.x0), area.height / (box.y1 - box.y0))\n if (Math.abs(scale - 1) < 1e-3) break\n outer = Math.max(0, outer * scale)\n }\n return {\n outer,\n cx: area.x + (area.width - (box.x1 - box.x0)) / 2 - box.x0,\n cy: area.y + (area.height - (box.y1 - box.y0)) / 2 - box.y0,\n }\n}\n\nfunction renderGauge(options: GaugeOptions, ctx: RenderContext): ChildInput {\n const { width, height, locale } = ctx\n const thickness = Math.max(1, options.thickness ?? 12)\n const gap = Math.max(0, options.gap ?? 4)\n const cornerRadius = options.cornerRadius ?? thickness / 2\n const pad = insets(options.padding, 0)\n const area = innerRect(width, height, {\n top: pad.top + HALO,\n right: pad.right + HALO,\n bottom: pad.bottom + HALO,\n left: pad.left + HALO,\n })\n const start = (options.startAngle ?? 0) * DEG\n const sweep = Math.min(360, Math.max(0, options.angle ?? 360)) * DEG\n const rings = layoutRings(options, ctx.hidden)\n const center = options.center\n const first = rings[0]\n const showCenter = center !== false && first !== undefined\n const centerLabel = showCenter ? (center?.label ?? (first.data.name || undefined)) : undefined\n const { outer, cx, cy } = fitGauge(\n area,\n start,\n sweep,\n showCenter ? -1.4 * ctx.fontSize : 0,\n showCenter ? (centerLabel ? 2 : 0.7) * ctx.fontSize : 0,\n )\n const value = formatNumber(options.format, locale)\n const share = getNumberFormat(locale, { style: 'percent', maximumFractionDigits: 1 })\n\n const radii = (ring: Ring, grow = 0) => {\n const r1 = Math.max(0, outer - ring.position * (thickness + gap))\n return { innerRadius: Math.max(0, r1 - thickness - grow), outerRadius: r1 + grow }\n }\n const fraction = (ring: Ring) => (ring.max > 0 ? ring.value / ring.max : 0)\n const geometry = (ring: Ring, grow = 0) => ({\n ...radii(ring, grow),\n startAngle: start,\n endAngle: start + sweep * fraction(ring),\n cornerRadius,\n })\n\n const hitFor = (ring: Ring): Hit => {\n const [x, y] = arcCentroid(geometry(ring))\n const item: HitItem = {\n name: ring.data.name,\n seriesIndex: ring.index,\n value: ring.value,\n text: `${value(ring.value)} (${share.format(fraction(ring))})`,\n x: cx + x,\n y: cy + y,\n }\n if (ring.data.color) item.color = ring.data.color\n return {\n index: ring.position,\n label: ring.data.name,\n title: '',\n x: cx + x,\n area: { x: cx - outer, y: cy - outer, width: outer * 2, height: outer * 2 },\n items: [item],\n seriesIndex: ring.index,\n // The value arc, slightly enlarged.\n mark: { d: arcPathStable(geometry(ring, 2)), x: cx, y: cy },\n }\n }\n\n const interaction: Interaction = {\n count: rings.length,\n hitIndex: (position) => {\n const ring = rings[position]\n return ring ? hitFor(ring) : null\n },\n hitTest(px, py) {\n const r = Math.hypot(px - cx, py - cy)\n const ring = rings.find((ring) => {\n const { innerRadius, outerRadius } = radii(ring, 2)\n return r >= innerRadius && r <= outerRadius\n })\n return ring ? hitFor(ring) : null\n },\n }\n ctx.onHitTest(interaction)\n\n const groups = rings.map((ring) =>\n h(\n 'g',\n groupAttrs(ring.data, ring.index),\n // Each path keeps its arc, so a new value (or a new shape of the gauge)\n // sweeps it around the center (see `sweep`).\n arcNode('tc-gauge-track', { ...geometry(ring), endAngle: start + sweep }),\n arcNode('tc-gauge-arc', geometry(ring)),\n ),\n )\n\n const centerValue = showCenter ? (center?.value ?? share.format(fraction(first))) : ''\n\n return [\n // Rings sit in their own group: the entrance animation transforms it, not the translated parent.\n h(\n 'g',\n { class: 'tc-gauge', style: `transform:translate(${cx}px,${cy}px)` },\n h('g', { class: 'tc-gauge-rings' }, groups),\n ),\n showCenter &&\n h(\n 'g',\n { class: 'tc-gauge-center', 'aria-hidden': 'true' },\n h(\n 'text',\n {\n class: 'tc-gauge-value',\n x: cx,\n y: cy,\n dy: centerLabel ? '0' : '0.35em',\n 'text-anchor': 'middle',\n },\n centerValue,\n ),\n centerLabel &&\n h(\n 'text',\n { class: 'tc-gauge-label', x: cx, y: cy, dy: '1.6em', 'text-anchor': 'middle' },\n centerLabel,\n ),\n ),\n ]\n}\n\nfunction gaugeTable(options: GaugeOptions, ctx: RenderContext): DataTable {\n const value = formatNumber(options.format, ctx.locale)\n const share = getNumberFormat(ctx.locale, { style: 'percent', maximumFractionDigits: 1 })\n return {\n columns: ['', 'Value', 'Share'],\n rows: layoutRings(options, ctx.hidden).map((ring) => [\n ring.data.name,\n value(ring.value),\n share.format(ring.max > 0 ? ring.value / ring.max : 0),\n ]),\n }\n}\n\n/**\n * Gauge (radial bar): progress towards a maximum as an arc on a track, with\n * the share in the middle. Several rings nest from the outside in.\n *\n * ```ts\n * new Chart('#el', { type: gauge, data: 58 })\n * new Chart('#el', { type: gauge, data: { name: 'completed', value: 1392, max: 2400 } })\n * ```\n */\nexport const gauge: ChartType<GaugeOptions> = {\n name: 'gauge',\n clean: cleanData((data) =>\n cleanItems(\n typeof data === 'number' ? [{ name: '', value: data }] : isRecord(data) ? [data] : data,\n ),\n ),\n render: (options, ctx): ChildInput => {\n // Set here, not as the module loads (see pie).\n features.sweep = sweepArcs\n return renderGauge(options, ctx)\n },\n legend: (options) => legendItems(ringsOf(options)),\n table: gaugeTable,\n}\n"],"mappings":";;;;;;;;;AA2DA,MAAM,UAAU,KAAK,KAAK;AAW1B,SAAS,QAAQ,SAAoC;CACnD,MAAM,EAAE,SAAS;CACjB,IAAI,OAAO,SAAS,UAAU,OAAO,CAAC;EAAE,MAAM;EAAI,OAAO;CAAK,CAAC;CAC/D,OAAO,MAAM,QAAQ,IAAI,IAAK,OAAuB,CAAC,IAAiB;AACzE;;AAGA,SAAS,YAAY,SAAuB,QAAqC;CAC/E,MAAM,MAAM,QAAQ,OAAO;CAC3B,OAAO,QAAQ,OAAO,CAAC,CACpB,KAAK,MAAM,WAAW;EAAE;EAAM;EAAO,KAAK,KAAK,OAAO;CAAI,EAAE,CAAC,CAC7D,QAAQ,SAAS,CAAC,OAAO,IAAI,MAAM,KAAK,IAAI,CAAC,CAAC,CAAC,CAC/C,KAAK,MAAM,cAAc;EACxB,GAAG;E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O,KAAK,MAAM,IAAI,KAAK,QAAQ,KAAK,MAAM,CAAC;EACvD,CAAC;CACH;AACF;;;;;;;;;;AAWA,MAAa,QAAiC;CAC5C,MAAM;CACN,OAAO,WAAW,SAChB,WACE,OAAO,SAAS,WAAW,CAAC;EAAE,MAAM;EAAI,OAAO;CAAK,CAAC,IAAI,SAAS,IAAI,IAAI,CAAC,IAAI,IAAI,IACrF,CACF;CACA,SAAS,SAAS,QAAoB;EAEpC,SAAS,QAAQA;EACjB,OAAO,YAAY,SAAS,GAAG;CACjC;CACA,SAAS,YAAY,YAAY,QAAQ,OAAO,CAAC;CACjD,OAAO;AACT"}
package/dist/gauge.cjs ADDED
@@ -0,0 +1,3 @@
1
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
+ const require_gauge = require("./gauge-CEfkWXSu.cjs");
3
+ exports.gauge = require_gauge.gauge;
@@ -0,0 +1,2 @@
1
+ import { n as GaugeRing, r as gauge, t as GaugeOptions } from "./gauge-Cu_OFxBd.cjs";
2
+ export { type GaugeOptions, type GaugeRing, gauge };
@@ -0,0 +1,2 @@
1
+ import { n as GaugeRing, r as gauge, t as GaugeOptions } from "./gauge-Cu9jttC0.js";
2
+ export { type GaugeOptions, type GaugeRing, gauge };
package/dist/gauge.js ADDED
@@ -0,0 +1,2 @@
1
+ import { t as gauge } from "./gauge-_ljQHrMN.js";
2
+ export { gauge };
@@ -0,0 +1,247 @@
1
+ const require_layout = require("./layout-CtMBhNd9.cjs");
2
+ const require_vnode = require("./vnode-CkQ27Cxe.cjs");
3
+ const require_format = require("./format-B0yKXBTH.cjs");
4
+ const require_cartesian = require("./cartesian-BoDfgBCV.cjs");
5
+ const require_extent = require("./extent-DsFWvAHJ.cjs");
6
+ const require_clean = require("./clean-Byl6kzf0.cjs");
7
+ //#region src/charts/heatmap.ts
8
+ /** Share of the full color at the minimum, so zero still reads as a value, not a gap. */
9
+ const FLOOR = .08;
10
+ const EMPTY = "var(--tc-heat-empty,var(--tc-grid-color))";
11
+ /** Cell color at `share` (0…1) of the way from the empty shade to `color`. */
12
+ const shade = (share, color = "var(--tc-heat-color,var(--tc-color-1))") => `color-mix(in oklab,${color} ${require_layout.round(share * 100)}%,${EMPTY})`;
13
+ /** Legend key of a range. */
14
+ const rangeKey = (range, index) => range.name ?? `range-${index + 1}`;
15
+ /** The first range containing `v` (`from` inclusive, `to` exclusive). */
16
+ const rangeOf = (ranges, v) => ranges.findIndex((r) => (r.from === void 0 || v >= r.from) && (r.to === void 0 || v < r.to));
17
+ /** Color of a palette slot by series index, as the CSS classes would pick it. */
18
+ const slotColor = (series, index) => series.color ?? (index < 8 ? `var(--tc-color-${index + 1})` : "var(--tc-color-other)");
19
+ /** A rounded rectangle as path data, for the hover ring. */
20
+ function ringPath(x, y, w, hgt, r) {
21
+ const rr = Math.max(0, Math.min(r, w / 2, hgt / 2));
22
+ const n = require_layout.round;
23
+ return `M${n(x + rr)},${n(y)}H${n(x + w - rr)}A${n(rr)},${n(rr)},0,0,1,${n(x + w)},${n(y + rr)}V${n(y + hgt - rr)}A${n(rr)},${n(rr)},0,0,1,${n(x + w - rr)},${n(y + hgt)}H${n(x + rr)}A${n(rr)},${n(rr)},0,0,1,${n(x)},${n(y + hgt - rr)}V${n(y + rr)}A${n(rr)},${n(rr)},0,0,1,${n(x + rr)},${n(y)}Z`;
24
+ }
25
+ function renderHeatmap(options, ctx) {
26
+ const { width, height, fontSize, locale } = ctx;
27
+ const { gap = 2, radius = 3 } = options;
28
+ const labels = require_cartesian.resolveLabels(options.data);
29
+ const formatLabel = options.x?.format ?? ((label) => String(label));
30
+ const value = require_format.formatNumber(options.format, locale);
31
+ const all = options.data.series.flatMap((s) => s.values);
32
+ const [dataMin, dataMax] = require_extent.extent(all) ?? [0, 1];
33
+ const lo = options.min ?? Math.min(0, dataMin);
34
+ const hi = options.max ?? dataMax;
35
+ /** Position of a value in the domain, 0…1 (through `mid` for a scale with a middle). */
36
+ const position = (v) => {
37
+ const { mid } = options;
38
+ let t;
39
+ if (mid !== void 0 && options.colors && lo < mid && mid < hi) t = v <= mid ? (v - lo) / (mid - lo) * .5 : .5 + (v - mid) / (hi - mid) * .5;
40
+ else t = hi > lo ? (v - lo) / (hi - lo) : v > lo ? 1 : 0;
41
+ return Math.min(1, Math.max(0, t));
42
+ };
43
+ const share = (v) => FLOOR + .92 * position(v);
44
+ const ranges = options.ranges?.length ? options.ranges : void 0;
45
+ const stops = !ranges && options.colors && options.colors.length >= 2 ? options.colors : void 0;
46
+ const bySeries = !ranges && !stops && options.colorBy === "series";
47
+ const rows = bySeries ? options.data.series.filter((s) => !ctx.hidden.has(require_cartesian.seriesKey(s))) : options.data.series;
48
+ const slot = (row) => options.data.series.indexOf(row);
49
+ /** How the cell of `row` with value `v` is painted in the active color mode. */
50
+ const paint = (v, row) => {
51
+ if (ranges) {
52
+ const index = rangeOf(ranges, v);
53
+ const range = ranges[index];
54
+ if (!range || ctx.hidden.has(rangeKey(range, index))) return {
55
+ color: EMPTY,
56
+ empty: true
57
+ };
58
+ return {
59
+ style: { "--tc-cell-fill": range.color },
60
+ color: range.color
61
+ };
62
+ }
63
+ if (stops) {
64
+ const at = position(v) * (stops.length - 1);
65
+ const k = Math.min(stops.length - 2, Math.floor(at));
66
+ const u = require_layout.round((at - k) * 100);
67
+ const from = stops[k];
68
+ const color = u <= 0 ? from : u >= 100 ? stops[k + 1] : `color-mix(in oklab,${stops[k + 1]} ${u}%,${from})`;
69
+ return {
70
+ style: { "--tc-cell-fill": color },
71
+ color
72
+ };
73
+ }
74
+ const pct = share(v);
75
+ return {
76
+ style: `--tc-heat:${require_layout.round(pct * 100)}%`,
77
+ color: bySeries ? shade(pct, slotColor(row, slot(row))) : shade(pct)
78
+ };
79
+ };
80
+ const pad = require_layout.insets(options.padding, 0);
81
+ const showX = options.x?.show !== false && labels.length > 0;
82
+ const showY = options.y?.show !== false && rows.length > 0;
83
+ const rowTicks = rows.map((s, i) => ({
84
+ value: i,
85
+ position: 0,
86
+ label: s.name
87
+ }));
88
+ const left = showY ? require_cartesian.axisSize("left", rowTicks, fontSize) : 0;
89
+ const bottom = showX ? require_cartesian.axisSize("bottom", [{
90
+ value: 0,
91
+ position: 0,
92
+ label: "M"
93
+ }], fontSize) : 0;
94
+ const lastLabel = showX ? require_layout.estimateTextWidth(formatLabel(labels[labels.length - 1], labels.length - 1), fontSize) : 0;
95
+ const halfColumn = (width - pad.left - pad.right - left) / Math.max(1, labels.length) / 2;
96
+ const area = require_layout.innerRect(width, height, {
97
+ top: pad.top,
98
+ right: pad.right + Math.max(0, Math.ceil(lastLabel / 2 - halfColumn)),
99
+ bottom: pad.bottom + bottom,
100
+ left: pad.left + left
101
+ });
102
+ const x = require_cartesian.band(labels.map((_, i) => i), [area.x, area.x + area.width]);
103
+ const y = require_cartesian.band(rows.map((_, i) => i), [area.y, area.y + area.height]);
104
+ const cellW = Math.max(0, x.bandwidth - gap);
105
+ const cellH = Math.max(0, y.bandwidth - gap);
106
+ const cellX = (i) => x.at(i) + gap / 2;
107
+ const cellY = (j) => y.at(j) + gap / 2;
108
+ const valueAt = (i, j) => {
109
+ const v = rows[j]?.values[i];
110
+ return v != null && Number.isFinite(v) ? v : null;
111
+ };
112
+ const hitAt = (i, row = 0) => {
113
+ if (i < 0 || i >= labels.length || rows.length === 0) return null;
114
+ const j = Math.max(0, Math.min(rows.length - 1, row));
115
+ const items = rows.map((s, r) => {
116
+ const v = valueAt(i, r);
117
+ const range = ranges && v !== null ? ranges[rangeOf(ranges, v)] : void 0;
118
+ return {
119
+ name: s.name,
120
+ seriesIndex: r,
121
+ value: v,
122
+ text: v === null ? "–" : range?.name ? `${value(v)} · ${range.name}` : value(v),
123
+ x: cellX(i) + cellW / 2,
124
+ y: cellY(r) + cellH / 2,
125
+ box: {
126
+ x: cellX(i),
127
+ y: cellY(r),
128
+ width: cellW,
129
+ height: cellH
130
+ },
131
+ color: v === null ? "var(--tc-grid-color)" : paint(v, s).color
132
+ };
133
+ });
134
+ return {
135
+ index: i,
136
+ label: require_cartesian.labelKey(labels[i]),
137
+ title: formatLabel(labels[i], i),
138
+ x: cellX(i) + cellW / 2,
139
+ area,
140
+ items,
141
+ seriesIndex: j,
142
+ mark: {
143
+ d: ringPath(cellX(i) - 2, cellY(j) - 2, cellW + 4, cellH + 4, radius + 2),
144
+ x: 0,
145
+ y: 0
146
+ }
147
+ };
148
+ };
149
+ const interaction = {
150
+ count: labels.length,
151
+ hitIndex: (i, row) => hitAt(i, row),
152
+ hitTest(px, py) {
153
+ if (px < area.x || px > area.x + area.width || py < area.y || py > area.y + area.height) return null;
154
+ const i = Math.min(labels.length - 1, Math.floor((px - area.x) / (x.step || 1)));
155
+ const j = Math.min(rows.length - 1, Math.floor((py - area.y) / (y.step || 1)));
156
+ return hitAt(i, j);
157
+ }
158
+ };
159
+ ctx.onHitTest(interaction);
160
+ const cells = rows.map((s, j) => require_vnode.h("g", {
161
+ key: require_cartesian.seriesKey(s),
162
+ class: ["tc-heatmap-row", bySeries && ["tc-series", `tc-series-${slot(s) + 1}`]],
163
+ "data-series": s.name,
164
+ style: bySeries ? { "--tc-series-color": s.color } : void 0
165
+ }, labels.map((label, i) => {
166
+ const v = valueAt(i, j);
167
+ const painted = v === null ? void 0 : paint(v, s);
168
+ return require_vnode.h("rect", {
169
+ key: require_cartesian.labelKey(label),
170
+ class: ["tc-cell", (v === null || painted?.empty) && "tc-cell-empty"],
171
+ x: require_layout.round(cellX(i)),
172
+ y: require_layout.round(cellY(j)),
173
+ width: require_layout.round(cellW),
174
+ height: require_layout.round(cellH),
175
+ rx: require_layout.round(Math.min(radius, cellW / 2, cellH / 2)),
176
+ style: painted?.style
177
+ });
178
+ })));
179
+ const xTicks = showX ? require_cartesian.thinTicks(require_cartesian.bandTicks(x, (_, i) => formatLabel(labels[i], i)), "bottom", fontSize) : [];
180
+ const yTicks = showY ? require_cartesian.bandTicks(y, (_, j) => rows[j]?.name ?? "") : [];
181
+ return [
182
+ require_vnode.h("g", { class: "tc-heatmap-cells" }, cells),
183
+ showX && require_cartesian.axis({
184
+ position: "bottom",
185
+ ticks: xTicks,
186
+ area
187
+ }),
188
+ showY && require_cartesian.axis({
189
+ position: "left",
190
+ ticks: yTicks,
191
+ area
192
+ })
193
+ ];
194
+ }
195
+ /** Legend: the ranges, or the rows when colored by series; none for a single scale. */
196
+ function heatmapLegend(options) {
197
+ const { ranges } = options;
198
+ if (ranges?.length) {
199
+ const value = require_format.formatNumber(options.format, options.locale);
200
+ return ranges.map((range, index) => ({
201
+ key: rangeKey(range, index),
202
+ name: range.name ?? (range.from === void 0 ? `< ${value(range.to ?? 0)}` : range.to === void 0 ? `≥ ${value(range.from)}` : `${value(range.from)}–${value(range.to)}`),
203
+ index,
204
+ color: range.color
205
+ }));
206
+ }
207
+ if (options.colors && options.colors.length >= 2) return [];
208
+ return options.colorBy === "series" ? require_cartesian.seriesLegend(options.data) : [];
209
+ }
210
+ /**
211
+ * Heatmap: a grid of cells, one row per series and one column per label,
212
+ * shaded from light to the full color by value (a single hue, so it reads
213
+ * as magnitude). Set the hue with `--tc-heat-color`, or color the cells by
214
+ * `ranges` of values, a `colors` scale (with a `mid` for diverging data),
215
+ * or one palette color per row with `colorBy: 'series'`.
216
+ *
217
+ * ```ts
218
+ * new Chart('#el', {
219
+ * type: heatmap,
220
+ * data: { labels: ['W1', 'W2', 'W3'], series: [{ name: 'Mon', values: [2, 4, 0] }] },
221
+ * })
222
+ * ```
223
+ */
224
+ const heatmap = {
225
+ name: "heatmap",
226
+ clean: require_clean.cleanData(require_clean.cleanSeries),
227
+ render: renderHeatmap,
228
+ legend: heatmapLegend,
229
+ valueLabels: {
230
+ marks: "cell",
231
+ format: (options) => options.format
232
+ },
233
+ table: (options, ctx, limit) => require_cartesian.seriesTable({
234
+ data: options.data,
235
+ ...options.x ? { x: options.x } : {},
236
+ y: { format: options.format }
237
+ }, ctx, limit)
238
+ };
239
+ //#endregion
240
+ Object.defineProperty(exports, "heatmap", {
241
+ enumerable: true,
242
+ get: function() {
243
+ return heatmap;
244
+ }
245
+ });
246
+
247
+ //# sourceMappingURL=heatmap-BK18EBgJ.cjs.map