@automattic/charts 0.57.0 → 0.59.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 (267) hide show
  1. package/CHANGELOG.md +36 -2
  2. package/README.md +7 -54
  3. package/dist/index.cjs +9607 -21
  4. package/dist/index.cjs.map +1 -1
  5. package/dist/index.css +32 -49
  6. package/dist/index.css.map +1 -1
  7. package/dist/index.d.cts +1612 -33
  8. package/dist/index.d.ts +1612 -33
  9. package/dist/index.js +9640 -54
  10. package/dist/index.js.map +1 -1
  11. package/package.json +9 -126
  12. package/src/charts/bar-chart/bar-chart.module.scss +0 -5
  13. package/src/charts/bar-chart/bar-chart.tsx +142 -149
  14. package/src/charts/bar-chart/test/bar-chart.test.tsx +48 -31
  15. package/src/charts/leaderboard-chart/leaderboard-chart.tsx +54 -74
  16. package/src/charts/leaderboard-chart/test/leaderboard-chart.test.tsx +4 -5
  17. package/src/charts/leaderboard-chart/types.ts +1 -11
  18. package/src/charts/line-chart/line-chart.module.scss +0 -5
  19. package/src/charts/line-chart/line-chart.tsx +202 -193
  20. package/src/charts/line-chart/private/line-chart-annotations-overlay.tsx +1 -2
  21. package/src/charts/line-chart/test/line-chart.test.tsx +49 -27
  22. package/src/charts/line-chart/types.ts +0 -1
  23. package/src/charts/pie-chart/pie-chart.module.scss +2 -10
  24. package/src/charts/pie-chart/pie-chart.tsx +212 -212
  25. package/src/charts/pie-chart/test/composition-api.test.tsx +44 -3
  26. package/src/charts/pie-chart/test/pie-chart.test.tsx +51 -44
  27. package/src/charts/pie-semi-circle-chart/pie-semi-circle-chart.module.scss +2 -8
  28. package/src/charts/pie-semi-circle-chart/pie-semi-circle-chart.tsx +166 -168
  29. package/src/charts/pie-semi-circle-chart/test/pie-semi-circle-chart.test.tsx +58 -30
  30. package/src/charts/private/chart-composition/index.ts +2 -0
  31. package/src/charts/private/chart-composition/render-legend-slot.ts +22 -0
  32. package/src/charts/private/chart-composition/test/render-legend-slot.test.tsx +60 -0
  33. package/src/charts/private/chart-composition/test/use-chart-children.test.tsx +91 -0
  34. package/src/charts/private/chart-composition/use-chart-children.ts +34 -2
  35. package/src/charts/private/chart-layout/chart-layout.module.scss +7 -0
  36. package/src/charts/private/chart-layout/chart-layout.tsx +106 -0
  37. package/src/charts/private/chart-layout/index.ts +2 -0
  38. package/src/charts/private/chart-layout/test/chart-layout.test.tsx +167 -0
  39. package/src/charts/private/single-chart-context/single-chart-context.tsx +2 -2
  40. package/src/charts/private/svg-empty-state/index.ts +1 -0
  41. package/src/charts/private/svg-empty-state/svg-empty-state.module.scss +7 -0
  42. package/src/charts/private/svg-empty-state/svg-empty-state.tsx +40 -0
  43. package/src/components/legend/hooks/test/use-chart-legend-items.test.tsx +12 -8
  44. package/src/components/legend/hooks/use-chart-legend-items.ts +12 -13
  45. package/src/components/legend/index.ts +1 -8
  46. package/src/components/legend/legend.tsx +33 -8
  47. package/src/components/legend/private/base-legend.module.scss +19 -37
  48. package/src/components/legend/private/base-legend.tsx +0 -2
  49. package/src/components/legend/test/legend.test.tsx +93 -1
  50. package/src/components/legend/types.ts +7 -34
  51. package/src/hooks/index.ts +1 -1
  52. package/src/hooks/use-data-with-percentages.ts +24 -0
  53. package/src/hooks/use-interactive-legend-data.ts +18 -15
  54. package/src/index.ts +66 -9
  55. package/src/providers/chart-context/global-charts-provider.tsx +7 -1
  56. package/src/providers/chart-context/hooks/use-chart-registration.ts +2 -1
  57. package/src/providers/chart-context/types.ts +2 -2
  58. package/src/types.ts +110 -45
  59. package/src/utils/date-parsing.ts +10 -1
  60. package/src/utils/test/date-parsing.test.ts +12 -0
  61. package/src/utils/test/resolve-css-var.test.ts +4 -2
  62. package/tsup.config.ts +1 -1
  63. package/dist/base-tooltip-DOq93wjU.d.cts +0 -38
  64. package/dist/base-tooltip-DOq93wjU.d.ts +0 -38
  65. package/dist/charts/bar-chart/index.cjs +0 -15
  66. package/dist/charts/bar-chart/index.cjs.map +0 -1
  67. package/dist/charts/bar-chart/index.css +0 -153
  68. package/dist/charts/bar-chart/index.css.map +0 -1
  69. package/dist/charts/bar-chart/index.d.cts +0 -37
  70. package/dist/charts/bar-chart/index.d.ts +0 -37
  71. package/dist/charts/bar-chart/index.js +0 -15
  72. package/dist/charts/bar-chart/index.js.map +0 -1
  73. package/dist/charts/bar-list-chart/index.cjs +0 -16
  74. package/dist/charts/bar-list-chart/index.cjs.map +0 -1
  75. package/dist/charts/bar-list-chart/index.css +0 -153
  76. package/dist/charts/bar-list-chart/index.css.map +0 -1
  77. package/dist/charts/bar-list-chart/index.d.cts +0 -92
  78. package/dist/charts/bar-list-chart/index.d.ts +0 -92
  79. package/dist/charts/bar-list-chart/index.js +0 -16
  80. package/dist/charts/bar-list-chart/index.js.map +0 -1
  81. package/dist/charts/conversion-funnel-chart/index.cjs +0 -11
  82. package/dist/charts/conversion-funnel-chart/index.cjs.map +0 -1
  83. package/dist/charts/conversion-funnel-chart/index.css +0 -251
  84. package/dist/charts/conversion-funnel-chart/index.css.map +0 -1
  85. package/dist/charts/conversion-funnel-chart/index.d.cts +0 -97
  86. package/dist/charts/conversion-funnel-chart/index.d.ts +0 -97
  87. package/dist/charts/conversion-funnel-chart/index.js +0 -11
  88. package/dist/charts/conversion-funnel-chart/index.js.map +0 -1
  89. package/dist/charts/geo-chart/index.cjs +0 -13
  90. package/dist/charts/geo-chart/index.cjs.map +0 -1
  91. package/dist/charts/geo-chart/index.css +0 -117
  92. package/dist/charts/geo-chart/index.css.map +0 -1
  93. package/dist/charts/geo-chart/index.d.cts +0 -67
  94. package/dist/charts/geo-chart/index.d.ts +0 -67
  95. package/dist/charts/geo-chart/index.js +0 -13
  96. package/dist/charts/geo-chart/index.js.map +0 -1
  97. package/dist/charts/leaderboard-chart/index.cjs +0 -20
  98. package/dist/charts/leaderboard-chart/index.cjs.map +0 -1
  99. package/dist/charts/leaderboard-chart/index.css +0 -172
  100. package/dist/charts/leaderboard-chart/index.css.map +0 -1
  101. package/dist/charts/leaderboard-chart/index.d.cts +0 -46
  102. package/dist/charts/leaderboard-chart/index.d.ts +0 -46
  103. package/dist/charts/leaderboard-chart/index.js +0 -20
  104. package/dist/charts/leaderboard-chart/index.js.map +0 -1
  105. package/dist/charts/line-chart/index.cjs +0 -15
  106. package/dist/charts/line-chart/index.cjs.map +0 -1
  107. package/dist/charts/line-chart/index.css +0 -225
  108. package/dist/charts/line-chart/index.css.map +0 -1
  109. package/dist/charts/line-chart/index.d.cts +0 -99
  110. package/dist/charts/line-chart/index.d.ts +0 -99
  111. package/dist/charts/line-chart/index.js +0 -15
  112. package/dist/charts/line-chart/index.js.map +0 -1
  113. package/dist/charts/pie-chart/index.cjs +0 -18
  114. package/dist/charts/pie-chart/index.cjs.map +0 -1
  115. package/dist/charts/pie-chart/index.css +0 -143
  116. package/dist/charts/pie-chart/index.css.map +0 -1
  117. package/dist/charts/pie-chart/index.d.cts +0 -97
  118. package/dist/charts/pie-chart/index.d.ts +0 -97
  119. package/dist/charts/pie-chart/index.js +0 -18
  120. package/dist/charts/pie-chart/index.js.map +0 -1
  121. package/dist/charts/pie-semi-circle-chart/index.cjs +0 -17
  122. package/dist/charts/pie-semi-circle-chart/index.cjs.map +0 -1
  123. package/dist/charts/pie-semi-circle-chart/index.css +0 -144
  124. package/dist/charts/pie-semi-circle-chart/index.css.map +0 -1
  125. package/dist/charts/pie-semi-circle-chart/index.d.cts +0 -94
  126. package/dist/charts/pie-semi-circle-chart/index.d.ts +0 -94
  127. package/dist/charts/pie-semi-circle-chart/index.js +0 -17
  128. package/dist/charts/pie-semi-circle-chart/index.js.map +0 -1
  129. package/dist/charts/sparkline/index.cjs +0 -16
  130. package/dist/charts/sparkline/index.cjs.map +0 -1
  131. package/dist/charts/sparkline/index.css +0 -242
  132. package/dist/charts/sparkline/index.css.map +0 -1
  133. package/dist/charts/sparkline/index.d.cts +0 -113
  134. package/dist/charts/sparkline/index.d.ts +0 -113
  135. package/dist/charts/sparkline/index.js +0 -16
  136. package/dist/charts/sparkline/index.js.map +0 -1
  137. package/dist/chunk-2A34OA5O.cjs +0 -51
  138. package/dist/chunk-2A34OA5O.cjs.map +0 -1
  139. package/dist/chunk-2NCY7R4G.js +0 -3897
  140. package/dist/chunk-2NCY7R4G.js.map +0 -1
  141. package/dist/chunk-32DH6JDF.js +0 -1263
  142. package/dist/chunk-32DH6JDF.js.map +0 -1
  143. package/dist/chunk-4OPFE4RM.js +0 -614
  144. package/dist/chunk-4OPFE4RM.js.map +0 -1
  145. package/dist/chunk-6CCZL2JJ.js +0 -63
  146. package/dist/chunk-6CCZL2JJ.js.map +0 -1
  147. package/dist/chunk-77OKCVQN.cjs +0 -421
  148. package/dist/chunk-77OKCVQN.cjs.map +0 -1
  149. package/dist/chunk-7FQX4ALL.cjs +0 -219
  150. package/dist/chunk-7FQX4ALL.cjs.map +0 -1
  151. package/dist/chunk-ASLARV7L.cjs +0 -81
  152. package/dist/chunk-ASLARV7L.cjs.map +0 -1
  153. package/dist/chunk-BCX5THDQ.js +0 -403
  154. package/dist/chunk-BCX5THDQ.js.map +0 -1
  155. package/dist/chunk-BPYKWMI7.js +0 -194
  156. package/dist/chunk-BPYKWMI7.js.map +0 -1
  157. package/dist/chunk-CZGYJKG6.js +0 -421
  158. package/dist/chunk-CZGYJKG6.js.map +0 -1
  159. package/dist/chunk-D2UH4CFE.cjs +0 -120
  160. package/dist/chunk-D2UH4CFE.cjs.map +0 -1
  161. package/dist/chunk-DAU3HNEG.js +0 -344
  162. package/dist/chunk-DAU3HNEG.js.map +0 -1
  163. package/dist/chunk-H2V4JMSA.js +0 -219
  164. package/dist/chunk-H2V4JMSA.js.map +0 -1
  165. package/dist/chunk-I2276W3I.cjs +0 -66
  166. package/dist/chunk-I2276W3I.cjs.map +0 -1
  167. package/dist/chunk-I35UYJJR.cjs +0 -468
  168. package/dist/chunk-I35UYJJR.cjs.map +0 -1
  169. package/dist/chunk-IU4DYUAV.js +0 -120
  170. package/dist/chunk-IU4DYUAV.js.map +0 -1
  171. package/dist/chunk-KXRWNFQJ.js +0 -51
  172. package/dist/chunk-KXRWNFQJ.js.map +0 -1
  173. package/dist/chunk-OP6PHB2U.js +0 -81
  174. package/dist/chunk-OP6PHB2U.js.map +0 -1
  175. package/dist/chunk-PXLEMUGJ.js +0 -165
  176. package/dist/chunk-PXLEMUGJ.js.map +0 -1
  177. package/dist/chunk-RCY6XLGU.cjs +0 -63
  178. package/dist/chunk-RCY6XLGU.cjs.map +0 -1
  179. package/dist/chunk-RHHVEJHJ.cjs +0 -1263
  180. package/dist/chunk-RHHVEJHJ.cjs.map +0 -1
  181. package/dist/chunk-TO3OQBXG.cjs +0 -165
  182. package/dist/chunk-TO3OQBXG.cjs.map +0 -1
  183. package/dist/chunk-V36ERY7Y.js +0 -375
  184. package/dist/chunk-V36ERY7Y.js.map +0 -1
  185. package/dist/chunk-VJM5XCB4.cjs +0 -614
  186. package/dist/chunk-VJM5XCB4.cjs.map +0 -1
  187. package/dist/chunk-VTS3PNMS.cjs +0 -344
  188. package/dist/chunk-VTS3PNMS.cjs.map +0 -1
  189. package/dist/chunk-WLODYNLB.js +0 -1067
  190. package/dist/chunk-WLODYNLB.js.map +0 -1
  191. package/dist/chunk-XKRJL2QT.cjs +0 -375
  192. package/dist/chunk-XKRJL2QT.cjs.map +0 -1
  193. package/dist/chunk-XWYZIFZW.js +0 -66
  194. package/dist/chunk-XWYZIFZW.js.map +0 -1
  195. package/dist/chunk-Y3NNQMAX.cjs +0 -194
  196. package/dist/chunk-Y3NNQMAX.cjs.map +0 -1
  197. package/dist/chunk-YE2T52VZ.cjs +0 -1067
  198. package/dist/chunk-YE2T52VZ.cjs.map +0 -1
  199. package/dist/chunk-Z26M4V2M.js +0 -468
  200. package/dist/chunk-Z26M4V2M.js.map +0 -1
  201. package/dist/chunk-Z45KX47P.cjs +0 -3897
  202. package/dist/chunk-Z45KX47P.cjs.map +0 -1
  203. package/dist/chunk-ZH4F5RMG.cjs +0 -403
  204. package/dist/chunk-ZH4F5RMG.cjs.map +0 -1
  205. package/dist/components/legend/index.cjs +0 -11
  206. package/dist/components/legend/index.cjs.map +0 -1
  207. package/dist/components/legend/index.css +0 -103
  208. package/dist/components/legend/index.css.map +0 -1
  209. package/dist/components/legend/index.d.cts +0 -37
  210. package/dist/components/legend/index.d.ts +0 -37
  211. package/dist/components/legend/index.js +0 -11
  212. package/dist/components/legend/index.js.map +0 -1
  213. package/dist/components/tooltip/index.cjs +0 -12
  214. package/dist/components/tooltip/index.cjs.map +0 -1
  215. package/dist/components/tooltip/index.css +0 -13
  216. package/dist/components/tooltip/index.css.map +0 -1
  217. package/dist/components/tooltip/index.d.cts +0 -71
  218. package/dist/components/tooltip/index.d.ts +0 -71
  219. package/dist/components/tooltip/index.js +0 -12
  220. package/dist/components/tooltip/index.js.map +0 -1
  221. package/dist/components/trend-indicator/index.cjs +0 -8
  222. package/dist/components/trend-indicator/index.cjs.map +0 -1
  223. package/dist/components/trend-indicator/index.css +0 -27
  224. package/dist/components/trend-indicator/index.css.map +0 -1
  225. package/dist/components/trend-indicator/index.d.cts +0 -44
  226. package/dist/components/trend-indicator/index.d.ts +0 -44
  227. package/dist/components/trend-indicator/index.js +0 -8
  228. package/dist/components/trend-indicator/index.js.map +0 -1
  229. package/dist/format-metric-value-MXm5DtQ_.d.cts +0 -24
  230. package/dist/format-metric-value-MXm5DtQ_.d.ts +0 -24
  231. package/dist/hooks/index.cjs +0 -31
  232. package/dist/hooks/index.cjs.map +0 -1
  233. package/dist/hooks/index.css +0 -103
  234. package/dist/hooks/index.css.map +0 -1
  235. package/dist/hooks/index.d.cts +0 -272
  236. package/dist/hooks/index.d.ts +0 -272
  237. package/dist/hooks/index.js +0 -31
  238. package/dist/hooks/index.js.map +0 -1
  239. package/dist/leaderboard-chart-BKYYXcg2.d.ts +0 -83
  240. package/dist/leaderboard-chart-DR7CGb0L.d.cts +0 -83
  241. package/dist/legend-C2grwnWk.d.cts +0 -9
  242. package/dist/legend-Cj0xM5dU.d.ts +0 -9
  243. package/dist/providers/index.cjs +0 -21
  244. package/dist/providers/index.cjs.map +0 -1
  245. package/dist/providers/index.css +0 -103
  246. package/dist/providers/index.css.map +0 -1
  247. package/dist/providers/index.d.cts +0 -28
  248. package/dist/providers/index.d.ts +0 -28
  249. package/dist/providers/index.js +0 -21
  250. package/dist/providers/index.js.map +0 -1
  251. package/dist/themes-BmVGrYnF.d.ts +0 -67
  252. package/dist/themes-CyjKm-P_.d.cts +0 -67
  253. package/dist/types-CuUEszrM.d.ts +0 -19
  254. package/dist/types-DZordNiO.d.cts +0 -505
  255. package/dist/types-DZordNiO.d.ts +0 -505
  256. package/dist/types-I67mddpr.d.cts +0 -78
  257. package/dist/types-I67mddpr.d.ts +0 -78
  258. package/dist/types-KtOPPzPX.d.cts +0 -19
  259. package/dist/utils/index.cjs +0 -44
  260. package/dist/utils/index.cjs.map +0 -1
  261. package/dist/utils/index.d.cts +0 -226
  262. package/dist/utils/index.d.ts +0 -226
  263. package/dist/utils/index.js +0 -44
  264. package/dist/utils/index.js.map +0 -1
  265. package/dist/with-responsive-CNfhzAUu.d.cts +0 -18
  266. package/dist/with-responsive-CNfhzAUu.d.ts +0 -18
  267. package/src/hooks/use-has-legend-child.ts +0 -22
@@ -1,251 +0,0 @@
1
- /* esbuild-sass-plugin:css-chunk:src/hooks/use-tooltip-portal-relocator.module.scss */
2
- .a8ccharts-jCw5dQ {
3
- position: fixed;
4
- inset: 0;
5
- overflow: visible;
6
- z-index: 1;
7
- pointer-events: none;
8
- }
9
-
10
- /* esbuild-sass-plugin:css-chunk:src/components/legend/private/base-legend.module.scss */
11
- .a8ccharts-AELBvX {
12
- display: flex;
13
- flex-direction: row;
14
- flex-wrap: wrap;
15
- gap: 16px;
16
- }
17
- .a8ccharts-fX8uQe {
18
- display: flex;
19
- flex-direction: column;
20
- gap: 8px;
21
- }
22
- .a8ccharts-fX8uQe.a8ccharts-DEe0wg {
23
- align-items: flex-start;
24
- }
25
- .a8ccharts-fX8uQe.a8ccharts-WBKF9I {
26
- align-items: center;
27
- }
28
- .a8ccharts-fX8uQe.a8ccharts-JfwMng {
29
- align-items: flex-end;
30
- }
31
- .a8ccharts-8Y73Kh {
32
- position: relative;
33
- }
34
- .a8ccharts-8Y73Kh.a8ccharts-DEe0wg {
35
- justify-content: flex-start;
36
- }
37
- .a8ccharts-8Y73Kh.a8ccharts-WBKF9I {
38
- justify-content: center;
39
- }
40
- .a8ccharts-8Y73Kh.a8ccharts-JfwMng {
41
- justify-content: flex-end;
42
- }
43
- .a8ccharts-TVM-IY {
44
- position: relative;
45
- }
46
- .a8ccharts-TVM-IY.a8ccharts-DEe0wg {
47
- justify-content: flex-start;
48
- }
49
- .a8ccharts-TVM-IY.a8ccharts-WBKF9I {
50
- justify-content: center;
51
- }
52
- .a8ccharts-TVM-IY.a8ccharts-JfwMng {
53
- justify-content: flex-end;
54
- }
55
- .a8ccharts-Vflwq8 {
56
- display: flex;
57
- align-items: center;
58
- font-size: 0.875rem;
59
- }
60
- .a8ccharts-qGsavM {
61
- cursor: pointer;
62
- user-select: none;
63
- transition: opacity 0.2s ease;
64
- }
65
- .a8ccharts-qGsavM:hover {
66
- opacity: 0.8;
67
- }
68
- .a8ccharts-qGsavM:focus {
69
- outline: 2px solid currentColor;
70
- outline-offset: 2px;
71
- border-radius: 4px;
72
- }
73
- .a8ccharts-qGsavM:focus:not(:focus-visible) {
74
- outline: none;
75
- }
76
- .a8ccharts-ZtDY-Q {
77
- opacity: 0.4;
78
- }
79
- .a8ccharts-ZtDY-Q .a8ccharts-2H65Kr {
80
- text-decoration: line-through;
81
- }
82
- .a8ccharts-2H65Kr {
83
- display: flex;
84
- align-items: center;
85
- gap: 0.5rem;
86
- }
87
- .a8ccharts-faSDBI {
88
- overflow-wrap: break-word;
89
- white-space: normal;
90
- hyphens: auto;
91
- }
92
- .a8ccharts-FISUIO {
93
- white-space: nowrap;
94
- overflow: hidden;
95
- text-overflow: ellipsis;
96
- flex-shrink: 1;
97
- min-width: 0;
98
- }
99
- .a8ccharts-DTZlT- {
100
- font-weight: 500;
101
- flex-shrink: 0;
102
- }
103
-
104
- /* esbuild-sass-plugin:css-chunk:src/charts/conversion-funnel-chart/conversion-funnel-chart.module.scss */
105
- .a8ccharts-lK-YNK {
106
- font-family: var(--funnel-font-family, "SF Pro Text");
107
- }
108
- .a8ccharts-lK-YNK.a8ccharts-DbHKK5 {
109
- opacity: 0.6;
110
- pointer-events: none;
111
- }
112
- .a8ccharts-61WPYr {
113
- display: flex;
114
- align-items: baseline;
115
- gap: 8px;
116
- margin-bottom: 24px;
117
- height: 20px;
118
- }
119
- .a8ccharts-RRRI6x {
120
- overflow: hidden;
121
- color: #1e1e1e;
122
- text-overflow: ellipsis;
123
- font-family: var(--funnel-font-family, "SF Pro Text");
124
- font-size: 18px;
125
- font-style: normal;
126
- font-weight: 500;
127
- line-height: 20px;
128
- margin: 0;
129
- }
130
- .a8ccharts-661iwx {
131
- overflow: hidden;
132
- text-overflow: ellipsis;
133
- font-family: var(--funnel-font-family, "SF Pro Text");
134
- font-size: 13px;
135
- font-style: normal;
136
- font-weight: 500;
137
- line-height: 20px;
138
- margin: 0;
139
- }
140
- .a8ccharts-Z7EGnW {
141
- display: flex;
142
- gap: 16px;
143
- align-items: flex-end;
144
- flex: 1;
145
- min-height: 200px;
146
- width: 100%;
147
- }
148
- .a8ccharts-VqFY0l {
149
- flex: 1 1 0;
150
- min-width: 0;
151
- display: flex;
152
- flex-direction: column;
153
- height: 100%;
154
- transition: all 0.3s ease;
155
- }
156
- .a8ccharts-VqFY0l.a8ccharts-7dTRBs {
157
- opacity: 0.3;
158
- }
159
- .a8ccharts-2JsQiV {
160
- margin-bottom: 24px;
161
- }
162
- .a8ccharts-6OabC4 {
163
- color: #757575;
164
- font-family: var(--step-font-family, "SF Pro");
165
- font-size: 12px;
166
- font-style: normal;
167
- font-weight: 400;
168
- line-height: 16px;
169
- margin: 0 0 2px 0;
170
- display: block;
171
- overflow: hidden;
172
- text-overflow: ellipsis;
173
- }
174
- .a8ccharts-9wSZ6n {
175
- color: #1e1e1e;
176
- font-family: var(--step-font-family, "SF Pro");
177
- font-size: 13px;
178
- font-style: normal;
179
- font-weight: 500;
180
- line-height: 20px;
181
- margin: 0;
182
- display: block;
183
- }
184
- .a8ccharts-sSmCTi {
185
- flex: 1;
186
- display: flex;
187
- align-items: flex-end;
188
- border-radius: 4px;
189
- position: relative;
190
- cursor: pointer;
191
- transition: all 0.2s ease;
192
- }
193
- .a8ccharts-sSmCTi.a8ccharts-PLWVAW {
194
- cursor: pointer;
195
- }
196
- .a8ccharts-EzczI- {
197
- width: 100%;
198
- min-height: 4px;
199
- border-radius: 4px 4px 0 0;
200
- transition: all 0.3s ease;
201
- }
202
- .a8ccharts-EzczI-.a8ccharts-wNpZEu {
203
- box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
204
- filter: brightness(1.1);
205
- }
206
- .a8ccharts-68HQJl {
207
- transform-origin: bottom;
208
- transform-box: fill-box;
209
- transform: scaleY(0);
210
- animation: a8ccharts-CmtieZ 1s ease-out forwards;
211
- }
212
- @keyframes a8ccharts-CmtieZ {
213
- to {
214
- transform: scaleY(1);
215
- }
216
- }
217
- .a8ccharts-2TeoCn {
218
- display: inline-flex;
219
- flex-direction: column;
220
- justify-content: center;
221
- align-items: flex-start;
222
- gap: 4px;
223
- border-bottom: 1px solid var(--Gray-Gray-5, #dcdcde);
224
- background: var(--black-white-white, #fff);
225
- border-radius: 4px !important;
226
- padding: 12px !important;
227
- box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.15), 0 3px 9px 0 rgba(0, 0, 0, 0.12) !important;
228
- }
229
- .a8ccharts-jkRitH {
230
- color: #1e1e1e;
231
- font-family: "SF Pro", sans-serif;
232
- font-size: 12px;
233
- font-style: normal;
234
- font-weight: 400;
235
- line-height: 16px;
236
- }
237
- .a8ccharts-8jgT-3 {
238
- color: #1e1e1e;
239
- font-family: "SF Pro", sans-serif;
240
- font-size: 13px;
241
- font-style: normal;
242
- font-weight: 500;
243
- line-height: 20px;
244
- }
245
- .a8ccharts-Ml6MMr {
246
- text-align: center;
247
- padding: 48px 24px;
248
- color: #6b7280;
249
- font-size: 16px;
250
- }
251
- /*# sourceMappingURL=index.css.map */
@@ -1 +0,0 @@
1
- {"version":3,"sources":["esbuild-sass-plugin:css-chunk:src/hooks/use-tooltip-portal-relocator.module.scss","esbuild-sass-plugin:css-chunk:src/components/legend/private/base-legend.module.scss","esbuild-sass-plugin:css-chunk:src/charts/conversion-funnel-chart/conversion-funnel-chart.module.scss"],"sourcesContent":[".a8ccharts-jCw5dQ {\n position: fixed;\n inset: 0;\n overflow: visible;\n z-index: 1;\n pointer-events: none;\n}",".a8ccharts-AELBvX {\n display: flex;\n flex-direction: row;\n flex-wrap: wrap;\n gap: 16px;\n}\n.a8ccharts-fX8uQe {\n display: flex;\n flex-direction: column;\n gap: 8px;\n}\n.a8ccharts-fX8uQe.a8ccharts-DEe0wg {\n align-items: flex-start;\n}\n.a8ccharts-fX8uQe.a8ccharts-WBKF9I {\n align-items: center;\n}\n.a8ccharts-fX8uQe.a8ccharts-JfwMng {\n align-items: flex-end;\n}\n.a8ccharts-8Y73Kh {\n position: relative;\n}\n.a8ccharts-8Y73Kh.a8ccharts-DEe0wg {\n justify-content: flex-start;\n}\n.a8ccharts-8Y73Kh.a8ccharts-WBKF9I {\n justify-content: center;\n}\n.a8ccharts-8Y73Kh.a8ccharts-JfwMng {\n justify-content: flex-end;\n}\n.a8ccharts-TVM-IY {\n position: relative;\n}\n.a8ccharts-TVM-IY.a8ccharts-DEe0wg {\n justify-content: flex-start;\n}\n.a8ccharts-TVM-IY.a8ccharts-WBKF9I {\n justify-content: center;\n}\n.a8ccharts-TVM-IY.a8ccharts-JfwMng {\n justify-content: flex-end;\n}\n\n.a8ccharts-Vflwq8 {\n display: flex;\n align-items: center;\n font-size: 0.875rem;\n}\n.a8ccharts-qGsavM {\n cursor: pointer;\n user-select: none;\n transition: opacity 0.2s ease;\n}\n.a8ccharts-qGsavM:hover {\n opacity: 0.8;\n}\n.a8ccharts-qGsavM:focus {\n outline: 2px solid currentColor;\n outline-offset: 2px;\n border-radius: 4px;\n}\n.a8ccharts-qGsavM:focus:not(:focus-visible) {\n outline: none;\n}\n.a8ccharts-ZtDY-Q {\n opacity: 0.4;\n}\n.a8ccharts-ZtDY-Q .a8ccharts-2H65Kr {\n text-decoration: line-through;\n}\n\n.a8ccharts-2H65Kr {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n /* Text wrapping is handled at the text level, not the label container */\n}\n\n.a8ccharts-faSDBI {\n overflow-wrap: break-word;\n white-space: normal;\n hyphens: auto;\n}\n.a8ccharts-FISUIO {\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n flex-shrink: 1;\n min-width: 0;\n}\n\n.a8ccharts-DTZlT- {\n font-weight: 500;\n flex-shrink: 0;\n}",".a8ccharts-lK-YNK {\n font-family: var(--funnel-font-family, \"SF Pro Text\");\n}\n.a8ccharts-lK-YNK.a8ccharts-DbHKK5 {\n opacity: 0.6;\n pointer-events: none;\n}\n\n.a8ccharts-61WPYr {\n display: flex;\n align-items: baseline;\n gap: 8px;\n margin-bottom: 24px;\n height: 20px;\n}\n\n.a8ccharts-RRRI6x {\n overflow: hidden;\n color: #1e1e1e;\n text-overflow: ellipsis;\n font-family: var(--funnel-font-family, \"SF Pro Text\");\n font-size: 18px;\n font-style: normal;\n font-weight: 500;\n line-height: 20px;\n margin: 0;\n}\n\n.a8ccharts-661iwx {\n overflow: hidden;\n text-overflow: ellipsis;\n font-family: var(--funnel-font-family, \"SF Pro Text\");\n font-size: 13px;\n font-style: normal;\n font-weight: 500;\n line-height: 20px;\n margin: 0;\n}\n\n.a8ccharts-Z7EGnW {\n display: flex;\n gap: 16px;\n align-items: flex-end;\n flex: 1;\n min-height: 200px;\n width: 100%;\n}\n\n.a8ccharts-VqFY0l {\n flex: 1 1 0;\n min-width: 0;\n display: flex;\n flex-direction: column;\n height: 100%;\n transition: all 0.3s ease;\n}\n.a8ccharts-VqFY0l.a8ccharts-7dTRBs {\n opacity: 0.3;\n}\n\n.a8ccharts-2JsQiV {\n margin-bottom: 24px;\n}\n\n.a8ccharts-6OabC4 {\n color: #757575;\n font-family: var(--step-font-family, \"SF Pro\");\n font-size: 12px;\n font-style: normal;\n font-weight: 400;\n line-height: 16px;\n margin: 0 0 2px 0;\n display: block;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n\n.a8ccharts-9wSZ6n {\n color: #1e1e1e;\n font-family: var(--step-font-family, \"SF Pro\");\n font-size: 13px;\n font-style: normal;\n font-weight: 500;\n line-height: 20px;\n margin: 0;\n display: block;\n}\n\n.a8ccharts-sSmCTi {\n flex: 1;\n display: flex;\n align-items: flex-end;\n border-radius: 4px;\n position: relative;\n cursor: pointer;\n transition: all 0.2s ease;\n}\n.a8ccharts-sSmCTi.a8ccharts-PLWVAW {\n cursor: pointer;\n}\n\n.a8ccharts-EzczI- {\n width: 100%;\n min-height: 4px;\n border-radius: 4px 4px 0 0;\n transition: all 0.3s ease;\n}\n.a8ccharts-EzczI-.a8ccharts-wNpZEu {\n box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);\n filter: brightness(1.1);\n}\n.a8ccharts-68HQJl {\n transform-origin: bottom;\n transform-box: fill-box;\n transform: scaleY(0);\n animation: a8ccharts-CmtieZ 1s ease-out forwards;\n}\n@keyframes a8ccharts-CmtieZ {\n to {\n transform: scaleY(1);\n }\n}\n\n.a8ccharts-2TeoCn {\n display: inline-flex;\n flex-direction: column;\n justify-content: center;\n align-items: flex-start;\n gap: 4px;\n border-bottom: 1px solid var(--Gray-Gray-5, #dcdcde);\n background: var(--black-white-white, #fff);\n border-radius: 4px !important;\n padding: 12px !important;\n box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.15), 0 3px 9px 0 rgba(0, 0, 0, 0.12) !important;\n}\n\n.a8ccharts-jkRitH {\n color: #1e1e1e;\n font-family: \"SF Pro\", sans-serif;\n font-size: 12px;\n font-style: normal;\n font-weight: 400;\n line-height: 16px;\n}\n\n.a8ccharts-8jgT-3 {\n color: #1e1e1e;\n font-family: \"SF Pro\", sans-serif;\n font-size: 13px;\n font-style: normal;\n font-weight: 500;\n line-height: 20px;\n}\n\n.a8ccharts-Ml6MMr {\n text-align: center;\n padding: 48px 24px;\n color: #6b7280;\n font-size: 16px;\n}"],"mappings":"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","names":[]}
@@ -1,97 +0,0 @@
1
- import { FC } from 'react';
2
- import { B as BaseChartProps } from '../../types-DZordNiO.cjs';
3
- import '@visx/annotation/lib/components/CircleSubject';
4
- import '@visx/annotation/lib/components/Connector';
5
- import '@visx/annotation/lib/components/Label';
6
- import '@visx/annotation/lib/components/LineSubject';
7
- import '@visx/axis';
8
- import '@visx/legend/lib/types';
9
- import '@visx/scale';
10
- import '@visx/text/lib/Text';
11
- import '@visx/xychart';
12
- import '@wordpress/theme';
13
- import 'react-google-charts';
14
-
15
- /**
16
- * Represents a single step in the conversion funnel
17
- */
18
- interface FunnelStep {
19
- /** Step identifier */
20
- id: string;
21
- /** Display label for the step */
22
- label: string;
23
- /** Conversion rate as percentage (0-100) */
24
- rate: number;
25
- /** Absolute count (optional, for tooltip/details) */
26
- count?: number;
27
- }
28
- /**
29
- * Render prop for customizing step labels
30
- */
31
- interface StepLabelRenderProps {
32
- step: FunnelStep;
33
- index: number;
34
- className?: string;
35
- }
36
- /**
37
- * Render prop for customizing step rates
38
- */
39
- interface StepRateRenderProps {
40
- step: FunnelStep;
41
- index: number;
42
- className?: string;
43
- }
44
- /**
45
- * Render prop for customizing the entire main metric section
46
- */
47
- interface MainMetricRenderProps {
48
- mainRate: number;
49
- changeIndicator?: string;
50
- className?: string;
51
- changeColor?: string;
52
- }
53
- /**
54
- * Render prop for customizing tooltip content
55
- */
56
- interface TooltipRenderProps {
57
- step: FunnelStep;
58
- index: number;
59
- top: number;
60
- left: number;
61
- className?: string;
62
- }
63
- /**
64
- * Props for the ConversionFunnelChart component
65
- */
66
- interface ConversionFunnelChartProps extends Pick<BaseChartProps, 'className' | 'chartId' | 'animation'> {
67
- /** Main conversion rate to highlight */
68
- mainRate: number;
69
- /** Change indicator (e.g., +2%, -1.5%) */
70
- changeIndicator?: string;
71
- /** Array of funnel steps */
72
- steps: FunnelStep[];
73
- /** Whether the chart is in loading state */
74
- loading?: boolean;
75
- /** Height of the chart container. Accepts a number (pixels) or CSS string (e.g., "400px", "100%"). Falls back to style.height if set, otherwise defaults to "100%". */
76
- height?: string | number;
77
- /** Custom styling */
78
- style?: React.CSSProperties;
79
- /** Custom render function for step labels */
80
- renderStepLabel?: (props: StepLabelRenderProps) => React.ReactNode;
81
- /** Custom render function for step rates */
82
- renderStepRate?: (props: StepRateRenderProps) => React.ReactNode;
83
- /** Custom render function for the entire main metric section */
84
- renderMainMetric?: (props: MainMetricRenderProps) => React.ReactNode;
85
- /** Custom render function for tooltip content */
86
- renderTooltip?: (props: TooltipRenderProps) => React.ReactNode;
87
- }
88
-
89
- /**
90
- * ConversionFunnelChart component with provider wrapper
91
- *
92
- * @param props - Component props
93
- * @return JSX element representing the conversion funnel chart
94
- */
95
- declare const ConversionFunnelChartWithProvider: FC<ConversionFunnelChartProps>;
96
-
97
- export { ConversionFunnelChartWithProvider as ConversionFunnelChart, type ConversionFunnelChartProps, type FunnelStep, type MainMetricRenderProps, type StepLabelRenderProps, type StepRateRenderProps, type TooltipRenderProps };
@@ -1,97 +0,0 @@
1
- import { FC } from 'react';
2
- import { B as BaseChartProps } from '../../types-DZordNiO.js';
3
- import '@visx/annotation/lib/components/CircleSubject';
4
- import '@visx/annotation/lib/components/Connector';
5
- import '@visx/annotation/lib/components/Label';
6
- import '@visx/annotation/lib/components/LineSubject';
7
- import '@visx/axis';
8
- import '@visx/legend/lib/types';
9
- import '@visx/scale';
10
- import '@visx/text/lib/Text';
11
- import '@visx/xychart';
12
- import '@wordpress/theme';
13
- import 'react-google-charts';
14
-
15
- /**
16
- * Represents a single step in the conversion funnel
17
- */
18
- interface FunnelStep {
19
- /** Step identifier */
20
- id: string;
21
- /** Display label for the step */
22
- label: string;
23
- /** Conversion rate as percentage (0-100) */
24
- rate: number;
25
- /** Absolute count (optional, for tooltip/details) */
26
- count?: number;
27
- }
28
- /**
29
- * Render prop for customizing step labels
30
- */
31
- interface StepLabelRenderProps {
32
- step: FunnelStep;
33
- index: number;
34
- className?: string;
35
- }
36
- /**
37
- * Render prop for customizing step rates
38
- */
39
- interface StepRateRenderProps {
40
- step: FunnelStep;
41
- index: number;
42
- className?: string;
43
- }
44
- /**
45
- * Render prop for customizing the entire main metric section
46
- */
47
- interface MainMetricRenderProps {
48
- mainRate: number;
49
- changeIndicator?: string;
50
- className?: string;
51
- changeColor?: string;
52
- }
53
- /**
54
- * Render prop for customizing tooltip content
55
- */
56
- interface TooltipRenderProps {
57
- step: FunnelStep;
58
- index: number;
59
- top: number;
60
- left: number;
61
- className?: string;
62
- }
63
- /**
64
- * Props for the ConversionFunnelChart component
65
- */
66
- interface ConversionFunnelChartProps extends Pick<BaseChartProps, 'className' | 'chartId' | 'animation'> {
67
- /** Main conversion rate to highlight */
68
- mainRate: number;
69
- /** Change indicator (e.g., +2%, -1.5%) */
70
- changeIndicator?: string;
71
- /** Array of funnel steps */
72
- steps: FunnelStep[];
73
- /** Whether the chart is in loading state */
74
- loading?: boolean;
75
- /** Height of the chart container. Accepts a number (pixels) or CSS string (e.g., "400px", "100%"). Falls back to style.height if set, otherwise defaults to "100%". */
76
- height?: string | number;
77
- /** Custom styling */
78
- style?: React.CSSProperties;
79
- /** Custom render function for step labels */
80
- renderStepLabel?: (props: StepLabelRenderProps) => React.ReactNode;
81
- /** Custom render function for step rates */
82
- renderStepRate?: (props: StepRateRenderProps) => React.ReactNode;
83
- /** Custom render function for the entire main metric section */
84
- renderMainMetric?: (props: MainMetricRenderProps) => React.ReactNode;
85
- /** Custom render function for tooltip content */
86
- renderTooltip?: (props: TooltipRenderProps) => React.ReactNode;
87
- }
88
-
89
- /**
90
- * ConversionFunnelChart component with provider wrapper
91
- *
92
- * @param props - Component props
93
- * @return JSX element representing the conversion funnel chart
94
- */
95
- declare const ConversionFunnelChartWithProvider: FC<ConversionFunnelChartProps>;
96
-
97
- export { ConversionFunnelChartWithProvider as ConversionFunnelChart, type ConversionFunnelChartProps, type FunnelStep, type MainMetricRenderProps, type StepLabelRenderProps, type StepRateRenderProps, type TooltipRenderProps };
@@ -1,11 +0,0 @@
1
- import {
2
- ConversionFunnelChartWithProvider
3
- } from "../../chunk-CZGYJKG6.js";
4
- import "../../chunk-Z26M4V2M.js";
5
- import "../../chunk-32DH6JDF.js";
6
- import "../../chunk-DAU3HNEG.js";
7
- import "../../chunk-G3PMV62Z.js";
8
- export {
9
- ConversionFunnelChartWithProvider as ConversionFunnelChart
10
- };
11
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
@@ -1,13 +0,0 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
-
3
-
4
- var _chunkD2UH4CFEcjs = require('../../chunk-D2UH4CFE.cjs');
5
- require('../../chunk-ASLARV7L.cjs');
6
- require('../../chunk-RHHVEJHJ.cjs');
7
- require('../../chunk-VTS3PNMS.cjs');
8
- require('../../chunk-EMMSS5I5.cjs');
9
-
10
-
11
-
12
- exports.GeoChart = _chunkD2UH4CFEcjs.GeoChartResponsive; exports.GeoChartUnresponsive = _chunkD2UH4CFEcjs.GeoChartWithProvider;
13
- //# sourceMappingURL=index.cjs.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["/home/runner/work/jetpack/jetpack/projects/js-packages/charts/dist/charts/geo-chart/index.cjs"],"names":[],"mappings":"AAAA;AACE;AACA;AACF,4DAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC,oCAAiC;AACjC;AACE;AACA;AACF,+HAAC","file":"/home/runner/work/jetpack/jetpack/projects/js-packages/charts/dist/charts/geo-chart/index.cjs"}
@@ -1,117 +0,0 @@
1
- /* esbuild-sass-plugin:css-chunk:src/hooks/use-tooltip-portal-relocator.module.scss */
2
- .a8ccharts-jCw5dQ {
3
- position: fixed;
4
- inset: 0;
5
- overflow: visible;
6
- z-index: 1;
7
- pointer-events: none;
8
- }
9
-
10
- /* esbuild-sass-plugin:css-chunk:src/components/legend/private/base-legend.module.scss */
11
- .a8ccharts-AELBvX {
12
- display: flex;
13
- flex-direction: row;
14
- flex-wrap: wrap;
15
- gap: 16px;
16
- }
17
- .a8ccharts-fX8uQe {
18
- display: flex;
19
- flex-direction: column;
20
- gap: 8px;
21
- }
22
- .a8ccharts-fX8uQe.a8ccharts-DEe0wg {
23
- align-items: flex-start;
24
- }
25
- .a8ccharts-fX8uQe.a8ccharts-WBKF9I {
26
- align-items: center;
27
- }
28
- .a8ccharts-fX8uQe.a8ccharts-JfwMng {
29
- align-items: flex-end;
30
- }
31
- .a8ccharts-8Y73Kh {
32
- position: relative;
33
- }
34
- .a8ccharts-8Y73Kh.a8ccharts-DEe0wg {
35
- justify-content: flex-start;
36
- }
37
- .a8ccharts-8Y73Kh.a8ccharts-WBKF9I {
38
- justify-content: center;
39
- }
40
- .a8ccharts-8Y73Kh.a8ccharts-JfwMng {
41
- justify-content: flex-end;
42
- }
43
- .a8ccharts-TVM-IY {
44
- position: relative;
45
- }
46
- .a8ccharts-TVM-IY.a8ccharts-DEe0wg {
47
- justify-content: flex-start;
48
- }
49
- .a8ccharts-TVM-IY.a8ccharts-WBKF9I {
50
- justify-content: center;
51
- }
52
- .a8ccharts-TVM-IY.a8ccharts-JfwMng {
53
- justify-content: flex-end;
54
- }
55
- .a8ccharts-Vflwq8 {
56
- display: flex;
57
- align-items: center;
58
- font-size: 0.875rem;
59
- }
60
- .a8ccharts-qGsavM {
61
- cursor: pointer;
62
- user-select: none;
63
- transition: opacity 0.2s ease;
64
- }
65
- .a8ccharts-qGsavM:hover {
66
- opacity: 0.8;
67
- }
68
- .a8ccharts-qGsavM:focus {
69
- outline: 2px solid currentColor;
70
- outline-offset: 2px;
71
- border-radius: 4px;
72
- }
73
- .a8ccharts-qGsavM:focus:not(:focus-visible) {
74
- outline: none;
75
- }
76
- .a8ccharts-ZtDY-Q {
77
- opacity: 0.4;
78
- }
79
- .a8ccharts-ZtDY-Q .a8ccharts-2H65Kr {
80
- text-decoration: line-through;
81
- }
82
- .a8ccharts-2H65Kr {
83
- display: flex;
84
- align-items: center;
85
- gap: 0.5rem;
86
- }
87
- .a8ccharts-faSDBI {
88
- overflow-wrap: break-word;
89
- white-space: normal;
90
- hyphens: auto;
91
- }
92
- .a8ccharts-FISUIO {
93
- white-space: nowrap;
94
- overflow: hidden;
95
- text-overflow: ellipsis;
96
- flex-shrink: 1;
97
- min-width: 0;
98
- }
99
- .a8ccharts-DTZlT- {
100
- font-weight: 500;
101
- flex-shrink: 0;
102
- }
103
-
104
- /* esbuild-sass-plugin:css-chunk:src/charts/private/with-responsive/with-responsive.module.scss */
105
- .a8ccharts-GSKfBD {
106
- min-width: 0;
107
- min-height: 0;
108
- }
109
-
110
- /* esbuild-sass-plugin:css-chunk:src/charts/geo-chart/geo-chart.module.scss */
111
- .a8ccharts-JvcqOz {
112
- position: relative;
113
- display: flex;
114
- justify-content: center;
115
- align-items: center;
116
- }
117
- /*# sourceMappingURL=index.css.map */
@@ -1 +0,0 @@
1
- {"version":3,"sources":["esbuild-sass-plugin:css-chunk:src/hooks/use-tooltip-portal-relocator.module.scss","esbuild-sass-plugin:css-chunk:src/components/legend/private/base-legend.module.scss","esbuild-sass-plugin:css-chunk:src/charts/private/with-responsive/with-responsive.module.scss","esbuild-sass-plugin:css-chunk:src/charts/geo-chart/geo-chart.module.scss"],"sourcesContent":[".a8ccharts-jCw5dQ {\n position: fixed;\n inset: 0;\n overflow: visible;\n z-index: 1;\n pointer-events: none;\n}",".a8ccharts-AELBvX {\n display: flex;\n flex-direction: row;\n flex-wrap: wrap;\n gap: 16px;\n}\n.a8ccharts-fX8uQe {\n display: flex;\n flex-direction: column;\n gap: 8px;\n}\n.a8ccharts-fX8uQe.a8ccharts-DEe0wg {\n align-items: flex-start;\n}\n.a8ccharts-fX8uQe.a8ccharts-WBKF9I {\n align-items: center;\n}\n.a8ccharts-fX8uQe.a8ccharts-JfwMng {\n align-items: flex-end;\n}\n.a8ccharts-8Y73Kh {\n position: relative;\n}\n.a8ccharts-8Y73Kh.a8ccharts-DEe0wg {\n justify-content: flex-start;\n}\n.a8ccharts-8Y73Kh.a8ccharts-WBKF9I {\n justify-content: center;\n}\n.a8ccharts-8Y73Kh.a8ccharts-JfwMng {\n justify-content: flex-end;\n}\n.a8ccharts-TVM-IY {\n position: relative;\n}\n.a8ccharts-TVM-IY.a8ccharts-DEe0wg {\n justify-content: flex-start;\n}\n.a8ccharts-TVM-IY.a8ccharts-WBKF9I {\n justify-content: center;\n}\n.a8ccharts-TVM-IY.a8ccharts-JfwMng {\n justify-content: flex-end;\n}\n\n.a8ccharts-Vflwq8 {\n display: flex;\n align-items: center;\n font-size: 0.875rem;\n}\n.a8ccharts-qGsavM {\n cursor: pointer;\n user-select: none;\n transition: opacity 0.2s ease;\n}\n.a8ccharts-qGsavM:hover {\n opacity: 0.8;\n}\n.a8ccharts-qGsavM:focus {\n outline: 2px solid currentColor;\n outline-offset: 2px;\n border-radius: 4px;\n}\n.a8ccharts-qGsavM:focus:not(:focus-visible) {\n outline: none;\n}\n.a8ccharts-ZtDY-Q {\n opacity: 0.4;\n}\n.a8ccharts-ZtDY-Q .a8ccharts-2H65Kr {\n text-decoration: line-through;\n}\n\n.a8ccharts-2H65Kr {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n /* Text wrapping is handled at the text level, not the label container */\n}\n\n.a8ccharts-faSDBI {\n overflow-wrap: break-word;\n white-space: normal;\n hyphens: auto;\n}\n.a8ccharts-FISUIO {\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n flex-shrink: 1;\n min-width: 0;\n}\n\n.a8ccharts-DTZlT- {\n font-weight: 500;\n flex-shrink: 0;\n}",".a8ccharts-GSKfBD {\n min-width: 0;\n min-height: 0;\n}",".a8ccharts-JvcqOz {\n position: relative;\n display: flex;\n justify-content: center;\n align-items: center;\n}"],"mappings":";AAAA,CAAC;AACC,YAAU;AACV,SAAO;AACP,YAAU;AACV,WAAS;AACT,kBAAgB;AAClB;;;ACNA,CAAC;AACC,WAAS;AACT,kBAAgB;AAChB,aAAW;AACX,OAAK;AACP;AACA,CAAC;AACC,WAAS;AACT,kBAAgB;AAChB,OAAK;AACP;AACA,CALC,gBAKgB,CAAC;AAChB,eAAa;AACf;AACA,CARC,gBAQgB,CAAC;AAChB,eAAa;AACf;AACA,CAXC,gBAWgB,CAAC;AAChB,eAAa;AACf;AACA,CAAC;AACC,YAAU;AACZ;AACA,CAHC,gBAGgB,CAZC;AAahB,mBAAiB;AACnB;AACA,CANC,gBAMgB,CAZC;AAahB,mBAAiB;AACnB;AACA,CATC,gBASgB,CAZC;AAahB,mBAAiB;AACnB;AACA,CAAC;AACC,YAAU;AACZ;AACA,CAHC,gBAGgB,CAxBC;AAyBhB,mBAAiB;AACnB;AACA,CANC,gBAMgB,CAxBC;AAyBhB,mBAAiB;AACnB;AACA,CATC,gBASgB,CAxBC;AAyBhB,mBAAiB;AACnB;AAEA,CAAC;AACC,WAAS;AACT,eAAa;AACb,aAAW;AACb;AACA,CAAC;AACC,UAAQ;AACR,eAAa;AACb,cAAY,QAAQ,KAAK;AAC3B;AACA,CALC,gBAKgB;AACf,WAAS;AACX;AACA,CARC,gBAQgB;AACf,WAAS,IAAI,MAAM;AACnB,kBAAgB;AAChB,iBAAe;AACjB;AACA,CAbC,gBAagB,MAAM,KAAK;AAC1B,WAAS;AACX;AACA,CAAC;AACC,WAAS;AACX;AACA,CAHC,iBAGiB,CAAC;AACjB,mBAAiB;AACnB;AAEA,CAJmB;AAKjB,WAAS;AACT,eAAa;AACb,OAAK;AAEP;AAEA,CAAC;AACC,iBAAe;AACf,eAAa;AACb,WAAS;AACX;AACA,CAAC;AACC,eAAa;AACb,YAAU;AACV,iBAAe;AACf,eAAa;AACb,aAAW;AACb;AAEA,CAAC;AACC,eAAa;AACb,eAAa;AACf;;;AChGA,CAAC;AACC,aAAW;AACX,cAAY;AACd;;;ACHA,CAAC;AACC,YAAU;AACV,WAAS;AACT,mBAAiB;AACjB,eAAa;AACf;","names":[]}
@@ -1,67 +0,0 @@
1
- import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { R as ResponsiveConfig } from '../../with-responsive-CNfhzAUu.cjs';
3
- import { FC } from 'react';
4
- import { B as BaseChartProps, G as GeoData } from '../../types-DZordNiO.cjs';
5
- import '@visx/annotation/lib/components/CircleSubject';
6
- import '@visx/annotation/lib/components/Connector';
7
- import '@visx/annotation/lib/components/Label';
8
- import '@visx/annotation/lib/components/LineSubject';
9
- import '@visx/axis';
10
- import '@visx/legend/lib/types';
11
- import '@visx/scale';
12
- import '@visx/text/lib/Text';
13
- import '@visx/xychart';
14
- import '@wordpress/theme';
15
- import 'react-google-charts';
16
-
17
- /**
18
- * Region to display on the map.
19
- * Use 'world' for global view or any ISO 3166-1 alpha-2 country code
20
- * (e.g., 'US' for United States, 'CA' for Canada).
21
- */
22
- type GeoRegion = 'world' | (string & {});
23
- /**
24
- * Resolution level for the map.
25
- * - 'countries': Country-level (default for 'world')
26
- * - 'provinces': State/province level (use with specific region like 'US')
27
- * - 'metros': Metropolitan areas (US only)
28
- */
29
- type GeoResolution = 'countries' | 'provinces' | 'metros';
30
- interface GeoChartProps extends Pick<BaseChartProps, 'className' | 'chartId' | 'width' | 'height'> {
31
- /**
32
- * Data in Google Charts native format for maximum flexibility.
33
- * First row contains column headers, subsequent rows contain data.
34
- *
35
- * Country identifiers can be either full country names or ISO 3166-1 alpha-2 codes
36
- * (e.g., 'United States' or 'US').
37
- */
38
- data: GeoData;
39
- /**
40
- * Region to display. Use 'world' for global view, 'US' for United States,
41
- * or any ISO 3166-1 alpha-2 country code.
42
- * @default 'world'
43
- */
44
- region?: GeoRegion;
45
- /**
46
- * Resolution level for the map.
47
- * - 'countries': Country-level (default for 'world')
48
- * - 'provinces': State/province level (use with specific region like 'US')
49
- * - 'metros': Metropolitan areas (US only)
50
- * @default 'countries'
51
- */
52
- resolution?: GeoResolution;
53
- /**
54
- * Optional render function for the loading placeholder.
55
- * Called while Google Charts is loading.
56
- */
57
- renderPlaceholder?: () => React.ReactNode;
58
- }
59
-
60
- declare const GeoChartWithProvider: FC<GeoChartProps>;
61
- declare const GeoChartResponsive: ({ resizeDebounceTime, maxWidth, aspectRatio, size, width, height, ...chartProps }: Omit<GeoChartProps, "width" | "height" | "size"> & {
62
- width?: number;
63
- height?: number;
64
- size?: number;
65
- } & ResponsiveConfig) => react_jsx_runtime.JSX.Element;
66
-
67
- export { GeoChartResponsive as GeoChart, type GeoChartProps, GeoChartWithProvider as GeoChartUnresponsive, type GeoRegion, type GeoResolution };