@mailwoman/react 11.0.0 → 11.2.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 (420) hide show
  1. package/README.md +3 -3
  2. package/fonts.css +3 -0
  3. package/lib/common/About.tsx +6 -5
  4. package/lib/common/ClientOnly.tsx +6 -4
  5. package/lib/common/CopyButton.tsx +6 -5
  6. package/lib/common/KindBadge.tsx +8 -7
  7. package/lib/common/LoadingIndicator.tsx +7 -7
  8. package/lib/common/PresetChips.tsx +5 -5
  9. package/lib/common/confidence-tiers.ts +3 -3
  10. package/lib/common/cx.ts +6 -6
  11. package/lib/common/text-tokens.ts +4 -4
  12. package/lib/common/useBuildInfo.ts +5 -5
  13. package/lib/common/useClipboard.ts +5 -5
  14. package/lib/common/useDebouncedValue.ts +6 -6
  15. package/lib/common.ts +3 -3
  16. package/lib/index.ts +2 -5
  17. package/lib/map/AppIdentity.tsx +5 -6
  18. package/lib/map/CompareToggle.tsx +5 -5
  19. package/lib/map/DebugInfo.tsx +3 -4
  20. package/lib/map/Geocoder.tsx +55 -17
  21. package/lib/map/GeocoderControls.tsx +140 -40
  22. package/lib/map/GraticuleLayer.tsx +6 -6
  23. package/lib/map/LoadLedgerList.tsx +96 -0
  24. package/lib/map/MapCanvas.tsx +19 -16
  25. package/lib/map/MapChipRow.tsx +3 -4
  26. package/lib/map/MapCompass.tsx +3 -4
  27. package/lib/map/MapContextMenu.tsx +206 -0
  28. package/lib/map/MapControlStack.tsx +3 -4
  29. package/lib/map/MapFooter.tsx +3 -6
  30. package/lib/map/MapPlaceCard.tsx +64 -0
  31. package/lib/map/MapProgressBar.tsx +5 -5
  32. package/lib/map/MapSearchBar.tsx +5 -4
  33. package/lib/map/MapSheet.tsx +4 -5
  34. package/lib/map/OverlayLayers.tsx +11 -10
  35. package/lib/map/PlaceAutocomplete.tsx +3 -4
  36. package/lib/map/PlaceMarker.tsx +10 -9
  37. package/lib/map/ResolvedPlaceLayers.tsx +2 -5
  38. package/lib/map/ResultCamera.tsx +138 -19
  39. package/lib/map/ResultOverlay.tsx +2 -5
  40. package/lib/map/ResultPanel.tsx +10 -5
  41. package/lib/map/StarfieldLayer.tsx +7 -6
  42. package/lib/map/VersionPicker.tsx +5 -5
  43. package/lib/map/fake-runtime.ts +2 -5
  44. package/lib/map/geometry.ts +3 -6
  45. package/lib/map/graticule.ts +6 -6
  46. package/lib/map/jump-curtain.ts +105 -0
  47. package/lib/map/map-debug.ts +4 -4
  48. package/lib/map/place-render.ts +32 -14
  49. package/lib/map/reduced-motion.ts +13 -0
  50. package/lib/map/starfield.ts +9 -8
  51. package/lib/map/types.ts +13 -4
  52. package/lib/map/useCompareState.ts +10 -7
  53. package/lib/map/useGeocode.ts +42 -12
  54. package/lib/map/useMapBearing.ts +7 -7
  55. package/lib/map/useMapPick.ts +277 -0
  56. package/lib/map/useMapPlaceRender.ts +5 -5
  57. package/lib/map/usePlaceAutocomplete.ts +2 -5
  58. package/lib/map.ts +21 -8
  59. package/lib/network/ReachabilityProvider.tsx +6 -7
  60. package/lib/pipeline/CandidatePicker.tsx +18 -11
  61. package/lib/pipeline/ComponentTable.tsx +5 -5
  62. package/lib/pipeline/ConfidenceCell.tsx +6 -5
  63. package/lib/pipeline/FailureDiagnostic.tsx +5 -6
  64. package/lib/pipeline/MatchTable.tsx +46 -0
  65. package/lib/pipeline/PipelineExplorer.tsx +8 -7
  66. package/lib/pipeline/QueryForm.tsx +6 -5
  67. package/lib/pipeline/ResolvedPlace.tsx +6 -6
  68. package/lib/pipeline/SpanHighlight.tsx +7 -6
  69. package/lib/pipeline/TimingPanel.tsx +7 -6
  70. package/lib/pipeline/TreeView.tsx +5 -5
  71. package/lib/pipeline/copy.ts +6 -6
  72. package/lib/pipeline/presets.ts +7 -6
  73. package/lib/pipeline/types.ts +17 -5
  74. package/lib/pipeline/useParsePipeline.ts +50 -23
  75. package/lib/pipeline.ts +3 -3
  76. package/lib/poi/AbstainPanel.tsx +6 -5
  77. package/lib/poi/LiveResultsBlock.tsx +7 -6
  78. package/lib/poi/OverpassBlock.tsx +7 -5
  79. package/lib/poi/POIExplorer.tsx +2 -5
  80. package/lib/poi/QueryInput.tsx +5 -5
  81. package/lib/poi/SubjectPanel.tsx +9 -6
  82. package/lib/poi/runtime.ts +2 -5
  83. package/lib/poi/types.ts +6 -5
  84. package/lib/poi/usePOISearch.ts +78 -50
  85. package/lib/poi.ts +3 -3
  86. package/lib/runtime/useReleaseRuntime.ts +77 -8
  87. package/lib/runtime.ts +3 -3
  88. package/lib/search/SearchModal.tsx +13 -9
  89. package/lib/search/search.css +3 -0
  90. package/lib/search/tokens.ts +7 -6
  91. package/lib/search/types.ts +6 -6
  92. package/lib/search.ts +3 -3
  93. package/out/common/About.d.ts +3 -5
  94. package/out/common/About.d.ts.map +1 -1
  95. package/out/common/About.js.map +1 -1
  96. package/out/common/ClientOnly.d.ts +3 -4
  97. package/out/common/ClientOnly.d.ts.map +1 -1
  98. package/out/common/ClientOnly.js +5 -4
  99. package/out/common/ClientOnly.js.map +1 -1
  100. package/out/common/CopyButton.d.ts +3 -5
  101. package/out/common/CopyButton.d.ts.map +1 -1
  102. package/out/common/CopyButton.js.map +1 -1
  103. package/out/common/KindBadge.d.ts +5 -7
  104. package/out/common/KindBadge.d.ts.map +1 -1
  105. package/out/common/KindBadge.js.map +1 -1
  106. package/out/common/LoadingIndicator.d.ts +0 -10
  107. package/out/common/LoadingIndicator.d.ts.map +1 -1
  108. package/out/common/LoadingIndicator.js +6 -7
  109. package/out/common/LoadingIndicator.js.map +1 -1
  110. package/out/common/PresetChips.d.ts +2 -5
  111. package/out/common/PresetChips.d.ts.map +1 -1
  112. package/out/common/confidence-tiers.d.ts +0 -3
  113. package/out/common/confidence-tiers.d.ts.map +1 -1
  114. package/out/common/confidence-tiers.js +2 -3
  115. package/out/common/confidence-tiers.js.map +1 -1
  116. package/out/common/cx.d.ts +3 -6
  117. package/out/common/cx.d.ts.map +1 -1
  118. package/out/common/cx.js +2 -9
  119. package/out/common/cx.js.map +1 -1
  120. package/out/common/text-tokens.d.ts +1 -4
  121. package/out/common/text-tokens.d.ts.map +1 -1
  122. package/out/common/text-tokens.js +2 -11
  123. package/out/common/text-tokens.js.map +1 -1
  124. package/out/common/useBuildInfo.d.ts +0 -7
  125. package/out/common/useBuildInfo.d.ts.map +1 -1
  126. package/out/common/useBuildInfo.js +4 -5
  127. package/out/common/useBuildInfo.js.map +1 -1
  128. package/out/common/useClipboard.d.ts +0 -7
  129. package/out/common/useClipboard.d.ts.map +1 -1
  130. package/out/common/useClipboard.js +4 -5
  131. package/out/common/useClipboard.js.map +1 -1
  132. package/out/common/useDebouncedValue.d.ts +0 -9
  133. package/out/common/useDebouncedValue.d.ts.map +1 -1
  134. package/out/common/useDebouncedValue.js +5 -6
  135. package/out/common/useDebouncedValue.js.map +1 -1
  136. package/out/common.d.ts +0 -3
  137. package/out/common.d.ts.map +1 -1
  138. package/out/common.js +2 -3
  139. package/out/common.js.map +1 -1
  140. package/out/index.d.ts +0 -5
  141. package/out/index.d.ts.map +1 -1
  142. package/out/index.js +2 -5
  143. package/out/index.js.map +1 -1
  144. package/out/map/AppIdentity.d.ts +2 -6
  145. package/out/map/AppIdentity.d.ts.map +1 -1
  146. package/out/map/AppIdentity.js.map +1 -1
  147. package/out/map/CompareToggle.d.ts +2 -5
  148. package/out/map/CompareToggle.d.ts.map +1 -1
  149. package/out/map/DebugInfo.d.ts +0 -4
  150. package/out/map/DebugInfo.d.ts.map +1 -1
  151. package/out/map/DebugInfo.js +2 -4
  152. package/out/map/DebugInfo.js.map +1 -1
  153. package/out/map/Geocoder.d.ts +21 -9
  154. package/out/map/Geocoder.d.ts.map +1 -1
  155. package/out/map/Geocoder.js +15 -10
  156. package/out/map/Geocoder.js.map +1 -1
  157. package/out/map/GeocoderControls.d.ts +7 -9
  158. package/out/map/GeocoderControls.d.ts.map +1 -1
  159. package/out/map/GeocoderControls.js +99 -31
  160. package/out/map/GeocoderControls.js.map +1 -1
  161. package/out/map/GraticuleLayer.d.ts +3 -6
  162. package/out/map/GraticuleLayer.d.ts.map +1 -1
  163. package/out/map/GraticuleLayer.js +5 -6
  164. package/out/map/GraticuleLayer.js.map +1 -1
  165. package/out/map/LoadLedgerList.d.ts +19 -0
  166. package/out/map/LoadLedgerList.d.ts.map +1 -0
  167. package/out/map/LoadLedgerList.js +59 -0
  168. package/out/map/LoadLedgerList.js.map +1 -0
  169. package/out/map/MapCanvas.d.ts +2 -24
  170. package/out/map/MapCanvas.d.ts.map +1 -1
  171. package/out/map/MapCanvas.js +16 -14
  172. package/out/map/MapCanvas.js.map +1 -1
  173. package/out/map/MapChipRow.d.ts +0 -4
  174. package/out/map/MapChipRow.d.ts.map +1 -1
  175. package/out/map/MapChipRow.js.map +1 -1
  176. package/out/map/MapCompass.d.ts +0 -4
  177. package/out/map/MapCompass.d.ts.map +1 -1
  178. package/out/map/MapCompass.js.map +1 -1
  179. package/out/map/MapContextMenu.d.ts +88 -0
  180. package/out/map/MapContextMenu.d.ts.map +1 -0
  181. package/out/map/MapContextMenu.js +96 -0
  182. package/out/map/MapContextMenu.js.map +1 -0
  183. package/out/map/MapControlStack.d.ts +0 -4
  184. package/out/map/MapControlStack.d.ts.map +1 -1
  185. package/out/map/MapControlStack.js.map +1 -1
  186. package/out/map/MapFooter.d.ts +1 -6
  187. package/out/map/MapFooter.d.ts.map +1 -1
  188. package/out/map/MapFooter.js +2 -5
  189. package/out/map/MapFooter.js.map +1 -1
  190. package/out/map/MapPlaceCard.d.ts +17 -0
  191. package/out/map/MapPlaceCard.d.ts.map +1 -0
  192. package/out/map/MapPlaceCard.js +27 -0
  193. package/out/map/MapPlaceCard.js.map +1 -0
  194. package/out/map/MapProgressBar.d.ts +2 -5
  195. package/out/map/MapProgressBar.d.ts.map +1 -1
  196. package/out/map/MapSearchBar.d.ts +2 -4
  197. package/out/map/MapSearchBar.d.ts.map +1 -1
  198. package/out/map/MapSearchBar.js.map +1 -1
  199. package/out/map/MapSheet.d.ts +1 -5
  200. package/out/map/MapSheet.d.ts.map +1 -1
  201. package/out/map/MapSheet.js +2 -4
  202. package/out/map/MapSheet.js.map +1 -1
  203. package/out/map/OverlayLayers.d.ts +8 -10
  204. package/out/map/OverlayLayers.d.ts.map +1 -1
  205. package/out/map/OverlayLayers.js +10 -10
  206. package/out/map/OverlayLayers.js.map +1 -1
  207. package/out/map/PlaceAutocomplete.d.ts +0 -4
  208. package/out/map/PlaceAutocomplete.d.ts.map +1 -1
  209. package/out/map/PlaceAutocomplete.js.map +1 -1
  210. package/out/map/PlaceMarker.d.ts +0 -13
  211. package/out/map/PlaceMarker.d.ts.map +1 -1
  212. package/out/map/PlaceMarker.js +9 -9
  213. package/out/map/PlaceMarker.js.map +1 -1
  214. package/out/map/ResolvedPlaceLayers.d.ts +0 -5
  215. package/out/map/ResolvedPlaceLayers.d.ts.map +1 -1
  216. package/out/map/ResolvedPlaceLayers.js.map +1 -1
  217. package/out/map/ResultCamera.d.ts +53 -7
  218. package/out/map/ResultCamera.d.ts.map +1 -1
  219. package/out/map/ResultCamera.js +103 -17
  220. package/out/map/ResultCamera.js.map +1 -1
  221. package/out/map/ResultOverlay.d.ts +0 -5
  222. package/out/map/ResultOverlay.d.ts.map +1 -1
  223. package/out/map/ResultOverlay.js +2 -5
  224. package/out/map/ResultOverlay.js.map +1 -1
  225. package/out/map/ResultPanel.d.ts +0 -5
  226. package/out/map/ResultPanel.d.ts.map +1 -1
  227. package/out/map/ResultPanel.js +2 -1
  228. package/out/map/ResultPanel.js.map +1 -1
  229. package/out/map/StarfieldLayer.d.ts +0 -11
  230. package/out/map/StarfieldLayer.d.ts.map +1 -1
  231. package/out/map/StarfieldLayer.js +6 -6
  232. package/out/map/StarfieldLayer.js.map +1 -1
  233. package/out/map/VersionPicker.d.ts +2 -5
  234. package/out/map/VersionPicker.d.ts.map +1 -1
  235. package/out/map/fake-runtime.d.ts +0 -5
  236. package/out/map/fake-runtime.d.ts.map +1 -1
  237. package/out/map/fake-runtime.js +2 -5
  238. package/out/map/fake-runtime.js.map +1 -1
  239. package/out/map/geometry.d.ts +1 -6
  240. package/out/map/geometry.d.ts.map +1 -1
  241. package/out/map/geometry.js +3 -6
  242. package/out/map/geometry.js.map +1 -1
  243. package/out/map/graticule.d.ts +3 -6
  244. package/out/map/graticule.d.ts.map +1 -1
  245. package/out/map/graticule.js +2 -9
  246. package/out/map/graticule.js.map +1 -1
  247. package/out/map/jump-curtain.d.ts +61 -0
  248. package/out/map/jump-curtain.d.ts.map +1 -0
  249. package/out/map/jump-curtain.js +69 -0
  250. package/out/map/jump-curtain.js.map +1 -0
  251. package/out/map/map-debug.d.ts +1 -4
  252. package/out/map/map-debug.d.ts.map +1 -1
  253. package/out/map/map-debug.js +2 -10
  254. package/out/map/map-debug.js.map +1 -1
  255. package/out/map/place-render.d.ts +5 -6
  256. package/out/map/place-render.d.ts.map +1 -1
  257. package/out/map/place-render.js +21 -12
  258. package/out/map/place-render.js.map +1 -1
  259. package/out/map/reduced-motion.d.ts +9 -0
  260. package/out/map/reduced-motion.d.ts.map +1 -0
  261. package/out/map/reduced-motion.js +13 -0
  262. package/out/map/reduced-motion.js.map +1 -0
  263. package/out/map/starfield.d.ts +0 -14
  264. package/out/map/starfield.d.ts.map +1 -1
  265. package/out/map/starfield.js +8 -8
  266. package/out/map/starfield.js.map +1 -1
  267. package/out/map/types.d.ts +10 -4
  268. package/out/map/types.d.ts.map +1 -1
  269. package/out/map/types.js +2 -7
  270. package/out/map/types.js.map +1 -1
  271. package/out/map/useCompareState.d.ts +0 -11
  272. package/out/map/useCompareState.d.ts.map +1 -1
  273. package/out/map/useCompareState.js +9 -7
  274. package/out/map/useCompareState.js.map +1 -1
  275. package/out/map/useGeocode.d.ts +13 -20
  276. package/out/map/useGeocode.d.ts.map +1 -1
  277. package/out/map/useGeocode.js +21 -11
  278. package/out/map/useGeocode.js.map +1 -1
  279. package/out/map/useMapBearing.d.ts +2 -9
  280. package/out/map/useMapBearing.d.ts.map +1 -1
  281. package/out/map/useMapBearing.js +4 -5
  282. package/out/map/useMapBearing.js.map +1 -1
  283. package/out/map/useMapPick.d.ts +28 -0
  284. package/out/map/useMapPick.d.ts.map +1 -0
  285. package/out/map/useMapPick.js +206 -0
  286. package/out/map/useMapPick.js.map +1 -0
  287. package/out/map/useMapPlaceRender.d.ts +0 -7
  288. package/out/map/useMapPlaceRender.d.ts.map +1 -1
  289. package/out/map/useMapPlaceRender.js +4 -5
  290. package/out/map/useMapPlaceRender.js.map +1 -1
  291. package/out/map/usePlaceAutocomplete.d.ts +0 -5
  292. package/out/map/usePlaceAutocomplete.d.ts.map +1 -1
  293. package/out/map/usePlaceAutocomplete.js +2 -5
  294. package/out/map/usePlaceAutocomplete.js.map +1 -1
  295. package/out/map.d.ts +10 -8
  296. package/out/map.d.ts.map +1 -1
  297. package/out/map.js +9 -8
  298. package/out/map.js.map +1 -1
  299. package/out/network/ReachabilityProvider.d.ts +3 -7
  300. package/out/network/ReachabilityProvider.d.ts.map +1 -1
  301. package/out/network/ReachabilityProvider.js +5 -7
  302. package/out/network/ReachabilityProvider.js.map +1 -1
  303. package/out/pipeline/CandidatePicker.d.ts +15 -11
  304. package/out/pipeline/CandidatePicker.d.ts.map +1 -1
  305. package/out/pipeline/CandidatePicker.js.map +1 -1
  306. package/out/pipeline/ComponentTable.d.ts +2 -5
  307. package/out/pipeline/ComponentTable.d.ts.map +1 -1
  308. package/out/pipeline/ConfidenceCell.d.ts +0 -8
  309. package/out/pipeline/ConfidenceCell.d.ts.map +1 -1
  310. package/out/pipeline/ConfidenceCell.js +5 -5
  311. package/out/pipeline/ConfidenceCell.js.map +1 -1
  312. package/out/pipeline/FailureDiagnostic.d.ts +2 -6
  313. package/out/pipeline/FailureDiagnostic.d.ts.map +1 -1
  314. package/out/pipeline/FailureDiagnostic.js.map +1 -1
  315. package/out/pipeline/MatchTable.d.ts +7 -0
  316. package/out/pipeline/MatchTable.d.ts.map +1 -0
  317. package/out/pipeline/MatchTable.js +18 -0
  318. package/out/pipeline/MatchTable.js.map +1 -0
  319. package/out/pipeline/PipelineExplorer.d.ts +5 -7
  320. package/out/pipeline/PipelineExplorer.d.ts.map +1 -1
  321. package/out/pipeline/PipelineExplorer.js.map +1 -1
  322. package/out/pipeline/QueryForm.d.ts +3 -5
  323. package/out/pipeline/QueryForm.d.ts.map +1 -1
  324. package/out/pipeline/QueryForm.js.map +1 -1
  325. package/out/pipeline/ResolvedPlace.d.ts +2 -5
  326. package/out/pipeline/ResolvedPlace.d.ts.map +1 -1
  327. package/out/pipeline/SpanHighlight.d.ts +4 -6
  328. package/out/pipeline/SpanHighlight.d.ts.map +1 -1
  329. package/out/pipeline/SpanHighlight.js.map +1 -1
  330. package/out/pipeline/TimingPanel.d.ts +4 -6
  331. package/out/pipeline/TimingPanel.d.ts.map +1 -1
  332. package/out/pipeline/TimingPanel.js.map +1 -1
  333. package/out/pipeline/TreeView.d.ts +2 -5
  334. package/out/pipeline/TreeView.d.ts.map +1 -1
  335. package/out/pipeline/copy.d.ts +0 -8
  336. package/out/pipeline/copy.d.ts.map +1 -1
  337. package/out/pipeline/copy.js +5 -6
  338. package/out/pipeline/copy.js.map +1 -1
  339. package/out/pipeline/presets.d.ts +3 -5
  340. package/out/pipeline/presets.d.ts.map +1 -1
  341. package/out/pipeline/presets.js +3 -9
  342. package/out/pipeline/presets.js.map +1 -1
  343. package/out/pipeline/types.d.ts +14 -5
  344. package/out/pipeline/types.d.ts.map +1 -1
  345. package/out/pipeline/types.js +2 -8
  346. package/out/pipeline/types.js.map +1 -1
  347. package/out/pipeline/useParsePipeline.d.ts +6 -6
  348. package/out/pipeline/useParsePipeline.d.ts.map +1 -1
  349. package/out/pipeline/useParsePipeline.js +38 -26
  350. package/out/pipeline/useParsePipeline.js.map +1 -1
  351. package/out/pipeline.d.ts +0 -3
  352. package/out/pipeline.d.ts.map +1 -1
  353. package/out/pipeline.js +2 -3
  354. package/out/pipeline.js.map +1 -1
  355. package/out/poi/AbstainPanel.d.ts +3 -5
  356. package/out/poi/AbstainPanel.d.ts.map +1 -1
  357. package/out/poi/AbstainPanel.js.map +1 -1
  358. package/out/poi/LiveResultsBlock.d.ts +4 -6
  359. package/out/poi/LiveResultsBlock.d.ts.map +1 -1
  360. package/out/poi/LiveResultsBlock.js.map +1 -1
  361. package/out/poi/OverpassBlock.d.ts +4 -5
  362. package/out/poi/OverpassBlock.d.ts.map +1 -1
  363. package/out/poi/OverpassBlock.js.map +1 -1
  364. package/out/poi/POIExplorer.d.ts +0 -5
  365. package/out/poi/POIExplorer.d.ts.map +1 -1
  366. package/out/poi/POIExplorer.js +2 -5
  367. package/out/poi/POIExplorer.js.map +1 -1
  368. package/out/poi/QueryInput.d.ts +2 -5
  369. package/out/poi/QueryInput.d.ts.map +1 -1
  370. package/out/poi/SubjectPanel.d.ts +6 -6
  371. package/out/poi/SubjectPanel.d.ts.map +1 -1
  372. package/out/poi/SubjectPanel.js.map +1 -1
  373. package/out/poi/runtime.d.ts +0 -5
  374. package/out/poi/runtime.d.ts.map +1 -1
  375. package/out/poi/runtime.js +2 -5
  376. package/out/poi/runtime.js.map +1 -1
  377. package/out/poi/types.d.ts +3 -5
  378. package/out/poi/types.d.ts.map +1 -1
  379. package/out/poi/types.js +2 -8
  380. package/out/poi/types.js.map +1 -1
  381. package/out/poi/usePOISearch.d.ts +7 -5
  382. package/out/poi/usePOISearch.d.ts.map +1 -1
  383. package/out/poi/usePOISearch.js +24 -10
  384. package/out/poi/usePOISearch.js.map +1 -1
  385. package/out/poi.d.ts +0 -3
  386. package/out/poi.d.ts.map +1 -1
  387. package/out/poi.js +2 -3
  388. package/out/poi.js.map +1 -1
  389. package/out/runtime/useReleaseRuntime.d.ts +33 -7
  390. package/out/runtime/useReleaseRuntime.d.ts.map +1 -1
  391. package/out/runtime/useReleaseRuntime.js +36 -6
  392. package/out/runtime/useReleaseRuntime.js.map +1 -1
  393. package/out/runtime.d.ts +0 -3
  394. package/out/runtime.d.ts.map +1 -1
  395. package/out/runtime.js +2 -3
  396. package/out/runtime.js.map +1 -1
  397. package/out/search/SearchModal.d.ts +0 -12
  398. package/out/search/SearchModal.d.ts.map +1 -1
  399. package/out/search/SearchModal.js +12 -9
  400. package/out/search/SearchModal.js.map +1 -1
  401. package/out/search/tokens.d.ts +4 -6
  402. package/out/search/tokens.d.ts.map +1 -1
  403. package/out/search/tokens.js +6 -6
  404. package/out/search/tokens.js.map +1 -1
  405. package/out/search/types.d.ts +3 -6
  406. package/out/search/types.d.ts.map +1 -1
  407. package/out/search/types.js +4 -5
  408. package/out/search/types.js.map +1 -1
  409. package/out/search.d.ts +0 -3
  410. package/out/search.d.ts.map +1 -1
  411. package/out/search.js +2 -3
  412. package/out/search.js.map +1 -1
  413. package/package.json +7 -6
  414. package/styles.css +214 -3
  415. package/tokens/index.css +3 -0
  416. package/lib/map/useMapLabelPick.ts +0 -114
  417. package/out/map/useMapLabelPick.d.ts +0 -13
  418. package/out/map/useMapLabelPick.d.ts.map +0 -1
  419. package/out/map/useMapLabelPick.js +0 -95
  420. package/out/map/useMapLabelPick.js.map +0 -1
@@ -1,10 +1,11 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
+ * Default query + example addresses for the pipeline explorer.
5
6
  *
6
- * Default query + example addresses for the pipeline explorer. Hosts can override via props. These
7
- * mirror the docs demo's set so the extracted component looks identical out of the box.
7
+ * Hosts can override via props.
8
+ * These mirror the docs demo's set so the extracted component looks identical out of the box.
8
9
  */
9
10
 
10
11
  import type { Preset } from "../common/PresetChips.tsx"
@@ -44,7 +45,7 @@ export const PIPELINE_PRESETS: ReadonlyArray<Preset> = [
44
45
  // The postcode is deliberately omitted, since a trailing "Porirua 5026" folds "porirua
45
46
  // 5026" in segment mode and misses the index's bare "porirua" key.
46
47
  // The `country: "nz"` pin is required, since locale-hint cannot structurally
47
- // detect NZ (a 4-digit postcode is not distinctive).
48
+ // detect NZ (a 4-digit postcode isn't distinctive).
48
49
  // Only the pin selects the nz index.
49
50
  { label: "Plimmerton (NZ dependent_locality)", value: "35 Steyne Avenue, Plimmerton, Porirua", country: "nz" },
50
51
  ]
@@ -1,12 +1,14 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
+ * Types for the pipeline (parse + resolve) explorer.
5
6
  *
6
- * Types for the pipeline (parse + resolve) explorer. The runtime is injected as a {@link PipelineRuntime},
7
- * keeping onnxruntime-web, sqlite-wasm and node builtins out of this package's browser graph.
7
+ * The runtime is injected as a {@link PipelineRuntime}, keeping onnxruntime-web,
8
+ * sqlite-wasm and node builtins out of this package's browser graph.
8
9
  */
9
10
 
11
+ import type { LoadLedgerSnapshot } from "@mailwoman/core/load-ledger"
10
12
  import type { ParseResult } from "@mailwoman/core/pipeline/client-result"
11
13
  import type { ReactNode } from "react"
12
14
 
@@ -24,6 +26,10 @@ export interface PipelineLoadingState {
24
26
  * The step index cannot report this download because the model is fetched before the first step begins.
25
27
  */
26
28
  byteFraction?: number | null
29
+ /**
30
+ * One entry per artifact the load requested, with its bytes, source, state and error.
31
+ */
32
+ ledger?: LoadLedgerSnapshot | null
27
33
  }
28
34
 
29
35
  /**
@@ -54,6 +60,12 @@ export interface PipelineRuntime {
54
60
  * Error surfaced by the bundle load, distinct from a per-parse error.
55
61
  */
56
62
  errorMessage?: string | null
63
+ /**
64
+ * Loads the bundle again after a failed load.
65
+ *
66
+ * A page shows a Retry button beside `errorMessage` when the host provides this.
67
+ */
68
+ retryLoad?: () => void
57
69
  }
58
70
 
59
71
  /**
@@ -1,14 +1,15 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
+ * The headless core of the pipeline explorer.
5
6
  *
6
- * The headless core of the pipeline explorer. It owns query text, busy/stage flags, result and candidate selection.
7
+ * It owns query text, busy/stage flags, result and candidate selection.
7
8
  * It delegates parse and resolve to the injected {@link PipelineRuntime}.
8
9
  */
9
10
 
10
11
  import type { ParseResult, ResolvedPlaceView } from "@mailwoman/core/pipeline/client-result"
11
- import { useCallback, useState } from "react"
12
+ import { useCallback, useRef, useState } from "react"
12
13
 
13
14
  import type { PipelineRuntime } from "#pipeline/types"
14
15
 
@@ -41,11 +42,13 @@ export interface UseParsePipeline {
41
42
  selectedCandidate: ResolvedPlaceView | null
42
43
  /**
43
44
  * Parse and resolve the current text, safe to bind to a form's `onSubmit`;
44
- * pass `query` to submit a value the field has not re-rendered with yet.
45
+ * pass `query` to submit a value the field hasn't re-rendered with yet.
46
+ *
47
+ * A submit during a parse queues its query, and the latest queued query runs when that parse settles.
45
48
  */
46
49
  submit: (query?: string) => Promise<void>
47
50
  /**
48
- * Clear the result, used when a preset replaces the input.
51
+ * Clear the result and the parse error, used when a preset replaces the input.
49
52
  */
50
53
  reset: () => void
51
54
  }
@@ -61,33 +64,57 @@ export function useParsePipeline({ runtime, defaultText }: UseParsePipelineOptio
61
64
  const [selectedCandidateIndex, setSelectedCandidateIndex] = useState(0)
62
65
  const [parseError, setParseError] = useState<string | null>(null)
63
66
 
64
- // `setText` does not reach this closure before the call after it runs,
67
+ // A ref rather than the `busy` state, because a submit made during a parse runs
68
+ // in a closure rendered before `busy` became true.
69
+ const parsingRef = useRef(false)
70
+ // The latest query submitted during a parse.
71
+ // It runs when that parse settles, and an earlier one it replaced is dropped.
72
+ const queuedRef = useRef<string | null>(null)
73
+
74
+ // `setText` doesn't reach this closure before the call after it runs,
65
75
  // so a caller that already knows the query passes it.
66
76
  const submit = useCallback(
67
77
  async (query?: string) => {
68
- if (!runtime.ready || busy) return
78
+ if (!runtime.ready) return
69
79
 
70
80
  const input = query ?? text
71
81
 
82
+ if (parsingRef.current) {
83
+ queuedRef.current = input
84
+
85
+ return
86
+ }
87
+
88
+ parsingRef.current = true
72
89
  setBusy(true)
73
- setParseStage(0)
74
- setParseError(null)
75
-
76
- try {
77
- const parsed = await runtime.runParse(input, { onStage: setParseStage })
78
- setSelectedCandidateIndex(0)
79
- setResult(parsed)
80
- } catch (error) {
81
- setParseError(error instanceof Error ? error.message : String(error))
82
- } finally {
83
- setBusy(false)
84
- setParseStage(-1)
90
+
91
+ for (let next: string | null = input; next !== null; next = queuedRef.current) {
92
+ queuedRef.current = null
93
+ setParseStage(0)
94
+ setParseError(null)
95
+
96
+ try {
97
+ const parsed = await runtime.runParse(next, { onStage: setParseStage })
98
+ setSelectedCandidateIndex(0)
99
+ setResult(parsed)
100
+ } catch (error) {
101
+ // The error answers this query, so the previous query's result leaves with it.
102
+ setResult(null)
103
+ setParseError(error instanceof Error ? error.message : String(error))
104
+ }
85
105
  }
106
+
107
+ parsingRef.current = false
108
+ setBusy(false)
109
+ setParseStage(-1)
86
110
  },
87
- [runtime, text, busy]
111
+ [runtime, text]
88
112
  )
89
113
 
90
- const reset = useCallback(() => setResult(null), [])
114
+ const reset = useCallback(() => {
115
+ setResult(null)
116
+ setParseError(null)
117
+ }, [])
91
118
 
92
119
  const selectedCandidate = result ? (result.candidates[selectedCandidateIndex] ?? result.candidates[0] ?? null) : null
93
120
 
package/lib/pipeline.ts CHANGED
@@ -1,7 +1,7 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
5
  * @file Pipeline explorer components, visualizers, hooks and interfaces.
6
6
  */
7
7
 
@@ -1,10 +1,11 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
+ * `AbstainPanel` — shown when the query has no POI intent (it parses as an address).
5
6
  *
6
- * `AbstainPanel` — shown when the query has no POI intent (it parses as an address). Names the
7
- * classifier's kind so the abstention is legible. Presentational.
7
+ * Names the classifier's kind so the abstention is legible.
8
+ * Presentational.
8
9
  */
9
10
 
10
11
  import type { ReactNode } from "react"
@@ -1,11 +1,12 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
+ * `LiveResultsBlock` — the on-demand live poi.db search affordance: a "Search live"
6
+ * button plus the idle / loading / error / results states.
5
7
  *
6
- * `LiveResultsBlock` — the on-demand live poi.db search affordance: a "Search live" button plus the
7
- * idle / loading / error / results states. Presentational — all behavior comes in via props (the
8
- * `usePOISearch` hook owns the state machine + the injected probe).
8
+ * Presentational — all behavior comes in via props
9
+ * (the `usePOISearch` hook owns the state machine + the injected probe).
9
10
  */
10
11
 
11
12
  import type { ReactNode } from "react"
@@ -1,10 +1,12 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
+ * `OverpassBlock` — the OverpassQL export panel: a header with a copy button
6
+ * and the query in a code block.
5
7
  *
6
- * `OverpassBlock` — the OverpassQL export panel: a header with a copy button and the query in a code
7
- * block. Renders the emitter error instead when the export failed. Presentational.
8
+ * Renders the emitter error instead when the export failed.
9
+ * Presentational.
8
10
  */
9
11
 
10
12
  import type { ReactNode } from "react"
@@ -1,8 +1,5 @@
1
- /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
- */
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
6
3
 
7
4
  import { type ReactNode, useState } from "react"
8
5
 
@@ -1,9 +1,9 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
- *
6
- * `QueryInput` — the labeled text field for the POI explorer. Controlled. presentational only.
5
+ * `QueryInput` — the labeled text field for the POI explorer.
6
+ * Controlled. presentational only.
7
7
  */
8
8
 
9
9
  import type { ReactNode } from "react"
@@ -1,11 +1,14 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
+ * `SubjectPanel` — renders the detected POI subject.
6
+ *
7
+ * For a category: the category chip, the optional build-local badge + note.
8
+ * For a brand: the brand-name chip + a Wikidata QID chip (linked).
5
9
  *
6
- * `SubjectPanel` — renders the detected POI subject. For a category: the category chip, the optional
7
- * build-local badge + note. For a brand: the brand-name chip + a Wikidata QID chip (linked). Both
8
- * share the match-detail list (matched phrase, confidence, anchor). Presentational.
10
+ * Both share the match-detail list (matched phrase, confidence, anchor).
11
+ * Presentational.
9
12
  */
10
13
 
11
14
  import type { ReactNode } from "react"
@@ -1,8 +1,5 @@
1
- /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
- */
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
6
3
 
7
4
  import { createKindClassifier } from "@mailwoman/kind-classifier"
8
5
  import type { POIPhraseLookup } from "@mailwoman/kind-classifier"
package/lib/poi/types.ts CHANGED
@@ -1,10 +1,11 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
+ * Types for the POI explorer.
5
6
  *
6
- * Types for the POI explorer. Live poi.db search is injected as {@link POILiveSearch} so the httpvfs
7
- * worker stays out of this package's browser graph.
7
+ * Live poi.db search is injected as {@link POILiveSearch} so the httpvfs worker
8
+ * stays out of this package's browser graph.
8
9
  */
9
10
 
10
11
  import type { QueryKindResult } from "@mailwoman/core/pipeline"
@@ -1,13 +1,10 @@
1
- /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
- */
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
6
3
 
7
4
  import { matchPOISubject } from "@mailwoman/kind-classifier"
8
5
  import { emitOverpassQL } from "@mailwoman/poi-taxonomy/overpass"
9
6
  import type { OverpassIntentLike } from "@mailwoman/poi-taxonomy/overpass"
10
- import { computeQueryShape } from "@mailwoman/query-shape"
7
+ import { computeQueryShape } from "@mailwoman/postcode/recognizer/query-shape"
11
8
  import { useCallback, useEffect, useEffectEvent, useState } from "react"
12
9
 
13
10
  import { useDebouncedValue } from "#common/useDebouncedValue"
@@ -73,6 +70,14 @@ export interface UsePOISearch {
73
70
  */
74
71
  result: POIExplorerResult | null
75
72
 
73
+ /**
74
+ * Why the taxonomy runtime failed to load, or why classifying the current debounced text failed.
75
+ *
76
+ * `null` while both succeed or are pending, so a failure reads apart from a
77
+ * classification still on its way.
78
+ */
79
+ error: string | null
80
+
76
81
  /**
77
82
  * The live-search state for the current debounced text, `idle` until a search runs.
78
83
  */
@@ -133,6 +138,8 @@ export function usePOISearch({
133
138
  const [storedResult, setStoredResult] = useState<{ query: string; value: POIExplorerResult } | null>(null)
134
139
 
135
140
  const [storedLive, setStoredLive] = useState<{ query: string; state: LiveSearchState } | null>(null)
141
+ const [runtimeError, setRuntimeError] = useState<string | null>(null)
142
+ const [storedClassifyError, setStoredClassifyError] = useState<{ query: string; message: string } | null>(null)
136
143
 
137
144
  const debouncedText = useDebouncedValue(text, debounceMs)
138
145
  const trimmedText = debouncedText.trim()
@@ -142,11 +149,18 @@ export function usePOISearch({
142
149
  useEffect(() => {
143
150
  let cancelled = false
144
151
 
145
- void loadRuntimeEvent().then((loaded) => {
146
- if (!cancelled) {
147
- setRuntime(loaded)
152
+ loadRuntimeEvent().then(
153
+ (loaded) => {
154
+ if (!cancelled) {
155
+ setRuntime(loaded)
156
+ }
157
+ },
158
+ (error: unknown) => {
159
+ if (!cancelled) {
160
+ setRuntimeError(error instanceof Error ? error.message : String(error))
161
+ }
148
162
  }
149
- })
163
+ )
150
164
 
151
165
  return () => {
152
166
  cancelled = true
@@ -165,62 +179,75 @@ export function usePOISearch({
165
179
  const input = { raw: trimmed, normalized: trimmed }
166
180
  const shape = computeQueryShape(trimmed)
167
181
 
168
- runtime.classify(input, shape).then((kindResult) => {
169
- if (cancelled) return
182
+ runtime.classify(input, shape).then(
183
+ (kindResult) => {
184
+ if (cancelled) return
185
+
186
+ const matched = kindResult.kind === "poi_query" ? matchPOISubject(trimmed, null, runtime.lexicon) : null
187
+
188
+ if (!matched) {
189
+ setStoredResult({
190
+ query: trimmed,
191
+ value: { kindResult, subject: null, overpassQL: null, overpassError: null },
192
+ })
193
+
194
+ return
195
+ }
196
+
197
+ if ((matched.match.kind ?? "category") === "brand") {
198
+ setStoredResult({
199
+ query: trimmed,
200
+ value: {
201
+ kindResult,
202
+ subject: {
203
+ kind: "brand",
204
+ name: matched.match.categoryID,
205
+ wikidata: matched.match.wikidata || null,
206
+ matchedPhrase: matched.match.matchedPhrase,
207
+ confidence: matched.match.confidence,
208
+ remainder: matched.remainder,
209
+ },
210
+ overpassQL: null,
211
+ overpassError: null,
212
+ },
213
+ })
170
214
 
171
- const matched = kindResult.kind === "poi_query" ? matchPOISubject(trimmed, null, runtime.lexicon) : null
215
+ return
216
+ }
172
217
 
173
- if (!matched) {
174
- setStoredResult({ query: trimmed, value: { kindResult, subject: null, overpassQL: null, overpassError: null } })
218
+ const category = runtime.lookup.getPOICategory(matched.match.categoryID)
175
219
 
176
- return
177
- }
220
+ if (!category) {
221
+ setStoredResult({
222
+ query: trimmed,
223
+ value: { kindResult, subject: null, overpassQL: null, overpassError: null },
224
+ })
225
+
226
+ return
227
+ }
178
228
 
179
- if ((matched.match.kind ?? "category") === "brand") {
180
229
  setStoredResult({
181
230
  query: trimmed,
182
231
  value: {
183
232
  kindResult,
184
233
  subject: {
185
- kind: "brand",
186
- name: matched.match.categoryID,
187
- wikidata: matched.match.wikidata || null,
234
+ kind: "category",
235
+ category,
188
236
  matchedPhrase: matched.match.matchedPhrase,
189
237
  confidence: matched.match.confidence,
190
238
  remainder: matched.remainder,
239
+ buildLocal: runtime.lookup.requiresBuildLocalLayer(category),
191
240
  },
192
- overpassQL: null,
193
- overpassError: null,
241
+ ...buildOverpass(runtime, matched.match.categoryID),
194
242
  },
195
243
  })
244
+ },
245
+ (error: unknown) => {
246
+ if (cancelled) return
196
247
 
197
- return
198
- }
199
-
200
- const category = runtime.lookup.getPOICategory(matched.match.categoryID)
201
-
202
- if (!category) {
203
- setStoredResult({ query: trimmed, value: { kindResult, subject: null, overpassQL: null, overpassError: null } })
204
-
205
- return
248
+ setStoredClassifyError({ query: trimmed, message: error instanceof Error ? error.message : String(error) })
206
249
  }
207
-
208
- setStoredResult({
209
- query: trimmed,
210
- value: {
211
- kindResult,
212
- subject: {
213
- kind: "category",
214
- category,
215
- matchedPhrase: matched.match.matchedPhrase,
216
- confidence: matched.match.confidence,
217
- remainder: matched.remainder,
218
- buildLocal: runtime.lookup.requiresBuildLocalLayer(category),
219
- },
220
- ...buildOverpass(runtime, matched.match.categoryID),
221
- },
222
- })
223
- })
250
+ )
224
251
 
225
252
  return () => {
226
253
  cancelled = true
@@ -228,6 +255,7 @@ export function usePOISearch({
228
255
  }, [trimmedText, runtime])
229
256
 
230
257
  const result = storedResult?.query === trimmedText ? storedResult.value : null
258
+ const error = runtimeError ?? (storedClassifyError?.query === trimmedText ? storedClassifyError.message : null)
231
259
  const liveSearch: LiveSearchState = storedLive?.query === trimmedText ? storedLive.state : { status: "idle" }
232
260
 
233
261
  const subject = result?.subject ?? null
@@ -287,5 +315,5 @@ export function usePOISearch({
287
315
  }
288
316
  }, [runLiveSearch, runtime, subject, brandLiveSearch, trimmedText])
289
317
 
290
- return { runtimeReady: runtime !== null, result, liveSearch, canSearchLive, searchLive }
318
+ return { runtimeReady: runtime !== null, result, error, liveSearch, canSearchLive, searchLive }
291
319
  }
package/lib/poi.ts CHANGED
@@ -1,7 +1,7 @@
1
+ // SPDX-FileCopyrightText: Teffen Ellis and Mailwoman contributors
2
+ // SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial
3
+
1
4
  /**
2
- * @copyright Sister Software
3
- * @license AGPL-3.0
4
- * @author Teffen Ellis, et al.
5
5
  * @file POI explorer components, hooks, runtime and interfaces.
6
6
  */
7
7