@sheetxl/studio-vanilla 0.8.0-beta.1 → 0.8.0-beta.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (539) hide show
  1. package/browser/esm/-LoBx7J6imeqaxCq.mjs +236 -0
  2. package/browser/esm/8-jmVNNbOHuXFdVQ.mjs +392 -0
  3. package/browser/esm/{CJPemkFUzhcAD_qR.mjs → B00ixdmb8-O5ijEp.mjs} +1 -1
  4. package/{cdn/assets/Bv_96nwOEMHN9Sa0.js → browser/esm/B0Wjc3lwtjKMwnvn.mjs} +27 -29
  5. package/browser/esm/B3Ii8x6RquHW1jMc.mjs +299 -0
  6. package/{cdn/assets/C_Io1QC4CeLGRBrz.js → browser/esm/B7iV5qzlmJlM2nQv.mjs} +179 -202
  7. package/{cdn/assets/D_t53-8k73CNpV-p2.js → browser/esm/BAH_cWcQEIBKWnl6.mjs} +94 -74
  8. package/browser/esm/BAdRecWK1maKGOZd.mjs +142 -0
  9. package/browser/esm/BBjgqNlHm-ssbSAG.mjs +47 -0
  10. package/browser/esm/BCWTI3jdTPG37r8W.mjs +46 -0
  11. package/browser/esm/{Dnx3_xXfRlD6ECfZ2.mjs → BMlPFJ1glExv-70Z.mjs} +5 -5
  12. package/browser/esm/{DBL3Qp5jyPrFg7KI2.mjs → BN2d5U1nw7pRtOrn.mjs} +1 -1
  13. package/browser/esm/BNIInlJQbJjH8B6G.mjs +84250 -0
  14. package/browser/esm/BPrHgyAsm2Htx15h.mjs +67 -0
  15. package/browser/esm/BRfat1fV3oGLwvin.mjs +76 -0
  16. package/browser/esm/{8V-VceXEjpADM8qK2.mjs → BSCja5yvevmKZPBB.mjs} +1 -1
  17. package/browser/esm/BThOwSja2ra4xejQ.mjs +6306 -0
  18. package/browser/esm/BVJUL2HhoedhbwVy.mjs +77 -0
  19. package/browser/esm/{CfvrjQGuf7vXiQCB.mjs → BWo1N4YbK_zGU0nu.mjs} +1 -1
  20. package/browser/esm/B_HB4y7AA88Z775Z.mjs +91 -0
  21. package/browser/esm/BaEZmurTZnX_yfKD.mjs +1082 -0
  22. package/browser/esm/BeMLfv6hWo15VCIL.mjs +239 -0
  23. package/{cdn/assets/C1ZePT2B182vSnxW.js → browser/esm/BhkeuRcx8RlLCQ5E.mjs} +1 -1
  24. package/browser/esm/Bi5-feQLtwpV6Ai8.mjs +57 -0
  25. package/browser/esm/BlPn_DXaEXOPxMxC.mjs +540 -0
  26. package/browser/esm/{B4iT_CduJeJunwBc.mjs → BsUrrzAgfyAdcCJW.mjs} +28 -13
  27. package/browser/esm/{47Yv4X226-93If7L.mjs → BtGmrIqU9W1L8zfZ.mjs} +1 -1
  28. package/browser/esm/BtdRr6IbtO6Gypsk.mjs +27 -0
  29. package/browser/esm/BwOxnbR61WFJwy0A.mjs +607 -0
  30. package/browser/esm/BxhKgo_rPQ2d12HT.mjs +35 -0
  31. package/browser/esm/By3a43qwWICwXRmw.mjs +8035 -0
  32. package/browser/esm/{BqTFwWLbXXJ0Fu-X2.mjs → ByUcqyCNfqi5Mm7w.mjs} +2 -2
  33. package/browser/esm/{Blc1T4zLkp8bRC_n2.mjs → ByqhqEMBLrnkaPKE.mjs} +28 -27
  34. package/{cdn/assets/8f9hCbpXTTYEgG31.js → browser/esm/C-0viTjg1dT2F-sk.mjs} +2 -2
  35. package/{cdn/assets/BMRav2VAqEzDSp3r.js → browser/esm/C3r_9RqlWrEmlXZ1.mjs} +37 -3
  36. package/browser/esm/C4VT6lNbpaDXCpBb.mjs +8820 -0
  37. package/browser/esm/{Be4QC65cR8N84rTn.mjs → C5EKgE9Owsc_juw-.mjs} +1 -1
  38. package/browser/esm/{1guzFZp1LHz_FwfL.mjs → C9NyIoUahFiyRCxP.mjs} +2 -2
  39. package/{cdn/assets/BykiUmcpDgSRNQI1.js → browser/esm/CBdNC7BOfc5TewHU.mjs} +1 -1
  40. package/browser/esm/CCd192S7yVpc6iOe.mjs +118 -0
  41. package/browser/esm/{BLcn1kGRsjURZSzk.mjs → CDsuiN--qdALFyql.mjs} +179 -202
  42. package/{cdn/assets/BDkVAo0CDCTE04ZJ.js → browser/esm/CFvKDDbrL3wpXnQH.mjs} +1 -1
  43. package/browser/esm/{CH0of3GZTzHviuQV.mjs → CHMqT9DzYKTxPfP6.mjs} +2 -2
  44. package/browser/esm/{CEN8dYSpN2oew8HH.mjs → CMxbiQ5J79M3n1tk.mjs} +604 -405
  45. package/browser/esm/{vcRSnmAqjwKglEkY.mjs → CQOyeq_-pg3CM-uA.mjs} +6 -7
  46. package/browser/esm/CQuv-nk5jtXUfu7C.mjs +7 -0
  47. package/browser/esm/CRAzVh3CaAa16avf.mjs +521 -0
  48. package/{cdn/assets/hFSDx-LnUOObv-6h.js → browser/esm/CSEMxasVyGCekxKf.mjs} +6 -7
  49. package/browser/esm/CTI-mCJbJzitJZwj.mjs +25 -0
  50. package/{cdn/assets/CdMv3f8Gyxh8q2RR.js → browser/esm/CTdFZ_I-41Vr6Dy4.mjs} +1 -1
  51. package/browser/esm/CVcCUfSRsiZ1-6hs.mjs +119 -0
  52. package/browser/esm/CVxlfyE-gnJM8hOz.mjs +177 -0
  53. package/browser/esm/CWJzHmEgahdOfNjH.mjs +527 -0
  54. package/browser/esm/CWoPWWRwMgkGPFFP.mjs +7393 -0
  55. package/browser/esm/CZOJogyZqMfUxcXj.mjs +1141 -0
  56. package/{cdn/assets/DLEdaT0MmrOxMa2h2.js → browser/esm/CaS8_J5HfBRk5_Nw.mjs} +94 -94
  57. package/browser/esm/CdeXXPCp5cCYvGyD.mjs +14 -0
  58. package/browser/esm/{BVRzmIk5PujkT_Ap.mjs → CfltjY8hY-RPwwpd.mjs} +582 -551
  59. package/browser/esm/Chr_TXM-48IsK8Va.mjs +155 -0
  60. package/browser/esm/{DTaVECXVrgvC48BE.mjs → ClJvUf8aR8vNC_3Z.mjs} +6 -6
  61. package/browser/esm/Clx8vvGDOTWK_M2l.mjs +484 -0
  62. package/browser/esm/CnWNviK4qlX2GVl6.mjs +73 -0
  63. package/browser/esm/{CQM87ZBN7Yzn4Yxr.mjs → Cpza4AeltEVHASij.mjs} +3 -3
  64. package/browser/esm/{BceIETi6JJRW6Ss62.mjs → CqoHxlGpZ3yzPj5V.mjs} +22 -21
  65. package/{cdn/assets/iXWgTu3qpYZHcx1J.js → browser/esm/CtZPEkaldpJpoGtW.mjs} +2197 -2013
  66. package/browser/esm/CvWGtHslTdesJik-.mjs +69 -0
  67. package/browser/esm/Cw-4uoMuq_m7ziA3.mjs +36 -0
  68. package/browser/esm/CxCipDFamYSOctBo.mjs +299 -0
  69. package/browser/esm/Cy00y9b9j17Txyv1.mjs +466 -0
  70. package/browser/esm/D-55MlIn7Wo_hdjI.mjs +905 -0
  71. package/browser/esm/D-9f1NKcpuYSgond.mjs +412 -0
  72. package/browser/esm/D-KZpU6HMaP4VUva.mjs +357 -0
  73. package/browser/esm/D0r2MPlWLnStWJNW.mjs +622 -0
  74. package/browser/esm/{9_bymSfTn_rR_v6W.mjs → D2aQPiGg0ZoMYzuf.mjs} +22 -21
  75. package/{cdn/assets/DKeLjEJPO9nT3bpr.js → browser/esm/D2coM-dNrlLpnUu5.mjs} +1000 -1010
  76. package/browser/esm/D7CGuQcwpkiuesEI.mjs +229 -0
  77. package/browser/esm/{RW23HF8taEtW8q9D.mjs → D7DWH3-5fBNx8jtc.mjs} +182 -132
  78. package/browser/esm/D7kkzIFPqKBK94kO.mjs +17952 -0
  79. package/browser/esm/D88StfSjZJi5E8Xb.mjs +5153 -0
  80. package/browser/esm/D8exjrado9TJrBp-.mjs +1946 -0
  81. package/browser/esm/DAE3Kv0Vs0VuBecT.mjs +32 -0
  82. package/browser/esm/DAprxR00V9qvNLL2.mjs +6607 -0
  83. package/browser/esm/DEvZj68igS7Q8SZE.mjs +763 -0
  84. package/browser/esm/DG3BfxRsbjey-B7E.mjs +441 -0
  85. package/browser/esm/DGCOPbZbEmt0x9z0.mjs +155 -0
  86. package/browser/esm/DGcvio2uhlrsE3ZY.mjs +236 -0
  87. package/browser/esm/DGuynZFJ9tqziqQs.mjs +92 -0
  88. package/browser/esm/DJqj66SnUcx0QmSN.mjs +15 -0
  89. package/browser/esm/DLhK_oSGg71ry6-m.mjs +86 -0
  90. package/{cdn/assets/D9-wpGVbTS9rRpxx.js → browser/esm/DLqc11Pf8vaE4Q5B.mjs} +2 -2
  91. package/browser/esm/DNCqTF9EbT-U1TdV.mjs +20 -0
  92. package/browser/esm/{R5bs6kCQSZmsCXz-.mjs → DNaPo7BQu6hr1fWq.mjs} +1 -1
  93. package/browser/esm/{BCkXtOM3yKocv7L-2.mjs → DQEjvIGMgEkiaP6J.mjs} +1 -1
  94. package/{cdn/assets/CAPgMrAKg07EREFD2.js → browser/esm/DQIRFXG4MveFkK3I.mjs} +1 -1
  95. package/browser/esm/{DrUEYcXg6N2D2s1Z2.mjs → DRm1R4uVOkaMfXNI.mjs} +51 -11
  96. package/browser/esm/DSf-Db1h8rlW2A6n.mjs +122 -0
  97. package/browser/esm/DSviq1TNoiIAGW7W.mjs +32 -0
  98. package/{cdn/assets/UYgwKnPX3US3Cj2k2.js → browser/esm/DTn9oYyiIYgyijAk.mjs} +110 -83
  99. package/{cdn/assets/Clfp7SznkOrJoQvL.js → browser/esm/DVpi1vC8ixXvUQG_.mjs} +3 -3
  100. package/browser/esm/{BOl4FzJRD7MplCU72.mjs → DWgp4t9N9u0eWthH.mjs} +1 -1
  101. package/{cdn/assets/B5ZqqASTcBEV5L9K.js → browser/esm/DXo8mR6t5HGsmTcu.mjs} +1 -1
  102. package/browser/esm/DZRmBfjn2TgOTu5e.mjs +3604 -0
  103. package/browser/esm/{DVZ_UnchuMRveDG32.mjs → D_7BWdsu8yejhUxy.mjs} +184 -11
  104. package/browser/esm/D_thhK0vSez8Yfle.mjs +798 -0
  105. package/browser/esm/DaMKWQQTgIF08cT7.mjs +105 -0
  106. package/browser/esm/Db6Tvr45TS9J5Qsb.mjs +259 -0
  107. package/{cdn/assets/EwzqnZl1lTr56hH-.js → browser/esm/Dc2ZwgbIEgYWwAsF.mjs} +1 -1
  108. package/{cdn/assets/DQ4o4dG7gWbL1X8F.js → browser/esm/DeUXRggj8Oz9ru_i.mjs} +2 -2
  109. package/{cdn/assets/DRc_Wi5c7WdKHTVN.js → browser/esm/DfESVLC8CAi8m8A7.mjs} +6 -6
  110. package/browser/esm/{D3G3tI3DVCUF3Gdk.mjs → DjdkGy-EI1kSo226.mjs} +7 -5
  111. package/browser/esm/DjtXfgbmXjUAoG0y.mjs +58 -0
  112. package/browser/esm/DlOVZD0OiAjouS6-.mjs +3563 -0
  113. package/browser/esm/Dme0qpRinBnhzp53.mjs +519 -0
  114. package/browser/esm/DnyZmrwPxShyeUjm.mjs +849 -0
  115. package/browser/esm/DoS1sE431fEhdOQb.mjs +216 -0
  116. package/browser/esm/DqBj-9o7UdXu4qhb.mjs +33 -0
  117. package/browser/esm/{DZbR5R1fNikjgqYb.mjs → DrI_S0A9TQvriTua.mjs} +1 -1
  118. package/browser/esm/Dv2z0548SZRGTN3l.mjs +149 -0
  119. package/browser/esm/{D6SKy2BtcWkhfiA02.mjs → Dv8aQFTTaQBJKDDk.mjs} +2 -5
  120. package/browser/esm/DvWCBuY0jAL-RmJV.mjs +3363 -0
  121. package/browser/esm/Dwxz0s23ra1tRtsH.mjs +7 -0
  122. package/browser/esm/{Cbw0JeJURvQyxIoa.mjs → DxcRLd7wmBGDgJsA.mjs} +1 -1
  123. package/{cdn/assets/DOsbSsKsexrBoeXa2.js → browser/esm/DxwprgjYhcmfDbXH.mjs} +24 -24
  124. package/browser/esm/{Dc0BDcQUGy_WIVFa.mjs → Dy44qJVkwNseMG-3.mjs} +1 -1
  125. package/browser/esm/DyeY6XwMQ_XNUHiW.mjs +89 -0
  126. package/browser/esm/{BD7RxHQgrqy_4tb5.mjs → ErIXJFPDFXwGEL8V.mjs} +2 -2
  127. package/{cdn/assets/COA_SZY2x8q6t4BD.js → browser/esm/FO1Jezau486fH4kN.mjs} +7 -6
  128. package/browser/esm/FjNOhkR7-JAIaRP6.mjs +19 -0
  129. package/browser/esm/H-JnJQMcZQbpvjdb.mjs +2706 -0
  130. package/browser/esm/J9i3r1fU0H10b2hX.mjs +1001 -0
  131. package/browser/esm/LAbUYeLiPG8z9cmA.mjs +277 -0
  132. package/browser/esm/M7RYrx20B_Yl_euJ.mjs +400 -0
  133. package/browser/esm/{Gy0CHZTvn4hY-rkx2.mjs → PtGiIWFBYP-ujLmf.mjs} +1 -1
  134. package/browser/esm/RLU85PsAYtKPUf6N.mjs +71 -0
  135. package/browser/esm/{qG5zdZZAe6mQIJo32.mjs → RfHd1JATBlcsfLPv.mjs} +5 -5
  136. package/{cdn/assets/CtXoSHbCUKMY-tSJ2.js → browser/esm/SNze-adFJwKuGSQW.mjs} +48 -2
  137. package/browser/esm/UTZcodQydbuMfCOS.mjs +171 -0
  138. package/browser/esm/{BHmYoIIbNW3GdcqV2.mjs → VwGokBaawZfZiV2X.mjs} +1 -1
  139. package/browser/esm/WMYR09ZOR8JbZEnx.mjs +4748 -0
  140. package/browser/esm/{DW72HwfnJtQxzoGa.mjs → ZbGPiRN9j0629JJQ.mjs} +2 -2
  141. package/browser/esm/{CR3jgkduTLczbMjH2.mjs → ZxsFYopF0_WWqw4Q.mjs} +1 -1
  142. package/browser/esm/_MPToH4oMe4rhTdZ.mjs +63 -0
  143. package/{cdn/assets/BHBJtVTiQByD_y9j2.js → browser/esm/_t0Mx-mUFVtmVNkU.mjs} +2 -2
  144. package/browser/esm/{B0HA_dHcr0kKfudQ.mjs → _zRV52yhE4gPf3XI.mjs} +213 -190
  145. package/browser/esm/aUREGNA8H7p4BpMK.mjs +33 -0
  146. package/browser/esm/cwuYkcKwsKkPe3gG.mjs +598 -0
  147. package/browser/esm/{NekeSGoazNCraGNC2.mjs → djM9mJznx8GzVq51.mjs} +16 -15
  148. package/browser/esm/{DuPdSe-EXFTx9dsc2.mjs → f1OJemsiZnbwnds-.mjs} +16 -15
  149. package/{cdn/assets/DQ-0yyFAwoWtxmhV2.js → browser/esm/i0P63Wd0RRlgJotb.mjs} +1 -1
  150. package/browser/esm/{B4vYIE3kSPTxCgpf2.mjs → iC69oOND5T8khIWf.mjs} +18 -17
  151. package/browser/esm/index.mjs +644 -48
  152. package/browser/esm/{7rixDGGrR72lXkMV.mjs → kVBPUUnVyZfb8pf3.mjs} +52 -52
  153. package/{cdn/assets/BCZjYGV8AqIZghBH.js → browser/esm/lqknEt3DTma5Juxs.mjs} +69 -4
  154. package/browser/esm/mZ92wNrHVpYdli1U.mjs +182 -0
  155. package/browser/esm/{DtXC6uPF2LLktqFE.mjs → pKc_RPdZPLAgvNDh.mjs} +2 -2
  156. package/browser/esm/{BPv6Pw1hW-sV5Fya.mjs → pc49xtHdprXZLW2X.mjs} +1 -1
  157. package/browser/esm/px-aQ8dMjiWag_pV.mjs +167 -0
  158. package/browser/esm/qYca4mdySLkACfo1.mjs +37 -0
  159. package/browser/esm/r2Az2Yc4_qj2-sn0.mjs +398 -0
  160. package/browser/esm/{DXWmgQSeh0_HDxZj.mjs → rY-dC3WB558TIbum.mjs} +4 -4
  161. package/browser/esm/rkTVQiYG3wd8oPom.mjs +2452 -0
  162. package/browser/esm/sDVzjXC1mS5rucF5.mjs +2447 -0
  163. package/browser/esm/sxxbiJiCMOW2Eivd.mjs +24952 -0
  164. package/{cdn/assets/CopfZ7Y1Zn_PDNXK.js → browser/esm/vGKTE7yjY8y-XnsW.mjs} +16 -11
  165. package/browser/esm/{CG5v2hAwGR5Ptufn.mjs → x6GcENwqoUVbd60j.mjs} +1 -1
  166. package/{cdn/assets/CGqvy5LwQ4z9J2oD.js → browser/esm/ycmpAs4kQfeh78Pa.mjs} +1 -1
  167. package/browser/esm/ztqpWR65YYMZ3EPk.mjs +811 -0
  168. package/cdn/assets/0vqRTRN0wEzWao1c.js +522 -0
  169. package/cdn/assets/514mXPTuNvdNgw35.js +412 -0
  170. package/{browser/esm/DVQNQmjI2PKkwiOw2.mjs → cdn/assets/7Sg0ht_ZCMJkPurt.js} +89 -87
  171. package/cdn/assets/{mtrwY1hjJeYlmzC-.js → 7i4WSxDsu2ApJJ2_.js} +6 -6
  172. package/cdn/assets/AjMG7Fb9r4Fk7Hsf.js +78 -0
  173. package/cdn/assets/{CJPemkFUzhcAD_qR.js → B00ixdmb8-O5ijEp.js} +1 -1
  174. package/{browser/esm/Bv_96nwOEMHN9Sa02.mjs → cdn/assets/B0Wjc3lwtjKMwnvn.js} +27 -29
  175. package/cdn/assets/B27vTQlxbHhSQJx8.js +24953 -0
  176. package/cdn/assets/B3NWCYKXucbHhOix.js +93 -0
  177. package/{browser/esm/D_t53-8k73CNpV-p.mjs → cdn/assets/BAH_cWcQEIBKWnl6.js} +94 -74
  178. package/cdn/assets/BAdRecWK1maKGOZd.js +142 -0
  179. package/cdn/assets/BB4MW8sSYEXjPvvf.js +64 -0
  180. package/cdn/assets/BBjgqNlHm-ssbSAG.js +47 -0
  181. package/cdn/assets/BI6afPOpgNYkzIWv.js +6609 -0
  182. package/cdn/assets/{CF8m5SqeMaRkGIYM.js → BIsbcP5RXRU2XPfx.js} +2 -2
  183. package/cdn/assets/{Dnx3_xXfRlD6ECfZ.js → BMlPFJ1glExv-70Z.js} +5 -5
  184. package/cdn/assets/{DBL3Qp5jyPrFg7KI.js → BN2d5U1nw7pRtOrn.js} +1 -1
  185. package/cdn/assets/BNsqqoZY7a4N1wWC.js +905 -0
  186. package/cdn/assets/BPrHgyAsm2Htx15h.js +67 -0
  187. package/cdn/assets/{8V-VceXEjpADM8qK.js → BSCja5yvevmKZPBB.js} +1 -1
  188. package/cdn/assets/{CfvrjQGuf7vXiQCB2.js → BWo1N4YbK_zGU0nu.js} +1 -1
  189. package/cdn/assets/B_3Musz0q2MSZ5H-.js +799 -0
  190. package/cdn/assets/Ba8taVvLslFcKS72.js +119 -0
  191. package/cdn/assets/{CBuvbUg67ah_3BOZ.js → BeQ95CzwR65il0CK.js} +2 -2
  192. package/cdn/assets/BelX6bvQPsGuo-x3.js +7 -0
  193. package/cdn/assets/{C8mUyjJ26jsHGl_D.js → Bgbi7BFR3rN5qj51.js} +22 -21
  194. package/cdn/assets/BgyY4zVPZSXljoCZ.js +14 -0
  195. package/{browser/esm/C1ZePT2B182vSnxW2.mjs → cdn/assets/BhkeuRcx8RlLCQ5E.js} +1 -1
  196. package/cdn/assets/BlIZ30huelIxNo6S.js +91 -0
  197. package/cdn/assets/BlPn_DXaEXOPxMxC.js +540 -0
  198. package/cdn/assets/BoFx07POTorOb5g-.js +7393 -0
  199. package/cdn/assets/{-2S675KWulPRlVNb2.js → BpZ7P0CO148rR4zW.js} +23 -22
  200. package/cdn/assets/BsTFy_iJXJYmaO3Z.js +763 -0
  201. package/cdn/assets/{j8nXVEYbO2kPuEYQ.js → Bsn-tUx172sEG2kR.js} +59 -47
  202. package/cdn/assets/{47Yv4X226-93If7L2.js → BtGmrIqU9W1L8zfZ.js} +1 -1
  203. package/cdn/assets/BuYS_ZjSlcvWZ1JC.js +8035 -0
  204. package/cdn/assets/BvlfKrfrDhE9Jw4d.js +598 -0
  205. package/cdn/assets/BwOxnbR61WFJwy0A.js +607 -0
  206. package/cdn/assets/BxqXOiOyI_XiOmvN.js +156 -0
  207. package/cdn/assets/{BqTFwWLbXXJ0Fu-X.js → ByUcqyCNfqi5Mm7w.js} +2 -2
  208. package/{browser/esm/CsufM5aF6VTLKDWM.mjs → cdn/assets/BzbP4jaN13wC9aSi.js} +58 -55
  209. package/{browser/esm/8f9hCbpXTTYEgG312.mjs → cdn/assets/C-0viTjg1dT2F-sk.js} +2 -2
  210. package/cdn/assets/C0CeCYdLWLjySEFe.js +123 -0
  211. package/cdn/assets/{B55nrhIK6gAAu4ZA.js → C32co-XulWTkEKrW.js} +2 -2
  212. package/{browser/esm/BMRav2VAqEzDSp3r2.mjs → cdn/assets/C3r_9RqlWrEmlXZ1.js} +37 -3
  213. package/cdn/assets/{Be4QC65cR8N84rTn2.js → C5EKgE9Owsc_juw-.js} +1 -1
  214. package/cdn/assets/C6INLvBy8kdzFpsX.js +2447 -0
  215. package/cdn/assets/C7fu6LrSMBlHqwUy.js +46 -0
  216. package/{browser/esm/DMX-ZlC_ljcf7oUN.mjs → cdn/assets/C9NyIoUahFiyRCxP.js} +2 -2
  217. package/{browser/esm/BykiUmcpDgSRNQI12.mjs → cdn/assets/CBdNC7BOfc5TewHU.js} +1 -1
  218. package/cdn/assets/{DZDynaLqNeVaDoiH2.js → CCvBdPu7W2ZF6A9J.js} +3 -3
  219. package/cdn/assets/{Chq4BwbjH0sbIkJN2.js → CDAYVaQYywqaxg4O.js} +28 -13
  220. package/cdn/assets/CEYyp6Qrr_IopxpL.js +22597 -0
  221. package/cdn/assets/CFBgmXap8kmumhoz.js +622 -0
  222. package/{browser/esm/BDkVAo0CDCTE04ZJ2.mjs → cdn/assets/CFvKDDbrL3wpXnQH.js} +1 -1
  223. package/cdn/assets/{1guzFZp1LHz_FwfL2.js → CHMqT9DzYKTxPfP6.js} +2 -2
  224. package/cdn/assets/CILUMtSddGz7WXEv.js +240 -0
  225. package/cdn/assets/{DnzDlqizzNkbhJP7.js → CIyaijfp6itgRpFM.js} +95 -87
  226. package/cdn/assets/{DW7JlG-SQEdLYNar2.js → CL6Tgu_rUO6G-fyq.js} +183 -10
  227. package/cdn/assets/CMVTwWHsRgyfSEDM.js +300 -0
  228. package/cdn/assets/{CEN8dYSpN2oew8HH2.js → CMxbiQ5J79M3n1tk.js} +604 -405
  229. package/cdn/assets/COMOqucXq7X1vi0P.js +230 -0
  230. package/cdn/assets/{vcRSnmAqjwKglEkY2.js → CQOyeq_-pg3CM-uA.js} +6 -7
  231. package/cdn/assets/{c6VvwMHfXubjjtyj.js → CRXSrbGNABtzf532.js} +141 -126
  232. package/{browser/esm/hFSDx-LnUOObv-6h2.mjs → cdn/assets/CSEMxasVyGCekxKf.js} +6 -7
  233. package/cdn/assets/CSIZpJClc66_20kP.js +849 -0
  234. package/cdn/assets/CTI-mCJbJzitJZwj.js +25 -0
  235. package/{browser/esm/CdMv3f8Gyxh8q2RR2.mjs → cdn/assets/CTdFZ_I-41Vr6Dy4.js} +1 -1
  236. package/cdn/assets/CTvPIYWTcjwlJeEA.js +237 -0
  237. package/cdn/assets/CU5cKipVT1X8Xz7F.js +156 -0
  238. package/cdn/assets/CVcCUfSRsiZ1-6hs.js +119 -0
  239. package/cdn/assets/CWJzHmEgahdOfNjH.js +527 -0
  240. package/cdn/assets/CZOJogyZqMfUxcXj.js +1141 -0
  241. package/{browser/esm/D4VqLbEWag8lTWzC2.mjs → cdn/assets/CakrxSS_RXtKmcUX.js} +123 -94
  242. package/{browser/esm/Bl6bX86tSq8hfyb2.mjs → cdn/assets/CbTN0q6XnYGJqyEp.js} +2215 -2027
  243. package/cdn/assets/{gspQcUnmlRIwG609.js → Cfg4Dtndwurxv9LM.js} +8 -8
  244. package/cdn/assets/{BhDLR-jtbOOG-tl12.js → ChAKLV5zrGAHAof2.js} +28 -27
  245. package/cdn/assets/{CpnA5TZRkPDt4HnM2.js → CsrTRThObSryov1b.js} +182 -132
  246. package/cdn/assets/Cv5PLuhEmh5IDHjb.js +75 -0
  247. package/cdn/assets/Cw-4uoMuq_m7ziA3.js +36 -0
  248. package/cdn/assets/Cw7AJWd0S2sjRmr6.js +6309 -0
  249. package/cdn/assets/CwqRA5h1u92Cyit-.js +7 -0
  250. package/cdn/assets/Cy00y9b9j17Txyv1.js +466 -0
  251. package/cdn/assets/{CT3G9YRPVfKtHWwf2.js → D-bNmX0QsA8SuT0m.js} +32 -31
  252. package/{browser/esm/Dg5wjQp0fArKXlM3.mjs → cdn/assets/D-yz3V2UC54rwctD.js} +16 -11
  253. package/cdn/assets/D32D_biNXRCZ24vG.js +87 -0
  254. package/cdn/assets/D8DghdqjOtBzO2Wx.js +35 -0
  255. package/cdn/assets/DAE3Kv0Vs0VuBecT.js +32 -0
  256. package/cdn/assets/DCnWyVXikb_8Dat3.js +61 -0
  257. package/cdn/assets/DHH_uKVzQ_kRYO2N.js +57 -0
  258. package/cdn/assets/DHugYwX4_ZyqGn-C.js +1947 -0
  259. package/cdn/assets/DJqj66SnUcx0QmSN.js +15 -0
  260. package/cdn/assets/{R5bs6kCQSZmsCXz-2.js → DNaPo7BQu6hr1fWq.js} +1 -1
  261. package/cdn/assets/DOHh3pUXxMM09UY5.js +3604 -0
  262. package/cdn/assets/DONxZZT2Iwu7psS5.js +27 -0
  263. package/cdn/assets/{BCkXtOM3yKocv7L-.js → DQEjvIGMgEkiaP6J.js} +1 -1
  264. package/{browser/esm/CAPgMrAKg07EREFD.mjs → cdn/assets/DQIRFXG4MveFkK3I.js} +1 -1
  265. package/cdn/assets/DQjxp9lDP9DzP8ah.js +357 -0
  266. package/cdn/assets/{DrUEYcXg6N2D2s1Z.js → DRm1R4uVOkaMfXNI.js} +51 -11
  267. package/cdn/assets/DSXJHEORGmMQX_Mb.js +8391 -0
  268. package/cdn/assets/DSviq1TNoiIAGW7W.js +32 -0
  269. package/{browser/esm/Clfp7SznkOrJoQvL.mjs → cdn/assets/DVpi1vC8ixXvUQG_.js} +3 -3
  270. package/cdn/assets/{BOl4FzJRD7MplCU7.js → DWgp4t9N9u0eWthH.js} +1 -1
  271. package/{browser/esm/B5ZqqASTcBEV5L9K2.mjs → cdn/assets/DXo8mR6t5HGsmTcu.js} +1 -1
  272. package/cdn/assets/DYvBgX17ZerZSHEJ.js +300 -0
  273. package/cdn/assets/DZRm4H75lnEtOG8e.js +260 -0
  274. package/cdn/assets/D_pMOq6FdH4RSBLc.js +3364 -0
  275. package/{browser/esm/EwzqnZl1lTr56hH-2.mjs → cdn/assets/Dc2ZwgbIEgYWwAsF.js} +1 -1
  276. package/cdn/assets/DckmFyHxGX4Y1gOq.js +70 -0
  277. package/{browser/esm/oYdWyqsKo9ejAdVm.mjs → cdn/assets/De2z8LdHaWRFiR5T.js} +179 -202
  278. package/{browser/esm/DQ4o4dG7gWbL1X8F2.mjs → cdn/assets/DeUXRggj8Oz9ru_i.js} +2 -2
  279. package/{browser/esm/DRc_Wi5c7WdKHTVN2.mjs → cdn/assets/DfESVLC8CAi8m8A7.js} +6 -6
  280. package/cdn/assets/DicTo_3G-KZyWDiE.js +1084 -0
  281. package/cdn/assets/{D3G3tI3DVCUF3Gdk2.js → DjdkGy-EI1kSo226.js} +7 -5
  282. package/cdn/assets/DjtXfgbmXjUAoG0y.js +58 -0
  283. package/cdn/assets/DlpgIJxNq2V4gdDq.js +74 -0
  284. package/cdn/assets/{DaBczM5xU9ev5_or.js → Dp-GJXOMz_b8qAxD.js} +2 -2
  285. package/cdn/assets/DqBj-9o7UdXu4qhb.js +33 -0
  286. package/cdn/assets/{DZbR5R1fNikjgqYb.js → DrI_S0A9TQvriTua.js} +1 -1
  287. package/cdn/assets/DuAbY54w5gJpQgss.js +84250 -0
  288. package/cdn/assets/{D6SKy2BtcWkhfiA0.js → Dv8aQFTTaQBJKDDk.js} +2 -5
  289. package/cdn/assets/DviEoeWW0EvDg1hr.js +149 -0
  290. package/cdn/assets/{Cbw0JeJURvQyxIoa.js → DxcRLd7wmBGDgJsA.js} +1 -1
  291. package/cdn/assets/DxisV9_27l_WU-nk.js +21 -0
  292. package/cdn/assets/{Dc0BDcQUGy_WIVFa.js → Dy44qJVkwNseMG-3.js} +1 -1
  293. package/cdn/assets/ENtt4kmaU9mJfVEp.js +236 -0
  294. package/{browser/esm/COA_SZY2x8q6t4BD.mjs → cdn/assets/FO1Jezau486fH4kN.js} +7 -6
  295. package/cdn/assets/FjNOhkR7-JAIaRP6.js +19 -0
  296. package/cdn/assets/{DbEGszSW_J_k96KJ.js → G5z0uVlyF6CLw_PA.js} +179 -202
  297. package/cdn/assets/H-JnJQMcZQbpvjdb.js +2706 -0
  298. package/cdn/assets/J3hutJxqQiHENpIe.js +392 -0
  299. package/cdn/assets/J9i3r1fU0H10b2hX.js +1001 -0
  300. package/cdn/assets/{Gy0CHZTvn4hY-rkx.js → PtGiIWFBYP-ujLmf.js} +1 -1
  301. package/cdn/assets/PzWqv-oXxEuzKdaT.js +484 -0
  302. package/cdn/assets/QJ4AkDD269D1MzmI.js +89 -0
  303. package/cdn/assets/{qG5zdZZAe6mQIJo3.js → RfHd1JATBlcsfLPv.js} +5 -5
  304. package/{browser/esm/CtXoSHbCUKMY-tSJ.mjs → cdn/assets/SNze-adFJwKuGSQW.js} +48 -2
  305. package/cdn/assets/UTZcodQydbuMfCOS.js +171 -0
  306. package/{browser/esm/DzDwSOBdJh_lx_NM.mjs → cdn/assets/VCiu_neIjCTg2NUa.js} +998 -1006
  307. package/cdn/assets/{BHmYoIIbNW3GdcqV.js → VwGokBaawZfZiV2X.js} +1 -1
  308. package/cdn/assets/W1d6GQyySAHrtjEu.js +3563 -0
  309. package/cdn/assets/ZSYS1J3uR7UQuHwZ.js +217 -0
  310. package/cdn/assets/{CR3jgkduTLczbMjH.js → ZxsFYopF0_WWqw4Q.js} +1 -1
  311. package/{browser/esm/BHBJtVTiQByD_y9j.mjs → cdn/assets/_t0Mx-mUFVtmVNkU.js} +2 -2
  312. package/cdn/assets/aHTKr1ijZ6bRi3Zg.js +33 -0
  313. package/cdn/assets/anQDUZhHMDPi1eha.js +812 -0
  314. package/cdn/assets/{tVOVNvOs6ro8FXqa2.js → dn69mDhY7Xcc91kF.js} +20 -19
  315. package/cdn/assets/fm3mUdTDo-STB36M.js +4749 -0
  316. package/cdn/assets/gpQ4FdJMbIScKnS_.js +400 -0
  317. package/cdn/assets/{EjOJX5m8OEL-IjPB.js → hg8WYI0Yy4WPPPoP.js} +28 -27
  318. package/{browser/esm/DQ-0yyFAwoWtxmhV2.mjs → cdn/assets/i0P63Wd0RRlgJotb.js} +1 -1
  319. package/cdn/assets/lWY3TbG2NDscy9He.js +72 -0
  320. package/{browser/esm/BCZjYGV8AqIZghBH.mjs → cdn/assets/lqknEt3DTma5Juxs.js} +69 -4
  321. package/cdn/assets/mK8HcIZyXkOTvL6E.js +2453 -0
  322. package/cdn/assets/{BPv6Pw1hW-sV5Fya.js → pc49xtHdprXZLW2X.js} +1 -1
  323. package/cdn/assets/px-aQ8dMjiWag_pV.js +167 -0
  324. package/cdn/assets/qYca4mdySLkACfo1.js +37 -0
  325. package/{browser/esm/BqwvP0318zI2izeL2.mjs → cdn/assets/w5IQWbJETgHhqMsY.js} +33 -31
  326. package/cdn/assets/wM7DzeOpoEGBVDBe.js +441 -0
  327. package/cdn/assets/{CG5v2hAwGR5Ptufn2.js → x6GcENwqoUVbd60j.js} +1 -1
  328. package/cdn/assets/xlXDq-qoj7eOE6_T.js +5153 -0
  329. package/{browser/esm/CGqvy5LwQ4z9J2oD2.mjs → cdn/assets/ycmpAs4kQfeh78Pa.js} +1 -1
  330. package/cdn/index.js +2 -2
  331. package/package.json +13 -14
  332. package/browser/cjs/1XrWGMP3GmsQOMIX2.cjs +0 -1
  333. package/browser/cjs/2zXD3NPfuQT2KSZq.cjs +0 -7
  334. package/browser/cjs/49_x589Na12sizKK.cjs +0 -1
  335. package/browser/cjs/4nReftSsKWmnRdtf2.cjs +0 -1
  336. package/browser/cjs/507hQYooKKjnRzsZ2.cjs +0 -1
  337. package/browser/cjs/B19QM3SGmPKKwD_o.cjs +0 -1
  338. package/browser/cjs/B4JJfKSI4ppwU8552.cjs +0 -1
  339. package/browser/cjs/B5YBx0GqLor3i0O1.cjs +0 -1
  340. package/browser/cjs/B7_pDFYCVzt-3hUs.cjs +0 -1
  341. package/browser/cjs/B9EI7wviSkHS9ZkH.cjs +0 -1
  342. package/browser/cjs/BAxVLKkxFgI6cXnR.cjs +0 -1
  343. package/browser/cjs/BC2gCQkR1iykfAuC.cjs +0 -1
  344. package/browser/cjs/BEJFcqVMDMKOvs11.cjs +0 -1
  345. package/browser/cjs/BEVqcFGFU6Ri9y8T.cjs +0 -5
  346. package/browser/cjs/BEzaum_kgG4yAOx0.cjs +0 -1
  347. package/browser/cjs/BF-38Z7Z0FZOPl192.cjs +0 -1
  348. package/browser/cjs/BIQZDBQfv3Qm5iC8.cjs +0 -4
  349. package/browser/cjs/BK0SCfN_VZYqBxoQ2.cjs +0 -1
  350. package/browser/cjs/BSCgCfORdZz1Ii5S.cjs +0 -2
  351. package/browser/cjs/BWDfauDHqB6U_2ka2.cjs +0 -1
  352. package/browser/cjs/BZr-IqNS1skh1hr6.cjs +0 -21
  353. package/browser/cjs/B_WV3e3yexp3dKaz.cjs +0 -9
  354. package/browser/cjs/BfzzZ9IR27ZPzj-8.cjs +0 -3
  355. package/browser/cjs/Bgke3PtMSF2Iaen4.cjs +0 -1
  356. package/browser/cjs/BnccBYHCCq9TGFx4.cjs +0 -8
  357. package/browser/cjs/Btc0Nzu40VYOpzLX.cjs +0 -1
  358. package/browser/cjs/BvG8N7G_8CXIAlT-.cjs +0 -1
  359. package/browser/cjs/BwLx9ix5Sq7suAYP2.cjs +0 -1
  360. package/browser/cjs/BziOCn_XEGT4ynN5.cjs +0 -1
  361. package/browser/cjs/C-HOJozu5NgCil1q.cjs +0 -1
  362. package/browser/cjs/C-bW8lKUTFFUVap4.cjs +0 -1
  363. package/browser/cjs/C2oTW2DjZypuqq7x.cjs +0 -1
  364. package/browser/cjs/C2uDl8VIJqh58YF_.cjs +0 -1
  365. package/browser/cjs/C5rQELB0TUeXY6VM.cjs +0 -1
  366. package/browser/cjs/C6yxQPAEgcGWAhYR.cjs +0 -33
  367. package/browser/cjs/C9C-pr-T_ThweQX92.cjs +0 -1
  368. package/browser/cjs/CHFOXPbNUaeZbrXn.cjs +0 -1
  369. package/browser/cjs/CHMgm0vAbEBS1mVW.cjs +0 -1
  370. package/browser/cjs/CJYewYJ5Z3iojl7J.cjs +0 -1
  371. package/browser/cjs/CPcBvw4ZPwHVTUZF.cjs +0 -1
  372. package/browser/cjs/CPgCih_KEqnUZ9Rv.cjs +0 -3
  373. package/browser/cjs/CRx1WvmgBjT8WVyB2.cjs +0 -1
  374. package/browser/cjs/CSNCOmYEOR-iTJ7K.cjs +0 -5
  375. package/browser/cjs/CV4KQsHluMqo1I2Q.cjs +0 -1
  376. package/browser/cjs/CW-b31_-r-_raT8Y2.cjs +0 -1
  377. package/browser/cjs/CXlzsh_WHCOsErJ12.cjs +0 -1
  378. package/browser/cjs/C_7w8EJZpHw8ueuq.cjs +0 -1
  379. package/browser/cjs/C_IEgjM-hSJCv6Gm.cjs +0 -1
  380. package/browser/cjs/CbLXP9WY38wTcGn5.cjs +0 -10
  381. package/browser/cjs/CcneNtiqtKppCa-p.cjs +0 -57
  382. package/browser/cjs/CeF0DZ-k4DB8M47I.cjs +0 -1
  383. package/browser/cjs/Ci8Uu7_b4lwwRLAD2.cjs +0 -1
  384. package/browser/cjs/Clu7XiAsCB48GDXN2.cjs +0 -1
  385. package/browser/cjs/Cm21F18ga8TluA9h.cjs +0 -1
  386. package/browser/cjs/CnZfa45XxA-9Jhmp.cjs +0 -1
  387. package/browser/cjs/CojEXZgX08waZOoq.cjs +0 -1
  388. package/browser/cjs/CpJJh4UnFl1_qFui.cjs +0 -1
  389. package/browser/cjs/CrDTTLE9EvaGDSD4.cjs +0 -88
  390. package/browser/cjs/CrZlUtdX1h2RUnCP.cjs +0 -1
  391. package/browser/cjs/Cty5pi0fwToP1GWe.cjs +0 -7
  392. package/browser/cjs/CvV18ZJgssoHMkdf2.cjs +0 -2
  393. package/browser/cjs/Cy-4IMt-AbR-ifP3.cjs +0 -126
  394. package/browser/cjs/CyGzzWYDy-IniKCq2.cjs +0 -7
  395. package/browser/cjs/CzgwTfy2072Dmt5u.cjs +0 -1
  396. package/browser/cjs/D19RglhKiroWfpQn2.cjs +0 -1
  397. package/browser/cjs/D8-KovdJ0LjxqCe2.cjs +0 -1
  398. package/browser/cjs/DCIlWcGDrp-5PDoA.cjs +0 -1
  399. package/browser/cjs/DDnGLOLTqLFsdUDS2.cjs +0 -1
  400. package/browser/cjs/DEOu_cHJ1FfTA9R_2.cjs +0 -1
  401. package/browser/cjs/DFHxNnJ-lHtv0hIq.cjs +0 -1
  402. package/browser/cjs/DG-AY_xO8RKHtEBE.cjs +0 -2
  403. package/browser/cjs/DG2kqsWRUtVugjay2.cjs +0 -1
  404. package/browser/cjs/DH3WXPfGHwWJW0nH.cjs +0 -1
  405. package/browser/cjs/DIbdDzNf_3S2RYZN.cjs +0 -1
  406. package/browser/cjs/DLYEQZzAGuSAmJsp.cjs +0 -6
  407. package/browser/cjs/DM7-R_ltoLbA9jde2.cjs +0 -1
  408. package/browser/cjs/DNCC-QNp2I7saV-I.cjs +0 -1
  409. package/browser/cjs/DNKyaSruDogoBd2H2.cjs +0 -1
  410. package/browser/cjs/DNy-UU3NKNqQQngF.cjs +0 -1
  411. package/browser/cjs/DPjEO7dwhCFd8DHR2.cjs +0 -2
  412. package/browser/cjs/DYqvGm5rx1DB53p7.cjs +0 -1
  413. package/browser/cjs/DZSvmqU8nRas1uz62.cjs +0 -1
  414. package/browser/cjs/DfMJOaJ0GcUiSn4Q.cjs +0 -1
  415. package/browser/cjs/DiZDRPIgbO3sQ8Vb.cjs +0 -1
  416. package/browser/cjs/DsFZgtSQpC75d1M02.cjs +0 -1
  417. package/browser/cjs/DsIHLUKUrSrYhFHl.cjs +0 -1
  418. package/browser/cjs/Du4jBiFxRIF1OjD4.cjs +0 -1
  419. package/browser/cjs/DvSvfeo9V0Abfd3q2.cjs +0 -1
  420. package/browser/cjs/Dx79LP1-YCQg8B87.cjs +0 -1
  421. package/browser/cjs/DxQkFYAFNZubVdn22.cjs +0 -1
  422. package/browser/cjs/E-IqDztfMb_xdszH.cjs +0 -1
  423. package/browser/cjs/EeOVMRq7TuptFKTc2.cjs +0 -1
  424. package/browser/cjs/ElcoSB--cCpS6i7R2.cjs +0 -1
  425. package/browser/cjs/JfM6P_qoQQTWakZf.cjs +0 -1
  426. package/browser/cjs/KNCocKN9uPR0tvUS.cjs +0 -1
  427. package/browser/cjs/Kr8f1inOTt-MICaP2.cjs +0 -1
  428. package/browser/cjs/Kvn916ebqGc4t6hv2.cjs +0 -1
  429. package/browser/cjs/NcNz8RfT5V889CMT.cjs +0 -10
  430. package/browser/cjs/PM3PrEWG3WHKxaDx.cjs +0 -1
  431. package/browser/cjs/YG320hBA20Dl3HoU2.cjs +0 -1
  432. package/browser/cjs/Ytzw6iUYx5f19wfK.cjs +0 -9
  433. package/browser/cjs/_H5j4dU7HOBYTawU.cjs +0 -1
  434. package/browser/cjs/a0Z-SXs_N71CtqYb2.cjs +0 -1
  435. package/browser/cjs/aONv0Ys3C8xmnaR82.cjs +0 -1
  436. package/browser/cjs/aYuNpndpwcZG5eik2.cjs +0 -20
  437. package/browser/cjs/bGMaev70Zd_NXqLM2.cjs +0 -1
  438. package/browser/cjs/bIaGoYEDSBCrAaB6.cjs +0 -1
  439. package/browser/cjs/bM25C5avKgBAJVfk2.cjs +0 -1
  440. package/browser/cjs/fqTQ_p3ehzUvc1tF2.cjs +0 -1
  441. package/browser/cjs/h3dw1jAp2J5Pu4p32.cjs +0 -1
  442. package/browser/cjs/hzUo76TXMOBqsI3U2.cjs +0 -1
  443. package/browser/cjs/i2VboqjlOcozI9MQ.cjs +0 -12
  444. package/browser/cjs/index.cjs +0 -79
  445. package/browser/cjs/jev6VGWTdgEgm4Yk2.cjs +0 -1
  446. package/browser/cjs/lEQC21-Sk4lwHy2r2.cjs +0 -1
  447. package/browser/cjs/ppSJKdLn646BZOzg.cjs +0 -1
  448. package/browser/cjs/xBcvszV6x7ys-m532.cjs +0 -1
  449. package/browser/cjs/xQ6-wbTw5UzZUM1Y.cjs +0 -1
  450. package/browser/cjs/z_rZE1OHFPpdGBh42.cjs +0 -1
  451. package/browser/esm/-vgNEEXiEad4bltZ.mjs +0 -28782
  452. package/browser/esm/3y_bCend8tkaewDG2.mjs +0 -106
  453. package/browser/esm/At60x9FEPePwPP_J.mjs +0 -51151
  454. package/browser/esm/B1NoGosH2YQh01g7.mjs +0 -105
  455. package/browser/esm/B4h6iO7hQ9lCR7kj.mjs +0 -11273
  456. package/browser/esm/BBtOlJMVlsWorNJH.mjs +0 -824
  457. package/browser/esm/BQDXkeSabbxB5DUB2.mjs +0 -47
  458. package/browser/esm/BUCKq_2lHPd1ndvw.mjs +0 -149
  459. package/browser/esm/BVjXdv_wkL1x_8ZJ2.mjs +0 -1149
  460. package/browser/esm/BX4f6i2WMBMKFVCq.mjs +0 -99
  461. package/browser/esm/BZsx0QHg1RZlM9ZN.mjs +0 -15
  462. package/browser/esm/BhxX7CZWSOlV2Dsz.mjs +0 -224
  463. package/browser/esm/BhzLZRz2N8RxjQ_U.mjs +0 -34
  464. package/browser/esm/BjTf3XA9Swj0ngpH.mjs +0 -7813
  465. package/browser/esm/BkSb_vyWe-AhyEDa.mjs +0 -4423
  466. package/browser/esm/Bp9qFBIcpIGXvMgo.mjs +0 -134
  467. package/browser/esm/C0rS1uBqfsj-gPR8.mjs +0 -152
  468. package/browser/esm/C6CK_4GD9IpxKglV2.mjs +0 -6713
  469. package/browser/esm/CGGJWgWSPZ0aP_C3.mjs +0 -87
  470. package/browser/esm/CGyydD3tRb0ik50l2.mjs +0 -20
  471. package/browser/esm/CPUlpDM6aAzZzCat2.mjs +0 -471
  472. package/browser/esm/CU1d8OvDv5TU6fSd.mjs +0 -2211
  473. package/browser/esm/CY1zykikO58_ADk8.mjs +0 -3188
  474. package/browser/esm/CZWIS7FuqNjbheSw.mjs +0 -235
  475. package/browser/esm/Cb-FUOYcyRSkHG6u2.mjs +0 -238
  476. package/browser/esm/Cc5IufffX4N-8QpE.mjs +0 -6104
  477. package/browser/esm/Cd8HXAJlflkkTXxc.mjs +0 -53
  478. package/browser/esm/CfuhUkrvOq11d9FR.mjs +0 -44
  479. package/browser/esm/Ckl3FLCOeqw7yhkP2.mjs +0 -82
  480. package/browser/esm/CpjX81WsWJbXMUoT.mjs +0 -3655
  481. package/browser/esm/D9-wpGVbTS9rRpxx.mjs +0 -24
  482. package/browser/esm/DDOO4tcrO4OfMUDe.mjs +0 -25
  483. package/browser/esm/DDUYQ8FPeh1TJU24.mjs +0 -538
  484. package/browser/esm/DFdU1DsC1lXOrejZ.mjs +0 -8260
  485. package/browser/esm/DMLwXmjo28k_iNEU.mjs +0 -4740
  486. package/browser/esm/DVJd6McdAG5udItH.mjs +0 -27
  487. package/browser/esm/D_zNx76HGunFi7xJ.mjs +0 -509
  488. package/browser/esm/DfRGH6mEtIVDWEYN2.mjs +0 -304
  489. package/browser/esm/DnuaqN0xfgqzl8qG.mjs +0 -2687
  490. package/browser/esm/fJ1McMt7xzRA_lUX.mjs +0 -383
  491. package/browser/esm/nguMxPB9LKexKBRX.mjs +0 -219
  492. package/browser/esm/qzhFT2j-mpQEQnKs.mjs +0 -16386
  493. package/cdn/assets/2CuCH0wi9XPgVzE42.js +0 -44
  494. package/cdn/assets/2UHIeioUPXrwtZy-2.js +0 -83
  495. package/cdn/assets/BAhvL7M7ZcgZ8eDc2.js +0 -48
  496. package/cdn/assets/BJEpPEyFWtLzMIq-2.js +0 -3655
  497. package/cdn/assets/BKEzd89UphJ8q1pp2.js +0 -2211
  498. package/cdn/assets/BM7OqAUEUk-up7_82.js +0 -134
  499. package/cdn/assets/BNuoKAzs4zkxSocG2.js +0 -44
  500. package/cdn/assets/BNybEGR813e3aNIv.js +0 -8263
  501. package/cdn/assets/BU6uQhQhpaLElTT82.js +0 -225
  502. package/cdn/assets/BVgTMDEoPgsWFmku.js +0 -510
  503. package/cdn/assets/BVjXdv_wkL1x_8ZJ2.js +0 -1149
  504. package/cdn/assets/BWlMK76Aj2d4ygsH.js +0 -538
  505. package/cdn/assets/BZsx0QHg1RZlM9ZN2.js +0 -15
  506. package/cdn/assets/BixsQGDDf3Iv_PtW2.js +0 -4740
  507. package/cdn/assets/Bl6C6xWT8E6b7OwJ2.js +0 -239
  508. package/cdn/assets/BzUU8y1IFjREzgog2.js +0 -107
  509. package/cdn/assets/CGyydD3tRb0ik50l.js +0 -20
  510. package/cdn/assets/CH0of3GZTzHviuQV.js +0 -24
  511. package/cdn/assets/CH0of3GZTzHviuQV2.js +0 -24
  512. package/cdn/assets/CHttngK66Ido5dWW.js +0 -106
  513. package/cdn/assets/Ce5A_D4YBgi_s2KF.js +0 -176
  514. package/cdn/assets/CpYlf4dXa_V2v-iS2.js +0 -3188
  515. package/cdn/assets/Crkvq5j5KIa6eTLI2.js +0 -51151
  516. package/cdn/assets/Cv-KXN9kl0UeMezQ.js +0 -824
  517. package/cdn/assets/CvtkpvGzCHhNuwTm.js +0 -16386
  518. package/cdn/assets/D-fJXasEYyfRUcj2.js +0 -6104
  519. package/cdn/assets/D1MA2ed2cLMt7hV9.js +0 -236
  520. package/cdn/assets/D9gETGi23d14kT7u2.js +0 -99
  521. package/cdn/assets/D9joTG0Z2zdWHAEa2.js +0 -4423
  522. package/cdn/assets/DC9obE_EVmxtvXCf.js +0 -11275
  523. package/cdn/assets/DCnA2-zB7W_QB-tD2.js +0 -2199
  524. package/cdn/assets/DDNivpFWzQ3AIJia.js +0 -2687
  525. package/cdn/assets/DDOO4tcrO4OfMUDe.js +0 -25
  526. package/cdn/assets/DEUY_zuVwmptMX4l.js +0 -150
  527. package/cdn/assets/DIQf1pX-j-dWQu_e.js +0 -472
  528. package/cdn/assets/DJwQ9abZkyFO9Doy.js +0 -7404
  529. package/cdn/assets/DTCtbG90ip7Z7LaG.js +0 -220
  530. package/cdn/assets/DVS_5oDniuAFH3vT2.js +0 -6715
  531. package/cdn/assets/D_HeH7AJqWoxehn52.js +0 -53
  532. package/cdn/assets/DfRGH6mEtIVDWEYN.js +0 -304
  533. package/cdn/assets/DvItgGbf8IOWPyxd.js +0 -28784
  534. package/cdn/assets/DvlpP6sUZ9Qzl9s22.js +0 -616
  535. package/cdn/assets/WLUhtyUNK5QJ7Pff.js +0 -34
  536. package/cdn/assets/c7aIqKLOO4pvUsV12.js +0 -220
  537. package/cdn/assets/mtI43hWjdp4E3Z_-.js +0 -152
  538. package/cdn/assets/nmR_PgTW7GrlbHHZ.js +0 -27
  539. package/cdn/assets/vTCuFafvRlSaT9wy.js +0 -87
@@ -1,2687 +0,0 @@
1
- /**
2
- * @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.8.0-beta.1
3
- *
4
- * (C) 2026-present SheetXL Inc. & Michael T. Ford
5
- * License: The license can be found at https://www.sheetxl.com/license.
6
- */
7
- import { d as e, o as t } from "./D_t53-8k73CNpV-p2.js";
8
- import { A as n, C as r, F as i, l as a, s as o } from "./CEN8dYSpN2oew8HH2.js";
9
- import { $ as s, A as c, B as l, G as u, nn as ee, s as d } from "./Crkvq5j5KIa6eTLI2.js";
10
- import { m as f } from "./CpYlf4dXa_V2v-iS2.js";
11
- import { A as p, B as m, D as h, H as g, K as _, L as v, P as te, R as ne, S as re, U as ie, V as ae, _ as oe, a as se, b as y, d as b, g as x, i as ce, j as le, k as ue, m as S, o as C, p as w, r as T, w as de, x as fe, y as pe, z as me } from "./BixsQGDDf3Iv_PtW2.js";
12
- import { t as E } from "./1guzFZp1LHz_FwfL2.js";
13
- import { a as D, c as O, d as he, l as ge, n as _e, o as ve, p as ye, u as be } from "./D9gETGi23d14kT7u2.js";
14
- var k = /* @__PURE__ */ new Uint8Array(), xe = class e {
15
- constructor(e, t, n) {
16
- this.buffers = /* @__PURE__ */ new Map(), this.zip = e, this.entries = t, this.rawBuffer = n;
17
- }
18
- static normalize(e) {
19
- return e.startsWith("/") ? e.slice(1) : e;
20
- }
21
- static async create(t) {
22
- let n = t instanceof Blob ? k : t instanceof Uint8Array ? t : new Uint8Array(t), r = new ue(t instanceof Blob ? new m(t) : new ie(n)), i = /* @__PURE__ */ new Map();
23
- for (let e of await r.getEntries()) e.directory || i.set(e.filename, e);
24
- return new e(r, i, n);
25
- }
26
- getNames() {
27
- return [...this.entries.keys()];
28
- }
29
- has(t) {
30
- return this.entries.has(e.normalize(t));
31
- }
32
- uncompressedSize(t) {
33
- return this.entries.get(e.normalize(t))?.uncompressedSize ?? 0;
34
- }
35
- async getBuffer(t) {
36
- let n = e.normalize(t), r = this.buffers.get(n);
37
- if (r) return r;
38
- let i = this.entries.get(n);
39
- if (!i) return null;
40
- let a = await i.getData(new y());
41
- return this.buffers.set(n, a), a;
42
- }
43
- async prefetch(e) {
44
- let t = [];
45
- for (let [n, r] of this.entries) !this.buffers.has(n) && e(n, r) && t.push(r.getData(new y()).then((e) => {
46
- this.buffers.set(n, e);
47
- }));
48
- await Promise.all(t);
49
- }
50
- getEntry(t) {
51
- return this.buffers.get(e.normalize(t)) ?? null;
52
- }
53
- async getTextStream(t, n) {
54
- let r = this.entries.get(e.normalize(t));
55
- if (!r) return null;
56
- let i = new TransformStream();
57
- r.getData(i.writable).catch(() => {});
58
- let a = i.readable.getReader(), o = new TextDecoder("utf-8");
59
- return new ReadableStream({ async pull(e) {
60
- let { value: t, done: r } = await a.read();
61
- if (r) {
62
- let t = o.decode();
63
- t && e.enqueue(t), e.close();
64
- return;
65
- }
66
- n?.(t.byteLength);
67
- let i = o.decode(t, { stream: !0 });
68
- i && e.enqueue(i);
69
- } }).getReader();
70
- }
71
- getRawEntry(t) {
72
- let n = this.entries.get(e.normalize(t));
73
- if (!n || n.encrypted) return null;
74
- let r = n.offset;
75
- if (r + 30 > this.rawBuffer.byteLength) return null;
76
- let i = new DataView(this.rawBuffer.buffer, this.rawBuffer.byteOffset + r, 30);
77
- if (i.getUint32(0, !0) !== 67324752) return null;
78
- let a = r + 30 + i.getUint16(26, !0) + i.getUint16(28, !0), o = a + n.compressedSize;
79
- return o > this.rawBuffer.byteLength ? null : {
80
- data: this.rawBuffer.subarray(a, o),
81
- compressionMethod: n.compressionMethod,
82
- signature: n.signature
83
- };
84
- }
85
- async close() {
86
- await this.zip.close();
87
- }
88
- }, Se = class {
89
- constructor(e) {
90
- this._sink = e, this._samples = [], this._t0 = A(), this._tPrev = this._t0, this._heapPrev = j();
91
- }
92
- mark(e) {
93
- let t = A(), n = j(), r = {
94
- label: e,
95
- tMs: t - this._t0,
96
- dtMs: t - this._tPrev,
97
- heapBytes: n,
98
- dHeapBytes: n !== void 0 && this._heapPrev !== void 0 ? n - this._heapPrev : void 0,
99
- rssBytes: Ce()
100
- };
101
- this._tPrev = t, this._heapPrev = n, this._samples.push(r), this._sink?.(r);
102
- }
103
- samples() {
104
- return this._samples;
105
- }
106
- toTable() {
107
- return this._samples.map((e) => ({
108
- phase: e.label,
109
- tMs: Math.round(e.tMs),
110
- dtMs: Math.round(e.dtMs),
111
- heapMB: e.heapBytes === void 0 ? "—" : we(e.heapBytes / 1048576),
112
- dHeapMB: e.dHeapBytes === void 0 ? "—" : we(e.dHeapBytes / 1048576),
113
- rssMB: e.rssBytes === void 0 ? "—" : we(e.rssBytes / 1048576)
114
- }));
115
- }
116
- }, A = typeof performance == "object" && typeof performance.now == "function" ? () => performance.now() : () => Date.now();
117
- function j() {
118
- let e = typeof performance == "object" ? performance.memory : void 0;
119
- if (e && typeof e.usedJSHeapSize == "number") return e.usedJSHeapSize;
120
- let t = globalThis.process;
121
- return typeof t == "object" && typeof t.memoryUsage == "function" ? t.memoryUsage().heapUsed : void 0;
122
- }
123
- function Ce() {
124
- let e = globalThis.process;
125
- if (typeof e == "object" && typeof e.memoryUsage == "function") return e.memoryUsage().rss;
126
- }
127
- function we(e) {
128
- return Math.round(10 * e) / 10;
129
- }
130
- var M = ":A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿", N = `-${M}.0-9·̀-ͯ‿-⁀`, Te = (RegExp(`^[${M}]$`, "u"), RegExp(`^[${N}]$`, "u"), RegExp(`^[${M}][${N}]*$`, "u")), Ee = (RegExp(`^[${N}]+$`, "u"), [
131
- 32,
132
- 10,
133
- 13,
134
- 9
135
- ]);
136
- function P(e) {
137
- return e >= 65 && e <= 90 || e >= 97 && e <= 122 || e === 58 || e === 95 || e === 8204 || e === 8205 || e >= 192 && e <= 214 || e >= 216 && e <= 246 || e >= 248 && e <= 767 || e >= 880 && e <= 893 || e >= 895 && e <= 8191 || e >= 8304 && e <= 8591 || e >= 11264 && e <= 12271 || e >= 12289 && e <= 55295 || e >= 63744 && e <= 64975 || e >= 65008 && e <= 65533 || e >= 65536 && e <= 983039;
138
- }
139
- var F = ":A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿", I = `-${F}.0-9·̀-ͯ‿-⁀`;
140
- RegExp(`^[${F}]$`, "u"), RegExp(`^[${I}]$`, "u"), RegExp(`^[${F}][${I}]*$`, "u"), RegExp(`^[${I}]+$`, "u");
141
- var De = "A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿", Oe = `-${De}.0-9·̀-ͯ‿-⁀`, L = (RegExp(`^[${De}]$`, "u"), RegExp(`^[${Oe}]$`, "u"), RegExp(`^[${De}][${Oe}]*$`, "u"));
142
- function ke(e) {
143
- return e >= 65 && e <= 90 || e === 95 || e >= 97 && e <= 122 || e >= 192 && e <= 214 || e >= 216 && e <= 246 || e >= 248 && e <= 767 || e >= 880 && e <= 893 || e >= 895 && e <= 8191 || e >= 8204 && e <= 8205 || e >= 8304 && e <= 8591 || e >= 11264 && e <= 12271 || e >= 12289 && e <= 55295 || e >= 63744 && e <= 64975 || e >= 65008 && e <= 65533 || e >= 65536 && e <= 983039;
144
- }
145
- var R, Ae, z = function(e) {
146
- return e === 32 || e === 10 || e === 13 || e === 9;
147
- }, je = function(e) {
148
- return e >= 32 && e <= 55295 || e === 10 || e === 13 || e === 9 || e >= 57344 && e <= 65533 || e >= 65536 && e <= 1114111;
149
- }, Me = P, B = function(e) {
150
- return P(e) || e >= 48 && e <= 57 || e === 45 || e === 46 || e === 183 || e >= 768 && e <= 879 || e >= 8255 && e <= 8256;
151
- }, Ne = Ee, V = Te, Pe = function(e) {
152
- return e >= 1 && e <= 55295 || e >= 57344 && e <= 65533 || e >= 65536 && e <= 1114111;
153
- }, Fe = ke, Ie = function(e) {
154
- return ke(e) || e === 45 || e === 46 || e >= 48 && e <= 57 || e === 183 || e >= 768 && e <= 879 || e >= 8255 && e <= 8256;
155
- }, Le = L, Re = "http://www.w3.org/XML/1998/namespace", ze = "http://www.w3.org/2000/xmlns/", Be = {
156
- __proto__: null,
157
- xml: Re,
158
- xmlns: ze
159
- }, Ve = {
160
- __proto__: null,
161
- amp: "&",
162
- gt: ">",
163
- lt: "<",
164
- quot: "\"",
165
- apos: "'"
166
- }, H = -1, U = -2, W = 13, He = 33, G = 10, K = 60, Ue = 61, q = 62, J = 63, We = 93, Y = (e) => e === 34 || e === 39, Ge = [34, 39], Ke = [
167
- ...Ge,
168
- 91,
169
- q
170
- ], qe = [
171
- ...Ge,
172
- K,
173
- We
174
- ], Je = [
175
- Ue,
176
- J,
177
- ...Ne
178
- ], Ye = [
179
- ...Ne,
180
- q,
181
- 38,
182
- K
183
- ];
184
- function Xe(e, t, n) {
185
- switch (t) {
186
- case "xml":
187
- n !== Re && e.fail(`xml prefix must be bound to ${Re}.`);
188
- break;
189
- case "xmlns": n !== ze && e.fail(`xmlns prefix must be bound to ${ze}.`);
190
- }
191
- switch (n) {
192
- case ze:
193
- e.fail(t === "" ? `the default namespace may not be set to ${n}.` : `may not assign a prefix (even "xmlns") to the URI ${ze}.`);
194
- break;
195
- case Re: switch (t) {
196
- case "xml": break;
197
- case "":
198
- e.fail(`the default namespace may not be set to ${n}.`);
199
- break;
200
- default: e.fail("may not assign the xml namespace to another prefix.");
201
- }
202
- }
203
- }
204
- var Ze = (e) => Le.test(e), Qe = (e) => V.test(e), $e = {
205
- xmldecl: "xmlDeclHandler",
206
- text: "textHandler",
207
- processinginstruction: "piHandler",
208
- doctype: "doctypeHandler",
209
- comment: "commentHandler",
210
- opentagstart: "openTagStartHandler",
211
- attribute: "attributeHandler",
212
- opentag: "openTagHandler",
213
- closetag: "closeTagHandler",
214
- cdata: "cdataHandler",
215
- error: "errorHandler",
216
- end: "endHandler",
217
- ready: "readyHandler"
218
- }, et = class {
219
- get closed() {
220
- return this._closed;
221
- }
222
- constructor(e) {
223
- this.i = 0, this.prevI = 0, this.opt = e ?? {}, this.fragmentOpt = !!this.opt.fragment;
224
- let t = this.xmlnsOpt = !!this.opt.xmlns;
225
- if (this.trackPosition = !1 !== this.opt.position, this.fileName = this.opt.fileName, t) {
226
- this.nameStartCheck = Fe, this.nameCheck = Ie, this.isName = Ze, this.processAttribs = this.processAttribsNS, this.pushAttrib = this.pushAttribNS, this.ns = {
227
- __proto__: null,
228
- ...Be
229
- };
230
- let e = this.opt.additionalNamespaces;
231
- e != null && (function(e, t) {
232
- for (let n of Object.keys(t)) Xe(e, n, t[n]);
233
- }(this, e), Object.assign(this.ns, e));
234
- } else this.nameStartCheck = Me, this.nameCheck = B, this.isName = Qe, this.processAttribs = this.processAttribsPlain, this.pushAttrib = this.pushAttribPlain;
235
- this.stateTable = [
236
- this.sBegin,
237
- this.sBeginWhitespace,
238
- this.sDoctype,
239
- this.sDoctypeQuote,
240
- this.sDTD,
241
- this.sDTDQuoted,
242
- this.sDTDOpenWaka,
243
- this.sDTDOpenWakaBang,
244
- this.sDTDComment,
245
- this.sDTDCommentEnding,
246
- this.sDTDCommentEnded,
247
- this.sDTDPI,
248
- this.sDTDPIEnding,
249
- this.sText,
250
- this.sEntity,
251
- this.sOpenWaka,
252
- this.sOpenWakaBang,
253
- this.sComment,
254
- this.sCommentEnding,
255
- this.sCommentEnded,
256
- this.sCData,
257
- this.sCDataEnding,
258
- this.sCDataEnding2,
259
- this.sPIFirstChar,
260
- this.sPIRest,
261
- this.sPIBody,
262
- this.sPIEnding,
263
- this.sXMLDeclNameStart,
264
- this.sXMLDeclName,
265
- this.sXMLDeclEq,
266
- this.sXMLDeclValueStart,
267
- this.sXMLDeclValue,
268
- this.sXMLDeclSeparator,
269
- this.sXMLDeclEnding,
270
- this.sOpenTag,
271
- this.sOpenTagSlash,
272
- this.sAttrib,
273
- this.sAttribName,
274
- this.sAttribNameSawWhite,
275
- this.sAttribValue,
276
- this.sAttribValueQuoted,
277
- this.sAttribValueClosed,
278
- this.sAttribValueUnquoted,
279
- this.sCloseTag,
280
- this.sCloseTagSawWhite
281
- ], this._init();
282
- }
283
- _init() {
284
- this.openWakaBang = "", this.text = "", this.name = "", this.piTarget = "", this.entity = "", this.q = null, this.tags = [], this.tag = null, this.topNS = null, this.chunk = "", this.chunkPosition = 0, this.i = 0, this.prevI = 0, this.carriedFromPrevious = void 0, this.forbiddenState = 0, this.attribList = [];
285
- let { fragmentOpt: e } = this;
286
- this.state = e ? W : 0, this.reportedTextBeforeRoot = this.reportedTextAfterRoot = this.closedRoot = this.sawRoot = e, this.xmlDeclPossible = !e, this.xmlDeclExpects = ["version"], this.entityReturnState = void 0;
287
- let { defaultXMLVersion: t } = this.opt;
288
- if (t === void 0) {
289
- if (!0 === this.opt.forceXMLVersion) throw Error("forceXMLVersion set but defaultXMLVersion is not set");
290
- t = "1.0";
291
- }
292
- this.setXMLVersion(t), this.positionAtNewLine = 0, this.doctype = !1, this._closed = !1, this.xmlDecl = {
293
- version: void 0,
294
- encoding: void 0,
295
- standalone: void 0
296
- }, this.line = 1, this.column = 0, this.ENTITIES = Object.create(Ve), this.readyHandler?.();
297
- }
298
- get position() {
299
- return this.chunkPosition + this.i;
300
- }
301
- get columnIndex() {
302
- return this.position - this.positionAtNewLine;
303
- }
304
- on(e, t) {
305
- this[$e[e]] = t;
306
- }
307
- off(e) {
308
- this[$e[e]] = void 0;
309
- }
310
- makeError(e) {
311
- let t = this.fileName ?? "";
312
- return this.trackPosition && (t.length > 0 && (t += ":"), t += `${this.line}:${this.column}`), t.length > 0 && (t += ": "), Error(t + e);
313
- }
314
- fail(e) {
315
- let t = this.makeError(e), n = this.errorHandler;
316
- if (n === void 0) throw t;
317
- return n(t), this;
318
- }
319
- write(e) {
320
- if (this.closed) return this.fail("cannot write after close.");
321
- let t = !1;
322
- e === null ? (t = !0, e = "") : typeof e == "object" && (e = e.toString()), this.carriedFromPrevious !== void 0 && (e = `${this.carriedFromPrevious}${e}`, this.carriedFromPrevious = void 0);
323
- let n = e.length, r = e.charCodeAt(n - 1);
324
- !t && (r === 13 || r >= 55296 && r <= 56319) && (this.carriedFromPrevious = e[n - 1], n--, e = e.slice(0, n));
325
- let { stateTable: i } = this;
326
- for (this.chunk = e, this.i = 0; this.i < n;) i[this.state].call(this);
327
- return this.chunkPosition += n, t ? this.end() : this;
328
- }
329
- close() {
330
- return this.write(null);
331
- }
332
- getCode10() {
333
- let e = this.chunk, t = this.i;
334
- if (this.prevI = t, this.i++, t >= e.length) return H;
335
- let n = e.charCodeAt(t);
336
- if (this.column++, n < 55296) {
337
- if (n >= 32 || n === 9) return n;
338
- switch (n) {
339
- case G: return this.line++, this.column = 0, this.positionAtNewLine = this.position, G;
340
- case 13: return e.charCodeAt(t + 1) === G && (this.i = t + 2), this.line++, this.column = 0, this.positionAtNewLine = this.position, U;
341
- default: return this.fail("disallowed character."), n;
342
- }
343
- }
344
- if (n > 56319) return n >= 57344 && n <= 65533 || this.fail("disallowed character."), n;
345
- let r = 65536 + 1024 * (n - 55296) + (e.charCodeAt(t + 1) - 56320);
346
- return this.i = t + 2, r > 1114111 && this.fail("disallowed character."), r;
347
- }
348
- getCode11() {
349
- let { chunk: e, i: t } = this;
350
- if (this.prevI = t, this.i = t + 1, t >= e.length) return H;
351
- let n = e.charCodeAt(t);
352
- if (this.column++, n < 55296) {
353
- if (n > 31 && n < 127 || n > 159 && n !== 8232 || n === 9) return n;
354
- switch (n) {
355
- case G: return this.line++, this.column = 0, this.positionAtNewLine = this.position, G;
356
- case 13: {
357
- let n = e.charCodeAt(t + 1);
358
- n !== G && n !== 133 || (this.i = t + 2);
359
- }
360
- case 133:
361
- case 8232: return this.line++, this.column = 0, this.positionAtNewLine = this.position, U;
362
- default: return this.fail("disallowed character."), n;
363
- }
364
- }
365
- if (n > 56319) return n >= 57344 && n <= 65533 || this.fail("disallowed character."), n;
366
- let r = 65536 + 1024 * (n - 55296) + (e.charCodeAt(t + 1) - 56320);
367
- return this.i = t + 2, r > 1114111 && this.fail("disallowed character."), r;
368
- }
369
- getCodeNorm() {
370
- let e = this.getCode();
371
- return e === U ? G : e;
372
- }
373
- unGet() {
374
- this.i = this.prevI, this.column--;
375
- }
376
- captureTo(e) {
377
- let { i: t } = this, { chunk: n } = this;
378
- for (;;) {
379
- let r = this.getCode(), i = r === U, a = i ? G : r;
380
- if (a === H || e.includes(a)) return this.text += n.slice(t, this.prevI), a;
381
- i && (this.text += `${n.slice(t, this.prevI)}\n`, t = this.i);
382
- }
383
- }
384
- captureToChar(e) {
385
- let { i: t } = this, { chunk: n } = this;
386
- for (;;) {
387
- let r = this.getCode();
388
- switch (r) {
389
- case U:
390
- this.text += `${n.slice(t, this.prevI)}\n`, t = this.i, r = G;
391
- break;
392
- case H: return this.text += n.slice(t), !1;
393
- }
394
- if (r === e) return this.text += n.slice(t, this.prevI), !0;
395
- }
396
- }
397
- captureNameChars() {
398
- let { chunk: e, i: t } = this;
399
- for (;;) {
400
- let n = this.getCode();
401
- if (n === H) return this.name += e.slice(t), H;
402
- if (!B(n)) return this.name += e.slice(t, this.prevI), n === U ? G : n;
403
- }
404
- }
405
- skipSpaces() {
406
- for (;;) {
407
- let e = this.getCodeNorm();
408
- if (e === H || !z(e)) return e;
409
- }
410
- }
411
- setXMLVersion(e) {
412
- this.currentXMLVersion = e, e === "1.0" ? (this.isChar = je, this.getCode = this.getCode10) : (this.isChar = Pe, this.getCode = this.getCode11);
413
- }
414
- sBegin() {
415
- this.chunk.charCodeAt(0) === 65279 && (this.i++, this.column++), this.state = 1;
416
- }
417
- sBeginWhitespace() {
418
- let e = this.i, t = this.skipSpaces();
419
- switch (this.prevI !== e && (this.xmlDeclPossible = !1), t) {
420
- case K:
421
- if (this.state = 15, this.text.length !== 0) throw Error("no-empty text at start");
422
- break;
423
- case H: break;
424
- default: this.unGet(), this.state = W, this.xmlDeclPossible = !1;
425
- }
426
- }
427
- sDoctype() {
428
- let e = this.captureTo(Ke);
429
- switch (e) {
430
- case q:
431
- this.doctypeHandler?.(this.text), this.text = "", this.state = W, this.doctype = !0;
432
- break;
433
- case H: break;
434
- default: this.text += String.fromCodePoint(e), e === 91 ? this.state = 4 : Y(e) && (this.state = 3, this.q = e);
435
- }
436
- }
437
- sDoctypeQuote() {
438
- let e = this.q;
439
- this.captureToChar(e) && (this.text += String.fromCodePoint(e), this.q = null, this.state = 2);
440
- }
441
- sDTD() {
442
- let e = this.captureTo(qe);
443
- e !== H && (this.text += String.fromCodePoint(e), e === We ? this.state = 2 : e === K ? this.state = 6 : Y(e) && (this.state = 5, this.q = e));
444
- }
445
- sDTDQuoted() {
446
- let e = this.q;
447
- this.captureToChar(e) && (this.text += String.fromCodePoint(e), this.state = 4, this.q = null);
448
- }
449
- sDTDOpenWaka() {
450
- let e = this.getCodeNorm();
451
- switch (this.text += String.fromCodePoint(e), e) {
452
- case 33:
453
- this.state = 7, this.openWakaBang = "";
454
- break;
455
- case J:
456
- this.state = 11;
457
- break;
458
- default: this.state = 4;
459
- }
460
- }
461
- sDTDOpenWakaBang() {
462
- let e = String.fromCodePoint(this.getCodeNorm()), t = this.openWakaBang += e;
463
- this.text += e, t !== "-" && (this.state = t === "--" ? 8 : 4, this.openWakaBang = "");
464
- }
465
- sDTDComment() {
466
- this.captureToChar(45) && (this.text += "-", this.state = 9);
467
- }
468
- sDTDCommentEnding() {
469
- let e = this.getCodeNorm();
470
- this.text += String.fromCodePoint(e), this.state = e === 45 ? 10 : 8;
471
- }
472
- sDTDCommentEnded() {
473
- let e = this.getCodeNorm();
474
- this.text += String.fromCodePoint(e), e === q ? this.state = 4 : (this.fail("malformed comment."), this.state = 8);
475
- }
476
- sDTDPI() {
477
- this.captureToChar(J) && (this.text += "?", this.state = 12);
478
- }
479
- sDTDPIEnding() {
480
- let e = this.getCodeNorm();
481
- this.text += String.fromCodePoint(e), e === q && (this.state = 4);
482
- }
483
- sText() {
484
- this.tags.length === 0 ? this.handleTextOutsideRoot() : this.handleTextInRoot();
485
- }
486
- sEntity() {
487
- let { i: e } = this, { chunk: t } = this;
488
- t: for (;;) switch (this.getCode()) {
489
- case U:
490
- this.entity += `${t.slice(e, this.prevI)}\n`, e = this.i;
491
- break;
492
- case 59: {
493
- let n, { entityReturnState: r } = this, i = this.entity + t.slice(e, this.prevI);
494
- this.state = r, i === "" ? (this.fail("empty entity name."), n = "&;") : (n = this.parseEntity(i), this.entity = ""), r === W && this.textHandler === void 0 || (this.text += n);
495
- break t;
496
- }
497
- case H:
498
- this.entity += t.slice(e);
499
- break t;
500
- }
501
- }
502
- sOpenWaka() {
503
- let e = this.getCode();
504
- if (Me(e)) this.state = 34, this.unGet(), this.xmlDeclPossible = !1;
505
- else switch (e) {
506
- case 47:
507
- this.state = 43, this.xmlDeclPossible = !1;
508
- break;
509
- case 33:
510
- this.state = 16, this.openWakaBang = "", this.xmlDeclPossible = !1;
511
- break;
512
- case J:
513
- this.state = 23;
514
- break;
515
- default: this.fail("disallowed character in tag name"), this.state = W, this.xmlDeclPossible = !1;
516
- }
517
- }
518
- sOpenWakaBang() {
519
- switch (this.openWakaBang += String.fromCodePoint(this.getCodeNorm()), this.openWakaBang) {
520
- case "[CDATA[":
521
- this.sawRoot || this.reportedTextBeforeRoot || (this.fail("text data outside of root node."), this.reportedTextBeforeRoot = !0), this.closedRoot && !this.reportedTextAfterRoot && (this.fail("text data outside of root node."), this.reportedTextAfterRoot = !0), this.state = 20, this.openWakaBang = "";
522
- break;
523
- case "--":
524
- this.state = 17, this.openWakaBang = "";
525
- break;
526
- case "DOCTYPE":
527
- this.state = 2, (this.doctype || this.sawRoot) && this.fail("inappropriately located doctype declaration."), this.openWakaBang = "";
528
- break;
529
- default: this.openWakaBang.length >= 7 && this.fail("incorrect syntax.");
530
- }
531
- }
532
- sComment() {
533
- this.captureToChar(45) && (this.state = 18);
534
- }
535
- sCommentEnding() {
536
- let e = this.getCodeNorm();
537
- e === 45 ? (this.state = 19, this.commentHandler?.(this.text), this.text = "") : (this.text += `-${String.fromCodePoint(e)}`, this.state = 17);
538
- }
539
- sCommentEnded() {
540
- let e = this.getCodeNorm();
541
- e === q ? this.state = W : (this.fail("malformed comment."), this.text += `--${String.fromCodePoint(e)}`, this.state = 17);
542
- }
543
- sCData() {
544
- this.captureToChar(We) && (this.state = 21);
545
- }
546
- sCDataEnding() {
547
- let e = this.getCodeNorm();
548
- e === We ? this.state = 22 : (this.text += `]${String.fromCodePoint(e)}`, this.state = 20);
549
- }
550
- sCDataEnding2() {
551
- let e = this.getCodeNorm();
552
- switch (e) {
553
- case q:
554
- this.cdataHandler?.(this.text), this.text = "", this.state = W;
555
- break;
556
- case We:
557
- this.text += "]";
558
- break;
559
- default: this.text += `]]${String.fromCodePoint(e)}`, this.state = 20;
560
- }
561
- }
562
- sPIFirstChar() {
563
- let e = this.getCodeNorm();
564
- this.nameStartCheck(e) ? (this.piTarget += String.fromCodePoint(e), this.state = 24) : e === J || z(e) ? (this.fail("processing instruction without a target."), this.state = e === J ? 26 : 25) : (this.fail("disallowed character in processing instruction name."), this.piTarget += String.fromCodePoint(e), this.state = 24);
565
- }
566
- sPIRest() {
567
- let { chunk: e, i: t } = this;
568
- for (;;) {
569
- let n = this.getCodeNorm();
570
- if (n === H) return void (this.piTarget += e.slice(t));
571
- if (!this.nameCheck(n)) {
572
- this.piTarget += e.slice(t, this.prevI);
573
- let r = n === J;
574
- r || z(n) ? this.piTarget === "xml" ? (this.xmlDeclPossible || this.fail("an XML declaration must be at the start of the document."), this.state = r ? He : 27) : this.state = r ? 26 : 25 : (this.fail("disallowed character in processing instruction name."), this.piTarget += String.fromCodePoint(n));
575
- break;
576
- }
577
- }
578
- }
579
- sPIBody() {
580
- if (this.text.length === 0) {
581
- let e = this.getCodeNorm();
582
- e === J ? this.state = 26 : z(e) || (this.text = String.fromCodePoint(e));
583
- } else this.captureToChar(J) && (this.state = 26);
584
- }
585
- sPIEnding() {
586
- let e = this.getCodeNorm();
587
- if (e === q) {
588
- let { piTarget: e } = this;
589
- e.toLowerCase() === "xml" && this.fail("the XML declaration must appear at the start of the document."), this.piHandler?.({
590
- target: e,
591
- body: this.text
592
- }), this.piTarget = this.text = "", this.state = W;
593
- } else e === J ? this.text += "?" : (this.text += `?${String.fromCodePoint(e)}`, this.state = 25);
594
- this.xmlDeclPossible = !1;
595
- }
596
- sXMLDeclNameStart() {
597
- let e = this.skipSpaces();
598
- e === J ? this.state = He : e !== H && (this.state = 28, this.name = String.fromCodePoint(e));
599
- }
600
- sXMLDeclName() {
601
- let e = this.captureTo(Je);
602
- if (e === J) return this.state = He, this.name += this.text, this.text = "", void this.fail("XML declaration is incomplete.");
603
- if (z(e) || e === Ue) {
604
- if (this.name += this.text, this.text = "", !this.xmlDeclExpects.includes(this.name)) switch (this.name.length) {
605
- case 0:
606
- this.fail("did not expect any more name/value pairs.");
607
- break;
608
- case 1:
609
- this.fail(`expected the name ${this.xmlDeclExpects[0]}.`);
610
- break;
611
- default: this.fail(`expected one of ${this.xmlDeclExpects.join(", ")}`);
612
- }
613
- this.state = e === Ue ? 30 : 29;
614
- }
615
- }
616
- sXMLDeclEq() {
617
- let e = this.getCodeNorm();
618
- if (e === J) return this.state = He, void this.fail("XML declaration is incomplete.");
619
- z(e) || (e !== Ue && this.fail("value required."), this.state = 30);
620
- }
621
- sXMLDeclValueStart() {
622
- let e = this.getCodeNorm();
623
- if (e === J) return this.state = He, void this.fail("XML declaration is incomplete.");
624
- z(e) || (Y(e) ? this.q = e : (this.fail("value must be quoted."), this.q = 32), this.state = 31);
625
- }
626
- sXMLDeclValue() {
627
- let e = this.captureTo([this.q, J]);
628
- if (e === J) return this.state = He, this.text = "", void this.fail("XML declaration is incomplete.");
629
- if (e === H) return;
630
- let t = this.text;
631
- switch (this.text = "", this.name) {
632
- case "version": {
633
- this.xmlDeclExpects = ["encoding", "standalone"];
634
- let e = t;
635
- this.xmlDecl.version = e, /^1\.[0-9]+$/.test(e) ? this.opt.forceXMLVersion || this.setXMLVersion(e) : this.fail("version number must match /^1\\.[0-9]+$/.");
636
- break;
637
- }
638
- case "encoding":
639
- /^[A-Za-z][A-Za-z0-9._-]*$/.test(t) || this.fail("encoding value must match /^[A-Za-z0-9][A-Za-z0-9._-]*$/."), this.xmlDeclExpects = ["standalone"], this.xmlDecl.encoding = t;
640
- break;
641
- case "standalone": t !== "yes" && t !== "no" && this.fail("standalone value must match \"yes\" or \"no\"."), this.xmlDeclExpects = [], this.xmlDecl.standalone = t;
642
- }
643
- this.name = "", this.state = 32;
644
- }
645
- sXMLDeclSeparator() {
646
- let e = this.getCodeNorm();
647
- e === J ? this.state = He : (z(e) || (this.fail("whitespace required."), this.unGet()), this.state = 27);
648
- }
649
- sXMLDeclEnding() {
650
- this.getCodeNorm() === q ? (this.piTarget === "xml" ? this.name !== "version" && this.xmlDeclExpects.includes("version") && this.fail("XML declaration must contain a version.") : this.fail("processing instructions are not allowed before root."), this.xmlDeclHandler?.(this.xmlDecl), this.name = "", this.piTarget = this.text = "", this.state = W) : this.fail("The character ? is disallowed anywhere in XML declarations."), this.xmlDeclPossible = !1;
651
- }
652
- sOpenTag() {
653
- let e = this.captureNameChars();
654
- if (e === H) return;
655
- let t = this.tag = {
656
- name: this.name,
657
- attributes: Object.create(null)
658
- };
659
- switch (this.name = "", this.xmlnsOpt && (this.topNS = t.ns = Object.create(null)), this.openTagStartHandler?.(t), this.sawRoot = !0, !this.fragmentOpt && this.closedRoot && this.fail("documents may contain only one root."), e) {
660
- case q:
661
- this.openTag();
662
- break;
663
- case 47:
664
- this.state = 35;
665
- break;
666
- default: z(e) || this.fail("disallowed character in tag name."), this.state = 36;
667
- }
668
- }
669
- sOpenTagSlash() {
670
- this.getCode() === q ? this.openSelfClosingTag() : (this.fail("forward-slash in opening tag not followed by >."), this.state = 36);
671
- }
672
- sAttrib() {
673
- let e = this.skipSpaces();
674
- e !== H && (Me(e) ? (this.unGet(), this.state = 37) : e === q ? this.openTag() : e === 47 ? this.state = 35 : this.fail("disallowed character in attribute name."));
675
- }
676
- sAttribName() {
677
- let e = this.captureNameChars();
678
- e === Ue ? this.state = 39 : z(e) ? this.state = 38 : e === q ? (this.fail("attribute without value."), this.pushAttrib(this.name, this.name), this.name = this.text = "", this.openTag()) : e !== H && this.fail("disallowed character in attribute name.");
679
- }
680
- sAttribNameSawWhite() {
681
- let e = this.skipSpaces();
682
- switch (e) {
683
- case H: return;
684
- case Ue:
685
- this.state = 39;
686
- break;
687
- default: this.fail("attribute without value."), this.text = "", this.name = "", e === q ? this.openTag() : Me(e) ? (this.unGet(), this.state = 37) : (this.fail("disallowed character in attribute name."), this.state = 36);
688
- }
689
- }
690
- sAttribValue() {
691
- let e = this.getCodeNorm();
692
- Y(e) ? (this.q = e, this.state = 40) : z(e) || (this.fail("unquoted attribute value."), this.state = 42, this.unGet());
693
- }
694
- sAttribValueQuoted() {
695
- let { q: e, chunk: t } = this, { i: n } = this;
696
- for (;;) switch (this.getCode()) {
697
- case e:
698
- this.pushAttrib(this.name, this.text + t.slice(n, this.prevI)), this.name = this.text = "", this.q = null, this.state = 41;
699
- return;
700
- case 38:
701
- this.text += t.slice(n, this.prevI), this.state = 14, this.entityReturnState = 40;
702
- return;
703
- case G:
704
- case U:
705
- case 9:
706
- this.text += `${t.slice(n, this.prevI)} `, n = this.i;
707
- break;
708
- case K:
709
- this.text += t.slice(n, this.prevI), this.fail("disallowed character.");
710
- return;
711
- case H:
712
- this.text += t.slice(n);
713
- return;
714
- }
715
- }
716
- sAttribValueClosed() {
717
- let e = this.getCodeNorm();
718
- z(e) ? this.state = 36 : e === q ? this.openTag() : e === 47 ? this.state = 35 : Me(e) ? (this.fail("no whitespace between attributes."), this.unGet(), this.state = 37) : this.fail("disallowed character in attribute name.");
719
- }
720
- sAttribValueUnquoted() {
721
- let e = this.captureTo(Ye);
722
- switch (e) {
723
- case 38:
724
- this.state = 14, this.entityReturnState = 42;
725
- break;
726
- case K:
727
- this.fail("disallowed character.");
728
- break;
729
- case H: break;
730
- default: this.text.includes("]]>") && this.fail("the string \"]]>\" is disallowed in char data."), this.pushAttrib(this.name, this.text), this.name = this.text = "", e === q ? this.openTag() : this.state = 36;
731
- }
732
- }
733
- sCloseTag() {
734
- let e = this.captureNameChars();
735
- e === q ? this.closeTag() : z(e) ? this.state = 44 : e !== H && this.fail("disallowed character in closing tag.");
736
- }
737
- sCloseTagSawWhite() {
738
- switch (this.skipSpaces()) {
739
- case q:
740
- this.closeTag();
741
- break;
742
- case H: break;
743
- default: this.fail("disallowed character in closing tag.");
744
- }
745
- }
746
- handleTextInRoot() {
747
- let { i: e, forbiddenState: t } = this, { chunk: n, textHandler: r } = this;
748
- t: for (;;) switch (this.getCode()) {
749
- case K:
750
- if (this.state = 15, r !== void 0) {
751
- let { text: t } = this, i = n.slice(e, this.prevI);
752
- t.length === 0 ? i.length !== 0 && r(i) : (r(t + i), this.text = "");
753
- }
754
- t = 0;
755
- break t;
756
- case 38:
757
- this.state = 14, this.entityReturnState = W, r !== void 0 && (this.text += n.slice(e, this.prevI)), t = 0;
758
- break t;
759
- case We:
760
- switch (t) {
761
- case 0:
762
- t = 1;
763
- break;
764
- case 1:
765
- t = 2;
766
- break;
767
- case 2: break;
768
- default: throw Error("impossible state");
769
- }
770
- break;
771
- case q:
772
- t === 2 && this.fail("the string \"]]>\" is disallowed in char data."), t = 0;
773
- break;
774
- case U:
775
- r !== void 0 && (this.text += `${n.slice(e, this.prevI)}\n`), e = this.i, t = 0;
776
- break;
777
- case H:
778
- r !== void 0 && (this.text += n.slice(e));
779
- break t;
780
- default: t = 0;
781
- }
782
- this.forbiddenState = t;
783
- }
784
- handleTextOutsideRoot() {
785
- let { i: e } = this, { chunk: t, textHandler: n } = this, r = !1;
786
- t: for (;;) {
787
- let i = this.getCode();
788
- switch (i) {
789
- case K:
790
- if (this.state = 15, n !== void 0) {
791
- let { text: r } = this, i = t.slice(e, this.prevI);
792
- r.length === 0 ? i.length !== 0 && n(i) : (n(r + i), this.text = "");
793
- }
794
- break t;
795
- case 38:
796
- this.state = 14, this.entityReturnState = W, n !== void 0 && (this.text += t.slice(e, this.prevI)), r = !0;
797
- break t;
798
- case U:
799
- n !== void 0 && (this.text += `${t.slice(e, this.prevI)}\n`), e = this.i;
800
- break;
801
- case H:
802
- n !== void 0 && (this.text += t.slice(e));
803
- break t;
804
- default: z(i) || (r = !0);
805
- }
806
- }
807
- r && (this.sawRoot || this.reportedTextBeforeRoot || (this.fail("text data outside of root node."), this.reportedTextBeforeRoot = !0), this.closedRoot && !this.reportedTextAfterRoot && (this.fail("text data outside of root node."), this.reportedTextAfterRoot = !0));
808
- }
809
- pushAttribNS(e, t) {
810
- let { prefix: n, local: r } = this.qName(e), i = {
811
- name: e,
812
- prefix: n,
813
- local: r,
814
- value: t
815
- };
816
- if (this.attribList.push(i), this.attributeHandler?.(i), n === "xmlns") {
817
- let e = t.trim();
818
- this.currentXMLVersion === "1.0" && e === "" && this.fail("invalid attempt to undefine prefix in XML 1.0"), this.topNS[r] = e, Xe(this, r, e);
819
- } else if (e === "xmlns") {
820
- let e = t.trim();
821
- this.topNS[""] = e, Xe(this, "", e);
822
- }
823
- }
824
- pushAttribPlain(e, t) {
825
- let n = {
826
- name: e,
827
- value: t
828
- };
829
- this.attribList.push(n), this.attributeHandler?.(n);
830
- }
831
- end() {
832
- this.sawRoot || this.fail("document must contain a root element.");
833
- let { tags: e } = this;
834
- for (; e.length > 0;) {
835
- let t = e.pop();
836
- this.fail(`unclosed tag: ${t.name}`);
837
- }
838
- this.state !== 0 && this.state !== W && this.fail("unexpected end.");
839
- let { text: t } = this;
840
- return t.length !== 0 && (this.textHandler?.(t), this.text = ""), this._closed = !0, this.endHandler?.(), this._init(), this;
841
- }
842
- resolve(e) {
843
- let t = this.topNS[e];
844
- if (t !== void 0) return t;
845
- let { tags: n } = this;
846
- for (let r = n.length - 1; r >= 0; r--) if (t = n[r].ns[e], t !== void 0) return t;
847
- return t = this.ns[e], t === void 0 ? this.opt.resolvePrefix?.(e) : t;
848
- }
849
- qName(e) {
850
- let t = e.indexOf(":");
851
- if (t === -1) return {
852
- prefix: "",
853
- local: e
854
- };
855
- let n = e.slice(t + 1), r = e.slice(0, t);
856
- return (r === "" || n === "" || n.includes(":")) && this.fail(`malformed name: ${e}.`), {
857
- prefix: r,
858
- local: n
859
- };
860
- }
861
- processAttribsNS() {
862
- let { attribList: e } = this, t = this.tag;
863
- {
864
- let { prefix: e, local: n } = this.qName(t.name);
865
- t.prefix = e, t.local = n;
866
- let r = t.uri = this.resolve(e) ?? "";
867
- e !== "" && (e === "xmlns" && this.fail("tags may not have \"xmlns\" as prefix."), r === "" && (this.fail(`unbound namespace prefix: ${JSON.stringify(e)}.`), t.uri = e));
868
- }
869
- if (e.length === 0) return;
870
- let { attributes: n } = t, r = /* @__PURE__ */ new Set();
871
- for (let t of e) {
872
- let e, i, { name: a, prefix: o, local: s } = t;
873
- o === "" ? (e = a === "xmlns" ? ze : "", i = a) : (e = this.resolve(o), e === void 0 && (this.fail(`unbound namespace prefix: ${JSON.stringify(o)}.`), e = o), i = `{${e}}${s}`), r.has(i) && this.fail(`duplicate attribute: ${i}.`), r.add(i), t.uri = e, n[a] = t;
874
- }
875
- this.attribList = [];
876
- }
877
- processAttribsPlain() {
878
- let { attribList: e } = this, t = this.tag.attributes;
879
- for (let { name: n, value: r } of e) t[n] !== void 0 && this.fail(`duplicate attribute: ${n}.`), t[n] = r;
880
- this.attribList = [];
881
- }
882
- openTag() {
883
- this.processAttribs();
884
- let { tags: e } = this, t = this.tag;
885
- t.isSelfClosing = !1, this.openTagHandler?.(t), e.push(t), this.state = W, this.name = "";
886
- }
887
- openSelfClosingTag() {
888
- this.processAttribs();
889
- let { tags: e } = this, t = this.tag;
890
- t.isSelfClosing = !0, this.openTagHandler?.(t), this.closeTagHandler?.(t), (this.tag = e[e.length - 1] ?? null) === null && (this.closedRoot = !0), this.state = W, this.name = "";
891
- }
892
- closeTag() {
893
- let { tags: e, name: t } = this;
894
- if (this.state = W, this.name = "", t === "") return this.fail("weird empty close tag."), void (this.text += "</>");
895
- let n = this.closeTagHandler, r = e.length;
896
- for (; r-- > 0;) {
897
- let r = this.tag = e.pop();
898
- if (this.topNS = r.ns, n?.(r), r.name === t) break;
899
- this.fail(`unexpected close tag: ${t}.`);
900
- }
901
- r === 0 ? this.closedRoot = !0 : r < 0 && (this.fail(`unmatched closing tag: ${t}.`), this.text += `</${t}>`);
902
- }
903
- parseEntity(e) {
904
- if (e[0] !== "#") {
905
- let t = this.ENTITIES[e];
906
- return t === void 0 ? (this.fail(this.isName(e) ? "undefined entity." : "disallowed character in entity name."), `&${e};`) : t;
907
- }
908
- let t = NaN;
909
- return e[1] === "x" && /^#x[0-9a-f]+$/i.test(e) ? t = parseInt(e.slice(2), 16) : /^#[0-9]+$/.test(e) && (t = parseInt(e.slice(1), 10)), this.isChar(t) ? String.fromCodePoint(t) : (this.fail("malformed character entity."), `&${e};`);
910
- }
911
- };
912
- (Ae = R ||= {}).Events = {
913
- XmlDecl: "xmldecl",
914
- Text: "text",
915
- ProcessingInstruction: "processinginstruction",
916
- Doctype: "doctype",
917
- Comment: "comment",
918
- OpenTagStart: "opentagstart",
919
- Attribute: "attribute",
920
- OpenTag: "opentag",
921
- CloseTag: "closetag",
922
- CDdata: "cdata",
923
- Error: "error",
924
- End: "end",
925
- Ready: "ready"
926
- }, Ae.parseStream = async (e, t, n) => {
927
- let r, i = new et({
928
- position: !1,
929
- ...n
930
- });
931
- t.onOpenTagStart && i.on(R.Events.OpenTagStart, t.onOpenTagStart), t.onOpenTag && i.on(R.Events.OpenTag, t.onOpenTag), t.onCloseTag && i.on(R.Events.CloseTag, t.onCloseTag), t.onAttribute && i.on(R.Events.Attribute, t.onAttribute), t.onText && i.on(R.Events.Text, t.onText), t.onError && i.on(R.Events.Error, t.onError);
932
- let a = t.onEnd;
933
- for (a && i.on(R.Events.End, () => {
934
- r = a();
935
- });;) {
936
- let { value: t, done: n } = await e.read();
937
- if (n) break;
938
- i.write(t);
939
- }
940
- return i.close(), r;
941
- };
942
- var X = (e) => !0 === e || e === "1" || e === "on" || e === "true" || !1 !== e && e !== "0" && e !== "off" && e !== "false" && null, Z = (e) => {
943
- let t = parseInt(e);
944
- return isNaN(t) ? null : t;
945
- }, Q = (e) => {
946
- let t = parseFloat(e);
947
- return isNaN(t) ? null : t;
948
- }, $ = null, tt = (e) => e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;"), nt = (e) => tt(e).replace(/"/g, "&quot;"), rt = class {
949
- constructor() {
950
- this._registeredVisitors = /* @__PURE__ */ new Map();
951
- }
952
- registerVisitor(e) {
953
- this._registeredVisitors.set(e.from, e);
954
- }
955
- createEventHandler(e, t, n) {
956
- let r = this._registeredVisitors, i = [], a = [], o = null, s = null, c = null, l = null, u = [], ee = {
957
- key: null,
958
- source: e,
959
- parent: null
960
- }, d = null, f = !1, p = null, m = null, h = null, g = (e, t) => {
961
- let n = c.attributes[e];
962
- if (t) {
963
- if (Array.isArray(t)) {
964
- let e = t.length;
965
- for (let r = 0; r < e; r++) if (n == null || (n = t[r](n), n == null)) return;
966
- } else if (n == null || (n = t(n), n == null)) return;
967
- }
968
- return n;
969
- }, _ = {
970
- getSource: () => d?.source ?? null,
971
- setSource: (e) => {
972
- d.source = e;
973
- },
974
- setKey: (e) => {
975
- d.key = e;
976
- },
977
- getFrom: () => c,
978
- getAttribute: (e, t) => g(e, t) ?? null,
979
- hasAttribute: (e) => _.getAttribute(e) !== null,
980
- getParent: () => {
981
- let e = u[u.length - 2];
982
- return e.parent ?? e.source;
983
- },
984
- getPath: () => {
985
- let e = [], t = a.length;
986
- for (let n = 0; n < t; n++) e.push(a[n].local);
987
- return e.join("\\");
988
- },
989
- parseAttribute: g,
990
- getRawXml: () => h,
991
- copyToObject: (e, t, n, r) => {
992
- let i = g(r ?? t, n);
993
- i !== void 0 && (e[t] = i);
994
- },
995
- copyTo: (e, t, n) => {
996
- let r = g(n ?? e, t);
997
- r !== void 0 && (d.source[e] = r);
998
- },
999
- warn: (e) => {
1000
- n ? n?.(e) : console.warn(e);
1001
- }
1002
- };
1003
- return {
1004
- onOpenTag: (e) => {
1005
- let t = e.name, n = t.indexOf(":");
1006
- if (n !== -1 && (t = t.slice(n + 1)), p) return p.push(((e) => {
1007
- let t = e.attributes ?? {}, n = `<${e.name}`;
1008
- for (let e in t) {
1009
- let r = t[e];
1010
- n += ` ${e}="${nt(typeof r == "string" ? r : r?.value ?? "")}"`;
1011
- }
1012
- return n + ">";
1013
- })(e)), o = {
1014
- local: t,
1015
- tag: e,
1016
- destination: null
1017
- }, a.push(o), s = t, void (c = e);
1018
- let h = (i.length > 0 ? i[i.length - 1] : r).get(t);
1019
- if (o = {
1020
- local: t,
1021
- visitor: h,
1022
- tag: e,
1023
- destination: null
1024
- }, f) return a.push(o), s = t, void (c = e);
1025
- l = o?.visitor ?? null, s = t, c = e;
1026
- let g = !!h && h.to === null;
1027
- if (h && !g && h.scope) {
1028
- let e = h.scope(_);
1029
- e === null ? g = !0 : e && (i.push(e), o.pushedScope = !0);
1030
- }
1031
- h && (a.length === 0 ? (d = ee, o.destination = d, o.pushedDestination = !0, u.push(d)) : g ? (d = null, o.destination = null) : h.transparent ? o.destination = d : (d = {
1032
- key: null,
1033
- source: {},
1034
- parent: null
1035
- }, o.destination = d, o.pushedDestination = !0, u.push(d))), a.push(o), f = g;
1036
- let v = l?.openTag?.(_);
1037
- v !== void 0 && (d.parent = v), h?.raw && !g && (p = [], m = o);
1038
- },
1039
- onCloseTag: (e) => {
1040
- let t = e.name, r = t.indexOf(":");
1041
- if (r !== -1 && (t = t.slice(r + 1)), t !== s) throw Error(`mismatch open/close tag: '${t}'/'${s}'`);
1042
- let g = !1;
1043
- if (p) {
1044
- if (a[a.length - 1] !== m) return p.push(`</${e.name}>`), a.pop(), o = a[a.length - 1] ?? null, s = o?.local ?? null, void (c = o?.tag ?? null);
1045
- h = p.join(""), p = null, m = null, g = !0;
1046
- }
1047
- f || l?.closeTag?.(_), g && (h = null);
1048
- let v = a.pop() ?? null;
1049
- o = a[a.length - 1] ?? null, v?.pushedScope && i.pop();
1050
- let te = v?.destination;
1051
- if (te && v.pushedDestination) {
1052
- u.pop(), d = u[u.length - 1] ?? ee;
1053
- let e = v.visitor;
1054
- e && e.to && te.source !== void 0 && (Array.isArray(e.to) ? d.source.push ? d.source.push(te.source) : n?.(`Unable to parse array for ${e.from} at ${_.getPath()}`) : te.key ? d.source[te.key] = te.source : typeof e.to == "string" && (d.source[e.to] = te.source));
1055
- }
1056
- s = o?.local ?? null, c = o?.tag ?? null, l = o?.visitor ?? null, f = !o?.destination;
1057
- },
1058
- onText: (e) => {
1059
- p ? p.push(tt(e)) : l?.text?.(e, _);
1060
- },
1061
- onEnd: t
1062
- };
1063
- }
1064
- }, it = `IFERROR(${S}(`, at = it.toUpperCase(), ot = x.toUpperCase(), st = { kind: "none" }, ct = { kind: "spilled" }, lt = (e, t) => {
1065
- if (e.charCodeAt(t) !== 34) return null;
1066
- let n = "", r = t + 1;
1067
- for (; r < e.length;) if (e.charCodeAt(r) === 34) {
1068
- if (e.charCodeAt(r + 1) !== 34) return {
1069
- value: n,
1070
- end: r + 1
1071
- };
1072
- n += "\"", r += 2;
1073
- } else n += e[r], r++;
1074
- return null;
1075
- }, ut = (e) => {
1076
- let t = [], n = 0;
1077
- for (; n < e.length;) {
1078
- let r = e.charCodeAt(n);
1079
- if (r === 34) {
1080
- let t = lt(e, n);
1081
- if (t === null) break;
1082
- n = t.end;
1083
- continue;
1084
- }
1085
- if (!(r >= 65 && r <= 90 || r >= 97 && r <= 122 || r === 95)) {
1086
- n++;
1087
- continue;
1088
- }
1089
- let i = n + 1;
1090
- for (; i < e.length;) {
1091
- let t = e.charCodeAt(i);
1092
- if (!(t >= 65 && t <= 90 || t >= 97 && t <= 122 || t >= 48 && t <= 57 || t === 95 || t === 46)) break;
1093
- i++;
1094
- }
1095
- e.charCodeAt(i) === 40 && t.push(e.slice(n, i).toUpperCase().replace(/^_XLFN\./, "").replace(/^_XLWS\./, "")), n = i;
1096
- }
1097
- return t;
1098
- }, dt = (e) => {
1099
- let t = 0, n = 0;
1100
- for (let r = 0; r < e.length; r++) {
1101
- let i = e[r];
1102
- if (i !== "\"" && i !== "'") {
1103
- if (i === "[") n++;
1104
- else if (i === "]") n > 0 && n--;
1105
- else if (n === 0) {
1106
- if (i === "(") t++;
1107
- else if (i === ")" && (t--, t < 0)) return !1;
1108
- }
1109
- } else {
1110
- for (r++; r < e.length;) {
1111
- if (e[r] === i) {
1112
- if (e[r + 1] === i) {
1113
- r += 2;
1114
- continue;
1115
- }
1116
- break;
1117
- }
1118
- r++;
1119
- }
1120
- if (r >= e.length) return !1;
1121
- }
1122
- }
1123
- return t === 0 && n === 0;
1124
- }, ft = class {
1125
- static {
1126
- this.Collapsed = 1;
1127
- }
1128
- static {
1129
- this.CustomFormat = 2;
1130
- }
1131
- static {
1132
- this.CustomHeight = 4;
1133
- }
1134
- static {
1135
- this.Hidden = 8;
1136
- }
1137
- static {
1138
- this.Ht = 16;
1139
- }
1140
- static {
1141
- this.OutlineLevel = 32;
1142
- }
1143
- static {
1144
- this.Ph = 64;
1145
- }
1146
- static {
1147
- this.R = 128;
1148
- }
1149
- static {
1150
- this.S = 256;
1151
- }
1152
- static {
1153
- this.Spans = 512;
1154
- }
1155
- static {
1156
- this.ThickBot = 1024;
1157
- }
1158
- static {
1159
- this.ThickTop = 2048;
1160
- }
1161
- }, pt = (e, t, n) => {
1162
- if (e[0].value[0] === e[1].value[0]) return t;
1163
- }, mt = {
1164
- colStart: 0,
1165
- colEnd: 0,
1166
- rowStart: 0,
1167
- rowEnd: 0
1168
- }, ht = (r, i, o, s, c, l, u) => {
1169
- let ee = !1, f = !1, p = [], m = !1, h = null, g = null, _ = null, v = null, te = null, ne = null, re = u?.get("richData") ?? n.EmptyArray, ie = u?.get("dummyWrapped") ?? null, ae = d.normalizeA1ToR1C1, oe = a.createConflatingRanges(), se = /* @__PURE__ */ new Map(), y = [], b = !1, x = !1, ce = null, le = !1, ue = a.createConflatingRanges(), S = !1, C = -1, w = -1, T = null, de = null, fe = null, pe = [], me = null, E = -2, D = 0, O = "", he = "", ge = "", _e = "", ve = "", ye = "", be = "", k = "", xe = "", Se = "", A = "", j = "", Ce = "", we = "", M = !0, N = null, Te = !1, Ee = !1, P = null, F = 0;
1170
- return {
1171
- ...o,
1172
- onEnd: () => {
1173
- pe.length > 0 && (i.rows = d.runsToRefs(pe, !1));
1174
- let t = oe.done(pt), n = t.length;
1175
- if (n > 0) {
1176
- let e = /* @__PURE__ */ new Set();
1177
- for (let t = 0; t < y.length; t++) e.add(y[t][0].split(":")[0]);
1178
- let r = Array(n);
1179
- for (let i = 0; i < n; i++) {
1180
- let n = t[i], a = d.rangeToString(n), o = n.value[1], s = d.resolveRelativeToA1(o, n.rowStart, n.colStart);
1181
- s && !e.has(a.split(":")[0]) && dt(s) && (s = `__sxl.INTERSECT(${s})`), r[i] = [a, s];
1182
- }
1183
- i.formulas = r;
1184
- }
1185
- let s = ue.done(!0), c = s.length;
1186
- if (c > 0) {
1187
- let e = Array(c);
1188
- for (let t = 0; t < c; t++) {
1189
- let n = s[t];
1190
- e[t] = d.rangeToString(n);
1191
- }
1192
- i.volatile = e;
1193
- }
1194
- y.length > 0 && (i.formulaArray = [...y]);
1195
- let l = p.length;
1196
- if (l > 0) {
1197
- p.sort(a.createRangeComparator(e.Axis.Column));
1198
- let t = p[0], n = t.colStart, r = t.colEnd, o = t.rowEnd, s = t.value, c = [];
1199
- c.push(t);
1200
- let u = null;
1201
- for (let e = 1; e < l; e++) u = p[e], s !== u.value || n !== u.colStart || r !== u.colEnd || o + 1 !== u.rowEnd ? (c.push(u), t = u, n = t.colStart, r = t.colEnd, o = t.rowEnd, s = t.value) : (o = u.rowEnd, t.rowEnd = o);
1202
- let ee = c.length, f = Array(ee);
1203
- for (let e = 0; e < ee; e++) {
1204
- let t = c[e];
1205
- f[e] = [d.rangeToString(t), t.value];
1206
- }
1207
- i.directStyles = f;
1208
- }
1209
- let u = r.build();
1210
- u && (i.data = u.tuples), o?.onEnd?.();
1211
- },
1212
- onOpenTag: (e) => {
1213
- let n = e.name, r = n.indexOf(":");
1214
- if (r !== -1 && (n = n.slice(r + 1)), F++, F % 196608 == 0 && c?.(F), de) {
1215
- let t = e.attributes;
1216
- switch (n) {
1217
- case "v":
1218
- f = !0;
1219
- break;
1220
- case "f":
1221
- switch (m = !0, t.t ?? null) {
1222
- case null:
1223
- case "normal": break;
1224
- case "shared":
1225
- let e = t.si;
1226
- g = t.ref, h = e;
1227
- break;
1228
- case "array":
1229
- g = t.ref, ce = g;
1230
- break;
1231
- case "datatable": g = t.ref, m = !0;
1232
- }
1233
- let e = t.ca;
1234
- e !== void 0 && (le = e === "1");
1235
- break;
1236
- case "is":
1237
- S = !0;
1238
- return;
1239
- }
1240
- S && !m && l?.onOpenTag?.(e);
1241
- return;
1242
- }
1243
- if (ee) {
1244
- if (n === "c") {
1245
- de = e;
1246
- let n = e.attributes, r = n.r;
1247
- w = d.fastStringToCol(r);
1248
- let i = n.t;
1249
- i === void 0 ? fe = null : (fe = i, fe === "str" && (S = !0));
1250
- let a = n.s;
1251
- a === void 0 && (P !== null || Ee) && (a = "0"), a !== void 0 && (a = parseInt(a), N && N.value === a && N.colEnd + 1 === w ? N.colEnd = w : (N = {
1252
- colStart: w,
1253
- rowStart: C,
1254
- colEnd: w,
1255
- rowEnd: C,
1256
- value: a
1257
- }, p.push(N))), ce = null, x = !1;
1258
- let o = n.cm;
1259
- b = o !== void 0 && ((e) => {
1260
- let t = u?.get("metadata")?.cells;
1261
- if (!t) return !1;
1262
- let n = parseInt(e, 10);
1263
- return !(!Number.isFinite(n) || n < 1) && !0 === t[n - 1]?.get("XLDAPR")?.fDynamic;
1264
- })(o);
1265
- let s = n.vm;
1266
- if (s !== void 0) {
1267
- let e = re[parseInt(s) - 1];
1268
- if (t.isError(e)) {
1269
- let n = e.getCode();
1270
- T = {
1271
- t: "e",
1272
- v: n
1273
- }, b && n === t.Code.Spill && (x = !0);
1274
- }
1275
- }
1276
- }
1277
- } else {
1278
- if (n === "row") {
1279
- ee = !0;
1280
- let t = e.attributes.r;
1281
- if (C = parseInt(t) - 1, D = 0, he = e.attributes.customHeight, he !== void 0 && (D |= ft.CustomHeight), he !== xe && (M = !0, xe = he), O = e.attributes.ht, O !== void 0 && (D |= ft.Ht), O !== k && (M = !0, k = O), ge = e.attributes.hidden, ge !== void 0 && (D |= ft.Hidden), ge !== Se && (M = !0, Se = ge), ve = e.attributes.s, ve !== void 0 && (D |= ft.S), ve !== j && (M = !0, j = ve), _e = e.attributes.customFormat, _e !== void 0 && (D |= ft.CustomFormat), _e !== A && (M = !0, A = _e), ye = e.attributes.outlineLevel, ye !== void 0 && (D |= ft.OutlineLevel), ye !== Ce && (M = !0, Ce = ye), be = e.attributes.collapsed, be !== void 0 && (D |= ft.Collapsed), be !== we && (M = !0, we = be), D !== 0) if (E + 1 !== C || M) {
1282
- let e = he !== void 0 && (he === "1" || he === "true"), t = _e !== void 0 && (_e === "1" || _e === "true");
1283
- P = t && ve !== void 0 ? ve : null, t && P === null && (P = "0"), me = {
1284
- min: C,
1285
- max: C,
1286
- value: {
1287
- sz: O === void 0 ? -1 : parseFloat(O),
1288
- csz: e,
1289
- h: ge !== void 0 && (ge === "1" || ge === "true"),
1290
- s: P === null ? void 0 : P === "0" ? 0 : parseInt(P),
1291
- l: ye === void 0 || ye === "0" ? 0 : parseInt(ye),
1292
- cl: be !== void 0 && (be === "1" || be === "true")
1293
- }
1294
- }, pe.push(me);
1295
- } else me.max = C;
1296
- E = C, M = !1;
1297
- return;
1298
- }
1299
- if (!Te && n === "sheetData") {
1300
- Te = !0;
1301
- let e = i.cols, t = e ? e.length : 0;
1302
- for (let n = 0; !Ee && n < t; n++) e[n].v.s && (Ee = !0);
1303
- }
1304
- o?.onOpenTag?.(e);
1305
- }
1306
- },
1307
- onCloseTag: (e) => {
1308
- let t = e.name;
1309
- if (!m || t !== "c" && t !== "f" || (h && (v = se.get(h) ?? null), v && (oe.append(C, w, v), le && ue.append(C, w)), ce !== null && y.push([ce, b ? x ? "dynamicSpillError" : "dynamic" : "static"]), m = !1, v = null, h = null, g = null, f = !1, le = !1, ce = null, b = !1, x = !1), de) {
1310
- let n = t.indexOf(":");
1311
- if (n !== -1 && (t = t.slice(n + 1)), S) if (t === "is" || t === "v") {
1312
- let e = l?.onEnd?.();
1313
- e != null && r.pushAt(C, w, "" + e);
1314
- } else t !== "f" && l?.onCloseTag?.(e);
1315
- f &&= !1, t === "c" && (de = null, S = !1);
1316
- return;
1317
- }
1318
- if (ee) return ee = !1, void (N = null);
1319
- o?.onCloseTag?.(e);
1320
- },
1321
- onText: (e) => {
1322
- let n = e.trim();
1323
- if (f) {
1324
- switch (T = null, fe) {
1325
- case null:
1326
- case "n":
1327
- T = parseFloat(n);
1328
- break;
1329
- case "b":
1330
- T = n === "1" || n === "true";
1331
- break;
1332
- case "s":
1333
- T = n;
1334
- break;
1335
- case "e":
1336
- if (n === "#VALUE!") {
1337
- let e = de.attributes.vm;
1338
- if (e !== void 0) {
1339
- let n = re[parseInt(e) - 1];
1340
- if (t.isError(n)) {
1341
- T = {
1342
- t: "e",
1343
- v: n.getCode()
1344
- };
1345
- break;
1346
- }
1347
- }
1348
- }
1349
- let e = t.getBuiltInByLabel(n);
1350
- e ? T = {
1351
- t: "e",
1352
- v: e.getCode()
1353
- } : (T = n, s?.(`Unknown formula error '${n}' in cell ${d.cellToString({
1354
- colIndex: w,
1355
- rowIndex: C
1356
- })}`));
1357
- break;
1358
- case "str":
1359
- case "inlineStr": S = !0;
1360
- }
1361
- T !== null && r.pushAt(C, w, T);
1362
- }
1363
- if (h) {
1364
- if (te === h) v = ne;
1365
- else {
1366
- if (v = se.get(h) ?? null, !v) {
1367
- let e = [];
1368
- _ = ae(n, C, w, e), v = [
1369
- _,
1370
- e,
1371
- n
1372
- ], se.set(h, v);
1373
- }
1374
- te = h, ne = v;
1375
- }
1376
- h = null;
1377
- }
1378
- if (m) {
1379
- if (ie !== null) {
1380
- let e = ((e) => {
1381
- if (e.length < it.length || e.slice(0, it.length).toUpperCase() !== at) return st;
1382
- let t = lt(e, it.length);
1383
- if (t === null || e.charCodeAt(t.end) !== 41 || e.charCodeAt(t.end + 1) !== 44 || e.charCodeAt(e.length - 1) !== 41) return st;
1384
- let n = t.value;
1385
- return n.toUpperCase() === ot ? ct : n.length === 0 ? st : {
1386
- kind: "formula",
1387
- formula: n
1388
- };
1389
- })(n);
1390
- e.kind !== "none" && ie.push({
1391
- sheet: i,
1392
- rowIndex: C,
1393
- colIndex: w,
1394
- formula: e.kind === "formula" ? e.formula : null
1395
- });
1396
- }
1397
- let e = [];
1398
- _ = ae(n, C, w, e), v = [
1399
- _,
1400
- e,
1401
- n
1402
- ];
1403
- }
1404
- S ? l?.onText?.(e) : ee || o?.onText?.(n);
1405
- }
1406
- };
1407
- }, gt = (e) => {
1408
- let t = e.indexOf(":");
1409
- return t === -1 ? e : e.slice(t + 1);
1410
- }, _t = {
1411
- "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml": "workbooks",
1412
- "application/vnd.ms-excel.sheet.macroEnabled.main+xml": "workbooks",
1413
- "application/vnd.ms-excel.sheet.binary.macroEnabled.main": "workbooks",
1414
- "application/vnd.ms-excel.addin.macroEnabled.main+xml": "workbooks",
1415
- "application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml": "workbooks",
1416
- "application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml": "sheets",
1417
- "application/vnd.ms-excel.worksheet": "sheets",
1418
- "application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml": "charts",
1419
- "application/vnd.ms-excel.chartsheet": "charts",
1420
- "application/vnd.ms-excel.macrosheet+xml": "macros",
1421
- "application/vnd.ms-excel.macrosheet": "macros",
1422
- "application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml": "dialogs",
1423
- "application/vnd.ms-excel.dialogsheet": "dialogs",
1424
- "application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml": "strs",
1425
- "application/vnd.ms-excel.sharedStrings": "strs",
1426
- "application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml": "styles",
1427
- "application/vnd.ms-excel.styles": "styles",
1428
- "application/vnd.openxmlformats-package.core-properties+xml": "coreprops",
1429
- "application/vnd.openxmlformats-officedocument.custom-properties+xml": "custprops",
1430
- "application/vnd.openxmlformats-officedocument.extended-properties+xml": "extprops",
1431
- "application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml": "comments",
1432
- "application/vnd.ms-excel.comments": "comments",
1433
- "application/vnd.ms-excel.threadedcomments+xml": "threadedcomments",
1434
- "application/vnd.ms-excel.person+xml": "people",
1435
- "application/vnd.openxmlformats-officedocument.spreadsheetml.sheetMetadata+xml": "metadata",
1436
- "application/vnd.ms-excel.sheetMetadata": "metadata",
1437
- "application/vnd.ms-excel.externalLink": "links",
1438
- "application/vnd.openxmlformats-officedocument.spreadsheetml.externalLink+xml": "links",
1439
- "application/vnd.openxmlformats-officedocument.theme+xml": "themes"
1440
- }, vt = (e) => e.startsWith("/") ? e.slice(1) : e, yt = /^xl\/(worksheets|chartsheets)\/[^/]+\.xml$/i, bt = async (e, t) => {
1441
- let { password: a, onVBA: m, profile: ie, createWorkbookOptions: y = {}, ...x } = t ?? {}, ue = y.origin && typeof y.origin != "string" ? y.origin : null, S = ie ? new Se(typeof ie == "function" ? ie : void 0) : null, k = [], A = t?.progress, j = A?.onProgress ? A.onProgress.bind(A) : void 0, Ce = e.byteLength, we = 0, M = 0, N = j ? (e) => {
1442
- if (we <= 0) return;
1443
- M += e;
1444
- let t = Math.min(Ce, Math.round(M / we * Ce));
1445
- j(t, Ce);
1446
- } : void 0, Te = import("./BKEzd89UphJ8q1pp2.js"), Ee = null;
1447
- try {
1448
- Ee = new DOMParser();
1449
- } catch {}
1450
- let P = null;
1451
- try {
1452
- P = new XMLSerializer();
1453
- } catch {}
1454
- let F, I, De, Oe = null;
1455
- Ee || (Oe = import("./CpnA5TZRkPDt4HnM2.js").then((e) => E(e.default, 1)));
1456
- try {
1457
- let [e, t] = await Promise.all([Oe, Te]);
1458
- F = new t.DOMTransformer(), I = Ee ?? new e.DOMParser(), De = P ?? new e.XMLSerializer();
1459
- } catch (e) {
1460
- throw Error("Unable to load XLSX parser.", { cause: e });
1461
- }
1462
- let L, ke = (e) => De.serializeToString(e);
1463
- try {
1464
- L = await xe.create(e);
1465
- } catch (e) {
1466
- throw new o("Unable to parse as an Excel document. Try to save as '.xlsx' and try again.", { cause: e });
1467
- }
1468
- S?.mark("zip-open");
1469
- try {
1470
- if (!L.has("[Content_Types].xml")) throw new o("Unable to parse as an Excel document. Try to save as '.xlsx' and try again.");
1471
- let e = (e) => {
1472
- let t = L.getEntry(e);
1473
- return t ? { content: t } : void 0;
1474
- }, t = {
1475
- workbooks: [],
1476
- sheets: [],
1477
- charts: [],
1478
- dialogs: [],
1479
- macros: [],
1480
- strs: [],
1481
- comments: [],
1482
- threadedcomments: [],
1483
- links: [],
1484
- coreprops: [],
1485
- extprops: [],
1486
- custprops: [],
1487
- themes: [],
1488
- styles: [],
1489
- metadata: [],
1490
- people: [],
1491
- sst: "",
1492
- style: "",
1493
- defaults: {}
1494
- };
1495
- {
1496
- let e = ((e) => ({
1497
- onOpenTag: (t) => {
1498
- let n = ((e) => {
1499
- let t = e.indexOf(":");
1500
- return t === -1 ? e : e.slice(t + 1);
1501
- })(t.name), r = t.attributes;
1502
- if (n === "Override") {
1503
- let t = r.ContentType, n = r.PartName;
1504
- if (!t || !n) return;
1505
- let i = _t[t], a = i ? e[i] : void 0;
1506
- Array.isArray(a) && a.push(n);
1507
- } else if (n === "Default") {
1508
- let t = r.Extension, n = r.ContentType;
1509
- t && (e.defaults[t.toLowerCase()] = n);
1510
- }
1511
- },
1512
- onEnd: () => {
1513
- e.sst = e.strs.length > 0 ? e.strs[0] : "", e.style = e.styles.length > 0 ? e.styles[0] : "";
1514
- },
1515
- onError: (e) => {
1516
- ((e) => {
1517
- k.push([e, "[Content_Types].xml"]);
1518
- })(`Error parsing content types: ${e?.message ?? e}`);
1519
- }
1520
- }))(t), n = await L.getTextStream("[Content_Types].xml");
1521
- if (!n) throw Error("Error parsing content types: '[Content_Types].xml'");
1522
- try {
1523
- await R.parseStream(n, e, { xmlns: !1 });
1524
- } catch (e) {
1525
- throw Error("Error parsing content types: '[Content_Types].xml'", { cause: e });
1526
- }
1527
- ue && await L.getBuffer("[Content_Types].xml");
1528
- }
1529
- S?.mark("content-types");
1530
- let r = t.sst, a = /* @__PURE__ */ new Set();
1531
- for (let e of t.sheets) a.add(vt(e));
1532
- r && a.add(vt(r));
1533
- for (let e of a) we += L.uncompressedSize(e);
1534
- if (await L.prefetch((e) => !a.has(e) && !yt.test(e)), S?.mark("prefetch-side-parts"), t.workbooks.length === 0) {
1535
- let n = _e("_rels/.rels", e, I, F);
1536
- if (n) {
1537
- for (let e of n.values()) if (e.type === "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" && e.target) {
1538
- t.workbooks.push(e.target);
1539
- break;
1540
- }
1541
- }
1542
- }
1543
- if (t.workbooks.length === 0) throw new o("Unable to parse as an Excel document. Try to save as '.xlsx' and try again.");
1544
- t.richstructure = ["/xl/richData/rdrichvaluestructure.xml"], t.richdata = ["/xl/richData/rdrichvalue.xml"];
1545
- let x = y?.resources ?? new c(), E = x.beginPersist(), xe = {}, Se = /* @__PURE__ */ new Set(), M = /* @__PURE__ */ new Map();
1546
- M.set("richTypes", []), M.set("parseInlineDxf", (e) => {
1547
- if (!e) return;
1548
- let t = I.parseFromString(`<dxf xmlns:x14="${me}" xmlns:xm="${h}">${e}</dxf>`, "text/xml")?.documentElement;
1549
- if (!t) return;
1550
- let n = F.parseDxf(t);
1551
- return Object.keys(n).length > 0 ? n : void 0;
1552
- });
1553
- let Te = [];
1554
- M.set("dummyWrapped", Te);
1555
- let Ee = O("metadata", t, e, I, F).entries().next()?.value?.[1]?.metadata;
1556
- Ee && M.set("metadata", Ee);
1557
- let P = /* @__PURE__ */ new Map(), De = [], Oe = (t, n = P) => {
1558
- let r = t.lastIndexOf("/"), i = t.substring(0, r + 1) + "_rels/" + t.substring(r + 1, t.length) + ".rels", a = n.get(i);
1559
- return a || (a = _e(i, e, I, F, V), n.set(i, a)), a;
1560
- }, Ae = (t, r, i, a = P) => {
1561
- let o = Oe(r, a).get(t), s = o?.target;
1562
- if (!s) return null;
1563
- if (o.targetMode === "External") {
1564
- if (!i) return o.target;
1565
- let e = x.add({ source: { external: o.target } });
1566
- return e.addReference(xe), Se.add(e), E.toResourceId(e);
1567
- }
1568
- let c = r.lastIndexOf("/"), f = r.substring(0, c + 1);
1569
- s.startsWith("/") || (s = f + s), s = be(s);
1570
- let m = F?.getVisitorParamsState().get("dxfs"), h = a.get(s);
1571
- if (!h) if (o.type === "http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet") {
1572
- let e = {};
1573
- h = e, De.push((async () => {
1574
- let t = ((e, t, n, r, i, a, o, s) => {
1575
- let c = new rt(), f = s?.get("parseInlineDxf"), m = new ee.TransposedBuilder(), h = null;
1576
- c.registerVisitor({
1577
- from: "autoFilter",
1578
- to: "autoTable",
1579
- openTag: (e) => {
1580
- let t = e.getAttribute("ref"), n = d.fastStringToRange(t);
1581
- e.getSource().r = n, e.getSource().v = {};
1582
- },
1583
- closeTag: (e) => {
1584
- let t = e.getSource(), n = t.v, r = n.hiddenButtons;
1585
- if (Array.isArray(r)) {
1586
- let e = r.length, i = t.r, a = i.colEnd - i.colStart + 1;
1587
- e === 0 ? n.hiddenButtons = !1 : e === a && (n.hiddenButtons = !0);
1588
- }
1589
- }
1590
- }), c.registerVisitor({
1591
- from: "conditionalFormatting",
1592
- to: {},
1593
- openTag: (e) => {
1594
- let t = e.getParent();
1595
- t.conditionals ||= [];
1596
- let n = e.getAttribute("sqref");
1597
- n &&= n.trim().split(/\s+/).join(",");
1598
- let r = {
1599
- r: n,
1600
- conditionals: t.conditionals
1601
- }, i = e.getAttribute("pivot", X);
1602
- i !== null && (r.pivot = i), e.setSource(r);
1603
- }
1604
- }), c.registerVisitor({
1605
- from: "cfRule",
1606
- to: {},
1607
- openTag: (e) => {
1608
- let t = e.getParent();
1609
- if (!t?.r) return;
1610
- let n = e.getSource() ?? {};
1611
- t.pivot !== void 0 && (n.pivot = t.pivot), t.conditionals.push({
1612
- r: t.r,
1613
- v: null,
1614
- rule: n
1615
- }), e.copyToObject(n, "type", $), e.copyToObject(n, "priority", Z), e.copyToObject(n, "stopIfTrue", X);
1616
- let i = e.getAttribute("dxfId", Z);
1617
- if (i !== null) {
1618
- let t = r?.get(i);
1619
- t ||= (a?.(`Unable to load conditional color. Invalid dxfI: '${i}' at '${e.getPath()}'.`), {}), n.style = t;
1620
- }
1621
- e.copyToObject(n, "aboveAverage", X), e.copyToObject(n, "equalAverage", X), e.copyToObject(n, "stdDev", Z), e.copyToObject(n, "bottom", X), e.copyToObject(n, "percent", X), e.copyToObject(n, "rank", Z), e.copyToObject(n, "operator", $), e.copyToObject(n, "text", $), e.copyToObject(n, "timePeriod", $);
1622
- },
1623
- closeTag: (e) => {
1624
- let t = e.getParent();
1625
- if (!t?.r) return;
1626
- let n = t.conditionals[t.conditionals.length - 1], r = n?.rule;
1627
- if (!r) return;
1628
- let i = {}, o = ce(r, a);
1629
- o && (i.condition = o), r.style && (i.style = r.style), r.scale && (i.scale = r.scale), r.stopIfTrue && (i.stopIfTrue = !0), r.pivot && (i.pivot = !0), n.v = i, n.priority = r.priority, r.x14Id && (n.x14Id = r.x14Id), delete n.rule;
1630
- }
1631
- });
1632
- let ne = (e) => {
1633
- let t = e.conditions ?? [], n = [];
1634
- for (let e = 0; e < t.length; e++) {
1635
- let r = t[e], i = {};
1636
- r.type && (i.type = r.type), r.value !== void 0 && (i.value = r.value), r.exclusive && (i.exclusive = !0), n.push(i);
1637
- }
1638
- return n;
1639
- };
1640
- c.registerVisitor({
1641
- from: "colorScale",
1642
- to: {},
1643
- openTag: (e) => {},
1644
- closeTag: (e) => {
1645
- let t = e.getSource(), n = t.colors ?? [], r = ne(t);
1646
- for (let e = 0; e < r.length; e++) r[e].color = n[e];
1647
- e.getParent().scale = {
1648
- type: u.ScaleType.ColorScale,
1649
- stops: r
1650
- };
1651
- }
1652
- }), c.registerVisitor({
1653
- from: "dataBar",
1654
- to: {},
1655
- openTag: (e) => {
1656
- e.copyTo("maxLength", Z), e.copyTo("minLength", Z), e.copyTo("showValue", X);
1657
- },
1658
- closeTag: (e) => {
1659
- let t = e.getSource(), n = {
1660
- type: u.ScaleType.DataBar,
1661
- stops: ne(t)
1662
- }, r = t.colors?.[0];
1663
- r && (n.color = r), t.minLength !== void 0 && (n.minLength = t.minLength), t.maxLength !== void 0 && (n.maxLength = t.maxLength), t.showValue !== void 0 && (n.showValue = t.showValue), e.getParent().scale = n;
1664
- }
1665
- }), c.registerVisitor({
1666
- from: "iconSet",
1667
- to: {},
1668
- openTag: (e) => {
1669
- e.copyTo("iconSet", $), e.copyTo("reverse", X), e.copyTo("showValue", X);
1670
- },
1671
- closeTag: (e) => {
1672
- let t = e.getSource(), n = {
1673
- type: u.ScaleType.IconSet,
1674
- stops: ne(t)
1675
- };
1676
- t.iconSet !== void 0 && (n.iconSet = t.iconSet), t.reverse !== void 0 && (n.reverse = t.reverse), t.showValue !== void 0 && (n.showValue = t.showValue), e.getParent().scale = n;
1677
- }
1678
- }), c.registerVisitor({
1679
- from: "formula",
1680
- to: {},
1681
- text: (e, t) => {
1682
- let n = t.getParent(), r = n.formulas;
1683
- r || (r = [], n.formulas = r), r.push(e);
1684
- }
1685
- }), c.registerVisitor({
1686
- from: "cfvo",
1687
- to: {},
1688
- openTag: (e) => {
1689
- let t = e.getParent();
1690
- t.conditions ||= [];
1691
- let n = e.getSource();
1692
- t.conditions.push(n), e.copyTo("type", $), n.type === u.ColorStopType.Formula ? e.copyTo("value", $, "val") : e.copyTo("value", Q, "val"), !1 === e.getAttribute("gte", X) && (n.exclusive = !0);
1693
- }
1694
- }), c.registerVisitor({
1695
- from: "color",
1696
- to: {},
1697
- openTag: (e) => {
1698
- let t = e.getParent();
1699
- t.colors ||= [];
1700
- let n = ve((t) => e.getAttribute(t));
1701
- t.colors.push(n);
1702
- }
1703
- }), c.registerVisitor({
1704
- from: "filterColumn",
1705
- to: {},
1706
- openTag: (e) => {
1707
- let t = e.getParent().v, n = parseInt(e.getAttribute("colId")), r = e.getSource();
1708
- r.index = n;
1709
- let i = t.filter;
1710
- i || (i = { conditions: [] }, t.filter = i);
1711
- let a = i.conditions;
1712
- if (a || (a = [], i.conditions = a), a.push(r), e.getAttribute("hiddenButton", X) && t) {
1713
- let e = t.hiddenButtons;
1714
- e || (e = [], t.hiddenButtons = e), e.push(n);
1715
- }
1716
- if (e.getAttribute("showButton", X) && t) {
1717
- let e = t.showButtons;
1718
- e || (e = [], t.showButtons = e), e.push(n);
1719
- }
1720
- return r;
1721
- }
1722
- }), c.registerVisitor({
1723
- from: "colorFilter",
1724
- openTag: (e) => {
1725
- let t = e.getParent(), n = {};
1726
- t.operator = l.BuiltInOperatorNames.Color, t.param = n, e.copyToObject(n, "cellColor"), e.copyToObject(n, "styleId", Z, "dxfId");
1727
- }
1728
- }), c.registerVisitor({
1729
- from: "iconFilter",
1730
- openTag: (e) => {
1731
- let t = e.getParent(), n = {};
1732
- t.operator = l.BuiltInOperatorNames.Icon, t.param = n, e.copyToObject(n, "iconId", Z), e.copyToObject(n, "iconSet", $);
1733
- }
1734
- }), c.registerVisitor({
1735
- from: "top10",
1736
- openTag: (e) => {
1737
- let t = e.getParent(), n = {};
1738
- t.operator = l.BuiltInOperatorNames.TopN, t.param = n, e.copyToObject(n, "filterVal", Q), e.copyToObject(n, "percent", X), e.copyToObject(n, "top", X), e.copyToObject(n, "limit", Q, "val");
1739
- }
1740
- }), c.registerVisitor({
1741
- from: "dynamicFilter",
1742
- openTag: (e) => {
1743
- let t = e.getParent(), n = {};
1744
- t.operator = l.BuiltInOperatorNames.TimePeriod, t.param = n;
1745
- let r = e.getAttribute("type");
1746
- Object.values(l.AverageType).includes(r) ? (t.operator = l.BuiltInOperatorNames.Average, e.copyToObject(n, "stdDevs", Z, "val")) : e.copyToObject(n, "anchorDate", Z, "val"), e.copyToObject(n, "operator", $, "type"), e.copyToObject(n, "maxVal", Q, "maxVal");
1747
- }
1748
- }), c.registerVisitor({
1749
- from: "filters",
1750
- to: {},
1751
- openTag: (e) => {
1752
- let t = e.getParent(), n = {};
1753
- return t.operator = l.BuiltInOperatorNames.InSet, t.param = n, e.copyToObject(n, "blank", X), e.copyToObject(n, "calendarType", $), n;
1754
- }
1755
- }), c.registerVisitor({
1756
- from: "filter",
1757
- openTag: (e) => {
1758
- let t = e.getParent(), n = t.items;
1759
- n || (n = [], t.items = n), n.push(e.getAttribute("val", $));
1760
- }
1761
- }), c.registerVisitor({
1762
- from: "dateGroupItem",
1763
- to: {},
1764
- openTag: (e) => {
1765
- let t = e.getParent(), n = t.dateGroups;
1766
- n || (n = [], t.dateGroups = n), n.push(e.getSource()), e.copyTo("group", $, "dateTimeGrouping"), e.copyTo("day", Z), e.copyTo("hour", Z), e.copyTo("minute", Z), e.copyTo("month", Z), e.copyTo("second", Z), e.copyTo("year", Z);
1767
- }
1768
- }), c.registerVisitor({
1769
- from: "customFilters",
1770
- openTag: (e) => {
1771
- let t = e.getParent(), n = e.getAttribute("and"), r = n === "and" || n === "1", i = [];
1772
- return t.operator = r ? l.BuiltInOperatorNames.And : l.BuiltInOperatorNames.Or, t.param = i, e.setSource(t), i;
1773
- },
1774
- closeTag: (e) => {
1775
- let t = e.getSource(), n = t?.param;
1776
- if (n?.length !== 1) return;
1777
- let r = n[0];
1778
- t.operator = r.operator, t.param = r.param;
1779
- }
1780
- }), c.registerVisitor({
1781
- from: "customFilter",
1782
- openTag: (e) => {
1783
- let t, n = e.getParent();
1784
- Array.isArray(n) ? (t = {}, n.push(t)) : t = n;
1785
- let r = C({
1786
- operator: e.getAttribute("operator"),
1787
- val: e.getAttribute("val")
1788
- });
1789
- r && (t.operator = r.operator, t.param = r.param);
1790
- }
1791
- }), c.registerVisitor({
1792
- from: "sortState",
1793
- to: {},
1794
- openTag: (e) => {
1795
- let t = e.getParent(), n = t.v;
1796
- n && (n.sort = {}, e.setSource(t));
1797
- }
1798
- }), c.registerVisitor({
1799
- from: "sortCondition",
1800
- to: {},
1801
- openTag: (e) => {
1802
- let t = e.getParent(), n = t.v;
1803
- if (!n) return;
1804
- let r = n.sort;
1805
- if (!r) return;
1806
- let i = r.sorts;
1807
- i || (i = [], r.sorts = i);
1808
- let a = e.getAttribute("ref"), o = 0;
1809
- if (a) {
1810
- let e = d.fastStringToRange(a, mt).colStart, n = t.r, r = n.colStart;
1811
- o = n ? e - r : e;
1812
- }
1813
- let s = {};
1814
- e.copyToObject(s, "sortOn", $, "sortBy"), e.copyToObject(s, "dxfId", $, "sortBy"), e.copyToObject(s, "iconSet", $), e.copyToObject(s, "customList", $), s.reverse = e.getAttribute("descending", X) ?? !1;
1815
- let c = {
1816
- index: o,
1817
- criteria: s
1818
- };
1819
- i.push(c);
1820
- }
1821
- }), c.registerVisitor({
1822
- from: "AlternateContent",
1823
- to: null
1824
- });
1825
- let ie = (e) => {
1826
- h = e.getSource(), e.copyTo("topLeft", $, "topLeftCell");
1827
- let t = ye(e.getAttribute("defaultGridColor")), n = e.getAttribute("colorId");
1828
- n === null || t || (e.getSource().gridLineColor = "index" + parseFloat(n)), e.copyTo("showZeros", X), e.copyTo("showFormulas", X), e.copyTo("zoomScale", Z), e.copyTo("showRowHeaders", X, "showRowColHeaders"), e.copyTo("showColumnHeaders", X, "showRowColHeaders"), e.copyTo("showRowGridlines", X, "showGridLines"), e.copyTo("showColumnGridlines", X, "showGridLines"), e.copyTo("rightToLeft", X);
1829
- };
1830
- c.registerVisitor({
1831
- from: "sheetView",
1832
- to: "view",
1833
- openTag: (e) => {
1834
- ie(e);
1835
- },
1836
- closeTag: () => {
1837
- h = null;
1838
- }
1839
- }), c.registerVisitor({
1840
- from: "customSheetViews",
1841
- to: "customSheetViews",
1842
- openTag: (e) => {
1843
- e.setSource([]);
1844
- }
1845
- }), c.registerVisitor({
1846
- from: "customSheetView",
1847
- to: [],
1848
- openTag: (e) => {
1849
- ie(e);
1850
- },
1851
- closeTag: () => {
1852
- h = null;
1853
- }
1854
- }), c.registerVisitor({
1855
- from: "selection",
1856
- to: "selection",
1857
- openTag: (e) => {
1858
- if (!h) return;
1859
- e.copyTo("cell", $, "activeCell"), e.copyTo("rangeIndex", Z, "activeCellId");
1860
- let t = e.getAttribute("activeCell"), n = e.getAttribute("sqref");
1861
- n && n !== t && (e.getSource().ranges = n.trim().split(/\s+/));
1862
- }
1863
- }), c.registerVisitor({
1864
- from: "pane",
1865
- to: null,
1866
- openTag: (e) => {
1867
- if (h && e.getAttribute("state") === "frozen") {
1868
- let t = {};
1869
- h.freezePanes = t, e.copyToObject(t, "topLeft", $, "topLeftCell");
1870
- let n = (h.topLeft ? d.fastStringToCell(h.topLeft) : void 0) ?? {
1871
- colIndex: 0,
1872
- rowIndex: 0
1873
- }, r = {
1874
- colIndex: 0,
1875
- rowIndex: 0
1876
- };
1877
- e.copyToObject(r, "colIndex", Z, "xSplit"), e.copyToObject(r, "rowIndex", Z, "ySplit");
1878
- let i = {
1879
- colIndex: n.colIndex + r.colIndex,
1880
- rowIndex: n.rowIndex + r.rowIndex
1881
- };
1882
- t.coords = d.cellToString(i);
1883
- }
1884
- }
1885
- }), c.registerVisitor({
1886
- from: "tabColor",
1887
- to: null,
1888
- openTag: (t) => {
1889
- let n = ve((e) => t.getAttribute(e));
1890
- n && (e.tabColor = n);
1891
- }
1892
- }), c.registerVisitor({
1893
- from: "pageSetUpPr",
1894
- to: "pageSetUpPr",
1895
- openTag: (e) => {}
1896
- }), c.registerVisitor({
1897
- from: "outlinePr",
1898
- to: "outlinePr",
1899
- openTag: (e) => {}
1900
- }), c.registerVisitor({
1901
- from: "pageMargins",
1902
- to: "pageMargins",
1903
- openTag: (e) => {
1904
- e.copyTo("bottom", Q), e.copyTo("footer", Q), e.copyTo("header", Q), e.copyTo("left", Q), e.copyTo("right", Q), e.copyTo("top", Q), e.copyTo("bottom", Q);
1905
- }
1906
- }), c.registerVisitor({
1907
- from: "pageSetup",
1908
- to: "pageSetup",
1909
- openTag: (e) => {
1910
- e.copyTo("blackAndWhite", X), e.copyTo("cellComments"), e.copyTo("copies", Z), e.copyTo("draft", X), e.copyTo("errors"), e.copyTo("firstPageNumber", Z), e.copyTo("fitToHeight", Z), e.copyTo("fitToWidth", Z), e.copyTo("horizontalDpi", Z), e.copyTo("orientation"), e.copyTo("pageOrder"), e.copyTo("paperSize", Z), e.copyTo("scale", Z), e.copyTo("useFirstPageNumber", X), e.copyTo("usePrinterDefaults", X), e.copyTo("verticalDpi", Z);
1911
- }
1912
- }), c.registerVisitor({
1913
- from: "printOptions",
1914
- to: "printOptions",
1915
- openTag: (e) => {
1916
- e.copyTo("gridLines", X), e.copyTo("gridLinesSet", X), e.copyTo("headings", X), e.copyTo("horizontalCentered", X), e.copyTo("verticalCentered", X);
1917
- }
1918
- }), c.registerVisitor({
1919
- from: "headerFoot",
1920
- to: "headerFoot",
1921
- openTag: (e) => {}
1922
- }), c.registerVisitor({
1923
- from: "mergeCells",
1924
- to: "merges",
1925
- openTag: (e) => {
1926
- e.setSource([]);
1927
- }
1928
- }), c.registerVisitor({
1929
- from: "dataValidations",
1930
- to: "validations",
1931
- openTag: (e) => {
1932
- e.setSource([]);
1933
- }
1934
- });
1935
- let se = {
1936
- from: "dataValidation",
1937
- to: [],
1938
- openTag: (e) => {
1939
- let t = e.getAttribute("sqref");
1940
- t &&= t.trim().split(/\s+/).join(",");
1941
- let n = {}, r = {
1942
- r: t,
1943
- v: n,
1944
- rule: {
1945
- type: e.getAttribute("type") ?? void 0,
1946
- operator: e.getAttribute("operator") ?? void 0
1947
- }
1948
- };
1949
- !0 === e.getAttribute("showDropDown", X) && (n.hideDropdown = !0), e.copyToObject(n, "alert", $, "error"), e.copyToObject(n, "alertTitle", $, "errorTitle"), e.copyToObject(n, "showAlertMessage", X, "showErrorMessage"), n.alertStyle = e.getAttribute("errorStyle") ?? "stop", e.copyToObject(n, "imeMode"), e.copyToObject(n, "prompt"), e.copyToObject(n, "promptTitle"), e.copyToObject(n, "showPromptMessage", X, "showInputMessage"), e.setSource(r);
1950
- },
1951
- closeTag: (e) => {
1952
- let t = e.getSource();
1953
- if (!t?.rule) return;
1954
- let n = re(t.rule, a);
1955
- n && (e.getAttribute("allowBlank", X) && (n.includeBlanks = !0), t.v.condition = n), delete t.rule;
1956
- }
1957
- };
1958
- c.registerVisitor(se), c.registerVisitor({
1959
- from: "formula1",
1960
- to: {},
1961
- text: (e, t) => {
1962
- let n = t.getParent().rule;
1963
- n?.type && (n.formula1 = le(e, n.type));
1964
- }
1965
- }), c.registerVisitor({
1966
- from: "formula2",
1967
- to: {},
1968
- text: (e, t) => {
1969
- let n = t.getParent().rule;
1970
- n?.type && (n.formula2 = le(e, n.type));
1971
- }
1972
- }), c.registerVisitor({
1973
- from: "picture",
1974
- to: "picture",
1975
- openTag: (e) => {
1976
- let n = e.getAttribute("r:id");
1977
- if (!n) return void console.warn("no rId found for picture", e.getPath());
1978
- let r = t(n, !0);
1979
- e.getSource().resId = r;
1980
- }
1981
- });
1982
- let y = {
1983
- from: "slicer",
1984
- to: {},
1985
- openTag: (e) => {
1986
- let n = e.getAttribute("r:id");
1987
- if (!n) return void console.warn("no rId found for picture", e.getPath());
1988
- let r = t(n)?.slicers, i = e.getParent();
1989
- i.slicers ||= {};
1990
- let a = Object.keys(r);
1991
- for (let e of a) i.slicers[e] = r[e];
1992
- }
1993
- };
1994
- c.registerVisitor(y);
1995
- let b = (e, t) => ({
1996
- from: e,
1997
- to: {},
1998
- openTag: (e) => {
1999
- e.setSource("");
2000
- },
2001
- text: (e, t) => {
2002
- t.setSource((t.getSource() ?? "") + e);
2003
- },
2004
- closeTag: (e) => {
2005
- t(String(e.getSource() ?? ""), e);
2006
- }
2007
- }), x = /* @__PURE__ */ new Map();
2008
- x.set("dataValidations", {
2009
- from: "dataValidations",
2010
- to: "validations",
2011
- openTag: (e) => {
2012
- let t = e.getParent();
2013
- e.setSource(t.validations ?? []);
2014
- },
2015
- closeTag: (e) => {
2016
- (e.getSource()?.length ?? 0) === 0 && e.setSource(void 0);
2017
- }
2018
- }), x.set("dataValidation", {
2019
- ...se,
2020
- closeTag: (e) => {
2021
- se.closeTag(e);
2022
- let t = e.getSource();
2023
- t && !t.r && (e.warn("x14 dataValidation with no xm:sqref was dropped."), e.setSource(void 0));
2024
- }
2025
- });
2026
- let ue = (e) => ({
2027
- from: e,
2028
- to: {},
2029
- openTag: (t) => {
2030
- t.setSource({
2031
- rule: t.getParent()?.rule,
2032
- key: e
2033
- });
2034
- }
2035
- });
2036
- x.set("formula1", ue("formula1")), x.set("formula2", ue("formula2")), x.set("f", b("f", (e, t) => {
2037
- let n = t.getParent(), r = n?.rule;
2038
- r && (r[n.key] = le(e, r.type));
2039
- })), x.set("sqref", b("sqref", (e, t) => {
2040
- let n = t.getParent(), r = e.trim();
2041
- n && r && (n.r = r.split(/\s+/).join(","));
2042
- }));
2043
- let S = /* @__PURE__ */ new Map(), w = [], T = /* @__PURE__ */ new Map();
2044
- T.set("conditionalFormattings", {
2045
- from: "conditionalFormattings",
2046
- transparent: !0
2047
- }), T.set("conditionalFormatting", {
2048
- from: "conditionalFormatting",
2049
- to: {},
2050
- openTag: (e) => {
2051
- e.setSource({ rules: [] });
2052
- },
2053
- closeTag: (e) => {
2054
- let t = e.getSource(), n = t?.rules ?? [];
2055
- for (let e = 0; e < n.length; e++) {
2056
- let r = n[e];
2057
- r.sqref = t.sqref, r.id ? S.set(r.id, r) : w.push(r);
2058
- }
2059
- }
2060
- }), T.set("cfRule", {
2061
- from: "cfRule",
2062
- to: {},
2063
- openTag: (e) => {
2064
- e.copyTo("id", $), e.copyTo("type", $), e.copyTo("priority", Z), e.copyTo("stopIfTrue", X), e.copyTo("operator", $), e.copyTo("text", $), e.copyTo("timePeriod", $), e.copyTo("aboveAverage", X), e.copyTo("equalAverage", X), e.copyTo("stdDev", Z), e.copyTo("bottom", X), e.copyTo("percent", X), e.copyTo("rank", Z);
2065
- },
2066
- closeTag: (e) => {
2067
- let t = e.getSource();
2068
- t && e.getParent()?.rules?.push(t);
2069
- }
2070
- }), T.set("sqref", b("sqref", (e, t) => {
2071
- let n = t.getParent(), r = e.trim();
2072
- n && r && (n.sqref = r);
2073
- })), T.set("dataBar", {
2074
- from: "dataBar",
2075
- to: {},
2076
- openTag: (e) => {
2077
- e.copyTo("minLength", Z), e.copyTo("maxLength", Z), e.copyTo("gradient", X), e.copyTo("border", X), e.copyTo("direction", $), e.copyTo("axisPosition", $), e.copyTo("negativeBarColorSameAsPositive", X), e.copyTo("negativeBarBorderColorSameAsPositive", X);
2078
- },
2079
- closeTag: (e) => {
2080
- e.getParent().dataBar = e.getSource();
2081
- }
2082
- }), T.set("iconSet", {
2083
- from: "iconSet",
2084
- to: {},
2085
- openTag: (e) => {
2086
- e.copyTo("iconSet", $), e.copyTo("custom", X), e.copyTo("reverse", X), e.copyTo("showValue", X);
2087
- },
2088
- closeTag: (e) => {
2089
- e.getParent().iconSet = e.getSource();
2090
- }
2091
- });
2092
- let me = /* @__PURE__ */ new Map();
2093
- me.set("f", b("f", (e, t) => {
2094
- let n = t.getParent();
2095
- if (!n) return;
2096
- let r = e.trim(), i = Number(r);
2097
- n.value = r.length > 0 && Number.isFinite(i) ? i : e;
2098
- })), T.set("cfvo", {
2099
- from: "cfvo",
2100
- to: {},
2101
- scope: () => me,
2102
- openTag: (e) => {
2103
- let t = e.getParent();
2104
- t.conditions ||= [];
2105
- let n = e.getSource();
2106
- t.conditions.push(n), e.copyTo("type", $), !1 === e.getAttribute("gte", X) && (n.exclusive = !0);
2107
- }
2108
- }), T.set("f", b("f", (e, t) => {
2109
- let n = t.getParent();
2110
- n && (n.formulas ??= []).push(e);
2111
- })), T.set("dxf", {
2112
- from: "dxf",
2113
- to: {},
2114
- raw: !0,
2115
- closeTag: (e) => {
2116
- if (!f) return;
2117
- let t = e.getParent();
2118
- if (!t) return;
2119
- let n = f(e.getRawXml() ?? "");
2120
- n && (t.style = n);
2121
- }
2122
- });
2123
- let E = (e) => ({
2124
- from: e,
2125
- to: {},
2126
- openTag: (t) => {
2127
- let n = ve((e) => t.getAttribute(e));
2128
- n && (t.getParent()[e] = n);
2129
- }
2130
- });
2131
- T.set("borderColor", E("borderColor")), T.set("negativeFillColor", E("negativeFillColor")), T.set("negativeBorderColor", E("negativeBorderColor")), T.set("axisColor", E("axisColor")), T.set("cfIcon", {
2132
- from: "cfIcon",
2133
- to: {},
2134
- openTag: (e) => {
2135
- let t = e.getAttribute("iconSet"), n = e.getAttribute("iconId", Z);
2136
- if (t === null || n === null) return;
2137
- let r = e.getParent();
2138
- r.icons ||= [], r.icons.push({
2139
- set: t,
2140
- id: n
2141
- });
2142
- }
2143
- });
2144
- let D = /* @__PURE__ */ new Map();
2145
- D.set("id", b("id", (e, t) => {
2146
- let n = t.getParent(), r = e.trim();
2147
- n && r && (n.x14Id = r);
2148
- }));
2149
- let O = /* @__PURE__ */ new Map();
2150
- O.set("slicerList", {
2151
- from: "slicerList",
2152
- transparent: !0
2153
- }), O.set("slicer", y);
2154
- let he = /* @__PURE__ */ new Map([
2155
- [v(oe), x],
2156
- [v(te), T],
2157
- [v(g), T],
2158
- [v(pe), D],
2159
- [v(p), O],
2160
- [v(_), O]
2161
- ]), ge = /* @__PURE__ */ new Set();
2162
- c.registerVisitor({
2163
- from: "extLst",
2164
- transparent: !0
2165
- }), c.registerVisitor({
2166
- from: "ext",
2167
- transparent: !0,
2168
- scope: (e) => {
2169
- let t = e.getAttribute("uri"), n = v(t), r = he.get(n);
2170
- if (r) return r;
2171
- if (!de.has(n) && !ge.has(n)) {
2172
- ge.add(n);
2173
- let r = fe[n];
2174
- e.warn(r ? `Extension content '${r}' (${t}) is not read; it will be lost on resave.` : `Unknown extension content (uri ${t}) is not read; it will be lost on resave.`);
2175
- }
2176
- return null;
2177
- }
2178
- }), c.registerVisitor({
2179
- from: "mergeCell",
2180
- to: [],
2181
- openTag: (e) => {
2182
- let t = e.getAttribute("ref");
2183
- e.setSource(t);
2184
- }
2185
- }), c.registerVisitor({
2186
- from: "hyperlinks",
2187
- to: "hyperlinks",
2188
- openTag: (e) => {
2189
- e.setSource([]);
2190
- }
2191
- }), c.registerVisitor({
2192
- from: "hyperlink",
2193
- to: [],
2194
- openTag: (e) => {
2195
- let n = e.getAttribute("r:id"), r = e.getAttribute("ref");
2196
- if (!r) return void console.warn("No ref found for hyperlink");
2197
- e.setKey(r);
2198
- let i = n ? t(n) : "";
2199
- if (typeof i != "string") return void console.warn("Invalid address ", i);
2200
- i.endsWith("\\") && (i = i.substring(0, i.length - 1));
2201
- let a = e.getAttribute("location");
2202
- if (a && (i += "#" + a), !i) return void console.warn("No address found for hyperlink. r:id", n);
2203
- let o, s = e.getAttribute("tooltip");
2204
- o = s ? {
2205
- address: i,
2206
- screenTip: s
2207
- } : i, e.setSource({
2208
- r,
2209
- v: o
2210
- });
2211
- }
2212
- }), c.registerVisitor({
2213
- from: "drawing",
2214
- to: "movables",
2215
- openTag: (e) => {
2216
- let n = e.getAttribute("r:id");
2217
- if (!n) return;
2218
- let r = t(n);
2219
- r ? e.setSource(r.movables) : console.warn("no drawing found for rId", n);
2220
- }
2221
- }), c.registerVisitor({
2222
- from: "tableParts",
2223
- to: "tables",
2224
- openTag: (e) => {
2225
- e.setSource([]);
2226
- }
2227
- }), c.registerVisitor({
2228
- from: "tablePart",
2229
- to: [],
2230
- openTag: (e) => {
2231
- let n = e.getAttribute("r:id");
2232
- if (!n) return;
2233
- let r = t(n);
2234
- r ? e.setSource(r) : console.warn("no table found for rId", n);
2235
- }
2236
- });
2237
- let _e = (e, t) => {
2238
- t.conditions?.length && (e.stops = ne(t)), t.minLength !== void 0 && (e.minLength = t.minLength), t.maxLength !== void 0 && (e.maxLength = t.maxLength), (t.gradient ?? 1) && (e.gradient = !0), t.border && t.borderColor && (e.borderColor = t.borderColor), !t.negativeBarColorSameAsPositive && t.negativeFillColor && (e.negativeFillColor = t.negativeFillColor), !(t.negativeBarBorderColorSameAsPositive ?? 1) && t.negativeBorderColor && (e.negativeBorderColor = t.negativeBorderColor), t.axisColor && (e.axisColor = t.axisColor), t.axisPosition !== "middle" && t.axisPosition !== "none" || (e.axisPosition = t.axisPosition), t.direction !== "leftToRight" && t.direction !== "rightToLeft" || (e.direction = t.direction);
2239
- }, be = (e, t) => {
2240
- t.conditions?.length && (e.stops = ne(t)), t.iconSet && t.iconSet !== e.iconSet && (e.iconSet = t.iconSet), t.icons?.length && (e.icon = t.icons), t.reverse !== void 0 && (e.reverse = t.reverse), t.showValue !== void 0 && (e.showValue = t.showValue);
2241
- }, k = (e) => {
2242
- if (!e.sqref) return null;
2243
- let t = e.sqref.split(/\s+/).join(",");
2244
- if (e.type === "iconSet") {
2245
- if (!e.iconSet) return null;
2246
- let n = {
2247
- type: u.ScaleType.IconSet,
2248
- stops: []
2249
- };
2250
- return be(n, e.iconSet), {
2251
- r: t,
2252
- v: { scale: n },
2253
- priority: e.priority
2254
- };
2255
- }
2256
- let n = ce(e, a);
2257
- if (!n) return null;
2258
- let r = { condition: n };
2259
- return e.style && (r.style = e.style), e.stopIfTrue && (r.stopIfTrue = !0), {
2260
- r: t,
2261
- v: r,
2262
- priority: e.priority
2263
- };
2264
- };
2265
- c.registerVisitor({
2266
- from: "worksheet",
2267
- to: {},
2268
- openTag: (e) => {},
2269
- closeTag: (e) => {
2270
- let t = e.getSource(), n = t?.conditionals;
2271
- if (n) for (let e = 0; e < n.length; e++) {
2272
- let t = n[e], r = t.x14Id;
2273
- if (!r) continue;
2274
- delete t.x14Id;
2275
- let i = S.get(r);
2276
- if (!i) continue;
2277
- S.delete(r);
2278
- let a = t.v?.scale;
2279
- i.dataBar && a?.type === u.ScaleType.DataBar ? _e(a, i.dataBar) : i.iconSet && a?.type === u.ScaleType.IconSet && be(a, i.iconSet);
2280
- }
2281
- let r = [...S.values(), ...w], i = /* @__PURE__ */ new Set(), o = 0;
2282
- for (let e = 0; e < r.length; e++) {
2283
- let a = k(r[e]);
2284
- a ? (n || (n = [], t.conditionals = n), n.push(a)) : (i.add(r[e].type ?? "unknown"), o++);
2285
- }
2286
- if (o > 0) {
2287
- let e = [...i].map((e) => `'${e}'`).join(", ");
2288
- a?.(o === 1 ? `An x14-only conditional formatting rule (type ${e}) is not read and will be lost on resave.` : `${o} x14-only conditional formatting rules (types ${e}) are not read and will be lost on resave.`);
2289
- }
2290
- if (n) {
2291
- n.length > 1 && n.sort((e, t) => (e.priority ?? Infinity) - (t.priority ?? Infinity));
2292
- for (let e = 0; e < n.length; e++) delete n[e].priority;
2293
- }
2294
- }
2295
- }), c.registerVisitor({
2296
- from: "customProperties",
2297
- to: "customProperties",
2298
- openTag: (e) => {
2299
- e.setSource([]);
2300
- },
2301
- closeTag: (e) => {
2302
- let t = e.getSource();
2303
- t.length > 0 && (e.getParent().customProperties = t);
2304
- }
2305
- }), c.registerVisitor({
2306
- from: "customPr",
2307
- to: {},
2308
- openTag: (e) => {
2309
- let n = e.getParent();
2310
- e.copyTo("name");
2311
- let r = e.getAttribute("r:id");
2312
- if (!r) return void console.warn("no rId found for customProperties", e.getPath());
2313
- let i = t(r, !0), a = e.getSource();
2314
- a.resId = i, n.push(a);
2315
- }
2316
- }), c.registerVisitor({
2317
- from: "sheetProtection",
2318
- to: "protection",
2319
- openTag: (e) => {
2320
- let t = !1;
2321
- if (e.hasAttribute("sheet") && X(e.getAttribute("sheet")) && (t = !0), !t) return void e.setSource(void 0);
2322
- let n = (e) => !0 === e || e === "1" || e === "on" || e === "true" || !1 !== e && e !== "0" && e !== "off" && e !== "false" && null;
2323
- e.copyTo("autoTable", n), e.copyTo("deleteColumns", n), e.copyTo("formatCells", n), e.copyTo("formatColumns", n), e.copyTo("formatRows", n), e.copyTo("insertColumns", n), e.copyTo("insertHyperlinks", n), e.copyTo("insertRows", n), e.copyTo("objects", n), e.copyTo("pivotTables", n), e.copyTo("scenarios", n), e.copyTo("selectLockedCells", n), e.copyTo("selectUnlockedCells", n), e.copyTo("sort", n);
2324
- let r = {};
2325
- e.copyToObject(r, "hash", $, "hashValue"), e.copyToObject(r, "algorithm", $, "algorithmName"), e.copyToObject(r, "salt", $, "saltValue"), e.copyToObject(r, "spinCount", Z), Object.keys(r).length > 0 && (e.getSource().password = r);
2326
- }
2327
- }), c.registerVisitor({
2328
- from: "protectedRanges",
2329
- to: "protectedRanges",
2330
- openTag: (e) => {
2331
- e.setSource([]);
2332
- }
2333
- }), c.registerVisitor({
2334
- from: "protectedRange",
2335
- to: [],
2336
- openTag: (e) => {
2337
- let t = e.getAttribute("sqref");
2338
- t &&= t.trim().split(/\s+/).join(",");
2339
- let n = {}, r = {
2340
- r: t,
2341
- v: n
2342
- };
2343
- e.copyToObject(n, "name"), e.copyToObject(n, "securityDescriptor");
2344
- let i = {};
2345
- e.copyToObject(i, "hash", $, "hashValue"), e.copyToObject(i, "algorithm", $, "algorithmName"), e.copyToObject(i, "salt", $, "saltValue"), e.copyToObject(i, "spinCount", Z), Object.keys(i).length > 0 && (n.password = i), e.setSource(r);
2346
- },
2347
- closeTag: (e) => {
2348
- let t = e.getSource();
2349
- t?.r && t.v.name || e.setSource(void 0);
2350
- }
2351
- }), c.registerVisitor({
2352
- from: "sheetFormatPr",
2353
- to: "sheetFormatPr",
2354
- openTag: (t) => {
2355
- t.copyToObject(e, "defaultColSize", Q, "defaultColWidth"), t.copyToObject(e, "outlineLevelCol", Z, "outlineLevelCol");
2356
- let n = t.getAttribute("customHeight");
2357
- n !== "1" && n !== "true" || t.copyToObject(e, "defaultRowSize", Q, "defaultRowHeight"), t.copyToObject(e, "outlineLevelRow", Z, "outlineLevelRow");
2358
- }
2359
- }), c.registerVisitor({
2360
- from: "cols",
2361
- to: "cols",
2362
- openTag: (e) => {
2363
- e.setSource([]);
2364
- }
2365
- }), c.registerVisitor({
2366
- from: "col",
2367
- to: [],
2368
- openTag: (e) => {
2369
- let t = e.getSource(), n = e.getAttribute("min"), r = e.getAttribute("max"), i = n === void 0 ? 0 : parseInt(n) - 1, a = r === void 0 ? i : parseInt(r) - 1;
2370
- t.r = d.runToString(i, a, !0);
2371
- let o = {};
2372
- t.v = o, e.copyToObject(o, "sz", Q, "width"), e.copyToObject(o, "csz", X, "customWidth"), e.copyToObject(o, "h", X, "hidden"), e.copyToObject(o, "l", Z, "outlineLevel"), e.copyToObject(o, "s", Z, "style");
2373
- }
2374
- }), c.registerVisitor({
2375
- from: "oleObjects",
2376
- to: null,
2377
- openTag: (e) => {
2378
- e.warn("'OLE Objects' are not supported.");
2379
- }
2380
- });
2381
- let xe = !1, Se = !1, A = 0, j = "", Ce = (e) => {
2382
- let t = e.indexOf(":");
2383
- return t === -1 ? e : e.slice(t + 1);
2384
- };
2385
- return ht(m, e, c.createEventHandler(e, () => {}, a), a, void 0, {
2386
- onOpenTag: (e) => {
2387
- xe = !0;
2388
- let t = Ce(e.name);
2389
- t === "t" || t === "v" ? A === 0 && (Se = !0) : t !== "rPh" && t !== "phoneticPr" || A++;
2390
- },
2391
- onText: (e) => {
2392
- Se && (j += e);
2393
- },
2394
- onCloseTag: (e) => {
2395
- let t = Ce(e.name);
2396
- t === "t" || t === "v" ? Se = !1 : t !== "rPh" && t !== "phoneticPr" || A > 0 && A--;
2397
- },
2398
- onEnd: () => {
2399
- if (!xe) return;
2400
- let e = n(ae(j));
2401
- return xe = !1, Se = !1, A = 0, j = "", e;
2402
- },
2403
- onError: (e) => {}
2404
- }, s);
2405
- })(e, (e, t = !1) => Ae(e, s, t) ?? null, Re, m, 0, (e, t) => {
2406
- let n = t ? `${t} (${s})` : s;
2407
- k.push([e, n]);
2408
- }, 0, M), r = await L.getTextStream(s, N);
2409
- if (r) try {
2410
- await R.parseStream(r, t, { xmlns: !1 });
2411
- } catch (e) {
2412
- throw console.warn(`Error parsing sheet: '${s}'`, e), Error(`Error parsing sheet: '${s}'`, { cause: e });
2413
- }
2414
- let i, o = Oe(s, a), c = /* @__PURE__ */ new Map();
2415
- if (o) {
2416
- let t;
2417
- if (o.forEach((e, t) => {
2418
- e.type === "http://schemas.microsoft.com/office/2017/10/relationships/threadedComment" && (i = Ae(t, s, !1, a)?.comments, i && i.forEach((e) => {
2419
- let t = e.v;
2420
- c.set(t.id, e);
2421
- }));
2422
- }), o.forEach((e, n) => {
2423
- e.type === "http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments" && (t = Ae(n, s, !1, a));
2424
- }), t || i) {
2425
- let r = i ?? [], a = t?.authors, o = t?.comments, s = o ? o.length : 0;
2426
- if (o) for (let e = 0; e < s; e++) {
2427
- let t = o[e];
2428
- if (!t) continue;
2429
- let i = t.v, s = a && i.personId !== void 0 ? a[i.personId] : i.personId;
2430
- if (s && s.startsWith("tc=") && (s = he(s.substring(3)), c.has(s))) continue;
2431
- let l = Ne({ displayName: s }), u = {
2432
- id: n.uuidV4(),
2433
- personId: l.id,
2434
- done: !1,
2435
- asNote: !0,
2436
- content: i.content
2437
- };
2438
- r.push({
2439
- r: t.r,
2440
- v: u
2441
- });
2442
- }
2443
- e.comments = r;
2444
- }
2445
- }
2446
- })());
2447
- } else if (o.type === "http://schemas.openxmlformats.org/officeDocument/2006/relationships/externalLink") {
2448
- let t = D(s, e, I, F, V);
2449
- if (t && Object.keys(t).length !== 0) {
2450
- let e = t, n = [];
2451
- Oe(s, a)?.forEach((e) => {
2452
- e.targetMode === "External" && e.type && e.target && n.push({
2453
- type: e.type,
2454
- target: e.target
2455
- });
2456
- }), e.identity = n, h = e;
2457
- } else h = null;
2458
- } else h = i ? ge(s, e, (e, t) => {
2459
- let n = x.add({ source: { buffer: e } });
2460
- return n.addReference(xe), Se.add(n), E.toResourceId(n);
2461
- }, V) : D(s, e, I, F, V);
2462
- return h;
2463
- };
2464
- O("coreprops", t, e, I, F), O("extprops", t, e, I, F);
2465
- let z = /* @__PURE__ */ new Map(), je = /* @__PURE__ */ new Map(), Me = O("people", t, e, I, F), B = null;
2466
- if (Me.size > 0 && (B = Me.entries().next()?.value?.[1]?.persons, B)) {
2467
- let e = B.length;
2468
- for (let t = 0; t < e; t++) {
2469
- let e = B[t];
2470
- z.set(e.id, e), e.displayName !== void 0 && je.set(e.displayName, e);
2471
- }
2472
- }
2473
- let Ne = (e) => {
2474
- if (!e) return;
2475
- if (e.id && z.has(e.id)) return z.get(e.id);
2476
- let t = e.displayName;
2477
- if (!e.id) {
2478
- if (t) {
2479
- let e = je.get(t);
2480
- if (e) return e;
2481
- }
2482
- e.id = n.uuidV4();
2483
- }
2484
- let r = z.get(e.id);
2485
- if (r) return r;
2486
- let i = e;
2487
- return z.set(e.id, i), t && je.set(t, i), B ||= [], B.push(i), i;
2488
- }, V = {
2489
- paramMap: M,
2490
- getRefs: Oe,
2491
- getRef: Ae,
2492
- parsedRefs: P,
2493
- addPerson: Ne,
2494
- serializeElement: ke
2495
- }, Pe = [];
2496
- if (r) {
2497
- let e = await L.getTextStream(r, N);
2498
- if (e) {
2499
- let t = (() => {
2500
- let e = !1, t = !1, n = 0, i = "";
2501
- return {
2502
- onOpenTag: (r) => {
2503
- let a = gt(r.name);
2504
- a === "t" ? e && n === 0 && (t = !0) : a === "si" ? (e = !0, i = "", n = 0) : a !== "rPh" && a !== "phoneticPr" || n++;
2505
- },
2506
- onText: (e) => {
2507
- t && (i += e);
2508
- },
2509
- onCloseTag: (r) => {
2510
- let a = gt(r.name);
2511
- a === "t" ? t = !1 : a === "si" ? (((e) => {
2512
- Pe.push(e);
2513
- })(ae(i)), e = !1, i = "") : a !== "rPh" && a !== "phoneticPr" || n > 0 && n--;
2514
- },
2515
- onError: (e) => {
2516
- ((e) => {
2517
- k.push([e, r]);
2518
- })(`Error parsing shared strings: ${e?.message ?? e}`);
2519
- }
2520
- };
2521
- })();
2522
- try {
2523
- await R.parseStream(e, t, { xmlns: !1 });
2524
- } catch (e) {
2525
- throw console.warn(`Error parsing shared strings: '${r}'`, e), Error(`Error parsing shared strings: '${r}'`, { cause: e });
2526
- }
2527
- }
2528
- }
2529
- S?.mark("shared-strings");
2530
- let Fe = Pe.length, Ie = /* @__PURE__ */ new Map(), Le = Fe, Re = (e) => {
2531
- let t = Ie.get(e);
2532
- if (t !== void 0) return t;
2533
- let n = Le;
2534
- return Ie.set(e, Le++), Pe.push(e), n;
2535
- }, ze = [];
2536
- t.slicersCache = ze;
2537
- let Be = L.getNames(), Ve = Be.length;
2538
- for (let e = 0; e < Ve; e++) {
2539
- let t = Be[e];
2540
- t && t.startsWith("xl/slicerCache") && ze.push(`/${t}`);
2541
- }
2542
- let H = O("slicersCache", t, e, I, F, V), U = /* @__PURE__ */ new Map();
2543
- H.forEach((e) => {
2544
- let t = e.name;
2545
- delete e.name, U.set(t, e);
2546
- }), M.set("slicerCaches", U), O("richstructure", t, e, I, F, V), O("richdata", t, e, I, F, V);
2547
- let W = O("themes", t, e, I, F, V), He = null;
2548
- if (W && W.entries) {
2549
- let e = W.entries().next();
2550
- e?.value?.[1] && (He = e.value[1]);
2551
- }
2552
- let G = new s(He), K = O("styles", t, e, I, F, V).entries().next()?.value?.[1];
2553
- K &&= JSON.parse(i.JSONStableStringify(K));
2554
- let Ue = O("workbooks", t, e, I, F, V);
2555
- S?.mark("side-parts-json"), await Promise.all(De), j && we > 0 && (j(Ce, Ce), await new Promise((e) => setTimeout(e, 0))), S?.mark("sheets");
2556
- let q = {
2557
- ...Ue.entries().next().value?.[1],
2558
- styles: K,
2559
- theme: G.toJSON()
2560
- };
2561
- if (Pe.length > 0 && (q.strings = Pe), B && B.length > 0 && (q.people = B), m) {
2562
- let e = L.getEntry("xl/vbaProject.bin");
2563
- if (e) try {
2564
- let { VBAProject: t } = await import("./Chq4BwbjH0sbIkJN2.js"), n = t.extract(e);
2565
- n ? (m?.(n), q.vba = n) : k.push(["Unable to parse VBA project.", "xl/vbaProject.bin"]);
2566
- } catch (e) {
2567
- k.push([`Error extracting VBA: ${e?.message ?? e}`, "xl/vbaProject.bin"]);
2568
- }
2569
- }
2570
- let J = null, We = {
2571
- ...y,
2572
- resources: x,
2573
- json: q,
2574
- formulaTransform: T(() => J?.getCalculation())
2575
- };
2576
- We.disableLoadAutoFit === void 0 && (We.disableLoadAutoFit = !1), S?.mark("json-assembled");
2577
- let Y = new f(We);
2578
- if (J = Y, S?.mark("workbook-constructed"), Te.length > 0) {
2579
- await Y.whenCalculationReady();
2580
- let e = /* @__PURE__ */ new Map(), t = q.sheets ?? [], n = Y.getSheets().getItems();
2581
- for (let r = 0; r < t.length; r++) {
2582
- let i = t[r]?.sheet, a = n[r];
2583
- i && a && e.set(i, a);
2584
- }
2585
- ((e, t, n) => {
2586
- if (t.length === 0) return;
2587
- let r = e.getCalculation().getFunctions(), i = /* @__PURE__ */ new Map(), a = (e) => {
2588
- let t = i.get(e);
2589
- return t === void 0 && (t = r.getByName(e) !== null, i.set(e, t)), t;
2590
- }, o = /* @__PURE__ */ new Map();
2591
- for (let e of t) {
2592
- let t = o.get(e.sheet);
2593
- t || (t = [], o.set(e.sheet, t)), t.push(e);
2594
- }
2595
- for (let [e, t] of o) {
2596
- let r = n.get(e);
2597
- if (!r) continue;
2598
- let i = (e, t) => `${e},${t}`, o = /* @__PURE__ */ new Set();
2599
- for (let e of t) e.formula === null && o.add(i(e.rowIndex, e.colIndex));
2600
- for (let e of t) {
2601
- if (e.formula === null) continue;
2602
- let t = ut(e.formula), n = !0;
2603
- for (let e of t) if (!a(e)) {
2604
- n = !1;
2605
- break;
2606
- }
2607
- if (!n) continue;
2608
- let s = [], c = [[e.rowIndex, e.colIndex]], l = /* @__PURE__ */ new Set([i(e.rowIndex, e.colIndex)]);
2609
- for (; c.length > 0;) {
2610
- let [e, t] = c.pop(), n = [
2611
- [e + 1, t],
2612
- [e - 1, t],
2613
- [e, t + 1],
2614
- [e, t - 1]
2615
- ];
2616
- for (let [e, t] of n) {
2617
- let n = i(e, t);
2618
- !l.has(n) && o.has(n) && (l.add(n), s.push([e, t]), c.push([e, t]));
2619
- }
2620
- }
2621
- for (let [e, t] of s) o.delete(i(e, t)), r.getRange({
2622
- rowStart: e,
2623
- colStart: t,
2624
- rowEnd: e,
2625
- colEnd: t
2626
- }).clear();
2627
- r.getRange({
2628
- rowStart: e.rowIndex,
2629
- colStart: e.colIndex,
2630
- rowEnd: e.rowIndex,
2631
- colEnd: e.colIndex
2632
- }).setValue("=" + e.formula);
2633
- }
2634
- }
2635
- })(Y, Te, e);
2636
- }
2637
- if (Se.forEach((e) => {
2638
- e.deleteReference(xe);
2639
- }), E.endPersist(), ue) {
2640
- se(ue);
2641
- let e = /* @__PURE__ */ new Map(), t = 0;
2642
- for (let n of L.getNames()) {
2643
- let r = L.getEntry(n);
2644
- if (!r) continue;
2645
- let i = L.getRawEntry(n), a = i ? {
2646
- data: r,
2647
- uncompressedSize: L.uncompressedSize(n),
2648
- raw: {
2649
- compressedData: i.data,
2650
- compressionMethod: i.compressionMethod,
2651
- signature: i.signature
2652
- }
2653
- } : {
2654
- data: r,
2655
- uncompressedSize: L.uncompressedSize(n)
2656
- };
2657
- e.set(n, a), t += r.byteLength;
2658
- }
2659
- if (t > 67108864) k.push([`Source package too large to retain (${t} bytes, limit ${b}); unmodeled parts will be dropped on save.`, "SourcePackage"]);
2660
- else if (e.size > 0) {
2661
- let t = new w(e);
2662
- ne(ue, t);
2663
- let n = Y.getSheets().getItems(), r = Y.getTransactions().addListener({ onCommitEnd: (e) => {
2664
- let n = e.getOperation()?.name;
2665
- n !== "insertCells" && n !== "deleteCells" || t.markStructuralChange();
2666
- } }), i = Y.addListeners({ onSheetsChange: () => {
2667
- let e = Y.getSheets().getItems();
2668
- (e.length !== n.length || e.some((e, t) => e !== n[t])) && t.markStructuralChange(), n = e;
2669
- } });
2670
- Y.addListeners({ onClose: () => {
2671
- r(), i(), se(ue);
2672
- } });
2673
- }
2674
- }
2675
- if (k.length && A?.onWarning) for (let e of k) {
2676
- let [t, n] = e;
2677
- A.onWarning(t, n);
2678
- }
2679
- return S && !0 === ie && console.table(S.toTable()), Y;
2680
- } catch (e) {
2681
- let t = "Unable to parse XLSX.";
2682
- throw e instanceof r && (t = "Unable to open XLSX. There are too many rows or columns."), Error(t, { cause: e });
2683
- } finally {
2684
- await L.close().catch(() => {});
2685
- }
2686
- };
2687
- export { bt as readXLSX };