uomtiles 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (507) hide show
  1. package/.output/nitro.json +15 -0
  2. package/.output/public/_nuxt/1d1PDhA4.js +1 -0
  3. package/.output/public/_nuxt/3B2XYGg4.js +1 -0
  4. package/.output/public/_nuxt/981KwFWf.js +1 -0
  5. package/.output/public/_nuxt/B30dSvM4.js +1 -0
  6. package/.output/public/_nuxt/BN1Gp4Dm.js +1 -0
  7. package/.output/public/_nuxt/BQlj8Xoe.js +6 -0
  8. package/.output/public/_nuxt/BRkljK8J.js +1 -0
  9. package/.output/public/_nuxt/BSdHYVlE2.js +1 -0
  10. package/.output/public/_nuxt/B_MqTg2k2.js +1 -0
  11. package/.output/public/_nuxt/BiWblTbb2.js +64 -0
  12. package/.output/public/_nuxt/BrPwntMr.js +1 -0
  13. package/.output/public/_nuxt/BskybydR.js +1 -0
  14. package/.output/public/_nuxt/ByRlKR9F.js +1 -0
  15. package/.output/public/_nuxt/C0Zdl2EE2.js +1 -0
  16. package/.output/public/_nuxt/C4qlzA4o.js +1 -0
  17. package/.output/public/_nuxt/C7HxHbxA.js +1 -0
  18. package/.output/public/_nuxt/C97TfNgP.js +3 -0
  19. package/.output/public/_nuxt/CNs_Ozdc.js +1 -0
  20. package/.output/public/_nuxt/CPuhwLY1.js +1 -0
  21. package/.output/public/_nuxt/CVE291Pi.js +1 -0
  22. package/.output/public/_nuxt/C_0VY3Cv2.js +4 -0
  23. package/.output/public/_nuxt/Ce26t8_Y.js +1 -0
  24. package/.output/public/_nuxt/CfW544W5.js +1 -0
  25. package/.output/public/_nuxt/CgMd2Y5s.js +2 -0
  26. package/.output/public/_nuxt/CgdzV712.js +1 -0
  27. package/.output/public/_nuxt/D1wVNWS0.js +1 -0
  28. package/.output/public/_nuxt/DC3bhq63.js +1 -0
  29. package/.output/public/_nuxt/DK3Fl9T5.js +1 -0
  30. package/.output/public/_nuxt/DL1MZZLI.js +1 -0
  31. package/.output/public/_nuxt/DXm-42Fi.js +1 -0
  32. package/.output/public/_nuxt/Djg3Kzfv.js +1 -0
  33. package/.output/public/_nuxt/DkcySee1.js +1 -0
  34. package/.output/public/_nuxt/DmN-PKW1.js +1 -0
  35. package/.output/public/_nuxt/DtFVCXI9.js +1 -0
  36. package/.output/public/_nuxt/Dz7VMlHR.js +1 -0
  37. package/.output/public/_nuxt/NL65vbjG2.js +1 -0
  38. package/.output/public/_nuxt/Oxy7pKSk.js +3 -0
  39. package/.output/public/_nuxt/Pik8or8N2.js +1 -0
  40. package/.output/public/_nuxt/XZ59tThl.js +1 -0
  41. package/.output/public/_nuxt/ZpWjFsgV.js +1 -0
  42. package/.output/public/_nuxt/builds/latest.json +1 -0
  43. package/.output/public/_nuxt/builds/meta/9f85104e-738d-4a74-8daa-40b136ce17d5.json +1 -0
  44. package/.output/public/_nuxt/dXz6dFgW2.js +1 -0
  45. package/.output/public/_nuxt/entry.P6tFNE31.css +1 -0
  46. package/.output/public/_nuxt/error-404.Biv0P6cJ.css +1 -0
  47. package/.output/public/_nuxt/error-500.8ok468rV.css +1 -0
  48. package/.output/public/_nuxt/j0MRD-c3.js +1 -0
  49. package/.output/public/_nuxt/local-pixel-diff.worker-C6RdZoCq.js +2 -0
  50. package/.output/public/_nuxt/maplibre-gl-worker.nfnkSQvL.mjs +6 -0
  51. package/.output/public/_nuxt/nearest-area.worker-iSLH0Y_s.js +2 -0
  52. package/.output/public/_nuxt/q7DkoVkj.js +828 -0
  53. package/.output/public/_nuxt/raster-tile.worker-BFlOgJig.js +2 -0
  54. package/.output/public/_nuxt/services._3nQizF8.css +1 -0
  55. package/.output/public/_nuxt/sql-wasm.DfANybxk.wasm +0 -0
  56. package/.output/public/_nuxt/tile-diff.worker-CvWWI_eu.js +1 -0
  57. package/.output/public/_nuxt/zZ1EGR7Y.js +1 -0
  58. package/.output/public/apple-touch-icon.png +0 -0
  59. package/.output/public/favicon.ico +0 -0
  60. package/.output/public/favicon.svg +8 -0
  61. package/.output/public/icon-192.png +0 -0
  62. package/.output/public/icon-512.png +0 -0
  63. package/.output/public/site.webmanifest +11 -0
  64. package/.output/server/chunks/_/config.mjs +208 -0
  65. package/.output/server/chunks/_/config.mjs.map +1 -0
  66. package/.output/server/chunks/_/data-directory.mjs +24 -0
  67. package/.output/server/chunks/_/data-directory.mjs.map +1 -0
  68. package/.output/server/chunks/_/error-500.mjs +20 -0
  69. package/.output/server/chunks/_/error-500.mjs.map +1 -0
  70. package/.output/server/chunks/_/file-workspace.mjs +910 -0
  71. package/.output/server/chunks/_/file-workspace.mjs.map +1 -0
  72. package/.output/server/chunks/_/icons.mjs +6269 -0
  73. package/.output/server/chunks/_/icons.mjs.map +1 -0
  74. package/.output/server/chunks/_/map-service.mjs +233 -0
  75. package/.output/server/chunks/_/map-service.mjs.map +1 -0
  76. package/.output/server/chunks/_/missing-tile.mjs +104 -0
  77. package/.output/server/chunks/_/missing-tile.mjs.map +1 -0
  78. package/.output/server/chunks/_/pixel-diff.mjs +78 -0
  79. package/.output/server/chunks/_/pixel-diff.mjs.map +1 -0
  80. package/.output/server/chunks/_/uom-auth.mjs +334 -0
  81. package/.output/server/chunks/_/uom-auth.mjs.map +1 -0
  82. package/.output/server/chunks/_/uom-map.mjs +265 -0
  83. package/.output/server/chunks/_/uom-map.mjs.map +1 -0
  84. package/.output/server/chunks/build/Alert-0ngTJXxP.mjs +5076 -0
  85. package/.output/server/chunks/build/Alert-0ngTJXxP.mjs.map +1 -0
  86. package/.output/server/chunks/build/DashboardSidebarToggle-pncTaIJq.mjs +569 -0
  87. package/.output/server/chunks/build/DashboardSidebarToggle-pncTaIJq.mjs.map +1 -0
  88. package/.output/server/chunks/build/Empty-CkW3mADt.mjs +359 -0
  89. package/.output/server/chunks/build/Empty-CkW3mADt.mjs.map +1 -0
  90. package/.output/server/chunks/build/FocusScope-Cf0lg0zt.mjs +207 -0
  91. package/.output/server/chunks/build/FocusScope-Cf0lg0zt.mjs.map +1 -0
  92. package/.output/server/chunks/build/FormField-CEUZHcv7.mjs +278 -0
  93. package/.output/server/chunks/build/FormField-CEUZHcv7.mjs.map +1 -0
  94. package/.output/server/chunks/build/Input-BeNavYXb.mjs +592 -0
  95. package/.output/server/chunks/build/Input-BeNavYXb.mjs.map +1 -0
  96. package/.output/server/chunks/build/MapBaseLayerTabs-4445J6yh.mjs +2003 -0
  97. package/.output/server/chunks/build/MapBaseLayerTabs-4445J6yh.mjs.map +1 -0
  98. package/.output/server/chunks/build/Modal-DNZtVxca.mjs +1326 -0
  99. package/.output/server/chunks/build/Modal-DNZtVxca.mjs.map +1 -0
  100. package/.output/server/chunks/build/OnlineMap-CKwiuqUY.mjs +146 -0
  101. package/.output/server/chunks/build/OnlineMap-CKwiuqUY.mjs.map +1 -0
  102. package/.output/server/chunks/build/Pagination-CDHx4HTZ.mjs +1025 -0
  103. package/.output/server/chunks/build/Pagination-CDHx4HTZ.mjs.map +1 -0
  104. package/.output/server/chunks/build/PopperArrow-Bqfdf2Et.mjs +2066 -0
  105. package/.output/server/chunks/build/PopperArrow-Bqfdf2Et.mjs.map +1 -0
  106. package/.output/server/chunks/build/ScrollArea-BQK3em8b.mjs +379 -0
  107. package/.output/server/chunks/build/ScrollArea-BQK3em8b.mjs.map +1 -0
  108. package/.output/server/chunks/build/Slider-D-n8Y0CX.mjs +1087 -0
  109. package/.output/server/chunks/build/Slider-D-n8Y0CX.mjs.map +1 -0
  110. package/.output/server/chunks/build/Tooltip-CkpSktvJ.mjs +1345 -0
  111. package/.output/server/chunks/build/Tooltip-CkpSktvJ.mjs.map +1 -0
  112. package/.output/server/chunks/build/_virtual_public-CeOptKUP.mjs +7 -0
  113. package/.output/server/chunks/build/_virtual_public-CeOptKUP.mjs.map +1 -0
  114. package/.output/server/chunks/build/advanced-D1onodoF.mjs +1430 -0
  115. package/.output/server/chunks/build/advanced-D1onodoF.mjs.map +1 -0
  116. package/.output/server/chunks/build/compare-DmSAW8oA.mjs +1093 -0
  117. package/.output/server/chunks/build/compare-DmSAW8oA.mjs.map +1 -0
  118. package/.output/server/chunks/build/dashboard-BJxrZ19n.mjs +3217 -0
  119. package/.output/server/chunks/build/dashboard-BJxrZ19n.mjs.map +1 -0
  120. package/.output/server/chunks/build/details-CBMqXYyo.mjs +3714 -0
  121. package/.output/server/chunks/build/details-CBMqXYyo.mjs.map +1 -0
  122. package/.output/server/chunks/build/error-404-D9aQjJRn.mjs +86 -0
  123. package/.output/server/chunks/build/error-404-D9aQjJRn.mjs.map +1 -0
  124. package/.output/server/chunks/build/error-404-styles.DciiguV6.mjs +9 -0
  125. package/.output/server/chunks/build/error-404-styles.DciiguV6.mjs.map +1 -0
  126. package/.output/server/chunks/build/error-500-BNyA3wrb.mjs +74 -0
  127. package/.output/server/chunks/build/error-500-BNyA3wrb.mjs.map +1 -0
  128. package/.output/server/chunks/build/error-500-styles.C562DYMR.mjs +9 -0
  129. package/.output/server/chunks/build/error-500-styles.C562DYMR.mjs.map +1 -0
  130. package/.output/server/chunks/build/esm-Dp2lJXbp.mjs +1121 -0
  131. package/.output/server/chunks/build/esm-Dp2lJXbp.mjs.map +1 -0
  132. package/.output/server/chunks/build/interval-BxUMpo78.mjs +411 -0
  133. package/.output/server/chunks/build/interval-BxUMpo78.mjs.map +1 -0
  134. package/.output/server/chunks/build/login-lbtjN0MV.mjs +642 -0
  135. package/.output/server/chunks/build/login-lbtjN0MV.mjs.map +1 -0
  136. package/.output/server/chunks/build/pages-Ba0Eixbd.mjs +220 -0
  137. package/.output/server/chunks/build/pages-Ba0Eixbd.mjs.map +1 -0
  138. package/.output/server/chunks/build/services-DuJwjAB8.mjs +3005 -0
  139. package/.output/server/chunks/build/services-DuJwjAB8.mjs.map +1 -0
  140. package/.output/server/chunks/build/services-styles.eoO16BY9.mjs +9 -0
  141. package/.output/server/chunks/build/services-styles.eoO16BY9.mjs.map +1 -0
  142. package/.output/server/chunks/build/tasks-CyN9x492.mjs +915 -0
  143. package/.output/server/chunks/build/tasks-CyN9x492.mjs.map +1 -0
  144. package/.output/server/chunks/build/tasks-D_Q5EDnn.mjs +87 -0
  145. package/.output/server/chunks/build/tasks-D_Q5EDnn.mjs.map +1 -0
  146. package/.output/server/chunks/nitro/nitro.mjs +6215 -0
  147. package/.output/server/chunks/nitro/nitro.mjs.map +1 -0
  148. package/.output/server/chunks/routes/api/auth/captcha.post.mjs +21 -0
  149. package/.output/server/chunks/routes/api/auth/captcha.post.mjs.map +1 -0
  150. package/.output/server/chunks/routes/api/auth/login.post.mjs +27 -0
  151. package/.output/server/chunks/routes/api/auth/login.post.mjs.map +1 -0
  152. package/.output/server/chunks/routes/api/auth/logout.post.mjs +22 -0
  153. package/.output/server/chunks/routes/api/auth/logout.post.mjs.map +1 -0
  154. package/.output/server/chunks/routes/api/auth/map-token.post.mjs +22 -0
  155. package/.output/server/chunks/routes/api/auth/map-token.post.mjs.map +1 -0
  156. package/.output/server/chunks/routes/api/auth/send-sms.post.mjs +31 -0
  157. package/.output/server/chunks/routes/api/auth/send-sms.post.mjs.map +1 -0
  158. package/.output/server/chunks/routes/api/auth/status.get.mjs +21 -0
  159. package/.output/server/chunks/routes/api/auth/status.get.mjs.map +1 -0
  160. package/.output/server/chunks/routes/api/map/base/_baseLayer/_zoom/_tileX/_tileY_.get.mjs +44 -0
  161. package/.output/server/chunks/routes/api/map/base/_baseLayer/_zoom/_tileX/_tileY_.get.mjs.map +1 -0
  162. package/.output/server/chunks/routes/api/map/live/status.get.mjs +32 -0
  163. package/.output/server/chunks/routes/api/map/live/status.get.mjs.map +1 -0
  164. package/.output/server/chunks/routes/api/map/online/_layerGroup/_zoom/_tileX/_tileY_.get.mjs +48 -0
  165. package/.output/server/chunks/routes/api/map/online/_layerGroup/_zoom/_tileX/_tileY_.get.mjs.map +1 -0
  166. package/.output/server/chunks/routes/api/map/online-root/_layerGroup/_rootX/_rootY_.get.mjs +46 -0
  167. package/.output/server/chunks/routes/api/map/online-root/_layerGroup/_rootX/_rootY_.get.mjs.map +1 -0
  168. package/.output/server/chunks/routes/api/map-service/config.post.mjs +38 -0
  169. package/.output/server/chunks/routes/api/map-service/config.post.mjs.map +1 -0
  170. package/.output/server/chunks/routes/api/map-service/file.post.mjs +41 -0
  171. package/.output/server/chunks/routes/api/map-service/file.post.mjs.map +1 -0
  172. package/.output/server/chunks/routes/api/map-service/source.post.mjs +35 -0
  173. package/.output/server/chunks/routes/api/map-service/source.post.mjs.map +1 -0
  174. package/.output/server/chunks/routes/api/map-service/status.get.mjs +32 -0
  175. package/.output/server/chunks/routes/api/map-service/status.get.mjs.map +1 -0
  176. package/.output/server/chunks/routes/api/workspace/_filename/analysis.get.mjs +47 -0
  177. package/.output/server/chunks/routes/api/workspace/_filename/analysis.get.mjs.map +1 -0
  178. package/.output/server/chunks/routes/api/workspace/_filename/download.get.mjs +38 -0
  179. package/.output/server/chunks/routes/api/workspace/_filename/download.get.mjs.map +1 -0
  180. package/.output/server/chunks/routes/api/workspace/_filename/export/_format_.get.mjs +42 -0
  181. package/.output/server/chunks/routes/api/workspace/_filename/export/_format_.get.mjs.map +1 -0
  182. package/.output/server/chunks/routes/api/workspace/_filename/tile.get.mjs +48 -0
  183. package/.output/server/chunks/routes/api/workspace/_filename/tile.get.mjs.map +1 -0
  184. package/.output/server/chunks/routes/api/workspace/_filename/tiles.get.mjs +45 -0
  185. package/.output/server/chunks/routes/api/workspace/_filename/tiles.get.mjs.map +1 -0
  186. package/.output/server/chunks/routes/api/workspace/_filename_.delete.mjs +32 -0
  187. package/.output/server/chunks/routes/api/workspace/_filename_.delete.mjs.map +1 -0
  188. package/.output/server/chunks/routes/api/workspace/compare/batch.get.mjs +38 -0
  189. package/.output/server/chunks/routes/api/workspace/compare/batch.get.mjs.map +1 -0
  190. package/.output/server/chunks/routes/api/workspace/compare.post.mjs +33 -0
  191. package/.output/server/chunks/routes/api/workspace/compare.post.mjs.map +1 -0
  192. package/.output/server/chunks/routes/api/workspace/fetch.post.mjs +33 -0
  193. package/.output/server/chunks/routes/api/workspace/fetch.post.mjs.map +1 -0
  194. package/.output/server/chunks/routes/api/workspace/files.get.mjs +27 -0
  195. package/.output/server/chunks/routes/api/workspace/files.get.mjs.map +1 -0
  196. package/.output/server/chunks/routes/api/workspace/files.post.mjs +38 -0
  197. package/.output/server/chunks/routes/api/workspace/files.post.mjs.map +1 -0
  198. package/.output/server/chunks/routes/api/workspace/stop.post.mjs +32 -0
  199. package/.output/server/chunks/routes/api/workspace/stop.post.mjs.map +1 -0
  200. package/.output/server/chunks/routes/api/workspace/tasks.post.mjs +36 -0
  201. package/.output/server/chunks/routes/api/workspace/tasks.post.mjs.map +1 -0
  202. package/.output/server/chunks/routes/renderer.mjs +422 -0
  203. package/.output/server/chunks/routes/renderer.mjs.map +1 -0
  204. package/.output/server/chunks/routes/services/wms.get.mjs +54 -0
  205. package/.output/server/chunks/routes/services/wms.get.mjs.map +1 -0
  206. package/.output/server/chunks/routes/services/wmts.get.mjs +54 -0
  207. package/.output/server/chunks/routes/services/wmts.get.mjs.map +1 -0
  208. package/.output/server/chunks/virtual/_virtual_spa-template.mjs +4 -0
  209. package/.output/server/chunks/virtual/_virtual_spa-template.mjs.map +1 -0
  210. package/.output/server/chunks/virtual/entry.mjs +18545 -0
  211. package/.output/server/chunks/virtual/entry.mjs.map +1 -0
  212. package/.output/server/chunks/virtual/precomputed.mjs +4 -0
  213. package/.output/server/chunks/virtual/precomputed.mjs.map +1 -0
  214. package/.output/server/chunks/virtual/styles.mjs +10 -0
  215. package/.output/server/chunks/virtual/styles.mjs.map +1 -0
  216. package/.output/server/index.mjs +12 -0
  217. package/.output/server/index.mjs.map +1 -0
  218. package/.output/server/node_modules/@babel/parser/lib/index.js +14611 -0
  219. package/.output/server/node_modules/@babel/parser/package.json +50 -0
  220. package/.output/server/node_modules/@iconify/utils/lib/colors/index.js +295 -0
  221. package/.output/server/node_modules/@iconify/utils/lib/colors/keywords.js +701 -0
  222. package/.output/server/node_modules/@iconify/utils/lib/css/common.js +75 -0
  223. package/.output/server/node_modules/@iconify/utils/lib/css/format.js +39 -0
  224. package/.output/server/node_modules/@iconify/utils/lib/css/icon.js +47 -0
  225. package/.output/server/node_modules/@iconify/utils/lib/css/icons.js +128 -0
  226. package/.output/server/node_modules/@iconify/utils/lib/customisations/bool.js +19 -0
  227. package/.output/server/node_modules/@iconify/utils/lib/customisations/defaults.js +13 -0
  228. package/.output/server/node_modules/@iconify/utils/lib/customisations/flip.js +17 -0
  229. package/.output/server/node_modules/@iconify/utils/lib/customisations/merge.js +16 -0
  230. package/.output/server/node_modules/@iconify/utils/lib/customisations/rotate.js +30 -0
  231. package/.output/server/node_modules/@iconify/utils/lib/emoji/cleanup.js +78 -0
  232. package/.output/server/node_modules/@iconify/utils/lib/emoji/convert.js +100 -0
  233. package/.output/server/node_modules/@iconify/utils/lib/emoji/data.js +28 -0
  234. package/.output/server/node_modules/@iconify/utils/lib/emoji/format.js +58 -0
  235. package/.output/server/node_modules/@iconify/utils/lib/emoji/parse.js +48 -0
  236. package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/base.js +203 -0
  237. package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/create.js +33 -0
  238. package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/numbers.js +132 -0
  239. package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/similar.js +165 -0
  240. package/.output/server/node_modules/@iconify/utils/lib/emoji/regex/tree.js +79 -0
  241. package/.output/server/node_modules/@iconify/utils/lib/emoji/replace/find.js +92 -0
  242. package/.output/server/node_modules/@iconify/utils/lib/emoji/replace/replace.js +26 -0
  243. package/.output/server/node_modules/@iconify/utils/lib/emoji/test/components.js +76 -0
  244. package/.output/server/node_modules/@iconify/utils/lib/emoji/test/missing.js +66 -0
  245. package/.output/server/node_modules/@iconify/utils/lib/emoji/test/name.js +45 -0
  246. package/.output/server/node_modules/@iconify/utils/lib/emoji/test/parse.js +103 -0
  247. package/.output/server/node_modules/@iconify/utils/lib/emoji/test/similar.js +36 -0
  248. package/.output/server/node_modules/@iconify/utils/lib/emoji/test/tree.js +92 -0
  249. package/.output/server/node_modules/@iconify/utils/lib/emoji/test/variations.js +62 -0
  250. package/.output/server/node_modules/@iconify/utils/lib/icon/defaults.js +25 -0
  251. package/.output/server/node_modules/@iconify/utils/lib/icon/merge.js +16 -0
  252. package/.output/server/node_modules/@iconify/utils/lib/icon/name.js +57 -0
  253. package/.output/server/node_modules/@iconify/utils/lib/icon/square.js +33 -0
  254. package/.output/server/node_modules/@iconify/utils/lib/icon/transformations.js +12 -0
  255. package/.output/server/node_modules/@iconify/utils/lib/icon-set/convert-info.js +125 -0
  256. package/.output/server/node_modules/@iconify/utils/lib/icon-set/expand.js +19 -0
  257. package/.output/server/node_modules/@iconify/utils/lib/icon-set/get-icon.js +25 -0
  258. package/.output/server/node_modules/@iconify/utils/lib/icon-set/get-icons.js +36 -0
  259. package/.output/server/node_modules/@iconify/utils/lib/icon-set/minify.js +91 -0
  260. package/.output/server/node_modules/@iconify/utils/lib/icon-set/parse.js +46 -0
  261. package/.output/server/node_modules/@iconify/utils/lib/icon-set/tree.js +23 -0
  262. package/.output/server/node_modules/@iconify/utils/lib/icon-set/validate-basic.js +42 -0
  263. package/.output/server/node_modules/@iconify/utils/lib/icon-set/validate.js +123 -0
  264. package/.output/server/node_modules/@iconify/utils/lib/index.js +52 -0
  265. package/.output/server/node_modules/@iconify/utils/lib/loader/custom.js +30 -0
  266. package/.output/server/node_modules/@iconify/utils/lib/loader/loader.js +26 -0
  267. package/.output/server/node_modules/@iconify/utils/lib/loader/modern.js +27 -0
  268. package/.output/server/node_modules/@iconify/utils/lib/loader/utils.js +105 -0
  269. package/.output/server/node_modules/@iconify/utils/lib/misc/objects.js +26 -0
  270. package/.output/server/node_modules/@iconify/utils/lib/misc/strings.js +26 -0
  271. package/.output/server/node_modules/@iconify/utils/lib/misc/title.js +9 -0
  272. package/.output/server/node_modules/@iconify/utils/lib/svg/build.js +113 -0
  273. package/.output/server/node_modules/@iconify/utils/lib/svg/defs.js +31 -0
  274. package/.output/server/node_modules/@iconify/utils/lib/svg/encode-svg-for-css.js +13 -0
  275. package/.output/server/node_modules/@iconify/utils/lib/svg/html.js +9 -0
  276. package/.output/server/node_modules/@iconify/utils/lib/svg/id.js +41 -0
  277. package/.output/server/node_modules/@iconify/utils/lib/svg/inner-html.js +22 -0
  278. package/.output/server/node_modules/@iconify/utils/lib/svg/parse.js +67 -0
  279. package/.output/server/node_modules/@iconify/utils/lib/svg/pretty.js +54 -0
  280. package/.output/server/node_modules/@iconify/utils/lib/svg/size.js +27 -0
  281. package/.output/server/node_modules/@iconify/utils/lib/svg/trim.js +7 -0
  282. package/.output/server/node_modules/@iconify/utils/lib/svg/url.js +22 -0
  283. package/.output/server/node_modules/@iconify/utils/lib/svg/viewbox.js +8 -0
  284. package/.output/server/node_modules/@iconify/utils/package.json +119 -0
  285. package/.output/server/node_modules/@vue/compiler-core/dist/compiler-core.cjs.prod.js +6801 -0
  286. package/.output/server/node_modules/@vue/compiler-core/package.json +58 -0
  287. package/.output/server/node_modules/@vue/compiler-dom/dist/compiler-dom.cjs.prod.js +692 -0
  288. package/.output/server/node_modules/@vue/compiler-dom/package.json +57 -0
  289. package/.output/server/node_modules/@vue/compiler-ssr/dist/compiler-ssr.cjs.js +1420 -0
  290. package/.output/server/node_modules/@vue/compiler-ssr/package.json +34 -0
  291. package/.output/server/node_modules/@vue/reactivity/dist/reactivity.cjs.prod.js +1903 -0
  292. package/.output/server/node_modules/@vue/reactivity/package.json +55 -0
  293. package/.output/server/node_modules/@vue/runtime-core/dist/runtime-core.cjs.prod.js +6976 -0
  294. package/.output/server/node_modules/@vue/runtime-core/package.json +52 -0
  295. package/.output/server/node_modules/@vue/runtime-dom/dist/runtime-dom.cjs.prod.js +1841 -0
  296. package/.output/server/node_modules/@vue/runtime-dom/package.json +60 -0
  297. package/.output/server/node_modules/@vue/server-renderer/dist/server-renderer.cjs.prod.js +904 -0
  298. package/.output/server/node_modules/@vue/server-renderer/package.json +53 -0
  299. package/.output/server/node_modules/@vue/shared/dist/shared.cjs.prod.js +609 -0
  300. package/.output/server/node_modules/@vue/shared/package.json +47 -0
  301. package/.output/server/node_modules/consola/dist/chunks/prompt.mjs +280 -0
  302. package/.output/server/node_modules/consola/dist/core.mjs +512 -0
  303. package/.output/server/node_modules/consola/dist/index.mjs +651 -0
  304. package/.output/server/node_modules/consola/dist/shared/consola.DRwqZj3T.mjs +72 -0
  305. package/.output/server/node_modules/consola/dist/shared/consola.DXBYu-KD.mjs +288 -0
  306. package/.output/server/node_modules/consola/package.json +136 -0
  307. package/.output/server/node_modules/devalue/index.js +17 -0
  308. package/.output/server/node_modules/devalue/package.json +39 -0
  309. package/.output/server/node_modules/devalue/src/base64.js +60 -0
  310. package/.output/server/node_modules/devalue/src/constants.js +12 -0
  311. package/.output/server/node_modules/devalue/src/operations.js +193 -0
  312. package/.output/server/node_modules/devalue/src/parse.js +270 -0
  313. package/.output/server/node_modules/devalue/src/stringify.js +428 -0
  314. package/.output/server/node_modules/devalue/src/uneval.js +582 -0
  315. package/.output/server/node_modules/devalue/src/utils.js +185 -0
  316. package/.output/server/node_modules/entities/dist/commonjs/decode-codepoint.js +77 -0
  317. package/.output/server/node_modules/entities/dist/commonjs/decode.js +568 -0
  318. package/.output/server/node_modules/entities/dist/commonjs/generated/decode-data-html.js +7 -0
  319. package/.output/server/node_modules/entities/dist/commonjs/generated/decode-data-xml.js +7 -0
  320. package/.output/server/node_modules/entities/dist/commonjs/internal/bin-trie-flags.js +21 -0
  321. package/.output/server/node_modules/entities/dist/commonjs/internal/decode-shared.js +31 -0
  322. package/.output/server/node_modules/entities/dist/commonjs/package.json +3 -0
  323. package/.output/server/node_modules/entities/package.json +120 -0
  324. package/.output/server/node_modules/estree-walker/dist/umd/estree-walker.js +344 -0
  325. package/.output/server/node_modules/estree-walker/package.json +37 -0
  326. package/.output/server/node_modules/fflate/esm/index.mjs +2710 -0
  327. package/.output/server/node_modules/fflate/package.json +128 -0
  328. package/.output/server/node_modules/fnv1a-64/dist/index.mjs +95 -0
  329. package/.output/server/node_modules/fnv1a-64/package.json +75 -0
  330. package/.output/server/node_modules/hookable/dist/index.mjs +257 -0
  331. package/.output/server/node_modules/hookable/package.json +53 -0
  332. package/.output/server/node_modules/nostics/dist/formatters/ansi.mjs +19 -0
  333. package/.output/server/node_modules/nostics/dist/index.mjs +187 -0
  334. package/.output/server/node_modules/nostics/package.json +125 -0
  335. package/.output/server/node_modules/object-identity/index.js +60 -0
  336. package/.output/server/node_modules/object-identity/package.json +40 -0
  337. package/.output/server/node_modules/p-limit/index.js +104 -0
  338. package/.output/server/node_modules/p-limit/package.json +58 -0
  339. package/.output/server/node_modules/pmtiles/dist/esm/index.js +2 -0
  340. package/.output/server/node_modules/pmtiles/package.json +50 -0
  341. package/.output/server/node_modules/source-map-js/lib/array-set.js +121 -0
  342. package/.output/server/node_modules/source-map-js/lib/base64-vlq.js +140 -0
  343. package/.output/server/node_modules/source-map-js/lib/base64.js +67 -0
  344. package/.output/server/node_modules/source-map-js/lib/binary-search.js +111 -0
  345. package/.output/server/node_modules/source-map-js/lib/mapping-list.js +79 -0
  346. package/.output/server/node_modules/source-map-js/lib/quick-sort.js +132 -0
  347. package/.output/server/node_modules/source-map-js/lib/source-map-consumer.js +1188 -0
  348. package/.output/server/node_modules/source-map-js/lib/source-map-generator.js +444 -0
  349. package/.output/server/node_modules/source-map-js/lib/source-node.js +413 -0
  350. package/.output/server/node_modules/source-map-js/lib/util.js +594 -0
  351. package/.output/server/node_modules/source-map-js/package.json +71 -0
  352. package/.output/server/node_modules/source-map-js/source-map.js +8 -0
  353. package/.output/server/node_modules/tailwindcss/dist/chunk-DCG7AFIE.mjs +1 -0
  354. package/.output/server/node_modules/tailwindcss/dist/colors.mjs +1 -0
  355. package/.output/server/node_modules/tailwindcss/package.json +89 -0
  356. package/.output/server/node_modules/ufo/dist/index.mjs +645 -0
  357. package/.output/server/node_modules/ufo/package.json +48 -0
  358. package/.output/server/node_modules/unhead/dist/client.mjs +22 -0
  359. package/.output/server/node_modules/unhead/dist/index.mjs +52 -0
  360. package/.output/server/node_modules/unhead/dist/legacy.mjs +33 -0
  361. package/.output/server/node_modules/unhead/dist/minify.mjs +183 -0
  362. package/.output/server/node_modules/unhead/dist/parser.mjs +518 -0
  363. package/.output/server/node_modules/unhead/dist/plugins.mjs +631 -0
  364. package/.output/server/node_modules/unhead/dist/scripts.node.mjs +6 -0
  365. package/.output/server/node_modules/unhead/dist/server.mjs +99 -0
  366. package/.output/server/node_modules/unhead/dist/shared/unhead.BEmVMkeA.mjs +673 -0
  367. package/.output/server/node_modules/unhead/dist/shared/unhead.BGFxPGPQ.mjs +47 -0
  368. package/.output/server/node_modules/unhead/dist/shared/unhead.BQWSw36o.mjs +192 -0
  369. package/.output/server/node_modules/unhead/dist/shared/unhead.Bb4d5b9h.mjs +67 -0
  370. package/.output/server/node_modules/unhead/dist/shared/unhead.BdK3SLPN.mjs +585 -0
  371. package/.output/server/node_modules/unhead/dist/shared/unhead.Bf_fPVYA.mjs +6 -0
  372. package/.output/server/node_modules/unhead/dist/shared/unhead.Bm4Y6XQI.mjs +17 -0
  373. package/.output/server/node_modules/unhead/dist/shared/unhead.C3b2Ipoj.mjs +223 -0
  374. package/.output/server/node_modules/unhead/dist/shared/unhead.CGPOfp5O.mjs +32 -0
  375. package/.output/server/node_modules/unhead/dist/shared/unhead.CHEy9ana.mjs +7 -0
  376. package/.output/server/node_modules/unhead/dist/shared/unhead.CTjuIdzk.mjs +27 -0
  377. package/.output/server/node_modules/unhead/dist/shared/unhead.CfKy3Kuq.mjs +196 -0
  378. package/.output/server/node_modules/unhead/dist/shared/unhead.D7HkBzZn.mjs +59 -0
  379. package/.output/server/node_modules/unhead/dist/shared/unhead.DNKiVLV7.mjs +400 -0
  380. package/.output/server/node_modules/unhead/dist/shared/unhead.MC5RsXLj.mjs +19 -0
  381. package/.output/server/node_modules/unhead/dist/shared/unhead.jEy9BmRq.mjs +264 -0
  382. package/.output/server/node_modules/unhead/dist/shared/unhead.tQnRaXfX.mjs +240 -0
  383. package/.output/server/node_modules/unhead/dist/stream/client.mjs +28 -0
  384. package/.output/server/node_modules/unhead/dist/stream/iife.mjs +2 -0
  385. package/.output/server/node_modules/unhead/dist/stream/server.mjs +264 -0
  386. package/.output/server/node_modules/unhead/dist/utils.mjs +7 -0
  387. package/.output/server/node_modules/unhead/package.json +179 -0
  388. package/.output/server/node_modules/vue/dist/vue.cjs.js +80 -0
  389. package/.output/server/node_modules/vue/dist/vue.cjs.prod.js +66 -0
  390. package/.output/server/node_modules/vue/index.js +7 -0
  391. package/.output/server/node_modules/vue/index.mjs +1 -0
  392. package/.output/server/node_modules/vue/package.json +112 -0
  393. package/.output/server/node_modules/vue/server-renderer/index.mjs +1 -0
  394. package/.output/server/node_modules/vue-bundle-renderer/dist/runtime.mjs +278 -0
  395. package/.output/server/node_modules/vue-bundle-renderer/package.json +54 -0
  396. package/.output/server/node_modules/yocto-queue/index.js +90 -0
  397. package/.output/server/node_modules/yocto-queue/package.json +48 -0
  398. package/.output/server/node_modules/zod/index.js +4 -0
  399. package/.output/server/node_modules/zod/package.json +135 -0
  400. package/.output/server/node_modules/zod/v4/classic/checks.js +1 -0
  401. package/.output/server/node_modules/zod/v4/classic/coerce.js +17 -0
  402. package/.output/server/node_modules/zod/v4/classic/compat.js +31 -0
  403. package/.output/server/node_modules/zod/v4/classic/errors.js +48 -0
  404. package/.output/server/node_modules/zod/v4/classic/external.js +20 -0
  405. package/.output/server/node_modules/zod/v4/classic/from-json-schema.js +599 -0
  406. package/.output/server/node_modules/zod/v4/classic/iso.js +30 -0
  407. package/.output/server/node_modules/zod/v4/classic/package.json +7 -0
  408. package/.output/server/node_modules/zod/v4/classic/parse.js +15 -0
  409. package/.output/server/node_modules/zod/v4/classic/schemas.js +1395 -0
  410. package/.output/server/node_modules/zod/v4/core/api.js +1087 -0
  411. package/.output/server/node_modules/zod/v4/core/checks.js +575 -0
  412. package/.output/server/node_modules/zod/v4/core/core.js +78 -0
  413. package/.output/server/node_modules/zod/v4/core/doc.js +35 -0
  414. package/.output/server/node_modules/zod/v4/core/errors.js +185 -0
  415. package/.output/server/node_modules/zod/v4/core/index.js +16 -0
  416. package/.output/server/node_modules/zod/v4/core/json-schema-generator.js +95 -0
  417. package/.output/server/node_modules/zod/v4/core/json-schema-processors.js +601 -0
  418. package/.output/server/node_modules/zod/v4/core/json-schema.js +1 -0
  419. package/.output/server/node_modules/zod/v4/core/package.json +7 -0
  420. package/.output/server/node_modules/zod/v4/core/parse.js +93 -0
  421. package/.output/server/node_modules/zod/v4/core/regexes.js +139 -0
  422. package/.output/server/node_modules/zod/v4/core/registries.js +51 -0
  423. package/.output/server/node_modules/zod/v4/core/schemas.js +2239 -0
  424. package/.output/server/node_modules/zod/v4/core/to-json-schema.js +448 -0
  425. package/.output/server/node_modules/zod/v4/core/util.js +674 -0
  426. package/.output/server/node_modules/zod/v4/core/versions.js +5 -0
  427. package/.output/server/node_modules/zod/v4/locales/ar.js +106 -0
  428. package/.output/server/node_modules/zod/v4/locales/az.js +105 -0
  429. package/.output/server/node_modules/zod/v4/locales/be.js +156 -0
  430. package/.output/server/node_modules/zod/v4/locales/bg.js +120 -0
  431. package/.output/server/node_modules/zod/v4/locales/ca.js +107 -0
  432. package/.output/server/node_modules/zod/v4/locales/cs.js +111 -0
  433. package/.output/server/node_modules/zod/v4/locales/da.js +115 -0
  434. package/.output/server/node_modules/zod/v4/locales/de.js +108 -0
  435. package/.output/server/node_modules/zod/v4/locales/el.js +109 -0
  436. package/.output/server/node_modules/zod/v4/locales/en.js +113 -0
  437. package/.output/server/node_modules/zod/v4/locales/eo.js +109 -0
  438. package/.output/server/node_modules/zod/v4/locales/es.js +132 -0
  439. package/.output/server/node_modules/zod/v4/locales/fa.js +114 -0
  440. package/.output/server/node_modules/zod/v4/locales/fi.js +112 -0
  441. package/.output/server/node_modules/zod/v4/locales/fr-CA.js +107 -0
  442. package/.output/server/node_modules/zod/v4/locales/fr.js +125 -0
  443. package/.output/server/node_modules/zod/v4/locales/he.js +214 -0
  444. package/.output/server/node_modules/zod/v4/locales/hr.js +122 -0
  445. package/.output/server/node_modules/zod/v4/locales/hu.js +108 -0
  446. package/.output/server/node_modules/zod/v4/locales/hy.js +147 -0
  447. package/.output/server/node_modules/zod/v4/locales/id.js +106 -0
  448. package/.output/server/node_modules/zod/v4/locales/index.js +52 -0
  449. package/.output/server/node_modules/zod/v4/locales/is.js +109 -0
  450. package/.output/server/node_modules/zod/v4/locales/it.js +108 -0
  451. package/.output/server/node_modules/zod/v4/locales/ja.js +107 -0
  452. package/.output/server/node_modules/zod/v4/locales/ka.js +112 -0
  453. package/.output/server/node_modules/zod/v4/locales/kh.js +5 -0
  454. package/.output/server/node_modules/zod/v4/locales/km.js +110 -0
  455. package/.output/server/node_modules/zod/v4/locales/ko.js +111 -0
  456. package/.output/server/node_modules/zod/v4/locales/lt.js +203 -0
  457. package/.output/server/node_modules/zod/v4/locales/mk.js +109 -0
  458. package/.output/server/node_modules/zod/v4/locales/ms.js +107 -0
  459. package/.output/server/node_modules/zod/v4/locales/nl.js +110 -0
  460. package/.output/server/node_modules/zod/v4/locales/no.js +108 -0
  461. package/.output/server/node_modules/zod/v4/locales/ota.js +109 -0
  462. package/.output/server/node_modules/zod/v4/locales/package.json +7 -0
  463. package/.output/server/node_modules/zod/v4/locales/pl.js +109 -0
  464. package/.output/server/node_modules/zod/v4/locales/ps.js +114 -0
  465. package/.output/server/node_modules/zod/v4/locales/pt.js +108 -0
  466. package/.output/server/node_modules/zod/v4/locales/ro.js +119 -0
  467. package/.output/server/node_modules/zod/v4/locales/ru.js +156 -0
  468. package/.output/server/node_modules/zod/v4/locales/sl.js +109 -0
  469. package/.output/server/node_modules/zod/v4/locales/sv.js +110 -0
  470. package/.output/server/node_modules/zod/v4/locales/ta.js +110 -0
  471. package/.output/server/node_modules/zod/v4/locales/th.js +110 -0
  472. package/.output/server/node_modules/zod/v4/locales/tr.js +105 -0
  473. package/.output/server/node_modules/zod/v4/locales/ua.js +5 -0
  474. package/.output/server/node_modules/zod/v4/locales/uk.js +108 -0
  475. package/.output/server/node_modules/zod/v4/locales/ur.js +110 -0
  476. package/.output/server/node_modules/zod/v4/locales/uz.js +110 -0
  477. package/.output/server/node_modules/zod/v4/locales/vi.js +108 -0
  478. package/.output/server/node_modules/zod/v4/locales/yo.js +107 -0
  479. package/.output/server/node_modules/zod/v4/locales/zh-CN.js +109 -0
  480. package/.output/server/node_modules/zod/v4/locales/zh-TW.js +107 -0
  481. package/.output/server/package.json +37 -0
  482. package/LICENSE +3 -0
  483. package/README.md +125 -0
  484. package/dist/src/bbox.js +55 -0
  485. package/dist/src/cli.js +255 -0
  486. package/dist/src/config.js +56 -0
  487. package/dist/src/core/fetch-process.js +19 -0
  488. package/dist/src/core/grid-renderer.js +149 -0
  489. package/dist/src/core/lease.js +103 -0
  490. package/dist/src/core/paths.js +13 -0
  491. package/dist/src/core/png.js +192 -0
  492. package/dist/src/core/raster-style.js +33 -0
  493. package/dist/src/core/uomtiles.js +307 -0
  494. package/dist/src/fetcher.js +208 -0
  495. package/dist/src/geographic-grid.js +162 -0
  496. package/dist/src/grid-crawl.js +478 -0
  497. package/dist/src/mask-image.js +16 -0
  498. package/dist/src/official-grid.js +51 -0
  499. package/dist/src/quality.js +30 -0
  500. package/dist/src/token.js +206 -0
  501. package/package.json +68 -0
  502. package/public/apple-touch-icon.png +0 -0
  503. package/public/favicon.ico +0 -0
  504. package/public/favicon.svg +8 -0
  505. package/public/icon-192.png +0 -0
  506. package/public/icon-512.png +0 -0
  507. package/public/site.webmanifest +11 -0
@@ -0,0 +1,910 @@
1
+ import { c as createError, u as useRuntimeConfig } from '../nitro/nitro.mjs';
2
+ import { open as open$1 } from 'node:fs/promises';
3
+ import { statSync, existsSync, mkdirSync, unlinkSync, renameSync, createReadStream, mkdtempSync, rmSync, createWriteStream, chmodSync, openSync, readSync, closeSync, readdirSync } from 'node:fs';
4
+ import { DatabaseSync } from 'node:sqlite';
5
+ import { PMTiles, tileIdToZxy, bytesToHeader } from 'pmtiles';
6
+ import { a as encodeCanonicalMask, b as tileRangeForBBox, C as CHINA_BBOX_LL, x as xyzYToTmsY } from './config.mjs';
7
+ import { randomUUID } from 'node:crypto';
8
+ import { dirname, extname, resolve, basename, sep } from 'node:path';
9
+ import { hostname, tmpdir } from 'node:os';
10
+ import { execFile, spawn } from 'node:child_process';
11
+ import { pipeline } from 'node:stream/promises';
12
+ import { promisify } from 'node:util';
13
+ import { s as serverDataDirectory, w as workspaceDirectory, a as accountFile } from './data-directory.mjs';
14
+
15
+ const GEOGRAPHIC_GRID_LEVEL = 18;
16
+ const GEOGRAPHIC_GRID_STEP = 360 / 2 ** GEOGRAPHIC_GRID_LEVEL;
17
+ function mercatorLatitude(globalY, worldSize) {
18
+ return 180 / Math.PI * Math.atan(Math.sinh(Math.PI - 2 * Math.PI * globalY / worldSize));
19
+ }
20
+ function mercatorY(latitude, worldSize) {
21
+ const radians = latitude * Math.PI / 180;
22
+ return worldSize * (1 - Math.log(Math.tan(radians) + 1 / Math.cos(radians)) / Math.PI) / 2;
23
+ }
24
+ function geographicGridLines(extent) {
25
+ const childrenPerSide = 2 ** (extent.sourceZ - extent.parentZ);
26
+ const worldSize = 256 * 2 ** extent.sourceZ;
27
+ const globalX0 = extent.parentX * childrenPerSide * 256;
28
+ const globalY0 = extent.parentY * childrenPerSide * 256;
29
+ const xPitch = worldSize / 2 ** GEOGRAPHIC_GRID_LEVEL;
30
+ const xLines = [];
31
+ for (let x = Math.floor(globalX0 / xPitch) * xPitch; x <= globalX0 + extent.width; x += xPitch) {
32
+ xLines.push(x - globalX0);
33
+ }
34
+ const latitudeTop = mercatorLatitude(globalY0, worldSize);
35
+ const latitudeBottom = mercatorLatitude(globalY0 + extent.width, worldSize);
36
+ const yLines = [];
37
+ for (let k = Math.ceil(latitudeTop / GEOGRAPHIC_GRID_STEP); k >= Math.floor(latitudeBottom / GEOGRAPHIC_GRID_STEP); k--) {
38
+ const y = mercatorY(k * GEOGRAPHIC_GRID_STEP, worldSize) - globalY0;
39
+ if (y >= -8 && y <= extent.width + 8) yLines.push(y);
40
+ }
41
+ yLines.sort((a, b) => a - b);
42
+ return { xLines, yLines };
43
+ }
44
+ function renderGeographicGridTile(model, extent, targetZ, tileX, tileY) {
45
+ if (targetZ < extent.parentZ) throw new RangeError("target tile must not be below the grid root zoom");
46
+ const rootScale = 2 ** (targetZ - extent.parentZ);
47
+ if (Math.floor(tileX / rootScale) !== extent.parentX || Math.floor(tileY / rootScale) !== extent.parentY) {
48
+ return new Uint8Array(256 * 256);
49
+ }
50
+ const scale = 2 ** (targetZ - extent.sourceZ);
51
+ const sourceRootSize = 256 * 2 ** (extent.sourceZ - extent.parentZ);
52
+ const sourceX0 = extent.parentX * sourceRootSize;
53
+ const sourceY0 = extent.parentY * sourceRootSize;
54
+ const tileX0 = tileX * 256;
55
+ const tileY0 = tileY * 256;
56
+ const output = new Uint8Array(256 * 256);
57
+ for (const rect of model.rects) {
58
+ const x0 = Math.max(0, Math.round((sourceX0 + model.xLines[rect.col0]) * scale) - tileX0);
59
+ const y0 = Math.max(0, Math.round((sourceY0 + model.yLines[rect.row0]) * scale) - tileY0);
60
+ const x1 = Math.min(256, Math.round((sourceX0 + model.xLines[rect.col1]) * scale) - tileX0);
61
+ const y1 = Math.min(256, Math.round((sourceY0 + model.yLines[rect.row1]) * scale) - tileY0);
62
+ if (x0 >= x1 || y0 >= y1) continue;
63
+ for (let y = y0; y < y1; y++) output.fill(1, y * 256 + x0, y * 256 + x1);
64
+ }
65
+ return output;
66
+ }
67
+
68
+ function deriveParentMask(children) {
69
+ if (children.length !== 4) throw new RangeError("exactly four children are required");
70
+ const big = new Uint8Array(512 * 512);
71
+ const offsets = [[0, 0], [256, 0], [0, 256], [256, 256]];
72
+ for (let index = 0; index < children.length; index++) {
73
+ const child = children[index];
74
+ if (!child) continue;
75
+ if (child.length !== 256 * 256) throw new RangeError("child mask must be 256x256");
76
+ const [offsetX, offsetY] = offsets[index];
77
+ for (let y = 0; y < 256; y++) {
78
+ big.set(child.subarray(y * 256, y * 256 + 256), (offsetY + y) * 512 + offsetX);
79
+ }
80
+ }
81
+ const parent = new Uint8Array(256 * 256);
82
+ for (let y = 0; y < 256; y++) {
83
+ for (let x = 0; x < 256; x++) {
84
+ const sx = x * 2;
85
+ const sy = y * 2;
86
+ parent[y * 256 + x] = big[sy * 512 + sx] | big[sy * 512 + sx + 1] | big[(sy + 1) * 512 + sx] | big[(sy + 1) * 512 + sx + 1];
87
+ }
88
+ }
89
+ return parent;
90
+ }
91
+
92
+ var __defProp = Object.defineProperty;
93
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
94
+ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
95
+ const ROOT_ZOOM = 9;
96
+ const SOURCE_ZOOM = 12;
97
+ const DYNAMIC_MAX_ZOOM = 18;
98
+ const PUBLISH_MAX_ZOOM = 14;
99
+ const sourceRootSize = 256 * 2 ** (SOURCE_ZOOM - ROOT_ZOOM);
100
+ function decodeRectangles(value) {
101
+ if (value.byteLength % 8 !== 0) throw new Error("invalid grid rectangle payload");
102
+ const buffer = Buffer.from(value.buffer, value.byteOffset, value.byteLength);
103
+ const rects = [];
104
+ for (let offset = 0; offset < buffer.length; offset += 8) {
105
+ rects.push({
106
+ col0: buffer.readUInt16LE(offset),
107
+ row0: buffer.readUInt16LE(offset + 2),
108
+ col1: buffer.readUInt16LE(offset + 4),
109
+ row1: buffer.readUInt16LE(offset + 6)
110
+ });
111
+ }
112
+ return rects;
113
+ }
114
+ function rootRange(z, coordinate) {
115
+ if (z >= ROOT_ZOOM) {
116
+ const root = Math.floor(coordinate / 2 ** (z - ROOT_ZOOM));
117
+ return [root, root];
118
+ }
119
+ const scale = 2 ** (ROOT_ZOOM - z);
120
+ return [coordinate * scale, (coordinate + 1) * scale - 1];
121
+ }
122
+ class GeographicGridRenderer {
123
+ constructor(path) {
124
+ __publicField(this, "roots", /* @__PURE__ */ new Map());
125
+ __publicField(this, "masks", /* @__PURE__ */ new Map());
126
+ const db = new DatabaseSync(path, { readOnly: true });
127
+ try {
128
+ const table = db.prepare("SELECT 1 ok FROM sqlite_master WHERE type='table' AND name='grid_roots'").get();
129
+ if (!table) return;
130
+ const columns = new Set(db.prepare("PRAGMA table_info(grid_roots)").all().map((column) => column.name));
131
+ if (!columns.has("rectangles")) return;
132
+ const rows = db.prepare(`SELECT root_x x,root_y y,rectangles FROM grid_roots
133
+ WHERE state='completed' AND rectangles IS NOT NULL AND length(rectangles)>0`).all();
134
+ for (const row of rows) {
135
+ const lines = geographicGridLines({ sourceZ: SOURCE_ZOOM, parentZ: ROOT_ZOOM, parentX: row.x, parentY: row.y, width: sourceRootSize });
136
+ this.roots.set(`${row.x}/${row.y}`, { x: row.x, y: row.y, rects: decodeRectangles(row.rectangles), ...lines });
137
+ }
138
+ } finally {
139
+ db.close();
140
+ }
141
+ }
142
+ get available() {
143
+ return this.roots.size > 0;
144
+ }
145
+ hasGeometry(z, x, y) {
146
+ const [rootX0, rootX1] = rootRange(z, x);
147
+ const [rootY0, rootY1] = rootRange(z, y);
148
+ for (let rootY = rootY0; rootY <= rootY1; rootY++) for (let rootX = rootX0; rootX <= rootX1; rootX++) {
149
+ if (this.roots.has(`${rootX}/${rootY}`)) return true;
150
+ }
151
+ return false;
152
+ }
153
+ renderMask(z, x, y) {
154
+ if (!Number.isInteger(z) || z < 0 || z > DYNAMIC_MAX_ZOOM) throw new RangeError(`unsupported dynamic zoom z${z}`);
155
+ const key = `${z}/${x}/${y}`;
156
+ const cached = this.masks.get(key);
157
+ if (cached) return cached;
158
+ if (!this.hasGeometry(z, x, y)) return new Uint8Array(256 * 256);
159
+ if (z < ROOT_ZOOM) {
160
+ const mask2 = deriveParentMask([
161
+ this.renderMask(z + 1, x * 2, y * 2),
162
+ this.renderMask(z + 1, x * 2 + 1, y * 2),
163
+ this.renderMask(z + 1, x * 2, y * 2 + 1),
164
+ this.renderMask(z + 1, x * 2 + 1, y * 2 + 1)
165
+ ]);
166
+ this.masks.set(key, mask2);
167
+ return mask2;
168
+ }
169
+ const mask = new Uint8Array(256 * 256);
170
+ const [rootX0, rootX1] = rootRange(z, x);
171
+ const [rootY0, rootY1] = rootRange(z, y);
172
+ for (let rootY = rootY0; rootY <= rootY1; rootY++) for (let rootX = rootX0; rootX <= rootX1; rootX++) {
173
+ const root = this.roots.get(`${rootX}/${rootY}`);
174
+ if (!root) continue;
175
+ const rendered = renderGeographicGridTile(
176
+ { rects: root.rects, xLines: root.xLines, yLines: root.yLines },
177
+ { sourceZ: SOURCE_ZOOM, parentZ: ROOT_ZOOM, parentX: rootX, parentY: rootY},
178
+ z,
179
+ x,
180
+ y
181
+ );
182
+ for (let pixel = 0; pixel < mask.length; pixel++) if (rendered[pixel]) mask[pixel] = 1;
183
+ }
184
+ if (this.masks.size < 512) this.masks.set(key, mask);
185
+ return mask;
186
+ }
187
+ renderTile(z, x, y) {
188
+ const mask = this.renderMask(z, x, y);
189
+ return mask.some(Boolean) ? encodeCanonicalMask(mask) : null;
190
+ }
191
+ *contentCoordinates(z) {
192
+ const coordinates = /* @__PURE__ */ new Set();
193
+ if (z < ROOT_ZOOM) {
194
+ const scale2 = 2 ** (ROOT_ZOOM - z);
195
+ for (const root of this.roots.values()) coordinates.add(`${Math.floor(root.x / scale2)}/${Math.floor(root.y / scale2)}`);
196
+ for (const coordinate of [...coordinates].sort((left, right) => {
197
+ const [leftX, leftY] = left.split("/").map(Number), [rightX, rightY] = right.split("/").map(Number);
198
+ return leftX - rightX || leftY - rightY;
199
+ })) {
200
+ const [x, y] = coordinate.split("/").map(Number);
201
+ yield { z, x, y };
202
+ }
203
+ return;
204
+ }
205
+ const scale = 2 ** (z - SOURCE_ZOOM);
206
+ for (const root of this.roots.values()) for (const rect of root.rects) {
207
+ const sourceX0 = root.x * sourceRootSize;
208
+ const sourceY0 = root.y * sourceRootSize;
209
+ const pixelX0 = Math.round((sourceX0 + root.xLines[rect.col0]) * scale);
210
+ const pixelY0 = Math.round((sourceY0 + root.yLines[rect.row0]) * scale);
211
+ const pixelX1 = Math.round((sourceX0 + root.xLines[rect.col1]) * scale);
212
+ const pixelY1 = Math.round((sourceY0 + root.yLines[rect.row1]) * scale);
213
+ if (pixelX0 >= pixelX1 || pixelY0 >= pixelY1) continue;
214
+ const x0 = Math.floor(pixelX0 / 256), y0 = Math.floor(pixelY0 / 256);
215
+ const x1 = Math.floor((pixelX1 - 1) / 256), y1 = Math.floor((pixelY1 - 1) / 256);
216
+ const worldMax = 2 ** z - 1;
217
+ for (let tileY = Math.max(0, y0); tileY <= Math.min(worldMax, y1); tileY++) {
218
+ for (let tileX = Math.max(0, x0); tileX <= Math.min(worldMax, x1); tileX++) coordinates.add(`${tileX}/${tileY}`);
219
+ }
220
+ }
221
+ for (const coordinate of [...coordinates].sort((left, right) => {
222
+ const [leftX, leftY] = left.split("/").map(Number), [rightX, rightY] = right.split("/").map(Number);
223
+ return leftX - rightX || leftY - rightY;
224
+ })) {
225
+ const [x, y] = coordinate.split("/").map(Number);
226
+ yield { z, x, y };
227
+ }
228
+ }
229
+ }
230
+
231
+ const archives = /* @__PURE__ */ new Map();
232
+ const geometry = /* @__PURE__ */ new Map();
233
+ function cacheKey(path) {
234
+ var _a, _b;
235
+ const stat = statSync(path);
236
+ const walPath = `${path}-wal`;
237
+ const wal = existsSync(walPath) ? statSync(walPath) : null;
238
+ return `${path}:${stat.size}:${stat.mtimeMs}:${(_a = wal == null ? void 0 : wal.size) != null ? _a : 0}:${(_b = wal == null ? void 0 : wal.mtimeMs) != null ? _b : 0}`;
239
+ }
240
+ function taskTileProgress(path, z, x, y) {
241
+ var _a;
242
+ const db = new DatabaseSync(path, { readOnly: true });
243
+ try {
244
+ const tables = new Set(db.prepare("SELECT name FROM sqlite_master WHERE type='table'").all().map((row) => row.name));
245
+ if (!tables.has("uomtiles_task")) return null;
246
+ const task = db.prepare("SELECT state FROM uomtiles_task LIMIT 1").get();
247
+ if (!task || task.state === "completed") return null;
248
+ const root = tables.has("grid_roots") ? db.prepare("SELECT MIN(root_z) z,COUNT(*) count FROM grid_roots").get() : { z: null, count: 0 };
249
+ const rootZoom = (_a = root.z) != null ? _a : 9;
250
+ const scale = 2 ** Math.abs(rootZoom - z);
251
+ let xMin = z < rootZoom ? x * scale : Math.floor(x / scale);
252
+ let xMax = z < rootZoom ? (x + 1) * scale - 1 : xMin;
253
+ let yMin = z < rootZoom ? y * scale : Math.floor(y / scale);
254
+ let yMax = z < rootZoom ? (y + 1) * scale - 1 : yMin;
255
+ if (root.count === 0) {
256
+ const china = tileRangeForBBox(rootZoom, CHINA_BBOX_LL.lonMin, CHINA_BBOX_LL.latMin, CHINA_BBOX_LL.lonMax, CHINA_BBOX_LL.latMax);
257
+ xMin = Math.max(xMin, china.xMin);
258
+ xMax = Math.min(xMax, china.xMax);
259
+ yMin = Math.max(yMin, china.yMin);
260
+ yMax = Math.min(yMax, china.yMax);
261
+ if (xMin > xMax || yMin > yMax) return null;
262
+ return { completed: 0, total: (xMax - xMin + 1) * (yMax - yMin + 1) };
263
+ }
264
+ const progress = db.prepare(`SELECT COUNT(*) total,
265
+ COALESCE(SUM(CASE WHEN state='completed' THEN 1 ELSE 0 END),0) completed
266
+ FROM grid_roots WHERE root_z=? AND root_x BETWEEN ? AND ? AND root_y BETWEEN ? AND ?`).get(rootZoom, xMin, xMax, yMin, yMax);
267
+ return progress.total > 0 ? { completed: Number(progress.completed), total: Number(progress.total) } : null;
268
+ } finally {
269
+ db.close();
270
+ }
271
+ }
272
+ function pmtiles(path) {
273
+ const key = cacheKey(path);
274
+ const cached = archives.get(key);
275
+ if (cached) return cached;
276
+ const source = {
277
+ path,
278
+ getKey: () => key,
279
+ async getBytes(offset, length) {
280
+ const file = await open$1(path, "r");
281
+ try {
282
+ const buffer = Buffer.allocUnsafe(length);
283
+ const { bytesRead } = await file.read(buffer, 0, length, offset);
284
+ return { data: buffer.subarray(0, bytesRead).buffer.slice(buffer.byteOffset, buffer.byteOffset + bytesRead) };
285
+ } finally {
286
+ await file.close();
287
+ }
288
+ }
289
+ };
290
+ const archive = new PMTiles(source);
291
+ archives.set(key, archive);
292
+ while (archives.size > 4) archives.delete(archives.keys().next().value);
293
+ return archive;
294
+ }
295
+ function renderer(path) {
296
+ const key = cacheKey(path);
297
+ const cached = geometry.get(key);
298
+ if (cached) return cached;
299
+ const created = new GeographicGridRenderer(path);
300
+ geometry.set(key, created);
301
+ while (geometry.size > 4) geometry.delete(geometry.keys().next().value);
302
+ return created;
303
+ }
304
+ async function readTileFile(file, z, x, y) {
305
+ var _a;
306
+ return (_a = (await readTileFiles(file, [{ z, x, y }]))[0]) != null ? _a : null;
307
+ }
308
+ async function readTileFiles(file, coordinates) {
309
+ if (file.kind === "pmtiles") {
310
+ const archive = pmtiles(file.path);
311
+ return await Promise.all(coordinates.map(async ({ z, x, y }) => {
312
+ const tile = await archive.getZxy(z, x, y);
313
+ return tile ? Buffer.from(tile.data) : null;
314
+ }));
315
+ }
316
+ const db = new DatabaseSync(file.path, { readOnly: true });
317
+ const tiles = [];
318
+ try {
319
+ const hasTiles = Boolean(db.prepare("SELECT 1 FROM sqlite_master WHERE type='table' AND name='tiles'").get());
320
+ if (!hasTiles) return coordinates.map(() => null);
321
+ const select = db.prepare("SELECT tile_data FROM tiles WHERE zoom_level=? AND tile_column=? AND tile_row=?");
322
+ for (const { z, x, y } of coordinates) {
323
+ const row = select.get(z, x, xyzYToTmsY(z, y));
324
+ tiles.push(row ? Buffer.from(row.tile_data) : null);
325
+ }
326
+ } finally {
327
+ db.close();
328
+ }
329
+ if (file.kind !== "uomtiles") return tiles;
330
+ const dynamic = renderer(file.path);
331
+ if (!dynamic.available) return tiles;
332
+ return tiles.map((tile, index) => {
333
+ const coordinate = coordinates[index];
334
+ return tile || coordinate.z > DYNAMIC_MAX_ZOOM ? tile : dynamic.renderTile(coordinate.z, coordinate.x, coordinate.y);
335
+ });
336
+ }
337
+ async function tileFileCoordinates(file) {
338
+ if (file.kind !== "pmtiles") {
339
+ const db = new DatabaseSync(file.path, { readOnly: true });
340
+ try {
341
+ const hasTiles = Boolean(db.prepare("SELECT 1 FROM sqlite_master WHERE type='table' AND name='tiles'").get());
342
+ if (!hasTiles) return [];
343
+ const rows = db.prepare(`SELECT zoom_level z,tile_column x,((1 << zoom_level)-1-tile_row) y
344
+ FROM tiles ORDER BY zoom_level,tile_column,((1 << zoom_level)-1-tile_row)`).all();
345
+ return rows.map(({ z, x, y }) => ({ z, x, y }));
346
+ } finally {
347
+ db.close();
348
+ }
349
+ }
350
+ const archive = pmtiles(file.path);
351
+ const header = await archive.getHeader();
352
+ const coordinates = [];
353
+ const visit = async (offset, length) => {
354
+ const entries = await archive.cache.getDirectory(archive.source, offset, length, header);
355
+ for (const entry of entries) {
356
+ if (entry.runLength === 0) {
357
+ await visit(header.leafDirectoryOffset + entry.offset, entry.length);
358
+ continue;
359
+ }
360
+ for (let index = 0; index < entry.runLength; index++) {
361
+ const [z, x, y] = tileIdToZxy(entry.tileId + index);
362
+ coordinates.push({ z, x, y });
363
+ }
364
+ }
365
+ };
366
+ await visit(header.rootDirectoryOffset, header.rootDirectoryLength);
367
+ coordinates.sort((left, right) => left.z - right.z || left.x - right.x || left.y - right.y);
368
+ return coordinates;
369
+ }
370
+ async function tileFileCoordinatesAtZoom(file, zoom) {
371
+ if (file.kind === "uomtiles") {
372
+ const dynamic = renderer(file.path);
373
+ if (dynamic.available) return [...dynamic.contentCoordinates(zoom)];
374
+ }
375
+ if (file.kind !== "pmtiles") {
376
+ const db = new DatabaseSync(file.path, { readOnly: true });
377
+ try {
378
+ const hasTiles = Boolean(db.prepare("SELECT 1 FROM sqlite_master WHERE type='table' AND name='tiles'").get());
379
+ if (!hasTiles) return [];
380
+ return db.prepare(`SELECT zoom_level z,tile_column x,((1 << zoom_level)-1-tile_row) y
381
+ FROM tiles WHERE zoom_level=? ORDER BY tile_column,((1 << zoom_level)-1-tile_row)`).all(zoom).map(({ z, x, y }) => ({ z, x, y }));
382
+ } finally {
383
+ db.close();
384
+ }
385
+ }
386
+ return (await tileFileCoordinates(file)).filter((coordinate) => coordinate.z === zoom);
387
+ }
388
+
389
+ const DEFAULT_LEASE_MS = 3e4;
390
+ function getSqliteLease(databasePath, resource, now = Date.now()) {
391
+ if (!existsSync(databasePath)) return null;
392
+ let db;
393
+ try {
394
+ db = new DatabaseSync(databasePath, { readOnly: true });
395
+ } catch {
396
+ return null;
397
+ }
398
+ try {
399
+ const table = db.prepare("SELECT 1 present FROM sqlite_master WHERE type='table' AND name='uomtiles_leases'").get();
400
+ if (!table) return null;
401
+ const row = db.prepare(`SELECT resource,owner,pid,hostname,acquired_at,heartbeat_at,expires_at
402
+ FROM uomtiles_leases WHERE resource=?`).get(resource);
403
+ if (!row || row.expires_at <= now) return null;
404
+ return {
405
+ resource: row.resource,
406
+ owner: row.owner,
407
+ pid: row.pid,
408
+ hostname: row.hostname,
409
+ acquiredAt: row.acquired_at,
410
+ heartbeatAt: row.heartbeat_at,
411
+ expiresAt: row.expires_at
412
+ };
413
+ } catch {
414
+ return null;
415
+ } finally {
416
+ db.close();
417
+ }
418
+ }
419
+ function hasActiveSqliteLease(databasePath, resource, now = Date.now()) {
420
+ return Boolean(getSqliteLease(databasePath, resource, now));
421
+ }
422
+ function open(path) {
423
+ mkdirSync(dirname(path), { recursive: true });
424
+ const db = new DatabaseSync(path);
425
+ db.exec(`PRAGMA busy_timeout=5000;
426
+ CREATE TABLE IF NOT EXISTS uomtiles_leases(
427
+ resource TEXT PRIMARY KEY,
428
+ owner TEXT NOT NULL,
429
+ pid INTEGER NOT NULL,
430
+ hostname TEXT NOT NULL,
431
+ acquired_at INTEGER NOT NULL,
432
+ heartbeat_at INTEGER NOT NULL,
433
+ expires_at INTEGER NOT NULL);`);
434
+ return db;
435
+ }
436
+ function acquireSqliteLease(databasePath, resource, leaseMs = DEFAULT_LEASE_MS) {
437
+ if (!Number.isSafeInteger(leaseMs) || leaseMs <= 0) throw new RangeError("SQLite lease duration must be a positive integer");
438
+ const db = open(databasePath);
439
+ const owner = randomUUID();
440
+ const now = Date.now();
441
+ try {
442
+ db.exec("BEGIN IMMEDIATE");
443
+ const current = db.prepare("SELECT owner,pid,hostname,expires_at FROM uomtiles_leases WHERE resource=?").get(resource);
444
+ if (current && current.expires_at > now) {
445
+ throw new Error(`SQLite \u8D44\u6E90\u6B63\u88AB\u5360\u7528\uFF1A${resource} (pid ${current.pid} on ${current.hostname})`);
446
+ }
447
+ db.prepare(`INSERT OR REPLACE INTO uomtiles_leases(resource,owner,pid,hostname,acquired_at,heartbeat_at,expires_at)
448
+ VALUES(?,?,?,?,?,?,?)`).run(resource, owner, process.pid, hostname(), now, now, now + leaseMs);
449
+ db.exec("COMMIT");
450
+ } catch (error) {
451
+ try {
452
+ db.exec("ROLLBACK");
453
+ } catch {
454
+ }
455
+ db.close();
456
+ throw error;
457
+ }
458
+ let released = false;
459
+ return {
460
+ resource,
461
+ owner,
462
+ heartbeat() {
463
+ if (released) return;
464
+ const heartbeatAt = Date.now();
465
+ const result = db.prepare("UPDATE uomtiles_leases SET heartbeat_at=?,expires_at=? WHERE resource=? AND owner=?").run(heartbeatAt, heartbeatAt + leaseMs, resource, owner);
466
+ if (result.changes !== 1) throw new Error(`SQLite lease \u5DF2\u4E22\u5931\uFF1A${resource}`);
467
+ },
468
+ release() {
469
+ if (released) return;
470
+ released = true;
471
+ try {
472
+ db.prepare("DELETE FROM uomtiles_leases WHERE resource=? AND owner=?").run(resource, owner);
473
+ } finally {
474
+ db.close();
475
+ }
476
+ }
477
+ };
478
+ }
479
+
480
+ const execFileAsync = promisify(execFile);
481
+ const UOMTILES_SCHEMA_VERSION = 1;
482
+ function tables(db) {
483
+ return new Set(db.prepare("SELECT name FROM sqlite_master WHERE type='table'").all().map((row) => row.name));
484
+ }
485
+ function metadata(db) {
486
+ if (!tables(db).has("metadata")) return {};
487
+ return Object.fromEntries(db.prepare("SELECT name,value FROM metadata").all().map((row) => [row.name, row.value]));
488
+ }
489
+ function initializeUomtiles(path, publisher) {
490
+ mkdirSync(dirname(path), { recursive: true });
491
+ const db = new DatabaseSync(path);
492
+ try {
493
+ db.exec(`
494
+ CREATE TABLE IF NOT EXISTS metadata(name TEXT PRIMARY KEY,value TEXT NOT NULL);
495
+ CREATE TABLE IF NOT EXISTS uomtiles_task(
496
+ id TEXT PRIMARY KEY,
497
+ schema_version INTEGER NOT NULL,
498
+ state TEXT NOT NULL,
499
+ publisher TEXT,
500
+ created_at TEXT NOT NULL,
501
+ started_at TEXT,
502
+ finished_at TEXT,
503
+ tool_version TEXT NOT NULL);
504
+ CREATE TABLE IF NOT EXISTS uomtiles_review(
505
+ kind TEXT NOT NULL,
506
+ object_key TEXT NOT NULL,
507
+ state TEXT NOT NULL,
508
+ note TEXT,
509
+ updated_at TEXT NOT NULL,
510
+ PRIMARY KEY(kind,object_key));
511
+ CREATE TABLE IF NOT EXISTS uomtiles_leases(
512
+ resource TEXT PRIMARY KEY,
513
+ owner TEXT NOT NULL,
514
+ pid INTEGER NOT NULL,
515
+ hostname TEXT NOT NULL,
516
+ acquired_at INTEGER NOT NULL,
517
+ heartbeat_at INTEGER NOT NULL,
518
+ expires_at INTEGER NOT NULL);
519
+ `);
520
+ const existing = db.prepare("SELECT id FROM uomtiles_task LIMIT 1").get();
521
+ if (!existing) {
522
+ const meta = metadata(db);
523
+ const createdAt = meta.crawl_started_at || (/* @__PURE__ */ new Date()).toISOString();
524
+ const finishedAt = meta.crawl_finished_at || null;
525
+ db.prepare(`INSERT INTO uomtiles_task(id,schema_version,state,publisher,created_at,started_at,finished_at,tool_version)
526
+ VALUES(?,?,?,?,?,?,?,?)`).run(
527
+ randomUUID(),
528
+ UOMTILES_SCHEMA_VERSION,
529
+ finishedAt ? "completed" : "incomplete",
530
+ publisher || null,
531
+ createdAt,
532
+ meta.crawl_started_at || null,
533
+ finishedAt,
534
+ process.env.npm_package_version || "0.1.0"
535
+ );
536
+ }
537
+ const upsert = db.prepare("INSERT OR REPLACE INTO metadata(name,value) VALUES(?,?)");
538
+ upsert.run("uomtiles_schema_version", String(UOMTILES_SCHEMA_VERSION));
539
+ if (publisher) upsert.run("publisher", publisher);
540
+ } finally {
541
+ db.close();
542
+ }
543
+ }
544
+ function inspectUomtiles(path) {
545
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j;
546
+ const absolute = resolve(path);
547
+ const db = new DatabaseSync(absolute, { readOnly: true });
548
+ try {
549
+ const knownTables = tables(db);
550
+ const meta = metadata(db);
551
+ const task = knownTables.has("uomtiles_task") ? db.prepare("SELECT * FROM uomtiles_task LIMIT 1").get() : null;
552
+ const roots = knownTables.has("grid_roots") ? Object.fromEntries(db.prepare("SELECT state,COUNT(*) count FROM grid_roots GROUP BY state").all().map((row) => [row.state, row.count])) : {};
553
+ const tiles = knownTables.has("tiles") ? db.prepare("SELECT zoom_level z,COUNT(*) count,COALESCE(SUM(length(tile_data)),0) bytes FROM tiles GROUP BY zoom_level ORDER BY zoom_level").all() : [];
554
+ return {
555
+ path: absolute,
556
+ bytes: statSync(absolute).size,
557
+ schemaVersion: (_a = task == null ? void 0 : task.schema_version) != null ? _a : meta.uomtiles_schema_version ? Number(meta.uomtiles_schema_version) : null,
558
+ taskId: (_b = task == null ? void 0 : task.id) != null ? _b : null,
559
+ state: (task == null ? void 0 : task.state) === "completed" || meta.crawl_finished_at ? "completed" : "incomplete",
560
+ publisher: (_d = (_c = task == null ? void 0 : task.publisher) != null ? _c : meta.publisher) != null ? _d : null,
561
+ createdAt: (_f = (_e = task == null ? void 0 : task.created_at) != null ? _e : meta.crawl_started_at) != null ? _f : null,
562
+ startedAt: (_h = (_g = task == null ? void 0 : task.started_at) != null ? _g : meta.crawl_started_at) != null ? _h : null,
563
+ finishedAt: (_j = (_i = task == null ? void 0 : task.finished_at) != null ? _i : meta.crawl_finished_at) != null ? _j : null,
564
+ sourceZoom: meta.source_zoom ? Number(meta.source_zoom) : null,
565
+ gridLevel: meta.geographic_grid_level ? Number(meta.geographic_grid_level) : null,
566
+ roots,
567
+ tiles
568
+ };
569
+ } finally {
570
+ db.close();
571
+ }
572
+ }
573
+ function exportMbtiles(source, target) {
574
+ var _a, _b;
575
+ const input = resolve(source);
576
+ const output = resolve(target);
577
+ if (extname(output).toLowerCase() !== ".mbtiles") throw new Error("MBTiles \u8F93\u51FA\u6587\u4EF6\u5FC5\u987B\u4F7F\u7528 .mbtiles \u6269\u5C55\u540D");
578
+ const lock = acquireSqliteLease(input, "writer");
579
+ const temporary = `${output}.${process.pid}.tmp`;
580
+ if (existsSync(temporary)) unlinkSync(temporary);
581
+ mkdirSync(dirname(output), { recursive: true });
582
+ const sourceDb = new DatabaseSync(input, { readOnly: true });
583
+ const outputDb = new DatabaseSync(temporary);
584
+ try {
585
+ outputDb.exec(`PRAGMA journal_mode=OFF; PRAGMA synchronous=OFF;
586
+ CREATE TABLE metadata(name TEXT PRIMARY KEY,value TEXT NOT NULL);
587
+ CREATE TABLE tiles(zoom_level INTEGER NOT NULL,tile_column INTEGER NOT NULL,tile_row INTEGER NOT NULL,tile_data BLOB NOT NULL,
588
+ PRIMARY KEY(zoom_level,tile_column,tile_row));`);
589
+ const insertMeta = outputDb.prepare("INSERT INTO metadata(name,value) VALUES(?,?)");
590
+ const standard = /* @__PURE__ */ new Set(["name", "type", "version", "description", "format", "bounds", "center", "minzoom", "attribution"]);
591
+ const meta = metadata(sourceDb);
592
+ outputDb.exec("BEGIN");
593
+ for (const name of standard) if (meta[name]) insertMeta.run(name, meta[name]);
594
+ const summary = inspectUomtiles(input);
595
+ insertMeta.run("uomtiles:publisher", summary.publisher || "unknown");
596
+ insertMeta.run("uomtiles:fetched_at", summary.finishedAt || summary.startedAt || "unknown");
597
+ insertMeta.run("uomtiles:source_zoom", String((_a = summary.sourceZoom) != null ? _a : "unknown"));
598
+ insertMeta.run("uomtiles:grid_level", String((_b = summary.gridLevel) != null ? _b : "unknown"));
599
+ const renderer = new GeographicGridRenderer(input);
600
+ insertMeta.run("maxzoom", String(renderer.available ? PUBLISH_MAX_ZOOM : Math.max(0, ...summary.tiles.map((tile) => tile.z))));
601
+ const insertTile = outputDb.prepare("INSERT INTO tiles VALUES(?,?,?,?)");
602
+ let copied = 0;
603
+ if (renderer.available) {
604
+ for (let z = 0; z <= PUBLISH_MAX_ZOOM; z++) for (const coordinate of renderer.contentCoordinates(z)) {
605
+ const tile = renderer.renderTile(z, coordinate.x, coordinate.y);
606
+ if (!tile) continue;
607
+ insertTile.run(z, coordinate.x, xyzYToTmsY(z, coordinate.y), tile);
608
+ copied++;
609
+ if (copied % 1e3 === 0) lock.heartbeat();
610
+ }
611
+ } else {
612
+ for (const row of sourceDb.prepare("SELECT zoom_level,tile_column,tile_row,tile_data FROM tiles ORDER BY zoom_level,tile_column,tile_row").iterate()) {
613
+ insertTile.run(row.zoom_level, row.tile_column, row.tile_row, row.tile_data);
614
+ copied++;
615
+ if (copied % 1e3 === 0) lock.heartbeat();
616
+ }
617
+ }
618
+ lock.heartbeat();
619
+ outputDb.exec("COMMIT");
620
+ outputDb.exec("CREATE UNIQUE INDEX tile_index ON tiles(zoom_level,tile_column,tile_row); PRAGMA optimize;");
621
+ } catch (error) {
622
+ try {
623
+ outputDb.exec("ROLLBACK");
624
+ } catch {
625
+ }
626
+ throw error;
627
+ } finally {
628
+ outputDb.close();
629
+ sourceDb.close();
630
+ lock.release();
631
+ }
632
+ if (existsSync(output)) unlinkSync(output);
633
+ renameSync(temporary, output);
634
+ return inspectUomtiles(output);
635
+ }
636
+ async function exportTiles(source, target, pmtilesCommand = process.env.UOMTILES_PMTILES_COMMAND || "pmtiles") {
637
+ const extension = extname(target).toLowerCase();
638
+ if (extension === ".mbtiles") {
639
+ exportMbtiles(source, target);
640
+ return;
641
+ }
642
+ if (extension !== ".pmtiles") throw new Error("\u8F93\u51FA\u6587\u4EF6\u5FC5\u987B\u4F7F\u7528 .mbtiles \u6216 .pmtiles \u6269\u5C55\u540D");
643
+ const intermediate = `${resolve(target)}.${process.pid}.mbtiles`;
644
+ try {
645
+ exportMbtiles(source, intermediate);
646
+ await execFileAsync(pmtilesCommand, ["convert", intermediate, resolve(target), "--force", "--quiet"], { timeout: 30 * 6e4 });
647
+ } catch (error) {
648
+ if ((error == null ? void 0 : error.code) === "ENOENT") throw new Error(`\u627E\u4E0D\u5230 ${pmtilesCommand}\uFF1B\u8BF7\u5B89\u88C5 Protomaps pmtiles CLI \u6216\u8BBE\u7F6E UOMTILES_PMTILES_COMMAND`);
649
+ throw error;
650
+ } finally {
651
+ if (existsSync(intermediate)) unlinkSync(intermediate);
652
+ }
653
+ }
654
+
655
+ const FETCH_PROCESS_ENV = "UOMTILES_FETCH_PROCESS";
656
+ function decodeFetchProcess(value) {
657
+ if (!value) throw new Error(`${FETCH_PROCESS_ENV} is not configured`);
658
+ let parsed;
659
+ try {
660
+ parsed = JSON.parse(value);
661
+ } catch {
662
+ throw new Error(`${FETCH_PROCESS_ENV} is invalid`);
663
+ }
664
+ if (!parsed || typeof parsed !== "object") throw new Error(`${FETCH_PROCESS_ENV} is invalid`);
665
+ const spec = parsed;
666
+ if (typeof spec.command !== "string" || !spec.command || !Array.isArray(spec.args) || spec.args.some((arg) => typeof arg !== "string")) {
667
+ throw new Error(`${FETCH_PROCESS_ENV} is invalid`);
668
+ }
669
+ return { command: spec.command, args: spec.args };
670
+ }
671
+
672
+ const workers = /* @__PURE__ */ new Map();
673
+ function root() {
674
+ const path = workspaceDirectory(serverDataDirectory());
675
+ mkdirSync(path, { recursive: true });
676
+ return path;
677
+ }
678
+ function authPath() {
679
+ return accountFile(serverDataDirectory());
680
+ }
681
+ function removeOrphanWorkspaceSidecars(directory) {
682
+ const databases = /* @__PURE__ */ new Set();
683
+ for (const entry of readdirSync(directory, { withFileTypes: true })) {
684
+ if (!entry.isFile() || !/\.uomtiles-(?:wal|shm)$/i.test(entry.name)) continue;
685
+ databases.add(resolve(directory, entry.name.replace(/-(?:wal|shm)$/i, "")));
686
+ }
687
+ for (const database of databases) {
688
+ if (existsSync(database) && hasActiveSqliteLease(database, "writer")) continue;
689
+ for (const suffix of ["-wal", "-shm"]) {
690
+ const sidecar = `${database}${suffix}`;
691
+ if (existsSync(sidecar)) unlinkSync(sidecar);
692
+ }
693
+ }
694
+ }
695
+ function cleanWorkspaceFilename(filename) {
696
+ const candidate = filename.trim();
697
+ if (!candidate || basename(candidate) !== candidate || candidate.includes("/") || candidate.includes("\\") || candidate.includes("\0")) {
698
+ throw createError({ statusCode: 400, statusMessage: "\u6587\u4EF6\u540D\u4E0D\u5408\u6CD5" });
699
+ }
700
+ const clean = candidate.replace(/[^a-zA-Z0-9._\u4e00-\u9fff-]+/g, "_");
701
+ if (!clean || clean === "." || clean === "..") throw createError({ statusCode: 400, statusMessage: "\u6587\u4EF6\u540D\u4E0D\u5408\u6CD5" });
702
+ return clean;
703
+ }
704
+ function entries() {
705
+ const directory = root();
706
+ removeOrphanWorkspaceSidecars(directory);
707
+ return readdirSync(directory, { withFileTypes: true }).filter((entry) => entry.isFile()).map((entry) => ({ filename: entry.name, path: resolve(directory, entry.name), extension: extname(entry.name).slice(1).toLowerCase() })).filter((entry) => entry.extension === "uomtiles").map((entry) => ({ filename: entry.filename, path: entry.path, kind: "uomtiles" }));
708
+ }
709
+ function safeFilename(filename) {
710
+ let candidate;
711
+ try {
712
+ candidate = decodeURIComponent(filename);
713
+ } catch {
714
+ throw createError({ statusCode: 400, statusMessage: "\u5DE5\u4F5C\u533A\u6587\u4EF6\u540D\u7F16\u7801\u4E0D\u5408\u6CD5" });
715
+ }
716
+ if (!candidate || candidate === "." || candidate === ".." || basename(candidate) !== candidate || candidate.includes("\\") || candidate.includes("\0")) {
717
+ throw createError({ statusCode: 400, statusMessage: "\u5DE5\u4F5C\u533A\u6587\u4EF6\u540D\u4E0D\u5408\u6CD5" });
718
+ }
719
+ const workspaceRoot = root();
720
+ const target = resolve(workspaceRoot, candidate);
721
+ if (!target.startsWith(`${workspaceRoot}${sep}`)) throw createError({ statusCode: 400, statusMessage: "\u5DE5\u4F5C\u533A\u6587\u4EF6\u8DEF\u5F84\u4E0D\u5408\u6CD5" });
722
+ return candidate;
723
+ }
724
+ function resolveWorkspaceFile(filename) {
725
+ const candidate = safeFilename(filename);
726
+ const found = entries().find((entry) => entry.filename === candidate);
727
+ if (!found) throw createError({ statusCode: 404, statusMessage: "\u5DE5\u4F5C\u533A\u6587\u4EF6\u4E0D\u5B58\u5728" });
728
+ return found;
729
+ }
730
+ function validateTileFile(path, kind) {
731
+ if (kind === "pmtiles") {
732
+ const bytes = Buffer.alloc(127);
733
+ const file = openSync(path, "r");
734
+ try {
735
+ if (readSync(file, bytes, 0, bytes.length, 0) !== bytes.length) throw new Error("PMTiles header is truncated");
736
+ bytesToHeader(bytes.buffer.slice(bytes.byteOffset, bytes.byteOffset + bytes.byteLength));
737
+ } finally {
738
+ closeSync(file);
739
+ }
740
+ return;
741
+ }
742
+ const db = new DatabaseSync(path, { readOnly: true });
743
+ try {
744
+ const tables = new Set(db.prepare("SELECT name FROM sqlite_master WHERE type='table'").all().map((row) => row.name));
745
+ if (kind === "uomtiles") {
746
+ if (!tables.has("uomtiles_task")) throw new Error("UOMTiles \u6587\u4EF6\u7F3A\u5C11 uomtiles_task \u8868");
747
+ return;
748
+ }
749
+ if (!tables.has("tiles")) throw new Error("SQLite \u6587\u4EF6\u7F3A\u5C11 tiles \u8868");
750
+ if (!tables.has("metadata")) throw new Error("MBTiles \u6587\u4EF6\u7F3A\u5C11 metadata \u8868");
751
+ db.prepare("SELECT zoom_level,tile_column,tile_row,tile_data FROM tiles LIMIT 1").get();
752
+ } finally {
753
+ db.close();
754
+ }
755
+ }
756
+ function publicSummary(summary, locked = true) {
757
+ const { path: _path, taskId: _taskId, ...publicValue } = summary;
758
+ return { ...publicValue, state: locked ? "running" : publicValue.state === "completed" ? "completed" : "incomplete" };
759
+ }
760
+ function readWorkspaceFile(entry) {
761
+ try {
762
+ const stat = statSync(entry.path);
763
+ validateTileFile(entry.path, entry.kind);
764
+ const locked = entry.kind === "uomtiles" && hasActiveSqliteLease(entry.path, "writer");
765
+ const summary = publicSummary(inspectUomtiles(entry.path), locked);
766
+ const zoomRange = { minZoom: 0, maxZoom: DYNAMIC_MAX_ZOOM };
767
+ return { filename: entry.filename, kind: entry.kind, bytes: stat.size, modifiedAt: stat.mtime.toISOString(), ...zoomRange, summary, locked };
768
+ } catch {
769
+ return null;
770
+ }
771
+ }
772
+ function listWorkspaceFiles() {
773
+ const files = entries().map(readWorkspaceFile).filter((entry) => Boolean(entry));
774
+ removeOrphanWorkspaceSidecars(root());
775
+ return files.sort((a, b) => b.modifiedAt.localeCompare(a.modifiedAt));
776
+ }
777
+ async function importWorkspaceFile(filename, input) {
778
+ const clean = cleanWorkspaceFilename(filename);
779
+ const extension = extname(clean).slice(1).toLowerCase();
780
+ if (extension !== "uomtiles") throw createError({ statusCode: 400, statusMessage: "\u5DE5\u4F5C\u533A\u4EC5\u652F\u6301 .uomtiles \u4EFB\u52A1\u6587\u4EF6" });
781
+ const target = resolve(root(), clean);
782
+ if (entries().some((entry) => entry.filename.toLocaleLowerCase() === clean.toLocaleLowerCase())) throw createError({ statusCode: 409, statusMessage: "\u5DE5\u4F5C\u533A\u4E2D\u5DF2\u5B58\u5728\u540C\u540D\u6587\u4EF6" });
783
+ const temporary = `${target}.${process.pid}.${randomUUID()}.tmp`;
784
+ try {
785
+ await pipeline(input, createWriteStream(temporary, { flags: "wx", mode: 384 }));
786
+ if (statSync(temporary).size === 0) throw createError({ statusCode: 400, statusMessage: "\u6587\u4EF6\u4E3A\u7A7A" });
787
+ try {
788
+ validateTileFile(temporary, "uomtiles");
789
+ } catch (error) {
790
+ throw createError({ statusCode: 400, statusMessage: `\u6587\u4EF6\u683C\u5F0F\u65E0\u6548\uFF1A${error instanceof Error ? error.message : String(error)}` });
791
+ }
792
+ renameSync(temporary, target);
793
+ } catch (error) {
794
+ if (existsSync(temporary)) unlinkSync(temporary);
795
+ throw error;
796
+ }
797
+ return listWorkspaceFiles().find((entry) => entry.filename === clean);
798
+ }
799
+ function createWorkspaceTask(filename, publisher) {
800
+ const clean = cleanWorkspaceFilename(filename);
801
+ const extension = extname(clean);
802
+ if (extension && extension.toLowerCase() !== ".uomtiles" || clean === ".uomtiles") {
803
+ throw createError({ statusCode: 400, statusMessage: "\u4EFB\u52A1\u6587\u4EF6\u5FC5\u987B\u4F7F\u7528 .uomtiles \u6269\u5C55\u540D" });
804
+ }
805
+ const name = extension ? `${clean.slice(0, -extension.length)}.uomtiles` : `${clean}.uomtiles`;
806
+ if (entries().some((entry) => entry.filename.toLocaleLowerCase() === name.toLocaleLowerCase())) {
807
+ throw createError({ statusCode: 409, statusMessage: "\u540C\u540D\u4EFB\u52A1\u6587\u4EF6\u5DF2\u5B58\u5728" });
808
+ }
809
+ const storedName = name;
810
+ if (existsSync(resolve(root(), storedName))) throw createError({ statusCode: 409, statusMessage: "\u5DE5\u4F5C\u533A\u4E2D\u5DF2\u5B58\u5728\u540C\u540D\u6587\u4EF6" });
811
+ const target = resolve(root(), storedName);
812
+ const temporary = `${target}.${process.pid}.${randomUUID()}.tmp`;
813
+ try {
814
+ initializeUomtiles(temporary, publisher);
815
+ chmodSync(temporary, 384);
816
+ renameSync(temporary, target);
817
+ } catch (error) {
818
+ if (existsSync(temporary)) unlinkSync(temporary);
819
+ throw error;
820
+ }
821
+ return listWorkspaceFiles().find((entry) => entry.filename === storedName);
822
+ }
823
+ function deleteWorkspaceFile(filename) {
824
+ if (workers.has(filename)) throw createError({ statusCode: 409, statusMessage: "\u4E0B\u8F7D\u4E2D\u7684\u4EFB\u52A1\u4E0D\u80FD\u5220\u9664\uFF0C\u8BF7\u5148\u505C\u6B62\u4E0B\u8F7D" });
825
+ const file = resolveWorkspaceFile(filename);
826
+ if (file.kind !== "uomtiles") throw createError({ statusCode: 400, statusMessage: "\u53EA\u80FD\u5220\u9664\u5730\u56FE\u4E0B\u8F7D\u4EFB\u52A1" });
827
+ if (hasActiveSqliteLease(file.path, "writer")) throw createError({ statusCode: 409, statusMessage: "\u4EFB\u52A1\u6B63\u5728\u88AB\u5176\u4ED6\u8FDB\u7A0B\u4F7F\u7528\uFF0C\u6682\u65F6\u4E0D\u80FD\u5220\u9664" });
828
+ unlinkSync(file.path);
829
+ for (const suffix of ["-wal", "-shm"]) {
830
+ const sidecar = `${file.path}${suffix}`;
831
+ if (existsSync(sidecar)) unlinkSync(sidecar);
832
+ }
833
+ }
834
+ function startWorkspaceFetch(filename) {
835
+ const file = resolveWorkspaceFile(filename);
836
+ if (file.kind !== "uomtiles") throw createError({ statusCode: 400, statusMessage: "\u53EA\u6709 .uomtiles \u652F\u6301\u6293\u53D6\u548C\u65AD\u70B9\u7EED\u4F20" });
837
+ if (hasActiveSqliteLease(file.path, "writer") || workers.has(file.filename)) {
838
+ throw createError({ statusCode: 409, statusMessage: "\u8BE5\u4EFB\u52A1\u6B63\u5728\u4E0B\u8F7D" });
839
+ }
840
+ if (!existsSync(authPath())) throw createError({ statusCode: 401, statusMessage: "\u8BF7\u5148\u767B\u5F55 UOM" });
841
+ let spec;
842
+ try {
843
+ spec = decodeFetchProcess(process.env[FETCH_PROCESS_ENV]);
844
+ } catch (error) {
845
+ throw createError({ statusCode: 500, statusMessage: error instanceof Error ? error.message : String(error) });
846
+ }
847
+ const child = spawn(spec.command, spec.args, {
848
+ cwd: process.cwd(),
849
+ env: {
850
+ ...process.env,
851
+ UOMTILES_DATA_DIR: serverDataDirectory(),
852
+ UOMTILES_TASK_FILENAME: file.filename
853
+ },
854
+ stdio: "ignore"
855
+ });
856
+ workers.set(file.filename, { child });
857
+ const clear = () => {
858
+ var _a;
859
+ if (((_a = workers.get(file.filename)) == null ? void 0 : _a.child) === child) workers.delete(file.filename);
860
+ };
861
+ child.once("error", clear);
862
+ child.once("close", clear);
863
+ return listWorkspaceFiles();
864
+ }
865
+ function stopWorkspaceFetch(filename) {
866
+ const candidates = entries().filter((entry2) => entry2.kind === "uomtiles");
867
+ const entry = filename ? candidates.find((candidate) => candidate.filename === filename) : candidates.find((candidate) => Boolean(getSqliteLease(candidate.path, "writer")));
868
+ const lease = entry ? getSqliteLease(entry.path, "writer") : null;
869
+ const targetFilename = (entry == null ? void 0 : entry.filename) || filename;
870
+ const local = targetFilename ? workers.get(targetFilename) : void 0;
871
+ const pid = (local == null ? void 0 : local.child.pid) || (lease == null ? void 0 : lease.pid);
872
+ if (local) local.child.kill("SIGTERM");
873
+ else if ((lease == null ? void 0 : lease.hostname) === hostname() && pid && pid !== process.pid) {
874
+ try {
875
+ process.kill(pid, "SIGTERM");
876
+ } catch (error) {
877
+ if ((error == null ? void 0 : error.code) !== "ESRCH") {
878
+ console.error(`\u505C\u6B62\u6293\u53D6\u5931\u8D25\uFF1A${(error == null ? void 0 : error.message) || String(error)}`);
879
+ }
880
+ }
881
+ }
882
+ return listWorkspaceFiles();
883
+ }
884
+ async function ensureWorkspaceExport(filename, format) {
885
+ const file = resolveWorkspaceFile(filename);
886
+ if (file.kind !== "uomtiles") throw createError({ statusCode: 400, statusMessage: "\u4EC5 .uomtiles \u53EF\u5BFC\u51FA" });
887
+ const directory = mkdtempSync(resolve(tmpdir(), "uomtiles-export-"));
888
+ const output = resolve(directory, `${file.filename.replace(/\.uomtiles$/i, "")}.${format}`);
889
+ try {
890
+ await exportTiles(file.path, output, String(useRuntimeConfig().pmtilesCommand || "pmtiles"));
891
+ return output;
892
+ } catch (error) {
893
+ rmSync(directory, { recursive: true, force: true });
894
+ throw error;
895
+ }
896
+ }
897
+ async function readWorkspaceTile(filename, z, x, y) {
898
+ return readTileFile(resolveWorkspaceFile(filename), z, x, y);
899
+ }
900
+ function workspaceTileProgress(filename, z, x, y) {
901
+ const file = resolveWorkspaceFile(filename);
902
+ return file.kind === "uomtiles" ? taskTileProgress(file.path, z, x, y) : null;
903
+ }
904
+ function workspaceReadStream(filename) {
905
+ const file = resolveWorkspaceFile(filename);
906
+ return { file, stream: createReadStream(file.path) };
907
+ }
908
+
909
+ export { workspaceTileProgress as a, readWorkspaceTile as b, readTileFiles as c, deleteWorkspaceFile as d, ensureWorkspaceExport as e, tileFileCoordinates as f, stopWorkspaceFetch as g, createWorkspaceTask as h, importWorkspaceFile as i, cleanWorkspaceFilename as j, hasActiveSqliteLease as k, listWorkspaceFiles as l, resolveWorkspaceFile as r, startWorkspaceFetch as s, tileFileCoordinatesAtZoom as t, validateTileFile as v, workspaceReadStream as w };
910
+ //# sourceMappingURL=file-workspace.mjs.map