@ktnpm_devops/react-component 0.16.0 → 0.17.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 (391) hide show
  1. package/README.md +38 -2
  2. package/dist/constants.d.ts +7 -3
  3. package/dist/constants.d.ts.map +1 -1
  4. package/dist/geo/GeoMapCard/GeoMapCard.d.ts +1 -1
  5. package/dist/geo/GeoMapCard/GeoMapCard.d.ts.map +1 -1
  6. package/dist/geo/GeoMapCard/GeoMapCard.types.d.ts +28 -2
  7. package/dist/geo/GeoMapCard/GeoMapCard.types.d.ts.map +1 -1
  8. package/dist/geo/GeoMapCard/MapStatusBars.d.ts +11 -0
  9. package/dist/geo/GeoMapCard/MapStatusBars.d.ts.map +1 -0
  10. package/dist/geo/GeoMapCard/ViewportReporter.d.ts +15 -0
  11. package/dist/geo/GeoMapCard/ViewportReporter.d.ts.map +1 -0
  12. package/dist/geo/GeoMapCard/describePoints.d.ts +7 -0
  13. package/dist/geo/GeoMapCard/describePoints.d.ts.map +1 -0
  14. package/dist/geo/GeoMapCard/normalizeViewport.d.ts +13 -0
  15. package/dist/geo/GeoMapCard/normalizeViewport.d.ts.map +1 -0
  16. package/dist/geo/GeoMapCard/normalizeViewport.test.d.ts +2 -0
  17. package/dist/geo/GeoMapCard/normalizeViewport.test.d.ts.map +1 -0
  18. package/dist/geo/GeoMapCard/resolveTiles.d.ts +9 -0
  19. package/dist/geo/GeoMapCard/resolveTiles.d.ts.map +1 -0
  20. package/dist/geo/GeoMapCard/warnMissingBasemapKey.d.ts +9 -0
  21. package/dist/geo/GeoMapCard/warnMissingBasemapKey.d.ts.map +1 -0
  22. package/dist/index.d.ts +1 -1
  23. package/dist/index.d.ts.map +1 -1
  24. package/dist/index10.cjs +1 -1
  25. package/dist/index10.js +1 -1
  26. package/dist/index100.cjs +39 -39
  27. package/dist/index100.cjs.map +1 -1
  28. package/dist/index100.js +38 -38
  29. package/dist/index100.js.map +1 -1
  30. package/dist/index101.cjs +9 -58
  31. package/dist/index101.cjs.map +1 -1
  32. package/dist/index101.js +8 -57
  33. package/dist/index101.js.map +1 -1
  34. package/dist/index102.cjs +9 -38
  35. package/dist/index102.cjs.map +1 -1
  36. package/dist/index102.js +10 -39
  37. package/dist/index102.js.map +1 -1
  38. package/dist/index103.cjs +19 -92
  39. package/dist/index103.cjs.map +1 -1
  40. package/dist/index103.js +19 -92
  41. package/dist/index103.js.map +1 -1
  42. package/dist/index104.cjs +14 -40
  43. package/dist/index104.cjs.map +1 -1
  44. package/dist/index104.js +13 -39
  45. package/dist/index104.js.map +1 -1
  46. package/dist/index105.cjs +8 -113
  47. package/dist/index105.cjs.map +1 -1
  48. package/dist/index105.js +8 -113
  49. package/dist/index105.js.map +1 -1
  50. package/dist/index106.cjs +51 -24
  51. package/dist/index106.cjs.map +1 -1
  52. package/dist/index106.js +52 -25
  53. package/dist/index106.js.map +1 -1
  54. package/dist/index107.cjs +9 -15
  55. package/dist/index107.cjs.map +1 -1
  56. package/dist/index107.js +10 -16
  57. package/dist/index107.js.map +1 -1
  58. package/dist/index108.cjs +48 -10
  59. package/dist/index108.cjs.map +1 -1
  60. package/dist/index108.js +47 -9
  61. package/dist/index108.js.map +1 -1
  62. package/dist/index109.cjs +16 -34
  63. package/dist/index109.cjs.map +1 -1
  64. package/dist/index109.js +16 -34
  65. package/dist/index109.js.map +1 -1
  66. package/dist/index110.cjs +36 -43
  67. package/dist/index110.cjs.map +1 -1
  68. package/dist/index110.js +35 -42
  69. package/dist/index110.js.map +1 -1
  70. package/dist/index111.cjs +54 -24
  71. package/dist/index111.cjs.map +1 -1
  72. package/dist/index111.js +53 -23
  73. package/dist/index111.js.map +1 -1
  74. package/dist/index112.cjs +40 -20
  75. package/dist/index112.cjs.map +1 -1
  76. package/dist/index112.js +39 -19
  77. package/dist/index112.js.map +1 -1
  78. package/dist/index113.cjs +16 -14
  79. package/dist/index113.cjs.map +1 -1
  80. package/dist/index113.js +15 -13
  81. package/dist/index113.js.map +1 -1
  82. package/dist/index114.cjs +15 -54
  83. package/dist/index114.cjs.map +1 -1
  84. package/dist/index114.js +16 -55
  85. package/dist/index114.js.map +1 -1
  86. package/dist/index115.cjs +36 -18
  87. package/dist/index115.cjs.map +1 -1
  88. package/dist/index115.js +36 -18
  89. package/dist/index115.js.map +1 -1
  90. package/dist/index116.cjs +64 -13
  91. package/dist/index116.cjs.map +1 -1
  92. package/dist/index116.js +65 -14
  93. package/dist/index116.js.map +1 -1
  94. package/dist/index117.cjs +52 -16
  95. package/dist/index117.cjs.map +1 -1
  96. package/dist/index117.js +52 -16
  97. package/dist/index117.js.map +1 -1
  98. package/dist/index119.cjs +16 -34
  99. package/dist/index119.cjs.map +1 -1
  100. package/dist/index119.js +16 -34
  101. package/dist/index119.js.map +1 -1
  102. package/dist/index12.cjs +1 -1
  103. package/dist/index12.js +1 -1
  104. package/dist/index120.cjs +16 -46
  105. package/dist/index120.cjs.map +1 -1
  106. package/dist/index120.js +16 -46
  107. package/dist/index120.js.map +1 -1
  108. package/dist/index121.cjs +7 -18
  109. package/dist/index121.cjs.map +1 -1
  110. package/dist/index121.js +6 -17
  111. package/dist/index121.js.map +1 -1
  112. package/dist/index122.cjs +15 -33
  113. package/dist/index122.cjs.map +1 -1
  114. package/dist/index122.js +15 -33
  115. package/dist/index122.js.map +1 -1
  116. package/dist/index123.cjs +2 -38
  117. package/dist/index123.cjs.map +1 -1
  118. package/dist/index123.js +3 -39
  119. package/dist/index123.js.map +1 -1
  120. package/dist/index124.cjs +19 -1164
  121. package/dist/index124.cjs.map +1 -1
  122. package/dist/index124.js +17 -1163
  123. package/dist/index124.js.map +1 -1
  124. package/dist/index125.cjs +84 -1575
  125. package/dist/index125.cjs.map +1 -1
  126. package/dist/index125.js +83 -1575
  127. package/dist/index125.js.map +1 -1
  128. package/dist/index126.cjs +24 -0
  129. package/dist/index126.cjs.map +1 -0
  130. package/dist/index126.js +24 -0
  131. package/dist/index126.js.map +1 -0
  132. package/dist/index127.cjs +36 -0
  133. package/dist/index127.cjs.map +1 -0
  134. package/dist/index127.js +36 -0
  135. package/dist/index127.js.map +1 -0
  136. package/dist/index128.cjs +1166 -0
  137. package/dist/index128.cjs.map +1 -0
  138. package/dist/index128.js +1167 -0
  139. package/dist/index128.js.map +1 -0
  140. package/dist/index129.cjs +1578 -0
  141. package/dist/index129.cjs.map +1 -0
  142. package/dist/index129.js +1579 -0
  143. package/dist/index129.js.map +1 -0
  144. package/dist/index13.cjs +1 -1
  145. package/dist/index13.js +1 -1
  146. package/dist/index130.cjs +37 -0
  147. package/dist/index130.cjs.map +1 -0
  148. package/dist/index130.js +37 -0
  149. package/dist/index130.js.map +1 -0
  150. package/dist/index14.cjs +1 -1
  151. package/dist/index14.js +1 -1
  152. package/dist/index15.cjs +1 -1
  153. package/dist/index15.js +1 -1
  154. package/dist/index16.cjs +2 -2
  155. package/dist/index16.js +2 -2
  156. package/dist/index17.cjs +1 -1
  157. package/dist/index17.js +1 -1
  158. package/dist/index19.cjs +1 -1
  159. package/dist/index19.js +1 -1
  160. package/dist/index20.cjs +1 -1
  161. package/dist/index20.js +1 -1
  162. package/dist/index21.cjs +1 -1
  163. package/dist/index21.js +1 -1
  164. package/dist/index22.cjs +2 -2
  165. package/dist/index22.js +2 -2
  166. package/dist/index23.cjs +2 -2
  167. package/dist/index23.js +2 -2
  168. package/dist/index24.cjs +2 -2
  169. package/dist/index24.js +2 -2
  170. package/dist/index25.cjs +1 -1
  171. package/dist/index25.js +1 -1
  172. package/dist/index26.cjs +1 -1
  173. package/dist/index26.js +1 -1
  174. package/dist/index27.cjs +1 -1
  175. package/dist/index27.js +1 -1
  176. package/dist/index28.cjs +1 -1
  177. package/dist/index28.js +1 -1
  178. package/dist/index29.cjs +2 -2
  179. package/dist/index29.js +2 -2
  180. package/dist/index30.cjs +37 -35
  181. package/dist/index30.cjs.map +1 -1
  182. package/dist/index30.js +35 -33
  183. package/dist/index30.js.map +1 -1
  184. package/dist/index31.cjs +4 -4
  185. package/dist/index31.js +4 -4
  186. package/dist/index32.cjs +3 -3
  187. package/dist/index32.js +3 -3
  188. package/dist/index33.cjs +1 -1
  189. package/dist/index33.js +1 -1
  190. package/dist/index34.cjs +2 -2
  191. package/dist/index34.js +2 -2
  192. package/dist/index35.cjs +2 -2
  193. package/dist/index35.js +2 -2
  194. package/dist/index36.cjs +2 -2
  195. package/dist/index36.js +2 -2
  196. package/dist/index37.cjs +1 -1
  197. package/dist/index37.js +1 -1
  198. package/dist/index38.cjs +2 -2
  199. package/dist/index38.js +2 -2
  200. package/dist/index39.cjs +1 -1
  201. package/dist/index39.js +1 -1
  202. package/dist/index40.cjs +2 -2
  203. package/dist/index40.js +2 -2
  204. package/dist/index41.cjs +2 -2
  205. package/dist/index41.js +2 -2
  206. package/dist/index42.cjs +2 -2
  207. package/dist/index42.js +2 -2
  208. package/dist/index43.cjs +1 -1
  209. package/dist/index43.js +1 -1
  210. package/dist/index44.cjs +2 -2
  211. package/dist/index44.js +2 -2
  212. package/dist/index45.cjs +4 -4
  213. package/dist/index45.js +4 -4
  214. package/dist/index46.cjs +1 -1
  215. package/dist/index46.js +1 -1
  216. package/dist/index47.cjs +1 -1
  217. package/dist/index47.js +1 -1
  218. package/dist/index48.cjs +1 -1
  219. package/dist/index48.js +1 -1
  220. package/dist/index49.cjs +2 -2
  221. package/dist/index49.js +2 -2
  222. package/dist/index50.cjs +2 -2
  223. package/dist/index50.js +2 -2
  224. package/dist/index51.cjs +1 -1
  225. package/dist/index51.js +1 -1
  226. package/dist/index52.cjs +3 -3
  227. package/dist/index52.js +3 -3
  228. package/dist/index53.cjs +1 -1
  229. package/dist/index53.js +1 -1
  230. package/dist/index54.cjs +1 -1
  231. package/dist/index54.js +1 -1
  232. package/dist/index55.cjs +3 -3
  233. package/dist/index55.js +3 -3
  234. package/dist/index56.cjs +1 -1
  235. package/dist/index56.js +1 -1
  236. package/dist/index57.cjs +1 -1
  237. package/dist/index57.js +1 -1
  238. package/dist/index58.cjs +2 -2
  239. package/dist/index58.js +2 -2
  240. package/dist/index60.cjs +13 -22
  241. package/dist/index60.cjs.map +1 -1
  242. package/dist/index60.js +13 -22
  243. package/dist/index60.js.map +1 -1
  244. package/dist/index61.cjs +18 -21
  245. package/dist/index61.cjs.map +1 -1
  246. package/dist/index61.js +19 -22
  247. package/dist/index61.js.map +1 -1
  248. package/dist/index62.cjs +13 -13
  249. package/dist/index62.js +13 -13
  250. package/dist/index63.cjs +10 -143
  251. package/dist/index63.cjs.map +1 -1
  252. package/dist/index63.js +8 -141
  253. package/dist/index63.js.map +1 -1
  254. package/dist/index64.cjs +143 -25
  255. package/dist/index64.cjs.map +1 -1
  256. package/dist/index64.js +141 -23
  257. package/dist/index64.js.map +1 -1
  258. package/dist/index65.cjs +16 -13
  259. package/dist/index65.cjs.map +1 -1
  260. package/dist/index65.js +17 -14
  261. package/dist/index65.js.map +1 -1
  262. package/dist/index66.cjs +19 -13
  263. package/dist/index66.cjs.map +1 -1
  264. package/dist/index66.js +20 -14
  265. package/dist/index66.js.map +1 -1
  266. package/dist/index68.cjs +35 -14
  267. package/dist/index68.cjs.map +1 -1
  268. package/dist/index68.js +36 -15
  269. package/dist/index68.js.map +1 -1
  270. package/dist/index69.cjs +28 -28
  271. package/dist/index69.js +28 -28
  272. package/dist/index70.cjs +19 -19
  273. package/dist/index70.js +20 -20
  274. package/dist/index71.cjs +4 -46
  275. package/dist/index71.cjs.map +1 -1
  276. package/dist/index71.js +5 -47
  277. package/dist/index71.js.map +1 -1
  278. package/dist/index72.cjs +116 -7
  279. package/dist/index72.cjs.map +1 -1
  280. package/dist/index72.js +115 -6
  281. package/dist/index72.js.map +1 -1
  282. package/dist/index73.cjs +35 -77
  283. package/dist/index73.cjs.map +1 -1
  284. package/dist/index73.js +35 -77
  285. package/dist/index73.js.map +1 -1
  286. package/dist/index74.cjs +52 -52
  287. package/dist/index74.js +52 -52
  288. package/dist/index75.cjs +39 -39
  289. package/dist/index75.cjs.map +1 -1
  290. package/dist/index75.js +38 -38
  291. package/dist/index75.js.map +1 -1
  292. package/dist/index76.cjs +89 -14
  293. package/dist/index76.cjs.map +1 -1
  294. package/dist/index76.js +89 -14
  295. package/dist/index76.js.map +1 -1
  296. package/dist/index77.cjs +35 -2
  297. package/dist/index77.cjs.map +1 -1
  298. package/dist/index77.js +36 -3
  299. package/dist/index77.js.map +1 -1
  300. package/dist/index78.cjs +22 -6
  301. package/dist/index78.cjs.map +1 -1
  302. package/dist/index78.js +21 -5
  303. package/dist/index78.js.map +1 -1
  304. package/dist/index79.cjs +70 -10
  305. package/dist/index79.cjs.map +1 -1
  306. package/dist/index79.js +68 -8
  307. package/dist/index79.js.map +1 -1
  308. package/dist/index80.cjs +7 -33
  309. package/dist/index80.cjs.map +1 -1
  310. package/dist/index80.js +6 -32
  311. package/dist/index80.js.map +1 -1
  312. package/dist/index81.cjs +34 -16
  313. package/dist/index81.cjs.map +1 -1
  314. package/dist/index81.js +35 -17
  315. package/dist/index81.js.map +1 -1
  316. package/dist/index82.cjs +134 -16
  317. package/dist/index82.cjs.map +1 -1
  318. package/dist/index82.js +133 -15
  319. package/dist/index82.js.map +1 -1
  320. package/dist/index83.cjs +36 -15
  321. package/dist/index83.cjs.map +1 -1
  322. package/dist/index83.js +37 -16
  323. package/dist/index83.js.map +1 -1
  324. package/dist/index84.cjs +1 -1
  325. package/dist/index84.js +1 -1
  326. package/dist/index85.cjs +32 -17
  327. package/dist/index85.cjs.map +1 -1
  328. package/dist/index85.js +33 -18
  329. package/dist/index85.js.map +1 -1
  330. package/dist/index86.cjs +28 -64
  331. package/dist/index86.cjs.map +1 -1
  332. package/dist/index86.js +28 -64
  333. package/dist/index86.js.map +1 -1
  334. package/dist/index87.cjs +2 -20
  335. package/dist/index87.cjs.map +1 -1
  336. package/dist/index87.js +3 -21
  337. package/dist/index87.js.map +1 -1
  338. package/dist/index88.cjs +17 -2
  339. package/dist/index88.cjs.map +1 -1
  340. package/dist/index88.js +18 -3
  341. package/dist/index88.js.map +1 -1
  342. package/dist/index89.cjs +20 -2
  343. package/dist/index89.cjs.map +1 -1
  344. package/dist/index89.js +20 -2
  345. package/dist/index89.js.map +1 -1
  346. package/dist/index90.cjs +46 -10
  347. package/dist/index90.cjs.map +1 -1
  348. package/dist/index90.js +47 -11
  349. package/dist/index90.js.map +1 -1
  350. package/dist/index91.cjs +22 -13
  351. package/dist/index91.cjs.map +1 -1
  352. package/dist/index91.js +23 -14
  353. package/dist/index91.js.map +1 -1
  354. package/dist/index92.cjs +22 -49
  355. package/dist/index92.cjs.map +1 -1
  356. package/dist/index92.js +22 -49
  357. package/dist/index92.js.map +1 -1
  358. package/dist/index93.cjs +7 -134
  359. package/dist/index93.cjs.map +1 -1
  360. package/dist/index93.js +6 -133
  361. package/dist/index93.js.map +1 -1
  362. package/dist/index94.cjs +13 -40
  363. package/dist/index94.cjs.map +1 -1
  364. package/dist/index94.js +14 -41
  365. package/dist/index94.js.map +1 -1
  366. package/dist/index95.cjs +3 -36
  367. package/dist/index95.cjs.map +1 -1
  368. package/dist/index95.js +3 -36
  369. package/dist/index95.js.map +1 -1
  370. package/dist/index96.cjs +15 -24
  371. package/dist/index96.cjs.map +1 -1
  372. package/dist/index96.js +15 -24
  373. package/dist/index96.js.map +1 -1
  374. package/dist/index97.cjs +33 -20
  375. package/dist/index97.cjs.map +1 -1
  376. package/dist/index97.js +33 -20
  377. package/dist/index97.js.map +1 -1
  378. package/dist/index98.cjs +37 -63
  379. package/dist/index98.cjs.map +1 -1
  380. package/dist/index98.js +37 -63
  381. package/dist/index98.js.map +1 -1
  382. package/dist/index99.cjs +23 -6
  383. package/dist/index99.cjs.map +1 -1
  384. package/dist/index99.js +23 -6
  385. package/dist/index99.js.map +1 -1
  386. package/dist/style.css +45 -0
  387. package/dist/types/geo.types.d.ts +14 -0
  388. package/dist/types/geo.types.d.ts.map +1 -1
  389. package/dist/types/index.d.ts +1 -1
  390. package/dist/types/index.d.ts.map +1 -1
  391. package/package.json +1 -1
package/dist/index16.js CHANGED
@@ -2,9 +2,9 @@ import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { useState, useRef, useEffect, useCallback } from "react";
3
3
  import { createPortal } from "react-dom";
4
4
  import { useEscapeKey } from "./index5.js";
5
- import { SVG_STROKE_WIDTH, SVG_VIEWBOX, ICON_SIZE, CHART_MODAL, VIEWPORT_MARGIN } from "./index63.js";
5
+ import { SVG_STROKE_WIDTH, SVG_VIEWBOX, ICON_SIZE, CHART_MODAL, VIEWPORT_MARGIN } from "./index64.js";
6
6
  import { clsx } from "./index59.js";
7
- import styles from "./index80.js";
7
+ import styles from "./index127.js";
8
8
  const getInitialSize = (override) => {
9
9
  if (typeof window === "undefined") {
10
10
  return {
package/dist/index17.cjs CHANGED
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
4
  const clsx = require("./index59.cjs");
5
- const ChatLayout_module = require("./index115.cjs");
5
+ const ChatLayout_module = require("./index126.cjs");
6
6
  const ChatLayout = ({
7
7
  sidebar,
8
8
  conversationList,
package/dist/index17.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
2
  import { clsx } from "./index59.js";
3
- import styles from "./index115.js";
3
+ import styles from "./index126.js";
4
4
  const ChatLayout = ({
5
5
  sidebar,
6
6
  conversationList,
package/dist/index19.cjs CHANGED
@@ -3,7 +3,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
4
  const react = require("react");
5
5
  const clsx = require("./index59.cjs");
6
- const Chip_module = require("./index65.cjs");
6
+ const Chip_module = require("./index60.cjs");
7
7
  const Chip = react.forwardRef(
8
8
  ({ className, value, selected = false, size = "md", type = "button", onToggle, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
9
9
  "button",
package/dist/index19.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { forwardRef } from "react";
3
3
  import { clsx } from "./index59.js";
4
- import styles from "./index65.js";
4
+ import styles from "./index60.js";
5
5
  const Chip = forwardRef(
6
6
  ({ className, value, selected = false, size = "md", type = "button", onToggle, ...props }, ref) => /* @__PURE__ */ jsx(
7
7
  "button",
package/dist/index20.cjs CHANGED
@@ -3,7 +3,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
4
  const react = require("react");
5
5
  const clsx = require("./index59.cjs");
6
- const ChipGroup_module = require("./index72.cjs");
6
+ const ChipGroup_module = require("./index87.cjs");
7
7
  const Chip = require("./index19.cjs");
8
8
  const ChipGroup = react.forwardRef(
9
9
  ({ options, selected, onToggle, size = "md", className, ...props }, ref) => {
package/dist/index20.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { forwardRef, useMemo } from "react";
3
3
  import { clsx } from "./index59.js";
4
- import styles from "./index72.js";
4
+ import styles from "./index87.js";
5
5
  import { Chip } from "./index19.js";
6
6
  const ChipGroup = forwardRef(
7
7
  ({ options, selected, onToggle, size = "md", className, ...props }, ref) => {
package/dist/index21.cjs CHANGED
@@ -3,7 +3,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
4
  const react = require("react");
5
5
  const clsx = require("./index59.cjs");
6
- const Col_module = require("./index78.cjs");
6
+ const Col_module = require("./index123.cjs");
7
7
  const GRID_COLUMNS = 12;
8
8
  function toFlexValue(value) {
9
9
  if (value === true) return 1;
package/dist/index21.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
2
  import { forwardRef } from "react";
3
3
  import { clsx } from "./index59.js";
4
- import styles from "./index78.js";
4
+ import styles from "./index123.js";
5
5
  const GRID_COLUMNS = 12;
6
6
  function toFlexValue(value) {
7
7
  if (value === true) return 1;
package/dist/index22.cjs CHANGED
@@ -4,9 +4,9 @@ const jsxRuntime = require("react/jsx-runtime");
4
4
  const react = require("react");
5
5
  const reactDom = require("react-dom");
6
6
  const useEscapeKey = require("./index5.cjs");
7
- const constants = require("./index63.cjs");
7
+ const constants = require("./index64.cjs");
8
8
  const clsx = require("./index59.cjs");
9
- const ContextMenu_module = require("./index91.cjs");
9
+ const ContextMenu_module = require("./index94.cjs");
10
10
  const ContextMenu = ({ x, y, items, onClose }) => {
11
11
  const menuRef = react.useRef(null);
12
12
  const [focusedIndex, setFocusedIndex] = react.useState(-1);
package/dist/index22.js CHANGED
@@ -2,9 +2,9 @@ import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { useRef, useState, useCallback, useEffect } from "react";
3
3
  import { createPortal } from "react-dom";
4
4
  import { useEscapeKey } from "./index5.js";
5
- import { CONTEXT_MENU_MARGIN } from "./index63.js";
5
+ import { CONTEXT_MENU_MARGIN } from "./index64.js";
6
6
  import { clsx } from "./index59.js";
7
- import styles from "./index91.js";
7
+ import styles from "./index94.js";
8
8
  const ContextMenu = ({ x, y, items, onClose }) => {
9
9
  const menuRef = useRef(null);
10
10
  const [focusedIndex, setFocusedIndex] = useState(-1);
package/dist/index23.cjs CHANGED
@@ -4,8 +4,8 @@ const jsxRuntime = require("react/jsx-runtime");
4
4
  const react = require("react");
5
5
  const ReactECharts = require("echarts-for-react");
6
6
  const clsx = require("./index59.cjs");
7
- const constants = require("./index63.cjs");
8
- const CounterTimeseriesChart_module = require("./index96.cjs");
7
+ const constants = require("./index64.cjs");
8
+ const CounterTimeseriesChart_module = require("./index69.cjs");
9
9
  const DEFAULT_TIME_RANGE_OPTIONS = ["auto", "1h", "6h", "24h", "7d", "30d"];
10
10
  const buildMarkAreas = (annotations) => annotations.filter((a) => a.end).map((a) => [
11
11
  { name: a.label, xAxis: a.start, itemStyle: { color: a.color ?? "rgba(255,107,90,0.12)" } },
package/dist/index23.js CHANGED
@@ -2,8 +2,8 @@ import { jsxs, jsx } from "react/jsx-runtime";
2
2
  import { useMemo } from "react";
3
3
  import ReactECharts from "echarts-for-react";
4
4
  import { clsx } from "./index59.js";
5
- import { CHART_COLORS } from "./index63.js";
6
- import styles from "./index96.js";
5
+ import { CHART_COLORS } from "./index64.js";
6
+ import styles from "./index69.js";
7
7
  const DEFAULT_TIME_RANGE_OPTIONS = ["auto", "1h", "6h", "24h", "7d", "30d"];
8
8
  const buildMarkAreas = (annotations) => annotations.filter((a) => a.end).map((a) => [
9
9
  { name: a.label, xAxis: a.start, itemStyle: { color: a.color ?? "rgba(255,107,90,0.12)" } },
package/dist/index24.cjs CHANGED
@@ -3,8 +3,8 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
4
  const react = require("react");
5
5
  const clsx = require("./index59.cjs");
6
- const constants = require("./index63.cjs");
7
- const CountersAnalysisCard_module = require("./index101.cjs");
6
+ const constants = require("./index64.cjs");
7
+ const CountersAnalysisCard_module = require("./index74.cjs");
8
8
  const CounterTimeseriesChart = require("./index23.cjs");
9
9
  const COLUMN_HEADERS = [
10
10
  { key: "counter", label: "Counter" },
package/dist/index24.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
2
  import { useState, useMemo } from "react";
3
3
  import { clsx } from "./index59.js";
4
- import { COUNTERS_PAGE_SIZE } from "./index63.js";
5
- import styles from "./index101.js";
4
+ import { COUNTERS_PAGE_SIZE } from "./index64.js";
5
+ import styles from "./index74.js";
6
6
  import { CounterTimeseriesChart } from "./index23.js";
7
7
  const COLUMN_HEADERS = [
8
8
  { key: "counter", label: "Counter" },
package/dist/index25.cjs CHANGED
@@ -6,7 +6,7 @@ const clsx = require("./index59.cjs");
6
6
  const useClickOutside = require("./index4.cjs");
7
7
  const useEscapeKey = require("./index5.cjs");
8
8
  const format = require("./index8.cjs");
9
- const CustomRangePicker_module = require("./index75.cjs");
9
+ const CustomRangePicker_module = require("./index85.cjs");
10
10
  const formatInputValue = (iso) => {
11
11
  if (!iso) return "";
12
12
  const date = new Date(iso);
package/dist/index25.js CHANGED
@@ -4,7 +4,7 @@ import { clsx } from "./index59.js";
4
4
  import { useClickOutside } from "./index4.js";
5
5
  import { useEscapeKey } from "./index5.js";
6
6
  import { formatLocalISOString } from "./index8.js";
7
- import styles from "./index75.js";
7
+ import styles from "./index85.js";
8
8
  const formatInputValue = (iso) => {
9
9
  if (!iso) return "";
10
10
  const date = new Date(iso);
package/dist/index26.cjs CHANGED
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
4
  const clsx = require("./index59.cjs");
5
- const DashboardLayout_module = require("./index107.cjs");
5
+ const DashboardLayout_module = require("./index119.cjs");
6
6
  const DashboardLayout = ({
7
7
  sidebar,
8
8
  filterBar,
package/dist/index26.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
2
  import { clsx } from "./index59.js";
3
- import styles from "./index107.js";
3
+ import styles from "./index119.js";
4
4
  const DashboardLayout = ({
5
5
  sidebar,
6
6
  filterBar,
package/dist/index27.cjs CHANGED
@@ -5,7 +5,7 @@ const react = require("react");
5
5
  const clsx = require("./index59.cjs");
6
6
  const useClickOutside = require("./index4.cjs");
7
7
  const useEscapeKey = require("./index5.cjs");
8
- const DatePickerDropdown_module = require("./index71.cjs");
8
+ const DatePickerDropdown_module = require("./index90.cjs");
9
9
  const MONTHS = [
10
10
  "January",
11
11
  "February",
package/dist/index27.js CHANGED
@@ -3,7 +3,7 @@ import { useState, useRef, useCallback, useEffect, useMemo } from "react";
3
3
  import { clsx } from "./index59.js";
4
4
  import { useClickOutside } from "./index4.js";
5
5
  import { useEscapeKey } from "./index5.js";
6
- import styles from "./index71.js";
6
+ import styles from "./index90.js";
7
7
  const MONTHS = [
8
8
  "January",
9
9
  "February",
package/dist/index28.cjs CHANGED
@@ -3,7 +3,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const jsxRuntime = require("react/jsx-runtime");
4
4
  const react = require("react");
5
5
  const clsx = require("./index59.cjs");
6
- const EmptyState_module = require("./index68.cjs");
6
+ const EmptyState_module = require("./index88.cjs");
7
7
  const EmptyState = react.forwardRef(
8
8
  ({ title, description, icon, action, variant = "default", className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsxs(
9
9
  "div",
package/dist/index28.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
2
  import { forwardRef } from "react";
3
3
  import { clsx } from "./index59.js";
4
- import styles from "./index68.js";
4
+ import styles from "./index88.js";
5
5
  const EmptyState = forwardRef(
6
6
  ({ title, description, icon, action, variant = "default", className, ...props }, ref) => /* @__PURE__ */ jsxs(
7
7
  "div",
package/dist/index29.cjs CHANGED
@@ -5,8 +5,8 @@ const react = require("react");
5
5
  const clsx = require("./index59.cjs");
6
6
  const useClickOutside = require("./index4.cjs");
7
7
  const useEscapeKey = require("./index5.cjs");
8
- const constants = require("./index63.cjs");
9
- const FilterDropdown_module = require("./index69.cjs");
8
+ const constants = require("./index64.cjs");
9
+ const FilterDropdown_module = require("./index86.cjs");
10
10
  const Chip = require("./index19.cjs");
11
11
  const FilterDropdown = ({
12
12
  label,
package/dist/index29.js CHANGED
@@ -3,8 +3,8 @@ import { useState, useRef, useEffect, useCallback, useMemo } from "react";
3
3
  import { clsx } from "./index59.js";
4
4
  import { useClickOutside } from "./index4.js";
5
5
  import { useEscapeKey } from "./index5.js";
6
- import { SVG_STROKE_WIDTH, SVG_VIEWBOX, ICON_SIZE } from "./index63.js";
7
- import styles from "./index69.js";
6
+ import { SVG_STROKE_WIDTH, SVG_VIEWBOX, ICON_SIZE } from "./index64.js";
7
+ import styles from "./index86.js";
8
8
  import { Chip } from "./index19.js";
9
9
  const FilterDropdown = ({
10
10
  label,
package/dist/index30.cjs CHANGED
@@ -5,22 +5,18 @@ const react = require("react");
5
5
  const reactLeaflet = require("react-leaflet");
6
6
  const clsx = require("./index59.cjs");
7
7
  const useThemeMode = require("./index7.cjs");
8
- const constants = require("./index63.cjs");
9
- const normalizePoints = require("./index109.cjs");
10
- const buildMarkerStyle = require("./index110.cjs");
11
- const MapViewport = require("./index111.cjs");
12
- const MapLegend = require("./index112.cjs");
13
- const PointListing = require("./index113.cjs");
14
- const GeoMapCard_module = require("./index114.cjs");
8
+ const constants = require("./index64.cjs");
9
+ const normalizePoints = require("./index97.cjs");
10
+ const buildMarkerStyle = require("./index98.cjs");
11
+ const MapViewport = require("./index99.cjs");
12
+ const ViewportReporter = require("./index100.cjs");
13
+ const MapStatusBars = require("./index101.cjs");
14
+ const describePoints = require("./index102.cjs");
15
+ const MapLegend = require("./index103.cjs");
16
+ const PointListing = require("./index104.cjs");
17
+ const resolveTiles = require("./index105.cjs");
18
+ const GeoMapCard_module = require("./index106.cjs");
15
19
  const EmptyState = require("./index28.cjs");
16
- const buildNotice = (info, maxPoints) => {
17
- const reasons = [];
18
- if (info.skipped > 0) reasons.push(`${info.skipped} without usable coordinates`);
19
- if (info.dropped > 0) reasons.push(`${info.dropped} over the ${maxPoints} marker cap`);
20
- if (reasons.length === 0) return null;
21
- return `Showing ${info.drawn} of ${info.total} points (${reasons.join(", ")}).`;
22
- };
23
- const describePoint = (point, categoryLabel) => [point.label, point.category != null ? `${categoryLabel}: ${point.category}` : null, point.detail].filter((part) => part != null && part !== "").join(" — ");
24
20
  const GeoMapCard = ({
25
21
  title,
26
22
  points,
@@ -35,7 +31,11 @@ const GeoMapCard = ({
35
31
  center,
36
32
  zoom,
37
33
  scrollWheelZoom = false,
34
+ onViewportChange,
35
+ isRefreshing = false,
36
+ refreshingLabel = "Updating…",
38
37
  basemap = "auto",
38
+ basemapKey,
39
39
  tileLayer,
40
40
  compact = false,
41
41
  toolbar,
@@ -68,36 +68,43 @@ const GeoMapCard = ({
68
68
  sourceIndex,
69
69
  selected,
70
70
  style: buildMarkerStyle.buildMarkerStyle(point, { categoryColors, weightScale, selected, theme }),
71
- description: describePoint(point, categoryLabel)
71
+ description: describePoints.describePoint(point, categoryLabel)
72
72
  };
73
73
  });
74
74
  }, [drawn, points, selectedIds, categoryColors, theme, categoryLabel]);
75
- const tiles = tileLayer ?? {
76
- url: constants.BASEMAP_TILES[basemap === "auto" ? theme : basemap],
77
- attribution: constants.BASEMAP_TILES.attribution
78
- };
79
- const shouldFitBounds = fitBounds && center == null && zoom == null;
75
+ const tiles = resolveTiles.resolveTiles(tileLayer, basemap, theme, basemapKey);
76
+ const viewportMode = onViewportChange != null;
77
+ const shouldFitBounds = fitBounds && center == null && zoom == null && !viewportMode;
80
78
  const showLegend = !hideLegend && legendItems.length > 0;
81
- const notice = buildNotice(info, maxPoints);
82
- const hasMap = !isLoading && error == null && info.drawn > 0;
79
+ const notice = describePoints.buildNotice(info, maxPoints);
80
+ const isBlocked = isLoading || error != null;
81
+ const hasMap = !isBlocked && (info.drawn > 0 || viewportMode);
82
+ const showEmptyState = !isBlocked && info.drawn === 0 && !viewportMode;
83
83
  react.useEffect(() => {
84
84
  onRender == null ? void 0 : onRender(info);
85
85
  }, [onRender, info]);
86
86
  react.useEffect(() => {
87
- }, [hasMap]);
87
+ return;
88
+ }, [hasMap, tileLayer, basemapKey]);
88
89
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: clsx.clsx(GeoMapCard_module.default.root, compact && GeoMapCard_module.default.compact, className), children: [
89
90
  /* @__PURE__ */ jsxRuntime.jsxs("header", { className: GeoMapCard_module.default.header, children: [
90
91
  /* @__PURE__ */ jsxRuntime.jsx("h3", { className: GeoMapCard_module.default.title, children: title }),
91
- actions && /* @__PURE__ */ jsxRuntime.jsx("div", { className: GeoMapCard_module.default.headerActions, children: actions })
92
+ (isRefreshing || actions) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: GeoMapCard_module.default.headerActions, children: [
93
+ isRefreshing && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: GeoMapCard_module.default.refreshing, role: "status", children: [
94
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: GeoMapCard_module.default.refreshingDot, "aria-hidden": "true" }),
95
+ refreshingLabel
96
+ ] }),
97
+ actions
98
+ ] })
92
99
  ] }),
93
100
  toolbar && /* @__PURE__ */ jsxRuntime.jsx("div", { className: GeoMapCard_module.default.toolbar, children: toolbar }),
94
- hasMap && notice && /* @__PURE__ */ jsxRuntime.jsx("div", { className: GeoMapCard_module.default.warning, role: "status", children: notice }),
101
+ hasMap && /* @__PURE__ */ jsxRuntime.jsx(MapStatusBars.MapStatusBars, { notice, emptyMessage: info.drawn === 0 ? emptyTitle : null }),
95
102
  isLoading && /* @__PURE__ */ jsxRuntime.jsx("div", { className: GeoMapCard_module.default.loading, children: loadingLabel }),
96
103
  !isLoading && error != null && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: GeoMapCard_module.default.error, children: [
97
104
  /* @__PURE__ */ jsxRuntime.jsx("span", { children: error }),
98
105
  onRetry && /* @__PURE__ */ jsxRuntime.jsx("button", { type: "button", className: GeoMapCard_module.default.retryButton, onClick: onRetry, children: retryLabel })
99
106
  ] }),
100
- !isLoading && error == null && info.drawn === 0 && /* @__PURE__ */ jsxRuntime.jsx(
107
+ showEmptyState && /* @__PURE__ */ jsxRuntime.jsx(
101
108
  EmptyState.EmptyState,
102
109
  {
103
110
  className: GeoMapCard_module.default.empty,
@@ -113,6 +120,7 @@ const GeoMapCard = ({
113
120
  className: GeoMapCard_module.default.mapContainer,
114
121
  role: "figure",
115
122
  "aria-label": `${title}: map of ${info.drawn} points`,
123
+ "aria-busy": isRefreshing || void 0,
116
124
  children: [
117
125
  /* @__PURE__ */ jsxRuntime.jsxs(
118
126
  reactLeaflet.MapContainer,
@@ -124,6 +132,7 @@ const GeoMapCard = ({
124
132
  children: [
125
133
  /* @__PURE__ */ jsxRuntime.jsx(reactLeaflet.TileLayer, { url: tiles.url, attribution: tiles.attribution }, tiles.url),
126
134
  /* @__PURE__ */ jsxRuntime.jsx(MapViewport.MapViewport, { bounds, fitBounds: shouldFitBounds }),
135
+ onViewportChange && /* @__PURE__ */ jsxRuntime.jsx(ViewportReporter.ViewportReporter, { onViewportChange }),
127
136
  markers.map(({ point, sourceIndex, style, description }) => /* @__PURE__ */ jsxRuntime.jsx(
128
137
  reactLeaflet.CircleMarker,
129
138
  {
@@ -139,14 +148,7 @@ const GeoMapCard = ({
139
148
  ]
140
149
  }
141
150
  ),
142
- /* @__PURE__ */ jsxRuntime.jsx(
143
- PointListing.PointListing,
144
- {
145
- markers,
146
- label: pointListLabel,
147
- onSelectPoint
148
- }
149
- )
151
+ /* @__PURE__ */ jsxRuntime.jsx(PointListing.PointListing, { markers, label: pointListLabel, onSelectPoint })
150
152
  ]
151
153
  }
152
154
  )
@@ -1 +1 @@
1
- {"version":3,"file":"index30.cjs","sources":["../src/geo/GeoMapCard/GeoMapCard.tsx"],"sourcesContent":["import { useEffect, useMemo, useRef } from 'react';\nimport { CircleMarker, MapContainer, TileLayer, Tooltip } from 'react-leaflet';\nimport clsx from 'clsx';\nimport { EmptyState } from '../../primitives/EmptyState';\nimport { useThemeMode } from '../../hooks/useThemeMode';\nimport { BASEMAP_TILES, GEO_MAP } from '../../constants';\nimport type { GeoPoint, GeoRenderInfo } from '../../types/geo.types';\nimport type { GeoMapCardProps, MarkerDescriptor } from './GeoMapCard.types';\nimport { normalizePoints } from './normalizePoints';\nimport { buildCategoryColors, buildLegendItems, buildMarkerStyle, buildWeightScale } from './buildMarkerStyle';\nimport { MapViewport } from './MapViewport';\nimport { MapLegend } from './MapLegend';\nimport { PointListing } from './PointListing';\nimport { warnMissingLeafletStylesheet } from './warnMissingLeafletStylesheet';\nimport styles from './GeoMapCard.module.css';\n\n/** States what was left out, so a truncated map never passes for a complete one. */\nconst buildNotice = (info: GeoRenderInfo, maxPoints: number): string | null => {\n const reasons: string[] = [];\n\n if (info.skipped > 0) reasons.push(`${info.skipped} without usable coordinates`);\n if (info.dropped > 0) reasons.push(`${info.dropped} over the ${maxPoints} marker cap`);\n\n if (reasons.length === 0) return null;\n\n return `Showing ${info.drawn} of ${info.total} points (${reasons.join(', ')}).`;\n};\n\n/** One line carrying everything the tooltip shows, for the screen reader too. */\nconst describePoint = (point: GeoPoint, categoryLabel: string): string =>\n [point.label, point.category != null ? `${categoryLabel}: ${point.category}` : null, point.detail]\n .filter((part): part is string => part != null && part !== '')\n .join(' — ');\n\nexport const GeoMapCard = ({\n title,\n points,\n selectedIds,\n onSelectPoint,\n categoryLabel = 'Category',\n legendTitle = 'Legend',\n hideLegend = false,\n maxPoints = GEO_MAP.MAX_POINTS,\n onRender,\n fitBounds = true,\n center,\n zoom,\n scrollWheelZoom = false,\n basemap = 'auto',\n tileLayer,\n compact = false,\n toolbar,\n actions,\n isLoading = false,\n error = null,\n onRetry,\n emptyTitle = 'No mappable points',\n emptyDescription = 'None of the points received carry usable coordinates.',\n retryLabel = 'Retry',\n loadingLabel = 'Loading map...',\n pointListLabel = 'Map points',\n className,\n}: GeoMapCardProps) => {\n const theme = useThemeMode();\n const containerRef = useRef<HTMLDivElement>(null);\n\n const { drawn, bounds, info } = useMemo(\n () => normalizePoints(points, maxPoints),\n [points, maxPoints],\n );\n\n const categoryColors = useMemo(() => buildCategoryColors(points), [points]);\n const legendItems = useMemo(() => buildLegendItems(categoryColors), [categoryColors]);\n\n const markers = useMemo<MarkerDescriptor[]>(() => {\n const weightScale = buildWeightScale(points);\n const selection = new Set(selectedIds ?? []);\n\n return drawn.map(({ point, sourceIndex }) => {\n const selected = selection.has(point.id);\n\n return {\n point,\n sourceIndex,\n selected,\n style: buildMarkerStyle(point, { categoryColors, weightScale, selected, theme }),\n description: describePoint(point, categoryLabel),\n };\n });\n }, [drawn, points, selectedIds, categoryColors, theme, categoryLabel]);\n\n const tiles = tileLayer ?? {\n url: BASEMAP_TILES[basemap === 'auto' ? theme : basemap],\n attribution: BASEMAP_TILES.attribution,\n };\n\n // Manual framing and automatic framing would fight over the viewport.\n const shouldFitBounds = fitBounds && center == null && zoom == null;\n const showLegend = !hideLegend && legendItems.length > 0;\n const notice = buildNotice(info, maxPoints);\n const hasMap = !isLoading && error == null && info.drawn > 0;\n\n useEffect(() => {\n onRender?.(info);\n }, [onRender, info]);\n\n useEffect(() => {\n if (import.meta.env.DEV && hasMap) warnMissingLeafletStylesheet(containerRef.current);\n }, [hasMap]);\n\n return (\n <div className={clsx(styles.root, compact && styles.compact, className)}>\n <header className={styles.header}>\n <h3 className={styles.title}>{title}</h3>\n {actions && <div className={styles.headerActions}>{actions}</div>}\n </header>\n\n {toolbar && <div className={styles.toolbar}>{toolbar}</div>}\n\n {hasMap && notice && (\n <div className={styles.warning} role=\"status\">\n {notice}\n </div>\n )}\n\n {isLoading && <div className={styles.loading}>{loadingLabel}</div>}\n\n {!isLoading && error != null && (\n <div className={styles.error}>\n <span>{error}</span>\n {onRetry && (\n <button type=\"button\" className={styles.retryButton} onClick={onRetry}>\n {retryLabel}\n </button>\n )}\n </div>\n )}\n\n {!isLoading && error == null && info.drawn === 0 && (\n <EmptyState\n className={styles.empty}\n variant=\"plain\"\n title={emptyTitle}\n description={emptyDescription}\n />\n )}\n\n {hasMap && (\n <div\n ref={containerRef}\n className={styles.mapContainer}\n role=\"figure\"\n aria-label={`${title}: map of ${info.drawn} points`}\n >\n <MapContainer\n className={styles.map}\n center={center ?? [...GEO_MAP.DEFAULT_CENTER]}\n zoom={zoom ?? GEO_MAP.DEFAULT_ZOOM}\n scrollWheelZoom={scrollWheelZoom}\n >\n <TileLayer key={tiles.url} url={tiles.url} attribution={tiles.attribution} />\n <MapViewport bounds={bounds} fitBounds={shouldFitBounds} />\n\n {markers.map(({ point, sourceIndex, style, description }) => (\n <CircleMarker\n key={point.id}\n center={[point.latitude, point.longitude]}\n radius={style.radius}\n pathOptions={style}\n eventHandlers={\n onSelectPoint ? { click: () => onSelectPoint({ point, index: sourceIndex }) } : {}\n }\n >\n <Tooltip>{description}</Tooltip>\n </CircleMarker>\n ))}\n\n {showLegend && <MapLegend items={legendItems} title={legendTitle} />}\n </MapContainer>\n\n <PointListing\n markers={markers}\n label={pointListLabel}\n onSelectPoint={onSelectPoint}\n />\n </div>\n )}\n </div>\n );\n};\n\nGeoMapCard.displayName = 'GeoMapCard';\n"],"names":["GEO_MAP","useThemeMode","useRef","useMemo","normalizePoints","buildCategoryColors","buildLegendItems","buildWeightScale","buildMarkerStyle","BASEMAP_TILES","useEffect","jsxs","clsx","styles","jsx","EmptyState","MapContainer","TileLayer","MapViewport","CircleMarker","Tooltip","MapLegend","PointListing"],"mappings":";;;;;;;;;;;;;;;AAiBA,MAAM,cAAc,CAAC,MAAqB,cAAqC;AAC7E,QAAM,UAAoB,CAAA;AAE1B,MAAI,KAAK,UAAU,EAAG,SAAQ,KAAK,GAAG,KAAK,OAAO,6BAA6B;AAC/E,MAAI,KAAK,UAAU,EAAG,SAAQ,KAAK,GAAG,KAAK,OAAO,aAAa,SAAS,aAAa;AAErF,MAAI,QAAQ,WAAW,EAAG,QAAO;AAEjC,SAAO,WAAW,KAAK,KAAK,OAAO,KAAK,KAAK,YAAY,QAAQ,KAAK,IAAI,CAAC;AAC7E;AAGA,MAAM,gBAAgB,CAAC,OAAiB,kBACtC,CAAC,MAAM,OAAO,MAAM,YAAY,OAAO,GAAG,aAAa,KAAK,MAAM,QAAQ,KAAK,MAAM,MAAM,MAAM,EAC9F,OAAO,CAAC,SAAyB,QAAQ,QAAQ,SAAS,EAAE,EAC5D,KAAK,KAAK;AAER,MAAM,aAAa,CAAC;AAAA,EACzB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,gBAAgB;AAAA,EAChB,cAAc;AAAA,EACd,aAAa;AAAA,EACb,YAAYA,UAAAA,QAAQ;AAAA,EACpB;AAAA,EACA,YAAY;AAAA,EACZ;AAAA,EACA;AAAA,EACA,kBAAkB;AAAA,EAClB,UAAU;AAAA,EACV;AAAA,EACA,UAAU;AAAA,EACV;AAAA,EACA;AAAA,EACA,YAAY;AAAA,E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AAAA,cACP;AAAA,YAAA;AAAA,UAAA;AAAA,QACF;AAAA,MAAA;AAAA,IAAA;AAAA,EACF,GAEJ;AAEJ;AAEA,WAAW,cAAc;;"}
1
+ {"version":3,"file":"index30.cjs","sources":["../src/geo/GeoMapCard/GeoMapCard.tsx"],"sourcesContent":["import { useEffect, useMemo, useRef } from 'react';\nimport { CircleMarker, MapContainer, TileLayer, Tooltip } from 'react-leaflet';\nimport clsx from 'clsx';\nimport { EmptyState } from '../../primitives/EmptyState';\nimport { useThemeMode } from '../../hooks/useThemeMode';\nimport { GEO_MAP } from '../../constants';\nimport type { GeoMapCardProps, MarkerDescriptor } from './GeoMapCard.types';\nimport { normalizePoints } from './normalizePoints';\nimport {\n buildCategoryColors,\n buildLegendItems,\n buildMarkerStyle,\n buildWeightScale,\n} from './buildMarkerStyle';\nimport { MapViewport } from './MapViewport';\nimport { ViewportReporter } from './ViewportReporter';\nimport { MapStatusBars } from './MapStatusBars';\nimport { buildNotice, describePoint } from './describePoints';\nimport { MapLegend } from './MapLegend';\nimport { PointListing } from './PointListing';\nimport { warnMissingLeafletStylesheet } from './warnMissingLeafletStylesheet';\nimport { warnMissingBasemapKey } from './warnMissingBasemapKey';\nimport { resolveTiles } from './resolveTiles';\nimport styles from './GeoMapCard.module.css';\n\nexport const GeoMapCard = ({\n title,\n points,\n selectedIds,\n onSelectPoint,\n categoryLabel = 'Category',\n legendTitle = 'Legend',\n hideLegend = false,\n maxPoints = GEO_MAP.MAX_POINTS,\n onRender,\n fitBounds = true,\n center,\n zoom,\n scrollWheelZoom = false,\n onViewportChange,\n isRefreshing = false,\n refreshingLabel = 'Updating…',\n basemap = 'auto',\n basemapKey,\n tileLayer,\n compact = false,\n toolbar,\n actions,\n isLoading = false,\n error = null,\n onRetry,\n emptyTitle = 'No mappable points',\n emptyDescription = 'None of the points received carry usable coordinates.',\n retryLabel = 'Retry',\n loadingLabel = 'Loading map...',\n pointListLabel = 'Map points',\n className,\n}: GeoMapCardProps) => {\n const theme = useThemeMode();\n const containerRef = useRef<HTMLDivElement>(null);\n\n const { drawn, bounds, info } = useMemo(\n () => normalizePoints(points, maxPoints),\n [points, maxPoints],\n );\n\n const categoryColors = useMemo(() => buildCategoryColors(points), [points]);\n const legendItems = useMemo(() => buildLegendItems(categoryColors), [categoryColors]);\n\n const markers = useMemo<MarkerDescriptor[]>(() => {\n const weightScale = buildWeightScale(points);\n const selection = new Set(selectedIds ?? []);\n\n return drawn.map(({ point, sourceIndex }) => {\n const selected = selection.has(point.id);\n\n return {\n point,\n sourceIndex,\n selected,\n style: buildMarkerStyle(point, { categoryColors, weightScale, selected, theme }),\n description: describePoint(point, categoryLabel),\n };\n });\n }, [drawn, points, selectedIds, categoryColors, theme, categoryLabel]);\n\n const tiles = resolveTiles(tileLayer, basemap, theme, basemapKey);\n\n // Viewport mode: the view drives the points, so the map must outlive an empty\n // area, and the points must never move the view (that would be a fetch loop).\n const viewportMode = onViewportChange != null;\n // Manual framing and automatic framing would fight over the viewport.\n const shouldFitBounds = fitBounds && center == null && zoom == null && !viewportMode;\n const showLegend = !hideLegend && legendItems.length > 0;\n const notice = buildNotice(info, maxPoints);\n const isBlocked = isLoading || error != null;\n const hasMap = !isBlocked && (info.drawn > 0 || viewportMode);\n const showEmptyState = !isBlocked && info.drawn === 0 && !viewportMode;\n\n useEffect(() => {\n onRender?.(info);\n }, [onRender, info]);\n\n useEffect(() => {\n if (!import.meta.env.DEV || !hasMap) return;\n\n warnMissingLeafletStylesheet(containerRef.current);\n if (tileLayer == null && !basemapKey) warnMissingBasemapKey();\n }, [hasMap, tileLayer, basemapKey]);\n\n return (\n <div className={clsx(styles.root, compact && styles.compact, className)}>\n <header className={styles.header}>\n <h3 className={styles.title}>{title}</h3>\n {(isRefreshing || actions) && (\n <div className={styles.headerActions}>\n {isRefreshing && (\n <span className={styles.refreshing} role=\"status\">\n <span className={styles.refreshingDot} aria-hidden=\"true\" />\n {refreshingLabel}\n </span>\n )}\n {actions}\n </div>\n )}\n </header>\n\n {toolbar && <div className={styles.toolbar}>{toolbar}</div>}\n\n {hasMap && (\n <MapStatusBars notice={notice} emptyMessage={info.drawn === 0 ? emptyTitle : null} />\n )}\n\n {isLoading && <div className={styles.loading}>{loadingLabel}</div>}\n\n {!isLoading && error != null && (\n <div className={styles.error}>\n <span>{error}</span>\n {onRetry && (\n <button type=\"button\" className={styles.retryButton} onClick={onRetry}>\n {retryLabel}\n </button>\n )}\n </div>\n )}\n\n {showEmptyState && (\n <EmptyState\n className={styles.empty}\n variant=\"plain\"\n title={emptyTitle}\n description={emptyDescription}\n />\n )}\n\n {hasMap && (\n <div\n ref={containerRef}\n className={styles.mapContainer}\n role=\"figure\"\n aria-label={`${title}: map of ${info.drawn} points`}\n aria-busy={isRefreshing || undefined}\n >\n <MapContainer\n className={styles.map}\n center={center ?? [...GEO_MAP.DEFAULT_CENTER]}\n zoom={zoom ?? GEO_MAP.DEFAULT_ZOOM}\n scrollWheelZoom={scrollWheelZoom}\n >\n <TileLayer key={tiles.url} url={tiles.url} attribution={tiles.attribution} />\n <MapViewport bounds={bounds} fitBounds={shouldFitBounds} />\n {onViewportChange && <ViewportReporter onViewportChange={onViewportChange} />}\n\n {markers.map(({ point, sourceIndex, style, description }) => (\n <CircleMarker\n key={point.id}\n center={[point.latitude, point.longitude]}\n radius={style.radius}\n pathOptions={style}\n eventHandlers={\n onSelectPoint ? { click: () => onSelectPoint({ point, index: sourceIndex }) } : {}\n }\n >\n <Tooltip>{description}</Tooltip>\n </CircleMarker>\n ))}\n\n {showLegend && <MapLegend items={legendItems} title={legendTitle} />}\n </MapContainer>\n\n <PointListing markers={markers} label={pointListLabel} onSelectPoint={onSelectPoint} />\n </div>\n )}\n </div>\n );\n};\n\nGeoMapCard.displayName = 'GeoMapCard';\n"],"names":["GEO_MAP","useThemeMode","useRef","useMemo","normalizePoints","buildCategoryColors","buildLegendItems","buildWeightScale","buildMarkerStyle","describePoint","resolveTiles","buildNotice","useEffect","jsxs","clsx","styles","jsx","MapStatusBars","EmptyState","MapContainer","TileLayer","MapViewport","ViewportReporter","CircleMarker","Tooltip","MapLegend","PointListing"],"mappings":";;;;;;;;;;;;;;;;;;;AAyBO,MAAM,aAAa,CAAC;AAAA,EACzB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,gBAAgB;AAAA,EAChB,cAAc;AAAA,EACd,aAAa;AAAA,EACb,YAAYA,UAAAA,QAAQ;AAAA,EACpB;AAAA,EACA,YAAY;AAAA,EACZ;AAAA,EACA;AAAA,EACA,kBAAkB;AAAA,EAClB;AAAA,EACA,eAAe;AAAA,EACf,kBAAkB;AAAA,EAClB,UAAU;AAAA,EACV;AAAA,EACA;AAAA,EACA,UAAU;AAAA,EACV;AAAA,EACA;AAAA,EACA,YAAY;AAAA,EACZ,QAAQ;AAAA,EACR;AAAA,EACA,aAAa;AAAA,EACb,mBAAmB;AAAA,EACnB,aAAa;AAAA,EACb,eAAe;AAAA,EACf,iBAAiB;AAAA,EACjB;AACF,MAAuB;AACrB,QAAM,QAAQC,aAAAA,aAAA;AACd,QAAM,eAAeC,MAAAA,OAAuB,IAAI;AAEhD,QAAM,EAAE,OAAO,QAAQ,KAAA,IAASC,MAAAA;AAAAA,IAC9B,MAAMC,gBAAAA,gBAAgB,QAAQ,SAAS;AAAA,IACvC,CAAC,QAAQ,SAAS;AAAA,EAAA;AAGpB,QAAM,iBAAiBD,MAAAA,QAAQ,MAAME,iBAAAA,oBAAoB,MAAM,GAAG,CAAC,MAAM,CAAC;AAC1E,QAAM,cAAcF,MAAAA,QAAQ,MAAMG,iBAAAA,iBAAiB,cAAc,GAAG,CAAC,cAAc,CAAC;AAEpF,QAAM,UAAUH,MAAAA,QAA4B,MAAM;AAChD,UAAM,cAAcI,iBAAAA,iBAAiB,MAAM;AAC3C,UAAM,YAAY,IAAI,IAAI,eAAe,CAAA,CAAE;AAE3C,WAAO,MAAM,IAAI,CAAC,EAAE,OAAO,kBAAkB;AAC3C,YAAM,WAAW,UAAU,IAAI,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cAEA,UAAA;AAAA,gBAAAgB,2BAAAA,IAACI,aAAAA,WAAA,EAA0B,KAAK,MAAM,KAAK,aAAa,MAAM,eAA9C,MAAM,GAAqD;AAAA,+CAC1EC,YAAAA,aAAA,EAAY,QAAgB,WAAW,iBAAiB;AAAA,gBACxD,oBAAoBL,2BAAAA,IAACM,mCAAA,EAAiB,kBAAoC;AAAA,gBAE1E,QAAQ,IAAI,CAAC,EAAE,OAAO,aAAa,OAAO,kBACzCN,2BAAAA;AAAAA,kBAACO,aAAAA;AAAAA,kBAAA;AAAA,oBAEC,QAAQ,CAAC,MAAM,UAAU,MAAM,SAAS;AAAA,oBACxC,QAAQ,MAAM;AAAA,oBACd,aAAa;AAAA,oBACb,eACE,gBAAgB,EAAE,OAAO,MAAM,cAAc,EAAE,OAAO,OAAO,aAAa,EAAA,IAAM,CAAA;AAAA,oBAGlF,UAAAP,2BAAAA,IAACQ,aAAAA,WAAS,UAAA,aAAY;AAAA,kBAAA;AAAA,kBARjB,MAAM;AAAA,gBAAA,CAUd;AAAA,gBAEA,6CAAeC,qBAAA,EAAU,OAAO,aAAa,OAAO,aAAa;AAAA,cAAA;AAAA,YAAA;AAAA,UAAA;AAAA,yCAGnEC,aAAAA,cAAA,EAAa,SAAkB,OAAO,gBAAgB,eAA8B;AAAA,QAAA;AAAA,MAAA;AAAA,IAAA;AAAA,EACvF,GAEJ;AAEJ;AAEA,WAAW,cAAc;;"}
package/dist/index30.js CHANGED
@@ -3,22 +3,18 @@ import { useRef, useMemo, useEffect } from "react";
3
3
  import { MapContainer, TileLayer, CircleMarker, Tooltip } from "react-leaflet";
4
4
  import { clsx } from "./index59.js";
5
5
  import { useThemeMode } from "./index7.js";
6
- import { GEO_MAP, BASEMAP_TILES } from "./index63.js";
7
- import { normalizePoints } from "./index109.js";
8
- import { buildCategoryColors, buildLegendItems, buildWeightScale, buildMarkerStyle } from "./index110.js";
9
- import { MapViewport } from "./index111.js";
10
- import { MapLegend } from "./index112.js";
11
- import { PointListing } from "./index113.js";
12
- import styles from "./index114.js";
6
+ import { GEO_MAP } from "./index64.js";
7
+ import { normalizePoints } from "./index97.js";
8
+ import { buildCategoryColors, buildLegendItems, buildWeightScale, buildMarkerStyle } from "./index98.js";
9
+ import { MapViewport } from "./index99.js";
10
+ import { ViewportReporter } from "./index100.js";
11
+ import { MapStatusBars } from "./index101.js";
12
+ import { describePoint, buildNotice } from "./index102.js";
13
+ import { MapLegend } from "./index103.js";
14
+ import { PointListing } from "./index104.js";
15
+ import { resolveTiles } from "./index105.js";
16
+ import styles from "./index106.js";
13
17
  import { EmptyState } from "./index28.js";
14
- const buildNotice = (info, maxPoints) => {
15
- const reasons = [];
16
- if (info.skipped > 0) reasons.push(`${info.skipped} without usable coordinates`);
17
- if (info.dropped > 0) reasons.push(`${info.dropped} over the ${maxPoints} marker cap`);
18
- if (reasons.length === 0) return null;
19
- return `Showing ${info.drawn} of ${info.total} points (${reasons.join(", ")}).`;
20
- };
21
- const describePoint = (point, categoryLabel) => [point.label, point.category != null ? `${categoryLabel}: ${point.category}` : null, point.detail].filter((part) => part != null && part !== "").join(" — ");
22
18
  const GeoMapCard = ({
23
19
  title,
24
20
  points,
@@ -33,7 +29,11 @@ const GeoMapCard = ({
33
29
  center,
34
30
  zoom,
35
31
  scrollWheelZoom = false,
32
+ onViewportChange,
33
+ isRefreshing = false,
34
+ refreshingLabel = "Updating…",
36
35
  basemap = "auto",
36
+ basemapKey,
37
37
  tileLayer,
38
38
  compact = false,
39
39
  toolbar,
@@ -70,32 +70,39 @@ const GeoMapCard = ({
70
70
  };
71
71
  });
72
72
  }, [drawn, points, selectedIds, categoryColors, theme, categoryLabel]);
73
- const tiles = tileLayer ?? {
74
- url: BASEMAP_TILES[basemap === "auto" ? theme : basemap],
75
- attribution: BASEMAP_TILES.attribution
76
- };
77
- const shouldFitBounds = fitBounds && center == null && zoom == null;
73
+ const tiles = resolveTiles(tileLayer, basemap, theme, basemapKey);
74
+ const viewportMode = onViewportChange != null;
75
+ const shouldFitBounds = fitBounds && center == null && zoom == null && !viewportMode;
78
76
  const showLegend = !hideLegend && legendItems.length > 0;
79
77
  const notice = buildNotice(info, maxPoints);
80
- const hasMap = !isLoading && error == null && info.drawn > 0;
78
+ const isBlocked = isLoading || error != null;
79
+ const hasMap = !isBlocked && (info.drawn > 0 || viewportMode);
80
+ const showEmptyState = !isBlocked && info.drawn === 0 && !viewportMode;
81
81
  useEffect(() => {
82
82
  onRender == null ? void 0 : onRender(info);
83
83
  }, [onRender, info]);
84
84
  useEffect(() => {
85
- }, [hasMap]);
85
+ return;
86
+ }, [hasMap, tileLayer, basemapKey]);
86
87
  return /* @__PURE__ */ jsxs("div", { className: clsx(styles.root, compact && styles.compact, className), children: [
87
88
  /* @__PURE__ */ jsxs("header", { className: styles.header, children: [
88
89
  /* @__PURE__ */ jsx("h3", { className: styles.title, children: title }),
89
- actions && /* @__PURE__ */ jsx("div", { className: styles.headerActions, children: actions })
90
+ (isRefreshing || actions) && /* @__PURE__ */ jsxs("div", { className: styles.headerActions, children: [
91
+ isRefreshing && /* @__PURE__ */ jsxs("span", { className: styles.refreshing, role: "status", children: [
92
+ /* @__PURE__ */ jsx("span", { className: styles.refreshingDot, "aria-hidden": "true" }),
93
+ refreshingLabel
94
+ ] }),
95
+ actions
96
+ ] })
90
97
  ] }),
91
98
  toolbar && /* @__PURE__ */ jsx("div", { className: styles.toolbar, children: toolbar }),
92
- hasMap && notice && /* @__PURE__ */ jsx("div", { className: styles.warning, role: "status", children: notice }),
99
+ hasMap && /* @__PURE__ */ jsx(MapStatusBars, { notice, emptyMessage: info.drawn === 0 ? emptyTitle : null }),
93
100
  isLoading && /* @__PURE__ */ jsx("div", { className: styles.loading, children: loadingLabel }),
94
101
  !isLoading && error != null && /* @__PURE__ */ jsxs("div", { className: styles.error, children: [
95
102
  /* @__PURE__ */ jsx("span", { children: error }),
96
103
  onRetry && /* @__PURE__ */ jsx("button", { type: "button", className: styles.retryButton, onClick: onRetry, children: retryLabel })
97
104
  ] }),
98
- !isLoading && error == null && info.drawn === 0 && /* @__PURE__ */ jsx(
105
+ showEmptyState && /* @__PURE__ */ jsx(
99
106
  EmptyState,
100
107
  {
101
108
  className: styles.empty,
@@ -111,6 +118,7 @@ const GeoMapCard = ({
111
118
  className: styles.mapContainer,
112
119
  role: "figure",
113
120
  "aria-label": `${title}: map of ${info.drawn} points`,
121
+ "aria-busy": isRefreshing || void 0,
114
122
  children: [
115
123
  /* @__PURE__ */ jsxs(
116
124
  MapContainer,
@@ -122,6 +130,7 @@ const GeoMapCard = ({
122
130
  children: [
123
131
  /* @__PURE__ */ jsx(TileLayer, { url: tiles.url, attribution: tiles.attribution }, tiles.url),
124
132
  /* @__PURE__ */ jsx(MapViewport, { bounds, fitBounds: shouldFitBounds }),
133
+ onViewportChange && /* @__PURE__ */ jsx(ViewportReporter, { onViewportChange }),
125
134
  markers.map(({ point, sourceIndex, style, description }) => /* @__PURE__ */ jsx(
126
135
  CircleMarker,
127
136
  {
@@ -137,14 +146,7 @@ const GeoMapCard = ({
137
146
  ]
138
147
  }
139
148
  ),
140
- /* @__PURE__ */ jsx(
141
- PointListing,
142
- {
143
- markers,
144
- label: pointListLabel,
145
- onSelectPoint
146
- }
147
- )
149
+ /* @__PURE__ */ jsx(PointListing, { markers, label: pointListLabel, onSelectPoint })
148
150
  ]
149
151
  }
150
152
  )