@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
@@ -0,0 +1,3563 @@
1
+ /**
2
+ * @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.8.0-beta.10
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 { C as e, P as t, V as n, q as r, u as i } from "./CMxbiQ5J79M3n1tk.mjs";
8
+ import { W as a, m as o } from "./CWoPWWRwMgkGPFFP.mjs";
9
+ import { i as s, l as c } from "./BAH_cWcQEIBKWnl6.mjs";
10
+ import { $ as l, K as u, Ut as d, _t as f, it as p, s as m, zt as h } from "./BNIInlJQbJjH8B6G.mjs";
11
+ import { m as g, r as _ } from "./DZRmBfjn2TgOTu5e.mjs";
12
+ import { $ as v, A as y, At as b, B as ee, Dt as x, I as te, J as ne, K as re, Kt as S, L as ie, Mt as ae, N as oe, Nt as se, O as ce, Ot as le, R as C, Rt as w, S as T, Tt as E, Ut as ue, V as D, W as O, Wt as de, X as fe, Y as k, _ as A, bt as pe, c as j, ct as me, d as M, ft as he, gt as N, h as ge, ht as _e, j as ve, m as ye, mt as P, nn as F, nt as I, ot as L, r as R, rn as be, ut as xe, xt as Se, z as Ce } from "./By3a43qwWICwXRmw.mjs";
13
+ var we = {
14
+ ascending: "ascending",
15
+ descending: "descending",
16
+ natural: "dataSource"
17
+ };
18
+ function Te(e, t) {
19
+ if (!t) return null;
20
+ for (let n = 0; n < e.length; n++) if (e[n].id !== void 0 && String(e[n].id) === t) return e[n];
21
+ let n = Number(t);
22
+ return Number.isInteger(n) && n >= 1 && n <= e.length ? e[n - 1] : null;
23
+ }
24
+ function Ee(e, t, n) {
25
+ let r = {
26
+ ...t,
27
+ source: n
28
+ };
29
+ if (e.caption !== void 0 && e.caption !== e.sourceName && (r.caption = e.caption), !1 === e.showCaption && (r.hiddenCaption = !0), e.columnCount !== void 0 && e.columnCount > 1 && (r.columnCount = e.columnCount), e.rowHeight !== void 0) {
30
+ let t = Math.round(e.rowHeight / 9525);
31
+ t > 0 && t !== 27 && (r.rowHeight = t);
32
+ }
33
+ e.style && e.style !== "SlicerStyleLight1" && (r.style = e.style);
34
+ let i = e.sortOrder ? we[e.sortOrder] : void 0;
35
+ return i && i !== "ascending" && (r.sortOrder = i), e.crossFilter && e.crossFilter !== "showItemsWithDataAtTop" && (r.crossFilter = e.crossFilter), e.lockedPosition && (r.lockedPosition = !0), !1 === e.customListSort && (r.disabledCustomListSort = !0), e.cacheName && (r.cacheName = e.cacheName), e.startItem && (r.startItem = e.startItem), e.level !== void 0 && (r.level = e.level), e.uid && (r.uid = e.uid), r;
36
+ }
37
+ var De = (e, t, n) => {
38
+ let r = `Unable to read '${e}': ${t?.message ?? t}`;
39
+ n?.onWarning ? n.onWarning(r, e) : console.warn(r);
40
+ }, z = (e, n, r, i, a = null) => {
41
+ if (!e) return null;
42
+ let o = e;
43
+ o.startsWith("/") && (o = o.substring(1));
44
+ let s = a?.parsedRefs?.get(e);
45
+ if (s !== void 0) return s;
46
+ let c = n(o);
47
+ if (!c) return null;
48
+ let l = c.content;
49
+ try {
50
+ let n = new TextDecoder().decode(l), o = r.parseFromString(n, "text/xml"), s = i.transform(o, e, a ?? t.EmptyObject);
51
+ return a?.parsedRefs?.set(e, s), s;
52
+ } catch (t) {
53
+ De(e, t, a);
54
+ }
55
+ return null;
56
+ }, Oe = (e, t, n, r, i = null) => {
57
+ if (!e) return null;
58
+ let a = z(e, t, n, r, i);
59
+ if (!a) return null;
60
+ let o = /* @__PURE__ */ new Map(), s = Object.keys(a), c = s.length;
61
+ for (let e = 0; e < c; e++) {
62
+ let t = s[e], n = a[t];
63
+ o.set(t, n);
64
+ }
65
+ return o;
66
+ }, B = (e, t, n, r, i, a = null) => {
67
+ let o = /* @__PURE__ */ new Map(), s = t[e], c = s ? s.length : 0;
68
+ for (let e = 0; e < c; e++) {
69
+ let t = s[e];
70
+ if (!t) continue;
71
+ let c = t;
72
+ c.startsWith("/") && (c = c.substring(1));
73
+ let l = z(c, n, r, i, a);
74
+ o.set(c, l);
75
+ }
76
+ return o;
77
+ }, ke = (e) => {
78
+ let t = e.split(/\/+/);
79
+ return t.reduce((e, t, n) => (t === "." ? e.splice(n, 1) : t === ".." && e.splice(n - 1, 2), e), t).join("/");
80
+ }, Ae = Object.freeze([
81
+ "lt1",
82
+ "dk1",
83
+ "lt2",
84
+ "dk2",
85
+ "accent1",
86
+ "accent2",
87
+ "accent3",
88
+ "accent4",
89
+ "accent5",
90
+ "accent6",
91
+ "hlink",
92
+ "folHlink"
93
+ ]), V = (e, t = "auto") => {
94
+ let n, r = e("auto");
95
+ r === void 0 || r !== "1" && r !== "true" || (n = t);
96
+ let i = e("indexed");
97
+ i && (n = i === "64" ? "auto" : `index${i}`);
98
+ let a = e("rgb");
99
+ a && (n = a.toLowerCase(), a.length !== 8 || a.startsWith("FF") || (n = "FF" + a.substring(2, a.length)));
100
+ let s = e("theme");
101
+ s && (n = Ae[Number(s)]);
102
+ let c = e("tint");
103
+ if (c && (n += ` ${o.AdjustmentType.ETint} ${parseFloat(c)}`), n) return n;
104
+ }, je = (e) => e && e.replace(/^\{([\s\S]+)\}$/, "$1"), Me = /* @__PURE__ */ new Uint8Array(), H = class e {
105
+ constructor(e, t, n) {
106
+ this.buffers = /* @__PURE__ */ new Map(), this.zip = e, this.entries = t, this.rawBuffer = n;
107
+ }
108
+ static normalize(e) {
109
+ return e.startsWith("/") ? e.slice(1) : e;
110
+ }
111
+ static async create(t) {
112
+ let n = t instanceof Blob ? Me : t instanceof Uint8Array ? t : new Uint8Array(t), r = t instanceof Blob ? new y(t) : new I(n), i = new ve(r), a = /* @__PURE__ */ new Map();
113
+ for (let e of await i.getEntries()) e.directory || a.set(e.filename, e);
114
+ return new e(i, a, n);
115
+ }
116
+ getNames() {
117
+ return [...this.entries.keys()];
118
+ }
119
+ has(t) {
120
+ return this.entries.has(e.normalize(t));
121
+ }
122
+ uncompressedSize(t) {
123
+ return this.entries.get(e.normalize(t))?.uncompressedSize ?? 0;
124
+ }
125
+ async getBuffer(t) {
126
+ let n = e.normalize(t), r = this.buffers.get(n);
127
+ if (r) return r;
128
+ let i = this.entries.get(n);
129
+ if (!i) return null;
130
+ let a = await i.getData(new v());
131
+ return this.buffers.set(n, a), a;
132
+ }
133
+ async prefetch(e) {
134
+ let t = [];
135
+ for (let [n, r] of this.entries) !this.buffers.has(n) && e(n, r) && t.push(r.getData(new v()).then((e) => {
136
+ this.buffers.set(n, e);
137
+ }));
138
+ await Promise.all(t);
139
+ }
140
+ getEntry(t) {
141
+ return this.buffers.get(e.normalize(t)) ?? null;
142
+ }
143
+ async getTextStream(t, n) {
144
+ let r = this.entries.get(e.normalize(t));
145
+ if (!r) return null;
146
+ let i = new TransformStream();
147
+ r.getData(i.writable).catch(() => {});
148
+ let a = i.readable.getReader(), o = new TextDecoder("utf-8");
149
+ return new ReadableStream({ async pull(e) {
150
+ let { value: t, done: r } = await a.read();
151
+ if (r) {
152
+ let t = o.decode();
153
+ t && e.enqueue(t), e.close();
154
+ return;
155
+ }
156
+ n?.(t.byteLength);
157
+ let i = o.decode(t, { stream: !0 });
158
+ i && e.enqueue(i);
159
+ } }).getReader();
160
+ }
161
+ getRawEntry(t) {
162
+ let n = this.entries.get(e.normalize(t));
163
+ if (!n || n.encrypted || n.crc32 === void 0) return null;
164
+ let r = n.offset;
165
+ if (r + 30 > this.rawBuffer.byteLength) return null;
166
+ let i = new DataView(this.rawBuffer.buffer, this.rawBuffer.byteOffset + r, 30);
167
+ if (i.getUint32(0, !0) !== 67324752) return null;
168
+ let a = r + 30 + i.getUint16(26, !0) + i.getUint16(28, !0), o = a + n.compressedSize;
169
+ return o > this.rawBuffer.byteLength ? null : {
170
+ data: this.rawBuffer.subarray(a, o),
171
+ compressionMethod: n.compressionMethod,
172
+ signature: n.crc32
173
+ };
174
+ }
175
+ async close() {
176
+ await this.zip.close();
177
+ }
178
+ }, U = class {
179
+ constructor(e) {
180
+ this._sink = e, this._samples = [], this._t0 = Ne(), this._tPrev = this._t0, this._heapPrev = Pe();
181
+ }
182
+ mark(e) {
183
+ let t = Ne(), n = Pe(), r = {
184
+ label: e,
185
+ tMs: t - this._t0,
186
+ dtMs: t - this._tPrev,
187
+ heapBytes: n,
188
+ dHeapBytes: n !== void 0 && this._heapPrev !== void 0 ? n - this._heapPrev : void 0,
189
+ rssBytes: Fe()
190
+ };
191
+ this._tPrev = t, this._heapPrev = n, this._samples.push(r), this._sink?.(r);
192
+ }
193
+ samples() {
194
+ return this._samples;
195
+ }
196
+ toTable() {
197
+ return this._samples.map((e) => ({
198
+ phase: e.label,
199
+ tMs: Math.round(e.tMs),
200
+ dtMs: Math.round(e.dtMs),
201
+ heapMB: e.heapBytes === void 0 ? "—" : Ie(e.heapBytes / 1048576),
202
+ dHeapMB: e.dHeapBytes === void 0 ? "—" : Ie(e.dHeapBytes / 1048576),
203
+ rssMB: e.rssBytes === void 0 ? "—" : Ie(e.rssBytes / 1048576)
204
+ }));
205
+ }
206
+ }, Ne = typeof performance == "object" && typeof performance.now == "function" ? () => performance.now() : () => Date.now();
207
+ function Pe() {
208
+ let e = typeof performance == "object" ? performance.memory : void 0;
209
+ if (e && typeof e.usedJSHeapSize == "number") return e.usedJSHeapSize;
210
+ let t = globalThis.process;
211
+ return typeof t == "object" && typeof t.memoryUsage == "function" ? t.memoryUsage().heapUsed : void 0;
212
+ }
213
+ function Fe() {
214
+ let e = globalThis.process;
215
+ if (typeof e == "object" && typeof e.memoryUsage == "function") return e.memoryUsage().rss;
216
+ }
217
+ function Ie(e) {
218
+ return Math.round(10 * e) / 10;
219
+ }
220
+ var Le = ":A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿", Re = `-${Le}.0-9·̀-ͯ‿-⁀`, ze = (RegExp(`^[${Le}]$`, "u"), RegExp(`^[${Re}]$`, "u"), RegExp(`^[${Le}][${Re}]*$`, "u")), Be = (RegExp(`^[${Re}]+$`, "u"), [
221
+ 32,
222
+ 10,
223
+ 13,
224
+ 9
225
+ ]);
226
+ function Ve(e) {
227
+ 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;
228
+ }
229
+ var He = ":A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿", Ue = `-${He}.0-9·̀-ͯ‿-⁀`;
230
+ RegExp(`^[${He}]$`, "u"), RegExp(`^[${Ue}]$`, "u"), RegExp(`^[${He}][${Ue}]*$`, "u"), RegExp(`^[${Ue}]+$`, "u");
231
+ var We = "A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-῿‌-‍⁰-↏Ⰰ-⿯、-퟿豈-﷏ﷰ-�𐀀-󯿿", Ge = `-${We}.0-9·̀-ͯ‿-⁀`, Ke = (RegExp(`^[${We}]$`, "u"), RegExp(`^[${Ge}]$`, "u"), RegExp(`^[${We}][${Ge}]*$`, "u"));
232
+ function qe(e) {
233
+ 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;
234
+ }
235
+ var Je, W = function(e) {
236
+ return e === 32 || e === 10 || e === 13 || e === 9;
237
+ }, Ye = function(e) {
238
+ return e >= 32 && e <= 55295 || e === 10 || e === 13 || e === 9 || e >= 57344 && e <= 65533 || e >= 65536 && e <= 1114111;
239
+ }, Xe = Ve, Ze = function(e) {
240
+ return Ve(e) || e >= 48 && e <= 57 || e === 45 || e === 46 || e === 183 || e >= 768 && e <= 879 || e >= 8255 && e <= 8256;
241
+ }, Qe = Be, $e = ze, et = function(e) {
242
+ return e >= 1 && e <= 55295 || e >= 57344 && e <= 65533 || e >= 65536 && e <= 1114111;
243
+ }, tt = qe, G = function(e) {
244
+ return qe(e) || e === 45 || e === 46 || e >= 48 && e <= 57 || e === 183 || e >= 768 && e <= 879 || e >= 8255 && e <= 8256;
245
+ }, nt = Ke, rt = "http://www.w3.org/XML/1998/namespace", it = "http://www.w3.org/2000/xmlns/", at = {
246
+ __proto__: null,
247
+ xml: rt,
248
+ xmlns: it
249
+ }, ot = {
250
+ __proto__: null,
251
+ amp: "&",
252
+ gt: ">",
253
+ lt: "<",
254
+ quot: "\"",
255
+ apos: "'"
256
+ }, K = -1, st = -2, q = 13, ct = 33, lt = 10, ut = 60, dt = 61, J = 62, Y = 63, ft = 93, pt = (e) => e === 34 || e === 39, mt = [34, 39], ht = [
257
+ ...mt,
258
+ 91,
259
+ J
260
+ ], gt = [
261
+ ...mt,
262
+ ut,
263
+ ft
264
+ ], _t = [
265
+ dt,
266
+ Y,
267
+ ...Qe
268
+ ], vt = [
269
+ ...Qe,
270
+ J,
271
+ 38,
272
+ ut
273
+ ];
274
+ function yt(e, t, n) {
275
+ switch (t) {
276
+ case "xml":
277
+ n !== rt && e.fail(`xml prefix must be bound to ${rt}.`);
278
+ break;
279
+ case "xmlns": n !== it && e.fail(`xmlns prefix must be bound to ${it}.`);
280
+ }
281
+ switch (n) {
282
+ case it:
283
+ e.fail(t === "" ? `the default namespace may not be set to ${n}.` : `may not assign a prefix (even "xmlns") to the URI ${it}.`);
284
+ break;
285
+ case rt: switch (t) {
286
+ case "xml": break;
287
+ case "":
288
+ e.fail(`the default namespace may not be set to ${n}.`);
289
+ break;
290
+ default: e.fail("may not assign the xml namespace to another prefix.");
291
+ }
292
+ }
293
+ }
294
+ var bt, xt = (e) => nt.test(e), St = (e) => $e.test(e), Ct = {
295
+ xmldecl: "xmlDeclHandler",
296
+ text: "textHandler",
297
+ processinginstruction: "piHandler",
298
+ doctype: "doctypeHandler",
299
+ comment: "commentHandler",
300
+ opentagstart: "openTagStartHandler",
301
+ attribute: "attributeHandler",
302
+ opentag: "openTagHandler",
303
+ closetag: "closeTagHandler",
304
+ cdata: "cdataHandler",
305
+ error: "errorHandler",
306
+ end: "endHandler",
307
+ ready: "readyHandler"
308
+ }, wt = class {
309
+ get closed() {
310
+ return this._closed;
311
+ }
312
+ constructor(e) {
313
+ this.i = 0, this.prevI = 0, this.opt = e ?? {}, this.fragmentOpt = !!this.opt.fragment;
314
+ let t = this.xmlnsOpt = !!this.opt.xmlns;
315
+ if (this.trackPosition = !1 !== this.opt.position, this.fileName = this.opt.fileName, t) {
316
+ this.nameStartCheck = tt, this.nameCheck = G, this.isName = xt, this.processAttribs = this.processAttribsNS, this.pushAttrib = this.pushAttribNS, this.ns = {
317
+ __proto__: null,
318
+ ...at
319
+ };
320
+ let e = this.opt.additionalNamespaces;
321
+ e != null && (function(e, t) {
322
+ for (let n of Object.keys(t)) yt(e, n, t[n]);
323
+ }(this, e), Object.assign(this.ns, e));
324
+ } else this.nameStartCheck = Xe, this.nameCheck = Ze, this.isName = St, this.processAttribs = this.processAttribsPlain, this.pushAttrib = this.pushAttribPlain;
325
+ this.stateTable = [
326
+ this.sBegin,
327
+ this.sBeginWhitespace,
328
+ this.sDoctype,
329
+ this.sDoctypeQuote,
330
+ this.sDTD,
331
+ this.sDTDQuoted,
332
+ this.sDTDOpenWaka,
333
+ this.sDTDOpenWakaBang,
334
+ this.sDTDComment,
335
+ this.sDTDCommentEnding,
336
+ this.sDTDCommentEnded,
337
+ this.sDTDPI,
338
+ this.sDTDPIEnding,
339
+ this.sText,
340
+ this.sEntity,
341
+ this.sOpenWaka,
342
+ this.sOpenWakaBang,
343
+ this.sComment,
344
+ this.sCommentEnding,
345
+ this.sCommentEnded,
346
+ this.sCData,
347
+ this.sCDataEnding,
348
+ this.sCDataEnding2,
349
+ this.sPIFirstChar,
350
+ this.sPIRest,
351
+ this.sPIBody,
352
+ this.sPIEnding,
353
+ this.sXMLDeclNameStart,
354
+ this.sXMLDeclName,
355
+ this.sXMLDeclEq,
356
+ this.sXMLDeclValueStart,
357
+ this.sXMLDeclValue,
358
+ this.sXMLDeclSeparator,
359
+ this.sXMLDeclEnding,
360
+ this.sOpenTag,
361
+ this.sOpenTagSlash,
362
+ this.sAttrib,
363
+ this.sAttribName,
364
+ this.sAttribNameSawWhite,
365
+ this.sAttribValue,
366
+ this.sAttribValueQuoted,
367
+ this.sAttribValueClosed,
368
+ this.sAttribValueUnquoted,
369
+ this.sCloseTag,
370
+ this.sCloseTagSawWhite
371
+ ], this._init();
372
+ }
373
+ _init() {
374
+ 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 = [];
375
+ let { fragmentOpt: e } = this;
376
+ this.state = e ? q : 0, this.reportedTextBeforeRoot = this.reportedTextAfterRoot = this.closedRoot = this.sawRoot = e, this.xmlDeclPossible = !e, this.xmlDeclExpects = ["version"], this.entityReturnState = void 0;
377
+ let { defaultXMLVersion: t } = this.opt;
378
+ if (t === void 0) {
379
+ if (!0 === this.opt.forceXMLVersion) throw Error("forceXMLVersion set but defaultXMLVersion is not set");
380
+ t = "1.0";
381
+ }
382
+ this.setXMLVersion(t), this.positionAtNewLine = 0, this.doctype = !1, this._closed = !1, this.xmlDecl = {
383
+ version: void 0,
384
+ encoding: void 0,
385
+ standalone: void 0
386
+ }, this.line = 1, this.column = 0, this.ENTITIES = Object.create(ot), this.readyHandler?.();
387
+ }
388
+ get position() {
389
+ return this.chunkPosition + this.i;
390
+ }
391
+ get columnIndex() {
392
+ return this.position - this.positionAtNewLine;
393
+ }
394
+ on(e, t) {
395
+ this[Ct[e]] = t;
396
+ }
397
+ off(e) {
398
+ this[Ct[e]] = void 0;
399
+ }
400
+ makeError(e) {
401
+ let t = this.fileName ?? "";
402
+ return this.trackPosition && (t.length > 0 && (t += ":"), t += `${this.line}:${this.column}`), t.length > 0 && (t += ": "), Error(t + e);
403
+ }
404
+ fail(e) {
405
+ let t = this.makeError(e), n = this.errorHandler;
406
+ if (n === void 0) throw t;
407
+ return n(t), this;
408
+ }
409
+ write(e) {
410
+ if (this.closed) return this.fail("cannot write after close.");
411
+ let t = !1;
412
+ e === null ? (t = !0, e = "") : typeof e == "object" && (e = e.toString()), this.carriedFromPrevious !== void 0 && (e = `${this.carriedFromPrevious}${e}`, this.carriedFromPrevious = void 0);
413
+ let n = e.length, r = e.charCodeAt(n - 1);
414
+ !t && (r === 13 || r >= 55296 && r <= 56319) && (this.carriedFromPrevious = e[n - 1], n--, e = e.slice(0, n));
415
+ let { stateTable: i } = this;
416
+ for (this.chunk = e, this.i = 0; this.i < n;) i[this.state].call(this);
417
+ return this.chunkPosition += n, t ? this.end() : this;
418
+ }
419
+ close() {
420
+ return this.write(null);
421
+ }
422
+ getCode10() {
423
+ let e = this.chunk, t = this.i;
424
+ if (this.prevI = t, this.i++, t >= e.length) return K;
425
+ let n = e.charCodeAt(t);
426
+ if (this.column++, n < 55296) {
427
+ if (n >= 32 || n === 9) return n;
428
+ switch (n) {
429
+ case lt: return this.line++, this.column = 0, this.positionAtNewLine = this.position, lt;
430
+ case 13: return e.charCodeAt(t + 1) === lt && (this.i = t + 2), this.line++, this.column = 0, this.positionAtNewLine = this.position, st;
431
+ default: return this.fail("disallowed character."), n;
432
+ }
433
+ }
434
+ if (n > 56319) return n >= 57344 && n <= 65533 || this.fail("disallowed character."), n;
435
+ let r = 65536 + 1024 * (n - 55296) + (e.charCodeAt(t + 1) - 56320);
436
+ return this.i = t + 2, r > 1114111 && this.fail("disallowed character."), r;
437
+ }
438
+ getCode11() {
439
+ let { chunk: e, i: t } = this;
440
+ if (this.prevI = t, this.i = t + 1, t >= e.length) return K;
441
+ let n = e.charCodeAt(t);
442
+ if (this.column++, n < 55296) {
443
+ if (n > 31 && n < 127 || n > 159 && n !== 8232 || n === 9) return n;
444
+ switch (n) {
445
+ case lt: return this.line++, this.column = 0, this.positionAtNewLine = this.position, lt;
446
+ case 13: {
447
+ let n = e.charCodeAt(t + 1);
448
+ n !== lt && n !== 133 || (this.i = t + 2);
449
+ }
450
+ case 133:
451
+ case 8232: return this.line++, this.column = 0, this.positionAtNewLine = this.position, st;
452
+ default: return this.fail("disallowed character."), n;
453
+ }
454
+ }
455
+ if (n > 56319) return n >= 57344 && n <= 65533 || this.fail("disallowed character."), n;
456
+ let r = 65536 + 1024 * (n - 55296) + (e.charCodeAt(t + 1) - 56320);
457
+ return this.i = t + 2, r > 1114111 && this.fail("disallowed character."), r;
458
+ }
459
+ getCodeNorm() {
460
+ let e = this.getCode();
461
+ return e === st ? lt : e;
462
+ }
463
+ unGet() {
464
+ this.i = this.prevI, this.column--;
465
+ }
466
+ captureTo(e) {
467
+ let { i: t } = this, { chunk: n } = this;
468
+ for (;;) {
469
+ let r = this.getCode(), i = r === st, a = i ? lt : r;
470
+ if (a === K || e.includes(a)) return this.text += n.slice(t, this.prevI), a;
471
+ i && (this.text += `${n.slice(t, this.prevI)}\n`, t = this.i);
472
+ }
473
+ }
474
+ captureToChar(e) {
475
+ let { i: t } = this, { chunk: n } = this;
476
+ for (;;) {
477
+ let r = this.getCode();
478
+ switch (r) {
479
+ case st:
480
+ this.text += `${n.slice(t, this.prevI)}\n`, t = this.i, r = lt;
481
+ break;
482
+ case K: return this.text += n.slice(t), !1;
483
+ }
484
+ if (r === e) return this.text += n.slice(t, this.prevI), !0;
485
+ }
486
+ }
487
+ captureNameChars() {
488
+ let { chunk: e, i: t } = this;
489
+ for (;;) {
490
+ let n = this.getCode();
491
+ if (n === K) return this.name += e.slice(t), K;
492
+ if (!Ze(n)) return this.name += e.slice(t, this.prevI), n === st ? lt : n;
493
+ }
494
+ }
495
+ skipSpaces() {
496
+ for (;;) {
497
+ let e = this.getCodeNorm();
498
+ if (e === K || !W(e)) return e;
499
+ }
500
+ }
501
+ setXMLVersion(e) {
502
+ this.currentXMLVersion = e, e === "1.0" ? (this.isChar = Ye, this.getCode = this.getCode10) : (this.isChar = et, this.getCode = this.getCode11);
503
+ }
504
+ sBegin() {
505
+ this.chunk.charCodeAt(0) === 65279 && (this.i++, this.column++), this.state = 1;
506
+ }
507
+ sBeginWhitespace() {
508
+ let e = this.i, t = this.skipSpaces();
509
+ switch (this.prevI !== e && (this.xmlDeclPossible = !1), t) {
510
+ case ut:
511
+ if (this.state = 15, this.text.length !== 0) throw Error("no-empty text at start");
512
+ break;
513
+ case K: break;
514
+ default: this.unGet(), this.state = q, this.xmlDeclPossible = !1;
515
+ }
516
+ }
517
+ sDoctype() {
518
+ let e = this.captureTo(ht);
519
+ switch (e) {
520
+ case J:
521
+ this.doctypeHandler?.(this.text), this.text = "", this.state = q, this.doctype = !0;
522
+ break;
523
+ case K: break;
524
+ default: this.text += String.fromCodePoint(e), e === 91 ? this.state = 4 : pt(e) && (this.state = 3, this.q = e);
525
+ }
526
+ }
527
+ sDoctypeQuote() {
528
+ let e = this.q;
529
+ this.captureToChar(e) && (this.text += String.fromCodePoint(e), this.q = null, this.state = 2);
530
+ }
531
+ sDTD() {
532
+ let e = this.captureTo(gt);
533
+ e !== K && (this.text += String.fromCodePoint(e), e === ft ? this.state = 2 : e === ut ? this.state = 6 : pt(e) && (this.state = 5, this.q = e));
534
+ }
535
+ sDTDQuoted() {
536
+ let e = this.q;
537
+ this.captureToChar(e) && (this.text += String.fromCodePoint(e), this.state = 4, this.q = null);
538
+ }
539
+ sDTDOpenWaka() {
540
+ let e = this.getCodeNorm();
541
+ switch (this.text += String.fromCodePoint(e), e) {
542
+ case 33:
543
+ this.state = 7, this.openWakaBang = "";
544
+ break;
545
+ case Y:
546
+ this.state = 11;
547
+ break;
548
+ default: this.state = 4;
549
+ }
550
+ }
551
+ sDTDOpenWakaBang() {
552
+ let e = String.fromCodePoint(this.getCodeNorm()), t = this.openWakaBang += e;
553
+ this.text += e, t !== "-" && (this.state = t === "--" ? 8 : 4, this.openWakaBang = "");
554
+ }
555
+ sDTDComment() {
556
+ this.captureToChar(45) && (this.text += "-", this.state = 9);
557
+ }
558
+ sDTDCommentEnding() {
559
+ let e = this.getCodeNorm();
560
+ this.text += String.fromCodePoint(e), this.state = e === 45 ? 10 : 8;
561
+ }
562
+ sDTDCommentEnded() {
563
+ let e = this.getCodeNorm();
564
+ this.text += String.fromCodePoint(e), e === J ? this.state = 4 : (this.fail("malformed comment."), this.state = 8);
565
+ }
566
+ sDTDPI() {
567
+ this.captureToChar(Y) && (this.text += "?", this.state = 12);
568
+ }
569
+ sDTDPIEnding() {
570
+ let e = this.getCodeNorm();
571
+ this.text += String.fromCodePoint(e), e === J && (this.state = 4);
572
+ }
573
+ sText() {
574
+ this.tags.length === 0 ? this.handleTextOutsideRoot() : this.handleTextInRoot();
575
+ }
576
+ sEntity() {
577
+ let { i: e } = this, { chunk: t } = this;
578
+ t: for (;;) switch (this.getCode()) {
579
+ case st:
580
+ this.entity += `${t.slice(e, this.prevI)}\n`, e = this.i;
581
+ break;
582
+ case 59: {
583
+ let n, { entityReturnState: r } = this, i = this.entity + t.slice(e, this.prevI);
584
+ this.state = r, i === "" ? (this.fail("empty entity name."), n = "&;") : (n = this.parseEntity(i), this.entity = ""), r === q && this.textHandler === void 0 || (this.text += n);
585
+ break t;
586
+ }
587
+ case K:
588
+ this.entity += t.slice(e);
589
+ break t;
590
+ }
591
+ }
592
+ sOpenWaka() {
593
+ let e = this.getCode();
594
+ if (Xe(e)) this.state = 34, this.unGet(), this.xmlDeclPossible = !1;
595
+ else switch (e) {
596
+ case 47:
597
+ this.state = 43, this.xmlDeclPossible = !1;
598
+ break;
599
+ case 33:
600
+ this.state = 16, this.openWakaBang = "", this.xmlDeclPossible = !1;
601
+ break;
602
+ case Y:
603
+ this.state = 23;
604
+ break;
605
+ default: this.fail("disallowed character in tag name"), this.state = q, this.xmlDeclPossible = !1;
606
+ }
607
+ }
608
+ sOpenWakaBang() {
609
+ switch (this.openWakaBang += String.fromCodePoint(this.getCodeNorm()), this.openWakaBang) {
610
+ case "[CDATA[":
611
+ 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 = "";
612
+ break;
613
+ case "--":
614
+ this.state = 17, this.openWakaBang = "";
615
+ break;
616
+ case "DOCTYPE":
617
+ this.state = 2, (this.doctype || this.sawRoot) && this.fail("inappropriately located doctype declaration."), this.openWakaBang = "";
618
+ break;
619
+ default: this.openWakaBang.length >= 7 && this.fail("incorrect syntax.");
620
+ }
621
+ }
622
+ sComment() {
623
+ this.captureToChar(45) && (this.state = 18);
624
+ }
625
+ sCommentEnding() {
626
+ let e = this.getCodeNorm();
627
+ e === 45 ? (this.state = 19, this.commentHandler?.(this.text), this.text = "") : (this.text += `-${String.fromCodePoint(e)}`, this.state = 17);
628
+ }
629
+ sCommentEnded() {
630
+ let e = this.getCodeNorm();
631
+ e === J ? this.state = q : (this.fail("malformed comment."), this.text += `--${String.fromCodePoint(e)}`, this.state = 17);
632
+ }
633
+ sCData() {
634
+ this.captureToChar(ft) && (this.state = 21);
635
+ }
636
+ sCDataEnding() {
637
+ let e = this.getCodeNorm();
638
+ e === ft ? this.state = 22 : (this.text += `]${String.fromCodePoint(e)}`, this.state = 20);
639
+ }
640
+ sCDataEnding2() {
641
+ let e = this.getCodeNorm();
642
+ switch (e) {
643
+ case J:
644
+ this.cdataHandler?.(this.text), this.text = "", this.state = q;
645
+ break;
646
+ case ft:
647
+ this.text += "]";
648
+ break;
649
+ default: this.text += `]]${String.fromCodePoint(e)}`, this.state = 20;
650
+ }
651
+ }
652
+ sPIFirstChar() {
653
+ let e = this.getCodeNorm();
654
+ this.nameStartCheck(e) ? (this.piTarget += String.fromCodePoint(e), this.state = 24) : e === Y || W(e) ? (this.fail("processing instruction without a target."), this.state = e === Y ? 26 : 25) : (this.fail("disallowed character in processing instruction name."), this.piTarget += String.fromCodePoint(e), this.state = 24);
655
+ }
656
+ sPIRest() {
657
+ let { chunk: e, i: t } = this;
658
+ for (;;) {
659
+ let n = this.getCodeNorm();
660
+ if (n === K) return void (this.piTarget += e.slice(t));
661
+ if (!this.nameCheck(n)) {
662
+ this.piTarget += e.slice(t, this.prevI);
663
+ let r = n === Y;
664
+ r || W(n) ? this.piTarget === "xml" ? (this.xmlDeclPossible || this.fail("an XML declaration must be at the start of the document."), this.state = r ? ct : 27) : this.state = r ? 26 : 25 : (this.fail("disallowed character in processing instruction name."), this.piTarget += String.fromCodePoint(n));
665
+ break;
666
+ }
667
+ }
668
+ }
669
+ sPIBody() {
670
+ if (this.text.length === 0) {
671
+ let e = this.getCodeNorm();
672
+ e === Y ? this.state = 26 : W(e) || (this.text = String.fromCodePoint(e));
673
+ } else this.captureToChar(Y) && (this.state = 26);
674
+ }
675
+ sPIEnding() {
676
+ let e = this.getCodeNorm();
677
+ if (e === J) {
678
+ let { piTarget: e } = this;
679
+ e.toLowerCase() === "xml" && this.fail("the XML declaration must appear at the start of the document."), this.piHandler?.({
680
+ target: e,
681
+ body: this.text
682
+ }), this.piTarget = this.text = "", this.state = q;
683
+ } else e === Y ? this.text += "?" : (this.text += `?${String.fromCodePoint(e)}`, this.state = 25);
684
+ this.xmlDeclPossible = !1;
685
+ }
686
+ sXMLDeclNameStart() {
687
+ let e = this.skipSpaces();
688
+ e === Y ? this.state = ct : e !== K && (this.state = 28, this.name = String.fromCodePoint(e));
689
+ }
690
+ sXMLDeclName() {
691
+ let e = this.captureTo(_t);
692
+ if (e === Y) return this.state = ct, this.name += this.text, this.text = "", void this.fail("XML declaration is incomplete.");
693
+ if (W(e) || e === dt) {
694
+ if (this.name += this.text, this.text = "", !this.xmlDeclExpects.includes(this.name)) switch (this.name.length) {
695
+ case 0:
696
+ this.fail("did not expect any more name/value pairs.");
697
+ break;
698
+ case 1:
699
+ this.fail(`expected the name ${this.xmlDeclExpects[0]}.`);
700
+ break;
701
+ default: this.fail(`expected one of ${this.xmlDeclExpects.join(", ")}`);
702
+ }
703
+ this.state = e === dt ? 30 : 29;
704
+ }
705
+ }
706
+ sXMLDeclEq() {
707
+ let e = this.getCodeNorm();
708
+ if (e === Y) return this.state = ct, void this.fail("XML declaration is incomplete.");
709
+ W(e) || (e !== dt && this.fail("value required."), this.state = 30);
710
+ }
711
+ sXMLDeclValueStart() {
712
+ let e = this.getCodeNorm();
713
+ if (e === Y) return this.state = ct, void this.fail("XML declaration is incomplete.");
714
+ W(e) || (pt(e) ? this.q = e : (this.fail("value must be quoted."), this.q = 32), this.state = 31);
715
+ }
716
+ sXMLDeclValue() {
717
+ let e = this.captureTo([this.q, Y]);
718
+ if (e === Y) return this.state = ct, this.text = "", void this.fail("XML declaration is incomplete.");
719
+ if (e === K) return;
720
+ let t = this.text;
721
+ switch (this.text = "", this.name) {
722
+ case "version": {
723
+ this.xmlDeclExpects = ["encoding", "standalone"];
724
+ let e = t;
725
+ this.xmlDecl.version = e, /^1\.[0-9]+$/.test(e) ? this.opt.forceXMLVersion || this.setXMLVersion(e) : this.fail("version number must match /^1\\.[0-9]+$/.");
726
+ break;
727
+ }
728
+ case "encoding":
729
+ /^[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;
730
+ break;
731
+ case "standalone": t !== "yes" && t !== "no" && this.fail("standalone value must match \"yes\" or \"no\"."), this.xmlDeclExpects = [], this.xmlDecl.standalone = t;
732
+ }
733
+ this.name = "", this.state = 32;
734
+ }
735
+ sXMLDeclSeparator() {
736
+ let e = this.getCodeNorm();
737
+ e === Y ? this.state = ct : (W(e) || (this.fail("whitespace required."), this.unGet()), this.state = 27);
738
+ }
739
+ sXMLDeclEnding() {
740
+ this.getCodeNorm() === J ? (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 = q) : this.fail("The character ? is disallowed anywhere in XML declarations."), this.xmlDeclPossible = !1;
741
+ }
742
+ sOpenTag() {
743
+ let e = this.captureNameChars();
744
+ if (e === K) return;
745
+ let t = this.tag = {
746
+ name: this.name,
747
+ attributes: Object.create(null)
748
+ };
749
+ 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) {
750
+ case J:
751
+ this.openTag();
752
+ break;
753
+ case 47:
754
+ this.state = 35;
755
+ break;
756
+ default: W(e) || this.fail("disallowed character in tag name."), this.state = 36;
757
+ }
758
+ }
759
+ sOpenTagSlash() {
760
+ this.getCode() === J ? this.openSelfClosingTag() : (this.fail("forward-slash in opening tag not followed by >."), this.state = 36);
761
+ }
762
+ sAttrib() {
763
+ let e = this.skipSpaces();
764
+ e !== K && (Xe(e) ? (this.unGet(), this.state = 37) : e === J ? this.openTag() : e === 47 ? this.state = 35 : this.fail("disallowed character in attribute name."));
765
+ }
766
+ sAttribName() {
767
+ let e = this.captureNameChars();
768
+ e === dt ? this.state = 39 : W(e) ? this.state = 38 : e === J ? (this.fail("attribute without value."), this.pushAttrib(this.name, this.name), this.name = this.text = "", this.openTag()) : e !== K && this.fail("disallowed character in attribute name.");
769
+ }
770
+ sAttribNameSawWhite() {
771
+ let e = this.skipSpaces();
772
+ switch (e) {
773
+ case K: return;
774
+ case dt:
775
+ this.state = 39;
776
+ break;
777
+ default: this.fail("attribute without value."), this.text = "", this.name = "", e === J ? this.openTag() : Xe(e) ? (this.unGet(), this.state = 37) : (this.fail("disallowed character in attribute name."), this.state = 36);
778
+ }
779
+ }
780
+ sAttribValue() {
781
+ let e = this.getCodeNorm();
782
+ pt(e) ? (this.q = e, this.state = 40) : W(e) || (this.fail("unquoted attribute value."), this.state = 42, this.unGet());
783
+ }
784
+ sAttribValueQuoted() {
785
+ let { q: e, chunk: t } = this, { i: n } = this;
786
+ for (;;) switch (this.getCode()) {
787
+ case e:
788
+ this.pushAttrib(this.name, this.text + t.slice(n, this.prevI)), this.name = this.text = "", this.q = null, this.state = 41;
789
+ return;
790
+ case 38:
791
+ this.text += t.slice(n, this.prevI), this.state = 14, this.entityReturnState = 40;
792
+ return;
793
+ case lt:
794
+ case st:
795
+ case 9:
796
+ this.text += `${t.slice(n, this.prevI)} `, n = this.i;
797
+ break;
798
+ case ut:
799
+ this.text += t.slice(n, this.prevI), this.fail("disallowed character.");
800
+ return;
801
+ case K:
802
+ this.text += t.slice(n);
803
+ return;
804
+ }
805
+ }
806
+ sAttribValueClosed() {
807
+ let e = this.getCodeNorm();
808
+ W(e) ? this.state = 36 : e === J ? this.openTag() : e === 47 ? this.state = 35 : Xe(e) ? (this.fail("no whitespace between attributes."), this.unGet(), this.state = 37) : this.fail("disallowed character in attribute name.");
809
+ }
810
+ sAttribValueUnquoted() {
811
+ let e = this.captureTo(vt);
812
+ switch (e) {
813
+ case 38:
814
+ this.state = 14, this.entityReturnState = 42;
815
+ break;
816
+ case ut:
817
+ this.fail("disallowed character.");
818
+ break;
819
+ case K: break;
820
+ default: this.text.includes("]]>") && this.fail("the string \"]]>\" is disallowed in char data."), this.pushAttrib(this.name, this.text), this.name = this.text = "", e === J ? this.openTag() : this.state = 36;
821
+ }
822
+ }
823
+ sCloseTag() {
824
+ let e = this.captureNameChars();
825
+ e === J ? this.closeTag() : W(e) ? this.state = 44 : e !== K && this.fail("disallowed character in closing tag.");
826
+ }
827
+ sCloseTagSawWhite() {
828
+ switch (this.skipSpaces()) {
829
+ case J:
830
+ this.closeTag();
831
+ break;
832
+ case K: break;
833
+ default: this.fail("disallowed character in closing tag.");
834
+ }
835
+ }
836
+ handleTextInRoot() {
837
+ let { i: e, forbiddenState: t } = this, { chunk: n, textHandler: r } = this;
838
+ t: for (;;) switch (this.getCode()) {
839
+ case ut:
840
+ if (this.state = 15, r !== void 0) {
841
+ let { text: t } = this, i = n.slice(e, this.prevI);
842
+ t.length === 0 ? i.length !== 0 && r(i) : (r(t + i), this.text = "");
843
+ }
844
+ t = 0;
845
+ break t;
846
+ case 38:
847
+ this.state = 14, this.entityReturnState = q, r !== void 0 && (this.text += n.slice(e, this.prevI)), t = 0;
848
+ break t;
849
+ case ft:
850
+ switch (t) {
851
+ case 0:
852
+ t = 1;
853
+ break;
854
+ case 1:
855
+ t = 2;
856
+ break;
857
+ case 2: break;
858
+ default: throw Error("impossible state");
859
+ }
860
+ break;
861
+ case J:
862
+ t === 2 && this.fail("the string \"]]>\" is disallowed in char data."), t = 0;
863
+ break;
864
+ case st:
865
+ r !== void 0 && (this.text += `${n.slice(e, this.prevI)}\n`), e = this.i, t = 0;
866
+ break;
867
+ case K:
868
+ r !== void 0 && (this.text += n.slice(e));
869
+ break t;
870
+ default: t = 0;
871
+ }
872
+ this.forbiddenState = t;
873
+ }
874
+ handleTextOutsideRoot() {
875
+ let { i: e } = this, { chunk: t, textHandler: n } = this, r = !1;
876
+ t: for (;;) {
877
+ let i = this.getCode();
878
+ switch (i) {
879
+ case ut:
880
+ if (this.state = 15, n !== void 0) {
881
+ let { text: r } = this, i = t.slice(e, this.prevI);
882
+ r.length === 0 ? i.length !== 0 && n(i) : (n(r + i), this.text = "");
883
+ }
884
+ break t;
885
+ case 38:
886
+ this.state = 14, this.entityReturnState = q, n !== void 0 && (this.text += t.slice(e, this.prevI)), r = !0;
887
+ break t;
888
+ case st:
889
+ n !== void 0 && (this.text += `${t.slice(e, this.prevI)}\n`), e = this.i;
890
+ break;
891
+ case K:
892
+ n !== void 0 && (this.text += t.slice(e));
893
+ break t;
894
+ default: W(i) || (r = !0);
895
+ }
896
+ }
897
+ 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));
898
+ }
899
+ pushAttribNS(e, t) {
900
+ let { prefix: n, local: r } = this.qName(e), i = {
901
+ name: e,
902
+ prefix: n,
903
+ local: r,
904
+ value: t
905
+ };
906
+ if (this.attribList.push(i), this.attributeHandler?.(i), n === "xmlns") {
907
+ let e = t.trim();
908
+ this.currentXMLVersion === "1.0" && e === "" && this.fail("invalid attempt to undefine prefix in XML 1.0"), this.topNS[r] = e, yt(this, r, e);
909
+ } else if (e === "xmlns") {
910
+ let e = t.trim();
911
+ this.topNS[""] = e, yt(this, "", e);
912
+ }
913
+ }
914
+ pushAttribPlain(e, t) {
915
+ let n = {
916
+ name: e,
917
+ value: t
918
+ };
919
+ this.attribList.push(n), this.attributeHandler?.(n);
920
+ }
921
+ end() {
922
+ this.sawRoot || this.fail("document must contain a root element.");
923
+ let { tags: e } = this;
924
+ for (; e.length > 0;) {
925
+ let t = e.pop();
926
+ this.fail(`unclosed tag: ${t.name}`);
927
+ }
928
+ this.state !== 0 && this.state !== q && this.fail("unexpected end.");
929
+ let { text: t } = this;
930
+ return t.length !== 0 && (this.textHandler?.(t), this.text = ""), this._closed = !0, this.endHandler?.(), this._init(), this;
931
+ }
932
+ resolve(e) {
933
+ let t = this.topNS[e];
934
+ if (t !== void 0) return t;
935
+ let { tags: n } = this;
936
+ for (let r = n.length - 1; r >= 0; r--) if (t = n[r].ns[e], t !== void 0) return t;
937
+ return t = this.ns[e], t === void 0 ? this.opt.resolvePrefix?.(e) : t;
938
+ }
939
+ qName(e) {
940
+ let t = e.indexOf(":");
941
+ if (t === -1) return {
942
+ prefix: "",
943
+ local: e
944
+ };
945
+ let n = e.slice(t + 1), r = e.slice(0, t);
946
+ return (r === "" || n === "" || n.includes(":")) && this.fail(`malformed name: ${e}.`), {
947
+ prefix: r,
948
+ local: n
949
+ };
950
+ }
951
+ processAttribsNS() {
952
+ let { attribList: e } = this, t = this.tag;
953
+ {
954
+ let { prefix: e, local: n } = this.qName(t.name);
955
+ t.prefix = e, t.local = n;
956
+ let r = t.uri = this.resolve(e) ?? "";
957
+ e !== "" && (e === "xmlns" && this.fail("tags may not have \"xmlns\" as prefix."), r === "" && (this.fail(`unbound namespace prefix: ${JSON.stringify(e)}.`), t.uri = e));
958
+ }
959
+ if (e.length === 0) return;
960
+ let { attributes: n } = t, r = /* @__PURE__ */ new Set();
961
+ for (let t of e) {
962
+ let e, i, { name: a, prefix: o, local: s } = t;
963
+ o === "" ? (e = a === "xmlns" ? it : "", 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;
964
+ }
965
+ this.attribList = [];
966
+ }
967
+ processAttribsPlain() {
968
+ let { attribList: e } = this, t = this.tag.attributes;
969
+ for (let { name: n, value: r } of e) t[n] !== void 0 && this.fail(`duplicate attribute: ${n}.`), t[n] = r;
970
+ this.attribList = [];
971
+ }
972
+ openTag() {
973
+ this.processAttribs();
974
+ let { tags: e } = this, t = this.tag;
975
+ t.isSelfClosing = !1, this.openTagHandler?.(t), e.push(t), this.state = q, this.name = "";
976
+ }
977
+ openSelfClosingTag() {
978
+ this.processAttribs();
979
+ let { tags: e } = this, t = this.tag;
980
+ t.isSelfClosing = !0, this.openTagHandler?.(t), this.closeTagHandler?.(t), (this.tag = e[e.length - 1] ?? null) === null && (this.closedRoot = !0), this.state = q, this.name = "";
981
+ }
982
+ closeTag() {
983
+ let { tags: e, name: t } = this;
984
+ if (this.state = q, this.name = "", t === "") return this.fail("weird empty close tag."), void (this.text += "</>");
985
+ let n = this.closeTagHandler, r = e.length;
986
+ for (; r-- > 0;) {
987
+ let r = this.tag = e.pop();
988
+ if (this.topNS = r.ns, n?.(r), r.name === t) break;
989
+ this.fail(`unexpected close tag: ${t}.`);
990
+ }
991
+ r === 0 ? this.closedRoot = !0 : r < 0 && (this.fail(`unmatched closing tag: ${t}.`), this.text += `</${t}>`);
992
+ }
993
+ parseEntity(e) {
994
+ if (e[0] !== "#") {
995
+ let t = this.ENTITIES[e];
996
+ return t === void 0 ? (this.fail(this.isName(e) ? "undefined entity." : "disallowed character in entity name."), `&${e};`) : t;
997
+ }
998
+ let t = NaN;
999
+ 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};`);
1000
+ }
1001
+ }, Tt = /&(#x[0-9a-fA-F]+|#[0-9]+|amp|lt|gt|quot|apos);/g, Et = {
1002
+ amp: "&",
1003
+ lt: "<",
1004
+ gt: ">",
1005
+ quot: "\"",
1006
+ apos: "'"
1007
+ }, Dt = (e, t) => {
1008
+ let n = Et[t];
1009
+ if (n !== void 0) return n;
1010
+ let r = t.charCodeAt(1) === 120 ? parseInt(t.slice(2), 16) : parseInt(t.slice(1), 10);
1011
+ return r > 0 && r <= 1114111 ? String.fromCodePoint(r) : e;
1012
+ }, Ot = (e) => {
1013
+ let t = e;
1014
+ return t.indexOf("\r") !== -1 && (t = t.replace(/\r\n?/g, "\n")), t.indexOf("&") !== -1 && (t = t.replace(Tt, Dt)), t;
1015
+ }, kt = (e) => {
1016
+ let t = e, n = t.length;
1017
+ for (let e = 0; e < n; e++) {
1018
+ let n = t.charCodeAt(e);
1019
+ if (n === 9 || n === 10 || n === 13) {
1020
+ t = t.replace(/\r\n|[\t\n\r]/g, " ");
1021
+ break;
1022
+ }
1023
+ }
1024
+ return t.indexOf("&") !== -1 && (t = t.replace(Tt, Dt)), t;
1025
+ }, At = (e) => e === 32 || e === 9 || e === 10 || e === 13, jt = class e {
1026
+ constructor() {
1027
+ this._openTagHandler = void 0, this._closeTagHandler = void 0, this._textHandler = void 0, this._cdataHandler = void 0, this._errorHandler = void 0, this._endHandler = void 0, this._scanners = null, this._carry = "", this._text = "", this._tags = [], this._sawRoot = !1, this._closed = !1;
1028
+ }
1029
+ static {
1030
+ this.NEED_MORE = -1;
1031
+ }
1032
+ static {
1033
+ this.NOT_HANDLED = -2;
1034
+ }
1035
+ static decodeText(e) {
1036
+ return Ot(e);
1037
+ }
1038
+ on(e, t) {
1039
+ switch (e) {
1040
+ case "opentag":
1041
+ this._openTagHandler = t;
1042
+ break;
1043
+ case "closetag":
1044
+ this._closeTagHandler = t;
1045
+ break;
1046
+ case "text":
1047
+ this._textHandler = t;
1048
+ break;
1049
+ case "cdata":
1050
+ this._cdataHandler = t;
1051
+ break;
1052
+ case "error":
1053
+ this._errorHandler = t;
1054
+ break;
1055
+ case "end": this._endHandler = t;
1056
+ }
1057
+ }
1058
+ setElementScanners(e) {
1059
+ if (!e || e.length === 0) return void (this._scanners = null);
1060
+ let t = Array(128);
1061
+ for (let n of e) {
1062
+ let e = n.name.charCodeAt(0);
1063
+ if (!(e < 128) || t[e] !== void 0) throw Error(`Element scanner '${n.name}' needs an ASCII first character no other scanner uses.`);
1064
+ t[e] = n;
1065
+ }
1066
+ this._scanners = t;
1067
+ }
1068
+ fail(e) {
1069
+ let t = Error(e), n = this._errorHandler;
1070
+ if (n === void 0) throw t;
1071
+ n(t);
1072
+ }
1073
+ write(e) {
1074
+ if (this._closed) return this.fail("cannot write after close."), this;
1075
+ let t = e;
1076
+ this._carry.length !== 0 && (t = this._carry + e, this._carry = "");
1077
+ let n = t.length, r = 0;
1078
+ for (; r < n;) {
1079
+ let e = t.indexOf("<", r);
1080
+ if (e === -1) return this._text += t.slice(r), this;
1081
+ e > r && (this._text += t.slice(r, e));
1082
+ let i = this._markup(t, e, n);
1083
+ if (i === -1) return this._carry = t.slice(e), this;
1084
+ r = i;
1085
+ }
1086
+ return this;
1087
+ }
1088
+ close() {
1089
+ this._carry.length !== 0 && (this.fail("unexpected end."), this._carry = ""), this._sawRoot || this.fail("document must contain a root element.");
1090
+ let e = this._tags;
1091
+ for (; e.length > 0;) {
1092
+ let t = e.pop();
1093
+ this.fail(`unclosed tag: ${t.name}`);
1094
+ }
1095
+ return this._flushText(), this._closed = !0, this._endHandler?.(), this;
1096
+ }
1097
+ _flushText() {
1098
+ let e = this._text;
1099
+ if (e.length === 0) return;
1100
+ this._text = "";
1101
+ let t = this._textHandler;
1102
+ t !== void 0 && this._tags.length !== 0 && t(Ot(e));
1103
+ }
1104
+ _markup(t, n, r) {
1105
+ if (n + 1 >= r) return -1;
1106
+ let i = t.charCodeAt(n + 1);
1107
+ if (i === 47) {
1108
+ let e = t.indexOf(">", n + 2);
1109
+ return e === -1 ? -1 : (this._flushText(), this._closeTag(t.slice(n + 2, e).trimEnd()), e + 1);
1110
+ }
1111
+ if (i === 63) {
1112
+ let e = t.indexOf("?>", n + 2);
1113
+ return e === -1 ? -1 : e + 2;
1114
+ }
1115
+ if (i === 33) {
1116
+ if (n + 4 > r) return -1;
1117
+ if (t.charCodeAt(n + 2) === 45 && t.charCodeAt(n + 3) === 45) {
1118
+ let e = t.indexOf("-->", n + 4);
1119
+ return e === -1 ? -1 : e + 3;
1120
+ }
1121
+ if (n + 9 > r) return -1;
1122
+ if (t.startsWith("[CDATA[", n + 2)) {
1123
+ let e = t.indexOf("]]>", n + 9);
1124
+ return e === -1 ? -1 : (this._flushText(), this._cdataHandler?.(t.slice(n + 9, e)), e + 3);
1125
+ }
1126
+ let e = t.indexOf("[", n + 2), i = t.indexOf(">", n + 2);
1127
+ if (i === -1) return -1;
1128
+ if (e !== -1 && e < i) {
1129
+ let n = t.indexOf("]>", e);
1130
+ return n === -1 ? -1 : n + 2;
1131
+ }
1132
+ return i + 1;
1133
+ }
1134
+ let a = this._scanners;
1135
+ if (a !== null) {
1136
+ let o = i < 128 ? a[i] : void 0;
1137
+ if (o !== void 0 && t.startsWith(o.name, n + 1)) {
1138
+ let i = n + 1 + o.name.length;
1139
+ if (i >= r) return -1;
1140
+ let a = t.charCodeAt(i);
1141
+ if (a === 62 || a === 47 || At(a)) {
1142
+ this._flushText();
1143
+ let i = o.scan(t, n, r);
1144
+ if (i !== e.NOT_HANDLED) {
1145
+ if (i !== e.NEED_MORE) {
1146
+ this._sawRoot = !0;
1147
+ let e = o.openTag;
1148
+ e !== void 0 && this._tags.push(e);
1149
+ }
1150
+ return i;
1151
+ }
1152
+ }
1153
+ }
1154
+ }
1155
+ return this._openTag(t, n, r);
1156
+ }
1157
+ _openTag(e, t, n) {
1158
+ let r = t + 1, i = 0;
1159
+ for (; r < n && (i = e.charCodeAt(r), i !== 62 && i !== 47 && !At(i));) r++;
1160
+ if (r >= n) return -1;
1161
+ let a = e.slice(t + 1, r), o = {}, s = !1;
1162
+ for (;;) {
1163
+ for (; r < n && At(i = e.charCodeAt(r));) r++;
1164
+ if (r >= n) return -1;
1165
+ if (i === 62) {
1166
+ r++;
1167
+ break;
1168
+ }
1169
+ if (i === 47) {
1170
+ if (r + 1 >= n) return -1;
1171
+ if (e.charCodeAt(r + 1) !== 62) {
1172
+ this.fail("forward-slash in opening tag not followed by >."), r++;
1173
+ continue;
1174
+ }
1175
+ s = !0, r += 2;
1176
+ break;
1177
+ }
1178
+ let t = r;
1179
+ for (; r < n && (i = e.charCodeAt(r), i !== 61 && i !== 62 && i !== 47 && !At(i));) r++;
1180
+ if (r >= n) return -1;
1181
+ let a = e.slice(t, r);
1182
+ for (; r < n && At(i = e.charCodeAt(r));) r++;
1183
+ if (r >= n) return -1;
1184
+ if (i !== 61) {
1185
+ this.fail("attribute without value.");
1186
+ continue;
1187
+ }
1188
+ for (r++; r < n && At(i = e.charCodeAt(r));) r++;
1189
+ if (r >= n) return -1;
1190
+ if (i !== 34 && i !== 39) {
1191
+ this.fail("unquoted attribute value.");
1192
+ continue;
1193
+ }
1194
+ let c = e.indexOf(i === 34 ? "\"" : "'", r + 1);
1195
+ if (c === -1) return -1;
1196
+ a !== "__proto__" && (o[a] = kt(e.slice(r + 1, c))), r = c + 1;
1197
+ }
1198
+ this._flushText(), this._sawRoot = !0;
1199
+ let c = {
1200
+ name: a,
1201
+ attributes: o,
1202
+ isSelfClosing: s
1203
+ };
1204
+ return this._openTagHandler?.(c), s ? this._closeTagHandler?.(c) : this._tags.push(c), r;
1205
+ }
1206
+ _closeTag(e) {
1207
+ if (e === "") return void this.fail("weird empty close tag.");
1208
+ let t = this._tags, n = this._closeTagHandler, r = t.length;
1209
+ for (; r-- > 0;) {
1210
+ let r = t.pop();
1211
+ if (n?.(r), r.name === e) return;
1212
+ this.fail(`unexpected close tag: ${e}.`);
1213
+ }
1214
+ this.fail(`unmatched closing tag: ${e}.`);
1215
+ }
1216
+ };
1217
+ (bt = Je ||= {}).Events = {
1218
+ XmlDecl: "xmldecl",
1219
+ Text: "text",
1220
+ ProcessingInstruction: "processinginstruction",
1221
+ Doctype: "doctype",
1222
+ Comment: "comment",
1223
+ OpenTagStart: "opentagstart",
1224
+ Attribute: "attribute",
1225
+ OpenTag: "opentag",
1226
+ CloseTag: "closetag",
1227
+ CDdata: "cdata",
1228
+ Error: "error",
1229
+ End: "end",
1230
+ Ready: "ready"
1231
+ }, bt.parseStream = async (e, t, n) => {
1232
+ if (n?.lean) return (async (e, t) => {
1233
+ let n, r = new jt();
1234
+ t.elementScanners && r.setElementScanners(t.elementScanners), t.onOpenTag && r.on("opentag", t.onOpenTag), t.onCloseTag && r.on("closetag", t.onCloseTag), t.onText && r.on("text", t.onText), t.onError && r.on("error", t.onError);
1235
+ let i = t.onEnd;
1236
+ for (i && r.on("end", () => {
1237
+ n = i();
1238
+ });;) {
1239
+ let { value: t, done: n } = await e.read();
1240
+ if (n) break;
1241
+ r.write(t);
1242
+ }
1243
+ return r.close(), n;
1244
+ })(e, t);
1245
+ let r, i = new wt({
1246
+ position: !1,
1247
+ ...n
1248
+ });
1249
+ t.onOpenTagStart && i.on(Je.Events.OpenTagStart, t.onOpenTagStart), t.onOpenTag && i.on(Je.Events.OpenTag, t.onOpenTag), t.onCloseTag && i.on(Je.Events.CloseTag, t.onCloseTag), t.onAttribute && i.on(Je.Events.Attribute, t.onAttribute), t.onText && i.on(Je.Events.Text, t.onText), t.onError && i.on(Je.Events.Error, t.onError);
1250
+ let a = t.onEnd;
1251
+ for (a && i.on(Je.Events.End, () => {
1252
+ r = a();
1253
+ });;) {
1254
+ let { value: t, done: n } = await e.read();
1255
+ if (n) break;
1256
+ i.write(t);
1257
+ }
1258
+ return i.close(), r;
1259
+ };
1260
+ var X = (e) => !0 === e || e === "1" || e === "on" || e === "true" || !1 !== e && e !== "0" && e !== "off" && e !== "false" && null, Z = (e) => {
1261
+ let t = parseInt(e);
1262
+ return isNaN(t) ? null : t;
1263
+ }, Q = (e) => {
1264
+ let t = parseFloat(e);
1265
+ return isNaN(t) ? null : t;
1266
+ }, $ = null, Mt = (e) => e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;"), Nt = (e) => Mt(e).replace(/"/g, "&quot;"), Pt = class {
1267
+ constructor() {
1268
+ this._registeredVisitors = /* @__PURE__ */ new Map();
1269
+ }
1270
+ registerVisitor(e) {
1271
+ this._registeredVisitors.set(e.from, e);
1272
+ }
1273
+ createEventHandler(e, t, n) {
1274
+ let r = this._registeredVisitors, i = [], a = [], o = null, s = null, c = null, l = null, u = [], d = {
1275
+ key: null,
1276
+ source: e,
1277
+ parent: null
1278
+ }, f = null, p = !1, m = null, h = null, g = null, _ = (e, t) => {
1279
+ let n = c.attributes[e];
1280
+ if (t) {
1281
+ if (Array.isArray(t)) {
1282
+ let e = t.length;
1283
+ for (let r = 0; r < e; r++) if (n == null || (n = t[r](n), n == null)) return;
1284
+ } else if (n == null || (n = t(n), n == null)) return;
1285
+ }
1286
+ return n;
1287
+ }, v = {
1288
+ getSource: () => f?.source ?? null,
1289
+ setSource: (e) => {
1290
+ f.source = e;
1291
+ },
1292
+ setKey: (e) => {
1293
+ f.key = e;
1294
+ },
1295
+ getFrom: () => c,
1296
+ getAttribute: (e, t) => _(e, t) ?? null,
1297
+ hasAttribute: (e) => v.getAttribute(e) !== null,
1298
+ getParent: () => {
1299
+ let e = u[u.length - 2];
1300
+ return e.parent ?? e.source;
1301
+ },
1302
+ getPath: () => {
1303
+ let e = [], t = a.length;
1304
+ for (let n = 0; n < t; n++) e.push(a[n].local);
1305
+ return e.join("\\");
1306
+ },
1307
+ parseAttribute: _,
1308
+ getRawXml: () => g,
1309
+ copyToObject: (e, t, n, r) => {
1310
+ let i = _(r ?? t, n);
1311
+ i !== void 0 && (e[t] = i);
1312
+ },
1313
+ copyTo: (e, t, n) => {
1314
+ let r = _(n ?? e, t);
1315
+ r !== void 0 && (f.source[e] = r);
1316
+ },
1317
+ warn: (e, t) => {
1318
+ n ? n(e, void 0, t?.onceKey) : console.warn(e);
1319
+ }
1320
+ };
1321
+ return {
1322
+ onOpenTag: (e) => {
1323
+ let t = e.name, n = t.indexOf(":");
1324
+ if (n !== -1 && (t = t.slice(n + 1)), m) return m.push(((e) => {
1325
+ let t = e.attributes ?? {}, n = `<${e.name}`;
1326
+ for (let e in t) {
1327
+ let r = t[e];
1328
+ n += ` ${e}="${Nt(typeof r == "string" ? r : r?.value ?? "")}"`;
1329
+ }
1330
+ return n + ">";
1331
+ })(e)), o = {
1332
+ local: t,
1333
+ tag: e,
1334
+ destination: null
1335
+ }, a.push(o), s = t, void (c = e);
1336
+ let g = (i.length > 0 ? i[i.length - 1] : r).get(t);
1337
+ if (o = {
1338
+ local: t,
1339
+ visitor: g,
1340
+ tag: e,
1341
+ destination: null
1342
+ }, p) return a.push(o), s = t, void (c = e);
1343
+ l = o?.visitor ?? null, s = t, c = e;
1344
+ let _ = !!g && g.to === null;
1345
+ if (g && !_ && g.scope) {
1346
+ let e = g.scope(v);
1347
+ e === null ? _ = !0 : e && (i.push(e), o.pushedScope = !0);
1348
+ }
1349
+ g && (a.length === 0 ? (f = d, o.destination = f, o.pushedDestination = !0, u.push(f)) : _ ? (f = null, o.destination = null) : g.transparent ? o.destination = f : (f = {
1350
+ key: null,
1351
+ source: {},
1352
+ parent: null
1353
+ }, o.destination = f, o.pushedDestination = !0, u.push(f))), a.push(o), p = _;
1354
+ let y = l?.openTag?.(v);
1355
+ y !== void 0 && (f.parent = y), g?.raw && !_ && (m = [], h = o);
1356
+ },
1357
+ onCloseTag: (e) => {
1358
+ let t = e.name, r = t.indexOf(":");
1359
+ if (r !== -1 && (t = t.slice(r + 1)), t !== s) throw Error(`mismatch open/close tag: '${t}'/'${s}'`);
1360
+ let _ = !1;
1361
+ if (m) {
1362
+ if (a[a.length - 1] !== h) return m.push(`</${e.name}>`), a.pop(), o = a[a.length - 1] ?? null, s = o?.local ?? null, void (c = o?.tag ?? null);
1363
+ g = m.join(""), m = null, h = null, _ = !0;
1364
+ }
1365
+ p || l?.closeTag?.(v), _ && (g = null);
1366
+ let y = a.pop() ?? null;
1367
+ o = a[a.length - 1] ?? null, y?.pushedScope && i.pop();
1368
+ let b = y?.destination;
1369
+ if (b && y.pushedDestination) {
1370
+ u.pop(), f = u[u.length - 1] ?? d;
1371
+ let e = y.visitor;
1372
+ e && e.to && b.source !== void 0 && (Array.isArray(e.to) ? f.source.push ? f.source.push(b.source) : n?.(`Unable to parse array for ${e.from} at ${v.getPath()}`) : b.key ? f.source[b.key] = b.source : typeof e.to == "string" && (f.source[e.to] = b.source));
1373
+ } else b || (f = u[u.length - 1] ?? d);
1374
+ s = o?.local ?? null, c = o?.tag ?? null, l = o?.visitor ?? null, p = !o?.destination;
1375
+ },
1376
+ onText: (e) => {
1377
+ m ? m.push(Mt(e)) : l?.text?.(e, v);
1378
+ },
1379
+ onEnd: t
1380
+ };
1381
+ }
1382
+ }, Ft = `IFERROR(${ae}(`, It = Ft.toUpperCase(), Lt = x.toUpperCase(), Rt = { kind: "none" }, zt = { kind: "spilled" }, Bt = (e, t) => {
1383
+ if (e.charCodeAt(t) !== 34) return null;
1384
+ let n = "", r = t + 1;
1385
+ for (; r < e.length;) if (e.charCodeAt(r) === 34) {
1386
+ if (e.charCodeAt(r + 1) !== 34) return {
1387
+ value: n,
1388
+ end: r + 1
1389
+ };
1390
+ n += "\"", r += 2;
1391
+ } else n += e[r], r++;
1392
+ return null;
1393
+ }, Vt = (e) => {
1394
+ let t = [], n = 0;
1395
+ for (; n < e.length;) {
1396
+ let r = e.charCodeAt(n);
1397
+ if (r === 34) {
1398
+ let t = Bt(e, n);
1399
+ if (t === null) break;
1400
+ n = t.end;
1401
+ continue;
1402
+ }
1403
+ if (!(r >= 65 && r <= 90 || r >= 97 && r <= 122 || r === 95)) {
1404
+ n++;
1405
+ continue;
1406
+ }
1407
+ let i = n + 1;
1408
+ for (; i < e.length;) {
1409
+ let t = e.charCodeAt(i);
1410
+ if (!(t >= 65 && t <= 90 || t >= 97 && t <= 122 || t >= 48 && t <= 57 || t === 95 || t === 46)) break;
1411
+ i++;
1412
+ }
1413
+ e.charCodeAt(i) === 40 && t.push(e.slice(n, i).toUpperCase().replace(/^_XLFN\./, "").replace(/^_XLWS\./, "")), n = i;
1414
+ }
1415
+ return t;
1416
+ }, Ht = (e) => {
1417
+ let t = (t) => {
1418
+ if (e) return RegExp(`<(?:[\\w.-]+:)?${t}\\b[^>]*>([^<]*)<`).exec(e)?.[1];
1419
+ }, n = (e) => {
1420
+ let t = parseInt(e ?? "", 10);
1421
+ return isNaN(t) ? 0 : t;
1422
+ };
1423
+ return {
1424
+ c: n(t("col")),
1425
+ r: n(t("row")),
1426
+ x: P(t("colOff") ?? "0") ?? 0,
1427
+ y: P(t("rowOff") ?? "0") ?? 0
1428
+ };
1429
+ }, Ut = "formulaDialect", Wt = (e, t, n, r, i, a, o, s) => {
1430
+ let c = new Pt(), u = s?.get("parseInlineDxf"), d = s?.get(Ut), f = (e) => d && e ? d.readDetached(e) : e, g = new p.TransposedBuilder(), _ = null;
1431
+ c.registerVisitor({
1432
+ from: "autoFilter",
1433
+ to: "autoTable",
1434
+ openTag: (e) => {
1435
+ let t = e.getAttribute("ref"), n = m.fastStringToRange(t);
1436
+ e.getSource().r = n, e.getSource().v = {};
1437
+ },
1438
+ closeTag: (e) => {
1439
+ let t = e.getSource(), n = t.v, r = n.hiddenButtons;
1440
+ if (Array.isArray(r)) {
1441
+ let e = r.length, i = t.r, a = i.colEnd - i.colStart + 1;
1442
+ e === 0 ? n.hiddenButtons = !1 : e === a && (n.hiddenButtons = !0);
1443
+ }
1444
+ }
1445
+ }), c.registerVisitor({
1446
+ from: "conditionalFormatting",
1447
+ to: {},
1448
+ openTag: (e) => {
1449
+ let t = e.getParent();
1450
+ t.conditionals ||= [];
1451
+ let n = e.getAttribute("sqref");
1452
+ n &&= n.trim().split(/\s+/).join(",");
1453
+ let r = {
1454
+ r: n,
1455
+ conditionals: t.conditionals
1456
+ }, i = e.getAttribute("pivot", X);
1457
+ i !== null && (r.pivot = i), e.setSource(r);
1458
+ }
1459
+ }), c.registerVisitor({
1460
+ from: "cfRule",
1461
+ to: {},
1462
+ openTag: (e) => {
1463
+ let t = e.getParent();
1464
+ if (!t?.r) return;
1465
+ let n = e.getSource() ?? {};
1466
+ t.pivot !== void 0 && (n.pivot = t.pivot), t.conditionals.push({
1467
+ r: t.r,
1468
+ v: null,
1469
+ rule: n
1470
+ }), e.copyToObject(n, "type", $), e.copyToObject(n, "priority", Z), e.copyToObject(n, "stopIfTrue", X);
1471
+ let i = e.getAttribute("dxfId", Z);
1472
+ if (i !== null) {
1473
+ let t = r?.get(i);
1474
+ t ||= (a?.(`Unable to load conditional color. Invalid dxfI: '${i}' at '${e.getPath()}'.`), {}), n.style = t;
1475
+ }
1476
+ 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", $);
1477
+ },
1478
+ closeTag: (e) => {
1479
+ let t = e.getParent();
1480
+ if (!t?.r) return;
1481
+ let n = t.conditionals[t.conditionals.length - 1], r = n?.rule;
1482
+ if (!r) return;
1483
+ let i = {}, o = le(r, a);
1484
+ 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;
1485
+ }
1486
+ });
1487
+ let v = (e) => {
1488
+ let t = e.conditions ?? [], n = [];
1489
+ for (let e = 0; e < t.length; e++) {
1490
+ let r = t[e], i = {};
1491
+ r.type && (i.type = r.type), r.value !== void 0 && (i.value = r.value), r.exclusive && (i.exclusive = !0), n.push(i);
1492
+ }
1493
+ return n;
1494
+ };
1495
+ c.registerVisitor({
1496
+ from: "colorScale",
1497
+ to: {},
1498
+ openTag: (e) => {},
1499
+ closeTag: (e) => {
1500
+ let t = e.getSource(), n = t.colors ?? [], r = v(t);
1501
+ for (let e = 0; e < r.length; e++) r[e].color = n[e];
1502
+ e.getParent().scale = {
1503
+ type: h.ScaleType.ColorScale,
1504
+ stops: r
1505
+ };
1506
+ }
1507
+ }), c.registerVisitor({
1508
+ from: "dataBar",
1509
+ to: {},
1510
+ openTag: (e) => {
1511
+ e.copyTo("maxLength", Z), e.copyTo("minLength", Z), e.copyTo("showValue", X);
1512
+ },
1513
+ closeTag: (e) => {
1514
+ let t = e.getSource(), n = {
1515
+ type: h.ScaleType.DataBar,
1516
+ stops: v(t)
1517
+ }, r = t.colors?.[0];
1518
+ 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;
1519
+ }
1520
+ }), c.registerVisitor({
1521
+ from: "iconSet",
1522
+ to: {},
1523
+ openTag: (e) => {
1524
+ e.copyTo("iconSet", $), e.copyTo("reverse", X), e.copyTo("showValue", X);
1525
+ },
1526
+ closeTag: (e) => {
1527
+ let t = e.getSource(), n = {
1528
+ type: h.ScaleType.IconSet,
1529
+ stops: v(t)
1530
+ };
1531
+ 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;
1532
+ }
1533
+ }), c.registerVisitor({
1534
+ from: "formula",
1535
+ to: {},
1536
+ text: (e, t) => {
1537
+ let n = t.getParent(), r = n.formulas;
1538
+ r || (r = [], n.formulas = r), r.push(f(e));
1539
+ }
1540
+ }), c.registerVisitor({
1541
+ from: "cfvo",
1542
+ to: {},
1543
+ openTag: (e) => {
1544
+ let t = e.getParent();
1545
+ t.conditions ||= [];
1546
+ let n = e.getSource();
1547
+ if (t.conditions.push(n), e.copyTo("type", $), n.type === h.ColorStopType.Formula) {
1548
+ let t = e.getAttribute("val");
1549
+ t != null && (n.value = f(String(t)));
1550
+ } else e.copyTo("value", Q, "val");
1551
+ !1 === e.getAttribute("gte", X) && (n.exclusive = !0);
1552
+ }
1553
+ }), c.registerVisitor({
1554
+ from: "color",
1555
+ to: {},
1556
+ openTag: (e) => {
1557
+ let t = e.getParent();
1558
+ t.colors ||= [];
1559
+ let n = V((t) => e.getAttribute(t));
1560
+ t.colors.push(n);
1561
+ }
1562
+ }), c.registerVisitor({
1563
+ from: "filterColumn",
1564
+ to: {},
1565
+ openTag: (e) => {
1566
+ let t = e.getParent().v, n = parseInt(e.getAttribute("colId")), r = e.getSource();
1567
+ r.index = n;
1568
+ let i = t.filter;
1569
+ i || (i = { conditions: [] }, t.filter = i);
1570
+ let a = i.conditions;
1571
+ if (a || (a = [], i.conditions = a), a.push(r), e.getAttribute("hiddenButton", X) && t) {
1572
+ let e = t.hiddenButtons;
1573
+ e || (e = [], t.hiddenButtons = e), e.push(n);
1574
+ }
1575
+ if (e.getAttribute("showButton", X) && t) {
1576
+ let e = t.showButtons;
1577
+ e || (e = [], t.showButtons = e), e.push(n);
1578
+ }
1579
+ return r;
1580
+ }
1581
+ }), c.registerVisitor({
1582
+ from: "colorFilter",
1583
+ openTag: (e) => {
1584
+ let t = e.getParent(), n = {};
1585
+ t.operator = l.BuiltInOperatorNames.Color, t.param = n, e.copyToObject(n, "cellColor", X), e.copyToObject(n, "styleId", Z, "dxfId");
1586
+ }
1587
+ }), c.registerVisitor({
1588
+ from: "iconFilter",
1589
+ openTag: (e) => {
1590
+ let t = e.getParent(), n = {};
1591
+ t.operator = l.BuiltInOperatorNames.Icon, t.param = n, e.copyToObject(n, "iconId", Z), e.copyToObject(n, "iconSet", $);
1592
+ }
1593
+ }), c.registerVisitor({
1594
+ from: "top10",
1595
+ openTag: (e) => {
1596
+ let t = e.getParent(), n = {};
1597
+ 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");
1598
+ }
1599
+ }), c.registerVisitor({
1600
+ from: "dynamicFilter",
1601
+ openTag: (e) => {
1602
+ let t = e.getParent(), n = me(e.getAttribute("type"));
1603
+ t.operator = n.operator, t.param = n.param;
1604
+ }
1605
+ });
1606
+ let y = {
1607
+ from: "filters",
1608
+ to: {},
1609
+ openTag: (e) => {
1610
+ let t = e.getParent(), n = {};
1611
+ return t.selector = l.BuiltInSelectorNames.Display, t.operator = l.BuiltInOperatorNames.InSet, t.param = n, e.copyToObject(n, "blank", X), e.copyToObject(n, "calendarType", $), n;
1612
+ }
1613
+ };
1614
+ c.registerVisitor(y);
1615
+ let b = {
1616
+ from: "filter",
1617
+ openTag: (e) => {
1618
+ let t = e.getParent(), n = t.items;
1619
+ n || (n = [], t.items = n), n.push(e.getAttribute("val", $));
1620
+ }
1621
+ };
1622
+ c.registerVisitor(b);
1623
+ let ee = {
1624
+ from: "dateGroupItem",
1625
+ to: {},
1626
+ openTag: (e) => {
1627
+ let t = e.getParent(), n = t.dateGroups;
1628
+ 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);
1629
+ }
1630
+ };
1631
+ c.registerVisitor(ee);
1632
+ let x = /* @__PURE__ */ new Map();
1633
+ x.set("filterColumn", {
1634
+ from: "filterColumn",
1635
+ transparent: !0
1636
+ }), x.set("filters", y), x.set("filter", b), x.set("dateGroupItem", ee), c.registerVisitor({
1637
+ from: "customFilters",
1638
+ openTag: (e) => {
1639
+ let t = e.getParent(), n = e.getAttribute("and"), r = n === "and" || n === "1", i = [];
1640
+ return t.operator = r ? l.BuiltInOperatorNames.And : l.BuiltInOperatorNames.Or, t.param = i, e.setSource(t), i;
1641
+ },
1642
+ closeTag: (e) => {
1643
+ let t = e.getSource(), n = t?.param;
1644
+ if (!t || !n) return;
1645
+ let r = n.length === 1 ? n[0] : j(t);
1646
+ r !== t && (t.operator = r.operator, t.param = r.param);
1647
+ }
1648
+ }), c.registerVisitor({
1649
+ from: "customFilter",
1650
+ openTag: (e) => {
1651
+ let t, n = e.getParent();
1652
+ Array.isArray(n) ? (t = {}, n.push(t)) : t = n;
1653
+ let r = ie({
1654
+ operator: e.getAttribute("operator"),
1655
+ val: e.getAttribute("val")
1656
+ }, (t) => e.warn(t));
1657
+ r && (t.operator = r.operator, t.param = r.param);
1658
+ }
1659
+ }), c.registerVisitor({
1660
+ from: "sortState",
1661
+ to: {},
1662
+ openTag: (e) => {
1663
+ let t = e.getParent(), n = t.v;
1664
+ n && (n.sort = {}, e.setSource(t));
1665
+ }
1666
+ }), c.registerVisitor({
1667
+ from: "sortCondition",
1668
+ to: {},
1669
+ openTag: (e) => {
1670
+ let t = e.getParent(), n = t.v;
1671
+ if (!n) return;
1672
+ let r = n.sort;
1673
+ if (!r) return;
1674
+ let i = r.sorts;
1675
+ i || (i = [], r.sorts = i);
1676
+ let a = e.getAttribute("ref"), o = 0;
1677
+ if (a) {
1678
+ let e = m.fastStringToRange(a, qt).colStart, n = t.r, r = n.colStart;
1679
+ o = n ? e - r : e;
1680
+ }
1681
+ let s = {};
1682
+ 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;
1683
+ let c = {
1684
+ index: o,
1685
+ criteria: s
1686
+ };
1687
+ i.push(c);
1688
+ }
1689
+ });
1690
+ let te = (e) => {
1691
+ _ = e.getSource(), e.copyTo("topLeft", $, "topLeftCell");
1692
+ let t = N(e.getAttribute("defaultGridColor")), n = e.getAttribute("colorId");
1693
+ 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), e.copyTo("showOutlineSymbols", X);
1694
+ };
1695
+ c.registerVisitor({
1696
+ from: "sheetView",
1697
+ to: "view",
1698
+ openTag: (e) => {
1699
+ te(e);
1700
+ },
1701
+ closeTag: () => {
1702
+ _ = null;
1703
+ }
1704
+ }), c.registerVisitor({
1705
+ from: "customSheetViews",
1706
+ to: "customSheetViews",
1707
+ openTag: (e) => {
1708
+ e.setSource([]);
1709
+ }
1710
+ }), c.registerVisitor({
1711
+ from: "customSheetView",
1712
+ to: [],
1713
+ openTag: (e) => {
1714
+ te(e);
1715
+ },
1716
+ closeTag: () => {
1717
+ _ = null;
1718
+ }
1719
+ }), c.registerVisitor({
1720
+ from: "selection",
1721
+ to: "selection",
1722
+ openTag: (e) => {
1723
+ if (!_) return;
1724
+ e.copyTo("cell", $, "activeCell"), e.copyTo("rangeIndex", Z, "activeCellId");
1725
+ let t = e.getAttribute("activeCell"), n = e.getAttribute("sqref");
1726
+ n && n !== t && (e.getSource().ranges = n.trim().split(/\s+/));
1727
+ }
1728
+ }), c.registerVisitor({
1729
+ from: "pane",
1730
+ to: null,
1731
+ openTag: (e) => {
1732
+ if (_ && e.getAttribute("state") === "frozen") {
1733
+ let t = {};
1734
+ _.freezePanes = t, e.copyToObject(t, "topLeft", $, "topLeftCell");
1735
+ let n = (_.topLeft ? m.fastStringToCell(_.topLeft) : void 0) ?? {
1736
+ colIndex: 0,
1737
+ rowIndex: 0
1738
+ }, r = {
1739
+ colIndex: 0,
1740
+ rowIndex: 0
1741
+ };
1742
+ e.copyToObject(r, "colIndex", Z, "xSplit"), e.copyToObject(r, "rowIndex", Z, "ySplit");
1743
+ let i = {
1744
+ colIndex: n.colIndex + r.colIndex,
1745
+ rowIndex: n.rowIndex + r.rowIndex
1746
+ };
1747
+ t.coords = m.cellToString(i);
1748
+ }
1749
+ }
1750
+ }), c.registerVisitor({
1751
+ from: "sheetPr",
1752
+ transparent: !0,
1753
+ openTag: (t) => {
1754
+ let n = t.getAttribute("codeName");
1755
+ n && (e.codeName = n), !1 === t.getAttribute("enableFormatConditionsCalculation", X) && (e.conditionalFormatCalculation = !1);
1756
+ }
1757
+ }), c.registerVisitor({
1758
+ from: "tabColor",
1759
+ to: null,
1760
+ openTag: (t) => {
1761
+ let n = V((e) => t.getAttribute(e));
1762
+ n && (e.tabColor = n);
1763
+ }
1764
+ }), c.registerVisitor({
1765
+ from: "pageSetUpPr",
1766
+ to: "pageSetUpPr",
1767
+ openTag: (e) => {}
1768
+ }), c.registerVisitor({
1769
+ from: "outlinePr",
1770
+ to: null,
1771
+ openTag: (t) => {
1772
+ let n = (e) => {
1773
+ let n = t.getAttribute(e);
1774
+ return n === "0" || n === "false";
1775
+ }, r = {};
1776
+ n("summaryBelow") && (r.summaryRow = "up"), n("summaryRight") && (r.summaryColumn = "left"), (() => {
1777
+ let e = t.getAttribute("applyStyles");
1778
+ return e === "1" || e === "true";
1779
+ })() && (r.automaticStyles = !0), Object.keys(r).length > 0 && (e.outline = r);
1780
+ }
1781
+ }), c.registerVisitor({
1782
+ from: "pageMargins",
1783
+ to: "pageMargins",
1784
+ openTag: (e) => {
1785
+ 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);
1786
+ }
1787
+ }), c.registerVisitor({
1788
+ from: "pageSetup",
1789
+ to: "pageSetup",
1790
+ openTag: (e) => {
1791
+ 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);
1792
+ }
1793
+ }), c.registerVisitor({
1794
+ from: "printOptions",
1795
+ to: "printOptions",
1796
+ openTag: (e) => {
1797
+ e.copyTo("gridLines", X), e.copyTo("gridLinesSet", X), e.copyTo("headings", X), e.copyTo("horizontalCentered", X), e.copyTo("verticalCentered", X);
1798
+ }
1799
+ }), c.registerVisitor({
1800
+ from: "headerFoot",
1801
+ to: "headerFoot",
1802
+ openTag: (e) => {}
1803
+ }), c.registerVisitor({
1804
+ from: "mergeCells",
1805
+ to: "merges",
1806
+ openTag: (e) => {
1807
+ e.setSource([]);
1808
+ }
1809
+ }), c.registerVisitor({
1810
+ from: "dataValidations",
1811
+ to: "validations",
1812
+ openTag: (e) => {
1813
+ e.setSource([]);
1814
+ }
1815
+ });
1816
+ let S = {
1817
+ from: "dataValidation",
1818
+ to: [],
1819
+ openTag: (e) => {
1820
+ let t = e.getAttribute("sqref");
1821
+ t &&= t.trim().split(/\s+/).join(",");
1822
+ let n = {}, r = {
1823
+ r: t,
1824
+ v: n,
1825
+ rule: {
1826
+ type: e.getAttribute("type") ?? void 0,
1827
+ operator: e.getAttribute("operator") ?? void 0
1828
+ }
1829
+ };
1830
+ !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);
1831
+ },
1832
+ closeTag: (e) => {
1833
+ let t = e.getSource();
1834
+ if (!t?.rule) return;
1835
+ let n = k(t.rule, a);
1836
+ n && (e.getAttribute("allowBlank", X) && (n.includeBlanks = !0), t.v.condition = n), delete t.rule;
1837
+ }
1838
+ };
1839
+ c.registerVisitor(S), c.registerVisitor({
1840
+ from: "formula1",
1841
+ to: {},
1842
+ text: (e, t) => {
1843
+ let n = t.getParent().rule;
1844
+ n?.type && (n.formula1 = re(f(e), n.type));
1845
+ }
1846
+ }), c.registerVisitor({
1847
+ from: "formula2",
1848
+ to: {},
1849
+ text: (e, t) => {
1850
+ let n = t.getParent().rule;
1851
+ n?.type && (n.formula2 = re(f(e), n.type));
1852
+ }
1853
+ }), c.registerVisitor({
1854
+ from: "picture",
1855
+ to: "picture",
1856
+ openTag: (e) => {
1857
+ let n = e.getAttribute("r:id");
1858
+ if (!n) return void e.warn("A picture names no image; it was not imported.", { onceKey: "xlsx.sheet.picture.noRel" });
1859
+ let r = t(n, "resource");
1860
+ e.getSource().resId = r;
1861
+ }
1862
+ });
1863
+ let ae = {
1864
+ from: "slicer",
1865
+ to: {},
1866
+ openTag: (e) => {
1867
+ let n = e.getAttribute("r:id");
1868
+ if (!n) return void e.warn("A slicer names no cache; it was not imported.", { onceKey: "xlsx.sheet.slicer.noRel" });
1869
+ let r = t(n)?.slicers, i = e.getParent();
1870
+ i.slicers ||= {};
1871
+ let a = Object.keys(r);
1872
+ for (let e of a) i.slicers[e] = r[e];
1873
+ }
1874
+ };
1875
+ c.registerVisitor(ae);
1876
+ let se = (e, t) => ({
1877
+ from: e,
1878
+ to: {},
1879
+ openTag: (e) => {
1880
+ e.setSource("");
1881
+ },
1882
+ text: (e, t) => {
1883
+ t.setSource((t.getSource() ?? "") + e);
1884
+ },
1885
+ closeTag: (e) => {
1886
+ t(String(e.getSource() ?? ""), e);
1887
+ }
1888
+ }), ce = /* @__PURE__ */ new Map();
1889
+ ce.set("dataValidations", {
1890
+ from: "dataValidations",
1891
+ to: "validations",
1892
+ openTag: (e) => {
1893
+ let t = e.getParent();
1894
+ e.setSource(t.validations ?? []);
1895
+ },
1896
+ closeTag: (e) => {
1897
+ (e.getSource()?.length ?? 0) === 0 && e.setSource(void 0);
1898
+ }
1899
+ }), ce.set("dataValidation", {
1900
+ ...S,
1901
+ closeTag: (e) => {
1902
+ S.closeTag(e);
1903
+ let t = e.getSource();
1904
+ t && !t.r && (e.warn("x14 dataValidation with no xm:sqref was dropped."), e.setSource(void 0));
1905
+ }
1906
+ });
1907
+ let C = (e) => ({
1908
+ from: e,
1909
+ to: {},
1910
+ openTag: (t) => {
1911
+ t.setSource({
1912
+ rule: t.getParent()?.rule,
1913
+ key: e
1914
+ });
1915
+ }
1916
+ });
1917
+ ce.set("formula1", C("formula1")), ce.set("formula2", C("formula2")), ce.set("f", se("f", (e, t) => {
1918
+ let n = t.getParent(), r = n?.rule;
1919
+ r && (r[n.key] = re(f(e), r.type));
1920
+ })), ce.set("sqref", se("sqref", (e, t) => {
1921
+ let n = t.getParent(), r = e.trim();
1922
+ n && r && (n.r = r.split(/\s+/).join(","));
1923
+ }));
1924
+ let w = /* @__PURE__ */ new Map(), T = [], D = /* @__PURE__ */ new Map();
1925
+ D.set("conditionalFormattings", {
1926
+ from: "conditionalFormattings",
1927
+ transparent: !0
1928
+ }), D.set("conditionalFormatting", {
1929
+ from: "conditionalFormatting",
1930
+ to: {},
1931
+ openTag: (e) => {
1932
+ e.setSource({ rules: [] });
1933
+ },
1934
+ closeTag: (e) => {
1935
+ let t = e.getSource(), n = t?.rules ?? [];
1936
+ for (let e = 0; e < n.length; e++) {
1937
+ let r = n[e];
1938
+ r.sqref = t.sqref, r.id ? w.set(r.id, r) : T.push(r);
1939
+ }
1940
+ }
1941
+ }), D.set("cfRule", {
1942
+ from: "cfRule",
1943
+ to: {},
1944
+ openTag: (e) => {
1945
+ 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);
1946
+ },
1947
+ closeTag: (e) => {
1948
+ let t = e.getSource();
1949
+ t && e.getParent()?.rules?.push(t);
1950
+ }
1951
+ }), D.set("sqref", se("sqref", (e, t) => {
1952
+ let n = t.getParent(), r = e.trim();
1953
+ n && r && (n.sqref = r);
1954
+ })), D.set("dataBar", {
1955
+ from: "dataBar",
1956
+ to: {},
1957
+ openTag: (e) => {
1958
+ 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);
1959
+ },
1960
+ closeTag: (e) => {
1961
+ e.getParent().dataBar = e.getSource();
1962
+ }
1963
+ }), D.set("iconSet", {
1964
+ from: "iconSet",
1965
+ to: {},
1966
+ openTag: (e) => {
1967
+ e.copyTo("iconSet", $), e.copyTo("custom", X), e.copyTo("reverse", X), e.copyTo("showValue", X);
1968
+ },
1969
+ closeTag: (e) => {
1970
+ e.getParent().iconSet = e.getSource();
1971
+ }
1972
+ });
1973
+ let de = /* @__PURE__ */ new Map();
1974
+ de.set("f", se("f", (e, t) => {
1975
+ let n = t.getParent();
1976
+ if (!n) return;
1977
+ let r = e.trim(), i = Number(r);
1978
+ n.value = r.length > 0 && Number.isFinite(i) ? i : f(e);
1979
+ })), D.set("cfvo", {
1980
+ from: "cfvo",
1981
+ to: {},
1982
+ scope: () => de,
1983
+ openTag: (e) => {
1984
+ let t = e.getParent();
1985
+ t.conditions ||= [];
1986
+ let n = e.getSource();
1987
+ t.conditions.push(n), e.copyTo("type", $), !1 === e.getAttribute("gte", X) && (n.exclusive = !0);
1988
+ }
1989
+ }), D.set("f", se("f", (e, t) => {
1990
+ let n = t.getParent();
1991
+ n && (n.formulas ??= []).push(f(e));
1992
+ })), D.set("dxf", {
1993
+ from: "dxf",
1994
+ to: {},
1995
+ raw: !0,
1996
+ closeTag: (e) => {
1997
+ if (!u) return;
1998
+ let t = e.getParent();
1999
+ if (!t) return;
2000
+ let n = u(e.getRawXml() ?? "");
2001
+ n && (t.style = n);
2002
+ }
2003
+ });
2004
+ let fe = (e) => ({
2005
+ from: e,
2006
+ to: {},
2007
+ openTag: (t) => {
2008
+ let n = V((e) => t.getAttribute(e));
2009
+ n && (t.getParent()[e] = n);
2010
+ }
2011
+ });
2012
+ D.set("borderColor", fe("borderColor")), D.set("negativeFillColor", fe("negativeFillColor")), D.set("negativeBorderColor", fe("negativeBorderColor")), D.set("axisColor", fe("axisColor")), D.set("cfIcon", {
2013
+ from: "cfIcon",
2014
+ to: {},
2015
+ openTag: (e) => {
2016
+ let t = e.getAttribute("iconSet"), n = e.getAttribute("iconId", Z);
2017
+ if (t === null || n === null) return;
2018
+ let r = e.getParent();
2019
+ r.icons ||= [], r.icons.push({
2020
+ set: t,
2021
+ id: n
2022
+ });
2023
+ }
2024
+ });
2025
+ let pe = /* @__PURE__ */ new Map();
2026
+ pe.set("id", se("id", (e, t) => {
2027
+ let n = t.getParent(), r = e.trim();
2028
+ n && r && (n.x14Id = r);
2029
+ }));
2030
+ let _e = /* @__PURE__ */ new Map();
2031
+ _e.set("slicerList", {
2032
+ from: "slicerList",
2033
+ transparent: !0
2034
+ }), _e.set("slicer", ae);
2035
+ let ve = /* @__PURE__ */ new Map([
2036
+ [E(L), ce],
2037
+ [E(ue), D],
2038
+ [E(be), D],
2039
+ [E(xe), pe],
2040
+ [E(Ce), _e],
2041
+ [E(M), _e],
2042
+ [E(A), x]
2043
+ ]), P = /* @__PURE__ */ new Set();
2044
+ c.registerVisitor({
2045
+ from: "extLst",
2046
+ transparent: !0
2047
+ }), c.registerVisitor({
2048
+ from: "ext",
2049
+ transparent: !0,
2050
+ scope: (e) => {
2051
+ let t = e.getAttribute("uri"), n = E(t), r = ve.get(n);
2052
+ if (r) return r;
2053
+ if (!oe.has(n) && !P.has(n)) {
2054
+ P.add(n);
2055
+ let r = ye[n];
2056
+ 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.`);
2057
+ }
2058
+ return null;
2059
+ }
2060
+ }), c.registerVisitor({
2061
+ from: "mergeCell",
2062
+ to: [],
2063
+ openTag: (e) => {
2064
+ let t = e.getAttribute("ref");
2065
+ e.setSource(t);
2066
+ }
2067
+ }), c.registerVisitor({
2068
+ from: "hyperlinks",
2069
+ to: "hyperlinks",
2070
+ openTag: (e) => {
2071
+ e.setSource([]);
2072
+ }
2073
+ }), c.registerVisitor({
2074
+ from: "hyperlink",
2075
+ to: [],
2076
+ openTag: (e) => {
2077
+ let n = e.getAttribute("r:id"), r = e.getAttribute("ref");
2078
+ if (!r) return void e.warn("A hyperlink has no ref; it was dropped.", { onceKey: "xlsx.sheet.hyperlink.noRef" });
2079
+ e.setKey(r);
2080
+ let i = n ? t(n) : "";
2081
+ if (typeof i != "string") return void e.warn("A hyperlink has an invalid address; it was dropped.", { onceKey: "xlsx.sheet.hyperlink.address" });
2082
+ i.endsWith("\\") && (i = i.substring(0, i.length - 1));
2083
+ let a = e.getAttribute("location");
2084
+ if (a && (i += "#" + a), !i) return void e.warn("A hyperlink has no address; it was dropped.", { onceKey: "xlsx.sheet.hyperlink.address" });
2085
+ let o, s = e.getAttribute("tooltip");
2086
+ o = s ? {
2087
+ address: i,
2088
+ screenTip: s
2089
+ } : i, e.setSource({
2090
+ r,
2091
+ v: o
2092
+ });
2093
+ }
2094
+ }), c.registerVisitor({
2095
+ from: "drawing",
2096
+ to: "movables",
2097
+ openTag: (e) => {
2098
+ let n = e.getAttribute("r:id");
2099
+ if (!n) return;
2100
+ let r = t(n);
2101
+ r ? e.setSource(r.movables) : e.warn("A drawing part is missing; its shapes were not imported.", { onceKey: "xlsx.sheet.drawing.missing" });
2102
+ }
2103
+ }), c.registerVisitor({
2104
+ from: "legacyDrawing",
2105
+ to: "legacyDrawing",
2106
+ openTag: (e) => {
2107
+ e.setSource(t(e.getAttribute("r:id"), "legacyDrawing") ?? void 0);
2108
+ }
2109
+ }), c.registerVisitor({
2110
+ from: "legacyDrawingHF",
2111
+ to: "legacyDrawingHF",
2112
+ openTag: (e) => {
2113
+ e.setSource(t(e.getAttribute("r:id"), "legacyDrawing") ?? void 0);
2114
+ }
2115
+ });
2116
+ let F = null, I = !1, R = /* @__PURE__ */ new Map(), Se = {
2117
+ from: "Fallback",
2118
+ to: null
2119
+ }, we = {
2120
+ from: "Choice",
2121
+ transparent: !0
2122
+ };
2123
+ R.set("Fallback", Se), R.set("Choice", we), R.set("control", {
2124
+ from: "control",
2125
+ transparent: !0,
2126
+ openTag: (e) => {
2127
+ let n = e.getAttribute("name"), r = e.getAttribute("r:id"), i = r ? t(r, "formControl") : null;
2128
+ if (!i) return e.warn(`The form control '${n ?? ""}' has no properties and was not read.`, { onceKey: "xlsx.sheet.control.noProperties" }), void (F = null);
2129
+ let a = i.json, o = parseInt(e.getAttribute("shapeId") ?? "", 10);
2130
+ isNaN(o) || (a.shapeId = o);
2131
+ let s = {
2132
+ anchor: {
2133
+ tl: {
2134
+ c: 0,
2135
+ r: 0,
2136
+ x: 0,
2137
+ y: 0
2138
+ },
2139
+ br: {
2140
+ c: 0,
2141
+ r: 0,
2142
+ x: 0,
2143
+ y: 0
2144
+ }
2145
+ },
2146
+ content: {
2147
+ type: i.type,
2148
+ json: a
2149
+ }
2150
+ };
2151
+ n && (s.content.name = n), F = {
2152
+ movable: s,
2153
+ control: a
2154
+ };
2155
+ },
2156
+ closeTag: () => {
2157
+ F &&= (e.movables ||= [], e.movables.push(F.movable), null);
2158
+ }
2159
+ }), R.set("controlPr", {
2160
+ from: "controlPr",
2161
+ transparent: !0,
2162
+ raw: !0,
2163
+ openTag: (e) => {
2164
+ if (!F) return;
2165
+ let t = e.getFrom().attributes ?? {}, n = {};
2166
+ for (let e in t) {
2167
+ let r = t[e];
2168
+ n[e] = typeof r == "string" ? r : r?.value ?? "";
2169
+ }
2170
+ ne(n, F.control);
2171
+ },
2172
+ closeTag: (e) => {
2173
+ if (!F) return;
2174
+ let t = ((e) => {
2175
+ let t = /<(?:[\w.-]+:)?anchor\b([^>]*)>([\s\S]*?)<\/(?:[\w.-]+:)?anchor>/.exec(e);
2176
+ if (!t) return null;
2177
+ let n = t[2], r = (e) => RegExp(`<(?:[\\w.-]+:)?${e}\\b[^>]*>([\\s\\S]*?)<\\/(?:[\\w.-]+:)?${e}>`).exec(n)?.[1], i = t[1], a = /\bmoveWithCells="(?:1|true)"/.test(i), o = /\bsizeWithCells="(?:1|true)"/.test(i);
2178
+ return {
2179
+ anchor: {
2180
+ tl: Ht(r("from")),
2181
+ br: Ht(r("to"))
2182
+ },
2183
+ anchorType: a ? o ? "twoCell" : "oneCell" : "absolute",
2184
+ rest: (e.slice(0, t.index) + e.slice(t.index + t[0].length)).trim()
2185
+ };
2186
+ })(e.getRawXml() ?? "");
2187
+ t ? (F.movable.anchor = t.anchor, t.anchorType !== "twoCell" && (F.movable.anchorType = t.anchorType), t.rest && (F.control.xml = t.rest)) : I || (I = !0, e.warn("A form control has no anchor; it is placed at the top left of the sheet."));
2188
+ }
2189
+ });
2190
+ let Te = {
2191
+ from: "controls",
2192
+ transparent: !0,
2193
+ scope: () => R
2194
+ };
2195
+ c.registerVisitor(Te);
2196
+ let Ee = /* @__PURE__ */ new Map([
2197
+ ["Choice", we],
2198
+ ["Fallback", Se],
2199
+ ["controls", Te]
2200
+ ]);
2201
+ c.registerVisitor({
2202
+ from: "AlternateContent",
2203
+ transparent: !0,
2204
+ scope: () => Ee
2205
+ }), c.registerVisitor({
2206
+ from: "tableParts",
2207
+ to: "tables",
2208
+ openTag: (e) => {
2209
+ e.setSource([]);
2210
+ }
2211
+ }), c.registerVisitor({
2212
+ from: "tablePart",
2213
+ to: [],
2214
+ openTag: (e) => {
2215
+ let n = e.getAttribute("r:id");
2216
+ if (!n) return;
2217
+ let r = t(n);
2218
+ r ? e.setSource(r) : e.warn("A table part is missing; the table was not imported.", { onceKey: "xlsx.sheet.table.missing" });
2219
+ }
2220
+ });
2221
+ let De = (e, t) => {
2222
+ t.conditions?.length && (e.stops = v(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);
2223
+ }, z = (e, t) => {
2224
+ t.conditions?.length && (e.stops = v(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);
2225
+ }, Oe = (e) => {
2226
+ if (!e.sqref) return null;
2227
+ let t = e.sqref.split(/\s+/).join(",");
2228
+ if (e.type === "iconSet") {
2229
+ if (!e.iconSet) return null;
2230
+ let n = {
2231
+ type: h.ScaleType.IconSet,
2232
+ stops: []
2233
+ };
2234
+ return z(n, e.iconSet), {
2235
+ r: t,
2236
+ v: { scale: n },
2237
+ priority: e.priority
2238
+ };
2239
+ }
2240
+ let n = le(e, a);
2241
+ if (!n) return null;
2242
+ let r = { condition: n };
2243
+ return e.style && (r.style = e.style), e.stopIfTrue && (r.stopIfTrue = !0), {
2244
+ r: t,
2245
+ v: r,
2246
+ priority: e.priority
2247
+ };
2248
+ };
2249
+ c.registerVisitor({
2250
+ from: "worksheet",
2251
+ to: {},
2252
+ openTag: (e) => {},
2253
+ closeTag: (e) => {
2254
+ let t = e.getSource(), n = t?.conditionals;
2255
+ if (n) for (let e = 0; e < n.length; e++) {
2256
+ let t = n[e], r = t.x14Id;
2257
+ if (!r) continue;
2258
+ delete t.x14Id;
2259
+ let i = w.get(r);
2260
+ if (!i) continue;
2261
+ w.delete(r);
2262
+ let a = t.v?.scale;
2263
+ i.dataBar && a?.type === h.ScaleType.DataBar ? De(a, i.dataBar) : i.iconSet && a?.type === h.ScaleType.IconSet && z(a, i.iconSet);
2264
+ }
2265
+ let r = [...w.values(), ...T], i = /* @__PURE__ */ new Set(), o = 0;
2266
+ for (let e = 0; e < r.length; e++) {
2267
+ let a = Oe(r[e]);
2268
+ a ? (n || (n = [], t.conditionals = n), n.push(a)) : (i.add(r[e].type ?? "unknown"), o++);
2269
+ }
2270
+ if (o > 0) {
2271
+ let e = [...i].map((e) => `'${e}'`).join(", ");
2272
+ 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.`);
2273
+ }
2274
+ if (n) {
2275
+ n.length > 1 && n.sort((e, t) => (e.priority ?? 1 / 0) - (t.priority ?? 1 / 0));
2276
+ for (let e = 0; e < n.length; e++) delete n[e].priority;
2277
+ }
2278
+ }
2279
+ }), c.registerVisitor({
2280
+ from: "customProperties",
2281
+ to: "customProperties",
2282
+ openTag: (e) => {
2283
+ e.setSource([]);
2284
+ },
2285
+ closeTag: (e) => {
2286
+ let t = e.getSource();
2287
+ t.length > 0 && (e.getParent().customProperties = t);
2288
+ }
2289
+ }), c.registerVisitor({
2290
+ from: "customPr",
2291
+ to: {},
2292
+ openTag: (e) => {
2293
+ let n = e.getParent();
2294
+ e.copyTo("name");
2295
+ let r = e.getAttribute("r:id");
2296
+ if (!r) return void e.warn("A custom property names no part; it was not imported.", { onceKey: "xlsx.sheet.customProperty.noRel" });
2297
+ let i = t(r, "resource"), a = e.getSource();
2298
+ a.resId = i, n.push(a);
2299
+ }
2300
+ }), c.registerVisitor({
2301
+ from: "sheetProtection",
2302
+ to: "protection",
2303
+ openTag: (e) => {
2304
+ let t = e.getSource();
2305
+ for (let n of O) {
2306
+ let r = e.hasAttribute(n.attribute) ? e.getAttribute(n.attribute) : null;
2307
+ t[n.key] = ge(n, r);
2308
+ }
2309
+ if (t.sheet) return;
2310
+ let n = {};
2311
+ e.copyToObject(n, "hash", $, "hashValue"), e.copyToObject(n, "algorithm", $, "algorithmName"), e.copyToObject(n, "salt", $, "saltValue"), e.copyToObject(n, "spinCount", Z), Object.keys(n).length > 0 && (e.getSource().password = n);
2312
+ }
2313
+ }), c.registerVisitor({
2314
+ from: "protectedRanges",
2315
+ to: "protectedRanges",
2316
+ openTag: (e) => {
2317
+ e.setSource([]);
2318
+ }
2319
+ }), c.registerVisitor({
2320
+ from: "protectedRange",
2321
+ to: [],
2322
+ openTag: (e) => {
2323
+ let t = e.getAttribute("sqref");
2324
+ t &&= t.trim().split(/\s+/).join(",");
2325
+ let n = {}, r = {
2326
+ r: t,
2327
+ v: n
2328
+ };
2329
+ e.copyToObject(n, "name"), e.copyToObject(n, "securityDescriptor");
2330
+ let i = {};
2331
+ 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);
2332
+ },
2333
+ closeTag: (e) => {
2334
+ let t = e.getSource();
2335
+ t?.r && t.v.name || e.setSource(void 0);
2336
+ }
2337
+ }), c.registerVisitor({
2338
+ from: "sheetFormatPr",
2339
+ to: "sheetFormatPr",
2340
+ openTag: (t) => {
2341
+ t.copyToObject(e, "defaultColSize", Q, "defaultColWidth");
2342
+ let n = t.getAttribute("customHeight");
2343
+ n !== "1" && n !== "true" || t.copyToObject(e, "defaultRowSize", Q, "defaultRowHeight");
2344
+ }
2345
+ }), c.registerVisitor({
2346
+ from: "cols",
2347
+ to: "cols",
2348
+ openTag: (e) => {
2349
+ e.setSource([]);
2350
+ }
2351
+ }), c.registerVisitor({
2352
+ from: "col",
2353
+ to: [],
2354
+ openTag: (e) => {
2355
+ 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;
2356
+ t.r = m.runToString(i, a, !0);
2357
+ let o = {};
2358
+ 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, "cl", X, "collapsed"), e.copyToObject(o, "s", Z, "style");
2359
+ }
2360
+ }), c.registerVisitor({
2361
+ from: "oleObjects",
2362
+ to: null,
2363
+ openTag: (e) => {
2364
+ e.warn("'OLE Objects' are not supported.");
2365
+ }
2366
+ });
2367
+ let B = !1, ke = !1, Ae = 0, je = "", Me = (e) => {
2368
+ let t = e.indexOf(":");
2369
+ return t === -1 ? e : e.slice(t + 1);
2370
+ };
2371
+ return Jt(g, e, c.createEventHandler(e, i, a), a, o, {
2372
+ onOpenTag: (e) => {
2373
+ B = !0;
2374
+ let t = Me(e.name);
2375
+ t === "t" || t === "v" ? Ae === 0 && (ke = !0) : t !== "rPh" && t !== "phoneticPr" || Ae++;
2376
+ },
2377
+ onText: (e) => {
2378
+ ke && (je += e);
2379
+ },
2380
+ onCloseTag: (e) => {
2381
+ let t = Me(e.name);
2382
+ t === "t" || t === "v" ? ke = !1 : t !== "rPh" && t !== "phoneticPr" || Ae > 0 && Ae--;
2383
+ },
2384
+ onEnd: () => {
2385
+ if (!B) return;
2386
+ let e = n(he(je));
2387
+ return B = !1, ke = !1, Ae = 0, je = "", e;
2388
+ },
2389
+ onError: (e) => {}
2390
+ }, s);
2391
+ }, Gt = class {
2392
+ static {
2393
+ this.Collapsed = 1;
2394
+ }
2395
+ static {
2396
+ this.CustomFormat = 2;
2397
+ }
2398
+ static {
2399
+ this.CustomHeight = 4;
2400
+ }
2401
+ static {
2402
+ this.Hidden = 8;
2403
+ }
2404
+ static {
2405
+ this.Ht = 16;
2406
+ }
2407
+ static {
2408
+ this.OutlineLevel = 32;
2409
+ }
2410
+ static {
2411
+ this.Ph = 64;
2412
+ }
2413
+ static {
2414
+ this.R = 128;
2415
+ }
2416
+ static {
2417
+ this.S = 256;
2418
+ }
2419
+ static {
2420
+ this.Spans = 512;
2421
+ }
2422
+ static {
2423
+ this.ThickBot = 1024;
2424
+ }
2425
+ static {
2426
+ this.ThickTop = 2048;
2427
+ }
2428
+ }, Kt = (e, t, n) => {
2429
+ if (e[0].value[0] === e[1].value[0]) return t;
2430
+ }, qt = {
2431
+ colStart: 0,
2432
+ colEnd: 0,
2433
+ rowStart: 0,
2434
+ rowEnd: 0
2435
+ }, Jt = (n, r, i, a, o, l, u) => {
2436
+ let d = !1, f = !1, p = [], h = !1, g = null, _ = null, v = null, y = null, b = null, ee = null, x = u?.get("richData") ?? t.EmptyArray, te = u?.get("dummyWrapped") ?? null, ne = m.normalizeA1ToR1C1, re = e.createConflatingRanges(), S = /* @__PURE__ */ new Map(), ie = [], ae = !1, oe = !1, se = null, ce = !1, le = e.createConflatingRanges(), C = !1, w = -1, T = -1, E = null, ue = null, D = null, O = [], de = null, fe = -2, k = 0, A = "", pe = "", j = "", me = "", M = "", he = "", N = "", ge = "", _e = "", ve = "", ye = "", P = "", F = "", I = "", L = !0, R = null, be = !1, xe = !1, Se = !1, Ce = null, we = 0, Te = (e) => {
2437
+ let t = e.name, n = t.indexOf(":");
2438
+ if (n !== -1 && (t = t.slice(n + 1)), we++, we % 196608 == 0 && o?.(we), ue) {
2439
+ let n = e.attributes;
2440
+ switch (t) {
2441
+ case "v":
2442
+ f = !0;
2443
+ break;
2444
+ case "f":
2445
+ switch (h = !0, n.t ?? null) {
2446
+ case null:
2447
+ case "normal": break;
2448
+ case "shared":
2449
+ let e = n.si;
2450
+ _ = n.ref, g = e;
2451
+ break;
2452
+ case "array":
2453
+ _ = n.ref, se = _;
2454
+ break;
2455
+ case "dataTable": _ = n.ref, h = !0;
2456
+ }
2457
+ let e = n.ca;
2458
+ e !== void 0 && (ce = e === "1");
2459
+ break;
2460
+ case "is":
2461
+ C = !0;
2462
+ return;
2463
+ }
2464
+ C && !h && l?.onOpenTag?.(e);
2465
+ } else if (d) {
2466
+ if (t === "c") {
2467
+ ue = e;
2468
+ let t = e.attributes, n = t.r;
2469
+ T = m.fastStringToCol(n);
2470
+ let r = t.t;
2471
+ r === void 0 ? D = null : (D = r, D === "str" && (C = !0));
2472
+ let i = t.s;
2473
+ i === void 0 && (Ce !== null || Se) && (i = "0"), i !== void 0 && (i = parseInt(i), R && R.value === i && R.colEnd + 1 === T ? R.colEnd = T : (R = {
2474
+ colStart: T,
2475
+ rowStart: w,
2476
+ colEnd: T,
2477
+ rowEnd: w,
2478
+ value: i
2479
+ }, p.push(R))), se = null, oe = !1;
2480
+ let a = t.cm;
2481
+ ae = a !== void 0 && ((e) => {
2482
+ let t = u?.get("metadata")?.cells;
2483
+ if (!t) return !1;
2484
+ let n = parseInt(e, 10);
2485
+ return !(!Number.isFinite(n) || n < 1) && !0 === t[n - 1]?.get("XLDAPR")?.fDynamic;
2486
+ })(a);
2487
+ let o = t.vm;
2488
+ if (o !== void 0) {
2489
+ let e = x[parseInt(o) - 1];
2490
+ if (s.isError(e)) {
2491
+ let t = e.getCode();
2492
+ E = {
2493
+ t: "e",
2494
+ v: t
2495
+ }, ae && t === s.Code.Spill && (oe = !0);
2496
+ }
2497
+ }
2498
+ }
2499
+ } else {
2500
+ if (xe && t === "row") {
2501
+ d = !0;
2502
+ let t = e.attributes.r;
2503
+ if (w = parseInt(t) - 1, k = 0, pe = e.attributes.customHeight, pe !== void 0 && (k |= Gt.CustomHeight), pe !== _e && (L = !0, _e = pe), A = e.attributes.ht, A !== void 0 && (k |= Gt.Ht), A !== ge && (L = !0, ge = A), j = e.attributes.hidden, j !== void 0 && (k |= Gt.Hidden), j !== ve && (L = !0, ve = j), M = e.attributes.s, M !== void 0 && (k |= Gt.S), M !== P && (L = !0, P = M), me = e.attributes.customFormat, me !== void 0 && (k |= Gt.CustomFormat), me !== ye && (L = !0, ye = me), he = e.attributes.outlineLevel, he !== void 0 && (k |= Gt.OutlineLevel), he !== F && (L = !0, F = he), N = e.attributes.collapsed, N !== void 0 && (k |= Gt.Collapsed), N !== I && (L = !0, I = N), k !== 0) {
2504
+ if (fe + 1 !== w || L) {
2505
+ let e = pe !== void 0 && (pe === "1" || pe === "true"), t = me !== void 0 && (me === "1" || me === "true");
2506
+ Ce = t && M !== void 0 ? M : null, t && Ce === null && (Ce = "0"), de = {
2507
+ min: w,
2508
+ max: w,
2509
+ value: {
2510
+ sz: A === void 0 ? -1 : parseFloat(A),
2511
+ csz: e,
2512
+ h: j !== void 0 && (j === "1" || j === "true"),
2513
+ s: Ce === null ? void 0 : Ce === "0" ? 0 : parseInt(Ce),
2514
+ l: he === void 0 || he === "0" ? 0 : parseInt(he),
2515
+ cl: N !== void 0 && (N === "1" || N === "true")
2516
+ }
2517
+ }, O.push(de);
2518
+ } else de.max = w;
2519
+ }
2520
+ fe = w, L = !1;
2521
+ return;
2522
+ }
2523
+ if (t === "sheetData" && (xe = !0), !be && t === "sheetData") {
2524
+ be = !0;
2525
+ let e = r.cols, t = e ? e.length : 0;
2526
+ for (let n = 0; !Se && n < t; n++) e[n].v.s && (Se = !0);
2527
+ }
2528
+ i?.onOpenTag?.(e);
2529
+ }
2530
+ }, Ee = (e) => {
2531
+ let t = e.name;
2532
+ if (t === "sheetData" && (xe = !1), !h || t !== "c" && t !== "f" || (g && (y = S.get(g) ?? null), y && (re.append(w, T, y), ce && le.append(w, T)), se !== null && ie.push([se, ae ? oe ? "error" : "dynamic" : "fixed"]), h = !1, y = null, g = null, _ = null, f = !1, ce = !1, se = null, ae = !1, oe = !1), ue) {
2533
+ let r = t.indexOf(":");
2534
+ if (r !== -1 && (t = t.slice(r + 1)), C) {
2535
+ if (t === "is" || t === "v") {
2536
+ let e = l?.onEnd?.();
2537
+ e != null && n.pushAt(w, T, "" + e);
2538
+ } else t !== "f" && l?.onCloseTag?.(e);
2539
+ }
2540
+ f &&= !1, t === "c" && (ue = null, C = !1);
2541
+ } else {
2542
+ if (d) return d = !1, void (R = null);
2543
+ i?.onCloseTag?.(e);
2544
+ }
2545
+ }, De = (e) => {
2546
+ let t = e.trim();
2547
+ if (f) {
2548
+ switch (E = null, D) {
2549
+ case null:
2550
+ case "n":
2551
+ E = parseFloat(t);
2552
+ break;
2553
+ case "b":
2554
+ E = t === "1" || t === "true";
2555
+ break;
2556
+ case "s":
2557
+ E = t;
2558
+ break;
2559
+ case "e":
2560
+ if (t === "#VALUE!") {
2561
+ let e = ue.attributes.vm;
2562
+ if (e !== void 0) {
2563
+ let t = x[parseInt(e) - 1];
2564
+ if (s.isError(t)) {
2565
+ E = {
2566
+ t: "e",
2567
+ v: t.getCode()
2568
+ };
2569
+ break;
2570
+ }
2571
+ }
2572
+ }
2573
+ let e = s.getBuiltInByLabel(t);
2574
+ e ? E = {
2575
+ t: "e",
2576
+ v: e.getCode()
2577
+ } : (E = t, a?.(`Unknown formula error '${t}' in cell ${m.cellToString({
2578
+ colIndex: T,
2579
+ rowIndex: w
2580
+ })}`));
2581
+ break;
2582
+ case "str":
2583
+ case "inlineStr": C = !0;
2584
+ }
2585
+ E !== null && n.pushAt(w, T, E);
2586
+ }
2587
+ if (g) {
2588
+ if (b === g) y = ee;
2589
+ else {
2590
+ if (y = S.get(g) ?? null, !y) {
2591
+ let e = [];
2592
+ v = ne(t, w, T, e), y = [
2593
+ v,
2594
+ e,
2595
+ t
2596
+ ], S.set(g, y);
2597
+ }
2598
+ b = g, ee = y;
2599
+ }
2600
+ g = null;
2601
+ }
2602
+ if (h) {
2603
+ if (te !== null) {
2604
+ let e = ((e) => {
2605
+ if (e.length < Ft.length || e.slice(0, Ft.length).toUpperCase() !== It) return Rt;
2606
+ let t = Bt(e, Ft.length);
2607
+ if (t === null || e.charCodeAt(t.end) !== 41 || e.charCodeAt(t.end + 1) !== 44 || e.charCodeAt(e.length - 1) !== 41) return Rt;
2608
+ let n = t.value;
2609
+ return n.toUpperCase() === Lt ? zt : n.length === 0 ? Rt : {
2610
+ kind: "formula",
2611
+ formula: n
2612
+ };
2613
+ })(t);
2614
+ e.kind !== "none" && te.push({
2615
+ sheet: r,
2616
+ rowIndex: w,
2617
+ colIndex: T,
2618
+ formula: e.kind === "formula" ? e.formula : null
2619
+ });
2620
+ }
2621
+ let e = [];
2622
+ v = ne(t, w, T, e), y = [
2623
+ v,
2624
+ e,
2625
+ t
2626
+ ];
2627
+ }
2628
+ C ? l?.onText?.(e) : d || i?.onText?.(t);
2629
+ }, z = {
2630
+ r: void 0,
2631
+ t: void 0,
2632
+ s: void 0,
2633
+ cm: void 0,
2634
+ vm: void 0
2635
+ }, Oe = {
2636
+ name: "c",
2637
+ attributes: z,
2638
+ isSelfClosing: !1
2639
+ }, B = {
2640
+ t: void 0,
2641
+ si: void 0,
2642
+ ref: void 0,
2643
+ ca: void 0
2644
+ }, ke = {
2645
+ name: "f",
2646
+ attributes: B,
2647
+ isSelfClosing: !1
2648
+ }, Ae = {
2649
+ name: "v",
2650
+ attributes: {},
2651
+ isSelfClosing: !1
2652
+ }, V = {
2653
+ r: void 0,
2654
+ s: void 0,
2655
+ ht: void 0,
2656
+ hidden: void 0,
2657
+ collapsed: void 0,
2658
+ customHeight: void 0,
2659
+ customFormat: void 0,
2660
+ outlineLevel: void 0
2661
+ }, je = {
2662
+ name: "row",
2663
+ attributes: V,
2664
+ isSelfClosing: !1
2665
+ }, Me = jt.NEED_MORE, H = jt.NOT_HANDLED, U = jt.decodeText, Ne = !1, Pe = (e, t, n, r) => {
2666
+ for (;;) {
2667
+ let i = 0;
2668
+ for (; t < n && ((i = e.charCodeAt(t)) === 32 || i === 9 || i === 10 || i === 13);) t++;
2669
+ if (t >= n) return Me;
2670
+ if (i === 62) return Ne = !1, t + 1;
2671
+ if (i === 47) return t + 1 >= n ? Me : e.charCodeAt(t + 1) === 62 ? (Ne = !0, t + 2) : H;
2672
+ let a = t;
2673
+ for (; t < n && (i = e.charCodeAt(t)) !== 61;) {
2674
+ if (i === 62 || i === 47 || i === 32 || i === 9 || i === 10 || i === 13) return H;
2675
+ t++;
2676
+ }
2677
+ if (t + 1 >= n) return Me;
2678
+ let o = t - a, s = e.charCodeAt(t + 1);
2679
+ if (s !== 34 && s !== 39) return H;
2680
+ let c = t + 2, l = c;
2681
+ for (; l < n && (i = e.charCodeAt(l)) !== s;) {
2682
+ if (i === 38 || i < 32) return H;
2683
+ l++;
2684
+ }
2685
+ if (l >= n) return Me;
2686
+ t = l + 1;
2687
+ let u = e.charCodeAt(a);
2688
+ if (r === 2) switch (o) {
2689
+ case 1:
2690
+ u === 114 ? V.r = e.slice(c, l) : u === 115 && (V.s = e.slice(c, l));
2691
+ break;
2692
+ case 2:
2693
+ e.startsWith("ht", a) && (V.ht = e.slice(c, l));
2694
+ break;
2695
+ case 6:
2696
+ e.startsWith("hidden", a) && (V.hidden = e.slice(c, l));
2697
+ break;
2698
+ case 9:
2699
+ e.startsWith("collapsed", a) && (V.collapsed = e.slice(c, l));
2700
+ break;
2701
+ case 12: e.startsWith("customHeight", a) ? V.customHeight = e.slice(c, l) : e.startsWith("customFormat", a) ? V.customFormat = e.slice(c, l) : e.startsWith("outlineLevel", a) && (V.outlineLevel = e.slice(c, l));
2702
+ }
2703
+ else if (r === 0) o === 1 ? u === 114 ? z.r = e.slice(c, l) : u === 116 ? z.t = e.slice(c, l) : u === 115 && (z.s = e.slice(c, l)) : o === 2 && e.charCodeAt(a + 1) === 109 && (u === 99 ? z.cm = e.slice(c, l) : u === 118 && (z.vm = e.slice(c, l)));
2704
+ else if (o === 1) u === 116 && (B.t = e.slice(c, l));
2705
+ else if (o === 2) {
2706
+ let t = e.charCodeAt(a + 1);
2707
+ u === 115 && t === 105 ? B.si = e.slice(c, l) : u === 99 && t === 97 && (B.ca = e.slice(c, l));
2708
+ } else o === 3 && e.startsWith("ref", a) && (B.ref = e.slice(c, l));
2709
+ }
2710
+ }, Fe = (e, t, n) => e.charCodeAt(t + 1) === 47 && e.charCodeAt(t + 2) === n && e.charCodeAt(t + 3) === 62;
2711
+ return {
2712
+ ...i,
2713
+ onEnd: () => {
2714
+ O.length > 0 && (r.rows = m.runsToRefs(O, !1));
2715
+ let t = re.done(Kt), a = t.length;
2716
+ if (a > 0) {
2717
+ let e = Array(a);
2718
+ for (let n = 0; n < a; n++) {
2719
+ let r = t[n], i = m.rangeToString(r), a = r.value[1], o = m.resolveRelativeToA1(a, r.rowStart, r.colStart);
2720
+ e[n] = [i, o];
2721
+ }
2722
+ r.formulas = e;
2723
+ }
2724
+ let o = le.done(!0), s = o.length;
2725
+ if (s > 0) {
2726
+ let e = Array(s);
2727
+ for (let t = 0; t < s; t++) {
2728
+ let n = o[t], r = m.rangeToString(n);
2729
+ e[t] = r;
2730
+ }
2731
+ r.volatile = e;
2732
+ }
2733
+ ie.length > 0 && (r.formulaArray = [...ie]);
2734
+ let l = p.length;
2735
+ if (l > 0) {
2736
+ p.sort(e.createRangeComparator(c.Axis.Column));
2737
+ let t = p[0], n = t.colStart, i = t.colEnd, a = t.rowEnd, o = t.value, s = [];
2738
+ s.push(t);
2739
+ let u = null;
2740
+ for (let e = 1; e < l; e++) u = p[e], o !== u.value || n !== u.colStart || i !== u.colEnd || a + 1 !== u.rowEnd ? (s.push(u), t = u, n = t.colStart, i = t.colEnd, a = t.rowEnd, o = t.value) : (a = u.rowEnd, t.rowEnd = a);
2741
+ let d = s.length, f = Array(d);
2742
+ for (let e = 0; e < d; e++) {
2743
+ let t = s[e], n = m.rangeToString(t);
2744
+ f[e] = [n, t.value];
2745
+ }
2746
+ r.directStyles = f;
2747
+ }
2748
+ let u = n.build();
2749
+ u && (r.data = u.tuples), i?.onEnd?.();
2750
+ },
2751
+ onOpenTag: Te,
2752
+ onCloseTag: Ee,
2753
+ onText: De,
2754
+ elementScanners: [{
2755
+ name: "c",
2756
+ scan: (e, t, n) => {
2757
+ if (!d || ue !== null) return H;
2758
+ z.r = z.t = z.s = z.cm = z.vm = void 0;
2759
+ let r = Pe(e, t + 2, n, 0);
2760
+ if (r < 0) return r;
2761
+ let i = z.t;
2762
+ if (z.r === void 0 || i === "str" || i === "inlineStr") return H;
2763
+ let a = !1, o = -1, s = -1, c = -1, l = -1, u = r;
2764
+ if (!Ne) for (B.t = B.si = B.ref = B.ca = void 0;;) {
2765
+ let t = e.indexOf("<", r);
2766
+ if (t === -1 || t + 3 >= n) return Me;
2767
+ for (let n = r; n < t; n++) {
2768
+ let t = e.charCodeAt(n);
2769
+ if (t !== 32 && t !== 9 && t !== 10 && t !== 13) return H;
2770
+ }
2771
+ let i = e.charCodeAt(t + 1), d = e.charCodeAt(t + 2);
2772
+ if (i === 47) {
2773
+ if (!Fe(e, t, 99)) return H;
2774
+ u = t + 4;
2775
+ break;
2776
+ }
2777
+ if (i !== 102 || a || c !== -1 || d !== 32 && d !== 62 && d !== 47) {
2778
+ if (i !== 118 || d !== 62 || c !== -1) return H;
2779
+ {
2780
+ let i = e.indexOf("<", t + 3);
2781
+ if (i === -1 || i + 3 >= n) return Me;
2782
+ if (!Fe(e, i, 118)) return H;
2783
+ c = t + 3, l = i, r = i + 4;
2784
+ }
2785
+ } else {
2786
+ if (a = !0, r = Pe(e, t + 2, n, 1), r < 0) return r;
2787
+ if (Ne) continue;
2788
+ let i = e.indexOf("<", r);
2789
+ if (i === -1 || i + 3 >= n) return Me;
2790
+ if (!Fe(e, i, 102)) return H;
2791
+ o = r, s = i, r = i + 4;
2792
+ }
2793
+ }
2794
+ return Te(Oe), a && (Te(ke), s > o && De(U(e.slice(o, s))), Ee(ke)), c !== -1 && (Te(Ae), l > c && De(U(e.slice(c, l))), Ee(Ae)), Ee(Oe), u;
2795
+ }
2796
+ }, {
2797
+ name: "row",
2798
+ openTag: je,
2799
+ scan: (e, t, n) => {
2800
+ if (!xe || d || ue !== null) return H;
2801
+ V.r = V.s = V.ht = V.hidden = V.collapsed = V.customHeight = V.customFormat = V.outlineLevel = void 0;
2802
+ let r = Pe(e, t + 4, n, 2);
2803
+ return r < 0 ? r : Ne || V.r === void 0 ? H : (Te(je), r);
2804
+ }
2805
+ }]
2806
+ };
2807
+ }, Yt = "hiddenXfs", Xt = (e) => (Array.isArray(e) ? e[1] : e?.v)?.s, Zt = (e) => {
2808
+ if (!e || e.length === 0) return !1;
2809
+ let t = m.refsToRuns(e, !0), n = 0;
2810
+ for (let e of t) {
2811
+ if (e.min > n || e.value?.s === void 0) return !1;
2812
+ n = Math.max(n, e.max + 1);
2813
+ }
2814
+ return n > C;
2815
+ }, Qt = (e, t) => {
2816
+ e.protection = {
2817
+ ...e.protection,
2818
+ showFormulas: t
2819
+ };
2820
+ }, $t = (e) => {
2821
+ let t = e.indexOf(":");
2822
+ return t === -1 ? e : e.slice(t + 1);
2823
+ }, en = {
2824
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml": "workbooks",
2825
+ "application/vnd.ms-excel.sheet.macroEnabled.main+xml": "workbooks",
2826
+ "application/vnd.ms-excel.sheet.binary.macroEnabled.main": "workbooks",
2827
+ "application/vnd.ms-excel.addin.macroEnabled.main+xml": "workbooks",
2828
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml": "workbooks",
2829
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml": "sheets",
2830
+ "application/vnd.ms-excel.worksheet": "sheets",
2831
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml": "charts",
2832
+ "application/vnd.ms-excel.chartsheet": "charts",
2833
+ "application/vnd.ms-excel.macrosheet+xml": "macros",
2834
+ "application/vnd.ms-excel.macrosheet": "macros",
2835
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml": "dialogs",
2836
+ "application/vnd.ms-excel.dialogsheet": "dialogs",
2837
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml": "strs",
2838
+ "application/vnd.ms-excel.sharedStrings": "strs",
2839
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml": "styles",
2840
+ "application/vnd.ms-excel.styles": "styles",
2841
+ "application/vnd.openxmlformats-package.core-properties+xml": "coreprops",
2842
+ "application/vnd.openxmlformats-officedocument.custom-properties+xml": "custprops",
2843
+ "application/vnd.openxmlformats-officedocument.extended-properties+xml": "extprops",
2844
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml": "comments",
2845
+ "application/vnd.ms-excel.comments": "comments",
2846
+ "application/vnd.ms-excel.threadedcomments+xml": "threadedcomments",
2847
+ "application/vnd.ms-excel.person+xml": "people",
2848
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.sheetMetadata+xml": "metadata",
2849
+ "application/vnd.ms-excel.sheetMetadata": "metadata",
2850
+ "application/vnd.ms-excel.externalLink": "links",
2851
+ "application/vnd.openxmlformats-officedocument.spreadsheetml.externalLink+xml": "links",
2852
+ "application/vnd.openxmlformats-officedocument.theme+xml": "themes"
2853
+ }, tn = S({ readXLSX: () => on }), nn = (e) => e.startsWith("/") ? e.slice(1) : e, rn = /^xl\/(worksheets|chartsheets)\/[^/]+\.xml$/i, an = (e) => typeof e == "string" ? e : (e?.runs ?? []).map((e) => e.text ?? "").join(""), on = async (e, o) => {
2854
+ let { password: s, onVBA: c, profile: l, calcOnLoad: p = "auto", createWorkbookOptions: h = {}, ...v } = o ?? {}, y = !!h.origin && typeof h.origin != "string", x = l ? new U(typeof l == "function" ? l : void 0) : null, ne = [], re = (e, t, n) => {
2855
+ ne.push([
2856
+ e,
2857
+ t ?? "",
2858
+ n
2859
+ ]);
2860
+ }, S = { onWarning: re }, ie = o?.progress, ae = ie?.onProgress ? ie.onProgress.bind(ie) : void 0, oe = e.byteLength, le = 0, C = 0, E = ae ? (e) => {
2861
+ if (le <= 0) return;
2862
+ C += e;
2863
+ let t = Math.min(oe, Math.round(C / le * oe));
2864
+ ae(t, oe);
2865
+ } : void 0, ue = import("./sDVzjXC1mS5rucF5.mjs"), O = null;
2866
+ try {
2867
+ O = new DOMParser();
2868
+ } catch {}
2869
+ let k = null;
2870
+ try {
2871
+ k = new XMLSerializer();
2872
+ } catch {}
2873
+ let A, j, me, M = null;
2874
+ O || (M = import("./D7DWH3-5fBNx8jtc.mjs").then((e) => D(e.default, 1)));
2875
+ try {
2876
+ let [e, t] = await Promise.all([M, ue]);
2877
+ A = new t.DOMTransformer(), j = O ?? new e.DOMParser(), me = k ?? new e.XMLSerializer();
2878
+ } catch (e) {
2879
+ throw Error("Unable to load XLSX parser.", { cause: e });
2880
+ }
2881
+ let N, ge = (e) => me.serializeToString(e);
2882
+ try {
2883
+ N = await H.create(e);
2884
+ } catch (e) {
2885
+ throw new i("Unable to parse as an Excel document. Try to save as '.xlsx' and try again.", { cause: e });
2886
+ }
2887
+ x?.mark("zip-open");
2888
+ try {
2889
+ if (!N.has("[Content_Types].xml")) throw new i("Unable to parse as an Excel document. Try to save as '.xlsx' and try again.");
2890
+ let e = (e) => {
2891
+ let t = N.getEntry(e);
2892
+ return t ? { content: t } : void 0;
2893
+ }, r = {
2894
+ workbooks: [],
2895
+ sheets: [],
2896
+ charts: [],
2897
+ dialogs: [],
2898
+ macros: [],
2899
+ strs: [],
2900
+ comments: [],
2901
+ threadedcomments: [],
2902
+ links: [],
2903
+ coreprops: [],
2904
+ extprops: [],
2905
+ custprops: [],
2906
+ themes: [],
2907
+ styles: [],
2908
+ metadata: [],
2909
+ people: [],
2910
+ overrides: {},
2911
+ sst: "",
2912
+ style: "",
2913
+ defaults: {}
2914
+ };
2915
+ {
2916
+ let e = ((e) => ({
2917
+ onOpenTag: (t) => {
2918
+ let n = ((e) => {
2919
+ let t = e.indexOf(":");
2920
+ return t === -1 ? e : e.slice(t + 1);
2921
+ })(t.name), r = t.attributes;
2922
+ if (n === "Override") {
2923
+ let t = r.ContentType, n = r.PartName;
2924
+ if (!t || !n) return;
2925
+ e.overrides[n.startsWith("/") ? n.slice(1) : n] = t;
2926
+ let i = en[t], a = i ? e[i] : void 0;
2927
+ Array.isArray(a) && a.push(n);
2928
+ } else if (n === "Default") {
2929
+ let t = r.Extension, n = r.ContentType;
2930
+ t && (e.defaults[t.toLowerCase()] = n);
2931
+ }
2932
+ },
2933
+ onEnd: () => {
2934
+ e.sst = e.strs.length > 0 ? e.strs[0] : "", e.style = e.styles.length > 0 ? e.styles[0] : "";
2935
+ },
2936
+ onError: (e) => {
2937
+ ((e) => {
2938
+ ne.push([e, "[Content_Types].xml"]);
2939
+ })(`Error parsing content types: ${e?.message ?? e}`);
2940
+ }
2941
+ }))(r), t = await N.getTextStream("[Content_Types].xml");
2942
+ if (!t) throw Error("Error parsing content types: '[Content_Types].xml'");
2943
+ try {
2944
+ await Je.parseStream(t, e, { xmlns: !1 });
2945
+ } catch (e) {
2946
+ throw Error("Error parsing content types: '[Content_Types].xml'", { cause: e });
2947
+ }
2948
+ y && await N.getBuffer("[Content_Types].xml");
2949
+ }
2950
+ x?.mark("content-types");
2951
+ let o = r.sst, s = /* @__PURE__ */ new Set();
2952
+ for (let e of r.sheets) s.add(nn(e));
2953
+ o && s.add(nn(o));
2954
+ for (let e of s) le += N.uncompressedSize(e);
2955
+ if (await N.prefetch((e) => !s.has(e) && !rn.test(e)), x?.mark("prefetch-side-parts"), r.workbooks.length === 0) {
2956
+ let t = Oe("_rels/.rels", e, j, A, S);
2957
+ if (t) {
2958
+ for (let e of t.values()) if (e.type === "http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" && e.target) {
2959
+ r.workbooks.push(e.target);
2960
+ break;
2961
+ }
2962
+ }
2963
+ }
2964
+ if (r.workbooks.length === 0) throw new i("Unable to parse as an Excel document. Try to save as '.xlsx' and try again.");
2965
+ r.richstructure = ["/xl/richData/rdrichvaluestructure.xml"], r.richdata = ["/xl/richData/rdrichvalue.xml"];
2966
+ let v = h?.resources ?? new f(), C = v.beginPersist(), ue = {}, D = /* @__PURE__ */ new Set(), O = /* @__PURE__ */ new Map();
2967
+ O.set("richTypes", []), O.set("parseInlineDxf", (e) => {
2968
+ if (!e) return;
2969
+ let t = j.parseFromString(`<dxf xmlns:x14="${Se}" xmlns:xm="${pe}">${e}</dxf>`, "text/xml")?.documentElement;
2970
+ if (!t) return;
2971
+ let n = A.parseDxf(t, "", S);
2972
+ return Object.keys(n).length > 0 ? n : void 0;
2973
+ });
2974
+ let k = [];
2975
+ O.set("dummyWrapped", k);
2976
+ let me = B("metadata", r, e, j, A, S).entries().next()?.value?.[1]?.metadata;
2977
+ me && O.set("metadata", me), O.set(Ut, ce());
2978
+ let M = /* @__PURE__ */ new Map(), ve = [], ye = /* @__PURE__ */ new Set(), P = (e) => {
2979
+ ye.add(nn(e));
2980
+ }, I = (t, n = M) => {
2981
+ let r = t.lastIndexOf("/"), i = t.substring(0, r + 1) + "_rels/" + t.substring(r + 1, t.length) + ".rels", a = n.get(i);
2982
+ return a || (a = Oe(i, e, j, A, U), n.set(i, a)), a;
2983
+ }, L = (t, n, r, i = M) => {
2984
+ let a = I(n, i).get(t), o = a?.target;
2985
+ if (!o) return null;
2986
+ if (a.targetMode === "External") {
2987
+ if (!r) return a.target;
2988
+ let e = v.add({ source: { external: a.target } });
2989
+ return e.addReference(ue), D.add(e), C.toResourceId(e);
2990
+ }
2991
+ let s = n.lastIndexOf("/"), c = n.substring(0, s + 1);
2992
+ o.startsWith("/") || (o = c + o), o = ke(o);
2993
+ let l = A?.getVisitorParamsState().get("dxfs"), u = i.get(o);
2994
+ if (!u) {
2995
+ if (a.type === "http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet") {
2996
+ let e = {};
2997
+ u = e, ve.push((async () => {
2998
+ let t = Wt(e, (e, t) => t === "legacyDrawing" ? Ce(e, o) : t === "formControl" ? we(e, o) : t === "part" ? Ae(e, o) : L(e, o, t === "resource") ?? null, Le, l, () => {}, (e, t, n) => {
2999
+ re(e, t ? `${t} (${o})` : o, n);
3000
+ }, void 0, O), n = await N.getTextStream(o, E);
3001
+ if (n) try {
3002
+ await Je.parseStream(n, t, {
3003
+ xmlns: !1,
3004
+ lean: !0
3005
+ });
3006
+ } catch (e) {
3007
+ throw Error(`Error parsing sheet: '${o}'`, { cause: e });
3008
+ }
3009
+ let r = I(o, i);
3010
+ if (r) {
3011
+ xe(e, o, r, i), T(e), F(e);
3012
+ let t = [];
3013
+ r.forEach((e, n) => {
3014
+ if (e.type !== "http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotTable") return;
3015
+ let r = Ae(n, o, e.type, (e) => e !== "http://schemas.openxmlformats.org/officeDocument/2006/relationships/pivotCacheDefinition");
3016
+ if (!r?.xml) return;
3017
+ let i = /<pivotTableDefinition\b[^>]*>/.exec(r.xml)?.[0] ?? "", a = parseInt(/\scacheId="(\d+)"/.exec(i)?.[1] ?? "", 10);
3018
+ if (isNaN(a)) return void ne.push([`Pivot table '${r.name}' names no cache and was dropped.`, o]);
3019
+ let s = /\sname="([^"]*)"/.exec(i)?.[1];
3020
+ t.push({
3021
+ ...s ? { name: fe(s) } : {},
3022
+ cacheId: a,
3023
+ part: r
3024
+ });
3025
+ }), t.length > 0 && (e.pivotTables = t);
3026
+ }
3027
+ })());
3028
+ } else if (a.type === "http://schemas.openxmlformats.org/officeDocument/2006/relationships/externalLink") {
3029
+ let t = z(o, e, j, A, U);
3030
+ if (t && Object.keys(t).length !== 0) {
3031
+ let e = t, n = e.__bookRelId, r = e.__absoluteUrlRelId;
3032
+ delete e.__bookRelId, delete e.__absoluteUrlRelId;
3033
+ let a = [];
3034
+ I(o, i)?.forEach((e, t) => {
3035
+ if (e.targetMode === "External" && e.type && e.target) {
3036
+ let i = {
3037
+ type: e.type,
3038
+ target: e.target
3039
+ };
3040
+ t === n ? i.role = "book" : t === r && (i.role = "absoluteUrl"), a.push(i);
3041
+ }
3042
+ }), a.sort((e, t) => (e.role === "book" ? 0 : 1) - (t.role === "book" ? 0 : 1)), e.sources = a, P(o), u = e;
3043
+ } else u = null;
3044
+ } else u = r ? ((e, t, n, r = null) => {
3045
+ if (!e) return null;
3046
+ let i = e;
3047
+ i.startsWith("/") && (i = i.substring(1));
3048
+ let a = r?.parsedRefs?.get(e);
3049
+ if (a !== void 0) return a;
3050
+ let o = t(i);
3051
+ if (!o) return null;
3052
+ let s = o.content;
3053
+ try {
3054
+ n && (s = n(s, e));
3055
+ } catch (t) {
3056
+ De(e, t, r);
3057
+ }
3058
+ return r?.parsedRefs?.set(e, s), s;
3059
+ })(o, e, (e, t) => {
3060
+ let n = v.add({ source: { buffer: e } });
3061
+ return n.addReference(ue), D.add(n), C.toResourceId(n);
3062
+ }, U) : z(o, e, j, A, U);
3063
+ }
3064
+ return u;
3065
+ }, be = (e, t) => {
3066
+ if (!e) return null;
3067
+ let n = I(t, M)?.get(e);
3068
+ if (!n?.target || n.targetMode === "External") return null;
3069
+ let r = n.target;
3070
+ return r.startsWith("/") || (r = t.substring(0, t.lastIndexOf("/") + 1) + r), ke(r);
3071
+ }, xe = (e, n, r, i) => {
3072
+ let a = [], o = /* @__PURE__ */ new Map(), s = [];
3073
+ r.forEach((e, t) => {
3074
+ if (e.type !== "http://schemas.microsoft.com/office/2017/10/relationships/threadedComment") return;
3075
+ let r = L(t, n, !1, i)?.comments;
3076
+ if (!r) return;
3077
+ for (let e = 0; e < r.length; e++) {
3078
+ let t = r[e];
3079
+ if (!t?.v?.id) continue;
3080
+ let { parentId: n, done: i, content: c, ...l } = t.v, u = {
3081
+ ...l,
3082
+ content: an(c)
3083
+ };
3084
+ n ? s.push({
3085
+ parentId: n,
3086
+ json: u
3087
+ }) : (i && (u.done = !0), o.set(u.id, u), a.push({
3088
+ r: t.r,
3089
+ v: u
3090
+ }));
3091
+ }
3092
+ let c = be(t, n);
3093
+ c && P(c);
3094
+ });
3095
+ for (let e = 0; e < s.length; e++) {
3096
+ let { parentId: t, json: n } = s[e], r = o.get(t);
3097
+ r && (r.replies ??= []).push(n);
3098
+ }
3099
+ let c = [];
3100
+ if (r.forEach((e, r) => {
3101
+ if (e.type !== "http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments") return;
3102
+ let a = L(r, n, !1, i), s = a?.comments;
3103
+ if (!s) return;
3104
+ let l = a?.authors;
3105
+ for (let e = 0; e < s.length; e++) {
3106
+ let n = s[e];
3107
+ if (!n?.r) continue;
3108
+ let r = l && n.v.authorId !== void 0 ? l[n.v.authorId] : void 0;
3109
+ if (r && r.startsWith("tc=")) {
3110
+ if (o.has(je(r.substring(3)))) continue;
3111
+ r = void 0;
3112
+ }
3113
+ let i = {
3114
+ id: t.uuidV4().toUpperCase(),
3115
+ asNote: !0,
3116
+ content: n.v.content ?? ""
3117
+ }, a = r ? H({ displayName: r }) : void 0;
3118
+ a && (i.personId = a.id), c.push({
3119
+ r: n.r,
3120
+ v: i
3121
+ });
3122
+ }
3123
+ let u = be(r, n);
3124
+ u && P(u);
3125
+ }), a.length === 0 && c.length === 0) return;
3126
+ let l = [...a, ...c], u = e.legacyDrawing;
3127
+ if (u?.xml) {
3128
+ let { rest: t, notes: n } = _e(u.xml);
3129
+ if (n.length > 0) {
3130
+ let r = /* @__PURE__ */ new Map();
3131
+ for (let e = 0; e < n.length; e++) {
3132
+ let t = n[e];
3133
+ r.set(m.cellToString({
3134
+ rowIndex: t.row,
3135
+ colIndex: t.col
3136
+ }), t);
3137
+ }
3138
+ for (let e = 0; e < l.length; e++) {
3139
+ let t = l[e], n = r.get(String(t.r).toUpperCase());
3140
+ if (!n || (r.delete(String(t.r).toUpperCase()), !t.v.asNote)) continue;
3141
+ let i = de(n.xml), a = {};
3142
+ if (i.anchor) {
3143
+ let [e, t, r, o, s, c, l, u] = i.anchor;
3144
+ a.anchor = {
3145
+ tl: {
3146
+ c: e - n.col,
3147
+ x: t,
3148
+ r: r - n.row,
3149
+ y: o
3150
+ },
3151
+ br: {
3152
+ c: s - n.col,
3153
+ x: c,
3154
+ r: l - n.row,
3155
+ y: u
3156
+ }
3157
+ };
3158
+ }
3159
+ i.xml && (a.xml = i.xml), (a.anchor || a.xml) && (t.v.box = a), i.visible && (t.v.shown = !0), i.alt && (t.v.description = i.alt);
3160
+ }
3161
+ let i = [];
3162
+ r.forEach((e) => {
3163
+ i.push(e.xml);
3164
+ });
3165
+ let a = ee(t, i);
3166
+ a ? u.xml = a : delete e.legacyDrawing;
3167
+ }
3168
+ }
3169
+ e.comments = l;
3170
+ }, Ce = (t, n) => {
3171
+ let r = be(t, n);
3172
+ if (!r) return null;
3173
+ let i = e(nn(r));
3174
+ if (!i) return null;
3175
+ let a = { xml: new TextDecoder("utf-8").decode(i.content) }, o = [];
3176
+ return I(r, M)?.forEach((e, t) => {
3177
+ if (e.type !== "http://schemas.openxmlformats.org/officeDocument/2006/relationships/image") return;
3178
+ let n = L(t, r, !0);
3179
+ typeof n == "number" && o.push({
3180
+ id: t,
3181
+ resId: n
3182
+ });
3183
+ }), o.length > 0 && (a.images = o), P(r), a;
3184
+ }, we = (t, n) => {
3185
+ let r = be(t, n);
3186
+ if (!r) return null;
3187
+ let i = z(r, e, j, A, U)?.formControl ?? null;
3188
+ return i && P(r), i;
3189
+ }, Ae = (t, n, i, a, o = /* @__PURE__ */ new Set()) => {
3190
+ let s = be(t, n);
3191
+ if (!s || o.has(s)) return null;
3192
+ let c = i ?? I(n, M)?.get(t)?.type;
3193
+ if (!c) return null;
3194
+ let l = e(nn(s));
3195
+ if (!l) return null;
3196
+ o.add(s);
3197
+ let u = s.substring(s.lastIndexOf("/") + 1), d = r.overrides[nn(s)] ?? r.defaults[u.substring(u.lastIndexOf(".") + 1).toLowerCase()], f = {
3198
+ id: t,
3199
+ type: c,
3200
+ name: u
3201
+ };
3202
+ if (d && (f.contentType = d), ((e, t) => e ? e.endsWith("+xml") || e === "application/xml" : /\.(xml|rels|vml)$/i.test(t))(d, u)) f.xml = new TextDecoder("utf-8").decode(l.content);
3203
+ else {
3204
+ let e = L(t, n, !0);
3205
+ if (typeof e != "number") return null;
3206
+ f.resId = e;
3207
+ }
3208
+ let p = [];
3209
+ return I(s, M)?.forEach((e, t) => {
3210
+ if (!e?.type || a && !a(e.type)) return;
3211
+ if (e.targetMode === "External") {
3212
+ let n = L(t, s, !0);
3213
+ typeof n == "number" && p.push({
3214
+ id: t,
3215
+ type: e.type,
3216
+ resId: n
3217
+ });
3218
+ return;
3219
+ }
3220
+ let n = Ae(t, s, e.type, a, o);
3221
+ n && p.push(n);
3222
+ }), p.length > 0 && (f.parts = p), P(s), f;
3223
+ };
3224
+ B("coreprops", r, e, j, A, S), B("extprops", r, e, j, A, S);
3225
+ let V = new g(), Me = B("people", r, e, j, A, S);
3226
+ if (Me.size > 0) {
3227
+ let [e, t] = Me.entries().next().value;
3228
+ V.fromJSON(t?.persons), P(e);
3229
+ }
3230
+ let H = (e) => {
3231
+ if (e) return V.add(e).toJSON();
3232
+ }, U = {
3233
+ paramMap: O,
3234
+ getRefs: I,
3235
+ getRef: L,
3236
+ parsedRefs: M,
3237
+ readEmbeddedPart: (e, t) => Ae(e, t),
3238
+ addPerson: H,
3239
+ serializeElement: ge,
3240
+ onWarning: re
3241
+ }, Ne = [];
3242
+ if (o) {
3243
+ let e = await N.getTextStream(o, E);
3244
+ if (e) {
3245
+ let t = (() => {
3246
+ let e = !1, t = !1, n = 0, r = "";
3247
+ return {
3248
+ onOpenTag: (i) => {
3249
+ let a = $t(i.name);
3250
+ a === "t" ? e && n === 0 && (t = !0) : a === "si" ? (e = !0, r = "", n = 0) : a !== "rPh" && a !== "phoneticPr" || n++;
3251
+ },
3252
+ onText: (e) => {
3253
+ t && (r += e);
3254
+ },
3255
+ onCloseTag: (i) => {
3256
+ let a = $t(i.name);
3257
+ a === "t" ? t = !1 : a === "si" ? (((e) => {
3258
+ Ne.push(e);
3259
+ })(he(r)), e = !1, r = "") : a !== "rPh" && a !== "phoneticPr" || n > 0 && n--;
3260
+ },
3261
+ onError: (e) => {
3262
+ ((e) => {
3263
+ re(e, o);
3264
+ })(`Error parsing shared strings: ${e?.message ?? e}`);
3265
+ }
3266
+ };
3267
+ })();
3268
+ try {
3269
+ await Je.parseStream(e, t, { xmlns: !1 });
3270
+ } catch (e) {
3271
+ throw Error(`Error parsing shared strings: '${o}'`, { cause: e });
3272
+ }
3273
+ }
3274
+ }
3275
+ x?.mark("shared-strings");
3276
+ let Pe = Ne.length, Fe = /* @__PURE__ */ new Map(), Ie = Pe, Le = (e) => {
3277
+ let t = Fe.get(e);
3278
+ if (t !== void 0) return t;
3279
+ let n = Ie;
3280
+ return Fe.set(e, Ie++), Ne.push(e), n;
3281
+ }, Re = [];
3282
+ r.slicersCache = Re;
3283
+ let ze = N.getNames(), Be = ze.length;
3284
+ for (let e = 0; e < Be; e++) {
3285
+ let t = ze[e];
3286
+ t && t.startsWith("xl/slicerCache") && Re.push(`/${t}`);
3287
+ }
3288
+ let Ve = B("slicersCache", r, e, j, A, U), He = /* @__PURE__ */ new Map();
3289
+ Ve.forEach((e, t) => {
3290
+ e?.cacheName && (e.cachePath = t, He.set(e.cacheName, e));
3291
+ }), O.set("slicerCaches", He);
3292
+ let Ue = [];
3293
+ r.slicers = Ue;
3294
+ for (let e = 0; e < Be; e++) {
3295
+ let t = ze[e];
3296
+ t && t.startsWith("xl/slicers/") && t.endsWith(".xml") && Ue.push(`/${t}`);
3297
+ }
3298
+ B("richstructure", r, e, j, A, U), B("richdata", r, e, j, A, U);
3299
+ let We = B("themes", r, e, j, A, U), Ge = null;
3300
+ if (We && We.entries) {
3301
+ let e = We.entries().next();
3302
+ e?.value?.[1] && (Ge = e.value[1]);
3303
+ }
3304
+ let Ke = new u(Ge), qe = B("styles", r, e, j, A, U).entries().next()?.value?.[1];
3305
+ qe &&= JSON.parse(n.JSONStableStringify(qe));
3306
+ let W = B("workbooks", r, e, j, A, U);
3307
+ x?.mark("side-parts-json"), await Promise.all(ve);
3308
+ {
3309
+ let e = W.entries().next().value?.[1], t = ce(e?.names), n = e?.sheets ?? [];
3310
+ for (let e = 0; e < n.length; e++) {
3311
+ let r = n[e]?.sheet;
3312
+ r && se(r, t);
3313
+ }
3314
+ let r = e?.names;
3315
+ if (r) for (let e = 0; e < r.length; e++) {
3316
+ let n = r[e]?.ref;
3317
+ typeof n == "string" && (r[e].ref = t.readDetached(n));
3318
+ }
3319
+ }
3320
+ ae && le > 0 && (ae(oe, oe), await new Promise((e) => setTimeout(e, 0))), x?.mark("sheets");
3321
+ let Ye = {
3322
+ ...W.entries().next().value?.[1],
3323
+ styles: qe,
3324
+ theme: Ke.toJSON()
3325
+ };
3326
+ ((e, t) => {
3327
+ if (!t || t.size === 0) return;
3328
+ let n = e.styles;
3329
+ if (!n) return;
3330
+ let r = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set();
3331
+ for (let n of e.sheets ?? []) {
3332
+ let e = n?.sheet;
3333
+ if (!e) continue;
3334
+ let a = /* @__PURE__ */ new Set();
3335
+ Zt(e.cols) || a.add(0);
3336
+ for (let t of e.directStyles ?? []) a.add(Array.isArray(t) ? t[1] : t.v);
3337
+ for (let t of e.rows ?? []) {
3338
+ let e = Xt(t);
3339
+ e !== void 0 && a.add(e);
3340
+ }
3341
+ for (let t of e.cols ?? []) {
3342
+ let e = Xt(t);
3343
+ e !== void 0 && a.add(e);
3344
+ }
3345
+ let o = !1;
3346
+ for (let e of a) if (t.has(e)) {
3347
+ o = !0;
3348
+ break;
3349
+ }
3350
+ if (o) {
3351
+ e.protection = {
3352
+ ...e.protection ?? { sheet: !0 },
3353
+ showFormulas: !1
3354
+ };
3355
+ for (let e of a) (t.has(e) ? i : r).add(e);
3356
+ }
3357
+ }
3358
+ if (r.size === 0) return;
3359
+ let o = n.direct ??= [];
3360
+ for (let e of r) e !== 0 && Qt(o[e] ?? (o[e] = {}), !0);
3361
+ for (let e of i) e !== 0 && Qt(o[e] ?? (o[e] = {}), !1);
3362
+ if (r.has(0)) {
3363
+ let e = n.named ??= [], t = a.BuiltInName.Normal.toLowerCase(), r = e.find((e) => e.name?.toLowerCase() === t);
3364
+ r || (r = {
3365
+ name: a.BuiltInName.Normal,
3366
+ style: {}
3367
+ }, e.push(r)), Qt(r.style, !0);
3368
+ }
3369
+ })(Ye, O.get(Yt));
3370
+ {
3371
+ let t = /* @__PURE__ */ new Map();
3372
+ B("slicers", r, e, j, A, U).forEach((e, n) => {
3373
+ e?.slicers && t.set(n, e.slicers);
3374
+ }), function(e, t) {
3375
+ let n = e.sheets ?? [], r = /* @__PURE__ */ new Map();
3376
+ for (let e = 0; e < n.length; e++) {
3377
+ let t = n[e]?.sheet?.tables ?? [];
3378
+ for (let e = 0; e < t.length; e++) {
3379
+ let n = t[e], i = Array.isArray(n) ? n[1] : n?.v;
3380
+ if (!i?.id) continue;
3381
+ let a = (i.columns ?? []).map((e) => typeof e == "string" ? { name: e } : e);
3382
+ r.set(String(i.id), {
3383
+ name: i.name ?? "",
3384
+ columns: a
3385
+ });
3386
+ }
3387
+ }
3388
+ let i = /* @__PURE__ */ new Set();
3389
+ for (let e = 0; e < n.length; e++) {
3390
+ let a = n[e]?.sheet;
3391
+ if (!a) continue;
3392
+ let o = a.slicers, s = a.movables;
3393
+ if (o && s) for (let e = s.length - 1; e >= 0; e--) {
3394
+ let n = s[e].content;
3395
+ if (n?.type !== "slicer" || n.json?.source) continue;
3396
+ let a = n.name ?? "", c = o[a];
3397
+ if (!c?.tableId) continue;
3398
+ let l = r.get(String(c.tableId)), u = l ? Te(l.columns, c.columnId) : null;
3399
+ l && u ? (n.json = Ee(c, n.json, d.structuredReference(l.name, u.name)), i.add(a), c.cachePath && t.markAbsorbed(c.cachePath)) : (t.warn("A slicer names no table; it was not imported.", "xlsx.slicer.cacheDefinition"), s.splice(e, 1));
3400
+ }
3401
+ delete a.slicers;
3402
+ }
3403
+ t.slicerParts.forEach((e, n) => {
3404
+ let r = Object.keys(e);
3405
+ r.length > 0 && r.every((e) => i.has(e)) && t.markAbsorbed(n);
3406
+ });
3407
+ }(Ye, {
3408
+ warn: (e, t) => {
3409
+ re(e, "xl/slicers", t);
3410
+ },
3411
+ markAbsorbed: P,
3412
+ slicerParts: t
3413
+ });
3414
+ }
3415
+ Ye.calc = {
3416
+ ...Ye.calc ?? {},
3417
+ legacyIntersect: !0
3418
+ }, Ne.length > 0 && (Ye.strings = Ne);
3419
+ let Xe = V.toJSON();
3420
+ Xe && Xe.length > 0 && (Ye.people = Xe);
3421
+ let Ze = N.getEntry("xl/vbaProject.bin");
3422
+ if (Ze) try {
3423
+ let { VBAProject: e } = await import("./BsUrrzAgfyAdcCJW.mjs"), t = e.extract(Ze);
3424
+ if (t) {
3425
+ let n = /* @__PURE__ */ new Map();
3426
+ for (let e of Ye.sheets ?? []) {
3427
+ let t = e?.sheet?.codeName;
3428
+ t && n.set(t, e.sheet);
3429
+ }
3430
+ for (let r of t.modules) {
3431
+ let t = { language: "vba" }, { header: i, body: a } = e.splitAttributes(r.code);
3432
+ a && (t.source = a), i && (t.sourceHeader = i);
3433
+ let o = r.type === "document" ? n.get(r.name) : void 0;
3434
+ o || r.type !== "document" || (t.scope = "workbook");
3435
+ let s = o ? o.modules ??= {} : Ye.modules ??= {};
3436
+ s[r.name] || (s[r.name] = t);
3437
+ }
3438
+ c?.(t);
3439
+ } else ne.push(["Unable to parse VBA project.", "xl/vbaProject.bin"]);
3440
+ } catch (e) {
3441
+ ne.push([`Error extracting VBA: ${e?.message ?? e}`, "xl/vbaProject.bin"]);
3442
+ }
3443
+ let Qe = O.get("calcId"), $e = Qe === void 0 || !(Number(Qe) >= 191029), et = h.calcOnLoad ?? (p === "auto" && $e ? "full" : p), tt = {
3444
+ ...h,
3445
+ calcOnLoad: et,
3446
+ resources: v,
3447
+ json: Ye
3448
+ };
3449
+ tt.disableLoadAutoFit === void 0 && (tt.disableLoadAutoFit = !1), x?.mark("json-assembled");
3450
+ let G = new _(tt);
3451
+ if (x?.mark("workbook-constructed"), k.length > 0 && et !== "none") {
3452
+ await G.whenCalculationReady();
3453
+ let e = /* @__PURE__ */ new Map(), t = Ye.sheets ?? [], n = G.getSheets().getItems();
3454
+ for (let r = 0; r < t.length; r++) {
3455
+ let i = t[r]?.sheet, a = n[r];
3456
+ i && a && e.set(i, a);
3457
+ }
3458
+ ((e, t, n) => {
3459
+ if (t.length === 0) return;
3460
+ let r = e.getCalculation().getFunctions(), i = /* @__PURE__ */ new Map(), a = (e) => {
3461
+ let t = i.get(e);
3462
+ return t === void 0 && (t = r.getByName(e) !== null, i.set(e, t)), t;
3463
+ }, o = /* @__PURE__ */ new Map();
3464
+ for (let e of t) {
3465
+ let t = o.get(e.sheet);
3466
+ t || (t = [], o.set(e.sheet, t)), t.push(e);
3467
+ }
3468
+ for (let [e, t] of o) {
3469
+ let r = n.get(e);
3470
+ if (!r) continue;
3471
+ let i = (e, t) => `${e},${t}`, o = /* @__PURE__ */ new Set();
3472
+ for (let e of t) e.formula === null && o.add(i(e.rowIndex, e.colIndex));
3473
+ for (let e of t) {
3474
+ if (e.formula === null) continue;
3475
+ let t = Vt(e.formula), n = !0;
3476
+ for (let e of t) if (!a(e)) {
3477
+ n = !1;
3478
+ break;
3479
+ }
3480
+ if (!n) continue;
3481
+ let s = [], c = [[e.rowIndex, e.colIndex]], l = /* @__PURE__ */ new Set([i(e.rowIndex, e.colIndex)]);
3482
+ for (; c.length > 0;) {
3483
+ let [e, t] = c.pop(), n = [
3484
+ [e + 1, t],
3485
+ [e - 1, t],
3486
+ [e, t + 1],
3487
+ [e, t - 1]
3488
+ ];
3489
+ for (let [e, t] of n) {
3490
+ let n = i(e, t);
3491
+ !l.has(n) && o.has(n) && (l.add(n), s.push([e, t]), c.push([e, t]));
3492
+ }
3493
+ }
3494
+ for (let [e, t] of s) o.delete(i(e, t)), r.getRange({
3495
+ rowStart: e,
3496
+ colStart: t,
3497
+ rowEnd: e,
3498
+ colEnd: t
3499
+ }).clear();
3500
+ r.getRange({
3501
+ rowStart: e.rowIndex,
3502
+ colStart: e.colIndex,
3503
+ rowEnd: e.rowIndex,
3504
+ colEnd: e.colIndex
3505
+ }).setValue("=" + e.formula);
3506
+ }
3507
+ }
3508
+ })(G, k, e);
3509
+ }
3510
+ if (D.forEach((e) => {
3511
+ e.deleteReference(ue);
3512
+ }), C.endPersist(), y) {
3513
+ w(G);
3514
+ let e = /* @__PURE__ */ new Map(), t = 0;
3515
+ for (let n of N.getNames()) {
3516
+ let r = N.getEntry(n);
3517
+ if (!r) continue;
3518
+ let i = N.getRawEntry(n), a = i ? {
3519
+ data: r,
3520
+ uncompressedSize: N.uncompressedSize(n),
3521
+ raw: {
3522
+ compressedData: i.data,
3523
+ compressionMethod: i.compressionMethod,
3524
+ signature: i.signature
3525
+ }
3526
+ } : {
3527
+ data: r,
3528
+ uncompressedSize: N.uncompressedSize(n)
3529
+ };
3530
+ e.set(n, a), t += r.byteLength;
3531
+ }
3532
+ if (t > 67108864) ne.push([`Source package too large to retain (${t} bytes, limit ${te}); unmodeled parts will be dropped on save.`, "SourcePackage"]);
3533
+ else if (e.size > 0) {
3534
+ let t = new R(e, ye);
3535
+ b(G, t);
3536
+ let n = G.getSheets().getItems(), r = G.getTransactions().addListener({ onCommitEnd: (e) => {
3537
+ let n = e.getOperation()?.name;
3538
+ n !== "insertCells" && n !== "deleteCells" || t.markStructuralChange();
3539
+ } }), i = G.addListeners({ onSheetsChange: () => {
3540
+ let e = G.getSheets().getItems();
3541
+ (e.length !== n.length || e.some((e, t) => e !== n[t])) && t.markStructuralChange(), n = e;
3542
+ } });
3543
+ G.addListeners({ onClose: () => {
3544
+ r(), i(), w(G);
3545
+ } });
3546
+ }
3547
+ }
3548
+ if (ne.length && ie?.onWarning) {
3549
+ let e = /* @__PURE__ */ new Set();
3550
+ for (let t of ne) {
3551
+ let [n, r, i] = t, a = i ?? n;
3552
+ e.has(a) || (e.add(a), ie.onWarning(n, r));
3553
+ }
3554
+ }
3555
+ return x && !0 === l && console.table(x.toTable()), G;
3556
+ } catch (e) {
3557
+ let t = "Unable to parse XLSX.";
3558
+ throw e instanceof r && (t = "Unable to open XLSX. There are too many rows or columns."), Error(t, { cause: e });
3559
+ } finally {
3560
+ await N.close().catch(() => {});
3561
+ }
3562
+ };
3563
+ export { je as i, Yt as n, V as r, tn as t };