@sheetxl/mcp 0.0.0-stage → 0.8.0-beta.15

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 (509) hide show
  1. package/LICENSE.md +11 -0
  2. package/README.md +72 -2
  3. package/agent/instructions.md +66 -0
  4. package/assets/9U9XCqqdn-q3i2fj.js +123 -0
  5. package/assets/B-MqXm_7luDLwazY.js +596 -0
  6. package/assets/B2Ek-DWpZMGJ0V1Z.js +18 -0
  7. package/assets/B2udpZ-uIaql3AUh.js +104 -0
  8. package/assets/B4VnJacrzr1x4PHR.js +402 -0
  9. package/assets/B5lHOOQ_rkP4Mi2r.js +638 -0
  10. package/assets/B7gUyrfLln3TiyKM.js +14 -0
  11. package/assets/B9US2ZrF93KOjmAx.js +22 -0
  12. package/assets/BBb_3gEGzmEzbTIk.js +359 -0
  13. package/assets/BCy1zP97fsiIcvj6.js +18 -0
  14. package/assets/BFXeoFUbuc4IKTz9.js +28 -0
  15. package/assets/BFdeov2e_xUQPEY_.js +202 -0
  16. package/assets/BG5kgbDRXMc0re6W.js +242 -0
  17. package/assets/BJxfinOazQqqByc-.js +105 -0
  18. package/assets/BOPsJmq7v7HOKUkO.js +32 -0
  19. package/assets/BPwmBu_aouERJjiW.js +45 -0
  20. package/assets/BQMDOjNBMjAx9WiW.js +3011 -0
  21. package/assets/BQbF1RkUH8WyXqSD.js +780 -0
  22. package/assets/BRzp6DEIYUgM3NkN.js +369 -0
  23. package/assets/BSxTn2BhkEEeF9x_.js +2346 -0
  24. package/assets/BTQhJQ3e0hsiousD.js +28 -0
  25. package/assets/BZPTaa0WjpoUAbgZ.js +35 -0
  26. package/assets/BbAmA46MhQSu3ZF_.js +119 -0
  27. package/assets/BbcUxIZe3YXywsQR.js +28 -0
  28. package/assets/BeLr36oL3jmeXFFi.js +58 -0
  29. package/assets/Bg95xYj5siqhHVEz.js +594 -0
  30. package/assets/Bh0PNKlrR4VAqnP8.js +60500 -0
  31. package/assets/BjqQjxBuoXza8oqg.js +362 -0
  32. package/assets/BlPubAFi7DY7VrAo.js +33 -0
  33. package/assets/BleMG0hAQgjE8fTa.js +7 -0
  34. package/assets/Bn8D2bebQ2tFfwQt.js +310 -0
  35. package/assets/BrcQmHcE7Hcr1erJ.js +24 -0
  36. package/assets/BsQZI1vXTRE63Zy-.js +2368 -0
  37. package/assets/BtjqpAKczftx91BQ.js +96 -0
  38. package/assets/Btys7KwtvV3hz2F6.js +656 -0
  39. package/assets/BuUEsifnQALe49uk.js +857 -0
  40. package/assets/By-7OWXShMlFFejV.js +119 -0
  41. package/assets/C0CiMKC3lWK1z9p5.js +449 -0
  42. package/assets/C2OrZ8LZ-TI6eYG0.js +22 -0
  43. package/assets/C4z2IilWTuu2TWXw.js +3917 -0
  44. package/assets/C7ONfuYIWRmDu_vs.js +319 -0
  45. package/assets/C7Z1li2XjWi6bkrp.js +1556 -0
  46. package/assets/C97xDe_wBbLZh_uW.js +35 -0
  47. package/assets/CGBGyaCGdlZFQYK0.js +447 -0
  48. package/assets/CJ5WQnaoCsdr5gf4.js +1783 -0
  49. package/assets/CMK6tIDVqYYvK4GZ.js +55 -0
  50. package/assets/CMWAsUQ66V8fYrME.js +223 -0
  51. package/assets/CNz3LdmvsOEJoLO9.js +12 -0
  52. package/assets/CWVWdbY1B1-WLl9k.js +199 -0
  53. package/assets/CWl6oHiJxkNKRixk.js +17 -0
  54. package/assets/CXHslDxkWCuEcCSQ.js +13 -0
  55. package/assets/CZTSZL3T_f-vSXqM.js +7 -0
  56. package/assets/CduNzsdbTigxH-ZK.js +5220 -0
  57. package/assets/CecTe22WURiXbVdY.js +2260 -0
  58. package/assets/Cf2dcwmmmf13Rywg.js +146 -0
  59. package/assets/Cf9LpgZz-W5blzy_.js +27 -0
  60. package/assets/Cfhv_Yw_LT8VzAMt.js +255 -0
  61. package/assets/Cg51xaLRUkVOMdCZ.js +144 -0
  62. package/assets/ChWpsFGl-BYOnX_A.js +142 -0
  63. package/assets/ClNQN3vEg5b5qUDp.js +10289 -0
  64. package/assets/Crt2kLdGIlBHANgg.js +28 -0
  65. package/assets/CudNpUD78SrtJIiy.js +610 -0
  66. package/assets/CvngwB17_ve4W49b.js +639 -0
  67. package/assets/CwPBmcY6xSP8dNlh.js +51 -0
  68. package/assets/CxjchwpiqxPM1XKd.js +304 -0
  69. package/assets/D-ffk16w8c5w0mxI.js +71 -0
  70. package/assets/D0CHDsemn0S31ltt.js +32 -0
  71. package/assets/D7oUtYjetuykGhQ5.js +18 -0
  72. package/assets/D8J14MLlN2HRXdXB.js +20 -0
  73. package/assets/DA_ar3QKLKtJ9fJD.js +37 -0
  74. package/assets/DB-tkqI6wFXDKEfB.js +118 -0
  75. package/assets/DD8HNAUFroTCuD-b.js +7514 -0
  76. package/assets/DDnwKPJSznyfYDZS.js +49 -0
  77. package/assets/DEW2GxfGYqVFvrfg.js +23 -0
  78. package/assets/DH7sGHzxUqIQkDnd.js +16 -0
  79. package/assets/DJiLWtmPR2OQNjzi.js +19 -0
  80. package/assets/DKLm4nWzynGw1Kr9.js +15 -0
  81. package/assets/DPCKMM7sgWbrtB8z.js +81 -0
  82. package/assets/DTfl-4Iboi6TQU5m.js +37 -0
  83. package/assets/DVchxwp6w6lu2Ihu.js +7 -0
  84. package/assets/DaoSWy3EFlqpZaLr.js +4437 -0
  85. package/assets/DcWTBOi_iBFc6U4J.js +8338 -0
  86. package/assets/Dht2mcOSyYlPY32b.js +14 -0
  87. package/assets/Diee6f_qAmcZBd2_.js +52 -0
  88. package/assets/DkibD_CEVePaoj_y.js +7 -0
  89. package/assets/DlBdhv6NHgrNp5Yo.js +7 -0
  90. package/assets/DoILAmhKUOlKWRVw.js +12 -0
  91. package/assets/DpdHDTFOeuzDVNEe.js +405 -0
  92. package/assets/DsCI_ZYm_jDjXF3J.js +12996 -0
  93. package/assets/DvUUArnZwoYOKOuk.js +12 -0
  94. package/assets/DwLZpYUp85UHBE3H.js +63 -0
  95. package/assets/DwWngYJTgC0KLbih.js +184 -0
  96. package/assets/Dz8UUJ7Xc2oN5PBG.js +45 -0
  97. package/assets/FS9NbEKgQvz5wqvZ.js +1135 -0
  98. package/assets/F_f0jJqM5MrXGbwC.js +86 -0
  99. package/assets/FzNG48GE_wso6RII.js +173 -0
  100. package/assets/JO3zH9hupFSV6vj2.js +15 -0
  101. package/assets/LEJp05fjmflKgyqF.js +1760 -0
  102. package/assets/LyLlBk--VJD2V-f8.js +351 -0
  103. package/assets/OVRdpPUzR0-ueTxE.js +1860 -0
  104. package/assets/PpFbmF0DFeUdpb9I.js +145 -0
  105. package/assets/S16s2h9qoYVBlVEa.js +9137 -0
  106. package/assets/SHZe9VOU1prGs1F9.js +19 -0
  107. package/assets/U1XXGEPuuqIAzYl1.js +8 -0
  108. package/assets/ZuYfVKlp41IJnrOS.js +540 -0
  109. package/assets/_d5XJ7dn1CKKYrep.js +1131 -0
  110. package/assets/_fUXIv6nKvgZkhxn.js +23 -0
  111. package/assets/fDMpDhXp36CatF-G.js +23 -0
  112. package/assets/hulrR0PldUxMJm_F.js +504 -0
  113. package/assets/iujMYIEPx_v3sdPf.js +9109 -0
  114. package/assets/jPUOH4FHF4b-rapv.js +171 -0
  115. package/assets/jadLBUNBVR9mbZ35.js +4036 -0
  116. package/assets/jiEe5eKV3BFPBWfi.js +6294 -0
  117. package/assets/oxjm7Yr7u7MeaO5P.js +37 -0
  118. package/assets/vZZi_iKYHm05gAye.js +30 -0
  119. package/assets/wfVh0olISLRWdv9Q.js +47 -0
  120. package/assets/xmTQJJVyCrcq77WR.js +63 -0
  121. package/assets/xnhBSX6lAcmBM65y.js +32 -0
  122. package/index.js +8070 -0
  123. package/lib.js +7 -0
  124. package/licenses/dependencies.txt +1552 -0
  125. package/package.json +44 -3
  126. package/resources/contents.json +333 -0
  127. package/resources/fonts/@sheetxl/sdk/aptos-bold-italic.hinted.json +125 -0
  128. package/resources/fonts/@sheetxl/sdk/aptos-bold-italic.metrics.json +221 -0
  129. package/resources/fonts/@sheetxl/sdk/aptos-bold-italic.rows.json +8 -0
  130. package/resources/fonts/@sheetxl/sdk/aptos-bold.hinted.json +125 -0
  131. package/resources/fonts/@sheetxl/sdk/aptos-bold.metrics.json +221 -0
  132. package/resources/fonts/@sheetxl/sdk/aptos-bold.rows.json +8 -0
  133. package/resources/fonts/@sheetxl/sdk/aptos-display-bold-italic.hinted.json +125 -0
  134. package/resources/fonts/@sheetxl/sdk/aptos-display-bold-italic.metrics.json +221 -0
  135. package/resources/fonts/@sheetxl/sdk/aptos-display-bold-italic.rows.json +8 -0
  136. package/resources/fonts/@sheetxl/sdk/aptos-display-bold.hinted.json +125 -0
  137. package/resources/fonts/@sheetxl/sdk/aptos-display-bold.metrics.json +221 -0
  138. package/resources/fonts/@sheetxl/sdk/aptos-display-bold.rows.json +8 -0
  139. package/resources/fonts/@sheetxl/sdk/aptos-display-italic.hinted.json +124 -0
  140. package/resources/fonts/@sheetxl/sdk/aptos-display-italic.metrics.json +221 -0
  141. package/resources/fonts/@sheetxl/sdk/aptos-display-italic.rows.json +8 -0
  142. package/resources/fonts/@sheetxl/sdk/aptos-display-regular.hinted.json +125 -0
  143. package/resources/fonts/@sheetxl/sdk/aptos-display-regular.metrics.json +221 -0
  144. package/resources/fonts/@sheetxl/sdk/aptos-display-regular.rows.json +8 -0
  145. package/resources/fonts/@sheetxl/sdk/aptos-italic.hinted.json +125 -0
  146. package/resources/fonts/@sheetxl/sdk/aptos-italic.metrics.json +221 -0
  147. package/resources/fonts/@sheetxl/sdk/aptos-italic.rows.json +8 -0
  148. package/resources/fonts/@sheetxl/sdk/aptos-narrow-bold-italic.hinted.json +125 -0
  149. package/resources/fonts/@sheetxl/sdk/aptos-narrow-bold-italic.metrics.json +221 -0
  150. package/resources/fonts/@sheetxl/sdk/aptos-narrow-bold-italic.rows.json +8 -0
  151. package/resources/fonts/@sheetxl/sdk/aptos-narrow-bold.hinted.json +125 -0
  152. package/resources/fonts/@sheetxl/sdk/aptos-narrow-bold.metrics.json +221 -0
  153. package/resources/fonts/@sheetxl/sdk/aptos-narrow-bold.rows.json +8 -0
  154. package/resources/fonts/@sheetxl/sdk/aptos-narrow-italic.hinted.json +125 -0
  155. package/resources/fonts/@sheetxl/sdk/aptos-narrow-italic.metrics.json +221 -0
  156. package/resources/fonts/@sheetxl/sdk/aptos-narrow-italic.rows.json +8 -0
  157. package/resources/fonts/@sheetxl/sdk/aptos-narrow-regular.hinted.json +125 -0
  158. package/resources/fonts/@sheetxl/sdk/aptos-narrow-regular.metrics.json +221 -0
  159. package/resources/fonts/@sheetxl/sdk/aptos-narrow-regular.rows.json +8 -0
  160. package/resources/fonts/@sheetxl/sdk/aptos-regular.hinted.json +125 -0
  161. package/resources/fonts/@sheetxl/sdk/aptos-regular.metrics.json +221 -0
  162. package/resources/fonts/@sheetxl/sdk/aptos-regular.rows.json +8 -0
  163. package/resources/fonts/@sheetxl/sdk/arial-bold-italic.hinted.json +125 -0
  164. package/resources/fonts/@sheetxl/sdk/arial-bold-italic.metrics.json +139 -0
  165. package/resources/fonts/@sheetxl/sdk/arial-bold-italic.rows.json +8 -0
  166. package/resources/fonts/@sheetxl/sdk/arial-bold.hinted.json +125 -0
  167. package/resources/fonts/@sheetxl/sdk/arial-bold.metrics.json +139 -0
  168. package/resources/fonts/@sheetxl/sdk/arial-bold.rows.json +8 -0
  169. package/resources/fonts/@sheetxl/sdk/arial-italic.hinted.json +125 -0
  170. package/resources/fonts/@sheetxl/sdk/arial-italic.metrics.json +139 -0
  171. package/resources/fonts/@sheetxl/sdk/arial-italic.rows.json +8 -0
  172. package/resources/fonts/@sheetxl/sdk/arial-regular.hinted.json +125 -0
  173. package/resources/fonts/@sheetxl/sdk/arial-regular.metrics.json +139 -0
  174. package/resources/fonts/@sheetxl/sdk/arial-regular.rows.json +8 -0
  175. package/resources/fonts/@sheetxl/sdk/calibri-bold-italic.hinted.json +122 -0
  176. package/resources/fonts/@sheetxl/sdk/calibri-bold-italic.metrics.json +137 -0
  177. package/resources/fonts/@sheetxl/sdk/calibri-bold-italic.rows.json +8 -0
  178. package/resources/fonts/@sheetxl/sdk/calibri-bold.hinted.json +122 -0
  179. package/resources/fonts/@sheetxl/sdk/calibri-bold.metrics.json +137 -0
  180. package/resources/fonts/@sheetxl/sdk/calibri-bold.rows.json +8 -0
  181. package/resources/fonts/@sheetxl/sdk/calibri-italic.hinted.json +121 -0
  182. package/resources/fonts/@sheetxl/sdk/calibri-italic.metrics.json +137 -0
  183. package/resources/fonts/@sheetxl/sdk/calibri-italic.rows.json +8 -0
  184. package/resources/fonts/@sheetxl/sdk/calibri-regular.hinted.json +121 -0
  185. package/resources/fonts/@sheetxl/sdk/calibri-regular.metrics.json +137 -0
  186. package/resources/fonts/@sheetxl/sdk/calibri-regular.rows.json +8 -0
  187. package/resources/fonts/@sheetxl/sdk/cambria-bold-italic.hinted.json +105 -0
  188. package/resources/fonts/@sheetxl/sdk/cambria-bold-italic.metrics.json +66 -0
  189. package/resources/fonts/@sheetxl/sdk/cambria-bold-italic.rows.json +8 -0
  190. package/resources/fonts/@sheetxl/sdk/cambria-bold.hinted.json +108 -0
  191. package/resources/fonts/@sheetxl/sdk/cambria-bold.metrics.json +66 -0
  192. package/resources/fonts/@sheetxl/sdk/cambria-bold.rows.json +8 -0
  193. package/resources/fonts/@sheetxl/sdk/cambria-italic.hinted.json +102 -0
  194. package/resources/fonts/@sheetxl/sdk/cambria-italic.metrics.json +66 -0
  195. package/resources/fonts/@sheetxl/sdk/cambria-italic.rows.json +8 -0
  196. package/resources/fonts/@sheetxl/sdk/cambria-regular.hinted.json +110 -0
  197. package/resources/fonts/@sheetxl/sdk/cambria-regular.metrics.json +66 -0
  198. package/resources/fonts/@sheetxl/sdk/cambria-regular.rows.json +8 -0
  199. package/resources/fonts/@sheetxl/sdk/contents.json +646 -0
  200. package/resources/fonts/@sheetxl/sdk/courier-new-bold-italic.hinted.json +11 -0
  201. package/resources/fonts/@sheetxl/sdk/courier-new-bold-italic.metrics.json +143 -0
  202. package/resources/fonts/@sheetxl/sdk/courier-new-bold-italic.rows.json +8 -0
  203. package/resources/fonts/@sheetxl/sdk/courier-new-bold.hinted.json +11 -0
  204. package/resources/fonts/@sheetxl/sdk/courier-new-bold.metrics.json +143 -0
  205. package/resources/fonts/@sheetxl/sdk/courier-new-bold.rows.json +8 -0
  206. package/resources/fonts/@sheetxl/sdk/courier-new-italic.hinted.json +11 -0
  207. package/resources/fonts/@sheetxl/sdk/courier-new-italic.metrics.json +143 -0
  208. package/resources/fonts/@sheetxl/sdk/courier-new-italic.rows.json +8 -0
  209. package/resources/fonts/@sheetxl/sdk/courier-new-regular.hinted.json +11 -0
  210. package/resources/fonts/@sheetxl/sdk/courier-new-regular.metrics.json +143 -0
  211. package/resources/fonts/@sheetxl/sdk/courier-new-regular.rows.json +8 -0
  212. package/resources/fonts/@sheetxl/sdk/times-new-roman-bold-italic.hinted.json +125 -0
  213. package/resources/fonts/@sheetxl/sdk/times-new-roman-bold-italic.metrics.json +141 -0
  214. package/resources/fonts/@sheetxl/sdk/times-new-roman-bold-italic.rows.json +8 -0
  215. package/resources/fonts/@sheetxl/sdk/times-new-roman-bold.hinted.json +125 -0
  216. package/resources/fonts/@sheetxl/sdk/times-new-roman-bold.metrics.json +141 -0
  217. package/resources/fonts/@sheetxl/sdk/times-new-roman-bold.rows.json +8 -0
  218. package/resources/fonts/@sheetxl/sdk/times-new-roman-italic.hinted.json +125 -0
  219. package/resources/fonts/@sheetxl/sdk/times-new-roman-italic.metrics.json +143 -0
  220. package/resources/fonts/@sheetxl/sdk/times-new-roman-italic.rows.json +8 -0
  221. package/resources/fonts/@sheetxl/sdk/times-new-roman-regular.hinted.json +125 -0
  222. package/resources/fonts/@sheetxl/sdk/times-new-roman-regular.metrics.json +141 -0
  223. package/resources/fonts/@sheetxl/sdk/times-new-roman-regular.rows.json +8 -0
  224. package/resources/locales/@sheetxl/formulas/contents.json +9 -0
  225. package/resources/locales/@sheetxl/formulas/de/functions.json +298 -0
  226. package/resources/locales/@sheetxl/formulas-extended/contents.json +9 -0
  227. package/resources/locales/@sheetxl/formulas-extended/de/functions.json +59 -0
  228. package/resources/locales/@sheetxl/sdk/contents.json +19 -0
  229. package/resources/locales/@sheetxl/sdk/de/grammar.json +16 -0
  230. package/resources/locales/@sheetxl/sdk/de/model.msg.json +710 -0
  231. package/resources/locales/@sheetxl/sdk/en/model.msg.json +732 -0
  232. package/screenshot-page/assets/-cpi3yOZYn6GsYN4.js +9 -0
  233. package/screenshot-page/assets/-i_fTASJeu9NdNH_.js +7 -0
  234. package/screenshot-page/assets/0MTaPYjKud2Q9QG9.js +1 -0
  235. package/screenshot-page/assets/21oAESJyBGXeHegm.js +2 -0
  236. package/screenshot-page/assets/3Ls_kOvlQseMV8Q0.js +1 -0
  237. package/screenshot-page/assets/4qZpl2QCzneWdmJO.js +1 -0
  238. package/screenshot-page/assets/6IEV7KeOEbBdrthj.js +1 -0
  239. package/screenshot-page/assets/8QrkTrKHDnMBb7q4.js +1 -0
  240. package/screenshot-page/assets/9w0ECZmzGUyk3F_O.js +1 -0
  241. package/screenshot-page/assets/AjS2PipZDIH3BXB2.js +1 -0
  242. package/screenshot-page/assets/B-KIwD5F_5S-NsPg.js +1 -0
  243. package/screenshot-page/assets/B-sAzW5ROrhvMGM4.js +1 -0
  244. package/screenshot-page/assets/B0FQypGas6gbGT_U.js +1 -0
  245. package/screenshot-page/assets/B2IQMVqTZT1rUnib.js +1 -0
  246. package/screenshot-page/assets/B2MJPcMcsuv6FekC.js +1 -0
  247. package/screenshot-page/assets/B2g3jiFIQ4Qjh5gG.js +1 -0
  248. package/screenshot-page/assets/B4PbXdzBe9BsoZ0e.js +2 -0
  249. package/screenshot-page/assets/B5GO9v4p9L70Xb9i.js +1 -0
  250. package/screenshot-page/assets/B8y_eLNCGnXLEIaE.js +1 -0
  251. package/screenshot-page/assets/BEuMvXYIa9A1JacY.js +1 -0
  252. package/screenshot-page/assets/BEwl-ucV9Jfr0RoC.js +1 -0
  253. package/screenshot-page/assets/BFaiQZKle44Rhyou.js +1 -0
  254. package/screenshot-page/assets/BHqg55S-4_OoAu3P.js +2 -0
  255. package/screenshot-page/assets/BNgLvS2bLOYKRguv.js +1 -0
  256. package/screenshot-page/assets/BQAN82ftWBiLJT3r.js +1 -0
  257. package/screenshot-page/assets/BQfe-XTIOGeUnD9B.js +1 -0
  258. package/screenshot-page/assets/BQnELVV0uR4T4ItQ.js +1 -0
  259. package/screenshot-page/assets/BRVZJ0OGJg9XJro6.js +1 -0
  260. package/screenshot-page/assets/BSdFVGZNhU6YHbMI.js +2 -0
  261. package/screenshot-page/assets/BTMW3ukmc44U2fy7.js +1 -0
  262. package/screenshot-page/assets/BTOQaSn9DDyJPUlX.js +1 -0
  263. package/screenshot-page/assets/BTboCICZ-951XWsi.js +1 -0
  264. package/screenshot-page/assets/BUGXf2DEBog16Slb.js +2 -0
  265. package/screenshot-page/assets/BUjI304IvdJnFXH3.js +1 -0
  266. package/screenshot-page/assets/B_W2QroTKADz3ABp.js +2 -0
  267. package/screenshot-page/assets/Baz0SC2AgGyxMX72.js +1 -0
  268. package/screenshot-page/assets/BbP9KThfrodyosvn.js +1 -0
  269. package/screenshot-page/assets/BcOdl17EeFSxnAiq.js +1 -0
  270. package/screenshot-page/assets/BclKeOKIOBjijhsu.js +1 -0
  271. package/screenshot-page/assets/Bf7xq8PyF4ohjMzP.js +2 -0
  272. package/screenshot-page/assets/BimyzECCZl-NESff.js +1 -0
  273. package/screenshot-page/assets/Bj-vfAT28PK-tWWa.js +2 -0
  274. package/screenshot-page/assets/BkLH7JH3A93TXFJi.js +1 -0
  275. package/screenshot-page/assets/BksaQEoZr5OWq-_d.js +3 -0
  276. package/screenshot-page/assets/BnoVwUBEor8NgQNs.js +4 -0
  277. package/screenshot-page/assets/BowRIybLgENunTOT.js +1 -0
  278. package/screenshot-page/assets/Bp7se0JaDGrzfSA_.js +1 -0
  279. package/screenshot-page/assets/Bx61vmiWY0Xvx9qs.js +1 -0
  280. package/screenshot-page/assets/ByY3fmwyDPAyOLdo.js +1 -0
  281. package/screenshot-page/assets/Bz5V1tmiy5gbT9ys.js +1 -0
  282. package/screenshot-page/assets/Bz9v1lgjvbu4QnOs.js +2 -0
  283. package/screenshot-page/assets/BzQ5GyiXq8gTz-H-.js +1 -0
  284. package/screenshot-page/assets/C1k_VrZqlpiUigCP.js +1 -0
  285. package/screenshot-page/assets/C2Wh2h27c7FUb8Yk.js +1 -0
  286. package/screenshot-page/assets/C6oLDVnuCS9LGkkH.js +1 -0
  287. package/screenshot-page/assets/C81mK8aZKZAAS-AB.js +1 -0
  288. package/screenshot-page/assets/C9SC-cEIt6gdhZRw.js +1 -0
  289. package/screenshot-page/assets/CE8MCCIiwjOVwBBW.js +1 -0
  290. package/screenshot-page/assets/CG3ynup87FmG-kkX.js +1 -0
  291. package/screenshot-page/assets/CHlWgOAlcRCjVuhg.js +1 -0
  292. package/screenshot-page/assets/CIged53b3hHKxa-o.js +1 -0
  293. package/screenshot-page/assets/CNQczIR5xcE5u5fT.js +1 -0
  294. package/screenshot-page/assets/CSUd8n1H0VBfREnk.js +2 -0
  295. package/screenshot-page/assets/CSlBTkRDITCC8JRB.js +1 -0
  296. package/screenshot-page/assets/CV2jr9hpQOG2OG0C.js +1 -0
  297. package/screenshot-page/assets/CXGgKVbVXjWzE0p6.js +1 -0
  298. package/screenshot-page/assets/CXKCmZ_TRyGaB9Ob.js +1 -0
  299. package/screenshot-page/assets/CXUO3vYip3JPSJ7A.js +1 -0
  300. package/screenshot-page/assets/CXwbGzavyvYgDbWU.js +1 -0
  301. package/screenshot-page/assets/CZf9s6otzzoaBlSs.js +1 -0
  302. package/screenshot-page/assets/CZvwQEeVhBilgKLG.js +1 -0
  303. package/screenshot-page/assets/Ca6nxdhEuLLty3d7.js +2 -0
  304. package/screenshot-page/assets/CbUDukmvDZmVfhJH.js +1 -0
  305. package/screenshot-page/assets/CbXtAM7H-Jg_J0dk.js +1 -0
  306. package/screenshot-page/assets/CctIRGMFmARVi2KT.js +1 -0
  307. package/screenshot-page/assets/Cenh1POxiGMxIQlv.js +1 -0
  308. package/screenshot-page/assets/ChSvXfVMLxZsP9zG.js +8 -0
  309. package/screenshot-page/assets/Ci5NtzhJLll1kxGf.js +10 -0
  310. package/screenshot-page/assets/CjngjJNheGaVRvZp.js +1 -0
  311. package/screenshot-page/assets/ClzdIJrFdInttVJA.js +1 -0
  312. package/screenshot-page/assets/CnPgk3HcIziOcskY.js +10 -0
  313. package/screenshot-page/assets/CnXLpFE_vFrJ5Jbf.js +1 -0
  314. package/screenshot-page/assets/CpbohdgEaEsVDi9J.js +1 -0
  315. package/screenshot-page/assets/CqR3hGrC956TkCMj.js +20 -0
  316. package/screenshot-page/assets/Cr1tQKUBVKOQl3QC.js +1 -0
  317. package/screenshot-page/assets/CwqNb7JYzC03lCj0.js +1 -0
  318. package/screenshot-page/assets/CykecBozGGFl26KA.js +3940 -0
  319. package/screenshot-page/assets/CzTizxHhb-CI_ajE.js +1 -0
  320. package/screenshot-page/assets/CzhH7lTYQrYGHct6.js +1 -0
  321. package/screenshot-page/assets/CzzEl3lAkZopkwhC.js +1 -0
  322. package/screenshot-page/assets/D-LgRj0s-PAVqY-L.js +1 -0
  323. package/screenshot-page/assets/D-XR1MGhwn7Jqj60.js +1 -0
  324. package/screenshot-page/assets/D47ePD4x1lVazNdl.js +7 -0
  325. package/screenshot-page/assets/D66vSE1ConAuENmB.js +586 -0
  326. package/screenshot-page/assets/D6Jpaz2YkhOfzxDB.js +1 -0
  327. package/screenshot-page/assets/D9zCVZpnJBfNSNO2.js +1 -0
  328. package/screenshot-page/assets/DCVUZ_ayOXFwV2d_.js +3 -0
  329. package/screenshot-page/assets/DDQWM8rNYCYzKa9R.js +1 -0
  330. package/screenshot-page/assets/DFE-fKq5NV7_O8V6.js +1 -0
  331. package/screenshot-page/assets/DGXDfjkGZjMRAXPg.js +5 -0
  332. package/screenshot-page/assets/DHa5_U58lSwCnpmG.js +1 -0
  333. package/screenshot-page/assets/DKVB6ddRfDJatYid.js +1 -0
  334. package/screenshot-page/assets/DK_QSosKV62NDcuT.js +42 -0
  335. package/screenshot-page/assets/DM9U7u7FQK0jcwh4.js +1 -0
  336. package/screenshot-page/assets/DNDaHmkQrQTaCHhV.js +1 -0
  337. package/screenshot-page/assets/DQ0kGd99-fXxuNYk.js +1 -0
  338. package/screenshot-page/assets/DQWHkaQeNXft9j8b.js +2 -0
  339. package/screenshot-page/assets/DRVfGdmVBvktrZ1t.js +1 -0
  340. package/screenshot-page/assets/DRrM-dY9nM7nDRpV.js +1 -0
  341. package/screenshot-page/assets/DT2x1gO3f2G5NfeB.js +1 -0
  342. package/screenshot-page/assets/DTFRGj188QuLKEXw.js +1 -0
  343. package/screenshot-page/assets/DU3FmyUH0RjPIBd-.js +1 -0
  344. package/screenshot-page/assets/DVueE--eOrZPrqrm.js +1 -0
  345. package/screenshot-page/assets/DXQLzGmxoyN3kfQi.js +27 -0
  346. package/screenshot-page/assets/DXWWyJlMSWgDFxs1.js +10 -0
  347. package/screenshot-page/assets/DYJSIlNxrNw8qk-w.js +1 -0
  348. package/screenshot-page/assets/DYRbCudWTaiE_Sjc.js +1 -0
  349. package/screenshot-page/assets/DZDRRw-62D6Zw7qs.js +1 -0
  350. package/screenshot-page/assets/DaKZ4-Li_ULIIwnK.js +1 -0
  351. package/screenshot-page/assets/DadZXeaVK5UXSHIi.js +1 -0
  352. package/screenshot-page/assets/Db_VGqQo2G2JgXWW.js +1 -0
  353. package/screenshot-page/assets/DceNHPrRLok2At-X.js +1 -0
  354. package/screenshot-page/assets/DcrVJCyDwGKeil2U.js +1 -0
  355. package/screenshot-page/assets/DeAKjatTVaZ0u_FY.js +1 -0
  356. package/screenshot-page/assets/DmMZ4pd492HPw_3_.js +1 -0
  357. package/screenshot-page/assets/DmbuCapSSCYIa3yk.js +1 -0
  358. package/screenshot-page/assets/Dpepompn_NhpSncR.js +1 -0
  359. package/screenshot-page/assets/DqYhS4mcQfOe96hU.js +1 -0
  360. package/screenshot-page/assets/Dsx0NUmGIxS7SvZ8.js +1 -0
  361. package/screenshot-page/assets/DyGpT6t96jrvgJes.js +1 -0
  362. package/screenshot-page/assets/DyLWQxXXTw5uwPVy.js +30 -0
  363. package/screenshot-page/assets/DyYVf8O1rhg3YmjW.js +1 -0
  364. package/screenshot-page/assets/DyxJBLjUkeDuu96F.js +1 -0
  365. package/screenshot-page/assets/HclGiUj8dZXDFmoM.js +1 -0
  366. package/screenshot-page/assets/IRtoU5oVgBWu9rnK.js +2 -0
  367. package/screenshot-page/assets/J73KTOmdZGNmnq-z.js +1 -0
  368. package/screenshot-page/assets/J_xJVgE7YlmeU-ZO.js +6 -0
  369. package/screenshot-page/assets/KoxRo2J_cwB_yOd5.js +2 -0
  370. package/screenshot-page/assets/LVtV_IPhPQroHRui.js +1 -0
  371. package/screenshot-page/assets/MNoPOsydrUv1UGU8.js +2 -0
  372. package/screenshot-page/assets/Q5EKmzoJZCE81Om-.js +2 -0
  373. package/screenshot-page/assets/TfhknTx8vxQkw4zV.js +2 -0
  374. package/screenshot-page/assets/VvqAh6BWzaD5OUPF.js +1 -0
  375. package/screenshot-page/assets/fGlPAximvsxzPzGA.js +1 -0
  376. package/screenshot-page/assets/gG0AFZ45VxS_moMw.js +2 -0
  377. package/screenshot-page/assets/hp_-JA1DMK4Yoztn.js +57 -0
  378. package/screenshot-page/assets/l32n8O_A78Qqduv3.js +1 -0
  379. package/screenshot-page/assets/nHThFXCAZFOM_npq.js +1 -0
  380. package/screenshot-page/assets/pRykm05ElquZBk_a.js +1 -0
  381. package/screenshot-page/assets/rPOkVKdPbFpTG6AY.js +1 -0
  382. package/screenshot-page/assets/sHBomL5R4-_px8rD.js +1 -0
  383. package/screenshot-page/assets/skRJ2qjA7kcmnOsh.js +39 -0
  384. package/screenshot-page/assets/w3bV7wggRayUYTd-.js +1 -0
  385. package/screenshot-page/assets/zFbb8ESzwR_bE7IQ.js +1 -0
  386. package/screenshot-page/index.html +44 -0
  387. package/screenshot-page/resources/contents.json +333 -0
  388. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-bold-italic.hinted.json +125 -0
  389. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-bold-italic.metrics.json +221 -0
  390. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-bold-italic.rows.json +8 -0
  391. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-bold.hinted.json +125 -0
  392. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-bold.metrics.json +221 -0
  393. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-bold.rows.json +8 -0
  394. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-bold-italic.hinted.json +125 -0
  395. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-bold-italic.metrics.json +221 -0
  396. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-bold-italic.rows.json +8 -0
  397. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-bold.hinted.json +125 -0
  398. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-bold.metrics.json +221 -0
  399. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-bold.rows.json +8 -0
  400. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-italic.hinted.json +124 -0
  401. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-italic.metrics.json +221 -0
  402. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-italic.rows.json +8 -0
  403. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-regular.hinted.json +125 -0
  404. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-regular.metrics.json +221 -0
  405. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-display-regular.rows.json +8 -0
  406. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-italic.hinted.json +125 -0
  407. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-italic.metrics.json +221 -0
  408. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-italic.rows.json +8 -0
  409. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-bold-italic.hinted.json +125 -0
  410. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-bold-italic.metrics.json +221 -0
  411. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-bold-italic.rows.json +8 -0
  412. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-bold.hinted.json +125 -0
  413. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-bold.metrics.json +221 -0
  414. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-bold.rows.json +8 -0
  415. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-italic.hinted.json +125 -0
  416. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-italic.metrics.json +221 -0
  417. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-italic.rows.json +8 -0
  418. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-regular.hinted.json +125 -0
  419. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-regular.metrics.json +221 -0
  420. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-narrow-regular.rows.json +8 -0
  421. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-regular.hinted.json +125 -0
  422. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-regular.metrics.json +221 -0
  423. package/screenshot-page/resources/fonts/@sheetxl/sdk/aptos-regular.rows.json +8 -0
  424. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-bold-italic.hinted.json +125 -0
  425. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-bold-italic.metrics.json +139 -0
  426. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-bold-italic.rows.json +8 -0
  427. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-bold.hinted.json +125 -0
  428. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-bold.metrics.json +139 -0
  429. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-bold.rows.json +8 -0
  430. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-italic.hinted.json +125 -0
  431. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-italic.metrics.json +139 -0
  432. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-italic.rows.json +8 -0
  433. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-regular.hinted.json +125 -0
  434. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-regular.metrics.json +139 -0
  435. package/screenshot-page/resources/fonts/@sheetxl/sdk/arial-regular.rows.json +8 -0
  436. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-bold-italic.hinted.json +122 -0
  437. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-bold-italic.metrics.json +137 -0
  438. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-bold-italic.rows.json +8 -0
  439. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-bold.hinted.json +122 -0
  440. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-bold.metrics.json +137 -0
  441. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-bold.rows.json +8 -0
  442. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-italic.hinted.json +121 -0
  443. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-italic.metrics.json +137 -0
  444. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-italic.rows.json +8 -0
  445. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-regular.hinted.json +121 -0
  446. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-regular.metrics.json +137 -0
  447. package/screenshot-page/resources/fonts/@sheetxl/sdk/calibri-regular.rows.json +8 -0
  448. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-bold-italic.hinted.json +105 -0
  449. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-bold-italic.metrics.json +66 -0
  450. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-bold-italic.rows.json +8 -0
  451. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-bold.hinted.json +108 -0
  452. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-bold.metrics.json +66 -0
  453. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-bold.rows.json +8 -0
  454. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-italic.hinted.json +102 -0
  455. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-italic.metrics.json +66 -0
  456. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-italic.rows.json +8 -0
  457. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-regular.hinted.json +110 -0
  458. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-regular.metrics.json +66 -0
  459. package/screenshot-page/resources/fonts/@sheetxl/sdk/cambria-regular.rows.json +8 -0
  460. package/screenshot-page/resources/fonts/@sheetxl/sdk/contents.json +646 -0
  461. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-bold-italic.hinted.json +11 -0
  462. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-bold-italic.metrics.json +143 -0
  463. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-bold-italic.rows.json +8 -0
  464. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-bold.hinted.json +11 -0
  465. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-bold.metrics.json +143 -0
  466. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-bold.rows.json +8 -0
  467. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-italic.hinted.json +11 -0
  468. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-italic.metrics.json +143 -0
  469. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-italic.rows.json +8 -0
  470. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-regular.hinted.json +11 -0
  471. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-regular.metrics.json +143 -0
  472. package/screenshot-page/resources/fonts/@sheetxl/sdk/courier-new-regular.rows.json +8 -0
  473. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-bold-italic.hinted.json +125 -0
  474. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-bold-italic.metrics.json +141 -0
  475. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-bold-italic.rows.json +8 -0
  476. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-bold.hinted.json +125 -0
  477. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-bold.metrics.json +141 -0
  478. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-bold.rows.json +8 -0
  479. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-italic.hinted.json +125 -0
  480. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-italic.metrics.json +143 -0
  481. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-italic.rows.json +8 -0
  482. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-regular.hinted.json +125 -0
  483. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-regular.metrics.json +141 -0
  484. package/screenshot-page/resources/fonts/@sheetxl/sdk/times-new-roman-regular.rows.json +8 -0
  485. package/screenshot-page/resources/locales/@sheetxl/formulas/contents.json +9 -0
  486. package/screenshot-page/resources/locales/@sheetxl/formulas/de/functions.json +298 -0
  487. package/screenshot-page/resources/locales/@sheetxl/formulas-extended/contents.json +9 -0
  488. package/screenshot-page/resources/locales/@sheetxl/formulas-extended/de/functions.json +59 -0
  489. package/screenshot-page/resources/locales/@sheetxl/sdk/contents.json +19 -0
  490. package/screenshot-page/resources/locales/@sheetxl/sdk/de/grammar.json +16 -0
  491. package/screenshot-page/resources/locales/@sheetxl/sdk/de/model.msg.json +710 -0
  492. package/screenshot-page/resources/locales/@sheetxl/sdk/en/model.msg.json +732 -0
  493. package/types/index.d.ts +1 -0
  494. package/types/lib.d.ts +2 -0
  495. package/types/scripting-api.json +10855 -0
  496. package/types/scripting-enums.json +1339 -0
  497. package/types/scripting.d.ts +49295 -0
  498. package/types/src/SessionRegistry.d.ts +630 -0
  499. package/types/src/index.d.ts +3 -0
  500. package/types/src/instances.d.ts +104 -0
  501. package/types/src/lib/Types.d.ts +17 -0
  502. package/types/src/lib/index.d.ts +2 -0
  503. package/types/src/lib/runReport.d.ts +158 -0
  504. package/types/src/lib.d.ts +2 -0
  505. package/types/src/prepareRun.d.ts +56 -0
  506. package/types/src/relay.d.ts +102 -0
  507. package/types/src/screenshot.d.ts +23 -0
  508. package/types/src/server.d.ts +37 -0
  509. package/types/src/taskStore.d.ts +28 -0
@@ -0,0 +1,2368 @@
1
+ /**
2
+ * @license @sheetxl/mcp - MCP server exposing SheetXL spreadsheet operations as tools and resources. - v0.8.0-beta.15
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 { ht as t } from "./BQMDOjNBMjAx9WiW.js";
8
+ import { L as e, T as o, U as s, Vt as r, m as i, st as n, yt as l } from "./iujMYIEPx_v3sdPf.js";
9
+ import { d as a, m as c } from "./BQbF1RkUH8WyXqSD.js";
10
+ import { $r as u, Hr as d, Wr as h, lt as p, vi as m } from "./Bh0PNKlrR4VAqnP8.js";
11
+ import { $ as f, $t as g, Bn as b, Cn as y, Dn as A, En as v, F as N, Fn as F, Ft as C, G as S, Gn as x, Ln as w, Ot as T, Pt as P, R as I, Tn as k, U as O, Vt as V, Xn as _, _n as B, an as L, bt as D, c as E, ct as R, gn as j, gt as Y, h as X, jn as M, ln as z, p as G, pn as $, pt as W, q as H, qn as U, qt as K, rn as q, xt as J, yt as Z, zn as Q } from "./DD8HNAUFroTCuD-b.js";
12
+ import "./DaoSWy3EFlqpZaLr.js";
13
+ import { a as st, o as rt, r as it } from "./BSxTn2BhkEEeF9x_.js";
14
+ var nt = class {
15
+ constructor(t) {
16
+ this.list = t;
17
+ }
18
+ get length() {
19
+ return this.list.length;
20
+ }
21
+ item(t) {
22
+ return this.list[t];
23
+ }
24
+ forEach(t, e) {
25
+ const o = this.list, s = o.length;
26
+ for (let e = 0; e < s; e++) t(o[e], e, this);
27
+ }
28
+ entries() {
29
+ return this.list.entries();
30
+ }
31
+ keys() {
32
+ return this.list.keys();
33
+ }
34
+ values() {
35
+ return this.list.values();
36
+ }
37
+ [Symbol.iterator]() {
38
+ return this.list.values();
39
+ }
40
+ }, lt = (t) => !0 === t || "1" === t || "on" === t || "true" === t || !1 !== t && "0" !== t && "off" !== t && "false" !== t && null, at = (t) => {
41
+ const e = parseInt(t);
42
+ return isNaN(e) ? null : e;
43
+ }, ct = (t) => {
44
+ const e = parseFloat(t);
45
+ return isNaN(e) ? null : e;
46
+ }, ut = /* @__PURE__ */ new Map(), dt = class {
47
+ constructor(e, o, s, r, i, n = null, l = t.EmptyObject) {
48
+ this._fileLocation = "";
49
+ this._parent = e, this.sharedShared = o, this.currentPath = s, this.elemRoot = r, this.jsonRoot = i, e ? (this._fileLocation = e._fileLocation, this._getRef = e._getRef, this._getRefs = e._getRefs, this._serializeElement = e._serializeElement, this._readEmbeddedPart = e._readEmbeddedPart) : (n && (this._fileLocation = n), l?.getRef && (this._getRef = (t, e, o) => l?.getRef?.(t, e, o, l?.parsedRefs)), l?.getRefs && (this._getRefs = (t) => l?.getRefs?.(t, l?.parsedRefs)), this._onWarning = l?.onWarning, this._addPerson = l?.addPerson, this._serializeElement = l?.serializeElement, this._readEmbeddedPart = l?.readEmbeddedPart);
50
+ }
51
+ getRef(t, e = !1) {
52
+ return this._getRef?.(t, this._fileLocation, e) ?? null;
53
+ }
54
+ readEmbeddedPart(t) {
55
+ return this._readEmbeddedPart?.(t, this._fileLocation) ?? null;
56
+ }
57
+ getRelationships() {
58
+ return this._getRefs?.(this._fileLocation) ?? ut;
59
+ }
60
+ getPath() {
61
+ return this.currentPath;
62
+ }
63
+ getFileLocation() {
64
+ return this._fileLocation;
65
+ }
66
+ getElemRoot() {
67
+ return this.elemRoot;
68
+ }
69
+ getJsonRoot() {
70
+ return this.jsonRoot;
71
+ }
72
+ warn(t, e) {
73
+ this._raiseWarning(t, this.getFileLocation(), e?.onceKey);
74
+ }
75
+ _raiseWarning(t, e, o) {
76
+ this._onWarning ? this._onWarning(t, e, o) : this._parent ? this._parent._raiseWarning(t, e, o) : console.warn(t);
77
+ }
78
+ serializeElement(t) {
79
+ return this._serializeElement?.(t) ?? null;
80
+ }
81
+ addPerson(t) {
82
+ return "string" == typeof t && (t = { displayName: t }), this._addPerson ? this._addPerson(t) : this._parent ? this._parent?._addPerson?.(t) ?? null : null;
83
+ }
84
+ getVisitorParamsState() {
85
+ return this.sharedShared.getVisitorParamsState();
86
+ }
87
+ evaluate(t, e) {
88
+ if (!t) return e;
89
+ let o = [e];
90
+ const s = t.split("/"), r = s.length;
91
+ for (let t = 0; t < r; t++) {
92
+ const e = s[t];
93
+ if ("" === e || "." === e) continue;
94
+ const i = [], n = !("*" !== e && "**" !== e || t === r - 1);
95
+ for (const r of o) if (r) if (n) {
96
+ const e = s[t + 1];
97
+ e && "" !== e && "." !== e && (this._findDescendants(r, e, i), t++);
98
+ } else if ("*" === e || "**" === e) {
99
+ if (!r.childNodes) continue;
100
+ const t = r.childNodes, e = t.length;
101
+ for (let o = 0; o < e; o++) {
102
+ const e = t[o];
103
+ 1 === e.nodeType && i.push(e);
104
+ }
105
+ } else {
106
+ if (!r.childNodes) continue;
107
+ const t = r.childNodes, o = t.length;
108
+ for (let s = 0; s < o; s++) {
109
+ const o = t[s];
110
+ if (1 !== o.nodeType) continue;
111
+ const r = o;
112
+ this._matchesElementName(r, e) && i.push(r);
113
+ }
114
+ }
115
+ if (o = i, 0 === o.length) return null;
116
+ }
117
+ return 1 === o.length ? o[0] : 0 === o.length ? null : new nt(o);
118
+ }
119
+ _matchesElementName(t, e) {
120
+ return e.includes(":") ? (t.tagName || t.nodeName) === e : t.localName === e;
121
+ }
122
+ _findDescendants(t, e, o) {
123
+ if (!t || !t.childNodes) return;
124
+ const s = t.childNodes, r = s.length;
125
+ for (let t = 0; t < r; t++) {
126
+ const r = s[t];
127
+ if (1 !== r.nodeType) continue;
128
+ const i = r;
129
+ this._matchesElementName(i, e) && o.push(i), this._findDescendants(i, e, o);
130
+ }
131
+ }
132
+ getFromPath(e, o) {
133
+ return t.getFromPath(e, o);
134
+ }
135
+ setToPath(e, o, s) {
136
+ return t.setToPath(e, o, s);
137
+ }
138
+ getValAttrAsString(t, e) {
139
+ let o = this.evaluate(t, e);
140
+ return o && o.hasAttribute("val") ? o.getAttribute("val") ?? null : null;
141
+ }
142
+ getValAttrAsBoolean(t, e, o = !1) {
143
+ let s = this.evaluate(t, e);
144
+ if (!s) return null;
145
+ const r = s.hasAttribute("val") ? s.getAttribute("val") : void 0;
146
+ return null == r ? o : "1" === r || "on" === r || "true" === r || "0" !== r && "off" !== r && "false" !== r && o;
147
+ }
148
+ getValAttrAsInteger(t, e) {
149
+ let o = this.evaluate(t, e);
150
+ return o && o.hasAttribute("val") ? parseInt(o.getAttribute("val")) ?? null : null;
151
+ }
152
+ getValAttrAsFloat(t, e) {
153
+ let o = this.evaluate(t, e);
154
+ return o && o.hasAttribute("val") ? parseFloat(o.getAttribute("val")) ?? null : null;
155
+ }
156
+ get BOOLEAN_COPY() {
157
+ return lt;
158
+ }
159
+ get INT_COPY() {
160
+ return at;
161
+ }
162
+ get FLOAT_COPY() {
163
+ return ct;
164
+ }
165
+ copyFromAttribute(t, e, o, s = e, r = null) {
166
+ if (!t || !o || !t.hasAttribute(e)) return;
167
+ let i = t.getAttribute(e);
168
+ if (r) if (Array.isArray(r)) {
169
+ const t = r.length;
170
+ for (let e = 0; e < t; e++) {
171
+ if (null == i) return;
172
+ if (i = r[e](i), null == i) return;
173
+ }
174
+ } else {
175
+ if (null == i) return;
176
+ if (i = r(i), null == i) return;
177
+ }
178
+ this.setToPath(o, s, i);
179
+ }
180
+ }, ht = (t, e) => {
181
+ const o = [], s = t.childNodes, r = s.length;
182
+ for (let t = 0; t < r; t++) {
183
+ const r = s.item(t);
184
+ 1 === r.nodeType && r.localName === e && o.push(r);
185
+ }
186
+ return o;
187
+ }, pt = [
188
+ ["fillRef", "fill"],
189
+ ["lnRef", "stroke"],
190
+ ["effectRef", "effect"]
191
+ ], mt = (t, e) => {
192
+ const o = new E(), s = {};
193
+ for (const [r, i] of pt) {
194
+ const n = t.evaluate(r, e);
195
+ if (!n) continue;
196
+ const l = { index: parseInt(n.getAttribute("idx") ?? "0", 10) || 0 }, a = o.processAdjColor(t, n);
197
+ a && (l.color = a), s[i] = l;
198
+ }
199
+ const r = t.evaluate("fontRef", e);
200
+ if (r) {
201
+ const e = { index: r.getAttribute("idx") ?? "none" }, i = o.processAdjColor(t, r);
202
+ i && (e.color = i), s.font = e;
203
+ }
204
+ return s;
205
+ }, ft = class {
206
+ visit(t, e, o) {
207
+ if (!e) return;
208
+ let s = t.evaluate("*/cNvPr", e);
209
+ return s.item && (s = s.item(0)), s && (t.copyFromAttribute(s, "name", o), t.copyFromAttribute(s, "descr", o, "description"), t.copyFromAttribute(s, "hidden", o, "hidden", t.BOOLEAN_COPY), this.readNonVisualDetails(t, s, o), t.copyFromAttribute(s, "id", o)), o;
210
+ }
211
+ readNonVisualDetails(t, e, o) {
212
+ e.hasAttribute("title") && (o.title = e.getAttribute("title"));
213
+ const s = t.evaluate("hlinkClick", e);
214
+ s && (o.hyperlink = N(t, s));
215
+ const r = t.evaluate("hlinkHover", e);
216
+ r && (o.hoverHyperlink = N(t, r));
217
+ const i = t.evaluate("extLst", e), n = i ? t.serializeElement(i) : null;
218
+ n && (o.extLst = {
219
+ ...o.extLst,
220
+ nonVisual: n
221
+ });
222
+ }
223
+ setContent(t, e) {
224
+ const o = t;
225
+ void 0 !== o.name && (e.name = o.name, delete o.name), void 0 !== o.description && (e.description = o.description, delete o.description);
226
+ for (const t of [
227
+ "title",
228
+ "hyperlink",
229
+ "hoverHyperlink",
230
+ "extLst"
231
+ ]) void 0 !== o[t] && (e.json && (e.json[t] = o[t]), delete o[t]);
232
+ t.content = e;
233
+ }
234
+ isGroupContent(t) {
235
+ return Array.isArray(t?.members);
236
+ }
237
+ readMemberHeader(t, e, o) {
238
+ const s = {}, r = {
239
+ anchor: void 0,
240
+ content: {
241
+ type: o,
242
+ json: s
243
+ }
244
+ };
245
+ let i = t.evaluate("*/cNvPr", e);
246
+ if (i?.item && (i = i.item(0)), i) {
247
+ const o = i.getAttribute("name");
248
+ null !== o && (r.content.name = o);
249
+ const n = i.getAttribute("descr");
250
+ n && (r.content.description = n), t.copyFromAttribute(i, "hidden", r, "hidden", t.BOOLEAN_COPY), this.readNonVisualDetails(t, i, s);
251
+ const l = this.readSourceId(t, e);
252
+ void 0 !== l && (s.sourceId = l);
253
+ }
254
+ return {
255
+ movable: r,
256
+ content: s
257
+ };
258
+ }
259
+ readStyleRefs(t, e, o) {
260
+ const s = t.evaluate("style", e);
261
+ if (!s) return void (o.style = null);
262
+ const r = mt(t, s), n = i.withoutDefaultStyleRefs({
263
+ ...o,
264
+ style: r
265
+ });
266
+ n && (o.style = n);
267
+ }
268
+ readLocks(t) {
269
+ const e = t?.attributes;
270
+ if (!e || 0 === e.length) return;
271
+ const o = {};
272
+ for (let t = 0; t < e.length; t++) {
273
+ const s = e.item(t);
274
+ s.name.startsWith("xmlns") || (o[s.localName ?? s.name] = Q(s.value));
275
+ }
276
+ return Object.keys(o).length > 0 ? o : void 0;
277
+ }
278
+ readSourceId(t, e) {
279
+ let o = t.evaluate("*/cNvPr", e);
280
+ o?.item && (o = o.item(0));
281
+ const s = o?.getAttribute?.("id"), r = s ? parseInt(s, 10) : void 0;
282
+ return void 0 === r || isNaN(r) ? void 0 : r;
283
+ }
284
+ }, gt = [
285
+ ["spDef", "shape"],
286
+ ["lnDef", "line"],
287
+ ["txDef", "text"]
288
+ ], bt = (t, e) => {
289
+ const o = e.getAttribute("dxfId");
290
+ if (null === o) return;
291
+ const s = parseInt(o);
292
+ return t.getVisitorParamsState().get("dxfs")?.get(s) || (t.warn(`A color filter or sort names a format that does not exist (dxfId '${o}').`), {});
293
+ }, yt = (t) => "1" === t || "true" === t, At = class {
294
+ visit(t, e, o) {}
295
+ processDataBarColor(t, e, o, s, r = "auto") {
296
+ if (!e) return;
297
+ const i = G((t) => e.getAttribute(t), r);
298
+ return i && (o[s] = i), o;
299
+ }
300
+ processFonts(t, e, o) {
301
+ if (!e) return;
302
+ const s = e.childNodes;
303
+ let r = 0;
304
+ const i = s.length;
305
+ for (let e = 0; e < i; e++) {
306
+ const i = s.item(e);
307
+ if (1 === i.nodeType && "font" === i.localName) {
308
+ const e = {};
309
+ this.processFont(t, i, e), o[r++] = e;
310
+ }
311
+ }
312
+ return o;
313
+ }
314
+ processFont(t, e, o) {
315
+ t.getValAttrAsBoolean("b", e, !0) && (o.weight = 700), t.getValAttrAsBoolean("i", e, !0) && (o.style = s.Style.Italic), t.getValAttrAsBoolean("strike", e, !0) && (o.strike = P(!0));
316
+ const r = t.evaluate("u", e);
317
+ if (r) {
318
+ const t = r.getAttribute("val");
319
+ o.underline = j(t);
320
+ }
321
+ const i = Y(t.evaluate("vertAlign", e)?.getAttribute("val"));
322
+ void 0 !== i && (o.baseline = i), M(t, e, o, "sz", "size");
323
+ const n = t.evaluate("color", e);
324
+ this.processDataBarColor(t, n, o, "color"), o.color || (o.color = "auto"), A(t, e, o, "name", "family"), A(t, e, o, "rFont", "family");
325
+ const l = t.evaluate("family", e);
326
+ if (l) {
327
+ const t = l.getAttribute("val");
328
+ if (t) switch (t) {
329
+ case "1":
330
+ o.fallbacks = ["serif"];
331
+ break;
332
+ case "2":
333
+ o.fallbacks = ["sans-serif"];
334
+ break;
335
+ case "3":
336
+ o.fallbacks = ["monospace"];
337
+ break;
338
+ case "4":
339
+ o.fallbacks = ["cursive"];
340
+ break;
341
+ case "5": o.fallbacks = ["fantasy"];
342
+ }
343
+ }
344
+ k(o, t.evaluate("scheme", e)?.getAttribute("val")), $(t, e, o, "shadow", "shadow", !0), $(t, e, o, "outline", "outline", !0);
345
+ for (const s of ["condense", "extend"]) {
346
+ const r = v(s, !!t.getValAttrAsBoolean(s, e, !0));
347
+ void 0 !== r && (o.letterSpacing = r);
348
+ }
349
+ return B(t, e, o, "charset", "charset"), o;
350
+ }
351
+ processFills(t, e, o) {
352
+ if (!e) return;
353
+ const s = e.childNodes;
354
+ let r = 0;
355
+ const i = s.length;
356
+ for (let e = 0; e < i; e++) {
357
+ const i = s.item(e);
358
+ 1 === i.nodeType && "fill" === i.localName && this.processFill(t, i, o, r++);
359
+ }
360
+ return o;
361
+ }
362
+ processFill(t, o, s, r) {
363
+ const i = { type: e.Type.None }, n = o.childNodes;
364
+ let l = !1;
365
+ const a = n.length;
366
+ for (let e = 0; !l && e < a; e++) {
367
+ const o = n.item(e);
368
+ 1 === o.nodeType && ("gradientFill" === o.localName ? (this.processGradientFill(t, o, i), l = !0) : "patternFill" === o.localName && (this.processPatternFill(t, o, i), l = !0));
369
+ }
370
+ return s[r] = i, s;
371
+ }
372
+ processGradientFill(t, o, s) {
373
+ if (!o) return;
374
+ s.type = e.Type.Gradient;
375
+ const r = [];
376
+ s.stops = r;
377
+ const i = o.getAttribute("type");
378
+ i && (s.gradientType = i);
379
+ const n = o.hasAttribute("degree") ? parseFloat(o.getAttribute("degree")) : 0;
380
+ (n + 90) % 360 != 0 && (s.angle = (n + 90) % 360), (o.hasAttribute("left") || o.hasAttribute("top") || o.hasAttribute("right") || o.hasAttribute("bottom")) && (s.focus = {
381
+ left: vt(o.getAttribute("left")),
382
+ top: vt(o.getAttribute("top")),
383
+ right: vt(o.getAttribute("right")),
384
+ bottom: vt(o.getAttribute("bottom"))
385
+ });
386
+ const l = o.childNodes, a = l.length;
387
+ for (let e = 0; e < a; e++) {
388
+ const o = l.item(e);
389
+ if (1 === o.nodeType && "stop" === o.localName) {
390
+ const e = {};
391
+ r.push(e), e.offset = parseFloat(o.getAttribute("position") ?? "");
392
+ const s = t.evaluate("color", o);
393
+ this.processDataBarColor(t, s, e, "color");
394
+ }
395
+ }
396
+ return s;
397
+ }
398
+ processPatternFill(t, o, s) {
399
+ if (!o) return;
400
+ const r = t.getVisitorParamsState().get("processingDXFs"), i = o.getAttribute("patternType") || (r ? e.BuiltInSheetPattern.Solid : e.BuiltInSheetPattern.None);
401
+ if (i === e.BuiltInSheetPattern.None) return { none: !0 };
402
+ s.type = e.Type.Pattern, i && (s.patternType = i);
403
+ let n = "foreground", l = "background";
404
+ const a = s.patternType === e.BuiltInSheetPattern.Solid && r;
405
+ let c = a ? "dk1" : "lt1", u = a ? "lt1" : "dk1";
406
+ if (a) {
407
+ const t = n;
408
+ n = l, l = t;
409
+ }
410
+ const d = t.evaluate("fgColor", o);
411
+ this.processDataBarColor(t, d, s, n, c);
412
+ const h = t.evaluate("bgColor", o);
413
+ return this.processDataBarColor(t, h, s, l, u), a && (s.foreground || (s.foreground = "lt1"), s.background || (s.background = "dk1")), s;
414
+ }
415
+ processBorders(t, e, o, s) {
416
+ if (!e) return;
417
+ const r = e.childNodes;
418
+ let i = 0;
419
+ const n = r.length;
420
+ for (let e = 0; e < n; e++) {
421
+ const n = r.item(e);
422
+ 1 === n.nodeType && "border" === n.localName && this.processBorder(t, n, o, i++, s);
423
+ }
424
+ return o;
425
+ }
426
+ processBorder(t, e, o, s, i) {
427
+ if (!e) return;
428
+ const n = {};
429
+ this.processBorderStroke(t, e, n, r.Edge.Left), this.processBorderStroke(t, e, n, r.Edge.Right), i ? (n.right || n.left) && (n.right ? n.vertical = { ...n.right } : n.vertical = { ...n.left }) : this.processBorderStroke(t, e, n, r.Edge.Vertical), this.processBorderStroke(t, e, n, r.Edge.Top), this.processBorderStroke(t, e, n, r.Edge.Bottom), i ? (n.bottom || n.top) && (n.bottom ? n.horizontal = { ...n.bottom } : n.horizontal = { ...n.top }) : this.processBorderStroke(t, e, n, r.Edge.Horizontal);
430
+ const l = this.processBorderStroke(t, e, {}, "diagonal");
431
+ return l && (yt(e.getAttribute("diagonalUp")) && (n.diagonalUp = { ...l }), yt(e.getAttribute("diagonalDown")) && (n.diagonalDown = { ...l })), o[s] = n, o;
432
+ }
433
+ processBorderStroke(t, e, o, s) {
434
+ if (!e) return;
435
+ const i = t.evaluate(s, e);
436
+ if (!i) return;
437
+ const n = {};
438
+ i.hasAttribute("style") ? n.style = i.getAttribute("style") : t.getVisitorParamsState().get("processingDXFs") && (n.style = r.StrokeStyle.None);
439
+ const l = t.evaluate("color", i);
440
+ return l && this.processDataBarColor(t, l, n, "color"), Object.keys(n).length > 0 ? o[s] = n : null;
441
+ }
442
+ }, vt = (t) => {
443
+ if (!t) return 0;
444
+ const e = parseFloat(t);
445
+ return isNaN(e) ? 0 : e;
446
+ }, Nt = (t, e) => {
447
+ if (!t || 1 !== t.nodeType) return null;
448
+ const o = t.childNodes;
449
+ for (let t = 0; t < o.length; t++) {
450
+ const s = o.item(t);
451
+ if (1 === s.nodeType && s.localName === e) return s;
452
+ }
453
+ return null;
454
+ }, Ft = new Set(Object.values(d.ElementType).filter((t) => t !== d.ElementType.WholeTable && t !== d.ElementType.HeaderRow)), Ct = {
455
+ auto: "auto",
456
+ autoNoTable: "automaticExceptTables",
457
+ manual: "manual"
458
+ }, St = [
459
+ "tableId",
460
+ "columnId",
461
+ "cacheName",
462
+ "cachePath",
463
+ "sourceName",
464
+ "sortOrder",
465
+ "customListSort",
466
+ "crossFilter"
467
+ ], xt = (t, e) => {
468
+ const o = t.content, s = o?.json;
469
+ if (s) {
470
+ if ("shape" === o.type || "picture" === o.type) {
471
+ const { rotation: o, flipH: r, flipV: i, bounds: n } = s;
472
+ delete s.rotation, delete s.flipH, delete s.flipV, delete s.bounds, void 0 !== o && 0 !== o && (t.rotation = o), r && (t.flipH = !0), i && (t.flipV = !0), e && n && (t.anchor = {
473
+ tl: {
474
+ x: n.x,
475
+ y: n.y
476
+ },
477
+ br: {
478
+ x: n.width,
479
+ y: n.height
480
+ }
481
+ });
482
+ }
483
+ if ("group" === o.type) for (const t of s.members ?? []) xt(t, !0);
484
+ }
485
+ }, wt = class extends ft {
486
+ visit(t, e, o) {
487
+ if (e) return this.visitShape(t, e, o, "sp", "nvSpPr/cNvSpPr/spLocks");
488
+ }
489
+ visitShape(t, e, s, r, i) {
490
+ const n = Z[r];
491
+ if (this.isGroupContent(s)) {
492
+ if (t.getPath().includes("Fallback")) return {};
493
+ const { movable: l, content: a } = this.readMemberHeader(t, e, "shape");
494
+ n !== o.Type.Shape && (a.type = n), this.readShapeDetails(t, e, r, i, a), this.readStyleRefs(t, e, a);
495
+ const c = t.evaluate(i, e);
496
+ c?.hasAttribute?.("noChangeAspect") && (l.lockAspect = "1" === c.getAttribute("noChangeAspect"));
497
+ const u = this.readTwinOf(t, e);
498
+ return void 0 !== u && Object.assign(a, { twinOf: u }), s.members.push(l), a;
499
+ }
500
+ if (t.getPath().includes("Fallback") && s.content) {
501
+ const r = s.content.json;
502
+ if ("shape" === s.content.type && r && (r.type ?? o.Type.Shape) === n) {
503
+ const o = t.evaluate("txBody", e), s = o ? new J().readTextBody(t, o) : null;
504
+ s && "" !== q(s) && (r.text = s);
505
+ }
506
+ return {};
507
+ }
508
+ s = super.visit(t, e, s);
509
+ const l = t.evaluate(i, e);
510
+ l?.hasAttribute?.("noChangeAspect") && (s.lockAspect = "1" === l.getAttribute("noChangeAspect"));
511
+ const a = n === o.Type.Shape ? {} : { type: n }, c = this.readSourceId(t, e);
512
+ void 0 !== c && (a.sourceId = c), this.readShapeDetails(t, e, r, i, a), this.readStyleRefs(t, e, a);
513
+ const u = this.readTwinOf(t, e);
514
+ return void 0 !== u && Object.assign(a, { twinOf: u }), this.setContent(s, {
515
+ type: "shape",
516
+ json: a
517
+ }), a;
518
+ }
519
+ readTwinOf(t, e) {
520
+ let o = t.evaluate("*/cNvPr/extLst/ext/compatExt", e);
521
+ o?.item && (o = o.item(0));
522
+ const s = /^_x0000_s(\d+)$/.exec(o?.getAttribute?.("spid") ?? "");
523
+ return s ? parseInt(s[1], 10) : void 0;
524
+ }
525
+ readShapeDetails(t, e, o, s, r) {
526
+ const i = e.getAttribute("macro");
527
+ i && (r.macro = i);
528
+ const n = e.getAttribute("textlink");
529
+ n && (r.textLink = n), e.hasAttribute("fLocksText") && (r.locksText = Q(e.getAttribute("fLocksText"))), e.hasAttribute("fPublished") && (r.published = Q(e.getAttribute("fPublished")));
530
+ const l = s.slice(0, s.lastIndexOf("/")), a = t.evaluate(l, e);
531
+ "1" === a?.getAttribute?.("txBox") && (r.textBox = !0);
532
+ const c = this.readLocks(t.evaluate(s, e));
533
+ if (c && (r.locks = c), "cxnSp" === o && a) {
534
+ const e = (e) => {
535
+ const o = t.evaluate(e, a);
536
+ if (o?.getAttribute) return {
537
+ id: parseInt(o.getAttribute("id") ?? "0", 10) || 0,
538
+ index: parseInt(o.getAttribute("idx") ?? "0", 10) || 0
539
+ };
540
+ }, o = e("stCxn"), s = e("endCxn");
541
+ (o || s) && (r.connectorEnds = {}, o && (r.connectorEnds.start = o), s && (r.connectorEnds.end = s));
542
+ }
543
+ }
544
+ }, Tt = /^<a:extLst(?:\s+xmlns:a="[^"]*")?><a:ext uri="\{28A0092B-C50C-407E-A947-70E740481C1C\}"><a14:useLocalDpi(?:\s+xmlns:a14="[^"]*")?\s+val="0"\s*\/><\/a:ext><\/a:extLst>$/, Pt = (t, e, o, s) => {
545
+ const r = t.evaluate(o, e), i = t.evaluate(s, e);
546
+ return r || i ? {
547
+ x: H(r?.getAttribute("x") ?? null) ?? 0,
548
+ y: H(r?.getAttribute("y") ?? null) ?? 0,
549
+ width: H(i?.getAttribute("cx") ?? null) ?? 0,
550
+ height: H(i?.getAttribute("cy") ?? null) ?? 0
551
+ } : null;
552
+ }, It = { Checkbox: "checkbox" }, kt = (t) => {
553
+ const e = t.getAttribute("val");
554
+ return "0" !== e && "false" !== e;
555
+ }, Ot = {
556
+ 1: "serif",
557
+ 2: "sans-serif",
558
+ 3: "monospace",
559
+ 4: "cursive",
560
+ 5: "fantasy"
561
+ };
562
+ function Vt(t) {
563
+ const e = {}, o = t.childNodes;
564
+ for (let t = 0; t < o.length; t++) {
565
+ const r = o.item(t);
566
+ if (1 === r.nodeType) switch (r.localName) {
567
+ case "b":
568
+ e.weight = kt(r) ? 700 : 400;
569
+ break;
570
+ case "i":
571
+ e.style = kt(r) ? s.Style.Italic : s.Style.Normal;
572
+ break;
573
+ case "strike":
574
+ e.strike = P(kt(r));
575
+ break;
576
+ case "outline":
577
+ e.outline = kt(r);
578
+ break;
579
+ case "shadow":
580
+ e.shadow = kt(r);
581
+ break;
582
+ case "condense":
583
+ case "extend": {
584
+ const t = v(r.localName, kt(r));
585
+ void 0 !== t && (e.letterSpacing = t);
586
+ break;
587
+ }
588
+ case "u":
589
+ e.underline = j(r.getAttribute("val"));
590
+ break;
591
+ case "vertAlign": {
592
+ const t = Y(r.getAttribute("val"));
593
+ void 0 !== t && (e.baseline = t);
594
+ break;
595
+ }
596
+ case "sz": {
597
+ const t = parseFloat(r.getAttribute("val") ?? "");
598
+ isNaN(t) || (e.size = t);
599
+ break;
600
+ }
601
+ case "rFont": {
602
+ const t = r.getAttribute("val");
603
+ t && (e.family = t);
604
+ break;
605
+ }
606
+ case "family": {
607
+ const t = Ot[r.getAttribute("val") ?? ""];
608
+ t && (e.fallbacks = [t]);
609
+ break;
610
+ }
611
+ case "charset": {
612
+ const t = parseInt(r.getAttribute("val") ?? "", 10);
613
+ isNaN(t) || (e.charset = t);
614
+ break;
615
+ }
616
+ case "scheme":
617
+ k(e, r.getAttribute("val"));
618
+ break;
619
+ case "color": {
620
+ const t = r.getAttribute("rgb");
621
+ if (t && !r.hasAttribute("theme")) {
622
+ e.color = "#" + (8 === t.length ? t.substring(2) : t).toUpperCase();
623
+ break;
624
+ }
625
+ const o = G((t) => r.getAttribute(t));
626
+ o && (e.color = o);
627
+ break;
628
+ }
629
+ }
630
+ }
631
+ return Object.keys(e).length > 0 ? e : null;
632
+ }
633
+ var _t = {
634
+ RelsVisitor: class {
635
+ visit(t, e, o) {
636
+ if (!e) return;
637
+ const s = e.childNodes, r = s.length;
638
+ for (let e = 0; e < r; e++) {
639
+ const r = s.item(e);
640
+ 1 === r.nodeType && "Relationship" === r.localName && this.processRelationship(t, r, o);
641
+ }
642
+ return o;
643
+ }
644
+ processRelationship(t, e, o) {
645
+ const s = {};
646
+ t.copyFromAttribute(e, "Target", s, "target"), t.copyFromAttribute(e, "Type", s, "type"), t.copyFromAttribute(e, "TargetMode", s, "targetMode"), o[e.getAttribute("Id")] = s;
647
+ }
648
+ },
649
+ CorePropertiesVisitor: class {
650
+ visit(t, e, o) {
651
+ const s = [], r = e.childNodes, i = r.length;
652
+ for (let e = 0; e < i; e++) {
653
+ const o = r.item(e);
654
+ if (1 !== o.nodeType) continue;
655
+ const i = this.processProperty(t, o);
656
+ i && s.push(i);
657
+ }
658
+ return s.length > 0 && (o.properties = s), s;
659
+ }
660
+ processProperty(t, e) {
661
+ if (e) return e.getAttribute("xsi:type"), {
662
+ key: e.localName,
663
+ value: e.textContent || ""
664
+ };
665
+ }
666
+ },
667
+ AppPropertiesVisitor: class {
668
+ visit(t, e, o) {
669
+ const s = e.childNodes, r = s.length;
670
+ for (let t = 0; t < r; t++) if ("property" === s.item(t).localName) return this.visitCustom(e, o);
671
+ const i = [];
672
+ for (let e = 0; e < r; e++) {
673
+ const o = s.item(e);
674
+ if (1 !== o.nodeType) continue;
675
+ const r = this.processProperty(t, o);
676
+ r && i.push(r);
677
+ }
678
+ return i.length > 0 && (o.properties = i), i;
679
+ }
680
+ visitCustom(t, e) {
681
+ const o = [], s = t.childNodes, r = s.length;
682
+ for (let t = 0; t < r; t++) {
683
+ const e = s.item(t);
684
+ if (1 !== e.nodeType || "property" !== e.localName) continue;
685
+ const r = e.getAttribute("name");
686
+ if (!r) continue;
687
+ let i = null;
688
+ for (let t = 0; t < e.childNodes.length && !i; t++) {
689
+ const o = e.childNodes.item(t);
690
+ 1 === o.nodeType && (i = o);
691
+ }
692
+ const n = {
693
+ key: r,
694
+ kind: i?.localName ?? null,
695
+ value: i?.textContent ?? ""
696
+ }, l = e.getAttribute("linkTarget");
697
+ l && (n.linkTarget = l), o.push(n);
698
+ }
699
+ return o.length > 0 && (e.custom = o), o;
700
+ }
701
+ processProperty(t, e) {
702
+ if (e) return {
703
+ key: e.localName,
704
+ value: e.textContent || ""
705
+ };
706
+ }
707
+ },
708
+ ShapePropertiesVisitor: b,
709
+ TextPropertiesVisitor: X,
710
+ ShapeTextVisitor: J,
711
+ ThemeVisitor: class {
712
+ visit(t, e, o) {
713
+ o.name = e.getAttribute("name"), o.objectDefaults = {};
714
+ const s = ht(e, "custClrLst")[0];
715
+ if (s) {
716
+ const e = new E(), r = [];
717
+ for (const o of ht(s, "custClr")) {
718
+ const s = e.processAdjColor(t, o);
719
+ if (!s) continue;
720
+ const i = { color: s }, n = o.getAttribute("name");
721
+ n && (i.name = n), r.push(i);
722
+ }
723
+ r.length && (o.customColors = r);
724
+ }
725
+ for (const t of ht(e, "extLst")) for (const e of ht(t, "ext")) {
726
+ if ("{05A4C25C-085E-4340-85A3-A5531E510DB2}" !== e.getAttribute("uri")) continue;
727
+ const t = ht(e, "themeFamily")[0], s = t?.getAttribute("id");
728
+ if (!s) continue;
729
+ const r = {
730
+ name: t.getAttribute("name") ?? "",
731
+ id: s
732
+ }, i = t.getAttribute("vid");
733
+ i && (r.vid = i), o.family = r;
734
+ }
735
+ return o;
736
+ }
737
+ },
738
+ ClrSchemeVisitor: class extends E {
739
+ visit(t, e, o) {
740
+ const s = {};
741
+ s.name = e.getAttribute("name");
742
+ const r = e.childNodes, i = r.length;
743
+ for (let o = 0; o < i; o++) {
744
+ const i = r.item(o);
745
+ if (1 === i.nodeType) {
746
+ let o = i.localName;
747
+ const r = t.evaluate(o, e);
748
+ s[o] = this.processAdjColor(t, r);
749
+ }
750
+ }
751
+ return Object.keys(s).length > 0 && (o.colors = s), s;
752
+ }
753
+ },
754
+ FontSchemeVisitor: class {
755
+ visit(t, e, o) {
756
+ const s = {};
757
+ s.name = e.getAttribute("name");
758
+ const r = this.processFontCollection(t, t.evaluate("majorFont", e));
759
+ r && (s.major = r);
760
+ const i = this.processFontCollection(t, t.evaluate("minorFont", e));
761
+ return i && (s.minor = i), o.fonts = s, s;
762
+ }
763
+ processFontCollection(t, e) {
764
+ if (!e) return;
765
+ const o = {}, s = t.evaluate("latin", e), r = s?.getAttribute("typeface");
766
+ r && (o.latin = r);
767
+ const i = s?.getAttribute("panose");
768
+ i && (o.panose = i);
769
+ const n = t.evaluate("ea", e)?.getAttribute("typeface");
770
+ n && (o.eastAsian = n);
771
+ const l = t.evaluate("cs", e)?.getAttribute("typeface");
772
+ let a;
773
+ l && (o.complexScript = l);
774
+ const c = e.childNodes, u = c.length;
775
+ for (let t = 0; t < u; t++) {
776
+ const e = c.item(t);
777
+ if (1 !== e.nodeType || "font" !== e.localName) continue;
778
+ const o = e.getAttribute("script");
779
+ o && ((a ??= {})[o] = e.getAttribute("typeface") ?? "");
780
+ }
781
+ return a && (o.scripts = a), o;
782
+ }
783
+ },
784
+ ObjectDefaultsVisitor: class {
785
+ visit(t, e, o) {
786
+ const s = {};
787
+ for (const [o, r] of gt) {
788
+ const i = t.evaluate(o, e);
789
+ i && (s[r] = this.processDefault(t, i));
790
+ }
791
+ return o.objectDefaults = s, {};
792
+ }
793
+ processDefault(t, e) {
794
+ const o = {}, s = t.evaluate("spPr", e);
795
+ s && new b().visit(t, s, o);
796
+ const r = new J().readTextBody(t, e);
797
+ (r.body || r.listStyle) && (o.text = r);
798
+ const i = t.evaluate("style", e);
799
+ return i && (o.style = mt(t, i)), o;
800
+ }
801
+ },
802
+ FmtSchemeVisitor: class extends E {
803
+ visit(t, e, o) {
804
+ const s = this.parseFillList(t, e, "fillStyleLst"), r = this.parseLnList(t, e, "lnStyleLst"), i = this.parseEffectStyleList(t, e, "effectStyleLst"), n = this.parseFillList(t, e, "bgFillStyleLst");
805
+ if (s && (o.fillStyleLst = s), r && (o.lnStyleLst = r), i && (o.effectStyleLst = i), n && (o.bgFillStyleLst = n), s && r && i && n) return;
806
+ const l = t.serializeElement(e);
807
+ l && (o.formatSchemeXml = l);
808
+ }
809
+ parseFillList(t, e, o) {
810
+ const s = t.evaluate(o, e);
811
+ if (!s) return;
812
+ const r = [], i = s.childNodes, n = i.length;
813
+ for (let e = 0; e < n; e++) {
814
+ const o = i.item(e);
815
+ if (1 !== o.nodeType) continue;
816
+ const s = this.parseFillListItem(t, o);
817
+ if (void 0 === s) return;
818
+ r.push(s);
819
+ }
820
+ return r;
821
+ }
822
+ parseFillListItem(t, o) {
823
+ switch (o.localName) {
824
+ case "noFill": return { type: e.Type.None };
825
+ case "solidFill": {
826
+ const s = this.processAdjColor(t, o);
827
+ return s ? {
828
+ type: e.Type.Solid,
829
+ color: s
830
+ } : void 0;
831
+ }
832
+ case "gradFill": return this.processGradFill(t, o);
833
+ case "pattFill": return this.processPatternFill(t, o);
834
+ default: return;
835
+ }
836
+ }
837
+ parseLnList(t, e, o) {
838
+ const s = t.evaluate(o, e);
839
+ if (!s) return;
840
+ const r = [], i = s.childNodes, n = i.length;
841
+ for (let e = 0; e < n; e++) {
842
+ const o = i.item(e);
843
+ 1 === o.nodeType && r.push(this.parseLn(t, o));
844
+ }
845
+ return r;
846
+ }
847
+ parseEffectStyleList(t, e, o) {
848
+ const s = t.evaluate(o, e);
849
+ if (!s) return;
850
+ const r = [], i = s.childNodes, n = i.length;
851
+ for (let e = 0; e < n; e++) {
852
+ const o = i.item(e);
853
+ if (1 !== o.nodeType) continue;
854
+ if (t.evaluate("scene3d", o) || t.evaluate("sp3d", o)) return;
855
+ const s = this.getEffects(t, o);
856
+ if (void 0 === s) return;
857
+ r.push(s ?? []);
858
+ }
859
+ return r;
860
+ }
861
+ },
862
+ AutoFilterVisitor: class {
863
+ visit(t, e, o) {
864
+ if (!e) return;
865
+ const s = {}, r = [];
866
+ return this.processFilterColumns(t, e, r, o), r.length > 0 && (s.conditions = r), Object.keys(s).length > 0 && (o.filter = s), o;
867
+ }
868
+ processColorFilter(t, e) {
869
+ const o = {}, s = {
870
+ operator: h.BuiltInOperatorNames.Color,
871
+ param: o
872
+ };
873
+ t.copyFromAttribute(e, "cellColor", o, "cellColor", t.BOOLEAN_COPY);
874
+ const r = bt(t, e);
875
+ return r && (o.style = r), s;
876
+ }
877
+ processCustomFilter(t, e) {
878
+ return K({
879
+ operator: e.getAttribute("operator"),
880
+ val: e.getAttribute("val")
881
+ }, (e) => t.warn(e));
882
+ }
883
+ processCustomFilters(t, e) {
884
+ const o = e.getAttribute("and"), s = "and" === o || "1" === o;
885
+ e.getAttribute("val");
886
+ const r = [], i = {
887
+ operator: s ? h.BuiltInOperatorNames.And : h.BuiltInOperatorNames.Or,
888
+ param: r
889
+ }, n = e.childNodes, l = n.length;
890
+ for (let e = 0; e < l; e++) {
891
+ const o = n.item(e);
892
+ if (1 !== o.nodeType) continue;
893
+ let s = null;
894
+ "customFilter" === o.localName && (s = this.processCustomFilter(t, o)), s && r.push(s);
895
+ }
896
+ return 1 === r.length ? r[0] : f(i);
897
+ }
898
+ processDynamicFilter(t, e) {
899
+ return y(e.getAttribute("type"));
900
+ }
901
+ processDateGroupItem(t, e) {
902
+ const o = {};
903
+ return t.copyFromAttribute(e, "dateTimeGrouping", o, "group"), t.copyFromAttribute(e, "day", o, "day", t.INT_COPY), t.copyFromAttribute(e, "hour", o, "hour", t.INT_COPY), t.copyFromAttribute(e, "minute", o, "minute", t.INT_COPY), t.copyFromAttribute(e, "month", o, "month", t.INT_COPY), t.copyFromAttribute(e, "second", o, "second", t.INT_COPY), t.copyFromAttribute(e, "year", o, "year", t.INT_COPY), o;
904
+ }
905
+ processFilterItem(t, e) {
906
+ if (e.hasAttribute("val")) return e.getAttribute("val");
907
+ }
908
+ processFilters(t, e) {
909
+ const o = {}, s = {
910
+ operator: h.BuiltInOperatorNames.InSet,
911
+ param: o
912
+ };
913
+ s.selector = h.BuiltInSelectorNames.Display, t.copyFromAttribute(e, "blank", o, "blank", t.BOOLEAN_COPY), t.copyFromAttribute(e, "calendarType", o, "calendarType");
914
+ let r = [], i = [];
915
+ const n = e.childNodes, l = n.length;
916
+ for (let e = 0; e < l; e++) {
917
+ const o = n.item(e);
918
+ if (1 === o.nodeType) {
919
+ if ("dateGroupItem" === o.localName) {
920
+ const e = this.processDateGroupItem(t, o);
921
+ e && r.push(e);
922
+ } else if ("filter" === o.localName) {
923
+ const e = this.processFilterItem(t, o);
924
+ void 0 !== e && i.push(e);
925
+ }
926
+ }
927
+ }
928
+ return r.length > 0 && (o.dateGroups = r), i.length > 0 && (o.items = i), s;
929
+ }
930
+ processIcon(t, e) {
931
+ const o = {}, s = {
932
+ operator: h.BuiltInOperatorNames.Icon,
933
+ param: o
934
+ };
935
+ return t.copyFromAttribute(e, "iconId", o, "iconId", t.INT_COPY), t.copyFromAttribute(e, "iconSet", o), s;
936
+ }
937
+ processTop10(t, e) {
938
+ const o = {}, s = {
939
+ operator: h.BuiltInOperatorNames.TopN,
940
+ param: o
941
+ };
942
+ return t.copyFromAttribute(e, "filterVal", o, "filterVal", t.FLOAT_COPY), t.copyFromAttribute(e, "percent", o, "percent", t.BOOLEAN_COPY), t.copyFromAttribute(e, "top", o, "top", t.BOOLEAN_COPY), t.copyFromAttribute(e, "val", o, "limit", t.FLOAT_COPY), s;
943
+ }
944
+ processFilterColumnExt(t, e) {
945
+ const o = e.childNodes;
946
+ for (let e = 0; e < o.length; e++) {
947
+ const s = o.item(e);
948
+ if (1 !== s.nodeType || "ext" !== s.localName) continue;
949
+ if (V(s.getAttribute("uri")) !== V("{1AD28BCE-077C-4C59-8B6E-1921CE8616D4}")) continue;
950
+ const r = s.childNodes;
951
+ for (let e = 0; e < r.length; e++) {
952
+ const o = r.item(e);
953
+ if (1 !== o.nodeType || "filterColumn" !== o.localName) continue;
954
+ const s = o.childNodes;
955
+ for (let e = 0; e < s.length; e++) {
956
+ const o = s.item(e);
957
+ if (1 === o.nodeType && "filters" === o.localName) return this.processFilters(t, o);
958
+ }
959
+ }
960
+ }
961
+ }
962
+ processFilterCriteria(t, e) {
963
+ if (!e) return;
964
+ const o = e.childNodes;
965
+ let s;
966
+ const r = o.length;
967
+ for (let e = 0; e < r; e++) {
968
+ const r = o.item(e);
969
+ 1 === r.nodeType && ("colorFilter" === r.localName ? s = this.processColorFilter(t, r) : "customFilters" === r.localName ? s = this.processCustomFilters(t, r) : "dynamicFilter" === r.localName ? s = this.processDynamicFilter(t, r) : "filters" === r.localName ? s = this.processFilters(t, r) : "iconFilter" === r.localName ? s = this.processIcon(t, r) : "top10" === r.localName ? s = this.processTop10(t, r) : "extLst" === r.localName && (s = this.processFilterColumnExt(t, r) ?? s));
970
+ }
971
+ return s;
972
+ }
973
+ processFilterColumn(t, e, o) {
974
+ if (!e) return null;
975
+ if (!e.hasAttribute("colId")) return;
976
+ const s = parseInt(e.getAttribute("colId"));
977
+ let r = !1;
978
+ if (e.hasAttribute("hiddenButton") && (r = Q(e.getAttribute("hiddenButton"))), r && o) {
979
+ let t = o.hiddenButtons;
980
+ t || (t = [], o.hiddenButtons = t), t.push(s);
981
+ }
982
+ let i = !1;
983
+ if (e.hasAttribute("showButton") && (i = Q(e.getAttribute("showButton"))), i && o) {
984
+ let t = o.showButtons;
985
+ !0 !== t && (t || (t = [], o.showButtons = t), t[s] = !0);
986
+ }
987
+ const n = this.processFilterCriteria(t, e);
988
+ return n ? (n.index = s, n) : null;
989
+ }
990
+ processFilterColumns(t, e, o, s) {
991
+ if (!e) return;
992
+ const r = e.childNodes, i = r.length;
993
+ for (let e = 0; e < i; e++) {
994
+ const i = r.item(e);
995
+ if (1 === i.nodeType && "filterColumn" === i.localName) {
996
+ const e = this.processFilterColumn(t, i, s);
997
+ e && o.push(e);
998
+ }
999
+ }
1000
+ return o;
1001
+ }
1002
+ },
1003
+ SortStateVisitor: class {
1004
+ visit(t, e, o) {
1005
+ if (!e) return;
1006
+ const s = e.getAttribute("ref"), r = {};
1007
+ e.hasAttribute("caseSensitive") && (r.collatorOptions = Q(e.getAttribute("caseSensitive")) ? p.CaseSensitiveOptions : p.CaseInsensitiveOptions);
1008
+ const i = e.getAttribute("sortMethod");
1009
+ null != i && "none" !== i && ("stroke" === i ? r.collatorOptions = {
1010
+ ...r.collatorOptions,
1011
+ collation: "stroke"
1012
+ } : "pinYin" === i && (r.collatorOptions = {
1013
+ ...r.collatorOptions,
1014
+ collation: "pinyin"
1015
+ }));
1016
+ const n = {};
1017
+ e.hasAttribute("columnSort") && Q(e.getAttribute("columnSort")) && (n.axis = c.Axis.Column);
1018
+ const l = u.fastStringToRange(s), a = [], d = [];
1019
+ this.processSortConditions(t, e, a, l, r, d), a.length > 0 && (n.sorts = a);
1020
+ const h = t.getVisitorParamsState().get("ref");
1021
+ if (h && s) {
1022
+ const t = u.fastStringToRange(h);
1023
+ n.extent = {
1024
+ range: D(t, l),
1025
+ sorts: d.map((e) => W(t, l, e))
1026
+ };
1027
+ }
1028
+ return Object.keys(a).length > 0 && (o.sort = n), n;
1029
+ }
1030
+ processSortCondition(t, e, o, s, r) {
1031
+ if (!e) return null;
1032
+ const i = {};
1033
+ if (!e.hasAttribute("ref")) return void t.warn("A sort condition has no ref; it was dropped.", { onceKey: "xlsx.sheet.sort.noRef" });
1034
+ if (e.hasAttribute("ref")) {
1035
+ const t = e.getAttribute("ref"), s = u.fastStringToRange(t);
1036
+ i.index = o ? s.colStart - o.colStart : s.colStart, r?.push(s);
1037
+ }
1038
+ const n = { ...s };
1039
+ i.criteria = n, n.reverse = !1, e.hasAttribute("descending") && (n.reverse = Q(e.getAttribute("descending")));
1040
+ const l = x(e.getAttribute("sortBy"));
1041
+ l && (n.sortOn = l);
1042
+ const a = bt(t, e);
1043
+ return a && (n.style = a), t.copyFromAttribute(e, "iconSet", n), t.copyFromAttribute(e, "customList", n), i;
1044
+ }
1045
+ processSortConditions(t, e, o, s, r, i) {
1046
+ if (!e) return;
1047
+ const n = e.childNodes, l = n.length;
1048
+ for (let e = 0; e < l; e++) {
1049
+ const l = n.item(e);
1050
+ if (1 === l.nodeType && "sortCondition" === l.localName) {
1051
+ const e = this.processSortCondition(t, l, s, r, i);
1052
+ e && o.push(e);
1053
+ }
1054
+ }
1055
+ }
1056
+ },
1057
+ SheetStyleVisitor: class extends At {
1058
+ visit(t, o, s) {
1059
+ this.processNumFmts(t, t.evaluate("numFmts", o), null), t.getVisitorParamsState().set("colorsToProcess", /* @__PURE__ */ new Set());
1060
+ const i = {
1061
+ fills: {},
1062
+ fonts: {},
1063
+ borders: {}
1064
+ }, n = t.evaluate("fonts", o);
1065
+ this.processFonts(t, n, i.fonts);
1066
+ const l = i.fonts[this.normalFontId(t, o)], a = {
1067
+ declared: ["1", "true"].includes(n?.getAttribute("x14ac:knownFonts") ?? ""),
1068
+ normalIsThemeFont: _(l?.family),
1069
+ faces: U(Object.values(i.fonts).map((t) => ({
1070
+ ...t,
1071
+ family: S(t?.family, t?.fallbacks, null, !1).name
1072
+ })))
1073
+ };
1074
+ t.getVisitorParamsState().set(g, a), l && t.getVisitorParamsState().set("defaultFont", l), this.processFills(t, t.evaluate("fills", o), i.fills), this.processBorders(t, t.evaluate("borders", o), i.borders, !0), i.fills[0] = { type: e.Type.None }, i.fills[1] = {
1075
+ type: e.Type.Pattern,
1076
+ patternType: e.BuiltInSheetPattern.Gray125
1077
+ }, i.borders[0] = {
1078
+ bottom: { style: r.StrokeStyle.None },
1079
+ left: { style: r.StrokeStyle.None },
1080
+ right: { style: r.StrokeStyle.None },
1081
+ top: { style: r.StrokeStyle.None }
1082
+ };
1083
+ const c = [];
1084
+ this.processXFs(t, t.evaluate("cellStyleXfs", o), c, i, null, !1);
1085
+ const u = /* @__PURE__ */ new Map();
1086
+ if (c.length > 0) {
1087
+ const e = [];
1088
+ this.processCellStyles(t, t.evaluate("cellStyles", o), e, c, u), s.named = e;
1089
+ }
1090
+ const d = [];
1091
+ this.processXFs(t, t.evaluate("cellXfs", o), d, i, u), Object.keys(d).length > 0 && (s.direct = d);
1092
+ const h = this.collectHiddenXfs(t.evaluate("cellXfs", o));
1093
+ h.size > 0 && t.getVisitorParamsState().set("hiddenXfs", h);
1094
+ const p = this.collectXfComplements(t.evaluate("cellXfs", o));
1095
+ p.size > 0 && t.getVisitorParamsState().set("xfComplements", p);
1096
+ const m = [];
1097
+ return this.processDXFs(t, t.evaluate("dxfs", o), m), this.processTableStyles(t, t.evaluate("tableStyles", o), s, m), this.processSlicerStyles(t, t.evaluate("extLst", o), s), this.processIndexColors(t, t.evaluate("colors/indexedColors", o), s), this.processMruColors(t, t.evaluate("colors/mruColors", o), s), s;
1098
+ }
1099
+ normalFontId(t, e) {
1100
+ const o = t.evaluate("cellStyles", e)?.childNodes;
1101
+ let s = 0;
1102
+ for (let t = 0; t < (o?.length ?? 0); t++) {
1103
+ const e = o.item(t);
1104
+ if (1 === e.nodeType && "0" === e.getAttribute("builtinId")) {
1105
+ s = parseInt(e.getAttribute("xfId") ?? "0", 10) || 0;
1106
+ break;
1107
+ }
1108
+ }
1109
+ const r = t.evaluate("cellStyleXfs", e)?.childNodes;
1110
+ let i = 0;
1111
+ for (let t = 0; t < (r?.length ?? 0); t++) {
1112
+ const e = r.item(t);
1113
+ if (1 === e.nodeType && i++ === s) return parseInt(e.getAttribute("fontId") ?? "0", 10) || 0;
1114
+ }
1115
+ return 0;
1116
+ }
1117
+ processIndexColors(t, e, o) {
1118
+ if (!e) return;
1119
+ const s = [], r = e.childNodes, i = r.length;
1120
+ for (let e = 0; e < i; e++) {
1121
+ const o = r.item(e);
1122
+ if (1 === o.nodeType && "rgbColor" === o.localName) {
1123
+ const e = { color: null };
1124
+ this.processDataBarColor(t, o, e, "color"), e.color && s.push(e.color);
1125
+ }
1126
+ }
1127
+ o.indexedColors = s;
1128
+ }
1129
+ processMruColors(t, e, o) {
1130
+ if (!e) return;
1131
+ const s = [], r = e.childNodes, i = r.length;
1132
+ for (let e = 0; e < i; e++) {
1133
+ const o = r.item(e);
1134
+ if (1 === o.nodeType && "color" === o.localName) {
1135
+ const e = { color: null };
1136
+ this.processDataBarColor(t, o, e, "color"), e.color && s.push(e.color);
1137
+ }
1138
+ }
1139
+ s.length > 0 && (o.mruColors = s);
1140
+ }
1141
+ processNumFmts(t, e, o) {
1142
+ if (!e) return;
1143
+ const s = /* @__PURE__ */ new Map();
1144
+ if (t.getVisitorParamsState().set("numFmts", s), !e) return;
1145
+ const r = e.childNodes, i = r.length;
1146
+ for (let t = 0; t < i; t++) {
1147
+ const e = r.item(t);
1148
+ if (1 === e.nodeType && "numFmt" === e.localName) {
1149
+ const t = e.getAttribute("numFmtId"), o = e.getAttribute("formatCode");
1150
+ if (t && o) {
1151
+ const e = o;
1152
+ s.set(parseInt(t), e);
1153
+ }
1154
+ }
1155
+ }
1156
+ }
1157
+ processXFs(t, e, o, s, r = null, i = !0) {
1158
+ if (!e) return;
1159
+ const n = e.childNodes, l = n.length;
1160
+ for (let e = 0; e < l; e++) {
1161
+ const l = n.item(e);
1162
+ if (1 === l.nodeType && "xf" === l.localName) {
1163
+ const e = {};
1164
+ this.processXF(t, l, e, s, r, i), o.push(e);
1165
+ }
1166
+ }
1167
+ }
1168
+ processXF(t, e, o, s, r, i) {
1169
+ if (!e) return;
1170
+ const n = e.getAttribute("xfId");
1171
+ if (n && r) {
1172
+ const t = r.get(parseInt(n));
1173
+ t && t !== l.BuiltInName.Normal && (o.named = t);
1174
+ }
1175
+ const a = (t) => !(!i && e.hasAttribute(t)) || Q(e.getAttribute(t)), c = (t) => !i || e.hasAttribute(t) && Q(e.getAttribute(t)), u = "0", d = i ? u : void 0;
1176
+ if (a("applyFont")) {
1177
+ const t = e.getAttribute("fontId") ?? d;
1178
+ if (void 0 !== t && (t !== u || c("applyFont"))) {
1179
+ const e = s.fonts[t];
1180
+ void 0 !== e && (o.font = e);
1181
+ }
1182
+ }
1183
+ if (a("applyFill")) {
1184
+ const t = e.getAttribute("fillId") ?? d;
1185
+ if (void 0 !== t && (t !== u || c("applyFill"))) {
1186
+ const e = s.fills[t];
1187
+ void 0 !== e && Object.keys(e).length > 0 && (o.fill = e);
1188
+ }
1189
+ }
1190
+ if (a("applyBorder")) {
1191
+ const t = e.getAttribute("borderId") ?? d;
1192
+ if (void 0 !== t && (t !== u || c("applyBorder"))) {
1193
+ const e = s.borders[t];
1194
+ void 0 !== e && (o.borders = e);
1195
+ }
1196
+ }
1197
+ if (a("applyNumberFormat")) {
1198
+ const s = e.getAttribute("numFmtId") ?? d;
1199
+ if (void 0 !== s && (s !== u || c("applyNumberFormat"))) {
1200
+ const e = parseInt(s);
1201
+ let r;
1202
+ const i = t.getVisitorParamsState();
1203
+ if (i) {
1204
+ const t = i.get("numFmts");
1205
+ t && (r = t.get(e)), o.numberFormat = r ?? e;
1206
+ } else t.warn("Number formats were unavailable; a cell format was not read.", { onceKey: "xlsx.style.numberFormat.state" });
1207
+ }
1208
+ }
1209
+ if (a("applyAlignment")) {
1210
+ const s = t.evaluate("alignment", e);
1211
+ (s || c("applyAlignment")) && this.processAlignment(t, s, o);
1212
+ }
1213
+ if (a("applyProtection")) {
1214
+ const s = t.evaluate("protection", e);
1215
+ (s || c("applyProtection")) && this.processProtection(t, s, o);
1216
+ }
1217
+ const h = Q(e.getAttribute("quotePrefix") ?? "");
1218
+ h && (o.quotePrefix = h);
1219
+ }
1220
+ processAlignment(t, e, o) {
1221
+ const s = {};
1222
+ if (e?.hasAttribute("horizontal") ? s.horizontal = e.getAttribute("horizontal") : s.horizontal = n.HorizontalAlignment.General, e?.hasAttribute("vertical") ? s.vertical = e.getAttribute("vertical") : s.vertical = n.VerticalAlignment.Bottom, e?.hasAttribute("indent") ? s.indent = parseInt(e.getAttribute("indent")) : s.indent = 0, e?.hasAttribute("relativeIndent") ? s.relativeIndent = parseInt(e.getAttribute("relativeIndent")) : s.relativeIndent = 0, Q(e?.getAttribute("wrapText") ?? "") ? s.overflow = n.Overflow.Wrap : s.overflow = n.Overflow.Visible, Q(e?.getAttribute("shrinkToFit") ?? "") && (s.overflow = n.Overflow.Shrink), e?.hasAttribute("textRotation")) {
1223
+ let t = parseFloat(e.getAttribute("textRotation"));
1224
+ t > 0 && t <= 90 ? t = 360 - t : t > 90 && t <= 180 ? t -= 90 : 255 === t && (t = 0, s.stacked = !0), s.rotation = t;
1225
+ } else s.rotation = 0;
1226
+ e?.hasAttribute("justifyLastLine") && (s.justifyLastLine = Q(e.getAttribute("justifyLastLine")));
1227
+ const r = e?.getAttribute("readingOrder");
1228
+ return r && ("0" === r ? s.readingDirection = n.ReadingDirection.Auto : "1" === r ? s.readingDirection = n.ReadingDirection.LeftToRight : "2" === r ? s.readingDirection = n.ReadingDirection.RightToLeft : t.warn(`Invalid readingOrder '${r}'; the direction was left automatic.`, { onceKey: "xlsx.style.readingOrder" })), Object.keys(s).length > 0 && (o.alignment = s), o;
1229
+ }
1230
+ collectHiddenXfs(t) {
1231
+ const e = /* @__PURE__ */ new Set();
1232
+ if (!t) return e;
1233
+ const o = t.childNodes;
1234
+ let s = 0;
1235
+ for (let t = 0; t < o.length; t++) {
1236
+ const r = o.item(t);
1237
+ if (1 !== r.nodeType || "xf" !== r.localName) continue;
1238
+ const i = r.childNodes;
1239
+ for (let t = 0; t < i.length; t++) {
1240
+ const o = i.item(t);
1241
+ 1 === o.nodeType && "protection" === o.localName && Q(o.getAttribute("hidden") ?? "") && e.add(s);
1242
+ }
1243
+ s++;
1244
+ }
1245
+ return e;
1246
+ }
1247
+ collectXfComplements(t) {
1248
+ const e = /* @__PURE__ */ new Map();
1249
+ if (!t) return e;
1250
+ const o = t.childNodes;
1251
+ let s = 0;
1252
+ for (let t = 0; t < o.length; t++) {
1253
+ const r = o.item(t);
1254
+ if (1 !== r.nodeType || "xf" !== r.localName) continue;
1255
+ const i = Nt(r, "extLst");
1256
+ if (i) {
1257
+ const t = i.childNodes;
1258
+ for (let o = 0; o < t.length; o++) {
1259
+ const r = Nt(t.item(o), "xfComplement"), i = parseInt(r?.getAttribute("i") ?? "", 10);
1260
+ isNaN(i) || e.set(s, i);
1261
+ }
1262
+ }
1263
+ s++;
1264
+ }
1265
+ return e;
1266
+ }
1267
+ processProtection(t, e, o) {
1268
+ if (!e) return;
1269
+ const s = e.getAttribute("locked");
1270
+ return o.protection = { alwaysUnlocked: !!s && !Q(s) }, o;
1271
+ }
1272
+ processDXF(t, e, o) {
1273
+ if (!e) return;
1274
+ const s = e.childNodes, r = s.length;
1275
+ for (let e = 0; e < r; e++) {
1276
+ const r = s.item(e);
1277
+ if (1 === r.nodeType && "font" === r.localName) {
1278
+ const e = {};
1279
+ this.processFont(t, r, e), o.font = e;
1280
+ } else if (1 === r.nodeType && "fill" === r.localName) {
1281
+ const e = [];
1282
+ this.processFill(t, r, e, 0), e.length > 0 && e[0] && (o.fill = e[0]);
1283
+ } else if (1 === r.nodeType && "border" === r.localName) {
1284
+ const e = [];
1285
+ this.processBorder(t, r, e, 0, !1), e.length > 0 && e[0] && (o.borders = e[0]);
1286
+ } else if (1 === r.nodeType && "numFmt" === r.localName) {
1287
+ const t = r.getAttribute("formatCode");
1288
+ if (t) o.numberFormat = t;
1289
+ else {
1290
+ const t = r.getAttribute("numFmtId");
1291
+ t && (o.numberFormat = Number(t));
1292
+ }
1293
+ } else 1 === r.nodeType && "alignment" === r.localName && this.processAlignment(t, r, o);
1294
+ }
1295
+ }
1296
+ processDXFs(t, e, o) {
1297
+ if (!e) return;
1298
+ t.getVisitorParamsState().set("processingDXFs", !0);
1299
+ const s = /* @__PURE__ */ new Map();
1300
+ t.getVisitorParamsState().set("dxfs", s);
1301
+ const r = e.childNodes, i = r.length;
1302
+ for (let e = 0; e < i; e++) {
1303
+ const i = r.item(e);
1304
+ if (1 === i.nodeType && "dxf" === i.localName) {
1305
+ const e = {};
1306
+ this.processDXF(t, i, e);
1307
+ const r = o.length;
1308
+ s.set(r, e), o.push(e);
1309
+ }
1310
+ }
1311
+ t.getVisitorParamsState().delete("processingDXFs");
1312
+ }
1313
+ processSlicerStyles(t, e, o) {
1314
+ if (!e) return;
1315
+ let s = null, r = null;
1316
+ const i = e.childNodes;
1317
+ for (let t = 0; t < i.length; t++) {
1318
+ const e = i.item(t);
1319
+ if (1 !== e.nodeType || "ext" !== e.localName) continue;
1320
+ const o = e.childNodes;
1321
+ for (let t = 0; t < o.length; t++) {
1322
+ const e = o.item(t);
1323
+ 1 === e.nodeType && ("dxfs" === e.localName ? s = e : "slicerStyles" === e.localName && (r = e));
1324
+ }
1325
+ }
1326
+ if (!r) return;
1327
+ const n = [];
1328
+ if (s) {
1329
+ t.getVisitorParamsState().set("processingDXFs", !0);
1330
+ const e = s.childNodes;
1331
+ for (let o = 0; o < e.length; o++) {
1332
+ const s = e.item(o);
1333
+ if (1 !== s.nodeType || "dxf" !== s.localName) continue;
1334
+ const r = {};
1335
+ this.processDXF(t, s, r), n.push(r);
1336
+ }
1337
+ t.getVisitorParamsState().delete("processingDXFs");
1338
+ }
1339
+ const l = {}, a = r.getAttribute("defaultSlicerStyle");
1340
+ a && "SlicerStyleLight1" !== a && (l.defaultSlicerStyle = a);
1341
+ const c = o.tables?.styles, u = r.childNodes;
1342
+ for (let e = 0; e < u.length; e++) {
1343
+ const o = u.item(e);
1344
+ if (1 !== o.nodeType || "slicerStyle" !== o.localName) continue;
1345
+ const s = o.getAttribute("name");
1346
+ if (!s) continue;
1347
+ const r = {}, i = c?.[s];
1348
+ i && !1 === i.table && !i.pivot && (i.wholeTable && (r.wholeTable = i.wholeTable), i.headerRow && (r.headerRow = i.headerRow), delete c[s]);
1349
+ const a = t.evaluate("slicerStyleElements", o)?.childNodes, d = a?.length ?? 0;
1350
+ for (let e = 0; e < d; e++) {
1351
+ const o = a.item(e);
1352
+ if (1 !== o.nodeType || "slicerStyleElement" !== o.localName) continue;
1353
+ const s = o.getAttribute("type");
1354
+ if (!s || !Ft.has(s)) continue;
1355
+ const i = o.getAttribute("dxfId"), l = null != i ? n[parseInt(i)] : void 0;
1356
+ l ? r[s] = l : t.warn(`A slicer style names a format that does not exist (dxfId '${i}').`, { onceKey: "xlsx.style.slicerStyle.dxf" });
1357
+ }
1358
+ (l.styles ??= {})[s] = r;
1359
+ }
1360
+ c && 0 === Object.keys(c).length && (delete o.tables.styles, 0 === Object.keys(o.tables).length && delete o.tables), Object.keys(l).length > 0 && (o.slicers = l);
1361
+ }
1362
+ processTableStyle(t, e, o, s, r = !1) {
1363
+ const i = e.getAttribute("name"), n = { name: i };
1364
+ e.hasAttribute("table") && (n.table = Q(e.getAttribute("table"))), e.hasAttribute("pivot") && (n.pivot = Q(e.getAttribute("pivot"))), r && !n.pivot && s.unshift(null);
1365
+ const l = e.childNodes, a = l.length;
1366
+ for (let e = 0; e < a; e++) {
1367
+ const o = l.item(e);
1368
+ if (1 === o.nodeType && "tableStyleElement" === o.localName) {
1369
+ const e = o.getAttribute("type"), r = o.getAttribute("dxfId");
1370
+ let i = null != r ? s?.[r] : void 0;
1371
+ i || (t.warn(`A table style names a format that does not exist (dxfId '${r}').`, { onceKey: "xlsx.style.tableStyle.dxf" }), i = {}), n[e] = i;
1372
+ let l = null;
1373
+ o.hasAttribute("size") && (l = parseInt(o.getAttribute("size"))), l && !isNaN(l) && (i.size = l);
1374
+ }
1375
+ }
1376
+ delete n.name, o[i] = n;
1377
+ }
1378
+ processTableStyles(t, e, o, s, r) {
1379
+ if (!e) return;
1380
+ const i = {}, n = e.getAttribute("defaultTableStyle");
1381
+ n && (i.defaultTableStyle = n);
1382
+ const l = e.getAttribute("defaultPivotStyle");
1383
+ l && (i.defaultPivotStyle = l);
1384
+ const a = e.childNodes, c = {}, u = a.length;
1385
+ for (let e = 0; e < u; e++) {
1386
+ const o = a.item(e);
1387
+ 1 === o.nodeType && "tableStyle" === o.localName && this.processTableStyle(t, o, c, s, r);
1388
+ }
1389
+ return Object.keys(c).length > 0 && (i.styles = c), Object.keys(i).length > 0 && (o.tables = i), o;
1390
+ }
1391
+ processCellStyles(t, e, o, s, r) {
1392
+ if (!e) return;
1393
+ const i = e.childNodes, n = i.length;
1394
+ for (let t = 0; t < n; t++) {
1395
+ const e = i.item(t);
1396
+ if (1 === e.nodeType && "cellStyle" === e.localName) {
1397
+ const t = parseInt(e.getAttribute("xfId") ?? ""), i = e.getAttribute("name"), n = e.getAttribute("builtinId");
1398
+ let a = i;
1399
+ if (null !== n) {
1400
+ const t = l.builtInNameFromId(parseInt(n));
1401
+ void 0 !== t && (a = t);
1402
+ }
1403
+ if (r.set(t, a), !s[t]) continue;
1404
+ const c = {
1405
+ name: a,
1406
+ style: s[t]
1407
+ };
1408
+ e.getAttribute("hidden") && (c.hidden = Q(e.getAttribute("hidden"))), e.getAttribute("iLevel") && (c.iLevel = parseInt(e.getAttribute("iLevel"))), null !== n && Q(e.getAttribute("customBuiltin") ?? "0") && (c.customized = !0), o.push(c);
1409
+ }
1410
+ }
1411
+ }
1412
+ afterVisit(t, e, o) {}
1413
+ },
1414
+ WorkbookVisitor: class extends At {
1415
+ visit(t, e, o) {
1416
+ return this.processSheetRefs(t, t.evaluate("sheets", e), o), this.processExternalReferences(t, t.evaluate("externalReferences", e), o), this.processBookViews(t, t.evaluate("bookViews", e), o), this.processDefinedNames(t, t.evaluate("definedNames", e), o), this.processCalcPr(t, t.evaluate("calcPr", e), o), this.processPivotCaches(t, t.evaluate("pivotCaches", e), o), this.processWorkbookProtection(t, t.evaluate("workbookProtection", e), o), this.processWorkbookPr(t, t.evaluate("workbookPr", e), o), o;
1417
+ }
1418
+ processPassword(t, e, o, s = "workbook", r = "password") {
1419
+ if (!e) return;
1420
+ const i = {};
1421
+ t.copyFromAttribute(e, `${s}AlgorithmName`, i, "algorithm"), t.copyFromAttribute(e, `${s}HashValue`, i, "hash"), t.copyFromAttribute(e, `${s}SaltValue`, i, "salt"), t.copyFromAttribute(e, `${s}SpinCount`, i, "spinCount", t.INT_COPY), t.copyFromAttribute(e, `${s}Password`, i, "legacyHash"), Object.keys(i).length > 0 && (o[r] = i);
1422
+ }
1423
+ processWorkbookProtection(t, e, o) {
1424
+ if (!e) return;
1425
+ const s = {};
1426
+ this.processPassword(t, e, s, "workbook", "password"), this.processPassword(t, e, s, "revisions", "revisionsPassword");
1427
+ for (const t of L) s[t.key] = T(t, e.getAttribute(t.attribute));
1428
+ return o.protection = s, o;
1429
+ }
1430
+ processCalcPr(t, e, o) {
1431
+ if (!e) return;
1432
+ const s = {};
1433
+ t.copyFromAttribute(e, "calcMode", s, "calcMode", (t) => Ct[t] ?? null), t.copyFromAttribute(e, "fullCalcOnLoad", s, "fullCalcOnLoad", t.BOOLEAN_COPY), t.copyFromAttribute(e, "calcOnSave", s, "calcOnSave", t.BOOLEAN_COPY), t.copyFromAttribute(e, "calcCompleted", s, "calcCompleted", t.BOOLEAN_COPY), t.copyFromAttribute(e, "fullPrecision", s, "fullPrecision", t.BOOLEAN_COPY), t.copyFromAttribute(e, "forceFullCalc", s, "forceFullCalc", t.BOOLEAN_COPY), t.copyFromAttribute(e, "concurrentCalc", s, "concurrentCalc", t.BOOLEAN_COPY), t.copyFromAttribute(e, "concurrentManualCount", s, "concurrentManualCount", t.INT_COPY), t.copyFromAttribute(e, "refMode", s, "refMode"), t.copyFromAttribute(e, "iterate", s, "iterate", t.BOOLEAN_COPY), t.copyFromAttribute(e, "iterateCount", s, "maxIteration", t.INT_COPY), t.copyFromAttribute(e, "iterateDelta", s, "maxIterateChange", t.FLOAT_COPY);
1434
+ const r = e.getAttribute("calcId");
1435
+ null !== r && t.getVisitorParamsState().set("calcId", r), o.calc = s;
1436
+ }
1437
+ processSheetRefs(t, e, o) {
1438
+ if (!e) return;
1439
+ const s = [], r = e.childNodes, i = r.length;
1440
+ for (let e = 0; e < i; e++) {
1441
+ const o = r.item(e);
1442
+ 1 === o.nodeType && "sheet" === o.localName && this.processSheetRef(t, o, s);
1443
+ }
1444
+ o.sheets = s;
1445
+ }
1446
+ processSheetRef(t, e, o) {
1447
+ const s = {};
1448
+ t.copyFromAttribute(e, "name", s, "name"), t.copyFromAttribute(e, "state", s, "visibility"), t.copyFromAttribute(e, "sheetId", s, "sheetId", t.INT_COPY);
1449
+ const r = e.getAttribute("r:id"), i = r ? R(t.getRelationships().get(r)?.type) : null;
1450
+ if (i) {
1451
+ const e = t.readEmbeddedPart(r);
1452
+ if (e?.xml) {
1453
+ const t = { part: e }, r = O(e.xml), n = r ? G((t) => r.get(t)) : void 0;
1454
+ n && (t.tabColor = n), s.kind = i, s.sheet = t, o.push(s);
1455
+ return;
1456
+ }
1457
+ t.warn(`The ${i} sheet '${s.name}' could not be read and was loaded as an empty worksheet.`), o.push(s);
1458
+ return;
1459
+ }
1460
+ const n = r ? t.getRef(r) : null;
1461
+ n && (s.sheet = n), o.push(s);
1462
+ }
1463
+ processExternalReferences(t, e, o) {
1464
+ if (!e) return;
1465
+ const s = [], r = e.childNodes, i = r.length;
1466
+ for (let e = 0; e < i; e++) {
1467
+ const o = r.item(e);
1468
+ if (1 === o.nodeType && "externalReference" === o.localName) {
1469
+ const e = o.getAttribute("r:id"), r = e ? t.getRef(e) : null;
1470
+ s.push(r ?? null);
1471
+ }
1472
+ }
1473
+ s.length > 0 && (o.externalBooks = s);
1474
+ }
1475
+ processPivotCaches(t, e, o) {
1476
+ if (!e) return;
1477
+ const s = [], r = e.childNodes, i = r.length;
1478
+ for (let e = 0; e < i; e++) {
1479
+ const o = r.item(e);
1480
+ if (1 !== o.nodeType || "pivotCache" !== o.localName) continue;
1481
+ const i = parseInt(o.getAttribute("cacheId") ?? "", 10), n = o.getAttribute("r:id");
1482
+ if (isNaN(i) || !n) continue;
1483
+ const l = t.readEmbeddedPart(n);
1484
+ l && s.push({
1485
+ cacheId: i,
1486
+ part: l
1487
+ });
1488
+ }
1489
+ s.length > 0 && (o.pivotCaches = s);
1490
+ }
1491
+ processBookViews(t, e, o) {
1492
+ if (!e) return;
1493
+ const s = e.childNodes;
1494
+ let r = 0;
1495
+ const i = s.length;
1496
+ for (let e = 0; r < 1 && e < i; e++) {
1497
+ const i = s.item(e);
1498
+ 1 === i.nodeType && "workbookView" === i.localName && (this.processWorkbookView(t, i, o), r++);
1499
+ }
1500
+ }
1501
+ processWorkbookView(t, e, o) {
1502
+ if (!e) return;
1503
+ const s = {}, r = [
1504
+ "xWindow",
1505
+ "yWindow",
1506
+ "windowWidth",
1507
+ "windowHeight"
1508
+ ].map((t) => parseInt(e.getAttribute(t) ?? "", 10));
1509
+ if (r.some((t) => Number.isFinite(t))) {
1510
+ const [t, e, o, i] = r.map((t) => Number.isFinite(t) ? t : 0);
1511
+ s.windowBounds = {
1512
+ left: t,
1513
+ top: e,
1514
+ width: o,
1515
+ height: i
1516
+ };
1517
+ }
1518
+ t.copyFromAttribute(e, "activeTab", s, "activeSheetId", [t.INT_COPY, (t) => t]), e.hasAttribute("activeTab") || (s.activeSheetId = 0), t.copyFromAttribute(e, "showHorizontalScroll", s, "showHorizontalScrollbar", t.BOOLEAN_COPY), t.copyFromAttribute(e, "showVerticalScroll", s, "showVerticalScrollbar", t.BOOLEAN_COPY), t.copyFromAttribute(e, "showSheetTabs", s, "showTabs", t.BOOLEAN_COPY), t.copyFromAttribute(e, "tabRatio", s, "tabRatio", [t.FLOAT_COPY, (t) => t]), t.copyFromAttribute(e, "firstSheet", s, "firstTab", [t.INT_COPY, (t) => t]), t.copyFromAttribute(e, "minimized", s, "minimized", t.BOOLEAN_COPY), t.copyFromAttribute(e, "autoFilterDateGrouping", s, "autoFilterDateGrouping", t.BOOLEAN_COPY);
1519
+ const i = e.getAttribute("visibility");
1520
+ "hidden" !== i && "veryHidden" !== i || (s.visibility = i), Object.keys(s).length > 0 && (o.view = s);
1521
+ }
1522
+ processDefineName(t, e, o, s) {
1523
+ if (!e) return;
1524
+ const r = {}, i = e.firstChild;
1525
+ if (i && 3 === i.nodeType && (r.ref = i.textContent), t.copyFromAttribute(e, "name", r), t.copyFromAttribute(e, "comment", r), t.copyFromAttribute(e, "hidden", r, "hidden", t.BOOLEAN_COPY), e.hasAttribute("localSheetId")) {
1526
+ const o = e.getAttribute("localSheetId");
1527
+ if (!s[o]?.name) return void t.warn(`Defined name '${e.getAttribute("name")}' references a sheet with localSheetId '${o}' which does not exist.`);
1528
+ r.scope = s[o].name;
1529
+ }
1530
+ const n = {};
1531
+ for (const o of st) t.copyFromAttribute(e, o, n);
1532
+ for (const t of rt) {
1533
+ const o = e.getAttribute(t);
1534
+ "1" !== o && "true" !== o || (n[t] = !0);
1535
+ }
1536
+ t.copyFromAttribute(e, "functionGroupId", n, "functionGroupId", t.INT_COPY), Object.keys(n).length > 0 && (r.fileAttributes = n), Object.keys(r).length > 0 && o.push(r);
1537
+ }
1538
+ processDefinedNames(t, e, o) {
1539
+ if (!e) return;
1540
+ const s = [], r = e.childNodes, i = r.length;
1541
+ for (let e = 0; e < i; e++) {
1542
+ const i = r.item(e);
1543
+ 1 === i.nodeType && "definedName" === i.localName && this.processDefineName(t, i, s, o.sheets);
1544
+ }
1545
+ s.length > 0 && (o.names = s);
1546
+ }
1547
+ processWorkbookPr(t, e, o) {
1548
+ e && (t.copyFromAttribute(e, "date1904", o, "date1904", t.BOOLEAN_COPY), t.copyFromAttribute(e, "codeName", o, "codeName"), t.copyFromAttribute(e, "updateLinks", o, "updateLinks"));
1549
+ }
1550
+ afterVisit(t, e, o) {}
1551
+ },
1552
+ TableVisitor: class {
1553
+ visit(t, e, o) {
1554
+ const s = {};
1555
+ return t.copyFromAttribute(e, "ref", o, "r"), t.getVisitorParamsState().set("ref", o.r), o.v = s, t.copyFromAttribute(e, "name", s), t.copyFromAttribute(e, "displayName", s, "name"), t.copyFromAttribute(e, "headerRowCount", s, "headerRowCount", t.INT_COPY), t.copyFromAttribute(e, "totalsRowCount", s, "totalsRowCount", t.INT_COPY), this.processTableColumns(t, e, s), this.processTableStyleInfo(t, e, s), t.copyFromAttribute(e, "id", s), t.copyFromAttribute(e, "comment", s, "description"), t.copyFromAttribute(e, "connectionId", s, "connectionId", t.INT_COPY), t.copyFromAttribute(e, "tableType", s), t.copyFromAttribute(e, "published", s, "published", t.BOOLEAN_COPY), t.copyFromAttribute(e, "insertRow", s, "insertRow", t.BOOLEAN_COPY), t.copyFromAttribute(e, "insertRowShift", s, "insertRowShift", t.BOOLEAN_COPY), s.totalsRowShown = "0" !== e.getAttribute("totalsRowShown"), s;
1556
+ }
1557
+ afterVisit(t, e, o) {
1558
+ const s = o.v;
1559
+ if (t.evaluate("autoFilter", e)) {
1560
+ if (Array.isArray(s.hiddenButtons)) {
1561
+ const t = s.hiddenButtons.length;
1562
+ 0 === t ? s.hiddenButtons = !1 : t === s.columns?.length && (s.hiddenButtons = !0);
1563
+ }
1564
+ } else s.hiddenButtons = !0, s.showButtons = !1;
1565
+ return s;
1566
+ }
1567
+ processTableStyleInfo(t, e, o) {
1568
+ if (!e) return;
1569
+ const s = e.childNodes, r = {}, i = s.length;
1570
+ for (let e = 0; e < i; e++) {
1571
+ const o = s.item(e);
1572
+ 1 === o.nodeType && "tableStyleInfo" === o.localName && (t.copyFromAttribute(o, "name", r), t.copyFromAttribute(o, "showColumnStripes", r, "showColumnStripes", t.BOOLEAN_COPY), t.copyFromAttribute(o, "showFirstColumn", r, "showFirstColumn", t.BOOLEAN_COPY), t.copyFromAttribute(o, "showLastColumn", r, "showLastColumn", t.BOOLEAN_COPY), t.copyFromAttribute(o, "showRowStripes", r, "showRowStripes", t.BOOLEAN_COPY));
1573
+ }
1574
+ Object.keys(r).length > 0 && (o.style = r);
1575
+ }
1576
+ processTableColumn(t, e, o) {
1577
+ if (!e) return null;
1578
+ const s = e.childNodes, r = s.length;
1579
+ for (let e = 0; e < r; e++) {
1580
+ const r = s.item(e);
1581
+ if (1 === r.nodeType && "tableColumn" === r.localName) {
1582
+ const e = {};
1583
+ t.copyFromAttribute(r, "name", e), t.copyFromAttribute(r, "id", e), t.copyFromAttribute(r, "uniqueName", e), t.copyFromAttribute(r, "queryTableFieldId", e), t.copyFromAttribute(r, "totalsRowLabel", e);
1584
+ let s = r.getAttribute("totalsRowFunction");
1585
+ if (null !== s) if ("custom" === s) {
1586
+ const o = t.evaluate("totalsRowFormula", r);
1587
+ o && (e.totalsRowFormula = o.textContent);
1588
+ } else e.totalsRowFormula = s;
1589
+ t.copyFromAttribute(r, "totalsRowLabel", e);
1590
+ const i = t.evaluate("calculatedColumnFormula", r);
1591
+ i?.textContent && (e.calculatedColumnFormula = i.textContent), o.push(e);
1592
+ }
1593
+ }
1594
+ return o;
1595
+ }
1596
+ processTableColumns(t, e, o) {
1597
+ const s = e.childNodes, r = [], i = s.length;
1598
+ for (let e = 0; e < i; e++) {
1599
+ const o = s.item(e);
1600
+ 1 === o.nodeType && "tableColumns" === o.localName && this.processTableColumn(t, o, r);
1601
+ }
1602
+ r.length > 0 && (o.columns = r);
1603
+ }
1604
+ },
1605
+ TableX14Visitor: class {
1606
+ visit(t, e, o) {
1607
+ const s = t.getVisitorParamsState().get("ref");
1608
+ if (s) {
1609
+ const o = t.getVisitorParamsState().get("descriptions");
1610
+ o && (o.add(s, e.getAttribute("altText")), o.add(s, e.getAttribute("altTextSummary")));
1611
+ }
1612
+ return t.copyFromAttribute(e, "altText", o), t.copyFromAttribute(e, "altTextSummary", o), o;
1613
+ }
1614
+ },
1615
+ ExternalLinkVisitor: class {
1616
+ visit(t, e, o) {
1617
+ const s = e.childNodes, r = s.length;
1618
+ let i = null;
1619
+ for (let t = 0; t < r; t++) {
1620
+ const e = s.item(t);
1621
+ if (1 === e.nodeType) {
1622
+ "externalBook" === e.localName && (i = e);
1623
+ break;
1624
+ }
1625
+ }
1626
+ if (!i) return o;
1627
+ e.getAttribute("mc:Ignorable") && (o.mceIgnorable = !0);
1628
+ const n = i.getAttribute("r:id");
1629
+ n && (o.__bookRelId = n);
1630
+ const l = this._findAbsoluteUrlRelId(i);
1631
+ return l && (o.__absoluteUrlRelId = l), o.sheetNames = [], this.processSheetNames(t, i, o), this.processDefinedNames(t, i, o), this.processSheetDataSet(t, i, o), o;
1632
+ }
1633
+ processSheetNames(t, e, o) {
1634
+ const s = this._findChild(e, "sheetNames");
1635
+ if (!s) return;
1636
+ const r = s.childNodes, i = r.length;
1637
+ for (let t = 0; t < i; t++) {
1638
+ const e = r.item(t);
1639
+ 1 === e.nodeType && "sheetName" === e.localName && o.sheetNames.push(e.getAttribute("val") ?? "");
1640
+ }
1641
+ }
1642
+ processDefinedNames(t, e, o) {
1643
+ const s = this._findChild(e, "definedNames");
1644
+ if (!s) return;
1645
+ const r = [], i = s.childNodes, n = i.length;
1646
+ for (let t = 0; t < n; t++) {
1647
+ const e = i.item(t);
1648
+ if (1 !== e.nodeType || "definedName" !== e.localName) continue;
1649
+ const o = e.getAttribute("name");
1650
+ if (!o) continue;
1651
+ const s = {
1652
+ name: o,
1653
+ refersTo: e.getAttribute("refersTo") ?? ""
1654
+ }, n = e.getAttribute("sheetId");
1655
+ null !== n && (s.sheetIndex = parseInt(n, 10)), r.push(s);
1656
+ }
1657
+ r.length > 0 && (o.definedNames = r);
1658
+ }
1659
+ processSheetDataSet(t, e, o) {
1660
+ const s = this._findChild(e, "sheetDataSet");
1661
+ if (!s) return;
1662
+ const r = [], i = s.childNodes, n = i.length;
1663
+ for (let e = 0; e < n; e++) {
1664
+ const o = i.item(e);
1665
+ if (1 !== o.nodeType || "sheetData" !== o.localName) continue;
1666
+ const s = o.getAttribute("sheetId");
1667
+ if (null === s) continue;
1668
+ const n = this.processSheetData(t, o);
1669
+ n.sheetIndex = parseInt(s, 10), "1" === o.getAttribute("refreshError") && (n.refreshError = !0), r.push(n);
1670
+ }
1671
+ r.length > 0 && (o.sheetDataSet = r);
1672
+ }
1673
+ processSheetData(t, e) {
1674
+ const o = new m.Builder(), s = e.childNodes, r = s.length;
1675
+ for (let t = 0; t < r; t++) {
1676
+ const e = s.item(t);
1677
+ if (1 !== e.nodeType || "row" !== e.localName) continue;
1678
+ const r = e.childNodes, i = r.length;
1679
+ for (let t = 0; t < i; t++) {
1680
+ const e = r.item(t);
1681
+ if (1 !== e.nodeType || "cell" !== e.localName) continue;
1682
+ const s = e.getAttribute("r");
1683
+ if (!s) continue;
1684
+ const i = u.fastStringToCell(s);
1685
+ if (void 0 === i?.rowIndex || void 0 === i?.colIndex) continue;
1686
+ const n = this._readCellValue(e);
1687
+ void 0 !== n && o.pushAt(i.rowIndex, i.colIndex, n);
1688
+ }
1689
+ }
1690
+ return {
1691
+ sheetIndex: -1,
1692
+ data: o.build()?.tuples ?? []
1693
+ };
1694
+ }
1695
+ _readCellValue(t) {
1696
+ const e = this._findChild(t, "v")?.textContent?.trim();
1697
+ if (void 0 !== e && "" !== e) switch (t.getAttribute("t")) {
1698
+ case null:
1699
+ case "n": return parseFloat(e);
1700
+ case "b": return "1" === e || "true" === e;
1701
+ case "str":
1702
+ default: return e;
1703
+ case "e": {
1704
+ const t = a.getBuiltInByLabel(e);
1705
+ return t ? {
1706
+ t: "e",
1707
+ v: t.getCode()
1708
+ } : e;
1709
+ }
1710
+ }
1711
+ }
1712
+ _findChild(t, e) {
1713
+ const o = t.childNodes, s = o.length;
1714
+ for (let t = 0; t < s; t++) {
1715
+ const s = o.item(t);
1716
+ if (1 === s.nodeType && s.localName === e) return s;
1717
+ }
1718
+ return null;
1719
+ }
1720
+ _findAbsoluteUrlRelId(t) {
1721
+ const e = this._findChild(t, "alternateUrls");
1722
+ return e ? this._findChild(e, "absoluteUrl")?.getAttribute("r:id") ?? null : null;
1723
+ }
1724
+ },
1725
+ SlicerCacheDefinitionVisitor: class {
1726
+ visit(t, e, o) {
1727
+ t.copyFromAttribute(e, "name", o, "cacheName"), t.copyFromAttribute(e, "sourceName", o);
1728
+ const s = t.evaluate("*/tableSlicerCache", e);
1729
+ return s ? (t.copyFromAttribute(s, "tableId", o), t.copyFromAttribute(s, "column", o, "columnId"), t.copyFromAttribute(s, "sortOrder", o), t.copyFromAttribute(s, "customListSort", o, "customListSort", t.BOOLEAN_COPY), t.copyFromAttribute(s, "crossFilter", o), o) : (t.warn("A slicer names no table; it was not imported.", { onceKey: "xlsx.slicer.cacheDefinition" }), o);
1730
+ }
1731
+ },
1732
+ SlicersVisitor: class {
1733
+ visit(t, e, o) {
1734
+ let s = o.slicers;
1735
+ s || (s = {}, o.slicers = s);
1736
+ const r = e.childNodes, i = r.length;
1737
+ for (let e = 0; e < i; e++) {
1738
+ const o = r.item(e);
1739
+ 1 === o.nodeType && "slicer" === o.localName && this.processSlicer(t, o, s);
1740
+ }
1741
+ return s;
1742
+ }
1743
+ processSlicer(t, e, o) {
1744
+ if (!e) return;
1745
+ const s = {};
1746
+ o[e.getAttribute("name")] = s, t.copyFromAttribute(e, "xr10:uid", s, "uid");
1747
+ const r = e.getAttribute("cache"), i = t.getVisitorParamsState().get("slicerCaches"), n = r ? i?.get(r) : void 0;
1748
+ if (n) for (let t = 0; t < St.length; t++) {
1749
+ const e = St[t];
1750
+ void 0 !== n[e] && (s[e] = n[e]);
1751
+ }
1752
+ t.copyFromAttribute(e, "caption", s), t.copyFromAttribute(e, "startItem", s, "startItem", t.INT_COPY), t.copyFromAttribute(e, "columnCount", s, "columnCount", t.INT_COPY), t.copyFromAttribute(e, "showCaption", s, "showCaption", t.BOOLEAN_COPY), t.copyFromAttribute(e, "level", s, "level", t.INT_COPY), t.copyFromAttribute(e, "style", s), t.copyFromAttribute(e, "lockedPosition", s, "lockedPosition", t.BOOLEAN_COPY), t.copyFromAttribute(e, "rowHeight", s, "rowHeight", t.INT_COPY);
1753
+ }
1754
+ },
1755
+ FormControlPrVisitor: class {
1756
+ visit(t, e, o) {
1757
+ const s = {}, r = e.attributes;
1758
+ for (let t = 0; t < r.length; t++) {
1759
+ const e = r.item(t), o = e.name;
1760
+ "xmlns" === o || o.startsWith("xmlns:") || (s[o] = e.value);
1761
+ }
1762
+ const i = [];
1763
+ let n;
1764
+ const l = e.childNodes;
1765
+ for (let e = 0; e < l.length; e++) {
1766
+ const o = l.item(e);
1767
+ if (1 === o.nodeType) if ("itemLst" === o.localName) {
1768
+ const t = o.childNodes;
1769
+ for (let e = 0; e < t.length; e++) {
1770
+ const o = t.item(e);
1771
+ 1 === o.nodeType && "item" === o.localName && i.push(o.getAttribute("val") ?? "");
1772
+ }
1773
+ } else "extLst" === o.localName && (n = t.serializeElement(o) ?? void 0);
1774
+ }
1775
+ const a = w(s, i, n);
1776
+ return o.formControl = a, a;
1777
+ }
1778
+ },
1779
+ DrawingVisitor: class {
1780
+ visit(t, e, o) {
1781
+ return o;
1782
+ }
1783
+ afterVisit(t, e, o) {
1784
+ for (const t of o?.movables ?? []) xt(t, !1);
1785
+ }
1786
+ },
1787
+ DrawingAnchorVisitor: class {
1788
+ visit(t, e, o) {
1789
+ if (!e) return;
1790
+ const s = {};
1791
+ t.copyFromAttribute(e, "editAs", s, "anchorType"), s.anchor = {}, "absoluteAnchor" === e.localName ? (s.anchorType = "absolute", this.processAbsoluteCoord(t, t.evaluate("pos", e), s.anchor, "from", "x", "y"), this.processAbsoluteCoord(t, t.evaluate("ext", e), s.anchor, "to", "cx", "cy")) : "oneCellAnchor" === e.localName ? (this.processOffsetCoord(t, t.evaluate("from", e), s.anchor, "from"), this.processAbsoluteCoord(t, t.evaluate("ext", e), s.anchor, "to", "cx", "cy")) : (this.processOffsetCoord(t, t.evaluate("from", e), s.anchor, "from"), this.processOffsetCoord(t, t.evaluate("to", e), s.anchor, "to"));
1792
+ const r = t.evaluate("clientData", e), i = (t) => {
1793
+ const e = r?.getAttribute(t);
1794
+ return "0" === e || "false" === e;
1795
+ };
1796
+ return i("fPrintsWithSheet") && (s.noPrint = !0), i("fLocksWithSheet") && (s.unlocked = !0), o.movables || (o.movables = []), o.movables.push(s), s;
1797
+ }
1798
+ processAbsoluteCoord(t, e, o, s, r, i) {
1799
+ if (!e) return;
1800
+ const n = {
1801
+ x: 0,
1802
+ y: 0
1803
+ };
1804
+ return n.x = H(e.getAttribute(r)), n.y = H(e.getAttribute(i)), "from" === s ? o.tl = n : o.br = n, o;
1805
+ }
1806
+ processOffsetCoord(t, e, o, s) {
1807
+ if (!e) return;
1808
+ const r = {
1809
+ c: 0,
1810
+ r: 0,
1811
+ x: 0,
1812
+ y: 0
1813
+ };
1814
+ return t.evaluate("col", e) && (r.c = parseInt(t.evaluate("col", e).textContent)), t.evaluate("row", e) && (r.r = parseInt(t.evaluate("row", e).textContent)), t.evaluate("colOff", e) && (r.x = H(t.evaluate("colOff", e).textContent)), t.evaluate("rowOff", e) && (r.y = H(t.evaluate("rowOff", e).textContent)), "from" === s ? o.tl = r : o.br = r, o;
1815
+ }
1816
+ },
1817
+ DrawingGraphicFrameVisitor: class extends ft {
1818
+ visit(t, e, o) {
1819
+ if (!e) return;
1820
+ if (this.isGroupContent(o)) {
1821
+ if (t.getPath().includes("Fallback")) return {};
1822
+ const { movable: s } = this.readMemberHeader(t, e, "graphicFrame"), r = t.evaluate("xfrm", e);
1823
+ if (r) {
1824
+ F(r, s);
1825
+ const e = t.evaluate("off", r), o = t.evaluate("ext", r);
1826
+ s.anchor = {
1827
+ tl: {
1828
+ x: H(e?.getAttribute("x") ?? null) ?? 0,
1829
+ y: H(e?.getAttribute("y") ?? null) ?? 0
1830
+ },
1831
+ br: {
1832
+ x: H(o?.getAttribute("cx") ?? null) ?? 0,
1833
+ y: H(o?.getAttribute("cy") ?? null) ?? 0
1834
+ }
1835
+ };
1836
+ }
1837
+ const i = this.readGraphic(t, e), n = "chart" === i.type ? {
1838
+ ...s.content.json,
1839
+ ...i.json
1840
+ } : i.json;
1841
+ return s.content = {
1842
+ ...s.content,
1843
+ type: i.type,
1844
+ json: n
1845
+ }, o.members.push(s), i.json;
1846
+ }
1847
+ o = super.visit(t, e, o);
1848
+ const s = t.evaluate("nvGraphicFramePr/cNvGraphicFramePr", e);
1849
+ if (s) {
1850
+ const e = t.evaluate("graphicFrameLocks", s);
1851
+ e && e.hasAttribute("noChangeAspect") && (o.lockAspect = "1" === e.getAttribute("noChangeAspect"));
1852
+ }
1853
+ const r = this.readGraphic(t, e);
1854
+ return this.setContent(o, r), r;
1855
+ }
1856
+ readGraphic(t, e) {
1857
+ const o = t.evaluate("graphic/graphicData", e), s = {
1858
+ type: "graphicFrame",
1859
+ json: {}
1860
+ };
1861
+ if (!o) return s;
1862
+ const r = o.childNodes, i = r.length;
1863
+ for (let o = 0; o < i; o++) {
1864
+ const i = r.item(o);
1865
+ if (1 === i.nodeType) try {
1866
+ let o = i.localName;
1867
+ "chart" === o ? o = "chart" : "slicer" === o && (o = "slicer"), s.type = o;
1868
+ const r = i.getAttribute("r:id");
1869
+ if ("chart" === o && r) {
1870
+ const o = this.readSourceId(t, e), i = t.readEmbeddedPart(r) ?? void 0;
1871
+ let n;
1872
+ try {
1873
+ const e = i?.xml ? it(i.xml) : null;
1874
+ n = e?.model, e?.lossy && t.warn("A chart states something its model does not; it is saved as it was until it is changed.", { onceKey: "xlsx.chart.lossy" });
1875
+ } catch (e) {
1876
+ t.warn(`A chart could not be read into the chart model; it is kept as its markup: ${e?.message ?? e}`, { onceKey: "xlsx.chart.model" });
1877
+ }
1878
+ s.json = {
1879
+ sourceId: o,
1880
+ part: i,
1881
+ model: n
1882
+ };
1883
+ } else if ("slicer" === o) {
1884
+ const o = this.readSourceId(t, e);
1885
+ void 0 !== o && (s.json = { sourceId: o });
1886
+ } else r && (s.json = t.getRef(r));
1887
+ } catch (e) {
1888
+ t.warn(`Unable to read a graphic frame: ${e?.message ?? e}`, { onceKey: "xlsx.drawing.graphicFrame" });
1889
+ }
1890
+ }
1891
+ return s;
1892
+ }
1893
+ },
1894
+ DrawingSpVisitor: wt,
1895
+ DrawingPicVisitor: class extends ft {
1896
+ visit(t, e, o) {
1897
+ if (!e) return;
1898
+ if (this.isGroupContent(o)) {
1899
+ if (t.getPath().includes("Fallback")) return {};
1900
+ const { movable: s, content: r } = this.readMemberHeader(t, e, "picture"), i = this.readImage(t, e);
1901
+ return i ? (this.readPictureDetails(t, e, i, s, r), o.members.push(s), r) : {};
1902
+ }
1903
+ const s = super.visit(t, e, o), r = this.readImage(t, e);
1904
+ if (null === r) return;
1905
+ const i = {}, n = this.readSourceId(t, e);
1906
+ return void 0 !== n && (i.sourceId = n), this.readPictureDetails(t, e, r, s, i), this.setContent(s, {
1907
+ type: "picture",
1908
+ json: i
1909
+ }), i;
1910
+ }
1911
+ readPictureDetails(t, e, o, s, r) {
1912
+ void 0 !== o?.resId && (r.resId = o.resId), o?.image && (r.image = o.image);
1913
+ const i = e.getAttribute("macro");
1914
+ i && (r.macro = i), e.hasAttribute("fPublished") && (r.published = Q(e.getAttribute("fPublished")));
1915
+ const n = t.evaluate("nvPicPr/cNvPicPr", e);
1916
+ if (n?.getAttribute) {
1917
+ "0" === n.getAttribute("preferRelativeResize") && (r.noRelativeResize = !0);
1918
+ const e = this.readLocks(t.evaluate("picLocks", n));
1919
+ e && (r.locks = e), s.lockAspect = e?.noChangeAspect ?? !1;
1920
+ }
1921
+ }
1922
+ readImage(t, e) {
1923
+ const o = t.evaluate("blipFill", e), s = o ? t.evaluate("blip", o) : null;
1924
+ if (!s) return;
1925
+ if (!(s.getAttribute("r:embed") ?? s.getAttribute("embed") ?? s.getAttribute("r:link") ?? s.getAttribute("link"))) return t.warn("A picture names no image; it was not imported.", { onceKey: "xlsx.drawing.picture.noRel" }), null;
1926
+ const { type: r, resId: i, ...n } = new E().processImageFill(t, o);
1927
+ return !n.tile && n.stretch && 0 === Object.keys(n.stretch).length && delete n.stretch, n.extLst && Tt.test(n.extLst) && delete n.extLst, {
1928
+ resId: i,
1929
+ image: Object.keys(n).length > 0 ? n : void 0
1930
+ };
1931
+ }
1932
+ },
1933
+ DrawingGrpSpVisitor: class extends ft {
1934
+ constructor(...t) {
1935
+ super(...t), this._fills = new E();
1936
+ }
1937
+ visit(t, e, o) {
1938
+ if (!e) return;
1939
+ const s = this.isGroupContent(o);
1940
+ let r, i;
1941
+ if (s) {
1942
+ if (t.getPath().includes("Fallback")) return {};
1943
+ const s = this.readMemberHeader(t, e, "group");
1944
+ r = s.movable, i = s.content, o.members.push(r);
1945
+ } else {
1946
+ if (t.getPath().includes("Fallback") && o.content) return {};
1947
+ r = super.visit(t, e, o), i = {};
1948
+ const s = this.readSourceId(t, e);
1949
+ void 0 !== s && (i.sourceId = s), this.setContent(r, {
1950
+ type: "group",
1951
+ json: i
1952
+ });
1953
+ }
1954
+ i.members = [];
1955
+ const n = t.evaluate("nvGrpSpPr/cNvGrpSpPr/grpSpLocks", e);
1956
+ n?.hasAttribute?.("noChangeAspect") && (r.lockAspect = "1" === n.getAttribute("noChangeAspect"));
1957
+ const l = this.readLocks(n);
1958
+ l && (i.locks = l);
1959
+ const a = t.evaluate("grpSpPr", e);
1960
+ if (a) {
1961
+ const e = t.evaluate("xfrm", a);
1962
+ if (e) {
1963
+ F(e, r), "1" === e.getAttribute("flipH") && (r.flipH = !0), "1" === e.getAttribute("flipV") && (r.flipV = !0);
1964
+ const o = Pt(t, e, "off", "ext"), n = Pt(t, e, "chOff", "chExt") ?? o;
1965
+ n && (i.childBounds = n), s && o && (r.anchor = {
1966
+ tl: {
1967
+ x: o.x,
1968
+ y: o.y
1969
+ },
1970
+ br: {
1971
+ x: o.width,
1972
+ y: o.height
1973
+ }
1974
+ });
1975
+ }
1976
+ const o = this._fills.getFill(t, a);
1977
+ o && Object.keys(o).length > 0 && (i.fill = o);
1978
+ const n = this._fills.getEffects(t, a);
1979
+ n && (i.effects = n);
1980
+ const l = t.evaluate("scene3d", a), c = l ? t.serializeElement(l) : null;
1981
+ c && (i.scene3d = c);
1982
+ const u = t.evaluate("extLst", a), d = u ? t.serializeElement(u) : null;
1983
+ d && (i.extLst = {
1984
+ ...i.extLst,
1985
+ properties: d
1986
+ });
1987
+ }
1988
+ return i;
1989
+ }
1990
+ },
1991
+ DrawingCxnSpVisitor: class extends wt {
1992
+ visit(t, e, o) {
1993
+ if (e) return this.visitShape(t, e, o, "cxnSp", "nvCxnSpPr/cNvCxnSpPr/cxnSpLocks");
1994
+ }
1995
+ },
1996
+ MetadataVisitor: class {
1997
+ visit(t, e, o) {
1998
+ const s = [], r = /* @__PURE__ */ new Map(), i = {
1999
+ cells: [],
2000
+ values: []
2001
+ }, n = e.childNodes;
2002
+ for (let t = 0; t < n.length; t++) {
2003
+ const e = n.item(t);
2004
+ if (1 === e.nodeType) switch (e.localName) {
2005
+ case "metadataTypes":
2006
+ this._parseMetadataTypes(e, s, r);
2007
+ break;
2008
+ case "futureMetadata":
2009
+ this._attachFutureMetadata(e, r);
2010
+ break;
2011
+ case "cellMetadata":
2012
+ this._resolveBlocks(e, s, i.cells);
2013
+ break;
2014
+ case "valueMetadata": this._resolveBlocks(e, s, i.values);
2015
+ }
2016
+ }
2017
+ return o.metadata = i, i;
2018
+ }
2019
+ _parseMetadataTypes(t, e, o) {
2020
+ const s = t.childNodes;
2021
+ for (let t = 0; t < s.length; t++) {
2022
+ const r = s.item(t);
2023
+ if (1 === r.nodeType && "metadataType" === r.localName) {
2024
+ const t = this._parseMetadataType(r);
2025
+ e.push(t), o.set(t.name, t);
2026
+ }
2027
+ }
2028
+ }
2029
+ _parseMetadataType(t) {
2030
+ const e = {
2031
+ name: t.getAttribute("name") ?? "",
2032
+ _blocks: []
2033
+ }, o = t.getAttribute("minSupportedVersion");
2034
+ null != o && (e.minSupportedVersion = Number(o));
2035
+ for (const o of [
2036
+ "copy",
2037
+ "pasteAll",
2038
+ "pasteValues",
2039
+ "merge",
2040
+ "splitFirst",
2041
+ "splitAll",
2042
+ "rowColShift",
2043
+ "clearFormats",
2044
+ "clearComments",
2045
+ "assign",
2046
+ "coerce",
2047
+ "cellMeta",
2048
+ "adjust",
2049
+ "trans",
2050
+ "delete",
2051
+ "edit"
2052
+ ]) "1" === t.getAttribute(o) && (e[o] = !0);
2053
+ return e;
2054
+ }
2055
+ _attachFutureMetadata(t, e) {
2056
+ const o = t.getAttribute("name") ?? "", s = e.get(o);
2057
+ if (!s) return;
2058
+ const r = t.childNodes;
2059
+ for (let t = 0; t < r.length; t++) {
2060
+ const e = r.item(t);
2061
+ 1 === e.nodeType && "bk" === e.localName && s._blocks.push(this._parseFutureBlock(e));
2062
+ }
2063
+ }
2064
+ _parseFutureBlock(t) {
2065
+ const e = {}, o = t.childNodes;
2066
+ for (let t = 0; t < o.length; t++) {
2067
+ const s = o.item(t);
2068
+ if (1 !== s.nodeType || "extLst" !== s.localName) continue;
2069
+ const r = s.childNodes;
2070
+ for (let t = 0; t < r.length; t++) {
2071
+ const o = r.item(t);
2072
+ if (1 !== o.nodeType || "ext" !== o.localName) continue;
2073
+ const s = o.childNodes;
2074
+ for (let t = 0; t < s.length; t++) {
2075
+ const o = s.item(t);
2076
+ 1 === o.nodeType && ("dynamicArrayProperties" === o.localName ? (e.fDynamic = "1" === o.getAttribute("fDynamic"), e.fCollapsed = "1" === o.getAttribute("fCollapsed")) : "rvb" === o.localName && (e.richValueIndex = Number(o.getAttribute("i") ?? "0")));
2077
+ }
2078
+ }
2079
+ }
2080
+ return e;
2081
+ }
2082
+ _resolveBlocks(t, e, o) {
2083
+ const s = t.childNodes;
2084
+ for (let t = 0; t < s.length; t++) {
2085
+ const r = s.item(t);
2086
+ 1 === r.nodeType && "bk" === r.localName && o.push(this._resolveBlock(r, e));
2087
+ }
2088
+ }
2089
+ _resolveBlock(t, e) {
2090
+ const o = /* @__PURE__ */ new Map(), s = t.childNodes;
2091
+ for (let t = 0; t < s.length; t++) {
2092
+ const r = s.item(t);
2093
+ if (1 !== r.nodeType || "rc" !== r.localName) continue;
2094
+ const i = Number(r.getAttribute("t")), n = Number(r.getAttribute("v")), l = e[i - 1];
2095
+ if (!l) continue;
2096
+ const { _blocks: a, ...c } = l, u = { ...c };
2097
+ for (const t of Object.keys(u)) void 0 === u[t] && delete u[t];
2098
+ const d = a[n];
2099
+ d && (void 0 !== d.fDynamic && (u.fDynamic = d.fDynamic, u.fCollapsed = d.fCollapsed ?? !1), void 0 !== d.richValueIndex && (u.richValueIndex = d.richValueIndex)), o.set(l.name, u);
2100
+ }
2101
+ return o;
2102
+ }
2103
+ },
2104
+ FeaturePropertyBagVisitor: class {
2105
+ visit(t, e, o) {
2106
+ const s = [], r = e.childNodes;
2107
+ for (let t = 0; t < r.length; t++) {
2108
+ const e = r.item(t);
2109
+ 1 === e.nodeType && "bag" === e.localName && s.push(this._readBag(e));
2110
+ }
2111
+ const i = [], n = s.find((t) => "XFComplements" === t.type)?.arrays.get("MappedFeaturePropertyBags") ?? [];
2112
+ for (let e = 0; e < n.length; e++) {
2113
+ const o = s[n[e]]?.ids.get("XFControls"), r = void 0 !== o ? s[o]?.ids.get("CellControl") : void 0, l = void 0 !== r ? s[r]?.type : void 0, a = l ? It[l] : void 0;
2114
+ a || t.warn(`A cell format's feature '${l ?? "unknown"}' is not read; its cells keep their values.`), i.push(a ? { type: a } : null);
2115
+ }
2116
+ const l = { controls: i };
2117
+ return o.featurePropertyBag = l, l;
2118
+ }
2119
+ _readBag(t) {
2120
+ const e = {
2121
+ type: t.getAttribute("type") ?? "",
2122
+ ids: /* @__PURE__ */ new Map(),
2123
+ arrays: /* @__PURE__ */ new Map()
2124
+ }, o = t.childNodes;
2125
+ for (let t = 0; t < o.length; t++) {
2126
+ const s = o.item(t);
2127
+ if (1 !== s.nodeType) continue;
2128
+ const r = s.getAttribute("k") ?? "";
2129
+ if ("bagId" === s.localName) {
2130
+ const t = parseInt(s.textContent ?? "", 10);
2131
+ isNaN(t) || e.ids.set(r, t);
2132
+ } else if ("a" === s.localName) {
2133
+ const t = [], o = s.childNodes;
2134
+ for (let e = 0; e < o.length; e++) {
2135
+ const s = o.item(e);
2136
+ if (1 !== s.nodeType || "bagId" !== s.localName) continue;
2137
+ const r = parseInt(s.textContent ?? "", 10);
2138
+ isNaN(r) || t.push(r);
2139
+ }
2140
+ e.arrays.set(r, t);
2141
+ }
2142
+ }
2143
+ return e;
2144
+ }
2145
+ },
2146
+ CommentsVisitor: class {
2147
+ visit(t, e, o) {
2148
+ if (!e) return;
2149
+ const s = [];
2150
+ this.processAuthors(t, t.evaluate("authors", e), s), s.length > 0 && (o.authors = s);
2151
+ const r = [];
2152
+ return o.comments = r, r;
2153
+ }
2154
+ processAuthors(t, e, o) {
2155
+ if (!e) return;
2156
+ const s = e.childNodes, r = s.length;
2157
+ for (let t = 0; t < r; t++) {
2158
+ const e = s.item(t);
2159
+ if (1 === e.nodeType && "author" === e.localName) {
2160
+ const t = e.firstChild;
2161
+ t && 3 === t.nodeType && o.push(t.textContent);
2162
+ }
2163
+ }
2164
+ }
2165
+ },
2166
+ CommentVisitor: class {
2167
+ visit(t, e, o) {
2168
+ if (!e) return;
2169
+ const s = e.getAttribute("ref");
2170
+ if (!s) return;
2171
+ const r = { content: "" };
2172
+ if (e.hasAttribute("authorId")) {
2173
+ const t = parseInt(e.getAttribute("authorId"), 10);
2174
+ isNaN(t) || (r.authorId = t);
2175
+ }
2176
+ return r.content = function(t) {
2177
+ if (!t) return "";
2178
+ const e = [];
2179
+ let o = !0;
2180
+ const s = t.childNodes;
2181
+ for (let t = 0; t < s.length; t++) {
2182
+ const r = s.item(t);
2183
+ if (1 === r.nodeType) {
2184
+ if ("t" === r.localName) e.push({ text: r.textContent ?? "" });
2185
+ else if ("r" === r.localName) {
2186
+ const t = { text: "" }, s = r.childNodes;
2187
+ for (let e = 0; e < s.length; e++) {
2188
+ const o = s.item(e);
2189
+ if (1 === o.nodeType) {
2190
+ if ("t" === o.localName) t.text += o.textContent ?? "";
2191
+ else if ("rPr" === o.localName) {
2192
+ const e = Vt(o);
2193
+ e && (t.font = e);
2194
+ }
2195
+ }
2196
+ }
2197
+ t.font && (o = !1), e.push(t);
2198
+ }
2199
+ }
2200
+ }
2201
+ return 0 === e.length ? t.textContent ?? "" : o ? e.map((t) => t.text).join("") : { runs: e };
2202
+ }(t.evaluate("text", e)), o.push({
2203
+ r: s,
2204
+ v: r
2205
+ }), r;
2206
+ }
2207
+ },
2208
+ ThreadedCommentsVisitor: class {
2209
+ visit(t, e, o) {
2210
+ if (!e) return;
2211
+ const s = [];
2212
+ return o.comments = s, s;
2213
+ }
2214
+ },
2215
+ ThreadedCommentVisitor: class {
2216
+ visit(t, e, o) {
2217
+ if (!e) return;
2218
+ const s = {};
2219
+ t.copyFromAttribute(e, "id", s, "id", I);
2220
+ const r = e.getAttribute("ref");
2221
+ t.copyFromAttribute(e, "personId", s, "personId", I), t.copyFromAttribute(e, "parentId", s, "parentId", I);
2222
+ const i = e.getAttribute("dT");
2223
+ i && (s.dt = function(t) {
2224
+ const e = /^(.*T\d{2}:\d{2}:\d{2})(?:\.(\d+))?(Z|[+-]\d{2}:?\d{2})?$/i.exec(t.trim());
2225
+ if (!e) return t;
2226
+ const [, o, s, r] = e;
2227
+ return `${o}${s ? `.${(s + "00").substring(0, 3)}` : ""}${r ?? "Z"}`;
2228
+ }(i)), e.hasAttribute("done") && (s.done = Q(e.getAttribute("done")));
2229
+ const n = function(t) {
2230
+ let e;
2231
+ const o = t.childNodes;
2232
+ for (let t = 0; t < o.length; t++) {
2233
+ const s = o.item(t);
2234
+ if (1 !== s.nodeType || "mentions" !== s.localName) continue;
2235
+ const r = s.childNodes;
2236
+ for (let t = 0; t < r.length; t++) {
2237
+ const o = r.item(t);
2238
+ if (1 !== o.nodeType || "mention" !== o.localName) continue;
2239
+ const s = o.getAttribute("mentionId"), i = o.getAttribute("mentionpersonId");
2240
+ if (!s || !i) continue;
2241
+ const n = {
2242
+ id: I(s),
2243
+ personId: I(i)
2244
+ }, l = parseInt(o.getAttribute("startIndex") ?? "", 10);
2245
+ isNaN(l) || (n.startIndex = l);
2246
+ const a = parseInt(o.getAttribute("length") ?? "", 10);
2247
+ isNaN(a) || (n.length = a), (e ??= []).push(n);
2248
+ }
2249
+ }
2250
+ return e;
2251
+ }(e);
2252
+ return n && (s.mentions = n), o.push({
2253
+ r,
2254
+ v: s
2255
+ }), s;
2256
+ }
2257
+ },
2258
+ PersonListVisitor: class {
2259
+ visit(t, e, o) {
2260
+ const s = [], r = e.childNodes, i = r.length;
2261
+ for (let e = 0; e < i; e++) {
2262
+ const o = r.item(e);
2263
+ if (1 === o.nodeType && "person" === o.localName) {
2264
+ const e = {};
2265
+ t.copyFromAttribute(o, "id", e, "id", I), t.copyFromAttribute(o, "displayName", e), t.copyFromAttribute(o, "userId", e, "userId", I), t.copyFromAttribute(o, "providerId", e), s.push(e);
2266
+ }
2267
+ }
2268
+ return s.length > 0 && (o.persons = s), s;
2269
+ }
2270
+ }
2271
+ }, Bt = class {
2272
+ constructor(t, e) {
2273
+ this.path = t, this.visitor = e;
2274
+ }
2275
+ }, Lt = class {
2276
+ constructor() {
2277
+ this.visitorsByXmlTagName = /* @__PURE__ */ new Map(), this.scopedVisitorsByXmlTagName = /* @__PURE__ */ new Map(), this.visitorParamsState = null, this.registerVisitor("Relationships", new _t.RelsVisitor()), this.registerVisitor("cp:coreProperties", new _t.CorePropertiesVisitor()), this.registerVisitor("Properties", new _t.AppPropertiesVisitor()), this.registerVisitor("spPr", new _t.ShapePropertiesVisitor()), this.registerVisitor("txBody", new _t.ShapeTextVisitor()), this.registerVisitor("txPr", new _t.TextPropertiesVisitor()), this.registerVisitor("a:theme", new _t.ThemeVisitor()), this.registerVisitor("a:theme", new _t.ClrSchemeVisitor(), "themeElements/clrScheme"), this.registerVisitor("a:theme", new _t.FontSchemeVisitor(), "themeElements/fontScheme"), this.registerVisitor("a:theme", new _t.FmtSchemeVisitor(), "themeElements/fmtScheme"), this.registerVisitor("a:theme", new _t.ObjectDefaultsVisitor(), "objectDefaults"), this.registerVisitor("autoFilter", new _t.AutoFilterVisitor()), this.registerVisitor("sortState", new _t.SortStateVisitor()), this.registerVisitor("s:workbook", new _t.WorkbookVisitor()), this.registerVisitor("styleSheet", new _t.SheetStyleVisitor()), this.registerVisitor("x14:table", new _t.TableX14Visitor()), this.registerVisitor("table", new _t.TableVisitor()), this.registerVisitor("externalLink", new _t.ExternalLinkVisitor()), this.registerVisitor("wsDr", new _t.DrawingVisitor()), this.registerVisitor("twoCellAnchor", new _t.DrawingAnchorVisitor()), this.registerVisitor("oneCellAnchor", new _t.DrawingAnchorVisitor()), this.registerVisitor("absoluteAnchor", new _t.DrawingAnchorVisitor()), this.registerVisitor("graphicFrame", new _t.DrawingGraphicFrameVisitor()), this.registerVisitor("sp", new _t.DrawingSpVisitor()), this.registerVisitor("grpSp", new _t.DrawingGrpSpVisitor()), this.registerVisitor("cxnSp", new _t.DrawingCxnSpVisitor()), this.registerVisitor("pic", new _t.DrawingPicVisitor()), this.registerVisitor("metadata", new _t.MetadataVisitor()), this.registerVisitor("FeaturePropertyBags", new _t.FeaturePropertyBagVisitor()), this.registerVisitor("comments", new _t.CommentsVisitor()), this.registerVisitor("comment", new _t.CommentVisitor()), this.registerVisitor("ThreadedComments", new _t.ThreadedCommentsVisitor()), this.registerVisitor("threadedComment", new _t.ThreadedCommentVisitor()), this.registerVisitor("threadedComment", new _t.TextPropertiesVisitor("content"), "text"), this.registerVisitor("personList", new _t.PersonListVisitor()), this.registerVisitor("slicerCacheDefinition", new _t.SlicerCacheDefinitionVisitor()), this.registerVisitor("slicers", new _t.SlicersVisitor()), this.registerVisitor("formControlPr", new _t.FormControlPrVisitor());
2278
+ }
2279
+ registerVisitor(t, e, o = null) {
2280
+ -1 === t.indexOf(":") && (t = "*:" + t);
2281
+ const s = t.split(":"), r = s.length > 1 ? s[1] : s[0];
2282
+ if (!o) return this.visitorsByXmlTagName.set(r, e), void this.visitorsByXmlTagName.set(t, e);
2283
+ let i = this.scopedVisitorsByXmlTagName.get(r);
2284
+ i || (i = [], this.scopedVisitorsByXmlTagName.set(r, i), this.scopedVisitorsByXmlTagName.set(t, i)), i.push(new Bt(o, e));
2285
+ }
2286
+ parseDxf(e, o = "", s = t.EmptyObject) {
2287
+ this.visitorParamsState || (this.visitorParamsState = /* @__PURE__ */ new Map());
2288
+ const r = this.visitorParamsState, i = r.get("processingDXFs");
2289
+ r.set("processingDXFs", !0);
2290
+ try {
2291
+ const t = new dt(null, this, "/dxf", e, {}, o, s), r = {};
2292
+ return new _t.SheetStyleVisitor().processDXF(t, e, r), r;
2293
+ } finally {
2294
+ void 0 === i ? r.delete("processingDXFs") : r.set("processingDXFs", i);
2295
+ }
2296
+ }
2297
+ getVisitorParamsState() {
2298
+ return this.visitorParamsState;
2299
+ }
2300
+ transform(e, o, s = t.EmptyObject) {
2301
+ const r = e.documentElement;
2302
+ this.visitorParamsState && !s?.paramMap || (this.visitorParamsState = s?.paramMap ?? /* @__PURE__ */ new Map());
2303
+ const i = {};
2304
+ let n = this.visitorsByXmlTagName.get(r.nodeName);
2305
+ if (n || (n = this.visitorsByXmlTagName.get(r.localName)), !n) throw new Error(`A visitor for the root element: '${r.nodeName}' or '${r.localName}' must be registered.`);
2306
+ const l = "/" + r.localName, a = new dt(null, this, l, r, i, o, s), c = [];
2307
+ this._doWalk(n, a, c, r, i, o, s);
2308
+ const u = c.length;
2309
+ for (let t = 0; t < u; t++) {
2310
+ const o = c[t];
2311
+ try {
2312
+ o.visitor?.afterVisit?.(o.context, o.elemParent, o.jsonParent);
2313
+ } catch (e) {
2314
+ o.context.warn(`Unable to finish reading '${o.context.getPath()}': ${e?.message ?? e}`, { onceKey: "xlsx.transform.afterVisit" });
2315
+ }
2316
+ }
2317
+ return i;
2318
+ }
2319
+ _walkScoped(t, e, o, s, r, i, n) {
2320
+ const l = this.scopedVisitorsByXmlTagName.get(t), a = l ? l.length : 0;
2321
+ for (let c = 0; c < a; c++) {
2322
+ const a = l[c];
2323
+ let u = null;
2324
+ try {
2325
+ u = e.evaluate(a.path, s);
2326
+ } catch (o) {
2327
+ e.warn(`Invalid path '${a.path}' for '${t}'.`, { onceKey: "xlsx.transform.invalidPath" });
2328
+ }
2329
+ if (!u) continue;
2330
+ const d = (t) => {
2331
+ let l = t.localName, c = t.parentNode;
2332
+ for (; c && c !== s;) l = c.localName + "/" + l, c = c.parentNode;
2333
+ const u = e.getPath() + "/" + l;
2334
+ if (a.visitor) {
2335
+ const s = new dt(e, this, u, e.getElemRoot(), e.getJsonRoot(), i, n);
2336
+ this._doWalk(a.visitor, s, o, t, r, i, n);
2337
+ }
2338
+ };
2339
+ if (u.length > 0) {
2340
+ const t = u, e = t.length;
2341
+ for (let o = 0; o < e; o++) d(t.item(o));
2342
+ } else d(u);
2343
+ }
2344
+ }
2345
+ _doWalk(t, e, o, s, r, i, n) {
2346
+ let l = null;
2347
+ t && (o.push({
2348
+ visitor: t,
2349
+ context: e,
2350
+ elemParent: s,
2351
+ jsonParent: r
2352
+ }), l = t.visit(e, s, r)), l || (l = r);
2353
+ const a = s.localName;
2354
+ this._walkScoped(a, e, o, s, l, i, n);
2355
+ const c = this.visitorsByXmlTagName, u = e.getElemRoot(), d = e.getJsonRoot(), h = s.childNodes, p = h.length;
2356
+ for (let t = 0; t < p; t++) {
2357
+ const s = h.item(t);
2358
+ if (1 !== s.nodeType) continue;
2359
+ const a = s;
2360
+ let p = a.nodeName, m = c.get(p);
2361
+ m || (p = a.localName, m = c.get(p));
2362
+ const f = e.getPath() + "/" + p, g = new dt(e, this, f, u, d, i, n);
2363
+ this._doWalk(m, g, o, a, l ?? r, i, n);
2364
+ }
2365
+ return l;
2366
+ }
2367
+ };
2368
+ export { Lt as DOMTransformer, dt as ExecutionContext, z as NumberUtils, C as VisitorUtils };