@performant-software/geospatial 3.1.18-beta.0 → 3.1.18-beta.10

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 (365) hide show
  1. package/dist/index.cjs100.js +1 -1
  2. package/dist/index.cjs101.js +1 -1
  3. package/dist/index.cjs102.js +1 -1
  4. package/dist/index.cjs103.js +1 -1
  5. package/dist/index.cjs106.js +1 -1
  6. package/dist/index.cjs107.js +1 -1
  7. package/dist/index.cjs109.js +1 -1
  8. package/dist/index.cjs110.js +1 -1
  9. package/dist/index.cjs111.js +1 -1
  10. package/dist/index.cjs112.js +1 -1
  11. package/dist/index.cjs117.js +1 -1
  12. package/dist/index.cjs118.js +1 -1
  13. package/dist/index.cjs119.js +1 -1
  14. package/dist/index.cjs120.js +1 -1
  15. package/dist/index.cjs123.js +1 -1
  16. package/dist/index.cjs124.js +1 -1
  17. package/dist/index.cjs125.js +1 -1
  18. package/dist/index.cjs129.js +1 -1
  19. package/dist/index.cjs13.js +1 -1
  20. package/dist/index.cjs13.js.map +1 -1
  21. package/dist/index.cjs132.js +1 -1
  22. package/dist/index.cjs136.js +1 -1
  23. package/dist/index.cjs139.js +1 -1
  24. package/dist/index.cjs147.js +1 -1
  25. package/dist/index.cjs148.js +1 -1
  26. package/dist/index.cjs149.js +1 -1
  27. package/dist/index.cjs150.js +1 -1
  28. package/dist/index.cjs151.js +1 -1
  29. package/dist/index.cjs152.js +1 -1
  30. package/dist/index.cjs153.js +1 -1
  31. package/dist/index.cjs155.js +1 -1
  32. package/dist/index.cjs156.js +1 -1
  33. package/dist/index.cjs157.js +1 -1
  34. package/dist/index.cjs158.js +1 -1
  35. package/dist/index.cjs159.js +1 -1
  36. package/dist/index.cjs16.js +1 -1
  37. package/dist/index.cjs160.js +1 -1
  38. package/dist/index.cjs161.js +1 -1
  39. package/dist/index.cjs162.js +1 -1
  40. package/dist/index.cjs163.js +1 -1
  41. package/dist/index.cjs166.js +1 -1
  42. package/dist/index.cjs167.js +1 -1
  43. package/dist/index.cjs169.js +1 -1
  44. package/dist/index.cjs17.js +1 -1
  45. package/dist/index.cjs170.js +1 -1
  46. package/dist/index.cjs171.js +1 -1
  47. package/dist/index.cjs172.js +1 -1
  48. package/dist/index.cjs173.js +1 -1
  49. package/dist/index.cjs174.js +1 -1
  50. package/dist/index.cjs175.js +1 -1
  51. package/dist/index.cjs176.js +1 -1
  52. package/dist/index.cjs18.js +1 -1
  53. package/dist/index.cjs182.js +1 -1
  54. package/dist/index.cjs183.js +1 -1
  55. package/dist/index.cjs184.js +1 -1
  56. package/dist/index.cjs185.js +1 -1
  57. package/dist/index.cjs186.js +1 -1
  58. package/dist/index.cjs19.js +1 -1
  59. package/dist/index.cjs2.js +1 -1
  60. package/dist/index.cjs2.js.map +1 -1
  61. package/dist/index.cjs20.js +1 -1
  62. package/dist/index.cjs205.js +1 -1
  63. package/dist/index.cjs205.js.map +1 -1
  64. package/dist/index.cjs206.js +1 -1
  65. package/dist/index.cjs206.js.map +1 -1
  66. package/dist/index.cjs207.js +1 -1
  67. package/dist/index.cjs207.js.map +1 -1
  68. package/dist/index.cjs208.js +1 -1
  69. package/dist/index.cjs208.js.map +1 -1
  70. package/dist/index.cjs209.js +1 -1
  71. package/dist/index.cjs209.js.map +1 -1
  72. package/dist/index.cjs21.js +1 -1
  73. package/dist/index.cjs210.js +1 -1
  74. package/dist/index.cjs210.js.map +1 -1
  75. package/dist/index.cjs211.js +1 -1
  76. package/dist/index.cjs211.js.map +1 -1
  77. package/dist/index.cjs212.js +1 -1
  78. package/dist/index.cjs212.js.map +1 -1
  79. package/dist/index.cjs213.js +1 -1
  80. package/dist/index.cjs213.js.map +1 -1
  81. package/dist/index.cjs214.js +1 -1
  82. package/dist/index.cjs214.js.map +1 -1
  83. package/dist/index.cjs215.js +1 -1
  84. package/dist/index.cjs215.js.map +1 -1
  85. package/dist/index.cjs216.js +1 -1
  86. package/dist/index.cjs216.js.map +1 -1
  87. package/dist/index.cjs217.js +1 -1
  88. package/dist/index.cjs217.js.map +1 -1
  89. package/dist/index.cjs218.js +1 -1
  90. package/dist/index.cjs218.js.map +1 -1
  91. package/dist/index.cjs219.js +1 -1
  92. package/dist/index.cjs219.js.map +1 -1
  93. package/dist/index.cjs22.js +1 -1
  94. package/dist/index.cjs220.js +1 -1
  95. package/dist/index.cjs220.js.map +1 -1
  96. package/dist/index.cjs221.js +1 -1
  97. package/dist/index.cjs221.js.map +1 -1
  98. package/dist/index.cjs222.js +1 -1
  99. package/dist/index.cjs222.js.map +1 -1
  100. package/dist/index.cjs223.js +1 -1
  101. package/dist/index.cjs223.js.map +1 -1
  102. package/dist/index.cjs224.js +1 -1
  103. package/dist/index.cjs224.js.map +1 -1
  104. package/dist/index.cjs225.js +1 -1
  105. package/dist/index.cjs225.js.map +1 -1
  106. package/dist/index.cjs226.js +1 -1
  107. package/dist/index.cjs226.js.map +1 -1
  108. package/dist/index.cjs227.js +1 -1
  109. package/dist/index.cjs227.js.map +1 -1
  110. package/dist/index.cjs228.js +1 -1
  111. package/dist/index.cjs228.js.map +1 -1
  112. package/dist/index.cjs229.js +1 -1
  113. package/dist/index.cjs229.js.map +1 -1
  114. package/dist/index.cjs23.js +1 -1
  115. package/dist/index.cjs230.js +1 -1
  116. package/dist/index.cjs230.js.map +1 -1
  117. package/dist/index.cjs231.js +1 -1
  118. package/dist/index.cjs231.js.map +1 -1
  119. package/dist/index.cjs232.js +1 -1
  120. package/dist/index.cjs232.js.map +1 -1
  121. package/dist/index.cjs233.js +1 -1
  122. package/dist/index.cjs233.js.map +1 -1
  123. package/dist/index.cjs234.js +1 -1
  124. package/dist/index.cjs234.js.map +1 -1
  125. package/dist/index.cjs235.js +1 -1
  126. package/dist/index.cjs235.js.map +1 -1
  127. package/dist/index.cjs236.js +1 -1
  128. package/dist/index.cjs236.js.map +1 -1
  129. package/dist/index.cjs237.js +1 -1
  130. package/dist/index.cjs237.js.map +1 -1
  131. package/dist/index.cjs238.js +1 -1
  132. package/dist/index.cjs238.js.map +1 -1
  133. package/dist/index.cjs239.js +1 -1
  134. package/dist/index.cjs239.js.map +1 -1
  135. package/dist/index.cjs24.js +1 -1
  136. package/dist/index.cjs242.js +1 -1
  137. package/dist/index.cjs243.js +1 -1
  138. package/dist/index.cjs243.js.map +1 -1
  139. package/dist/index.cjs244.js +1 -1
  140. package/dist/index.cjs244.js.map +1 -1
  141. package/dist/index.cjs245.js +1 -1
  142. package/dist/index.cjs245.js.map +1 -1
  143. package/dist/index.cjs246.js +1 -1
  144. package/dist/index.cjs246.js.map +1 -1
  145. package/dist/index.cjs25.js +1 -1
  146. package/dist/index.cjs254.js +1 -1
  147. package/dist/index.cjs258.js +1 -1
  148. package/dist/index.cjs259.js +1 -1
  149. package/dist/index.cjs26.js +1 -1
  150. package/dist/index.cjs262.js +1 -1
  151. package/dist/index.cjs266.js +1 -1
  152. package/dist/index.cjs266.js.map +1 -1
  153. package/dist/index.cjs267.js +1 -1
  154. package/dist/index.cjs267.js.map +1 -1
  155. package/dist/index.cjs268.js +1 -1
  156. package/dist/index.cjs268.js.map +1 -1
  157. package/dist/index.cjs27.js +1 -1
  158. package/dist/index.cjs38.js +1 -1
  159. package/dist/index.cjs40.js +1 -1
  160. package/dist/index.cjs42.js +1 -1
  161. package/dist/index.cjs43.js +1 -1
  162. package/dist/index.cjs44.js +1 -1
  163. package/dist/index.cjs46.js +1 -1
  164. package/dist/index.cjs47.js +1 -1
  165. package/dist/index.cjs48.js +1 -1
  166. package/dist/index.cjs50.js +1 -1
  167. package/dist/index.cjs51.js +1 -1
  168. package/dist/index.cjs52.js +1 -1
  169. package/dist/index.cjs56.js +1 -1
  170. package/dist/index.cjs57.js +1 -1
  171. package/dist/index.cjs58.js +1 -1
  172. package/dist/index.cjs60.js +1 -1
  173. package/dist/index.cjs61.js +1 -1
  174. package/dist/index.cjs63.js +1 -1
  175. package/dist/index.cjs88.js +1 -1
  176. package/dist/index.cjs95.js +1 -1
  177. package/dist/index.cjs96.js +1 -1
  178. package/dist/index.cjs97.js +1 -1
  179. package/dist/index.cjs98.js +1 -1
  180. package/dist/index.cjs99.js +1 -1
  181. package/dist/index.es100.js +1 -1
  182. package/dist/index.es101.js +1 -1
  183. package/dist/index.es102.js +1 -1
  184. package/dist/index.es103.js +1 -1
  185. package/dist/index.es106.js +1 -1
  186. package/dist/index.es107.js +1 -1
  187. package/dist/index.es109.js +3 -3
  188. package/dist/index.es110.js +1 -1
  189. package/dist/index.es111.js +2 -2
  190. package/dist/index.es112.js +1 -1
  191. package/dist/index.es117.js +1 -1
  192. package/dist/index.es118.js +1 -1
  193. package/dist/index.es119.js +1 -1
  194. package/dist/index.es120.js +1 -1
  195. package/dist/index.es123.js +2 -2
  196. package/dist/index.es124.js +2 -2
  197. package/dist/index.es125.js +1 -1
  198. package/dist/index.es129.js +2 -2
  199. package/dist/index.es13.js +65 -42
  200. package/dist/index.es13.js.map +1 -1
  201. package/dist/index.es132.js +1 -1
  202. package/dist/index.es136.js +1 -1
  203. package/dist/index.es139.js +1 -1
  204. package/dist/index.es147.js +1 -1
  205. package/dist/index.es148.js +1 -1
  206. package/dist/index.es149.js +1 -1
  207. package/dist/index.es150.js +2 -2
  208. package/dist/index.es151.js +1 -1
  209. package/dist/index.es152.js +1 -1
  210. package/dist/index.es153.js +1 -1
  211. package/dist/index.es155.js +2 -2
  212. package/dist/index.es156.js +2 -2
  213. package/dist/index.es157.js +1 -1
  214. package/dist/index.es158.js +1 -1
  215. package/dist/index.es159.js +1 -1
  216. package/dist/index.es16.js +4 -4
  217. package/dist/index.es160.js +1 -1
  218. package/dist/index.es161.js +2 -2
  219. package/dist/index.es162.js +2 -2
  220. package/dist/index.es163.js +1 -1
  221. package/dist/index.es166.js +2 -2
  222. package/dist/index.es167.js +2 -2
  223. package/dist/index.es169.js +2 -2
  224. package/dist/index.es17.js +3 -3
  225. package/dist/index.es170.js +1 -1
  226. package/dist/index.es171.js +2 -2
  227. package/dist/index.es172.js +1 -1
  228. package/dist/index.es173.js +2 -2
  229. package/dist/index.es174.js +1 -1
  230. package/dist/index.es175.js +1 -1
  231. package/dist/index.es176.js +1 -1
  232. package/dist/index.es18.js +3 -3
  233. package/dist/index.es182.js +1 -1
  234. package/dist/index.es183.js +2 -2
  235. package/dist/index.es184.js +1 -1
  236. package/dist/index.es185.js +1 -1
  237. package/dist/index.es186.js +1 -1
  238. package/dist/index.es19.js +1 -1
  239. package/dist/index.es2.js +7 -7
  240. package/dist/index.es2.js.map +1 -1
  241. package/dist/index.es20.js +1 -1
  242. package/dist/index.es205.js +242 -7
  243. package/dist/index.es205.js.map +1 -1
  244. package/dist/index.es206.js +42 -4
  245. package/dist/index.es206.js.map +1 -1
  246. package/dist/index.es207.js +3 -4
  247. package/dist/index.es207.js.map +1 -1
  248. package/dist/index.es208.js +11 -3
  249. package/dist/index.es208.js.map +1 -1
  250. package/dist/index.es209.js +11 -3
  251. package/dist/index.es209.js.map +1 -1
  252. package/dist/index.es21.js +1 -1
  253. package/dist/index.es210.js +30 -8
  254. package/dist/index.es210.js.map +1 -1
  255. package/dist/index.es211.js +13 -18
  256. package/dist/index.es211.js.map +1 -1
  257. package/dist/index.es212.js +4 -20
  258. package/dist/index.es212.js.map +1 -1
  259. package/dist/index.es213.js +6 -11
  260. package/dist/index.es213.js.map +1 -1
  261. package/dist/index.es214.js +4 -14
  262. package/dist/index.es214.js.map +1 -1
  263. package/dist/index.es215.js +4 -6
  264. package/dist/index.es215.js.map +1 -1
  265. package/dist/index.es216.js +3 -8
  266. package/dist/index.es216.js.map +1 -1
  267. package/dist/index.es217.js +3 -7
  268. package/dist/index.es217.js.map +1 -1
  269. package/dist/index.es218.js +8 -21
  270. package/dist/index.es218.js.map +1 -1
  271. package/dist/index.es219.js +17 -8
  272. package/dist/index.es219.js.map +1 -1
  273. package/dist/index.es22.js +1 -1
  274. package/dist/index.es220.js +21 -9
  275. package/dist/index.es220.js.map +1 -1
  276. package/dist/index.es221.js +13 -4
  277. package/dist/index.es221.js.map +1 -1
  278. package/dist/index.es222.js +14 -10
  279. package/dist/index.es222.js.map +1 -1
  280. package/dist/index.es223.js +5 -7
  281. package/dist/index.es223.js.map +1 -1
  282. package/dist/index.es224.js +6 -19
  283. package/dist/index.es224.js.map +1 -1
  284. package/dist/index.es225.js +6 -10
  285. package/dist/index.es225.js.map +1 -1
  286. package/dist/index.es226.js +20 -16
  287. package/dist/index.es226.js.map +1 -1
  288. package/dist/index.es227.js +10 -4
  289. package/dist/index.es227.js.map +1 -1
  290. package/dist/index.es228.js +9 -18
  291. package/dist/index.es228.js.map +1 -1
  292. package/dist/index.es229.js +4 -12
  293. package/dist/index.es229.js.map +1 -1
  294. package/dist/index.es23.js +1 -1
  295. package/dist/index.es230.js +10 -3
  296. package/dist/index.es230.js.map +1 -1
  297. package/dist/index.es231.js +7 -4
  298. package/dist/index.es231.js.map +1 -1
  299. package/dist/index.es232.js +20 -242
  300. package/dist/index.es232.js.map +1 -1
  301. package/dist/index.es233.js +9 -41
  302. package/dist/index.es233.js.map +1 -1
  303. package/dist/index.es234.js +18 -3
  304. package/dist/index.es234.js.map +1 -1
  305. package/dist/index.es235.js +3 -10
  306. package/dist/index.es235.js.map +1 -1
  307. package/dist/index.es236.js +17 -10
  308. package/dist/index.es236.js.map +1 -1
  309. package/dist/index.es237.js +11 -30
  310. package/dist/index.es237.js.map +1 -1
  311. package/dist/index.es238.js +3 -13
  312. package/dist/index.es238.js.map +1 -1
  313. package/dist/index.es239.js +4 -4
  314. package/dist/index.es239.js.map +1 -1
  315. package/dist/index.es24.js +1 -1
  316. package/dist/index.es242.js +1 -1
  317. package/dist/index.es243.js +19 -6
  318. package/dist/index.es243.js.map +1 -1
  319. package/dist/index.es244.js +22 -5
  320. package/dist/index.es244.js.map +1 -1
  321. package/dist/index.es245.js +4 -19
  322. package/dist/index.es245.js.map +1 -1
  323. package/dist/index.es246.js +7 -22
  324. package/dist/index.es246.js.map +1 -1
  325. package/dist/index.es25.js +1 -1
  326. package/dist/index.es254.js +1 -1
  327. package/dist/index.es258.js +1 -1
  328. package/dist/index.es259.js +2 -2
  329. package/dist/index.es26.js +2 -2
  330. package/dist/index.es262.js +1 -1
  331. package/dist/index.es266.js +15 -4
  332. package/dist/index.es266.js.map +1 -1
  333. package/dist/index.es267.js +4 -69
  334. package/dist/index.es267.js.map +1 -1
  335. package/dist/index.es268.js +69 -15
  336. package/dist/index.es268.js.map +1 -1
  337. package/dist/index.es27.js +2 -2
  338. package/dist/index.es38.js +1 -1
  339. package/dist/index.es40.js +2 -2
  340. package/dist/index.es42.js +2 -2
  341. package/dist/index.es43.js +2 -2
  342. package/dist/index.es44.js +2 -2
  343. package/dist/index.es46.js +1 -1
  344. package/dist/index.es47.js +2 -2
  345. package/dist/index.es48.js +2 -2
  346. package/dist/index.es50.js +1 -1
  347. package/dist/index.es51.js +1 -1
  348. package/dist/index.es52.js +1 -1
  349. package/dist/index.es56.js +2 -2
  350. package/dist/index.es57.js +3 -3
  351. package/dist/index.es58.js +1 -1
  352. package/dist/index.es60.js +1 -1
  353. package/dist/index.es61.js +1 -1
  354. package/dist/index.es63.js +1 -1
  355. package/dist/index.es88.js +1 -1
  356. package/dist/index.es95.js +1 -1
  357. package/dist/index.es96.js +1 -1
  358. package/dist/index.es97.js +1 -1
  359. package/dist/index.es98.js +1 -1
  360. package/dist/index.es99.js +1 -1
  361. package/package.json +1 -1
  362. package/src/components/CertaintyLayer.js +10 -4
  363. package/src/utils/Map.js +36 -27
  364. package/types/components/CertaintyLayer.js.flow +10 -4
  365. package/types/utils/Map.js.flow +36 -27
@@ -1,2 +1,2 @@
1
- "use strict";const t=require("./index.cjs89.js"),c=require("./index.cjs38.js"),l=require("./index.cjs156.js"),f=require("./index.cjs216.js"),q=require("./index.cjs215.js"),v=t(function(s,e,o){var i,u;return c(e)?u=e:(e=q(e),i=e.slice(0,-1),e=e[e.length-1]),l(s,function(r){var n=u;if(!n){if(i&&i.length&&(r=f(r,i)),r==null)return;n=r[e]}return n==null?n:n.apply(r,o)})});module.exports=v;
1
+ "use strict";const t=require("./index.cjs89.js"),c=require("./index.cjs38.js"),l=require("./index.cjs156.js"),f=require("./index.cjs224.js"),q=require("./index.cjs223.js"),v=t(function(s,e,o){var i,u;return c(e)?u=e:(e=q(e),i=e.slice(0,-1),e=e[e.length-1]),l(s,function(r){var n=u;if(!n){if(i&&i.length&&(r=f(r,i)),r==null)return;n=r[e]}return n==null?n:n.apply(r,o)})});module.exports=v;
2
2
  //# sourceMappingURL=index.cjs56.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const l=require("./index.cjs89.js"),f=require("./index.cjs38.js"),a=require("./index.cjs218.js"),o=require("./index.cjs112.js"),q=require("./index.cjs230.js"),g=require("./index.cjs224.js"),p=l(function(t,r){var n={},e=r[0];if(t==null)return n;f(e)?(r.length>1&&(e=a(e,r[1])),r=o(t)):(e=q,r=g(r,!1,!1),t=Object(t));for(var i=0,s=r.length;i<s;i++){var u=r[i],c=t[u];e(c,u,t)&&(n[u]=c)}return n});module.exports=p;
1
+ "use strict";const l=require("./index.cjs89.js"),f=require("./index.cjs38.js"),a=require("./index.cjs226.js"),o=require("./index.cjs112.js"),q=require("./index.cjs238.js"),g=require("./index.cjs232.js"),p=l(function(t,r){var n={},e=r[0];if(t==null)return n;f(e)?(r.length>1&&(e=a(e,r[1])),r=o(t)):(e=q,r=g(r,!1,!1),t=Object(t));for(var i=0,s=r.length;i<s;i++){var u=r[i],c=t[u];e(c,u,t)&&(n[u]=c)}return n});module.exports=p;
2
2
  //# sourceMappingURL=index.cjs57.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const c=require("./index.cjs89.js"),o=require("./index.cjs38.js"),u=require("./index.cjs143.js"),s=require("./index.cjs156.js"),a=require("./index.cjs224.js"),f=require("./index.cjs163.js"),q=require("./index.cjs57.js"),l=c(function(n,t){var e=t[0],r;return o(e)?(e=u(e),t.length>1&&(r=t[1])):(t=s(a(t,!1,!1),String),e=function(g,i){return!f(t,i)}),q(n,e,r)});module.exports=l;
1
+ "use strict";const c=require("./index.cjs89.js"),o=require("./index.cjs38.js"),u=require("./index.cjs143.js"),s=require("./index.cjs156.js"),a=require("./index.cjs232.js"),f=require("./index.cjs163.js"),q=require("./index.cjs57.js"),l=c(function(n,t){var e=t[0],r;return o(e)?(e=u(e),t.length>1&&(r=t[1])):(t=s(a(t,!1,!1),String),e=function(g,i){return!f(t,i)}),q(n,e,r)});module.exports=l;
2
2
  //# sourceMappingURL=index.cjs58.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const e=require("./index.cjs89.js"),r=require("./index.cjs183.js"),n=require("./index.cjs224.js"),u=e(function(t){return r(n(t,!0,!0))});module.exports=u;
1
+ "use strict";const e=require("./index.cjs89.js"),r=require("./index.cjs183.js"),n=require("./index.cjs232.js"),u=e(function(t){return r(n(t,!0,!0))});module.exports=u;
2
2
  //# sourceMappingURL=index.cjs60.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const n=require("./index.cjs89.js"),u=require("./index.cjs224.js"),c=require("./index.cjs159.js"),i=require("./index.cjs163.js"),o=n(function(r,e){return e=u(e,!0,!0),c(r,function(t){return!i(e,t)})});module.exports=o;
1
+ "use strict";const n=require("./index.cjs89.js"),u=require("./index.cjs232.js"),c=require("./index.cjs159.js"),i=require("./index.cjs163.js"),o=n(function(r,e){return e=u(e,!0,!0),c(r,function(t){return!i(e,t)})});module.exports=o;
2
2
  //# sourceMappingURL=index.cjs61.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const o=require("./index.cjs41.js"),s=require("./index.cjs155.js"),i=require("./index.cjs37.js"),n=require("./index.cjs231.js");s(["pop","push","reverse","shift","sort","splice","unshift"],function(r){var e=i.ArrayProto[r];o.prototype[r]=function(){var t=this._wrapped;return t!=null&&(e.apply(t,arguments),(r==="shift"||r==="splice")&&t.length===0&&delete t[0]),n(this,t)}});s(["concat","join","slice"],function(r){var e=i.ArrayProto[r];o.prototype[r]=function(){var t=this._wrapped;return t!=null&&(t=e.apply(t,arguments)),n(this,t)}});module.exports=o;
1
+ "use strict";const o=require("./index.cjs41.js"),s=require("./index.cjs155.js"),i=require("./index.cjs37.js"),n=require("./index.cjs239.js");s(["pop","push","reverse","shift","sort","splice","unshift"],function(r){var e=i.ArrayProto[r];o.prototype[r]=function(){var t=this._wrapped;return t!=null&&(e.apply(t,arguments),(r==="shift"||r==="splice")&&t.length===0&&delete t[0]),n(this,t)}});s(["concat","join","slice"],function(r){var e=i.ArrayProto[r];o.prototype[r]=function(){var t=this._wrapped;return t!=null&&(t=e.apply(t,arguments)),n(this,t)}});module.exports=o;
2
2
  //# sourceMappingURL=index.cjs63.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const r=require("./index.cjs41.js"),s=require("./index.cjs155.js"),i=require("./index.cjs116.js"),c=require("./index.cjs37.js"),o=require("./index.cjs231.js");function p(e){return s(i(e),function(t){var u=r[t]=e[t];r.prototype[t]=function(){var n=[this._wrapped];return c.push.apply(n,arguments),o(this,u.apply(r,n))}}),r}module.exports=p;
1
+ "use strict";const r=require("./index.cjs41.js"),s=require("./index.cjs155.js"),i=require("./index.cjs116.js"),c=require("./index.cjs37.js"),o=require("./index.cjs239.js");function p(e){return s(i(e),function(t){var u=r[t]=e[t];r.prototype[t]=function(){var n=[this._wrapped];return c.push.apply(n,arguments),o(this,u.apply(r,n))}}),r}module.exports=p;
2
2
  //# sourceMappingURL=index.cjs88.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const t=require("./index.cjs205.js"),r=t("String");module.exports=r;
1
+ "use strict";const t=require("./index.cjs213.js"),r=t("String");module.exports=r;
2
2
  //# sourceMappingURL=index.cjs95.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const e=require("./index.cjs205.js"),r=e("Number");module.exports=r;
1
+ "use strict";const e=require("./index.cjs213.js"),r=e("Number");module.exports=r;
2
2
  //# sourceMappingURL=index.cjs96.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const t=require("./index.cjs205.js"),e=t("Date");module.exports=e;
1
+ "use strict";const t=require("./index.cjs213.js"),e=t("Date");module.exports=e;
2
2
  //# sourceMappingURL=index.cjs97.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const e=require("./index.cjs205.js"),s=e("RegExp");module.exports=s;
1
+ "use strict";const e=require("./index.cjs213.js"),s=e("RegExp");module.exports=s;
2
2
  //# sourceMappingURL=index.cjs98.js.map
@@ -1,2 +1,2 @@
1
- "use strict";const r=require("./index.cjs205.js"),s=r("Error");module.exports=s;
1
+ "use strict";const r=require("./index.cjs213.js"),s=r("Error");module.exports=s;
2
2
  //# sourceMappingURL=index.cjs99.js.map
@@ -1,4 +1,4 @@
1
- import o from "./index.es205.js";
1
+ import o from "./index.es213.js";
2
2
  const e = o("Symbol");
3
3
  export {
4
4
  e as default
@@ -1,4 +1,4 @@
1
- import r from "./index.es205.js";
1
+ import r from "./index.es213.js";
2
2
  const f = r("ArrayBuffer");
3
3
  export {
4
4
  f as default
@@ -1,4 +1,4 @@
1
- import a from "./index.es205.js";
1
+ import a from "./index.es213.js";
2
2
  import r from "./index.es38.js";
3
3
  import e from "./index.es101.js";
4
4
  import { hasDataViewBug as i } from "./index.es39.js";
@@ -1,5 +1,5 @@
1
1
  import { nativeIsArray as r } from "./index.es37.js";
2
- import t from "./index.es205.js";
2
+ import t from "./index.es213.js";
3
3
  const e = r || t("Array");
4
4
  export {
5
5
  e as default
@@ -1,7 +1,7 @@
1
1
  import { supportsArrayBuffer as i, nativeIsView as t, toString as a } from "./index.es37.js";
2
2
  import e from "./index.es102.js";
3
3
  import o from "./index.es127.js";
4
- import n from "./index.es207.js";
4
+ import n from "./index.es215.js";
5
5
  var s = /\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/;
6
6
  function f(r) {
7
7
  return t ? t(r) && !e(r) : n(r) && s.test(a.call(r));
@@ -1,4 +1,4 @@
1
- import e from "./index.es208.js";
1
+ import e from "./index.es216.js";
2
2
  import i from "./index.es103.js";
3
3
  import m from "./index.es95.js";
4
4
  import n from "./index.es40.js";
@@ -1,13 +1,13 @@
1
1
  import m from "./index.es41.js";
2
2
  import { toString as h, SymbolProto as j } from "./index.es37.js";
3
- import g from "./index.es209.js";
3
+ import g from "./index.es217.js";
4
4
  import V from "./index.es106.js";
5
5
  import y from "./index.es38.js";
6
6
  import { hasDataViewBug as A } from "./index.es39.js";
7
7
  import w from "./index.es102.js";
8
8
  import v from "./index.es111.js";
9
- import a from "./index.es206.js";
10
- import d from "./index.es210.js";
9
+ import a from "./index.es214.js";
10
+ import d from "./index.es218.js";
11
11
  var B = "[object DataView]";
12
12
  function c(e, r, f, n) {
13
13
  if (e === r) return e !== 0 || 1 / e === 1 / r;
@@ -1,4 +1,4 @@
1
- import e from "./index.es205.js";
1
+ import e from "./index.es213.js";
2
2
  const a = e("WeakSet");
3
3
  export {
4
4
  a as default
@@ -1,7 +1,7 @@
1
1
  import e from "./index.es90.js";
2
2
  import { nativeKeys as f, hasEnumBug as m } from "./index.es37.js";
3
- import n from "./index.es206.js";
4
- import o from "./index.es212.js";
3
+ import n from "./index.es214.js";
4
+ import o from "./index.es220.js";
5
5
  function c(r) {
6
6
  if (!e(r)) return [];
7
7
  if (f) return f(r);
@@ -1,6 +1,6 @@
1
1
  import e from "./index.es90.js";
2
2
  import { hasEnumBug as f } from "./index.es37.js";
3
- import i from "./index.es212.js";
3
+ import i from "./index.es220.js";
4
4
  function s(r) {
5
5
  if (!e(r)) return [];
6
6
  var o = [];
@@ -1,4 +1,4 @@
1
- import e from "./index.es213.js";
1
+ import e from "./index.es221.js";
2
2
  import r from "./index.es112.js";
3
3
  const s = e(r);
4
4
  export {
@@ -1,4 +1,4 @@
1
- import e from "./index.es213.js";
1
+ import e from "./index.es221.js";
2
2
  import r from "./index.es111.js";
3
3
  const s = e(r);
4
4
  export {
@@ -1,4 +1,4 @@
1
- import e from "./index.es213.js";
1
+ import e from "./index.es221.js";
2
2
  import r from "./index.es112.js";
3
3
  const s = e(r, !0);
4
4
  export {
@@ -1,4 +1,4 @@
1
- import a from "./index.es214.js";
1
+ import a from "./index.es222.js";
2
2
  import f from "./index.es118.js";
3
3
  function i(t, e) {
4
4
  var r = a(t);
@@ -1,5 +1,5 @@
1
- import f from "./index.es215.js";
2
- import i from "./index.es216.js";
1
+ import f from "./index.es223.js";
2
+ import i from "./index.es224.js";
3
3
  import m from "./index.es92.js";
4
4
  function d(e, r, o) {
5
5
  var t = i(e, f(r));
@@ -1,5 +1,5 @@
1
- import n from "./index.es206.js";
2
- import o from "./index.es215.js";
1
+ import n from "./index.es214.js";
2
+ import o from "./index.es223.js";
3
3
  function s(t, r) {
4
4
  r = o(r);
5
5
  for (var a = r.length, f = 0; f < a; f++) {
@@ -1,4 +1,4 @@
1
- import t from "./index.es217.js";
1
+ import t from "./index.es225.js";
2
2
  import v from "./index.es111.js";
3
3
  function k(r, f, l) {
4
4
  f = t(f, l);
@@ -1,5 +1,5 @@
1
- import o from "./index.es216.js";
2
- import e from "./index.es215.js";
1
+ import o from "./index.es224.js";
2
+ import e from "./index.es223.js";
3
3
  function u(r) {
4
4
  return r = e(r), function(t) {
5
5
  return o(t, r);
@@ -1,10 +1,10 @@
1
1
  import { WarpedMapLayer as c } from "./index.es68.js";
2
- import { bbox as n } from "./index.es69.js";
2
+ import { bbox as m } from "./index.es69.js";
3
3
  import { bboxPolygon as u } from "./index.es70.js";
4
4
  import { buffer as y } from "./index.es71.js";
5
- import d from "./index.es72.js";
6
- import { featureCollection as s, feature as g } from "./index.es67.js";
7
- import p from "./index.es36.js";
5
+ import f from "./index.es72.js";
6
+ import { featureCollection as d, feature as g } from "./index.es67.js";
7
+ import l from "./index.es36.js";
8
8
  import "./index.es37.js";
9
9
  import "./index.es38.js";
10
10
  import "./index.es39.js";
@@ -32,29 +32,52 @@ import "./index.es60.js";
32
32
  import "./index.es61.js";
33
33
  import "./index.es62.js";
34
34
  import "./index.es63.js";
35
- const _ = -90, L = 90, I = -180, M = 180, m = (t, r) => d(t.coordinates, r, { units: "kilometers", steps: 32 }), b = (t, r) => {
36
- const o = [];
37
- for (const e of t)
38
- if (r(e))
39
- if (e.geometry?.type === "FeatureCollection")
40
- for (const i of e.geometry.features)
41
- i.geometry?.type === "Point" && o.push(m(i.geometry, r(e)));
42
- else if (e.geometry.type === "GeometryCollection")
43
- for (const i of e.geometry.geometries)
44
- i.type === "Point" && o.push(m(i, r(e)));
45
- else e.geometry?.type === "Point" && o.push(m(e.geometry, r(e)));
46
- return s(o);
47
- }, v = (t, r, o = {}) => {
48
- const e = new c(r);
49
- t.addLayer(e), o.url ? e.addGeoreferenceAnnotationByUrl(o.url) : o.manifest && e.addGeoreferenceAnnotation(o.manifest), o.opacity && e.setOpacity(o.opacity);
50
- }, x = (t, r = null) => {
51
- const o = n(t);
52
- if (!l(o))
35
+ const _ = -90, L = 90, C = -180, G = 180, p = (t, r) => f(t.coordinates, r, { units: "kilometers", steps: 32 }), I = (t, r) => {
36
+ if (t.geometry?.type === "FeatureCollection") {
37
+ let e = [];
38
+ for (const o of t.geometry.features)
39
+ if (o.geometry?.type === "Point") {
40
+ const { geometry: i, type: n } = p(o.geometry, r);
41
+ e.push({
42
+ ...o,
43
+ geometry: i,
44
+ type: n
45
+ });
46
+ }
47
+ return {
48
+ ...t,
49
+ geometry: {
50
+ type: "GeometryCollection",
51
+ geometries: e
52
+ }
53
+ };
54
+ } else {
55
+ if (t?.type === "GeometryCollection")
56
+ return {
57
+ ...t,
58
+ geometries: t.geometries.map((e) => e.type === "Point" ? p(e, r) : e)
59
+ };
60
+ if (t.geometry?.type === "Point") {
61
+ const { geometry: e, type: o } = p(t.geometry, r);
62
+ return {
63
+ ...t,
64
+ geometry: e,
65
+ type: o
66
+ };
67
+ }
68
+ }
69
+ return t;
70
+ }, M = (t, r, e = {}) => {
71
+ const o = new c(r);
72
+ t.addLayer(o), e.url ? o.addGeoreferenceAnnotationByUrl(e.url) : e.manifest && o.addGeoreferenceAnnotation(e.manifest), e.opacity && o.setOpacity(e.opacity);
73
+ }, b = (t, r = null) => {
74
+ const e = m(t);
75
+ if (!a(e))
53
76
  return null;
54
- const e = u(o);
77
+ const o = u(e);
55
78
  let i;
56
- return r ? i = y(e, r, { units: "miles" }) : i = e, n(i);
57
- }, A = (t, r) => t && t.removeLayer(r), B = (t, r, o, e) => {
79
+ return r ? i = y(o, r, { units: "miles" }) : i = o, m(i);
80
+ }, v = (t, r) => t && t.removeLayer(r), x = (t, r, e, o) => {
58
81
  const i = {
59
82
  id: t.record_id,
60
83
  ccode: [],
@@ -62,31 +85,31 @@ const _ = -90, L = 90, I = -180, M = 180, m = (t, r) => d(t.coordinates, r, { un
62
85
  uuid: t.uuid,
63
86
  record_id: t.record_id,
64
87
  name: t.name,
65
- names: t.names?.map((f) => ({ toponym: f })),
88
+ names: t.names?.map((s) => ({ toponym: s })),
66
89
  type: t.type,
67
90
  items: [r],
68
91
  url: t.url,
69
- originalProperties: e || {}
70
- }, a = parseInt(t.record_id, 10);
71
- return g(o, i, { id: a });
72
- }, G = (t) => s(t), l = (t) => p.every(t, p.isFinite), T = (t) => {
92
+ originalProperties: o || {}
93
+ }, n = parseInt(t.record_id, 10);
94
+ return g(e, i, { id: n });
95
+ }, A = (t) => d(t), a = (t) => l.every(t, l.isFinite), B = (t) => {
73
96
  let r = !1;
74
97
  if (t) {
75
- const [o, e] = t;
76
- r = o >= _ && o <= L && e >= I && e <= M;
98
+ const [e, o] = t;
99
+ r = e >= _ && e <= L && o >= C && o <= G;
77
100
  }
78
101
  return r;
79
- }, st = {
80
- addGeoreferenceLayer: v,
81
- getCertaintyCircles: b,
82
- getBoundingBox: x,
83
- removeLayer: A,
84
- toFeature: B,
85
- toFeatureCollection: G,
86
- validateBoundingBox: l,
87
- validateCoordinates: T
102
+ }, lt = {
103
+ addGeoreferenceLayer: M,
104
+ toCertaintyCircle: I,
105
+ getBoundingBox: b,
106
+ removeLayer: v,
107
+ toFeature: x,
108
+ toFeatureCollection: A,
109
+ validateBoundingBox: a,
110
+ validateCoordinates: B
88
111
  };
89
112
  export {
90
- st as default
113
+ lt as default
91
114
  };
92
115
  //# sourceMappingURL=index.es13.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.es13.js","sources":["../src/utils/Map.js"],"sourcesContent":["// @flow\n\nimport { WarpedMapLayer } from '@allmaps/maplibre';\nimport {\n bbox,\n bboxPolygon,\n buffer,\n feature,\n featureCollection\n} from '@turf/turf';\nimport _ from 'underscore';\nimport circle from '@turf/circle';\n\nconst MIN_LATITUDE = -90;\nconst MAX_LATITUDE = 90;\nconst MIN_LONGITUDE = -180;\nconst MAX_LONGITUDE = 180;\n\n/**\n * Returns a GeoJSON circle feature with the given center point and radius.\n * @param point - The center point of the circle.\n * @param radius - The radius of the circle in kilometers.\n * @returns {Feature<Geometry, Properties>} - The GeoJSON circle feature.\n */\nconst buildCircle = (point, radius) => (\n circle(point.coordinates, radius, { units: 'kilometers', steps: 32 })\n);\n\n/**\n * Returns a GeoJSON feature collection containing circles for each item in the given array.\n */\nconst getCertaintyCircles = (\n items,\n getCertaintyRadius: (item: any) => number | undefined\n) => {\n const features = [];\n\n for (const item of items) {\n if (getCertaintyRadius(item)) {\n if (item.geometry?.type === 'FeatureCollection') {\n for (const childFeature of item.geometry.features) {\n if (childFeature.geometry?.type === 'Point') {\n features.push(buildCircle(childFeature.geometry, getCertaintyRadius(item)));\n }\n }\n } else if (item.geometry.type === 'GeometryCollection') {\n for (const geometry of item.geometry.geometries) {\n if (geometry.type === 'Point') {\n features.push(buildCircle(geometry, getCertaintyRadius(item)));\n }\n }\n } else if (item.geometry?.type === 'Point') {\n features.push(buildCircle(item.geometry, getCertaintyRadius(item)));\n }\n }\n }\n\n return featureCollection(features);\n};\n\n/**\n * Adds the geo-referenced image layer to the passed map.\n *\n * @param map\n * @param layerId\n * @param options\n */\nconst addGeoreferenceLayer = (map, layerId, options = {}) => {\n const warpedMapLayer = new WarpedMapLayer(layerId);\n map.addLayer(warpedMapLayer);\n\n if (options.url) {\n warpedMapLayer.addGeoreferenceAnnotationByUrl(options.url);\n } else if (options.manifest) {\n warpedMapLayer.addGeoreferenceAnnotation(options.manifest);\n }\n\n if (options.opacity) {\n warpedMapLayer.setOpacity(options.opacity);\n }\n};\n\n/**\n * Returns a bounding box for the passed geometry (with optional buffer).\n *\n * @param data\n * @param bufferDistance\n *\n * @returns {BBox}\n */\nconst getBoundingBox = (data, bufferDistance = null) => {\n // Convert the GeoJSON into a bounding box\n const box = bbox(data);\n\n if (!validateBoundingBox(box)) {\n return null;\n }\n\n // Convert the bounding box to a polygon\n const polygon = bboxPolygon(box);\n\n // Create a buffer around the polygon (if a distance is provided)\n let polygonBuffer;\n\n if (bufferDistance) {\n polygonBuffer = buffer(polygon, bufferDistance, { units: 'miles' });\n } else {\n polygonBuffer = polygon;\n }\n\n // Convert the buffer to a bounding box\n return bbox(polygonBuffer);\n};\n\n/**\n * Removes a layer from the passed map.\n *\n * @param map\n * @param layerId\n *\n * @returns {*}\n */\nconst removeLayer = (map, layerId) => map && map.removeLayer(layerId);\n\n/**\n * Wraps the passed record in a feature.\n *\n * @param record\n * @param item\n * @param geometry\n * @param originalProperties\n *\n * @returns {Feature<Geometry, {\n * id: *,\n * ccode: [],\n * title: *,\n * uuid: *,\n * record_id: *,\n * name: *,\n * names: *,\n * type: *,\n * items: [*],\n * url: *\n * }>}\n */\nconst toFeature = (record: any, item: any, geometry: any, originalProperties?: any) => {\n const properties = {\n id: record.record_id,\n ccode: [],\n title: record.name,\n uuid: record.uuid,\n record_id: record.record_id,\n name: record.name,\n names: record.names?.map((toponym: string) => ({ toponym })),\n type: record.type,\n items: [item],\n url: record.url,\n originalProperties: originalProperties || {}\n };\n\n const id = parseInt(record.record_id, 10);\n return feature(geometry, properties, { id });\n};\n\n/**\n * Returns a feature collection for the passed set of features.\n *\n * @param features\n *\n * @returns {FeatureCollection<Geometry, GeoJsonProperties>}\n */\nconst toFeatureCollection = (features: Array<any>) => featureCollection(features);\n\n/**\n * Validates that the passed bounding box contains finite coordinates.\n *\n * @param boundingBox\n *\n * @returns {*}\n */\nconst validateBoundingBox = (boundingBox: Array<number>) => _.every(boundingBox, _.isFinite);\n\n/**\n * Returns true if the passed coordinates are valid.\n *\n * @param coordinates\n *\n * @returns {boolean}\n */\nconst validateCoordinates = (coordinates) => {\n let valid = false;\n\n if (coordinates) {\n const [latitude, longitude] = coordinates;\n\n valid = latitude >= MIN_LATITUDE\n && latitude <= MAX_LATITUDE\n && longitude >= MIN_LONGITUDE\n && longitude <= MAX_LONGITUDE;\n }\n\n return valid;\n};\n\nexport default {\n addGeoreferenceLayer,\n getCertaintyCircles,\n getBoundingBox,\n removeLayer,\n toFeature,\n toFeatureCollection,\n validateBoundingBox,\n validateCoordinates\n};\n"],"names":["MIN_LATITUDE","MAX_LATITUDE","MIN_LONGITUDE","MAX_LONGITUDE","buildCircle","point","radius","circle","getCertaintyCircles","items","getCertaintyRadius","features","item","childFeature","geometry","featureCollection","addGeoreferenceLayer","map","layerId","options","warpedMapLayer","WarpedMapLayer","getBoundingBox","data","bufferDistance","box","bbox","validateBoundingBox","polygon","bboxPolygon","polygonBuffer","buffer","removeLayer","toFeature","record","originalProperties","properties","toponym","id","feature","toFeatureCollection","boundingBox","_","validateCoordinates","coordinates","valid","latitude","longitude","MapUtils"],"mappings":"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"}
1
+ {"version":3,"file":"index.es13.js","sources":["../src/utils/Map.js"],"sourcesContent":["// @flow\n\nimport { WarpedMapLayer } from '@allmaps/maplibre';\nimport {\n bbox,\n bboxPolygon,\n buffer,\n feature,\n featureCollection\n} from '@turf/turf';\nimport _ from 'underscore';\nimport circle from '@turf/circle';\n\nconst MIN_LATITUDE = -90;\nconst MAX_LATITUDE = 90;\nconst MIN_LONGITUDE = -180;\nconst MAX_LONGITUDE = 180;\n\n/**\n * Returns a GeoJSON circle feature with the given center point and radius.\n * @param point - The center point of the circle.\n * @param radius - The radius of the circle in kilometers.\n * @returns {Feature<Geometry, Properties>} - The GeoJSON circle feature.\n */\nconst buildCircle = (point, radius) => (\n circle(point.coordinates, radius, { units: 'kilometers', steps: 32 })\n);\n\nconst toCertaintyCircle = (item, radius: number) => {\n if (item.geometry?.type === 'FeatureCollection') {\n let children = [];\n\n for (const childFeature of item.geometry.features) {\n if (childFeature.geometry?.type === 'Point') {\n const { geometry, type } = buildCircle(childFeature.geometry, radius);\n children.push({\n ...childFeature,\n geometry,\n type\n });\n }\n }\n\n return {\n ...item,\n geometry: {\n type: 'GeometryCollection',\n geometries: children\n }\n };\n } else if (item?.type === 'GeometryCollection') {\n return {\n ...item,\n geometries: item.geometries.map((geometry) => geometry.type === 'Point'\n ? buildCircle(geometry, radius)\n : geometry)\n };\n } else if (item.geometry?.type === 'Point') {\n const { geometry, type } = buildCircle(item.geometry, radius);\n return {\n ...item,\n geometry,\n type\n };\n }\n\n return item;\n};\n\n/**\n * Adds the geo-referenced image layer to the passed map.\n *\n * @param map\n * @param layerId\n * @param options\n */\nconst addGeoreferenceLayer = (map, layerId, options = {}) => {\n const warpedMapLayer = new WarpedMapLayer(layerId);\n map.addLayer(warpedMapLayer);\n\n if (options.url) {\n warpedMapLayer.addGeoreferenceAnnotationByUrl(options.url);\n } else if (options.manifest) {\n warpedMapLayer.addGeoreferenceAnnotation(options.manifest);\n }\n\n if (options.opacity) {\n warpedMapLayer.setOpacity(options.opacity);\n }\n};\n\n/**\n * Returns a bounding box for the passed geometry (with optional buffer).\n *\n * @param data\n * @param bufferDistance\n *\n * @returns {BBox}\n */\nconst getBoundingBox = (data, bufferDistance = null) => {\n // Convert the GeoJSON into a bounding box\n const box = bbox(data);\n\n if (!validateBoundingBox(box)) {\n return null;\n }\n\n // Convert the bounding box to a polygon\n const polygon = bboxPolygon(box);\n\n // Create a buffer around the polygon (if a distance is provided)\n let polygonBuffer;\n\n if (bufferDistance) {\n polygonBuffer = buffer(polygon, bufferDistance, { units: 'miles' });\n } else {\n polygonBuffer = polygon;\n }\n\n // Convert the buffer to a bounding box\n return bbox(polygonBuffer);\n};\n\n/**\n * Removes a layer from the passed map.\n *\n * @param map\n * @param layerId\n *\n * @returns {*}\n */\nconst removeLayer = (map, layerId) => map && map.removeLayer(layerId);\n\n/**\n * Wraps the passed record in a feature.\n *\n * @param record\n * @param item\n * @param geometry\n * @param originalProperties\n *\n * @returns {Feature<Geometry, {\n * id: *,\n * ccode: [],\n * title: *,\n * uuid: *,\n * record_id: *,\n * name: *,\n * names: *,\n * type: *,\n * items: [*],\n * url: *\n * }>}\n */\nconst toFeature = (record: any, item: any, geometry: any, originalProperties?: any) => {\n const properties = {\n id: record.record_id,\n ccode: [],\n title: record.name,\n uuid: record.uuid,\n record_id: record.record_id,\n name: record.name,\n names: record.names?.map((toponym: string) => ({ toponym })),\n type: record.type,\n items: [item],\n url: record.url,\n originalProperties: originalProperties || {}\n };\n\n const id = parseInt(record.record_id, 10);\n return feature(geometry, properties, { id });\n};\n\n/**\n * Returns a feature collection for the passed set of features.\n *\n * @param features\n *\n * @returns {FeatureCollection<Geometry, GeoJsonProperties>}\n */\nconst toFeatureCollection = (features: Array<any>) => featureCollection(features);\n\n/**\n * Validates that the passed bounding box contains finite coordinates.\n *\n * @param boundingBox\n *\n * @returns {*}\n */\nconst validateBoundingBox = (boundingBox: Array<number>) => _.every(boundingBox, _.isFinite);\n\n/**\n * Returns true if the passed coordinates are valid.\n *\n * @param coordinates\n *\n * @returns {boolean}\n */\nconst validateCoordinates = (coordinates) => {\n let valid = false;\n\n if (coordinates) {\n const [latitude, longitude] = coordinates;\n\n valid = latitude >= MIN_LATITUDE\n && latitude <= MAX_LATITUDE\n && longitude >= MIN_LONGITUDE\n && longitude <= MAX_LONGITUDE;\n }\n\n return valid;\n};\n\nexport default {\n addGeoreferenceLayer,\n toCertaintyCircle,\n getBoundingBox,\n removeLayer,\n toFeature,\n toFeatureCollection,\n validateBoundingBox,\n validateCoordinates\n};\n"],"names":["MIN_LATITUDE","MAX_LATITUDE","MIN_LONGITUDE","MAX_LONGITUDE","buildCircle","point","radius","circle","toCertaintyCircle","item","children","childFeature","geometry","type","addGeoreferenceLayer","map","layerId","options","warpedMapLayer","WarpedMapLayer","getBoundingBox","data","bufferDistance","box","bbox","validateBoundingBox","polygon","bboxPolygon","polygonBuffer","buffer","removeLayer","toFeature","record","originalProperties","properties","toponym","id","feature","toFeatureCollection","features","featureCollection","boundingBox","_","validateCoordinates","coordinates","valid","latitude","longitude","MapUtils"],"mappings":"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"}
@@ -1,4 +1,4 @@
1
- import t from "./index.es218.js";
1
+ import t from "./index.es226.js";
2
2
  function c(m, a, f) {
3
3
  var o = Array(Math.max(0, m));
4
4
  a = t(a, f, 1);
@@ -1,5 +1,5 @@
1
1
  import v from "./index.es38.js";
2
- import f from "./index.es215.js";
2
+ import f from "./index.es223.js";
3
3
  function d(r, n, e) {
4
4
  n = f(n);
5
5
  var i = n.length;
@@ -1,4 +1,4 @@
1
- import m from "./index.es206.js";
1
+ import m from "./index.es214.js";
2
2
  function o(c, t) {
3
3
  var a = function(i) {
4
4
  var e = a.cache, r = "" + (t ? t.apply(this, arguments) : i);
@@ -1,4 +1,4 @@
1
- import y from "./index.es217.js";
1
+ import y from "./index.es225.js";
2
2
  import k from "./index.es111.js";
3
3
  function a(f, n, e) {
4
4
  n = y(n, e);
@@ -1,4 +1,4 @@
1
- import e from "./index.es225.js";
1
+ import e from "./index.es233.js";
2
2
  const r = e(1);
3
3
  export {
4
4
  r as default
@@ -1,4 +1,4 @@
1
- import e from "./index.es225.js";
1
+ import e from "./index.es233.js";
2
2
  const d = e(-1);
3
3
  export {
4
4
  d as default
@@ -1,5 +1,5 @@
1
- import v from "./index.es217.js";
2
- import g from "./index.es208.js";
1
+ import v from "./index.es225.js";
2
+ import g from "./index.es216.js";
3
3
  function a(h, n, o, t) {
4
4
  o = v(o, t, 1);
5
5
  for (var u = o(n), r = 0, f = g(h); r < f; ) {
@@ -1,6 +1,6 @@
1
1
  import e from "./index.es150.js";
2
2
  import r from "./index.es148.js";
3
- import o from "./index.es226.js";
3
+ import o from "./index.es234.js";
4
4
  const f = o(1, r, e);
5
5
  export {
6
6
  f as default
@@ -1,5 +1,5 @@
1
1
  import e from "./index.es149.js";
2
- import t from "./index.es226.js";
2
+ import t from "./index.es234.js";
3
3
  const n = t(-1, e);
4
4
  export {
5
5
  n as default
@@ -1,4 +1,4 @@
1
- import d from "./index.es227.js";
1
+ import d from "./index.es235.js";
2
2
  import o from "./index.es148.js";
3
3
  import t from "./index.es147.js";
4
4
  function y(r, e, f) {
@@ -1,5 +1,5 @@
1
- import p from "./index.es218.js";
2
- import t from "./index.es227.js";
1
+ import p from "./index.es226.js";
2
+ import t from "./index.es235.js";
3
3
  import h from "./index.es111.js";
4
4
  function u(f, i, l) {
5
5
  i = p(i, l);
@@ -1,5 +1,5 @@
1
- import l from "./index.es217.js";
2
- import k from "./index.es227.js";
1
+ import l from "./index.es225.js";
2
+ import k from "./index.es235.js";
3
3
  import u from "./index.es111.js";
4
4
  function h(r, a, t) {
5
5
  a = l(a, t);
@@ -1,4 +1,4 @@
1
- import e from "./index.es228.js";
1
+ import e from "./index.es236.js";
2
2
  const t = e(1);
3
3
  export {
4
4
  t as default
@@ -1,4 +1,4 @@
1
- import e from "./index.es228.js";
1
+ import e from "./index.es236.js";
2
2
  const r = e(-1);
3
3
  export {
4
4
  r as default
@@ -1,4 +1,4 @@
1
- import m from "./index.es217.js";
1
+ import m from "./index.es225.js";
2
2
  import s from "./index.es155.js";
3
3
  function l(t, r, n) {
4
4
  var f = [];
@@ -1,10 +1,10 @@
1
1
  import * as i from "react";
2
2
  import { useContext as b, useState as E, useRef as s, useEffect as v, useImperativeHandle as L, useMemo as x } from "react";
3
3
  import { MountedMapsContext as y } from "./index.es28.js";
4
- import u from "./index.es232.js";
5
- import I from "./index.es233.js";
6
- import w from "./index.es234.js";
7
- import C from "./index.es235.js";
4
+ import u from "./index.es205.js";
5
+ import I from "./index.es206.js";
6
+ import w from "./index.es207.js";
7
+ import C from "./index.es208.js";
8
8
  const g = i.createContext(null);
9
9
  function R(e, f) {
10
10
  const c = b(y), [o, M] = E(null), l = s(), { current: a } = s({ mapLib: null, map: null });
@@ -1,6 +1,6 @@
1
1
  import o from "./index.es159.js";
2
2
  import f from "./index.es143.js";
3
- import m from "./index.es217.js";
3
+ import m from "./index.es225.js";
4
4
  function a(r, t, e) {
5
5
  return o(r, f(m(t)), e);
6
6
  }
@@ -1,5 +1,5 @@
1
- import e from "./index.es217.js";
2
- import l from "./index.es227.js";
1
+ import e from "./index.es225.js";
2
+ import l from "./index.es235.js";
3
3
  import u from "./index.es111.js";
4
4
  function g(r, t, o) {
5
5
  t = e(t, o);
@@ -1,5 +1,5 @@
1
- import l from "./index.es217.js";
2
- import u from "./index.es227.js";
1
+ import l from "./index.es225.js";
2
+ import u from "./index.es235.js";
3
3
  import e from "./index.es111.js";
4
4
  function h(r, t, s) {
5
5
  t = l(t, s);
@@ -1,4 +1,4 @@
1
- import e from "./index.es227.js";
1
+ import e from "./index.es235.js";
2
2
  import a from "./index.es113.js";
3
3
  import m from "./index.es151.js";
4
4
  function u(i, t, r, f) {
@@ -1,6 +1,6 @@
1
- import c from "./index.es227.js";
1
+ import c from "./index.es235.js";
2
2
  import s from "./index.es113.js";
3
- import e from "./index.es217.js";
3
+ import e from "./index.es225.js";
4
4
  import I from "./index.es155.js";
5
5
  function g(n, f, o) {
6
6
  var r = -1 / 0, u = -1 / 0, i, l;
@@ -1,6 +1,6 @@
1
- import s from "./index.es227.js";
1
+ import s from "./index.es235.js";
2
2
  import a from "./index.es113.js";
3
- import e from "./index.es217.js";
3
+ import e from "./index.es225.js";
4
4
  import I from "./index.es155.js";
5
5
  function k(n, f, o) {
6
6
  var i = 1 / 0, u = 1 / 0, r, l;
@@ -1,6 +1,6 @@
1
- import s from "./index.es227.js";
1
+ import s from "./index.es235.js";
2
2
  import v from "./index.es113.js";
3
- import u from "./index.es208.js";
3
+ import u from "./index.es216.js";
4
4
  import o from "./index.es133.js";
5
5
  import h from "./index.es175.js";
6
6
  function M(r, a, e) {