@sheetxl/studio-vanilla 0.6.12 → 0.6.13
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.
- package/browser/cjs/{4-Zslot8tjgvc7us.cjs → 85va2-St3DCDHPWi.cjs} +1 -1
- package/browser/cjs/{BCsNCdYPRZAraC8d.cjs → B83nqvOr_nMkM51I.cjs} +2 -2
- package/browser/cjs/{C8DarB4sLQFKkMdV.cjs → BA3DFG2nrzDKBzaP.cjs} +2 -2
- package/browser/cjs/{CTa1cghbdu13Meza.cjs → BCHCINYLsB92fUd2.cjs} +1 -1
- package/browser/cjs/{Boy3moLTpE7cpem5.cjs → BIUjmZ7HCNaQXoTG.cjs} +8 -8
- package/browser/cjs/{NtKPXFY8UW5S4av6.cjs → BIqfwHs636pnurrX.cjs} +3 -3
- package/browser/cjs/{DAQ2c_a0DiwtXSaS.cjs → BQVmSIuGfNsnFzf2.cjs} +1 -1
- package/browser/cjs/{B4FapNwAXbDFE8ft.cjs → BTxWGtgw_dE_0eih.cjs} +2 -2
- package/browser/cjs/{yh2Uf1xuszGzx-Kd.cjs → BbXgRYTl82jkiJaS.cjs} +1 -1
- package/browser/cjs/{C-yKdfqW8ivEjtXi.cjs → BeDR_qSmp_PLY_Ni.cjs} +2 -2
- package/browser/cjs/{BNitOAf-dpHk9FAH.cjs → BeNeF7OU6_ZUh22o.cjs} +1 -1
- package/browser/cjs/BrhEZihB-_ktU4T0.cjs +330 -0
- package/browser/cjs/{C_jL_h3BhzCBcoNT.cjs → ByCaPv9jy1xJhUpy.cjs} +3 -3
- package/browser/cjs/{CR-Z1D2-Uyz85QbN.cjs → C4EMf-yOeuX251Jh.cjs} +1 -1
- package/browser/cjs/{DBn_kVVpgYJXg1vG.cjs → C8AeV12HEQmDxrrQ.cjs} +2 -2
- package/browser/cjs/{BOqJU1qWO4s0kvRe.cjs → CALDtOfkcN6Jbojq.cjs} +1 -1
- package/browser/cjs/{Brrg7KQy-WJCm6FH.cjs → CBtS7k3EP9UtqHZA.cjs} +2 -2
- package/browser/cjs/{DL0V_BZDzrH833iW.cjs → CJ0SZF-8BpXpqHLG.cjs} +1 -1
- package/browser/cjs/{CJrBR6R7kDQkwzDV.cjs → CWlyoyrXvR3BE-jk.cjs} +5 -5
- package/browser/cjs/{njyeDxwePNCLYht0.cjs → CXScQ9sAbW2fVquw.cjs} +2 -2
- package/browser/cjs/{fE5gdtaj9xH9Txl_.cjs → CasVQHVmCabxIFHY.cjs} +1 -1
- package/browser/cjs/{C4ZH_yXSgUMDda3E.cjs → CgBJ4g6tv3H_R9Kq.cjs} +1 -1
- package/browser/cjs/{Jk8I-g8k-Te3mAuW.cjs → ChmjJCMH-Sj2mRSq.cjs} +4 -4
- package/browser/cjs/{R6J7xzanm7-0r18y.cjs → Cjs1mwoaLDl4U-id.cjs} +1 -1
- package/browser/cjs/{Da_WyXJxemYwJoAW.cjs → Cl4L7g73r_uCVljX.cjs} +4 -4
- package/browser/cjs/{DNf7isxHvn8kBRBA.cjs → Cqczoyf-mvCrVkOI.cjs} +2 -2
- package/browser/cjs/{JaamSR8t55rP4NaB.cjs → D7zeG4Dq9VVDwSCI.cjs} +1 -1
- package/browser/cjs/{COM0YKv6v1OA6y1u.cjs → DBKQY-gTKLMo6-YQ.cjs} +1 -1
- package/browser/cjs/{DFOzxzj-b_EbdLEa.cjs → DDuh_76jNqQi3oLw.cjs} +1 -1
- package/browser/cjs/{C2rXEJDkPPb_6bl6.cjs → DFT-gVNBVM8fGO8X.cjs} +1 -1
- package/browser/cjs/{DMwyLM5GUVT6L-l8.cjs → DGdTkgwo5VMpqkhB.cjs} +1 -1
- package/browser/cjs/{IRPvPzzAgVBXsrg2.cjs → DKGbGPckRJ9FAaOu.cjs} +2 -2
- package/browser/cjs/{DSkj4UimNvsCb_Bo.cjs → DMJdnLcsnQ4_pLhU.cjs} +1 -1
- package/browser/cjs/{Dy_s-ZN3iyVqDRnH.cjs → DPQzQo_cVgr2USBG.cjs} +2 -2
- package/browser/cjs/{CGxvgqdca6DE1Lhw.cjs → DQW4tBlpxAN0KXQU.cjs} +1 -1
- package/browser/cjs/{DI03QTzE-fMeS32m.cjs → DR3JN8rVWa74y02y.cjs} +2 -2
- package/browser/cjs/{DjuqFymLKIETWBUv.cjs → Ddtzu7c4EPXHIcj3.cjs} +4 -4
- package/browser/cjs/{CSvSCui528E6xP8g.cjs → DiVH7U1zQL9bIPWC.cjs} +2 -2
- package/browser/cjs/{CfwAF66WGeApcIV7.cjs → Dle9M9YwjxGPX_3i.cjs} +1 -1
- package/browser/cjs/{Dl9rBEBFEK4bojp4.cjs → Dm-KbyB99BvHX4Kj.cjs} +1 -1
- package/browser/cjs/{R9ax_8QNF98Y821b.cjs → DnDQwTAcMZ5GJY8Z.cjs} +1 -1
- package/browser/cjs/{Ch1_UvIWpbaN5rxX.cjs → DnZMQJu4QVG8s-fn.cjs} +1 -1
- package/browser/cjs/{OGrDjh4lYzIe6ZM5.cjs → DoeuZwPF0BW81fKT.cjs} +1 -1
- package/browser/cjs/{DZLWeYBtRacbnS2V.cjs → DqTSKOcPLPd5hE94.cjs} +1 -1
- package/browser/cjs/{Ck0O0hNjhD25TPwp.cjs → DyeaxRojXEDcJmNz.cjs} +1 -1
- package/browser/cjs/{CAVjIsXFeiRxV6Kv.cjs → FdX2120MW2CEXVRc.cjs} +1 -1
- package/browser/cjs/{BV960fH0vsNpcjBp.cjs → LtiL0iFw0m26ARIc.cjs} +1 -1
- package/browser/cjs/{BlpYyYvqFay95gtr.cjs → S9PRYtPVpUU_kcmv.cjs} +6 -6
- package/browser/cjs/{Bs5b-WL6BMU_-Wvd.cjs → _e73Vjd1NqFit8RL.cjs} +2 -2
- package/browser/cjs/{C_zWjLH_j3ePtsRH.cjs → avSPDYdtIZXU6BVy.cjs} +1 -1
- package/browser/cjs/{CMpa1fnuR2ziK7NB.cjs → bMuFKnmBsbIAepS_.cjs} +2 -2
- package/browser/cjs/{BXf4V8dISiSJ2_cG.cjs → cVZC0sIrdzPDxhdC.cjs} +2 -2
- package/browser/cjs/{XT4qtSqsj6Dg_5VI.cjs → eDrXkhn28xrKJ3ya.cjs} +1 -1
- package/browser/cjs/index.cjs +2 -2
- package/browser/cjs/{D0GbFTRW6O4tbElz.cjs → ki0IuetxD1LusOEq.cjs} +1 -1
- package/browser/cjs/{UY-uDUpWCfoqDJlO.cjs → r6vlBldZ16g1uolO.cjs} +3 -3
- package/browser/cjs/{DPBUOWQyRkPwMG0m.cjs → rKX_hwcSaby8h2iH.cjs} +1 -1
- package/browser/cjs/{DbL9vDnd3L7k8G-R.cjs → t_AXht1hkkuNmw2N.cjs} +1 -1
- package/browser/esm/{D-VISOh6uxM42YNT.mjs → 29Sn9qQkO4LVQQCN.mjs} +1 -1
- package/browser/esm/{B7rrClXu0eRVgFbS.mjs → 76VvrZLkHuvhAsGN.mjs} +1 -1
- package/browser/esm/{DRp6Z8JOgSVz5KVo.mjs → AR0xdN94FQwwXbn9.mjs} +1 -1
- package/{cdn/assets/BabjkJyBvfShpoga.js → browser/esm/B7ZM811lP5XYGPik.mjs} +1 -1
- package/browser/esm/{CA5x6U9yNu6x128O.mjs → BA3TCV9RT2qEC0xB.mjs} +13 -13
- package/{cdn/assets/C9rxHmaMq-L_x7pb.js → browser/esm/BADK5eZr5gw7iuRF.mjs} +1 -1
- package/browser/esm/{CGnn4gT6NK3Bw5pR.mjs → BQFzNGa2dsGEDk63.mjs} +2 -2
- package/browser/esm/{XJNikNOEymEAtfjl.mjs → BYv_u70XXEBkT_cs.mjs} +1 -1
- package/browser/esm/{Dhb1eEwqVInwjoyG.mjs → B_JqrBu4snd1mCAn.mjs} +2 -2
- package/{cdn/assets/Bl27rOq1mpdD4Yji.js → browser/esm/B_hYStAOL_dOzrHe.mjs} +1 -1
- package/{cdn/assets/C3lClRQOAni_quGG.js → browser/esm/BbPCzb3P6bAIX34V.mjs} +1 -1
- package/browser/esm/{B-Oz4I1r23gPcXtp.mjs → BoRdOfmhMnafZKpp.mjs} +1 -1
- package/browser/esm/{BSOz6BjHa-XOQdRs.mjs → Bp4gXO1YggYh_6K-.mjs} +1 -1
- package/browser/esm/{qxg4jdD-zZv0PRCg.mjs → BpTPfzuAljxFXK_W.mjs} +1 -1
- package/browser/esm/{DcIRNl6SaeKJrSc6.mjs → BzPlKUXEzPpB_g68.mjs} +2 -2
- package/browser/esm/{C-dhvN5nFYjOTtnf.mjs → Bzo80FZKYoESKlFb.mjs} +2 -2
- package/browser/esm/{B2bF9iG7UILgJ4LM.mjs → C-Ay0vwKnUkXnbuO.mjs} +1 -1
- package/browser/esm/{CuBFnYLmVuuQMiAZ.mjs → C9EHcO72-0BYtF6X.mjs} +2 -2
- package/browser/esm/{j44G4tJc6BIPMmb9.mjs → CFhOaUfgpajcEzT4.mjs} +4 -4
- package/browser/esm/{CXHUQUpCSKWXmmjX.mjs → CJAKxm3wwhG-as_J.mjs} +6 -6
- package/browser/esm/{9kLrv4iH3OnaZex5.mjs → CM4zwhrcqWhPALAe.mjs} +1 -1
- package/browser/esm/{B2oT-2hVpuF0xe5t.mjs → CRn4lFFQEAdHbc1M.mjs} +2 -2
- package/{cdn/assets/DBO3fKTIkE6M92Bg.js → browser/esm/CamJyaespLDx13Dh.mjs} +1 -1
- package/browser/esm/{5O4eIWNJ77z4TjwU.mjs → Cd6zSAicX966oPBT.mjs} +1 -1
- package/browser/esm/{DksxIsuBVNe7uoPS.mjs → CeyZOF9jknWRbv_d.mjs} +5 -5
- package/browser/esm/{CAr85I1oRSn-qxYa.mjs → CgnBjUP2KrJ1LNiX.mjs} +4 -4
- package/browser/esm/{CNXNYlU8Dqt2viBf.mjs → CiA5mkGar8N83Ic4.mjs} +2 -2
- package/{cdn/assets/ZR2RN4BOEE96xkBY.js → browser/esm/CiaDxCDY_EsZby9w.mjs} +1 -1
- package/{cdn/assets/CYJRyhAeTiNXpPLo.js → browser/esm/Cpi9GqXowtMM0FvH.mjs} +1 -1
- package/{cdn/assets/BX3gHGuDwz4BGqH0.js → browser/esm/CpvXecYYY7hudiEG.mjs} +1 -1
- package/browser/esm/{DfvlmDzGrrBDmpqY.mjs → Cs5vWhsVEbLA4gem.mjs} +1 -1
- package/{cdn/assets/DQ6pTYleameL7ZnI.js → browser/esm/CuXsvRqqdXfQP5EM.mjs} +2 -2
- package/browser/esm/{TLTkEOsOpx-SfUf4.mjs → CxqVBPbGSpS0kn2c.mjs} +2 -2
- package/browser/esm/{BRDTgAugVbh4e6kG.mjs → D2AuFfFnooIsiOnO.mjs} +8454 -8448
- package/browser/esm/{Gg-pPE_6Nsgkhl6j.mjs → D4JXMgZoY6e8jRBg.mjs} +1 -1
- package/browser/esm/{BiJaL5j4bBPGzMnc.mjs → D6w1YhRYKtvFB_So.mjs} +1 -1
- package/browser/esm/{BAnj7CWdaYauBEsE.mjs → D7QWyRlUXJflAC3a.mjs} +4 -4
- package/{cdn/assets/Npd571NhpOOtNve2.js → browser/esm/DBF1GJpLrjlM-6CC.mjs} +1 -1
- package/browser/esm/{DQGFC4U25ZdPl6i2.mjs → DEisLoDkr9m-vJ1h.mjs} +3 -3
- package/browser/esm/{DNwXrDJZgzDvQ7hV.mjs → DMa-cM-SjpZHaDfI.mjs} +1 -1
- package/browser/esm/{BDEjqZxtaMX_J8pu.mjs → DOCbzL6fsqN0Lj-4.mjs} +2 -2
- package/browser/esm/{Wp01wcnbYbu0n6rc.mjs → DSL1nO9X0e6fUT1o.mjs} +3 -3
- package/browser/esm/{6Xj_0tp5yFHA2fVh.mjs → DSxawwOgXGe57KpB.mjs} +1 -1
- package/browser/esm/{DntCxcF_3Few0z5K.mjs → DUhymiAI6BuvNbKJ.mjs} +10 -10
- package/browser/esm/{pVzsXwLrd5e4m33L.mjs → DXYOC-KhV5LdDmIY.mjs} +1 -1
- package/browser/esm/{BWA77V9GH3zUe8NP.mjs → D_WqqxbwbGDsSsCl.mjs} +1 -1
- package/browser/esm/{CYWJ0enPPDIfk7ov.mjs → Do7U-DkzG4JJUJe3.mjs} +1 -1
- package/{cdn/assets/CITvMm_Jp7v1uCHW.js → browser/esm/DuIvCvai3YZKxdLf.mjs} +1 -1
- package/browser/esm/{B4PjIaFGQ3Q4_Wlk.mjs → Dv4KM68IVqBp8HZ-.mjs} +1 -1
- package/browser/esm/{Dztc75Ftff64xaBA.mjs → DvUB0bNvINn6oYy_.mjs} +3 -3
- package/{cdn/assets/OnAC-8n9ixY--d3D.js → browser/esm/DwYLofBisLEysG7X.mjs} +36 -38
- package/browser/esm/{BigyDKW7Xug_6ElX.mjs → HTJovRKXdY2qgi_6.mjs} +1 -1
- package/browser/esm/{DXw2MUY2h3AeyOq1.mjs → NbEKj1EeT3TPECvv.mjs} +6 -6
- package/browser/esm/{Cc5jl2vdimKVy27f.mjs → PNvC5lw27NuD--Bq.mjs} +1 -1
- package/{cdn/assets/DKboJ05jC9VLIceA.js → browser/esm/SJ-UwheLV5pfR_jD.mjs} +3 -3
- package/browser/esm/{CvD92TtLywni95vu.mjs → gyJPHFTvBx6YCTMu.mjs} +8 -8
- package/browser/esm/index.mjs +2 -2
- package/{cdn/assets/BwT6PgiFTI1lZJnk.js → browser/esm/lSJ-6GsnTin_DAf-.mjs} +1 -1
- package/cdn/assets/{DKTEcMXrRxDkrir3.js → 25ums9tFCOUg3O2Q.js} +4 -4
- package/cdn/assets/{D-VISOh6uxM42YNT.js → 29Sn9qQkO4LVQQCN.js} +1 -1
- package/cdn/assets/{DYQveTPG7NR7YBdr.js → 36SzenckOtIq8sv4.js} +4 -4
- package/cdn/assets/{EpGdvM6bMgq82BXo.js → 3Jv-_TB7f6AMsi_b.js} +2 -2
- package/cdn/assets/{CQAECca1tqM9ZhJZ.js → 41F2zE-NjrEaRUct.js} +19 -19
- package/cdn/assets/{ZeZqdFUNRHKncGhU.js → 4nLfCXAlUUohbH0F.js} +20 -20
- package/cdn/assets/{B7rrClXu0eRVgFbS.js → 76VvrZLkHuvhAsGN.js} +1 -1
- package/cdn/assets/{DRp6Z8JOgSVz5KVo.js → AR0xdN94FQwwXbn9.js} +1 -1
- package/{browser/esm/BabjkJyBvfShpoga.mjs → cdn/assets/B7ZM811lP5XYGPik.js} +1 -1
- package/{browser/esm/C9rxHmaMq-L_x7pb.mjs → cdn/assets/BADK5eZr5gw7iuRF.js} +1 -1
- package/{browser/esm/evBaY41MlM7-q0bd.mjs → cdn/assets/BCgLmV2yUGlW6j0o.js} +2 -2
- package/cdn/assets/{Dq3Hgc9Lmm-1ayqr.js → BErZItp6yDnW8EoI.js} +1 -1
- package/{browser/esm/BZHxwifCKgkMgVWc.mjs → cdn/assets/BIaw6w__smOxTgrS.js} +33 -31
- package/cdn/assets/{BKPXInAd0xgvnL4x.js → BJeCYOWmWd7Tdt4z.js} +13 -13
- package/cdn/assets/{CQJXEyhsu_b5wZxs.js → BLGd08GlRgwYIO_Y.js} +3 -3
- package/cdn/assets/{Du-jQnBOwfUti9qS.js → BUMAQHiE6B8VcRBt.js} +3 -3
- package/cdn/assets/{XJNikNOEymEAtfjl.js → BYv_u70XXEBkT_cs.js} +1 -1
- package/{browser/esm/Bl27rOq1mpdD4Yji.mjs → cdn/assets/B_hYStAOL_dOzrHe.js} +1 -1
- package/{browser/esm/C3lClRQOAni_quGG.mjs → cdn/assets/BbPCzb3P6bAIX34V.js} +1 -1
- package/cdn/assets/{DEmdGe7U-ScNqm-T.js → BcZsnZ76Ig1BEjZI.js} +1 -1
- package/cdn/assets/{B-Oz4I1r23gPcXtp.js → BoRdOfmhMnafZKpp.js} +1 -1
- package/cdn/assets/{BSOz6BjHa-XOQdRs.js → Bp4gXO1YggYh_6K-.js} +1 -1
- package/cdn/assets/{qxg4jdD-zZv0PRCg.js → BpTPfzuAljxFXK_W.js} +1 -1
- package/cdn/assets/{B2bF9iG7UILgJ4LM.js → C-Ay0vwKnUkXnbuO.js} +1 -1
- package/cdn/assets/{Czz8tW5NIYeklMEl.js → CI3Q-_9QUjsWi4jv.js} +9 -9
- package/cdn/assets/{BaNoD-xiJQh3ZPmb.js → CJB8tfn11J6m2Clz.js} +8497 -8491
- package/cdn/assets/{9kLrv4iH3OnaZex5.js → CM4zwhrcqWhPALAe.js} +1 -1
- package/cdn/assets/{DkbiO2yzCX_MpLUM.js → CROWrWkGO9UZHTdk.js} +2 -2
- package/{browser/esm/DBO3fKTIkE6M92Bg.mjs → cdn/assets/CamJyaespLDx13Dh.js} +1 -1
- package/cdn/assets/{5O4eIWNJ77z4TjwU.js → Cd6zSAicX966oPBT.js} +1 -1
- package/cdn/assets/{B5TWIqveUshhY5R1.js → CeQD5RH8lpSuWO70.js} +2 -2
- package/{browser/esm/ZR2RN4BOEE96xkBY.mjs → cdn/assets/CiaDxCDY_EsZby9w.js} +1 -1
- package/cdn/assets/{OOEShXRM0SSzABgT.js → CoE8l1qq0IF7Mt-y.js} +2 -2
- package/cdn/assets/{Cv8DhxU4CydNjgYf.js → CoZhXKCBM0IPKnL_.js} +2 -2
- package/{browser/esm/CYJRyhAeTiNXpPLo.mjs → cdn/assets/Cpi9GqXowtMM0FvH.js} +1 -1
- package/cdn/assets/{DIey2xEJmI7O0YnZ.js → Cptaglf3icdDq0qQ.js} +3 -3
- package/{browser/esm/BX3gHGuDwz4BGqH0.mjs → cdn/assets/CpvXecYYY7hudiEG.js} +1 -1
- package/cdn/assets/{DfvlmDzGrrBDmpqY.js → Cs5vWhsVEbLA4gem.js} +1 -1
- package/{browser/esm/CODPPS0Z3-eGlIpk.mjs → cdn/assets/CuavCINiWUPmC7Vf.js} +3 -3
- package/cdn/assets/{KpqL_5GK5wD7HGlW.js → D01fmVK5D7_USTVV.js} +12 -12
- package/cdn/assets/{Gg-pPE_6Nsgkhl6j.js → D4JXMgZoY6e8jRBg.js} +1 -1
- package/cdn/assets/{fJPZ_Jd-HQOXASB4.js → D6UyN94iMzzzdb1j.js} +16 -16
- package/cdn/assets/{BiJaL5j4bBPGzMnc.js → D6w1YhRYKtvFB_So.js} +1 -1
- package/{browser/esm/Npd571NhpOOtNve2.mjs → cdn/assets/DBF1GJpLrjlM-6CC.js} +1 -1
- package/cdn/assets/{DQzcbKOoBbOJ0J0a.js → DH9hyBLBu3iKEDKB.js} +2 -2
- package/cdn/assets/{DNwXrDJZgzDvQ7hV.js → DMa-cM-SjpZHaDfI.js} +1 -1
- package/cdn/assets/{6Xj_0tp5yFHA2fVh.js → DSxawwOgXGe57KpB.js} +1 -1
- package/cdn/assets/{pVzsXwLrd5e4m33L.js → DXYOC-KhV5LdDmIY.js} +1 -1
- package/cdn/assets/{BWA77V9GH3zUe8NP.js → D_WqqxbwbGDsSsCl.js} +1 -1
- package/cdn/assets/{Dki3Tc8f5EEPSy2A.js → DlMTJf51lC636nM7.js} +4 -4
- package/{browser/esm/CITvMm_Jp7v1uCHW.mjs → cdn/assets/DuIvCvai3YZKxdLf.js} +1 -1
- package/cdn/assets/{B4PjIaFGQ3Q4_Wlk.js → Dv4KM68IVqBp8HZ-.js} +1 -1
- package/cdn/assets/{BigyDKW7Xug_6ElX.js → HTJovRKXdY2qgi_6.js} +1 -1
- package/cdn/assets/{aYMVmCGUoMrWBWdJ.js → P3tZrt0e9QaxIsSj.js} +3 -3
- package/cdn/assets/{Cc5jl2vdimKVy27f.js → PNvC5lw27NuD--Bq.js} +1 -1
- package/cdn/assets/{CIqXHw7AeHuTWFv1.js → dyXa5mldoVYOGp53.js} +2 -2
- package/cdn/assets/iGmpf_LzbJL2CsAa.js +22 -0
- package/cdn/assets/{CjsqTf4aAZsSOQ4J.js → kVuelG_XYHvC8tLV.js} +6 -6
- package/{browser/esm/BwT6PgiFTI1lZJnk.mjs → cdn/assets/lSJ-6GsnTin_DAf-.js} +1 -1
- package/cdn/assets/{BY0xpEYpsbIWoas1.js → r1CnkJ31QoXTp_nk.js} +4 -4
- package/cdn/assets/{CgURqXMk55k7LcUi.js → t-1W8YGdgV1JTqbk.js} +2 -2
- package/cdn/assets/{BF9myo60dkqcm4qq.js → tlI4qejEXDcDO0lI.js} +10 -10
- package/cdn/assets/{DdUOGC8VEXGTJMCr.js → wPWci8JgKtfKzAb-.js} +4 -4
- package/cdn/assets/{CoVV4Ol-kN87MzAH.js → wanybeV42m66cubX.js} +5 -5
- package/cdn/index.js +2 -2
- package/cdn/loader.js +1 -1
- package/package.json +3 -3
- package/browser/cjs/BjZIUujglND8Gflk.cjs +0 -330
- package/cdn/assets/CqBvDRcS9lQOZqd0.js +0 -22
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("./BjZIUujglND8Gflk.cjs"),g=require("./CJrBR6R7kDQkwzDV.cjs");class z{constructor(t){this.list=t}get length(){return this.list.length}item(t){return this.list[t]}forEach(t,e){for(let s=0;s<this.list.length;s++)t(this.list[s],s,this)}}const G=u=>u===!0||u==="1"||u==="on"||u==="true"||u!==!1&&u!=="0"&&u!=="off"&&u!=="false"&&null,X=u=>{const t=parseInt(u);return isNaN(t)?null:t},W=u=>{const t=parseFloat(u);return isNaN(t)?null:t},$=new Map;class V{constructor(t,e,s,r,o,i=null,n){const l=(c,h,d)=>n?.getRef?.(c,h,d,n?.parsedRefs),a=c=>n?.getRefs?.(c,n?.parsedRefs);this._parent=t,this.sharedShared=e,this.currentPath=s,this.elemRoot=r,this.jsonRoot=o,t?(this._fileLocation=t._fileLocation,this._getRef=t._getRef,this._getRefs=t._getRefs):(i&&(this._fileLocation=i),l&&a&&(this._getRef=l),a&&(this._getRefs=a),this._onWarning=n?.onWarning,this._addPerson=n?.addPerson)}getRef(t,e=!1){return this._getRef?.(t,this._fileLocation,e)??null}getRelationships(){return this._getRefs(this._fileLocation)??$}getPath(){return this.currentPath}getElemRoot(){return this.elemRoot}getJsonRoot(){return this.jsonRoot}warn(t){this._onWarning?this._onWarning(t):this._parent?this._parent?.warn?.(t):console.warn(t)}addPerson(t){return this._addPerson?this._addPerson(t):this._parent?this._parent?._addPerson?.(t):null}getVisitorParamsState(){return this.sharedShared.getVisitorParamsState()}evaluate(t,e){if(!t)return e;let s=[e];const r=t.split("/");for(let o=0;o<r.length;o++){const i=r[o];if(i===""||i===".")continue;let n=[];for(let l=0;l<s.length;l++){const a=s[l],c=a.childNodes;for(let h=0;c&&h<c.length;h++){const d=a.childNodes[h];d.localName!==i&&i!=="*"||n.push(d)}}s=n}return s.length===1?s[0]:s.length===0?null:new z(s)}getFromPath(t,e){return p.Xt.getFromPath(t,e)}setToPath(t,e,s){return p.Xt.setToPath(t,e,s)}getValAttrAsString(t,e){let s=this.evaluate(t,e);return s&&s.hasAttribute("val")?s.getAttribute("val")??null:null}getValAttrAsBoolean(t,e,s=!1){let r=this.evaluate(t,e);if(!r)return null;const o=r.hasAttribute("val")?r.getAttribute("val"):void 0;return o==null?s:o==="1"||o==="on"||o==="true"||o!=="0"&&o!=="off"&&o!=="false"&&s}getValAttrAsInteger(t,e){let s=this.evaluate(t,e);return s&&s.hasAttribute("val")?parseInt(s.getAttribute("val"))??null:null}getValAttrAsFloat(t,e){let s=this.evaluate(t,e);return s&&s.hasAttribute("val")?parseFloat(s.getAttribute("val"))??null:null}get BOOLEAN_COPY(){return G}get INT_COPY(){return X}get FLOAT_COPY(){return W}copyFromAttribute(t,e,s,r=e,o=null){if(!t||!s||!t.hasAttribute(e))return;let i=t.getAttribute(e);if(o){if(Array.isArray(o)){for(let n=0;n<o.length;n++)if(i==null||(i=o[n](i),i==null))return}else if(i==null||(i=o(i),i==null))return}this.setToPath(s,r,i)}}class S{constructor(t){this.jsonKey=t}visit(t,e,s){const r={};return s[this.jsonKey]=r,r}}class K{visit(t,e,s){if(!e)return;const r=e.childNodes;for(let o=0;o<r.length;o++){const i=r.item(o);i.nodeType===1&&i.localName==="Relationship"&&this.processRelationship(t,i,s)}return s}processRelationship(t,e,s){const r={};t.copyFromAttribute(e,"Target",r,"target"),t.copyFromAttribute(e,"Type",r,"type"),t.copyFromAttribute(e,"TargetMode",r,"targetMode"),s[e.getAttribute("Id")]=r}}const Y=(u,t)=>{if(u||!u.hasAttribute("rot"))return;const e=u.getAttribute("rot"),s=p.Xt.roundAccurately(g.p(e),2);s!==-1e3&&(t.rotation=s)},A=(u,t,e,s,r)=>{const o=u.getValAttrAsString(s,t);o!==null&&(e[r]=o)},f=(u,t,e,s,r=s,o=null)=>{const i=u.getValAttrAsBoolean(s,t,o);i!==null&&(e[r]=i)},C=(u,t,e,s,r)=>{const o=u.getValAttrAsInteger(s,t);o!==null&&(e[r]=o)},y=(u,t,e,s,r,o=1)=>{const i=u.getValAttrAsFloat(s,t);i!==null&&(e[r]=i*o)};class Z{visit(t,e,s){return f(t,e,s,"roundedCorners","roundedCorners"),C(t,e,s,".//AlternateContent/Fallback/style","styleId"),s.range=null,s}afterVisit(t,e,s){let r={};s.types=r;let o={},i=0,n={},l=0,a=t.getVisitorParamsState().get("axes");const c=t.getVisitorParamsState().get("types");for(let m=0;m<c.length;m++){const b=c[m];if(b.xAxisId){const v=b.xAxisId,P=a.get(v);o[m+""]=P,b.offsetXAxis=m,delete b.xAxisId,s.xAxes=o,o.length=++i}if(b.yAxisId){const v=b.yAxisId,P=a.get(v);n[m+""]=P,b.offsetYAxis=m,delete b.yAxisId,s.yAxes=n,n.length=++l}r[m+""]=b}r.length=c.length;const h=t.getVisitorParamsState().get("series");if(!h||h.length===0)return;const d={};s.series=d;for(let m=0;m<h.length;m++)d[m+""]=h[m];d.length=h.length}}class q{visit(t,e,s){return f(t,e,s,"plotVisOnly","plotVisOnly"),A(t,e,s,"dispBlanksAs","dispBlanksAs"),f(t,e,s,".//extLst/ext/dataDisplayOptions16/dispNaAsBlank","dispNaAsBlank"),f(t,e,s,"showDLblsOverMax","showDLblsOverMax"),s}afterVisit(t,e,s){try{const r=t.getValAttrAsBoolean("autoTitleDeleted",e),o=t.evaluate("title",e);t.setToPath(s,"title.shown",!(r===!0||!o));const i=t.evaluate("legend",e);t.setToPath(s,"legend.shown",i!==null)}catch(r){throw new Error("Unexpected Error parsing Chart: "+r)}}}class H{visit(t,e,s){let r={};return s.plotArea=r,r}}class O{EnumMappings(){}static fromOoxmlGradientType(t){return t==="circle"?"radial":t}static fromOoxmlLineCap(t){if(t==="rnd")return"round";if(t==="flat")return"butt";if(t==="sq")return"square";throw new Error("Invalid lineCap type: "+t)}static fromOoxmlCompound(t){return t==="sng"?"single":t}static fromOoxmlAlignment(t){return t==="ctr"?"center":t}}class D{visit(t,e,s){}processStroke(t,e,s){const r={},o=t.evaluate("ln",e);if(o){o.hasAttribute("algn")&&(r.align=O.fromOoxmlAlignment(o.getAttribute("algn"))),o.hasAttribute("cap")&&(r.lineCap=O.fromOoxmlLineCap(o.getAttribute("cap"))),o.hasAttribute("cmpd")&&(r.compound=O.fromOoxmlCompound(o.getAttribute("cmpd"))),o.hasAttribute("w")&&(r.width=g.t(o.getAttribute("w")));const i=t.evaluate("miter",o);i&&(r.lineJoin="miter",i.hasAttribute("lim")&&(r.miter=parseFloat(i.getAttribute("lim")))),t.evaluate("bevel",o)&&(r.lineJoin="bevel"),t.evaluate("round",o)&&(r.lineJoin="round");const n=t.evaluate("custDash",o);if(n){const c=t.evaluate("ds",n);if(c&&c.length>0){let h="";for(let d=0;d<c.length;d++){const m=c.item(d);h+=g.a(m.getAttribute("d"))+","+g.a(m.getAttribute("sp"))}r.dash=h}}const l=t.evaluate("prstDash",o);l&&l.hasAttribute("val")&&(r.dash=l.getAttribute("val")),this.parseEndElement(t,o,r,"headEnd","head"),this.parseEndElement(t,o,r,"tailEnd","tail");const a=this.processFill(t,o,s);r.fill=a}return r}parseEndElement(t,e,s,r,o){const i=t.evaluate(r,e);if(i&&(i.hasAttribute("type")&&(s[o+"Type"]=i.getAttribute("type")),i.hasAttribute("len")||i.hasAttribute("w"))){const n=i.getAttribute("len")?i.getAttribute("len"):"med",l=i.getAttribute("w")?i.getAttribute("w"):"med";s[o+"Size"]=n+"-"+l}}processFill(t,e,s){const r={};if(t.evaluate("noFill",e))return r.none=!0,r;const o=t.evaluate("solidFill",e);if(o){const a=this.processAdjColor(t,o);return a&&(r.solid=a),r}const i=t.evaluate("gradFill",e);if(i){i.hasAttribute("rotWithShape")&&(r.isRotated=i.getAttribute("rotWithShape")==="1");const a=this.processGradFill(t,i);return r.gradient=a,r}const n=t.evaluate("pattFill",e);if(n){const a=this.processPatternFill(t,n);return r.pattern=a,r}const l=t.evaluate("blipFill",e);if(l){l.hasAttribute("rotWithShape")&&(r.isRotated=g.b(l.getAttribute("rotWithShape"))),l.hasAttribute("dpi")&&(r.dpi=l.getAttribute("dpi"));const a=this.processImageFill(t,l);return r.image=a,r}return r.none=!0,r}processGradFill(t,e){const s={},r=t.evaluate("lin",e);if(r){if(s.type="linear",r.hasAttribute("ang")){const c=g.p(r.getAttribute("ang"));s.angle=c}if(r.hasAttribute("scaled")){const c=g.b(r.getAttribute("scaled"));s.scaled=c}}const o={};e.hasAttribute("flip")&&(o.mirror=e.getAttribute("flip")),Object.keys(o).length>0&&(s.tile=o);const i=t.evaluate("path",e);if(i){i.hasAttribute("path")&&(s.type=O.fromOoxmlGradientType(i.getAttribute("path")));const c=t.evaluate("fillToRect",i);c&&(s.fillTo=this.getRect(c))}const n=t.evaluate("tileRect",e);n&&(s.tile.bounds=this.getRect(n));const l=[],a=t.evaluate("gsLst/gs",e);for(let c=0;a&&c<a.length;c++){const h=a.item(c),d={offset:g.a(h.getAttribute("pos")),color:this.processAdjColor(t,h)};l.push(d)}return l.length>0&&(s.stops=l),s}getRect(t){const e={};return t.hasAttribute("t")&&(e.t=g.a(t.getAttribute("t"))),t.hasAttribute("l")&&(e.l=g.a(t.getAttribute("l"))),t.hasAttribute("b")&&(e.b=g.a(t.getAttribute("b"))),t.hasAttribute("r")&&(e.r=g.a(t.getAttribute("r"))),Object.keys(e).length===0?null:e}processImageFill(t,e){return{ref:"https://www.sheetxl.com/logo-color-padded-white.jpg",tile:!1}}processPatternFill(t,e){const s={},r=e.getAttribute("prst");s.type=r;const o=t.evaluate("bgClr",e);if(o){const n=this.processAdjColor(t,o);n&&(s.background=n)}const i=t.evaluate("fgClr",e);if(i){let n=this.processAdjColor(t,i);n&&(s.foreground=n)}return s}processAdjColor(t,e){const s=t.evaluate("hslClr",e);if(s)return this.processHslClr(t,s);const r=t.evaluate("prstClr",e);if(r)return this.processClrWithValAttribute(t,r);const o=t.evaluate("schemeClr",e);if(o)return this.processClrWithValAttribute(t,o);const i=t.evaluate("sysClr",e);if(i)return this.processClrWithValAttribute(t,i);const n=t.evaluate("scrgbClr",e);if(n)return this.processScrgbClrElement(t,n);const l=t.evaluate("srgbClr",e);return l?this.processSrgbClrElement(t,l):null}processScrgbClrElement(t,e){let s="lrgba("+g.a(e.getAttribute("r"))+","+g.a(e.getAttribute("g"))+","+g.a(e.getAttribute("b"))+")";return s+=this.processAdjustments(t,e),s}processSrgbClrElement(t,e){let s=e.getAttribute("val");return s+=this.processAdjustments(t,e),s}processHslClr(t,e){let s="hsl("+g.p(e.getAttribute("hue"))+","+g.a(e.getAttribute("sat"))+","+g.a(e.getAttribute("lum"))+")";return s+=this.processAdjustments(t,e),s}processClrWithValAttribute(t,e){const s=e.getAttribute("val");if(!s)return;let r=s;return r+=this.processAdjustments(t,e),r}processAdjustments(t,e){let s="";const r=e.childNodes;for(let o=0;o<r.length;o++){const i=r.item(o);if(i.nodeType===1){let n=i.localName;s+=n==="hue"||n==="hueOff"||n==="hueMod"?this.processAdjustmentElement(t,e,n,6e4):n==="gray"||n==="comp"||n==="inv"||n==="gamma"||n==="invGamma"?this.processAdjustmentElement(t,e,n,1):this.processAdjustmentElement(t,e,n)}}return s}processAdjustmentElement(t,e,s,r=1e3){const o=t.evaluate(s,e);if(!o)return"";const i=o.getAttribute("val");return i?` ${s} ${!i||parseFloat(i)/r}`:` ${s}`}}class L extends D{visit(t,e,s){try{const r=t.evaluate("xfrm",e);if(r){Y(r,s);const l={x:0,y:0,width:0,height:0},a=t.evaluate("off",r);a&&(l.x=g.c(a.getAttribute("x"))??0,l.y=g.c(a.getAttribute("y"))??0);const c=t.evaluate("ext",r);a&&(l.width=g.c(c.getAttribute("cx"))??0,l.height=g.c(c.getAttribute("cy"))??0),s.bounds=l}const o=t.evaluate("prstGeom",e);o?.hasAttribute("prst")?s.geometry=o?.getAttribute("prst"):t.evaluate("customGeom",e)&&console.warn("customGeom not supported yet");const i=this.processFill(t,e,s);i&&Object.keys(i).length>0&&(s.fill=i);const n=this.processStroke(t,e,s);return n&&Object.keys(n).length>0&&(s.stroke=n),s}catch(r){throw console.warn(r),new Error("Unexpected Error parsing Shape Properties element")}}}class N{visit(t,e,s){let r={};if(A(t,e,r,"grouping","grouping"),f(t,e,r,"varyColors","varyColors"),y(t,e,r,"gapWidth","gapWidth",.01),y(t,e,r,"overlap","overlap",.01),this.parseType(t,e,r),C(t,e,r,"bubbleScale","bubbleScale"),f(t,e,r,"showNegBubbles","showNegativeBubbleValues"),f(t,e,r,"sizeRepresents","bubbleSizeRepresentsWidth"),C(t,e,r,"firstSliceAng","startAngle"),C(t,e,r,"holeSize","holeSize"),A(t,e,r,"scatterStyle","scatterStyle"),this.parseAxisIds(t,e,r),Object.keys(r).length>0){let o=t.getVisitorParamsState().get("types");o||(o=[],t.getVisitorParamsState().set("types",o)),o.push(r)}return r}parseType(t,e,s){switch(e.localName){case"areaChart":s.type="area";break;case"bubbleChart":s.type="bubble";break;case"doughnutChart":case"ofPieType":case"pieChart":s.type="pie";break;case"lineChart":s.type="line";break;case"scatterChart":s.type="scatter"}}parseAxisIds(t,e,s){const r=t.evaluate("axId",e);if(!r||r.length===0)return;const o=r.item(0).getAttribute("val");s.xAxisId=o;const i=r.item(1).getAttribute("val");s.yAxisId=i}}class J extends N{parseType(t,e,s){const r=t.getValAttrAsString("barDir",e);r&&(s.type=r==="col"?"column":"bar")}}class w{constructor(t){this.jsonKey=t}visit(t,e,s){let r={},o=r,i=t.getValAttrAsString("idx",e);i!==null&&(o={},o[i]=r);const n=t.getValAttrAsBoolean("delete",e);this.parseNumFormat(t,e,r),n===!0?(r.showBubbleSize=!1,r.showCatName=!1,r.showLeaderLines=!1,r.showPercentage=!1,r.showSerName=!1,r.showVal=!1,r.showLegendKey=!1):(f(t,e,r,"showBubbleSize","showBubbleSize"),f(t,e,r,"showCatName","showCatName"),f(t,e,r,"showLeaderLines","showLeaderLines"),f(t,e,r,"showPercent","showPercentage"),f(t,e,r,"showSerName","showSerName"),f(t,e,r,"showVal","showVal"),f(t,e,r,"showLegendKey","showLegendKey"));const l=t.evaluate("separator",e);return l!==null&&(r.separator=l.textContent),A(t,e,r,"dLblPos","position"),s[this.jsonKey]=o,r}parseNumFormat(t,e,s){const r=t.evaluate("numFmt",e);if(r){const o=r.getAttribute("formatCode");s.formatCode=o,r.hasAttribute("sourceLinked")&&(s.sourceLinked=r.getAttribute("sourceLinked")==="1")}}}const M=(u,t,e)=>{if(u.getValAttrAsBoolean("invertIfNegative",t)===!0)if(u.evaluate("extLst/ext/invertSolidFillFmt",t)){if(e.fill&&e.fillNegative){const s=u.getFromPath(e,"fill.solid.adjs");s&&u.setToPath(e,"fillNegative.solid.adjs",s)}}else{const s={val:"FFFFFF"},r={};r.solid=s,e.fillNegative=r;const o={val:"000000"},i={};i.solid=o;const n={};n.fill=i,e.strokeNegative=n}};class Q{visit(t,e,s){const r={};C(t,e,r,"explosion","explosion");let o=t.evaluate("cat/*/f",e);o||(o=t.evaluate("xVal/*/f",e));let i=null;o!==null&&o.firstChild!==null&&(i=o.firstChild.nodeValue),o||(o=t.evaluate("cat/strLit",e),o||(o=t.evaluate("cat/numLit",e)),o&&(i=this.parsePointsAsString(t,o))),i!==null&&(r.xRange=i);let n=t.evaluate("val/*/f",e);n||(n=t.evaluate("yVal/*/f",e));let l=null;n&&n.firstChild&&(l=n.firstChild.nodeValue),n||(n=t.evaluate("val/numLit",e),n!==null&&(l=this.parsePointsAsString(t,n))),l!==null&&(r.valRange=l),this.parseTitleRangeOrValue(t,e,r),C(t,e,r,"idx","idx"),f(t,e,r,"smooth","smooth");const a=t.getVisitorParamsState().get("types").length-1;r.offsetChart=a;let c=t.getVisitorParamsState().get("series");return c||(c=[],t.getVisitorParamsState().set("series",c)),c.push(r),r}parseTitleRangeOrValue(t,e,s){const r=t.evaluate("tx/strRef/f",e);if(r!==null){const o=r.firstChild.nodeValue;t.setToPath(s,"title.range",o)}else{const o=t.evaluate("tx/v",e);o!==null&&t.setToPath(s,"title.text.simpleRun",o.firstChild.nodeValue)}}parsePointsAsString(t,e){let s="{";const r=t.getValAttrAsInteger("ptCount",e),o=t.evaluate("pt",e),i=[];for(let n=0;o&&r&&n<r;n++){let l=null,a=t.evaluate("pt[@idx='"+n+"']/v",e);a instanceof Node&&(l=a.textContent),i[n]=l}for(let n=0;n<i.length;n++)n>0&&(s+=","),i[n]!==void 0&&(s+=i[n]);return s+="}",s}afterVisit(t,e,s){M(t,e,s);let r=t.getFromPath(s,"points");if(r){const o=Object.keys(r);for(let i=0;i<o.length;i++){const n=o[i],l=t.getFromPath(r,n);if(!l)continue;let a=t.getFromPath(l,"markers");a&&(t.setToPath(s,"markers.points."+n,a),delete l.markers)}}}}class tt{DataPointVisitor(){}visit(t,e,s){let r=t.getFromPath(s,"points"),o=null;r?o=r:(o={},t.setToPath(s,"points",o));let i={},n=t.getValAttrAsString("idx",e);return n!==null&&(o[n]=i),f(t,e,i,"bubble3D","bubble3D"),C(t,e,i,"explosion","explosion"),M(t,e,i),i}}class et{visit(t,e,s){const r=e.parentNode.localName;if(r==="ser"||r==="dPt"){const o={},i=t.getValAttrAsString("size",e);i!==null&&(o.size=i);const n=t.getValAttrAsString("symbol",e);return n&&(o.type=n),s.markers=o,o}return null}}class k{visit(t,e,s){let r={};this.parseScaling(t,e,r),y(t,e,r,"majorUnit","majorUnits"),y(t,e,r,"minorUnit","minorUnits"),f(t,e,r,"delete","shown"),this.parseOrientation(t,e,r),this.parseNumFormat(t,e,r),A(t,e,r,"majorTickMark","majorTickMarks"),A(t,e,r,"minorTickMark","minorTickMarks"),A(t,e,r,"crosses","crosses"),y(t,e,r,"crossesAt","crosses"),A(t,e,r,"crossBetween","crossBetween"),this.parseLabelAlign(t,e,r),C(t,e,r,"lblOffset","labelOffset"),A(t,e,r,"tickLblPos","labelPosition");const o=t.getValAttrAsInteger("noMultiLvlLbl",e);r.labelMultiLevel=o!==null&&o===0,C(t,e,r,"tickMarkSkip","tickMarkSkip"),C(t,e,r,"tickLblSkip","labelInterval"),this.parseDisplayCustOrBuiltInUnit(e,t,r),this.parseTimeUnits(t,e,r,"majorUnitDates","majorTimeUnit","majorUnit"),this.parseTimeUnits(t,e,r,"minorUnitDates","minorTimeUnit","minorUnit"),A(t,e,r,"baseTimeUnit","baseUnitDates"),t.getVisitorParamsState().get("axes")||t.getVisitorParamsState().set("axes",new Map);const i=t.getValAttrAsString("axId",e);return t.getVisitorParamsState().get("axes").set(i,r),r}parseTimeUnits(t,e,s,r,o,i){const n={};let l=t.getValAttrAsString(o,e);if(l!==null){n.dem=l;let a=t.getValAttrAsString(i,e);n.amt=a}Object.keys(n).length>0&&(s[r]=n)}parseDisplayCustOrBuiltInUnit(t,e,s){let r=e.getValAttrAsString("dispUnits/builtInUnit",t);r||(r=e.getValAttrAsString("dispUnits/custUnit",t)),r&&(s.displayUnits=r)}parseLabelAlign(t,e,s){let r=t.getValAttrAsString("lblAlgn",e);r!==null&&(r==="ctr"?s.labelAlign="center":r==="l"?s.labelAlign="left":r==="r"&&(s.labelAlign="right"))}parseOrientation(t,e,s){const r=t.getValAttrAsString("AxPos",e);r!==null&&(r==="b"?s.orientation="bottom":r==="l"?s.orientation="left":r==="r"?s.orientation="right":r==="t"&&(s.orientation="top"))}parseNumFormat(t,e,s){const r={},o=t.evaluate("numFmt",e);o!==null&&(o.hasAttribute("formatCode")&&(r.formatCode=o.getAttribute("formatCode")),o.hasAttribute("sourceLinked")&&(r.sourceLinked=o.getAttribute("sourceLinked")==="1")),Object.keys(r).length>0&&(s.labels=r)}parseScaling(t,e,s){const r=t.getValAttrAsString("scaling/orientation",e);r!==null&&(s.inverted=r!=="minMax");const o=t.getValAttrAsFloat("scaling/logBase",e);o!==null&&(s.logBase=o,s.scaleType="log"),y(t,e,s,"scaling/max","max"),y(t,e,s,"scaling/min","min")}afterVisit(t,e,s){s.fill&&s.labels&&(s.labels.fill=s.fill,delete s.fill);let r=t.getValAttrAsBoolean("delete",e);r!==null&&(t.setToPath(s,"labels.shown",r!==!0),t.setToPath(s,"shown",r!==!0));const o=t.getFromPath(s,"dispUnits.displayUnitsLabel");o&&(t.setToPath(s,"displayUnitsLabel",o),delete s.dispUnits);const i=t.evaluate("title",e);t.setToPath(s,"title.shown",i!==null);const n=t.evaluate("minorGridlines",e);t.setToPath(s,"gridLinesMinor.shown",n!==null);const l=t.evaluate("majorGridlines",e);t.setToPath(s,"gridLinesMajor.shown",l!==null)}}class F{constructor(t="text"){this._jsonKey=t}getTextPath(){return this._jsonKey}visit(t,e,s){let r=t.getFromPath(s,this.getTextPath());return r||(r={}),this.parseTextElement(t,e,r,!1),Object.keys(r).length>0&&t.setToPath(s,this.getTextPath(),r),s}parseTextElement(t,e,s,r){const o=t.evaluate("p/pPr/defRPr",e)??t.evaluate("defRPr",e);o&&(this.parseTextProperties(t,o,s),new L().visit(t,o,s));let i=[],n=t.evaluate("p/r",e)??t.evaluate("r",e);const l=c=>{const h={};let d=t.evaluate("t",c);const m=t.evaluate("rPr",c);m&&this.parseTextProperties(t,m,h),d?h.text=d.firstChild.textContent??"":c.textContent&&(h.text=c.textContent??""),i.push(h)};if(n?.length!==void 0)for(let c=0;n&&c<n.length;c++)l(n.item(c));else l(n||e);i.length>0&&(s.runs=i);const a=t.evaluate("bodyPr",e);a&&Y(a,s)}parseTextProperties(t,e,s){if(!e)return;e.hasAttribute("sz")&&(s.size=parseFloat(e.getAttribute("sz"))/100),e.hasAttribute("b")&&(s.weight=e.getAttribute("b")==="1"?700:400),e.hasAttribute("i")&&(s.italic=e.getAttribute("i")==="1"),e.hasAttribute("u")&&(s.underline=e.getAttribute("u")),e.hasAttribute("strike")&&(s.strike=e.getAttribute("strike"));const r=t.evaluate("latin",e);if(r&&!r.getAttribute("typeface").startsWith("+")){const o=s.font??{};if(r.hasAttribute("typeface")&&(o.family=r.getAttribute("typeface")),r.hasAttribute("panose")){const i=r.getAttribute("panose");i&&(o.fallbacks=[p.ne.getPanoseFallback(i)])}r.hasAttribute("pitchFamily")&&(o.pitch=r.getAttribute("pitchFamily")),r.hasAttribute("charset")&&(o.charset=r.getAttribute("charset")),Object.keys(o).length>0&&(s.font=o)}}}class rt{visit(t,e,s){let r=t.getVisitorParamsState().get("series")[t.getValAttrAsInteger("idx",e)];if(r){let o=t.getFromPath(r,"title");o||(o={},t.setToPath(r,"title",o));let i=o,n=t.getValAttrAsBoolean("delete",e);return n!==null&&(i.shown=!n),i}return s}}class st{visit(t,e,s){const r={};return f(t,e,r,"overlay","overlay"),A(t,e,r,"legendPos","position"),s.legend=r,r}}class ot extends L{visit(t,e,s){const r=this.processFill(t,e,s);Object.keys(r).length>0&&(s.fillNegative=r);const o=this.processStroke(t,e,s);return Object.keys(o).length>0&&(s.strokeNegative=o),s}}class _ extends F{constructor(t="title"){super(t)}parseTitleRangeOrValue(t,e,s){let r=t.evaluate("tx/strRef/f",e)??null;if(r){const o=r.firstElementChild.nodeValue;t.setToPath(s,"range",o)}}visit(t,e,s){const r={};f(t,e,r,"overlay","overlay"),s[this._jsonKey]=r;let o=t.getFromPath(r,this.getTextPath());o||(o={}),this.parseTitleRangeOrValue(t,e,r);const i=t.evaluate("txPr",e);i&&this.parseTextElement(t,i,o,!1);const n=t.evaluate("tx/rich",e);return n&&this.parseTextElement(t,n,o,!0),Object.keys(o).length>0&&t.setToPath(r,this.getTextPath(),o),r}afterVisit(t,e,s){if(s?.text){const r=s.text?.rotation??null;r!==null&&(s.rotation=parseInt(r),delete s.title.rotation)}}}class it{visit(t,e,s){const r=t.evaluate("manualLayout",e);if(r){let o={};y(t,r,o,"x","x"),y(t,r,o,"y","y"),y(t,r,o,"w","w"),y(t,r,o,"h","h"),A(t,r,o,"xMode","xMode"),A(t,r,o,"yMode","yMode"),A(t,r,o,"wMode","wMode"),A(t,r,o,"hMode","hMode"),Object.keys(o).length>0&&(s.manualLayout=o)}return s}}class nt{visit(t,e,s){return s.name=e.getAttribute("name"),s}}class lt extends D{visit(t,e,s){const r={};r.name=e.getAttribute("name");const o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1){let l=n.localName;const a=t.evaluate(l,e),c=this.processAdjColor(t,a);r[l]=c}}return Object.keys(r).length>0&&(s.colors=r),r}}class at{visit(t,e,s){const r={};r.name=e.getAttribute("name");const o=t.evaluate("majorFont",e),i=this.processFontElement(t,o,{});r.majorFont=i.family,i.fallbacks&&(r.majorFallbacks=i.fallbacks);const n=t.evaluate("minorFont",e),l=this.processFontElement(t,n,{});return r.minorFont=l.family,i.fallbacks&&(r.minorFallbacks=l.fallbacks),s.fonts=r,r}processFontElement(t,e,s){if(!e)return;const r=t.evaluate("latin",e);if(!r)return;const o=r.getAttribute("typeface");o&&(s.family=o);const i=r.getAttribute("panose");return i&&(s.fallbacks=[p.ne.getPanoseFallback(i)]),s}}class ct{visit(t,e,s){if(!e)return;const r={},o=e.getAttribute("r:id");if(o){const i=t.getRef(o);typeof i=="string"&&(r.address=i)}return t.copyFromAttribute(e,"tooltip",r),t.copyFromAttribute(e,"history",r,"history",t.BOOLEAN_COPY),t.copyFromAttribute(e,"tgtFrame",r,"target"),s.hyperlink=r,r}}class ut{visit(t,e,s){if(!e)return;const r={};return t.copyFromAttribute(e,"ref",r),this.processFilterColumns(t,e,r),Object.keys(r).length>0&&(s.filter=r),r}processColorFilter(t,e){const s={type:p.uu.Type.Color};return t.copyFromAttribute(e,"cellColor",s,"cellColor",t.BOOLEAN_COPY),t.copyFromAttribute(e,"dxfId",s,"styleId",t.INT_COPY),s}processCustomFilter(t,e){const s={};return t.copyFromAttribute(e,"operator",s,"operator",t.BOOLEAN_COPY),t.copyFromAttribute(e,"val",s,"val"),s}processCustomFilters(t,e){const s={type:p.uu.Type.Custom};t.copyFromAttribute(e,"and",s,"and",t.BOOLEAN_COPY);const r=e.childNodes;s.filters=[];for(let o=0;o<r.length;o++){const i=r.item(o);if(i.nodeType!==1)continue;let n=null;i.localName==="customFilter"&&(n=this.processCustomFilter(t,i)),n&&s.filters.push(n)}return s}processDynamicFilter(t,e){const s={type:p.uu.Type.Dynamic};return t.copyFromAttribute(e,"type",s,"dynamicType"),t.copyFromAttribute(e,"val",s,"val",t.INT_COPY),t.copyFromAttribute(e,"maxVal",s,"maxVal",t.INT_COPY),s}processDateGroupItem(t,e){const s={};return t.copyFromAttribute(e,"dateTimeGrouping",s,"group"),t.copyFromAttribute(e,"day",s,"day",t.INT_COPY),t.copyFromAttribute(e,"hour",s,"hour",t.INT_COPY),t.copyFromAttribute(e,"minute",s,"minute",t.INT_COPY),t.copyFromAttribute(e,"month",s,"month",t.INT_COPY),t.copyFromAttribute(e,"second",s,"second",t.INT_COPY),t.copyFromAttribute(e,"year",s,"year",t.INT_COPY),s}processFilterItem(t,e){if(e.hasAttribute("val"))return e.getAttribute("val")}processFilters(t,e){const s={type:p.uu.Type.Items};t.copyFromAttribute(e,"blank",s,"blank",t.BOOLEAN_COPY),t.copyFromAttribute(e,"calendarType",s,"calendarType");let r=[],o=[];const i=e.childNodes;for(let n=0;n<i.length;n++){const l=i.item(n);if(l.nodeType===1){if(l.localName==="dateGroupItem"){const a=this.processDateGroupItem(t,l);a&&r.push(a)}else if(l.localName==="filter"){const a=this.processFilterItem(t,l);a!==void 0&&o.push(a)}}}return r.length>0&&(s.dateGroups=r),o.length>0&&(s.items=o),s}processIcon(t,e){const s={type:p.uu.Type.Icon};return t.copyFromAttribute(e,"iconId",s,"iconId",t.INT_COPY),t.copyFromAttribute(e,"iconSet",s),s}processTop10(t,e){const s={type:p.uu.Type.Top10};return t.copyFromAttribute(e,"filterVal",s,"filterVal",t.FLOAT_COPY),t.copyFromAttribute(e,"percent",s,"percent",t.BOOLEAN_COPY),t.copyFromAttribute(e,"top",s,"top",t.BOOLEAN_COPY),t.copyFromAttribute(e,"val",s,"val",t.FLOAT_COPY),s}processFilterCriteria(t,e,s){if(!e)return;const r=e.childNodes,o=[];for(let i=0;i<r.length;i++){const n=r.item(i);if(n.nodeType!==1)continue;let l=null;n.localName==="colorFilter"?l=this.processColorFilter(t,n):n.localName==="customFilters"?l=this.processCustomFilters(t,n):n.localName==="dynamicFilter"?l=this.processDynamicFilter(t,n):n.localName==="filters"?l=this.processFilters(t,n):n.localName==="iconFilter"?l=this.processIcon(t,n):n.localName==="top10"&&(l=this.processTop10(t,n)),l&&o.push(l)}return o.length>0&&(s.criteria=o),o}processFilterColumn(t,e){if(!e)return null;const s={};if(!e.hasAttribute("colId"))return;s.offset=parseInt(e.getAttribute("colId"));let r=!1;return e.hasAttribute("hiddenButton")&&(r=g.b(e.getAttribute("hiddenButton"))),r&&(s.hiddenButton=!0),e.hasAttribute("showButton")&&(s.showButton=g.b(e.getAttribute("showButton"))),this.processFilterCriteria(t,e,s),s}processFilterColumns(t,e,s){if(!e)return;const r=e.childNodes,o=[];for(let i=0;i<r.length;i++){const n=r.item(i);if(n.nodeType===1&&n.localName==="filterColumn"){const l=this.processFilterColumn(t,n);l&&o.push(l)}}return o.length>0&&(s.fields=o),o}}class ht{visit(t,e,s){if(!e)return;const r={};if(t.copyFromAttribute(e,"ref",r),e.hasAttribute("caseSensitive")){const n=g.b(e.getAttribute("caseSensitive"));r.collatorOptions=n?p.qr.CaseSensitiveOptions:p.qr.CaseInsensitiveOptions}const o=e.getAttribute("sortMethod");o!=null&&o!=="none"&&(o==="stroke"?r.collatorOptions={...r.collatorOptions,collation:"stroke"}:o==="pinYin"&&(r.collatorOptions={...r.collatorOptions,collation:"pinyin"})),e.hasAttribute("columnSort")&&g.b(e.getAttribute("columnSort"))&&(r.orientation=p.w.Orientation.Column);const i=p.Zr.fastStringToRange(r.ref);return this.processSortConditions(t,e,r,i),Object.keys(r).length>0&&(s.sort=r),r}processSortCondition(t,e,s){if(!e)return null;const r={};if(e.hasAttribute("ref")){if(e.hasAttribute("ref")){const o=e.getAttribute("ref"),i=p.Zr.fastStringToRange(o);r.offset=s?i.colStart-s.colStart:i.colStart}return r.reverse=!1,e.hasAttribute("descending")&&(r.reverse=g.b(e.getAttribute("descending"))),t.copyFromAttribute(e,"sortBy",r,"sortOn"),t.copyFromAttribute(e,"dxfId",r),t.copyFromAttribute(e,"iconSet",r),t.copyFromAttribute(e,"customList",r),r}console.warn("no ref for sort conditional",t.getPath())}processSortConditions(t,e,s,r){if(!e)return;const o=e.childNodes,i=[];for(let n=0;n<o.length;n++){const l=o.item(n);if(l.nodeType===1&&l.localName==="sortCondition"){const a=this.processSortCondition(t,l,r);a&&i.push(a)}}return i.length>0&&(s.fields=i),i}}class U{visit(t,e,s){}processDataBarColor(t,e,s,r,o="dk1"){if(!e)return;const i=g.d(n=>e.getAttribute(n),o);return i&&(s[r]=i),s}processFonts(t,e,s){if(!e)return;const r=e.childNodes;let o=0;for(let i=0;i<r.length;i++){const n=r.item(i);if(n.nodeType===1&&n.localName==="font"){const l={};this.processFont(t,n,l),s[o++]=l}}return s}processFont(t,e,s){t.getValAttrAsBoolean("b",e,!0)&&(s.weight=700),t.getValAttrAsBoolean("i",e,!0)&&(s.style=p.ne.Style.Italic),t.getValAttrAsBoolean("strike",e,!0)&&(s.strike=!0);const r=t.evaluate("u",e);if(r){const n=r.getAttribute("val");s.underline=n||p.ne.UnderlineStyle.Single}A(t,e,s,"vertAlign","verticalAlign"),s.verticalAlign==="superscript"?s.verticalAlign=p.ne.VerticalAlignment.Super:s.verticalAlign==="subscript"&&(s.verticalAlign=p.ne.VerticalAlignment.Sub),y(t,e,s,"sz","size");const o=t.evaluate("color",e);this.processDataBarColor(t,o,s,"fill"),s.fill||(s.fill="dk1"),A(t,e,s,"name","family"),A(t,e,s,"rFont","family");const i=t.evaluate("family",e);if(i){const n=i.getAttribute("val");if(n)switch(n){case"1":s.fallbacks=["serif"];break;case"2":s.fallbacks=["sans-serif"];break;case"3":s.fallbacks=["monospace"];break;case"4":s.fallbacks=["cursive"];break;case"5":s.fallbacks=["fantasy"]}}return A(t,e,s,"scheme","scheme"),f(t,e,s,"shadow","shadow",!0),f(t,e,s,"outline","outline",!0),t.getValAttrAsBoolean("condense",e,!0)&&(s.letterSpacing=-1),t.getValAttrAsBoolean("extend",e,!0)&&(s.letterSpacing=1),A(t,e,s,"charset","charset"),s}processFills(t,e,s){if(!e)return;const r=e.childNodes;let o=0;for(let i=0;i<r.length;i++){const n=r.item(i);n.nodeType===1&&n.localName==="fill"&&this.processFill(t,n,s,o++)}return s}processFill(t,e,s,r){const o={type:p.Z$1.Type.None},i=e.childNodes;let n=!1;for(let l=0;!n&&l<i.length;l++){const a=i.item(l);a.nodeType===1&&(a.localName==="gradientFill"?(this.processGradientFill(t,a,o),n=!0):a.localName==="patternFill"&&(this.processPatternFill(t,a,o),n=!0))}return s[r]=o,s}processGradientFill(t,e,s){if(!e)return;s.type=p.Z$1.Type.Gradient;const r=[];s.stops=r,s.angle=90+(e.hasAttribute("degree")?parseFloat(e.getAttribute("degree")):0);const o=e.getAttribute("type");o&&(s.gradientType=o);const i=l=>{if(!l)return 0;const a=parseFloat(l);return isNaN(a)?0:a};(e.hasAttribute("left")||e.hasAttribute("top")||e.hasAttribute("right")||e.hasAttribute("bottom"))&&(s.fillTo={left:i(e.getAttribute("left")),top:i(e.getAttribute("top")),right:i(e.getAttribute("right")),bottom:i(e.getAttribute("bottom"))});const n=e.childNodes;for(let l=0;l<n.length;l++){const a=n.item(l);if(a.nodeType===1&&a.localName==="stop"){const c={};r.push(c);const h=parseFloat(a.getAttribute("position"));c.offset=h;const d=t.evaluate("color",a);this.processDataBarColor(t,d,c,"color")}}return s}processPatternFill(t,e,s){if(!e)return;const r=t.getVisitorParamsState().get("processingDXFs"),o=e.getAttribute("patternType")||(r?p.Z$1.BuiltInSheetPattern.Solid:p.Z$1.BuiltInSheetPattern.None);if(o===p.Z$1.BuiltInSheetPattern.None)return{none:!0};s.type=p.Z$1.Type.Pattern,o&&(s.patternType=o);let i,n="foreground",l="background";const a=s.patternType===p.Z$1.BuiltInSheetPattern.Solid&&r;if(a){i="lt1";const d=n;n=l,l=d}const c=t.evaluate("fgColor",e);this.processDataBarColor(t,c,s,n,i);const h=t.evaluate("bgColor",e);return this.processDataBarColor(t,h,s,l,i),a&&!s.foreground&&(s.foreground=i),s}processBorders(t,e,s,r){if(!e)return;const o=e.childNodes;let i=0;for(let n=0;n<o.length;n++){const l=o.item(n);l.nodeType===1&&l.localName==="border"&&this.processBorder(t,l,s,i++,r)}return s}processBorder(t,e,s,r,o){if(!e)return;const i={};return this.processBorderStroke(t,e,i,p.U.Edge.Left),this.processBorderStroke(t,e,i,p.U.Edge.Right),o?(i.right||i.left)&&(i.right?i.vertical={...i.right}:i.vertical={...i.left}):this.processBorderStroke(t,e,i,p.U.Edge.Vertical),this.processBorderStroke(t,e,i,p.U.Edge.Top),this.processBorderStroke(t,e,i,p.U.Edge.Bottom),o?(i.bottom||i.top)&&(i.right?i.horizontal={...i.bottom}:i.horizontal={...i.top}):this.processBorderStroke(t,e,i,p.U.Edge.Horizontal),s[r]=i,s}processBorderStroke(t,e,s,r){if(!e)return;const o=t.evaluate(r,e);if(!o)return;const i={};o.hasAttribute("style")&&(i.style=o.getAttribute("style"));const n=t.evaluate("color",o);return n&&this.processDataBarColor(t,n,i,"color"),Object.keys(i).length>0?s[r]=i:null}}class pt extends U{visit(t,e,s){this.processNumFmts(t,t.evaluate("numFmts",e),null),t.getVisitorParamsState().set("colorsToProcess",new Set);const r={fills:{},fonts:{},borders:{}};this.processFonts(t,t.evaluate("fonts",e),r.fonts),this.processFills(t,t.evaluate("fills",e),r.fills),this.processBorders(t,t.evaluate("borders",e),r.borders,!0),r.fills[0]={type:p.Z$1.Type.None},r.fills[1]={type:p.Z$1.Type.Pattern,patternType:p.Z$1.BuiltInSheetPattern.Gray125},r.borders[0]={};const o=[];this.processXFs(t,t.evaluate("cellStyleXfs",e),o,r,null,!1);const i=new Map;if(o.length>0){const a=[];this.processCellStyles(t,t.evaluate("cellStyles",e),a,o,i),s.named=a}const n=[];this.processXFs(t,t.evaluate("cellXfs",e),n,r,i),Object.keys(n).length>0&&(s.direct=n);const l=[];return this.processDXFs(t,t.evaluate("dxfs",e),l),this.processTableStyles(t,t.evaluate("tableStyles",e),s,l),this.processIndexColors(t,t.evaluate("colors/indexedColors",e),s),this.processMruColors(t,t.evaluate("colors/mruColors",e),s),s}processIndexColors(t,e,s){if(!e)return;const r=[],o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1&&n.localName==="rgbColor"){const l={color:null};this.processDataBarColor(t,n,l,"color"),l.color&&r.push(l.color)}}s.indexedColors=r}processMruColors(t,e,s){if(!e)return;const r=[],o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1&&n.localName==="color"){const l={color:null};this.processDataBarColor(t,n,l,"color"),l.color&&r.push(l.color)}}r.length>0&&(s.mruColors=r)}processNumFmts(t,e,s){if(!e)return;const r=new Map;if(t.getVisitorParamsState().set("numFmts",r),!e)return;const o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1&&n.localName==="numFmt"){const l=n.getAttribute("numFmtId"),a=n.getAttribute("formatCode");if(l&&a){const c=a.replace(/\\(.)/g,"$1");r.set(parseInt(l),c)}}}}processXFs(t,e,s,r,o=null,i=!0){if(!e)return;const n=e.childNodes;for(let l=0;l<n.length;l++){const a=n.item(l);if(a.nodeType===1&&a.localName==="xf"){const c={};this.processXF(t,a,c,r,o,i),s.push(c)}}}processXF(t,e,s,r,o,i){if(!e)return;const n=e.getAttribute("xfId");if(n&&o){const c=o.get(parseInt(n));c&&c!==p.ue.BuiltInName.Normal&&(s.named=c)}const l=c=>!(!i&&e.hasAttribute(c))||g.b(e.getAttribute("applyFont"));if(l("applyFont")){const c=r.fonts[e.getAttribute("fontId")];c&&(s.font=c)}if(l("applyFill")){const c=r.fills[e.getAttribute("fillId")];c&&Object.keys(c).length>0&&(s.fill=c)}if(l("applyBorder")){const c=r.borders[e.getAttribute("borderId")];c&&Object.keys(c).length>0&&(s.border=c)}if(l("applyNumberFormat")){const c=e.getAttribute("numFmtId");if(c){const h=parseInt(c);let d;const m=t.getVisitorParamsState();if(m){const b=m.get("numFmts");b&&(d=b.get(h)),s.numberFormat=d??h}else console.warn("no visitor params state")}}l("applyAlignment")&&this.processAlignment(t,t.evaluate("alignment",e),s),l("applyProtection")&&this.processProtection(t,t.evaluate("protection",e),s);const a=g.b(e.getAttribute("quotePrefix"));a&&(s.quotePrefix=a)}processAlignment(t,e,s){const r={};if(e?.hasAttribute("horizontal")?r.horizontal=e.getAttribute("horizontal"):r.horizontal=p.K.HorizontalAlignment.General,e?.hasAttribute("vertical")?r.vertical=e.getAttribute("vertical"):r.vertical=p.K.VerticalAlignment.Bottom,e?.hasAttribute("indent")?r.indent=parseInt(e.getAttribute("indent")):r.indent=0,e?.hasAttribute("relativeIndent")?r.relativeIndent=parseInt(e.getAttribute("relativeIndent")):r.relativeIndent=0,g.b(e?.getAttribute("wrapText"))?r.overflow=p.K.Overflow.Wrap:r.overflow=p.K.Overflow.Visible,g.b(e?.getAttribute("shrinkToFit"))&&(r.overflow=p.K.Overflow.Shrink),e?.hasAttribute("textRotation")){let i=parseFloat(e.getAttribute("textRotation"));i>0&&i<=90?i=360-i:i>90&&i<=180?i-=90:i===255&&(i=0,r.stacked=!0),r.rotation=i}else r.rotation=0;e?.hasAttribute("justifyLastLine")&&(r.justifyLastLine=g.b(e.getAttribute("justifyLastLine")));const o=e?.getAttribute("readingOrder");return o&&(o==="0"?r.readingDirection=p.K.ReadingDirection.Auto:o==="1"?r.readingDirection=p.K.ReadingDirection.LeftToRight:o==="2"?r.readingDirection=p.K.ReadingDirection.RightToLeft:console.warn(`invalid readingOrder: ${o}`)),Object.keys(r).length>0&&(s.alignment=r),s}processProtection(t,e,s){if(!e)return;const r={},o=e.getAttribute("locked");o&&!g.b(o)&&(r.edit=!0);const i=e.getAttribute("hidden");return i&&g.b(i)&&(r.formulaHidden=!0),Object.keys(r).length>0&&(s.protection=r),s}processDXF(t,e,s){if(!e)return;const r=e.childNodes;for(let o=0;o<r.length;o++){const i=r.item(o);if(i.nodeType===1&&i.localName==="font"){const n={};this.processFont(t,i,n),s.font=n}else if(i.nodeType===1&&i.localName==="fill"){const n=[];this.processFill(t,i,n,0),n.length>0&&n[0]&&(s.fill=n[0])}else if(i.nodeType===1&&i.localName==="border"){const n=[];this.processBorder(t,i,n,0,!1),n.length>0&&n[0]&&(s.border=n[0])}}}processDXFs(t,e,s){if(!e)return;t.getVisitorParamsState().set("processingDXFs",!0);const r=new Map;t.getVisitorParamsState().set("dxfs",r);const o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1&&n.localName==="dxf"){const l={};this.processDXF(t,n,l);const a=s.length;r.set(a,l),s.push(l)}}t.getVisitorParamsState().delete("processingDXFs")}processTableStyle(t,e,s,r,o=!1){const i=e.getAttribute("name"),n={name:i};e.hasAttribute("table")&&(n.table=g.b(e.getAttribute("table"))),e.hasAttribute("pivot")&&(n.pivot=g.b(e.getAttribute("pivot"))),o&&!n.pivot&&r.unshift(null);const l=e.childNodes;for(let a=0;a<l.length;a++){const c=l.item(a);if(c.nodeType===1&&c.localName==="tableStyleElement"){const h=c.getAttribute("type"),d=c.getAttribute("dxfId");let m=r?.[d];m||(console.warn("invalid dfx id",d),m={}),n[h]=m;let b=null;c.hasAttribute("size")&&(b=parseInt(c.getAttribute("size"))),b&&!isNaN(b)&&(m.size=b)}}delete n.name,s[i]=n}processTableStyles(t,e,s,r,o){if(!e)return;const i={},n=e.getAttribute("defaultTableStyle");n&&(i.defaultTableStyle=n);const l=e.getAttribute("defaultPivotStyle");l&&(i.defaultPivotStyle=l);const a=e.childNodes,c={};for(let h=0;h<a.length;h++){const d=a.item(h);d.nodeType===1&&d.localName==="tableStyle"&&this.processTableStyle(t,d,c,r,o)}return Object.keys(c).length>0&&(i.styles=c),Object.keys(i).length>0&&(s.tables=i),s}processCellStyles(t,e,s,r,o){if(!e)return;const i=e.childNodes;for(let n=0;n<i.length;n++){const l=i.item(n);if(l.nodeType===1&&l.localName==="cellStyle"){const a=parseInt(l.getAttribute("xfId")),c=l.getAttribute("name");if(o.set(a,c),!r[a])continue;const h={name:c,style:r[a]};l.getAttribute("hidden")&&(h.hidden=g.b(l.getAttribute("hidden"))),l.getAttribute("iLevel")&&(h.iLevel=parseInt(l.getAttribute("iLevel"))),s.push(h)}}}afterVisit(t,e,s){}}class gt extends U{visit(t,e,s){return this.processSheetRefs(t,t.evaluate("sheets",e),s),this.processBookViews(t,t.evaluate("bookViews",e),s),this.processDefinedNames(t,t.evaluate("definedNames",e),s),this.processCalcPr(t,t.evaluate("calcPr",e),s),this.processWorkbookProtection(t,t.evaluate("workbookProtection",e),s),this.processWorkbookPr(t,t.evaluate("workbookPr",e),s),s}processPassword(t,e,s,r="password"){if(!e)return;const o={};t.copyFromAttribute(e,"algorithmName",o,"algorithmName"),t.copyFromAttribute(e,"hashValue",o,"hashValue"),t.copyFromAttribute(e,"saltValue",o,"saltValue",t.BOOLEAN_COPY),t.copyFromAttribute(e,"spinCount",o,"spinCount",t.INT_COPY),Object.keys(o).length>0&&(s[r]=o)}processWorkbookProtection(t,e,s){if(!e)return;const r={};this.processPassword(t,t.evaluate("workbookPassword",e),r),this.processPassword(t,t.evaluate("revisionsPassword",e),r,"revisionsPassword");const o=i=>i!==!0&&i!=="1"&&i!=="on"&&i!=="true"&&(i===!1||i==="0"||i==="off"||i==="false"||null);return t.copyFromAttribute(e,"lockStructure",r,"structure",o),t.copyFromAttribute(e,"lockWindows",r,"windows",o),t.copyFromAttribute(e,"lockRevision",r,"revision",o),s.protection=r,s}processCalcPr(t,e,s){e&&(s.calc={})}processSheetRefs(t,e,s){if(!e)return;const r=[],o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);n.nodeType===1&&n.localName==="sheet"&&this.processSheetRef(t,n,r)}s.sheets=r}processSheetRef(t,e,s){const r={};t.copyFromAttribute(e,"name",r,"name"),t.copyFromAttribute(e,"state",r,"visibility");const o=e.getAttribute("r:id"),i=t.getRef(o);i&&(r.sheet=i),s.push(r)}processBookViews(t,e,s){if(!e)return;const r=e.childNodes;let o=0;for(let i=0;o<1&&i<e.childNodes.length;i++){const n=r.item(i);n.nodeType===1&&n.localName==="workbookView"&&(this.processWorkbookView(t,n,s),o++)}}processWorkbookView(t,e,s){if(!e)return;const r={};t.copyFromAttribute(e,"activeTab",r,"activeSheetId",[t.INT_COPY,o=>o+1]),e.hasAttribute("activeTab")||(r.activeSheetId=1),t.copyFromAttribute(e,"showHorizontalScroll",r,"showHorizontalScrollbar",t.BOOLEAN_COPY),t.copyFromAttribute(e,"showVerticalScroll",r,"showVerticalScrollbar",t.BOOLEAN_COPY),t.copyFromAttribute(e,"showSheetTabs",r,"showTabs",t.BOOLEAN_COPY),t.copyFromAttribute(e,"tabRatio",r,"tabRatio",[t.FLOAT_COPY,o=>o]),Object.keys(r).length>0&&(s.view=r)}processDefineName(t,e,s,r){if(!e)return;const o={},i=e.firstChild;if(i&&i.nodeType===3&&(o.ref=i.textContent),t.copyFromAttribute(e,"name",o),t.copyFromAttribute(e,"comment",o),t.copyFromAttribute(e,"hidden",o,"hidden",t.BOOLEAN_COPY),e.hasAttribute("localSheetId")){const n=e.getAttribute("localSheetId");if(!r[n]?.name)return void console.warn(`Defined name '${e.getAttribute("name")}' references a sheet with localSheetId '${n}' which does not exist.`);o.scope=r[n].name}t.copyFromAttribute(e,"customMenu",o),t.copyFromAttribute(e,"description",o),t.copyFromAttribute(e,"statusBar",o),t.copyFromAttribute(e,"help",o),t.copyFromAttribute(e,"shortcutKey",o),t.copyFromAttribute(e,"function",o,"function",t.BOOLEAN_COPY),t.copyFromAttribute(e,"functionGroupId",o,"functionGroupId",t.INT_COPY),t.copyFromAttribute(e,"publishToServer",o,"publishToServer",t.BOOLEAN_COPY),t.copyFromAttribute(e,"vbProcedure",o,"vbProcedure",t.BOOLEAN_COPY),t.copyFromAttribute(e,"xlm",o,"xlm",t.BOOLEAN_COPY),Object.keys(o).length>0&&s.push(o)}processDefinedNames(t,e,s){if(!e)return;const r=[],o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);n.nodeType===1&&n.localName==="definedName"&&this.processDefineName(t,n,r,s.sheets)}r.length>0&&(s.names=r)}processWorkbookPr(t,e,s){e&&t.copyFromAttribute(e,"date1904",s,"date1904",t.BOOLEAN_COPY)}afterVisit(t,e,s){}}class dt{visit(t,e,s){return t.copyFromAttribute(e,"name",s),t.copyFromAttribute(e,"displayName",s),t.copyFromAttribute(e,"ref",s),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),s}processTableStyleInfo(t,e,s){if(!e)return;const r=e.childNodes,o={};for(let i=0;i<r.length;i++){const n=r.item(i);n.nodeType===1&&n.localName==="tableStyleInfo"&&(t.copyFromAttribute(n,"name",o),t.copyFromAttribute(n,"showColumnStripes",o,"showColumnStripes",t.BOOLEAN_COPY),t.copyFromAttribute(n,"showFirstColumn",o,"showFirstColumn",t.BOOLEAN_COPY),t.copyFromAttribute(n,"showLastColumn",o,"showLastColumn",t.BOOLEAN_COPY),t.copyFromAttribute(n,"showRowStripes",o,"showRowStripes",t.BOOLEAN_COPY))}Object.keys(o).length>0&&(s.styleOptions=o)}processTableColumn(t,e,s){if(!e)return null;const r=e.childNodes;for(let o=0;o<r.length;o++){const i=r.item(o);if(i.nodeType===1&&i.localName==="tableColumn"){const n={};t.copyFromAttribute(i,"name",n),t.copyFromAttribute(i,"uniqueName",n),s.push(n)}}return s}processTableColumns(t,e,s){const r=e.childNodes,o=[];for(let i=0;i<r.length;i++){const n=r.item(i);n.nodeType===1&&n.localName==="tableColumns"&&this.processTableColumn(t,n,o)}o.length>0&&(s.columns=o)}}class mt{visit(t,e,s){return s}}class x{visit(t,e,s){if(!e)return;const r={};return t.copyFromAttribute(e,"editAs",r,"anchorType"),r.anchor={},this.processOffsetCoord(t,t.evaluate("from",e),r.anchor,"from"),this.processOffsetCoord(t,t.evaluate("to",e),r.anchor,"to"),s.movables||(s.movables=[]),s.movables.push(r),r}processOffsetCoord(t,e,s,r){if(!e)return;const o={c:0,r:0,x:0,y:0};return t.evaluate("col",e)&&(o.c=parseInt(t.evaluate("col",e).textContent)),t.evaluate("row",e)&&(o.r=parseInt(t.evaluate("row",e).textContent)),t.evaluate("colOff",e)&&(o.x=g.c(t.evaluate("colOff",e).textContent)),t.evaluate("rowOff",e)&&(o.y=g.c(t.evaluate("rowOff",e).textContent)),r==="from"?s.tl=o:s.br=o,s}}class I{visit(t,e,s){if(!e)return;const r=t.evaluate("*/cNvPr",e);return r&&(t.copyFromAttribute(r,"name",s),t.copyFromAttribute(r,"desc",s),t.copyFromAttribute(r,"hidden",s,"hidden",t.BOOLEAN_COPY),t.copyFromAttribute(r,"id",s)),s}}class bt extends I{visit(t,e,s){if(!e)return;s=super.visit(t,e,s);const r=t.evaluate("nvGraphicFramePr/cNvGraphicFramePr",e);if(r){const n=t.evaluate("graphicFrameLocks",r);if(n){n.hasAttribute("noChangeAspect")&&(s.lockAspect=n.getAttribute("noChangeAspect")==="1");const l={};Object.keys(l).length>0&&(s.locks=l)}}let o={type:"graphicFrame",json:{}};const i=t.evaluate("graphic/graphicData",e).childNodes;for(let n=0;n<i.length;n++){const l=i.item(n);if(l.nodeType===1)try{let a=l.localName;a==="chart"&&(a="chart"),o.type=a;const c=l.getAttribute("r:id");c&&(o.json=t.getRef(c))}catch(a){console.warn("Unable to parse graphicFrame",a)}}return o&&(s.content=o),o}}class B extends I{visit(t,e,s){if(!e)return;s=super.visit(t,e,s);const r=t.evaluate("nvSpPr/cNvSpPr",e);if(r){const i=t.evaluate("spLocks",r);if(i){i.hasAttribute("noChangeAspect")&&(s.lockAspect=i.getAttribute("noChangeAspect")==="1");const n={};Object.keys(n).length>0&&(s.locks=n)}}t.warn(`Unable to import '${s.name}', shapes are not supported.`);const o={};return s.content={type:"sp",json:o},o}}class ft extends I{visit(t,e,s){if(!e)return;const r=super.visit(t,e,s),o=t.evaluate("nvPicPr/cNvPicPr",e);if(o){t.copyFromAttribute(e,"preferRelativeResize",r,"preferRelativeResize",t.BOOLEAN_COPY);const a=t.evaluate("picLocks",o);if(a){a.hasAttribute("noChangeAspect")&&(r.lockAspect=a.getAttribute("noChangeAspect")==="1");const c={};t.copyFromAttribute(a,"noChangeArrowheads",r,"noChangeArrowheads",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noChangeShapeType",r,"noChangeShapeType",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noEditPoints",r,"noEditPoints",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noAdjustHandles",r,"noAdjustHandles",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noCrop",r,"noCrop",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noGrp",r,"noGrp",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noMove",r,"noMove",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noResize",r,"noResize",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noRot",r,"noRot",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noSelect",r,"noSelect",t.BOOLEAN_COPY),Object.keys(c).length>0&&(r.locks=c)}}const i=t.evaluate("blipFill/blip",e);let n;if(i){const a=i.getAttribute("r:embed")??i.getAttribute("embed");if(!a)return void console.warn("no rId found for blip",i);n=t.getRef(a,!0)}const l={resId:n};return s.content={type:"picture",json:l},r}}class At extends B{visit(t,e,s){if(!e)return;s=super.visit(t,e,s);const r=t.evaluate("nvGrpSpPr/cNvGrpSpPr",e);if(r){const i=t.evaluate("grpSpLocks",r);if(i){i.hasAttribute("noChangeAspect")&&(s.lockAspect=i.getAttribute("noChangeAspect")==="1");const n={};Object.keys(n).length>0&&(s.locks=n)}}t.warn(`Unable to import '${s.name}', group shapes are not supported.`);const o={};return s.content={type:"grpSp",json:o},o}}class yt extends B{visit(t,e,s){if(!e)return;s=super.visit(t,e,s);const r=t.evaluate("nvCxnSpPr/cNvCxnSpPr",e);if(r){const i=t.evaluate("cxnSpLocks",r);if(i){i.hasAttribute("noChangeAspect")&&(s.lockAspect=i.getAttribute("noChangeAspect")==="1");const n={};Object.keys(n).length>0&&(s.locks=n)}}t.warn(`Unable to import '${s.name}', connection shapes are not supported.`);const o={};return s.content={type:"cxnSp",json:o},o}}const j="richTypes";class vt{visit(t,e,s){let r=t.getVisitorParamsState().get(j);r||(r=[],t.getVisitorParamsState().set(j,r));const o=e.childNodes,i=o.length;for(let n=0;n<i;n++){const l=o.item(n);if(l.nodeType===1&&l.localName==="s"){const a={type:l.getAttribute("t")??"n",keys:[]};this.processKeys(t,l,a),r.push(a)}}return s.richTypes=r,r}processKeys(t,e,s){const r=e.childNodes,o=r.length,i=s.keys;for(let n=0;n<o;n++){const l=r.item(n);if(l.nodeType===1&&l.localName==="k"){const a=l.getAttribute("n"),c=l.getAttribute("t");i.push([a,c])}}}}const R="richData";class Ft{visit(t,e,s){let r=t.getVisitorParamsState().get("richTypes");if(!r)return void t.warn("RichValueFound but not type.");let o=t.getVisitorParamsState().get(R);o||(o=[],t.getVisitorParamsState().set(R,o));const i=e.childNodes,n=i.length;for(let l=0;l<n;l++){const a=i.item(l);if(a.nodeType===1&&a.localName==="rv"){const c=r[a.getAttribute("s")],h={type:c.type};this.processValues(t,a,h,c);const d=this.mapType(t,h);o.push(d)}}return s.richData=o,o}mapType(t,e){if(e.type==="_error"){const s=e.errorType;if(s)try{e=p.n.getBuiltInById(s+1)}catch{}}return e}processValues(t,e,s,r){const o=e.childNodes,i=o.length;r.type;const n=r.keys;for(let l=0;l<i;l++){const a=o.item(l);if(a.nodeType===1&&a.localName==="v"){const c=n[l];if(!c)return void t.warn("Invalid richData");const h=c[0],d=c[1];let m=a.textContent;d==="i"&&(m=Number(m)),s[h]=m}}}}class Ct{visit(t,e,s){if(!e)return;const r=[];return this.processAuthors(t,t.evaluate("authors",e),r),r.length>0&&(s.authors=r),s.comments=[],s}processAuthors(t,e,s){if(!e)return;const r=e.childNodes;for(let o=0;o<r.length;o++){const i=r.item(o);if(i.nodeType===1&&i.localName==="author"){const n=i.firstChild;n&&n.nodeType===3&&s.push(n.textContent)}}}}class wt{visit(t,e,s){if(!e)return;const r={};return t.copyFromAttribute(e,"ref",r),t.copyFromAttribute(e,"authorId",r,"authorId",t.INT_COPY),r.asNote=!0,s.comments||(s.comments=[]),s.comments.push(r),r}}class Pt{visit(t,e,s){if(!e)return;const r=[];return s.comments=r,r}}class Nt{visit(t,e,s){if(!e)return;const r={};return t.copyFromAttribute(e,"id",r,"id",g.r),t.copyFromAttribute(e,"personId",r,"personId",g.r),t.copyFromAttribute(e,"ref",r),t.copyFromAttribute(e,"parentId",r,"parentId",g.r),t.copyFromAttribute(e,"dT",r),e.hasAttribute("done")&&(r.done=g.b(e.getAttribute("done"))),s.push(r),r}}class Ot{visit(t,e,s){const r=[],o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1&&n.localName==="person"){const l={};t.copyFromAttribute(n,"id",l,"id",g.r),t.copyFromAttribute(n,"displayName",l),t.copyFromAttribute(n,"userId",l,"userId",g.r),t.copyFromAttribute(n,"providerId",l),r.push(l)}}return r.length>0&&(s.persons=r),r}}const Tt={};class Vt{constructor(t,e){this.path=t,this.visitor=e}}class E{constructor(){this.visitorsByXmlTagName=new Map,this.scopedVisitorsByXmlTagName=new Map,this.visitorParamsState=null,this.registerVisitor("Relationships",new K),this.registerVisitor("spPr",new L),this.registerVisitor("txBody",new F),this.registerVisitor("txPr",new F),this.registerVisitor("c:chartSpace",new Z),this.registerVisitor("c:chartSpace",new q,"chart"),this.registerVisitor("c:plotArea",new H),this.registerVisitor("c:barChart",new J),this.registerVisitor("c:doughnutChart",new N),this.registerVisitor("c:lineChart",new N),this.registerVisitor("c:ofPieType",new N),this.registerVisitor("c:pieChart",new N),this.registerVisitor("c:scatterChart",new N),this.registerVisitor("c:barChart",new w("dataLabels"),"dLbls"),this.registerVisitor("c:doughnutChart",new w("dataLabels"),"dLbls"),this.registerVisitor("c:lineChart",new w("dataLabels"),"dLbls"),this.registerVisitor("c:ofPieType",new w("dataLabels"),"dLbls"),this.registerVisitor("c:pieChart",new w("dataLabels"),"dLbls"),this.registerVisitor("c:scatterChart",new w("dataLabels"),"dLbls"),this.registerVisitor("c:ser",new Q),this.registerVisitor("c:dPt",new tt),this.registerVisitor("c:marker",new et),this.registerVisitor("c:catAx",new k),this.registerVisitor("c:valAx",new k),this.registerVisitor("c:dateAx",new k),this.registerVisitor("c:majorGridlines",new S("gridLinesMajor")),this.registerVisitor("c:minorGridlines",new S("gridLinesMinor")),this.registerVisitor("c:chartSpace",null,"txPr"),this.registerVisitor("c:catAx",new F("labels.text"),"txPr"),this.registerVisitor("c:valAx",new F("labels.text"),"txPr"),this.registerVisitor("c:dateAx",new F("labels.text"),"txPr"),this.registerVisitor("c:legend",new st),this.registerVisitor("c:legend",new F("labels.text"),"txPr"),this.registerVisitor("c:legendEntry",new rt),this.registerVisitor("c:ser",new ot,"extLst/ext/invertSolidFillFmt/spPr"),this.registerVisitor("c:ser",new w("labels"),"dLbls"),this.registerVisitor("c:dLbl",new w("points")),this.registerVisitor("c:title",new _),this.registerVisitor("c:title",null,"tx/rich"),this.registerVisitor("c:title",null,"txPr"),this.registerVisitor("c:layout",new it),this.registerVisitor("c:dispUnits",new S("dispUnits")),this.registerVisitor("c:dispUnitsLbl",new _("displayUnitsLabel")),this.registerVisitor("c:dispUnitsLbl",new F,"tx/rich"),this.registerVisitor("a:theme",new nt),this.registerVisitor("a:theme",new lt,"themeElements/clrScheme"),this.registerVisitor("a:theme",new at,"themeElements/fontScheme"),this.registerVisitor("autoFilter",new ut),this.registerVisitor("sortState",new ht),this.registerVisitor("s:workbook",new gt),this.registerVisitor("styleSheet",new pt),this.registerVisitor("table",new dt),this.registerVisitor("hlinkClick",new ct),this.registerVisitor("wsDr",new mt),this.registerVisitor("twoCellAnchor",new x),this.registerVisitor("oneCellAnchor",new x),this.registerVisitor("absoluteAnchor",new x),this.registerVisitor("graphicFrame",new bt),this.registerVisitor("sp",new B),this.registerVisitor("grpSp",new At),this.registerVisitor("cxnSp",new yt),this.registerVisitor("pic",new ft),this.registerVisitor("rvStructures",new vt),this.registerVisitor("rvData",new Ft),this.registerVisitor("comments",new Ct),this.registerVisitor("commentList",new wt,"comment"),this.registerVisitor("comment",new F("content"),"text"),this.registerVisitor("ThreadedComments",new Pt),this.registerVisitor("threadedComment",new Nt),this.registerVisitor("threadedComment",new F("content"),"text"),this.registerVisitor("personList",new Ot)}registerVisitor(t,e,s=null){t.indexOf(":")===-1&&(t="*:"+t);const r=t.split(":"),o=r.length>1?r[1]:r[0];if(!s)return this.visitorsByXmlTagName.set(o,e),void this.visitorsByXmlTagName.set(t,e);let i=this.scopedVisitorsByXmlTagName.get(o);i||(i=[],this.scopedVisitorsByXmlTagName.set(o,i),this.scopedVisitorsByXmlTagName.set(t,i)),i.push(new Vt(s,e))}getVisitorParamsState(){return this.visitorParamsState}convert(t,e,s=Tt){const r=t.documentElement;this.visitorParamsState&&!s?.paramMap||(this.visitorParamsState=s?.paramMap??new Map);const o={};let i=this.visitorsByXmlTagName.get(r.nodeName);if(i||(i=this.visitorsByXmlTagName.get(r.localName)),!i)throw new Error(`A visitor for the root element: '${r.nodeName}' or '${r.localName}' must be registered.`);const n="/"+r.localName,l=new V(null,this,n,r,o,e,s),a=[];this._doWalk(i,l,a,r,o,e,s);for(let c=0;c<a.length;c++){const h=a[c];try{h.visitor?.afterVisit?.(h.context,h.elemParent,h.jsonParent)}catch(d){console.warn(`Error in afterVisit: ${h.context.getPath()}`,d)}}return o}_walkScoped(t,e,s,r,o,i,n){const l=this.scopedVisitorsByXmlTagName.get(t);for(let a=0;l&&a<l.length;a++){const c=l[a];let h=null;try{h=e.evaluate(c.path,r)}catch{console.warn(`"Invalid path '${c.path}' for '${t}'.`)}if(!h)continue;const d=m=>{let b=m.localName,v=m.parentNode;for(;v&&v!==r;)b=v.localName+"/"+b,v=v.parentNode;const P=e.getPath()+"/"+b;if(c.visitor){const T=new V(e,this,P,e.getElemRoot(),e.getJsonRoot(),i,n);this._doWalk(c.visitor,T,s,m,o,i,n)}};if(h.length>0){const m=h;for(let b=0;b<m.length;b++)d(m.item(b))}else d(h)}}_doWalk(t,e,s,r,o,i,n){let l=null;t&&(s.push({visitor:t,context:e,elemParent:r,jsonParent:o}),l=t.visit(e,r,o)),l||(l=o);const a=r.localName;this._walkScoped(a,e,s,r,l,i,n);const c=r.childNodes;for(let h=0;h<c.length;h++){const d=c.item(h);if(d.nodeType===1){const m=d,b=m.localName,v=this.visitorsByXmlTagName.get(b),P=e.getPath()+"/"+b,T=new V(e,this,P,e.getElemRoot(),e.getJsonRoot(),i,n);this._doWalk(v,T,s,m,l??o,i,n)}}return l}}exports.FromOOXMLConverter=E,exports.default=E;
|
|
6
|
+
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("./BrhEZihB-_ktU4T0.cjs"),g=require("./CWlyoyrXvR3BE-jk.cjs");class X{constructor(t){this.list=t}get length(){return this.list.length}item(t){return this.list[t]}forEach(t,e){for(let s=0;s<this.list.length;s++)t(this.list[s],s,this)}}const z=u=>u===!0||u==="1"||u==="on"||u==="true"||u!==!1&&u!=="0"&&u!=="off"&&u!=="false"&&null,G=u=>{const t=parseInt(u);return isNaN(t)?null:t},W=u=>{const t=parseFloat(u);return isNaN(t)?null:t},$=new Map;class V{constructor(t,e,s,r,o,i=null,n){const l=(c,h,d)=>n?.getRef?.(c,h,d,n?.parsedRefs),a=c=>n?.getRefs?.(c,n?.parsedRefs);this._parent=t,this.sharedShared=e,this.currentPath=s,this.elemRoot=r,this.jsonRoot=o,t?(this._fileLocation=t._fileLocation,this._getRef=t._getRef,this._getRefs=t._getRefs):(i&&(this._fileLocation=i),l&&a&&(this._getRef=l),a&&(this._getRefs=a),this._onWarning=n?.onWarning,this._addPerson=n?.addPerson)}getRef(t,e=!1){return this._getRef?.(t,this._fileLocation,e)??null}getRelationships(){return this._getRefs(this._fileLocation)??$}getPath(){return this.currentPath}getElemRoot(){return this.elemRoot}getJsonRoot(){return this.jsonRoot}warn(t){this._onWarning?this._onWarning(t):this._parent?this._parent?.warn?.(t):console.warn(t)}addPerson(t){return this._addPerson?this._addPerson(t):this._parent?this._parent?._addPerson?.(t):null}getVisitorParamsState(){return this.sharedShared.getVisitorParamsState()}evaluate(t,e){if(!t)return e;let s=[e];const r=t.split("/");for(let o=0;o<r.length;o++){const i=r[o];if(i===""||i===".")continue;let n=[];for(let l=0;l<s.length;l++){const a=s[l],c=a.childNodes;for(let h=0;c&&h<c.length;h++){const d=a.childNodes[h];d.localName!==i&&i!=="*"||n.push(d)}}s=n}return s.length===1?s[0]:s.length===0?null:new X(s)}getFromPath(t,e){return p.Xt.getFromPath(t,e)}setToPath(t,e,s){return p.Xt.setToPath(t,e,s)}getValAttrAsString(t,e){let s=this.evaluate(t,e);return s&&s.hasAttribute("val")?s.getAttribute("val")??null:null}getValAttrAsBoolean(t,e,s=!1){let r=this.evaluate(t,e);if(!r)return null;const o=r.hasAttribute("val")?r.getAttribute("val"):void 0;return o==null?s:o==="1"||o==="on"||o==="true"||o!=="0"&&o!=="off"&&o!=="false"&&s}getValAttrAsInteger(t,e){let s=this.evaluate(t,e);return s&&s.hasAttribute("val")?parseInt(s.getAttribute("val"))??null:null}getValAttrAsFloat(t,e){let s=this.evaluate(t,e);return s&&s.hasAttribute("val")?parseFloat(s.getAttribute("val"))??null:null}get BOOLEAN_COPY(){return z}get INT_COPY(){return G}get FLOAT_COPY(){return W}copyFromAttribute(t,e,s,r=e,o=null){if(!t||!s||!t.hasAttribute(e))return;let i=t.getAttribute(e);if(o){if(Array.isArray(o)){for(let n=0;n<o.length;n++)if(i==null||(i=o[n](i),i==null))return}else if(i==null||(i=o(i),i==null))return}this.setToPath(s,r,i)}}class S{constructor(t){this.jsonKey=t}visit(t,e,s){const r={};return s[this.jsonKey]=r,r}}class K{visit(t,e,s){if(!e)return;const r=e.childNodes;for(let o=0;o<r.length;o++){const i=r.item(o);i.nodeType===1&&i.localName==="Relationship"&&this.processRelationship(t,i,s)}return s}processRelationship(t,e,s){const r={};t.copyFromAttribute(e,"Target",r,"target"),t.copyFromAttribute(e,"Type",r,"type"),t.copyFromAttribute(e,"TargetMode",r,"targetMode"),s[e.getAttribute("Id")]=r}}const Y=(u,t)=>{if(u||!u.hasAttribute("rot"))return;const e=u.getAttribute("rot"),s=p.Xt.roundAccurately(g.p(e),2);s!==-1e3&&(t.rotation=s)},A=(u,t,e,s,r)=>{const o=u.getValAttrAsString(s,t);o!==null&&(e[r]=o)},f=(u,t,e,s,r=s,o=null)=>{const i=u.getValAttrAsBoolean(s,t,o);i!==null&&(e[r]=i)},C=(u,t,e,s,r)=>{const o=u.getValAttrAsInteger(s,t);o!==null&&(e[r]=o)},y=(u,t,e,s,r,o=1)=>{const i=u.getValAttrAsFloat(s,t);i!==null&&(e[r]=i*o)};class Z{visit(t,e,s){return f(t,e,s,"roundedCorners","roundedCorners"),C(t,e,s,".//AlternateContent/Fallback/style","styleId"),s.range=null,s}afterVisit(t,e,s){let r={};s.types=r;let o={},i=0,n={},l=0,a=t.getVisitorParamsState().get("axes");const c=t.getVisitorParamsState().get("types");for(let m=0;m<c.length;m++){const b=c[m];if(b.xAxisId){const v=b.xAxisId,P=a.get(v);o[m+""]=P,b.offsetXAxis=m,delete b.xAxisId,s.xAxes=o,o.length=++i}if(b.yAxisId){const v=b.yAxisId,P=a.get(v);n[m+""]=P,b.offsetYAxis=m,delete b.yAxisId,s.yAxes=n,n.length=++l}r[m+""]=b}r.length=c.length;const h=t.getVisitorParamsState().get("series");if(!h||h.length===0)return;const d={};s.series=d;for(let m=0;m<h.length;m++)d[m+""]=h[m];d.length=h.length}}class H{visit(t,e,s){return f(t,e,s,"plotVisOnly","plotVisOnly"),A(t,e,s,"dispBlanksAs","dispBlanksAs"),f(t,e,s,".//extLst/ext/dataDisplayOptions16/dispNaAsBlank","dispNaAsBlank"),f(t,e,s,"showDLblsOverMax","showDLblsOverMax"),s}afterVisit(t,e,s){try{const r=t.getValAttrAsBoolean("autoTitleDeleted",e),o=t.evaluate("title",e);t.setToPath(s,"title.shown",!(r===!0||!o));const i=t.evaluate("legend",e);t.setToPath(s,"legend.shown",i!==null)}catch(r){throw new Error("Unexpected Error parsing Chart: "+r)}}}class q{visit(t,e,s){let r={};return s.plotArea=r,r}}class O{EnumMappings(){}static fromOoxmlGradientType(t){return t==="circle"?"radial":t}static fromOoxmlLineCap(t){if(t==="rnd")return"round";if(t==="flat")return"butt";if(t==="sq")return"square";throw new Error("Invalid lineCap type: "+t)}static fromOoxmlCompound(t){return t==="sng"?"single":t}static fromOoxmlAlignment(t){return t==="ctr"?"center":t}}class D{visit(t,e,s){}processStroke(t,e,s){const r={},o=t.evaluate("ln",e);if(o){o.hasAttribute("algn")&&(r.align=O.fromOoxmlAlignment(o.getAttribute("algn"))),o.hasAttribute("cap")&&(r.lineCap=O.fromOoxmlLineCap(o.getAttribute("cap"))),o.hasAttribute("cmpd")&&(r.compound=O.fromOoxmlCompound(o.getAttribute("cmpd"))),o.hasAttribute("w")&&(r.width=g.t(o.getAttribute("w")));const i=t.evaluate("miter",o);i&&(r.lineJoin="miter",i.hasAttribute("lim")&&(r.miter=parseFloat(i.getAttribute("lim")))),t.evaluate("bevel",o)&&(r.lineJoin="bevel"),t.evaluate("round",o)&&(r.lineJoin="round");const n=t.evaluate("custDash",o);if(n){const c=t.evaluate("ds",n);if(c&&c.length>0){let h="";for(let d=0;d<c.length;d++){const m=c.item(d);h+=g.a(m.getAttribute("d"))+","+g.a(m.getAttribute("sp"))}r.dash=h}}const l=t.evaluate("prstDash",o);l&&l.hasAttribute("val")&&(r.dash=l.getAttribute("val")),this.parseEndElement(t,o,r,"headEnd","head"),this.parseEndElement(t,o,r,"tailEnd","tail");const a=this.processFill(t,o,s);r.fill=a}return r}parseEndElement(t,e,s,r,o){const i=t.evaluate(r,e);if(i&&(i.hasAttribute("type")&&(s[o+"Type"]=i.getAttribute("type")),i.hasAttribute("len")||i.hasAttribute("w"))){const n=i.getAttribute("len")?i.getAttribute("len"):"med",l=i.getAttribute("w")?i.getAttribute("w"):"med";s[o+"Size"]=n+"-"+l}}processFill(t,e,s){const r={};if(t.evaluate("noFill",e))return r.none=!0,r;const o=t.evaluate("solidFill",e);if(o){const a=this.processAdjColor(t,o);return a&&(r.solid=a),r}const i=t.evaluate("gradFill",e);if(i){i.hasAttribute("rotWithShape")&&(r.isRotated=i.getAttribute("rotWithShape")==="1");const a=this.processGradFill(t,i);return r.gradient=a,r}const n=t.evaluate("pattFill",e);if(n){const a=this.processPatternFill(t,n);return r.pattern=a,r}const l=t.evaluate("blipFill",e);if(l){l.hasAttribute("rotWithShape")&&(r.isRotated=g.b(l.getAttribute("rotWithShape"))),l.hasAttribute("dpi")&&(r.dpi=l.getAttribute("dpi"));const a=this.processImageFill(t,l);return r.image=a,r}return r.none=!0,r}processGradFill(t,e){const s={},r=t.evaluate("lin",e);if(r){if(s.type="linear",r.hasAttribute("ang")){const c=g.p(r.getAttribute("ang"));s.angle=c}if(r.hasAttribute("scaled")){const c=g.b(r.getAttribute("scaled"));s.scaled=c}}const o={};e.hasAttribute("flip")&&(o.mirror=e.getAttribute("flip")),Object.keys(o).length>0&&(s.tile=o);const i=t.evaluate("path",e);if(i){i.hasAttribute("path")&&(s.type=O.fromOoxmlGradientType(i.getAttribute("path")));const c=t.evaluate("fillToRect",i);c&&(s.fillTo=this.getRect(c))}const n=t.evaluate("tileRect",e);n&&(s.tile.bounds=this.getRect(n));const l=[],a=t.evaluate("gsLst/gs",e);for(let c=0;a&&c<a.length;c++){const h=a.item(c),d={offset:g.a(h.getAttribute("pos")),color:this.processAdjColor(t,h)};l.push(d)}return l.length>0&&(s.stops=l),s}getRect(t){const e={};return t.hasAttribute("t")&&(e.t=g.a(t.getAttribute("t"))),t.hasAttribute("l")&&(e.l=g.a(t.getAttribute("l"))),t.hasAttribute("b")&&(e.b=g.a(t.getAttribute("b"))),t.hasAttribute("r")&&(e.r=g.a(t.getAttribute("r"))),Object.keys(e).length===0?null:e}processImageFill(t,e){return{ref:"https://www.sheetxl.com/logo-color-padded-white.jpg",tile:!1}}processPatternFill(t,e){const s={},r=e.getAttribute("prst");s.type=r;const o=t.evaluate("bgClr",e);if(o){const n=this.processAdjColor(t,o);n&&(s.background=n)}const i=t.evaluate("fgClr",e);if(i){let n=this.processAdjColor(t,i);n&&(s.foreground=n)}return s}processAdjColor(t,e){const s=t.evaluate("hslClr",e);if(s)return this.processHslClr(t,s);const r=t.evaluate("prstClr",e);if(r)return this.processClrWithValAttribute(t,r);const o=t.evaluate("schemeClr",e);if(o)return this.processClrWithValAttribute(t,o);const i=t.evaluate("sysClr",e);if(i)return this.processClrWithValAttribute(t,i);const n=t.evaluate("scrgbClr",e);if(n)return this.processScrgbClrElement(t,n);const l=t.evaluate("srgbClr",e);return l?this.processSrgbClrElement(t,l):null}processScrgbClrElement(t,e){let s="lrgba("+g.a(e.getAttribute("r"))+","+g.a(e.getAttribute("g"))+","+g.a(e.getAttribute("b"))+")";return s+=this.processAdjustments(t,e),s}processSrgbClrElement(t,e){let s=e.getAttribute("val");return s+=this.processAdjustments(t,e),s}processHslClr(t,e){let s="hsl("+g.p(e.getAttribute("hue"))+","+g.a(e.getAttribute("sat"))+","+g.a(e.getAttribute("lum"))+")";return s+=this.processAdjustments(t,e),s}processClrWithValAttribute(t,e){const s=e.getAttribute("val");if(!s)return;let r=s;return r+=this.processAdjustments(t,e),r}processAdjustments(t,e){let s="";const r=e.childNodes;for(let o=0;o<r.length;o++){const i=r.item(o);if(i.nodeType===1){let n=i.localName;s+=n==="hue"||n==="hueOff"||n==="hueMod"?this.processAdjustmentElement(t,e,n,6e4):n==="gray"||n==="comp"||n==="inv"||n==="gamma"||n==="invGamma"?this.processAdjustmentElement(t,e,n,1):this.processAdjustmentElement(t,e,n)}}return s}processAdjustmentElement(t,e,s,r=1e3){const o=t.evaluate(s,e);if(!o)return"";const i=o.getAttribute("val");return i?` ${s} ${!i||parseFloat(i)/r}`:` ${s}`}}class L extends D{visit(t,e,s){try{const r=t.evaluate("xfrm",e);if(r){Y(r,s);const l={x:0,y:0,width:0,height:0},a=t.evaluate("off",r);a&&(l.x=g.c(a.getAttribute("x"))??0,l.y=g.c(a.getAttribute("y"))??0);const c=t.evaluate("ext",r);a&&(l.width=g.c(c.getAttribute("cx"))??0,l.height=g.c(c.getAttribute("cy"))??0),s.bounds=l}const o=t.evaluate("prstGeom",e);o?.hasAttribute("prst")?s.geometry=o?.getAttribute("prst"):t.evaluate("customGeom",e)&&console.warn("customGeom not supported yet");const i=this.processFill(t,e,s);i&&Object.keys(i).length>0&&(s.fill=i);const n=this.processStroke(t,e,s);return n&&Object.keys(n).length>0&&(s.stroke=n),s}catch(r){throw console.warn(r),new Error("Unexpected Error parsing Shape Properties element")}}}class N{visit(t,e,s){let r={};if(A(t,e,r,"grouping","grouping"),f(t,e,r,"varyColors","varyColors"),y(t,e,r,"gapWidth","gapWidth",.01),y(t,e,r,"overlap","overlap",.01),this.parseType(t,e,r),C(t,e,r,"bubbleScale","bubbleScale"),f(t,e,r,"showNegBubbles","showNegativeBubbleValues"),f(t,e,r,"sizeRepresents","bubbleSizeRepresentsWidth"),C(t,e,r,"firstSliceAng","startAngle"),C(t,e,r,"holeSize","holeSize"),A(t,e,r,"scatterStyle","scatterStyle"),this.parseAxisIds(t,e,r),Object.keys(r).length>0){let o=t.getVisitorParamsState().get("types");o||(o=[],t.getVisitorParamsState().set("types",o)),o.push(r)}return r}parseType(t,e,s){switch(e.localName){case"areaChart":s.type="area";break;case"bubbleChart":s.type="bubble";break;case"doughnutChart":case"ofPieType":case"pieChart":s.type="pie";break;case"lineChart":s.type="line";break;case"scatterChart":s.type="scatter"}}parseAxisIds(t,e,s){const r=t.evaluate("axId",e);if(!r||r.length===0)return;const o=r.item(0).getAttribute("val");s.xAxisId=o;const i=r.item(1).getAttribute("val");s.yAxisId=i}}class J extends N{parseType(t,e,s){const r=t.getValAttrAsString("barDir",e);r&&(s.type=r==="col"?"column":"bar")}}class w{constructor(t){this.jsonKey=t}visit(t,e,s){let r={},o=r,i=t.getValAttrAsString("idx",e);i!==null&&(o={},o[i]=r);const n=t.getValAttrAsBoolean("delete",e);this.parseNumFormat(t,e,r),n===!0?(r.showBubbleSize=!1,r.showCatName=!1,r.showLeaderLines=!1,r.showPercentage=!1,r.showSerName=!1,r.showVal=!1,r.showLegendKey=!1):(f(t,e,r,"showBubbleSize","showBubbleSize"),f(t,e,r,"showCatName","showCatName"),f(t,e,r,"showLeaderLines","showLeaderLines"),f(t,e,r,"showPercent","showPercentage"),f(t,e,r,"showSerName","showSerName"),f(t,e,r,"showVal","showVal"),f(t,e,r,"showLegendKey","showLegendKey"));const l=t.evaluate("separator",e);return l!==null&&(r.separator=l.textContent),A(t,e,r,"dLblPos","position"),s[this.jsonKey]=o,r}parseNumFormat(t,e,s){const r=t.evaluate("numFmt",e);if(r){const o=r.getAttribute("formatCode");s.formatCode=o,r.hasAttribute("sourceLinked")&&(s.sourceLinked=r.getAttribute("sourceLinked")==="1")}}}const M=(u,t,e)=>{if(u.getValAttrAsBoolean("invertIfNegative",t)===!0)if(u.evaluate("extLst/ext/invertSolidFillFmt",t)){if(e.fill&&e.fillNegative){const s=u.getFromPath(e,"fill.solid.adjs");s&&u.setToPath(e,"fillNegative.solid.adjs",s)}}else{const s={val:"FFFFFF"},r={};r.solid=s,e.fillNegative=r;const o={val:"000000"},i={};i.solid=o;const n={};n.fill=i,e.strokeNegative=n}};class Q{visit(t,e,s){const r={};C(t,e,r,"explosion","explosion");let o=t.evaluate("cat/*/f",e);o||(o=t.evaluate("xVal/*/f",e));let i=null;o!==null&&o.firstChild!==null&&(i=o.firstChild.nodeValue),o||(o=t.evaluate("cat/strLit",e),o||(o=t.evaluate("cat/numLit",e)),o&&(i=this.parsePointsAsString(t,o))),i!==null&&(r.xRange=i);let n=t.evaluate("val/*/f",e);n||(n=t.evaluate("yVal/*/f",e));let l=null;n&&n.firstChild&&(l=n.firstChild.nodeValue),n||(n=t.evaluate("val/numLit",e),n!==null&&(l=this.parsePointsAsString(t,n))),l!==null&&(r.valRange=l),this.parseTitleRangeOrValue(t,e,r),C(t,e,r,"idx","idx"),f(t,e,r,"smooth","smooth");const a=t.getVisitorParamsState().get("types").length-1;r.offsetChart=a;let c=t.getVisitorParamsState().get("series");return c||(c=[],t.getVisitorParamsState().set("series",c)),c.push(r),r}parseTitleRangeOrValue(t,e,s){const r=t.evaluate("tx/strRef/f",e);if(r!==null){const o=r.firstChild.nodeValue;t.setToPath(s,"title.range",o)}else{const o=t.evaluate("tx/v",e);o!==null&&t.setToPath(s,"title.text.simpleRun",o.firstChild.nodeValue)}}parsePointsAsString(t,e){let s="{";const r=t.getValAttrAsInteger("ptCount",e),o=t.evaluate("pt",e),i=[];for(let n=0;o&&r&&n<r;n++){let l=null,a=t.evaluate("pt[@idx='"+n+"']/v",e);a instanceof Node&&(l=a.textContent),i[n]=l}for(let n=0;n<i.length;n++)n>0&&(s+=","),i[n]!==void 0&&(s+=i[n]);return s+="}",s}afterVisit(t,e,s){M(t,e,s);let r=t.getFromPath(s,"points");if(r){const o=Object.keys(r);for(let i=0;i<o.length;i++){const n=o[i],l=t.getFromPath(r,n);if(!l)continue;let a=t.getFromPath(l,"markers");a&&(t.setToPath(s,"markers.points."+n,a),delete l.markers)}}}}class tt{DataPointVisitor(){}visit(t,e,s){let r=t.getFromPath(s,"points"),o=null;r?o=r:(o={},t.setToPath(s,"points",o));let i={},n=t.getValAttrAsString("idx",e);return n!==null&&(o[n]=i),f(t,e,i,"bubble3D","bubble3D"),C(t,e,i,"explosion","explosion"),M(t,e,i),i}}class et{visit(t,e,s){const r=e.parentNode.localName;if(r==="ser"||r==="dPt"){const o={},i=t.getValAttrAsString("size",e);i!==null&&(o.size=i);const n=t.getValAttrAsString("symbol",e);return n&&(o.type=n),s.markers=o,o}return null}}class k{visit(t,e,s){let r={};this.parseScaling(t,e,r),y(t,e,r,"majorUnit","majorUnits"),y(t,e,r,"minorUnit","minorUnits"),f(t,e,r,"delete","shown"),this.parseOrientation(t,e,r),this.parseNumFormat(t,e,r),A(t,e,r,"majorTickMark","majorTickMarks"),A(t,e,r,"minorTickMark","minorTickMarks"),A(t,e,r,"crosses","crosses"),y(t,e,r,"crossesAt","crosses"),A(t,e,r,"crossBetween","crossBetween"),this.parseLabelAlign(t,e,r),C(t,e,r,"lblOffset","labelOffset"),A(t,e,r,"tickLblPos","labelPosition");const o=t.getValAttrAsInteger("noMultiLvlLbl",e);r.labelMultiLevel=o!==null&&o===0,C(t,e,r,"tickMarkSkip","tickMarkSkip"),C(t,e,r,"tickLblSkip","labelInterval"),this.parseDisplayCustOrBuiltInUnit(e,t,r),this.parseTimeUnits(t,e,r,"majorUnitDates","majorTimeUnit","majorUnit"),this.parseTimeUnits(t,e,r,"minorUnitDates","minorTimeUnit","minorUnit"),A(t,e,r,"baseTimeUnit","baseUnitDates"),t.getVisitorParamsState().get("axes")||t.getVisitorParamsState().set("axes",new Map);const i=t.getValAttrAsString("axId",e);return t.getVisitorParamsState().get("axes").set(i,r),r}parseTimeUnits(t,e,s,r,o,i){const n={};let l=t.getValAttrAsString(o,e);if(l!==null){n.dem=l;let a=t.getValAttrAsString(i,e);n.amt=a}Object.keys(n).length>0&&(s[r]=n)}parseDisplayCustOrBuiltInUnit(t,e,s){let r=e.getValAttrAsString("dispUnits/builtInUnit",t);r||(r=e.getValAttrAsString("dispUnits/custUnit",t)),r&&(s.displayUnits=r)}parseLabelAlign(t,e,s){let r=t.getValAttrAsString("lblAlgn",e);r!==null&&(r==="ctr"?s.labelAlign="center":r==="l"?s.labelAlign="left":r==="r"&&(s.labelAlign="right"))}parseOrientation(t,e,s){const r=t.getValAttrAsString("AxPos",e);r!==null&&(r==="b"?s.orientation="bottom":r==="l"?s.orientation="left":r==="r"?s.orientation="right":r==="t"&&(s.orientation="top"))}parseNumFormat(t,e,s){const r={},o=t.evaluate("numFmt",e);o!==null&&(o.hasAttribute("formatCode")&&(r.formatCode=o.getAttribute("formatCode")),o.hasAttribute("sourceLinked")&&(r.sourceLinked=o.getAttribute("sourceLinked")==="1")),Object.keys(r).length>0&&(s.labels=r)}parseScaling(t,e,s){const r=t.getValAttrAsString("scaling/orientation",e);r!==null&&(s.inverted=r!=="minMax");const o=t.getValAttrAsFloat("scaling/logBase",e);o!==null&&(s.logBase=o,s.scaleType="log"),y(t,e,s,"scaling/max","max"),y(t,e,s,"scaling/min","min")}afterVisit(t,e,s){s.fill&&s.labels&&(s.labels.fill=s.fill,delete s.fill);let r=t.getValAttrAsBoolean("delete",e);r!==null&&(t.setToPath(s,"labels.shown",r!==!0),t.setToPath(s,"shown",r!==!0));const o=t.getFromPath(s,"dispUnits.displayUnitsLabel");o&&(t.setToPath(s,"displayUnitsLabel",o),delete s.dispUnits);const i=t.evaluate("title",e);t.setToPath(s,"title.shown",i!==null);const n=t.evaluate("minorGridlines",e);t.setToPath(s,"gridLinesMinor.shown",n!==null);const l=t.evaluate("majorGridlines",e);t.setToPath(s,"gridLinesMajor.shown",l!==null)}}class F{constructor(t="text"){this._jsonKey=t}getTextPath(){return this._jsonKey}visit(t,e,s){let r=t.getFromPath(s,this.getTextPath());return r||(r={}),this.parseTextElement(t,e,r,!1),Object.keys(r).length>0&&t.setToPath(s,this.getTextPath(),r),s}parseTextElement(t,e,s,r){const o=t.evaluate("p/pPr/defRPr",e)??t.evaluate("defRPr",e);o&&(this.parseTextProperties(t,o,s),new L().visit(t,o,s));let i=[],n=t.evaluate("p/r",e)??t.evaluate("r",e);const l=c=>{const h={};let d=t.evaluate("t",c);const m=t.evaluate("rPr",c);m&&this.parseTextProperties(t,m,h),d?h.text=d.firstChild.textContent??"":c.textContent&&(h.text=c.textContent??""),i.push(h)};if(n?.length!==void 0)for(let c=0;n&&c<n.length;c++)l(n.item(c));else l(n||e);i.length>0&&(s.runs=i);const a=t.evaluate("bodyPr",e);a&&Y(a,s)}parseTextProperties(t,e,s){if(!e)return;e.hasAttribute("sz")&&(s.size=parseFloat(e.getAttribute("sz"))/100),e.hasAttribute("b")&&(s.weight=e.getAttribute("b")==="1"?700:400),e.hasAttribute("i")&&(s.italic=e.getAttribute("i")==="1"),e.hasAttribute("u")&&(s.underline=e.getAttribute("u")),e.hasAttribute("strike")&&(s.strike=e.getAttribute("strike"));const r=t.evaluate("latin",e);if(r&&!r.getAttribute("typeface").startsWith("+")){const o=s.font??{};if(r.hasAttribute("typeface")&&(o.family=r.getAttribute("typeface")),r.hasAttribute("panose")){const i=r.getAttribute("panose");i&&(o.fallbacks=[p.nt.getPanoseFallback(i)])}r.hasAttribute("pitchFamily")&&(o.pitch=r.getAttribute("pitchFamily")),r.hasAttribute("charset")&&(o.charset=r.getAttribute("charset")),Object.keys(o).length>0&&(s.font=o)}}}class rt{visit(t,e,s){let r=t.getVisitorParamsState().get("series")[t.getValAttrAsInteger("idx",e)];if(r){let o=t.getFromPath(r,"title");o||(o={},t.setToPath(r,"title",o));let i=o,n=t.getValAttrAsBoolean("delete",e);return n!==null&&(i.shown=!n),i}return s}}class st{visit(t,e,s){const r={};return f(t,e,r,"overlay","overlay"),A(t,e,r,"legendPos","position"),s.legend=r,r}}class ot extends L{visit(t,e,s){const r=this.processFill(t,e,s);Object.keys(r).length>0&&(s.fillNegative=r);const o=this.processStroke(t,e,s);return Object.keys(o).length>0&&(s.strokeNegative=o),s}}class _ extends F{constructor(t="title"){super(t)}parseTitleRangeOrValue(t,e,s){let r=t.evaluate("tx/strRef/f",e)??null;if(r){const o=r.firstElementChild.nodeValue;t.setToPath(s,"range",o)}}visit(t,e,s){const r={};f(t,e,r,"overlay","overlay"),s[this._jsonKey]=r;let o=t.getFromPath(r,this.getTextPath());o||(o={}),this.parseTitleRangeOrValue(t,e,r);const i=t.evaluate("txPr",e);i&&this.parseTextElement(t,i,o,!1);const n=t.evaluate("tx/rich",e);return n&&this.parseTextElement(t,n,o,!0),Object.keys(o).length>0&&t.setToPath(r,this.getTextPath(),o),r}afterVisit(t,e,s){if(s?.text){const r=s.text?.rotation??null;r!==null&&(s.rotation=parseInt(r),delete s.title.rotation)}}}class it{visit(t,e,s){const r=t.evaluate("manualLayout",e);if(r){let o={};y(t,r,o,"x","x"),y(t,r,o,"y","y"),y(t,r,o,"w","w"),y(t,r,o,"h","h"),A(t,r,o,"xMode","xMode"),A(t,r,o,"yMode","yMode"),A(t,r,o,"wMode","wMode"),A(t,r,o,"hMode","hMode"),Object.keys(o).length>0&&(s.manualLayout=o)}return s}}class nt{visit(t,e,s){return s.name=e.getAttribute("name"),s}}class lt extends D{visit(t,e,s){const r={};r.name=e.getAttribute("name");const o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1){let l=n.localName;const a=t.evaluate(l,e),c=this.processAdjColor(t,a);r[l]=c}}return Object.keys(r).length>0&&(s.colors=r),r}}class at{visit(t,e,s){const r={};r.name=e.getAttribute("name");const o=t.evaluate("majorFont",e),i=this.processFontElement(t,o,{});r.majorFont=i.family,i.fallbacks&&(r.majorFallbacks=i.fallbacks);const n=t.evaluate("minorFont",e),l=this.processFontElement(t,n,{});return r.minorFont=l.family,i.fallbacks&&(r.minorFallbacks=l.fallbacks),s.fonts=r,r}processFontElement(t,e,s){if(!e)return;const r=t.evaluate("latin",e);if(!r)return;const o=r.getAttribute("typeface");o&&(s.family=o);const i=r.getAttribute("panose");return i&&(s.fallbacks=[p.nt.getPanoseFallback(i)]),s}}class ct{visit(t,e,s){if(!e)return;const r={},o=e.getAttribute("r:id");if(o){const i=t.getRef(o);typeof i=="string"&&(r.address=i)}return t.copyFromAttribute(e,"tooltip",r),t.copyFromAttribute(e,"history",r,"history",t.BOOLEAN_COPY),t.copyFromAttribute(e,"tgtFrame",r,"target"),s.hyperlink=r,r}}class ut{visit(t,e,s){if(!e)return;const r={};return t.copyFromAttribute(e,"ref",r),this.processFilterColumns(t,e,r),Object.keys(r).length>0&&(s.filter=r),r}processColorFilter(t,e){const s={type:p.ud.Type.Color};return t.copyFromAttribute(e,"cellColor",s,"cellColor",t.BOOLEAN_COPY),t.copyFromAttribute(e,"dxfId",s,"styleId",t.INT_COPY),s}processCustomFilter(t,e){const s={};return t.copyFromAttribute(e,"operator",s,"operator",t.BOOLEAN_COPY),t.copyFromAttribute(e,"val",s,"val"),s}processCustomFilters(t,e){const s={type:p.ud.Type.Custom};t.copyFromAttribute(e,"and",s,"and",t.BOOLEAN_COPY);const r=e.childNodes;s.filters=[];for(let o=0;o<r.length;o++){const i=r.item(o);if(i.nodeType!==1)continue;let n=null;i.localName==="customFilter"&&(n=this.processCustomFilter(t,i)),n&&s.filters.push(n)}return s}processDynamicFilter(t,e){const s={type:p.ud.Type.Dynamic};return t.copyFromAttribute(e,"type",s,"dynamicType"),t.copyFromAttribute(e,"val",s,"val",t.INT_COPY),t.copyFromAttribute(e,"maxVal",s,"maxVal",t.INT_COPY),s}processDateGroupItem(t,e){const s={};return t.copyFromAttribute(e,"dateTimeGrouping",s,"group"),t.copyFromAttribute(e,"day",s,"day",t.INT_COPY),t.copyFromAttribute(e,"hour",s,"hour",t.INT_COPY),t.copyFromAttribute(e,"minute",s,"minute",t.INT_COPY),t.copyFromAttribute(e,"month",s,"month",t.INT_COPY),t.copyFromAttribute(e,"second",s,"second",t.INT_COPY),t.copyFromAttribute(e,"year",s,"year",t.INT_COPY),s}processFilterItem(t,e){if(e.hasAttribute("val"))return e.getAttribute("val")}processFilters(t,e){const s={type:p.ud.Type.Items};t.copyFromAttribute(e,"blank",s,"blank",t.BOOLEAN_COPY),t.copyFromAttribute(e,"calendarType",s,"calendarType");let r=[],o=[];const i=e.childNodes;for(let n=0;n<i.length;n++){const l=i.item(n);if(l.nodeType===1){if(l.localName==="dateGroupItem"){const a=this.processDateGroupItem(t,l);a&&r.push(a)}else if(l.localName==="filter"){const a=this.processFilterItem(t,l);a!==void 0&&o.push(a)}}}return r.length>0&&(s.dateGroups=r),o.length>0&&(s.items=o),s}processIcon(t,e){const s={type:p.ud.Type.Icon};return t.copyFromAttribute(e,"iconId",s,"iconId",t.INT_COPY),t.copyFromAttribute(e,"iconSet",s),s}processTop10(t,e){const s={type:p.ud.Type.Top10};return t.copyFromAttribute(e,"filterVal",s,"filterVal",t.FLOAT_COPY),t.copyFromAttribute(e,"percent",s,"percent",t.BOOLEAN_COPY),t.copyFromAttribute(e,"top",s,"top",t.BOOLEAN_COPY),t.copyFromAttribute(e,"val",s,"val",t.FLOAT_COPY),s}processFilterCriteria(t,e,s){if(!e)return;const r=e.childNodes,o=[];for(let i=0;i<r.length;i++){const n=r.item(i);if(n.nodeType!==1)continue;let l=null;n.localName==="colorFilter"?l=this.processColorFilter(t,n):n.localName==="customFilters"?l=this.processCustomFilters(t,n):n.localName==="dynamicFilter"?l=this.processDynamicFilter(t,n):n.localName==="filters"?l=this.processFilters(t,n):n.localName==="iconFilter"?l=this.processIcon(t,n):n.localName==="top10"&&(l=this.processTop10(t,n)),l&&o.push(l)}return o.length>0&&(s.criteria=o),o}processFilterColumn(t,e){if(!e)return null;const s={};if(!e.hasAttribute("colId"))return;s.offset=parseInt(e.getAttribute("colId"));let r=!1;return e.hasAttribute("hiddenButton")&&(r=g.b(e.getAttribute("hiddenButton"))),r&&(s.hiddenButton=!0),e.hasAttribute("showButton")&&(s.showButton=g.b(e.getAttribute("showButton"))),this.processFilterCriteria(t,e,s),s}processFilterColumns(t,e,s){if(!e)return;const r=e.childNodes,o=[];for(let i=0;i<r.length;i++){const n=r.item(i);if(n.nodeType===1&&n.localName==="filterColumn"){const l=this.processFilterColumn(t,n);l&&o.push(l)}}return o.length>0&&(s.fields=o),o}}class ht{visit(t,e,s){if(!e)return;const r={};if(t.copyFromAttribute(e,"ref",r),e.hasAttribute("caseSensitive")){const n=g.b(e.getAttribute("caseSensitive"));r.collatorOptions=n?p.Gr.CaseSensitiveOptions:p.Gr.CaseInsensitiveOptions}const o=e.getAttribute("sortMethod");o!=null&&o!=="none"&&(o==="stroke"?r.collatorOptions={...r.collatorOptions,collation:"stroke"}:o==="pinYin"&&(r.collatorOptions={...r.collatorOptions,collation:"pinyin"})),e.hasAttribute("columnSort")&&g.b(e.getAttribute("columnSort"))&&(r.orientation=p.w.Orientation.Column);const i=p.Yr.fastStringToRange(r.ref);return this.processSortConditions(t,e,r,i),Object.keys(r).length>0&&(s.sort=r),r}processSortCondition(t,e,s){if(!e)return null;const r={};if(e.hasAttribute("ref")){if(e.hasAttribute("ref")){const o=e.getAttribute("ref"),i=p.Yr.fastStringToRange(o);r.offset=s?i.colStart-s.colStart:i.colStart}return r.reverse=!1,e.hasAttribute("descending")&&(r.reverse=g.b(e.getAttribute("descending"))),t.copyFromAttribute(e,"sortBy",r,"sortOn"),t.copyFromAttribute(e,"dxfId",r),t.copyFromAttribute(e,"iconSet",r),t.copyFromAttribute(e,"customList",r),r}console.warn("no ref for sort conditional",t.getPath())}processSortConditions(t,e,s,r){if(!e)return;const o=e.childNodes,i=[];for(let n=0;n<o.length;n++){const l=o.item(n);if(l.nodeType===1&&l.localName==="sortCondition"){const a=this.processSortCondition(t,l,r);a&&i.push(a)}}return i.length>0&&(s.fields=i),i}}class U{visit(t,e,s){}processDataBarColor(t,e,s,r,o="dk1"){if(!e)return;const i=g.d(n=>e.getAttribute(n),o);return i&&(s[r]=i),s}processFonts(t,e,s){if(!e)return;const r=e.childNodes;let o=0;for(let i=0;i<r.length;i++){const n=r.item(i);if(n.nodeType===1&&n.localName==="font"){const l={};this.processFont(t,n,l),s[o++]=l}}return s}processFont(t,e,s){t.getValAttrAsBoolean("b",e,!0)&&(s.weight=700),t.getValAttrAsBoolean("i",e,!0)&&(s.style=p.nt.Style.Italic),t.getValAttrAsBoolean("strike",e,!0)&&(s.strike=!0);const r=t.evaluate("u",e);if(r){const n=r.getAttribute("val");s.underline=n||p.nt.UnderlineStyle.Single}A(t,e,s,"vertAlign","verticalAlign"),s.verticalAlign==="superscript"?s.verticalAlign=p.nt.VerticalAlignment.Super:s.verticalAlign==="subscript"&&(s.verticalAlign=p.nt.VerticalAlignment.Sub),y(t,e,s,"sz","size");const o=t.evaluate("color",e);this.processDataBarColor(t,o,s,"fill"),s.fill||(s.fill="dk1"),A(t,e,s,"name","family"),A(t,e,s,"rFont","family");const i=t.evaluate("family",e);if(i){const n=i.getAttribute("val");if(n)switch(n){case"1":s.fallbacks=["serif"];break;case"2":s.fallbacks=["sans-serif"];break;case"3":s.fallbacks=["monospace"];break;case"4":s.fallbacks=["cursive"];break;case"5":s.fallbacks=["fantasy"]}}return A(t,e,s,"scheme","scheme"),f(t,e,s,"shadow","shadow",!0),f(t,e,s,"outline","outline",!0),t.getValAttrAsBoolean("condense",e,!0)&&(s.letterSpacing=-1),t.getValAttrAsBoolean("extend",e,!0)&&(s.letterSpacing=1),A(t,e,s,"charset","charset"),s}processFills(t,e,s){if(!e)return;const r=e.childNodes;let o=0;for(let i=0;i<r.length;i++){const n=r.item(i);n.nodeType===1&&n.localName==="fill"&&this.processFill(t,n,s,o++)}return s}processFill(t,e,s,r){const o={type:p.Z$1.Type.None},i=e.childNodes;let n=!1;for(let l=0;!n&&l<i.length;l++){const a=i.item(l);a.nodeType===1&&(a.localName==="gradientFill"?(this.processGradientFill(t,a,o),n=!0):a.localName==="patternFill"&&(this.processPatternFill(t,a,o),n=!0))}return s[r]=o,s}processGradientFill(t,e,s){if(!e)return;s.type=p.Z$1.Type.Gradient;const r=[];s.stops=r,s.angle=90+(e.hasAttribute("degree")?parseFloat(e.getAttribute("degree")):0);const o=e.getAttribute("type");o&&(s.gradientType=o);const i=l=>{if(!l)return 0;const a=parseFloat(l);return isNaN(a)?0:a};(e.hasAttribute("left")||e.hasAttribute("top")||e.hasAttribute("right")||e.hasAttribute("bottom"))&&(s.fillTo={left:i(e.getAttribute("left")),top:i(e.getAttribute("top")),right:i(e.getAttribute("right")),bottom:i(e.getAttribute("bottom"))});const n=e.childNodes;for(let l=0;l<n.length;l++){const a=n.item(l);if(a.nodeType===1&&a.localName==="stop"){const c={};r.push(c);const h=parseFloat(a.getAttribute("position"));c.offset=h;const d=t.evaluate("color",a);this.processDataBarColor(t,d,c,"color")}}return s}processPatternFill(t,e,s){if(!e)return;const r=t.getVisitorParamsState().get("processingDXFs"),o=e.getAttribute("patternType")||(r?p.Z$1.BuiltInSheetPattern.Solid:p.Z$1.BuiltInSheetPattern.None);if(o===p.Z$1.BuiltInSheetPattern.None)return{none:!0};s.type=p.Z$1.Type.Pattern,o&&(s.patternType=o);let i,n="foreground",l="background";const a=s.patternType===p.Z$1.BuiltInSheetPattern.Solid&&r;if(a){i="lt1";const d=n;n=l,l=d}const c=t.evaluate("fgColor",e);this.processDataBarColor(t,c,s,n,i);const h=t.evaluate("bgColor",e);return this.processDataBarColor(t,h,s,l,i),a&&!s.foreground&&(s.foreground=i),s}processBorders(t,e,s,r){if(!e)return;const o=e.childNodes;let i=0;for(let n=0;n<o.length;n++){const l=o.item(n);l.nodeType===1&&l.localName==="border"&&this.processBorder(t,l,s,i++,r)}return s}processBorder(t,e,s,r,o){if(!e)return;const i={};return this.processBorderStroke(t,e,i,p.U.Edge.Left),this.processBorderStroke(t,e,i,p.U.Edge.Right),o?(i.right||i.left)&&(i.right?i.vertical={...i.right}:i.vertical={...i.left}):this.processBorderStroke(t,e,i,p.U.Edge.Vertical),this.processBorderStroke(t,e,i,p.U.Edge.Top),this.processBorderStroke(t,e,i,p.U.Edge.Bottom),o?(i.bottom||i.top)&&(i.right?i.horizontal={...i.bottom}:i.horizontal={...i.top}):this.processBorderStroke(t,e,i,p.U.Edge.Horizontal),s[r]=i,s}processBorderStroke(t,e,s,r){if(!e)return;const o=t.evaluate(r,e);if(!o)return;const i={};o.hasAttribute("style")&&(i.style=o.getAttribute("style"));const n=t.evaluate("color",o);return n&&this.processDataBarColor(t,n,i,"color"),Object.keys(i).length>0?s[r]=i:null}}class pt extends U{visit(t,e,s){this.processNumFmts(t,t.evaluate("numFmts",e),null),t.getVisitorParamsState().set("colorsToProcess",new Set);const r={fills:{},fonts:{},borders:{}};this.processFonts(t,t.evaluate("fonts",e),r.fonts),this.processFills(t,t.evaluate("fills",e),r.fills),this.processBorders(t,t.evaluate("borders",e),r.borders,!0),r.fills[0]={type:p.Z$1.Type.None},r.fills[1]={type:p.Z$1.Type.Pattern,patternType:p.Z$1.BuiltInSheetPattern.Gray125},r.borders[0]={};const o=[];this.processXFs(t,t.evaluate("cellStyleXfs",e),o,r,null,!1);const i=new Map;if(o.length>0){const a=[];this.processCellStyles(t,t.evaluate("cellStyles",e),a,o,i),s.named=a}const n=[];this.processXFs(t,t.evaluate("cellXfs",e),n,r,i),Object.keys(n).length>0&&(s.direct=n);const l=[];return this.processDXFs(t,t.evaluate("dxfs",e),l),this.processTableStyles(t,t.evaluate("tableStyles",e),s,l),this.processIndexColors(t,t.evaluate("colors/indexedColors",e),s),this.processMruColors(t,t.evaluate("colors/mruColors",e),s),s}processIndexColors(t,e,s){if(!e)return;const r=[],o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1&&n.localName==="rgbColor"){const l={color:null};this.processDataBarColor(t,n,l,"color"),l.color&&r.push(l.color)}}s.indexedColors=r}processMruColors(t,e,s){if(!e)return;const r=[],o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1&&n.localName==="color"){const l={color:null};this.processDataBarColor(t,n,l,"color"),l.color&&r.push(l.color)}}r.length>0&&(s.mruColors=r)}processNumFmts(t,e,s){if(!e)return;const r=new Map;if(t.getVisitorParamsState().set("numFmts",r),!e)return;const o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1&&n.localName==="numFmt"){const l=n.getAttribute("numFmtId"),a=n.getAttribute("formatCode");if(l&&a){const c=a.replace(/\\(.)/g,"$1");r.set(parseInt(l),c)}}}}processXFs(t,e,s,r,o=null,i=!0){if(!e)return;const n=e.childNodes;for(let l=0;l<n.length;l++){const a=n.item(l);if(a.nodeType===1&&a.localName==="xf"){const c={};this.processXF(t,a,c,r,o,i),s.push(c)}}}processXF(t,e,s,r,o,i){if(!e)return;const n=e.getAttribute("xfId");if(n&&o){const c=o.get(parseInt(n));c&&c!==p.lt.BuiltInName.Normal&&(s.named=c)}const l=c=>!(!i&&e.hasAttribute(c))||g.b(e.getAttribute("applyFont"));if(l("applyFont")){const c=r.fonts[e.getAttribute("fontId")];c&&(s.font=c)}if(l("applyFill")){const c=r.fills[e.getAttribute("fillId")];c&&Object.keys(c).length>0&&(s.fill=c)}if(l("applyBorder")){const c=r.borders[e.getAttribute("borderId")];c&&Object.keys(c).length>0&&(s.border=c)}if(l("applyNumberFormat")){const c=e.getAttribute("numFmtId");if(c){const h=parseInt(c);let d;const m=t.getVisitorParamsState();if(m){const b=m.get("numFmts");b&&(d=b.get(h)),s.numberFormat=d??h}else console.warn("no visitor params state")}}l("applyAlignment")&&this.processAlignment(t,t.evaluate("alignment",e),s),l("applyProtection")&&this.processProtection(t,t.evaluate("protection",e),s);const a=g.b(e.getAttribute("quotePrefix"));a&&(s.quotePrefix=a)}processAlignment(t,e,s){const r={};if(e?.hasAttribute("horizontal")?r.horizontal=e.getAttribute("horizontal"):r.horizontal=p.X.HorizontalAlignment.General,e?.hasAttribute("vertical")?r.vertical=e.getAttribute("vertical"):r.vertical=p.X.VerticalAlignment.Bottom,e?.hasAttribute("indent")?r.indent=parseInt(e.getAttribute("indent")):r.indent=0,e?.hasAttribute("relativeIndent")?r.relativeIndent=parseInt(e.getAttribute("relativeIndent")):r.relativeIndent=0,g.b(e?.getAttribute("wrapText"))?r.overflow=p.X.Overflow.Wrap:r.overflow=p.X.Overflow.Visible,g.b(e?.getAttribute("shrinkToFit"))&&(r.overflow=p.X.Overflow.Shrink),e?.hasAttribute("textRotation")){let i=parseFloat(e.getAttribute("textRotation"));i>0&&i<=90?i=360-i:i>90&&i<=180?i-=90:i===255&&(i=0,r.stacked=!0),r.rotation=i}else r.rotation=0;e?.hasAttribute("justifyLastLine")&&(r.justifyLastLine=g.b(e.getAttribute("justifyLastLine")));const o=e?.getAttribute("readingOrder");return o&&(o==="0"?r.readingDirection=p.X.ReadingDirection.Auto:o==="1"?r.readingDirection=p.X.ReadingDirection.LeftToRight:o==="2"?r.readingDirection=p.X.ReadingDirection.RightToLeft:console.warn(`invalid readingOrder: ${o}`)),Object.keys(r).length>0&&(s.alignment=r),s}processProtection(t,e,s){if(!e)return;const r={},o=e.getAttribute("locked");o&&!g.b(o)&&(r.edit=!0);const i=e.getAttribute("hidden");return i&&g.b(i)&&(r.formulaHidden=!0),Object.keys(r).length>0&&(s.protection=r),s}processDXF(t,e,s){if(!e)return;const r=e.childNodes;for(let o=0;o<r.length;o++){const i=r.item(o);if(i.nodeType===1&&i.localName==="font"){const n={};this.processFont(t,i,n),s.font=n}else if(i.nodeType===1&&i.localName==="fill"){const n=[];this.processFill(t,i,n,0),n.length>0&&n[0]&&(s.fill=n[0])}else if(i.nodeType===1&&i.localName==="border"){const n=[];this.processBorder(t,i,n,0,!1),n.length>0&&n[0]&&(s.border=n[0])}}}processDXFs(t,e,s){if(!e)return;t.getVisitorParamsState().set("processingDXFs",!0);const r=new Map;t.getVisitorParamsState().set("dxfs",r);const o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1&&n.localName==="dxf"){const l={};this.processDXF(t,n,l);const a=s.length;r.set(a,l),s.push(l)}}t.getVisitorParamsState().delete("processingDXFs")}processTableStyle(t,e,s,r,o=!1){const i=e.getAttribute("name"),n={name:i};e.hasAttribute("table")&&(n.table=g.b(e.getAttribute("table"))),e.hasAttribute("pivot")&&(n.pivot=g.b(e.getAttribute("pivot"))),o&&!n.pivot&&r.unshift(null);const l=e.childNodes;for(let a=0;a<l.length;a++){const c=l.item(a);if(c.nodeType===1&&c.localName==="tableStyleElement"){const h=c.getAttribute("type"),d=c.getAttribute("dxfId");let m=r?.[d];m||(console.warn("invalid dfx id",d),m={}),n[h]=m;let b=null;c.hasAttribute("size")&&(b=parseInt(c.getAttribute("size"))),b&&!isNaN(b)&&(m.size=b)}}delete n.name,s[i]=n}processTableStyles(t,e,s,r,o){if(!e)return;const i={},n=e.getAttribute("defaultTableStyle");n&&(i.defaultTableStyle=n);const l=e.getAttribute("defaultPivotStyle");l&&(i.defaultPivotStyle=l);const a=e.childNodes,c={};for(let h=0;h<a.length;h++){const d=a.item(h);d.nodeType===1&&d.localName==="tableStyle"&&this.processTableStyle(t,d,c,r,o)}return Object.keys(c).length>0&&(i.styles=c),Object.keys(i).length>0&&(s.tables=i),s}processCellStyles(t,e,s,r,o){if(!e)return;const i=e.childNodes;for(let n=0;n<i.length;n++){const l=i.item(n);if(l.nodeType===1&&l.localName==="cellStyle"){const a=parseInt(l.getAttribute("xfId")),c=l.getAttribute("name");if(o.set(a,c),!r[a])continue;const h={name:c,style:r[a]};l.getAttribute("hidden")&&(h.hidden=g.b(l.getAttribute("hidden"))),l.getAttribute("iLevel")&&(h.iLevel=parseInt(l.getAttribute("iLevel"))),s.push(h)}}}afterVisit(t,e,s){}}class gt extends U{visit(t,e,s){return this.processSheetRefs(t,t.evaluate("sheets",e),s),this.processBookViews(t,t.evaluate("bookViews",e),s),this.processDefinedNames(t,t.evaluate("definedNames",e),s),this.processCalcPr(t,t.evaluate("calcPr",e),s),this.processWorkbookProtection(t,t.evaluate("workbookProtection",e),s),this.processWorkbookPr(t,t.evaluate("workbookPr",e),s),s}processPassword(t,e,s,r="password"){if(!e)return;const o={};t.copyFromAttribute(e,"algorithmName",o,"algorithmName"),t.copyFromAttribute(e,"hashValue",o,"hashValue"),t.copyFromAttribute(e,"saltValue",o,"saltValue",t.BOOLEAN_COPY),t.copyFromAttribute(e,"spinCount",o,"spinCount",t.INT_COPY),Object.keys(o).length>0&&(s[r]=o)}processWorkbookProtection(t,e,s){if(!e)return;const r={};this.processPassword(t,t.evaluate("workbookPassword",e),r),this.processPassword(t,t.evaluate("revisionsPassword",e),r,"revisionsPassword");const o=i=>i!==!0&&i!=="1"&&i!=="on"&&i!=="true"&&(i===!1||i==="0"||i==="off"||i==="false"||null);return t.copyFromAttribute(e,"lockStructure",r,"structure",o),t.copyFromAttribute(e,"lockWindows",r,"windows",o),t.copyFromAttribute(e,"lockRevision",r,"revision",o),s.protection=r,s}processCalcPr(t,e,s){e&&(s.calc={})}processSheetRefs(t,e,s){if(!e)return;const r=[],o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);n.nodeType===1&&n.localName==="sheet"&&this.processSheetRef(t,n,r)}s.sheets=r}processSheetRef(t,e,s){const r={};t.copyFromAttribute(e,"name",r,"name"),t.copyFromAttribute(e,"state",r,"visibility");const o=e.getAttribute("r:id"),i=t.getRef(o);i&&(r.sheet=i),s.push(r)}processBookViews(t,e,s){if(!e)return;const r=e.childNodes;let o=0;for(let i=0;o<1&&i<e.childNodes.length;i++){const n=r.item(i);n.nodeType===1&&n.localName==="workbookView"&&(this.processWorkbookView(t,n,s),o++)}}processWorkbookView(t,e,s){if(!e)return;const r={};t.copyFromAttribute(e,"activeTab",r,"activeSheetId",[t.INT_COPY,o=>o+1]),e.hasAttribute("activeTab")||(r.activeSheetId=1),t.copyFromAttribute(e,"showHorizontalScroll",r,"showHorizontalScrollbar",t.BOOLEAN_COPY),t.copyFromAttribute(e,"showVerticalScroll",r,"showVerticalScrollbar",t.BOOLEAN_COPY),t.copyFromAttribute(e,"showSheetTabs",r,"showTabs",t.BOOLEAN_COPY),t.copyFromAttribute(e,"tabRatio",r,"tabRatio",[t.FLOAT_COPY,o=>o]),Object.keys(r).length>0&&(s.view=r)}processDefineName(t,e,s,r){if(!e)return;const o={},i=e.firstChild;if(i&&i.nodeType===3&&(o.ref=i.textContent),t.copyFromAttribute(e,"name",o),t.copyFromAttribute(e,"comment",o),t.copyFromAttribute(e,"hidden",o,"hidden",t.BOOLEAN_COPY),e.hasAttribute("localSheetId")){const n=e.getAttribute("localSheetId");if(!r[n]?.name)return void console.warn(`Defined name '${e.getAttribute("name")}' references a sheet with localSheetId '${n}' which does not exist.`);o.scope=r[n].name}t.copyFromAttribute(e,"customMenu",o),t.copyFromAttribute(e,"description",o),t.copyFromAttribute(e,"statusBar",o),t.copyFromAttribute(e,"help",o),t.copyFromAttribute(e,"shortcutKey",o),t.copyFromAttribute(e,"function",o,"function",t.BOOLEAN_COPY),t.copyFromAttribute(e,"functionGroupId",o,"functionGroupId",t.INT_COPY),t.copyFromAttribute(e,"publishToServer",o,"publishToServer",t.BOOLEAN_COPY),t.copyFromAttribute(e,"vbProcedure",o,"vbProcedure",t.BOOLEAN_COPY),t.copyFromAttribute(e,"xlm",o,"xlm",t.BOOLEAN_COPY),Object.keys(o).length>0&&s.push(o)}processDefinedNames(t,e,s){if(!e)return;const r=[],o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);n.nodeType===1&&n.localName==="definedName"&&this.processDefineName(t,n,r,s.sheets)}r.length>0&&(s.names=r)}processWorkbookPr(t,e,s){e&&t.copyFromAttribute(e,"date1904",s,"date1904",t.BOOLEAN_COPY)}afterVisit(t,e,s){}}class dt{visit(t,e,s){return t.copyFromAttribute(e,"name",s),t.copyFromAttribute(e,"displayName",s),t.copyFromAttribute(e,"ref",s),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),s}processTableStyleInfo(t,e,s){if(!e)return;const r=e.childNodes,o={};for(let i=0;i<r.length;i++){const n=r.item(i);n.nodeType===1&&n.localName==="tableStyleInfo"&&(t.copyFromAttribute(n,"name",o),t.copyFromAttribute(n,"showColumnStripes",o,"showColumnStripes",t.BOOLEAN_COPY),t.copyFromAttribute(n,"showFirstColumn",o,"showFirstColumn",t.BOOLEAN_COPY),t.copyFromAttribute(n,"showLastColumn",o,"showLastColumn",t.BOOLEAN_COPY),t.copyFromAttribute(n,"showRowStripes",o,"showRowStripes",t.BOOLEAN_COPY))}Object.keys(o).length>0&&(s.styleOptions=o)}processTableColumn(t,e,s){if(!e)return null;const r=e.childNodes;for(let o=0;o<r.length;o++){const i=r.item(o);if(i.nodeType===1&&i.localName==="tableColumn"){const n={};t.copyFromAttribute(i,"name",n),t.copyFromAttribute(i,"uniqueName",n),s.push(n)}}return s}processTableColumns(t,e,s){const r=e.childNodes,o=[];for(let i=0;i<r.length;i++){const n=r.item(i);n.nodeType===1&&n.localName==="tableColumns"&&this.processTableColumn(t,n,o)}o.length>0&&(s.columns=o)}}class mt{visit(t,e,s){return s}}class x{visit(t,e,s){if(!e)return;const r={};return t.copyFromAttribute(e,"editAs",r,"anchorType"),r.anchor={},this.processOffsetCoord(t,t.evaluate("from",e),r.anchor,"from"),this.processOffsetCoord(t,t.evaluate("to",e),r.anchor,"to"),s.movables||(s.movables=[]),s.movables.push(r),r}processOffsetCoord(t,e,s,r){if(!e)return;const o={c:0,r:0,x:0,y:0};return t.evaluate("col",e)&&(o.c=parseInt(t.evaluate("col",e).textContent)),t.evaluate("row",e)&&(o.r=parseInt(t.evaluate("row",e).textContent)),t.evaluate("colOff",e)&&(o.x=g.c(t.evaluate("colOff",e).textContent)),t.evaluate("rowOff",e)&&(o.y=g.c(t.evaluate("rowOff",e).textContent)),r==="from"?s.tl=o:s.br=o,s}}class I{visit(t,e,s){if(!e)return;const r=t.evaluate("*/cNvPr",e);return r&&(t.copyFromAttribute(r,"name",s),t.copyFromAttribute(r,"desc",s),t.copyFromAttribute(r,"hidden",s,"hidden",t.BOOLEAN_COPY),t.copyFromAttribute(r,"id",s)),s}}class bt extends I{visit(t,e,s){if(!e)return;s=super.visit(t,e,s);const r=t.evaluate("nvGraphicFramePr/cNvGraphicFramePr",e);if(r){const n=t.evaluate("graphicFrameLocks",r);if(n){n.hasAttribute("noChangeAspect")&&(s.lockAspect=n.getAttribute("noChangeAspect")==="1");const l={};Object.keys(l).length>0&&(s.locks=l)}}let o={type:"graphicFrame",json:{}};const i=t.evaluate("graphic/graphicData",e).childNodes;for(let n=0;n<i.length;n++){const l=i.item(n);if(l.nodeType===1)try{let a=l.localName;a==="chart"&&(a="chart"),o.type=a;const c=l.getAttribute("r:id");c&&(o.json=t.getRef(c))}catch(a){console.warn("Unable to parse graphicFrame",a)}}return o&&(s.content=o),o}}class B extends I{visit(t,e,s){if(!e)return;s=super.visit(t,e,s);const r=t.evaluate("nvSpPr/cNvSpPr",e);if(r){const i=t.evaluate("spLocks",r);if(i){i.hasAttribute("noChangeAspect")&&(s.lockAspect=i.getAttribute("noChangeAspect")==="1");const n={};Object.keys(n).length>0&&(s.locks=n)}}t.warn(`Unable to import '${s.name}', shapes are not supported.`);const o={};return s.content={type:"sp",json:o},o}}class ft extends I{visit(t,e,s){if(!e)return;const r=super.visit(t,e,s),o=t.evaluate("nvPicPr/cNvPicPr",e);if(o){t.copyFromAttribute(e,"preferRelativeResize",r,"preferRelativeResize",t.BOOLEAN_COPY);const a=t.evaluate("picLocks",o);if(a){a.hasAttribute("noChangeAspect")&&(r.lockAspect=a.getAttribute("noChangeAspect")==="1");const c={};t.copyFromAttribute(a,"noChangeArrowheads",r,"noChangeArrowheads",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noChangeShapeType",r,"noChangeShapeType",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noEditPoints",r,"noEditPoints",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noAdjustHandles",r,"noAdjustHandles",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noCrop",r,"noCrop",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noGrp",r,"noGrp",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noMove",r,"noMove",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noResize",r,"noResize",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noRot",r,"noRot",t.BOOLEAN_COPY),t.copyFromAttribute(a,"noSelect",r,"noSelect",t.BOOLEAN_COPY),Object.keys(c).length>0&&(r.locks=c)}}const i=t.evaluate("blipFill/blip",e);let n;if(i){const a=i.getAttribute("r:embed")??i.getAttribute("embed");if(!a)return void console.warn("no rId found for blip",i);n=t.getRef(a,!0)}const l={resId:n};return s.content={type:"picture",json:l},r}}class At extends B{visit(t,e,s){if(!e)return;s=super.visit(t,e,s);const r=t.evaluate("nvGrpSpPr/cNvGrpSpPr",e);if(r){const i=t.evaluate("grpSpLocks",r);if(i){i.hasAttribute("noChangeAspect")&&(s.lockAspect=i.getAttribute("noChangeAspect")==="1");const n={};Object.keys(n).length>0&&(s.locks=n)}}t.warn(`Unable to import '${s.name}', group shapes are not supported.`);const o={};return s.content={type:"grpSp",json:o},o}}class yt extends B{visit(t,e,s){if(!e)return;s=super.visit(t,e,s);const r=t.evaluate("nvCxnSpPr/cNvCxnSpPr",e);if(r){const i=t.evaluate("cxnSpLocks",r);if(i){i.hasAttribute("noChangeAspect")&&(s.lockAspect=i.getAttribute("noChangeAspect")==="1");const n={};Object.keys(n).length>0&&(s.locks=n)}}t.warn(`Unable to import '${s.name}', connection shapes are not supported.`);const o={};return s.content={type:"cxnSp",json:o},o}}const j="richTypes";class vt{visit(t,e,s){let r=t.getVisitorParamsState().get(j);r||(r=[],t.getVisitorParamsState().set(j,r));const o=e.childNodes,i=o.length;for(let n=0;n<i;n++){const l=o.item(n);if(l.nodeType===1&&l.localName==="s"){const a={type:l.getAttribute("t")??"n",keys:[]};this.processKeys(t,l,a),r.push(a)}}return s.richTypes=r,r}processKeys(t,e,s){const r=e.childNodes,o=r.length,i=s.keys;for(let n=0;n<o;n++){const l=r.item(n);if(l.nodeType===1&&l.localName==="k"){const a=l.getAttribute("n"),c=l.getAttribute("t");i.push([a,c])}}}}const R="richData";class Ft{visit(t,e,s){let r=t.getVisitorParamsState().get("richTypes");if(!r)return void t.warn("RichValueFound but not type.");let o=t.getVisitorParamsState().get(R);o||(o=[],t.getVisitorParamsState().set(R,o));const i=e.childNodes,n=i.length;for(let l=0;l<n;l++){const a=i.item(l);if(a.nodeType===1&&a.localName==="rv"){const c=r[a.getAttribute("s")],h={type:c.type};this.processValues(t,a,h,c);const d=this.mapType(t,h);o.push(d)}}return s.richData=o,o}mapType(t,e){if(e.type==="_error"){const s=e.errorType;if(s)try{e=p.n.getBuiltInById(s+1)}catch{}}return e}processValues(t,e,s,r){const o=e.childNodes,i=o.length;r.type;const n=r.keys;for(let l=0;l<i;l++){const a=o.item(l);if(a.nodeType===1&&a.localName==="v"){const c=n[l];if(!c)return void t.warn("Invalid richData");const h=c[0],d=c[1];let m=a.textContent;d==="i"&&(m=Number(m)),s[h]=m}}}}class Ct{visit(t,e,s){if(!e)return;const r=[];return this.processAuthors(t,t.evaluate("authors",e),r),r.length>0&&(s.authors=r),s.comments=[],s}processAuthors(t,e,s){if(!e)return;const r=e.childNodes;for(let o=0;o<r.length;o++){const i=r.item(o);if(i.nodeType===1&&i.localName==="author"){const n=i.firstChild;n&&n.nodeType===3&&s.push(n.textContent)}}}}class wt{visit(t,e,s){if(!e)return;const r={};return t.copyFromAttribute(e,"ref",r),t.copyFromAttribute(e,"authorId",r,"authorId",t.INT_COPY),r.asNote=!0,s.comments||(s.comments=[]),s.comments.push(r),r}}class Pt{visit(t,e,s){if(!e)return;const r=[];return s.comments=r,r}}class Nt{visit(t,e,s){if(!e)return;const r={};return t.copyFromAttribute(e,"id",r,"id",g.r),t.copyFromAttribute(e,"personId",r,"personId",g.r),t.copyFromAttribute(e,"ref",r),t.copyFromAttribute(e,"parentId",r,"parentId",g.r),t.copyFromAttribute(e,"dT",r),e.hasAttribute("done")&&(r.done=g.b(e.getAttribute("done"))),s.push(r),r}}class Ot{visit(t,e,s){const r=[],o=e.childNodes;for(let i=0;i<o.length;i++){const n=o.item(i);if(n.nodeType===1&&n.localName==="person"){const l={};t.copyFromAttribute(n,"id",l,"id",g.r),t.copyFromAttribute(n,"displayName",l),t.copyFromAttribute(n,"userId",l,"userId",g.r),t.copyFromAttribute(n,"providerId",l),r.push(l)}}return r.length>0&&(s.persons=r),r}}const Tt={};class Vt{constructor(t,e){this.path=t,this.visitor=e}}class E{constructor(){this.visitorsByXmlTagName=new Map,this.scopedVisitorsByXmlTagName=new Map,this.visitorParamsState=null,this.registerVisitor("Relationships",new K),this.registerVisitor("spPr",new L),this.registerVisitor("txBody",new F),this.registerVisitor("txPr",new F),this.registerVisitor("c:chartSpace",new Z),this.registerVisitor("c:chartSpace",new H,"chart"),this.registerVisitor("c:plotArea",new q),this.registerVisitor("c:barChart",new J),this.registerVisitor("c:doughnutChart",new N),this.registerVisitor("c:lineChart",new N),this.registerVisitor("c:ofPieType",new N),this.registerVisitor("c:pieChart",new N),this.registerVisitor("c:scatterChart",new N),this.registerVisitor("c:barChart",new w("dataLabels"),"dLbls"),this.registerVisitor("c:doughnutChart",new w("dataLabels"),"dLbls"),this.registerVisitor("c:lineChart",new w("dataLabels"),"dLbls"),this.registerVisitor("c:ofPieType",new w("dataLabels"),"dLbls"),this.registerVisitor("c:pieChart",new w("dataLabels"),"dLbls"),this.registerVisitor("c:scatterChart",new w("dataLabels"),"dLbls"),this.registerVisitor("c:ser",new Q),this.registerVisitor("c:dPt",new tt),this.registerVisitor("c:marker",new et),this.registerVisitor("c:catAx",new k),this.registerVisitor("c:valAx",new k),this.registerVisitor("c:dateAx",new k),this.registerVisitor("c:majorGridlines",new S("gridLinesMajor")),this.registerVisitor("c:minorGridlines",new S("gridLinesMinor")),this.registerVisitor("c:chartSpace",null,"txPr"),this.registerVisitor("c:catAx",new F("labels.text"),"txPr"),this.registerVisitor("c:valAx",new F("labels.text"),"txPr"),this.registerVisitor("c:dateAx",new F("labels.text"),"txPr"),this.registerVisitor("c:legend",new st),this.registerVisitor("c:legend",new F("labels.text"),"txPr"),this.registerVisitor("c:legendEntry",new rt),this.registerVisitor("c:ser",new ot,"extLst/ext/invertSolidFillFmt/spPr"),this.registerVisitor("c:ser",new w("labels"),"dLbls"),this.registerVisitor("c:dLbl",new w("points")),this.registerVisitor("c:title",new _),this.registerVisitor("c:title",null,"tx/rich"),this.registerVisitor("c:title",null,"txPr"),this.registerVisitor("c:layout",new it),this.registerVisitor("c:dispUnits",new S("dispUnits")),this.registerVisitor("c:dispUnitsLbl",new _("displayUnitsLabel")),this.registerVisitor("c:dispUnitsLbl",new F,"tx/rich"),this.registerVisitor("a:theme",new nt),this.registerVisitor("a:theme",new lt,"themeElements/clrScheme"),this.registerVisitor("a:theme",new at,"themeElements/fontScheme"),this.registerVisitor("autoFilter",new ut),this.registerVisitor("sortState",new ht),this.registerVisitor("s:workbook",new gt),this.registerVisitor("styleSheet",new pt),this.registerVisitor("table",new dt),this.registerVisitor("hlinkClick",new ct),this.registerVisitor("wsDr",new mt),this.registerVisitor("twoCellAnchor",new x),this.registerVisitor("oneCellAnchor",new x),this.registerVisitor("absoluteAnchor",new x),this.registerVisitor("graphicFrame",new bt),this.registerVisitor("sp",new B),this.registerVisitor("grpSp",new At),this.registerVisitor("cxnSp",new yt),this.registerVisitor("pic",new ft),this.registerVisitor("rvStructures",new vt),this.registerVisitor("rvData",new Ft),this.registerVisitor("comments",new Ct),this.registerVisitor("commentList",new wt,"comment"),this.registerVisitor("comment",new F("content"),"text"),this.registerVisitor("ThreadedComments",new Pt),this.registerVisitor("threadedComment",new Nt),this.registerVisitor("threadedComment",new F("content"),"text"),this.registerVisitor("personList",new Ot)}registerVisitor(t,e,s=null){t.indexOf(":")===-1&&(t="*:"+t);const r=t.split(":"),o=r.length>1?r[1]:r[0];if(!s)return this.visitorsByXmlTagName.set(o,e),void this.visitorsByXmlTagName.set(t,e);let i=this.scopedVisitorsByXmlTagName.get(o);i||(i=[],this.scopedVisitorsByXmlTagName.set(o,i),this.scopedVisitorsByXmlTagName.set(t,i)),i.push(new Vt(s,e))}getVisitorParamsState(){return this.visitorParamsState}convert(t,e,s=Tt){const r=t.documentElement;this.visitorParamsState&&!s?.paramMap||(this.visitorParamsState=s?.paramMap??new Map);const o={};let i=this.visitorsByXmlTagName.get(r.nodeName);if(i||(i=this.visitorsByXmlTagName.get(r.localName)),!i)throw new Error(`A visitor for the root element: '${r.nodeName}' or '${r.localName}' must be registered.`);const n="/"+r.localName,l=new V(null,this,n,r,o,e,s),a=[];this._doWalk(i,l,a,r,o,e,s);for(let c=0;c<a.length;c++){const h=a[c];try{h.visitor?.afterVisit?.(h.context,h.elemParent,h.jsonParent)}catch(d){console.warn(`Error in afterVisit: ${h.context.getPath()}`,d)}}return o}_walkScoped(t,e,s,r,o,i,n){const l=this.scopedVisitorsByXmlTagName.get(t);for(let a=0;l&&a<l.length;a++){const c=l[a];let h=null;try{h=e.evaluate(c.path,r)}catch{console.warn(`"Invalid path '${c.path}' for '${t}'.`)}if(!h)continue;const d=m=>{let b=m.localName,v=m.parentNode;for(;v&&v!==r;)b=v.localName+"/"+b,v=v.parentNode;const P=e.getPath()+"/"+b;if(c.visitor){const T=new V(e,this,P,e.getElemRoot(),e.getJsonRoot(),i,n);this._doWalk(c.visitor,T,s,m,o,i,n)}};if(h.length>0){const m=h;for(let b=0;b<m.length;b++)d(m.item(b))}else d(h)}}_doWalk(t,e,s,r,o,i,n){let l=null;t&&(s.push({visitor:t,context:e,elemParent:r,jsonParent:o}),l=t.visit(e,r,o)),l||(l=o);const a=r.localName;this._walkScoped(a,e,s,r,l,i,n);const c=r.childNodes;for(let h=0;h<c.length;h++){const d=c.item(h);if(d.nodeType===1){const m=d,b=m.localName,v=this.visitorsByXmlTagName.get(b),P=e.getPath()+"/"+b,T=new V(e,this,P,e.getElemRoot(),e.getJsonRoot(),i,n);this._doWalk(v,T,s,m,l??o,i,n)}}return l}}exports.FromOOXMLConverter=E,exports.default=E;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
6
|
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});let c=class{constructor(e){this._worker=null,this._nextId=1,this._pendingRequests=new Map,this._workerFactory=e}start(){if(typeof Worker>"u")throw new Error("Web Workers are not supported in this environment.");return this._worker||(this._worker=this._workerFactory(),this._worker.onmessage=e=>{const{id:n,result:t,error:r}=e.data,o=this._pendingRequests.get(n);if(o)if(this._pendingRequests.delete(n),r){const i=new Error(r.message);i.stack=r.stack,r.cause&&(i.cause=r.cause),o.reject(i)}else o.resolve(t)},this._worker.onerror=e=>{console.error("Worker error:",e),this._pendingRequests.forEach(n=>{n.reject(new Error(`Worker failed: ${e.message}`))}),this._pendingRequests.clear(),this._worker=null}),Promise.resolve()}execute(e){if(!this._worker)throw new Error("Worker is not initialized. Call start() first.");const n=this._nextId++;return new Promise((t,r)=>{this._pendingRequests.set(n,{resolve:t,reject:r}),this._worker.postMessage({id:n,params:e})})}terminate(){this._worker&&(this._worker.terminate(),this._worker=null)}};class u{constructor(n){this._onExecute=n}execute(n){return this._onExecute(n)}start(){return Promise.resolve()}terminate(){}}const s=`/**
|
|
7
|
-
* @license @sheetxl/primitives - Primitives - Base types for SheetXL functions. - v0.6.
|
|
7
|
+
* @license @sheetxl/primitives - Primitives - Base types for SheetXL functions. - v0.6.13
|
|
8
8
|
*
|
|
9
9
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
10
10
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -223,7 +223,7 @@ var v;
|
|
|
223
223
|
return r = typeof e == "string" ? rt.get(e) : ot.get(e), r || (r = v.Unknown), new r(t, n);
|
|
224
224
|
}, v.getBuiltInById = (e) => Te.get(e) || xt;
|
|
225
225
|
/**
|
|
226
|
-
* @license @sheetxl/utils - Utils - Utilities used by most SheetXL components. - v0.6.
|
|
226
|
+
* @license @sheetxl/utils - Utils - Utilities used by most SheetXL components. - v0.6.13
|
|
227
227
|
*
|
|
228
228
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
229
229
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1504,4 +1504,4 @@ var ln = /* @__PURE__ */ Object.freeze({
|
|
|
1504
1504
|
__proto__: null,
|
|
1505
1505
|
initialize: an
|
|
1506
1506
|
});
|
|
1507
|
-
`,a=typeof self<"u"&&self.Blob&&new Blob(["URL.revokeObjectURL(import.meta.url);",s],{type:"text/javascript;charset=utf-8"});function d(e){let n;try{if(n=a&&(self.URL||self.webkitURL).createObjectURL(a),!n)throw"";const t=new Worker(n,{type:"module",name:e?.name});return t.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(n)}),t}catch{return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(s),{type:"module",name:e?.name})}}const l=async()=>{const{compileModule:e}=await Promise.resolve().then(()=>require("./
|
|
1507
|
+
`,a=typeof self<"u"&&self.Blob&&new Blob(["URL.revokeObjectURL(import.meta.url);",s],{type:"text/javascript;charset=utf-8"});function d(e){let n;try{if(n=a&&(self.URL||self.webkitURL).createObjectURL(a),!n)throw"";const t=new Worker(n,{type:"module",name:e?.name});return t.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(n)}),t}catch{return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(s),{type:"module",name:e?.name})}}const l=async()=>{const{compileModule:e}=await Promise.resolve().then(()=>require("./Cl4L7g73r_uCVljX.cjs")),n=new u(t=>e(t));return await n.start(),n};exports.createCompilerWorker=async function(){if(typeof process<"u"&&process.versions?.node&&typeof Worker>"u")return await l();if(typeof Worker<"u"){const e=new c(()=>new d);try{return await e.start(),e}catch(n){console.error("Failed to start TypescriptCompiler worker reverting to fallback:",n)}}return await l()};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});exports.TypeScriptCompiler=class{constructor(r={}){this.workerWrapper=null}async getWorkerWrapper(){if(this.workerWrapper)return this.workerWrapper;const{createCompilerWorker:r}=await Promise.resolve().then(()=>require("./
|
|
6
|
+
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});exports.TypeScriptCompiler=class{constructor(r={}){this.workerWrapper=null}async getWorkerWrapper(){if(this.workerWrapper)return this.workerWrapper;const{createCompilerWorker:r}=await Promise.resolve().then(()=>require("./Ddtzu7c4EPXHIcj3.cjs"));return this.workerWrapper=await r(),this.workerWrapper}async compileModule(r){try{return(await this.getWorkerWrapper()).execute(r)}catch(e){throw console.error("Failed to compile using worker:",e),e}}terminate(){this.workerWrapper?.terminate(),this.workerWrapper=null}};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";var c=Object.create;var n=Object.defineProperty;var a=Object.getOwnPropertyDescriptor;var s=Object.getOwnPropertyNames;var u=Object.getPrototypeOf,y=Object.prototype.hasOwnProperty;var p=(e,r,t,l)=>{if(r&&typeof r=="object"||typeof r=="function")for(let i of s(r))!y.call(e,i)&&i!==t&&n(e,i,{get:()=>r[i],enumerable:!(l=a(r,i))||l.enumerable});return e};var g=(e,r,t)=>(t=e!=null?c(u(e)):{},p(r||!e||!e.__esModule?n(t,"default",{value:e,enumerable:!0}):t,e));/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const J=require("./
|
|
7
|
-
`;for(let h=0;h<c;h++)y+=
|
|
6
|
+
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const J=require("./BrhEZihB-_ktU4T0.cjs");exports.fromBufferJSON=async(w,l)=>{let u=w;(function(t){if(t.byteLength<4)return!1;const i=new Uint8Array(t),r={gzip:[31,139],zip:[80,75,3,4],bz2:[66,90,104],br:[206,178,207,129]},n=Object.keys(r);for(let f=0;f<n.length;f++){const o=n[f],e=r[o];let a=!0;for(let s=0;s<e.length;s++)if(i[s]!==e[s]){a=!1;break}if(a)return o}return!1})(u)&&(u=await(async function(t,i="gzip"){let r;typeof SharedArrayBuffer<"u"&&t instanceof SharedArrayBuffer?(r=new ArrayBuffer(t.byteLength),new Uint8Array(r).set(new Uint8Array(t))):r=t;const n=new Blob([r]).stream(),f=new DecompressionStream(i),o=n.pipeThrough(f);return(await new Response(o).blob()).arrayBuffer()})(u));let b=new TextDecoder().decode(u);const g=JSON.parse(b),p={...l?.createWorkbookOptions??{},json:g};return new J.vy(p)},exports.toBufferJSON=async(w,l)=>{const u=await w.toJSON(),b=l?.whiteSpace??0;let g;l?.beforeWrite?.(w,u),g=b===0?JSON.stringify(u):(function(i,r=2){const n=[];function f(o){const e=r*o;return n[e]===void 0&&(n[e]=" ".repeat(e)),n[e]}return(function o(e,a,s,m){if(e==null||typeof e!="object")return JSON.stringify(e);const A=f(a),O=f(a+1);if(Array.isArray(e)){const c=e.length;if(c===0)return"[]";if(s!==0)return JSON.stringify(e);let y=`[
|
|
7
|
+
`;for(let h=0;h<c;h++)y+=O+o(e[h],a+1,s+1,!0),h<c-1&&(y+=`,
|
|
8
8
|
`);return y+=`
|
|
9
|
-
`+
|
|
10
|
-
`;m||(s=0);for(let c=0;c<d;c++){const y=B[c];S+=
|
|
9
|
+
`+A+"]",y}const B=Object.keys(e),d=B.length;if(d===0)return"{}";if(!(s<2))return JSON.stringify(e);let S=`{
|
|
10
|
+
`;m||(s=0);for(let c=0;c<d;c++){const y=B[c];S+=O+JSON.stringify(y)+": "+o(e[y],a+1,s,!1),c<d-1&&(S+=`,
|
|
11
11
|
`)}return S+=`
|
|
12
|
-
`+
|
|
12
|
+
`+A+"}",S})(i,0,0,!1)})(u,b);let p=new TextEncoder().encode(g).buffer;const t=l?.compress??!0;return t&&(p=await(async function(i,r="gzip"){let n;typeof SharedArrayBuffer<"u"&&i instanceof SharedArrayBuffer?(n=new ArrayBuffer(i.byteLength),new Uint8Array(n).set(new Uint8Array(i))):n=i;const f=new ReadableStream({start(a){a.enqueue(n),a.close()}}),o=new CompressionStream(r),e=f.pipeThrough(o);return(await new Response(e).blob()).arrayBuffer()})(p,typeof t=="string"?t:void 0)),p};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./
|
|
6
|
+
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./BrhEZihB-_ktU4T0.cjs"),I=["Ok","Cancel"],j=e.reactExports.memo(O=>{const{initialValue:E,context:x,onOption:m,onValidateOption:p,onInputOption:d,onDone:l,options:g=I,defaultOption:r=g?.[0],cancelOption:i="Cancel",sx:T,...b}=O,[o,y]=e.reactExports.useState(E),[v,C]=e.reactExports.useState(!1),u=e.reactExports.useCallback(async(t,a)=>!0,[]),c=e.T(async t=>{d?.(o,t),m?.(t,t===i,t===r),l?.()},[o,d,l,m,i,r]),k=e.T(async t=>{t.keyCode===e.eo.Enter&&await u?.(o,null)!==!1&&c(r)},[o,c]),R=e.T(t=>{y(t.target.value),u?.(t.target.value,null)},[p]),S=e.T(async t=>{let a=await Promise.resolve(p?.(t));try{a!==!1&&(a=await Promise.resolve(u?.(o,t))??!0)}catch{}return a??!0},[p]),[h,f]=e.reactExports.useState(e.Oe.Styles.lookupStyle(o).formatType??e.Oe.Type.Custom);e.reactExports.useEffect(()=>{f(e.Oe.Styles.lookupStyle(o).formatType??e.Oe.Type.Custom)},[o]);const F=e.reactExports.useMemo(()=>{const t=e.Oe.Styles.lookupPrimary(),a=n=>e.jsxRuntimeExports.jsx(e.MenuItem,{value:n,children:n},n),s=Object.keys(t).map(n=>a(t[n].formatType));return s.push(a(e.Oe.Type.Custom)),s},[]),P=e.reactExports.useCallback(t=>{const a=t.target.value;f(a);const s=e.Oe.Styles.lookupDefault(a);s&&y(s)},[]),w=e.reactExports.useMemo(()=>{const t=x();return t.createTemporaryCell({value:t.getValue()??12345,style:{numberFormat:o}})},[h,o,x]);return e.jsxRuntimeExports.jsx(e.k3,{title:"Number Format",options:g,onDone:l,onOption:t=>c(t),onValidateOption:S,defaultOption:r,cancelOption:i,autoFocusSel:".autoFocus",sx:{width:"580px",...T},...b,children:e.jsxRuntimeExports.jsxs(e.Box,{sx:{paddingTop:t=>t.spacing(1),paddingBottom:t=>t.spacing(0),rowGap:t=>t.spacing(1),display:"flex",flexDirection:"column"},children:[e.jsxRuntimeExports.jsxs(e.FormControl,{sx:{minWidth:135},size:"small",children:[e.jsxRuntimeExports.jsx(e.InputLabel,{children:"Category"}),e.jsxRuntimeExports.jsx(e.Select,{value:h,label:"Category",onChange:P,sx:{backgroundImage:`linear-gradient(${e.alpha("#fff",e.getOverlayAlpha(5))}, ${e.alpha("#fff",e.getOverlayAlpha(5))})`},children:F})]}),e.jsxRuntimeExports.jsx(e.FormControl,{sx:{paddingTop:t=>t.spacing(1.5),minWidth:135,width:"100%"},size:"small",children:e.jsxRuntimeExports.jsx(e.TextField,{label:"Code",onFocus:t=>{v||t.target?.select(),C(!0)},sx:{"& .MuiFormHelperText-root":{marginTop:t=>t.spacing(.5)}},InputLabelProps:{shrink:!0},InputProps:{inputProps:{className:"autoFocus",spellCheck:!1,autoComplete:"off",sx:{paddingTop:t=>t.spacing(1.25),paddingBottom:t=>t.spacing(.75),backgroundImage:`linear-gradient(${e.alpha("#fff",e.getOverlayAlpha(5))}, ${e.alpha("#fff",e.getOverlayAlpha(5))})`}}},value:o,onChange:R,onKeyDown:k,onContextMenu:t=>{t.stopPropagation()}})}),e.jsxRuntimeExports.jsxs(e.Box,{children:[e.jsxRuntimeExports.jsx(e.Typography,{variant:"caption",component:"div",sx:{paddingLeft:t=>t.spacing(2)},children:"Preview"}),e.jsxRuntimeExports.jsx(e.Typography,{variant:"body2",component:"div",sx:{borderRadius:t=>`${t.shape.borderRadius}px`,padding:t=>t.spacing(1),border:t=>`1px solid ${t.palette.grey[400]}`},children:w.getNumberFormat().displayText||"(empty)"})]})]})})});exports.NumberFormatDialog=j,exports.default=j;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./
|
|
6
|
+
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./BrhEZihB-_ktU4T0.cjs"),P=["Ok","Cancel"],g=e.reactExports.memo(f=>{const{initialComments:h=null,onUpdateComments:c,context:C,onOption:u,onValidateOption:i,onDone:r,options:m=P,defaultOption:p=m?.[0],cancelOption:l="Cancel",sx:O,...E}=f,x=e.reactExports.useMemo(()=>{const t=h??C?.()?.getComments();let n="";if(t&&t.content&&t.content.runs){const s=t.content.runs;for(let o=0;o<s.length;o++){const k=s[o];n+=k?.text}}return n},[]),[a,T]=e.reactExports.useState(x),[j,y]=e.reactExports.useState(!1),d=e.reactExports.useCallback(async(t,n)=>null,[]),v=e.T(async t=>{const n=a===""?[]:a.split(`
|
|
7
7
|
`);if(t!==l){const s=[];for(let o=0;o<n.length;o++)s.push({text:n[o]});c?.({content:{runs:s}})}u?.(t,t===l,t===p),r?.()},[a,c,r,u,p,l]),F=e.T(t=>{T(t.target.value),d(t.target.value,null)},[i]),b=e.T(async t=>{let n=await Promise.resolve(i?.(t));try{n!==!1&&(n=await d(a,t))}catch{}return n??!0},[i,a]);return e.jsxRuntimeExports.jsx(e.k3,{title:(x?"Edit":"Insert")+" Comments",options:m,onDone:r,onOption:t=>v(t),onValidateOption:b,defaultOption:p,cancelOption:l,autoFocusSel:".autoFocus",sx:{width:"480px",...O},...E,children:e.jsxRuntimeExports.jsx(e.Box,{sx:{paddingTop:t=>t.spacing(1),paddingBottom:t=>t.spacing(0),rowGap:t=>t.spacing(1),display:"flex",flexDirection:"column"},children:e.jsxRuntimeExports.jsx(e.FormControl,{sx:{paddingTop:t=>t.spacing(1.5),minWidth:135,width:"100%"},size:"small",children:e.jsxRuntimeExports.jsx(e.TextField,{label:"Comments",placeholder:"Enter a comment.",onFocus:t=>{j||t.target?.select(),y(!0)},sx:{"& .MuiFormHelperText-root":{marginTop:t=>t.spacing(.5)}},InputLabelProps:{shrink:!0},InputProps:{inputProps:{className:"autoFocus",spellCheck:!1,autoComplete:"off",sx:{paddingTop:t=>t.spacing(1.25),paddingBottom:t=>t.spacing(.75),backgroundImage:`linear-gradient(${e.alpha("#fff",e.getOverlayAlpha(5))}, ${e.alpha("#fff",e.getOverlayAlpha(5))})`}}},value:a,onChange:F,onContextMenu:t=>{t.stopPropagation()}})})})})});exports.CommentsDialog=g,exports.default=g;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./
|
|
6
|
+
*/Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./BrhEZihB-_ktU4T0.cjs"),D=["Input"],M=e.reactExports.memo(e.reactExports.forwardRef((f,h)=>{const{initialValue:T="",onOption:y,onValidateOption:p,onInputOption:r,onValidateInputOption:i,onDone:s,inputProps:l,inputLabel:O,inputType:E,inputPlaceHolder:j,options:u=D,autoFocusSel:v=".autoFocus",cancelOption:c,defaultOption:d=u?.[0],...w}=f,[F,S]=e.reactExports.useState(!1),[o,P]=e.reactExports.useState(T),[b,C]=e.reactExports.useState(""),[I,k]=e.reactExports.useState(!0),n=e.T(async(t,a)=>{if(!i)return!0;const g=await i?.(t,a);C(g?.message??"");const m=g?.valid??!0;return k(m),m},[i]),x=e.T(async t=>{r?.(o,t)},[o,r,s,y,c,d]),R=e.T(async t=>{t.keyCode===e.eo.Enter&&await n?.(o,null)},[o,x]),V=e.T(t=>{P(t.target.value),n?.(t.target.value,null)},[p]),B=e.T(async t=>{let a=await n(o,t);try{a!==!1&&(a=await n(o,t))}catch{}return a??!0},[o,p]);return e.jsxRuntimeExports.jsx(e.k3,{options:u,onDone:s,onOption:(t,a)=>{a||x(t)},onValidateOption:B,cancelOption:c,defaultOption:d,autoFocusSel:v,ref:h,...w,children:e.jsxRuntimeExports.jsx(e.Box,{sx:{paddingTop:t=>t.spacing(1),paddingBottom:t=>t.spacing(0)},children:e.jsxRuntimeExports.jsx(e.FormControl,{sx:{paddingTop:t=>t.spacing(1.5),minWidth:135,width:"100%"},size:"small",children:e.jsxRuntimeExports.jsx(e.TextField,{onFocus:t=>{F||t.target?.select(),S(!0)},type:E,label:O,helperText:b||" ",sx:{width:"100%","& .MuiFormHelperText-root":{marginTop:t=>t.spacing(.5),color:I?void 0:"error.main"}},InputLabelProps:{shrink:!0},InputProps:{inputProps:{placeholder:j,spellCheck:!1,autoComplete:"off",...l,className:e.z0("autoFocus",l?.className),sx:{paddingTop:t=>t.spacing(1.25),paddingBottom:t=>t.spacing(.75),backgroundImage:`linear-gradient(${e.alpha("#fff",e.getOverlayAlpha(5))}, ${e.alpha("#fff",e.getOverlayAlpha(5))})`}}},value:o,onChange:V,onKeyDown:R,onContextMenu:t=>{t.stopPropagation()}})})})})}));exports.default=M;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
package/browser/cjs/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
-
*/Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./
|
|
6
|
+
*/Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./BrhEZihB-_ktU4T0.cjs");exports.SheetXL=e.SheetXL,exports.default=e.SheetXL;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";/**
|
|
2
|
-
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.
|
|
2
|
+
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.13
|
|
3
3
|
*
|
|
4
4
|
* (C) 2025-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|