jupytergis-core 0.1.3__py3-none-any.whl → 0.1.5__py3-none-any.whl

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 (103) hide show
  1. jupytergis_core/_version.py +1 -1
  2. jupytergis_core/jgis_ydoc.py +1 -10
  3. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/package.json +4 -4
  4. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/00c411a1ee170202a2e9.png +0 -0
  5. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/0141a2f191aec848c2fc.png +0 -0
  6. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/0658ea829d1a5bb04782.png +0 -0
  7. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/0cc01c5e06e85f07278d.png +0 -0
  8. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/0da4fb6356fc019b42db.png +0 -0
  9. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/155.ab2d4685af67486e0658.js +1 -0
  10. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/2a84257afdcbef844b92.png +0 -0
  11. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/2c73fcafe95e709689ec.png +0 -0
  12. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/2cfc6c2c5119745ef7fd.png +0 -0
  13. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/44bdc73392ad23fcdf8c.png +0 -0
  14. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/557.0b58e3e2f305c1511239.js +1 -0
  15. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/57.44a013e9affe2ac3d6f8.js +8 -0
  16. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/63a2e6b796d3371f0dbe.png +0 -0
  17. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/69de9b388f10a59617ab.png +0 -0
  18. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/6d3f756096544a4eb94c.png +0 -0
  19. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/887786e1adaea7e7f538.png +0 -0
  20. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/991.bb0392c1b52af940e3a4.js +1 -0
  21. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/ad72ae933fb2e1bdaa5a.png +0 -0
  22. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/d14d26bf47e46c9bad29.png +0 -0
  23. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/d60bd335ae109e02c303.png +0 -0
  24. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/d8a3298da7a65d7b5e71.png +0 -0
  25. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/dd972f8b6d596f779629.png +0 -0
  26. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/deaabc4d2e62eaa7260e.png +0 -0
  27. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/ed84732e3f459c60501b.png +0 -0
  28. jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/remoteEntry.3efacd5a07b08d672cb0.js +1 -0
  29. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/third-party-licenses.json +4 -4
  30. {jupytergis_core-0.1.3.dist-info → jupytergis_core-0.1.5.dist-info}/METADATA +1 -1
  31. jupytergis_core-0.1.5.dist-info/RECORD +79 -0
  32. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/05cd6f9ef7cee99b045d.png +0 -0
  33. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/25add056a64c313112c1.png +0 -0
  34. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/2fd48688b8db6630a98b.png +0 -0
  35. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/342e1e3d19b03b1fe609.png +0 -0
  36. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/378afa99d57ed2ae3412.png +0 -0
  37. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/49aaa70fdbd358566081.png +0 -0
  38. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/557.fe291f5575a15c36d24c.js +0 -1
  39. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/57.5de96a80fc76b40d5c98.js +0 -8
  40. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/65a5e66f99e9379dfc35.png +0 -0
  41. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/6d8404aa058fc40542b5.png +0 -0
  42. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/81ffc09a91df6d865b2a.png +0 -0
  43. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/880b33982acf113f7814.png +0 -0
  44. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/91d7eac484745f2cc5be.png +0 -0
  45. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/936.169e398d63d619903349.js +0 -1
  46. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/987b25b09e2ab3aa14c7.png +0 -0
  47. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/991.31397828c39e542d58cd.js +0 -1
  48. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/9ed013096549f2bf7c22.png +0 -0
  49. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/a3d0ada3998dc5eedfd3.png +0 -0
  50. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/b55cd9c1ba258194a75b.png +0 -0
  51. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/c5f242778732b5dc2895.png +0 -0
  52. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/c6533f8919fbd9204588.png +0 -0
  53. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/e48a0a08bd9700f029ef.png +0 -0
  54. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/edf2f8b4d83dca6ed541.png +0 -0
  55. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/f96120c463d07664c2e3.png +0 -0
  56. jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/remoteEntry.2c0a4f1ad6ed25d278ab.js +0 -1
  57. jupytergis_core-0.1.3.dist-info/RECORD +0 -79
  58. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/etc/jupyter/jupyter_server_config.d/jupytergis_core.json +0 -0
  59. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/034e72037478aea1bd04.png +0 -0
  60. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/062a9554f6b4caac9713.png +0 -0
  61. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/064f37cecb8130ad66e8.png +0 -0
  62. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/08da2741746ddab81d04.png +0 -0
  63. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/154.0d16fbe1d1182d138b2c.js +0 -0
  64. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/197.34d9096e78e2f4b7138c.js +0 -0
  65. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/1d440270da19a2f22fee.png +0 -0
  66. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/1f152a2e838d5bc9734a.png +0 -0
  67. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/226.280aa14a2e4c0654c374.js +0 -0
  68. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/27.aea9e291ba3dd16790fb.js +0 -0
  69. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/27.aea9e291ba3dd16790fb.js.LICENSE.txt +0 -0
  70. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/2b3d42a470b5ce14859a.png +0 -0
  71. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/32c7a73662cceb5bb1d7.png +0 -0
  72. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/350eec4ce9ae4bc10bca.wasm +0 -0
  73. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/36.b2f6adaa2d1def5c163f.js +0 -0
  74. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/363ca7c5f78deb6fd033.png +0 -0
  75. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/366.33cb40029b4f4da3d3ad.js +0 -0
  76. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/3d48be10ffea86eb15de.png +0 -0
  77. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/407.fa2f7a0dc4d3371a5e2c.js +0 -0
  78. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/432.19e693d578a221132366.js +0 -0
  79. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/460.a2074380632031c05e8d.js +0 -0
  80. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/472.08add5249d72d563ba32.js +0 -0
  81. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/4ed4ae4121d38d85100b.png +0 -0
  82. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/509.0d58394cd3a34bdbd0b9.js +0 -0
  83. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/542.3038c6cef679f15b8d9a.js +0 -0
  84. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/552.9f37fbb73d9f60b6c3f3.js +0 -0
  85. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/555.7d0c1d2ee9e49a619cb9.js +0 -0
  86. /jupytergis_core-0.1.3.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/57.5de96a80fc76b40d5c98.js.LICENSE.txt → /jupytergis_core-0.1.5.data/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/57.44a013e9affe2ac3d6f8.js.LICENSE.txt +0 -0
  87. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/618.86523276f857e0a3362e.js +0 -0
  88. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/733.9bce9fdd113869d413d0.js +0 -0
  89. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/777.b41e81dd6b0af001baab.js +0 -0
  90. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/777.b41e81dd6b0af001baab.js.LICENSE.txt +0 -0
  91. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/803.959deb5eafbb3ab489c6.js +0 -0
  92. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/9d23b9ebf800c009f835.png +0 -0
  93. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/aa0d1282df07ef3c385f.png +0 -0
  94. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/ae2589dc6f6090080a25.png +0 -0
  95. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/bf9c5537f242b3244cfd.png +0 -0
  96. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/d0917c2edc1eee1562a2.png +0 -0
  97. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/d7eb57ad53f788b1fa92.png +0 -0
  98. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/d83457b1b925c1718f6d.png +0 -0
  99. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/e473e1e9f20af114bbb4.data +0 -0
  100. {jupytergis_core-0.1.3.data → jupytergis_core-0.1.5.data}/data/share/jupyter/labextensions/@jupytergis/jupytergis-core/static/style.js +0 -0
  101. {jupytergis_core-0.1.3.dist-info → jupytergis_core-0.1.5.dist-info}/WHEEL +0 -0
  102. {jupytergis_core-0.1.3.dist-info → jupytergis_core-0.1.5.dist-info}/entry_points.txt +0 -0
  103. {jupytergis_core-0.1.3.dist-info → jupytergis_core-0.1.5.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,8 @@
1
+ /*! For license information please see 57.44a013e9affe2ac3d6f8.js.LICENSE.txt */
2
+ (self.webpackChunk_jupytergis_jupytergis_core=self.webpackChunk_jupytergis_jupytergis_core||[]).push([[57],{72858:(t,e,r)=>{"use strict";r.d(e,{q:()=>at});var n=r(93345),i=r.n(n);const s=function(t,e=console.error){let r,n;return class extends i().Component{constructor(){super(...arguments),this.displayName="AsyncComponent",this.state={__async_component:null}}componentDidMount(){null==r?(null==n&&(n=t().then((t=>r=t))),n.then((()=>this.componentWasCached())).catch(e)):this.componentWasCached()}componentWasCached(){this.setState({__async_component:r})}render(){const t=this.state.__async_component;return null==t?i().createElement("div",{className:"jp-Spinner"},i().createElement("div",{className:"jp-SpinnerContent"})):i().createElement(t,Object.assign({},this.props),this.props.children)}}}((async()=>{const{withTheme:t}=await Promise.resolve().then(r.bind(r,72192));return t((await r.e(366).then(r.bind(r,38366))).default)}));var o=r(12200),a=r(44993),l=r(81473),c=r(2678),u=r(64053),h=r(29452),d=r.n(h);let f={async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,hooks:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1};const p=/[&<>"']/,m=new RegExp(p.source,"g"),g=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,y=new RegExp(g.source,"g"),v={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},_=t=>v[t];function b(t,e){if(e){if(p.test(t))return t.replace(m,_)}else if(g.test(t))return t.replace(y,_);return t}const w=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi;function x(t){return t.replace(w,((t,e)=>"colon"===(e=e.toLowerCase())?":":"#"===e.charAt(0)?"x"===e.charAt(1)?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""))}const E=/(^|[^\[])\^/g;function S(t,e){t="string"==typeof t?t:t.source,e=e||"";const r={replace:(e,n)=>(n=(n=n.source||n).replace(E,"$1"),t=t.replace(e,n),r),getRegex:()=>new RegExp(t,e)};return r}const A=/[^\w:]/g,P=/^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;function T(t,e,r){if(t){let t;try{t=decodeURIComponent(x(r)).replace(A,"").toLowerCase()}catch(t){return null}if(0===t.indexOf("javascript:")||0===t.indexOf("vbscript:")||0===t.indexOf("data:"))return null}e&&!P.test(r)&&(r=function(t,e){C[" "+t]||(M.test(t)?C[" "+t]=t+"/":C[" "+t]=k(t,"/",!0));const r=-1===(t=C[" "+t]).indexOf(":");return"//"===e.substring(0,2)?r?e:t.replace(O,"$1")+e:"/"===e.charAt(0)?r?e:t.replace(R,"$1")+e:t+e}(e,r));try{r=encodeURI(r).replace(/%25/g,"%")}catch(t){return null}return r}const C={},M=/^[^:]+:\/*[^/]*$/,O=/^([^:]+:)[\s\S]*$/,R=/^([^:]+:\/*[^/]*)[\s\S]*$/,D={exec:function(){}};function I(t,e){const r=t.replace(/\|/g,((t,e,r)=>{let n=!1,i=e;for(;--i>=0&&"\\"===r[i];)n=!n;return n?"|":" |"})).split(/ \|/);let n=0;if(r[0].trim()||r.shift(),r.length>0&&!r[r.length-1].trim()&&r.pop(),r.length>e)r.splice(e);else for(;r.length<e;)r.push("");for(;n<r.length;n++)r[n]=r[n].trim().replace(/\\\|/g,"|");return r}function k(t,e,r){const n=t.length;if(0===n)return"";let i=0;for(;i<n;){const s=t.charAt(n-i-1);if(s!==e||r){if(s===e||!r)break;i++}else i++}return t.slice(0,n-i)}function L(t,e){if(e<1)return"";let r="";for(;e>1;)1&e&&(r+=t),e>>=1,t+=t;return r+t}function F(t,e,r,n){const i=e.href,s=e.title?b(e.title):null,o=t[1].replace(/\\([\[\]])/g,"$1");if("!"!==t[0].charAt(0)){n.state.inLink=!0;const t={type:"link",raw:r,href:i,title:s,text:o,tokens:n.inlineTokens(o)};return n.state.inLink=!1,t}return{type:"image",raw:r,href:i,title:s,text:b(o)}}class j{constructor(t){this.options=t||f}space(t){const e=this.rules.block.newline.exec(t);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(t){const e=this.rules.block.code.exec(t);if(e){const t=e[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?t:k(t,"\n")}}}fences(t){const e=this.rules.block.fences.exec(t);if(e){const t=e[0],r=function(t,e){const r=t.match(/^(\s+)(?:```)/);if(null===r)return e;const n=r[1];return e.split("\n").map((t=>{const e=t.match(/^\s+/);if(null===e)return t;const[r]=e;return r.length>=n.length?t.slice(n.length):t})).join("\n")}(t,e[3]||"");return{type:"code",raw:t,lang:e[2]?e[2].trim().replace(this.rules.inline._escapes,"$1"):e[2],text:r}}}heading(t){const e=this.rules.block.heading.exec(t);if(e){let t=e[2].trim();if(/#$/.test(t)){const e=k(t,"#");this.options.pedantic?t=e.trim():e&&!/ $/.test(e)||(t=e.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:t,tokens:this.lexer.inline(t)}}}hr(t){const e=this.rules.block.hr.exec(t);if(e)return{type:"hr",raw:e[0]}}blockquote(t){const e=this.rules.block.blockquote.exec(t);if(e){const t=e[0].replace(/^ *>[ \t]?/gm,""),r=this.lexer.state.top;this.lexer.state.top=!0;const n=this.lexer.blockTokens(t);return this.lexer.state.top=r,{type:"blockquote",raw:e[0],tokens:n,text:t}}}list(t){let e=this.rules.block.list.exec(t);if(e){let r,n,i,s,o,a,l,c,u,h,d,f,p=e[1].trim();const m=p.length>1,g={type:"list",raw:"",ordered:m,start:m?+p.slice(0,-1):"",loose:!1,items:[]};p=m?`\\d{1,9}\\${p.slice(-1)}`:`\\${p}`,this.options.pedantic&&(p=m?p:"[*+-]");const y=new RegExp(`^( {0,3}${p})((?:[\t ][^\\n]*)?(?:\\n|$))`);for(;t&&(f=!1,e=y.exec(t))&&!this.rules.block.hr.test(t);){if(r=e[0],t=t.substring(r.length),c=e[2].split("\n",1)[0].replace(/^\t+/,(t=>" ".repeat(3*t.length))),u=t.split("\n",1)[0],this.options.pedantic?(s=2,d=c.trimLeft()):(s=e[2].search(/[^ ]/),s=s>4?1:s,d=c.slice(s),s+=e[1].length),a=!1,!c&&/^ *$/.test(u)&&(r+=u+"\n",t=t.substring(u.length+1),f=!0),!f){const e=new RegExp(`^ {0,${Math.min(3,s-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ \t][^\\n]*)?(?:\\n|$))`),n=new RegExp(`^ {0,${Math.min(3,s-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),i=new RegExp(`^ {0,${Math.min(3,s-1)}}(?:\`\`\`|~~~)`),o=new RegExp(`^ {0,${Math.min(3,s-1)}}#`);for(;t&&(h=t.split("\n",1)[0],u=h,this.options.pedantic&&(u=u.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),!i.test(u))&&!o.test(u)&&!e.test(u)&&!n.test(t);){if(u.search(/[^ ]/)>=s||!u.trim())d+="\n"+u.slice(s);else{if(a)break;if(c.search(/[^ ]/)>=4)break;if(i.test(c))break;if(o.test(c))break;if(n.test(c))break;d+="\n"+u}a||u.trim()||(a=!0),r+=h+"\n",t=t.substring(h.length+1),c=u.slice(s)}}g.loose||(l?g.loose=!0:/\n *\n *$/.test(r)&&(l=!0)),this.options.gfm&&(n=/^\[[ xX]\] /.exec(d),n&&(i="[ ] "!==n[0],d=d.replace(/^\[[ xX]\] +/,""))),g.items.push({type:"list_item",raw:r,task:!!n,checked:i,loose:!1,text:d}),g.raw+=r}g.items[g.items.length-1].raw=r.trimRight(),g.items[g.items.length-1].text=d.trimRight(),g.raw=g.raw.trimRight();const v=g.items.length;for(o=0;o<v;o++)if(this.lexer.state.top=!1,g.items[o].tokens=this.lexer.blockTokens(g.items[o].text,[]),!g.loose){const t=g.items[o].tokens.filter((t=>"space"===t.type)),e=t.length>0&&t.some((t=>/\n.*\n/.test(t.raw)));g.loose=e}if(g.loose)for(o=0;o<v;o++)g.items[o].loose=!0;return g}}html(t){const e=this.rules.block.html.exec(t);if(e){const t={type:"html",raw:e[0],pre:!this.options.sanitizer&&("pre"===e[1]||"script"===e[1]||"style"===e[1]),text:e[0]};if(this.options.sanitize){const r=this.options.sanitizer?this.options.sanitizer(e[0]):b(e[0]);t.type="paragraph",t.text=r,t.tokens=this.lexer.inline(r)}return t}}def(t){const e=this.rules.block.def.exec(t);if(e){const t=e[1].toLowerCase().replace(/\s+/g," "),r=e[2]?e[2].replace(/^<(.*)>$/,"$1").replace(this.rules.inline._escapes,"$1"):"",n=e[3]?e[3].substring(1,e[3].length-1).replace(this.rules.inline._escapes,"$1"):e[3];return{type:"def",tag:t,raw:e[0],href:r,title:n}}}table(t){const e=this.rules.block.table.exec(t);if(e){const t={type:"table",header:I(e[1]).map((t=>({text:t}))),align:e[2].replace(/^ *|\| *$/g,"").split(/ *\| */),rows:e[3]&&e[3].trim()?e[3].replace(/\n[ \t]*$/,"").split("\n"):[]};if(t.header.length===t.align.length){t.raw=e[0];let r,n,i,s,o=t.align.length;for(r=0;r<o;r++)/^ *-+: *$/.test(t.align[r])?t.align[r]="right":/^ *:-+: *$/.test(t.align[r])?t.align[r]="center":/^ *:-+ *$/.test(t.align[r])?t.align[r]="left":t.align[r]=null;for(o=t.rows.length,r=0;r<o;r++)t.rows[r]=I(t.rows[r],t.header.length).map((t=>({text:t})));for(o=t.header.length,n=0;n<o;n++)t.header[n].tokens=this.lexer.inline(t.header[n].text);for(o=t.rows.length,n=0;n<o;n++)for(s=t.rows[n],i=0;i<s.length;i++)s[i].tokens=this.lexer.inline(s[i].text);return t}}}lheading(t){const e=this.rules.block.lheading.exec(t);if(e)return{type:"heading",raw:e[0],depth:"="===e[2].charAt(0)?1:2,text:e[1],tokens:this.lexer.inline(e[1])}}paragraph(t){const e=this.rules.block.paragraph.exec(t);if(e){const t="\n"===e[1].charAt(e[1].length-1)?e[1].slice(0,-1):e[1];return{type:"paragraph",raw:e[0],text:t,tokens:this.lexer.inline(t)}}}text(t){const e=this.rules.block.text.exec(t);if(e)return{type:"text",raw:e[0],text:e[0],tokens:this.lexer.inline(e[0])}}escape(t){const e=this.rules.inline.escape.exec(t);if(e)return{type:"escape",raw:e[0],text:b(e[1])}}tag(t){const e=this.rules.inline.tag.exec(t);if(e)return!this.lexer.state.inLink&&/^<a /i.test(e[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&/^<\/a>/i.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:this.options.sanitize?"text":"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,text:this.options.sanitize?this.options.sanitizer?this.options.sanitizer(e[0]):b(e[0]):e[0]}}link(t){const e=this.rules.inline.link.exec(t);if(e){const t=e[2].trim();if(!this.options.pedantic&&/^</.test(t)){if(!/>$/.test(t))return;const e=k(t.slice(0,-1),"\\");if((t.length-e.length)%2==0)return}else{const t=function(t,e){if(-1===t.indexOf(e[1]))return-1;const r=t.length;let n=0,i=0;for(;i<r;i++)if("\\"===t[i])i++;else if(t[i]===e[0])n++;else if(t[i]===e[1]&&(n--,n<0))return i;return-1}(e[2],"()");if(t>-1){const r=(0===e[0].indexOf("!")?5:4)+e[1].length+t;e[2]=e[2].substring(0,t),e[0]=e[0].substring(0,r).trim(),e[3]=""}}let r=e[2],n="";if(this.options.pedantic){const t=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(r);t&&(r=t[1],n=t[3])}else n=e[3]?e[3].slice(1,-1):"";return r=r.trim(),/^</.test(r)&&(r=this.options.pedantic&&!/>$/.test(t)?r.slice(1):r.slice(1,-1)),F(e,{href:r?r.replace(this.rules.inline._escapes,"$1"):r,title:n?n.replace(this.rules.inline._escapes,"$1"):n},e[0],this.lexer)}}reflink(t,e){let r;if((r=this.rules.inline.reflink.exec(t))||(r=this.rules.inline.nolink.exec(t))){let t=(r[2]||r[1]).replace(/\s+/g," ");if(t=e[t.toLowerCase()],!t){const t=r[0].charAt(0);return{type:"text",raw:t,text:t}}return F(r,t,r[0],this.lexer)}}emStrong(t,e,r=""){let n=this.rules.inline.emStrong.lDelim.exec(t);if(!n)return;if(n[3]&&r.match(/[\p{L}\p{N}]/u))return;const i=n[1]||n[2]||"";if(!i||i&&(""===r||this.rules.inline.punctuation.exec(r))){const r=n[0].length-1;let i,s,o=r,a=0;const l="*"===n[0][0]?this.rules.inline.emStrong.rDelimAst:this.rules.inline.emStrong.rDelimUnd;for(l.lastIndex=0,e=e.slice(-1*t.length+r);null!=(n=l.exec(e));){if(i=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!i)continue;if(s=i.length,n[3]||n[4]){o+=s;continue}if((n[5]||n[6])&&r%3&&!((r+s)%3)){a+=s;continue}if(o-=s,o>0)continue;s=Math.min(s,s+o+a);const e=t.slice(0,r+n.index+(n[0].length-i.length)+s);if(Math.min(r,s)%2){const t=e.slice(1,-1);return{type:"em",raw:e,text:t,tokens:this.lexer.inlineTokens(t)}}const l=e.slice(2,-2);return{type:"strong",raw:e,text:l,tokens:this.lexer.inlineTokens(l)}}}}codespan(t){const e=this.rules.inline.code.exec(t);if(e){let t=e[2].replace(/\n/g," ");const r=/[^ ]/.test(t),n=/^ /.test(t)&&/ $/.test(t);return r&&n&&(t=t.substring(1,t.length-1)),t=b(t,!0),{type:"codespan",raw:e[0],text:t}}}br(t){const e=this.rules.inline.br.exec(t);if(e)return{type:"br",raw:e[0]}}del(t){const e=this.rules.inline.del.exec(t);if(e)return{type:"del",raw:e[0],text:e[2],tokens:this.lexer.inlineTokens(e[2])}}autolink(t,e){const r=this.rules.inline.autolink.exec(t);if(r){let t,n;return"@"===r[2]?(t=b(this.options.mangle?e(r[1]):r[1]),n="mailto:"+t):(t=b(r[1]),n=t),{type:"link",raw:r[0],text:t,href:n,tokens:[{type:"text",raw:t,text:t}]}}}url(t,e){let r;if(r=this.rules.inline.url.exec(t)){let t,n;if("@"===r[2])t=b(this.options.mangle?e(r[0]):r[0]),n="mailto:"+t;else{let e;do{e=r[0],r[0]=this.rules.inline._backpedal.exec(r[0])[0]}while(e!==r[0]);t=b(r[0]),n="www."===r[1]?"http://"+r[0]:r[0]}return{type:"link",raw:r[0],text:t,href:n,tokens:[{type:"text",raw:t,text:t}]}}}inlineText(t,e){const r=this.rules.inline.text.exec(t);if(r){let t;return t=this.lexer.state.inRawBlock?this.options.sanitize?this.options.sanitizer?this.options.sanitizer(r[0]):b(r[0]):r[0]:b(this.options.smartypants?e(r[0]):r[0]),{type:"text",raw:r[0],text:t}}}}const N={newline:/^(?: *(?:\n|$))+/,code:/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,hr:/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,blockquote:/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,list:/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,html:"^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",def:/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,table:D,lheading:/^((?:.|\n(?!\n))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,_paragraph:/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,text:/^[^\n]+/,_label:/(?!\s*\])(?:\\.|[^\[\]\\])+/,_title:/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/};N.def=S(N.def).replace("label",N._label).replace("title",N._title).getRegex(),N.bullet=/(?:[*+-]|\d{1,9}[.)])/,N.listItemStart=S(/^( *)(bull) */).replace("bull",N.bullet).getRegex(),N.list=S(N.list).replace(/bull/g,N.bullet).replace("hr","\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def","\\n+(?="+N.def.source+")").getRegex(),N._tag="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",N._comment=/<!--(?!-?>)[\s\S]*?(?:-->|$)/,N.html=S(N.html,"i").replace("comment",N._comment).replace("tag",N._tag).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),N.paragraph=S(N._paragraph).replace("hr",N.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",N._tag).getRegex(),N.blockquote=S(N.blockquote).replace("paragraph",N.paragraph).getRegex(),N.normal={...N},N.gfm={...N.normal,table:"^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"},N.gfm.table=S(N.gfm.table).replace("hr",N.hr).replace("heading"," {0,3}#{1,6} ").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",N._tag).getRegex(),N.gfm.paragraph=S(N._paragraph).replace("hr",N.hr).replace("heading"," {0,3}#{1,6} ").replace("|lheading","").replace("table",N.gfm.table).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",N._tag).getRegex(),N.pedantic={...N.normal,html:S("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",N._comment).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:D,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:S(N.normal._paragraph).replace("hr",N.hr).replace("heading"," *#{1,6} *[^\n]").replace("lheading",N.lheading).replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").getRegex()};const G={escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,autolink:/^<(scheme:[^\s\x00-\x1f<>]*|email)>/,url:D,tag:"^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",link:/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,reflink:/^!?\[(label)\]\[(ref)\]/,nolink:/^!?\[(ref)\](?:\[\])?/,reflinkSearch:"reflink|nolink(?!\\()",emStrong:{lDelim:/^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,rDelimAst:/^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,rDelimUnd:/^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/},code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,br:/^( {2,}|\\)\n(?!\s*$)/,del:D,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,punctuation:/^([\spunctuation])/};function $(t){return t.replace(/---/g,"—").replace(/--/g,"–").replace(/(^|[-\u2014/(\[{"\s])'/g,"$1‘").replace(/'/g,"’").replace(/(^|[-\u2014/(\[{\u2018\s])"/g,"$1“").replace(/"/g,"”").replace(/\.{3}/g,"…")}function z(t){let e,r,n="";const i=t.length;for(e=0;e<i;e++)r=t.charCodeAt(e),Math.random()>.5&&(r="x"+r.toString(16)),n+="&#"+r+";";return n}G._punctuation="!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~",G.punctuation=S(G.punctuation).replace(/punctuation/g,G._punctuation).getRegex(),G.blockSkip=/\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g,G.escapedEmSt=/(?:^|[^\\])(?:\\\\)*\\[*_]/g,G._comment=S(N._comment).replace("(?:--\x3e|$)","--\x3e").getRegex(),G.emStrong.lDelim=S(G.emStrong.lDelim).replace(/punct/g,G._punctuation).getRegex(),G.emStrong.rDelimAst=S(G.emStrong.rDelimAst,"g").replace(/punct/g,G._punctuation).getRegex(),G.emStrong.rDelimUnd=S(G.emStrong.rDelimUnd,"g").replace(/punct/g,G._punctuation).getRegex(),G._escapes=/\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g,G._scheme=/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/,G._email=/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/,G.autolink=S(G.autolink).replace("scheme",G._scheme).replace("email",G._email).getRegex(),G._attribute=/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/,G.tag=S(G.tag).replace("comment",G._comment).replace("attribute",G._attribute).getRegex(),G._label=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,G._href=/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/,G._title=/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/,G.link=S(G.link).replace("label",G._label).replace("href",G._href).replace("title",G._title).getRegex(),G.reflink=S(G.reflink).replace("label",G._label).replace("ref",N._label).getRegex(),G.nolink=S(G.nolink).replace("ref",N._label).getRegex(),G.reflinkSearch=S(G.reflinkSearch,"g").replace("reflink",G.reflink).replace("nolink",G.nolink).getRegex(),G.normal={...G},G.pedantic={...G.normal,strong:{start:/^__|\*\*/,middle:/^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,endAst:/\*\*(?!\*)/g,endUnd:/__(?!_)/g},em:{start:/^_|\*/,middle:/^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,endAst:/\*(?!\*)/g,endUnd:/_(?!_)/g},link:S(/^!?\[(label)\]\((.*?)\)/).replace("label",G._label).getRegex(),reflink:S(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",G._label).getRegex()},G.gfm={...G.normal,escape:S(G.escape).replace("])","~|])").getRegex(),_extended_email:/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,url:/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/},G.gfm.url=S(G.gfm.url,"i").replace("email",G.gfm._extended_email).getRegex(),G.breaks={...G.gfm,br:S(G.br).replace("{2,}","*").getRegex(),text:S(G.gfm.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()};class U{constructor(t){this.tokens=[],this.tokens.links=Object.create(null),this.options=t||f,this.options.tokenizer=this.options.tokenizer||new j,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const e={block:N.normal,inline:G.normal};this.options.pedantic?(e.block=N.pedantic,e.inline=G.pedantic):this.options.gfm&&(e.block=N.gfm,this.options.breaks?e.inline=G.breaks:e.inline=G.gfm),this.tokenizer.rules=e}static get rules(){return{block:N,inline:G}}static lex(t,e){return new U(e).lex(t)}static lexInline(t,e){return new U(e).inlineTokens(t)}lex(t){let e;for(t=t.replace(/\r\n|\r/g,"\n"),this.blockTokens(t,this.tokens);e=this.inlineQueue.shift();)this.inlineTokens(e.src,e.tokens);return this.tokens}blockTokens(t,e=[]){let r,n,i,s;for(t=this.options.pedantic?t.replace(/\t/g," ").replace(/^ +$/gm,""):t.replace(/^( *)(\t+)/gm,((t,e,r)=>e+" ".repeat(r.length)));t;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some((n=>!!(r=n.call({lexer:this},t,e))&&(t=t.substring(r.raw.length),e.push(r),!0)))))if(r=this.tokenizer.space(t))t=t.substring(r.raw.length),1===r.raw.length&&e.length>0?e[e.length-1].raw+="\n":e.push(r);else if(r=this.tokenizer.code(t))t=t.substring(r.raw.length),n=e[e.length-1],!n||"paragraph"!==n.type&&"text"!==n.type?e.push(r):(n.raw+="\n"+r.raw,n.text+="\n"+r.text,this.inlineQueue[this.inlineQueue.length-1].src=n.text);else if(r=this.tokenizer.fences(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.heading(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.hr(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.blockquote(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.list(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.html(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.def(t))t=t.substring(r.raw.length),n=e[e.length-1],!n||"paragraph"!==n.type&&"text"!==n.type?this.tokens.links[r.tag]||(this.tokens.links[r.tag]={href:r.href,title:r.title}):(n.raw+="\n"+r.raw,n.text+="\n"+r.raw,this.inlineQueue[this.inlineQueue.length-1].src=n.text);else if(r=this.tokenizer.table(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.lheading(t))t=t.substring(r.raw.length),e.push(r);else{if(i=t,this.options.extensions&&this.options.extensions.startBlock){let e=1/0;const r=t.slice(1);let n;this.options.extensions.startBlock.forEach((function(t){n=t.call({lexer:this},r),"number"==typeof n&&n>=0&&(e=Math.min(e,n))})),e<1/0&&e>=0&&(i=t.substring(0,e+1))}if(this.state.top&&(r=this.tokenizer.paragraph(i)))n=e[e.length-1],s&&"paragraph"===n.type?(n.raw+="\n"+r.raw,n.text+="\n"+r.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=n.text):e.push(r),s=i.length!==t.length,t=t.substring(r.raw.length);else if(r=this.tokenizer.text(t))t=t.substring(r.raw.length),n=e[e.length-1],n&&"text"===n.type?(n.raw+="\n"+r.raw,n.text+="\n"+r.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=n.text):e.push(r);else if(t){const e="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(e);break}throw new Error(e)}}return this.state.top=!0,e}inline(t,e=[]){return this.inlineQueue.push({src:t,tokens:e}),e}inlineTokens(t,e=[]){let r,n,i,s,o,a,l=t;if(this.tokens.links){const t=Object.keys(this.tokens.links);if(t.length>0)for(;null!=(s=this.tokenizer.rules.inline.reflinkSearch.exec(l));)t.includes(s[0].slice(s[0].lastIndexOf("[")+1,-1))&&(l=l.slice(0,s.index)+"["+L("a",s[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(s=this.tokenizer.rules.inline.blockSkip.exec(l));)l=l.slice(0,s.index)+"["+L("a",s[0].length-2)+"]"+l.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;null!=(s=this.tokenizer.rules.inline.escapedEmSt.exec(l));)l=l.slice(0,s.index+s[0].length-2)+"++"+l.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex),this.tokenizer.rules.inline.escapedEmSt.lastIndex--;for(;t;)if(o||(a=""),o=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some((n=>!!(r=n.call({lexer:this},t,e))&&(t=t.substring(r.raw.length),e.push(r),!0)))))if(r=this.tokenizer.escape(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.tag(t))t=t.substring(r.raw.length),n=e[e.length-1],n&&"text"===r.type&&"text"===n.type?(n.raw+=r.raw,n.text+=r.text):e.push(r);else if(r=this.tokenizer.link(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.reflink(t,this.tokens.links))t=t.substring(r.raw.length),n=e[e.length-1],n&&"text"===r.type&&"text"===n.type?(n.raw+=r.raw,n.text+=r.text):e.push(r);else if(r=this.tokenizer.emStrong(t,l,a))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.codespan(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.br(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.del(t))t=t.substring(r.raw.length),e.push(r);else if(r=this.tokenizer.autolink(t,z))t=t.substring(r.raw.length),e.push(r);else if(this.state.inLink||!(r=this.tokenizer.url(t,z))){if(i=t,this.options.extensions&&this.options.extensions.startInline){let e=1/0;const r=t.slice(1);let n;this.options.extensions.startInline.forEach((function(t){n=t.call({lexer:this},r),"number"==typeof n&&n>=0&&(e=Math.min(e,n))})),e<1/0&&e>=0&&(i=t.substring(0,e+1))}if(r=this.tokenizer.inlineText(i,$))t=t.substring(r.raw.length),"_"!==r.raw.slice(-1)&&(a=r.raw.slice(-1)),o=!0,n=e[e.length-1],n&&"text"===n.type?(n.raw+=r.raw,n.text+=r.text):e.push(r);else if(t){const e="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(e);break}throw new Error(e)}}else t=t.substring(r.raw.length),e.push(r);return e}}class B{constructor(t){this.options=t||f}code(t,e,r){const n=(e||"").match(/\S*/)[0];if(this.options.highlight){const e=this.options.highlight(t,n);null!=e&&e!==t&&(r=!0,t=e)}return t=t.replace(/\n$/,"")+"\n",n?'<pre><code class="'+this.options.langPrefix+b(n)+'">'+(r?t:b(t,!0))+"</code></pre>\n":"<pre><code>"+(r?t:b(t,!0))+"</code></pre>\n"}blockquote(t){return`<blockquote>\n${t}</blockquote>\n`}html(t){return t}heading(t,e,r,n){return this.options.headerIds?`<h${e} id="${this.options.headerPrefix+n.slug(r)}">${t}</h${e}>\n`:`<h${e}>${t}</h${e}>\n`}hr(){return this.options.xhtml?"<hr/>\n":"<hr>\n"}list(t,e,r){const n=e?"ol":"ul";return"<"+n+(e&&1!==r?' start="'+r+'"':"")+">\n"+t+"</"+n+">\n"}listitem(t){return`<li>${t}</li>\n`}checkbox(t){return"<input "+(t?'checked="" ':"")+'disabled="" type="checkbox"'+(this.options.xhtml?" /":"")+"> "}paragraph(t){return`<p>${t}</p>\n`}table(t,e){return e&&(e=`<tbody>${e}</tbody>`),"<table>\n<thead>\n"+t+"</thead>\n"+e+"</table>\n"}tablerow(t){return`<tr>\n${t}</tr>\n`}tablecell(t,e){const r=e.header?"th":"td";return(e.align?`<${r} align="${e.align}">`:`<${r}>`)+t+`</${r}>\n`}strong(t){return`<strong>${t}</strong>`}em(t){return`<em>${t}</em>`}codespan(t){return`<code>${t}</code>`}br(){return this.options.xhtml?"<br/>":"<br>"}del(t){return`<del>${t}</del>`}link(t,e,r){if(null===(t=T(this.options.sanitize,this.options.baseUrl,t)))return r;let n='<a href="'+t+'"';return e&&(n+=' title="'+e+'"'),n+=">"+r+"</a>",n}image(t,e,r){if(null===(t=T(this.options.sanitize,this.options.baseUrl,t)))return r;let n=`<img src="${t}" alt="${r}"`;return e&&(n+=` title="${e}"`),n+=this.options.xhtml?"/>":">",n}text(t){return t}}class V{strong(t){return t}em(t){return t}codespan(t){return t}del(t){return t}html(t){return t}text(t){return t}link(t,e,r){return""+r}image(t,e,r){return""+r}br(){return""}}class q{constructor(){this.seen={}}serialize(t){return t.toLowerCase().trim().replace(/<[!\/a-z].*?>/gi,"").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g,"").replace(/\s/g,"-")}getNextSafeSlug(t,e){let r=t,n=0;if(this.seen.hasOwnProperty(r)){n=this.seen[t];do{n++,r=t+"-"+n}while(this.seen.hasOwnProperty(r))}return e||(this.seen[t]=n,this.seen[r]=0),r}slug(t,e={}){const r=this.serialize(t);return this.getNextSafeSlug(r,e.dryrun)}}class K{constructor(t){this.options=t||f,this.options.renderer=this.options.renderer||new B,this.renderer=this.options.renderer,this.renderer.options=this.options,this.textRenderer=new V,this.slugger=new q}static parse(t,e){return new K(e).parse(t)}static parseInline(t,e){return new K(e).parseInline(t)}parse(t,e=!0){let r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_,b,w="";const E=t.length;for(r=0;r<E;r++)if(h=t[r],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[h.type]&&(b=this.options.extensions.renderers[h.type].call({parser:this},h),!1!==b||!["space","hr","heading","code","table","blockquote","list","html","paragraph","text"].includes(h.type)))w+=b||"";else switch(h.type){case"space":continue;case"hr":w+=this.renderer.hr();continue;case"heading":w+=this.renderer.heading(this.parseInline(h.tokens),h.depth,x(this.parseInline(h.tokens,this.textRenderer)),this.slugger);continue;case"code":w+=this.renderer.code(h.text,h.lang,h.escaped);continue;case"table":for(c="",l="",s=h.header.length,n=0;n<s;n++)l+=this.renderer.tablecell(this.parseInline(h.header[n].tokens),{header:!0,align:h.align[n]});for(c+=this.renderer.tablerow(l),u="",s=h.rows.length,n=0;n<s;n++){for(a=h.rows[n],l="",o=a.length,i=0;i<o;i++)l+=this.renderer.tablecell(this.parseInline(a[i].tokens),{header:!1,align:h.align[i]});u+=this.renderer.tablerow(l)}w+=this.renderer.table(c,u);continue;case"blockquote":u=this.parse(h.tokens),w+=this.renderer.blockquote(u);continue;case"list":for(d=h.ordered,f=h.start,p=h.loose,s=h.items.length,u="",n=0;n<s;n++)g=h.items[n],y=g.checked,v=g.task,m="",g.task&&(_=this.renderer.checkbox(y),p?g.tokens.length>0&&"paragraph"===g.tokens[0].type?(g.tokens[0].text=_+" "+g.tokens[0].text,g.tokens[0].tokens&&g.tokens[0].tokens.length>0&&"text"===g.tokens[0].tokens[0].type&&(g.tokens[0].tokens[0].text=_+" "+g.tokens[0].tokens[0].text)):g.tokens.unshift({type:"text",text:_}):m+=_),m+=this.parse(g.tokens,p),u+=this.renderer.listitem(m,v,y);w+=this.renderer.list(u,d,f);continue;case"html":w+=this.renderer.html(h.text);continue;case"paragraph":w+=this.renderer.paragraph(this.parseInline(h.tokens));continue;case"text":for(u=h.tokens?this.parseInline(h.tokens):h.text;r+1<E&&"text"===t[r+1].type;)h=t[++r],u+="\n"+(h.tokens?this.parseInline(h.tokens):h.text);w+=e?this.renderer.paragraph(u):u;continue;default:{const t='Token with "'+h.type+'" type was not found.';if(this.options.silent)return void console.error(t);throw new Error(t)}}return w}parseInline(t,e){e=e||this.renderer;let r,n,i,s="";const o=t.length;for(r=0;r<o;r++)if(n=t[r],this.options.extensions&&this.options.extensions.renderers&&this.options.extensions.renderers[n.type]&&(i=this.options.extensions.renderers[n.type].call({parser:this},n),!1!==i||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(n.type)))s+=i||"";else switch(n.type){case"escape":case"text":s+=e.text(n.text);break;case"html":s+=e.html(n.text);break;case"link":s+=e.link(n.href,n.title,this.parseInline(n.tokens,e));break;case"image":s+=e.image(n.href,n.title,n.text);break;case"strong":s+=e.strong(this.parseInline(n.tokens,e));break;case"em":s+=e.em(this.parseInline(n.tokens,e));break;case"codespan":s+=e.codespan(n.text);break;case"br":s+=e.br();break;case"del":s+=e.del(this.parseInline(n.tokens,e));break;default:{const t='Token with "'+n.type+'" type was not found.';if(this.options.silent)return void console.error(t);throw new Error(t)}}return s}}class W{constructor(t){this.options=t||f}static passThroughHooks=new Set(["preprocess","postprocess"]);preprocess(t){return t}postprocess(t){return t}}function H(t,e){return(r,n,i)=>{"function"==typeof n&&(i=n,n=null);const s={...n},o=function(t,e,r){return n=>{if(n.message+="\nPlease report this to https://github.com/markedjs/marked.",t){const t="<p>An error occurred:</p><pre>"+b(n.message+"",!0)+"</pre>";return e?Promise.resolve(t):r?void r(null,t):t}if(e)return Promise.reject(n);if(!r)throw n;r(n)}}((n={...Y.defaults,...s}).silent,n.async,i);if(null==r)return o(new Error("marked(): input parameter is undefined or null"));if("string"!=typeof r)return o(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(r)+", string expected"));if(function(t){t&&t.sanitize&&!t.silent&&console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options")}(n),n.hooks&&(n.hooks.options=n),i){const s=n.highlight;let a;try{n.hooks&&(r=n.hooks.preprocess(r)),a=t(r,n)}catch(t){return o(t)}const l=function(t){let r;if(!t)try{n.walkTokens&&Y.walkTokens(a,n.walkTokens),r=e(a,n),n.hooks&&(r=n.hooks.postprocess(r))}catch(e){t=e}return n.highlight=s,t?o(t):i(null,r)};if(!s||s.length<3)return l();if(delete n.highlight,!a.length)return l();let c=0;return Y.walkTokens(a,(function(t){"code"===t.type&&(c++,setTimeout((()=>{s(t.text,t.lang,(function(e,r){if(e)return l(e);null!=r&&r!==t.text&&(t.text=r,t.escaped=!0),c--,0===c&&l()}))}),0))})),void(0===c&&l())}if(n.async)return Promise.resolve(n.hooks?n.hooks.preprocess(r):r).then((e=>t(e,n))).then((t=>n.walkTokens?Promise.all(Y.walkTokens(t,n.walkTokens)).then((()=>t)):t)).then((t=>e(t,n))).then((t=>n.hooks?n.hooks.postprocess(t):t)).catch(o);try{n.hooks&&(r=n.hooks.preprocess(r));const i=t(r,n);n.walkTokens&&Y.walkTokens(i,n.walkTokens);let s=e(i,n);return n.hooks&&(s=n.hooks.postprocess(s)),s}catch(t){return o(t)}}}function Y(t,e,r){return H(U.lex,K.parse)(t,e,r)}Y.options=Y.setOptions=function(t){var e;return Y.defaults={...Y.defaults,...t},e=Y.defaults,f=e,Y},Y.getDefaults=function(){return{async:!1,baseUrl:null,breaks:!1,extensions:null,gfm:!0,headerIds:!0,headerPrefix:"",highlight:null,hooks:null,langPrefix:"language-",mangle:!0,pedantic:!1,renderer:null,sanitize:!1,sanitizer:null,silent:!1,smartypants:!1,tokenizer:null,walkTokens:null,xhtml:!1}},Y.defaults=f,Y.use=function(...t){const e=Y.defaults.extensions||{renderers:{},childTokens:{}};t.forEach((t=>{const r={...t};if(r.async=Y.defaults.async||r.async||!1,t.extensions&&(t.extensions.forEach((t=>{if(!t.name)throw new Error("extension name required");if(t.renderer){const r=e.renderers[t.name];e.renderers[t.name]=r?function(...e){let n=t.renderer.apply(this,e);return!1===n&&(n=r.apply(this,e)),n}:t.renderer}if(t.tokenizer){if(!t.level||"block"!==t.level&&"inline"!==t.level)throw new Error("extension level must be 'block' or 'inline'");e[t.level]?e[t.level].unshift(t.tokenizer):e[t.level]=[t.tokenizer],t.start&&("block"===t.level?e.startBlock?e.startBlock.push(t.start):e.startBlock=[t.start]:"inline"===t.level&&(e.startInline?e.startInline.push(t.start):e.startInline=[t.start]))}t.childTokens&&(e.childTokens[t.name]=t.childTokens)})),r.extensions=e),t.renderer){const e=Y.defaults.renderer||new B;for(const r in t.renderer){const n=e[r];e[r]=(...i)=>{let s=t.renderer[r].apply(e,i);return!1===s&&(s=n.apply(e,i)),s}}r.renderer=e}if(t.tokenizer){const e=Y.defaults.tokenizer||new j;for(const r in t.tokenizer){const n=e[r];e[r]=(...i)=>{let s=t.tokenizer[r].apply(e,i);return!1===s&&(s=n.apply(e,i)),s}}r.tokenizer=e}if(t.hooks){const e=Y.defaults.hooks||new W;for(const r in t.hooks){const n=e[r];W.passThroughHooks.has(r)?e[r]=i=>{if(Y.defaults.async)return Promise.resolve(t.hooks[r].call(e,i)).then((t=>n.call(e,t)));const s=t.hooks[r].call(e,i);return n.call(e,s)}:e[r]=(...i)=>{let s=t.hooks[r].apply(e,i);return!1===s&&(s=n.apply(e,i)),s}}r.hooks=e}if(t.walkTokens){const e=Y.defaults.walkTokens;r.walkTokens=function(r){let n=[];return n.push(t.walkTokens.call(this,r)),e&&(n=n.concat(e.call(this,r))),n}}Y.setOptions(r)}))},Y.walkTokens=function(t,e){let r=[];for(const n of t)switch(r=r.concat(e.call(Y,n)),n.type){case"table":for(const t of n.header)r=r.concat(Y.walkTokens(t.tokens,e));for(const t of n.rows)for(const n of t)r=r.concat(Y.walkTokens(n.tokens,e));break;case"list":r=r.concat(Y.walkTokens(n.items,e));break;default:Y.defaults.extensions&&Y.defaults.extensions.childTokens&&Y.defaults.extensions.childTokens[n.type]?Y.defaults.extensions.childTokens[n.type].forEach((function(t){r=r.concat(Y.walkTokens(n[t],e))})):n.tokens&&(r=r.concat(Y.walkTokens(n.tokens,e)))}return r},Y.parseInline=H(U.lexInline,K.parseInline),Y.Parser=K,Y.parser=K.parse,Y.Renderer=B,Y.TextRenderer=V,Y.Lexer=U,Y.lexer=U.lex,Y.Tokenizer=j,Y.Slugger=q,Y.Hooks=W,Y.parse=Y,Y.options,Y.setOptions,Y.use,Y.walkTokens,Y.parseInline;const X=/(\$\$?|\\(?:begin|end)\{[a-z]*\*?\}|\\[{}$]|[{}]|(?:\n\s*)+|@@\d+@@|\\\\(?:\(|\)|\[|\]))/i;function Z(t,e,r,n,i){let s=i.slice(t,e+1).join("").replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;");for(navigator&&"Microsoft Internet Explorer"===navigator.appName&&(s=s.replace(/(%[^\n]*)\n/g,"$1<br/>\n"));e>t;)i[e]="",e--;return i[t]="@@"+n.length+"@@",r&&(s=r(s)),n.push(s),i}var J;async function Q(t){const{host:e,source:r}=t,n=function(t,e){var r={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(r[n]=t[n]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(t);i<n.length;i++)e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(t,n[i])&&(r[n[i]]=t[n[i]])}return r}(t,["host","source"]);if(!r)return void(e.textContent="");const i=function(t){const e=[];let r,n=null,i=null,s=null,o=0;t.includes("`")||t.includes("~~~")?(t=t.replace(/~/g,"~T").replace(/^(?<fence>`{3,}|(~T){3,})[^`\n]*\n([\s\S]*?)^\k<fence>`*$/gm,(t=>t.replace(/\$/g,"~D"))).replace(/(^|[^\\])(`+)([^\n]*?[^`\n])\2(?!`)/gm,(t=>t.replace(/\$/g,"~D"))),r=t=>t.replace(/~([TD])/g,((t,e)=>"T"===e?"~":"$"))):r=t=>t;let a=t.replace(/\r\n?/g,"\n").split(X);for(let t=1,l=a.length;t<l;t+=2){const l=a[t];"@"===l.charAt(0)?(a[t]="@@"+e.length+"@@",e.push(l)):null!==n?l===i?o?s=t:(a=Z(n,t,r,e,a),n=null,i=null,s=null):l.match(/\n.*\n/)?(null!==s&&(t=s,a=Z(n,t,r,e,a)),n=null,i=null,s=null,o=0):"{"===l?o++:"}"===l&&o&&o--:"$"===l||"$$"===l?(n=t,i=l,o=0):"\\\\("===l||"\\\\["===l?(n=t,i="("===l.slice(-1)?"\\\\)":"\\\\]",o=0):"begin"===l.substr(1,5)&&(n=t,i="\\end"+l.substr(6),o=0)}return null!==n&&null!==s&&(a=Z(n,s,r,e,a),n=null,i=null,s=null),{text:r(a.join("")),math:e}}(r);let s=await Q.renderMarked(i.text);var o,a;o=s,a=i.math,s=o.replace(/@@(\d+)@@/g,((t,e)=>{let r=a[e];return"\\\\("===r.substr(0,3)&&"\\\\)"===r.substr(r.length-3)?r="\\("+r.substring(3,r.length-3)+"\\)":"\\\\["===r.substr(0,3)&&"\\\\]"===r.substr(r.length-3)&&(r="\\["+r.substring(3,r.length-3)+"\\]"),r})),await function(t){let{host:e,source:r,trusted:n,sanitizer:i,resolver:s,linkHandler:o,shouldTypeset:a,latexTypesetter:l,translator:u}=t;u=u||c.nullTranslator;const h=null==u?void 0:u.load("jupyterlab");let d,f=r;if(!r)return e.textContent="",Promise.resolve(void 0);if(n||(f=`${r}`,r=i.sanitize(r)),e.innerHTML=r,e.getElementsByTagName("script").length>0)if(n)J.evalInnerHTMLScriptTags(e);else{const t=document.createElement("div"),r=document.createElement("pre");r.textContent=h.__("This HTML output contains inline scripts. Are you sure that you want to run arbitrary Javascript within your JupyterLab session?");const n=document.createElement("button");n.textContent=h.__("Run"),n.onclick=t=>{e.innerHTML=f,J.evalInnerHTMLScriptTags(e),e.firstChild&&e.removeChild(e.firstChild)},t.appendChild(r),t.appendChild(n),e.insertBefore(t,e.firstChild)}return J.handleDefaults(e,s),d=s?J.handleUrls(e,s,o):Promise.resolve(void 0),d.then((()=>{a&&l&&l.typeset(e)}))}(Object.assign({host:e,source:s},n)),J.headerAnchors(e)}!function(t){t.renderMarked=function(t){return J.initializeMarked(),new Promise(((e,r)=>{Y(t,((t,n)=>{t?r(t):e(n)}))}))}}(Q||(Q={})),function(t){async function e(t,e,r){const n=t.getAttribute(e)||"",i=r.isLocal?r.isLocal(n):l.URLExt.isLocal(n);if(n&&i)try{const i=await r.resolveUrl(n);let s=await r.getDownloadUrl(i);"data:"!==l.URLExt.parse(s).protocol&&(s+=(/\?/.test(s)?"&":"?")+(new Date).getTime()),t.setAttribute(e,s)}catch(r){throw t.setAttribute(e,""),r}}function r(t,e,r){let n=t.getAttribute("href")||"";const i=e.isLocal?e.isLocal(n):l.URLExt.isLocal(n);if(!n||!i)return Promise.resolve(void 0);const s=t.hash;if(s){if(s===n)return t.target="_self",Promise.resolve(void 0);n=n.replace(s,"")}return e.resolveUrl(n).then((n=>{const i=decodeURIComponent(n);return r&&r.handleLink(t,i,s),e.getDownloadUrl(n)})).then((e=>{t.href=e+s})).catch((e=>{t.href=""}))}t.evalInnerHTMLScriptTags=function(t){const e=(0,u.toArray)(t.getElementsByTagName("script"));for(const t of e){if(!t.parentNode)continue;const e=document.createElement("script"),r=t.attributes;for(let t=0,n=r.length;t<n;++t){const{name:n,value:i}=r[t];e.setAttribute(n,i)}e.textContent=t.textContent,t.parentNode.replaceChild(e,t)}},t.handleDefaults=function(t,e){const r=t.getElementsByTagName("a");for(let t=0;t<r.length;t++){const n=r[t];if(!(n instanceof HTMLAnchorElement))continue;const i=n.href,s=e&&e.isLocal?e.isLocal(i):l.URLExt.isLocal(i);n.target||(n.target=s?"_self":"_blank"),s||(n.rel="noopener")}const n=t.getElementsByTagName("img");for(let t=0;t<n.length;t++)n[t].alt||(n[t].alt="Image")},t.handleUrls=function(t,n,i){const s=[],o=t.querySelectorAll("*[src]");for(let t=0;t<o.length;t++)s.push(e(o[t],"src",n));const a=t.getElementsByTagName("a");for(let t=0;t<a.length;t++)s.push(r(a[t],n,i));const l=t.getElementsByTagName("link");for(let t=0;t<l.length;t++)s.push(e(l[t],"href",n));return Promise.all(s).then((()=>{}))},t.headerAnchors=function(t){var e;const r=["h1","h2","h3","h4","h5","h6"];for(const n of r){const r=t.getElementsByTagName(n);for(let t=0;t<r.length;t++){const n=r[t];n.id=(null!==(e=n.textContent)&&void 0!==e?e:"").replace(/ /g,"-");const i=document.createElement("a");i.target="_self",i.textContent="¶",i.href="#"+n.id,i.classList.add("jp-InternalAnchorLink"),n.appendChild(i)}}};let n=!1;t.initializeMarked=function(){n||(n=!0,Y.setOptions({gfm:!0,sanitize:!1,langPrefix:`cm-s-${a.CodeMirrorEditor.defaultConfig.theme} language-`,highlight:(t,e,r)=>{const n=(t,e)=>(r&&r(t,e),e);return e?(a.Mode.ensure(e).then((r=>{const i=document.createElement("div");if(!r)return console.error(`No CodeMirror mode: ${e}`),n(null,t);try{return a.Mode.run(t,r.mime,i),n(null,i.innerHTML)}catch(r){return console.error(`Failed to highlight ${e} code`,r),n(r,t)}})).catch((r=>(console.error(`No CodeMirror mode: ${e}`),console.error(`Require CodeMirror mode error: ${r}`),n(null,t)))),t):n(null,t)}}))};const i=["ansi-black","ansi-red","ansi-green","ansi-yellow","ansi-blue","ansi-magenta","ansi-cyan","ansi-white","ansi-black-intense","ansi-red-intense","ansi-green-intense","ansi-yellow-intense","ansi-blue-intense","ansi-magenta-intense","ansi-cyan-intense","ansi-white-intense"];function s(t,e,r,n,s,o,a){if(t){const l=[],c=[];n&&"number"==typeof e&&0<=e&&e<8&&(e+=8),o&&([e,r]=[r,e]),"number"==typeof e?l.push(i[e]+"-fg"):e.length?c.push(`color: rgb(${e})`):o&&l.push("ansi-default-inverse-fg"),"number"==typeof r?l.push(i[r]+"-bg"):r.length?c.push(`background-color: rgb(${r})`):o&&l.push("ansi-default-inverse-bg"),n&&l.push("ansi-bold"),s&&l.push("ansi-underline"),l.length||c.length?(a.push("<span"),l.length&&a.push(` class="${l.join(" ")}"`),c.length&&a.push(` style="${c.join("; ")}"`),a.push(">"),a.push(t),a.push("</span>")):a.push(t)}}function o(t){let e,r,n;const i=t.shift();if(2===i&&t.length>=3){if(e=t.shift(),r=t.shift(),n=t.shift(),[e,r,n].some((t=>t<0||255<t)))throw new RangeError("Invalid range for RGB colors")}else{if(!(5===i&&t.length>=1))throw new RangeError("Invalid extended color specification");{const i=t.shift();if(i<0)throw new RangeError("Color index must be >= 0");if(i<16)return i;if(i<232)e=Math.floor((i-16)/36),e=e>0?55+40*e:0,r=Math.floor((i-16)%36/6),r=r>0?55+40*r:0,n=(i-16)%6,n=n>0?55+40*n:0;else{if(!(i<256))throw new RangeError("Color index must be < 256");e=r=n=10*(i-232)+8}}}return[e,r,n]}t.ansiSpan=function(t){const e=/\x1b\[(.*?)([@-~])/g;let r,n=[],i=[],a=!1,l=!1,c=!1;const u=[],h=[];let f=0;for(t=d()(t),t+="";r=e.exec(t);){if("m"===r[2]){const t=r[1].split(";");for(let e=0;e<t.length;e++){const r=t[e];if(""===r)h.push(0);else{if(-1===r.search(/^\d+$/)){h.length=0;break}h.push(parseInt(r,10))}}}for(s(t.substring(f,r.index),n,i,a,l,c,u),f=e.lastIndex;h.length;){const t=h.shift();switch(t){case 0:n=i=[],a=!1,l=!1,c=!1;break;case 1:case 5:a=!0;break;case 4:l=!0;break;case 7:c=!0;break;case 21:case 22:a=!1;break;case 24:l=!1;break;case 27:c=!1;break;case 30:case 31:case 32:case 33:case 34:case 35:case 36:case 37:n=t-30;break;case 38:try{n=o(h)}catch(t){h.length=0}break;case 39:n=[];break;case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:i=t-40;break;case 48:try{i=o(h)}catch(t){h.length=0}break;case 49:i=[];break;case 90:case 91:case 92:case 93:case 94:case 95:case 96:case 97:n=t-90+8;break;case 100:case 101:case 102:case 103:case 104:case 105:case 106:case 107:i=t-100+8}}}return u.join("")}}(J||(J={}));var tt=r(74602);class et extends o.VDomModel{constructor(t,e,r){super(),this._errors=[],this._errorsObserved=!1,this._rendered=new tt.Signal(this),this._liveMarkdown=!1,this.schema=t,e&&(this.props=e,e.formData&&(this._formData=e.formData)),r&&(this._markdown=r.markdown||null,this._liveMarkdown=null!=r.liveMarkdown?r.liveMarkdown:this._liveMarkdown)}get errors(){return this._errors}set errors(t){this._errors=t,this.stateChanged.emit(void 0)}get formData(){return this._formData}set formData(t){this._formData=t,this.stateChanged.emit(void 0)}get schema(){return this._schema}set schema(t){this._schema=t,this.stateChanged.emit(void 0)}set uiSchema(t){this._props.uiSchema=t,this.stateChanged.emit(void 0)}get uiSchema(){return this._props.uiSchema}get props(){return this._props}set props(t){this._props=t,this.stateChanged.emit(void 0)}get errorsObserved(){return this._errorsObserved}set errorsObserved(t){t!==this._errorsObserved&&(this._errorsObserved=t,this.stateChanged.emit(void 0))}get rendered(){return this._rendered}emitRenderered(){this._rendered.emit(void 0)}get markdown(){return this._markdown}get liveMarkdown(){return this._liveMarkdown}set liveMarkdown(t){this._liveMarkdown=t,this.stateChanged.emit(void 0)}}const rt=["jp-RenderedMarkdown","jp-RenderedHTMLCommon"],nt=["legend",".field-description",".control-label",".help-block",".field-radio-group .radio > label > span > span",".field-boolean .checkbox > label > span"],it=nt.join(", "),st=nt.map((t=>`${t}:not(.jp-RenderedMarkdown)`)).join(", "),ot="jp-SchemaForm-markdown";class at extends o.VDomRenderer{constructor(t,e={},r){super(new et(t,e,r)),this._renderMarkdown=async()=>{const t=Array.from(this.node.querySelectorAll(this.model.liveMarkdown?st:it));if(!t.length&&!this._initialRender)return this._initialRenderDelay=2*this._initialRenderDelay,void setTimeout(this._renderMarkdown,this._initialRenderDelay);this._initialRender=!0,await Promise.all(t.map(this._renderOneMarkdown))},this._renderOneMarkdown=async t=>{if(t.querySelector(`.${ot}`))return;const e=this.model.markdown;if(null==e)return;const{textContent:r,dataset:n}=t,{rawMarkdown:i}=n,s=i||r;if(null==s||!s.trim())return;r&&(n.rawMarkdown=r),t.classList.add(...rt),await Q({host:t,source:i||r||"",trusted:!0,sanitizer:e.sanitizer,latexTypesetter:e.latexTypesetter,resolver:e.resolver,linkHandler:e.linkHandler,shouldTypeset:!0});const o=document.createElement("span");o.className=ot,t.appendChild(o)},this._postRender=()=>{this.model.errorsObserved=!!this.node.querySelector(".errors"),this.model.emitRenderered()},this._initialRender=!1,this._initialRenderDelay=10,this._idPrefix=`id-jp-schemaform-${lt.nextId()}`,this.model.markdown&&this.model.rendered.connect(this._renderMarkdown)}render(){if(!this.model)return null;const{schema:t,props:e,formData:r}=this.model,n=`jp-SchemaForm ${e.className||""}`.trim(),o=Object.assign(Object.assign({},e),{idPrefix:this._idPrefix,schema:t,formData:r,className:n,validate:(t,e)=>e,onChange:(t,r)=>{this.onChange(t,r),e.onChange&&e.onChange(t,r)}});return setTimeout(this._postRender,100),i().createElement(s,Object.assign({},o))}onChange(t,e){const{formData:r,errors:n}=t;null!=r&&(this.model.errors=n,this.model.formData=r),this.model.stateChanged.emit(void 0)}getValue(){return{formData:this.model.formData,errors:this.model.errors}}}var lt;!function(t){let e=0;t.nextId=function(){return e++}}(lt||(lt={})),r(72192)},72192:(t,e,r)=>{"use strict";r.d(e,{A:()=>An,W:()=>n,withTheme:()=>Sn});var n={};r.r(n),r.d(n,{ADDITIONAL_PROPERTY_FLAG:()=>yr,allowAdditionalItems:()=>Gr,asNumber:()=>Rr,canExpand:()=>_r,dataURItoBlob:()=>ln,deepEquals:()=>Jr,findSchemaDefinition:()=>zr,getDefaultFormState:()=>Ar,getDefaultRegistry:()=>br,getDisplayLabel:()=>Cr,getMatchingOption:()=>un,getSchemaType:()=>wr,getUiOptions:()=>Tr,getWidget:()=>xr,guessType:()=>Ur,hasWidget:()=>Er,isConstant:()=>Ir,isFilesArray:()=>jr,isFixedItems:()=>Nr,isMultiSelect:()=>Fr,isObject:()=>Mr,isSelect:()=>Lr,localToUTC:()=>on,mergeDefaultsWithFormData:()=>Pr,mergeObjects:()=>Or,mergeSchemas:()=>Xr,optionsList:()=>$r,orderProperties:()=>Dr,pad:()=>an,parseDateString:()=>rn,rangeSpec:()=>cn,resolveSchema:()=>Vr,retrieveSchema:()=>Kr,schemaRequiresTrueValue:()=>hn,shouldRender:()=>Qr,stubExistingAdditionalProperties:()=>Br,toConstant:()=>kr,toDateString:()=>nn,toIdSchema:()=>tn,toPathSchema:()=>en,utcToLocal:()=>sn});var i=r(93345),s=r.n(i),o=r(74874),a=r.n(o),l=r(46123),c=r.n(l),u=r(3514),h=r.n(u),d=r(524),f=r(587),p=r.n(f),m=r(8125),g=r.n(m),y=r(55620),v=r.n(y),_=r(45838);function b(){return b=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},b.apply(this,arguments)}function w(t){var e=t.type,r=void 0===e?"default":e,n=t.icon,i=t.className,o=function(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}(t,["type","icon","className"]);return s().createElement("button",b({type:"button",className:"btn btn-".concat(r," ").concat(i)},o),s().createElement("i",{className:"glyphicon glyphicon-".concat(n)}))}function x(t){var e=t.className,r=t.onClick,n=t.disabled;return s().createElement("div",{className:"row"},s().createElement("p",{className:"col-xs-3 col-xs-offset-9 text-right ".concat(e)},s().createElement(w,{type:"info",icon:"plus",className:"btn-add col-xs-12","aria-label":"Add",tabIndex:"0",onClick:r,disabled:n})))}var E=r(92654),S=r.n(E),A=r(39067),P=r.n(A),T=P().shape({ArrayFieldTemplate:P().elementType,FieldTemplate:P().elementType,ObjectFieldTemplate:P().elementType,definitions:P().object.isRequired,rootSchema:P().object,fields:P().objectOf(P().elementType).isRequired,formContext:P().object.isRequired,widgets:P().objectOf(P().oneOfType([P().func,P().object])).isRequired});function C(t){return C="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},C(t)}function M(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}function O(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){F(t,e,r[e])}))}return t}function R(t){return function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function D(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function I(t){return I=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},I(t)}function k(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function L(t,e){return L=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},L(t,e)}function F(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function j(t){var e=t.TitleField,r=t.idSchema,n=t.title,i=t.required;if(!n)return null;var o="".concat(r.$id,"__title");return s().createElement(e,{id:o,title:n,required:i})}function N(t){var e=t.DescriptionField,r=t.idSchema,n=t.description;if(!n)return null;var i="".concat(r.$id,"__description");return s().createElement(e,{id:i,description:n})}function G(t){var e={flex:1,paddingLeft:6,paddingRight:6,fontWeight:"bold"};return s().createElement("div",{key:t.key,className:t.className},s().createElement("div",{className:t.hasToolbar?"col-xs-9":"col-xs-12"},t.children),t.hasToolbar&&s().createElement("div",{className:"col-xs-3 array-item-toolbox"},s().createElement("div",{className:"btn-group",style:{display:"flex",justifyContent:"space-around"}},(t.hasMoveUp||t.hasMoveDown)&&s().createElement(w,{icon:"arrow-up","aria-label":"Move up",className:"array-item-move-up",tabIndex:"-1",style:e,disabled:t.disabled||t.readonly||!t.hasMoveUp,onClick:t.onReorderClick(t.index,t.index-1)}),(t.hasMoveUp||t.hasMoveDown)&&s().createElement(w,{icon:"arrow-down",className:"array-item-move-down","aria-label":"Move down",tabIndex:"-1",style:e,disabled:t.disabled||t.readonly||!t.hasMoveDown,onClick:t.onReorderClick(t.index,t.index+1)}),t.hasRemove&&s().createElement(w,{type:"danger",icon:"remove","aria-label":"Remove",className:"array-item-remove",tabIndex:"-1",style:e,disabled:t.disabled||t.readonly,onClick:t.onDropIndexClick(t.index)}))))}function $(t){return s().createElement("fieldset",{className:t.className,id:t.idSchema.$id},s().createElement(j,{key:"array-field-title-".concat(t.idSchema.$id),TitleField:t.TitleField,idSchema:t.idSchema,title:t.uiSchema["ui:title"]||t.title,required:t.required}),(t.uiSchema["ui:description"]||t.schema.description)&&s().createElement("div",{className:"field-description",key:"field-description-".concat(t.idSchema.$id)},t.uiSchema["ui:description"]||t.schema.description),s().createElement("div",{className:"row array-item-list",key:"array-item-list-".concat(t.idSchema.$id)},t.items&&t.items.map(G)),t.canAdd&&s().createElement(x,{className:"array-item-add",onClick:t.onAddClick,disabled:t.disabled||t.readonly}))}function z(t){return s().createElement("fieldset",{className:t.className,id:t.idSchema.$id},s().createElement(j,{key:"array-field-title-".concat(t.idSchema.$id),TitleField:t.TitleField,idSchema:t.idSchema,title:t.uiSchema["ui:title"]||t.title,required:t.required}),(t.uiSchema["ui:description"]||t.schema.description)&&s().createElement(N,{key:"array-field-description-".concat(t.idSchema.$id),DescriptionField:t.DescriptionField,idSchema:t.idSchema,description:t.uiSchema["ui:description"]||t.schema.description}),s().createElement("div",{className:"row array-item-list",key:"array-item-list-".concat(t.idSchema.$id)},t.items&&t.items.map((function(t){return G(t)}))),t.canAdd&&s().createElement(x,{className:"array-item-add",onClick:t.onAddClick,disabled:t.disabled||t.readonly}))}function U(){return((t=21)=>crypto.getRandomValues(new Uint8Array(t)).reduce(((t,e)=>t+((e&=63)<36?e.toString(36):e<62?(e-26).toString(36).toUpperCase():e>62?"-":"_")),""))()}function B(t){return Array.isArray(t)?t.map((function(t){return{key:U(),item:t}})):[]}function V(t){return t.map((function(t){return t.item}))}P().bool,P().bool,P().object,P().any,P().object,P().func,P().func.isRequired,P().func,P().arrayOf(P().string),P().bool,T.isRequired,P().bool,P().object.isRequired,P().shape({"ui:options":P().shape({addable:P().bool,orderable:P().bool,removable:P().bool})});var q=function(t){function e(t){var r;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),r=function(t,e){return!e||"object"!==C(e)&&"function"!=typeof e?k(t):e}(this,I(e).call(this,t)),F(k(r),"_getNewFormDataRow",(function(){var t=r.props,e=t.schema,n=t.registry,i=(void 0===n?br():n).rootSchema,s=e.items;return Nr(e)&&Gr(e)&&(s=e.additionalItems),Ar(s,void 0,i)})),F(k(r),"onAddClick",(function(t){t&&t.preventDefault();var e=r.props.onChange,n={key:U(),item:r._getNewFormDataRow()},i=[].concat(R(r.state.keyedFormData),[n]);r.setState({keyedFormData:i,updatedKeyedFormData:!0},(function(){return e(V(i))}))})),F(k(r),"onAddIndexClick",(function(t){return function(e){e&&e.preventDefault();var n=r.props.onChange,i={key:U(),item:r._getNewFormDataRow()},s=R(r.state.keyedFormData);s.splice(t,0,i),r.setState({keyedFormData:s,updatedKeyedFormData:!0},(function(){return n(V(s))}))}})),F(k(r),"onDropIndexClick",(function(t){return function(e){e&&e.preventDefault();var n,i=r.props.onChange,s=r.state.keyedFormData;if(r.props.errorSchema){n={};var o=r.props.errorSchema;for(var a in o)(a=parseInt(a))<t?n[a]=o[a]:a>t&&(n[a-1]=o[a])}var l=s.filter((function(e,r){return r!==t}));r.setState({keyedFormData:l,updatedKeyedFormData:!0},(function(){return i(V(l),n)}))}})),F(k(r),"onReorderClick",(function(t,e){return function(n){n&&(n.preventDefault(),n.target.blur());var i,s=r.props.onChange;if(r.props.errorSchema){i={};var o=r.props.errorSchema;for(var a in o)a==t?i[e]=o[t]:a==e?i[t]=o[e]:i[a]=o[a]}var l,c=r.state.keyedFormData,u=((l=c.slice()).splice(t,1),l.splice(e,0,c[t]),l);r.setState({keyedFormData:u},(function(){return s(V(u),i)}))}})),F(k(r),"onChangeForIndex",(function(t){return function(e,n){var i=r.props,s=i.formData;(0,i.onChange)(s.map((function(r,n){return t===n?void 0===e?null:e:r})),n&&r.props.errorSchema&&O({},r.props.errorSchema,F({},t,n)))}})),F(k(r),"onSelectChange",(function(t){r.props.onChange(t)}));var n=B(t.formData);return r.state={keyedFormData:n,updatedKeyedFormData:!1},r}var r,n,i;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&L(t,e)}(e,t),r=e,n=[{key:"isItemRequired",value:function(t){return Array.isArray(t.type)?!S()(t.type,"null"):"null"!==t.type}},{key:"canAddItem",value:function(t){var e=this.props,r=e.schema,n=Tr(e.uiSchema).addable;return!1!==n&&(n=void 0===r.maxItems||t.length<r.maxItems),n}},{key:"render",value:function(){var t=this.props,e=t.schema,r=t.uiSchema,n=t.idSchema,i=t.registry,o=void 0===i?br():i,a=o.rootSchema;if(!e.hasOwnProperty("items")){var l=o.fields.UnsupportedField;return s().createElement(l,{schema:e,idSchema:n,reason:"Missing items definition"})}return Nr(e)?this.renderFixedArray():jr(e,r,a)?this.renderFiles():Fr(e,a)?this.renderMultiSelect():this.renderNormalArray()}},{key:"renderNormalArray",value:function(){var t=this,e=this.props,r=e.schema,n=e.uiSchema,i=e.errorSchema,o=e.idSchema,a=e.name,l=e.required,c=e.disabled,u=e.readonly,h=e.autofocus,d=e.registry,f=void 0===d?br():d,p=e.onBlur,m=e.onFocus,g=e.idPrefix,y=e.rawErrors,v=void 0===r.title?a:r.title,_=f.ArrayFieldTemplate,b=f.rootSchema,w=f.fields,x=f.formContext,E=w.TitleField,S=w.DescriptionField,A=Kr(r.items,b),P=V(this.state.keyedFormData),T={canAdd:this.canAddItem(P),items:this.state.keyedFormData.map((function(e,s){var a=e.key,l=e.item,c=Kr(r.items,b,l),u=i?i[s]:void 0,d=tn(c,o.$id+"_"+s,b,l,g);return t.renderArrayFieldItem({key:a,index:s,canMoveUp:s>0,canMoveDown:s<P.length-1,itemSchema:c,itemIdSchema:d,itemErrorSchema:u,itemData:l,itemUiSchema:n.items,autofocus:h&&0===s,onBlur:p,onFocus:m})})),className:"field field-array field-array-of-".concat(A.type),DescriptionField:S,disabled:c,idSchema:o,uiSchema:n,onAddClick:this.onAddClick,readonly:u,required:l,schema:r,title:v,TitleField:E,formContext:x,formData:P,rawErrors:y,registry:f},C=n["ui:ArrayFieldTemplate"]||_||z;return s().createElement(C,T)}},{key:"renderMultiSelect",value:function(){var t=this.props,e=t.schema,r=t.idSchema,n=t.uiSchema,i=t.formData,o=t.disabled,a=t.readonly,l=t.required,c=t.placeholder,u=t.autofocus,h=t.onBlur,d=t.onFocus,f=t.registry,p=void 0===f?br():f,m=t.rawErrors,g=t.name,y=this.props.formData,v=p.widgets,_=p.rootSchema,b=p.formContext,w=Kr(e.items,_,i),x=e.title||g,E=$r(w),S=O({},Tr(n),{enumOptions:E}),A=S.widget,P=void 0===A?"select":A,T=M(S,["widget"]),C=xr(e,P,v);return s().createElement(C,{id:r&&r.$id,multiple:!0,onChange:this.onSelectChange,onBlur:h,onFocus:d,options:T,schema:e,registry:p,value:y,disabled:o,readonly:a,required:l,label:x,placeholder:c,formContext:b,autofocus:u,rawErrors:m})}},{key:"renderFiles",value:function(){var t=this.props,e=t.schema,r=t.uiSchema,n=t.idSchema,i=t.name,o=t.disabled,a=t.readonly,l=t.autofocus,c=t.onBlur,u=t.onFocus,h=t.registry,d=void 0===h?br():h,f=t.rawErrors,p=e.title||i,m=this.props.formData,g=d.widgets,y=d.formContext,v=Tr(r),_=v.widget,b=void 0===_?"files":_,w=M(v,["widget"]),x=xr(e,b,g);return s().createElement(x,{options:w,id:n&&n.$id,multiple:!0,onChange:this.onSelectChange,onBlur:c,onFocus:u,schema:e,title:p,value:m,disabled:o,readonly:a,formContext:y,autofocus:l,rawErrors:f})}},{key:"renderFixedArray",value:function(){var t=this,e=this.props,r=e.schema,n=e.uiSchema,i=e.formData,o=e.errorSchema,a=e.idPrefix,l=e.idSchema,c=e.name,u=e.required,h=e.disabled,d=e.readonly,f=e.autofocus,p=e.registry,m=void 0===p?br():p,g=e.onBlur,y=e.onFocus,v=e.rawErrors,_=r.title||c,b=this.props.formData,w=m.ArrayFieldTemplate,x=m.rootSchema,E=m.fields,S=m.formContext,A=E.TitleField,P=r.items.map((function(t,e){return Kr(t,x,i[e])})),T=Gr(r)?Kr(r.additionalItems,x,i):null;(!b||b.length<P.length)&&(b=(b=b||[]).concat(new Array(P.length-b.length)));var C={canAdd:this.canAddItem(b)&&T,className:"field field-array field-array-fixed-items",disabled:h,idSchema:l,formData:i,items:this.state.keyedFormData.map((function(e,i){var s=e.key,c=e.item,u=i>=P.length,h=u?Kr(r.additionalItems,x,c):P[i],d=tn(h,l.$id+"_"+i,x,c,a),p=u?n.additionalItems||{}:Array.isArray(n.items)?n.items[i]:n.items||{},m=o?o[i]:void 0;return t.renderArrayFieldItem({key:s,index:i,canRemove:u,canMoveUp:i>=P.length+1,canMoveDown:u&&i<b.length-1,itemSchema:h,itemData:c,itemUiSchema:p,itemIdSchema:d,itemErrorSchema:m,autofocus:f&&0===i,onBlur:g,onFocus:y})})),onAddClick:this.onAddClick,readonly:d,required:u,schema:r,uiSchema:n,title:_,TitleField:A,formContext:S,rawErrors:v},M=n["ui:ArrayFieldTemplate"]||w||$;return s().createElement(M,C)}},{key:"renderArrayFieldItem",value:function(t){var e=t.key,r=t.index,n=t.canRemove,i=void 0===n||n,o=t.canMoveUp,a=void 0===o||o,l=t.canMoveDown,c=void 0===l||l,u=t.itemSchema,h=t.itemData,d=t.itemUiSchema,f=t.itemIdSchema,p=t.itemErrorSchema,m=t.autofocus,g=t.onBlur,y=t.onFocus,v=t.rawErrors,_=this.props,b=_.disabled,w=_.readonly,x=_.uiSchema,E=_.registry,S=(void 0===E?br():E).fields.SchemaField,A=O({orderable:!0,removable:!0},x["ui:options"]),P=A.orderable,T={moveUp:P&&a,moveDown:P&&c,remove:A.removable&&i};return T.toolbar=Object.keys(T).some((function(t){return T[t]})),{children:s().createElement(S,{index:r,schema:u,uiSchema:d,formData:h,errorSchema:p,idSchema:f,required:this.isItemRequired(u),onChange:this.onChangeForIndex(r),onBlur:g,onFocus:y,registry:this.props.registry,disabled:this.props.disabled,readonly:this.props.readonly,autofocus:m,rawErrors:v}),className:"array-item",disabled:b,hasToolbar:T.toolbar,hasMoveUp:T.moveUp,hasMoveDown:T.moveDown,hasRemove:T.remove,index:r,key:e,onAddIndexClick:this.onAddIndexClick,onDropIndexClick:this.onDropIndexClick,onReorderClick:this.onReorderClick,readonly:w}}},{key:"itemTitle",get:function(){var t=this.props.schema;return t.items.title||t.items.description||"Item"}}],i=[{key:"getDerivedStateFromProps",value:function(t,e){if(e.updatedKeyedFormData)return{updatedKeyedFormData:!1};var r=t.formData||[],n=e.keyedFormData||[];return{keyedFormData:r.length===n.length?n.map((function(t,e){return{key:t.key,item:r[e]}})):B(r)}}}],n&&D(r.prototype,n),i&&D(r,i),e}(i.Component);F(q,"defaultProps",{uiSchema:{},formData:[],idSchema:{},required:!1,disabled:!1,readonly:!1,autofocus:!1});const K=q;function W(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){H(t,e,r[e])}))}return t}function H(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Y(t){var e,r=t.schema,n=t.name,i=t.uiSchema,o=t.idSchema,a=t.formData,l=t.registry,c=void 0===l?br():l,u=t.required,h=t.disabled,d=t.readonly,f=t.autofocus,p=t.onChange,m=t.onFocus,g=t.onBlur,y=t.rawErrors,v=r.title,_=c.widgets,b=c.formContext,w=c.fields,x=Tr(i),E=x.widget,S=void 0===E?"checkbox":E,A=function(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}(x,["widget"]),P=xr(r,S,_);return e=Array.isArray(r.oneOf)?$r({oneOf:r.oneOf.map((function(t){return W({},t,{title:t.title||(!0===t.const?"Yes":"No")})}))}):$r({enum:r.enum||[!0,!1],enumNames:r.enumNames||(r.enum&&!1===r.enum[0]?["No","Yes"]:["Yes","No"])}),s().createElement(P,{options:W({},A,{enumOptions:e}),schema:r,uiSchema:i,id:o&&o.$id,onChange:p,onFocus:m,onBlur:g,label:void 0===v?n:v,value:a,required:u,disabled:h,readonly:d,registry:c,formContext:b,autofocus:f,rawErrors:y,DescriptionField:w.DescriptionField})}Y.defaultProps={uiSchema:{},disabled:!1,readonly:!1,autofocus:!1};const X=Y;function Z(t){return Z="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Z(t)}function J(){return J=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},J.apply(this,arguments)}function Q(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function tt(t){return tt=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},tt(t)}function et(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function rt(t,e){return rt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},rt(t,e)}var nt=function(t){function e(t){var r,n,i,s;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),r=function(t,e){return!e||"object"!==Z(e)&&"function"!=typeof e?et(t):e}(this,tt(e).call(this,t)),s=function(t){var e=parseInt(t,10),n=r.props,i=n.formData,s=n.onChange,o=n.options,a=n.registry.rootSchema,l=Kr(o[e],a,i),c=void 0;if("object"===Ur(i)&&("object"===l.type||l.properties)){c=Object.assign({},i);var u=o.slice();u.splice(e,1);var h=!0,d=!1,f=void 0;try{for(var p,m=u[Symbol.iterator]();!(h=(p=m.next()).done);h=!0){var g=p.value;if(g.properties)for(var y in g.properties)c.hasOwnProperty(y)&&delete c[y]}}catch(t){d=!0,f=t}finally{try{h||null==m.return||m.return()}finally{if(d)throw f}}}s(Ar(o[e],c,a)),r.setState({selectedOption:parseInt(t,10)})},(i="onOptionChange")in(n=et(r))?Object.defineProperty(n,i,{value:s,enumerable:!0,configurable:!0,writable:!0}):n[i]=s;var o=r.props,a=o.formData,l=o.options;return r.state={selectedOption:r.getMatchingOption(a,l)},r}var r,n;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&rt(t,e)}(e,t),r=e,n=[{key:"componentDidUpdate",value:function(t,e){if(!Jr(this.props.formData,t.formData)&&this.props.idSchema.$id===t.idSchema.$id){var r=this.getMatchingOption(this.props.formData,this.props.options);if(!e||r===this.state.selectedOption)return;this.setState({selectedOption:r})}}},{key:"getMatchingOption",value:function(t,e){var r=un(t,e,this.props.registry.rootSchema);return 0!==r?r:this&&this.state?this.state.selectedOption:0}},{key:"render",value:function(){var t,e=this.props,r=e.baseType,n=e.disabled,i=e.errorSchema,o=e.formData,a=e.idPrefix,l=e.idSchema,c=e.onBlur,u=e.onChange,h=e.onFocus,d=e.options,f=e.registry,p=e.uiSchema,m=e.schema,g=f.fields.SchemaField,y=f.widgets,v=this.state.selectedOption,_=Tr(p),b=_.widget,w=void 0===b?"select":b,x=function(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}(_,["widget"]),E=xr({type:"number"},w,y),S=d[v]||null;S&&(t=S.type?S:Object.assign({},S,{type:r}));var A=d.map((function(t,e){return{label:t.title||"Option ".concat(e+1),value:e}}));return s().createElement("div",{className:"panel panel-default panel-body"},s().createElement("div",{className:"form-group"},s().createElement(E,J({id:"".concat(l.$id).concat(m.oneOf?"__oneof_select":"__anyof_select"),schema:{type:"number",default:0},onChange:this.onOptionChange,onBlur:c,onFocus:h,value:v,options:{enumOptions:A}},x))),null!==S&&s().createElement(g,{schema:t,uiSchema:p,errorSchema:i,idSchema:l,idPrefix:a,formData:o,onChange:u,onBlur:c,onFocus:h,registry:f,disabled:n}))}}],n&&Q(r.prototype,n),e}(i.Component);nt.defaultProps={disabled:!1,errorSchema:{},idSchema:{},uiSchema:{}};const it=nt;function st(t){return st="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},st(t)}function ot(){return ot=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},ot.apply(this,arguments)}function at(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function lt(t){return lt=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},lt(t)}function ct(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function ut(t,e){return ut=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},ut(t,e)}var ht=/\.([0-9]*0)*$/,dt=/[0.]0*$/,ft=function(t){function e(t){var r,n,i,s;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),r=function(t,e){return!e||"object"!==st(e)&&"function"!=typeof e?ct(t):e}(this,lt(e).call(this,t)),s=function(t){r.setState({lastValue:t}),"."==="".concat(t).charAt(0)&&(t="0".concat(t));var e="string"==typeof t&&t.match(ht)?Rr(t.replace(dt,"")):Rr(t);r.props.onChange(e)},(i="handleChange")in(n=ct(r))?Object.defineProperty(n,i,{value:s,enumerable:!0,configurable:!0,writable:!0}):n[i]=s,r.state={lastValue:t.value},r}var r,n;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&ut(t,e)}(e,t),r=e,n=[{key:"render",value:function(){var t=this.props.registry.fields.StringField,e=this.props,r=e.formData,n=function(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}(e,["formData"]),i=this.state.lastValue,o=r;if("string"==typeof i&&"number"==typeof o){var a=new RegExp("".concat(o).replace(".","\\.")+"\\.?0*$");i.match(a)&&(o=i)}return s().createElement(t,ot({},n,{formData:o,onChange:this.handleChange}))}}],n&&at(r.prototype,n),e}(s().Component);ft.defaultProps={uiSchema:{}};const pt=ft;function mt(t){return mt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mt(t)}function gt(){return gt=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},gt.apply(this,arguments)}function yt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){xt(t,e,r[e])}))}return t}function vt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function _t(t){return _t=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},_t(t)}function bt(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function wt(t,e){return wt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},wt(t,e)}function xt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function Et(t){var e=t.TitleField,r=t.DescriptionField;return s().createElement("fieldset",{id:t.idSchema.$id},(t.uiSchema["ui:title"]||t.title)&&s().createElement(e,{id:"".concat(t.idSchema.$id,"__title"),title:t.title||t.uiSchema["ui:title"],required:t.required,formContext:t.formContext}),t.description&&s().createElement(r,{id:"".concat(t.idSchema.$id,"__description"),description:t.description,formContext:t.formContext}),t.properties.map((function(t){return t.content})),_r(t.schema,t.uiSchema,t.formData)&&s().createElement(x,{className:"object-property-expand",onClick:t.onAddClick(t.schema),disabled:t.disabled||t.readonly}))}var St=function(t){function e(){var t,r;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);for(var n=arguments.length,i=new Array(n),s=0;s<n;s++)i[s]=arguments[s];return r=function(t,e){return!e||"object"!==mt(e)&&"function"!=typeof e?bt(t):e}(this,(t=_t(e)).call.apply(t,[this].concat(i))),xt(bt(r),"state",{wasPropertyKeyModified:!1,additionalProperties:{}}),xt(bt(r),"onPropertyChange",(function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return function(n,i){void 0===n&&e&&(n="");var s=yt({},r.props.formData,xt({},t,n));r.props.onChange(s,i&&r.props.errorSchema&&yt({},r.props.errorSchema,xt({},t,i)))}})),xt(bt(r),"onDropPropertyClick",(function(t){return function(e){e.preventDefault();var n=r.props,i=n.onChange,s=yt({},n.formData);delete s[t],i(s)}})),xt(bt(r),"getAvailableKey",(function(t,e){for(var r=0,n=t;e.hasOwnProperty(n);)n="".concat(t,"-").concat(++r);return n})),xt(bt(r),"onKeyChange",(function(t){return function(e,n){if(t!==e){e=r.getAvailableKey(e,r.props.formData);var i=yt({},r.props.formData),s=xt({},t,e),o=Object.keys(i).map((function(t){return xt({},s[t]||t,i[t])})),a=Object.assign.apply(Object,[{}].concat(function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}(l=o)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(l)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()));r.setState({wasPropertyKeyModified:!0}),r.props.onChange(a,n&&r.props.errorSchema&&yt({},r.props.errorSchema,xt({},e,n)))}var l}})),xt(bt(r),"handleAddClick",(function(t){return function(){var e=t.additionalProperties.type,n=yt({},r.props.formData);if(t.additionalProperties.hasOwnProperty("$ref")){var i=r.props.registry,s=void 0===i?br():i;e=Kr({$ref:t.additionalProperties.$ref},s.rootSchema,r.props.formData).type}n[r.getAvailableKey("newKey",n)]=r.getDefaultValue(e),r.props.onChange(n)}})),r}var r,n;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&wt(t,e)}(e,t),r=e,n=[{key:"isRequired",value:function(t){var e=this.props.schema;return Array.isArray(e.required)&&-1!==e.required.indexOf(t)}},{key:"getDefaultValue",value:function(t){switch(t){case"string":default:return"New Value";case"array":return[];case"boolean":return!1;case"null":return null;case"number":return 0;case"object":return{}}}},{key:"render",value:function(){var t,e=this,r=this.props,n=r.uiSchema,i=r.formData,o=r.errorSchema,a=r.idSchema,l=r.name,c=r.required,u=r.disabled,h=r.readonly,d=r.idPrefix,f=r.onBlur,p=r.onFocus,m=r.registry,g=void 0===m?br():m,y=g.rootSchema,v=g.fields,_=g.formContext,b=v.SchemaField,w=v.TitleField,x=v.DescriptionField,E=Kr(this.props.schema,y,i),S=void 0===E.title?l:E.title,A=n["ui:description"]||E.description;try{t=Dr(Object.keys(E.properties||{}),n["ui:order"])}catch(t){return s().createElement("div",null,s().createElement("p",{className:"config-error",style:{color:"red"}},"Invalid ",l||"root"," object field configuration:",s().createElement("em",null,t.message),"."),s().createElement("pre",null,JSON.stringify(E)))}var P=n["ui:ObjectFieldTemplate"]||g.ObjectFieldTemplate||Et,T={title:n["ui:title"]||S,description:A,TitleField:w,DescriptionField:x,properties:t.map((function(t){var r=E.properties[t].hasOwnProperty(yr),l=r?n.additionalProperties:n[t],m=l&&"hidden"===l["ui:widget"];return{content:s().createElement(b,{key:t,name:t,required:e.isRequired(t),schema:E.properties[t],uiSchema:l,errorSchema:o[t],idSchema:a[t],idPrefix:d,formData:(i||{})[t],wasPropertyKeyModified:e.state.wasPropertyKeyModified,onKeyChange:e.onKeyChange(t),onChange:e.onPropertyChange(t,r),onBlur:f,onFocus:p,registry:g,disabled:u,readonly:h,onDropPropertyClick:e.onDropPropertyClick}),name:t,readonly:h,disabled:u,required:c,hidden:m}})),readonly:h,disabled:u,required:c,idSchema:a,uiSchema:n,schema:E,formData:i,formContext:_,registry:g};return s().createElement(P,gt({},T,{onAddClick:this.handleAddClick}))}}],n&&vt(r.prototype,n),e}(i.Component);xt(St,"defaultProps",{uiSchema:{},formData:{},errorSchema:{},idSchema:{},required:!1,disabled:!1,readonly:!1});const At=St;function Pt(t){return Pt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Pt(t)}function Tt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function Ct(t){return Ct=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Ct(t)}function Mt(t,e){return Mt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},Mt(t,e)}function Ot(){return Ot=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Ot.apply(this,arguments)}function Rt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){Dt(t,e,r[e])}))}return t}function Dt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var It={array:"ArrayField",boolean:"BooleanField",integer:"NumberField",number:"NumberField",object:"ObjectField",string:"StringField",null:"NullField"};function kt(t){var e=t.label,r=t.required,n=t.id;return e?s().createElement("label",{className:"control-label",htmlFor:n},e,r&&s().createElement("span",{className:"required"},"*")):null}function Lt(t){var e=t.id,r=t.label,n=t.onChange;return s().createElement("input",{className:"form-control",type:"text",id:e,onBlur:function(t){return n(t.target.value)},defaultValue:r})}function Ft(t){var e=t.id,r=t.help;return r?"string"==typeof r?s().createElement("p",{id:e,className:"help-block"},r):s().createElement("div",{id:e,className:"help-block"},r):null}function jt(t){var e=t.errors,r=void 0===e?[]:e;return 0===r.length?null:s().createElement("div",null,s().createElement("ul",{className:"error-detail bs-callout bs-callout-info"},r.filter((function(t){return!!t})).map((function(t,e){return s().createElement("li",{className:"text-danger",key:e},t)}))))}function Nt(t){var e=t.id,r=t.label,n=t.children,i=t.errors,o=t.help,a=t.description,l=t.hidden,c=t.required,u=t.displayLabel;return l?s().createElement("div",{className:"hidden"},n):s().createElement(Gt,t,u&&s().createElement(kt,{label:r,required:c,id:e}),u&&a?a:null,n,i,o)}function Gt(t){var e=t.id,r=t.classNames,n=t.disabled,i=t.label,o=t.onKeyChange,a=t.onDropPropertyClick,l=t.readonly,c=t.required,u=t.schema,h="".concat(i," Key");return u.hasOwnProperty(yr)?s().createElement("div",{className:r},s().createElement("div",{className:"row"},s().createElement("div",{className:"col-xs-5 form-additional"},s().createElement("div",{className:"form-group"},s().createElement(kt,{label:h,required:c,id:"".concat(e,"-key")}),s().createElement(Lt,{label:i,required:c,id:"".concat(e,"-key"),onChange:o}))),s().createElement("div",{className:"form-additional form-group col-xs-5"},t.children),s().createElement("div",{className:"col-xs-2"},s().createElement(w,{type:"danger",icon:"remove",className:"array-item-remove btn-block",tabIndex:"-1",style:{border:"0"},disabled:n||l,onClick:a(i)})))):s().createElement("div",{className:r},t.children)}function $t(t){var e=t.uiSchema,r=t.formData,n=t.errorSchema,i=t.idPrefix,o=t.name,a=t.onChange,l=t.onKeyChange,c=t.onDropPropertyClick,u=t.required,h=t.registry,d=void 0===h?br():h,f=t.wasPropertyKeyModified,p=void 0!==f&&f,m=d.rootSchema,g=d.fields,y=d.formContext,v=e["ui:FieldTemplate"]||d.FieldTemplate||Nt,_=t.idSchema,b=Kr(t.schema,m,r),w=function(t,e,r,n){var i=e["ui:field"];if("function"==typeof i)return i;if("string"==typeof i&&i in n)return n[i];var o=It[wr(t)];return o||!t.anyOf&&!t.oneOf?o in n?n[o]:function(){var e=n.UnsupportedField;return s().createElement(e,{schema:t,idSchema:r,reason:"Unknown field type ".concat(t.type)})}:function(){return null}}(b,e,_=Or(tn(b,null,m,r,i),_),g),x=g.DescriptionField,E=Boolean(t.disabled||e["ui:disabled"]),S=Boolean(t.readonly||e["ui:readonly"]||t.schema.readOnly||b.readOnly),A=Boolean(t.autofocus||e["ui:autofocus"]);if(0===Object.keys(b).length)return null;var P,T=Cr(b,e,m),C=n.__errors,M=function(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}(n,["__errors"]),O=s().createElement(w,Ot({},t,{idSchema:_,schema:b,uiSchema:Rt({},e,{classNames:void 0}),disabled:E,readonly:S,autofocus:A,errorSchema:M,formContext:y,rawErrors:C})),R=_.$id;P=p?o:e["ui:title"]||t.schema.title||b.title||o;var D=e["ui:description"]||t.schema.description||b.description,I=C,k=e["ui:help"],L="hidden"===e["ui:widget"],F=["form-group","field","field-".concat(b.type),I&&I.length>0?"field-error has-error has-danger":"",e.classNames].join(" ").trim(),j={description:s().createElement(x,{id:R+"__description",description:D,formContext:y}),rawDescription:D,help:s().createElement(Ft,{id:R+"__help",help:k}),rawHelp:"string"==typeof k?k:void 0,errors:s().createElement(jt,{errors:I}),rawErrors:I,id:R,label:P,hidden:L,onChange:a,onKeyChange:l,onDropPropertyClick:c,required:u,disabled:E,readonly:S,displayLabel:T,classNames:F,formContext:y,formData:r,fields:g,schema:b,uiSchema:e,registry:d},N=d.fields.AnyOfField,G=d.fields.OneOfField;return s().createElement(v,j,s().createElement(s().Fragment,null,O,b.anyOf&&!Lr(b)&&s().createElement(N,{disabled:E,errorSchema:n,formData:r,idPrefix:i,idSchema:_,onBlur:t.onBlur,onChange:t.onChange,onFocus:t.onFocus,options:b.anyOf.map((function(t){return Kr(t,m,r)})),baseType:b.type,registry:d,schema:b,uiSchema:e}),b.oneOf&&!Lr(b)&&s().createElement(G,{disabled:E,errorSchema:n,formData:r,idPrefix:i,idSchema:_,onBlur:t.onBlur,onChange:t.onChange,onFocus:t.onFocus,options:b.oneOf.map((function(t){return Kr(t,m,r)})),baseType:b.type,registry:d,schema:b,uiSchema:e})))}Nt.defaultProps={hidden:!1,readonly:!1,required:!1,displayLabel:!0};var zt=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){return!e||"object"!==Pt(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}(this,Ct(e).apply(this,arguments))}var r,n;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Mt(t,e)}(e,t),r=e,(n=[{key:"shouldComponentUpdate",value:function(t,e){return!Jr(this.props,t)}},{key:"render",value:function(){return $t(this.props)}}])&&Tt(r.prototype,n),e}(s().Component);zt.defaultProps={uiSchema:{},errorSchema:{},idSchema:{},disabled:!1,readonly:!1,autofocus:!1};const Ut=zt;function Bt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){Vt(t,e,r[e])}))}return t}function Vt(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function qt(t){var e=t.schema,r=t.name,n=t.uiSchema,i=t.idSchema,o=t.formData,a=t.required,l=t.disabled,c=t.readonly,u=t.autofocus,h=t.onChange,d=t.onBlur,f=t.onFocus,p=t.registry,m=void 0===p?br():p,g=t.rawErrors,y=e.title,v=e.format,_=m.widgets,b=m.formContext,w=Lr(e)&&$r(e),x=w?"select":"text";v&&Er(e,v,_)&&(x=v);var E=Tr(n),S=E.widget,A=void 0===S?x:S,P=E.placeholder,T=void 0===P?"":P,C=function(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}(E,["widget","placeholder"]),M=xr(e,A,_);return s().createElement(M,{options:Bt({},C,{enumOptions:w}),schema:e,uiSchema:n,id:i&&i.$id,label:void 0===y?r:y,value:o,onChange:h,onBlur:d,onFocus:f,required:a,disabled:l,readonly:c,formContext:b,autofocus:u,registry:m,placeholder:T,rawErrors:g})}function Kt(t){return Kt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Kt(t)}function Wt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function Ht(t){return Ht=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Ht(t)}function Yt(t,e){return Yt=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},Yt(t,e)}qt.defaultProps={uiSchema:{},disabled:!1,readonly:!1,autofocus:!1};const Xt={AnyOfField:it,ArrayField:K,BooleanField:X,DescriptionField:function(t){var e=t.id,r=t.description;return r?"string"==typeof r?s().createElement("p",{id:e,className:"field-description"},r):s().createElement("div",{id:e,className:"field-description"},r):null},NumberField:pt,ObjectField:At,OneOfField:it,SchemaField:Ut,StringField:qt,TitleField:function(t){var e=t.id,r=t.title,n=t.required;return s().createElement("legend",{id:e},r,n&&s().createElement("span",{className:"required"},"*"))},NullField:function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){return!e||"object"!==Kt(e)&&"function"!=typeof e?function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t):e}(this,Ht(e).apply(this,arguments))}var r,n;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Yt(t,e)}(e,t),r=e,(n=[{key:"componentDidMount",value:function(){void 0===this.props.formData&&this.props.onChange(null)}},{key:"render",value:function(){return null}}])&&Wt(r.prototype,n),e}(i.Component),UnsupportedField:function(t){var e=t.schema,r=t.idSchema,n=t.reason;return s().createElement("div",{className:"unsupported-field"},s().createElement("p",null,"Unsupported field schema",r&&r.$id&&s().createElement("span",null," for"," field ",s().createElement("code",null,r.$id)),n&&s().createElement("em",null,": ",n),"."),e&&s().createElement("pre",null,JSON.stringify(e,null,2)))}};function Zt(t){return Zt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zt(t)}function Jt(){return Jt=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Jt.apply(this,arguments)}function Qt(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function te(t){return te=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},te(t)}function ee(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function re(t,e){return re=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},re(t,e)}function ne(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function ie(t,e){for(var r=[],n=t;n<=e;n++)r.push({value:n,label:an(n,2)});return r}function se(t){var e=t.type,r=t.range,n=t.value,i=t.select,o=t.rootId,a=t.disabled,l=t.readonly,c=t.autofocus,u=t.registry,h=t.onBlur,d=o+"_"+e,f=u.widgets.SelectWidget;return s().createElement(f,{schema:{type:"integer"},id:d,className:"form-control",options:{enumOptions:ie(r[0],r[1])},placeholder:e,value:n,disabled:a,readonly:l,autofocus:c,onChange:function(t){return i(e,t)},onBlur:h})}var oe=function(t){function e(t){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),r=function(t,e){return!e||"object"!==Zt(e)&&"function"!=typeof e?ee(t):e}(this,te(e).call(this,t)),ne(ee(r),"onChange",(function(t,e){r.setState(ne({},t,void 0===e?-1:e),(function(){var t;t=r.state,Object.keys(t).every((function(e){return-1!==t[e]}))&&r.props.onChange(nn(r.state,r.props.time))}))})),ne(ee(r),"setNow",(function(t){t.preventDefault();var e=r.props,n=e.time,i=e.disabled,s=e.readonly,o=e.onChange;if(!i&&!s){var a=rn((new Date).toJSON(),n);r.setState(a,(function(){return o(nn(r.state,n))}))}})),ne(ee(r),"clear",(function(t){t.preventDefault();var e=r.props,n=e.time,i=e.disabled,s=e.readonly,o=e.onChange;i||s||r.setState(rn("",n),(function(){return o(void 0)}))})),r.state=rn(t.value,t.time),r}var r,n;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&re(t,e)}(e,t),r=e,n=[{key:"componentDidUpdate",value:function(t,e){t.value&&t.value!==rn(this.props.value,this.props.time)&&this.setState(rn(this.props.value,this.props.time))}},{key:"shouldComponentUpdate",value:function(t,e){return Qr(this,t,e)}},{key:"render",value:function(){var t=this,e=this.props,r=e.id,n=e.disabled,i=e.readonly,o=e.autofocus,a=e.registry,l=e.onBlur,c=e.options;return s().createElement("ul",{className:"list-inline"},this.dateElementProps.map((function(e,c){return s().createElement("li",{key:c},s().createElement(se,Jt({rootId:r,select:t.onChange},e,{disabled:n,readonly:i,registry:a,onBlur:l,autofocus:o&&0===c})))})),("undefined"===c.hideNowButton||!c.hideNowButton)&&s().createElement("li",null,s().createElement("a",{href:"#",className:"btn btn-info btn-now",onClick:this.setNow},"Now")),("undefined"===c.hideClearButton||!c.hideClearButton)&&s().createElement("li",null,s().createElement("a",{href:"#",className:"btn btn-warning btn-clear",onClick:this.clear},"Clear")))}},{key:"dateElementProps",get:function(){var t=this.props,e=t.time,r=t.options,n=this.state,i=n.year,s=n.month,o=n.day,a=n.hour,l=n.minute,c=n.second,u=[{type:"year",range:r.yearsRange,value:i},{type:"month",range:[1,12],value:s},{type:"day",range:[1,31],value:o}];return e&&u.push({type:"hour",range:[0,23],value:a},{type:"minute",range:[0,59],value:l},{type:"second",range:[0,59],value:c}),u}}],n&&Qt(r.prototype,n),e}(i.Component);ne(oe,"defaultProps",{time:!1,disabled:!1,readonly:!1,autofocus:!1,options:{yearsRange:[1900,(new Date).getFullYear()+2]}});const ae=oe;function le(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function ce(){return ce=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},ce.apply(this,arguments)}function ue(t){var e=t.registry.widgets.AltDateWidget;return s().createElement(e,ce({time:!0},t))}ue.defaultProps=function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){le(t,e,r[e])}))}return t}({},ae.defaultProps,{time:!0});const he=ue;function de(){return de=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},de.apply(this,arguments)}function fe(t){if(!t.id)throw console.log("No id for",t),new Error("no id for props ".concat(JSON.stringify(t)));var e,r=t.value,n=t.readonly,i=t.disabled,o=t.autofocus,a=t.onBlur,l=t.onFocus,c=t.options,u=t.schema,h=(t.uiSchema,t.formContext,t.registry,t.rawErrors,function(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}(t,["value","readonly","disabled","autofocus","onBlur","onFocus","options","schema","uiSchema","formContext","registry","rawErrors"]));return c.inputType?h.type=c.inputType:h.type||("number"===u.type?(h.type="number",h.step="any"):"integer"===u.type?(h.type="number",h.step="1"):h.type="text"),c.autocomplete&&(h.autoComplete=c.autocomplete),u.multipleOf&&(h.step=u.multipleOf),void 0!==u.minimum&&(h.min=u.minimum),void 0!==u.maximum&&(h.max=u.maximum),[s().createElement("input",de({key:h.id,className:"form-control",readOnly:n,disabled:i,autoFocus:o,value:null==r?"":r},h,{list:u.examples?"examples_".concat(h.id):null,onChange:function(e){var r=e.target.value;return t.onChange(""===r?c.emptyValue:r)},onBlur:a&&function(t){return a(h.id,t.target.value)},onFocus:l&&function(t){return l(h.id,t.target.value)}})),u.examples?s().createElement("datalist",{key:"datalist_".concat(h.id),id:"examples_".concat(h.id)},(e=new Set(u.examples.concat(u.default?[u.default]:[])),function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}(e)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()).map((function(t){return s().createElement("option",{key:t,value:t})}))):null]}fe.defaultProps={required:!1,disabled:!1,readonly:!1,autofocus:!1};const pe=fe;function me(t){var e=t.schema,r=t.id,n=t.value,i=t.disabled,o=t.readonly,a=t.label,l=t.autofocus,c=t.onBlur,u=t.onFocus,h=t.onChange,d=t.DescriptionField,f=hn(e);return s().createElement("div",{className:"checkbox ".concat(i||o?"disabled":"")},e.description&&s().createElement(d,{description:e.description}),s().createElement("label",null,s().createElement("input",{type:"checkbox",id:r,checked:void 0!==n&&n,required:f,disabled:i||o,autoFocus:l,onChange:function(t){return h(t.target.checked)},onBlur:c&&function(t){return c(r,t.target.checked)},onFocus:u&&function(t){return u(r,t.target.checked)}}),s().createElement("span",null,a)))}me.defaultProps={autofocus:!1};const ge=me;function ye(t){var e=t.id,r=t.disabled,n=t.options,i=t.value,o=t.autofocus,a=t.readonly,l=t.onChange,c=n.enumOptions,u=n.enumDisabled,h=n.inline;return s().createElement("div",{className:"checkboxes",id:e},c.map((function(t,n){var d=-1!==i.indexOf(t.value),f=u&&-1!=u.indexOf(t.value),p=r||f||a?"disabled":"",m=s().createElement("span",null,s().createElement("input",{type:"checkbox",id:"".concat(e,"_").concat(n),checked:d,disabled:r||f||a,autoFocus:o&&0===n,onChange:function(e){var r=c.map((function(t){return t.value}));e.target.checked?l(function(t,e,r){var n=r.indexOf(t);return e.slice(0,n).concat(t,e.slice(n)).sort((function(t,e){return r.indexOf(t)>r.indexOf(e)}))}(t.value,i,r)):l(function(t,e){return e.filter((function(e){return e!==t}))}(t.value,i))}}),s().createElement("span",null,t.label));return h?s().createElement("label",{key:n,className:"checkbox-inline ".concat(p)},m):s().createElement("div",{key:n,className:"checkbox ".concat(p)},s().createElement("label",null,m))})))}ye.defaultProps={autofocus:!1,options:{inline:!1}};const ve=ye;function _e(){return _e=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},_e.apply(this,arguments)}function be(){return be=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},be.apply(this,arguments)}function we(){return we=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},we.apply(this,arguments)}function xe(){return xe=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},xe.apply(this,arguments)}function Ee(t){return Ee="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ee(t)}function Se(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function Ae(t){return Ae=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},Ae(t)}function Pe(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Te(t,e){return Te=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},Te(t,e)}function Ce(t,e){return t.replace(";base64",";name=".concat(encodeURIComponent(e),";base64"))}function Me(t){var e=t.name,r=t.size,n=t.type;return new Promise((function(i,s){var o=new window.FileReader;o.onerror=s,o.onload=function(t){i({dataURL:Ce(t.target.result,e),name:e,size:r,type:n})},o.readAsDataURL(t)}))}function Oe(t){var e=t.filesInfo;return 0===e.length?null:s().createElement("ul",{className:"file-info"},e.map((function(t,e){var r=t.name,n=t.size,i=t.type;return s().createElement("li",{key:e},s().createElement("strong",null,r)," (",i,", ",n," bytes)")})))}var Re=function(t){function e(t){var r;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),r=function(t,e){return!e||"object"!==Ee(e)&&"function"!=typeof e?Pe(t):e}(this,Ae(e).call(this,t)),function(t,e,r){e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r}(Pe(r),"onChange",(function(t){var e,n=r.props,i=n.multiple,s=n.onChange;(e=t.target.files,Promise.all([].map.call(e,Me))).then((function(t){var e={values:t.map((function(t){return t.dataURL})),filesInfo:t};r.setState(e,(function(){s(i?e.values:e.values[0])}))}))}));var n,i=t.value,s=Array.isArray(i)?i:[i];return r.state={values:s,filesInfo:(n=s,n.filter((function(t){return void 0!==t})).map((function(t){var e=ln(t),r=e.blob;return{name:e.name,size:r.size,type:r.type}})))},r}var r,n;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Te(t,e)}(e,t),r=e,(n=[{key:"shouldComponentUpdate",value:function(t,e){return Qr(this,t,e)}},{key:"render",value:function(){var t=this,e=this.props,r=e.multiple,n=e.id,i=e.readonly,o=e.disabled,a=e.autofocus,l=e.options,c=this.state.filesInfo;return s().createElement("div",null,s().createElement("p",null,s().createElement("input",{ref:function(e){return t.inputRef=e},id:n,type:"file",disabled:i||o,onChange:this.onChange,defaultValue:"",autoFocus:a,multiple:r,accept:l.accept})),s().createElement(Oe,{filesInfo:c}))}}])&&Se(r.prototype,n),e}(i.Component);Re.defaultProps={autofocus:!1};const De=Re;function Ie(){return Ie=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Ie.apply(this,arguments)}function ke(t){var e=t.options,r=t.value,n=t.required,i=t.disabled,o=t.readonly,a=t.autofocus,l=t.onBlur,c=t.onFocus,u=t.onChange,h=t.id,d=Math.random().toString(),f=e.enumOptions,p=e.enumDisabled,m=e.inline;return s().createElement("div",{className:"field-radio-group",id:h},f.map((function(t,e){var f=t.value===r,g=p&&-1!=p.indexOf(t.value),y=i||g||o?"disabled":"",v=s().createElement("span",null,s().createElement("input",{type:"radio",checked:f,name:d,required:n,value:t.value,disabled:i||g||o,autoFocus:a&&0===e,onChange:function(e){return u(t.value)},onBlur:l&&function(t){return l(h,t.target.value)},onFocus:c&&function(t){return c(h,t.target.value)}}),s().createElement("span",null,t.label));return m?s().createElement("label",{key:e,className:"radio-inline ".concat(y)},v):s().createElement("div",{key:e,className:"radio ".concat(y)},s().createElement("label",null,v))})))}ke.defaultProps={autofocus:!1};const Le=ke;function Fe(){return Fe=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Fe.apply(this,arguments)}var je=new Set(["number","integer"]);function Ne(t,e){var r=t.type,n=t.items;if(""!==e){if("array"===r&&n&&je.has(n.type))return e.map(Rr);if("boolean"===r)return"true"===e;if("number"===r)return Rr(e);if(t.enum){if(t.enum.every((function(t){return"number"===Ur(t)})))return Rr(e);if(t.enum.every((function(t){return"boolean"===Ur(t)})))return"true"===e}return e}}function Ge(t,e){return e?[].slice.call(t.target.options).filter((function(t){return t.selected})).map((function(t){return t.value})):t.target.value}function $e(t){var e=t.schema,r=t.id,n=t.options,i=t.value,o=t.required,a=t.disabled,l=t.readonly,c=t.multiple,u=t.autofocus,h=t.onChange,d=t.onBlur,f=t.onFocus,p=t.placeholder,m=n.enumOptions,g=n.enumDisabled,y=c?[]:"";return s().createElement("select",{id:r,multiple:c,className:"form-control",value:void 0===i?y:i,required:o,disabled:a||l,autoFocus:u,onBlur:d&&function(t){var n=Ge(t,c);d(r,Ne(e,n))},onFocus:f&&function(t){var n=Ge(t,c);f(r,Ne(e,n))},onChange:function(t){var r=Ge(t,c);h(Ne(e,r))}},!c&&void 0===e.default&&s().createElement("option",{value:""},p),m.map((function(t,e){var r=t.value,n=t.label,i=g&&-1!=g.indexOf(r);return s().createElement("option",{key:e,value:r,disabled:i},n)})))}$e.defaultProps={autofocus:!1};const ze=$e;function Ue(t){var e=t.id,r=t.options,n=t.placeholder,i=t.value,o=t.required,a=t.disabled,l=t.readonly,c=t.autofocus,u=t.onChange,h=t.onBlur,d=t.onFocus;return s().createElement("textarea",{id:e,className:"form-control",value:i||"",placeholder:n,required:o,disabled:a,readOnly:l,autoFocus:c,rows:r.rows,onBlur:h&&function(t){return h(e,t.target.value)},onFocus:d&&function(t){return d(e,t.target.value)},onChange:function(t){var e=t.target.value;return u(""===e?r.emptyValue:e)}})}Ue.defaultProps={autofocus:!1,options:{}};function Be(){return Be=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Be.apply(this,arguments)}function Ve(){return Ve=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Ve.apply(this,arguments)}const qe={BaseInput:pe,PasswordWidget:function(t){var e=t.registry.widgets.BaseInput;return s().createElement(e,Ie({type:"password"},t))},RadioWidget:Le,UpDownWidget:function(t){var e=t.registry.widgets.BaseInput;return s().createElement(e,Ve({type:"number"},t,cn(t.schema)))},RangeWidget:function(t){var e=t.schema,r=t.value,n=t.registry.widgets.BaseInput;return s().createElement("div",{className:"field-range-wrapper"},s().createElement(n,Fe({type:"range"},t,cn(e))),s().createElement("span",{className:"range-view"},r))},SelectWidget:ze,TextWidget:function(t){var e=t.registry.widgets.BaseInput;return s().createElement(e,t)},DateWidget:function(t){var e=t.onChange,r=t.registry.widgets.BaseInput;return s().createElement(r,be({type:"date"},t,{onChange:function(t){return e(t||void 0)}}))},DateTimeWidget:function(t){var e=t.value,r=t.onChange,n=t.registry.widgets.BaseInput;return s().createElement(n,we({type:"datetime-local"},t,{value:sn(e),onChange:function(t){return r(on(t))}}))},AltDateWidget:ae,AltDateTimeWidget:he,EmailWidget:function(t){var e=t.registry.widgets.BaseInput;return s().createElement(e,xe({type:"email"},t))},URLWidget:function(t){var e=t.registry.widgets.BaseInput;return s().createElement(e,Be({type:"url"},t))},TextareaWidget:Ue,HiddenWidget:function(t){var e=t.id,r=t.value;return s().createElement("input",{type:"hidden",id:e,value:void 0===r?"":r})},ColorWidget:function(t){var e=t.disabled,r=t.readonly,n=t.registry.widgets.BaseInput;return s().createElement(n,_e({type:"color"},t,{disabled:e||r}))},FileWidget:De,CheckboxWidget:ge,CheckboxesWidget:ve};var Ke=r(42613),We=r.n(Ke),He=r(88115),Ye=r.n(He);function Xe(t){return function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function Ze(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){Je(t,e,r[e])}))}return t}function Je(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var Qe=nr(),tr=null,er=null,rr="__rjsf_rootSchema";function nr(){var t=new(Ye())({errorDataPath:"property",allErrors:!0,multipleOfPrecision:8,schemaId:"auto",unknownFormats:"ignore"});return t.addFormat("data-url",/^data:([a-z]+\/[a-z0-9-+.]+)?;(?:name=(.*);)?base64,(.*)$/),t.addFormat("color",/^(#?([0-9A-Fa-f]{3}){1,2}\b|aqua|black|blue|fuchsia|gray|green|lime|maroon|navy|olive|orange|purple|red|silver|teal|white|yellow|(rgb\(\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*\))|(rgb\(\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*\)))$/),t}function ir(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"root",r=[];return"__errors"in t&&(r=r.concat(t.__errors.map((function(t){return{stack:"".concat(e,": ").concat(t)}})))),Object.keys(t).reduce((function(e,r){return"__errors"!==r&&(e=e.concat(ir(t[r],r))),e}),r)}function sr(t){var e={__errors:[],addError:function(t){this.__errors.push(t)}};return Mr(t)?Object.keys(t).reduce((function(e,r){return Ze({},e,Je({},r,sr(t[r])))}),e):Array.isArray(t)?t.reduce((function(t,e,r){return Ze({},t,Je({},r,sr(e)))}),e):e}function or(t){return Object.keys(t).reduce((function(e,r){return"addError"===r?e:Ze({},e,Je({},r,"__errors"===r?t[r]:or(t[r])))}),{})}function ar(t,e,r,n){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[],s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{};t=Ar(e,t,e,!0);var o=!Jr(er,i),a=!Jr(tr,s);(o||a)&&(Qe=nr()),i&&o&&Array.isArray(i)&&(Qe.addMetaSchema(i),er=i),s&&a&&Mr(s)&&(Object.keys(s).forEach((function(t){Qe.addFormat(t,s[t])})),tr=s);var l=null;try{Qe.validate(e,t)}catch(t){l=t}var c=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return null===t?[]:t.map((function(t){var e=t.dataPath,r=t.keyword,n=t.message,i=t.params,s=t.schemaPath,o="".concat(e);return{name:r,property:o,message:n,params:i,stack:"".concat(o," ").concat(n).trim(),schemaPath:s}}))}(Qe.errors);Qe.errors=null;var u=l&&l.message&&"string"==typeof l.message&&l.message.includes("no schema with key or ref ");u&&(c=[].concat(Xe(c),[{stack:l.message}])),"function"==typeof n&&(c=n(c));var h=function(t){return t.length?t.reduce((function(t,e){var r=e.property,n=e.message,i=We()(r),s=t;i.length>0&&""===i[0]&&i.splice(0,1);var o=!0,a=!1,l=void 0;try{for(var c,u=i.slice(0)[Symbol.iterator]();!(o=(c=u.next()).done);o=!0){var h=c.value;h in s||(s[h]={}),s=s[h]}}catch(t){a=!0,l=t}finally{try{o||null==u.return||u.return()}finally{if(a)throw l}}return Array.isArray(s.__errors)?s.__errors=s.__errors.concat(n):n&&(s.__errors=[n]),t}),{}):{}}(c);if(u&&(h=Ze({},h,{$schema:{__errors:[l.message]}})),"function"!=typeof r)return{errors:c,errorSchema:h};var d=Or(h,or(r(t,sr(t))),!0);return{errors:ir(d),errorSchema:d}}function lr(t){var e=t;if(t.constructor===Object)for(var r in e=Ze({},t)){var n=e[r];"$ref"===r&&"string"==typeof n&&n.startsWith("#")?e[r]=rr+n:e[r]=lr(n)}else if(Array.isArray(t)){e=Xe(t);for(var i=0;i<e.length;i++)e[i]=lr(e[i])}return e}function cr(t,e,r){try{return Qe.addSchema(r,rr).validate(lr(t),e)}catch(t){return!1}finally{Qe.removeSchema(rr)}}function ur(t){var e=function(t){if("object"!==dr(t)||null===t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var r=e.call(t,"string");if("object"!==dr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"===dr(e)?e:String(e)}function hr(t){return function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function dr(t){return dr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},dr(t)}function fr(){return fr=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},fr.apply(this,arguments)}function pr(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){mr(t,e,r[e])}))}return t}function mr(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function gr(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}var yr="__additional_property",vr={boolean:{checkbox:"CheckboxWidget",radio:"RadioWidget",select:"SelectWidget",hidden:"HiddenWidget"},string:{text:"TextWidget",password:"PasswordWidget",email:"EmailWidget",hostname:"TextWidget",ipv4:"TextWidget",ipv6:"TextWidget",uri:"URLWidget","data-url":"FileWidget",radio:"RadioWidget",select:"SelectWidget",textarea:"TextareaWidget",hidden:"HiddenWidget",date:"DateWidget",datetime:"DateTimeWidget","date-time":"DateTimeWidget","alt-date":"AltDateWidget","alt-datetime":"AltDateTimeWidget",color:"ColorWidget",file:"FileWidget"},number:{text:"TextWidget",select:"SelectWidget",updown:"UpDownWidget",range:"RangeWidget",radio:"RadioWidget",hidden:"HiddenWidget"},integer:{text:"TextWidget",select:"SelectWidget",updown:"UpDownWidget",range:"RangeWidget",radio:"RadioWidget",hidden:"HiddenWidget"},array:{select:"SelectWidget",checkboxes:"CheckboxesWidget",files:"FileWidget",hidden:"HiddenWidget"}};function _r(t,e,r){if(!t.additionalProperties)return!1;var n=Tr(e).expandable;return!1===n?n:void 0===t.maxProperties||Object.keys(r).length<t.maxProperties}function br(){return{fields:Xt,widgets:qe,definitions:{},rootSchema:{},formContext:{}}}function wr(t){var e=t.type;return!e&&t.const?Ur(t.const):!e&&t.enum?"string":e||!t.properties&&!t.additionalProperties?e instanceof Array&&2===e.length&&e.includes("null")?e.find((function(t){return"null"!==t})):e:"object"}function xr(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=wr(t);if("function"==typeof e||d.isForwardRef(s().createElement(e))||d.isMemo(e))return function(t){if(!t.MergedWidget){var e=t.defaultProps&&t.defaultProps.options||{};t.MergedWidget=function(r){var n=r.options,i=void 0===n?{}:n,o=gr(r,["options"]);return s().createElement(t,fr({options:pr({},e,i)},o))}}return t.MergedWidget}(e);if("string"!=typeof e)throw new Error("Unsupported widget definition: ".concat(dr(e)));if(r.hasOwnProperty(e))return xr(t,r[e],r);if(!vr.hasOwnProperty(n))throw new Error('No widget for type "'.concat(n,'"'));if(vr[n].hasOwnProperty(e))return xr(t,r[vr[n][e]],r);throw new Error('No widget "'.concat(e,'" for type "').concat(n,'"'))}function Er(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};try{return xr(t,e,r),!0}catch(t){if(t.message&&(t.message.startsWith("No widget")||t.message.startsWith("Unsupported widget")))return!1;throw t}}function Sr(t,e,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=arguments.length>4&&void 0!==arguments[4]&&arguments[4],s=Mr(t)?t:{},o=Mr(n)?n:{},a=e;if(Mr(a)&&Mr(s.default))a=Or(a,s.default);else if("default"in s)a=s.default;else{if("$ref"in s)return Sr(zr(s.$ref,r),a,r,o,i);if("dependencies"in s)return Sr(Wr(s,r,o),a,r,o,i);Nr(s)?a=s.items.map((function(t,n){return Sr(t,Array.isArray(e)?e[n]:void 0,r,o,i)})):"oneOf"in s?s=s.oneOf[un(void 0,s.oneOf,r)]:"anyOf"in s&&(s=s.anyOf[un(void 0,s.anyOf,r)])}switch(void 0===a&&(a=s.default),wr(s)){case"object":return Object.keys(s.properties||{}).reduce((function(t,e){var n=Sr(s.properties[e],(a||{})[e],r,(o||{})[e],i);return(i||void 0!==n)&&(t[e]=n),t}),{});case"array":if(Array.isArray(a)&&(a=a.map((function(t,e){return Sr(s.items[e]||s.additionalItems||{},t,r)}))),Array.isArray(n)&&(a=n.map((function(t,e){return Sr(s.items,(a||{})[e],r,t)}))),s.minItems){if(Fr(s,r))return a||[];var l=a?a.length:0;if(s.minItems>l){var c=a||[],u=Array.isArray(s.items)?s.additionalItems:s.items,h=g()(new Array(s.minItems-l),Sr(u,u.defaults,r));return c.concat(h)}}}return a}function Ar(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(!Mr(t))throw new Error("Invalid schema: "+t);var i=Sr(Kr(t,r,e),t.default,r,e,n);return void 0===e?i:Mr(e)||Array.isArray(e)?Pr(i,e):0===e||!1===e||""===e?e:e||i}function Pr(t,e){if(Array.isArray(e))return Array.isArray(t)||(t=[]),e.map((function(e,r){return t[r]?Pr(t[r],e):e}));if(Mr(e)){var r=Object.assign({},t);return Object.keys(e).reduce((function(r,n){return r[n]=Pr(t?t[n]:{},e[n]),r}),r)}return e}function Tr(t){return Object.keys(t).filter((function(t){return 0===t.indexOf("ui:")})).reduce((function(e,r){var n=t[r];return"ui:widget"===r&&Mr(n)?(console.warn("Setting options via ui:widget object is deprecated, use ui:options instead"),pr({},e,n.options||{},{widget:n.component})):"ui:options"===r&&Mr(n)?pr({},e,n):pr({},e,mr({},r.substring(3),n))}),{})}function Cr(t,e,r){var n=Tr(e).label,i=void 0===n||n,s=wr(t);return"array"===s&&(i=Fr(t,r)||jr(t,e,r)),"object"===s&&(i=!1),"boolean"!==s||e["ui:widget"]||(i=!1),e["ui:field"]&&(i=!1),i}function Mr(t){return!("undefined"!=typeof File&&t instanceof File||"object"!==dr(t)||null===t||Array.isArray(t))}function Or(t,e){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=Object.assign({},t);return Object.keys(e).reduce((function(n,i){var s=t?t[i]:{},o=e[i];return t&&t.hasOwnProperty(i)&&Mr(o)?n[i]=Or(s,o,r):r&&Array.isArray(s)&&Array.isArray(o)?n[i]=s.concat(o):n[i]=o,n}),n)}function Rr(t){if(""!==t){if(null===t)return null;if(/\.$/.test(t))return t;if(/\.0$/.test(t))return t;var e=Number(t),r="number"==typeof e&&!Number.isNaN(e);return/\.\d*0$/.test(t)?t:r?e:t}}function Dr(t,e){if(!Array.isArray(e))return t;var r,n=function(t){return t.reduce((function(t,e){return t[e]=!0,t}),{})},i=n(t),s=e.filter((function(t){return"*"===t||i[t]})),o=n(s),a=t.filter((function(t){return!o[t]})),l=s.indexOf("*");if(-1===l){if(a.length)throw new Error("uiSchema order list does not contain ".concat((r=a).length>1?"properties '".concat(r.join("', '"),"'"):"property '".concat(r[0],"'")));return s}if(l!==s.lastIndexOf("*"))throw new Error("uiSchema order list contains more than one wildcard item");var c=hr(s);return c.splice.apply(c,[l,1].concat(hr(a))),c}function Ir(t){return Array.isArray(t.enum)&&1===t.enum.length||t.hasOwnProperty("const")}function kr(t){if(Array.isArray(t.enum)&&1===t.enum.length)return t.enum[0];if(t.hasOwnProperty("const"))return t.const;throw new Error("schema cannot be inferred as a constant")}function Lr(t){var e=Kr(t,arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}),r=e.oneOf||e.anyOf;return!!Array.isArray(e.enum)||!!Array.isArray(r)&&r.every((function(t){return Ir(t)}))}function Fr(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return!(!t.uniqueItems||!t.items)&&Lr(t.items,e)}function jr(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if("files"===e["ui:widget"])return!0;if(t.items){var n=Kr(t.items,r);return"string"===n.type&&"data-url"===n.format}return!1}function Nr(t){return Array.isArray(t.items)&&t.items.length>0&&t.items.every((function(t){return Mr(t)}))}function Gr(t){return!0===t.additionalItems&&console.warn("additionalItems=true is currently not supported"),Mr(t.additionalItems)}function $r(t){return t.enum?t.enum.map((function(e,r){return{label:t.enumNames&&t.enumNames[r]||String(e),value:e}})):(t.oneOf||t.anyOf).map((function(t,e){var r=kr(t);return{schema:t,label:t.title||String(r),value:r}}))}function zr(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=t;if(!t.startsWith("#"))throw new Error("Could not find a definition for ".concat(r,"."));t=decodeURIComponent(t.substring(1));var n=_.get(e,t);if(void 0===n)throw new Error("Could not find a definition for ".concat(r,"."));return n.hasOwnProperty("$ref")?zr(n.$ref,e):n}var Ur=function(t){return Array.isArray(t)?"array":"string"==typeof t?"string":null==t?"null":"boolean"==typeof t?"boolean":isNaN(t)?"object"===dr(t)?"object":"string":"number"};function Br(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return t=pr({},t,{properties:pr({},t.properties)}),r=Mr(r)?r:{},Object.keys(r).forEach((function(n){var i;t.properties.hasOwnProperty(n)||(i=t.additionalProperties.hasOwnProperty("$ref")?Kr({$ref:t.additionalProperties.$ref},e,r):t.additionalProperties.hasOwnProperty("type")?pr({},t.additionalProperties):{type:Ur(r[n])},t.properties[n]=i,t.properties[n][yr]=!0)})),t}function Vr(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return t.hasOwnProperty("$ref")?qr(t,e,r):t.hasOwnProperty("dependencies")?Kr(Wr(t,e,r),e,r):t.hasOwnProperty("allOf")?pr({},t,{allOf:t.allOf.map((function(t){return Kr(t,e,r)}))}):t}function qr(t,e,r){var n=zr(t.$ref,e);return t.$ref,Kr(pr({},n,gr(t,["$ref"])),e,r)}function Kr(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(!Mr(t))return{};var n=Vr(t,e,r);if("allOf"in t)try{n=p()(pr({},n,{allOf:n.allOf}))}catch(t){console.warn("could not merge subschemas in allOf:\n"+t);var i=n;return i.allOf,gr(i,["allOf"])}return n.hasOwnProperty("additionalProperties")&&!1!==n.additionalProperties?Br(n,e,r):n}function Wr(t,e,r){var n=t.dependencies,i=void 0===n?{}:n,s=gr(t,["dependencies"]);return"oneOf"in s?s=s.oneOf[un(r,s.oneOf,e)]:"anyOf"in s&&(s=s.anyOf[un(r,s.anyOf,e)]),Hr(i,s,e,r)}function Hr(t,e,r,n){for(var i in t)if(void 0!==n[i]&&(!e.properties||i in e.properties)){var s=t[i],o=gr(t,[i].map(ur));return Array.isArray(s)?(a=e,e=(l=s)?pr({},a,{required:Array.isArray(a.required)?Array.from(new Set([].concat(hr(a.required),hr(l)))):l}):a):Mr(s)&&(e=Yr(e,r,n,i,s)),Hr(o,e,r,n)}var a,l;return e}function Yr(t,e,r,n,i){var s=Kr(i,e,r),o=s.oneOf;if(t=Xr(t,gr(s,["oneOf"])),void 0===o)return t;if(!Array.isArray(o))throw new Error("invalid: it is some ".concat(dr(o)," instead of an array"));var a=o.map((function(t){return t.hasOwnProperty("$ref")?qr(t,e,r):t}));return function(t,e,r,n,i){var s=i.filter((function(t){if(!t.properties)return!1;var e=t.properties[n];if(e){var i={type:"object",properties:mr({},n,e)};return 0===ar(r,i).errors.length}}));if(1!==s.length)return console.warn("ignoring oneOf in dependencies because there isn't exactly one subschema that is valid"),t;var o=s[0],a=o.properties;return Xr(t,Kr(pr({},o,{properties:(a[n],gr(a,[n].map(ur)))}),e,r))}(t,e,r,n,a)}function Xr(t,e){var r=Object.assign({},t);return Object.keys(e).reduce((function(r,n){var i=t?t[n]:{},s=e[n];return t&&t.hasOwnProperty(n)&&Mr(s)?r[n]=Xr(i,s):t&&e&&("object"===wr(t)||"object"===wr(e))&&"required"===n&&Array.isArray(i)&&Array.isArray(s)?r[n]=v()(i,s):r[n]=s,r}),r)}function Zr(t){return"[object Arguments]"===Object.prototype.toString.call(t)}function Jr(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[];if(t===e)return!0;if("function"==typeof t||"function"==typeof e)return!0;if("object"!==dr(t)||"object"!==dr(e))return!1;if(null===t||null===e)return!1;if(t instanceof Date&&e instanceof Date)return t.getTime()===e.getTime();if(t instanceof RegExp&&e instanceof RegExp)return t.source===e.source&&t.global===e.global&&t.multiline===e.multiline&&t.lastIndex===e.lastIndex&&t.ignoreCase===e.ignoreCase;if(Zr(t)||Zr(e)){if(!Zr(t)||!Zr(e))return!1;var i=Array.prototype.slice;return Jr(i.call(t),i.call(e),r,n)}if(t.constructor!==e.constructor)return!1;var s=Object.keys(t),o=Object.keys(e);if(0===s.length&&0===o.length)return!0;if(s.length!==o.length)return!1;for(var a,l=r.length;l--;)if(r[l]===t)return n[l]===e;r.push(t),n.push(e),s.sort(),o.sort();for(var c=s.length-1;c>=0;c--)if(s[c]!==o[c])return!1;for(var u=s.length-1;u>=0;u--)if(!Jr(t[a=s[u]],e[a],r,n))return!1;return r.pop(),n.pop(),!0}function Qr(t,e,r){var n=t.props,i=t.state;return!Jr(n,e)||!Jr(i,r)}function tn(t,e,r){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"root",s={$id:e||i};if("$ref"in t||"dependencies"in t||"allOf"in t)return tn(Kr(t,r,n),e,r,n,i);if("items"in t&&!t.items.$ref)return tn(t.items,e,r,n,i);if("object"!==t.type)return s;for(var o in t.properties||{}){var a=t.properties[o],l=s.$id+"_"+o;s[o]=tn(Mr(a)?a:{},l,r,(n||{})[o],i)}return s}function en(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=arguments.length>2?arguments[2]:void 0,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i={$name:e.replace(/^\./,"")};if("$ref"in t||"dependencies"in t||"allOf"in t)return en(Kr(t,r,n),e,r,n);if(t.hasOwnProperty("additionalProperties")&&(i.__rjsf_additionalProperties=!0),t.hasOwnProperty("items")&&Array.isArray(n))n.forEach((function(n,s){i[s]=en(t.items,"".concat(e,".").concat(s),r,n)}));else if(t.hasOwnProperty("properties"))for(var s in t.properties)i[s]=en(t.properties[s],"".concat(e,".").concat(s),r,(n||{})[s]);return i}function rn(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(!t)return{year:-1,month:-1,day:-1,hour:e?-1:0,minute:e?-1:0,second:e?-1:0};var r=new Date(t);if(Number.isNaN(r.getTime()))throw new Error("Unable to parse date "+t);return{year:r.getUTCFullYear(),month:r.getUTCMonth()+1,day:r.getUTCDate(),hour:e?r.getUTCHours():0,minute:e?r.getUTCMinutes():0,second:e?r.getUTCSeconds():0}}function nn(t){var e=t.year,r=t.month,n=t.day,i=t.hour,s=void 0===i?0:i,o=t.minute,a=void 0===o?0:o,l=t.second,c=void 0===l?0:l,u=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],h=Date.UTC(e,r-1,n,s,a,c),d=new Date(h).toJSON();return u?d:d.slice(0,10)}function sn(t){if(!t)return"";var e=new Date(t),r=an(e.getFullYear(),4),n=an(e.getMonth()+1,2),i=an(e.getDate(),2),s=an(e.getHours(),2),o=an(e.getMinutes(),2),a=an(e.getSeconds(),2),l=an(e.getMilliseconds(),3);return"".concat(r,"-").concat(n,"-").concat(i,"T").concat(s,":").concat(o,":").concat(a,".").concat(l)}function on(t){if(t)return new Date(t).toJSON()}function an(t,e){for(var r=String(t);r.length<e;)r="0"+r;return r}function ln(t){var e,r=t.split(","),n=r[0].split(";"),i=n[0].replace("data:",""),s=n.filter((function(t){return"name"===t.split("=")[0]}));e=1!==s.length?"unknown":s[0].split("=")[1];for(var o=atob(r[1]),a=[],l=0;l<o.length;l++)a.push(o.charCodeAt(l));return{blob:new window.Blob([new Uint8Array(a)],{type:i}),name:e}}function cn(t){var e={};return t.multipleOf&&(e.step=t.multipleOf),(t.minimum||0===t.minimum)&&(e.min=t.minimum),(t.maximum||0===t.maximum)&&(e.max=t.maximum),e}function un(t,e,r){for(var n=0;n<e.length;n++){var i=e[n];if(i.properties){var s={anyOf:Object.keys(i.properties).map((function(t){return{required:[t]}}))},o=void 0;if(i.anyOf){var a=fr({},i);a.allOf?a.allOf=a.allOf.slice():a.allOf=[],a.allOf.push(s),o=a}else o=Object.assign({},i,s);if(delete o.required,cr(o,t,r))return n}else if(cr(i,t,r))return n}return 0}function hn(t){return!!t.const||!(!t.enum||1!==t.enum.length||!0!==t.enum[0])||(t.anyOf&&1===t.anyOf.length?hn(t.anyOf[0]):t.oneOf&&1===t.oneOf.length?hn(t.oneOf[0]):!!t.allOf&&t.allOf.some(hn))}function dn(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){vn(t,e,r[e])}))}return t}function fn(t){return fn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fn(t)}function pn(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function mn(t){return mn=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},mn(t)}function gn(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function yn(t,e){return yn=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},yn(t,e)}function vn(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var _n=function(t){function e(t){var r;return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),r=function(t,e){return!e||"object"!==fn(e)&&"function"!=typeof e?gn(t):e}(this,mn(e).call(this,t)),vn(gn(r),"getUsedFormData",(function(t,e){if(0===e.length&&"object"!==fn(t))return t;var r=a()(t,e);return Array.isArray(t)?Object.keys(r).map((function(t){return r[t]})):r})),vn(gn(r),"getFieldNames",(function(t,e){return function t(r){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[""];return Object.keys(r).forEach((function(s){if("object"===fn(r[s])){var o=i.map((function(t){return"".concat(t,".").concat(s)}));r[s].__rjsf_additionalProperties&&""!==r[s].$name?n.push(r[s].$name):t(r[s],n,o)}else"$name"===s&&""!==r[s]&&i.forEach((function(t){t=t.replace(/^\./,"");var r=c()(e,t);("object"!==fn(r)||h()(r))&&n.push(t)}))})),n}(t)})),vn(gn(r),"onChange",(function(t,e){(Mr(t)||Array.isArray(t))&&(t=r.getStateFromProps(r.props,t).formData);var n=!r.props.noValidate&&r.props.liveValidate,i={formData:t},s=t;if(!0===r.props.omitExtraData&&!0===r.props.liveOmit){var o=en(Kr(r.state.schema,r.state.schema,t),"",r.state.schema,t),a=r.getFieldNames(o,t);i={formData:s=r.getUsedFormData(t,a)}}if(n){var l=r.validate(s),c=l.errors,u=l.errorSchema,h=c,d=u;r.props.extraErrors&&(c=ir(u=Or(u,r.props.extraErrors,!0))),i={formData:s,errors:c,errorSchema:u,schemaValidationErrors:h,schemaValidationErrorSchema:d}}else if(!r.props.noValidate&&e){var f=r.props.extraErrors?Or(e,r.props.extraErrors,!0):e;i={formData:s,errorSchema:f,errors:ir(f)}}r.setState(i,(function(){return r.props.onChange&&r.props.onChange(r.state)}))})),vn(gn(r),"onBlur",(function(){var t;r.props.onBlur&&(t=r.props).onBlur.apply(t,arguments)})),vn(gn(r),"onFocus",(function(){var t;r.props.onFocus&&(t=r.props).onFocus.apply(t,arguments)})),vn(gn(r),"onSubmit",(function(t){if(t.preventDefault(),t.target===t.currentTarget){t.persist();var e,n,i=r.state.formData;if(!0===r.props.omitExtraData){var s=en(Kr(r.state.schema,r.state.schema,i),"",r.state.schema,i),o=r.getFieldNames(s,i);i=r.getUsedFormData(i,o)}if(!r.props.noValidate){var a=r.validate(i),l=a.errors,c=a.errorSchema,u=l,h=c;if(Object.keys(l).length>0)return r.props.extraErrors&&(c=Or(c,r.props.extraErrors,!0),l=ir(c)),void r.setState({errors:l,errorSchema:c,schemaValidationErrors:u,schemaValidationErrorSchema:h},(function(){r.props.onError?r.props.onError(l):console.error("Form validation failed",l)}))}r.props.extraErrors?n=ir(e=r.props.extraErrors):(e={},n=[]),r.setState({formData:i,errors:n,errorSchema:e,schemaValidationErrors:[],schemaValidationErrorSchema:{}},(function(){r.props.onSubmit&&r.props.onSubmit(dn({},r.state,{formData:i,status:"submitted"}),t)}))}})),r.state=r.getStateFromProps(t,t.formData),r.props.onChange&&!Jr(r.state.formData,r.props.formData)&&r.props.onChange(r.state),r.formElement=null,r}var r,n;return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&yn(t,e)}(e,t),r=e,n=[{key:"UNSAFE_componentWillReceiveProps",value:function(t){var e=this.getStateFromProps(t,t.formData);Jr(e.formData,t.formData)||Jr(e.formData,this.state.formData)||!this.props.onChange||this.props.onChange(e),this.setState(e)}},{key:"getStateFromProps",value:function(t,e){var r,n,i,s,o=this.state||{},a="schema"in t?t.schema:this.props.schema,l="uiSchema"in t?t.uiSchema:this.props.uiSchema,c=void 0!==e,u="liveValidate"in t?t.liveValidate:this.props.liveValidate,h=c&&!t.noValidate&&u,d=a,f=Ar(a,e,d),p=Kr(a,d,f),m=t.customFormats,g=t.additionalMetaSchemas;if(h){var y=this.validate(f,a,g,m);i=r=y.errors,s=n=y.errorSchema}else{var v=t.noValidate?{errors:[],errorSchema:{}}:t.liveValidate?{errors:o.errors||[],errorSchema:o.errorSchema||{}}:{errors:o.schemaValidationErrors||[],errorSchema:o.schemaValidationErrorSchema||{}};r=v.errors,n=v.errorSchema,i=o.schemaValidationErrors,s=o.schemaValidationErrorSchema}t.extraErrors&&(r=ir(n=Or(n,t.extraErrors,!0)));var _={schema:a,uiSchema:l,idSchema:tn(p,l["ui:rootFieldId"],d,f,t.idPrefix),formData:f,edit:c,errors:r,errorSchema:n,additionalMetaSchemas:g};return i&&(_.schemaValidationErrors=i,_.schemaValidationErrorSchema=s),_}},{key:"shouldComponentUpdate",value:function(t,e){return Qr(this,t,e)}},{key:"validate",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.props.schema,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.props.additionalMetaSchemas,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:this.props.customFormats,i=this.props,s=i.validate,o=i.transformErrors;return ar(t,Kr(e,this.getRegistry().rootSchema,t),s,o,r,n)}},{key:"renderErrors",value:function(){var t=this.state,e=t.errors,r=t.errorSchema,n=t.schema,i=t.uiSchema,o=this.props,a=o.ErrorList,l=o.showErrorList,c=o.formContext;return e.length&&0!=l?s().createElement(a,{errors:e,errorSchema:r,schema:n,uiSchema:i,formContext:c}):null}},{key:"getRegistry",value:function(){var t=br(),e=t.fields,r=t.widgets;return{fields:dn({},e,this.props.fields),widgets:dn({},r,this.props.widgets),ArrayFieldTemplate:this.props.ArrayFieldTemplate,ObjectFieldTemplate:this.props.ObjectFieldTemplate,FieldTemplate:this.props.FieldTemplate,definitions:this.props.schema.definitions||{},rootSchema:this.props.schema,formContext:this.props.formContext||{}}}},{key:"submit",value:function(){this.formElement&&this.formElement.dispatchEvent(new CustomEvent("submit",{cancelable:!0}))}},{key:"render",value:function(){var t=this,e=this.props,r=e.children,n=e.id,i=e.idPrefix,o=e.className,a=e.tagName,l=e.name,c=e.method,u=e.target,h=e.action,d=e.autocomplete,f=e.autoComplete,p=e.enctype,m=e.acceptcharset,g=e.noHtml5Validate,y=e.disabled,v=e.readonly,_=e.formContext,b=this.state,w=b.schema,x=b.uiSchema,E=b.formData,S=b.errorSchema,A=b.idSchema,P=this.getRegistry(),T=P.fields.SchemaField,C=a||"form";d&&console.warn("Using autocomplete property of Form is deprecated, use autoComplete instead.");var M=f||d;return s().createElement(C,{className:o||"rjsf",id:n,name:l,method:c,target:u,action:h,autoComplete:M,encType:p,acceptCharset:m,noValidate:g,onSubmit:this.onSubmit,ref:function(e){t.formElement=e}},this.renderErrors(),s().createElement(T,{schema:w,uiSchema:x,errorSchema:S,idSchema:A,idPrefix:i,formContext:_,formData:E,onChange:this.onChange,onBlur:this.onBlur,onFocus:this.onFocus,registry:P,disabled:y,readonly:v}),r||s().createElement("div",null,s().createElement("button",{type:"submit",className:"btn btn-info"},"Submit")))}}],n&&pn(r.prototype,n),e}(i.Component);function bn(){return bn=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},bn.apply(this,arguments)}function wn(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter((function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable})))),n.forEach((function(e){xn(t,e,r[e])}))}return t}function xn(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function En(t){return(0,i.forwardRef)((function(e,r){var n=e.fields,i=e.widgets,o=function(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}(e,["fields","widgets"]);return n=wn({},t.fields,n),i=wn({},t.widgets,i),s().createElement(An,bn({},t,o,{fields:n,widgets:i,ref:r}))}))}vn(_n,"defaultProps",{uiSchema:{},noValidate:!1,liveValidate:!1,disabled:!1,readonly:!1,noHtml5Validate:!1,ErrorList:function(t){var e=t.errors;return s().createElement("div",{className:"panel panel-danger errors"},s().createElement("div",{className:"panel-heading"},s().createElement("h3",{className:"panel-title"},"Errors")),s().createElement("ul",{className:"list-group"},e.map((function(t,e){return s().createElement("li",{key:e,className:"list-group-item text-danger"},t.stack)}))))},omitExtraData:!1}),En.propTypes={widgets:P().object,fields:P().object};const Sn=En,An=_n},88115:(t,e,r)=>{"use strict";var n=r(57306),i=r(24630),s=r(62742),o=r(99289),a=r(56075),l=r(17438),c=r(77749),u=r(28246),h=r(96644);t.exports=y,y.prototype.validate=function(t,e){var r;if("string"==typeof t){if(!(r=this.getSchema(t)))throw new Error('no schema with key or ref "'+t+'"')}else{var n=this._addSchema(t);r=n.validate||this._compile(n)}var i=r(e);return!0!==r.$async&&(this.errors=r.errors),i},y.prototype.compile=function(t,e){var r=this._addSchema(t,void 0,e);return r.validate||this._compile(r)},y.prototype.addSchema=function(t,e,r,n){if(Array.isArray(t)){for(var s=0;s<t.length;s++)this.addSchema(t[s],void 0,r,n);return this}var o=this._getId(t);if(void 0!==o&&"string"!=typeof o)throw new Error("schema id must be string");return E(this,e=i.normalizeId(e||o)),this._schemas[e]=this._addSchema(t,r,n,!0),this},y.prototype.addMetaSchema=function(t,e,r){return this.addSchema(t,e,r,!0),this},y.prototype.validateSchema=function(t,e){var r=t.$schema;if(void 0!==r&&"string"!=typeof r)throw new Error("$schema must be a string");if(!(r=r||this._opts.defaultMeta||function(t){var e=t._opts.meta;return t._opts.defaultMeta="object"==typeof e?t._getId(e)||e:t.getSchema(p)?p:void 0,t._opts.defaultMeta}(this)))return this.logger.warn("meta-schema not available"),this.errors=null,!0;var n=this.validate(r,t);if(!n&&e){var i="schema is invalid: "+this.errorsText();if("log"!=this._opts.validateSchema)throw new Error(i);this.logger.error(i)}return n},y.prototype.getSchema=function(t){var e=v(this,t);switch(typeof e){case"object":return e.validate||this._compile(e);case"string":return this.getSchema(e);case"undefined":return function(t,e){var r=i.schema.call(t,{schema:{}},e);if(r){var s=r.schema,a=r.root,l=r.baseId,c=n.call(t,s,a,void 0,l);return t._fragments[e]=new o({ref:e,fragment:!0,schema:s,root:a,baseId:l,validate:c}),c}}(this,t)}},y.prototype.removeSchema=function(t){if(t instanceof RegExp)return _(this,this._schemas,t),_(this,this._refs,t),this;switch(typeof t){case"undefined":return _(this,this._schemas),_(this,this._refs),this._cache.clear(),this;case"string":var e=v(this,t);return e&&this._cache.del(e.cacheKey),delete this._schemas[t],delete this._refs[t],this;case"object":var r=this._opts.serialize,n=r?r(t):t;this._cache.del(n);var s=this._getId(t);s&&(s=i.normalizeId(s),delete this._schemas[s],delete this._refs[s])}return this},y.prototype.addFormat=function(t,e){return"string"==typeof e&&(e=new RegExp(e)),this._formats[t]=e,this},y.prototype.errorsText=function(t,e){if(!(t=t||this.errors))return"No errors";for(var r=void 0===(e=e||{}).separator?", ":e.separator,n=void 0===e.dataVar?"data":e.dataVar,i="",s=0;s<t.length;s++){var o=t[s];o&&(i+=n+o.dataPath+" "+o.message+r)}return i.slice(0,-r.length)},y.prototype._addSchema=function(t,e,r,n){if("object"!=typeof t&&"boolean"!=typeof t)throw new Error("schema should be object or boolean");var s=this._opts.serialize,a=s?s(t):t,l=this._cache.get(a);if(l)return l;n=n||!1!==this._opts.addUsedSchema;var c=i.normalizeId(this._getId(t));c&&n&&E(this,c);var u,h=!1!==this._opts.validateSchema&&!e;h&&!(u=c&&c==i.normalizeId(t.$schema))&&this.validateSchema(t,!0);var d=i.ids.call(this,t),f=new o({id:c,schema:t,localRefs:d,cacheKey:a,meta:r});return"#"!=c[0]&&n&&(this._refs[c]=f),this._cache.put(a,f),h&&u&&this.validateSchema(t,!0),f},y.prototype._compile=function(t,e){if(t.compiling)return t.validate=s,s.schema=t.schema,s.errors=null,s.root=e||s,!0===t.schema.$async&&(s.$async=!0),s;var r,i;t.compiling=!0,t.meta&&(r=this._opts,this._opts=this._metaOpts);try{i=n.call(this,t.schema,e,t.localRefs)}catch(e){throw delete t.validate,e}finally{t.compiling=!1,t.meta&&(this._opts=r)}return t.validate=i,t.refs=i.refs,t.refVal=i.refVal,t.root=i.root,i;function s(){var e=t.validate,r=e.apply(this,arguments);return s.errors=e.errors,r}},y.prototype.compileAsync=r(44622);var d=r(22755);y.prototype.addKeyword=d.add,y.prototype.getKeyword=d.get,y.prototype.removeKeyword=d.remove,y.prototype.validateKeyword=d.validate;var f=r(70343);y.ValidationError=f.Validation,y.MissingRefError=f.MissingRef,y.$dataMetaSchema=u;var p="http://json-schema.org/draft-07/schema",m=["removeAdditional","useDefaults","coerceTypes","strictDefaults"],g=["/properties"];function y(t){if(!(this instanceof y))return new y(t);t=this._opts=h.copy(t)||{},function(t){var e=t._opts.logger;if(!1===e)t.logger={log:S,warn:S,error:S};else{if(void 0===e&&(e=console),!("object"==typeof e&&e.log&&e.warn&&e.error))throw new Error("logger must implement log, warn and error methods");t.logger=e}}(this),this._schemas={},this._refs={},this._fragments={},this._formats=l(t.format),this._cache=t.cache||new s,this._loadingSchemas={},this._compilations=[],this.RULES=c(),this._getId=function(t){switch(t.schemaId){case"auto":return x;case"id":return b;default:return w}}(t),t.loopRequired=t.loopRequired||1/0,"property"==t.errorDataPath&&(t._errorDataPathProperty=!0),void 0===t.serialize&&(t.serialize=a),this._metaOpts=function(t){for(var e=h.copy(t._opts),r=0;r<m.length;r++)delete e[m[r]];return e}(this),t.formats&&function(t){for(var e in t._opts.formats){var r=t._opts.formats[e];t.addFormat(e,r)}}(this),t.keywords&&function(t){for(var e in t._opts.keywords){var r=t._opts.keywords[e];t.addKeyword(e,r)}}(this),function(t){var e;if(t._opts.$data&&(e=r(32604),t.addMetaSchema(e,e.$id,!0)),!1!==t._opts.meta){var n=r(42710);t._opts.$data&&(n=u(n,g)),t.addMetaSchema(n,p,!0),t._refs["http://json-schema.org/schema"]=p}}(this),"object"==typeof t.meta&&this.addMetaSchema(t.meta),t.nullable&&this.addKeyword("nullable",{metaSchema:{type:"boolean"}}),function(t){var e=t._opts.schemas;if(e)if(Array.isArray(e))t.addSchema(e);else for(var r in e)t.addSchema(e[r],r)}(this)}function v(t,e){return e=i.normalizeId(e),t._schemas[e]||t._refs[e]||t._fragments[e]}function _(t,e,r){for(var n in e){var i=e[n];i.meta||r&&!r.test(n)||(t._cache.del(i.cacheKey),delete e[n])}}function b(t){return t.$id&&this.logger.warn("schema $id ignored",t.$id),t.id}function w(t){return t.id&&this.logger.warn("schema id ignored",t.id),t.$id}function x(t){if(t.$id&&t.id&&t.$id!=t.id)throw new Error("schema $id is different from id");return t.$id||t.id}function E(t,e){if(t._schemas[e]||t._refs[e])throw new Error('schema with key or id "'+e+'" already exists')}function S(){}},62742:t=>{"use strict";var e=t.exports=function(){this._cache={}};e.prototype.put=function(t,e){this._cache[t]=e},e.prototype.get=function(t){return this._cache[t]},e.prototype.del=function(t){delete this._cache[t]},e.prototype.clear=function(){this._cache={}}},44622:(t,e,r)=>{"use strict";var n=r(70343).MissingRef;t.exports=function t(e,r,i){var s=this;if("function"!=typeof this._opts.loadSchema)throw new Error("options.loadSchema should be a function");"function"==typeof r&&(i=r,r=void 0);var o=a(e).then((function(){var t=s._addSchema(e,void 0,r);return t.validate||l(t)}));return i&&o.then((function(t){i(null,t)}),i),o;function a(e){var r=e.$schema;return r&&!s.getSchema(r)?t.call(s,{$ref:r},!0):Promise.resolve()}function l(t){try{return s._compile(t)}catch(e){if(e instanceof n)return function(e){var n=e.missingSchema;if(c(n))throw new Error("Schema "+n+" is loaded but "+e.missingRef+" cannot be resolved");var i=s._loadingSchemas[n];return i||(i=s._loadingSchemas[n]=s._opts.loadSchema(n)).then(o,o),i.then((function(t){if(!c(n))return a(t).then((function(){c(n)||s.addSchema(t,n,void 0,r)}))})).then((function(){return l(t)}));function o(){delete s._loadingSchemas[n]}function c(t){return s._refs[t]||s._schemas[t]}}(e);throw e}}}},70343:(t,e,r)=>{"use strict";var n=r(24630);function i(t,e,r){this.message=r||i.message(t,e),this.missingRef=n.url(t,e),this.missingSchema=n.normalizeId(n.fullPath(this.missingRef))}function s(t){return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t}t.exports={Validation:s((function(t){this.message="validation failed",this.errors=t,this.ajv=this.validation=!0})),MissingRef:s(i)},i.message=function(t,e){return"can't resolve reference "+e+" from id "+t}},17438:(t,e,r)=>{"use strict";var n=r(96644),i=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,s=[0,31,28,31,30,31,30,31,31,30,31,30,31],o=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i,a=/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,l=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,c=/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,u=/^(?:(?:http[s\u017F]?|ftp):\/\/)(?:(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+(?::(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?@)?(?:(?!10(?:\.[0-9]{1,3}){3})(?!127(?:\.[0-9]{1,3}){3})(?!169\.254(?:\.[0-9]{1,3}){2})(?!192\.168(?:\.[0-9]{1,3}){2})(?!172\.(?:1[6-9]|2[0-9]|3[01])(?:\.[0-9]{1,3}){2})(?:[1-9][0-9]?|1[0-9][0-9]|2[01][0-9]|22[0-3])(?:\.(?:1?[0-9]{1,2}|2[0-4][0-9]|25[0-5])){2}(?:\.(?:[1-9][0-9]?|1[0-9][0-9]|2[0-4][0-9]|25[0-4]))|(?:(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)(?:\.(?:(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-)*(?:[0-9a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)*(?:\.(?:(?:[a-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]){2,})))(?::[0-9]{2,5})?(?:\/(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?$/i,h=/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,d=/^(?:\/(?:[^~/]|~0|~1)*)*$/,f=/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,p=/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/;function m(t){return t="full"==t?"full":"fast",n.copy(m[t])}function g(t){var e=t.match(i);if(!e)return!1;var r=+e[1],n=+e[2],o=+e[3];return n>=1&&n<=12&&o>=1&&o<=(2==n&&function(t){return t%4==0&&(t%100!=0||t%400==0)}(r)?29:s[n])}function y(t,e){var r=t.match(o);if(!r)return!1;var n=r[1],i=r[2],s=r[3],a=r[5];return(n<=23&&i<=59&&s<=59||23==n&&59==i&&60==s)&&(!e||a)}t.exports=m,m.fast={date:/^\d\d\d\d-[0-1]\d-[0-3]\d$/,time:/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,"date-time":/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,"uri-template":c,url:u,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i,hostname:a,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:w,uuid:h,"json-pointer":d,"json-pointer-uri-fragment":f,"relative-json-pointer":p},m.full={date:g,time:y,"date-time":function(t){var e=t.split(v);return 2==e.length&&g(e[0])&&y(e[1],!0)},uri:function(t){return _.test(t)&&l.test(t)},"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":c,url:u,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:a,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:w,uuid:h,"json-pointer":d,"json-pointer-uri-fragment":f,"relative-json-pointer":p};var v=/t|\s/i,_=/\/|:/,b=/[^\\]\\Z/;function w(t){if(b.test(t))return!1;try{return new RegExp(t),!0}catch(t){return!1}}},57306:(t,e,r)=>{"use strict";var n=r(24630),i=r(96644),s=r(70343),o=r(56075),a=r(19905),l=i.ucs2length,c=r(38792),u=s.Validation;function h(t,e,r){var n=f.call(this,t,e,r);return n>=0?{index:n,compiling:!0}:(n=this._compilations.length,this._compilations[n]={schema:t,root:e,baseId:r},{index:n,compiling:!1})}function d(t,e,r){var n=f.call(this,t,e,r);n>=0&&this._compilations.splice(n,1)}function f(t,e,r){for(var n=0;n<this._compilations.length;n++){var i=this._compilations[n];if(i.schema==t&&i.root==e&&i.baseId==r)return n}return-1}function p(t,e){return"var pattern"+t+" = new RegExp("+i.toQuotedString(e[t])+");"}function m(t){return"var default"+t+" = defaults["+t+"];"}function g(t,e){return void 0===e[t]?"":"var refVal"+t+" = refVal["+t+"];"}function y(t){return"var customRule"+t+" = customRules["+t+"];"}function v(t,e){if(!t.length)return"";for(var r="",n=0;n<t.length;n++)r+=e(n,t);return r}t.exports=function t(e,r,f,_){var b=this,w=this._opts,x=[void 0],E={},S=[],A={},P=[],T={},C=[];r=r||{schema:e,refVal:x,refs:E};var M=h.call(this,e,r,_),O=this._compilations[M.index];if(M.compiling)return O.callValidate=function t(){var e=O.validate,r=e.apply(this,arguments);return t.errors=e.errors,r};var R=this._formats,D=this.RULES;try{var I=L(e,r,f,_);O.validate=I;var k=O.callValidate;return k&&(k.schema=I.schema,k.errors=null,k.refs=I.refs,k.refVal=I.refVal,k.root=I.root,k.$async=I.$async,w.sourceCode&&(k.source=I.source)),I}finally{d.call(this,e,r,_)}function L(e,o,h,d){var f=!o||o&&o.schema==e;if(o.schema!=r.schema)return t.call(b,e,o,h,d);var _,A=!0===e.$async,T=a({isTop:!0,schema:e,isRoot:f,baseId:d,root:o,schemaPath:"",errSchemaPath:"#",errorPath:'""',MissingRefError:s.MissingRef,RULES:D,validate:a,util:i,resolve:n,resolveRef:F,usePattern:G,useDefault:$,useCustomRule:z,opts:w,formats:R,logger:b.logger,self:b});T=v(x,g)+v(S,p)+v(P,m)+v(C,y)+T,w.processCode&&(T=w.processCode(T,e));try{_=new Function("self","RULES","formats","root","refVal","defaults","customRules","equal","ucs2length","ValidationError",T)(b,D,R,r,x,P,C,c,l,u),x[0]=_}catch(t){throw b.logger.error("Error compiling schema, function code:",T),t}return _.schema=e,_.errors=null,_.refs=E,_.refVal=x,_.root=f?_:o,A&&(_.$async=!0),!0===w.sourceCode&&(_.source={code:T,patterns:S,defaults:P}),_}function F(e,i,s){i=n.url(e,i);var o,a,l=E[i];if(void 0!==l)return N(o=x[l],a="refVal["+l+"]");if(!s&&r.refs){var c=r.refs[i];if(void 0!==c)return N(o=r.refVal[c],a=j(i,o))}a=j(i);var u=n.call(b,L,r,i);if(void 0===u){var h=f&&f[i];h&&(u=n.inlineRef(h,w.inlineRefs)?h:t.call(b,h,r,f,e))}if(void 0!==u)return function(t,e){var r=E[t];x[r]=e}(i,u),N(u,a);!function(t){delete E[t]}(i)}function j(t,e){var r=x.length;return x[r]=e,E[t]=r,"refVal"+r}function N(t,e){return"object"==typeof t||"boolean"==typeof t?{code:e,schema:t,inline:!0}:{code:e,$async:t&&!!t.$async}}function G(t){var e=A[t];return void 0===e&&(e=A[t]=S.length,S[e]=t),"pattern"+e}function $(t){switch(typeof t){case"boolean":case"number":return""+t;case"string":return i.toQuotedString(t);case"object":if(null===t)return"null";var e=o(t),r=T[e];return void 0===r&&(r=T[e]=P.length,P[r]=t),"default"+r}}function z(t,e,r,n){if(!1!==b._opts.validateSchema){var i=t.definition.dependencies;if(i&&!i.every((function(t){return Object.prototype.hasOwnProperty.call(r,t)})))throw new Error("parent schema must have all required keywords: "+i.join(","));var s=t.definition.validateSchema;if(s&&!s(e)){var o="keyword schema is invalid: "+b.errorsText(s.errors);if("log"!=b._opts.validateSchema)throw new Error(o);b.logger.error(o)}}var a,l=t.definition.compile,c=t.definition.inline,u=t.definition.macro;if(l)a=l.call(b,e,r,n);else if(u)a=u.call(b,e,r,n),!1!==w.validateSchema&&b.validateSchema(a,!0);else if(c)a=c.call(b,n,t.keyword,e,r);else if(!(a=t.definition.validate))return;if(void 0===a)throw new Error('custom keyword "'+t.keyword+'"failed to compile');var h=C.length;return C[h]=a,{code:"customRule"+h,validate:a}}}},24630:(t,e,r)=>{"use strict";var n=r(2862),i=r(38792),s=r(96644),o=r(99289),a=r(86850);function l(t,e,r){var n=this._refs[r];if("string"==typeof n){if(!this._refs[n])return l.call(this,t,e,n);n=this._refs[n]}if((n=n||this._schemas[r])instanceof o)return p(n.schema,this._opts.inlineRefs)?n.schema:n.validate||this._compile(n);var i,s,a,u=c.call(this,e,r);return u&&(i=u.schema,e=u.root,a=u.baseId),i instanceof o?s=i.validate||t.call(this,i.schema,e,void 0,a):void 0!==i&&(s=p(i,this._opts.inlineRefs)?i:t.call(this,i,e,void 0,a)),s}function c(t,e){var r=n.parse(e),i=v(r),s=y(this._getId(t.schema));if(0===Object.keys(t.schema).length||i!==s){var a=b(i),l=this._refs[a];if("string"==typeof l)return u.call(this,t,l,r);if(l instanceof o)l.validate||this._compile(l),t=l;else{if(!((l=this._schemas[a])instanceof o))return;if(l.validate||this._compile(l),a==b(e))return{schema:l,root:t,baseId:s};t=l}if(!t.schema)return;s=y(this._getId(t.schema))}return d.call(this,r,s,t.schema,t)}function u(t,e,r){var n=c.call(this,t,e);if(n){var i=n.schema,s=n.baseId;t=n.root;var o=this._getId(i);return o&&(s=w(s,o)),d.call(this,r,s,i,t)}}t.exports=l,l.normalizeId=b,l.fullPath=y,l.url=w,l.ids=function(t){var e=b(this._getId(t)),r={"":e},o={"":y(e,!1)},l={},c=this;return a(t,{allKeys:!0},(function(t,e,a,u,h,d,f){if(""!==e){var p=c._getId(t),m=r[u],g=o[u]+"/"+h;if(void 0!==f&&(g+="/"+("number"==typeof f?f:s.escapeFragment(f))),"string"==typeof p){p=m=b(m?n.resolve(m,p):p);var y=c._refs[p];if("string"==typeof y&&(y=c._refs[y]),y&&y.schema){if(!i(t,y.schema))throw new Error('id "'+p+'" resolves to more than one schema')}else if(p!=b(g))if("#"==p[0]){if(l[p]&&!i(t,l[p]))throw new Error('id "'+p+'" resolves to more than one schema');l[p]=t}else c._refs[p]=g}r[e]=m,o[e]=g}})),l},l.inlineRef=p,l.schema=c;var h=s.toHash(["properties","patternProperties","enum","dependencies","definitions"]);function d(t,e,r,n){if(t.fragment=t.fragment||"","/"==t.fragment.slice(0,1)){for(var i=t.fragment.split("/"),o=1;o<i.length;o++){var a=i[o];if(a){if(void 0===(r=r[a=s.unescapeFragment(a)]))break;var l;if(!h[a]&&((l=this._getId(r))&&(e=w(e,l)),r.$ref)){var u=w(e,r.$ref),d=c.call(this,n,u);d&&(r=d.schema,n=d.root,e=d.baseId)}}}return void 0!==r&&r!==n.schema?{schema:r,root:n,baseId:e}:void 0}}var f=s.toHash(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum"]);function p(t,e){return!1!==e&&(void 0===e||!0===e?m(t):e?g(t)<=e:void 0)}function m(t){var e;if(Array.isArray(t)){for(var r=0;r<t.length;r++)if("object"==typeof(e=t[r])&&!m(e))return!1}else for(var n in t){if("$ref"==n)return!1;if("object"==typeof(e=t[n])&&!m(e))return!1}return!0}function g(t){var e,r=0;if(Array.isArray(t)){for(var n=0;n<t.length;n++)if("object"==typeof(e=t[n])&&(r+=g(e)),r==1/0)return 1/0}else for(var i in t){if("$ref"==i)return 1/0;if(f[i])r++;else if("object"==typeof(e=t[i])&&(r+=g(e)+1),r==1/0)return 1/0}return r}function y(t,e){return!1!==e&&(t=b(t)),v(n.parse(t))}function v(t){return n.serialize(t).split("#")[0]+"#"}var _=/#\/?$/;function b(t){return t?t.replace(_,""):""}function w(t,e){return e=b(e),n.resolve(t,e)}},77749:(t,e,r)=>{"use strict";var n=r(13131),i=r(96644).toHash;t.exports=function(){var t=[{type:"number",rules:[{maximum:["exclusiveMaximum"]},{minimum:["exclusiveMinimum"]},"multipleOf","format"]},{type:"string",rules:["maxLength","minLength","pattern","format"]},{type:"array",rules:["maxItems","minItems","items","contains","uniqueItems"]},{type:"object",rules:["maxProperties","minProperties","required","dependencies","propertyNames",{properties:["additionalProperties","patternProperties"]}]},{rules:["$ref","const","enum","not","anyOf","oneOf","allOf","if"]}],e=["type","$comment"];return t.all=i(e),t.types=i(["number","integer","string","array","object","boolean","null"]),t.forEach((function(r){r.rules=r.rules.map((function(r){var i;if("object"==typeof r){var s=Object.keys(r)[0];i=r[s],r=s,i.forEach((function(r){e.push(r),t.all[r]=!0}))}return e.push(r),t.all[r]={keyword:r,code:n[r],implements:i}})),t.all.$comment={keyword:"$comment",code:n.$comment},r.type&&(t.types[r.type]=r)})),t.keywords=i(e.concat(["$schema","$id","id","$data","$async","title","description","default","definitions","examples","readOnly","writeOnly","contentMediaType","contentEncoding","additionalItems","then","else"])),t.custom={},t}},99289:(t,e,r)=>{"use strict";var n=r(96644);t.exports=function(t){n.copy(t,this)}},78205:t=>{"use strict";t.exports=function(t){for(var e,r=0,n=t.length,i=0;i<n;)r++,(e=t.charCodeAt(i++))>=55296&&e<=56319&&i<n&&56320==(64512&(e=t.charCodeAt(i)))&&i++;return r}},96644:(t,e,r)=>{"use strict";function n(t,e,r,n){var i=n?" !== ":" === ",s=n?" || ":" && ",o=n?"!":"",a=n?"":"!";switch(t){case"null":return e+i+"null";case"array":return o+"Array.isArray("+e+")";case"object":return"("+o+e+s+"typeof "+e+i+'"object"'+s+a+"Array.isArray("+e+"))";case"integer":return"(typeof "+e+i+'"number"'+s+a+"("+e+" % 1)"+s+e+i+e+(r?s+o+"isFinite("+e+")":"")+")";case"number":return"(typeof "+e+i+'"'+t+'"'+(r?s+o+"isFinite("+e+")":"")+")";default:return"typeof "+e+i+'"'+t+'"'}}t.exports={copy:function(t,e){for(var r in e=e||{},t)e[r]=t[r];return e},checkDataType:n,checkDataTypes:function(t,e,r){if(1===t.length)return n(t[0],e,r,!0);var i="",o=s(t);for(var a in o.array&&o.object&&(i=o.null?"(":"(!"+e+" || ",i+="typeof "+e+' !== "object")',delete o.null,delete o.array,delete o.object),o.number&&delete o.integer,o)i+=(i?" && ":"")+n(a,e,r,!0);return i},coerceToTypes:function(t,e){if(Array.isArray(e)){for(var r=[],n=0;n<e.length;n++){var s=e[n];(i[s]||"array"===t&&"array"===s)&&(r[r.length]=s)}if(r.length)return r}else{if(i[e])return[e];if("array"===t&&"array"===e)return["array"]}},toHash:s,getProperty:l,escapeQuotes:c,equal:r(38792),ucs2length:r(78205),varOccurences:function(t,e){e+="[^0-9]";var r=t.match(new RegExp(e,"g"));return r?r.length:0},varReplace:function(t,e,r){return e+="([^0-9])",r=r.replace(/\$/g,"$$$$"),t.replace(new RegExp(e,"g"),r+"$1")},schemaHasRules:function(t,e){if("boolean"==typeof t)return!t;for(var r in t)if(e[r])return!0},schemaHasRulesExcept:function(t,e,r){if("boolean"==typeof t)return!t&&"not"!=r;for(var n in t)if(n!=r&&e[n])return!0},schemaUnknownRules:function(t,e){if("boolean"!=typeof t)for(var r in t)if(!e[r])return r},toQuotedString:u,getPathExpr:function(t,e,r,n){return f(t,r?"'/' + "+e+(n?"":".replace(/~/g, '~0').replace(/\\//g, '~1')"):n?"'[' + "+e+" + ']'":"'[\\'' + "+e+" + '\\']'")},getPath:function(t,e,r){return f(t,u(r?"/"+p(e):l(e)))},getData:function(t,e,r){var n,i,s,o;if(""===t)return"rootData";if("/"==t[0]){if(!h.test(t))throw new Error("Invalid JSON-pointer: "+t);i=t,s="rootData"}else{if(!(o=t.match(d)))throw new Error("Invalid JSON-pointer: "+t);if(n=+o[1],"#"==(i=o[2])){if(n>=e)throw new Error("Cannot access property/index "+n+" levels up, current level is "+e);return r[e-n]}if(n>e)throw new Error("Cannot access data "+n+" levels up, current level is "+e);if(s="data"+(e-n||""),!i)return s}for(var a=s,c=i.split("/"),u=0;u<c.length;u++){var f=c[u];f&&(a+=" && "+(s+=l(m(f))))}return a},unescapeFragment:function(t){return m(decodeURIComponent(t))},unescapeJsonPointer:m,escapeFragment:function(t){return encodeURIComponent(p(t))},escapeJsonPointer:p};var i=s(["string","number","integer","boolean","null"]);function s(t){for(var e={},r=0;r<t.length;r++)e[t[r]]=!0;return e}var o=/^[a-z$_][a-z$_0-9]*$/i,a=/'|\\/g;function l(t){return"number"==typeof t?"["+t+"]":o.test(t)?"."+t:"['"+c(t)+"']"}function c(t){return t.replace(a,"\\$&").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\f/g,"\\f").replace(/\t/g,"\\t")}function u(t){return"'"+c(t)+"'"}var h=/^\/(?:[^~]|~0|~1)*$/,d=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function f(t,e){return'""'==t?e:(t+" + "+e).replace(/([^\\])' \+ '/g,"$1")}function p(t){return t.replace(/~/g,"~0").replace(/\//g,"~1")}function m(t){return t.replace(/~1/g,"/").replace(/~0/g,"~")}},28246:t=>{"use strict";var e=["multipleOf","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","additionalItems","maxItems","minItems","uniqueItems","maxProperties","minProperties","required","additionalProperties","enum","format","const"];t.exports=function(t,r){for(var n=0;n<r.length;n++){t=JSON.parse(JSON.stringify(t));var i,s=r[n].split("/"),o=t;for(i=1;i<s.length;i++)o=o[s[i]];for(i=0;i<e.length;i++){var a=e[i],l=o[a];l&&(o[a]={anyOf:[l,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]})}}return t}},27569:(t,e,r)=>{"use strict";var n=r(42710);t.exports={$id:"https://github.com/ajv-validator/ajv/blob/master/lib/definition_schema.js",definitions:{simpleTypes:n.definitions.simpleTypes},type:"object",dependencies:{schema:["validate"],$data:["validate"],statements:["inline"],valid:{not:{required:["macro"]}}},properties:{type:n.properties.type,schema:{type:"boolean"},statements:{type:"boolean"},dependencies:{type:"array",items:{type:"string"}},metaSchema:{type:"object"},modifying:{type:"boolean"},valid:{type:"boolean"},$data:{type:"boolean"},async:{type:"boolean"},errors:{anyOf:[{type:"boolean"},{const:"full"}]}}}},88363:t=>{"use strict";t.exports=function(t,e,r){var n,i=" ",s=t.level,o=t.dataLevel,a=t.schema[e],l=t.schemaPath+t.util.getProperty(e),c=t.errSchemaPath+"/"+e,u=!t.opts.allErrors,h="data"+(o||""),d=t.opts.$data&&a&&a.$data;d?(i+=" var schema"+s+" = "+t.util.getData(a.$data,o,t.dataPathArr)+"; ",n="schema"+s):n=a;var f="maximum"==e,p=f?"exclusiveMaximum":"exclusiveMinimum",m=t.schema[p],g=t.opts.$data&&m&&m.$data,y=f?"<":">",v=f?">":"<",_=void 0;if(!d&&"number"!=typeof a&&void 0!==a)throw new Error(e+" must be number");if(!g&&void 0!==m&&"number"!=typeof m&&"boolean"!=typeof m)throw new Error(p+" must be number or boolean");if(g){var b,w=t.util.getData(m.$data,o,t.dataPathArr),x="exclusive"+s,E="exclType"+s,S="exclIsNumber"+s,A="' + "+(T="op"+s)+" + '";i+=" var schemaExcl"+s+" = "+w+"; ",i+=" var "+x+"; var "+E+" = typeof "+(w="schemaExcl"+s)+"; if ("+E+" != 'boolean' && "+E+" != 'undefined' && "+E+" != 'number') { ",_=p,(b=b||[]).push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(_||"_exclusiveLimit")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(c)+" , params: {} ",!1!==t.opts.messages&&(i+=" , message: '"+p+" should be boolean' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var P=i;i=b.pop(),!t.compositeRule&&u?t.async?i+=" throw new ValidationError(["+P+"]); ":i+=" validate.errors = ["+P+"]; return false; ":i+=" var err = "+P+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } else if ( ",d&&(i+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),i+=" "+E+" == 'number' ? ( ("+x+" = "+n+" === undefined || "+w+" "+y+"= "+n+") ? "+h+" "+v+"= "+w+" : "+h+" "+v+" "+n+" ) : ( ("+x+" = "+w+" === true) ? "+h+" "+v+"= "+n+" : "+h+" "+v+" "+n+" ) || "+h+" !== "+h+") { var op"+s+" = "+x+" ? '"+y+"' : '"+y+"='; ",void 0===a&&(_=p,c=t.errSchemaPath+"/"+p,n=w,d=g)}else if(A=y,(S="number"==typeof m)&&d){var T="'"+A+"'";i+=" if ( ",d&&(i+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),i+=" ( "+n+" === undefined || "+m+" "+y+"= "+n+" ? "+h+" "+v+"= "+m+" : "+h+" "+v+" "+n+" ) || "+h+" !== "+h+") { "}else S&&void 0===a?(x=!0,_=p,c=t.errSchemaPath+"/"+p,n=m,v+="="):(S&&(n=Math[f?"min":"max"](m,a)),m===(!S||n)?(x=!0,_=p,c=t.errSchemaPath+"/"+p,v+="="):(x=!1,A+="=")),T="'"+A+"'",i+=" if ( ",d&&(i+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),i+=" "+h+" "+v+" "+n+" || "+h+" !== "+h+") { ";return _=_||e,(b=b||[]).push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(_||"_limit")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(c)+" , params: { comparison: "+T+", limit: "+n+", exclusive: "+x+" } ",!1!==t.opts.messages&&(i+=" , message: 'should be "+A+" ",i+=d?"' + "+n:n+"'"),t.opts.verbose&&(i+=" , schema: ",i+=d?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ",P=i,i=b.pop(),!t.compositeRule&&u?t.async?i+=" throw new ValidationError(["+P+"]); ":i+=" validate.errors = ["+P+"]; return false; ":i+=" var err = "+P+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } ",u&&(i+=" else { "),i}},81463:t=>{"use strict";t.exports=function(t,e,r){var n,i=" ",s=t.level,o=t.dataLevel,a=t.schema[e],l=t.schemaPath+t.util.getProperty(e),c=t.errSchemaPath+"/"+e,u=!t.opts.allErrors,h="data"+(o||""),d=t.opts.$data&&a&&a.$data;if(d?(i+=" var schema"+s+" = "+t.util.getData(a.$data,o,t.dataPathArr)+"; ",n="schema"+s):n=a,!d&&"number"!=typeof a)throw new Error(e+" must be number");i+="if ( ",d&&(i+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),i+=" "+h+".length "+("maxItems"==e?">":"<")+" "+n+") { ";var f=e,p=p||[];p.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(f||"_limitItems")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(c)+" , params: { limit: "+n+" } ",!1!==t.opts.messages&&(i+=" , message: 'should NOT have ",i+="maxItems"==e?"more":"fewer",i+=" than ",i+=d?"' + "+n+" + '":""+a,i+=" items' "),t.opts.verbose&&(i+=" , schema: ",i+=d?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var m=i;return i=p.pop(),!t.compositeRule&&u?t.async?i+=" throw new ValidationError(["+m+"]); ":i+=" validate.errors = ["+m+"]; return false; ":i+=" var err = "+m+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+="} ",u&&(i+=" else { "),i}},51103:t=>{"use strict";t.exports=function(t,e,r){var n,i=" ",s=t.level,o=t.dataLevel,a=t.schema[e],l=t.schemaPath+t.util.getProperty(e),c=t.errSchemaPath+"/"+e,u=!t.opts.allErrors,h="data"+(o||""),d=t.opts.$data&&a&&a.$data;if(d?(i+=" var schema"+s+" = "+t.util.getData(a.$data,o,t.dataPathArr)+"; ",n="schema"+s):n=a,!d&&"number"!=typeof a)throw new Error(e+" must be number");var f="maxLength"==e?">":"<";i+="if ( ",d&&(i+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),!1===t.opts.unicode?i+=" "+h+".length ":i+=" ucs2length("+h+") ",i+=" "+f+" "+n+") { ";var p=e,m=m||[];m.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(p||"_limitLength")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(c)+" , params: { limit: "+n+" } ",!1!==t.opts.messages&&(i+=" , message: 'should NOT be ",i+="maxLength"==e?"longer":"shorter",i+=" than ",i+=d?"' + "+n+" + '":""+a,i+=" characters' "),t.opts.verbose&&(i+=" , schema: ",i+=d?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var g=i;return i=m.pop(),!t.compositeRule&&u?t.async?i+=" throw new ValidationError(["+g+"]); ":i+=" validate.errors = ["+g+"]; return false; ":i+=" var err = "+g+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+="} ",u&&(i+=" else { "),i}},31106:t=>{"use strict";t.exports=function(t,e,r){var n,i=" ",s=t.level,o=t.dataLevel,a=t.schema[e],l=t.schemaPath+t.util.getProperty(e),c=t.errSchemaPath+"/"+e,u=!t.opts.allErrors,h="data"+(o||""),d=t.opts.$data&&a&&a.$data;if(d?(i+=" var schema"+s+" = "+t.util.getData(a.$data,o,t.dataPathArr)+"; ",n="schema"+s):n=a,!d&&"number"!=typeof a)throw new Error(e+" must be number");i+="if ( ",d&&(i+=" ("+n+" !== undefined && typeof "+n+" != 'number') || "),i+=" Object.keys("+h+").length "+("maxProperties"==e?">":"<")+" "+n+") { ";var f=e,p=p||[];p.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(f||"_limitProperties")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(c)+" , params: { limit: "+n+" } ",!1!==t.opts.messages&&(i+=" , message: 'should NOT have ",i+="maxProperties"==e?"more":"fewer",i+=" than ",i+=d?"' + "+n+" + '":""+a,i+=" properties' "),t.opts.verbose&&(i+=" , schema: ",i+=d?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var m=i;return i=p.pop(),!t.compositeRule&&u?t.async?i+=" throw new ValidationError(["+m+"]); ":i+=" validate.errors = ["+m+"]; return false; ":i+=" var err = "+m+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+="} ",u&&(i+=" else { "),i}},62753:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.schema[e],s=t.schemaPath+t.util.getProperty(e),o=t.errSchemaPath+"/"+e,a=!t.opts.allErrors,l=t.util.copy(t),c="";l.level++;var u="valid"+l.level,h=l.baseId,d=!0,f=i;if(f)for(var p,m=-1,g=f.length-1;m<g;)p=f[m+=1],(t.opts.strictKeywords?"object"==typeof p&&Object.keys(p).length>0||!1===p:t.util.schemaHasRules(p,t.RULES.all))&&(d=!1,l.schema=p,l.schemaPath=s+"["+m+"]",l.errSchemaPath=o+"/"+m,n+=" "+t.validate(l)+" ",l.baseId=h,a&&(n+=" if ("+u+") { ",c+="}"));return a&&(n+=d?" if (true) { ":" "+c.slice(0,-1)+" "),n}},42024:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="valid"+i,d="errs__"+i,f=t.util.copy(t),p="";f.level++;var m="valid"+f.level,g=o.every((function(e){return t.opts.strictKeywords?"object"==typeof e&&Object.keys(e).length>0||!1===e:t.util.schemaHasRules(e,t.RULES.all)}));if(g){var y=f.baseId;n+=" var "+d+" = errors; var "+h+" = false; ";var v=t.compositeRule;t.compositeRule=f.compositeRule=!0;var _=o;if(_)for(var b,w=-1,x=_.length-1;w<x;)b=_[w+=1],f.schema=b,f.schemaPath=a+"["+w+"]",f.errSchemaPath=l+"/"+w,n+=" "+t.validate(f)+" ",f.baseId=y,n+=" "+h+" = "+h+" || "+m+"; if (!"+h+") { ",p+="}";t.compositeRule=f.compositeRule=v,n+=" "+p+" if (!"+h+") { var err = ",!1!==t.createErrors?(n+=" { keyword: 'anyOf' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: {} ",!1!==t.opts.messages&&(n+=" , message: 'should match some schema in anyOf' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",n+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!t.compositeRule&&c&&(t.async?n+=" throw new ValidationError(vErrors); ":n+=" validate.errors = vErrors; return false; "),n+=" } else { errors = "+d+"; if (vErrors !== null) { if ("+d+") vErrors.length = "+d+"; else vErrors = null; } ",t.opts.allErrors&&(n+=" } ")}else c&&(n+=" if (true) { ");return n}},29094:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.schema[e],s=t.errSchemaPath+"/"+e,o=(t.opts.allErrors,t.util.toQuotedString(i));return!0===t.opts.$comment?n+=" console.log("+o+");":"function"==typeof t.opts.$comment&&(n+=" self._opts.$comment("+o+", "+t.util.toQuotedString(s)+", validate.root.schema);"),n}},76816:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="valid"+i,d=t.opts.$data&&o&&o.$data;d&&(n+=" var schema"+i+" = "+t.util.getData(o.$data,s,t.dataPathArr)+"; "),d||(n+=" var schema"+i+" = validate.schema"+a+";"),n+="var "+h+" = equal("+u+", schema"+i+"); if (!"+h+") { ";var f=f||[];f.push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'const' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { allowedValue: schema"+i+" } ",!1!==t.opts.messages&&(n+=" , message: 'should be equal to constant' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ";var p=n;return n=f.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+p+"]); ":n+=" validate.errors = ["+p+"]; return false; ":n+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" }",c&&(n+=" else { "),n}},74010:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="valid"+i,d="errs__"+i,f=t.util.copy(t);f.level++;var p="valid"+f.level,m="i"+i,g=f.dataLevel=t.dataLevel+1,y="data"+g,v=t.baseId,_=t.opts.strictKeywords?"object"==typeof o&&Object.keys(o).length>0||!1===o:t.util.schemaHasRules(o,t.RULES.all);if(n+="var "+d+" = errors;var "+h+";",_){var b=t.compositeRule;t.compositeRule=f.compositeRule=!0,f.schema=o,f.schemaPath=a,f.errSchemaPath=l,n+=" var "+p+" = false; for (var "+m+" = 0; "+m+" < "+u+".length; "+m+"++) { ",f.errorPath=t.util.getPathExpr(t.errorPath,m,t.opts.jsonPointers,!0);var w=u+"["+m+"]";f.dataPathArr[g]=m;var x=t.validate(f);f.baseId=v,t.util.varOccurences(x,y)<2?n+=" "+t.util.varReplace(x,y,w)+" ":n+=" var "+y+" = "+w+"; "+x+" ",n+=" if ("+p+") break; } ",t.compositeRule=f.compositeRule=b,n+=" if (!"+p+") {"}else n+=" if ("+u+".length == 0) {";var E=E||[];E.push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'contains' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: {} ",!1!==t.opts.messages&&(n+=" , message: 'should contain a valid item' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ";var S=n;return n=E.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+S+"]); ":n+=" validate.errors = ["+S+"]; return false; ":n+=" var err = "+S+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" } else { ",_&&(n+=" errors = "+d+"; if (vErrors !== null) { if ("+d+") vErrors.length = "+d+"; else vErrors = null; } "),t.opts.allErrors&&(n+=" } "),n}},36088:t=>{"use strict";t.exports=function(t,e,r){var n,i,s=" ",o=t.level,a=t.dataLevel,l=t.schema[e],c=t.schemaPath+t.util.getProperty(e),u=t.errSchemaPath+"/"+e,h=!t.opts.allErrors,d="data"+(a||""),f="valid"+o,p="errs__"+o,m=t.opts.$data&&l&&l.$data;m?(s+=" var schema"+o+" = "+t.util.getData(l.$data,a,t.dataPathArr)+"; ",i="schema"+o):i=l;var g,y,v,_,b,w=this,x="definition"+o,E=w.definition,S="";if(m&&E.$data){b="keywordValidate"+o;var A=E.validateSchema;s+=" var "+x+" = RULES.custom['"+e+"'].definition; var "+b+" = "+x+".validate;"}else{if(!(_=t.useCustomRule(w,l,t.schema,t)))return;i="validate.schema"+c,b=_.code,g=E.compile,y=E.inline,v=E.macro}var P=b+".errors",T="i"+o,C="ruleErr"+o,M=E.async;if(M&&!t.async)throw new Error("async keyword in sync schema");if(y||v||(s+=P+" = null;"),s+="var "+p+" = errors;var "+f+";",m&&E.$data&&(S+="}",s+=" if ("+i+" === undefined) { "+f+" = true; } else { ",A&&(S+="}",s+=" "+f+" = "+x+".validateSchema("+i+"); if ("+f+") { ")),y)E.statements?s+=" "+_.validate+" ":s+=" "+f+" = "+_.validate+"; ";else if(v){var O=t.util.copy(t);S="",O.level++;var R="valid"+O.level;O.schema=_.validate,O.schemaPath="";var D=t.compositeRule;t.compositeRule=O.compositeRule=!0;var I=t.validate(O).replace(/validate\.schema/g,b);t.compositeRule=O.compositeRule=D,s+=" "+I}else{(j=j||[]).push(s),s="",s+=" "+b+".call( ",t.opts.passContext?s+="this":s+="self",g||!1===E.schema?s+=" , "+d+" ":s+=" , "+i+" , "+d+" , validate.schema"+t.schemaPath+" ",s+=" , (dataPath || '')",'""'!=t.errorPath&&(s+=" + "+t.errorPath);var k=a?"data"+(a-1||""):"parentData",L=a?t.dataPathArr[a]:"parentDataProperty",F=s+=" , "+k+" , "+L+" , rootData ) ";s=j.pop(),!1===E.errors?(s+=" "+f+" = ",M&&(s+="await "),s+=F+"; "):s+=M?" var "+(P="customErrors"+o)+" = null; try { "+f+" = await "+F+"; } catch (e) { "+f+" = false; if (e instanceof ValidationError) "+P+" = e.errors; else throw e; } ":" "+P+" = null; "+f+" = "+F+"; "}if(E.modifying&&(s+=" if ("+k+") "+d+" = "+k+"["+L+"];"),s+=""+S,E.valid)h&&(s+=" if (true) { ");else{var j;s+=" if ( ",void 0===E.valid?(s+=" !",s+=v?""+R:""+f):s+=" "+!E.valid+" ",s+=") { ",n=w.keyword,(j=j||[]).push(s),s="",(j=j||[]).push(s),s="",!1!==t.createErrors?(s+=" { keyword: '"+(n||"custom")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { keyword: '"+w.keyword+"' } ",!1!==t.opts.messages&&(s+=" , message: 'should pass \""+w.keyword+"\" keyword validation' "),t.opts.verbose&&(s+=" , schema: validate.schema"+c+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+d+" "),s+=" } "):s+=" {} ";var N=s;s=j.pop(),!t.compositeRule&&h?t.async?s+=" throw new ValidationError(["+N+"]); ":s+=" validate.errors = ["+N+"]; return false; ":s+=" var err = "+N+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";var G=s;s=j.pop(),y?E.errors?"full"!=E.errors&&(s+=" for (var "+T+"="+p+"; "+T+"<errors; "+T+"++) { var "+C+" = vErrors["+T+"]; if ("+C+".dataPath === undefined) "+C+".dataPath = (dataPath || '') + "+t.errorPath+"; if ("+C+".schemaPath === undefined) { "+C+'.schemaPath = "'+u+'"; } ',t.opts.verbose&&(s+=" "+C+".schema = "+i+"; "+C+".data = "+d+"; "),s+=" } "):!1===E.errors?s+=" "+G+" ":(s+=" if ("+p+" == errors) { "+G+" } else { for (var "+T+"="+p+"; "+T+"<errors; "+T+"++) { var "+C+" = vErrors["+T+"]; if ("+C+".dataPath === undefined) "+C+".dataPath = (dataPath || '') + "+t.errorPath+"; if ("+C+".schemaPath === undefined) { "+C+'.schemaPath = "'+u+'"; } ',t.opts.verbose&&(s+=" "+C+".schema = "+i+"; "+C+".data = "+d+"; "),s+=" } } "):v?(s+=" var err = ",!1!==t.createErrors?(s+=" { keyword: '"+(n||"custom")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { keyword: '"+w.keyword+"' } ",!1!==t.opts.messages&&(s+=" , message: 'should pass \""+w.keyword+"\" keyword validation' "),t.opts.verbose&&(s+=" , schema: validate.schema"+c+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+d+" "),s+=" } "):s+=" {} ",s+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!t.compositeRule&&h&&(t.async?s+=" throw new ValidationError(vErrors); ":s+=" validate.errors = vErrors; return false; ")):!1===E.errors?s+=" "+G+" ":(s+=" if (Array.isArray("+P+")) { if (vErrors === null) vErrors = "+P+"; else vErrors = vErrors.concat("+P+"); errors = vErrors.length; for (var "+T+"="+p+"; "+T+"<errors; "+T+"++) { var "+C+" = vErrors["+T+"]; if ("+C+".dataPath === undefined) "+C+".dataPath = (dataPath || '') + "+t.errorPath+"; "+C+'.schemaPath = "'+u+'"; ',t.opts.verbose&&(s+=" "+C+".schema = "+i+"; "+C+".data = "+d+"; "),s+=" } } else { "+G+" } "),s+=" } ",h&&(s+=" else { ")}return s}},97478:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="errs__"+i,d=t.util.copy(t),f="";d.level++;var p="valid"+d.level,m={},g={},y=t.opts.ownProperties;for(w in o)if("__proto__"!=w){var v=o[w],_=Array.isArray(v)?g:m;_[w]=v}n+="var "+h+" = errors;";var b=t.errorPath;for(var w in n+="var missing"+i+";",g)if((_=g[w]).length){if(n+=" if ( "+u+t.util.getProperty(w)+" !== undefined ",y&&(n+=" && Object.prototype.hasOwnProperty.call("+u+", '"+t.util.escapeQuotes(w)+"') "),c){n+=" && ( ";var x=_;if(x)for(var E=-1,S=x.length-1;E<S;)O=x[E+=1],E&&(n+=" || "),n+=" ( ( "+(k=u+(I=t.util.getProperty(O)))+" === undefined ",y&&(n+=" || ! Object.prototype.hasOwnProperty.call("+u+", '"+t.util.escapeQuotes(O)+"') "),n+=") && (missing"+i+" = "+t.util.toQuotedString(t.opts.jsonPointers?O:I)+") ) ";n+=")) { ";var A="missing"+i,P="' + "+A+" + '";t.opts._errorDataPathProperty&&(t.errorPath=t.opts.jsonPointers?t.util.getPathExpr(b,A,!0):b+" + "+A);var T=T||[];T.push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { property: '"+t.util.escapeQuotes(w)+"', missingProperty: '"+P+"', depsCount: "+_.length+", deps: '"+t.util.escapeQuotes(1==_.length?_[0]:_.join(", "))+"' } ",!1!==t.opts.messages&&(n+=" , message: 'should have ",1==_.length?n+="property "+t.util.escapeQuotes(_[0]):n+="properties "+t.util.escapeQuotes(_.join(", ")),n+=" when property "+t.util.escapeQuotes(w)+" is present' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ";var C=n;n=T.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+C+"]); ":n+=" validate.errors = ["+C+"]; return false; ":n+=" var err = "+C+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else{n+=" ) { ";var M=_;if(M)for(var O,R=-1,D=M.length-1;R<D;){O=M[R+=1];var I=t.util.getProperty(O),k=(P=t.util.escapeQuotes(O),u+I);t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPath(b,O,t.opts.jsonPointers)),n+=" if ( "+k+" === undefined ",y&&(n+=" || ! Object.prototype.hasOwnProperty.call("+u+", '"+t.util.escapeQuotes(O)+"') "),n+=") { var err = ",!1!==t.createErrors?(n+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { property: '"+t.util.escapeQuotes(w)+"', missingProperty: '"+P+"', depsCount: "+_.length+", deps: '"+t.util.escapeQuotes(1==_.length?_[0]:_.join(", "))+"' } ",!1!==t.opts.messages&&(n+=" , message: 'should have ",1==_.length?n+="property "+t.util.escapeQuotes(_[0]):n+="properties "+t.util.escapeQuotes(_.join(", ")),n+=" when property "+t.util.escapeQuotes(w)+" is present' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",n+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}n+=" } ",c&&(f+="}",n+=" else { ")}t.errorPath=b;var L=d.baseId;for(var w in m)v=m[w],(t.opts.strictKeywords?"object"==typeof v&&Object.keys(v).length>0||!1===v:t.util.schemaHasRules(v,t.RULES.all))&&(n+=" "+p+" = true; if ( "+u+t.util.getProperty(w)+" !== undefined ",y&&(n+=" && Object.prototype.hasOwnProperty.call("+u+", '"+t.util.escapeQuotes(w)+"') "),n+=") { ",d.schema=v,d.schemaPath=a+t.util.getProperty(w),d.errSchemaPath=l+"/"+t.util.escapeFragment(w),n+=" "+t.validate(d)+" ",d.baseId=L,n+=" } ",c&&(n+=" if ("+p+") { ",f+="}"));return c&&(n+=" "+f+" if ("+h+" == errors) {"),n}},92982:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="valid"+i,d=t.opts.$data&&o&&o.$data;d&&(n+=" var schema"+i+" = "+t.util.getData(o.$data,s,t.dataPathArr)+"; ");var f="i"+i,p="schema"+i;d||(n+=" var "+p+" = validate.schema"+a+";"),n+="var "+h+";",d&&(n+=" if (schema"+i+" === undefined) "+h+" = true; else if (!Array.isArray(schema"+i+")) "+h+" = false; else {"),n+=h+" = false;for (var "+f+"=0; "+f+"<"+p+".length; "+f+"++) if (equal("+u+", "+p+"["+f+"])) { "+h+" = true; break; }",d&&(n+=" } "),n+=" if (!"+h+") { ";var m=m||[];m.push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'enum' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { allowedValues: schema"+i+" } ",!1!==t.opts.messages&&(n+=" , message: 'should be equal to one of the allowed values' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ";var g=n;return n=m.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+g+"]); ":n+=" validate.errors = ["+g+"]; return false; ":n+=" var err = "+g+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" }",c&&(n+=" else { "),n}},27152:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||"");if(!1===t.opts.format)return c&&(n+=" if (true) { "),n;var h,d=t.opts.$data&&o&&o.$data;d?(n+=" var schema"+i+" = "+t.util.getData(o.$data,s,t.dataPathArr)+"; ",h="schema"+i):h=o;var f=t.opts.unknownFormats,p=Array.isArray(f);if(d)n+=" var "+(m="format"+i)+" = formats["+h+"]; var "+(g="isObject"+i)+" = typeof "+m+" == 'object' && !("+m+" instanceof RegExp) && "+m+".validate; var "+(y="formatType"+i)+" = "+g+" && "+m+".type || 'string'; if ("+g+") { ",t.async&&(n+=" var async"+i+" = "+m+".async; "),n+=" "+m+" = "+m+".validate; } if ( ",d&&(n+=" ("+h+" !== undefined && typeof "+h+" != 'string') || "),n+=" (","ignore"!=f&&(n+=" ("+h+" && !"+m+" ",p&&(n+=" && self._opts.unknownFormats.indexOf("+h+") == -1 "),n+=") || "),n+=" ("+m+" && "+y+" == '"+r+"' && !(typeof "+m+" == 'function' ? ",t.async?n+=" (async"+i+" ? await "+m+"("+u+") : "+m+"("+u+")) ":n+=" "+m+"("+u+") ",n+=" : "+m+".test("+u+"))))) {";else{var m;if(!(m=t.formats[o])){if("ignore"==f)return t.logger.warn('unknown format "'+o+'" ignored in schema at path "'+t.errSchemaPath+'"'),c&&(n+=" if (true) { "),n;if(p&&f.indexOf(o)>=0)return c&&(n+=" if (true) { "),n;throw new Error('unknown format "'+o+'" is used in schema at path "'+t.errSchemaPath+'"')}var g,y=(g="object"==typeof m&&!(m instanceof RegExp)&&m.validate)&&m.type||"string";if(g){var v=!0===m.async;m=m.validate}if(y!=r)return c&&(n+=" if (true) { "),n;if(v){if(!t.async)throw new Error("async format in sync schema");n+=" if (!(await "+(_="formats"+t.util.getProperty(o)+".validate")+"("+u+"))) { "}else{n+=" if (! ";var _="formats"+t.util.getProperty(o);g&&(_+=".validate"),n+="function"==typeof m?" "+_+"("+u+") ":" "+_+".test("+u+") ",n+=") { "}}var b=b||[];b.push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'format' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { format: ",n+=d?""+h:""+t.util.toQuotedString(o),n+=" } ",!1!==t.opts.messages&&(n+=" , message: 'should match format \"",n+=d?"' + "+h+" + '":""+t.util.escapeQuotes(o),n+="\"' "),t.opts.verbose&&(n+=" , schema: ",n+=d?"validate.schema"+a:""+t.util.toQuotedString(o),n+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ";var w=n;return n=b.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+w+"]); ":n+=" validate.errors = ["+w+"]; return false; ":n+=" var err = "+w+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" } ",c&&(n+=" else { "),n}},72788:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="valid"+i,d="errs__"+i,f=t.util.copy(t);f.level++;var p="valid"+f.level,m=t.schema.then,g=t.schema.else,y=void 0!==m&&(t.opts.strictKeywords?"object"==typeof m&&Object.keys(m).length>0||!1===m:t.util.schemaHasRules(m,t.RULES.all)),v=void 0!==g&&(t.opts.strictKeywords?"object"==typeof g&&Object.keys(g).length>0||!1===g:t.util.schemaHasRules(g,t.RULES.all)),_=f.baseId;if(y||v){var b;f.createErrors=!1,f.schema=o,f.schemaPath=a,f.errSchemaPath=l,n+=" var "+d+" = errors; var "+h+" = true; ";var w=t.compositeRule;t.compositeRule=f.compositeRule=!0,n+=" "+t.validate(f)+" ",f.baseId=_,f.createErrors=!0,n+=" errors = "+d+"; if (vErrors !== null) { if ("+d+") vErrors.length = "+d+"; else vErrors = null; } ",t.compositeRule=f.compositeRule=w,y?(n+=" if ("+p+") { ",f.schema=t.schema.then,f.schemaPath=t.schemaPath+".then",f.errSchemaPath=t.errSchemaPath+"/then",n+=" "+t.validate(f)+" ",f.baseId=_,n+=" "+h+" = "+p+"; ",y&&v?n+=" var "+(b="ifClause"+i)+" = 'then'; ":b="'then'",n+=" } ",v&&(n+=" else { ")):n+=" if (!"+p+") { ",v&&(f.schema=t.schema.else,f.schemaPath=t.schemaPath+".else",f.errSchemaPath=t.errSchemaPath+"/else",n+=" "+t.validate(f)+" ",f.baseId=_,n+=" "+h+" = "+p+"; ",y&&v?n+=" var "+(b="ifClause"+i)+" = 'else'; ":b="'else'",n+=" } "),n+=" if (!"+h+") { var err = ",!1!==t.createErrors?(n+=" { keyword: 'if' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { failingKeyword: "+b+" } ",!1!==t.opts.messages&&(n+=" , message: 'should match \"' + "+b+" + '\" schema' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",n+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!t.compositeRule&&c&&(t.async?n+=" throw new ValidationError(vErrors); ":n+=" validate.errors = vErrors; return false; "),n+=" } ",c&&(n+=" else { ")}else c&&(n+=" if (true) { ");return n}},13131:(t,e,r)=>{"use strict";t.exports={$ref:r(91502),allOf:r(62753),anyOf:r(42024),$comment:r(29094),const:r(76816),contains:r(74010),dependencies:r(97478),enum:r(92982),format:r(27152),if:r(72788),items:r(66819),maximum:r(88363),minimum:r(88363),maxItems:r(81463),minItems:r(81463),maxLength:r(51103),minLength:r(51103),maxProperties:r(31106),minProperties:r(31106),multipleOf:r(46558),not:r(52658),oneOf:r(7774),pattern:r(34333),properties:r(42558),propertyNames:r(4728),required:r(20458),uniqueItems:r(87466),validate:r(19905)}},66819:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="valid"+i,d="errs__"+i,f=t.util.copy(t),p="";f.level++;var m="valid"+f.level,g="i"+i,y=f.dataLevel=t.dataLevel+1,v="data"+y,_=t.baseId;if(n+="var "+d+" = errors;var "+h+";",Array.isArray(o)){var b=t.schema.additionalItems;if(!1===b){n+=" "+h+" = "+u+".length <= "+o.length+"; ";var w=l;l=t.errSchemaPath+"/additionalItems",n+=" if (!"+h+") { ";var x=x||[];x.push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'additionalItems' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { limit: "+o.length+" } ",!1!==t.opts.messages&&(n+=" , message: 'should NOT have more than "+o.length+" items' "),t.opts.verbose&&(n+=" , schema: false , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ";var E=n;n=x.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+E+"]); ":n+=" validate.errors = ["+E+"]; return false; ":n+=" var err = "+E+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" } ",l=w,c&&(p+="}",n+=" else { ")}var S=o;if(S)for(var A,P=-1,T=S.length-1;P<T;)if(A=S[P+=1],t.opts.strictKeywords?"object"==typeof A&&Object.keys(A).length>0||!1===A:t.util.schemaHasRules(A,t.RULES.all)){n+=" "+m+" = true; if ("+u+".length > "+P+") { ";var C=u+"["+P+"]";f.schema=A,f.schemaPath=a+"["+P+"]",f.errSchemaPath=l+"/"+P,f.errorPath=t.util.getPathExpr(t.errorPath,P,t.opts.jsonPointers,!0),f.dataPathArr[y]=P;var M=t.validate(f);f.baseId=_,t.util.varOccurences(M,v)<2?n+=" "+t.util.varReplace(M,v,C)+" ":n+=" var "+v+" = "+C+"; "+M+" ",n+=" } ",c&&(n+=" if ("+m+") { ",p+="}")}"object"==typeof b&&(t.opts.strictKeywords?"object"==typeof b&&Object.keys(b).length>0||!1===b:t.util.schemaHasRules(b,t.RULES.all))&&(f.schema=b,f.schemaPath=t.schemaPath+".additionalItems",f.errSchemaPath=t.errSchemaPath+"/additionalItems",n+=" "+m+" = true; if ("+u+".length > "+o.length+") { for (var "+g+" = "+o.length+"; "+g+" < "+u+".length; "+g+"++) { ",f.errorPath=t.util.getPathExpr(t.errorPath,g,t.opts.jsonPointers,!0),C=u+"["+g+"]",f.dataPathArr[y]=g,M=t.validate(f),f.baseId=_,t.util.varOccurences(M,v)<2?n+=" "+t.util.varReplace(M,v,C)+" ":n+=" var "+v+" = "+C+"; "+M+" ",c&&(n+=" if (!"+m+") break; "),n+=" } } ",c&&(n+=" if ("+m+") { ",p+="}"))}else(t.opts.strictKeywords?"object"==typeof o&&Object.keys(o).length>0||!1===o:t.util.schemaHasRules(o,t.RULES.all))&&(f.schema=o,f.schemaPath=a,f.errSchemaPath=l,n+=" for (var "+g+" = 0; "+g+" < "+u+".length; "+g+"++) { ",f.errorPath=t.util.getPathExpr(t.errorPath,g,t.opts.jsonPointers,!0),C=u+"["+g+"]",f.dataPathArr[y]=g,M=t.validate(f),f.baseId=_,t.util.varOccurences(M,v)<2?n+=" "+t.util.varReplace(M,v,C)+" ":n+=" var "+v+" = "+C+"; "+M+" ",c&&(n+=" if (!"+m+") break; "),n+=" }");return c&&(n+=" "+p+" if ("+d+" == errors) {"),n}},46558:t=>{"use strict";t.exports=function(t,e,r){var n,i=" ",s=t.level,o=t.dataLevel,a=t.schema[e],l=t.schemaPath+t.util.getProperty(e),c=t.errSchemaPath+"/"+e,u=!t.opts.allErrors,h="data"+(o||""),d=t.opts.$data&&a&&a.$data;if(d?(i+=" var schema"+s+" = "+t.util.getData(a.$data,o,t.dataPathArr)+"; ",n="schema"+s):n=a,!d&&"number"!=typeof a)throw new Error(e+" must be number");i+="var division"+s+";if (",d&&(i+=" "+n+" !== undefined && ( typeof "+n+" != 'number' || "),i+=" (division"+s+" = "+h+" / "+n+", ",t.opts.multipleOfPrecision?i+=" Math.abs(Math.round(division"+s+") - division"+s+") > 1e-"+t.opts.multipleOfPrecision+" ":i+=" division"+s+" !== parseInt(division"+s+") ",i+=" ) ",d&&(i+=" ) "),i+=" ) { ";var f=f||[];f.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'multipleOf' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(c)+" , params: { multipleOf: "+n+" } ",!1!==t.opts.messages&&(i+=" , message: 'should be multiple of ",i+=d?"' + "+n:n+"'"),t.opts.verbose&&(i+=" , schema: ",i+=d?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var p=i;return i=f.pop(),!t.compositeRule&&u?t.async?i+=" throw new ValidationError(["+p+"]); ":i+=" validate.errors = ["+p+"]; return false; ":i+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+="} ",u&&(i+=" else { "),i}},52658:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="errs__"+i,d=t.util.copy(t);d.level++;var f="valid"+d.level;if(t.opts.strictKeywords?"object"==typeof o&&Object.keys(o).length>0||!1===o:t.util.schemaHasRules(o,t.RULES.all)){d.schema=o,d.schemaPath=a,d.errSchemaPath=l,n+=" var "+h+" = errors; ";var p,m=t.compositeRule;t.compositeRule=d.compositeRule=!0,d.createErrors=!1,d.opts.allErrors&&(p=d.opts.allErrors,d.opts.allErrors=!1),n+=" "+t.validate(d)+" ",d.createErrors=!0,p&&(d.opts.allErrors=p),t.compositeRule=d.compositeRule=m,n+=" if ("+f+") { ";var g=g||[];g.push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'not' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: {} ",!1!==t.opts.messages&&(n+=" , message: 'should NOT be valid' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ";var y=n;n=g.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+y+"]); ":n+=" validate.errors = ["+y+"]; return false; ":n+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" } else { errors = "+h+"; if (vErrors !== null) { if ("+h+") vErrors.length = "+h+"; else vErrors = null; } ",t.opts.allErrors&&(n+=" } ")}else n+=" var err = ",!1!==t.createErrors?(n+=" { keyword: 'not' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: {} ",!1!==t.opts.messages&&(n+=" , message: 'should NOT be valid' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",n+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",c&&(n+=" if (false) { ");return n}},7774:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="valid"+i,d="errs__"+i,f=t.util.copy(t),p="";f.level++;var m="valid"+f.level,g=f.baseId,y="prevValid"+i,v="passingSchemas"+i;n+="var "+d+" = errors , "+y+" = false , "+h+" = false , "+v+" = null; ";var _=t.compositeRule;t.compositeRule=f.compositeRule=!0;var b=o;if(b)for(var w,x=-1,E=b.length-1;x<E;)w=b[x+=1],(t.opts.strictKeywords?"object"==typeof w&&Object.keys(w).length>0||!1===w:t.util.schemaHasRules(w,t.RULES.all))?(f.schema=w,f.schemaPath=a+"["+x+"]",f.errSchemaPath=l+"/"+x,n+=" "+t.validate(f)+" ",f.baseId=g):n+=" var "+m+" = true; ",x&&(n+=" if ("+m+" && "+y+") { "+h+" = false; "+v+" = ["+v+", "+x+"]; } else { ",p+="}"),n+=" if ("+m+") { "+h+" = "+y+" = true; "+v+" = "+x+"; }";return t.compositeRule=f.compositeRule=_,n+=p+"if (!"+h+") { var err = ",!1!==t.createErrors?(n+=" { keyword: 'oneOf' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { passingSchemas: "+v+" } ",!1!==t.opts.messages&&(n+=" , message: 'should match exactly one schema in oneOf' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",n+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!t.compositeRule&&c&&(t.async?n+=" throw new ValidationError(vErrors); ":n+=" validate.errors = vErrors; return false; "),n+="} else { errors = "+d+"; if (vErrors !== null) { if ("+d+") vErrors.length = "+d+"; else vErrors = null; }",t.opts.allErrors&&(n+=" } "),n}},34333:t=>{"use strict";t.exports=function(t,e,r){var n,i=" ",s=t.level,o=t.dataLevel,a=t.schema[e],l=t.schemaPath+t.util.getProperty(e),c=t.errSchemaPath+"/"+e,u=!t.opts.allErrors,h="data"+(o||""),d=t.opts.$data&&a&&a.$data;d?(i+=" var schema"+s+" = "+t.util.getData(a.$data,o,t.dataPathArr)+"; ",n="schema"+s):n=a,i+="if ( ",d&&(i+=" ("+n+" !== undefined && typeof "+n+" != 'string') || "),i+=" !"+(d?"(new RegExp("+n+"))":t.usePattern(a))+".test("+h+") ) { ";var f=f||[];f.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'pattern' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(c)+" , params: { pattern: ",i+=d?""+n:""+t.util.toQuotedString(a),i+=" } ",!1!==t.opts.messages&&(i+=" , message: 'should match pattern \"",i+=d?"' + "+n+" + '":""+t.util.escapeQuotes(a),i+="\"' "),t.opts.verbose&&(i+=" , schema: ",i+=d?"validate.schema"+l:""+t.util.toQuotedString(a),i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var p=i;return i=f.pop(),!t.compositeRule&&u?t.async?i+=" throw new ValidationError(["+p+"]); ":i+=" validate.errors = ["+p+"]; return false; ":i+=" var err = "+p+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+="} ",u&&(i+=" else { "),i}},42558:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="errs__"+i,d=t.util.copy(t),f="";d.level++;var p="valid"+d.level,m="key"+i,g="idx"+i,y=d.dataLevel=t.dataLevel+1,v="data"+y,_="dataProperties"+i,b=Object.keys(o||{}).filter(I),w=t.schema.patternProperties||{},x=Object.keys(w).filter(I),E=t.schema.additionalProperties,S=b.length||x.length,A=!1===E,P="object"==typeof E&&Object.keys(E).length,T=t.opts.removeAdditional,C=A||P||T,M=t.opts.ownProperties,O=t.baseId,R=t.schema.required;if(R&&(!t.opts.$data||!R.$data)&&R.length<t.opts.loopRequired)var D=t.util.toHash(R);function I(t){return"__proto__"!==t}if(n+="var "+h+" = errors;var "+p+" = true;",M&&(n+=" var "+_+" = undefined;"),C){if(n+=M?" "+_+" = "+_+" || Object.keys("+u+"); for (var "+g+"=0; "+g+"<"+_+".length; "+g+"++) { var "+m+" = "+_+"["+g+"]; ":" for (var "+m+" in "+u+") { ",S){if(n+=" var isAdditional"+i+" = !(false ",b.length)if(b.length>8)n+=" || validate.schema"+a+".hasOwnProperty("+m+") ";else{var k=b;if(k)for(var L=-1,F=k.length-1;L<F;)Y=k[L+=1],n+=" || "+m+" == "+t.util.toQuotedString(Y)+" "}if(x.length){var j=x;if(j)for(var N=-1,G=j.length-1;N<G;)st=j[N+=1],n+=" || "+t.usePattern(st)+".test("+m+") "}n+=" ); if (isAdditional"+i+") { "}if("all"==T)n+=" delete "+u+"["+m+"]; ";else{var $=t.errorPath,z="' + "+m+" + '";if(t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPathExpr(t.errorPath,m,t.opts.jsonPointers)),A)if(T)n+=" delete "+u+"["+m+"]; ";else{n+=" "+p+" = false; ";var U=l;l=t.errSchemaPath+"/additionalProperties",(rt=rt||[]).push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'additionalProperties' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { additionalProperty: '"+z+"' } ",!1!==t.opts.messages&&(n+=" , message: '",t.opts._errorDataPathProperty?n+="is an invalid additional property":n+="should NOT have additional properties",n+="' "),t.opts.verbose&&(n+=" , schema: false , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ";var B=n;n=rt.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+B+"]); ":n+=" validate.errors = ["+B+"]; return false; ":n+=" var err = "+B+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",l=U,c&&(n+=" break; ")}else if(P)if("failing"==T){n+=" var "+h+" = errors; ";var V=t.compositeRule;t.compositeRule=d.compositeRule=!0,d.schema=E,d.schemaPath=t.schemaPath+".additionalProperties",d.errSchemaPath=t.errSchemaPath+"/additionalProperties",d.errorPath=t.opts._errorDataPathProperty?t.errorPath:t.util.getPathExpr(t.errorPath,m,t.opts.jsonPointers);var q=u+"["+m+"]";d.dataPathArr[y]=m;var K=t.validate(d);d.baseId=O,t.util.varOccurences(K,v)<2?n+=" "+t.util.varReplace(K,v,q)+" ":n+=" var "+v+" = "+q+"; "+K+" ",n+=" if (!"+p+") { errors = "+h+"; if (validate.errors !== null) { if (errors) validate.errors.length = errors; else validate.errors = null; } delete "+u+"["+m+"]; } ",t.compositeRule=d.compositeRule=V}else d.schema=E,d.schemaPath=t.schemaPath+".additionalProperties",d.errSchemaPath=t.errSchemaPath+"/additionalProperties",d.errorPath=t.opts._errorDataPathProperty?t.errorPath:t.util.getPathExpr(t.errorPath,m,t.opts.jsonPointers),q=u+"["+m+"]",d.dataPathArr[y]=m,K=t.validate(d),d.baseId=O,t.util.varOccurences(K,v)<2?n+=" "+t.util.varReplace(K,v,q)+" ":n+=" var "+v+" = "+q+"; "+K+" ",c&&(n+=" if (!"+p+") break; ");t.errorPath=$}S&&(n+=" } "),n+=" } ",c&&(n+=" if ("+p+") { ",f+="}")}var W=t.opts.useDefaults&&!t.compositeRule;if(b.length){var H=b;if(H)for(var Y,X=-1,Z=H.length-1;X<Z;){var J=o[Y=H[X+=1]];if(t.opts.strictKeywords?"object"==typeof J&&Object.keys(J).length>0||!1===J:t.util.schemaHasRules(J,t.RULES.all)){var Q=t.util.getProperty(Y),tt=(q=u+Q,W&&void 0!==J.default);if(d.schema=J,d.schemaPath=a+Q,d.errSchemaPath=l+"/"+t.util.escapeFragment(Y),d.errorPath=t.util.getPath(t.errorPath,Y,t.opts.jsonPointers),d.dataPathArr[y]=t.util.toQuotedString(Y),K=t.validate(d),d.baseId=O,t.util.varOccurences(K,v)<2){K=t.util.varReplace(K,v,q);var et=q}else et=v,n+=" var "+v+" = "+q+"; ";if(tt)n+=" "+K+" ";else{if(D&&D[Y]){n+=" if ( "+et+" === undefined ",M&&(n+=" || ! Object.prototype.hasOwnProperty.call("+u+", '"+t.util.escapeQuotes(Y)+"') "),n+=") { "+p+" = false; ",$=t.errorPath,U=l;var rt,nt=t.util.escapeQuotes(Y);t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPath($,Y,t.opts.jsonPointers)),l=t.errSchemaPath+"/required",(rt=rt||[]).push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { missingProperty: '"+nt+"' } ",!1!==t.opts.messages&&(n+=" , message: '",t.opts._errorDataPathProperty?n+="is a required property":n+="should have required property \\'"+nt+"\\'",n+="' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",B=n,n=rt.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+B+"]); ":n+=" validate.errors = ["+B+"]; return false; ":n+=" var err = "+B+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",l=U,t.errorPath=$,n+=" } else { "}else c?(n+=" if ( "+et+" === undefined ",M&&(n+=" || ! Object.prototype.hasOwnProperty.call("+u+", '"+t.util.escapeQuotes(Y)+"') "),n+=") { "+p+" = true; } else { "):(n+=" if ("+et+" !== undefined ",M&&(n+=" && Object.prototype.hasOwnProperty.call("+u+", '"+t.util.escapeQuotes(Y)+"') "),n+=" ) { ");n+=" "+K+" } "}}c&&(n+=" if ("+p+") { ",f+="}")}}if(x.length){var it=x;if(it)for(var st,ot=-1,at=it.length-1;ot<at;)J=w[st=it[ot+=1]],(t.opts.strictKeywords?"object"==typeof J&&Object.keys(J).length>0||!1===J:t.util.schemaHasRules(J,t.RULES.all))&&(d.schema=J,d.schemaPath=t.schemaPath+".patternProperties"+t.util.getProperty(st),d.errSchemaPath=t.errSchemaPath+"/patternProperties/"+t.util.escapeFragment(st),n+=M?" "+_+" = "+_+" || Object.keys("+u+"); for (var "+g+"=0; "+g+"<"+_+".length; "+g+"++) { var "+m+" = "+_+"["+g+"]; ":" for (var "+m+" in "+u+") { ",n+=" if ("+t.usePattern(st)+".test("+m+")) { ",d.errorPath=t.util.getPathExpr(t.errorPath,m,t.opts.jsonPointers),q=u+"["+m+"]",d.dataPathArr[y]=m,K=t.validate(d),d.baseId=O,t.util.varOccurences(K,v)<2?n+=" "+t.util.varReplace(K,v,q)+" ":n+=" var "+v+" = "+q+"; "+K+" ",c&&(n+=" if (!"+p+") break; "),n+=" } ",c&&(n+=" else "+p+" = true; "),n+=" } ",c&&(n+=" if ("+p+") { ",f+="}"))}return c&&(n+=" "+f+" if ("+h+" == errors) {"),n}},4728:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="errs__"+i,d=t.util.copy(t);d.level++;var f="valid"+d.level;if(n+="var "+h+" = errors;",t.opts.strictKeywords?"object"==typeof o&&Object.keys(o).length>0||!1===o:t.util.schemaHasRules(o,t.RULES.all)){d.schema=o,d.schemaPath=a,d.errSchemaPath=l;var p="key"+i,m="idx"+i,g="i"+i,y="' + "+p+" + '",v="data"+(d.dataLevel=t.dataLevel+1),_="dataProperties"+i,b=t.opts.ownProperties,w=t.baseId;b&&(n+=" var "+_+" = undefined; "),n+=b?" "+_+" = "+_+" || Object.keys("+u+"); for (var "+m+"=0; "+m+"<"+_+".length; "+m+"++) { var "+p+" = "+_+"["+m+"]; ":" for (var "+p+" in "+u+") { ",n+=" var startErrs"+i+" = errors; ";var x=p,E=t.compositeRule;t.compositeRule=d.compositeRule=!0;var S=t.validate(d);d.baseId=w,t.util.varOccurences(S,v)<2?n+=" "+t.util.varReplace(S,v,x)+" ":n+=" var "+v+" = "+x+"; "+S+" ",t.compositeRule=d.compositeRule=E,n+=" if (!"+f+") { for (var "+g+"=startErrs"+i+"; "+g+"<errors; "+g+"++) { vErrors["+g+"].propertyName = "+p+"; } var err = ",!1!==t.createErrors?(n+=" { keyword: 'propertyNames' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { propertyName: '"+y+"' } ",!1!==t.opts.messages&&(n+=" , message: 'property name \\'"+y+"\\' is invalid' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",n+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!t.compositeRule&&c&&(t.async?n+=" throw new ValidationError(vErrors); ":n+=" validate.errors = vErrors; return false; "),c&&(n+=" break; "),n+=" } }"}return c&&(n+=" if ("+h+" == errors) {"),n}},91502:t=>{"use strict";t.exports=function(t,e,r){var n,i,s=" ",o=t.level,a=t.dataLevel,l=t.schema[e],c=t.errSchemaPath+"/"+e,u=!t.opts.allErrors,h="data"+(a||""),d="valid"+o;if("#"==l||"#/"==l)t.isRoot?(n=t.async,i="validate"):(n=!0===t.root.schema.$async,i="root.refVal[0]");else{var f=t.resolveRef(t.baseId,l,t.isRoot);if(void 0===f){var p=t.MissingRefError.message(t.baseId,l);if("fail"==t.opts.missingRefs){t.logger.error(p),(v=v||[]).push(s),s="",!1!==t.createErrors?(s+=" { keyword: '$ref' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(c)+" , params: { ref: '"+t.util.escapeQuotes(l)+"' } ",!1!==t.opts.messages&&(s+=" , message: 'can\\'t resolve reference "+t.util.escapeQuotes(l)+"' "),t.opts.verbose&&(s+=" , schema: "+t.util.toQuotedString(l)+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),s+=" } "):s+=" {} ";var m=s;s=v.pop(),!t.compositeRule&&u?t.async?s+=" throw new ValidationError(["+m+"]); ":s+=" validate.errors = ["+m+"]; return false; ":s+=" var err = "+m+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u&&(s+=" if (false) { ")}else{if("ignore"!=t.opts.missingRefs)throw new t.MissingRefError(t.baseId,l,p);t.logger.warn(p),u&&(s+=" if (true) { ")}}else if(f.inline){var g=t.util.copy(t);g.level++;var y="valid"+g.level;g.schema=f.schema,g.schemaPath="",g.errSchemaPath=l,s+=" "+t.validate(g).replace(/validate\.schema/g,f.code)+" ",u&&(s+=" if ("+y+") { ")}else n=!0===f.$async||t.async&&!1!==f.$async,i=f.code}if(i){var v;(v=v||[]).push(s),s="",t.opts.passContext?s+=" "+i+".call(this, ":s+=" "+i+"( ",s+=" "+h+", (dataPath || '')",'""'!=t.errorPath&&(s+=" + "+t.errorPath);var _=s+=" , "+(a?"data"+(a-1||""):"parentData")+" , "+(a?t.dataPathArr[a]:"parentDataProperty")+", rootData) ";if(s=v.pop(),n){if(!t.async)throw new Error("async schema referenced by sync schema");u&&(s+=" var "+d+"; "),s+=" try { await "+_+"; ",u&&(s+=" "+d+" = true; "),s+=" } catch (e) { if (!(e instanceof ValidationError)) throw e; if (vErrors === null) vErrors = e.errors; else vErrors = vErrors.concat(e.errors); errors = vErrors.length; ",u&&(s+=" "+d+" = false; "),s+=" } ",u&&(s+=" if ("+d+") { ")}else s+=" if (!"+_+") { if (vErrors === null) vErrors = "+i+".errors; else vErrors = vErrors.concat("+i+".errors); errors = vErrors.length; } ",u&&(s+=" else { ")}return s}},20458:t=>{"use strict";t.exports=function(t,e,r){var n=" ",i=t.level,s=t.dataLevel,o=t.schema[e],a=t.schemaPath+t.util.getProperty(e),l=t.errSchemaPath+"/"+e,c=!t.opts.allErrors,u="data"+(s||""),h="valid"+i,d=t.opts.$data&&o&&o.$data;d&&(n+=" var schema"+i+" = "+t.util.getData(o.$data,s,t.dataPathArr)+"; ");var f="schema"+i;if(!d)if(o.length<t.opts.loopRequired&&t.schema.properties&&Object.keys(t.schema.properties).length){var p=[],m=o;if(m)for(var g,y=-1,v=m.length-1;y<v;){g=m[y+=1];var _=t.schema.properties[g];_&&(t.opts.strictKeywords?"object"==typeof _&&Object.keys(_).length>0||!1===_:t.util.schemaHasRules(_,t.RULES.all))||(p[p.length]=g)}}else p=o;if(d||p.length){var b=t.errorPath,w=d||p.length>=t.opts.loopRequired,x=t.opts.ownProperties;if(c)if(n+=" var missing"+i+"; ",w){d||(n+=" var "+f+" = validate.schema"+a+"; ");var E="' + "+(M="schema"+i+"["+(T="i"+i)+"]")+" + '";t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPathExpr(b,M,t.opts.jsonPointers)),n+=" var "+h+" = true; ",d&&(n+=" if (schema"+i+" === undefined) "+h+" = true; else if (!Array.isArray(schema"+i+")) "+h+" = false; else {"),n+=" for (var "+T+" = 0; "+T+" < "+f+".length; "+T+"++) { "+h+" = "+u+"["+f+"["+T+"]] !== undefined ",x&&(n+=" && Object.prototype.hasOwnProperty.call("+u+", "+f+"["+T+"]) "),n+="; if (!"+h+") break; } ",d&&(n+=" } "),n+=" if (!"+h+") { ",(A=A||[]).push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { missingProperty: '"+E+"' } ",!1!==t.opts.messages&&(n+=" , message: '",t.opts._errorDataPathProperty?n+="is a required property":n+="should have required property \\'"+E+"\\'",n+="' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ";var S=n;n=A.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+S+"]); ":n+=" validate.errors = ["+S+"]; return false; ":n+=" var err = "+S+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" } else { "}else{n+=" if ( ";var A,P=p;if(P)for(var T=-1,C=P.length-1;T<C;)R=P[T+=1],T&&(n+=" || "),n+=" ( ( "+(L=u+(k=t.util.getProperty(R)))+" === undefined ",x&&(n+=" || ! Object.prototype.hasOwnProperty.call("+u+", '"+t.util.escapeQuotes(R)+"') "),n+=") && (missing"+i+" = "+t.util.toQuotedString(t.opts.jsonPointers?R:k)+") ) ";n+=") { ",E="' + "+(M="missing"+i)+" + '",t.opts._errorDataPathProperty&&(t.errorPath=t.opts.jsonPointers?t.util.getPathExpr(b,M,!0):b+" + "+M),(A=A||[]).push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { missingProperty: '"+E+"' } ",!1!==t.opts.messages&&(n+=" , message: '",t.opts._errorDataPathProperty?n+="is a required property":n+="should have required property \\'"+E+"\\'",n+="' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",S=n,n=A.pop(),!t.compositeRule&&c?t.async?n+=" throw new ValidationError(["+S+"]); ":n+=" validate.errors = ["+S+"]; return false; ":n+=" var err = "+S+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" } else { "}else if(w){var M;d||(n+=" var "+f+" = validate.schema"+a+"; "),E="' + "+(M="schema"+i+"["+(T="i"+i)+"]")+" + '",t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPathExpr(b,M,t.opts.jsonPointers)),d&&(n+=" if ("+f+" && !Array.isArray("+f+")) { var err = ",!1!==t.createErrors?(n+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { missingProperty: '"+E+"' } ",!1!==t.opts.messages&&(n+=" , message: '",t.opts._errorDataPathProperty?n+="is a required property":n+="should have required property \\'"+E+"\\'",n+="' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",n+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } else if ("+f+" !== undefined) { "),n+=" for (var "+T+" = 0; "+T+" < "+f+".length; "+T+"++) { if ("+u+"["+f+"["+T+"]] === undefined ",x&&(n+=" || ! Object.prototype.hasOwnProperty.call("+u+", "+f+"["+T+"]) "),n+=") { var err = ",!1!==t.createErrors?(n+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { missingProperty: '"+E+"' } ",!1!==t.opts.messages&&(n+=" , message: '",t.opts._errorDataPathProperty?n+="is a required property":n+="should have required property \\'"+E+"\\'",n+="' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",n+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } } ",d&&(n+=" } ")}else{var O=p;if(O)for(var R,D=-1,I=O.length-1;D<I;){R=O[D+=1];var k=t.util.getProperty(R),L=(E=t.util.escapeQuotes(R),u+k);t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPath(b,R,t.opts.jsonPointers)),n+=" if ( "+L+" === undefined ",x&&(n+=" || ! Object.prototype.hasOwnProperty.call("+u+", '"+t.util.escapeQuotes(R)+"') "),n+=") { var err = ",!1!==t.createErrors?(n+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { missingProperty: '"+E+"' } ",!1!==t.opts.messages&&(n+=" , message: '",t.opts._errorDataPathProperty?n+="is a required property":n+="should have required property \\'"+E+"\\'",n+="' "),t.opts.verbose&&(n+=" , schema: validate.schema"+a+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+u+" "),n+=" } "):n+=" {} ",n+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}t.errorPath=b}else c&&(n+=" if (true) {");return n}},87466:t=>{"use strict";t.exports=function(t,e,r){var n,i=" ",s=t.level,o=t.dataLevel,a=t.schema[e],l=t.schemaPath+t.util.getProperty(e),c=t.errSchemaPath+"/"+e,u=!t.opts.allErrors,h="data"+(o||""),d="valid"+s,f=t.opts.$data&&a&&a.$data;if(f?(i+=" var schema"+s+" = "+t.util.getData(a.$data,o,t.dataPathArr)+"; ",n="schema"+s):n=a,(a||f)&&!1!==t.opts.uniqueItems){f&&(i+=" var "+d+"; if ("+n+" === false || "+n+" === undefined) "+d+" = true; else if (typeof "+n+" != 'boolean') "+d+" = false; else { "),i+=" var i = "+h+".length , "+d+" = true , j; if (i > 1) { ";var p=t.schema.items&&t.schema.items.type,m=Array.isArray(p);if(!p||"object"==p||"array"==p||m&&(p.indexOf("object")>=0||p.indexOf("array")>=0))i+=" outer: for (;i--;) { for (j = i; j--;) { if (equal("+h+"[i], "+h+"[j])) { "+d+" = false; break outer; } } } ";else{i+=" var itemIndices = {}, item; for (;i--;) { var item = "+h+"[i]; ";var g="checkDataType"+(m?"s":"");i+=" if ("+t.util[g](p,"item",t.opts.strictNumbers,!0)+") continue; ",m&&(i+=" if (typeof item == 'string') item = '\"' + item; "),i+=" if (typeof itemIndices[item] == 'number') { "+d+" = false; j = itemIndices[item]; break; } itemIndices[item] = i; } "}i+=" } ",f&&(i+=" } "),i+=" if (!"+d+") { ";var y=y||[];y.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'uniqueItems' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(c)+" , params: { i: i, j: j } ",!1!==t.opts.messages&&(i+=" , message: 'should NOT have duplicate items (items ## ' + j + ' and ' + i + ' are identical)' "),t.opts.verbose&&(i+=" , schema: ",i+=f?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var v=i;i=y.pop(),!t.compositeRule&&u?t.async?i+=" throw new ValidationError(["+v+"]); ":i+=" validate.errors = ["+v+"]; return false; ":i+=" var err = "+v+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } ",u&&(i+=" else { ")}else u&&(i+=" if (true) { ");return i}},19905:t=>{"use strict";t.exports=function(t,e,r){var n="",i=!0===t.schema.$async,s=t.util.schemaHasRulesExcept(t.schema,t.RULES.all,"$ref"),o=t.self._getId(t.schema);if(t.opts.strictKeywords){var a=t.util.schemaUnknownRules(t.schema,t.RULES.keywords);if(a){var l="unknown keyword: "+a;if("log"!==t.opts.strictKeywords)throw new Error(l);t.logger.warn(l)}}if(t.isTop&&(n+=" var validate = ",i&&(t.async=!0,n+="async "),n+="function(data, dataPath, parentData, parentDataProperty, rootData) { 'use strict'; ",o&&(t.opts.sourceCode||t.opts.processCode)&&(n+=" /*# sourceURL="+o+" */ ")),"boolean"==typeof t.schema||!s&&!t.schema.$ref){e="false schema";var c=t.level,u=t.dataLevel,h=t.schema[e],d=t.schemaPath+t.util.getProperty(e),f=t.errSchemaPath+"/"+e,p=!t.opts.allErrors,m="data"+(u||""),g="valid"+c;if(!1===t.schema){t.isTop?p=!0:n+=" var "+g+" = false; ",(q=q||[]).push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'false schema' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(f)+" , params: {} ",!1!==t.opts.messages&&(n+=" , message: 'boolean schema is false' "),t.opts.verbose&&(n+=" , schema: false , parentSchema: validate.schema"+t.schemaPath+" , data: "+m+" "),n+=" } "):n+=" {} ";var y=n;n=q.pop(),!t.compositeRule&&p?t.async?n+=" throw new ValidationError(["+y+"]); ":n+=" validate.errors = ["+y+"]; return false; ":n+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else t.isTop?n+=i?" return data; ":" validate.errors = null; return true; ":n+=" var "+g+" = true; ";return t.isTop&&(n+=" }; return validate; "),n}if(t.isTop){var v=t.isTop;if(c=t.level=0,u=t.dataLevel=0,m="data",t.rootId=t.resolve.fullPath(t.self._getId(t.root.schema)),t.baseId=t.baseId||t.rootId,delete t.isTop,t.dataPathArr=[""],void 0!==t.schema.default&&t.opts.useDefaults&&t.opts.strictDefaults){var _="default is ignored in the schema root";if("log"!==t.opts.strictDefaults)throw new Error(_);t.logger.warn(_)}n+=" var vErrors = null; ",n+=" var errors = 0; ",n+=" if (rootData === undefined) rootData = data; "}else{if(c=t.level,m="data"+((u=t.dataLevel)||""),o&&(t.baseId=t.resolve.url(t.baseId,o)),i&&!t.async)throw new Error("async schema in sync schema");n+=" var errs_"+c+" = errors;"}g="valid"+c,p=!t.opts.allErrors;var b="",w="",x=t.schema.type,E=Array.isArray(x);if(x&&t.opts.nullable&&!0===t.schema.nullable&&(E?-1==x.indexOf("null")&&(x=x.concat("null")):"null"!=x&&(x=[x,"null"],E=!0)),E&&1==x.length&&(x=x[0],E=!1),t.schema.$ref&&s){if("fail"==t.opts.extendRefs)throw new Error('$ref: validation keywords used in schema at path "'+t.errSchemaPath+'" (see option extendRefs)');!0!==t.opts.extendRefs&&(s=!1,t.logger.warn('$ref: keywords ignored in schema at path "'+t.errSchemaPath+'"'))}if(t.schema.$comment&&t.opts.$comment&&(n+=" "+t.RULES.all.$comment.code(t,"$comment")),x){if(t.opts.coerceTypes)var S=t.util.coerceToTypes(t.opts.coerceTypes,x);var A=t.RULES.types[x];if(S||E||!0===A||A&&!Z(A)){d=t.schemaPath+".type",f=t.errSchemaPath+"/type",d=t.schemaPath+".type",f=t.errSchemaPath+"/type";var P=E?"checkDataTypes":"checkDataType";if(n+=" if ("+t.util[P](x,m,t.opts.strictNumbers,!0)+") { ",S){var T="dataType"+c,C="coerced"+c;n+=" var "+T+" = typeof "+m+"; var "+C+" = undefined; ","array"==t.opts.coerceTypes&&(n+=" if ("+T+" == 'object' && Array.isArray("+m+") && "+m+".length == 1) { "+m+" = "+m+"[0]; "+T+" = typeof "+m+"; if ("+t.util.checkDataType(t.schema.type,m,t.opts.strictNumbers)+") "+C+" = "+m+"; } "),n+=" if ("+C+" !== undefined) ; ";var M=S;if(M)for(var O,R=-1,D=M.length-1;R<D;)"string"==(O=M[R+=1])?n+=" else if ("+T+" == 'number' || "+T+" == 'boolean') "+C+" = '' + "+m+"; else if ("+m+" === null) "+C+" = ''; ":"number"==O||"integer"==O?(n+=" else if ("+T+" == 'boolean' || "+m+" === null || ("+T+" == 'string' && "+m+" && "+m+" == +"+m+" ","integer"==O&&(n+=" && !("+m+" % 1)"),n+=")) "+C+" = +"+m+"; "):"boolean"==O?n+=" else if ("+m+" === 'false' || "+m+" === 0 || "+m+" === null) "+C+" = false; else if ("+m+" === 'true' || "+m+" === 1) "+C+" = true; ":"null"==O?n+=" else if ("+m+" === '' || "+m+" === 0 || "+m+" === false) "+C+" = null; ":"array"==t.opts.coerceTypes&&"array"==O&&(n+=" else if ("+T+" == 'string' || "+T+" == 'number' || "+T+" == 'boolean' || "+m+" == null) "+C+" = ["+m+"]; ");n+=" else { ",(q=q||[]).push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'type' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(f)+" , params: { type: '",n+=E?""+x.join(","):""+x,n+="' } ",!1!==t.opts.messages&&(n+=" , message: 'should be ",n+=E?""+x.join(","):""+x,n+="' "),t.opts.verbose&&(n+=" , schema: validate.schema"+d+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+m+" "),n+=" } "):n+=" {} ",y=n,n=q.pop(),!t.compositeRule&&p?t.async?n+=" throw new ValidationError(["+y+"]); ":n+=" validate.errors = ["+y+"]; return false; ":n+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" } if ("+C+" !== undefined) { ";var I=u?"data"+(u-1||""):"parentData";n+=" "+m+" = "+C+"; ",u||(n+="if ("+I+" !== undefined)"),n+=" "+I+"["+(u?t.dataPathArr[u]:"parentDataProperty")+"] = "+C+"; } "}else(q=q||[]).push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'type' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(f)+" , params: { type: '",n+=E?""+x.join(","):""+x,n+="' } ",!1!==t.opts.messages&&(n+=" , message: 'should be ",n+=E?""+x.join(","):""+x,n+="' "),t.opts.verbose&&(n+=" , schema: validate.schema"+d+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+m+" "),n+=" } "):n+=" {} ",y=n,n=q.pop(),!t.compositeRule&&p?t.async?n+=" throw new ValidationError(["+y+"]); ":n+=" validate.errors = ["+y+"]; return false; ":n+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";n+=" } "}}if(t.schema.$ref&&!s)n+=" "+t.RULES.all.$ref.code(t,"$ref")+" ",p&&(n+=" } if (errors === ",n+=v?"0":"errs_"+c,n+=") { ",w+="}");else{var k=t.RULES;if(k)for(var L=-1,F=k.length-1;L<F;)if(Z(A=k[L+=1])){if(A.type&&(n+=" if ("+t.util.checkDataType(A.type,m,t.opts.strictNumbers)+") { "),t.opts.useDefaults)if("object"==A.type&&t.schema.properties){h=t.schema.properties;var j=Object.keys(h);if(j)for(var N,G=-1,$=j.length-1;G<$;)if(void 0!==(B=h[N=j[G+=1]]).default){var z=m+t.util.getProperty(N);if(t.compositeRule){if(t.opts.strictDefaults){if(_="default is ignored for: "+z,"log"!==t.opts.strictDefaults)throw new Error(_);t.logger.warn(_)}}else n+=" if ("+z+" === undefined ","empty"==t.opts.useDefaults&&(n+=" || "+z+" === null || "+z+" === '' "),n+=" ) "+z+" = ","shared"==t.opts.useDefaults?n+=" "+t.useDefault(B.default)+" ":n+=" "+JSON.stringify(B.default)+" ",n+="; "}}else if("array"==A.type&&Array.isArray(t.schema.items)){var U=t.schema.items;if(U){R=-1;for(var B,V=U.length-1;R<V;)if(void 0!==(B=U[R+=1]).default)if(z=m+"["+R+"]",t.compositeRule){if(t.opts.strictDefaults){if(_="default is ignored for: "+z,"log"!==t.opts.strictDefaults)throw new Error(_);t.logger.warn(_)}}else n+=" if ("+z+" === undefined ","empty"==t.opts.useDefaults&&(n+=" || "+z+" === null || "+z+" === '' "),n+=" ) "+z+" = ","shared"==t.opts.useDefaults?n+=" "+t.useDefault(B.default)+" ":n+=" "+JSON.stringify(B.default)+" ",n+="; "}}var q,K=A.rules;if(K)for(var W,H=-1,Y=K.length-1;H<Y;)if(J(W=K[H+=1])){var X=W.code(t,W.keyword,A.type);X&&(n+=" "+X+" ",p&&(b+="}"))}if(p&&(n+=" "+b+" ",b=""),A.type&&(n+=" } ",x&&x===A.type&&!S))n+=" else { ",d=t.schemaPath+".type",f=t.errSchemaPath+"/type",(q=q||[]).push(n),n="",!1!==t.createErrors?(n+=" { keyword: 'type' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(f)+" , params: { type: '",n+=E?""+x.join(","):""+x,n+="' } ",!1!==t.opts.messages&&(n+=" , message: 'should be ",n+=E?""+x.join(","):""+x,n+="' "),t.opts.verbose&&(n+=" , schema: validate.schema"+d+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+m+" "),n+=" } "):n+=" {} ",y=n,n=q.pop(),!t.compositeRule&&p?t.async?n+=" throw new ValidationError(["+y+"]); ":n+=" validate.errors = ["+y+"]; return false; ":n+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",n+=" } ";p&&(n+=" if (errors === ",n+=v?"0":"errs_"+c,n+=") { ",w+="}")}}function Z(t){for(var e=t.rules,r=0;r<e.length;r++)if(J(e[r]))return!0}function J(e){return void 0!==t.schema[e.keyword]||e.implements&&function(e){for(var r=e.implements,n=0;n<r.length;n++)if(void 0!==t.schema[r[n]])return!0}(e)}return p&&(n+=" "+w+" "),v?(i?(n+=" if (errors === 0) return data; ",n+=" else throw new ValidationError(vErrors); "):(n+=" validate.errors = vErrors; ",n+=" return errors === 0; "),n+=" }; return validate;"):n+=" var "+g+" = errors === errs_"+c+";",n}},22755:(t,e,r)=>{"use strict";var n=/^[a-z_$][a-z0-9_$-]*$/i,i=r(36088),s=r(27569);t.exports={add:function(t,e){var r=this.RULES;if(r.keywords[t])throw new Error("Keyword "+t+" is already defined");if(!n.test(t))throw new Error("Keyword "+t+" is not a valid identifier");if(e){this.validateKeyword(e,!0);var s=e.type;if(Array.isArray(s))for(var o=0;o<s.length;o++)l(t,s[o],e);else l(t,s,e);var a=e.metaSchema;a&&(e.$data&&this._opts.$data&&(a={anyOf:[a,{$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"}]}),e.validateSchema=this.compile(a,!0))}function l(t,e,n){for(var s,o=0;o<r.length;o++){var a=r[o];if(a.type==e){s=a;break}}s||(s={type:e,rules:[]},r.push(s));var l={keyword:t,definition:n,custom:!0,code:i,implements:n.implements};s.rules.push(l),r.custom[t]=l}return r.keywords[t]=r.all[t]=!0,this},get:function(t){var e=this.RULES.custom[t];return e?e.definition:this.RULES.keywords[t]||!1},remove:function(t){var e=this.RULES;delete e.keywords[t],delete e.all[t],delete e.custom[t];for(var r=0;r<e.length;r++)for(var n=e[r].rules,i=0;i<n.length;i++)if(n[i].keyword==t){n.splice(i,1);break}return this},validate:function t(e,r){t.errors=null;var n=this._validateKeyword=this._validateKeyword||this.compile(s,!0);if(n(e))return!0;if(t.errors=n.errors,r)throw new Error("custom keyword definition is invalid: "+this.errorsText(n.errors));return!1}}},86850:t=>{"use strict";var e=t.exports=function(t,e,n){"function"==typeof e&&(n=e,e={}),r(e,"function"==typeof(n=e.cb||n)?n:n.pre||function(){},n.post||function(){},t,"",t)};function r(t,n,i,s,o,a,l,c,u,h){if(s&&"object"==typeof s&&!Array.isArray(s)){for(var d in n(s,o,a,l,c,u,h),s){var f=s[d];if(Array.isArray(f)){if(d in e.arrayKeywords)for(var p=0;p<f.length;p++)r(t,n,i,f[p],o+"/"+d+"/"+p,a,o,d,s,p)}else if(d in e.propsKeywords){if(f&&"object"==typeof f)for(var m in f)r(t,n,i,f[m],o+"/"+d+"/"+m.replace(/~/g,"~0").replace(/\//g,"~1"),a,o,d,s,m)}else(d in e.keywords||t.allKeys&&!(d in e.skipKeywords))&&r(t,n,i,f,o+"/"+d,a,o,d,s)}i(s,o,a,l,c,u,h)}}e.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0},e.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},e.propsKeywords={definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},e.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0}},68326:(t,e,r)=>{"use strict";r.d(e,{QLR:()=>i,e68:()=>o,yLS:()=>n,z1G:()=>s});const n={prefix:"fas",iconName:"trash",icon:[448,512,[],"f1f8","M135.2 17.7L128 32 32 32C14.3 32 0 46.3 0 64S14.3 96 32 96l384 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-96 0-7.2-14.3C307.4 6.8 296.3 0 284.2 0L163.8 0c-12.1 0-23.2 6.8-28.6 17.7zM416 128L32 128 53.2 467c1.6 25.3 22.6 45 47.9 45l245.8 0c25.3 0 46.3-19.7 47.9-45L416 128z"]},i={prefix:"fas",iconName:"plus",icon:[448,512,[10133,61543,"add"],"2b","M256 80c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 144L48 224c-17.7 0-32 14.3-32 32s14.3 32 32 32l144 0 0 144c0 17.7 14.3 32 32 32s32-14.3 32-32l0-144 144 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-144 0 0-144z"]},s={prefix:"fas",iconName:"spinner",icon:[512,512,[],"f110","M304 48a48 48 0 1 0 -96 0 48 48 0 1 0 96 0zm0 416a48 48 0 1 0 -96 0 48 48 0 1 0 96 0zM48 304a48 48 0 1 0 0-96 48 48 0 1 0 0 96zm464-48a48 48 0 1 0 -96 0 48 48 0 1 0 96 0zM142.9 437A48 48 0 1 0 75 369.1 48 48 0 1 0 142.9 437zm0-294.2A48 48 0 1 0 75 75a48 48 0 1 0 67.9 67.9zM369.1 437A48 48 0 1 0 437 369.1 48 48 0 1 0 369.1 437z"]},o={prefix:"fas",iconName:"check",icon:[448,512,[10003,10004],"f00c","M438.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L160 338.7 393.4 105.4c12.5-12.5 32.8-12.5 45.3 0z"]}},90560:(t,e,r)=>{"use strict";r.d(e,{g:()=>wr});const n=()=>{};let i={},s={},o=null,a={mark:n,measure:n};try{"undefined"!=typeof window&&(i=window),"undefined"!=typeof document&&(s=document),"undefined"!=typeof MutationObserver&&(o=MutationObserver),"undefined"!=typeof performance&&(a=performance)}catch(t){}const{userAgent:l=""}=i.navigator||{},c=i,u=s,h=o,d=a,f=(c.document,!!u.documentElement&&!!u.head&&"function"==typeof u.addEventListener&&"function"==typeof u.createElement),p=~l.indexOf("MSIE")||~l.indexOf("Trident/");var m="classic",g="duotone",y="sharp",v="sharp-duotone",_=[m,g,y,v],b={classic:{fa:"solid",fas:"solid","fa-solid":"solid",far:"regular","fa-regular":"regular",fal:"light","fa-light":"light",fat:"thin","fa-thin":"thin",fad:"duotone","fa-duotone":"duotone",fab:"brands","fa-brands":"brands"},sharp:{fa:"solid",fass:"solid","fa-solid":"solid",fasr:"regular","fa-regular":"regular",fasl:"light","fa-light":"light",fast:"thin","fa-thin":"thin"},"sharp-duotone":{fa:"solid",fasds:"solid","fa-solid":"solid"}},w=[1,2,3,4,5,6,7,8,9,10],x=w.concat([11,12,13,14,15,16,17,18,19,20]),E={GROUP:"duotone-group",SWAP_OPACITY:"swap-opacity",PRIMARY:"primary",SECONDARY:"secondary"},S=[...Object.keys({classic:["fas","far","fal","fat"],sharp:["fass","fasr","fasl","fast"],"sharp-duotone":["fasds"]}),"solid","regular","light","thin","duotone","brands","2xs","xs","sm","lg","xl","2xl","beat","border","fade","beat-fade","bounce","flip-both","flip-horizontal","flip-vertical","flip","fw","inverse","layers-counter","layers-text","layers","li","pull-left","pull-right","pulse","rotate-180","rotate-270","rotate-90","rotate-by","shake","spin-pulse","spin-reverse","spin","stack-1x","stack-2x","stack","ul",E.GROUP,E.SWAP_OPACITY,E.PRIMARY,E.SECONDARY].concat(w.map((t=>"".concat(t,"x")))).concat(x.map((t=>"w-".concat(t))));const A="___FONT_AWESOME___",P=16,T="svg-inline--fa",C="data-fa-i2svg",M="data-fa-pseudo-element",O="data-prefix",R="data-icon",D="fontawesome-i2svg",I=["HTML","HEAD","STYLE","SCRIPT"],k=(()=>{try{return!0}catch(t){return!1}})(),L=[m,y,v];function F(t){return new Proxy(t,{get:(t,e)=>e in t?t[e]:t[m]})}const j={...b};j[m]={...b[m],fak:"kit","fa-kit":"kit",fakd:"kit-duotone","fa-kit-duotone":"kit-duotone"};const N=F(j),G={classic:{solid:"fas",regular:"far",light:"fal",thin:"fat",duotone:"fad",brands:"fab"},sharp:{solid:"fass",regular:"fasr",light:"fasl",thin:"fast"},"sharp-duotone":{solid:"fasds"}};G[m]={...G[m],kit:"fak","kit-duotone":"fakd"};const $=F(G),z={classic:{fab:"fa-brands",fad:"fa-duotone",fal:"fa-light",far:"fa-regular",fas:"fa-solid",fat:"fa-thin"},sharp:{fass:"fa-solid",fasr:"fa-regular",fasl:"fa-light",fast:"fa-thin"},"sharp-duotone":{fasds:"fa-solid"}};z[m]={...z[m],fak:"fa-kit"};const U=F(z),B={classic:{"fa-brands":"fab","fa-duotone":"fad","fa-light":"fal","fa-regular":"far","fa-solid":"fas","fa-thin":"fat"},sharp:{"fa-solid":"fass","fa-regular":"fasr","fa-light":"fasl","fa-thin":"fast"},"sharp-duotone":{"fa-solid":"fasds"}};B[m]={...B[m],"fa-kit":"fak"};const V=F(B),q=/fa(s|r|l|t|d|b|k|kd|ss|sr|sl|st|sds)?[\-\ ]/,K="fa-layers-text",W=/Font ?Awesome ?([56 ]*)(Solid|Regular|Light|Thin|Duotone|Brands|Free|Pro|Sharp Duotone|Sharp|Kit)?.*/i,H=(F({classic:{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},sharp:{900:"fass",400:"fasr",300:"fasl",100:"fast"},"sharp-duotone":{900:"fasds"}}),["class","data-prefix","data-icon","data-fa-transform","data-fa-mask"]),Y=E,X=new Set;Object.keys($[m]).map(X.add.bind(X)),Object.keys($[y]).map(X.add.bind(X)),Object.keys($[v]).map(X.add.bind(X));const Z=["kit",...S],J=c.FontAwesomeConfig||{};u&&"function"==typeof u.querySelector&&[["data-family-prefix","familyPrefix"],["data-css-prefix","cssPrefix"],["data-family-default","familyDefault"],["data-style-default","styleDefault"],["data-replacement-class","replacementClass"],["data-auto-replace-svg","autoReplaceSvg"],["data-auto-add-css","autoAddCss"],["data-auto-a11y","autoA11y"],["data-search-pseudo-elements","searchPseudoElements"],["data-observe-mutations","observeMutations"],["data-mutate-approach","mutateApproach"],["data-keep-original-source","keepOriginalSource"],["data-measure-performance","measurePerformance"],["data-show-missing-icons","showMissingIcons"]].forEach((t=>{let[e,r]=t;const n=function(t){return""===t||"false"!==t&&("true"===t||t)}(function(t){var e=u.querySelector("script["+t+"]");if(e)return e.getAttribute(t)}(e));null!=n&&(J[r]=n)}));const Q={styleDefault:"solid",familyDefault:"classic",cssPrefix:"fa",replacementClass:T,autoReplaceSvg:!0,autoAddCss:!0,autoA11y:!0,searchPseudoElements:!1,observeMutations:!0,mutateApproach:"async",keepOriginalSource:!0,measurePerformance:!1,showMissingIcons:!0};J.familyPrefix&&(J.cssPrefix=J.familyPrefix);const tt={...Q,...J};tt.autoReplaceSvg||(tt.observeMutations=!1);const et={};Object.keys(Q).forEach((t=>{Object.defineProperty(et,t,{enumerable:!0,set:function(e){tt[t]=e,rt.forEach((t=>t(et)))},get:function(){return tt[t]}})})),Object.defineProperty(et,"familyPrefix",{enumerable:!0,set:function(t){tt.cssPrefix=t,rt.forEach((t=>t(et)))},get:function(){return tt.cssPrefix}}),c.FontAwesomeConfig=et;const rt=[],nt=P,it={size:16,x:0,y:0,rotate:0,flipX:!1,flipY:!1};function st(){let t=12,e="";for(;t-- >0;)e+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[62*Math.random()|0];return e}function ot(t){const e=[];for(let r=(t||[]).length>>>0;r--;)e[r]=t[r];return e}function at(t){return t.classList?ot(t.classList):(t.getAttribute("class")||"").split(" ").filter((t=>t))}function lt(t){return"".concat(t).replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function ct(t){return Object.keys(t||{}).reduce(((e,r)=>e+"".concat(r,": ").concat(t[r].trim(),";")),"")}function ut(t){return t.size!==it.size||t.x!==it.x||t.y!==it.y||t.rotate!==it.rotate||t.flipX||t.flipY}function ht(){const t="fa",e=T,r=et.cssPrefix,n=et.replacementClass;let i=':root, :host {\n --fa-font-solid: normal 900 1em/1 "Font Awesome 6 Free";\n --fa-font-regular: normal 400 1em/1 "Font Awesome 6 Free";\n --fa-font-light: normal 300 1em/1 "Font Awesome 6 Pro";\n --fa-font-thin: normal 100 1em/1 "Font Awesome 6 Pro";\n --fa-font-duotone: normal 900 1em/1 "Font Awesome 6 Duotone";\n --fa-font-brands: normal 400 1em/1 "Font Awesome 6 Brands";\n --fa-font-sharp-solid: normal 900 1em/1 "Font Awesome 6 Sharp";\n --fa-font-sharp-regular: normal 400 1em/1 "Font Awesome 6 Sharp";\n --fa-font-sharp-light: normal 300 1em/1 "Font Awesome 6 Sharp";\n --fa-font-sharp-thin: normal 100 1em/1 "Font Awesome 6 Sharp";\n --fa-font-sharp-duotone-solid: normal 900 1em/1 "Font Awesome 6 Sharp Duotone";\n}\n\nsvg:not(:root).svg-inline--fa, svg:not(:host).svg-inline--fa {\n overflow: visible;\n box-sizing: content-box;\n}\n\n.svg-inline--fa {\n display: var(--fa-display, inline-block);\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n}\n.svg-inline--fa.fa-2xs {\n vertical-align: 0.1em;\n}\n.svg-inline--fa.fa-xs {\n vertical-align: 0em;\n}\n.svg-inline--fa.fa-sm {\n vertical-align: -0.0714285705em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.2em;\n}\n.svg-inline--fa.fa-xl {\n vertical-align: -0.25em;\n}\n.svg-inline--fa.fa-2xl {\n vertical-align: -0.3125em;\n}\n.svg-inline--fa.fa-pull-left {\n margin-right: var(--fa-pull-margin, 0.3em);\n width: auto;\n}\n.svg-inline--fa.fa-pull-right {\n margin-left: var(--fa-pull-margin, 0.3em);\n width: auto;\n}\n.svg-inline--fa.fa-li {\n width: var(--fa-li-width, 2em);\n top: 0.25em;\n}\n.svg-inline--fa.fa-fw {\n width: var(--fa-fw-width, 1.25em);\n}\n\n.fa-layers svg.svg-inline--fa {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: 1em;\n}\n.fa-layers svg.svg-inline--fa {\n transform-origin: center center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n transform: translate(-50%, -50%);\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: var(--fa-counter-background-color, #ff253a);\n border-radius: var(--fa-counter-border-radius, 1em);\n box-sizing: border-box;\n color: var(--fa-inverse, #fff);\n line-height: var(--fa-counter-line-height, 1);\n max-width: var(--fa-counter-max-width, 5em);\n min-width: var(--fa-counter-min-width, 1.5em);\n overflow: hidden;\n padding: var(--fa-counter-padding, 0.25em 0.5em);\n right: var(--fa-right, 0);\n text-overflow: ellipsis;\n top: var(--fa-top, 0);\n transform: scale(var(--fa-counter-scale, 0.25));\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: var(--fa-bottom, 0);\n right: var(--fa-right, 0);\n top: auto;\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: var(--fa-bottom, 0);\n left: var(--fa-left, 0);\n right: auto;\n top: auto;\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n top: var(--fa-top, 0);\n right: var(--fa-right, 0);\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: var(--fa-left, 0);\n right: auto;\n top: var(--fa-top, 0);\n transform: scale(var(--fa-layers-scale, 0.25));\n transform-origin: top left;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-2xs {\n font-size: 0.625em;\n line-height: 0.1em;\n vertical-align: 0.225em;\n}\n\n.fa-xs {\n font-size: 0.75em;\n line-height: 0.0833333337em;\n vertical-align: 0.125em;\n}\n\n.fa-sm {\n font-size: 0.875em;\n line-height: 0.0714285718em;\n vertical-align: 0.0535714295em;\n}\n\n.fa-lg {\n font-size: 1.25em;\n line-height: 0.05em;\n vertical-align: -0.075em;\n}\n\n.fa-xl {\n font-size: 1.5em;\n line-height: 0.0416666682em;\n vertical-align: -0.125em;\n}\n\n.fa-2xl {\n font-size: 2em;\n line-height: 0.03125em;\n vertical-align: -0.1875em;\n}\n\n.fa-fw {\n text-align: center;\n width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-left: var(--fa-li-margin, 2.5em);\n padding-left: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n left: calc(-1 * var(--fa-li-width, 2em));\n position: absolute;\n text-align: center;\n width: var(--fa-li-width, 2em);\n line-height: inherit;\n}\n\n.fa-border {\n border-color: var(--fa-border-color, #eee);\n border-radius: var(--fa-border-radius, 0.1em);\n border-style: var(--fa-border-style, solid);\n border-width: var(--fa-border-width, 0.08em);\n padding: var(--fa-border-padding, 0.2em 0.25em 0.15em);\n}\n\n.fa-pull-left {\n float: left;\n margin-right: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-pull-right {\n float: right;\n margin-left: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-beat {\n animation-name: fa-beat;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-bounce {\n animation-name: fa-bounce;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1));\n}\n\n.fa-fade {\n animation-name: fa-fade;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-beat-fade {\n animation-name: fa-beat-fade;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-flip {\n animation-name: fa-flip;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-shake {\n animation-name: fa-shake;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin {\n animation-name: fa-spin;\n animation-delay: var(--fa-animation-delay, 0s);\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 2s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin-reverse {\n --fa-animation-direction: reverse;\n}\n\n.fa-pulse,\n.fa-spin-pulse {\n animation-name: fa-spin;\n animation-direction: var(--fa-animation-direction, normal);\n animation-duration: var(--fa-animation-duration, 1s);\n animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n animation-timing-function: var(--fa-animation-timing, steps(8));\n}\n\n@media (prefers-reduced-motion: reduce) {\n .fa-beat,\n.fa-bounce,\n.fa-fade,\n.fa-beat-fade,\n.fa-flip,\n.fa-pulse,\n.fa-shake,\n.fa-spin,\n.fa-spin-pulse {\n animation-delay: -1ms;\n animation-duration: 1ms;\n animation-iteration-count: 1;\n transition-delay: 0s;\n transition-duration: 0s;\n }\n}\n@keyframes fa-beat {\n 0%, 90% {\n transform: scale(1);\n }\n 45% {\n transform: scale(var(--fa-beat-scale, 1.25));\n }\n}\n@keyframes fa-bounce {\n 0% {\n transform: scale(1, 1) translateY(0);\n }\n 10% {\n transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n }\n 30% {\n transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n }\n 50% {\n transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n }\n 57% {\n transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n }\n 64% {\n transform: scale(1, 1) translateY(0);\n }\n 100% {\n transform: scale(1, 1) translateY(0);\n }\n}\n@keyframes fa-fade {\n 50% {\n opacity: var(--fa-fade-opacity, 0.4);\n }\n}\n@keyframes fa-beat-fade {\n 0%, 100% {\n opacity: var(--fa-beat-fade-opacity, 0.4);\n transform: scale(1);\n }\n 50% {\n opacity: 1;\n transform: scale(var(--fa-beat-fade-scale, 1.125));\n }\n}\n@keyframes fa-flip {\n 50% {\n transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n }\n}\n@keyframes fa-shake {\n 0% {\n transform: rotate(-15deg);\n }\n 4% {\n transform: rotate(15deg);\n }\n 8%, 24% {\n transform: rotate(-18deg);\n }\n 12%, 28% {\n transform: rotate(18deg);\n }\n 16% {\n transform: rotate(-22deg);\n }\n 20% {\n transform: rotate(22deg);\n }\n 32% {\n transform: rotate(-12deg);\n }\n 36% {\n transform: rotate(12deg);\n }\n 40%, 100% {\n transform: rotate(0deg);\n }\n}\n@keyframes fa-spin {\n 0% {\n transform: rotate(0deg);\n }\n 100% {\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n transform: scale(1, -1);\n}\n\n.fa-flip-both,\n.fa-flip-horizontal.fa-flip-vertical {\n transform: scale(-1, -1);\n}\n\n.fa-rotate-by {\n transform: rotate(var(--fa-rotate-angle, 0));\n}\n\n.fa-stack {\n display: inline-block;\n vertical-align: middle;\n height: 2em;\n position: relative;\n width: 2.5em;\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n z-index: var(--fa-stack-z-index, auto);\n}\n\n.svg-inline--fa.fa-stack-1x {\n height: 1em;\n width: 1.25em;\n}\n.svg-inline--fa.fa-stack-2x {\n height: 2em;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: var(--fa-inverse, #fff);\n}\n\n.sr-only,\n.fa-sr-only {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n white-space: nowrap;\n border-width: 0;\n}\n\n.sr-only-focusable:not(:focus),\n.fa-sr-only-focusable:not(:focus) {\n position: absolute;\n width: 1px;\n height: 1px;\n padding: 0;\n margin: -1px;\n overflow: hidden;\n clip: rect(0, 0, 0, 0);\n white-space: nowrap;\n border-width: 0;\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.fad.fa-inverse,\n.fa-duotone.fa-inverse {\n color: var(--fa-inverse, #fff);\n}';if(r!==t||n!==e){const s=new RegExp("\\.".concat(t,"\\-"),"g"),o=new RegExp("\\--".concat(t,"\\-"),"g"),a=new RegExp("\\.".concat(e),"g");i=i.replace(s,".".concat(r,"-")).replace(o,"--".concat(r,"-")).replace(a,".".concat(n))}return i}let dt=!1;function ft(){et.autoAddCss&&!dt&&(function(t){if(!t||!f)return;const e=u.createElement("style");e.setAttribute("type","text/css"),e.innerHTML=t;const r=u.head.childNodes;let n=null;for(let t=r.length-1;t>-1;t--){const e=r[t],i=(e.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(i)>-1&&(n=e)}u.head.insertBefore(e,n)}(ht()),dt=!0)}var pt={mixout:()=>({dom:{css:ht,insertCss:ft}}),hooks:()=>({beforeDOMElementCreation(){ft()},beforeI2svg(){ft()}})};const mt=c||{};mt[A]||(mt[A]={}),mt[A].styles||(mt[A].styles={}),mt[A].hooks||(mt[A].hooks={}),mt[A].shims||(mt[A].shims=[]);var gt=mt[A];const yt=[],vt=function(){u.removeEventListener("DOMContentLoaded",vt),_t=1,yt.map((t=>t()))};let _t=!1;function bt(t){const{tag:e,attributes:r={},children:n=[]}=t;return"string"==typeof t?lt(t):"<".concat(e," ").concat(function(t){return Object.keys(t||{}).reduce(((e,r)=>e+"".concat(r,'="').concat(lt(t[r]),'" ')),"").trim()}(r),">").concat(n.map(bt).join(""),"</").concat(e,">")}function wt(t,e,r){if(t&&t[e]&&t[e][r])return{prefix:e,iconName:r,icon:t[e][r]}}f&&(_t=(u.documentElement.doScroll?/^loaded|^c/:/^loaded|^i|^c/).test(u.readyState),_t||u.addEventListener("DOMContentLoaded",vt));var xt=function(t,e,r,n){var i,s,o,a=Object.keys(t),l=a.length,c=void 0!==n?function(t,e){return function(r,n,i,s){return t.call(e,r,n,i,s)}}(e,n):e;for(void 0===r?(i=1,o=t[a[0]]):(i=0,o=r);i<l;i++)o=c(o,t[s=a[i]],s,t);return o};function Et(t){const e=function(t){const e=[];let r=0;const n=t.length;for(;r<n;){const i=t.charCodeAt(r++);if(i>=55296&&i<=56319&&r<n){const n=t.charCodeAt(r++);56320==(64512&n)?e.push(((1023&i)<<10)+(1023&n)+65536):(e.push(i),r--)}else e.push(i)}return e}(t);return 1===e.length?e[0].toString(16):null}function St(t){return Object.keys(t).reduce(((e,r)=>{const n=t[r];return n.icon?e[n.iconName]=n.icon:e[r]=n,e}),{})}function At(t,e){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const{skipHooks:n=!1}=r,i=St(e);"function"!=typeof gt.hooks.addPack||n?gt.styles[t]={...gt.styles[t]||{},...i}:gt.hooks.addPack(t,St(e)),"fas"===t&&At("fa",e)}const{styles:Pt,shims:Tt}=gt,Ct={[m]:Object.values(U[m]),[y]:Object.values(U[y]),[v]:Object.values(U[v])};let Mt=null,Ot={},Rt={},Dt={},It={},kt={};const Lt={[m]:Object.keys(N[m]),[y]:Object.keys(N[y]),[v]:Object.keys(N[v])};const Ft=()=>{const t=t=>xt(Pt,((e,r,n)=>(e[n]=xt(r,t,{}),e)),{});Ot=t(((t,e,r)=>(e[3]&&(t[e[3]]=r),e[2]&&e[2].filter((t=>"number"==typeof t)).forEach((e=>{t[e.toString(16)]=r})),t))),Rt=t(((t,e,r)=>(t[r]=r,e[2]&&e[2].filter((t=>"string"==typeof t)).forEach((e=>{t[e]=r})),t))),kt=t(((t,e,r)=>{const n=e[2];return t[r]=r,n.forEach((e=>{t[e]=r})),t}));const e="far"in Pt||et.autoFetchSvg,r=xt(Tt,((t,r)=>{const n=r[0];let i=r[1];const s=r[2];return"far"!==i||e||(i="fas"),"string"==typeof n&&(t.names[n]={prefix:i,iconName:s}),"number"==typeof n&&(t.unicodes[n.toString(16)]={prefix:i,iconName:s}),t}),{names:{},unicodes:{}});Dt=r.names,It=r.unicodes,Mt=Ut(et.styleDefault,{family:et.familyDefault})};var jt;function Nt(t,e){return(Ot[t]||{})[e]}function Gt(t,e){return(kt[t]||{})[e]}function $t(t){return Dt[t]||{prefix:null,iconName:null}}function zt(){return Mt}function Ut(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{family:r=m}=e,n=N[r][t],i=$[r][t]||$[r][n],s=t in gt.styles?t:null;return i||s||null}jt=t=>{Mt=Ut(t.styleDefault,{family:et.familyDefault})},rt.push(jt),Ft();const Bt={[m]:Object.keys(U[m]),[y]:Object.keys(U[y]),[v]:Object.keys(U[v])};function Vt(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{skipLookups:r=!1}=e,n={[m]:"".concat(et.cssPrefix,"-").concat(m),[y]:"".concat(et.cssPrefix,"-").concat(y),[v]:"".concat(et.cssPrefix,"-").concat(v)};let i=null,s=m;const o=_.filter((t=>t!==g));o.forEach((e=>{(t.includes(n[e])||t.some((t=>Bt[e].includes(t))))&&(s=e)}));const a=t.reduce(((t,e)=>{const a=function(t,e){const r=e.split("-"),n=r[0],i=r.slice(1).join("-");return n!==t||""===i||(s=i,~Z.indexOf(s))?null:i;var s}(et.cssPrefix,e);if(Pt[e]?(e=Ct[s].includes(e)?V[s][e]:e,i=e,t.prefix=e):Lt[s].indexOf(e)>-1?(i=e,t.prefix=Ut(e,{family:s})):a?t.iconName=a:e===et.replacementClass||o.some((t=>e===n[t]))||t.rest.push(e),!r&&t.prefix&&t.iconName){const e="fa"===i?$t(t.iconName):{},r=Gt(t.prefix,t.iconName);e.prefix&&(i=null),t.iconName=e.iconName||r||t.iconName,t.prefix=e.prefix||t.prefix,"far"!==t.prefix||Pt.far||!Pt.fas||et.autoFetchSvg||(t.prefix="fas")}return t}),{prefix:null,iconName:null,rest:[]});return(t.includes("fa-brands")||t.includes("fab"))&&(a.prefix="fab"),(t.includes("fa-duotone")||t.includes("fad"))&&(a.prefix="fad"),a.prefix||s!==y||!Pt.fass&&!et.autoFetchSvg||(a.prefix="fass",a.iconName=Gt(a.prefix,a.iconName)||a.iconName),a.prefix||s!==v||!Pt.fasds&&!et.autoFetchSvg||(a.prefix="fasds",a.iconName=Gt(a.prefix,a.iconName)||a.iconName),"fa"!==a.prefix&&"fa"!==i||(a.prefix=zt()||"fas"),a}let qt=[],Kt={};const Wt={},Ht=Object.keys(Wt);function Yt(t,e){for(var r=arguments.length,n=new Array(r>2?r-2:0),i=2;i<r;i++)n[i-2]=arguments[i];return(Kt[t]||[]).forEach((t=>{e=t.apply(null,[e,...n])})),e}function Xt(t){for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];(Kt[t]||[]).forEach((t=>{t.apply(null,r)}))}function Zt(){const t=arguments[0],e=Array.prototype.slice.call(arguments,1);return Wt[t]?Wt[t].apply(null,e):void 0}function Jt(t){"fa"===t.prefix&&(t.prefix="fas");let{iconName:e}=t;const r=t.prefix||zt();if(e)return e=Gt(r,e)||e,wt(Qt.definitions,r,e)||wt(gt.styles,r,e)}const Qt=new class{constructor(){this.definitions={}}add(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];const n=e.reduce(this._pullDefinitions,{});Object.keys(n).forEach((t=>{this.definitions[t]={...this.definitions[t]||{},...n[t]},At(t,n[t]);const e=U[m][t];e&&At(e,n[t]),Ft()}))}reset(){this.definitions={}}_pullDefinitions(t,e){const r=e.prefix&&e.iconName&&e.icon?{0:e}:e;return Object.keys(r).map((e=>{const{prefix:n,iconName:i,icon:s}=r[e],o=s[2];t[n]||(t[n]={}),o.length>0&&o.forEach((e=>{"string"==typeof e&&(t[n][e]=s)})),t[n][i]=s})),t}},te={i2svg:function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return f?(Xt("beforeI2svg",t),Zt("pseudoElements2svg",t),Zt("i2svg",t)):Promise.reject(new Error("Operation requires a DOM of some kind."))},watch:function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{autoReplaceSvgRoot:e}=t;var r;!1===et.autoReplaceSvg&&(et.autoReplaceSvg=!0),et.observeMutations=!0,r=()=>{ne({autoReplaceSvgRoot:e}),Xt("watch",t)},f&&(_t?setTimeout(r,0):yt.push(r))}},ee={icon:t=>{if(null===t)return null;if("object"==typeof t&&t.prefix&&t.iconName)return{prefix:t.prefix,iconName:Gt(t.prefix,t.iconName)||t.iconName};if(Array.isArray(t)&&2===t.length){const e=0===t[1].indexOf("fa-")?t[1].slice(3):t[1],r=Ut(t[0]);return{prefix:r,iconName:Gt(r,e)||e}}if("string"==typeof t&&(t.indexOf("".concat(et.cssPrefix,"-"))>-1||t.match(q))){const e=Vt(t.split(" "),{skipLookups:!0});return{prefix:e.prefix||zt(),iconName:Gt(e.prefix,e.iconName)||e.iconName}}if("string"==typeof t){const e=zt();return{prefix:e,iconName:Gt(e,t)||t}}}},re={noAuto:()=>{et.autoReplaceSvg=!1,et.observeMutations=!1,Xt("noAuto")},config:et,dom:te,parse:ee,library:Qt,findIconDefinition:Jt,toHtml:bt},ne=function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{autoReplaceSvgRoot:e=u}=t;(Object.keys(gt.styles).length>0||et.autoFetchSvg)&&f&&et.autoReplaceSvg&&re.dom.i2svg({node:e})};function ie(t,e){return Object.defineProperty(t,"abstract",{get:e}),Object.defineProperty(t,"html",{get:function(){return t.abstract.map((t=>bt(t)))}}),Object.defineProperty(t,"node",{get:function(){if(!f)return;const e=u.createElement("div");return e.innerHTML=t.html,e.children}}),t}function se(t){const{icons:{main:e,mask:r},prefix:n,iconName:i,transform:s,symbol:o,title:a,maskId:l,titleId:c,extra:u,watchable:h=!1}=t,{width:d,height:f}=r.found?r:e,p="fak"===n,m=[et.replacementClass,i?"".concat(et.cssPrefix,"-").concat(i):""].filter((t=>-1===u.classes.indexOf(t))).filter((t=>""!==t||!!t)).concat(u.classes).join(" ");let g={children:[],attributes:{...u.attributes,"data-prefix":n,"data-icon":i,class:m,role:u.attributes.role||"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(d," ").concat(f)}};const y=p&&!~u.classes.indexOf("fa-fw")?{width:"".concat(d/f*16*.0625,"em")}:{};h&&(g.attributes[C]=""),a&&(g.children.push({tag:"title",attributes:{id:g.attributes["aria-labelledby"]||"title-".concat(c||st())},children:[a]}),delete g.attributes.title);const v={...g,prefix:n,iconName:i,main:e,mask:r,maskId:l,transform:s,symbol:o,styles:{...y,...u.styles}},{children:_,attributes:b}=r.found&&e.found?Zt("generateAbstractMask",v)||{children:[],attributes:{}}:Zt("generateAbstractIcon",v)||{children:[],attributes:{}};return v.children=_,v.attributes=b,o?function(t){let{prefix:e,iconName:r,children:n,attributes:i,symbol:s}=t;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:{...i,id:!0===s?"".concat(e,"-").concat(et.cssPrefix,"-").concat(r):s},children:n}]}]}(v):function(t){let{children:e,main:r,mask:n,attributes:i,styles:s,transform:o}=t;if(ut(o)&&r.found&&!n.found){const{width:t,height:e}=r,n={x:t/e/2,y:.5};i.style=ct({...s,"transform-origin":"".concat(n.x+o.x/16,"em ").concat(n.y+o.y/16,"em")})}return[{tag:"svg",attributes:i,children:e}]}(v)}function oe(t){const{content:e,width:r,height:n,transform:i,title:s,extra:o,watchable:a=!1}=t,l={...o.attributes,...s?{title:s}:{},class:o.classes.join(" ")};a&&(l[C]="");const c={...o.styles};ut(i)&&(c.transform=function(t){let{transform:e,width:r=P,height:n=P,startCentered:i=!1}=t,s="";return s+=i&&p?"translate(".concat(e.x/nt-r/2,"em, ").concat(e.y/nt-n/2,"em) "):i?"translate(calc(-50% + ".concat(e.x/nt,"em), calc(-50% + ").concat(e.y/nt,"em)) "):"translate(".concat(e.x/nt,"em, ").concat(e.y/nt,"em) "),s+="scale(".concat(e.size/nt*(e.flipX?-1:1),", ").concat(e.size/nt*(e.flipY?-1:1),") "),s+="rotate(".concat(e.rotate,"deg) "),s}({transform:i,startCentered:!0,width:r,height:n}),c["-webkit-transform"]=c.transform);const u=ct(c);u.length>0&&(l.style=u);const h=[];return h.push({tag:"span",attributes:l,children:[e]}),s&&h.push({tag:"span",attributes:{class:"sr-only"},children:[s]}),h}const{styles:ae}=gt;function le(t){const e=t[0],r=t[1],[n]=t.slice(4);let i=null;return i=Array.isArray(n)?{tag:"g",attributes:{class:"".concat(et.cssPrefix,"-").concat(Y.GROUP)},children:[{tag:"path",attributes:{class:"".concat(et.cssPrefix,"-").concat(Y.SECONDARY),fill:"currentColor",d:n[0]}},{tag:"path",attributes:{class:"".concat(et.cssPrefix,"-").concat(Y.PRIMARY),fill:"currentColor",d:n[1]}}]}:{tag:"path",attributes:{fill:"currentColor",d:n}},{found:!0,width:e,height:r,icon:i}}const ce={found:!1,width:512,height:512};function ue(t,e){let r=e;return"fa"===e&&null!==et.styleDefault&&(e=zt()),new Promise(((n,i)=>{if("fa"===r){const r=$t(t)||{};t=r.iconName||t,e=r.prefix||e}if(t&&e&&ae[e]&&ae[e][t])return n(le(ae[e][t]));!function(t,e){k||et.showMissingIcons||!t||console.error('Icon with name "'.concat(t,'" and prefix "').concat(e,'" is missing.'))}(t,e),n({...ce,icon:et.showMissingIcons&&t&&Zt("missingIconAbstract")||{}})}))}const he=()=>{},de=et.measurePerformance&&d&&d.mark&&d.measure?d:{mark:he,measure:he},fe='FA "6.6.0"';var pe=t=>(de.mark("".concat(fe," ").concat(t," begins")),()=>(t=>{de.mark("".concat(fe," ").concat(t," ends")),de.measure("".concat(fe," ").concat(t),"".concat(fe," ").concat(t," begins"),"".concat(fe," ").concat(t," ends"))})(t));const me=()=>{};function ge(t){return"string"==typeof(t.getAttribute?t.getAttribute(C):null)}function ye(t){return u.createElementNS("http://www.w3.org/2000/svg",t)}function ve(t){return u.createElement(t)}function _e(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{ceFn:r=("svg"===t.tag?ye:ve)}=e;if("string"==typeof t)return u.createTextNode(t);const n=r(t.tag);return Object.keys(t.attributes||[]).forEach((function(e){n.setAttribute(e,t.attributes[e])})),(t.children||[]).forEach((function(t){n.appendChild(_e(t,{ceFn:r}))})),n}const be={replace:function(t){const e=t[0];if(e.parentNode)if(t[1].forEach((t=>{e.parentNode.insertBefore(_e(t),e)})),null===e.getAttribute(C)&&et.keepOriginalSource){let t=u.createComment(function(t){let e=" ".concat(t.outerHTML," ");return e="".concat(e,"Font Awesome fontawesome.com "),e}(e));e.parentNode.replaceChild(t,e)}else e.remove()},nest:function(t){const e=t[0],r=t[1];if(~at(e).indexOf(et.replacementClass))return be.replace(t);const n=new RegExp("".concat(et.cssPrefix,"-.*"));if(delete r[0].attributes.id,r[0].attributes.class){const t=r[0].attributes.class.split(" ").reduce(((t,e)=>(e===et.replacementClass||e.match(n)?t.toSvg.push(e):t.toNode.push(e),t)),{toNode:[],toSvg:[]});r[0].attributes.class=t.toSvg.join(" "),0===t.toNode.length?e.removeAttribute("class"):e.setAttribute("class",t.toNode.join(" "))}const i=r.map((t=>bt(t))).join("\n");e.setAttribute(C,""),e.innerHTML=i}};function we(t){t()}function xe(t,e){const r="function"==typeof e?e:me;if(0===t.length)r();else{let e=we;"async"===et.mutateApproach&&(e=c.requestAnimationFrame||we),e((()=>{const e=!0===et.autoReplaceSvg?be.replace:be[et.autoReplaceSvg]||be.replace,n=pe("mutate");t.map(e),n(),r()}))}}let Ee=!1;function Se(){Ee=!0}function Ae(){Ee=!1}let Pe=null;function Te(t){if(!h)return;if(!et.observeMutations)return;const{treeCallback:e=me,nodeCallback:r=me,pseudoElementsCallback:n=me,observeMutationsRoot:i=u}=t;Pe=new h((t=>{if(Ee)return;const i=zt();ot(t).forEach((t=>{if("childList"===t.type&&t.addedNodes.length>0&&!ge(t.addedNodes[0])&&(et.searchPseudoElements&&n(t.target),e(t.target)),"attributes"===t.type&&t.target.parentNode&&et.searchPseudoElements&&n(t.target.parentNode),"attributes"===t.type&&ge(t.target)&&~H.indexOf(t.attributeName))if("class"===t.attributeName&&function(t){const e=t.getAttribute?t.getAttribute(O):null,r=t.getAttribute?t.getAttribute(R):null;return e&&r}(t.target)){const{prefix:e,iconName:r}=Vt(at(t.target));t.target.setAttribute(O,e||i),r&&t.target.setAttribute(R,r)}else(s=t.target)&&s.classList&&s.classList.contains&&s.classList.contains(et.replacementClass)&&r(t.target);var s}))})),f&&Pe.observe(i,{childList:!0,attributes:!0,characterData:!0,subtree:!0})}function Ce(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{styleParser:!0};const{iconName:r,prefix:n,rest:i}=function(t){const e=t.getAttribute("data-prefix"),r=t.getAttribute("data-icon"),n=void 0!==t.innerText?t.innerText.trim():"";let i=Vt(at(t));return i.prefix||(i.prefix=zt()),e&&r&&(i.prefix=e,i.iconName=r),i.iconName&&i.prefix||(i.prefix&&n.length>0&&(i.iconName=(s=i.prefix,o=t.innerText,(Rt[s]||{})[o]||Nt(i.prefix,Et(t.innerText)))),!i.iconName&&et.autoFetchSvg&&t.firstChild&&t.firstChild.nodeType===Node.TEXT_NODE&&(i.iconName=t.firstChild.data)),i;var s,o}(t),s=function(t){const e=ot(t.attributes).reduce(((t,e)=>("class"!==t.name&&"style"!==t.name&&(t[e.name]=e.value),t)),{}),r=t.getAttribute("title"),n=t.getAttribute("data-fa-title-id");return et.autoA11y&&(r?e["aria-labelledby"]="".concat(et.replacementClass,"-title-").concat(n||st()):(e["aria-hidden"]="true",e.focusable="false")),e}(t),o=Yt("parseNodeAttributes",{},t);let a=e.styleParser?function(t){const e=t.getAttribute("style");let r=[];return e&&(r=e.split(";").reduce(((t,e)=>{const r=e.split(":"),n=r[0],i=r.slice(1);return n&&i.length>0&&(t[n]=i.join(":").trim()),t}),{})),r}(t):[];return{iconName:r,title:t.getAttribute("title"),titleId:t.getAttribute("data-fa-title-id"),prefix:n,transform:it,mask:{iconName:null,prefix:null,rest:[]},maskId:null,symbol:!1,extra:{classes:i,styles:a,attributes:s},...o}}const{styles:Me}=gt;function Oe(t){const e="nest"===et.autoReplaceSvg?Ce(t,{styleParser:!1}):Ce(t);return~e.extra.classes.indexOf(K)?Zt("generateLayersText",t,e):Zt("generateSvgReplacementMutation",t,e)}let Re=new Set;function De(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(!f)return Promise.resolve();const r=u.documentElement.classList,n=t=>r.add("".concat(D,"-").concat(t)),i=t=>r.remove("".concat(D,"-").concat(t)),s=et.autoFetchSvg?Re:L.map((t=>"fa-".concat(t))).concat(Object.keys(Me));s.includes("fa")||s.push("fa");const o=[".".concat(K,":not([").concat(C,"])")].concat(s.map((t=>".".concat(t,":not([").concat(C,"])")))).join(", ");if(0===o.length)return Promise.resolve();let a=[];try{a=ot(t.querySelectorAll(o))}catch(t){}if(!(a.length>0))return Promise.resolve();n("pending"),i("complete");const l=pe("onTree"),c=a.reduce(((t,e)=>{try{const r=Oe(e);r&&t.push(r)}catch(t){k||"MissingIcon"===t.name&&console.error(t)}return t}),[]);return new Promise(((t,r)=>{Promise.all(c).then((r=>{xe(r,(()=>{n("active"),n("complete"),i("pending"),"function"==typeof e&&e(),l(),t()}))})).catch((t=>{l(),r(t)}))}))}function Ie(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;Oe(t).then((t=>{t&&xe([t],e)}))}L.map((t=>{Re.add("fa-".concat(t))})),Object.keys(N[m]).map(Re.add.bind(Re)),Object.keys(N[y]).map(Re.add.bind(Re)),Object.keys(N[v]).map(Re.add.bind(Re)),Re=[...Re];const ke=function(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{transform:r=it,symbol:n=!1,mask:i=null,maskId:s=null,title:o=null,titleId:a=null,classes:l=[],attributes:c={},styles:u={}}=e;if(!t)return;const{prefix:h,iconName:d,icon:f}=t;return ie({type:"icon",...t},(()=>(Xt("beforeDOMElementCreation",{iconDefinition:t,params:e}),et.autoA11y&&(o?c["aria-labelledby"]="".concat(et.replacementClass,"-title-").concat(a||st()):(c["aria-hidden"]="true",c.focusable="false")),se({icons:{main:le(f),mask:i?le(i.icon):{found:!1,width:null,height:null,icon:{}}},prefix:h,iconName:d,transform:{...it,...r},symbol:n,title:o,maskId:s,titleId:a,extra:{attributes:c,styles:u,classes:l}}))))};var Le={mixout(){return{icon:(t=ke,function(e){let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=(e||{}).icon?e:Jt(e||{});let{mask:i}=r;return i&&(i=(i||{}).icon?i:Jt(i||{})),t(n,{...r,mask:i})})};var t},hooks:()=>({mutationObserverCallbacks:t=>(t.treeCallback=De,t.nodeCallback=Ie,t)}),provides(t){t.i2svg=function(t){const{node:e=u,callback:r=()=>{}}=t;return De(e,r)},t.generateSvgReplacementMutation=function(t,e){const{iconName:r,title:n,titleId:i,prefix:s,transform:o,symbol:a,mask:l,maskId:c,extra:u}=e;return new Promise(((e,h)=>{Promise.all([ue(r,s),l.iconName?ue(l.iconName,l.prefix):Promise.resolve({found:!1,width:512,height:512,icon:{}})]).then((l=>{let[h,d]=l;e([t,se({icons:{main:h,mask:d},prefix:s,iconName:r,transform:o,symbol:a,maskId:c,title:n,titleId:i,extra:u,watchable:!0})])})).catch(h)}))},t.generateAbstractIcon=function(t){let{children:e,attributes:r,main:n,transform:i,styles:s}=t;const o=ct(s);let a;return o.length>0&&(r.style=o),ut(i)&&(a=Zt("generateAbstractTransformGrouping",{main:n,transform:i,containerWidth:n.width,iconWidth:n.width})),e.push(a||n.icon),{children:e,attributes:r}}}},Fe={mixout:()=>({layer(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{classes:r=[]}=e;return ie({type:"layer"},(()=>{Xt("beforeDOMElementCreation",{assembler:t,params:e});let n=[];return t((t=>{Array.isArray(t)?t.map((t=>{n=n.concat(t.abstract)})):n=n.concat(t.abstract)})),[{tag:"span",attributes:{class:["".concat(et.cssPrefix,"-layers"),...r].join(" ")},children:n}]}))}})},je={mixout:()=>({counter(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{title:r=null,classes:n=[],attributes:i={},styles:s={}}=e;return ie({type:"counter",content:t},(()=>(Xt("beforeDOMElementCreation",{content:t,params:e}),function(t){const{content:e,title:r,extra:n}=t,i={...n.attributes,...r?{title:r}:{},class:n.classes.join(" ")},s=ct(n.styles);s.length>0&&(i.style=s);const o=[];return o.push({tag:"span",attributes:i,children:[e]}),r&&o.push({tag:"span",attributes:{class:"sr-only"},children:[r]}),o}({content:t.toString(),title:r,extra:{attributes:i,styles:s,classes:["".concat(et.cssPrefix,"-layers-counter"),...n]}}))))}})},Ne={mixout:()=>({text(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const{transform:r=it,title:n=null,classes:i=[],attributes:s={},styles:o={}}=e;return ie({type:"text",content:t},(()=>(Xt("beforeDOMElementCreation",{content:t,params:e}),oe({content:t,transform:{...it,...r},title:n,extra:{attributes:s,styles:o,classes:["".concat(et.cssPrefix,"-layers-text"),...i]}}))))}}),provides(t){t.generateLayersText=function(t,e){const{title:r,transform:n,extra:i}=e;let s=null,o=null;if(p){const e=parseInt(getComputedStyle(t).fontSize,10),r=t.getBoundingClientRect();s=r.width/e,o=r.height/e}return et.autoA11y&&!r&&(i.attributes["aria-hidden"]="true"),Promise.resolve([t,oe({content:t.innerHTML,width:s,height:o,transform:n,title:r,extra:i,watchable:!0})])}}};const Ge=new RegExp('"',"ug"),$e=[1105920,1112319],ze={FontAwesome:{normal:"fas",400:"fas"},"Font Awesome 6 Free":{900:"fas",400:"far"},"Font Awesome 6 Pro":{900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},"Font Awesome 6 Brands":{400:"fab",normal:"fab"},"Font Awesome 6 Duotone":{900:"fad"},"Font Awesome 6 Sharp":{900:"fass",400:"fasr",normal:"fasr",300:"fasl",100:"fast"},"Font Awesome 6 Sharp Duotone":{900:"fasds"},"Font Awesome 5 Free":{900:"fas",400:"far"},"Font Awesome 5 Pro":{900:"fas",400:"far",normal:"far",300:"fal"},"Font Awesome 5 Brands":{400:"fab",normal:"fab"},"Font Awesome 5 Duotone":{900:"fad"},"Font Awesome Kit":{400:"fak",normal:"fak"},"Font Awesome Kit Duotone":{400:"fakd",normal:"fakd"}},Ue=Object.keys(ze).reduce(((t,e)=>(t[e.toLowerCase()]=ze[e],t)),{}),Be=Object.keys(Ue).reduce(((t,e)=>{const r=Ue[e];return t[e]=r[900]||[...Object.entries(r)][0][1],t}),{});function Ve(t,e){const r="".concat("data-fa-pseudo-element-pending").concat(e.replace(":","-"));return new Promise(((n,i)=>{if(null!==t.getAttribute(r))return n();const s=ot(t.children).filter((t=>t.getAttribute(M)===e))[0],o=c.getComputedStyle(t,e),a=o.getPropertyValue("font-family"),l=a.match(W),h=o.getPropertyValue("font-weight"),d=o.getPropertyValue("content");if(s&&!l)return t.removeChild(s),n();if(l&&"none"!==d&&""!==d){const c=o.getPropertyValue("content");let d=function(t,e){const r=t.replace(/^['"]|['"]$/g,"").toLowerCase(),n=parseInt(e),i=isNaN(n)?"normal":n;return(Ue[r]||{})[i]||Be[r]}(a,h);const{value:f,isSecondary:p}=function(t){const e=t.replace(Ge,""),r=function(t){const e=t.length;let r,n=t.charCodeAt(0);return n>=55296&&n<=56319&&e>1&&(r=t.charCodeAt(1),r>=56320&&r<=57343)?1024*(n-55296)+r-56320+65536:n}(e),n=r>=$e[0]&&r<=$e[1],i=2===e.length&&e[0]===e[1];return{value:Et(i?e[0]:e),isSecondary:n||i}}(c),m=l[0].startsWith("FontAwesome");let g=Nt(d,f),y=g;if(m){const t=function(t){const e=It[t],r=Nt("fas",t);return e||(r?{prefix:"fas",iconName:r}:null)||{prefix:null,iconName:null}}(f);t.iconName&&t.prefix&&(g=t.iconName,d=t.prefix)}if(!g||p||s&&s.getAttribute(O)===d&&s.getAttribute(R)===y)n();else{t.setAttribute(r,y),s&&t.removeChild(s);const o={iconName:null,title:null,titleId:null,prefix:null,transform:it,symbol:!1,mask:{iconName:null,prefix:null,rest:[]},maskId:null,extra:{classes:[],styles:{},attributes:{}}},{extra:a}=o;a.attributes[M]=e,ue(g,d).then((i=>{const s=se({...o,icons:{main:i,mask:{prefix:null,iconName:null,rest:[]}},prefix:d,iconName:y,extra:a,watchable:!0}),l=u.createElementNS("http://www.w3.org/2000/svg","svg");"::before"===e?t.insertBefore(l,t.firstChild):t.appendChild(l),l.outerHTML=s.map((t=>bt(t))).join("\n"),t.removeAttribute(r),n()})).catch(i)}}else n()}))}function qe(t){return Promise.all([Ve(t,"::before"),Ve(t,"::after")])}function Ke(t){return!(t.parentNode===document.head||~I.indexOf(t.tagName.toUpperCase())||t.getAttribute(M)||t.parentNode&&"svg"===t.parentNode.tagName)}function We(t){if(f)return new Promise(((e,r)=>{const n=ot(t.querySelectorAll("*")).filter(Ke).map(qe),i=pe("searchPseudoElements");Se(),Promise.all(n).then((()=>{i(),Ae(),e()})).catch((()=>{i(),Ae(),r()}))}))}var He={hooks:()=>({mutationObserverCallbacks:t=>(t.pseudoElementsCallback=We,t)}),provides(t){t.pseudoElements2svg=function(t){const{node:e=u}=t;et.searchPseudoElements&&We(e)}}};let Ye=!1;var Xe={mixout:()=>({dom:{unwatch(){Se(),Ye=!0}}}),hooks:()=>({bootstrap(){Te(Yt("mutationObserverCallbacks",{}))},noAuto(){Pe&&Pe.disconnect()},watch(t){const{observeMutationsRoot:e}=t;Ye?Ae():Te(Yt("mutationObserverCallbacks",{observeMutationsRoot:e}))}})};const Ze=t=>t.toLowerCase().split(" ").reduce(((t,e)=>{const r=e.toLowerCase().split("-"),n=r[0];let i=r.slice(1).join("-");if(n&&"h"===i)return t.flipX=!0,t;if(n&&"v"===i)return t.flipY=!0,t;if(i=parseFloat(i),isNaN(i))return t;switch(n){case"grow":t.size=t.size+i;break;case"shrink":t.size=t.size-i;break;case"left":t.x=t.x-i;break;case"right":t.x=t.x+i;break;case"up":t.y=t.y-i;break;case"down":t.y=t.y+i;break;case"rotate":t.rotate=t.rotate+i}return t}),{size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0});var Je={mixout:()=>({parse:{transform:t=>Ze(t)}}),hooks:()=>({parseNodeAttributes(t,e){const r=e.getAttribute("data-fa-transform");return r&&(t.transform=Ze(r)),t}}),provides(t){t.generateAbstractTransformGrouping=function(t){let{main:e,transform:r,containerWidth:n,iconWidth:i}=t;const s={transform:"translate(".concat(n/2," 256)")},o="translate(".concat(32*r.x,", ").concat(32*r.y,") "),a="scale(".concat(r.size/16*(r.flipX?-1:1),", ").concat(r.size/16*(r.flipY?-1:1),") "),l="rotate(".concat(r.rotate," 0 0)"),c={transform:"".concat(o," ").concat(a," ").concat(l)},u={transform:"translate(".concat(i/2*-1," -256)")};return{tag:"g",attributes:{...s},children:[{tag:"g",attributes:{...c},children:[{tag:e.icon.tag,children:e.icon.children,attributes:{...e.icon.attributes,...u}}]}]}}}};const Qe={x:0,y:0,width:"100%",height:"100%"};function tr(t){let e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return t.attributes&&(t.attributes.fill||e)&&(t.attributes.fill="black"),t}var er={hooks:()=>({parseNodeAttributes(t,e){const r=e.getAttribute("data-fa-mask"),n=r?Vt(r.split(" ").map((t=>t.trim()))):{prefix:null,iconName:null,rest:[]};return n.prefix||(n.prefix=zt()),t.mask=n,t.maskId=e.getAttribute("data-fa-mask-id"),t}}),provides(t){t.generateAbstractMask=function(t){let{children:e,attributes:r,main:n,mask:i,maskId:s,transform:o}=t;const{width:a,icon:l}=n,{width:c,icon:u}=i,h=function(t){let{transform:e,containerWidth:r,iconWidth:n}=t;const i={transform:"translate(".concat(r/2," 256)")},s="translate(".concat(32*e.x,", ").concat(32*e.y,") "),o="scale(".concat(e.size/16*(e.flipX?-1:1),", ").concat(e.size/16*(e.flipY?-1:1),") "),a="rotate(".concat(e.rotate," 0 0)");return{outer:i,inner:{transform:"".concat(s," ").concat(o," ").concat(a)},path:{transform:"translate(".concat(n/2*-1," -256)")}}}({transform:o,containerWidth:c,iconWidth:a}),d={tag:"rect",attributes:{...Qe,fill:"white"}},f=l.children?{children:l.children.map(tr)}:{},p={tag:"g",attributes:{...h.inner},children:[tr({tag:l.tag,attributes:{...l.attributes,...h.path},...f})]},m={tag:"g",attributes:{...h.outer},children:[p]},g="mask-".concat(s||st()),y="clip-".concat(s||st()),v={tag:"mask",attributes:{...Qe,id:g,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"},children:[d,m]},_={tag:"defs",children:[{tag:"clipPath",attributes:{id:y},children:(b=u,"g"===b.tag?b.children:[b])},v]};var b;return e.push(_,{tag:"rect",attributes:{fill:"currentColor","clip-path":"url(#".concat(y,")"),mask:"url(#".concat(g,")"),...Qe}}),{children:e,attributes:r}}}},rr={provides(t){let e=!1;c.matchMedia&&(e=c.matchMedia("(prefers-reduced-motion: reduce)").matches),t.missingIconAbstract=function(){const t=[],r={fill:"currentColor"},n={attributeType:"XML",repeatCount:"indefinite",dur:"2s"};t.push({tag:"path",attributes:{...r,d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"}});const i={...n,attributeName:"opacity"},s={tag:"circle",attributes:{...r,cx:"256",cy:"364",r:"28"},children:[]};return e||s.children.push({tag:"animate",attributes:{...n,attributeName:"r",values:"28;14;28;28;14;28;"}},{tag:"animate",attributes:{...i,values:"1;0;1;1;0;1;"}}),t.push(s),t.push({tag:"path",attributes:{...r,opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"},children:e?[]:[{tag:"animate",attributes:{...i,values:"1;0;0;0;0;1;"}}]}),e||t.push({tag:"path",attributes:{...r,opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"},children:[{tag:"animate",attributes:{...i,values:"0;0;1;1;0;0;"}}]}),{tag:"g",attributes:{class:"missing"},children:t}}}};!function(t,e){let{mixoutsTo:r}=e;qt=t,Kt={},Object.keys(Wt).forEach((t=>{-1===Ht.indexOf(t)&&delete Wt[t]})),qt.forEach((t=>{const e=t.mixout?t.mixout():{};if(Object.keys(e).forEach((t=>{"function"==typeof e[t]&&(r[t]=e[t]),"object"==typeof e[t]&&Object.keys(e[t]).forEach((n=>{r[t]||(r[t]={}),r[t][n]=e[t][n]}))})),t.hooks){const e=t.hooks();Object.keys(e).forEach((t=>{Kt[t]||(Kt[t]=[]),Kt[t].push(e[t])}))}t.provides&&t.provides(Wt)}))}([pt,Le,Fe,je,Ne,He,Xe,Je,er,rr,{hooks:()=>({parseNodeAttributes(t,e){const r=e.getAttribute("data-fa-symbol"),n=null!==r&&(""===r||r);return t.symbol=n,t}})}],{mixoutsTo:re});const nr=re.parse,ir=re.icon;var sr=r(39067),or=r.n(sr),ar=r(93345),lr=r.n(ar);function cr(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function ur(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?cr(Object(r),!0).forEach((function(e){dr(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):cr(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function hr(t){return hr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},hr(t)}function dr(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}function fr(t){return function(t){if(Array.isArray(t))return pr(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return pr(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?pr(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function pr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function mr(t){return e=t,(e-=0)==e?t:(t=t.replace(/[\-_\s]+(.)?/g,(function(t,e){return e?e.toUpperCase():""}))).substr(0,1).toLowerCase()+t.substr(1);var e}var gr=["style"],yr=!1;try{yr=!0}catch(t){}function vr(t){return t&&"object"===hr(t)&&t.prefix&&t.iconName&&t.icon?t:nr.icon?nr.icon(t):null===t?null:t&&"object"===hr(t)&&t.prefix&&t.iconName?t:Array.isArray(t)&&2===t.length?{prefix:t[0],iconName:t[1]}:"string"==typeof t?{prefix:"fas",iconName:t}:void 0}function _r(t,e){return Array.isArray(e)&&e.length>0||!Array.isArray(e)&&e?dr({},t,e):{}}var br={border:!1,className:"",mask:null,maskId:null,fixedWidth:!1,inverse:!1,flip:!1,icon:null,listItem:!1,pull:null,pulse:!1,rotation:null,size:null,spin:!1,spinPulse:!1,spinReverse:!1,beat:!1,fade:!1,beatFade:!1,bounce:!1,shake:!1,symbol:!1,title:"",titleId:null,transform:null,swapOpacity:!1},wr=lr().forwardRef((function(t,e){var r=ur(ur({},br),t),n=r.icon,i=r.mask,s=r.symbol,o=r.className,a=r.title,l=r.titleId,c=r.maskId,u=vr(n),h=_r("classes",[].concat(fr(function(t){var e,r=t.beat,n=t.fade,i=t.beatFade,s=t.bounce,o=t.shake,a=t.flash,l=t.spin,c=t.spinPulse,u=t.spinReverse,h=t.pulse,d=t.fixedWidth,f=t.inverse,p=t.border,m=t.listItem,g=t.flip,y=t.size,v=t.rotation,_=t.pull,b=(dr(e={"fa-beat":r,"fa-fade":n,"fa-beat-fade":i,"fa-bounce":s,"fa-shake":o,"fa-flash":a,"fa-spin":l,"fa-spin-reverse":u,"fa-spin-pulse":c,"fa-pulse":h,"fa-fw":d,"fa-inverse":f,"fa-border":p,"fa-li":m,"fa-flip":!0===g,"fa-flip-horizontal":"horizontal"===g||"both"===g,"fa-flip-vertical":"vertical"===g||"both"===g},"fa-".concat(y),null!=y),dr(e,"fa-rotate-".concat(v),null!=v&&0!==v),dr(e,"fa-pull-".concat(_),null!=_),dr(e,"fa-swap-opacity",t.swapOpacity),e);return Object.keys(b).map((function(t){return b[t]?t:null})).filter((function(t){return t}))}(r)),fr((o||"").split(" ")))),d=_r("transform","string"==typeof r.transform?nr.transform(r.transform):r.transform),f=_r("mask",vr(i)),p=ir(u,ur(ur(ur(ur({},h),d),f),{},{symbol:s,title:a,titleId:l,maskId:c}));if(!p)return function(){var t;!yr&&console&&"function"==typeof console.error&&(t=console).error.apply(t,arguments)}("Could not find icon",u),null;var m=p.abstract,g={ref:e};return Object.keys(r).forEach((function(t){br.hasOwnProperty(t)||(g[t]=r[t])})),xr(m[0],g)}));wr.displayName="FontAwesomeIcon",wr.propTypes={beat:or().bool,border:or().bool,beatFade:or().bool,bounce:or().bool,className:or().string,fade:or().bool,flash:or().bool,mask:or().oneOfType([or().object,or().array,or().string]),maskId:or().string,fixedWidth:or().bool,inverse:or().bool,flip:or().oneOf([!0,!1,"horizontal","vertical","both"]),icon:or().oneOfType([or().object,or().array,or().string]),listItem:or().bool,pull:or().oneOf(["right","left"]),pulse:or().bool,rotation:or().oneOf([0,90,180,270]),shake:or().bool,size:or().oneOf(["2xs","xs","sm","lg","xl","2xl","1x","2x","3x","4x","5x","6x","7x","8x","9x","10x"]),spin:or().bool,spinPulse:or().bool,spinReverse:or().bool,symbol:or().oneOfType([or().bool,or().string]),title:or().string,titleId:or().string,transform:or().oneOfType([or().string,or().object]),swapOpacity:or().bool};var xr=function t(e,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if("string"==typeof r)return r;var i=(r.children||[]).map((function(r){return t(e,r)})),s=Object.keys(r.attributes||{}).reduce((function(t,e){var n=r.attributes[e];switch(e){case"class":t.attrs.className=n,delete r.attributes.class;break;case"style":t.attrs.style=n.split(";").map((function(t){return t.trim()})).filter((function(t){return t})).reduce((function(t,e){var r,n=e.indexOf(":"),i=mr(e.slice(0,n)),s=e.slice(n+1).trim();return i.startsWith("webkit")?t[(r=i,r.charAt(0).toUpperCase()+r.slice(1))]=s:t[i]=s,t}),{});break;default:0===e.indexOf("aria-")||0===e.indexOf("data-")?t.attrs[e.toLowerCase()]=n:t.attrs[mr(e)]=n}return t}),{attrs:{}}),o=n.style,a=void 0===o?{}:o,l=function(t,e){if(null==t)return{};var r,n,i=function(t,e){if(null==t)return{};var r,n,i={},s=Object.keys(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||(i[r]=t[r]);return i}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(n=0;n<s.length;n++)r=s[n],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(i[r]=t[r])}return i}(n,gr);return s.attrs.style=ur(ur({},s.attrs.style),a),e.apply(void 0,[r.tag,ur(ur({},s.attrs),l)].concat(fr(i)))}.bind(null,lr().createElement)},80313:(t,e,r)=>{"use strict";function n(t,e){this.x=t,this.y=e}r.d(e,{cW:()=>c}),n.prototype={clone(){return new n(this.x,this.y)},add(t){return this.clone()._add(t)},sub(t){return this.clone()._sub(t)},multByPoint(t){return this.clone()._multByPoint(t)},divByPoint(t){return this.clone()._divByPoint(t)},mult(t){return this.clone()._mult(t)},div(t){return this.clone()._div(t)},rotate(t){return this.clone()._rotate(t)},rotateAround(t,e){return this.clone()._rotateAround(t,e)},matMult(t){return this.clone()._matMult(t)},unit(){return this.clone()._unit()},perp(){return this.clone()._perp()},round(){return this.clone()._round()},mag(){return Math.sqrt(this.x*this.x+this.y*this.y)},equals(t){return this.x===t.x&&this.y===t.y},dist(t){return Math.sqrt(this.distSqr(t))},distSqr(t){const e=t.x-this.x,r=t.y-this.y;return e*e+r*r},angle(){return Math.atan2(this.y,this.x)},angleTo(t){return Math.atan2(this.y-t.y,this.x-t.x)},angleWith(t){return this.angleWithSep(t.x,t.y)},angleWithSep(t,e){return Math.atan2(this.x*e-this.y*t,this.x*t+this.y*e)},_matMult(t){const e=t[0]*this.x+t[1]*this.y,r=t[2]*this.x+t[3]*this.y;return this.x=e,this.y=r,this},_add(t){return this.x+=t.x,this.y+=t.y,this},_sub(t){return this.x-=t.x,this.y-=t.y,this},_mult(t){return this.x*=t,this.y*=t,this},_div(t){return this.x/=t,this.y/=t,this},_multByPoint(t){return this.x*=t.x,this.y*=t.y,this},_divByPoint(t){return this.x/=t.x,this.y/=t.y,this},_unit(){return this._div(this.mag()),this},_perp(){const t=this.y;return this.y=this.x,this.x=-t,this},_rotate(t){const e=Math.cos(t),r=Math.sin(t),n=e*this.x-r*this.y,i=r*this.x+e*this.y;return this.x=n,this.y=i,this},_rotateAround(t,e){const r=Math.cos(t),n=Math.sin(t),i=e.x+r*(this.x-e.x)-n*(this.y-e.y),s=e.y+n*(this.x-e.x)+r*(this.y-e.y);return this.x=i,this.y=s,this},_round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},constructor:n},n.convert=function(t){if(t instanceof n)return t;if(Array.isArray(t))return new n(+t[0],+t[1]);if(void 0!==t.x&&void 0!==t.y)return new n(+t.x,+t.y);throw new Error("Expected [x, y] or {x, y} point format")};class i{constructor(t,e,r,n,i){this.properties={},this.extent=r,this.type=0,this.id=void 0,this._pbf=t,this._geometry=-1,this._keys=n,this._values=i,t.readFields(s,this,e)}loadGeometry(){const t=this._pbf;t.pos=this._geometry;const e=t.readVarint()+t.pos,r=[];let i,s=1,o=0,a=0,l=0;for(;t.pos<e;){if(o<=0){const e=t.readVarint();s=7&e,o=e>>3}if(o--,1===s||2===s)a+=t.readSVarint(),l+=t.readSVarint(),1===s&&(i&&r.push(i),i=[]),i&&i.push(new n(a,l));else{if(7!==s)throw new Error(`unknown command ${s}`);i&&i.push(i[0].clone())}}return i&&r.push(i),r}bbox(){const t=this._pbf;t.pos=this._geometry;const e=t.readVarint()+t.pos;let r=1,n=0,i=0,s=0,o=1/0,a=-1/0,l=1/0,c=-1/0;for(;t.pos<e;){if(n<=0){const e=t.readVarint();r=7&e,n=e>>3}if(n--,1===r||2===r)i+=t.readSVarint(),s+=t.readSVarint(),i<o&&(o=i),i>a&&(a=i),s<l&&(l=s),s>c&&(c=s);else if(7!==r)throw new Error(`unknown command ${r}`)}return[o,l,a,c]}toGeoJSON(t,e,r){const n=this.extent*Math.pow(2,r),i=this.extent*t,s=this.extent*e,a=this.loadGeometry();function l(t){return[360*(t.x+i)/n-180,360/Math.PI*Math.atan(Math.exp((1-2*(t.y+s)/n)*Math.PI))-90]}function c(t){return t.map(l)}let u;if(1===this.type){const t=[];for(const e of a)t.push(e[0]);const e=c(t);u=1===t.length?{type:"Point",coordinates:e[0]}:{type:"MultiPoint",coordinates:e}}else if(2===this.type){const t=a.map(c);u=1===t.length?{type:"LineString",coordinates:t[0]}:{type:"MultiLineString",coordinates:t}}else{if(3!==this.type)throw new Error("unknown feature type");{const t=function(t){const e=t.length;if(e<=1)return[t];const r=[];let n,i;for(let s=0;s<e;s++){const e=o(t[s]);0!==e&&(void 0===i&&(i=e<0),i===e<0?(n&&r.push(n),n=[t[s]]):n&&n.push(t[s]))}return n&&r.push(n),r}(a),e=[];for(const r of t)e.push(r.map(c));u=1===e.length?{type:"Polygon",coordinates:e[0]}:{type:"MultiPolygon",coordinates:e}}}const h={type:"Feature",geometry:u,properties:this.properties};return null!=this.id&&(h.id=this.id),h}}function s(t,e,r){1===t?e.id=r.readVarint():2===t?function(t,e){const r=t.readVarint()+t.pos;for(;t.pos<r;){const r=e._keys[t.readVarint()],n=e._values[t.readVarint()];e.properties[r]=n}}(r,e):3===t?e.type=r.readVarint():4===t&&(e._geometry=r.pos)}function o(t){let e=0;for(let r,n,i=0,s=t.length,o=s-1;i<s;o=i++)r=t[i],n=t[o],e+=(n.x-r.x)*(r.y+n.y);return e}i.types=["Unknown","Point","LineString","Polygon"];class a{constructor(t,e){this.version=1,this.name="",this.extent=4096,this.length=0,this._pbf=t,this._keys=[],this._values=[],this._features=[],t.readFields(l,this,e),this.length=this._features.length}feature(t){if(t<0||t>=this._features.length)throw new Error("feature index out of bounds");this._pbf.pos=this._features[t];const e=this._pbf.readVarint()+this._pbf.pos;return new i(this._pbf,e,this.extent,this._keys,this._values)}}function l(t,e,r){15===t?e.version=r.readVarint():1===t?e.name=r.readString():5===t?e.extent=r.readVarint():2===t?e._features.push(r.pos):3===t?e._keys.push(r.readString()):4===t&&e._values.push(function(t){let e=null;const r=t.readVarint()+t.pos;for(;t.pos<r;){const r=t.readVarint()>>3;e=1===r?t.readString():2===r?t.readFloat():3===r?t.readDouble():4===r?t.readVarint64():5===r?t.readVarint():6===r?t.readSVarint():7===r?t.readBoolean():null}return e}(r))}class c{constructor(t,e){this.layers=t.readFields(u,{},e)}}function u(t,e,r){if(3===t){const t=new a(r,r.readVarint()+r.pos);t.length&&(e[t.name]=t)}}},49004:(t,e,r)=>{"use strict";var n=r(10646),i=r(50709),s=r(43225),o=Math.pow(2,31)-1;function a(t,e){var r,n=1;if(0===t)return e;if(0===e)return t;for(;t%2==0&&e%2==0;)t/=2,e/=2,n*=2;for(;t%2==0;)t/=2;for(;e;){for(;e%2==0;)e/=2;t>e&&(r=e,e=t,t=r),e-=t}return n*t}function l(t,e){var r,n=0;if(0===t)return e;if(0===e)return t;for(;!(1&t||1&e);)t>>>=1,e>>>=1,n++;for(;!(1&t);)t>>>=1;for(;e;){for(;!(1&e);)e>>>=1;t>e&&(r=e,e=t,t=r),e-=t}return t<<n}t.exports=function(){var t,e,r,c,u,h,d,f=arguments.length;for(t=new Array(f),d=0;d<f;d++)t[d]=arguments[d];if(i(t)){if(2===f)return(u=t[0])<0&&(u=-u),(h=t[1])<0&&(h=-h),u<=o&&h<=o?l(u,h):a(u,h);r=t}else{if(!n(t[0]))throw new TypeError("gcd()::invalid input argument. Must provide an array of integers. Value: `"+t[0]+"`.");if(f>1){if(r=t[0],e=t[1],!s(e))throw new TypeError("gcd()::invalid input argument. Accessor must be a function. Value: `"+e+"`.")}else r=t[0]}if((c=r.length)<2)return null;if(e){for(u=new Array(c),d=0;d<c;d++)u[d]=e(r[d],d);r=u}if(f<3&&!i(r))throw new TypeError("gcd()::invalid input argument. Accessed array values must be integers. Value: `"+r+"`.");for(d=0;d<c;d++)(u=r[d])<0&&(r[d]=-u);for(u=r[0],d=1;d<c;d++)u=(h=r[d])<=o&&u<=o?l(u,h):a(u,h);return u}},23050:(t,e,r)=>{"use strict";var n=r(49004),i=r(10646),s=r(50709),o=r(43225);t.exports=function(){var t,e,r,a,l,c,u,h=arguments.length;for(t=new Array(h),u=0;u<h;u++)t[u]=arguments[u];if(s(t)){if(2===h)return(l=t[0])<0&&(l=-l),(c=t[1])<0&&(c=-c),0===l||0===c?0:l/n(l,c)*c;r=t}else{if(!i(t[0]))throw new TypeError("lcm()::invalid input argument. Must provide an array of integers. Value: `"+t[0]+"`.");if(h>1){if(r=t[0],e=t[1],!o(e))throw new TypeError("lcm()::invalid input argument. Accessor must be a function. Value: `"+e+"`.")}else r=t[0]}if((a=r.length)<2)return null;if(e){for(l=new Array(a),u=0;u<a;u++)l[u]=e(r[u],u);r=l}if(h<3&&!s(r))throw new TypeError("lcm()::invalid input argument. Accessed array values must be integers. Value: `"+r+"`.");for(u=0;u<a;u++)(l=r[u])<0&&(r[u]=-l);for(l=r[0],u=1;u<a;u++){if(c=r[u],0===l||0===c)return 0;l=l/n(l,c)*c}return l}},51372:(t,e,r)=>{"use strict";var n=r(52371);t.exports=n},28610:(t,e,r)=>{"use strict";r(83336);var n=r(83190);t.exports=n("Array","fill")},92654:(t,e,r)=>{"use strict";r(59076);var n=r(83190);t.exports=n("Array","includes")},8125:(t,e,r)=>{"use strict";var n=r(51372);t.exports=n},55023:(t,e,r)=>{"use strict";var n=r(92490),i=r(57664),s=TypeError;t.exports=function(t){if(n(t))return t;throw new s(i(t)+" is not a function")}},780:t=>{"use strict";t.exports=function(){}},59760:(t,e,r)=>{"use strict";var n=r(69421),i=String,s=TypeError;t.exports=function(t){if(n(t))return t;throw new s(i(t)+" is not an object")}},86344:(t,e,r)=>{"use strict";var n=r(62434),i=r(88385),s=r(86719);t.exports=function(t){for(var e=n(this),r=s(e),o=arguments.length,a=i(o>1?arguments[1]:void 0,r),l=o>2?arguments[2]:void 0,c=void 0===l?r:i(l,r);c>a;)e[a++]=t;return e}},54372:(t,e,r)=>{"use strict";var n=r(97262),i=r(88385),s=r(86719),o=function(t){return function(e,r,o){var a=n(e),l=s(a);if(0===l)return!t&&-1;var c,u=i(o,l);if(t&&r!=r){for(;l>u;)if((c=a[u++])!=c)return!0}else for(;l>u;u++)if((t||u in a)&&a[u]===r)return t||u||0;return!t&&-1}};t.exports={includes:o(!0),indexOf:o(!1)}},92399:(t,e,r)=>{"use strict";var n=r(1299),i=n({}.toString),s=n("".slice);t.exports=function(t){return s(i(t),8,-1)}},35706:(t,e,r)=>{"use strict";var n=r(86039),i=r(1004),s=r(58729);t.exports=n?function(t,e,r){return i.f(t,e,s(1,r))}:function(t,e,r){return t[e]=r,t}},58729:t=>{"use strict";t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},45604:(t,e,r)=>{"use strict";var n=r(92543),i=Object.defineProperty;t.exports=function(t,e){try{i(n,t,{value:e,configurable:!0,writable:!0})}catch(r){n[t]=e}return e}},86039:(t,e,r)=>{"use strict";var n=r(48908);t.exports=!n((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]}))},33392:(t,e,r)=>{"use strict";var n=r(92543),i=r(69421),s=n.document,o=i(s)&&i(s.createElement);t.exports=function(t){return o?s.createElement(t):{}}},83190:(t,e,r)=>{"use strict";var n=r(97390);t.exports=n},39866:(t,e,r)=>{"use strict";var n=r(92543).navigator,i=n&&n.userAgent;t.exports=i?String(i):""},63870:(t,e,r)=>{"use strict";var n,i,s=r(92543),o=r(39866),a=s.process,l=s.Deno,c=a&&a.versions||l&&l.version,u=c&&c.v8;u&&(i=(n=u.split("."))[0]>0&&n[0]<4?1:+(n[0]+n[1])),!i&&o&&(!(n=o.match(/Edge\/(\d+)/))||n[1]>=74)&&(n=o.match(/Chrome\/(\d+)/))&&(i=+n[1]),t.exports=i},62547:(t,e,r)=>{"use strict";var n=r(92543),i=r(72312),s=r(66473),o=r(92490),a=r(25494).f,l=r(30599),c=r(13646),u=r(11351),h=r(35706),d=r(71228);r(47936);var f=function(t){var e=function(r,n,s){if(this instanceof e){switch(arguments.length){case 0:return new t;case 1:return new t(r);case 2:return new t(r,n)}return new t(r,n,s)}return i(t,this,arguments)};return e.prototype=t.prototype,e};t.exports=function(t,e){var r,i,p,m,g,y,v,_,b,w=t.target,x=t.global,E=t.stat,S=t.proto,A=x?n:E?n[w]:n[w]&&n[w].prototype,P=x?c:c[w]||h(c,w,{})[w],T=P.prototype;for(m in e)i=!(r=l(x?m:w+(E?".":"#")+m,t.forced))&&A&&d(A,m),y=P[m],i&&(v=t.dontCallGetSet?(b=a(A,m))&&b.value:A[m]),g=i&&v?v:e[m],(r||S||typeof y!=typeof g)&&(_=t.bind&&i?u(g,n):t.wrap&&i?f(g):S&&o(g)?s(g):g,(t.sham||g&&g.sham||y&&y.sham)&&h(_,"sham",!0),h(P,m,_),S&&(d(c,p=w+"Prototype")||h(c,p,{}),h(c[p],m,g),t.real&&T&&(r||!T[m])&&h(T,m,g)))}},48908:t=>{"use strict";t.exports=function(t){try{return!!t()}catch(t){return!0}}},72312:(t,e,r)=>{"use strict";var n=r(7649),i=Function.prototype,s=i.apply,o=i.call;t.exports="object"==typeof Reflect&&Reflect.apply||(n?o.bind(s):function(){return o.apply(s,arguments)})},11351:(t,e,r)=>{"use strict";var n=r(66473),i=r(55023),s=r(7649),o=n(n.bind);t.exports=function(t,e){return i(t),void 0===e?t:s?o(t,e):function(){return t.apply(e,arguments)}}},7649:(t,e,r)=>{"use strict";var n=r(48908);t.exports=!n((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")}))},83306:(t,e,r)=>{"use strict";var n=r(7649),i=Function.prototype.call;t.exports=n?i.bind(i):function(){return i.apply(i,arguments)}},66473:(t,e,r)=>{"use strict";var n=r(92399),i=r(1299);t.exports=function(t){if("Function"===n(t))return i(t)}},1299:(t,e,r)=>{"use strict";var n=r(7649),i=Function.prototype,s=i.call,o=n&&i.bind.bind(s,s);t.exports=n?o:function(t){return function(){return s.apply(t,arguments)}}},97390:(t,e,r)=>{"use strict";var n=r(13646),i=r(92543),s=r(92490),o=function(t){return s(t)?t:void 0};t.exports=function(t,e){return arguments.length<2?o(n[t])||o(i[t]):n[t]&&n[t][e]||i[t]&&i[t][e]}},85879:(t,e,r)=>{"use strict";var n=r(55023),i=r(47251);t.exports=function(t,e){var r=t[e];return i(r)?void 0:n(r)}},92543:function(t,e,r){"use strict";var n=function(t){return t&&t.Math===Math&&t};t.exports=n("object"==typeof globalThis&&globalThis)||n("object"==typeof window&&window)||n("object"==typeof self&&self)||n("object"==typeof r.g&&r.g)||n("object"==typeof this&&this)||function(){return this}()||Function("return this")()},71228:(t,e,r)=>{"use strict";var n=r(1299),i=r(62434),s=n({}.hasOwnProperty);t.exports=Object.hasOwn||function(t,e){return s(i(t),e)}},69936:(t,e,r)=>{"use strict";var n=r(86039),i=r(48908),s=r(33392);t.exports=!n&&!i((function(){return 7!==Object.defineProperty(s("div"),"a",{get:function(){return 7}}).a}))},96882:(t,e,r)=>{"use strict";var n=r(1299),i=r(48908),s=r(92399),o=Object,a=n("".split);t.exports=i((function(){return!o("z").propertyIsEnumerable(0)}))?function(t){return"String"===s(t)?a(t,""):o(t)}:o},92490:t=>{"use strict";var e="object"==typeof document&&document.all;t.exports=void 0===e&&void 0!==e?function(t){return"function"==typeof t||t===e}:function(t){return"function"==typeof t}},30599:(t,e,r)=>{"use strict";var n=r(48908),i=r(92490),s=/#|\.prototype\./,o=function(t,e){var r=l[a(t)];return r===u||r!==c&&(i(e)?n(e):!!e)},a=o.normalize=function(t){return String(t).replace(s,".").toLowerCase()},l=o.data={},c=o.NATIVE="N",u=o.POLYFILL="P";t.exports=o},47251:t=>{"use strict";t.exports=function(t){return null==t}},69421:(t,e,r)=>{"use strict";var n=r(92490);t.exports=function(t){return"object"==typeof t?null!==t:n(t)}},73712:t=>{"use strict";t.exports=!0},48730:(t,e,r)=>{"use strict";var n=r(97390),i=r(92490),s=r(31352),o=r(4711),a=Object;t.exports=o?function(t){return"symbol"==typeof t}:function(t){var e=n("Symbol");return i(e)&&s(e.prototype,a(t))}},86719:(t,e,r)=>{"use strict";var n=r(26257);t.exports=function(t){return n(t.length)}},14040:t=>{"use strict";var e=Math.ceil,r=Math.floor;t.exports=Math.trunc||function(t){var n=+t;return(n>0?r:e)(n)}},1004:(t,e,r)=>{"use strict";var n=r(86039),i=r(69936),s=r(42501),o=r(59760),a=r(9798),l=TypeError,c=Object.defineProperty,u=Object.getOwnPropertyDescriptor,h="enumerable",d="configurable",f="writable";e.f=n?s?function(t,e,r){if(o(t),e=a(e),o(r),"function"==typeof t&&"prototype"===e&&"value"in r&&f in r&&!r[f]){var n=u(t,e);n&&n[f]&&(t[e]=r.value,r={configurable:d in r?r[d]:n[d],enumerable:h in r?r[h]:n[h],writable:!1})}return c(t,e,r)}:c:function(t,e,r){if(o(t),e=a(e),o(r),i)try{return c(t,e,r)}catch(t){}if("get"in r||"set"in r)throw new l("Accessors not supported");return"value"in r&&(t[e]=r.value),t}},25494:(t,e,r)=>{"use strict";var n=r(86039),i=r(83306),s=r(34990),o=r(58729),a=r(97262),l=r(9798),c=r(71228),u=r(69936),h=Object.getOwnPropertyDescriptor;e.f=n?h:function(t,e){if(t=a(t),e=l(e),u)try{return h(t,e)}catch(t){}if(c(t,e))return o(!i(s.f,t,e),t[e])}},31352:(t,e,r)=>{"use strict";var n=r(1299);t.exports=n({}.isPrototypeOf)},34990:(t,e)=>{"use strict";var r={}.propertyIsEnumerable,n=Object.getOwnPropertyDescriptor,i=n&&!r.call({1:2},1);e.f=i?function(t){var e=n(this,t);return!!e&&e.enumerable}:r},59973:(t,e,r)=>{"use strict";var n=r(83306),i=r(92490),s=r(69421),o=TypeError;t.exports=function(t,e){var r,a;if("string"===e&&i(r=t.toString)&&!s(a=n(r,t)))return a;if(i(r=t.valueOf)&&!s(a=n(r,t)))return a;if("string"!==e&&i(r=t.toString)&&!s(a=n(r,t)))return a;throw new o("Can't convert object to primitive value")}},13646:t=>{"use strict";t.exports={}},65471:(t,e,r)=>{"use strict";var n=r(47251),i=TypeError;t.exports=function(t){if(n(t))throw new i("Can't call method on "+t);return t}},47936:(t,e,r)=>{"use strict";var n=r(73712),i=r(92543),s=r(45604),o="__core-js_shared__",a=t.exports=i[o]||s(o,{});(a.versions||(a.versions=[])).push({version:"3.38.1",mode:n?"pure":"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"})},37272:(t,e,r)=>{"use strict";var n=r(47936);t.exports=function(t,e){return n[t]||(n[t]=e||{})}},93958:(t,e,r)=>{"use strict";var n=r(63870),i=r(48908),s=r(92543).String;t.exports=!!Object.getOwnPropertySymbols&&!i((function(){var t=Symbol("symbol detection");return!s(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&n&&n<41}))},88385:(t,e,r)=>{"use strict";var n=r(92202),i=Math.max,s=Math.min;t.exports=function(t,e){var r=n(t);return r<0?i(r+e,0):s(r,e)}},97262:(t,e,r)=>{"use strict";var n=r(96882),i=r(65471);t.exports=function(t){return n(i(t))}},92202:(t,e,r)=>{"use strict";var n=r(14040);t.exports=function(t){var e=+t;return e!=e||0===e?0:n(e)}},26257:(t,e,r)=>{"use strict";var n=r(92202),i=Math.min;t.exports=function(t){var e=n(t);return e>0?i(e,9007199254740991):0}},62434:(t,e,r)=>{"use strict";var n=r(65471),i=Object;t.exports=function(t){return i(n(t))}},57836:(t,e,r)=>{"use strict";var n=r(83306),i=r(69421),s=r(48730),o=r(85879),a=r(59973),l=r(29800),c=TypeError,u=l("toPrimitive");t.exports=function(t,e){if(!i(t)||s(t))return t;var r,l=o(t,u);if(l){if(void 0===e&&(e="default"),r=n(l,t,e),!i(r)||s(r))return r;throw new c("Can't convert object to primitive value")}return void 0===e&&(e="number"),a(t,e)}},9798:(t,e,r)=>{"use strict";var n=r(57836),i=r(48730);t.exports=function(t){var e=n(t,"string");return i(e)?e:e+""}},57664:t=>{"use strict";var e=String;t.exports=function(t){try{return e(t)}catch(t){return"Object"}}},8995:(t,e,r)=>{"use strict";var n=r(1299),i=0,s=Math.random(),o=n(1..toString);t.exports=function(t){return"Symbol("+(void 0===t?"":t)+")_"+o(++i+s,36)}},4711:(t,e,r)=>{"use strict";var n=r(93958);t.exports=n&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},42501:(t,e,r)=>{"use strict";var n=r(86039),i=r(48908);t.exports=n&&i((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},29800:(t,e,r)=>{"use strict";var n=r(92543),i=r(37272),s=r(71228),o=r(8995),a=r(93958),l=r(4711),c=n.Symbol,u=i("wks"),h=l?c.for||c:c&&c.withoutSetter||o;t.exports=function(t){return s(u,t)||(u[t]=a&&s(c,t)?c[t]:h("Symbol."+t)),u[t]}},83336:(t,e,r)=>{"use strict";var n=r(62547),i=r(86344),s=r(780);n({target:"Array",proto:!0},{fill:i}),s("fill")},59076:(t,e,r)=>{"use strict";var n=r(62547),i=r(54372).includes,s=r(48908),o=r(780);n({target:"Array",proto:!0,forced:s((function(){return!Array(1).includes()}))},{includes:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}}),o("includes")},52371:(t,e,r)=>{"use strict";var n=r(28610);t.exports=n},8996:(t,e,r)=>{"use strict";function n(t,e,r){t.prototype=e.prototype=r,r.constructor=t}function i(t,e){var r=Object.create(t.prototype);for(var n in e)r[n]=e[n];return r}function s(){}r.d(e,{Qh:()=>S});var o=.7,a=1/o,l="\\s*([+-]?\\d+)\\s*",c="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",u="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",h=/^#([0-9a-f]{3,8})$/,d=new RegExp(`^rgb\\(${l},${l},${l}\\)$`),f=new RegExp(`^rgb\\(${u},${u},${u}\\)$`),p=new RegExp(`^rgba\\(${l},${l},${l},${c}\\)$`),m=new RegExp(`^rgba\\(${u},${u},${u},${c}\\)$`),g=new RegExp(`^hsl\\(${c},${u},${u}\\)$`),y=new RegExp(`^hsla\\(${c},${u},${u},${c}\\)$`),v={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function _(){return this.rgb().formatHex()}function b(){return this.rgb().formatRgb()}function w(t){var e,r;return t=(t+"").trim().toLowerCase(),(e=h.exec(t))?(r=e[1].length,e=parseInt(e[1],16),6===r?x(e):3===r?new A(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===r?E(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===r?E(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=d.exec(t))?new A(e[1],e[2],e[3],1):(e=f.exec(t))?new A(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=p.exec(t))?E(e[1],e[2],e[3],e[4]):(e=m.exec(t))?E(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=g.exec(t))?R(e[1],e[2]/100,e[3]/100,1):(e=y.exec(t))?R(e[1],e[2]/100,e[3]/100,e[4]):v.hasOwnProperty(t)?x(v[t]):"transparent"===t?new A(NaN,NaN,NaN,0):null}function x(t){return new A(t>>16&255,t>>8&255,255&t,1)}function E(t,e,r,n){return n<=0&&(t=e=r=NaN),new A(t,e,r,n)}function S(t,e,r,n){return 1===arguments.length?((i=t)instanceof s||(i=w(i)),i?new A((i=i.rgb()).r,i.g,i.b,i.opacity):new A):new A(t,e,r,null==n?1:n);var i}function A(t,e,r,n){this.r=+t,this.g=+e,this.b=+r,this.opacity=+n}function P(){return`#${O(this.r)}${O(this.g)}${O(this.b)}`}function T(){const t=C(this.opacity);return`${1===t?"rgb(":"rgba("}${M(this.r)}, ${M(this.g)}, ${M(this.b)}${1===t?")":`, ${t})`}`}function C(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function M(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function O(t){return((t=M(t))<16?"0":"")+t.toString(16)}function R(t,e,r,n){return n<=0?t=e=r=NaN:r<=0||r>=1?t=e=NaN:e<=0&&(t=NaN),new I(t,e,r,n)}function D(t){if(t instanceof I)return new I(t.h,t.s,t.l,t.opacity);if(t instanceof s||(t=w(t)),!t)return new I;if(t instanceof I)return t;var e=(t=t.rgb()).r/255,r=t.g/255,n=t.b/255,i=Math.min(e,r,n),o=Math.max(e,r,n),a=NaN,l=o-i,c=(o+i)/2;return l?(a=e===o?(r-n)/l+6*(r<n):r===o?(n-e)/l+2:(e-r)/l+4,l/=c<.5?o+i:2-o-i,a*=60):l=c>0&&c<1?0:a,new I(a,l,c,t.opacity)}function I(t,e,r,n){this.h=+t,this.s=+e,this.l=+r,this.opacity=+n}function k(t){return(t=(t||0)%360)<0?t+360:t}function L(t){return Math.max(0,Math.min(1,t||0))}function F(t,e,r){return 255*(t<60?e+(r-e)*t/60:t<180?r:t<240?e+(r-e)*(240-t)/60:e)}n(s,w,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:_,formatHex:_,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return D(this).formatHsl()},formatRgb:b,toString:b}),n(A,S,i(s,{brighter(t){return t=null==t?a:Math.pow(a,t),new A(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=null==t?o:Math.pow(o,t),new A(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new A(M(this.r),M(this.g),M(this.b),C(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:P,formatHex:P,formatHex8:function(){return`#${O(this.r)}${O(this.g)}${O(this.b)}${O(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:T,toString:T})),n(I,(function(t,e,r,n){return 1===arguments.length?D(t):new I(t,e,r,null==n?1:n)}),i(s,{brighter(t){return t=null==t?a:Math.pow(a,t),new I(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=null==t?o:Math.pow(o,t),new I(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*e,i=2*r-n;return new A(F(t>=240?t-240:t+120,i,n),F(t,i,n),F(t<120?t+240:t-120,i,n),this.opacity)},clamp(){return new I(k(this.h),L(this.s),L(this.l),C(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const t=C(this.opacity);return`${1===t?"hsl(":"hsla("}${k(this.h)}, ${100*L(this.s)}%, ${100*L(this.l)}%${1===t?")":`, ${t})`}`}}))},56075:t=>{"use strict";t.exports=function(t,e){e||(e={}),"function"==typeof e&&(e={cmp:e});var r,n="boolean"==typeof e.cycles&&e.cycles,i=e.cmp&&(r=e.cmp,function(t){return function(e,n){var i={key:e,value:t[e]},s={key:n,value:t[n]};return r(i,s)}}),s=[];return function t(e){if(e&&e.toJSON&&"function"==typeof e.toJSON&&(e=e.toJSON()),void 0!==e){if("number"==typeof e)return isFinite(e)?""+e:"null";if("object"!=typeof e)return JSON.stringify(e);var r,o;if(Array.isArray(e)){for(o="[",r=0;r<e.length;r++)r&&(o+=","),o+=t(e[r])||"null";return o+"]"}if(null===e)return"null";if(-1!==s.indexOf(e)){if(n)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}var a=s.push(e)-1,l=Object.keys(e).sort(i&&i(e));for(o="",r=0;r<l.length;r++){var c=l[r],u=t(e[c]);u&&(o&&(o+=","),o+=JSON.stringify(c)+":"+u)}return s.splice(a,1),"{"+o+"}"}}(t)}},79639:(t,e,r)=>{"use strict";const{normalizeIPv6:n,normalizeIPv4:i,removeDotSegments:s,recomposeAuthority:o,normalizeComponentEncoding:a}=r(89970),l=r(36855);function c(t,e,r,n){const i={};return n||(t=f(u(t,r),r),e=f(u(e,r),r)),!(r=r||{}).tolerant&&e.scheme?(i.scheme=e.scheme,i.userinfo=e.userinfo,i.host=e.host,i.port=e.port,i.path=s(e.path||""),i.query=e.query):(void 0!==e.userinfo||void 0!==e.host||void 0!==e.port?(i.userinfo=e.userinfo,i.host=e.host,i.port=e.port,i.path=s(e.path||""),i.query=e.query):(e.path?("/"===e.path.charAt(0)?i.path=s(e.path):(void 0===t.userinfo&&void 0===t.host&&void 0===t.port||t.path?t.path?i.path=t.path.slice(0,t.path.lastIndexOf("/")+1)+e.path:i.path=e.path:i.path="/"+e.path,i.path=s(i.path)),i.query=e.query):(i.path=t.path,void 0!==e.query?i.query=e.query:i.query=t.query),i.userinfo=t.userinfo,i.host=t.host,i.port=t.port),i.scheme=t.scheme),i.fragment=e.fragment,i}function u(t,e){const r={host:t.host,scheme:t.scheme,userinfo:t.userinfo,port:t.port,path:t.path,query:t.query,nid:t.nid,nss:t.nss,uuid:t.uuid,fragment:t.fragment,reference:t.reference,resourceName:t.resourceName,secure:t.secure,error:""},n=Object.assign({},e),i=[],a=l[(n.scheme||r.scheme||"").toLowerCase()];a&&a.serialize&&a.serialize(r,n),void 0!==r.path&&(n.skipEscape?r.path=unescape(r.path):(r.path=escape(r.path),void 0!==r.scheme&&(r.path=r.path.split("%3A").join(":")))),"suffix"!==n.reference&&r.scheme&&i.push(r.scheme,":");const c=o(r,n);if(void 0!==c&&("suffix"!==n.reference&&i.push("//"),i.push(c),r.path&&"/"!==r.path.charAt(0)&&i.push("/")),void 0!==r.path){let t=r.path;n.absolutePath||a&&a.absolutePath||(t=s(t)),void 0===c&&(t=t.replace(/^\/\//u,"/%2F")),i.push(t)}return void 0!==r.query&&i.push("?",r.query),void 0!==r.fragment&&i.push("#",r.fragment),i.join("")}const h=Array.from({length:127},((t,e)=>/[^!"$&'()*+,\-.;=_`a-z{}~]/u.test(String.fromCharCode(e)))),d=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function f(t,e){const r=Object.assign({},e),s={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0},o=-1!==t.indexOf("%");let a=!1;"suffix"===r.reference&&(t=(r.scheme?r.scheme+":":"")+"//"+t);const c=t.match(d);if(c){if(s.scheme=c[1],s.userinfo=c[3],s.host=c[4],s.port=parseInt(c[5],10),s.path=c[6]||"",s.query=c[7],s.fragment=c[8],isNaN(s.port)&&(s.port=c[5]),s.host){const t=i(s.host);if(!1===t.isIPV4){const e=n(t.host,{isIPV4:!1});s.host=e.host.toLowerCase(),a=e.isIPV6}else s.host=t.host,a=!0}void 0!==s.scheme||void 0!==s.userinfo||void 0!==s.host||void 0!==s.port||s.path||void 0!==s.query?void 0===s.scheme?s.reference="relative":void 0===s.fragment?s.reference="absolute":s.reference="uri":s.reference="same-document",r.reference&&"suffix"!==r.reference&&r.reference!==s.reference&&(s.error=s.error||"URI is not a "+r.reference+" reference.");const t=l[(r.scheme||s.scheme||"").toLowerCase()];if(!(r.unicodeSupport||t&&t.unicodeSupport)&&s.host&&(r.domainHost||t&&t.domainHost)&&!1===a&&function(t){let e=0;for(let r=0,n=t.length;r<n;++r)if(e=t.charCodeAt(r),e>126||h[e])return!0;return!1}(s.host))try{s.host=URL.domainToASCII(s.host.toLowerCase())}catch(t){s.error=s.error||"Host's domain name can not be converted to ASCII: "+t}(!t||t&&!t.skipNormalize)&&(o&&void 0!==s.scheme&&(s.scheme=unescape(s.scheme)),o&&void 0!==s.host&&(s.host=unescape(s.host)),void 0!==s.path&&s.path.length&&(s.path=escape(unescape(s.path))),void 0!==s.fragment&&s.fragment.length&&(s.fragment=encodeURI(decodeURIComponent(s.fragment)))),t&&t.parse&&t.parse(s,r)}else s.error=s.error||"URI can not be parsed.";return s}const p={SCHEMES:l,normalize:function(t,e){return"string"==typeof t?t=u(f(t,e),e):"object"==typeof t&&(t=f(u(t,e),e)),t},resolve:function(t,e,r){const n=Object.assign({scheme:"null"},r);return u(c(f(t,n),f(e,n),n,!0),{...n,skipEscape:!0})},resolveComponents:c,equal:function(t,e,r){return"string"==typeof t?(t=unescape(t),t=u(a(f(t,r),!0),{...r,skipEscape:!0})):"object"==typeof t&&(t=u(a(t,!0),{...r,skipEscape:!0})),"string"==typeof e?(e=unescape(e),e=u(a(f(e,r),!0),{...r,skipEscape:!0})):"object"==typeof e&&(e=u(a(e,!0),{...r,skipEscape:!0})),t.toLowerCase()===e.toLowerCase()},serialize:u,parse:f};t.exports=p,t.exports.default=p,t.exports.fastUri=p},36855:t=>{"use strict";const e=/^[\da-f]{8}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{4}\b-[\da-f]{12}$/iu,r=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;function n(t){return"boolean"==typeof t.secure?t.secure:"wss"===String(t.scheme).toLowerCase()}function i(t){return t.host||(t.error=t.error||"HTTP URIs must have a host."),t}function s(t){const e="https"===String(t.scheme).toLowerCase();return t.port!==(e?443:80)&&""!==t.port||(t.port=void 0),t.path||(t.path="/"),t}const o={scheme:"http",domainHost:!0,parse:i,serialize:s},a={scheme:"ws",domainHost:!0,parse:function(t){return t.secure=n(t),t.resourceName=(t.path||"/")+(t.query?"?"+t.query:""),t.path=void 0,t.query=void 0,t},serialize:function(t){if(t.port!==(n(t)?443:80)&&""!==t.port||(t.port=void 0),"boolean"==typeof t.secure&&(t.scheme=t.secure?"wss":"ws",t.secure=void 0),t.resourceName){const[e,r]=t.resourceName.split("?");t.path=e&&"/"!==e?e:void 0,t.query=r,t.resourceName=void 0}return t.fragment=void 0,t}},l={http:o,https:{scheme:"https",domainHost:o.domainHost,parse:i,serialize:s},ws:a,wss:{scheme:"wss",domainHost:a.domainHost,parse:a.parse,serialize:a.serialize},urn:{scheme:"urn",parse:function(t,e){if(!t.path)return t.error="URN can not be parsed",t;const n=t.path.match(r);if(n){const r=e.scheme||t.scheme||"urn";t.nid=n[1].toLowerCase(),t.nss=n[2];const i=`${r}:${e.nid||t.nid}`,s=l[i];t.path=void 0,s&&(t=s.parse(t,e))}else t.error=t.error||"URN can not be parsed.";return t},serialize:function(t,e){const r=e.scheme||t.scheme||"urn",n=t.nid.toLowerCase(),i=`${r}:${e.nid||n}`,s=l[i];s&&(t=s.serialize(t,e));const o=t,a=t.nss;return o.path=`${n||e.nid}:${a}`,e.skipEscape=!0,o},skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:function(t,r){const n=t;return n.uuid=n.nss,n.nss=void 0,r.tolerant||n.uuid&&e.test(n.uuid)||(n.error=n.error||"UUID is not valid."),n},serialize:function(t){const e=t;return e.nss=(t.uuid||"").toLowerCase(),e},skipNormalize:!0}};t.exports=l},94962:t=>{"use strict";t.exports={HEX:{0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15}}},89970:(t,e,r)=>{"use strict";const{HEX:n}=r(94962);function i(t){if(l(t,".")<3)return{host:t,isIPV4:!1};const e=t.match(/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/u)||[],[r]=e;return r?{host:a(r,"."),isIPV4:!0}:{host:t,isIPV4:!1}}function s(t,e=!1){let r="",i=!0;for(const e of t){if(void 0===n[e])return;"0"!==e&&!0===i&&(i=!1),i||(r+=e)}return e&&0===r.length&&(r="0"),r}function o(t,e={}){if(l(t,":")<2)return{host:t,isIPV6:!1};const r=function(t){let e=0;const r={error:!1,address:"",zone:""},n=[],i=[];let o=!1,a=!1,l=!1;function c(){if(i.length){if(!1===o){const t=s(i);if(void 0===t)return r.error=!0,!1;n.push(t)}i.length=0}return!0}for(let s=0;s<t.length;s++){const u=t[s];if("["!==u&&"]"!==u)if(":"!==u)if("%"===u){if(!c())break;o=!0}else i.push(u);else{if(!0===a&&(l=!0),!c())break;if(e++,n.push(":"),e>7){r.error=!0;break}s-1>=0&&":"===t[s-1]&&(a=!0)}}return i.length&&(o?r.zone=i.join(""):l?n.push(i.join("")):n.push(s(i))),r.address=n.join(""),r}(t);if(r.error)return{host:t,isIPV6:!1};{let t=r.address,e=r.address;return r.zone&&(t+="%"+r.zone,e+="%25"+r.zone),{host:t,escapedHost:e,isIPV6:!0}}}function a(t,e){let r="",n=!0;const i=t.length;for(let s=0;s<i;s++){const o=t[s];"0"===o&&n?(s+1<=i&&t[s+1]===e||s+1===i)&&(r+=o,n=!1):(n=o===e,r+=o)}return r}function l(t,e){let r=0;for(let n=0;n<t.length;n++)t[n]===e&&r++;return r}const c=/^\.\.?\//u,u=/^\/\.(?:\/|$)/u,h=/^\/\.\.(?:\/|$)/u,d=/^\/?(?:.|\n)*?(?=\/|$)/u;t.exports={recomposeAuthority:function(t,e){const r=[];if(void 0!==t.userinfo&&(r.push(t.userinfo),r.push("@")),void 0!==t.host){let e=unescape(t.host);const n=i(e);if(n.isIPV4)e=n.host;else{const r=o(n.host,{isIPV4:!1});e=!0===r.isIPV6?`[${r.escapedHost}]`:t.host}r.push(e)}return"number"!=typeof t.port&&"string"!=typeof t.port||(r.push(":"),r.push(String(t.port))),r.length?r.join(""):void 0},normalizeComponentEncoding:function(t,e){const r=!0!==e?escape:unescape;return void 0!==t.scheme&&(t.scheme=r(t.scheme)),void 0!==t.userinfo&&(t.userinfo=r(t.userinfo)),void 0!==t.host&&(t.host=r(t.host)),void 0!==t.path&&(t.path=r(t.path)),void 0!==t.query&&(t.query=r(t.query)),void 0!==t.fragment&&(t.fragment=r(t.fragment)),t},removeDotSegments:function(t){const e=[];for(;t.length;)if(t.match(c))t=t.replace(c,"");else if(t.match(u))t=t.replace(u,"/");else if(t.match(h))t=t.replace(h,"/"),e.pop();else if("."===t||".."===t)t="";else{const r=t.match(d);if(!r)throw new Error("Unexpected dot segment condition");{const n=r[0];t=t.slice(n.length),e.push(n)}}return e.join("")},normalizeIPv4:i,normalizeIPv6:o,stringArrayToHexStripped:s}},66519:function(t,e,r){var n=r(39907);t.exports=function(){"use strict";function t(t,e){var r,n=Object.keys(t);return Object.getOwnPropertySymbols&&(r=Object.getOwnPropertySymbols(t),e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)),n}function e(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{};r%2?t(Object(n),!0).forEach((function(t){var r,i;r=e,i=n[t],(t=u(t))in r?Object.defineProperty(r,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):r[t]=i})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):t(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function s(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,u(n.key),n)}}function o(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var n,i,s,o,a=[],l=!0,c=!1;try{if(s=(r=r.call(t)).next,0===e){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=s.call(r)).done)&&(a.push(n.value),a.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=r.return&&(o=r.return(),Object(o)!==o))return}finally{if(c)throw i}}return a}}(t,e)||l(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function a(t){return function(t){if(Array.isArray(t))return c(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||l(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(t,e){var r;if(t)return"string"==typeof t?c(t,e):"Map"===(r="Object"===(r=Object.prototype.toString.call(t).slice(8,-1))&&t.constructor?t.constructor.name:r)||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?c(t,e):void 0}function c(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function u(t){return t=function(t){if("object"!=typeof t||null===t)return t;var e=t[Symbol.toPrimitive];if(void 0===e)return String(t);if("object"!=typeof(e=e.call(t,"string")))return e;throw new TypeError("@@toPrimitive must return a primitive value.")}(t),"symbol"==typeof t?t:String(t)}function h(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function d(t){var e,r;return t.__esModule?t:("function"==typeof(e=t.default)?(r=function t(){return this instanceof t?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)}).prototype=e.prototype:r={},Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach((function(e){var n=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(r,e,n.get?n:{enumerable:!0,get:function(){return t[e]}})})),r)}var f,p=d(Object.freeze({__proto__:null,default:{}})),m="[object process]"===Object.prototype.toString.call(void 0!==n?n:0),g={exports:{}},y=d(Object.freeze({__proto__:null,default:{}})),v=d(Object.freeze({__proto__:null,default:{}})),_=g;f=(f="undefined"!=typeof document&&document.currentScript?document.currentScript.src:void 0)||"/index.js",_.exports=function(){var t,e,r,s,o,a,l,c,u,h,d=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},m=d;function g(){function t(t,e){if(!t)throw e+(new Error).stack}function e(t,e,r){this.start=t,this.end=e,this.audio=r}m.FS_createPath("/","usr",!0,!0),m.FS_createPath("/usr","share",!0,!0),m.FS_createPath("/usr/share","gdal",!0,!0),m.FS_createPath("/usr/share","proj",!0,!0),e.prototype={requests:{},open:function(t,e){this.name=e,this.requests[e]=this,m.addRunDependency("fp ".concat(this.name))},send:function(){},onload:function(){var t=this.byteArray.subarray(this.start,this.end);this.finish(t)},finish:function(t){m.FS_createDataFile(this.name,null,t,!0,!0,!0),m.removeRunDependency("fp ".concat(this.name)),this.requests[this.name]=null}};for(var n=r.files,i=0;i<n.length;++i)new e(n[i].start,n[i].end,n[i].audio||0).open("GET",n[i].filename);function s(n){t(n,"Loading data file failed."),t(n.constructor.name===ArrayBuffer.name,"bad input to processPackageData"),n=new Uint8Array(n);for(var i=(e.prototype.byteArray=n,r.files),s=0;s<i.length;++s)e.prototype.requests[i[s].filename].onload();m.removeRunDependency("datafile_/home/bugra/Documents/MiniProject/gdal3.js/build/package/gdal3WebAssembly.data")}m.addRunDependency("datafile_/home/bugra/Documents/MiniProject/gdal3.js/build/package/gdal3WebAssembly.data"),m.preloadResults||(m.preloadResults={}),m.preloadResults["/home/bugra/Documents/MiniProject/gdal3.js/build/package/gdal3WebAssembly.data"]={fromCache:!1},h?(s(h),h=null):u=s}m.ready=new Promise((function(r,n){t=r,e=n})),m.expectedDataFileDownloads||(m.expectedDataFileDownloads=0),m.expectedDataFileDownloads++,m.ENVIRONMENT_IS_PTHREAD||m.$ww||(r={files:[{filename:"/usr/share/gdal/GDALLogoBW.svg",start:0,end:13022},{filename:"/usr/share/gdal/GDALLogoColor.svg",start:13022,end:25327},{filename:"/usr/share/gdal/GDALLogoGS.svg",start:25327,end:37632},{filename:"/usr/share/gdal/LICENSE.TXT",start:37632,end:59473},{filename:"/usr/share/gdal/bag_template.xml",start:59473,end:68493},{filename:"/usr/share/gdal/cubewerx_extra.wkt",start:68493,end:80470},{filename:"/usr/share/gdal/default.rsc",start:80470,end:544102},{filename:"/usr/share/gdal/ecw_cs.wkt",start:544102,end:908134},{filename:"/usr/share/gdal/eedaconf.json",start:908134,end:908545},{filename:"/usr/share/gdal/epsg.wkt",start:908545,end:908572},{filename:"/usr/share/gdal/esri_StatePlane_extra.wkt",start:908572,end:1241118},{filename:"/usr/share/gdal/gdalicon.png",start:1241118,end:1243139},{filename:"/usr/share/gdal/gdalinfo_output.schema.json",start:1243139,end:1251130},{filename:"/usr/share/gdal/gdalmdiminfo_output.schema.json",start:1251130,end:1257673},{filename:"/usr/share/gdal/gdalvrt.xsd",start:1257673,end:1291600},{filename:"/usr/share/gdal/gfs.xsd",start:1291600,end:1308069},{filename:"/usr/share/gdal/gml_registry.xml",start:1308069,end:1314712},{filename:"/usr/share/gdal/gml_registry.xsd",start:1314712,end:1321174},{filename:"/usr/share/gdal/gmlasconf.xml",start:1321174,end:1328606},{filename:"/usr/share/gdal/gmlasconf.xsd",start:1328606,end:1377260},{filename:"/usr/share/gdal/grib2_center.csv",start:1377260,end:1381431},{filename:"/usr/share/gdal/grib2_process.csv",start:1381431,end:1386357},{filename:"/usr/share/gdal/grib2_subcenter.csv",start:1386357,end:1388685},{filename:"/usr/share/gdal/grib2_table_4_2_0_0.csv",start:1388685,end:1399048},{filename:"/usr/share/gdal/grib2_table_4_2_0_1.csv",start:1399048,end:1415553},{filename:"/usr/share/gdal/grib2_table_4_2_0_13.csv",start:1415553,end:1425149},{filename:"/usr/share/gdal/grib2_table_4_2_0_14.csv",start:1425149,end:1434700},{filename:"/usr/share/gdal/grib2_table_4_2_0_15.csv",start:1434700,end:1444546},{filename:"/usr/share/gdal/grib2_table_4_2_0_16.csv",start:1444546,end:1454217},{filename:"/usr/share/gdal/grib2_table_4_2_0_17.csv",start:1454217,end:1455140},{filename:"/usr/share/gdal/grib2_table_4_2_0_18.csv",start:1455140,end:1465364},{filename:"/usr/share/gdal/grib2_table_4_2_0_19.csv",start:1465364,end:1477238},{filename:"/usr/share/gdal/grib2_table_4_2_0_190.csv",start:1477238,end:1486745},{filename:"/usr/share/gdal/grib2_table_4_2_0_191.csv",start:1486745,end:1496365},{filename:"/usr/share/gdal/grib2_table_4_2_0_2.csv",start:1496365,end:1507257},{filename:"/usr/share/gdal/grib2_table_4_2_0_20.csv",start:1507257,end:1519548},{filename:"/usr/share/gdal/grib2_table_4_2_0_21.csv",start:1519548,end:1529810},{filename:"/usr/share/gdal/grib2_table_4_2_0_3.csv",start:1529810,end:1540368},{filename:"/usr/share/gdal/grib2_table_4_2_0_4.csv",start:1540368,end:1550679},{filename:"/usr/share/gdal/grib2_table_4_2_0_5.csv",start:1550679,end:1560505},{filename:"/usr/share/gdal/grib2_table_4_2_0_6.csv",start:1560505,end:1572147},{filename:"/usr/share/gdal/grib2_table_4_2_0_7.csv",start:1572147,end:1582639},{filename:"/usr/share/gdal/grib2_table_4_2_10_0.csv",start:1582639,end:1594461},{filename:"/usr/share/gdal/grib2_table_4_2_10_1.csv",start:1594461,end:1604086},{filename:"/usr/share/gdal/grib2_table_4_2_10_191.csv",start:1604086,end:1613720},{filename:"/usr/share/gdal/grib2_table_4_2_10_2.csv",start:1613720,end:1623832},{filename:"/usr/share/gdal/grib2_table_4_2_10_3.csv",start:1623832,end:1633821},{filename:"/usr/share/gdal/grib2_table_4_2_10_4.csv",start:1633821,end:1644637},{filename:"/usr/share/gdal/grib2_table_4_2_1_0.csv",start:1644637,end:1654779},{filename:"/usr/share/gdal/grib2_table_4_2_1_1.csv",start:1654779,end:1664434},{filename:"/usr/share/gdal/grib2_table_4_2_1_2.csv",start:1664434,end:1674232},{filename:"/usr/share/gdal/grib2_table_4_2_20_0.csv",start:1674232,end:1683875},{filename:"/usr/share/gdal/grib2_table_4_2_20_1.csv",start:1683875,end:1693726},{filename:"/usr/share/gdal/grib2_table_4_2_20_2.csv",start:1693726,end:1703232},{filename:"/usr/share/gdal/grib2_table_4_2_2_0.csv",start:1703232,end:1715898},{filename:"/usr/share/gdal/grib2_table_4_2_2_3.csv",start:1715898,end:1726532},{filename:"/usr/share/gdal/grib2_table_4_2_2_4.csv",start:1726532,end:1737760},{filename:"/usr/share/gdal/grib2_table_4_2_2_5.csv",start:1737760,end:1747273},{filename:"/usr/share/gdal/grib2_table_4_2_2_6.csv",start:1747273,end:1756872},{filename:"/usr/share/gdal/grib2_table_4_2_3_0.csv",start:1756872,end:1767823},{filename:"/usr/share/gdal/grib2_table_4_2_3_1.csv",start:1767823,end:1778486},{filename:"/usr/share/gdal/grib2_table_4_2_3_2.csv",start:1778486,end:1782319},{filename:"/usr/share/gdal/grib2_table_4_2_3_3.csv",start:1782319,end:1783103},{filename:"/usr/share/gdal/grib2_table_4_2_3_4.csv",start:1783103,end:1784154},{filename:"/usr/share/gdal/grib2_table_4_2_3_5.csv",start:1784154,end:1785074},{filename:"/usr/share/gdal/grib2_table_4_2_3_6.csv",start:1785074,end:1785893},{filename:"/usr/share/gdal/grib2_table_4_2_4_0.csv",start:1785893,end:1795446},{filename:"/usr/share/gdal/grib2_table_4_2_4_1.csv",start:1795446,end:1805132},{filename:"/usr/share/gdal/grib2_table_4_2_4_10.csv",start:1805132,end:1814833},{filename:"/usr/share/gdal/grib2_table_4_2_4_2.csv",start:1814833,end:1824493},{filename:"/usr/share/gdal/grib2_table_4_2_4_3.csv",start:1824493,end:1834215},{filename:"/usr/share/gdal/grib2_table_4_2_4_4.csv",start:1834215,end:1843905},{filename:"/usr/share/gdal/grib2_table_4_2_4_5.csv",start:1843905,end:1853400},{filename:"/usr/share/gdal/grib2_table_4_2_4_6.csv",start:1853400,end:1863033},{filename:"/usr/share/gdal/grib2_table_4_2_4_7.csv",start:1863033,end:1872589},{filename:"/usr/share/gdal/grib2_table_4_2_4_8.csv",start:1872589,end:1882275},{filename:"/usr/share/gdal/grib2_table_4_2_4_9.csv",start:1882275,end:1891811},{filename:"/usr/share/gdal/grib2_table_4_2_local_Canada.csv",start:1891811,end:1892144},{filename:"/usr/share/gdal/grib2_table_4_2_local_HPC.csv",start:1892144,end:1892231},{filename:"/usr/share/gdal/grib2_table_4_2_local_MRMS.csv",start:1892231,end:1907818},{filename:"/usr/share/gdal/grib2_table_4_2_local_NCEP.csv",start:1907818,end:1935795},{filename:"/usr/share/gdal/grib2_table_4_2_local_NDFD.csv",start:1935795,end:1938454},{filename:"/usr/share/gdal/grib2_table_4_2_local_index.csv",start:1938454,end:1938705},{filename:"/usr/share/gdal/grib2_table_4_5.csv",start:1938705,end:1948718},{filename:"/usr/share/gdal/grib2_table_versions.csv",start:1948718,end:1948756},{filename:"/usr/share/gdal/gt_datum.csv",start:1948756,end:1964560},{filename:"/usr/share/gdal/gt_ellips.csv",start:1964560,end:1966279},{filename:"/usr/share/gdal/header.dxf",start:1966279,end:1972851},{filename:"/usr/share/gdal/inspire_cp_BasicPropertyUnit.gfs",start:1972851,end:1974591},{filename:"/usr/share/gdal/inspire_cp_CadastralBoundary.gfs",start:1974591,end:1976241},{filename:"/usr/share/gdal/inspire_cp_CadastralParcel.gfs",start:1976241,end:1978691},{filename:"/usr/share/gdal/inspire_cp_CadastralZoning.gfs",start:1978691,end:1983503},{filename:"/usr/share/gdal/jpfgdgml_AdmArea.gfs",start:1983503,end:1985143},{filename:"/usr/share/gdal/jpfgdgml_AdmBdry.gfs",start:1985143,end:1986525},{filename:"/usr/share/gdal/jpfgdgml_AdmPt.gfs",start:1986525,end:1988158},{filename:"/usr/share/gdal/jpfgdgml_BldA.gfs",start:1988158,end:1989659},{filename:"/usr/share/gdal/jpfgdgml_BldL.gfs",start:1989659,end:1991162},{filename:"/usr/share/gdal/jpfgdgml_Cntr.gfs",start:1991162,end:1992663},{filename:"/usr/share/gdal/jpfgdgml_CommBdry.gfs",start:1992663,end:1994047},{filename:"/usr/share/gdal/jpfgdgml_CommPt.gfs",start:1994047,end:1995682},{filename:"/usr/share/gdal/jpfgdgml_Cstline.gfs",start:1995682,end:1997191},{filename:"/usr/share/gdal/jpfgdgml_ElevPt.gfs",start:1997191,end:1998691},{filename:"/usr/share/gdal/jpfgdgml_GCP.gfs",start:1998691,end:2001214},{filename:"/usr/share/gdal/jpfgdgml_LeveeEdge.gfs",start:2001214,end:2002600},{filename:"/usr/share/gdal/jpfgdgml_RailCL.gfs",start:2002600,end:2004107},{filename:"/usr/share/gdal/jpfgdgml_RdASL.gfs",start:2004107,end:2005358},{filename:"/usr/share/gdal/jpfgdgml_RdArea.gfs",start:2005358,end:2006873},{filename:"/usr/share/gdal/jpfgdgml_RdCompt.gfs",start:2006873,end:2008519},{filename:"/usr/share/gdal/jpfgdgml_RdEdg.gfs",start:2008519,end:2010161},{filename:"/usr/share/gdal/jpfgdgml_RdMgtBdry.gfs",start:2010161,end:2011547},{filename:"/usr/share/gdal/jpfgdgml_RdSgmtA.gfs",start:2011547,end:2013191},{filename:"/usr/share/gdal/jpfgdgml_RvrMgtBdry.gfs",start:2013191,end:2014579},{filename:"/usr/share/gdal/jpfgdgml_SBAPt.gfs",start:2014579,end:2015954},{filename:"/usr/share/gdal/jpfgdgml_SBArea.gfs",start:2015954,end:2017461},{filename:"/usr/share/gdal/jpfgdgml_SBBdry.gfs",start:2017461,end:2018714},{filename:"/usr/share/gdal/jpfgdgml_WA.gfs",start:2018714,end:2020211},{filename:"/usr/share/gdal/jpfgdgml_WL.gfs",start:2020211,end:2021710},{filename:"/usr/share/gdal/jpfgdgml_WStrA.gfs",start:2021710,end:2023213},{filename:"/usr/share/gdal/jpfgdgml_WStrL.gfs",start:2023213,end:2024718},{filename:"/usr/share/gdal/netcdf_config.xsd",start:2024718,end:2032209},{filename:"/usr/share/gdal/nitf_spec.xml",start:2032209,end:2219654},{filename:"/usr/share/gdal/nitf_spec.xsd",start:2219654,end:2228162},{filename:"/usr/share/gdal/ogrinfo_output.schema.json",start:2228162,end:2239289},{filename:"/usr/share/gdal/ogrvrt.xsd",start:2239289,end:2265210},{filename:"/usr/share/gdal/osmconf.ini",start:2265210,end:2270610},{filename:"/usr/share/gdal/ozi_datum.csv",start:2270610,end:2279092},{filename:"/usr/share/gdal/ozi_ellips.csv",start:2279092,end:2280441},{filename:"/usr/share/gdal/pci_datum.txt",start:2280441,end:2315535},{filename:"/usr/share/gdal/pci_ellips.txt",start:2315535,end:2319050},{filename:"/usr/share/gdal/pdfcomposition.xsd",start:2319050,end:2353384},{filename:"/usr/share/gdal/pds4_template.xml",start:2353384,end:2356817},{filename:"/usr/share/gdal/plscenesconf.json",start:2356817,end:2398189},{filename:"/usr/share/gdal/ruian_vf_ob_v1.gfs",start:2398189,end:2444924},{filename:"/usr/share/gdal/ruian_vf_st_uvoh_v1.gfs",start:2444924,end:2447520},{filename:"/usr/share/gdal/ruian_vf_st_v1.gfs",start:2447520,end:2493420},{filename:"/usr/share/gdal/ruian_vf_v1.gfs",start:2493420,end:2560672},{filename:"/usr/share/gdal/s57agencies.csv",start:2560672,end:2573976},{filename:"/usr/share/gdal/s57attributes.csv",start:2573976,end:2593977},{filename:"/usr/share/gdal/s57expectedinput.csv",start:2593977,end:2614862},{filename:"/usr/share/gdal/s57objectclasses.csv",start:2614862,end:2668287},{filename:"/usr/share/gdal/seed_2d.dgn",start:2668287,end:2677503},{filename:"/usr/share/gdal/seed_3d.dgn",start:2677503,end:2679551},{filename:"/usr/share/gdal/stateplane.csv",start:2679551,end:2689911},{filename:"/usr/share/gdal/template_tiles.mapml",start:2689911,end:2691858},{filename:"/usr/share/gdal/tms_LINZAntarticaMapTileGrid.json",start:2691858,end:2695973},{filename:"/usr/share/gdal/tms_MapML_APSTILE.json",start:2695973,end:2702246},{filename:"/usr/share/gdal/tms_MapML_CBMTILE.json",start:2702246,end:2710038},{filename:"/usr/share/gdal/tms_NZTM2000.json",start:2710038,end:2715303},{filename:"/usr/share/gdal/trailer.dxf",start:2715303,end:2717578},{filename:"/usr/share/gdal/vdv452.xml",start:2717578,end:2743394},{filename:"/usr/share/gdal/vdv452.xsd",start:2743394,end:2746248},{filename:"/usr/share/gdal/vicar.json",start:2746248,end:2749858},{filename:"/usr/share/proj/CH",start:2749858,end:2750955},{filename:"/usr/share/proj/GL27",start:2750955,end:2751683},{filename:"/usr/share/proj/ITRF2000",start:2751683,end:2753782},{filename:"/usr/share/proj/ITRF2008",start:2753782,end:2759464},{filename:"/usr/share/proj/ITRF2014",start:2759464,end:2762953},{filename:"/usr/share/proj/deformation_model.schema.json",start:2762953,end:2780624},{filename:"/usr/share/proj/nad.lst",start:2780624,end:2787009},{filename:"/usr/share/proj/nad27",start:2787009,end:2806544},{filename:"/usr/share/proj/nad83",start:2806544,end:2823137},{filename:"/usr/share/proj/other.extra",start:2823137,end:2827052},{filename:"/usr/share/proj/proj.db",start:2827052,end:11539244},{filename:"/usr/share/proj/proj.ini",start:11539244,end:11541351},{filename:"/usr/share/proj/projjson.schema.json",start:11541351,end:11579663},{filename:"/usr/share/proj/triangulation.schema.json",start:11579663,end:11588066},{filename:"/usr/share/proj/world",start:11588066,end:11595145}],remote_package_size:11595145},"object"===("undefined"==typeof window?"undefined":i(window))?window.encodeURIComponent(window.location.pathname.toString().substring(0,window.location.pathname.toString().lastIndexOf("/"))+"/"):void 0===n&&"undefined"!=typeof location&&encodeURIComponent(location.pathname.toString().substring(0,location.pathname.toString().lastIndexOf("/"))+"/"),S="gdal3WebAssembly.data","function"!=typeof m.locateFilePackage||m.locateFile||(m.locateFile=m.locateFilePackage,z("warning: you defined Module.locateFilePackage, that has been renamed to Module.locateFile (using your locateFilePackage for now)")),S=m.locateFile?m.locateFile(S,""):S,O=r.remote_package_size,u=null,(h=m.getPreloadedPackage?m.getPreloadedPackage(S,O):null)||(s=S,o=O,a=function(t){u?(u(t),u=null):h=t},l=function(t){console.error("package error:",t)},"object"===(void 0===n?"undefined":i(n))&&"object"===i(n.versions)&&"string"==typeof n.versions.node?p.readFile(s,(function(t,e){t?l(t):a(e.buffer)})):((c=new XMLHttpRequest).open("GET",s,!0),c.responseType="arraybuffer",c.onprogress=function(t){var e=s,r=o;if(t.total&&(r=t.total),t.loaded){c.addedTotal?m.dataFileDownloads[e].loaded=t.loaded:(c.addedTotal=!0,m.dataFileDownloads||(m.dataFileDownloads={}),m.dataFileDownloads[e]={loaded:t.loaded,total:r});var n,i=0,a=0,l=0;for(n in m.dataFileDownloads){var u=m.dataFileDownloads[n];i+=u.total,a+=u.loaded,l++}i=Math.ceil(i*m.expectedDataFileDownloads/l),m.setStatus&&m.setStatus("Downloading data... (".concat(a,"/").concat(i,")"))}else m.dataFileDownloads||m.setStatus&&m.setStatus("Downloading data...")},c.onerror=function(t){throw new Error("NetworkError for: "+s)},c.onload=function(t){if(!(200==c.status||304==c.status||206==c.status||0==c.status&&c.response))throw new Error(c.statusText+" : "+c.responseURL);var e=c.response;a(e)},c.send(null))),m.calledRun?g():(m.preRun||(m.preRun=[]),m.preRun.push(g)));var _,b,w,x,E,S=Object.assign({},m),A="./this.program",P=function(t,e){throw e},T="object"==("undefined"==typeof window?"undefined":i(window)),C="function"==typeof importScripts,M="object"==(void 0===n?"undefined":i(n))&&"object"==i(n.versions)&&"string"==typeof n.versions.node,O="";M?(_=p,b=y,O=C?b.dirname(O)+"/":"//",w=function(t,e){return t=nt(t)?new URL(t):b.normalize(t),_.readFileSync(t,e?void 0:"utf8")},x=function(t){return(t=w(t,!0)).buffer?t:new Uint8Array(t)},E=function(t,e,r){var n=!(3<arguments.length&&void 0!==arguments[3])||arguments[3];t=nt(t)?new URL(t):b.normalize(t),_.readFile(t,n?void 0:"utf8",(function(t,i){t?r(t):e(n?i.buffer:i)}))},!m.thisProgram&&1<n.argv.length&&(A=n.argv[1].replace(/\\/g,"/")),n.argv.slice(2),P=function(t,e){throw n.exitCode=t,e},m.inspect=function(){return"[Emscripten Module object]"}):(T||C)&&(C?O=self.location.href:"undefined"!=typeof document&&document.currentScript&&(O=document.currentScript.src),O=0!==(O=f||O).indexOf("blob:")?O.substr(0,O.replace(/[?#].*/,"").lastIndexOf("/")+1):"",w=function(t){var e=new XMLHttpRequest;return e.open("GET",t,!1),e.send(null),e.responseText},C&&(x=function(t){var e=new XMLHttpRequest;return e.open("GET",t,!1),e.responseType="arraybuffer",e.send(null),new Uint8Array(e.response)}),E=function(t,e,r){var n=new XMLHttpRequest;n.open("GET",t,!0),n.responseType="arraybuffer",n.onload=function(){200==n.status||0==n.status&&n.response?e(n.response):r()},n.onerror=r,n.send(null)});var R,D,I,k,L,F,j,N,G,$=m.print||console.log.bind(console),z=m.printErr||console.error.bind(console),U=(Object.assign(m,S),m.arguments&&m.arguments,m.thisProgram&&(A=m.thisProgram),m.quit&&(P=m.quit),m.wasmBinary&&(R=m.wasmBinary),"object"!=("undefined"==typeof WebAssembly?"undefined":i(WebAssembly))&&J("no native wasm support detected"),!1);function B(t,e){t||J(e)}function V(){var t=D.buffer;m.HEAP8=I=new Int8Array(t),m.HEAP16=L=new Int16Array(t),m.HEAPU8=k=new Uint8Array(t),m.HEAPU16=new Uint16Array(t),m.HEAP32=F=new Int32Array(t),m.HEAPU32=j=new Uint32Array(t),m.HEAPF32=N=new Float32Array(t),m.HEAPF64=G=new Float64Array(t)}var q=[],K=[],W=[],H=0,Y=null;function X(t){var e;H++,null!=(e=m.monitorRunDependencies)&&e.call(m,H)}function Z(t){var e;H--,null!=(e=m.monitorRunDependencies)&&e.call(m,H),0==H&&Y&&(e=Y,Y=null,e())}function J(t){null!=(r=m.onAbort)&&r.call(m,t),z(t="Aborted("+t+")"),U=!0,t+=". Build with -sASSERTIONS for more info.";var r=new WebAssembly.RuntimeError(t);throw e(r),r}var Q,tt,et,rt=function(t){return t.startsWith("data:application/octet-stream;base64,")},nt=function(t){return t.startsWith("file://")};function it(t){if(t==Q&&R)return new Uint8Array(R);if(x)return x(t);throw"both async and sync fetching of the wasm failed"}function st(t,e,r){return function(t){if(!R&&(T||C)){if("function"==typeof fetch&&!nt(t))return fetch(t,{credentials:"same-origin"}).then((function(e){if(e.ok)return e.arrayBuffer();throw"failed to load wasm binary file at '"+t+"'"})).catch((function(){return it(t)}));if(E)return new Promise((function(e,r){E(t,(function(t){return e(new Uint8Array(t))}),r)}))}return Promise.resolve().then((function(){return it(t)}))}(t).then((function(t){return WebAssembly.instantiate(t,e)})).then((function(t){return t})).then(r,(function(t){z("failed to asynchronously prepare wasm: ".concat(t)),J(t)}))}function ot(t){this.name="ExitStatus",this.message="Program terminated with exit(".concat(t,")"),this.status=t}function at(t){for(;0<t.length;)t.shift()(m)}rt(Q="gdal3WebAssembly.wasm")||(Xt=Q,Q=m.locateFile?m.locateFile(Xt,O):O+Xt);var lt=m.noExitRuntime||!0;function ct(t,e,r){for(var n=e+r,i=e;t[i]&&!(n<=i);)++i;if(16<i-e&&t.buffer&&ft)return ft.decode(t.subarray(e,i));for(var s="";e<i;){var o,a,l=t[e++];128&l?(a=63&t[e++],192==(224&l)?s+=String.fromCharCode((31&l)<<6|a):(o=63&t[e++],(l=224==(240&l)?(15&l)<<12|a<<6|o:(7&l)<<18|a<<12|o<<6|63&t[e++])<65536?s+=String.fromCharCode(l):(a=l-65536,s+=String.fromCharCode(55296|a>>10,56320|1023&a)))):s+=String.fromCharCode(l)}return s}function ut(t,e){return t?ct(k,t,e):""}function ht(t){var e=pt[t];return e||(t>=pt.length&&(pt.length=t+1),pt[t]=e=dt.get(t)),e}var dt,ft="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0,pt=[],mt=[],gt=0,yt=0;function vt(t){this.excPtr=t,this.ptr=t-24,this.set_type=function(t){j[this.ptr+4>>2]=t},this.get_type=function(){return j[this.ptr+4>>2]},this.set_destructor=function(t){j[this.ptr+8>>2]=t},this.get_destructor=function(){return j[this.ptr+8>>2]},this.set_caught=function(t){I[this.ptr+12|0]=t=t?1:0},this.get_caught=function(){return 0!=I[this.ptr+12|0]},this.set_rethrown=function(t){I[this.ptr+13|0]=t=t?1:0},this.get_rethrown=function(){return 0!=I[this.ptr+13|0]},this.init=function(t,e){this.set_adjusted_ptr(0),this.set_type(t),this.set_destructor(e)},this.set_adjusted_ptr=function(t){j[this.ptr+16>>2]=t},this.get_adjusted_ptr=function(){return j[this.ptr+16>>2]},this.get_exception_ptr=function(){var t;return Te(this.get_type())?j[this.excPtr>>2]:0!==(t=this.get_adjusted_ptr())?t:this.excPtr}}function _t(t){var e=yt;if(!e)return be(0),0;var r=new vt(e),n=(r.set_adjusted_ptr(e),r.get_type());if(n){for(var i in t){if(0===(i=t[i])||i===n)break;var s=r.ptr+16;if(Pe(i,n,s))return be(i),e}be(n)}else be(0);return e}var bt={isAbs:function(t){return"/"===t.charAt(0)},splitPath:function(t){return/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/.exec(t).slice(1)},normalizeArray:function(t,e){for(var r=0,n=t.length-1;0<=n;n--){var i=t[n];"."===i?t.splice(n,1):".."===i?(t.splice(n,1),r++):r&&(t.splice(n,1),r--)}if(e)for(;r;r--)t.unshift("..");return t},normalize:function(t){var e=bt.isAbs(t),r="/"===t.substr(-1);return(t=(t=bt.normalizeArray(t.split("/").filter((function(t){return!!t})),!e).join("/"))||e?t:".")&&r&&(t+="/"),(e?"/":"")+t},dirname:function(t){var e=(t=bt.splitPath(t))[0];return t=t[1],e||t?e+(t=t&&t.substr(0,t.length-1)):"."},basename:function(t){var e;return"/"===t?"/":-1===(e=(t=(t=bt.normalize(t)).replace(/\/$/,"")).lastIndexOf("/"))?t:t.substr(e+1)},join:function(){var t=Array.prototype.slice.call(arguments);return bt.normalize(t.join("/"))},join2:function(t,e){return bt.normalize(t+"/"+e)}},wt=function(t){return(wt=function(){if("object"==("undefined"==typeof crypto?"undefined":i(crypto))&&"function"==typeof crypto.getRandomValues)return function(t){return crypto.getRandomValues(t)};if(M)try{var t,e=v;return e.randomFillSync?function(t){return e.randomFillSync(t)}:(t=e.randomBytes,function(e){return e.set(t(e.byteLength)),e})}catch(t){}J("initRandomDevice")}())(t)},xt={resolve:function(){for(var t="",e=!1,r=arguments.length-1;-1<=r&&!e;r--){var n=0<=r?arguments[r]:Lt.cwd();if("string"!=typeof n)throw new TypeError("Arguments to path.resolve must be strings");if(!n)return"";t=n+"/"+t,e=bt.isAbs(n)}return(e?"/":"")+(t=bt.normalizeArray(t.split("/").filter((function(t){return!!t})),!e).join("/"))||"."},relative:function(t,e){function r(t){for(var e=0;e<t.length&&""===t[e];e++);for(var r=t.length-1;0<=r&&""===t[r];r--);return r<e?[]:t.slice(e,r-e+1)}t=xt.resolve(t).substr(1),e=xt.resolve(e).substr(1);for(var n=r(t.split("/")),i=r(e.split("/")),s=Math.min(n.length,i.length),o=s,a=0;a<s;a++)if(n[a]!==i[a]){o=a;break}var l=[];for(a=o;a<n.length;a++)l.push("..");return(l=l.concat(i.slice(o))).join("/")}},Et=[],St=function(t){for(var e=0,r=0;r<t.length;++r){var n=t.charCodeAt(r);n<=127?e++:n<=2047?e+=2:55296<=n&&n<=57343?(e+=4,++r):e+=3}return e},At=function(t,e,r,n){if(!(0<n))return 0;for(var i=r,s=r+n-1,o=0;o<t.length;++o){var a=t.charCodeAt(o);if((a=55296<=a&&a<=57343?65536+((1023&a)<<10)|1023&t.charCodeAt(++o):a)<=127){if(s<=r)break;e[r++]=a}else{if(a<=2047){if(s<=r+1)break;e[r++]=192|a>>6}else{if(a<=65535){if(s<=r+2)break;e[r++]=224|a>>12}else{if(s<=r+3)break;e[r++]=240|a>>18,e[r++]=128|a>>12&63}e[r++]=128|a>>6&63}e[r++]=128|63&a}}return e[r]=0,r-i};function Pt(t,e,r){return r=0<r?r:St(t)+1,r=new Array(r),t=At(t,r,0,r.length),e&&(r.length=t),r}function Tt(t){r=t,e=65536,t=Math.ceil(r/e)*e;var e,r=ve(65536,t);return r?(e=r,r=t,k.fill(0,e,e+r),e):0}function Ct(t,e){var r=0;return t&&(r|=365),e&&(r|=146),r}var Mt={ttys:[],init:function(){},shutdown:function(){},register:function(t,e){Mt.ttys[t]={input:[],output:[],ops:e},Lt.registerDevice(t,Mt.stream_ops)},stream_ops:{open:function(t){var e=Mt.ttys[t.node.rdev];if(!e)throw new Lt.ErrnoError(43);t.tty=e,t.seekable=!1},close:function(t){t.tty.ops.fsync(t.tty)},fsync:function(t){t.tty.ops.fsync(t.tty)},read:function(t,e,r,n,i){if(!t.tty||!t.tty.ops.get_char)throw new Lt.ErrnoError(60);for(var s,o=0,a=0;a<n;a++){try{s=t.tty.ops.get_char(t.tty)}catch(t){throw new Lt.ErrnoError(29)}if(void 0===s&&0===o)throw new Lt.ErrnoError(6);if(null==s)break;o++,e[r+a]=s}return o&&(t.node.timestamp=Date.now()),o},write:function(t,e,r,n,i){if(!t.tty||!t.tty.ops.put_char)throw new Lt.ErrnoError(60);try{for(var s=0;s<n;s++)t.tty.ops.put_char(t.tty,e[r+s])}catch(t){throw new Lt.ErrnoError(29)}return n&&(t.node.timestamp=Date.now()),s}},default_tty_ops:{get_char:function(t){if(!Et.length){var e=null;if(M){var r=Buffer.alloc(256),i=0,s=n.stdin.fd;try{i=_.readSync(s,r)}catch(t){if(!t.toString().includes("EOF"))throw t;i=0}e=0<i?r.slice(0,i).toString("utf-8"):null}else"undefined"!=typeof window&&"function"==typeof window.prompt?null!==(e=window.prompt("Input: "))&&(e+="\n"):"function"==typeof readline&&null!==(e=readline())&&(e+="\n");if(!e)return null;Et=Pt(e,!0)}return Et.shift()},put_char:function(t,e){null===e||10===e?($(ct(t.output,0)),t.output=[]):0!=e&&t.output.push(e)},fsync:function(t){t.output&&0<t.output.length&&($(ct(t.output,0)),t.output=[])},ioctl_tcgets:function(t){return{c_iflag:25856,c_oflag:5,c_cflag:191,c_lflag:35387,c_cc:[3,28,127,21,4,0,1,0,17,19,26,0,18,15,23,22,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]}},ioctl_tcsets:function(t,e,r){return 0},ioctl_tiocgwinsz:function(t){return[24,80]}},default_tty1_ops:{put_char:function(t,e){null===e||10===e?(z(ct(t.output,0)),t.output=[]):0!=e&&t.output.push(e)},fsync:function(t){t.output&&0<t.output.length&&(z(ct(t.output,0)),t.output=[])}}},Ot={ops_table:null,mount:function(t){return Ot.createNode(null,"/",16895,0)},createNode:function(t,e,r,n){if(Lt.isBlkdev(r)||Lt.isFIFO(r))throw new Lt.ErrnoError(63);return Ot.ops_table||(Ot.ops_table={dir:{node:{getattr:Ot.node_ops.getattr,setattr:Ot.node_ops.setattr,lookup:Ot.node_ops.lookup,mknod:Ot.node_ops.mknod,rename:Ot.node_ops.rename,unlink:Ot.node_ops.unlink,rmdir:Ot.node_ops.rmdir,readdir:Ot.node_ops.readdir,symlink:Ot.node_ops.symlink},stream:{llseek:Ot.stream_ops.llseek}},file:{node:{getattr:Ot.node_ops.getattr,setattr:Ot.node_ops.setattr},stream:{llseek:Ot.stream_ops.llseek,read:Ot.stream_ops.read,write:Ot.stream_ops.write,allocate:Ot.stream_ops.allocate,mmap:Ot.stream_ops.mmap,msync:Ot.stream_ops.msync}},link:{node:{getattr:Ot.node_ops.getattr,setattr:Ot.node_ops.setattr,readlink:Ot.node_ops.readlink},stream:{}},chrdev:{node:{getattr:Ot.node_ops.getattr,setattr:Ot.node_ops.setattr},stream:Lt.chrdev_stream_ops}}),r=Lt.createNode(t,e,r,n),Lt.isDir(r.mode)?(r.node_ops=Ot.ops_table.dir.node,r.stream_ops=Ot.ops_table.dir.stream,r.contents={}):Lt.isFile(r.mode)?(r.node_ops=Ot.ops_table.file.node,r.stream_ops=Ot.ops_table.file.stream,r.usedBytes=0,r.contents=null):Lt.isLink(r.mode)?(r.node_ops=Ot.ops_table.link.node,r.stream_ops=Ot.ops_table.link.stream):Lt.isChrdev(r.mode)&&(r.node_ops=Ot.ops_table.chrdev.node,r.stream_ops=Ot.ops_table.chrdev.stream),r.timestamp=Date.now(),t&&(t.contents[e]=r,t.timestamp=r.timestamp),r},getFileDataAsTypedArray:function(t){return t.contents?t.contents.subarray?t.contents.subarray(0,t.usedBytes):new Uint8Array(t.contents):new Uint8Array(0)},expandFileStorage:function(t,e){var r=t.contents?t.contents.length:0;e<=r||(e=Math.max(e,r*(r<1048576?2:1.125)>>>0),0!=r&&(e=Math.max(e,256)),r=t.contents,t.contents=new Uint8Array(e),0<t.usedBytes&&t.contents.set(r.subarray(0,t.usedBytes),0))},resizeFileStorage:function(t,e){var r;t.usedBytes!=e&&(0==e?(t.contents=null,t.usedBytes=0):(r=t.contents,t.contents=new Uint8Array(e),r&&t.contents.set(r.subarray(0,Math.min(e,t.usedBytes))),t.usedBytes=e))},node_ops:{getattr:function(t){var e={};return e.dev=Lt.isChrdev(t.mode)?t.id:1,e.ino=t.id,e.mode=t.mode,e.nlink=1,e.uid=0,e.gid=0,e.rdev=t.rdev,Lt.isDir(t.mode)?e.size=4096:Lt.isFile(t.mode)?e.size=t.usedBytes:Lt.isLink(t.mode)?e.size=t.link.length:e.size=0,e.atime=new Date(t.timestamp),e.mtime=new Date(t.timestamp),e.ctime=new Date(t.timestamp),e.blksize=4096,e.blocks=Math.ceil(e.size/e.blksize),e},setattr:function(t,e){void 0!==e.mode&&(t.mode=e.mode),void 0!==e.timestamp&&(t.timestamp=e.timestamp),void 0!==e.size&&Ot.resizeFileStorage(t,e.size)},lookup:function(t,e){throw Lt.genericErrors[44]},mknod:function(t,e,r,n){return Ot.createNode(t,e,r,n)},rename:function(t,e,r){if(Lt.isDir(t.mode)){var n;try{n=Lt.lookupNode(e,r)}catch(t){}if(n)for(var i in n.contents)throw new Lt.ErrnoError(55)}delete t.parent.contents[t.name],t.parent.timestamp=Date.now(),t.name=r,e.contents[r]=t,e.timestamp=t.parent.timestamp,t.parent=e},unlink:function(t,e){delete t.contents[e],t.timestamp=Date.now()},rmdir:function(t,e){for(var r in Lt.lookupNode(t,e).contents)throw new Lt.ErrnoError(55);delete t.contents[e],t.timestamp=Date.now()},readdir:function(t){for(var e=[".",".."],r=0,n=Object.keys(t.contents);r<n.length;r++){var i=n[r];e.push(i)}return e},symlink:function(t,e,r){return(t=Ot.createNode(t,e,41471,0)).link=r,t},readlink:function(t){if(Lt.isLink(t.mode))return t.link;throw new Lt.ErrnoError(28)}},stream_ops:{read:function(t,e,r,n,i){var s=t.node.contents;if(i>=t.node.usedBytes)return 0;var o=Math.min(t.node.usedBytes-i,n);if(8<o&&s.subarray)e.set(s.subarray(i,i+o),r);else for(var a=0;a<o;a++)e[r+a]=s[i+a];return o},write:function(t,e,r,n,i,s){if(e.buffer===I.buffer&&(s=!1),!n)return 0;var o=t.node;if(o.timestamp=Date.now(),e.subarray&&(!o.contents||o.contents.subarray)){if(s)return o.contents=e.subarray(r,r+n),o.usedBytes=n;if(0===o.usedBytes&&0===i)return o.contents=e.slice(r,r+n),o.usedBytes=n;if(i+n<=o.usedBytes)return o.contents.set(e.subarray(r,r+n),i),n}if(Ot.expandFileStorage(o,i+n),o.contents.subarray&&e.subarray)o.contents.set(e.subarray(r,r+n),i);else for(var a=0;a<n;a++)o.contents[i+a]=e[r+a];return o.usedBytes=Math.max(o.usedBytes,i+n),n},llseek:function(t,e,r){if(1===r?e+=t.position:2===r&&Lt.isFile(t.node.mode)&&(e+=t.node.usedBytes),e<0)throw new Lt.ErrnoError(28);return e},allocate:function(t,e,r){Ot.expandFileStorage(t.node,e+r),t.node.usedBytes=Math.max(t.node.usedBytes,e+r)},mmap:function(t,e,r,n,i){if(!Lt.isFile(t.node.mode))throw new Lt.ErrnoError(43);var s,o;if(t=t.node.contents,2&i||t.buffer!==I.buffer){if((0<r||r+e<t.length)&&(t=t.subarray?t.subarray(r,r+e):Array.prototype.slice.call(t,r,r+e)),o=!0,!(s=Tt(e)))throw new Lt.ErrnoError(48);I.set(t,s)}else o=!1,s=t.byteOffset;return{ptr:s,allocated:o}},msync:function(t,e,r,n,i){return Ot.stream_ops.write(t,e,0,n,r,!1),0}}},Rt=m.preloadPlugins||[],Dt={EPERM:63,ENOENT:44,ESRCH:71,EINTR:27,EIO:29,ENXIO:60,E2BIG:1,ENOEXEC:45,EBADF:8,ECHILD:12,EAGAIN:6,EWOULDBLOCK:6,ENOMEM:48,EACCES:2,EFAULT:21,ENOTBLK:105,EBUSY:10,EEXIST:20,EXDEV:75,ENODEV:43,ENOTDIR:54,EISDIR:31,EINVAL:28,ENFILE:41,EMFILE:33,ENOTTY:59,ETXTBSY:74,EFBIG:22,ENOSPC:51,ESPIPE:70,EROFS:69,EMLINK:34,EPIPE:64,EDOM:18,ERANGE:68,ENOMSG:49,EIDRM:24,ECHRNG:106,EL2NSYNC:156,EL3HLT:107,EL3RST:108,ELNRNG:109,EUNATCH:110,ENOCSI:111,EL2HLT:112,EDEADLK:16,ENOLCK:46,EBADE:113,EBADR:114,EXFULL:115,ENOANO:104,EBADRQC:103,EBADSLT:102,EDEADLOCK:16,EBFONT:101,ENOSTR:100,ENODATA:116,ETIME:117,ENOSR:118,ENONET:119,ENOPKG:120,EREMOTE:121,ENOLINK:47,EADV:122,ESRMNT:123,ECOMM:124,EPROTO:65,EMULTIHOP:36,EDOTDOT:125,EBADMSG:9,ENOTUNIQ:126,EBADFD:127,EREMCHG:128,ELIBACC:129,ELIBBAD:130,ELIBSCN:131,ELIBMAX:132,ELIBEXEC:133,ENOSYS:52,ENOTEMPTY:55,ENAMETOOLONG:37,ELOOP:32,EOPNOTSUPP:138,EPFNOSUPPORT:139,ECONNRESET:15,ENOBUFS:42,EAFNOSUPPORT:5,EPROTOTYPE:67,ENOTSOCK:57,ENOPROTOOPT:50,ESHUTDOWN:140,ECONNREFUSED:14,EADDRINUSE:3,ECONNABORTED:13,ENETUNREACH:40,ENETDOWN:38,ETIMEDOUT:73,EHOSTDOWN:142,EHOSTUNREACH:23,EINPROGRESS:26,EALREADY:7,EDESTADDRREQ:17,EMSGSIZE:35,EPROTONOSUPPORT:66,ESOCKTNOSUPPORT:137,EADDRNOTAVAIL:4,ENETRESET:39,EISCONN:30,ENOTCONN:53,ETOOMANYREFS:141,EUSERS:136,EDQUOT:19,ESTALE:72,ENOTSUP:138,ENOMEDIUM:148,EILSEQ:25,EOVERFLOW:61,ECANCELED:11,ENOTRECOVERABLE:56,EOWNERDEAD:62,ESTRPIPE:135},It={isWindows:!1,staticInit:function(){It.isWindows=!!n.platform.match(/^win/);var t=n.binding("constants");t.fs&&(t=t.fs),It.flagsForNodeMap={1024:t.O_APPEND,64:t.O_CREAT,128:t.O_EXCL,256:t.O_NOCTTY,0:t.O_RDONLY,2:t.O_RDWR,4096:t.O_SYNC,512:t.O_TRUNC,1:t.O_WRONLY,131072:t.O_NOFOLLOW}},convertNodeCode:function(t){return t=t.code,Dt[t]},mount:function(t){return It.createNode(null,"/",It.getMode(t.opts.root),0)},createNode:function(t,e,r,n){if(Lt.isDir(r)||Lt.isFile(r)||Lt.isLink(r))return(t=Lt.createNode(t,e,r)).node_ops=It.node_ops,t.stream_ops=It.stream_ops,t;throw new Lt.ErrnoError(28)},getMode:function(t){var e;try{e=_.lstatSync(t),It.isWindows&&(e.mode=e.mode|(292&e.mode)>>2)}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}return e.mode},realPath:function(t){for(var e=[];t.parent!==t;)e.push(t.name),t=t.parent;return e.push(t.mount.opts.root),e.reverse(),bt.join.apply(null,e)},flagsForNode:function(t){t=-2097153&t&-2049&-32769&-524289&-65537;var e,r=0;for(e in It.flagsForNodeMap)t&e&&(r|=It.flagsForNodeMap[e],t^=e);if(t)throw new Lt.ErrnoError(28);return r},node_ops:{getattr:function(t){var e;t=It.realPath(t);try{e=_.lstatSync(t)}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}return It.isWindows&&!e.blksize&&(e.blksize=4096),It.isWindows&&!e.blocks&&(e.blocks=(e.size+e.blksize-1)/e.blksize|0),{dev:e.dev,ino:e.ino,mode:e.mode,nlink:e.nlink,uid:e.uid,gid:e.gid,rdev:e.rdev,size:e.size,atime:e.atime,mtime:e.mtime,ctime:e.ctime,blksize:e.blksize,blocks:e.blocks}},setattr:function(t,e){var r,n=It.realPath(t);try{void 0!==e.mode&&(_.chmodSync(n,e.mode),t.mode=e.mode),void 0!==e.timestamp&&(r=new Date(e.timestamp),_.utimesSync(n,r,r)),void 0!==e.size&&_.truncateSync(n,e.size)}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}},lookup:function(t,e){var r=bt.join2(It.realPath(t),e);return r=It.getMode(r),It.createNode(t,e,r)},mknod:function(t,e,r,n){t=It.createNode(t,e,r,n),e=It.realPath(t);try{Lt.isDir(t.mode)?_.mkdirSync(e,t.mode):_.writeFileSync(e,"",{mode:t.mode})}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}return t},rename:function(t,e,r){var n=It.realPath(t);e=bt.join2(It.realPath(e),r);try{_.renameSync(n,e)}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}t.name=r},unlink:function(t,e){t=bt.join2(It.realPath(t),e);try{_.unlinkSync(t)}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}},rmdir:function(t,e){t=bt.join2(It.realPath(t),e);try{_.rmdirSync(t)}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}},readdir:function(t){t=It.realPath(t);try{return _.readdirSync(t)}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}},symlink:function(t,e,r){t=bt.join2(It.realPath(t),e);try{_.symlinkSync(r,t)}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}},readlink:function(t){var e=It.realPath(t);try{return e=_.readlinkSync(e),b.relative(b.resolve(t.mount.opts.root),e)}catch(t){if(!t.code)throw t;if("UNKNOWN"===t.code)throw new Lt.ErrnoError(28);throw new Lt.ErrnoError(It.convertNodeCode(t))}}},stream_ops:{open:function(t){var e=It.realPath(t.node);try{Lt.isFile(t.node.mode)&&(t.nfd=_.openSync(e,It.flagsForNode(t.flags)))}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}},close:function(t){try{Lt.isFile(t.node.mode)&&t.nfd&&_.closeSync(t.nfd)}catch(t){if(t.code)throw new Lt.ErrnoError(It.convertNodeCode(t));throw t}},read:function(t,e,r,n,i){if(0===n)return 0;try{return _.readSync(t.nfd,new Int8Array(e.buffer,r,n),{position:i})}catch(t){throw new Lt.ErrnoError(It.convertNodeCode(t))}},write:function(t,e,r,n,i){try{return _.writeSync(t.nfd,new Int8Array(e.buffer,r,n),{position:i})}catch(t){throw new Lt.ErrnoError(It.convertNodeCode(t))}},llseek:function(t,e,r){if(1===r)e+=t.position;else if(2===r&&Lt.isFile(t.node.mode))try{e+=_.fstatSync(t.nfd).size}catch(t){throw new Lt.ErrnoError(It.convertNodeCode(t))}if(e<0)throw new Lt.ErrnoError(28);return e},mmap:function(t,e,r,n,i){var s;if(Lt.isFile(t.node.mode))return s=Tt(e),It.stream_ops.read(t,I,s,e,r),{ptr:s,allocated:!0};throw new Lt.ErrnoError(43)},msync:function(t,e,r,n,i){return It.stream_ops.write(t,e,0,n,r,!1),0}}},kt={DIR_MODE:16895,FILE_MODE:33279,reader:null,mount:function(t){B(C),kt.reader||(kt.reader=new FileReaderSync);var e=kt.createNode(null,"/",kt.DIR_MODE,0),r={};function n(t){for(var n=t.split("/"),i=e,s=0;s<n.length-1;s++){var o,a=n.slice(0,s+1).join("/");r[o=a]||(r[o]=kt.createNode(i,n[s],kt.DIR_MODE,0)),i=r[a]}return i}function i(t){return(t=t.split("/"))[t.length-1]}return Array.prototype.forEach.call(t.opts.files||[],(function(t){kt.createNode(n(t.name),i(t.name),kt.FILE_MODE,0,t,t.lastModifiedDate)})),(t.opts.blobs||[]).forEach((function(t){kt.createNode(n(t.name),i(t.name),kt.FILE_MODE,0,t.data)})),(t.opts.packages||[]).forEach((function(t){t.metadata.files.forEach((function(e){var r=e.filename.substr(1);kt.createNode(n(r),i(r),kt.FILE_MODE,0,t.blob.slice(e.start,e.end))}))})),e},createNode:function(t,e,r,n,i,s){var o=Lt.createNode(t,e,r);return o.mode=r,o.node_ops=kt.node_ops,o.stream_ops=kt.stream_ops,o.timestamp=(s||new Date).getTime(),B(kt.FILE_MODE!==kt.DIR_MODE),r===kt.FILE_MODE?(o.size=i.size,o.contents=i):(o.size=4096,o.contents={}),t&&(t.contents[e]=o),o},node_ops:{getattr:function(t){return{dev:1,ino:t.id,mode:t.mode,nlink:1,uid:0,gid:0,rdev:0,size:t.size,atime:new Date(t.timestamp),mtime:new Date(t.timestamp),ctime:new Date(t.timestamp),blksize:4096,blocks:Math.ceil(t.size/4096)}},setattr:function(t,e){void 0!==e.mode&&(t.mode=e.mode),void 0!==e.timestamp&&(t.timestamp=e.timestamp)},lookup:function(t,e){throw new Lt.ErrnoError(44)},mknod:function(t,e,r,n){throw new Lt.ErrnoError(63)},rename:function(t,e,r){throw new Lt.ErrnoError(63)},unlink:function(t,e){throw new Lt.ErrnoError(63)},rmdir:function(t,e){throw new Lt.ErrnoError(63)},readdir:function(t){for(var e=[".",".."],r=0,n=Object.keys(t.contents);r<n.length;r++){var i=n[r];e.push(i)}return e},symlink:function(t,e,r){throw new Lt.ErrnoError(63)}},stream_ops:{read:function(t,e,r,n,i){return i>=t.node.size?0:(t=t.node.contents.slice(i,i+n),i=kt.reader.readAsArrayBuffer(t),e.set(new Uint8Array(i),r),t.size)},write:function(t,e,r,n,i){throw new Lt.ErrnoError(29)},llseek:function(t,e,r){if(1===r?e+=t.position:2===r&&Lt.isFile(t.node.mode)&&(e+=t.node.size),e<0)throw new Lt.ErrnoError(28);return e}}},Lt={root:null,mounts:[],devices:{},streams:[],nextInode:1,nameTable:null,currentPath:"/",initialized:!1,ignorePermissions:!0,ErrnoError:null,genericErrors:{},filesystems:null,syncFSRequests:0,lookupPath:function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};if(!(t=xt.resolve(t)))return{path:"",node:null};if(8<(e=Object.assign({follow_mount:!0,recurse_count:0},e)).recurse_count)throw new Lt.ErrnoError(32);for(var r=t.split("/").filter((function(t){return!!t})),n=Lt.root,i="/",s=0;s<r.length;s++){var o=s===r.length-1;if(o&&e.parent)break;if(n=Lt.lookupNode(n,r[s]),i=bt.join2(i,r[s]),!Lt.isMountpoint(n)||o&&!e.follow_mount||(n=n.mounted.root),!o||e.follow)for(var a=0;Lt.isLink(n.mode);){var l=Lt.readlink(i);if(i=xt.resolve(bt.dirname(i),l),n=Lt.lookupPath(i,{recurse_count:e.recurse_count+1}).node,40<a++)throw new Lt.ErrnoError(32)}}return{path:i,node:n}},getPath:function(t){for(var e,r;;){if(Lt.isRoot(t))return r=t.mount.mountpoint,e?"/"!==r[r.length-1]?"".concat(r,"/").concat(e):r+e:r;e=e?"".concat(t.name,"/").concat(e):t.name,t=t.parent}},hashName:function(t,e){for(var r=0,n=0;n<e.length;n++)r=(r<<5)-r+e.charCodeAt(n)|0;return(t+r>>>0)%Lt.nameTable.length},hashAddNode:function(t){var e=Lt.hashName(t.parent.id,t.name);t.name_next=Lt.nameTable[e],Lt.nameTable[e]=t},hashRemoveNode:function(t){var e=Lt.hashName(t.parent.id,t.name);if(Lt.nameTable[e]===t)Lt.nameTable[e]=t.name_next;else for(var r=Lt.nameTable[e];r;){if(r.name_next===t){r.name_next=t.name_next;break}r=r.name_next}},lookupNode:function(t,e){if(r=Lt.mayLookup(t))throw new Lt.ErrnoError(r,t);for(var r=Lt.hashName(t.id,e),n=Lt.nameTable[r];n;n=n.name_next){var i=n.name;if(n.parent.id===t.id&&i===e)return n}return Lt.lookup(t,e)},createNode:function(t,e,r,n){return t=new Lt.FSNode(t,e,r,n),Lt.hashAddNode(t),t},destroyNode:function(t){Lt.hashRemoveNode(t)},isRoot:function(t){return t===t.parent},isMountpoint:function(t){return!!t.mounted},isFile:function(t){return 32768==(61440&t)},isDir:function(t){return 16384==(61440&t)},isLink:function(t){return 40960==(61440&t)},isChrdev:function(t){return 8192==(61440&t)},isBlkdev:function(t){return 24576==(61440&t)},isFIFO:function(t){return 4096==(61440&t)},isSocket:function(t){return!(49152&~t)},flagsToPermissionString:function(t){var e=["r","w","rw"][3&t];return 512&t&&(e+="w"),e},nodePermissions:function(t,e){return Lt.ignorePermissions||(!e.includes("r")||292&t.mode)&&(!e.includes("w")||146&t.mode)&&(!e.includes("x")||73&t.mode)?0:2},mayLookup:function(t){return Lt.nodePermissions(t,"x")||(t.node_ops.lookup?0:2)},mayCreate:function(t,e){try{return Lt.lookupNode(t,e),20}catch(t){}return Lt.nodePermissions(t,"wx")},mayDelete:function(t,e,r){var n;try{n=Lt.lookupNode(t,e)}catch(t){return t.errno}if(e=Lt.nodePermissions(t,"wx"))return e;if(r){if(!Lt.isDir(n.mode))return 54;if(Lt.isRoot(n)||Lt.getPath(n)===Lt.cwd())return 10}else if(Lt.isDir(n.mode))return 31;return 0},mayOpen:function(t,e){return t?Lt.isLink(t.mode)?32:Lt.isDir(t.mode)&&("r"!==Lt.flagsToPermissionString(e)||512&e)?31:Lt.nodePermissions(t,Lt.flagsToPermissionString(e)):44},MAX_OPEN_FDS:4096,nextfd:function(){for(var t=0;t<=Lt.MAX_OPEN_FDS;t++)if(!Lt.streams[t])return t;throw new Lt.ErrnoError(33)},getStreamChecked:function(t){if(t=Lt.getStream(t))return t;throw new Lt.ErrnoError(8)},getStream:function(t){return Lt.streams[t]},createStream:function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:-1;return Lt.FSStream||(Lt.FSStream=function(){this.shared={}},Lt.FSStream.prototype={},Object.defineProperties(Lt.FSStream.prototype,{object:{get:function(){return this.node},set:function(t){this.node=t}},isRead:{get:function(){return 1!=(2097155&this.flags)}},isWrite:{get:function(){return!!(2097155&this.flags)}},isAppend:{get:function(){return 1024&this.flags}},flags:{get:function(){return this.shared.flags},set:function(t){this.shared.flags=t}},position:{get:function(){return this.shared.position},set:function(t){this.shared.position=t}}})),t=Object.assign(new Lt.FSStream,t),-1==e&&(e=Lt.nextfd()),t.fd=e,Lt.streams[e]=t},closeStream:function(t){Lt.streams[t]=null},chrdev_stream_ops:{open:function(t){var e,r=Lt.getDevice(t.node.rdev);t.stream_ops=r.stream_ops,null!=(e=(r=t.stream_ops).open)&&e.call(r,t)},llseek:function(){throw new Lt.ErrnoError(70)}},major:function(t){return t>>8},minor:function(t){return 255&t},makedev:function(t,e){return t<<8|e},registerDevice:function(t,e){Lt.devices[t]={stream_ops:e}},getDevice:function(t){return Lt.devices[t]},getMounts:function(t){for(var e=[],r=[t];r.length;){var n=r.pop();e.push(n),r.push.apply(r,n.mounts)}return e},syncfs:function(t,e){"function"==typeof t&&(e=t,t=!1),Lt.syncFSRequests++,1<Lt.syncFSRequests&&z("warning: ".concat(Lt.syncFSRequests," FS.syncfs operations in flight at once, probably just doing extra work"));var r=Lt.getMounts(Lt.root.mount),n=0;function i(t){return Lt.syncFSRequests--,e(t)}function s(t){if(t)return s.errored?void 0:(s.errored=!0,i(t));++n>=r.length&&i(null)}r.forEach((function(e){if(!e.type.syncfs)return s(null);e.type.syncfs(e,t,s)}))},mount:function(t,e,r){var n,i="/"===r,s=!r;if(i&&Lt.root)throw new Lt.ErrnoError(10);if(!i&&!s){if(r=(s=Lt.lookupPath(r,{follow_mount:!1})).path,n=s.node,Lt.isMountpoint(n))throw new Lt.ErrnoError(10);if(!Lt.isDir(n.mode))throw new Lt.ErrnoError(54)}return s={type:t,opts:e,mountpoint:r,mounts:[]},((e=t.mount(s)).mount=s).root=e,i?Lt.root=e:n&&(n.mounted=s,n.mount)&&n.mount.mounts.push(s),e},unmount:function(t){if(t=Lt.lookupPath(t,{follow_mount:!1}),!Lt.isMountpoint(t.node))throw new Lt.ErrnoError(28);var e=(t=t.node).mounted,r=Lt.getMounts(e);Object.keys(Lt.nameTable).forEach((function(t){for(var e=Lt.nameTable[t];e;){var n=e.name_next;r.includes(e.mount)&&Lt.destroyNode(e),e=n}})),t.mounted=null,e=t.mount.mounts.indexOf(e),t.mount.mounts.splice(e,1)},lookup:function(t,e){return t.node_ops.lookup(t,e)},mknod:function(t,e,r){var n=Lt.lookupPath(t,{parent:!0}).node;if(!(t=bt.basename(t))||"."===t||".."===t)throw new Lt.ErrnoError(28);var i=Lt.mayCreate(n,t);if(i)throw new Lt.ErrnoError(i);if(n.node_ops.mknod)return n.node_ops.mknod(n,t,e,r);throw new Lt.ErrnoError(63)},create:function(t,e){return Lt.mknod(t,e=4095&(e=void 0!==e?e:438)|32768,0)},mkdir:function(t,e){return Lt.mknod(t,e=1023&(e=void 0!==e?e:511)|16384,0)},mkdirTree:function(t,e){for(var r=t.split("/"),n="",i=0;i<r.length;++i)if(r[i]){n+="/"+r[i];try{Lt.mkdir(n,e)}catch(t){if(20!=t.errno)throw t}}},mkdev:function(t,e,r){return void 0===r&&(r=e,e=438),Lt.mknod(t,e|=8192,r)},symlink:function(t,e){if(!xt.resolve(t))throw new Lt.ErrnoError(44);var r=Lt.lookupPath(e,{parent:!0}).node;if(!r)throw new Lt.ErrnoError(44);e=bt.basename(e);var n=Lt.mayCreate(r,e);if(n)throw new Lt.ErrnoError(n);if(r.node_ops.symlink)return r.node_ops.symlink(r,e,t);throw new Lt.ErrnoError(63)},rename:function(t,e){var r=bt.dirname(t),n=bt.dirname(e),i=bt.basename(t),s=bt.basename(e),o=(o=Lt.lookupPath(t,{parent:!0})).node,a=Lt.lookupPath(e,{parent:!0}).node;if(!o||!a)throw new Lt.ErrnoError(44);if(o.mount!==a.mount)throw new Lt.ErrnoError(75);var l,c=Lt.lookupNode(o,i);if("."!==(t=xt.relative(t,n)).charAt(0))throw new Lt.ErrnoError(28);if("."!==(t=xt.relative(e,r)).charAt(0))throw new Lt.ErrnoError(55);try{l=Lt.lookupNode(a,s)}catch(t){}if(c!==l){if(n=Lt.isDir(c.mode),e=Lt.mayDelete(o,i,n))throw new Lt.ErrnoError(e);if(e=l?Lt.mayDelete(a,s,n):Lt.mayCreate(a,s))throw new Lt.ErrnoError(e);if(!o.node_ops.rename)throw new Lt.ErrnoError(63);if(Lt.isMountpoint(c)||l&&Lt.isMountpoint(l))throw new Lt.ErrnoError(10);if(a!==o&&(e=Lt.nodePermissions(o,"w")))throw new Lt.ErrnoError(e);Lt.hashRemoveNode(c);try{o.node_ops.rename(c,a,s)}catch(t){throw t}finally{Lt.hashAddNode(c)}}},rmdir:function(t){var e=Lt.lookupPath(t,{parent:!0}).node,r=(t=bt.basename(t),Lt.lookupNode(e,t)),n=Lt.mayDelete(e,t,!0);if(n)throw new Lt.ErrnoError(n);if(!e.node_ops.rmdir)throw new Lt.ErrnoError(63);if(Lt.isMountpoint(r))throw new Lt.ErrnoError(10);e.node_ops.rmdir(e,t),Lt.destroyNode(r)},readdir:function(t){if((t=Lt.lookupPath(t,{follow:!0}).node).node_ops.readdir)return t.node_ops.readdir(t);throw new Lt.ErrnoError(54)},unlink:function(t){var e=Lt.lookupPath(t,{parent:!0}).node;if(!e)throw new Lt.ErrnoError(44);t=bt.basename(t);var r=Lt.lookupNode(e,t),n=Lt.mayDelete(e,t,!1);if(n)throw new Lt.ErrnoError(n);if(!e.node_ops.unlink)throw new Lt.ErrnoError(63);if(Lt.isMountpoint(r))throw new Lt.ErrnoError(10);e.node_ops.unlink(e,t),Lt.destroyNode(r)},readlink:function(t){if(!(t=Lt.lookupPath(t).node))throw new Lt.ErrnoError(44);if(t.node_ops.readlink)return xt.resolve(Lt.getPath(t.parent),t.node_ops.readlink(t));throw new Lt.ErrnoError(28)},stat:function(t,e){if(!(t=Lt.lookupPath(t,{follow:!e}).node))throw new Lt.ErrnoError(44);if(t.node_ops.getattr)return t.node_ops.getattr(t);throw new Lt.ErrnoError(63)},lstat:function(t){return Lt.stat(t,!0)},chmod:function(t,e,r){if(!(r="string"==typeof t?Lt.lookupPath(t,{follow:!r}).node:t).node_ops.setattr)throw new Lt.ErrnoError(63);r.node_ops.setattr(r,{mode:4095&e|-4096&r.mode,timestamp:Date.now()})},lchmod:function(t,e){Lt.chmod(t,e,!0)},fchmod:function(t,e){t=Lt.getStreamChecked(t),Lt.chmod(t.node,e)},chown:function(t,e,r,n){if(!(n="string"==typeof t?Lt.lookupPath(t,{follow:!n}).node:t).node_ops.setattr)throw new Lt.ErrnoError(63);n.node_ops.setattr(n,{timestamp:Date.now()})},lchown:function(t,e,r){Lt.chown(t,e,r,!0)},fchown:function(t,e,r){t=Lt.getStreamChecked(t),Lt.chown(t.node,e,r)},truncate:function(t,e){if(e<0)throw new Lt.ErrnoError(28);if(!(t="string"==typeof t?Lt.lookupPath(t,{follow:!0}).node:t).node_ops.setattr)throw new Lt.ErrnoError(63);if(Lt.isDir(t.mode))throw new Lt.ErrnoError(31);if(!Lt.isFile(t.mode))throw new Lt.ErrnoError(28);var r=Lt.nodePermissions(t,"w");if(r)throw new Lt.ErrnoError(r);t.node_ops.setattr(t,{size:e,timestamp:Date.now()})},ftruncate:function(t,e){if(!(2097155&(t=Lt.getStreamChecked(t)).flags))throw new Lt.ErrnoError(28);Lt.truncate(t.node,e)},utime:function(t,e,r){(t=Lt.lookupPath(t,{follow:!0}).node).node_ops.setattr(t,{timestamp:Math.max(e,r)})},open:function(t,e,r){if(""===t)throw new Lt.ErrnoError(44);if(r=void 0===r?438:r,r=64&(e="string"==typeof e?function(t){var e={r:0,"r+":2,w:577,"w+":578,a:1089,"a+":1090}[t];if(void 0===e)throw new Error("Unknown file open mode: ".concat(t));return e}(e):e)?4095&r|32768:0,"object"==i(t))n=t;else{t=bt.normalize(t);try{var n=Lt.lookupPath(t,{follow:!(131072&e)}).node}catch(t){}}var s=!1;if(64&e)if(n){if(128&e)throw new Lt.ErrnoError(20)}else n=Lt.mknod(t,r,0),s=!0;if(!n)throw new Lt.ErrnoError(44);if(Lt.isChrdev(n.mode)&&(e&=-513),65536&e&&!Lt.isDir(n.mode))throw new Lt.ErrnoError(54);if(!s&&(r=Lt.mayOpen(n,e)))throw new Lt.ErrnoError(r);return 512&e&&!s&&Lt.truncate(n,0),e&=-131713,(r=Lt.createStream({node:n,path:Lt.getPath(n),flags:e,seekable:!0,position:0,stream_ops:n.stream_ops,ungotten:[],error:!1})).stream_ops.open&&r.stream_ops.open(r),!m.logReadFiles||1&e||(Lt.readFiles||(Lt.readFiles={}),t in Lt.readFiles)||(Lt.readFiles[t]=1),r},close:function(t){if(Lt.isClosed(t))throw new Lt.ErrnoError(8);t.getdents&&(t.getdents=null);try{t.stream_ops.close&&t.stream_ops.close(t)}catch(t){throw t}finally{Lt.closeStream(t.fd)}t.fd=null},isClosed:function(t){return null===t.fd},llseek:function(t,e,r){if(Lt.isClosed(t))throw new Lt.ErrnoError(8);if(!t.seekable||!t.stream_ops.llseek)throw new Lt.ErrnoError(70);if(0!=r&&1!=r&&2!=r)throw new Lt.ErrnoError(28);return t.position=t.stream_ops.llseek(t,e,r),t.ungotten=[],t.position},read:function(t,e,r,n,i){if(n<0||i<0)throw new Lt.ErrnoError(28);if(Lt.isClosed(t))throw new Lt.ErrnoError(8);if(1==(2097155&t.flags))throw new Lt.ErrnoError(8);if(Lt.isDir(t.node.mode))throw new Lt.ErrnoError(31);if(!t.stream_ops.read)throw new Lt.ErrnoError(28);var s=void 0!==i;if(s){if(!t.seekable)throw new Lt.ErrnoError(70)}else i=t.position;return e=t.stream_ops.read(t,e,r,n,i),s||(t.position+=e),e},write:function(t,e,r,n,i,s){if(n<0||i<0)throw new Lt.ErrnoError(28);if(Lt.isClosed(t))throw new Lt.ErrnoError(8);if(!(2097155&t.flags))throw new Lt.ErrnoError(8);if(Lt.isDir(t.node.mode))throw new Lt.ErrnoError(31);if(!t.stream_ops.write)throw new Lt.ErrnoError(28);t.seekable&&1024&t.flags&&Lt.llseek(t,0,2);var o=void 0!==i;if(o){if(!t.seekable)throw new Lt.ErrnoError(70)}else i=t.position;return e=t.stream_ops.write(t,e,r,n,i,s),o||(t.position+=e),e},allocate:function(t,e,r){if(Lt.isClosed(t))throw new Lt.ErrnoError(8);if(e<0||r<=0)throw new Lt.ErrnoError(28);if(!(2097155&t.flags))throw new Lt.ErrnoError(8);if(!Lt.isFile(t.node.mode)&&!Lt.isDir(t.node.mode))throw new Lt.ErrnoError(43);if(!t.stream_ops.allocate)throw new Lt.ErrnoError(138);t.stream_ops.allocate(t,e,r)},mmap:function(t,e,r,n,i){if(2&n&&!(2&i)&&2!=(2097155&t.flags))throw new Lt.ErrnoError(2);if(1==(2097155&t.flags))throw new Lt.ErrnoError(2);if(t.stream_ops.mmap)return t.stream_ops.mmap(t,e,r,n,i);throw new Lt.ErrnoError(43)},msync:function(t,e,r,n,i){return t.stream_ops.msync?t.stream_ops.msync(t,e,r,n,i):0},munmap:function(t){return 0},ioctl:function(t,e,r){if(t.stream_ops.ioctl)return t.stream_ops.ioctl(t,e,r);throw new Lt.ErrnoError(59)},readFile:function(t){var e,r=1<arguments.length&&void 0!==arguments[1]?arguments[1]:{};if(r.flags=r.flags||0,r.encoding=r.encoding||"binary","utf8"!==r.encoding&&"binary"!==r.encoding)throw new Error('Invalid encoding type "'.concat(r.encoding,'"'));var n=Lt.open(t,r.flags),i=(t=Lt.stat(t).size,new Uint8Array(t));return Lt.read(n,i,0,t,0),"utf8"===r.encoding?e=ct(i,0):"binary"===r.encoding&&(e=i),Lt.close(n),e},writeFile:function(t,e){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:{};if(r.flags=r.flags||577,t=Lt.open(t,r.flags,r.mode),"string"==typeof e){var n=new Uint8Array(St(e)+1),i=At(e,n,0,n.length);Lt.write(t,n,0,i,void 0,r.canOwn)}else{if(!ArrayBuffer.isView(e))throw new Error("Unsupported data type");Lt.write(t,e,0,e.byteLength,void 0,r.canOwn)}Lt.close(t)},cwd:function(){return Lt.currentPath},chdir:function(t){if(null===(t=Lt.lookupPath(t,{follow:!0})).node)throw new Lt.ErrnoError(44);if(!Lt.isDir(t.node.mode))throw new Lt.ErrnoError(54);var e=Lt.nodePermissions(t.node,"x");if(e)throw new Lt.ErrnoError(e);Lt.currentPath=t.path},createDefaultDirectories:function(){Lt.mkdir("/tmp"),Lt.mkdir("/home"),Lt.mkdir("/home/web_user")},createDefaultDevices:function(){function t(){return 0===r&&(r=wt(e).byteLength),e[--r]}Lt.mkdir("/dev"),Lt.registerDevice(Lt.makedev(1,3),{read:function(){return 0},write:function(t,e,r,n,i){return n}}),Lt.mkdev("/dev/null",Lt.makedev(1,3)),Mt.register(Lt.makedev(5,0),Mt.default_tty_ops),Mt.register(Lt.makedev(6,0),Mt.default_tty1_ops),Lt.mkdev("/dev/tty",Lt.makedev(5,0)),Lt.mkdev("/dev/tty1",Lt.makedev(6,0));var e=new Uint8Array(1024),r=0;Lt.createDevice("/dev","random",t),Lt.createDevice("/dev","urandom",t),Lt.mkdir("/dev/shm"),Lt.mkdir("/dev/shm/tmp")},createSpecialDirectories:function(){Lt.mkdir("/proc");var t=Lt.mkdir("/proc/self");Lt.mkdir("/proc/self/fd"),Lt.mount({mount:function(){var e=Lt.createNode(t,"fd",16895,73);return e.node_ops={lookup:function(t,e){var r=Lt.getStreamChecked(+e);return(e={parent:null,mount:{mountpoint:"fake"},node_ops:{readlink:function(){return r.path}}}).parent=e}},e}},{},"/proc/self/fd")},createStandardStreams:function(){m.stdin?Lt.createDevice("/dev","stdin",m.stdin):Lt.symlink("/dev/tty","/dev/stdin"),m.stdout?Lt.createDevice("/dev","stdout",null,m.stdout):Lt.symlink("/dev/tty","/dev/stdout"),m.stderr?Lt.createDevice("/dev","stderr",null,m.stderr):Lt.symlink("/dev/tty1","/dev/stderr"),Lt.open("/dev/stdin",0),Lt.open("/dev/stdout",1),Lt.open("/dev/stderr",1)},ensureErrnoError:function(){Lt.ErrnoError||(Lt.ErrnoError=function(t,e){this.name="ErrnoError",this.node=e,this.setErrno=function(t){this.errno=t},this.setErrno(t),this.message="FS error"},Lt.ErrnoError.prototype=new Error,Lt.ErrnoError.prototype.constructor=Lt.ErrnoError,[44].forEach((function(t){Lt.genericErrors[t]=new Lt.ErrnoError(t),Lt.genericErrors[t].stack="<generic error, no stack>"})))},staticInit:function(){Lt.ensureErrnoError(),Lt.nameTable=new Array(4096),Lt.mount(Ot,{},"/"),Lt.createDefaultDirectories(),Lt.createDefaultDevices(),Lt.createSpecialDirectories(),Lt.filesystems={MEMFS:Ot,NODEFS:It,WORKERFS:kt}},init:function(t,e,r){Lt.init.initialized=!0,Lt.ensureErrnoError(),m.stdin=t||m.stdin,m.stdout=e||m.stdout,m.stderr=r||m.stderr,Lt.createStandardStreams()},quit:function(){Lt.init.initialized=!1;for(var t=0;t<Lt.streams.length;t++){var e=Lt.streams[t];e&&Lt.close(e)}},findObject:function(t,e){return(t=Lt.analyzePath(t,e)).exists?t.object:null},analyzePath:function(t,e){try{t=(n=Lt.lookupPath(t,{follow:!e})).path}catch(t){}var r={isRoot:!1,exists:!1,error:0,name:null,path:null,object:null,parentExists:!1,parentPath:null,parentObject:null};try{var n=Lt.lookupPath(t,{parent:!0});r.parentExists=!0,r.parentPath=n.path,r.parentObject=n.node,r.name=bt.basename(t),n=Lt.lookupPath(t,{follow:!e}),r.exists=!0,r.path=n.path,r.object=n.node,r.name=n.node.name,r.isRoot="/"===n.path}catch(t){r.error=t.errno}return r},createPath:function(t,e,r,n){t="string"==typeof t?t:Lt.getPath(t);for(var i=e.split("/").reverse();i.length;){var s=i.pop();if(s){var o=bt.join2(t,s);try{Lt.mkdir(o)}catch(t){}t=o}}return o},createFile:function(t,e,r,n,i){return t=bt.join2("string"==typeof t?t:Lt.getPath(t),e),e=Ct(n,i),Lt.create(t,e)},createDataFile:function(t,e,r,n,i,s){var o=e;if(t&&(t="string"==typeof t?t:Lt.getPath(t),o=e?bt.join2(t,e):t),e=Ct(n,i),t=Lt.create(o,e),r){if("string"==typeof r){for(var a=new Array(r.length),l=0,c=r.length;l<c;++l)a[l]=r.charCodeAt(l);r=a}Lt.chmod(t,146|e),n=Lt.open(t,577),Lt.write(n,r,0,r.length,0,s),Lt.close(n),Lt.chmod(t,e)}},createDevice:function(t,e,r,n){t=bt.join2("string"==typeof t?t:Lt.getPath(t),e),e=Ct(!!r,!!n);var i=(Lt.createDevice.major||(Lt.createDevice.major=64),Lt.makedev(Lt.createDevice.major++,0));return Lt.registerDevice(i,{open:function(t){t.seekable=!1},close:function(t){var e;null!=n&&null!=(e=n.buffer)&&e.length&&n(10)},read:function(t,e,n,i,s){for(var o,a=0,l=0;l<i;l++){try{o=r()}catch(t){throw new Lt.ErrnoError(29)}if(void 0===o&&0===a)throw new Lt.ErrnoError(6);if(null==o)break;a++,e[n+l]=o}return a&&(t.node.timestamp=Date.now()),a},write:function(t,e,r,i,s){for(var o=0;o<i;o++)try{n(e[r+o])}catch(t){throw new Lt.ErrnoError(29)}return i&&(t.node.timestamp=Date.now()),o}}),Lt.mkdev(t,e,i)},forceLoadFile:function(t){if(t.isDevice||t.isFolder||t.link||t.contents)return!0;if("undefined"!=typeof XMLHttpRequest)throw new Error("Lazy loading should have been performed (contents set) in createLazyFile, but it was not. Lazy loading only works in web workers. Use --embed-file or --preload-file in emcc on the main thread.");if(!w)throw new Error("Cannot load without read() or XMLHttpRequest.");try{t.contents=Pt(w(t.url),!0),t.usedBytes=t.contents.length}catch(t){throw new Lt.ErrnoError(29)}},createLazyFile:function(t,e,r,n,i){function s(){this.lengthKnown=!1,this.chunks=[]}if(s.prototype.get=function(t){var e;if(!(t>this.length-1||t<0))return e=t%this.chunkSize,t=t/this.chunkSize|0,this.getter(t)[e]},s.prototype.setDataGetter=function(t){this.getter=t},s.prototype.cacheLength=function(){if((i=new XMLHttpRequest).open("HEAD",r,!1),i.send(null),!(200<=i.status&&i.status<300||304===i.status))throw new Error("Couldn't load "+r+". Status: "+i.status);var t,e=Number(i.getResponseHeader("Content-length")),n=(t=i.getResponseHeader("Accept-Ranges"))&&"bytes"===t,i=(t=i.getResponseHeader("Content-Encoding"))&&"gzip"===t,s=1048576,o=(n||(s=e),this);o.setDataGetter((function(t){var n=t*s,i=(t+1)*s-1;if(i=Math.min(i,e-1),void 0===o.chunks[t]&&(o.chunks[t]=function(t,n){if(n<t)throw new Error("invalid range ("+t+", "+n+") or no bytes requested!");if(e-1<n)throw new Error("only "+e+" bytes available! programmer error!");var i=new XMLHttpRequest;if(i.open("GET",r,!1),e!==s&&i.setRequestHeader("Range","bytes="+t+"-"+n),i.responseType="arraybuffer",i.overrideMimeType&&i.overrideMimeType("text/plain; charset=x-user-defined"),i.send(null),200<=i.status&&i.status<300||304===i.status)return void 0!==i.response?new Uint8Array(i.response||[]):Pt(i.responseText||"",!0);throw new Error("Couldn't load "+r+". Status: "+i.status)}(n,i)),void 0===o.chunks[t])throw new Error("doXHR failed!");return o.chunks[t]})),!i&&e||(s=e=1,e=this.getter(0).length,s=e,$("LazyFiles on gzip forces download of the whole file when length is accessed")),this._length=e,this._chunkSize=s,this.lengthKnown=!0},"undefined"!=typeof XMLHttpRequest){if(!C)throw"Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc";var o=new s;Object.defineProperties(o,{length:{get:function(){return this.lengthKnown||this.cacheLength(),this._length}},chunkSize:{get:function(){return this.lengthKnown||this.cacheLength(),this._chunkSize}}}),o={isDevice:!1,contents:o}}else o={isDevice:!1,url:r};var a=Lt.createFile(t,e,o,n,i),l=(o.contents?a.contents=o.contents:o.url&&(a.contents=null,a.url=o.url),Object.defineProperties(a,{usedBytes:{get:function(){return this.contents.length}}}),{});function c(t,e,r,n,i){var s=t.node.contents;if(i>=s.length)return 0;var o=Math.min(s.length-i,n);if(s.slice)for(var a=0;a<o;a++)e[r+a]=s[i+a];else for(a=0;a<o;a++)e[r+a]=s.get(i+a);return o}return Object.keys(a.stream_ops).forEach((function(t){var e=a.stream_ops[t];l[t]=function(){return Lt.forceLoadFile(a),e.apply(null,arguments)}})),l.read=function(t,e,r,n,i){return Lt.forceLoadFile(a),c(t,e,r,n,i)},l.mmap=function(t,e,r,n,i){Lt.forceLoadFile(a);var s=Tt(e);if(s)return c(t,I,s,e,r),{ptr:s,allocated:!0};throw new Lt.ErrnoError(48)},a.stream_ops=l,a}},Ft={DEFAULT_POLLMASK:5,calculateAt:function(t,e,r){if(bt.isAbs(e))return e;if(t=-100===t?Lt.cwd():Ft.getStreamFromFD(t).path,0!=e.length)return bt.join2(t,e);if(r)return t;throw new Lt.ErrnoError(44)},doStat:function(t,e,r){try{var n=t(e)}catch(t){if(t&&t.node&&bt.normalize(e)!==bt.normalize(Lt.getPath(t.node)))return-54;throw t}F[r>>2]=n.dev,F[r+4>>2]=n.mode,j[r+8>>2]=n.nlink,F[r+12>>2]=n.uid,F[r+16>>2]=n.gid,F[r+20>>2]=n.rdev,et=[n.size>>>0,(tt=n.size,1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)],F[r+24>>2]=et[0],F[r+28>>2]=et[1],F[r+32>>2]=4096,F[r+36>>2]=n.blocks,t=n.atime.getTime(),e=n.mtime.getTime();var i=n.ctime.getTime();return et=[Math.floor(t/1e3)>>>0,(tt=Math.floor(t/1e3),1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)],F[r+40>>2]=et[0],F[r+44>>2]=et[1],j[r+48>>2]=t%1e3*1e3,et=[Math.floor(e/1e3)>>>0,(tt=Math.floor(e/1e3),1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)],F[r+56>>2]=et[0],F[r+60>>2]=et[1],j[r+64>>2]=e%1e3*1e3,et=[Math.floor(i/1e3)>>>0,(tt=Math.floor(i/1e3),1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)],F[r+72>>2]=et[0],F[r+76>>2]=et[1],j[r+80>>2]=i%1e3*1e3,et=[n.ino>>>0,(tt=n.ino,1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)],F[r+88>>2]=et[0],F[r+92>>2]=et[1],0},doMsync:function(t,e,r,n,i){if(!Lt.isFile(e.node.mode))throw new Lt.ErrnoError(43);if(2&n)return 0;t=k.slice(t,t+r),Lt.msync(e,t,i,r,n)},varargs:void 0,get:function(){var t=F[+Ft.varargs>>2];return Ft.varargs+=4,t},getp:function(){return Ft.get()},getStr:function(t){return ut(t)},getStreamFromFD:function(t){return Lt.getStreamChecked(t)}};function jt(t,e){return e+2097152>>>0<4194305-!!t?(t>>>0)+4294967296*e:NaN}function Nt(t){F[ge()>>2]=t}var Gt=function(t,e,r){return At(t,k,e,r)},$t={BUCKET_BUFFER_SIZE:8192,mount:function(t){return Lt.createNode(null,"/",16895,0)},createPipe:function(){var t=((i={buckets:[],refcnt:2}).buckets.push({buffer:new Uint8Array($t.BUCKET_BUFFER_SIZE),offset:0,roffset:0}),$t.nextname()),e=$t.nextname(),r=Lt.createNode($t.root,t,4096,0),n=Lt.createNode($t.root,e,4096,0),i=(r.pipe=i,n.pipe=i,Lt.createStream({path:t,node:r,flags:0,seekable:!1,stream_ops:$t.stream_ops}));return r.stream=i,t=Lt.createStream({path:e,node:n,flags:1,seekable:!1,stream_ops:$t.stream_ops}),n.stream=t,{readable_fd:i.fd,writable_fd:t.fd}},stream_ops:{poll:function(t){var e=t.node.pipe;if(1==(2097155&t.flags))return 260;if(0<e.buckets.length)for(var r=0;r<e.buckets.length;r++){var n=e.buckets[r];if(0<n.offset-n.roffset)return 65}return 0},ioctl:function(t,e,r){return 28},fsync:function(t){return 28},read:function(t,e,r,n,i){for(var s=t.node.pipe,o=0,a=0;a<s.buckets.length;a++){var l=s.buckets[a];o+=l.offset-l.roffset}var c=e.subarray(r,r+n);if(n<=0)return 0;if(0==o)throw new Lt.ErrnoError(6);var u=Math.min(o,n),h=(t=u,0);for(a=0;a<s.buckets.length;a++){var d=s.buckets[a],f=d.offset-d.roffset;if(u<=f){var p=d.buffer.subarray(d.roffset,d.offset);u<f?(p=p.subarray(0,u),d.roffset+=u):h++,c.set(p);break}p=d.buffer.subarray(d.roffset,d.offset),c.set(p),c=c.subarray(p.byteLength),u-=p.byteLength,h++}return h&&h==s.buckets.length&&(s.buckets[--h].offset=0,s.buckets[h].roffset=0),s.buckets.splice(0,h),t},write:function(t,e,r,n,i){var s=t.node.pipe,o=e.subarray(r,r+n);if((t=o.byteLength)<=0)return 0;if(e=null,0==s.buckets.length?(e={buffer:new Uint8Array($t.BUCKET_BUFFER_SIZE),offset:0,roffset:0},s.buckets.push(e)):e=s.buckets[s.buckets.length-1],B(e.offset<=$t.BUCKET_BUFFER_SIZE),t<=(r=$t.BUCKET_BUFFER_SIZE-e.offset))e.buffer.set(o,e.offset),e.offset+=t;else{0<r&&(e.buffer.set(o.subarray(0,r),e.offset),e.offset+=r,o=o.subarray(r,o.byteLength));for(var a=o.byteLength/$t.BUCKET_BUFFER_SIZE|0,l=(n=o.byteLength%$t.BUCKET_BUFFER_SIZE,0);l<a;l++){var c={buffer:new Uint8Array($t.BUCKET_BUFFER_SIZE),offset:$t.BUCKET_BUFFER_SIZE,roffset:0};s.buckets.push(c),c.buffer.set(o.subarray(0,$t.BUCKET_BUFFER_SIZE)),o=o.subarray($t.BUCKET_BUFFER_SIZE,o.byteLength)}0<n&&(c={buffer:new Uint8Array($t.BUCKET_BUFFER_SIZE),offset:o.byteLength,roffset:0},s.buckets.push(c),c.buffer.set(o))}return t},close:function(t){(t=t.node.pipe).refcnt--,0===t.refcnt&&(t.buckets=null)}},nextname:function(){return $t.nextname.current||($t.nextname.current=0),"pipe["+$t.nextname.current+++"]"}};function zt(t){return j[t>>2]+4294967296*F[t+4>>2]}function Ut(t){return(Bt(t.getFullYear())?Vt:qt)[t.getMonth()]+t.getDate()-1}var Bt=function(t){return t%4==0&&(t%100!=0||t%400==0)},Vt=[0,31,60,91,121,152,182,213,244,274,305,335],qt=[0,31,59,90,120,151,181,212,243,273,304,334];function Kt(t){var e=St(t)+1,r=ye(e);return r&&Gt(t,r,e),r}function Wt(){return 2147483648}function Ht(){if(!Ht.strings){var t={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",HOME:"/home/web_user",LANG:("object"==("undefined"==typeof navigator?"undefined":i(navigator))&&navigator.languages&&navigator.languages[0]||"C").replace("-","_")+".UTF-8",_:Jt()};for(e in Zt)void 0===Zt[e]?delete t[e]:t[e]=Zt[e];var e,r=[];for(e in t)r.push("".concat(e,"=").concat(t[e]));Ht.strings=r}return Ht.strings}function Yt(t){var e;te()||(null!=(e=m.onExit)&&e.call(m,t),U=!0),P(t,new ot(t))}var Xt=Wt,Zt={},Jt=function(){return A||"./this.program"},Qt=0,te=function(){return lt||0<Qt};function ee(t,e,r,n){for(var i=0,s=0;s<r;s++){var o=j[e>>2],a=j[e+4>>2];if(e+=8,(o=Lt.read(t,I,o,a,n))<0)return-1;if(i+=o,o<a)break;void 0!==n&&(n+=o)}return i}function re(t,e){I.set(t,e)}function ne(t,e,r,n){var i=j[n+40>>2],s={tm_sec:F[n>>2],tm_min:F[n+4>>2],tm_hour:F[n+8>>2],tm_mday:F[n+12>>2],tm_mon:F[n+16>>2],tm_year:F[n+20>>2],tm_wday:F[n+24>>2],tm_yday:F[n+28>>2],tm_isdst:F[n+32>>2],tm_gmtoff:F[n+36>>2],tm_zone:i?ut(i):""},o=ut(r),a={"%c":"%a %b %d %H:%M:%S %Y","%D":"%m/%d/%y","%F":"%Y-%m-%d","%h":"%b","%r":"%I:%M:%S %p","%R":"%H:%M","%T":"%H:%M:%S","%x":"%m/%d/%y","%X":"%H:%M:%S","%Ec":"%c","%EC":"%C","%Ex":"%m/%d/%y","%EX":"%H:%M:%S","%Ey":"%y","%EY":"%Y","%Od":"%d","%Oe":"%e","%OH":"%H","%OI":"%I","%Om":"%m","%OM":"%M","%OS":"%S","%Ou":"%u","%OU":"%U","%OV":"%V","%Ow":"%w","%OW":"%W","%Oy":"%y"};for(m in a)o=o.replace(new RegExp(m,"g"),a[m]);var l=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],c=["January","February","March","April","May","June","July","August","September","October","November","December"];function u(t,e,r){for(var n="number"==typeof t?t.toString():t||"";n.length<e;)n=r[0]+n;return n}function h(t,e){return u(t,e,"0")}function d(t,e){function r(t){return t<0?-1:0<t?1:0}var n;return 0===(n=r(t.getFullYear()-e.getFullYear()))&&0===(n=r(t.getMonth()-e.getMonth()))?r(t.getDate()-e.getDate()):n}function f(t){switch(t.getDay()){case 0:return new Date(t.getFullYear()-1,11,29);case 1:return t;case 2:return new Date(t.getFullYear(),0,3);case 3:return new Date(t.getFullYear(),0,2);case 4:return new Date(t.getFullYear(),0,1);case 5:return new Date(t.getFullYear()-1,11,31);case 6:return new Date(t.getFullYear()-1,11,30)}}function p(t){t=function(t,e){for(var r=new Date(t.getTime());0<e;){var n=Bt(r.getFullYear()),i=r.getMonth();if(!(e>(n=(n?ue:he)[i])-r.getDate()))return r.setDate(r.getDate()+e),r;e-=n-r.getDate()+1,r.setDate(1),i<11?r.setMonth(i+1):(r.setMonth(0),r.setFullYear(r.getFullYear()+1))}return r}(new Date(t.tm_year+1900,0,1),t.tm_yday);var e=new Date(t.getFullYear(),0,4),r=new Date(t.getFullYear()+1,0,4);return e=f(e),r=f(r),d(e,t)<=0?d(r,t)<=0?t.getFullYear()+1:t.getFullYear():t.getFullYear()-1}var m,g={"%a":function(t){return l[t.tm_wday].substring(0,3)},"%A":function(t){return l[t.tm_wday]},"%b":function(t){return c[t.tm_mon].substring(0,3)},"%B":function(t){return c[t.tm_mon]},"%C":function(t){return h((t.tm_year+1900)/100|0,2)},"%d":function(t){return h(t.tm_mday,2)},"%e":function(t){return u(t.tm_mday,2," ")},"%g":function(t){return p(t).toString().substring(2)},"%G":p,"%H":function(t){return h(t.tm_hour,2)},"%I":function(t){return 0==(t=t.tm_hour)?t=12:12<t&&(t-=12),h(t,2)},"%j":function(t){return h(t.tm_mday+function(t,e){for(var r=0,n=0;n<=e;r+=t[n++]);return r}(Bt(t.tm_year+1900)?ue:he,t.tm_mon-1),3)},"%m":function(t){return h(t.tm_mon+1,2)},"%M":function(t){return h(t.tm_min,2)},"%n":function(){return"\n"},"%p":function(t){return 0<=t.tm_hour&&t.tm_hour<12?"AM":"PM"},"%S":function(t){return h(t.tm_sec,2)},"%t":function(){return"\t"},"%u":function(t){return t.tm_wday||7},"%U":function(t){return t=t.tm_yday+7-t.tm_wday,h(Math.floor(t/7),2)},"%V":function(t){var e,r=Math.floor((t.tm_yday+7-(t.tm_wday+6)%7)/7);return(t.tm_wday+371-t.tm_yday-2)%7<=2&&r++,r?53!=r||4==(e=(t.tm_wday+371-t.tm_yday)%7)||3==e&&Bt(t.tm_year)||(r=1):(r=52,(4==(e=(t.tm_wday+7-t.tm_yday-1)%7)||5==e&&Bt(t.tm_year%400-1))&&r++),h(r,2)},"%w":function(t){return t.tm_wday},"%W":function(t){return t=t.tm_yday+7-(t.tm_wday+6)%7,h(Math.floor(t/7),2)},"%y":function(t){return(t.tm_year+1900).toString().substring(2)},"%Y":function(t){return t.tm_year+1900},"%z":function(t){var e=0<=(t=t.tm_gmtoff);return t=Math.abs(t)/60,(e?"+":"-")+String("0000"+(t/60*100+t%60)).slice(-4)},"%Z":function(t){return t.tm_zone},"%%":function(){return"%"}};for(m in o=o.replace(/%%/g,"\0\0"),g)o.includes(m)&&(o=o.replace(new RegExp(m,"g"),g[m](s)));return(n=Pt(o=o.replace(/\0\0/g,"%"),!1)).length>e?0:(re(n,t),n.length-1)}function ie(t){return m["_"+t]}function se(t,e,r,n,i){var s={string:function(t){var e,r,n=0;return null!=t&&0!==t&&(e=St(t)+1,r=Ee(e),Gt(t,r,e),n=r),n},array:function(t){var e=Ee(t.length);return re(t,e),e}},o=(t=ie(t),[]),a=0;if(n)for(var l=0;l<n.length;l++){var c=s[r[l]];c?(0===a&&(a=we()),o[l]=c(n[l])):o[l]=n[l]}return t=t=t.apply(null,o),0!==a&&xe(a),"string"===e?ut(t):"boolean"===e?Boolean(t):t}function oe(t,e){dt.set(t,e),pt[t]=dt.get(t)}function ae(t,e,r,n){this.parent=t=t||this,this.mount=t.mount,this.mounted=null,this.id=Lt.nextInode++,this.name=e,this.mode=r,this.node_ops={},this.stream_ops={},this.rdev=n}var le,ce,ue=[31,29,31,30,31,30,31,31,30,31,30,31],he=[31,28,31,30,31,30,31,31,30,31,30,31],de=function(t,e){t<128?e.push(t):e.push(t%128|128,t>>7)},fe=[],pe=(Object.defineProperties(ae.prototype,{read:{get:function(){return!(365&~this.mode)},set:function(t){t?this.mode|=365:this.mode&=-366}},write:{get:function(){return!(146&~this.mode)},set:function(t){t?this.mode|=146:this.mode&=-147}},isFolder:{get:function(){return Lt.isDir(this.mode)}},isDevice:{get:function(){return Lt.isChrdev(this.mode)}}}),Lt.FSNode=ae,Lt.createPreloadedFile=function(t,e,r,n,i,s,o,a,l,c){var u,h,d,f,p=e?xt.resolve(bt.join2(t,e)):t;function m(r){function u(r){null!=c&&c(),a||Lt.createDataFile(t,e,r,n,i,l),null!=s&&s(),Z()}var h,d,f,m,g;h=r,d=p,f=u,m=function(){null!=o&&o(),Z()},"undefined"!=typeof Browser&&Browser.init(),g=!1,Rt.forEach((function(t){g||t.canHandle(d)&&(t.handle(h,d,f,m),g=!0)})),g||u(r)}X(),"string"==typeof r?(h=function(t){m(t)},d=o,f="al ".concat(u=r),E(u,(function(t){B(t,'Loading data file "'.concat(u,'" failed (no arrayBuffer).')),h(new Uint8Array(t)),f&&Z()}),(function(t){if(!d)throw'Loading data file "'.concat(u,'" failed.');d()})),f&&X()):m(r)},Lt.staticInit(),m.FS_createPath=Lt.createPath,m.FS_createDataFile=Lt.createDataFile,m.FS_createPreloadedFile=Lt.createPreloadedFile,m.FS_unlink=Lt.unlink,m.FS_createLazyFile=Lt.createLazyFile,m.FS_createDevice=Lt.createDevice,M&&It.staticInit(),{y:function(t,e,r,n){J("Assertion failed: ".concat(ut(t),", at: ")+[e?ut(e):"unknown filename",r,n?ut(n):"unknown function"])},Ke:function(t,e){return ht(t)(e)},p:function(t){return(t=new vt(t)).get_caught()||(t.set_caught(!0),gt--),t.set_rethrown(!1),mt.push(t),Se(t.excPtr),t.get_exception_ptr()},v:function(){_e(0,0);var t=mt.pop();Ae(t.excPtr),yt=0},a:function(){return _t([])},i:function(t){return _t([t])},x:function(t,e){return _t([t,e])},Ab:function(){var t=mt.pop(),e=(t||J("no exception to throw"),t.excPtr);throw t.get_rethrown()||(mt.push(t),t.set_rethrown(!0),t.set_caught(!1),gt++),yt=e},B:function(t,e,r){throw new vt(t).init(e,r),gt++,yt=t},xc:function(){return gt},e:function(t){throw yt=yt||t},ic:function(t,e){try{return t=Ft.getStr(t),Lt.chmod(t,e),0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},af:function(t,e,r){try{var n,i=Ft.getStreamFromFD(t);return i.fd===e?-28:((n=Lt.getStream(e))&&Lt.close(n),Lt.createStream(i,e).fd)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},qc:function(t,e,r,n){try{var i,s;return e=Ft.getStr(e),e=Ft.calculateAt(t,e),-8&r?-28:(i=Lt.lookupPath(e,{follow:!0}).node)?(s="",4&r&&(s+="r"),2&r&&(s+="w"),1&r&&(s+="x"),s&&Lt.nodePermissions(i,s)?-2:0):-44}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},Rd:function(t,e,r,n,i,s){var o;r=jt(r,n),n=jt(i,s);try{return isNaN(r)?61:(o=Ft.getStreamFromFD(t),Lt.allocate(o,r,n),0)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},jc:function(t,e){try{return Lt.fchmod(t,e),0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},hc:function(t,e,r){try{return Lt.fchown(t,e,r),0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},ua:function(t,e,r){Ft.varargs=r;try{var n=Ft.getStreamFromFD(t);switch(e){case 0:if((i=Ft.get())<0)return-28;for(;Lt.streams[i];)i++;return Lt.createStream(n,i).fd;case 1:case 2:case 6:case 7:return 0;case 3:return n.flags;case 4:var i=Ft.get();return n.flags|=i,0;case 5:return i=Ft.getp(),L[i+0>>1]=2,0;case 16:case 8:default:return-28;case 9:return Nt(28),-1}}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},lc:function(t){try{return Ft.getStreamFromFD(t),0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},je:function(t,e){try{var r=Ft.getStreamFromFD(t);return Ft.doStat(Lt.stat,r.path,e)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},be:function(t,e,r){e=jt(e,r);try{return isNaN(e)?61:(Lt.ftruncate(t,e),0)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},yc:function(t,e){try{var r,n;return 0===e?-28:(r=Lt.cwd(),e<(n=St(r)+1)?-68:(Gt(r,t,e),n))}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},sc:function(t,e,r){try{for(var n=Ft.getStreamFromFD(t),i=(n.getdents||(n.getdents=Lt.readdir(n.path)),0),s=Lt.llseek(n,0,1),o=Math.floor(s/280);o<n.getdents.length&&i+280<=r;){var a,l,c,u=n.getdents[o];l="."===u?(a=n.node.id,4):".."===u?(a=Lt.lookupPath(n.path,{parent:!0}).node.id,4):(a=(c=Lt.lookupNode(n.node,u)).id,Lt.isChrdev(c.mode)?2:Lt.isDir(c.mode)?4:Lt.isLink(c.mode)?10:8),et=[a>>>0,(tt=a,1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)],F[e+i>>2]=et[0],F[e+i+4>>2]=et[1],et=[280*(o+1)>>>0,(tt=280*(o+1),1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)],F[e+i+8>>2]=et[0],F[e+i+12>>2]=et[1],L[e+i+16>>1]=280,I[e+i+18|0]=l,Gt(u,e+i+19,256),i+=280,o+=1}return Lt.llseek(n,280*o,0),i}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},ue:function(t,e,r){Ft.varargs=r;try{var n,i=Ft.getStreamFromFD(t);switch(e){case 21509:case 21510:case 21511:case 21512:case 21524:case 21515:return i.tty?0:-59;case 21505:if(!i.tty)return-59;if(i.tty.ops.ioctl_tcgets){var s=i.tty.ops.ioctl_tcgets(i),o=Ft.getp();F[o>>2]=s.c_iflag||0,F[o+4>>2]=s.c_oflag||0,F[o+8>>2]=s.c_cflag||0,F[o+12>>2]=s.c_lflag||0;for(var a=0;a<32;a++)I[o+a+17|0]=s.c_cc[a]||0}return 0;case 21506:case 21507:case 21508:if(!i.tty)return-59;if(i.tty.ops.ioctl_tcsets){o=Ft.getp();var l=F[o>>2],c=F[o+4>>2],u=F[o+8>>2],h=F[o+12>>2],d=[];for(a=0;a<32;a++)d.push(I[o+a+17|0]);return i.tty.ops.ioctl_tcsets(i.tty,e,{c_iflag:l,c_oflag:c,c_cflag:u,c_lflag:h,c_cc:d})}return 0;case 21519:return i.tty?(o=Ft.getp(),F[o>>2]=0):-59;case 21520:return i.tty?-28:-59;case 21531:return o=Ft.getp(),Lt.ioctl(i,e,o);case 21523:return i.tty?(i.tty.ops.ioctl_tiocgwinsz&&(n=i.tty.ops.ioctl_tiocgwinsz(i.tty),o=Ft.getp(),L[o>>1]=n[0],L[o+2>>1]=n[1]),0):-59;default:return-28}}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},Fd:function(t,e){try{return t=Ft.getStr(t),Ft.doStat(Lt.lstat,t,e)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},uc:function(t,e,r){try{return e=Ft.getStr(e),e=Ft.calculateAt(t,e),"/"===(e=bt.normalize(e))[e.length-1]&&(e=e.substr(0,e.length-1)),Lt.mkdir(e,r,0),0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},Qd:function(t,e,r,n){try{e=Ft.getStr(e);var i=256&n,s=4096&n;return n&=-6401,e=Ft.calculateAt(t,e,s),Ft.doStat(i?Lt.lstat:Lt.stat,e,r)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},Sb:function(t,e,r,n){Ft.varargs=n;try{e=Ft.getStr(e),e=Ft.calculateAt(t,e);var i=n?Ft.get():0;return Lt.open(e,r,i).fd}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},bf:function(t){try{if(0==t)throw new Lt.ErrnoError(21);var e=$t.createPipe();return F[t>>2]=e.readable_fd,F[t+4>>2]=e.writable_fd,0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},gc:function(t,e,r,n){try{var i,s,o;return e=Ft.getStr(e),e=Ft.calculateAt(t,e),n<=0?-28:(i=Lt.readlink(e),s=Math.min(n,St(i)),o=I[r+s],Gt(i,r,n+1),I[r+s]=o,s)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},vc:function(t,e,r,n){try{return e=Ft.getStr(e),n=Ft.getStr(n),e=Ft.calculateAt(t,e),n=Ft.calculateAt(r,n),Lt.rename(e,n),0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},tc:function(t){try{return t=Ft.getStr(t),Lt.rmdir(t),0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},$d:function(t,e){try{return t=Ft.getStr(t),Ft.doStat(Lt.stat,t,e)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},rc:function(t,e,r){try{return t=Ft.getStr(t),F[r+4>>2]=4096,F[r+40>>2]=4096,F[r+8>>2]=1e6,F[r+12>>2]=5e5,F[r+16>>2]=5e5,F[r+20>>2]=Lt.nextInode,F[r+24>>2]=1e6,F[r+28>>2]=42,F[r+44>>2]=2,F[r+36>>2]=255,0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},wc:function(t,e,r){try{return e=Ft.getStr(e),e=Ft.calculateAt(t,e),0===r?Lt.unlink(e):512===r?Lt.rmdir(e):J("Invalid flags passed to unlinkat"),0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},kc:function(t,e,r,n){try{var i,s;return e=Ft.getStr(e),e=Ft.calculateAt(t,e,!0),s=r?(i=1e3*zt(r)+F[r+8>>2]/1e6,1e3*zt(r+=16)+F[r+8>>2]/1e6):i=Date.now(),Lt.utime(e,i,s),0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},Ie:function(){return 1},Le:function(){lt=!1,Qt=0},Ue:function(){throw 1/0},ge:function(t,e,r){t=jt(t,e),e=new Date(1e3*t),F[r>>2]=e.getSeconds(),F[r+4>>2]=e.getMinutes(),F[r+8>>2]=e.getHours(),F[r+12>>2]=e.getDate(),F[r+16>>2]=e.getMonth(),F[r+20>>2]=e.getFullYear()-1900,F[r+24>>2]=e.getDay(),t=0|Ut(e),F[r+28>>2]=t,F[r+36>>2]=-60*e.getTimezoneOffset(),t=new Date(e.getFullYear(),0,1);var n=new Date(e.getFullYear(),6,1).getTimezoneOffset();e=0|(n!=(t=t.getTimezoneOffset())&&e.getTimezoneOffset()==Math.min(t,n)),F[r+32>>2]=e},he:function(t){e=new Date(F[t+20>>2]+1900,F[t+16>>2],F[t+12>>2],F[t+8>>2],F[t+4>>2],F[t>>2],0),r=F[t+32>>2],n=e.getTimezoneOffset(),o=new Date(e.getFullYear(),0,1),i=new Date(e.getFullYear(),6,1).getTimezoneOffset(),o=o.getTimezoneOffset(),s=Math.min(o,i),r<0?F[t+32>>2]=Number(i!=o&&s==n):0<r!=(s==n)&&(o=Math.max(o,i),i=0<r?s:o,e.setTime(e.getTime()+6e4*(i-n))),F[t+24>>2]=e.getDay(),r=0|Ut(e),F[t+28>>2]=r,F[t>>2]=e.getSeconds(),F[t+4>>2]=e.getMinutes(),F[t+8>>2]=e.getHours(),F[t+12>>2]=e.getDate(),F[t+16>>2]=e.getMonth(),F[t+20>>2]=e.getYear(),s=e.getTime();var e,r,n,i,s,o=isNaN(s)?(Nt(61),-1):s/1e3;return be((tt=o,1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)),o>>>0},Od:function(t,e,r,n,i,s,o,a){var l,c,u;i=jt(i,s);try{return isNaN(i)?61:(l=Ft.getStreamFromFD(n),u=(c=Lt.mmap(l,t,i,e,r)).ptr,F[o>>2]=c.allocated,j[a>>2]=u,0)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},Pd:function(t,e,r,n,i,s,o){s=jt(s,o);try{if(isNaN(s))return 61;var a=Ft.getStreamFromFD(i);2&r&&Ft.doMsync(t,a,e,n,s),Lt.munmap(a)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return-t.errno}},ud:function(t,e,r){var n=(new Date).getFullYear(),i=new Date(n,0,1),s=(n=new Date(n,6,1),i.getTimezoneOffset()),o=n.getTimezoneOffset(),a=Math.max(s,o);function l(t){return(t=t.toTimeString().match(/\(([A-Za-z ]+)\)$/))?t[1]:"GMT"}j[t>>2]=60*a,F[e>>2]=Number(s!=o),t=l(i),a=l(n),e=Kt(t),i=Kt(a),o<s?(j[r>>2]=e,j[r+4>>2]=i):(j[r>>2]=i,j[r+4>>2]=e)},_:function(){J("")},$a:function(){return Date.now()},Oe:Xt,ob:function(){return performance.now()},De:function(t,e,r){return k.copyWithin(t,e,e+r)},ff:function(t){var e=k.length,r=(t>>>=0,2147483648);if(!(r<t))for(var n=1;n<=4;n*=2){var i=e*(1+.2/n);if(i=Math.min(i,t+100663296),function(t){t=(t-D.buffer.byteLength+65535)/65536;try{return D.grow(t),V(),1}catch(t){}}(Math.min(r,(i=Math.max(t,i))+(65536-i%65536)%65536)))return!0}return!1},nc:function(t,e){var r=0;return Ht().forEach((function(n,i){for(var s=e+r,o=(j[t+4*i>>2]=s,n),a=s,l=0;l<o.length;++l)I[0|a++]=o.charCodeAt(l);I[0|a]=0,r+=n.length+1})),0},oc:function(t,e){var r=Ht(),n=(j[t>>2]=r.length,0);return r.forEach((function(t){return n+=t.length+1})),j[e>>2]=n,0},wa:function(t,e){Yt(t)},Sa:function(t){try{var e=Ft.getStreamFromFD(t);return Lt.close(e),0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return t.errno}},Yb:function(t,e){try{var r=Ft.getStreamFromFD(t),n=r.tty?2:Lt.isDir(r.mode)?3:Lt.isLink(r.mode)?7:4;return I[0|e]=n,L[e+2>>1]=0,et=[0,(tt=0,1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)],F[e+8>>2]=et[0],F[e+12>>2]=et[1],et=[0,(tt=0,1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)],F[e+16>>2]=et[0],F[e+20>>2]=et[1],0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return t.errno}},ae:function(t,e,r,n,i,s){var o;n=jt(n,i);try{return isNaN(n)?61:(o=ee(Ft.getStreamFromFD(t),e,r,n),j[s>>2]=o,0)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return t.errno}},Gb:function(t,e,r,n){try{var i=ee(Ft.getStreamFromFD(t),e,r);return j[n>>2]=i,0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return t.errno}},ie:function(t,e,r,n,i){var s;e=jt(e,r);try{return isNaN(e)?61:(s=Ft.getStreamFromFD(t),Lt.llseek(s,e,n),et=[s.position>>>0,(tt=s.position,1<=+Math.abs(tt)?0<tt?+Math.floor(tt/4294967296)>>>0:~~+Math.ceil((tt-(~~tt>>>0))/4294967296)>>>0:0)],F[i>>2]=et[0],F[i+4>>2]=et[1],s.getdents&&0===e&&0===n&&(s.getdents=null),0)}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return t.errno}},sb:function(t,e,r,n){try{var i=function(t,e,r,n){for(var i=0,s=0;s<r;s++){var o=j[e>>2],a=j[e+4>>2];if(e+=8,(o=Lt.write(t,I,o,a,n))<0)return-1;i+=o,void 0!==n&&(n+=o)}return i}(Ft.getStreamFromFD(t),e,r);return j[n>>2]=i,0}catch(t){if(void 0===Lt||"ErrnoError"!==t.name)throw t;return t.errno}},df:function(t,e){return wt(k.subarray(t,t+e)),0},ac:function(t,e){var r=we();try{return ht(t)(e)}catch(t){if(xe(r),t!==t+0)throw t;_e(1,0)}},cb:function(t,e,r){var n=we();try{return ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},rb:function(t,e,r){var n=we();try{return ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},We:function(t,e,r,n){var i=we();try{return ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},m:function(t,e){var r=we();try{return ht(t)(e)}catch(t){if(xe(r),t!==t+0)throw t;_e(1,0)}},X:function(t,e,r){var n=we();try{return ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},u:function(t,e,r){var n=we();try{return ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},Aa:function(t,e,r,n){var i=we();try{return ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},A:function(t,e,r,n,i){var s=we();try{return ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},D:function(t,e,r,n){var i=we();try{return ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},Ja:function(t,e,r,n,i){var s=we();try{return ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},qa:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Zb:function(t,e,r,n,i,s,o,a,l){var c=we();try{return ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},Hb:function(t,e,r){var n=we();try{return ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},Ua:function(t,e,r,n){var i=we();try{return ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},ma:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},t:function(t){var e=we();try{return ht(t)()}catch(t){if(xe(e),t!==t+0)throw t;_e(1,0)}},ia:function(t,e){var r=we();try{return ht(t)(e)}catch(t){if(xe(r),t!==t+0)throw t;_e(1,0)}},xe:function(t,e,r){var n=we();try{return ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},Ha:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Ma:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Ve:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_,b,w,x,E,S){var A=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_,b,w,x,E,S)}catch(t){if(xe(A),t!==t+0)throw t;_e(1,0)}},ha:function(t,e,r,n,i){var s=we();try{return ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},L:function(t,e,r){var n=we();try{return ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},T:function(t,e,r,n){var i=we();try{return ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},b:function(t,e){var r=we();try{return ht(t)(e)}catch(t){if(xe(r),t!==t+0)throw t;_e(1,0)}},z:function(t,e,r){var n=we();try{return ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},Q:function(t,e,r,n){var i=we();try{return ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},S:function(t,e,r,n,i){var s=we();try{return ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},O:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Z:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},ca:function(t,e,r,n,i,s,o,a){var l=we();try{return ht(t)(e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},ra:function(t,e,r,n,i,s,o,a,l){var c=we();try{return ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},Ya:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Ge:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p){var m=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p)}catch(t){if(xe(m),t!==t+0)throw t;_e(1,0)}},tb:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Te:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Me:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_,b){var w=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_,b)}catch(t){if(xe(w),t!==t+0)throw t;_e(1,0)}},$b:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},_a:function(t,e,r,n,i){var s=we();try{return ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},Da:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},ya:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Wb:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},w:function(t,e,r,n){var i=we();try{return ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},Ee:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},c:function(t,e,r){var n=we();try{return ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},E:function(t,e,r,n){var i=we();try{return ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},Vb:function(t,e,r,n,i){var s=we();try{return ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},fa:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Ea:function(t,e,r,n,i,s,o,a,l){var c=we();try{return ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},La:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},jb:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},Ze:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p){var m=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p)}catch(t){if(xe(m),t!==t+0)throw t;_e(1,0)}},Xb:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},hb:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y){var v=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y)}catch(t){if(xe(v),t!==t+0)throw t;_e(1,0)}},Ob:function(t,e,r,n,i,s,o,a,l){var c=we();try{return ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},Rb:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},ub:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},md:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return dr(t,e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Xe:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Tb:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Ce:function(t,e,r,n,i,s,o,a){var l=we();try{return ht(t)(e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},pa:function(t,e,r,n,i){var s=we();try{return ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},Qa:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},V:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},ab:function(t,e,r,n,i,s,o,a,l){var c=we();try{return ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},Pb:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},_b:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},d:function(t,e,r,n){var i=we();try{return ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},Y:function(t,e,r,n,i){var s=we();try{return ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},re:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},mb:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Za:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m){var g=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m)}catch(t){if(xe(g),t!==t+0)throw t;_e(1,0)}},Ia:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f){var p=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f)}catch(t){if(xe(p),t!==t+0)throw t;_e(1,0)}},Mb:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p){var m=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p)}catch(t){if(xe(m),t!==t+0)throw t;_e(1,0)}},Nb:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Ne:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Fa:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},pb:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},k:function(t,e,r,n,i){var s=we();try{return ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},Ba:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Se:function(t,e,r,n,i,s,o,a){var l=we();try{return ht(t)(e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},Ib:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},pe:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Lb:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},aa:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},ef:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Ub:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},n:function(t,e,r,n,i,s){var o=we();try{return ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Wa:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Fb:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Ae:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y){var v=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y)}catch(t){if(xe(v),t!==t+0)throw t;_e(1,0)}},Be:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m){var g=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m)}catch(t){if(xe(g),t!==t+0)throw t;_e(1,0)}},_e:function(t,e,r,n,i,s,o,a,l){var c=we();try{return ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},se:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Ka:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Pa:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},s:function(t,e,r,n,i,s,o){var a=we();try{return ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Fe:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},ze:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},le:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f){var p=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f)}catch(t){if(xe(p),t!==t+0)throw t;_e(1,0)}},Re:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g){var y=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g)}catch(t){if(xe(y),t!==t+0)throw t;_e(1,0)}},te:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},ve:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},F:function(t,e,r,n,i,s,o,a){var l=we();try{return ht(t)(e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},oe:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Va:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},Cb:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g){var y=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g)}catch(t){if(xe(y),t!==t+0)throw t;_e(1,0)}},we:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},H:function(t,e,r,n,i,s,o,a,l){var c=we();try{return ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},Pe:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p){var m=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p)}catch(t){if(xe(m),t!==t+0)throw t;_e(1,0)}},Je:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Kb:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},M:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},ba:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},za:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f){var p=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f)}catch(t){if(xe(p),t!==t+0)throw t;_e(1,0)}},ea:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},va:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},la:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},ke:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f){var p=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f)}catch(t){if(xe(p),t!==t+0)throw t;_e(1,0)}},Ca:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f){var p=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f)}catch(t){if(xe(p),t!==t+0)throw t;_e(1,0)}},gb:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p){var m=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p)}catch(t){if(xe(m),t!==t+0)throw t;_e(1,0)}},Oa:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m){var g=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m)}catch(t){if(xe(g),t!==t+0)throw t;_e(1,0)}},pc:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v){var _=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v)}catch(t){if(xe(_),t!==t+0)throw t;_e(1,0)}},qe:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_){var b=we();try{return ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_)}catch(t){if(xe(b),t!==t+0)throw t;_e(1,0)}},zc:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y){var v=we();try{return tn(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y)}catch(t){if(xe(v),t!==t+0)throw t;_e(1,0)}},hd:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v){var _=we();try{return _r(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v)}catch(t){if(xe(_),t!==t+0)throw t;_e(1,0)}},yd:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_){var b=we();try{return or(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_)}catch(t){if(xe(b),t!==t+0)throw t;_e(1,0)}},zd:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m){var g=we();try{return ar(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m)}catch(t){if(xe(g),t!==t+0)throw t;_e(1,0)}},Fc:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g){var y=we();try{return Xr(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g)}catch(t){if(xe(y),t!==t+0)throw t;_e(1,0)}},Oc:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return Ur(t,e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Xc:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{return Ir(t,e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},Yc:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p){var m=we();try{return Dr(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p)}catch(t){if(xe(m),t!==t+0)throw t;_e(1,0)}},Qc:function(t,e,r,n,i,s,o,a,l){var c=we();try{return $r(t,e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},wd:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return mr(t,e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Uc:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return Fr(t,e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},sd:function(t,e,r,n,i,s,o,a){var l=we();try{return Ke(t,e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},vd:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return fr(t,e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Gc:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return Be(t,e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Cd:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return yr(t,e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Sd:function(t,e,r,n,i,s,o){var a=we();try{return Ue(t,e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Kd:function(t,e,r,n,i,s,o,a){var l=we();try{return er(t,e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},Nc:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return Br(t,e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Bd:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return lr(t,e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Rc:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return jr(t,e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Vc:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return Lr(t,e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},qd:function(t,e,r,n,i,s){var o=we();try{return ke(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},ld:function(t,e,r,n,i,s,o){var a=we();try{return He(t,e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},gd:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return br(t,e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},td:function(t,e,r,n,i,s,o,a,l){var c=we();try{return Ze(t,e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},Xd:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return $e(t,e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Yd:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return je(t,e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Wd:function(t,e,r,n,i){var s=we();try{return Ne(t,e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},rd:function(t,e,r,n,i,s){var o=we();try{return Le(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Dc:function(t,e,r,n,i,s,o){var a=we();try{return Zr(t,e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},pd:function(t,e,r,n,i,s,o,a){var l=we();try{return ur(t,e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},ad:function(t,e,r,n,i,s,o,a,l){var c=we();try{return Tr(t,e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},Hd:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{return Mr(t,e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Jd:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return nr(t,e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Ad:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{return cr(t,e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},_c:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return Cr(t,e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},cd:function(t,e,r,n,i,s,o){var a=we();try{return Ar(t,e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Wc:function(t,e,r,n,i,s,o,a,l){var c=we();try{return kr(t,e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},id:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return vr(t,e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Zd:function(t,e,r,n){var i=we();try{return De(t,e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},Pc:function(t,e,r,n,i,s,o,a){var l=we();try{return zr(t,e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},_d:function(t,e,r,n,i){var s=we();try{return Oe(t,e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},nd:function(t,e,r,n,i,s){var o=we();try{return qe(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Vd:function(t,e,r,n,i,s,o,a){var l=we();try{return Ge(t,e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},Bb:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return wr(t,e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Ac:function(t,e,r,n,i,s){var o=we();try{return Ie(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Jc:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{return Wr(t,e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Dd:function(t,e,r){var n=we();try{return Ye(t,e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},Ud:function(t,e,r,n){var i=we();try{return Fe(t,e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},Td:function(t){var e=we();try{return ze(t)}catch(t){if(xe(e),t!==t+0)throw t;_e(1,0)}},de:function(t,e){var r=we();try{return Re(t,e)}catch(t){if(xe(r),t!==t+0)throw t;_e(1,0)}},ce:function(t,e,r){var n=we();try{return Me(t,e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},Md:function(t,e,r,n){var i=we();try{return Qe(t,e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},Kc:function(t,e,r,n,i){var s=we();try{return Yr(t,e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},fe:function(t,e,r,n,i){var s=we();try{return Ce(t,e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},od:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_,b,w,x,E,S,A){var P=we();try{return hr(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_,b,w,x,E,S,A)}catch(t){if(xe(P),t!==t+0)throw t;_e(1,0)}},bd:function(t,e,r,n,i,s){var o=we();try{return Or(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},$c:function(t,e,r,n,i,s,o,a){var l=we();try{return Rr(t,e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},Ic:function(t,e,r,n){var i=we();try{return ir(t,e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},Mc:function(t,e,r,n,i,s){var o=we();try{return Kr(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Cc:function(t,e,r,n){var i=we();try{return Jr(t,e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},l:function(t){var e=we();try{ht(t)()}catch(t){if(xe(e),t!==t+0)throw t;_e(1,0)}},ja:function(t,e){var r=we();try{ht(t)(e)}catch(t){if(xe(r),t!==t+0)throw t;_e(1,0)}},ne:function(t,e,r,n,i,s,o){var a=we();try{ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Db:function(t,e,r,n,i){var s=we();try{ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},g:function(t,e){var r=we();try{ht(t)(e)}catch(t){if(xe(r),t!==t+0)throw t;_e(1,0)}},R:function(t,e,r){var n=we();try{ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},I:function(t,e,r,n){var i=we();try{ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},W:function(t,e,r,n,i){var s=we();try{ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},da:function(t,e,r,n,i,s){var o=we();try{ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},vb:function(t,e,r,n,i,s,o){var a=we();try{ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},ye:function(t,e,r,n,i,s,o,a){var l=we();try{ht(t)(e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},fb:function(t,e,r,n,i,s,o,a,l){var c=we();try{ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},kb:function(t,e,r,n,i,s){var o=we();try{ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},sa:function(t,e,r,n,i){var s=we();try{ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},N:function(t,e,r,n){var i=we();try{ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},lb:function(t,e,r,n,i){var s=we();try{ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},$:function(t,e,r,n,i,s){var o=we();try{ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Eb:function(t,e,r,n,i,s,o){var a=we();try{ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},h:function(t,e,r){var n=we();try{ht(t)(e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},C:function(t,e,r,n){var i=we();try{ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},J:function(t,e,r,n,i){var s=we();try{ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},ga:function(t,e,r,n,i,s){var o=we();try{ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Ta:function(t,e,r,n,i,s,o){var a=we();try{ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Xa:function(t,e,r,n,i,s,o,a,l){var c=we();try{ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},Ye:function(t,e,r,n,i,s,o){var a=we();try{ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},nb:function(t,e,r,n,i,s){var o=we();try{ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},bc:function(t,e,r,n,i){var s=we();try{ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},K:function(t,e,r,n,i,s){var o=we();try{ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},eb:function(t,e,r,n,i,s,o){var a=we();try{ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},f:function(t,e,r,n){var i=we();try{ht(t)(e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},ka:function(t,e,r,n,i){var s=we();try{ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},bb:function(t,e,r,n,i,s,o){var a=we();try{ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},cf:function(t,e,r,n,i,s){var o=we();try{ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},j:function(t,e,r,n,i){var s=we();try{ht(t)(e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},Ra:function(t,e,r,n,i,s){var o=we();try{ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},xa:function(t,e,r,n,i,s,o,a){var l=we();try{ht(t)(e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},db:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},ec:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},ib:function(t,e,r,n,i,s,o,a,l){var c=we();try{ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},wb:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},ta:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},Na:function(t,e,r,n,i,s,o){var a=we();try{ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Qb:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},o:function(t,e,r,n,i,s){var o=we();try{ht(t)(e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},fc:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_,b,w){var x=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_,b,w)}catch(t){if(xe(x),t!==t+0)throw t;_e(1,0)}},zb:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f){var p=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f)}catch(t){if(xe(p),t!==t+0)throw t;_e(1,0)}},yb:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},Jb:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p){var m=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p)}catch(t){if(xe(m),t!==t+0)throw t;_e(1,0)}},q:function(t,e,r,n,i,s,o){var a=we();try{ht(t)(e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},G:function(t,e,r,n,i,s,o,a){var l=we();try{ht(t)(e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},me:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},U:function(t,e,r,n,i,s,o,a,l){var c=we();try{ht(t)(e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},He:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Qe:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p){var m=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p)}catch(t){if(xe(m),t!==t+0)throw t;_e(1,0)}},P:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{ht(t)(e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},na:function(t,e,r,n,i,s,o,a,l,c,u){var h=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u)}catch(t){if(xe(h),t!==t+0)throw t;_e(1,0)}},qb:function(t,e,r,n,i,s,o,a,l,c,u,h){var d=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h)}catch(t){if(xe(d),t!==t+0)throw t;_e(1,0)}},dc:function(t,e,r,n,i,s,o,a,l,c,u,h,d){var f=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h,d)}catch(t){if(xe(f),t!==t+0)throw t;_e(1,0)}},xb:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p){var m=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p)}catch(t){if(xe(m),t!==t+0)throw t;_e(1,0)}},Ga:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m){var g=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m)}catch(t){if(xe(g),t!==t+0)throw t;_e(1,0)}},cc:function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y){var v=we();try{ht(t)(e,r,n,i,s,o,a,l,c,u,h,d,f,p,m,g,y)}catch(t){if(xe(v),t!==t+0)throw t;_e(1,0)}},xd:function(t,e,r,n,i,s,o,a,l){var c=we();try{pr(t,e,r,n,i,s,o,a,l)}catch(t){if(xe(c),t!==t+0)throw t;_e(1,0)}},Ld:function(t,e,r,n,i,s,o){var a=we();try{tr(t,e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},Bc:function(t,e,r,n,i,s){var o=we();try{Qr(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Id:function(t,e,r,n,i,s,o){var a=we();try{rr(t,e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},dd:function(t,e,r,n,i,s,o,a){var l=we();try{Pr(t,e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},Gd:function(t,e,r,n,i){var s=we();try{Je(t,e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},Ec:function(t,e,r,n,i,s){var o=we();try{Xe(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},ee:function(t,e,r,n,i,s,o){var a=we();try{xr(t,e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},jd:function(t,e,r,n,i,s,o,a){var l=we();try{qr(t,e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},Zc:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{Sr(t,e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Nd:function(t,e,r,n){var i=we();try{We(t,e,r,n)}catch(t){if(xe(i),t!==t+0)throw t;_e(1,0)}},Hc:function(t,e,r,n,i){var s=we();try{Vr(t,e,r,n,i)}catch(t){if(xe(s),t!==t+0)throw t;_e(1,0)}},Sc:function(t,e,r,n,i,s){var o=we();try{Gr(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},fd:function(t,e,r,n,i,s){var o=we();try{Ve(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},Lc:function(t,e,r,n,i,s,o,a,l,c){var u=we();try{Hr(t,e,r,n,i,s,o,a,l,c)}catch(t){if(xe(u),t!==t+0)throw t;_e(1,0)}},Tc:function(t,e,r,n,i,s,o){var a=we();try{Nr(t,e,r,n,i,s,o)}catch(t){if(xe(a),t!==t+0)throw t;_e(1,0)}},kd:function(t,e,r,n,i,s){var o=we();try{gr(t,e,r,n,i,s)}catch(t){if(xe(o),t!==t+0)throw t;_e(1,0)}},ed:function(t,e,r,n,i,s,o,a){var l=we();try{Er(t,e,r,n,i,s,o,a)}catch(t){if(xe(l),t!==t+0)throw t;_e(1,0)}},Ed:function(t,e,r){var n=we();try{sr(t,e,r)}catch(t){if(xe(n),t!==t+0)throw t;_e(1,0)}},r:function(t){return t},$e:Yt,oa:ne,mc:function(t,e,r,n,i){return ne(t,e,r,n)}}),me=function(){var t,r,n,i={a:pe};function s(t,e){return me=t.exports,D=me.gf,V(),dt=me.hh,t=me.hf,K.unshift(t),Z(),me}if(X(),m.instantiateWasm)try{return m.instantiateWasm(i,s)}catch(i){z("Module.instantiateWasm callback failed with error: ".concat(i)),e(i)}return t=Q,r=i,n=function(t){s(t.instance)},(R||"function"!=typeof WebAssembly.instantiateStreaming||rt(t)||nt(t)||M||"function"!=typeof fetch?st(t,r,n):fetch(t,{credentials:"same-origin"}).then((function(e){return WebAssembly.instantiateStreaming(e,r).then(n,(function(e){return z("wasm streaming compile failed: ".concat(e)),z("falling back to ArrayBuffer instantiation"),st(t,r,n)}))}))).catch(e),{}}(),ge=(m._CPLSetConfigOption=function(t,e){return(m._CPLSetConfigOption=me.jf)(t,e)},m._CPLSetThreadLocalConfigOption=function(t,e){return(m._CPLSetThreadLocalConfigOption=me.kf)(t,e)},m._CPLError=function(t,e,r,n){return(m._CPLError=me.lf)(t,e,r,n)},m._CPLErrorReset=function(){return(m._CPLErrorReset=me.mf)()},m._CPLGetLastErrorNo=function(){return(m._CPLGetLastErrorNo=me.nf)()},m._CPLGetLastErrorType=function(){return(m._CPLGetLastErrorType=me.of)()},m._CPLGetLastErrorMsg=function(){return(m._CPLGetLastErrorMsg=me.pf)()},m._CPLQuietErrorHandler=function(t,e,r){return(m._CPLQuietErrorHandler=me.qf)(t,e,r)},m._CPLSetErrorHandler=function(t){return(m._CPLSetErrorHandler=me.rf)(t)},m._CSLCount=function(t){return(m._CSLCount=me.sf)(t)},m._CPLAtof=function(t){return(m._CPLAtof=me.tf)(t)},m._GDALSuggestedWarpOutput=function(t,e,r,n,i,s){return(m._GDALSuggestedWarpOutput=me.uf)(t,e,r,n,i,s)},m._GDALGenImgProjTransform=function(t,e,r,n,i,s,o){return(m._GDALGenImgProjTransform=me.vf)(t,e,r,n,i,s,o)},m._GDALCreateGenImgProjTransformer=function(t,e,r,n,i,s,o){return(m._GDALCreateGenImgProjTransformer=me.wf)(t,e,r,n,i,s,o)},m._GDALCreateGenImgProjTransformer2=function(t,e,r){return(m._GDALCreateGenImgProjTransformer2=me.xf)(t,e,r)},m._GDALDestroyGenImgProjTransformer=function(t){return(m._GDALDestroyGenImgProjTransformer=me.yf)(t)},m._GDALInvGeoTransform=function(t,e){return(m._GDALInvGeoTransform=me.zf)(t,e)},m._GDALReprojectImage=function(t,e,r,n,i,s,o,a,l,c){return(m._GDALReprojectImage=me.Af)(t,e,r,n,i,s,o,a,l,c)},m._OSRNewSpatialReference=function(t){return(m._OSRNewSpatialReference=me.Bf)(t)},m._OSRDestroySpatialReference=function(t){return(m._OSRDestroySpatialReference=me.Cf)(t)},m._OSRExportToWkt=function(t,e){return(m._OSRExportToWkt=me.Df)(t,e)},m._OSRSetFromUserInput=function(t,e){return(m._OSRSetFromUserInput=me.Ef)(t,e)},m._OSRImportFromEPSG=function(t,e){return(m._OSRImportFromEPSG=me.Ff)(t,e)},m._OSRSetAxisMappingStrategy=function(t,e){return(m._OSRSetAxisMappingStrategy=me.Gf)(t,e)},m._OCTDestroyCoordinateTransformation=function(t){return(m._OCTDestroyCoordinateTransformation=me.Hf)(t)},m._OCTNewCoordinateTransformation=function(t,e){return(m._OCTNewCoordinateTransformation=me.If)(t,e)},m._OCTTransform=function(t,e,r,n,i){return(m._OCTTransform=me.Jf)(t,e,r,n,i)},m._GDALAllRegister=function(){return(m._GDALAllRegister=me.Kf)()},m._OGRGetDriverCount=function(){return(m._OGRGetDriverCount=me.Lf)()},m._OGRGetDriver=function(t){return(m._OGRGetDriver=me.Mf)(t)},m._OGR_L_GetFeatureCount=function(t,e){return(m._OGR_L_GetFeatureCount=me.Nf)(t,e)},m._OGR_L_GetName=function(t){return(m._OGR_L_GetName=me.Of)(t)},m._OGR_DS_GetLayerCount=function(t){return(m._OGR_DS_GetLayerCount=me.Pf)(t)},m._OGR_DS_GetLayer=function(t,e){return(m._OGR_DS_GetLayer=me.Qf)(t,e)},m._OGR_DS_GetName=function(t){return(m._OGR_DS_GetName=me.Rf)(t)},m._OGR_DS_GetDriver=function(t){return(m._OGR_DS_GetDriver=me.Sf)(t)},m._OGR_Dr_GetName=function(t){return(m._OGR_Dr_GetName=me.Tf)(t)},m._GDALCreate=function(t,e,r,n,i,s,o){return(m._GDALCreate=me.Uf)(t,e,r,n,i,s,o)},m._GDALCreateCopy=function(t,e,r,n,i,s,o){return(m._GDALCreateCopy=me.Vf)(t,e,r,n,i,s,o)},m._GDALGetDriverShortName=function(t){return(m._GDALGetDriverShortName=me.Wf)(t)},m._GDALGetDriverLongName=function(t){return(m._GDALGetDriverLongName=me.Xf)(t)},m._GDALGetDriverCount=function(){return(m._GDALGetDriverCount=me.Yf)()},m._GDALGetDriver=function(t){return(m._GDALGetDriver=me.Zf)(t)},m._GDALGetDriverByName=function(t){return(m._GDALGetDriverByName=me._f)(t)},m._GDALGetRasterXSize=function(t){return(m._GDALGetRasterXSize=me.$f)(t)},m._GDALGetRasterYSize=function(t){return(m._GDALGetRasterYSize=me.ag)(t)},m._GDALGetRasterBand=function(t,e){return(m._GDALGetRasterBand=me.bg)(t,e)},m._GDALGetRasterCount=function(t){return(m._GDALGetRasterCount=me.cg)(t)},m._GDALGetSpatialRef=function(t){return(m._GDALGetSpatialRef=me.dg)(t)},m._GDALGetProjectionRef=function(t){return(m._GDALGetProjectionRef=me.eg)(t)},m._GDALSetProjection=function(t,e){return(m._GDALSetProjection=me.fg)(t,e)},m._GDALGetGeoTransform=function(t,e){return(m._GDALGetGeoTransform=me.gg)(t,e)},m._GDALSetGeoTransform=function(t,e){return(m._GDALSetGeoTransform=me.hg)(t,e)},m._GDALGetDatasetDriver=function(t){return(m._GDALGetDatasetDriver=me.ig)(t)},m._GDALGetFileList=function(t){return(m._GDALGetFileList=me.jg)(t)},m._GDALOpen=function(t,e){return(m._GDALOpen=me.kg)(t,e)},m._GDALOpenEx=function(t,e,r,n,i){return(m._GDALOpenEx=me.lg)(t,e,r,n,i)},m._GDALClose=function(t){return(m._GDALClose=me.mg)(t)},m._GDALDatasetGetLayerCount=function(t){return(m._GDALDatasetGetLayerCount=me.ng)(t)},m._GDALDatasetGetLayer=function(t,e){return(m._GDALDatasetGetLayer=me.og)(t,e)},m._GDALGetRasterDataType=function(t){return(m._GDALGetRasterDataType=me.pg)(t)},m._GDALGetRasterNoDataValue=function(t,e){return(m._GDALGetRasterNoDataValue=me.qg)(t,e)},m._GDALGetRasterMaximum=function(t,e){return(m._GDALGetRasterMaximum=me.rg)(t,e)},m._GDALGetRasterMinimum=function(t,e){return(m._GDALGetRasterMinimum=me.sg)(t,e)},m._GDALGetRasterStatistics=function(t,e,r,n,i,s,o){return(m._GDALGetRasterStatistics=me.tg)(t,e,r,n,i,s,o)},m._GDALSetCacheMax=function(t){return(m._GDALSetCacheMax=me.ug)(t)},m._GDALGetDescription=function(t){return(m._GDALGetDescription=me.vg)(t)},m._GDALGetMetadataItem=function(t,e,r){return(m._GDALGetMetadataItem=me.wg)(t,e,r)},m._GDALInfo=function(t,e){return(m._GDALInfo=me.xg)(t,e)},m._GDALInfoOptionsNew=function(t,e){return(m._GDALInfoOptionsNew=me.yg)(t,e)},m._GDALInfoOptionsFree=function(t){return(m._GDALInfoOptionsFree=me.zg)(t)},m._GDALBuildVRT=function(t,e,r,n,i,s){return(m._GDALBuildVRT=me.Ag)(t,e,r,n,i,s)},m._GDALBuildVRTOptionsFree=function(t){return(m._GDALBuildVRTOptionsFree=me.Bg)(t)},m._GDALBuildVRTOptionsNew=function(t,e){return(m._GDALBuildVRTOptionsNew=me.Cg)(t,e)},m._GDALTranslate=function(t,e,r,n){return(m._GDALTranslate=me.Dg)(t,e,r,n)},m._GDALTranslateOptionsNew=function(t,e){return(m._GDALTranslateOptionsNew=me.Eg)(t,e)},m._GDALTranslateOptionsFree=function(t){return(m._GDALTranslateOptionsFree=me.Fg)(t)},m._GDALRasterize=function(t,e,r,n,i){return(m._GDALRasterize=me.Gg)(t,e,r,n,i)},m._GDALRasterizeOptionsNew=function(t,e){return(m._GDALRasterizeOptionsNew=me.Hg)(t,e)},m._GDALRasterizeOptionsFree=function(t){return(m._GDALRasterizeOptionsFree=me.Ig)(t)},m._GDALWarp=function(t,e,r,n,i,s){return(m._GDALWarp=me.Jg)(t,e,r,n,i,s)},m._GDALWarpAppOptionsNew=function(t,e){return(m._GDALWarpAppOptionsNew=me.Kg)(t,e)},m._GDALWarpAppOptionsFree=function(t){return(m._GDALWarpAppOptionsFree=me.Lg)(t)},m._GDALWarpAppOptionsSetProgress=function(t,e,r){return(m._GDALWarpAppOptionsSetProgress=me.Mg)(t,e,r)},m._GDALVectorInfoOptionsFree=function(t){return(m._GDALVectorInfoOptionsFree=me.Ng)(t)},m._GDALVectorInfo=function(t,e){return(m._GDALVectorInfo=me.Og)(t,e)},m._GDALVectorInfoOptionsNew=function(t,e){return(m._GDALVectorInfoOptionsNew=me.Pg)(t,e)},m._GDALVectorTranslate=function(t,e,r,n,i,s){return(m._GDALVectorTranslate=me.Qg)(t,e,r,n,i,s)},m._GDALVectorTranslateOptionsNew=function(t,e){return(m._GDALVectorTranslateOptionsNew=me.Rg)(t,e)},m._GDALVectorTranslateOptionsFree=function(t){return(m._GDALVectorTranslateOptionsFree=me.Sg)(t)},m._GDALDEMProcessing=function(t,e,r,n,i,s){return(m._GDALDEMProcessing=me.Tg)(t,e,r,n,i,s)},m._GDALDEMProcessingOptionsNew=function(t,e){return(m._GDALDEMProcessingOptionsNew=me.Ug)(t,e)},m._GDALDEMProcessingOptionsFree=function(t){return(m._GDALDEMProcessingOptionsFree=me.Vg)(t)},function(){return(ge=me.Wg)()}),ye=m._malloc=function(t){return(ye=m._malloc=me.Xg)(t)},ve=(m._free=function(t){return(m._free=me.Yg)(t)},function(t,e){return(ve=me.Zg)(t,e)}),_e=function(t,e){return(_e=me._g)(t,e)},be=function(t){return(be=me.$g)(t)},we=function(){return(we=me.ah)()},xe=function(t){return(xe=me.bh)(t)},Ee=function(t){return(Ee=me.ch)(t)},Se=function(t){return(Se=me.dh)(t)},Ae=function(t){return(Ae=me.eh)(t)},Pe=function(t,e,r){return(Pe=me.fh)(t,e,r)},Te=function(t){return(Te=me.gh)(t)},Ce=m.dynCall_jiiii=function(t,e,r,n,i){return(Ce=m.dynCall_jiiii=me.ih)(t,e,r,n,i)},Me=m.dynCall_jii=function(t,e,r){return(Me=m.dynCall_jii=me.jh)(t,e,r)},Oe=m.dynCall_iiji=function(t,e,r,n,i){return(Oe=m.dynCall_iiji=me.kh)(t,e,r,n,i)},Re=m.dynCall_ji=function(t,e){return(Re=m.dynCall_ji=me.lh)(t,e)},De=m.dynCall_iij=function(t,e,r,n){return(De=m.dynCall_iij=me.mh)(t,e,r,n)},Ie=m.dynCall_iijj=function(t,e,r,n,i,s){return(Ie=m.dynCall_iijj=me.nh)(t,e,r,n,i,s)},ke=m.dynCall_iiiij=function(t,e,r,n,i,s){return(ke=m.dynCall_iiiij=me.oh)(t,e,r,n,i,s)},Le=m.dynCall_iiiji=function(t,e,r,n,i,s){return(Le=m.dynCall_iiiji=me.ph)(t,e,r,n,i,s)},Fe=m.dynCall_iji=function(t,e,r,n){return(Fe=m.dynCall_iji=me.qh)(t,e,r,n)},je=m.dynCall_iiiijjjii=function(t,e,r,n,i,s,o,a,l,c,u,h){return(je=m.dynCall_iiiijjjii=me.rh)(t,e,r,n,i,s,o,a,l,c,u,h)},Ne=m.dynCall_iiij=function(t,e,r,n,i){return(Ne=m.dynCall_iiij=me.sh)(t,e,r,n,i)},Ge=m.dynCall_iijiiii=function(t,e,r,n,i,s,o,a){return(Ge=m.dynCall_iijiiii=me.th)(t,e,r,n,i,s,o,a)},$e=m.dynCall_iiiijjji=function(t,e,r,n,i,s,o,a,l,c,u){return($e=m.dynCall_iiiijjji=me.uh)(t,e,r,n,i,s,o,a,l,c,u)},ze=m.dynCall_j=function(t){return(ze=m.dynCall_j=me.vh)(t)},Ue=m.dynCall_iiiiij=function(t,e,r,n,i,s,o){return(Ue=m.dynCall_iiiiij=me.wh)(t,e,r,n,i,s,o)},Be=m.dynCall_iiiiiijj=function(t,e,r,n,i,s,o,a,l,c){return(Be=m.dynCall_iiiiiijj=me.xh)(t,e,r,n,i,s,o,a,l,c)},Ve=m.dynCall_vijii=function(t,e,r,n,i,s){return(Ve=m.dynCall_vijii=me.yh)(t,e,r,n,i,s)},qe=m.dynCall_iijii=function(t,e,r,n,i,s){return(qe=m.dynCall_iijii=me.zh)(t,e,r,n,i,s)},Ke=m.dynCall_iiiiiij=function(t,e,r,n,i,s,o,a){return(Ke=m.dynCall_iiiiiij=me.Ah)(t,e,r,n,i,s,o,a)},We=m.dynCall_vij=function(t,e,r,n){return(We=m.dynCall_vij=me.Bh)(t,e,r,n)},He=m.dynCall_iiiiji=function(t,e,r,n,i,s,o){return(He=m.dynCall_iiiiji=me.Ch)(t,e,r,n,i,s,o)},Ye=m.dynCall_ij=function(t,e,r){return(Ye=m.dynCall_ij=me.Dh)(t,e,r)},Xe=m.dynCall_viiji=function(t,e,r,n,i,s){return(Xe=m.dynCall_viiji=me.Eh)(t,e,r,n,i,s)},Ze=m.dynCall_iiiijji=function(t,e,r,n,i,s,o,a,l){return(Ze=m.dynCall_iiiijji=me.Fh)(t,e,r,n,i,s,o,a,l)},Je=m.dynCall_viij=function(t,e,r,n,i){return(Je=m.dynCall_viij=me.Gh)(t,e,r,n,i)},Qe=m.dynCall_jiii=function(t,e,r,n){return(Qe=m.dynCall_jiii=me.Hh)(t,e,r,n)},tr=m.dynCall_viiiij=function(t,e,r,n,i,s,o){return(tr=m.dynCall_viiiij=me.Ih)(t,e,r,n,i,s,o)},er=m.dynCall_iiiiiji=function(t,e,r,n,i,s,o,a){return(er=m.dynCall_iiiiiji=me.Jh)(t,e,r,n,i,s,o,a)},rr=m.dynCall_viiiji=function(t,e,r,n,i,s,o){return(rr=m.dynCall_viiiji=me.Kh)(t,e,r,n,i,s,o)},nr=m.dynCall_iiijiiiiii=function(t,e,r,n,i,s,o,a,l,c,u){return(nr=m.dynCall_iiijiiiiii=me.Lh)(t,e,r,n,i,s,o,a,l,c,u)},ir=m.dynCall_jij=function(t,e,r,n){return(ir=m.dynCall_jij=me.Mh)(t,e,r,n)},sr=m.dynCall_vj=function(t,e,r){return(sr=m.dynCall_vj=me.Nh)(t,e,r)},or=m.dynCall_iiiiiiiiiiiiijjji=function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g,y,v,_,b){return(or=m.dynCall_iiiiiiiiiiiiijjji=me.Oh)(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g,y,v,_,b)},ar=m.dynCall_iiiiiiiiiiijji=function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g){return(ar=m.dynCall_iiiiiiiiiiijji=me.Ph)(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g)},lr=m.dynCall_iiiiijiiiii=function(t,e,r,n,i,s,o,a,l,c,u,h){return(lr=m.dynCall_iiiiijiiiii=me.Qh)(t,e,r,n,i,s,o,a,l,c,u,h)},cr=m.dynCall_iiijiiiiiii=function(t,e,r,n,i,s,o,a,l,c,u,h){return(cr=m.dynCall_iiijiiiiiii=me.Rh)(t,e,r,n,i,s,o,a,l,c,u,h)},ur=m.dynCall_iiijiii=function(t,e,r,n,i,s,o,a){return(ur=m.dynCall_iiijiii=me.Sh)(t,e,r,n,i,s,o,a)},hr=m.dynCall_jiiiiiiiiiiiiiiiiiiiiiiiii=function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g,y,v,_,b,w,x,E,S,A,P){return(hr=m.dynCall_jiiiiiiiiiiiiiiiiiiiiiiiii=me.Th)(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g,y,v,_,b,w,x,E,S,A,P)},dr=m.dynCall_iiiddddji=function(t,e,r,n,i,s,o,a,l,c){return(dr=m.dynCall_iiiddddji=me.Uh)(t,e,r,n,i,s,o,a,l,c)},fr=m.dynCall_iiiiiijii=function(t,e,r,n,i,s,o,a,l,c){return(fr=m.dynCall_iiiiiijii=me.Vh)(t,e,r,n,i,s,o,a,l,c)},pr=m.dynCall_viiiiiji=function(t,e,r,n,i,s,o,a,l){return(pr=m.dynCall_viiiiiji=me.Wh)(t,e,r,n,i,s,o,a,l)},mr=m.dynCall_iiiiiiijiii=function(t,e,r,n,i,s,o,a,l,c,u,h){return(mr=m.dynCall_iiiiiiijiii=me.Xh)(t,e,r,n,i,s,o,a,l,c,u,h)},gr=m.dynCall_vijj=function(t,e,r,n,i,s){return(gr=m.dynCall_vijj=me.Yh)(t,e,r,n,i,s)},yr=m.dynCall_iiiiiijjii=function(t,e,r,n,i,s,o,a,l,c,u,h){return(yr=m.dynCall_iiiiiijjii=me.Zh)(t,e,r,n,i,s,o,a,l,c,u,h)},vr=m.dynCall_iiijjiji=function(t,e,r,n,i,s,o,a,l,c,u){return(vr=m.dynCall_iiijjiji=me._h)(t,e,r,n,i,s,o,a,l,c,u)},_r=m.dynCall_iiiiiiiiiiiiijjii=function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g,y,v,_){return(_r=m.dynCall_iiiiiiiiiiiiijjii=me.$h)(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g,y,v,_)},br=m.dynCall_iiiijiiiii=function(t,e,r,n,i,s,o,a,l,c,u){return(br=m.dynCall_iiiijiiiii=me.ai)(t,e,r,n,i,s,o,a,l,c,u)},wr=m.dynCall_iijiiiiiii=function(t,e,r,n,i,s,o,a,l,c,u){return(wr=m.dynCall_iijiiiiiii=me.bi)(t,e,r,n,i,s,o,a,l,c,u)},xr=m.dynCall_viijj=function(t,e,r,n,i,s,o){return(xr=m.dynCall_viijj=me.ci)(t,e,r,n,i,s,o)},Er=m.dynCall_vijjj=function(t,e,r,n,i,s,o,a){return(Er=m.dynCall_vijjj=me.di)(t,e,r,n,i,s,o,a)},Sr=m.dynCall_viijjji=function(t,e,r,n,i,s,o,a,l,c){return(Sr=m.dynCall_viijjji=me.ei)(t,e,r,n,i,s,o,a,l,c)},Ar=m.dynCall_iiijj=function(t,e,r,n,i,s,o){return(Ar=m.dynCall_iiijj=me.fi)(t,e,r,n,i,s,o)},Pr=m.dynCall_viiijj=function(t,e,r,n,i,s,o,a){return(Pr=m.dynCall_viiijj=me.gi)(t,e,r,n,i,s,o,a)},Tr=m.dynCall_iiijiiii=function(t,e,r,n,i,s,o,a,l){return(Tr=m.dynCall_iiijiiii=me.hi)(t,e,r,n,i,s,o,a,l)},Cr=m.dynCall_iiijiiiji=function(t,e,r,n,i,s,o,a,l,c,u){return(Cr=m.dynCall_iiijiiiji=me.ii)(t,e,r,n,i,s,o,a,l,c,u)},Mr=m.dynCall_iiijiiiii=function(t,e,r,n,i,s,o,a,l,c){return(Mr=m.dynCall_iiijiiiii=me.ji)(t,e,r,n,i,s,o,a,l,c)},Or=m.dynCall_jiiji=function(t,e,r,n,i,s){return(Or=m.dynCall_jiiji=me.ki)(t,e,r,n,i,s)},Rr=m.dynCall_jiijji=function(t,e,r,n,i,s,o,a){return(Rr=m.dynCall_jiijji=me.li)(t,e,r,n,i,s,o,a)},Dr=m.dynCall_iiiiiiiijjji=function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p){return(Dr=m.dynCall_iiiiiiiijjji=me.mi)(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p)},Ir=m.dynCall_iiiiiiiijiii=function(t,e,r,n,i,s,o,a,l,c,u,h,d){return(Ir=m.dynCall_iiiiiiiijiii=me.ni)(t,e,r,n,i,s,o,a,l,c,u,h,d)},kr=m.dynCall_iiijjii=function(t,e,r,n,i,s,o,a,l){return(kr=m.dynCall_iiijjii=me.oi)(t,e,r,n,i,s,o,a,l)},Lr=m.dynCall_iiiiijjii=function(t,e,r,n,i,s,o,a,l,c,u){return(Lr=m.dynCall_iiiiijjii=me.pi)(t,e,r,n,i,s,o,a,l,c,u)},Fr=m.dynCall_iiiiiiijji=function(t,e,r,n,i,s,o,a,l,c,u,h){return(Fr=m.dynCall_iiiiiiijji=me.qi)(t,e,r,n,i,s,o,a,l,c,u,h)},jr=m.dynCall_iiiiijji=function(t,e,r,n,i,s,o,a,l,c){return(jr=m.dynCall_iiiiijji=me.ri)(t,e,r,n,i,s,o,a,l,c)},Nr=m.dynCall_vijiii=function(t,e,r,n,i,s,o){return(Nr=m.dynCall_vijiii=me.si)(t,e,r,n,i,s,o)},Gr=m.dynCall_vijid=function(t,e,r,n,i,s){return(Gr=m.dynCall_vijid=me.ti)(t,e,r,n,i,s)},$r=m.dynCall_iiiiiiij=function(t,e,r,n,i,s,o,a,l){return($r=m.dynCall_iiiiiiij=me.ui)(t,e,r,n,i,s,o,a,l)},zr=m.dynCall_iijdddd=function(t,e,r,n,i,s,o,a){return(zr=m.dynCall_iijdddd=me.vi)(t,e,r,n,i,s,o,a)},Ur=m.dynCall_iiiiiiiijii=function(t,e,r,n,i,s,o,a,l,c,u,h){return(Ur=m.dynCall_iiiiiiiijii=me.wi)(t,e,r,n,i,s,o,a,l,c,u,h)},Br=m.dynCall_iiiiijiiii=function(t,e,r,n,i,s,o,a,l,c,u){return(Br=m.dynCall_iiiiijiiii=me.xi)(t,e,r,n,i,s,o,a,l,c,u)},Vr=m.dynCall_viji=function(t,e,r,n,i){return(Vr=m.dynCall_viji=me.yi)(t,e,r,n,i)},qr=m.dynCall_viijji=function(t,e,r,n,i,s,o,a){return(qr=m.dynCall_viijji=me.zi)(t,e,r,n,i,s,o,a)},Kr=m.dynCall_jijj=function(t,e,r,n,i,s){return(Kr=m.dynCall_jijj=me.Ai)(t,e,r,n,i,s)},Wr=m.dynCall_iijjjddi=function(t,e,r,n,i,s,o,a,l,c,u){return(Wr=m.dynCall_iijjjddi=me.Bi)(t,e,r,n,i,s,o,a,l,c,u)},Hr=m.dynCall_vijiidddi=function(t,e,r,n,i,s,o,a,l,c){return(Hr=m.dynCall_vijiidddi=me.Ci)(t,e,r,n,i,s,o,a,l,c)},Yr=m.dynCall_jiiid=function(t,e,r,n,i){return(Yr=m.dynCall_jiiid=me.Di)(t,e,r,n,i)},Xr=m.dynCall_iiiiiiiiiijiiiii=function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g,y){return(Xr=m.dynCall_iiiiiiiiiijiiiii=me.Ei)(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g,y)},Zr=m.dynCall_iiijii=function(t,e,r,n,i,s,o){return(Zr=m.dynCall_iiijii=me.Fi)(t,e,r,n,i,s,o)},Jr=m.dynCall_jji=function(t,e,r,n){return(Jr=m.dynCall_jji=me.Gi)(t,e,r,n)},Qr=m.dynCall_viiij=function(t,e,r,n,i,s){return(Qr=m.dynCall_viiij=me.Hi)(t,e,r,n,i,s)},tn=m.dynCall_iiiiiiiiiiiiiijj=function(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g,y,v){return(tn=m.dynCall_iiiiiiiiiiiiiijj=me.Ii)(t,e,r,n,i,s,o,a,l,c,u,h,d,f,p,g,y,v)};function en(){function e(){ce||(ce=!0,m.calledRun=!0,U)||(m.noFSInit||Lt.init.initialized||Lt.init(),Lt.ignorePermissions=!1,$t.root=Lt.mount($t,{},null),at(K),t(m),m.onRuntimeInitialized&&m.onRuntimeInitialized(),function(){if(m.postRun)for("function"==typeof m.postRun&&(m.postRun=[m.postRun]);m.postRun.length;)t=m.postRun.shift(),W.unshift(t);var t;at(W)}())}0<H||(function(){if(m.preRun)for("function"==typeof m.preRun&&(m.preRun=[m.preRun]);m.preRun.length;)t=m.preRun.shift(),q.unshift(t);var t;at(q)}(),0<H)||(m.setStatus?(m.setStatus("Running..."),setTimeout((function(){setTimeout((function(){m.setStatus("")}),1),e()}),1)):e())}if(m.addRunDependency=X,m.removeRunDependency=Z,m.FS_createPath=Lt.createPath,m.FS_createLazyFile=Lt.createLazyFile,m.FS_createDevice=Lt.createDevice,m.ENV=Zt,m.ccall=se,m.cwrap=function(t,e,r,n){var i=!r||r.every((function(t){return"number"===t||"boolean"===t}));return"string"!==e&&i&&!n?ie(t):function(){return se(t,e,r,arguments)}},m.addFunction=function(t,e){if(n=t,le||(le=new WeakMap,function(t,e){if(le)for(var r=t;r<t+e;r++){var n=ht(r);n&&le.set(n,r)}}(0,dt.length)),n=le.get(n)||0)return n;var r,n=function(){if(fe.length)return fe.pop();try{dt.grow(1)}catch(t){if(t instanceof RangeError)throw"Unable to grow wasm table. Set ALLOW_TABLE_GROWTH.";throw t}return dt.length-1}();try{oe(n,t)}catch(s){if(!(s instanceof TypeError))throw s;r=t;var i="function"==typeof WebAssembly.Function?new WebAssembly.Function(function(t){for(var e={i:"i32",j:"i64",f:"f32",d:"f64",e:"externref",p:"i32"},r={parameters:[],results:"v"==t[0]?[]:[e[t[0]]]},n=1;n<t.length;++n)r.parameters.push(e[t[n]]);return r}(e),r):(function(t,e){var r=t.slice(0,1),n=t.slice(1),i={i:127,p:127,j:126,f:125,d:124,e:111};e.push(96),de(n.length,e);for(var s=0;s<n.length;++s)e.push(i[n[s]]);"v"==r?e.push(0):e.push(1,i[r])}(e,e=[1]),de(e.length,i=[0,97,115,109,1,0,0,0,1]),i.push.apply(i,e),i.push(2,7,1,1,101,1,102,0,0,7,5,1,1,102,0,0),e=new WebAssembly.Module(new Uint8Array(i)),new WebAssembly.Instance(e,{e:{f:r}}).exports.f);oe(n,i)}return le.set(t,n),n},m.setValue=function(t,e){var r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:"i8";switch(r=r.endsWith("*")?"*":r){case"i1":case"i8":I[0|t]=e;break;case"i16":L[t>>1]=e;break;case"i32":F[t>>2]=e;break;case"i64":J("to do setValue(i64) use WASM_BIGINT");case"float":N[t>>2]=e;break;case"double":G[t>>3]=e;break;case"*":j[t>>2]=e;break;default:J("invalid type for setValue: ".concat(r))}},m.getValue=function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:"i8";switch(e=e.endsWith("*")?"*":e){case"i1":case"i8":return I[0|t];case"i16":return L[t>>1];case"i32":return F[t>>2];case"i64":J("to do getValue(i64) use WASM_BIGINT");case"float":return N[t>>2];case"double":return G[t>>3];case"*":return j[t>>2];default:J("invalid type for getValue: ".concat(e))}},m.UTF8ToString=ut,m.stringToUTF8=Gt,m.lengthBytesUTF8=St,m.FS_createPreloadedFile=Lt.createPreloadedFile,m.FS=Lt,m.FS_createDataFile=Lt.createDataFile,m.FS_unlink=Lt.unlink,m.MEMFS=Ot,m.WORKERFS=kt,m.NODEFS=It,Y=function t(){ce||en(),ce||(Y=t)},m.preInit)for("function"==typeof m.preInit&&(m.preInit=[m.preInit]);0<m.preInit.length;)m.preInit.pop()();return en(),d.ready};var b=h(g.exports),w={Module:{}};function x(){var t=w.CPLGetLastErrorMsg(),e=w.CPLGetLastErrorNo();return w.CPLErrorReset(),{no:e,message:t}}function E(t){for(var e=[],r={},n=0;n<t.length;n+=1){var i=t[n];"--config"===i?(r[t[n+1]]=t[n+2],n+=2):e.push(i)}var s=e.map((function(t){return w.Module._malloc(w.Module.lengthBytesUTF8(t)+1)})),o=(s.push(0),Uint32Array.from(s)),a=(e.forEach((function(t,e){w.Module.stringToUTF8(t,o[e],w.Module.lengthBytesUTF8(t)+1)})),w.Module._malloc(o.length*o.BYTES_PER_ELEMENT));return w.Module.HEAPU32.set(o,a/o.BYTES_PER_ELEMENT),{ptr:a,ptrArray:s,config:r}}function S(t){w.Module._free(t.ptr),t.ptrArray.forEach((function(t){w.Module._free(t)}))}var A="/input",P="/output",T=P,C=(_={},g=d(Object.freeze({__proto__:null,default:{}})),d(Object.freeze({__proto__:null,default:{}}))),M=_,O=(M.parser=function(t,e){return new R(t,e)},M.SAXParser=R,M.SAXStream=k,M.createStream=function(t,e){return new k(t,e)},M.MAX_BUFFER_LENGTH=65536,["comment","sgmlDecl","textNode","tagName","doctype","procInstName","procInstBody","entity","attribName","attribValue","cdata","script"]);function R(t,e){if(!(this instanceof R))return new R(t,e);for(var r=this,n=r,i=0,s=O.length;i<s;i++)n[O[i]]="";r.q=r.c="",r.bufferCheckPosition=M.MAX_BUFFER_LENGTH,r.opt=e||{},r.opt.lowercase=r.opt.lowercase||r.opt.lowercasetags,r.looseCase=r.opt.lowercase?"toLowerCase":"toUpperCase",r.tags=[],r.closed=r.closedRoot=r.sawRoot=!1,r.tag=r.error=null,r.strict=!!t,r.noscript=!(!t&&!r.opt.noscript),r.state=X.BEGIN,r.strictEntities=r.opt.strictEntities,r.ENTITIES=r.strictEntities?Object.create(M.XML_ENTITIES):Object.create(M.ENTITIES),r.attribList=[],r.opt.xmlns&&(r.ns=Object.create(G)),r.trackPosition=!1!==r.opt.position,r.trackPosition&&(r.position=r.line=r.column=0),Z(r,"onready")}M.EVENTS=["text","processinginstruction","sgmldeclaration","doctype","comment","opentagstart","attribute","opentag","closetag","opencdata","cdata","closecdata","error","end","ready","script","opennamespace","closenamespace"],Object.create||(Object.create=function(t){function e(){}return e.prototype=t,new e}),Object.keys||(Object.keys=function(t){var e,r=[];for(e in t)t.hasOwnProperty(e)&&r.push(e);return r}),R.prototype={end:function(){rt(this)},write:function(t){var e=this;if(this.error)throw this.error;if(e.closed)return et(e,"Cannot write after close. Assign an onready handler.");if(null===t)return rt(e);"object"==typeof t&&(t=t.toString());for(var r,n,i=0,s="";s=ut(t,i++),e.c=s;)switch(e.trackPosition&&(e.position++,"\n"===s?(e.line++,e.column=0):e.column++),e.state){case X.BEGIN:if(e.state=X.BEGIN_WHITESPACE,"\ufeff"===s)continue;ct(e,s);continue;case X.BEGIN_WHITESPACE:ct(e,s);continue;case X.TEXT:if(e.sawRoot&&!e.closedRoot){for(var o=i-1;s&&"<"!==s&&"&"!==s;)(s=ut(t,i++))&&e.trackPosition&&(e.position++,"\n"===s?(e.line++,e.column=0):e.column++);e.textNode+=t.substring(o,i-1)}"<"!==s||e.sawRoot&&e.closedRoot&&!e.strict?(V(s)||e.sawRoot&&!e.closedRoot||nt(e,"Text data outside of root node."),"&"===s?e.state=X.TEXT_ENTITY:e.textNode+=s):(e.state=X.OPEN_WAKA,e.startTagPosition=e.position);continue;case X.SCRIPT:"<"===s?e.state=X.SCRIPT_ENDING:e.script+=s;continue;case X.SCRIPT_ENDING:"/"===s?e.state=X.CLOSE_TAG:(e.script+="<"+s,e.state=X.SCRIPT);continue;case X.OPEN_WAKA:"!"===s?(e.state=X.SGML_DECL,e.sgmlDecl=""):V(s)||(K($,s)?(e.state=X.OPEN_TAG,e.tagName=s):"/"===s?(e.state=X.CLOSE_TAG,e.tagName=""):"?"===s?(e.state=X.PROC_INST,e.procInstName=e.procInstBody=""):(nt(e,"Unencoded <"),e.startTagPosition+1<e.position&&(o=e.position-e.startTagPosition,s=new Array(o).join(" ")+s),e.textNode+="<"+s,e.state=X.TEXT));continue;case X.SGML_DECL:(e.sgmlDecl+s).toUpperCase()===L?(J(e,"onopencdata"),e.state=X.CDATA,e.sgmlDecl="",e.cdata=""):e.sgmlDecl+s==="--"?(e.state=X.COMMENT,e.comment="",e.sgmlDecl=""):(e.sgmlDecl+s).toUpperCase()===F?(e.state=X.DOCTYPE,(e.doctype||e.sawRoot)&&nt(e,"Inappropriately located doctype declaration"),e.doctype="",e.sgmlDecl=""):">"===s?(J(e,"onsgmldeclaration",e.sgmlDecl),e.sgmlDecl="",e.state=X.TEXT):(q(s)&&(e.state=X.SGML_DECL_QUOTED),e.sgmlDecl+=s);continue;case X.SGML_DECL_QUOTED:s===e.q&&(e.state=X.SGML_DECL,e.q=""),e.sgmlDecl+=s;continue;case X.DOCTYPE:">"===s?(e.state=X.TEXT,J(e,"ondoctype",e.doctype),e.doctype=!0):(e.doctype+=s,"["===s?e.state=X.DOCTYPE_DTD:q(s)&&(e.state=X.DOCTYPE_QUOTED,e.q=s));continue;case X.DOCTYPE_QUOTED:e.doctype+=s,s===e.q&&(e.q="",e.state=X.DOCTYPE);continue;case X.DOCTYPE_DTD:e.doctype+=s,"]"===s?e.state=X.DOCTYPE:q(s)&&(e.state=X.DOCTYPE_DTD_QUOTED,e.q=s);continue;case X.DOCTYPE_DTD_QUOTED:e.doctype+=s,s===e.q&&(e.state=X.DOCTYPE_DTD,e.q="");continue;case X.COMMENT:"-"===s?e.state=X.COMMENT_ENDING:e.comment+=s;continue;case X.COMMENT_ENDING:"-"===s?(e.state=X.COMMENT_ENDED,e.comment=tt(e.opt,e.comment),e.comment&&J(e,"oncomment",e.comment),e.comment=""):(e.comment+="-"+s,e.state=X.COMMENT);continue;case X.COMMENT_ENDED:">"!==s?(nt(e,"Malformed comment"),e.comment+="--"+s,e.state=X.COMMENT):e.state=X.TEXT;continue;case X.CDATA:"]"===s?e.state=X.CDATA_ENDING:e.cdata+=s;continue;case X.CDATA_ENDING:"]"===s?e.state=X.CDATA_ENDING_2:(e.cdata+="]"+s,e.state=X.CDATA);continue;case X.CDATA_ENDING_2:">"===s?(e.cdata&&J(e,"oncdata",e.cdata),J(e,"onclosecdata"),e.cdata="",e.state=X.TEXT):"]"===s?e.cdata+="]":(e.cdata+="]]"+s,e.state=X.CDATA);continue;case X.PROC_INST:"?"===s?e.state=X.PROC_INST_ENDING:V(s)?e.state=X.PROC_INST_BODY:e.procInstName+=s;continue;case X.PROC_INST_BODY:if(!e.procInstBody&&V(s))continue;"?"===s?e.state=X.PROC_INST_ENDING:e.procInstBody+=s;continue;case X.PROC_INST_ENDING:">"===s?(J(e,"onprocessinginstruction",{name:e.procInstName,body:e.procInstBody}),e.procInstName=e.procInstBody="",e.state=X.TEXT):(e.procInstBody+="?"+s,e.state=X.PROC_INST_BODY);continue;case X.OPEN_TAG:K(z,s)?e.tagName+=s:(function(t){t.strict||(t.tagName=t.tagName[t.looseCase]());var e=t.tags[t.tags.length-1]||t,r=t.tag={name:t.tagName,attributes:{}};t.opt.xmlns&&(r.ns=e.ns),t.attribList.length=0,J(t,"onopentagstart",r)}(e),">"===s?ot(e):"/"===s?e.state=X.OPEN_TAG_SLASH:(V(s)||nt(e,"Invalid character in tag name"),e.state=X.ATTRIB));continue;case X.OPEN_TAG_SLASH:">"===s?(ot(e,!0),at(e)):(nt(e,"Forward-slash in opening tag not followed by >"),e.state=X.ATTRIB);continue;case X.ATTRIB:if(V(s))continue;">"===s?ot(e):"/"===s?e.state=X.OPEN_TAG_SLASH:K($,s)?(e.attribName=s,e.attribValue="",e.state=X.ATTRIB_NAME):nt(e,"Invalid attribute name");continue;case X.ATTRIB_NAME:"="===s?e.state=X.ATTRIB_VALUE:">"===s?(nt(e,"Attribute without value"),e.attribValue=e.attribName,st(e),ot(e)):V(s)?e.state=X.ATTRIB_NAME_SAW_WHITE:K(z,s)?e.attribName+=s:nt(e,"Invalid attribute name");continue;case X.ATTRIB_NAME_SAW_WHITE:if("="===s)e.state=X.ATTRIB_VALUE;else{if(V(s))continue;nt(e,"Attribute without value"),e.tag.attributes[e.attribName]="",e.attribValue="",J(e,"onattribute",{name:e.attribName,value:""}),e.attribName="",">"===s?ot(e):K($,s)?(e.attribName=s,e.state=X.ATTRIB_NAME):(nt(e,"Invalid attribute name"),e.state=X.ATTRIB)}continue;case X.ATTRIB_VALUE:if(V(s))continue;q(s)?(e.q=s,e.state=X.ATTRIB_VALUE_QUOTED):(nt(e,"Unquoted attribute value"),e.state=X.ATTRIB_VALUE_UNQUOTED,e.attribValue=s);continue;case X.ATTRIB_VALUE_QUOTED:if(s!==e.q){"&"===s?e.state=X.ATTRIB_VALUE_ENTITY_Q:e.attribValue+=s;continue}st(e),e.q="",e.state=X.ATTRIB_VALUE_CLOSED;continue;case X.ATTRIB_VALUE_CLOSED:V(s)?e.state=X.ATTRIB:">"===s?ot(e):"/"===s?e.state=X.OPEN_TAG_SLASH:K($,s)?(nt(e,"No whitespace between attributes"),e.attribName=s,e.attribValue="",e.state=X.ATTRIB_NAME):nt(e,"Invalid attribute name");continue;case X.ATTRIB_VALUE_UNQUOTED:if(!function(t){return">"===t||V(t)}(s)){"&"===s?e.state=X.ATTRIB_VALUE_ENTITY_U:e.attribValue+=s;continue}st(e),">"===s?ot(e):e.state=X.ATTRIB;continue;case X.CLOSE_TAG:if(e.tagName)">"===s?at(e):K(z,s)?e.tagName+=s:e.script?(e.script+="</"+e.tagName,e.tagName="",e.state=X.SCRIPT):(V(s)||nt(e,"Invalid tagname in closing tag"),e.state=X.CLOSE_TAG_SAW_WHITE);else{if(V(s))continue;!function(t,e){return!K(t,e)}($,s)?e.tagName=s:e.script?(e.script+="</"+s,e.state=X.SCRIPT):nt(e,"Invalid tagname in closing tag.")}continue;case X.CLOSE_TAG_SAW_WHITE:if(V(s))continue;">"===s?at(e):nt(e,"Invalid characters in closing tag");continue;case X.TEXT_ENTITY:case X.ATTRIB_VALUE_ENTITY_Q:case X.ATTRIB_VALUE_ENTITY_U:switch(e.state){case X.TEXT_ENTITY:r=X.TEXT,n="textNode";break;case X.ATTRIB_VALUE_ENTITY_Q:r=X.ATTRIB_VALUE_QUOTED,n="attribValue";break;case X.ATTRIB_VALUE_ENTITY_U:r=X.ATTRIB_VALUE_UNQUOTED,n="attribValue"}var a;";"===s?e.opt.unparsedEntities?(a=lt(e),e.entity="",e.state=r,e.write(a)):(e[n]+=lt(e),e.entity="",e.state=r):K(e.entity.length?B:U,s)?e.entity+=s:(nt(e,"Invalid character in entity name"),e[n]+="&"+e.entity+s,e.entity="",e.state=r);continue;default:throw new Error(e,"Unknown state: "+e.state)}return e.position>=e.bufferCheckPosition&&function(t){for(var e=Math.max(M.MAX_BUFFER_LENGTH,10),r=0,n=0,i=O.length;n<i;n++){var s=t[O[n]].length;if(e<s)switch(O[n]){case"textNode":Q(t);break;case"cdata":J(t,"oncdata",t.cdata),t.cdata="";break;case"script":J(t,"onscript",t.script),t.script="";break;default:et(t,"Max buffer length exceeded: "+O[n])}r=Math.max(r,s)}var o=M.MAX_BUFFER_LENGTH-r;t.bufferCheckPosition=o+t.position}(e),e},resume:function(){return this.error=null,this},close:function(){return this.write(null)},flush:function(){var t;Q(t=this),""!==t.cdata&&(J(t,"oncdata",t.cdata),t.cdata=""),""!==t.script&&(J(t,"onscript",t.script),t.script="")}};try{D=g.Stream}catch(d){D=function(){}}var D=D||function(){},I=M.EVENTS.filter((function(t){return"error"!==t&&"end"!==t}));function k(t,e){if(!(this instanceof k))return new k(t,e);D.apply(this),this._parser=new R(t,e),this.writable=!0,this.readable=!0;var r=this;this._parser.onend=function(){r.emit("end")},this._parser.onerror=function(t){r.emit("error",t),r._parser.error=null},this._decoder=null,I.forEach((function(t){Object.defineProperty(r,"on"+t,{get:function(){return r._parser["on"+t]},set:function(e){if(!e)return r.removeAllListeners(t),r._parser["on"+t]=e;r.on(t,e)},enumerable:!0,configurable:!1})}))}(k.prototype=Object.create(D.prototype,{constructor:{value:k}})).write=function(t){var e;return"function"==typeof Buffer&&"function"==typeof Buffer.isBuffer&&Buffer.isBuffer(t)&&(this._decoder||(e=C.StringDecoder,this._decoder=new e("utf8")),t=this._decoder.write(t)),this._parser.write(t.toString()),this.emit("data",t),!0},k.prototype.end=function(t){return t&&t.length&&this.write(t),this._parser.end(),!0},k.prototype.on=function(t,e){var r=this;return r._parser["on"+t]||-1===I.indexOf(t)||(r._parser["on"+t]=function(){var e=1===arguments.length?[arguments[0]]:Array.apply(null,arguments);e.splice(0,0,t),r.emit.apply(r,e)}),D.prototype.on.call(r,t,e)};var L="[CDATA[",F="DOCTYPE",j="http://www.w3.org/XML/1998/namespace",N="http://www.w3.org/2000/xmlns/",G={xml:j,xmlns:N},$=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,z=/[:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/,U=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,B=/[#:_A-Za-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\u00B7\u0300-\u036F\u203F-\u2040.\d-]/;function V(t){return" "===t||"\n"===t||"\r"===t||"\t"===t}function q(t){return'"'===t||"'"===t}function K(t,e){return t.test(e)}var W,H,Y,X=0;for(W in M.STATE={BEGIN:X++,BEGIN_WHITESPACE:X++,TEXT:X++,TEXT_ENTITY:X++,OPEN_WAKA:X++,SGML_DECL:X++,SGML_DECL_QUOTED:X++,DOCTYPE:X++,DOCTYPE_QUOTED:X++,DOCTYPE_DTD:X++,DOCTYPE_DTD_QUOTED:X++,COMMENT_STARTING:X++,COMMENT:X++,COMMENT_ENDING:X++,COMMENT_ENDED:X++,CDATA:X++,CDATA_ENDING:X++,CDATA_ENDING_2:X++,PROC_INST:X++,PROC_INST_BODY:X++,PROC_INST_ENDING:X++,OPEN_TAG:X++,OPEN_TAG_SLASH:X++,ATTRIB:X++,ATTRIB_NAME:X++,ATTRIB_NAME_SAW_WHITE:X++,ATTRIB_VALUE:X++,ATTRIB_VALUE_QUOTED:X++,ATTRIB_VALUE_CLOSED:X++,ATTRIB_VALUE_UNQUOTED:X++,ATTRIB_VALUE_ENTITY_Q:X++,ATTRIB_VALUE_ENTITY_U:X++,CLOSE_TAG:X++,CLOSE_TAG_SAW_WHITE:X++,SCRIPT:X++,SCRIPT_ENDING:X++},M.XML_ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},M.ENTITIES={amp:"&",gt:">",lt:"<",quot:'"',apos:"'",AElig:198,Aacute:193,Acirc:194,Agrave:192,Aring:197,Atilde:195,Auml:196,Ccedil:199,ETH:208,Eacute:201,Ecirc:202,Egrave:200,Euml:203,Iacute:205,Icirc:206,Igrave:204,Iuml:207,Ntilde:209,Oacute:211,Ocirc:212,Ograve:210,Oslash:216,Otilde:213,Ouml:214,THORN:222,Uacute:218,Ucirc:219,Ugrave:217,Uuml:220,Yacute:221,aacute:225,acirc:226,aelig:230,agrave:224,aring:229,atilde:227,auml:228,ccedil:231,eacute:233,ecirc:234,egrave:232,eth:240,euml:235,iacute:237,icirc:238,igrave:236,iuml:239,ntilde:241,oacute:243,ocirc:244,ograve:242,oslash:248,otilde:245,ouml:246,szlig:223,thorn:254,uacute:250,ucirc:251,ugrave:249,uuml:252,yacute:253,yuml:255,copy:169,reg:174,nbsp:160,iexcl:161,cent:162,pound:163,curren:164,yen:165,brvbar:166,sect:167,uml:168,ordf:170,laquo:171,not:172,shy:173,macr:175,deg:176,plusmn:177,sup1:185,sup2:178,sup3:179,acute:180,micro:181,para:182,middot:183,cedil:184,ordm:186,raquo:187,frac14:188,frac12:189,frac34:190,iquest:191,times:215,divide:247,OElig:338,oelig:339,Scaron:352,scaron:353,Yuml:376,fnof:402,circ:710,tilde:732,Alpha:913,Beta:914,Gamma:915,Delta:916,Epsilon:917,Zeta:918,Eta:919,Theta:920,Iota:921,Kappa:922,Lambda:923,Mu:924,Nu:925,Xi:926,Omicron:927,Pi:928,Rho:929,Sigma:931,Tau:932,Upsilon:933,Phi:934,Chi:935,Psi:936,Omega:937,alpha:945,beta:946,gamma:947,delta:948,epsilon:949,zeta:950,eta:951,theta:952,iota:953,kappa:954,lambda:955,mu:956,nu:957,xi:958,omicron:959,pi:960,rho:961,sigmaf:962,sigma:963,tau:964,upsilon:965,phi:966,chi:967,psi:968,omega:969,thetasym:977,upsih:978,piv:982,ensp:8194,emsp:8195,thinsp:8201,zwnj:8204,zwj:8205,lrm:8206,rlm:8207,ndash:8211,mdash:8212,lsquo:8216,rsquo:8217,sbquo:8218,ldquo:8220,rdquo:8221,bdquo:8222,dagger:8224,Dagger:8225,bull:8226,hellip:8230,permil:8240,prime:8242,Prime:8243,lsaquo:8249,rsaquo:8250,oline:8254,frasl:8260,euro:8364,image:8465,weierp:8472,real:8476,trade:8482,alefsym:8501,larr:8592,uarr:8593,rarr:8594,darr:8595,harr:8596,crarr:8629,lArr:8656,uArr:8657,rArr:8658,dArr:8659,hArr:8660,forall:8704,part:8706,exist:8707,empty:8709,nabla:8711,isin:8712,notin:8713,ni:8715,prod:8719,sum:8721,minus:8722,lowast:8727,radic:8730,prop:8733,infin:8734,ang:8736,and:8743,or:8744,cap:8745,cup:8746,int:8747,there4:8756,sim:8764,cong:8773,asymp:8776,ne:8800,equiv:8801,le:8804,ge:8805,sub:8834,sup:8835,nsub:8836,sube:8838,supe:8839,oplus:8853,otimes:8855,perp:8869,sdot:8901,lceil:8968,rceil:8969,lfloor:8970,rfloor:8971,lang:9001,rang:9002,loz:9674,spades:9824,clubs:9827,hearts:9829,diams:9830},Object.keys(M.ENTITIES).forEach((function(t){var e="number"==typeof(e=M.ENTITIES[t])?String.fromCharCode(e):e;M.ENTITIES[t]=e})),M.STATE)M.STATE[M.STATE[W]]=W;function Z(t,e,r){t[e]&&t[e](r)}function J(t,e,r){t.textNode&&Q(t),Z(t,e,r)}function Q(t){t.textNode=tt(t.opt,t.textNode),t.textNode&&Z(t,"ontext",t.textNode),t.textNode=""}function tt(t,e){return t.trim&&(e=e.trim()),t.normalize?e.replace(/\s+/g," "):e}function et(t,e){return Q(t),t.trackPosition&&(e+="\nLine: "+t.line+"\nColumn: "+t.column+"\nChar: "+t.c),e=new Error(e),t.error=e,Z(t,"onerror",e),t}function rt(t){return t.sawRoot&&!t.closedRoot&&nt(t,"Unclosed root tag"),t.state!==X.BEGIN&&t.state!==X.BEGIN_WHITESPACE&&t.state!==X.TEXT&&et(t,"Unexpected end"),Q(t),t.c="",t.closed=!0,Z(t,"onend"),R.call(t,t.strict,t.opt),t}function nt(t,e){if("object"!=typeof t||!(t instanceof R))throw new Error("bad call to strictFail");t.strict&&et(t,e)}function it(t,e){var r=(n=t.indexOf(":")<0?["",t]:t.split(":"))[0],n=n[1];return e&&"xmlns"===t&&(r="xmlns",n=""),{prefix:r,local:n}}function st(t){var e,r,n;t.strict||(t.attribName=t.attribName[t.looseCase]()),-1!==t.attribList.indexOf(t.attribName)||t.tag.attributes.hasOwnProperty(t.attribName)||(t.opt.xmlns?(r=(e=it(t.attribName,!0)).prefix,e=e.local,"xmlns"===r&&("xml"===e&&t.attribValue!==j?nt(t,"xml: prefix must be bound to "+j+"\nActual: "+t.attribValue):"xmlns"===e&&t.attribValue!==N?nt(t,"xmlns: prefix must be bound to "+N+"\nActual: "+t.attribValue):(r=t.tag,n=t.tags[t.tags.length-1]||t,r.ns===n.ns&&(r.ns=Object.create(n.ns)),r.ns[e]=t.attribValue)),t.attribList.push([t.attribName,t.attribValue])):(t.tag.attributes[t.attribName]=t.attribValue,J(t,"onattribute",{name:t.attribName,value:t.attribValue}))),t.attribName=t.attribValue=""}function ot(t,e){if(t.opt.xmlns){var r=t.tag,n=it(t.tagName);r.prefix=n.prefix,r.local=n.local,r.uri=r.ns[n.prefix]||"",r.prefix&&!r.uri&&(nt(t,"Unbound namespace prefix: "+JSON.stringify(t.tagName)),r.uri=n.prefix),n=t.tags[t.tags.length-1]||t,r.ns&&n.ns!==r.ns&&Object.keys(r.ns).forEach((function(e){J(t,"onopennamespace",{prefix:e,uri:r.ns[e]})}));for(var i=0,s=t.attribList.length;i<s;i++){var o=(a=t.attribList[i])[0],a=a[1],l=(c=it(o,!0)).prefix,c=c.local,u=""!==l&&r.ns[l]||"";a={name:o,value:a,prefix:l,local:c,uri:u},l&&"xmlns"!==l&&!u&&(nt(t,"Unbound namespace prefix: "+JSON.stringify(l)),a.uri=l),t.tag.attributes[o]=a,J(t,"onattribute",a)}t.attribList.length=0}t.tag.isSelfClosing=!!e,t.sawRoot=!0,t.tags.push(t.tag),J(t,"onopentag",t.tag),e||(t.noscript||"script"!==t.tagName.toLowerCase()?t.state=X.TEXT:t.state=X.SCRIPT,t.tag=null,t.tagName=""),t.attribName=t.attribValue="",t.attribList.length=0}function at(t){if(t.tagName){if(t.script){if("script"!==t.tagName)return t.script+="</"+t.tagName+">",t.tagName="",void(t.state=X.SCRIPT);J(t,"onscript",t.script),t.script=""}for(var e=t.tags.length,r=t.tagName,n=r=t.strict?r:r[t.looseCase]();e--&&t.tags[e].name!==n;)nt(t,"Unexpected close tag");if(e<0)nt(t,"Unmatched closing tag: "+t.tagName),t.textNode+="</"+t.tagName+">";else{t.tagName=r;for(var i=t.tags.length;i-- >e;){var s,o=t.tag=t.tags.pop();for(s in t.tagName=t.tag.name,J(t,"onclosetag",t.tagName),o.ns)o.ns[s];var a=t.tags[t.tags.length-1]||t;t.opt.xmlns&&o.ns!==a.ns&&Object.keys(o.ns).forEach((function(e){var r=o.ns[e];J(t,"onclosenamespace",{prefix:e,uri:r})}))}0===e&&(t.closedRoot=!0),t.tagName=t.attribValue=t.attribName="",t.attribList.length=0}}else nt(t,"Weird empty close tag."),t.textNode+="</>";t.state=X.TEXT}function lt(t){var e,r=t.entity,n=r.toLowerCase(),i="";return t.ENTITIES[r]||t.ENTITIES[n]||("#"===(r=n).charAt(0)&&(i="x"===r.charAt(1)?(r=r.slice(2),(e=parseInt(r,16)).toString(16)):(r=r.slice(1),(e=parseInt(r,10)).toString(10))),r=r.replace(/^0+/,""),isNaN(e)||i.toLowerCase()!==r?(nt(t,"Invalid character entity"),"&"+t.entity+";"):String.fromCodePoint(e))}function ct(t,e){"<"===e?(t.state=X.OPEN_WAKA,t.startTagPosition=t.position):V(e)||(nt(t,"Non-whitespace before first tag."),t.textNode=e,t.state=X.TEXT)}function ut(t,e){return e<t.length?t.charAt(e):""}function ht(){var t=[],e=-1,r=arguments.length;if(!r)return"";for(var n="";++e<r;){var i=Number(arguments[e]);if(!isFinite(i)||i<0||1114111<i||Y(i)!==i)throw RangeError("Invalid code point: "+i);i<=65535?t.push(i):t.push(55296+((i-=65536)>>10),i%1024+56320),(e+1===r||16384<t.length)&&(n+=H.apply(null,t),t.length=0)}return n}X=M.STATE,String.fromCodePoint||(H=String.fromCharCode,Y=Math.floor,Object.defineProperty?Object.defineProperty(String,"fromCodePoint",{value:ht,configurable:!0,writable:!0}):String.fromCodePoint=ht),g=function(t){return Array.isArray?Array.isArray(t):"[object Array]"===Object.prototype.toString.call(t)};var dt,ft,pt=g,mt={copyOptions:function(t){var e,r={};for(e in t)t.hasOwnProperty(e)&&(r[e]=t[e]);return r},ensureFlagExists:function(t,e){t in e&&"boolean"==typeof e[t]||(e[t]=!1)},ensureSpacesExists:function(t){"spaces"in t&&("number"==typeof t.spaces||"string"==typeof t.spaces)||(t.spaces=0)},ensureAlwaysArrayExists:function(t){"alwaysArray"in t&&("boolean"==typeof t.alwaysArray||pt(t.alwaysArray))||(t.alwaysArray=!1)},ensureKeyExists:function(t,e){t+"Key"in e&&"string"==typeof e[t+"Key"]||(e[t+"Key"]=e.compact?"_"+t:t)},checkFnExists:function(t,e){return t+"Fn"in e}},gt=_,yt=mt,vt=g;function _t(t){var e,r=Number(t);return isNaN(r)?"true"===(e=t.toLowerCase())||"false"!==e&&t:r}function bt(t,e){var r,n;if(dt.compact){if(!ft[dt[t+"Key"]]&&(vt(dt.alwaysArray)?-1!==dt.alwaysArray.indexOf(dt[t+"Key"]):dt.alwaysArray)&&(ft[dt[t+"Key"]]=[]),ft[dt[t+"Key"]]&&!vt(ft[dt[t+"Key"]])&&(ft[dt[t+"Key"]]=[ft[dt[t+"Key"]]]),t+"Fn"in dt&&"string"==typeof e&&(e=dt[t+"Fn"](e,ft)),"instruction"===t&&("instructionFn"in dt||"instructionNameFn"in dt))for(r in e)e.hasOwnProperty(r)&&("instructionFn"in dt?e[r]=dt.instructionFn(e[r],r,ft):(n=e[r],delete e[r],e[dt.instructionNameFn(r,n,ft)]=n));vt(ft[dt[t+"Key"]])?ft[dt[t+"Key"]].push(e):ft[dt[t+"Key"]]=e}else{ft[dt.elementsKey]||(ft[dt.elementsKey]=[]);var i={};if("instruction"===(i[dt.typeKey]=t)){for(r in e)if(e.hasOwnProperty(r))break;i[dt.nameKey]="instructionNameFn"in dt?dt.instructionNameFn(r,e,ft):r,dt.instructionHasAttributes?(i[dt.attributesKey]=e[r][dt.attributesKey],"instructionFn"in dt&&(i[dt.attributesKey]=dt.instructionFn(i[dt.attributesKey],r,ft))):("instructionFn"in dt&&(e[r]=dt.instructionFn(e[r],r,ft)),i[dt.instructionKey]=e[r])}else t+"Fn"in dt&&(e=dt[t+"Fn"](e,ft)),i[dt[t+"Key"]]=e;dt.addParent&&(i[dt.parentKey]=ft),ft[dt.elementsKey].push(i)}}function wt(t){var e,r;if("attributesFn"in dt&&(t=t&&dt.attributesFn(t,ft)),(dt.trim||"attributeValueFn"in dt||"attributeNameFn"in dt||dt.nativeTypeAttributes)&&t)for(e in t)t.hasOwnProperty(e)&&(dt.trim&&(t[e]=t[e].trim()),dt.nativeTypeAttributes&&(t[e]=_t(t[e])),"attributeValueFn"in dt&&(t[e]=dt.attributeValueFn(t[e],e,ft)),"attributeNameFn"in dt)&&(r=t[e],delete t[e],t[dt.attributeNameFn(e,t[e],ft)]=r);return t}function xt(t){var e,r={};if(t.body&&("xml"===t.name.toLowerCase()||dt.instructionHasAttributes)){for(var n,i=/([\w:-]+)\s*=\s*(?:"([^"]*)"|'([^']*)'|(\w+))\s*/g;null!==(n=i.exec(t.body));)r[n[1]]=n[2]||n[3]||n[4];r=wt(r)}"xml"===t.name.toLowerCase()?dt.ignoreDeclaration||(ft[dt.declarationKey]={},Object.keys(r).length&&(ft[dt.declarationKey][dt.attributesKey]=r),dt.addParent&&(ft[dt.declarationKey][dt.parentKey]=ft)):dt.ignoreInstruction||(dt.trim&&(t.body=t.body.trim()),e={},dt.instructionHasAttributes&&Object.keys(r).length?(e[t.name]={},e[t.name][dt.attributesKey]=r):e[t.name]=t.body,bt("instruction",e))}function Et(t,e){if("object"==typeof t&&(e=t.attributes,t=t.name),e=wt(e),"elementNameFn"in dt&&(t=dt.elementNameFn(t,ft)),dt.compact){var r,n={};if(!dt.ignoreAttributes&&e&&Object.keys(e).length)for(r in n[dt.attributesKey]={},e)e.hasOwnProperty(r)&&(n[dt.attributesKey][r]=e[r]);t in ft||(vt(dt.alwaysArray)?-1===dt.alwaysArray.indexOf(t):!dt.alwaysArray)||(ft[t]=[]),ft[t]&&!vt(ft[t])&&(ft[t]=[ft[t]]),vt(ft[t])?ft[t].push(n):ft[t]=n}else ft[dt.elementsKey]||(ft[dt.elementsKey]=[]),(n={})[dt.typeKey]="element",n[dt.nameKey]=t,!dt.ignoreAttributes&&e&&Object.keys(e).length&&(n[dt.attributesKey]=e),dt.alwaysChildren&&(n[dt.elementsKey]=[]),ft[dt.elementsKey].push(n);n[dt.parentKey]=ft,ft=n}function St(t){dt.ignoreText||(t.trim()||dt.captureSpacesBetweenElements)&&(dt.trim&&(t=t.trim()),dt.nativeType&&(t=_t(t)),bt("text",t=dt.sanitize?t.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;"):t))}function At(t){dt.ignoreComment||bt("comment",t=dt.trim?t.trim():t)}function Pt(t){var e=ft[dt.parentKey];dt.addParent||delete ft[dt.parentKey],ft=e}function Tt(t){dt.ignoreCdata||bt("cdata",t=dt.trim?t.trim():t)}function Ct(t){dt.ignoreDoctype||(t=t.replace(/^ /,""),bt("doctype",t=dt.trim?t.trim():t))}function Mt(t){t.note=t}function Ot(t,e){var r=gt.parser(!0,{}),n={};return ft=n,dt=yt.copyOptions(e),yt.ensureFlagExists("ignoreDeclaration",dt),yt.ensureFlagExists("ignoreInstruction",dt),yt.ensureFlagExists("ignoreAttributes",dt),yt.ensureFlagExists("ignoreText",dt),yt.ensureFlagExists("ignoreComment",dt),yt.ensureFlagExists("ignoreCdata",dt),yt.ensureFlagExists("ignoreDoctype",dt),yt.ensureFlagExists("compact",dt),yt.ensureFlagExists("alwaysChildren",dt),yt.ensureFlagExists("addParent",dt),yt.ensureFlagExists("trim",dt),yt.ensureFlagExists("nativeType",dt),yt.ensureFlagExists("nativeTypeAttributes",dt),yt.ensureFlagExists("sanitize",dt),yt.ensureFlagExists("instructionHasAttributes",dt),yt.ensureFlagExists("captureSpacesBetweenElements",dt),yt.ensureAlwaysArrayExists(dt),yt.ensureKeyExists("declaration",dt),yt.ensureKeyExists("instruction",dt),yt.ensureKeyExists("attributes",dt),yt.ensureKeyExists("text",dt),yt.ensureKeyExists("comment",dt),yt.ensureKeyExists("cdata",dt),yt.ensureKeyExists("doctype",dt),yt.ensureKeyExists("type",dt),yt.ensureKeyExists("name",dt),yt.ensureKeyExists("elements",dt),yt.ensureKeyExists("parent",dt),yt.checkFnExists("doctype",dt),yt.checkFnExists("instruction",dt),yt.checkFnExists("cdata",dt),yt.checkFnExists("comment",dt),yt.checkFnExists("text",dt),yt.checkFnExists("instructionName",dt),yt.checkFnExists("elementName",dt),yt.checkFnExists("attributeName",dt),yt.checkFnExists("attributeValue",dt),yt.checkFnExists("attributes",dt),r.opt={strictEntities:!0},r.onopentag=Et,r.ontext=St,r.oncomment=At,r.onclosetag=Pt,r.onerror=Mt,r.oncdata=Tt,r.ondoctype=Ct,r.onprocessinginstruction=xt,r.write(t).close(),n[dt.elementsKey]&&(e=n[dt.elementsKey],delete n[dt.elementsKey],n[dt.elementsKey]=e,delete n.text),n}var Rt,Dt,It=mt,kt=Ot,Lt=mt,Ft=g;function jt(t,e,r){return(!r&&t.spaces?"\n":"")+Array(e+1).join(t.spaces)}function Nt(t,e,r){if(e.ignoreAttributes)return"";var n,i,s,o,a=[];for(n in t="attributesFn"in e?e.attributesFn(t,Dt,Rt):t)t.hasOwnProperty(n)&&null!==t[n]&&void 0!==t[n]&&(o=e.noQuotesForNativeAttributes&&"string"!=typeof t[n]?"":'"',i=(i=""+t[n]).replace(/"/g,"&quot;"),s="attributeNameFn"in e?e.attributeNameFn(n,i,Dt,Rt):n,a.push(e.spaces&&e.indentAttributes?jt(e,r+1,!1):" "),a.push(s+"="+o+("attributeValueFn"in e?e.attributeValueFn(i,n,Dt,Rt):i)+o));return t&&Object.keys(t).length&&e.spaces&&e.indentAttributes&&a.push(jt(e,r,!1)),a.join("")}function Gt(t,e,r){return Rt=t,Dt="xml",e.ignoreDeclaration?"":"<?xml"+Nt(t[e.attributesKey],e,r)+"?>"}function $t(t,e,r){if(e.ignoreInstruction)return"";for(var n in t)if(t.hasOwnProperty(n))break;var i="instructionNameFn"in e?e.instructionNameFn(n,t[n],Dt,Rt):n;return"object"==typeof t[n]?"<?"+(Dt=i)+Nt((Rt=t)[n][e.attributesKey],e,r)+"?>":(r=t[n]||"","<?"+i+((r="instructionFn"in e?e.instructionFn(r,n,Dt,Rt):r)?" "+r:"")+"?>")}function zt(t,e){return e.ignoreComment?"":"\x3c!--"+("commentFn"in e?e.commentFn(t,Dt,Rt):t)+"--\x3e"}function Ut(t,e){return e.ignoreCdata?"":"<![CDATA["+("cdataFn"in e?e.cdataFn(t,Dt,Rt):t.replace("]]>","]]]]><![CDATA[>"))+"]]>"}function Bt(t,e){return e.ignoreDoctype?"":"<!DOCTYPE "+("doctypeFn"in e?e.doctypeFn(t,Dt,Rt):t)+">"}function Vt(t,e){return e.ignoreText?"":(t=(t=(t=""+t).replace(/&amp;/g,"&")).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;"),"textFn"in e?e.textFn(t,Dt,Rt):t)}function qt(t,e,r,n){return t.reduce((function(t,i){var s=jt(e,r,n&&!t);switch(i.type){case"element":return t+s+function(t,e,r){Dt=(Rt=t).name;var n=[],i="elementNameFn"in e?e.elementNameFn(t.name,t):t.name,s=(n.push("<"+i),t[e.attributesKey]&&n.push(Nt(t[e.attributesKey],e,r)),t[e.elementsKey]&&t[e.elementsKey].length||t[e.attributesKey]&&"preserve"===t[e.attributesKey]["xml:space"]);return(s=s||("fullTagEmptyElementFn"in e?e.fullTagEmptyElementFn(t.name,t):e.fullTagEmptyElement))?(n.push(">"),t[e.elementsKey]&&t[e.elementsKey].length&&(n.push(qt(t[e.elementsKey],e,r+1)),Dt=(Rt=t).name),n.push(e.spaces&&function(t,e){var r;if(t.elements&&t.elements.length)for(r=0;r<t.elements.length;++r)switch(t.elements[r][e.typeKey]){case"text":if(e.indentText)return 1;break;case"cdata":if(e.indentCdata)return 1;break;case"instruction":if(e.indentInstruction)return 1;break;default:return 1}}(t,e)?"\n"+Array(r+1).join(e.spaces):""),n.push("</"+i+">")):n.push("/>"),n.join("")}(i,e,r);case"comment":return t+s+zt(i[e.commentKey],e);case"doctype":return t+s+Bt(i[e.doctypeKey],e);case"cdata":return t+(e.indentCdata?s:"")+Ut(i[e.cdataKey],e);case"text":return t+(e.indentText?s:"")+Vt(i[e.textKey],e);case"instruction":var o={};return o[i[e.nameKey]]=i[e.attributesKey]?i:i[e.instructionKey],t+(e.indentInstruction?s:"")+$t(o,e,r)}}),"")}function Kt(t,e,r){for(var n in t)if(t.hasOwnProperty(n))switch(n){case e.parentKey:case e.attributesKey:break;case e.textKey:if(e.indentText||r)return!0;break;case e.cdataKey:if(e.indentCdata||r)return!0;break;case e.instructionKey:if(e.indentInstruction||r)return!0;break;case e.doctypeKey:case e.commentKey:default:return!0}return!1}function Wt(t,e,r,n){var i,s,o,a=[];for(s in t)if(t.hasOwnProperty(s))for(o=Ft(t[s])?t[s]:[t[s]],i=0;i<o.length;++i){switch(s){case e.declarationKey:a.push(Gt(o[i],e,r));break;case e.instructionKey:a.push((e.indentInstruction?jt(e,r,n):"")+$t(o[i],e,r));break;case e.attributesKey:case e.parentKey:break;case e.textKey:a.push((e.indentText?jt(e,r,n):"")+Vt(o[i],e));break;case e.cdataKey:a.push((e.indentCdata?jt(e,r,n):"")+Ut(o[i],e));break;case e.doctypeKey:a.push(jt(e,r,n)+Bt(o[i],e));break;case e.commentKey:a.push(jt(e,r,n)+zt(o[i],e));break;default:a.push(jt(e,r,n)+function(t,e,r,n,i){Rt=t,Dt=e;var s="elementNameFn"in r?r.elementNameFn(e,t):e;if(null==t||""===t)return"fullTagEmptyElementFn"in r&&r.fullTagEmptyElementFn(e,t)||r.fullTagEmptyElement?"<"+s+"></"+s+">":"<"+s+"/>";var o=[];if(e){if(o.push("<"+s),"object"!=typeof t)return o.push(">"+Vt(t,r)+"</"+s+">"),o.join("");t[r.attributesKey]&&o.push(Nt(t[r.attributesKey],r,n));var a=Kt(t,r,!0)||t[r.attributesKey]&&"preserve"===t[r.attributesKey]["xml:space"];if(!(a=a||("fullTagEmptyElementFn"in r?r.fullTagEmptyElementFn(e,t):r.fullTagEmptyElement)))return o.push("/>"),o.join("");o.push(">")}return o.push(Wt(t,r,n+1,!1)),Rt=t,(Dt=e)&&o.push((i?jt(r,n,!1):"")+"</"+s+">"),o.join("")}(o[i],s,e,r,Kt(o[i],e)))}n=n&&!a.length}return a.join("")}function Ht(t,e){r=e,r=Lt.copyOptions(r),Lt.ensureFlagExists("ignoreDeclaration",r),Lt.ensureFlagExists("ignoreInstruction",r),Lt.ensureFlagExists("ignoreAttributes",r),Lt.ensureFlagExists("ignoreText",r),Lt.ensureFlagExists("ignoreComment",r),Lt.ensureFlagExists("ignoreCdata",r),Lt.ensureFlagExists("ignoreDoctype",r),Lt.ensureFlagExists("compact",r),Lt.ensureFlagExists("indentText",r),Lt.ensureFlagExists("indentCdata",r),Lt.ensureFlagExists("indentAttributes",r),Lt.ensureFlagExists("indentInstruction",r),Lt.ensureFlagExists("fullTagEmptyElement",r),Lt.ensureFlagExists("noQuotesForNativeAttributes",r),Lt.ensureSpacesExists(r),"number"==typeof r.spaces&&(r.spaces=Array(r.spaces+1).join(" ")),Lt.ensureKeyExists("declaration",r),Lt.ensureKeyExists("instruction",r),Lt.ensureKeyExists("attributes",r),Lt.ensureKeyExists("text",r),Lt.ensureKeyExists("comment",r),Lt.ensureKeyExists("cdata",r),Lt.ensureKeyExists("doctype",r),Lt.ensureKeyExists("type",r),Lt.ensureKeyExists("name",r),Lt.ensureKeyExists("elements",r),Lt.checkFnExists("doctype",r),Lt.checkFnExists("instruction",r),Lt.checkFnExists("cdata",r),Lt.checkFnExists("comment",r),Lt.checkFnExists("text",r),Lt.checkFnExists("instructionName",r),Lt.checkFnExists("elementName",r),Lt.checkFnExists("attributeName",r),Lt.checkFnExists("attributeValue",r),Lt.checkFnExists("attributes",r),Lt.checkFnExists("fullTagEmptyElement",r);var r,n=[];return Rt=t,Dt="_root_",(e=r).compact?n.push(Wt(t,e,0,!0)):(t[e.declarationKey]&&n.push(Gt(t[e.declarationKey],e,0)),t[e.elementsKey]&&t[e.elementsKey].length&&n.push(qt(t[e.elementsKey],e,0,!n.length))),n.join("")}var Yt,Xt=Ht,Zt=h({xml2js:Ot,xml2json:function(t,e){var r;return e=It.copyOptions(e),It.ensureSpacesExists(e),e=kt(t,t=e),r="compact"in t&&t.compact?"_parent":"parent",("addParent"in t&&t.addParent?JSON.stringify(e,(function(t,e){return t===r?"_":e}),t.spaces):JSON.stringify(e,null,t.spaces)).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")},js2xml:Ht,json2xml:function(t,e){var r=null;if("string"==typeof(t=t instanceof Buffer?t.toString():t))try{r=JSON.parse(t)}catch(t){throw new Error("The JSON structure is invalid")}else r=t;return Xt(r,e)}}),Jt={raster:{},vector:{}};function Qt(t){return t&&(t=Zt.xml2js(t)).elements&&0<t.elements.length&&(1!==t.elements.length&&console.warn("invalid xml!"),t.elements[0])&&t.elements[0].elements?t.elements[0].elements.map((function(t){var e=t.attributes;return t.elements&&0<t.elements.length&&(e.options=t.elements.map((function(t){return t.elements[0].text}))),e})):null}function te(t){var e=w.GDALGetFileList(t);if(!e)return[];for(var r=[],n=0;n<100;n+=1){var i=w.Module.HEAP32[e+4*n>>2];if(0===i)break;i=w.Module.UTF8ToString(i),r.push(i)}return r}function ee(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:[];return new Promise((function(r,n){var i=E(["-json"].concat(a(e))),s=i.config,l=(Object.entries(s).forEach((function(t){var e=(t=o(t,2))[0];t=t[1],w.CPLSetConfigOption(e,t)})),s=w.GDALInfoOptionsNew(i.ptr,null),w.GDALInfo(t.pointer,s));w.GDALInfoOptionsFree(s),S(i),3<=w.CPLGetLastErrorNo()?n(x()):r(JSON.parse(l))}))}function re(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:[];return new Promise((function(r,n){var i=E(["-json"].concat(a(e))),s=i.config,l=(Object.entries(s).forEach((function(t){var e=(t=o(t,2))[0];t=t[1],w.CPLSetConfigOption(e,t)})),s=w.GDALVectorInfoOptionsNew(i.ptr,null),w.GDALVectorInfo(t.pointer,s));w.GDALVectorInfoOptionsFree(s),S(i),3<=w.CPLGetLastErrorNo()?n(x()):r(JSON.parse(l))}))}function ne(){!m&&"function"!=typeof importScripts||w.Module.FS.unmount(A)}var ie={ogr2ogr:function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:[],r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;return new Promise((function(n,i){var s=E(e),a=s.config,l=(Object.entries(a).forEach((function(t){var e=(t=o(t,2))[0];t=t[1],w.CPLSetConfigOption(e,t)})),a=w.GDALVectorTranslateOptionsNew(s.ptr,null),w.Module._malloc(4)),c="unknown",u=(0!==(w.Module.setValue(l,t.pointer,"*"),u=e.indexOf("-f")+1)&&(u=e[u],h=Jt.vector[u])&&(c="MapInfo File"===u&&-1!==e.indexOf("FORMAT=MIF")?"mif":h.extension),r||t.path.split(".",1)[0]),h="".concat(P,"/").concat(u,".").concat(c),d=te(l=w.GDALVectorTranslate(h,null,1,l,a,null));w.GDALVectorTranslateOptionsFree(a),S(s),w.GDALClose(l),3<=w.CPLGetLastErrorNo()?i(x()):n({local:h,real:"".concat(T,"/").concat(u,".").concat(c),all:d.map((function(t){return{local:t,real:t.replace("".concat(P,"/"),"".concat(T,"/"))}}))})}))},gdal_translate:function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:[],r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;return new Promise((function(n,i){var s=E(e),a=s.config,l=(Object.entries(a).forEach((function(t){var e=(t=o(t,2))[0];t=t[1],w.CPLSetConfigOption(e,t)})),a=w.GDALTranslateOptionsNew(s.ptr,null),"unknown"),c=(0!==(c=e.indexOf("-of")+1)&&(c=e[c],c=Jt.raster[c])&&(l=c.extension),r||t.path.split(".",1)[0]),u="".concat(P,"/").concat(c,".").concat(l),h=w.GDALTranslate(u,t.pointer,a,null),d=te(h);w.GDALTranslateOptionsFree(a),S(s),w.GDALClose(h),3<=w.CPLGetLastErrorNo()?i(x()):n({local:u,real:"".concat(T,"/").concat(c,".").concat(l),all:d.map((function(t){return{local:t,real:t.replace("".concat(P,"/"),"".concat(T,"/"))}}))})}))},gdal_rasterize:function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:[],r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;return new Promise((function(n,i){var s=E(e),a=s.config,l=(Object.entries(a).forEach((function(t){var e=(t=o(t,2))[0];t=t[1],w.CPLSetConfigOption(e,t)})),a=w.GDALRasterizeOptionsNew(s.ptr,null),"tif"),c=(0!==(c=e.indexOf("-of")+1)&&(c=e[c],c=Jt.raster[c])&&(l=c.extension),r||t.path.split(".",1)[0]),u="".concat(P,"/").concat(c,".").concat(l),h=w.GDALRasterize(u,null,t.pointer,a,null),d=te(h);w.GDALRasterizeOptionsFree(a),S(s),w.GDALClose(h),3<=w.CPLGetLastErrorNo()?i(x()):n({local:u,real:"".concat(T,"/").concat(c,".").concat(l),all:d.map((function(t){return{local:t,real:t.replace("".concat(P,"/"),"".concat(T,"/"))}}))})}))},gdalwarp:function(t){var e=1<arguments.length&&void 0!==arguments[1]?arguments[1]:[],r=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;return new Promise((function(n,i){var s=E(e),a=s.config,l=(Object.entries(a).forEach((function(t){var e=(t=o(t,2))[0];t=t[1],w.CPLSetConfigOption(e,t)})),a=w.GDALWarpAppOptionsNew(s.ptr,null),w.Module._malloc(4)),c="unknown",u=(0!==(w.Module.setValue(l,t.pointer,"*"),u=e.indexOf("-of")+1)&&(u=e[u],u=Jt.raster[u])&&(c=u.extension),r||t.path.split(".",1)[0]),h="".concat(P,"/").concat(u,".").concat(c),d=te(l=w.GDALWarp(h,null,1,l,a,null));w.GDALWarpAppOptionsFree(a),S(s),w.GDALClose(l),3<=w.CPLGetLastErrorNo()?i(x()):n({local:h,real:"".concat(T,"/").concat(u,".").concat(c),all:d.map((function(t){return{local:t,real:t.replace("".concat(P,"/"),"".concat(T,"/"))}}))})}))},gdaltransform:function(t,e){return new Promise((function(r){for(var n=new Float64Array(t.map((function(t){return t[0]}))),i=new Float64Array(t.map((function(t){return t[1]}))),s=new Float64Array(t.map((function(t){return t[2]||0}))),o=w.Module._malloc(n.length*n.BYTES_PER_ELEMENT),a=w.Module._malloc(i.length*i.BYTES_PER_ELEMENT),l=w.Module._malloc(s.length*s.BYTES_PER_ELEMENT),c=(w.Module.HEAPF64.set(n,o/n.BYTES_PER_ELEMENT),w.Module.HEAPF64.set(i,a/i.BYTES_PER_ELEMENT),w.Module.HEAPF64.set(s,l/s.BYTES_PER_ELEMENT),!1),u=!1,h=[],d=0;d<e.length;d+=1)switch(e[d]){case"-s_srs":h.push("SRC_SRS=".concat(e[d+=1]));break;case"-t_srs":h.push("DST_SRS=".concat(e[d+=1]));break;case"-ct":h.push("COORDINATE_OPERATION=".concat(e[d+=1]));break;case"-order":h.push("MAX_GCP_ORDER=".concat(e[d+=1]));break;case"-tps":h.push("METHOD=GCP_TPS");break;case"-rpc":h.push("METHOD=RPC");break;case"-geoloc":h.push("METHOD=GEOLOC_ARRAY");break;case"-i":c=!0;break;case"-to":h.push("".concat(e[d+=1]));break;case"-output_xy":u=!0}for(var f=E(h),p=w.GDALCreateGenImgProjTransformer2(null,null,f.ptr),m=(w.GDALGenImgProjTransform(p,c,t.length,o,a,l,null),[Array.from(w.Module.HEAPF64.subarray(o/n.BYTES_PER_ELEMENT,o/n.BYTES_PER_ELEMENT+n.length)),Array.from(w.Module.HEAPF64.subarray(a/i.BYTES_PER_ELEMENT,a/i.BYTES_PER_ELEMENT+i.length)),Array.from(w.Module.HEAPF64.subarray(l/s.BYTES_PER_ELEMENT,l/s.BYTES_PER_ELEMENT+s.length))]),g=[],y=0;y<m[0].length;y+=1)g.push(u?[m[0][y],m[1][y]]:[m[0][y],m[1][y],m[2][y]]);w.Module._free(o),w.Module._free(a),w.Module._free(l),S(f),w.GDALDestroyGenImgProjTransformer(p),r(g)}))},gdal_location_info:function(t,e){return new Promise((function(r,n){var i=w.OSRNewSpatialReference('GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137,298.257223563]],PRIMEM["Greenwich",0],UNIT["Degree",0.017453292519943295]]'),s=(w.OSRSetAxisMappingStrategy(i,0),w.GDALGetSpatialRef(t.pointer)),o=(i=w.OCTNewCoordinateTransformation(i,s),s=w.CPLAtof(String(e[0])),w.CPLAtof(String(e[1]))),a=w.Module._malloc(8);w.Module.setValue(a,s,"double"),s=w.Module._malloc(8),w.Module.setValue(s,o,"double"),w.OCTTransform(i,1,s,a,null)||n(new Error("Failed to perform OCTTransform")),o=w.Module.getValue(s,"double"),i=w.Module.getValue(a,"double"),s=w.Module._malloc(6*Float64Array.BYTES_PER_ELEMENT),w.GDALGetGeoTransform(t.pointer,s),a=w.Module._malloc(6*Float64Array.BYTES_PER_ELEMENT),w.GDALInvGeoTransform(s,a)||n(new Error("Failed to invert transform")),s=w.Module.HEAPF64.subarray(a/Float64Array.BYTES_PER_ELEMENT,a/Float64Array.BYTES_PER_ELEMENT+6),r({pixel:Math.floor(s[0]+s[1]*o+s[2]*i),line:Math.floor(s[3]+s[4]*o+s[5]*i)})}))},gdalinfo:ee,ogrinfo:re,open:function(t){var e=2<arguments.length&&void 0!==arguments[2]?arguments[2]:[],r=t,n=E(1<arguments.length&&void 0!==arguments[1]?arguments[1]:[]);return Array.isArray(r)||"function"==typeof FileList&&r instanceof FileList||(r=[r]),new Promise((function(t,i){var s,o=[],l=[];a(r).forEach((function(t){!("string"==typeof t||t instanceof String)||t.substring(0,7)!=="".concat(A,"/")&&t.substring(0,8)!=="".concat(P,"/")?l.push(t):o.push({name:t.substring(t.indexOf("/",1)+1),internal:!0,prefix:t.substring(0,t.indexOf("/",1))})})),s=l,new Promise((function(t){var e,r;0===s.length?t([]):m?(e=[],s.forEach((function(t){var r=(t=t.split("/")).pop();t=t.join("/")||".",Yt!==t&&(Yt&&ne(),Yt=t,w.Module.FS.mount(w.Module.NODEFS,{root:t},A)),e.push({name:r})})),t(e)):"function"==typeof importScripts?(Yt&&ne(),w.Module.FS.mount(w.Module.WORKERFS,{files:s},A),Yt=!0,t(s)):(r=[],s.forEach((function(t){r.push(t.arrayBuffer())})),Promise.all(r).then((function(e){e.forEach((function(t,e){t=new Uint8Array(t),w.Module.FS.writeFile("".concat(A,"/").concat(s[e].name),t)})),t(s)})))})).then((function(r){for(var s=[].concat(a(r),o),l=[],c=(w.CPLErrorReset(),{}),u=[],h=function(){var t=s[d].name,r=t.split(".",1)[0];if(c[r]||(c[r]={}),c[r].pointer)return 0;c[r].path=t;var i=e&&e.length?"/".concat(e.join("/"),"/"):"",o="".concat(i).concat(A,"/").concat(t),a=(s[d].internal&&(o="".concat(i).concat(s[d].prefix,"/").concat(t)),w.GDALOpenEx(o,null,null,n.ptr,null));if(0===a)return i=x(),l.push(i),delete c[r],0;function h(){var t=w.GDALGetRasterCount(a),e=w.GDALDatasetGetLayerCount(a);c[r].type=0<t&&0===e?"raster":"vector"}c[r].pointer=a,t=ee(c[r]).then((function(t){if(t&&t.bands){var e=t.size&&2<=t.size.length&&(0<t.size[0]||0<t.size[1]);if(c[r].type=0<t.bands.length&&e?"raster":"vector","vector"===c[r].type)return re(c[r]).then((function(t){c[r].info=t}));c[r].info=t}else h();return!0})).catch(h),u.push(t)},d=0;d<s.length;d+=1)h();S(n),Promise.allSettled(u).then((function(){var e=Object.values(c);0<e.length||0===l.length?t({datasets:e,errors:l}):i(l)}))}))}))},close:function(t){return new Promise((function(e){w.GDALClose(t.pointer),e()}))},getInfo:function(t){return new Promise((function(e){var r=w.GDALGetRasterCount(t.pointer),n=w.GDALDatasetGetLayerCount(t.pointer);if(0<r&&0===n){var i=w.GDALGetRasterXSize(t.pointer),s=w.GDALGetRasterYSize(t.pointer),o=w.GDALGetProjectionRef(t.pointer),a=w.Module._malloc(6*Float64Array.BYTES_PER_ELEMENT),l=(w.GDALGetGeoTransform(t.pointer,a),w.Module.HEAPF64.subarray(a/Float64Array.BYTES_PER_ELEMENT,a/Float64Array.BYTES_PER_ELEMENT+6)),c=(a=[[0,0],[i,0],[i,s],[0,s]].map((function(t){var e=t[0];return t=t[1],[l[0]+l[1]*e+l[2]*t,l[3]+l[4]*e+l[5]*t]})),w.GDALGetDatasetDriver(t.pointer)),u=(c=w.GDALGetDriverLongName(c),w.OGR_DS_GetName(t.pointer));e(JSON.parse(JSON.stringify({type:"raster",bandCount:r,width:i,height:s,projectionWkt:o,coordinateTransform:l,corners:a,driverName:c,dsName:u})))}else{for(var h=[],d=0;d<n;d+=1){var f=w.OGR_DS_GetLayer(t.pointer,d),p=w.OGR_L_GetName(f);f=w.OGR_L_GetFeatureCount(f,1),h.push({name:p,featureCount:f})}r=h.reduce((function(t,e){return t+e.featureCount}),0),i=w.OGR_DS_GetName(t.pointer),s=w.GDALGetDatasetDriver(t.pointer),e({type:"vector",layerCount:n,featureCount:r,layers:h,dsName:i,driverName:w.GDALGetDriverLongName(s)})}}))},getOutputFiles:function(){return new Promise((function(t){t(function t(e){var r=0<arguments.length&&void 0!==e?e:P.substr(1),n=r.split("/").reduce((function(t,e){return t.contents[e]}),w.Module.FS.root).contents,i=[];return Object.keys(n).forEach((function(e){var s=n[e];s.usedBytes?i.push({path:"/".concat(r,"/").concat(e),size:s.usedBytes}):s.contents&&i.push.apply(i,a(t("".concat(r,"/").concat(e))))})),i}())}))},getFileBytes:function(t){return new Promise((function(e){var r;t?(r=t.local||t,e(w.Module.FS.readFile(r,{encoding:"binary"}))):e(new Uint8Array)}))},drivers:Jt,Module:w.Module};var se,oe={gdalWorkerWrapper:null,drivers:null},ae=(_=function(){function t(e,r,n){var i=this;if(!(this instanceof t))throw new TypeError("Cannot call a class as a function");this.promises={onload:{resolve:n,reject:console.error}},this.gdalWorker=new Worker(e),this.gdalWorker.onmessage=function(t){t.data&&t.data.id&&i.promises[t.data.id]&&(t.data.success?i.promises[t.data.id].resolve(t.data.data):i.promises[t.data.id].reject(t.data.data))},this.gdalWorker.postMessage({func:"constructor",params:{config:r}})}var e,r;return e=t,(r=[{key:"call",value:function(t){var e=this;return new Promise((function(r,n){t.id=Math.floor(1e5*Math.random()),e.promises[t.id]={resolve:r,reject:n},e.gdalWorker.postMessage(t)}))}},{key:"terminate",value:function(){this.gdalWorker.terminate(),delete this.gdalWorker,delete this.promises}}])&&s(e.prototype,r),Object.defineProperty(e,"prototype",{writable:!1}),t}(),mt=new Proxy({},{get:function(t,e){return"then"===e||"catch"===e?t:"drivers"===e?oe.drivers:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return new Promise((function(t,n){oe.gdalWorkerWrapper.call({func:e,params:r}).then((function(e){t(e)})).catch((function(t){return n(t)}))}))}}}),{variables:oe,WorkerWrapper:_,gdalProxy:mt});function le(){var t,r,n=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{};return se=se||(m||!1===n.useWorker?new Promise((function(t,r){var i=w.Module,s=i.onAbort;i.onAbort=function(t){r(new Error(t)),s&&s(t)},i.print=function(t){n.logHandler?n.logHandler(t,"stdout"):console.debug("gdal stdout: ".concat(t))},i.printErr=function(t){n.errorHandler?n.errorHandler(t,"stderr"):console.error("gdal stderr: ".concat(t))},i.preRun=[function(t){var e=t.ENV;e.PROJ_LIB="/usr/share/proj",e.GDAL_DATA="/usr/share/gdal",e.DXF_FEATURE_LIMIT_PER_BLOCK="-1",e.GDAL_NUM_THREADS="0",e.GDAL_ENABLE_DEPRECATED_DRIVER_GTM="YES",e.CPL_LOG_ERRORS="ON",n.env&&Object.entries(n.env).forEach((function(t){var r=(t=o(t,2))[0];t=t[1],e[r]=t}))}],i.onRuntimeInitialized=function(){var t,r;w.GDALOpen||((r=w.Module).ccall("GDALAllRegister",null,[],[]),w.GDALOpen=r.cwrap("GDALOpen","number",["string"]),w.GDALOpenEx=r.cwrap("GDALOpenEx","number",["string","number","number","number","number"]),w.GDALClose=r.cwrap("GDALClose",null,["number"]),w.CPLErrorReset=r.cwrap("CPLErrorReset",null,[]),w.CPLSetErrorHandler=r.cwrap("CPLSetErrorHandler","number",["number"]),w.CPLQuietErrorHandler=r.cwrap("CPLQuietErrorHandler",null,["number","number","string"]),w.CPLGetLastErrorNo=r.cwrap("CPLGetLastErrorNo","number",[]),w.CPLGetLastErrorMsg=r.cwrap("CPLGetLastErrorMsg","string",[]),w.CPLGetLastErrorType=r.cwrap("CPLGetLastErrorType","number",[]),w.CPLSetConfigOption=r.cwrap("CPLSetConfigOption",null,["string","string"]),w.CPLSetThreadLocalConfigOption=r.cwrap("CPLSetThreadLocalConfigOption",null,["string","string"]),w.GDALGetRasterCount=r.cwrap("GDALGetRasterCount","number",["number"]),w.GDALGetRasterXSize=r.cwrap("GDALGetRasterXSize","number",["number"]),w.GDALGetRasterYSize=r.cwrap("GDALGetRasterYSize","number",["number"]),w.GDALGetProjectionRef=r.cwrap("GDALGetProjectionRef","string",["number"]),w.GDALGetGeoTransform=r.cwrap("GDALGetGeoTransform","number",["number","number"]),w.GDALInvGeoTransform=r.cwrap("GDALInvGeoTransform","number",["number","number"]),w.GDALVectorTranslate=r.cwrap("GDALVectorTranslate","number",["string","number","number","number","number","number"]),w.GDALVectorTranslateOptionsNew=r.cwrap("GDALVectorTranslateOptionsNew","number",["number","number"]),w.GDALVectorTranslateOptionsFree=r.cwrap("GDALVectorTranslateOptionsFree","number",["number"]),w.GDALDatasetGetLayerCount=r.cwrap("GDALDatasetGetLayerCount","number",["number"]),w.GDALDatasetGetLayer=r.cwrap("GDALDatasetGetLayer","number",["number","number"]),w.OGR_DS_GetLayerCount=r.cwrap("OGR_DS_GetLayerCount","number",["number"]),w.OGR_DS_GetName=r.cwrap("OGR_DS_GetName","string",["number"]),w.OGR_DS_GetLayer=r.cwrap("OGR_DS_GetLayer","number",["number","number"]),w.OGR_L_GetName=r.cwrap("OGR_L_GetName","string",["number"]),w.OGR_DS_GetDriver=r.cwrap("OGR_DS_GetDriver","number",["number"]),w.OGR_Dr_GetName=r.cwrap("OGR_Dr_GetName","string",["number"]),w.GDALGetDatasetDriver=r.cwrap("GDALGetDatasetDriver","number",["number"]),w.GDALGetDriverLongName=r.cwrap("GDALGetDriverLongName","string",["number"]),w.GDALGetDriverShortName=r.cwrap("GDALGetDriverShortName","string",["number"]),w.GDALTranslate=r.cwrap("GDALTranslate","number",["string","number","number","number"]),w.GDALTranslateOptionsNew=r.cwrap("GDALTranslateOptionsNew","number",["number","number"]),w.GDALTranslateOptionsFree=r.cwrap("GDALTranslateOptionsFree","number",["number"]),w.GDALRasterize=r.cwrap("GDALRasterize","number",["string","number","number","number","number"]),w.GDALRasterizeOptionsNew=r.cwrap("GDALRasterizeOptionsNew","number",["number","number"]),w.GDALRasterizeOptionsFree=r.cwrap("GDALRasterizeOptionsFree","number",["number"]),w.GDALWarp=r.cwrap("GDALWarp","number",["string","number","number","number","number","number"]),w.GDALWarpAppOptionsNew=r.cwrap("GDALWarpAppOptionsNew","number",["number","number"]),w.GDALWarpAppOptionsSetProgress=r.cwrap("GDALWarpAppOptionsSetProgress","number",["number","number","number"]),w.GDALWarpAppOptionsFree=r.cwrap("GDALWarpAppOptionsFree","number",["number"]),w.OSRNewSpatialReference=r.cwrap("OSRNewSpatialReference","number",["string"]),w.OSRDestroySpatialReference=r.cwrap("OSRDestroySpatialReference","number",["number"]),w.OCTNewCoordinateTransformation=r.cwrap("OCTNewCoordinateTransformation","number",["number","number"]),w.OCTDestroyCoordinateTransformation=r.cwrap("OCTDestroyCoordinateTransformation","number",["number"]),w.OCTTransform=r.cwrap("OCTTransform","number",["number","number","number","number","number"]),w.GDALGetDriverCount=r.cwrap("GDALGetDriverCount","number",[]),w.OGRGetDriverCount=r.cwrap("OGRGetDriverCount","number",[]),w.GDALGetDriver=r.cwrap("GDALGetDriver","number",["number"]),w.OGRGetDriver=r.cwrap("OGRGetDriver","number",["number"]),w.GDALGetMetadataItem=r.cwrap("GDALGetMetadataItem","string",["number","string","string"]),w.GDALGetDescription=r.cwrap("GDALGetDescription","string",["number"]),w.OGR_L_GetFeatureCount=r.cwrap("OGR_L_GetFeatureCount","number",["number","number"]),w.GDALGenImgProjTransform=r.cwrap("GDALGenImgProjTransform","number",["number","number","number","number","number","number","number"]),w.GDALCreateGenImgProjTransformer2=r.cwrap("GDALCreateGenImgProjTransformer2","number",["number","number","number"]),w.GDALDestroyGenImgProjTransformer=r.cwrap("GDALDestroyGenImgProjTransformer",null,["number"]),w.OSRSetFromUserInput=r.cwrap("OSRSetFromUserInput","number",["number","string"]),w.OSRExportToWkt=r.cwrap("OSRExportToWkt","number",["number","number"]),w.GDALGetSpatialRef=r.cwrap("GDALGetSpatialRef","number",["number"]),w.CPLAtof=r.cwrap("CPLAtof","number",["string"]),w.OSRSetAxisMappingStrategy=r.cwrap("OSRSetAxisMappingStrategy",null,["number","number"]),w.GDALInfo=r.cwrap("GDALInfo","string",["number","number"]),w.GDALInfoOptionsNew=r.cwrap("GDALInfoOptionsNew","number",["number","number"]),w.GDALInfoOptionsFree=r.cwrap("GDALInfoOptionsFree",null,["number"]),w.GDALVectorInfo=r.cwrap("GDALVectorInfo","string",["number","number"]),w.GDALVectorInfoOptionsNew=r.cwrap("GDALVectorInfoOptionsNew","number",["number","number"]),w.GDALVectorInfoOptionsFree=r.cwrap("GDALVectorInfoOptionsFree",null,["number"]),w.GDALGetFileList=r.cwrap("GDALGetFileList","number",["number"])),i.FS.mkdir(A),i.FS.mkdir(P),n.dest&&(r=n.dest,T=r,t=n.dest,m)&&w.Module.FS.mount(w.Module.NODEFS,{root:t},P),function(){for(var t,r,n=w.GDALGetDriverCount(),i=0;i<n;i+=1){var s=w.GDALGetDriver(i),o=(o=t=void 0,t=w.GDALGetMetadataItem(s,"DMD_EXTENSIONS",null),""!==(o=""===(o=w.GDALGetMetadataItem(s,"DMD_EXTENSION",null))&&""!==t?t.split(" ")[0]:o)&&(o=o.replace(".","").replace("/","")),"GeoJSON"===(r=w.GDALGetDescription(s))&&(o="geojson"),{extension:o,extensions:t,shortName:r,longName:w.GDALGetMetadataItem(s,"DMD_LONGNAME",null),isReadable:"YES"===w.GDALGetMetadataItem(s,"DCAP_OPEN",null),isWritable:"YES"===w.GDALGetMetadataItem(s,"DCAP_CREATE",null)||"YES"===w.GDALGetMetadataItem(s,"DCAP_CREATECOPY",null),isRaster:"YES"===w.GDALGetMetadataItem(s,"DCAP_RASTER",null),isVector:"YES"===w.GDALGetMetadataItem(s,"DCAP_VECTOR",null),openOptionsList:Qt(w.GDALGetMetadataItem(s,"DMD_OPENOPTIONLIST",null)),creationOptionList:Qt(w.GDALGetMetadataItem(s,"DMD_CREATIONOPTIONLIST",null)),layerCreationOptionList:Qt(w.GDALGetMetadataItem(s,"DS_LAYER_CREATIONOPTIONLIST",null)),helpUrl:w.GDALGetMetadataItem(s,"DMD_HELPTOPIC",null)});o.isRaster&&(Jt.raster[o.shortName]=e(e({index:i},o),{},{type:"raster"})),o.isVector&&(Jt.vector[o.shortName]=e(e({index:i},o),{},{type:"vector"}))}}()},i.locateFile=function(t){var e=t;return n.paths&&n.paths.wasm&&"wasm"===t.split(".").pop()?e=n.paths.wasm:n.paths&&n.paths.data&&"data"===t.split(".").pop()&&(e=n.paths.data),t="",n.path?"/"!==(t=n.path).slice(-1)&&(t+="/"):m&&(t="node_modules/gdal3.js/dist/package/"),t+=e,m||"http"===t.substring(0,4)||"/"===t[0]?t:"/".concat(t)},m&&(i.getPreloadedPackage=function(t){return p.readFileSync("./".concat(t),{flag:"r"}).buffer}),b(w.Module).then((function(){t(ie)}))})):(t=n.paths&&n.paths.js||"gdal3.js",r="",n.path&&"/"!==(r=n.path).slice(-1)&&(r+="/"),new Promise((function(e){ae.variables.gdalWorkerWrapper=new ae.WorkerWrapper("".concat(r).concat(t),n,(function(t){ae.variables.drivers=t,e(ae.gdalProxy)}))}))))}return m&&(r.g.location={pathname:"./"}),"undefined"!=typeof window&&(window.initGdalJs=le),"function"==typeof importScripts&&function(t){var r;onmessage=function(n){var i;return n.data&&"constructor"===n.data.func?(i={useWorker:!1},n.data.params&&n.data.params.config&&(i=e(e({},n.data.params.config),i)),(r=t(i)).then((function(t){return t=t.drivers,postMessage({success:!0,id:"onload",data:t})})).catch((function(t){return postMessage({success:!1,id:"onload",data:t})})),null):r.then(function(t){var e=this;this.data&&this.data.func&&t[this.data.func]?t[this.data.func].apply(t,a(this.data.params)).then((function(t){postMessage({success:!0,id:e.data.id,data:t})})).catch((function(t){postMessage({success:!1,id:e.data.id,data:{message:t.message}})})):console.error("undefined function",this.data)}.bind(n)).catch(function(t){postMessage({success:!1,id:this.id,data:{no:-1,message:t.message}})}.bind(n))}}(le),le}()},74244:(t,e,r)=>{"use strict";r.d(e,{$:()=>n,AC:()=>c,Hm:()=>d,NZ:()=>s,S3:()=>h,TZ:()=>u,s$:()=>a,ub:()=>l});const n={315:"Artist",258:"BitsPerSample",265:"CellLength",264:"CellWidth",320:"ColorMap",259:"Compression",33432:"Copyright",306:"DateTime",338:"ExtraSamples",266:"FillOrder",289:"FreeByteCounts",288:"FreeOffsets",291:"GrayResponseCurve",290:"GrayResponseUnit",316:"HostComputer",270:"ImageDescription",257:"ImageLength",256:"ImageWidth",271:"Make",281:"MaxSampleValue",280:"MinSampleValue",272:"Model",254:"NewSubfileType",274:"Orientation",262:"PhotometricInterpretation",284:"PlanarConfiguration",296:"ResolutionUnit",278:"RowsPerStrip",277:"SamplesPerPixel",305:"Software",279:"StripByteCounts",273:"StripOffsets",255:"SubfileType",263:"Threshholding",282:"XResolution",283:"YResolution",326:"BadFaxLines",327:"CleanFaxData",343:"ClipPath",328:"ConsecutiveBadFaxLines",433:"Decode",434:"DefaultImageColor",269:"DocumentName",336:"DotRange",321:"HalftoneHints",346:"Indexed",347:"JPEGTables",285:"PageName",297:"PageNumber",317:"Predictor",319:"PrimaryChromaticities",532:"ReferenceBlackWhite",339:"SampleFormat",340:"SMinSampleValue",341:"SMaxSampleValue",559:"StripRowCounts",330:"SubIFDs",292:"T4Options",293:"T6Options",325:"TileByteCounts",323:"TileLength",324:"TileOffsets",322:"TileWidth",301:"TransferFunction",318:"WhitePoint",344:"XClipPathUnits",286:"XPosition",529:"YCbCrCoefficients",531:"YCbCrPositioning",530:"YCbCrSubSampling",345:"YClipPathUnits",287:"YPosition",37378:"ApertureValue",40961:"ColorSpace",36868:"DateTimeDigitized",36867:"DateTimeOriginal",34665:"Exif IFD",36864:"ExifVersion",33434:"ExposureTime",41728:"FileSource",37385:"Flash",40960:"FlashpixVersion",33437:"FNumber",42016:"ImageUniqueID",37384:"LightSource",37500:"MakerNote",37377:"ShutterSpeedValue",37510:"UserComment",33723:"IPTC",34675:"ICC Profile",700:"XMP",42112:"GDAL_METADATA",42113:"GDAL_NODATA",34377:"Photoshop",33550:"ModelPixelScale",33922:"ModelTiepoint",34264:"ModelTransformation",34735:"GeoKeyDirectory",34736:"GeoDoubleParams",34737:"GeoAsciiParams",50674:"LercParameters"},i={};for(const t in n)n.hasOwnProperty(t)&&(i[n[t]]=parseInt(t,10));const s=[i.BitsPerSample,i.ExtraSamples,i.SampleFormat,i.StripByteCounts,i.StripOffsets,i.StripRowCounts,i.TileByteCounts,i.TileOffsets,i.SubIFDs],o={1:"BYTE",2:"ASCII",3:"SHORT",4:"LONG",5:"RATIONAL",6:"SBYTE",7:"UNDEFINED",8:"SSHORT",9:"SLONG",10:"SRATIONAL",11:"FLOAT",12:"DOUBLE",13:"IFD",16:"LONG8",17:"SLONG8",18:"IFD8"},a={};for(const t in o)o.hasOwnProperty(t)&&(a[o[t]]=parseInt(t,10));const l={WhiteIsZero:0,BlackIsZero:1,RGB:2,Palette:3,TransparencyMask:4,CMYK:5,YCbCr:6,CIELab:8,ICCLab:9},c={Unspecified:0,Assocalpha:1,Unassalpha:2},u={Version:0,AddCompression:1},h={None:0,Deflate:1,Zstandard:2},d={1024:"GTModelTypeGeoKey",1025:"GTRasterTypeGeoKey",1026:"GTCitationGeoKey",2048:"GeographicTypeGeoKey",2049:"GeogCitationGeoKey",2050:"GeogGeodeticDatumGeoKey",2051:"GeogPrimeMeridianGeoKey",2052:"GeogLinearUnitsGeoKey",2053:"GeogLinearUnitSizeGeoKey",2054:"GeogAngularUnitsGeoKey",2055:"GeogAngularUnitSizeGeoKey",2056:"GeogEllipsoidGeoKey",2057:"GeogSemiMajorAxisGeoKey",2058:"GeogSemiMinorAxisGeoKey",2059:"GeogInvFlatteningGeoKey",2060:"GeogAzimuthUnitsGeoKey",2061:"GeogPrimeMeridianLongGeoKey",2062:"GeogTOWGS84GeoKey",3072:"ProjectedCSTypeGeoKey",3073:"PCSCitationGeoKey",3074:"ProjectionGeoKey",3075:"ProjCoordTransGeoKey",3076:"ProjLinearUnitsGeoKey",3077:"ProjLinearUnitSizeGeoKey",3078:"ProjStdParallel1GeoKey",3079:"ProjStdParallel2GeoKey",3080:"ProjNatOriginLongGeoKey",3081:"ProjNatOriginLatGeoKey",3082:"ProjFalseEastingGeoKey",3083:"ProjFalseNorthingGeoKey",3084:"ProjFalseOriginLongGeoKey",3085:"ProjFalseOriginLatGeoKey",3086:"ProjFalseOriginEastingGeoKey",3087:"ProjFalseOriginNorthingGeoKey",3088:"ProjCenterLongGeoKey",3089:"ProjCenterLatGeoKey",3090:"ProjCenterEastingGeoKey",3091:"ProjCenterNorthingGeoKey",3092:"ProjScaleAtNatOriginGeoKey",3093:"ProjScaleAtCenterGeoKey",3094:"ProjAzimuthAngleGeoKey",3095:"ProjStraightVertPoleLongGeoKey",3096:"ProjRectifiedGridAngleGeoKey",4096:"VerticalCSTypeGeoKey",4097:"VerticalCitationGeoKey",4098:"VerticalDatumGeoKey",4099:"VerticalUnitsGeoKey"},f={};for(const t in d)d.hasOwnProperty(t)&&(f[d[t]]=parseInt(t,10))},12651:(t,e,r)=>{var n=r(46343),i=r(40074),s=r(82438),o=r(19106),a=r(32293),l=r(30306),c=r(48360),u=r(22563),h=t=>Array.isArray(t)?t:[t],d=t=>void 0===t,f=t=>c(t)||Array.isArray(t)?Object.keys(t):[],p=(t,e)=>t.hasOwnProperty(e),m=t=>i(s(t)),g=t=>d(t)||Array.isArray(t)&&0===t.length,y=(t,e)=>d(t)&&0===e||d(e)&&0===t||n(t,e),v=t=>d(t)||n(t,{})||!0===t,_=t=>d(t)||n(t,{}),b=t=>d(t)||c(t)||!0===t||!1===t;function w(t,e){return!(!g(t)||!g(e))||n(m(t),m(e))}function x(t,e,r,i){var o=s(f(t).concat(f(e)));return!(!_(t)||!_(e))||(!_(t)||!f(e).length)&&(!_(e)||!f(t).length)&&o.every((function(r){var s=t[r],o=e[r];return Array.isArray(s)&&Array.isArray(o)?n(m(t),m(e)):!(Array.isArray(s)&&!Array.isArray(o))&&!(Array.isArray(o)&&!Array.isArray(s))&&((t,e,r,n)=>e&&p(e,r)&&t&&p(t,r)&&n(t[r],e[r]))(t,e,r,i)}))}function E(t,e,r,n){var i=o(t,n),s=o(e,n);return l(i,s,n).length===Math.max(i.length,s.length)}var S={title:n,uniqueItems:(t,e)=>d(t)&&!1===e||d(e)&&!1===t||n(t,e),minLength:y,minItems:y,minProperties:y,required:w,enum:w,type:function(t,e){return t=h(t),e=h(e),n(m(t),m(e))},items:function(t,e,r,i){return c(t)&&c(e)?i(t,e):Array.isArray(t)&&Array.isArray(e)?x(t,e,0,i):n(t,e)},anyOf:E,allOf:E,oneOf:E,properties:x,patternProperties:x,dependencies:x},A=["properties","patternProperties","dependencies","uniqueItems","minLength","minItems","minProperties","required"],P=["additionalProperties","additionalItems","contains","propertyNames","not"];t.exports=function t(e,r,i){if(i=a(i,{ignore:[]}),v(e)&&v(r))return!0;if(!b(e)||!b(r))throw new Error("Either of the values are not a JSON schema.");if(e===r)return!0;if(u(e)&&u(r))return e===r;if(void 0===e&&!1===r||void 0===r&&!1===e)return!1;if(d(e)&&!d(r)||!d(e)&&d(r))return!1;var o=s(Object.keys(e).concat(Object.keys(r)));if(i.ignore.length&&(o=o.filter((t=>-1===i.ignore.indexOf(t)))),!o.length)return!0;function l(e,r){return t(e,r,i)}return o.every((function(s){var o=e[s],a=r[s];if(-1!==P.indexOf(s))return t(o,a,i);var c=S[s];if(c||(c=n),n(o,a))return!0;if(-1===A.indexOf(s)&&(!p(e,s)&&p(r,s)||p(e,s)&&!p(r,s)))return o===a;var h=c(o,a,s,l);if(!u(h))throw new Error("Comparer must return true or false");return h}))}},587:(t,e,r)=>{var n=r(46108),i=r(12651),s=r(23050),o=r(69383),a=r(75857),l=r(53435),c=r(58150),u=r(30306),h=r(46343),d=r(48360),f=r(70581),p=r(40074),m=r(83657),g=r(82438),y=r(19106),v=r(30795),_=(t,...e)=>v.apply(null,[t].concat(a(e))),b=t=>x(V,t),w=t=>x(q,t),x=(t,e)=>-1!==t.indexOf(e),E=t=>d(t)||!0===t||!1===t,S=t=>!1===t,A=t=>!0===t,P=(t,e,r)=>r(t),T=t=>p(g(l(t))),C=t=>void 0!==t,M=t=>g(l(t.map(F))),O=t=>t[0],R=t=>Math.max.apply(Math,t),D=t=>Math.min.apply(Math,t);function I(t){if(Array.isArray(t.allOf)){var e=t.allOf;return delete t.allOf,[t].concat(e.map((function(t){return I(t)})))}return[t]}function k(t,e){return t.map((function(t){return t&&t[e]}))}function L(t,e){return t.map((function(t){if(t){if(!Array.isArray(t.items))return t.items;var r=t.items[e];return E(r)?r:t.hasOwnProperty("additionalItems")?t.additionalItems:void 0}}))}function F(t){return d(t)||Array.isArray(t)?Object.keys(t):[]}function j(t,e){if(e=e||[],!t.length)return e;var r=t.slice(0).shift(),n=t.slice(1);return e.length?j(n,a(e.map((t=>r.map((e=>[e].concat(t))))))):j(n,r.map((t=>t)))}function N(t,e){var r;try{r=t.map((function(t){return JSON.stringify(t,null,2)})).join("\n")}catch(e){r=t.join(", ")}throw new Error('Could not resolve values for path:"'+e.join(".")+'". They are probably incompatible. Values: \n'+r)}function G(t){for(var e in t)t.hasOwnProperty(e)&&!F(r=t[e]).length&&!1!==r&&!0!==r&&delete t[e];var r;return t}function $(t,e,r){return function(n,i){if(void 0===i)throw new Error("You need to call merger with a key for the property name or index if array.");return i=String(i),t(n,null,r.concat(e,i))}}function z(t,e,r,n,s,o){if(t.length){var a=s.resolvers[e];if(!a)throw new Error("No resolver found for "+e);var l=y(r.map((function(e){return t.reduce((function(t,r){return void 0!==e[r]&&(t[r]=e[r]),t}),{})})).filter(C),i),c=("properties"===e?V:q).reduce((function(t,e){return x(K,e)?t[e]=$(n,e,o):t[e]=function(t){return n(t,null,o.concat(e))},t}),{});"items"===e&&(c.itemsArray=$(n,"items",o),c.items=function(t){return n(t,null,o.concat("items"))});var u=a(l,o.concat(e),c,s);return d(u)||N(l,o.concat(e)),G(u)}}function U(t,e,r){var n=M(r||t),s=r?L:k;return n.reduce((function(r,n){var o=s(t,n),a=y(o.filter(C),i);return r[n]=e(a,n),r}),r?[]:{})}function B(t){return{required:t}}var V=["properties","patternProperties","additionalProperties"],q=["items","additionalItems"],K=["properties","patternProperties","definitions","dependencies"],W=["anyOf","oneOf"],H=["additionalProperties","additionalItems","contains","propertyNames","not","items"],Y={type(t){if(t.some(Array.isArray)){var e=t.map((function(t){return Array.isArray(t)?t:[t]})),r=c.apply(null,e);if(1===r.length)return r[0];if(r.length>1)return g(r)}},properties(t,e,r,n){n.ignoreAdditionalProperties||(t.forEach((function(e){var n=t.filter((t=>t!==e)),i=F(e.properties),s=F(e.patternProperties).map((t=>new RegExp(t)));n.forEach((function(t){var n=F(t.properties),o=n.filter((t=>s.some((e=>e.test(t)))));_(n,i,o).forEach((function(n){t.properties[n]=r.properties([t.properties[n],e.additionalProperties],n)}))}))})),t.forEach((function(e){var r=t.filter((t=>t!==e)),n=F(e.patternProperties);!1===e.additionalProperties&&r.forEach((function(t){var e=F(t.patternProperties);_(e,n).forEach((e=>delete t.patternProperties[e]))}))})));var i,s={additionalProperties:r.additionalProperties(t.map((t=>t.additionalProperties))),patternProperties:U(t.map((t=>t.patternProperties)),r.patternProperties),properties:U(t.map((t=>t.properties)),r.properties)};return!1===s.additionalProperties&&m(i=s.properties,(function(t,e){!1===t&&delete i[e]})),s},dependencies:(t,e,r)=>M(t).reduce((function(e,n){var s=k(t,n),o=y(s.filter(C),h),a=o.filter(Array.isArray);if(a.length){if(a.length===o.length)e[n]=T(o);else{var l=o.filter(E),c=a.map(B);e[n]=r(l.concat(c),n)}return e}return o=y(o,i),e[n]=r(o,n),e}),{}),items(t,e,r){var n,i,s=t.map((t=>t.items)),o=s.filter(C),a={};return o.every(E)?a.items=r.items(s):a.items=U(t,r.itemsArray,s),o.every(Array.isArray)?n=t.map((t=>t.additionalItems)):o.some(Array.isArray)&&(n=t.map((function(t){if(t)return Array.isArray(t.items)?t.additionalItems:t.items}))),n&&(a.additionalItems=r.additionalItems(n)),!1===a.additionalItems&&Array.isArray(a.items)&&(i=a.items,m(i,(function(t,e){!1===t&&i.splice(e,1)}))),a},oneOf(t,e,r){var s=function(t,e){return t.map((function(t,r){try{return e(t,r)}catch(t){return}})).filter(C)}(j(n(t)),r),o=y(s,i);if(o.length)return o},not:t=>({anyOf:t}),pattern(t,e,r,n,i){var s=e.pop();i(t.map((function(t){return{[s]:t}})))},multipleOf(t){for(var e=t.slice(0),r=1;e.some((t=>!Number.isInteger(t)));)e=e.map((t=>10*t)),r*=10;return s(e)/r},enum(t){var e=u.apply(null,t.concat(h));if(e.length)return p(e)}};function X(t,e,r){return r=r||[],e=o(e,{ignoreAdditionalProperties:!1,resolvers:Y}),function t(s,o,a){s=n(s.filter(C)),a=a||[];var l=d(o)?o:{};if(s.length){if(s.some(S))return!1;if(s.every(A))return!0;s=s.filter(d);var c=M(s);if(x(c,"allOf"))return X({allOf:s},e,r);var u=c.filter(b);f(c,u);var h=c.filter(w);return f(c,h),c.forEach((function(r){var n=k(s,r),o=y(n.filter(C),function(t){return function(e,r){return i({[t]:e},{[t]:r})}}(r));if(1===o.length&&x(W,r))l[r]=o[0].map((function(e){return t([e],e)}));else if(1!==o.length||x(K,r)||x(H,r)){var c,u=e.resolvers[r]||e.resolvers.defaultResolver;if(!u)throw new Error("No resolver found for key "+r+". You can provide a resolver for this keyword in the options, or provide a default resolver.");c=x(K,r)||x(W,r)?$(t,r,a):function(e){return t(e,null,a.concat(r))};var h=!1;l[r]=u(o,a.concat(r),c,e,(function(t){return h=Array.isArray(t),function(t){l.allOf=function(t,e){return Array.isArray(t)?(t.splice.apply(t,[0,0].concat(e)),t):e}(l.allOf,t)}(t)})),void 0!==l[r]||h?void 0===l[r]&&delete l[r]:N(o,a.concat(r))}else l[r]=o[0]})),Object.assign(l,z(u,"properties",s,t,e,a)),Object.assign(l,z(h,"items",s,t,e,a)),l}}(l(I(t)),t)}Y.$id=O,Y.$ref=O,Y.$schema=O,Y.additionalItems=P,Y.additionalProperties=P,Y.anyOf=Y.oneOf,Y.contains=P,Y.default=O,Y.definitions=Y.dependencies,Y.description=O,Y.examples=t=>y(a(t),h),Y.exclusiveMaximum=D,Y.exclusiveMinimum=R,Y.maximum=D,Y.maxItems=D,Y.maxLength=D,Y.maxProperties=D,Y.minimum=R,Y.minItems=R,Y.minLength=R,Y.minProperties=R,Y.propertyNames=P,Y.required=t=>T(t),Y.title=O,Y.uniqueItems=t=>t.some(A),X.options={resolvers:Y},t.exports=X},45838:(t,e)=>{var r=/~/,n=/~[01]/g;function i(t){switch(t){case"~1":return"/";case"~0":return"~"}throw new Error("Invalid tilde escape: "+t)}function s(t){return r.test(t)?t.replace(n,i):t}function o(t){if("string"==typeof t){if(""===(t=t.split("/"))[0])return t;throw new Error("Invalid JSON pointer.")}if(Array.isArray(t)){for(const e of t)if("string"!=typeof e&&"number"!=typeof e)throw new Error("Invalid JSON pointer. Must be of type string or number.");return t}throw new Error("Invalid JSON pointer.")}function a(t,e){if("object"!=typeof t)throw new Error("Invalid input object.");var r=(e=o(e)).length;if(1===r)return t;for(var n=1;n<r;){if(t=t[s(e[n++])],r===n)return t;if("object"!=typeof t||null===t)return}}function l(t,e,r){if("object"!=typeof t)throw new Error("Invalid input object.");if(0===(e=o(e)).length)throw new Error("Invalid JSON pointer for set.");return function(t,e,r){for(var n,i,o=1,a=e.length;o<a;){if("constructor"===e[o]||"prototype"===e[o]||"__proto__"===e[o])return t;if(n=s(e[o++]),i=a>o,void 0===t[n]&&(Array.isArray(t)&&"-"===n&&(n=t.length),i&&(""!==e[o]&&e[o]<1/0||"-"===e[o]?t[n]=[]:t[n]={})),!i)break;t=t[n]}var l=t[n];return void 0===r?delete t[n]:t[n]=r,l}(t,e,r)}e.get=a,e.set=l,e.compile=function(t){var e=o(t);return{get:function(t){return a(t,e)},set:function(t,r){return l(t,e,r)}}}},29452:(t,e,r)=>{var n,i=/[&<>"'`]/g,s=RegExp(i.source),o="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g,a="object"==typeof self&&self&&self.Object===Object&&self,l=o||a||Function("return this")(),c=(n={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","`":"&#96;"},function(t){return null==n?void 0:n[t]}),u=Object.prototype.toString,h=l.Symbol,d=h?h.prototype:void 0,f=d?d.toString:void 0;t.exports=function(t){var e;return(t=null==(e=t)?"":function(t){if("string"==typeof t)return t;if(function(t){return"symbol"==typeof t||function(t){return!!t&&"object"==typeof t}(t)&&"[object Symbol]"==u.call(t)}(t))return f?f.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}(e))&&s.test(t)?t.replace(i,c):t}},33103:(t,e,r)=>{var n=r(94715)(r(78942),"DataView");t.exports=n},25098:(t,e,r)=>{var n=r(23305),i=r(39361),s=r(11112),o=r(25276),a=r(57452);function l(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}l.prototype.clear=n,l.prototype.delete=i,l.prototype.get=s,l.prototype.has=o,l.prototype.set=a,t.exports=l},1386:(t,e,r)=>{var n=r(12393),i=r(62049),s=r(7144),o=r(7452),a=r(13964);function l(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}l.prototype.clear=n,l.prototype.delete=i,l.prototype.get=s,l.prototype.has=o,l.prototype.set=a,t.exports=l},19770:(t,e,r)=>{var n=r(94715)(r(78942),"Map");t.exports=n},68250:(t,e,r)=>{var n=r(49753),i=r(5681),s=r(80088),o=r(54732),a=r(59068);function l(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}l.prototype.clear=n,l.prototype.delete=i,l.prototype.get=s,l.prototype.has=o,l.prototype.set=a,t.exports=l},89413:(t,e,r)=>{var n=r(94715)(r(78942),"Promise");t.exports=n},64512:(t,e,r)=>{var n=r(94715)(r(78942),"Set");t.exports=n},23212:(t,e,r)=>{var n=r(68250),i=r(1877),s=r(8006);function o(t){var e=-1,r=null==t?0:t.length;for(this.__data__=new n;++e<r;)this.add(t[e])}o.prototype.add=o.prototype.push=i,o.prototype.has=s,t.exports=o},51340:(t,e,r)=>{var n=r(1386),i=r(64103),s=r(21779),o=r(34162),a=r(7462),l=r(96638);function c(t){var e=this.__data__=new n(t);this.size=e.size}c.prototype.clear=i,c.prototype.delete=s,c.prototype.get=o,c.prototype.has=a,c.prototype.set=l,t.exports=c},65650:(t,e,r)=>{var n=r(78942).Symbol;t.exports=n},31623:(t,e,r)=>{var n=r(78942).Uint8Array;t.exports=n},19270:(t,e,r)=>{var n=r(94715)(r(78942),"WeakMap");t.exports=n},86912:t=>{t.exports=function(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}},79968:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length;++r<n&&!1!==e(t[r],r,t););return t}},79847:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length,i=0,s=[];++r<n;){var o=t[r];e(o,r,t)&&(s[i++]=o)}return s}},59756:(t,e,r)=>{var n=r(2478);t.exports=function(t,e){return!(null==t||!t.length)&&n(t,e,0)>-1}},43316:t=>{t.exports=function(t,e,r){for(var n=-1,i=null==t?0:t.length;++n<i;)if(r(e,t[n]))return!0;return!1}},10358:(t,e,r)=>{var n=r(26137),i=r(3283),s=r(53142),o=r(75853),a=r(69632),l=r(8666),c=Object.prototype.hasOwnProperty;t.exports=function(t,e){var r=s(t),u=!r&&i(t),h=!r&&!u&&o(t),d=!r&&!u&&!h&&l(t),f=r||u||h||d,p=f?n(t.length,String):[],m=p.length;for(var g in t)!e&&!c.call(t,g)||f&&("length"==g||h&&("offset"==g||"parent"==g)||d&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||a(g,m))||p.push(g);return p}},65111:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}},11129:t=>{t.exports=function(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}},36465:t=>{t.exports=function(t,e){for(var r=-1,n=null==t?0:t.length;++r<n;)if(e(t[r],r,t))return!0;return!1}},24810:(t,e,r)=>{var n=r(57073),i=r(46285);t.exports=function(t,e,r){(void 0!==r&&!i(t[e],r)||void 0===r&&!(e in t))&&n(t,e,r)}},3422:(t,e,r)=>{var n=r(57073),i=r(46285),s=Object.prototype.hasOwnProperty;t.exports=function(t,e,r){var o=t[e];s.call(t,e)&&i(o,r)&&(void 0!==r||e in t)||n(t,e,r)}},97034:(t,e,r)=>{var n=r(46285);t.exports=function(t,e){for(var r=t.length;r--;)if(n(t[r][0],e))return r;return-1}},37930:(t,e,r)=>{var n=r(39032),i=r(81211);t.exports=function(t,e){return t&&n(e,i(e),t)}},30125:(t,e,r)=>{var n=r(39032),i=r(25288);t.exports=function(t,e){return t&&n(e,i(e),t)}},57073:(t,e,r)=>{var n=r(72532);t.exports=function(t,e,r){"__proto__"==e&&n?n(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}},69334:(t,e,r)=>{var n=r(51340),i=r(79968),s=r(3422),o=r(37930),a=r(30125),l=r(17099),c=r(84354),u=r(83546),h=r(24733),d=r(80393),f=r(93650),p=r(28486),m=r(97350),g=r(50424),y=r(75964),v=r(53142),_=r(75853),b=r(37681),w=r(41580),x=r(83943),E=r(81211),S=r(25288),A="[object Arguments]",P="[object Function]",T="[object Object]",C={};C[A]=C["[object Array]"]=C["[object ArrayBuffer]"]=C["[object DataView]"]=C["[object Boolean]"]=C["[object Date]"]=C["[object Float32Array]"]=C["[object Float64Array]"]=C["[object Int8Array]"]=C["[object Int16Array]"]=C["[object Int32Array]"]=C["[object Map]"]=C["[object Number]"]=C[T]=C["[object RegExp]"]=C["[object Set]"]=C["[object String]"]=C["[object Symbol]"]=C["[object Uint8Array]"]=C["[object Uint8ClampedArray]"]=C["[object Uint16Array]"]=C["[object Uint32Array]"]=!0,C["[object Error]"]=C[P]=C["[object WeakMap]"]=!1,t.exports=function t(e,r,M,O,R,D){var I,k=1&r,L=2&r,F=4&r;if(M&&(I=R?M(e,O,R,D):M(e)),void 0!==I)return I;if(!w(e))return e;var j=v(e);if(j){if(I=m(e),!k)return c(e,I)}else{var N=p(e),G=N==P||"[object GeneratorFunction]"==N;if(_(e))return l(e,k);if(N==T||N==A||G&&!R){if(I=L||G?{}:y(e),!k)return L?h(e,a(I,e)):u(e,o(I,e))}else{if(!C[N])return R?e:{};I=g(e,N,k)}}D||(D=new n);var $=D.get(e);if($)return $;D.set(e,I),x(e)?e.forEach((function(n){I.add(t(n,r,M,n,e,D))})):b(e)&&e.forEach((function(n,i){I.set(i,t(n,r,M,i,e,D))}));var z=j?void 0:(F?L?f:d:L?S:E)(e);return i(z||e,(function(n,i){z&&(n=e[i=n]),s(I,i,t(n,r,M,i,e,D))})),I}},39747:(t,e,r)=>{var n=r(41580),i=Object.create,s=function(){function t(){}return function(e){if(!n(e))return{};if(i)return i(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}();t.exports=s},96576:(t,e,r)=>{var n=r(23212),i=r(59756),s=r(43316),o=r(65111),a=r(49460),l=r(65568);t.exports=function(t,e,r,c){var u=-1,h=i,d=!0,f=t.length,p=[],m=e.length;if(!f)return p;r&&(e=o(e,a(r))),c?(h=s,d=!1):e.length>=200&&(h=l,d=!1,e=new n(e));t:for(;++u<f;){var g=t[u],y=null==r?g:r(g);if(g=c||0!==g?g:0,d&&y==y){for(var v=m;v--;)if(e[v]===y)continue t;p.push(g)}else h(e,y,c)||p.push(g)}return p}},84570:(t,e,r)=>{var n=r(47170),i=r(45770)(n);t.exports=i},37250:t=>{t.exports=function(t,e,r,n){for(var i=t.length,s=r+(n?1:-1);n?s--:++s<i;)if(e(t[s],s,t))return s;return-1}},90313:(t,e,r)=>{var n=r(11129),i=r(20714);t.exports=function t(e,r,s,o,a){var l=-1,c=e.length;for(s||(s=i),a||(a=[]);++l<c;){var u=e[l];r>0&&s(u)?r>1?t(u,r-1,s,o,a):n(a,u):o||(a[a.length]=u)}return a}},35636:(t,e,r)=>{var n=r(86596)();t.exports=n},47170:(t,e,r)=>{var n=r(35636),i=r(81211);t.exports=function(t,e){return t&&n(t,e,i)}},57923:(t,e,r)=>{var n=r(93526),i=r(66040);t.exports=function(t,e){for(var r=0,s=(e=n(e,t)).length;null!=t&&r<s;)t=t[i(e[r++])];return r&&r==s?t:void 0}},48244:(t,e,r)=>{var n=r(11129),i=r(53142);t.exports=function(t,e,r){var s=e(t);return i(t)?s:n(s,r(t))}},87379:(t,e,r)=>{var n=r(65650),i=r(8870),s=r(29005),o=n?n.toStringTag:void 0;t.exports=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":o&&o in Object(t)?i(t):s(t)}},43636:t=>{t.exports=function(t,e){return null!=t&&e in Object(t)}},2478:(t,e,r)=>{var n=r(37250),i=r(69454),s=r(97706);t.exports=function(t,e,r){return e==e?s(t,e,r):n(t,i,r)}},38250:t=>{t.exports=function(t,e,r,n){for(var i=r-1,s=t.length;++i<s;)if(n(t[i],e))return i;return-1}},93854:(t,e,r)=>{var n=r(23212),i=r(59756),s=r(43316),o=r(65111),a=r(49460),l=r(65568),c=Math.min;t.exports=function(t,e,r){for(var u=r?s:i,h=t[0].length,d=t.length,f=d,p=Array(d),m=1/0,g=[];f--;){var y=t[f];f&&e&&(y=o(y,a(e))),m=c(y.length,m),p[f]=!r&&(e||h>=120&&y.length>=120)?new n(f&&y):void 0}y=t[0];var v=-1,_=p[0];t:for(;++v<h&&g.length<m;){var b=y[v],w=e?e(b):b;if(b=r||0!==b?b:0,!(_?l(_,w):u(g,w,r))){for(f=d;--f;){var x=p[f];if(!(x?l(x,w):u(t[f],w,r)))continue t}_&&_.push(w),g.push(b)}}return g}},56027:(t,e,r)=>{var n=r(87379),i=r(80547);t.exports=function(t){return i(t)&&"[object Arguments]"==n(t)}},94687:(t,e,r)=>{var n=r(90353),i=r(80547);t.exports=function t(e,r,s,o,a){return e===r||(null==e||null==r||!i(e)&&!i(r)?e!=e&&r!=r:n(e,r,s,o,t,a))}},90353:(t,e,r)=>{var n=r(51340),i=r(33934),s=r(88861),o=r(31182),a=r(28486),l=r(53142),c=r(75853),u=r(8666),h="[object Arguments]",d="[object Array]",f="[object Object]",p=Object.prototype.hasOwnProperty;t.exports=function(t,e,r,m,g,y){var v=l(t),_=l(e),b=v?d:a(t),w=_?d:a(e),x=(b=b==h?f:b)==f,E=(w=w==h?f:w)==f,S=b==w;if(S&&c(t)){if(!c(e))return!1;v=!0,x=!1}if(S&&!x)return y||(y=new n),v||u(t)?i(t,e,r,m,g,y):s(t,e,b,r,m,g,y);if(!(1&r)){var A=x&&p.call(t,"__wrapped__"),P=E&&p.call(e,"__wrapped__");if(A||P){var T=A?t.value():t,C=P?e.value():e;return y||(y=new n),g(T,C,r,m,y)}}return!!S&&(y||(y=new n),o(t,e,r,m,g,y))}},80777:(t,e,r)=>{var n=r(28486),i=r(80547);t.exports=function(t){return i(t)&&"[object Map]"==n(t)}},38330:(t,e,r)=>{var n=r(51340),i=r(94687);t.exports=function(t,e,r,s){var o=r.length,a=o,l=!s;if(null==t)return!a;for(t=Object(t);o--;){var c=r[o];if(l&&c[2]?c[1]!==t[c[0]]:!(c[0]in t))return!1}for(;++o<a;){var u=(c=r[o])[0],h=t[u],d=c[1];if(l&&c[2]){if(void 0===h&&!(u in t))return!1}else{var f=new n;if(s)var p=s(h,d,u,t,e,f);if(!(void 0===p?i(d,h,3,s,f):p))return!1}}return!0}},69454:t=>{t.exports=function(t){return t!=t}},89624:(t,e,r)=>{var n=r(93655),i=r(64759),s=r(41580),o=r(64066),a=/^\[object .+?Constructor\]$/,l=Function.prototype,c=Object.prototype,u=l.toString,h=c.hasOwnProperty,d=RegExp("^"+u.call(h).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=function(t){return!(!s(t)||i(t))&&(n(t)?d:a).test(o(t))}},81935:(t,e,r)=>{var n=r(28486),i=r(80547);t.exports=function(t){return i(t)&&"[object Set]"==n(t)}},70674:(t,e,r)=>{var n=r(87379),i=r(65387),s=r(80547),o={};o["[object Float32Array]"]=o["[object Float64Array]"]=o["[object Int8Array]"]=o["[object Int16Array]"]=o["[object Int32Array]"]=o["[object Uint8Array]"]=o["[object Uint8ClampedArray]"]=o["[object Uint16Array]"]=o["[object Uint32Array]"]=!0,o["[object Arguments]"]=o["[object Array]"]=o["[object ArrayBuffer]"]=o["[object Boolean]"]=o["[object DataView]"]=o["[object Date]"]=o["[object Error]"]=o["[object Function]"]=o["[object Map]"]=o["[object Number]"]=o["[object Object]"]=o["[object RegExp]"]=o["[object Set]"]=o["[object String]"]=o["[object WeakMap]"]=!1,t.exports=function(t){return s(t)&&i(t.length)&&!!o[n(t)]}},3334:(t,e,r)=>{var n=r(36526),i=r(12343),s=r(22053),o=r(53142),a=r(43282);t.exports=function(t){return"function"==typeof t?t:null==t?s:"object"==typeof t?o(t)?i(t[0],t[1]):n(t):a(t)}},195:(t,e,r)=>{var n=r(84882),i=r(98121),s=Object.prototype.hasOwnProperty;t.exports=function(t){if(!n(t))return i(t);var e=[];for(var r in Object(t))s.call(t,r)&&"constructor"!=r&&e.push(r);return e}},57200:(t,e,r)=>{var n=r(41580),i=r(84882),s=r(38546),o=Object.prototype.hasOwnProperty;t.exports=function(t){if(!n(t))return s(t);var e=i(t),r=[];for(var a in t)("constructor"!=a||!e&&o.call(t,a))&&r.push(a);return r}},41393:(t,e,r)=>{var n=r(84570),i=r(36529);t.exports=function(t,e){var r=-1,s=i(t)?Array(t.length):[];return n(t,(function(t,n,i){s[++r]=e(t,n,i)})),s}},36526:(t,e,r)=>{var n=r(38330),i=r(24367),s=r(23904);t.exports=function(t){var e=i(t);return 1==e.length&&e[0][2]?s(e[0][0],e[0][1]):function(r){return r===t||n(r,t,e)}}},12343:(t,e,r)=>{var n=r(94687),i=r(46123),s=r(27276),o=r(65187),a=r(67267),l=r(23904),c=r(66040);t.exports=function(t,e){return o(t)&&a(e)?l(c(t),e):function(r){var o=i(r,t);return void 0===o&&o===e?s(r,t):n(e,o,3)}}},40091:(t,e,r)=>{var n=r(51340),i=r(24810),s=r(35636),o=r(26885),a=r(41580),l=r(25288),c=r(78763);t.exports=function t(e,r,u,h,d){e!==r&&s(r,(function(s,l){if(d||(d=new n),a(s))o(e,r,l,u,t,h,d);else{var f=h?h(c(e,l),s,l+"",e,r,d):void 0;void 0===f&&(f=s),i(e,l,f)}}),l)}},26885:(t,e,r)=>{var n=r(24810),i=r(17099),s=r(92264),o=r(84354),a=r(75964),l=r(3283),c=r(53142),u=r(65406),h=r(75853),d=r(93655),f=r(41580),p=r(48360),m=r(8666),g=r(78763),y=r(64207);t.exports=function(t,e,r,v,_,b,w){var x=g(t,r),E=g(e,r),S=w.get(E);if(S)n(t,r,S);else{var A=b?b(x,E,r+"",t,e,w):void 0,P=void 0===A;if(P){var T=c(E),C=!T&&h(E),M=!T&&!C&&m(E);A=E,T||C||M?c(x)?A=x:u(x)?A=o(x):C?(P=!1,A=i(E,!0)):M?(P=!1,A=s(E,!0)):A=[]:p(E)||l(E)?(A=x,l(x)?A=y(x):f(x)&&!d(x)||(A=a(E))):P=!1}P&&(w.set(E,A),_(A,E,v,b,w),w.delete(E)),n(t,r,A)}}},70310:(t,e,r)=>{var n=r(65111),i=r(57923),s=r(3334),o=r(41393),a=r(50642),l=r(49460),c=r(46775),u=r(22053),h=r(53142);t.exports=function(t,e,r){e=e.length?n(e,(function(t){return h(t)?function(e){return i(e,1===t.length?t[0]:t)}:t})):[u];var d=-1;e=n(e,l(s));var f=o(t,(function(t,r,i){return{criteria:n(e,(function(e){return e(t)})),index:++d,value:t}}));return a(f,(function(t,e){return c(t,e,r)}))}},90242:(t,e,r)=>{var n=r(35031),i=r(27276);t.exports=function(t,e){return n(t,e,(function(e,r){return i(t,r)}))}},35031:(t,e,r)=>{var n=r(57923),i=r(87655),s=r(93526);t.exports=function(t,e,r){for(var o=-1,a=e.length,l={};++o<a;){var c=e[o],u=n(t,c);r(u,c)&&i(l,s(c,t),u)}return l}},12762:t=>{t.exports=function(t){return function(e){return null==e?void 0:e[t]}}},98880:(t,e,r)=>{var n=r(57923);t.exports=function(t){return function(e){return n(e,t)}}},49261:(t,e,r)=>{var n=r(65111),i=r(2478),s=r(38250),o=r(49460),a=r(84354),l=Array.prototype.splice;t.exports=function(t,e,r,c){var u=c?s:i,h=-1,d=e.length,f=t;for(t===e&&(e=a(e)),r&&(f=n(t,o(r)));++h<d;)for(var p=0,m=e[h],g=r?r(m):m;(p=u(f,g,p,c))>-1;)f!==t&&l.call(f,p,1),l.call(t,p,1);return t}},23945:(t,e,r)=>{var n=r(22053),i=r(75234),s=r(80796);t.exports=function(t,e){return s(i(t,e,n),t+"")}},87655:(t,e,r)=>{var n=r(3422),i=r(93526),s=r(69632),o=r(41580),a=r(66040);t.exports=function(t,e,r,l){if(!o(t))return t;for(var c=-1,u=(e=i(e,t)).length,h=u-1,d=t;null!=d&&++c<u;){var f=a(e[c]),p=r;if("__proto__"===f||"constructor"===f||"prototype"===f)return t;if(c!=h){var m=d[f];void 0===(p=l?l(m,f,d):void 0)&&(p=o(m)?m:s(e[c+1])?[]:{})}n(d,f,p),d=d[f]}return t}},47403:(t,e,r)=>{var n=r(82619),i=r(72532),s=r(22053),o=i?function(t,e){return i(t,"toString",{configurable:!0,enumerable:!1,value:n(e),writable:!0})}:s;t.exports=o},50642:t=>{t.exports=function(t,e){var r=t.length;for(t.sort(e);r--;)t[r]=t[r].value;return t}},26137:t=>{t.exports=function(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}},52291:(t,e,r)=>{var n=r(65650),i=r(65111),s=r(53142),o=r(51187),a=n?n.prototype:void 0,l=a?a.toString:void 0;t.exports=function t(e){if("string"==typeof e)return e;if(s(e))return i(e,t)+"";if(o(e))return l?l.call(e):"";var r=e+"";return"0"==r&&1/e==-1/0?"-0":r}},49460:t=>{t.exports=function(t){return function(e){return t(e)}}},15630:(t,e,r)=>{var n=r(23212),i=r(59756),s=r(43316),o=r(65568),a=r(36208),l=r(49828);t.exports=function(t,e,r){var c=-1,u=i,h=t.length,d=!0,f=[],p=f;if(r)d=!1,u=s;else if(h>=200){var m=e?null:a(t);if(m)return l(m);d=!1,u=o,p=new n}else p=e?[]:f;t:for(;++c<h;){var g=t[c],y=e?e(g):g;if(g=r||0!==g?g:0,d&&y==y){for(var v=p.length;v--;)if(p[v]===y)continue t;e&&p.push(y),f.push(g)}else u(p,y,r)||(p!==f&&p.push(y),f.push(g))}return f}},65568:t=>{t.exports=function(t,e){return t.has(e)}},47648:(t,e,r)=>{var n=r(65406);t.exports=function(t){return n(t)?t:[]}},23997:(t,e,r)=>{var n=r(22053);t.exports=function(t){return"function"==typeof t?t:n}},93526:(t,e,r)=>{var n=r(53142),i=r(65187),s=r(96493),o=r(95243);t.exports=function(t,e){return n(t)?t:i(t,e)?[t]:s(o(t))}},58898:(t,e,r)=>{var n=r(31623);t.exports=function(t){var e=new t.constructor(t.byteLength);return new n(e).set(new n(t)),e}},17099:(t,e,r)=>{t=r.nmd(t);var n=r(78942),i=e&&!e.nodeType&&e,s=i&&t&&!t.nodeType&&t,o=s&&s.exports===i?n.Buffer:void 0,a=o?o.allocUnsafe:void 0;t.exports=function(t,e){if(e)return t.slice();var r=t.length,n=a?a(r):new t.constructor(r);return t.copy(n),n}},92480:(t,e,r)=>{var n=r(58898);t.exports=function(t,e){var r=e?n(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}},78340:t=>{var e=/\w*$/;t.exports=function(t){var r=new t.constructor(t.source,e.exec(t));return r.lastIndex=t.lastIndex,r}},18069:(t,e,r)=>{var n=r(65650),i=n?n.prototype:void 0,s=i?i.valueOf:void 0;t.exports=function(t){return s?Object(s.call(t)):{}}},92264:(t,e,r)=>{var n=r(58898);t.exports=function(t,e){var r=e?n(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}},63521:(t,e,r)=>{var n=r(51187);t.exports=function(t,e){if(t!==e){var r=void 0!==t,i=null===t,s=t==t,o=n(t),a=void 0!==e,l=null===e,c=e==e,u=n(e);if(!l&&!u&&!o&&t>e||o&&a&&c&&!l&&!u||i&&a&&c||!r&&c||!s)return 1;if(!i&&!o&&!u&&t<e||u&&r&&s&&!i&&!o||l&&r&&s||!a&&s||!c)return-1}return 0}},46775:(t,e,r)=>{var n=r(63521);t.exports=function(t,e,r){for(var i=-1,s=t.criteria,o=e.criteria,a=s.length,l=r.length;++i<a;){var c=n(s[i],o[i]);if(c)return i>=l?c:c*("desc"==r[i]?-1:1)}return t.index-e.index}},84354:t=>{t.exports=function(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r<n;)e[r]=t[r];return e}},39032:(t,e,r)=>{var n=r(3422),i=r(57073);t.exports=function(t,e,r,s){var o=!r;r||(r={});for(var a=-1,l=e.length;++a<l;){var c=e[a],u=s?s(r[c],t[c],c,r,t):void 0;void 0===u&&(u=t[c]),o?i(r,c,u):n(r,c,u)}return r}},83546:(t,e,r)=>{var n=r(39032),i=r(77979);t.exports=function(t,e){return n(t,i(t),e)}},24733:(t,e,r)=>{var n=r(39032),i=r(85832);t.exports=function(t,e){return n(t,i(t),e)}},41950:(t,e,r)=>{var n=r(78942)["__core-js_shared__"];t.exports=n},77848:(t,e,r)=>{var n=r(23945),i=r(74535);t.exports=function(t){return n((function(e,r){var n=-1,s=r.length,o=s>1?r[s-1]:void 0,a=s>2?r[2]:void 0;for(o=t.length>3&&"function"==typeof o?(s--,o):void 0,a&&i(r[0],r[1],a)&&(o=s<3?void 0:o,s=1),e=Object(e);++n<s;){var l=r[n];l&&t(e,l,n,o)}return e}))}},45770:(t,e,r)=>{var n=r(36529);t.exports=function(t,e){return function(r,i){if(null==r)return r;if(!n(r))return t(r,i);for(var s=r.length,o=e?s:-1,a=Object(r);(e?o--:++o<s)&&!1!==i(a[o],o,a););return r}}},86596:t=>{t.exports=function(t){return function(e,r,n){for(var i=-1,s=Object(e),o=n(e),a=o.length;a--;){var l=o[t?a:++i];if(!1===r(s[l],l,s))break}return e}}},36208:(t,e,r)=>{var n=r(64512),i=r(79071),s=r(49828),o=n&&1/s(new n([,-0]))[1]==1/0?function(t){return new n(t)}:i;t.exports=o},52107:(t,e,r)=>{var n=r(40091),i=r(41580);t.exports=function t(e,r,s,o,a,l){return i(e)&&i(r)&&(l.set(r,e),n(e,r,void 0,t,l),l.delete(r)),e}},72532:(t,e,r)=>{var n=r(94715),i=function(){try{var t=n(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=i},33934:(t,e,r)=>{var n=r(23212),i=r(36465),s=r(65568);t.exports=function(t,e,r,o,a,l){var c=1&r,u=t.length,h=e.length;if(u!=h&&!(c&&h>u))return!1;var d=l.get(t),f=l.get(e);if(d&&f)return d==e&&f==t;var p=-1,m=!0,g=2&r?new n:void 0;for(l.set(t,e),l.set(e,t);++p<u;){var y=t[p],v=e[p];if(o)var _=c?o(v,y,p,e,t,l):o(y,v,p,t,e,l);if(void 0!==_){if(_)continue;m=!1;break}if(g){if(!i(e,(function(t,e){if(!s(g,e)&&(y===t||a(y,t,r,o,l)))return g.push(e)}))){m=!1;break}}else if(y!==v&&!a(y,v,r,o,l)){m=!1;break}}return l.delete(t),l.delete(e),m}},88861:(t,e,r)=>{var n=r(65650),i=r(31623),s=r(46285),o=r(33934),a=r(95894),l=r(49828),c=n?n.prototype:void 0,u=c?c.valueOf:void 0;t.exports=function(t,e,r,n,c,h,d){switch(r){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return!(t.byteLength!=e.byteLength||!h(new i(t),new i(e)));case"[object Boolean]":case"[object Date]":case"[object Number]":return s(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var f=a;case"[object Set]":var p=1&n;if(f||(f=l),t.size!=e.size&&!p)return!1;var m=d.get(t);if(m)return m==e;n|=2,d.set(t,e);var g=o(f(t),f(e),n,c,h,d);return d.delete(t),g;case"[object Symbol]":if(u)return u.call(t)==u.call(e)}return!1}},31182:(t,e,r)=>{var n=r(80393),i=Object.prototype.hasOwnProperty;t.exports=function(t,e,r,s,o,a){var l=1&r,c=n(t),u=c.length;if(u!=n(e).length&&!l)return!1;for(var h=u;h--;){var d=c[h];if(!(l?d in e:i.call(e,d)))return!1}var f=a.get(t),p=a.get(e);if(f&&p)return f==e&&p==t;var m=!0;a.set(t,e),a.set(e,t);for(var g=l;++h<u;){var y=t[d=c[h]],v=e[d];if(s)var _=l?s(v,y,d,e,t,a):s(y,v,d,t,e,a);if(!(void 0===_?y===v||o(y,v,r,s,a):_)){m=!1;break}g||(g="constructor"==d)}if(m&&!g){var b=t.constructor,w=e.constructor;b==w||!("constructor"in t)||!("constructor"in e)||"function"==typeof b&&b instanceof b&&"function"==typeof w&&w instanceof w||(m=!1)}return a.delete(t),a.delete(e),m}},41439:(t,e,r)=>{var n=r(75857),i=r(75234),s=r(80796);t.exports=function(t){return s(i(t,void 0,n),t+"")}},74967:(t,e,r)=>{var n="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g;t.exports=n},80393:(t,e,r)=>{var n=r(48244),i=r(77979),s=r(81211);t.exports=function(t){return n(t,s,i)}},93650:(t,e,r)=>{var n=r(48244),i=r(85832),s=r(25288);t.exports=function(t){return n(t,s,i)}},44700:(t,e,r)=>{var n=r(79067);t.exports=function(t,e){var r=t.__data__;return n(e)?r["string"==typeof e?"string":"hash"]:r.map}},24367:(t,e,r)=>{var n=r(67267),i=r(81211);t.exports=function(t){for(var e=i(t),r=e.length;r--;){var s=e[r],o=t[s];e[r]=[s,o,n(o)]}return e}},94715:(t,e,r)=>{var n=r(89624),i=r(20155);t.exports=function(t,e){var r=i(t,e);return n(r)?r:void 0}},74784:(t,e,r)=>{var n=r(3766)(Object.getPrototypeOf,Object);t.exports=n},8870:(t,e,r)=>{var n=r(65650),i=Object.prototype,s=i.hasOwnProperty,o=i.toString,a=n?n.toStringTag:void 0;t.exports=function(t){var e=s.call(t,a),r=t[a];try{t[a]=void 0;var n=!0}catch(t){}var i=o.call(t);return n&&(e?t[a]=r:delete t[a]),i}},77979:(t,e,r)=>{var n=r(79847),i=r(99306),s=Object.prototype.propertyIsEnumerable,o=Object.getOwnPropertySymbols,a=o?function(t){return null==t?[]:(t=Object(t),n(o(t),(function(e){return s.call(t,e)})))}:i;t.exports=a},85832:(t,e,r)=>{var n=r(11129),i=r(74784),s=r(77979),o=r(99306),a=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)n(e,s(t)),t=i(t);return e}:o;t.exports=a},28486:(t,e,r)=>{var n=r(33103),i=r(19770),s=r(89413),o=r(64512),a=r(19270),l=r(87379),c=r(64066),u="[object Map]",h="[object Promise]",d="[object Set]",f="[object WeakMap]",p="[object DataView]",m=c(n),g=c(i),y=c(s),v=c(o),_=c(a),b=l;(n&&b(new n(new ArrayBuffer(1)))!=p||i&&b(new i)!=u||s&&b(s.resolve())!=h||o&&b(new o)!=d||a&&b(new a)!=f)&&(b=function(t){var e=l(t),r="[object Object]"==e?t.constructor:void 0,n=r?c(r):"";if(n)switch(n){case m:return p;case g:return u;case y:return h;case v:return d;case _:return f}return e}),t.exports=b},20155:t=>{t.exports=function(t,e){return null==t?void 0:t[e]}},85899:(t,e,r)=>{var n=r(93526),i=r(3283),s=r(53142),o=r(69632),a=r(65387),l=r(66040);t.exports=function(t,e,r){for(var c=-1,u=(e=n(e,t)).length,h=!1;++c<u;){var d=l(e[c]);if(!(h=null!=t&&r(t,d)))break;t=t[d]}return h||++c!=u?h:!!(u=null==t?0:t.length)&&a(u)&&o(d,u)&&(s(t)||i(t))}},23305:(t,e,r)=>{var n=r(94497);t.exports=function(){this.__data__=n?n(null):{},this.size=0}},39361:t=>{t.exports=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}},11112:(t,e,r)=>{var n=r(94497),i=Object.prototype.hasOwnProperty;t.exports=function(t){var e=this.__data__;if(n){var r=e[t];return"__lodash_hash_undefined__"===r?void 0:r}return i.call(e,t)?e[t]:void 0}},25276:(t,e,r)=>{var n=r(94497),i=Object.prototype.hasOwnProperty;t.exports=function(t){var e=this.__data__;return n?void 0!==e[t]:i.call(e,t)}},57452:(t,e,r)=>{var n=r(94497);t.exports=function(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=n&&void 0===e?"__lodash_hash_undefined__":e,this}},97350:t=>{var e=Object.prototype.hasOwnProperty;t.exports=function(t){var r=t.length,n=new t.constructor(r);return r&&"string"==typeof t[0]&&e.call(t,"index")&&(n.index=t.index,n.input=t.input),n}},50424:(t,e,r)=>{var n=r(58898),i=r(92480),s=r(78340),o=r(18069),a=r(92264);t.exports=function(t,e,r){var l=t.constructor;switch(e){case"[object ArrayBuffer]":return n(t);case"[object Boolean]":case"[object Date]":return new l(+t);case"[object DataView]":return i(t,r);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return a(t,r);case"[object Map]":case"[object Set]":return new l;case"[object Number]":case"[object String]":return new l(t);case"[object RegExp]":return s(t);case"[object Symbol]":return o(t)}}},75964:(t,e,r)=>{var n=r(39747),i=r(74784),s=r(84882);t.exports=function(t){return"function"!=typeof t.constructor||s(t)?{}:n(i(t))}},20714:(t,e,r)=>{var n=r(65650),i=r(3283),s=r(53142),o=n?n.isConcatSpreadable:void 0;t.exports=function(t){return s(t)||i(t)||!!(o&&t&&t[o])}},69632:t=>{var e=/^(?:0|[1-9]\d*)$/;t.exports=function(t,r){var n=typeof t;return!!(r=null==r?9007199254740991:r)&&("number"==n||"symbol"!=n&&e.test(t))&&t>-1&&t%1==0&&t<r}},74535:(t,e,r)=>{var n=r(46285),i=r(36529),s=r(69632),o=r(41580);t.exports=function(t,e,r){if(!o(r))return!1;var a=typeof e;return!!("number"==a?i(r)&&s(e,r.length):"string"==a&&e in r)&&n(r[e],t)}},65187:(t,e,r)=>{var n=r(53142),i=r(51187),s=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,o=/^\w*$/;t.exports=function(t,e){if(n(t))return!1;var r=typeof t;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=t&&!i(t))||o.test(t)||!s.test(t)||null!=e&&t in Object(e)}},79067:t=>{t.exports=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}},64759:(t,e,r)=>{var n,i=r(41950),s=(n=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"";t.exports=function(t){return!!s&&s in t}},84882:t=>{var e=Object.prototype;t.exports=function(t){var r=t&&t.constructor;return t===("function"==typeof r&&r.prototype||e)}},67267:(t,e,r)=>{var n=r(41580);t.exports=function(t){return t==t&&!n(t)}},12393:t=>{t.exports=function(){this.__data__=[],this.size=0}},62049:(t,e,r)=>{var n=r(97034),i=Array.prototype.splice;t.exports=function(t){var e=this.__data__,r=n(e,t);return!(r<0||(r==e.length-1?e.pop():i.call(e,r,1),--this.size,0))}},7144:(t,e,r)=>{var n=r(97034);t.exports=function(t){var e=this.__data__,r=n(e,t);return r<0?void 0:e[r][1]}},7452:(t,e,r)=>{var n=r(97034);t.exports=function(t){return n(this.__data__,t)>-1}},13964:(t,e,r)=>{var n=r(97034);t.exports=function(t,e){var r=this.__data__,i=n(r,t);return i<0?(++this.size,r.push([t,e])):r[i][1]=e,this}},49753:(t,e,r)=>{var n=r(25098),i=r(1386),s=r(19770);t.exports=function(){this.size=0,this.__data__={hash:new n,map:new(s||i),string:new n}}},5681:(t,e,r)=>{var n=r(44700);t.exports=function(t){var e=n(this,t).delete(t);return this.size-=e?1:0,e}},80088:(t,e,r)=>{var n=r(44700);t.exports=function(t){return n(this,t).get(t)}},54732:(t,e,r)=>{var n=r(44700);t.exports=function(t){return n(this,t).has(t)}},59068:(t,e,r)=>{var n=r(44700);t.exports=function(t,e){var r=n(this,t),i=r.size;return r.set(t,e),this.size+=r.size==i?0:1,this}},95894:t=>{t.exports=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t,n){r[++e]=[n,t]})),r}},23904:t=>{t.exports=function(t,e){return function(r){return null!=r&&r[t]===e&&(void 0!==e||t in Object(r))}}},76853:(t,e,r)=>{var n=r(69011);t.exports=function(t){var e=n(t,(function(t){return 500===r.size&&r.clear(),t})),r=e.cache;return e}},94497:(t,e,r)=>{var n=r(94715)(Object,"create");t.exports=n},98121:(t,e,r)=>{var n=r(3766)(Object.keys,Object);t.exports=n},38546:t=>{t.exports=function(t){var e=[];if(null!=t)for(var r in Object(t))e.push(r);return e}},2306:(t,e,r)=>{t=r.nmd(t);var n=r(74967),i=e&&!e.nodeType&&e,s=i&&t&&!t.nodeType&&t,o=s&&s.exports===i&&n.process,a=function(){try{return s&&s.require&&s.require("util").types||o&&o.binding&&o.binding("util")}catch(t){}}();t.exports=a},29005:t=>{var e=Object.prototype.toString;t.exports=function(t){return e.call(t)}},3766:t=>{t.exports=function(t,e){return function(r){return t(e(r))}}},75234:(t,e,r)=>{var n=r(86912),i=Math.max;t.exports=function(t,e,r){return e=i(void 0===e?t.length-1:e,0),function(){for(var s=arguments,o=-1,a=i(s.length-e,0),l=Array(a);++o<a;)l[o]=s[e+o];o=-1;for(var c=Array(e+1);++o<e;)c[o]=s[o];return c[e]=r(l),n(t,this,c)}}},78942:(t,e,r)=>{var n=r(74967),i="object"==typeof self&&self&&self.Object===Object&&self,s=n||i||Function("return this")();t.exports=s},78763:t=>{t.exports=function(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}},1877:t=>{t.exports=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this}},8006:t=>{t.exports=function(t){return this.__data__.has(t)}},49828:t=>{t.exports=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t){r[++e]=t})),r}},80796:(t,e,r)=>{var n=r(47403),i=r(3316)(n);t.exports=i},3316:t=>{var e=Date.now;t.exports=function(t){var r=0,n=0;return function(){var i=e(),s=16-(i-n);if(n=i,s>0){if(++r>=800)return arguments[0]}else r=0;return t.apply(void 0,arguments)}}},64103:(t,e,r)=>{var n=r(1386);t.exports=function(){this.__data__=new n,this.size=0}},21779:t=>{t.exports=function(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}},34162:t=>{t.exports=function(t){return this.__data__.get(t)}},7462:t=>{t.exports=function(t){return this.__data__.has(t)}},96638:(t,e,r)=>{var n=r(1386),i=r(19770),s=r(68250);t.exports=function(t,e){var r=this.__data__;if(r instanceof n){var o=r.__data__;if(!i||o.length<199)return o.push([t,e]),this.size=++r.size,this;r=this.__data__=new s(o)}return r.set(t,e),this.size=r.size,this}},97706:t=>{t.exports=function(t,e,r){for(var n=r-1,i=t.length;++n<i;)if(t[n]===e)return n;return-1}},96493:(t,e,r)=>{var n=r(76853),i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,s=/\\(\\)?/g,o=n((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(i,(function(t,r,n,i){e.push(n?i.replace(s,"$1"):r||t)})),e}));t.exports=o},66040:(t,e,r)=>{var n=r(51187);t.exports=function(t){if("string"==typeof t||n(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},64066:t=>{var e=Function.prototype.toString;t.exports=function(t){if(null!=t){try{return e.call(t)}catch(t){}try{return t+""}catch(t){}}return""}},46108:(t,e,r)=>{var n=r(69334);t.exports=function(t){return n(t,5)}},82619:t=>{t.exports=function(t){return function(){return t}}},32293:(t,e,r)=>{var n=r(23945),i=r(46285),s=r(74535),o=r(25288),a=Object.prototype,l=a.hasOwnProperty,c=n((function(t,e){t=Object(t);var r=-1,n=e.length,c=n>2?e[2]:void 0;for(c&&s(e[0],e[1],c)&&(n=1);++r<n;)for(var u=e[r],h=o(u),d=-1,f=h.length;++d<f;){var p=h[d],m=t[p];(void 0===m||i(m,a[p])&&!l.call(t,p))&&(t[p]=u[p])}return t}));t.exports=c},69383:(t,e,r)=>{var n=r(86912),i=r(23945),s=r(52107),o=r(48875),a=i((function(t){return t.push(void 0,s),n(o,void 0,t)}));t.exports=a},46285:t=>{t.exports=function(t,e){return t===e||t!=t&&e!=e}},75857:(t,e,r)=>{var n=r(90313);t.exports=function(t){return null!=t&&t.length?n(t,1):[]}},53435:(t,e,r)=>{var n=r(90313),i=1/0;t.exports=function(t){return null!=t&&t.length?n(t,i):[]}},83657:(t,e,r)=>{var n=r(79968),i=r(84570),s=r(23997),o=r(53142);t.exports=function(t,e){return(o(t)?n:i)(t,s(e))}},46123:(t,e,r)=>{var n=r(57923);t.exports=function(t,e,r){var i=null==t?void 0:n(t,e);return void 0===i?r:i}},27276:(t,e,r)=>{var n=r(43636),i=r(85899);t.exports=function(t,e){return null!=t&&i(t,e,n)}},22053:t=>{t.exports=function(t){return t}},58150:(t,e,r)=>{var n=r(65111),i=r(93854),s=r(23945),o=r(47648),a=s((function(t){var e=n(t,o);return e.length&&e[0]===t[0]?i(e):[]}));t.exports=a},30306:(t,e,r)=>{var n=r(65111),i=r(93854),s=r(23945),o=r(47648),a=r(98087),l=s((function(t){var e=a(t),r=n(t,o);return(e="function"==typeof e?e:void 0)&&r.pop(),r.length&&r[0]===t[0]?i(r,void 0,e):[]}));t.exports=l},3283:(t,e,r)=>{var n=r(56027),i=r(80547),s=Object.prototype,o=s.hasOwnProperty,a=s.propertyIsEnumerable,l=n(function(){return arguments}())?n:function(t){return i(t)&&o.call(t,"callee")&&!a.call(t,"callee")};t.exports=l},53142:t=>{var e=Array.isArray;t.exports=e},36529:(t,e,r)=>{var n=r(93655),i=r(65387);t.exports=function(t){return null!=t&&i(t.length)&&!n(t)}},65406:(t,e,r)=>{var n=r(36529),i=r(80547);t.exports=function(t){return i(t)&&n(t)}},22563:(t,e,r)=>{var n=r(87379),i=r(80547);t.exports=function(t){return!0===t||!1===t||i(t)&&"[object Boolean]"==n(t)}},75853:(t,e,r)=>{t=r.nmd(t);var n=r(78942),i=r(34772),s=e&&!e.nodeType&&e,o=s&&t&&!t.nodeType&&t,a=o&&o.exports===s?n.Buffer:void 0,l=(a?a.isBuffer:void 0)||i;t.exports=l},3514:(t,e,r)=>{var n=r(195),i=r(28486),s=r(3283),o=r(53142),a=r(36529),l=r(75853),c=r(84882),u=r(8666),h=Object.prototype.hasOwnProperty;t.exports=function(t){if(null==t)return!0;if(a(t)&&(o(t)||"string"==typeof t||"function"==typeof t.splice||l(t)||u(t)||s(t)))return!t.length;var e=i(t);if("[object Map]"==e||"[object Set]"==e)return!t.size;if(c(t))return!n(t).length;for(var r in t)if(h.call(t,r))return!1;return!0}},46343:(t,e,r)=>{var n=r(94687);t.exports=function(t,e){return n(t,e)}},93655:(t,e,r)=>{var n=r(87379),i=r(41580);t.exports=function(t){if(!i(t))return!1;var e=n(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},65387:t=>{t.exports=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},37681:(t,e,r)=>{var n=r(80777),i=r(49460),s=r(2306),o=s&&s.isMap,a=o?i(o):n;t.exports=a},41580:t=>{t.exports=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}},80547:t=>{t.exports=function(t){return null!=t&&"object"==typeof t}},48360:(t,e,r)=>{var n=r(87379),i=r(74784),s=r(80547),o=Function.prototype,a=Object.prototype,l=o.toString,c=a.hasOwnProperty,u=l.call(Object);t.exports=function(t){if(!s(t)||"[object Object]"!=n(t))return!1;var e=i(t);if(null===e)return!0;var r=c.call(e,"constructor")&&e.constructor;return"function"==typeof r&&r instanceof r&&l.call(r)==u}},83943:(t,e,r)=>{var n=r(81935),i=r(49460),s=r(2306),o=s&&s.isSet,a=o?i(o):n;t.exports=a},51187:(t,e,r)=>{var n=r(87379),i=r(80547);t.exports=function(t){return"symbol"==typeof t||i(t)&&"[object Symbol]"==n(t)}},8666:(t,e,r)=>{var n=r(70674),i=r(49460),s=r(2306),o=s&&s.isTypedArray,a=o?i(o):n;t.exports=a},81211:(t,e,r)=>{var n=r(10358),i=r(195),s=r(36529);t.exports=function(t){return s(t)?n(t):i(t)}},25288:(t,e,r)=>{var n=r(10358),i=r(57200),s=r(36529);t.exports=function(t){return s(t)?n(t,!0):i(t)}},98087:t=>{t.exports=function(t){var e=null==t?0:t.length;return e?t[e-1]:void 0}},45250:function(t,e,r){var n;t=r.nmd(t),function(){var i,s="Expected a function",o="__lodash_hash_undefined__",a="__lodash_placeholder__",l=32,c=128,u=1/0,h=9007199254740991,d=NaN,f=4294967295,p=[["ary",c],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",l],["partialRight",64],["rearg",256]],m="[object Arguments]",g="[object Array]",y="[object Boolean]",v="[object Date]",_="[object Error]",b="[object Function]",w="[object GeneratorFunction]",x="[object Map]",E="[object Number]",S="[object Object]",A="[object Promise]",P="[object RegExp]",T="[object Set]",C="[object String]",M="[object Symbol]",O="[object WeakMap]",R="[object ArrayBuffer]",D="[object DataView]",I="[object Float32Array]",k="[object Float64Array]",L="[object Int8Array]",F="[object Int16Array]",j="[object Int32Array]",N="[object Uint8Array]",G="[object Uint8ClampedArray]",$="[object Uint16Array]",z="[object Uint32Array]",U=/\b__p \+= '';/g,B=/\b(__p \+=) '' \+/g,V=/(__e\(.*?\)|\b__t\)) \+\n'';/g,q=/&(?:amp|lt|gt|quot|#39);/g,K=/[&<>"']/g,W=RegExp(q.source),H=RegExp(K.source),Y=/<%-([\s\S]+?)%>/g,X=/<%([\s\S]+?)%>/g,Z=/<%=([\s\S]+?)%>/g,J=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Q=/^\w*$/,tt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,et=/[\\^$.*+?()[\]{}|]/g,rt=RegExp(et.source),nt=/^\s+/,it=/\s/,st=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,ot=/\{\n\/\* \[wrapped with (.+)\] \*/,at=/,? & /,lt=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,ct=/[()=,{}\[\]\/\s]/,ut=/\\(\\)?/g,ht=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,dt=/\w*$/,ft=/^[-+]0x[0-9a-f]+$/i,pt=/^0b[01]+$/i,mt=/^\[object .+?Constructor\]$/,gt=/^0o[0-7]+$/i,yt=/^(?:0|[1-9]\d*)$/,vt=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,_t=/($^)/,bt=/['\n\r\u2028\u2029\\]/g,wt="\\ud800-\\udfff",xt="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Et="\\u2700-\\u27bf",St="a-z\\xdf-\\xf6\\xf8-\\xff",At="A-Z\\xc0-\\xd6\\xd8-\\xde",Pt="\\ufe0e\\ufe0f",Tt="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Ct="["+wt+"]",Mt="["+Tt+"]",Ot="["+xt+"]",Rt="\\d+",Dt="["+Et+"]",It="["+St+"]",kt="[^"+wt+Tt+Rt+Et+St+At+"]",Lt="\\ud83c[\\udffb-\\udfff]",Ft="[^"+wt+"]",jt="(?:\\ud83c[\\udde6-\\uddff]){2}",Nt="[\\ud800-\\udbff][\\udc00-\\udfff]",Gt="["+At+"]",$t="\\u200d",zt="(?:"+It+"|"+kt+")",Ut="(?:"+Gt+"|"+kt+")",Bt="(?:['’](?:d|ll|m|re|s|t|ve))?",Vt="(?:['’](?:D|LL|M|RE|S|T|VE))?",qt="(?:"+Ot+"|"+Lt+")?",Kt="["+Pt+"]?",Wt=Kt+qt+"(?:"+$t+"(?:"+[Ft,jt,Nt].join("|")+")"+Kt+qt+")*",Ht="(?:"+[Dt,jt,Nt].join("|")+")"+Wt,Yt="(?:"+[Ft+Ot+"?",Ot,jt,Nt,Ct].join("|")+")",Xt=RegExp("['’]","g"),Zt=RegExp(Ot,"g"),Jt=RegExp(Lt+"(?="+Lt+")|"+Yt+Wt,"g"),Qt=RegExp([Gt+"?"+It+"+"+Bt+"(?="+[Mt,Gt,"$"].join("|")+")",Ut+"+"+Vt+"(?="+[Mt,Gt+zt,"$"].join("|")+")",Gt+"?"+zt+"+"+Bt,Gt+"+"+Vt,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Rt,Ht].join("|"),"g"),te=RegExp("["+$t+wt+xt+Pt+"]"),ee=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,re=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],ne=-1,ie={};ie[I]=ie[k]=ie[L]=ie[F]=ie[j]=ie[N]=ie[G]=ie[$]=ie[z]=!0,ie[m]=ie[g]=ie[R]=ie[y]=ie[D]=ie[v]=ie[_]=ie[b]=ie[x]=ie[E]=ie[S]=ie[P]=ie[T]=ie[C]=ie[O]=!1;var se={};se[m]=se[g]=se[R]=se[D]=se[y]=se[v]=se[I]=se[k]=se[L]=se[F]=se[j]=se[x]=se[E]=se[S]=se[P]=se[T]=se[C]=se[M]=se[N]=se[G]=se[$]=se[z]=!0,se[_]=se[b]=se[O]=!1;var oe={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},ae=parseFloat,le=parseInt,ce="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g,ue="object"==typeof self&&self&&self.Object===Object&&self,he=ce||ue||Function("return this")(),de=e&&!e.nodeType&&e,fe=de&&t&&!t.nodeType&&t,pe=fe&&fe.exports===de,me=pe&&ce.process,ge=function(){try{return fe&&fe.require&&fe.require("util").types||me&&me.binding&&me.binding("util")}catch(t){}}(),ye=ge&&ge.isArrayBuffer,ve=ge&&ge.isDate,_e=ge&&ge.isMap,be=ge&&ge.isRegExp,we=ge&&ge.isSet,xe=ge&&ge.isTypedArray;function Ee(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}function Se(t,e,r,n){for(var i=-1,s=null==t?0:t.length;++i<s;){var o=t[i];e(n,o,r(o),t)}return n}function Ae(t,e){for(var r=-1,n=null==t?0:t.length;++r<n&&!1!==e(t[r],r,t););return t}function Pe(t,e){for(var r=null==t?0:t.length;r--&&!1!==e(t[r],r,t););return t}function Te(t,e){for(var r=-1,n=null==t?0:t.length;++r<n;)if(!e(t[r],r,t))return!1;return!0}function Ce(t,e){for(var r=-1,n=null==t?0:t.length,i=0,s=[];++r<n;){var o=t[r];e(o,r,t)&&(s[i++]=o)}return s}function Me(t,e){return!(null==t||!t.length)&&Ge(t,e,0)>-1}function Oe(t,e,r){for(var n=-1,i=null==t?0:t.length;++n<i;)if(r(e,t[n]))return!0;return!1}function Re(t,e){for(var r=-1,n=null==t?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}function De(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}function Ie(t,e,r,n){var i=-1,s=null==t?0:t.length;for(n&&s&&(r=t[++i]);++i<s;)r=e(r,t[i],i,t);return r}function ke(t,e,r,n){var i=null==t?0:t.length;for(n&&i&&(r=t[--i]);i--;)r=e(r,t[i],i,t);return r}function Le(t,e){for(var r=-1,n=null==t?0:t.length;++r<n;)if(e(t[r],r,t))return!0;return!1}var Fe=Be("length");function je(t,e,r){var n;return r(t,(function(t,r,i){if(e(t,r,i))return n=r,!1})),n}function Ne(t,e,r,n){for(var i=t.length,s=r+(n?1:-1);n?s--:++s<i;)if(e(t[s],s,t))return s;return-1}function Ge(t,e,r){return e==e?function(t,e,r){for(var n=r-1,i=t.length;++n<i;)if(t[n]===e)return n;return-1}(t,e,r):Ne(t,ze,r)}function $e(t,e,r,n){for(var i=r-1,s=t.length;++i<s;)if(n(t[i],e))return i;return-1}function ze(t){return t!=t}function Ue(t,e){var r=null==t?0:t.length;return r?Ke(t,e)/r:d}function Be(t){return function(e){return null==e?i:e[t]}}function Ve(t){return function(e){return null==t?i:t[e]}}function qe(t,e,r,n,i){return i(t,(function(t,i,s){r=n?(n=!1,t):e(r,t,i,s)})),r}function Ke(t,e){for(var r,n=-1,s=t.length;++n<s;){var o=e(t[n]);o!==i&&(r=r===i?o:r+o)}return r}function We(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}function He(t){return t?t.slice(0,hr(t)+1).replace(nt,""):t}function Ye(t){return function(e){return t(e)}}function Xe(t,e){return Re(e,(function(e){return t[e]}))}function Ze(t,e){return t.has(e)}function Je(t,e){for(var r=-1,n=t.length;++r<n&&Ge(e,t[r],0)>-1;);return r}function Qe(t,e){for(var r=t.length;r--&&Ge(e,t[r],0)>-1;);return r}var tr=Ve({À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"}),er=Ve({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"});function rr(t){return"\\"+oe[t]}function nr(t){return te.test(t)}function ir(t){var e=-1,r=Array(t.size);return t.forEach((function(t,n){r[++e]=[n,t]})),r}function sr(t,e){return function(r){return t(e(r))}}function or(t,e){for(var r=-1,n=t.length,i=0,s=[];++r<n;){var o=t[r];o!==e&&o!==a||(t[r]=a,s[i++]=r)}return s}function ar(t){var e=-1,r=Array(t.size);return t.forEach((function(t){r[++e]=t})),r}function lr(t){var e=-1,r=Array(t.size);return t.forEach((function(t){r[++e]=[t,t]})),r}function cr(t){return nr(t)?function(t){for(var e=Jt.lastIndex=0;Jt.test(t);)++e;return e}(t):Fe(t)}function ur(t){return nr(t)?function(t){return t.match(Jt)||[]}(t):function(t){return t.split("")}(t)}function hr(t){for(var e=t.length;e--&&it.test(t.charAt(e)););return e}var dr=Ve({"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"}),fr=function t(e){var r,n=(e=null==e?he:fr.defaults(he.Object(),e,fr.pick(he,re))).Array,it=e.Date,wt=e.Error,xt=e.Function,Et=e.Math,St=e.Object,At=e.RegExp,Pt=e.String,Tt=e.TypeError,Ct=n.prototype,Mt=xt.prototype,Ot=St.prototype,Rt=e["__core-js_shared__"],Dt=Mt.toString,It=Ot.hasOwnProperty,kt=0,Lt=(r=/[^.]+$/.exec(Rt&&Rt.keys&&Rt.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"",Ft=Ot.toString,jt=Dt.call(St),Nt=he._,Gt=At("^"+Dt.call(It).replace(et,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),$t=pe?e.Buffer:i,zt=e.Symbol,Ut=e.Uint8Array,Bt=$t?$t.allocUnsafe:i,Vt=sr(St.getPrototypeOf,St),qt=St.create,Kt=Ot.propertyIsEnumerable,Wt=Ct.splice,Ht=zt?zt.isConcatSpreadable:i,Yt=zt?zt.iterator:i,Jt=zt?zt.toStringTag:i,te=function(){try{var t=ls(St,"defineProperty");return t({},"",{}),t}catch(t){}}(),oe=e.clearTimeout!==he.clearTimeout&&e.clearTimeout,ce=it&&it.now!==he.Date.now&&it.now,ue=e.setTimeout!==he.setTimeout&&e.setTimeout,de=Et.ceil,fe=Et.floor,me=St.getOwnPropertySymbols,ge=$t?$t.isBuffer:i,Fe=e.isFinite,Ve=Ct.join,pr=sr(St.keys,St),mr=Et.max,gr=Et.min,yr=it.now,vr=e.parseInt,_r=Et.random,br=Ct.reverse,wr=ls(e,"DataView"),xr=ls(e,"Map"),Er=ls(e,"Promise"),Sr=ls(e,"Set"),Ar=ls(e,"WeakMap"),Pr=ls(St,"create"),Tr=Ar&&new Ar,Cr={},Mr=Fs(wr),Or=Fs(xr),Rr=Fs(Er),Dr=Fs(Sr),Ir=Fs(Ar),kr=zt?zt.prototype:i,Lr=kr?kr.valueOf:i,Fr=kr?kr.toString:i;function jr(t){if(ta(t)&&!Bo(t)&&!(t instanceof zr)){if(t instanceof $r)return t;if(It.call(t,"__wrapped__"))return js(t)}return new $r(t)}var Nr=function(){function t(){}return function(e){if(!Qo(e))return{};if(qt)return qt(e);t.prototype=e;var r=new t;return t.prototype=i,r}}();function Gr(){}function $r(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=i}function zr(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=f,this.__views__=[]}function Ur(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function Br(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function Vr(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}function qr(t){var e=-1,r=null==t?0:t.length;for(this.__data__=new Vr;++e<r;)this.add(t[e])}function Kr(t){var e=this.__data__=new Br(t);this.size=e.size}function Wr(t,e){var r=Bo(t),n=!r&&Uo(t),i=!r&&!n&&Wo(t),s=!r&&!n&&!i&&la(t),o=r||n||i||s,a=o?We(t.length,Pt):[],l=a.length;for(var c in t)!e&&!It.call(t,c)||o&&("length"==c||i&&("offset"==c||"parent"==c)||s&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||ms(c,l))||a.push(c);return a}function Hr(t){var e=t.length;return e?t[qn(0,e-1)]:i}function Yr(t,e){return Rs(Pi(t),sn(e,0,t.length))}function Xr(t){return Rs(Pi(t))}function Zr(t,e,r){(r!==i&&!Go(t[e],r)||r===i&&!(e in t))&&rn(t,e,r)}function Jr(t,e,r){var n=t[e];It.call(t,e)&&Go(n,r)&&(r!==i||e in t)||rn(t,e,r)}function Qr(t,e){for(var r=t.length;r--;)if(Go(t[r][0],e))return r;return-1}function tn(t,e,r,n){return un(t,(function(t,i,s){e(n,t,r(t),s)})),n}function en(t,e){return t&&Ti(e,Oa(e),t)}function rn(t,e,r){"__proto__"==e&&te?te(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}function nn(t,e){for(var r=-1,s=e.length,o=n(s),a=null==t;++r<s;)o[r]=a?i:Aa(t,e[r]);return o}function sn(t,e,r){return t==t&&(r!==i&&(t=t<=r?t:r),e!==i&&(t=t>=e?t:e)),t}function on(t,e,r,n,s,o){var a,l=1&e,c=2&e,u=4&e;if(r&&(a=s?r(t,n,s,o):r(t)),a!==i)return a;if(!Qo(t))return t;var h=Bo(t);if(h){if(a=function(t){var e=t.length,r=new t.constructor(e);return e&&"string"==typeof t[0]&&It.call(t,"index")&&(r.index=t.index,r.input=t.input),r}(t),!l)return Pi(t,a)}else{var d=hs(t),f=d==b||d==w;if(Wo(t))return bi(t,l);if(d==S||d==m||f&&!s){if(a=c||f?{}:fs(t),!l)return c?function(t,e){return Ti(t,us(t),e)}(t,function(t,e){return t&&Ti(e,Ra(e),t)}(a,t)):function(t,e){return Ti(t,cs(t),e)}(t,en(a,t))}else{if(!se[d])return s?t:{};a=function(t,e,r){var n,i=t.constructor;switch(e){case R:return wi(t);case y:case v:return new i(+t);case D:return function(t,e){var r=e?wi(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}(t,r);case I:case k:case L:case F:case j:case N:case G:case $:case z:return xi(t,r);case x:return new i;case E:case C:return new i(t);case P:return function(t){var e=new t.constructor(t.source,dt.exec(t));return e.lastIndex=t.lastIndex,e}(t);case T:return new i;case M:return n=t,Lr?St(Lr.call(n)):{}}}(t,d,l)}}o||(o=new Kr);var p=o.get(t);if(p)return p;o.set(t,a),sa(t)?t.forEach((function(n){a.add(on(n,e,r,n,t,o))})):ea(t)&&t.forEach((function(n,i){a.set(i,on(n,e,r,i,t,o))}));var g=h?i:(u?c?es:ts:c?Ra:Oa)(t);return Ae(g||t,(function(n,i){g&&(n=t[i=n]),Jr(a,i,on(n,e,r,i,t,o))})),a}function an(t,e,r){var n=r.length;if(null==t)return!n;for(t=St(t);n--;){var s=r[n],o=e[s],a=t[s];if(a===i&&!(s in t)||!o(a))return!1}return!0}function ln(t,e,r){if("function"!=typeof t)throw new Tt(s);return Ts((function(){t.apply(i,r)}),e)}function cn(t,e,r,n){var i=-1,s=Me,o=!0,a=t.length,l=[],c=e.length;if(!a)return l;r&&(e=Re(e,Ye(r))),n?(s=Oe,o=!1):e.length>=200&&(s=Ze,o=!1,e=new qr(e));t:for(;++i<a;){var u=t[i],h=null==r?u:r(u);if(u=n||0!==u?u:0,o&&h==h){for(var d=c;d--;)if(e[d]===h)continue t;l.push(u)}else s(e,h,n)||l.push(u)}return l}jr.templateSettings={escape:Y,evaluate:X,interpolate:Z,variable:"",imports:{_:jr}},jr.prototype=Gr.prototype,jr.prototype.constructor=jr,$r.prototype=Nr(Gr.prototype),$r.prototype.constructor=$r,zr.prototype=Nr(Gr.prototype),zr.prototype.constructor=zr,Ur.prototype.clear=function(){this.__data__=Pr?Pr(null):{},this.size=0},Ur.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},Ur.prototype.get=function(t){var e=this.__data__;if(Pr){var r=e[t];return r===o?i:r}return It.call(e,t)?e[t]:i},Ur.prototype.has=function(t){var e=this.__data__;return Pr?e[t]!==i:It.call(e,t)},Ur.prototype.set=function(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Pr&&e===i?o:e,this},Br.prototype.clear=function(){this.__data__=[],this.size=0},Br.prototype.delete=function(t){var e=this.__data__,r=Qr(e,t);return!(r<0||(r==e.length-1?e.pop():Wt.call(e,r,1),--this.size,0))},Br.prototype.get=function(t){var e=this.__data__,r=Qr(e,t);return r<0?i:e[r][1]},Br.prototype.has=function(t){return Qr(this.__data__,t)>-1},Br.prototype.set=function(t,e){var r=this.__data__,n=Qr(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this},Vr.prototype.clear=function(){this.size=0,this.__data__={hash:new Ur,map:new(xr||Br),string:new Ur}},Vr.prototype.delete=function(t){var e=os(this,t).delete(t);return this.size-=e?1:0,e},Vr.prototype.get=function(t){return os(this,t).get(t)},Vr.prototype.has=function(t){return os(this,t).has(t)},Vr.prototype.set=function(t,e){var r=os(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this},qr.prototype.add=qr.prototype.push=function(t){return this.__data__.set(t,o),this},qr.prototype.has=function(t){return this.__data__.has(t)},Kr.prototype.clear=function(){this.__data__=new Br,this.size=0},Kr.prototype.delete=function(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r},Kr.prototype.get=function(t){return this.__data__.get(t)},Kr.prototype.has=function(t){return this.__data__.has(t)},Kr.prototype.set=function(t,e){var r=this.__data__;if(r instanceof Br){var n=r.__data__;if(!xr||n.length<199)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new Vr(n)}return r.set(t,e),this.size=r.size,this};var un=Oi(vn),hn=Oi(_n,!0);function dn(t,e){var r=!0;return un(t,(function(t,n,i){return r=!!e(t,n,i)})),r}function fn(t,e,r){for(var n=-1,s=t.length;++n<s;){var o=t[n],a=e(o);if(null!=a&&(l===i?a==a&&!aa(a):r(a,l)))var l=a,c=o}return c}function pn(t,e){var r=[];return un(t,(function(t,n,i){e(t,n,i)&&r.push(t)})),r}function mn(t,e,r,n,i){var s=-1,o=t.length;for(r||(r=ps),i||(i=[]);++s<o;){var a=t[s];e>0&&r(a)?e>1?mn(a,e-1,r,n,i):De(i,a):n||(i[i.length]=a)}return i}var gn=Ri(),yn=Ri(!0);function vn(t,e){return t&&gn(t,e,Oa)}function _n(t,e){return t&&yn(t,e,Oa)}function bn(t,e){return Ce(e,(function(e){return Xo(t[e])}))}function wn(t,e){for(var r=0,n=(e=gi(e,t)).length;null!=t&&r<n;)t=t[Ls(e[r++])];return r&&r==n?t:i}function xn(t,e,r){var n=e(t);return Bo(t)?n:De(n,r(t))}function En(t){return null==t?t===i?"[object Undefined]":"[object Null]":Jt&&Jt in St(t)?function(t){var e=It.call(t,Jt),r=t[Jt];try{t[Jt]=i;var n=!0}catch(t){}var s=Ft.call(t);return n&&(e?t[Jt]=r:delete t[Jt]),s}(t):function(t){return Ft.call(t)}(t)}function Sn(t,e){return t>e}function An(t,e){return null!=t&&It.call(t,e)}function Pn(t,e){return null!=t&&e in St(t)}function Tn(t,e,r){for(var s=r?Oe:Me,o=t[0].length,a=t.length,l=a,c=n(a),u=1/0,h=[];l--;){var d=t[l];l&&e&&(d=Re(d,Ye(e))),u=gr(d.length,u),c[l]=!r&&(e||o>=120&&d.length>=120)?new qr(l&&d):i}d=t[0];var f=-1,p=c[0];t:for(;++f<o&&h.length<u;){var m=d[f],g=e?e(m):m;if(m=r||0!==m?m:0,!(p?Ze(p,g):s(h,g,r))){for(l=a;--l;){var y=c[l];if(!(y?Ze(y,g):s(t[l],g,r)))continue t}p&&p.push(g),h.push(m)}}return h}function Cn(t,e,r){var n=null==(t=Ss(t,e=gi(e,t)))?t:t[Ls(Hs(e))];return null==n?i:Ee(n,t,r)}function Mn(t){return ta(t)&&En(t)==m}function On(t,e,r,n,s){return t===e||(null==t||null==e||!ta(t)&&!ta(e)?t!=t&&e!=e:function(t,e,r,n,s,o){var a=Bo(t),l=Bo(e),c=a?g:hs(t),u=l?g:hs(e),h=(c=c==m?S:c)==S,d=(u=u==m?S:u)==S,f=c==u;if(f&&Wo(t)){if(!Wo(e))return!1;a=!0,h=!1}if(f&&!h)return o||(o=new Kr),a||la(t)?Ji(t,e,r,n,s,o):function(t,e,r,n,i,s,o){switch(r){case D:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case R:return!(t.byteLength!=e.byteLength||!s(new Ut(t),new Ut(e)));case y:case v:case E:return Go(+t,+e);case _:return t.name==e.name&&t.message==e.message;case P:case C:return t==e+"";case x:var a=ir;case T:var l=1&n;if(a||(a=ar),t.size!=e.size&&!l)return!1;var c=o.get(t);if(c)return c==e;n|=2,o.set(t,e);var u=Ji(a(t),a(e),n,i,s,o);return o.delete(t),u;case M:if(Lr)return Lr.call(t)==Lr.call(e)}return!1}(t,e,c,r,n,s,o);if(!(1&r)){var p=h&&It.call(t,"__wrapped__"),b=d&&It.call(e,"__wrapped__");if(p||b){var w=p?t.value():t,A=b?e.value():e;return o||(o=new Kr),s(w,A,r,n,o)}}return!!f&&(o||(o=new Kr),function(t,e,r,n,s,o){var a=1&r,l=ts(t),c=l.length;if(c!=ts(e).length&&!a)return!1;for(var u=c;u--;){var h=l[u];if(!(a?h in e:It.call(e,h)))return!1}var d=o.get(t),f=o.get(e);if(d&&f)return d==e&&f==t;var p=!0;o.set(t,e),o.set(e,t);for(var m=a;++u<c;){var g=t[h=l[u]],y=e[h];if(n)var v=a?n(y,g,h,e,t,o):n(g,y,h,t,e,o);if(!(v===i?g===y||s(g,y,r,n,o):v)){p=!1;break}m||(m="constructor"==h)}if(p&&!m){var _=t.constructor,b=e.constructor;_==b||!("constructor"in t)||!("constructor"in e)||"function"==typeof _&&_ instanceof _&&"function"==typeof b&&b instanceof b||(p=!1)}return o.delete(t),o.delete(e),p}(t,e,r,n,s,o))}(t,e,r,n,On,s))}function Rn(t,e,r,n){var s=r.length,o=s,a=!n;if(null==t)return!o;for(t=St(t);s--;){var l=r[s];if(a&&l[2]?l[1]!==t[l[0]]:!(l[0]in t))return!1}for(;++s<o;){var c=(l=r[s])[0],u=t[c],h=l[1];if(a&&l[2]){if(u===i&&!(c in t))return!1}else{var d=new Kr;if(n)var f=n(u,h,c,t,e,d);if(!(f===i?On(h,u,3,n,d):f))return!1}}return!0}function Dn(t){return!(!Qo(t)||(e=t,Lt&&Lt in e))&&(Xo(t)?Gt:mt).test(Fs(t));var e}function In(t){return"function"==typeof t?t:null==t?rl:"object"==typeof t?Bo(t)?Nn(t[0],t[1]):jn(t):hl(t)}function kn(t){if(!bs(t))return pr(t);var e=[];for(var r in St(t))It.call(t,r)&&"constructor"!=r&&e.push(r);return e}function Ln(t,e){return t<e}function Fn(t,e){var r=-1,i=qo(t)?n(t.length):[];return un(t,(function(t,n,s){i[++r]=e(t,n,s)})),i}function jn(t){var e=as(t);return 1==e.length&&e[0][2]?xs(e[0][0],e[0][1]):function(r){return r===t||Rn(r,t,e)}}function Nn(t,e){return ys(t)&&ws(e)?xs(Ls(t),e):function(r){var n=Aa(r,t);return n===i&&n===e?Pa(r,t):On(e,n,3)}}function Gn(t,e,r,n,s){t!==e&&gn(e,(function(o,a){if(s||(s=new Kr),Qo(o))!function(t,e,r,n,s,o,a){var l=As(t,r),c=As(e,r),u=a.get(c);if(u)Zr(t,r,u);else{var h=o?o(l,c,r+"",t,e,a):i,d=h===i;if(d){var f=Bo(c),p=!f&&Wo(c),m=!f&&!p&&la(c);h=c,f||p||m?Bo(l)?h=l:Ko(l)?h=Pi(l):p?(d=!1,h=bi(c,!0)):m?(d=!1,h=xi(c,!0)):h=[]:na(c)||Uo(c)?(h=l,Uo(l)?h=ga(l):Qo(l)&&!Xo(l)||(h=fs(c))):d=!1}d&&(a.set(c,h),s(h,c,n,o,a),a.delete(c)),Zr(t,r,h)}}(t,e,a,r,Gn,n,s);else{var l=n?n(As(t,a),o,a+"",t,e,s):i;l===i&&(l=o),Zr(t,a,l)}}),Ra)}function $n(t,e){var r=t.length;if(r)return ms(e+=e<0?r:0,r)?t[e]:i}function zn(t,e,r){e=e.length?Re(e,(function(t){return Bo(t)?function(e){return wn(e,1===t.length?t[0]:t)}:t})):[rl];var n=-1;e=Re(e,Ye(ss()));var i=Fn(t,(function(t,r,i){var s=Re(e,(function(e){return e(t)}));return{criteria:s,index:++n,value:t}}));return function(t){var e=t.length;for(t.sort((function(t,e){return function(t,e,r){for(var n=-1,i=t.criteria,s=e.criteria,o=i.length,a=r.length;++n<o;){var l=Ei(i[n],s[n]);if(l)return n>=a?l:l*("desc"==r[n]?-1:1)}return t.index-e.index}(t,e,r)}));e--;)t[e]=t[e].value;return t}(i)}function Un(t,e,r){for(var n=-1,i=e.length,s={};++n<i;){var o=e[n],a=wn(t,o);r(a,o)&&Xn(s,gi(o,t),a)}return s}function Bn(t,e,r,n){var i=n?$e:Ge,s=-1,o=e.length,a=t;for(t===e&&(e=Pi(e)),r&&(a=Re(t,Ye(r)));++s<o;)for(var l=0,c=e[s],u=r?r(c):c;(l=i(a,u,l,n))>-1;)a!==t&&Wt.call(a,l,1),Wt.call(t,l,1);return t}function Vn(t,e){for(var r=t?e.length:0,n=r-1;r--;){var i=e[r];if(r==n||i!==s){var s=i;ms(i)?Wt.call(t,i,1):li(t,i)}}return t}function qn(t,e){return t+fe(_r()*(e-t+1))}function Kn(t,e){var r="";if(!t||e<1||e>h)return r;do{e%2&&(r+=t),(e=fe(e/2))&&(t+=t)}while(e);return r}function Wn(t,e){return Cs(Es(t,e,rl),t+"")}function Hn(t){return Hr(Ga(t))}function Yn(t,e){var r=Ga(t);return Rs(r,sn(e,0,r.length))}function Xn(t,e,r,n){if(!Qo(t))return t;for(var s=-1,o=(e=gi(e,t)).length,a=o-1,l=t;null!=l&&++s<o;){var c=Ls(e[s]),u=r;if("__proto__"===c||"constructor"===c||"prototype"===c)return t;if(s!=a){var h=l[c];(u=n?n(h,c,l):i)===i&&(u=Qo(h)?h:ms(e[s+1])?[]:{})}Jr(l,c,u),l=l[c]}return t}var Zn=Tr?function(t,e){return Tr.set(t,e),t}:rl,Jn=te?function(t,e){return te(t,"toString",{configurable:!0,enumerable:!1,value:Qa(e),writable:!0})}:rl;function Qn(t){return Rs(Ga(t))}function ti(t,e,r){var i=-1,s=t.length;e<0&&(e=-e>s?0:s+e),(r=r>s?s:r)<0&&(r+=s),s=e>r?0:r-e>>>0,e>>>=0;for(var o=n(s);++i<s;)o[i]=t[i+e];return o}function ei(t,e){var r;return un(t,(function(t,n,i){return!(r=e(t,n,i))})),!!r}function ri(t,e,r){var n=0,i=null==t?n:t.length;if("number"==typeof e&&e==e&&i<=2147483647){for(;n<i;){var s=n+i>>>1,o=t[s];null!==o&&!aa(o)&&(r?o<=e:o<e)?n=s+1:i=s}return i}return ni(t,e,rl,r)}function ni(t,e,r,n){var s=0,o=null==t?0:t.length;if(0===o)return 0;for(var a=(e=r(e))!=e,l=null===e,c=aa(e),u=e===i;s<o;){var h=fe((s+o)/2),d=r(t[h]),f=d!==i,p=null===d,m=d==d,g=aa(d);if(a)var y=n||m;else y=u?m&&(n||f):l?m&&f&&(n||!p):c?m&&f&&!p&&(n||!g):!p&&!g&&(n?d<=e:d<e);y?s=h+1:o=h}return gr(o,4294967294)}function ii(t,e){for(var r=-1,n=t.length,i=0,s=[];++r<n;){var o=t[r],a=e?e(o):o;if(!r||!Go(a,l)){var l=a;s[i++]=0===o?0:o}}return s}function si(t){return"number"==typeof t?t:aa(t)?d:+t}function oi(t){if("string"==typeof t)return t;if(Bo(t))return Re(t,oi)+"";if(aa(t))return Fr?Fr.call(t):"";var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function ai(t,e,r){var n=-1,i=Me,s=t.length,o=!0,a=[],l=a;if(r)o=!1,i=Oe;else if(s>=200){var c=e?null:Ki(t);if(c)return ar(c);o=!1,i=Ze,l=new qr}else l=e?[]:a;t:for(;++n<s;){var u=t[n],h=e?e(u):u;if(u=r||0!==u?u:0,o&&h==h){for(var d=l.length;d--;)if(l[d]===h)continue t;e&&l.push(h),a.push(u)}else i(l,h,r)||(l!==a&&l.push(h),a.push(u))}return a}function li(t,e){return null==(t=Ss(t,e=gi(e,t)))||delete t[Ls(Hs(e))]}function ci(t,e,r,n){return Xn(t,e,r(wn(t,e)),n)}function ui(t,e,r,n){for(var i=t.length,s=n?i:-1;(n?s--:++s<i)&&e(t[s],s,t););return r?ti(t,n?0:s,n?s+1:i):ti(t,n?s+1:0,n?i:s)}function hi(t,e){var r=t;return r instanceof zr&&(r=r.value()),Ie(e,(function(t,e){return e.func.apply(e.thisArg,De([t],e.args))}),r)}function di(t,e,r){var i=t.length;if(i<2)return i?ai(t[0]):[];for(var s=-1,o=n(i);++s<i;)for(var a=t[s],l=-1;++l<i;)l!=s&&(o[s]=cn(o[s]||a,t[l],e,r));return ai(mn(o,1),e,r)}function fi(t,e,r){for(var n=-1,s=t.length,o=e.length,a={};++n<s;){var l=n<o?e[n]:i;r(a,t[n],l)}return a}function pi(t){return Ko(t)?t:[]}function mi(t){return"function"==typeof t?t:rl}function gi(t,e){return Bo(t)?t:ys(t,e)?[t]:ks(ya(t))}var yi=Wn;function vi(t,e,r){var n=t.length;return r=r===i?n:r,!e&&r>=n?t:ti(t,e,r)}var _i=oe||function(t){return he.clearTimeout(t)};function bi(t,e){if(e)return t.slice();var r=t.length,n=Bt?Bt(r):new t.constructor(r);return t.copy(n),n}function wi(t){var e=new t.constructor(t.byteLength);return new Ut(e).set(new Ut(t)),e}function xi(t,e){var r=e?wi(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}function Ei(t,e){if(t!==e){var r=t!==i,n=null===t,s=t==t,o=aa(t),a=e!==i,l=null===e,c=e==e,u=aa(e);if(!l&&!u&&!o&&t>e||o&&a&&c&&!l&&!u||n&&a&&c||!r&&c||!s)return 1;if(!n&&!o&&!u&&t<e||u&&r&&s&&!n&&!o||l&&r&&s||!a&&s||!c)return-1}return 0}function Si(t,e,r,i){for(var s=-1,o=t.length,a=r.length,l=-1,c=e.length,u=mr(o-a,0),h=n(c+u),d=!i;++l<c;)h[l]=e[l];for(;++s<a;)(d||s<o)&&(h[r[s]]=t[s]);for(;u--;)h[l++]=t[s++];return h}function Ai(t,e,r,i){for(var s=-1,o=t.length,a=-1,l=r.length,c=-1,u=e.length,h=mr(o-l,0),d=n(h+u),f=!i;++s<h;)d[s]=t[s];for(var p=s;++c<u;)d[p+c]=e[c];for(;++a<l;)(f||s<o)&&(d[p+r[a]]=t[s++]);return d}function Pi(t,e){var r=-1,i=t.length;for(e||(e=n(i));++r<i;)e[r]=t[r];return e}function Ti(t,e,r,n){var s=!r;r||(r={});for(var o=-1,a=e.length;++o<a;){var l=e[o],c=n?n(r[l],t[l],l,r,t):i;c===i&&(c=t[l]),s?rn(r,l,c):Jr(r,l,c)}return r}function Ci(t,e){return function(r,n){var i=Bo(r)?Se:tn,s=e?e():{};return i(r,t,ss(n,2),s)}}function Mi(t){return Wn((function(e,r){var n=-1,s=r.length,o=s>1?r[s-1]:i,a=s>2?r[2]:i;for(o=t.length>3&&"function"==typeof o?(s--,o):i,a&&gs(r[0],r[1],a)&&(o=s<3?i:o,s=1),e=St(e);++n<s;){var l=r[n];l&&t(e,l,n,o)}return e}))}function Oi(t,e){return function(r,n){if(null==r)return r;if(!qo(r))return t(r,n);for(var i=r.length,s=e?i:-1,o=St(r);(e?s--:++s<i)&&!1!==n(o[s],s,o););return r}}function Ri(t){return function(e,r,n){for(var i=-1,s=St(e),o=n(e),a=o.length;a--;){var l=o[t?a:++i];if(!1===r(s[l],l,s))break}return e}}function Di(t){return function(e){var r=nr(e=ya(e))?ur(e):i,n=r?r[0]:e.charAt(0),s=r?vi(r,1).join(""):e.slice(1);return n[t]()+s}}function Ii(t){return function(e){return Ie(Xa(Ua(e).replace(Xt,"")),t,"")}}function ki(t){return function(){var e=arguments;switch(e.length){case 0:return new t;case 1:return new t(e[0]);case 2:return new t(e[0],e[1]);case 3:return new t(e[0],e[1],e[2]);case 4:return new t(e[0],e[1],e[2],e[3]);case 5:return new t(e[0],e[1],e[2],e[3],e[4]);case 6:return new t(e[0],e[1],e[2],e[3],e[4],e[5]);case 7:return new t(e[0],e[1],e[2],e[3],e[4],e[5],e[6])}var r=Nr(t.prototype),n=t.apply(r,e);return Qo(n)?n:r}}function Li(t){return function(e,r,n){var s=St(e);if(!qo(e)){var o=ss(r,3);e=Oa(e),r=function(t){return o(s[t],t,s)}}var a=t(e,r,n);return a>-1?s[o?e[a]:a]:i}}function Fi(t){return Qi((function(e){var r=e.length,n=r,o=$r.prototype.thru;for(t&&e.reverse();n--;){var a=e[n];if("function"!=typeof a)throw new Tt(s);if(o&&!l&&"wrapper"==ns(a))var l=new $r([],!0)}for(n=l?n:r;++n<r;){var c=ns(a=e[n]),u="wrapper"==c?rs(a):i;l=u&&vs(u[0])&&424==u[1]&&!u[4].length&&1==u[9]?l[ns(u[0])].apply(l,u[3]):1==a.length&&vs(a)?l[c]():l.thru(a)}return function(){var t=arguments,n=t[0];if(l&&1==t.length&&Bo(n))return l.plant(n).value();for(var i=0,s=r?e[i].apply(this,t):n;++i<r;)s=e[i].call(this,s);return s}}))}function ji(t,e,r,s,o,a,l,u,h,d){var f=e&c,p=1&e,m=2&e,g=24&e,y=512&e,v=m?i:ki(t);return function c(){for(var _=arguments.length,b=n(_),w=_;w--;)b[w]=arguments[w];if(g)var x=is(c),E=function(t,e){for(var r=t.length,n=0;r--;)t[r]===e&&++n;return n}(b,x);if(s&&(b=Si(b,s,o,g)),a&&(b=Ai(b,a,l,g)),_-=E,g&&_<d){var S=or(b,x);return Vi(t,e,ji,c.placeholder,r,b,S,u,h,d-_)}var A=p?r:this,P=m?A[t]:t;return _=b.length,u?b=function(t,e){for(var r=t.length,n=gr(e.length,r),s=Pi(t);n--;){var o=e[n];t[n]=ms(o,r)?s[o]:i}return t}(b,u):y&&_>1&&b.reverse(),f&&h<_&&(b.length=h),this&&this!==he&&this instanceof c&&(P=v||ki(P)),P.apply(A,b)}}function Ni(t,e){return function(r,n){return function(t,e,r,n){return vn(t,(function(t,i,s){e(n,r(t),i,s)})),n}(r,t,e(n),{})}}function Gi(t,e){return function(r,n){var s;if(r===i&&n===i)return e;if(r!==i&&(s=r),n!==i){if(s===i)return n;"string"==typeof r||"string"==typeof n?(r=oi(r),n=oi(n)):(r=si(r),n=si(n)),s=t(r,n)}return s}}function $i(t){return Qi((function(e){return e=Re(e,Ye(ss())),Wn((function(r){var n=this;return t(e,(function(t){return Ee(t,n,r)}))}))}))}function zi(t,e){var r=(e=e===i?" ":oi(e)).length;if(r<2)return r?Kn(e,t):e;var n=Kn(e,de(t/cr(e)));return nr(e)?vi(ur(n),0,t).join(""):n.slice(0,t)}function Ui(t){return function(e,r,s){return s&&"number"!=typeof s&&gs(e,r,s)&&(r=s=i),e=da(e),r===i?(r=e,e=0):r=da(r),function(t,e,r,i){for(var s=-1,o=mr(de((e-t)/(r||1)),0),a=n(o);o--;)a[i?o:++s]=t,t+=r;return a}(e,r,s=s===i?e<r?1:-1:da(s),t)}}function Bi(t){return function(e,r){return"string"==typeof e&&"string"==typeof r||(e=ma(e),r=ma(r)),t(e,r)}}function Vi(t,e,r,n,s,o,a,c,u,h){var d=8&e;e|=d?l:64,4&(e&=~(d?64:l))||(e&=-4);var f=[t,e,s,d?o:i,d?a:i,d?i:o,d?i:a,c,u,h],p=r.apply(i,f);return vs(t)&&Ps(p,f),p.placeholder=n,Ms(p,t,e)}function qi(t){var e=Et[t];return function(t,r){if(t=ma(t),(r=null==r?0:gr(fa(r),292))&&Fe(t)){var n=(ya(t)+"e").split("e");return+((n=(ya(e(n[0]+"e"+(+n[1]+r)))+"e").split("e"))[0]+"e"+(+n[1]-r))}return e(t)}}var Ki=Sr&&1/ar(new Sr([,-0]))[1]==u?function(t){return new Sr(t)}:al;function Wi(t){return function(e){var r=hs(e);return r==x?ir(e):r==T?lr(e):function(t,e){return Re(e,(function(e){return[e,t[e]]}))}(e,t(e))}}function Hi(t,e,r,o,u,h,d,f){var p=2&e;if(!p&&"function"!=typeof t)throw new Tt(s);var m=o?o.length:0;if(m||(e&=-97,o=u=i),d=d===i?d:mr(fa(d),0),f=f===i?f:fa(f),m-=u?u.length:0,64&e){var g=o,y=u;o=u=i}var v=p?i:rs(t),_=[t,e,r,o,u,g,y,h,d,f];if(v&&function(t,e){var r=t[1],n=e[1],i=r|n,s=i<131,o=n==c&&8==r||n==c&&256==r&&t[7].length<=e[8]||384==n&&e[7].length<=e[8]&&8==r;if(!s&&!o)return t;1&n&&(t[2]=e[2],i|=1&r?0:4);var l=e[3];if(l){var u=t[3];t[3]=u?Si(u,l,e[4]):l,t[4]=u?or(t[3],a):e[4]}(l=e[5])&&(u=t[5],t[5]=u?Ai(u,l,e[6]):l,t[6]=u?or(t[5],a):e[6]),(l=e[7])&&(t[7]=l),n&c&&(t[8]=null==t[8]?e[8]:gr(t[8],e[8])),null==t[9]&&(t[9]=e[9]),t[0]=e[0],t[1]=i}(_,v),t=_[0],e=_[1],r=_[2],o=_[3],u=_[4],!(f=_[9]=_[9]===i?p?0:t.length:mr(_[9]-m,0))&&24&e&&(e&=-25),e&&1!=e)b=8==e||16==e?function(t,e,r){var s=ki(t);return function o(){for(var a=arguments.length,l=n(a),c=a,u=is(o);c--;)l[c]=arguments[c];var h=a<3&&l[0]!==u&&l[a-1]!==u?[]:or(l,u);return(a-=h.length)<r?Vi(t,e,ji,o.placeholder,i,l,h,i,i,r-a):Ee(this&&this!==he&&this instanceof o?s:t,this,l)}}(t,e,f):e!=l&&33!=e||u.length?ji.apply(i,_):function(t,e,r,i){var s=1&e,o=ki(t);return function e(){for(var a=-1,l=arguments.length,c=-1,u=i.length,h=n(u+l),d=this&&this!==he&&this instanceof e?o:t;++c<u;)h[c]=i[c];for(;l--;)h[c++]=arguments[++a];return Ee(d,s?r:this,h)}}(t,e,r,o);else var b=function(t,e,r){var n=1&e,i=ki(t);return function e(){return(this&&this!==he&&this instanceof e?i:t).apply(n?r:this,arguments)}}(t,e,r);return Ms((v?Zn:Ps)(b,_),t,e)}function Yi(t,e,r,n){return t===i||Go(t,Ot[r])&&!It.call(n,r)?e:t}function Xi(t,e,r,n,s,o){return Qo(t)&&Qo(e)&&(o.set(e,t),Gn(t,e,i,Xi,o),o.delete(e)),t}function Zi(t){return na(t)?i:t}function Ji(t,e,r,n,s,o){var a=1&r,l=t.length,c=e.length;if(l!=c&&!(a&&c>l))return!1;var u=o.get(t),h=o.get(e);if(u&&h)return u==e&&h==t;var d=-1,f=!0,p=2&r?new qr:i;for(o.set(t,e),o.set(e,t);++d<l;){var m=t[d],g=e[d];if(n)var y=a?n(g,m,d,e,t,o):n(m,g,d,t,e,o);if(y!==i){if(y)continue;f=!1;break}if(p){if(!Le(e,(function(t,e){if(!Ze(p,e)&&(m===t||s(m,t,r,n,o)))return p.push(e)}))){f=!1;break}}else if(m!==g&&!s(m,g,r,n,o)){f=!1;break}}return o.delete(t),o.delete(e),f}function Qi(t){return Cs(Es(t,i,Bs),t+"")}function ts(t){return xn(t,Oa,cs)}function es(t){return xn(t,Ra,us)}var rs=Tr?function(t){return Tr.get(t)}:al;function ns(t){for(var e=t.name+"",r=Cr[e],n=It.call(Cr,e)?r.length:0;n--;){var i=r[n],s=i.func;if(null==s||s==t)return i.name}return e}function is(t){return(It.call(jr,"placeholder")?jr:t).placeholder}function ss(){var t=jr.iteratee||nl;return t=t===nl?In:t,arguments.length?t(arguments[0],arguments[1]):t}function os(t,e){var r,n,i=t.__data__;return("string"==(n=typeof(r=e))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?i["string"==typeof e?"string":"hash"]:i.map}function as(t){for(var e=Oa(t),r=e.length;r--;){var n=e[r],i=t[n];e[r]=[n,i,ws(i)]}return e}function ls(t,e){var r=function(t,e){return null==t?i:t[e]}(t,e);return Dn(r)?r:i}var cs=me?function(t){return null==t?[]:(t=St(t),Ce(me(t),(function(e){return Kt.call(t,e)})))}:pl,us=me?function(t){for(var e=[];t;)De(e,cs(t)),t=Vt(t);return e}:pl,hs=En;function ds(t,e,r){for(var n=-1,i=(e=gi(e,t)).length,s=!1;++n<i;){var o=Ls(e[n]);if(!(s=null!=t&&r(t,o)))break;t=t[o]}return s||++n!=i?s:!!(i=null==t?0:t.length)&&Jo(i)&&ms(o,i)&&(Bo(t)||Uo(t))}function fs(t){return"function"!=typeof t.constructor||bs(t)?{}:Nr(Vt(t))}function ps(t){return Bo(t)||Uo(t)||!!(Ht&&t&&t[Ht])}function ms(t,e){var r=typeof t;return!!(e=null==e?h:e)&&("number"==r||"symbol"!=r&&yt.test(t))&&t>-1&&t%1==0&&t<e}function gs(t,e,r){if(!Qo(r))return!1;var n=typeof e;return!!("number"==n?qo(r)&&ms(e,r.length):"string"==n&&e in r)&&Go(r[e],t)}function ys(t,e){if(Bo(t))return!1;var r=typeof t;return!("number"!=r&&"symbol"!=r&&"boolean"!=r&&null!=t&&!aa(t))||Q.test(t)||!J.test(t)||null!=e&&t in St(e)}function vs(t){var e=ns(t),r=jr[e];if("function"!=typeof r||!(e in zr.prototype))return!1;if(t===r)return!0;var n=rs(r);return!!n&&t===n[0]}(wr&&hs(new wr(new ArrayBuffer(1)))!=D||xr&&hs(new xr)!=x||Er&&hs(Er.resolve())!=A||Sr&&hs(new Sr)!=T||Ar&&hs(new Ar)!=O)&&(hs=function(t){var e=En(t),r=e==S?t.constructor:i,n=r?Fs(r):"";if(n)switch(n){case Mr:return D;case Or:return x;case Rr:return A;case Dr:return T;case Ir:return O}return e});var _s=Rt?Xo:ml;function bs(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||Ot)}function ws(t){return t==t&&!Qo(t)}function xs(t,e){return function(r){return null!=r&&r[t]===e&&(e!==i||t in St(r))}}function Es(t,e,r){return e=mr(e===i?t.length-1:e,0),function(){for(var i=arguments,s=-1,o=mr(i.length-e,0),a=n(o);++s<o;)a[s]=i[e+s];s=-1;for(var l=n(e+1);++s<e;)l[s]=i[s];return l[e]=r(a),Ee(t,this,l)}}function Ss(t,e){return e.length<2?t:wn(t,ti(e,0,-1))}function As(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}var Ps=Os(Zn),Ts=ue||function(t,e){return he.setTimeout(t,e)},Cs=Os(Jn);function Ms(t,e,r){var n=e+"";return Cs(t,function(t,e){var r=e.length;if(!r)return t;var n=r-1;return e[n]=(r>1?"& ":"")+e[n],e=e.join(r>2?", ":" "),t.replace(st,"{\n/* [wrapped with "+e+"] */\n")}(n,function(t,e){return Ae(p,(function(r){var n="_."+r[0];e&r[1]&&!Me(t,n)&&t.push(n)})),t.sort()}(function(t){var e=t.match(ot);return e?e[1].split(at):[]}(n),r)))}function Os(t){var e=0,r=0;return function(){var n=yr(),s=16-(n-r);if(r=n,s>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(i,arguments)}}function Rs(t,e){var r=-1,n=t.length,s=n-1;for(e=e===i?n:e;++r<e;){var o=qn(r,s),a=t[o];t[o]=t[r],t[r]=a}return t.length=e,t}var Ds,Is,ks=(Ds=Io((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(tt,(function(t,r,n,i){e.push(n?i.replace(ut,"$1"):r||t)})),e}),(function(t){return 500===Is.size&&Is.clear(),t})),Is=Ds.cache,Ds);function Ls(t){if("string"==typeof t||aa(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}function Fs(t){if(null!=t){try{return Dt.call(t)}catch(t){}try{return t+""}catch(t){}}return""}function js(t){if(t instanceof zr)return t.clone();var e=new $r(t.__wrapped__,t.__chain__);return e.__actions__=Pi(t.__actions__),e.__index__=t.__index__,e.__values__=t.__values__,e}var Ns=Wn((function(t,e){return Ko(t)?cn(t,mn(e,1,Ko,!0)):[]})),Gs=Wn((function(t,e){var r=Hs(e);return Ko(r)&&(r=i),Ko(t)?cn(t,mn(e,1,Ko,!0),ss(r,2)):[]})),$s=Wn((function(t,e){var r=Hs(e);return Ko(r)&&(r=i),Ko(t)?cn(t,mn(e,1,Ko,!0),i,r):[]}));function zs(t,e,r){var n=null==t?0:t.length;if(!n)return-1;var i=null==r?0:fa(r);return i<0&&(i=mr(n+i,0)),Ne(t,ss(e,3),i)}function Us(t,e,r){var n=null==t?0:t.length;if(!n)return-1;var s=n-1;return r!==i&&(s=fa(r),s=r<0?mr(n+s,0):gr(s,n-1)),Ne(t,ss(e,3),s,!0)}function Bs(t){return null!=t&&t.length?mn(t,1):[]}function Vs(t){return t&&t.length?t[0]:i}var qs=Wn((function(t){var e=Re(t,pi);return e.length&&e[0]===t[0]?Tn(e):[]})),Ks=Wn((function(t){var e=Hs(t),r=Re(t,pi);return e===Hs(r)?e=i:r.pop(),r.length&&r[0]===t[0]?Tn(r,ss(e,2)):[]})),Ws=Wn((function(t){var e=Hs(t),r=Re(t,pi);return(e="function"==typeof e?e:i)&&r.pop(),r.length&&r[0]===t[0]?Tn(r,i,e):[]}));function Hs(t){var e=null==t?0:t.length;return e?t[e-1]:i}var Ys=Wn(Xs);function Xs(t,e){return t&&t.length&&e&&e.length?Bn(t,e):t}var Zs=Qi((function(t,e){var r=null==t?0:t.length,n=nn(t,e);return Vn(t,Re(e,(function(t){return ms(t,r)?+t:t})).sort(Ei)),n}));function Js(t){return null==t?t:br.call(t)}var Qs=Wn((function(t){return ai(mn(t,1,Ko,!0))})),to=Wn((function(t){var e=Hs(t);return Ko(e)&&(e=i),ai(mn(t,1,Ko,!0),ss(e,2))})),eo=Wn((function(t){var e=Hs(t);return e="function"==typeof e?e:i,ai(mn(t,1,Ko,!0),i,e)}));function ro(t){if(!t||!t.length)return[];var e=0;return t=Ce(t,(function(t){if(Ko(t))return e=mr(t.length,e),!0})),We(e,(function(e){return Re(t,Be(e))}))}function no(t,e){if(!t||!t.length)return[];var r=ro(t);return null==e?r:Re(r,(function(t){return Ee(e,i,t)}))}var io=Wn((function(t,e){return Ko(t)?cn(t,e):[]})),so=Wn((function(t){return di(Ce(t,Ko))})),oo=Wn((function(t){var e=Hs(t);return Ko(e)&&(e=i),di(Ce(t,Ko),ss(e,2))})),ao=Wn((function(t){var e=Hs(t);return e="function"==typeof e?e:i,di(Ce(t,Ko),i,e)})),lo=Wn(ro),co=Wn((function(t){var e=t.length,r=e>1?t[e-1]:i;return r="function"==typeof r?(t.pop(),r):i,no(t,r)}));function uo(t){var e=jr(t);return e.__chain__=!0,e}function ho(t,e){return e(t)}var fo=Qi((function(t){var e=t.length,r=e?t[0]:0,n=this.__wrapped__,s=function(e){return nn(e,t)};return!(e>1||this.__actions__.length)&&n instanceof zr&&ms(r)?((n=n.slice(r,+r+(e?1:0))).__actions__.push({func:ho,args:[s],thisArg:i}),new $r(n,this.__chain__).thru((function(t){return e&&!t.length&&t.push(i),t}))):this.thru(s)})),po=Ci((function(t,e,r){It.call(t,r)?++t[r]:rn(t,r,1)})),mo=Li(zs),go=Li(Us);function yo(t,e){return(Bo(t)?Ae:un)(t,ss(e,3))}function vo(t,e){return(Bo(t)?Pe:hn)(t,ss(e,3))}var _o=Ci((function(t,e,r){It.call(t,r)?t[r].push(e):rn(t,r,[e])})),bo=Wn((function(t,e,r){var i=-1,s="function"==typeof e,o=qo(t)?n(t.length):[];return un(t,(function(t){o[++i]=s?Ee(e,t,r):Cn(t,e,r)})),o})),wo=Ci((function(t,e,r){rn(t,r,e)}));function xo(t,e){return(Bo(t)?Re:Fn)(t,ss(e,3))}var Eo=Ci((function(t,e,r){t[r?0:1].push(e)}),(function(){return[[],[]]})),So=Wn((function(t,e){if(null==t)return[];var r=e.length;return r>1&&gs(t,e[0],e[1])?e=[]:r>2&&gs(e[0],e[1],e[2])&&(e=[e[0]]),zn(t,mn(e,1),[])})),Ao=ce||function(){return he.Date.now()};function Po(t,e,r){return e=r?i:e,e=t&&null==e?t.length:e,Hi(t,c,i,i,i,i,e)}function To(t,e){var r;if("function"!=typeof e)throw new Tt(s);return t=fa(t),function(){return--t>0&&(r=e.apply(this,arguments)),t<=1&&(e=i),r}}var Co=Wn((function(t,e,r){var n=1;if(r.length){var i=or(r,is(Co));n|=l}return Hi(t,n,e,r,i)})),Mo=Wn((function(t,e,r){var n=3;if(r.length){var i=or(r,is(Mo));n|=l}return Hi(e,n,t,r,i)}));function Oo(t,e,r){var n,o,a,l,c,u,h=0,d=!1,f=!1,p=!0;if("function"!=typeof t)throw new Tt(s);function m(e){var r=n,s=o;return n=o=i,h=e,l=t.apply(s,r)}function g(t){var r=t-u;return u===i||r>=e||r<0||f&&t-h>=a}function y(){var t=Ao();if(g(t))return v(t);c=Ts(y,function(t){var r=e-(t-u);return f?gr(r,a-(t-h)):r}(t))}function v(t){return c=i,p&&n?m(t):(n=o=i,l)}function _(){var t=Ao(),r=g(t);if(n=arguments,o=this,u=t,r){if(c===i)return function(t){return h=t,c=Ts(y,e),d?m(t):l}(u);if(f)return _i(c),c=Ts(y,e),m(u)}return c===i&&(c=Ts(y,e)),l}return e=ma(e)||0,Qo(r)&&(d=!!r.leading,a=(f="maxWait"in r)?mr(ma(r.maxWait)||0,e):a,p="trailing"in r?!!r.trailing:p),_.cancel=function(){c!==i&&_i(c),h=0,n=u=o=c=i},_.flush=function(){return c===i?l:v(Ao())},_}var Ro=Wn((function(t,e){return ln(t,1,e)})),Do=Wn((function(t,e,r){return ln(t,ma(e)||0,r)}));function Io(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new Tt(s);var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],s=r.cache;if(s.has(i))return s.get(i);var o=t.apply(this,n);return r.cache=s.set(i,o)||s,o};return r.cache=new(Io.Cache||Vr),r}function ko(t){if("function"!=typeof t)throw new Tt(s);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}Io.Cache=Vr;var Lo=yi((function(t,e){var r=(e=1==e.length&&Bo(e[0])?Re(e[0],Ye(ss())):Re(mn(e,1),Ye(ss()))).length;return Wn((function(n){for(var i=-1,s=gr(n.length,r);++i<s;)n[i]=e[i].call(this,n[i]);return Ee(t,this,n)}))})),Fo=Wn((function(t,e){var r=or(e,is(Fo));return Hi(t,l,i,e,r)})),jo=Wn((function(t,e){var r=or(e,is(jo));return Hi(t,64,i,e,r)})),No=Qi((function(t,e){return Hi(t,256,i,i,i,e)}));function Go(t,e){return t===e||t!=t&&e!=e}var $o=Bi(Sn),zo=Bi((function(t,e){return t>=e})),Uo=Mn(function(){return arguments}())?Mn:function(t){return ta(t)&&It.call(t,"callee")&&!Kt.call(t,"callee")},Bo=n.isArray,Vo=ye?Ye(ye):function(t){return ta(t)&&En(t)==R};function qo(t){return null!=t&&Jo(t.length)&&!Xo(t)}function Ko(t){return ta(t)&&qo(t)}var Wo=ge||ml,Ho=ve?Ye(ve):function(t){return ta(t)&&En(t)==v};function Yo(t){if(!ta(t))return!1;var e=En(t);return e==_||"[object DOMException]"==e||"string"==typeof t.message&&"string"==typeof t.name&&!na(t)}function Xo(t){if(!Qo(t))return!1;var e=En(t);return e==b||e==w||"[object AsyncFunction]"==e||"[object Proxy]"==e}function Zo(t){return"number"==typeof t&&t==fa(t)}function Jo(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=h}function Qo(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function ta(t){return null!=t&&"object"==typeof t}var ea=_e?Ye(_e):function(t){return ta(t)&&hs(t)==x};function ra(t){return"number"==typeof t||ta(t)&&En(t)==E}function na(t){if(!ta(t)||En(t)!=S)return!1;var e=Vt(t);if(null===e)return!0;var r=It.call(e,"constructor")&&e.constructor;return"function"==typeof r&&r instanceof r&&Dt.call(r)==jt}var ia=be?Ye(be):function(t){return ta(t)&&En(t)==P},sa=we?Ye(we):function(t){return ta(t)&&hs(t)==T};function oa(t){return"string"==typeof t||!Bo(t)&&ta(t)&&En(t)==C}function aa(t){return"symbol"==typeof t||ta(t)&&En(t)==M}var la=xe?Ye(xe):function(t){return ta(t)&&Jo(t.length)&&!!ie[En(t)]},ca=Bi(Ln),ua=Bi((function(t,e){return t<=e}));function ha(t){if(!t)return[];if(qo(t))return oa(t)?ur(t):Pi(t);if(Yt&&t[Yt])return function(t){for(var e,r=[];!(e=t.next()).done;)r.push(e.value);return r}(t[Yt]());var e=hs(t);return(e==x?ir:e==T?ar:Ga)(t)}function da(t){return t?(t=ma(t))===u||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function fa(t){var e=da(t),r=e%1;return e==e?r?e-r:e:0}function pa(t){return t?sn(fa(t),0,f):0}function ma(t){if("number"==typeof t)return t;if(aa(t))return d;if(Qo(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=Qo(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=He(t);var r=pt.test(t);return r||gt.test(t)?le(t.slice(2),r?2:8):ft.test(t)?d:+t}function ga(t){return Ti(t,Ra(t))}function ya(t){return null==t?"":oi(t)}var va=Mi((function(t,e){if(bs(e)||qo(e))Ti(e,Oa(e),t);else for(var r in e)It.call(e,r)&&Jr(t,r,e[r])})),_a=Mi((function(t,e){Ti(e,Ra(e),t)})),ba=Mi((function(t,e,r,n){Ti(e,Ra(e),t,n)})),wa=Mi((function(t,e,r,n){Ti(e,Oa(e),t,n)})),xa=Qi(nn),Ea=Wn((function(t,e){t=St(t);var r=-1,n=e.length,s=n>2?e[2]:i;for(s&&gs(e[0],e[1],s)&&(n=1);++r<n;)for(var o=e[r],a=Ra(o),l=-1,c=a.length;++l<c;){var u=a[l],h=t[u];(h===i||Go(h,Ot[u])&&!It.call(t,u))&&(t[u]=o[u])}return t})),Sa=Wn((function(t){return t.push(i,Xi),Ee(Ia,i,t)}));function Aa(t,e,r){var n=null==t?i:wn(t,e);return n===i?r:n}function Pa(t,e){return null!=t&&ds(t,e,Pn)}var Ta=Ni((function(t,e,r){null!=e&&"function"!=typeof e.toString&&(e=Ft.call(e)),t[e]=r}),Qa(rl)),Ca=Ni((function(t,e,r){null!=e&&"function"!=typeof e.toString&&(e=Ft.call(e)),It.call(t,e)?t[e].push(r):t[e]=[r]}),ss),Ma=Wn(Cn);function Oa(t){return qo(t)?Wr(t):kn(t)}function Ra(t){return qo(t)?Wr(t,!0):function(t){if(!Qo(t))return function(t){var e=[];if(null!=t)for(var r in St(t))e.push(r);return e}(t);var e=bs(t),r=[];for(var n in t)("constructor"!=n||!e&&It.call(t,n))&&r.push(n);return r}(t)}var Da=Mi((function(t,e,r){Gn(t,e,r)})),Ia=Mi((function(t,e,r,n){Gn(t,e,r,n)})),ka=Qi((function(t,e){var r={};if(null==t)return r;var n=!1;e=Re(e,(function(e){return e=gi(e,t),n||(n=e.length>1),e})),Ti(t,es(t),r),n&&(r=on(r,7,Zi));for(var i=e.length;i--;)li(r,e[i]);return r})),La=Qi((function(t,e){return null==t?{}:function(t,e){return Un(t,e,(function(e,r){return Pa(t,r)}))}(t,e)}));function Fa(t,e){if(null==t)return{};var r=Re(es(t),(function(t){return[t]}));return e=ss(e),Un(t,r,(function(t,r){return e(t,r[0])}))}var ja=Wi(Oa),Na=Wi(Ra);function Ga(t){return null==t?[]:Xe(t,Oa(t))}var $a=Ii((function(t,e,r){return e=e.toLowerCase(),t+(r?za(e):e)}));function za(t){return Ya(ya(t).toLowerCase())}function Ua(t){return(t=ya(t))&&t.replace(vt,tr).replace(Zt,"")}var Ba=Ii((function(t,e,r){return t+(r?"-":"")+e.toLowerCase()})),Va=Ii((function(t,e,r){return t+(r?" ":"")+e.toLowerCase()})),qa=Di("toLowerCase"),Ka=Ii((function(t,e,r){return t+(r?"_":"")+e.toLowerCase()})),Wa=Ii((function(t,e,r){return t+(r?" ":"")+Ya(e)})),Ha=Ii((function(t,e,r){return t+(r?" ":"")+e.toUpperCase()})),Ya=Di("toUpperCase");function Xa(t,e,r){return t=ya(t),(e=r?i:e)===i?function(t){return ee.test(t)}(t)?function(t){return t.match(Qt)||[]}(t):function(t){return t.match(lt)||[]}(t):t.match(e)||[]}var Za=Wn((function(t,e){try{return Ee(t,i,e)}catch(t){return Yo(t)?t:new wt(t)}})),Ja=Qi((function(t,e){return Ae(e,(function(e){e=Ls(e),rn(t,e,Co(t[e],t))})),t}));function Qa(t){return function(){return t}}var tl=Fi(),el=Fi(!0);function rl(t){return t}function nl(t){return In("function"==typeof t?t:on(t,1))}var il=Wn((function(t,e){return function(r){return Cn(r,t,e)}})),sl=Wn((function(t,e){return function(r){return Cn(t,r,e)}}));function ol(t,e,r){var n=Oa(e),i=bn(e,n);null!=r||Qo(e)&&(i.length||!n.length)||(r=e,e=t,t=this,i=bn(e,Oa(e)));var s=!(Qo(r)&&"chain"in r&&!r.chain),o=Xo(t);return Ae(i,(function(r){var n=e[r];t[r]=n,o&&(t.prototype[r]=function(){var e=this.__chain__;if(s||e){var r=t(this.__wrapped__);return(r.__actions__=Pi(this.__actions__)).push({func:n,args:arguments,thisArg:t}),r.__chain__=e,r}return n.apply(t,De([this.value()],arguments))})})),t}function al(){}var ll=$i(Re),cl=$i(Te),ul=$i(Le);function hl(t){return ys(t)?Be(Ls(t)):function(t){return function(e){return wn(e,t)}}(t)}var dl=Ui(),fl=Ui(!0);function pl(){return[]}function ml(){return!1}var gl,yl=Gi((function(t,e){return t+e}),0),vl=qi("ceil"),_l=Gi((function(t,e){return t/e}),1),bl=qi("floor"),wl=Gi((function(t,e){return t*e}),1),xl=qi("round"),El=Gi((function(t,e){return t-e}),0);return jr.after=function(t,e){if("function"!=typeof e)throw new Tt(s);return t=fa(t),function(){if(--t<1)return e.apply(this,arguments)}},jr.ary=Po,jr.assign=va,jr.assignIn=_a,jr.assignInWith=ba,jr.assignWith=wa,jr.at=xa,jr.before=To,jr.bind=Co,jr.bindAll=Ja,jr.bindKey=Mo,jr.castArray=function(){if(!arguments.length)return[];var t=arguments[0];return Bo(t)?t:[t]},jr.chain=uo,jr.chunk=function(t,e,r){e=(r?gs(t,e,r):e===i)?1:mr(fa(e),0);var s=null==t?0:t.length;if(!s||e<1)return[];for(var o=0,a=0,l=n(de(s/e));o<s;)l[a++]=ti(t,o,o+=e);return l},jr.compact=function(t){for(var e=-1,r=null==t?0:t.length,n=0,i=[];++e<r;){var s=t[e];s&&(i[n++]=s)}return i},jr.concat=function(){var t=arguments.length;if(!t)return[];for(var e=n(t-1),r=arguments[0],i=t;i--;)e[i-1]=arguments[i];return De(Bo(r)?Pi(r):[r],mn(e,1))},jr.cond=function(t){var e=null==t?0:t.length,r=ss();return t=e?Re(t,(function(t){if("function"!=typeof t[1])throw new Tt(s);return[r(t[0]),t[1]]})):[],Wn((function(r){for(var n=-1;++n<e;){var i=t[n];if(Ee(i[0],this,r))return Ee(i[1],this,r)}}))},jr.conforms=function(t){return function(t){var e=Oa(t);return function(r){return an(r,t,e)}}(on(t,1))},jr.constant=Qa,jr.countBy=po,jr.create=function(t,e){var r=Nr(t);return null==e?r:en(r,e)},jr.curry=function t(e,r,n){var s=Hi(e,8,i,i,i,i,i,r=n?i:r);return s.placeholder=t.placeholder,s},jr.curryRight=function t(e,r,n){var s=Hi(e,16,i,i,i,i,i,r=n?i:r);return s.placeholder=t.placeholder,s},jr.debounce=Oo,jr.defaults=Ea,jr.defaultsDeep=Sa,jr.defer=Ro,jr.delay=Do,jr.difference=Ns,jr.differenceBy=Gs,jr.differenceWith=$s,jr.drop=function(t,e,r){var n=null==t?0:t.length;return n?ti(t,(e=r||e===i?1:fa(e))<0?0:e,n):[]},jr.dropRight=function(t,e,r){var n=null==t?0:t.length;return n?ti(t,0,(e=n-(e=r||e===i?1:fa(e)))<0?0:e):[]},jr.dropRightWhile=function(t,e){return t&&t.length?ui(t,ss(e,3),!0,!0):[]},jr.dropWhile=function(t,e){return t&&t.length?ui(t,ss(e,3),!0):[]},jr.fill=function(t,e,r,n){var s=null==t?0:t.length;return s?(r&&"number"!=typeof r&&gs(t,e,r)&&(r=0,n=s),function(t,e,r,n){var s=t.length;for((r=fa(r))<0&&(r=-r>s?0:s+r),(n=n===i||n>s?s:fa(n))<0&&(n+=s),n=r>n?0:pa(n);r<n;)t[r++]=e;return t}(t,e,r,n)):[]},jr.filter=function(t,e){return(Bo(t)?Ce:pn)(t,ss(e,3))},jr.flatMap=function(t,e){return mn(xo(t,e),1)},jr.flatMapDeep=function(t,e){return mn(xo(t,e),u)},jr.flatMapDepth=function(t,e,r){return r=r===i?1:fa(r),mn(xo(t,e),r)},jr.flatten=Bs,jr.flattenDeep=function(t){return null!=t&&t.length?mn(t,u):[]},jr.flattenDepth=function(t,e){return null!=t&&t.length?mn(t,e=e===i?1:fa(e)):[]},jr.flip=function(t){return Hi(t,512)},jr.flow=tl,jr.flowRight=el,jr.fromPairs=function(t){for(var e=-1,r=null==t?0:t.length,n={};++e<r;){var i=t[e];n[i[0]]=i[1]}return n},jr.functions=function(t){return null==t?[]:bn(t,Oa(t))},jr.functionsIn=function(t){return null==t?[]:bn(t,Ra(t))},jr.groupBy=_o,jr.initial=function(t){return null!=t&&t.length?ti(t,0,-1):[]},jr.intersection=qs,jr.intersectionBy=Ks,jr.intersectionWith=Ws,jr.invert=Ta,jr.invertBy=Ca,jr.invokeMap=bo,jr.iteratee=nl,jr.keyBy=wo,jr.keys=Oa,jr.keysIn=Ra,jr.map=xo,jr.mapKeys=function(t,e){var r={};return e=ss(e,3),vn(t,(function(t,n,i){rn(r,e(t,n,i),t)})),r},jr.mapValues=function(t,e){var r={};return e=ss(e,3),vn(t,(function(t,n,i){rn(r,n,e(t,n,i))})),r},jr.matches=function(t){return jn(on(t,1))},jr.matchesProperty=function(t,e){return Nn(t,on(e,1))},jr.memoize=Io,jr.merge=Da,jr.mergeWith=Ia,jr.method=il,jr.methodOf=sl,jr.mixin=ol,jr.negate=ko,jr.nthArg=function(t){return t=fa(t),Wn((function(e){return $n(e,t)}))},jr.omit=ka,jr.omitBy=function(t,e){return Fa(t,ko(ss(e)))},jr.once=function(t){return To(2,t)},jr.orderBy=function(t,e,r,n){return null==t?[]:(Bo(e)||(e=null==e?[]:[e]),Bo(r=n?i:r)||(r=null==r?[]:[r]),zn(t,e,r))},jr.over=ll,jr.overArgs=Lo,jr.overEvery=cl,jr.overSome=ul,jr.partial=Fo,jr.partialRight=jo,jr.partition=Eo,jr.pick=La,jr.pickBy=Fa,jr.property=hl,jr.propertyOf=function(t){return function(e){return null==t?i:wn(t,e)}},jr.pull=Ys,jr.pullAll=Xs,jr.pullAllBy=function(t,e,r){return t&&t.length&&e&&e.length?Bn(t,e,ss(r,2)):t},jr.pullAllWith=function(t,e,r){return t&&t.length&&e&&e.length?Bn(t,e,i,r):t},jr.pullAt=Zs,jr.range=dl,jr.rangeRight=fl,jr.rearg=No,jr.reject=function(t,e){return(Bo(t)?Ce:pn)(t,ko(ss(e,3)))},jr.remove=function(t,e){var r=[];if(!t||!t.length)return r;var n=-1,i=[],s=t.length;for(e=ss(e,3);++n<s;){var o=t[n];e(o,n,t)&&(r.push(o),i.push(n))}return Vn(t,i),r},jr.rest=function(t,e){if("function"!=typeof t)throw new Tt(s);return Wn(t,e=e===i?e:fa(e))},jr.reverse=Js,jr.sampleSize=function(t,e,r){return e=(r?gs(t,e,r):e===i)?1:fa(e),(Bo(t)?Yr:Yn)(t,e)},jr.set=function(t,e,r){return null==t?t:Xn(t,e,r)},jr.setWith=function(t,e,r,n){return n="function"==typeof n?n:i,null==t?t:Xn(t,e,r,n)},jr.shuffle=function(t){return(Bo(t)?Xr:Qn)(t)},jr.slice=function(t,e,r){var n=null==t?0:t.length;return n?(r&&"number"!=typeof r&&gs(t,e,r)?(e=0,r=n):(e=null==e?0:fa(e),r=r===i?n:fa(r)),ti(t,e,r)):[]},jr.sortBy=So,jr.sortedUniq=function(t){return t&&t.length?ii(t):[]},jr.sortedUniqBy=function(t,e){return t&&t.length?ii(t,ss(e,2)):[]},jr.split=function(t,e,r){return r&&"number"!=typeof r&&gs(t,e,r)&&(e=r=i),(r=r===i?f:r>>>0)?(t=ya(t))&&("string"==typeof e||null!=e&&!ia(e))&&!(e=oi(e))&&nr(t)?vi(ur(t),0,r):t.split(e,r):[]},jr.spread=function(t,e){if("function"!=typeof t)throw new Tt(s);return e=null==e?0:mr(fa(e),0),Wn((function(r){var n=r[e],i=vi(r,0,e);return n&&De(i,n),Ee(t,this,i)}))},jr.tail=function(t){var e=null==t?0:t.length;return e?ti(t,1,e):[]},jr.take=function(t,e,r){return t&&t.length?ti(t,0,(e=r||e===i?1:fa(e))<0?0:e):[]},jr.takeRight=function(t,e,r){var n=null==t?0:t.length;return n?ti(t,(e=n-(e=r||e===i?1:fa(e)))<0?0:e,n):[]},jr.takeRightWhile=function(t,e){return t&&t.length?ui(t,ss(e,3),!1,!0):[]},jr.takeWhile=function(t,e){return t&&t.length?ui(t,ss(e,3)):[]},jr.tap=function(t,e){return e(t),t},jr.throttle=function(t,e,r){var n=!0,i=!0;if("function"!=typeof t)throw new Tt(s);return Qo(r)&&(n="leading"in r?!!r.leading:n,i="trailing"in r?!!r.trailing:i),Oo(t,e,{leading:n,maxWait:e,trailing:i})},jr.thru=ho,jr.toArray=ha,jr.toPairs=ja,jr.toPairsIn=Na,jr.toPath=function(t){return Bo(t)?Re(t,Ls):aa(t)?[t]:Pi(ks(ya(t)))},jr.toPlainObject=ga,jr.transform=function(t,e,r){var n=Bo(t),i=n||Wo(t)||la(t);if(e=ss(e,4),null==r){var s=t&&t.constructor;r=i?n?new s:[]:Qo(t)&&Xo(s)?Nr(Vt(t)):{}}return(i?Ae:vn)(t,(function(t,n,i){return e(r,t,n,i)})),r},jr.unary=function(t){return Po(t,1)},jr.union=Qs,jr.unionBy=to,jr.unionWith=eo,jr.uniq=function(t){return t&&t.length?ai(t):[]},jr.uniqBy=function(t,e){return t&&t.length?ai(t,ss(e,2)):[]},jr.uniqWith=function(t,e){return e="function"==typeof e?e:i,t&&t.length?ai(t,i,e):[]},jr.unset=function(t,e){return null==t||li(t,e)},jr.unzip=ro,jr.unzipWith=no,jr.update=function(t,e,r){return null==t?t:ci(t,e,mi(r))},jr.updateWith=function(t,e,r,n){return n="function"==typeof n?n:i,null==t?t:ci(t,e,mi(r),n)},jr.values=Ga,jr.valuesIn=function(t){return null==t?[]:Xe(t,Ra(t))},jr.without=io,jr.words=Xa,jr.wrap=function(t,e){return Fo(mi(e),t)},jr.xor=so,jr.xorBy=oo,jr.xorWith=ao,jr.zip=lo,jr.zipObject=function(t,e){return fi(t||[],e||[],Jr)},jr.zipObjectDeep=function(t,e){return fi(t||[],e||[],Xn)},jr.zipWith=co,jr.entries=ja,jr.entriesIn=Na,jr.extend=_a,jr.extendWith=ba,ol(jr,jr),jr.add=yl,jr.attempt=Za,jr.camelCase=$a,jr.capitalize=za,jr.ceil=vl,jr.clamp=function(t,e,r){return r===i&&(r=e,e=i),r!==i&&(r=(r=ma(r))==r?r:0),e!==i&&(e=(e=ma(e))==e?e:0),sn(ma(t),e,r)},jr.clone=function(t){return on(t,4)},jr.cloneDeep=function(t){return on(t,5)},jr.cloneDeepWith=function(t,e){return on(t,5,e="function"==typeof e?e:i)},jr.cloneWith=function(t,e){return on(t,4,e="function"==typeof e?e:i)},jr.conformsTo=function(t,e){return null==e||an(t,e,Oa(e))},jr.deburr=Ua,jr.defaultTo=function(t,e){return null==t||t!=t?e:t},jr.divide=_l,jr.endsWith=function(t,e,r){t=ya(t),e=oi(e);var n=t.length,s=r=r===i?n:sn(fa(r),0,n);return(r-=e.length)>=0&&t.slice(r,s)==e},jr.eq=Go,jr.escape=function(t){return(t=ya(t))&&H.test(t)?t.replace(K,er):t},jr.escapeRegExp=function(t){return(t=ya(t))&&rt.test(t)?t.replace(et,"\\$&"):t},jr.every=function(t,e,r){var n=Bo(t)?Te:dn;return r&&gs(t,e,r)&&(e=i),n(t,ss(e,3))},jr.find=mo,jr.findIndex=zs,jr.findKey=function(t,e){return je(t,ss(e,3),vn)},jr.findLast=go,jr.findLastIndex=Us,jr.findLastKey=function(t,e){return je(t,ss(e,3),_n)},jr.floor=bl,jr.forEach=yo,jr.forEachRight=vo,jr.forIn=function(t,e){return null==t?t:gn(t,ss(e,3),Ra)},jr.forInRight=function(t,e){return null==t?t:yn(t,ss(e,3),Ra)},jr.forOwn=function(t,e){return t&&vn(t,ss(e,3))},jr.forOwnRight=function(t,e){return t&&_n(t,ss(e,3))},jr.get=Aa,jr.gt=$o,jr.gte=zo,jr.has=function(t,e){return null!=t&&ds(t,e,An)},jr.hasIn=Pa,jr.head=Vs,jr.identity=rl,jr.includes=function(t,e,r,n){t=qo(t)?t:Ga(t),r=r&&!n?fa(r):0;var i=t.length;return r<0&&(r=mr(i+r,0)),oa(t)?r<=i&&t.indexOf(e,r)>-1:!!i&&Ge(t,e,r)>-1},jr.indexOf=function(t,e,r){var n=null==t?0:t.length;if(!n)return-1;var i=null==r?0:fa(r);return i<0&&(i=mr(n+i,0)),Ge(t,e,i)},jr.inRange=function(t,e,r){return e=da(e),r===i?(r=e,e=0):r=da(r),function(t,e,r){return t>=gr(e,r)&&t<mr(e,r)}(t=ma(t),e,r)},jr.invoke=Ma,jr.isArguments=Uo,jr.isArray=Bo,jr.isArrayBuffer=Vo,jr.isArrayLike=qo,jr.isArrayLikeObject=Ko,jr.isBoolean=function(t){return!0===t||!1===t||ta(t)&&En(t)==y},jr.isBuffer=Wo,jr.isDate=Ho,jr.isElement=function(t){return ta(t)&&1===t.nodeType&&!na(t)},jr.isEmpty=function(t){if(null==t)return!0;if(qo(t)&&(Bo(t)||"string"==typeof t||"function"==typeof t.splice||Wo(t)||la(t)||Uo(t)))return!t.length;var e=hs(t);if(e==x||e==T)return!t.size;if(bs(t))return!kn(t).length;for(var r in t)if(It.call(t,r))return!1;return!0},jr.isEqual=function(t,e){return On(t,e)},jr.isEqualWith=function(t,e,r){var n=(r="function"==typeof r?r:i)?r(t,e):i;return n===i?On(t,e,i,r):!!n},jr.isError=Yo,jr.isFinite=function(t){return"number"==typeof t&&Fe(t)},jr.isFunction=Xo,jr.isInteger=Zo,jr.isLength=Jo,jr.isMap=ea,jr.isMatch=function(t,e){return t===e||Rn(t,e,as(e))},jr.isMatchWith=function(t,e,r){return r="function"==typeof r?r:i,Rn(t,e,as(e),r)},jr.isNaN=function(t){return ra(t)&&t!=+t},jr.isNative=function(t){if(_s(t))throw new wt("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Dn(t)},jr.isNil=function(t){return null==t},jr.isNull=function(t){return null===t},jr.isNumber=ra,jr.isObject=Qo,jr.isObjectLike=ta,jr.isPlainObject=na,jr.isRegExp=ia,jr.isSafeInteger=function(t){return Zo(t)&&t>=-9007199254740991&&t<=h},jr.isSet=sa,jr.isString=oa,jr.isSymbol=aa,jr.isTypedArray=la,jr.isUndefined=function(t){return t===i},jr.isWeakMap=function(t){return ta(t)&&hs(t)==O},jr.isWeakSet=function(t){return ta(t)&&"[object WeakSet]"==En(t)},jr.join=function(t,e){return null==t?"":Ve.call(t,e)},jr.kebabCase=Ba,jr.last=Hs,jr.lastIndexOf=function(t,e,r){var n=null==t?0:t.length;if(!n)return-1;var s=n;return r!==i&&(s=(s=fa(r))<0?mr(n+s,0):gr(s,n-1)),e==e?function(t,e,r){for(var n=r+1;n--;)if(t[n]===e)return n;return n}(t,e,s):Ne(t,ze,s,!0)},jr.lowerCase=Va,jr.lowerFirst=qa,jr.lt=ca,jr.lte=ua,jr.max=function(t){return t&&t.length?fn(t,rl,Sn):i},jr.maxBy=function(t,e){return t&&t.length?fn(t,ss(e,2),Sn):i},jr.mean=function(t){return Ue(t,rl)},jr.meanBy=function(t,e){return Ue(t,ss(e,2))},jr.min=function(t){return t&&t.length?fn(t,rl,Ln):i},jr.minBy=function(t,e){return t&&t.length?fn(t,ss(e,2),Ln):i},jr.stubArray=pl,jr.stubFalse=ml,jr.stubObject=function(){return{}},jr.stubString=function(){return""},jr.stubTrue=function(){return!0},jr.multiply=wl,jr.nth=function(t,e){return t&&t.length?$n(t,fa(e)):i},jr.noConflict=function(){return he._===this&&(he._=Nt),this},jr.noop=al,jr.now=Ao,jr.pad=function(t,e,r){t=ya(t);var n=(e=fa(e))?cr(t):0;if(!e||n>=e)return t;var i=(e-n)/2;return zi(fe(i),r)+t+zi(de(i),r)},jr.padEnd=function(t,e,r){t=ya(t);var n=(e=fa(e))?cr(t):0;return e&&n<e?t+zi(e-n,r):t},jr.padStart=function(t,e,r){t=ya(t);var n=(e=fa(e))?cr(t):0;return e&&n<e?zi(e-n,r)+t:t},jr.parseInt=function(t,e,r){return r||null==e?e=0:e&&(e=+e),vr(ya(t).replace(nt,""),e||0)},jr.random=function(t,e,r){if(r&&"boolean"!=typeof r&&gs(t,e,r)&&(e=r=i),r===i&&("boolean"==typeof e?(r=e,e=i):"boolean"==typeof t&&(r=t,t=i)),t===i&&e===i?(t=0,e=1):(t=da(t),e===i?(e=t,t=0):e=da(e)),t>e){var n=t;t=e,e=n}if(r||t%1||e%1){var s=_r();return gr(t+s*(e-t+ae("1e-"+((s+"").length-1))),e)}return qn(t,e)},jr.reduce=function(t,e,r){var n=Bo(t)?Ie:qe,i=arguments.length<3;return n(t,ss(e,4),r,i,un)},jr.reduceRight=function(t,e,r){var n=Bo(t)?ke:qe,i=arguments.length<3;return n(t,ss(e,4),r,i,hn)},jr.repeat=function(t,e,r){return e=(r?gs(t,e,r):e===i)?1:fa(e),Kn(ya(t),e)},jr.replace=function(){var t=arguments,e=ya(t[0]);return t.length<3?e:e.replace(t[1],t[2])},jr.result=function(t,e,r){var n=-1,s=(e=gi(e,t)).length;for(s||(s=1,t=i);++n<s;){var o=null==t?i:t[Ls(e[n])];o===i&&(n=s,o=r),t=Xo(o)?o.call(t):o}return t},jr.round=xl,jr.runInContext=t,jr.sample=function(t){return(Bo(t)?Hr:Hn)(t)},jr.size=function(t){if(null==t)return 0;if(qo(t))return oa(t)?cr(t):t.length;var e=hs(t);return e==x||e==T?t.size:kn(t).length},jr.snakeCase=Ka,jr.some=function(t,e,r){var n=Bo(t)?Le:ei;return r&&gs(t,e,r)&&(e=i),n(t,ss(e,3))},jr.sortedIndex=function(t,e){return ri(t,e)},jr.sortedIndexBy=function(t,e,r){return ni(t,e,ss(r,2))},jr.sortedIndexOf=function(t,e){var r=null==t?0:t.length;if(r){var n=ri(t,e);if(n<r&&Go(t[n],e))return n}return-1},jr.sortedLastIndex=function(t,e){return ri(t,e,!0)},jr.sortedLastIndexBy=function(t,e,r){return ni(t,e,ss(r,2),!0)},jr.sortedLastIndexOf=function(t,e){if(null!=t&&t.length){var r=ri(t,e,!0)-1;if(Go(t[r],e))return r}return-1},jr.startCase=Wa,jr.startsWith=function(t,e,r){return t=ya(t),r=null==r?0:sn(fa(r),0,t.length),e=oi(e),t.slice(r,r+e.length)==e},jr.subtract=El,jr.sum=function(t){return t&&t.length?Ke(t,rl):0},jr.sumBy=function(t,e){return t&&t.length?Ke(t,ss(e,2)):0},jr.template=function(t,e,r){var n=jr.templateSettings;r&&gs(t,e,r)&&(e=i),t=ya(t),e=ba({},e,n,Yi);var s,o,a=ba({},e.imports,n.imports,Yi),l=Oa(a),c=Xe(a,l),u=0,h=e.interpolate||_t,d="__p += '",f=At((e.escape||_t).source+"|"+h.source+"|"+(h===Z?ht:_t).source+"|"+(e.evaluate||_t).source+"|$","g"),p="//# sourceURL="+(It.call(e,"sourceURL")?(e.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++ne+"]")+"\n";t.replace(f,(function(e,r,n,i,a,l){return n||(n=i),d+=t.slice(u,l).replace(bt,rr),r&&(s=!0,d+="' +\n__e("+r+") +\n'"),a&&(o=!0,d+="';\n"+a+";\n__p += '"),n&&(d+="' +\n((__t = ("+n+")) == null ? '' : __t) +\n'"),u=l+e.length,e})),d+="';\n";var m=It.call(e,"variable")&&e.variable;if(m){if(ct.test(m))throw new wt("Invalid `variable` option passed into `_.template`")}else d="with (obj) {\n"+d+"\n}\n";d=(o?d.replace(U,""):d).replace(B,"$1").replace(V,"$1;"),d="function("+(m||"obj")+") {\n"+(m?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(s?", __e = _.escape":"")+(o?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+d+"return __p\n}";var g=Za((function(){return xt(l,p+"return "+d).apply(i,c)}));if(g.source=d,Yo(g))throw g;return g},jr.times=function(t,e){if((t=fa(t))<1||t>h)return[];var r=f,n=gr(t,f);e=ss(e),t-=f;for(var i=We(n,e);++r<t;)e(r);return i},jr.toFinite=da,jr.toInteger=fa,jr.toLength=pa,jr.toLower=function(t){return ya(t).toLowerCase()},jr.toNumber=ma,jr.toSafeInteger=function(t){return t?sn(fa(t),-9007199254740991,h):0===t?t:0},jr.toString=ya,jr.toUpper=function(t){return ya(t).toUpperCase()},jr.trim=function(t,e,r){if((t=ya(t))&&(r||e===i))return He(t);if(!t||!(e=oi(e)))return t;var n=ur(t),s=ur(e);return vi(n,Je(n,s),Qe(n,s)+1).join("")},jr.trimEnd=function(t,e,r){if((t=ya(t))&&(r||e===i))return t.slice(0,hr(t)+1);if(!t||!(e=oi(e)))return t;var n=ur(t);return vi(n,0,Qe(n,ur(e))+1).join("")},jr.trimStart=function(t,e,r){if((t=ya(t))&&(r||e===i))return t.replace(nt,"");if(!t||!(e=oi(e)))return t;var n=ur(t);return vi(n,Je(n,ur(e))).join("")},jr.truncate=function(t,e){var r=30,n="...";if(Qo(e)){var s="separator"in e?e.separator:s;r="length"in e?fa(e.length):r,n="omission"in e?oi(e.omission):n}var o=(t=ya(t)).length;if(nr(t)){var a=ur(t);o=a.length}if(r>=o)return t;var l=r-cr(n);if(l<1)return n;var c=a?vi(a,0,l).join(""):t.slice(0,l);if(s===i)return c+n;if(a&&(l+=c.length-l),ia(s)){if(t.slice(l).search(s)){var u,h=c;for(s.global||(s=At(s.source,ya(dt.exec(s))+"g")),s.lastIndex=0;u=s.exec(h);)var d=u.index;c=c.slice(0,d===i?l:d)}}else if(t.indexOf(oi(s),l)!=l){var f=c.lastIndexOf(s);f>-1&&(c=c.slice(0,f))}return c+n},jr.unescape=function(t){return(t=ya(t))&&W.test(t)?t.replace(q,dr):t},jr.uniqueId=function(t){var e=++kt;return ya(t)+e},jr.upperCase=Ha,jr.upperFirst=Ya,jr.each=yo,jr.eachRight=vo,jr.first=Vs,ol(jr,(gl={},vn(jr,(function(t,e){It.call(jr.prototype,e)||(gl[e]=t)})),gl),{chain:!1}),jr.VERSION="4.17.21",Ae(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(t){jr[t].placeholder=jr})),Ae(["drop","take"],(function(t,e){zr.prototype[t]=function(r){r=r===i?1:mr(fa(r),0);var n=this.__filtered__&&!e?new zr(this):this.clone();return n.__filtered__?n.__takeCount__=gr(r,n.__takeCount__):n.__views__.push({size:gr(r,f),type:t+(n.__dir__<0?"Right":"")}),n},zr.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}})),Ae(["filter","map","takeWhile"],(function(t,e){var r=e+1,n=1==r||3==r;zr.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:ss(t,3),type:r}),e.__filtered__=e.__filtered__||n,e}})),Ae(["head","last"],(function(t,e){var r="take"+(e?"Right":"");zr.prototype[t]=function(){return this[r](1).value()[0]}})),Ae(["initial","tail"],(function(t,e){var r="drop"+(e?"":"Right");zr.prototype[t]=function(){return this.__filtered__?new zr(this):this[r](1)}})),zr.prototype.compact=function(){return this.filter(rl)},zr.prototype.find=function(t){return this.filter(t).head()},zr.prototype.findLast=function(t){return this.reverse().find(t)},zr.prototype.invokeMap=Wn((function(t,e){return"function"==typeof t?new zr(this):this.map((function(r){return Cn(r,t,e)}))})),zr.prototype.reject=function(t){return this.filter(ko(ss(t)))},zr.prototype.slice=function(t,e){t=fa(t);var r=this;return r.__filtered__&&(t>0||e<0)?new zr(r):(t<0?r=r.takeRight(-t):t&&(r=r.drop(t)),e!==i&&(r=(e=fa(e))<0?r.dropRight(-e):r.take(e-t)),r)},zr.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},zr.prototype.toArray=function(){return this.take(f)},vn(zr.prototype,(function(t,e){var r=/^(?:filter|find|map|reject)|While$/.test(e),n=/^(?:head|last)$/.test(e),s=jr[n?"take"+("last"==e?"Right":""):e],o=n||/^find/.test(e);s&&(jr.prototype[e]=function(){var e=this.__wrapped__,a=n?[1]:arguments,l=e instanceof zr,c=a[0],u=l||Bo(e),h=function(t){var e=s.apply(jr,De([t],a));return n&&d?e[0]:e};u&&r&&"function"==typeof c&&1!=c.length&&(l=u=!1);var d=this.__chain__,f=!!this.__actions__.length,p=o&&!d,m=l&&!f;if(!o&&u){e=m?e:new zr(this);var g=t.apply(e,a);return g.__actions__.push({func:ho,args:[h],thisArg:i}),new $r(g,d)}return p&&m?t.apply(this,a):(g=this.thru(h),p?n?g.value()[0]:g.value():g)})})),Ae(["pop","push","shift","sort","splice","unshift"],(function(t){var e=Ct[t],r=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",n=/^(?:pop|shift)$/.test(t);jr.prototype[t]=function(){var t=arguments;if(n&&!this.__chain__){var i=this.value();return e.apply(Bo(i)?i:[],t)}return this[r]((function(r){return e.apply(Bo(r)?r:[],t)}))}})),vn(zr.prototype,(function(t,e){var r=jr[e];if(r){var n=r.name+"";It.call(Cr,n)||(Cr[n]=[]),Cr[n].push({name:e,func:r})}})),Cr[ji(i,2).name]=[{name:"wrapper",func:i}],zr.prototype.clone=function(){var t=new zr(this.__wrapped__);return t.__actions__=Pi(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Pi(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Pi(this.__views__),t},zr.prototype.reverse=function(){if(this.__filtered__){var t=new zr(this);t.__dir__=-1,t.__filtered__=!0}else(t=this.clone()).__dir__*=-1;return t},zr.prototype.value=function(){var t=this.__wrapped__.value(),e=this.__dir__,r=Bo(t),n=e<0,i=r?t.length:0,s=function(t,e,r){for(var n=-1,i=r.length;++n<i;){var s=r[n],o=s.size;switch(s.type){case"drop":t+=o;break;case"dropRight":e-=o;break;case"take":e=gr(e,t+o);break;case"takeRight":t=mr(t,e-o)}}return{start:t,end:e}}(0,i,this.__views__),o=s.start,a=s.end,l=a-o,c=n?a:o-1,u=this.__iteratees__,h=u.length,d=0,f=gr(l,this.__takeCount__);if(!r||!n&&i==l&&f==l)return hi(t,this.__actions__);var p=[];t:for(;l--&&d<f;){for(var m=-1,g=t[c+=e];++m<h;){var y=u[m],v=y.iteratee,_=y.type,b=v(g);if(2==_)g=b;else if(!b){if(1==_)continue t;break t}}p[d++]=g}return p},jr.prototype.at=fo,jr.prototype.chain=function(){return uo(this)},jr.prototype.commit=function(){return new $r(this.value(),this.__chain__)},jr.prototype.next=function(){this.__values__===i&&(this.__values__=ha(this.value()));var t=this.__index__>=this.__values__.length;return{done:t,value:t?i:this.__values__[this.__index__++]}},jr.prototype.plant=function(t){for(var e,r=this;r instanceof Gr;){var n=js(r);n.__index__=0,n.__values__=i,e?s.__wrapped__=n:e=n;var s=n;r=r.__wrapped__}return s.__wrapped__=t,e},jr.prototype.reverse=function(){var t=this.__wrapped__;if(t instanceof zr){var e=t;return this.__actions__.length&&(e=new zr(this)),(e=e.reverse()).__actions__.push({func:ho,args:[Js],thisArg:i}),new $r(e,this.__chain__)}return this.thru(Js)},jr.prototype.toJSON=jr.prototype.valueOf=jr.prototype.value=function(){return hi(this.__wrapped__,this.__actions__)},jr.prototype.first=jr.prototype.head,Yt&&(jr.prototype[Yt]=function(){return this}),jr}();he._=fr,(n=function(){return fr}.call(e,r,e,t))===i||(t.exports=n)}.call(this)},69011:(t,e,r)=>{var n=r(68250);function i(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],s=r.cache;if(s.has(i))return s.get(i);var o=t.apply(this,n);return r.cache=s.set(i,o)||s,o};return r.cache=new(i.Cache||n),r}i.Cache=n,t.exports=i},48875:(t,e,r)=>{var n=r(40091),i=r(77848)((function(t,e,r,i){n(t,e,r,i)}));t.exports=i},79071:t=>{t.exports=function(){}},74874:(t,e,r)=>{var n=r(90242),i=r(41439)((function(t,e){return null==t?{}:n(t,e)}));t.exports=i},43282:(t,e,r)=>{var n=r(12762),i=r(98880),s=r(65187),o=r(66040);t.exports=function(t){return s(t)?n(o(t)):i(t)}},70581:(t,e,r)=>{var n=r(49261);t.exports=function(t,e){return t&&t.length&&e&&e.length?n(t,e):t}},40074:(t,e,r)=>{var n=r(90313),i=r(70310),s=r(23945),o=r(74535),a=s((function(t,e){if(null==t)return[];var r=e.length;return r>1&&o(t,e[0],e[1])?e=[]:r>2&&o(e[0],e[1],e[2])&&(e=[e[0]]),i(t,n(e,1),[])}));t.exports=a},99306:t=>{t.exports=function(){return[]}},34772:t=>{t.exports=function(){return!1}},42613:(t,e,r)=>{var n=r(65111),i=r(84354),s=r(53142),o=r(51187),a=r(96493),l=r(66040),c=r(95243);t.exports=function(t){return s(t)?n(t,l):o(t)?[t]:i(a(c(t)))}},64207:(t,e,r)=>{var n=r(39032),i=r(25288);t.exports=function(t){return n(t,i(t))}},95243:(t,e,r)=>{var n=r(52291);t.exports=function(t){return null==t?"":n(t)}},55620:(t,e,r)=>{var n=r(90313),i=r(23945),s=r(15630),o=r(65406),a=i((function(t){return s(n(t,1,o,!0))}));t.exports=a},82438:(t,e,r)=>{var n=r(15630);t.exports=function(t){return t&&t.length?n(t):[]}},19106:(t,e,r)=>{var n=r(15630);t.exports=function(t,e){return e="function"==typeof e?e:void 0,t&&t.length?n(t,void 0,e):[]}},30795:(t,e,r)=>{var n=r(96576),i=r(23945),s=r(65406),o=i((function(t,e){return s(t)?n(t,e):[]}));t.exports=o},37056:(t,e,r)=>{"use strict";r.d(e,{b:()=>lt,X:()=>ct});var n=r(15159),i=r(34633),s=r(20884),o=r(39512),a=Math.pow,l=(t,e,r)=>new Promise(((n,i)=>{var s=t=>{try{a(r.next(t))}catch(t){i(t)}},o=t=>{try{a(r.throw(t))}catch(t){i(t)}},a=t=>t.done?n(t.value):Promise.resolve(t.value).then(s,o);a((r=r.apply(t,e)).next())})),c=Uint8Array,u=Uint16Array,h=Int32Array,d=new c([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),f=new c([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),p=new c([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),m=function(t,e){for(var r=new u(31),n=0;n<31;++n)r[n]=e+=1<<t[n-1];var i=new h(r[30]);for(n=1;n<30;++n)for(var s=r[n];s<r[n+1];++s)i[s]=s-r[n]<<5|n;return{b:r,r:i}},g=m(d,2),y=g.b,v=g.r;y[28]=258,v[258]=28;var _,b=m(f,0),w=b.b,x=(b.r,new u(32768));for(A=0;A<32768;++A)_=(61680&(_=(52428&(_=(43690&A)>>1|(21845&A)<<1))>>2|(13107&_)<<2))>>4|(3855&_)<<4,x[A]=((65280&_)>>8|(255&_)<<8)>>1;var E=function(t,e,r){for(var n=t.length,i=0,s=new u(e);i<n;++i)t[i]&&++s[t[i]-1];var o,a=new u(e);for(i=1;i<e;++i)a[i]=a[i-1]+s[i-1]<<1;if(r){o=new u(1<<e);var l=15-e;for(i=0;i<n;++i)if(t[i])for(var c=i<<4|t[i],h=e-t[i],d=a[t[i]-1]++<<h,f=d|(1<<h)-1;d<=f;++d)o[x[d]>>l]=c}else for(o=new u(n),i=0;i<n;++i)t[i]&&(o[i]=x[a[t[i]-1]++]>>15-t[i]);return o},S=new c(288);for(A=0;A<144;++A)S[A]=8;for(A=144;A<256;++A)S[A]=9;for(A=256;A<280;++A)S[A]=7;for(A=280;A<288;++A)S[A]=8;var A,P=new c(32);for(A=0;A<32;++A)P[A]=5;var T=E(S,9,1),C=E(P,5,1),M=function(t){for(var e=t[0],r=1;r<t.length;++r)t[r]>e&&(e=t[r]);return e},O=function(t,e,r){var n=e/8|0;return(t[n]|t[n+1]<<8)>>(7&e)&r},R=function(t,e){var r=e/8|0;return(t[r]|t[r+1]<<8|t[r+2]<<16)>>(7&e)},D=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],I=function(t,e,r){var n=new Error(e||D[t]);if(n.code=t,Error.captureStackTrace&&Error.captureStackTrace(n,I),!r)throw n;return n},k=function(t,e,r,n){var i=t.length,s=n?n.length:0;if(!i||e.f&&!e.l)return r||new c(0);var o=!r||2!=e.i,a=e.i;r||(r=new c(3*i));var l=function(t){var e=r.length;if(t>e){var n=new c(Math.max(2*e,t));n.set(r),r=n}},u=e.f||0,h=e.p||0,m=e.b||0,g=e.l,v=e.d,_=e.m,b=e.n,x=8*i;do{if(!g){u=O(t,h,1);var S=O(t,h+1,3);if(h+=3,!S){var A=t[(U=4+((h+7)/8|0))-4]|t[U-3]<<8,P=U+A;if(P>i){a&&I(0);break}o&&l(m+A),r.set(t.subarray(U,P),m),e.b=m+=A,e.p=h=8*P,e.f=u;continue}if(1==S)g=T,v=C,_=9,b=5;else if(2==S){var D=O(t,h,31)+257,k=O(t,h+10,15)+4,L=D+O(t,h+5,31)+1;h+=14;for(var F=new c(L),j=new c(19),N=0;N<k;++N)j[p[N]]=O(t,h+3*N,7);h+=3*k;var G=M(j),$=(1<<G)-1,z=E(j,G,1);for(N=0;N<L;){var U,B=z[O(t,h,$)];if(h+=15&B,(U=B>>4)<16)F[N++]=U;else{var V=0,q=0;for(16==U?(q=3+O(t,h,3),h+=2,V=F[N-1]):17==U?(q=3+O(t,h,7),h+=3):18==U&&(q=11+O(t,h,127),h+=7);q--;)F[N++]=V}}var K=F.subarray(0,D),W=F.subarray(D);_=M(K),b=M(W),g=E(K,_,1),v=E(W,b,1)}else I(1);if(h>x){a&&I(0);break}}o&&l(m+131072);for(var H=(1<<_)-1,Y=(1<<b)-1,X=h;;X=h){var Z=(V=g[R(t,h)&H])>>4;if((h+=15&V)>x){a&&I(0);break}if(V||I(2),Z<256)r[m++]=Z;else{if(256==Z){X=h,g=null;break}var J=Z-254;if(Z>264){var Q=d[N=Z-257];J=O(t,h,(1<<Q)-1)+y[N],h+=Q}var tt=v[R(t,h)&Y],et=tt>>4;if(tt||I(3),h+=15&tt,W=w[et],et>3&&(Q=f[et],W+=R(t,h)&(1<<Q)-1,h+=Q),h>x){a&&I(0);break}o&&l(m+131072);var rt=m+J;if(m<W){var nt=s-W,it=Math.min(W,rt);for(nt+m<0&&I(3);m<it;++m)r[m]=n[nt+m]}for(;m<rt;m+=4)r[m]=r[m-W],r[m+1]=r[m+1-W],r[m+2]=r[m+2-W],r[m+3]=r[m+3-W];m=rt}}e.l=g,e.p=X,e.b=m,e.f=u,g&&(u=1,e.m=_,e.d=v,e.n=b)}while(!u);return m==r.length?r:function(t,e,r){(null==e||e<0)&&(e=0),(null==r||r>t.length)&&(r=t.length);var n=new c(r-e);return n.set(t.subarray(e,r)),n}(r,0,m)},L=new c(0);function F(t,e){return 31==t[0]&&139==t[1]&&8==t[2]?function(t,e){var r,n,i=function(t){31==t[0]&&139==t[1]&&8==t[2]||I(6,"invalid gzip data");var e=t[3],r=10;4&e&&(r+=2+(t[10]|t[11]<<8));for(var n=(e>>3&1)+(e>>4&1);n>0;n-=!t[r++]);return r+(2&e)}(t);return i+8>t.length&&I(6,"invalid gzip data"),k(t.subarray(i,-8),{i:2},e&&e.out||new c((n=(r=t).length,(r[n-4]|r[n-3]<<8|r[n-2]<<16|r[n-1]<<24)>>>0)),e&&e.dictionary)}(t,e):8!=(15&t[0])||t[0]>>4>7||(t[0]<<8|t[1])%31?function(t,e){return k(t,{i:2},e&&e.out,e&&e.dictionary)}(t,e):function(t,e){return k(t.subarray((r=t,n=e&&e.dictionary,(8!=(15&r[0])||r[0]>>4>7||(r[0]<<8|r[1])%31)&&I(6,"invalid zlib data"),(r[1]>>5&1)==+!n&&I(6,"invalid zlib data: "+(32&r[1]?"need":"unexpected")+" dictionary"),2+(r[1]>>3&4)),-4),{i:2},e&&e.out,e&&e.dictionary);var r,n}(t,e)}var j="undefined"!=typeof TextDecoder&&new TextDecoder;try{j.decode(L,{stream:!0})}catch(t){}var N=(t,e)=>t*a(2,e),G=(t,e)=>Math.floor(t/a(2,e)),$=(t,e)=>N(t.getUint16(e+1,!0),8)+t.getUint8(e),z=(t,e)=>N(t.getUint32(e+2,!0),16)+t.getUint16(e,!0),U=(t,e,r,n,i)=>{if(t!==n.getUint8(i))return t-n.getUint8(i);const s=$(n,i+1);if(e!==s)return e-s;const o=$(n,i+4);return r!==o?r-o:0},B=(t,e,r,n)=>{const i=V(t,e,r,n);return i?{z:e,x:r,y:n,offset:i[0],length:i[1],isDir:!1}:null},V=(t,e,r,n)=>{let i=0,s=t.byteLength/17-1;for(;i<=s;){const o=s+i>>1,a=U(e,r,n,t,17*o);if(a>0)i=o+1;else{if(!(a<0))return[z(t,17*o+7),t.getUint32(17*o+13,!0)];s=o-1}}return null},q=(t,e)=>t.isDir&&!e.isDir?1:!t.isDir&&e.isDir?-1:t.z!==e.z?t.z-e.z:t.x!==e.x?t.x-e.x:t.y-e.y,K=(t,e)=>{const r=t.getUint8(17*e);return{z:127&r,x:$(t,17*e+1),y:$(t,17*e+4),offset:z(t,17*e+7),length:t.getUint32(17*e+13,!0),isDir:r>>7==1}},W=t=>{const e=[],r=new DataView(t);for(let t=0;t<r.byteLength/17;t++)e.push(K(r,t));return H(e)},H=t=>{t.sort(q);const e=new ArrayBuffer(17*t.length),r=new Uint8Array(e);for(let e=0;e<t.length;e++){const n=t[e];let i=n.z;n.isDir&&(i|=128),r[17*e]=i,r[17*e+1]=255&n.x,r[17*e+2]=n.x>>8&255,r[17*e+3]=n.x>>16&255,r[17*e+4]=255&n.y,r[17*e+5]=n.y>>8&255,r[17*e+6]=n.y>>16&255,r[17*e+7]=255&n.offset,r[17*e+8]=255&G(n.offset,8),r[17*e+9]=255&G(n.offset,16),r[17*e+10]=255&G(n.offset,24),r[17*e+11]=255&G(n.offset,32),r[17*e+12]=255&G(n.offset,48),r[17*e+13]=255&n.length,r[17*e+14]=n.length>>8&255,r[17*e+15]=n.length>>16&255,r[17*e+16]=n.length>>24&255}return e},Y={getHeader:function(t){return l(this,null,(function*(){const e=yield t.getBytes(0,512e3),r=new DataView(e.data),n=r.getUint32(4,!0),i=r.getUint16(8,!0),s=new TextDecoder("utf-8"),o=JSON.parse(s.decode(new DataView(e.data,10,n)));let a=0;"gzip"===o.compression&&(a=2);let l=0;"minzoom"in o&&(l=+o.minzoom);let c=0;"maxzoom"in o&&(c=+o.maxzoom);let u=0,h=0,d=0,f=-180,p=-85,m=180,g=85;if(o.bounds){const t=o.bounds.split(",");f=+t[0],p=+t[1],m=+t[2],g=+t[3]}if(o.center){const t=o.center.split(",");u=+t[0],h=+t[1],d=+t[2]}return{specVersion:r.getUint16(2,!0),rootDirectoryOffset:10+n,rootDirectoryLength:17*i,jsonMetadataOffset:10,jsonMetadataLength:n,leafDirectoryOffset:0,leafDirectoryLength:void 0,tileDataOffset:0,tileDataLength:void 0,numAddressedTiles:0,numTileEntries:0,numTileContents:0,clustered:!1,internalCompression:1,tileCompression:a,tileType:1,minZoom:l,maxZoom:c,minLon:f,minLat:p,maxLon:m,maxLat:g,centerZoom:d,centerLon:u,centerLat:h,etag:e.etag}}))},getZxy:function(t,e,r,n,i,s,o){return l(this,null,(function*(){let a=yield r.getArrayBuffer(e,t.rootDirectoryOffset,t.rootDirectoryLength,t);1===t.specVersion&&(a=W(a));const l=B(new DataView(a),n,i,s);if(l){let t=(yield e.getBytes(l.offset,l.length,o)).data;const r=new DataView(t);return 31===r.getUint8(0)&&139===r.getUint8(1)&&(t=F(new Uint8Array(t))),{data:t}}const c=((t,e)=>{if(t.byteLength<17)return null;const r=t.byteLength/17,n=K(t,r-1);if(n.isDir){const t=n.z,r=e.z-t;return{z:t,x:Math.trunc(e.x/(1<<r)),y:Math.trunc(e.y/(1<<r))}}return null})(new DataView(a),{z:n,x:i,y:s});if(c){const l=((t,e,r,n)=>{const i=V(t,128|e,r,n);return i?{z:e,x:r,y:n,offset:i[0],length:i[1],isDir:!0}:null})(new DataView(a),c.z,c.x,c.y);if(l){let a=yield r.getArrayBuffer(e,l.offset,l.length,t);1===t.specVersion&&(a=W(a));const c=B(new DataView(a),n,i,s);if(c){let t=(yield e.getBytes(c.offset,c.length,o)).data;const r=new DataView(t);return 31===r.getUint8(0)&&139===r.getUint8(1)&&(t=F(new Uint8Array(t))),{data:t}}}}}))}};function X(t,e){return 4294967296*(e>>>0)+(t>>>0)}function Z(t){const e=t.buf;let r=e[t.pos++],n=127&r;return r<128?n:(r=e[t.pos++],n|=(127&r)<<7,r<128?n:(r=e[t.pos++],n|=(127&r)<<14,r<128?n:(r=e[t.pos++],n|=(127&r)<<21,r<128?n:(r=e[t.pos],n|=(15&r)<<28,function(t,e){const r=e.buf;let n=r[e.pos++],i=(112&n)>>4;if(n<128)return X(t,i);if(n=r[e.pos++],i|=(127&n)<<3,n<128)return X(t,i);if(n=r[e.pos++],i|=(127&n)<<10,n<128)return X(t,i);if(n=r[e.pos++],i|=(127&n)<<17,n<128)return X(t,i);if(n=r[e.pos++],i|=(127&n)<<24,n<128)return X(t,i);if(n=r[e.pos++],i|=(1&n)<<31,n<128)return X(t,i);throw new Error("Expected varint not more than 10 bytes")}(n,t)))))}function J(t,e,r,n){if(0===n){1===r&&(e[0]=t-1-e[0],e[1]=t-1-e[1]);const n=e[0];e[0]=e[1],e[1]=n}}var Q=[0,1,5,21,85,341,1365,5461,21845,87381,349525,1398101,5592405,22369621,89478485,357913941,1431655765,5726623061,22906492245,91625968981,366503875925,1466015503701,5864062014805,23456248059221,93824992236885,375299968947541,0x5555555555555];function tt(t,e){return l(this,null,(function*(){if(1===e||0===e)return t;if(2===e){if(void 0===globalThis.DecompressionStream)return F(new Uint8Array(t));const e=new Response(t).body;if(!e)throw Error("Failed to read response stream");const r=e.pipeThrough(new globalThis.DecompressionStream("gzip"));return new Response(r).arrayBuffer()}throw Error("Compression method not supported")}))}function et(t,e){let r=0,n=t.length-1;for(;r<=n;){const i=n+r>>1,s=e-t[i].tileId;if(s>0)r=i+1;else{if(!(s<0))return t[i];n=i-1}}if(n>=0){if(0===t[n].runLength)return t[n];if(e-t[n].tileId<t[n].runLength)return t[n]}return null}var rt=class{constructor(t,e=new Headers){this.url=t,this.customHeaders=e,this.mustReload=!1;let r="";"navigator"in globalThis&&(r=globalThis.navigator.userAgent||"");const n=r.indexOf("Windows")>-1,i=/Chrome|Chromium|Edg|OPR|Brave/.test(r);this.chromeWindowsNoCache=!1,n&&i&&(this.chromeWindowsNoCache=!0)}getKey(){return this.url}setHeaders(t){this.customHeaders=t}getBytes(t,e,r,n){return l(this,null,(function*(){let i,s;r?s=r:(i=new AbortController,s=i.signal);const o=new Headers(this.customHeaders);let a;o.set("range",`bytes=${t}-${t+e-1}`),this.mustReload?a="reload":this.chromeWindowsNoCache&&(a="no-store");let l=yield fetch(this.url,{signal:s,cache:a,headers:o});if(0===t&&416===l.status){const t=l.headers.get("Content-Range");if(!t||!t.startsWith("bytes */"))throw Error("Missing content-length on 416 response");const e=+t.substr(8);l=yield fetch(this.url,{signal:s,cache:"reload",headers:{range:"bytes=0-"+(e-1)}})}let c=l.headers.get("Etag");if((null==c?void 0:c.startsWith("W/"))&&(c=null),416===l.status||n&&c&&c!==n)throw this.mustReload=!0,new st(`Server returned non-matching ETag ${n} after one retry. Check browser extensions and servers for issues that may affect correct ETag headers.`);if(l.status>=300)throw Error(`Bad response code: ${l.status}`);const u=l.headers.get("Content-Length");if(200===l.status&&(!u||+u>e))throw i&&i.abort(),Error("Server returned no content-length header or content-length exceeding request. Check that your storage backend supports HTTP Byte Serving.");return{data:yield l.arrayBuffer(),etag:c||void 0,cacheControl:l.headers.get("Cache-Control")||void 0,expires:l.headers.get("Expires")||void 0}}))}};function nt(t,e){const r=t.getUint32(e+4,!0),n=t.getUint32(e+0,!0);return r*a(2,32)+n}function it(t){const e={buf:new Uint8Array(t),pos:0},r=Z(e),n=[];let i=0;for(let t=0;t<r;t++){const t=Z(e);n.push({tileId:i+t,offset:0,length:0,runLength:1}),i+=t}for(let t=0;t<r;t++)n[t].runLength=Z(e);for(let t=0;t<r;t++)n[t].length=Z(e);for(let t=0;t<r;t++){const r=Z(e);n[t].offset=0===r&&t>0?n[t-1].offset+n[t-1].length:r-1}return n}var st=class extends Error{};var ot=class{constructor(t=100,e=!0,r=tt){this.cache=new Map,this.invalidations=new Map,this.maxCacheEntries=t,this.counter=1,this.decompress=r}getHeader(t){return l(this,null,(function*(){const e=t.getKey(),r=this.cache.get(e);if(r)return r.lastUsed=this.counter++,yield r.data;const n=new Promise(((e,r)=>{(function(t,e){return l(this,null,(function*(){const r=yield t.getBytes(0,16384);if(19792!==new DataView(r.data).getUint16(0,!0))throw new Error("Wrong magic number for PMTiles archive");if(function(t){const e=new DataView(t);return 2===e.getUint16(2,!0)?(console.warn("PMTiles spec version 2 has been deprecated; please see github.com/protomaps/PMTiles for tools to upgrade"),2):1===e.getUint16(2,!0)?(console.warn("PMTiles spec version 1 has been deprecated; please see github.com/protomaps/PMTiles for tools to upgrade"),1):3}(r.data)<3)return[yield Y.getHeader(t)];const n=function(t,e){const r=new DataView(t),n=r.getUint8(7);if(n>3)throw Error(`Archive is spec version ${n} but this library supports up to spec version 3`);return{specVersion:n,rootDirectoryOffset:nt(r,8),rootDirectoryLength:nt(r,16),jsonMetadataOffset:nt(r,24),jsonMetadataLength:nt(r,32),leafDirectoryOffset:nt(r,40),leafDirectoryLength:nt(r,48),tileDataOffset:nt(r,56),tileDataLength:nt(r,64),numAddressedTiles:nt(r,72),numTileEntries:nt(r,80),numTileContents:nt(r,88),clustered:1===r.getUint8(96),internalCompression:r.getUint8(97),tileCompression:r.getUint8(98),tileType:r.getUint8(99),minZoom:r.getUint8(100),maxZoom:r.getUint8(101),minLon:r.getInt32(102,!0)/1e7,minLat:r.getInt32(106,!0)/1e7,maxLon:r.getInt32(110,!0)/1e7,maxLat:r.getInt32(114,!0)/1e7,centerZoom:r.getUint8(118),centerLon:r.getInt32(119,!0)/1e7,centerLat:r.getInt32(123,!0)/1e7,etag:e}}(r.data.slice(0,127),r.etag),i=r.data.slice(n.rootDirectoryOffset,n.rootDirectoryOffset+n.rootDirectoryLength),s=`${t.getKey()}|${n.etag||""}|${n.rootDirectoryOffset}|${n.rootDirectoryLength}`,o=it(yield e(i,n.internalCompression));return[n,[s,o.length,o]]}))})(t,this.decompress).then((t=>{t[1]&&this.cache.set(t[1][0],{lastUsed:this.counter++,data:Promise.resolve(t[1][2])}),e(t[0]),this.prune()})).catch((t=>{r(t)}))}));return this.cache.set(e,{lastUsed:this.counter++,data:n}),n}))}getDirectory(t,e,r,n){return l(this,null,(function*(){const i=`${t.getKey()}|${n.etag||""}|${e}|${r}`,s=this.cache.get(i);if(s)return s.lastUsed=this.counter++,yield s.data;const o=new Promise(((i,s)=>{(function(t,e,r,n,i){return l(this,null,(function*(){const s=yield t.getBytes(r,n,void 0,i.etag),o=it(yield e(s.data,i.internalCompression));if(0===o.length)throw new Error("Empty directory is invalid");return o}))})(t,this.decompress,e,r,n).then((t=>{i(t),this.prune()})).catch((t=>{s(t)}))}));return this.cache.set(i,{lastUsed:this.counter++,data:o}),o}))}getArrayBuffer(t,e,r,n){return l(this,null,(function*(){const i=`${t.getKey()}|${n.etag||""}|${e}|${r}`,s=this.cache.get(i);if(s)return s.lastUsed=this.counter++,yield s.data;const o=new Promise(((s,o)=>{t.getBytes(e,r,void 0,n.etag).then((t=>{s(t.data),this.cache.has(i),this.prune()})).catch((t=>{o(t)}))}));return this.cache.set(i,{lastUsed:this.counter++,data:o}),o}))}prune(){if(this.cache.size>=this.maxCacheEntries){let t,e=1/0;this.cache.forEach(((r,n)=>{r.lastUsed<e&&(e=r.lastUsed,t=n)})),t&&this.cache.delete(t)}}invalidate(t){return l(this,null,(function*(){const e=t.getKey();if(this.invalidations.get(e))return yield this.invalidations.get(e);this.cache.delete(t.getKey());const r=new Promise(((r,n)=>{this.getHeader(t).then((t=>{r(),this.invalidations.delete(e)})).catch((t=>{n(t)}))}));this.invalidations.set(e,r)}))}},at=class{constructor(t,e,r){this.source="string"==typeof t?new rt(t):t,this.decompress=r||tt,this.cache=e||new ot}getHeader(){return l(this,null,(function*(){return yield this.cache.getHeader(this.source)}))}getZxyAttempt(t,e,r,n){return l(this,null,(function*(){const i=function(t,e,r){if(t>26)throw Error("Tile zoom level exceeds max safe number limit (26)");if(e>a(2,t)-1||r>a(2,t)-1)throw Error("tile x/y outside zoom level bounds");const n=Q[t];let i=0,s=0,o=0;const l=[e,r];let c=a(2,t)/2;for(;c>0;)i=(l[0]&c)>0?1:0,s=(l[1]&c)>0?1:0,o+=c*c*(3*i^s),J(c,l,i,s),c/=2;return n+o}(t,e,r),s=yield this.cache.getHeader(this.source);if(s.specVersion<3)return Y.getZxy(s,this.source,this.cache,t,e,r,n);if(t<s.minZoom||t>s.maxZoom)return;let o=s.rootDirectoryOffset,l=s.rootDirectoryLength;for(let t=0;t<=3;t++){const t=et(yield this.cache.getDirectory(this.source,o,l,s),i);if(!t)return;if(t.runLength>0){const e=yield this.source.getBytes(s.tileDataOffset+t.offset,t.length,n,s.etag);return{data:yield this.decompress(e.data,s.tileCompression),cacheControl:e.cacheControl,expires:e.expires}}o=s.leafDirectoryOffset+t.offset,l=t.length}throw Error("Maximum directory depth exceeded")}))}getZxy(t,e,r,n){return l(this,null,(function*(){try{return yield this.getZxyAttempt(t,e,r,n)}catch(i){if(i instanceof st)return this.cache.invalidate(this.source),yield this.getZxyAttempt(t,e,r,n);throw i}}))}getMetadataAttempt(){return l(this,null,(function*(){const t=yield this.cache.getHeader(this.source),e=yield this.source.getBytes(t.jsonMetadataOffset,t.jsonMetadataLength,void 0,t.etag),r=yield this.decompress(e.data,t.internalCompression),n=new TextDecoder("utf-8");return JSON.parse(n.decode(r))}))}getMetadata(){return l(this,null,(function*(){try{return yield this.getMetadataAttempt()}catch(t){if(t instanceof st)return this.cache.invalidate(this.source),yield this.getMetadataAttempt();throw t}}))}getTileJson(t){return l(this,null,(function*(){const e=yield this.getHeader(),r=yield this.getMetadata(),n=1===(i=e.tileType)?".mvt":2===i?".png":3===i?".jpg":4===i?".webp":5===i?".avif":"";var i;return{tilejson:"3.0.0",scheme:"xyz",tiles:[`${t}/{z}/{x}/{y}${n}`],vector_layers:r.vector_layers,attribution:r.attribution,description:r.description,name:r.name,version:r.version,bounds:[e.minLon,e.minLat,e.maxLon,e.maxLat],center:[e.centerLon,e.centerLat,e.centerZoom],minzoom:e.minZoom,maxzoom:e.maxZoom}}))}};class lt extends n.A{loadImage=t=>new Promise(((e,r)=>{const n=new Image;n.addEventListener("load",(()=>e(n))),n.addEventListener("error",(()=>r(new Error("load failed")))),n.src=t}));constructor(t){super({...t,state:"loading"});const e=new rt(t.url,new Headers(t.headers)),r=new at(e);r.getHeader().then((t=>{this.tileGrid.minZoom=t.minZoom,this.tileGrid.maxZoom=t.maxZoom,this.setLoader((async(t,e,n)=>{const i=await r.getZxy(t,e,n),s=URL.createObjectURL(new Blob([i.data])),o=await this.loadImage(s);return URL.revokeObjectURL(s),o})),this.setState("ready")}))}}class ct extends i.A{tileLoadFunction=(t,e)=>{const r=new RegExp(/pmtiles:\/\/(.+)\/(\d+)\/(\d+)\/(\d+)/),n=e.match(r),i=+n[2],o=+n[3],a=+n[4];t.setLoader(((e,r,n)=>{this.pmtiles_.getZxy(i,o,a).then((r=>{if(r){const i=t.getFormat();t.setFeatures(i.readFeatures(r.data,{extent:e,featureProjection:n})),t.setState(s.A.LOADED)}else t.setFeatures([]),t.setState(s.A.EMPTY)})).catch((e=>{t.setFeatures([]),t.setState(s.A.ERROR)}))}))};constructor(t){super({...t,state:"loading",url:"pmtiles://"+t.url+"/{z}/{x}/{y}",format:t.format||new o.A});const e=new rt(t.url,new Headers(t.headers));this.pmtiles_=new at(e),this.pmtiles_.getHeader().then((t=>{this.tileGrid.minZoom=t.minZoom,this.tileGrid.maxZoom=t.maxZoom,this.setTileLoadFunction(this.tileLoadFunction),this.setState("ready")}))}}},20489:(t,e,r)=>{"use strict";r.d(e,{A:()=>c});var n=r(72614),i=r(45981),s=r(37283);const o="length";class a extends s.Ay{constructor(t,e,r){super(t),this.element=e,this.index=r}}class l extends n.A{constructor(t,e){if(super(),this.on,this.once,this.un,e=e||{},this.unique_=!!e.unique,this.array_=t||[],this.unique_)for(let t=0,e=this.array_.length;t<e;++t)this.assertUnique_(this.array_[t],t);this.updateLength_()}clear(){for(;this.getLength()>0;)this.pop()}extend(t){for(let e=0,r=t.length;e<r;++e)this.push(t[e]);return this}forEach(t){const e=this.array_;for(let r=0,n=e.length;r<n;++r)t(e[r],r,e)}getArray(){return this.array_}item(t){return this.array_[t]}getLength(){return this.get(o)}insertAt(t,e){if(t<0||t>this.getLength())throw new Error("Index out of bounds: "+t);this.unique_&&this.assertUnique_(e),this.array_.splice(t,0,e),this.updateLength_(),this.dispatchEvent(new a(i.A.ADD,e,t))}pop(){return this.removeAt(this.getLength()-1)}push(t){this.unique_&&this.assertUnique_(t);const e=this.getLength();return this.insertAt(e,t),this.getLength()}remove(t){const e=this.array_;for(let r=0,n=e.length;r<n;++r)if(e[r]===t)return this.removeAt(r)}removeAt(t){if(t<0||t>=this.getLength())return;const e=this.array_[t];return this.array_.splice(t,1),this.updateLength_(),this.dispatchEvent(new a(i.A.REMOVE,e,t)),e}setAt(t,e){if(t>=this.getLength())return void this.insertAt(t,e);if(t<0)throw new Error("Index out of bounds: "+t);this.unique_&&this.assertUnique_(e,t);const r=this.array_[t];this.array_[t]=e,this.dispatchEvent(new a(i.A.REMOVE,r,t)),this.dispatchEvent(new a(i.A.ADD,e,t))}updateLength_(){this.set(o,this.array_.length)}assertUnique_(t,e){for(let r=0,n=this.array_.length;r<n;++r)if(this.array_[r]===t&&r!==e)throw new Error("Duplicate item added to a unique collection")}}const c=l},45981:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={ADD:"add",REMOVE:"remove"}},97141:(t,e,r)=>{"use strict";r.d(e,{$r:()=>u,Ay:()=>f,bL:()=>a,xo:()=>o});var n=r(76741),i=r(20884),s=r(83085);function o(t){return t instanceof Image||t instanceof HTMLCanvasElement||t instanceof HTMLVideoElement||t instanceof ImageBitmap?t:null}function a(t){return t instanceof Uint8Array||t instanceof Uint8ClampedArray||t instanceof Float32Array||t instanceof DataView?t:null}const l=new Error("disposed");let c=null;function u(t){c||(c=(0,s.Y)(t.width,t.height,void 0,{willReadFrequently:!0}));const e=c.canvas,r=t.width;e.width!==r&&(e.width=r);const n=t.height;return e.height!==n&&(e.height=n),c.clearRect(0,0,r,n),c.drawImage(t,0,0),c.getImageData(0,0,r,n).data}const h=[256,256];class d extends n.A{constructor(t){const e=i.A.IDLE;super(t.tileCoord,e,{transition:t.transition,interpolate:t.interpolate}),this.loader_=t.loader,this.data_=null,this.error_=null,this.size_=t.size||null,this.controller_=t.controller||null}getSize(){if(this.size_)return this.size_;const t=o(this.data_);return t?[t.width,t.height]:h}getData(){return this.data_}getError(){return this.error_}load(){if(this.state!==i.A.IDLE&&this.state!==i.A.ERROR)return;this.state=i.A.LOADING,this.changed();const t=this;this.loader_().then((function(e){t.data_=e,t.state=i.A.LOADED,t.changed()})).catch((function(e){t.error_=e,t.state=i.A.ERROR,t.changed()}))}disposeInternal(){this.controller_&&(this.controller_.abort(l),this.controller_=null),super.disposeInternal()}}const f=d},60239:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n=class{constructor(){this.disposed=!1}dispose(){this.disposed||(this.disposed=!0,this.disposeInternal())}disposeInternal(){}}},75839:(t,e,r)=>{"use strict";r.d(e,{A:()=>l});var n=r(72614),i=r(24187),s=r(30878),o=r(94456);class a extends n.A{constructor(t){if(super(),this.on,this.once,this.un,this.id_=void 0,this.geometryName_="geometry",this.style_=null,this.styleFunction_=void 0,this.geometryChangeKey_=null,this.addChangeListener(this.geometryName_,this.handleGeometryChanged_),t)if("function"==typeof t.getSimplifiedGeometry){const e=t;this.setGeometry(e)}else{const e=t;this.setProperties(e)}}clone(){const t=new a(this.hasProperties()?this.getProperties():null);t.setGeometryName(this.getGeometryName());const e=this.getGeometry();e&&t.setGeometry(e.clone());const r=this.getStyle();return r&&t.setStyle(r),t}getGeometry(){return this.get(this.geometryName_)}getId(){return this.id_}getGeometryName(){return this.geometryName_}getStyle(){return this.style_}getStyleFunction(){return this.styleFunction_}handleGeometryChange_(){this.changed()}handleGeometryChanged_(){this.geometryChangeKey_&&((0,o.JH)(this.geometryChangeKey_),this.geometryChangeKey_=null);const t=this.getGeometry();t&&(this.geometryChangeKey_=(0,o.KT)(t,i.A.CHANGE,this.handleGeometryChange_,this)),this.changed()}setGeometry(t){this.set(this.geometryName_,t)}setStyle(t){this.style_=t,this.styleFunction_=t?function(t){if("function"==typeof t)return t;let e;return Array.isArray(t)?e=t:((0,s.v)("function"==typeof t.getZIndex,"Expected an `ol/style/Style` or an array of `ol/style/Style.js`"),e=[t]),function(){return e}}(t):void 0,this.changed()}setId(t){this.id_=t,this.changed()}setGeometryName(t){this.removeChangeListener(this.geometryName_,this.handleGeometryChanged_),this.geometryName_=t,this.addChangeListener(this.geometryName_,this.handleGeometryChanged_),this.handleGeometryChanged_()}}const l=a},77032:(t,e,r)=>{"use strict";r.d(e,{Ay:()=>f,D4:()=>d,RA:()=>h,f6:()=>u});var n=r(91086),i=r(24187),s=r(39915),o=r(66993),a=r(94456),l=r(97440);class c extends n.A{constructor(t,e,r,n){super(),this.extent=t,this.pixelRatio_=r,this.resolution=e,this.state="function"==typeof n?s.A.IDLE:n,this.image_=null,this.loader="function"==typeof n?n:null}changed(){this.dispatchEvent(i.A.CHANGE)}getExtent(){return this.extent}getImage(){return this.image_}getPixelRatio(){return this.pixelRatio_}getResolution(){return this.resolution}getState(){return this.state}load(){if(this.state==s.A.IDLE&&this.loader){this.state=s.A.LOADING,this.changed();const t=this.getResolution(),e=Array.isArray(t)?t[0]:t;(0,l.hq)((()=>this.loader(this.getExtent(),e,this.getPixelRatio()))).then((t=>{"image"in t&&(this.image_=t.image),"extent"in t&&(this.extent=t.extent),"resolution"in t&&(this.resolution=t.resolution),"pixelRatio"in t&&(this.pixelRatio_=t.pixelRatio),(t instanceof HTMLImageElement||t instanceof ImageBitmap||t instanceof HTMLCanvasElement||t instanceof HTMLVideoElement)&&(this.image_=t),this.state=s.A.LOADED})).catch((t=>{this.state=s.A.ERROR,console.error(t)})).finally((()=>this.changed()))}}setImage(t){this.image_=t}setResolution(t){this.resolution=t}}function u(t,e,r){const n=t;let s=!0,l=!1,c=!1;const u=[(0,a.Jz)(n,i.A.LOAD,(function(){c=!0,l||e()}))];return n.src&&o.DT?(l=!0,n.decode().then((function(){s&&e()})).catch((function(t){s&&(c?e():r())}))):u.push((0,a.Jz)(n,i.A.ERROR,r)),function(){s=!1,u.forEach(a.JH)}}function h(t,e){return e&&(t.src=e),t.src&&o.DT?new Promise(((e,r)=>t.decode().then((()=>e(t))).catch((n=>t.complete&&t.width?e(t):r(n))))):function(t){return new Promise(((e,r)=>{function n(){s(),e(t)}function i(){s(),r(new Error("Image load error"))}function s(){t.removeEventListener("load",n),t.removeEventListener("error",i)}t.addEventListener("load",n),t.addEventListener("error",i)}))}(t)}function d(t,e){return e&&(t.src=e),t.src&&o.DT&&o.XM?t.decode().then((()=>createImageBitmap(t))).catch((e=>{if(t.complete&&t.width)return t;throw e})):h(t)}const f=c},39915:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={IDLE:0,LOADING:1,LOADED:2,ERROR:3,EMPTY:4}},67564:(t,e,r)=>{"use strict";r.d(e,{A:()=>l});var n=r(76741),i=r(20884),s=r(83085),o=r(77032);class a extends n.A{constructor(t,e,r,n,i,s){super(t,e,s),this.crossOrigin_=n,this.src_=r,this.key=r,this.image_=new Image,null!==n&&(this.image_.crossOrigin=n),this.unlisten_=null,this.tileLoadFunction_=i}getImage(){return this.image_}setImage(t){this.image_=t,this.state=i.A.LOADED,this.unlistenImage_(),this.changed()}handleImageError_(){this.state=i.A.ERROR,this.unlistenImage_(),this.image_=function(){const t=(0,s.Y)(1,1);return t.fillStyle="rgba(0,0,0,0)",t.fillRect(0,0,1,1),t.canvas}(),this.changed()}handleImageLoad_(){const t=this.image_;t.naturalWidth&&t.naturalHeight?this.state=i.A.LOADED:this.state=i.A.EMPTY,this.unlistenImage_(),this.changed()}load(){this.state==i.A.ERROR&&(this.state=i.A.IDLE,this.image_=new Image,null!==this.crossOrigin_&&(this.image_.crossOrigin=this.crossOrigin_)),this.state==i.A.IDLE&&(this.state=i.A.LOADING,this.changed(),this.tileLoadFunction_(this,this.src_),this.unlisten_=(0,o.f6)(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this)))}unlistenImage_(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)}disposeInternal(){this.unlistenImage_(),this.image_=null,super.disposeInternal()}}const l=a},81758:(t,e,r)=>{"use strict";r.d(e,{A:()=>ee});var n=r(72614),i=r(20489),s=r(45981),o=r(69199),a=r(60239),l=r(97440),c=r(98629),u=r(37377),h=r(44509),d=r(67031),f=r(73626),p=r(9535);class m extends a.A{constructor(t){super(),this.map_=t}dispatchRenderEvent(t,e){(0,c.b0)()}calculateMatrices2D(t){const e=t.viewState,r=t.coordinateToPixelTransform,n=t.pixelToCoordinateTransform;(0,u.Zz)(r,t.size[0]/2,t.size[1]/2,1/e.resolution,-1/e.resolution,-e.rotation,-e.center[0],-e.center[1]),(0,u.T9)(n,r)}forEachFeatureAtCoordinate(t,e,r,n,i,s,o,a){let l;const c=e.viewState;function u(t,e,r,n){return i.call(s,e,t?r:null,n)}const d=c.projection,m=(0,p.Li)(t.slice(),d),g=[[0,0]];if(d.canWrapX()&&n){const t=d.getExtent(),e=(0,h.RG)(t);g.push([-e,0],[e,0])}const y=e.layerStatesArray,v=y.length,_=[],b=[];for(let n=0;n<g.length;n++)for(let i=v-1;i>=0;--i){const s=y[i],h=s.layer;if(h.hasRenderer()&&(0,f.l)(s,c)&&o.call(a,h)){const i=h.getRenderer(),o=h.getSource();if(i&&o){const a=o.getWrapX()?m:t,c=u.bind(null,s.managed);b[0]=a[0]+g[n][0],b[1]=a[1]+g[n][1],l=i.forEachFeatureAtCoordinate(b,e,r,c,_)}if(l)return l}}if(0===_.length)return;const w=1/_.length;return _.forEach(((t,e)=>t.distanceSq+=e*w)),_.sort(((t,e)=>t.distanceSq-e.distanceSq)),_.some((t=>l=t.callback(t.feature,t.layer,t.geometry))),l}hasFeatureAtCoordinate(t,e,r,n,i,s){return void 0!==this.forEachFeatureAtCoordinate(t,e,r,n,l.rT,this,i,s)}getMap(){return this.map_}renderFrame(t){(0,c.b0)()}scheduleExpireIconCache(t){d.ue.canExpireCache()&&t.postRenderFunctions.push(g)}}function g(t,e){d.ue.expire()}const y=m;var v=r(56644),_=r(3094),b=r(45630),w=r(71686),x=r(33976),E=r(94456),S=r(83085);const A=class extends y{constructor(t){super(t),this.fontChangeListenerKey_=(0,E.KT)(x.yY,v.A.PROPERTYCHANGE,t.redrawText,t),this.element_=document.createElement("div");const e=this.element_.style;e.position="absolute",e.width="100%",e.height="100%",e.zIndex="0",this.element_.className=w.XI+" ol-layers";const r=t.getViewport();r.insertBefore(this.element_,r.firstChild||null),this.children_=[],this.renderedVisible_=!0}dispatchRenderEvent(t,e){const r=this.getMap();if(r.hasListener(t)){const n=new _.A(t,void 0,e);r.dispatchEvent(n)}}disposeInternal(){(0,E.JH)(this.fontChangeListenerKey_),this.element_.remove(),super.disposeInternal()}renderFrame(t){if(!t)return void(this.renderedVisible_&&(this.element_.style.display="none",this.renderedVisible_=!1));this.calculateMatrices2D(t),this.dispatchRenderEvent(b.A.PRECOMPOSE,t);const e=t.layerStatesArray.sort(((t,e)=>t.zIndex-e.zIndex));e.some((t=>t.layer instanceof o.A&&t.layer.getDeclutter()))&&(t.declutter={});const r=t.viewState;this.children_.length=0;const n=[];let i=null;for(let s=0,o=e.length;s<o;++s){const o=e[s];t.layerIndex=s;const a=o.layer,l=a.getSourceState();if(!(0,f.l)(o,r)||"ready"!=l&&"undefined"!=l){a.unrender();continue}const c=a.render(t,i);c&&(c!==i&&(this.children_.push(c),i=c),n.push(o))}this.declutter(t,n),(0,S.WM)(this.element_,this.children_),this.dispatchRenderEvent(b.A.POSTCOMPOSE,t),this.renderedVisible_||(this.element_.style.display="",this.renderedVisible_=!0),this.scheduleExpireIconCache(t)}declutter(t,e){if(t.declutter){for(let r=e.length-1;r>=0;--r){const n=e[r],i=n.layer;i.getDeclutter()&&i.renderDeclutter(t,n)}e.forEach((e=>e.layer.renderDeferred(t)))}}};var P=r(24187),T=r(93450),C=r(37283),M=r(30878),O=r(82048);class R extends C.Ay{constructor(t,e){super(t),this.layer=e}}const D="layers";class I extends T.A{constructor(t){t=t||{};const e=Object.assign({},t);delete e.layers;let r=t.layers;super(e),this.on,this.once,this.un,this.layersListenerKeys_=[],this.listenerKeys_={},this.addChangeListener(D,this.handleLayersChanged_),r?Array.isArray(r)?r=new i.A(r.slice(),{unique:!0}):(0,M.v)("function"==typeof r.getArray,"Expected `layers` to be an array or a `Collection`"):r=new i.A(void 0,{unique:!0}),this.setLayers(r)}handleLayerChange_(){this.changed()}handleLayersChanged_(){this.layersListenerKeys_.forEach(E.JH),this.layersListenerKeys_.length=0;const t=this.getLayers();this.layersListenerKeys_.push((0,E.KT)(t,s.A.ADD,this.handleLayersAdd_,this),(0,E.KT)(t,s.A.REMOVE,this.handleLayersRemove_,this));for(const t in this.listenerKeys_)this.listenerKeys_[t].forEach(E.JH);(0,O.I)(this.listenerKeys_);const e=t.getArray();for(let t=0,r=e.length;t<r;t++){const r=e[t];this.registerLayerListeners_(r),this.dispatchEvent(new R("addlayer",r))}this.changed()}registerLayerListeners_(t){const e=[(0,E.KT)(t,v.A.PROPERTYCHANGE,this.handleLayerChange_,this),(0,E.KT)(t,P.A.CHANGE,this.handleLayerChange_,this)];t instanceof I&&e.push((0,E.KT)(t,"addlayer",this.handleLayerGroupAdd_,this),(0,E.KT)(t,"removelayer",this.handleLayerGroupRemove_,this)),this.listenerKeys_[(0,c.v6)(t)]=e}handleLayerGroupAdd_(t){this.dispatchEvent(new R("addlayer",t.layer))}handleLayerGroupRemove_(t){this.dispatchEvent(new R("removelayer",t.layer))}handleLayersAdd_(t){const e=t.element;this.registerLayerListeners_(e),this.dispatchEvent(new R("addlayer",e)),this.changed()}handleLayersRemove_(t){const e=t.element,r=(0,c.v6)(e);this.listenerKeys_[r].forEach(E.JH),delete this.listenerKeys_[r],this.dispatchEvent(new R("removelayer",e)),this.changed()}getLayers(){return this.get(D)}setLayers(t){const e=this.getLayers();if(e){const t=e.getArray();for(let e=0,r=t.length;e<r;++e)this.dispatchEvent(new R("removelayer",t[e]))}this.set(D,t)}getLayersArray(t){return t=void 0!==t?t:[],this.getLayers().forEach((function(e){e.getLayersArray(t)})),t}getLayerStatesArray(t){const e=void 0!==t?t:[],r=e.length;this.getLayers().forEach((function(t){t.getLayerStatesArray(e)}));const n=this.getLayerState();let i=n.zIndex;t||void 0!==n.zIndex||(i=0);for(let t=r,s=e.length;t<s;t++){const r=e[t];r.opacity*=n.opacity,r.visible=r.visible&&n.visible,r.maxResolution=Math.min(r.maxResolution,n.maxResolution),r.minResolution=Math.max(r.minResolution,n.minResolution),r.minZoom=Math.max(r.minZoom,n.minZoom),r.maxZoom=Math.min(r.maxZoom,n.maxZoom),void 0!==n.extent&&(void 0!==r.extent?r.extent=(0,h._N)(r.extent,n.extent):r.extent=n.extent),void 0===r.zIndex&&(r.zIndex=i)}return e}getSourceState(){return"ready"}}const k=I;class L extends C.Ay{constructor(t,e,r){super(t),this.map=e,this.frameState=void 0!==r?r:null}}const F=L,j=class extends F{constructor(t,e,r,n,i,s){super(t,e,i),this.originalEvent=r,this.pixel_=null,this.coordinate_=null,this.dragging=void 0!==n&&n,this.activePointers=s}get pixel(){return this.pixel_||(this.pixel_=this.map.getEventPixel(this.originalEvent)),this.pixel_}set pixel(t){this.pixel_=t}get coordinate(){return this.coordinate_||(this.coordinate_=this.map.getCoordinateFromPixel(this.pixel)),this.coordinate_}set coordinate(t){this.coordinate_=t}preventDefault(){super.preventDefault(),"preventDefault"in this.originalEvent&&this.originalEvent.preventDefault()}stopPropagation(){super.stopPropagation(),"stopPropagation"in this.originalEvent&&this.originalEvent.stopPropagation()}},N={SINGLECLICK:"singleclick",CLICK:P.A.CLICK,DBLCLICK:P.A.DBLCLICK,POINTERDRAG:"pointerdrag",POINTERMOVE:"pointermove",POINTERDOWN:"pointerdown",POINTERUP:"pointerup",POINTEROVER:"pointerover",POINTEROUT:"pointerout",POINTERENTER:"pointerenter",POINTERLEAVE:"pointerleave",POINTERCANCEL:"pointercancel"},G="pointerdown";var $=r(91086),z=r(66993);class U extends $.A{constructor(t,e){super(t),this.map_=t,this.clickTimeoutId_,this.emulateClicks_=!1,this.dragging_=!1,this.dragListenerKeys_=[],this.moveTolerance_=void 0===e?1:e,this.down_=null;const r=this.map_.getViewport();this.activePointers_=[],this.trackedTouches_={},this.element_=r,this.pointerdownListenerKey_=(0,E.KT)(r,G,this.handlePointerDown_,this),this.originalPointerMoveEvent_,this.relayedListenerKey_=(0,E.KT)(r,"pointermove",this.relayMoveEvent_,this),this.boundHandleTouchMove_=this.handleTouchMove_.bind(this),this.element_.addEventListener(P.A.TOUCHMOVE,this.boundHandleTouchMove_,!!z.FT&&{passive:!1})}emulateClick_(t){let e=new j(N.CLICK,this.map_,t);this.dispatchEvent(e),void 0!==this.clickTimeoutId_?(clearTimeout(this.clickTimeoutId_),this.clickTimeoutId_=void 0,e=new j(N.DBLCLICK,this.map_,t),this.dispatchEvent(e)):this.clickTimeoutId_=setTimeout((()=>{this.clickTimeoutId_=void 0;const e=new j(N.SINGLECLICK,this.map_,t);this.dispatchEvent(e)}),250)}updateActivePointers_(t){const e=t,r=e.pointerId;if(e.type==N.POINTERUP||e.type==N.POINTERCANCEL){delete this.trackedTouches_[r];for(const t in this.trackedTouches_)if(this.trackedTouches_[t].target!==e.target){delete this.trackedTouches_[t];break}}else e.type!=N.POINTERDOWN&&e.type!=N.POINTERMOVE||(this.trackedTouches_[r]=e);this.activePointers_=Object.values(this.trackedTouches_)}handlePointerUp_(t){this.updateActivePointers_(t);const e=new j(N.POINTERUP,this.map_,t,void 0,void 0,this.activePointers_);this.dispatchEvent(e),this.emulateClicks_&&!e.defaultPrevented&&!this.dragging_&&this.isMouseActionButton_(t)&&this.emulateClick_(this.down_),0===this.activePointers_.length&&(this.dragListenerKeys_.forEach(E.JH),this.dragListenerKeys_.length=0,this.dragging_=!1,this.down_=null)}isMouseActionButton_(t){return 0===t.button}handlePointerDown_(t){this.emulateClicks_=0===this.activePointers_.length,this.updateActivePointers_(t);const e=new j(N.POINTERDOWN,this.map_,t,void 0,void 0,this.activePointers_);if(this.dispatchEvent(e),this.down_=new PointerEvent(t.type,t),Object.defineProperty(this.down_,"target",{writable:!1,value:t.target}),0===this.dragListenerKeys_.length){const t=this.map_.getOwnerDocument();this.dragListenerKeys_.push((0,E.KT)(t,N.POINTERMOVE,this.handlePointerMove_,this),(0,E.KT)(t,N.POINTERUP,this.handlePointerUp_,this),(0,E.KT)(this.element_,N.POINTERCANCEL,this.handlePointerUp_,this)),this.element_.getRootNode&&this.element_.getRootNode()!==t&&this.dragListenerKeys_.push((0,E.KT)(this.element_.getRootNode(),N.POINTERUP,this.handlePointerUp_,this))}}handlePointerMove_(t){if(this.isMoving_(t)){this.updateActivePointers_(t),this.dragging_=!0;const e=new j(N.POINTERDRAG,this.map_,t,this.dragging_,void 0,this.activePointers_);this.dispatchEvent(e)}}relayMoveEvent_(t){this.originalPointerMoveEvent_=t;const e=!(!this.down_||!this.isMoving_(t));this.dispatchEvent(new j(N.POINTERMOVE,this.map_,t,e))}handleTouchMove_(t){const e=this.originalPointerMoveEvent_;e&&!e.defaultPrevented||"boolean"==typeof t.cancelable&&!0!==t.cancelable||t.preventDefault()}isMoving_(t){return this.dragging_||Math.abs(t.clientX-this.down_.clientX)>this.moveTolerance_||Math.abs(t.clientY-this.down_.clientY)>this.moveTolerance_}disposeInternal(){this.relayedListenerKey_&&((0,E.JH)(this.relayedListenerKey_),this.relayedListenerKey_=null),this.element_.removeEventListener(P.A.TOUCHMOVE,this.boundHandleTouchMove_),this.pointerdownListenerKey_&&((0,E.JH)(this.pointerdownListenerKey_),this.pointerdownListenerKey_=null),this.dragListenerKeys_.forEach(E.JH),this.dragListenerKeys_.length=0,this.element_=null,super.disposeInternal()}}const B=U;var V=r(63479);const q="layergroup",K="size",W="target",H="view",Y=1/0,X=class{constructor(t,e){this.priorityFunction_=t,this.keyFunction_=e,this.elements_=[],this.priorities_=[],this.queuedElements_={}}clear(){this.elements_.length=0,this.priorities_.length=0,(0,O.I)(this.queuedElements_)}dequeue(){const t=this.elements_,e=this.priorities_,r=t[0];1==t.length?(t.length=0,e.length=0):(t[0]=t.pop(),e[0]=e.pop(),this.siftUp_(0));const n=this.keyFunction_(r);return delete this.queuedElements_[n],r}enqueue(t){(0,M.v)(!(this.keyFunction_(t)in this.queuedElements_),"Tried to enqueue an `element` that was already added to the queue");const e=this.priorityFunction_(t);return e!=Y&&(this.elements_.push(t),this.priorities_.push(e),this.queuedElements_[this.keyFunction_(t)]=!0,this.siftDown_(0,this.elements_.length-1),!0)}getCount(){return this.elements_.length}getLeftChildIndex_(t){return 2*t+1}getRightChildIndex_(t){return 2*t+2}getParentIndex_(t){return t-1>>1}heapify_(){let t;for(t=(this.elements_.length>>1)-1;t>=0;t--)this.siftUp_(t)}isEmpty(){return 0===this.elements_.length}isKeyQueued(t){return t in this.queuedElements_}isQueued(t){return this.isKeyQueued(this.keyFunction_(t))}siftUp_(t){const e=this.elements_,r=this.priorities_,n=e.length,i=e[t],s=r[t],o=t;for(;t<n>>1;){const i=this.getLeftChildIndex_(t),s=this.getRightChildIndex_(t),o=s<n&&r[s]<r[i]?s:i;e[t]=e[o],r[t]=r[o],t=o}e[t]=i,r[t]=s,this.siftDown_(o,t)}siftDown_(t,e){const r=this.elements_,n=this.priorities_,i=r[e],s=n[e];for(;e>t;){const t=this.getParentIndex_(e);if(!(n[t]>s))break;r[e]=r[t],n[e]=n[t],e=t}r[e]=i,n[e]=s}reprioritize(){const t=this.priorityFunction_,e=this.elements_,r=this.priorities_;let n=0;const i=e.length;let s,o,a;for(o=0;o<i;++o)s=e[o],a=t(s),a==Y?delete this.queuedElements_[this.keyFunction_(s)]:(r[n]=a,e[n++]=s);e.length=n,r.length=n,this.heapify_()}};var Z=r(20884);const J=class extends X{constructor(t,e){super((function(e){return t.apply(null,e)}),(function(t){return t[0].getKey()})),this.boundHandleTileChange_=this.handleTileChange.bind(this),this.tileChangeCallback_=e,this.tilesLoading_=0,this.tilesLoadingKeys_={}}enqueue(t){const e=super.enqueue(t);return e&&t[0].addEventListener(P.A.CHANGE,this.boundHandleTileChange_),e}getTilesLoading(){return this.tilesLoading_}handleTileChange(t){const e=t.target,r=e.getState();if(r===Z.A.LOADED||r===Z.A.ERROR||r===Z.A.EMPTY){r!==Z.A.ERROR&&e.removeEventListener(P.A.CHANGE,this.boundHandleTileChange_);const t=e.getKey();t in this.tilesLoadingKeys_&&(delete this.tilesLoadingKeys_[t],--this.tilesLoading_),this.tileChangeCallback_()}}loadMoreTiles(t,e){let r=0;for(;this.tilesLoading_<t&&r<e&&this.getCount()>0;){const t=this.dequeue()[0],e=t.getKey();t.getState()!==Z.A.IDLE||e in this.tilesLoadingKeys_||(this.tilesLoadingKeys_[e]=!0,++this.tilesLoading_,++r,t.load())}}};var Q=r(95854),tt=r(32769),et=r(41554),rt=r(30444);class nt extends et.A{constructor(t){t=t||{},super({element:document.createElement("div"),render:t.render,target:t.target}),this.ulElement_=document.createElement("ul"),this.collapsed_=void 0===t.collapsed||t.collapsed,this.userCollapsed_=this.collapsed_,this.overrideCollapsible_=void 0!==t.collapsible,this.collapsible_=void 0===t.collapsible||t.collapsible,this.collapsible_||(this.collapsed_=!1),this.attributions_=t.attributions;const e=void 0!==t.className?t.className:"ol-attribution",r=void 0!==t.tipLabel?t.tipLabel:"Attributions",n=void 0!==t.expandClassName?t.expandClassName:e+"-expand",i=void 0!==t.collapseLabel?t.collapseLabel:"›",s=void 0!==t.collapseClassName?t.collapseClassName:e+"-collapse";"string"==typeof i?(this.collapseLabel_=document.createElement("span"),this.collapseLabel_.textContent=i,this.collapseLabel_.className=s):this.collapseLabel_=i;const o=void 0!==t.label?t.label:"i";"string"==typeof o?(this.label_=document.createElement("span"),this.label_.textContent=o,this.label_.className=n):this.label_=o;const a=this.collapsible_&&!this.collapsed_?this.collapseLabel_:this.label_;this.toggleButton_=document.createElement("button"),this.toggleButton_.setAttribute("type","button"),this.toggleButton_.setAttribute("aria-expanded",String(!this.collapsed_)),this.toggleButton_.title=r,this.toggleButton_.appendChild(a),this.toggleButton_.addEventListener(P.A.CLICK,this.handleClick_.bind(this),!1);const l=e+" "+w.XI+" "+w.$N+(this.collapsed_&&this.collapsible_?" "+w.nT:"")+(this.collapsible_?"":" ol-uncollapsible"),c=this.element;c.className=l,c.appendChild(this.toggleButton_),c.appendChild(this.ulElement_),this.renderedAttributions_=[],this.renderedVisible_=!0}collectSourceAttributions_(t){const e=this.getMap().getAllLayers(),r=new Set(e.flatMap((e=>e.getAttributions(t))));if(void 0!==this.attributions_&&(Array.isArray(this.attributions_)?this.attributions_.forEach((t=>r.add(t))):r.add(this.attributions_)),!this.overrideCollapsible_){const t=!e.some((t=>!1===t.getSource()?.getAttributionsCollapsible()));this.setCollapsible(t)}return Array.from(r)}async updateElement_(t){if(!t)return void(this.renderedVisible_&&(this.element.style.display="none",this.renderedVisible_=!1));const e=await Promise.all(this.collectSourceAttributions_(t).map((t=>(0,l.hq)((()=>t))))),r=e.length>0;if(this.renderedVisible_!=r&&(this.element.style.display=r?"":"none",this.renderedVisible_=r),!(0,rt.aI)(e,this.renderedAttributions_)){(0,S.gS)(this.ulElement_);for(let t=0,r=e.length;t<r;++t){const r=document.createElement("li");r.innerHTML=e[t],this.ulElement_.appendChild(r)}this.renderedAttributions_=e}}handleClick_(t){t.preventDefault(),this.handleToggle_(),this.userCollapsed_=this.collapsed_}handleToggle_(){this.element.classList.toggle(w.nT),this.collapsed_?(0,S.fo)(this.collapseLabel_,this.label_):(0,S.fo)(this.label_,this.collapseLabel_),this.collapsed_=!this.collapsed_,this.toggleButton_.setAttribute("aria-expanded",String(!this.collapsed_))}getCollapsible(){return this.collapsible_}setCollapsible(t){this.collapsible_!==t&&(this.collapsible_=t,this.element.classList.toggle("ol-uncollapsible"),this.userCollapsed_&&this.handleToggle_())}setCollapsed(t){this.userCollapsed_=t,this.collapsible_&&this.collapsed_!==t&&this.handleToggle_()}getCollapsed(){return this.collapsed_}render(t){this.updateElement_(t.frameState)}}const it=nt;var st=r(2620);class ot extends et.A{constructor(t){t=t||{},super({element:document.createElement("div"),render:t.render,target:t.target});const e=void 0!==t.className?t.className:"ol-rotate",r=void 0!==t.label?t.label:"⇧",n=void 0!==t.compassClassName?t.compassClassName:"ol-compass";this.label_=null,"string"==typeof r?(this.label_=document.createElement("span"),this.label_.className=n,this.label_.textContent=r):(this.label_=r,this.label_.classList.add(n));const i=t.tipLabel?t.tipLabel:"Reset rotation",s=document.createElement("button");s.className=e+"-reset",s.setAttribute("type","button"),s.title=i,s.appendChild(this.label_),s.addEventListener(P.A.CLICK,this.handleClick_.bind(this),!1);const o=e+" "+w.XI+" "+w.$N,a=this.element;a.className=o,a.appendChild(s),this.callResetNorth_=t.resetNorth?t.resetNorth:void 0,this.duration_=void 0!==t.duration?t.duration:250,this.autoHide_=void 0===t.autoHide||t.autoHide,this.rotation_=void 0,this.autoHide_&&this.element.classList.add(w.Si)}handleClick_(t){t.preventDefault(),void 0!==this.callResetNorth_?this.callResetNorth_():this.resetNorth_()}resetNorth_(){const t=this.getMap().getView();if(!t)return;const e=t.getRotation();void 0!==e&&(this.duration_>0&&e%(2*Math.PI)!=0?t.animate({rotation:0,duration:this.duration_,easing:st.vT}):t.setRotation(0))}render(t){const e=t.frameState;if(!e)return;const r=e.viewState.rotation;if(r!=this.rotation_){const t="rotate("+r+"rad)";if(this.autoHide_){const t=this.element.classList.contains(w.Si);t||0!==r?t&&0!==r&&this.element.classList.remove(w.Si):this.element.classList.add(w.Si)}this.label_.style.transform=t}this.rotation_=r}}const at=ot;class lt extends et.A{constructor(t){t=t||{},super({element:document.createElement("div"),target:t.target});const e=void 0!==t.className?t.className:"ol-zoom",r=void 0!==t.delta?t.delta:1,n=void 0!==t.zoomInClassName?t.zoomInClassName:e+"-in",i=void 0!==t.zoomOutClassName?t.zoomOutClassName:e+"-out",s=void 0!==t.zoomInLabel?t.zoomInLabel:"+",o=void 0!==t.zoomOutLabel?t.zoomOutLabel:"–",a=void 0!==t.zoomInTipLabel?t.zoomInTipLabel:"Zoom in",l=void 0!==t.zoomOutTipLabel?t.zoomOutTipLabel:"Zoom out",c=document.createElement("button");c.className=n,c.setAttribute("type","button"),c.title=a,c.appendChild("string"==typeof s?document.createTextNode(s):s),c.addEventListener(P.A.CLICK,this.handleClick_.bind(this,r),!1);const u=document.createElement("button");u.className=i,u.setAttribute("type","button"),u.title=l,u.appendChild("string"==typeof o?document.createTextNode(o):o),u.addEventListener(P.A.CLICK,this.handleClick_.bind(this,-r),!1);const h=e+" "+w.XI+" "+w.$N,d=this.element;d.className=h,d.appendChild(c),d.appendChild(u),this.duration_=void 0!==t.duration?t.duration:250}handleClick_(t,e){e.preventDefault(),this.zoomByDelta_(t)}zoomByDelta_(t){const e=this.getMap().getView();if(!e)return;const r=e.getZoom();if(void 0!==r){const n=e.getConstrainedZoom(r+t);this.duration_>0?(e.getAnimating()&&e.cancelAnimations(),e.animate({zoom:n,duration:this.duration_,easing:st.vT})):e.setZoom(n)}}}const ct=lt;var ut=r(78083);class ht extends ut.Ay{constructor(t){super(),t=t||{},this.delta_=t.delta?t.delta:1,this.duration_=void 0!==t.duration?t.duration:250}handleEvent(t){let e=!1;if(t.type==N.DBLCLICK){const r=t.originalEvent,n=t.map,i=t.coordinate,s=r.shiftKey?-this.delta_:this.delta_,o=n.getView();(0,ut.D2)(o,s,i,this.duration_),r.preventDefault(),e=!0}return!e}}const dt=ht;class ft extends ut.Ay{constructor(t){super(t=t||{}),t.handleDownEvent&&(this.handleDownEvent=t.handleDownEvent),t.handleDragEvent&&(this.handleDragEvent=t.handleDragEvent),t.handleMoveEvent&&(this.handleMoveEvent=t.handleMoveEvent),t.handleUpEvent&&(this.handleUpEvent=t.handleUpEvent),t.stopDown&&(this.stopDown=t.stopDown),this.handlingDownUpSequence=!1,this.targetPointers=[]}getPointerCount(){return this.targetPointers.length}handleDownEvent(t){return!1}handleDragEvent(t){}handleEvent(t){if(!t.originalEvent)return!0;let e=!1;if(this.updateTrackedPointers_(t),this.handlingDownUpSequence){if(t.type==N.POINTERDRAG)this.handleDragEvent(t),t.originalEvent.preventDefault();else if(t.type==N.POINTERUP){const e=this.handleUpEvent(t);this.handlingDownUpSequence=e&&this.targetPointers.length>0}}else if(t.type==N.POINTERDOWN){const r=this.handleDownEvent(t);this.handlingDownUpSequence=r,e=this.stopDown(r)}else t.type==N.POINTERMOVE&&this.handleMoveEvent(t);return!e}handleMoveEvent(t){}handleUpEvent(t){return!1}stopDown(t){return t}updateTrackedPointers_(t){t.activePointers&&(this.targetPointers=t.activePointers)}}function pt(t){const e=t.length;let r=0,n=0;for(let i=0;i<e;i++)r+=t[i].clientX,n+=t[i].clientY;return{clientX:r/e,clientY:n/e}}const mt=ft;function gt(t){const e=arguments;return function(t){let r=!0;for(let n=0,i=e.length;n<i&&(r=r&&e[n](t),r);++n);return r}}const yt=function(t){const e=t.originalEvent;return e.altKey&&!(e.metaKey||e.ctrlKey)&&e.shiftKey},vt=function(t){const e=t.map.getTargetElement(),r=e.getRootNode();return!(r instanceof ShadowRoot?r.host:e).hasAttribute("tabindex")||function(t){const e=t.map.getTargetElement(),r=e.getRootNode(),n=t.map.getOwnerDocument().activeElement;return r instanceof ShadowRoot?r.host.contains(n):e.contains(n)}(t)},_t=l.rT,bt=function(t){const e=t.originalEvent;return 0==e.button&&!(z.j&&z.ew&&e.ctrlKey)},wt=function(t){const e=t.originalEvent;return!e.altKey&&!(e.metaKey||e.ctrlKey)&&!e.shiftKey},xt=function(t){const e=t.originalEvent;return!e.altKey&&!(e.metaKey||e.ctrlKey)&&e.shiftKey},Et=function(t){const e=t.originalEvent,r=e.target.tagName;return"INPUT"!==r&&"SELECT"!==r&&"TEXTAREA"!==r&&!e.target.isContentEditable},St=function(t){const e=t.originalEvent;return(0,M.v)(void 0!==e,"mapBrowserEvent must originate from a pointer event"),"mouse"==e.pointerType},At=function(t){const e=t.originalEvent;return(0,M.v)(void 0!==e,"mapBrowserEvent must originate from a pointer event"),e.isPrimary&&0===e.button},Pt=class extends mt{constructor(t){super({stopDown:l.W8}),t=t||{},this.kinetic_=t.kinetic,this.lastCentroid=null,this.lastPointersCount_,this.panning_=!1;const e=t.condition?t.condition:gt(wt,At);this.condition_=t.onFocusOnly?gt(vt,e):e,this.noKinetic_=!1}handleDragEvent(t){const e=t.map;this.panning_||(this.panning_=!0,e.getView().beginInteraction());const r=this.targetPointers,n=e.getEventPixel(pt(r));if(r.length==this.lastPointersCount_){if(this.kinetic_&&this.kinetic_.update(n[0],n[1]),this.lastCentroid){const e=[this.lastCentroid[0]-n[0],n[1]-this.lastCentroid[1]],r=t.map.getView();(0,p.hs)(e,r.getResolution()),(0,p.e$)(e,r.getRotation()),r.adjustCenterInternal(e)}}else this.kinetic_&&this.kinetic_.begin();this.lastCentroid=n,this.lastPointersCount_=r.length,t.originalEvent.preventDefault()}handleUpEvent(t){const e=t.map,r=e.getView();if(0===this.targetPointers.length){if(!this.noKinetic_&&this.kinetic_&&this.kinetic_.end()){const t=this.kinetic_.getDistance(),n=this.kinetic_.getAngle(),i=r.getCenterInternal(),s=e.getPixelFromCoordinateInternal(i),o=e.getCoordinateFromPixelInternal([s[0]-t*Math.cos(n),s[1]-t*Math.sin(n)]);r.animateInternal({center:r.getConstrainedCenter(o),duration:500,easing:st.vT})}return this.panning_&&(this.panning_=!1,r.endInteraction()),!1}return this.kinetic_&&this.kinetic_.begin(),this.lastCentroid=null,!0}handleDownEvent(t){if(this.targetPointers.length>0&&this.condition_(t)){const e=t.map.getView();return this.lastCentroid=null,e.getAnimating()&&e.cancelAnimations(),this.kinetic_&&this.kinetic_.begin(),this.noKinetic_=this.targetPointers.length>1,!0}return!1}};var Tt=r(26392);const Ct=class extends mt{constructor(t){t=t||{},super({stopDown:l.W8}),this.condition_=t.condition?t.condition:yt,this.lastAngle_=void 0,this.duration_=void 0!==t.duration?t.duration:250}handleDragEvent(t){if(!St(t))return;const e=t.map,r=e.getView();if(r.getConstraints().rotation===Tt.b8)return;const n=e.getSize(),i=t.pixel,s=Math.atan2(n[1]/2-i[1],i[0]-n[0]/2);if(void 0!==this.lastAngle_){const t=s-this.lastAngle_;r.adjustRotationInternal(-t)}this.lastAngle_=s}handleUpEvent(t){return!St(t)||(t.map.getView().endInteraction(this.duration_),!1)}handleDownEvent(t){return!!St(t)&&(!(!bt(t)||!this.condition_(t))&&(t.map.getView().beginInteraction(),this.lastAngle_=void 0,!0))}};var Mt=r(68609);class Ot extends a.A{constructor(t){super(),this.geometry_=null,this.element_=document.createElement("div"),this.element_.style.position="absolute",this.element_.style.pointerEvents="auto",this.element_.className="ol-box "+t,this.map_=null,this.startPixel_=null,this.endPixel_=null}disposeInternal(){this.setMap(null)}render_(){const t=this.startPixel_,e=this.endPixel_,r="px",n=this.element_.style;n.left=Math.min(t[0],e[0])+r,n.top=Math.min(t[1],e[1])+r,n.width=Math.abs(e[0]-t[0])+r,n.height=Math.abs(e[1]-t[1])+r}setMap(t){if(this.map_){this.map_.getOverlayContainer().removeChild(this.element_);const t=this.element_.style;t.left="inherit",t.top="inherit",t.width="inherit",t.height="inherit"}this.map_=t,this.map_&&this.map_.getOverlayContainer().appendChild(this.element_)}setPixels(t,e){this.startPixel_=t,this.endPixel_=e,this.createOrUpdateGeometry(),this.render_()}createOrUpdateGeometry(){if(!this.map_)return;const t=this.startPixel_,e=this.endPixel_,r=[t,[t[0],e[1]],e,[e[0],t[1]]].map(this.map_.getCoordinateFromPixelInternal,this.map_);r[4]=r[0].slice(),this.geometry_?this.geometry_.setCoordinates([r]):this.geometry_=new Mt.Ay([r])}getGeometry(){return this.geometry_}}const Rt=Ot,Dt="boxcancel";class It extends C.Ay{constructor(t,e,r){super(t),this.coordinate=e,this.mapBrowserEvent=r}}const kt=class extends mt{constructor(t){super(),this.on,this.once,this.un,t=t??{},this.box_=new Rt(t.className||"ol-dragbox"),this.minArea_=t.minArea??64,t.onBoxEnd&&(this.onBoxEnd=t.onBoxEnd),this.startPixel_=null,this.condition_=t.condition??bt,this.boxEndCondition_=t.boxEndCondition??this.defaultBoxEndCondition}defaultBoxEndCondition(t,e,r){const n=r[0]-e[0],i=r[1]-e[1];return n*n+i*i>=this.minArea_}getGeometry(){return this.box_.getGeometry()}handleDragEvent(t){this.startPixel_&&(this.box_.setPixels(this.startPixel_,t.pixel),this.dispatchEvent(new It("boxdrag",t.coordinate,t)))}handleUpEvent(t){if(!this.startPixel_)return!1;const e=this.boxEndCondition_(t,this.startPixel_,t.pixel);return e&&this.onBoxEnd(t),this.dispatchEvent(new It(e?"boxend":Dt,t.coordinate,t)),this.box_.setMap(null),this.startPixel_=null,!1}handleDownEvent(t){return!!this.condition_(t)&&(this.startPixel_=t.pixel,this.box_.setMap(t.map),this.box_.setPixels(this.startPixel_,this.startPixel_),this.dispatchEvent(new It("boxstart",t.coordinate,t)),!0)}onBoxEnd(t){}setActive(t){t||(this.box_.setMap(null),this.startPixel_&&(this.dispatchEvent(new It(Dt,this.startPixel_,null)),this.startPixel_=null)),super.setActive(t)}setMap(t){this.getMap()&&(this.box_.setMap(null),this.startPixel_&&(this.dispatchEvent(new It(Dt,this.startPixel_,null)),this.startPixel_=null)),super.setMap(t)}},Lt=class extends kt{constructor(t){super({condition:(t=t||{}).condition?t.condition:xt,className:t.className||"ol-dragzoom",minArea:t.minArea}),this.duration_=void 0!==t.duration?t.duration:200,this.out_=void 0!==t.out&&t.out}onBoxEnd(t){const e=this.getMap().getView();let r=this.getGeometry();if(this.out_){const t=e.rotatedExtentForGeometry(r),n=e.getResolutionForExtentInternal(t),i=e.getResolution()/n;r=r.clone(),r.scale(i*i)}e.fitInternal(r,{duration:this.duration_,easing:st.vT})}},Ft="ArrowLeft",jt="ArrowRight",Nt="ArrowDown";class Gt extends ut.Ay{constructor(t){super(),t=t||{},this.defaultCondition_=function(t){return wt(t)&&Et(t)},this.condition_=void 0!==t.condition?t.condition:this.defaultCondition_,this.duration_=void 0!==t.duration?t.duration:100,this.pixelDelta_=void 0!==t.pixelDelta?t.pixelDelta:128}handleEvent(t){let e=!1;if(t.type==P.A.KEYDOWN){const r=t.originalEvent,n=r.key;if(this.condition_(t)&&(n==Nt||n==Ft||n==jt||"ArrowUp"==n)){const i=t.map.getView(),s=i.getResolution()*this.pixelDelta_;let o=0,a=0;n==Nt?a=-s:n==Ft?o=-s:n==jt?o=s:a=s;const l=[o,a];(0,p.e$)(l,i.getRotation()),(0,ut.e4)(i,l,this.duration_),r.preventDefault(),e=!0}}return!e}}const $t=Gt;class zt extends ut.Ay{constructor(t){super(),t=t||{},this.condition_=t.condition?t.condition:function(t){return!function(t){const e=t.originalEvent;return z.ew?e.metaKey:e.ctrlKey}(t)&&Et(t)},this.delta_=t.delta?t.delta:1,this.duration_=void 0!==t.duration?t.duration:100}handleEvent(t){let e=!1;if(t.type==P.A.KEYDOWN||t.type==P.A.KEYPRESS){const r=t.originalEvent,n=r.key;if(this.condition_(t)&&("+"===n||"-"===n)){const i=t.map,s="+"===n?this.delta_:-this.delta_,o=i.getView();(0,ut.D2)(o,s,void 0,this.duration_),r.preventDefault(),e=!0}}return!e}}const Ut=zt,Bt=class{constructor(t,e,r){this.decay_=t,this.minVelocity_=e,this.delay_=r,this.points_=[],this.angle_=0,this.initialVelocity_=0}begin(){this.points_.length=0,this.angle_=0,this.initialVelocity_=0}update(t,e){this.points_.push(t,e,Date.now())}end(){if(this.points_.length<6)return!1;const t=Date.now()-this.delay_,e=this.points_.length-3;if(this.points_[e+2]<t)return!1;let r=e-3;for(;r>0&&this.points_[r+2]>t;)r-=3;const n=this.points_[e+2]-this.points_[r+2];if(n<1e3/60)return!1;const i=this.points_[e]-this.points_[r],s=this.points_[e+1]-this.points_[r+1];return this.angle_=Math.atan2(s,i),this.initialVelocity_=Math.sqrt(i*i+s*s)/n,this.initialVelocity_>this.minVelocity_}getDistance(){return(this.minVelocity_-this.initialVelocity_)/this.decay_}getAngle(){return this.angle_}};var Vt=r(72475);class qt extends ut.Ay{constructor(t){super(t=t||{}),this.totalDelta_=0,this.lastDelta_=0,this.maxDelta_=void 0!==t.maxDelta?t.maxDelta:1,this.duration_=void 0!==t.duration?t.duration:250,this.timeout_=void 0!==t.timeout?t.timeout:80,this.useAnchor_=void 0===t.useAnchor||t.useAnchor,this.constrainResolution_=void 0!==t.constrainResolution&&t.constrainResolution;const e=t.condition?t.condition:_t;this.condition_=t.onFocusOnly?gt(vt,e):e,this.lastAnchor_=null,this.startTime_=void 0,this.timeoutId_,this.mode_=void 0,this.trackpadEventGap_=400,this.trackpadTimeoutId_,this.deltaPerZoom_=300}endInteraction_(){this.trackpadTimeoutId_=void 0;const t=this.getMap();t&&t.getView().endInteraction(void 0,this.lastDelta_?this.lastDelta_>0?1:-1:0,this.lastAnchor_?t.getCoordinateFromPixel(this.lastAnchor_):null)}handleEvent(t){if(!this.condition_(t))return!0;if(t.type!==P.A.WHEEL)return!0;const e=t.map,r=t.originalEvent;let n;if(r.preventDefault(),this.useAnchor_&&(this.lastAnchor_=t.pixel),t.type==P.A.WHEEL&&(n=r.deltaY,z._p&&r.deltaMode===WheelEvent.DOM_DELTA_PIXEL&&(n/=z.cr),r.deltaMode===WheelEvent.DOM_DELTA_LINE&&(n*=40)),0===n)return!1;this.lastDelta_=n;const i=Date.now();void 0===this.startTime_&&(this.startTime_=i),(!this.mode_||i-this.startTime_>this.trackpadEventGap_)&&(this.mode_=Math.abs(n)<4?"trackpad":"wheel");const s=e.getView();if("trackpad"===this.mode_&&!s.getConstrainResolution()&&!this.constrainResolution_)return this.trackpadTimeoutId_?clearTimeout(this.trackpadTimeoutId_):(s.getAnimating()&&s.cancelAnimations(),s.beginInteraction()),this.trackpadTimeoutId_=setTimeout(this.endInteraction_.bind(this),this.timeout_),s.adjustZoom(-n/this.deltaPerZoom_,this.lastAnchor_?e.getCoordinateFromPixel(this.lastAnchor_):null),this.startTime_=i,!1;this.totalDelta_+=n;const o=Math.max(this.timeout_-(i-this.startTime_),0);return clearTimeout(this.timeoutId_),this.timeoutId_=setTimeout(this.handleWheelZoom_.bind(this,e),o),!1}handleWheelZoom_(t){const e=t.getView();e.getAnimating()&&e.cancelAnimations();let r=-(0,Vt.qE)(this.totalDelta_,-this.maxDelta_*this.deltaPerZoom_,this.maxDelta_*this.deltaPerZoom_)/this.deltaPerZoom_;(e.getConstrainResolution()||this.constrainResolution_)&&(r=r?r>0?1:-1:0),(0,ut.D2)(e,r,this.lastAnchor_?t.getCoordinateFromPixel(this.lastAnchor_):null,this.duration_),this.mode_=void 0,this.totalDelta_=0,this.lastAnchor_=null,this.startTime_=void 0,this.timeoutId_=void 0}setMouseAnchor(t){this.useAnchor_=t,t||(this.lastAnchor_=null)}}const Kt=qt,Wt=class extends mt{constructor(t){const e=t=t||{};e.stopDown||(e.stopDown=l.W8),super(e),this.anchor_=null,this.lastAngle_=void 0,this.rotating_=!1,this.rotationDelta_=0,this.threshold_=void 0!==t.threshold?t.threshold:.3,this.duration_=void 0!==t.duration?t.duration:250}handleDragEvent(t){let e=0;const r=this.targetPointers[0],n=this.targetPointers[1],i=Math.atan2(n.clientY-r.clientY,n.clientX-r.clientX);if(void 0!==this.lastAngle_){const t=i-this.lastAngle_;this.rotationDelta_+=t,!this.rotating_&&Math.abs(this.rotationDelta_)>this.threshold_&&(this.rotating_=!0),e=t}this.lastAngle_=i;const s=t.map,o=s.getView();o.getConstraints().rotation!==Tt.b8&&(this.anchor_=s.getCoordinateFromPixelInternal(s.getEventPixel(pt(this.targetPointers))),this.rotating_&&(s.render(),o.adjustRotationInternal(e,this.anchor_)))}handleUpEvent(t){return!(this.targetPointers.length<2)||(t.map.getView().endInteraction(this.duration_),!1)}handleDownEvent(t){if(this.targetPointers.length>=2){const e=t.map;return this.anchor_=null,this.lastAngle_=void 0,this.rotating_=!1,this.rotationDelta_=0,this.handlingDownUpSequence||e.getView().beginInteraction(),!0}return!1}},Ht=class extends mt{constructor(t){const e=t=t||{};e.stopDown||(e.stopDown=l.W8),super(e),this.anchor_=null,this.duration_=void 0!==t.duration?t.duration:400,this.lastDistance_=void 0,this.lastScaleDelta_=1}handleDragEvent(t){let e=1;const r=this.targetPointers[0],n=this.targetPointers[1],i=r.clientX-n.clientX,s=r.clientY-n.clientY,o=Math.sqrt(i*i+s*s);void 0!==this.lastDistance_&&(e=this.lastDistance_/o),this.lastDistance_=o;const a=t.map,l=a.getView();1!=e&&(this.lastScaleDelta_=e),this.anchor_=a.getCoordinateFromPixelInternal(a.getEventPixel(pt(this.targetPointers))),a.render(),l.adjustResolutionInternal(e,this.anchor_)}handleUpEvent(t){if(this.targetPointers.length<2){const e=t.map.getView(),r=this.lastScaleDelta_>1?1:-1;return e.endInteraction(this.duration_,r),!1}return!0}handleDownEvent(t){if(this.targetPointers.length>=2){const e=t.map;return this.anchor_=null,this.lastDistance_=void 0,this.lastScaleDelta_=1,this.handlingDownUpSequence||e.getView().beginInteraction(),!0}return!1}};var Yt=r(12940),Xt=r(53908),Zt=r(96372);function Jt(t){t instanceof f.A?t.setMapInternal(null):t instanceof k&&t.getLayers().forEach(Jt)}function Qt(t,e){if(t instanceof f.A)t.setMapInternal(e);else if(t instanceof k){const r=t.getLayers().getArray();for(let t=0,n=r.length;t<n;++t)Qt(r[t],e)}}class te extends n.A{constructor(t){super(),t=t||{},this.on,this.once,this.un;const e=function(t){let e=null;void 0!==t.keyboardEventTarget&&(e="string"==typeof t.keyboardEventTarget?document.getElementById(t.keyboardEventTarget):t.keyboardEventTarget);const r={},n=t.layers&&"function"==typeof t.layers.getLayers?t.layers:new k({layers:t.layers});let s,o,a;return r[q]=n,r[W]=t.target,r[H]=t.view instanceof Q.Ay?t.view:new Q.Ay,void 0!==t.controls&&(Array.isArray(t.controls)?s=new i.A(t.controls.slice()):((0,M.v)("function"==typeof t.controls.getArray,"Expected `controls` to be an array or an `ol/Collection.js`"),s=t.controls)),void 0!==t.interactions&&(Array.isArray(t.interactions)?o=new i.A(t.interactions.slice()):((0,M.v)("function"==typeof t.interactions.getArray,"Expected `interactions` to be an array or an `ol/Collection.js`"),o=t.interactions)),void 0!==t.overlays?Array.isArray(t.overlays)?a=new i.A(t.overlays.slice()):((0,M.v)("function"==typeof t.overlays.getArray,"Expected `overlays` to be an array or an `ol/Collection.js`"),a=t.overlays):a=new i.A,{controls:s,interactions:o,keyboardEventTarget:e,overlays:a,values:r}}(t);this.renderComplete_=!1,this.loaded_=!0,this.boundHandleBrowserEvent_=this.handleBrowserEvent.bind(this),this.maxTilesLoading_=void 0!==t.maxTilesLoading?t.maxTilesLoading:16,this.pixelRatio_=void 0!==t.pixelRatio?t.pixelRatio:z.cr,this.postRenderTimeoutHandle_,this.animationDelayKey_,this.animationDelay_=this.animationDelay_.bind(this),this.coordinateToPixelTransform_=(0,u.vt)(),this.pixelToCoordinateTransform_=(0,u.vt)(),this.frameIndex_=0,this.frameState_=null,this.previousExtent_=null,this.viewPropertyListenerKey_=null,this.viewChangeListenerKey_=null,this.layerGroupPropertyListenerKeys_=null,this.viewport_=document.createElement("div"),this.viewport_.className="ol-viewport"+("ontouchstart"in window?" ol-touch":""),this.viewport_.style.position="relative",this.viewport_.style.overflow="hidden",this.viewport_.style.width="100%",this.viewport_.style.height="100%",this.overlayContainer_=document.createElement("div"),this.overlayContainer_.style.position="absolute",this.overlayContainer_.style.zIndex="0",this.overlayContainer_.style.width="100%",this.overlayContainer_.style.height="100%",this.overlayContainer_.style.pointerEvents="none",this.overlayContainer_.className="ol-overlaycontainer",this.viewport_.appendChild(this.overlayContainer_),this.overlayContainerStopEvent_=document.createElement("div"),this.overlayContainerStopEvent_.style.position="absolute",this.overlayContainerStopEvent_.style.zIndex="0",this.overlayContainerStopEvent_.style.width="100%",this.overlayContainerStopEvent_.style.height="100%",this.overlayContainerStopEvent_.style.pointerEvents="none",this.overlayContainerStopEvent_.className="ol-overlaycontainer-stopevent",this.viewport_.appendChild(this.overlayContainerStopEvent_),this.mapBrowserEventHandler_=null,this.moveTolerance_=t.moveTolerance,this.keyboardEventTarget_=e.keyboardEventTarget,this.targetChangeHandlerKeys_=null,this.targetElement_=null,this.resizeObserver_=new ResizeObserver((()=>this.updateSize())),this.controls=e.controls||function(t){t=t||{};const e=new i.A;return(void 0===t.zoom||t.zoom)&&e.push(new ct(t.zoomOptions)),(void 0===t.rotate||t.rotate)&&e.push(new at(t.rotateOptions)),(void 0===t.attribution||t.attribution)&&e.push(new it(t.attributionOptions)),e}(),this.interactions=e.interactions||function(t){t=t||{};const e=new i.A,r=new Bt(-.005,.05,100);return(void 0===t.altShiftDragRotate||t.altShiftDragRotate)&&e.push(new Ct),(void 0===t.doubleClickZoom||t.doubleClickZoom)&&e.push(new dt({delta:t.zoomDelta,duration:t.zoomDuration})),(void 0===t.dragPan||t.dragPan)&&e.push(new Pt({onFocusOnly:t.onFocusOnly,kinetic:r})),(void 0===t.pinchRotate||t.pinchRotate)&&e.push(new Wt),(void 0===t.pinchZoom||t.pinchZoom)&&e.push(new Ht({duration:t.zoomDuration})),(void 0===t.keyboard||t.keyboard)&&(e.push(new $t),e.push(new Ut({delta:t.zoomDelta,duration:t.zoomDuration}))),(void 0===t.mouseWheelZoom||t.mouseWheelZoom)&&e.push(new Kt({onFocusOnly:t.onFocusOnly,duration:t.zoomDuration})),(void 0===t.shiftDragZoom||t.shiftDragZoom)&&e.push(new Lt({duration:t.zoomDuration})),e}({onFocusOnly:!0}),this.overlays_=e.overlays,this.overlayIdIndex_={},this.renderer_=null,this.postRenderFunctions_=[],this.tileQueue_=new J(this.getTilePriority.bind(this),this.handleTileChange_.bind(this)),this.addChangeListener(q,this.handleLayerGroupChanged_),this.addChangeListener(H,this.handleViewChanged_),this.addChangeListener(K,this.handleSizeChanged_),this.addChangeListener(W,this.handleTargetChanged_),this.setProperties(e.values);const r=this;!t.view||t.view instanceof Q.Ay||t.view.then((function(t){r.setView(new Q.Ay(t))})),this.controls.addEventListener(s.A.ADD,(t=>{t.element.setMap(this)})),this.controls.addEventListener(s.A.REMOVE,(t=>{t.element.setMap(null)})),this.interactions.addEventListener(s.A.ADD,(t=>{t.element.setMap(this)})),this.interactions.addEventListener(s.A.REMOVE,(t=>{t.element.setMap(null)})),this.overlays_.addEventListener(s.A.ADD,(t=>{this.addOverlayInternal_(t.element)})),this.overlays_.addEventListener(s.A.REMOVE,(t=>{const e=t.element.getId();void 0!==e&&delete this.overlayIdIndex_[e.toString()],t.element.setMap(null)})),this.controls.forEach((t=>{t.setMap(this)})),this.interactions.forEach((t=>{t.setMap(this)})),this.overlays_.forEach(this.addOverlayInternal_.bind(this))}addControl(t){this.getControls().push(t)}addInteraction(t){this.getInteractions().push(t)}addLayer(t){this.getLayerGroup().getLayers().push(t)}handleLayerAdd_(t){Qt(t.layer,this)}addOverlay(t){this.getOverlays().push(t)}addOverlayInternal_(t){const e=t.getId();void 0!==e&&(this.overlayIdIndex_[e.toString()]=t),t.setMap(this)}disposeInternal(){this.controls.clear(),this.interactions.clear(),this.overlays_.clear(),this.resizeObserver_.disconnect(),this.setTarget(null),super.disposeInternal()}forEachFeatureAtPixel(t,e,r){if(!this.frameState_||!this.renderer_)return;const n=this.getCoordinateFromPixelInternal(t),i=void 0!==(r=void 0!==r?r:{}).hitTolerance?r.hitTolerance:0,s=void 0!==r.layerFilter?r.layerFilter:l.rT,o=!1!==r.checkWrapped;return this.renderer_.forEachFeatureAtCoordinate(n,this.frameState_,i,o,e,null,s,null)}getFeaturesAtPixel(t,e){const r=[];return this.forEachFeatureAtPixel(t,(function(t){r.push(t)}),e),r}getAllLayers(){const t=[];return function e(r){r.forEach((function(r){r instanceof k?e(r.getLayers()):t.push(r)}))}(this.getLayers()),t}hasFeatureAtPixel(t,e){if(!this.frameState_||!this.renderer_)return!1;const r=this.getCoordinateFromPixelInternal(t),n=void 0!==(e=void 0!==e?e:{}).layerFilter?e.layerFilter:l.rT,i=void 0!==e.hitTolerance?e.hitTolerance:0,s=!1!==e.checkWrapped;return this.renderer_.hasFeatureAtCoordinate(r,this.frameState_,i,s,n,null)}getEventCoordinate(t){return this.getCoordinateFromPixel(this.getEventPixel(t))}getEventCoordinateInternal(t){return this.getCoordinateFromPixelInternal(this.getEventPixel(t))}getEventPixel(t){const e=this.viewport_.getBoundingClientRect(),r=this.getSize(),n=e.width/r[0],i=e.height/r[1],s="changedTouches"in t?t.changedTouches[0]:t;return[(s.clientX-e.left)/n,(s.clientY-e.top)/i]}getTarget(){return this.get(W)}getTargetElement(){return this.targetElement_}getCoordinateFromPixel(t){return(0,Yt.te)(this.getCoordinateFromPixelInternal(t),this.getView().getProjection())}getCoordinateFromPixelInternal(t){const e=this.frameState_;return e?(0,u.Bb)(e.pixelToCoordinateTransform,t.slice()):null}getControls(){return this.controls}getOverlays(){return this.overlays_}getOverlayById(t){const e=this.overlayIdIndex_[t.toString()];return void 0!==e?e:null}getInteractions(){return this.interactions}getLayerGroup(){return this.get(q)}setLayers(t){const e=this.getLayerGroup();if(t instanceof i.A)return void e.setLayers(t);const r=e.getLayers();r.clear(),r.extend(t)}getLayers(){return this.getLayerGroup().getLayers()}getLoadingOrNotReady(){const t=this.getLayerGroup().getLayerStatesArray();for(let e=0,r=t.length;e<r;++e){const r=t[e];if(!r.visible)continue;const n=r.layer.getRenderer();if(n&&!n.ready)return!0;const i=r.layer.getSource();if(i&&i.loading)return!0}return!1}getPixelFromCoordinate(t){const e=(0,Yt.Ad)(t,this.getView().getProjection());return this.getPixelFromCoordinateInternal(e)}getPixelFromCoordinateInternal(t){const e=this.frameState_;return e?(0,u.Bb)(e.coordinateToPixelTransform,t.slice(0,2)):null}getRenderer(){return this.renderer_}getSize(){return this.get(K)}getView(){return this.get(H)}getViewport(){return this.viewport_}getOverlayContainer(){return this.overlayContainer_}getOverlayContainerStopEvent(){return this.overlayContainerStopEvent_}getOwnerDocument(){const t=this.getTargetElement();return t?t.ownerDocument:document}getTilePriority(t,e,r,n){return function(t,e,r,n,i){if(!t||!(r in t.wantedTiles))return Y;if(!t.wantedTiles[r][e.getKey()])return Y;const s=t.viewState.center,o=n[0]-s[0],a=n[1]-s[1];return 65536*Math.log(i)+Math.sqrt(o*o+a*a)/i}(this.frameState_,t,e,r,n)}handleBrowserEvent(t,e){e=e||t.type;const r=new j(e,this,t);this.handleMapBrowserEvent(r)}handleMapBrowserEvent(t){if(!this.frameState_)return;const e=t.originalEvent,r=e.type;if(r===G||r===P.A.WHEEL||r===P.A.KEYDOWN){const t=this.getOwnerDocument(),r=this.viewport_.getRootNode?this.viewport_.getRootNode():t,n=e.target,i=r instanceof ShadowRoot?r.host===n?r.host.ownerDocument:r:r===t?t.documentElement:r;if(this.overlayContainerStopEvent_.contains(n)||!i.contains(n))return}if(t.frameState=this.frameState_,!1!==this.dispatchEvent(t)){const e=this.getInteractions().getArray().slice();for(let r=e.length-1;r>=0;r--){const n=e[r];if(n.getMap()===this&&n.getActive()&&this.getTargetElement()&&(!n.handleEvent(t)||t.propagationStopped))break}}}handlePostRender(){const t=this.frameState_,e=this.tileQueue_;if(!e.isEmpty()){let r=this.maxTilesLoading_,n=r;if(t){const e=t.viewHints;if(e[tt.A.ANIMATING]||e[tt.A.INTERACTING]){const e=Date.now()-t.time>8;r=e?0:8,n=e?0:2}}e.getTilesLoading()<r&&(e.reprioritize(),e.loadMoreTiles(r,n))}t&&this.renderer_&&!t.animate&&(this.renderComplete_?(this.hasListener(b.A.RENDERCOMPLETE)&&this.renderer_.dispatchRenderEvent(b.A.RENDERCOMPLETE,t),!1===this.loaded_&&(this.loaded_=!0,this.dispatchEvent(new F(V.A.LOADEND,this,t)))):!0===this.loaded_&&(this.loaded_=!1,this.dispatchEvent(new F(V.A.LOADSTART,this,t))));const r=this.postRenderFunctions_;for(let e=0,n=r.length;e<n;++e)r[e](this,t);r.length=0}handleSizeChanged_(){this.getView()&&!this.getView().getAnimating()&&this.getView().resolveConstraints(0),this.render()}handleTargetChanged_(){if(this.mapBrowserEventHandler_){for(let t=0,e=this.targetChangeHandlerKeys_.length;t<e;++t)(0,E.JH)(this.targetChangeHandlerKeys_[t]);this.targetChangeHandlerKeys_=null,this.viewport_.removeEventListener(P.A.CONTEXTMENU,this.boundHandleBrowserEvent_),this.viewport_.removeEventListener(P.A.WHEEL,this.boundHandleBrowserEvent_),this.mapBrowserEventHandler_.dispose(),this.mapBrowserEventHandler_=null,this.viewport_.remove()}if(this.targetElement_){this.resizeObserver_.unobserve(this.targetElement_);const t=this.targetElement_.getRootNode();t instanceof ShadowRoot&&this.resizeObserver_.unobserve(t.host),this.setSize(void 0)}const t=this.getTarget(),e="string"==typeof t?document.getElementById(t):t;if(this.targetElement_=e,e){e.appendChild(this.viewport_),this.renderer_||(this.renderer_=new A(this)),this.mapBrowserEventHandler_=new B(this,this.moveTolerance_);for(const t in N)this.mapBrowserEventHandler_.addEventListener(N[t],this.handleMapBrowserEvent.bind(this));let t;if(this.viewport_.addEventListener(P.A.CONTEXTMENU,this.boundHandleBrowserEvent_,!1),this.viewport_.addEventListener(P.A.WHEEL,this.boundHandleBrowserEvent_,!!z.FT&&{passive:!1}),this.keyboardEventTarget_)t=this.keyboardEventTarget_;else{const r=e.getRootNode();t=r instanceof ShadowRoot?r.host:e}this.targetChangeHandlerKeys_=[(0,E.KT)(t,P.A.KEYDOWN,this.handleBrowserEvent,this),(0,E.KT)(t,P.A.KEYPRESS,this.handleBrowserEvent,this)];const r=e.getRootNode();r instanceof ShadowRoot&&this.resizeObserver_.observe(r.host),this.resizeObserver_.observe(e)}else this.renderer_&&(clearTimeout(this.postRenderTimeoutHandle_),this.postRenderTimeoutHandle_=void 0,this.postRenderFunctions_.length=0,this.renderer_.dispose(),this.renderer_=null),this.animationDelayKey_&&(cancelAnimationFrame(this.animationDelayKey_),this.animationDelayKey_=void 0);this.updateSize()}handleTileChange_(){this.render()}handleViewPropertyChanged_(){this.render()}handleViewChanged_(){this.viewPropertyListenerKey_&&((0,E.JH)(this.viewPropertyListenerKey_),this.viewPropertyListenerKey_=null),this.viewChangeListenerKey_&&((0,E.JH)(this.viewChangeListenerKey_),this.viewChangeListenerKey_=null);const t=this.getView();t&&(this.updateViewportSize_(this.getSize()),this.viewPropertyListenerKey_=(0,E.KT)(t,v.A.PROPERTYCHANGE,this.handleViewPropertyChanged_,this),this.viewChangeListenerKey_=(0,E.KT)(t,P.A.CHANGE,this.handleViewPropertyChanged_,this),t.resolveConstraints(0)),this.render()}handleLayerGroupChanged_(){this.layerGroupPropertyListenerKeys_&&(this.layerGroupPropertyListenerKeys_.forEach(E.JH),this.layerGroupPropertyListenerKeys_=null);const t=this.getLayerGroup();t&&(this.handleLayerAdd_(new R("addlayer",t)),this.layerGroupPropertyListenerKeys_=[(0,E.KT)(t,v.A.PROPERTYCHANGE,this.render,this),(0,E.KT)(t,P.A.CHANGE,this.render,this),(0,E.KT)(t,"addlayer",this.handleLayerAdd_,this),(0,E.KT)(t,"removelayer",this.handleLayerRemove_,this)]),this.render()}isRendered(){return!!this.frameState_}animationDelay_(){this.animationDelayKey_=void 0,this.renderFrame_(Date.now())}renderSync(){this.animationDelayKey_&&cancelAnimationFrame(this.animationDelayKey_),this.animationDelay_()}redrawText(){const t=this.getLayerGroup().getLayerStatesArray();for(let e=0,r=t.length;e<r;++e){const r=t[e].layer;r.hasRenderer()&&r.getRenderer().handleFontsChanged()}}render(){this.renderer_&&void 0===this.animationDelayKey_&&(this.animationDelayKey_=requestAnimationFrame(this.animationDelay_))}removeControl(t){return this.getControls().remove(t)}removeInteraction(t){return this.getInteractions().remove(t)}removeLayer(t){return this.getLayerGroup().getLayers().remove(t)}handleLayerRemove_(t){Jt(t.layer)}removeOverlay(t){return this.getOverlays().remove(t)}renderFrame_(t){const e=this.getSize(),r=this.getView(),n=this.frameState_;let i=null;if(void 0!==e&&(0,Xt.Ie)(e)&&r&&r.isDef()){const n=r.getHints(this.frameState_?this.frameState_.viewHints:void 0),s=r.getState();if(i={animate:!1,coordinateToPixelTransform:this.coordinateToPixelTransform_,declutter:null,extent:(0,h.Bg)(s.center,s.resolution,s.rotation,e),index:this.frameIndex_++,layerIndex:0,layerStatesArray:this.getLayerGroup().getLayerStatesArray(),pixelRatio:this.pixelRatio_,pixelToCoordinateTransform:this.pixelToCoordinateTransform_,postRenderFunctions:[],size:e,tileQueue:this.tileQueue_,time:t,usedTiles:{},viewState:s,viewHints:n,wantedTiles:{},mapId:(0,c.v6)(this),renderTargets:{}},s.nextCenter&&s.nextResolution){const t=isNaN(s.nextRotation)?s.rotation:s.nextRotation;i.nextExtent=(0,h.Bg)(s.nextCenter,s.nextResolution,t,e)}}this.frameState_=i,this.renderer_.renderFrame(i),i&&(i.animate&&this.render(),Array.prototype.push.apply(this.postRenderFunctions_,i.postRenderFunctions),n&&(!this.previousExtent_||!(0,h.Im)(this.previousExtent_)&&!(0,h.aI)(i.extent,this.previousExtent_))&&(this.dispatchEvent(new F(V.A.MOVESTART,this,n)),this.previousExtent_=(0,h.aZ)(this.previousExtent_)),this.previousExtent_&&!i.viewHints[tt.A.ANIMATING]&&!i.viewHints[tt.A.INTERACTING]&&!(0,h.aI)(i.extent,this.previousExtent_)&&(this.dispatchEvent(new F(V.A.MOVEEND,this,i)),(0,h.o8)(i.extent,this.previousExtent_))),this.dispatchEvent(new F(V.A.POSTRENDER,this,i)),this.renderComplete_=(this.hasListener(V.A.LOADSTART)||this.hasListener(V.A.LOADEND)||this.hasListener(b.A.RENDERCOMPLETE))&&!this.tileQueue_.getTilesLoading()&&!this.tileQueue_.getCount()&&!this.getLoadingOrNotReady(),this.postRenderTimeoutHandle_||(this.postRenderTimeoutHandle_=setTimeout((()=>{this.postRenderTimeoutHandle_=void 0,this.handlePostRender()}),0))}setLayerGroup(t){const e=this.getLayerGroup();e&&this.handleLayerRemove_(new R("removelayer",e)),this.set(q,t)}setSize(t){this.set(K,t)}setTarget(t){this.set(W,t)}setView(t){if(!t||t instanceof Q.Ay)return void this.set(H,t);this.set(H,new Q.Ay);const e=this;t.then((function(t){e.setView(new Q.Ay(t))}))}updateSize(){const t=this.getTargetElement();let e;if(t){const r=getComputedStyle(t),n=t.offsetWidth-parseFloat(r.borderLeftWidth)-parseFloat(r.paddingLeft)-parseFloat(r.paddingRight)-parseFloat(r.borderRightWidth),i=t.offsetHeight-parseFloat(r.borderTopWidth)-parseFloat(r.paddingTop)-parseFloat(r.paddingBottom)-parseFloat(r.borderBottomWidth);isNaN(n)||isNaN(i)||(e=[Math.max(0,n),Math.max(0,i)],!(0,Xt.Ie)(e)&&(t.offsetWidth||t.offsetHeight||t.getClientRects().length)&&(0,Zt.R8)("No map visible because the map container's width or height are 0."))}const r=this.getSize();!e||r&&(0,rt.aI)(e,r)||(this.setSize(e),this.updateViewportSize_(e))}updateViewportSize_(t){const e=this.getView();e&&e.setViewportSize(t)}}const ee=te},63479:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={POSTRENDER:"postrender",MOVESTART:"movestart",MOVEEND:"moveend",LOADSTART:"loadstart",LOADEND:"loadend"}},72614:(t,e,r)=>{"use strict";r.d(e,{A:()=>u});var n=r(37283),i=r(56644),s=r(80548),o=r(98629),a=r(82048);class l extends n.Ay{constructor(t,e,r){super(t),this.key=e,this.oldValue=r}}class c extends s.A{constructor(t){super(),this.on,this.once,this.un,(0,o.v6)(this),this.values_=null,void 0!==t&&this.setProperties(t)}get(t){let e;return this.values_&&this.values_.hasOwnProperty(t)&&(e=this.values_[t]),e}getKeys(){return this.values_&&Object.keys(this.values_)||[]}getProperties(){return this.values_&&Object.assign({},this.values_)||{}}getPropertiesInternal(){return this.values_}hasProperties(){return!!this.values_}notify(t,e){let r;r=`change:${t}`,this.hasListener(r)&&this.dispatchEvent(new l(r,t,e)),r=i.A.PROPERTYCHANGE,this.hasListener(r)&&this.dispatchEvent(new l(r,t,e))}addChangeListener(t,e){this.addEventListener(`change:${t}`,e)}removeChangeListener(t,e){this.removeEventListener(`change:${t}`,e)}set(t,e,r){const n=this.values_||(this.values_={});if(r)n[t]=e;else{const r=n[t];n[t]=e,r!==e&&this.notify(t,r)}}setProperties(t,e){for(const r in t)this.set(r,t[r],e)}applyProperties(t){t.values_&&Object.assign(this.values_||(this.values_={}),t.values_)}unset(t,e){if(this.values_&&t in this.values_){const r=this.values_[t];delete this.values_[t],(0,a.p)(this.values_)&&(this.values_=null),e||this.notify(t,r)}}}const u=c},56644:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={PROPERTYCHANGE:"propertychange"}},80548:(t,e,r)=>{"use strict";r.d(e,{A:()=>a});var n=r(91086),i=r(24187),s=r(94456);class o extends n.A{constructor(){super(),this.on=this.onInternal,this.once=this.onceInternal,this.un=this.unInternal,this.revision_=0}changed(){++this.revision_,this.dispatchEvent(i.A.CHANGE)}getRevision(){return this.revision_}onInternal(t,e){if(Array.isArray(t)){const r=t.length,n=new Array(r);for(let i=0;i<r;++i)n[i]=(0,s.KT)(this,t[i],e);return n}return(0,s.KT)(this,t,e)}onceInternal(t,e){let r;if(Array.isArray(t)){const n=t.length;r=new Array(n);for(let i=0;i<n;++i)r[i]=(0,s.Jz)(this,t[i],e)}else r=(0,s.Jz)(this,t,e);return e.ol_key=r,r}unInternal(t,e){const r=e.ol_key;if(r)!function(t){if(Array.isArray(t))for(let e=0,r=t.length;e<r;++e)(0,s.JH)(t[e]);else(0,s.JH)(t)}(r);else if(Array.isArray(t))for(let r=0,n=t.length;r<n;++r)this.removeEventListener(t[r],e);else this.removeEventListener(t,e)}}o.prototype.on,o.prototype.once,o.prototype.un;const a=o},76741:(t,e,r)=>{"use strict";r.d(e,{A:()=>c});var n=r(91086),i=r(24187),s=r(20884),o=r(98629),a=r(2620);class l extends n.A{constructor(t,e,r){super(),r=r||{},this.tileCoord=t,this.state=e,this.key="",this.transition_=void 0===r.transition?250:r.transition,this.transitionStarts_={},this.interpolate=!!r.interpolate}changed(){this.dispatchEvent(i.A.CHANGE)}release(){this.state===s.A.ERROR&&this.setState(s.A.EMPTY)}getKey(){return this.key+"/"+this.tileCoord}getTileCoord(){return this.tileCoord}getState(){return this.state}setState(t){if(this.state!==s.A.ERROR&&this.state>t)throw new Error("Tile load sequence violation");this.state=t,this.changed()}load(){(0,o.b0)()}getAlpha(t,e){if(!this.transition_)return 1;let r=this.transitionStarts_[t];if(r){if(-1===r)return 1}else r=e,this.transitionStarts_[t]=r;const n=e-r+1e3/60;return n>=this.transition_?1:(0,a.a6)(n/this.transition_)}inTransition(t){return!!this.transition_&&-1!==this.transitionStarts_[t]}endTransition(t){this.transition_&&(this.transitionStarts_[t]=-1)}disposeInternal(){this.release(),super.disposeInternal()}}const c=l},64444:(t,e,r)=>{"use strict";r.d(e,{A:()=>s,N:()=>i});class n{constructor(t,e,r,n){this.minX=t,this.maxX=e,this.minY=r,this.maxY=n}contains(t){return this.containsXY(t[1],t[2])}containsTileRange(t){return this.minX<=t.minX&&t.maxX<=this.maxX&&this.minY<=t.minY&&t.maxY<=this.maxY}containsXY(t,e){return this.minX<=t&&t<=this.maxX&&this.minY<=e&&e<=this.maxY}equals(t){return this.minX==t.minX&&this.minY==t.minY&&this.maxX==t.maxX&&this.maxY==t.maxY}extend(t){t.minX<this.minX&&(this.minX=t.minX),t.maxX>this.maxX&&(this.maxX=t.maxX),t.minY<this.minY&&(this.minY=t.minY),t.maxY>this.maxY&&(this.maxY=t.maxY)}getHeight(){return this.maxY-this.minY+1}getSize(){return[this.getWidth(),this.getHeight()]}getWidth(){return this.maxX-this.minX+1}intersects(t){return this.minX<=t.maxX&&this.maxX>=t.minX&&this.minY<=t.maxY&&this.maxY>=t.minY}}function i(t,e,r,i,s){return void 0!==s?(s.minX=t,s.maxX=e,s.minY=r,s.maxY=i,s):new n(t,e,r,i)}const s=n},20884:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={IDLE:0,LOADING:1,LOADED:2,ERROR:3,EMPTY:4}},95854:(t,e,r)=>{"use strict";r.d(e,{Ay:()=>P});var n=r(72614),i=r(32769);const s={CENTER:"center",RESOLUTION:"resolution",ROTATION:"rotation"};var o=r(75961),a=r(12940),l=r(97440),c=r(9535),u=r(30878),h=r(72475);function d(t,e,r){return function(n,i,s,o,a){if(!n)return;if(!i&&!e)return n;const l=e?0:s[0]*i,c=e?0:s[1]*i,u=a?a[0]:0,d=a?a[1]:0;let f=t[0]+l/2+u,p=t[2]-l/2+u,m=t[1]+c/2+d,g=t[3]-c/2+d;f>p&&(f=(p+f)/2,p=f),m>g&&(m=(g+m)/2,g=m);let y=(0,h.qE)(n[0],f,p),v=(0,h.qE)(n[1],m,g);if(o&&r&&i){const t=30*i;y+=-t*Math.log(1+Math.max(0,f-n[0])/t)+t*Math.log(1+Math.max(0,n[0]-p)/t),v+=-t*Math.log(1+Math.max(0,m-n[1])/t)+t*Math.log(1+Math.max(0,n[1]-g)/t)}return[y,v]}}function f(t){return t}var p=r(44509),m=r(30444);function g(t,e,r,n){const i=(0,p.RG)(e)/r[0],s=(0,p.Oq)(e)/r[1];return n?Math.min(t,Math.max(i,s)):Math.min(t,Math.min(i,s))}function y(t,e,r){let n=Math.min(t,e);return n*=Math.log(1+50*Math.max(0,t/e-1))/50+1,r&&(n=Math.max(n,r),n/=Math.log(1+50*Math.max(0,r/t-1))/50+1),(0,h.qE)(n,r/2,2*e)}function v(t,e,r,n,i){return r=void 0===r||r,function(s,o,a,l){if(void 0!==s){const o=n?g(t,n,a,i):t;return r&&l?y(s,o,e):(0,h.qE)(s,e,o)}}}var _=r(26392),b=r(2620),w=r(68609);class x extends n.A{constructor(t){super(),this.on,this.once,this.un,t=Object.assign({},t),this.hints_=[0,0],this.animations_=[],this.updateAnimationKey_,this.projection_=(0,a.Av)(t.projection,"EPSG:3857"),this.viewportSize_=[100,100],this.targetCenter_=null,this.targetResolution_,this.targetRotation_,this.nextCenter_=null,this.nextResolution_,this.nextRotation_,this.cancelAnchor_=void 0,t.projection&&(0,a.RJ)(),t.center&&(t.center=(0,a.Ad)(t.center,this.projection_)),t.extent&&(t.extent=(0,a.SD)(t.extent,this.projection_)),this.applyOptions_(t)}applyOptions_(t){const e=Object.assign({},t);for(const t in s)delete e[t];this.setProperties(e,!0);const r=function(t){let e,r,n;let i=void 0!==t.minZoom?t.minZoom:0,s=void 0!==t.maxZoom?t.maxZoom:28;const l=void 0!==t.zoomFactor?t.zoomFactor:2,c=void 0!==t.multiWorld&&t.multiWorld,u=void 0===t.smoothResolutionConstraint||t.smoothResolutionConstraint,d=void 0!==t.showFullExtent&&t.showFullExtent,f=(0,a.Av)(t.projection,"EPSG:3857"),_=f.getExtent();let b=t.constrainOnlyCenter,w=t.extent;if(c||w||!f.isGlobal()||(b=!1,w=_),void 0!==t.resolutions){const o=t.resolutions;r=o[i],n=void 0!==o[s]?o[s]:o[o.length-1],e=t.constrainResolution?function(t,e,r,n){return e=void 0===e||e,function(i,s,o,a){if(void 0!==i){const l=t[0],c=t[t.length-1],u=r?g(l,r,o,n):l;if(a)return e?y(i,u,c):(0,h.qE)(i,c,u);const d=Math.min(u,i),f=Math.floor((0,m.FT)(t,d,s));return t[f]>u&&f<t.length-1?t[f+1]:t[f]}}}(o,u,!b&&w,d):v(r,n,u,!b&&w,d)}else{const c=(_?Math.max((0,p.RG)(_),(0,p.Oq)(_)):360*a.Ig.degrees/f.getMetersPerUnit())/o.R/Math.pow(2,0),m=c/Math.pow(2,28);r=t.maxResolution,void 0!==r?i=0:r=c/Math.pow(l,i),n=t.minResolution,void 0===n&&(n=void 0!==t.maxZoom?void 0!==t.maxResolution?r/Math.pow(l,s):c/Math.pow(l,s):m),s=i+Math.floor(Math.log(r/n)/Math.log(l)),n=r/Math.pow(l,s-i),e=t.constrainResolution?function(t,e,r,n,i,s){return n=void 0===n||n,r=void 0!==r?r:0,function(o,a,l,c){if(void 0!==o){const u=i?g(e,i,l,s):e;if(c)return n?y(o,u,r):(0,h.qE)(o,r,u);const d=1e-9,f=Math.ceil(Math.log(e/u)/Math.log(t)-d),p=-a*(.5-d)+.5,m=Math.min(u,o),v=Math.floor(Math.log(e/m)/Math.log(t)+p),_=Math.max(f,v),b=e/Math.pow(t,_);return(0,h.qE)(b,r,u)}}}(l,r,n,u,!b&&w,d):v(r,n,u,!b&&w,d)}return{constraint:e,maxResolution:r,minResolution:n,minZoom:i,zoomFactor:l}}(t);this.maxResolution_=r.maxResolution,this.minResolution_=r.minResolution,this.zoomFactor_=r.zoomFactor,this.resolutions_=t.resolutions,this.padding_=t.padding,this.minZoom_=r.minZoom;const n=function(t){if(void 0!==t.extent){const e=void 0===t.smoothExtentConstraint||t.smoothExtentConstraint;return d(t.extent,t.constrainOnlyCenter,e)}const e=(0,a.Av)(t.projection,"EPSG:3857");if(!0!==t.multiWorld&&e.isGlobal()){const t=e.getExtent().slice();return t[0]=-1/0,t[2]=1/0,d(t,!1,!1)}return f}(t),i=r.constraint,l=function(t){if(void 0===t.enableRotation||t.enableRotation){const e=t.constrainRotation;return void 0===e||!0===e?(0,_.cq)():!1===e?_.dv:"number"==typeof e?(0,_.a$)(e):_.dv}return _.b8}(t);this.constraints_={center:n,resolution:i,rotation:l},this.setRotation(void 0!==t.rotation?t.rotation:0),this.setCenterInternal(void 0!==t.center?t.center:null),void 0!==t.resolution?this.setResolution(t.resolution):void 0!==t.zoom&&this.setZoom(t.zoom)}get padding(){return this.padding_}set padding(t){let e=this.padding_;this.padding_=t;const r=this.getCenterInternal();if(r){const n=t||[0,0,0,0];e=e||[0,0,0,0];const i=this.getResolution(),s=i/2*(n[3]-e[3]+e[1]-n[1]),o=i/2*(n[0]-e[0]+e[2]-n[2]);this.setCenterInternal([r[0]+s,r[1]-o])}}getUpdatedOptions_(t){const e=this.getProperties();return void 0!==e.resolution?e.resolution=this.getResolution():e.zoom=this.getZoom(),e.center=this.getCenterInternal(),e.rotation=this.getRotation(),Object.assign({},e,t)}animate(t){this.isDef()&&!this.getAnimating()&&this.resolveConstraints(0);const e=new Array(arguments.length);for(let t=0;t<e.length;++t){let r=arguments[t];r.center&&(r=Object.assign({},r),r.center=(0,a.Ad)(r.center,this.getProjection())),r.anchor&&(r=Object.assign({},r),r.anchor=(0,a.Ad)(r.anchor,this.getProjection())),e[t]=r}this.animateInternal.apply(this,e)}animateInternal(t){let e,r=arguments.length;r>1&&"function"==typeof arguments[r-1]&&(e=arguments[r-1],--r);let n=0;for(;n<r&&!this.isDef();++n){const t=arguments[n];t.center&&this.setCenterInternal(t.center),void 0!==t.zoom?this.setZoom(t.zoom):t.resolution&&this.setResolution(t.resolution),void 0!==t.rotation&&this.setRotation(t.rotation)}if(n===r)return void(e&&E(e,!0));let s=Date.now(),o=this.targetCenter_.slice(),a=this.targetResolution_,l=this.targetRotation_;const c=[];for(;n<r;++n){const t=arguments[n],r={start:s,complete:!1,anchor:t.anchor,duration:void 0!==t.duration?t.duration:1e3,easing:t.easing||b.T9,callback:e};if(t.center&&(r.sourceCenter=o,r.targetCenter=t.center.slice(),o=r.targetCenter),void 0!==t.zoom?(r.sourceResolution=a,r.targetResolution=this.getResolutionForZoom(t.zoom),a=r.targetResolution):t.resolution&&(r.sourceResolution=a,r.targetResolution=t.resolution,a=r.targetResolution),void 0!==t.rotation){r.sourceRotation=l;const e=(0,h.xP)(t.rotation-l+Math.PI,2*Math.PI)-Math.PI;r.targetRotation=l+e,l=r.targetRotation}S(r)?r.complete=!0:s+=r.duration,c.push(r)}this.animations_.push(c),this.setHint(i.A.ANIMATING,1),this.updateAnimations_()}getAnimating(){return this.hints_[i.A.ANIMATING]>0}getInteracting(){return this.hints_[i.A.INTERACTING]>0}cancelAnimations(){let t;this.setHint(i.A.ANIMATING,-this.hints_[i.A.ANIMATING]);for(let e=0,r=this.animations_.length;e<r;++e){const r=this.animations_[e];if(r[0].callback&&E(r[0].callback,!1),!t)for(let e=0,n=r.length;e<n;++e){const n=r[e];if(!n.complete){t=n.anchor;break}}}this.animations_.length=0,this.cancelAnchor_=t,this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN}updateAnimations_(){if(void 0!==this.updateAnimationKey_&&(cancelAnimationFrame(this.updateAnimationKey_),this.updateAnimationKey_=void 0),!this.getAnimating())return;const t=Date.now();let e=!1;for(let r=this.animations_.length-1;r>=0;--r){const n=this.animations_[r];let s=!0;for(let r=0,i=n.length;r<i;++r){const i=n[r];if(i.complete)continue;const o=t-i.start;let a=i.duration>0?o/i.duration:1;a>=1?(i.complete=!0,a=1):s=!1;const l=i.easing(a);if(i.sourceCenter){const t=i.sourceCenter[0],e=i.sourceCenter[1],r=i.targetCenter[0],n=i.targetCenter[1];this.nextCenter_=i.targetCenter;const s=t+l*(r-t),o=e+l*(n-e);this.targetCenter_=[s,o]}if(i.sourceResolution&&i.targetResolution){const t=1===l?i.targetResolution:i.sourceResolution+l*(i.targetResolution-i.sourceResolution);if(i.anchor){const e=this.getViewportSize_(this.getRotation()),r=this.constraints_.resolution(t,0,e,!0);this.targetCenter_=this.calculateCenterZoom(r,i.anchor)}this.nextResolution_=i.targetResolution,this.targetResolution_=t,this.applyTargetState_(!0)}if(void 0!==i.sourceRotation&&void 0!==i.targetRotation){const t=1===l?(0,h.xP)(i.targetRotation+Math.PI,2*Math.PI)-Math.PI:i.sourceRotation+l*(i.targetRotation-i.sourceRotation);if(i.anchor){const e=this.constraints_.rotation(t,!0);this.targetCenter_=this.calculateCenterRotate(e,i.anchor)}this.nextRotation_=i.targetRotation,this.targetRotation_=t}if(this.applyTargetState_(!0),e=!0,!i.complete)break}if(s){this.animations_[r]=null,this.setHint(i.A.ANIMATING,-1),this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN;const t=n[0].callback;t&&E(t,!0)}}this.animations_=this.animations_.filter(Boolean),e&&void 0===this.updateAnimationKey_&&(this.updateAnimationKey_=requestAnimationFrame(this.updateAnimations_.bind(this)))}calculateCenterRotate(t,e){let r;const n=this.getCenterInternal();return void 0!==n&&(r=[n[0]-e[0],n[1]-e[1]],(0,c.e$)(r,t-this.getRotation()),(0,c.WQ)(r,e)),r}calculateCenterZoom(t,e){let r;const n=this.getCenterInternal(),i=this.getResolution();return void 0!==n&&void 0!==i&&(r=[e[0]-t*(e[0]-n[0])/i,e[1]-t*(e[1]-n[1])/i]),r}getViewportSize_(t){const e=this.viewportSize_;if(t){const r=e[0],n=e[1];return[Math.abs(r*Math.cos(t))+Math.abs(n*Math.sin(t)),Math.abs(r*Math.sin(t))+Math.abs(n*Math.cos(t))]}return e}setViewportSize(t){this.viewportSize_=Array.isArray(t)?t.slice():[100,100],this.getAnimating()||this.resolveConstraints(0)}getCenter(){const t=this.getCenterInternal();return t?(0,a.te)(t,this.getProjection()):t}getCenterInternal(){return this.get(s.CENTER)}getConstraints(){return this.constraints_}getConstrainResolution(){return this.get("constrainResolution")}getHints(t){return void 0!==t?(t[0]=this.hints_[0],t[1]=this.hints_[1],t):this.hints_.slice()}calculateExtent(t){const e=this.calculateExtentInternal(t);return(0,a.JR)(e,this.getProjection())}calculateExtentInternal(t){t=t||this.getViewportSizeMinusPadding_();const e=this.getCenterInternal();(0,u.v)(e,"The view center is not defined");const r=this.getResolution();(0,u.v)(void 0!==r,"The view resolution is not defined");const n=this.getRotation();return(0,u.v)(void 0!==n,"The view rotation is not defined"),(0,p.Bg)(e,r,n,t)}getMaxResolution(){return this.maxResolution_}getMinResolution(){return this.minResolution_}getMaxZoom(){return this.getZoomForResolution(this.minResolution_)}setMaxZoom(t){this.applyOptions_(this.getUpdatedOptions_({maxZoom:t}))}getMinZoom(){return this.getZoomForResolution(this.maxResolution_)}setMinZoom(t){this.applyOptions_(this.getUpdatedOptions_({minZoom:t}))}setConstrainResolution(t){this.applyOptions_(this.getUpdatedOptions_({constrainResolution:t}))}getProjection(){return this.projection_}getResolution(){return this.get(s.RESOLUTION)}getResolutions(){return this.resolutions_}getResolutionForExtent(t,e){return this.getResolutionForExtentInternal((0,a.SD)(t,this.getProjection()),e)}getResolutionForExtentInternal(t,e){e=e||this.getViewportSizeMinusPadding_();const r=(0,p.RG)(t)/e[0],n=(0,p.Oq)(t)/e[1];return Math.max(r,n)}getResolutionForValueFunction(t){t=t||2;const e=this.getConstrainedResolution(this.maxResolution_),r=this.minResolution_,n=Math.log(e/r)/Math.log(t);return function(r){return e/Math.pow(t,r*n)}}getRotation(){return this.get(s.ROTATION)}getValueForResolutionFunction(t){const e=Math.log(t||2),r=this.getConstrainedResolution(this.maxResolution_),n=this.minResolution_,i=Math.log(r/n)/e;return function(t){return Math.log(r/t)/e/i}}getViewportSizeMinusPadding_(t){let e=this.getViewportSize_(t);const r=this.padding_;return r&&(e=[e[0]-r[1]-r[3],e[1]-r[0]-r[2]]),e}getState(){const t=this.getProjection(),e=this.getResolution(),r=this.getRotation();let n=this.getCenterInternal();const i=this.padding_;if(i){const t=this.getViewportSizeMinusPadding_();n=A(n,this.getViewportSize_(),[t[0]/2+i[3],t[1]/2+i[0]],e,r)}return{center:n.slice(0),projection:void 0!==t?t:null,resolution:e,nextCenter:this.nextCenter_,nextResolution:this.nextResolution_,nextRotation:this.nextRotation_,rotation:r,zoom:this.getZoom()}}getViewStateAndExtent(){return{viewState:this.getState(),extent:this.calculateExtent()}}getZoom(){let t;const e=this.getResolution();return void 0!==e&&(t=this.getZoomForResolution(e)),t}getZoomForResolution(t){let e,r,n=this.minZoom_||0;if(this.resolutions_){const i=(0,m.FT)(this.resolutions_,t,1);n=i,e=this.resolutions_[i],r=i==this.resolutions_.length-1?2:e/this.resolutions_[i+1]}else e=this.maxResolution_,r=this.zoomFactor_;return n+Math.log(e/t)/Math.log(r)}getResolutionForZoom(t){if(this.resolutions_?.length){if(1===this.resolutions_.length)return this.resolutions_[0];const e=(0,h.qE)(Math.floor(t),0,this.resolutions_.length-2),r=this.resolutions_[e]/this.resolutions_[e+1];return this.resolutions_[e]/Math.pow(r,(0,h.qE)(t-e,0,1))}return this.maxResolution_/Math.pow(this.zoomFactor_,t-this.minZoom_)}fit(t,e){let r;if((0,u.v)(Array.isArray(t)||"function"==typeof t.getSimplifiedGeometry,"Invalid extent or geometry provided as `geometry`"),Array.isArray(t)){(0,u.v)(!(0,p.Im)(t),"Cannot fit empty extent provided as `geometry`");const e=(0,a.SD)(t,this.getProjection());r=(0,w.VY)(e)}else if("Circle"===t.getType()){const e=(0,a.SD)(t.getExtent(),this.getProjection());r=(0,w.VY)(e),r.rotate(this.getRotation(),(0,p.q1)(e))}else{const e=(0,a.Tf)();r=e?t.clone().transform(e,this.getProjection()):t}this.fitInternal(r,e)}rotatedExtentForGeometry(t){const e=this.getRotation(),r=Math.cos(e),n=Math.sin(-e),i=t.getFlatCoordinates(),s=t.getStride();let o=1/0,a=1/0,l=-1/0,c=-1/0;for(let t=0,e=i.length;t<e;t+=s){const e=i[t]*r-i[t+1]*n,s=i[t]*n+i[t+1]*r;o=Math.min(o,e),a=Math.min(a,s),l=Math.max(l,e),c=Math.max(c,s)}return[o,a,l,c]}fitInternal(t,e){let r=(e=e||{}).size;r||(r=this.getViewportSizeMinusPadding_());const n=void 0!==e.padding?e.padding:[0,0,0,0],i=void 0!==e.nearest&&e.nearest;let s;s=void 0!==e.minResolution?e.minResolution:void 0!==e.maxZoom?this.getResolutionForZoom(e.maxZoom):0;const o=this.rotatedExtentForGeometry(t);let a=this.getResolutionForExtentInternal(o,[r[0]-n[1]-n[3],r[1]-n[0]-n[2]]);a=isNaN(a)?s:Math.max(a,s),a=this.getConstrainedResolution(a,i?0:1);const c=this.getRotation(),u=Math.sin(c),h=Math.cos(c),d=(0,p.q1)(o);d[0]+=(n[1]-n[3])/2*a,d[1]+=(n[0]-n[2])/2*a;const f=d[0]*h-d[1]*u,m=d[1]*h+d[0]*u,g=this.getConstrainedCenter([f,m],a),y=e.callback?e.callback:l.tV;void 0!==e.duration?this.animateInternal({resolution:a,center:g,duration:e.duration,easing:e.easing},y):(this.targetResolution_=a,this.targetCenter_=g,this.applyTargetState_(!1,!0),E(y,!0))}centerOn(t,e,r){this.centerOnInternal((0,a.Ad)(t,this.getProjection()),e,r)}centerOnInternal(t,e,r){this.setCenterInternal(A(t,e,r,this.getResolution(),this.getRotation()))}calculateCenterShift(t,e,r,n){let i;const s=this.padding_;if(s&&t){const o=this.getViewportSizeMinusPadding_(-r),a=A(t,n,[o[0]/2+s[3],o[1]/2+s[0]],e,r);i=[t[0]-a[0],t[1]-a[1]]}return i}isDef(){return!!this.getCenterInternal()&&void 0!==this.getResolution()}adjustCenter(t){const e=(0,a.te)(this.targetCenter_,this.getProjection());this.setCenter([e[0]+t[0],e[1]+t[1]])}adjustCenterInternal(t){const e=this.targetCenter_;this.setCenterInternal([e[0]+t[0],e[1]+t[1]])}adjustResolution(t,e){e=e&&(0,a.Ad)(e,this.getProjection()),this.adjustResolutionInternal(t,e)}adjustResolutionInternal(t,e){const r=this.getAnimating()||this.getInteracting(),n=this.getViewportSize_(this.getRotation()),i=this.constraints_.resolution(this.targetResolution_*t,0,n,r);e&&(this.targetCenter_=this.calculateCenterZoom(i,e)),this.targetResolution_*=t,this.applyTargetState_()}adjustZoom(t,e){this.adjustResolution(Math.pow(this.zoomFactor_,-t),e)}adjustRotation(t,e){e&&(e=(0,a.Ad)(e,this.getProjection())),this.adjustRotationInternal(t,e)}adjustRotationInternal(t,e){const r=this.getAnimating()||this.getInteracting(),n=this.constraints_.rotation(this.targetRotation_+t,r);e&&(this.targetCenter_=this.calculateCenterRotate(n,e)),this.targetRotation_+=t,this.applyTargetState_()}setCenter(t){this.setCenterInternal(t?(0,a.Ad)(t,this.getProjection()):t)}setCenterInternal(t){this.targetCenter_=t,this.applyTargetState_()}setHint(t,e){return this.hints_[t]+=e,this.changed(),this.hints_[t]}setResolution(t){this.targetResolution_=t,this.applyTargetState_()}setRotation(t){this.targetRotation_=t,this.applyTargetState_()}setZoom(t){this.setResolution(this.getResolutionForZoom(t))}applyTargetState_(t,e){const r=this.getAnimating()||this.getInteracting()||e,n=this.constraints_.rotation(this.targetRotation_,r),i=this.getViewportSize_(n),o=this.constraints_.resolution(this.targetResolution_,0,i,r),a=this.constraints_.center(this.targetCenter_,o,i,r,this.calculateCenterShift(this.targetCenter_,o,n,i));this.get(s.ROTATION)!==n&&this.set(s.ROTATION,n),this.get(s.RESOLUTION)!==o&&(this.set(s.RESOLUTION,o),this.set("zoom",this.getZoom(),!0)),a&&this.get(s.CENTER)&&(0,c.aI)(this.get(s.CENTER),a)||this.set(s.CENTER,a),this.getAnimating()&&!t&&this.cancelAnimations(),this.cancelAnchor_=void 0}resolveConstraints(t,e,r){t=void 0!==t?t:200;const n=e||0,i=this.constraints_.rotation(this.targetRotation_),s=this.getViewportSize_(i),o=this.constraints_.resolution(this.targetResolution_,n,s),a=this.constraints_.center(this.targetCenter_,o,s,!1,this.calculateCenterShift(this.targetCenter_,o,i,s));if(0===t&&!this.cancelAnchor_)return this.targetResolution_=o,this.targetRotation_=i,this.targetCenter_=a,void this.applyTargetState_();r=r||(0===t?this.cancelAnchor_:void 0),this.cancelAnchor_=void 0,this.getResolution()===o&&this.getRotation()===i&&this.getCenterInternal()&&(0,c.aI)(this.getCenterInternal(),a)||(this.getAnimating()&&this.cancelAnimations(),this.animateInternal({rotation:i,center:a,resolution:o,duration:t,easing:b.vT,anchor:r}))}beginInteraction(){this.resolveConstraints(0),this.setHint(i.A.INTERACTING,1)}endInteraction(t,e,r){r=r&&(0,a.Ad)(r,this.getProjection()),this.endInteractionInternal(t,e,r)}endInteractionInternal(t,e,r){this.getInteracting()&&(this.setHint(i.A.INTERACTING,-1),this.resolveConstraints(t,e,r))}getConstrainedCenter(t,e){const r=this.getViewportSize_(this.getRotation());return this.constraints_.center(t,e||this.getResolution(),r)}getConstrainedZoom(t,e){const r=this.getResolutionForZoom(t);return this.getZoomForResolution(this.getConstrainedResolution(r,e))}getConstrainedResolution(t,e){e=e||0;const r=this.getViewportSize_(this.getRotation());return this.constraints_.resolution(t,e,r)}}function E(t,e){setTimeout((function(){t(e)}),0)}function S(t){return!(t.sourceCenter&&t.targetCenter&&!(0,c.aI)(t.sourceCenter,t.targetCenter))&&t.sourceResolution===t.targetResolution&&t.sourceRotation===t.targetRotation}function A(t,e,r,n,i){const s=Math.cos(-i);let o=Math.sin(-i),a=t[0]*s-t[1]*o,l=t[1]*s+t[0]*o;return a+=(e[0]/2-r[0])*n,l+=(r[1]-e[1]/2)*n,o=-o,[a*s-l*o,l*s+a*o]}const P=x},32769:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={ANIMATING:0,INTERACTING:1}},30444:(t,e,r)=>{"use strict";function n(t,e,r){let n,s;r=r||i;let o=0,a=t.length,l=!1;for(;o<a;)n=o+(a-o>>1),s=+r(t[n],e),s<0?o=n+1:(a=n,l=!s);return l?o:~o}function i(t,e){return t>e?1:t<e?-1:0}function s(t,e){return t<e?1:t>e?-1:0}function o(t,e,r){if(t[0]<=e)return 0;const n=t.length;if(e<=t[n-1])return n-1;if("function"==typeof r){for(let i=1;i<n;++i){const n=t[i];if(n===e)return i;if(n<e)return r(e,t[i-1],n)>0?i-1:i}return n-1}if(r>0){for(let r=1;r<n;++r)if(t[r]<e)return r-1;return n-1}if(r<0){for(let r=1;r<n;++r)if(t[r]<=e)return r;return n-1}for(let r=1;r<n;++r){if(t[r]==e)return r;if(t[r]<e)return t[r-1]-e<e-t[r]?r-1:r}return n-1}function a(t,e,r){for(;e<r;){const n=t[e];t[e]=t[r],t[r]=n,++e,--r}}function l(t,e){const r=Array.isArray(e)?e:[e],n=r.length;for(let e=0;e<n;e++)t[t.length]=r[e]}function c(t,e){const r=t.length;if(r!==e.length)return!1;for(let n=0;n<r;n++)if(t[n]!==e[n])return!1;return!0}function u(t,e,r){const n=e||i;return t.every((function(e,i){if(0===i)return!0;const s=n(t[i-1],e);return!(s>0||r&&0===s)}))}r.d(e,{El:()=>n,FT:()=>o,V_:()=>i,WC:()=>u,X$:()=>l,aI:()=>c,gI:()=>a,rG:()=>s})},30878:(t,e,r)=>{"use strict";function n(t,e){if(!t)throw new Error(e)}r.d(e,{v:()=>n})},41009:(t,e,r)=>{"use strict";r.d(e,{qV:()=>p,_j:()=>E,oJ:()=>m,sH:()=>x,cD:()=>w,S8:()=>S,eE:()=>b,dI:()=>A,fu:()=>_});const n={name:"rgb",min:[0,0,0],max:[255,255,255],channel:["red","green","blue"],alias:["RGB"]};var i={name:"xyz",min:[0,0,0],channel:["X","Y","Z"],alias:["XYZ","ciexyz","cie1931"],whitepoint:{2:{A:[109.85,100,35.585],C:[98.074,100,118.232],D50:[96.422,100,82.521],D55:[95.682,100,92.149],D65:[95.045592705167,100,108.9057750759878],D75:[94.972,100,122.638],F2:[99.187,100,67.395],F7:[95.044,100,108.755],F11:[100.966,100,64.37],E:[100,100,100]},10:{A:[111.144,100,35.2],C:[97.285,100,116.145],D50:[96.72,100,81.427],D55:[95.799,100,90.926],D65:[94.811,100,107.304],D75:[94.416,100,120.641],F2:[103.28,100,69.026],F7:[95.792,100,107.687],F11:[103.866,100,65.627],E:[100,100,100]}}};i.max=i.whitepoint[2].D65,i.rgb=function(t,e){e=e||i.whitepoint[2].E;var r,n,s,o=t[0]/e[0],a=t[1]/e[1],l=t[2]/e[2];return n=-.96924363628087*o+1.87596750150772*a+.041555057407175*l,s=.055630079696993*o+-.20397695888897*a+1.056971514242878*l,r=(r=3.240969941904521*o+-1.537383177570093*a+-.498610760293*l)>.0031308?1.055*Math.pow(r,1/2.4)-.055:r*=12.92,n=n>.0031308?1.055*Math.pow(n,1/2.4)-.055:n*=12.92,s=s>.0031308?1.055*Math.pow(s,1/2.4)-.055:s*=12.92,[255*(r=Math.min(Math.max(0,r),1)),255*(n=Math.min(Math.max(0,n),1)),255*(s=Math.min(Math.max(0,s),1))]},n.xyz=function(t,e){var r=t[0]/255,n=t[1]/255,s=t[2]/255,o=.21263900587151*(r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92)+.71516867876775*(n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92)+.072192315360733*(s=s>.04045?Math.pow((s+.055)/1.055,2.4):s/12.92),a=.019330818715591*r+.11919477979462*n+.95053215224966*s;return[(.41239079926595*r+.35758433938387*n+.18048078840183*s)*(e=e||i.whitepoint[2].E)[0],o*e[1],a*e[2]]};const s=i,o={name:"luv",min:[0,-134,-140],max:[100,224,122],channel:["lightness","u","v"],alias:["LUV","cieluv","cie1976"],xyz:function(t,e,r){var n,i,o,a,l,c,u,h,d;return o=t[0],a=t[1],l=t[2],0===o?[0,0,0]:(e=e||"D65",r=r||2,n=a/(13*o)+4*(u=s.whitepoint[r][e][0])/(u+15*(h=s.whitepoint[r][e][1])+3*(d=s.whitepoint[r][e][2]))||0,i=l/(13*o)+9*h/(u+15*h+3*d)||0,[9*(c=o>8?h*Math.pow((o+16)/116,3):h*o*.0011070564598794539)*n/(4*i)||0,c,c*(12-3*n-20*i)/(4*i)||0])}};s.luv=function(t,e,r){var n,i,o,a,l,c,u,h,d,f,p;e=e||"D65",r=r||2,f=4*(u=s.whitepoint[r][e][0])/(u+15*(h=s.whitepoint[r][e][1])+3*(d=s.whitepoint[r][e][2])),p=9*h/(u+15*h+3*d),n=4*(a=t[0])/(a+15*(l=t[1])+3*(c=t[2]))||0,i=9*l/(a+15*l+3*c)||0;var m=l/h;return[o=m<=.008856451679035631?903.2962962962961*m:116*Math.pow(m,1/3)-16,13*o*(n-f),13*o*(i-p)]};var a={name:"lchuv",channel:["lightness","chroma","hue"],alias:["LCHuv","cielchuv"],min:[0,0,0],max:[100,100,360],luv:function(t){var e,r=t[0],n=t[1];return e=t[2]/360*2*Math.PI,[r,n*Math.cos(e),n*Math.sin(e)]},xyz:function(t){return o.xyz(a.luv(t))}};const l=a;o.lchuv=function(t){var e=t[0],r=t[1],n=t[2],i=Math.sqrt(r*r+n*n),s=360*Math.atan2(n,r)/2/Math.PI;return s<0&&(s+=360),[e,i,s]},s.lchuv=function(t){return o.lchuv(s.luv(t))};const c={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},u=function(t){var e,r,n=[],i=1;if("number"==typeof t)return{space:"rgb",values:[t>>>16,(65280&t)>>>8,255&t],alpha:1};if("number"==typeof t)return{space:"rgb",values:[t>>>16,(65280&t)>>>8,255&t],alpha:1};if(t=String(t).toLowerCase(),c[t])n=c[t].slice(),r="rgb";else if("transparent"===t)i=0,r="rgb",n=[0,0,0];else if("#"===t[0]){var s=t.slice(1),o=s.length;i=1,o<=4?(n=[parseInt(s[0]+s[0],16),parseInt(s[1]+s[1],16),parseInt(s[2]+s[2],16)],4===o&&(i=parseInt(s[3]+s[3],16)/255)):(n=[parseInt(s[0]+s[1],16),parseInt(s[2]+s[3],16),parseInt(s[4]+s[5],16)],8===o&&(i=parseInt(s[6]+s[7],16)/255)),n[0]||(n[0]=0),n[1]||(n[1]=0),n[2]||(n[2]=0),r="rgb"}else if(e=/^((?:rgba?|hs[lvb]a?|hwba?|cmyk?|xy[zy]|gray|lab|lchu?v?|[ly]uv|lms|oklch|oklab|color))\s*\(([^\)]*)\)/.exec(t)){var a=e[1],l="cmyk"===(r=a.replace(/a$/,""))?4:"gray"===r?1:3;n=e[2].trim().split(/\s*[,\/]\s*|\s+/),"color"===r&&(r=n.shift()),i=(n=n.map((function(t,e){if("%"===t[t.length-1])return t=parseFloat(t)/100,3===e?t:"rgb"===r?255*t:"h"===r[0]?100*t:"l"!==r[0]||e?"lab"===r?125*t:"lch"===r?e<2?150*t:360*t:"o"!==r[0]||e?"oklab"===r?.4*t:"oklch"===r?e<2?.4*t:360*t:t:t:100*t;if("h"===r[e]||2===e&&"h"===r[r.length-1]){if(void 0!==h[t])return h[t];if(t.endsWith("deg"))return parseFloat(t);if(t.endsWith("turn"))return 360*parseFloat(t);if(t.endsWith("grad"))return 360*parseFloat(t)/400;if(t.endsWith("rad"))return 180*parseFloat(t)/Math.PI}return"none"===t?0:parseFloat(t)}))).length>l?n.pop():1}else/[0-9](?:\s|\/|,)/.test(t)&&(n=t.match(/([0-9]+)/g).map((function(t){return parseFloat(t)})),r=t.match(/([a-z])/gi)?.join("")?.toLowerCase()||"rgb");return{space:r,values:n,alpha:i}};var h={red:0,orange:60,yellow:120,green:180,blue:240,purple:300};const d={name:"hsl",min:[0,0,0],max:[360,100,100],channel:["hue","saturation","lightness"],alias:["HSL"],rgb:function(t){var e,r,n,i,s,o=t[0]/360,a=t[1]/100,l=t[2]/100,c=0;if(0===a)return[s=255*l,s,s];for(e=2*l-(r=l<.5?l*(1+a):l+a-l*a),i=[0,0,0];c<3;)(n=o+1/3*-(c-1))<0?n++:n>1&&n--,s=6*n<1?e+6*(r-e)*n:2*n<1?r:3*n<2?e+(r-e)*(2/3-n)*6:e,i[c++]=255*s;return i}};n.hsl=function(t){var e,r,n=t[0]/255,i=t[1]/255,s=t[2]/255,o=Math.min(n,i,s),a=Math.max(n,i,s),l=a-o;return a===o?e=0:n===a?e=(i-s)/l:i===a?e=2+(s-n)/l:s===a&&(e=4+(n-i)/l),(e=Math.min(60*e,360))<0&&(e+=360),r=(o+a)/2,[e,100*(a===o?0:r<=.5?l/(a+o):l/(2-a-o)),100*r]};var f=r(72475);const p=[NaN,NaN,NaN,0];function m(t){return"string"==typeof t?t:A(t)}const g=1024,y={};let v=0;function _(t){if(4===t.length)return t;const e=t.slice();return e[3]=1,e}function b(t){const e=s.lchuv(n.xyz(t));return e[3]=t[3],e}function w(t){const e=s.rgb(l.xyz(t));return e[3]=t[3],e}function x(t){if("none"===t)return p;if(y.hasOwnProperty(t))return y[t];if(v>=g){let t=0;for(const e in y)3&t++||(delete y[e],--v)}const e=function(t){var e;Array.isArray(t)&&t.raw&&(t=String.raw(...arguments)),t instanceof Number&&(t=+t);var r=u(t);if(!r.space)return[];const i="h"===r.space[0]?d.min:n.min,s="h"===r.space[0]?d.max:n.max;return(e=Array(3))[0]=Math.min(Math.max(r.values[0],i[0]),s[0]),e[1]=Math.min(Math.max(r.values[1],i[1]),s[1]),e[2]=Math.min(Math.max(r.values[2],i[2]),s[2]),"h"===r.space[0]&&(e=d.rgb(e)),e.push(Math.min(Math.max(r.alpha,0),1)),e}(t);if(4!==e.length)throw new Error('failed to parse "'+t+'" as color');for(const r of e)if(isNaN(r))throw new Error('failed to parse "'+t+'" as color');return S(e),y[t]=e,++v,e}function E(t){return Array.isArray(t)?t:x(t)}function S(t){return t[0]=(0,f.qE)(t[0]+.5|0,0,255),t[1]=(0,f.qE)(t[1]+.5|0,0,255),t[2]=(0,f.qE)(t[2]+.5|0,0,255),t[3]=(0,f.qE)(t[3],0,1),t}function A(t){let e=t[0];e!=(0|e)&&(e=e+.5|0);let r=t[1];r!=(0|r)&&(r=r+.5|0);let n=t[2];return n!=(0|n)&&(n=n+.5|0),"rgba("+e+","+r+","+n+","+(void 0===t[3]?1:Math.round(1e3*t[3])/1e3)+")"}},67029:(t,e,r)=>{"use strict";r.d(e,{F:()=>l});var n=r(39915),i=r(83085),s=r(98525),o=r(67031),a=r(41009);function l(t){return t?Array.isArray(t)?(0,a.dI)(t):"object"==typeof t&&"src"in t?function(t){if(!t.offset||!t.size)return o.ue.getPattern(t.src,"anonymous",t.color);const e=t.src+":"+t.offset,r=o.ue.getPattern(e,void 0,t.color);if(r)return r;const a=o.ue.get(t.src,"anonymous",null);if(a.getImageState()!==n.A.LOADED)return null;const l=(0,i.Y)(t.size[0],t.size[1]);return l.drawImage(a.getImage(1),t.offset[0],t.offset[1],t.size[0],t.size[1],0,0,t.size[0],t.size[1]),(0,s.J)(l.canvas,e,void 0,n.A.LOADED,t.color,!0),o.ue.getPattern(e,void 0,t.color)}(t):t:null}},96372:(t,e,r)=>{"use strict";r.d(e,{R8:()=>s,z3:()=>o});const n={info:1,warn:2,error:3,none:4};let i=n.info;function s(...t){i>n.warn||console.warn(...t)}function o(...t){i>n.error||console.error(...t)}},41554:(t,e,r)=>{"use strict";r.d(e,{A:()=>l});var n=r(72614),i=r(63479),s=r(97440),o=r(94456);class a extends n.A{constructor(t){super();const e=t.element;!e||t.target||e.style.pointerEvents||(e.style.pointerEvents="auto"),this.element=e||null,this.target_=null,this.map_=null,this.listenerKeys=[],t.render&&(this.render=t.render),t.target&&this.setTarget(t.target)}disposeInternal(){this.element?.remove(),super.disposeInternal()}getMap(){return this.map_}setMap(t){this.map_&&this.element?.remove();for(let t=0,e=this.listenerKeys.length;t<e;++t)(0,o.JH)(this.listenerKeys[t]);this.listenerKeys.length=0,this.map_=t,t&&((this.target_??t.getOverlayContainerStopEvent()).appendChild(this.element),this.render!==s.tV&&this.listenerKeys.push((0,o.KT)(t,i.A.POSTRENDER,this.render,this)),t.render())}render(t){}setTarget(t){this.target_="string"==typeof t?document.getElementById(t):t}}const l=a},77835:(t,e,r)=>{"use strict";r.d(e,{A:()=>u});var n=r(41554),i=r(71686),s=r(12940);const o="units",a=[1,2,5],l=25.4/.28;class c extends n.A{constructor(t){t=t||{};const e=document.createElement("div");e.style.pointerEvents="none",super({element:e,render:t.render,target:t.target}),this.on,this.once,this.un;const r=void 0!==t.className?t.className:t.bar?"ol-scale-bar":"ol-scale-line";this.innerElement_=document.createElement("div"),this.innerElement_.className=r+"-inner",this.element.className=r+" "+i.XI,this.element.appendChild(this.innerElement_),this.viewState_=null,this.minWidth_=void 0!==t.minWidth?t.minWidth:64,this.maxWidth_=t.maxWidth,this.renderedVisible_=!1,this.renderedWidth_=void 0,this.renderedHTML_="",this.addChangeListener(o,this.handleUnitsChanged_),this.setUnits(t.units||"metric"),this.scaleBar_=t.bar||!1,this.scaleBarSteps_=t.steps||4,this.scaleBarText_=t.text||!1,this.dpi_=t.dpi||void 0}getUnits(){return this.get(o)}handleUnitsChanged_(){this.updateElement_()}setUnits(t){this.set(o,t)}setDpi(t){this.dpi_=t}updateElement_(){const t=this.viewState_;if(!t)return void(this.renderedVisible_&&(this.element.style.display="none",this.renderedVisible_=!1));const e=t.center,r=t.projection,n=this.getUnits(),i="degrees"==n?"degrees":"m";let o=(0,s.hO)(r,t.resolution,e,i);const c=this.minWidth_*(this.dpi_||l)/l,u=void 0!==this.maxWidth_?this.maxWidth_*(this.dpi_||l)/l:void 0;let h=c*o,d="";if("degrees"==n){const t=s.Ig.degrees;h*=t,h<t/60?(d="″",o*=3600):h<t?(d="′",o*=60):d="°"}else if("imperial"==n)h<.9144?(d="in",o/=.0254):h<1609.344?(d="ft",o/=.3048):(d="mi",o/=1609.344);else if("nautical"==n)o/=1852,d="NM";else if("metric"==n)h<1e-6?(d="nm",o*=1e9):h<.001?(d="μm",o*=1e6):h<1?(d="mm",o*=1e3):h<1e3?d="m":(d="km",o/=1e3);else{if("us"!=n)throw new Error("Invalid units");h<.9144?(d="in",o*=39.37):h<1609.344?(d="ft",o/=.30480061):(d="mi",o/=1609.3472)}let f,p,m,g,y,v,_=3*Math.floor(Math.log(c*o)/Math.log(10));for(;;){m=Math.floor(_/3);const t=Math.pow(10,m);if(f=a[(_%3+3)%3]*t,p=Math.round(f/o),isNaN(p))return this.element.style.display="none",void(this.renderedVisible_=!1);if(void 0!==u&&p>=u){f=g,p=y,m=v;break}if(p>=c)break;g=f,y=p,v=m,++_}const b=this.scaleBar_?this.createScaleBar(p,f,d):f.toFixed(m<0?-m:0)+" "+d;this.renderedHTML_!=b&&(this.innerElement_.innerHTML=b,this.renderedHTML_=b),this.renderedWidth_!=p&&(this.innerElement_.style.width=p+"px",this.renderedWidth_=p),this.renderedVisible_||(this.element.style.display="",this.renderedVisible_=!0)}createScaleBar(t,e,r){const n=this.getScaleForResolution(),i=n<1?Math.round(1/n).toLocaleString()+" : 1":"1 : "+Math.round(n).toLocaleString(),s=this.scaleBarSteps_,o=t/s,a=[this.createMarker("absolute")];for(let n=0;n<s;++n){const i=n%2==0?"ol-scale-singlebar-odd":"ol-scale-singlebar-even";a.push(`<div><div class="ol-scale-singlebar ${i}" style="width: ${o}px;"></div>`+this.createMarker("relative")+(n%2==0||2===s?this.createStepText(n,t,!1,e,r):"")+"</div>")}return a.push(this.createStepText(s,t,!0,e,r)),(this.scaleBarText_?`<div class="ol-scale-text" style="width: ${t}px;">`+i+"</div>":"")+a.join("")}createMarker(t){return`<div class="ol-scale-step-marker" style="position: ${t}; top: ${"absolute"===t?3:-10}px;"></div>`}createStepText(t,e,r,n,i){const s=(0===t?0:Math.round(n/this.scaleBarSteps_*t*100)/100)+(0===t?"":" "+i);return`<div class="ol-scale-step-text" style="margin-left: ${0===t?-3:e/this.scaleBarSteps_*-1}px;text-align: ${0===t?"left":"center"};min-width: ${0===t?0:e/this.scaleBarSteps_*2}px;left: ${r?e+"px":"unset"};">`+s+"</div>"}getScaleForResolution(){return(0,s.hO)(this.viewState_.projection,this.viewState_.resolution,this.viewState_.center,"m")*(1e3/25.4)*(this.dpi_||l)}render(t){const e=t.frameState;this.viewState_=e?e.viewState:null,this.updateElement_()}}const u=c},9535:(t,e,r)=>{"use strict";r.d(e,{Li:()=>l,WQ:()=>i,aI:()=>s,e$:()=>o,hs:()=>a});var n=r(44509);function i(t,e){return t[0]+=+e[0],t[1]+=+e[1],t}function s(t,e){let r=!0;for(let n=t.length-1;n>=0;--n)if(t[n]!=e[n]){r=!1;break}return r}function o(t,e){const r=Math.cos(e),n=Math.sin(e),i=t[0]*r-t[1]*n,s=t[1]*r+t[0]*n;return t[0]=i,t[1]=s,t}function a(t,e){return t[0]*=e,t[1]*=e,t}function l(t,e){if(e.canWrapX()){const r=(0,n.RG)(e.getExtent()),i=function(t,e,r){const i=e.getExtent();let s=0;return e.canWrapX()&&(t[0]<i[0]||t[0]>i[2])&&(r=r||(0,n.RG)(i),s=Math.floor((t[0]-i[0])/r)),s}(t,e,r);i&&(t[0]-=i*r)}return t}},71686:(t,e,r)=>{"use strict";r.d(e,{$N:()=>s,K5:()=>c,Si:()=>n,XI:()=>i,nT:()=>o});const n="ol-hidden",i="ol-unselectable",s="ol-control",o="ol-collapsed",a=new RegExp(["^\\s*(?=(?:(?:[-a-z]+\\s*){0,2}(italic|oblique))?)","(?=(?:(?:[-a-z]+\\s*){0,2}(small-caps))?)","(?=(?:(?:[-a-z]+\\s*){0,2}(bold(?:er)?|lighter|[1-9]00 ))?)","(?:(?:normal|\\1|\\2|\\3)\\s*){0,3}((?:xx?-)?","(?:small|large)|medium|smaller|larger|[\\.\\d]+(?:\\%|in|[cem]m|ex|p[ctx]))","(?:\\s*\\/\\s*(normal|[\\.\\d]+(?:\\%|in|[cem]m|ex|p[ctx])?))","?\\s*([-,\\\"\\'\\sa-z]+?)\\s*$"].join(""),"i"),l=["style","variant","weight","size","lineHeight","family"],c=function(t){const e=t.match(a);if(!e)return null;const r={lineHeight:"normal",size:"1.2em",style:"normal",weight:"normal",variant:"normal"};for(let t=0,n=l.length;t<n;++t){const n=e[t+1];void 0!==n&&(r[l[t]]=n)}return r.families=r.family.split(/,\s?/),r}},83085:(t,e,r)=>{"use strict";r.d(e,{WM:()=>u,Y:()=>i,Yg:()=>a,fo:()=>l,gS:()=>c,lr:()=>o});var n=r(66993);function i(t,e,r,i){let s;return s=r&&r.length?r.shift():n.Wl?new OffscreenCanvas(t||300,e||300):document.createElement("canvas"),t&&(s.width=t),e&&(s.height=e),s.getContext("2d",i)}let s;function o(){return s||(s=i(1,1)),s}function a(t){const e=t.canvas;e.width=1,e.height=1,t.clearRect(0,0,1,1)}function l(t,e){const r=e.parentNode;r&&r.replaceChild(t,e)}function c(t){for(;t.lastChild;)t.lastChild.remove()}function u(t,e){const r=t.childNodes;for(let n=0;;++n){const i=r[n],s=e[n];if(!i&&!s)break;i!==s&&(i?s?t.insertBefore(s,i):(t.removeChild(i),--n):t.appendChild(s))}}},2620:(t,e,r)=>{"use strict";function n(t){return Math.pow(t,3)}function i(t){return 1-n(1-t)}function s(t){return 3*t*t-2*t*t*t}function o(t){return t}r.d(e,{T9:()=>s,a6:()=>n,sn:()=>o,vT:()=>i})},94456:(t,e,r)=>{"use strict";r.d(e,{JH:()=>o,Jz:()=>s,KT:()=>i});var n=r(82048);function i(t,e,r,n,i){if(i){const i=r;r=function(){t.removeEventListener(e,r),i.apply(n??this,arguments)}}else n&&n!==t&&(r=r.bind(n));const s={target:t,type:e,listener:r};return t.addEventListener(e,r),s}function s(t,e,r,n){return i(t,e,r,n,!0)}function o(t){t&&t.target&&(t.target.removeEventListener(t.type,t.listener),(0,n.I)(t))}},37283:(t,e,r)=>{"use strict";r.d(e,{Ay:()=>n});const n=class{constructor(t){this.propagationStopped,this.defaultPrevented,this.type=t,this.target=null}preventDefault(){this.defaultPrevented=!0}stopPropagation(){this.propagationStopped=!0}}},24187:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={CHANGE:"change",ERROR:"error",BLUR:"blur",CLEAR:"clear",CONTEXTMENU:"contextmenu",CLICK:"click",DBLCLICK:"dblclick",DRAGENTER:"dragenter",DRAGOVER:"dragover",DROP:"drop",FOCUS:"focus",KEYDOWN:"keydown",KEYPRESS:"keypress",LOAD:"load",RESIZE:"resize",TOUCHMOVE:"touchmove",WHEEL:"wheel"}},91086:(t,e,r)=>{"use strict";r.d(e,{A:()=>l});var n=r(60239),i=r(37283),s=r(97440),o=r(82048);class a extends n.A{constructor(t){super(),this.eventTarget_=t,this.pendingRemovals_=null,this.dispatching_=null,this.listeners_=null}addEventListener(t,e){if(!t||!e)return;const r=this.listeners_||(this.listeners_={}),n=r[t]||(r[t]=[]);n.includes(e)||n.push(e)}dispatchEvent(t){const e="string"==typeof t,r=e?t:t.type,n=this.listeners_&&this.listeners_[r];if(!n)return;const o=e?new i.Ay(t):t;o.target||(o.target=this.eventTarget_||this);const a=this.dispatching_||(this.dispatching_={}),l=this.pendingRemovals_||(this.pendingRemovals_={});let c;r in a||(a[r]=0,l[r]=0),++a[r];for(let t=0,e=n.length;t<e;++t)if(c="handleEvent"in n[t]?n[t].handleEvent(o):n[t].call(this,o),!1===c||o.propagationStopped){c=!1;break}if(0==--a[r]){let t=l[r];for(delete l[r];t--;)this.removeEventListener(r,s.tV);delete a[r]}return c}disposeInternal(){this.listeners_&&(0,o.I)(this.listeners_)}getListeners(t){return this.listeners_&&this.listeners_[t]||void 0}hasListener(t){return!!this.listeners_&&(t?t in this.listeners_:Object.keys(this.listeners_).length>0)}removeEventListener(t,e){if(!this.listeners_)return;const r=this.listeners_[t];if(!r)return;const n=r.indexOf(e);-1!==n&&(this.pendingRemovals_&&t in this.pendingRemovals_?(r[n]=s.tV,++this.pendingRemovals_[t]):(r.splice(n,1),0===r.length&&delete this.listeners_[t]))}}const l=a},62439:(t,e,r)=>{"use strict";r.d(e,{DG:()=>b,Fq:()=>h,SR:()=>w,T8:()=>a,Ye:()=>D,ZD:()=>E,_D:()=>_,cT:()=>c,go:()=>g,mE:()=>u,qA:()=>d,qg:()=>x,wl:()=>l});var n=r(30444),i=r(41009),s=r(53908);let o=0;const a=1<<o++,l=1<<o++,c=1<<o++,u=1<<o++,h=1<<o++,d=1<<o++,f=Math.pow(2,6)-1,p={[a]:"boolean",[l]:"number",[c]:"string",[u]:"color",[h]:"number[]",[d]:"size"},m=Object.keys(p).map(Number).sort(n.V_);function g(t){const e=[];for(const r of m)y(t,r)&&e.push(p[r]);return 0===e.length?"untyped":e.length<3?e.join(" or "):e.slice(0,-1).join(", ")+", or "+e[e.length-1]}function y(t,e){return(t&e)===e}function v(t,e){return t===e}class _{constructor(t,e){if(!function(t){return t in p}(t))throw new Error(`literal expressions must have a specific type, got ${g(t)}`);this.type=t,this.value=e}}class b{constructor(t,e,...r){this.type=t,this.operator=e,this.args=r}}function w(){return{variables:new Set,properties:new Set,featureId:!1,geometryType:!1}}function x(t,e,r){switch(typeof t){case"boolean":if(v(e,c))return new _(c,t?"true":"false");if(!y(e,a))throw new Error(`got a boolean, but expected ${g(e)}`);return new _(a,t);case"number":if(v(e,d))return new _(d,(0,s.xq)(t));if(v(e,a))return new _(a,!!t);if(v(e,c))return new _(c,t.toString());if(!y(e,l))throw new Error(`got a number, but expected ${g(e)}`);return new _(l,t);case"string":if(v(e,u))return new _(u,(0,i.sH)(t));if(v(e,a))return new _(a,!!t);if(!y(e,c))throw new Error(`got a string, but expected ${g(e)}`);return new _(c,t)}if(!Array.isArray(t))throw new Error("expression must be an array or a primitive value");if(0===t.length)throw new Error("empty expression");if("string"==typeof t[0])return function(t,e,r){const n=t[0],i=S[n];if(!i)throw new Error(`unknown operator: ${n}`);return i(t,e,r)}(t,e,r);for(const e of t)if("number"!=typeof e)throw new Error("expected an array of numbers");if(v(e,d)){if(2!==t.length)throw new Error(`expected an array of two values for a size, got ${t.length}`);return new _(d,t)}if(v(e,u)){if(3===t.length)return new _(u,[...t,1]);if(4===t.length)return new _(u,t);throw new Error(`expected an array of 3 or 4 values for a color, got ${t.length}`)}if(!y(e,h))throw new Error(`got an array of numbers, but expected ${g(e)}`);return new _(h,t)}const E={Get:"get",Var:"var",Concat:"concat",GeometryType:"geometry-type",LineMetric:"line-metric",Any:"any",All:"all",Not:"!",Resolution:"resolution",Zoom:"zoom",Time:"time",Equal:"==",NotEqual:"!=",GreaterThan:">",GreaterThanOrEqualTo:">=",LessThan:"<",LessThanOrEqualTo:"<=",Multiply:"*",Divide:"/",Add:"+",Subtract:"-",Clamp:"clamp",Mod:"%",Pow:"^",Abs:"abs",Floor:"floor",Ceil:"ceil",Round:"round",Sin:"sin",Cos:"cos",Atan:"atan",Sqrt:"sqrt",Match:"match",Between:"between",Interpolate:"interpolate",Coalesce:"coalesce",Case:"case",In:"in",Number:"number",String:"string",Array:"array",Color:"color",Id:"id",Band:"band",Palette:"palette",ToString:"to-string",Has:"has"},S={[E.Get]:R(T(1,1/0),A),[E.Var]:R(T(1,1),(function(t,e,r){const n=t[1];if("string"!=typeof n)throw new Error("expected a string argument for var operation");return r.variables.add(n),[new _(c,n)]})),[E.Has]:R(T(1,1/0),A),[E.Id]:R((function(t,e,r){r.featureId=!0}),P),[E.Concat]:R(T(2,1/0),M(c)),[E.GeometryType]:R((function(t,e,r){r.geometryType=!0}),P),[E.LineMetric]:R(P),[E.Resolution]:R(P),[E.Zoom]:R(P),[E.Time]:R(P),[E.Any]:R(T(2,1/0),M(a)),[E.All]:R(T(2,1/0),M(a)),[E.Not]:R(T(1,1),M(a)),[E.Equal]:R(T(2,2),M(f)),[E.NotEqual]:R(T(2,2),M(f)),[E.GreaterThan]:R(T(2,2),M(l)),[E.GreaterThanOrEqualTo]:R(T(2,2),M(l)),[E.LessThan]:R(T(2,2),M(l)),[E.LessThanOrEqualTo]:R(T(2,2),M(l)),[E.Multiply]:R(T(2,1/0),C),[E.Coalesce]:R(T(2,1/0),C),[E.Divide]:R(T(2,2),M(l)),[E.Add]:R(T(2,1/0),M(l)),[E.Subtract]:R(T(2,2),M(l)),[E.Clamp]:R(T(3,3),M(l)),[E.Mod]:R(T(2,2),M(l)),[E.Pow]:R(T(2,2),M(l)),[E.Abs]:R(T(1,1),M(l)),[E.Floor]:R(T(1,1),M(l)),[E.Ceil]:R(T(1,1),M(l)),[E.Round]:R(T(1,1),M(l)),[E.Sin]:R(T(1,1),M(l)),[E.Cos]:R(T(1,1),M(l)),[E.Atan]:R(T(1,2),M(l)),[E.Sqrt]:R(T(1,1),M(l)),[E.Match]:R(T(4,1/0),O,(function(t,e,r){const n=t.length-1,i=c|l|a,s=x(t[1],i,r),o=x(t[t.length-1],e,r),u=new Array(n-2);for(let e=0;e<n-2;e+=2){try{const n=x(t[e+2],s.type,r);u[e]=n}catch(t){throw new Error(`failed to parse argument ${e+1} of match expression: ${t.message}`)}try{const n=x(t[e+3],o.type,r);u[e+1]=n}catch(t){throw new Error(`failed to parse argument ${e+2} of match expression: ${t.message}`)}}return[s,...u,o]})),[E.Between]:R(T(3,3),M(l)),[E.Interpolate]:R(T(6,1/0),O,(function(t,e,r){const n=t[1];let i;switch(n[0]){case"linear":i=1;break;case"exponential":const t=n[1];if("number"!=typeof t||t<=0)throw new Error(`expected a number base for exponential interpolation, got ${JSON.stringify(t)} instead`);i=t;break;default:throw new Error(`invalid interpolation type: ${JSON.stringify(n)}`)}const s=new _(l,i);let o;try{o=x(t[2],l,r)}catch(t){throw new Error(`failed to parse argument 1 in interpolate expression: ${t.message}`)}const a=new Array(t.length-3);for(let n=0;n<a.length;n+=2){try{const e=x(t[n+3],l,r);a[n]=e}catch(t){throw new Error(`failed to parse argument ${n+2} for interpolate expression: ${t.message}`)}try{const i=x(t[n+4],e,r);a[n+1]=i}catch(t){throw new Error(`failed to parse argument ${n+3} for interpolate expression: ${t.message}`)}}return[s,o,...a]})),[E.Case]:R(T(3,1/0),(function(t,e,r){const n=t[0],i=t.length-1;if(i%2==0)throw new Error(`expected an odd number of arguments for ${n}, got ${i} instead`)}),(function(t,e,r){const n=x(t[t.length-1],e,r),i=new Array(t.length-1);for(let e=0;e<i.length-1;e+=2){try{const n=x(t[e+1],a,r);i[e]=n}catch(t){throw new Error(`failed to parse argument ${e} of case expression: ${t.message}`)}try{const s=x(t[e+2],n.type,r);i[e+1]=s}catch(t){throw new Error(`failed to parse argument ${e+1} of case expression: ${t.message}`)}}return i[i.length-1]=n,i})),[E.In]:R(T(2,2),(function(t,e,r){let n,i=t[2];if(!Array.isArray(i))throw new Error('the second argument for the "in" operator must be an array');if("string"==typeof i[0]){if("literal"!==i[0])throw new Error('for the "in" operator, a string array should be wrapped in a "literal" operator to disambiguate from expressions');if(!Array.isArray(i[1]))throw new Error('failed to parse "in" expression: the literal operator must be followed by an array');i=i[1],n=c}else n=l;const s=new Array(i.length);for(let t=0;t<s.length;t++)try{const e=x(i[t],n,r);s[t]=e}catch(e){throw new Error(`failed to parse haystack item ${t} for "in" expression: ${e.message}`)}return[x(t[1],n,r),...s]})),[E.Number]:R(T(1,1/0),M(f)),[E.String]:R(T(1,1/0),M(f)),[E.Array]:R(T(1,1/0),M(l)),[E.Color]:R(T(1,4),M(l)),[E.Band]:R(T(1,3),M(l)),[E.Palette]:R(T(2,2),(function(t,e,r){let n;try{n=x(t[1],l,r)}catch(t){throw new Error(`failed to parse first argument in palette expression: ${t.message}`)}const i=t[2];if(!Array.isArray(i))throw new Error("the second argument of palette must be an array");const s=new Array(i.length);for(let t=0;t<s.length;t++){let e;try{e=x(i[t],u,r)}catch(e){throw new Error(`failed to parse color at index ${t} in palette expression: ${e.message}`)}if(!(e instanceof _))throw new Error(`the palette color at index ${t} must be a literal value`);s[t]=e}return[n,...s]})),[E.ToString]:R(T(1,1),M(a|l|c|u))};function A(t,e,r){const n=t.length-1,i=new Array(n);for(let e=0;e<n;++e){const n=t[e+1];switch(typeof n){case"number":i[e]=new _(l,n);break;case"string":i[e]=new _(c,n);break;default:throw new Error(`expected a string key or numeric array index for a get operation, got ${n}`)}0===e&&r.properties.add(String(n))}return i}function P(t,e,r){const n=t[0];if(1!==t.length)throw new Error(`expected no arguments for ${n} operation`);return[]}function T(t,e){return function(r,n,i){const s=r[0],o=r.length-1;if(t===e){if(o!==t)throw new Error(`expected ${t} argument${1===t?"":"s"} for ${s}, got ${o}`)}else if(o<t||o>e)throw new Error(`expected ${e===1/0?`${t} or more`:`${t} to ${e}`} arguments for ${s}, got ${o}`)}}function C(t,e,r){const n=t.length-1,i=new Array(n);for(let s=0;s<n;++s){const n=x(t[s+1],e,r);i[s]=n}return i}function M(t){return function(e,r,n){const i=e.length-1,s=new Array(i);for(let r=0;r<i;++r){const i=x(e[r+1],t,n);s[r]=i}return s}}function O(t,e,r){const n=t[0],i=t.length-1;if(i%2==1)throw new Error(`expected an even number of arguments for operation ${n}, got ${i} instead`)}function R(...t){return function(e,r,n){const i=e[0];let s;for(let i=0;i<t.length;i++){const o=t[i](e,r,n);if(i==t.length-1){if(!o)throw new Error("expected last argument validator to return the parsed args");s=o}}return new b(r,i,...s)}}function D(t){if(!t)return"";const e=t.getType();switch(e){case"Point":case"LineString":case"Polygon":return e;case"MultiPoint":case"MultiLineString":case"MultiPolygon":return e.substring(5);case"Circle":return"Polygon";case"GeometryCollection":return D(t.getGeometries()[0]);default:return""}}},44509:(t,e,r)=>{"use strict";r.d(e,{$C:()=>_,$u:()=>F,Bg:()=>C,HY:()=>k,Im:()=>L,Ld:()=>a,Li:()=>G,Mx:()=>j,N:()=>f,NW:()=>N,Oq:()=>M,Py:()=>R,QJ:()=>$,R:()=>S,R8:()=>b,RG:()=>I,Rj:()=>u,S5:()=>d,Tr:()=>i,UG:()=>E,Vy:()=>g,WU:()=>D,X$:()=>v,Ym:()=>l,_N:()=>O,aI:()=>y,aZ:()=>p,dP:()=>m,k_:()=>A,ms:()=>c,o8:()=>o,q1:()=>P,qF:()=>T,r:()=>s,sB:()=>x,vz:()=>h});var n=r(85262);function i(t){const e=[1/0,1/0,-1/0,-1/0];for(let r=0,n=t.length;r<n;++r)_(e,t[r]);return e}function s(t,e,r){return r?(r[0]=t[0]-e,r[1]=t[1]-e,r[2]=t[2]+e,r[3]=t[3]+e,r):[t[0]-e,t[1]-e,t[2]+e,t[3]+e]}function o(t,e){return e?(e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e):t.slice()}function a(t,e,r){let n,i;return n=e<t[0]?t[0]-e:t[2]<e?e-t[2]:0,i=r<t[1]?t[1]-r:t[3]<r?r-t[3]:0,n*n+i*i}function l(t,e){return u(t,e[0],e[1])}function c(t,e){return t[0]<=e[0]&&e[2]<=t[2]&&t[1]<=e[1]&&e[3]<=t[3]}function u(t,e,r){return t[0]<=e&&e<=t[2]&&t[1]<=r&&r<=t[3]}function h(t,e){const r=t[0],i=t[1],s=t[2],o=t[3],a=e[0],l=e[1];let c=n.A.UNKNOWN;return a<r?c|=n.A.LEFT:a>s&&(c|=n.A.RIGHT),l<i?c|=n.A.BELOW:l>o&&(c|=n.A.ABOVE),c===n.A.UNKNOWN&&(c=n.A.INTERSECTING),c}function d(){return[1/0,1/0,-1/0,-1/0]}function f(t,e,r,n,i){return i?(i[0]=t,i[1]=e,i[2]=r,i[3]=n,i):[t,e,r,n]}function p(t){return f(1/0,1/0,-1/0,-1/0,t)}function m(t,e){const r=t[0],n=t[1];return f(r,n,r,n,e)}function g(t,e,r,n,i){return b(p(i),t,e,r,n)}function y(t,e){return t[0]==e[0]&&t[2]==e[2]&&t[1]==e[1]&&t[3]==e[3]}function v(t,e){return e[0]<t[0]&&(t[0]=e[0]),e[2]>t[2]&&(t[2]=e[2]),e[1]<t[1]&&(t[1]=e[1]),e[3]>t[3]&&(t[3]=e[3]),t}function _(t,e){e[0]<t[0]&&(t[0]=e[0]),e[0]>t[2]&&(t[2]=e[0]),e[1]<t[1]&&(t[1]=e[1]),e[1]>t[3]&&(t[3]=e[1])}function b(t,e,r,n,i){for(;r<n;r+=i)w(t,e[r],e[r+1]);return t}function w(t,e,r){t[0]=Math.min(t[0],e),t[1]=Math.min(t[1],r),t[2]=Math.max(t[2],e),t[3]=Math.max(t[3],r)}function x(t,e){let r;return r=e(S(t)),r||(r=e(A(t)),r||(r=e(D(t)),r||(r=e(R(t)),r||!1)))}function E(t){let e=0;return L(t)||(e=I(t)*M(t)),e}function S(t){return[t[0],t[1]]}function A(t){return[t[2],t[1]]}function P(t){return[(t[0]+t[2])/2,(t[1]+t[3])/2]}function T(t,e){let r;if("bottom-left"===e)r=S(t);else if("bottom-right"===e)r=A(t);else if("top-left"===e)r=R(t);else{if("top-right"!==e)throw new Error("Invalid corner");r=D(t)}return r}function C(t,e,r,n,i){const[s,o,a,l,c,u,h,d]=function(t,e,r,n){const i=e*n[0]/2,s=e*n[1]/2,o=Math.cos(r),a=Math.sin(r),l=i*o,c=i*a,u=s*o,h=s*a,d=t[0],f=t[1];return[d-l+h,f-c-u,d-l-h,f-c+u,d+l-h,f+c+u,d+l+h,f+c-u,d-l+h,f-c-u]}(t,e,r,n);return f(Math.min(s,a,c,h),Math.min(o,l,u,d),Math.max(s,a,c,h),Math.max(o,l,u,d),i)}function M(t){return t[3]-t[1]}function O(t,e,r){const n=r||[1/0,1/0,-1/0,-1/0];return k(t,e)?(t[0]>e[0]?n[0]=t[0]:n[0]=e[0],t[1]>e[1]?n[1]=t[1]:n[1]=e[1],t[2]<e[2]?n[2]=t[2]:n[2]=e[2],t[3]<e[3]?n[3]=t[3]:n[3]=e[3]):p(n),n}function R(t){return[t[0],t[3]]}function D(t){return[t[2],t[3]]}function I(t){return t[2]-t[0]}function k(t,e){return t[0]<=e[2]&&t[2]>=e[0]&&t[1]<=e[3]&&t[3]>=e[1]}function L(t){return t[2]<t[0]||t[3]<t[1]}function F(t,e){return e?(e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e):t}function j(t,e,r){let i=!1;const s=h(t,e),o=h(t,r);if(s===n.A.INTERSECTING||o===n.A.INTERSECTING)i=!0;else{const a=t[0],l=t[1],c=t[2],u=t[3],h=e[0],d=e[1],f=r[0],p=r[1],m=(p-d)/(f-h);let g,y;o&n.A.ABOVE&&!(s&n.A.ABOVE)&&(g=f-(p-u)/m,i=g>=a&&g<=c),i||!(o&n.A.RIGHT)||s&n.A.RIGHT||(y=p-(f-c)*m,i=y>=l&&y<=u),i||!(o&n.A.BELOW)||s&n.A.BELOW||(g=f-(p-l)/m,i=g>=a&&g<=c),i||!(o&n.A.LEFT)||s&n.A.LEFT||(y=p-(f-a)*m,i=y>=l&&y<=u)}return i}function N(t,e,r,n){if(L(t))return p(r);let i=[];if(n>1){const e=t[2]-t[0],r=t[3]-t[1];for(let s=0;s<n;++s)i.push(t[0]+e*s/n,t[1],t[2],t[1]+r*s/n,t[2]-e*s/n,t[3],t[0],t[3]-r*s/n)}else i=[t[0],t[1],t[2],t[1],t[2],t[3],t[0],t[3]];e(i,i,2);const s=[],o=[];for(let t=0,e=i.length;t<e;t+=2)s.push(i[t]),o.push(i[t+1]);return function(t,e,r){return f(Math.min.apply(null,t),Math.min.apply(null,e),Math.max.apply(null,t),Math.max.apply(null,e),r)}(s,o,r)}function G(t,e){const r=e.getExtent(),n=P(t);if(e.canWrapX()&&(n[0]<r[0]||n[0]>=r[2])){const e=I(r),i=Math.floor((n[0]-r[0])/e)*e;t[0]-=i,t[2]-=i}return t}function $(t,e,r){if(e.canWrapX()){const n=e.getExtent();if(!isFinite(t[0])||!isFinite(t[2]))return[[n[0],t[1],n[2],t[3]]];G(t,e);const i=I(n);if(I(t)>i&&!r)return[[n[0],t[1],n[2],t[3]]];if(t[0]<n[0])return[[t[0]+i,t[1],n[2],t[3]],[n[0],t[1],t[2],t[3]]];if(t[2]>n[2])return[[t[0],t[1],n[2],t[3]],[n[0],t[1],t[2]-i,t[3]]]}return[t]}},85262:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={UNKNOWN:0,INTERSECTING:1,ABOVE:2,RIGHT:4,BELOW:8,LEFT:16}},64272:(t,e,r)=>{"use strict";r.d(e,{m8:()=>s,nF:()=>o});var n=r(97440);let i=!1;function s(t,e,r,n,s,o,a){const l=new XMLHttpRequest;l.open("GET","function"==typeof t?t(r,n,s):t,!0),"arraybuffer"==e.getType()&&(l.responseType="arraybuffer"),l.withCredentials=i,l.onload=function(t){if(!l.status||l.status>=200&&l.status<300){const t=e.getType();try{let n;"text"==t||"json"==t?n=l.responseText:"xml"==t?n=l.responseXML||l.responseText:"arraybuffer"==t&&(n=l.response),n?o(e.readFeatures(n,{extent:r,featureProjection:s}),e.readProjection(n)):a()}catch{a()}}else a()},l.onerror=a,l.send()}function o(t,e){return function(r,i,o,a,l){const c=this;s(t,e,r,i,o,(function(t,e){c.addFeatures(t),void 0!==a&&a(t)}),l||n.tV)}}},69612:(t,e,r)=>{"use strict";r.d(e,{te:()=>A,Bs:()=>S,Ay:()=>w,hX:()=>x});var n=r(75839),i=r(28528),s=r(20696),o=r(67955),a=r(68609),l=r(30173),c=r(81924),u=r(61437),h=r(24187),d=r(96488),f=r(44509),p=r(94456);class m extends d.A{constructor(t){super(),this.geometries_=t,this.changeEventsKeys_=[],this.listenGeometriesChange_()}unlistenGeometriesChange_(){this.changeEventsKeys_.forEach(p.JH),this.changeEventsKeys_.length=0}listenGeometriesChange_(){const t=this.geometries_;for(let e=0,r=t.length;e<r;++e)this.changeEventsKeys_.push((0,p.KT)(t[e],h.A.CHANGE,this.changed,this))}clone(){const t=new m(g(this.geometries_));return t.applyProperties(this),t}closestPointXY(t,e,r,n){if(n<(0,f.Ld)(this.getExtent(),t,e))return n;const i=this.geometries_;for(let s=0,o=i.length;s<o;++s)n=i[s].closestPointXY(t,e,r,n);return n}containsXY(t,e){const r=this.geometries_;for(let n=0,i=r.length;n<i;++n)if(r[n].containsXY(t,e))return!0;return!1}computeExtent(t){(0,f.aZ)(t);const e=this.geometries_;for(let r=0,n=e.length;r<n;++r)(0,f.X$)(t,e[r].getExtent());return t}getGeometries(){return g(this.geometries_)}getGeometriesArray(){return this.geometries_}getGeometriesArrayRecursive(){let t=[];const e=this.geometries_;for(let r=0,n=e.length;r<n;++r)e[r].getType()===this.getType()?t=t.concat(e[r].getGeometriesArrayRecursive()):t.push(e[r]);return t}getSimplifiedGeometry(t){if(this.simplifiedGeometryRevision!==this.getRevision()&&(this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=this.getRevision()),t<0||0!==this.simplifiedGeometryMaxMinSquaredTolerance&&t<this.simplifiedGeometryMaxMinSquaredTolerance)return this;const e=[],r=this.geometries_;let n=!1;for(let i=0,s=r.length;i<s;++i){const s=r[i],o=s.getSimplifiedGeometry(t);e.push(o),o!==s&&(n=!0)}return n?new m(e):(this.simplifiedGeometryMaxMinSquaredTolerance=t,this)}getType(){return"GeometryCollection"}intersectsExtent(t){const e=this.geometries_;for(let r=0,n=e.length;r<n;++r)if(e[r].intersectsExtent(t))return!0;return!1}isEmpty(){return 0===this.geometries_.length}rotate(t,e){const r=this.geometries_;for(let n=0,i=r.length;n<i;++n)r[n].rotate(t,e);this.changed()}scale(t,e,r){r||(r=(0,f.q1)(this.getExtent()));const n=this.geometries_;for(let i=0,s=n.length;i<s;++i)n[i].scale(t,e,r);this.changed()}setGeometries(t){this.setGeometriesArray(g(t))}setGeometriesArray(t){this.unlistenGeometriesChange_(),this.geometries_=t,this.listenGeometriesChange_(),this.changed()}applyTransform(t){const e=this.geometries_;for(let r=0,n=e.length;r<n;++r)e[r].applyTransform(t);this.changed()}translate(t,e){const r=this.geometries_;for(let n=0,i=r.length;n<i;++n)r[n].translate(t,e);this.changed()}disposeInternal(){this.unlistenGeometriesChange_(),super.disposeInternal()}}function g(t){return t.map((t=>t.clone()))}const y=m;var v=r(98629),_=r(12940),b=r(65709);const w=class{constructor(){this.dataProjection=void 0,this.defaultFeatureProjection=void 0,this.featureClass=n.A,this.supportedMediaTypes=null}getReadOptions(t,e){if(e){let r=e.dataProjection?(0,_.Jt)(e.dataProjection):this.readProjection(t);e.extent&&r&&"tile-pixels"===r.getUnits()&&(r=(0,_.Jt)(r),r.setWorldExtent(e.extent)),e={dataProjection:r,featureProjection:e.featureProjection}}return this.adaptOptions(e)}adaptOptions(t){return Object.assign({dataProjection:this.dataProjection,featureProjection:this.defaultFeatureProjection,featureClass:this.featureClass},t)}getType(){return(0,v.b0)()}readFeature(t,e){return(0,v.b0)()}readFeatures(t,e){return(0,v.b0)()}readGeometry(t,e){return(0,v.b0)()}readProjection(t){return(0,v.b0)()}writeFeature(t,e){return(0,v.b0)()}writeFeatures(t,e){return(0,v.b0)()}writeGeometry(t,e){return(0,v.b0)()}};function x(t,e,r){const n=r?(0,_.Jt)(r.featureProjection):null,i=r?(0,_.Jt)(r.dataProjection):null;let s=t;if(n&&i&&!(0,_.tI)(n,i)){e&&(s=t.clone());const r=e?n:i,o=e?i:n;"tile-pixels"===r.getUnits()?s.transform(r,o):s.applyTransform((0,_.RG)(r,o))}if(e&&r&&void 0!==r.decimals){const e=Math.pow(10,r.decimals),n=function(t){for(let r=0,n=t.length;r<n;++r)t[r]=Math.round(t[r]*e)/e;return t};s===t&&(s=t.clone()),s.applyTransform(n)}return s}const E={Point:s.A,LineString:o.A,Polygon:a.Ay,MultiPoint:l.A,MultiLineString:c.A,MultiPolygon:u.A};function S(t,e){const r=t.geometry;if(!r)return[];if(Array.isArray(r))return r.map((e=>S({...t,geometry:e}))).flat();const n="MultiPolygon"===r.type?"Polygon":r.type;if("GeometryCollection"===n||"Circle"===n)throw new Error("Unsupported geometry type: "+n);const s=r.layout.length;return x(new i.Ay(n,"Polygon"===n?function(t,e,r){return Array.isArray(e[0])?((0,b.mb)(t,0,e,r)||(t=t.slice(),(0,b.NK)(t,0,e,r)),t):((0,b.PA)(t,0,e,r)||(t=t.slice(),(0,b.ug)(t,0,e,r)),t)}(r.flatCoordinates,r.ends,s):r.flatCoordinates,r.ends?.flat(),s,t.properties||{},t.id).enableSimplifyTransformed(),!1,e)}function A(t,e){if(!t)return null;if(Array.isArray(t)){const r=t.map((t=>A(t,e)));return new y(r)}return x(new(0,E[t.type])(t.flatCoordinates,t.layout,t.ends),!1,e)}},56952:(t,e,r)=>{"use strict";r.d(e,{A:()=>g});var n=r(75839),i=r(69612),s=r(98629);class o extends i.Ay{constructor(){super()}getType(){return"json"}readFeature(t,e){return this.readFeatureFromObject(a(t),this.getReadOptions(t,e))}readFeatures(t,e){return this.readFeaturesFromObject(a(t),this.getReadOptions(t,e))}readFeatureFromObject(t,e){return(0,s.b0)()}readFeaturesFromObject(t,e){return(0,s.b0)()}readGeometry(t,e){return this.readGeometryFromObject(a(t),this.getReadOptions(t,e))}readGeometryFromObject(t,e){return(0,s.b0)()}readProjection(t){return this.readProjectionFromObject(a(t))}readProjectionFromObject(t){return(0,s.b0)()}writeFeature(t,e){return JSON.stringify(this.writeFeatureObject(t,e))}writeFeatureObject(t,e){return(0,s.b0)()}writeFeatures(t,e){return JSON.stringify(this.writeFeaturesObject(t,e))}writeFeaturesObject(t,e){return(0,s.b0)()}writeGeometry(t,e){return JSON.stringify(this.writeGeometryObject(t,e))}writeGeometryObject(t,e){return(0,s.b0)()}}function a(t){if("string"==typeof t){return JSON.parse(t)||null}return null!==t?t:null}const l=o;var c=r(28528),u=r(28851),h=r(31886),d=r(12940),f=r(82048);function p(t,e){if(!t)return null;let r;switch(t.type){case"Point":r=function(t){const e=t.coordinates;return{type:"Point",flatCoordinates:e,layout:(0,h.p0)(e.length)}}(t);break;case"LineString":r=function(t){const e=t.coordinates,r=e.flat();return{type:"LineString",flatCoordinates:r,ends:[r.length],layout:(0,h.p0)(e[0]?.length||2)}}(t);break;case"Polygon":r=function(t){const e=t.coordinates,r=[],n=e[0]?.[0]?.length;return{type:"Polygon",flatCoordinates:r,ends:(0,u.KG)(r,0,e,n),layout:(0,h.p0)(n)}}(t);break;case"MultiPoint":r=function(t){const e=t.coordinates;return{type:"MultiPoint",flatCoordinates:e.flat(),layout:(0,h.p0)(e[0]?.length||2)}}(t);break;case"MultiLineString":r=function(t){const e=t.coordinates,r=e[0]?.[0]?.length||2,n=[];return{type:"MultiLineString",flatCoordinates:n,ends:(0,u.KG)(n,0,e,r),layout:(0,h.p0)(r)}}(t);break;case"MultiPolygon":r=function(t){const e=t.coordinates,r=[],n=e[0]?.[0]?.[0].length||2;return{type:"MultiPolygon",flatCoordinates:r,ends:(0,u.d6)(r,0,e,n),layout:(0,h.p0)(n)}}(t);break;case"GeometryCollection":r=function(t){const e=t.geometries.map((function(t){return p(t)}));return e}(t);break;default:throw new Error("Unsupported GeoJSON type: "+t.type)}return r}function m(t,e){const r=(t=(0,i.hX)(t,!0,e)).getType();let n;switch(r){case"Point":n=function(t){return{type:"Point",coordinates:t.getCoordinates()}}(t);break;case"LineString":n=function(t){return{type:"LineString",coordinates:t.getCoordinates()}}(t);break;case"Polygon":n=function(t,e){let r;return e&&(r=e.rightHanded),{type:"Polygon",coordinates:t.getCoordinates(r)}}(t,e);break;case"MultiPoint":n=function(t){return{type:"MultiPoint",coordinates:t.getCoordinates()}}(t);break;case"MultiLineString":n=function(t){return{type:"MultiLineString",coordinates:t.getCoordinates()}}(t);break;case"MultiPolygon":n=function(t,e){let r;return e&&(r=e.rightHanded),{type:"MultiPolygon",coordinates:t.getCoordinates(r)}}(t,e);break;case"GeometryCollection":n=function(t,e){delete(e=Object.assign({},e)).featureProjection;return{type:"GeometryCollection",geometries:t.getGeometriesArray().map((function(t){return m(t,e)}))}}(t,e);break;case"Circle":n={type:"GeometryCollection",geometries:[]};break;default:throw new Error("Unsupported geometry type: "+r)}return n}const g=class extends l{constructor(t){t=t||{},super(),this.dataProjection=(0,d.Jt)(t.dataProjection?t.dataProjection:"EPSG:4326"),t.featureProjection&&(this.defaultFeatureProjection=(0,d.Jt)(t.featureProjection)),t.featureClass&&(this.featureClass=t.featureClass),this.geometryName_=t.geometryName,this.extractGeometryName_=t.extractGeometryName,this.supportedMediaTypes=["application/geo+json","application/vnd.geo+json"]}readFeatureFromObject(t,e){let r=null;r="Feature"===t.type?t:{type:"Feature",geometry:t,properties:null};const s=p(r.geometry);if(this.featureClass===c.Ay)return(0,i.Bs)({geometry:s,id:r.id,properties:r.properties},e);const o=new n.A;return this.geometryName_?o.setGeometryName(this.geometryName_):this.extractGeometryName_&&r.geometry_name&&o.setGeometryName(r.geometry_name),o.setGeometry((0,i.te)(s,e)),"id"in r&&o.setId(r.id),r.properties&&o.setProperties(r.properties,!0),o}readFeaturesFromObject(t,e){let r=null;if("FeatureCollection"===t.type){r=[];const n=t.features;for(let t=0,i=n.length;t<i;++t){const i=this.readFeatureFromObject(n[t],e);i&&r.push(i)}}else r=[this.readFeatureFromObject(t,e)];return r.flat()}readGeometryFromObject(t,e){return function(t,e){const r=p(t);return(0,i.te)(r,e)}(t,e)}readProjectionFromObject(t){const e=t.crs;let r;if(e)if("name"==e.type)r=(0,d.Jt)(e.properties.name);else{if("EPSG"!==e.type)throw new Error("Unknown SRS type");r=(0,d.Jt)("EPSG:"+e.properties.code)}else r=this.dataProjection;return r}writeFeatureObject(t,e){e=this.adaptOptions(e);const r={type:"Feature",geometry:null,properties:null},n=t.getId();if(void 0!==n&&(r.id=n),!t.hasProperties())return r;const i=t.getProperties(),s=t.getGeometry();return s&&(r.geometry=m(s,e),delete i[t.getGeometryName()]),(0,f.p)(i)||(r.properties=i),r}writeFeaturesObject(t,e){e=this.adaptOptions(e);const r=[];for(let n=0,i=t.length;n<i;++n)r.push(this.writeFeatureObject(t[n],e));return{type:"FeatureCollection",features:r}}writeGeometryObject(t,e){return m(t,this.adaptOptions(e))}}},39512:(t,e,r)=>{"use strict";r.d(e,{A:()=>b});var n=r(69612),i=r(67955),s=r(81924),o=r(30173),a=r(61437),l=r(38286),c=r(20696),u=r(68609),h=r(55528),d=r(28528),f=r(12940),p=r(65709);class m extends n.Ay{constructor(t){super(),t=t||{},this.dataProjection=new h.A({code:"",units:"tile-pixels"}),this.featureClass=t.featureClass?t.featureClass:d.Ay,this.geometryName_=t.geometryName,this.layerName_=t.layerName?t.layerName:"layer",this.layers_=t.layers?t.layers:null,this.idProperty_=t.idProperty,this.supportedMediaTypes=["application/vnd.mapbox-vector-tile","application/x-protobuf"]}readRawGeometry_(t,e,r,n){t.pos=e.geometry;const i=t.readVarint()+t.pos;let s=1,o=0,a=0,l=0,c=0,u=0;for(;t.pos<i;){if(!o){const e=t.readVarint();s=7&e,o=e>>3}if(o--,1===s||2===s)a+=t.readSVarint(),l+=t.readSVarint(),1===s&&c>u&&(n.push(c),u=c),r.push(a,l),c+=2;else{if(7!==s)throw new Error("Invalid command found in the PBF");c>u&&(r.push(r[u],r[u+1]),c+=2)}}c>u&&(n.push(c),u=c)}createFeature_(t,e,r){const l=e.type;if(0===l)return null;let h;const f=e.properties;let m;this.idProperty_?(m=f[this.idProperty_],delete f[this.idProperty_]):m=e.id,f[this.layerName_]=e.layer.name;const g=[],y=[];this.readRawGeometry_(t,e,g,y);const v=function(t,e){let r;return 1===t?r=1===e?"Point":"MultiPoint":2===t?r=1===e?"LineString":"MultiLineString":3===t&&(r="Polygon"),r}(l,y.length);if(this.featureClass===d.Ay)h=new this.featureClass(v,g,y,2,f,m),h.transform(r.dataProjection);else{let t;if("Polygon"==v){const e=(0,p.yJ)(g,y);t=e.length>1?new a.A(g,"XY",e):new u.Ay(g,"XY",y)}else t="Point"===v?new c.A(g,"XY"):"LineString"===v?new i.A(g,"XY"):"MultiPoint"===v?new o.A(g,"XY"):"MultiLineString"===v?new s.A(g,"XY",y):null;h=new(0,this.featureClass),this.geometryName_&&h.setGeometryName(this.geometryName_);const e=(0,n.hX)(t,!1,r);h.setGeometry(e),void 0!==m&&h.setId(m),h.setProperties(f,!0)}return h}getType(){return"arraybuffer"}readFeatures(t,e){const r=this.layers_;e=this.adaptOptions(e);const n=(0,f.Jt)(e.dataProjection);n.setWorldExtent(e.extent),e.dataProjection=n;const i=new l.A(t),s=i.readFields(g,{}),o=[];for(const t in s){if(r&&!r.includes(t))continue;const a=s[t],l=a?[0,0,a.extent,a.extent]:null;n.setExtent(l);for(let t=0,r=a.length;t<r;++t){const r=_(i,a,t),n=this.createFeature_(i,r,e);null!==n&&o.push(n)}}return o}readProjection(t){return this.dataProjection}setLayers(t){this.layers_=t}}function g(t,e,r){if(3===t){const t={keys:[],values:[],features:[]},n=r.readVarint()+r.pos;r.readFields(y,t,n),t.length=t.features.length,t.length&&(e[t.name]=t)}}function y(t,e,r){if(15===t)e.version=r.readVarint();else if(1===t)e.name=r.readString();else if(5===t)e.extent=r.readVarint();else if(2===t)e.features.push(r.pos);else if(3===t)e.keys.push(r.readString());else if(4===t){let n=null;const i=r.readVarint()+r.pos;for(;r.pos<i;)n=1==(t=r.readVarint()>>3)?r.readString():2===t?r.readFloat():3===t?r.readDouble():4===t?r.readVarint64():5===t?r.readVarint():6===t?r.readSVarint():7===t?r.readBoolean():null;e.values.push(n)}}function v(t,e,r){if(1==t)e.id=r.readVarint();else if(2==t){const t=r.readVarint()+r.pos;for(;r.pos<t;){const t=e.layer.keys[r.readVarint()],n=e.layer.values[r.readVarint()];e.properties[t]=n}}else 3==t?e.type=r.readVarint():4==t&&(e.geometry=r.pos)}function _(t,e,r){t.pos=e.features[r];const n=t.readVarint()+t.pos,i={layer:e,type:0,properties:{}};return t.readFields(v,i,n),i}const b=m},97440:(t,e,r)=>{"use strict";r.d(e,{B4:()=>a,W8:()=>s,hq:()=>l,rT:()=>i,tV:()=>o});var n=r(30444);function i(){return!0}function s(){return!1}function o(){}function a(t){let e,r,i;return function(){const s=Array.prototype.slice.call(arguments);return r&&this===i&&(0,n.aI)(s,r)||(i=this,r=s,e=t.apply(this,arguments)),e}}function l(t){return function(){let e;try{e=t()}catch(t){return Promise.reject(t)}return e instanceof Promise?e:Promise.resolve(e)}()}},96488:(t,e,r)=>{"use strict";r.d(e,{A:()=>d});var n=r(72614),i=r(98629),s=r(37377),o=r(44509),a=r(12940),l=r(97440),c=r(70772);const u=(0,s.vt)();class h extends n.A{constructor(){super(),this.extent_=(0,o.S5)(),this.extentRevision_=-1,this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=0,this.simplifyTransformedInternal=(0,l.B4)(((t,e,r)=>{if(!r)return this.getSimplifiedGeometry(e);const n=this.clone();return n.applyTransform(r),n.getSimplifiedGeometry(e)}))}simplifyTransformed(t,e){return this.simplifyTransformedInternal(this.getRevision(),t,e)}clone(){return(0,i.b0)()}closestPointXY(t,e,r,n){return(0,i.b0)()}containsXY(t,e){const r=this.getClosestPoint([t,e]);return r[0]===t&&r[1]===e}getClosestPoint(t,e){return e=e||[NaN,NaN],this.closestPointXY(t[0],t[1],e,1/0),e}intersectsCoordinate(t){return this.containsXY(t[0],t[1])}computeExtent(t){return(0,i.b0)()}getExtent(t){if(this.extentRevision_!=this.getRevision()){const t=this.computeExtent(this.extent_);(isNaN(t[0])||isNaN(t[1]))&&(0,o.aZ)(t),this.extentRevision_=this.getRevision()}return(0,o.$u)(this.extent_,t)}rotate(t,e){(0,i.b0)()}scale(t,e,r){(0,i.b0)()}simplify(t){return this.getSimplifiedGeometry(t*t)}getSimplifiedGeometry(t){return(0,i.b0)()}getType(){return(0,i.b0)()}applyTransform(t){(0,i.b0)()}intersectsExtent(t){return(0,i.b0)()}translate(t,e){(0,i.b0)()}transform(t,e){const r=(0,a.Jt)(t),n="tile-pixels"==r.getUnits()?function(t,n,i){const l=r.getExtent(),h=r.getWorldExtent(),d=(0,o.Oq)(h)/(0,o.Oq)(l);return(0,s.Zz)(u,h[0],h[3],d,-d,0,0,0),(0,c.Rc)(t,0,t.length,i,u,n),(0,a.RG)(r,e)(t,n,i)}:(0,a.RG)(r,e);return this.applyTransform(n),this}}const d=h},67955:(t,e,r)=>{"use strict";r.d(e,{A:()=>m});var n=r(31886),i=r(28519),s=r(44509),o=r(28851),a=r(9761),l=r(30444),c=r(35024),u=r(35455),h=r(82611),d=r(78096),f=r(22346);class p extends n.Ay{constructor(t,e){super(),this.flatMidpoint_=null,this.flatMidpointRevision_=-1,this.maxDelta_=-1,this.maxDeltaRevision_=-1,void 0===e||Array.isArray(t[0])?this.setCoordinates(t,e):this.setFlatCoordinates(e,t)}appendCoordinate(t){(0,l.X$)(this.flatCoordinates,t),this.changed()}clone(){const t=new p(this.flatCoordinates.slice(),this.layout);return t.applyProperties(this),t}closestPointXY(t,e,r,n){return n<(0,s.Ld)(this.getExtent(),t,e)?n:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt((0,i.MD)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),(0,i.n)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,this.maxDelta_,!1,t,e,r,n))}forEachSegment(t){return(0,c.j)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)}getCoordinateAtM(t,e){return"XYM"!=this.layout&&"XYZM"!=this.layout?null:(e=void 0!==e&&e,(0,h.gr)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,e))}getCoordinates(){return(0,u.n2)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getCoordinateAt(t,e){return(0,h.SH)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,e,this.stride)}getLength(){return(0,f.k)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getFlatMidpoint(){return this.flatMidpointRevision_!=this.getRevision()&&(this.flatMidpoint_=this.getCoordinateAt(.5,this.flatMidpoint_??void 0),this.flatMidpointRevision_=this.getRevision()),this.flatMidpoint_}getSimplifiedGeometryInternal(t){const e=[];return e.length=(0,a.P4)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,e,0),new p(e,"XY")}getType(){return"LineString"}intersectsExtent(t){return(0,d.gp)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)}setCoordinates(t,e){this.setLayout(e,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=(0,o.z2)(this.flatCoordinates,0,t,this.stride),this.changed()}}const m=p},81924:(t,e,r)=>{"use strict";r.d(e,{A:()=>p});var n=r(67955),i=r(31886),s=r(28519),o=r(44509),a=r(28851),l=r(9761),c=r(30444),u=r(35455),h=r(82611),d=r(78096);class f extends i.Ay{constructor(t,e,r){if(super(),this.ends_=[],this.maxDelta_=-1,this.maxDeltaRevision_=-1,Array.isArray(t[0]))this.setCoordinates(t,e);else if(void 0!==e&&r)this.setFlatCoordinates(e,t),this.ends_=r;else{const e=t,r=[],n=[];for(let t=0,i=e.length;t<i;++t){const i=e[t];(0,c.X$)(r,i.getFlatCoordinates()),n.push(r.length)}const i=0===e.length?this.getLayout():e[0].getLayout();this.setFlatCoordinates(i,r),this.ends_=n}}appendLineString(t){(0,c.X$)(this.flatCoordinates,t.getFlatCoordinates().slice()),this.ends_.push(this.flatCoordinates.length),this.changed()}clone(){const t=new f(this.flatCoordinates.slice(),this.layout,this.ends_.slice());return t.applyProperties(this),t}closestPointXY(t,e,r,n){return n<(0,o.Ld)(this.getExtent(),t,e)?n:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt((0,s.HX)(this.flatCoordinates,0,this.ends_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),(0,s.oW)(this.flatCoordinates,0,this.ends_,this.stride,this.maxDelta_,!1,t,e,r,n))}getCoordinateAtM(t,e,r){return"XYM"!=this.layout&&"XYZM"!=this.layout||0===this.flatCoordinates.length?null:(e=void 0!==e&&e,r=void 0!==r&&r,(0,h.L8)(this.flatCoordinates,0,this.ends_,this.stride,t,e,r))}getCoordinates(){return(0,u.cD)(this.flatCoordinates,0,this.ends_,this.stride)}getEnds(){return this.ends_}getLineString(t){return t<0||this.ends_.length<=t?null:new n.A(this.flatCoordinates.slice(0===t?0:this.ends_[t-1],this.ends_[t]),this.layout)}getLineStrings(){const t=this.flatCoordinates,e=this.ends_,r=this.layout,i=[];let s=0;for(let o=0,a=e.length;o<a;++o){const a=e[o],l=new n.A(t.slice(s,a),r);i.push(l),s=a}return i}getFlatMidpoints(){const t=[],e=this.flatCoordinates;let r=0;const n=this.ends_,i=this.stride;for(let s=0,o=n.length;s<o;++s){const o=n[s],a=(0,h.SH)(e,r,o,i,.5);(0,c.X$)(t,a),r=o}return t}getSimplifiedGeometryInternal(t){const e=[],r=[];return e.length=(0,l.AL)(this.flatCoordinates,0,this.ends_,this.stride,t,e,0,r),new f(e,"XY",r)}getType(){return"MultiLineString"}intersectsExtent(t){return(0,d.fB)(this.flatCoordinates,0,this.ends_,this.stride,t)}setCoordinates(t,e){this.setLayout(e,t,2),this.flatCoordinates||(this.flatCoordinates=[]);const r=(0,a.KG)(this.flatCoordinates,0,t,this.stride,this.ends_);this.flatCoordinates.length=0===r.length?0:r[r.length-1],this.changed()}}const p=f},30173:(t,e,r)=>{"use strict";r.d(e,{A:()=>h});var n=r(20696),i=r(31886),s=r(44509),o=r(28851),a=r(30444),l=r(35455),c=r(72475);class u extends i.Ay{constructor(t,e){super(),e&&!Array.isArray(t[0])?this.setFlatCoordinates(e,t):this.setCoordinates(t,e)}appendPoint(t){(0,a.X$)(this.flatCoordinates,t.getFlatCoordinates()),this.changed()}clone(){const t=new u(this.flatCoordinates.slice(),this.layout);return t.applyProperties(this),t}closestPointXY(t,e,r,n){if(n<(0,s.Ld)(this.getExtent(),t,e))return n;const i=this.flatCoordinates,o=this.stride;for(let s=0,a=i.length;s<a;s+=o){const a=(0,c.hG)(t,e,i[s],i[s+1]);if(a<n){n=a;for(let t=0;t<o;++t)r[t]=i[s+t];r.length=o}}return n}getCoordinates(){return(0,l.n2)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getPoint(t){const e=this.flatCoordinates.length/this.stride;return t<0||e<=t?null:new n.A(this.flatCoordinates.slice(t*this.stride,(t+1)*this.stride),this.layout)}getPoints(){const t=this.flatCoordinates,e=this.layout,r=this.stride,i=[];for(let s=0,o=t.length;s<o;s+=r){const o=new n.A(t.slice(s,s+r),e);i.push(o)}return i}getType(){return"MultiPoint"}intersectsExtent(t){const e=this.flatCoordinates,r=this.stride;for(let n=0,i=e.length;n<i;n+=r){const r=e[n],i=e[n+1];if((0,s.Rj)(t,r,i))return!0}return!1}setCoordinates(t,e){this.setLayout(e,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=(0,o.z2)(this.flatCoordinates,0,t,this.stride),this.changed()}}const h=u},61437:(t,e,r)=>{"use strict";r.d(e,{A:()=>_});var n=r(30173),i=r(68609),s=r(31886),o=r(28519),a=r(44509),l=r(28851),c=r(30444),u=r(93350),h=r(35455),d=r(78096),f=r(65709),p=r(45999),m=r(77055),g=r(16587),y=r(9761);class v extends s.Ay{constructor(t,e,r){if(super(),this.endss_=[],this.flatInteriorPointsRevision_=-1,this.flatInteriorPoints_=null,this.maxDelta_=-1,this.maxDeltaRevision_=-1,this.orientedRevision_=-1,this.orientedFlatCoordinates_=null,!r&&!Array.isArray(t[0])){const n=t,i=[],s=[];for(let t=0,e=n.length;t<e;++t){const e=n[t],r=i.length,o=e.getEnds();for(let t=0,e=o.length;t<e;++t)o[t]+=r;(0,c.X$)(i,e.getFlatCoordinates()),s.push(o)}e=0===n.length?this.getLayout():n[0].getLayout(),t=i,r=s}void 0!==e&&r?(this.setFlatCoordinates(e,t),this.endss_=r):this.setCoordinates(t,e)}appendPolygon(t){let e;if(this.flatCoordinates){const r=this.flatCoordinates.length;(0,c.X$)(this.flatCoordinates,t.getFlatCoordinates()),e=t.getEnds().slice();for(let t=0,n=e.length;t<n;++t)e[t]+=r}else this.flatCoordinates=t.getFlatCoordinates().slice(),e=t.getEnds().slice(),this.endss_.push();this.endss_.push(e),this.changed()}clone(){const t=this.endss_.length,e=new Array(t);for(let r=0;r<t;++r)e[r]=this.endss_[r].slice();const r=new v(this.flatCoordinates.slice(),this.layout,e);return r.applyProperties(this),r}closestPointXY(t,e,r,n){return n<(0,a.Ld)(this.getExtent(),t,e)?n:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt((0,o.c)(this.flatCoordinates,0,this.endss_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),(0,o.te)(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,this.maxDelta_,!0,t,e,r,n))}containsXY(t,e){return(0,g.Gd)(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t,e)}getArea(){return(0,p.Cs)(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride)}getCoordinates(t){let e;return void 0!==t?(e=this.getOrientedFlatCoordinates().slice(),(0,f.NK)(e,0,this.endss_,this.stride,t)):e=this.flatCoordinates,(0,h.Dz)(e,0,this.endss_,this.stride)}getEndss(){return this.endss_}getFlatInteriorPoints(){if(this.flatInteriorPointsRevision_!=this.getRevision()){const t=(0,m.C)(this.flatCoordinates,0,this.endss_,this.stride);this.flatInteriorPoints_=(0,u.p)(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t),this.flatInteriorPointsRevision_=this.getRevision()}return this.flatInteriorPoints_}getInteriorPoints(){return new n.A(this.getFlatInteriorPoints().slice(),"XYM")}getOrientedFlatCoordinates(){if(this.orientedRevision_!=this.getRevision()){const t=this.flatCoordinates;(0,f.mb)(t,0,this.endss_,this.stride)?this.orientedFlatCoordinates_=t:(this.orientedFlatCoordinates_=t.slice(),this.orientedFlatCoordinates_.length=(0,f.NK)(this.orientedFlatCoordinates_,0,this.endss_,this.stride)),this.orientedRevision_=this.getRevision()}return this.orientedFlatCoordinates_}getSimplifiedGeometryInternal(t){const e=[],r=[];return e.length=(0,y.sx)(this.flatCoordinates,0,this.endss_,this.stride,Math.sqrt(t),e,0,r),new v(e,"XY",r)}getPolygon(t){if(t<0||this.endss_.length<=t)return null;let e;if(0===t)e=0;else{const r=this.endss_[t-1];e=r[r.length-1]}const r=this.endss_[t].slice(),n=r[r.length-1];if(0!==e)for(let t=0,n=r.length;t<n;++t)r[t]-=e;return new i.Ay(this.flatCoordinates.slice(e,n),this.layout,r)}getPolygons(){const t=this.layout,e=this.flatCoordinates,r=this.endss_,n=[];let s=0;for(let o=0,a=r.length;o<a;++o){const a=r[o].slice(),l=a[a.length-1];if(0!==s)for(let t=0,e=a.length;t<e;++t)a[t]-=s;const c=new i.Ay(e.slice(s,l),t,a);n.push(c),s=l}return n}getType(){return"MultiPolygon"}intersectsExtent(t){return(0,d.Wp)(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t)}setCoordinates(t,e){this.setLayout(e,t,3),this.flatCoordinates||(this.flatCoordinates=[]);const r=(0,l.d6)(this.flatCoordinates,0,t,this.stride,this.endss_);if(0===r.length)this.flatCoordinates.length=0;else{const t=r[r.length-1];this.flatCoordinates.length=0===t.length?0:t[t.length-1]}this.changed()}}const _=v},20696:(t,e,r)=>{"use strict";r.d(e,{A:()=>l});var n=r(31886),i=r(44509),s=r(28851),o=r(72475);class a extends n.Ay{constructor(t,e){super(),this.setCoordinates(t,e)}clone(){const t=new a(this.flatCoordinates.slice(),this.layout);return t.applyProperties(this),t}closestPointXY(t,e,r,n){const i=this.flatCoordinates,s=(0,o.hG)(t,e,i[0],i[1]);if(s<n){const t=this.stride;for(let e=0;e<t;++e)r[e]=i[e];return r.length=t,s}return n}getCoordinates(){return this.flatCoordinates.slice()}computeExtent(t){return(0,i.dP)(this.flatCoordinates,t)}getType(){return"Point"}intersectsExtent(t){return(0,i.Rj)(t,this.flatCoordinates[0],this.flatCoordinates[1])}setCoordinates(t,e){this.setLayout(e,t,0),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=(0,s._n)(this.flatCoordinates,0,t,this.stride),this.changed()}}const l=a},68609:(t,e,r)=>{"use strict";r.d(e,{Ay:()=>_,VY:()=>b});var n=r(31886),i=r(28519),s=r(44509),o=r(28851),a=r(9761),l=r(35455),c=r(45999);class u extends n.Ay{constructor(t,e){super(),this.maxDelta_=-1,this.maxDeltaRevision_=-1,void 0===e||Array.isArray(t[0])?this.setCoordinates(t,e):this.setFlatCoordinates(e,t)}clone(){return new u(this.flatCoordinates.slice(),this.layout)}closestPointXY(t,e,r,n){return n<(0,s.Ld)(this.getExtent(),t,e)?n:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt((0,i.MD)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),(0,i.n)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,this.maxDelta_,!0,t,e,r,n))}getArea(){return(0,c.eN)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getCoordinates(){return(0,l.n2)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getSimplifiedGeometryInternal(t){const e=[];return e.length=(0,a.P4)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,e,0),new u(e,"XY")}getType(){return"LinearRing"}intersectsExtent(t){return!1}setCoordinates(t,e){this.setLayout(e,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=(0,o.z2)(this.flatCoordinates,0,t,this.stride),this.changed()}}const h=u;var d=r(20696),f=r(30444),p=r(93350),m=r(78096),g=r(65709),y=r(16587);class v extends n.Ay{constructor(t,e,r){super(),this.ends_=[],this.flatInteriorPointRevision_=-1,this.flatInteriorPoint_=null,this.maxDelta_=-1,this.maxDeltaRevision_=-1,this.orientedRevision_=-1,this.orientedFlatCoordinates_=null,void 0!==e&&r?(this.setFlatCoordinates(e,t),this.ends_=r):this.setCoordinates(t,e)}appendLinearRing(t){this.flatCoordinates?(0,f.X$)(this.flatCoordinates,t.getFlatCoordinates()):this.flatCoordinates=t.getFlatCoordinates().slice(),this.ends_.push(this.flatCoordinates.length),this.changed()}clone(){const t=new v(this.flatCoordinates.slice(),this.layout,this.ends_.slice());return t.applyProperties(this),t}closestPointXY(t,e,r,n){return n<(0,s.Ld)(this.getExtent(),t,e)?n:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt((0,i.HX)(this.flatCoordinates,0,this.ends_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),(0,i.oW)(this.flatCoordinates,0,this.ends_,this.stride,this.maxDelta_,!0,t,e,r,n))}containsXY(t,e){return(0,y.zb)(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t,e)}getArea(){return(0,c.PK)(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride)}getCoordinates(t){let e;return void 0!==t?(e=this.getOrientedFlatCoordinates().slice(),(0,g.ug)(e,0,this.ends_,this.stride,t)):e=this.flatCoordinates,(0,l.cD)(e,0,this.ends_,this.stride)}getEnds(){return this.ends_}getFlatInteriorPoint(){if(this.flatInteriorPointRevision_!=this.getRevision()){const t=(0,s.q1)(this.getExtent());this.flatInteriorPoint_=(0,p.J)(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t,0),this.flatInteriorPointRevision_=this.getRevision()}return this.flatInteriorPoint_}getInteriorPoint(){return new d.A(this.getFlatInteriorPoint(),"XYM")}getLinearRingCount(){return this.ends_.length}getLinearRing(t){return t<0||this.ends_.length<=t?null:new h(this.flatCoordinates.slice(0===t?0:this.ends_[t-1],this.ends_[t]),this.layout)}getLinearRings(){const t=this.layout,e=this.flatCoordinates,r=this.ends_,n=[];let i=0;for(let s=0,o=r.length;s<o;++s){const o=r[s],a=new h(e.slice(i,o),t);n.push(a),i=o}return n}getOrientedFlatCoordinates(){if(this.orientedRevision_!=this.getRevision()){const t=this.flatCoordinates;(0,g.PA)(t,0,this.ends_,this.stride)?this.orientedFlatCoordinates_=t:(this.orientedFlatCoordinates_=t.slice(),this.orientedFlatCoordinates_.length=(0,g.ug)(this.orientedFlatCoordinates_,0,this.ends_,this.stride)),this.orientedRevision_=this.getRevision()}return this.orientedFlatCoordinates_}getSimplifiedGeometryInternal(t){const e=[],r=[];return e.length=(0,a.Hg)(this.flatCoordinates,0,this.ends_,this.stride,Math.sqrt(t),e,0,r),new v(e,"XY",r)}getType(){return"Polygon"}intersectsExtent(t){return(0,m.HT)(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t)}setCoordinates(t,e){this.setLayout(e,t,2),this.flatCoordinates||(this.flatCoordinates=[]);const r=(0,o.KG)(this.flatCoordinates,0,t,this.stride,this.ends_);this.flatCoordinates.length=0===r.length?0:r[r.length-1],this.changed()}}const _=v;function b(t){if((0,s.Im)(t))throw new Error("Cannot create polygon from empty extent");const e=t[0],r=t[1],n=t[2],i=t[3],o=[e,r,e,i,n,i,n,r,e,r];return new v(o,"XY",[o.length])}},31886:(t,e,r)=>{"use strict";r.d(e,{Ay:()=>h,p0:()=>l,v7:()=>u});var n=r(96488),i=r(98629),s=r(44509),o=r(70772);class a extends n.A{constructor(){super(),this.layout="XY",this.stride=2,this.flatCoordinates}computeExtent(t){return(0,s.Vy)(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)}getCoordinates(){return(0,i.b0)()}getFirstCoordinate(){return this.flatCoordinates.slice(0,this.stride)}getFlatCoordinates(){return this.flatCoordinates}getLastCoordinate(){return this.flatCoordinates.slice(this.flatCoordinates.length-this.stride)}getLayout(){return this.layout}getSimplifiedGeometry(t){if(this.simplifiedGeometryRevision!==this.getRevision()&&(this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=this.getRevision()),t<0||0!==this.simplifiedGeometryMaxMinSquaredTolerance&&t<=this.simplifiedGeometryMaxMinSquaredTolerance)return this;const e=this.getSimplifiedGeometryInternal(t);return e.getFlatCoordinates().length<this.flatCoordinates.length?e:(this.simplifiedGeometryMaxMinSquaredTolerance=t,this)}getSimplifiedGeometryInternal(t){return this}getStride(){return this.stride}setFlatCoordinates(t,e){this.stride=c(t),this.layout=t,this.flatCoordinates=e}setCoordinates(t,e){(0,i.b0)()}setLayout(t,e,r){let n;if(t)n=c(t);else{for(let t=0;t<r;++t){if(0===e.length)return this.layout="XY",void(this.stride=2);e=e[0]}n=e.length,t=l(n)}this.layout=t,this.stride=n}applyTransform(t){this.flatCoordinates&&(t(this.flatCoordinates,this.flatCoordinates,this.layout.startsWith("XYZ")?3:2,this.stride),this.changed())}rotate(t,e){const r=this.getFlatCoordinates();if(r){const n=this.getStride();(0,o.e$)(r,0,r.length,n,t,e,r),this.changed()}}scale(t,e,r){void 0===e&&(e=t),r||(r=(0,s.q1)(this.getExtent()));const n=this.getFlatCoordinates();if(n){const i=this.getStride();(0,o.hs)(n,0,n.length,i,t,e,r,n),this.changed()}}translate(t,e){const r=this.getFlatCoordinates();if(r){const n=this.getStride();(0,o.Tl)(r,0,r.length,n,t,e,r),this.changed()}}}function l(t){let e;return 2==t?e="XY":3==t?e="XYZ":4==t&&(e="XYZM"),e}function c(t){let e;return"XY"==t?e=2:"XYZ"==t||"XYM"==t?e=3:"XYZM"==t&&(e=4),e}function u(t,e,r){const n=t.getFlatCoordinates();if(!n)return null;const i=t.getStride();return(0,o.Rc)(n,0,n.length,i,e,r)}const h=a},45999:(t,e,r)=>{"use strict";function n(t,e,r,n){let i=0;const s=t[r-n],o=t[r-n+1];let a=0,l=0;for(;e<r;e+=n){const r=t[e]-s,n=t[e+1]-o;i+=l*r-a*n,a=r,l=n}return i/2}function i(t,e,r,i){let s=0;for(let o=0,a=r.length;o<a;++o){const a=r[o];s+=n(t,e,a,i),e=a}return s}function s(t,e,r,n){let s=0;for(let o=0,a=r.length;o<a;++o){const a=r[o];s+=i(t,e,a,n),e=a[a.length-1]}return s}r.d(e,{Cs:()=>s,PK:()=>i,eN:()=>n})},77055:(t,e,r)=>{"use strict";r.d(e,{C:()=>i});var n=r(44509);function i(t,e,r,i){const s=[];let o=(0,n.S5)();for(let a=0,l=r.length;a<l;++a){const l=r[a];o=(0,n.Vy)(t,e,l[0],i),s.push((o[0]+o[2])/2,(o[1]+o[3])/2),e=l[l.length-1]}return s}},28519:(t,e,r)=>{"use strict";r.d(e,{HX:()=>o,MD:()=>s,c:()=>a,n:()=>l,oW:()=>c,te:()=>u});var n=r(72475);function i(t,e,r,i,s,o,a){const l=t[e],c=t[e+1],u=t[r]-l,h=t[r+1]-c;let d;if(0===u&&0===h)d=e;else{const f=((s-l)*u+(o-c)*h)/(u*u+h*h);if(f>1)d=r;else{if(f>0){for(let s=0;s<i;++s)a[s]=(0,n.Cc)(t[e+s],t[r+s],f);return void(a.length=i)}d=e}}for(let e=0;e<i;++e)a[e]=t[d+e];a.length=i}function s(t,e,r,i,s){let o=t[e],a=t[e+1];for(e+=i;e<r;e+=i){const r=t[e],i=t[e+1],l=(0,n.hG)(o,a,r,i);l>s&&(s=l),o=r,a=i}return s}function o(t,e,r,n,i){for(let o=0,a=r.length;o<a;++o){const a=r[o];i=s(t,e,a,n,i),e=a}return i}function a(t,e,r,n,i){for(let s=0,a=r.length;s<a;++s){const a=r[s];i=o(t,e,a,n,i),e=a[a.length-1]}return i}function l(t,e,r,s,o,a,l,c,u,h,d){if(e==r)return h;let f,p;if(0===o){if(p=(0,n.hG)(l,c,t[e],t[e+1]),p<h){for(f=0;f<s;++f)u[f]=t[e+f];return u.length=s,p}return h}d=d||[NaN,NaN];let m=e+s;for(;m<r;)if(i(t,m-s,m,s,l,c,d),p=(0,n.hG)(l,c,d[0],d[1]),p<h){for(h=p,f=0;f<s;++f)u[f]=d[f];u.length=s,m+=s}else m+=s*Math.max((Math.sqrt(p)-Math.sqrt(h))/o|0,1);if(a&&(i(t,r-s,e,s,l,c,d),p=(0,n.hG)(l,c,d[0],d[1]),p<h)){for(h=p,f=0;f<s;++f)u[f]=d[f];u.length=s}return h}function c(t,e,r,n,i,s,o,a,c,u,h){h=h||[NaN,NaN];for(let d=0,f=r.length;d<f;++d){const f=r[d];u=l(t,e,f,n,i,s,o,a,c,u,h),e=f}return u}function u(t,e,r,n,i,s,o,a,l,u,h){h=h||[NaN,NaN];for(let d=0,f=r.length;d<f;++d){const f=r[d];u=c(t,e,f,n,i,s,o,a,l,u,h),e=f[f.length-1]}return u}},16587:(t,e,r)=>{"use strict";r.d(e,{Gd:()=>a,a_:()=>s,t7:()=>i,zb:()=>o});var n=r(44509);function i(t,e,r,i,o){return!(0,n.sB)(o,(function(n){return!s(t,e,r,i,n[0],n[1])}))}function s(t,e,r,n,i,s){let o=0,a=t[r-n],l=t[r-n+1];for(;e<r;e+=n){const r=t[e],n=t[e+1];l<=s?n>s&&(r-a)*(s-l)-(i-a)*(n-l)>0&&o++:n<=s&&(r-a)*(s-l)-(i-a)*(n-l)<0&&o--,a=r,l=n}return 0!==o}function o(t,e,r,n,i,o){if(0===r.length)return!1;if(!s(t,e,r[0],n,i,o))return!1;for(let e=1,a=r.length;e<a;++e)if(s(t,r[e-1],r[e],n,i,o))return!1;return!0}function a(t,e,r,n,i,s){if(0===r.length)return!1;for(let a=0,l=r.length;a<l;++a){const l=r[a];if(o(t,e,l,n,i,s))return!0;e=l[l.length-1]}return!1}},28851:(t,e,r)=>{"use strict";function n(t,e,r,n){for(let n=0,i=r.length;n<i;++n)t[e++]=r[n];return e}function i(t,e,r,n){for(let i=0,s=r.length;i<s;++i){const s=r[i];for(let r=0;r<n;++r)t[e++]=s[r]}return e}function s(t,e,r,n,s){s=s||[];let o=0;for(let a=0,l=r.length;a<l;++a){const l=i(t,e,r[a],n);s[o++]=l,e=l}return s.length=o,s}function o(t,e,r,n,i){i=i||[];let o=0;for(let a=0,l=r.length;a<l;++a){const l=s(t,e,r[a],n,i[o]);0===l.length&&(l[0]=e),i[o++]=l,e=l[l.length-1]}return i.length=o,i}r.d(e,{KG:()=>s,_n:()=>n,d6:()=>o,z2:()=>i})},35455:(t,e,r)=>{"use strict";function n(t,e,r,n,i){i=void 0!==i?i:[];let s=0;for(let o=e;o<r;o+=n)i[s++]=t.slice(o,o+n);return i.length=s,i}function i(t,e,r,i,s){s=void 0!==s?s:[];let o=0;for(let a=0,l=r.length;a<l;++a){const l=r[a];s[o++]=n(t,e,l,i,s[o]),e=l}return s.length=o,s}function s(t,e,r,n,s){s=void 0!==s?s:[];let o=0;for(let a=0,l=r.length;a<l;++a){const l=r[a];s[o++]=1===l.length&&l[0]===e?[]:i(t,e,l,n,s[o]),e=l[l.length-1]}return s.length=o,s}r.d(e,{Dz:()=>s,cD:()=>i,n2:()=>n})},93350:(t,e,r)=>{"use strict";r.d(e,{J:()=>s,p:()=>o});var n=r(30444),i=r(16587);function s(t,e,r,s,o,a,l){let c,u,h,d,f,p,m;const g=o[a+1],y=[];for(let n=0,i=r.length;n<i;++n){const i=r[n];for(d=t[i-s],p=t[i-s+1],c=e;c<i;c+=s)f=t[c],m=t[c+1],(g<=p&&m<=g||p<=g&&g<=m)&&(h=(g-p)/(m-p)*(f-d)+d,y.push(h)),d=f,p=m}let v=NaN,_=-1/0;for(y.sort(n.V_),d=y[0],c=1,u=y.length;c<u;++c){f=y[c];const n=Math.abs(f-d);n>_&&(h=(d+f)/2,(0,i.zb)(t,e,r,s,h,g)&&(v=h,_=n)),d=f}return isNaN(v)&&(v=o[a]),l?(l.push(v,g,_),l):[v,g,_]}function o(t,e,r,n,i){let o=[];for(let a=0,l=r.length;a<l;++a){const l=r[a];o=s(t,e,l,n,i,2*a,o),e=l[l.length-1]}return o}},82611:(t,e,r)=>{"use strict";r.d(e,{L8:()=>a,SH:()=>s,gr:()=>o});var n=r(30444),i=r(72475);function s(t,e,r,s,o,a,l){let c,u;const h=(r-e)/s;if(1===h)c=e;else if(2===h)c=e,u=o;else if(0!==h){let i=t[e],a=t[e+1],l=0;const h=[0];for(let n=e+s;n<r;n+=s){const e=t[n],r=t[n+1];l+=Math.sqrt((e-i)*(e-i)+(r-a)*(r-a)),h.push(l),i=e,a=r}const d=o*l,f=(0,n.El)(h,d);f<0?(u=(d-h[-f-2])/(h[-f-1]-h[-f-2]),c=e+(-f-2)*s):c=e+f*s}l=l>1?l:2,a=a||new Array(l);for(let e=0;e<l;++e)a[e]=void 0===c?NaN:void 0===u?t[c+e]:(0,i.Cc)(t[c+e],t[c+s+e],u);return a}function o(t,e,r,n,s,o){if(r==e)return null;let a;if(s<t[e+n-1])return o?(a=t.slice(e,e+n),a[n-1]=s,a):null;if(t[r-1]<s)return o?(a=t.slice(r-n,r),a[n-1]=s,a):null;if(s==t[e+n-1])return t.slice(e,e+n);let l=e/n,c=r/n;for(;l<c;){const e=l+c>>1;s<t[(e+1)*n-1]?c=e:l=e+1}const u=t[l*n-1];if(s==u)return t.slice((l-1)*n,(l-1)*n+n);const h=(s-u)/(t[(l+1)*n-1]-u);a=[];for(let e=0;e<n-1;++e)a.push((0,i.Cc)(t[(l-1)*n+e],t[l*n+e],h));return a.push(s),a}function a(t,e,r,n,i,s,a){if(a)return o(t,e,r[r.length-1],n,i,s);let l;if(i<t[n-1])return s?(l=t.slice(0,n),l[n-1]=i,l):null;if(t[t.length-1]<i)return s?(l=t.slice(t.length-n),l[n-1]=i,l):null;for(let s=0,a=r.length;s<a;++s){const a=r[s];if(e!=a){if(i<t[e+n-1])return null;if(i<=t[a-1])return o(t,e,a,n,i,!1);e=a}}return null}},78096:(t,e,r)=>{"use strict";r.d(e,{HT:()=>c,Wp:()=>u,fB:()=>a,gp:()=>o,sj:()=>l});var n=r(44509),i=r(35024),s=r(16587);function o(t,e,r,s,o){const a=(0,n.R8)((0,n.S5)(),t,e,r,s);return!!(0,n.HY)(o,a)&&(!!(0,n.ms)(o,a)||a[0]>=o[0]&&a[2]<=o[2]||a[1]>=o[1]&&a[3]<=o[3]||(0,i.j)(t,e,r,s,(function(t,e){return(0,n.Mx)(o,t,e)})))}function a(t,e,r,n,i){for(let s=0,a=r.length;s<a;++s){if(o(t,e,r[s],n,i))return!0;e=r[s]}return!1}function l(t,e,r,n,i){return!!(o(t,e,r,n,i)||(0,s.a_)(t,e,r,n,i[0],i[1])||(0,s.a_)(t,e,r,n,i[0],i[3])||(0,s.a_)(t,e,r,n,i[2],i[1])||(0,s.a_)(t,e,r,n,i[2],i[3]))}function c(t,e,r,n,i){if(!l(t,e,r[0],n,i))return!1;if(1===r.length)return!0;for(let e=1,a=r.length;e<a;++e)if((0,s.t7)(t,r[e-1],r[e],n,i)&&!o(t,r[e-1],r[e],n,i))return!1;return!0}function u(t,e,r,n,i){for(let s=0,o=r.length;s<o;++s){const o=r[s];if(c(t,e,o,n,i))return!0;e=o[o.length-1]}return!1}},22346:(t,e,r)=>{"use strict";function n(t,e,r,n){let i=t[e],s=t[e+1],o=0;for(let a=e+n;a<r;a+=n){const e=t[a],r=t[a+1];o+=Math.sqrt((e-i)*(e-i)+(r-s)*(r-s)),i=e,s=r}return o}r.d(e,{k:()=>n})},65709:(t,e,r)=>{"use strict";function n(t,e,r,n){for(;e<r-n;){for(let i=0;i<n;++i){const s=t[e+i];t[e+i]=t[r-n+i],t[r-n+i]=s}e+=n,r-=n}}function i(t,e,r,n){let i=0,s=t[r-n],o=t[r-n+1];for(;e<r;e+=n){const r=t[e],n=t[e+1];i+=(r-s)*(n+o),s=r,o=n}return 0===i?void 0:i>0}function s(t,e,r,n,s){s=void 0!==s&&s;for(let o=0,a=r.length;o<a;++o){const a=r[o],l=i(t,e,a,n);if(0===o){if(s&&l||!s&&!l)return!1}else if(s&&!l||!s&&l)return!1;e=a}return!0}function o(t,e,r,n,i){for(let o=0,a=r.length;o<a;++o){const a=r[o];if(!s(t,e,a,n,i))return!1;a.length&&(e=a[a.length-1])}return!0}function a(t,e,r,s,o){o=void 0!==o&&o;for(let a=0,l=r.length;a<l;++a){const l=r[a],c=i(t,e,l,s);(0===a?o&&c||!o&&!c:o&&!c||!o&&c)&&n(t,e,l,s),e=l}return e}function l(t,e,r,n,i){for(let s=0,o=r.length;s<o;++s)e=a(t,e,r[s],n,i);return e}function c(t,e){const r=[];let n,s=0,o=0;for(let a=0,l=e.length;a<l;++a){const l=e[a],c=i(t,s,l,2);if(void 0===n&&(n=c),c===n)r.push(e.slice(o,a+1));else{if(0===r.length)continue;r[r.length-1].push(e[o])}o=a+1,s=l}return r}r.d(e,{yJ:()=>c,PA:()=>s,mb:()=>o,ug:()=>a,NK:()=>l})},35024:(t,e,r)=>{"use strict";function n(t,e,r,n,i){let s;for(e+=n;e<r;e+=n)if(s=i(t.slice(e-n,e),t.slice(e,e+n)),s)return s;return!1}r.d(e,{j:()=>n})},9761:(t,e,r)=>{"use strict";r.d(e,{AL:()=>s,Hg:()=>l,P4:()=>i,n$:()=>o,sx:()=>c});var n=r(72475);function i(t,e,r,i,s,o,a){const l=(r-e)/i;if(l<3){for(;e<r;e+=i)o[a++]=t[e],o[a++]=t[e+1];return a}const c=new Array(l);c[0]=1,c[l-1]=1;const u=[e,r-i];let h=0;for(;u.length>0;){const r=u.pop(),o=u.pop();let a=0;const l=t[o],d=t[o+1],f=t[r],p=t[r+1];for(let e=o+i;e<r;e+=i){const r=t[e],i=t[e+1],s=(0,n.Q1)(r,i,l,d,f,p);s>a&&(h=e,a=s)}a>s&&(c[(h-e)/i]=1,o+i<h&&u.push(o,h),h+i<r&&u.push(h,r))}for(let r=0;r<l;++r)c[r]&&(o[a++]=t[e+r*i],o[a++]=t[e+r*i+1]);return a}function s(t,e,r,n,s,o,a,l){for(let c=0,u=r.length;c<u;++c){const u=r[c];a=i(t,e,u,n,s,o,a),l.push(a),e=u}return a}function o(t,e){return e*Math.round(t/e)}function a(t,e,r,n,i,s,a){if(e==r)return a;let l,c,u=o(t[e],i),h=o(t[e+1],i);e+=n,s[a++]=u,s[a++]=h;do{if(l=o(t[e],i),c=o(t[e+1],i),(e+=n)==r)return s[a++]=l,s[a++]=c,a}while(l==u&&c==h);for(;e<r;){const r=o(t[e],i),d=o(t[e+1],i);if(e+=n,r==l&&d==c)continue;const f=l-u,p=c-h,m=r-u,g=d-h;f*g==p*m&&(f<0&&m<f||f==m||f>0&&m>f)&&(p<0&&g<p||p==g||p>0&&g>p)?(l=r,c=d):(s[a++]=l,s[a++]=c,u=l,h=c,l=r,c=d)}return s[a++]=l,s[a++]=c,a}function l(t,e,r,n,i,s,o,l){for(let c=0,u=r.length;c<u;++c){const u=r[c];o=a(t,e,u,n,i,s,o),l.push(o),e=u}return o}function c(t,e,r,n,i,s,o,a){for(let c=0,u=r.length;c<u;++c){const u=r[c],h=[];o=l(t,e,u,n,i,s,o,h),a.push(h),e=u[u.length-1]}return o}},70772:(t,e,r)=>{"use strict";function n(t,e,r,n,i,s,o){s=s||[],o=o||2;let a=0;for(let l=e;l<r;l+=n){const e=t[l],r=t[l+1];s[a++]=i[0]*e+i[2]*r+i[4],s[a++]=i[1]*e+i[3]*r+i[5];for(let e=2;e<o;e++)s[a++]=t[l+e]}return s&&s.length!=a&&(s.length=a),s}function i(t,e,r,n,i,s,o){o=o||[];const a=Math.cos(i),l=Math.sin(i),c=s[0],u=s[1];let h=0;for(let i=e;i<r;i+=n){const e=t[i]-c,r=t[i+1]-u;o[h++]=c+e*a-r*l,o[h++]=u+e*l+r*a;for(let e=i+2;e<i+n;++e)o[h++]=t[e]}return o&&o.length!=h&&(o.length=h),o}function s(t,e,r,n,i,s,o,a){a=a||[];const l=o[0],c=o[1];let u=0;for(let o=e;o<r;o+=n){const e=t[o]-l,r=t[o+1]-c;a[u++]=l+i*e,a[u++]=c+s*r;for(let e=o+2;e<o+n;++e)a[u++]=t[e]}return a&&a.length!=u&&(a.length=u),a}function o(t,e,r,n,i,s,o){o=o||[];let a=0;for(let l=e;l<r;l+=n){o[a++]=t[l]+i,o[a++]=t[l+1]+s;for(let e=l+2;e<l+n;++e)o[a++]=t[e]}return o&&o.length!=a&&(o.length=a),o}r.d(e,{Rc:()=>n,Tl:()=>o,e$:()=>i,hs:()=>s})},66993:(t,e,r)=>{"use strict";r.d(e,{DT:()=>u,FT:()=>d,Wl:()=>c,XM:()=>h,_p:()=>i,cr:()=>l,ew:()=>a,j:()=>o,oF:()=>s});const n="undefined"!=typeof navigator&&void 0!==navigator.userAgent?navigator.userAgent.toLowerCase():"",i=n.includes("firefox"),s=n.includes("safari")&&!n.includes("chrom")&&(n.includes("version/15.4")||/cpu (os|iphone os) 15_4 like mac os x/.test(n)),o=n.includes("webkit")&&!n.includes("edge"),a=n.includes("macintosh"),l="undefined"!=typeof devicePixelRatio?devicePixelRatio:1,c="undefined"!=typeof WorkerGlobalScope&&"undefined"!=typeof OffscreenCanvas&&self instanceof WorkerGlobalScope,u="undefined"!=typeof Image&&Image.prototype.decode,h="function"==typeof createImageBitmap,d=function(){let t=!1;try{const e=Object.defineProperty({},"passive",{get:function(){t=!0}});window.addEventListener("_",null,e),window.removeEventListener("_",null,e)}catch(t){}return t}()},88436:(t,e,r)=>{"use strict";r.d(e,{A:()=>h});var n=r(37283),i=r(24187),s=r(78083),o=r(97440),a=r(12940),l=r(94456);class c extends n.Ay{constructor(t,e,r,n){super(t),this.features=r,this.file=e,this.projection=n}}class u extends s.Ay{constructor(t){t=t||{},super({handleEvent:o.rT}),this.on,this.once,this.un,this.readAsBuffer_=!1,this.formats_=[];const e=t.formatConstructors?t.formatConstructors:[];for(let t=0,r=e.length;t<r;++t){let r=e[t];"function"==typeof r&&(r=new r),this.formats_.push(r),this.readAsBuffer_=this.readAsBuffer_||"arraybuffer"===r.getType()}this.projection_=t.projection?(0,a.Jt)(t.projection):null,this.dropListenKeys_=null,this.source_=t.source||null,this.target=t.target?t.target:null}handleResult_(t,e){const r=e.target.result,n=this.getMap();let i,s=this.projection_;s||(s=(0,a.Tf)(),s)||(s=n.getView().getProjection());const o=this.formats_;for(let e=0,n=o.length;e<n;++e){const n=o[e];let a=r;this.readAsBuffer_&&"arraybuffer"!==n.getType()&&(void 0===i&&(i=(new TextDecoder).decode(r)),a=i);const l=this.tryReadFeatures_(n,a,{featureProjection:s});if(l&&l.length>0){this.source_&&(this.source_.clear(),this.source_.addFeatures(l)),this.dispatchEvent(new c("addfeatures",t,l,s));break}}}registerListeners_(){const t=this.getMap();if(t){const e=this.target?this.target:t.getViewport();this.dropListenKeys_=[(0,l.KT)(e,i.A.DROP,this.handleDrop,this),(0,l.KT)(e,i.A.DRAGENTER,this.handleStop,this),(0,l.KT)(e,i.A.DRAGOVER,this.handleStop,this),(0,l.KT)(e,i.A.DROP,this.handleStop,this)]}}setActive(t){!this.getActive()&&t&&this.registerListeners_(),this.getActive()&&!t&&this.unregisterListeners_(),super.setActive(t)}setMap(t){this.unregisterListeners_(),super.setMap(t),this.getActive()&&this.registerListeners_()}tryReadFeatures_(t,e,r){try{return t.readFeatures(e,r)}catch(t){return null}}unregisterListeners_(){this.dropListenKeys_&&(this.dropListenKeys_.forEach(l.JH),this.dropListenKeys_=null)}handleDrop(t){const e=t.dataTransfer.files;for(let t=0,r=e.length;t<r;++t){const r=e.item(t),n=new FileReader;n.addEventListener(i.A.LOAD,this.handleResult_.bind(this,r)),this.readAsBuffer_?n.readAsArrayBuffer(r):n.readAsText(r)}}handleStop(t){t.stopPropagation(),t.preventDefault(),t.dataTransfer.dropEffect="copy"}}const h=u},78083:(t,e,r)=>{"use strict";r.d(e,{Ay:()=>c,e4:()=>a,D2:()=>l});var n=r(72614);const i="active";var s=r(2620);class o extends n.A{constructor(t){super(),this.on,this.once,this.un,t&&t.handleEvent&&(this.handleEvent=t.handleEvent),this.map_=null,this.setActive(!0)}getActive(){return this.get(i)}getMap(){return this.map_}handleEvent(t){return!0}setActive(t){this.set(i,t)}setMap(t){this.map_=t}}function a(t,e,r){const n=t.getCenterInternal();if(n){const i=[n[0]+e[0],n[1]+e[1]];t.animateInternal({duration:void 0!==r?r:250,easing:s.sn,center:t.getConstrainedCenter(i)})}}function l(t,e,r,n){const i=t.getZoom();if(void 0===i)return;const o=t.getConstrainedZoom(i+e),a=t.getResolutionForZoom(o);t.getAnimating()&&t.cancelAnimations(),t.animate({resolution:a,anchor:r,duration:void 0!==n?n:250,easing:s.vT})}const c=o},93450:(t,e,r)=>{"use strict";r.d(e,{A:()=>c});var n=r(72614),i=r(59014),s=r(98629),o=r(30878),a=r(72475);class l extends n.A{constructor(t){super(),this.on,this.once,this.un,this.background_=t.background;const e=Object.assign({},t);"object"==typeof t.properties&&(delete e.properties,Object.assign(e,t.properties)),e[i.A.OPACITY]=void 0!==t.opacity?t.opacity:1,(0,o.v)("number"==typeof e[i.A.OPACITY],"Layer opacity must be a number"),e[i.A.VISIBLE]=void 0===t.visible||t.visible,e[i.A.Z_INDEX]=t.zIndex,e[i.A.MAX_RESOLUTION]=void 0!==t.maxResolution?t.maxResolution:1/0,e[i.A.MIN_RESOLUTION]=void 0!==t.minResolution?t.minResolution:0,e[i.A.MIN_ZOOM]=void 0!==t.minZoom?t.minZoom:-1/0,e[i.A.MAX_ZOOM]=void 0!==t.maxZoom?t.maxZoom:1/0,this.className_=void 0!==e.className?e.className:"ol-layer",delete e.className,this.setProperties(e),this.state_=null}getBackground(){return this.background_}getClassName(){return this.className_}getLayerState(t){const e=this.state_||{layer:this,managed:void 0===t||t},r=this.getZIndex();return e.opacity=(0,a.qE)(Math.round(100*this.getOpacity())/100,0,1),e.visible=this.getVisible(),e.extent=this.getExtent(),e.zIndex=void 0!==r||e.managed?r:1/0,e.maxResolution=this.getMaxResolution(),e.minResolution=Math.max(this.getMinResolution(),0),e.minZoom=this.getMinZoom(),e.maxZoom=this.getMaxZoom(),this.state_=e,e}getLayersArray(t){return(0,s.b0)()}getLayerStatesArray(t){return(0,s.b0)()}getExtent(){return this.get(i.A.EXTENT)}getMaxResolution(){return this.get(i.A.MAX_RESOLUTION)}getMinResolution(){return this.get(i.A.MIN_RESOLUTION)}getMinZoom(){return this.get(i.A.MIN_ZOOM)}getMaxZoom(){return this.get(i.A.MAX_ZOOM)}getOpacity(){return this.get(i.A.OPACITY)}getSourceState(){return(0,s.b0)()}getVisible(){return this.get(i.A.VISIBLE)}getZIndex(){return this.get(i.A.Z_INDEX)}setBackground(t){this.background_=t,this.changed()}setExtent(t){this.set(i.A.EXTENT,t)}setMaxResolution(t){this.set(i.A.MAX_RESOLUTION,t)}setMinResolution(t){this.set(i.A.MIN_RESOLUTION,t)}setMaxZoom(t){this.set(i.A.MAX_ZOOM,t)}setMinZoom(t){this.set(i.A.MIN_ZOOM,t)}setOpacity(t){(0,o.v)("number"==typeof t,"Layer opacity must be a number"),this.set(i.A.OPACITY,t)}setVisible(t){this.set(i.A.VISIBLE,t)}setZIndex(t){this.set(i.A.Z_INDEX,t)}disposeInternal(){this.state_&&(this.state_.layer=null,this.state_=null),super.disposeInternal()}}const c=l},91430:(t,e,r)=>{"use strict";r.d(e,{A:()=>o});var n=r(73626),i=r(56106);class s extends n.A{constructor(t){t=t||{};const e=Object.assign({},t),r=t.cacheSize;delete t.cacheSize,delete e.preload,delete e.useInterimTilesOnError,super(e),this.on,this.once,this.un,this.cacheSize_=r,this.setPreload(void 0!==t.preload?t.preload:0),this.setUseInterimTilesOnError(void 0===t.useInterimTilesOnError||t.useInterimTilesOnError)}getCacheSize(){return this.cacheSize_}getPreload(){return this.get(i.A.PRELOAD)}setPreload(t){this.set(i.A.PRELOAD,t)}getUseInterimTilesOnError(){return this.get(i.A.USE_INTERIM_TILES_ON_ERROR)}setUseInterimTilesOnError(t){this.set(i.A.USE_INTERIM_TILES_ON_ERROR,t)}getData(t){return super.getData(t)}}const o=s},69199:(t,e,r)=>{"use strict";r.d(e,{A:()=>at});var n=r(73626),i=r(44663),s=r(39915),o=r(51386),a=r(41009),l=r(67029),c=r(83085),u=r(33976);class h extends o.A{constructor(t){super({opacity:1,rotateWithView:void 0!==t.rotateWithView&&t.rotateWithView,rotation:void 0!==t.rotation?t.rotation:0,scale:void 0!==t.scale?t.scale:1,displacement:void 0!==t.displacement?t.displacement:[0,0],declutterMode:t.declutterMode}),this.canvases_,this.hitDetectionCanvas_=null,this.fill_=void 0!==t.fill?t.fill:null,this.origin_=[0,0],this.points_=t.points,this.radius=t.radius,this.radius2_=t.radius2,this.angle_=void 0!==t.angle?t.angle:0,this.stroke_=void 0!==t.stroke?t.stroke:null,this.size_,this.renderOptions_,this.imageState_=this.fill_&&this.fill_.loading()?s.A.LOADING:s.A.LOADED,this.imageState_===s.A.LOADING&&this.ready().then((()=>this.imageState_=s.A.LOADED)),this.render()}clone(){const t=this.getScale(),e=new h({fill:this.getFill()?this.getFill().clone():void 0,points:this.getPoints(),radius:this.getRadius(),radius2:this.getRadius2(),angle:this.getAngle(),stroke:this.getStroke()?this.getStroke().clone():void 0,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),scale:Array.isArray(t)?t.slice():t,displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()});return e.setOpacity(this.getOpacity()),e}getAnchor(){const t=this.size_,e=this.getDisplacement(),r=this.getScaleArray();return[t[0]/2-e[0]/r[0],t[1]/2+e[1]/r[1]]}getAngle(){return this.angle_}getFill(){return this.fill_}setFill(t){this.fill_=t,this.render()}getHitDetectionImage(){return this.hitDetectionCanvas_||(this.hitDetectionCanvas_=this.createHitDetectionCanvas_(this.renderOptions_)),this.hitDetectionCanvas_}getImage(t){let e=this.canvases_[t];if(!e){const r=this.renderOptions_,n=(0,c.Y)(r.size*t,r.size*t);this.draw_(r,n,t),e=n.canvas,this.canvases_[t]=e}return e}getPixelRatio(t){return t}getImageSize(){return this.size_}getImageState(){return this.imageState_}getOrigin(){return this.origin_}getPoints(){return this.points_}getRadius(){return this.radius}getRadius2(){return this.radius2_}getSize(){return this.size_}getStroke(){return this.stroke_}setStroke(t){this.stroke_=t,this.render()}listenImageChange(t){}load(){}unlistenImageChange(t){}calculateLineJoinSize_(t,e,r){if(0===e||this.points_===1/0||"bevel"!==t&&"miter"!==t)return e;let n=this.radius,i=void 0===this.radius2_?n:this.radius2_;if(n<i){const t=n;n=i,i=t}const s=void 0===this.radius2_?this.points_:2*this.points_,o=2*Math.PI/s,a=i*Math.sin(o),l=n-Math.sqrt(i*i-a*a),c=Math.sqrt(a*a+l*l),u=c/a;if("miter"===t&&u<=r)return u*e;const h=e/2/u,d=e/2*(l/c),f=Math.sqrt((n+h)*(n+h)+d*d)-n;if(void 0===this.radius2_||"bevel"===t)return 2*f;const p=n*Math.sin(o),m=i-Math.sqrt(n*n-p*p),g=Math.sqrt(p*p+m*m)/p;if(g<=r){const t=g*e/2-i-n;return 2*Math.max(f,t)}return 2*f}createRenderOptions(){let t,e=u._m,r=u._K,n=0,i=null,s=0,o=0;this.stroke_&&(t=(0,l.F)(this.stroke_.getColor()??u.NT),o=this.stroke_.getWidth()??u.aq,i=this.stroke_.getLineDash(),s=this.stroke_.getLineDashOffset()??0,r=this.stroke_.getLineJoin()??u._K,e=this.stroke_.getLineCap()??u._m,n=this.stroke_.getMiterLimit()??u.eL);const a=this.calculateLineJoinSize_(r,o,n),c=Math.max(this.radius,this.radius2_||0);return{strokeStyle:t,strokeWidth:o,size:Math.ceil(2*c+a),lineCap:e,lineDash:i,lineDashOffset:s,lineJoin:r,miterLimit:n}}render(){this.renderOptions_=this.createRenderOptions();const t=this.renderOptions_.size;this.canvases_={},this.hitDetectionCanvas_=null,this.size_=[t,t]}draw_(t,e,r){if(e.scale(r,r),e.translate(t.size/2,t.size/2),this.createPath_(e),this.fill_){let t=this.fill_.getColor();null===t&&(t=u.qY),e.fillStyle=(0,l.F)(t),e.fill()}t.strokeStyle&&(e.strokeStyle=t.strokeStyle,e.lineWidth=t.strokeWidth,t.lineDash&&(e.setLineDash(t.lineDash),e.lineDashOffset=t.lineDashOffset),e.lineCap=t.lineCap,e.lineJoin=t.lineJoin,e.miterLimit=t.miterLimit,e.stroke())}createHitDetectionCanvas_(t){let e;if(this.fill_){let r=this.fill_.getColor(),n=0;"string"==typeof r&&(r=(0,a._j)(r)),null===r?n=1:Array.isArray(r)&&(n=4===r.length?r[3]:1),0===n&&(e=(0,c.Y)(t.size,t.size),this.drawHitDetectionCanvas_(t,e))}return e?e.canvas:this.getImage(1)}createPath_(t){let e=this.points_;const r=this.radius;if(e===1/0)t.arc(0,0,r,0,2*Math.PI);else{const n=void 0===this.radius2_?r:this.radius2_;void 0!==this.radius2_&&(e*=2);const i=this.angle_-Math.PI/2,s=2*Math.PI/e;for(let o=0;o<e;o++){const e=i+o*s,a=o%2==0?r:n;t.lineTo(a*Math.cos(e),a*Math.sin(e))}t.closePath()}}drawHitDetectionCanvas_(t,e){e.translate(t.size/2,t.size/2),this.createPath_(e),e.fillStyle=u.qY,e.fill(),t.strokeStyle&&(e.strokeStyle=t.strokeStyle,e.lineWidth=t.strokeWidth,t.lineDash&&(e.setLineDash(t.lineDash),e.lineDashOffset=t.lineDashOffset),e.lineJoin=t.lineJoin,e.miterLimit=t.miterLimit,e.stroke())}ready(){return this.fill_?this.fill_.ready():Promise.resolve()}}const d=h;class f extends d{constructor(t){super({points:1/0,fill:(t=t||{radius:5}).fill,radius:t.radius,stroke:t.stroke,scale:void 0!==t.scale?t.scale:1,rotation:void 0!==t.rotation?t.rotation:0,rotateWithView:void 0!==t.rotateWithView&&t.rotateWithView,displacement:void 0!==t.displacement?t.displacement:[0,0],declutterMode:t.declutterMode})}clone(){const t=this.getScale(),e=new f({fill:this.getFill()?this.getFill().clone():void 0,stroke:this.getStroke()?this.getStroke().clone():void 0,radius:this.getRadius(),scale:Array.isArray(t)?t.slice():t,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()});return e.setOpacity(this.getOpacity()),e}setRadius(t){this.radius=t,this.render()}}const p=f;var m=r(98525);class g{constructor(t){t=t||{},this.patternImage_=null,this.color_=null,void 0!==t.color&&this.setColor(t.color)}clone(){const t=this.getColor();return new g({color:Array.isArray(t)?t.slice():t||void 0})}getColor(){return this.color_}setColor(t){if(null!==t&&"object"==typeof t&&"src"in t){const e=(0,m.J)(null,t.src,"anonymous",void 0,t.offset?null:t.color?t.color:null,!(t.offset&&t.size));e.ready().then((()=>{this.patternImage_=null})),e.getImageState()===s.A.IDLE&&e.load(),e.getImageState()===s.A.LOADING&&(this.patternImage_=e)}this.color_=t}loading(){return!!this.patternImage_}ready(){return this.patternImage_?this.patternImage_.ready():Promise.resolve()}}const y=g;class v{constructor(t){t=t||{},this.color_=void 0!==t.color?t.color:null,this.lineCap_=t.lineCap,this.lineDash_=void 0!==t.lineDash?t.lineDash:null,this.lineDashOffset_=t.lineDashOffset,this.lineJoin_=t.lineJoin,this.miterLimit_=t.miterLimit,this.width_=t.width}clone(){const t=this.getColor();return new v({color:Array.isArray(t)?t.slice():t||void 0,lineCap:this.getLineCap(),lineDash:this.getLineDash()?this.getLineDash().slice():void 0,lineDashOffset:this.getLineDashOffset(),lineJoin:this.getLineJoin(),miterLimit:this.getMiterLimit(),width:this.getWidth()})}getColor(){return this.color_}getLineCap(){return this.lineCap_}getLineDash(){return this.lineDash_}getLineDashOffset(){return this.lineDashOffset_}getLineJoin(){return this.lineJoin_}getMiterLimit(){return this.miterLimit_}getWidth(){return this.width_}setColor(t){this.color_=t}setLineCap(t){this.lineCap_=t}setLineDash(t){this.lineDash_=t}setLineDashOffset(t){this.lineDashOffset_=t}setLineJoin(t){this.lineJoin_=t}setMiterLimit(t){this.miterLimit_=t}setWidth(t){this.width_=t}}const _=v;var b=r(30878);class w{constructor(t){t=t||{},this.geometry_=null,this.geometryFunction_=S,void 0!==t.geometry&&this.setGeometry(t.geometry),this.fill_=void 0!==t.fill?t.fill:null,this.image_=void 0!==t.image?t.image:null,this.renderer_=void 0!==t.renderer?t.renderer:null,this.hitDetectionRenderer_=void 0!==t.hitDetectionRenderer?t.hitDetectionRenderer:null,this.stroke_=void 0!==t.stroke?t.stroke:null,this.text_=void 0!==t.text?t.text:null,this.zIndex_=t.zIndex}clone(){let t=this.getGeometry();return t&&"object"==typeof t&&(t=t.clone()),new w({geometry:t??void 0,fill:this.getFill()?this.getFill().clone():void 0,image:this.getImage()?this.getImage().clone():void 0,renderer:this.getRenderer()??void 0,stroke:this.getStroke()?this.getStroke().clone():void 0,text:this.getText()?this.getText().clone():void 0,zIndex:this.getZIndex()})}getRenderer(){return this.renderer_}setRenderer(t){this.renderer_=t}setHitDetectionRenderer(t){this.hitDetectionRenderer_=t}getHitDetectionRenderer(){return this.hitDetectionRenderer_}getGeometry(){return this.geometry_}getGeometryFunction(){return this.geometryFunction_}getFill(){return this.fill_}setFill(t){this.fill_=t}getImage(){return this.image_}setImage(t){this.image_=t}getStroke(){return this.stroke_}setStroke(t){this.stroke_=t}getText(){return this.text_}setText(t){this.text_=t}getZIndex(){return this.zIndex_}setGeometry(t){"function"==typeof t?this.geometryFunction_=t:"string"==typeof t?this.geometryFunction_=function(e){return e.get(t)}:t?void 0!==t&&(this.geometryFunction_=function(){return t}):this.geometryFunction_=S,this.geometry_=t}setZIndex(t){this.zIndex_=t}}let x=null;function E(t,e){if(!x){const t=new y({color:"rgba(255,255,255,0.4)"}),e=new _({color:"#3399CC",width:1.25});x=[new w({image:new p({fill:t,stroke:e,radius:5}),fill:t,stroke:e})]}return x}function S(t){return t.getGeometry()}const A=w;var P=r(25174),T=r(53908);class C{constructor(t){t=t||{},this.font_=t.font,this.rotation_=t.rotation,this.rotateWithView_=t.rotateWithView,this.scale_=t.scale,this.scaleArray_=(0,T.xq)(void 0!==t.scale?t.scale:1),this.text_=t.text,this.textAlign_=t.textAlign,this.justify_=t.justify,this.repeat_=t.repeat,this.textBaseline_=t.textBaseline,this.fill_=void 0!==t.fill?t.fill:new y({color:"#333"}),this.maxAngle_=void 0!==t.maxAngle?t.maxAngle:Math.PI/4,this.placement_=void 0!==t.placement?t.placement:"point",this.overflow_=!!t.overflow,this.stroke_=void 0!==t.stroke?t.stroke:null,this.offsetX_=void 0!==t.offsetX?t.offsetX:0,this.offsetY_=void 0!==t.offsetY?t.offsetY:0,this.backgroundFill_=t.backgroundFill?t.backgroundFill:null,this.backgroundStroke_=t.backgroundStroke?t.backgroundStroke:null,this.padding_=void 0===t.padding?null:t.padding,this.declutterMode_=t.declutterMode}clone(){const t=this.getScale();return new C({font:this.getFont(),placement:this.getPlacement(),repeat:this.getRepeat(),maxAngle:this.getMaxAngle(),overflow:this.getOverflow(),rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),scale:Array.isArray(t)?t.slice():t,text:this.getText(),textAlign:this.getTextAlign(),justify:this.getJustify(),textBaseline:this.getTextBaseline(),fill:this.getFill()?this.getFill().clone():void 0,stroke:this.getStroke()?this.getStroke().clone():void 0,offsetX:this.getOffsetX(),offsetY:this.getOffsetY(),backgroundFill:this.getBackgroundFill()?this.getBackgroundFill().clone():void 0,backgroundStroke:this.getBackgroundStroke()?this.getBackgroundStroke().clone():void 0,padding:this.getPadding()||void 0,declutterMode:this.getDeclutterMode()})}getOverflow(){return this.overflow_}getFont(){return this.font_}getMaxAngle(){return this.maxAngle_}getPlacement(){return this.placement_}getRepeat(){return this.repeat_}getOffsetX(){return this.offsetX_}getOffsetY(){return this.offsetY_}getFill(){return this.fill_}getRotateWithView(){return this.rotateWithView_}getRotation(){return this.rotation_}getScale(){return this.scale_}getScaleArray(){return this.scaleArray_}getStroke(){return this.stroke_}getText(){return this.text_}getTextAlign(){return this.textAlign_}getJustify(){return this.justify_}getTextBaseline(){return this.textBaseline_}getBackgroundFill(){return this.backgroundFill_}getBackgroundStroke(){return this.backgroundStroke_}getPadding(){return this.padding_}getDeclutterMode(){return this.declutterMode_}setOverflow(t){this.overflow_=t}setFont(t){this.font_=t}setMaxAngle(t){this.maxAngle_=t}setOffsetX(t){this.offsetX_=t}setOffsetY(t){this.offsetY_=t}setPlacement(t){this.placement_=t}setRepeat(t){this.repeat_=t}setRotateWithView(t){this.rotateWithView_=t}setFill(t){this.fill_=t}setRotation(t){this.rotation_=t}setScale(t){this.scale_=t,this.scaleArray_=(0,T.xq)(void 0!==t?t:1)}setStroke(t){this.stroke_=t}setText(t){this.text_=t}setTextAlign(t){this.textAlign_=t}setJustify(t){this.justify_=t}setTextBaseline(t){this.textBaseline_=t}setBackgroundFill(t){this.backgroundFill_=t}setBackgroundStroke(t){this.backgroundStroke_=t}setPadding(t){this.padding_=t}}const M=C;var O=r(62439);function R(t,e,r){return D((0,O.qg)(t,e,r),r)}function D(t,e){if(t instanceof O._D){if(t.type===O.mE&&"string"==typeof t.value){const e=(0,a.sH)(t.value);return function(){return e}}return function(){return t.value}}const r=t.operator;switch(r){case O.ZD.Number:case O.ZD.String:case O.ZD.Coalesce:return function(t,e){const r=t.operator,n=t.args.length,i=new Array(n);for(let r=0;r<n;++r)i[r]=D(t.args[r],e);switch(r){case O.ZD.Coalesce:return t=>{for(let e=0;e<n;++e){const r=i[e](t);if(null!=r)return r}throw new Error("Expected one of the values to be non-null")};case O.ZD.Number:case O.ZD.String:return t=>{for(let e=0;e<n;++e){const n=i[e](t);if(typeof n===r)return n}throw new Error(`Expected one of the values to be a ${r}`)};default:throw new Error(`Unsupported assertion operator ${r}`)}}(t,e);case O.ZD.Get:case O.ZD.Var:case O.ZD.Has:return function(t){const e=t.args[0].value;switch(t.operator){case O.ZD.Get:return r=>{const n=t.args;let i=r.properties[e];for(let t=1,e=n.length;t<e;++t)i=i[n[t].value];return i};case O.ZD.Var:return t=>t.variables[e];case O.ZD.Has:return r=>{const n=t.args;if(!(e in r.properties))return!1;let i=r.properties[e];for(let t=1,e=n.length;t<e;++t){const e=n[t].value;if(!i||!Object.hasOwn(i,e))return!1;i=i[e]}return!0};default:throw new Error(`Unsupported accessor operator ${t.operator}`)}}(t);case O.ZD.Id:return t=>t.featureId;case O.ZD.GeometryType:return t=>t.geometryType;case O.ZD.Concat:{const r=t.args.map((t=>D(t,e)));return t=>"".concat(...r.map((e=>e(t).toString())))}case O.ZD.Resolution:return t=>t.resolution;case O.ZD.Any:case O.ZD.All:case O.ZD.Between:case O.ZD.In:case O.ZD.Not:return function(t,e){const r=t.operator,n=t.args.length,i=new Array(n);for(let r=0;r<n;++r)i[r]=D(t.args[r],e);switch(r){case O.ZD.Any:return t=>{for(let e=0;e<n;++e)if(i[e](t))return!0;return!1};case O.ZD.All:return t=>{for(let e=0;e<n;++e)if(!i[e](t))return!1;return!0};case O.ZD.Between:return t=>{const e=i[0](t),r=i[1](t),n=i[2](t);return e>=r&&e<=n};case O.ZD.In:return t=>{const e=i[0](t);for(let r=1;r<n;++r)if(e===i[r](t))return!0;return!1};case O.ZD.Not:return t=>!i[0](t);default:throw new Error(`Unsupported logical operator ${r}`)}}(t,e);case O.ZD.Equal:case O.ZD.NotEqual:case O.ZD.LessThan:case O.ZD.LessThanOrEqualTo:case O.ZD.GreaterThan:case O.ZD.GreaterThanOrEqualTo:return function(t,e){const r=t.operator,n=D(t.args[0],e),i=D(t.args[1],e);switch(r){case O.ZD.Equal:return t=>n(t)===i(t);case O.ZD.NotEqual:return t=>n(t)!==i(t);case O.ZD.LessThan:return t=>n(t)<i(t);case O.ZD.LessThanOrEqualTo:return t=>n(t)<=i(t);case O.ZD.GreaterThan:return t=>n(t)>i(t);case O.ZD.GreaterThanOrEqualTo:return t=>n(t)>=i(t);default:throw new Error(`Unsupported comparison operator ${r}`)}}(t,e);case O.ZD.Multiply:case O.ZD.Divide:case O.ZD.Add:case O.ZD.Subtract:case O.ZD.Clamp:case O.ZD.Mod:case O.ZD.Pow:case O.ZD.Abs:case O.ZD.Floor:case O.ZD.Ceil:case O.ZD.Round:case O.ZD.Sin:case O.ZD.Cos:case O.ZD.Atan:case O.ZD.Sqrt:return function(t,e){const r=t.operator,n=t.args.length,i=new Array(n);for(let r=0;r<n;++r)i[r]=D(t.args[r],e);switch(r){case O.ZD.Multiply:return t=>{let e=1;for(let r=0;r<n;++r)e*=i[r](t);return e};case O.ZD.Divide:return t=>i[0](t)/i[1](t);case O.ZD.Add:return t=>{let e=0;for(let r=0;r<n;++r)e+=i[r](t);return e};case O.ZD.Subtract:return t=>i[0](t)-i[1](t);case O.ZD.Clamp:return t=>{const e=i[0](t),r=i[1](t);if(e<r)return r;const n=i[2](t);return e>n?n:e};case O.ZD.Mod:return t=>i[0](t)%i[1](t);case O.ZD.Pow:return t=>Math.pow(i[0](t),i[1](t));case O.ZD.Abs:return t=>Math.abs(i[0](t));case O.ZD.Floor:return t=>Math.floor(i[0](t));case O.ZD.Ceil:return t=>Math.ceil(i[0](t));case O.ZD.Round:return t=>Math.round(i[0](t));case O.ZD.Sin:return t=>Math.sin(i[0](t));case O.ZD.Cos:return t=>Math.cos(i[0](t));case O.ZD.Atan:return 2===n?t=>Math.atan2(i[0](t),i[1](t)):t=>Math.atan(i[0](t));case O.ZD.Sqrt:return t=>Math.sqrt(i[0](t));default:throw new Error(`Unsupported numeric operator ${r}`)}}(t,e);case O.ZD.Case:return function(t,e){const r=t.args.length,n=new Array(r);for(let i=0;i<r;++i)n[i]=D(t.args[i],e);return t=>{for(let e=0;e<r-1;e+=2)if(n[e](t))return n[e+1](t);return n[r-1](t)}}(t,e);case O.ZD.Match:return function(t,e){const r=t.args.length,n=new Array(r);for(let i=0;i<r;++i)n[i]=D(t.args[i],e);return t=>{const e=n[0](t);for(let i=1;i<r;i+=2)if(e===n[i](t))return n[i+1](t);return n[r-1](t)}}(t,e);case O.ZD.Interpolate:return function(t,e){const r=t.args.length,n=new Array(r);for(let i=0;i<r;++i)n[i]=D(t.args[i],e);return t=>{const e=n[0](t),i=n[1](t);let s,o;for(let l=2;l<r;l+=2){const r=n[l](t);let c=n[l+1](t);const u=Array.isArray(c);if(u&&(c=(0,a.fu)(c)),r>=i)return 2===l?c:u?k(e,i,s,o,r,c):I(e,i,s,o,r,c);s=r,o=c}return o}}(t,e);case O.ZD.ToString:return function(t,e){const r=t.operator,n=t.args.length,i=new Array(n);for(let r=0;r<n;++r)i[r]=D(t.args[r],e);if(r===O.ZD.ToString)return e=>{const r=i[0](e);return t.args[0].type===O.mE?(0,a.dI)(r):r.toString()};throw new Error(`Unsupported convert operator ${r}`)}(t,e);default:throw new Error(`Unsupported operator ${r}`)}}function I(t,e,r,n,i,s){const o=i-r;if(0===o)return n;const a=e-r;return n+(1===t?a/o:(Math.pow(t,a)-1)/(Math.pow(t,o)-1))*(s-n)}function k(t,e,r,n,i,s){if(0==i-r)return n;const o=(0,a.eE)(n),l=(0,a.eE)(s);let c=l[2]-o[2];c>180?c-=360:c<-180&&(c+=360);const u=[I(t,e,r,o[0],i,l[0]),I(t,e,r,o[1],i,l[1]),o[2]+I(t,e,r,0,i,c),I(t,e,r,n[3],i,s[3])];return(0,a.S8)((0,a.cD)(u))}var L=r(82048);function F(t){return!0}function j(t){const e=(0,O.SR)(),r=t.length,n=new Array(r);for(let i=0;i<r;++i)n[i]=N(t[i],e);const i={variables:{},properties:{},resolution:NaN,featureId:null,geometryType:""},s=new Array(r);return function(t,o){if(i.properties=t.getPropertiesInternal(),i.resolution=o,e.featureId){const e=t.getId();i.featureId=void 0!==e?e:null}let a=0;for(let t=0;t<r;++t){const e=n[t](i);e&&(s[a]=e,a+=1)}return s.length=a,s}}function N(t,e){const r=G(t,"",e),n=$(t,"",e),i=function(t,e){const r="text-",n=U(t,r+"value",e);if(!n)return null;const i=G(t,r,e),s=G(t,r+"background-",e),o=$(t,r,e),a=$(t,r+"background-",e),l=U(t,r+"font",e),c=z(t,r+"max-angle",e),u=z(t,r+"offset-x",e),h=z(t,r+"offset-y",e),d=B(t,r+"overflow",e),f=U(t,r+"placement",e),p=z(t,r+"repeat",e),m=H(t,r+"scale",e),g=B(t,r+"rotate-with-view",e),y=z(t,r+"rotation",e),v=U(t,r+"align",e),_=U(t,r+"justify",e),b=U(t,r+"baseline",e),w=q(t,r+"padding",e),x=Q(t,r+"declutter-mode"),E=new M({declutterMode:x});return function(t){if(E.setText(n(t)),i&&E.setFill(i(t)),s&&E.setBackgroundFill(s(t)),o&&E.setStroke(o(t)),a&&E.setBackgroundStroke(a(t)),l&&E.setFont(l(t)),c&&E.setMaxAngle(c(t)),u&&E.setOffsetX(u(t)),h&&E.setOffsetY(h(t)),d&&E.setOverflow(d(t)),f){const e=f(t);if("point"!==e&&"line"!==e)throw new Error("Expected point or line for text-placement");E.setPlacement(e)}if(p&&E.setRepeat(p(t)),m&&E.setScale(m(t)),g&&E.setRotateWithView(g(t)),y&&E.setRotation(y(t)),v){const e=v(t);if("left"!==e&&"center"!==e&&"right"!==e&&"end"!==e&&"start"!==e)throw new Error("Expected left, right, center, start, or end for text-align");E.setTextAlign(e)}if(_){const e=_(t);if("left"!==e&&"right"!==e&&"center"!==e)throw new Error("Expected left, right, or center for text-justify");E.setJustify(e)}if(b){const e=b(t);if("bottom"!==e&&"top"!==e&&"middle"!==e&&"alphabetic"!==e&&"hanging"!==e)throw new Error("Expected bottom, top, middle, alphabetic, or hanging for text-baseline");E.setTextBaseline(e)}return w&&E.setPadding(w(t)),E}}(t,e),s=function(t,e){return"icon-src"in t?function(t,e){const r="icon-",n=r+"src",i=et(t[n],n),s=K(t,r+"anchor",e),o=H(t,r+"scale",e),a=z(t,r+"opacity",e),l=K(t,r+"displacement",e),c=z(t,r+"rotation",e),u=B(t,r+"rotate-with-view",e),h=Z(t,r+"anchor-origin"),d=J(t,r+"anchor-x-units"),f=J(t,r+"anchor-y-units"),p=function(t,e){const r=t[e];if(void 0!==r)return nt(r,e)}(t,r+"color"),m=function(t,e){const r=t[e];if(void 0!==r){if("string"!=typeof r)throw new Error(`Expected a string for ${e}`);return r}}(t,r+"cross-origin"),g=function(t,e){const r=t[e];if(void 0!==r)return tt(r,e)}(t,r+"offset"),y=Z(t,r+"offset-origin"),v=Y(t,r+"width"),_=Y(t,r+"height"),b=X(t,r+"size"),w=Q(t,r+"declutter-mode"),x=new P.A({src:i,anchorOrigin:h,anchorXUnits:d,anchorYUnits:f,color:p,crossOrigin:m,offset:g,offsetOrigin:y,height:_,width:v,size:b,declutterMode:w});return function(t){return a&&x.setOpacity(a(t)),l&&x.setDisplacement(l(t)),c&&x.setRotation(c(t)),u&&x.setRotateWithView(u(t)),o&&x.setScale(o(t)),s&&x.setAnchor(s(t)),x}}(t,e):"shape-points"in t?function(t,e){const r="shape-",n=r+"points",i=r+"radius",s=rt(t[n],n),o=rt(t[i],i),a=G(t,r,e),l=$(t,r,e),c=H(t,r+"scale",e),u=K(t,r+"displacement",e),h=z(t,r+"rotation",e),f=B(t,r+"rotate-with-view",e),p=Y(t,r+"radius2"),m=Y(t,r+"angle"),g=Q(t,r+"declutter-mode"),y=new d({points:s,radius:o,radius2:p,angle:m,declutterMode:g});return function(t){return a&&y.setFill(a(t)),l&&y.setStroke(l(t)),u&&y.setDisplacement(u(t)),h&&y.setRotation(h(t)),f&&y.setRotateWithView(f(t)),c&&y.setScale(c(t)),y}}(t,e):"circle-radius"in t?function(t,e){const r="circle-",n=G(t,r,e),i=$(t,r,e),s=z(t,r+"radius",e),o=H(t,r+"scale",e),a=K(t,r+"displacement",e),l=z(t,r+"rotation",e),c=B(t,r+"rotate-with-view",e),u=Q(t,r+"declutter-mode"),h=new p({radius:5,declutterMode:u});return function(t){return s&&h.setRadius(s(t)),n&&h.setFill(n(t)),i&&h.setStroke(i(t)),a&&h.setDisplacement(a(t)),l&&h.setRotation(l(t)),c&&h.setRotateWithView(c(t)),o&&h.setScale(o(t)),h}}(t,e):null}(t,e),o=z(t,"z-index",e);if(!(r||n||i||s||(0,L.p)(t)))throw new Error("No fill, stroke, point, or text symbolizer properties in style: "+JSON.stringify(t));const a=new A;return function(t){let e=!0;if(r){const n=r(t);n&&(e=!1),a.setFill(n)}if(n){const r=n(t);r&&(e=!1),a.setStroke(r)}if(i){const r=i(t);r&&(e=!1),a.setText(r)}if(s){const r=s(t);r&&(e=!1),a.setImage(r)}return o&&a.setZIndex(o(t)),e?null:a}}function G(t,e,r){let n;if(e+"fill-pattern-src"in t)n=function(t,e,r){const n=U(t,e+"pattern-src",r),i=W(t,e+"pattern-offset",r),s=W(t,e+"pattern-size",r),o=V(t,e+"color",r);return function(t){return{src:n(t),offset:i&&i(t),size:s&&s(t),color:o&&o(t)}}}(t,e+"fill-",r);else{if("none"===t[e+"fill-color"])return t=>null;n=V(t,e+"fill-color",r)}if(!n)return null;const i=new y;return function(t){const e=n(t);return e===a.qV?null:(i.setColor(e),i)}}function $(t,e,r){const n=z(t,e+"stroke-width",r),i=V(t,e+"stroke-color",r);if(!n&&!i)return null;const s=U(t,e+"stroke-line-cap",r),o=U(t,e+"stroke-line-join",r),l=q(t,e+"stroke-line-dash",r),c=z(t,e+"stroke-line-dash-offset",r),u=z(t,e+"stroke-miter-limit",r),h=new _;return function(t){if(i){const e=i(t);if(e===a.qV)return null;h.setColor(e)}if(n&&h.setWidth(n(t)),s){const e=s(t);if("butt"!==e&&"round"!==e&&"square"!==e)throw new Error("Expected butt, round, or square line cap");h.setLineCap(e)}if(o){const e=o(t);if("bevel"!==e&&"round"!==e&&"miter"!==e)throw new Error("Expected bevel, round, or miter line join");h.setLineJoin(e)}return l&&h.setLineDash(l(t)),c&&h.setLineDashOffset(c(t)),u&&h.setMiterLimit(u(t)),h}}function z(t,e,r){if(!(e in t))return;const n=R(t[e],O.wl,r);return function(t){return rt(n(t),e)}}function U(t,e,r){if(!(e in t))return null;const n=R(t[e],O.cT,r);return function(t){return et(n(t),e)}}function B(t,e,r){if(!(e in t))return null;const n=R(t[e],O.T8,r);return function(t){const r=n(t);if("boolean"!=typeof r)throw new Error(`Expected a boolean for ${e}`);return r}}function V(t,e,r){if(!(e in t))return null;const n=R(t[e],O.mE,r);return function(t){return nt(n(t),e)}}function q(t,e,r){if(!(e in t))return null;const n=R(t[e],O.Fq,r);return function(t){return tt(n(t),e)}}function K(t,e,r){if(!(e in t))return null;const n=R(t[e],O.Fq,r);return function(t){const r=tt(n(t),e);if(2!==r.length)throw new Error(`Expected two numbers for ${e}`);return r}}function W(t,e,r){if(!(e in t))return null;const n=R(t[e],O.Fq,r);return function(t){return it(n(t),e)}}function H(t,e,r){if(!(e in t))return null;const n=R(t[e],O.Fq|O.wl,r);return function(t){return r=n(t),i=e,"number"==typeof r?r:it(r,i);var r,i}}function Y(t,e){const r=t[e];if(void 0!==r){if("number"!=typeof r)throw new Error(`Expected a number for ${e}`);return r}}function X(t,e){const r=t[e];if(void 0!==r){if("number"==typeof r)return(0,T.xq)(r);if(!Array.isArray(r))throw new Error(`Expected a number or size array for ${e}`);if(2!==r.length||"number"!=typeof r[0]||"number"!=typeof r[1])throw new Error(`Expected a number or size array for ${e}`);return r}}function Z(t,e){const r=t[e];if(void 0!==r){if("bottom-left"!==r&&"bottom-right"!==r&&"top-left"!==r&&"top-right"!==r)throw new Error(`Expected bottom-left, bottom-right, top-left, or top-right for ${e}`);return r}}function J(t,e){const r=t[e];if(void 0!==r){if("pixels"!==r&&"fraction"!==r)throw new Error(`Expected pixels or fraction for ${e}`);return r}}function Q(t,e){const r=t[e];if(void 0!==r){if("string"!=typeof r)throw new Error(`Expected a string for ${e}`);if("declutter"!==r&&"obstacle"!==r&&"none"!==r)throw new Error(`Expected declutter, obstacle, or none for ${e}`);return r}}function tt(t,e){if(!Array.isArray(t))throw new Error(`Expected an array for ${e}`);const r=t.length;for(let n=0;n<r;++n)if("number"!=typeof t[n])throw new Error(`Expected an array of numbers for ${e}`);return t}function et(t,e){if("string"!=typeof t)throw new Error(`Expected a string for ${e}`);return t}function rt(t,e){if("number"!=typeof t)throw new Error(`Expected a number for ${e}`);return t}function nt(t,e){if("string"==typeof t)return t;const r=tt(t,e),n=r.length;if(n<3||n>4)throw new Error(`Expected a color with 3 or 4 values for ${e}`);return r}function it(t,e){const r=tt(t,e);if(2!==r.length)throw new Error(`Expected an array of two numbers for ${e}`);return r}const st="renderOrder";class ot extends n.A{constructor(t){t=t||{};const e=Object.assign({},t);delete e.style,delete e.renderBuffer,delete e.updateWhileAnimating,delete e.updateWhileInteracting,super(e),this.declutter_=t.declutter?String(t.declutter):void 0,this.renderBuffer_=void 0!==t.renderBuffer?t.renderBuffer:100,this.style_=null,this.styleFunction_=void 0,this.setStyle(t.style),this.updateWhileAnimating_=void 0!==t.updateWhileAnimating&&t.updateWhileAnimating,this.updateWhileInteracting_=void 0!==t.updateWhileInteracting&&t.updateWhileInteracting}getDeclutter(){return this.declutter_}getFeatures(t){return super.getFeatures(t)}getRenderBuffer(){return this.renderBuffer_}getRenderOrder(){return this.get(st)}getStyle(){return this.style_}getStyleFunction(){return this.styleFunction_}getUpdateWhileAnimating(){return this.updateWhileAnimating_}getUpdateWhileInteracting(){return this.updateWhileInteracting_}renderDeclutter(t,e){const r=this.getDeclutter();r in t.declutter==0&&(t.declutter[r]=new i.A(9)),this.getRenderer().renderDeclutter(t,e)}setRenderOrder(t){this.set(st,t)}setStyle(t){this.style_=void 0===t?E:t;const e=function(t){if(void 0===t)return E;if(!t)return null;if("function"==typeof t)return t;if(t instanceof A)return t;if(!Array.isArray(t))return j([t]);if(0===t.length)return[];const e=t.length,r=t[0];if(r instanceof A){const r=new Array(e);for(let n=0;n<e;++n){const e=t[n];if(!(e instanceof A))throw new Error("Expected a list of style instances");r[n]=e}return r}if("style"in r){const r=new Array(e);for(let n=0;n<e;++n){const e=t[n];if(!("style"in e))throw new Error("Expected a list of rules with a style property");r[n]=e}return function(t){const e=(0,O.SR)(),r=function(t,e){const r=t.length,n=new Array(r);for(let i=0;i<r;++i){const r=t[i],s="filter"in r?R(r.filter,O.T8,e):F;let o;if(Array.isArray(r.style)){const t=r.style.length;o=new Array(t);for(let n=0;n<t;++n)o[n]=N(r.style[n],e)}else o=[N(r.style,e)];n[i]={filter:s,styles:o}}return function(e){const i=[];let s=!1;for(let o=0;o<r;++o)if((0,n[o].filter)(e)&&(!t[o].else||!s)){s=!0;for(const t of n[o].styles){const r=t(e);r&&i.push(r)}}return i}}(t,e),n={variables:{},properties:{},resolution:NaN,featureId:null,geometryType:""};return function(t,i){if(n.properties=t.getPropertiesInternal(),n.resolution=i,e.featureId){const e=t.getId();n.featureId=void 0!==e?e:null}return e.geometryType&&(n.geometryType=(0,O.Ye)(t.getGeometry())),r(n)}}(r)}return j(t)}(t);this.styleFunction_=null===t?void 0:function(t){let e;if("function"==typeof t)e=t;else{let r;Array.isArray(t)?r=t:((0,b.v)("function"==typeof t.getZIndex,"Expected an `Style` or an array of `Style`"),r=[t]),e=function(){return r}}return e}(e),this.changed()}}const at=ot},59916:(t,e,r)=>{"use strict";r.d(e,{A:()=>p});var n=r(73626);class i extends n.A{constructor(t){super(t=t||{})}}const s=i;var o=r(87383),a=r(39915),l=r(32769),c=r(37377),u=r(44509),h=r(12940);class d extends o.A{constructor(t){super(t),this.image=null}getImage(){return this.image?this.image.getImage():null}prepareFrame(t){const e=t.layerStatesArray[t.layerIndex],r=t.pixelRatio,n=t.viewState,i=n.resolution,s=this.getLayer().getSource(),o=t.viewHints;let c=t.extent;if(void 0!==e.extent&&(c=(0,u._N)(c,(0,h.SD)(e.extent,n.projection))),!o[l.A.ANIMATING]&&!o[l.A.INTERACTING]&&!(0,u.Im)(c))if(s){const t=n.projection,e=s.getImage(c,i,r,t);e&&(this.loadImage(e)?this.image=e:e.getState()===a.A.EMPTY&&(this.image=null))}else this.image=null;return!!this.image}getData(t){const e=this.frameState;if(!e)return null;const r=this.getLayer(),n=(0,c.Bb)(e.pixelToCoordinateTransform,t.slice()),i=r.getExtent();if(i&&!(0,u.Ym)(i,n))return null;const s=this.image.getExtent(),o=this.image.getImage(),a=(0,u.RG)(s),l=Math.floor(o.width*((n[0]-s[0])/a));if(l<0||l>=o.width)return null;const h=(0,u.Oq)(s),d=Math.floor(o.height*((s[3]-n[1])/h));return d<0||d>=o.height?null:this.getImageData(o,l,d)}renderFrame(t,e){const r=this.image,n=r.getExtent(),i=r.getResolution(),[s,o]=Array.isArray(i)?i:[i,i],a=r.getPixelRatio(),l=t.layerStatesArray[t.layerIndex],d=t.pixelRatio,f=t.viewState,p=f.center,m=f.resolution,g=d*s/(m*a),y=d*o/(m*a);this.prepareContainer(t,e);const v=this.context.canvas.width,_=this.context.canvas.height,b=this.getRenderContext(t);let w=!1,x=!0;if(l.extent){const e=(0,h.SD)(l.extent,f.projection);x=(0,u.HY)(e,t.extent),w=x&&!(0,u.ms)(e,t.extent),w&&this.clipUnrotated(b,t,e)}const E=r.getImage(),S=(0,c.Zz)(this.tempTransform,v/2,_/2,g,y,0,a*(n[0]-p[0])/s,a*(p[1]-n[3])/o);this.renderedResolution=o*d/a;const A=E.width*S[0],P=E.height*S[3];if(this.getLayer().getSource().getInterpolate()||(b.imageSmoothingEnabled=!1),this.preRender(b,t),x&&A>=.5&&P>=.5){const t=S[4],e=S[5],r=l.opacity;1!==r&&(b.save(),b.globalAlpha=r),b.drawImage(E,0,0,+E.width,+E.height,t,e,A,P),1!==r&&b.restore()}return this.postRender(this.context,t),w&&b.restore(),b.imageSmoothingEnabled=!0,this.container}}const f=d,p=class extends s{constructor(t){super(t)}createRenderer(){return new f(this)}getData(t){return super.getData(t)}}},73626:(t,e,r)=>{"use strict";r.d(e,{A:()=>f,l:()=>d});var n=r(93450),i=r(24187),s=r(59014),o=r(45630),a=r(95854),l=r(30878),c=r(44509),u=r(94456);class h extends n.A{constructor(t){const e=Object.assign({},t);delete e.source,super(e),this.on,this.once,this.un,this.mapPrecomposeKey_=null,this.mapRenderKey_=null,this.sourceChangeKey_=null,this.renderer_=null,this.sourceReady_=!1,this.rendered=!1,t.render&&(this.render=t.render),t.map&&this.setMap(t.map),this.addChangeListener(s.A.SOURCE,this.handleSourcePropertyChange_);const r=t.source?t.source:null;this.setSource(r)}getLayersArray(t){return(t=t||[]).push(this),t}getLayerStatesArray(t){return(t=t||[]).push(this.getLayerState()),t}getSource(){return this.get(s.A.SOURCE)||null}getRenderSource(){return this.getSource()}getSourceState(){const t=this.getSource();return t?t.getState():"undefined"}handleSourceChange_(){this.changed(),this.sourceReady_||"ready"!==this.getSource().getState()||(this.sourceReady_=!0,this.dispatchEvent("sourceready"))}handleSourcePropertyChange_(){this.sourceChangeKey_&&((0,u.JH)(this.sourceChangeKey_),this.sourceChangeKey_=null),this.sourceReady_=!1;const t=this.getSource();t&&(this.sourceChangeKey_=(0,u.KT)(t,i.A.CHANGE,this.handleSourceChange_,this),"ready"===t.getState()&&(this.sourceReady_=!0,setTimeout((()=>{this.dispatchEvent("sourceready")}),0))),this.changed()}getFeatures(t){return this.renderer_?this.renderer_.getFeatures(t):Promise.resolve([])}getData(t){return this.renderer_&&this.rendered?this.renderer_.getData(t):null}isVisible(t){let e;const r=this.getMapInternal();let n;!t&&r&&(t=r.getView()),e=t instanceof a.Ay?{viewState:t.getState(),extent:t.calculateExtent()}:t,!e.layerStatesArray&&r&&(e.layerStatesArray=r.getLayerGroup().getLayerStatesArray()),n=e.layerStatesArray?e.layerStatesArray.find((t=>t.layer===this)):this.getLayerState();const i=this.getExtent();return d(n,e.viewState)&&(!i||(0,c.HY)(i,e.extent))}getAttributions(t){if(!this.isVisible(t))return[];const e=this.getSource()?.getAttributions();if(!e)return[];let r=e(t instanceof a.Ay?t.getViewStateAndExtent():t);return Array.isArray(r)||(r=[r]),r}render(t,e){const r=this.getRenderer();return r.prepareFrame(t)?(this.rendered=!0,r.renderFrame(t,e)):null}unrender(){this.rendered=!1}getDeclutter(){}renderDeclutter(t,e){}renderDeferred(t){const e=this.getRenderer();e&&e.renderDeferred(t)}setMapInternal(t){t||this.unrender(),this.set(s.A.MAP,t)}getMapInternal(){return this.get(s.A.MAP)}setMap(t){this.mapPrecomposeKey_&&((0,u.JH)(this.mapPrecomposeKey_),this.mapPrecomposeKey_=null),t||this.changed(),this.mapRenderKey_&&((0,u.JH)(this.mapRenderKey_),this.mapRenderKey_=null),t&&(this.mapPrecomposeKey_=(0,u.KT)(t,o.A.PRECOMPOSE,this.handlePrecompose_,this),this.mapRenderKey_=(0,u.KT)(this,i.A.CHANGE,t.render,t),this.changed())}handlePrecompose_(t){const e=t.frameState.layerStatesArray,r=this.getLayerState(!1);(0,l.v)(!e.some((t=>t.layer===r.layer)),"A layer can only be added to the map once. Use either `layer.setMap()` or `map.addLayer()`, not both."),e.push(r)}setSource(t){this.set(s.A.SOURCE,t)}getRenderer(){return this.renderer_||(this.renderer_=this.createRenderer()),this.renderer_}hasRenderer(){return!!this.renderer_}createRenderer(){return null}disposeInternal(){this.renderer_&&(this.renderer_.dispose(),delete this.renderer_),this.setSource(null),super.disposeInternal()}}function d(t,e){if(!t.visible)return!1;const r=e.resolution;if(r<t.minResolution||r>=t.maxResolution)return!1;const n=e.zoom;return n>t.minZoom&&n<=t.maxZoom}const f=h},59014:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={OPACITY:"opacity",VISIBLE:"visible",EXTENT:"extent",Z_INDEX:"zIndex",MAX_RESOLUTION:"maxResolution",MIN_RESOLUTION:"minResolution",MAX_ZOOM:"maxZoom",MIN_ZOOM:"minZoom",SOURCE:"source",MAP:"map"}},12895:(t,e,r)=>{"use strict";r.d(e,{A:()=>o});var n=r(91430),i=r(34539);class s extends n.A{constructor(t){super(t)}createRenderer(){return new i.A(this,{cacheSize:this.getCacheSize()})}}const o=s},56106:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={PRELOAD:"preload",USE_INTERIM_TILES_ON_ERROR:"useInterimTilesOnError"}},79178:(t,e,r)=>{"use strict";r.d(e,{A:()=>b});var n=r(69199),i=r(21347),s=r(87383),o=r(9539),a=r(45630),l=r(32769),c=r(12049),u=r(44509),h=r(83085),d=r(75454),f=r(30444),p=r(12940),m=r(98629),g=r(9535);class y extends s.A{constructor(t){super(t),this.boundHandleStyleImageChange_=this.handleStyleImageChange_.bind(this),this.animatingOrInteracting_,this.hitDetectionImageData_=null,this.clipped_=!1,this.renderedFeatures_=null,this.renderedRevision_=-1,this.renderedResolution_=NaN,this.renderedExtent_=(0,u.S5)(),this.wrappedRenderedExtent_=(0,u.S5)(),this.renderedRotation_,this.renderedCenter_=null,this.renderedProjection_=null,this.renderedPixelRatio_=1,this.renderedRenderOrder_=null,this.renderedFrameDeclutter_,this.replayGroup_=null,this.replayGroupChanged=!0,this.clipping=!0,this.targetContext_=null,this.opacity_=1}renderWorlds(t,e,r){const n=e.extent,i=e.viewState,s=i.center,a=i.resolution,c=i.projection,h=i.rotation,d=c.getExtent(),f=this.getLayer().getSource(),p=this.getLayer().getDeclutter(),m=e.pixelRatio,g=e.viewHints,y=!(g[l.A.ANIMATING]||g[l.A.INTERACTING]),v=this.context,_=Math.round((0,u.RG)(n)/a*m),b=Math.round((0,u.Oq)(n)/a*m),w=f.getWrapX()&&c.canWrapX(),x=w?(0,u.RG)(d):null,E=w?Math.ceil((n[2]-d[2])/x)+1:1;let S=w?Math.floor((n[0]-d[0])/x):0;do{let n=this.getRenderTransform(s,a,0,m,_,b,S*x);e.declutter&&(n=n.slice(0)),t.execute(v,[v.canvas.width,v.canvas.height],n,h,y,void 0===r?o.y2:r?o.$i:o.x$,r?p&&e.declutter[p]:void 0)}while(++S<E)}setDrawContext_(){1!==this.opacity_&&(this.targetContext_=this.context,this.context=(0,h.Y)(this.context.canvas.width,this.context.canvas.height,s.B))}resetDrawContext_(){if(1!==this.opacity_){const t=this.targetContext_.globalAlpha;this.targetContext_.globalAlpha=this.opacity_,this.targetContext_.drawImage(this.context.canvas,0,0),this.targetContext_.globalAlpha=t,(0,h.Yg)(this.context),s.B.push(this.context.canvas),this.context=this.targetContext_,this.targetContext_=null}}renderDeclutter(t){this.replayGroup_&&this.getLayer().getDeclutter()&&this.renderWorlds(this.replayGroup_,t,!0)}renderDeferredInternal(t){this.replayGroup_&&(this.replayGroup_.renderDeferred(),this.clipped_&&this.context.restore(),this.resetDrawContext_())}renderFrame(t,e){const r=t.layerStatesArray[t.layerIndex];this.opacity_=r.opacity;const n=t.viewState;this.prepareContainer(t,e);const i=this.context,s=this.replayGroup_;let o=s&&!s.isEmpty();if(!o&&!this.getLayer().hasListener(a.A.PRERENDER)&&!this.getLayer().hasListener(a.A.POSTRENDER))return null;this.setDrawContext_(),this.preRender(i,t);const l=n.projection;if(this.clipped_=!1,o&&r.extent&&this.clipping){const e=(0,p.SD)(r.extent,l);o=(0,u.HY)(e,t.extent),this.clipped_=o&&!(0,u.ms)(e,t.extent),this.clipped_&&this.clipUnrotated(i,t,e)}return o&&this.renderWorlds(s,t,!this.getLayer().getDeclutter()&&void 0),!t.declutter&&this.clipped_&&i.restore(),this.postRender(i,t),this.renderedRotation_!==n.rotation&&(this.renderedRotation_=n.rotation,this.hitDetectionImageData_=null),t.declutter||this.resetDrawContext_(),this.container}getFeatures(t){return new Promise((e=>{if(this.frameState&&!this.hitDetectionImageData_&&!this.animatingOrInteracting_){const t=this.frameState.size.slice(),e=this.renderedCenter_,r=this.renderedResolution_,n=this.renderedRotation_,i=this.renderedProjection_,s=this.wrappedRenderedExtent_,o=this.getLayer(),a=[],l=t[0]*c.tF,h=t[1]*c.tF;a.push(this.getRenderTransform(e,r,n,c.tF,l,h,0).slice());const f=o.getSource(),m=i.getExtent();if(f.getWrapX()&&i.canWrapX()&&!(0,u.ms)(m,s)){let t=s[0];const i=(0,u.RG)(m);let o,d=0;for(;t<m[0];)--d,o=i*d,a.push(this.getRenderTransform(e,r,n,c.tF,l,h,o).slice()),t+=i;for(d=0,t=s[2];t>m[2];)++d,o=i*d,a.push(this.getRenderTransform(e,r,n,c.tF,l,h,o).slice()),t-=i}const g=(0,p.Tf)();this.hitDetectionImageData_=(0,c._7)(t,a,this.renderedFeatures_,o.getStyleFunction(),s,r,n,(0,d.j)(r,this.renderedPixelRatio_),g?i:null)}e((0,c.F8)(t,this.renderedFeatures_,this.hitDetectionImageData_))}))}forEachFeatureAtCoordinate(t,e,r,n,i){if(!this.replayGroup_)return;const s=e.viewState.resolution,o=e.viewState.rotation,a=this.getLayer(),l={},c=function(t,e,r){const s=(0,m.v6)(t),o=l[s];if(o){if(!0!==o&&r<o.distanceSq){if(0===r)return l[s]=!0,i.splice(i.lastIndexOf(o),1),n(t,a,e);o.geometry=e,o.distanceSq=r}}else{if(0===r)return l[s]=!0,n(t,a,e);i.push(l[s]={feature:t,layer:a,geometry:e,distanceSq:r,callback:n})}};let u;const h=[this.replayGroup_],d=this.getLayer().getDeclutter();return h.some((n=>u=n.forEachFeatureAtCoordinate(t,s,o,r,c,d&&e.declutter[d]?e.declutter[d].all().map((t=>t.value)):null))),u}handleFontsChanged(){const t=this.getLayer();t.getVisible()&&this.replayGroup_&&t.changed()}handleStyleImageChange_(t){this.renderIfReadyAndVisible()}prepareFrame(t){const e=this.getLayer(),r=e.getSource();if(!r)return!1;const n=t.viewHints[l.A.ANIMATING],s=t.viewHints[l.A.INTERACTING],a=e.getUpdateWhileAnimating(),c=e.getUpdateWhileInteracting();if(this.ready&&!a&&n||!c&&s)return this.animatingOrInteracting_=!0,!0;this.animatingOrInteracting_=!1;const h=t.extent,m=t.viewState,y=m.projection,v=m.resolution,_=t.pixelRatio,b=e.getRevision(),w=e.getRenderBuffer();let x=e.getRenderOrder();void 0===x&&(x=d.Eo);const E=m.center.slice(),S=(0,u.r)(h,w*v),A=S.slice(),P=[S.slice()],T=y.getExtent();if(r.getWrapX()&&y.canWrapX()&&!(0,u.ms)(T,t.extent)){const t=(0,u.RG)(T),e=Math.max((0,u.RG)(S)/2,t);S[0]=T[0]-e,S[2]=T[2]+e,(0,g.Li)(E,y);const r=(0,u.Li)(P[0],y);r[0]<T[0]&&r[2]<T[2]?P.push([r[0]+t,r[1],r[2]+t,r[3]]):r[0]>T[0]&&r[2]>T[2]&&P.push([r[0]-t,r[1],r[2]-t,r[3]])}if(this.ready&&this.renderedResolution_==v&&this.renderedRevision_==b&&this.renderedRenderOrder_==x&&this.renderedFrameDeclutter_===!!t.declutter&&(0,u.ms)(this.wrappedRenderedExtent_,S))return(0,f.aI)(this.renderedExtent_,A)||(this.hitDetectionImageData_=null,this.renderedExtent_=A),this.renderedCenter_=E,this.replayGroupChanged=!1,!0;this.replayGroup_=null;const C=new i.A((0,d.gY)(v,_),S,v,_),M=(0,p.Tf)();let O;if(M){for(let t=0,e=P.length;t<e;++t){const e=P[t],n=(0,p.JR)(e,y);r.loadFeatures(n,(0,p.vN)(v,y),M)}O=(0,p.FO)(M,y)}else for(let t=0,e=P.length;t<e;++t)r.loadFeatures(P[t],v,y);const R=(0,d.j)(v,_);let D=!0;const I=(t,r)=>{let n;const i=t.getStyleFunction()||e.getStyleFunction();if(i&&(n=i(t,v)),n){const e=this.renderFeature(t,R,n,C,O,this.getLayer().getDeclutter(),r);D=D&&!e}},k=(0,p.JR)(S,y),L=r.getFeaturesInExtent(k);x&&L.sort(x);for(let t=0,e=L.length;t<e;++t)I(L[t],t);this.renderedFeatures_=L,this.ready=D;const F=C.finish(),j=new o.Ay(S,v,_,r.getOverlaps(),F,e.getRenderBuffer(),!!t.declutter);return this.renderedResolution_=v,this.renderedRevision_=b,this.renderedRenderOrder_=x,this.renderedFrameDeclutter_=!!t.declutter,this.renderedExtent_=A,this.wrappedRenderedExtent_=S,this.renderedCenter_=E,this.renderedProjection_=y,this.renderedPixelRatio_=_,this.replayGroup_=j,this.hitDetectionImageData_=null,this.replayGroupChanged=!0,!0}renderFeature(t,e,r,n,i,s,o){if(!r)return!1;let a=!1;if(Array.isArray(r))for(let l=0,c=r.length;l<c;++l)a=(0,d.nl)(n,t,r[l],e,this.boundHandleStyleImageChange_,i,s,o)||a;else a=(0,d.nl)(n,t,r,e,this.boundHandleStyleImageChange_,i,s,o);return a}}const v=y;class _ extends n.A{constructor(t){super(t)}createRenderer(){return new v(this)}}const b=_},43802:(t,e,r)=>{"use strict";r.d(e,{A:()=>A});var n=r(69199),i=r(21347),s=r(9539),o=r(34539),a=r(20884),l=r(32769),c=r(83050),u=r(12049),h=r(37377),d=r(30444),f=r(44509),p=r(75454),m=r(98629),g=r(53908),y=r(9535);const v={image:["Polygon","Circle","LineString","Image","Text"],hybrid:["Polygon","LineString"],vector:[]},_={hybrid:["Image","Text","Default"],vector:["Polygon","Circle","LineString","Image","Text","Default"]};class b extends o.A{constructor(t,e){super(t,e),this.boundHandleStyleImageChange_=this.handleStyleImageChange_.bind(this),this.renderedLayerRevision_,this.renderedPixelToCoordinateTransform_=null,this.renderedRotation_,this.renderedOpacity_=1,this.tmpTransform_=(0,h.vt)(),this.tileClipContexts_=null}drawTile(t,e,r,n,i,s,o,a){this.updateExecutorGroup_(t,e.pixelRatio,e.viewState.projection),this.tileImageNeedsRender_(t)&&this.renderTileImage_(t,e),super.drawTile(t,e,r,n,i,s,o,a)}getTile(t,e,r,n){const i=this.getOrCreateTile(t,e,r,n);if(!i)return null;const s=n.viewState.resolution,o=n.viewHints;return!(!o[l.A.ANIMATING]&&!o[l.A.INTERACTING])&&i.wantedResolution||(i.wantedResolution=s),i}prepareFrame(t){const e=this.getLayer().getRevision();return this.renderedLayerRevision_!==e&&(this.renderedLayerRevision_=e,this.renderedTiles.length=0),super.prepareFrame(t)}updateExecutorGroup_(t,e,r){const n=this.getLayer(),o=n.getRevision(),l=n.getRenderOrder()||null,c=t.wantedResolution,u=t.getReplayState(n);if(!u.dirty&&u.renderedResolution===c&&u.renderedRevision==o&&u.renderedRenderOrder==l)return;const h=n.getSource(),d=!!n.getDeclutter(),g=h.getTileGrid(),y=h.getTileGridForProjection(r).getTileCoordExtent(t.wrappedTileCoord),v=h.getSourceTiles(e,r,t),_=(0,m.v6)(n);delete t.hitDetectionImageData[_],t.executorGroups[_]=[],u.dirty=!1;for(let r=0,o=v.length;r<o;++r){const o=v[r];if(o.getState()!=a.A.LOADED)continue;const m=o.tileCoord,b=g.getTileCoordExtent(m),w=(0,f._N)(y,b),x=(0,f.r)(w,n.getRenderBuffer()*c,this.tempExtent),E=(0,f.aI)(b,w)?null:x,S=new i.A(0,w,c,e),A=(0,p.j)(c,e),P=function(t,e){let r;const i=t.getStyleFunction()||n.getStyleFunction();if(i&&(r=i(t,c)),r){const n=this.renderFeature(t,A,r,S,d,e);u.dirty=u.dirty||n}},T=o.getFeatures();l&&l!==u.renderedRenderOrder&&T.sort(l);for(let t=0,e=T.length;t<e;++t){const e=T[t];E&&!(0,f.HY)(E,e.getGeometry().getExtent())||P.call(this,e,t)}const C=S.finish(),M="vector"!==n.getRenderMode()&&d&&1===v.length?null:w,O=new s.Ay(M,c,e,h.getOverlaps(),C,n.getRenderBuffer(),!0);t.executorGroups[_].push(O)}u.renderedRevision=o,u.renderedRenderOrder=l,u.renderedResolution=c}forEachFeatureAtCoordinate(t,e,r,n,i){const s=e.viewState.resolution,o=e.viewState.rotation;r=null==r?0:r;const a=this.getLayer(),l=a.getSource().getTileGridForProjection(e.viewState.projection),c=(0,f.Tr)([t]);(0,f.r)(c,s*r,c);const u={},h=function(t,e,r){let s=t.getId();void 0===s&&(s=(0,m.v6)(t));const o=u[s];if(o){if(!0!==o&&r<o.distanceSq){if(0===r)return u[s]=!0,i.splice(i.lastIndexOf(o),1),n(t,a,e);o.geometry=e,o.distanceSq=r}}else{if(0===r)return u[s]=!0,n(t,a,e);i.push(u[s]={feature:t,layer:a,geometry:e,distanceSq:r,callback:n})}},d=this.renderedTiles;let p;for(let n=0,i=d.length;!p&&n<i;++n){const i=d[n],u=l.getTileCoordExtent(i.wrappedTileCoord);if(!(0,f.HY)(u,c))continue;const g=(0,m.v6)(a),y=[i.executorGroups[g]],v=a.getDeclutter();y.some((n=>{const i=v?e.declutter[v].all().map((t=>t.value)):null;for(let e=0,a=n.length;e<a;++e){const a=n[e];if(p=a.forEachFeatureAtCoordinate(t,s,o,r,h,i),p)return!0}}))}return p}getFeatures(t){return new Promise(((e,r)=>{const n=this.getLayer(),i=(0,m.v6)(n),s=n.getSource(),o=this.renderedProjection,l=o.getExtent(),c=this.renderedResolution,d=s.getTileGridForProjection(o),p=(0,h.Bb)(this.renderedPixelToCoordinateTransform_,t.slice()),v=d.getTileCoordForCoordAndResolution(p,c);let _;for(let t=0,e=this.renderedTiles.length;t<e;++t)if(v.toString()===this.renderedTiles[t].tileCoord.toString()){if(_=this.renderedTiles[t],_.getState()===a.A.LOADED){const t=d.getTileCoordExtent(_.tileCoord);s.getWrapX()&&o.canWrapX()&&!(0,f.ms)(l,t)&&(0,y.Li)(p,o);break}_=void 0}if(!_||_.loadingSourceTiles>0)return void e([]);const b=d.getTileCoordExtent(_.wrappedTileCoord),w=(0,f.Py)(b),x=[(p[0]-w[0])/c,(w[1]-p[1])/c],E=_.getSourceTiles().reduce((function(t,e){return t.concat(e.getFeatures())}),[]);let S=_.hitDetectionImageData[i];if(!S){const t=(0,g.xq)(d.getTileSize(d.getZForResolution(c,s.zDirection))),e=this.renderedRotation_,r=[this.getRenderTransform(d.getTileCoordCenter(_.wrappedTileCoord),c,0,u.tF,t[0]*u.tF,t[1]*u.tF,0)];S=(0,u._7)(t,r,E,n.getStyleFunction(),d.getTileCoordExtent(_.wrappedTileCoord),_.getReplayState(n).renderedResolution,e),_.hitDetectionImageData[i]=S}e((0,u.F8)(x,E,S))}))}getFeaturesInExtent(t){const e=[],r=this.getTileCache();if(0===r.getCount())return e;const n=this.getLayer().getSource().getTileGridForProjection(this.frameState.viewState.projection),i=n.getZForResolution(this.renderedResolution),s={};return r.forEach((r=>{if(r.tileCoord[0]!==i||r.getState()!==a.A.LOADED)return;const o=r.getSourceTiles();for(let r=0,i=o.length;r<i;++r){const i=o[r],a=i.getKey();if(a in s)continue;s[a]=!0;const l=i.tileCoord;if((0,f.HY)(t,n.getTileCoordExtent(l))){const r=i.getFeatures();if(r)for(let n=0,i=r.length;n<i;++n){const i=r[n],s=i.getGeometry();(0,f.HY)(t,s.getExtent())&&e.push(i)}}}})),e}handleFontsChanged(){const t=this.getLayer();t.getVisible()&&void 0!==this.renderedLayerRevision_&&t.changed()}handleStyleImageChange_(t){this.renderIfReadyAndVisible()}renderDeclutter(t,e){const r=this.context,n=r.globalAlpha;r.globalAlpha=e.opacity;const i=t.viewHints,o=!(i[l.A.ANIMATING]||i[l.A.INTERACTING]),a=this.renderedTiles;for(let e=0,r=a.length;e<r;++e){const r=a[e],n=r.executorGroups[(0,m.v6)(this.getLayer())],i=this.getLayer().getDeclutter();if(n)for(let e=n.length-1;e>=0;--e)n[e].execute(this.context,[this.context.canvas.width,this.context.canvas.height],this.getTileRenderTransform(r,t),t.viewState.rotation,o,s.$i,i?t.declutter[i]:void 0)}r.globalAlpha=n}renderDeferredInternal(t){const e=this.renderedTiles.reduce(((t,e,r)=>(e.executorGroups[(0,m.v6)(this.getLayer())].forEach((e=>t.push({executorGroup:e,index:r}))),t)),[]),r=e.map((({executorGroup:t})=>t.getDeferredZIndexContexts())),n={};for(let t=0,r=e.length;t<r;++t){const r=e[t].executorGroup.getDeferredZIndexContexts();for(const t in r)n[t]=!0}Object.keys(n).sort(d.V_).map(Number).forEach((t=>{r.forEach(((r,n)=>{r[t]&&(r[t].forEach((t=>{const{executorGroup:r,index:i}=e[n],s=r.getRenderedContext(),o=s.globalAlpha;s.globalAlpha=this.renderedOpacity_;const a=this.tileClipContexts_[i];a&&a.draw(s),t.draw(s),a&&s.restore(),s.globalAlpha=o,t.clear()})),r[t].length=0)}))}))}getTileRenderTransform(t,e){const r=e.pixelRatio,n=e.viewState,i=n.center,s=n.resolution,o=n.rotation,a=e.size,l=Math.round(a[0]*r),c=Math.round(a[1]*r),u=this.getLayer().getSource().getTileGridForProjection(e.viewState.projection),d=t.tileCoord,f=u.getTileCoordExtent(t.wrappedTileCoord),p=u.getTileCoordExtent(d,this.tempExtent)[0]-f[0];return(0,h.lw)((0,h.hs)(this.inversePixelTransform.slice(),1/r,1/r),this.getRenderTransform(i,s,o,r,l,c,p))}postRender(t,e){const r=e.viewHints,n=!(r[l.A.ANIMATING]||r[l.A.INTERACTING]);this.renderedPixelToCoordinateTransform_=e.pixelToCoordinateTransform.slice(),this.renderedRotation_=e.viewState.rotation,this.renderedOpacity_=e.layerStatesArray[e.layerIndex].opacity;const i=this.getLayer(),o=i.getRenderMode(),a=t.globalAlpha;t.globalAlpha=this.renderedOpacity_;const u=i.getDeclutter(),h=u?_[o].filter((t=>!s.$i.includes(t))):_[o],d=e.viewState,p=d.rotation,g=i.getSource(),y=g.getTileGridForProjection(d.projection).getZForResolution(d.resolution,g.zDirection),v=this.renderedTiles,b=[],w=[],x=[];let E=!0;for(let r=v.length-1;r>=0;--r){const s=v[r];E=E&&!s.getReplayState(i).dirty;const o=s.executorGroups[(0,m.v6)(i)].filter((t=>t.hasExecutors(h)));if(0===o.length)continue;const a=this.getTileRenderTransform(s,e),l=s.tileCoord[0];let d=!1;const g=o[0].getClipCoords(a);let _,S=t;if(g){_=new c.A,S=_.getContext();for(let t=0,e=b.length;t<e;++t)if(y!==l&&l<w[t]){const e=b[t];(0,f.HY)([g[0],g[3],g[4],g[7]],[e[0],e[3],e[4],e[7]])&&(d||(S.save(),d=!0),S.beginPath(),S.moveTo(g[0],g[1]),S.lineTo(g[2],g[3]),S.lineTo(g[4],g[5]),S.lineTo(g[6],g[7]),S.moveTo(e[6],e[7]),S.lineTo(e[4],e[5]),S.lineTo(e[2],e[3]),S.lineTo(e[0],e[1]),S.clip())}b.push(g),w.push(l)}for(let r=0,i=o.length;r<i;++r)o[r].execute(t,[t.canvas.width,t.canvas.height],a,p,n,h,e.declutter?.[u]);d&&(S===t?S.restore():x[r]=_)}t.globalAlpha=a,this.ready=E,this.tileClipContexts_=x,e.declutter||this.renderDeferredInternal(e),super.postRender(t,e)}renderFeature(t,e,r,n,i,s){if(!r)return!1;let o=!1;if(Array.isArray(r))for(let a=0,l=r.length;a<l;++a)o=(0,p.nl)(n,t,r[a],e,this.boundHandleStyleImageChange_,void 0,i,s)||o;else o=(0,p.nl)(n,t,r,e,this.boundHandleStyleImageChange_,void 0,i,s);return o}tileImageNeedsRender_(t){const e=this.getLayer();if("vector"===e.getRenderMode())return!1;const r=t.getReplayState(e),n=e.getRevision(),i=t.wantedResolution;return r.renderedTileResolution!==i||r.renderedTileRevision!==n}renderTileImage_(t,e){const r=this.getLayer(),n=t.getReplayState(r),i=r.getRevision(),s=t.executorGroups[(0,m.v6)(r)];n.renderedTileRevision=i;const o=t.wrappedTileCoord,a=o[0],l=r.getSource();let c=e.pixelRatio;const u=e.viewState.projection,d=l.getTileGridForProjection(u),f=d.getResolution(t.tileCoord[0]),p=e.pixelRatio/t.wantedResolution*f,g=d.getResolution(a),y=t.getContext();c=Math.round(Math.max(c,p/c));const _=l.getTilePixelSize(a,c,u);y.canvas.width=_[0],y.canvas.height=_[1];const b=c/p;if(1!==b){const t=(0,h.cL)(this.tmpTransform_);(0,h.hs)(t,b,b),y.setTransform.apply(y,t)}const w=d.getTileCoordExtent(o,this.tempExtent),x=p/g,E=(0,h.cL)(this.tmpTransform_);(0,h.hs)(E,x,-x),(0,h.Tl)(E,-w[0],-w[3]);for(let t=0,e=s.length;t<e;++t)s[t].execute(y,[y.canvas.width*b,y.canvas.height*b],E,0,!0,v[r.getRenderMode()],null);n.renderedTileResolution=t.wantedResolution}}const w=b;var x=r(56106),E=r(30878);class S extends n.A{constructor(t){t=t||{};const e=Object.assign({},t);delete e.preload;const r=void 0===t.cacheSize?0:t.cacheSize;delete t.cacheSize,delete e.useInterimTilesOnError,super(e),this.on,this.once,this.un,this.cacheSize_=r;const n=t.renderMode||"hybrid";(0,E.v)("hybrid"==n||"vector"==n,"`renderMode` must be `'hybrid'` or `'vector'`"),this.renderMode_=n,this.setPreload(t.preload?t.preload:0),this.setUseInterimTilesOnError(void 0===t.useInterimTilesOnError||t.useInterimTilesOnError),this.getBackground,this.setBackground}createRenderer(){return new w(this,{cacheSize:this.cacheSize_})}getFeatures(t){return super.getFeatures(t)}getFeaturesInExtent(t){return this.getRenderer().getFeaturesInExtent(t)}getRenderMode(){return this.renderMode_}getPreload(){return this.get(x.A.PRELOAD)}getUseInterimTilesOnError(){return this.get(x.A.USE_INTERIM_TILES_ON_ERROR)}setPreload(t){this.set(x.A.PRELOAD,t)}setUseInterimTilesOnError(t){this.set(x.A.USE_INTERIM_TILES_ON_ERROR,t)}}const A=S},79382:(t,e,r)=>{"use strict";r.d(e,{A:()=>Gt});var n=r(91430),i=r(59014),s=r(91202),o=r(84562),a=r(20884),l=r(91086),c=r(24187),u=r(67564),h=r(98629);class d extends l.A{constructor(t){super(),this.tile,this.handleTileChange_=this.handleTileChange_.bind(this),this.gutter=t.gutter||0,this.helper=t.helper,this.loaded=!1,this.ready=!1}setTile(t){if(t!==this.tile)if(this.tile&&this.tile.removeEventListener(c.A.CHANGE,this.handleTileChange_),this.tile=t,this.loaded=t.getState()===a.A.LOADED,this.loaded)this.uploadTile();else{if(t instanceof u.A){const e=t.getImage();e instanceof Image&&!e.crossOrigin&&(e.crossOrigin="anonymous")}t.addEventListener(c.A.CHANGE,this.handleTileChange_)}}uploadTile(){(0,h.b0)()}setReady(){this.ready=!0,this.dispatchEvent(c.A.CHANGE)}handleTileChange_(){this.tile.getState()===a.A.LOADED&&(this.loaded=!0,this.uploadTile())}setHelper(t){this.helper=t,this.helper&&this.loaded&&this.uploadTile()}disposeInternal(){this.setHelper(null),this.tile.removeEventListener(c.A.CHANGE,this.handleTileChange_)}}const f=d;var p=r(97141),m=r(66993);const g=34962,y=34963,v=35044,_=["experimental-webgl","webgl","webkit-3d","moz-webgl"];function b(t,e){e=Object.assign({preserveDrawingBuffer:!0,antialias:!m.oF},e);const r=_.length;for(let n=0;n<r;++n)try{const r=t.getContext(_[n],e);if(r)return r}catch(t){}return null}var w=r(30878);function x(t){switch(t){case g:return Float32Array;case y:return Uint32Array;default:return Float32Array}}const E=class{constructor(t,e){this.array_=null,this.type_=t,(0,w.v)(t===g||t===y,"A `WebGLArrayBuffer` must either be of type `ELEMENT_ARRAY_BUFFER` or `ARRAY_BUFFER`"),this.usage_=void 0!==e?e:35044}ofSize(t){return this.array_=new(x(this.type_))(t),this}fromArray(t){return this.array_=x(this.type_).from(t),this}fromArrayBuffer(t){return this.array_=new(x(this.type_))(t),this}getType(){return this.type_}getArray(){return this.array_}setArray(t){const e=x(this.type_);if(!(t instanceof e))throw new Error(`Expected ${e}`);this.array_=t}getUsage(){return this.usage_}getSize(){return this.array_?this.array_.length:0}};var S=r(83085),A=r(53908);function P(t,e,r){const n=r?t.LINEAR:t.NEAREST;t.bindTexture(t.TEXTURE_2D,e),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,n),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MAG_FILTER,n)}function T(t,e,r,n,i,s){const o=t.getGL();let a,l;r instanceof Float32Array?(a=o.FLOAT,t.getExtension("OES_texture_float"),l=null!==t.getExtension("OES_texture_float_linear")):(a=o.UNSIGNED_BYTE,l=!0),P(o,e,s&&l);const c=r.byteLength/n[1];let u,h=1;switch(c%8==0?h=8:c%4==0?h=4:c%2==0&&(h=2),i){case 1:u=o.LUMINANCE;break;case 2:u=o.LUMINANCE_ALPHA;break;case 3:u=o.RGB;break;case 4:u=o.RGBA;break;default:throw new Error(`Unsupported number of bands: ${i}`)}const d=o.getParameter(o.UNPACK_ALIGNMENT);o.pixelStorei(o.UNPACK_ALIGNMENT,h),o.texImage2D(o.TEXTURE_2D,0,u,n[0],n[1],0,u,a,r),o.pixelStorei(o.UNPACK_ALIGNMENT,d)}let C=null;const M=class extends f{constructor(t){super(t),this.textures=[],this.renderSize_=(0,A.xq)(t.grid.getTileSize(t.tile.tileCoord[0])),this.bandCount=NaN;const e=new E(g,v);e.fromArray([0,1,1,1,1,0,0,0]),this.helper.flushBufferData(e),this.coords=e,this.setTile(t.tile)}setHelper(t){const e=this.helper?.getGL();if(e){this.helper.deleteBuffer(this.coords);for(let t=0;t<this.textures.length;++t)e.deleteTexture(this.textures[t])}super.setHelper(t),t&&t.flushBufferData(this.coords)}uploadTile(){const t=this.helper,e=t.getGL(),r=this.tile;let n;this.textures.length=0,n=r instanceof u.A||r instanceof o.A?r.getImage():r.getData();const i=(0,p.xo)(n);if(i){const t=e.createTexture();return this.textures.push(t),this.bandCount=4,function(t,e,r,n){P(t,e,n),t.texImage2D(t.TEXTURE_2D,0,t.RGBA,t.RGBA,t.UNSIGNED_BYTE,r)}(e,t,i,r.interpolate),void this.setReady()}n=(0,p.bL)(n);const s=r.getSize(),a=[s[0]+2*this.gutter,s[1]+2*this.gutter],l=n instanceof Float32Array,c=a[0]*a[1],h=l?Float32Array:Uint8Array,d=h.BYTES_PER_ELEMENT,f=n.byteLength/a[1];this.bandCount=Math.floor(f/d/a[0]);const m=Math.ceil(this.bandCount/4);if(1===m){const i=e.createTexture();return this.textures.push(i),T(t,i,n,a,this.bandCount,r.interpolate),void this.setReady()}const g=new Array(m);for(let t=0;t<m;++t){const r=e.createTexture();this.textures.push(r);const n=t<m-1?4:(this.bandCount-1)%4+1;g[t]=new h(c*n)}let y=0,v=0;const _=a[0]*this.bandCount;for(let t=0;t<a[1];++t){for(let t=0;t<_;++t){const e=n[v+t],r=Math.floor(y/this.bandCount),i=t%this.bandCount,s=g[Math.floor(i/4)];s[r*(s.length/c)+i%4]=e,++y}v+=f/d}for(let e=0;e<m;++e){const n=this.textures[e],i=g[e];T(t,n,i,a,i.length/c,r.interpolate)}this.setReady()}getImagePixelData_(t,e,r){const n=this.gutter,i=this.renderSize_[0],s=this.renderSize_[1];C||(C=(0,S.Y)(1,1,void 0,{willReadFrequently:!0})),C.clearRect(0,0,1,1);const o=t.width-2*n,a=t.height-2*n,l=n+Math.floor(o*(e/i)),c=n+Math.floor(a*(r/s));let u;try{C.drawImage(t,l,c,1,1,0,0,1,1),u=C.getImageData(0,0,1,1).data}catch(t){return C=null,null}return u}getArrayPixelData_(t,e,r,n){const i=this.gutter,s=this.renderSize_[0],o=this.renderSize_[1],a=e[0],l=e[1],c=a+2*i,u=l+2*i,h=i+Math.floor(a*(r/s)),d=i+Math.floor(l*(n/o));if(t instanceof DataView){const e=t.byteLength/(c*u),r=e*(d*c+h),n=t.buffer.slice(r,r+e);return new DataView(n)}const f=this.bandCount*(d*c+h);return t.slice(f,f+this.bandCount)}getPixelData(t,e){if(!this.loaded)return null;if(this.tile instanceof p.Ay){const r=this.tile.getData(),n=(0,p.bL)(r);if(n){const r=this.tile.getSize();return this.getArrayPixelData_(n,r,t,e)}return this.getImagePixelData_((0,p.xo)(r),t,e)}return this.getImagePixelData_(this.tile.getImage(),t,e)}};var O=r(98063),R=r(64444),D=r(10312),I=r(3094),k=r(45630);const L="webglcontextlost",F="webglcontextrestored";var j=r(60239);const N=class{constructor(t){this.gl_=t.webGlContext;const e=this.gl_;this.scaleRatio_=t.scaleRatio||1,this.renderTargetTexture_=e.createTexture(),this.renderTargetTextureSize_=null,this.frameBuffer_=e.createFramebuffer(),this.depthBuffer_=e.createRenderbuffer();const r=e.createShader(e.VERTEX_SHADER);e.shaderSource(r,t.vertexShader||"\n precision mediump float;\n\n attribute vec2 a_position;\n varying vec2 v_texCoord;\n varying vec2 v_screenCoord;\n\n uniform vec2 u_screenSize;\n\n void main() {\n v_texCoord = a_position * 0.5 + 0.5;\n v_screenCoord = v_texCoord * u_screenSize;\n gl_Position = vec4(a_position, 0.0, 1.0);\n }\n"),e.compileShader(r);const n=e.createShader(e.FRAGMENT_SHADER);e.shaderSource(n,t.fragmentShader||"\n precision mediump float;\n\n uniform sampler2D u_image;\n uniform float u_opacity;\n\n varying vec2 v_texCoord;\n\n void main() {\n gl_FragColor = texture2D(u_image, v_texCoord) * u_opacity;\n }\n"),e.compileShader(n),this.renderTargetProgram_=e.createProgram(),e.attachShader(this.renderTargetProgram_,r),e.attachShader(this.renderTargetProgram_,n),e.linkProgram(this.renderTargetProgram_),this.renderTargetVerticesBuffer_=e.createBuffer(),e.bindBuffer(e.ARRAY_BUFFER,this.renderTargetVerticesBuffer_),e.bufferData(e.ARRAY_BUFFER,new Float32Array([-1,-1,1,-1,-1,1,1,-1,1,1,-1,1]),e.STATIC_DRAW),this.renderTargetAttribLocation_=e.getAttribLocation(this.renderTargetProgram_,"a_position"),this.renderTargetUniformLocation_=e.getUniformLocation(this.renderTargetProgram_,"u_screenSize"),this.renderTargetOpacityLocation_=e.getUniformLocation(this.renderTargetProgram_,"u_opacity"),this.renderTargetTextureLocation_=e.getUniformLocation(this.renderTargetProgram_,"u_image"),this.uniforms_=[],t.uniforms&&Object.keys(t.uniforms).forEach((r=>{this.uniforms_.push({value:t.uniforms[r],location:e.getUniformLocation(this.renderTargetProgram_,r)})}))}getRenderTargetTexture(){return this.renderTargetTexture_}getGL(){return this.gl_}init(t){const e=this.getGL(),r=[e.drawingBufferWidth*this.scaleRatio_,e.drawingBufferHeight*this.scaleRatio_];if(e.bindFramebuffer(e.FRAMEBUFFER,this.getFrameBuffer()),e.bindRenderbuffer(e.RENDERBUFFER,this.getDepthBuffer()),e.viewport(0,0,r[0],r[1]),!this.renderTargetTextureSize_||this.renderTargetTextureSize_[0]!==r[0]||this.renderTargetTextureSize_[1]!==r[1]){this.renderTargetTextureSize_=r;const t=0,n=e.RGBA,i=0,s=e.RGBA,o=e.UNSIGNED_BYTE,a=null;e.bindTexture(e.TEXTURE_2D,this.renderTargetTexture_),e.texImage2D(e.TEXTURE_2D,t,n,r[0],r[1],i,s,o,a),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,this.renderTargetTexture_,0),e.renderbufferStorage(e.RENDERBUFFER,e.DEPTH_COMPONENT16,r[0],r[1]),e.framebufferRenderbuffer(e.FRAMEBUFFER,e.DEPTH_ATTACHMENT,e.RENDERBUFFER,this.depthBuffer_)}}apply(t,e,r,n){const i=this.getGL(),s=t.size;if(i.bindFramebuffer(i.FRAMEBUFFER,e?e.getFrameBuffer():null),i.activeTexture(i.TEXTURE0),i.bindTexture(i.TEXTURE_2D,this.renderTargetTexture_),!e){const e=(0,h.v6)(i.canvas);if(!t.renderTargets[e]){const r=i.getContextAttributes();r&&r.preserveDrawingBuffer&&(i.clearColor(0,0,0,0),i.clearDepth(1),i.clear(i.COLOR_BUFFER_BIT|i.DEPTH_BUFFER_BIT)),t.renderTargets[e]=!0}}i.disable(i.DEPTH_TEST),i.enable(i.BLEND),i.blendFunc(i.ONE,i.ONE_MINUS_SRC_ALPHA),i.viewport(0,0,i.drawingBufferWidth,i.drawingBufferHeight),i.bindBuffer(i.ARRAY_BUFFER,this.renderTargetVerticesBuffer_),i.useProgram(this.renderTargetProgram_),i.enableVertexAttribArray(this.renderTargetAttribLocation_),i.vertexAttribPointer(this.renderTargetAttribLocation_,2,i.FLOAT,!1,0,0),i.uniform2f(this.renderTargetUniformLocation_,s[0],s[1]),i.uniform1i(this.renderTargetTextureLocation_,0);const o=t.layerStatesArray[t.layerIndex].opacity;i.uniform1f(this.renderTargetOpacityLocation_,o),this.applyUniforms(t),r&&r(i,t),i.drawArrays(i.TRIANGLES,0,6),n&&n(i,t)}getFrameBuffer(){return this.frameBuffer_}getDepthBuffer(){return this.depthBuffer_}applyUniforms(t){const e=this.getGL();let r,n=1;this.uniforms_.forEach((function(i){if(r="function"==typeof i.value?i.value(t):i.value,r instanceof HTMLCanvasElement||r instanceof ImageData)i.texture||(i.texture=e.createTexture()),e.activeTexture(e[`TEXTURE${n}`]),e.bindTexture(e.TEXTURE_2D,i.texture),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),r instanceof ImageData?e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,r.width,r.height,0,e.UNSIGNED_BYTE,new Uint8Array(r.data)):e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,r),e.uniform1i(i.location,n++);else if(Array.isArray(r))switch(r.length){case 2:return void e.uniform2f(i.location,r[0],r[1]);case 3:return void e.uniform3f(i.location,r[0],r[1],r[2]);case 4:return void e.uniform4f(i.location,r[0],r[1],r[2],r[3]);default:return}else"number"==typeof r&&e.uniform1f(i.location,r)}))}};var G=r(82048),$=r(37377);function z(t,e){return t[0]=e[0],t[1]=e[1],t[4]=e[2],t[5]=e[3],t[12]=e[4],t[13]=e[5],t}const U="u_pixelRatio",B={};function V(t){return"shared/"+t}let q=0;class K extends j.A{constructor(t){super(),t=t||{},this.boundHandleWebGLContextLost_=this.handleWebGLContextLost.bind(this),this.boundHandleWebGLContextRestored_=this.handleWebGLContextRestored.bind(this),this.canvasCacheKey_=t.canvasCacheKey?V(t.canvasCacheKey):function(){const t="unique/"+q;return q+=1,t}(),this.gl_=function(t){let e=B[t];if(!e){const r=document.createElement("canvas");r.width=1,r.height=1,r.style.position="absolute",r.style.left="0",e={users:0,context:b(r)},B[t]=e}return e.users+=1,e.context}(this.canvasCacheKey_),this.bufferCache_={},this.extensionCache_={},this.currentProgram_=null,this.needsToBeRecreated_=!1;const e=this.gl_.canvas;e.addEventListener(L,this.boundHandleWebGLContextLost_),e.addEventListener(F,this.boundHandleWebGLContextRestored_),this.offsetRotateMatrix_=(0,$.vt)(),this.offsetScaleMatrix_=(0,$.vt)(),this.tmpMat4_=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],this.uniformLocationsByProgram_={},this.attribLocationsByProgram_={},this.uniforms_=[],t.uniforms&&this.setUniforms(t.uniforms),this.postProcessPasses_=t.postProcesses?t.postProcesses.map((t=>new N({webGlContext:this.gl_,scaleRatio:t.scaleRatio,vertexShader:t.vertexShader,fragmentShader:t.fragmentShader,uniforms:t.uniforms}))):[new N({webGlContext:this.gl_})],this.shaderCompileErrors_=null,this.startTime_=Date.now()}setUniforms(t){this.uniforms_=[],this.addUniforms(t)}addUniforms(t){for(const e in t)this.uniforms_.push({name:e,value:t[e]})}canvasCacheKeyMatches(t){return this.canvasCacheKey_===V(t)}getExtension(t){if(t in this.extensionCache_)return this.extensionCache_[t];const e=this.gl_.getExtension(t);return this.extensionCache_[t]=e,e}bindBuffer(t){const e=this.gl_,r=(0,h.v6)(t);let n=this.bufferCache_[r];n||(n={buffer:t,webGlBuffer:e.createBuffer()},this.bufferCache_[r]=n),e.bindBuffer(t.getType(),n.webGlBuffer)}flushBufferData(t){const e=this.gl_;this.bindBuffer(t),e.bufferData(t.getType(),t.getArray(),t.getUsage())}deleteBuffer(t){const e=(0,h.v6)(t);delete this.bufferCache_[e]}disposeInternal(){const t=this.gl_.canvas;t.removeEventListener(L,this.boundHandleWebGLContextLost_),t.removeEventListener(F,this.boundHandleWebGLContextRestored_),function(t){const e=B[t];if(!e)return;if(e.users-=1,e.users>0)return;const r=e.context,n=r.getExtension("WEBGL_lose_context");n&&n.loseContext();const i=r.canvas;i.width=1,i.height=1,delete B[t]}(this.canvasCacheKey_),delete this.gl_}prepareDraw(t,e,r){const n=this.gl_,i=this.getCanvas(),s=t.size,o=t.pixelRatio;i.width===s[0]*o&&i.height===s[1]*o||(i.width=s[0]*o,i.height=s[1]*o,i.style.width=s[0]+"px",i.style.height=s[1]+"px");for(let e=this.postProcessPasses_.length-1;e>=0;e--)this.postProcessPasses_[e].init(t);n.bindTexture(n.TEXTURE_2D,null),n.clearColor(0,0,0,0),n.depthRange(0,1),n.clearDepth(1),n.clear(n.COLOR_BUFFER_BIT|n.DEPTH_BUFFER_BIT),n.enable(n.BLEND),n.blendFunc(n.ONE,e?n.ZERO:n.ONE_MINUS_SRC_ALPHA),r?(n.enable(n.DEPTH_TEST),n.depthFunc(n.LEQUAL)):n.disable(n.DEPTH_TEST)}bindFrameBuffer(t,e){const r=this.getGL();r.bindFramebuffer(r.FRAMEBUFFER,t),e&&r.framebufferTexture2D(r.FRAMEBUFFER,r.COLOR_ATTACHMENT0,r.TEXTURE_2D,e,0)}bindInitialFrameBuffer(){const t=this.getGL(),e=this.postProcessPasses_[0].getFrameBuffer();t.bindFramebuffer(t.FRAMEBUFFER,e);const r=this.postProcessPasses_[0].getRenderTargetTexture();t.framebufferTexture2D(t.FRAMEBUFFER,t.COLOR_ATTACHMENT0,t.TEXTURE_2D,r,0)}bindTexture(t,e,r){const n=this.gl_;n.activeTexture(n.TEXTURE0+e),n.bindTexture(n.TEXTURE_2D,t),n.uniform1i(this.getUniformLocation(r),e)}bindAttribute(t,e,r){const n=this.getGL();this.bindBuffer(t);const i=this.getAttributeLocation(e);n.enableVertexAttribArray(i),n.vertexAttribPointer(i,r,n.FLOAT,!1,0,0)}prepareDrawToRenderTarget(t,e,r,n){const i=this.gl_,s=e.getSize();i.bindFramebuffer(i.FRAMEBUFFER,e.getFramebuffer()),i.bindRenderbuffer(i.RENDERBUFFER,e.getDepthbuffer()),i.viewport(0,0,s[0],s[1]),i.bindTexture(i.TEXTURE_2D,e.getTexture()),i.clearColor(0,0,0,0),i.depthRange(0,1),i.clearDepth(1),i.clear(i.COLOR_BUFFER_BIT|i.DEPTH_BUFFER_BIT),i.enable(i.BLEND),i.blendFunc(i.ONE,r?i.ZERO:i.ONE_MINUS_SRC_ALPHA),n?(i.enable(i.DEPTH_TEST),i.depthFunc(i.LEQUAL)):i.disable(i.DEPTH_TEST)}drawElements(t,e){const r=this.gl_;this.getExtension("OES_element_index_uint");const n=r.UNSIGNED_INT,i=e-t,s=4*t;r.drawElements(r.TRIANGLES,i,n,s)}finalizeDraw(t,e,r){for(let n=0,i=this.postProcessPasses_.length;n<i;n++)n===i-1?this.postProcessPasses_[n].apply(t,null,e,r):this.postProcessPasses_[n].apply(t,this.postProcessPasses_[n+1])}getCanvas(){return this.gl_.canvas}getGL(){return this.gl_}applyFrameState(t){const e=t.size,r=t.viewState.rotation,n=t.pixelRatio;this.setUniformFloatValue("u_time",.001*(Date.now()-this.startTime_)),this.setUniformFloatValue("u_zoom",t.viewState.zoom),this.setUniformFloatValue("u_resolution",t.viewState.resolution),this.setUniformFloatValue(U,n),this.setUniformFloatVec2("u_viewportSizePx",[e[0],e[1]]),this.setUniformFloatValue("u_rotation",r)}applyHitDetectionUniform(t){const e=this.getUniformLocation("u_hitDetection");this.getGL().uniform1i(e,t?1:0),t&&this.setUniformFloatValue(U,.5)}applyUniforms(t){const e=this.gl_;let r,n=0;this.uniforms_.forEach((i=>{if(r="function"==typeof i.value?i.value(t):i.value,r instanceof HTMLCanvasElement||r instanceof HTMLImageElement||r instanceof ImageData||r instanceof WebGLTexture){r instanceof WebGLTexture&&!i.texture?(i.prevValue=void 0,i.texture=r):i.texture||(i.prevValue=void 0,i.texture=e.createTexture()),this.bindTexture(i.texture,n,i.name),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE);const t=!(r instanceof HTMLImageElement)||r.complete;r instanceof WebGLTexture||!t||i.prevValue===r||(i.prevValue=r,e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,r)),n++}else if(Array.isArray(r)&&6===r.length)this.setUniformMatrixValue(i.name,z(this.tmpMat4_,r));else if(Array.isArray(r)&&r.length<=4)switch(r.length){case 2:return void e.uniform2f(this.getUniformLocation(i.name),r[0],r[1]);case 3:return void e.uniform3f(this.getUniformLocation(i.name),r[0],r[1],r[2]);case 4:return void e.uniform4f(this.getUniformLocation(i.name),r[0],r[1],r[2],r[3]);default:return}else"number"==typeof r&&e.uniform1f(this.getUniformLocation(i.name),r)}))}useProgram(t,e){this.gl_.useProgram(t),this.currentProgram_=t,e&&(this.applyFrameState(e),this.applyUniforms(e))}compileShader(t,e){const r=this.gl_,n=r.createShader(e);return r.shaderSource(n,t),r.compileShader(n),n}getProgram(t,e){const r=this.gl_,n=this.compileShader(t,r.FRAGMENT_SHADER),i=this.compileShader(e,r.VERTEX_SHADER),s=r.createProgram();if(r.attachShader(s,n),r.attachShader(s,i),r.linkProgram(s),!r.getShaderParameter(n,r.COMPILE_STATUS)){const t=`Fragment shader compilation failed: ${r.getShaderInfoLog(n)}`;throw new Error(t)}if(r.deleteShader(n),!r.getShaderParameter(i,r.COMPILE_STATUS)){const t=`Vertex shader compilation failed: ${r.getShaderInfoLog(i)}`;throw new Error(t)}if(r.deleteShader(i),!r.getProgramParameter(s,r.LINK_STATUS)){const t=`GL program linking failed: ${r.getProgramInfoLog(s)}`;throw new Error(t)}return s}getUniformLocation(t){const e=(0,h.v6)(this.currentProgram_);return void 0===this.uniformLocationsByProgram_[e]&&(this.uniformLocationsByProgram_[e]={}),void 0===this.uniformLocationsByProgram_[e][t]&&(this.uniformLocationsByProgram_[e][t]=this.gl_.getUniformLocation(this.currentProgram_,t)),this.uniformLocationsByProgram_[e][t]}getAttributeLocation(t){const e=(0,h.v6)(this.currentProgram_);return void 0===this.attribLocationsByProgram_[e]&&(this.attribLocationsByProgram_[e]={}),void 0===this.attribLocationsByProgram_[e][t]&&(this.attribLocationsByProgram_[e][t]=this.gl_.getAttribLocation(this.currentProgram_,t)),this.attribLocationsByProgram_[e][t]}makeProjectionTransform(t,e){const r=t.size,n=t.viewState.rotation,i=t.viewState.resolution,s=t.viewState.center;return(0,$.Zz)(e,0,0,2/(i*r[0]),2/(i*r[1]),-n,-s[0],-s[1]),e}setUniformFloatValue(t,e){this.gl_.uniform1f(this.getUniformLocation(t),e)}setUniformFloatVec2(t,e){this.gl_.uniform2fv(this.getUniformLocation(t),e)}setUniformFloatVec4(t,e){this.gl_.uniform4fv(this.getUniformLocation(t),e)}setUniformMatrixValue(t,e){this.gl_.uniformMatrix4fv(this.getUniformLocation(t),!1,e)}enableAttributeArray_(t,e,r,n,i){const s=this.getAttributeLocation(t);s<0||(this.gl_.enableVertexAttribArray(s),this.gl_.vertexAttribPointer(s,e,r,!1,n,i))}enableAttributes(t){const e=function(t){let e=0;for(let r=0;r<t.length;r++){const n=t[r];e+=n.size*W(n.type)}return e}(t);let r=0;for(let n=0;n<t.length;n++){const i=t[n];this.enableAttributeArray_(i.name,i.size,i.type||5126,e,r),r+=i.size*W(i.type)}}handleWebGLContextLost(t){(0,G.I)(this.bufferCache_),this.currentProgram_=null,t.preventDefault()}handleWebGLContextRestored(){this.needsToBeRecreated_=!0}needsToBeRecreated(){return this.needsToBeRecreated_}createTexture(t,e,r,n){const i=this.gl_;r=r||i.createTexture();const s=n?i.NEAREST:i.LINEAR;i.bindTexture(i.TEXTURE_2D,r),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,s),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,s),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE);const o=i.RGBA,a=i.RGBA,l=i.UNSIGNED_BYTE;return e instanceof Uint8Array?i.texImage2D(i.TEXTURE_2D,0,o,t[0],t[1],0,a,l,e):e?i.texImage2D(i.TEXTURE_2D,0,o,a,l,e):i.texImage2D(i.TEXTURE_2D,0,o,t[0],t[1],0,a,l,null),r}}function W(t){switch(t){case 5121:return Uint8Array.BYTES_PER_ELEMENT;case 5123:return Uint16Array.BYTES_PER_ELEMENT;case 5125:return Uint32Array.BYTES_PER_ELEMENT;default:return Float32Array.BYTES_PER_ELEMENT}}const H=K;class Y extends D.A{constructor(t,e){super(t),e=e||{},this.inversePixelTransform_=(0,$.vt)(),this.postProcesses_=e.postProcesses,this.uniforms_=e.uniforms,this.helper,this.onMapChanged_=()=>{this.clearCache(),this.removeHelper()},t.addChangeListener(i.A.MAP,this.onMapChanged_),this.dispatchPreComposeEvent=this.dispatchPreComposeEvent.bind(this),this.dispatchPostComposeEvent=this.dispatchPostComposeEvent.bind(this)}dispatchPreComposeEvent(t,e){const r=this.getLayer();if(r.hasListener(k.A.PRECOMPOSE)){const n=new I.A(k.A.PRECOMPOSE,void 0,e,t);r.dispatchEvent(n)}}dispatchPostComposeEvent(t,e){const r=this.getLayer();if(r.hasListener(k.A.POSTCOMPOSE)){const n=new I.A(k.A.POSTCOMPOSE,void 0,e,t);r.dispatchEvent(n)}}reset(t){this.uniforms_=t.uniforms,this.helper&&this.helper.setUniforms(this.uniforms_)}removeHelper(){this.helper&&(this.helper.dispose(),delete this.helper)}prepareFrame(t){if(this.getLayer().getRenderSource()){let e,r=!0,n=-1;for(let i=0,s=t.layerStatesArray.length;i<s;i++){const s=t.layerStatesArray[i].layer,o=s.getRenderer();if(!(o instanceof Y)){r=!0;continue}const a=s.getClassName();if((r||a!==e)&&(n+=1,r=!1),e=a,o===this)break}const i="map/"+t.mapId+"/group/"+n;this.helper&&this.helper.canvasCacheKeyMatches(i)&&!this.helper.needsToBeRecreated()||(this.removeHelper(),this.helper=new H({postProcesses:this.postProcesses_,uniforms:this.uniforms_,canvasCacheKey:i}),e&&(this.helper.getCanvas().className=e),this.afterHelperCreated())}return this.prepareFrameInternal(t)}afterHelperCreated(){}prepareFrameInternal(t){return!0}clearCache(){}disposeInternal(){this.clearCache(),this.removeHelper(),this.getLayer()?.removeChangeListener(i.A.MAP,this.onMapChanged_),super.disposeInternal()}dispatchRenderEvent_(t,e,r){const n=this.getLayer();if(n.hasListener(t)){(0,$.Zz)(this.inversePixelTransform_,0,0,r.pixelRatio,-r.pixelRatio,0,0,-r.size[1]);const i=new I.A(t,this.inversePixelTransform_,r,e);n.dispatchEvent(i)}}preRender(t,e){this.dispatchRenderEvent_(k.A.PRERENDER,t,e)}postRender(t,e){this.dispatchRenderEvent_(k.A.POSTRENDER,t,e)}}const X=Y;var Z=r(80996),J=r(30444),Q=r(12940),tt=r(44509);function et(t){return 1/(t+2)}function rt(t,e){return t.tileIds.has((0,h.v6)(e))}function nt(t,e,r){const n=t.representationsByZ;r in n||(n[r]=new Set),n[r].add(e),t.tileIds.add((0,h.v6)(e.tile))}function it(t,e){const r=t.layerStatesArray[t.layerIndex];r.extent&&(e=(0,tt._N)(e,(0,Q.SD)(r.extent,t.viewState.projection)));const n=r.layer.getRenderSource();if(!n.getWrapX()){const r=n.getTileGridForProjection(t.viewState.projection).getExtent();r&&(e=(0,tt._N)(e,r))}return e}function st(t,e){return`${t.getKey()},${(0,Z.i7)(e)}`}const ot=class extends X{constructor(t,e){super(t,{uniforms:e.uniforms,postProcesses:e.postProcesses}),this.renderComplete=!1,this.tileTransform_=(0,$.vt)(),this.tempMat4=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],this.tempTileRange_=new R.A(0,0,0,0),this.tempTileCoord_=(0,Z.N)(0,0,0),this.tempSize_=[0,0];const r=void 0!==e.cacheSize?e.cacheSize:512;this.tileRepresentationCache=new O.A(r),this.frameState=null,this.renderedProjection_=void 0}reset(t){super.reset({uniforms:t.uniforms})}prepareFrameInternal(t){this.renderedProjection_?t.viewState.projection!==this.renderedProjection_&&(this.clearCache(),this.renderedProjection_=t.viewState.projection):this.renderedProjection_=t.viewState.projection;const e=this.getLayer().getRenderSource();return!!e&&!(0,tt.Im)(it(t,t.extent))&&"ready"===e.getState()}createTileRepresentation(t){return(0,h.b0)()}enqueueTiles(t,e,r,n,i){const s=t.viewState,o=this.getLayer(),l=o.getRenderSource(),c=l.getTileGridForProjection(s.projection),u=l.getGutterForProjection(s.projection),d=(0,h.v6)(l);d in t.wantedTiles||(t.wantedTiles[d]={});const f=t.wantedTiles[d],p=this.tileRepresentationCache,m=o.getMapInternal(),g=Math.max(r-i,c.getMinZoom(),c.getZForResolution(Math.min(o.getMaxResolution(),m?m.getView().getResolutionForZoom(Math.max(o.getMinZoom(),0)):c.getResolution(0)),l.zDirection));for(let i=r;i>=g;--i){const r=c.getTileRangeForExtentAndZ(e,i,this.tempTileRange_),o=c.getResolution(i);for(let e=r.minX;e<=r.maxX;++e)for(let h=r.minY;h<=r.maxY;++h){const r=(0,Z.N)(i,e,h,this.tempTileCoord_),m=st(l,r);let g,y;if(p.containsKey(m)&&(g=p.get(m),y=g.tile),!(g&&g.tile.key===l.getKey()||(y=l.getTile(i,e,h,t.pixelRatio,s.projection),y)))continue;if(rt(n,y))continue;g?g.setTile(y):(g=this.createTileRepresentation({tile:y,grid:c,helper:this.helper,gutter:u}),p.set(m,g)),nt(n,g,i);const v=y.getKey();f[v]=!0,y.getState()===a.A.IDLE&&(t.tileQueue.isKeyQueued(v)||t.tileQueue.enqueue([y,d,c.getTileCoordCenter(r),o]))}}}beforeTilesRender(t,e){this.helper.prepareDraw(this.frameState,!e,!0)}beforeTilesMaskRender(t){return!1}renderTile(t,e,r,n,i,s,o,a,l,c,u){}renderTileMask(t,e,r,n){}drawTile_(t,e,r,n,i,s,o){if(!e.ready)return;const a=e.tile.tileCoord,l=(0,Z.i7)(a),c=l in s?s[l]:1,u=o.getResolution(r),h=(0,A.xq)(o.getTileSize(r),this.tempSize_),d=o.getOrigin(r),f=o.getTileCoordExtent(a),p=c<1?-1:et(r);c<1&&(t.animate=!0);const m=t.viewState,g=m.center[0],y=m.center[1],v=h[0]+2*n,_=h[1]+2*n,b=v/_,w=(g-d[0])/(h[0]*u),x=(d[1]-y)/(h[1]*u),E=m.resolution/u,S=a[1],P=a[2];(0,$.cL)(this.tileTransform_),(0,$.hs)(this.tileTransform_,2/(t.size[0]*E/v),-2/(t.size[1]*E/v)),(0,$.e$)(this.tileTransform_,m.rotation),(0,$.hs)(this.tileTransform_,1,1/b),(0,$.Tl)(this.tileTransform_,(h[0]*(S-w)-n)/v,(h[1]*(P-x)-n)/_),this.renderTile(e,this.tileTransform_,t,i,u,h,d,f,p,n,c)}renderFrame(t){this.frameState=t,this.renderComplete=!0;const e=this.helper.getGL();this.preRender(e,t);const r=t.viewState,n=this.getLayer(),i=n.getRenderSource(),l=i.getTileGridForProjection(r.projection),c=i.getGutterForProjection(r.projection),u=it(t,t.extent),d=l.getZForResolution(r.resolution,i.zDirection),f={tileIds:new Set,representationsByZ:{}},p=n.getPreload();if(t.nextExtent){const e=l.getZForResolution(r.nextResolution,i.zDirection),n=it(t,t.nextExtent);this.enqueueTiles(t,n,e,f,p)}this.enqueueTiles(t,u,d,f,0),p>0&&setTimeout((()=>{this.enqueueTiles(t,u,d-1,f,p-1)}),0);const m={},g=(0,h.v6)(this),y=t.time;let v=!1;const _=f.representationsByZ;if(d in _)for(const t of _[d]){const e=t.tile;if((e instanceof o.A||e instanceof s.A)&&e.getState()===a.A.EMPTY)continue;const r=e.tileCoord;if(t.ready){const t=e.getAlpha(g,y);if(1===t){e.endTransition(g);continue}v=!0,m[(0,Z.i7)(r)]=t}if(this.renderComplete=!1,this.findAltTiles_(l,r,d+1,f))continue;const n=l.getMinZoom();for(let t=d-1;t>=n&&!this.findAltTiles_(l,r,t,f);--t);}const b=Object.keys(_).map(Number).sort(J.rG);if(this.beforeTilesMaskRender(t))for(let t=0,e=b.length;t<e;++t){const e=b[t];for(const t of _[e]){const r=t.tile.tileCoord;if((0,Z.i7)(r)in m)continue;const n=l.getTileCoordExtent(r);this.renderTileMask(t,e,n,et(e))}}this.beforeTilesRender(t,v);for(let e=0,r=b.length;e<r;++e){const r=b[e];for(const e of _[r]){const n=e.tile.tileCoord;(0,Z.i7)(n)in m||this.drawTile_(t,e,r,c,u,m,l)}}if(d in _)for(const e of _[d]){const r=e.tile.tileCoord;(0,Z.i7)(r)in m&&this.drawTile_(t,e,d,c,u,m,l)}this.beforeFinalize(t),this.helper.finalizeDraw(t,this.dispatchPreComposeEvent,this.dispatchPostComposeEvent);const w=this.helper.getCanvas(),x=this.tileRepresentationCache;for(;x.canExpireCache();)x.pop().dispose();return this.postRender(e,t),w}beforeFinalize(t){}findAltTiles_(t,e,r,n){const i=t.getTileRangeForTileCoordAndZ(e,r,this.tempTileRange_);if(!i)return!1;let s=!0;const o=this.tileRepresentationCache,a=this.getLayer().getRenderSource();for(let t=i.minX;t<=i.maxX;++t)for(let e=i.minY;e<=i.maxY;++e){const i=st(a,[r,t,e]);let l=!1;if(o.containsKey(i)){const t=o.get(i);t.ready&&!rt(n,t.tile)&&(nt(n,t,r),l=!0)}l||(s=!1)}return s}clearCache(){super.clearCache();const t=this.tileRepresentationCache;t.forEach((t=>t.dispose())),t.clear()}afterHelperCreated(){super.afterHelperCreated(),this.tileRepresentationCache.forEach((t=>t.setHelper(this.helper)))}disposeInternal(){super.disposeInternal(),delete this.frameState}},at="u_tileTransform",lt="u_transitionAlpha",ct="u_depth",ut="u_renderExtent",ht="u_resolution",dt="u_zoom",ft="u_tileTextures",pt="u_texturePixelWidth",mt="u_texturePixelHeight",gt="u_textureResolution",yt="u_textureOriginX",vt="u_textureOriginY",_t="a_textureCoord",bt=[{name:_t,size:2,type:5126}],wt=class extends ot{constructor(t,e){super(t,e),this.program_,this.vertexShader_=e.vertexShader,this.fragmentShader_=e.fragmentShader,this.indices_=new E(y,v),this.indices_.fromArray([0,1,3,1,2,3]),this.paletteTextures_=e.paletteTextures||[]}reset(t){if(super.reset(t),this.helper){const t=this.helper.getGL();for(const e of this.paletteTextures_)e.delete(t)}if(this.vertexShader_=t.vertexShader,this.fragmentShader_=t.fragmentShader,this.paletteTextures_=t.paletteTextures||[],this.helper){this.program_=this.helper.getProgram(this.fragmentShader_,this.vertexShader_);const t=this.helper.getGL();for(const e of this.paletteTextures_)e.getTexture(t)}}afterHelperCreated(){super.afterHelperCreated();const t=this.helper.getGL();for(const e of this.paletteTextures_)e.getTexture(t);this.program_=this.helper.getProgram(this.fragmentShader_,this.vertexShader_),this.helper.flushBufferData(this.indices_)}removeHelper(){if(this.helper){const t=this.helper.getGL();for(const e of this.paletteTextures_)e.delete(t)}super.removeHelper()}createTileRepresentation(t){return new M(t)}beforeTilesRender(t,e){super.beforeTilesRender(t,e),this.helper.useProgram(this.program_,t)}renderTile(t,e,r,n,i,s,o,a,l,c,u){const h=this.helper.getGL();this.helper.bindBuffer(t.coords),this.helper.bindBuffer(this.indices_),this.helper.enableAttributes(bt);let d=0;for(;d<t.textures.length;){const e=`${ft}[${d}]`;this.helper.bindTexture(t.textures[d],d,e),++d}for(let t=0;t<this.paletteTextures_.length;++t){const e=this.paletteTextures_[t],r=e.getTexture(h);this.helper.bindTexture(r,d,e.name),++d}const f=r.viewState,p=s[0]+2*c,m=s[1]+2*c,g=t.tile.tileCoord,y=g[1],v=g[2];this.helper.setUniformMatrixValue(at,z(this.tempMat4,e)),this.helper.setUniformFloatValue(lt,u),this.helper.setUniformFloatValue(ct,l);let _=n;c>0&&(_=a,(0,tt._N)(_,n,_)),this.helper.setUniformFloatVec4(ut,_),this.helper.setUniformFloatValue(ht,f.resolution),this.helper.setUniformFloatValue(dt,f.zoom),this.helper.setUniformFloatValue(pt,p),this.helper.setUniformFloatValue(mt,m),this.helper.setUniformFloatValue(gt,i),this.helper.setUniformFloatValue(yt,o[0]+y*s[0]*i-c*i),this.helper.setUniformFloatValue(vt,o[1]-v*s[1]*i+c*i),this.helper.drawElements(0,this.indices_.getSize())}getData(t){if(!this.helper.getGL())return null;const e=this.frameState;if(!e)return null;const r=this.getLayer(),n=(0,$.Bb)(e.pixelToCoordinateTransform,t.slice()),i=e.viewState,l=r.getExtent();if(l&&!(0,tt.Ym)((0,Q.SD)(l,i.projection),n))return null;const c=r.getSources((0,tt.Tr)([n]),i.resolution);let u,h,d;for(u=c.length-1;u>=0;--u)if(h=c[u],"ready"===h.getState()){if(d=h.getTileGridForProjection(i.projection),h.getWrapX())break;const t=d.getExtent();if(!t||(0,tt.Ym)(t,n))break}if(u<0)return null;const f=this.tileRepresentationCache;for(let t=d.getZForResolution(i.resolution);t>=d.getMinZoom();--t){const e=d.getTileCoordForCoordAndZ(n,t),r=st(h,e);if(!f.containsKey(r))continue;const i=f.get(r),l=i.tile;if((l instanceof o.A||l instanceof s.A)&&l.getState()===a.A.EMPTY)return null;if(!i.loaded)continue;const c=d.getOrigin(t),u=(0,A.xq)(d.getTileSize(t)),p=d.getResolution(t),m=(n[0]-c[0])/p-e[1]*u[0],g=(c[1]-n[1])/p-e[2]*u[1];return i.getPixelData(m,g)}return null}disposeInternal(){const t=this.helper;if(t){const e=t.getGL();for(const t of this.paletteTextures_)t.delete(e);this.paletteTextures_.length=0,e.deleteProgram(this.program_),delete this.program_,t.deleteBuffer(this.indices_)}super.disposeInternal(),delete this.indices_}};var xt=r(62439);const Et=class{constructor(t,e){this.name=t,this.data=e,this.texture_=null}getTexture(t){if(!this.texture_){const e=t.createTexture();t.bindTexture(t.TEXTURE_2D,e),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,t.NEAREST),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MAG_FILTER,t.NEAREST),t.texImage2D(t.TEXTURE_2D,0,t.RGBA,this.data.length/4,1,0,t.RGBA,t.UNSIGNED_BYTE,this.data),this.texture_=e}return this.texture_}delete(t){this.texture_&&t.deleteTexture(this.texture_),this.texture_=null}};var St=r(41009);function At(t){const e=t.toString();return e.includes(".")?e:e+".0"}function Pt(t){if(t.length<2||t.length>4)throw new Error("`formatArray` can only output `vec2`, `vec3` or `vec4` arrays.");return`vec${t.length}(${t.map(At).join(", ")})`}const Tt={};let Ct=0;function Mt(t){return t in Tt||(Tt[t]=Ct++),Tt[t]}function Ot(t){return"u_var_"+t}const Rt="getBandValue",Dt="u_paletteTextures";function It(t){return(e,r,n)=>{const i=r.args.length,s=new Array(i);for(let t=0;t<i;++t)s[t]=Lt(r.args[t],n,e);return t(s,e)}}const kt={[xt.ZD.Get]:(t,e)=>{const r=e.args[0].value;return r in t.properties||(t.properties[r]={name:r,type:e.type}),(t.inFragmentShader?"v_prop_":"a_prop_")+r},[xt.ZD.GeometryType]:(t,e,r)=>{const n="geometryType";return n in t.properties||(t.properties[n]={name:n,type:xt.cT,evaluator:t=>(0,xt.Ye)(t.getGeometry())}),(t.inFragmentShader?"v_prop_":"a_prop_")+n},[xt.ZD.LineMetric]:()=>"currentLineMetric",[xt.ZD.Var]:(t,e)=>{const r=e.args[0].value;return r in t.variables||(t.variables[r]={name:r,type:e.type}),Ot(r)},[xt.ZD.Resolution]:()=>"u_resolution",[xt.ZD.Zoom]:()=>"u_zoom",[xt.ZD.Time]:()=>"u_time",[xt.ZD.Any]:It((t=>`(${t.join(" || ")})`)),[xt.ZD.All]:It((t=>`(${t.join(" && ")})`)),[xt.ZD.Not]:It((([t])=>`(!${t})`)),[xt.ZD.Equal]:It((([t,e])=>`(${t} == ${e})`)),[xt.ZD.NotEqual]:It((([t,e])=>`(${t} != ${e})`)),[xt.ZD.GreaterThan]:It((([t,e])=>`(${t} > ${e})`)),[xt.ZD.GreaterThanOrEqualTo]:It((([t,e])=>`(${t} >= ${e})`)),[xt.ZD.LessThan]:It((([t,e])=>`(${t} < ${e})`)),[xt.ZD.LessThanOrEqualTo]:It((([t,e])=>`(${t} <= ${e})`)),[xt.ZD.Multiply]:It((t=>`(${t.join(" * ")})`)),[xt.ZD.Divide]:It((([t,e])=>`(${t} / ${e})`)),[xt.ZD.Add]:It((t=>`(${t.join(" + ")})`)),[xt.ZD.Subtract]:It((([t,e])=>`(${t} - ${e})`)),[xt.ZD.Clamp]:It((([t,e,r])=>`clamp(${t}, ${e}, ${r})`)),[xt.ZD.Mod]:It((([t,e])=>`mod(${t}, ${e})`)),[xt.ZD.Pow]:It((([t,e])=>`pow(${t}, ${e})`)),[xt.ZD.Abs]:It((([t])=>`abs(${t})`)),[xt.ZD.Floor]:It((([t])=>`floor(${t})`)),[xt.ZD.Ceil]:It((([t])=>`ceil(${t})`)),[xt.ZD.Round]:It((([t])=>`floor(${t} + 0.5)`)),[xt.ZD.Sin]:It((([t])=>`sin(${t})`)),[xt.ZD.Cos]:It((([t])=>`cos(${t})`)),[xt.ZD.Atan]:It((([t,e])=>void 0!==e?`atan(${t}, ${e})`:`atan(${t})`)),[xt.ZD.Sqrt]:It((([t])=>`sqrt(${t})`)),[xt.ZD.Match]:It((t=>{const e=t[0],r=t[t.length-1];let n=null;for(let i=t.length-3;i>=1;i-=2)n=`(${e} == ${t[i]} ? ${t[i+1]} : ${n||r})`;return n})),[xt.ZD.Between]:It((([t,e,r])=>`(${t} >= ${e} && ${t} <= ${r})`)),[xt.ZD.Interpolate]:It((([t,e,...r])=>{let n="";for(let i=0;i<r.length-2;i+=2){const s=r[i],o=n||r[i+1],a=r[i+2],l=r[i+3];let c;c=t===At(1)?`(${e} - ${s}) / (${a} - ${s})`:`(pow(${t}, (${e} - ${s})) - 1.0) / (pow(${t}, (${a} - ${s})) - 1.0)`,n=`mix(${o}, ${l}, clamp(${c}, 0.0, 1.0))`}return n})),[xt.ZD.Case]:It((t=>{const e=t[t.length-1];let r=null;for(let n=t.length-3;n>=0;n-=2)r=`(${t[n]} ? ${t[n+1]} : ${r||e})`;return r})),[xt.ZD.In]:It((([t,...e],r)=>{const n=function(t,e){return`operator_in_${Object.keys(e.functions).length}`}(0,r),i=[];for(let t=0;t<e.length;t+=1)i.push(` if (inputValue == ${e[t]}) { return true; }`);return r.functions[n]=`bool ${n}(float inputValue) {\n${i.join("\n")}\n return false;\n}`,`${n}(${t})`})),[xt.ZD.Array]:It((t=>`vec${t.length}(${t.join(", ")})`)),[xt.ZD.Color]:It((t=>{if(1===t.length)return`vec4(vec3(${t[0]} / 255.0), 1.0)`;if(2===t.length)return`vec4(vec3(${t[0]} / 255.0), ${t[1]})`;const e=t.slice(0,3).map((t=>`${t} / 255.0`));if(3===t.length)return`vec4(${e.join(", ")}, 1.0)`;const r=t[3];return`vec4(${e.join(", ")}, ${r})`})),[xt.ZD.Band]:It((([t,e,r],n)=>{if(!(Rt in n.functions)){let t="";const e=n.bandCount||1;for(let r=0;r<e;r++){const n=Math.floor(r/4);let i=r%4;r===e-1&&1===i&&(i=3),t+=` if (band == ${r+1}.0) {\n return texture2D(${ft}[${n}], v_textureCoord + vec2(dx, dy))[${i}];\n }\n`}n.functions[Rt]=`float getBandValue(float band, float xOffset, float yOffset) {\n float dx = xOffset / ${pt};\n float dy = yOffset / ${mt};\n${t}\n}`}return`${Rt}(${t}, ${e??"0.0"}, ${r??"0.0"})`})),[xt.ZD.Palette]:(t,e)=>{const[r,...n]=e.args,i=n.length,s=new Uint8Array(4*i);for(let t=0;t<n.length;t++){const e=n[t].value,r=(0,St._j)(e),i=4*t;s[i]=r[0],s[i+1]=r[1],s[i+2]=r[2],s[i+3]=255*r[3]}t.paletteTextures||(t.paletteTextures=[]);const o=`${Dt}[${t.paletteTextures.length}]`,a=new Et(o,s);return t.paletteTextures.push(a),`texture2D(${o}, vec2((${Lt(r,xt.wl,t)} + 0.5) / ${i}.0, 0.5))`}};function Lt(t,e,r){if(t instanceof xt.DG){const n=kt[t.operator];if(void 0===n)throw new Error(`No compiler defined for this operator: ${JSON.stringify(t.operator)}`);return n(r,t,e)}if((t.type&xt.wl)>0)return At(t.value);if((t.type&xt.T8)>0)return t.value.toString();if((t.type&xt.cT)>0)return At(Mt(t.value.toString()));var n;if((t.type&xt.mE)>0)return function(t){const e=(0,St._j)(t),r=e.length>3?e[3]:1;return Pt([e[0]/255,e[1]/255,e[2]/255,r])}(t.value);if((t.type&xt.Fq)>0)return Pt(t.value);if((t.type&xt.qA)>0)return n=t.value,Pt((0,A.xq)(n));throw new Error(`Unexpected expression ${t.value} (expected type ${(0,xt.go)(e)})`)}function Ft(t,e,r){return function(t,e,r,n){return Lt((0,xt.qg)(t,e,r),e,n)}(e,r,(0,xt.SR)(),t)}function jt(t,e){const r=`\n attribute vec2 ${_t};\n uniform mat4 ${at};\n uniform float ${pt};\n uniform float ${mt};\n uniform float ${gt};\n uniform float ${yt};\n uniform float ${vt};\n uniform float ${ct};\n\n varying vec2 v_textureCoord;\n varying vec2 v_mapCoord;\n\n void main() {\n v_textureCoord = ${_t};\n v_mapCoord = vec2(\n ${yt} + ${gt} * ${pt} * v_textureCoord[0],\n ${vt} - ${gt} * ${mt} * v_textureCoord[1]\n );\n gl_Position = ${at} * vec4(${_t}, ${ct}, 1.0);\n }\n `,n={inFragmentShader:!1,variables:{},properties:{},functions:{},bandCount:0,style:{},inFragmentShader:!0,bandCount:e,style:t},i=[];if(void 0!==t.color){const e=Ft(n,t.color,xt.mE);i.push(`color = ${e};`)}if(void 0!==t.contrast){const e=Ft(n,t.contrast,xt.wl);i.push(`color.rgb = clamp((${e} + 1.0) * color.rgb - (${e} / 2.0), vec3(0.0, 0.0, 0.0), vec3(1.0, 1.0, 1.0));`)}if(void 0!==t.exposure){const e=Ft(n,t.exposure,xt.wl);i.push(`color.rgb = clamp((${e} + 1.0) * color.rgb, vec3(0.0, 0.0, 0.0), vec3(1.0, 1.0, 1.0));`)}if(void 0!==t.saturation){const e=Ft(n,t.saturation,xt.wl);i.push(`\n float saturation = ${e} + 1.0;\n float sr = (1.0 - saturation) * 0.2126;\n float sg = (1.0 - saturation) * 0.7152;\n float sb = (1.0 - saturation) * 0.0722;\n mat3 saturationMatrix = mat3(\n sr + saturation, sr, sr,\n sg, sg + saturation, sg,\n sb, sb, sb + saturation\n );\n color.rgb = clamp(saturationMatrix * color.rgb, vec3(0.0, 0.0, 0.0), vec3(1.0, 1.0, 1.0));\n `)}if(void 0!==t.gamma){const e=Ft(n,t.gamma,xt.wl);i.push(`color.rgb = pow(color.rgb, vec3(1.0 / ${e}));`)}if(void 0!==t.brightness){const e=Ft(n,t.brightness,xt.wl);i.push(`color.rgb = clamp(color.rgb + ${e}, vec3(0.0, 0.0, 0.0), vec3(1.0, 1.0, 1.0));`)}const s={},o=Object.keys(n.variables).length;if(o>1&&!t.variables)throw new Error(`Missing variables in style (expected ${n.variables})`);for(let e=0;e<o;++e){const r=n.variables[Object.keys(n.variables)[e]];if(!(r.name in t.variables))throw new Error(`Missing '${r.name}' in style variables`);s[Ot(r.name)]=function(){let e=t.variables[r.name];return"string"==typeof e&&(e=Mt(e)),void 0!==e?e:-9999999}}const a=Object.keys(s).map((function(t){return`uniform float ${t};`})),l=Math.ceil(e/4);a.push(`uniform sampler2D ${ft}[${l}];`),n.paletteTextures&&a.push(`uniform sampler2D ${Dt}[${n.paletteTextures.length}];`);const c=Object.keys(n.functions).map((function(t){return n.functions[t]}));return{vertexShader:r,fragmentShader:`\n #ifdef GL_FRAGMENT_PRECISION_HIGH\n precision highp float;\n #else\n precision mediump float;\n #endif\n\n varying vec2 v_textureCoord;\n varying vec2 v_mapCoord;\n uniform vec4 ${ut};\n uniform float ${lt};\n uniform float ${pt};\n uniform float ${mt};\n uniform float ${ht};\n uniform float ${dt};\n\n ${a.join("\n")}\n\n ${c.join("\n")}\n\n void main() {\n if (\n v_mapCoord[0] < ${ut}[0] ||\n v_mapCoord[1] < ${ut}[1] ||\n v_mapCoord[0] > ${ut}[2] ||\n v_mapCoord[1] > ${ut}[3]\n ) {\n discard;\n }\n\n vec4 color = texture2D(${ft}[0], v_textureCoord);\n\n ${i.join("\n")}\n\n gl_FragColor = color;\n gl_FragColor.rgb *= gl_FragColor.a;\n gl_FragColor *= ${lt};\n }`,uniforms:s,paletteTextures:n.paletteTextures}}class Nt extends n.A{constructor(t){const e=(t=t?Object.assign({},t):{}).style||{};delete t.style,super(t),this.sources_=t.sources,this.renderedSource_=null,this.renderedResolution_=NaN,this.style_=e,this.styleVariables_=this.style_.variables||{},this.addChangeListener(i.A.SOURCE,this.handleSourceUpdate_)}getSources(t,e){const r=this.getSource();return this.sources_?"function"==typeof this.sources_?this.sources_(t,e):this.sources_:r?[r]:[]}getRenderSource(){return this.renderedSource_||this.getSource()}getSourceState(){const t=this.getRenderSource();return t?t.getState():"undefined"}handleSourceUpdate_(){this.hasRenderer()&&this.getRenderer().clearCache();const t=this.getSource();if(t)if("loading"===t.getState()){const e=()=>{"ready"===t.getState()&&(t.removeEventListener("change",e),this.setStyle(this.style_))};t.addEventListener("change",e)}else this.setStyle(this.style_)}getSourceBandCount_(){const t=Number.MAX_SAFE_INTEGER,e=this.getSources([-t,-t,t,t],t);return e&&e.length&&"bandCount"in e[0]?e[0].bandCount:4}createRenderer(){const t=jt(this.style_,this.getSourceBandCount_());return new wt(this,{vertexShader:t.vertexShader,fragmentShader:t.fragmentShader,uniforms:t.uniforms,cacheSize:this.getCacheSize(),paletteTextures:t.paletteTextures})}renderSources(t,e){const r=this.getRenderer();let n;for(let i=0,s=e.length;i<s;++i)this.renderedSource_=e[i],r.prepareFrame(t)&&(n=r.renderFrame(t));return n}render(t,e){this.rendered=!0;const r=t.viewState,n=this.getSources(t.extent,r.resolution);let i=!0;for(let t=0,e=n.length;t<e;++t){const e=n[t],r=e.getState();if("loading"==r){const t=()=>{"ready"==e.getState()&&(e.removeEventListener("change",t),this.changed())};e.addEventListener("change",t)}i=i&&"ready"==r}const s=this.renderSources(t,n);if(this.getRenderer().renderComplete&&i)return this.renderedResolution_=r.resolution,s;if(this.renderedResolution_>.5*r.resolution){const e=this.getSources(t.extent,this.renderedResolution_).filter((t=>!n.includes(t)));if(e.length>0)return this.renderSources(t,e)}return s}setStyle(t){if(this.styleVariables_=t.variables||{},this.style_=t,this.hasRenderer()){const t=jt(this.style_,this.getSourceBandCount_());this.getRenderer().reset({vertexShader:t.vertexShader,fragmentShader:t.fragmentShader,uniforms:t.uniforms,paletteTextures:t.paletteTextures}),this.changed()}}updateStyleVariables(t){Object.assign(this.styleVariables_,t),this.changed()}}Nt.prototype.dispose;const Gt=Nt},72475:(t,e,r)=>{"use strict";function n(t,e,r){return Math.min(Math.max(t,e),r)}function i(t,e,r,n,i,o){const a=i-r,l=o-n;if(0!==a||0!==l){const s=((t-r)*a+(e-n)*l)/(a*a+l*l);s>1?(r=i,n=o):s>0&&(r+=a*s,n+=l*s)}return s(t,e,r,n)}function s(t,e,r,n){const i=r-t,s=n-e;return i*i+s*s}function o(t){const e=t.length;for(let r=0;r<e;r++){let n=r,i=Math.abs(t[r][r]);for(let s=r+1;s<e;s++){const e=Math.abs(t[s][r]);e>i&&(i=e,n=s)}if(0===i)return null;const s=t[n];t[n]=t[r],t[r]=s;for(let n=r+1;n<e;n++){const i=-t[n][r]/t[r][r];for(let s=r;s<e+1;s++)r==s?t[n][s]=0:t[n][s]+=i*t[r][s]}}const r=new Array(e);for(let n=e-1;n>=0;n--){r[n]=t[n][e]/t[n][n];for(let i=n-1;i>=0;i--)t[i][e]-=t[i][n]*r[n]}return r}function a(t){return t*Math.PI/180}function l(t,e){const r=t%e;return r*e<0?r+e:r}function c(t,e,r){return t+r*(e-t)}function u(t,e){const r=Math.pow(10,e);return Math.round(t*r)/r}function h(t,e){return Math.floor(u(t,e))}function d(t,e){return Math.ceil(u(t,e))}r.d(e,{Cc:()=>c,KU:()=>o,Mg:()=>u,Q1:()=>i,RI:()=>h,eh:()=>a,hG:()=>s,mk:()=>d,qE:()=>n,xP:()=>l})},82048:(t,e,r)=>{"use strict";function n(t){for(const e in t)delete t[e]}function i(t){let e;for(e in t)return!1;return!e}r.d(e,{I:()=>n,p:()=>i})},12940:(t,e,r)=>{"use strict";r.d(e,{Ig:()=>m.I,MF:()=>n.A,Av:()=>I,RJ:()=>P,tI:()=>F,Rb:()=>k,Ad:()=>V,SD:()=>K,Jt:()=>O,hO:()=>R,RG:()=>N,FO:()=>j,Tf:()=>U,WP:()=>L,te:()=>B,JR:()=>q,vN:()=>W,pd:()=>G});var n=r(55528);const i=6378137,s=Math.PI*i,o=[-s,-s,s,s],a=[-180,-85,180,85],l=i*Math.log(Math.tan(Math.PI/2));class c extends n.A{constructor(t){super({code:t,units:"m",extent:o,global:!0,worldExtent:a,getPointResolution:function(t,e){return t/Math.cosh(e[1]/i)}})}}const u=[new c("EPSG:3857"),new c("EPSG:102100"),new c("EPSG:102113"),new c("EPSG:900913"),new c("http://www.opengis.net/def/crs/EPSG/0/3857"),new c("http://www.opengis.net/gml/srs/epsg.xml#3857")];const h=[-180,-90,180,90],d=6378137*Math.PI/180;class f extends n.A{constructor(t,e){super({code:t,units:"degrees",extent:h,axisOrientation:e,global:!0,metersPerUnit:d,worldExtent:h})}}const p=[new f("CRS:84"),new f("EPSG:4326","neu"),new f("urn:ogc:def:crs:OGC:1.3:CRS84"),new f("urn:ogc:def:crs:OGC:2:84"),new f("http://www.opengis.net/def/crs/OGC/1.3/CRS84"),new f("http://www.opengis.net/gml/srs/epsg.xml#4326","neu"),new f("http://www.opengis.net/def/crs/EPSG/0/4326","neu")];var m=r(82410);let g={},y={};function v(t,e,r){const n=t.getCode(),i=e.getCode();n in y||(y[n]={}),y[n][i]=r}var _=r(44509),b=r(72475),w=r(9535);const x=6371008.8;function E(t,e,r){r=r||x;const n=(0,b.eh)(t[1]),i=(0,b.eh)(e[1]),s=(i-n)/2,o=(0,b.eh)(e[0]-t[0])/2,a=Math.sin(s)*Math.sin(s)+Math.sin(o)*Math.sin(o)*Math.cos(n)*Math.cos(i);return 2*r*Math.atan2(Math.sqrt(a),Math.sqrt(1-a))}var S=r(96372);let A=!0;function P(t){A=!(void 0===t||t)}function T(t,e){if(void 0!==e)for(let r=0,n=t.length;r<n;++r)e[r]=t[r];else e=t.slice();return e}function C(t,e){if(void 0!==e&&t!==e){for(let r=0,n=t.length;r<n;++r)e[r]=t[r];t=e}return t}function M(t){!function(t,e){g[t]=e}(t.getCode(),t),v(t,t,T)}function O(t){return"string"==typeof t?g[e=t]||g[e.replace(/urn:(x-)?ogc:def:crs:EPSG:(.*:)?(\w+)$/,"EPSG:$3")]||null:t||null;var e}function R(t,e,r,n){let i;const s=(t=O(t)).getPointResolutionFunc();if(s){if(i=s(e,r),n&&n!==t.getUnits()){const e=t.getMetersPerUnit();e&&(i=i*e/m.I[n])}}else{const s=t.getUnits();if("degrees"==s&&!n||"degrees"==n)i=e;else{const o=j(t,O("EPSG:4326"));if(o===C&&"degrees"!==s)i=e*t.getMetersPerUnit();else{let t=[r[0]-e/2,r[1],r[0]+e/2,r[1],r[0],r[1]-e/2,r[0],r[1]+e/2];t=o(t,t,2),i=(E(t.slice(0,2),t.slice(2,4))+E(t.slice(4,6),t.slice(6,8)))/2}const a=n?m.I[n]:t.getMetersPerUnit();void 0!==a&&(i/=a)}}return i}function D(t){!function(t){t.forEach(M)}(t),t.forEach((function(e){t.forEach((function(t){e!==t&&v(e,t,T)}))}))}function I(t,e){return t?"string"==typeof t?O(t):t:O(e)}function k(t,e){return P(),G(t,"EPSG:4326",void 0!==e?e:"EPSG:3857")}function L(t,e){const r=G(t,void 0!==e?e:"EPSG:3857","EPSG:4326"),n=r[0];return(n<-180||n>180)&&(r[0]=(0,b.xP)(n+180,360)-180),r}function F(t,e){if(t===e)return!0;const r=t.getUnits()===e.getUnits();return(t.getCode()===e.getCode()||j(t,e)===T)&&r}function j(t,e){let r=function(t,e){let r;return t in y&&e in y[t]&&(r=y[t][e]),r}(t.getCode(),e.getCode());return r||(r=C),r}function N(t,e){return j(O(t),O(e))}function G(t,e,r){return N(e,r)(t,void 0,t.length)}function $(t,e,r,n){const i=N(e,r);return(0,_.NW)(t,i,void 0,n)}let z=null;function U(){return z}function B(t,e){return z?G(t,e,z):t}function V(t,e){return z?G(t,z,e):(A&&!(0,w.aI)(t,[0,0])&&t[0]>=-180&&t[0]<=180&&t[1]>=-90&&t[1]<=90&&(A=!1,(0,S.R8)("Call useGeographic() from ol/proj once to work with [longitude, latitude] coordinates.")),t)}function q(t,e){return z?$(t,e,z):t}function K(t,e){return z?$(t,z,e):t}function W(t,e){if(!z)return t;const r=O(e).getMetersPerUnit(),n=z.getMetersPerUnit();return r&&n?t*r/n:t}var H,Y,X;D(u),D(p),H=u,Y=function(t,e,r,n){const o=t.length;r=r>1?r:2,n=n??r,void 0===e&&(e=r>2?t.slice():new Array(o));for(let r=0;r<o;r+=n){e[r]=s*t[r]/180;let n=i*Math.log(Math.tan(Math.PI*(+t[r+1]+90)/360));n>l?n=l:n<-l&&(n=-l),e[r+1]=n}return e},X=function(t,e,r,n){const o=t.length;r=r>1?r:2,n=n??r,void 0===e&&(e=r>2?t.slice():new Array(o));for(let r=0;r<o;r+=n)e[r]=180*t[r]/s,e[r+1]=360*Math.atan(Math.exp(t[r+1]/i))/Math.PI-90;return e},p.forEach((function(t){H.forEach((function(e){v(t,e,Y),v(e,t,X)}))}))},55528:(t,e,r)=>{"use strict";r.d(e,{A:()=>i});var n=r(82410);const i=class{constructor(t){this.code_=t.code,this.units_=t.units,this.extent_=void 0!==t.extent?t.extent:null,this.worldExtent_=void 0!==t.worldExtent?t.worldExtent:null,this.axisOrientation_=void 0!==t.axisOrientation?t.axisOrientation:"enu",this.global_=void 0!==t.global&&t.global,this.canWrapX_=!(!this.global_||!this.extent_),this.getPointResolutionFunc_=t.getPointResolution,this.defaultTileGrid_=null,this.metersPerUnit_=t.metersPerUnit}canWrapX(){return this.canWrapX_}getCode(){return this.code_}getExtent(){return this.extent_}getUnits(){return this.units_}getMetersPerUnit(){return this.metersPerUnit_||n.I[this.units_]}getWorldExtent(){return this.worldExtent_}getAxisOrientation(){return this.axisOrientation_}isGlobal(){return this.global_}setGlobal(t){this.global_=t,this.canWrapX_=!(!t||!this.extent_)}getDefaultTileGrid(){return this.defaultTileGrid_}setDefaultTileGrid(t){this.defaultTileGrid_=t}setExtent(t){this.extent_=t,this.canWrapX_=!(!this.global_||!t)}setWorldExtent(t){this.worldExtent_=t}setGetPointResolution(t){this.getPointResolutionFunc_=t}getPointResolutionFunc(){return this.getPointResolutionFunc_}}},82410:(t,e,r)=>{"use strict";r.d(e,{I:()=>s,q:()=>i});const n={9001:"m",9002:"ft",9003:"us-ft",9101:"radians",9102:"degrees"};function i(t){return n[t]}const s={radians:6370997/(2*Math.PI),degrees:2*Math.PI*6370997/360,ft:.3048,m:1,"us-ft":1200/3937}},3094:(t,e,r)=>{"use strict";r.d(e,{A:()=>s});var n=r(37283);class i extends n.Ay{constructor(t,e,r,n){super(t),this.inversePixelTransform=e,this.frameState=r,this.context=n}}const s=i},45630:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={PRERENDER:"prerender",POSTRENDER:"postrender",PRECOMPOSE:"precompose",POSTCOMPOSE:"postcompose",RENDERCOMPLETE:"rendercomplete"}},28528:(t,e,r)=>{"use strict";r.d(e,{Ay:()=>g});var n=r(37377),i=r(44509),s=r(9761),o=r(30444),a=r(93350),l=r(12940),c=r(65709),u=r(82611),h=r(77055),d=r(97440),f=r(70772);const p=(0,n.vt)();class m{constructor(t,e,r,n,i,s){this.styleFunction,this.extent_,this.id_=s,this.type_=t,this.flatCoordinates_=e,this.flatInteriorPoints_=null,this.flatMidpoints_=null,this.ends_=r||null,this.properties_=i,this.squaredTolerance_,this.stride_=n,this.simplifiedGeometry_}get(t){return this.properties_[t]}getExtent(){return this.extent_||(this.extent_="Point"===this.type_?(0,i.dP)(this.flatCoordinates_):(0,i.Vy)(this.flatCoordinates_,0,this.flatCoordinates_.length,2)),this.extent_}getFlatInteriorPoint(){if(!this.flatInteriorPoints_){const t=(0,i.q1)(this.getExtent());this.flatInteriorPoints_=(0,a.J)(this.flatCoordinates_,0,this.ends_,2,t,0)}return this.flatInteriorPoints_}getFlatInteriorPoints(){if(!this.flatInteriorPoints_){const t=(0,c.yJ)(this.flatCoordinates_,this.ends_),e=(0,h.C)(this.flatCoordinates_,0,t,2);this.flatInteriorPoints_=(0,a.p)(this.flatCoordinates_,0,t,2,e)}return this.flatInteriorPoints_}getFlatMidpoint(){return this.flatMidpoints_||(this.flatMidpoints_=(0,u.SH)(this.flatCoordinates_,0,this.flatCoordinates_.length,2,.5)),this.flatMidpoints_}getFlatMidpoints(){if(!this.flatMidpoints_){this.flatMidpoints_=[];const t=this.flatCoordinates_;let e=0;const r=this.ends_;for(let n=0,i=r.length;n<i;++n){const i=r[n],s=(0,u.SH)(t,e,i,2,.5);(0,o.X$)(this.flatMidpoints_,s),e=i}}return this.flatMidpoints_}getId(){return this.id_}getOrientedFlatCoordinates(){return this.flatCoordinates_}getGeometry(){return this}getSimplifiedGeometry(t){return this}simplifyTransformed(t,e){return this}getProperties(){return this.properties_}getPropertiesInternal(){return this.properties_}getStride(){return this.stride_}getStyleFunction(){return this.styleFunction}getType(){return this.type_}transform(t){const e=(t=(0,l.Jt)(t)).getExtent(),r=t.getWorldExtent();if(e&&r){const t=(0,i.Oq)(r)/(0,i.Oq)(e);(0,n.Zz)(p,r[0],r[3],t,-t,0,0,0),(0,f.Rc)(this.flatCoordinates_,0,this.flatCoordinates_.length,2,p,this.flatCoordinates_)}}applyTransform(t){t(this.flatCoordinates_,this.flatCoordinates_,this.stride_)}clone(){return new m(this.type_,this.flatCoordinates_.slice(),this.ends_?.slice(),this.stride_,Object.assign({},this.properties_),this.id_)}getEnds(){return this.ends_}enableSimplifyTransformed(){return this.simplifyTransformed=(0,d.B4)(((t,e)=>{if(t===this.squaredTolerance_)return this.simplifiedGeometry_;this.simplifiedGeometry_=this.clone(),e&&this.simplifiedGeometry_.applyTransform(e);const r=this.simplifiedGeometry_.getFlatCoordinates();let n;switch(this.type_){case"LineString":r.length=(0,s.P4)(r,0,this.simplifiedGeometry_.flatCoordinates_.length,this.simplifiedGeometry_.stride_,t,r,0),n=[r.length];break;case"MultiLineString":n=[],r.length=(0,s.AL)(r,0,this.simplifiedGeometry_.ends_,this.simplifiedGeometry_.stride_,t,r,0,n);break;case"Polygon":n=[],r.length=(0,s.Hg)(r,0,this.simplifiedGeometry_.ends_,this.simplifiedGeometry_.stride_,Math.sqrt(t),r,0,n)}return n&&(this.simplifiedGeometry_=new m(this.type_,r,n,2,this.properties_,this.id_)),this.squaredTolerance_=t,this.simplifiedGeometry_})),this}}m.prototype.getFlatCoordinates=m.prototype.getOrientedFlatCoordinates;const g=m},16724:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n=class{drawCustom(t,e,r,n,i){}drawGeometry(t){}setStyle(t){}drawCircle(t,e,r){}drawFeature(t,e,r){}drawGeometryCollection(t,e,r){}drawLineString(t,e,r){}drawMultiLineString(t,e,r){}drawMultiPoint(t,e,r){}drawMultiPolygon(t,e,r){}drawPoint(t,e,r){}drawPolygon(t,e,r){}drawText(t,e,r){}setFillStrokeStyle(t,e){}setImageStyle(t,e){}setTextStyle(t,e){}}},33976:(t,e,r)=>{"use strict";r.d(e,{Jw:()=>O,M8:()=>y,MY:()=>g,NT:()=>m,Oq:()=>h,TA:()=>C,Tq:()=>v,ZV:()=>l,_K:()=>f,_m:()=>u,aq:()=>_,eL:()=>p,fZ:()=>S,jT:()=>M,qY:()=>c,vk:()=>d,yY:()=>b});var n=r(72614),i=r(66993),s=r(82048),o=r(83085),a=r(71686);const l="10px sans-serif",c="#000",u="round",h=[],d=0,f="round",p=10,m="#000",g="center",y="middle",v=[0,0,0,0],_=1,b=new n.A;let w,x=null;const E={},S=function(){const t="32px ",e=["monospace","serif"],r=e.length,n="wmytzilWMYTZIL@#/&?$%10";let i,o;function l(i,s,a){let l=!0;for(let c=0;c<r;++c){const r=e[c];if(o=T(i+" "+s+" "+t+r,n),a!=r){const e=T(i+" "+s+" "+t+a+","+r,n);l=l&&e!=o}}return!!l}function c(){let t=!0;const e=b.getKeys();for(let r=0,n=e.length;r<n;++r){const n=e[r];if(b.get(n)<100){const[e,r,i]=n.split("\n");l(e,r,i)?((0,s.I)(E),x=null,w=void 0,b.set(n,100)):(b.set(n,b.get(n)+1,!0),t=!1)}}t&&(clearInterval(i),i=void 0)}return function(t){const e=(0,a.K5)(t);if(!e)return;const r=e.families;for(let t=0,n=r.length;t<n;++t){const n=r[t],s=e.style+"\n"+e.weight+"\n"+n;void 0===b.get(s)&&(b.set(s,100,!0),l(e.style,e.weight,n)||(b.set(s,0,!0),void 0===i&&(i=setInterval(c,32))))}}}(),A=function(){let t;return function(e){let r=E[e];if(null==r){if(i.Wl){const t=(0,a.K5)(e),n=P(e,"Žg");r=(isNaN(Number(t.lineHeight))?1.2:Number(t.lineHeight))*(n.actualBoundingBoxAscent+n.actualBoundingBoxDescent)}else t||(t=document.createElement("div"),t.innerHTML="M",t.style.minHeight="0",t.style.maxHeight="none",t.style.height="auto",t.style.padding="0",t.style.border="none",t.style.position="absolute",t.style.display="block",t.style.left="-99999px"),t.style.font=e,document.body.appendChild(t),r=t.offsetHeight,document.body.removeChild(t);E[e]=r}return r}}();function P(t,e){return x||(x=(0,o.Y)(1,1)),t!=w&&(x.font=t,w=x.font),x.measureText(e)}function T(t,e){return P(t,e).width}function C(t,e,r){if(e in r)return r[e];const n=e.split("\n").reduce(((e,r)=>Math.max(e,T(t,r))),0);return r[e]=n,n}function M(t,e){const r=[],n=[],i=[];let s=0,o=0,a=0,l=0;for(let c=0,u=e.length;c<=u;c+=2){const h=e[c];if("\n"===h||c===u){s=Math.max(s,o),i.push(o),o=0,a+=l,l=0;continue}const d=e[c+1]||t.font,f=T(d,h);r.push(f),o+=f;const p=A(d);n.push(p),l=Math.max(l,p)}return{width:s,height:a,widths:r,heights:n,lineWidths:i}}function O(t,e,r,n,i,s,o,a,l,c,u){t.save(),1!==r&&(void 0===t.globalAlpha?t.globalAlpha=t=>t.globalAlpha*=r:t.globalAlpha*=r),e&&t.transform.apply(t,e),n.contextInstructions?(t.translate(l,c),t.scale(u[0],u[1]),function(t,e){const r=t.contextInstructions;for(let t=0,n=r.length;t<n;t+=2)Array.isArray(r[t+1])?e[r[t]].apply(e,r[t+1]):e[r[t]]=r[t+1]}(n,t)):u[0]<0||u[1]<0?(t.translate(l,c),t.scale(u[0],u[1]),t.drawImage(n,i,s,o,a,0,0,o,a)):t.drawImage(n,i,s,o,a,l,c,o*u[0],a*u[1]),t.restore()}},10272:(t,e,r)=>{"use strict";r.d(e,{A:()=>d});var n=r(15675),i=r(85262),s=r(16724),o=r(67029),a=r(44509),l=r(33976),c=r(30444),u=r(35455);class h extends s.A{constructor(t,e,r,n){super(),this.tolerance=t,this.maxExtent=e,this.pixelRatio=n,this.maxLineWidth=0,this.resolution=r,this.beginGeometryInstruction1_=null,this.beginGeometryInstruction2_=null,this.bufferedMaxExtent_=null,this.instructions=[],this.coordinates=[],this.tmpCoordinate_=[],this.hitDetectionInstructions=[],this.state={}}applyPixelRatio(t){const e=this.pixelRatio;return 1==e?t:t.map((function(t){return t*e}))}appendFlatPointCoordinates(t,e){const r=this.getBufferedMaxExtent(),n=this.tmpCoordinate_,i=this.coordinates;let s=i.length;for(let o=0,l=t.length;o<l;o+=e)n[0]=t[o],n[1]=t[o+1],(0,a.Ym)(r,n)&&(i[s++]=n[0],i[s++]=n[1]);return s}appendFlatLineCoordinates(t,e,r,n,s,o){const l=this.coordinates;let c=l.length;const u=this.getBufferedMaxExtent();o&&(e+=n);let h=t[e],d=t[e+1];const f=this.tmpCoordinate_;let p,m,g,y=!0;for(p=e+n;p<r;p+=n)f[0]=t[p],f[1]=t[p+1],g=(0,a.vz)(u,f),g!==m?(y&&(l[c++]=h,l[c++]=d,y=!1),l[c++]=f[0],l[c++]=f[1]):g===i.A.INTERSECTING?(l[c++]=f[0],l[c++]=f[1],y=!1):y=!0,h=f[0],d=f[1],m=g;return(s&&y||p===e+n)&&(l[c++]=h,l[c++]=d),c}drawCustomCoordinates_(t,e,r,n,i){for(let s=0,o=r.length;s<o;++s){const o=r[s],a=this.appendFlatLineCoordinates(t,e,o,n,!1,!1);i.push(a),e=o}return e}drawCustom(t,e,r,i,s){this.beginGeometry(t,e,s);const o=t.getType(),a=t.getStride(),l=this.coordinates.length;let c,h,d,f,p;switch(o){case"MultiPolygon":c=t.getOrientedFlatCoordinates(),f=[];const e=t.getEndss();p=0;for(let t=0,r=e.length;t<r;++t){const r=[];p=this.drawCustomCoordinates_(c,p,e[t],a,r),f.push(r)}this.instructions.push([n.Ay.CUSTOM,l,f,t,r,u.Dz,s]),this.hitDetectionInstructions.push([n.Ay.CUSTOM,l,f,t,i||r,u.Dz,s]);break;case"Polygon":case"MultiLineString":d=[],c="Polygon"==o?t.getOrientedFlatCoordinates():t.getFlatCoordinates(),p=this.drawCustomCoordinates_(c,0,t.getEnds(),a,d),this.instructions.push([n.Ay.CUSTOM,l,d,t,r,u.cD,s]),this.hitDetectionInstructions.push([n.Ay.CUSTOM,l,d,t,i||r,u.cD,s]);break;case"LineString":case"Circle":c=t.getFlatCoordinates(),h=this.appendFlatLineCoordinates(c,0,c.length,a,!1,!1),this.instructions.push([n.Ay.CUSTOM,l,h,t,r,u.n2,s]),this.hitDetectionInstructions.push([n.Ay.CUSTOM,l,h,t,i||r,u.n2,s]);break;case"MultiPoint":c=t.getFlatCoordinates(),h=this.appendFlatPointCoordinates(c,a),h>l&&(this.instructions.push([n.Ay.CUSTOM,l,h,t,r,u.n2,s]),this.hitDetectionInstructions.push([n.Ay.CUSTOM,l,h,t,i||r,u.n2,s]));break;case"Point":c=t.getFlatCoordinates(),this.coordinates.push(c[0],c[1]),h=this.coordinates.length,this.instructions.push([n.Ay.CUSTOM,l,h,t,r,void 0,s]),this.hitDetectionInstructions.push([n.Ay.CUSTOM,l,h,t,i||r,void 0,s])}this.endGeometry(e)}beginGeometry(t,e,r){this.beginGeometryInstruction1_=[n.Ay.BEGIN_GEOMETRY,e,0,t,r],this.instructions.push(this.beginGeometryInstruction1_),this.beginGeometryInstruction2_=[n.Ay.BEGIN_GEOMETRY,e,0,t,r],this.hitDetectionInstructions.push(this.beginGeometryInstruction2_)}finish(){return{instructions:this.instructions,hitDetectionInstructions:this.hitDetectionInstructions,coordinates:this.coordinates}}reverseHitDetectionInstructions(){const t=this.hitDetectionInstructions;let e;t.reverse();const r=t.length;let i,s,o=-1;for(e=0;e<r;++e)i=t[e],s=i[0],s==n.Ay.END_GEOMETRY?o=e:s==n.Ay.BEGIN_GEOMETRY&&(i[2]=e,(0,c.gI)(this.hitDetectionInstructions,o,e),o=-1)}setFillStrokeStyle(t,e){const r=this.state;if(t){const e=t.getColor();r.fillPatternScale=e&&"object"==typeof e&&"src"in e?this.pixelRatio:1,r.fillStyle=(0,o.F)(e||l.qY)}else r.fillStyle=void 0;if(e){const t=e.getColor();r.strokeStyle=(0,o.F)(t||l.NT);const n=e.getLineCap();r.lineCap=void 0!==n?n:l._m;const i=e.getLineDash();r.lineDash=i?i.slice():l.Oq;const s=e.getLineDashOffset();r.lineDashOffset=s||l.vk;const a=e.getLineJoin();r.lineJoin=void 0!==a?a:l._K;const c=e.getWidth();r.lineWidth=void 0!==c?c:l.aq;const u=e.getMiterLimit();r.miterLimit=void 0!==u?u:l.eL,r.lineWidth>this.maxLineWidth&&(this.maxLineWidth=r.lineWidth,this.bufferedMaxExtent_=null)}else r.strokeStyle=void 0,r.lineCap=void 0,r.lineDash=null,r.lineDashOffset=void 0,r.lineJoin=void 0,r.lineWidth=void 0,r.miterLimit=void 0}createFill(t){const e=t.fillStyle,r=[n.Ay.SET_FILL_STYLE,e];return"string"!=typeof e&&r.push(t.fillPatternScale),r}applyStroke(t){this.instructions.push(this.createStroke(t))}createStroke(t){return[n.Ay.SET_STROKE_STYLE,t.strokeStyle,t.lineWidth*this.pixelRatio,t.lineCap,t.lineJoin,t.miterLimit,this.applyPixelRatio(t.lineDash),t.lineDashOffset*this.pixelRatio]}updateFillStyle(t,e){const r=t.fillStyle;"string"==typeof r&&t.currentFillStyle==r||(void 0!==r&&this.instructions.push(e.call(this,t)),t.currentFillStyle=r)}updateStrokeStyle(t,e){const r=t.strokeStyle,n=t.lineCap,i=t.lineDash,s=t.lineDashOffset,o=t.lineJoin,a=t.lineWidth,l=t.miterLimit;(t.currentStrokeStyle!=r||t.currentLineCap!=n||i!=t.currentLineDash&&!(0,c.aI)(t.currentLineDash,i)||t.currentLineDashOffset!=s||t.currentLineJoin!=o||t.currentLineWidth!=a||t.currentMiterLimit!=l)&&(void 0!==r&&e.call(this,t),t.currentStrokeStyle=r,t.currentLineCap=n,t.currentLineDash=i,t.currentLineDashOffset=s,t.currentLineJoin=o,t.currentLineWidth=a,t.currentMiterLimit=l)}endGeometry(t){this.beginGeometryInstruction1_[2]=this.instructions.length,this.beginGeometryInstruction1_=null,this.beginGeometryInstruction2_[2]=this.hitDetectionInstructions.length,this.beginGeometryInstruction2_=null;const e=[n.Ay.END_GEOMETRY,t];this.instructions.push(e),this.hitDetectionInstructions.push(e)}getBufferedMaxExtent(){if(!this.bufferedMaxExtent_&&(this.bufferedMaxExtent_=(0,a.o8)(this.maxExtent),this.maxLineWidth>0)){const t=this.resolution*(this.maxLineWidth+1)/2;(0,a.r)(this.bufferedMaxExtent_,t,this.bufferedMaxExtent_)}return this.bufferedMaxExtent_}}const d=h},21347:(t,e,r)=>{"use strict";r.d(e,{A:()=>g});var n=r(10272),i=r(15675),s=r(44509);class o extends n.A{constructor(t,e,r,n){super(t,e,r,n),this.hitDetectionImage_=null,this.image_=null,this.imagePixelRatio_=void 0,this.anchorX_=void 0,this.anchorY_=void 0,this.height_=void 0,this.opacity_=void 0,this.originX_=void 0,this.originY_=void 0,this.rotateWithView_=void 0,this.rotation_=void 0,this.scale_=void 0,this.width_=void 0,this.declutterMode_=void 0,this.declutterImageWithText_=void 0}drawPoint(t,e,r){if(!this.image_||this.maxExtent&&!(0,s.Ym)(this.maxExtent,t.getFlatCoordinates()))return;this.beginGeometry(t,e,r);const n=t.getFlatCoordinates(),o=t.getStride(),a=this.coordinates.length,l=this.appendFlatPointCoordinates(n,o);this.instructions.push([i.Ay.DRAW_IMAGE,a,l,this.image_,this.anchorX_*this.imagePixelRatio_,this.anchorY_*this.imagePixelRatio_,Math.ceil(this.height_*this.imagePixelRatio_),this.opacity_,this.originX_*this.imagePixelRatio_,this.originY_*this.imagePixelRatio_,this.rotateWithView_,this.rotation_,[this.scale_[0]*this.pixelRatio/this.imagePixelRatio_,this.scale_[1]*this.pixelRatio/this.imagePixelRatio_],Math.ceil(this.width_*this.imagePixelRatio_),this.declutterMode_,this.declutterImageWithText_]),this.hitDetectionInstructions.push([i.Ay.DRAW_IMAGE,a,l,this.hitDetectionImage_,this.anchorX_,this.anchorY_,this.height_,1,this.originX_,this.originY_,this.rotateWithView_,this.rotation_,this.scale_,this.width_,this.declutterMode_,this.declutterImageWithText_]),this.endGeometry(e)}drawMultiPoint(t,e,r){if(!this.image_)return;this.beginGeometry(t,e,r);const n=t.getFlatCoordinates(),o=[];for(let e=0,r=n.length;e<r;e+=t.getStride())this.maxExtent&&!(0,s.Ym)(this.maxExtent,n.slice(e,e+2))||o.push(n[e],n[e+1]);const a=this.coordinates.length,l=this.appendFlatPointCoordinates(o,2);this.instructions.push([i.Ay.DRAW_IMAGE,a,l,this.image_,this.anchorX_*this.imagePixelRatio_,this.anchorY_*this.imagePixelRatio_,Math.ceil(this.height_*this.imagePixelRatio_),this.opacity_,this.originX_*this.imagePixelRatio_,this.originY_*this.imagePixelRatio_,this.rotateWithView_,this.rotation_,[this.scale_[0]*this.pixelRatio/this.imagePixelRatio_,this.scale_[1]*this.pixelRatio/this.imagePixelRatio_],Math.ceil(this.width_*this.imagePixelRatio_),this.declutterMode_,this.declutterImageWithText_]),this.hitDetectionInstructions.push([i.Ay.DRAW_IMAGE,a,l,this.hitDetectionImage_,this.anchorX_,this.anchorY_,this.height_,1,this.originX_,this.originY_,this.rotateWithView_,this.rotation_,this.scale_,this.width_,this.declutterMode_,this.declutterImageWithText_]),this.endGeometry(e)}finish(){return this.reverseHitDetectionInstructions(),this.anchorX_=void 0,this.anchorY_=void 0,this.hitDetectionImage_=null,this.image_=null,this.imagePixelRatio_=void 0,this.height_=void 0,this.scale_=void 0,this.opacity_=void 0,this.originX_=void 0,this.originY_=void 0,this.rotateWithView_=void 0,this.rotation_=void 0,this.width_=void 0,super.finish()}setImageStyle(t,e){const r=t.getAnchor(),n=t.getSize(),i=t.getOrigin();this.imagePixelRatio_=t.getPixelRatio(this.pixelRatio),this.anchorX_=r[0],this.anchorY_=r[1],this.hitDetectionImage_=t.getHitDetectionImage(),this.image_=t.getImage(this.pixelRatio),this.height_=n[1],this.opacity_=t.getOpacity(),this.originX_=i[0],this.originY_=i[1],this.rotateWithView_=t.getRotateWithView(),this.rotation_=t.getRotation(),this.scale_=t.getScaleArray(),this.width_=n[0],this.declutterMode_=t.getDeclutterMode(),this.declutterImageWithText_=e}}const a=o;var l=r(33976);class c extends n.A{constructor(t,e,r,n){super(t,e,r,n)}drawFlatCoordinates_(t,e,r,n){const s=this.coordinates.length,o=this.appendFlatLineCoordinates(t,e,r,n,!1,!1),a=[i.Ay.MOVE_TO_LINE_TO,s,o];return this.instructions.push(a),this.hitDetectionInstructions.push(a),r}drawLineString(t,e,r){const n=this.state,s=n.strokeStyle,o=n.lineWidth;if(void 0===s||void 0===o)return;this.updateStrokeStyle(n,this.applyStroke),this.beginGeometry(t,e,r),this.hitDetectionInstructions.push([i.Ay.SET_STROKE_STYLE,n.strokeStyle,n.lineWidth,n.lineCap,n.lineJoin,n.miterLimit,l.Oq,l.vk],i.th);const a=t.getFlatCoordinates(),c=t.getStride();this.drawFlatCoordinates_(a,0,a.length,c),this.hitDetectionInstructions.push(i.VD),this.endGeometry(e)}drawMultiLineString(t,e,r){const n=this.state,s=n.strokeStyle,o=n.lineWidth;if(void 0===s||void 0===o)return;this.updateStrokeStyle(n,this.applyStroke),this.beginGeometry(t,e,r),this.hitDetectionInstructions.push([i.Ay.SET_STROKE_STYLE,n.strokeStyle,n.lineWidth,n.lineCap,n.lineJoin,n.miterLimit,l.Oq,l.vk],i.th);const a=t.getEnds(),c=t.getFlatCoordinates(),u=t.getStride();let h=0;for(let t=0,e=a.length;t<e;++t)h=this.drawFlatCoordinates_(c,h,a[t],u);this.hitDetectionInstructions.push(i.VD),this.endGeometry(e)}finish(){const t=this.state;return null!=t.lastStroke&&t.lastStroke!=this.coordinates.length&&this.instructions.push(i.VD),this.reverseHitDetectionInstructions(),this.state=null,super.finish()}applyStroke(t){null!=t.lastStroke&&t.lastStroke!=this.coordinates.length&&(this.instructions.push(i.VD),t.lastStroke=this.coordinates.length),t.lastStroke=0,super.applyStroke(t),this.instructions.push(i.th)}}const u=c;var h=r(9761);class d extends n.A{constructor(t,e,r,n){super(t,e,r,n)}drawFlatCoordinatess_(t,e,r,n){const s=this.state,o=void 0!==s.fillStyle,a=void 0!==s.strokeStyle,l=r.length;this.instructions.push(i.th),this.hitDetectionInstructions.push(i.th);for(let s=0;s<l;++s){const o=r[s],l=this.coordinates.length,c=this.appendFlatLineCoordinates(t,e,o,n,!0,!a),u=[i.Ay.MOVE_TO_LINE_TO,l,c];this.instructions.push(u),this.hitDetectionInstructions.push(u),a&&(this.instructions.push(i.kx),this.hitDetectionInstructions.push(i.kx)),e=o}return o&&(this.instructions.push(i.I5),this.hitDetectionInstructions.push(i.I5)),a&&(this.instructions.push(i.VD),this.hitDetectionInstructions.push(i.VD)),e}drawCircle(t,e,r){const n=this.state,s=n.fillStyle,o=n.strokeStyle;if(void 0===s&&void 0===o)return;this.setFillStrokeStyles_(),this.beginGeometry(t,e,r),void 0!==n.fillStyle&&this.hitDetectionInstructions.push([i.Ay.SET_FILL_STYLE,l.qY]),void 0!==n.strokeStyle&&this.hitDetectionInstructions.push([i.Ay.SET_STROKE_STYLE,n.strokeStyle,n.lineWidth,n.lineCap,n.lineJoin,n.miterLimit,l.Oq,l.vk]);const a=t.getFlatCoordinates(),c=t.getStride(),u=this.coordinates.length;this.appendFlatLineCoordinates(a,0,a.length,c,!1,!1);const h=[i.Ay.CIRCLE,u];this.instructions.push(i.th,h),this.hitDetectionInstructions.push(i.th,h),void 0!==n.fillStyle&&(this.instructions.push(i.I5),this.hitDetectionInstructions.push(i.I5)),void 0!==n.strokeStyle&&(this.instructions.push(i.VD),this.hitDetectionInstructions.push(i.VD)),this.endGeometry(e)}drawPolygon(t,e,r){const n=this.state,s=n.fillStyle,o=n.strokeStyle;if(void 0===s&&void 0===o)return;this.setFillStrokeStyles_(),this.beginGeometry(t,e,r),void 0!==n.fillStyle&&this.hitDetectionInstructions.push([i.Ay.SET_FILL_STYLE,l.qY]),void 0!==n.strokeStyle&&this.hitDetectionInstructions.push([i.Ay.SET_STROKE_STYLE,n.strokeStyle,n.lineWidth,n.lineCap,n.lineJoin,n.miterLimit,l.Oq,l.vk]);const a=t.getEnds(),c=t.getOrientedFlatCoordinates(),u=t.getStride();this.drawFlatCoordinatess_(c,0,a,u),this.endGeometry(e)}drawMultiPolygon(t,e,r){const n=this.state,s=n.fillStyle,o=n.strokeStyle;if(void 0===s&&void 0===o)return;this.setFillStrokeStyles_(),this.beginGeometry(t,e,r),void 0!==n.fillStyle&&this.hitDetectionInstructions.push([i.Ay.SET_FILL_STYLE,l.qY]),void 0!==n.strokeStyle&&this.hitDetectionInstructions.push([i.Ay.SET_STROKE_STYLE,n.strokeStyle,n.lineWidth,n.lineCap,n.lineJoin,n.miterLimit,l.Oq,l.vk]);const a=t.getEndss(),c=t.getOrientedFlatCoordinates(),u=t.getStride();let h=0;for(let t=0,e=a.length;t<e;++t)h=this.drawFlatCoordinatess_(c,h,a[t],u);this.endGeometry(e)}finish(){this.reverseHitDetectionInstructions(),this.state=null;const t=this.tolerance;if(0!==t){const e=this.coordinates;for(let r=0,n=e.length;r<n;++r)e[r]=(0,h.n$)(e[r],t)}return super.finish()}setFillStrokeStyles_(){const t=this.state;void 0!==t.fillStyle&&this.updateFillStyle(t,this.createFill),void 0!==t.strokeStyle&&this.updateStrokeStyle(t,this.applyStroke)}}const f=d;var p=r(79596);const m={Circle:f,Default:n.A,Image:a,LineString:u,Polygon:f,Text:p.A},g=class{constructor(t,e,r,n){this.tolerance_=t,this.maxExtent_=e,this.pixelRatio_=n,this.resolution_=r,this.buildersByZIndex_={}}finish(){const t={};for(const e in this.buildersByZIndex_){t[e]=t[e]||{};const r=this.buildersByZIndex_[e];for(const n in r){const i=r[n].finish();t[e][n]=i}}return t}getBuilder(t,e){const r=void 0!==t?t.toString():"0";let n=this.buildersByZIndex_[r];void 0===n&&(n={},this.buildersByZIndex_[r]=n);let i=n[e];return void 0===i&&(i=new(0,m[e])(this.tolerance_,this.maxExtent_,this.resolution_,this.pixelRatio_),n[e]=i),i}}},9539:(t,e,r)=>{"use strict";r.d(e,{y2:()=>P,$i:()=>T,x$:()=>C,Ay:()=>O});var n=r(15675),i=r(83050),s=r(79596),o=r(37377),a=r(44509),l=r(33976),c=r(72475),u=r(70772);function h(t,e,r,n,i,s,o,a,l,h,d,f){let p=t[e],m=t[e+1],g=0,y=0,v=0,_=0;function b(){g=p,y=m,p=t[e+=n],m=t[e+1],_+=v,v=Math.sqrt((p-g)*(p-g)+(m-y)*(m-y))}do{b()}while(e<r-n&&_+v<s);let w=0===v?0:(s-_)/v;const x=(0,c.Cc)(g,p,w),E=(0,c.Cc)(y,m,w),S=e-n,A=_,P=s+a*l(h,i,d);for(;e<r-n&&_+v<P;)b();w=0===v?0:(P-_)/v;const T=(0,c.Cc)(g,p,w),C=(0,c.Cc)(y,m,w);let M;if(f){const t=[x,E,T,C];(0,u.e$)(t,0,4,2,f,t,t),M=t[0]>t[2]}else M=x>T;const O=Math.PI,R=[],D=S+n===e;let I;if(v=0,_=A,p=t[e=S],m=t[e+1],D){b(),I=Math.atan2(m-y,p-g),M&&(I+=I>0?-O:O);const t=(T+x)/2,e=(C+E)/2;return R[0]=[t,e,(P-s)/2,I,i],R}for(let t=0,u=(i=i.replace(/\n/g," ")).length;t<u;){b();let f=Math.atan2(m-y,p-g);if(M&&(f+=f>0?-O:O),void 0!==I){let t=f-I;if(t+=t>O?-2*O:t<-O?2*O:0,Math.abs(t)>o)return null}I=f;const x=t;let E=0;for(;t<u;++t){const o=a*l(h,i[M?u-t-1:t],d);if(e+n<r&&_+v<s+E+o/2)break;E+=o}if(t===x)continue;const S=M?i.substring(u-x,u-t):i.substring(x,t);w=0===v?0:(s+E/2-_)/v;const A=(0,c.Cc)(g,p,w),P=(0,c.Cc)(y,m,w);R.push([A,P,E/2,f,S]),s+=E}return R}var d=r(30444),f=r(22346);const p=(0,a.S5)(),m=[],g=[],y=[],v=[];function _(t){return t[3].declutterBox}const b=new RegExp("["+String.fromCharCode(1425)+"-"+String.fromCharCode(2303)+String.fromCharCode(64285)+"-"+String.fromCharCode(65023)+String.fromCharCode(65136)+"-"+String.fromCharCode(65276)+String.fromCharCode(67584)+"-"+String.fromCharCode(69631)+String.fromCharCode(124928)+"-"+String.fromCharCode(126975)+"]");function w(t,e){return"start"===e?e=b.test(t)?"right":"left":"end"===e&&(e=b.test(t)?"left":"right"),s.E[e]}function x(t,e,r){return r>0&&t.push("\n",""),t.push(e,""),t}const E=class{constructor(t,e,r,n,s){this.overlaps=r,this.pixelRatio=e,this.resolution=t,this.alignAndScaleFill_,this.instructions=n.instructions,this.coordinates=n.coordinates,this.coordinateCache_={},this.renderedTransform_=(0,o.vt)(),this.hitDetectionInstructions=n.hitDetectionInstructions,this.pixelCoordinates_=null,this.viewRotation_=0,this.fillStates=n.fillStates||{},this.strokeStates=n.strokeStates||{},this.textStates=n.textStates||{},this.widths_={},this.labels_={},this.zIndexContext_=s?new i.A:null}getZIndexContext(){return this.zIndexContext_}createLabel(t,e,r,n){const i=t+e+r+n;if(this.labels_[i])return this.labels_[i];const o=n?this.strokeStates[n]:null,a=r?this.fillStates[r]:null,c=this.textStates[e],u=this.pixelRatio,h=[c.scale[0]*u,c.scale[1]*u],d=c.justify?s.E[c.justify]:w(Array.isArray(t)?t[0]:t,c.textAlign||l.MY),f=n&&o.lineWidth?o.lineWidth:0,p=Array.isArray(t)?t:String(t).split("\n").reduce(x,[]),{width:m,height:g,widths:y,heights:v,lineWidths:_}=(0,l.jT)(c,p),b=m+f,E=[],S=(b+2)*h[0],A=(g+f)*h[1],P={width:S<0?Math.floor(S):Math.ceil(S),height:A<0?Math.floor(A):Math.ceil(A),contextInstructions:E};1==h[0]&&1==h[1]||E.push("scale",h),n&&(E.push("strokeStyle",o.strokeStyle),E.push("lineWidth",f),E.push("lineCap",o.lineCap),E.push("lineJoin",o.lineJoin),E.push("miterLimit",o.miterLimit),E.push("setLineDash",[o.lineDash]),E.push("lineDashOffset",o.lineDashOffset)),r&&E.push("fillStyle",a.fillStyle),E.push("textBaseline","middle"),E.push("textAlign","center");const T=.5-d;let C=d*b+T*f;const M=[],O=[];let R,D=0,I=0,k=0,L=0;for(let t=0,e=p.length;t<e;t+=2){const e=p[t];if("\n"===e){I+=D,D=0,C=d*b+T*f,++L;continue}const i=p[t+1]||c.font;i!==R&&(n&&M.push("font",i),r&&O.push("font",i),R=i),D=Math.max(D,v[k]);const s=[e,C+T*y[k]+d*(y[k]-_[L]),.5*(f+D)+I];C+=y[k],n&&M.push("strokeText",s),r&&O.push("fillText",s),++k}return Array.prototype.push.apply(E,M),Array.prototype.push.apply(E,O),this.labels_[i]=P,P}replayTextBackground_(t,e,r,n,i,s,o){t.beginPath(),t.moveTo.apply(t,e),t.lineTo.apply(t,r),t.lineTo.apply(t,n),t.lineTo.apply(t,i),t.lineTo.apply(t,e),s&&(this.alignAndScaleFill_=s[2],this.fill_(t)),o&&(this.setStrokeStyle_(t,o),t.stroke())}calculateImageOrLabelDimensions_(t,e,r,n,i,s,l,c,u,h,d,f,_,b,w,x){let E=r-(l*=f[0]),S=n-(c*=f[1]);const A=i+u>t?t-u:i,P=s+h>e?e-h:s,T=b[3]+A*f[0]+b[1],C=b[0]+P*f[1]+b[2],M=E-b[3],O=S-b[0];let R;return(w||0!==d)&&(m[0]=M,v[0]=M,m[1]=O,g[1]=O,g[0]=M+T,y[0]=g[0],y[1]=O+C,v[1]=y[1]),0!==d?(R=(0,o.Zz)((0,o.vt)(),r,n,1,1,d,-r,-n),(0,o.Bb)(R,m),(0,o.Bb)(R,g),(0,o.Bb)(R,y),(0,o.Bb)(R,v),(0,a.N)(Math.min(m[0],g[0],y[0],v[0]),Math.min(m[1],g[1],y[1],v[1]),Math.max(m[0],g[0],y[0],v[0]),Math.max(m[1],g[1],y[1],v[1]),p)):(0,a.N)(Math.min(M,M+T),Math.min(O,O+C),Math.max(M,M+T),Math.max(O,O+C),p),_&&(E=Math.round(E),S=Math.round(S)),{drawImageX:E,drawImageY:S,drawImageW:A,drawImageH:P,originX:u,originY:h,declutterBox:{minX:p[0],minY:p[1],maxX:p[2],maxY:p[3],value:x},canvasTransform:R,scale:f}}replayImageOrLabel_(t,e,r,n,i,s,o){const a=!(!s&&!o),c=n.declutterBox,u=o?o[2]*n.scale[0]/2:0;return c.minX-u<=e[0]&&c.maxX+u>=0&&c.minY-u<=e[1]&&c.maxY+u>=0&&(a&&this.replayTextBackground_(t,m,g,y,v,s,o),(0,l.Jw)(t,n.canvasTransform,i,r,n.originX,n.originY,n.drawImageW,n.drawImageH,n.drawImageX,n.drawImageY,n.scale)),!0}fill_(t){const e=this.alignAndScaleFill_;if(e){const r=(0,o.Bb)(this.renderedTransform_,[0,0]),n=512*this.pixelRatio;t.save(),t.translate(r[0]%n,r[1]%n),1!==e&&t.scale(e,e),t.rotate(this.viewRotation_)}t.fill(),e&&t.restore()}setStrokeStyle_(t,e){t.strokeStyle=e[1],t.lineWidth=e[2],t.lineCap=e[3],t.lineJoin=e[4],t.miterLimit=e[5],t.lineDashOffset=e[7],t.setLineDash(e[6])}drawLabelWithPointPlacement_(t,e,r,n){const i=this.textStates[e],o=this.createLabel(t,e,n,r),a=this.strokeStates[r],c=this.pixelRatio,u=w(Array.isArray(t)?t[0]:t,i.textAlign||l.MY),h=s.E[i.textBaseline||l.M8],d=a&&a.lineWidth?a.lineWidth:0;return{label:o,anchorX:u*(o.width/c-2*i.scale[0])+2*(.5-u)*d,anchorY:h*o.height/c+2*(.5-h)*d}}execute_(t,e,r,i,s,c,p,m){const g=this.zIndexContext_;let y;this.pixelCoordinates_&&(0,d.aI)(r,this.renderedTransform_)?y=this.pixelCoordinates_:(this.pixelCoordinates_||(this.pixelCoordinates_=[]),y=(0,u.Rc)(this.coordinates,0,this.coordinates.length,2,r,this.pixelCoordinates_),(0,o.k3)(this.renderedTransform_,r));let v=0;const b=i.length;let x,E,S,A,P,T,C,M,O,R,D,I,k,L=0,F=0,j=0,N=null,G=null;const $=this.coordinateCache_,z=this.viewRotation_,U=Math.round(1e12*Math.atan2(-r[1],r[0]))/1e12,B={context:t,pixelRatio:this.pixelRatio,resolution:this.resolution,rotation:z},V=this.instructions!=i||this.overlaps?0:200;let q,K,W,H;for(;v<b;){const r=i[v];switch(r[0]){case n.Ay.BEGIN_GEOMETRY:q=r[1],H=r[3],q.getGeometry()?void 0===p||(0,a.HY)(p,H.getExtent())?++v:v=r[2]+1:v=r[2],g&&(g.zIndex=r[4]);break;case n.Ay.BEGIN_PATH:F>V&&(this.fill_(t),F=0),j>V&&(t.stroke(),j=0),F||j||(t.beginPath(),P=NaN,T=NaN),++v;break;case n.Ay.CIRCLE:L=r[1];const i=y[L],o=y[L+1],u=y[L+2]-i,d=y[L+3]-o,b=Math.sqrt(u*u+d*d);t.moveTo(i+b,o),t.arc(i,o,b,0,2*Math.PI,!0),++v;break;case n.Ay.CLOSE_PATH:t.closePath(),++v;break;case n.Ay.CUSTOM:L=r[1],x=r[2];const Y=r[3],X=r[4],Z=r[5];B.geometry=Y,B.feature=q,v in $||($[v]=[]);const J=$[v];Z?Z(y,L,x,2,J):(J[0]=y[L],J[1]=y[L+1],J.length=2),g&&(g.zIndex=r[6]),X(J,B),++v;break;case n.Ay.DRAW_IMAGE:L=r[1],x=r[2],O=r[3],E=r[4],S=r[5];let Q=r[6];const tt=r[7],et=r[8],rt=r[9],nt=r[10];let it=r[11];const st=r[12];let ot=r[13];A=r[14]||"declutter";const at=r[15];if(!O&&r.length>=20){R=r[19],D=r[20],I=r[21],k=r[22];const t=this.drawLabelWithPointPlacement_(R,D,I,k);O=t.label,r[3]=O;const e=r[23];E=(t.anchorX-e)*this.pixelRatio,r[4]=E;const n=r[24];S=(t.anchorY-n)*this.pixelRatio,r[5]=S,Q=O.height,r[6]=Q,ot=O.width,r[13]=ot}let lt,ct,ut,ht;r.length>25&&(lt=r[25]),r.length>17?(ct=r[16],ut=r[17],ht=r[18]):(ct=l.Tq,ut=!1,ht=!1),nt&&U?it+=z:nt||U||(it-=z);let dt=0;for(;L<x;L+=2){if(lt&&lt[dt++]<ot/this.pixelRatio)continue;const r=this.calculateImageOrLabelDimensions_(O.width,O.height,y[L],y[L+1],ot,Q,E,S,et,rt,it,st,s,ct,ut||ht,q),n=[t,e,O,r,tt,ut?N:null,ht?G:null];if(m){let t,e,i,s,o;if(at){const r=x-L;if(!at[r]){at[r]={args:n,declutterMode:A};continue}const s=at[r];t=s.args,e=s.declutterMode,delete at[r],i=_(t)}if(!t||"declutter"===e&&m.collides(i)||(s=!0),"declutter"===A&&m.collides(r.declutterBox)||(o=!0),"declutter"===e&&"declutter"===A){const t=s&&o;s=t,o=t}s&&("none"!==e&&m.insert(i),this.replayImageOrLabel_.apply(this,t)),o&&("none"!==A&&m.insert(r.declutterBox),this.replayImageOrLabel_.apply(this,n))}else this.replayImageOrLabel_.apply(this,n)}++v;break;case n.Ay.DRAW_CHARS:const ft=r[1],pt=r[2],mt=r[3],gt=r[4];k=r[5];const yt=r[6],vt=r[7],_t=r[8];I=r[9];const bt=r[10];R=r[11],D=r[12];const wt=[r[13],r[13]];A=r[14]||"declutter";const xt=this.textStates[D],Et=xt.font,St=[xt.scale[0]*vt,xt.scale[1]*vt];let At;Et in this.widths_?At=this.widths_[Et]:(At={},this.widths_[Et]=At);const Pt=(0,f.k)(y,ft,pt,2),Tt=Math.abs(St[0])*(0,l.TA)(Et,R,At);if(gt||Tt<=Pt){const r=h(y,ft,pt,2,R,(Pt-Tt)*w(R,this.textStates[D].textAlign),yt,Math.abs(St[0]),l.TA,Et,At,U?0:this.viewRotation_);t:if(r){const n=[];let i,s,o,a,c;if(I)for(i=0,s=r.length;i<s;++i){c=r[i],o=c[4],a=this.createLabel(o,D,"",I),E=c[2]+(St[0]<0?-bt:bt),S=mt*a.height+2*(.5-mt)*bt*St[1]/St[0]-_t;const s=this.calculateImageOrLabelDimensions_(a.width,a.height,c[0],c[1],a.width,a.height,E,S,0,0,c[3],wt,!1,l.Tq,!1,q);if(m&&"declutter"===A&&m.collides(s.declutterBox))break t;n.push([t,e,a,s,1,null,null])}if(k)for(i=0,s=r.length;i<s;++i){c=r[i],o=c[4],a=this.createLabel(o,D,k,""),E=c[2],S=mt*a.height-_t;const s=this.calculateImageOrLabelDimensions_(a.width,a.height,c[0],c[1],a.width,a.height,E,S,0,0,c[3],wt,!1,l.Tq,!1,q);if(m&&"declutter"===A&&m.collides(s.declutterBox))break t;n.push([t,e,a,s,1,null,null])}m&&"none"!==A&&m.load(n.map(_));for(let t=0,e=n.length;t<e;++t)this.replayImageOrLabel_.apply(this,n[t])}}++v;break;case n.Ay.END_GEOMETRY:if(void 0!==c){q=r[1];const t=c(q,H,A);if(t)return t}++v;break;case n.Ay.FILL:V?F++:this.fill_(t),++v;break;case n.Ay.MOVE_TO_LINE_TO:for(L=r[1],x=r[2],K=y[L],W=y[L+1],t.moveTo(K,W),P=K+.5|0,T=W+.5|0,L+=2;L<x;L+=2)K=y[L],W=y[L+1],C=K+.5|0,M=W+.5|0,L!=x-2&&C===P&&M===T||(t.lineTo(K,W),P=C,T=M);++v;break;case n.Ay.SET_FILL_STYLE:N=r,this.alignAndScaleFill_=r[2],F&&(this.fill_(t),F=0,j&&(t.stroke(),j=0)),t.fillStyle=r[1],++v;break;case n.Ay.SET_STROKE_STYLE:G=r,j&&(t.stroke(),j=0),this.setStrokeStyle_(t,r),++v;break;case n.Ay.STROKE:V?j++:t.stroke(),++v;break;default:++v}}F&&this.fill_(t),j&&t.stroke()}execute(t,e,r,n,i,s){this.viewRotation_=n,this.execute_(t,e,r,this.instructions,i,void 0,void 0,s)}executeHitDetection(t,e,r,n,i){return this.viewRotation_=r,this.execute_(t,[t.canvas.width,t.canvas.height],e,this.hitDetectionInstructions,!0,n,i)}};var S=r(83085),A=r(82048);const P=["Polygon","Circle","LineString","Image","Text","Default"],T=["Image","Text"],C=P.filter((t=>!T.includes(t))),M={},O=class{constructor(t,e,r,n,i,s,a){this.maxExtent_=t,this.overlaps_=n,this.pixelRatio_=r,this.resolution_=e,this.renderBuffer_=s,this.executorsByZIndex_={},this.hitDetectionContext_=null,this.hitDetectionTransform_=(0,o.vt)(),this.renderedContext_=null,this.deferredZIndexContexts_={},this.createExecutors_(i,a)}clip(t,e){const r=this.getClipCoords(e);t.beginPath(),t.moveTo(r[0],r[1]),t.lineTo(r[2],r[3]),t.lineTo(r[4],r[5]),t.lineTo(r[6],r[7]),t.clip()}createExecutors_(t,e){for(const r in t){let n=this.executorsByZIndex_[r];void 0===n&&(n={},this.executorsByZIndex_[r]=n);const i=t[r];for(const t in i){const r=i[t];n[t]=new E(this.resolution_,this.pixelRatio_,this.overlaps_,r,e)}}}hasExecutors(t){for(const e in this.executorsByZIndex_){const r=this.executorsByZIndex_[e];for(let e=0,n=t.length;e<n;++e)if(t[e]in r)return!0}return!1}forEachFeatureAtCoordinate(t,e,r,n,i,s){const l=2*(n=Math.round(n))+1,c=(0,o.Zz)(this.hitDetectionTransform_,n+.5,n+.5,1/e,-1/e,-r,-t[0],-t[1]),u=!this.hitDetectionContext_;u&&(this.hitDetectionContext_=(0,S.Y)(l,l,void 0,{willReadFrequently:!0}));const h=this.hitDetectionContext_;let f;h.canvas.width!==l||h.canvas.height!==l?(h.canvas.width=l,h.canvas.height=l):u||h.clearRect(0,0,l,l),void 0!==this.renderBuffer_&&(f=(0,a.S5)(),(0,a.$C)(f,t),(0,a.r)(f,e*(this.renderBuffer_+n),f));const p=function(t){if(void 0!==M[t])return M[t];const e=2*t+1,r=t*t,n=new Array(r+1);for(let i=0;i<=t;++i)for(let s=0;s<=t;++s){const o=i*i+s*s;if(o>r)break;let a=n[o];a||(a=[],n[o]=a),a.push(4*((t+i)*e+(t+s))+3),i>0&&a.push(4*((t-i)*e+(t+s))+3),s>0&&(a.push(4*((t+i)*e+(t-s))+3),i>0&&a.push(4*((t-i)*e+(t-s))+3))}const i=[];for(let t=0,e=n.length;t<e;++t)n[t]&&i.push(...n[t]);return M[t]=i,i}(n);let m;function g(t,e,r){const o=h.getImageData(0,0,l,l).data;for(let a=0,c=p.length;a<c;a++)if(o[p[a]]>0){if(!s||"none"===r||"Image"!==m&&"Text"!==m||s.includes(t)){const r=(p[a]-3)/4,s=n-r%l,o=n-(r/l|0),c=i(t,e,s*s+o*o);if(c)return c}h.clearRect(0,0,l,l);break}}const y=Object.keys(this.executorsByZIndex_).map(Number);let v,_,b,w,x;for(y.sort(d.V_),v=y.length-1;v>=0;--v){const t=y[v].toString();for(b=this.executorsByZIndex_[t],_=P.length-1;_>=0;--_)if(m=P[_],w=b[m],void 0!==w&&(x=w.executeHitDetection(h,c,r,g,f),x))return x}}getClipCoords(t){const e=this.maxExtent_;if(!e)return null;const r=e[0],n=e[1],i=e[2],s=e[3],o=[r,n,r,s,i,s,i,n];return(0,u.Rc)(o,0,8,2,t,o),o}isEmpty(){return(0,A.p)(this.executorsByZIndex_)}execute(t,e,r,n,i,s,o){const a=Object.keys(this.executorsByZIndex_).map(Number);a.sort(d.V_),s=s||P;const l=P.length;let c,u,h,f,p;for(o&&a.reverse(),c=0,u=a.length;c<u;++c){const u=a[c].toString();for(p=this.executorsByZIndex_[u],h=0,f=s.length;h<f;++h){const u=s[h],d=p[u];if(void 0!==d){const s=null===o?void 0:d.getZIndexContext(),f=s?s.getContext():t,p=this.maxExtent_&&"Image"!==u&&"Text"!==u;if(p&&(f.save(),this.clip(f,r)),s&&"Text"!==u&&"Image"!==u?s.pushFunction((t=>d.execute(t,e,r,n,i,o))):d.execute(f,e,r,n,i,o),p&&f.restore(),s){s.offset();const t=a[c]*l+h;this.deferredZIndexContexts_[t]||(this.deferredZIndexContexts_[t]=[]),this.deferredZIndexContexts_[t].push(s)}}}}this.renderedContext_=t}getDeferredZIndexContexts(){return this.deferredZIndexContexts_}getRenderedContext(){return this.renderedContext_}renderDeferred(){const t=this.deferredZIndexContexts_,e=Object.keys(t).map(Number).sort(d.V_);for(let r=0,n=e.length;r<n;++r)t[e[r]].forEach((t=>{t.draw(this.renderedContext_),t.clear()})),t[e[r]].length=0}}},15675:(t,e,r)=>{"use strict";r.d(e,{Ay:()=>l,I5:()=>i,VD:()=>s,kx:()=>a,th:()=>o});const n={BEGIN_GEOMETRY:0,BEGIN_PATH:1,CIRCLE:2,CLOSE_PATH:3,CUSTOM:4,DRAW_CHARS:5,DRAW_IMAGE:6,END_GEOMETRY:7,FILL:8,MOVE_TO_LINE_TO:9,SET_FILL_STYLE:10,SET_STROKE_STYLE:11,STROKE:12},i=[n.FILL],s=[n.STROKE],o=[n.BEGIN_PATH],a=[n.CLOSE_PATH],l=n},79596:(t,e,r)=>{"use strict";r.d(e,{E:()=>d,A:()=>p});var n=r(10272),i=r(15675),s=r(67029),o=r(33976),a=r(98629),l=r(44509),c=r(72475);function u(t,e,r,n,i){const s=[];let o=r,a=0,l=e.slice(r,2);for(;a<t&&o+i<n;){const[r,n]=l.slice(-2),u=e[o+i],h=e[o+i+1],d=Math.sqrt((u-r)*(u-r)+(h-n)*(h-n));if(a+=d,a>=t){const e=(t-a+d)/d,f=(0,c.Cc)(r,u,e),p=(0,c.Cc)(n,h,e);l.push(f,p),s.push(l),l=[f,p],a==t&&(o+=i),a=0}else if(a<t)l.push(e[o+i],e[o+i+1]),o+=i;else{const t=d-a,e=(0,c.Cc)(r,u,t/d),f=(0,c.Cc)(n,h,t/d);l.push(e,f),s.push(l),l=[e,f],a=0,o+=i}}return a>0&&s.push(l),s}function h(t,e,r,n,i){let s,o,a,l,c,u,h,d,f,p,m=r,g=r,y=0,v=0,_=r;for(o=r;o<n;o+=i){const r=e[o],n=e[o+1];void 0!==c&&(f=r-c,p=n-u,l=Math.sqrt(f*f+p*p),void 0!==h&&(v+=a,s=Math.acos((h*f+d*p)/(a*l)),s>t&&(v>y&&(y=v,m=_,g=o),v=0,_=o-i)),a=l,h=f,d=p),c=r,u=n}return v+=l,v>y?[_,o]:[m,g]}const d={left:0,center:.5,right:1,top:0,middle:.5,hanging:.2,alphabetic:.8,ideographic:.8,bottom:1};class f extends n.A{constructor(t,e,r,n){super(t,e,r,n),this.labels_=null,this.text_="",this.textOffsetX_=0,this.textOffsetY_=0,this.textRotateWithView_=void 0,this.textRotation_=0,this.textFillState_=null,this.fillStates={},this.fillStates[o.qY]={fillStyle:o.qY},this.textStrokeState_=null,this.strokeStates={},this.textState_={},this.textStates={},this.textKey_="",this.fillKey_="",this.strokeKey_="",this.declutterMode_=void 0,this.declutterImageWithText_=void 0}finish(){const t=super.finish();return t.textStates=this.textStates,t.fillStates=this.fillStates,t.strokeStates=this.strokeStates,t}drawText(t,e,r){const n=this.textFillState_,s=this.textStrokeState_,a=this.textState_;if(""===this.text_||!a||!n&&!s)return;const c=this.coordinates;let d=c.length;const f=t.getType();let p=null,m=t.getStride();if("line"!==a.placement||"LineString"!=f&&"MultiLineString"!=f&&"Polygon"!=f&&"MultiPolygon"!=f){let n=a.overflow?null:[];switch(f){case"Point":case"MultiPoint":p=t.getFlatCoordinates();break;case"LineString":p=t.getFlatMidpoint();break;case"Circle":p=t.getCenter();break;case"MultiLineString":p=t.getFlatMidpoints(),m=2;break;case"Polygon":p=t.getFlatInteriorPoint(),a.overflow||n.push(p[2]/this.resolution),m=3;break;case"MultiPolygon":const e=t.getFlatInteriorPoints();p=[];for(let t=0,r=e.length;t<r;t+=3)a.overflow||n.push(e[t+2]/this.resolution),p.push(e[t],e[t+1]);if(0===p.length)return;m=2}const s=this.appendFlatPointCoordinates(p,m);if(s===d)return;if(n&&(s-d)/2!=p.length/m){let t=d/2;n=n.filter(((e,r)=>{const n=c[2*(t+r)]===p[r*m]&&c[2*(t+r)+1]===p[r*m+1];return n||--t,n}))}this.saveTextStates_(),(a.backgroundFill||a.backgroundStroke)&&(this.setFillStrokeStyle(a.backgroundFill,a.backgroundStroke),a.backgroundFill&&this.updateFillStyle(this.state,this.createFill),a.backgroundStroke&&(this.updateStrokeStyle(this.state,this.applyStroke),this.hitDetectionInstructions.push(this.createStroke(this.state)))),this.beginGeometry(t,e,r);let l=a.padding;if(l!=o.Tq&&(a.scale[0]<0||a.scale[1]<0)){let t=a.padding[0],e=a.padding[1],r=a.padding[2],n=a.padding[3];a.scale[0]<0&&(e=-e,n=-n),a.scale[1]<0&&(t=-t,r=-r),l=[t,e,r,n]}const u=this.pixelRatio;this.instructions.push([i.Ay.DRAW_IMAGE,d,s,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[1,1],NaN,this.declutterMode_,this.declutterImageWithText_,l==o.Tq?o.Tq:l.map((function(t){return t*u})),!!a.backgroundFill,!!a.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_,this.textOffsetX_,this.textOffsetY_,n]);const h=1/u,g=this.state.fillStyle;a.backgroundFill&&(this.state.fillStyle=o.qY,this.hitDetectionInstructions.push(this.createFill(this.state))),this.hitDetectionInstructions.push([i.Ay.DRAW_IMAGE,d,s,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[h,h],NaN,this.declutterMode_,this.declutterImageWithText_,l,!!a.backgroundFill,!!a.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_?o.qY:this.fillKey_,this.textOffsetX_,this.textOffsetY_,n]),a.backgroundFill&&(this.state.fillStyle=g,this.hitDetectionInstructions.push(this.createFill(this.state))),this.endGeometry(e)}else{if(!(0,l.HY)(this.maxExtent,t.getExtent()))return;let n;if(p=t.getFlatCoordinates(),"LineString"==f)n=[p.length];else if("MultiLineString"==f)n=t.getEnds();else if("Polygon"==f)n=t.getEnds().slice(0,1);else if("MultiPolygon"==f){const e=t.getEndss();n=[];for(let t=0,r=e.length;t<r;++t)n.push(e[t][0])}this.beginGeometry(t,e,r);const i=a.repeat,s=i?void 0:a.textAlign;let o=0;for(let t=0,e=n.length;t<e;++t){let e;e=i?u(i*this.resolution,p,o,n[t],m):[p.slice(o,n[t])];for(let r=0,i=e.length;r<i;++r){const i=e[r];let l=0,u=i.length;if(null==s){const t=h(a.maxAngle,i,0,i.length,2);l=t[0],u=t[1]}for(let t=l;t<u;t+=m)c.push(i[t],i[t+1]);const f=c.length;o=n[t],this.drawChars_(d,f),d=f}}this.endGeometry(e)}}saveTextStates_(){const t=this.textStrokeState_,e=this.textState_,r=this.textFillState_,n=this.strokeKey_;t&&(n in this.strokeStates||(this.strokeStates[n]={strokeStyle:t.strokeStyle,lineCap:t.lineCap,lineDashOffset:t.lineDashOffset,lineWidth:t.lineWidth,lineJoin:t.lineJoin,miterLimit:t.miterLimit,lineDash:t.lineDash}));const i=this.textKey_;i in this.textStates||(this.textStates[i]={font:e.font,textAlign:e.textAlign||o.MY,justify:e.justify,textBaseline:e.textBaseline||o.M8,scale:e.scale});const s=this.fillKey_;r&&(s in this.fillStates||(this.fillStates[s]={fillStyle:r.fillStyle}))}drawChars_(t,e){const r=this.textStrokeState_,n=this.textState_,s=this.strokeKey_,a=this.textKey_,l=this.fillKey_;this.saveTextStates_();const c=this.pixelRatio,u=d[n.textBaseline],h=this.textOffsetY_*c,f=this.text_,p=r?r.lineWidth*Math.abs(n.scale[0])/2:0;this.instructions.push([i.Ay.DRAW_CHARS,t,e,u,n.overflow,l,n.maxAngle,c,h,s,p*c,f,a,1,this.declutterMode_]),this.hitDetectionInstructions.push([i.Ay.DRAW_CHARS,t,e,u,n.overflow,l?o.qY:l,n.maxAngle,c,h,s,p*c,f,a,1/c,this.declutterMode_])}setTextStyle(t,e){let r,n,i;if(t){const e=t.getFill();e?(n=this.textFillState_,n||(n={},this.textFillState_=n),n.fillStyle=(0,s.F)(e.getColor()||o.qY)):(n=null,this.textFillState_=n);const l=t.getStroke();if(l){i=this.textStrokeState_,i||(i={},this.textStrokeState_=i);const t=l.getLineDash(),e=l.getLineDashOffset(),r=l.getWidth(),n=l.getMiterLimit();i.lineCap=l.getLineCap()||o._m,i.lineDash=t?t.slice():o.Oq,i.lineDashOffset=void 0===e?o.vk:e,i.lineJoin=l.getLineJoin()||o._K,i.lineWidth=void 0===r?o.aq:r,i.miterLimit=void 0===n?o.eL:n,i.strokeStyle=(0,s.F)(l.getColor()||o.NT)}else i=null,this.textStrokeState_=i;r=this.textState_;const c=t.getFont()||o.ZV;(0,o.fZ)(c);const u=t.getScaleArray();r.overflow=t.getOverflow(),r.font=c,r.maxAngle=t.getMaxAngle(),r.placement=t.getPlacement(),r.textAlign=t.getTextAlign(),r.repeat=t.getRepeat(),r.justify=t.getJustify(),r.textBaseline=t.getTextBaseline()||o.M8,r.backgroundFill=t.getBackgroundFill(),r.backgroundStroke=t.getBackgroundStroke(),r.padding=t.getPadding()||o.Tq,r.scale=void 0===u?[1,1]:u;const h=t.getOffsetX(),d=t.getOffsetY(),f=t.getRotateWithView(),p=t.getRotation();this.text_=t.getText()||"",this.textOffsetX_=void 0===h?0:h,this.textOffsetY_=void 0===d?0:d,this.textRotateWithView_=void 0!==f&&f,this.textRotation_=void 0===p?0:p,this.strokeKey_=i?("string"==typeof i.strokeStyle?i.strokeStyle:(0,a.v6)(i.strokeStyle))+i.lineCap+i.lineDashOffset+"|"+i.lineWidth+i.lineJoin+i.miterLimit+"["+i.lineDash.join()+"]":"",this.textKey_=r.font+r.scale+(r.textAlign||"?")+(r.repeat||"?")+(r.justify||"?")+(r.textBaseline||"?"),this.fillKey_=n&&n.fillStyle?"string"==typeof n.fillStyle?n.fillStyle:"|"+(0,a.v6)(n.fillStyle):""}else this.text_="";this.declutterMode_=t.getDeclutterMode(),this.declutterImageWithText_=e}}const p=f},83050:(t,e,r)=>{"use strict";r.d(e,{A:()=>i});var n=r(83085);const i=class{constructor(){this.instructions_=[],this.zIndex=0,this.offset_=0,this.context_=new Proxy((0,n.lr)(),{get:(t,e)=>{if("function"==typeof(0,n.lr)()[e])return this.instructions_[this.zIndex+this.offset_]||(this.instructions_[this.zIndex+this.offset_]=[]),this.instructions_[this.zIndex+this.offset_].push(e),this.pushMethodArgs_},set:(t,e,r)=>(this.instructions_[this.zIndex+this.offset_]||(this.instructions_[this.zIndex+this.offset_]=[]),this.instructions_[this.zIndex+this.offset_].push(e,r),!0)})}pushMethodArgs_=(...t)=>(this.instructions_[this.zIndex+this.offset_].push(t),this);pushFunction(t){this.instructions_[this.zIndex+this.offset_].push(t)}getContext(){return this.context_}draw(t){this.instructions_.forEach((e=>{for(let r=0,n=e.length;r<n;++r){const n=e[r];if("function"==typeof n){n(t);continue}const i=e[++r];if("function"==typeof t[n])t[n](...i);else{if("function"==typeof i){t[n]=i(t);continue}t[n]=i}}}))}clear(){this.instructions_.length=0,this.zIndex=0,this.offset_=0}offset(){this.offset_=this.instructions_.length,this.zIndex=0}}},12049:(t,e,r)=>{"use strict";r.d(e,{tF:()=>y,_7:()=>v,F8:()=>_});var n=r(16724),i=r(67029),s=r(37377),o=r(33976),a=r(30444),l=r(44509),c=r(72475),u=r(70772),h=r(31886);class d extends n.A{constructor(t,e,r,n,i,o,a){super(),this.context_=t,this.pixelRatio_=e,this.extent_=r,this.transform_=n,this.transformRotation_=n?(0,c.Mg)(Math.atan2(n[1],n[0]),10):0,this.viewRotation_=i,this.squaredTolerance_=o,this.userTransform_=a,this.contextFillState_=null,this.contextStrokeState_=null,this.contextTextState_=null,this.fillState_=null,this.strokeState_=null,this.image_=null,this.imageAnchorX_=0,this.imageAnchorY_=0,this.imageHeight_=0,this.imageOpacity_=0,this.imageOriginX_=0,this.imageOriginY_=0,this.imageRotateWithView_=!1,this.imageRotation_=0,this.imageScale_=[0,0],this.imageWidth_=0,this.text_="",this.textOffsetX_=0,this.textOffsetY_=0,this.textRotateWithView_=!1,this.textRotation_=0,this.textScale_=[0,0],this.textFillState_=null,this.textStrokeState_=null,this.textState_=null,this.pixelCoordinates_=[],this.tmpLocalTransform_=(0,s.vt)()}drawImages_(t,e,r,n){if(!this.image_)return;const i=(0,u.Rc)(t,e,r,n,this.transform_,this.pixelCoordinates_),o=this.context_,a=this.tmpLocalTransform_,l=o.globalAlpha;1!=this.imageOpacity_&&(o.globalAlpha=l*this.imageOpacity_);let c=this.imageRotation_;0===this.transformRotation_&&(c-=this.viewRotation_),this.imageRotateWithView_&&(c+=this.viewRotation_);for(let t=0,e=i.length;t<e;t+=2){const e=i[t]-this.imageAnchorX_,r=i[t+1]-this.imageAnchorY_;if(0!==c||1!=this.imageScale_[0]||1!=this.imageScale_[1]){const t=e+this.imageAnchorX_,n=r+this.imageAnchorY_;(0,s.Zz)(a,t,n,1,1,c,-t,-n),o.save(),o.transform.apply(o,a),o.translate(t,n),o.scale(this.imageScale_[0],this.imageScale_[1]),o.drawImage(this.image_,this.imageOriginX_,this.imageOriginY_,this.imageWidth_,this.imageHeight_,-this.imageAnchorX_,-this.imageAnchorY_,this.imageWidth_,this.imageHeight_),o.restore()}else o.drawImage(this.image_,this.imageOriginX_,this.imageOriginY_,this.imageWidth_,this.imageHeight_,e,r,this.imageWidth_,this.imageHeight_)}1!=this.imageOpacity_&&(o.globalAlpha=l)}drawText_(t,e,r,n){if(!this.textState_||""===this.text_)return;this.textFillState_&&this.setContextFillState_(this.textFillState_),this.textStrokeState_&&this.setContextStrokeState_(this.textStrokeState_),this.setContextTextState_(this.textState_);const i=(0,u.Rc)(t,e,r,n,this.transform_,this.pixelCoordinates_),s=this.context_;let o=this.textRotation_;for(0===this.transformRotation_&&(o-=this.viewRotation_),this.textRotateWithView_&&(o+=this.viewRotation_);e<r;e+=n){const t=i[e]+this.textOffsetX_,r=i[e+1]+this.textOffsetY_;0!==o||1!=this.textScale_[0]||1!=this.textScale_[1]?(s.save(),s.translate(t-this.textOffsetX_,r-this.textOffsetY_),s.rotate(o),s.translate(this.textOffsetX_,this.textOffsetY_),s.scale(this.textScale_[0],this.textScale_[1]),this.textStrokeState_&&s.strokeText(this.text_,0,0),this.textFillState_&&s.fillText(this.text_,0,0),s.restore()):(this.textStrokeState_&&s.strokeText(this.text_,t,r),this.textFillState_&&s.fillText(this.text_,t,r))}}moveToLineTo_(t,e,r,n,i){const s=this.context_,o=(0,u.Rc)(t,e,r,n,this.transform_,this.pixelCoordinates_);s.moveTo(o[0],o[1]);let a=o.length;i&&(a-=2);for(let t=2;t<a;t+=2)s.lineTo(o[t],o[t+1]);return i&&s.closePath(),r}drawRings_(t,e,r,n){for(let i=0,s=r.length;i<s;++i)e=this.moveToLineTo_(t,e,r[i],n,!0);return e}drawCircle(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),(0,l.HY)(this.extent_,t.getExtent())){if(this.fillState_||this.strokeState_){this.fillState_&&this.setContextFillState_(this.fillState_),this.strokeState_&&this.setContextStrokeState_(this.strokeState_);const e=(0,h.v7)(t,this.transform_,this.pixelCoordinates_),r=e[2]-e[0],n=e[3]-e[1],i=Math.sqrt(r*r+n*n),s=this.context_;s.beginPath(),s.arc(e[0],e[1],i,0,2*Math.PI),this.fillState_&&s.fill(),this.strokeState_&&s.stroke()}""!==this.text_&&this.drawText_(t.getCenter(),0,2,2)}}setStyle(t){this.setFillStrokeStyle(t.getFill(),t.getStroke()),this.setImageStyle(t.getImage()),this.setTextStyle(t.getText())}setTransform(t){this.transform_=t}drawGeometry(t){switch(t.getType()){case"Point":this.drawPoint(t);break;case"LineString":this.drawLineString(t);break;case"Polygon":this.drawPolygon(t);break;case"MultiPoint":this.drawMultiPoint(t);break;case"MultiLineString":this.drawMultiLineString(t);break;case"MultiPolygon":this.drawMultiPolygon(t);break;case"GeometryCollection":this.drawGeometryCollection(t);break;case"Circle":this.drawCircle(t)}}drawFeature(t,e){const r=e.getGeometryFunction()(t);r&&(this.setStyle(e),this.drawGeometry(r))}drawGeometryCollection(t){const e=t.getGeometriesArray();for(let t=0,r=e.length;t<r;++t)this.drawGeometry(e[t])}drawPoint(t){this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_));const e=t.getFlatCoordinates(),r=t.getStride();this.image_&&this.drawImages_(e,0,e.length,r),""!==this.text_&&this.drawText_(e,0,e.length,r)}drawMultiPoint(t){this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_));const e=t.getFlatCoordinates(),r=t.getStride();this.image_&&this.drawImages_(e,0,e.length,r),""!==this.text_&&this.drawText_(e,0,e.length,r)}drawLineString(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),(0,l.HY)(this.extent_,t.getExtent())){if(this.strokeState_){this.setContextStrokeState_(this.strokeState_);const e=this.context_,r=t.getFlatCoordinates();e.beginPath(),this.moveToLineTo_(r,0,r.length,t.getStride(),!1),e.stroke()}if(""!==this.text_){const e=t.getFlatMidpoint();this.drawText_(e,0,2,2)}}}drawMultiLineString(t){this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_));const e=t.getExtent();if((0,l.HY)(this.extent_,e)){if(this.strokeState_){this.setContextStrokeState_(this.strokeState_);const e=this.context_,r=t.getFlatCoordinates();let n=0;const i=t.getEnds(),s=t.getStride();e.beginPath();for(let t=0,e=i.length;t<e;++t)n=this.moveToLineTo_(r,n,i[t],s,!1);e.stroke()}if(""!==this.text_){const e=t.getFlatMidpoints();this.drawText_(e,0,e.length,2)}}}drawPolygon(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),(0,l.HY)(this.extent_,t.getExtent())){if(this.strokeState_||this.fillState_){this.fillState_&&this.setContextFillState_(this.fillState_),this.strokeState_&&this.setContextStrokeState_(this.strokeState_);const e=this.context_;e.beginPath(),this.drawRings_(t.getOrientedFlatCoordinates(),0,t.getEnds(),t.getStride()),this.fillState_&&e.fill(),this.strokeState_&&e.stroke()}if(""!==this.text_){const e=t.getFlatInteriorPoint();this.drawText_(e,0,2,2)}}}drawMultiPolygon(t){if(this.squaredTolerance_&&(t=t.simplifyTransformed(this.squaredTolerance_,this.userTransform_)),(0,l.HY)(this.extent_,t.getExtent())){if(this.strokeState_||this.fillState_){this.fillState_&&this.setContextFillState_(this.fillState_),this.strokeState_&&this.setContextStrokeState_(this.strokeState_);const e=this.context_,r=t.getOrientedFlatCoordinates();let n=0;const i=t.getEndss(),s=t.getStride();e.beginPath();for(let t=0,e=i.length;t<e;++t){const e=i[t];n=this.drawRings_(r,n,e,s)}this.fillState_&&e.fill(),this.strokeState_&&e.stroke()}if(""!==this.text_){const e=t.getFlatInteriorPoints();this.drawText_(e,0,e.length,2)}}}setContextFillState_(t){const e=this.context_,r=this.contextFillState_;r?r.fillStyle!=t.fillStyle&&(r.fillStyle=t.fillStyle,e.fillStyle=t.fillStyle):(e.fillStyle=t.fillStyle,this.contextFillState_={fillStyle:t.fillStyle})}setContextStrokeState_(t){const e=this.context_,r=this.contextStrokeState_;r?(r.lineCap!=t.lineCap&&(r.lineCap=t.lineCap,e.lineCap=t.lineCap),(0,a.aI)(r.lineDash,t.lineDash)||e.setLineDash(r.lineDash=t.lineDash),r.lineDashOffset!=t.lineDashOffset&&(r.lineDashOffset=t.lineDashOffset,e.lineDashOffset=t.lineDashOffset),r.lineJoin!=t.lineJoin&&(r.lineJoin=t.lineJoin,e.lineJoin=t.lineJoin),r.lineWidth!=t.lineWidth&&(r.lineWidth=t.lineWidth,e.lineWidth=t.lineWidth),r.miterLimit!=t.miterLimit&&(r.miterLimit=t.miterLimit,e.miterLimit=t.miterLimit),r.strokeStyle!=t.strokeStyle&&(r.strokeStyle=t.strokeStyle,e.strokeStyle=t.strokeStyle)):(e.lineCap=t.lineCap,e.setLineDash(t.lineDash),e.lineDashOffset=t.lineDashOffset,e.lineJoin=t.lineJoin,e.lineWidth=t.lineWidth,e.miterLimit=t.miterLimit,e.strokeStyle=t.strokeStyle,this.contextStrokeState_={lineCap:t.lineCap,lineDash:t.lineDash,lineDashOffset:t.lineDashOffset,lineJoin:t.lineJoin,lineWidth:t.lineWidth,miterLimit:t.miterLimit,strokeStyle:t.strokeStyle})}setContextTextState_(t){const e=this.context_,r=this.contextTextState_,n=t.textAlign?t.textAlign:o.MY;r?(r.font!=t.font&&(r.font=t.font,e.font=t.font),r.textAlign!=n&&(r.textAlign=n,e.textAlign=n),r.textBaseline!=t.textBaseline&&(r.textBaseline=t.textBaseline,e.textBaseline=t.textBaseline)):(e.font=t.font,e.textAlign=n,e.textBaseline=t.textBaseline,this.contextTextState_={font:t.font,textAlign:n,textBaseline:t.textBaseline})}setFillStrokeStyle(t,e){if(t){const e=t.getColor();this.fillState_={fillStyle:(0,i.F)(e||o.qY)}}else this.fillState_=null;if(e){const t=e.getColor(),r=e.getLineCap(),n=e.getLineDash(),s=e.getLineDashOffset(),a=e.getLineJoin(),l=e.getWidth(),c=e.getMiterLimit(),u=n||o.Oq;this.strokeState_={lineCap:void 0!==r?r:o._m,lineDash:1===this.pixelRatio_?u:u.map((t=>t*this.pixelRatio_)),lineDashOffset:(s||o.vk)*this.pixelRatio_,lineJoin:void 0!==a?a:o._K,lineWidth:(void 0!==l?l:o.aq)*this.pixelRatio_,miterLimit:void 0!==c?c:o.eL,strokeStyle:(0,i.F)(t||o.NT)}}else this.strokeState_=null}setImageStyle(t){let e;if(!t||!(e=t.getSize()))return void(this.image_=null);const r=t.getPixelRatio(this.pixelRatio_),n=t.getAnchor(),i=t.getOrigin();this.image_=t.getImage(this.pixelRatio_),this.imageAnchorX_=n[0]*r,this.imageAnchorY_=n[1]*r,this.imageHeight_=e[1]*r,this.imageOpacity_=t.getOpacity(),this.imageOriginX_=i[0],this.imageOriginY_=i[1],this.imageRotateWithView_=t.getRotateWithView(),this.imageRotation_=t.getRotation();const s=t.getScaleArray();this.imageScale_=[s[0]*this.pixelRatio_/r,s[1]*this.pixelRatio_/r],this.imageWidth_=e[0]*r}setTextStyle(t){if(t){const e=t.getFill();if(e){const t=e.getColor();this.textFillState_={fillStyle:(0,i.F)(t||o.qY)}}else this.textFillState_=null;const r=t.getStroke();if(r){const t=r.getColor(),e=r.getLineCap(),n=r.getLineDash(),s=r.getLineDashOffset(),a=r.getLineJoin(),l=r.getWidth(),c=r.getMiterLimit();this.textStrokeState_={lineCap:void 0!==e?e:o._m,lineDash:n||o.Oq,lineDashOffset:s||o.vk,lineJoin:void 0!==a?a:o._K,lineWidth:void 0!==l?l:o.aq,miterLimit:void 0!==c?c:o.eL,strokeStyle:(0,i.F)(t||o.NT)}}else this.textStrokeState_=null;const n=t.getFont(),s=t.getOffsetX(),a=t.getOffsetY(),l=t.getRotateWithView(),c=t.getRotation(),u=t.getScaleArray(),h=t.getText(),d=t.getTextAlign(),f=t.getTextBaseline();this.textState_={font:void 0!==n?n:o.ZV,textAlign:void 0!==d?d:o.MY,textBaseline:void 0!==f?f:o.M8},this.text_=void 0!==h?Array.isArray(h)?h.reduce(((t,e,r)=>t+(r%2?" ":e)),""):h:"",this.textOffsetX_=void 0!==s?this.pixelRatio_*s:0,this.textOffsetY_=void 0!==a?this.pixelRatio_*a:0,this.textRotateWithView_=void 0!==l&&l,this.textRotation_=void 0!==c?c:0,this.textScale_=[this.pixelRatio_*u[0],this.pixelRatio_*u[1]]}else this.text_=""}}const f=d;var p=r(25174),m=r(83085),g=r(12940);const y=.5;function v(t,e,r,n,i,s,o,c,u){const h=u?(0,g.JR)(i,u):i,d=t[0]*y,v=t[1]*y,_=(0,m.Y)(d,v);_.imageSmoothingEnabled=!1;const b=_.canvas,w=new f(_,y,i,null,o,c,u?(0,g.FO)((0,g.Tf)(),u):null),x=r.length,E=Math.floor(16777215/x),S={};for(let t=1;t<=x;++t){const e=r[t-1],i=e.getStyleFunction()||n;if(!i)continue;let o=i(e,s);if(!o)continue;Array.isArray(o)||(o=[o]);const a=(t*E).toString(16).padStart(7,"#00000");for(let t=0,r=o.length;t<r;++t){const r=o[t],n=r.getGeometryFunction()(e);if(!n||!(0,l.HY)(h,n.getExtent()))continue;const i=r.clone(),s=i.getFill();s&&s.setColor(a);const c=i.getStroke();c&&(c.setColor(a),c.setLineDash(null)),i.setText(void 0);const u=r.getImage();if(u){const t=u.getImageSize();if(!t)continue;const e=(0,m.Y)(t[0],t[1],void 0,{alpha:!1}),r=e.canvas;e.fillStyle=a,e.fillRect(0,0,r.width,r.height),i.setImage(new p.A({img:r,anchor:u.getAnchor(),anchorXUnits:"pixels",anchorYUnits:"pixels",offset:u.getOrigin(),opacity:1,size:u.getSize(),scale:u.getScale(),rotation:u.getRotation(),rotateWithView:u.getRotateWithView()}))}const d=i.getZIndex()||0;let f=S[d];f||(f={},S[d]=f,f.Polygon=[],f.Circle=[],f.LineString=[],f.Point=[]);const g=n.getType();if("GeometryCollection"===g){const t=n.getGeometriesArrayRecursive();for(let e=0,r=t.length;e<r;++e){const r=t[e];f[r.getType().replace("Multi","")].push(r,i)}}else f[g.replace("Multi","")].push(n,i)}}const A=Object.keys(S).map(Number).sort(a.V_);for(let t=0,r=A.length;t<r;++t){const r=S[A[t]];for(const t in r){const n=r[t];for(let t=0,r=n.length;t<r;t+=2){w.setStyle(n[t+1]);for(let r=0,i=e.length;r<i;++r)w.setTransform(e[r]),w.drawGeometry(n[t])}}}return _.getImageData(0,0,b.width,b.height)}function _(t,e,r){const n=[];if(r){const i=Math.floor(Math.round(t[0])*y),s=Math.floor(Math.round(t[1])*y),o=4*((0,c.qE)(i,0,r.width-1)+(0,c.qE)(s,0,r.height-1)*r.width),a=r.data[o],l=r.data[o+1],u=r.data[o+2]+256*(l+256*a),h=Math.floor(16777215/e.length);u&&u%h==0&&n.push(e[u/h-1])}return n}},10312:(t,e,r)=>{"use strict";r.d(e,{A:()=>l});var n=r(24187),i=r(39915),s=r(80548),o=r(98629);class a extends s.A{constructor(t){super(),this.ready=!0,this.boundHandleImageChange_=this.handleImageChange_.bind(this),this.layer_=t,this.staleKeys_=new Array,this.maxStaleKeys=5}getStaleKeys(){return this.staleKeys_}prependStaleKey(t){this.staleKeys_.unshift(t),this.staleKeys_.length>this.maxStaleKeys&&(this.staleKeys_.length=this.maxStaleKeys)}getFeatures(t){return(0,o.b0)()}getData(t){return null}prepareFrame(t){return(0,o.b0)()}renderFrame(t,e){return(0,o.b0)()}forEachFeatureAtCoordinate(t,e,r,n,i){}getLayer(){return this.layer_}handleFontsChanged(){}handleImageChange_(t){const e=t.target;e.getState()!==i.A.LOADED&&e.getState()!==i.A.ERROR||this.renderIfReadyAndVisible()}loadImage(t){let e=t.getState();return e!=i.A.LOADED&&e!=i.A.ERROR&&t.addEventListener(n.A.CHANGE,this.boundHandleImageChange_),e==i.A.IDLE&&(t.load(),e=t.getState()),e==i.A.LOADED}renderIfReadyAndVisible(){const t=this.getLayer();t&&t.getVisible()&&"ready"===t.getSourceState()&&t.changed()}renderDeferred(t){}disposeInternal(){delete this.layer_,super.disposeInternal()}}const l=a},87383:(t,e,r)=>{"use strict";r.d(e,{A:()=>m,B:()=>d});var n=r(10312),i=r(3094),s=r(45630),o=r(83050),a=r(37377),l=r(41009),c=r(83085),u=r(30444),h=r(44509);const d=[];let f=null;class p extends n.A{constructor(t){super(t),this.container=null,this.renderedResolution,this.tempTransform=(0,a.vt)(),this.pixelTransform=(0,a.vt)(),this.inversePixelTransform=(0,a.vt)(),this.context=null,this.deferredContext_=null,this.containerReused=!1,this.frameState=null}getImageData(t,e,r){let n;f||(f=(0,c.Y)(1,1,void 0,{willReadFrequently:!0})),f.clearRect(0,0,1,1);try{f.drawImage(t,e,r,1,1,0,0,1,1),n=f.getImageData(0,0,1,1).data}catch(t){return f=null,null}return n}getBackground(t){let e=this.getLayer().getBackground();return"function"==typeof e&&(e=e(t.viewState.resolution)),e||void 0}useContainer(t,e,r){const n=this.getLayer().getClassName();let i,s;if(t&&t.className===n&&(!r||t&&t.style.backgroundColor&&(0,u.aI)((0,l._j)(t.style.backgroundColor),(0,l._j)(r)))){const e=t.firstElementChild;e instanceof HTMLCanvasElement&&(s=e.getContext("2d"))}if(s&&s.canvas.style.transform===e?(this.container=t,this.context=s,this.containerReused=!0):this.containerReused?(this.container=null,this.context=null,this.containerReused=!1):this.container&&(this.container.style.backgroundColor=null),!this.container){i=document.createElement("div"),i.className=n;let t=i.style;t.position="absolute",t.width="100%",t.height="100%",s=(0,c.Y)();const e=s.canvas;i.appendChild(e),t=e.style,t.position="absolute",t.left="0",t.transformOrigin="top left",this.container=i,this.context=s}this.containerReused||!r||this.container.style.backgroundColor||(this.container.style.backgroundColor=r)}clipUnrotated(t,e,r){const n=(0,h.Py)(r),i=(0,h.WU)(r),s=(0,h.k_)(r),o=(0,h.R)(r);(0,a.Bb)(e.coordinateToPixelTransform,n),(0,a.Bb)(e.coordinateToPixelTransform,i),(0,a.Bb)(e.coordinateToPixelTransform,s),(0,a.Bb)(e.coordinateToPixelTransform,o);const l=this.inversePixelTransform;(0,a.Bb)(l,n),(0,a.Bb)(l,i),(0,a.Bb)(l,s),(0,a.Bb)(l,o),t.save(),t.beginPath(),t.moveTo(Math.round(n[0]),Math.round(n[1])),t.lineTo(Math.round(i[0]),Math.round(i[1])),t.lineTo(Math.round(s[0]),Math.round(s[1])),t.lineTo(Math.round(o[0]),Math.round(o[1])),t.clip()}prepareContainer(t,e){const r=t.extent,n=t.viewState.resolution,i=t.viewState.rotation,s=t.pixelRatio,o=Math.round((0,h.RG)(r)/n*s),l=Math.round((0,h.Oq)(r)/n*s);(0,a.Zz)(this.pixelTransform,t.size[0]/2,t.size[1]/2,1/s,1/s,i,-o/2,-l/2),(0,a.T9)(this.inversePixelTransform,this.pixelTransform);const c=(0,a.dI)(this.pixelTransform);if(this.useContainer(e,c,this.getBackground(t)),!this.containerReused){const t=this.context.canvas;t.width!=o||t.height!=l?(t.width=o,t.height=l):this.context.clearRect(0,0,o,l),c!==t.style.transform&&(t.style.transform=c)}}dispatchRenderEvent_(t,e,r){const n=this.getLayer();if(n.hasListener(t)){const s=new i.A(t,this.inversePixelTransform,r,e);n.dispatchEvent(s)}}preRender(t,e){this.frameState=e,e.declutter||this.dispatchRenderEvent_(s.A.PRERENDER,t,e)}postRender(t,e){e.declutter||this.dispatchRenderEvent_(s.A.POSTRENDER,t,e)}renderDeferredInternal(t){}getRenderContext(t){return t.declutter&&!this.deferredContext_&&(this.deferredContext_=new o.A),t.declutter?this.deferredContext_.getContext():this.context}renderDeferred(t){t.declutter&&(this.dispatchRenderEvent_(s.A.PRERENDER,this.context,t),t.declutter&&this.deferredContext_&&(this.deferredContext_.draw(this.context),this.deferredContext_.clear()),this.renderDeferredInternal(t),this.dispatchRenderEvent_(s.A.POSTRENDER,this.context,t))}getRenderTransform(t,e,r,n,i,s,o){const l=i/2,c=s/2,u=n/e,h=-u,d=-t[0]+o,f=-t[1];return(0,a.Zz)(this.tempTransform,l,c,u,h,-r,d,f)}disposeInternal(){delete this.frameState,super.disposeInternal()}}const m=p},34539:(t,e,r)=>{"use strict";r.d(e,{A:()=>E});var n=r(87383),i=r(97141),s=r(67564),o=r(98063),a=r(91202),l=r(84562),c=r(64444),u=r(20884),h=r(37377),d=r(30444),f=r(44509),p=r(80996),m=r(12940),g=r(98629),y=r(53908);function v(t,e,r,n){return`${t},${(0,p.dp)(e,r,n)}`}function _(t,e,r){if(!(r in t))return t[r]=new Set([e]),!0;const n=t[r],i=n.has(e);return i||n.add(e),!i}function b(t,e,r){const n=t[r];return!!n&&n.delete(e)}function w(t,e){const r=t.layerStatesArray[t.layerIndex];r.extent&&(e=(0,f._N)(e,(0,m.SD)(r.extent,t.viewState.projection)));const n=r.layer.getRenderSource();if(!n.getWrapX()){const r=n.getTileGridForProjection(t.viewState.projection).getExtent();r&&(e=(0,f._N)(e,r))}return e}class x extends n.A{constructor(t,e){super(t),e=e||{},this.extentChanged=!0,this.renderComplete=!1,this.renderedExtent_=null,this.renderedPixelRatio,this.renderedProjection=null,this.renderedRevision,this.renderedTiles=[],this.renderedSourceKey_,this.renderedSourceRevision_,this.tempExtent=(0,f.S5)(),this.tempTileRange_=new c.A(0,0,0,0),this.tempTileCoord_=(0,p.N)(0,0,0);const r=void 0!==e.cacheSize?e.cacheSize:512;this.tileCache_=new o.A(r),this.renderedProjection_=void 0,this.maxStaleKeys=.5*r}getTileCache(){return this.tileCache_}getOrCreateTile(t,e,r,n){const i=this.tileCache_,s=this.getLayer().getSource(),o=v(s.getKey(),t,e,r);let a;if(i.containsKey(o))a=i.get(o);else{if(a=s.getTile(t,e,r,n.pixelRatio,n.viewState.projection),!a)return null;i.set(o,a)}return a}getTile(t,e,r,n){return this.getOrCreateTile(t,e,r,n)||null}getData(t){const e=this.frameState;if(!e)return null;const r=this.getLayer(),n=(0,h.Bb)(e.pixelToCoordinateTransform,t.slice()),o=r.getExtent();if(o&&!(0,f.Ym)(o,n))return null;const a=e.viewState,c=r.getRenderSource(),d=c.getTileGridForProjection(a.projection),p=c.getTilePixelRatio(e.pixelRatio);for(let t=d.getZForResolution(a.resolution);t>=d.getMinZoom();--t){const r=d.getTileCoordForCoordAndZ(n,t),o=this.getTile(t,r[1],r[2],e);if(!o||o.getState()!==u.A.LOADED)continue;const h=d.getOrigin(t),f=(0,y.xq)(d.getTileSize(t)),m=d.getResolution(t);let g;if(o instanceof s.A||o instanceof l.A)g=o.getImage();else{if(!(o instanceof i.Ay))continue;if(g=(0,i.xo)(o.getData()),!g)continue}const v=Math.floor(p*((n[0]-h[0])/m-r[1]*f[0])),_=Math.floor(p*((h[1]-n[1])/m-r[2]*f[1])),b=Math.round(p*c.getGutterForProjection(a.projection));return this.getImageData(g,v+b,_+b)}return null}prepareFrame(t){this.renderedProjection_?t.viewState.projection!==this.renderedProjection_&&(this.tileCache_.clear(),this.renderedProjection_=t.viewState.projection):this.renderedProjection_=t.viewState.projection;const e=this.getLayer().getSource();if(!e)return!1;const r=e.getRevision();return this.renderedRevision_?this.renderedRevision_!==r&&(this.renderedRevision_=r,this.renderedSourceKey_===e.getKey()&&this.tileCache_.clear()):this.renderedRevision_=r,!0}enqueueTiles(t,e,r,n,i){const s=t.viewState,o=this.getLayer(),a=o.getRenderSource(),l=a.getTileGridForProjection(s.projection),c=(0,g.v6)(a);c in t.wantedTiles||(t.wantedTiles[c]={});const h=t.wantedTiles[c],d=o.getMapInternal(),f=Math.max(r-i,l.getMinZoom(),l.getZForResolution(Math.min(o.getMaxResolution(),d?d.getView().getResolutionForZoom(Math.max(o.getMinZoom(),0)):l.getResolution(0)),a.zDirection));for(let i=r;i>=f;--i){const r=l.getTileRangeForExtentAndZ(e,i,this.tempTileRange_),s=l.getResolution(i);for(let e=r.minX;e<=r.maxX;++e)for(let o=r.minY;o<=r.maxY;++o){const r=this.getTile(i,e,o,t);if(!r)continue;if(!_(n,r,i))continue;const a=r.getKey();if(h[a]=!0,r.getState()===u.A.IDLE&&!t.tileQueue.isKeyQueued(a)){const n=(0,p.N)(i,e,o,this.tempTileCoord_);t.tileQueue.enqueue([r,c,l.getTileCoordCenter(n),s])}}}}findStaleTile_(t,e){const r=this.tileCache_,n=t[0],i=t[1],s=t[2],o=this.getStaleKeys();for(let t=0;t<o.length;++t){const a=v(o[t],n,i,s);if(r.containsKey(a)){const t=r.get(a);if(t.getState()===u.A.LOADED)return t.endTransition((0,g.v6)(this)),_(e,t,n),!0}}return!1}findAltTiles_(t,e,r,n){const i=t.getTileRangeForTileCoordAndZ(e,r,this.tempTileRange_);if(!i)return!1;let s=!0;const o=this.tileCache_,a=this.getLayer().getRenderSource().getKey();for(let t=i.minX;t<=i.maxX;++t)for(let e=i.minY;e<=i.maxY;++e){const i=v(a,r,t,e);let l=!1;if(o.containsKey(i)){const t=o.get(i);t.getState()===u.A.LOADED&&(_(n,t,r),l=!0)}l||(s=!1)}return s}renderFrame(t,e){this.renderComplete=!0;const r=t.layerStatesArray[t.layerIndex],n=t.viewState,i=n.projection,s=n.resolution,o=n.center,c=t.pixelRatio,p=this.getLayer(),y=p.getSource(),v=y.getRevision(),_=y.getTileGridForProjection(i),x=_.getZForResolution(s,y.zDirection),E=_.getResolution(x),S=y.getKey();this.renderedSourceKey_?this.renderedSourceKey_!==S&&(this.prependStaleKey(this.renderedSourceKey_),this.renderedSourceKey_=S):this.renderedSourceKey_=S;let A=t.extent;const P=y.getTilePixelRatio(c);this.prepareContainer(t,e);const T=this.context.canvas.width,C=this.context.canvas.height,M=r.extent&&(0,m.SD)(r.extent,i);M&&(A=(0,f._N)(A,(0,m.SD)(r.extent,i)));const O=E*T/2/P,R=E*C/2/P,D=[o[0]-O,o[1]-R,o[0]+O,o[1]+R],I={};this.renderedTiles.length=0;const k=p.getPreload();if(t.nextExtent){const e=_.getZForResolution(n.nextResolution,y.zDirection),r=w(t,t.nextExtent);this.enqueueTiles(t,r,e,I,k)}const L=w(t,A);if(this.enqueueTiles(t,L,x,I,0),k>0&&setTimeout((()=>{this.enqueueTiles(t,L,x-1,I,k-1)}),0),!(x in I))return this.container;const F=(0,g.v6)(this),j=t.time;for(const e of I[x]){const r=e.getState();if((e instanceof l.A||e instanceof a.A)&&r===u.A.EMPTY)continue;const n=e.tileCoord;if(r===u.A.LOADED&&1===e.getAlpha(F,j)){e.endTransition(F);continue}if(this.renderComplete=!1,this.findStaleTile_(n,I)){b(I,e,x),t.animate=!0;continue}if(this.findAltTiles_(_,n,x+1,I))continue;const i=_.getMinZoom();for(let t=x-1;t>=i&&!this.findAltTiles_(_,n,t,I);--t);}const N=E/s*c/P,G=this.getRenderContext(t);(0,h.Zz)(this.tempTransform,T/2,C/2,N,N,0,-T/2,-C/2),r.extent&&this.clipUnrotated(G,t,M),y.getInterpolate()||(G.imageSmoothingEnabled=!1),this.preRender(G,t);const $=Object.keys(I).map(Number);let z;$.sort(d.V_);const U=[],B=[];for(let e=$.length-1;e>=0;--e){const r=$[e],n=y.getTilePixelSize(r,c,i),s=_.getResolution(r)/E,o=n[0]*s*N,a=n[1]*s*N,l=_.getTileCoordForCoordAndZ((0,f.Py)(D),r),d=_.getTileCoordExtent(l),p=(0,h.Bb)(this.tempTransform,[P*(d[0]-D[0])/E,P*(D[3]-d[3])/E]),m=P*y.getGutterForProjection(i);for(const e of I[r]){if(e.getState()!==u.A.LOADED)continue;const n=e.tileCoord,i=l[1]-n[1],s=Math.round(p[0]-(i-1)*o),c=l[2]-n[2],h=Math.round(p[1]-(c-1)*a),d=Math.round(p[0]-i*o),g=Math.round(p[1]-c*a),v=s-d,_=h-g,b=1===$.length;let w=!1;z=[d,g,d+v,g,d+v,g+_,d,g+_];for(let t=0,e=U.length;t<e;++t)if(!b&&r<B[t]){const e=U[t];(0,f.HY)([d,g,d+v,g+_],[e[0],e[3],e[4],e[7]])&&(w||(G.save(),w=!0),G.beginPath(),G.moveTo(z[0],z[1]),G.lineTo(z[2],z[3]),G.lineTo(z[4],z[5]),G.lineTo(z[6],z[7]),G.moveTo(e[6],e[7]),G.lineTo(e[4],e[5]),G.lineTo(e[2],e[3]),G.lineTo(e[0],e[1]),G.clip())}U.push(z),B.push(r),this.drawTile(e,t,d,g,v,_,m,b),w&&G.restore(),this.renderedTiles.unshift(e),this.updateUsedTiles(t.usedTiles,y,e)}}return this.renderedRevision=v,this.renderedResolution=E,this.extentChanged=!this.renderedExtent_||!(0,f.aI)(this.renderedExtent_,D),this.renderedExtent_=D,this.renderedPixelRatio=c,this.renderedProjection=i,this.postRender(this.context,t),r.extent&&G.restore(),G.imageSmoothingEnabled=!0,t.postRenderFunctions.push(((t,e)=>{const r=(0,g.v6)(y),n=e.wantedTiles[r],i=n?Object.keys(n).length:0;this.updateCacheSize(i),this.tileCache_.expireCache()})),this.container}updateCacheSize(t){this.tileCache_.highWaterMark=Math.max(this.tileCache_.highWaterMark,2*t)}drawTile(t,e,r,n,s,o,a,l){let c;if(t instanceof i.Ay){if(c=(0,i.xo)(t.getData()),!c)throw new Error("Rendering array data is not yet supported")}else c=this.getTileImage(t);if(!c)return;const u=this.getRenderContext(e),h=(0,g.v6)(this),d=e.layerStatesArray[e.layerIndex],f=d.opacity*(l?t.getAlpha(h,e.time):1),p=f!==u.globalAlpha;p&&(u.save(),u.globalAlpha=f),u.drawImage(c,a,a,c.width-2*a,c.height-2*a,r,n,s,o),p&&u.restore(),f!==d.opacity?e.animate=!0:l&&t.endTransition(h)}getImage(){const t=this.context;return t?t.canvas:null}getTileImage(t){return t.getImage()}updateUsedTiles(t,e,r){const n=(0,g.v6)(e);n in t||(t[n]={}),t[n][r.getKey()]=!0}}const E=x},75454:(t,e,r)=>{"use strict";r.d(e,{Eo:()=>a,gY:()=>c,j:()=>l,nl:()=>u});var n=r(39915),i=r(98629);const s=.5,o={Point:function(t,e,r,i,s,o){const a=r.getImage(),l=r.getText(),c=l&&l.getText(),u=o&&a&&c?{}:void 0;if(a){if(a.getImageState()!=n.A.LOADED)return;const o=t.getBuilder(r.getZIndex(),"Image");o.setImageStyle(a,u),o.drawPoint(e,i,s)}if(c){const n=t.getBuilder(r.getZIndex(),"Text");n.setTextStyle(l,u),n.drawText(e,i,s)}},LineString:function(t,e,r,n,i){const s=r.getStroke();if(s){const o=t.getBuilder(r.getZIndex(),"LineString");o.setFillStrokeStyle(null,s),o.drawLineString(e,n,i)}const o=r.getText();if(o&&o.getText()){const s=t.getBuilder(r.getZIndex(),"Text");s.setTextStyle(o),s.drawText(e,n,i)}},Polygon:function(t,e,r,n,i){const s=r.getFill(),o=r.getStroke();if(s||o){const a=t.getBuilder(r.getZIndex(),"Polygon");a.setFillStrokeStyle(s,o),a.drawPolygon(e,n,i)}const a=r.getText();if(a&&a.getText()){const s=t.getBuilder(r.getZIndex(),"Text");s.setTextStyle(a),s.drawText(e,n,i)}},MultiPoint:function(t,e,r,i,s,o){const a=r.getImage(),l=a&&0!==a.getOpacity(),c=r.getText(),u=c&&c.getText(),h=o&&l&&u?{}:void 0;if(l){if(a.getImageState()!=n.A.LOADED)return;const o=t.getBuilder(r.getZIndex(),"Image");o.setImageStyle(a,h),o.drawMultiPoint(e,i,s)}if(u){const n=t.getBuilder(r.getZIndex(),"Text");n.setTextStyle(c,h),n.drawText(e,i,s)}},MultiLineString:function(t,e,r,n,i){const s=r.getStroke();if(s){const o=t.getBuilder(r.getZIndex(),"LineString");o.setFillStrokeStyle(null,s),o.drawMultiLineString(e,n,i)}const o=r.getText();if(o&&o.getText()){const s=t.getBuilder(r.getZIndex(),"Text");s.setTextStyle(o),s.drawText(e,n,i)}},MultiPolygon:function(t,e,r,n,i){const s=r.getFill(),o=r.getStroke();if(o||s){const a=t.getBuilder(r.getZIndex(),"Polygon");a.setFillStrokeStyle(s,o),a.drawMultiPolygon(e,n,i)}const a=r.getText();if(a&&a.getText()){const s=t.getBuilder(r.getZIndex(),"Text");s.setTextStyle(a),s.drawText(e,n,i)}},GeometryCollection:function(t,e,r,n,i,s){const a=e.getGeometriesArray();let l,c;for(l=0,c=a.length;l<c;++l)(0,o[a[l].getType()])(t,a[l],r,n,i,s)},Circle:function(t,e,r,n,i){const s=r.getFill(),o=r.getStroke();if(s||o){const a=t.getBuilder(r.getZIndex(),"Circle");a.setFillStrokeStyle(s,o),a.drawCircle(e,n,i)}const a=r.getText();if(a&&a.getText()){const i=t.getBuilder(r.getZIndex(),"Text");i.setTextStyle(a),i.drawText(e,n)}}};function a(t,e){return parseInt((0,i.v6)(t),10)-parseInt((0,i.v6)(e),10)}function l(t,e){const r=c(t,e);return r*r}function c(t,e){return s*t/e}function u(t,e,r,i,s,a,l,c){const u=[],d=r.getImage();if(d){let t=!0;const e=d.getImageState();e==n.A.LOADED||e==n.A.ERROR?t=!1:e==n.A.IDLE&&d.load(),t&&u.push(d.ready())}const f=r.getFill();f&&f.loading()&&u.push(f.ready());const p=u.length>0;return p&&Promise.all(u).then((()=>s(null))),function(t,e,r,n,i,s,a){const l=r.getGeometryFunction()(e);if(!l)return;const c=l.simplifyTransformed(n,i);r.getRenderer()?h(t,c,r,e,a):(0,o[c.getType()])(t,c,r,e,a,s)}(t,e,r,i,a,l,c),p}function h(t,e,r,n,i){if("GeometryCollection"!=e.getType())t.getBuilder(r.getZIndex(),"Default").drawCustom(e,n,r.getRenderer(),r.getHitDetectionRenderer(),i);else{const s=e.getGeometries();for(let e=0,o=s.length;e<o;++e)h(t,s[e],r,n,i)}}},2175:(t,e,r)=>{"use strict";r.d(e,{BV:()=>l,KQ:()=>h,XX:()=>f,aY:()=>d});var n=r(44509),i=r(83085),s=r(12940),o=r(72475);let a;const l=[];function c(t,e,r,n,i){t.beginPath(),t.moveTo(0,0),t.lineTo(e,r),t.lineTo(n,i),t.closePath(),t.save(),t.clip(),t.fillRect(0,0,Math.max(e,n)+1,Math.max(r,i)),t.restore()}function u(t,e){return Math.abs(t[4*e]-210)>2||Math.abs(t[4*e+3]-191.25)>2}function h(t,e,r,i){const o=(0,s.pd)(r,e,t);let a=(0,s.hO)(e,i,r);const l=e.getMetersPerUnit();void 0!==l&&(a*=l);const c=t.getMetersPerUnit();void 0!==c&&(a/=c);const u=t.getExtent();if(!u||(0,n.Ym)(u,o)){const e=(0,s.hO)(t,a,o)/a;isFinite(e)&&e>0&&(a/=e)}return a}function d(t,e,r,i){const s=(0,n.q1)(r);let o=h(t,e,s,i);return(!isFinite(o)||o<=0)&&(0,n.sB)(r,(function(r){return o=h(t,e,r,i),isFinite(o)&&o>0})),o}function f(t,e,r,s,h,d,f,p,m,g,y,v,_,b){const w=(0,i.Y)(Math.round(r*t),Math.round(r*e),l);if(v||(w.imageSmoothingEnabled=!1),0===m.length)return w.canvas;function x(t){return Math.round(t*r)/r}w.scale(r,r),w.globalCompositeOperation="lighter";const E=(0,n.S5)();let S;m.forEach((function(t,e,r){(0,n.X$)(E,t.extent)}));const A=r/s,P=(v?1:1+Math.pow(2,-24))/A;if(!_||1!==m.length||0!==g){if(S=(0,i.Y)(Math.round((0,n.RG)(E)*A),Math.round((0,n.Oq)(E)*A),l),v||(S.imageSmoothingEnabled=!1),h&&b){const t=(h[0]-E[0])*A,e=-(h[3]-E[3])*A,r=(0,n.RG)(h)*A,i=(0,n.Oq)(h)*A;S.rect(t,e,r,i),S.clip()}m.forEach((function(t,e,r){if(t.image.width>0&&t.image.height>0){if(t.clipExtent){S.save();const e=(t.clipExtent[0]-E[0])*A,r=-(t.clipExtent[3]-E[3])*A,i=(0,n.RG)(t.clipExtent)*A,s=(0,n.Oq)(t.clipExtent)*A;S.rect(v?e:Math.round(e),v?r:Math.round(r),v?i:Math.round(e+i)-Math.round(e),v?s:Math.round(r+s)-Math.round(r)),S.clip()}const e=(t.extent[0]-E[0])*A,r=-(t.extent[3]-E[3])*A,i=(0,n.RG)(t.extent)*A,s=(0,n.Oq)(t.extent)*A;S.drawImage(t.image,g,g,t.image.width-2*g,t.image.height-2*g,v?e:Math.round(e),v?r:Math.round(r),v?i:Math.round(e+i)-Math.round(e),v?s:Math.round(r+s)-Math.round(r)),t.clipExtent&&S.restore()}}))}const T=(0,n.Py)(f);return p.getTriangles().forEach((function(t,e,r){const s=t.source,h=t.target;let f=s[0][0],p=s[0][1],g=s[1][0],y=s[1][1],_=s[2][0],b=s[2][1];const A=x((h[0][0]-T[0])/d),C=x(-(h[0][1]-T[1])/d),M=x((h[1][0]-T[0])/d),O=x(-(h[1][1]-T[1])/d),R=x((h[2][0]-T[0])/d),D=x(-(h[2][1]-T[1])/d),I=f,k=p;f=0,p=0,g-=I,y-=k,_-=I,b-=k;const L=[[g,y,0,0,M-A],[_,b,0,0,R-A],[0,0,g,y,O-C],[0,0,_,b,D-C]],F=(0,o.KU)(L);if(!F)return;if(w.save(),w.beginPath(),function(){if(void 0===a){const t=(0,i.Y)(6,6,l);t.globalCompositeOperation="lighter",t.fillStyle="rgba(210, 0, 0, 0.75)",c(t,4,5,4,0),c(t,4,5,0,5);const e=t.getImageData(0,0,3,3).data;a=u(e,0)||u(e,4)||u(e,8),(0,i.Yg)(t),l.push(t.canvas)}return a}()||!v){w.moveTo(M,O);const t=4,e=A-M,r=C-O;for(let n=0;n<t;n++)w.lineTo(M+x((n+1)*e/t),O+x(n*r/(t-1))),n!=t-1&&w.lineTo(M+x((n+1)*e/t),O+x((n+1)*r/(t-1)));w.lineTo(R,D)}else w.moveTo(M,O),w.lineTo(A,C),w.lineTo(R,D);let j;if(w.clip(),w.transform(F[0],F[2],F[1],F[3],A,C),w.translate(E[0]-I,E[3]-k),S)j=S.canvas,w.scale(P,-P);else{const t=m[0],e=t.extent;j=t.image,w.scale((0,n.RG)(e)/j.width,-(0,n.Oq)(e)/j.height)}w.drawImage(j,0,0),w.restore()})),S&&((0,i.Yg)(S),l.push(S.canvas)),y&&(w.save(),w.globalCompositeOperation="source-over",w.strokeStyle="black",w.lineWidth=1,p.getTriangles().forEach((function(t,e,r){const n=t.target,i=(n[0][0]-T[0])/d,s=-(n[0][1]-T[1])/d,o=(n[1][0]-T[0])/d,a=-(n[1][1]-T[1])/d,l=(n[2][0]-T[0])/d,c=-(n[2][1]-T[1])/d;w.beginPath(),w.moveTo(o,a),w.lineTo(i,s),w.lineTo(l,c),w.closePath(),w.stroke()})),w.restore()),w.canvas}},91202:(t,e,r)=>{"use strict";r.d(e,{A:()=>p});var n=r(35035),i=r(97141),s=r(24187),o=r(20884),a=r(14695),l=r(2175),c=r(72475),u=r(83085),h=r(44509),d=r(94456);class f extends i.Ay{constructor(t){super({tileCoord:t.tileCoord,loader:()=>Promise.resolve(new Uint8ClampedArray(4)),interpolate:t.interpolate,transition:t.transition}),this.pixelRatio_=t.pixelRatio,this.gutter_=t.gutter,this.reprojData_=null,this.reprojError_=null,this.reprojSize_=void 0,this.sourceTileGrid_=t.sourceTileGrid,this.targetTileGrid_=t.targetTileGrid,this.wrappedTileCoord_=t.wrappedTileCoord||t.tileCoord,this.sourceTiles_=[],this.sourcesListenerKeys_=null,this.sourceZ_=0;const e=t.sourceProj,r=e.getExtent(),i=t.sourceTileGrid.getExtent();this.clipExtent_=e.canWrapX()?i?(0,h._N)(r,i):r:i;const s=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_),u=this.targetTileGrid_.getExtent();let d=this.sourceTileGrid_.getExtent();const f=u?(0,h._N)(s,u):s;if(0===(0,h.UG)(f))return void(this.state=o.A.EMPTY);r&&(d=d?(0,h._N)(d,r):r);const p=this.targetTileGrid_.getResolution(this.wrappedTileCoord_[0]),m=t.targetProj,g=(0,l.aY)(e,m,f,p);if(!isFinite(g)||g<=0)return void(this.state=o.A.EMPTY);const y=void 0!==t.errorThreshold?t.errorThreshold:n.l;if(this.triangulation_=new a.A(e,m,f,d,g*y,p),0===this.triangulation_.getTriangles().length)return void(this.state=o.A.EMPTY);this.sourceZ_=this.sourceTileGrid_.getZForResolution(g);let v=this.triangulation_.calculateSourceExtent();if(d&&(e.canWrapX()?(v[1]=(0,c.qE)(v[1],d[1],d[3]),v[3]=(0,c.qE)(v[3],d[1],d[3])):v=(0,h._N)(v,d)),(0,h.UG)(v)){let n=0,i=0;e.canWrapX()&&(n=(0,h.RG)(r),i=Math.floor((v[0]-r[0])/n)),(0,h.QJ)(v.slice(),e,!0).forEach((e=>{const r=this.sourceTileGrid_.getTileRangeForExtentAndZ(e,this.sourceZ_),s=t.getTileFunction;for(let t=r.minX;t<=r.maxX;t++)for(let e=r.minY;e<=r.maxY;e++){const r=s(this.sourceZ_,t,e,this.pixelRatio_);if(r){const t=i*n;this.sourceTiles_.push({tile:r,offset:t})}}++i})),0===this.sourceTiles_.length&&(this.state=o.A.EMPTY)}else this.state=o.A.EMPTY}getSize(){return this.reprojSize_}getData(){return this.reprojData_}getError(){return this.reprojError_}reproject_(){const t=[];let e=!1;if(this.sourceTiles_.forEach((r=>{const n=r.tile;if(!n||n.getState()!==o.A.LOADED)return;const s=n.getSize(),a=this.gutter_;let l;const c=(0,i.bL)(n.getData());c?l=c:(e=!0,l=(0,i.$r)((0,i.xo)(n.getData())));const u=[s[0]+2*a,s[1]+2*a],h=l instanceof Float32Array,d=u[0]*u[1],f=h?Float32Array:Uint8ClampedArray,p=new f(l.buffer),m=f.BYTES_PER_ELEMENT,g=m*p.length/d,y=p.byteLength/u[1],v=Math.floor(y/m/u[0]),_=d*v;let b=p;if(p.length!==_){b=new f(_);let t=0,e=0;const r=u[0]*v;for(let n=0;n<u[1];++n){for(let n=0;n<r;++n)b[t++]=p[e+n];e+=y/m}}const w=this.sourceTileGrid_.getTileCoordExtent(n.tileCoord);w[0]+=r.offset,w[2]+=r.offset;const x=this.clipExtent_?.slice();x&&(x[0]+=r.offset,x[2]+=r.offset),t.push({extent:w,clipExtent:x,data:new Uint8ClampedArray(b.buffer),dataType:f,bytesPerPixel:g,pixelSize:u})})),this.sourceTiles_.length=0,0===t.length)return this.state=o.A.ERROR,void this.changed();const r=this.wrappedTileCoord_[0],n=this.targetTileGrid_.getTileSize(r),s="number"==typeof n?n:n[0],a="number"==typeof n?n:n[1],c=this.targetTileGrid_.getResolution(r),h=this.sourceTileGrid_.getResolution(this.sourceZ_),d=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_);let f,p;const m=t[0].bytesPerPixel;for(let e=Math.ceil(m/3)-1;e>=0;--e){const r=[];for(let n=0,i=t.length;n<i;++n){const i=t[n],s=i.data,o=i.pixelSize,a=o[0],c=o[1],h=(0,u.Y)(a,c,l.BV),d=h.createImageData(a,c),f=d.data;let p=3*e;for(let t=0,e=f.length;t<e;t+=4)f[t]=s[p],f[t+1]=s[p+1],f[t+2]=s[p+2],f[t+3]=255,p+=m;h.putImageData(d,0,0),r.push({extent:i.extent,clipExtent:i.clipExtent,image:h.canvas})}const n=(0,l.XX)(s,a,this.pixelRatio_,h,this.sourceTileGrid_.getExtent(),c,d,this.triangulation_,r,this.gutter_,!1,!1,!1);for(let t=0,e=r.length;t<e;++t){const e=r[t].image.getContext("2d");(0,u.Yg)(e),l.BV.push(e.canvas)}const i=n.getContext("2d"),o=i.getImageData(0,0,n.width,n.height);(0,u.Yg)(i),l.BV.push(n),f||(p=new Uint8ClampedArray(m*o.width*o.height),f=new t[0].dataType(p.buffer));const g=o.data;let y=3*e;for(let t=0,e=g.length;t<e;t+=4)255===g[t+3]?(p[y]=g[t],p[y+1]=g[t+1],p[y+2]=g[t+2]):(p[y]=0,p[y+1]=0,p[y+2]=0),y+=m}if(e){const t=(0,u.Y)(s,a),e=new ImageData(f,s);t.putImageData(e,0,0),this.reprojData_=t.canvas}else this.reprojData_=f;this.reprojSize_=[Math.round(s*this.pixelRatio_),Math.round(a*this.pixelRatio_)],this.state=o.A.LOADED,this.changed()}load(){if(this.state!==o.A.IDLE&&this.state!==o.A.ERROR)return;this.state=o.A.LOADING,this.changed();let t=0;this.sourcesListenerKeys_=[],this.sourceTiles_.forEach((({tile:e})=>{const r=e.getState();if(r!==o.A.IDLE&&r!==o.A.LOADING)return;t++;const n=(0,d.KT)(e,s.A.CHANGE,(()=>{const r=e.getState();r!=o.A.LOADED&&r!=o.A.ERROR&&r!=o.A.EMPTY||((0,d.JH)(n),t--,0===t&&(this.unlistenSources_(),this.reproject_()))}));this.sourcesListenerKeys_.push(n)})),0===t?setTimeout(this.reproject_.bind(this),0):this.sourceTiles_.forEach((function({tile:t}){t.getState()==o.A.IDLE&&t.load()}))}unlistenSources_(){this.sourcesListenerKeys_.forEach(d.JH),this.sourcesListenerKeys_=null}}const p=f},84562:(t,e,r)=>{"use strict";r.d(e,{A:()=>p});var n=r(35035),i=r(24187),s=r(76741),o=r(20884),a=r(14695),l=r(2175),c=r(72475),u=r(44509),h=r(94456),d=r(83085);class f extends s.A{constructor(t,e,r,i,s,h,d,f,p,m,g,y){super(s,o.A.IDLE,y),this.renderEdges_=void 0!==g&&g,this.pixelRatio_=d,this.gutter_=f,this.canvas_=null,this.sourceTileGrid_=e,this.targetTileGrid_=i,this.wrappedTileCoord_=h||s,this.sourceTiles_=[],this.sourcesListenerKeys_=null,this.sourceZ_=0,this.clipExtent_=t.canWrapX()?t.getExtent():void 0;const v=i.getTileCoordExtent(this.wrappedTileCoord_),_=this.targetTileGrid_.getExtent();let b=this.sourceTileGrid_.getExtent();const w=_?(0,u._N)(v,_):v;if(0===(0,u.UG)(w))return void(this.state=o.A.EMPTY);const x=t.getExtent();x&&(b=b?(0,u._N)(b,x):x);const E=i.getResolution(this.wrappedTileCoord_[0]),S=(0,l.aY)(t,r,w,E);if(!isFinite(S)||S<=0)return void(this.state=o.A.EMPTY);const A=void 0!==m?m:n.l;if(this.triangulation_=new a.A(t,r,w,b,S*A,E),0===this.triangulation_.getTriangles().length)return void(this.state=o.A.EMPTY);this.sourceZ_=e.getZForResolution(S);let P=this.triangulation_.calculateSourceExtent();if(b&&(t.canWrapX()?(P[1]=(0,c.qE)(P[1],b[1],b[3]),P[3]=(0,c.qE)(P[3],b[1],b[3])):P=(0,u._N)(P,b)),(0,u.UG)(P)){let r=0,n=0;t.canWrapX()&&(r=(0,u.RG)(x),n=Math.floor((P[0]-x[0])/r)),(0,u.QJ)(P.slice(),t,!0).forEach((t=>{const i=e.getTileRangeForExtentAndZ(t,this.sourceZ_);for(let t=i.minX;t<=i.maxX;t++)for(let e=i.minY;e<=i.maxY;e++){const i=p(this.sourceZ_,t,e,d);if(i){const t=n*r;this.sourceTiles_.push({tile:i,offset:t})}}++n})),0===this.sourceTiles_.length&&(this.state=o.A.EMPTY)}else this.state=o.A.EMPTY}getImage(){return this.canvas_}reproject_(){const t=[];if(this.sourceTiles_.forEach((e=>{const r=e.tile;if(r&&r.getState()==o.A.LOADED){const n=this.sourceTileGrid_.getTileCoordExtent(r.tileCoord);n[0]+=e.offset,n[2]+=e.offset;const i=this.clipExtent_?.slice();i&&(i[0]+=e.offset,i[2]+=e.offset),t.push({extent:n,clipExtent:i,image:r.getImage()})}})),this.sourceTiles_.length=0,0===t.length)this.state=o.A.ERROR;else{const e=this.wrappedTileCoord_[0],r=this.targetTileGrid_.getTileSize(e),n="number"==typeof r?r:r[0],i="number"==typeof r?r:r[1],s=this.targetTileGrid_.getResolution(e),a=this.sourceTileGrid_.getResolution(this.sourceZ_),c=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_);this.canvas_=(0,l.XX)(n,i,this.pixelRatio_,a,this.sourceTileGrid_.getExtent(),s,c,this.triangulation_,t,this.gutter_,this.renderEdges_,this.interpolate),this.state=o.A.LOADED}this.changed()}load(){if(this.state==o.A.IDLE){this.state=o.A.LOADING,this.changed();let t=0;this.sourcesListenerKeys_=[],this.sourceTiles_.forEach((({tile:e})=>{const r=e.getState();if(r==o.A.IDLE||r==o.A.LOADING){t++;const r=(0,h.KT)(e,i.A.CHANGE,(n=>{const i=e.getState();i!=o.A.LOADED&&i!=o.A.ERROR&&i!=o.A.EMPTY||((0,h.JH)(r),t--,0===t&&(this.unlistenSources_(),this.reproject_()))}));this.sourcesListenerKeys_.push(r)}})),0===t?setTimeout(this.reproject_.bind(this),0):this.sourceTiles_.forEach((function({tile:t},e,r){t.getState()==o.A.IDLE&&t.load()}))}}unlistenSources_(){this.sourcesListenerKeys_.forEach(h.JH),this.sourcesListenerKeys_=null}release(){this.canvas_&&((0,d.Yg)(this.canvas_.getContext("2d")),l.BV.push(this.canvas_),this.canvas_=null),super.release()}}const p=f},14695:(t,e,r)=>{"use strict";r.d(e,{A:()=>o});var n=r(44509),i=r(12940),s=r(72475);const o=class{constructor(t,e,r,s,o,a){this.sourceProj_=t,this.targetProj_=e;let l={};const c=(0,i.RG)(this.targetProj_,this.sourceProj_);this.transformInv_=function(t){const e=t[0]+"/"+t[1];return l[e]||(l[e]=c(t)),l[e]},this.maxSourceExtent_=s,this.errorThresholdSquared_=o*o,this.triangles_=[],this.wrapsXInSource_=!1,this.canWrapXInSource_=this.sourceProj_.canWrapX()&&!!s&&!!this.sourceProj_.getExtent()&&(0,n.RG)(s)>=(0,n.RG)(this.sourceProj_.getExtent()),this.sourceWorldWidth_=this.sourceProj_.getExtent()?(0,n.RG)(this.sourceProj_.getExtent()):null,this.targetWorldWidth_=this.targetProj_.getExtent()?(0,n.RG)(this.targetProj_.getExtent()):null;const u=(0,n.Py)(r),h=(0,n.WU)(r),d=(0,n.k_)(r),f=(0,n.R)(r),p=this.transformInv_(u),m=this.transformInv_(h),g=this.transformInv_(d),y=this.transformInv_(f),v=10+(a?Math.max(0,Math.ceil(Math.log2((0,n.UG)(r)/(a*a*256*256)))):0);if(this.addQuad_(u,h,d,f,p,m,g,y,v),this.wrapsXInSource_){let t=1/0;this.triangles_.forEach((function(e,r,n){t=Math.min(t,e.source[0][0],e.source[1][0],e.source[2][0])})),this.triangles_.forEach((e=>{if(Math.max(e.source[0][0],e.source[1][0],e.source[2][0])-t>this.sourceWorldWidth_/2){const r=[[e.source[0][0],e.source[0][1]],[e.source[1][0],e.source[1][1]],[e.source[2][0],e.source[2][1]]];r[0][0]-t>this.sourceWorldWidth_/2&&(r[0][0]-=this.sourceWorldWidth_),r[1][0]-t>this.sourceWorldWidth_/2&&(r[1][0]-=this.sourceWorldWidth_),r[2][0]-t>this.sourceWorldWidth_/2&&(r[2][0]-=this.sourceWorldWidth_);const n=Math.min(r[0][0],r[1][0],r[2][0]);Math.max(r[0][0],r[1][0],r[2][0])-n<this.sourceWorldWidth_/2&&(e.source=r)}}))}l={}}addTriangle_(t,e,r,n,i,s){this.triangles_.push({source:[n,i,s],target:[t,e,r]})}addQuad_(t,e,r,i,o,a,l,c,u){const h=(0,n.Tr)([o,a,l,c]),d=this.sourceWorldWidth_?(0,n.RG)(h)/this.sourceWorldWidth_:null,f=this.sourceWorldWidth_,p=this.sourceProj_.canWrapX()&&d>.5&&d<1;let m=!1;if(u>0){if(this.targetProj_.isGlobal()&&this.targetWorldWidth_){const s=(0,n.Tr)([t,e,r,i]);m=(0,n.RG)(s)/this.targetWorldWidth_>.25||m}!p&&this.sourceProj_.isGlobal()&&d&&(m=d>.25||m)}if(!m&&this.maxSourceExtent_&&isFinite(h[0])&&isFinite(h[1])&&isFinite(h[2])&&isFinite(h[3])&&!(0,n.HY)(h,this.maxSourceExtent_))return;let g=0;if(!(m||isFinite(o[0])&&isFinite(o[1])&&isFinite(a[0])&&isFinite(a[1])&&isFinite(l[0])&&isFinite(l[1])&&isFinite(c[0])&&isFinite(c[1])))if(u>0)m=!0;else if(g=(isFinite(o[0])&&isFinite(o[1])?0:8)+(isFinite(a[0])&&isFinite(a[1])?0:4)+(isFinite(l[0])&&isFinite(l[1])?0:2)+(isFinite(c[0])&&isFinite(c[1])?0:1),1!=g&&2!=g&&4!=g&&8!=g)return;if(u>0){if(!m){const e=[(t[0]+r[0])/2,(t[1]+r[1])/2],n=this.transformInv_(e);let i;i=p?((0,s.xP)(o[0],f)+(0,s.xP)(l[0],f))/2-(0,s.xP)(n[0],f):(o[0]+l[0])/2-n[0];const a=(o[1]+l[1])/2-n[1];m=i*i+a*a>this.errorThresholdSquared_}if(m){if(Math.abs(t[0]-r[0])<=Math.abs(t[1]-r[1])){const n=[(e[0]+r[0])/2,(e[1]+r[1])/2],s=this.transformInv_(n),h=[(i[0]+t[0])/2,(i[1]+t[1])/2],d=this.transformInv_(h);this.addQuad_(t,e,n,h,o,a,s,d,u-1),this.addQuad_(h,n,r,i,d,s,l,c,u-1)}else{const n=[(t[0]+e[0])/2,(t[1]+e[1])/2],s=this.transformInv_(n),h=[(r[0]+i[0])/2,(r[1]+i[1])/2],d=this.transformInv_(h);this.addQuad_(t,n,h,i,o,s,d,c,u-1),this.addQuad_(n,e,r,h,s,a,l,d,u-1)}return}}if(p){if(!this.canWrapXInSource_)return;this.wrapsXInSource_=!0}11&g||this.addTriangle_(t,r,i,o,l,c),14&g||this.addTriangle_(t,r,e,o,l,a),g&&(13&g||this.addTriangle_(e,i,t,a,c,o),7&g||this.addTriangle_(e,i,r,a,c,l))}calculateSourceExtent(){const t=(0,n.S5)();return this.triangles_.forEach((function(e,r,i){const s=e.source;(0,n.$C)(t,s[0]),(0,n.$C)(t,s[1]),(0,n.$C)(t,s[2])})),t}getTriangles(){return this.triangles_}}},35035:(t,e,r)=>{"use strict";r.d(e,{l:()=>n});const n=.5},26392:(t,e,r)=>{"use strict";r.d(e,{a$:()=>o,b8:()=>i,cq:()=>a,dv:()=>s});var n=r(72475);function i(t){if(void 0!==t)return 0}function s(t){if(void 0!==t)return t}function o(t){const e=2*Math.PI/t;return function(t,r){return r?t:void 0!==t?t=Math.floor(t/e+.5)*e:void 0}}function a(t){const e=void 0===t?(0,n.eh)(5):t;return function(t,r){return r||void 0===t?t:Math.abs(t)<=e?0:t}}},53908:(t,e,r)=>{"use strict";function n(t){return t[0]>0&&t[1]>0}function i(t,e,r){return void 0===r&&(r=[0,0]),r[0]=t[0]*e+.5|0,r[1]=t[1]*e+.5|0,r}function s(t,e){return Array.isArray(t)?t:(void 0===e?e=[t,t]:(e[0]=t,e[1]=t),e)}r.d(e,{Ie:()=>n,hs:()=>i,xq:()=>s})},15159:(t,e,r)=>{"use strict";r.d(e,{A:()=>m});var n=r(97141),i=r(24187),s=r(91202),o=r(67663),a=r(17903),l=r(20884),c=r(32077),u=r(12940),h=r(98629),d=r(97440),f=r(53908);class p extends a.A{constructor(t){const e=void 0===t.projection?"EPSG:3857":t.projection;let r=t.tileGrid;void 0===r&&e&&(r=(0,c.EN)({extent:(0,c.kZ)(e),maxResolution:t.maxResolution,maxZoom:t.maxZoom,minZoom:t.minZoom,tileSize:t.tileSize})),super({cacheSize:.1,attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,projection:e,tileGrid:r,state:t.state,wrapX:t.wrapX,transition:t.transition,interpolate:t.interpolate,key:t.key}),this.gutter_=void 0!==t.gutter?t.gutter:0,this.tileSize_=t.tileSize?(0,f.xq)(t.tileSize):null,this.tileSizes_=null,this.tileLoadingKeys_={},this.loader_=t.loader,this.handleTileChange_=this.handleTileChange_.bind(this),this.bandCount=void 0===t.bandCount?4:t.bandCount,this.tileGridForProjection_={},this.crossOrigin_=t.crossOrigin||"anonymous"}setTileSizes(t){this.tileSizes_=t}getTileSize(t){if(this.tileSizes_)return this.tileSizes_[t];if(this.tileSize_)return this.tileSize_;const e=this.getTileGrid();return e?(0,f.xq)(e.getTileSize(t)):[256,256]}getGutterForProjection(t){const e=this.getProjection();return!e||(0,u.tI)(e,t)?this.gutter_:0}setLoader(t){this.loader_=t}getReprojTile_(t,e,r,n,i){const o=this.getTileGrid(),a=Math.max.apply(null,o.getResolutions().map(((t,e)=>{const r=(0,f.xq)(o.getTileSize(e)),n=this.getTileSize(e);return Math.max(n[0]/r[0],n[1]/r[1])}))),l=this.getTileGridForProjection(i),c=this.getTileGridForProjection(n),u=[t,e,r],h=this.getTileCoordForTileUrlFunction(u,n),d=Object.assign({sourceProj:i,sourceTileGrid:l,targetProj:n,targetTileGrid:c,tileCoord:u,wrappedTileCoord:h,pixelRatio:a,gutter:this.getGutterForProjection(i),getTileFunction:(t,e,r,n)=>this.getTile(t,e,r,n,i)},this.tileOptions),p=new s.A(d);return p.key=this.getKey(),p}getTile(t,e,r,s,o){const a=this.getProjection();if(a&&o&&!(0,u.tI)(a,o))return this.getReprojTile_(t,e,r,o,a);const l=this.getTileSize(t),c=this.loader_,h=new AbortController,f={signal:h.signal,crossOrigin:this.crossOrigin_},p=this.getTileCoordForTileUrlFunction([t,e,r]);if(!p)return null;const m=p[0],g=p[1],y=p[2],v=Object.assign({tileCoord:[t,e,r],loader:function(){return(0,d.hq)((function(){return c(m,g,y,f)}))},size:l,controller:h},this.tileOptions),_=new n.Ay(v);return _.key=this.getKey(),_.addEventListener(i.A.CHANGE,this.handleTileChange_),_}handleTileChange_(t){const e=t.target,r=(0,h.v6)(e),n=e.getState();let i;n==l.A.LOADING?(this.tileLoadingKeys_[r]=!0,i=o.A.TILELOADSTART):r in this.tileLoadingKeys_&&(delete this.tileLoadingKeys_[r],i=n==l.A.ERROR?o.A.TILELOADERROR:n==l.A.LOADED?o.A.TILELOADEND:void 0),i&&this.dispatchEvent(new a.c(i,e))}getTileGridForProjection(t){const e=this.getProjection();if(this.tileGrid&&(!e||(0,u.tI)(e,t)))return this.tileGrid;const r=(0,h.v6)(t);return r in this.tileGridForProjection_||(this.tileGridForProjection_[r]=(0,c.pr)(t)),this.tileGridForProjection_[r]}setTileGridForProjection(t,e){const r=(0,u.Jt)(t);if(r){const t=(0,h.v6)(r);t in this.tileGridForProjection_||(this.tileGridForProjection_[t]=e)}}}const m=p},64827:(t,e,r)=>{"use strict";r.d(e,{A:()=>ke});var n=r(15159),i=r(17668),s=r(74244);const o=new Map;function a(t,e){Array.isArray(t)||(t=[t]),t.forEach((t=>o.set(t,e)))}async function l(t){const e=o.get(t.Compression);if(!e)throw new Error(`Unknown compression method identifier: ${t.Compression}`);return new(await e())(t)}a([void 0,1],(()=>r.e(407).then(r.bind(r,3407)).then((t=>t.default)))),a(5,(()=>r.e(154).then(r.bind(r,87154)).then((t=>t.default)))),a(6,(()=>{throw new Error("old style JPEG compression is not supported.")})),a(7,(()=>r.e(555).then(r.bind(r,50555)).then((t=>t.default)))),a([8,32946],(()=>Promise.all([r.e(552),r.e(618)]).then(r.bind(r,20618)).then((t=>t.default)))),a(32773,(()=>r.e(472).then(r.bind(r,58472)).then((t=>t.default)))),a(34887,(()=>Promise.all([r.e(552),r.e(27)]).then(r.bind(r,71027)).then((async t=>(await t.zstd.init(),t))).then((t=>t.default)))),a(50001,(()=>r.e(542).then(r.bind(r,5542)).then((t=>t.default))));const c="undefined"!=typeof navigator&&navigator.hardwareConcurrency||2,u=class{constructor(t=c,e){this.workers=null,this._awaitingDecoder=null,this.size=t,this.messageId=0,t&&(this._awaitingDecoder=e?Promise.resolve(e):new Promise((t=>{r.e(460).then(r.bind(r,82460)).then((e=>{t(e.create)}))})),this._awaitingDecoder.then((e=>{this._awaitingDecoder=null,this.workers=[];for(let r=0;r<t;r++)this.workers.push({worker:e(),idle:!0})})))}async decode(t,e){return this._awaitingDecoder&&await this._awaitingDecoder,0===this.size?l(t).then((r=>r.decode(t,e))):new Promise((r=>{const n=this.workers.find((t=>t.idle))||this.workers[Math.floor(Math.random()*this.size)];n.idle=!1;const i=this.messageId++,s=t=>{t.data.id===i&&(n.idle=!0,r(t.data.decoded),n.worker.removeEventListener("message",s))};n.worker.addEventListener("message",s),n.worker.postMessage({fileDirectory:t,buffer:e,id:i},[e])}))}destroy(){this.workers&&(this.workers.forEach((t=>{t.worker.terminate()})),this.workers=null)}};function h(t){return(e,...r)=>f(t,e,r)}function d(t,e){return h(y(t,e).get)}const{apply:f,construct:p,defineProperty:m,get:g,getOwnPropertyDescriptor:y,getPrototypeOf:v,has:_,ownKeys:b,set:w,setPrototypeOf:x}=Reflect,{EPSILON:E,MAX_SAFE_INTEGER:S,isFinite:A,isNaN:P}=Number,{iterator:T,species:C,toStringTag:M,for:O}=Symbol,R=Object,{create:D,defineProperty:I,freeze:k,is:L}=R,F=R.prototype,j=(F.__lookupGetter__&&h(F.__lookupGetter__),R.hasOwn||h(F.hasOwnProperty),Array),N=(j.isArray,j.prototype),G=(h(N.join),h(N.push),h(N.toLocaleString),N[T]),$=h(G),{abs:z,trunc:U}=Math,B=ArrayBuffer,V=(B.isView,B.prototype),q=(h(V.slice),d(V,"byteLength"),"undefined"!=typeof SharedArrayBuffer?SharedArrayBuffer:null),K=(q&&d(q.prototype,"byteLength"),v(Uint8Array)),W=(K.from,K.prototype),H=(W[T],h(W.keys),h(W.values),h(W.entries),h(W.set),h(W.reverse),h(W.fill),h(W.copyWithin),h(W.sort),h(W.slice),h(W.subarray),d(W,"buffer"),d(W,"byteOffset"),d(W,"length"),d(W,M),Uint8Array),Y=Uint16Array,X=Uint32Array,Z=Float32Array,J=v([][T]()),Q=h(J.next),tt=h(function*(){}().next),et=v(J),rt=DataView.prototype,nt=h(rt.getUint16),it=(h(rt.setUint16),TypeError,WeakSet.prototype),st=(h(it.add),h(it.has),WeakMap),ot=st.prototype,at=h(ot.get),lt=(h(ot.has),h(ot.set)),ct=new st,ut=D(null,{next:{value:function(){const t=at(ct,this);return Q(t)}},[T]:{value:function(){return this}}}),ht=new st,dt=D(et,{next:{value:function(){const t=at(ht,this);return tt(t)},writable:!0,configurable:!0}});for(const t of b(J))"next"!==t&&I(dt,t,y(J,t));const ft=new B(4),pt=new Z(ft),mt=new X(ft),gt=new Y(512),yt=new H(512);for(let t=0;t<256;++t){const e=t-127;e<-24?(gt[t]=0,gt[256|t]=32768,yt[t]=24,yt[256|t]=24):e<-14?(gt[t]=1024>>-e-14,gt[256|t]=1024>>-e-14|32768,yt[t]=-e-1,yt[256|t]=-e-1):e<=15?(gt[t]=e+15<<10,gt[256|t]=e+15<<10|32768,yt[t]=13,yt[256|t]=13):e<128?(gt[t]=31744,gt[256|t]=64512,yt[t]=24,yt[256|t]=24):(gt[t]=31744,gt[256|t]=64512,yt[t]=13,yt[256|t]=13)}const vt=new X(2048);for(let t=1;t<1024;++t){let e=t<<13,r=0;for(;!(8388608&e);)e<<=1,r-=8388608;e&=-8388609,r+=947912704,vt[t]=e|r}for(let t=1024;t<2048;++t)vt[t]=939524096+(t-1024<<13);const _t=new X(64);for(let t=1;t<31;++t)_t[t]=t<<23;_t[31]=1199570944,_t[32]=2147483648;for(let t=33;t<63;++t)_t[t]=2147483648+(t-32<<23);_t[63]=3347054592;const bt=new Y(64);for(let t=1;t<64;++t)32!==t&&(bt[t]=1024);function wt(t,e,...r){return function(t){const e=t>>10;return mt[0]=vt[bt[e]+(1023&t)]+_t[e],pt[0]}(nt(t,e,...function(t){if(t[T]===G&&J.next===Q)return t;const e=D(ut);return lt(ct,e,$(t)),e}(r)))}var xt=r(96682),Et=r.n(xt),St=r(91818),At=r.n(St);function Pt(t,e,r,n=1){return new(Object.getPrototypeOf(t).constructor)(e*r*n)}function Tt(t,e,r){return(1-r)*t+r*e}function Ct(t,e,r){let n=0;for(let i=e;i<r;++i)n+=t[i];return n}function Mt(t,e,r){switch(t){case 1:if(e<=8)return new Uint8Array(r);if(e<=16)return new Uint16Array(r);if(e<=32)return new Uint32Array(r);break;case 2:if(8===e)return new Int8Array(r);if(16===e)return new Int16Array(r);if(32===e)return new Int32Array(r);break;case 3:switch(e){case 16:case 32:return new Float32Array(r);case 64:return new Float64Array(r)}}throw Error("Unsupported data format/bitsPerSample")}const Ot=class{constructor(t,e,r,n,i,s){this.fileDirectory=t,this.geoKeys=e,this.dataView=r,this.littleEndian=n,this.tiles=i?{}:null,this.isTiled=!t.StripOffsets;const o=t.PlanarConfiguration;if(this.planarConfiguration=void 0===o?1:o,1!==this.planarConfiguration&&2!==this.planarConfiguration)throw new Error("Invalid planar configuration.");this.source=s}getFileDirectory(){return this.fileDirectory}getGeoKeys(){return this.geoKeys}getWidth(){return this.fileDirectory.ImageWidth}getHeight(){return this.fileDirectory.ImageLength}getSamplesPerPixel(){return void 0!==this.fileDirectory.SamplesPerPixel?this.fileDirectory.SamplesPerPixel:1}getTileWidth(){return this.isTiled?this.fileDirectory.TileWidth:this.getWidth()}getTileHeight(){return this.isTiled?this.fileDirectory.TileLength:void 0!==this.fileDirectory.RowsPerStrip?Math.min(this.fileDirectory.RowsPerStrip,this.getHeight()):this.getHeight()}getBlockWidth(){return this.getTileWidth()}getBlockHeight(t){return this.isTiled||(t+1)*this.getTileHeight()<=this.getHeight()?this.getTileHeight():this.getHeight()-t*this.getTileHeight()}getBytesPerPixel(){let t=0;for(let e=0;e<this.fileDirectory.BitsPerSample.length;++e)t+=this.getSampleByteSize(e);return t}getSampleByteSize(t){if(t>=this.fileDirectory.BitsPerSample.length)throw new RangeError(`Sample index ${t} is out of range.`);return Math.ceil(this.fileDirectory.BitsPerSample[t]/8)}getReaderForSample(t){const e=this.fileDirectory.SampleFormat?this.fileDirectory.SampleFormat[t]:1,r=this.fileDirectory.BitsPerSample[t];switch(e){case 1:if(r<=8)return DataView.prototype.getUint8;if(r<=16)return DataView.prototype.getUint16;if(r<=32)return DataView.prototype.getUint32;break;case 2:if(r<=8)return DataView.prototype.getInt8;if(r<=16)return DataView.prototype.getInt16;if(r<=32)return DataView.prototype.getInt32;break;case 3:switch(r){case 16:return function(t,e){return wt(this,t,e)};case 32:return DataView.prototype.getFloat32;case 64:return DataView.prototype.getFloat64}}throw Error("Unsupported data format/bitsPerSample")}getSampleFormat(t=0){return this.fileDirectory.SampleFormat?this.fileDirectory.SampleFormat[t]:1}getBitsPerSample(t=0){return this.fileDirectory.BitsPerSample[t]}getArrayForSample(t,e){return Mt(this.getSampleFormat(t),this.getBitsPerSample(t),e)}async getTileOrStrip(t,e,r,n,i){const s=Math.ceil(this.getWidth()/this.getTileWidth()),o=Math.ceil(this.getHeight()/this.getTileHeight());let a;const{tiles:l}=this;let c,u;1===this.planarConfiguration?a=e*s+t:2===this.planarConfiguration&&(a=r*s*o+e*s+t),this.isTiled?(c=this.fileDirectory.TileOffsets[a],u=this.fileDirectory.TileByteCounts[a]):(c=this.fileDirectory.StripOffsets[a],u=this.fileDirectory.StripByteCounts[a]);const h=(await this.source.fetch([{offset:c,length:u}],i))[0];let d;return null!==l&&l[a]?d=l[a]:(d=(async()=>{let t=await n.decode(this.fileDirectory,h);const r=this.getSampleFormat(),i=this.getBitsPerSample();return function(t,e){return(1!==t&&2!==t||!(e<=32)||e%8!=0)&&(3!==t||16!==e&&32!==e&&64!==e)}(r,i)&&(t=function(t,e,r,n,i,s,o){const a=new DataView(t),l=2===r?1:n,c=Mt(e,i,2===r?o*s:o*s*n),u=parseInt("1".repeat(i),2);if(1===e){let t;t=1===r?n*i:i;let e=s*t;7&e&&(e=e+7&-8);for(let t=0;t<o;++t){const r=t*e;for(let e=0;e<s;++e){const n=r+e*l*i;for(let r=0;r<l;++r){const o=n+r*i,h=(t*s+e)*l+r,d=Math.floor(o/8),f=o%8;if(f+i<=8)c[h]=a.getUint8(d)>>8-i-f&u;else if(f+i<=16)c[h]=a.getUint16(d)>>16-i-f&u;else if(f+i<=24){const t=a.getUint16(d)<<8|a.getUint8(d+2);c[h]=t>>24-i-f&u}else c[h]=a.getUint32(d)>>32-i-f&u}}}}return c.buffer}(t,r,this.planarConfiguration,this.getSamplesPerPixel(),i,this.getTileWidth(),this.getBlockHeight(e))),t})(),null!==l&&(l[a]=d)),{x:t,y:e,sample:r,data:await d}}async _readRaster(t,e,r,n,i,s,o,a,l){const c=this.getTileWidth(),u=this.getTileHeight(),h=this.getWidth(),d=this.getHeight(),f=Math.max(Math.floor(t[0]/c),0),p=Math.min(Math.ceil(t[2]/c),Math.ceil(h/c)),m=Math.max(Math.floor(t[1]/u),0),g=Math.min(Math.ceil(t[3]/u),Math.ceil(d/u)),y=t[2]-t[0];let v=this.getBytesPerPixel();const _=[],b=[];for(let t=0;t<e.length;++t)1===this.planarConfiguration?_.push(Ct(this.fileDirectory.BitsPerSample,0,e[t])/8):_.push(0),b.push(this.getReaderForSample(e[t]));const w=[],{littleEndian:x}=this;for(let s=m;s<g;++s)for(let o=f;o<p;++o){let a;1===this.planarConfiguration&&(a=this.getTileOrStrip(o,s,0,i,l));for(let f=0;f<e.length;++f){const p=f,m=e[f];2===this.planarConfiguration&&(v=this.getSampleByteSize(m),a=this.getTileOrStrip(o,s,m,i,l));const g=a.then((i=>{const s=i.data,o=new DataView(s),a=this.getBlockHeight(i.y),l=i.y*u,f=i.x*c,m=l+a,g=(i.x+1)*c,w=b[p],E=Math.min(a,a-(m-t[3]),d-l),S=Math.min(c,c-(g-t[2]),h-f);for(let i=Math.max(0,t[1]-l);i<E;++i)for(let s=Math.max(0,t[0]-f);s<S;++s){const a=(i*c+s)*v,u=w.call(o,a+_[p],x);let h;n?(h=(i+l-t[1])*y*e.length+(s+f-t[0])*e.length+p,r[h]=u):(h=(i+l-t[1])*y+s+f-t[0],r[p][h]=u)}}));w.push(g)}}if(await Promise.all(w),s&&t[2]-t[0]!==s||o&&t[3]-t[1]!==o){let i;return i=n?function(t,e,r,n,i,s,o="nearest"){switch(o.toLowerCase()){case"nearest":return function(t,e,r,n,i,s){const o=e/n,a=r/i,l=Pt(t,n,i,s);for(let c=0;c<i;++c){const i=Math.min(Math.round(a*c),r-1);for(let r=0;r<n;++r){const a=Math.min(Math.round(o*r),e-1);for(let o=0;o<s;++o){const u=t[i*e*s+a*s+o];l[c*n*s+r*s+o]=u}}}return l}(t,e,r,n,i,s);case"bilinear":case"linear":return function(t,e,r,n,i,s){const o=e/n,a=r/i,l=Pt(t,n,i,s);for(let c=0;c<i;++c){const i=a*c,u=Math.floor(i),h=Math.min(Math.ceil(i),r-1);for(let r=0;r<n;++r){const a=o*r,d=a%1,f=Math.floor(a),p=Math.min(Math.ceil(a),e-1);for(let o=0;o<s;++o){const a=t[u*e*s+f*s+o],m=t[u*e*s+p*s+o],g=t[h*e*s+f*s+o],y=t[h*e*s+p*s+o],v=Tt(Tt(a,m,d),Tt(g,y,d),i%1);l[c*n*s+r*s+o]=v}}}return l}(t,e,r,n,i,s);default:throw new Error(`Unsupported resampling method: '${o}'`)}}(r,t[2]-t[0],t[3]-t[1],s,o,e.length,a):function(t,e,r,n,i,s="nearest"){switch(s.toLowerCase()){case"nearest":return function(t,e,r,n,i){const s=e/n,o=r/i;return t.map((t=>{const a=Pt(t,n,i);for(let l=0;l<i;++l){const i=Math.min(Math.round(o*l),r-1);for(let r=0;r<n;++r){const o=Math.min(Math.round(s*r),e-1),c=t[i*e+o];a[l*n+r]=c}}return a}))}(t,e,r,n,i);case"bilinear":case"linear":return function(t,e,r,n,i){const s=e/n,o=r/i;return t.map((t=>{const a=Pt(t,n,i);for(let l=0;l<i;++l){const i=o*l,c=Math.floor(i),u=Math.min(Math.ceil(i),r-1);for(let r=0;r<n;++r){const o=s*r,h=o%1,d=Math.floor(o),f=Math.min(Math.ceil(o),e-1),p=t[c*e+d],m=t[c*e+f],g=t[u*e+d],y=t[u*e+f],v=Tt(Tt(p,m,h),Tt(g,y,h),i%1);a[l*n+r]=v}}return a}))}(t,e,r,n,i);default:throw new Error(`Unsupported resampling method: '${s}'`)}}(r,t[2]-t[0],t[3]-t[1],s,o,a),i.width=s,i.height=o,i}return r.width=s||t[2]-t[0],r.height=o||t[3]-t[1],r}async readRasters({window:t,samples:e=[],interleave:r,pool:n=null,width:i,height:s,resampleMethod:o,fillValue:a,signal:c}={}){const u=t||[0,0,this.getWidth(),this.getHeight()];if(u[0]>u[2]||u[1]>u[3])throw new Error("Invalid subsets");const h=(u[2]-u[0])*(u[3]-u[1]),d=this.getSamplesPerPixel();if(e&&e.length){for(let t=0;t<e.length;++t)if(e[t]>=d)return Promise.reject(new RangeError(`Invalid sample index '${e[t]}'.`))}else for(let t=0;t<d;++t)e.push(t);let f;if(r)f=Mt(this.fileDirectory.SampleFormat?Math.max.apply(null,this.fileDirectory.SampleFormat):1,Math.max.apply(null,this.fileDirectory.BitsPerSample),h*e.length),a&&f.fill(a);else{f=[];for(let t=0;t<e.length;++t){const r=this.getArrayForSample(e[t],h);Array.isArray(a)&&t<a.length?r.fill(a[t]):a&&!Array.isArray(a)&&r.fill(a),f.push(r)}}const p=n||await l(this.fileDirectory);return await this._readRaster(u,e,f,r,p,i,s,o,c)}async readRGB({window:t,interleave:e=!0,pool:r=null,width:n,height:i,resampleMethod:o,enableAlpha:a=!1,signal:l}={}){const c=t||[0,0,this.getWidth(),this.getHeight()];if(c[0]>c[2]||c[1]>c[3])throw new Error("Invalid subsets");const u=this.fileDirectory.PhotometricInterpretation;if(u===s.ub.RGB){let c=[0,1,2];if(this.fileDirectory.ExtraSamples!==s.AC.Unspecified&&a){c=[];for(let t=0;t<this.fileDirectory.BitsPerSample.length;t+=1)c.push(t)}return this.readRasters({window:t,interleave:e,samples:c,pool:r,width:n,height:i,resampleMethod:o,signal:l})}let h;switch(u){case s.ub.WhiteIsZero:case s.ub.BlackIsZero:case s.ub.Palette:h=[0];break;case s.ub.CMYK:h=[0,1,2,3];break;case s.ub.YCbCr:case s.ub.CIELab:h=[0,1,2];break;default:throw new Error("Invalid or unsupported photometric interpretation.")}const d={window:c,interleave:!0,samples:h,pool:r,width:n,height:i,resampleMethod:o,signal:l},{fileDirectory:f}=this,p=await this.readRasters(d),m=2**this.fileDirectory.BitsPerSample[0];let g;switch(u){case s.ub.WhiteIsZero:g=function(t,e){const{width:r,height:n}=t,i=new Uint8Array(r*n*3);let s;for(let r=0,n=0;r<t.length;++r,n+=3)s=256-t[r]/e*256,i[n]=s,i[n+1]=s,i[n+2]=s;return i}(p,m);break;case s.ub.BlackIsZero:g=function(t,e){const{width:r,height:n}=t,i=new Uint8Array(r*n*3);let s;for(let r=0,n=0;r<t.length;++r,n+=3)s=t[r]/e*256,i[n]=s,i[n+1]=s,i[n+2]=s;return i}(p,m);break;case s.ub.Palette:g=function(t,e){const{width:r,height:n}=t,i=new Uint8Array(r*n*3),s=e.length/3,o=e.length/3*2;for(let r=0,n=0;r<t.length;++r,n+=3){const a=t[r];i[n]=e[a]/65536*256,i[n+1]=e[a+s]/65536*256,i[n+2]=e[a+o]/65536*256}return i}(p,f.ColorMap);break;case s.ub.CMYK:g=function(t){const{width:e,height:r}=t,n=new Uint8Array(e*r*3);for(let e=0,r=0;e<t.length;e+=4,r+=3){const i=t[e],s=t[e+1],o=t[e+2],a=t[e+3];n[r]=(255-i)/256*255*((255-a)/256),n[r+1]=(255-s)/256*255*((255-a)/256),n[r+2]=(255-o)/256*255*((255-a)/256)}return n}(p);break;case s.ub.YCbCr:g=function(t){const{width:e,height:r}=t,n=new Uint8ClampedArray(e*r*3);for(let e=0,r=0;e<t.length;e+=3,r+=3){const i=t[e],s=t[e+1],o=t[e+2];n[r]=i+1.402*(o-128),n[r+1]=i-.34414*(s-128)-.71414*(o-128),n[r+2]=i+1.772*(s-128)}return n}(p);break;case s.ub.CIELab:g=function(t){const{width:e,height:r}=t,n=new Uint8Array(e*r*3);for(let e=0,r=0;e<t.length;e+=3,r+=3){let i,s,o,a=(t[e+0]+16)/116,l=(t[e+1]<<24>>24)/500+a,c=a-(t[e+2]<<24>>24)/200;l=.95047*(l*l*l>.008856?l*l*l:(l-16/116)/7.787),a=1*(a*a*a>.008856?a*a*a:(a-16/116)/7.787),c=1.08883*(c*c*c>.008856?c*c*c:(c-16/116)/7.787),i=3.2406*l+-1.5372*a+-.4986*c,s=-.9689*l+1.8758*a+.0415*c,o=.0557*l+-.204*a+1.057*c,i=i>.0031308?1.055*i**(1/2.4)-.055:12.92*i,s=s>.0031308?1.055*s**(1/2.4)-.055:12.92*s,o=o>.0031308?1.055*o**(1/2.4)-.055:12.92*o,n[r]=255*Math.max(0,Math.min(1,i)),n[r+1]=255*Math.max(0,Math.min(1,s)),n[r+2]=255*Math.max(0,Math.min(1,o))}return n}(p);break;default:throw new Error("Unsupported photometric interpretation.")}if(!e){const t=new Uint8Array(g.length/3),e=new Uint8Array(g.length/3),r=new Uint8Array(g.length/3);for(let n=0,i=0;n<g.length;n+=3,++i)t[i]=g[n],e[i]=g[n+1],r[i]=g[n+2];g=[t,e,r]}return g.width=p.width,g.height=p.height,g}getTiePoints(){if(!this.fileDirectory.ModelTiepoint)return[];const t=[];for(let e=0;e<this.fileDirectory.ModelTiepoint.length;e+=6)t.push({i:this.fileDirectory.ModelTiepoint[e],j:this.fileDirectory.ModelTiepoint[e+1],k:this.fileDirectory.ModelTiepoint[e+2],x:this.fileDirectory.ModelTiepoint[e+3],y:this.fileDirectory.ModelTiepoint[e+4],z:this.fileDirectory.ModelTiepoint[e+5]});return t}getGDALMetadata(t=null){const e={};if(!this.fileDirectory.GDAL_METADATA)return null;const r=this.fileDirectory.GDAL_METADATA;let n=At()(r,"Item");n=null===t?n.filter((t=>void 0===Et()(t,"sample"))):n.filter((e=>Number(Et()(e,"sample"))===t));for(let t=0;t<n.length;++t){const r=n[t];e[Et()(r,"name")]=r.inner}return e}getGDALNoData(){if(!this.fileDirectory.GDAL_NODATA)return null;const t=this.fileDirectory.GDAL_NODATA;return Number(t.substring(0,t.length-1))}getOrigin(){const t=this.fileDirectory.ModelTiepoint,e=this.fileDirectory.ModelTransformation;if(t&&6===t.length)return[t[3],t[4],t[5]];if(e)return[e[3],e[7],e[11]];throw new Error("The image does not have an affine transformation.")}getResolution(t=null){const e=this.fileDirectory.ModelPixelScale,r=this.fileDirectory.ModelTransformation;if(e)return[e[0],-e[1],e[2]];if(r)return 0===r[1]&&0===r[4]?[r[0],-r[5],r[10]]:[Math.sqrt(r[0]*r[0]+r[4]*r[4]),-Math.sqrt(r[1]*r[1]+r[5]*r[5]),r[10]];if(t){const[e,r,n]=t.getResolution();return[e*t.getWidth()/this.getWidth(),r*t.getHeight()/this.getHeight(),n*t.getWidth()/this.getWidth()]}throw new Error("The image does not have an affine transformation.")}pixelIsArea(){return 1===this.geoKeys.GTRasterTypeGeoKey}getBoundingBox(t=!1){const e=this.getHeight(),r=this.getWidth();if(this.fileDirectory.ModelTransformation&&!t){const[t,n,i,s,o,a,l,c]=this.fileDirectory.ModelTransformation,u=[[0,0],[0,e],[r,0],[r,e]].map((([e,r])=>[s+t*e+n*r,c+o*e+a*r])),h=u.map((t=>t[0])),d=u.map((t=>t[1]));return[Math.min(...h),Math.min(...d),Math.max(...h),Math.max(...d)]}{const t=this.getOrigin(),n=this.getResolution(),i=t[0],s=t[1],o=i+n[0]*r,a=s+n[1]*e;return[Math.min(i,o),Math.min(s,a),Math.max(i,o),Math.max(s,a)]}}};class Rt{constructor(t){this._dataView=new DataView(t)}get buffer(){return this._dataView.buffer}getUint64(t,e){const r=this.getUint32(t,e),n=this.getUint32(t+4,e);let i;if(e){if(i=r+2**32*n,!Number.isSafeInteger(i))throw new Error(`${i} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return i}if(i=2**32*r+n,!Number.isSafeInteger(i))throw new Error(`${i} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return i}getInt64(t,e){let r=0;const n=(128&this._dataView.getUint8(t+(e?7:0)))>0;let i=!0;for(let s=0;s<8;s++){let o=this._dataView.getUint8(t+(e?s:7-s));n&&(i?0!==o&&(o=255&~(o-1),i=!1):o=255&~o),r+=o*256**s}return n&&(r=-r),r}getUint8(t,e){return this._dataView.getUint8(t,e)}getInt8(t,e){return this._dataView.getInt8(t,e)}getUint16(t,e){return this._dataView.getUint16(t,e)}getInt16(t,e){return this._dataView.getInt16(t,e)}getUint32(t,e){return this._dataView.getUint32(t,e)}getInt32(t,e){return this._dataView.getInt32(t,e)}getFloat16(t,e){return wt(this._dataView,t,e)}getFloat32(t,e){return this._dataView.getFloat32(t,e)}getFloat64(t,e){return this._dataView.getFloat64(t,e)}}class Dt{constructor(t,e,r,n){this._dataView=new DataView(t),this._sliceOffset=e,this._littleEndian=r,this._bigTiff=n}get sliceOffset(){return this._sliceOffset}get sliceTop(){return this._sliceOffset+this.buffer.byteLength}get littleEndian(){return this._littleEndian}get bigTiff(){return this._bigTiff}get buffer(){return this._dataView.buffer}covers(t,e){return this.sliceOffset<=t&&this.sliceTop>=t+e}readUint8(t){return this._dataView.getUint8(t-this._sliceOffset,this._littleEndian)}readInt8(t){return this._dataView.getInt8(t-this._sliceOffset,this._littleEndian)}readUint16(t){return this._dataView.getUint16(t-this._sliceOffset,this._littleEndian)}readInt16(t){return this._dataView.getInt16(t-this._sliceOffset,this._littleEndian)}readUint32(t){return this._dataView.getUint32(t-this._sliceOffset,this._littleEndian)}readInt32(t){return this._dataView.getInt32(t-this._sliceOffset,this._littleEndian)}readFloat32(t){return this._dataView.getFloat32(t-this._sliceOffset,this._littleEndian)}readFloat64(t){return this._dataView.getFloat64(t-this._sliceOffset,this._littleEndian)}readUint64(t){const e=this.readUint32(t),r=this.readUint32(t+4);let n;if(this._littleEndian){if(n=e+2**32*r,!Number.isSafeInteger(n))throw new Error(`${n} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return n}if(n=2**32*e+r,!Number.isSafeInteger(n))throw new Error(`${n} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return n}readInt64(t){let e=0;const r=(128&this._dataView.getUint8(t+(this._littleEndian?7:0)))>0;let n=!0;for(let i=0;i<8;i++){let s=this._dataView.getUint8(t+(this._littleEndian?i:7-i));r&&(n?0!==s&&(s=255&~(s-1),n=!1):s=255&~s),e+=s*256**i}return r&&(e=-e),e}readOffset(t){return this._bigTiff?this.readUint64(t):this.readUint32(t)}}function It(t){if(void 0!==Object.fromEntries)return Object.fromEntries(t);const e={};for(const[r,n]of t)e[r.toLowerCase()]=n;return e}function kt(t){return It(t.split("\r\n").map((t=>{const e=t.split(":").map((t=>t.trim()));return e[0]=e[0].toLowerCase(),e})))}function Lt(t){let e,r,n;return t&&([,e,r,n]=t.match(/bytes (\d+)-(\d+)\/(\d+)/),e=parseInt(e,10),r=parseInt(r,10),n=parseInt(n,10)),{start:e,end:r,total:n}}class Ft{async fetch(t,e=void 0){return Promise.all(t.map((t=>this.fetchSlice(t,e))))}async fetchSlice(t){throw new Error(`fetching of slice ${t} not possible, not implemented`)}get fileSize(){return null}async close(){}}class jt extends Map{constructor(t={}){if(super(),!(t.maxSize&&t.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");if("number"==typeof t.maxAge&&0===t.maxAge)throw new TypeError("`maxAge` must be a number greater than 0");this.maxSize=t.maxSize,this.maxAge=t.maxAge||Number.POSITIVE_INFINITY,this.onEviction=t.onEviction,this.cache=new Map,this.oldCache=new Map,this._size=0}_emitEvictions(t){if("function"==typeof this.onEviction)for(const[e,r]of t)this.onEviction(e,r.value)}_deleteIfExpired(t,e){return"number"==typeof e.expiry&&e.expiry<=Date.now()&&("function"==typeof this.onEviction&&this.onEviction(t,e.value),this.delete(t))}_getOrDeleteIfExpired(t,e){if(!1===this._deleteIfExpired(t,e))return e.value}_getItemValue(t,e){return e.expiry?this._getOrDeleteIfExpired(t,e):e.value}_peek(t,e){const r=e.get(t);return this._getItemValue(t,r)}_set(t,e){this.cache.set(t,e),this._size++,this._size>=this.maxSize&&(this._size=0,this._emitEvictions(this.oldCache),this.oldCache=this.cache,this.cache=new Map)}_moveToRecent(t,e){this.oldCache.delete(t),this._set(t,e)}*_entriesAscending(){for(const t of this.oldCache){const[e,r]=t;this.cache.has(e)||!1===this._deleteIfExpired(e,r)&&(yield t)}for(const t of this.cache){const[e,r]=t;!1===this._deleteIfExpired(e,r)&&(yield t)}}get(t){if(this.cache.has(t)){const e=this.cache.get(t);return this._getItemValue(t,e)}if(this.oldCache.has(t)){const e=this.oldCache.get(t);if(!1===this._deleteIfExpired(t,e))return this._moveToRecent(t,e),e.value}}set(t,e,{maxAge:r=this.maxAge}={}){const n="number"==typeof r&&r!==Number.POSITIVE_INFINITY?Date.now()+r:void 0;return this.cache.has(t)?this.cache.set(t,{value:e,expiry:n}):this._set(t,{value:e,expiry:n}),this}has(t){return this.cache.has(t)?!this._deleteIfExpired(t,this.cache.get(t)):!!this.oldCache.has(t)&&!this._deleteIfExpired(t,this.oldCache.get(t))}peek(t){return this.cache.has(t)?this._peek(t,this.cache):this.oldCache.has(t)?this._peek(t,this.oldCache):void 0}delete(t){const e=this.cache.delete(t);return e&&this._size--,this.oldCache.delete(t)||e}clear(){this.cache.clear(),this.oldCache.clear(),this._size=0}resize(t){if(!(t&&t>0))throw new TypeError("`maxSize` must be a number greater than 0");const e=[...this._entriesAscending()],r=e.length-t;r<0?(this.cache=new Map(e),this.oldCache=new Map,this._size=e.length):(r>0&&this._emitEvictions(e.slice(0,r)),this.oldCache=new Map(e.slice(r)),this.cache=new Map,this._size=0),this.maxSize=t}*keys(){for(const[t]of this)yield t}*values(){for(const[,t]of this)yield t}*[Symbol.iterator](){for(const t of this.cache){const[e,r]=t;!1===this._deleteIfExpired(e,r)&&(yield[e,r.value])}for(const t of this.oldCache){const[e,r]=t;this.cache.has(e)||!1===this._deleteIfExpired(e,r)&&(yield[e,r.value])}}*entriesDescending(){let t=[...this.cache];for(let e=t.length-1;e>=0;--e){const r=t[e],[n,i]=r;!1===this._deleteIfExpired(n,i)&&(yield[n,i.value])}t=[...this.oldCache];for(let e=t.length-1;e>=0;--e){const r=t[e],[n,i]=r;this.cache.has(n)||!1===this._deleteIfExpired(n,i)&&(yield[n,i.value])}}*entriesAscending(){for(const[t,e]of this._entriesAscending())yield[t,e.value]}get size(){if(!this._size)return this.oldCache.size;let t=0;for(const e of this.oldCache.keys())this.cache.has(e)||t++;return Math.min(this._size+t,this.maxSize)}entries(){return this.entriesAscending()}forEach(t,e=this){for(const[r,n]of this.entriesAscending())t.call(e,n,r,this)}get[Symbol.toStringTag](){return JSON.stringify([...this.entriesAscending()])}}class Nt extends Error{constructor(t){super(t),Error.captureStackTrace&&Error.captureStackTrace(this,Nt),this.name="AbortError"}}class Gt extends Error{constructor(t,e){super(e),this.errors=t,this.message=e,this.name="AggregateError"}}const $t=Gt;class zt{constructor(t,e,r=null){this.offset=t,this.length=e,this.data=r}get top(){return this.offset+this.length}}class Ut{constructor(t,e,r){this.offset=t,this.length=e,this.blockIds=r}}class Bt extends Ft{constructor(t,{blockSize:e=65536,cacheSize:r=100}={}){super(),this.source=t,this.blockSize=e,this.blockCache=new jt({maxSize:r,onEviction:(t,e)=>{this.evictedBlocks.set(t,e)}}),this.evictedBlocks=new Map,this.blockRequests=new Map,this.blockIdsToFetch=new Set,this.abortedBlockIds=new Set}get fileSize(){return this.source.fileSize}async fetch(t,e){const r=[],n=[],i=[];this.evictedBlocks.clear();for(const{offset:e,length:s}of t){let t=e+s;const{fileSize:o}=this;null!==o&&(t=Math.min(t,o));for(let s=Math.floor(e/this.blockSize)*this.blockSize;s<t;s+=this.blockSize){const t=Math.floor(s/this.blockSize);this.blockCache.has(t)||this.blockRequests.has(t)||(this.blockIdsToFetch.add(t),n.push(t)),this.blockRequests.has(t)&&r.push(this.blockRequests.get(t)),i.push(t)}}await async function(){return new Promise((t=>setTimeout(t,undefined)))}(),this.fetchBlocks(e);const s=[];for(const t of n)this.blockRequests.has(t)&&s.push(this.blockRequests.get(t));await Promise.allSettled(r),await Promise.allSettled(s);const o=[],a=i.filter((t=>this.abortedBlockIds.has(t)||!this.blockCache.has(t)));if(a.forEach((t=>this.blockIdsToFetch.add(t))),a.length>0&&e&&!e.aborted){this.fetchBlocks(null);for(const t of a){const e=this.blockRequests.get(t);if(!e)throw new Error(`Block ${t} is not in the block requests`);o.push(e)}await Promise.allSettled(o)}if(e&&e.aborted)throw new Nt("Request was aborted");const l=i.map((t=>this.blockCache.get(t)||this.evictedBlocks.get(t))),c=l.filter((t=>!t));if(c.length)throw new $t(c,"Request failed");const u=new Map(function(t,e){const r=Array.isArray(t)?t:Array.from(t),n=Array.isArray(e)?e:Array.from(e);return r.map(((t,e)=>[t,n[e]]))}(i,l));return this.readSliceData(t,u)}fetchBlocks(t){if(this.blockIdsToFetch.size>0){const e=this.groupBlocks(this.blockIdsToFetch),r=this.source.fetch(e,t);for(let n=0;n<e.length;++n){const i=e[n];for(const e of i.blockIds)this.blockRequests.set(e,(async()=>{try{const t=(await r)[n],i=e*this.blockSize,s=i-t.offset,o=Math.min(s+this.blockSize,t.data.byteLength),a=t.data.slice(s,o),l=new zt(i,a.byteLength,a,e);this.blockCache.set(e,l),this.abortedBlockIds.delete(e)}catch(r){if("AbortError"!==r.name)throw r;r.signal=t,this.blockCache.delete(e),this.abortedBlockIds.add(e)}finally{this.blockRequests.delete(e)}})())}this.blockIdsToFetch.clear()}}groupBlocks(t){const e=Array.from(t).sort(((t,e)=>t-e));if(0===e.length)return[];let r=[],n=null;const i=[];for(const t of e)null===n||n+1===t?(r.push(t),n=t):(i.push(new Ut(r[0]*this.blockSize,r.length*this.blockSize,r)),r=[t],n=t);return i.push(new Ut(r[0]*this.blockSize,r.length*this.blockSize,r)),i}readSliceData(t,e){return t.map((t=>{let r=t.offset+t.length;null!==this.fileSize&&(r=Math.min(this.fileSize,r));const n=Math.floor(t.offset/this.blockSize),i=Math.floor(r/this.blockSize),s=new ArrayBuffer(t.length),o=new Uint8Array(s);for(let s=n;s<=i;++s){const n=e.get(s),i=n.offset-t.offset;let a,l=0,c=0;i<0?l=-i:i>0&&(c=i),a=n.top-r<0?n.length-l:r-n.offset-l;const u=new Uint8Array(n.data,l,a);o.set(u,c)}return s}))}}class Vt{get ok(){return this.status>=200&&this.status<=299}get status(){throw new Error("not implemented")}getHeader(t){throw new Error("not implemented")}async getData(){throw new Error("not implemented")}}class qt{constructor(t){this.url=t}async request({headers:t,signal:e}={}){throw new Error("request is not implemented")}}class Kt extends Vt{constructor(t){super(),this.response=t}get status(){return this.response.status}getHeader(t){return this.response.headers.get(t)}async getData(){return this.response.arrayBuffer?await this.response.arrayBuffer():(await this.response.buffer()).buffer}}class Wt extends qt{constructor(t,e){super(t),this.credentials=e}async request({headers:t,signal:e}={}){const r=await fetch(this.url,{headers:t,credentials:this.credentials,signal:e});return new Kt(r)}}class Ht extends Vt{constructor(t,e){super(),this.xhr=t,this.data=e}get status(){return this.xhr.status}getHeader(t){return this.xhr.getResponseHeader(t)}async getData(){return this.data}}class Yt extends qt{constructRequest(t,e){return new Promise(((r,n)=>{const i=new XMLHttpRequest;i.open("GET",this.url),i.responseType="arraybuffer";for(const[e,r]of Object.entries(t))i.setRequestHeader(e,r);i.onload=()=>{const t=i.response;r(new Ht(i,t))},i.onerror=n,i.onabort=()=>n(new Nt("Request aborted")),i.send(),e&&(e.aborted&&i.abort(),e.addEventListener("abort",(()=>i.abort())))}))}async request({headers:t,signal:e}={}){return await this.constructRequest(t,e)}}var Xt=r(80432),Zt=r.n(Xt),Jt=r(85787),Qt=r.n(Jt),te=r(93907),ee=r.n(te);class re extends Vt{constructor(t,e){super(),this.response=t,this.dataPromise=e}get status(){return this.response.statusCode}getHeader(t){return this.response.headers[t]}async getData(){return await this.dataPromise}}class ne extends qt{constructor(t){super(t),this.parsedUrl=ee().parse(this.url),this.httpApi="http:"===this.parsedUrl.protocol?Zt():Qt()}constructRequest(t,e){return new Promise(((r,n)=>{const i=this.httpApi.get({...this.parsedUrl,headers:t},(t=>{const e=new Promise((e=>{const r=[];t.on("data",(t=>{r.push(t)})),t.on("end",(()=>{const t=Buffer.concat(r).buffer;e(t)})),t.on("error",n)}));r(new re(t,e))}));i.on("error",n),e&&(e.aborted&&i.destroy(new Nt("Request aborted")),e.addEventListener("abort",(()=>i.destroy(new Nt("Request aborted")))))}))}async request({headers:t,signal:e}={}){return await this.constructRequest(t,e)}}class ie extends Ft{constructor(t,e,r,n){super(),this.client=t,this.headers=e,this.maxRanges=r,this.allowFullFile=n,this._fileSize=null}async fetch(t,e){return this.maxRanges>=t.length?this.fetchSlices(t,e):(this.maxRanges>0&&t.length,Promise.all(t.map((t=>this.fetchSlice(t,e)))))}async fetchSlices(t,e){const r=await this.client.request({headers:{...this.headers,Range:`bytes=${t.map((({offset:t,length:e})=>`${t}-${t+e}`)).join(",")}`},signal:e});if(r.ok){if(206===r.status){const{type:n,params:i}=function(t){const[e,...r]=t.split(";").map((t=>t.trim()));return{type:e,params:It(r.map((t=>t.split("="))))}}(r.getHeader("content-type"));if("multipart/byteranges"===n){const t=function(t,e){let r=null;const n=new TextDecoder("ascii"),i=[],s=`--${e}`,o=`${s}--`;for(let e=0;e<10;++e)n.decode(new Uint8Array(t,e,s.length))===s&&(r=e);if(null===r)throw new Error("Could not find initial boundary");for(;r<t.byteLength;){const e=n.decode(new Uint8Array(t,r,Math.min(s.length+1024,t.byteLength-r)));if(0===e.length||e.startsWith(o))break;if(!e.startsWith(s))throw new Error("Part does not start with boundary");const a=e.substr(s.length+2);if(0===a.length)break;const l=a.indexOf("\r\n\r\n"),c=kt(a.substr(0,l)),{start:u,end:h,total:d}=Lt(c["content-range"]),f=r+s.length+l+4,p=parseInt(h,10)+1-parseInt(u,10);i.push({headers:c,data:t.slice(f,f+p),offset:u,length:p,fileSize:d}),r=f+p+4}return i}(await r.getData(),i.boundary);return this._fileSize=t[0].fileSize||null,t}const s=await r.getData(),{start:o,end:a,total:l}=Lt(r.getHeader("content-range"));this._fileSize=l||null;const c=[{data:s,offset:o,length:a-o}];if(t.length>1){const r=await Promise.all(t.slice(1).map((t=>this.fetchSlice(t,e))));return c.concat(r)}return c}{if(!this.allowFullFile)throw new Error("Server responded with full file");const t=await r.getData();return this._fileSize=t.byteLength,[{data:t,offset:0,length:t.byteLength}]}}throw new Error("Error fetching data.")}async fetchSlice(t,e){const{offset:r,length:n}=t,i=await this.client.request({headers:{...this.headers,Range:`bytes=${r}-${r+n}`},signal:e});if(i.ok){if(206===i.status){const t=await i.getData(),{total:e}=Lt(i.getHeader("content-range"));return this._fileSize=e||null,{data:t,offset:r,length:n}}{if(!this.allowFullFile)throw new Error("Server responded with full file");const t=await i.getData();return this._fileSize=t.byteLength,{data:t,offset:0,length:t.byteLength}}}throw new Error("Error fetching data.")}get fileSize(){return this._fileSize}}function se(t,{blockSize:e,cacheSize:r}){return null===e?t:new Bt(t,{blockSize:e,cacheSize:r})}function oe(t,{forceXHR:e=!1,...r}={}){return"function"!=typeof fetch||e?"undefined"!=typeof XMLHttpRequest?function(t,{headers:e={},maxRanges:r=0,allowFullFile:n=!1,...i}={}){const s=new Yt(t);return se(new ie(s,e,r,n),i)}(t,r):function(t,{headers:e={},maxRanges:r=0,allowFullFile:n=!1,...i}={}){const s=new ne(t);return se(new ie(s,e,r,n),i)}(t,r):function(t,{headers:e={},credentials:r,maxRanges:n=0,allowFullFile:i=!1,...s}={}){const o=new Wt(t,r);return se(new ie(o,e,n,i),s)}(t,r)}class ae extends Ft{constructor(t){super(),this.file=t}async fetchSlice(t,e){return new Promise(((r,n)=>{const i=this.file.slice(t.offset,t.offset+t.length),s=new FileReader;s.onload=t=>r(t.target.result),s.onerror=n,s.onabort=n,s.readAsArrayBuffer(i),e&&e.addEventListener("abort",(()=>s.abort()))}))}}function le(t){switch(t){case s.s$.BYTE:case s.s$.ASCII:case s.s$.SBYTE:case s.s$.UNDEFINED:return 1;case s.s$.SHORT:case s.s$.SSHORT:return 2;case s.s$.LONG:case s.s$.SLONG:case s.s$.FLOAT:case s.s$.IFD:return 4;case s.s$.RATIONAL:case s.s$.SRATIONAL:case s.s$.DOUBLE:case s.s$.LONG8:case s.s$.SLONG8:case s.s$.IFD8:return 8;default:throw new RangeError(`Invalid field type: ${t}`)}}function ce(t,e,r,n){let i=null,o=null;const a=le(e);switch(e){case s.s$.BYTE:case s.s$.ASCII:case s.s$.UNDEFINED:i=new Uint8Array(r),o=t.readUint8;break;case s.s$.SBYTE:i=new Int8Array(r),o=t.readInt8;break;case s.s$.SHORT:i=new Uint16Array(r),o=t.readUint16;break;case s.s$.SSHORT:i=new Int16Array(r),o=t.readInt16;break;case s.s$.LONG:case s.s$.IFD:i=new Uint32Array(r),o=t.readUint32;break;case s.s$.SLONG:i=new Int32Array(r),o=t.readInt32;break;case s.s$.LONG8:case s.s$.IFD8:i=new Array(r),o=t.readUint64;break;case s.s$.SLONG8:i=new Array(r),o=t.readInt64;break;case s.s$.RATIONAL:i=new Uint32Array(2*r),o=t.readUint32;break;case s.s$.SRATIONAL:i=new Int32Array(2*r),o=t.readInt32;break;case s.s$.FLOAT:i=new Float32Array(r),o=t.readFloat32;break;case s.s$.DOUBLE:i=new Float64Array(r),o=t.readFloat64;break;default:throw new RangeError(`Invalid field type: ${e}`)}if(e!==s.s$.RATIONAL&&e!==s.s$.SRATIONAL)for(let e=0;e<r;++e)i[e]=o.call(t,n+e*a);else for(let e=0;e<r;e+=2)i[e]=o.call(t,n+e*a),i[e+1]=o.call(t,n+(e*a+4));return e===s.s$.ASCII?new TextDecoder("utf-8").decode(i):i}class ue{constructor(t,e,r){this.fileDirectory=t,this.geoKeyDirectory=e,this.nextIFDByteOffset=r}}class he extends Error{constructor(t){super(`No image at index ${t}`),this.index=t}}class de{async readRasters(t={}){const{window:e,width:r,height:n}=t;let{resX:i,resY:s,bbox:o}=t;const a=await this.getImage();let l=a;const c=await this.getImageCount(),u=a.getBoundingBox();if(e&&o)throw new Error('Both "bbox" and "window" passed.');if(r||n){if(e){const[t,r]=a.getOrigin(),[n,i]=a.getResolution();o=[t+e[0]*n,r+e[1]*i,t+e[2]*n,r+e[3]*i]}const t=o||u;if(r){if(i)throw new Error("Both width and resX passed");i=(t[2]-t[0])/r}if(n){if(s)throw new Error("Both width and resY passed");s=(t[3]-t[1])/n}}if(i||s){const t=[];for(let e=0;e<c;++e){const r=await this.getImage(e),{SubfileType:n,NewSubfileType:i}=r.fileDirectory;(0===e||2===n||1&i)&&t.push(r)}t.sort(((t,e)=>t.getWidth()-e.getWidth()));for(let e=0;e<t.length;++e){const r=t[e],n=(u[2]-u[0])/r.getWidth(),o=(u[3]-u[1])/r.getHeight();if(l=r,i&&i>n||s&&s>o)break}}let h=e;if(o){const[t,e]=a.getOrigin(),[r,n]=l.getResolution(a);h=[Math.round((o[0]-t)/r),Math.round((o[1]-e)/n),Math.round((o[2]-t)/r),Math.round((o[3]-e)/n)],h=[Math.min(h[0],h[2]),Math.min(h[1],h[3]),Math.max(h[0],h[2]),Math.max(h[1],h[3])]}return l.readRasters({...t,window:h})}}class fe extends de{constructor(t,e,r,n,i={}){super(),this.source=t,this.littleEndian=e,this.bigTiff=r,this.firstIFDOffset=n,this.cache=i.cache||!1,this.ifdRequests=[],this.ghostValues=null}async getSlice(t,e){const r=this.bigTiff?4048:1024;return new Dt((await this.source.fetch([{offset:t,length:void 0!==e?e:r}]))[0],t,this.littleEndian,this.bigTiff)}async parseFileDirectoryAt(t){const e=this.bigTiff?20:12,r=this.bigTiff?8:2;let n=await this.getSlice(t);const i=this.bigTiff?n.readUint64(t):n.readUint16(t),o=i*e+(this.bigTiff?16:6);n.covers(t,o)||(n=await this.getSlice(t,o));const a={};let l=t+(this.bigTiff?8:2);for(let t=0;t<i;l+=e,++t){const t=n.readUint16(l),e=n.readUint16(l+2),r=this.bigTiff?n.readUint64(l+4):n.readUint32(l+4);let i,o;const c=le(e),u=l+(this.bigTiff?12:8);if(c*r<=(this.bigTiff?8:4))i=ce(n,e,r,u);else{const t=n.readOffset(u),s=le(e)*r;i=n.covers(t,s)?ce(n,e,r,t):ce(await this.getSlice(t,s),e,r,t)}o=1===r&&-1===s.NZ.indexOf(t)&&e!==s.s$.RATIONAL&&e!==s.s$.SRATIONAL?i[0]:i,a[s.$[t]]=o}const c=function(t){const e=t.GeoKeyDirectory;if(!e)return null;const r={};for(let n=4;n<=4*e[3];n+=4){const i=s.Hm[e[n]],o=e[n+1]?s.$[e[n+1]]:null,a=e[n+2],l=e[n+3];let c=null;if(o){if(c=t[o],null==c)throw new Error(`Could not get value of geoKey '${i}'.`);"string"==typeof c?c=c.substring(l,l+a-1):c.subarray&&(c=c.subarray(l,l+a),1===a&&(c=c[0]))}else c=l;r[i]=c}return r}(a),u=n.readOffset(t+r+e*i);return new ue(a,c,u)}async requestIFD(t){if(this.ifdRequests[t])return this.ifdRequests[t];if(0===t)return this.ifdRequests[t]=this.parseFileDirectoryAt(this.firstIFDOffset),this.ifdRequests[t];if(!this.ifdRequests[t-1])try{this.ifdRequests[t-1]=this.requestIFD(t-1)}catch(e){if(e instanceof he)throw new he(t);throw e}return this.ifdRequests[t]=(async()=>{const e=await this.ifdRequests[t-1];if(0===e.nextIFDByteOffset)throw new he(t);return this.parseFileDirectoryAt(e.nextIFDByteOffset)})(),this.ifdRequests[t]}async getImage(t=0){const e=await this.requestIFD(t);return new Ot(e.fileDirectory,e.geoKeyDirectory,this.dataView,this.littleEndian,this.cache,this.source)}async getImageCount(){let t=0,e=!0;for(;e;)try{await this.requestIFD(t),++t}catch(t){if(!(t instanceof he))throw t;e=!1}return t}async getGhostValues(){const t=this.bigTiff?16:8;if(this.ghostValues)return this.ghostValues;let e=await this.getSlice(t,130);if("GDAL_STRUCTURAL_METADATA_SIZE="===ce(e,s.s$.ASCII,30,t)){const r=ce(e,s.s$.ASCII,130,t).split("\n")[0],n=Number(r.split("=")[1].split(" ")[0])+r.length;n>130&&(e=await this.getSlice(t,n));const i=ce(e,s.s$.ASCII,n,t);this.ghostValues={},i.split("\n").filter((t=>t.length>0)).map((t=>t.split("="))).forEach((([t,e])=>{this.ghostValues[t]=e}))}return this.ghostValues}static async fromSource(t,e,r){const n=(await t.fetch([{offset:0,length:1024}],r))[0],i=new Rt(n),s=i.getUint16(0,0);let o;if(18761===s)o=!0;else{if(19789!==s)throw new TypeError("Invalid byte order value.");o=!1}const a=i.getUint16(2,o);let l;if(42===a)l=!1;else{if(43!==a)throw new TypeError("Invalid magic number.");if(l=!0,8!==i.getUint16(4,o))throw new Error("Unsupported offset byte-size.")}const c=l?i.getUint64(8,o):i.getUint32(4,o);return new fe(t,o,l,c,e)}close(){return"function"==typeof this.source.close&&this.source.close()}}class pe extends de{constructor(t,e){super(),this.mainFile=t,this.overviewFiles=e,this.imageFiles=[t].concat(e),this.fileDirectoriesPerFile=null,this.fileDirectoriesPerFileParsing=null,this.imageCount=null}async parseFileDirectoriesPerFile(){const t=[this.mainFile.parseFileDirectoryAt(this.mainFile.firstIFDOffset)].concat(this.overviewFiles.map((t=>t.parseFileDirectoryAt(t.firstIFDOffset))));return this.fileDirectoriesPerFile=await Promise.all(t),this.fileDirectoriesPerFile}async getImage(t=0){await this.getImageCount(),await this.parseFileDirectoriesPerFile();let e=0,r=0;for(let n=0;n<this.imageFiles.length;n++){const i=this.imageFiles[n];for(let s=0;s<this.imageCounts[n];s++){if(t===e){const t=await i.requestIFD(r);return new Ot(t.fileDirectory,t.geoKeyDirectory,i.dataView,i.littleEndian,i.cache,i.source)}e++,r++}r=0}throw new RangeError("Invalid image index")}async getImageCount(){if(null!==this.imageCount)return this.imageCount;const t=[this.mainFile.getImageCount()].concat(this.overviewFiles.map((t=>t.getImageCount())));return this.imageCounts=await Promise.all(t),this.imageCount=this.imageCounts.reduce(((t,e)=>t+e),0),this.imageCount}}var me=r(12940),ge=r(72475),ye=r(44509),ve=r(96372),_e=r(82410);function be(t,e){if(!t)return!1;if(!0===t)return!0;if(3!==e.getSamplesPerPixel())return!1;const r=e.fileDirectory.PhotometricInterpretation,n=s.ub;return r===n.CMYK||r===n.YCbCr||r===n.CIELab||r===n.ICCLab}const we="STATISTICS_MAXIMUM",xe="STATISTICS_MINIMUM";let Ee;function Se(){return Ee||(Ee=new u),Ee}function Ae(t){try{return t.getBoundingBox()}catch(e){return[0,0,t.getWidth(),t.getHeight()]}}function Pe(t){try{return t.getOrigin().slice(0,2)}catch(e){return[0,t.getHeight()]}}function Te(t,e){try{return t.getResolution(e)}catch(r){return[e.getWidth()/t.getWidth(),e.getHeight()/t.getHeight()]}}function Ce(t){const e=t.geoKeys;if(!e)return null;if(e.ProjectedCSTypeGeoKey&&32767!==e.ProjectedCSTypeGeoKey){const t="EPSG:"+e.ProjectedCSTypeGeoKey;let r=(0,me.Jt)(t);if(!r){const n=(0,_e.q)(e.ProjLinearUnitsGeoKey);n&&(r=new me.MF({code:t,units:n}))}return r}if(e.GeographicTypeGeoKey&&32767!==e.GeographicTypeGeoKey){const t="EPSG:"+e.GeographicTypeGeoKey;let r=(0,me.Jt)(t);if(!r){const n=(0,_e.q)(e.GeogAngularUnitsGeoKey);n&&(r=new me.MF({code:t,units:n}))}return r}return null}function Me(t){return t.getImageCount().then((function(e){const r=new Array(e);for(let n=0;n<e;++n)r[n]=t.getImage(n);return Promise.all(r)}))}function Oe(t,e){let r;return r=t.blob?async function(t,e){return fe.fromSource(new ae(t),e)}(t.blob):t.overviews?async function(t,e=[],r={},n){const i=await fe.fromSource(oe(t,r),n),s=await Promise.all(e.map((t=>fe.fromSource(oe(t,r)))));return new pe(i,s)}(t.url,t.overviews,e):async function(t,e={},r){return fe.fromSource(oe(t,e),r)}(t.url,e),r.then(Me)}function Re(t,e,r,n,i){if(Array.isArray(t)){const s=t.length;if(!Array.isArray(e)||s!=e.length){const t=new Error(n);throw i(t),t}for(let o=0;o<s;++o)Re(t[o],e[o],r,n,i)}else if(Math.abs(t-e)>r*t)throw new Error(n)}function De(t){return t instanceof Int8Array?127:t instanceof Uint8Array||t instanceof Uint8ClampedArray?255:t instanceof Int16Array?32767:t instanceof Uint16Array?65535:t instanceof Int32Array?2147483647:t instanceof Uint32Array?4294967295:t instanceof Float32Array?34e37:255}class Ie extends n.A{constructor(t){super({state:"loading",tileGrid:null,projection:t.projection||null,transition:t.transition,interpolate:!1!==t.interpolate,wrapX:t.wrapX}),this.sourceInfo_=t.sources;const e=this.sourceInfo_.length;this.sourceOptions_=t.sourceOptions,this.sourceImagery_=new Array(e),this.sourceMasks_=new Array(e),this.resolutionFactors_=new Array(e),this.samplesPerPixel_,this.nodataValues_,this.metadata_,this.normalize_=!1!==t.normalize,this.addAlpha_=!1,this.error_=null,this.convertToRGB_=t.convertToRGB||!1,this.setKey(this.sourceInfo_.map((t=>t.url)).join(","));const r=this,n=new Array(e);for(let t=0;t<e;++t)n[t]=Oe(this.sourceInfo_[t],this.sourceOptions_);Promise.all(n).then((function(t){r.configure_(t)})).catch((function(t){(0,ve.z3)(t),r.error_=t,r.setState("error")}))}getError(){return this.error_}determineProjection(t){const e=t[0];for(let t=e.length-1;t>=0;--t){const r=Ce(e[t]);if(r){this.projection=r;break}}}configure_(t){let e,r,n,s,o;const a=new Array(t.length),l=new Array(t.length),c=new Array(t.length);let u=0;const h=t.length;for(let i=0;i<h;++i){const h=[],d=[];t[i].forEach((t=>{4&~(t.fileDirectory.NewSubfileType||0)?h.push(t):d.push(t)}));const f=h.length;if(d.length>0&&d.length!==f)throw new Error(`Expected one mask per image found ${d.length} masks and ${f} images`);let p,m;const g=new Array(f),y=new Array(f),v=new Array(f);l[i]=new Array(f),c[i]=new Array(f);for(let t=0;t<f;++t){const e=h[t],r=e.getGDALNoData();c[i][t]=e.getGDALMetadata(0),l[i][t]=r;const n=this.sourceInfo_[i].bands;a[i]=n?n.length:e.getSamplesPerPixel();const s=f-(t+1);p||(p=Ae(e)),m||(m=Pe(e));const o=Te(e,h[0]);v[s]=o[0];const u=[e.getTileWidth(),e.getTileHeight()];u[0]!==u[1]&&u[1]<256&&(u[0]=256,u[1]=256),g[s]=u;const d=o[0]/Math.abs(o[1]);y[s]=[u[0],u[1]/d]}if(e?(0,ye._N)(e,p,e):e=p,r?Re(r,m,0,`Origin mismatch for source ${i}, got [${m}] but expected [${r}]`,this.viewRejector):r=m,o){o.length-u>v.length&&(u=o.length-v.length);const t=o[o.length-1]/v[v.length-1];this.resolutionFactors_[i]=t;const e=v.map((e=>e*t)),r=`Resolution mismatch for source ${i}, got [${e}] but expected [${o}]`;Re(o.slice(u,o.length),e,.02,r,this.viewRejector)}else o=v,this.resolutionFactors_[i]=1;n?Re(n.slice(u,n.length),y,.01,`Tile size mismatch for source ${i}`,this.viewRejector):n=y,s?Re(s.slice(u,s.length),g,0,`Tile size mismatch for source ${i}`,this.viewRejector):s=g,this.sourceImagery_[i]=h.reverse(),this.sourceMasks_[i]=d.reverse()}for(let t=0,e=this.sourceImagery_.length;t<e;++t){const e=this.sourceImagery_[t];for(;e.length<o.length;)e.unshift(void 0)}this.getProjection()||this.determineProjection(t),this.samplesPerPixel_=a,this.nodataValues_=l,this.metadata_=c;t:for(let t=0;t<h;++t){if(void 0!==this.sourceInfo_[t].nodata){this.addAlpha_=!0;break}if(this.sourceMasks_[t].length){this.addAlpha_=!0;break}const e=l[t],r=this.sourceInfo_[t].bands;if(r){for(let t=0;t<r.length;++t)if(null!==e[r[t]-1]){this.addAlpha_=!0;break t}}else for(let t=0;t<e.length;++t)if(null!==e[t]){this.addAlpha_=!0;break t}}let d=this.addAlpha_?1:0;for(let t=0;t<h;++t)d+=a[t];this.bandCount=d;const f=new i.A({extent:e,minZoom:u,origin:r,resolutions:o,tileSizes:n});this.tileGrid=f,this.setTileSizes(s),this.setLoader(this.loadTile_.bind(this)),this.setState("ready"),2===o.length?o=[o[0],o[1],o[1]/2]:1===o.length&&(o=[2*o[0],o[0],o[0]/2]),this.viewResolver({showFullExtent:!0,projection:this.projection,resolutions:o,center:(0,me.te)((0,ye.q1)(e),this.projection),extent:(0,me.JR)(e,this.projection),zoom:1})}loadTile_(t,e,r,n){const i=this.getTileSize(t),s=this.sourceImagery_.length,o=new Array(2*s),a=this.nodataValues_,l=this.sourceInfo_,c=Se();for(let u=0;u<s;++u){const h=l[u],d=this.resolutionFactors_[u],f=[Math.round(e*(i[0]*d)),Math.round(r*(i[1]*d)),Math.round((e+1)*(i[0]*d)),Math.round((r+1)*(i[1]*d))],p=this.sourceImagery_[u][t];let m,g;h.bands&&(m=h.bands.map((function(t){return t-1}))),g="nodata"in h&&null!==h.nodata?h.nodata:m?m.map((function(t){return a[u][t]})):a[u];const y={window:f,width:i[0],height:i[1],samples:m,fillValue:g,pool:c,interleave:!1,signal:n.signal};be(this.convertToRGB_,p)?o[u]=p.readRGB(y):o[u]=p.readRasters(y);const v=s+u,_=this.sourceMasks_[u][t];o[v]=_?_.readRasters({window:f,width:i[0],height:i[1],samples:[0],pool:c,interleave:!1}):Promise.resolve(null)}return Promise.all(o).then(this.composeTile_.bind(this,i)).catch((function(t){throw(0,ve.z3)(t),t}))}composeTile_(t,e){const r=this.metadata_,n=this.sourceInfo_,i=this.sourceImagery_.length,s=this.bandCount,o=this.samplesPerPixel_,a=this.nodataValues_,l=this.normalize_,c=this.addAlpha_,u=t[0]*t[1],h=u*s;let d;d=l?new Uint8Array(h):new Float32Array(h);let f=0;for(let t=0;t<u;++t){let s=c;for(let u=0;u<i;++u){const h=n[u];let m,g,y=h.min,v=h.max;if(l){const t=r[u][0];void 0===y&&(y=t&&xe in t?parseFloat(t[xe]):(p=e[u][0])instanceof Int8Array?-128:p instanceof Int16Array?-32768:p instanceof Int32Array?-2147483648:p instanceof Float32Array?12e-39:0),void 0===v&&(v=t&&we in t?parseFloat(t[we]):De(e[u][0])),m=255/(v-y),g=-y*m}for(let r=0;r<o[u];++r){const n=e[u][r][t];let i;if(i=l?(0,ge.qE)(m*n+g,0,255):n,c){let t=h.nodata;if(void 0===t){let e;e=h.bands?h.bands[r]-1:r,t=a[u][e]}const e=isNaN(t);(!e&&n!==t||e&&!isNaN(n))&&(s=!1,d[f]=i)}else d[f]=i;f++}if(!s){const r=e[i+u];r&&!r[0][t]&&(s=!0)}}c&&(s||(d[f]=255),f++)}var p;return d}}Ie.prototype.getView;const ke=Ie},39895:(t,e,r)=>{"use strict";r.d(e,{A:()=>E});var n=r(24187),i=r(37283),s=r(39915),o=r(77032),a=r(35035),l=r(14695),c=r(2175);function u(t){return Array.isArray(t)?Math.min(...t):t}var h=r(44509),d=r(94456);class f extends o.Ay{constructor(t,e,r,n,i,o,u){let d=t.getExtent();d&&t.canWrapX()&&(d=d.slice(),d[0]=-1/0,d[2]=1/0);let f=e.getExtent();f&&e.canWrapX()&&(f=f.slice(),f[0]=-1/0,f[2]=1/0);const p=f?(0,h._N)(r,f):r,m=(0,h.q1)(p),g=(0,c.KQ)(t,e,m,n),y=a.l,v=new l.A(t,e,p,d,g*y,n),_=v.calculateSourceExtent(),b=(0,h.Im)(_)?null:o(_,g,i),w=b?s.A.IDLE:s.A.EMPTY,x=b?b.getPixelRatio():1;super(r,n,x,w),this.targetProj_=e,this.maxSourceExtent_=d,this.triangulation_=v,this.targetResolution_=n,this.targetExtent_=r,this.sourceImage_=b,this.sourcePixelRatio_=x,this.interpolate_=u,this.canvas_=null,this.sourceListenerKey_=null}disposeInternal(){this.state==s.A.LOADING&&this.unlistenSource_(),super.disposeInternal()}getImage(){return this.canvas_}getProjection(){return this.targetProj_}reproject_(){const t=this.sourceImage_.getState();if(t==s.A.LOADED){const t=(0,h.RG)(this.targetExtent_)/this.targetResolution_,e=(0,h.Oq)(this.targetExtent_)/this.targetResolution_;this.canvas_=(0,c.XX)(t,e,this.sourcePixelRatio_,u(this.sourceImage_.getResolution()),this.maxSourceExtent_,this.targetResolution_,this.targetExtent_,this.triangulation_,[{extent:this.sourceImage_.getExtent(),image:this.sourceImage_.getImage()}],0,void 0,this.interpolate_,!0)}this.state=t,this.changed()}load(){if(this.state==s.A.IDLE){this.state=s.A.LOADING,this.changed();const t=this.sourceImage_.getState();t==s.A.LOADED||t==s.A.ERROR?this.reproject_():(this.sourceListenerKey_=(0,d.KT)(this.sourceImage_,n.A.CHANGE,(t=>{const e=this.sourceImage_.getState();e!=s.A.LOADED&&e!=s.A.ERROR||(this.unlistenSource_(),this.reproject_())})),this.sourceImage_.load())}}unlistenSource_(){(0,d.JH)(this.sourceListenerKey_),this.sourceListenerKey_=null}}const p=f;var m=r(31274),g=r(72475),y=r(12940),v=r(30444);class _ extends i.Ay{constructor(t,e){super(t),this.image=e}}class b extends m.A{constructor(t){super({attributions:t.attributions,projection:t.projection,state:t.state,interpolate:void 0===t.interpolate||t.interpolate}),this.on,this.once,this.un,this.loader=t.loader||null,this.resolutions_=void 0!==t.resolutions?t.resolutions:null,this.reprojectedImage_=null,this.reprojectedRevision_=0,this.image=null,this.wantedExtent_,this.wantedResolution_,this.static_=!!t.loader&&0===t.loader.length,this.wantedProjection_=null}getResolutions(){return this.resolutions_}setResolutions(t){this.resolutions_=t}findNearestResolution(t){const e=this.getResolutions();return e&&(t=e[(0,v.FT)(e,t,0)]),t}getImage(t,e,r,n){const i=this.getProjection();if(!i||!n||(0,y.tI)(i,n))return i&&(n=i),this.getImageInternal(t,e,r,n);if(this.reprojectedImage_){if(this.reprojectedRevision_==this.getRevision()&&(0,y.tI)(this.reprojectedImage_.getProjection(),n)&&this.reprojectedImage_.getResolution()==e&&(0,h.aI)(this.reprojectedImage_.getExtent(),t))return this.reprojectedImage_;this.reprojectedImage_.dispose(),this.reprojectedImage_=null}return this.reprojectedImage_=new p(i,n,t,e,r,((t,e,r)=>this.getImageInternal(t,e,r,i)),this.getInterpolate()),this.reprojectedRevision_=this.getRevision(),this.reprojectedImage_}getImageInternal(t,e,r,i){if(this.loader){const s=function(t,e,r){const n=e/r,i=(0,h.q1)(t),s=(0,g.mk)((0,h.RG)(t)/n,4),o=(0,g.mk)((0,h.Oq)(t)/n,4),a=s+2*(0,g.mk)(0*s/2,4),l=o+2*(0,g.mk)(0*o/2,4);return(0,h.Bg)(i,n,0,[a,l])}(t,e,r),a=this.findNearestResolution(e);if(this.image&&(this.static_||this.wantedProjection_===i&&(this.wantedExtent_&&(0,h.ms)(this.wantedExtent_,s)||(0,h.ms)(this.image.getExtent(),s))&&(this.wantedResolution_&&u(this.wantedResolution_)===a||u(this.image.getResolution())===a)))return this.image;this.wantedProjection_=i,this.wantedExtent_=s,this.wantedResolution_=a,this.image=new o.Ay(s,a,r,this.loader),this.image.addEventListener(n.A.CHANGE,this.handleImageChange.bind(this))}return this.image}handleImageChange(t){const e=t.target;let r;switch(e.getState()){case s.A.LOADING:this.loading=!0,r="imageloadstart";break;case s.A.LOADED:this.loading=!1,r="imageloadend";break;case s.A.ERROR:this.loading=!1,r="imageloaderror";break;default:return}this.hasListener(r)&&this.dispatchEvent(new _(r,e))}}function w(t,e){t.getImage().src=e}const x=b,E=class extends x{constructor(t){const e=void 0!==t.crossOrigin?t.crossOrigin:null,r=void 0!==t.imageLoadFunction?t.imageLoadFunction:w;super({attributions:t.attributions,interpolate:t.interpolate,projection:(0,y.Jt)(t.projection)}),this.url_=t.url,this.imageExtent_=t.imageExtent,this.image=null,this.image=new o.Ay(this.imageExtent_,void 0,1,function(t){const e=t.load||o.D4,r=t.imageExtent,n=t.crossOrigin??null;return()=>{const i=new Image;return i.crossOrigin=n,e(i,t.url).then((t=>{const e=(0,h.RG)(r)/t.width,n=(0,h.Oq)(r)/t.height;return{image:t,extent:r,resolution:e!==n?[e,n]:n,pixelRatio:1}}))}}({url:t.url,imageExtent:t.imageExtent,crossOrigin:e,load:(t,e)=>(this.image.setImage(t),r(this.image,e),(0,o.D4)(t))})),this.image.addEventListener(n.A.CHANGE,this.handleImageChange.bind(this))}getImageExtent(){return this.imageExtent_}getImageInternal(t,e,r,n){return(0,h.HY)(t,this.image.getExtent())?this.image:null}getUrl(){return this.url_}}},83486:(t,e,r)=>{"use strict";r.d(e,{A:()=>d});var n=r(15159),i=r(44095);const s=new Error("Image failed to load");function o(t,e,r,n,o){return new Promise(((a,l)=>{const c=new Image;c.crossOrigin=o.crossOrigin??null,c.addEventListener("load",(()=>a(c))),c.addEventListener("error",(()=>l(s))),c.src=(0,i.M)(t,e,r,n,o.maxY)}))}function a(t){return function(e,r,n,s){return o((0,i.de)(t,e,r,n),e,r,n,s)}}function l(t){let e;if(Array.isArray(t))e=a(t);else if("string"==typeof t)e=a((0,i.Uu)(t));else{if("function"!=typeof t)throw new Error("The url option must be a single template, an array of templates, or a function for getting a URL");r=t,e=function(t,e,n,i){return o(r(t,e,n,i),t,e,n,i)}}var r;return e}let c=0;function u(t){return Array.isArray(t)?t.join("\n"):"string"==typeof t?t:(++c,"url-function-key-"+c)}class h extends n.A{constructor(t){let e,r=(t=t||{}).loader;t.url&&(r=l(t.url),e=u(t.url));const n=r?t.state:"loading",i=void 0===t.wrapX||t.wrapX;super({loader:r,key:e,attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,maxZoom:t.maxZoom,minZoom:t.minZoom,tileSize:t.tileSize,gutter:t.gutter,maxResolution:t.maxResolution,projection:t.projection,tileGrid:t.tileGrid,state:n,wrapX:i,transition:t.transition,interpolate:!1!==t.interpolate,crossOrigin:t.crossOrigin})}setUrl(t){const e=l(t);this.setLoader(e),this.setKey(u(t)),"ready"!==this.getState()&&this.setState("ready")}}const d=h},31274:(t,e,r)=>{"use strict";r.d(e,{A:()=>a});var n=r(72614),i=r(12940);class s extends n.A{constructor(t){super(),this.projection=(0,i.Jt)(t.projection),this.attributions_=o(t.attributions),this.attributionsCollapsible_=t.attributionsCollapsible??!0,this.loading=!1,this.state_=void 0!==t.state?t.state:"ready",this.wrapX_=void 0!==t.wrapX&&t.wrapX,this.interpolate_=!!t.interpolate,this.viewResolver=null,this.viewRejector=null;const e=this;this.viewPromise_=new Promise((function(t,r){e.viewResolver=t,e.viewRejector=r}))}getAttributions(){return this.attributions_}getAttributionsCollapsible(){return this.attributionsCollapsible_}getProjection(){return this.projection}getResolutions(t){return null}getView(){return this.viewPromise_}getState(){return this.state_}getWrapX(){return this.wrapX_}getInterpolate(){return this.interpolate_}refresh(){this.changed()}setAttributions(t){this.attributions_=o(t),this.changed()}setState(t){this.state_=t,this.changed()}}function o(t){return t?"function"==typeof t?t:(Array.isArray(t)||(t=[t]),e=>t):null}const a=s},17903:(t,e,r)=>{"use strict";r.d(e,{A:()=>h,c:()=>u});var n=r(37283),i=r(31274),s=r(98629),o=r(32077),a=r(53908),l=r(80996);class c extends i.A{constructor(t){super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,projection:t.projection,state:t.state,wrapX:t.wrapX,interpolate:t.interpolate}),this.on,this.once,this.un,this.tilePixelRatio_=void 0!==t.tilePixelRatio?t.tilePixelRatio:1,this.tileGrid=void 0!==t.tileGrid?t.tileGrid:null;this.tileGrid&&(0,a.xq)(this.tileGrid.getTileSize(this.tileGrid.getMinZoom()),[256,256]),this.tmpSize=[0,0],this.key_=t.key||(0,s.v6)(this),this.tileOptions={transition:t.transition,interpolate:t.interpolate},this.zDirection=t.zDirection?t.zDirection:0}getGutterForProjection(t){return 0}getKey(){return this.key_}setKey(t){this.key_!==t&&(this.key_=t,this.changed())}getResolutions(t){const e=t?this.getTileGridForProjection(t):this.tileGrid;return e?e.getResolutions():null}getTile(t,e,r,n,i){return(0,s.b0)()}getTileGrid(){return this.tileGrid}getTileGridForProjection(t){return this.tileGrid?this.tileGrid:(0,o.pr)(t)}getTilePixelRatio(t){return this.tilePixelRatio_}getTilePixelSize(t,e,r){const n=this.getTileGridForProjection(r),i=this.getTilePixelRatio(e),s=(0,a.xq)(n.getTileSize(t),this.tmpSize);return 1==i?s:(0,a.hs)(s,i,this.tmpSize)}getTileCoordForTileUrlFunction(t,e){e=void 0!==e?e:this.getProjection();const r=this.getTileGridForProjection(e);return this.getWrapX()&&e.isGlobal()&&(t=(0,o.Li)(r,t,e)),(0,l.N5)(t,r)?t:null}clear(){}refresh(){this.clear(),super.refresh()}}class u extends n.Ay{constructor(t,e){super(t),this.tile=e}}const h=c},67663:(t,e,r)=>{"use strict";r.d(e,{A:()=>n});const n={TILELOADSTART:"tileloadstart",TILELOADEND:"tileloadend",TILELOADERROR:"tileloaderror"}},27948:(t,e,r)=>{"use strict";r.d(e,{A:()=>d});var n=r(67663),i=r(17903),s=r(20884),o=r(72475),a=r(44095),l=r(80996);function c(t,e){return function(r,n,i){if(!r)return;let s;const o=r[0];if(e){const t=e.getFullTileRange(o);t&&(s=t.getHeight()-1)}return(0,a.M)(t,o,r[1],r[2],s)}}var u=r(98629);class h extends i.A{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,projection:t.projection,state:t.state,tileGrid:t.tileGrid,tilePixelRatio:t.tilePixelRatio,wrapX:t.wrapX,transition:t.transition,interpolate:t.interpolate,key:t.key,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection}),this.generateTileUrlFunction_=this.tileUrlFunction===h.prototype.tileUrlFunction,this.tileLoadFunction=t.tileLoadFunction,t.tileUrlFunction&&(this.tileUrlFunction=t.tileUrlFunction),this.urls=null,t.urls?this.setUrls(t.urls):t.url&&this.setUrl(t.url),this.tileLoadingKeys_={}}getTileLoadFunction(){return this.tileLoadFunction}getTileUrlFunction(){return Object.getPrototypeOf(this).tileUrlFunction===this.tileUrlFunction?this.tileUrlFunction.bind(this):this.tileUrlFunction}getUrls(){return this.urls}handleTileChange(t){const e=t.target,r=(0,u.v6)(e),o=e.getState();let a;o==s.A.LOADING?(this.tileLoadingKeys_[r]=!0,a=n.A.TILELOADSTART):r in this.tileLoadingKeys_&&(delete this.tileLoadingKeys_[r],a=o==s.A.ERROR?n.A.TILELOADERROR:o==s.A.LOADED?n.A.TILELOADEND:void 0),null!=a&&this.dispatchEvent(new i.c(a,e))}setTileLoadFunction(t){this.tileLoadFunction=t,this.changed()}setTileUrlFunction(t,e){this.tileUrlFunction=t,void 0!==e?this.setKey(e):this.changed()}setUrl(t){const e=(0,a.Uu)(t);this.urls=e,this.setUrls(e)}setUrls(t){this.urls=t;const e=t.join("\n");this.generateTileUrlFunction_?this.setTileUrlFunction(function(t,e){const r=t.length,n=new Array(r);for(let i=0;i<r;++i)n[i]=c(t[i],e);return function(t){return 1===t.length?t[0]:function(e,r,n){if(!e)return;const i=(0,l.tW)(e),s=(0,o.xP)(i,t.length);return t[s](e,r,n)}}(n)}(t,this.tileGrid),e):this.setKey(e)}tileUrlFunction(t,e,r){}}const d=h},90693:(t,e,r)=>{"use strict";r.d(e,{A:()=>A});var n=r(20489),i=r(45981),s=r(37283),o=r(24187),a=r(56644),l=r(44663),c=r(44509),u=r(98629),h=r(82048);const d=class{constructor(t){this.rbush_=new l.A(t),this.items_={}}insert(t,e){const r={minX:t[0],minY:t[1],maxX:t[2],maxY:t[3],value:e};this.rbush_.insert(r),this.items_[(0,u.v6)(e)]=r}load(t,e){const r=new Array(e.length);for(let n=0,i=e.length;n<i;n++){const i=t[n],s=e[n],o={minX:i[0],minY:i[1],maxX:i[2],maxY:i[3],value:s};r[n]=o,this.items_[(0,u.v6)(s)]=o}this.rbush_.load(r)}remove(t){const e=(0,u.v6)(t),r=this.items_[e];return delete this.items_[e],null!==this.rbush_.remove(r)}update(t,e){const r=this.items_[(0,u.v6)(e)],n=[r.minX,r.minY,r.maxX,r.maxY];(0,c.aI)(n,t)||(this.remove(e),this.insert(t,e))}getAll(){return this.rbush_.all().map((function(t){return t.value}))}getInExtent(t){const e={minX:t[0],minY:t[1],maxX:t[2],maxY:t[3]};return this.rbush_.search(e).map((function(t){return t.value}))}forEach(t){return this.forEach_(this.getAll(),t)}forEachInExtent(t,e){return this.forEach_(this.getInExtent(t),e)}forEach_(t,e){let r;for(let n=0,i=t.length;n<i;n++)if(r=e(t[n]),r)return r;return r}isEmpty(){return(0,h.p)(this.items_)}clear(){this.rbush_.clear(),this.items_={}}getExtent(t){const e=this.rbush_.toJSON();return(0,c.N)(e.minX,e.minY,e.maxX,e.maxY,t)}concat(t){this.rbush_.load(t.rbush_.all());for(const e in t.items_)this.items_[e]=t.items_[e]}};var f=r(28528),p=r(31274);const m="addfeature",g="removefeature";var y=r(97440);function v(t,e){return[[-1/0,-1/0,1/0,1/0]]}r(12940);var _=r(30878),b=r(30444),w=r(94456),x=r(64272);class E extends s.Ay{constructor(t,e,r){super(t),this.feature=e,this.features=r}}class S extends p.A{constructor(t){super({attributions:(t=t||{}).attributions,interpolate:!0,projection:void 0,state:"ready",wrapX:void 0===t.wrapX||t.wrapX}),this.on,this.once,this.un,this.loader_=y.tV,this.format_=t.format||null,this.overlaps_=void 0===t.overlaps||t.overlaps,this.url_=t.url,void 0!==t.loader?this.loader_=t.loader:void 0!==this.url_&&((0,_.v)(this.format_,"`format` must be set when `url` is set"),this.loader_=(0,x.nF)(this.url_,this.format_)),this.strategy_=void 0!==t.strategy?t.strategy:v;const e=void 0===t.useSpatialIndex||t.useSpatialIndex;let r,i;this.featuresRtree_=e?new d:null,this.loadedExtentsRtree_=new d,this.loadingExtentsCount_=0,this.nullGeometryFeatures_={},this.idIndex_={},this.uidIndex_={},this.featureChangeKeys_={},this.featuresCollection_=null,Array.isArray(t.features)?i=t.features:t.features&&(r=t.features,i=r.getArray()),e||void 0!==r||(r=new n.A(i)),void 0!==i&&this.addFeaturesInternal(i),void 0!==r&&this.bindFeaturesCollection_(r)}addFeature(t){this.addFeatureInternal(t),this.changed()}addFeatureInternal(t){const e=(0,u.v6)(t);if(!this.addToIndex_(e,t))return void(this.featuresCollection_&&this.featuresCollection_.remove(t));this.setupChangeEvents_(e,t);const r=t.getGeometry();if(r){const e=r.getExtent();this.featuresRtree_&&this.featuresRtree_.insert(e,t)}else this.nullGeometryFeatures_[e]=t;this.dispatchEvent(new E(m,t))}setupChangeEvents_(t,e){e instanceof f.Ay||(this.featureChangeKeys_[t]=[(0,w.KT)(e,o.A.CHANGE,this.handleFeatureChange_,this),(0,w.KT)(e,a.A.PROPERTYCHANGE,this.handleFeatureChange_,this)])}addToIndex_(t,e){let r=!0;if(void 0!==e.getId()){const t=String(e.getId());if(t in this.idIndex_)if(e instanceof f.Ay){const n=this.idIndex_[t];n instanceof f.Ay?Array.isArray(n)?n.push(e):this.idIndex_[t]=[n,e]:r=!1}else r=!1;else this.idIndex_[t]=e}return r&&((0,_.v)(!(t in this.uidIndex_),"The passed `feature` was already added to the source"),this.uidIndex_[t]=e),r}addFeatures(t){this.addFeaturesInternal(t),this.changed()}addFeaturesInternal(t){const e=[],r=[],n=[];for(let e=0,n=t.length;e<n;e++){const n=t[e],i=(0,u.v6)(n);this.addToIndex_(i,n)&&r.push(n)}for(let t=0,i=r.length;t<i;t++){const i=r[t],s=(0,u.v6)(i);this.setupChangeEvents_(s,i);const o=i.getGeometry();if(o){const t=o.getExtent();e.push(t),n.push(i)}else this.nullGeometryFeatures_[s]=i}if(this.featuresRtree_&&this.featuresRtree_.load(e,n),this.hasListener(m))for(let t=0,e=r.length;t<e;t++)this.dispatchEvent(new E(m,r[t]))}bindFeaturesCollection_(t){let e=!1;this.addEventListener(m,(function(r){e||(e=!0,t.push(r.feature),e=!1)})),this.addEventListener(g,(function(r){e||(e=!0,t.remove(r.feature),e=!1)})),t.addEventListener(i.A.ADD,(t=>{e||(e=!0,this.addFeature(t.element),e=!1)})),t.addEventListener(i.A.REMOVE,(t=>{e||(e=!0,this.removeFeature(t.element),e=!1)})),this.featuresCollection_=t}clear(t){if(t){for(const t in this.featureChangeKeys_)this.featureChangeKeys_[t].forEach(w.JH);this.featuresCollection_||(this.featureChangeKeys_={},this.idIndex_={},this.uidIndex_={})}else if(this.featuresRtree_){const t=t=>{this.removeFeatureInternal(t)};this.featuresRtree_.forEach(t);for(const t in this.nullGeometryFeatures_)this.removeFeatureInternal(this.nullGeometryFeatures_[t])}this.featuresCollection_&&this.featuresCollection_.clear(),this.featuresRtree_&&this.featuresRtree_.clear(),this.nullGeometryFeatures_={};const e=new E("clear");this.dispatchEvent(e),this.changed()}forEachFeature(t){if(this.featuresRtree_)return this.featuresRtree_.forEach(t);this.featuresCollection_&&this.featuresCollection_.forEach(t)}forEachFeatureAtCoordinateDirect(t,e){const r=[t[0],t[1],t[0],t[1]];return this.forEachFeatureInExtent(r,(function(r){const n=r.getGeometry();if(n instanceof f.Ay||n.intersectsCoordinate(t))return e(r)}))}forEachFeatureInExtent(t,e){if(this.featuresRtree_)return this.featuresRtree_.forEachInExtent(t,e);this.featuresCollection_&&this.featuresCollection_.forEach(e)}forEachFeatureIntersectingExtent(t,e){return this.forEachFeatureInExtent(t,(function(r){const n=r.getGeometry();if(n instanceof f.Ay||n.intersectsExtent(t)){const t=e(r);if(t)return t}}))}getFeaturesCollection(){return this.featuresCollection_}getFeatures(){let t;return this.featuresCollection_?t=this.featuresCollection_.getArray().slice(0):this.featuresRtree_&&(t=this.featuresRtree_.getAll(),(0,h.p)(this.nullGeometryFeatures_)||(0,b.X$)(t,Object.values(this.nullGeometryFeatures_))),t}getFeaturesAtCoordinate(t){const e=[];return this.forEachFeatureAtCoordinateDirect(t,(function(t){e.push(t)})),e}getFeaturesInExtent(t,e){if(this.featuresRtree_){if(!(e&&e.canWrapX()&&this.getWrapX()))return this.featuresRtree_.getInExtent(t);const r=(0,c.QJ)(t,e);return[].concat(...r.map((t=>this.featuresRtree_.getInExtent(t))))}return this.featuresCollection_?this.featuresCollection_.getArray().slice(0):[]}getClosestFeatureToCoordinate(t,e){const r=t[0],n=t[1];let i=null;const s=[NaN,NaN];let o=1/0;const a=[-1/0,-1/0,1/0,1/0];return e=e||y.rT,this.featuresRtree_.forEachInExtent(a,(function(t){if(e(t)){const e=t.getGeometry(),l=o;if(o=e instanceof f.Ay?0:e.closestPointXY(r,n,s,o),o<l){i=t;const e=Math.sqrt(o);a[0]=r-e,a[1]=n-e,a[2]=r+e,a[3]=n+e}}})),i}getExtent(t){return this.featuresRtree_.getExtent(t)}getFeatureById(t){const e=this.idIndex_[t.toString()];return void 0!==e?e:null}getFeatureByUid(t){const e=this.uidIndex_[t];return void 0!==e?e:null}getFormat(){return this.format_}getOverlaps(){return this.overlaps_}getUrl(){return this.url_}handleFeatureChange_(t){const e=t.target,r=(0,u.v6)(e),n=e.getGeometry();if(n){const t=n.getExtent();r in this.nullGeometryFeatures_?(delete this.nullGeometryFeatures_[r],this.featuresRtree_&&this.featuresRtree_.insert(t,e)):this.featuresRtree_&&this.featuresRtree_.update(t,e)}else r in this.nullGeometryFeatures_||(this.featuresRtree_&&this.featuresRtree_.remove(e),this.nullGeometryFeatures_[r]=e);const i=e.getId();if(void 0!==i){const t=i.toString();this.idIndex_[t]!==e&&(this.removeFromIdIndex_(e),this.idIndex_[t]=e)}else this.removeFromIdIndex_(e),this.uidIndex_[r]=e;this.changed(),this.dispatchEvent(new E("changefeature",e))}hasFeature(t){const e=t.getId();return void 0!==e?e in this.idIndex_:(0,u.v6)(t)in this.uidIndex_}isEmpty(){return this.featuresRtree_?this.featuresRtree_.isEmpty()&&(0,h.p)(this.nullGeometryFeatures_):!this.featuresCollection_||0===this.featuresCollection_.getLength()}loadFeatures(t,e,r){const n=this.loadedExtentsRtree_,i=this.strategy_(t,e,r);for(let t=0,s=i.length;t<s;++t){const s=i[t];n.forEachInExtent(s,(function(t){return(0,c.ms)(t.extent,s)}))||(++this.loadingExtentsCount_,this.dispatchEvent(new E("featuresloadstart")),this.loader_.call(this,s,e,r,(t=>{--this.loadingExtentsCount_,this.dispatchEvent(new E("featuresloadend",void 0,t))}),(()=>{--this.loadingExtentsCount_,this.dispatchEvent(new E("featuresloaderror"))})),n.insert(s,{extent:s.slice()}))}this.loading=!(this.loader_.length<4)&&this.loadingExtentsCount_>0}refresh(){this.clear(!0),this.loadedExtentsRtree_.clear(),super.refresh()}removeLoadedExtent(t){const e=this.loadedExtentsRtree_;let r;e.forEachInExtent(t,(function(e){if((0,c.aI)(e.extent,t))return r=e,!0})),r&&e.remove(r)}removeFeatures(t){let e=!1;for(let r=0,n=t.length;r<n;++r)e=this.removeFeatureInternal(t[r])||e;e&&this.changed()}removeFeature(t){t&&this.removeFeatureInternal(t)&&this.changed()}removeFeatureInternal(t){const e=(0,u.v6)(t);if(!(e in this.uidIndex_))return!1;e in this.nullGeometryFeatures_?delete this.nullGeometryFeatures_[e]:this.featuresRtree_&&this.featuresRtree_.remove(t);const r=this.featureChangeKeys_[e];r?.forEach(w.JH),delete this.featureChangeKeys_[e];const n=t.getId();if(void 0!==n){const e=n.toString(),r=this.idIndex_[e];r===t?delete this.idIndex_[e]:Array.isArray(r)&&(r.splice(r.indexOf(t),1),1===r.length&&(this.idIndex_[e]=r[0]))}return delete this.uidIndex_[e],this.hasListener(g)&&this.dispatchEvent(new E(g,t)),!0}removeFromIdIndex_(t){for(const e in this.idIndex_)if(this.idIndex_[e]===t){delete this.idIndex_[e];break}}setLoader(t){this.loader_=t}setUrl(t){(0,_.v)(this.format_,"`format` must be set when `url` is set"),this.url_=t,this.setLoader((0,x.nF)(t,this.format_))}}const A=S},34633:(t,e,r)=>{"use strict";r.d(e,{A:()=>x});var n=r(24187),i=r(76741),s=r(20884);class o extends i.A{constructor(t,e,r,n,i,s){super(t,e,s),this.extent=null,this.format_=n,this.features_=null,this.loader_,this.projection=null,this.resolution,this.tileLoadFunction_=i,this.url_=r,this.key=r}getTileUrl(){return this.url_}getFormat(){return this.format_}getFeatures(){return this.features_}load(){this.state==s.A.IDLE&&(this.setState(s.A.LOADING),this.tileLoadFunction_(this,this.url_),this.loader_&&this.loader_(this.extent,this.resolution,this.projection))}onLoad(t,e){this.setFeatures(t)}onError(){this.setState(s.A.ERROR)}setFeatures(t){this.features_=t,this.setState(s.A.LOADED)}setLoader(t){this.loader_=t}}const a=o;var l=r(17668),c=r(27948),u=r(83085),h=r(98629);const d=[];class f extends i.A{constructor(t,e,r,n,i){super(t,e,{transition:0}),this.context_=null,this.executorGroups=[],this.loadingSourceTiles=0,this.hitDetectionImageData={},this.replayState_={},this.sourceTiles=[],this.errorTileKeys={},this.wantedResolution,this.getSourceTiles=n.bind(void 0,this),this.removeSourceTiles_=i,this.wrappedTileCoord=r}getContext(){return this.context_||(this.context_=(0,u.Y)(1,1,d)),this.context_}hasContext(){return!!this.context_}getImage(){return this.hasContext()?this.getContext().canvas:null}getReplayState(t){const e=(0,h.v6)(t);return e in this.replayState_||(this.replayState_[e]={dirty:!1,renderedRenderOrder:null,renderedResolution:NaN,renderedRevision:-1,renderedTileResolution:NaN,renderedTileRevision:-1,renderedTileZ:-1}),this.replayState_[e]}load(){this.getSourceTiles()}release(){this.context_&&((0,u.Yg)(this.context_),d.push(this.context_.canvas),this.context_=null),this.removeSourceTiles_(this),this.sourceTiles.length=0,super.release()}}const p=f;var m=r(75961),g=r(44509),y=r(32077),v=r(82048),_=r(64272),b=r(53908);class w extends c.A{constructor(t){const e=t.projection||"EPSG:3857",r=t.extent||(0,y.kZ)(e),n=t.tileGrid||(0,y.EN)({extent:r,maxResolution:t.maxResolution,maxZoom:void 0!==t.maxZoom?t.maxZoom:22,minZoom:t.minZoom,tileSize:t.tileSize||512});super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,interpolate:!0,projection:e,state:t.state,tileGrid:n,tileLoadFunction:t.tileLoadFunction?t.tileLoadFunction:E,tileUrlFunction:t.tileUrlFunction,url:t.url,urls:t.urls,wrapX:void 0===t.wrapX||t.wrapX,transition:t.transition,zDirection:void 0===t.zDirection?1:t.zDirection}),this.format_=t.format?t.format:null,this.tileKeysBySourceTileUrl_={},this.sourceTiles_={},this.overlaps_=null==t.overlaps||t.overlaps,this.tileClass=t.tileClass?t.tileClass:a,this.tileGrids_={}}getOverlaps(){return this.overlaps_}getSourceTiles(t,e,r){if(r.getState()===s.A.IDLE){r.setState(s.A.LOADING);const i=r.wrappedTileCoord,o=this.getTileGridForProjection(e),a=o.getTileCoordExtent(i),l=i[0],c=o.getResolution(l);(0,g.r)(a,-c,a);const u=this.tileGrid,h=u.getExtent();h&&(0,g._N)(a,h,a);const d=u.getZForResolution(c,this.zDirection);u.forEachTileCoord(a,d,(i=>{const o=this.tileUrlFunction(i,t,e);this.sourceTiles_[o]||(this.sourceTiles_[o]=new this.tileClass(i,o?s.A.IDLE:s.A.EMPTY,o,this.format_,this.tileLoadFunction));const a=this.sourceTiles_[o];r.sourceTiles.push(a),this.tileKeysBySourceTileUrl_[o]||(this.tileKeysBySourceTileUrl_[o]=[]),this.tileKeysBySourceTileUrl_[o].push(r.getKey());const l=a.getState();if(l<s.A.LOADED){const t=e=>{this.handleTileChange(e);const i=a.getState();if(i===s.A.LOADED||i===s.A.ERROR){const e=a.getKey();e in r.errorTileKeys?a.getState()===s.A.LOADED&&delete r.errorTileKeys[e]:r.loadingSourceTiles--,i===s.A.ERROR?r.errorTileKeys[e]=!0:a.removeEventListener(n.A.CHANGE,t),0===r.loadingSourceTiles&&r.setState((0,v.p)(r.errorTileKeys)?s.A.LOADED:s.A.ERROR)}};a.addEventListener(n.A.CHANGE,t),r.loadingSourceTiles++}l===s.A.IDLE&&(a.extent=u.getTileCoordExtent(i),a.projection=e,a.resolution=u.getResolution(i[0]),a.load())})),r.loadingSourceTiles||r.setState(r.sourceTiles.some((t=>t.getState()===s.A.ERROR))?s.A.ERROR:s.A.LOADED)}return r.sourceTiles}removeSourceTiles(t){const e=t.sourceTiles;for(let t=0,r=e.length;t<r;++t){const r=e[t].getTileUrl(),n=this.getKey();if(!this.tileKeysBySourceTileUrl_[r])return;const i=this.tileKeysBySourceTileUrl_[r][n];-1!==i&&(this.tileKeysBySourceTileUrl_[r].splice(i,1),0===this.tileKeysBySourceTileUrl_[r].length&&(delete this.tileKeysBySourceTileUrl_[r],delete this.sourceTiles_[r]))}}getTile(t,e,r,n,i){const o=[t,e,r];let a=this.getTileCoordForTileUrlFunction(o,i);const l=this.getTileGrid().getExtent(),c=this.getTileGridForProjection(i);if(a&&l){const e=c.getTileCoordExtent(a);(0,g.r)(e,-c.getResolution(t),e),(0,g.HY)(l,e)||(a=null)}let u=!0;if(null!==a){const e=this.tileGrid,r=c.getResolution(t),s=e.getZForResolution(r,1),o=c.getTileCoordExtent(a);(0,g.r)(o,-r,o),e.forEachTileCoord(o,s,(t=>{u=u&&!this.tileUrlFunction(t,n,i)}))}const h=new p(o,u?s.A.EMPTY:s.A.IDLE,a,this.getSourceTiles.bind(this,n,i),this.removeSourceTiles.bind(this));return h.key=this.getKey(),h}getTileGridForProjection(t){const e=t.getCode();let r=this.tileGrids_[e];if(!r){const t=this.tileGrid,n=t.getResolutions().slice(),i=n.map((function(e,r){return t.getOrigin(r)})),s=n.map((function(e,r){return t.getTileSize(r)})),o=m.L+1;for(let t=n.length;t<o;++t)n.push(n[t-1]/2),i.push(i[t-1]),s.push(s[t-1]);r=new l.A({extent:t.getExtent(),origins:i,resolutions:n,tileSizes:s}),this.tileGrids_[e]=r}return r}getTilePixelRatio(t){return t}getTilePixelSize(t,e,r){const n=this.getTileGridForProjection(r),i=(0,b.xq)(n.getTileSize(t),this.tmpSize);return[Math.round(i[0]*e),Math.round(i[1]*e)]}}const x=w;function E(t,e){t.setLoader((function(r,n,i){(0,_.m8)(e,t.getFormat(),r,n,i,t.onLoad.bind(t),t.onError.bind(t))}))}},61691:(t,e,r)=>{"use strict";r.d(e,{A:()=>p});var n=r(24187),i=r(67564),s=r(84562),o=r(20884),a=r(27948),l=r(12940),c=r(32077),u=r(98629);class h extends a.A{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,projection:t.projection,state:t.state,tileGrid:t.tileGrid,tileLoadFunction:t.tileLoadFunction?t.tileLoadFunction:d,tilePixelRatio:t.tilePixelRatio,tileUrlFunction:t.tileUrlFunction,url:t.url,urls:t.urls,wrapX:t.wrapX,transition:t.transition,interpolate:void 0===t.interpolate||t.interpolate,key:t.key,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection}),this.crossOrigin=void 0!==t.crossOrigin?t.crossOrigin:null,this.tileClass=void 0!==t.tileClass?t.tileClass:i.A,this.tileGridForProjection={},this.reprojectionErrorThreshold_=t.reprojectionErrorThreshold,this.renderReprojectionEdges_=!1}getGutterForProjection(t){return this.getProjection()&&t&&!(0,l.tI)(this.getProjection(),t)?0:this.getGutter()}getGutter(){return 0}getKey(){let t=super.getKey();return this.getInterpolate()||(t+=":disable-interpolation"),t}getTileGridForProjection(t){const e=this.getProjection();if(this.tileGrid&&(!e||(0,l.tI)(e,t)))return this.tileGrid;const r=(0,u.v6)(t);return r in this.tileGridForProjection||(this.tileGridForProjection[r]=(0,c.pr)(t)),this.tileGridForProjection[r]}createTile_(t,e,r,i,s,a){const l=[t,e,r],c=this.getTileCoordForTileUrlFunction(l,s),u=c?this.tileUrlFunction(c,i,s):void 0,h=new this.tileClass(l,void 0!==u?o.A.IDLE:o.A.EMPTY,void 0!==u?u:"",this.crossOrigin,this.tileLoadFunction,this.tileOptions);return h.key=a,h.addEventListener(n.A.CHANGE,this.handleTileChange.bind(this)),h}getTile(t,e,r,n,i){const o=this.getProjection();if(!o||!i||(0,l.tI)(o,i))return this.getTileInternal(t,e,r,n,o||i);const a=[t,e,r],c=this.getKey(),u=this.getTileGridForProjection(o),h=this.getTileGridForProjection(i),d=this.getTileCoordForTileUrlFunction(a,i),f=new s.A(o,u,i,h,a,d,this.getTilePixelRatio(n),this.getGutter(),((t,e,r,n)=>this.getTileInternal(t,e,r,n,o)),this.reprojectionErrorThreshold_,this.renderReprojectionEdges_,this.tileOptions);return f.key=c,f}getTileInternal(t,e,r,n,i){const s=this.getKey();return this.createTile_(t,e,r,n,i,s)}setRenderReprojectionEdges(t){this.renderReprojectionEdges_!=t&&(this.renderReprojectionEdges_=t,this.changed())}setTileGridForProjection(t,e){const r=(0,l.Jt)(t);if(r){const t=(0,u.v6)(r);t in this.tileGridForProjection||(this.tileGridForProjection[t]=e)}}}function d(t,e){t.getImage().src=e}const f=h,p=class extends f{constructor(t){const e=void 0!==(t=t||{}).projection?t.projection:"EPSG:3857",r=void 0!==t.tileGrid?t.tileGrid:(0,c.EN)({extent:(0,c.kZ)(e),maxResolution:t.maxResolution,maxZoom:t.maxZoom,minZoom:t.minZoom,tileSize:t.tileSize});super({attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:e,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileGrid:r,tileLoadFunction:t.tileLoadFunction,tilePixelRatio:t.tilePixelRatio,tileUrlFunction:t.tileUrlFunction,url:t.url,urls:t.urls,wrapX:void 0===t.wrapX||t.wrapX,transition:t.transition,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection}),this.gutter_=void 0!==t.gutter?t.gutter:0}getGutter(){return this.gutter_}}},98063:(t,e,r)=>{"use strict";r.d(e,{A:()=>s});var n=r(60239),i=r(30878);const s=class{constructor(t){this.highWaterMark=void 0!==t?t:2048,this.count_=0,this.entries_={},this.oldest_=null,this.newest_=null}canExpireCache(){return this.highWaterMark>0&&this.getCount()>this.highWaterMark}expireCache(t){for(;this.canExpireCache();){const t=this.pop();t instanceof n.A&&t.dispose()}}clear(){this.count_=0,this.entries_={},this.oldest_=null,this.newest_=null}containsKey(t){return this.entries_.hasOwnProperty(t)}forEach(t){let e=this.oldest_;for(;e;)t(e.value_,e.key_,this),e=e.newer}get(t,e){const r=this.entries_[t];return(0,i.v)(void 0!==r,"Tried to get a value for a key that does not exist in the cache"),r===this.newest_||(r===this.oldest_?(this.oldest_=this.oldest_.newer,this.oldest_.older=null):(r.newer.older=r.older,r.older.newer=r.newer),r.newer=null,r.older=this.newest_,this.newest_.newer=r,this.newest_=r),r.value_}remove(t){const e=this.entries_[t];return(0,i.v)(void 0!==e,"Tried to get a value for a key that does not exist in the cache"),e===this.newest_?(this.newest_=e.older,this.newest_&&(this.newest_.newer=null)):e===this.oldest_?(this.oldest_=e.newer,this.oldest_&&(this.oldest_.older=null)):(e.newer.older=e.older,e.older.newer=e.newer),delete this.entries_[t],--this.count_,e.value_}getCount(){return this.count_}getKeys(){const t=new Array(this.count_);let e,r=0;for(e=this.newest_;e;e=e.older)t[r++]=e.key_;return t}getValues(){const t=new Array(this.count_);let e,r=0;for(e=this.newest_;e;e=e.older)t[r++]=e.value_;return t}peekLast(){return this.oldest_.value_}peekLastKey(){return this.oldest_.key_}peekFirstKey(){return this.newest_.key_}peek(t){return this.entries_[t]?.value_}pop(){const t=this.oldest_;return delete this.entries_[t.key_],t.newer&&(t.newer.older=null),this.oldest_=t.newer,this.oldest_||(this.newest_=null),--this.count_,t.value_}replace(t,e){this.get(t),this.entries_[t].value_=e}set(t,e){(0,i.v)(!(t in this.entries_),"Tried to set a value for a key that is used already");const r={key_:t,newer:null,older:this.newest_,value_:e};this.newest_?this.newest_.newer=r:this.oldest_=r,this.newest_=r,this.entries_[t]=r,++this.count_}setSize(t){this.highWaterMark=t}}},25174:(t,e,r)=>{"use strict";r.d(e,{A:()=>d});var n=r(24187),i=r(39915),s=r(51386),o=r(41009),a=r(30878),l=r(98525),c=r(98629);function u(t,e,r,n){return void 0!==r&&void 0!==n?[r/t,n/e]:void 0!==r?r/t:void 0!==n?n/e:1}class h extends s.A{constructor(t){const e=void 0!==(t=t||{}).opacity?t.opacity:1,r=void 0!==t.rotation?t.rotation:0,n=void 0!==t.scale?t.scale:1,s=void 0!==t.rotateWithView&&t.rotateWithView;super({opacity:e,rotation:r,scale:n,displacement:void 0!==t.displacement?t.displacement:[0,0],rotateWithView:s,declutterMode:t.declutterMode}),this.anchor_=void 0!==t.anchor?t.anchor:[.5,.5],this.normalizedAnchor_=null,this.anchorOrigin_=void 0!==t.anchorOrigin?t.anchorOrigin:"top-left",this.anchorXUnits_=void 0!==t.anchorXUnits?t.anchorXUnits:"fraction",this.anchorYUnits_=void 0!==t.anchorYUnits?t.anchorYUnits:"fraction",this.crossOrigin_=void 0!==t.crossOrigin?t.crossOrigin:null;const h=void 0!==t.img?t.img:null;let d,f=t.src;if((0,a.v)(!(void 0!==f&&h),"`image` and `src` cannot be provided at the same time"),void 0!==f&&0!==f.length||!h||(f=h.src||(0,c.v6)(h)),(0,a.v)(void 0!==f&&f.length>0,"A defined and non-empty `src` or `image` must be provided"),(0,a.v)(!((void 0!==t.width||void 0!==t.height)&&void 0!==t.scale),"`width` or `height` cannot be provided together with `scale`"),void 0!==t.src?d=i.A.IDLE:void 0!==h&&(d="complete"in h?h.complete?h.src?i.A.LOADED:i.A.IDLE:i.A.LOADING:i.A.LOADED),this.color_=void 0!==t.color?(0,o._j)(t.color):null,this.iconImage_=(0,l.J)(h,f,this.crossOrigin_,d,this.color_),this.offset_=void 0!==t.offset?t.offset:[0,0],this.offsetOrigin_=void 0!==t.offsetOrigin?t.offsetOrigin:"top-left",this.origin_=null,this.size_=void 0!==t.size?t.size:null,this.initialOptions_,void 0!==t.width||void 0!==t.height){let e,r;if(t.size)[e,r]=t.size;else{const n=this.getImage(1);if(n.width&&n.height)e=n.width,r=n.height;else if(n instanceof HTMLImageElement){this.initialOptions_=t;const e=()=>{if(this.unlistenImageChange(e),!this.initialOptions_)return;const r=this.iconImage_.getSize();this.setScale(u(r[0],r[1],t.width,t.height))};return void this.listenImageChange(e)}}void 0!==e&&this.setScale(u(e,r,t.width,t.height))}}clone(){let t,e,r;return this.initialOptions_?(e=this.initialOptions_.width,r=this.initialOptions_.height):(t=this.getScale(),t=Array.isArray(t)?t.slice():t),new h({anchor:this.anchor_.slice(),anchorOrigin:this.anchorOrigin_,anchorXUnits:this.anchorXUnits_,anchorYUnits:this.anchorYUnits_,color:this.color_&&this.color_.slice?this.color_.slice():this.color_||void 0,crossOrigin:this.crossOrigin_,offset:this.offset_.slice(),offsetOrigin:this.offsetOrigin_,opacity:this.getOpacity(),rotateWithView:this.getRotateWithView(),rotation:this.getRotation(),scale:t,width:e,height:r,size:null!==this.size_?this.size_.slice():void 0,src:this.getSrc(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()})}getAnchor(){let t=this.normalizedAnchor_;if(!t){t=this.anchor_;const e=this.getSize();if("fraction"==this.anchorXUnits_||"fraction"==this.anchorYUnits_){if(!e)return null;t=this.anchor_.slice(),"fraction"==this.anchorXUnits_&&(t[0]*=e[0]),"fraction"==this.anchorYUnits_&&(t[1]*=e[1])}if("top-left"!=this.anchorOrigin_){if(!e)return null;t===this.anchor_&&(t=this.anchor_.slice()),"top-right"!=this.anchorOrigin_&&"bottom-right"!=this.anchorOrigin_||(t[0]=-t[0]+e[0]),"bottom-left"!=this.anchorOrigin_&&"bottom-right"!=this.anchorOrigin_||(t[1]=-t[1]+e[1])}this.normalizedAnchor_=t}const e=this.getDisplacement(),r=this.getScaleArray();return[t[0]-e[0]/r[0],t[1]+e[1]/r[1]]}setAnchor(t){this.anchor_=t,this.normalizedAnchor_=null}getColor(){return this.color_}getImage(t){return this.iconImage_.getImage(t)}getPixelRatio(t){return this.iconImage_.getPixelRatio(t)}getImageSize(){return this.iconImage_.getSize()}getImageState(){return this.iconImage_.getImageState()}getHitDetectionImage(){return this.iconImage_.getHitDetectionImage()}getOrigin(){if(this.origin_)return this.origin_;let t=this.offset_;if("top-left"!=this.offsetOrigin_){const e=this.getSize(),r=this.iconImage_.getSize();if(!e||!r)return null;t=t.slice(),"top-right"!=this.offsetOrigin_&&"bottom-right"!=this.offsetOrigin_||(t[0]=r[0]-e[0]-t[0]),"bottom-left"!=this.offsetOrigin_&&"bottom-right"!=this.offsetOrigin_||(t[1]=r[1]-e[1]-t[1])}return this.origin_=t,this.origin_}getSrc(){return this.iconImage_.getSrc()}getSize(){return this.size_?this.size_:this.iconImage_.getSize()}getWidth(){const t=this.getScaleArray();return this.size_?this.size_[0]*t[0]:this.iconImage_.getImageState()==i.A.LOADED?this.iconImage_.getSize()[0]*t[0]:void 0}getHeight(){const t=this.getScaleArray();return this.size_?this.size_[1]*t[1]:this.iconImage_.getImageState()==i.A.LOADED?this.iconImage_.getSize()[1]*t[1]:void 0}setScale(t){delete this.initialOptions_,super.setScale(t)}listenImageChange(t){this.iconImage_.addEventListener(n.A.CHANGE,t)}load(){this.iconImage_.load()}unlistenImageChange(t){this.iconImage_.removeEventListener(n.A.CHANGE,t)}ready(){return this.iconImage_.ready()}}const d=h},98525:(t,e,r)=>{"use strict";r.d(e,{J:()=>d});var n=r(91086),i=r(24187),s=r(39915),o=r(41009),a=r(83085),l=r(77032),c=r(67031);let u=null;class h extends n.A{constructor(t,e,r,n,i){super(),this.hitDetectionImage_=null,this.image_=t,this.crossOrigin_=r,this.canvas_={},this.color_=i,this.imageState_=void 0===n?s.A.IDLE:n,this.size_=t&&t.width&&t.height?[t.width,t.height]:null,this.src_=e,this.tainted_,this.ready_=null}initializeImage_(){this.image_=new Image,null!==this.crossOrigin_&&(this.image_.crossOrigin=this.crossOrigin_)}isTainted_(){if(void 0===this.tainted_&&this.imageState_===s.A.LOADED){u||(u=(0,a.Y)(1,1,void 0,{willReadFrequently:!0})),u.drawImage(this.image_,0,0);try{u.getImageData(0,0,1,1),this.tainted_=!1}catch(t){u=null,this.tainted_=!0}}return!0===this.tainted_}dispatchChangeEvent_(){this.dispatchEvent(i.A.CHANGE)}handleImageError_(){this.imageState_=s.A.ERROR,this.dispatchChangeEvent_()}handleImageLoad_(){this.imageState_=s.A.LOADED,this.size_=[this.image_.width,this.image_.height],this.dispatchChangeEvent_()}getImage(t){return this.image_||this.initializeImage_(),this.replaceColor_(t),this.canvas_[t]?this.canvas_[t]:this.image_}getPixelRatio(t){return this.replaceColor_(t),this.canvas_[t]?t:1}getImageState(){return this.imageState_}getHitDetectionImage(){if(this.image_||this.initializeImage_(),!this.hitDetectionImage_)if(this.isTainted_()){const t=this.size_[0],e=this.size_[1],r=(0,a.Y)(t,e);r.fillRect(0,0,t,e),this.hitDetectionImage_=r.canvas}else this.hitDetectionImage_=this.image_;return this.hitDetectionImage_}getSize(){return this.size_}getSrc(){return this.src_}load(){if(this.imageState_===s.A.IDLE){this.image_||this.initializeImage_(),this.imageState_=s.A.LOADING;try{void 0!==this.src_&&(this.image_.src=this.src_)}catch(t){this.handleImageError_()}this.image_ instanceof HTMLImageElement&&(0,l.RA)(this.image_,this.src_).then((t=>{this.image_=t,this.handleImageLoad_()})).catch(this.handleImageError_.bind(this))}}replaceColor_(t){if(!this.color_||this.canvas_[t]||this.imageState_!==s.A.LOADED)return;const e=this.image_,r=(0,a.Y)(Math.ceil(e.width*t),Math.ceil(e.height*t)),n=r.canvas;r.scale(t,t),r.drawImage(e,0,0),r.globalCompositeOperation="multiply",r.fillStyle=(0,o.oJ)(this.color_),r.fillRect(0,0,n.width/t,n.height/t),r.globalCompositeOperation="destination-in",r.drawImage(e,0,0),this.canvas_[t]=n}ready(){return this.ready_||(this.ready_=new Promise((t=>{if(this.imageState_===s.A.LOADED||this.imageState_===s.A.ERROR)t();else{const e=()=>{this.imageState_!==s.A.LOADED&&this.imageState_!==s.A.ERROR||(this.removeEventListener(i.A.CHANGE,e),t())};this.addEventListener(i.A.CHANGE,e)}}))),this.ready_}}function d(t,e,r,n,i,s){let o=void 0===e?void 0:c.ue.get(e,r,i);return o||(o=new h(t,t&&"src"in t?t.src||void 0:e,r,n,i),c.ue.set(e,r,i,o,s)),s&&o&&!c.ue.getPattern(e,r,i)&&c.ue.set(e,r,i,o,s),o}},67031:(t,e,r)=>{"use strict";r.d(e,{ue:()=>a});var n=r(39915),i=r(41009),s=r(83085);function o(t,e,r){return e+":"+t+":"+(r?(0,i._j)(r):"null")}const a=new class{constructor(){this.cache_={},this.patternCache_={},this.cacheSize_=0,this.maxCacheSize_=32}clear(){this.cache_={},this.patternCache_={},this.cacheSize_=0}canExpireCache(){return this.cacheSize_>this.maxCacheSize_}expire(){if(this.canExpireCache()){let t=0;for(const e in this.cache_){const r=this.cache_[e];3&t++||r.hasListener()||(delete this.cache_[e],delete this.patternCache_[e],--this.cacheSize_)}}}get(t,e,r){const n=o(t,e,r);return n in this.cache_?this.cache_[n]:null}getPattern(t,e,r){const n=o(t,e,r);return n in this.patternCache_?this.patternCache_[n]:null}set(t,e,r,i,a){const l=o(t,e,r),c=l in this.cache_;this.cache_[l]=i,a&&(i.getImageState()===n.A.IDLE&&i.load(),i.getImageState()===n.A.LOADING?i.ready().then((()=>{this.patternCache_[l]=(0,s.lr)().createPattern(i.getImage(1),"repeat")})):this.patternCache_[l]=(0,s.lr)().createPattern(i.getImage(1),"repeat")),c||++this.cacheSize_}setSize(t){this.maxCacheSize_=t,this.expire()}}},51386:(t,e,r)=>{"use strict";r.d(e,{A:()=>o});var n=r(98629),i=r(53908);class s{constructor(t){this.opacity_=t.opacity,this.rotateWithView_=t.rotateWithView,this.rotation_=t.rotation,this.scale_=t.scale,this.scaleArray_=(0,i.xq)(t.scale),this.displacement_=t.displacement,this.declutterMode_=t.declutterMode}clone(){const t=this.getScale();return new s({opacity:this.getOpacity(),scale:Array.isArray(t)?t.slice():t,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()})}getOpacity(){return this.opacity_}getRotateWithView(){return this.rotateWithView_}getRotation(){return this.rotation_}getScale(){return this.scale_}getScaleArray(){return this.scaleArray_}getDisplacement(){return this.displacement_}getDeclutterMode(){return this.declutterMode_}getAnchor(){return(0,n.b0)()}getImage(t){return(0,n.b0)()}getHitDetectionImage(){return(0,n.b0)()}getPixelRatio(t){return 1}getImageState(){return(0,n.b0)()}getImageSize(){return(0,n.b0)()}getOrigin(){return(0,n.b0)()}getSize(){return(0,n.b0)()}setDisplacement(t){this.displacement_=t}setOpacity(t){this.opacity_=t}setRotateWithView(t){this.rotateWithView_=t}setRotation(t){this.rotation_=t}setScale(t){this.scale_=t,this.scaleArray_=(0,i.xq)(t)}listenImageChange(t){(0,n.b0)()}load(){(0,n.b0)()}unlistenImageChange(t){(0,n.b0)()}ready(){return Promise.resolve()}}const o=s},80996:(t,e,r)=>{"use strict";function n(t,e,r,n){return void 0!==n?(n[0]=t,n[1]=e,n[2]=r,n):[t,e,r]}function i(t,e,r){return t+"/"+e+"/"+r}function s(t){return i(t[0],t[1],t[2])}function o(t){return a(t[0],t[1],t[2])}function a(t,e,r){return(e<<t)+r}function l(t,e){const r=t[0],n=t[1],i=t[2];if(e.getMinZoom()>r||r>e.getMaxZoom())return!1;const s=e.getFullTileRange(r);return!s||s.containsXY(n,i)}r.d(e,{N:()=>n,N5:()=>l,_T:()=>a,dp:()=>i,i7:()=>s,tW:()=>o})},32077:(t,e,r)=>{"use strict";r.d(e,{EN:()=>u,Li:()=>c,kZ:()=>d,pr:()=>l});var n=r(17668),i=r(75961),s=r(12940),o=r(44509),a=r(53908);function l(t){let e=t.getDefaultTileGrid();return e||(e=function(t){return function(t,e,r,i){i=void 0!==i?i:"top-left";const s=h(t,e,r);return new n.A({extent:t,origin:(0,o.qF)(t,i),resolutions:s,tileSize:r})}(d(t),void 0,void 0,void 0)}(t),t.setDefaultTileGrid(e)),e}function c(t,e,r){const n=e[0],i=t.getTileCoordCenter(e),s=d(r);if(!(0,o.Ym)(s,i)){const e=(0,o.RG)(s),r=Math.ceil((s[0]-i[0])/e);return i[0]+=e*r,t.getTileCoordForCoordAndZ(i,n)}return e}function u(t){const e=t||{},r=e.extent||(0,s.Jt)("EPSG:3857").getExtent(),i={extent:r,minZoom:e.minZoom,tileSize:e.tileSize,resolutions:h(r,e.maxZoom,e.tileSize,e.maxResolution)};return new n.A(i)}function h(t,e,r,n){e=void 0!==e?e:i.L,r=(0,a.xq)(void 0!==r?r:i.R);const s=(0,o.Oq)(t),l=(0,o.RG)(t);n=n>0?n:Math.max(l/r[0],s/r[1]);const c=e+1,u=new Array(c);for(let t=0;t<c;++t)u[t]=n/Math.pow(2,t);return u}function d(t){let e=(t=(0,s.Jt)(t)).getExtent();if(!e){const r=180*s.Ig.degrees/t.getMetersPerUnit();e=(0,o.N)(-r,-r,r,r)}return e}},17668:(t,e,r)=>{"use strict";r.d(e,{A:()=>f});var n=r(64444),i=r(75961),s=r(30878),o=r(72475),a=r(44509),l=r(80996),c=r(78096),u=r(30444),h=r(53908);const d=[0,0,0],f=class{constructor(t){let e;if(this.minZoom=void 0!==t.minZoom?t.minZoom:0,this.resolutions_=t.resolutions,(0,s.v)((0,u.WC)(this.resolutions_,((t,e)=>e-t),!0),"`resolutions` must be sorted in descending order"),!t.origins)for(let t=0,r=this.resolutions_.length-1;t<r;++t)if(e){if(this.resolutions_[t]/this.resolutions_[t+1]!==e){e=void 0;break}}else e=this.resolutions_[t]/this.resolutions_[t+1];this.zoomFactor_=e,this.maxZoom=this.resolutions_.length-1,this.origin_=void 0!==t.origin?t.origin:null,this.origins_=null,void 0!==t.origins&&(this.origins_=t.origins,(0,s.v)(this.origins_.length==this.resolutions_.length,"Number of `origins` and `resolutions` must be equal"));const r=t.extent;void 0===r||this.origin_||this.origins_||(this.origin_=(0,a.Py)(r)),(0,s.v)(!this.origin_&&this.origins_||this.origin_&&!this.origins_,"Either `origin` or `origins` must be configured, never both"),this.tileSizes_=null,void 0!==t.tileSizes&&(this.tileSizes_=t.tileSizes,(0,s.v)(this.tileSizes_.length==this.resolutions_.length,"Number of `tileSizes` and `resolutions` must be equal")),this.tileSize_=void 0!==t.tileSize?t.tileSize:this.tileSizes_?null:i.R,(0,s.v)(!this.tileSize_&&this.tileSizes_||this.tileSize_&&!this.tileSizes_,"Either `tileSize` or `tileSizes` must be configured, never both"),this.extent_=void 0!==r?r:null,this.fullTileRanges_=null,this.tmpSize_=[0,0],this.tmpExtent_=[0,0,0,0],void 0!==t.sizes?this.fullTileRanges_=t.sizes.map(((t,e)=>{const i=new n.A(Math.min(0,t[0]),Math.max(t[0]-1,-1),Math.min(0,t[1]),Math.max(t[1]-1,-1));if(r){const t=this.getTileRangeForExtentAndZ(r,e);i.minX=Math.max(t.minX,i.minX),i.maxX=Math.min(t.maxX,i.maxX),i.minY=Math.max(t.minY,i.minY),i.maxY=Math.min(t.maxY,i.maxY)}return i})):r&&this.calculateTileRanges_(r)}forEachTileCoord(t,e,r){const n=this.getTileRangeForExtentAndZ(t,e);for(let t=n.minX,i=n.maxX;t<=i;++t)for(let i=n.minY,s=n.maxY;i<=s;++i)r([e,t,i])}forEachTileCoordParentTileRange(t,e,r,i){let s,o,a,l=null,c=t[0]-1;for(2===this.zoomFactor_?(o=t[1],a=t[2]):l=this.getTileCoordExtent(t,i);c>=this.minZoom;){if(void 0!==o&&void 0!==a?(o=Math.floor(o/2),a=Math.floor(a/2),s=(0,n.N)(o,o,a,a,r)):s=this.getTileRangeForExtentAndZ(l,c,r),e(c,s))return!0;--c}return!1}getExtent(){return this.extent_}getMaxZoom(){return this.maxZoom}getMinZoom(){return this.minZoom}getOrigin(t){return this.origin_?this.origin_:this.origins_[t]}getResolution(t){return this.resolutions_[t]}getResolutions(){return this.resolutions_}getTileCoordChildTileRange(t,e,r){if(t[0]<this.maxZoom){if(2===this.zoomFactor_){const r=2*t[1],i=2*t[2];return(0,n.N)(r,r+1,i,i+1,e)}const i=this.getTileCoordExtent(t,r||this.tmpExtent_);return this.getTileRangeForExtentAndZ(i,t[0]+1,e)}return null}getTileRangeForTileCoordAndZ(t,e,r){if(e>this.maxZoom||e<this.minZoom)return null;const i=t[0],s=t[1],o=t[2];if(e===i)return(0,n.N)(s,o,s,o,r);if(this.zoomFactor_){const t=Math.pow(this.zoomFactor_,e-i),a=Math.floor(s*t),l=Math.floor(o*t);if(e<i)return(0,n.N)(a,a,l,l,r);const c=Math.floor(t*(s+1))-1,u=Math.floor(t*(o+1))-1;return(0,n.N)(a,c,l,u,r)}const a=this.getTileCoordExtent(t,this.tmpExtent_);return this.getTileRangeForExtentAndZ(a,e,r)}getTileRangeForExtentAndZ(t,e,r){this.getTileCoordForXYAndZ_(t[0],t[3],e,!1,d);const i=d[1],s=d[2];this.getTileCoordForXYAndZ_(t[2],t[1],e,!0,d);const o=d[1],a=d[2];return(0,n.N)(i,o,s,a,r)}getTileCoordCenter(t){const e=this.getOrigin(t[0]),r=this.getResolution(t[0]),n=(0,h.xq)(this.getTileSize(t[0]),this.tmpSize_);return[e[0]+(t[1]+.5)*n[0]*r,e[1]-(t[2]+.5)*n[1]*r]}getTileCoordExtent(t,e){const r=this.getOrigin(t[0]),n=this.getResolution(t[0]),i=(0,h.xq)(this.getTileSize(t[0]),this.tmpSize_),s=r[0]+t[1]*i[0]*n,o=r[1]-(t[2]+1)*i[1]*n,l=s+i[0]*n,c=o+i[1]*n;return(0,a.N)(s,o,l,c,e)}getTileCoordForCoordAndResolution(t,e,r){return this.getTileCoordForXYAndResolution_(t[0],t[1],e,!1,r)}getTileCoordForXYAndResolution_(t,e,r,n,i){const s=this.getZForResolution(r),a=r/this.getResolution(s),c=this.getOrigin(s),u=(0,h.xq)(this.getTileSize(s),this.tmpSize_);let d=a*(t-c[0])/r/u[0],f=a*(c[1]-e)/r/u[1];return n?(d=(0,o.mk)(d,5)-1,f=(0,o.mk)(f,5)-1):(d=(0,o.RI)(d,5),f=(0,o.RI)(f,5)),(0,l.N)(s,d,f,i)}getTileCoordForXYAndZ_(t,e,r,n,i){const s=this.getOrigin(r),a=this.getResolution(r),c=(0,h.xq)(this.getTileSize(r),this.tmpSize_);let u=(t-s[0])/a/c[0],d=(s[1]-e)/a/c[1];return n?(u=(0,o.mk)(u,5)-1,d=(0,o.mk)(d,5)-1):(u=(0,o.RI)(u,5),d=(0,o.RI)(d,5)),(0,l.N)(r,u,d,i)}getTileCoordForCoordAndZ(t,e,r){return this.getTileCoordForXYAndZ_(t[0],t[1],e,!1,r)}getTileCoordResolution(t){return this.resolutions_[t[0]]}getTileSize(t){return this.tileSize_?this.tileSize_:this.tileSizes_[t]}getFullTileRange(t){return this.fullTileRanges_?this.fullTileRanges_[t]:this.extent_?this.getTileRangeForExtentAndZ(this.extent_,t):null}getZForResolution(t,e){const r=(0,u.FT)(this.resolutions_,t,e||0);return(0,o.qE)(r,this.minZoom,this.maxZoom)}tileCoordIntersectsViewport(t,e){return(0,c.sj)(e,0,e.length,2,this.getTileCoordExtent(t))}calculateTileRanges_(t){const e=this.resolutions_.length,r=new Array(e);for(let n=this.minZoom;n<e;++n)r[n]=this.getTileRangeForExtentAndZ(t,n);this.fullTileRanges_=r}}},75961:(t,e,r)=>{"use strict";r.d(e,{L:()=>n,R:()=>i});const n=42,i=256},37377:(t,e,r)=>{"use strict";r.d(e,{Bb:()=>u,T9:()=>m,Tl:()=>f,Zz:()=>p,cL:()=>o,dI:()=>y,e$:()=>h,hs:()=>d,k3:()=>c,lw:()=>a,vt:()=>s});var n=r(30878);const i=new Array(6);function s(){return[1,0,0,1,0,0]}function o(t){return l(t,1,0,0,1,0,0)}function a(t,e){const r=t[0],n=t[1],i=t[2],s=t[3],o=t[4],a=t[5],l=e[0],c=e[1],u=e[2],h=e[3],d=e[4],f=e[5];return t[0]=r*l+i*c,t[1]=n*l+s*c,t[2]=r*u+i*h,t[3]=n*u+s*h,t[4]=r*d+i*f+o,t[5]=n*d+s*f+a,t}function l(t,e,r,n,i,s,o){return t[0]=e,t[1]=r,t[2]=n,t[3]=i,t[4]=s,t[5]=o,t}function c(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t}function u(t,e){const r=e[0],n=e[1];return e[0]=t[0]*r+t[2]*n+t[4],e[1]=t[1]*r+t[3]*n+t[5],e}function h(t,e){const r=Math.cos(e),n=Math.sin(e);return a(t,l(i,r,n,-n,r,0,0))}function d(t,e,r){return a(t,l(i,e,0,0,r,0,0))}function f(t,e,r){return a(t,l(i,1,0,0,1,e,r))}function p(t,e,r,n,i,s,o,a){const l=Math.sin(s),c=Math.cos(s);return t[0]=n*c,t[1]=i*l,t[2]=-n*l,t[3]=i*c,t[4]=o*n*c-a*n*l+e,t[5]=o*i*l+a*i*c+r,t}function m(t,e){const r=(i=e)[0]*i[3]-i[1]*i[2];var i;(0,n.v)(0!==r,"Transformation matrix cannot be inverted");const s=e[0],o=e[1],a=e[2],l=e[3],c=e[4],u=e[5];return t[0]=l/r,t[1]=-o/r,t[2]=-a/r,t[3]=s/r,t[4]=(a*u-l*c)/r,t[5]=-(s*u-o*c)/r,t}const g=[1e6,1e6,1e6,1e6,2,2];function y(t){return"matrix("+t.map(((t,e)=>Math.round(t*g[e])/g[e])).join(", ")+")"}},44095:(t,e,r)=>{"use strict";r.d(e,{M:()=>c,Uu:()=>h,de:()=>u});var n=r(80996),i=r(72475);const s=/\{z\}/g,o=/\{x\}/g,a=/\{y\}/g,l=/\{-y\}/g;function c(t,e,r,n,i){return t.replace(s,e.toString()).replace(o,r.toString()).replace(a,n.toString()).replace(l,(function(){if(void 0===i)throw new Error("If the URL template has a {-y} placeholder, the grid extent must be known");return(i-n).toString()}))}function u(t,e,r,s){const o=(0,n._T)(e,r,s);return t[(0,i.xP)(o,t.length)]}function h(t){const e=[];let r=/\{([a-z])-([a-z])\}/.exec(t);if(r){const n=r[1].charCodeAt(0),i=r[2].charCodeAt(0);let s;for(s=n;s<=i;++s)e.push(t.replace(r[0],String.fromCharCode(s)));return e}if(r=/\{(\d+)-(\d+)\}/.exec(t),r){const n=parseInt(r[2],10);for(let i=parseInt(r[1],10);i<=n;i++)e.push(t.replace(r[0],i.toString()));return e}return e.push(t),e}},98629:(t,e,r)=>{"use strict";function n(){throw new Error("Unimplemented abstract method.")}r.d(e,{b0:()=>n,v6:()=>s});let i=0;function s(t){return t.ol_uid||(t.ol_uid=String(++i))}},38286:(t,e,r)=>{"use strict";r.d(e,{A:()=>o});const n=4294967296,i=1/n,s="undefined"==typeof TextDecoder?null:new TextDecoder("utf-8");class o{constructor(t=new Uint8Array(16)){this.buf=ArrayBuffer.isView(t)?t:new Uint8Array(t),this.dataView=new DataView(this.buf.buffer),this.pos=0,this.type=0,this.length=this.buf.length}readFields(t,e,r=this.length){for(;this.pos<r;){const r=this.readVarint(),n=r>>3,i=this.pos;this.type=7&r,t(n,e,this),this.pos===i&&this.skip(r)}return e}readMessage(t,e){return this.readFields(t,e,this.readVarint()+this.pos)}readFixed32(){const t=this.dataView.getUint32(this.pos,!0);return this.pos+=4,t}readSFixed32(){const t=this.dataView.getInt32(this.pos,!0);return this.pos+=4,t}readFixed64(){const t=this.dataView.getUint32(this.pos,!0)+this.dataView.getUint32(this.pos+4,!0)*n;return this.pos+=8,t}readSFixed64(){const t=this.dataView.getUint32(this.pos,!0)+this.dataView.getInt32(this.pos+4,!0)*n;return this.pos+=8,t}readFloat(){const t=this.dataView.getFloat32(this.pos,!0);return this.pos+=4,t}readDouble(){const t=this.dataView.getFloat64(this.pos,!0);return this.pos+=8,t}readVarint(t){const e=this.buf;let r,n;return n=e[this.pos++],r=127&n,n<128?r:(n=e[this.pos++],r|=(127&n)<<7,n<128?r:(n=e[this.pos++],r|=(127&n)<<14,n<128?r:(n=e[this.pos++],r|=(127&n)<<21,n<128?r:(n=e[this.pos],r|=(15&n)<<28,function(t,e,r){const n=r.buf;let i,s;if(s=n[r.pos++],i=(112&s)>>4,s<128)return a(t,i,e);if(s=n[r.pos++],i|=(127&s)<<3,s<128)return a(t,i,e);if(s=n[r.pos++],i|=(127&s)<<10,s<128)return a(t,i,e);if(s=n[r.pos++],i|=(127&s)<<17,s<128)return a(t,i,e);if(s=n[r.pos++],i|=(127&s)<<24,s<128)return a(t,i,e);if(s=n[r.pos++],i|=(1&s)<<31,s<128)return a(t,i,e);throw new Error("Expected varint not more than 10 bytes")}(r,t,this)))))}readVarint64(){return this.readVarint(!0)}readSVarint(){const t=this.readVarint();return t%2==1?(t+1)/-2:t/2}readBoolean(){return Boolean(this.readVarint())}readString(){const t=this.readVarint()+this.pos,e=this.pos;return this.pos=t,t-e>=12&&s?s.decode(this.buf.subarray(e,t)):function(t,e,r){let n="",i=e;for(;i<r;){const e=t[i];let s,o,a,l=null,c=e>239?4:e>223?3:e>191?2:1;if(i+c>r)break;1===c?e<128&&(l=e):2===c?(s=t[i+1],128==(192&s)&&(l=(31&e)<<6|63&s,l<=127&&(l=null))):3===c?(s=t[i+1],o=t[i+2],128==(192&s)&&128==(192&o)&&(l=(15&e)<<12|(63&s)<<6|63&o,(l<=2047||l>=55296&&l<=57343)&&(l=null))):4===c&&(s=t[i+1],o=t[i+2],a=t[i+3],128==(192&s)&&128==(192&o)&&128==(192&a)&&(l=(15&e)<<18|(63&s)<<12|(63&o)<<6|63&a,(l<=65535||l>=1114112)&&(l=null))),null===l?(l=65533,c=1):l>65535&&(l-=65536,n+=String.fromCharCode(l>>>10&1023|55296),l=56320|1023&l),n+=String.fromCharCode(l),i+=c}return n}(this.buf,e,t)}readBytes(){const t=this.readVarint()+this.pos,e=this.buf.subarray(this.pos,t);return this.pos=t,e}readPackedVarint(t=[],e){const r=this.readPackedEnd();for(;this.pos<r;)t.push(this.readVarint(e));return t}readPackedSVarint(t=[]){const e=this.readPackedEnd();for(;this.pos<e;)t.push(this.readSVarint());return t}readPackedBoolean(t=[]){const e=this.readPackedEnd();for(;this.pos<e;)t.push(this.readBoolean());return t}readPackedFloat(t=[]){const e=this.readPackedEnd();for(;this.pos<e;)t.push(this.readFloat());return t}readPackedDouble(t=[]){const e=this.readPackedEnd();for(;this.pos<e;)t.push(this.readDouble());return t}readPackedFixed32(t=[]){const e=this.readPackedEnd();for(;this.pos<e;)t.push(this.readFixed32());return t}readPackedSFixed32(t=[]){const e=this.readPackedEnd();for(;this.pos<e;)t.push(this.readSFixed32());return t}readPackedFixed64(t=[]){const e=this.readPackedEnd();for(;this.pos<e;)t.push(this.readFixed64());return t}readPackedSFixed64(t=[]){const e=this.readPackedEnd();for(;this.pos<e;)t.push(this.readSFixed64());return t}readPackedEnd(){return 2===this.type?this.readVarint()+this.pos:this.pos+1}skip(t){const e=7&t;if(0===e)for(;this.buf[this.pos++]>127;);else if(2===e)this.pos=this.readVarint()+this.pos;else if(5===e)this.pos+=4;else{if(1!==e)throw new Error(`Unimplemented type: ${e}`);this.pos+=8}}writeTag(t,e){this.writeVarint(t<<3|e)}realloc(t){let e=this.length||16;for(;e<this.pos+t;)e*=2;if(e!==this.length){const t=new Uint8Array(e);t.set(this.buf),this.buf=t,this.dataView=new DataView(t.buffer),this.length=e}}finish(){return this.length=this.pos,this.pos=0,this.buf.subarray(0,this.length)}writeFixed32(t){this.realloc(4),this.dataView.setInt32(this.pos,t,!0),this.pos+=4}writeSFixed32(t){this.realloc(4),this.dataView.setInt32(this.pos,t,!0),this.pos+=4}writeFixed64(t){this.realloc(8),this.dataView.setInt32(this.pos,-1&t,!0),this.dataView.setInt32(this.pos+4,Math.floor(t*i),!0),this.pos+=8}writeSFixed64(t){this.realloc(8),this.dataView.setInt32(this.pos,-1&t,!0),this.dataView.setInt32(this.pos+4,Math.floor(t*i),!0),this.pos+=8}writeVarint(t){(t=+t||0)>268435455||t<0?function(t,e){let r,n;if(t>=0?(r=t%4294967296|0,n=t/4294967296|0):(r=~(-t%4294967296),n=~(-t/4294967296),4294967295^r?r=r+1|0:(r=0,n=n+1|0)),t>=0x10000000000000000||t<-0x10000000000000000)throw new Error("Given varint doesn't fit into 10 bytes");e.realloc(10),function(t,e,r){r.buf[r.pos++]=127&t|128,t>>>=7,r.buf[r.pos++]=127&t|128,t>>>=7,r.buf[r.pos++]=127&t|128,t>>>=7,r.buf[r.pos++]=127&t|128,t>>>=7,r.buf[r.pos]=127&t}(r,0,e),function(t,e){const r=(7&t)<<4;e.buf[e.pos++]|=r|((t>>>=3)?128:0),t&&(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),t&&(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),t&&(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),t&&(e.buf[e.pos++]=127&t|((t>>>=7)?128:0),t&&(e.buf[e.pos++]=127&t)))))}(n,e)}(t,this):(this.realloc(4),this.buf[this.pos++]=127&t|(t>127?128:0),t<=127||(this.buf[this.pos++]=127&(t>>>=7)|(t>127?128:0),t<=127||(this.buf[this.pos++]=127&(t>>>=7)|(t>127?128:0),t<=127||(this.buf[this.pos++]=t>>>7&127))))}writeSVarint(t){this.writeVarint(t<0?2*-t-1:2*t)}writeBoolean(t){this.writeVarint(+t)}writeString(t){t=String(t),this.realloc(4*t.length),this.pos++;const e=this.pos;this.pos=function(t,e,r){for(let n,i,s=0;s<e.length;s++){if(n=e.charCodeAt(s),n>55295&&n<57344){if(!i){n>56319||s+1===e.length?(t[r++]=239,t[r++]=191,t[r++]=189):i=n;continue}if(n<56320){t[r++]=239,t[r++]=191,t[r++]=189,i=n;continue}n=i-55296<<10|n-56320|65536,i=null}else i&&(t[r++]=239,t[r++]=191,t[r++]=189,i=null);n<128?t[r++]=n:(n<2048?t[r++]=n>>6|192:(n<65536?t[r++]=n>>12|224:(t[r++]=n>>18|240,t[r++]=n>>12&63|128),t[r++]=n>>6&63|128),t[r++]=63&n|128)}return r}(this.buf,t,this.pos);const r=this.pos-e;r>=128&&l(e,r,this),this.pos=e-1,this.writeVarint(r),this.pos+=r}writeFloat(t){this.realloc(4),this.dataView.setFloat32(this.pos,t,!0),this.pos+=4}writeDouble(t){this.realloc(8),this.dataView.setFloat64(this.pos,t,!0),this.pos+=8}writeBytes(t){const e=t.length;this.writeVarint(e),this.realloc(e);for(let r=0;r<e;r++)this.buf[this.pos++]=t[r]}writeRawMessage(t,e){this.pos++;const r=this.pos;t(e,this);const n=this.pos-r;n>=128&&l(r,n,this),this.pos=r-1,this.writeVarint(n),this.pos+=n}writeMessage(t,e,r){this.writeTag(t,2),this.writeRawMessage(e,r)}writePackedVarint(t,e){e.length&&this.writeMessage(t,c,e)}writePackedSVarint(t,e){e.length&&this.writeMessage(t,u,e)}writePackedBoolean(t,e){e.length&&this.writeMessage(t,f,e)}writePackedFloat(t,e){e.length&&this.writeMessage(t,h,e)}writePackedDouble(t,e){e.length&&this.writeMessage(t,d,e)}writePackedFixed32(t,e){e.length&&this.writeMessage(t,p,e)}writePackedSFixed32(t,e){e.length&&this.writeMessage(t,m,e)}writePackedFixed64(t,e){e.length&&this.writeMessage(t,g,e)}writePackedSFixed64(t,e){e.length&&this.writeMessage(t,y,e)}writeBytesField(t,e){this.writeTag(t,2),this.writeBytes(e)}writeFixed32Field(t,e){this.writeTag(t,5),this.writeFixed32(e)}writeSFixed32Field(t,e){this.writeTag(t,5),this.writeSFixed32(e)}writeFixed64Field(t,e){this.writeTag(t,1),this.writeFixed64(e)}writeSFixed64Field(t,e){this.writeTag(t,1),this.writeSFixed64(e)}writeVarintField(t,e){this.writeTag(t,0),this.writeVarint(e)}writeSVarintField(t,e){this.writeTag(t,0),this.writeSVarint(e)}writeStringField(t,e){this.writeTag(t,2),this.writeString(e)}writeFloatField(t,e){this.writeTag(t,5),this.writeFloat(e)}writeDoubleField(t,e){this.writeTag(t,1),this.writeDouble(e)}writeBooleanField(t,e){this.writeVarintField(t,+e)}}function a(t,e,r){return r?4294967296*e+(t>>>0):4294967296*(e>>>0)+(t>>>0)}function l(t,e,r){const n=e<=16383?1:e<=2097151?2:e<=268435455?3:Math.floor(Math.log(e)/(7*Math.LN2));r.realloc(n);for(let e=r.pos-1;e>=t;e--)r.buf[e+n]=r.buf[e]}function c(t,e){for(let r=0;r<t.length;r++)e.writeVarint(t[r])}function u(t,e){for(let r=0;r<t.length;r++)e.writeSVarint(t[r])}function h(t,e){for(let r=0;r<t.length;r++)e.writeFloat(t[r])}function d(t,e){for(let r=0;r<t.length;r++)e.writeDouble(t[r])}function f(t,e){for(let r=0;r<t.length;r++)e.writeBoolean(t[r])}function p(t,e){for(let r=0;r<t.length;r++)e.writeFixed32(t[r])}function m(t,e){for(let r=0;r<t.length;r++)e.writeSFixed32(t[r])}function g(t,e){for(let r=0;r<t.length;r++)e.writeFixed64(t[r])}function y(t,e){for(let r=0;r<t.length;r++)e.writeSFixed64(t[r])}},39907:t=>{var e,r,n=t.exports={};function i(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function o(t){if(e===setTimeout)return setTimeout(t,0);if((e===i||!e)&&setTimeout)return e=setTimeout,setTimeout(t,0);try{return e(t,0)}catch(r){try{return e.call(null,t,0)}catch(r){return e.call(this,t,0)}}}!function(){try{e="function"==typeof setTimeout?setTimeout:i}catch(t){e=i}try{r="function"==typeof clearTimeout?clearTimeout:s}catch(t){r=s}}();var a,l=[],c=!1,u=-1;function h(){c&&a&&(c=!1,a.length?l=a.concat(l):u=-1,l.length&&d())}function d(){if(!c){var t=o(h);c=!0;for(var e=l.length;e;){for(a=l,l=[];++u<e;)a&&a[u].run();u=-1,e=l.length}a=null,c=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===s||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{return r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function f(t,e){this.fun=t,this.array=e}function p(){}n.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];l.push(new f(t,e)),1!==l.length||c||o(d)},f.prototype.run=function(){this.fun.apply(null,this.array)},n.title="browser",n.browser=!0,n.env={},n.argv=[],n.version="",n.versions={},n.on=p,n.addListener=p,n.once=p,n.off=p,n.removeListener=p,n.removeAllListeners=p,n.emit=p,n.prependListener=p,n.prependOnceListener=p,n.listeners=function(t){return[]},n.binding=function(t){throw new Error("process.binding is not supported")},n.cwd=function(){return"/"},n.chdir=function(t){throw new Error("process.chdir is not supported")},n.umask=function(){return 0}},36999:(t,e,r)=>{"use strict";var n=r(36848);function i(){}function s(){}s.resetWarningCache=i,t.exports=function(){function t(t,e,r,i,s,o){if(o!==n){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function e(){return t}t.isRequired=t;var r={array:t,bigint:t,bool:t,func:t,number:t,object:t,string:t,symbol:t,any:t,arrayOf:e,element:t,elementType:t,instanceOf:e,node:t,objectOf:e,oneOf:e,oneOfType:e,shape:e,exact:e,checkPropTypes:s,resetWarningCache:i};return r.PropTypes=r,r}},39067:(t,e,r)=>{t.exports=r(36999)()},36848:t=>{"use strict";t.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},44663:(t,e,r)=>{"use strict";function n(t,e,r=0,o=t.length-1,a=s){for(;o>r;){if(o-r>600){const i=o-r+1,s=e-r+1,l=Math.log(i),c=.5*Math.exp(2*l/3),u=.5*Math.sqrt(l*c*(i-c)/i)*(s-i/2<0?-1:1);n(t,e,Math.max(r,Math.floor(e-s*c/i+u)),Math.min(o,Math.floor(e+(i-s)*c/i+u)),a)}const s=t[e];let l=r,c=o;for(i(t,r,e),a(t[o],s)>0&&i(t,r,o);l<c;){for(i(t,l,c),l++,c--;a(t[l],s)<0;)l++;for(;a(t[c],s)>0;)c--}0===a(t[r],s)?i(t,r,c):(c++,i(t,c,o)),c<=e&&(r=c+1),e<=c&&(o=c-1)}}function i(t,e,r){const n=t[e];t[e]=t[r],t[r]=n}function s(t,e){return t<e?-1:t>e?1:0}r.d(e,{A:()=>o});class o{constructor(t=9){this._maxEntries=Math.max(4,t),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),this.clear()}all(){return this._all(this.data,[])}search(t){let e=this.data;const r=[];if(!y(t,e))return r;const n=this.toBBox,i=[];for(;e;){for(let s=0;s<e.children.length;s++){const o=e.children[s],a=e.leaf?n(o):o;y(t,a)&&(e.leaf?r.push(o):g(t,a)?this._all(o,r):i.push(o))}e=i.pop()}return r}collides(t){let e=this.data;if(!y(t,e))return!1;const r=[];for(;e;){for(let n=0;n<e.children.length;n++){const i=e.children[n],s=e.leaf?this.toBBox(i):i;if(y(t,s)){if(e.leaf||g(t,s))return!0;r.push(i)}}e=r.pop()}return!1}load(t){if(!t||!t.length)return this;if(t.length<this._minEntries){for(let e=0;e<t.length;e++)this.insert(t[e]);return this}let e=this._build(t.slice(),0,t.length-1,0);if(this.data.children.length)if(this.data.height===e.height)this._splitRoot(this.data,e);else{if(this.data.height<e.height){const t=this.data;this.data=e,e=t}this._insert(e,this.data.height-e.height-1,!0)}else this.data=e;return this}insert(t){return t&&this._insert(t,this.data.height-1),this}clear(){return this.data=v([]),this}remove(t,e){if(!t)return this;let r=this.data;const n=this.toBBox(t),i=[],s=[];let o,l,c;for(;r||i.length;){if(r||(r=i.pop(),l=i[i.length-1],o=s.pop(),c=!0),r.leaf){const n=a(t,r.children,e);if(-1!==n)return r.children.splice(n,1),i.push(r),this._condense(i),this}c||r.leaf||!g(r,n)?l?(o++,r=l.children[o],c=!1):r=null:(i.push(r),s.push(o),o=0,l=r,r=r.children[0])}return this}toBBox(t){return t}compareMinX(t,e){return t.minX-e.minX}compareMinY(t,e){return t.minY-e.minY}toJSON(){return this.data}fromJSON(t){return this.data=t,this}_all(t,e){const r=[];for(;t;)t.leaf?e.push(...t.children):r.push(...t.children),t=r.pop();return e}_build(t,e,r,n){const i=r-e+1;let s,o=this._maxEntries;if(i<=o)return s=v(t.slice(e,r+1)),l(s,this.toBBox),s;n||(n=Math.ceil(Math.log(i)/Math.log(o)),o=Math.ceil(i/Math.pow(o,n-1))),s=v([]),s.leaf=!1,s.height=n;const a=Math.ceil(i/o),c=a*Math.ceil(Math.sqrt(o));_(t,e,r,c,this.compareMinX);for(let i=e;i<=r;i+=c){const e=Math.min(i+c-1,r);_(t,i,e,a,this.compareMinY);for(let r=i;r<=e;r+=a){const i=Math.min(r+a-1,e);s.children.push(this._build(t,r,i,n-1))}}return l(s,this.toBBox),s}_chooseSubtree(t,e,r,n){for(;n.push(e),!e.leaf&&n.length-1!==r;){let r,n=1/0,o=1/0;for(let a=0;a<e.children.length;a++){const l=e.children[a],c=f(l),u=(i=t,s=l,(Math.max(s.maxX,i.maxX)-Math.min(s.minX,i.minX))*(Math.max(s.maxY,i.maxY)-Math.min(s.minY,i.minY))-c);u<o?(o=u,n=c<n?c:n,r=l):u===o&&c<n&&(n=c,r=l)}e=r||e.children[0]}var i,s;return e}_insert(t,e,r){const n=r?t:this.toBBox(t),i=[],s=this._chooseSubtree(n,this.data,e,i);for(s.children.push(t),u(s,n);e>=0&&i[e].children.length>this._maxEntries;)this._split(i,e),e--;this._adjustParentBBoxes(n,i,e)}_split(t,e){const r=t[e],n=r.children.length,i=this._minEntries;this._chooseSplitAxis(r,i,n);const s=this._chooseSplitIndex(r,i,n),o=v(r.children.splice(s,r.children.length-s));o.height=r.height,o.leaf=r.leaf,l(r,this.toBBox),l(o,this.toBBox),e?t[e-1].children.push(o):this._splitRoot(r,o)}_splitRoot(t,e){this.data=v([t,e]),this.data.height=t.height+1,this.data.leaf=!1,l(this.data,this.toBBox)}_chooseSplitIndex(t,e,r){let n,i=1/0,s=1/0;for(let o=e;o<=r-e;o++){const e=c(t,0,o,this.toBBox),a=c(t,o,r,this.toBBox),l=m(e,a),u=f(e)+f(a);l<i?(i=l,n=o,s=u<s?u:s):l===i&&u<s&&(s=u,n=o)}return n||r-e}_chooseSplitAxis(t,e,r){const n=t.leaf?this.compareMinX:h,i=t.leaf?this.compareMinY:d;this._allDistMargin(t,e,r,n)<this._allDistMargin(t,e,r,i)&&t.children.sort(n)}_allDistMargin(t,e,r,n){t.children.sort(n);const i=this.toBBox,s=c(t,0,e,i),o=c(t,r-e,r,i);let a=p(s)+p(o);for(let n=e;n<r-e;n++){const e=t.children[n];u(s,t.leaf?i(e):e),a+=p(s)}for(let n=r-e-1;n>=e;n--){const e=t.children[n];u(o,t.leaf?i(e):e),a+=p(o)}return a}_adjustParentBBoxes(t,e,r){for(let n=r;n>=0;n--)u(e[n],t)}_condense(t){for(let e,r=t.length-1;r>=0;r--)0===t[r].children.length?r>0?(e=t[r-1].children,e.splice(e.indexOf(t[r]),1)):this.clear():l(t[r],this.toBBox)}}function a(t,e,r){if(!r)return e.indexOf(t);for(let n=0;n<e.length;n++)if(r(t,e[n]))return n;return-1}function l(t,e){c(t,0,t.children.length,e,t)}function c(t,e,r,n,i){i||(i=v(null)),i.minX=1/0,i.minY=1/0,i.maxX=-1/0,i.maxY=-1/0;for(let s=e;s<r;s++){const e=t.children[s];u(i,t.leaf?n(e):e)}return i}function u(t,e){return t.minX=Math.min(t.minX,e.minX),t.minY=Math.min(t.minY,e.minY),t.maxX=Math.max(t.maxX,e.maxX),t.maxY=Math.max(t.maxY,e.maxY),t}function h(t,e){return t.minX-e.minX}function d(t,e){return t.minY-e.minY}function f(t){return(t.maxX-t.minX)*(t.maxY-t.minY)}function p(t){return t.maxX-t.minX+(t.maxY-t.minY)}function m(t,e){const r=Math.max(t.minX,e.minX),n=Math.max(t.minY,e.minY),i=Math.min(t.maxX,e.maxX),s=Math.min(t.maxY,e.maxY);return Math.max(0,i-r)*Math.max(0,s-n)}function g(t,e){return t.minX<=e.minX&&t.minY<=e.minY&&e.maxX<=t.maxX&&e.maxY<=t.maxY}function y(t,e){return e.minX<=t.maxX&&e.minY<=t.maxY&&e.maxX>=t.minX&&e.maxY>=t.minY}function v(t){return{children:t,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function _(t,e,r,i,s){const o=[e,r];for(;o.length;){if((r=o.pop())-(e=o.pop())<=i)continue;const a=e+Math.ceil((r-e)/i/2)*i;n(t,a,e,r,s),o.push(e,a,a,r)}}},90320:(t,e)=>{"use strict";var r="function"==typeof Symbol&&Symbol.for,n=r?Symbol.for("react.element"):60103,i=r?Symbol.for("react.portal"):60106,s=r?Symbol.for("react.fragment"):60107,o=r?Symbol.for("react.strict_mode"):60108,a=r?Symbol.for("react.profiler"):60114,l=r?Symbol.for("react.provider"):60109,c=r?Symbol.for("react.context"):60110,u=r?Symbol.for("react.async_mode"):60111,h=r?Symbol.for("react.concurrent_mode"):60111,d=r?Symbol.for("react.forward_ref"):60112,f=r?Symbol.for("react.suspense"):60113,p=(r&&Symbol.for("react.suspense_list"),r?Symbol.for("react.memo"):60115),m=r?Symbol.for("react.lazy"):60116;r&&Symbol.for("react.block"),r&&Symbol.for("react.fundamental"),r&&Symbol.for("react.responder"),r&&Symbol.for("react.scope");function g(t){if("object"==typeof t&&null!==t){var e=t.$$typeof;switch(e){case n:switch(t=t.type){case u:case h:case s:case a:case o:case f:return t;default:switch(t=t&&t.$$typeof){case c:case d:case m:case p:case l:return t;default:return e}}case i:return e}}}e.isForwardRef=function(t){return g(t)===d},e.isMemo=function(t){return g(t)===p}},524:(t,e,r)=>{"use strict";t.exports=r(90320)},42877:(t,e,r)=>{"use strict";r.d(e,{Ay:()=>Ir});var n=6378137,i=.0066943799901413165,s=484813681109536e-20,o=Math.PI/2,a=1e-10,l=.017453292519943295,c=57.29577951308232,u=Math.PI/4,h=2*Math.PI,d=3.14159265359,f={greenwich:0,lisbon:-9.131906111111,paris:2.337229166667,bogota:-74.080916666667,madrid:-3.687938888889,rome:12.452333333333,bern:7.439583333333,jakarta:106.807719444444,ferro:-17.666666666667,brussels:4.367975,stockholm:18.058277777778,athens:23.7163375,oslo:10.722916666667};const p={ft:{to_meter:.3048},"us-ft":{to_meter:1200/3937}};var m=/[\s_\-\/\(\)]/g;function g(t,e){if(t[e])return t[e];for(var r,n=Object.keys(t),i=e.toLowerCase().replace(m,""),s=-1;++s<n.length;)if((r=n[s]).toLowerCase().replace(m,"")===i)return t[r]}function y(t){var e,r,n,i={},s=t.split("+").map((function(t){return t.trim()})).filter((function(t){return t})).reduce((function(t,e){var r=e.split("=");return r.push(!0),t[r[0].toLowerCase()]=r[1],t}),{}),o={proj:"projName",datum:"datumCode",rf:function(t){i.rf=parseFloat(t)},lat_0:function(t){i.lat0=t*l},lat_1:function(t){i.lat1=t*l},lat_2:function(t){i.lat2=t*l},lat_ts:function(t){i.lat_ts=t*l},lon_0:function(t){i.long0=t*l},lon_1:function(t){i.long1=t*l},lon_2:function(t){i.long2=t*l},alpha:function(t){i.alpha=parseFloat(t)*l},gamma:function(t){i.rectified_grid_angle=parseFloat(t)},lonc:function(t){i.longc=t*l},x_0:function(t){i.x0=parseFloat(t)},y_0:function(t){i.y0=parseFloat(t)},k_0:function(t){i.k0=parseFloat(t)},k:function(t){i.k0=parseFloat(t)},a:function(t){i.a=parseFloat(t)},b:function(t){i.b=parseFloat(t)},r:function(t){i.a=i.b=parseFloat(t)},r_a:function(){i.R_A=!0},zone:function(t){i.zone=parseInt(t,10)},south:function(){i.utmSouth=!0},towgs84:function(t){i.datum_params=t.split(",").map((function(t){return parseFloat(t)}))},to_meter:function(t){i.to_meter=parseFloat(t)},units:function(t){i.units=t;var e=g(p,t);e&&(i.to_meter=e.to_meter)},from_greenwich:function(t){i.from_greenwich=t*l},pm:function(t){var e=g(f,t);i.from_greenwich=(e||parseFloat(t))*l},nadgrids:function(t){"@null"===t?i.datumCode="none":i.nadgrids=t},axis:function(t){var e="ewnsud";3===t.length&&-1!==e.indexOf(t.substr(0,1))&&-1!==e.indexOf(t.substr(1,1))&&-1!==e.indexOf(t.substr(2,1))&&(i.axis=t)},approx:function(){i.approx=!0}};for(e in s)r=s[e],e in o?"function"==typeof(n=o[e])?n(r):i[n]=r:i[e]=r;return"string"==typeof i.datumCode&&"WGS84"!==i.datumCode&&(i.datumCode=i.datumCode.toLowerCase()),i}var v=1,_=/\s/,b=/[A-Za-z]/,w=/[A-Za-z84_]/,x=/[,\]]/,E=/[\d\.E\-\+]/;function S(t){if("string"!=typeof t)throw new Error("not a string");this.text=t.trim(),this.level=0,this.place=0,this.root=null,this.stack=[],this.currentObject=null,this.state=v}function A(t,e,r){Array.isArray(e)&&(r.unshift(e),e=null);var n=e?{}:t,i=r.reduce((function(t,e){return P(e,t),t}),n);e&&(t[e]=i)}function P(t,e){if(Array.isArray(t)){var r=t.shift();if("PARAMETER"===r&&(r=t.shift()),1===t.length)return Array.isArray(t[0])?(e[r]={},void P(t[0],e[r])):void(e[r]=t[0]);if(t.length)if("TOWGS84"!==r){if("AXIS"===r)return r in e||(e[r]=[]),void e[r].push(t);var n;switch(Array.isArray(r)||(e[r]={}),r){case"UNIT":case"PRIMEM":case"VERT_DATUM":return e[r]={name:t[0].toLowerCase(),convert:t[1]},void(3===t.length&&P(t[2],e[r]));case"SPHEROID":case"ELLIPSOID":return e[r]={name:t[0],a:t[1],rf:t[2]},void(4===t.length&&P(t[3],e[r]));case"PROJECTEDCRS":case"PROJCRS":case"GEOGCS":case"GEOCCS":case"PROJCS":case"LOCAL_CS":case"GEODCRS":case"GEODETICCRS":case"GEODETICDATUM":case"EDATUM":case"ENGINEERINGDATUM":case"VERT_CS":case"VERTCRS":case"VERTICALCRS":case"COMPD_CS":case"COMPOUNDCRS":case"ENGINEERINGCRS":case"ENGCRS":case"FITTED_CS":case"LOCAL_DATUM":case"DATUM":return t[0]=["name",t[0]],void A(e,r,t);default:for(n=-1;++n<t.length;)if(!Array.isArray(t[n]))return P(t,e[r]);return A(e,r,t)}}else e[r]=t;else e[r]=!0}else e[t]=!0}function T(t){return.017453292519943295*t}function C(t){var e=new S(t).output(),r=e.shift(),n=e.shift();e.unshift(["name",n]),e.unshift(["type",r]);var i={};return P(e,i),function(t){if("GEOGCS"===t.type?t.projName="longlat":"LOCAL_CS"===t.type?(t.projName="identity",t.local=!0):"object"==typeof t.PROJECTION?t.projName=Object.keys(t.PROJECTION)[0]:t.projName=t.PROJECTION,t.AXIS){for(var e="",r=0,n=t.AXIS.length;r<n;++r){var i=[t.AXIS[r][0].toLowerCase(),t.AXIS[r][1].toLowerCase()];-1!==i[0].indexOf("north")||("y"===i[0]||"lat"===i[0])&&"north"===i[1]?e+="n":-1!==i[0].indexOf("south")||("y"===i[0]||"lat"===i[0])&&"south"===i[1]?e+="s":-1!==i[0].indexOf("east")||("x"===i[0]||"lon"===i[0])&&"east"===i[1]?e+="e":-1===i[0].indexOf("west")&&("x"!==i[0]&&"lon"!==i[0]||"west"!==i[1])||(e+="w")}2===e.length&&(e+="u"),3===e.length&&(t.axis=e)}t.UNIT&&(t.units=t.UNIT.name.toLowerCase(),"metre"===t.units&&(t.units="meter"),t.UNIT.convert&&("GEOGCS"===t.type?t.DATUM&&t.DATUM.SPHEROID&&(t.to_meter=t.UNIT.convert*t.DATUM.SPHEROID.a):t.to_meter=t.UNIT.convert));var s=t.GEOGCS;function o(e){return e*(t.to_meter||1)}"GEOGCS"===t.type&&(s=t),s&&(s.DATUM?t.datumCode=s.DATUM.name.toLowerCase():t.datumCode=s.name.toLowerCase(),"d_"===t.datumCode.slice(0,2)&&(t.datumCode=t.datumCode.slice(2)),"new_zealand_geodetic_datum_1949"!==t.datumCode&&"new_zealand_1949"!==t.datumCode||(t.datumCode="nzgd49"),"wgs_1984"!==t.datumCode&&"world_geodetic_system_1984"!==t.datumCode||("Mercator_Auxiliary_Sphere"===t.PROJECTION&&(t.sphere=!0),t.datumCode="wgs84"),"_ferro"===t.datumCode.slice(-6)&&(t.datumCode=t.datumCode.slice(0,-6)),"_jakarta"===t.datumCode.slice(-8)&&(t.datumCode=t.datumCode.slice(0,-8)),~t.datumCode.indexOf("belge")&&(t.datumCode="rnb72"),s.DATUM&&s.DATUM.SPHEROID&&(t.ellps=s.DATUM.SPHEROID.name.replace("_19","").replace(/[Cc]larke\_18/,"clrk"),"international"===t.ellps.toLowerCase().slice(0,13)&&(t.ellps="intl"),t.a=s.DATUM.SPHEROID.a,t.rf=parseFloat(s.DATUM.SPHEROID.rf,10)),s.DATUM&&s.DATUM.TOWGS84&&(t.datum_params=s.DATUM.TOWGS84),~t.datumCode.indexOf("osgb_1936")&&(t.datumCode="osgb36"),~t.datumCode.indexOf("osni_1952")&&(t.datumCode="osni52"),(~t.datumCode.indexOf("tm65")||~t.datumCode.indexOf("geodetic_datum_of_1965"))&&(t.datumCode="ire65"),"ch1903+"===t.datumCode&&(t.datumCode="ch1903"),~t.datumCode.indexOf("israel")&&(t.datumCode="isr93")),t.b&&!isFinite(t.b)&&(t.b=t.a),[["standard_parallel_1","Standard_Parallel_1"],["standard_parallel_1","Latitude of 1st standard parallel"],["standard_parallel_2","Standard_Parallel_2"],["standard_parallel_2","Latitude of 2nd standard parallel"],["false_easting","False_Easting"],["false_easting","False easting"],["false-easting","Easting at false origin"],["false_northing","False_Northing"],["false_northing","False northing"],["false_northing","Northing at false origin"],["central_meridian","Central_Meridian"],["central_meridian","Longitude of natural origin"],["central_meridian","Longitude of false origin"],["latitude_of_origin","Latitude_Of_Origin"],["latitude_of_origin","Central_Parallel"],["latitude_of_origin","Latitude of natural origin"],["latitude_of_origin","Latitude of false origin"],["scale_factor","Scale_Factor"],["k0","scale_factor"],["latitude_of_center","Latitude_Of_Center"],["latitude_of_center","Latitude_of_center"],["lat0","latitude_of_center",T],["longitude_of_center","Longitude_Of_Center"],["longitude_of_center","Longitude_of_center"],["longc","longitude_of_center",T],["x0","false_easting",o],["y0","false_northing",o],["long0","central_meridian",T],["lat0","latitude_of_origin",T],["lat0","standard_parallel_1",T],["lat1","standard_parallel_1",T],["lat2","standard_parallel_2",T],["azimuth","Azimuth"],["alpha","azimuth",T],["srsCode","name"]].forEach((function(e){return function(t,e){var r=e[0],n=e[1];!(r in t)&&n in t&&(t[r]=t[n],3===e.length&&(t[r]=e[2](t[r])))}(t,e)})),t.long0||!t.longc||"Albers_Conic_Equal_Area"!==t.projName&&"Lambert_Azimuthal_Equal_Area"!==t.projName||(t.long0=t.longc),t.lat_ts||!t.lat1||"Stereographic_South_Pole"!==t.projName&&"Polar Stereographic (variant B)"!==t.projName?!t.lat_ts&&t.lat0&&"Polar_Stereographic"===t.projName&&(t.lat_ts=t.lat0,t.lat0=T(t.lat0>0?90:-90)):(t.lat0=T(t.lat1>0?90:-90),t.lat_ts=t.lat1)}(i),i}function M(t){var e=this;if(2===arguments.length){var r=arguments[1];"string"==typeof r?"+"===r.charAt(0)?M[t]=y(arguments[1]):M[t]=C(arguments[1]):M[t]=r}else if(1===arguments.length){if(Array.isArray(t))return t.map((function(t){Array.isArray(t)?M.apply(e,t):M(t)}));if("string"==typeof t){if(t in M)return M[t]}else"EPSG"in t?M["EPSG:"+t.EPSG]=t:"ESRI"in t?M["ESRI:"+t.ESRI]=t:"IAU2000"in t?M["IAU2000:"+t.IAU2000]=t:console.log(t);return}}S.prototype.readCharicter=function(){var t=this.text[this.place++];if(4!==this.state)for(;_.test(t);){if(this.place>=this.text.length)return;t=this.text[this.place++]}switch(this.state){case v:return this.neutral(t);case 2:return this.keyword(t);case 4:return this.quoted(t);case 5:return this.afterquote(t);case 3:return this.number(t);case-1:return}},S.prototype.afterquote=function(t){if('"'===t)return this.word+='"',void(this.state=4);if(x.test(t))return this.word=this.word.trim(),void this.afterItem(t);throw new Error("havn't handled \""+t+'" in afterquote yet, index '+this.place)},S.prototype.afterItem=function(t){return","===t?(null!==this.word&&this.currentObject.push(this.word),this.word=null,void(this.state=v)):"]"===t?(this.level--,null!==this.word&&(this.currentObject.push(this.word),this.word=null),this.state=v,this.currentObject=this.stack.pop(),void(this.currentObject||(this.state=-1))):void 0},S.prototype.number=function(t){if(!E.test(t)){if(x.test(t))return this.word=parseFloat(this.word),void this.afterItem(t);throw new Error("havn't handled \""+t+'" in number yet, index '+this.place)}this.word+=t},S.prototype.quoted=function(t){'"'!==t?this.word+=t:this.state=5},S.prototype.keyword=function(t){if(w.test(t))this.word+=t;else{if("["===t){var e=[];return e.push(this.word),this.level++,null===this.root?this.root=e:this.currentObject.push(e),this.stack.push(this.currentObject),this.currentObject=e,void(this.state=v)}if(!x.test(t))throw new Error("havn't handled \""+t+'" in keyword yet, index '+this.place);this.afterItem(t)}},S.prototype.neutral=function(t){if(b.test(t))return this.word=t,void(this.state=2);if('"'===t)return this.word="",void(this.state=4);if(E.test(t))return this.word=t,void(this.state=3);if(!x.test(t))throw new Error("havn't handled \""+t+'" in neutral yet, index '+this.place);this.afterItem(t)},S.prototype.output=function(){for(;this.place<this.text.length;)this.readCharicter();if(-1===this.state)return this.root;throw new Error('unable to parse string "'+this.text+'". State is '+this.state)},function(t){t("EPSG:4326","+title=WGS 84 (long/lat) +proj=longlat +ellps=WGS84 +datum=WGS84 +units=degrees"),t("EPSG:4269","+title=NAD83 (long/lat) +proj=longlat +a=6378137.0 +b=6356752.31414036 +ellps=GRS80 +datum=NAD83 +units=degrees"),t("EPSG:3857","+title=WGS 84 / Pseudo-Mercator +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs"),t.WGS84=t["EPSG:4326"],t["EPSG:3785"]=t["EPSG:3857"],t.GOOGLE=t["EPSG:3857"],t["EPSG:900913"]=t["EPSG:3857"],t["EPSG:102113"]=t["EPSG:3857"]}(M);const O=M;var R=["PROJECTEDCRS","PROJCRS","GEOGCS","GEOCCS","PROJCS","LOCAL_CS","GEODCRS","GEODETICCRS","GEODETICDATUM","ENGCRS","ENGINEERINGCRS"],D=["3857","900913","3785","102113"];function I(t,e){var r,n;if(t=t||{},!e)return t;for(n in e)void 0!==(r=e[n])&&(t[n]=r);return t}function k(t,e,r){var n=t*e;return r/Math.sqrt(1-n*n)}function L(t){return t<0?-1:1}function F(t){return Math.abs(t)<=d?t:t-L(t)*h}function j(t,e,r){var n=t*r,i=.5*t;return n=Math.pow((1-n)/(1+n),i),Math.tan(.5*(o-e))/n}function N(t,e){for(var r,n,i=.5*t,s=o-2*Math.atan(e),a=0;a<=15;a++)if(r=t*Math.sin(s),s+=n=o-2*Math.atan(e*Math.pow((1-r)/(1+r),i))-s,Math.abs(n)<=1e-10)return s;return-9999}const G={init:function(){var t=this.b/this.a;this.es=1-t*t,"x0"in this||(this.x0=0),"y0"in this||(this.y0=0),this.e=Math.sqrt(this.es),this.lat_ts?this.sphere?this.k0=Math.cos(this.lat_ts):this.k0=k(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)):this.k0||(this.k?this.k0=this.k:this.k0=1)},forward:function(t){var e,r,n=t.x,i=t.y;if(i*c>90&&i*c<-90&&n*c>180&&n*c<-180)return null;if(Math.abs(Math.abs(i)-o)<=a)return null;if(this.sphere)e=this.x0+this.a*this.k0*F(n-this.long0),r=this.y0+this.a*this.k0*Math.log(Math.tan(u+.5*i));else{var s=Math.sin(i),l=j(this.e,i,s);e=this.x0+this.a*this.k0*F(n-this.long0),r=this.y0-this.a*this.k0*Math.log(l)}return t.x=e,t.y=r,t},inverse:function(t){var e,r,n=t.x-this.x0,i=t.y-this.y0;if(this.sphere)r=o-2*Math.atan(Math.exp(-i/(this.a*this.k0)));else{var s=Math.exp(-i/(this.a*this.k0));if(-9999===(r=N(this.e,s)))return null}return e=F(this.long0+n/(this.a*this.k0)),t.x=e,t.y=r,t},names:["Mercator","Popular Visualisation Pseudo Mercator","Mercator_1SP","Mercator_Auxiliary_Sphere","merc"]};function $(t){return t}var z=[G,{init:function(){},forward:$,inverse:$,names:["longlat","identity"]}],U={},B=[];function V(t,e){var r=B.length;return t.names?(B[r]=t,t.names.forEach((function(t){U[t.toLowerCase()]=r})),this):(console.log(e),!0)}const q={start:function(){z.forEach(V)},add:V,get:function(t){if(!t)return!1;var e=t.toLowerCase();return void 0!==U[e]&&B[U[e]]?B[U[e]]:void 0}};var K={MERIT:{a:6378137,rf:298.257,ellipseName:"MERIT 1983"},SGS85:{a:6378136,rf:298.257,ellipseName:"Soviet Geodetic System 85"},GRS80:{a:6378137,rf:298.257222101,ellipseName:"GRS 1980(IUGG, 1980)"},IAU76:{a:6378140,rf:298.257,ellipseName:"IAU 1976"},airy:{a:6377563.396,b:6356256.91,ellipseName:"Airy 1830"},APL4:{a:6378137,rf:298.25,ellipseName:"Appl. Physics. 1965"},NWL9D:{a:6378145,rf:298.25,ellipseName:"Naval Weapons Lab., 1965"},mod_airy:{a:6377340.189,b:6356034.446,ellipseName:"Modified Airy"},andrae:{a:6377104.43,rf:300,ellipseName:"Andrae 1876 (Den., Iclnd.)"},aust_SA:{a:6378160,rf:298.25,ellipseName:"Australian Natl & S. Amer. 1969"},GRS67:{a:6378160,rf:298.247167427,ellipseName:"GRS 67(IUGG 1967)"},bessel:{a:6377397.155,rf:299.1528128,ellipseName:"Bessel 1841"},bess_nam:{a:6377483.865,rf:299.1528128,ellipseName:"Bessel 1841 (Namibia)"},clrk66:{a:6378206.4,b:6356583.8,ellipseName:"Clarke 1866"},clrk80:{a:6378249.145,rf:293.4663,ellipseName:"Clarke 1880 mod."},clrk80ign:{a:6378249.2,b:6356515,rf:293.4660213,ellipseName:"Clarke 1880 (IGN)"},clrk58:{a:6378293.645208759,rf:294.2606763692654,ellipseName:"Clarke 1858"},CPM:{a:6375738.7,rf:334.29,ellipseName:"Comm. des Poids et Mesures 1799"},delmbr:{a:6376428,rf:311.5,ellipseName:"Delambre 1810 (Belgium)"},engelis:{a:6378136.05,rf:298.2566,ellipseName:"Engelis 1985"},evrst30:{a:6377276.345,rf:300.8017,ellipseName:"Everest 1830"},evrst48:{a:6377304.063,rf:300.8017,ellipseName:"Everest 1948"},evrst56:{a:6377301.243,rf:300.8017,ellipseName:"Everest 1956"},evrst69:{a:6377295.664,rf:300.8017,ellipseName:"Everest 1969"},evrstSS:{a:6377298.556,rf:300.8017,ellipseName:"Everest (Sabah & Sarawak)"},fschr60:{a:6378166,rf:298.3,ellipseName:"Fischer (Mercury Datum) 1960"},fschr60m:{a:6378155,rf:298.3,ellipseName:"Fischer 1960"},fschr68:{a:6378150,rf:298.3,ellipseName:"Fischer 1968"},helmert:{a:6378200,rf:298.3,ellipseName:"Helmert 1906"},hough:{a:6378270,rf:297,ellipseName:"Hough"},intl:{a:6378388,rf:297,ellipseName:"International 1909 (Hayford)"},kaula:{a:6378163,rf:298.24,ellipseName:"Kaula 1961"},lerch:{a:6378139,rf:298.257,ellipseName:"Lerch 1979"},mprts:{a:6397300,rf:191,ellipseName:"Maupertius 1738"},new_intl:{a:6378157.5,b:6356772.2,ellipseName:"New International 1967"},plessis:{a:6376523,rf:6355863,ellipseName:"Plessis 1817 (France)"},krass:{a:6378245,rf:298.3,ellipseName:"Krassovsky, 1942"},SEasia:{a:6378155,b:6356773.3205,ellipseName:"Southeast Asia"},walbeck:{a:6376896,b:6355834.8467,ellipseName:"Walbeck"},WGS60:{a:6378165,rf:298.3,ellipseName:"WGS 60"},WGS66:{a:6378145,rf:298.25,ellipseName:"WGS 66"},WGS7:{a:6378135,rf:298.26,ellipseName:"WGS 72"}},W=K.WGS84={a:6378137,rf:298.257223563,ellipseName:"WGS 84"};K.sphere={a:6370997,b:6370997,ellipseName:"Normal Sphere (r=6370997)"};var H={wgs84:{towgs84:"0,0,0",ellipse:"WGS84",datumName:"WGS84"},ch1903:{towgs84:"674.374,15.056,405.346",ellipse:"bessel",datumName:"swiss"},ggrs87:{towgs84:"-199.87,74.79,246.62",ellipse:"GRS80",datumName:"Greek_Geodetic_Reference_System_1987"},nad83:{towgs84:"0,0,0",ellipse:"GRS80",datumName:"North_American_Datum_1983"},nad27:{nadgrids:"@conus,@alaska,@ntv2_0.gsb,@ntv1_can.dat",ellipse:"clrk66",datumName:"North_American_Datum_1927"},potsdam:{towgs84:"598.1,73.7,418.2,0.202,0.045,-2.455,6.7",ellipse:"bessel",datumName:"Potsdam Rauenberg 1950 DHDN"},carthage:{towgs84:"-263.0,6.0,431.0",ellipse:"clark80",datumName:"Carthage 1934 Tunisia"},hermannskogel:{towgs84:"577.326,90.129,463.919,5.137,1.474,5.297,2.4232",ellipse:"bessel",datumName:"Hermannskogel"},militargeographische_institut:{towgs84:"577.326,90.129,463.919,5.137,1.474,5.297,2.4232",ellipse:"bessel",datumName:"Militar-Geographische Institut"},osni52:{towgs84:"482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",ellipse:"airy",datumName:"Irish National"},ire65:{towgs84:"482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",ellipse:"mod_airy",datumName:"Ireland 1965"},rassadiran:{towgs84:"-133.63,-157.5,-158.62",ellipse:"intl",datumName:"Rassadiran"},nzgd49:{towgs84:"59.47,-5.04,187.44,0.47,-0.1,1.024,-4.5993",ellipse:"intl",datumName:"New Zealand Geodetic Datum 1949"},osgb36:{towgs84:"446.448,-125.157,542.060,0.1502,0.2470,0.8421,-20.4894",ellipse:"airy",datumName:"Airy 1830"},s_jtsk:{towgs84:"589,76,480",ellipse:"bessel",datumName:"S-JTSK (Ferro)"},beduaram:{towgs84:"-106,-87,188",ellipse:"clrk80",datumName:"Beduaram"},gunung_segara:{towgs84:"-403,684,41",ellipse:"bessel",datumName:"Gunung Segara Jakarta"},rnb72:{towgs84:"106.869,-52.2978,103.724,-0.33657,0.456955,-1.84218,1",ellipse:"intl",datumName:"Reseau National Belge 1972"}};var Y={};function X(t){if(0===t.length)return null;var e="@"===t[0];return e&&(t=t.slice(1)),"null"===t?{name:"null",mandatory:!e,grid:null,isNull:!0}:{name:t,mandatory:!e,grid:Y[t]||null,isNull:!1}}function Z(t){return t/3600*Math.PI/180}function J(t,e,r){return String.fromCharCode.apply(null,new Uint8Array(t.buffer.slice(e,r)))}function Q(t){return t.map((function(t){return[Z(t.longitudeShift),Z(t.latitudeShift)]}))}function tt(t,e,r){return{name:J(t,e+8,e+16).trim(),parent:J(t,e+24,e+24+8).trim(),lowerLatitude:t.getFloat64(e+72,r),upperLatitude:t.getFloat64(e+88,r),lowerLongitude:t.getFloat64(e+104,r),upperLongitude:t.getFloat64(e+120,r),latitudeInterval:t.getFloat64(e+136,r),longitudeInterval:t.getFloat64(e+152,r),gridNodeCount:t.getInt32(e+168,r)}}function et(t,e,r,n){for(var i=e+176,s=[],o=0;o<r.gridNodeCount;o++){var a={latitudeShift:t.getFloat32(i+16*o,n),longitudeShift:t.getFloat32(i+16*o+4,n),latitudeAccuracy:t.getFloat32(i+16*o+8,n),longitudeAccuracy:t.getFloat32(i+16*o+12,n)};s.push(a)}return s}function rt(t,e){if(!(this instanceof rt))return new rt(t);e=e||function(t){if(t)throw t};var r=function(t){if(!function(t){return"string"==typeof t}(t))return t;if(function(t){return t in O}(t))return O[t];if(function(t){return R.some((function(e){return t.indexOf(e)>-1}))}(t)){var e=C(t);if(function(t){var e=g(t,"authority");if(e){var r=g(e,"epsg");return r&&D.indexOf(r)>-1}}(e))return O["EPSG:3857"];var r=function(t){var e=g(t,"extension");if(e)return g(e,"proj4")}(e);return r?y(r):e}return function(t){return"+"===t[0]}(t)?y(t):void 0}(t);if("object"==typeof r){var n=rt.projections.get(r.projName);if(n){if(r.datumCode&&"none"!==r.datumCode){var i=g(H,r.datumCode);i&&(r.datum_params=r.datum_params||(i.towgs84?i.towgs84.split(","):null),r.ellps=i.ellipse,r.datumName=i.datumName?i.datumName:r.datumCode)}r.k0=r.k0||1,r.axis=r.axis||"enu",r.ellps=r.ellps||"wgs84",r.lat1=r.lat1||r.lat0;var o,l,c,u,h,d,f=function(t,e,r,n,i){if(!t){var s=g(K,n);s||(s=W),t=s.a,e=s.b,r=s.rf}return r&&!e&&(e=(1-1/r)*t),(0===r||Math.abs(t-e)<a)&&(i=!0,e=t),{a:t,b:e,rf:r,sphere:i}}(r.a,r.b,r.rf,r.ellps,r.sphere),p=(o=f.a,l=f.b,f.rf,h=((c=o*o)-(u=l*l))/c,d=0,r.R_A?(c=(o*=1-h*(.16666666666666666+h*(.04722222222222222+.022156084656084655*h)))*o,h=0):d=Math.sqrt(h),{es:h,e:d,ep2:(c-u)/u}),m=function(t){return void 0===t?null:t.split(",").map(X)}(r.nadgrids),v=r.datum||function(t,e,r,n,i,o,a){var l={};return l.datum_type=void 0===t||"none"===t?5:4,e&&(l.datum_params=e.map(parseFloat),0===l.datum_params[0]&&0===l.datum_params[1]&&0===l.datum_params[2]||(l.datum_type=1),l.datum_params.length>3&&(0===l.datum_params[3]&&0===l.datum_params[4]&&0===l.datum_params[5]&&0===l.datum_params[6]||(l.datum_type=2,l.datum_params[3]*=s,l.datum_params[4]*=s,l.datum_params[5]*=s,l.datum_params[6]=l.datum_params[6]/1e6+1))),a&&(l.datum_type=3,l.grids=a),l.a=r,l.b=n,l.es=i,l.ep2=o,l}(r.datumCode,r.datum_params,f.a,f.b,p.es,p.ep2,m);I(this,r),I(this,n),this.a=f.a,this.b=f.b,this.rf=f.rf,this.sphere=f.sphere,this.es=p.es,this.e=p.e,this.ep2=p.ep2,this.datum=v,this.init(),e(null,this)}else e("Could not get projection name from: "+t)}else e("Could not parse to valid json: "+t)}rt.projections=q,rt.projections.start();const nt=rt;function it(t,e,r){var n,i,s,a,l=t.x,c=t.y,u=t.z?t.z:0;if(c<-o&&c>-1.001*o)c=-o;else if(c>o&&c<1.001*o)c=o;else{if(c<-o)return{x:-1/0,y:-1/0,z:t.z};if(c>o)return{x:1/0,y:1/0,z:t.z}}return l>Math.PI&&(l-=2*Math.PI),i=Math.sin(c),a=Math.cos(c),s=i*i,{x:((n=r/Math.sqrt(1-e*s))+u)*a*Math.cos(l),y:(n+u)*a*Math.sin(l),z:(n*(1-e)+u)*i}}function st(t,e,r,n){var i,s,o,a,l,c,u,h,d,f,p,m,g,y,v,_=t.x,b=t.y,w=t.z?t.z:0;if(i=Math.sqrt(_*_+b*b),s=Math.sqrt(_*_+b*b+w*w),i/r<1e-12){if(y=0,s/r<1e-12)return v=-n,{x:t.x,y:t.y,z:t.z}}else y=Math.atan2(b,_);o=w/s,h=(a=i/s)*(1-e)*(l=1/Math.sqrt(1-e*(2-e)*a*a)),d=o*l,g=0;do{g++,c=e*(u=r/Math.sqrt(1-e*d*d))/(u+(v=i*h+w*d-u*(1-e*d*d))),m=(p=o*(l=1/Math.sqrt(1-c*(2-c)*a*a)))*h-(f=a*(1-c)*l)*d,h=f,d=p}while(m*m>1e-24&&g<30);return{x:y,y:Math.atan(p/Math.abs(f)),z:v}}function ot(t){return 1===t||2===t}function at(t,e,r){if(null===t.grids||0===t.grids.length)return console.log("Grid shift grids not found"),-1;var n={x:-r.x,y:r.y},i={x:Number.NaN,y:Number.NaN},s=[];t:for(var o=0;o<t.grids.length;o++){var a=t.grids[o];if(s.push(a.name),a.isNull){i=n;break}if(a.mandatory,null!==a.grid)for(var l=a.grid.subgrids,u=0,h=l.length;u<h;u++){var d=l[u],f=(Math.abs(d.del[1])+Math.abs(d.del[0]))/1e4,p=d.ll[0]-f,m=d.ll[1]-f,g=d.ll[0]+(d.lim[0]-1)*d.del[0]+f,y=d.ll[1]+(d.lim[1]-1)*d.del[1]+f;if(!(m>n.y||p>n.x||y<n.y||g<n.x||(i=lt(n,e,d),isNaN(i.x))))break t}else if(a.mandatory)return console.log("Unable to find mandatory grid '"+a.name+"'"),-1}return isNaN(i.x)?(console.log("Failed to find a grid shift table for location '"+-n.x*c+" "+n.y*c+" tried: '"+s+"'"),-1):(r.x=-i.x,r.y=i.y,0)}function lt(t,e,r){var n={x:Number.NaN,y:Number.NaN};if(isNaN(t.x))return n;var i={x:t.x,y:t.y};i.x-=r.ll[0],i.y-=r.ll[1],i.x=F(i.x-Math.PI)+Math.PI;var s=ct(i,r);if(e){if(isNaN(s.x))return n;s.x=i.x-s.x,s.y=i.y-s.y;var o,a,l=9;do{if(a=ct(s,r),isNaN(a.x)){console.log("Inverse grid shift iteration failed, presumably at grid edge. Using first approximation.");break}o={x:i.x-(a.x+s.x),y:i.y-(a.y+s.y)},s.x+=o.x,s.y+=o.y}while(l--&&Math.abs(o.x)>1e-12&&Math.abs(o.y)>1e-12);if(l<0)return console.log("Inverse grid shift iterator failed to converge."),n;n.x=F(s.x+r.ll[0]),n.y=s.y+r.ll[1]}else isNaN(s.x)||(n.x=t.x+s.x,n.y=t.y+s.y);return n}function ct(t,e){var r,n={x:t.x/e.del[0],y:t.y/e.del[1]},i=Math.floor(n.x),s=Math.floor(n.y),o=n.x-1*i,a=n.y-1*s,l={x:Number.NaN,y:Number.NaN};if(i<0||i>=e.lim[0])return l;if(s<0||s>=e.lim[1])return l;r=s*e.lim[0]+i;var c=e.cvs[r][0],u=e.cvs[r][1];r++;var h=e.cvs[r][0],d=e.cvs[r][1];r+=e.lim[0];var f=e.cvs[r][0],p=e.cvs[r][1];r--;var m=e.cvs[r][0],g=e.cvs[r][1],y=o*a,v=o*(1-a),_=(1-o)*(1-a),b=(1-o)*a;return l.x=_*c+v*h+b*m+y*f,l.y=_*u+v*d+b*g+y*p,l}function ut(t,e,r){var n,i,s,o=r.x,a=r.y,l=r.z||0,c={};for(s=0;s<3;s++)if(!e||2!==s||void 0!==r.z)switch(0===s?(n=o,i=-1!=="ew".indexOf(t.axis[s])?"x":"y"):1===s?(n=a,i=-1!=="ns".indexOf(t.axis[s])?"y":"x"):(n=l,i="z"),t.axis[s]){case"e":case"n":c[i]=n;break;case"w":case"s":c[i]=-n;break;case"u":void 0!==r[i]&&(c.z=n);break;case"d":void 0!==r[i]&&(c.z=-n);break;default:return null}return c}function ht(t){var e={x:t[0],y:t[1]};return t.length>2&&(e.z=t[2]),t.length>3&&(e.m=t[3]),e}function dt(t){if("function"==typeof Number.isFinite){if(Number.isFinite(t))return;throw new TypeError("coordinates must be finite numbers")}if("number"!=typeof t||t!=t||!isFinite(t))throw new TypeError("coordinates must be finite numbers")}function ft(t,e,r,s){var o,a=void 0!==(r=Array.isArray(r)?ht(r):{x:r.x,y:r.y,z:r.z,m:r.m}).z;if(function(t){dt(t.x),dt(t.y)}(r),t.datum&&e.datum&&function(t,e){return(1===t.datum.datum_type||2===t.datum.datum_type||3===t.datum.datum_type)&&"WGS84"!==e.datumCode||(1===e.datum.datum_type||2===e.datum.datum_type||3===e.datum.datum_type)&&"WGS84"!==t.datumCode}(t,e)&&(r=ft(t,o=new nt("WGS84"),r,s),t=o),s&&"enu"!==t.axis&&(r=ut(t,!1,r)),"longlat"===t.projName)r={x:r.x*l,y:r.y*l,z:r.z||0};else if(t.to_meter&&(r={x:r.x*t.to_meter,y:r.y*t.to_meter,z:r.z||0}),!(r=t.inverse(r)))return;if(t.from_greenwich&&(r.x+=t.from_greenwich),r=function(t,e,r){if(function(t,e){return t.datum_type===e.datum_type&&!(t.a!==e.a||Math.abs(t.es-e.es)>5e-11)&&(1===t.datum_type?t.datum_params[0]===e.datum_params[0]&&t.datum_params[1]===e.datum_params[1]&&t.datum_params[2]===e.datum_params[2]:2!==t.datum_type||t.datum_params[0]===e.datum_params[0]&&t.datum_params[1]===e.datum_params[1]&&t.datum_params[2]===e.datum_params[2]&&t.datum_params[3]===e.datum_params[3]&&t.datum_params[4]===e.datum_params[4]&&t.datum_params[5]===e.datum_params[5]&&t.datum_params[6]===e.datum_params[6])}(t,e))return r;if(5===t.datum_type||5===e.datum_type)return r;var s=t.a,o=t.es;if(3===t.datum_type){if(0!==at(t,!1,r))return;s=n,o=i}var a=e.a,l=e.b,c=e.es;return 3===e.datum_type&&(a=n,l=6356752.314,c=i),o!==c||s!==a||ot(t.datum_type)||ot(e.datum_type)?(r=it(r,o,s),ot(t.datum_type)&&(r=function(t,e,r){if(1===e)return{x:t.x+r[0],y:t.y+r[1],z:t.z+r[2]};if(2===e){var n=r[0],i=r[1],s=r[2],o=r[3],a=r[4],l=r[5],c=r[6];return{x:c*(t.x-l*t.y+a*t.z)+n,y:c*(l*t.x+t.y-o*t.z)+i,z:c*(-a*t.x+o*t.y+t.z)+s}}}(r,t.datum_type,t.datum_params)),ot(e.datum_type)&&(r=function(t,e,r){if(1===e)return{x:t.x-r[0],y:t.y-r[1],z:t.z-r[2]};if(2===e){var n=r[0],i=r[1],s=r[2],o=r[3],a=r[4],l=r[5],c=r[6],u=(t.x-n)/c,h=(t.y-i)/c,d=(t.z-s)/c;return{x:u+l*h-a*d,y:-l*u+h+o*d,z:a*u-o*h+d}}}(r,e.datum_type,e.datum_params)),r=st(r,c,a,l),3!==e.datum_type||0===at(e,!0,r)?r:void 0):r}(t.datum,e.datum,r))return e.from_greenwich&&(r={x:r.x-e.from_greenwich,y:r.y,z:r.z||0}),"longlat"===e.projName?r={x:r.x*c,y:r.y*c,z:r.z||0}:(r=e.forward(r),e.to_meter&&(r={x:r.x/e.to_meter,y:r.y/e.to_meter,z:r.z||0})),s&&"enu"!==e.axis?ut(e,!0,r):(r&&!a&&delete r.z,r)}var pt=nt("WGS84");function mt(t,e,r,n){var i,s,o;return Array.isArray(r)?(i=ft(t,e,r,n)||{x:NaN,y:NaN},r.length>2?void 0!==t.name&&"geocent"===t.name||void 0!==e.name&&"geocent"===e.name?"number"==typeof i.z?[i.x,i.y,i.z].concat(r.slice(3)):[i.x,i.y,r[2]].concat(r.slice(3)):[i.x,i.y].concat(r.slice(2)):[i.x,i.y]):(s=ft(t,e,r,n),2===(o=Object.keys(r)).length||o.forEach((function(n){if(void 0!==t.name&&"geocent"===t.name||void 0!==e.name&&"geocent"===e.name){if("x"===n||"y"===n||"z"===n)return}else if("x"===n||"y"===n)return;s[n]=r[n]})),s)}function gt(t){return t instanceof nt?t:t.oProj?t.oProj:nt(t)}const yt=function(t,e,r){t=gt(t);var n,i=!1;return void 0===e?(e=t,t=pt,i=!0):(void 0!==e.x||Array.isArray(e))&&(r=e,e=t,t=pt,i=!0),e=gt(e),r?mt(t,e,r):(n={forward:function(r,n){return mt(t,e,r,n)},inverse:function(r,n){return mt(e,t,r,n)}},i&&(n.oProj=e),n)};var vt="AJSAJS",_t="AFAFAF",bt=65,wt=73,xt=79;const Et={forward:St,inverse:function(t){var e=Ct(Ot(t.toUpperCase()));return e.lat&&e.lon?[e.lon,e.lat,e.lon,e.lat]:[e.left,e.bottom,e.right,e.top]},toPoint:At};function St(t,e){return e=e||5,function(t,e){var r,n,i,s,o,a,l,c,u,h,d,f="00000"+t.easting,p="00000"+t.northing;return t.zoneNumber+t.zoneLetter+(u=t.easting,h=t.northing,d=Mt(t.zoneNumber),r=Math.floor(u/1e5),n=Math.floor(h/1e5)%20,s=vt.charCodeAt(i=d-1),o=_t.charCodeAt(i),c=!1,(a=s+r-1)>90&&(a=a-90+bt-1,c=!0),(a===wt||s<wt&&a>wt||(a>wt||s<wt)&&c)&&a++,(a===xt||s<xt&&a>xt||(a>xt||s<xt)&&c)&&++a===wt&&a++,a>90&&(a=a-90+bt-1),(l=o+n)>86?(l=l-86+bt-1,c=!0):c=!1,(l===wt||o<wt&&l>wt||(l>wt||o<wt)&&c)&&l++,(l===xt||o<xt&&l>xt||(l>xt||o<xt)&&c)&&++l===wt&&l++,l>86&&(l=l-86+bt-1),String.fromCharCode(a)+String.fromCharCode(l))+f.substr(f.length-5,e)+p.substr(p.length-5,e)}(function(t){var e,r,n,i,s,o,a,l=t.lat,c=t.lon,u=6378137,h=.00669438,d=.9996,f=Pt(l),p=Pt(c);a=Math.floor((c+180)/6)+1,180===c&&(a=60),l>=56&&l<64&&c>=3&&c<12&&(a=32),l>=72&&l<84&&(c>=0&&c<9?a=31:c>=9&&c<21?a=33:c>=21&&c<33?a=35:c>=33&&c<42&&(a=37)),o=Pt(6*(a-1)-180+3),e=.006739496752268451,r=u/Math.sqrt(1-h*Math.sin(f)*Math.sin(f)),n=Math.tan(f)*Math.tan(f),i=e*Math.cos(f)*Math.cos(f);var m,g,y=d*r*((s=Math.cos(f)*(p-o))+(1-n+i)*s*s*s/6+(5-18*n+n*n+72*i-58*e)*s*s*s*s*s/120)+5e5,v=d*(u*(.9983242984503243*f-.002514607064228144*Math.sin(2*f)+2639046602129982e-21*Math.sin(4*f)-3.418046101696858e-9*Math.sin(6*f))+r*Math.tan(f)*(s*s/2+(5-n+9*i+4*i*i)*s*s*s*s/24+(61-58*n+n*n+600*i-2.2240339282485886)*s*s*s*s*s*s/720));return l<0&&(v+=1e7),{northing:Math.round(v),easting:Math.round(y),zoneNumber:a,zoneLetter:(m=l,g="Z",84>=m&&m>=72?g="X":72>m&&m>=64?g="W":64>m&&m>=56?g="V":56>m&&m>=48?g="U":48>m&&m>=40?g="T":40>m&&m>=32?g="S":32>m&&m>=24?g="R":24>m&&m>=16?g="Q":16>m&&m>=8?g="P":8>m&&m>=0?g="N":0>m&&m>=-8?g="M":-8>m&&m>=-16?g="L":-16>m&&m>=-24?g="K":-24>m&&m>=-32?g="J":-32>m&&m>=-40?g="H":-40>m&&m>=-48?g="G":-48>m&&m>=-56?g="F":-56>m&&m>=-64?g="E":-64>m&&m>=-72?g="D":-72>m&&m>=-80&&(g="C"),g)}}({lat:t[1],lon:t[0]}),e)}function At(t){var e=Ct(Ot(t.toUpperCase()));return e.lat&&e.lon?[e.lon,e.lat]:[(e.left+e.right)/2,(e.top+e.bottom)/2]}function Pt(t){return t*(Math.PI/180)}function Tt(t){return t/Math.PI*180}function Ct(t){var e=t.northing,r=t.easting,n=t.zoneLetter,i=t.zoneNumber;if(i<0||i>60)return null;var s,o,a,l,c,u,h,d,f,p=.9996,m=6378137,g=.00669438,y=(1-Math.sqrt(.99330562))/(1+Math.sqrt(.99330562)),v=r-5e5,_=e;n<"N"&&(_-=1e7),h=6*(i-1)-180+3,s=.006739496752268451,f=(d=_/p/6367449.145945056)+(3*y/2-27*y*y*y/32)*Math.sin(2*d)+(21*y*y/16-55*y*y*y*y/32)*Math.sin(4*d)+151*y*y*y/96*Math.sin(6*d),o=m/Math.sqrt(1-g*Math.sin(f)*Math.sin(f)),a=Math.tan(f)*Math.tan(f),l=s*Math.cos(f)*Math.cos(f),c=.99330562*m/Math.pow(1-g*Math.sin(f)*Math.sin(f),1.5),u=v/(o*p);var b=f-o*Math.tan(f)/c*(u*u/2-(5+3*a+10*l-4*l*l-9*s)*u*u*u*u/24+(61+90*a+298*l+45*a*a-1.6983531815716497-3*l*l)*u*u*u*u*u*u/720);b=Tt(b);var w,x=(u-(1+2*a+l)*u*u*u/6+(5-2*l+28*a-3*l*l+8*s+24*a*a)*u*u*u*u*u/120)/Math.cos(f);if(x=h+Tt(x),t.accuracy){var E=Ct({northing:t.northing+t.accuracy,easting:t.easting+t.accuracy,zoneLetter:t.zoneLetter,zoneNumber:t.zoneNumber});w={top:E.lat,right:E.lon,bottom:b,left:x}}else w={lat:b,lon:x};return w}function Mt(t){var e=t%6;return 0===e&&(e=6),e}function Ot(t){if(t&&0===t.length)throw"MGRSPoint coverting from nothing";for(var e,r=t.length,n=null,i="",s=0;!/[A-Z]/.test(e=t.charAt(s));){if(s>=2)throw"MGRSPoint bad conversion from: "+t;i+=e,s++}var o=parseInt(i,10);if(0===s||s+3>r)throw"MGRSPoint bad conversion from: "+t;var a=t.charAt(s++);if(a<="A"||"B"===a||"Y"===a||a>="Z"||"I"===a||"O"===a)throw"MGRSPoint zone letter "+a+" not handled: "+t;n=t.substring(s,s+=2);for(var l=Mt(o),c=function(t,e){for(var r=vt.charCodeAt(e-1),n=1e5,i=!1;r!==t.charCodeAt(0);){if(++r===wt&&r++,r===xt&&r++,r>90){if(i)throw"Bad character: "+t;r=bt,i=!0}n+=1e5}return n}(n.charAt(0),l),u=function(t,e){if(t>"V")throw"MGRSPoint given invalid Northing "+t;for(var r=_t.charCodeAt(e-1),n=0,i=!1;r!==t.charCodeAt(0);){if(++r===wt&&r++,r===xt&&r++,r>86){if(i)throw"Bad character: "+t;r=bt,i=!0}n+=1e5}return n}(n.charAt(1),l);u<Rt(a);)u+=2e6;var h=r-s;if(h%2!=0)throw"MGRSPoint has to have an even number \nof digits after the zone letter and two 100km letters - front \nhalf for easting meters, second half for \nnorthing meters"+t;var d,f,p,m=h/2,g=0,y=0;return m>0&&(d=1e5/Math.pow(10,m),f=t.substring(s,s+m),g=parseFloat(f)*d,p=t.substring(s+m),y=parseFloat(p)*d),{easting:g+c,northing:y+u,zoneLetter:a,zoneNumber:o,accuracy:d}}function Rt(t){var e;switch(t){case"C":e=11e5;break;case"D":e=2e6;break;case"E":e=28e5;break;case"F":e=37e5;break;case"G":e=46e5;break;case"H":e=55e5;break;case"J":e=64e5;break;case"K":e=73e5;break;case"L":e=82e5;break;case"M":e=91e5;break;case"N":e=0;break;case"P":e=8e5;break;case"Q":e=17e5;break;case"R":e=26e5;break;case"S":e=35e5;break;case"T":e=44e5;break;case"U":e=53e5;break;case"V":e=62e5;break;case"W":e=7e6;break;case"X":e=79e5;break;default:e=-1}if(e>=0)return e;throw"Invalid zone letter: "+t}function Dt(t,e,r){if(!(this instanceof Dt))return new Dt(t,e,r);if(Array.isArray(t))this.x=t[0],this.y=t[1],this.z=t[2]||0;else if("object"==typeof t)this.x=t.x,this.y=t.y,this.z=t.z||0;else if("string"==typeof t&&void 0===e){var n=t.split(",");this.x=parseFloat(n[0],10),this.y=parseFloat(n[1],10),this.z=parseFloat(n[2],10)||0}else this.x=t,this.y=e,this.z=r||0;console.warn("proj4.Point will be removed in version 3, use proj4.toPoint")}Dt.fromMGRS=function(t){return new Dt(At(t))},Dt.prototype.toMGRS=function(t){return St([this.x,this.y],t)};const It=Dt;var kt=.046875,Lt=.01953125,Ft=.01068115234375;function jt(t){var e=[];e[0]=1-t*(.25+t*(kt+t*(Lt+t*Ft))),e[1]=t*(.75-t*(kt+t*(Lt+t*Ft)));var r=t*t;return e[2]=r*(.46875-t*(.013020833333333334+.007120768229166667*t)),r*=t,e[3]=r*(.3645833333333333-.005696614583333333*t),e[4]=r*t*.3076171875,e}function Nt(t,e,r,n){return r*=e,e*=e,n[0]*t-r*(n[1]+e*(n[2]+e*(n[3]+e*n[4])))}function Gt(t,e,r){for(var n=1/(1-e),i=t,s=20;s;--s){var o=Math.sin(i),l=1-e*o*o;if(i-=l=(Nt(i,o,Math.cos(i),r)-t)*(l*Math.sqrt(l))*n,Math.abs(l)<a)return i}return i}const $t={init:function(){this.x0=void 0!==this.x0?this.x0:0,this.y0=void 0!==this.y0?this.y0:0,this.long0=void 0!==this.long0?this.long0:0,this.lat0=void 0!==this.lat0?this.lat0:0,this.es&&(this.en=jt(this.es),this.ml0=Nt(this.lat0,Math.sin(this.lat0),Math.cos(this.lat0),this.en))},forward:function(t){var e,r,n,i=t.x,s=t.y,o=F(i-this.long0),l=Math.sin(s),c=Math.cos(s);if(this.es){var u=c*o,h=Math.pow(u,2),d=this.ep2*Math.pow(c,2),f=Math.pow(d,2),p=Math.abs(c)>a?Math.tan(s):0,m=Math.pow(p,2),g=Math.pow(m,2);e=1-this.es*Math.pow(l,2),u/=Math.sqrt(e);var y=Nt(s,l,c,this.en);r=this.a*(this.k0*u*(1+h/6*(1-m+d+h/20*(5-18*m+g+14*d-58*m*d+h/42*(61+179*g-g*m-479*m)))))+this.x0,n=this.a*(this.k0*(y-this.ml0+l*o*u/2*(1+h/12*(5-m+9*d+4*f+h/30*(61+g-58*m+270*d-330*m*d+h/56*(1385+543*g-g*m-3111*m))))))+this.y0}else{var v=c*Math.sin(o);if(Math.abs(Math.abs(v)-1)<a)return 93;if(r=.5*this.a*this.k0*Math.log((1+v)/(1-v))+this.x0,n=c*Math.cos(o)/Math.sqrt(1-Math.pow(v,2)),(v=Math.abs(n))>=1){if(v-1>a)return 93;n=0}else n=Math.acos(n);s<0&&(n=-n),n=this.a*this.k0*(n-this.lat0)+this.y0}return t.x=r,t.y=n,t},inverse:function(t){var e,r,n,i,s=(t.x-this.x0)*(1/this.a),l=(t.y-this.y0)*(1/this.a);if(this.es)if(r=Gt(e=this.ml0+l/this.k0,this.es,this.en),Math.abs(r)<o){var c=Math.sin(r),u=Math.cos(r),h=Math.abs(u)>a?Math.tan(r):0,d=this.ep2*Math.pow(u,2),f=Math.pow(d,2),p=Math.pow(h,2),m=Math.pow(p,2);e=1-this.es*Math.pow(c,2);var g=s*Math.sqrt(e)/this.k0,y=Math.pow(g,2);n=r-(e*=h)*y/(1-this.es)*.5*(1-y/12*(5+3*p-9*d*p+d-4*f-y/30*(61+90*p-252*d*p+45*m+46*d-y/56*(1385+3633*p+4095*m+1574*m*p)))),i=F(this.long0+g*(1-y/6*(1+2*p+d-y/20*(5+28*p+24*m+8*d*p+6*d-y/42*(61+662*p+1320*m+720*m*p))))/u)}else n=o*L(l),i=0;else{var v=Math.exp(s/this.k0),_=.5*(v-1/v),b=this.lat0+l/this.k0,w=Math.cos(b);e=Math.sqrt((1-Math.pow(w,2))/(1+Math.pow(_,2))),n=Math.asin(e),l<0&&(n=-n),i=0===_&&0===w?0:F(Math.atan2(_,w)+this.long0)}return t.x=i,t.y=n,t},names:["Fast_Transverse_Mercator","Fast Transverse Mercator"]};function zt(t){var e=Math.exp(t);return(e-1/e)/2}function Ut(t,e){t=Math.abs(t),e=Math.abs(e);var r=Math.max(t,e),n=Math.min(t,e)/(r||1);return r*Math.sqrt(1+Math.pow(n,2))}function Bt(t,e){for(var r,n=2*Math.cos(2*e),i=t.length-1,s=t[i],o=0;--i>=0;)r=n*s-o+t[i],o=s,s=r;return e+r*Math.sin(2*e)}function Vt(t,e,r){for(var n,i,s=Math.sin(e),o=Math.cos(e),a=zt(r),l=function(t){var e=Math.exp(t);return(e+1/e)/2}(r),c=2*o*l,u=-2*s*a,h=t.length-1,d=t[h],f=0,p=0,m=0;--h>=0;)n=p,i=f,d=c*(p=d)-n-u*(f=m)+t[h],m=u*p-i+c*f;return[(c=s*l)*d-(u=o*a)*m,c*m+u*d]}const qt={init:function(){if(!this.approx&&(isNaN(this.es)||this.es<=0))throw new Error('Incorrect elliptical usage. Try using the +approx option in the proj string, or PROJECTION["Fast_Transverse_Mercator"] in the WKT.');this.approx&&($t.init.apply(this),this.forward=$t.forward,this.inverse=$t.inverse),this.x0=void 0!==this.x0?this.x0:0,this.y0=void 0!==this.y0?this.y0:0,this.long0=void 0!==this.long0?this.long0:0,this.lat0=void 0!==this.lat0?this.lat0:0,this.cgb=[],this.cbg=[],this.utg=[],this.gtu=[];var t=this.es/(1+Math.sqrt(1-this.es)),e=t/(2-t),r=e;this.cgb[0]=e*(2+e*(-2/3+e*(e*(116/45+e*(26/45+e*(-2854/675)))-2))),this.cbg[0]=e*(e*(2/3+e*(4/3+e*(-82/45+e*(32/45+e*(4642/4725)))))-2),r*=e,this.cgb[1]=r*(7/3+e*(e*(-227/45+e*(2704/315+e*(2323/945)))-1.6)),this.cbg[1]=r*(5/3+e*(-16/15+e*(-13/9+e*(904/315+e*(-1522/945))))),r*=e,this.cgb[2]=r*(56/15+e*(-136/35+e*(-1262/105+e*(73814/2835)))),this.cbg[2]=r*(-26/15+e*(34/21+e*(1.6+e*(-12686/2835)))),r*=e,this.cgb[3]=r*(4279/630+e*(-332/35+e*(-399572/14175))),this.cbg[3]=r*(1237/630+e*(e*(-24832/14175)-2.4)),r*=e,this.cgb[4]=r*(4174/315+e*(-144838/6237)),this.cbg[4]=r*(-734/315+e*(109598/31185)),r*=e,this.cgb[5]=r*(601676/22275),this.cbg[5]=r*(444337/155925),r=Math.pow(e,2),this.Qn=this.k0/(1+e)*(1+r*(1/4+r*(1/64+r/256))),this.utg[0]=e*(e*(2/3+e*(-37/96+e*(1/360+e*(81/512+e*(-96199/604800)))))-.5),this.gtu[0]=e*(.5+e*(-2/3+e*(5/16+e*(41/180+e*(-127/288+e*(7891/37800)))))),this.utg[1]=r*(-1/48+e*(-1/15+e*(437/1440+e*(-46/105+e*(1118711/3870720))))),this.gtu[1]=r*(13/48+e*(e*(557/1440+e*(281/630+e*(-1983433/1935360)))-.6)),r*=e,this.utg[2]=r*(-17/480+e*(37/840+e*(209/4480+e*(-5569/90720)))),this.gtu[2]=r*(61/240+e*(-103/140+e*(15061/26880+e*(167603/181440)))),r*=e,this.utg[3]=r*(-4397/161280+e*(11/504+e*(830251/7257600))),this.gtu[3]=r*(49561/161280+e*(-179/168+e*(6601661/7257600))),r*=e,this.utg[4]=r*(-4583/161280+e*(108847/3991680)),this.gtu[4]=r*(34729/80640+e*(-3418889/1995840)),r*=e,this.utg[5]=r*(-20648693/638668800),this.gtu[5]=.6650675310896665*r;var n=Bt(this.cbg,this.lat0);this.Zb=-this.Qn*(n+function(t,e){for(var r,n=2*Math.cos(e),i=t.length-1,s=t[i],o=0;--i>=0;)r=n*s-o+t[i],o=s,s=r;return Math.sin(e)*r}(this.gtu,2*n))},forward:function(t){var e=F(t.x-this.long0),r=t.y;r=Bt(this.cbg,r);var n=Math.sin(r),i=Math.cos(r),s=Math.sin(e),o=Math.cos(e);r=Math.atan2(n,o*i),e=Math.atan2(s*i,Ut(n,i*o)),e=function(t){var e=Math.abs(t);return e=function(t){var e=1+t,r=e-1;return 0===r?t:t*Math.log(e)/r}(e*(1+e/(Ut(1,e)+1))),t<0?-e:e}(Math.tan(e));var a,l,c=Vt(this.gtu,2*r,2*e);return r+=c[0],e+=c[1],Math.abs(e)<=2.623395162778?(a=this.a*(this.Qn*e)+this.x0,l=this.a*(this.Qn*r+this.Zb)+this.y0):(a=1/0,l=1/0),t.x=a,t.y=l,t},inverse:function(t){var e,r,n=(t.x-this.x0)*(1/this.a),i=(t.y-this.y0)*(1/this.a);if(i=(i-this.Zb)/this.Qn,n/=this.Qn,Math.abs(n)<=2.623395162778){var s=Vt(this.utg,2*i,2*n);i+=s[0],n+=s[1],n=Math.atan(zt(n));var o=Math.sin(i),a=Math.cos(i),l=Math.sin(n),c=Math.cos(n);i=Math.atan2(o*c,Ut(l,c*a)),e=F((n=Math.atan2(l,c*a))+this.long0),r=Bt(this.cgb,i)}else e=1/0,r=1/0;return t.x=e,t.y=r,t},names:["Extended_Transverse_Mercator","Extended Transverse Mercator","etmerc","Transverse_Mercator","Transverse Mercator","Gauss Kruger","Gauss_Kruger","tmerc"]},Kt={init:function(){var t=function(t,e){if(void 0===t){if((t=Math.floor(30*(F(e)+Math.PI)/Math.PI)+1)<0)return 0;if(t>60)return 60}return t}(this.zone,this.long0);if(void 0===t)throw new Error("unknown utm zone");this.lat0=0,this.long0=(6*Math.abs(t)-183)*l,this.x0=5e5,this.y0=this.utmSouth?1e7:0,this.k0=.9996,qt.init.apply(this),this.forward=qt.forward,this.inverse=qt.inverse},names:["Universal Transverse Mercator System","utm"],dependsOn:"etmerc"};function Wt(t,e){return Math.pow((1-t)/(1+t),e)}const Ht={init:function(){var t=Math.sin(this.lat0),e=Math.cos(this.lat0);e*=e,this.rc=Math.sqrt(1-this.es)/(1-this.es*t*t),this.C=Math.sqrt(1+this.es*e*e/(1-this.es)),this.phic0=Math.asin(t/this.C),this.ratexp=.5*this.C*this.e,this.K=Math.tan(.5*this.phic0+u)/(Math.pow(Math.tan(.5*this.lat0+u),this.C)*Wt(this.e*t,this.ratexp))},forward:function(t){var e=t.x,r=t.y;return t.y=2*Math.atan(this.K*Math.pow(Math.tan(.5*r+u),this.C)*Wt(this.e*Math.sin(r),this.ratexp))-o,t.x=this.C*e,t},inverse:function(t){for(var e=t.x/this.C,r=t.y,n=Math.pow(Math.tan(.5*r+u)/this.K,1/this.C),i=20;i>0&&(r=2*Math.atan(n*Wt(this.e*Math.sin(t.y),-.5*this.e))-o,!(Math.abs(r-t.y)<1e-14));--i)t.y=r;return i?(t.x=e,t.y=r,t):null},names:["gauss"]},Yt={init:function(){Ht.init.apply(this),this.rc&&(this.sinc0=Math.sin(this.phic0),this.cosc0=Math.cos(this.phic0),this.R2=2*this.rc,this.title||(this.title="Oblique Stereographic Alternative"))},forward:function(t){var e,r,n,i;return t.x=F(t.x-this.long0),Ht.forward.apply(this,[t]),e=Math.sin(t.y),r=Math.cos(t.y),n=Math.cos(t.x),i=this.k0*this.R2/(1+this.sinc0*e+this.cosc0*r*n),t.x=i*r*Math.sin(t.x),t.y=i*(this.cosc0*e-this.sinc0*r*n),t.x=this.a*t.x+this.x0,t.y=this.a*t.y+this.y0,t},inverse:function(t){var e,r,n,i,s;if(t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,t.x/=this.k0,t.y/=this.k0,s=Ut(t.x,t.y)){var o=2*Math.atan2(s,this.R2);e=Math.sin(o),r=Math.cos(o),i=Math.asin(r*this.sinc0+t.y*e*this.cosc0/s),n=Math.atan2(t.x*e,s*this.cosc0*r-t.y*this.sinc0*e)}else i=this.phic0,n=0;return t.x=n,t.y=i,Ht.inverse.apply(this,[t]),t.x=F(t.x+this.long0),t},names:["Stereographic_North_Pole","Oblique_Stereographic","sterea","Oblique Stereographic Alternative","Double_Stereographic"]},Xt={init:function(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.coslat0=Math.cos(this.lat0),this.sinlat0=Math.sin(this.lat0),this.sphere?1===this.k0&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=a&&(this.k0=.5*(1+L(this.lat0)*Math.sin(this.lat_ts))):(Math.abs(this.coslat0)<=a&&(this.lat0>0?this.con=1:this.con=-1),this.cons=Math.sqrt(Math.pow(1+this.e,1+this.e)*Math.pow(1-this.e,1-this.e)),1===this.k0&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=a&&Math.abs(Math.cos(this.lat_ts))>a&&(this.k0=.5*this.cons*k(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts))/j(this.e,this.con*this.lat_ts,this.con*Math.sin(this.lat_ts))),this.ms1=k(this.e,this.sinlat0,this.coslat0),this.X0=2*Math.atan(this.ssfn_(this.lat0,this.sinlat0,this.e))-o,this.cosX0=Math.cos(this.X0),this.sinX0=Math.sin(this.X0))},forward:function(t){var e,r,n,i,s,l,c=t.x,u=t.y,h=Math.sin(u),d=Math.cos(u),f=F(c-this.long0);return Math.abs(Math.abs(c-this.long0)-Math.PI)<=a&&Math.abs(u+this.lat0)<=a?(t.x=NaN,t.y=NaN,t):this.sphere?(e=2*this.k0/(1+this.sinlat0*h+this.coslat0*d*Math.cos(f)),t.x=this.a*e*d*Math.sin(f)+this.x0,t.y=this.a*e*(this.coslat0*h-this.sinlat0*d*Math.cos(f))+this.y0,t):(r=2*Math.atan(this.ssfn_(u,h,this.e))-o,i=Math.cos(r),n=Math.sin(r),Math.abs(this.coslat0)<=a?(s=j(this.e,u*this.con,this.con*h),l=2*this.a*this.k0*s/this.cons,t.x=this.x0+l*Math.sin(c-this.long0),t.y=this.y0-this.con*l*Math.cos(c-this.long0),t):(Math.abs(this.sinlat0)<a?(e=2*this.a*this.k0/(1+i*Math.cos(f)),t.y=e*n):(e=2*this.a*this.k0*this.ms1/(this.cosX0*(1+this.sinX0*n+this.cosX0*i*Math.cos(f))),t.y=e*(this.cosX0*n-this.sinX0*i*Math.cos(f))+this.y0),t.x=e*i*Math.sin(f)+this.x0,t))},inverse:function(t){var e,r,n,i,s;t.x-=this.x0,t.y-=this.y0;var l=Math.sqrt(t.x*t.x+t.y*t.y);if(this.sphere){var c=2*Math.atan(l/(2*this.a*this.k0));return e=this.long0,r=this.lat0,l<=a?(t.x=e,t.y=r,t):(r=Math.asin(Math.cos(c)*this.sinlat0+t.y*Math.sin(c)*this.coslat0/l),e=Math.abs(this.coslat0)<a?this.lat0>0?F(this.long0+Math.atan2(t.x,-1*t.y)):F(this.long0+Math.atan2(t.x,t.y)):F(this.long0+Math.atan2(t.x*Math.sin(c),l*this.coslat0*Math.cos(c)-t.y*this.sinlat0*Math.sin(c))),t.x=e,t.y=r,t)}if(Math.abs(this.coslat0)<=a){if(l<=a)return r=this.lat0,e=this.long0,t.x=e,t.y=r,t;t.x*=this.con,t.y*=this.con,n=l*this.cons/(2*this.a*this.k0),r=this.con*N(this.e,n),e=this.con*F(this.con*this.long0+Math.atan2(t.x,-1*t.y))}else i=2*Math.atan(l*this.cosX0/(2*this.a*this.k0*this.ms1)),e=this.long0,l<=a?s=this.X0:(s=Math.asin(Math.cos(i)*this.sinX0+t.y*Math.sin(i)*this.cosX0/l),e=F(this.long0+Math.atan2(t.x*Math.sin(i),l*this.cosX0*Math.cos(i)-t.y*this.sinX0*Math.sin(i)))),r=-1*N(this.e,Math.tan(.5*(o+s)));return t.x=e,t.y=r,t},names:["stere","Stereographic_South_Pole","Polar Stereographic (variant B)","Polar_Stereographic"],ssfn_:function(t,e,r){return e*=r,Math.tan(.5*(o+t))*Math.pow((1-e)/(1+e),.5*r)}},Zt={init:function(){var t=this.lat0;this.lambda0=this.long0;var e=Math.sin(t),r=this.a,n=1/this.rf,i=2*n-Math.pow(n,2),s=this.e=Math.sqrt(i);this.R=this.k0*r*Math.sqrt(1-i)/(1-i*Math.pow(e,2)),this.alpha=Math.sqrt(1+i/(1-i)*Math.pow(Math.cos(t),4)),this.b0=Math.asin(e/this.alpha);var o=Math.log(Math.tan(Math.PI/4+this.b0/2)),a=Math.log(Math.tan(Math.PI/4+t/2)),l=Math.log((1+s*e)/(1-s*e));this.K=o-this.alpha*a+this.alpha*s/2*l},forward:function(t){var e=Math.log(Math.tan(Math.PI/4-t.y/2)),r=this.e/2*Math.log((1+this.e*Math.sin(t.y))/(1-this.e*Math.sin(t.y))),n=-this.alpha*(e+r)+this.K,i=2*(Math.atan(Math.exp(n))-Math.PI/4),s=this.alpha*(t.x-this.lambda0),o=Math.atan(Math.sin(s)/(Math.sin(this.b0)*Math.tan(i)+Math.cos(this.b0)*Math.cos(s))),a=Math.asin(Math.cos(this.b0)*Math.sin(i)-Math.sin(this.b0)*Math.cos(i)*Math.cos(s));return t.y=this.R/2*Math.log((1+Math.sin(a))/(1-Math.sin(a)))+this.y0,t.x=this.R*o+this.x0,t},inverse:function(t){for(var e=t.x-this.x0,r=t.y-this.y0,n=e/this.R,i=2*(Math.atan(Math.exp(r/this.R))-Math.PI/4),s=Math.asin(Math.cos(this.b0)*Math.sin(i)+Math.sin(this.b0)*Math.cos(i)*Math.cos(n)),o=Math.atan(Math.sin(n)/(Math.cos(this.b0)*Math.cos(n)-Math.sin(this.b0)*Math.tan(i))),a=this.lambda0+o/this.alpha,l=0,c=s,u=-1e3,h=0;Math.abs(c-u)>1e-7;){if(++h>20)return;l=1/this.alpha*(Math.log(Math.tan(Math.PI/4+s/2))-this.K)+this.e*Math.log(Math.tan(Math.PI/4+Math.asin(this.e*Math.sin(c))/2)),u=c,c=2*Math.atan(Math.exp(l))-Math.PI/2}return t.x=a,t.y=c,t},names:["somerc"]};var Jt=1e-7;const Qt={init:function(){var t,e,r,n,i,s,c,d,f,p,m,g,y,v=0,_=0,b=0,w=0,x=0,E=0,S=0;this.no_off=(y="object"==typeof(g=this).PROJECTION?Object.keys(g.PROJECTION)[0]:g.PROJECTION,"no_uoff"in g||"no_off"in g||-1!==["Hotine_Oblique_Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin"].indexOf(y)),this.no_rot="no_rot"in this;var A=!1;"alpha"in this&&(A=!0);var P=!1;if("rectified_grid_angle"in this&&(P=!0),A&&(S=this.alpha),P&&(v=this.rectified_grid_angle*l),A||P)_=this.longc;else if(b=this.long1,x=this.lat1,w=this.long2,E=this.lat2,Math.abs(x-E)<=Jt||(t=Math.abs(x))<=Jt||Math.abs(t-o)<=Jt||Math.abs(Math.abs(this.lat0)-o)<=Jt||Math.abs(Math.abs(E)-o)<=Jt)throw new Error;var T=1-this.es;e=Math.sqrt(T),Math.abs(this.lat0)>a?(d=Math.sin(this.lat0),r=Math.cos(this.lat0),t=1-this.es*d*d,this.B=r*r,this.B=Math.sqrt(1+this.es*this.B*this.B/T),this.A=this.B*this.k0*e/t,(i=(n=this.B*e/(r*Math.sqrt(t)))*n-1)<=0?i=0:(i=Math.sqrt(i),this.lat0<0&&(i=-i)),this.E=i+=n,this.E*=Math.pow(j(this.e,this.lat0,d),this.B)):(this.B=1/e,this.A=this.k0,this.E=n=i=1),A||P?(A?(m=Math.asin(Math.sin(S)/n),P||(v=S)):(m=v,S=Math.asin(n*Math.sin(m))),this.lam0=_-Math.asin(.5*(i-1/i)*Math.tan(m))/this.B):(s=Math.pow(j(this.e,x,Math.sin(x)),this.B),c=Math.pow(j(this.e,E,Math.sin(E)),this.B),i=this.E/s,f=(c-s)/(c+s),p=((p=this.E*this.E)-c*s)/(p+c*s),(t=b-w)<-Math.pi?w-=h:t>Math.pi&&(w+=h),this.lam0=F(.5*(b+w)-Math.atan(p*Math.tan(.5*this.B*(b-w))/f)/this.B),m=Math.atan(2*Math.sin(this.B*F(b-this.lam0))/(i-1/i)),v=S=Math.asin(n*Math.sin(m))),this.singam=Math.sin(m),this.cosgam=Math.cos(m),this.sinrot=Math.sin(v),this.cosrot=Math.cos(v),this.rB=1/this.B,this.ArB=this.A*this.rB,this.BrA=1/this.ArB,this.A,this.B,this.no_off?this.u_0=0:(this.u_0=Math.abs(this.ArB*Math.atan(Math.sqrt(n*n-1)/Math.cos(S))),this.lat0<0&&(this.u_0=-this.u_0)),i=.5*m,this.v_pole_n=this.ArB*Math.log(Math.tan(u-i)),this.v_pole_s=this.ArB*Math.log(Math.tan(u+i))},forward:function(t){var e,r,n,i,s,l,c,u,h={};if(t.x=t.x-this.lam0,Math.abs(Math.abs(t.y)-o)>a){if(e=.5*((s=this.E/Math.pow(j(this.e,t.y,Math.sin(t.y)),this.B))-(l=1/s)),r=.5*(s+l),i=Math.sin(this.B*t.x),n=(e*this.singam-i*this.cosgam)/r,Math.abs(Math.abs(n)-1)<a)throw new Error;u=.5*this.ArB*Math.log((1-n)/(1+n)),l=Math.cos(this.B*t.x),c=Math.abs(l)<Jt?this.A*t.x:this.ArB*Math.atan2(e*this.cosgam+i*this.singam,l)}else u=t.y>0?this.v_pole_n:this.v_pole_s,c=this.ArB*t.y;return this.no_rot?(h.x=c,h.y=u):(c-=this.u_0,h.x=u*this.cosrot+c*this.sinrot,h.y=c*this.cosrot-u*this.sinrot),h.x=this.a*h.x+this.x0,h.y=this.a*h.y+this.y0,h},inverse:function(t){var e,r,n,i,s,l,c,u={};if(t.x=(t.x-this.x0)*(1/this.a),t.y=(t.y-this.y0)*(1/this.a),this.no_rot?(r=t.y,e=t.x):(r=t.x*this.cosrot-t.y*this.sinrot,e=t.y*this.cosrot+t.x*this.sinrot+this.u_0),i=.5*((n=Math.exp(-this.BrA*r))-1/n),s=.5*(n+1/n),c=((l=Math.sin(this.BrA*e))*this.cosgam+i*this.singam)/s,Math.abs(Math.abs(c)-1)<a)u.x=0,u.y=c<0?-o:o;else{if(u.y=this.E/Math.sqrt((1+c)/(1-c)),u.y=N(this.e,Math.pow(u.y,1/this.B)),u.y===1/0)throw new Error;u.x=-this.rB*Math.atan2(i*this.cosgam-l*this.singam,Math.cos(this.BrA*e))}return u.x+=this.lam0,u},names:["Hotine_Oblique_Mercator","Hotine Oblique Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin","Hotine_Oblique_Mercator_Two_Point_Natural_Origin","Hotine_Oblique_Mercator_Azimuth_Center","Oblique_Mercator","omerc"]},te={init:function(){if(this.lat2||(this.lat2=this.lat1),this.k0||(this.k0=1),this.x0=this.x0||0,this.y0=this.y0||0,!(Math.abs(this.lat1+this.lat2)<a)){var t=this.b/this.a;this.e=Math.sqrt(1-t*t);var e=Math.sin(this.lat1),r=Math.cos(this.lat1),n=k(this.e,e,r),i=j(this.e,this.lat1,e),s=Math.sin(this.lat2),o=Math.cos(this.lat2),l=k(this.e,s,o),c=j(this.e,this.lat2,s),u=j(this.e,this.lat0,Math.sin(this.lat0));Math.abs(this.lat1-this.lat2)>a?this.ns=Math.log(n/l)/Math.log(i/c):this.ns=e,isNaN(this.ns)&&(this.ns=e),this.f0=n/(this.ns*Math.pow(i,this.ns)),this.rh=this.a*this.f0*Math.pow(u,this.ns),this.title||(this.title="Lambert Conformal Conic")}},forward:function(t){var e=t.x,r=t.y;Math.abs(2*Math.abs(r)-Math.PI)<=a&&(r=L(r)*(o-2e-10));var n,i,s=Math.abs(Math.abs(r)-o);if(s>a)n=j(this.e,r,Math.sin(r)),i=this.a*this.f0*Math.pow(n,this.ns);else{if((s=r*this.ns)<=0)return null;i=0}var l=this.ns*F(e-this.long0);return t.x=this.k0*(i*Math.sin(l))+this.x0,t.y=this.k0*(this.rh-i*Math.cos(l))+this.y0,t},inverse:function(t){var e,r,n,i,s,a=(t.x-this.x0)/this.k0,l=this.rh-(t.y-this.y0)/this.k0;this.ns>0?(e=Math.sqrt(a*a+l*l),r=1):(e=-Math.sqrt(a*a+l*l),r=-1);var c=0;if(0!==e&&(c=Math.atan2(r*a,r*l)),0!==e||this.ns>0){if(r=1/this.ns,n=Math.pow(e/(this.a*this.f0),r),-9999===(i=N(this.e,n)))return null}else i=-o;return s=F(c/this.ns+this.long0),t.x=s,t.y=i,t},names:["Lambert Tangential Conformal Conic Projection","Lambert_Conformal_Conic","Lambert_Conformal_Conic_1SP","Lambert_Conformal_Conic_2SP","lcc","Lambert Conic Conformal (1SP)","Lambert Conic Conformal (2SP)"]},ee={init:function(){this.a=6377397.155,this.es=.006674372230614,this.e=Math.sqrt(this.es),this.lat0||(this.lat0=.863937979737193),this.long0||(this.long0=.4334234309119251),this.k0||(this.k0=.9999),this.s45=.785398163397448,this.s90=2*this.s45,this.fi0=this.lat0,this.e2=this.es,this.e=Math.sqrt(this.e2),this.alfa=Math.sqrt(1+this.e2*Math.pow(Math.cos(this.fi0),4)/(1-this.e2)),this.uq=1.04216856380474,this.u0=Math.asin(Math.sin(this.fi0)/this.alfa),this.g=Math.pow((1+this.e*Math.sin(this.fi0))/(1-this.e*Math.sin(this.fi0)),this.alfa*this.e/2),this.k=Math.tan(this.u0/2+this.s45)/Math.pow(Math.tan(this.fi0/2+this.s45),this.alfa)*this.g,this.k1=this.k0,this.n0=this.a*Math.sqrt(1-this.e2)/(1-this.e2*Math.pow(Math.sin(this.fi0),2)),this.s0=1.37008346281555,this.n=Math.sin(this.s0),this.ro0=this.k1*this.n0/Math.tan(this.s0),this.ad=this.s90-this.uq},forward:function(t){var e,r,n,i,s,o,a,l=t.x,c=t.y,u=F(l-this.long0);return e=Math.pow((1+this.e*Math.sin(c))/(1-this.e*Math.sin(c)),this.alfa*this.e/2),r=2*(Math.atan(this.k*Math.pow(Math.tan(c/2+this.s45),this.alfa)/e)-this.s45),n=-u*this.alfa,i=Math.asin(Math.cos(this.ad)*Math.sin(r)+Math.sin(this.ad)*Math.cos(r)*Math.cos(n)),s=Math.asin(Math.cos(r)*Math.sin(n)/Math.cos(i)),o=this.n*s,a=this.ro0*Math.pow(Math.tan(this.s0/2+this.s45),this.n)/Math.pow(Math.tan(i/2+this.s45),this.n),t.y=a*Math.cos(o)/1,t.x=a*Math.sin(o)/1,this.czech||(t.y*=-1,t.x*=-1),t},inverse:function(t){var e,r,n,i,s,o,a,l=t.x;t.x=t.y,t.y=l,this.czech||(t.y*=-1,t.x*=-1),s=Math.sqrt(t.x*t.x+t.y*t.y),i=Math.atan2(t.y,t.x)/Math.sin(this.s0),n=2*(Math.atan(Math.pow(this.ro0/s,1/this.n)*Math.tan(this.s0/2+this.s45))-this.s45),e=Math.asin(Math.cos(this.ad)*Math.sin(n)-Math.sin(this.ad)*Math.cos(n)*Math.cos(i)),r=Math.asin(Math.cos(n)*Math.sin(i)/Math.cos(e)),t.x=this.long0-r/this.alfa,o=e,a=0;var c=0;do{t.y=2*(Math.atan(Math.pow(this.k,-1/this.alfa)*Math.pow(Math.tan(e/2+this.s45),1/this.alfa)*Math.pow((1+this.e*Math.sin(o))/(1-this.e*Math.sin(o)),this.e/2))-this.s45),Math.abs(o-t.y)<1e-10&&(a=1),o=t.y,c+=1}while(0===a&&c<15);return c>=15?null:t},names:["Krovak","krovak"]};function re(t,e,r,n,i){return t*i-e*Math.sin(2*i)+r*Math.sin(4*i)-n*Math.sin(6*i)}function ne(t){return 1-.25*t*(1+t/16*(3+1.25*t))}function ie(t){return.375*t*(1+.25*t*(1+.46875*t))}function se(t){return.05859375*t*t*(1+.75*t)}function oe(t){return t*t*t*(35/3072)}function ae(t,e,r){var n=e*r;return t/Math.sqrt(1-n*n)}function le(t){return Math.abs(t)<o?t:t-L(t)*Math.PI}function ce(t,e,r,n,i){var s,o;s=t/e;for(var a=0;a<15;a++)if(s+=o=(t-(e*s-r*Math.sin(2*s)+n*Math.sin(4*s)-i*Math.sin(6*s)))/(e-2*r*Math.cos(2*s)+4*n*Math.cos(4*s)-6*i*Math.cos(6*s)),Math.abs(o)<=1e-10)return s;return NaN}const ue={init:function(){this.sphere||(this.e0=ne(this.es),this.e1=ie(this.es),this.e2=se(this.es),this.e3=oe(this.es),this.ml0=this.a*re(this.e0,this.e1,this.e2,this.e3,this.lat0))},forward:function(t){var e,r,n=t.x,i=t.y;if(n=F(n-this.long0),this.sphere)e=this.a*Math.asin(Math.cos(i)*Math.sin(n)),r=this.a*(Math.atan2(Math.tan(i),Math.cos(n))-this.lat0);else{var s=Math.sin(i),o=Math.cos(i),a=ae(this.a,this.e,s),l=Math.tan(i)*Math.tan(i),c=n*Math.cos(i),u=c*c,h=this.es*o*o/(1-this.es);e=a*c*(1-u*l*(1/6-(8-l+8*h)*u/120)),r=this.a*re(this.e0,this.e1,this.e2,this.e3,i)-this.ml0+a*s/o*u*(.5+(5-l+6*h)*u/24)}return t.x=e+this.x0,t.y=r+this.y0,t},inverse:function(t){t.x-=this.x0,t.y-=this.y0;var e,r,n=t.x/this.a,i=t.y/this.a;if(this.sphere){var s=i+this.lat0;e=Math.asin(Math.sin(s)*Math.cos(n)),r=Math.atan2(Math.tan(n),Math.cos(s))}else{var l=ce(this.ml0/this.a+i,this.e0,this.e1,this.e2,this.e3);if(Math.abs(Math.abs(l)-o)<=a)return t.x=this.long0,t.y=o,i<0&&(t.y*=-1),t;var c=ae(this.a,this.e,Math.sin(l)),u=c*c*c/this.a/this.a*(1-this.es),h=Math.pow(Math.tan(l),2),d=n*this.a/c,f=d*d;e=l-c*Math.tan(l)/u*d*d*(.5-(1+3*h)*d*d/24),r=d*(1-f*(h/3+(1+3*h)*h*f/15))/Math.cos(l)}return t.x=F(r+this.long0),t.y=le(e),t},names:["Cassini","Cassini_Soldner","cass"]};function he(t,e){var r;return t>1e-7?(1-t*t)*(e/(1-(r=t*e)*r)-.5/t*Math.log((1-r)/(1+r))):2*e}const de={init:function(){var t,e=Math.abs(this.lat0);if(Math.abs(e-o)<a?this.mode=this.lat0<0?this.S_POLE:this.N_POLE:Math.abs(e)<a?this.mode=this.EQUIT:this.mode=this.OBLIQ,this.es>0)switch(this.qp=he(this.e,1),this.mmf=.5/(1-this.es),this.apa=function(t){var e,r=[];return r[0]=.3333333333333333*t,e=t*t,r[0]+=.17222222222222222*e,r[1]=.06388888888888888*e,e*=t,r[0]+=.10257936507936508*e,r[1]+=.0664021164021164*e,r[2]=.016415012942191543*e,r}(this.es),this.mode){case this.N_POLE:case this.S_POLE:this.dd=1;break;case this.EQUIT:this.rq=Math.sqrt(.5*this.qp),this.dd=1/this.rq,this.xmf=1,this.ymf=.5*this.qp;break;case this.OBLIQ:this.rq=Math.sqrt(.5*this.qp),t=Math.sin(this.lat0),this.sinb1=he(this.e,t)/this.qp,this.cosb1=Math.sqrt(1-this.sinb1*this.sinb1),this.dd=Math.cos(this.lat0)/(Math.sqrt(1-this.es*t*t)*this.rq*this.cosb1),this.ymf=(this.xmf=this.rq)/this.dd,this.xmf*=this.dd}else this.mode===this.OBLIQ&&(this.sinph0=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0))},forward:function(t){var e,r,n,i,s,l,c,h,d,f,p=t.x,m=t.y;if(p=F(p-this.long0),this.sphere){if(s=Math.sin(m),f=Math.cos(m),n=Math.cos(p),this.mode===this.OBLIQ||this.mode===this.EQUIT){if((r=this.mode===this.EQUIT?1+f*n:1+this.sinph0*s+this.cosph0*f*n)<=a)return null;e=(r=Math.sqrt(2/r))*f*Math.sin(p),r*=this.mode===this.EQUIT?s:this.cosph0*s-this.sinph0*f*n}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(n=-n),Math.abs(m+this.lat0)<a)return null;r=u-.5*m,e=(r=2*(this.mode===this.S_POLE?Math.cos(r):Math.sin(r)))*Math.sin(p),r*=n}}else{switch(c=0,h=0,d=0,n=Math.cos(p),i=Math.sin(p),s=Math.sin(m),l=he(this.e,s),this.mode!==this.OBLIQ&&this.mode!==this.EQUIT||(c=l/this.qp,h=Math.sqrt(1-c*c)),this.mode){case this.OBLIQ:d=1+this.sinb1*c+this.cosb1*h*n;break;case this.EQUIT:d=1+h*n;break;case this.N_POLE:d=o+m,l=this.qp-l;break;case this.S_POLE:d=m-o,l=this.qp+l}if(Math.abs(d)<a)return null;switch(this.mode){case this.OBLIQ:case this.EQUIT:d=Math.sqrt(2/d),r=this.mode===this.OBLIQ?this.ymf*d*(this.cosb1*c-this.sinb1*h*n):(d=Math.sqrt(2/(1+h*n)))*c*this.ymf,e=this.xmf*d*h*i;break;case this.N_POLE:case this.S_POLE:l>=0?(e=(d=Math.sqrt(l))*i,r=n*(this.mode===this.S_POLE?d:-d)):e=r=0}}return t.x=this.a*e+this.x0,t.y=this.a*r+this.y0,t},inverse:function(t){t.x-=this.x0,t.y-=this.y0;var e,r,n,i,s,l,c,u,h,d,f=t.x/this.a,p=t.y/this.a;if(this.sphere){var m,g=0,y=0;if((r=.5*(m=Math.sqrt(f*f+p*p)))>1)return null;switch(r=2*Math.asin(r),this.mode!==this.OBLIQ&&this.mode!==this.EQUIT||(y=Math.sin(r),g=Math.cos(r)),this.mode){case this.EQUIT:r=Math.abs(m)<=a?0:Math.asin(p*y/m),f*=y,p=g*m;break;case this.OBLIQ:r=Math.abs(m)<=a?this.lat0:Math.asin(g*this.sinph0+p*y*this.cosph0/m),f*=y*this.cosph0,p=(g-Math.sin(r)*this.sinph0)*m;break;case this.N_POLE:p=-p,r=o-r;break;case this.S_POLE:r-=o}e=0!==p||this.mode!==this.EQUIT&&this.mode!==this.OBLIQ?Math.atan2(f,p):0}else{if(c=0,this.mode===this.OBLIQ||this.mode===this.EQUIT){if(f/=this.dd,p*=this.dd,(l=Math.sqrt(f*f+p*p))<a)return t.x=this.long0,t.y=this.lat0,t;i=2*Math.asin(.5*l/this.rq),n=Math.cos(i),f*=i=Math.sin(i),this.mode===this.OBLIQ?(c=n*this.sinb1+p*i*this.cosb1/l,s=this.qp*c,p=l*this.cosb1*n-p*this.sinb1*i):(c=p*i/l,s=this.qp*c,p=l*n)}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(p=-p),!(s=f*f+p*p))return t.x=this.long0,t.y=this.lat0,t;c=1-s/this.qp,this.mode===this.S_POLE&&(c=-c)}e=Math.atan2(f,p),d=(u=Math.asin(c))+u,r=u+(h=this.apa)[0]*Math.sin(d)+h[1]*Math.sin(d+d)+h[2]*Math.sin(d+d+d)}return t.x=F(this.long0+e),t.y=r,t},names:["Lambert Azimuthal Equal Area","Lambert_Azimuthal_Equal_Area","laea"],S_POLE:1,N_POLE:2,EQUIT:3,OBLIQ:4};function fe(t){return Math.abs(t)>1&&(t=t>1?1:-1),Math.asin(t)}const pe={init:function(){Math.abs(this.lat1+this.lat2)<a||(this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e3=Math.sqrt(this.es),this.sin_po=Math.sin(this.lat1),this.cos_po=Math.cos(this.lat1),this.t1=this.sin_po,this.con=this.sin_po,this.ms1=k(this.e3,this.sin_po,this.cos_po),this.qs1=he(this.e3,this.sin_po),this.sin_po=Math.sin(this.lat2),this.cos_po=Math.cos(this.lat2),this.t2=this.sin_po,this.ms2=k(this.e3,this.sin_po,this.cos_po),this.qs2=he(this.e3,this.sin_po),this.sin_po=Math.sin(this.lat0),this.cos_po=Math.cos(this.lat0),this.t3=this.sin_po,this.qs0=he(this.e3,this.sin_po),Math.abs(this.lat1-this.lat2)>a?this.ns0=(this.ms1*this.ms1-this.ms2*this.ms2)/(this.qs2-this.qs1):this.ns0=this.con,this.c=this.ms1*this.ms1+this.ns0*this.qs1,this.rh=this.a*Math.sqrt(this.c-this.ns0*this.qs0)/this.ns0)},forward:function(t){var e=t.x,r=t.y;this.sin_phi=Math.sin(r),this.cos_phi=Math.cos(r);var n=he(this.e3,this.sin_phi),i=this.a*Math.sqrt(this.c-this.ns0*n)/this.ns0,s=this.ns0*F(e-this.long0),o=i*Math.sin(s)+this.x0,a=this.rh-i*Math.cos(s)+this.y0;return t.x=o,t.y=a,t},inverse:function(t){var e,r,n,i,s,o;return t.x-=this.x0,t.y=this.rh-t.y+this.y0,this.ns0>=0?(e=Math.sqrt(t.x*t.x+t.y*t.y),n=1):(e=-Math.sqrt(t.x*t.x+t.y*t.y),n=-1),i=0,0!==e&&(i=Math.atan2(n*t.x,n*t.y)),n=e*this.ns0/this.a,this.sphere?o=Math.asin((this.c-n*n)/(2*this.ns0)):(r=(this.c-n*n)/this.ns0,o=this.phi1z(this.e3,r)),s=F(i/this.ns0+this.long0),t.x=s,t.y=o,t},names:["Albers_Conic_Equal_Area","Albers","aea"],phi1z:function(t,e){var r,n,i,s,o=fe(.5*e);if(t<a)return o;for(var l=t*t,c=1;c<=25;c++)if(o+=s=.5*(i=1-(n=t*(r=Math.sin(o)))*n)*i/Math.cos(o)*(e/(1-l)-r/i+.5/t*Math.log((1-n)/(1+n))),Math.abs(s)<=1e-7)return o;return null}},me={init:function(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0),this.infinity_dist=1e3*this.a,this.rc=1},forward:function(t){var e,r,n,i,s,o,l,c=t.x,u=t.y;return n=F(c-this.long0),e=Math.sin(u),r=Math.cos(u),i=Math.cos(n),(s=this.sin_p14*e+this.cos_p14*r*i)>0||Math.abs(s)<=a?(o=this.x0+1*this.a*r*Math.sin(n)/s,l=this.y0+1*this.a*(this.cos_p14*e-this.sin_p14*r*i)/s):(o=this.x0+this.infinity_dist*r*Math.sin(n),l=this.y0+this.infinity_dist*(this.cos_p14*e-this.sin_p14*r*i)),t.x=o,t.y=l,t},inverse:function(t){var e,r,n,i,s,o;return t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,t.x/=this.k0,t.y/=this.k0,(e=Math.sqrt(t.x*t.x+t.y*t.y))?(i=Math.atan2(e,this.rc),r=Math.sin(i),o=fe((n=Math.cos(i))*this.sin_p14+t.y*r*this.cos_p14/e),s=Math.atan2(t.x*r,e*this.cos_p14*n-t.y*this.sin_p14*r),s=F(this.long0+s)):(o=this.phic0,s=0),t.x=s,t.y=o,t},names:["gnom"]},ge={init:function(){this.sphere||(this.k0=k(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)))},forward:function(t){var e,r,n=t.x,i=t.y,s=F(n-this.long0);if(this.sphere)e=this.x0+this.a*s*Math.cos(this.lat_ts),r=this.y0+this.a*Math.sin(i)/Math.cos(this.lat_ts);else{var o=he(this.e,Math.sin(i));e=this.x0+this.a*this.k0*s,r=this.y0+this.a*o*.5/this.k0}return t.x=e,t.y=r,t},inverse:function(t){var e,r;return t.x-=this.x0,t.y-=this.y0,this.sphere?(e=F(this.long0+t.x/this.a/Math.cos(this.lat_ts)),r=Math.asin(t.y/this.a*Math.cos(this.lat_ts))):(r=function(t,e){var r=1-(1-t*t)/(2*t)*Math.log((1-t)/(1+t));if(Math.abs(Math.abs(e)-r)<1e-6)return e<0?-1*o:o;for(var n,i,s,a,l=Math.asin(.5*e),c=0;c<30;c++)if(i=Math.sin(l),s=Math.cos(l),a=t*i,l+=n=Math.pow(1-a*a,2)/(2*s)*(e/(1-t*t)-i/(1-a*a)+.5/t*Math.log((1-a)/(1+a))),Math.abs(n)<=1e-10)return l;return NaN}(this.e,2*t.y*this.k0/this.a),e=F(this.long0+t.x/(this.a*this.k0))),t.x=e,t.y=r,t},names:["cea"]},ye={init:function(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Equidistant Cylindrical (Plate Carre)",this.rc=Math.cos(this.lat_ts)},forward:function(t){var e=t.x,r=t.y,n=F(e-this.long0),i=le(r-this.lat0);return t.x=this.x0+this.a*n*this.rc,t.y=this.y0+this.a*i,t},inverse:function(t){var e=t.x,r=t.y;return t.x=F(this.long0+(e-this.x0)/(this.a*this.rc)),t.y=le(this.lat0+(r-this.y0)/this.a),t},names:["Equirectangular","Equidistant_Cylindrical","eqc"]},ve={init:function(){this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=ne(this.es),this.e1=ie(this.es),this.e2=se(this.es),this.e3=oe(this.es),this.ml0=this.a*re(this.e0,this.e1,this.e2,this.e3,this.lat0)},forward:function(t){var e,r,n,i=t.x,s=t.y,o=F(i-this.long0);if(n=o*Math.sin(s),this.sphere)Math.abs(s)<=a?(e=this.a*o,r=-1*this.a*this.lat0):(e=this.a*Math.sin(n)/Math.tan(s),r=this.a*(le(s-this.lat0)+(1-Math.cos(n))/Math.tan(s)));else if(Math.abs(s)<=a)e=this.a*o,r=-1*this.ml0;else{var l=ae(this.a,this.e,Math.sin(s))/Math.tan(s);e=l*Math.sin(n),r=this.a*re(this.e0,this.e1,this.e2,this.e3,s)-this.ml0+l*(1-Math.cos(n))}return t.x=e+this.x0,t.y=r+this.y0,t},inverse:function(t){var e,r,n,i,s,o,l,c,u;if(n=t.x-this.x0,i=t.y-this.y0,this.sphere)if(Math.abs(i+this.a*this.lat0)<=a)e=F(n/this.a+this.long0),r=0;else{var h;for(o=this.lat0+i/this.a,l=n*n/this.a/this.a+o*o,c=o,s=20;s;--s)if(c+=u=-1*(o*(c*(h=Math.tan(c))+1)-c-.5*(c*c+l)*h)/((c-o)/h-1),Math.abs(u)<=a){r=c;break}e=F(this.long0+Math.asin(n*Math.tan(c)/this.a)/Math.sin(r))}else if(Math.abs(i+this.ml0)<=a)r=0,e=F(this.long0+n/this.a);else{var d,f,p,m,g;for(o=(this.ml0+i)/this.a,l=n*n/this.a/this.a+o*o,c=o,s=20;s;--s)if(g=this.e*Math.sin(c),d=Math.sqrt(1-g*g)*Math.tan(c),f=this.a*re(this.e0,this.e1,this.e2,this.e3,c),p=this.e0-2*this.e1*Math.cos(2*c)+4*this.e2*Math.cos(4*c)-6*this.e3*Math.cos(6*c),c-=u=(o*(d*(m=f/this.a)+1)-m-.5*d*(m*m+l))/(this.es*Math.sin(2*c)*(m*m+l-2*o*m)/(4*d)+(o-m)*(d*p-2/Math.sin(2*c))-p),Math.abs(u)<=a){r=c;break}d=Math.sqrt(1-this.es*Math.pow(Math.sin(r),2))*Math.tan(r),e=F(this.long0+Math.asin(n*d/this.a)/Math.sin(r))}return t.x=e,t.y=r,t},names:["Polyconic","poly"]},_e={init:function(){this.A=[],this.A[1]=.6399175073,this.A[2]=-.1358797613,this.A[3]=.063294409,this.A[4]=-.02526853,this.A[5]=.0117879,this.A[6]=-.0055161,this.A[7]=.0026906,this.A[8]=-.001333,this.A[9]=67e-5,this.A[10]=-34e-5,this.B_re=[],this.B_im=[],this.B_re[1]=.7557853228,this.B_im[1]=0,this.B_re[2]=.249204646,this.B_im[2]=.003371507,this.B_re[3]=-.001541739,this.B_im[3]=.04105856,this.B_re[4]=-.10162907,this.B_im[4]=.01727609,this.B_re[5]=-.26623489,this.B_im[5]=-.36249218,this.B_re[6]=-.6870983,this.B_im[6]=-1.1651967,this.C_re=[],this.C_im=[],this.C_re[1]=1.3231270439,this.C_im[1]=0,this.C_re[2]=-.577245789,this.C_im[2]=-.007809598,this.C_re[3]=.508307513,this.C_im[3]=-.112208952,this.C_re[4]=-.15094762,this.C_im[4]=.18200602,this.C_re[5]=1.01418179,this.C_im[5]=1.64497696,this.C_re[6]=1.9660549,this.C_im[6]=2.5127645,this.D=[],this.D[1]=1.5627014243,this.D[2]=.5185406398,this.D[3]=-.03333098,this.D[4]=-.1052906,this.D[5]=-.0368594,this.D[6]=.007317,this.D[7]=.0122,this.D[8]=.00394,this.D[9]=-.0013},forward:function(t){var e,r=t.x,n=t.y-this.lat0,i=r-this.long0,o=n/s*1e-5,a=i,l=1,c=0;for(e=1;e<=10;e++)l*=o,c+=this.A[e]*l;var u,h=c,d=a,f=1,p=0,m=0,g=0;for(e=1;e<=6;e++)u=p*h+f*d,f=f*h-p*d,p=u,m=m+this.B_re[e]*f-this.B_im[e]*p,g=g+this.B_im[e]*f+this.B_re[e]*p;return t.x=g*this.a+this.x0,t.y=m*this.a+this.y0,t},inverse:function(t){var e,r,n=t.x,i=t.y,o=n-this.x0,a=(i-this.y0)/this.a,l=o/this.a,c=1,u=0,h=0,d=0;for(e=1;e<=6;e++)r=u*a+c*l,c=c*a-u*l,u=r,h=h+this.C_re[e]*c-this.C_im[e]*u,d=d+this.C_im[e]*c+this.C_re[e]*u;for(var f=0;f<this.iterations;f++){var p,m=h,g=d,y=a,v=l;for(e=2;e<=6;e++)p=g*h+m*d,m=m*h-g*d,g=p,y+=(e-1)*(this.B_re[e]*m-this.B_im[e]*g),v+=(e-1)*(this.B_im[e]*m+this.B_re[e]*g);m=1,g=0;var _=this.B_re[1],b=this.B_im[1];for(e=2;e<=6;e++)p=g*h+m*d,m=m*h-g*d,g=p,_+=e*(this.B_re[e]*m-this.B_im[e]*g),b+=e*(this.B_im[e]*m+this.B_re[e]*g);var w=_*_+b*b;h=(y*_+v*b)/w,d=(v*_-y*b)/w}var x=h,E=d,S=1,A=0;for(e=1;e<=9;e++)S*=x,A+=this.D[e]*S;var P=this.lat0+A*s*1e5,T=this.long0+E;return t.x=T,t.y=P,t},names:["New_Zealand_Map_Grid","nzmg"]},be={init:function(){},forward:function(t){var e=t.x,r=t.y,n=F(e-this.long0),i=this.x0+this.a*n,s=this.y0+this.a*Math.log(Math.tan(Math.PI/4+r/2.5))*1.25;return t.x=i,t.y=s,t},inverse:function(t){t.x-=this.x0,t.y-=this.y0;var e=F(this.long0+t.x/this.a),r=2.5*(Math.atan(Math.exp(.8*t.y/this.a))-Math.PI/4);return t.x=e,t.y=r,t},names:["Miller_Cylindrical","mill"]},we={init:function(){this.sphere?(this.n=1,this.m=0,this.es=0,this.C_y=Math.sqrt((this.m+1)/this.n),this.C_x=this.C_y/(this.m+1)):this.en=jt(this.es)},forward:function(t){var e,r,n=t.x,i=t.y;if(n=F(n-this.long0),this.sphere){if(this.m)for(var s=this.n*Math.sin(i),o=20;o;--o){var l=(this.m*i+Math.sin(i)-s)/(this.m+Math.cos(i));if(i-=l,Math.abs(l)<a)break}else i=1!==this.n?Math.asin(this.n*Math.sin(i)):i;e=this.a*this.C_x*n*(this.m+Math.cos(i)),r=this.a*this.C_y*i}else{var c=Math.sin(i),u=Math.cos(i);r=this.a*Nt(i,c,u,this.en),e=this.a*n*u/Math.sqrt(1-this.es*c*c)}return t.x=e,t.y=r,t},inverse:function(t){var e,r,n;return t.x-=this.x0,r=t.x/this.a,t.y-=this.y0,e=t.y/this.a,this.sphere?(e/=this.C_y,r/=this.C_x*(this.m+Math.cos(e)),this.m?e=fe((this.m*e+Math.sin(e))/this.n):1!==this.n&&(e=fe(Math.sin(e)/this.n)),r=F(r+this.long0),e=le(e)):(e=Gt(t.y/this.a,this.es,this.en),(n=Math.abs(e))<o?(n=Math.sin(e),r=F(this.long0+t.x*Math.sqrt(1-this.es*n*n)/(this.a*Math.cos(e)))):n-a<o&&(r=this.long0)),t.x=r,t.y=e,t},names:["Sinusoidal","sinu"]},xe={init:function(){},forward:function(t){for(var e=t.x,r=t.y,n=F(e-this.long0),i=r,s=Math.PI*Math.sin(r);;){var o=-(i+Math.sin(i)-s)/(1+Math.cos(i));if(i+=o,Math.abs(o)<a)break}i/=2,Math.PI/2-Math.abs(r)<a&&(n=0);var l=.900316316158*this.a*n*Math.cos(i)+this.x0,c=1.4142135623731*this.a*Math.sin(i)+this.y0;return t.x=l,t.y=c,t},inverse:function(t){var e,r;t.x-=this.x0,t.y-=this.y0,r=t.y/(1.4142135623731*this.a),Math.abs(r)>.999999999999&&(r=.999999999999),e=Math.asin(r);var n=F(this.long0+t.x/(.900316316158*this.a*Math.cos(e)));n<-Math.PI&&(n=-Math.PI),n>Math.PI&&(n=Math.PI),r=(2*e+Math.sin(2*e))/Math.PI,Math.abs(r)>1&&(r=1);var i=Math.asin(r);return t.x=n,t.y=i,t},names:["Mollweide","moll"]},Ee={init:function(){Math.abs(this.lat1+this.lat2)<a||(this.lat2=this.lat2||this.lat1,this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=ne(this.es),this.e1=ie(this.es),this.e2=se(this.es),this.e3=oe(this.es),this.sinphi=Math.sin(this.lat1),this.cosphi=Math.cos(this.lat1),this.ms1=k(this.e,this.sinphi,this.cosphi),this.ml1=re(this.e0,this.e1,this.e2,this.e3,this.lat1),Math.abs(this.lat1-this.lat2)<a?this.ns=this.sinphi:(this.sinphi=Math.sin(this.lat2),this.cosphi=Math.cos(this.lat2),this.ms2=k(this.e,this.sinphi,this.cosphi),this.ml2=re(this.e0,this.e1,this.e2,this.e3,this.lat2),this.ns=(this.ms1-this.ms2)/(this.ml2-this.ml1)),this.g=this.ml1+this.ms1/this.ns,this.ml0=re(this.e0,this.e1,this.e2,this.e3,this.lat0),this.rh=this.a*(this.g-this.ml0))},forward:function(t){var e,r=t.x,n=t.y;if(this.sphere)e=this.a*(this.g-n);else{var i=re(this.e0,this.e1,this.e2,this.e3,n);e=this.a*(this.g-i)}var s=this.ns*F(r-this.long0),o=this.x0+e*Math.sin(s),a=this.y0+this.rh-e*Math.cos(s);return t.x=o,t.y=a,t},inverse:function(t){var e,r,n,i;t.x-=this.x0,t.y=this.rh-t.y+this.y0,this.ns>=0?(r=Math.sqrt(t.x*t.x+t.y*t.y),e=1):(r=-Math.sqrt(t.x*t.x+t.y*t.y),e=-1);var s=0;return 0!==r&&(s=Math.atan2(e*t.x,e*t.y)),this.sphere?(i=F(this.long0+s/this.ns),n=le(this.g-r/this.a),t.x=i,t.y=n,t):(n=ce(this.g-r/this.a,this.e0,this.e1,this.e2,this.e3),i=F(this.long0+s/this.ns),t.x=i,t.y=n,t)},names:["Equidistant_Conic","eqdc"]},Se={init:function(){this.R=this.a},forward:function(t){var e,r,n=t.x,i=t.y,s=F(n-this.long0);Math.abs(i)<=a&&(e=this.x0+this.R*s,r=this.y0);var l=fe(2*Math.abs(i/Math.PI));(Math.abs(s)<=a||Math.abs(Math.abs(i)-o)<=a)&&(e=this.x0,r=i>=0?this.y0+Math.PI*this.R*Math.tan(.5*l):this.y0+Math.PI*this.R*-Math.tan(.5*l));var c=.5*Math.abs(Math.PI/s-s/Math.PI),u=c*c,h=Math.sin(l),d=Math.cos(l),f=d/(h+d-1),p=f*f,m=f*(2/h-1),g=m*m,y=Math.PI*this.R*(c*(f-g)+Math.sqrt(u*(f-g)*(f-g)-(g+u)*(p-g)))/(g+u);s<0&&(y=-y),e=this.x0+y;var v=u+f;return y=Math.PI*this.R*(m*v-c*Math.sqrt((g+u)*(u+1)-v*v))/(g+u),r=i>=0?this.y0+y:this.y0-y,t.x=e,t.y=r,t},inverse:function(t){var e,r,n,i,s,o,l,c,u,h,d,f;return t.x-=this.x0,t.y-=this.y0,d=Math.PI*this.R,s=(n=t.x/d)*n+(i=t.y/d)*i,d=3*(i*i/(c=-2*(o=-Math.abs(i)*(1+s))+1+2*i*i+s*s)+(2*(l=o-2*i*i+n*n)*l*l/c/c/c-9*o*l/c/c)/27)/(u=(o-l*l/3/c)/c)/(h=2*Math.sqrt(-u/3)),Math.abs(d)>1&&(d=d>=0?1:-1),f=Math.acos(d)/3,r=t.y>=0?(-h*Math.cos(f+Math.PI/3)-l/3/c)*Math.PI:-(-h*Math.cos(f+Math.PI/3)-l/3/c)*Math.PI,e=Math.abs(n)<a?this.long0:F(this.long0+Math.PI*(s-1+Math.sqrt(1+2*(n*n-i*i)+s*s))/2/n),t.x=e,t.y=r,t},names:["Van_der_Grinten_I","VanDerGrinten","vandg"]},Ae={init:function(){this.sin_p12=Math.sin(this.lat0),this.cos_p12=Math.cos(this.lat0)},forward:function(t){var e,r,n,i,s,l,c,u,h,d,f,p,m,g,y,v,_,b,w,x,E,S,A=t.x,P=t.y,T=Math.sin(t.y),C=Math.cos(t.y),M=F(A-this.long0);return this.sphere?Math.abs(this.sin_p12-1)<=a?(t.x=this.x0+this.a*(o-P)*Math.sin(M),t.y=this.y0-this.a*(o-P)*Math.cos(M),t):Math.abs(this.sin_p12+1)<=a?(t.x=this.x0+this.a*(o+P)*Math.sin(M),t.y=this.y0+this.a*(o+P)*Math.cos(M),t):(b=this.sin_p12*T+this.cos_p12*C*Math.cos(M),_=(v=Math.acos(b))?v/Math.sin(v):1,t.x=this.x0+this.a*_*C*Math.sin(M),t.y=this.y0+this.a*_*(this.cos_p12*T-this.sin_p12*C*Math.cos(M)),t):(e=ne(this.es),r=ie(this.es),n=se(this.es),i=oe(this.es),Math.abs(this.sin_p12-1)<=a?(s=this.a*re(e,r,n,i,o),l=this.a*re(e,r,n,i,P),t.x=this.x0+(s-l)*Math.sin(M),t.y=this.y0-(s-l)*Math.cos(M),t):Math.abs(this.sin_p12+1)<=a?(s=this.a*re(e,r,n,i,o),l=this.a*re(e,r,n,i,P),t.x=this.x0+(s+l)*Math.sin(M),t.y=this.y0+(s+l)*Math.cos(M),t):(c=T/C,u=ae(this.a,this.e,this.sin_p12),h=ae(this.a,this.e,T),d=Math.atan((1-this.es)*c+this.es*u*this.sin_p12/(h*C)),w=0===(f=Math.atan2(Math.sin(M),this.cos_p12*Math.tan(d)-this.sin_p12*Math.cos(M)))?Math.asin(this.cos_p12*Math.sin(d)-this.sin_p12*Math.cos(d)):Math.abs(Math.abs(f)-Math.PI)<=a?-Math.asin(this.cos_p12*Math.sin(d)-this.sin_p12*Math.cos(d)):Math.asin(Math.sin(M)*Math.cos(d)/Math.sin(f)),p=this.e*this.sin_p12/Math.sqrt(1-this.es),v=u*w*(1-(x=w*w)*(y=(m=this.e*this.cos_p12*Math.cos(f)/Math.sqrt(1-this.es))*m)*(1-y)/6+(E=x*w)/8*(g=p*m)*(1-2*y)+(S=E*w)/120*(y*(4-7*y)-3*p*p*(1-7*y))-S*w/48*g),t.x=this.x0+v*Math.sin(f),t.y=this.y0+v*Math.cos(f),t))},inverse:function(t){var e,r,n,i,s,l,c,u,h,d,f,p,m,g,y,v,_,b,w,x,E,S,A;if(t.x-=this.x0,t.y-=this.y0,this.sphere){if((e=Math.sqrt(t.x*t.x+t.y*t.y))>2*o*this.a)return;return r=e/this.a,n=Math.sin(r),i=Math.cos(r),s=this.long0,Math.abs(e)<=a?l=this.lat0:(l=fe(i*this.sin_p12+t.y*n*this.cos_p12/e),c=Math.abs(this.lat0)-o,s=Math.abs(c)<=a?this.lat0>=0?F(this.long0+Math.atan2(t.x,-t.y)):F(this.long0-Math.atan2(-t.x,t.y)):F(this.long0+Math.atan2(t.x*n,e*this.cos_p12*i-t.y*this.sin_p12*n))),t.x=s,t.y=l,t}return u=ne(this.es),h=ie(this.es),d=se(this.es),f=oe(this.es),Math.abs(this.sin_p12-1)<=a?(l=ce(((p=this.a*re(u,h,d,f,o))-(e=Math.sqrt(t.x*t.x+t.y*t.y)))/this.a,u,h,d,f),s=F(this.long0+Math.atan2(t.x,-1*t.y)),t.x=s,t.y=l,t):Math.abs(this.sin_p12+1)<=a?(p=this.a*re(u,h,d,f,o),l=ce(((e=Math.sqrt(t.x*t.x+t.y*t.y))-p)/this.a,u,h,d,f),s=F(this.long0+Math.atan2(t.x,t.y)),t.x=s,t.y=l,t):(e=Math.sqrt(t.x*t.x+t.y*t.y),y=Math.atan2(t.x,t.y),m=ae(this.a,this.e,this.sin_p12),v=Math.cos(y),b=-(_=this.e*this.cos_p12*v)*_/(1-this.es),w=3*this.es*(1-b)*this.sin_p12*this.cos_p12*v/(1-this.es),S=1-b*(E=(x=e/m)-b*(1+b)*Math.pow(x,3)/6-w*(1+3*b)*Math.pow(x,4)/24)*E/2-x*E*E*E/6,g=Math.asin(this.sin_p12*Math.cos(E)+this.cos_p12*Math.sin(E)*v),s=F(this.long0+Math.asin(Math.sin(y)*Math.sin(E)/Math.cos(g))),A=Math.sin(g),l=Math.atan2((A-this.es*S*this.sin_p12)*Math.tan(g),A*(1-this.es)),t.x=s,t.y=l,t)},names:["Azimuthal_Equidistant","aeqd"]},Pe={init:function(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0)},forward:function(t){var e,r,n,i,s,o,l,c=t.x,u=t.y;return n=F(c-this.long0),e=Math.sin(u),r=Math.cos(u),i=Math.cos(n),((s=this.sin_p14*e+this.cos_p14*r*i)>0||Math.abs(s)<=a)&&(o=1*this.a*r*Math.sin(n),l=this.y0+1*this.a*(this.cos_p14*e-this.sin_p14*r*i)),t.x=o,t.y=l,t},inverse:function(t){var e,r,n,i,s,l,c;return t.x-=this.x0,t.y-=this.y0,r=fe((e=Math.sqrt(t.x*t.x+t.y*t.y))/this.a),n=Math.sin(r),i=Math.cos(r),l=this.long0,Math.abs(e)<=a?(c=this.lat0,t.x=l,t.y=c,t):(c=fe(i*this.sin_p14+t.y*n*this.cos_p14/e),s=Math.abs(this.lat0)-o,Math.abs(s)<=a?(l=this.lat0>=0?F(this.long0+Math.atan2(t.x,-t.y)):F(this.long0-Math.atan2(-t.x,t.y)),t.x=l,t.y=c,t):(l=F(this.long0+Math.atan2(t.x*n,e*this.cos_p14*i-t.y*this.sin_p14*n)),t.x=l,t.y=c,t))},names:["ortho"]};function Te(t,e,r,n){var i;return t<a?(n.value=1,i=0):(i=Math.atan2(e,r),Math.abs(i)<=u?n.value=1:i>u&&i<=o+u?(n.value=2,i-=o):i>o+u||i<=-(o+u)?(n.value=3,i=i>=0?i-d:i+d):(n.value=4,i+=o)),i}function Ce(t,e){var r=t+e;return r<-d?r+=h:r>+d&&(r-=h),r}const Me={init:function(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Quadrilateralized Spherical Cube",this.lat0>=o-u/2?this.face=5:this.lat0<=-(o-u/2)?this.face=6:Math.abs(this.long0)<=u?this.face=1:Math.abs(this.long0)<=o+u?this.face=this.long0>0?2:4:this.face=3,0!==this.es&&(this.one_minus_f=1-(this.a-this.b)/this.a,this.one_minus_f_squared=this.one_minus_f*this.one_minus_f)},forward:function(t){var e,r,n,i,s,a,l={x:0,y:0},c={value:0};if(t.x-=this.long0,e=0!==this.es?Math.atan(this.one_minus_f_squared*Math.tan(t.y)):t.y,r=t.x,5===this.face)i=o-e,r>=u&&r<=o+u?(c.value=1,n=r-o):r>o+u||r<=-(o+u)?(c.value=2,n=r>0?r-d:r+d):r>-(o+u)&&r<=-u?(c.value=3,n=r+o):(c.value=4,n=r);else if(6===this.face)i=o+e,r>=u&&r<=o+u?(c.value=1,n=-r+o):r<u&&r>=-u?(c.value=2,n=-r):r<-u&&r>=-(o+u)?(c.value=3,n=-r-o):(c.value=4,n=r>0?-r+d:-r-d);else{var h,f,p,m,g,y;2===this.face?r=Ce(r,+o):3===this.face?r=Ce(r,+d):4===this.face&&(r=Ce(r,-o)),m=Math.sin(e),g=Math.cos(e),y=Math.sin(r),h=g*Math.cos(r),f=g*y,p=m,1===this.face?n=Te(i=Math.acos(h),p,f,c):2===this.face?n=Te(i=Math.acos(f),p,-h,c):3===this.face?n=Te(i=Math.acos(-h),p,-f,c):4===this.face?n=Te(i=Math.acos(-f),p,h,c):(i=n=0,c.value=1)}return a=Math.atan(12/d*(n+Math.acos(Math.sin(n)*Math.cos(u))-o)),s=Math.sqrt((1-Math.cos(i))/(Math.cos(a)*Math.cos(a))/(1-Math.cos(Math.atan(1/Math.cos(n))))),2===c.value?a+=o:3===c.value?a+=d:4===c.value&&(a+=1.5*d),l.x=s*Math.cos(a),l.y=s*Math.sin(a),l.x=l.x*this.a+this.x0,l.y=l.y*this.a+this.y0,t.x=l.x,t.y=l.y,t},inverse:function(t){var e,r,n,i,s,a,l,c,u,h,f,p,m={lam:0,phi:0},g={value:0};if(t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a,r=Math.atan(Math.sqrt(t.x*t.x+t.y*t.y)),e=Math.atan2(t.y,t.x),t.x>=0&&t.x>=Math.abs(t.y)?g.value=1:t.y>=0&&t.y>=Math.abs(t.x)?(g.value=2,e-=o):t.x<0&&-t.x>=Math.abs(t.y)?(g.value=3,e=e<0?e+d:e-d):(g.value=4,e+=o),u=d/12*Math.tan(e),s=Math.sin(u)/(Math.cos(u)-1/Math.sqrt(2)),a=Math.atan(s),(l=1-(n=Math.cos(e))*n*(i=Math.tan(r))*i*(1-Math.cos(Math.atan(1/Math.cos(a)))))<-1?l=-1:l>1&&(l=1),5===this.face)c=Math.acos(l),m.phi=o-c,1===g.value?m.lam=a+o:2===g.value?m.lam=a<0?a+d:a-d:3===g.value?m.lam=a-o:m.lam=a;else if(6===this.face)c=Math.acos(l),m.phi=c-o,1===g.value?m.lam=-a+o:2===g.value?m.lam=-a:3===g.value?m.lam=-a-o:m.lam=a<0?-a-d:-a+d;else{var y,v,_;u=(y=l)*y,v=(u+=(_=u>=1?0:Math.sqrt(1-u)*Math.sin(a))*_)>=1?0:Math.sqrt(1-u),2===g.value?(u=v,v=-_,_=u):3===g.value?(v=-v,_=-_):4===g.value&&(u=v,v=_,_=-u),2===this.face?(u=y,y=-v,v=u):3===this.face?(y=-y,v=-v):4===this.face&&(u=y,y=v,v=-u),m.phi=Math.acos(-_)-o,m.lam=Math.atan2(v,y),2===this.face?m.lam=Ce(m.lam,-o):3===this.face?m.lam=Ce(m.lam,-d):4===this.face&&(m.lam=Ce(m.lam,+o))}return 0!==this.es&&(h=m.phi<0?1:0,f=Math.tan(m.phi),p=this.b/Math.sqrt(f*f+this.one_minus_f_squared),m.phi=Math.atan(Math.sqrt(this.a*this.a-p*p)/(this.one_minus_f*p)),h&&(m.phi=-m.phi)),m.lam+=this.long0,t.x=m.lam,t.y=m.phi,t},names:["Quadrilateralized Spherical Cube","Quadrilateralized_Spherical_Cube","qsc"]};var Oe=[[1,22199e-21,-715515e-10,31103e-10],[.9986,-482243e-9,-24897e-9,-13309e-10],[.9954,-83103e-8,-448605e-10,-9.86701e-7],[.99,-.00135364,-59661e-9,36777e-10],[.9822,-.00167442,-449547e-11,-572411e-11],[.973,-.00214868,-903571e-10,1.8736e-8],[.96,-.00305085,-900761e-10,164917e-11],[.9427,-.00382792,-653386e-10,-26154e-10],[.9216,-.00467746,-10457e-8,481243e-11],[.8962,-.00536223,-323831e-10,-543432e-11],[.8679,-.00609363,-113898e-9,332484e-11],[.835,-.00698325,-640253e-10,9.34959e-7],[.7986,-.00755338,-500009e-10,9.35324e-7],[.7597,-.00798324,-35971e-9,-227626e-11],[.7186,-.00851367,-701149e-10,-86303e-10],[.6732,-.00986209,-199569e-9,191974e-10],[.6213,-.010418,883923e-10,624051e-11],[.5722,-.00906601,182e-6,624051e-11],[.5322,-.00677797,275608e-9,624051e-11]],Re=[[-520417e-23,.0124,121431e-23,-845284e-16],[.062,.0124,-1.26793e-9,4.22642e-10],[.124,.0124,5.07171e-9,-1.60604e-9],[.186,.0123999,-1.90189e-8,6.00152e-9],[.248,.0124002,7.10039e-8,-2.24e-8],[.31,.0123992,-2.64997e-7,8.35986e-8],[.372,.0124029,9.88983e-7,-3.11994e-7],[.434,.0123893,-369093e-11,-4.35621e-7],[.4958,.0123198,-102252e-10,-3.45523e-7],[.5571,.0121916,-154081e-10,-5.82288e-7],[.6176,.0119938,-241424e-10,-5.25327e-7],[.6769,.011713,-320223e-10,-5.16405e-7],[.7346,.0113541,-397684e-10,-6.09052e-7],[.7903,.0109107,-489042e-10,-104739e-11],[.8435,.0103431,-64615e-9,-1.40374e-9],[.8936,.00969686,-64636e-9,-8547e-9],[.9394,.00840947,-192841e-9,-42106e-10],[.9761,.00616527,-256e-6,-42106e-10],[1,.00328947,-319159e-9,-42106e-10]],De=.8487,Ie=1.3523,ke=c/5,Le=1/ke,Fe=function(t,e){return t[0]+e*(t[1]+e*(t[2]+e*t[3]))};const je={init:function(){this.x0=this.x0||0,this.y0=this.y0||0,this.long0=this.long0||0,this.es=0,this.title=this.title||"Robinson"},forward:function(t){var e=F(t.x-this.long0),r=Math.abs(t.y),n=Math.floor(r*ke);n<0?n=0:n>=18&&(n=17);var i={x:Fe(Oe[n],r=c*(r-Le*n))*e,y:Fe(Re[n],r)};return t.y<0&&(i.y=-i.y),i.x=i.x*this.a*De+this.x0,i.y=i.y*this.a*Ie+this.y0,i},inverse:function(t){var e={x:(t.x-this.x0)/(this.a*De),y:Math.abs(t.y-this.y0)/(this.a*Ie)};if(e.y>=1)e.x/=Oe[18][0],e.y=t.y<0?-o:o;else{var r=Math.floor(18*e.y);for(r<0?r=0:r>=18&&(r=17);;)if(Re[r][0]>e.y)--r;else{if(!(Re[r+1][0]<=e.y))break;++r}var n=Re[r],i=5*(e.y-n[0])/(Re[r+1][0]-n[0]);i=function(t,e,r,n){for(var i=e;n;--n){var s=t(i);if(i-=s,Math.abs(s)<1e-10)break}return i}((function(t){return(Fe(n,t)-e.y)/function(t,e){return t[1]+e*(2*t[2]+3*e*t[3])}(n,t)}),i,0,100),e.x/=Fe(Oe[r],i),e.y=(5*r+i)*l,t.y<0&&(e.y=-e.y)}return e.x=F(e.x+this.long0),e},names:["Robinson","robin"]},Ne={init:function(){this.name="geocent"},forward:function(t){return it(t,this.es,this.a)},inverse:function(t){return st(t,this.es,this.a,this.b)},names:["Geocentric","geocentric","geocent","Geocent"]};var Ge={h:{def:1e5,num:!0},azi:{def:0,num:!0,degrees:!0},tilt:{def:0,num:!0,degrees:!0},long0:{def:0,num:!0},lat0:{def:0,num:!0}};const $e={init:function(){if(Object.keys(Ge).forEach(function(t){if(void 0===this[t])this[t]=Ge[t].def;else{if(Ge[t].num&&isNaN(this[t]))throw new Error("Invalid parameter value, must be numeric "+t+" = "+this[t]);Ge[t].num&&(this[t]=parseFloat(this[t]))}Ge[t].degrees&&(this[t]=this[t]*l)}.bind(this)),Math.abs(Math.abs(this.lat0)-o)<a?this.mode=this.lat0<0?1:0:Math.abs(this.lat0)<a?this.mode=2:(this.mode=3,this.sinph0=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0)),this.pn1=this.h/this.a,this.pn1<=0||this.pn1>1e10)throw new Error("Invalid height");this.p=1+this.pn1,this.rp=1/this.p,this.h1=1/this.pn1,this.pfact=(this.p+1)*this.h1,this.es=0;var t=this.tilt,e=this.azi;this.cg=Math.cos(e),this.sg=Math.sin(e),this.cw=Math.cos(t),this.sw=Math.sin(t)},forward:function(t){t.x-=this.long0;var e,r,n,i,s=Math.sin(t.y),o=Math.cos(t.y),a=Math.cos(t.x);switch(this.mode){case 3:r=this.sinph0*s+this.cosph0*o*a;break;case 2:r=o*a;break;case 1:r=-s;break;case 0:r=s}switch(e=(r=this.pn1/(this.p-r))*o*Math.sin(t.x),this.mode){case 3:r*=this.cosph0*s-this.sinph0*o*a;break;case 2:r*=s;break;case 0:r*=-o*a;break;case 1:r*=o*a}return i=1/((n=r*this.cg+e*this.sg)*this.sw*this.h1+this.cw),e=(e*this.cg-r*this.sg)*this.cw*i,r=n*i,t.x=e*this.a,t.y=r*this.a,t},inverse:function(t){t.x/=this.a,t.y/=this.a;var e,r,n,i={x:t.x,y:t.y};n=1/(this.pn1-t.y*this.sw),e=this.pn1*t.x*n,r=this.pn1*t.y*this.cw*n,t.x=e*this.cg+r*this.sg,t.y=r*this.cg-e*this.sg;var s=Ut(t.x,t.y);if(Math.abs(s)<a)i.x=0,i.y=t.y;else{var o,l;switch(l=1-s*s*this.pfact,l=(this.p-Math.sqrt(l))/(this.pn1/s+s/this.pn1),o=Math.sqrt(1-l*l),this.mode){case 3:i.y=Math.asin(o*this.sinph0+t.y*l*this.cosph0/s),t.y=(o-this.sinph0*Math.sin(i.y))*s,t.x*=l*this.cosph0;break;case 2:i.y=Math.asin(t.y*l/s),t.y=o*s,t.x*=l;break;case 0:i.y=Math.asin(o),t.y=-t.y;break;case 1:i.y=-Math.asin(o)}i.x=Math.atan2(t.x,t.y)}return t.x=i.x+this.long0,t.y=i.y,t},names:["Tilted_Perspective","tpers"]},ze={init:function(){if(this.flip_axis="x"===this.sweep?1:0,this.h=Number(this.h),this.radius_g_1=this.h/this.a,this.radius_g_1<=0||this.radius_g_1>1e10)throw new Error;if(this.radius_g=1+this.radius_g_1,this.C=this.radius_g*this.radius_g-1,0!==this.es){var t=1-this.es,e=1/t;this.radius_p=Math.sqrt(t),this.radius_p2=t,this.radius_p_inv2=e,this.shape="ellipse"}else this.radius_p=1,this.radius_p2=1,this.radius_p_inv2=1,this.shape="sphere";this.title||(this.title="Geostationary Satellite View")},forward:function(t){var e,r,n,i,s=t.x,o=t.y;if(s-=this.long0,"ellipse"===this.shape){o=Math.atan(this.radius_p2*Math.tan(o));var a=this.radius_p/Ut(this.radius_p*Math.cos(o),Math.sin(o));if(r=a*Math.cos(s)*Math.cos(o),n=a*Math.sin(s)*Math.cos(o),i=a*Math.sin(o),(this.radius_g-r)*r-n*n-i*i*this.radius_p_inv2<0)return t.x=Number.NaN,t.y=Number.NaN,t;e=this.radius_g-r,this.flip_axis?(t.x=this.radius_g_1*Math.atan(n/Ut(i,e)),t.y=this.radius_g_1*Math.atan(i/e)):(t.x=this.radius_g_1*Math.atan(n/e),t.y=this.radius_g_1*Math.atan(i/Ut(n,e)))}else"sphere"===this.shape&&(e=Math.cos(o),r=Math.cos(s)*e,n=Math.sin(s)*e,i=Math.sin(o),e=this.radius_g-r,this.flip_axis?(t.x=this.radius_g_1*Math.atan(n/Ut(i,e)),t.y=this.radius_g_1*Math.atan(i/e)):(t.x=this.radius_g_1*Math.atan(n/e),t.y=this.radius_g_1*Math.atan(i/Ut(n,e))));return t.x=t.x*this.a,t.y=t.y*this.a,t},inverse:function(t){var e,r,n,i,s=-1,o=0,a=0;if(t.x=t.x/this.a,t.y=t.y/this.a,"ellipse"===this.shape){this.flip_axis?(a=Math.tan(t.y/this.radius_g_1),o=Math.tan(t.x/this.radius_g_1)*Ut(1,a)):(o=Math.tan(t.x/this.radius_g_1),a=Math.tan(t.y/this.radius_g_1)*Ut(1,o));var l=a/this.radius_p;if(e=o*o+l*l+s*s,(n=(r=2*this.radius_g*s)*r-4*e*this.C)<0)return t.x=Number.NaN,t.y=Number.NaN,t;i=(-r-Math.sqrt(n))/(2*e),s=this.radius_g+i*s,o*=i,a*=i,t.x=Math.atan2(o,s),t.y=Math.atan(a*Math.cos(t.x)/s),t.y=Math.atan(this.radius_p_inv2*Math.tan(t.y))}else if("sphere"===this.shape){if(this.flip_axis?(a=Math.tan(t.y/this.radius_g_1),o=Math.tan(t.x/this.radius_g_1)*Math.sqrt(1+a*a)):(o=Math.tan(t.x/this.radius_g_1),a=Math.tan(t.y/this.radius_g_1)*Math.sqrt(1+o*o)),e=o*o+a*a+s*s,(n=(r=2*this.radius_g*s)*r-4*e*this.C)<0)return t.x=Number.NaN,t.y=Number.NaN,t;i=(-r-Math.sqrt(n))/(2*e),s=this.radius_g+i*s,o*=i,a*=i,t.x=Math.atan2(o,s),t.y=Math.atan(a*Math.cos(t.x)/s)}return t.x=t.x+this.long0,t},names:["Geostationary Satellite View","Geostationary_Satellite","geos"]};var Ue=1.340264,Be=-.081106,Ve=893e-6,qe=.003796,Ke=Math.sqrt(3)/2;const We={init:function(){this.es=0,this.long0=void 0!==this.long0?this.long0:0},forward:function(t){var e=F(t.x-this.long0),r=t.y,n=Math.asin(Ke*Math.sin(r)),i=n*n,s=i*i*i;return t.x=e*Math.cos(n)/(Ke*(Ue+3*Be*i+s*(7*Ve+9*qe*i))),t.y=n*(Ue+Be*i+s*(Ve+qe*i)),t.x=this.a*t.x+this.x0,t.y=this.a*t.y+this.y0,t},inverse:function(t){t.x=(t.x-this.x0)/this.a,t.y=(t.y-this.y0)/this.a;var e,r,n,i,s=t.y;for(i=0;i<12&&(s-=n=(s*(Ue+Be*(e=s*s)+(r=e*e*e)*(Ve+qe*e))-t.y)/(Ue+3*Be*e+r*(7*Ve+9*qe*e)),!(Math.abs(n)<1e-9));++i);return r=(e=s*s)*e*e,t.x=Ke*t.x*(Ue+3*Be*e+r*(7*Ve+9*qe*e))/Math.cos(s),t.y=Math.asin(Math.sin(s)/Ke),t.x=F(t.x+this.long0),t},names:["eqearth","Equal Earth","Equal_Earth"]};var He=1e-10;function Ye(t){var e,r,n,i=F(t.x-(this.long0||0)),s=t.y;return e=this.am1+this.m1-Nt(s,r=Math.sin(s),n=Math.cos(s),this.en),r=n*i/(e*Math.sqrt(1-this.es*r*r)),t.x=e*Math.sin(r),t.y=this.am1-e*Math.cos(r),t.x=this.a*t.x+(this.x0||0),t.y=this.a*t.y+(this.y0||0),t}function Xe(t){var e,r,n,i;if(t.x=(t.x-(this.x0||0))/this.a,t.y=(t.y-(this.y0||0))/this.a,r=Ut(t.x,t.y=this.am1-t.y),i=Gt(this.am1+this.m1-r,this.es,this.en),(e=Math.abs(i))<o)e=Math.sin(i),n=r*Math.atan2(t.x,t.y)*Math.sqrt(1-this.es*e*e)/Math.cos(i);else{if(!(Math.abs(e-o)<=He))throw new Error;n=0}return t.x=F(n+(this.long0||0)),t.y=le(i),t}function Ze(t){var e,r,n=F(t.x-(this.long0||0)),i=t.y;return r=this.cphi1+this.phi1-i,Math.abs(r)>He?(t.x=r*Math.sin(e=n*Math.cos(i)/r),t.y=this.cphi1-r*Math.cos(e)):t.x=t.y=0,t.x=this.a*t.x+(this.x0||0),t.y=this.a*t.y+(this.y0||0),t}function Je(t){var e,r;t.x=(t.x-(this.x0||0))/this.a,t.y=(t.y-(this.y0||0))/this.a;var n=Ut(t.x,t.y=this.cphi1-t.y);if(r=this.cphi1+this.phi1-n,Math.abs(r)>o)throw new Error;return e=Math.abs(Math.abs(r)-o)<=He?0:n*Math.atan2(t.x,t.y)/Math.cos(r),t.x=F(e+(this.long0||0)),t.y=le(r),t}const Qe={init:function(){var t;if(this.phi1=this.lat1,Math.abs(this.phi1)<He)throw new Error;this.es?(this.en=jt(this.es),this.m1=Nt(this.phi1,this.am1=Math.sin(this.phi1),t=Math.cos(this.phi1),this.en),this.am1=t/(Math.sqrt(1-this.es*this.am1*this.am1)*this.am1),this.inverse=Xe,this.forward=Ye):(Math.abs(this.phi1)+He>=o?this.cphi1=0:this.cphi1=1/Math.tan(this.phi1),this.inverse=Je,this.forward=Ze)},names:["bonne","Bonne (Werner lat_1=90)"]};var tr;yt.defaultDatum="WGS84",yt.Proj=nt,yt.WGS84=new yt.Proj("WGS84"),yt.Point=It,yt.toPoint=ht,yt.defs=O,yt.nadgrid=function(t,e){var r=new DataView(e),n=function(t){var e=t.getInt32(8,!1);return 11!==e&&(11!==(e=t.getInt32(8,!0))&&console.warn("Failed to detect nadgrid endian-ness, defaulting to little-endian"),!0)}(r),i=function(t,e){return{nFields:t.getInt32(8,e),nSubgridFields:t.getInt32(24,e),nSubgrids:t.getInt32(40,e),shiftType:J(t,56,64).trim(),fromSemiMajorAxis:t.getFloat64(120,e),fromSemiMinorAxis:t.getFloat64(136,e),toSemiMajorAxis:t.getFloat64(152,e),toSemiMinorAxis:t.getFloat64(168,e)}}(r,n),s=function(t,e,r){for(var n=176,i=[],s=0;s<e.nSubgrids;s++){var o=tt(t,n,r),a=et(t,n,o,r),l=Math.round(1+(o.upperLongitude-o.lowerLongitude)/o.longitudeInterval),c=Math.round(1+(o.upperLatitude-o.lowerLatitude)/o.latitudeInterval);i.push({ll:[Z(o.lowerLongitude),Z(o.lowerLatitude)],del:[Z(o.longitudeInterval),Z(o.latitudeInterval)],lim:[l,c],count:o.gridNodeCount,cvs:Q(a)}),n+=176+16*o.gridNodeCount}return i}(r,i,n),o={header:i,subgrids:s};return Y[t]=o,o},yt.transform=ft,yt.mgrs=Et,yt.version="__VERSION__",(tr=yt).Proj.projections.add($t),tr.Proj.projections.add(qt),tr.Proj.projections.add(Kt),tr.Proj.projections.add(Yt),tr.Proj.projections.add(Xt),tr.Proj.projections.add(Zt),tr.Proj.projections.add(Qt),tr.Proj.projections.add(te),tr.Proj.projections.add(ee),tr.Proj.projections.add(ue),tr.Proj.projections.add(de),tr.Proj.projections.add(pe),tr.Proj.projections.add(me),tr.Proj.projections.add(ge),tr.Proj.projections.add(ye),tr.Proj.projections.add(ve),tr.Proj.projections.add(_e),tr.Proj.projections.add(be),tr.Proj.projections.add(we),tr.Proj.projections.add(xe),tr.Proj.projections.add(Ee),tr.Proj.projections.add(Se),tr.Proj.projections.add(Ae),tr.Proj.projections.add(Pe),tr.Proj.projections.add(Me),tr.Proj.projections.add(je),tr.Proj.projections.add(Ne),tr.Proj.projections.add($e),tr.Proj.projections.add(ze),tr.Proj.projections.add(We),tr.Proj.projections.add(Qe);const er=yt;var rr,nr="deflate-raw",ir=self.DecompressionStream;try{new ir(nr),rr=async t=>{let e=new ir(nr),r=e.writable.getWriter(),n=e.readable.getReader();r.write(t),r.close();let i,s,o=[],a=0,l=0;for(;!(s=await n.read()).done;)i=s.value,o.push(i),a+=i.length;return o.length-1?(i=new Uint8Array(a),o.map((t=>{i.set(t,l),l+=t.length})),i):o[0]}}catch{}var sr=new TextDecoder,or=t=>{throw new Error("but-unzip~"+t)},ar=t=>sr.decode(t);const lr=/.+\.(shp|dbf|json|prj|cpg)$/i,cr=globalThis.URL;async function ur(t,e){const r=((t,e)=>{if(!e)return t;const r=new cr(t);return r.pathname=`${r.pathname}.${e}`,r.href})(t,e),n="prj"===e||"cpg"===e;try{const t=await fetch(r);if(t.status>399)throw new Error(t.statusText);if(n)return t.text();const e=await t.arrayBuffer();return new DataView(e)}catch(t){if(n||"dbf"===e)return!1;throw t}}function hr(t){let e=0,r=1;const n=t.length;let i,s;const o=[t[0][0],t[0][1],t[0][0],t[0][1]];for(;r<n;)i=s||t[0],s=t[r],e+=(s[0]-i[0])*(s[1]+i[1]),r++,s[0]<o[0]&&(o[0]=s[0]),s[1]<o[1]&&(o[1]=s[1]),s[0]>o[2]&&(o[2]=s[0]),s[1]>o[3]&&(o[3]=s[1]);return{ring:t,clockWise:e>0,bbox:o,children:[]}}function dr(t,e){return!(t.bbox[0]>e.bbox[0]||t.bbox[1]>e.bbox[1]||t.bbox[2]<e.bbox[2]||t.bbox[3]<e.bbox[3])}pr.prototype.parsePoint=function(t){return{type:"Point",coordinates:this.parseCoord(t,0)}},pr.prototype.parseZPoint=function(t){const e=this.parsePoint(t);return e.coordinates.push(t.getFloat64(16,!0)),e},pr.prototype.parsePointArray=function(t,e,r){const n=[];let i=0;for(;i<r;)n.push(this.parseCoord(t,e)),e+=16,i++;return n},pr.prototype.parseZPointArray=function(t,e,r,n){let i=0;for(;i<r;)n[i].push(t.getFloat64(e,!0)),i++,e+=8;return n},pr.prototype.parseArrayGroup=function(t,e,r,n,i){const s=[];let o,a,l=0,c=0;for(;l<n;)l++,r+=4,o=c,c=l===n?i:t.getInt32(r,!0),a=c-o,a&&(s.push(this.parsePointArray(t,e,a)),e+=a<<4);return s},pr.prototype.parseZArrayGroup=function(t,e,r,n){let i=0;for(;i<r;)n[i]=this.parseZPointArray(t,e,n[i].length,n[i]),e+=n[i].length<<3,i++;return n},pr.prototype.parseMultiPoint=function(t){const e={},r=t.getInt32(32,!0);if(!r)return null;const n=this.parseCoord(t,0),i=this.parseCoord(t,16);return e.bbox=[n[0],n[1],i[0],i[1]],1===r?(e.type="Point",e.coordinates=this.parseCoord(t,36)):(e.type="MultiPoint",e.coordinates=this.parsePointArray(t,36,r)),e},pr.prototype.parseZMultiPoint=function(t){const e=this.parseMultiPoint(t);if(!e)return null;let r;if("Point"===e.type)return e.coordinates.push(t.getFloat64(72,!0)),e;r=e.coordinates.length;const n=52+(r<<4);return e.coordinates=this.parseZPointArray(t,n,r,e.coordinates),e},pr.prototype.parsePolyline=function(t){const e={},r=t.getInt32(32,!0);if(!r)return null;const n=this.parseCoord(t,0),i=this.parseCoord(t,16);e.bbox=[n[0],n[1],i[0],i[1]];const s=t.getInt32(36,!0);let o,a;return 1===r?(e.type="LineString",o=44,e.coordinates=this.parsePointArray(t,o,s)):(e.type="MultiLineString",o=40+(r<<2),a=40,e.coordinates=this.parseArrayGroup(t,o,40,r,s)),e},pr.prototype.parseZPolyline=function(t){const e=this.parsePolyline(t);if(!e)return null;const r=e.coordinates.length;let n;return"LineString"===e.type?(n=60+(r<<4),e.coordinates=this.parseZPointArray(t,n,r,e.coordinates),e):(n=56+(e.coordinates.reduce((function(t,e){return t+e.length}),0)<<4)+(r<<2),e.coordinates=this.parseZArrayGroup(t,n,r,e.coordinates),e)},pr.prototype.polyFuncs=function(t){return t?"LineString"===t.type?(t.type="Polygon",t.coordinates=[t.coordinates],t):(t.coordinates=function(t){const e=[],r=[];for(const n of t){const t=hr(n);t.clockWise?e.push(t):r.push(t)}for(const t of r)for(const r of e)if(dr(r,t)){r.children.push(t.ring);break}const n=[];for(const t of e)n.push([t.ring].concat(t.children));return n}(t.coordinates),1===t.coordinates.length?(t.type="Polygon",t.coordinates=t.coordinates[0],t):(t.type="MultiPolygon",t)):t},pr.prototype.parsePolygon=function(t){return this.polyFuncs(this.parsePolyline(t))},pr.prototype.parseZPolygon=function(t){return this.polyFuncs(this.parseZPolyline(t))};const fr={1:"parsePoint",3:"parsePolyline",5:"parsePolygon",8:"parseMultiPoint",11:"parseZPoint",13:"parseZPolyline",15:"parseZPolygon",18:"parseZMultiPoint"};function pr(t,e){if(!(this instanceof pr))return new pr(t,e);this.buffer=t,this.headers=this.parseHeader(),this.shpFuncs(e),this.rows=this.getRows()}function mr(t,e){return new pr(t,e).rows}pr.prototype.shpFuncs=function(t){let e=this.headers.shpCode;if(e>20&&(e-=20),!(e in fr))throw new Error(`I don't know shp type "${e}"`);var r;this.parseFunc=this[fr[e]],this.parseCoord=(r=t)?function(t,e){const n=[t.getFloat64(e,!0),t.getFloat64(e+8,!0)];return r.inverse(n)}:function(t,e){return[t.getFloat64(e,!0),t.getFloat64(e+8,!0)]}},pr.prototype.getShpCode=function(){return this.parseHeader().shpCode},pr.prototype.parseHeader=function(){const t=this.buffer;return{length:t.getInt32(24)<<1,version:t.getInt32(28,!0),shpCode:t.getInt32(32,!0),bbox:[t.getFloat64(36,!0),t.getFloat64(44,!0),t.getFloat64(52,!0),t.getFloat64(60,!0)]}},pr.prototype.getRows=function(){let t=100;const e=this.buffer.byteLength-8,r=[];let n;for(;t<=e&&(n=this.getRow(t),n);)t+=8,t+=n.len,n.type?r.push(this.parseFunc(n.data)):r.push(null);return r},pr.prototype.getRow=function(t){const e=this.buffer.getInt32(t),r=this.buffer.getInt32(t+4)<<1;return 0===r?{id:e,len:r,type:0}:t+r+8>this.buffer.byteLength?void 0:{id:e,len:r,data:new DataView(this.buffer.buffer,this.buffer.byteOffset+t+12,r-4),type:this.buffer.getInt32(t+8,!0)}};var gr=/^(?:ANSI\s)?(\d+)$/m;function yr(t,e){if(!t)return n;try{new TextDecoder(t.trim())}catch(i){var r=gr.exec(t);return r&&!e?yr("windows-"+r[1],!0):(t=void 0,n)}return n;function n(e){var r=new TextDecoder(t||void 0);return(r.decode(e,{stream:!0})+r.decode()).replace(/\0/g,"").trim()}}function vr(t,e,r,n,i){var s=i(new Uint8Array(t.buffer.slice(t.byteOffset+e,t.byteOffset+e+r)));switch(n){case"N":case"F":case"O":return parseFloat(s,10);case"D":return new Date(s.slice(0,4),parseInt(s.slice(4,6),10)-1,s.slice(6,8));case"L":return"y"===s.toLowerCase()||"t"===s.toLowerCase();default:return s}}function _r(t,e,r,n){for(var i,s,o={},a=0,l=r.length;a<l;)i=vr(t,e,(s=r[a]).len,s.dataType,n),e+=s.len,void 0!==i&&(o[s.name]=i),a++;return o}function br(t,e){for(var r=yr(e),n=function(t){var e={};return e.lastUpdated=new Date(t.getUint8(1)+1900,t.getUint8(2),t.getUint8(3)),e.records=t.getUint32(4,!0),e.headerLen=t.getUint16(8,!0),e.recLen=t.getUint16(10,!0),e}(t),i=function(t,e,r){for(var n=[],i=32;i<e&&(n.push({name:r(new Uint8Array(t.buffer.slice(t.byteOffset+i,t.byteOffset+i+11))),dataType:String.fromCharCode(t.getUint8(i+11)),len:t.getUint8(i+16),decimal:t.getUint8(i+17)}),13!==t.getUint8(i+32));)i+=32;return n}(t,n.headerLen-1,r),s=2+(i.length+1<<5),o=n.recLen,a=n.records,l=[];a;)l.push(_r(t,s,i,r)),s+=o,a--;return l}const wr=globalThis.URL,xr=new TextDecoder,Er=t=>{if(t)return"string"==typeof t?t:Ar(t)||ArrayBuffer.isView(t)||Pr(t)?xr.decode(t):void 0},Sr=t=>{if(!t)throw new Error("forgot to pass buffer");if(Pr(t))return t;if(Ar(t))return new DataView(t);if(Ar(t.buffer))return new DataView(t.buffer,t.byteOffset,t.byteLength);throw new Error("invalid buffer like object")};function Ar(t){return t instanceof globalThis.ArrayBuffer||"[object ArrayBuffer]"===Object.prototype.toString.call(t)}function Pr(t){return t instanceof globalThis.DataView||"[object DataView]"===Object.prototype.toString.call(t)}const Tr=function([t,e]){const r={type:"FeatureCollection",features:[]};let n=0;const i=t.length;for(e||(e=[]);n<i;)r.features.push({type:"Feature",geometry:t[n],properties:e[n]||{}}),n++;return r},Cr=async function(t,e){let r;t=(t=>{if(!t)throw new Error("forgot to pass buffer");if(Ar(t))return new Uint8Array(t);if(Ar(t.buffer))return 1===t.BYTES_PER_ELEMENT?t:new Uint8Array(t.buffer,t.byteOffset,t.byteLength);throw new Error("invalid buffer like object")})(t);const n=await(async t=>{const e={},r=[];for(const n of function*(t,e=rr){let r=(t=>{let e=t.length-20,r=Math.max(e-65516,2);for(;-1!==(e=t.lastIndexOf(80,e-1))&&(75!==t[e+1]||5!==t[e+2]||6!==t[e+3])&&e>r;);return e})(t);-1===r&&or(2);let n=(e,n)=>t.subarray(r+=e,r+=n),i=new DataView(t.buffer,t.byteOffset),s=t=>i.getUint16(t+r,!0),o=t=>i.getUint32(t+r,!0),a=s(10);for(a!==s(8)&&or(3),r=o(16);a--;){let t,i=s(10),a=s(28),l=s(30),c=s(32),u=o(20),h=o(42),d=ar(n(46,a)),f=ar(n(l,c)),p=r;r=h,t=n(30+s(26)+s(28),u),yield{filename:d,comment:f,read:()=>8&i?e(t):i?or(1):t},r=p}}(t))lr.test(n.filename)&&r.push(Promise.resolve(n.read()).then((t=>e[n.filename]=t)));await Promise.all(r);const n={},i=new TextDecoder;for(const[t,r]of Object.entries(e))"shp"===t.slice(-3).toLowerCase()||"dbf"===t.slice(-3).toLowerCase()?n[t]=new DataView(r.buffer,r.byteOffset,r.byteLength):n[t]=i.decode(r);return n})(t),i=[];for(r in e=e||[],n)-1===r.indexOf("__MACOSX")&&(".shp"===r.slice(-4).toLowerCase()?(i.push(r.slice(0,-4)),n[r.slice(0,-3)+r.slice(-3).toLowerCase()]=n[r]):".prj"===r.slice(-4).toLowerCase()?n[r.slice(0,-3)+r.slice(-3).toLowerCase()]=er(n[r]):".json"===r.slice(-5).toLowerCase()||e.indexOf(r.split(".").pop())>-1?i.push(r.slice(0,-3)+r.slice(-3).toLowerCase()):".dbf"!==r.slice(-4).toLowerCase()&&".cpg"!==r.slice(-4).toLowerCase()||(n[r.slice(0,-3)+r.slice(-3).toLowerCase()]=n[r]));if(!i.length)throw new Error("no layers founds");const s=i.map((function(t){let r,i;const s=t.lastIndexOf(".");return s>-1&&t.slice(s).indexOf("json")>-1?(r=JSON.parse(n[t]),r.fileName=t.slice(0,s)):e.indexOf(t.slice(s+1))>-1?(r=n[t],r.fileName=t):(n[t+".dbf"]&&(i=br(n[t+".dbf"],n[t+".cpg"])),r=Tr([mr(n[t+".shp"],n[t+".prj"]),i]),r.fileName=t),r}));return 1===s.length?s[0]:s},Mr=async t=>{const e=await Promise.all([ur(t,"shp"),ur(t,"prj")]);let r=!1;try{e[1]&&(r=er(e[1]))}catch(t){r=!1}return mr(e[0],r)},Or=async t=>{const[e,r]=await Promise.all([ur(t,"dbf"),ur(t,"cpg")]);if(e)return br(e,r)},Rr=(t,e)=>new wr(t,globalThis?.document?.location).pathname.slice(-4).toLowerCase()===e,Dr=function(t,e){if(t=Sr(t),"string"==typeof(e=Er(e)))try{e=er(e)}catch(t){e=!1}return mr(t,e)},Ir=async function(t,e){if("string"!=typeof t){if(Ar(t)||ArrayBuffer.isView(t)||Pr(t))return Cr(t);if(t.shp)return(({shp:t,dbf:e,cpg:r,prj:n})=>{const i=[Dr(t,n)];return e&&i.push(function(t,e){return br(t=Sr(t),e=Er(e))}(e,r)),Tr(i)})(t);throw new TypeError("must be a string, some sort of Buffer, or an object with at least a .shp property")}if(Rr(t,".zip"))return async function(t,e){const r=await ur(t);return Cr(r,e)}(t,e);Rr(t,".shp")&&(t=t.slice(0,-4));const r=await Promise.all([Mr(t),Or(t)]);return Tr(r)}},10646:t=>{"use strict";t.exports=Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)}},43225:t=>{"use strict";t.exports=function(t){return"function"==typeof t}},50709:(t,e,r)=>{"use strict";var n=r(10646),i=r(70925);t.exports=function(t){var e;if(!n(t))return!1;if(!(e=t.length))return!1;for(var r=0;r<e;r++)if(!i(t[r]))return!1;return!0}},70925:(t,e,r)=>{"use strict";var n=r(72100);t.exports=function(t){return n(t)&&t%1==0}},72100:t=>{"use strict";t.exports=function(t){return("number"==typeof t||"[object Number]"===Object.prototype.toString.call(t))&&t.valueOf()==t.valueOf()}},670:t=>{function e(t,e){const r=new RegExp(e,"g"),n=t.match(r);return n?n.length:0}t.exports=e,t.exports.default=e},34687:(t,e,r)=>{const n=r(31197),i=r(21453),s=r(670);function o(t,e,r){const o=r&&r.debug||!1,a=!(r&&!1===typeof r.nested),l=r&&r.startIndex||0;o&&console.log("[xml-utils] starting findTagByName with",e," and ",r);const c=n(t,`<${e}[ \n>/]`,l);if(o&&console.log("[xml-utils] start:",c),-1===c)return;const u=t.slice(c+e.length);let h=i(u,"^[^<]*[ /]>",0);const d=-1!==h&&"/"===u[h-1];if(o&&console.log("[xml-utils] selfClosing:",d),!1===d)if(a){let t=0,r=1,n=0;for(;-1!==(h=i(u,"[ /]"+e+">",t));){const i=u.substring(t,h+1);if(r+=s(i,"<"+e+"[ \n\t>]"),n+=s(i,"</"+e+">"),n>=r)break;t=h}}else h=i(u,"[ /]"+e+">",0);const f=c+e.length+h+1;if(o&&console.log("[xml-utils] end:",f),-1===f)return;const p=t.slice(c,f);let m;return m=d?null:p.slice(p.indexOf(">")+1,p.lastIndexOf("<")),{inner:m,outer:p,start:c,end:f}}t.exports=o,t.exports.default=o},91818:(t,e,r)=>{const n=r(34687);function i(t,e,r){const i=[],s=r&&r.debug||!1,o=!r||"boolean"!=typeof r.nested||r.nested;let a,l=r&&r.startIndex||0;for(;a=n(t,e,{debug:s,startIndex:l});)l=o?a.start+1+e.length:a.end,i.push(a);return s&&console.log("findTagsByName found",i.length,"tags"),i}t.exports=i,t.exports.default=i},96682:t=>{function e(t,e,r){const n=r&&r.debug||!1;n&&console.log("[xml-utils] getting "+e+" in "+t);const i="object"==typeof t?t.outer:t,s=i.slice(0,i.indexOf(">")+1),o=['"',"'"];for(let t=0;t<o.length;t++){const r=o[t],i=e+"\\="+r+"([^"+r+"]*)"+r;n&&console.log("[xml-utils] pattern:",i);const a=new RegExp(i).exec(s);if(n&&console.log("[xml-utils] match:",a),a)return a[1]}}t.exports=e,t.exports.default=e},21453:t=>{function e(t,e,r){const n=new RegExp(e).exec(t.slice(r));return n?r+n.index+n[0].length-1:-1}t.exports=e,t.exports.default=e},31197:t=>{function e(t,e,r){const n=new RegExp(e).exec(t.slice(r));return n?r+n.index:-1}t.exports=e,t.exports.default=e},32193:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.MissingRefError=e.ValidationError=e.CodeGen=e.Name=e.nil=e.stringify=e.str=e._=e.KeywordCxt=e.Ajv=void 0;const n=r(97719),i=r(38159),s=r(91944),o=r(34376),a=["/properties"],l="http://json-schema.org/draft-07/schema";class c extends n.default{_addVocabularies(){super._addVocabularies(),i.default.forEach((t=>this.addVocabulary(t))),this.opts.discriminator&&this.addKeyword(s.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const t=this.opts.$data?this.$dataMetaSchema(o,a):o;this.addMetaSchema(t,l,!1),this.refs["http://json-schema.org/schema"]=l}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(l)?l:void 0)}}e.Ajv=c,t.exports=e=c,t.exports.Ajv=c,Object.defineProperty(e,"__esModule",{value:!0}),e.default=c;var u=r(55087);Object.defineProperty(e,"KeywordCxt",{enumerable:!0,get:function(){return u.KeywordCxt}});var h=r(6394);Object.defineProperty(e,"_",{enumerable:!0,get:function(){return h._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return h.str}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return h.stringify}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return h.nil}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return h.Name}}),Object.defineProperty(e,"CodeGen",{enumerable:!0,get:function(){return h.CodeGen}});var d=r(99079);Object.defineProperty(e,"ValidationError",{enumerable:!0,get:function(){return d.default}});var f=r(96516);Object.defineProperty(e,"MissingRefError",{enumerable:!0,get:function(){return f.default}})},57213:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.regexpCode=e.getEsmExportName=e.getProperty=e.safeStringify=e.stringify=e.strConcat=e.addCodeArg=e.str=e._=e.nil=e._Code=e.Name=e.IDENTIFIER=e._CodeOrName=void 0;class r{}e._CodeOrName=r,e.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class n extends r{constructor(t){if(super(),!e.IDENTIFIER.test(t))throw new Error("CodeGen: name must be a valid identifier");this.str=t}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}e.Name=n;class i extends r{constructor(t){super(),this._items="string"==typeof t?[t]:t}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const t=this._items[0];return""===t||'""'===t}get str(){var t;return null!==(t=this._str)&&void 0!==t?t:this._str=this._items.reduce(((t,e)=>`${t}${e}`),"")}get names(){var t;return null!==(t=this._names)&&void 0!==t?t:this._names=this._items.reduce(((t,e)=>(e instanceof n&&(t[e.str]=(t[e.str]||0)+1),t)),{})}}function s(t,...e){const r=[t[0]];let n=0;for(;n<e.length;)l(r,e[n]),r.push(t[++n]);return new i(r)}e._Code=i,e.nil=new i(""),e._=s;const o=new i("+");function a(t,...e){const r=[u(t[0])];let n=0;for(;n<e.length;)r.push(o),l(r,e[n]),r.push(o,u(t[++n]));return function(t){let e=1;for(;e<t.length-1;){if(t[e]===o){const r=c(t[e-1],t[e+1]);if(void 0!==r){t.splice(e-1,3,r);continue}t[e++]="+"}e++}}(r),new i(r)}function l(t,e){var r;e instanceof i?t.push(...e._items):e instanceof n?t.push(e):t.push("number"==typeof(r=e)||"boolean"==typeof r||null===r?r:u(Array.isArray(r)?r.join(","):r))}function c(t,e){if('""'===e)return t;if('""'===t)return e;if("string"==typeof t){if(e instanceof n||'"'!==t[t.length-1])return;return"string"!=typeof e?`${t.slice(0,-1)}${e}"`:'"'===e[0]?t.slice(0,-1)+e.slice(1):void 0}return"string"!=typeof e||'"'!==e[0]||t instanceof n?void 0:`"${t}${e.slice(1)}`}function u(t){return JSON.stringify(t).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}e.str=a,e.addCodeArg=l,e.strConcat=function(t,e){return e.emptyStr()?t:t.emptyStr()?e:a`${t}${e}`},e.stringify=function(t){return new i(u(t))},e.safeStringify=u,e.getProperty=function(t){return"string"==typeof t&&e.IDENTIFIER.test(t)?new i(`.${t}`):s`[${t}]`},e.getEsmExportName=function(t){if("string"==typeof t&&e.IDENTIFIER.test(t))return new i(`${t}`);throw new Error(`CodeGen: invalid export name: ${t}, use explicit $id name mapping`)},e.regexpCode=function(t){return new i(t.toString())}},6394:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.or=e.and=e.not=e.CodeGen=e.operators=e.varKinds=e.ValueScopeName=e.ValueScope=e.Scope=e.Name=e.regexpCode=e.stringify=e.getProperty=e.nil=e.strConcat=e.str=e._=void 0;const n=r(57213),i=r(47314);var s=r(57213);Object.defineProperty(e,"_",{enumerable:!0,get:function(){return s._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return s.str}}),Object.defineProperty(e,"strConcat",{enumerable:!0,get:function(){return s.strConcat}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return s.nil}}),Object.defineProperty(e,"getProperty",{enumerable:!0,get:function(){return s.getProperty}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return s.stringify}}),Object.defineProperty(e,"regexpCode",{enumerable:!0,get:function(){return s.regexpCode}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return s.Name}});var o=r(47314);Object.defineProperty(e,"Scope",{enumerable:!0,get:function(){return o.Scope}}),Object.defineProperty(e,"ValueScope",{enumerable:!0,get:function(){return o.ValueScope}}),Object.defineProperty(e,"ValueScopeName",{enumerable:!0,get:function(){return o.ValueScopeName}}),Object.defineProperty(e,"varKinds",{enumerable:!0,get:function(){return o.varKinds}}),e.operators={GT:new n._Code(">"),GTE:new n._Code(">="),LT:new n._Code("<"),LTE:new n._Code("<="),EQ:new n._Code("==="),NEQ:new n._Code("!=="),NOT:new n._Code("!"),OR:new n._Code("||"),AND:new n._Code("&&"),ADD:new n._Code("+")};class a{optimizeNodes(){return this}optimizeNames(t,e){return this}}class l extends a{constructor(t,e,r){super(),this.varKind=t,this.name=e,this.rhs=r}render({es5:t,_n:e}){const r=t?i.varKinds.var:this.varKind,n=void 0===this.rhs?"":` = ${this.rhs}`;return`${r} ${this.name}${n};`+e}optimizeNames(t,e){if(t[this.name.str])return this.rhs&&(this.rhs=R(this.rhs,t,e)),this}get names(){return this.rhs instanceof n._CodeOrName?this.rhs.names:{}}}class c extends a{constructor(t,e,r){super(),this.lhs=t,this.rhs=e,this.sideEffects=r}render({_n:t}){return`${this.lhs} = ${this.rhs};`+t}optimizeNames(t,e){if(!(this.lhs instanceof n.Name)||t[this.lhs.str]||this.sideEffects)return this.rhs=R(this.rhs,t,e),this}get names(){return O(this.lhs instanceof n.Name?{}:{...this.lhs.names},this.rhs)}}class u extends c{constructor(t,e,r,n){super(t,r,n),this.op=e}render({_n:t}){return`${this.lhs} ${this.op}= ${this.rhs};`+t}}class h extends a{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`${this.label}:`+t}}class d extends a{constructor(t){super(),this.label=t,this.names={}}render({_n:t}){return`break${this.label?` ${this.label}`:""};`+t}}class f extends a{constructor(t){super(),this.error=t}render({_n:t}){return`throw ${this.error};`+t}get names(){return this.error.names}}class p extends a{constructor(t){super(),this.code=t}render({_n:t}){return`${this.code};`+t}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(t,e){return this.code=R(this.code,t,e),this}get names(){return this.code instanceof n._CodeOrName?this.code.names:{}}}class m extends a{constructor(t=[]){super(),this.nodes=t}render(t){return this.nodes.reduce(((e,r)=>e+r.render(t)),"")}optimizeNodes(){const{nodes:t}=this;let e=t.length;for(;e--;){const r=t[e].optimizeNodes();Array.isArray(r)?t.splice(e,1,...r):r?t[e]=r:t.splice(e,1)}return t.length>0?this:void 0}optimizeNames(t,e){const{nodes:r}=this;let n=r.length;for(;n--;){const i=r[n];i.optimizeNames(t,e)||(D(t,i.names),r.splice(n,1))}return r.length>0?this:void 0}get names(){return this.nodes.reduce(((t,e)=>M(t,e.names)),{})}}class g extends m{render(t){return"{"+t._n+super.render(t)+"}"+t._n}}class y extends m{}class v extends g{}v.kind="else";class _ extends g{constructor(t,e){super(e),this.condition=t}render(t){let e=`if(${this.condition})`+super.render(t);return this.else&&(e+="else "+this.else.render(t)),e}optimizeNodes(){super.optimizeNodes();const t=this.condition;if(!0===t)return this.nodes;let e=this.else;if(e){const t=e.optimizeNodes();e=this.else=Array.isArray(t)?new v(t):t}return e?!1===t?e instanceof _?e:e.nodes:this.nodes.length?this:new _(I(t),e instanceof _?[e]:e.nodes):!1!==t&&this.nodes.length?this:void 0}optimizeNames(t,e){var r;if(this.else=null===(r=this.else)||void 0===r?void 0:r.optimizeNames(t,e),super.optimizeNames(t,e)||this.else)return this.condition=R(this.condition,t,e),this}get names(){const t=super.names;return O(t,this.condition),this.else&&M(t,this.else.names),t}}_.kind="if";class b extends g{}b.kind="for";class w extends b{constructor(t){super(),this.iteration=t}render(t){return`for(${this.iteration})`+super.render(t)}optimizeNames(t,e){if(super.optimizeNames(t,e))return this.iteration=R(this.iteration,t,e),this}get names(){return M(super.names,this.iteration.names)}}class x extends b{constructor(t,e,r,n){super(),this.varKind=t,this.name=e,this.from=r,this.to=n}render(t){const e=t.es5?i.varKinds.var:this.varKind,{name:r,from:n,to:s}=this;return`for(${e} ${r}=${n}; ${r}<${s}; ${r}++)`+super.render(t)}get names(){const t=O(super.names,this.from);return O(t,this.to)}}class E extends b{constructor(t,e,r,n){super(),this.loop=t,this.varKind=e,this.name=r,this.iterable=n}render(t){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(t)}optimizeNames(t,e){if(super.optimizeNames(t,e))return this.iterable=R(this.iterable,t,e),this}get names(){return M(super.names,this.iterable.names)}}class S extends g{constructor(t,e,r){super(),this.name=t,this.args=e,this.async=r}render(t){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(t)}}S.kind="func";class A extends m{render(t){return"return "+super.render(t)}}A.kind="return";class P extends g{render(t){let e="try"+super.render(t);return this.catch&&(e+=this.catch.render(t)),this.finally&&(e+=this.finally.render(t)),e}optimizeNodes(){var t,e;return super.optimizeNodes(),null===(t=this.catch)||void 0===t||t.optimizeNodes(),null===(e=this.finally)||void 0===e||e.optimizeNodes(),this}optimizeNames(t,e){var r,n;return super.optimizeNames(t,e),null===(r=this.catch)||void 0===r||r.optimizeNames(t,e),null===(n=this.finally)||void 0===n||n.optimizeNames(t,e),this}get names(){const t=super.names;return this.catch&&M(t,this.catch.names),this.finally&&M(t,this.finally.names),t}}class T extends g{constructor(t){super(),this.error=t}render(t){return`catch(${this.error})`+super.render(t)}}T.kind="catch";class C extends g{render(t){return"finally"+super.render(t)}}function M(t,e){for(const r in e)t[r]=(t[r]||0)+(e[r]||0);return t}function O(t,e){return e instanceof n._CodeOrName?M(t,e.names):t}function R(t,e,r){return t instanceof n.Name?s(t):(i=t)instanceof n._Code&&i._items.some((t=>t instanceof n.Name&&1===e[t.str]&&void 0!==r[t.str]))?new n._Code(t._items.reduce(((t,e)=>(e instanceof n.Name&&(e=s(e)),e instanceof n._Code?t.push(...e._items):t.push(e),t)),[])):t;var i;function s(t){const n=r[t.str];return void 0===n||1!==e[t.str]?t:(delete e[t.str],n)}}function D(t,e){for(const r in e)t[r]=(t[r]||0)-(e[r]||0)}function I(t){return"boolean"==typeof t||"number"==typeof t||null===t?!t:n._`!${j(t)}`}C.kind="finally",e.CodeGen=class{constructor(t,e={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...e,_n:e.lines?"\n":""},this._extScope=t,this._scope=new i.Scope({parent:t}),this._nodes=[new y]}toString(){return this._root.render(this.opts)}name(t){return this._scope.name(t)}scopeName(t){return this._extScope.name(t)}scopeValue(t,e){const r=this._extScope.value(t,e);return(this._values[r.prefix]||(this._values[r.prefix]=new Set)).add(r),r}getScopeValue(t,e){return this._extScope.getValue(t,e)}scopeRefs(t){return this._extScope.scopeRefs(t,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(t,e,r,n){const i=this._scope.toName(e);return void 0!==r&&n&&(this._constants[i.str]=r),this._leafNode(new l(t,i,r)),i}const(t,e,r){return this._def(i.varKinds.const,t,e,r)}let(t,e,r){return this._def(i.varKinds.let,t,e,r)}var(t,e,r){return this._def(i.varKinds.var,t,e,r)}assign(t,e,r){return this._leafNode(new c(t,e,r))}add(t,r){return this._leafNode(new u(t,e.operators.ADD,r))}code(t){return"function"==typeof t?t():t!==n.nil&&this._leafNode(new p(t)),this}object(...t){const e=["{"];for(const[r,i]of t)e.length>1&&e.push(","),e.push(r),(r!==i||this.opts.es5)&&(e.push(":"),(0,n.addCodeArg)(e,i));return e.push("}"),new n._Code(e)}if(t,e,r){if(this._blockNode(new _(t)),e&&r)this.code(e).else().code(r).endIf();else if(e)this.code(e).endIf();else if(r)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(t){return this._elseNode(new _(t))}else(){return this._elseNode(new v)}endIf(){return this._endBlockNode(_,v)}_for(t,e){return this._blockNode(t),e&&this.code(e).endFor(),this}for(t,e){return this._for(new w(t),e)}forRange(t,e,r,n,s=(this.opts.es5?i.varKinds.var:i.varKinds.let)){const o=this._scope.toName(t);return this._for(new x(s,o,e,r),(()=>n(o)))}forOf(t,e,r,s=i.varKinds.const){const o=this._scope.toName(t);if(this.opts.es5){const t=e instanceof n.Name?e:this.var("_arr",e);return this.forRange("_i",0,n._`${t}.length`,(e=>{this.var(o,n._`${t}[${e}]`),r(o)}))}return this._for(new E("of",s,o,e),(()=>r(o)))}forIn(t,e,r,s=(this.opts.es5?i.varKinds.var:i.varKinds.const)){if(this.opts.ownProperties)return this.forOf(t,n._`Object.keys(${e})`,r);const o=this._scope.toName(t);return this._for(new E("in",s,o,e),(()=>r(o)))}endFor(){return this._endBlockNode(b)}label(t){return this._leafNode(new h(t))}break(t){return this._leafNode(new d(t))}return(t){const e=new A;if(this._blockNode(e),this.code(t),1!==e.nodes.length)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(A)}try(t,e,r){if(!e&&!r)throw new Error('CodeGen: "try" without "catch" and "finally"');const n=new P;if(this._blockNode(n),this.code(t),e){const t=this.name("e");this._currNode=n.catch=new T(t),e(t)}return r&&(this._currNode=n.finally=new C,this.code(r)),this._endBlockNode(T,C)}throw(t){return this._leafNode(new f(t))}block(t,e){return this._blockStarts.push(this._nodes.length),t&&this.code(t).endBlock(e),this}endBlock(t){const e=this._blockStarts.pop();if(void 0===e)throw new Error("CodeGen: not in self-balancing block");const r=this._nodes.length-e;if(r<0||void 0!==t&&r!==t)throw new Error(`CodeGen: wrong number of nodes: ${r} vs ${t} expected`);return this._nodes.length=e,this}func(t,e=n.nil,r,i){return this._blockNode(new S(t,e,r)),i&&this.code(i).endFunc(),this}endFunc(){return this._endBlockNode(S)}optimize(t=1){for(;t-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(t){return this._currNode.nodes.push(t),this}_blockNode(t){this._currNode.nodes.push(t),this._nodes.push(t)}_endBlockNode(t,e){const r=this._currNode;if(r instanceof t||e&&r instanceof e)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${e?`${t.kind}/${e.kind}`:t.kind}"`)}_elseNode(t){const e=this._currNode;if(!(e instanceof _))throw new Error('CodeGen: "else" without "if"');return this._currNode=e.else=t,this}get _root(){return this._nodes[0]}get _currNode(){const t=this._nodes;return t[t.length-1]}set _currNode(t){const e=this._nodes;e[e.length-1]=t}},e.not=I;const k=F(e.operators.AND);e.and=function(...t){return t.reduce(k)};const L=F(e.operators.OR);function F(t){return(e,r)=>e===n.nil?r:r===n.nil?e:n._`${j(e)} ${t} ${j(r)}`}function j(t){return t instanceof n.Name?t:n._`(${t})`}e.or=function(...t){return t.reduce(L)}},47314:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ValueScope=e.ValueScopeName=e.Scope=e.varKinds=e.UsedValueState=void 0;const n=r(57213);class i extends Error{constructor(t){super(`CodeGen: "code" for ${t} not defined`),this.value=t.value}}var s;!function(t){t[t.Started=0]="Started",t[t.Completed=1]="Completed"}(s||(e.UsedValueState=s={})),e.varKinds={const:new n.Name("const"),let:new n.Name("let"),var:new n.Name("var")};class o{constructor({prefixes:t,parent:e}={}){this._names={},this._prefixes=t,this._parent=e}toName(t){return t instanceof n.Name?t:this.name(t)}name(t){return new n.Name(this._newName(t))}_newName(t){return`${t}${(this._names[t]||this._nameGroup(t)).index++}`}_nameGroup(t){var e,r;if((null===(r=null===(e=this._parent)||void 0===e?void 0:e._prefixes)||void 0===r?void 0:r.has(t))||this._prefixes&&!this._prefixes.has(t))throw new Error(`CodeGen: prefix "${t}" is not allowed in this scope`);return this._names[t]={prefix:t,index:0}}}e.Scope=o;class a extends n.Name{constructor(t,e){super(e),this.prefix=t}setValue(t,{property:e,itemIndex:r}){this.value=t,this.scopePath=n._`.${new n.Name(e)}[${r}]`}}e.ValueScopeName=a;const l=n._`\n`;e.ValueScope=class extends o{constructor(t){super(t),this._values={},this._scope=t.scope,this.opts={...t,_n:t.lines?l:n.nil}}get(){return this._scope}name(t){return new a(t,this._newName(t))}value(t,e){var r;if(void 0===e.ref)throw new Error("CodeGen: ref must be passed in value");const n=this.toName(t),{prefix:i}=n,s=null!==(r=e.key)&&void 0!==r?r:e.ref;let o=this._values[i];if(o){const t=o.get(s);if(t)return t}else o=this._values[i]=new Map;o.set(s,n);const a=this._scope[i]||(this._scope[i]=[]),l=a.length;return a[l]=e.ref,n.setValue(e,{property:i,itemIndex:l}),n}getValue(t,e){const r=this._values[t];if(r)return r.get(e)}scopeRefs(t,e=this._values){return this._reduceValues(e,(e=>{if(void 0===e.scopePath)throw new Error(`CodeGen: name "${e}" has no value`);return n._`${t}${e.scopePath}`}))}scopeCode(t=this._values,e,r){return this._reduceValues(t,(t=>{if(void 0===t.value)throw new Error(`CodeGen: name "${t}" has no value`);return t.value.code}),e,r)}_reduceValues(t,r,o={},a){let l=n.nil;for(const c in t){const u=t[c];if(!u)continue;const h=o[c]=o[c]||new Map;u.forEach((t=>{if(h.has(t))return;h.set(t,s.Started);let o=r(t);if(o){const r=this.opts.es5?e.varKinds.var:e.varKinds.const;l=n._`${l}${r} ${t} = ${o};${this.opts._n}`}else{if(!(o=null==a?void 0:a(t)))throw new i(t);l=n._`${l}${o}${this.opts._n}`}h.set(t,s.Completed)}))}return l}}},78705:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.extendErrors=e.resetErrorsCount=e.reportExtraError=e.reportError=e.keyword$DataError=e.keywordError=void 0;const n=r(6394),i=r(88938),s=r(44);function o(t,e){const r=t.const("err",e);t.if(n._`${s.default.vErrors} === null`,(()=>t.assign(s.default.vErrors,n._`[${r}]`)),n._`${s.default.vErrors}.push(${r})`),t.code(n._`${s.default.errors}++`)}function a(t,e){const{gen:r,validateName:i,schemaEnv:s}=t;s.$async?r.throw(n._`new ${t.ValidationError}(${e})`):(r.assign(n._`${i}.errors`,e),r.return(!1))}e.keywordError={message:({keyword:t})=>n.str`must pass "${t}" keyword validation`},e.keyword$DataError={message:({keyword:t,schemaType:e})=>e?n.str`"${t}" keyword must be ${e} ($data)`:n.str`"${t}" keyword is invalid ($data)`},e.reportError=function(t,r=e.keywordError,i,s){const{it:l}=t,{gen:u,compositeRule:h,allErrors:d}=l,f=c(t,r,i);(null!=s?s:h||d)?o(u,f):a(l,n._`[${f}]`)},e.reportExtraError=function(t,r=e.keywordError,n){const{it:i}=t,{gen:l,compositeRule:u,allErrors:h}=i;o(l,c(t,r,n)),u||h||a(i,s.default.vErrors)},e.resetErrorsCount=function(t,e){t.assign(s.default.errors,e),t.if(n._`${s.default.vErrors} !== null`,(()=>t.if(e,(()=>t.assign(n._`${s.default.vErrors}.length`,e)),(()=>t.assign(s.default.vErrors,null)))))},e.extendErrors=function({gen:t,keyword:e,schemaValue:r,data:i,errsCount:o,it:a}){if(void 0===o)throw new Error("ajv implementation error");const l=t.name("err");t.forRange("i",o,s.default.errors,(o=>{t.const(l,n._`${s.default.vErrors}[${o}]`),t.if(n._`${l}.instancePath === undefined`,(()=>t.assign(n._`${l}.instancePath`,(0,n.strConcat)(s.default.instancePath,a.errorPath)))),t.assign(n._`${l}.schemaPath`,n.str`${a.errSchemaPath}/${e}`),a.opts.verbose&&(t.assign(n._`${l}.schema`,r),t.assign(n._`${l}.data`,i))}))};const l={keyword:new n.Name("keyword"),schemaPath:new n.Name("schemaPath"),params:new n.Name("params"),propertyName:new n.Name("propertyName"),message:new n.Name("message"),schema:new n.Name("schema"),parentSchema:new n.Name("parentSchema")};function c(t,e,r){const{createErrors:i}=t.it;return!1===i?n._`{}`:function(t,e,r={}){const{gen:i,it:o}=t,a=[u(o,r),h(t,r)];return function(t,{params:e,message:r},i){const{keyword:o,data:a,schemaValue:c,it:u}=t,{opts:h,propertyName:d,topSchemaRef:f,schemaPath:p}=u;i.push([l.keyword,o],[l.params,"function"==typeof e?e(t):e||n._`{}`]),h.messages&&i.push([l.message,"function"==typeof r?r(t):r]),h.verbose&&i.push([l.schema,c],[l.parentSchema,n._`${f}${p}`],[s.default.data,a]),d&&i.push([l.propertyName,d])}(t,e,a),i.object(...a)}(t,e,r)}function u({errorPath:t},{instancePath:e}){const r=e?n.str`${t}${(0,i.getErrorPath)(e,i.Type.Str)}`:t;return[s.default.instancePath,(0,n.strConcat)(s.default.instancePath,r)]}function h({keyword:t,it:{errSchemaPath:e}},{schemaPath:r,parentSchema:s}){let o=s?e:n.str`${e}/${t}`;return r&&(o=n.str`${o}${(0,i.getErrorPath)(r,i.Type.Str)}`),[l.schemaPath,o]}},13312:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.resolveSchema=e.getCompilingSchema=e.resolveRef=e.compileSchema=e.SchemaEnv=void 0;const n=r(6394),i=r(99079),s=r(44),o=r(51512),a=r(88938),l=r(55087);class c{constructor(t){var e;let r;this.refs={},this.dynamicAnchors={},"object"==typeof t.schema&&(r=t.schema),this.schema=t.schema,this.schemaId=t.schemaId,this.root=t.root||this,this.baseId=null!==(e=t.baseId)&&void 0!==e?e:(0,o.normalizeId)(null==r?void 0:r[t.schemaId||"$id"]),this.schemaPath=t.schemaPath,this.localRefs=t.localRefs,this.meta=t.meta,this.$async=null==r?void 0:r.$async,this.refs={}}}function u(t){const e=d.call(this,t);if(e)return e;const r=(0,o.getFullPath)(this.opts.uriResolver,t.root.baseId),{es5:a,lines:c}=this.opts.code,{ownProperties:u}=this.opts,h=new n.CodeGen(this.scope,{es5:a,lines:c,ownProperties:u});let f;t.$async&&(f=h.scopeValue("Error",{ref:i.default,code:n._`require("ajv/dist/runtime/validation_error").default`}));const p=h.scopeName("validate");t.validateName=p;const m={gen:h,allErrors:this.opts.allErrors,data:s.default.data,parentData:s.default.parentData,parentDataProperty:s.default.parentDataProperty,dataNames:[s.default.data],dataPathArr:[n.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:h.scopeValue("schema",!0===this.opts.code.source?{ref:t.schema,code:(0,n.stringify)(t.schema)}:{ref:t.schema}),validateName:p,ValidationError:f,schema:t.schema,schemaEnv:t,rootId:r,baseId:t.baseId||r,schemaPath:n.nil,errSchemaPath:t.schemaPath||(this.opts.jtd?"":"#"),errorPath:n._`""`,opts:this.opts,self:this};let g;try{this._compilations.add(t),(0,l.validateFunctionCode)(m),h.optimize(this.opts.code.optimize);const e=h.toString();g=`${h.scopeRefs(s.default.scope)}return ${e}`,this.opts.code.process&&(g=this.opts.code.process(g,t));const r=new Function(`${s.default.self}`,`${s.default.scope}`,g)(this,this.scope.get());if(this.scope.value(p,{ref:r}),r.errors=null,r.schema=t.schema,r.schemaEnv=t,t.$async&&(r.$async=!0),!0===this.opts.code.source&&(r.source={validateName:p,validateCode:e,scopeValues:h._values}),this.opts.unevaluated){const{props:t,items:e}=m;r.evaluated={props:t instanceof n.Name?void 0:t,items:e instanceof n.Name?void 0:e,dynamicProps:t instanceof n.Name,dynamicItems:e instanceof n.Name},r.source&&(r.source.evaluated=(0,n.stringify)(r.evaluated))}return t.validate=r,t}catch(e){throw delete t.validate,delete t.validateName,g&&this.logger.error("Error compiling schema, function code:",g),e}finally{this._compilations.delete(t)}}function h(t){return(0,o.inlineRef)(t.schema,this.opts.inlineRefs)?t.schema:t.validate?t:u.call(this,t)}function d(t){for(const n of this._compilations)if(r=t,(e=n).schema===r.schema&&e.root===r.root&&e.baseId===r.baseId)return n;var e,r}function f(t,e){let r;for(;"string"==typeof(r=this.refs[e]);)e=r;return r||this.schemas[e]||p.call(this,t,e)}function p(t,e){const r=this.opts.uriResolver.parse(e),n=(0,o._getFullPath)(this.opts.uriResolver,r);let i=(0,o.getFullPath)(this.opts.uriResolver,t.baseId,void 0);if(Object.keys(t.schema).length>0&&n===i)return g.call(this,r,t);const s=(0,o.normalizeId)(n),a=this.refs[s]||this.schemas[s];if("string"==typeof a){const e=p.call(this,t,a);if("object"!=typeof(null==e?void 0:e.schema))return;return g.call(this,r,e)}if("object"==typeof(null==a?void 0:a.schema)){if(a.validate||u.call(this,a),s===(0,o.normalizeId)(e)){const{schema:e}=a,{schemaId:r}=this.opts,n=e[r];return n&&(i=(0,o.resolveUrl)(this.opts.uriResolver,i,n)),new c({schema:e,schemaId:r,root:t,baseId:i})}return g.call(this,r,a)}}e.SchemaEnv=c,e.compileSchema=u,e.resolveRef=function(t,e,r){var n;r=(0,o.resolveUrl)(this.opts.uriResolver,e,r);const i=t.refs[r];if(i)return i;let s=f.call(this,t,r);if(void 0===s){const i=null===(n=t.localRefs)||void 0===n?void 0:n[r],{schemaId:o}=this.opts;i&&(s=new c({schema:i,schemaId:o,root:t,baseId:e}))}return void 0!==s?t.refs[r]=h.call(this,s):void 0},e.getCompilingSchema=d,e.resolveSchema=p;const m=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function g(t,{baseId:e,schema:r,root:n}){var i;if("/"!==(null===(i=t.fragment)||void 0===i?void 0:i[0]))return;for(const n of t.fragment.slice(1).split("/")){if("boolean"==typeof r)return;const t=r[(0,a.unescapeFragment)(n)];if(void 0===t)return;const i="object"==typeof(r=t)&&r[this.opts.schemaId];!m.has(n)&&i&&(e=(0,o.resolveUrl)(this.opts.uriResolver,e,i))}let s;if("boolean"!=typeof r&&r.$ref&&!(0,a.schemaHasRulesButRef)(r,this.RULES)){const t=(0,o.resolveUrl)(this.opts.uriResolver,e,r.$ref);s=p.call(this,n,t)}const{schemaId:l}=this.opts;return s=s||new c({schema:r,schemaId:l,root:n,baseId:e}),s.schema!==s.root.schema?s:void 0}},44:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i={data:new n.Name("data"),valCxt:new n.Name("valCxt"),instancePath:new n.Name("instancePath"),parentData:new n.Name("parentData"),parentDataProperty:new n.Name("parentDataProperty"),rootData:new n.Name("rootData"),dynamicAnchors:new n.Name("dynamicAnchors"),vErrors:new n.Name("vErrors"),errors:new n.Name("errors"),this:new n.Name("this"),self:new n.Name("self"),scope:new n.Name("scope"),json:new n.Name("json"),jsonPos:new n.Name("jsonPos"),jsonLen:new n.Name("jsonLen"),jsonPart:new n.Name("jsonPart")};e.default=i},96516:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(51512);class i extends Error{constructor(t,e,r,i){super(i||`can't resolve reference ${r} from id ${e}`),this.missingRef=(0,n.resolveUrl)(t,e,r),this.missingSchema=(0,n.normalizeId)((0,n.getFullPath)(t,this.missingRef))}}e.default=i},51512:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getSchemaRefs=e.resolveUrl=e.normalizeId=e._getFullPath=e.getFullPath=e.inlineRef=void 0;const n=r(88938),i=r(38792),s=r(1645),o=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);e.inlineRef=function(t,e=!0){return"boolean"==typeof t||(!0===e?!l(t):!!e&&c(t)<=e)};const a=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function l(t){for(const e in t){if(a.has(e))return!0;const r=t[e];if(Array.isArray(r)&&r.some(l))return!0;if("object"==typeof r&&l(r))return!0}return!1}function c(t){let e=0;for(const r in t){if("$ref"===r)return 1/0;if(e++,!o.has(r)&&("object"==typeof t[r]&&(0,n.eachItem)(t[r],(t=>e+=c(t))),e===1/0))return 1/0}return e}function u(t,e="",r){!1!==r&&(e=f(e));const n=t.parse(e);return h(t,n)}function h(t,e){return t.serialize(e).split("#")[0]+"#"}e.getFullPath=u,e._getFullPath=h;const d=/#\/?$/;function f(t){return t?t.replace(d,""):""}e.normalizeId=f,e.resolveUrl=function(t,e,r){return r=f(r),t.resolve(e,r)};const p=/^[a-z_][-a-z0-9._]*$/i;e.getSchemaRefs=function(t,e){if("boolean"==typeof t)return{};const{schemaId:r,uriResolver:n}=this.opts,o=f(t[r]||e),a={"":o},l=u(n,o,!1),c={},h=new Set;return s(t,{allKeys:!0},((t,e,n,i)=>{if(void 0===i)return;const s=l+e;let o=a[i];function u(e){const r=this.opts.uriResolver.resolve;if(e=f(o?r(o,e):e),h.has(e))throw m(e);h.add(e);let n=this.refs[e];return"string"==typeof n&&(n=this.refs[n]),"object"==typeof n?d(t,n.schema,e):e!==f(s)&&("#"===e[0]?(d(t,c[e],e),c[e]=t):this.refs[e]=s),e}function g(t){if("string"==typeof t){if(!p.test(t))throw new Error(`invalid anchor "${t}"`);u.call(this,`#${t}`)}}"string"==typeof t[r]&&(o=u.call(this,t[r])),g.call(this,t.$anchor),g.call(this,t.$dynamicAnchor),a[e]=o})),c;function d(t,e,r){if(void 0!==e&&!i(t,e))throw m(r)}function m(t){return new Error(`reference "${t}" resolves to more than one schema`)}}},78399:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getRules=e.isJSONType=void 0;const r=new Set(["string","number","integer","boolean","null","object","array"]);e.isJSONType=function(t){return"string"==typeof t&&r.has(t)},e.getRules=function(){const t={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...t,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},t.number,t.string,t.array,t.object],post:{rules:[]},all:{},keywords:{}}}},88938:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.checkStrictMode=e.getErrorPath=e.Type=e.useFunc=e.setEvaluated=e.evaluatedPropsToName=e.mergeEvaluated=e.eachItem=e.unescapeJsonPointer=e.escapeJsonPointer=e.escapeFragment=e.unescapeFragment=e.schemaRefOrVal=e.schemaHasRulesButRef=e.schemaHasRules=e.checkUnknownRules=e.alwaysValidSchema=e.toHash=void 0;const n=r(6394),i=r(57213);function s(t,e=t.schema){const{opts:r,self:n}=t;if(!r.strictSchema)return;if("boolean"==typeof e)return;const i=n.RULES.keywords;for(const r in e)i[r]||p(t,`unknown keyword: "${r}"`)}function o(t,e){if("boolean"==typeof t)return!t;for(const r in t)if(e[r])return!0;return!1}function a(t){return"number"==typeof t?`${t}`:t.replace(/~/g,"~0").replace(/\//g,"~1")}function l(t){return t.replace(/~1/g,"/").replace(/~0/g,"~")}function c({mergeNames:t,mergeToName:e,mergeValues:r,resultToName:i}){return(s,o,a,l)=>{const c=void 0===a?o:a instanceof n.Name?(o instanceof n.Name?t(s,o,a):e(s,o,a),a):o instanceof n.Name?(e(s,a,o),o):r(o,a);return l!==n.Name||c instanceof n.Name?c:i(s,c)}}function u(t,e){if(!0===e)return t.var("props",!0);const r=t.var("props",n._`{}`);return void 0!==e&&h(t,r,e),r}function h(t,e,r){Object.keys(r).forEach((r=>t.assign(n._`${e}${(0,n.getProperty)(r)}`,!0)))}e.toHash=function(t){const e={};for(const r of t)e[r]=!0;return e},e.alwaysValidSchema=function(t,e){return"boolean"==typeof e?e:0===Object.keys(e).length||(s(t,e),!o(e,t.self.RULES.all))},e.checkUnknownRules=s,e.schemaHasRules=o,e.schemaHasRulesButRef=function(t,e){if("boolean"==typeof t)return!t;for(const r in t)if("$ref"!==r&&e.all[r])return!0;return!1},e.schemaRefOrVal=function({topSchemaRef:t,schemaPath:e},r,i,s){if(!s){if("number"==typeof r||"boolean"==typeof r)return r;if("string"==typeof r)return n._`${r}`}return n._`${t}${e}${(0,n.getProperty)(i)}`},e.unescapeFragment=function(t){return l(decodeURIComponent(t))},e.escapeFragment=function(t){return encodeURIComponent(a(t))},e.escapeJsonPointer=a,e.unescapeJsonPointer=l,e.eachItem=function(t,e){if(Array.isArray(t))for(const r of t)e(r);else e(t)},e.mergeEvaluated={props:c({mergeNames:(t,e,r)=>t.if(n._`${r} !== true && ${e} !== undefined`,(()=>{t.if(n._`${e} === true`,(()=>t.assign(r,!0)),(()=>t.assign(r,n._`${r} || {}`).code(n._`Object.assign(${r}, ${e})`)))})),mergeToName:(t,e,r)=>t.if(n._`${r} !== true`,(()=>{!0===e?t.assign(r,!0):(t.assign(r,n._`${r} || {}`),h(t,r,e))})),mergeValues:(t,e)=>!0===t||{...t,...e},resultToName:u}),items:c({mergeNames:(t,e,r)=>t.if(n._`${r} !== true && ${e} !== undefined`,(()=>t.assign(r,n._`${e} === true ? true : ${r} > ${e} ? ${r} : ${e}`))),mergeToName:(t,e,r)=>t.if(n._`${r} !== true`,(()=>t.assign(r,!0===e||n._`${r} > ${e} ? ${r} : ${e}`))),mergeValues:(t,e)=>!0===t||Math.max(t,e),resultToName:(t,e)=>t.var("items",e)})},e.evaluatedPropsToName=u,e.setEvaluated=h;const d={};var f;function p(t,e,r=t.opts.strictSchema){if(r){if(e=`strict mode: ${e}`,!0===r)throw new Error(e);t.self.logger.warn(e)}}e.useFunc=function(t,e){return t.scopeValue("func",{ref:e,code:d[e.code]||(d[e.code]=new i._Code(e.code))})},function(t){t[t.Num=0]="Num",t[t.Str=1]="Str"}(f||(e.Type=f={})),e.getErrorPath=function(t,e,r){if(t instanceof n.Name){const i=e===f.Num;return r?i?n._`"[" + ${t} + "]"`:n._`"['" + ${t} + "']"`:i?n._`"/" + ${t}`:n._`"/" + ${t}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return r?(0,n.getProperty)(t).toString():"/"+a(t)},e.checkStrictMode=p},27670:(t,e)=>{"use strict";function r(t,e){return e.rules.some((e=>n(t,e)))}function n(t,e){var r;return void 0!==t[e.keyword]||(null===(r=e.definition.implements)||void 0===r?void 0:r.some((e=>void 0!==t[e])))}Object.defineProperty(e,"__esModule",{value:!0}),e.shouldUseRule=e.shouldUseGroup=e.schemaHasRulesForType=void 0,e.schemaHasRulesForType=function({schema:t,self:e},n){const i=e.RULES.types[n];return i&&!0!==i&&r(t,i)},e.shouldUseGroup=r,e.shouldUseRule=n},38012:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.boolOrEmptySchema=e.topBoolOrEmptySchema=void 0;const n=r(78705),i=r(6394),s=r(44),o={message:"boolean schema is false"};function a(t,e){const{gen:r,data:i}=t,s={gen:r,keyword:"false schema",data:i,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:t};(0,n.reportError)(s,o,void 0,e)}e.topBoolOrEmptySchema=function(t){const{gen:e,schema:r,validateName:n}=t;!1===r?a(t,!1):"object"==typeof r&&!0===r.$async?e.return(s.default.data):(e.assign(i._`${n}.errors`,null),e.return(!0))},e.boolOrEmptySchema=function(t,e){const{gen:r,schema:n}=t;!1===n?(r.var(e,!1),a(t)):r.var(e,!0)}},14939:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.reportTypeError=e.checkDataTypes=e.checkDataType=e.coerceAndCheckDataType=e.getJSONTypes=e.getSchemaTypes=e.DataType=void 0;const n=r(78399),i=r(27670),s=r(78705),o=r(6394),a=r(88938);var l;function c(t){const e=Array.isArray(t)?t:t?[t]:[];if(e.every(n.isJSONType))return e;throw new Error("type must be JSONType or JSONType[]: "+e.join(","))}!function(t){t[t.Correct=0]="Correct",t[t.Wrong=1]="Wrong"}(l||(e.DataType=l={})),e.getSchemaTypes=function(t){const e=c(t.type);if(e.includes("null")){if(!1===t.nullable)throw new Error("type: null contradicts nullable: false")}else{if(!e.length&&void 0!==t.nullable)throw new Error('"nullable" cannot be used without "type"');!0===t.nullable&&e.push("null")}return e},e.getJSONTypes=c,e.coerceAndCheckDataType=function(t,e){const{gen:r,data:n,opts:s}=t,a=function(t,e){return e?t.filter((t=>u.has(t)||"array"===e&&"array"===t)):[]}(e,s.coerceTypes),c=e.length>0&&!(0===a.length&&1===e.length&&(0,i.schemaHasRulesForType)(t,e[0]));if(c){const i=d(e,n,s.strictNumbers,l.Wrong);r.if(i,(()=>{a.length?function(t,e,r){const{gen:n,data:i,opts:s}=t,a=n.let("dataType",o._`typeof ${i}`),l=n.let("coerced",o._`undefined`);"array"===s.coerceTypes&&n.if(o._`${a} == 'object' && Array.isArray(${i}) && ${i}.length == 1`,(()=>n.assign(i,o._`${i}[0]`).assign(a,o._`typeof ${i}`).if(d(e,i,s.strictNumbers),(()=>n.assign(l,i))))),n.if(o._`${l} !== undefined`);for(const t of r)(u.has(t)||"array"===t&&"array"===s.coerceTypes)&&c(t);function c(t){switch(t){case"string":return void n.elseIf(o._`${a} == "number" || ${a} == "boolean"`).assign(l,o._`"" + ${i}`).elseIf(o._`${i} === null`).assign(l,o._`""`);case"number":return void n.elseIf(o._`${a} == "boolean" || ${i} === null
3
+ || (${a} == "string" && ${i} && ${i} == +${i})`).assign(l,o._`+${i}`);case"integer":return void n.elseIf(o._`${a} === "boolean" || ${i} === null
4
+ || (${a} === "string" && ${i} && ${i} == +${i} && !(${i} % 1))`).assign(l,o._`+${i}`);case"boolean":return void n.elseIf(o._`${i} === "false" || ${i} === 0 || ${i} === null`).assign(l,!1).elseIf(o._`${i} === "true" || ${i} === 1`).assign(l,!0);case"null":return n.elseIf(o._`${i} === "" || ${i} === 0 || ${i} === false`),void n.assign(l,null);case"array":n.elseIf(o._`${a} === "string" || ${a} === "number"
5
+ || ${a} === "boolean" || ${i} === null`).assign(l,o._`[${i}]`)}}n.else(),p(t),n.endIf(),n.if(o._`${l} !== undefined`,(()=>{n.assign(i,l),function({gen:t,parentData:e,parentDataProperty:r},n){t.if(o._`${e} !== undefined`,(()=>t.assign(o._`${e}[${r}]`,n)))}(t,l)}))}(t,e,a):p(t)}))}return c};const u=new Set(["string","number","integer","boolean","null"]);function h(t,e,r,n=l.Correct){const i=n===l.Correct?o.operators.EQ:o.operators.NEQ;let s;switch(t){case"null":return o._`${e} ${i} null`;case"array":s=o._`Array.isArray(${e})`;break;case"object":s=o._`${e} && typeof ${e} == "object" && !Array.isArray(${e})`;break;case"integer":s=a(o._`!(${e} % 1) && !isNaN(${e})`);break;case"number":s=a();break;default:return o._`typeof ${e} ${i} ${t}`}return n===l.Correct?s:(0,o.not)(s);function a(t=o.nil){return(0,o.and)(o._`typeof ${e} == "number"`,t,r?o._`isFinite(${e})`:o.nil)}}function d(t,e,r,n){if(1===t.length)return h(t[0],e,r,n);let i;const s=(0,a.toHash)(t);if(s.array&&s.object){const t=o._`typeof ${e} != "object"`;i=s.null?t:o._`!${e} || ${t}`,delete s.null,delete s.array,delete s.object}else i=o.nil;s.number&&delete s.integer;for(const t in s)i=(0,o.and)(i,h(t,e,r,n));return i}e.checkDataType=h,e.checkDataTypes=d;const f={message:({schema:t})=>`must be ${t}`,params:({schema:t,schemaValue:e})=>"string"==typeof t?o._`{type: ${t}}`:o._`{type: ${e}}`};function p(t){const e=function(t){const{gen:e,data:r,schema:n}=t,i=(0,a.schemaRefOrVal)(t,n,"type");return{gen:e,keyword:"type",data:r,schema:n.type,schemaCode:i,schemaValue:i,parentSchema:n,params:{},it:t}}(t);(0,s.reportError)(e,f)}e.reportTypeError=p},63385:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.assignDefaults=void 0;const n=r(6394),i=r(88938);function s(t,e,r){const{gen:s,compositeRule:o,data:a,opts:l}=t;if(void 0===r)return;const c=n._`${a}${(0,n.getProperty)(e)}`;if(o)return void(0,i.checkStrictMode)(t,`default is ignored for: ${c}`);let u=n._`${c} === undefined`;"empty"===l.useDefaults&&(u=n._`${u} || ${c} === null || ${c} === ""`),s.if(u,n._`${c} = ${(0,n.stringify)(r)}`)}e.assignDefaults=function(t,e){const{properties:r,items:n}=t.schema;if("object"===e&&r)for(const e in r)s(t,e,r[e].default);else"array"===e&&Array.isArray(n)&&n.forEach(((e,r)=>s(t,r,e.default)))}},55087:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getData=e.KeywordCxt=e.validateFunctionCode=void 0;const n=r(38012),i=r(14939),s=r(27670),o=r(14939),a=r(63385),l=r(39444),c=r(33210),u=r(6394),h=r(44),d=r(51512),f=r(88938),p=r(78705);function m({gen:t,validateName:e,schema:r,schemaEnv:n,opts:i},s){i.code.es5?t.func(e,u._`${h.default.data}, ${h.default.valCxt}`,n.$async,(()=>{t.code(u._`"use strict"; ${g(r,i)}`),function(t,e){t.if(h.default.valCxt,(()=>{t.var(h.default.instancePath,u._`${h.default.valCxt}.${h.default.instancePath}`),t.var(h.default.parentData,u._`${h.default.valCxt}.${h.default.parentData}`),t.var(h.default.parentDataProperty,u._`${h.default.valCxt}.${h.default.parentDataProperty}`),t.var(h.default.rootData,u._`${h.default.valCxt}.${h.default.rootData}`),e.dynamicRef&&t.var(h.default.dynamicAnchors,u._`${h.default.valCxt}.${h.default.dynamicAnchors}`)}),(()=>{t.var(h.default.instancePath,u._`""`),t.var(h.default.parentData,u._`undefined`),t.var(h.default.parentDataProperty,u._`undefined`),t.var(h.default.rootData,h.default.data),e.dynamicRef&&t.var(h.default.dynamicAnchors,u._`{}`)}))}(t,i),t.code(s)})):t.func(e,u._`${h.default.data}, ${function(t){return u._`{${h.default.instancePath}="", ${h.default.parentData}, ${h.default.parentDataProperty}, ${h.default.rootData}=${h.default.data}${t.dynamicRef?u._`, ${h.default.dynamicAnchors}={}`:u.nil}}={}`}(i)}`,n.$async,(()=>t.code(g(r,i)).code(s)))}function g(t,e){const r="object"==typeof t&&t[e.schemaId];return r&&(e.code.source||e.code.process)?u._`/*# sourceURL=${r} */`:u.nil}function y({schema:t,self:e}){if("boolean"==typeof t)return!t;for(const r in t)if(e.RULES.all[r])return!0;return!1}function v(t){return"boolean"!=typeof t.schema}function _(t){(0,f.checkUnknownRules)(t),function(t){const{schema:e,errSchemaPath:r,opts:n,self:i}=t;e.$ref&&n.ignoreKeywordsWithRef&&(0,f.schemaHasRulesButRef)(e,i.RULES)&&i.logger.warn(`$ref: keywords ignored in schema at path "${r}"`)}(t)}function b(t,e){if(t.opts.jtd)return x(t,[],!1,e);const r=(0,i.getSchemaTypes)(t.schema);x(t,r,!(0,i.coerceAndCheckDataType)(t,r),e)}function w({gen:t,schemaEnv:e,schema:r,errSchemaPath:n,opts:i}){const s=r.$comment;if(!0===i.$comment)t.code(u._`${h.default.self}.logger.log(${s})`);else if("function"==typeof i.$comment){const r=u.str`${n}/$comment`,i=t.scopeValue("root",{ref:e.root});t.code(u._`${h.default.self}.opts.$comment(${s}, ${r}, ${i}.schema)`)}}function x(t,e,r,n){const{gen:i,schema:a,data:l,allErrors:c,opts:d,self:p}=t,{RULES:m}=p;function g(f){(0,s.shouldUseGroup)(a,f)&&(f.type?(i.if((0,o.checkDataType)(f.type,l,d.strictNumbers)),E(t,f),1===e.length&&e[0]===f.type&&r&&(i.else(),(0,o.reportTypeError)(t)),i.endIf()):E(t,f),c||i.if(u._`${h.default.errors} === ${n||0}`))}!a.$ref||!d.ignoreKeywordsWithRef&&(0,f.schemaHasRulesButRef)(a,m)?(d.jtd||function(t,e){!t.schemaEnv.meta&&t.opts.strictTypes&&(function(t,e){e.length&&(t.dataTypes.length?(e.forEach((e=>{S(t.dataTypes,e)||A(t,`type "${e}" not allowed by context "${t.dataTypes.join(",")}"`)})),function(t,e){const r=[];for(const n of t.dataTypes)S(e,n)?r.push(n):e.includes("integer")&&"number"===n&&r.push("integer");t.dataTypes=r}(t,e)):t.dataTypes=e)}(t,e),t.opts.allowUnionTypes||function(t,e){e.length>1&&(2!==e.length||!e.includes("null"))&&A(t,"use allowUnionTypes to allow union type keyword")}(t,e),function(t,e){const r=t.self.RULES.all;for(const n in r){const i=r[n];if("object"==typeof i&&(0,s.shouldUseRule)(t.schema,i)){const{type:r}=i.definition;r.length&&!r.some((t=>{return n=t,(r=e).includes(n)||"number"===n&&r.includes("integer");var r,n}))&&A(t,`missing type "${r.join(",")}" for keyword "${n}"`)}}}(t,t.dataTypes))}(t,e),i.block((()=>{for(const t of m.rules)g(t);g(m.post)}))):i.block((()=>T(t,"$ref",m.all.$ref.definition)))}function E(t,e){const{gen:r,schema:n,opts:{useDefaults:i}}=t;i&&(0,a.assignDefaults)(t,e.type),r.block((()=>{for(const r of e.rules)(0,s.shouldUseRule)(n,r)&&T(t,r.keyword,r.definition,e.type)}))}function S(t,e){return t.includes(e)||"integer"===e&&t.includes("number")}function A(t,e){e+=` at "${t.schemaEnv.baseId+t.errSchemaPath}" (strictTypes)`,(0,f.checkStrictMode)(t,e,t.opts.strictTypes)}e.validateFunctionCode=function(t){v(t)&&(_(t),y(t))?function(t){const{schema:e,opts:r,gen:n}=t;m(t,(()=>{r.$comment&&e.$comment&&w(t),function(t){const{schema:e,opts:r}=t;void 0!==e.default&&r.useDefaults&&r.strictSchema&&(0,f.checkStrictMode)(t,"default is ignored in the schema root")}(t),n.let(h.default.vErrors,null),n.let(h.default.errors,0),r.unevaluated&&function(t){const{gen:e,validateName:r}=t;t.evaluated=e.const("evaluated",u._`${r}.evaluated`),e.if(u._`${t.evaluated}.dynamicProps`,(()=>e.assign(u._`${t.evaluated}.props`,u._`undefined`))),e.if(u._`${t.evaluated}.dynamicItems`,(()=>e.assign(u._`${t.evaluated}.items`,u._`undefined`)))}(t),b(t),function(t){const{gen:e,schemaEnv:r,validateName:n,ValidationError:i,opts:s}=t;r.$async?e.if(u._`${h.default.errors} === 0`,(()=>e.return(h.default.data)),(()=>e.throw(u._`new ${i}(${h.default.vErrors})`))):(e.assign(u._`${n}.errors`,h.default.vErrors),s.unevaluated&&function({gen:t,evaluated:e,props:r,items:n}){r instanceof u.Name&&t.assign(u._`${e}.props`,r),n instanceof u.Name&&t.assign(u._`${e}.items`,n)}(t),e.return(u._`${h.default.errors} === 0`))}(t)}))}(t):m(t,(()=>(0,n.topBoolOrEmptySchema)(t)))};class P{constructor(t,e,r){if((0,l.validateKeywordUsage)(t,e,r),this.gen=t.gen,this.allErrors=t.allErrors,this.keyword=r,this.data=t.data,this.schema=t.schema[r],this.$data=e.$data&&t.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,f.schemaRefOrVal)(t,this.schema,r,this.$data),this.schemaType=e.schemaType,this.parentSchema=t.schema,this.params={},this.it=t,this.def=e,this.$data)this.schemaCode=t.gen.const("vSchema",O(this.$data,t));else if(this.schemaCode=this.schemaValue,!(0,l.validSchemaType)(this.schema,e.schemaType,e.allowUndefined))throw new Error(`${r} value must be ${JSON.stringify(e.schemaType)}`);("code"in e?e.trackErrors:!1!==e.errors)&&(this.errsCount=t.gen.const("_errs",h.default.errors))}result(t,e,r){this.failResult((0,u.not)(t),e,r)}failResult(t,e,r){this.gen.if(t),r?r():this.error(),e?(this.gen.else(),e(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(t,e){this.failResult((0,u.not)(t),void 0,e)}fail(t){if(void 0===t)return this.error(),void(this.allErrors||this.gen.if(!1));this.gen.if(t),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(t){if(!this.$data)return this.fail(t);const{schemaCode:e}=this;this.fail(u._`${e} !== undefined && (${(0,u.or)(this.invalid$data(),t)})`)}error(t,e,r){if(e)return this.setParams(e),this._error(t,r),void this.setParams({});this._error(t,r)}_error(t,e){(t?p.reportExtraError:p.reportError)(this,this.def.error,e)}$dataError(){(0,p.reportError)(this,this.def.$dataError||p.keyword$DataError)}reset(){if(void 0===this.errsCount)throw new Error('add "trackErrors" to keyword definition');(0,p.resetErrorsCount)(this.gen,this.errsCount)}ok(t){this.allErrors||this.gen.if(t)}setParams(t,e){e?Object.assign(this.params,t):this.params=t}block$data(t,e,r=u.nil){this.gen.block((()=>{this.check$data(t,r),e()}))}check$data(t=u.nil,e=u.nil){if(!this.$data)return;const{gen:r,schemaCode:n,schemaType:i,def:s}=this;r.if((0,u.or)(u._`${n} === undefined`,e)),t!==u.nil&&r.assign(t,!0),(i.length||s.validateSchema)&&(r.elseIf(this.invalid$data()),this.$dataError(),t!==u.nil&&r.assign(t,!1)),r.else()}invalid$data(){const{gen:t,schemaCode:e,schemaType:r,def:n,it:i}=this;return(0,u.or)(function(){if(r.length){if(!(e instanceof u.Name))throw new Error("ajv implementation error");const t=Array.isArray(r)?r:[r];return u._`${(0,o.checkDataTypes)(t,e,i.opts.strictNumbers,o.DataType.Wrong)}`}return u.nil}(),function(){if(n.validateSchema){const r=t.scopeValue("validate$data",{ref:n.validateSchema});return u._`!${r}(${e})`}return u.nil}())}subschema(t,e){const r=(0,c.getSubschema)(this.it,t);(0,c.extendSubschemaData)(r,this.it,t),(0,c.extendSubschemaMode)(r,t);const i={...this.it,...r,items:void 0,props:void 0};return function(t,e){v(t)&&(_(t),y(t))?function(t,e){const{schema:r,gen:n,opts:i}=t;i.$comment&&r.$comment&&w(t),function(t){const e=t.schema[t.opts.schemaId];e&&(t.baseId=(0,d.resolveUrl)(t.opts.uriResolver,t.baseId,e))}(t),function(t){if(t.schema.$async&&!t.schemaEnv.$async)throw new Error("async schema in sync schema")}(t);const s=n.const("_errs",h.default.errors);b(t,s),n.var(e,u._`${s} === ${h.default.errors}`)}(t,e):(0,n.boolOrEmptySchema)(t,e)}(i,e),i}mergeEvaluated(t,e){const{it:r,gen:n}=this;r.opts.unevaluated&&(!0!==r.props&&void 0!==t.props&&(r.props=f.mergeEvaluated.props(n,t.props,r.props,e)),!0!==r.items&&void 0!==t.items&&(r.items=f.mergeEvaluated.items(n,t.items,r.items,e)))}mergeValidEvaluated(t,e){const{it:r,gen:n}=this;if(r.opts.unevaluated&&(!0!==r.props||!0!==r.items))return n.if(e,(()=>this.mergeEvaluated(t,u.Name))),!0}}function T(t,e,r,n){const i=new P(t,r,e);"code"in r?r.code(i,n):i.$data&&r.validate?(0,l.funcKeywordCode)(i,r):"macro"in r?(0,l.macroKeywordCode)(i,r):(r.compile||r.validate)&&(0,l.funcKeywordCode)(i,r)}e.KeywordCxt=P;const C=/^\/(?:[^~]|~0|~1)*$/,M=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function O(t,{dataLevel:e,dataNames:r,dataPathArr:n}){let i,s;if(""===t)return h.default.rootData;if("/"===t[0]){if(!C.test(t))throw new Error(`Invalid JSON-pointer: ${t}`);i=t,s=h.default.rootData}else{const o=M.exec(t);if(!o)throw new Error(`Invalid JSON-pointer: ${t}`);const a=+o[1];if(i=o[2],"#"===i){if(a>=e)throw new Error(l("property/index",a));return n[e-a]}if(a>e)throw new Error(l("data",a));if(s=r[e-a],!i)return s}let o=s;const a=i.split("/");for(const t of a)t&&(s=u._`${s}${(0,u.getProperty)((0,f.unescapeJsonPointer)(t))}`,o=u._`${o} && ${s}`);return o;function l(t,r){return`Cannot access ${t} ${r} levels up, current level is ${e}`}}e.getData=O},39444:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.validateKeywordUsage=e.validSchemaType=e.funcKeywordCode=e.macroKeywordCode=void 0;const n=r(6394),i=r(44),s=r(85154),o=r(78705);function a(t){const{gen:e,data:r,it:i}=t;e.if(i.parentData,(()=>e.assign(r,n._`${i.parentData}[${i.parentDataProperty}]`)))}function l(t,e,r){if(void 0===r)throw new Error(`keyword "${e}" failed to compile`);return t.scopeValue("keyword","function"==typeof r?{ref:r}:{ref:r,code:(0,n.stringify)(r)})}e.macroKeywordCode=function(t,e){const{gen:r,keyword:i,schema:s,parentSchema:o,it:a}=t,c=e.macro.call(a.self,s,o,a),u=l(r,i,c);!1!==a.opts.validateSchema&&a.self.validateSchema(c,!0);const h=r.name("valid");t.subschema({schema:c,schemaPath:n.nil,errSchemaPath:`${a.errSchemaPath}/${i}`,topSchemaRef:u,compositeRule:!0},h),t.pass(h,(()=>t.error(!0)))},e.funcKeywordCode=function(t,e){var r;const{gen:c,keyword:u,schema:h,parentSchema:d,$data:f,it:p}=t;!function({schemaEnv:t},e){if(e.async&&!t.$async)throw new Error("async keyword in sync schema")}(p,e);const m=!f&&e.compile?e.compile.call(p.self,h,d,p):e.validate,g=l(c,u,m),y=c.let("valid");function v(r=(e.async?n._`await `:n.nil)){const o=p.opts.passContext?i.default.this:i.default.self,a=!("compile"in e&&!f||!1===e.schema);c.assign(y,n._`${r}${(0,s.callValidateCode)(t,g,o,a)}`,e.modifying)}function _(t){var r;c.if((0,n.not)(null!==(r=e.valid)&&void 0!==r?r:y),t)}t.block$data(y,(function(){if(!1===e.errors)v(),e.modifying&&a(t),_((()=>t.error()));else{const r=e.async?function(){const t=c.let("ruleErrs",null);return c.try((()=>v(n._`await `)),(e=>c.assign(y,!1).if(n._`${e} instanceof ${p.ValidationError}`,(()=>c.assign(t,n._`${e}.errors`)),(()=>c.throw(e))))),t}():function(){const t=n._`${g}.errors`;return c.assign(t,null),v(n.nil),t}();e.modifying&&a(t),_((()=>function(t,e){const{gen:r}=t;r.if(n._`Array.isArray(${e})`,(()=>{r.assign(i.default.vErrors,n._`${i.default.vErrors} === null ? ${e} : ${i.default.vErrors}.concat(${e})`).assign(i.default.errors,n._`${i.default.vErrors}.length`),(0,o.extendErrors)(t)}),(()=>t.error()))}(t,r)))}})),t.ok(null!==(r=e.valid)&&void 0!==r?r:y)},e.validSchemaType=function(t,e,r=!1){return!e.length||e.some((e=>"array"===e?Array.isArray(t):"object"===e?t&&"object"==typeof t&&!Array.isArray(t):typeof t==e||r&&void 0===t))},e.validateKeywordUsage=function({schema:t,opts:e,self:r,errSchemaPath:n},i,s){if(Array.isArray(i.keyword)?!i.keyword.includes(s):i.keyword!==s)throw new Error("ajv implementation error");const o=i.dependencies;if(null==o?void 0:o.some((e=>!Object.prototype.hasOwnProperty.call(t,e))))throw new Error(`parent schema must have dependencies of ${s}: ${o.join(",")}`);if(i.validateSchema&&!i.validateSchema(t[s])){const t=`keyword "${s}" value is invalid at path "${n}": `+r.errorsText(i.validateSchema.errors);if("log"!==e.validateSchema)throw new Error(t);r.logger.error(t)}}},33210:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.extendSubschemaMode=e.extendSubschemaData=e.getSubschema=void 0;const n=r(6394),i=r(88938);e.getSubschema=function(t,{keyword:e,schemaProp:r,schema:s,schemaPath:o,errSchemaPath:a,topSchemaRef:l}){if(void 0!==e&&void 0!==s)throw new Error('both "keyword" and "schema" passed, only one allowed');if(void 0!==e){const s=t.schema[e];return void 0===r?{schema:s,schemaPath:n._`${t.schemaPath}${(0,n.getProperty)(e)}`,errSchemaPath:`${t.errSchemaPath}/${e}`}:{schema:s[r],schemaPath:n._`${t.schemaPath}${(0,n.getProperty)(e)}${(0,n.getProperty)(r)}`,errSchemaPath:`${t.errSchemaPath}/${e}/${(0,i.escapeFragment)(r)}`}}if(void 0!==s){if(void 0===o||void 0===a||void 0===l)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:s,schemaPath:o,topSchemaRef:l,errSchemaPath:a}}throw new Error('either "keyword" or "schema" must be passed')},e.extendSubschemaData=function(t,e,{dataProp:r,dataPropType:s,data:o,dataTypes:a,propertyName:l}){if(void 0!==o&&void 0!==r)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:c}=e;if(void 0!==r){const{errorPath:o,dataPathArr:a,opts:l}=e;u(c.let("data",n._`${e.data}${(0,n.getProperty)(r)}`,!0)),t.errorPath=n.str`${o}${(0,i.getErrorPath)(r,s,l.jsPropertySyntax)}`,t.parentDataProperty=n._`${r}`,t.dataPathArr=[...a,t.parentDataProperty]}function u(r){t.data=r,t.dataLevel=e.dataLevel+1,t.dataTypes=[],e.definedProperties=new Set,t.parentData=e.data,t.dataNames=[...e.dataNames,r]}void 0!==o&&(u(o instanceof n.Name?o:c.let("data",o,!0)),void 0!==l&&(t.propertyName=l)),a&&(t.dataTypes=a)},e.extendSubschemaMode=function(t,{jtdDiscriminator:e,jtdMetadata:r,compositeRule:n,createErrors:i,allErrors:s}){void 0!==n&&(t.compositeRule=n),void 0!==i&&(t.createErrors=i),void 0!==s&&(t.allErrors=s),t.jtdDiscriminator=e,t.jtdMetadata=r}},97719:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.CodeGen=e.Name=e.nil=e.stringify=e.str=e._=e.KeywordCxt=void 0;var n=r(55087);Object.defineProperty(e,"KeywordCxt",{enumerable:!0,get:function(){return n.KeywordCxt}});var i=r(6394);Object.defineProperty(e,"_",{enumerable:!0,get:function(){return i._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return i.str}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return i.stringify}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return i.nil}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return i.Name}}),Object.defineProperty(e,"CodeGen",{enumerable:!0,get:function(){return i.CodeGen}});const s=r(99079),o=r(96516),a=r(78399),l=r(13312),c=r(6394),u=r(51512),h=r(14939),d=r(88938),f=r(69962),p=r(80655),m=(t,e)=>new RegExp(t,e);m.code="new RegExp";const g=["removeAdditional","useDefaults","coerceTypes"],y=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),v={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},_={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'};function b(t){var e,r,n,i,s,o,a,l,c,u,h,d,f,g,y,v,_,b,w,x,E,S,A,P,T;const C=t.strict,M=null===(e=t.code)||void 0===e?void 0:e.optimize,O=!0===M||void 0===M?1:M||0,R=null!==(n=null===(r=t.code)||void 0===r?void 0:r.regExp)&&void 0!==n?n:m,D=null!==(i=t.uriResolver)&&void 0!==i?i:p.default;return{strictSchema:null===(o=null!==(s=t.strictSchema)&&void 0!==s?s:C)||void 0===o||o,strictNumbers:null===(l=null!==(a=t.strictNumbers)&&void 0!==a?a:C)||void 0===l||l,strictTypes:null!==(u=null!==(c=t.strictTypes)&&void 0!==c?c:C)&&void 0!==u?u:"log",strictTuples:null!==(d=null!==(h=t.strictTuples)&&void 0!==h?h:C)&&void 0!==d?d:"log",strictRequired:null!==(g=null!==(f=t.strictRequired)&&void 0!==f?f:C)&&void 0!==g&&g,code:t.code?{...t.code,optimize:O,regExp:R}:{optimize:O,regExp:R},loopRequired:null!==(y=t.loopRequired)&&void 0!==y?y:200,loopEnum:null!==(v=t.loopEnum)&&void 0!==v?v:200,meta:null===(_=t.meta)||void 0===_||_,messages:null===(b=t.messages)||void 0===b||b,inlineRefs:null===(w=t.inlineRefs)||void 0===w||w,schemaId:null!==(x=t.schemaId)&&void 0!==x?x:"$id",addUsedSchema:null===(E=t.addUsedSchema)||void 0===E||E,validateSchema:null===(S=t.validateSchema)||void 0===S||S,validateFormats:null===(A=t.validateFormats)||void 0===A||A,unicodeRegExp:null===(P=t.unicodeRegExp)||void 0===P||P,int32range:null===(T=t.int32range)||void 0===T||T,uriResolver:D}}class w{constructor(t={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,t=this.opts={...t,...b(t)};const{es5:e,lines:r}=this.opts.code;this.scope=new c.ValueScope({scope:{},prefixes:y,es5:e,lines:r}),this.logger=function(t){if(!1===t)return C;if(void 0===t)return console;if(t.log&&t.warn&&t.error)return t;throw new Error("logger must implement log, warn and error methods")}(t.logger);const n=t.validateFormats;t.validateFormats=!1,this.RULES=(0,a.getRules)(),x.call(this,v,t,"NOT SUPPORTED"),x.call(this,_,t,"DEPRECATED","warn"),this._metaOpts=T.call(this),t.formats&&A.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),t.keywords&&P.call(this,t.keywords),"object"==typeof t.meta&&this.addMetaSchema(t.meta),S.call(this),t.validateFormats=n}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:t,meta:e,schemaId:r}=this.opts;let n=f;"id"===r&&(n={...f},n.id=n.$id,delete n.$id),e&&t&&this.addMetaSchema(n,n[r],!1)}defaultMeta(){const{meta:t,schemaId:e}=this.opts;return this.opts.defaultMeta="object"==typeof t?t[e]||t:void 0}validate(t,e){let r;if("string"==typeof t){if(r=this.getSchema(t),!r)throw new Error(`no schema with key or ref "${t}"`)}else r=this.compile(t);const n=r(e);return"$async"in r||(this.errors=r.errors),n}compile(t,e){const r=this._addSchema(t,e);return r.validate||this._compileSchemaEnv(r)}compileAsync(t,e){if("function"!=typeof this.opts.loadSchema)throw new Error("options.loadSchema should be a function");const{loadSchema:r}=this.opts;return n.call(this,t,e);async function n(t,e){await i.call(this,t.$schema);const r=this._addSchema(t,e);return r.validate||s.call(this,r)}async function i(t){t&&!this.getSchema(t)&&await n.call(this,{$ref:t},!0)}async function s(t){try{return this._compileSchemaEnv(t)}catch(e){if(!(e instanceof o.default))throw e;return a.call(this,e),await l.call(this,e.missingSchema),s.call(this,t)}}function a({missingSchema:t,missingRef:e}){if(this.refs[t])throw new Error(`AnySchema ${t} is loaded but ${e} cannot be resolved`)}async function l(t){const r=await c.call(this,t);this.refs[t]||await i.call(this,r.$schema),this.refs[t]||this.addSchema(r,t,e)}async function c(t){const e=this._loading[t];if(e)return e;try{return await(this._loading[t]=r(t))}finally{delete this._loading[t]}}}addSchema(t,e,r,n=this.opts.validateSchema){if(Array.isArray(t)){for(const e of t)this.addSchema(e,void 0,r,n);return this}let i;if("object"==typeof t){const{schemaId:e}=this.opts;if(i=t[e],void 0!==i&&"string"!=typeof i)throw new Error(`schema ${e} must be string`)}return e=(0,u.normalizeId)(e||i),this._checkUnique(e),this.schemas[e]=this._addSchema(t,r,e,n,!0),this}addMetaSchema(t,e,r=this.opts.validateSchema){return this.addSchema(t,e,!0,r),this}validateSchema(t,e){if("boolean"==typeof t)return!0;let r;if(r=t.$schema,void 0!==r&&"string"!=typeof r)throw new Error("$schema must be a string");if(r=r||this.opts.defaultMeta||this.defaultMeta(),!r)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const n=this.validate(r,t);if(!n&&e){const t="schema is invalid: "+this.errorsText();if("log"!==this.opts.validateSchema)throw new Error(t);this.logger.error(t)}return n}getSchema(t){let e;for(;"string"==typeof(e=E.call(this,t));)t=e;if(void 0===e){const{schemaId:r}=this.opts,n=new l.SchemaEnv({schema:{},schemaId:r});if(e=l.resolveSchema.call(this,n,t),!e)return;this.refs[t]=e}return e.validate||this._compileSchemaEnv(e)}removeSchema(t){if(t instanceof RegExp)return this._removeAllSchemas(this.schemas,t),this._removeAllSchemas(this.refs,t),this;switch(typeof t){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const e=E.call(this,t);return"object"==typeof e&&this._cache.delete(e.schema),delete this.schemas[t],delete this.refs[t],this}case"object":{const e=t;this._cache.delete(e);let r=t[this.opts.schemaId];return r&&(r=(0,u.normalizeId)(r),delete this.schemas[r],delete this.refs[r]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(t){for(const e of t)this.addKeyword(e);return this}addKeyword(t,e){let r;if("string"==typeof t)r=t,"object"==typeof e&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),e.keyword=r);else{if("object"!=typeof t||void 0!==e)throw new Error("invalid addKeywords parameters");if(r=(e=t).keyword,Array.isArray(r)&&!r.length)throw new Error("addKeywords: keyword must be string or non-empty array")}if(O.call(this,r,e),!e)return(0,d.eachItem)(r,(t=>R.call(this,t))),this;I.call(this,e);const n={...e,type:(0,h.getJSONTypes)(e.type),schemaType:(0,h.getJSONTypes)(e.schemaType)};return(0,d.eachItem)(r,0===n.type.length?t=>R.call(this,t,n):t=>n.type.forEach((e=>R.call(this,t,n,e)))),this}getKeyword(t){const e=this.RULES.all[t];return"object"==typeof e?e.definition:!!e}removeKeyword(t){const{RULES:e}=this;delete e.keywords[t],delete e.all[t];for(const r of e.rules){const e=r.rules.findIndex((e=>e.keyword===t));e>=0&&r.rules.splice(e,1)}return this}addFormat(t,e){return"string"==typeof e&&(e=new RegExp(e)),this.formats[t]=e,this}errorsText(t=this.errors,{separator:e=", ",dataVar:r="data"}={}){return t&&0!==t.length?t.map((t=>`${r}${t.instancePath} ${t.message}`)).reduce(((t,r)=>t+e+r)):"No errors"}$dataMetaSchema(t,e){const r=this.RULES.all;t=JSON.parse(JSON.stringify(t));for(const n of e){const e=n.split("/").slice(1);let i=t;for(const t of e)i=i[t];for(const t in r){const e=r[t];if("object"!=typeof e)continue;const{$data:n}=e.definition,s=i[t];n&&s&&(i[t]=L(s))}}return t}_removeAllSchemas(t,e){for(const r in t){const n=t[r];e&&!e.test(r)||("string"==typeof n?delete t[r]:n&&!n.meta&&(this._cache.delete(n.schema),delete t[r]))}}_addSchema(t,e,r,n=this.opts.validateSchema,i=this.opts.addUsedSchema){let s;const{schemaId:o}=this.opts;if("object"==typeof t)s=t[o];else{if(this.opts.jtd)throw new Error("schema must be object");if("boolean"!=typeof t)throw new Error("schema must be object or boolean")}let a=this._cache.get(t);if(void 0!==a)return a;r=(0,u.normalizeId)(s||r);const c=u.getSchemaRefs.call(this,t,r);return a=new l.SchemaEnv({schema:t,schemaId:o,meta:e,baseId:r,localRefs:c}),this._cache.set(a.schema,a),i&&!r.startsWith("#")&&(r&&this._checkUnique(r),this.refs[r]=a),n&&this.validateSchema(t,!0),a}_checkUnique(t){if(this.schemas[t]||this.refs[t])throw new Error(`schema with key or id "${t}" already exists`)}_compileSchemaEnv(t){if(t.meta?this._compileMetaSchema(t):l.compileSchema.call(this,t),!t.validate)throw new Error("ajv implementation error");return t.validate}_compileMetaSchema(t){const e=this.opts;this.opts=this._metaOpts;try{l.compileSchema.call(this,t)}finally{this.opts=e}}}function x(t,e,r,n="error"){for(const i in t){const s=i;s in e&&this.logger[n](`${r}: option ${i}. ${t[s]}`)}}function E(t){return t=(0,u.normalizeId)(t),this.schemas[t]||this.refs[t]}function S(){const t=this.opts.schemas;if(t)if(Array.isArray(t))this.addSchema(t);else for(const e in t)this.addSchema(t[e],e)}function A(){for(const t in this.opts.formats){const e=this.opts.formats[t];e&&this.addFormat(t,e)}}function P(t){if(Array.isArray(t))this.addVocabulary(t);else{this.logger.warn("keywords option as map is deprecated, pass array");for(const e in t){const r=t[e];r.keyword||(r.keyword=e),this.addKeyword(r)}}}function T(){const t={...this.opts};for(const e of g)delete t[e];return t}w.ValidationError=s.default,w.MissingRefError=o.default,e.default=w;const C={log(){},warn(){},error(){}},M=/^[a-z_$][a-z0-9_$:-]*$/i;function O(t,e){const{RULES:r}=this;if((0,d.eachItem)(t,(t=>{if(r.keywords[t])throw new Error(`Keyword ${t} is already defined`);if(!M.test(t))throw new Error(`Keyword ${t} has invalid name`)})),e&&e.$data&&!("code"in e)&&!("validate"in e))throw new Error('$data keyword must have "code" or "validate" function')}function R(t,e,r){var n;const i=null==e?void 0:e.post;if(r&&i)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:s}=this;let o=i?s.post:s.rules.find((({type:t})=>t===r));if(o||(o={type:r,rules:[]},s.rules.push(o)),s.keywords[t]=!0,!e)return;const a={keyword:t,definition:{...e,type:(0,h.getJSONTypes)(e.type),schemaType:(0,h.getJSONTypes)(e.schemaType)}};e.before?D.call(this,o,a,e.before):o.rules.push(a),s.all[t]=a,null===(n=e.implements)||void 0===n||n.forEach((t=>this.addKeyword(t)))}function D(t,e,r){const n=t.rules.findIndex((t=>t.keyword===r));n>=0?t.rules.splice(n,0,e):(t.rules.push(e),this.logger.warn(`rule ${r} is not defined`))}function I(t){let{metaSchema:e}=t;void 0!==e&&(t.$data&&this.opts.$data&&(e=L(e)),t.validateSchema=this.compile(e,!0))}const k={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function L(t){return{anyOf:[t,k]}}},79781:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(38792);n.code='require("ajv/dist/runtime/equal").default',e.default=n},83252:(t,e)=>{"use strict";function r(t){const e=t.length;let r,n=0,i=0;for(;i<e;)n++,r=t.charCodeAt(i++),r>=55296&&r<=56319&&i<e&&(r=t.charCodeAt(i),56320==(64512&r)&&i++);return n}Object.defineProperty(e,"__esModule",{value:!0}),e.default=r,r.code='require("ajv/dist/runtime/ucs2length").default'},80655:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(79639);n.code='require("ajv/dist/runtime/uri").default',e.default=n},99079:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});class r extends Error{constructor(t){super("validation failed"),this.errors=t,this.ajv=this.validation=!0}}e.default=r},62338:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.validateAdditionalItems=void 0;const n=r(6394),i=r(88938),s={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:({params:{len:t}})=>n.str`must NOT have more than ${t} items`,params:({params:{len:t}})=>n._`{limit: ${t}}`},code(t){const{parentSchema:e,it:r}=t,{items:n}=e;Array.isArray(n)?o(t,n):(0,i.checkStrictMode)(r,'"additionalItems" is ignored when "items" is not an array of schemas')}};function o(t,e){const{gen:r,schema:s,data:o,keyword:a,it:l}=t;l.items=!0;const c=r.const("len",n._`${o}.length`);if(!1===s)t.setParams({len:e.length}),t.pass(n._`${c} <= ${e.length}`);else if("object"==typeof s&&!(0,i.alwaysValidSchema)(l,s)){const s=r.var("valid",n._`${c} <= ${e.length}`);r.if((0,n.not)(s),(()=>function(s){r.forRange("i",e.length,c,(e=>{t.subschema({keyword:a,dataProp:e,dataPropType:i.Type.Num},s),l.allErrors||r.if((0,n.not)(s),(()=>r.break()))}))}(s))),t.ok(s)}}e.validateAdditionalItems=o,e.default=s},9865:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(85154),i=r(6394),s=r(44),o=r(88938),a={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:t})=>i._`{additionalProperty: ${t.additionalProperty}}`},code(t){const{gen:e,schema:r,parentSchema:a,data:l,errsCount:c,it:u}=t;if(!c)throw new Error("ajv implementation error");const{allErrors:h,opts:d}=u;if(u.props=!0,"all"!==d.removeAdditional&&(0,o.alwaysValidSchema)(u,r))return;const f=(0,n.allSchemaProperties)(a.properties),p=(0,n.allSchemaProperties)(a.patternProperties);function m(t){e.code(i._`delete ${l}[${t}]`)}function g(n){if("all"===d.removeAdditional||d.removeAdditional&&!1===r)m(n);else{if(!1===r)return t.setParams({additionalProperty:n}),t.error(),void(h||e.break());if("object"==typeof r&&!(0,o.alwaysValidSchema)(u,r)){const r=e.name("valid");"failing"===d.removeAdditional?(y(n,r,!1),e.if((0,i.not)(r),(()=>{t.reset(),m(n)}))):(y(n,r),h||e.if((0,i.not)(r),(()=>e.break())))}}}function y(e,r,n){const i={keyword:"additionalProperties",dataProp:e,dataPropType:o.Type.Str};!1===n&&Object.assign(i,{compositeRule:!0,createErrors:!1,allErrors:!1}),t.subschema(i,r)}e.forIn("key",l,(r=>{f.length||p.length?e.if(function(r){let s;if(f.length>8){const t=(0,o.schemaRefOrVal)(u,a.properties,"properties");s=(0,n.isOwnProperty)(e,t,r)}else s=f.length?(0,i.or)(...f.map((t=>i._`${r} === ${t}`))):i.nil;return p.length&&(s=(0,i.or)(s,...p.map((e=>i._`${(0,n.usePattern)(t,e)}.test(${r})`)))),(0,i.not)(s)}(r),(()=>g(r))):g(r)})),t.ok(i._`${c} === ${s.default.errors}`)}};e.default=a},39051:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(88938),i={keyword:"allOf",schemaType:"array",code(t){const{gen:e,schema:r,it:i}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");const s=e.name("valid");r.forEach(((e,r)=>{if((0,n.alwaysValidSchema)(i,e))return;const o=t.subschema({keyword:"allOf",schemaProp:r},s);t.ok(s),t.mergeEvaluated(o)}))}};e.default=i},58326:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:r(85154).validateUnion,error:{message:"must match a schema in anyOf"}};e.default=n},38108:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i=r(88938),s={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:({params:{min:t,max:e}})=>void 0===e?n.str`must contain at least ${t} valid item(s)`:n.str`must contain at least ${t} and no more than ${e} valid item(s)`,params:({params:{min:t,max:e}})=>void 0===e?n._`{minContains: ${t}}`:n._`{minContains: ${t}, maxContains: ${e}}`},code(t){const{gen:e,schema:r,parentSchema:s,data:o,it:a}=t;let l,c;const{minContains:u,maxContains:h}=s;a.opts.next?(l=void 0===u?1:u,c=h):l=1;const d=e.const("len",n._`${o}.length`);if(t.setParams({min:l,max:c}),void 0===c&&0===l)return void(0,i.checkStrictMode)(a,'"minContains" == 0 without "maxContains": "contains" keyword ignored');if(void 0!==c&&l>c)return(0,i.checkStrictMode)(a,'"minContains" > "maxContains" is always invalid'),void t.fail();if((0,i.alwaysValidSchema)(a,r)){let e=n._`${d} >= ${l}`;return void 0!==c&&(e=n._`${e} && ${d} <= ${c}`),void t.pass(e)}a.items=!0;const f=e.name("valid");function p(){const t=e.name("_valid"),r=e.let("count",0);m(t,(()=>e.if(t,(()=>function(t){e.code(n._`${t}++`),void 0===c?e.if(n._`${t} >= ${l}`,(()=>e.assign(f,!0).break())):(e.if(n._`${t} > ${c}`,(()=>e.assign(f,!1).break())),1===l?e.assign(f,!0):e.if(n._`${t} >= ${l}`,(()=>e.assign(f,!0))))}(r)))))}function m(r,n){e.forRange("i",0,d,(e=>{t.subschema({keyword:"contains",dataProp:e,dataPropType:i.Type.Num,compositeRule:!0},r),n()}))}void 0===c&&1===l?m(f,(()=>e.if(f,(()=>e.break())))):0===l?(e.let(f,!0),void 0!==c&&e.if(n._`${o}.length > 0`,p)):(e.let(f,!1),p()),t.result(f,(()=>t.reset()))}};e.default=s},64076:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.validateSchemaDeps=e.validatePropertyDeps=e.error=void 0;const n=r(6394),i=r(88938),s=r(85154);e.error={message:({params:{property:t,depsCount:e,deps:r}})=>{const i=1===e?"property":"properties";return n.str`must have ${i} ${r} when property ${t} is present`},params:({params:{property:t,depsCount:e,deps:r,missingProperty:i}})=>n._`{property: ${t},
6
+ missingProperty: ${i},
7
+ depsCount: ${e},
8
+ deps: ${r}}`};const o={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(t){const[e,r]=function({schema:t}){const e={},r={};for(const n in t)"__proto__"!==n&&((Array.isArray(t[n])?e:r)[n]=t[n]);return[e,r]}(t);a(t,e),l(t,r)}};function a(t,e=t.schema){const{gen:r,data:i,it:o}=t;if(0===Object.keys(e).length)return;const a=r.let("missing");for(const l in e){const c=e[l];if(0===c.length)continue;const u=(0,s.propertyInData)(r,i,l,o.opts.ownProperties);t.setParams({property:l,depsCount:c.length,deps:c.join(", ")}),o.allErrors?r.if(u,(()=>{for(const e of c)(0,s.checkReportMissingProp)(t,e)})):(r.if(n._`${u} && (${(0,s.checkMissingProp)(t,c,a)})`),(0,s.reportMissingProp)(t,a),r.else())}}function l(t,e=t.schema){const{gen:r,data:n,keyword:o,it:a}=t,l=r.name("valid");for(const c in e)(0,i.alwaysValidSchema)(a,e[c])||(r.if((0,s.propertyInData)(r,n,c,a.opts.ownProperties),(()=>{const e=t.subschema({keyword:o,schemaProp:c},l);t.mergeValidEvaluated(e,l)}),(()=>r.var(l,!0))),t.ok(l))}e.validatePropertyDeps=a,e.validateSchemaDeps=l,e.default=o},254:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i=r(88938),s={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:t})=>n.str`must match "${t.ifClause}" schema`,params:({params:t})=>n._`{failingKeyword: ${t.ifClause}}`},code(t){const{gen:e,parentSchema:r,it:s}=t;void 0===r.then&&void 0===r.else&&(0,i.checkStrictMode)(s,'"if" without "then" and "else" is ignored');const a=o(s,"then"),l=o(s,"else");if(!a&&!l)return;const c=e.let("valid",!0),u=e.name("_valid");if(function(){const e=t.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},u);t.mergeEvaluated(e)}(),t.reset(),a&&l){const r=e.let("ifClause");t.setParams({ifClause:r}),e.if(u,h("then",r),h("else",r))}else a?e.if(u,h("then")):e.if((0,n.not)(u),h("else"));function h(r,i){return()=>{const s=t.subschema({keyword:r},u);e.assign(c,u),t.mergeValidEvaluated(s,c),i?e.assign(i,n._`${r}`):t.setParams({ifClause:r})}}t.pass(c,(()=>t.error(!0)))}};function o(t,e){const r=t.schema[e];return void 0!==r&&!(0,i.alwaysValidSchema)(t,r)}e.default=s},36481:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(62338),i=r(68981),s=r(74761),o=r(6297),a=r(38108),l=r(64076),c=r(77998),u=r(9865),h=r(53052),d=r(74950),f=r(9900),p=r(58326),m=r(8192),g=r(39051),y=r(254),v=r(34167);e.default=function(t=!1){const e=[f.default,p.default,m.default,g.default,y.default,v.default,c.default,u.default,l.default,h.default,d.default];return t?e.push(i.default,o.default):e.push(n.default,s.default),e.push(a.default),e}},74761:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.validateTuple=void 0;const n=r(6394),i=r(88938),s=r(85154),o={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(t){const{schema:e,it:r}=t;if(Array.isArray(e))return a(t,"additionalItems",e);r.items=!0,(0,i.alwaysValidSchema)(r,e)||t.ok((0,s.validateArray)(t))}};function a(t,e,r=t.schema){const{gen:s,parentSchema:o,data:a,keyword:l,it:c}=t;!function(t){const{opts:n,errSchemaPath:s}=c,o=r.length,a=o===t.minItems&&(o===t.maxItems||!1===t[e]);if(n.strictTuples&&!a){const t=`"${l}" is ${o}-tuple, but minItems or maxItems/${e} are not specified or different at path "${s}"`;(0,i.checkStrictMode)(c,t,n.strictTuples)}}(o),c.opts.unevaluated&&r.length&&!0!==c.items&&(c.items=i.mergeEvaluated.items(s,r.length,c.items));const u=s.name("valid"),h=s.const("len",n._`${a}.length`);r.forEach(((e,r)=>{(0,i.alwaysValidSchema)(c,e)||(s.if(n._`${h} > ${r}`,(()=>t.subschema({keyword:l,schemaProp:r,dataProp:r},u))),t.ok(u))}))}e.validateTuple=a,e.default=o},6297:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i=r(88938),s=r(85154),o=r(62338),a={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:({params:{len:t}})=>n.str`must NOT have more than ${t} items`,params:({params:{len:t}})=>n._`{limit: ${t}}`},code(t){const{schema:e,parentSchema:r,it:n}=t,{prefixItems:a}=r;n.items=!0,(0,i.alwaysValidSchema)(n,e)||(a?(0,o.validateAdditionalItems)(t,a):t.ok((0,s.validateArray)(t)))}};e.default=a},9900:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(88938),i={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(t){const{gen:e,schema:r,it:i}=t;if((0,n.alwaysValidSchema)(i,r))return void t.fail();const s=e.name("valid");t.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},s),t.failResult(s,(()=>t.reset()),(()=>t.error()))},error:{message:"must NOT be valid"}};e.default=i},8192:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i=r(88938),s={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:t})=>n._`{passingSchemas: ${t.passing}}`},code(t){const{gen:e,schema:r,parentSchema:s,it:o}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");if(o.opts.discriminator&&s.discriminator)return;const a=r,l=e.let("valid",!1),c=e.let("passing",null),u=e.name("_valid");t.setParams({passing:c}),e.block((function(){a.forEach(((r,s)=>{let a;(0,i.alwaysValidSchema)(o,r)?e.var(u,!0):a=t.subschema({keyword:"oneOf",schemaProp:s,compositeRule:!0},u),s>0&&e.if(n._`${u} && ${l}`).assign(l,!1).assign(c,n._`[${c}, ${s}]`).else(),e.if(u,(()=>{e.assign(l,!0),e.assign(c,s),a&&t.mergeEvaluated(a,n.Name)}))}))})),t.result(l,(()=>t.reset()),(()=>t.error(!0)))}};e.default=s},74950:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(85154),i=r(6394),s=r(88938),o=r(88938),a={keyword:"patternProperties",type:"object",schemaType:"object",code(t){const{gen:e,schema:r,data:a,parentSchema:l,it:c}=t,{opts:u}=c,h=(0,n.allSchemaProperties)(r),d=h.filter((t=>(0,s.alwaysValidSchema)(c,r[t])));if(0===h.length||d.length===h.length&&(!c.opts.unevaluated||!0===c.props))return;const f=u.strictSchema&&!u.allowMatchingProperties&&l.properties,p=e.name("valid");!0===c.props||c.props instanceof i.Name||(c.props=(0,o.evaluatedPropsToName)(e,c.props));const{props:m}=c;function g(t){for(const e in f)new RegExp(t).test(e)&&(0,s.checkStrictMode)(c,`property ${e} matches pattern ${t} (use allowMatchingProperties)`)}function y(r){e.forIn("key",a,(s=>{e.if(i._`${(0,n.usePattern)(t,r)}.test(${s})`,(()=>{const n=d.includes(r);n||t.subschema({keyword:"patternProperties",schemaProp:r,dataProp:s,dataPropType:o.Type.Str},p),c.opts.unevaluated&&!0!==m?e.assign(i._`${m}[${s}]`,!0):n||c.allErrors||e.if((0,i.not)(p),(()=>e.break()))}))}))}!function(){for(const t of h)f&&g(t),c.allErrors?y(t):(e.var(p,!0),y(t),e.if(p))}()}};e.default=a},68981:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(74761),i={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:t=>(0,n.validateTuple)(t,"items")};e.default=i},53052:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(55087),i=r(85154),s=r(88938),o=r(9865),a={keyword:"properties",type:"object",schemaType:"object",code(t){const{gen:e,schema:r,parentSchema:a,data:l,it:c}=t;"all"===c.opts.removeAdditional&&void 0===a.additionalProperties&&o.default.code(new n.KeywordCxt(c,o.default,"additionalProperties"));const u=(0,i.allSchemaProperties)(r);for(const t of u)c.definedProperties.add(t);c.opts.unevaluated&&u.length&&!0!==c.props&&(c.props=s.mergeEvaluated.props(e,(0,s.toHash)(u),c.props));const h=u.filter((t=>!(0,s.alwaysValidSchema)(c,r[t])));if(0===h.length)return;const d=e.name("valid");for(const r of h)f(r)?p(r):(e.if((0,i.propertyInData)(e,l,r,c.opts.ownProperties)),p(r),c.allErrors||e.else().var(d,!0),e.endIf()),t.it.definedProperties.add(r),t.ok(d);function f(t){return c.opts.useDefaults&&!c.compositeRule&&void 0!==r[t].default}function p(e){t.subschema({keyword:"properties",schemaProp:e,dataProp:e},d)}}};e.default=a},77998:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i=r(88938),s={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:t})=>n._`{propertyName: ${t.propertyName}}`},code(t){const{gen:e,schema:r,data:s,it:o}=t;if((0,i.alwaysValidSchema)(o,r))return;const a=e.name("valid");e.forIn("key",s,(r=>{t.setParams({propertyName:r}),t.subschema({keyword:"propertyNames",data:r,dataTypes:["string"],propertyName:r,compositeRule:!0},a),e.if((0,n.not)(a),(()=>{t.error(!0),o.allErrors||e.break()}))})),t.ok(a)}};e.default=s},34167:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(88938),i={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:t,parentSchema:e,it:r}){void 0===e.if&&(0,n.checkStrictMode)(r,`"${t}" without "if" is ignored`)}};e.default=i},85154:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.validateUnion=e.validateArray=e.usePattern=e.callValidateCode=e.schemaProperties=e.allSchemaProperties=e.noPropertyInData=e.propertyInData=e.isOwnProperty=e.hasPropFunc=e.reportMissingProp=e.checkMissingProp=e.checkReportMissingProp=void 0;const n=r(6394),i=r(88938),s=r(44),o=r(88938);function a(t){return t.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:n._`Object.prototype.hasOwnProperty`})}function l(t,e,r){return n._`${a(t)}.call(${e}, ${r})`}function c(t,e,r,i){const s=n._`${e}${(0,n.getProperty)(r)} === undefined`;return i?(0,n.or)(s,(0,n.not)(l(t,e,r))):s}function u(t){return t?Object.keys(t).filter((t=>"__proto__"!==t)):[]}e.checkReportMissingProp=function(t,e){const{gen:r,data:i,it:s}=t;r.if(c(r,i,e,s.opts.ownProperties),(()=>{t.setParams({missingProperty:n._`${e}`},!0),t.error()}))},e.checkMissingProp=function({gen:t,data:e,it:{opts:r}},i,s){return(0,n.or)(...i.map((i=>(0,n.and)(c(t,e,i,r.ownProperties),n._`${s} = ${i}`))))},e.reportMissingProp=function(t,e){t.setParams({missingProperty:e},!0),t.error()},e.hasPropFunc=a,e.isOwnProperty=l,e.propertyInData=function(t,e,r,i){const s=n._`${e}${(0,n.getProperty)(r)} !== undefined`;return i?n._`${s} && ${l(t,e,r)}`:s},e.noPropertyInData=c,e.allSchemaProperties=u,e.schemaProperties=function(t,e){return u(e).filter((r=>!(0,i.alwaysValidSchema)(t,e[r])))},e.callValidateCode=function({schemaCode:t,data:e,it:{gen:r,topSchemaRef:i,schemaPath:o,errorPath:a},it:l},c,u,h){const d=h?n._`${t}, ${e}, ${i}${o}`:e,f=[[s.default.instancePath,(0,n.strConcat)(s.default.instancePath,a)],[s.default.parentData,l.parentData],[s.default.parentDataProperty,l.parentDataProperty],[s.default.rootData,s.default.rootData]];l.opts.dynamicRef&&f.push([s.default.dynamicAnchors,s.default.dynamicAnchors]);const p=n._`${d}, ${r.object(...f)}`;return u!==n.nil?n._`${c}.call(${u}, ${p})`:n._`${c}(${p})`};const h=n._`new RegExp`;e.usePattern=function({gen:t,it:{opts:e}},r){const i=e.unicodeRegExp?"u":"",{regExp:s}=e.code,a=s(r,i);return t.scopeValue("pattern",{key:a.toString(),ref:a,code:n._`${"new RegExp"===s.code?h:(0,o.useFunc)(t,s)}(${r}, ${i})`})},e.validateArray=function(t){const{gen:e,data:r,keyword:s,it:o}=t,a=e.name("valid");if(o.allErrors){const t=e.let("valid",!0);return l((()=>e.assign(t,!1))),t}return e.var(a,!0),l((()=>e.break())),a;function l(o){const l=e.const("len",n._`${r}.length`);e.forRange("i",0,l,(r=>{t.subschema({keyword:s,dataProp:r,dataPropType:i.Type.Num},a),e.if((0,n.not)(a),o)}))}},e.validateUnion=function(t){const{gen:e,schema:r,keyword:s,it:o}=t;if(!Array.isArray(r))throw new Error("ajv implementation error");if(r.some((t=>(0,i.alwaysValidSchema)(o,t)))&&!o.opts.unevaluated)return;const a=e.let("valid",!1),l=e.name("_valid");e.block((()=>r.forEach(((r,i)=>{const o=t.subschema({keyword:s,schemaProp:i,compositeRule:!0},l);e.assign(a,n._`${a} || ${l}`),t.mergeValidEvaluated(o,l)||e.if((0,n.not)(a))})))),t.result(a,(()=>t.reset()),(()=>t.error(!0)))}},68202:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const r={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};e.default=r},17615:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(68202),i=r(31658),s=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",n.default,i.default];e.default=s},31658:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.callRef=e.getValidate=void 0;const n=r(96516),i=r(85154),s=r(6394),o=r(44),a=r(13312),l=r(88938),c={keyword:"$ref",schemaType:"string",code(t){const{gen:e,schema:r,it:i}=t,{baseId:o,schemaEnv:l,validateName:c,opts:d,self:f}=i,{root:p}=l;if(("#"===r||"#/"===r)&&o===p.baseId)return function(){if(l===p)return h(t,c,l,l.$async);const r=e.scopeValue("root",{ref:p});return h(t,s._`${r}.validate`,p,p.$async)}();const m=a.resolveRef.call(f,p,o,r);if(void 0===m)throw new n.default(i.opts.uriResolver,o,r);return m instanceof a.SchemaEnv?function(e){const r=u(t,e);h(t,r,e,e.$async)}(m):function(n){const i=e.scopeValue("schema",!0===d.code.source?{ref:n,code:(0,s.stringify)(n)}:{ref:n}),o=e.name("valid"),a=t.subschema({schema:n,dataTypes:[],schemaPath:s.nil,topSchemaRef:i,errSchemaPath:r},o);t.mergeEvaluated(a),t.ok(o)}(m)}};function u(t,e){const{gen:r}=t;return e.validate?r.scopeValue("validate",{ref:e.validate}):s._`${r.scopeValue("wrapper",{ref:e})}.validate`}function h(t,e,r,n){const{gen:a,it:c}=t,{allErrors:u,schemaEnv:h,opts:d}=c,f=d.passContext?o.default.this:s.nil;function p(t){const e=s._`${t}.errors`;a.assign(o.default.vErrors,s._`${o.default.vErrors} === null ? ${e} : ${o.default.vErrors}.concat(${e})`),a.assign(o.default.errors,s._`${o.default.vErrors}.length`)}function m(t){var e;if(!c.opts.unevaluated)return;const n=null===(e=null==r?void 0:r.validate)||void 0===e?void 0:e.evaluated;if(!0!==c.props)if(n&&!n.dynamicProps)void 0!==n.props&&(c.props=l.mergeEvaluated.props(a,n.props,c.props));else{const e=a.var("props",s._`${t}.evaluated.props`);c.props=l.mergeEvaluated.props(a,e,c.props,s.Name)}if(!0!==c.items)if(n&&!n.dynamicItems)void 0!==n.items&&(c.items=l.mergeEvaluated.items(a,n.items,c.items));else{const e=a.var("items",s._`${t}.evaluated.items`);c.items=l.mergeEvaluated.items(a,e,c.items,s.Name)}}n?function(){if(!h.$async)throw new Error("async schema referenced by sync schema");const r=a.let("valid");a.try((()=>{a.code(s._`await ${(0,i.callValidateCode)(t,e,f)}`),m(e),u||a.assign(r,!0)}),(t=>{a.if(s._`!(${t} instanceof ${c.ValidationError})`,(()=>a.throw(t))),p(t),u||a.assign(r,!1)})),t.ok(r)}():t.result((0,i.callValidateCode)(t,e,f),(()=>m(e)),(()=>p(e)))}e.getValidate=u,e.callRef=h,e.default=c},91944:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i=r(50253),s=r(13312),o=r(96516),a=r(88938),l={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:t,tagName:e}})=>t===i.DiscrError.Tag?`tag "${e}" must be string`:`value of tag "${e}" must be in oneOf`,params:({params:{discrError:t,tag:e,tagName:r}})=>n._`{error: ${t}, tag: ${r}, tagValue: ${e}}`},code(t){const{gen:e,data:r,schema:l,parentSchema:c,it:u}=t,{oneOf:h}=c;if(!u.opts.discriminator)throw new Error("discriminator: requires discriminator option");const d=l.propertyName;if("string"!=typeof d)throw new Error("discriminator: requires propertyName");if(l.mapping)throw new Error("discriminator: mapping is not supported");if(!h)throw new Error("discriminator: requires oneOf keyword");const f=e.let("valid",!1),p=e.const("tag",n._`${r}${(0,n.getProperty)(d)}`);function m(r){const i=e.name("valid"),s=t.subschema({keyword:"oneOf",schemaProp:r},i);return t.mergeEvaluated(s,n.Name),i}e.if(n._`typeof ${p} == "string"`,(()=>function(){const r=function(){var t;const e={},r=i(c);let n=!0;for(let e=0;e<h.length;e++){let c=h[e];if((null==c?void 0:c.$ref)&&!(0,a.schemaHasRulesButRef)(c,u.self.RULES)){const t=c.$ref;if(c=s.resolveRef.call(u.self,u.schemaEnv.root,u.baseId,t),c instanceof s.SchemaEnv&&(c=c.schema),void 0===c)throw new o.default(u.opts.uriResolver,u.baseId,t)}const f=null===(t=null==c?void 0:c.properties)||void 0===t?void 0:t[d];if("object"!=typeof f)throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${d}"`);n=n&&(r||i(c)),l(f,e)}if(!n)throw new Error(`discriminator: "${d}" must be required`);return e;function i({required:t}){return Array.isArray(t)&&t.includes(d)}function l(t,e){if(t.const)f(t.const,e);else{if(!t.enum)throw new Error(`discriminator: "properties/${d}" must have "const" or "enum"`);for(const r of t.enum)f(r,e)}}function f(t,r){if("string"!=typeof t||t in e)throw new Error(`discriminator: "${d}" values must be unique strings`);e[t]=r}}();e.if(!1);for(const t in r)e.elseIf(n._`${p} === ${t}`),e.assign(f,m(r[t]));e.else(),t.error(!1,{discrError:i.DiscrError.Mapping,tag:p,tagName:d}),e.endIf()}()),(()=>t.error(!1,{discrError:i.DiscrError.Tag,tag:p,tagName:d}))),t.ok(f)}};e.default=l},50253:(t,e)=>{"use strict";var r;Object.defineProperty(e,"__esModule",{value:!0}),e.DiscrError=void 0,function(t){t.Tag="tag",t.Mapping="mapping"}(r||(e.DiscrError=r={}))},38159:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(17615),i=r(19915),s=r(36481),o=r(85083),a=r(98034),l=[n.default,i.default,(0,s.default)(),o.default,a.metadataVocabulary,a.contentVocabulary];e.default=l},6752:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:t})=>n.str`must match format "${t}"`,params:({schemaCode:t})=>n._`{format: ${t}}`},code(t,e){const{gen:r,data:i,$data:s,schema:o,schemaCode:a,it:l}=t,{opts:c,errSchemaPath:u,schemaEnv:h,self:d}=l;c.validateFormats&&(s?function(){const s=r.scopeValue("formats",{ref:d.formats,code:c.code.formats}),o=r.const("fDef",n._`${s}[${a}]`),l=r.let("fType"),u=r.let("format");r.if(n._`typeof ${o} == "object" && !(${o} instanceof RegExp)`,(()=>r.assign(l,n._`${o}.type || "string"`).assign(u,n._`${o}.validate`)),(()=>r.assign(l,n._`"string"`).assign(u,o))),t.fail$data((0,n.or)(!1===c.strictSchema?n.nil:n._`${a} && !${u}`,function(){const t=h.$async?n._`(${o}.async ? await ${u}(${i}) : ${u}(${i}))`:n._`${u}(${i})`,r=n._`(typeof ${u} == "function" ? ${t} : ${u}.test(${i}))`;return n._`${u} && ${u} !== true && ${l} === ${e} && !${r}`}()))}():function(){const s=d.formats[o];if(!s)return void function(){if(!1!==c.strictSchema)throw new Error(t());function t(){return`unknown format "${o}" ignored in schema at path "${u}"`}d.logger.warn(t())}();if(!0===s)return;const[a,l,f]=function(t){const e=t instanceof RegExp?(0,n.regexpCode)(t):c.code.formats?n._`${c.code.formats}${(0,n.getProperty)(o)}`:void 0,i=r.scopeValue("formats",{key:o,ref:t,code:e});return"object"!=typeof t||t instanceof RegExp?["string",t,i]:[t.type||"string",t.validate,n._`${i}.validate`]}(s);a===e&&t.pass(function(){if("object"==typeof s&&!(s instanceof RegExp)&&s.async){if(!h.$async)throw new Error("async format in sync schema");return n._`await ${f}(${i})`}return"function"==typeof l?n._`${f}(${i})`:n._`${f}.test(${i})`}())}())}};e.default=i},85083:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=[r(6752).default];e.default=n},98034:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.contentVocabulary=e.metadataVocabulary=void 0,e.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],e.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]},2736:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i=r(88938),s=r(79781),o={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:({schemaCode:t})=>n._`{allowedValue: ${t}}`},code(t){const{gen:e,data:r,$data:o,schemaCode:a,schema:l}=t;o||l&&"object"==typeof l?t.fail$data(n._`!${(0,i.useFunc)(e,s.default)}(${r}, ${a})`):t.fail(n._`${l} !== ${r}`)}};e.default=o},43510:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i=r(88938),s=r(79781),o={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:({schemaCode:t})=>n._`{allowedValues: ${t}}`},code(t){const{gen:e,data:r,$data:o,schema:a,schemaCode:l,it:c}=t;if(!o&&0===a.length)throw new Error("enum must have non-empty array");const u=a.length>=c.opts.loopEnum;let h;const d=()=>null!=h?h:h=(0,i.useFunc)(e,s.default);let f;if(u||o)f=e.let("valid"),t.block$data(f,(function(){e.assign(f,!1),e.forOf("v",l,(t=>e.if(n._`${d()}(${r}, ${t})`,(()=>e.assign(f,!0).break()))))}));else{if(!Array.isArray(a))throw new Error("ajv implementation error");const t=e.const("vSchema",l);f=(0,n.or)(...a.map(((e,i)=>function(t,e){const i=a[e];return"object"==typeof i&&null!==i?n._`${d()}(${r}, ${t}[${e}])`:n._`${r} === ${i}`}(t,i))))}t.pass(f)}};e.default=o},19915:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(67005),i=r(30206),s=r(42192),o=r(67709),a=r(58005),l=r(87882),c=r(32910),u=r(28298),h=r(2736),d=r(43510),f=[n.default,i.default,s.default,o.default,a.default,l.default,c.default,u.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},h.default,d.default];e.default=f},32910:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message({keyword:t,schemaCode:e}){const r="maxItems"===t?"more":"fewer";return n.str`must NOT have ${r} than ${e} items`},params:({schemaCode:t})=>n._`{limit: ${t}}`},code(t){const{keyword:e,data:r,schemaCode:i}=t,s="maxItems"===e?n.operators.GT:n.operators.LT;t.fail$data(n._`${r}.length ${s} ${i}`)}};e.default=i},42192:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i=r(88938),s=r(83252),o={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message({keyword:t,schemaCode:e}){const r="maxLength"===t?"more":"fewer";return n.str`must NOT have ${r} than ${e} characters`},params:({schemaCode:t})=>n._`{limit: ${t}}`},code(t){const{keyword:e,data:r,schemaCode:o,it:a}=t,l="maxLength"===e?n.operators.GT:n.operators.LT,c=!1===a.opts.unicode?n._`${r}.length`:n._`${(0,i.useFunc)(t.gen,s.default)}(${r})`;t.fail$data(n._`${c} ${l} ${o}`)}};e.default=o},67005:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i=n.operators,s={maximum:{okStr:"<=",ok:i.LTE,fail:i.GT},minimum:{okStr:">=",ok:i.GTE,fail:i.LT},exclusiveMaximum:{okStr:"<",ok:i.LT,fail:i.GTE},exclusiveMinimum:{okStr:">",ok:i.GT,fail:i.LTE}},o={message:({keyword:t,schemaCode:e})=>n.str`must be ${s[t].okStr} ${e}`,params:({keyword:t,schemaCode:e})=>n._`{comparison: ${s[t].okStr}, limit: ${e}}`},a={keyword:Object.keys(s),type:"number",schemaType:"number",$data:!0,error:o,code(t){const{keyword:e,data:r,schemaCode:i}=t;t.fail$data(n._`${r} ${s[e].fail} ${i} || isNaN(${r})`)}};e.default=a},58005:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message({keyword:t,schemaCode:e}){const r="maxProperties"===t?"more":"fewer";return n.str`must NOT have ${r} than ${e} properties`},params:({schemaCode:t})=>n._`{limit: ${t}}`},code(t){const{keyword:e,data:r,schemaCode:i}=t,s="maxProperties"===e?n.operators.GT:n.operators.LT;t.fail$data(n._`Object.keys(${r}).length ${s} ${i}`)}};e.default=i},30206:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(6394),i={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:({schemaCode:t})=>n.str`must be multiple of ${t}`,params:({schemaCode:t})=>n._`{multipleOf: ${t}}`},code(t){const{gen:e,data:r,schemaCode:i,it:s}=t,o=s.opts.multipleOfPrecision,a=e.let("res"),l=o?n._`Math.abs(Math.round(${a}) - ${a}) > 1e-${o}`:n._`${a} !== parseInt(${a})`;t.fail$data(n._`(${i} === 0 || (${a} = ${r}/${i}, ${l}))`)}};e.default=i},67709:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(85154),i=r(6394),s={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:({schemaCode:t})=>i.str`must match pattern "${t}"`,params:({schemaCode:t})=>i._`{pattern: ${t}}`},code(t){const{data:e,$data:r,schema:s,schemaCode:o,it:a}=t,l=a.opts.unicodeRegExp?"u":"",c=r?i._`(new RegExp(${o}, ${l}))`:(0,n.usePattern)(t,s);t.fail$data(i._`!${c}.test(${e})`)}};e.default=s},87882:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(85154),i=r(6394),s=r(88938),o={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:({params:{missingProperty:t}})=>i.str`must have required property '${t}'`,params:({params:{missingProperty:t}})=>i._`{missingProperty: ${t}}`},code(t){const{gen:e,schema:r,schemaCode:o,data:a,$data:l,it:c}=t,{opts:u}=c;if(!l&&0===r.length)return;const h=r.length>=u.loopRequired;if(c.allErrors?function(){if(h||l)t.block$data(i.nil,d);else for(const e of r)(0,n.checkReportMissingProp)(t,e)}():function(){const s=e.let("missing");if(h||l){const r=e.let("valid",!0);t.block$data(r,(()=>function(r,s){t.setParams({missingProperty:r}),e.forOf(r,o,(()=>{e.assign(s,(0,n.propertyInData)(e,a,r,u.ownProperties)),e.if((0,i.not)(s),(()=>{t.error(),e.break()}))}),i.nil)}(s,r))),t.ok(r)}else e.if((0,n.checkMissingProp)(t,r,s)),(0,n.reportMissingProp)(t,s),e.else()}(),u.strictRequired){const e=t.parentSchema.properties,{definedProperties:n}=t.it;for(const t of r)if(void 0===(null==e?void 0:e[t])&&!n.has(t)){const e=`required property "${t}" is not defined at "${c.schemaEnv.baseId+c.errSchemaPath}" (strictRequired)`;(0,s.checkStrictMode)(c,e,c.opts.strictRequired)}}function d(){e.forOf("prop",o,(r=>{t.setParams({missingProperty:r}),e.if((0,n.noPropertyInData)(e,a,r,u.ownProperties),(()=>t.error()))}))}}};e.default=o},28298:(t,e,r)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});const n=r(14939),i=r(6394),s=r(88938),o=r(79781),a={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:({params:{i:t,j:e}})=>i.str`must NOT have duplicate items (items ## ${e} and ${t} are identical)`,params:({params:{i:t,j:e}})=>i._`{i: ${t}, j: ${e}}`},code(t){const{gen:e,data:r,$data:a,schema:l,parentSchema:c,schemaCode:u,it:h}=t;if(!a&&!l)return;const d=e.let("valid"),f=c.items?(0,n.getSchemaTypes)(c.items):[];function p(s,o){const a=e.name("item"),l=(0,n.checkDataTypes)(f,a,h.opts.strictNumbers,n.DataType.Wrong),c=e.const("indices",i._`{}`);e.for(i._`;${s}--;`,(()=>{e.let(a,i._`${r}[${s}]`),e.if(l,i._`continue`),f.length>1&&e.if(i._`typeof ${a} == "string"`,i._`${a} += "_"`),e.if(i._`typeof ${c}[${a}] == "number"`,(()=>{e.assign(o,i._`${c}[${a}]`),t.error(),e.assign(d,!1).break()})).code(i._`${c}[${a}] = ${s}`)}))}function m(n,a){const l=(0,s.useFunc)(e,o.default),c=e.name("outer");e.label(c).for(i._`;${n}--;`,(()=>e.for(i._`${a} = ${n}; ${a}--;`,(()=>e.if(i._`${l}(${r}[${n}], ${r}[${a}])`,(()=>{t.error(),e.assign(d,!1).break(c)}))))))}t.block$data(d,(function(){const n=e.let("i",i._`${r}.length`),s=e.let("j");t.setParams({i:n,j:s}),e.assign(d,!0),e.if(i._`${n} > 1`,(()=>(f.length>0&&!f.some((t=>"object"===t||"array"===t))?p:m)(n,s)))}),i._`${u} === false`),t.ok(d)}};e.default=a},80185:(t,e,r)=>{"use strict";var n;r.d(e,{A:()=>u});var i=new Uint8Array(16);function s(){if(!n&&!(n="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return n(i)}const o=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;for(var a=[],l=0;l<256;++l)a.push((l+256).toString(16).substr(1));const c=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=(a[t[e+0]]+a[t[e+1]]+a[t[e+2]]+a[t[e+3]]+"-"+a[t[e+4]]+a[t[e+5]]+"-"+a[t[e+6]]+a[t[e+7]]+"-"+a[t[e+8]]+a[t[e+9]]+"-"+a[t[e+10]]+a[t[e+11]]+a[t[e+12]]+a[t[e+13]]+a[t[e+14]]+a[t[e+15]]).toLowerCase();if(!function(t){return"string"==typeof t&&o.test(t)}(r))throw TypeError("Stringified UUID is invalid");return r},u=function(t,e,r){var n=(t=t||{}).random||(t.rng||s)();if(n[6]=15&n[6]|64,n[8]=63&n[8]|128,e){r=r||0;for(var i=0;i<16;++i)e[r+i]=n[i];return e}return c(n)}},32604:t=>{"use strict";t.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#","description":"Meta-schema for $data reference (JSON Schema extension proposal)","type":"object","required":["$data"],"properties":{"$data":{"type":"string","anyOf":[{"format":"relative-json-pointer"},{"format":"json-pointer"}]}},"additionalProperties":false}')},42710:t=>{"use strict";t.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"http://json-schema.org/draft-07/schema#","title":"Core schema meta-schema","definitions":{"schemaArray":{"type":"array","minItems":1,"items":{"$ref":"#"}},"nonNegativeInteger":{"type":"integer","minimum":0},"nonNegativeIntegerDefault0":{"allOf":[{"$ref":"#/definitions/nonNegativeInteger"},{"default":0}]},"simpleTypes":{"enum":["array","boolean","integer","null","number","object","string"]},"stringArray":{"type":"array","items":{"type":"string"},"uniqueItems":true,"default":[]}},"type":["object","boolean"],"properties":{"$id":{"type":"string","format":"uri-reference"},"$schema":{"type":"string","format":"uri"},"$ref":{"type":"string","format":"uri-reference"},"$comment":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"default":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"multipleOf":{"type":"number","exclusiveMinimum":0},"maximum":{"type":"number"},"exclusiveMaximum":{"type":"number"},"minimum":{"type":"number"},"exclusiveMinimum":{"type":"number"},"maxLength":{"$ref":"#/definitions/nonNegativeInteger"},"minLength":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"pattern":{"type":"string","format":"regex"},"additionalItems":{"$ref":"#"},"items":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/schemaArray"}],"default":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"contains":{"$ref":"#"},"maxProperties":{"$ref":"#/definitions/nonNegativeInteger"},"minProperties":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"required":{"$ref":"#/definitions/stringArray"},"additionalProperties":{"$ref":"#"},"definitions":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"properties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"patternProperties":{"type":"object","additionalProperties":{"$ref":"#"},"propertyNames":{"format":"regex"},"default":{}},"dependencies":{"type":"object","additionalProperties":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/stringArray"}]}},"propertyNames":{"$ref":"#"},"const":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"format":{"type":"string"},"contentMediaType":{"type":"string"},"contentEncoding":{"type":"string"},"if":{"$ref":"#"},"then":{"$ref":"#"},"else":{"$ref":"#"},"allOf":{"$ref":"#/definitions/schemaArray"},"anyOf":{"$ref":"#/definitions/schemaArray"},"oneOf":{"$ref":"#/definitions/schemaArray"},"not":{"$ref":"#"}},"default":true}')},34639:t=>{"use strict";t.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"https://geojson.org/schema/GeoJSON.json","title":"GeoJSON","oneOf":[{"title":"GeoJSON Point","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Point"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"number"}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON LineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["LineString"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON Polygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Polygon"]},"coordinates":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPoint","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPoint"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiLineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiLineString"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPolygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPolygon"]},"coordinates":{"type":"array","items":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON GeometryCollection","type":"object","required":["type","geometries"],"properties":{"type":{"type":"string","enum":["GeometryCollection"]},"geometries":{"type":"array","items":{"oneOf":[{"title":"GeoJSON Point","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Point"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"number"}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON LineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["LineString"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON Polygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Polygon"]},"coordinates":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPoint","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPoint"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiLineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiLineString"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPolygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPolygon"]},"coordinates":{"type":"array","items":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}}]}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON Feature","type":"object","required":["type","properties","geometry"],"properties":{"type":{"type":"string","enum":["Feature"]},"id":{"oneOf":[{"type":"number"},{"type":"string"}]},"properties":{"oneOf":[{"type":"null"},{"type":"object"}]},"geometry":{"oneOf":[{"type":"null"},{"title":"GeoJSON Point","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Point"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"number"}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON LineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["LineString"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON Polygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Polygon"]},"coordinates":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPoint","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPoint"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiLineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiLineString"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPolygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPolygon"]},"coordinates":{"type":"array","items":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON GeometryCollection","type":"object","required":["type","geometries"],"properties":{"type":{"type":"string","enum":["GeometryCollection"]},"geometries":{"type":"array","items":{"oneOf":[{"title":"GeoJSON Point","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Point"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"number"}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON LineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["LineString"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON Polygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Polygon"]},"coordinates":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPoint","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPoint"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiLineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiLineString"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPolygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPolygon"]},"coordinates":{"type":"array","items":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}}]}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}}]},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON FeatureCollection","type":"object","required":["type","features"],"properties":{"type":{"type":"string","enum":["FeatureCollection"]},"features":{"type":"array","items":{"title":"GeoJSON Feature","type":"object","required":["type","properties","geometry"],"properties":{"type":{"type":"string","enum":["Feature"]},"id":{"oneOf":[{"type":"number"},{"type":"string"}]},"properties":{"oneOf":[{"type":"null"},{"type":"object"}]},"geometry":{"oneOf":[{"type":"null"},{"title":"GeoJSON Point","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Point"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"number"}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON LineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["LineString"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON Polygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Polygon"]},"coordinates":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPoint","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPoint"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiLineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiLineString"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPolygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPolygon"]},"coordinates":{"type":"array","items":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON GeometryCollection","type":"object","required":["type","geometries"],"properties":{"type":{"type":"string","enum":["GeometryCollection"]},"geometries":{"type":"array","items":{"oneOf":[{"title":"GeoJSON Point","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Point"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"number"}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON LineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["LineString"]},"coordinates":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON Polygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["Polygon"]},"coordinates":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPoint","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPoint"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"number"}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiLineString","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiLineString"]},"coordinates":{"type":"array","items":{"type":"array","minItems":2,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}},{"title":"GeoJSON MultiPolygon","type":"object","required":["type","coordinates"],"properties":{"type":{"type":"string","enum":["MultiPolygon"]},"coordinates":{"type":"array","items":{"type":"array","items":{"type":"array","minItems":4,"items":{"type":"array","minItems":2,"items":{"type":"number"}}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}}]}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}}]},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}}},"bbox":{"type":"array","minItems":4,"items":{"type":"number"}}}}]}')},69962:t=>{"use strict";t.exports=JSON.parse('{"$id":"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#","description":"Meta-schema for $data reference (JSON AnySchema extension proposal)","type":"object","required":["$data"],"properties":{"$data":{"type":"string","anyOf":[{"format":"relative-json-pointer"},{"format":"json-pointer"}]}},"additionalProperties":false}')},34376:t=>{"use strict";t.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"http://json-schema.org/draft-07/schema#","title":"Core schema meta-schema","definitions":{"schemaArray":{"type":"array","minItems":1,"items":{"$ref":"#"}},"nonNegativeInteger":{"type":"integer","minimum":0},"nonNegativeIntegerDefault0":{"allOf":[{"$ref":"#/definitions/nonNegativeInteger"},{"default":0}]},"simpleTypes":{"enum":["array","boolean","integer","null","number","object","string"]},"stringArray":{"type":"array","items":{"type":"string"},"uniqueItems":true,"default":[]}},"type":["object","boolean"],"properties":{"$id":{"type":"string","format":"uri-reference"},"$schema":{"type":"string","format":"uri"},"$ref":{"type":"string","format":"uri-reference"},"$comment":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"default":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"multipleOf":{"type":"number","exclusiveMinimum":0},"maximum":{"type":"number"},"exclusiveMaximum":{"type":"number"},"minimum":{"type":"number"},"exclusiveMinimum":{"type":"number"},"maxLength":{"$ref":"#/definitions/nonNegativeInteger"},"minLength":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"pattern":{"type":"string","format":"regex"},"additionalItems":{"$ref":"#"},"items":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/schemaArray"}],"default":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"contains":{"$ref":"#"},"maxProperties":{"$ref":"#/definitions/nonNegativeInteger"},"minProperties":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"required":{"$ref":"#/definitions/stringArray"},"additionalProperties":{"$ref":"#"},"definitions":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"properties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"patternProperties":{"type":"object","additionalProperties":{"$ref":"#"},"propertyNames":{"format":"regex"},"default":{}},"dependencies":{"type":"object","additionalProperties":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/stringArray"}]}},"propertyNames":{"$ref":"#"},"const":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"format":{"type":"string"},"contentMediaType":{"type":"string"},"contentEncoding":{"type":"string"},"if":{"$ref":"#"},"then":{"$ref":"#"},"else":{"$ref":"#"},"allOf":{"$ref":"#/definitions/schemaArray"},"anyOf":{"$ref":"#/definitions/schemaArray"},"oneOf":{"$ref":"#/definitions/schemaArray"},"not":{"$ref":"#"}},"default":true}')}}]);