@datalayer/agent-runtimes 1.6.97 → 1.6.98
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/dist-embed/chunks/{AgentDetails-B5csrqWi.js → AgentDetails-CqMfY8zN.js} +1 -1
- package/dist-embed/chunks/{AgentDetailsDialog-gGnV2mTY.js → AgentDetailsDialog-lxnKA_dF.js} +1 -1
- package/dist-embed/chunks/{CellSidebarExtension-B4QBsTRy.js → CellSidebarExtension-CrdbRLaE.js} +1 -1
- package/dist-embed/chunks/ChatView-B9oVgZ72.js +32 -0
- package/dist-embed/chunks/{CollapsiblePlugin-vjE7wFOu.js → CollapsiblePlugin-CnG1qA1e.js} +1 -1
- package/dist-embed/chunks/{ContextPie-Dqj618Q2.js → ContextPie-DAZz2yzl.js} +1 -1
- package/dist-embed/chunks/{DeckComponent-CSxElvrq.js → DeckComponent-qAMqKLzs.js} +1 -1
- package/dist-embed/chunks/{DeckRenderer-DcyoBlq5.js → DeckRenderer-DQmjQ_vE.js} +2 -2
- package/dist-embed/chunks/{DeckStage-DJJkDWlM.js → DeckStage-LDi6nZOg.js} +2 -2
- package/dist-embed/chunks/{DiagramView-D8385Uvy.js → DiagramView-CpCoC99y.js} +1 -1
- package/dist-embed/chunks/{DocumentView-pHXY2GUy.js → DocumentView-B-lWAJgm.js} +1 -1
- package/dist-embed/chunks/{DrawingStage-CBhXNP2j.js → DrawingStage-DEeTWKLT.js} +1 -1
- package/dist-embed/chunks/{EphemeralDocument-C12bJ2Zi.js → EphemeralDocument-CZNRDs_b.js} +1 -1
- package/dist-embed/chunks/{EphemeralNotebook-DW9uU70P.js → EphemeralNotebook-BDutT9GQ.js} +1 -1
- package/dist-embed/chunks/{ExcalidrawComponent-BvB8s8DF.js → ExcalidrawComponent-CmJy7bb4.js} +1 -1
- package/dist-embed/chunks/{ExcalidrawModal-CLGo6lxD.js → ExcalidrawModal-D_DmAro7.js} +1 -1
- package/dist-embed/chunks/{FormulaBar-IFoQ6yN8.js → FormulaBar-f9U7lupQ.js} +1 -1
- package/dist-embed/chunks/{JupyterLexicalExtension-DhlGUbc0.js → JupyterLexicalExtension-DpGAnn7v.js} +9 -9
- package/dist-embed/chunks/{KernelVariables-COPHuvQe.js → KernelVariables-BIWju6rZ.js} +1 -1
- package/dist-embed/chunks/{LexicalToolRegistry-mRwpy8uR.js → LexicalToolRegistry-BqxU1w4N.js} +1 -1
- package/dist-embed/chunks/{NotebookToolSurfaces-f0K0s6tk.js → NotebookToolSurfaces-CqU9CVCl.js} +1 -1
- package/dist-embed/chunks/{NotebookView-CkgduWGZ.js → NotebookView-CpOBHIut.js} +1 -1
- package/dist-embed/chunks/{Output-BlVb0nsN.js → Output-DLpf2Of9.js} +6 -6
- package/dist-embed/chunks/{SandboxDetailsDialog-BWr3ZHmy.js → SandboxDetailsDialog-yUjpxBdw.js} +1 -1
- package/dist-embed/chunks/{SchemaForm-BYx28f9R.js → SchemaForm-N0hu4z_p.js} +1 -1
- package/dist-embed/chunks/{SheetStage-UDDuD0c-.js → SheetStage-gUVhALxR.js} +1 -1
- package/dist-embed/chunks/{SheetTabs-CRqCh6SH.js → SheetTabs-sx_-jWyq.js} +1 -1
- package/dist-embed/chunks/{SignInIcon-C0lCx6yN.js → SignInIcon-XIbntAUw.js} +1 -1
- package/dist-embed/chunks/{SpreadsheetPreviewView-D3bm2FuW.js → SpreadsheetPreviewView-C9LaI5mp.js} +1 -1
- package/dist-embed/chunks/{SpreadsheetView-C0jqVlH0.js → SpreadsheetView-FfnOGHeU.js} +1 -1
- package/dist-embed/chunks/{WidgetVariableView-CEWGssAP.js → WidgetVariableView-CKcw-pPX.js} +1 -1
- package/dist-embed/chunks/{YouTubePlugin-CwtVeT4X.js → YouTubePlugin-DUDVTb3B.js} +1 -1
- package/dist-embed/chunks/{abnfDiagram-VCTEODGH-JXHACDBz.js → abnfDiagram-VCTEODGH-B0MQRzNo.js} +1 -1
- package/dist-embed/chunks/{abnfDiagram-VCTEODGH-C-5M28HY.js → abnfDiagram-VCTEODGH-BM2pAacI.js} +1 -1
- package/dist-embed/chunks/{abnfDiagram-VCTEODGH-Bwv6WjS-.js → abnfDiagram-VCTEODGH-fcR8gNdJ.js} +1 -1
- package/dist-embed/chunks/{ar-SA-G6X2FPQ2-BM34ImM5.js → ar-SA-G6X2FPQ2-BfVZMCow.js} +1 -1
- package/dist-embed/chunks/{architectureDiagram-5GKGNRK7-DpujQos2.js → architectureDiagram-5GKGNRK7-CnP0s6uJ.js} +1 -1
- package/dist-embed/chunks/{architectureDiagram-5GKGNRK7-KCUb-Mex.js → architectureDiagram-5GKGNRK7-Cpu0tfD1.js} +1 -1
- package/dist-embed/chunks/{architectureDiagram-5GKGNRK7-CAgLqF4a.js → architectureDiagram-5GKGNRK7-GZ5981UE.js} +1 -1
- package/dist-embed/chunks/{az-AZ-76LH7QW2-ClbRZkch.js → az-AZ-76LH7QW2-BeD9jzcd.js} +1 -1
- package/dist-embed/chunks/{bg-BG-XCXSNQG7-C9-xTdL3.js → bg-BG-XCXSNQG7-VUraF-a0.js} +1 -1
- package/dist-embed/chunks/{blockDiagram-868be97b-BIKcIMyQ.js → blockDiagram-868be97b-BK7odeOZ.js} +1 -1
- package/dist-embed/chunks/{blockDiagram-I7D4REHJ-6rNTajX4.js → blockDiagram-I7D4REHJ-BMQSOcOL.js} +1 -1
- package/dist-embed/chunks/{blockDiagram-I7D4REHJ-Dk3ubhN6.js → blockDiagram-I7D4REHJ-CZlh2u1A.js} +1 -1
- package/dist-embed/chunks/{blockDiagram-I7D4REHJ-Dg9wRDSP.js → blockDiagram-I7D4REHJ-DiBWN476.js} +1 -1
- package/dist-embed/chunks/{bn-BD-2XOGV67Q-yHaSEyU7.js → bn-BD-2XOGV67Q-DjghL9Ba.js} +1 -1
- package/dist-embed/chunks/{c4Diagram-3f4bdde3-DX31j648.js → c4Diagram-3f4bdde3-CMf0cOcM.js} +1 -1
- package/dist-embed/chunks/{c4Diagram-7LVT6UL2-Blhl5Ivg.js → c4Diagram-7LVT6UL2-BYPUXI1P.js} +1 -1
- package/dist-embed/chunks/{c4Diagram-7LVT6UL2-DotUFrPy.js → c4Diagram-7LVT6UL2-plU3oizm.js} +1 -1
- package/dist-embed/chunks/{c4Diagram-7LVT6UL2-kO868bTp.js → c4Diagram-7LVT6UL2-qmYneJtb.js} +1 -1
- package/dist-embed/chunks/{ca-ES-6MX7JW3Y-Co3yrY97.js → ca-ES-6MX7JW3Y-J6FuV-ut.js} +1 -1
- package/dist-embed/chunks/{celltoolbartracker-DzouPWbZ.js → celltoolbartracker-0MFBHjtq.js} +1 -1
- package/dist-embed/chunks/{chunk-2Q5K7J3B-BC8SN0W_.js → chunk-2Q5K7J3B-B5DIEbuU.js} +1 -1
- package/dist-embed/chunks/{chunk-2Q5K7J3B-BB4YNChb.js → chunk-2Q5K7J3B-BfCPaxeK.js} +1 -1
- package/dist-embed/chunks/{chunk-2Q5K7J3B-COf2HInf.js → chunk-2Q5K7J3B-Cj3jAIkT.js} +1 -1
- package/dist-embed/chunks/{chunk-5VM5RSS4-C3jze8cb.js → chunk-5VM5RSS4-BZGDG9GF.js} +1 -1
- package/dist-embed/chunks/{chunk-5VM5RSS4-DiJWlaEG.js → chunk-5VM5RSS4-DYeTGvz7.js} +1 -1
- package/dist-embed/chunks/{chunk-5VM5RSS4-cXmhCpsu.js → chunk-5VM5RSS4-g3id5Hpo.js} +1 -1
- package/dist-embed/chunks/{chunk-F27PBJKO-BXMw8fcU.js → chunk-F27PBJKO-DvclqQhV.js} +1 -1
- package/dist-embed/chunks/{chunk-F27PBJKO-DaAtxZ3_.js → chunk-F27PBJKO-S3msebgW.js} +1 -1
- package/dist-embed/chunks/{chunk-F27PBJKO-DZJGymAh.js → chunk-F27PBJKO-kACIRR-8.js} +1 -1
- package/dist-embed/chunks/{chunk-IMKFNOWR-CR3C15pD.js → chunk-IMKFNOWR-Ch7v5XHt.js} +1 -1
- package/dist-embed/chunks/{chunk-IMKFNOWR-C4f2Xvwg.js → chunk-IMKFNOWR-DjIARM3y.js} +1 -1
- package/dist-embed/chunks/{chunk-IMKFNOWR-Ct7GddYG.js → chunk-IMKFNOWR-SiS0o9FR.js} +1 -1
- package/dist-embed/chunks/{chunk-JWPE2WC7-9KydF4Cl.js → chunk-JWPE2WC7-BwLKeh91.js} +1 -1
- package/dist-embed/chunks/{chunk-JWPE2WC7-B54sCK-y.js → chunk-JWPE2WC7-CVacxpin.js} +1 -1
- package/dist-embed/chunks/{chunk-JWPE2WC7-D9_2-oUP.js → chunk-JWPE2WC7-M6oulZhu.js} +1 -1
- package/dist-embed/chunks/{chunk-POPQ4Y6H-BaMRoQVu.js → chunk-POPQ4Y6H-BCHaCocF.js} +1 -1
- package/dist-embed/chunks/{chunk-POPQ4Y6H-BgtIg837.js → chunk-POPQ4Y6H-DacAiEUG.js} +1 -1
- package/dist-embed/chunks/{chunk-POPQ4Y6H-Db5GUGhc.js → chunk-POPQ4Y6H-DicNgh7k.js} +1 -1
- package/dist-embed/chunks/{chunk-SVP7TREG-CeM8qf58.js → chunk-SVP7TREG-3X_ReA6d.js} +1 -1
- package/dist-embed/chunks/{chunk-SVP7TREG-F4uclbvM.js → chunk-SVP7TREG-COLBrDOd.js} +1 -1
- package/dist-embed/chunks/{chunk-SVP7TREG-BYkF4CFZ.js → chunk-SVP7TREG-Cit7UeF2.js} +1 -1
- package/dist-embed/chunks/{chunk-TICWLB2K-D-Wwl7XB.js → chunk-TICWLB2K-C4D-h9t1.js} +1 -1
- package/dist-embed/chunks/{chunk-TICWLB2K-BFf8Le3M.js → chunk-TICWLB2K-DfGZ1S46.js} +1 -1
- package/dist-embed/chunks/{chunk-TICWLB2K-BHq2Ystt.js → chunk-TICWLB2K-TaUeWpZb.js} +1 -1
- package/dist-embed/chunks/{chunk-XXDRQBXY-BHMLcU9A.js → chunk-XXDRQBXY-B6fuzLc9.js} +1 -1
- package/dist-embed/chunks/{chunk-XXDRQBXY-BlVD4u-l.js → chunk-XXDRQBXY-Bo_XDdf-.js} +1 -1
- package/dist-embed/chunks/{chunk-XXDRQBXY-DTCYLV17.js → chunk-XXDRQBXY-Bz5lFaJG.js} +1 -1
- package/dist-embed/chunks/{classDiagram-ZZMXUADV-B1H5YR5N.js → classDiagram-ZZMXUADV-DDZ5U8jk.js} +1 -1
- package/dist-embed/chunks/{classDiagram-ZZMXUADV-C69Ng482.js → classDiagram-ZZMXUADV-DpQTfwXC.js} +1 -1
- package/dist-embed/chunks/{classDiagram-ZZMXUADV-fah4qQBw.js → classDiagram-ZZMXUADV-orzU8a0Z.js} +1 -1
- package/dist-embed/chunks/{classDiagram-f62afe4f-BpmDNOf_.js → classDiagram-f62afe4f-CNI3U8Mt.js} +1 -1
- package/dist-embed/chunks/{classDiagram-v2-604399ef-DXSVTZaU.js → classDiagram-v2-604399ef-CLQHn0oB.js} +1 -1
- package/dist-embed/chunks/{classDiagram-v2-VYDZK3BY-B1H5YR5N.js → classDiagram-v2-VYDZK3BY-DDZ5U8jk.js} +1 -1
- package/dist-embed/chunks/{classDiagram-v2-VYDZK3BY-C69Ng482.js → classDiagram-v2-VYDZK3BY-DpQTfwXC.js} +1 -1
- package/dist-embed/chunks/{classDiagram-v2-VYDZK3BY-fah4qQBw.js → classDiagram-v2-VYDZK3BY-orzU8a0Z.js} +1 -1
- package/dist-embed/chunks/{code-block-IT6T5CEO-BzV6dOeo.js → code-block-IT6T5CEO-DjmCcA6a.js} +1 -1
- package/dist-embed/chunks/{component-DQ0vRpmL.js → component-B62XEB_I.js} +1 -1
- package/dist-embed/chunks/{core-YLcIWC_X.js → core-CsMGn5rr.js} +1 -1
- package/dist-embed/chunks/{cose-bilkent-JH36ORCC-DUgmse9Z.js → cose-bilkent-JH36ORCC-B_IELYPJ.js} +1 -1
- package/dist-embed/chunks/{cose-bilkent-JH36ORCC-CFC6-4OL.js → cose-bilkent-JH36ORCC-CE9lt3OO.js} +1 -1
- package/dist-embed/chunks/{cose-bilkent-JH36ORCC-B13OR0_2.js → cose-bilkent-JH36ORCC-CJiHk5L4.js} +1 -1
- package/dist-embed/chunks/{createText-aed3d8b3-Cft4GZJy.js → createText-aed3d8b3-DTAS6DfQ.js} +1 -1
- package/dist-embed/chunks/{cs-CZ-2BRQDIVT-BXDHJOy0.js → cs-CZ-2BRQDIVT-BJRVSuxc.js} +1 -1
- package/dist-embed/chunks/{cynefinDiagram-5FMLGOSQ-Baap8yDb.js → cynefinDiagram-5FMLGOSQ-B2073FgP.js} +1 -1
- package/dist-embed/chunks/{cynefinDiagram-5FMLGOSQ-B7_plLD6.js → cynefinDiagram-5FMLGOSQ-CyHkNAUC.js} +1 -1
- package/dist-embed/chunks/{cynefinDiagram-5FMLGOSQ-kHl-Cu_e.js → cynefinDiagram-5FMLGOSQ-HsJLw9Ow.js} +1 -1
- package/dist-embed/chunks/{da-DK-5WZEPLOC-Bv_vMRQS.js → da-DK-5WZEPLOC-DmvpQmCz.js} +1 -1
- package/dist-embed/chunks/{dagre-GXQ25YYZ-l25rB3RT.js → dagre-GXQ25YYZ-BkxHUUfX.js} +1 -1
- package/dist-embed/chunks/{dagre-GXQ25YYZ-DLkLgXkX.js → dagre-GXQ25YYZ-DzmuuJ_r.js} +1 -1
- package/dist-embed/chunks/{dagre-GXQ25YYZ-De_KrzkJ.js → dagre-GXQ25YYZ-R_lzFrVl.js} +1 -1
- package/dist-embed/chunks/{de-DE-XR44H4JA-Bko2COU8.js → de-DE-XR44H4JA-aRPZsjh8.js} +1 -1
- package/dist-embed/chunks/{diagram-S7CK7UJ4-uPenisEP.js → diagram-S7CK7UJ4-1KpTTJPB.js} +1 -1
- package/dist-embed/chunks/{diagram-S7CK7UJ4-uDpubVD_.js → diagram-S7CK7UJ4-BANHWGqU.js} +1 -1
- package/dist-embed/chunks/{diagram-S7CK7UJ4-BiZ-ex3Q.js → diagram-S7CK7UJ4-DsEYZOqE.js} +1 -1
- package/dist-embed/chunks/{diagram-UQ7AKVKN-FzXo7K78.js → diagram-UQ7AKVKN-B-SbMZjY.js} +1 -1
- package/dist-embed/chunks/{diagram-UQ7AKVKN-BzBp2O2s.js → diagram-UQ7AKVKN-BadWwEqS.js} +1 -1
- package/dist-embed/chunks/{diagram-UQ7AKVKN-DbPeWUnW.js → diagram-UQ7AKVKN-E5q5_JWL.js} +1 -1
- package/dist-embed/chunks/{diagram-VSXAHHWV-DLDYySj7.js → diagram-VSXAHHWV-B-ZTas3h.js} +1 -1
- package/dist-embed/chunks/{diagram-VSXAHHWV-CwicQwvc.js → diagram-VSXAHHWV-BsdL7E17.js} +1 -1
- package/dist-embed/chunks/{diagram-VSXAHHWV-BcQHUbuO.js → diagram-VSXAHHWV-D_7x_Ody.js} +1 -1
- package/dist-embed/chunks/{diagram-VX7I27RA-Ft45yb-L.js → diagram-VX7I27RA-BGyPrgPC.js} +1 -1
- package/dist-embed/chunks/{diagram-VX7I27RA-BscrabRG.js → diagram-VX7I27RA-CNSwTKHP.js} +1 -1
- package/dist-embed/chunks/{diagram-VX7I27RA-BSiMudGz.js → diagram-VX7I27RA-C_1S9aIm.js} +1 -1
- package/dist-embed/chunks/{diagram-Z3DM3KII-C5mNapBw.js → diagram-Z3DM3KII-B5t8N8ZT.js} +1 -1
- package/dist-embed/chunks/{diagram-Z3DM3KII-B86lp0dM.js → diagram-Z3DM3KII-C2gtrmQ9.js} +1 -1
- package/dist-embed/chunks/{diagram-Z3DM3KII-Y-lVwha7.js → diagram-Z3DM3KII-yVDxeysg.js} +1 -1
- package/dist-embed/chunks/{ebnfDiagram-PWID7BFC-DuGxLmkd.js → ebnfDiagram-PWID7BFC-BgfF1EZn.js} +1 -1
- package/dist-embed/chunks/{ebnfDiagram-PWID7BFC-COn39ksr.js → ebnfDiagram-PWID7BFC-C7dUKFPT.js} +1 -1
- package/dist-embed/chunks/{ebnfDiagram-PWID7BFC-Tzta9jsh.js → ebnfDiagram-PWID7BFC-LCa7gn5F.js} +1 -1
- package/dist-embed/chunks/{edges-b2856ca0-B0fzIYH0.js → edges-b2856ca0-J2ON9YC7.js} +1 -1
- package/dist-embed/chunks/{el-GR-BZB4AONW-CGifhWk7.js → el-GR-BZB4AONW-BBpO4fOL.js} +1 -1
- package/dist-embed/chunks/{erDiagram-5d81789a-Bs2AlkA7.js → erDiagram-5d81789a-BM5rHLzM.js} +1 -1
- package/dist-embed/chunks/{erDiagram-RLTQ6QDP-gNk7K_1a.js → erDiagram-RLTQ6QDP-BguBlD55.js} +1 -1
- package/dist-embed/chunks/{erDiagram-RLTQ6QDP-dY0zbwz5.js → erDiagram-RLTQ6QDP-C35O3IA_.js} +1 -1
- package/dist-embed/chunks/{erDiagram-RLTQ6QDP-69KYQDkg.js → erDiagram-RLTQ6QDP-CX1vL7D6.js} +1 -1
- package/dist-embed/chunks/{es-ES-U4NZUMDT-CG3eLB2T.js → es-ES-U4NZUMDT-CyrQHwAL.js} +1 -1
- package/dist-embed/chunks/{esm-jxjWs5qw.js → esm-BaC41XaP.js} +1 -1
- package/dist-embed/chunks/{esm-DXOCHrTC.js → esm-DNtiNaWu.js} +1 -1
- package/dist-embed/chunks/{eu-ES-A7QVB2H4-DzPN5Wvi.js → eu-ES-A7QVB2H4-BJG9zHud.js} +1 -1
- package/dist-embed/chunks/{fa-IR-HGAKTJCU-DFiN2zZy.js → fa-IR-HGAKTJCU-BOnLqEaQ.js} +1 -1
- package/dist-embed/chunks/{fi-FI-Z5N7JZ37-DoWgfc_V.js → fi-FI-Z5N7JZ37-DdQTDw9O.js} +1 -1
- package/dist-embed/chunks/{flowDb-185abca5-CX3GWJVI.js → flowDb-185abca5-CLfj2Qv7.js} +1 -1
- package/dist-embed/chunks/{flowDiagram-1629c991-CLqeIp_x.js → flowDiagram-1629c991-DjfIfqQ2.js} +1 -1
- package/dist-embed/chunks/{flowDiagram-HODETNUW-BHSFqLFz.js → flowDiagram-HODETNUW-CmpkqsRJ.js} +1 -1
- package/dist-embed/chunks/{flowDiagram-HODETNUW-CJEJhhfg.js → flowDiagram-HODETNUW-Cuv1YfzK.js} +1 -1
- package/dist-embed/chunks/{flowDiagram-HODETNUW-Du69fYws.js → flowDiagram-HODETNUW-DEVM2ZrI.js} +1 -1
- package/dist-embed/chunks/{flowDiagram-v2-1d953310-CBHgUV1p.js → flowDiagram-v2-1d953310-4wSPcojK.js} +1 -1
- package/dist-embed/chunks/{flowchart-elk-definition-6df44142-DeZ--5a6.js → flowchart-elk-definition-6df44142-Cb0xBerO.js} +1 -1
- package/dist-embed/chunks/{fr-FR-RHASNOE6-J88GG3aE.js → fr-FR-RHASNOE6-DQXpQs87.js} +1 -1
- package/dist-embed/chunks/{ganttDiagram-3b0b3873-C2r1fH39.js → ganttDiagram-3b0b3873-DI6DrFsY.js} +1 -1
- package/dist-embed/chunks/{ganttDiagram-EL5Y4UJY-7MMvC1fh.js → ganttDiagram-EL5Y4UJY-CSmChevD.js} +1 -1
- package/dist-embed/chunks/{ganttDiagram-EL5Y4UJY-DKaPd3MM.js → ganttDiagram-EL5Y4UJY-DdKCj2ex.js} +1 -1
- package/dist-embed/chunks/{ganttDiagram-EL5Y4UJY-C3YxQe7W.js → ganttDiagram-EL5Y4UJY-drl1C7t5.js} +1 -1
- package/dist-embed/chunks/{gitGraphDiagram-WWUBYQGX-Cnig1EpR.js → gitGraphDiagram-WWUBYQGX-Dna0JScG.js} +1 -1
- package/dist-embed/chunks/{gitGraphDiagram-WWUBYQGX-BhAiY2G7.js → gitGraphDiagram-WWUBYQGX-PLhOfVTI.js} +1 -1
- package/dist-embed/chunks/{gitGraphDiagram-WWUBYQGX-DL75-74K.js → gitGraphDiagram-WWUBYQGX-gYDVDk5C.js} +1 -1
- package/dist-embed/chunks/{gitGraphDiagram-f01e8bc2-DpCnh99K.js → gitGraphDiagram-f01e8bc2-BmE4UKm_.js} +1 -1
- package/dist-embed/chunks/{gl-ES-HMX3MZ6V-DCx-cx3z.js → gl-ES-HMX3MZ6V-DzfCce3N.js} +1 -1
- package/dist-embed/chunks/{he-IL-6SHJWFNN-DSVCS7oh.js → he-IL-6SHJWFNN-DRlcBbb7.js} +1 -1
- package/dist-embed/chunks/{hi-IN-IWLTKZ5I-dYf4Ui9C.js → hi-IN-IWLTKZ5I-BrerMuM3.js} +1 -1
- package/dist-embed/chunks/{hu-HU-A5ZG7DT2-D62ZhqXS.js → hu-HU-A5ZG7DT2-DFTsPGh6.js} +1 -1
- package/dist-embed/chunks/{id-ID-SAP4L64H-CPbEyEGt.js → id-ID-SAP4L64H-D0pKFdUL.js} +1 -1
- package/dist-embed/chunks/{index-DUo_Q0bE.js → index-46VEGuyz.js} +2 -2
- package/dist-embed/chunks/{index-9bae90f3-BXKxYnBg.js → index-9bae90f3-Cc18qrXw.js} +1 -1
- package/dist-embed/chunks/{index-h3ezbReI.js → index-B5W7CVUY.js} +1 -1
- package/dist-embed/chunks/{index-BeTQYXBa.js → index-BQEWUnIX.js} +1 -1
- package/dist-embed/chunks/{index-C1V3QrNG.js → index-BXY2kJ1z.js} +1 -1
- package/dist-embed/chunks/{index-BDfHQl3F.js → index-BzdaTJ02.js} +4 -4
- package/dist-embed/chunks/{index-BxqT3iXs.js → index-C-4crJTg.js} +4 -4
- package/dist-embed/chunks/{index-BrEfsSSF.js → index-CBWGYoQM.js} +1 -1
- package/dist-embed/chunks/{index-D6Jo2GVI.js → index-CET7bv5d.js} +1 -1
- package/dist-embed/chunks/{index-BAjfjlr1.js → index-h8lXpqtD.js} +1 -1
- package/dist-embed/chunks/index.esm-DwyYEnhk.js +1 -0
- package/dist-embed/chunks/{index.esm-hHiWwus_.js → index.esm-fF--io5D.js} +1 -1
- package/dist-embed/chunks/{infoDiagram-27XIBGKW-DR9uGGbg.js → infoDiagram-27XIBGKW-BZLQcxTA.js} +1 -1
- package/dist-embed/chunks/{infoDiagram-27XIBGKW-BWng8B0-.js → infoDiagram-27XIBGKW-DlOi-VkF.js} +1 -1
- package/dist-embed/chunks/{infoDiagram-27XIBGKW-CUOzYTfJ.js → infoDiagram-27XIBGKW-Ir7z7vae.js} +1 -1
- package/dist-embed/chunks/{infoDiagram-a29d40f1-HEc-jV3D.js → infoDiagram-a29d40f1-B_50LXsh.js} +1 -1
- package/dist-embed/chunks/{ishikawaDiagram-5VMMS53U-bN5K7Z_H.js → ishikawaDiagram-5VMMS53U-CUxqPwbA.js} +1 -1
- package/dist-embed/chunks/{ishikawaDiagram-5VMMS53U-D-4s54qG.js → ishikawaDiagram-5VMMS53U-CmchLGEY.js} +1 -1
- package/dist-embed/chunks/{ishikawaDiagram-5VMMS53U-A0e9fSuG.js → ishikawaDiagram-5VMMS53U-Erx01g7S.js} +1 -1
- package/dist-embed/chunks/{it-IT-JPQ66NNP-B82xwLEQ.js → it-IT-JPQ66NNP-CbZLqWAE.js} +1 -1
- package/dist-embed/chunks/{ja-JP-DBVTYXUO-CM-98LRm.js → ja-JP-DBVTYXUO-9xZnJjLg.js} +1 -1
- package/dist-embed/chunks/{journeyDiagram-3NMN7TZE-Bi4bGCmh.js → journeyDiagram-3NMN7TZE-B6PqY62p.js} +1 -1
- package/dist-embed/chunks/{journeyDiagram-3NMN7TZE-BxzwEGdA.js → journeyDiagram-3NMN7TZE-BRe0KiaN.js} +1 -1
- package/dist-embed/chunks/{journeyDiagram-3NMN7TZE-8G4uOxBl.js → journeyDiagram-3NMN7TZE-C9s2og1s.js} +1 -1
- package/dist-embed/chunks/{journeyDiagram-95396277-eqSlSLqg.js → journeyDiagram-95396277-BsoN0fKG.js} +1 -1
- package/dist-embed/chunks/{kaa-6HZHGXH3-Ef811qmk.js → kaa-6HZHGXH3-CO2r0Hb-.js} +1 -1
- package/dist-embed/chunks/{kab-KAB-ZGHBKWFO-DXBRnDqR.js → kab-KAB-ZGHBKWFO-0WoWjCrc.js} +1 -1
- package/dist-embed/chunks/{kanban-definition-UXKFOSKX-CmTw15_j.js → kanban-definition-UXKFOSKX-B6PDcRlF.js} +1 -1
- package/dist-embed/chunks/{kanban-definition-UXKFOSKX-DMF43A4Q.js → kanban-definition-UXKFOSKX-BO0-y3yZ.js} +1 -1
- package/dist-embed/chunks/{kanban-definition-UXKFOSKX-DMkqn8yL.js → kanban-definition-UXKFOSKX-CKIjAYbp.js} +1 -1
- package/dist-embed/chunks/{kk-KZ-P5N5QNE5-DXPHFZv8.js → kk-KZ-P5N5QNE5-DFQE1uuw.js} +1 -1
- package/dist-embed/chunks/{km-KH-HSX4SM5Z-fcVwn7la.js → km-KH-HSX4SM5Z-D0Bja56Q.js} +1 -1
- package/dist-embed/chunks/{ko-KR-MTYHY66A-fPmaSt-R.js → ko-KR-MTYHY66A-C6MeQrMU.js} +1 -1
- package/dist-embed/chunks/{ku-TR-6OUDTVRD-DLO8mEqc.js → ku-TR-6OUDTVRD-CweepkXr.js} +1 -1
- package/dist-embed/chunks/{layout-BQJeAUxn.js → layout-Bz98EP0E.js} +1 -1
- package/dist-embed/chunks/{layout-DKKRYrOx.js → layout-DPmNjViN.js} +1 -1
- package/dist-embed/chunks/{layout-BiwLrHFv.js → layout-mk0FGxVc.js} +1 -1
- package/dist-embed/chunks/{lexicalHooks-CJT40c-i.js → lexicalHooks-Cj3BNPDC.js} +1 -1
- package/dist-embed/chunks/{lib-CCs8IFk9.js → lib-0j0dfH8p.js} +1 -1
- package/dist-embed/chunks/{lib-BWVYnyap.js → lib-B01oDNlH.js} +1 -1
- package/dist-embed/chunks/{lib-DGyQX8HH.js → lib-B62N3zGB.js} +1 -1
- package/dist-embed/chunks/{lib-DjnzrDLN.js → lib-BItrfBU4.js} +1 -1
- package/dist-embed/chunks/{lib-DiaM9sQK.js → lib-BmoHRaAo.js} +1 -1
- package/dist-embed/chunks/{lib-Bt7-2uko.js → lib-BnAfx9wF.js} +1 -1
- package/dist-embed/chunks/{lib-5GRWA8Zf.js → lib-C-8NAvI1.js} +1 -1
- package/dist-embed/chunks/{lib-D-sHfT2H.js → lib-COg_k5cY.js} +1 -1
- package/dist-embed/chunks/{lib-DlJpF03q.js → lib-CY6QUCzq.js} +1 -1
- package/dist-embed/chunks/{lib-Bkasfzit.js → lib-CjicD0Pj.js} +1 -1
- package/dist-embed/chunks/{lib-Ct98HeTv.js → lib-CkKgTevD.js} +1 -1
- package/dist-embed/chunks/{lib-CAO9TgtV.js → lib-D8Ksfd49.js} +1 -1
- package/dist-embed/chunks/{lib-hGDX-thU.js → lib-DCBCbRKN.js} +1 -1
- package/dist-embed/chunks/{lib-C9Xg-F1Z.js → lib-DpZphKNm.js} +1 -1
- package/dist-embed/chunks/{lib-D63-MDjq.js → lib-DzVf9ZJD.js} +1 -1
- package/dist-embed/chunks/{lib-Duu9jvZE.js → lib-Hgl-pfON.js} +1 -1
- package/dist-embed/chunks/{lib-D7hI6faK.js → lib-f60SfhfM.js} +1 -1
- package/dist-embed/chunks/{lib-Bp97CI40.js → lib-ku1U2GxE.js} +1 -1
- package/dist-embed/chunks/{lib-B9ZzlHt8.js → lib-tR3XRdBe.js} +1 -1
- package/dist-embed/chunks/{lib-BBunDtjl.js → lib-w650Gz0V.js} +1 -1
- package/dist-embed/chunks/{lt-LT-XHIRWOB4-CDj2NwJ7.js → lt-LT-XHIRWOB4-DrPOBOia.js} +1 -1
- package/dist-embed/chunks/{lv-LV-5QDEKY6T-DM0UmntK.js → lv-LV-5QDEKY6T-BlGiDUA0.js} +1 -1
- package/dist-embed/chunks/{mermaid.core-BFu8E2Ch.js → mermaid.core-1p09QPXM.js} +3 -3
- package/dist-embed/chunks/{mermaid.core-oCOrUXH6.js → mermaid.core-BiF8MSuv.js} +5 -5
- package/dist-embed/chunks/{mindmap-definition-YA3MSWOX-BBOAmrK9.js → mindmap-definition-YA3MSWOX-CEFrcqEk.js} +1 -1
- package/dist-embed/chunks/{mindmap-definition-YA3MSWOX-D5P4dsfO.js → mindmap-definition-YA3MSWOX-DpAy5heR.js} +1 -1
- package/dist-embed/chunks/{mindmap-definition-YA3MSWOX-k9DaqQ85.js → mindmap-definition-YA3MSWOX-t1pDKjS3.js} +1 -1
- package/dist-embed/chunks/{mindmap-definition-e4c1d938-pjtVjzMw.js → mindmap-definition-e4c1d938-DcepOwKv.js} +1 -1
- package/dist-embed/chunks/{model-BlGqAZ_E.js → model-jLDiOPpQ.js} +1 -1
- package/dist-embed/chunks/{mr-IN-CRQNXWMA-DKu7Lbyh.js → mr-IN-CRQNXWMA-BWEVprKf.js} +1 -1
- package/dist-embed/chunks/{my-MM-5M5IBNSE-OpXhxQFy.js → my-MM-5M5IBNSE-BBxutJOz.js} +1 -1
- package/dist-embed/chunks/{nb-NO-T6EIAALU-CaW58ARR.js → nb-NO-T6EIAALU-DJnrKa7W.js} +1 -1
- package/dist-embed/chunks/{nl-NL-IS3SIHDZ-D4WjKwio.js → nl-NL-IS3SIHDZ-DQfv4h3e.js} +1 -1
- package/dist-embed/chunks/{nn-NO-6E72VCQL-n-7vV9Cs.js → nn-NO-6E72VCQL-DiGj9RA6.js} +1 -1
- package/dist-embed/chunks/{oc-FR-POXYY2M6-CB6dwikR.js → oc-FR-POXYY2M6-WJRn50ji.js} +1 -1
- package/dist-embed/chunks/{pa-IN-N4M65BXN-Cq4oiAGn.js → pa-IN-N4M65BXN-U7QCzNgm.js} +1 -1
- package/dist-embed/chunks/{pegDiagram-XKGWAZYB-oNVN1IG9.js → pegDiagram-XKGWAZYB-BlYwAwEo.js} +1 -1
- package/dist-embed/chunks/{pegDiagram-XKGWAZYB-BTn5P1TU.js → pegDiagram-XKGWAZYB-CudwiD3O.js} +1 -1
- package/dist-embed/chunks/{pegDiagram-XKGWAZYB-Cge-GlZ7.js → pegDiagram-XKGWAZYB-iE6rBtXO.js} +1 -1
- package/dist-embed/chunks/{percentages-BXMCSKIN-DRR-eJCX.js → percentages-BXMCSKIN-DhE6_GLO.js} +5 -5
- package/dist-embed/chunks/{pieDiagram-E7YTZNPT-C9syugZr.js → pieDiagram-E7YTZNPT-CIawCiDR.js} +1 -1
- package/dist-embed/chunks/{pieDiagram-E7YTZNPT-LKAJV-f9.js → pieDiagram-E7YTZNPT-Cy6Wueqp.js} +1 -1
- package/dist-embed/chunks/{pieDiagram-E7YTZNPT-LRVEFdTA.js → pieDiagram-E7YTZNPT-DkhDYj7K.js} +1 -1
- package/dist-embed/chunks/{pieDiagram-c941bede-DjCRmn-L.js → pieDiagram-c941bede-Ds-rlqjJ.js} +1 -1
- package/dist-embed/chunks/{pl-PL-T2D74RX3-C1YHW5JY.js → pl-PL-T2D74RX3-D5hzyBxL.js} +1 -1
- package/dist-embed/chunks/{plugin-DdlXgZum.js → plugin-BqLEv-U0.js} +1 -1
- package/dist-embed/chunks/{pt-BR-5N22H2LF-CeAhQlI9.js → pt-BR-5N22H2LF-CAs1Vbwd.js} +1 -1
- package/dist-embed/chunks/{pt-PT-UZXXM6DQ-GWUC3hdB.js → pt-PT-UZXXM6DQ-f3BuGnIL.js} +1 -1
- package/dist-embed/chunks/{quadrantDiagram-AXDQQJYC-8vY1ABOf.js → quadrantDiagram-AXDQQJYC-1ViFLfLW.js} +1 -1
- package/dist-embed/chunks/{quadrantDiagram-AXDQQJYC-C2i8SYpJ.js → quadrantDiagram-AXDQQJYC-B30POsrM.js} +1 -1
- package/dist-embed/chunks/{quadrantDiagram-AXDQQJYC-DFP2Eoj5.js → quadrantDiagram-AXDQQJYC-CqArYUyr.js} +1 -1
- package/dist-embed/chunks/{quadrantDiagram-cf8b8fe0-Bgejfr6D.js → quadrantDiagram-cf8b8fe0-QoN4fcns.js} +1 -1
- package/dist-embed/chunks/{railroadDiagram-O6MQD6OU-D8iXssMi.js → railroadDiagram-O6MQD6OU-BKrSAEIz.js} +1 -1
- package/dist-embed/chunks/{railroadDiagram-O6MQD6OU-Ck2bziJ8.js → railroadDiagram-O6MQD6OU-BelGMNLe.js} +1 -1
- package/dist-embed/chunks/{railroadDiagram-O6MQD6OU-B54ysFcl.js → railroadDiagram-O6MQD6OU-nWQg4Zha.js} +1 -1
- package/dist-embed/chunks/{renderer-Dsm4_V5Z.js → renderer-NdtLW87o.js} +1 -1
- package/dist-embed/chunks/{requirementDiagram-53bda41b-Don9LmwH.js → requirementDiagram-53bda41b-DRQpj1S7.js} +1 -1
- package/dist-embed/chunks/{requirementDiagram-BXWQKSXE-BKfTxvAx.js → requirementDiagram-BXWQKSXE-BsKIaNx-.js} +1 -1
- package/dist-embed/chunks/{requirementDiagram-BXWQKSXE-BluOoSWL.js → requirementDiagram-BXWQKSXE-C-ZNAzIA.js} +1 -1
- package/dist-embed/chunks/{requirementDiagram-BXWQKSXE-DzYOora7.js → requirementDiagram-BXWQKSXE-Dj_84sJE.js} +1 -1
- package/dist-embed/chunks/{ro-RO-JPDTUUEW-CfstrBRj.js → ro-RO-JPDTUUEW-Ck6Pl6T-.js} +1 -1
- package/dist-embed/chunks/{ru-RU-B4JR7IUQ-CprdF87i.js → ru-RU-B4JR7IUQ-B5ZFvbSm.js} +1 -1
- package/dist-embed/chunks/{sankeyDiagram-P5KCCOFB-BbWM5efa.js → sankeyDiagram-P5KCCOFB-BwrjNR9f.js} +1 -1
- package/dist-embed/chunks/{sankeyDiagram-P5KCCOFB-BO6yMQvy.js → sankeyDiagram-P5KCCOFB-CvESkMt0.js} +1 -1
- package/dist-embed/chunks/{sankeyDiagram-P5KCCOFB-CFPCOaBB.js → sankeyDiagram-P5KCCOFB-DNcJ8lTV.js} +1 -1
- package/dist-embed/chunks/{sankeyDiagram-c3ef121a-foGV8N2_.js → sankeyDiagram-c3ef121a-NSdOSIUQ.js} +1 -1
- package/dist-embed/chunks/{sequenceDiagram-82a5b84f-6pLDiDbB.js → sequenceDiagram-82a5b84f-Cxc06-S6.js} +1 -1
- package/dist-embed/chunks/{sequenceDiagram-WJ2MYXX4-C0zWhG8B.js → sequenceDiagram-WJ2MYXX4-CdKf7EXa.js} +1 -1
- package/dist-embed/chunks/{sequenceDiagram-WJ2MYXX4-w41G2RsH.js → sequenceDiagram-WJ2MYXX4-DYkcZR01.js} +1 -1
- package/dist-embed/chunks/{sequenceDiagram-WJ2MYXX4-BGIbaSlI.js → sequenceDiagram-WJ2MYXX4-vrbMF2lh.js} +1 -1
- package/dist-embed/chunks/{sheet-4YYsjTBK.js → sheet-BFp5lgzm.js} +1 -1
- package/dist-embed/chunks/{si-LK-N5RQ5JYF-CBECC-z7.js → si-LK-N5RQ5JYF-turarKuZ.js} +1 -1
- package/dist-embed/chunks/{sizeCapture-INFHLROL-C4Um3fMN.js → sizeCapture-INFHLROL-B05-5pAF.js} +1 -1
- package/dist-embed/chunks/{sizeCapture-INFHLROL-WE85tnHS.js → sizeCapture-INFHLROL-BTK449Mq.js} +1 -1
- package/dist-embed/chunks/{sizeCapture-INFHLROL-DAIM469w.js → sizeCapture-INFHLROL-DBDGASUh.js} +1 -1
- package/dist-embed/chunks/{sk-SK-C5VTKIMK-DMJnHZkB.js → sk-SK-C5VTKIMK-B61Eejyh.js} +1 -1
- package/dist-embed/chunks/{sl-SI-NN7IZMDC-7Z4OGoYj.js → sl-SI-NN7IZMDC-Vmd7HFee.js} +1 -1
- package/dist-embed/chunks/{state-DWaoyyF_.js → state-B-9Ja93T.js} +1 -1
- package/dist-embed/chunks/{stateDiagram-43e79a5f-S14mEvLi.js → stateDiagram-43e79a5f-BNfT8BMf.js} +1 -1
- package/dist-embed/chunks/{stateDiagram-D77RDMKH-BC6_D1er.js → stateDiagram-D77RDMKH-B4P4foWm.js} +1 -1
- package/dist-embed/chunks/{stateDiagram-D77RDMKH-BKswuz-D.js → stateDiagram-D77RDMKH-DGy5pPcJ.js} +1 -1
- package/dist-embed/chunks/{stateDiagram-D77RDMKH-DaQTz1j_.js → stateDiagram-D77RDMKH-cX1LxuDW.js} +1 -1
- package/dist-embed/chunks/{stateDiagram-v2-2041ed4f-3GcjyBy-.js → stateDiagram-v2-2041ed4f-DT_Cb2bL.js} +1 -1
- package/dist-embed/chunks/{stateDiagram-v2-MP3YSRHH-Bm6DUSD7.js → stateDiagram-v2-MP3YSRHH-BSxDwfLM.js} +1 -1
- package/dist-embed/chunks/{stateDiagram-v2-MP3YSRHH-z0Ujpn87.js → stateDiagram-v2-MP3YSRHH-CoF-m0JB.js} +1 -1
- package/dist-embed/chunks/{stateDiagram-v2-MP3YSRHH-DOLQNFRH.js → stateDiagram-v2-MP3YSRHH-GuE-uLPq.js} +1 -1
- package/dist-embed/chunks/{styles-455b33cd-BRr4X9hL.js → styles-455b33cd-Cp1Ujuo8.js} +1 -1
- package/dist-embed/chunks/{styles-f932cba9-UDBXX5a8.js → styles-f932cba9-CxoS5hwQ.js} +1 -1
- package/dist-embed/chunks/{styles-fcc2142b-CSFZuop9.js → styles-fcc2142b-ByLmqETE.js} +1 -1
- package/dist-embed/chunks/{subset-shared.chunk-B3u5KdN0.js → subset-shared.chunk-BsVAPxIg.js} +1 -1
- package/dist-embed/chunks/{subset-worker.chunk-CT6VKIPU.js → subset-worker.chunk-BS8PIaQX.js} +1 -1
- package/dist-embed/chunks/{substates-CZP38fPi.js → substates-CeUNAPt2.js} +1 -1
- package/dist-embed/chunks/{sv-SE-XGPEYMSR-FpJ1BpmI.js → sv-SE-XGPEYMSR-C9lMr16n.js} +1 -1
- package/dist-embed/chunks/{svgDrawCommon-148a3cd9-F4sRB6k0.js → svgDrawCommon-148a3cd9-BHhr6lti.js} +1 -1
- package/dist-embed/chunks/{swimlanes-42K2YHIH-EibPKc5o.js → swimlanes-42K2YHIH-DKdFBGRm.js} +1 -1
- package/dist-embed/chunks/{swimlanes-42K2YHIH-Bm2EMEIj.js → swimlanes-42K2YHIH-DQJZa-xA.js} +1 -1
- package/dist-embed/chunks/{swimlanes-42K2YHIH-60OSS3vA.js → swimlanes-42K2YHIH-RHIIyMRW.js} +1 -1
- package/dist-embed/chunks/{swimlanesDiagram-VR7AAH4N-C5g-ZOer.js → swimlanesDiagram-VR7AAH4N-DPhzMK19.js} +1 -1
- package/dist-embed/chunks/{swimlanesDiagram-VR7AAH4N-mQfKwLBP.js → swimlanesDiagram-VR7AAH4N-qQpIxgus.js} +1 -1
- package/dist-embed/chunks/{swimlanesDiagram-VR7AAH4N-Dd4rkKxx.js → swimlanesDiagram-VR7AAH4N-rV-EK234.js} +1 -1
- package/dist-embed/chunks/{ta-IN-2NMHFXQM-CGrfHW-T.js → ta-IN-2NMHFXQM-DDvtKbYb.js} +1 -1
- package/dist-embed/chunks/{th-TH-HPSO5L25-XSyuAjYd.js → th-TH-HPSO5L25-Cuk9i9q1.js} +1 -1
- package/dist-embed/chunks/{timeline-definition-24CTP7MA-Dw-j__OF.js → timeline-definition-24CTP7MA-B0VfyyC9.js} +1 -1
- package/dist-embed/chunks/{timeline-definition-24CTP7MA-DrK86SXx.js → timeline-definition-24CTP7MA-BYQXqujM.js} +1 -1
- package/dist-embed/chunks/{timeline-definition-24CTP7MA-4xcdFEe3.js → timeline-definition-24CTP7MA-CNJYLQV3.js} +1 -1
- package/dist-embed/chunks/{timeline-definition-7545f45a-BbuRGmnt.js → timeline-definition-7545f45a-B6u65RjP.js} +1 -1
- package/dist-embed/chunks/{tr-TR-DEFEU3FU-Bmilf4wA.js → tr-TR-DEFEU3FU-Dt5AbXXF.js} +1 -1
- package/dist-embed/chunks/{uk-UA-QMV73CPH-D7__x2rc.js → uk-UA-QMV73CPH-CqxkvO2g.js} +1 -1
- package/dist-embed/chunks/{vennDiagram-4TSXK5OY-Dyygo0QE.js → vennDiagram-4TSXK5OY-8GPjZ_rY.js} +1 -1
- package/dist-embed/chunks/{vennDiagram-4TSXK5OY-DU_TiJPw.js → vennDiagram-4TSXK5OY-BC0uMGWS.js} +1 -1
- package/dist-embed/chunks/{vennDiagram-4TSXK5OY-aBwLZ5sI.js → vennDiagram-4TSXK5OY-ERcpoENM.js} +1 -1
- package/dist-embed/chunks/{vi-VN-M7AON7JQ-Cp1NNDFR.js → vi-VN-M7AON7JQ-CZtlZzss.js} +1 -1
- package/dist-embed/chunks/{wardleyDiagram-VM6X3IG4-BUupZELs.js → wardleyDiagram-VM6X3IG4-Bubuc1xO.js} +1 -1
- package/dist-embed/chunks/{wardleyDiagram-VM6X3IG4-8uoJ6em9.js → wardleyDiagram-VM6X3IG4-DMJNYu8Y.js} +1 -1
- package/dist-embed/chunks/{wardleyDiagram-VM6X3IG4-DJsJzMBH.js → wardleyDiagram-VM6X3IG4-DdRbpzRB.js} +1 -1
- package/dist-embed/chunks/workbook-BQLbQvZ-.js +1 -0
- package/dist-embed/chunks/{write-DDDJmUTa.js → write-D-y9_9sL.js} +1 -1
- package/dist-embed/chunks/{xychartDiagram-3f383b91-CbuvIhMQ.js → xychartDiagram-3f383b91-CEkYRds9.js} +1 -1
- package/dist-embed/chunks/{xychartDiagram-S5SC5T6Z-D2_kfHro.js → xychartDiagram-S5SC5T6Z-C0WCXM2P.js} +1 -1
- package/dist-embed/chunks/{xychartDiagram-S5SC5T6Z-AUNwwAUK.js → xychartDiagram-S5SC5T6Z-DKWKSC-B.js} +1 -1
- package/dist-embed/chunks/{xychartDiagram-S5SC5T6Z-B9ZiyRsR.js → xychartDiagram-S5SC5T6Z-iG96dorC.js} +1 -1
- package/dist-embed/chunks/{zh-CN-LNUGB5OW-1W7T5K4d.js → zh-CN-LNUGB5OW-6_SDF9o2.js} +1 -1
- package/dist-embed/chunks/{zh-HK-E62DVLB3-6wLRdIMH.js → zh-HK-E62DVLB3-em8dd9Nl.js} +1 -1
- package/dist-embed/chunks/{zh-TW-RAJ6MFWO-Bq3E0gIc.js → zh-TW-RAJ6MFWO-BCzbAoXj.js} +1 -1
- package/dist-embed/datalayer-app-main.js +68 -74
- package/lib/apps/plugins/chat/ChatView.js +96 -38
- package/lib/chat/anonymous/AnonymousChat.d.ts +0 -3
- package/lib/chat/anonymous/anonymousMode.d.ts +0 -4
- package/lib/chat/anonymous/anonymousMode.js +0 -4
- package/lib/chat/base/ChatBase.js +2 -58
- package/lib/chat/index.d.ts +1 -1
- package/lib/chat/index.js +1 -1
- package/lib/chat/indicators/index.d.ts +3 -12
- package/lib/chat/indicators/index.js +0 -15
- package/lib/chat/prompt/InputPrompt.d.ts +28 -16
- package/lib/chat/prompt/InputPrompt.js +60 -12
- package/lib/chat/prompt/menus/EquipmentMenus.d.ts +58 -81
- package/lib/chat/prompt/menus/EquipmentMenus.js +190 -127
- package/lib/chat/prompt/menus/ToolsMenu.d.ts +2 -11
- package/lib/chat/prompt/menus/ToolsMenu.js +8 -43
- package/lib/chat/prompt/menus/equipmentRows.d.ts +160 -0
- package/lib/chat/prompt/menus/equipmentRows.js +349 -0
- package/lib/chat/prompt/menus/index.d.ts +2 -1
- package/lib/chat/prompt/menus/index.js +2 -1
- package/lib/hooks/useConversationSwitches.d.ts +29 -0
- package/lib/hooks/useConversationSwitches.js +102 -0
- package/lib/hooks/useMcpToolSwitches.d.ts +13 -0
- package/lib/hooks/useMcpToolSwitches.js +96 -0
- package/lib/portable/index.d.ts +1 -1
- package/lib/portable/sessions.d.ts +47 -0
- package/lib/portable/sessions.js +7 -0
- package/lib/types/chat.d.ts +2 -3
- package/package.json +1 -1
- package/dist-embed/chunks/ChatView-BxxW10wd.js +0 -32
- package/dist-embed/chunks/index.esm-ClpGzk_d.js +0 -1
- package/dist-embed/chunks/workbook-B-AfiHkC.js +0 -1
- package/lib/chat/indicators/DisabledIndicator.d.ts +0 -18
- package/lib/chat/indicators/DisabledIndicator.js +0 -22
- package/lib/chat/indicators/McpStatusIndicator.d.ts +0 -18
- package/lib/chat/indicators/McpStatusIndicator.js +0 -106
- package/lib/chat/indicators/SkillsStatusIndicator.d.ts +0 -13
- package/lib/chat/indicators/SkillsStatusIndicator.js +0 -88
- package/lib/chat/prompt/menus/SkillsMenu.d.ts +0 -10
- package/lib/chat/prompt/menus/SkillsMenu.js +0 -49
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as re}from"./chunk-XXDRQBXY-
|
|
1
|
+
import{g as re}from"./chunk-XXDRQBXY-B6fuzLc9.js";import{s as oe}from"./chunk-POPQ4Y6H-DacAiEUG.js";import{_ as l,l as O,u as ae,v as ce,y as le,B as F,c as $,i as V,T as he}from"./mermaid.core-BiF8MSuv.js";import{v as de}from"./v4-CeVyOvU8.js";import{A as ge,w as ue,z as pe}from"./index-wHoWF_7d.js";import"../datalayer-app-main.js";import"./fastdom-promised-DP8eIWg7.js";import"./_baseRest-CxHO6LCs.js";import"./isObject-CeOzAI2h.js";import"./forEach-Bvicu226.js";import"./isSymbol-DfwdEMHq.js";import"./isUndefined-QeaoSmDB.js";import"./stringify-D92ucQ0I.js";import"./dayjs.min-u3zuoSR8.js";var X=(function(){var e=l(function(x,n,i,o){for(i=i||{},o=x.length;o--;i[x[o]]=n);return i},"o"),r=[1,4],u=[1,13],c=[1,12],t=[1,15],h=[1,16],f=[1,20],m=[1,19],E=[6,7,8],v=[1,26],C=[1,24],I=[1,25],d=[6,7,11],w=[1,6,13,15,16,19,22],Y=[1,33],q=[1,34],R=[1,6,7,11,13,15,16,19,22],G={trace:l(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,MINDMAP:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,ICON:15,CLASS:16,nodeWithId:17,nodeWithoutId:18,NODE_DSTART:19,NODE_DESCR:20,NODE_DEND:21,NODE_ID:22,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"MINDMAP",11:"EOF",13:"SPACELIST",15:"ICON",16:"CLASS",19:"NODE_DSTART",20:"NODE_DESCR",21:"NODE_DEND",22:"NODE_ID"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[18,3],[17,1],[17,4]],performAction:l(function(n,i,o,a,p,s,A){var g=s.length-1;switch(p){case 6:case 7:return a;case 8:a.getLogger().trace("Stop NL ");break;case 9:a.getLogger().trace("Stop EOF ");break;case 11:a.getLogger().trace("Stop NL2 ");break;case 12:a.getLogger().trace("Stop EOF2 ");break;case 15:a.getLogger().info("Node: ",s[g].id),a.addNode(s[g-1].length,s[g].id,s[g].descr,s[g].type);break;case 16:a.getLogger().trace("Icon: ",s[g]),a.decorateNode({icon:s[g]});break;case 17:case 21:a.decorateNode({class:s[g]});break;case 18:a.getLogger().trace("SPACELIST");break;case 19:a.getLogger().trace("Node: ",s[g].id),a.addNode(0,s[g].id,s[g].descr,s[g].type);break;case 20:a.decorateNode({icon:s[g]});break;case 25:a.getLogger().trace("node found ..",s[g-2]),this.$={id:s[g-1],descr:s[g-1],type:a.getType(s[g-2],s[g])};break;case 26:this.$={id:s[g],descr:s[g],type:a.nodeType.DEFAULT};break;case 27:a.getLogger().trace("node found ..",s[g-3]),this.$={id:s[g-3],descr:s[g-1],type:a.getType(s[g-2],s[g])};break}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:r},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:r},{6:u,7:[1,10],9:9,12:11,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},e(E,[2,3]),{1:[2,2]},e(E,[2,4]),e(E,[2,5]),{1:[2,6],6:u,12:21,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},{6:u,9:22,12:11,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},{6:v,7:C,10:23,11:I},e(d,[2,22],{17:17,18:18,14:27,15:[1,28],16:[1,29],19:f,22:m}),e(d,[2,18]),e(d,[2,19]),e(d,[2,20]),e(d,[2,21]),e(d,[2,23]),e(d,[2,24]),e(d,[2,26],{19:[1,30]}),{20:[1,31]},{6:v,7:C,10:32,11:I},{1:[2,7],6:u,12:21,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},e(w,[2,14],{7:Y,11:q}),e(R,[2,8]),e(R,[2,9]),e(R,[2,10]),e(d,[2,15]),e(d,[2,16]),e(d,[2,17]),{20:[1,35]},{21:[1,36]},e(w,[2,13],{7:Y,11:q}),e(R,[2,11]),e(R,[2,12]),{21:[1,37]},e(d,[2,25]),e(d,[2,27])],defaultActions:{2:[2,1],6:[2,2]},parseError:l(function(n,i){if(i.recoverable)this.trace(n);else{var o=new Error(n);throw o.hash=i,o}},"parseError"),parse:l(function(n){var i=this,o=[0],a=[],p=[null],s=[],A=this.table,g="",P=0,J=0,te=2,K=1,ie=s.slice.call(arguments,1),y=Object.create(this.lexer),D={yy:{}};for(var j in this.yy)Object.prototype.hasOwnProperty.call(this.yy,j)&&(D.yy[j]=this.yy[j]);y.setInput(n,D.yy),D.yy.lexer=y,D.yy.parser=this,typeof y.yylloc>"u"&&(y.yylloc={});var H=y.yylloc;s.push(H);var ne=y.options&&y.options.ranges;typeof D.yy.parseError=="function"?this.parseError=D.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function se(k){o.length=o.length-2*k,p.length=p.length-k,s.length=s.length-k}l(se,"popStack");function Q(){var k;return k=a.pop()||y.lex()||K,typeof k!="number"&&(k instanceof Array&&(a=k,k=a.pop()),k=i.symbols_[k]||k),k}l(Q,"lex");for(var _,L,b,z,T={},M,S,Z,U;;){if(L=o[o.length-1],this.defaultActions[L]?b=this.defaultActions[L]:((_===null||typeof _>"u")&&(_=Q()),b=A[L]&&A[L][_]),typeof b>"u"||!b.length||!b[0]){var W="";U=[];for(M in A[L])this.terminals_[M]&&M>te&&U.push("'"+this.terminals_[M]+"'");y.showPosition?W="Parse error on line "+(P+1)+`:
|
|
2
2
|
`+y.showPosition()+`
|
|
3
3
|
Expecting `+U.join(", ")+", got '"+(this.terminals_[_]||_)+"'":W="Parse error on line "+(P+1)+": Unexpected "+(_==K?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(W,{text:y.match,token:this.terminals_[_]||_,line:y.yylineno,loc:H,expected:U})}if(b[0]instanceof Array&&b.length>1)throw new Error("Parse Error: multiple actions possible at state: "+L+", token: "+_);switch(b[0]){case 1:o.push(_),p.push(y.yytext),s.push(y.yylloc),o.push(b[1]),_=null,J=y.yyleng,g=y.yytext,P=y.yylineno,H=y.yylloc;break;case 2:if(S=this.productions_[b[1]][1],T.$=p[p.length-S],T._$={first_line:s[s.length-(S||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(S||1)].first_column,last_column:s[s.length-1].last_column},ne&&(T._$.range=[s[s.length-(S||1)].range[0],s[s.length-1].range[1]]),z=this.performAction.apply(T,[g,J,P,D.yy,b[1],p,s].concat(ie)),typeof z<"u")return z;S&&(o=o.slice(0,-1*S*2),p=p.slice(0,-1*S),s=s.slice(0,-1*S)),o.push(this.productions_[b[1]][0]),p.push(T.$),s.push(T._$),Z=A[o[o.length-2]][o[o.length-1]],o.push(Z);break;case 3:return!0}}return!0},"parse")},ee=(function(){var x={EOF:1,parseError:l(function(i,o){if(this.yy.parser)this.yy.parser.parseError(i,o);else throw new Error(i)},"parseError"),setInput:l(function(n,i){return this.yy=i||this.yy||{},this._input=n,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:l(function(){var n=this._input[0];this.yytext+=n,this.yyleng++,this.offset++,this.match+=n,this.matched+=n;var i=n.match(/(?:\r\n?|\n).*/g);return i?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),n},"input"),unput:l(function(n){var i=n.length,o=n.split(/(?:\r\n?|\n)/g);this._input=n+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-i),this.offset-=i;var a=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),o.length-1&&(this.yylineno-=o.length-1);var p=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:o?(o.length===a.length?this.yylloc.first_column:0)+a[a.length-o.length].length-o[0].length:this.yylloc.first_column-i},this.options.ranges&&(this.yylloc.range=[p[0],p[0]+this.yyleng-i]),this.yyleng=this.yytext.length,this},"unput"),more:l(function(){return this._more=!0,this},"more"),reject:l(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:l(function(n){this.unput(this.match.slice(n))},"less"),pastInput:l(function(){var n=this.matched.substr(0,this.matched.length-this.match.length);return(n.length>20?"...":"")+n.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:l(function(){var n=this.match;return n.length<20&&(n+=this._input.substr(0,20-n.length)),(n.substr(0,20)+(n.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:l(function(){var n=this.pastInput(),i=new Array(n.length+1).join("-");return n+this.upcomingInput()+`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as re}from"./chunk-XXDRQBXY-
|
|
1
|
+
import{g as re}from"./chunk-XXDRQBXY-Bo_XDdf-.js";import{s as oe}from"./chunk-POPQ4Y6H-BCHaCocF.js";import{_ as l,l as O,u as ae,v as ce,y as le,B as F,c as $,i as V,T as he}from"./index-C-4crJTg.js";import{v as de}from"./v4-CeVyOvU8.js";import{A as ge,w as ue,z as pe}from"./index-wHoWF_7d.js";import"./index-CJys1M3A.js";import"../datalayer-app-main.js";import"./fastdom-promised-DP8eIWg7.js";import"./_baseRest-CxHO6LCs.js";import"./isObject-CeOzAI2h.js";import"./forEach-Bvicu226.js";import"./isSymbol-DfwdEMHq.js";import"./isUndefined-QeaoSmDB.js";import"./stringify-D92ucQ0I.js";import"./dayjs.min-u3zuoSR8.js";var X=(function(){var e=l(function(x,n,i,o){for(i=i||{},o=x.length;o--;i[x[o]]=n);return i},"o"),r=[1,4],u=[1,13],c=[1,12],t=[1,15],h=[1,16],f=[1,20],m=[1,19],E=[6,7,8],v=[1,26],C=[1,24],I=[1,25],d=[6,7,11],w=[1,6,13,15,16,19,22],Y=[1,33],q=[1,34],R=[1,6,7,11,13,15,16,19,22],G={trace:l(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,MINDMAP:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,ICON:15,CLASS:16,nodeWithId:17,nodeWithoutId:18,NODE_DSTART:19,NODE_DESCR:20,NODE_DEND:21,NODE_ID:22,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"MINDMAP",11:"EOF",13:"SPACELIST",15:"ICON",16:"CLASS",19:"NODE_DSTART",20:"NODE_DESCR",21:"NODE_DEND",22:"NODE_ID"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[18,3],[17,1],[17,4]],performAction:l(function(n,i,o,a,p,s,A){var g=s.length-1;switch(p){case 6:case 7:return a;case 8:a.getLogger().trace("Stop NL ");break;case 9:a.getLogger().trace("Stop EOF ");break;case 11:a.getLogger().trace("Stop NL2 ");break;case 12:a.getLogger().trace("Stop EOF2 ");break;case 15:a.getLogger().info("Node: ",s[g].id),a.addNode(s[g-1].length,s[g].id,s[g].descr,s[g].type);break;case 16:a.getLogger().trace("Icon: ",s[g]),a.decorateNode({icon:s[g]});break;case 17:case 21:a.decorateNode({class:s[g]});break;case 18:a.getLogger().trace("SPACELIST");break;case 19:a.getLogger().trace("Node: ",s[g].id),a.addNode(0,s[g].id,s[g].descr,s[g].type);break;case 20:a.decorateNode({icon:s[g]});break;case 25:a.getLogger().trace("node found ..",s[g-2]),this.$={id:s[g-1],descr:s[g-1],type:a.getType(s[g-2],s[g])};break;case 26:this.$={id:s[g],descr:s[g],type:a.nodeType.DEFAULT};break;case 27:a.getLogger().trace("node found ..",s[g-3]),this.$={id:s[g-3],descr:s[g-1],type:a.getType(s[g-2],s[g])};break}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:r},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:r},{6:u,7:[1,10],9:9,12:11,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},e(E,[2,3]),{1:[2,2]},e(E,[2,4]),e(E,[2,5]),{1:[2,6],6:u,12:21,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},{6:u,9:22,12:11,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},{6:v,7:C,10:23,11:I},e(d,[2,22],{17:17,18:18,14:27,15:[1,28],16:[1,29],19:f,22:m}),e(d,[2,18]),e(d,[2,19]),e(d,[2,20]),e(d,[2,21]),e(d,[2,23]),e(d,[2,24]),e(d,[2,26],{19:[1,30]}),{20:[1,31]},{6:v,7:C,10:32,11:I},{1:[2,7],6:u,12:21,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},e(w,[2,14],{7:Y,11:q}),e(R,[2,8]),e(R,[2,9]),e(R,[2,10]),e(d,[2,15]),e(d,[2,16]),e(d,[2,17]),{20:[1,35]},{21:[1,36]},e(w,[2,13],{7:Y,11:q}),e(R,[2,11]),e(R,[2,12]),{21:[1,37]},e(d,[2,25]),e(d,[2,27])],defaultActions:{2:[2,1],6:[2,2]},parseError:l(function(n,i){if(i.recoverable)this.trace(n);else{var o=new Error(n);throw o.hash=i,o}},"parseError"),parse:l(function(n){var i=this,o=[0],a=[],p=[null],s=[],A=this.table,g="",P=0,J=0,te=2,K=1,ie=s.slice.call(arguments,1),y=Object.create(this.lexer),D={yy:{}};for(var j in this.yy)Object.prototype.hasOwnProperty.call(this.yy,j)&&(D.yy[j]=this.yy[j]);y.setInput(n,D.yy),D.yy.lexer=y,D.yy.parser=this,typeof y.yylloc>"u"&&(y.yylloc={});var H=y.yylloc;s.push(H);var ne=y.options&&y.options.ranges;typeof D.yy.parseError=="function"?this.parseError=D.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function se(k){o.length=o.length-2*k,p.length=p.length-k,s.length=s.length-k}l(se,"popStack");function Q(){var k;return k=a.pop()||y.lex()||K,typeof k!="number"&&(k instanceof Array&&(a=k,k=a.pop()),k=i.symbols_[k]||k),k}l(Q,"lex");for(var _,L,b,z,T={},M,S,Z,U;;){if(L=o[o.length-1],this.defaultActions[L]?b=this.defaultActions[L]:((_===null||typeof _>"u")&&(_=Q()),b=A[L]&&A[L][_]),typeof b>"u"||!b.length||!b[0]){var W="";U=[];for(M in A[L])this.terminals_[M]&&M>te&&U.push("'"+this.terminals_[M]+"'");y.showPosition?W="Parse error on line "+(P+1)+`:
|
|
2
2
|
`+y.showPosition()+`
|
|
3
3
|
Expecting `+U.join(", ")+", got '"+(this.terminals_[_]||_)+"'":W="Parse error on line "+(P+1)+": Unexpected "+(_==K?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(W,{text:y.match,token:this.terminals_[_]||_,line:y.yylineno,loc:H,expected:U})}if(b[0]instanceof Array&&b.length>1)throw new Error("Parse Error: multiple actions possible at state: "+L+", token: "+_);switch(b[0]){case 1:o.push(_),p.push(y.yytext),s.push(y.yylloc),o.push(b[1]),_=null,J=y.yyleng,g=y.yytext,P=y.yylineno,H=y.yylloc;break;case 2:if(S=this.productions_[b[1]][1],T.$=p[p.length-S],T._$={first_line:s[s.length-(S||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(S||1)].first_column,last_column:s[s.length-1].last_column},ne&&(T._$.range=[s[s.length-(S||1)].range[0],s[s.length-1].range[1]]),z=this.performAction.apply(T,[g,J,P,D.yy,b[1],p,s].concat(ie)),typeof z<"u")return z;S&&(o=o.slice(0,-1*S*2),p=p.slice(0,-1*S),s=s.slice(0,-1*S)),o.push(this.productions_[b[1]][0]),p.push(T.$),s.push(T._$),Z=A[o[o.length-2]][o[o.length-1]],o.push(Z);break;case 3:return!0}}return!0},"parse")},ee=(function(){var x={EOF:1,parseError:l(function(i,o){if(this.yy.parser)this.yy.parser.parseError(i,o);else throw new Error(i)},"parseError"),setInput:l(function(n,i){return this.yy=i||this.yy||{},this._input=n,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:l(function(){var n=this._input[0];this.yytext+=n,this.yyleng++,this.offset++,this.match+=n,this.matched+=n;var i=n.match(/(?:\r\n?|\n).*/g);return i?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),n},"input"),unput:l(function(n){var i=n.length,o=n.split(/(?:\r\n?|\n)/g);this._input=n+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-i),this.offset-=i;var a=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),o.length-1&&(this.yylineno-=o.length-1);var p=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:o?(o.length===a.length?this.yylloc.first_column:0)+a[a.length-o.length].length-o[0].length:this.yylloc.first_column-i},this.options.ranges&&(this.yylloc.range=[p[0],p[0]+this.yyleng-i]),this.yyleng=this.yytext.length,this},"unput"),more:l(function(){return this._more=!0,this},"more"),reject:l(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:l(function(n){this.unput(this.match.slice(n))},"less"),pastInput:l(function(){var n=this.matched.substr(0,this.matched.length-this.match.length);return(n.length>20?"...":"")+n.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:l(function(){var n=this.match;return n.length<20&&(n+=this._input.substr(0,20-n.length)),(n.substr(0,20)+(n.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:l(function(){var n=this.pastInput(),i=new Array(n.length+1).join("-");return n+this.upcomingInput()+`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as re}from"./chunk-XXDRQBXY-
|
|
1
|
+
import{g as re}from"./chunk-XXDRQBXY-Bz5lFaJG.js";import{s as oe}from"./chunk-POPQ4Y6H-DicNgh7k.js";import{_ as l,l as O,u as ae,v as ce,y as le,B as F,c as $,i as V,T as he}from"./index-BzdaTJ02.js";import{v as de}from"./v4-CeVyOvU8.js";import{A as ge,w as ue,z as pe}from"./index-wHoWF_7d.js";import"./index-CJys1M3A.js";import"../datalayer-app-main.js";import"./fastdom-promised-DP8eIWg7.js";import"./_baseRest-CxHO6LCs.js";import"./isObject-CeOzAI2h.js";import"./forEach-Bvicu226.js";import"./isSymbol-DfwdEMHq.js";import"./isUndefined-QeaoSmDB.js";import"./stringify-D92ucQ0I.js";import"./dayjs.min-u3zuoSR8.js";var X=(function(){var e=l(function(x,n,i,o){for(i=i||{},o=x.length;o--;i[x[o]]=n);return i},"o"),r=[1,4],u=[1,13],c=[1,12],t=[1,15],h=[1,16],f=[1,20],m=[1,19],E=[6,7,8],v=[1,26],C=[1,24],I=[1,25],d=[6,7,11],w=[1,6,13,15,16,19,22],Y=[1,33],q=[1,34],R=[1,6,7,11,13,15,16,19,22],G={trace:l(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,MINDMAP:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,ICON:15,CLASS:16,nodeWithId:17,nodeWithoutId:18,NODE_DSTART:19,NODE_DESCR:20,NODE_DEND:21,NODE_ID:22,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"MINDMAP",11:"EOF",13:"SPACELIST",15:"ICON",16:"CLASS",19:"NODE_DSTART",20:"NODE_DESCR",21:"NODE_DEND",22:"NODE_ID"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[18,3],[17,1],[17,4]],performAction:l(function(n,i,o,a,p,s,A){var g=s.length-1;switch(p){case 6:case 7:return a;case 8:a.getLogger().trace("Stop NL ");break;case 9:a.getLogger().trace("Stop EOF ");break;case 11:a.getLogger().trace("Stop NL2 ");break;case 12:a.getLogger().trace("Stop EOF2 ");break;case 15:a.getLogger().info("Node: ",s[g].id),a.addNode(s[g-1].length,s[g].id,s[g].descr,s[g].type);break;case 16:a.getLogger().trace("Icon: ",s[g]),a.decorateNode({icon:s[g]});break;case 17:case 21:a.decorateNode({class:s[g]});break;case 18:a.getLogger().trace("SPACELIST");break;case 19:a.getLogger().trace("Node: ",s[g].id),a.addNode(0,s[g].id,s[g].descr,s[g].type);break;case 20:a.decorateNode({icon:s[g]});break;case 25:a.getLogger().trace("node found ..",s[g-2]),this.$={id:s[g-1],descr:s[g-1],type:a.getType(s[g-2],s[g])};break;case 26:this.$={id:s[g],descr:s[g],type:a.nodeType.DEFAULT};break;case 27:a.getLogger().trace("node found ..",s[g-3]),this.$={id:s[g-3],descr:s[g-1],type:a.getType(s[g-2],s[g])};break}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:r},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:r},{6:u,7:[1,10],9:9,12:11,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},e(E,[2,3]),{1:[2,2]},e(E,[2,4]),e(E,[2,5]),{1:[2,6],6:u,12:21,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},{6:u,9:22,12:11,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},{6:v,7:C,10:23,11:I},e(d,[2,22],{17:17,18:18,14:27,15:[1,28],16:[1,29],19:f,22:m}),e(d,[2,18]),e(d,[2,19]),e(d,[2,20]),e(d,[2,21]),e(d,[2,23]),e(d,[2,24]),e(d,[2,26],{19:[1,30]}),{20:[1,31]},{6:v,7:C,10:32,11:I},{1:[2,7],6:u,12:21,13:c,14:14,15:t,16:h,17:17,18:18,19:f,22:m},e(w,[2,14],{7:Y,11:q}),e(R,[2,8]),e(R,[2,9]),e(R,[2,10]),e(d,[2,15]),e(d,[2,16]),e(d,[2,17]),{20:[1,35]},{21:[1,36]},e(w,[2,13],{7:Y,11:q}),e(R,[2,11]),e(R,[2,12]),{21:[1,37]},e(d,[2,25]),e(d,[2,27])],defaultActions:{2:[2,1],6:[2,2]},parseError:l(function(n,i){if(i.recoverable)this.trace(n);else{var o=new Error(n);throw o.hash=i,o}},"parseError"),parse:l(function(n){var i=this,o=[0],a=[],p=[null],s=[],A=this.table,g="",P=0,J=0,te=2,K=1,ie=s.slice.call(arguments,1),y=Object.create(this.lexer),D={yy:{}};for(var j in this.yy)Object.prototype.hasOwnProperty.call(this.yy,j)&&(D.yy[j]=this.yy[j]);y.setInput(n,D.yy),D.yy.lexer=y,D.yy.parser=this,typeof y.yylloc>"u"&&(y.yylloc={});var H=y.yylloc;s.push(H);var ne=y.options&&y.options.ranges;typeof D.yy.parseError=="function"?this.parseError=D.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function se(k){o.length=o.length-2*k,p.length=p.length-k,s.length=s.length-k}l(se,"popStack");function Q(){var k;return k=a.pop()||y.lex()||K,typeof k!="number"&&(k instanceof Array&&(a=k,k=a.pop()),k=i.symbols_[k]||k),k}l(Q,"lex");for(var _,L,b,z,T={},M,S,Z,U;;){if(L=o[o.length-1],this.defaultActions[L]?b=this.defaultActions[L]:((_===null||typeof _>"u")&&(_=Q()),b=A[L]&&A[L][_]),typeof b>"u"||!b.length||!b[0]){var W="";U=[];for(M in A[L])this.terminals_[M]&&M>te&&U.push("'"+this.terminals_[M]+"'");y.showPosition?W="Parse error on line "+(P+1)+`:
|
|
2
2
|
`+y.showPosition()+`
|
|
3
3
|
Expecting `+U.join(", ")+", got '"+(this.terminals_[_]||_)+"'":W="Parse error on line "+(P+1)+": Unexpected "+(_==K?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(W,{text:y.match,token:this.terminals_[_]||_,line:y.yylineno,loc:H,expected:U})}if(b[0]instanceof Array&&b.length>1)throw new Error("Parse Error: multiple actions possible at state: "+L+", token: "+_);switch(b[0]){case 1:o.push(_),p.push(y.yytext),s.push(y.yylloc),o.push(b[1]),_=null,J=y.yyleng,g=y.yytext,P=y.yylineno,H=y.yylloc;break;case 2:if(S=this.productions_[b[1]][1],T.$=p[p.length-S],T._$={first_line:s[s.length-(S||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(S||1)].first_column,last_column:s[s.length-1].last_column},ne&&(T._$.range=[s[s.length-(S||1)].range[0],s[s.length-1].range[1]]),z=this.performAction.apply(T,[g,J,P,D.yy,b[1],p,s].concat(ie)),typeof z<"u")return z;S&&(o=o.slice(0,-1*S*2),p=p.slice(0,-1*S),s=s.slice(0,-1*S)),o.push(this.productions_[b[1]][0]),p.push(T.$),s.push(T._$),Z=A[o[o.length-2]][o[o.length-1]],o.push(Z);break;case 3:return!0}}return!0},"parse")},ee=(function(){var x={EOF:1,parseError:l(function(i,o){if(this.yy.parser)this.yy.parser.parseError(i,o);else throw new Error(i)},"parseError"),setInput:l(function(n,i){return this.yy=i||this.yy||{},this._input=n,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:l(function(){var n=this._input[0];this.yytext+=n,this.yyleng++,this.offset++,this.match+=n,this.matched+=n;var i=n.match(/(?:\r\n?|\n).*/g);return i?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),n},"input"),unput:l(function(n){var i=n.length,o=n.split(/(?:\r\n?|\n)/g);this._input=n+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-i),this.offset-=i;var a=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),o.length-1&&(this.yylineno-=o.length-1);var p=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:o?(o.length===a.length?this.yylloc.first_column:0)+a[a.length-o.length].length-o[0].length:this.yylloc.first_column-i},this.options.ranges&&(this.yylloc.range=[p[0],p[0]+this.yyleng-i]),this.yyleng=this.yytext.length,this},"unput"),more:l(function(){return this._more=!0,this},"more"),reject:l(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:l(function(n){this.unput(this.match.slice(n))},"less"),pastInput:l(function(){var n=this.matched.substr(0,this.matched.length-this.match.length);return(n.length>20?"...":"")+n.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:l(function(){var n=this.match;return n.length<20&&(n+=this._input.substr(0,20-n.length)),(n.substr(0,20)+(n.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:l(function(){var n=this.pastInput(),i=new Array(n.length+1).join("-");return n+this.upcomingInput()+`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{l as C,c as q,y as lt,I as ht,B as F,h as U,A as gt}from"./mermaid.core-
|
|
1
|
+
import{l as C,c as q,y as lt,I as ht,B as F,h as U,A as gt}from"./mermaid.core-1p09QPXM.js";import{c as tt}from"./cytoscape.esm-By_5ytxT.js";import{c as dt}from"./cytoscape-cose-bilkent-mZ95rL_r.js";import{c as ut}from"./createText-aed3d8b3-DTAS6DfQ.js";import{A as pt,w as ft,z as yt,s as mt}from"./index-wHoWF_7d.js";import"./index-DoBkwclg.js";import"../datalayer-app-main.js";import"./_baseRest-CxHO6LCs.js";import"./isObject-CeOzAI2h.js";import"./merge-Bj_36vYI.js";import"./Middleware-BiLBmIq0.js";import"./dayjs.min-u3zuoSR8.js";var Y=(function(){var e=function(w,o,s,l){for(s=s||{},l=w.length;l--;s[w[l]]=o);return s},a=[1,4],t=[1,13],n=[1,12],r=[1,15],i=[1,16],g=[1,20],u=[1,19],f=[6,7,8],E=[1,26],$=[1,24],O=[1,25],y=[6,7,11],B=[1,6,13,15,16,19,22],S=[1,33],N=[1,34],T=[1,6,7,11,13,15,16,19,22],H={trace:function(){},yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,MINDMAP:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,ICON:15,CLASS:16,nodeWithId:17,nodeWithoutId:18,NODE_DSTART:19,NODE_DESCR:20,NODE_DEND:21,NODE_ID:22,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"MINDMAP",11:"EOF",13:"SPACELIST",15:"ICON",16:"CLASS",19:"NODE_DSTART",20:"NODE_DESCR",21:"NODE_DEND",22:"NODE_ID"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[18,3],[17,1],[17,4]],performAction:function(o,s,l,h,p,c,R){var d=c.length-1;switch(p){case 6:case 7:return h;case 8:h.getLogger().trace("Stop NL ");break;case 9:h.getLogger().trace("Stop EOF ");break;case 11:h.getLogger().trace("Stop NL2 ");break;case 12:h.getLogger().trace("Stop EOF2 ");break;case 15:h.getLogger().info("Node: ",c[d].id),h.addNode(c[d-1].length,c[d].id,c[d].descr,c[d].type);break;case 16:h.getLogger().trace("Icon: ",c[d]),h.decorateNode({icon:c[d]});break;case 17:case 21:h.decorateNode({class:c[d]});break;case 18:h.getLogger().trace("SPACELIST");break;case 19:h.getLogger().trace("Node: ",c[d].id),h.addNode(0,c[d].id,c[d].descr,c[d].type);break;case 20:h.decorateNode({icon:c[d]});break;case 25:h.getLogger().trace("node found ..",c[d-2]),this.$={id:c[d-1],descr:c[d-1],type:h.getType(c[d-2],c[d])};break;case 26:this.$={id:c[d],descr:c[d],type:h.nodeType.DEFAULT};break;case 27:h.getLogger().trace("node found ..",c[d-3]),this.$={id:c[d-3],descr:c[d-1],type:h.getType(c[d-2],c[d])};break}},table:[{3:1,4:2,5:3,6:[1,5],8:a},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:a},{6:t,7:[1,10],9:9,12:11,13:n,14:14,15:r,16:i,17:17,18:18,19:g,22:u},e(f,[2,3]),{1:[2,2]},e(f,[2,4]),e(f,[2,5]),{1:[2,6],6:t,12:21,13:n,14:14,15:r,16:i,17:17,18:18,19:g,22:u},{6:t,9:22,12:11,13:n,14:14,15:r,16:i,17:17,18:18,19:g,22:u},{6:E,7:$,10:23,11:O},e(y,[2,22],{17:17,18:18,14:27,15:[1,28],16:[1,29],19:g,22:u}),e(y,[2,18]),e(y,[2,19]),e(y,[2,20]),e(y,[2,21]),e(y,[2,23]),e(y,[2,24]),e(y,[2,26],{19:[1,30]}),{20:[1,31]},{6:E,7:$,10:32,11:O},{1:[2,7],6:t,12:21,13:n,14:14,15:r,16:i,17:17,18:18,19:g,22:u},e(B,[2,14],{7:S,11:N}),e(T,[2,8]),e(T,[2,9]),e(T,[2,10]),e(y,[2,15]),e(y,[2,16]),e(y,[2,17]),{20:[1,35]},{21:[1,36]},e(B,[2,13],{7:S,11:N}),e(T,[2,11]),e(T,[2,12]),{21:[1,37]},e(y,[2,25]),e(y,[2,27])],defaultActions:{2:[2,1],6:[2,2]},parseError:function(o,s){if(s.recoverable)this.trace(o);else{var l=new Error(o);throw l.hash=s,l}},parse:function(o){var s=this,l=[0],h=[],p=[null],c=[],R=this.table,d="",P=0,J=0,rt=2,K=1,at=c.slice.call(arguments,1),_=Object.create(this.lexer),v={yy:{}};for(var z in this.yy)Object.prototype.hasOwnProperty.call(this.yy,z)&&(v.yy[z]=this.yy[z]);_.setInput(o,v.yy),v.yy.lexer=_,v.yy.parser=this,typeof _.yylloc>"u"&&(_.yylloc={});var G=_.yylloc;c.push(G);var ot=_.options&&_.options.ranges;typeof v.yy.parseError=="function"?this.parseError=v.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function ct(){var D;return D=h.pop()||_.lex()||K,typeof D!="number"&&(D instanceof Array&&(h=D,D=h.pop()),D=s.symbols_[D]||D),D}for(var b,I,k,X,A={},M,L,Q,V;;){if(I=l[l.length-1],this.defaultActions[I]?k=this.defaultActions[I]:((b===null||typeof b>"u")&&(b=ct()),k=R[I]&&R[I][b]),typeof k>"u"||!k.length||!k[0]){var W="";V=[];for(M in R[I])this.terminals_[M]&&M>rt&&V.push("'"+this.terminals_[M]+"'");_.showPosition?W="Parse error on line "+(P+1)+`:
|
|
2
2
|
`+_.showPosition()+`
|
|
3
3
|
Expecting `+V.join(", ")+", got '"+(this.terminals_[b]||b)+"'":W="Parse error on line "+(P+1)+": Unexpected "+(b==K?"end of input":"'"+(this.terminals_[b]||b)+"'"),this.parseError(W,{text:_.match,token:this.terminals_[b]||b,line:_.yylineno,loc:G,expected:V})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+I+", token: "+b);switch(k[0]){case 1:l.push(b),p.push(_.yytext),c.push(_.yylloc),l.push(k[1]),b=null,J=_.yyleng,d=_.yytext,P=_.yylineno,G=_.yylloc;break;case 2:if(L=this.productions_[k[1]][1],A.$=p[p.length-L],A._$={first_line:c[c.length-(L||1)].first_line,last_line:c[c.length-1].last_line,first_column:c[c.length-(L||1)].first_column,last_column:c[c.length-1].last_column},ot&&(A._$.range=[c[c.length-(L||1)].range[0],c[c.length-1].range[1]]),X=this.performAction.apply(A,[d,J,P,v.yy,k[1],p,c].concat(at)),typeof X<"u")return X;L&&(l=l.slice(0,-1*L*2),p=p.slice(0,-1*L),c=c.slice(0,-1*L)),l.push(this.productions_[k[1]][0]),p.push(A.$),c.push(A._$),Q=R[l[l.length-2]][l[l.length-1]],l.push(Q);break;case 3:return!0}}return!0}},st=(function(){var w={EOF:1,parseError:function(s,l){if(this.yy.parser)this.yy.parser.parseError(s,l);else throw new Error(s)},setInput:function(o,s){return this.yy=s||this.yy||{},this._input=o,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var o=this._input[0];this.yytext+=o,this.yyleng++,this.offset++,this.match+=o,this.matched+=o;var s=o.match(/(?:\r\n?|\n).*/g);return s?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),o},unput:function(o){var s=o.length,l=o.split(/(?:\r\n?|\n)/g);this._input=o+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-s),this.offset-=s;var h=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),l.length-1&&(this.yylineno-=l.length-1);var p=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:l?(l.length===h.length?this.yylloc.first_column:0)+h[h.length-l.length].length-l[0].length:this.yylloc.first_column-s},this.options.ranges&&(this.yylloc.range=[p[0],p[0]+this.yyleng-s]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},less:function(o){this.unput(this.match.slice(o))},pastInput:function(){var o=this.matched.substr(0,this.matched.length-this.match.length);return(o.length>20?"...":"")+o.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var o=this.match;return o.length<20&&(o+=this._input.substr(0,20-o.length)),(o.substr(0,20)+(o.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var o=this.pastInput(),s=new Array(o.length+1).join("-");return o+this.upcomingInput()+`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{mj as P,mk as Gs,bS as fe,bU as L,dJ as Ks,ml as Zs}from"../datalayer-app-main.js";const ls={rows:new Int32Array(0),cols:new Int32Array(0),values:[],formulas:[],styles:new Uint16Array(0)};function Ve(t,e){const n=[],o=[],s=[],r=[],i=[];for(const[l,a,c]of t.cells.entries(e))n.push(l),o.push(a),s.push(c.value),r.push(c.formula),i.push(c.style);return{rows:Int32Array.from(n),cols:Int32Array.from(o),values:s,formulas:r,styles:Uint16Array.from(i)}}function Ne(t){return{rows:Int32Array.from(t,e=>e[0]),cols:Int32Array.from(t,e=>e[1]),values:t.map(e=>e[2].value),formulas:t.map(e=>e[2].formula),styles:Uint16Array.from(t,e=>e[2].style)}}function gt(t){const e=[];for(let n=0;n<t.rows.length;n+=1){const o=t.formulas[n];e.push([t.rows[n],t.cols[n],o===void 0?{value:t.values[n],style:t.styles[n]}:{value:t.values[n],formula:o,style:t.styles[n]}])}return e}function lo(t){let e=64+t.rows.length*26;for(const n of t.values)typeof n=="string"&&(e+=n.length*2);for(const n of t.formulas)n!==void 0&&(e+=n.length*2);return e}function Xt(t){return 64+t.ids.byteLength+(t.sizes?.byteLength??0)+(t.hidden?.byteLength??0)}const qt=(t,e)=>e==="rows"?t.rows:t.cols,Nn=t=>({ids:Int32Array.from(t),sizes:null,hidden:null}),Js={op:"cells",apply(t,e){const n=t.sheet(e.sheet);for(const[o,s]of[...n.cells.entries(e.zone)])n.cells.set(o,s,null);for(const[o,s,r]of gt(e.after)){if(o<e.zone.top||o>e.zone.bottom||s<e.zone.left||s>e.zone.right)throw new Error(`A cells patch writes ${o},${s} outside its zone.`);n.cells.set(o,s,r)}},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"cells",sheet:"s1",zone:{top:0,left:0,bottom:1,right:1},before:ls,after:Ne([[1,1,{value:42,style:0}]])}),bytes:t=>lo(t.before)+lo(t.after)};function as(t,e,n,o){e==="rows"?t.cells.shiftRows(n,o,t.rows.count):t.cells.shiftCols(n,o,t.cols.count)}const qs={op:"axis-insert",apply(t,e){const n=t.sheet(e.sheet);qt(n,e.axis).insert(e.at,e.n,e.inserted),as(n,e.axis,e.at,e.n)},invert:t=>({op:"axis-delete",sheet:t.sheet,axis:t.axis,at:t.at,n:t.n,removed:t.inserted,tail:t.dropped}),example:t=>{const e=t.sheet("s1").rows.count;return{op:"axis-insert",sheet:"s1",axis:"rows",at:2,n:2,inserted:Nn([1<<30,(1<<30)+1]),dropped:Nn([e-2,e-1])}},bytes:t=>Xt(t.inserted)+(t.dropped?Xt(t.dropped):0)},Qs={op:"axis-delete",apply(t,e){const n=t.sheet(e.sheet);qt(n,e.axis).delete(e.at,e.n,e.tail),as(n,e.axis,e.at,-e.n)},invert:t=>({op:"axis-insert",sheet:t.sheet,axis:t.axis,at:t.at,n:t.n,inserted:t.removed,dropped:t.tail}),example:t=>({op:"axis-delete",sheet:"s1",axis:"rows",at:1,n:1,removed:Nn([1])}),bytes:t=>Xt(t.removed)+(t.tail?Xt(t.tail):0)},er={op:"axis-move",apply(t,e){qt(t.sheet(e.sheet),e.axis).move(e.at,e.n,e.to)},invert:t=>t.to<t.at?{...t,at:t.to,to:t.at+t.n}:{...t,at:t.to-t.n,to:t.at},example:()=>({op:"axis-move",sheet:"s1",axis:"cols",at:1,n:2,to:6})},tr={op:"axis-sizes",apply(t,e){qt(t.sheet(e.sheet),e.axis).setSegmentSizes(e.at,e.after.sizes,e.after.hidden,e.n)},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"axis-sizes",sheet:"s1",axis:"cols",at:3,n:2,before:{sizes:null,hidden:null},after:{sizes:Float64Array.of(40,50),hidden:Uint8Array.of(0,1)}})},nr={op:"merges",apply(t,e){t.sheet(e.sheet).merges=e.after.map(n=>({...n}))},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"merges",sheet:"s1",before:[],after:[{top:0,left:0,bottom:1,right:2}]})},or={op:"sheet-add",apply(t,e){if(t.hasSheet(e.sheet.id))throw new Error(`Sheet '${e.sheet.id}' is in the workbook already.`);if(e.index<0||e.index>t.sheets.length)throw new Error(`No sheet position ${e.index}.`);t.sheets.splice(e.index,0,e.sheet)},invert:t=>({op:"sheet-delete",index:t.index,sheet:t.sheet}),example:t=>({op:"sheet-add",index:1,sheet:t.createSheet("Example","example")})},sr={op:"sheet-delete",apply(t,e){if(t.sheets[e.index]!==e.sheet)throw new Error(`Sheet '${e.sheet.id}' is not at position ${e.index}.`);t.sheets.splice(e.index,1)},invert:t=>({op:"sheet-add",index:t.index,sheet:t.sheet}),example:t=>({op:"sheet-delete",index:0,sheet:t.sheet("s1")})},rr={op:"sheet-rename",apply(t,e){t.sheet(e.sheet).name=e.after},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"sheet-rename",sheet:"s1",before:"Sheet1",after:"Budget"})},ir={op:"sheet-move",apply(t,e){const[n]=t.sheets.splice(e.from,1);if(n===void 0)throw new Error(`No sheet at position ${e.from}.`);t.sheets.splice(e.to,0,n)},invert:t=>({...t,from:t.to,to:t.from}),example:()=>({op:"sheet-move",from:0,to:0})},lr={op:"frozen",apply(t,e){t.sheet(e.sheet).frozen={...e.after}},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"frozen",sheet:"s1",before:{rows:0,cols:0},after:{rows:1,cols:2}})},ar=[Js,qs,Qs,er,tr,nr,or,sr,rr,ir,lr],cs=["#DIV/0!","#REF!","#NAME?","#VALUE!","#N/A","#NUM!","#NULL!","#CYCLE!","#BUSY!","#SPILL!","#ERROR!"],Fn=new Set(cs);function ae(t,e){if(!Fn.has(t))throw new Error(`'${t}' is not a cell error; there are ${cs.join(" ")}.`);return e===void 0?{error:t}:{error:t,message:e}}function $(t){return typeof t=="object"&&t!==null&&Fn.has(t.error)}function dt(t){return Fn.has(t)}const Rn={decimal:".",group:",",months:["January","February","March","April","May","June","July","August","September","October","November","December"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]};class ve extends Error{}const ao={black:"#000000",blue:"#0000ff",cyan:"#00ffff",green:"#00ff00",magenta:"#ff00ff",red:"#ff0000",white:"#ffffff",yellow:"#ffff00"};function cr(t){const e=[];let n="";for(let o=0;o<t.length;o+=1){const s=t[o];if(s==='"'){const r=t.indexOf('"',o+1);if(r<0)throw new ve(`'${t}' opens a quote it never closes.`);n+=t.slice(o,r+1),o=r}else if(s==="["){const r=t.indexOf("]",o+1);if(r<0)throw new ve(`'${t}' opens a bracket it never closes.`);n+=t.slice(o,r+1),o=r}else if(s==="\\"||s==="_"||s==="*"){if(o+1>=t.length)throw new ve(`'${t}' ends with ${s} and nothing after it.`);n+=t.slice(o,o+2),o+=1}else s===";"?(e.push(n),n=""):n+=s}if(e.push(n),e.length>4)throw new ve(`'${t}' has ${e.length} sections; a format has at most four.`);return e}const ur=/[ymdhsYMDHS]/;function hr(t,e){const n=[],o={tokens:n,isDate:!1,isText:!1,hasAmPm:!1};let s=0;const r=a=>{const c=n[n.length-1];c?.t==="lit"?c.s+=a:n.push({t:"lit",s:a})};for(;s<t.length;){const a=t[s],c=t.slice(s);if(a==='"'){const u=t.indexOf('"',s+1);r(t.slice(s+1,u)),s=u+1}else if(a==="\\")r(t[s+1]),s+=2;else if(a==="_")r(" "),s+=2;else if(a==="*")s+=2;else if(a==="["){const u=t.indexOf("]",s),h=t.slice(s+1,u),d=h.toLowerCase();if(d in ao)o.color=ao[d];else if(/^color\d+$/.test(d))o.color=void 0;else if(/^(<=|>=|<>|<|>|=)-?\d+(\.\d+)?$/.test(h)){const f=/^(<=|>=|<>|<|>|=)(-?\d+(?:\.\d+)?)$/.exec(h);o.condition={op:f[1],value:Number(f[2])}}else if(/^h+$/i.test(h)||/^m+$/i.test(h)||/^s+$/i.test(h))n.push({t:"elapsed",unit:h[0].toLowerCase(),width:h.length}),o.isDate=!0;else if(h.startsWith("$"))r(h.slice(1).split("-")[0]);else throw new ve(`'${e}': [${h}] is not a colour, a condition or an elapsed time.`);s=u+1}else if(/^general/i.test(c))n.push({t:"general"}),s+=7;else if(/^(am\/pm|a\/p)/i.test(c)){const u=/^am\/pm/i.test(c)?t.slice(s,s+5):t.slice(s,s+3);n.push({t:"ampm",s:u}),o.hasAmPm=!0,o.isDate=!0,s+=u.length}else if(a==="0"||a==="#"||a==="?")n.push({t:"digit",c:a}),s+=1;else if(a==="."){const u=n[n.length-1];if(u?.t==="date"&&u.s.toLowerCase().startsWith("s")){let h=s+1;for(;t[h]==="0";)h+=1;n.push({t:"date",s:`.${"0".repeat(h-s-1)}`}),s=h}else n.push({t:"point"}),s+=1}else if(a===",")n.push({t:"comma"}),s+=1;else if(a==="%")n.push({t:"percent"}),s+=1;else if((a==="E"||a==="e")&&(t[s+1]==="+"||t[s+1]==="-"))n.push({t:"exp",sign:t[s+1]}),s+=2;else if(a==="@")n.push({t:"text"}),o.isText=!0,s+=1;else if(ur.test(a)){let u=s+1;for(;u<t.length&&t[u].toLowerCase()===a.toLowerCase();)u+=1;n.push({t:"date",s:t.slice(s,u).toLowerCase()}),o.isDate=!0,s=u}else{if(a==="/"&&n.some(u=>u.t==="digit")&&!o.isDate)throw new ve(`'${e}': fractions (# ?/?) are not supported yet.`);r(a),s+=1}}if(o.isDate)for(let a=0;a<n.length;a+=1){const c=n[a];c.t==="comma"?n[a]={t:"lit",s:","}:c.t==="point"?n[a]={t:"lit",s:"."}:c.t==="percent"&&(n[a]={t:"lit",s:"%"})}const i=n.filter(a=>a.t==="date"||a.t==="elapsed"),l=a=>a===void 0?"":a.t==="date"?a.s[0]:a.unit;return i.forEach((a,c)=>{a.t!=="date"||a.s[0]!=="m"||a.s.length>2||(l(i[c-1])==="h"||l(i[c+1])==="s")&&(a.s=a.s==="m"?"mi":"mmi")}),o}function Pn(t,e){if(t===0)return"0";const n=Math.abs(t);let o;if(n>=1e11||n<1e-9)o=t.toExponential(5).replace(/\.?0+e/,"e").replace("e+","E+").replace("e-","E-"),o=o.replace(/E([+-])(\d)$/,"E$10$2");else if(Number.isInteger(t))o=String(t);else{const s=String(Math.trunc(n)).length+(t<0?1:0),r=Math.max(0,Math.min(10,11-s-1));o=String(Number(t.toFixed(r)))}return o.replace(".",e.decimal)}function fr(t){const e=Math.floor(t),n=Math.round((t-e)*864e5),o=e<60?e+1:e,s=new Date(Date.UTC(1899,11,30)+o*864e5-(e<60?864e5:0));return{...e===60?{y:1900,m:2,d:29,dow:4}:{y:s.getUTCFullYear(),m:s.getUTCMonth()+1,d:s.getUTCDate(),dow:s.getUTCDay()},ms:n}}function ie(t,e){return String(t).padStart(e,"0")}function dr(t,e,n){const o=t.tokens.reduce((m,p)=>p.t==="date"&&p.s.startsWith(".")?Math.max(m,p.s.length-1):m,0),s=86400*10**o,r=t.tokens.some(m=>m.t==="elapsed"),i=o>0||r?Math.round(e*s)/s:Math.floor(e*s+1e-9)/s,l=fr(i),a=Math.round(i*864e5);let c=Math.floor(l.ms/36e5);const u=Math.floor(l.ms%36e5/6e4),h=Math.floor(l.ms%6e4/1e3),d=l.ms%1e3;let f="";for(const m of t.tokens)if(m.t==="lit")f+=m.s;else if(m.t==="ampm"){const p=c>=12;f+=m.s.length===5?p?"PM":"AM":p?"P":"A"}else if(m.t==="elapsed"){const p=m.unit==="h"?Math.floor(a/36e5):m.unit==="m"?Math.floor(a/6e4):Math.floor(a/1e3);f+=ie(p,m.width)}else if(m.t==="date"){const p=t.hasAmPm?(c+11)%12+1:c;switch(m.s){case"y":case"yy":f+=ie(l.y%100,2);break;case"yyy":case"yyyy":f+=String(l.y);break;case"m":f+=String(l.m);break;case"mm":f+=ie(l.m,2);break;case"mmm":f+=n.months[l.m-1].slice(0,3);break;case"mmmm":f+=n.months[l.m-1];break;case"mmmmm":f+=n.months[l.m-1][0];break;case"d":f+=String(l.d);break;case"dd":f+=ie(l.d,2);break;case"ddd":f+=n.days[l.dow].slice(0,3);break;case"dddd":f+=n.days[l.dow];break;case"h":f+=String(p);break;case"hh":f+=ie(p,2);break;case"mi":f+=String(u);break;case"mmi":f+=ie(u,2);break;case"s":f+=String(h);break;case"ss":f+=ie(h,2);break;default:m.s.startsWith(".")?f+=n.decimal+ie(Math.floor(d/10**(3-(m.s.length-1))),m.s.length-1):f+=m.s}}else m.t==="general"&&(f+=Pn(e,n));return c=0,f}function mr(t,e,n,o){const s=e.filter(l=>l==="0").length;let r=t==="0"&&s===0?"":t;r=r.padStart(s,"0");const i=Math.max(0,e.filter(l=>l==="?").length+s-r.length);return n&&(r=r.replace(/\B(?=(\d{3})+(?!\d))/g,o.group))," ".repeat(e.includes("?")?Math.max(0,i-s):0)+r}function pr(t,e,n){const o=t.tokens;if(o.some(k=>k.t==="general"))return o.map(k=>k.t==="lit"?k.s:k.t==="general"?Pn(e,n):"").join("");let s=e;const r=o.filter(k=>k.t==="percent").length;s*=100**r;let i=-1;o.forEach((k,z)=>{k.t==="digit"&&(i=z)});const l=o.findIndex(k=>k.t==="point"),a=l>=0?l:i+1,c=new Set;if(l>=0)for(let k=l-1;k>=0&&o[k].t==="comma";k-=1)c.add(k);for(let k=i+1;k<o.length&&o[k].t==="comma";k+=1)c.add(k);s/=1e3**c.size;const u=o.findIndex(k=>k.t==="exp"),h=u>=0?o.slice(0,u):o,d=[],f=[];let m=!1,p=!1;h.forEach((k,z)=>{k.t==="point"?m=!0:k.t==="digit"?(m?f:d).push(k.c):k.t==="comma"&&!m&&!c.has(z)&&z<a&&(p=!0)});let g=0;if(u>=0&&s!==0){const k=d.length>1&&d[0]==="#"?d.length:1;g=Math.floor(Math.log10(Math.abs(s))/k)*k,k===1&&(g=Math.floor(Math.log10(Math.abs(s)))-Math.max(0,d.filter(z=>z==="0").length-1)),s/=10**g}const y=Math.abs(s).toFixed(f.length);let[E,T=""]=y.split(".");if(u>=0&&y.startsWith("10")&&d.length<=1){g+=1;const k=(Math.abs(s)/10).toFixed(f.length).split(".");E=k[0],T=k[1]??""}let x="";for(let k=f.length-1,z=!1;k>=0;k-=1){const j=T[k];if(!z&&j==="0"&&f[k]!=="0"){x=(f[k]==="?"?" ":"")+x;continue}z=!0,x=j+x}const Q=mr(E,d,p,n);let K="",O=!1,de=!1,Qe=!1;for(let k=0;k<o.length;k+=1){const z=o[k];if(z.t==="lit")K+=z.s;else if(z.t==="percent")K+="%";else if(z.t==="text")K+="";else if(z.t==="digit"&&(u<0||k<u))k<(l>=0?l:1/0)&&!O?(K+=Q,O=!0):k>l&&l>=0&&!de&&(K+=x,de=!0);else if(z.t==="point")O||(K+=Q,O=!0),x.trim()===""&&f.every(j=>j==="#")||(K+=n.decimal);else if(z.t==="exp"&&!Qe){const j=o.slice(k+1).filter(rn=>rn.t==="digit").length,ke=g<0?"-":z.sign==="+"?"+":"";K+=`E${ke}${ie(Math.abs(g),Math.max(1,j))}`,Qe=!0}}return K}const co=new Map;function Bn(t,e=Rn){const n=e===Rn?t:`${t}\0${e.decimal}${e.group}`,o=co.get(n);if(o)return o;const s=cr(t).map(u=>hr(u,t)),r=s.find(u=>u.isText),i=s.filter(u=>u!==r||s.length===1),l=s.some(u=>u.condition!==void 0),a=u=>{if(l){for(const d of i){const f=d.condition;if(f===void 0)continue;if(f.op==="<"?u<f.value:f.op==="<="?u<=f.value:f.op===">"?u>f.value:f.op===">="?u>=f.value:f.op==="="?u===f.value:u!==f.value)return{section:d,signed:f.value>=0&&u<0}}return{section:i.find(d=>d.condition===void 0)??i[i.length-1],signed:u<0}}return i.length>=3&&u===0?{section:i[2],signed:!1}:i.length>=2&&u<0?{section:i[1],signed:!1}:{section:i[0],signed:u<0}},c=u=>{if(u===null)return{text:""};if($(u))return{text:u.error};if(typeof u=="boolean")return{text:u?"TRUE":"FALSE"};if(typeof u=="string"){const g=r??(s.length===1&&s[0].isText?s[0]:void 0);return g===void 0?{text:u}:{text:g.tokens.map(y=>y.t==="lit"?y.s:y.t==="text"?u:"").join(""),color:g.color}}const{section:h,signed:d}=a(u);if(h.isText)return{text:Pn(u,e)};const f=Math.abs(u),m=h.isDate?dr(h,f,e):pr(h,f,e),p=/^[^1-9]*$/.test(m);return{text:d&&!p?`-${m}`:m,color:h.color}};return co.set(n,c),c}function gr(t){Bn(t)}const jn=["font","size","bold","italic","underline","strike","color","fill","align","valign","wrap","borders","format","type"],wr=new Set(jn),uo=65535;function ho(t){const e={};for(const n of jn){const o=t[n];o===void 0||o===!1||(e[n]=n==="borders"?yr(o):o)}return JSON.stringify(e)}function yr(t){if(t===void 0)return;const e={};for(const n of["top","right","bottom","left"])t[n]&&(e[n]=t[n]);return e}function Hn(t,e="style"){if(typeof t!="object"||t===null||Array.isArray(t))throw new Error(`${e}: a style is an object.`);for(const o of Object.keys(t))if(!wr.has(o))throw new Error(`${e}: '${o}' is not a style property (${jn.join(", ")}).`);const n=t;for(const o of["bold","italic","underline","strike","wrap"])if(n[o]!==void 0&&typeof n[o]!="boolean")throw new Error(`${e}.${o}: true or false.`);for(const o of["font","color","fill","format"])if(n[o]!==void 0&&typeof n[o]!="string")throw new Error(`${e}.${o}: a string.`);if(n.type!==void 0&&!(typeof n.type=="string"&&n.type!==""))throw new Error(`${e}.type: the id of a cell type, a non-empty string.`);if(n.format!==void 0)try{gr(n.format)}catch(o){throw new Error(`${e}.format: ${o.message}`)}if(n.size!==void 0&&!(typeof n.size=="number"&&n.size>0))throw new Error(`${e}.size: a positive number.`);if(n.align!==void 0&&!["left","center","right"].includes(n.align))throw new Error(`${e}.align: left, center or right.`);if(n.valign!==void 0&&!["top","middle","bottom"].includes(n.valign))throw new Error(`${e}.valign: top, middle or bottom.`)}class br{#e=[{}];#t=new Map([[ho({}),0]]);intern(e){const n=ho(e);let o=this.#t.get(n);if(o===void 0){if(this.#e.length>uo)throw new Error(`A workbook holds at most ${uo+1} distinct styles.`);o=this.#e.length,this.#e.push(JSON.parse(n)),this.#t.set(n,o)}return o}get(e){const n=this.#e[e];if(n===void 0)throw new Error(`No style ${e}; the workbook has ${this.#e.length}.`);return n}get size(){return this.#e.length}all(){return this.#e}}function mt(t){if(!Number.isInteger(t)||t<0)throw new Error(`No column at index ${t}.`);let e="",n=t+1;for(;n>0;){const o=(n-1)%26;e=String.fromCharCode(65+o)+e,n=Math.floor((n-1)/26)}return e}function us(t){if(!/^[A-Za-z]{1,3}$/.test(t))throw new Error(`'${t}' is not a column (A to XFD).`);let e=0;for(const n of t.toUpperCase())e=e*26+(n.charCodeAt(0)-64);return e-1}function fo(t){return`${mt(t.col)}${t.row+1}`}const Er=/^\$?([A-Za-z]{1,3})\$?([1-9][0-9]{0,6})$/;function mo(t){const e=Er.exec(t.trim());if(!e)throw new Error(`'${t}' is not a cell reference such as B3.`);return{row:Number(e[2])-1,col:us(e[1])}}function Ar(t){const e=t.trim().split(":");if(e.length>2||e[0]==="")throw new Error(`'${t}' is not a range such as A1:C4.`);const n=mo(e[0]),o=e.length===2?mo(e[1]):n;return Qt(n,o)}function He(t){const e=fo({row:t.top,col:t.left});return t.top===t.bottom&&t.left===t.right?e:`${e}:${fo({row:t.bottom,col:t.right})}`}function Qt(t,e=t){return{top:Math.min(t.row,e.row),left:Math.min(t.col,e.col),bottom:Math.max(t.row,e.row),right:Math.max(t.col,e.col)}}function en(t,e){return e.row>=t.top&&e.row<=t.bottom&&e.col>=t.left&&e.col<=t.right}function Te(t,e){return t.left<=e.right&&e.left<=t.right&&t.top<=e.bottom&&e.top<=t.bottom}function kr(t){const e=t.lastIndexOf("!");if(e<0)return{ref:t};let n=t.slice(0,e);if(n.startsWith("'")){if(!n.endsWith("'")||n.length<2)throw new Error(`'${t}' has an unclosed sheet name.`);n=n.slice(1,-1).replace(/''/g,"'")}if(n==="")throw new Error(`'${t}' names an empty sheet.`);return{sheet:n,ref:t.slice(e+1)}}const hs={argumentSeparator:",",decimal:".",arrayColumn:","},$r=["#DIV/0!","#REF!","#NAME?","#VALUE!","#N/A","#NUM!","#NULL!","#CYCLE!","#BUSY!","#SPILL!","#ERROR!","#GETTING_DATA"],Sr=["<>","<=",">=","+","-","*","/","^","&","=","<",">","%",":"],xr=/\$?[A-Za-z]{1,3}\$?[0-9]{1,7}/y,vr=/\$?[A-Za-z]{1,3}(?=\s*:)/y,Mr=/[0-9]*(?:\.[0-9]*)?(?:[eE][+-]?[0-9]+)?/y,Tr=/[0-9]*(?:,[0-9]*)?(?:[eE][+-]?[0-9]+)?/y,Cr=/\$?[0-9]{1,7}(?=\s*:)/y,Nr=/\$?[0-9]{1,7}(?![0-9.eE%A-Za-z(])/y,Rr=/\$[0-9]{1,7}/y,Or=/[A-Za-z_\\][A-Za-z0-9_.\\]*/y,po=/\$?[A-Za-z]{1,3}(?![A-Za-z0-9_(])/y;function se(t,e,n){t.lastIndex=n;const o=t.exec(e);return o===null?-1:o[0].length}const ln=t=>t===" "||t===" "||t===`
|
|
1
|
+
import{mn as P,mo as Gs,bS as fe,bU as L,dJ as Ks,mp as Zs}from"../datalayer-app-main.js";const ls={rows:new Int32Array(0),cols:new Int32Array(0),values:[],formulas:[],styles:new Uint16Array(0)};function Ve(t,e){const n=[],o=[],s=[],r=[],i=[];for(const[l,a,c]of t.cells.entries(e))n.push(l),o.push(a),s.push(c.value),r.push(c.formula),i.push(c.style);return{rows:Int32Array.from(n),cols:Int32Array.from(o),values:s,formulas:r,styles:Uint16Array.from(i)}}function Ne(t){return{rows:Int32Array.from(t,e=>e[0]),cols:Int32Array.from(t,e=>e[1]),values:t.map(e=>e[2].value),formulas:t.map(e=>e[2].formula),styles:Uint16Array.from(t,e=>e[2].style)}}function gt(t){const e=[];for(let n=0;n<t.rows.length;n+=1){const o=t.formulas[n];e.push([t.rows[n],t.cols[n],o===void 0?{value:t.values[n],style:t.styles[n]}:{value:t.values[n],formula:o,style:t.styles[n]}])}return e}function lo(t){let e=64+t.rows.length*26;for(const n of t.values)typeof n=="string"&&(e+=n.length*2);for(const n of t.formulas)n!==void 0&&(e+=n.length*2);return e}function Xt(t){return 64+t.ids.byteLength+(t.sizes?.byteLength??0)+(t.hidden?.byteLength??0)}const qt=(t,e)=>e==="rows"?t.rows:t.cols,Nn=t=>({ids:Int32Array.from(t),sizes:null,hidden:null}),Js={op:"cells",apply(t,e){const n=t.sheet(e.sheet);for(const[o,s]of[...n.cells.entries(e.zone)])n.cells.set(o,s,null);for(const[o,s,r]of gt(e.after)){if(o<e.zone.top||o>e.zone.bottom||s<e.zone.left||s>e.zone.right)throw new Error(`A cells patch writes ${o},${s} outside its zone.`);n.cells.set(o,s,r)}},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"cells",sheet:"s1",zone:{top:0,left:0,bottom:1,right:1},before:ls,after:Ne([[1,1,{value:42,style:0}]])}),bytes:t=>lo(t.before)+lo(t.after)};function as(t,e,n,o){e==="rows"?t.cells.shiftRows(n,o,t.rows.count):t.cells.shiftCols(n,o,t.cols.count)}const qs={op:"axis-insert",apply(t,e){const n=t.sheet(e.sheet);qt(n,e.axis).insert(e.at,e.n,e.inserted),as(n,e.axis,e.at,e.n)},invert:t=>({op:"axis-delete",sheet:t.sheet,axis:t.axis,at:t.at,n:t.n,removed:t.inserted,tail:t.dropped}),example:t=>{const e=t.sheet("s1").rows.count;return{op:"axis-insert",sheet:"s1",axis:"rows",at:2,n:2,inserted:Nn([1<<30,(1<<30)+1]),dropped:Nn([e-2,e-1])}},bytes:t=>Xt(t.inserted)+(t.dropped?Xt(t.dropped):0)},Qs={op:"axis-delete",apply(t,e){const n=t.sheet(e.sheet);qt(n,e.axis).delete(e.at,e.n,e.tail),as(n,e.axis,e.at,-e.n)},invert:t=>({op:"axis-insert",sheet:t.sheet,axis:t.axis,at:t.at,n:t.n,inserted:t.removed,dropped:t.tail}),example:t=>({op:"axis-delete",sheet:"s1",axis:"rows",at:1,n:1,removed:Nn([1])}),bytes:t=>Xt(t.removed)+(t.tail?Xt(t.tail):0)},er={op:"axis-move",apply(t,e){qt(t.sheet(e.sheet),e.axis).move(e.at,e.n,e.to)},invert:t=>t.to<t.at?{...t,at:t.to,to:t.at+t.n}:{...t,at:t.to-t.n,to:t.at},example:()=>({op:"axis-move",sheet:"s1",axis:"cols",at:1,n:2,to:6})},tr={op:"axis-sizes",apply(t,e){qt(t.sheet(e.sheet),e.axis).setSegmentSizes(e.at,e.after.sizes,e.after.hidden,e.n)},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"axis-sizes",sheet:"s1",axis:"cols",at:3,n:2,before:{sizes:null,hidden:null},after:{sizes:Float64Array.of(40,50),hidden:Uint8Array.of(0,1)}})},nr={op:"merges",apply(t,e){t.sheet(e.sheet).merges=e.after.map(n=>({...n}))},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"merges",sheet:"s1",before:[],after:[{top:0,left:0,bottom:1,right:2}]})},or={op:"sheet-add",apply(t,e){if(t.hasSheet(e.sheet.id))throw new Error(`Sheet '${e.sheet.id}' is in the workbook already.`);if(e.index<0||e.index>t.sheets.length)throw new Error(`No sheet position ${e.index}.`);t.sheets.splice(e.index,0,e.sheet)},invert:t=>({op:"sheet-delete",index:t.index,sheet:t.sheet}),example:t=>({op:"sheet-add",index:1,sheet:t.createSheet("Example","example")})},sr={op:"sheet-delete",apply(t,e){if(t.sheets[e.index]!==e.sheet)throw new Error(`Sheet '${e.sheet.id}' is not at position ${e.index}.`);t.sheets.splice(e.index,1)},invert:t=>({op:"sheet-add",index:t.index,sheet:t.sheet}),example:t=>({op:"sheet-delete",index:0,sheet:t.sheet("s1")})},rr={op:"sheet-rename",apply(t,e){t.sheet(e.sheet).name=e.after},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"sheet-rename",sheet:"s1",before:"Sheet1",after:"Budget"})},ir={op:"sheet-move",apply(t,e){const[n]=t.sheets.splice(e.from,1);if(n===void 0)throw new Error(`No sheet at position ${e.from}.`);t.sheets.splice(e.to,0,n)},invert:t=>({...t,from:t.to,to:t.from}),example:()=>({op:"sheet-move",from:0,to:0})},lr={op:"frozen",apply(t,e){t.sheet(e.sheet).frozen={...e.after}},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"frozen",sheet:"s1",before:{rows:0,cols:0},after:{rows:1,cols:2}})},ar=[Js,qs,Qs,er,tr,nr,or,sr,rr,ir,lr],cs=["#DIV/0!","#REF!","#NAME?","#VALUE!","#N/A","#NUM!","#NULL!","#CYCLE!","#BUSY!","#SPILL!","#ERROR!"],Fn=new Set(cs);function ae(t,e){if(!Fn.has(t))throw new Error(`'${t}' is not a cell error; there are ${cs.join(" ")}.`);return e===void 0?{error:t}:{error:t,message:e}}function $(t){return typeof t=="object"&&t!==null&&Fn.has(t.error)}function dt(t){return Fn.has(t)}const Rn={decimal:".",group:",",months:["January","February","March","April","May","June","July","August","September","October","November","December"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]};class ve extends Error{}const ao={black:"#000000",blue:"#0000ff",cyan:"#00ffff",green:"#00ff00",magenta:"#ff00ff",red:"#ff0000",white:"#ffffff",yellow:"#ffff00"};function cr(t){const e=[];let n="";for(let o=0;o<t.length;o+=1){const s=t[o];if(s==='"'){const r=t.indexOf('"',o+1);if(r<0)throw new ve(`'${t}' opens a quote it never closes.`);n+=t.slice(o,r+1),o=r}else if(s==="["){const r=t.indexOf("]",o+1);if(r<0)throw new ve(`'${t}' opens a bracket it never closes.`);n+=t.slice(o,r+1),o=r}else if(s==="\\"||s==="_"||s==="*"){if(o+1>=t.length)throw new ve(`'${t}' ends with ${s} and nothing after it.`);n+=t.slice(o,o+2),o+=1}else s===";"?(e.push(n),n=""):n+=s}if(e.push(n),e.length>4)throw new ve(`'${t}' has ${e.length} sections; a format has at most four.`);return e}const ur=/[ymdhsYMDHS]/;function hr(t,e){const n=[],o={tokens:n,isDate:!1,isText:!1,hasAmPm:!1};let s=0;const r=a=>{const c=n[n.length-1];c?.t==="lit"?c.s+=a:n.push({t:"lit",s:a})};for(;s<t.length;){const a=t[s],c=t.slice(s);if(a==='"'){const u=t.indexOf('"',s+1);r(t.slice(s+1,u)),s=u+1}else if(a==="\\")r(t[s+1]),s+=2;else if(a==="_")r(" "),s+=2;else if(a==="*")s+=2;else if(a==="["){const u=t.indexOf("]",s),h=t.slice(s+1,u),d=h.toLowerCase();if(d in ao)o.color=ao[d];else if(/^color\d+$/.test(d))o.color=void 0;else if(/^(<=|>=|<>|<|>|=)-?\d+(\.\d+)?$/.test(h)){const f=/^(<=|>=|<>|<|>|=)(-?\d+(?:\.\d+)?)$/.exec(h);o.condition={op:f[1],value:Number(f[2])}}else if(/^h+$/i.test(h)||/^m+$/i.test(h)||/^s+$/i.test(h))n.push({t:"elapsed",unit:h[0].toLowerCase(),width:h.length}),o.isDate=!0;else if(h.startsWith("$"))r(h.slice(1).split("-")[0]);else throw new ve(`'${e}': [${h}] is not a colour, a condition or an elapsed time.`);s=u+1}else if(/^general/i.test(c))n.push({t:"general"}),s+=7;else if(/^(am\/pm|a\/p)/i.test(c)){const u=/^am\/pm/i.test(c)?t.slice(s,s+5):t.slice(s,s+3);n.push({t:"ampm",s:u}),o.hasAmPm=!0,o.isDate=!0,s+=u.length}else if(a==="0"||a==="#"||a==="?")n.push({t:"digit",c:a}),s+=1;else if(a==="."){const u=n[n.length-1];if(u?.t==="date"&&u.s.toLowerCase().startsWith("s")){let h=s+1;for(;t[h]==="0";)h+=1;n.push({t:"date",s:`.${"0".repeat(h-s-1)}`}),s=h}else n.push({t:"point"}),s+=1}else if(a===",")n.push({t:"comma"}),s+=1;else if(a==="%")n.push({t:"percent"}),s+=1;else if((a==="E"||a==="e")&&(t[s+1]==="+"||t[s+1]==="-"))n.push({t:"exp",sign:t[s+1]}),s+=2;else if(a==="@")n.push({t:"text"}),o.isText=!0,s+=1;else if(ur.test(a)){let u=s+1;for(;u<t.length&&t[u].toLowerCase()===a.toLowerCase();)u+=1;n.push({t:"date",s:t.slice(s,u).toLowerCase()}),o.isDate=!0,s=u}else{if(a==="/"&&n.some(u=>u.t==="digit")&&!o.isDate)throw new ve(`'${e}': fractions (# ?/?) are not supported yet.`);r(a),s+=1}}if(o.isDate)for(let a=0;a<n.length;a+=1){const c=n[a];c.t==="comma"?n[a]={t:"lit",s:","}:c.t==="point"?n[a]={t:"lit",s:"."}:c.t==="percent"&&(n[a]={t:"lit",s:"%"})}const i=n.filter(a=>a.t==="date"||a.t==="elapsed"),l=a=>a===void 0?"":a.t==="date"?a.s[0]:a.unit;return i.forEach((a,c)=>{a.t!=="date"||a.s[0]!=="m"||a.s.length>2||(l(i[c-1])==="h"||l(i[c+1])==="s")&&(a.s=a.s==="m"?"mi":"mmi")}),o}function Pn(t,e){if(t===0)return"0";const n=Math.abs(t);let o;if(n>=1e11||n<1e-9)o=t.toExponential(5).replace(/\.?0+e/,"e").replace("e+","E+").replace("e-","E-"),o=o.replace(/E([+-])(\d)$/,"E$10$2");else if(Number.isInteger(t))o=String(t);else{const s=String(Math.trunc(n)).length+(t<0?1:0),r=Math.max(0,Math.min(10,11-s-1));o=String(Number(t.toFixed(r)))}return o.replace(".",e.decimal)}function fr(t){const e=Math.floor(t),n=Math.round((t-e)*864e5),o=e<60?e+1:e,s=new Date(Date.UTC(1899,11,30)+o*864e5-(e<60?864e5:0));return{...e===60?{y:1900,m:2,d:29,dow:4}:{y:s.getUTCFullYear(),m:s.getUTCMonth()+1,d:s.getUTCDate(),dow:s.getUTCDay()},ms:n}}function ie(t,e){return String(t).padStart(e,"0")}function dr(t,e,n){const o=t.tokens.reduce((m,p)=>p.t==="date"&&p.s.startsWith(".")?Math.max(m,p.s.length-1):m,0),s=86400*10**o,r=t.tokens.some(m=>m.t==="elapsed"),i=o>0||r?Math.round(e*s)/s:Math.floor(e*s+1e-9)/s,l=fr(i),a=Math.round(i*864e5);let c=Math.floor(l.ms/36e5);const u=Math.floor(l.ms%36e5/6e4),h=Math.floor(l.ms%6e4/1e3),d=l.ms%1e3;let f="";for(const m of t.tokens)if(m.t==="lit")f+=m.s;else if(m.t==="ampm"){const p=c>=12;f+=m.s.length===5?p?"PM":"AM":p?"P":"A"}else if(m.t==="elapsed"){const p=m.unit==="h"?Math.floor(a/36e5):m.unit==="m"?Math.floor(a/6e4):Math.floor(a/1e3);f+=ie(p,m.width)}else if(m.t==="date"){const p=t.hasAmPm?(c+11)%12+1:c;switch(m.s){case"y":case"yy":f+=ie(l.y%100,2);break;case"yyy":case"yyyy":f+=String(l.y);break;case"m":f+=String(l.m);break;case"mm":f+=ie(l.m,2);break;case"mmm":f+=n.months[l.m-1].slice(0,3);break;case"mmmm":f+=n.months[l.m-1];break;case"mmmmm":f+=n.months[l.m-1][0];break;case"d":f+=String(l.d);break;case"dd":f+=ie(l.d,2);break;case"ddd":f+=n.days[l.dow].slice(0,3);break;case"dddd":f+=n.days[l.dow];break;case"h":f+=String(p);break;case"hh":f+=ie(p,2);break;case"mi":f+=String(u);break;case"mmi":f+=ie(u,2);break;case"s":f+=String(h);break;case"ss":f+=ie(h,2);break;default:m.s.startsWith(".")?f+=n.decimal+ie(Math.floor(d/10**(3-(m.s.length-1))),m.s.length-1):f+=m.s}}else m.t==="general"&&(f+=Pn(e,n));return c=0,f}function mr(t,e,n,o){const s=e.filter(l=>l==="0").length;let r=t==="0"&&s===0?"":t;r=r.padStart(s,"0");const i=Math.max(0,e.filter(l=>l==="?").length+s-r.length);return n&&(r=r.replace(/\B(?=(\d{3})+(?!\d))/g,o.group))," ".repeat(e.includes("?")?Math.max(0,i-s):0)+r}function pr(t,e,n){const o=t.tokens;if(o.some(k=>k.t==="general"))return o.map(k=>k.t==="lit"?k.s:k.t==="general"?Pn(e,n):"").join("");let s=e;const r=o.filter(k=>k.t==="percent").length;s*=100**r;let i=-1;o.forEach((k,z)=>{k.t==="digit"&&(i=z)});const l=o.findIndex(k=>k.t==="point"),a=l>=0?l:i+1,c=new Set;if(l>=0)for(let k=l-1;k>=0&&o[k].t==="comma";k-=1)c.add(k);for(let k=i+1;k<o.length&&o[k].t==="comma";k+=1)c.add(k);s/=1e3**c.size;const u=o.findIndex(k=>k.t==="exp"),h=u>=0?o.slice(0,u):o,d=[],f=[];let m=!1,p=!1;h.forEach((k,z)=>{k.t==="point"?m=!0:k.t==="digit"?(m?f:d).push(k.c):k.t==="comma"&&!m&&!c.has(z)&&z<a&&(p=!0)});let g=0;if(u>=0&&s!==0){const k=d.length>1&&d[0]==="#"?d.length:1;g=Math.floor(Math.log10(Math.abs(s))/k)*k,k===1&&(g=Math.floor(Math.log10(Math.abs(s)))-Math.max(0,d.filter(z=>z==="0").length-1)),s/=10**g}const y=Math.abs(s).toFixed(f.length);let[E,T=""]=y.split(".");if(u>=0&&y.startsWith("10")&&d.length<=1){g+=1;const k=(Math.abs(s)/10).toFixed(f.length).split(".");E=k[0],T=k[1]??""}let x="";for(let k=f.length-1,z=!1;k>=0;k-=1){const j=T[k];if(!z&&j==="0"&&f[k]!=="0"){x=(f[k]==="?"?" ":"")+x;continue}z=!0,x=j+x}const Q=mr(E,d,p,n);let K="",O=!1,de=!1,Qe=!1;for(let k=0;k<o.length;k+=1){const z=o[k];if(z.t==="lit")K+=z.s;else if(z.t==="percent")K+="%";else if(z.t==="text")K+="";else if(z.t==="digit"&&(u<0||k<u))k<(l>=0?l:1/0)&&!O?(K+=Q,O=!0):k>l&&l>=0&&!de&&(K+=x,de=!0);else if(z.t==="point")O||(K+=Q,O=!0),x.trim()===""&&f.every(j=>j==="#")||(K+=n.decimal);else if(z.t==="exp"&&!Qe){const j=o.slice(k+1).filter(rn=>rn.t==="digit").length,ke=g<0?"-":z.sign==="+"?"+":"";K+=`E${ke}${ie(Math.abs(g),Math.max(1,j))}`,Qe=!0}}return K}const co=new Map;function Bn(t,e=Rn){const n=e===Rn?t:`${t}\0${e.decimal}${e.group}`,o=co.get(n);if(o)return o;const s=cr(t).map(u=>hr(u,t)),r=s.find(u=>u.isText),i=s.filter(u=>u!==r||s.length===1),l=s.some(u=>u.condition!==void 0),a=u=>{if(l){for(const d of i){const f=d.condition;if(f===void 0)continue;if(f.op==="<"?u<f.value:f.op==="<="?u<=f.value:f.op===">"?u>f.value:f.op===">="?u>=f.value:f.op==="="?u===f.value:u!==f.value)return{section:d,signed:f.value>=0&&u<0}}return{section:i.find(d=>d.condition===void 0)??i[i.length-1],signed:u<0}}return i.length>=3&&u===0?{section:i[2],signed:!1}:i.length>=2&&u<0?{section:i[1],signed:!1}:{section:i[0],signed:u<0}},c=u=>{if(u===null)return{text:""};if($(u))return{text:u.error};if(typeof u=="boolean")return{text:u?"TRUE":"FALSE"};if(typeof u=="string"){const g=r??(s.length===1&&s[0].isText?s[0]:void 0);return g===void 0?{text:u}:{text:g.tokens.map(y=>y.t==="lit"?y.s:y.t==="text"?u:"").join(""),color:g.color}}const{section:h,signed:d}=a(u);if(h.isText)return{text:Pn(u,e)};const f=Math.abs(u),m=h.isDate?dr(h,f,e):pr(h,f,e),p=/^[^1-9]*$/.test(m);return{text:d&&!p?`-${m}`:m,color:h.color}};return co.set(n,c),c}function gr(t){Bn(t)}const jn=["font","size","bold","italic","underline","strike","color","fill","align","valign","wrap","borders","format","type"],wr=new Set(jn),uo=65535;function ho(t){const e={};for(const n of jn){const o=t[n];o===void 0||o===!1||(e[n]=n==="borders"?yr(o):o)}return JSON.stringify(e)}function yr(t){if(t===void 0)return;const e={};for(const n of["top","right","bottom","left"])t[n]&&(e[n]=t[n]);return e}function Hn(t,e="style"){if(typeof t!="object"||t===null||Array.isArray(t))throw new Error(`${e}: a style is an object.`);for(const o of Object.keys(t))if(!wr.has(o))throw new Error(`${e}: '${o}' is not a style property (${jn.join(", ")}).`);const n=t;for(const o of["bold","italic","underline","strike","wrap"])if(n[o]!==void 0&&typeof n[o]!="boolean")throw new Error(`${e}.${o}: true or false.`);for(const o of["font","color","fill","format"])if(n[o]!==void 0&&typeof n[o]!="string")throw new Error(`${e}.${o}: a string.`);if(n.type!==void 0&&!(typeof n.type=="string"&&n.type!==""))throw new Error(`${e}.type: the id of a cell type, a non-empty string.`);if(n.format!==void 0)try{gr(n.format)}catch(o){throw new Error(`${e}.format: ${o.message}`)}if(n.size!==void 0&&!(typeof n.size=="number"&&n.size>0))throw new Error(`${e}.size: a positive number.`);if(n.align!==void 0&&!["left","center","right"].includes(n.align))throw new Error(`${e}.align: left, center or right.`);if(n.valign!==void 0&&!["top","middle","bottom"].includes(n.valign))throw new Error(`${e}.valign: top, middle or bottom.`)}class br{#e=[{}];#t=new Map([[ho({}),0]]);intern(e){const n=ho(e);let o=this.#t.get(n);if(o===void 0){if(this.#e.length>uo)throw new Error(`A workbook holds at most ${uo+1} distinct styles.`);o=this.#e.length,this.#e.push(JSON.parse(n)),this.#t.set(n,o)}return o}get(e){const n=this.#e[e];if(n===void 0)throw new Error(`No style ${e}; the workbook has ${this.#e.length}.`);return n}get size(){return this.#e.length}all(){return this.#e}}function mt(t){if(!Number.isInteger(t)||t<0)throw new Error(`No column at index ${t}.`);let e="",n=t+1;for(;n>0;){const o=(n-1)%26;e=String.fromCharCode(65+o)+e,n=Math.floor((n-1)/26)}return e}function us(t){if(!/^[A-Za-z]{1,3}$/.test(t))throw new Error(`'${t}' is not a column (A to XFD).`);let e=0;for(const n of t.toUpperCase())e=e*26+(n.charCodeAt(0)-64);return e-1}function fo(t){return`${mt(t.col)}${t.row+1}`}const Er=/^\$?([A-Za-z]{1,3})\$?([1-9][0-9]{0,6})$/;function mo(t){const e=Er.exec(t.trim());if(!e)throw new Error(`'${t}' is not a cell reference such as B3.`);return{row:Number(e[2])-1,col:us(e[1])}}function Ar(t){const e=t.trim().split(":");if(e.length>2||e[0]==="")throw new Error(`'${t}' is not a range such as A1:C4.`);const n=mo(e[0]),o=e.length===2?mo(e[1]):n;return Qt(n,o)}function He(t){const e=fo({row:t.top,col:t.left});return t.top===t.bottom&&t.left===t.right?e:`${e}:${fo({row:t.bottom,col:t.right})}`}function Qt(t,e=t){return{top:Math.min(t.row,e.row),left:Math.min(t.col,e.col),bottom:Math.max(t.row,e.row),right:Math.max(t.col,e.col)}}function en(t,e){return e.row>=t.top&&e.row<=t.bottom&&e.col>=t.left&&e.col<=t.right}function Te(t,e){return t.left<=e.right&&e.left<=t.right&&t.top<=e.bottom&&e.top<=t.bottom}function kr(t){const e=t.lastIndexOf("!");if(e<0)return{ref:t};let n=t.slice(0,e);if(n.startsWith("'")){if(!n.endsWith("'")||n.length<2)throw new Error(`'${t}' has an unclosed sheet name.`);n=n.slice(1,-1).replace(/''/g,"'")}if(n==="")throw new Error(`'${t}' names an empty sheet.`);return{sheet:n,ref:t.slice(e+1)}}const hs={argumentSeparator:",",decimal:".",arrayColumn:","},$r=["#DIV/0!","#REF!","#NAME?","#VALUE!","#N/A","#NUM!","#NULL!","#CYCLE!","#BUSY!","#SPILL!","#ERROR!","#GETTING_DATA"],Sr=["<>","<=",">=","+","-","*","/","^","&","=","<",">","%",":"],xr=/\$?[A-Za-z]{1,3}\$?[0-9]{1,7}/y,vr=/\$?[A-Za-z]{1,3}(?=\s*:)/y,Mr=/[0-9]*(?:\.[0-9]*)?(?:[eE][+-]?[0-9]+)?/y,Tr=/[0-9]*(?:,[0-9]*)?(?:[eE][+-]?[0-9]+)?/y,Cr=/\$?[0-9]{1,7}(?=\s*:)/y,Nr=/\$?[0-9]{1,7}(?![0-9.eE%A-Za-z(])/y,Rr=/\$[0-9]{1,7}/y,Or=/[A-Za-z_\\][A-Za-z0-9_.\\]*/y,po=/\$?[A-Za-z]{1,3}(?![A-Za-z0-9_(])/y;function se(t,e,n){t.lastIndex=n;const o=t.exec(e);return o===null?-1:o[0].length}const ln=t=>t===" "||t===" "||t===`
|
|
2
2
|
`||t==="\r"||t!==void 0&&/\s/.test(t),an=t=>t!==void 0&&t>="0"&&t<="9",Ir=t=>t>="A"&&t<="Z"||t>="a"&&t<="z"||t==="_"||t==="\\";function _r(t,e=hs){const n=[];let o=0;const s=(i,l)=>{n.push({kind:i,text:t.slice(o,l),start:o,end:l}),o=l},r=()=>{for(let i=n.length-1;i>=0;i-=1)if(n[i].kind!=="whitespace")return n[i].kind==="operator"&&n[i].text===":";return!1};for(;o<t.length;){const i=t[o];if(ln(i)){let l=o+1;for(;l<t.length&&ln(t[l]);)l+=1;s("whitespace",l)}else if(i==='"'){let l=o+1;for(;!(l>=t.length);)if(t[l]==='"')if(t[l+1]==='"')l+=2;else{l+=1;break}else l+=1;s("string",l)}else if(i==="'"){let l=o+1;for(;!(l>=t.length);)if(t[l]==="'")if(t[l+1]==="'")l+=2;else{l+=1;break}else l+=1;t[l]==="!"?s("sheet",l+1):s("unknown",l)}else if(i==="#"){const l=$r.find(a=>t.slice(o,o+a.length).toUpperCase()===a);l?s("error",o+l.length):s("unknown",o+1)}else if(i==="(")s("lparen",o+1);else if(i===")")s("rparen",o+1);else if(i==="{")s("lbrace",o+1);else if(i==="}")s("rbrace",o+1);else if(i===e.argumentSeparator)s("separator",o+1);else if(i===";"||e.arrayColumn!==e.argumentSeparator&&i===e.arrayColumn)s("arraySeparator",o+1);else if(an(i)||i===e.decimal&&an(t[o+1])){const l=se(Cr,t,o);if(l>=0){s("ref",o+l);continue}if(r()){const a=se(Nr,t,o);if(a>=0){s("ref",o+a);continue}}s("number",o+se(e.decimal==="."?Mr:Tr,t,o))}else if(i==="$"||Ir(i)){const l=se(xr,t,o),a=Math.max(0,se(Or,t,o)),c=se(vr,t,o);if(a>0&&t[o+a]==="!")s("sheet",o+a+1);else if(l>=0&&l>=a&&t[o+l]!=="(")s("ref",o+l);else if(i==="$"&&an(t[o+1]))s("ref",o+se(Rr,t,o));else if(c>=0&&(a===0||c>=a))s("ref",o+c);else if(r()&&se(po,t,o)>=0)s("ref",o+se(po,t,o));else if(a>0){const u=t.slice(o,o+a).toUpperCase();let h=o+a;for(;ln(t[h]);)h+=1;t[h]==="("?s("function",o+a):s(u==="TRUE"||u==="FALSE"?"bool":"name",o+a)}else s("unknown",o+1)}else{const l=Sr.find(a=>t.startsWith(a,o));l?s("operator",o+l.length):s("unknown",o+1)}}return n}class I extends Error{start;end;constructor(e,n,o){super(e),this.start=n,this.end=o}}const zr={"=":10,"<>":10,"<":10,"<=":10,">":10,">=":10,"&":20,"+":30,"-":30,"*":40,"/":40,"^":50},Lr=60,Ur=70,go=80,wo=90,yo=1048576,Dr=16384;function bo(t,e,n){const o=/^(\$?)([A-Za-z]{1,3})?(\$?)([0-9]{1,7})?$/.exec(t);if(!o||o[2]===void 0&&o[4]===void 0)throw new I(`'${t}' is not a reference.`,e,n);const s={rowAbs:!1,colAbs:!1};if(o[2]!==void 0){if(s.col=us(o[2]),s.colAbs=o[1]==="$",s.col>=Dr)throw new I(`'${t}' is past the last column, XFD.`,e,n);o[4]!==void 0&&(s.rowAbs=o[3]==="$",s.row=Number(o[4])-1)}else s.rowAbs=o[1]==="$"||o[3]==="$",s.row=Number(o[4])-1;if(s.row!==void 0&&(s.row<0||s.row>=yo))throw new I(`'${t}' is outside rows 1 to ${yo}.`,e,n);return s}function Fr(t){const e=t.slice(0,-1);return e.startsWith("'")?e.slice(1,-1).replace(/''/g,"'"):e}class Pr{#e;#t;#s;#o=0;constructor(e,n,o){this.#t=e,this.#e=n,this.#s=o}parse(){if(this.#n(),this.#o>=this.#e.length)throw new I("The formula is empty.",0,this.#t.length);const e=this.#l(0);this.#n();const n=this.#e[this.#o];if(n!==void 0)throw new I(n.kind==="rparen"?"A closing parenthesis has no opening one.":`Unexpected '${n.text}'.`,n.start,n.end);return e}#r(){return this.#n(),this.#e[this.#o]}#i(){let e=this.#o;for(;this.#e[e]?.kind==="whitespace";)e+=1;return{token:this.#e[e],at:e}}#n(){for(;this.#e[this.#o]?.kind==="whitespace";)this.#o+=1}#f(){if(this.#e[this.#o]?.kind!=="whitespace")return!1;const n=this.#e[this.#o+1];return n!==void 0&&(n.kind==="ref"||n.kind==="sheet"||n.kind==="name"||n.kind==="lparen"||n.kind==="function")}#l(e){let n=this.#u();for(;;){if(this.#f()&&go>e&&this.#m(n)){this.#o+=1;const l=this.#l(go);n={type:"binary",op:" ",left:n,right:l};continue}const{token:o,at:s}=this.#i();if(o===void 0||o.kind!=="operator")break;if(o.text==="%"){if(Ur<=e)break;this.#o=s+1,n={type:"percent",arg:n};continue}if(o.text===":"){if(wo<=e)break;this.#o=s+1;const l=this.#l(wo);n=this.#g(n,l,o);continue}const r=zr[o.text];if(r===void 0||r<=e)break;this.#o=s+1;const i=this.#l(r);n={type:"binary",op:o.text,left:n,right:i}}return n}#m(e){return e.type==="cell"||e.type==="range"||e.type==="name"||e.type==="union"||e.type==="binary"&&e.op===" "||e.type==="call"}#g(e,n,o){const s=l=>l.type==="cell"?{sheet:l.sheet,part:l.ref}:void 0,r=s(e),i=s(n);if(r&&i){if(i.sheet!==void 0&&i.sheet!==r.sheet)throw new I("A range lies on one sheet.",o.start,o.end);const l=a=>a.row===void 0?"cols":a.col===void 0?"rows":"cells";if(l(r.part)!==l(i.part))throw new I("Both ends of a range are cells, columns or rows alike.",o.start,o.end);return{type:"range",sheet:r.sheet,from:r.part,to:i.part}}if(this.#m(e)&&this.#m(n))return{type:"call",name:":",args:[e,n]};throw new I("':' joins two references.",o.start,o.end)}#u(){const e=this.#r();if(e===void 0)throw new I("The formula ends where a value was expected.",this.#t.length,this.#t.length);switch(this.#o+=1,e.kind){case"number":{const n=Number(e.text.replace(this.#s.decimal,"."));if(!Number.isFinite(n))throw new I(`'${e.text}' is not a number.`,e.start,e.end);return{type:"number",value:n}}case"string":if(!/^"(?:[^"]|"")*"$/.test(e.text))throw new I("A text opens a quote it never closes.",e.start,this.#t.length);return{type:"string",value:e.text.slice(1,-1).replace(/""/g,'"')};case"bool":return{type:"bool",value:e.text.toUpperCase()==="TRUE"};case"error":{const n=e.text.toUpperCase();if(!dt(n))throw new I(`'${e.text}' is not an error value.`,e.start,e.end);return{type:"error",code:n}}case"sheet":{const n=this.#e[this.#o];if(n?.kind!=="ref")throw new I(`A reference follows ${e.text}.`,e.start,e.end);return this.#o+=1,{type:"cell",sheet:Fr(e.text),ref:bo(n.text,n.start,n.end)}}case"ref":return{type:"cell",ref:bo(e.text,e.start,e.end)};case"name":return{type:"name",name:e.text};case"function":return this.#a(e);case"operator":if(e.text==="-"||e.text==="+"){const n=this.#l(Lr);return{type:"unary",op:e.text,arg:n}}throw new I(`'${e.text}' needs a value before it.`,e.start,e.end);case"lparen":{const n=this.#l(0),o=[n];for(;this.#r()?.kind==="separator";)this.#o+=1,o.push(this.#l(0));const s=this.#r();if(s?.kind!=="rparen")throw new I("A parenthesis is never closed.",e.start,s?.start??this.#t.length);if(this.#o+=1,o.length===1)return n;if(!o.every(r=>this.#m(r)))throw new I("A union joins references only.",e.start,s.end);return{type:"union",items:o}}case"lbrace":return this.#c(e);case"rparen":throw new I("A closing parenthesis has no opening one.",e.start,e.end);default:throw new I(`Unexpected '${e.text}'.`,e.start,e.end)}}#a(e){if(this.#r()?.kind!=="lparen")throw new I(`${e.text} is called with ( ).`,e.start,e.end);this.#o+=1;const o=[],s=()=>{const i=this.#r();return i?.kind==="rparen"||i?.kind==="separator"};if(this.#r()?.kind!=="rparen")for(;;){if(o.push(s()?{type:"empty"}:this.#l(0)),this.#r()?.kind==="separator"){this.#o+=1,this.#r()?.kind==="rparen"&&o.push({type:"empty"});continue}break}const r=this.#r();if(r?.kind!=="rparen")throw new I(`${e.text}( is never closed.`,e.start,r?.start??this.#t.length);return this.#o+=1,{type:"call",name:e.text.toUpperCase(),args:o}}#c(e){const n=[[]];for(;;){const s=this.#r();if(s===void 0)throw new I("An array is never closed.",e.start,this.#t.length);if(s.kind==="rbrace"){this.#o+=1;break}if(s.kind==="separator"&&this.#s.argumentSeparator!==";"||s.kind==="arraySeparator"&&s.text===this.#s.arrayColumn){this.#o+=1;continue}if(s.kind==="arraySeparator"||s.kind==="separator"){this.#o+=1,n.push([]);continue}const r=this.#u();if(!(r.type==="number"||r.type==="string"||r.type==="bool"||r.type==="error"||r.type==="unary"&&r.arg.type==="number"))throw new I("An array holds constants only.",s.start,s.end);n[n.length-1].push(r)}const o=n[0].length;if(o===0||n.some(s=>s.length!==o))throw new I("Every row of an array has the same number of values.",e.start,e.end);return{type:"array",rows:n}}}function Re(t,e=hs){const n=_r(t,e),o=n.find(s=>s.kind==="unknown");if(o)throw new I(`'${o.text}' is not part of a formula.`,o.start,o.end);return{ast:new Pr(t,n,e).parse(),tokens:n}}function Ye(t,e){return{rowAbs:t.rowAbs,colAbs:t.colAbs,...t.row!==void 0?{row:t.rowAbs?t.row:t.row-e.row}:{},...t.col!==void 0?{col:t.colAbs?t.col:t.col-e.col}:{}}}const cn=t=>`${t.row===void 0?"":t.rowAbs?`R${t.row}`:`R[${t.row}]`}${t.col===void 0?"":t.colAbs?`C${t.col}`:`C[${t.col}]`}`;function Br(t,e){const n=[],o=s=>{switch(s.type){case"number":return n.push(s.value),"#n";case"string":return n.push(s.value),"#s";case"bool":return s.value?"T":"F";case"error":return s.code;case"cell":return`${s.sheet===void 0?"":`'${s.sheet}'!`}${cn(Ye(s.ref,e))}`;case"range":return`${s.sheet===void 0?"":`'${s.sheet}'!`}${cn(Ye(s.from,e))}:${cn(Ye(s.to,e))}`;case"name":return`N(${s.name.toUpperCase()})`;case"call":return`${s.name}(${s.args.map(o).join(",")})`;case"unary":return`${s.op}(${o(s.arg)})`;case"percent":return`%(${o(s.arg)})`;case"binary":return`(${o(s.left)}${s.op===" "?"_":s.op}${o(s.right)})`;case"union":return`U(${s.items.map(o).join(",")})`;case"array":return`{${s.rows.map(r=>r.map(o).join(",")).join(";")}}`;case"empty":return"~"}};return{key:o(t),constants:n}}const Eo=t=>/^[A-Za-z_][A-Za-z0-9_.]*$/.test(t)&&!/^[A-Za-z]{1,3}[0-9]+$/.test(t)?t:`'${t.replace(/'/g,"''")}'`;function un(t){const e=t.col===void 0?"":`${t.colAbs?"$":""}${mt(t.col)}`,n=t.row===void 0?"":`${t.rowAbs?"$":""}${t.row+1}`;return e+n}const jr={"=":10,"<>":10,"<":10,"<=":10,">":10,">=":10,"&":20,"+":30,"-":30,"*":40,"/":40,"^":50," ":80};function tn(t){const e=(n,o=0)=>{switch(n.type){case"number":return String(n.value);case"string":return`"${n.value.replace(/"/g,'""')}"`;case"bool":return n.value?"TRUE":"FALSE";case"error":return n.code;case"cell":return`${n.sheet===void 0?"":`${Eo(n.sheet)}!`}${un(n.ref)}`;case"range":return`${n.sheet===void 0?"":`${Eo(n.sheet)}!`}${un(n.from)}:${un(n.to)}`;case"name":return n.name;case"call":return n.name===":"?`${e(n.args[0],90)}:${e(n.args[1],90)}`:`${n.name}(${n.args.map(s=>e(s)).join(",")})`;case"unary":return`${n.op}${e(n.arg,60)}`;case"percent":return`${e(n.arg,70)}%`;case"binary":{const s=jr[n.op],r=`${e(n.left,s-.5)}${n.op}${e(n.right,s)}`;return s<=o?`(${r})`:r}case"union":return`(${n.items.map(s=>e(s)).join(",")})`;case"array":return`{${n.rows.map(s=>s.map(r=>e(r)).join(",")).join(";")}}`;case"empty":return""}};return e(t)}function Hr(t,e,n,o={rows:1048576,cols:16384}){return fs(t,o,s=>({row:s.row===void 0||s.rowAbs?s.row:s.row+e,col:s.col===void 0||s.colAbs?s.col:s.col+n}))}function Yr(t,e,n,o={rows:1048576,cols:16384}){return fs(t,o,s=>s.row!==void 0&&s.col!==void 0&&!s.rowAbs&&!s.colAbs?{row:n.row+(s.col-e.col),col:n.col+(s.row-e.row)}:{row:s.row===void 0||s.rowAbs?s.row:s.row+n.row-e.row,col:s.col===void 0||s.colAbs?s.col:s.col+n.col-e.col})}function fs(t,e,n){const o=r=>{const{row:i,col:l}=n(r);if(!(i!==void 0&&(i<0||i>=e.rows)||l!==void 0&&(l<0||l>=e.cols)))return{...r,...i!==void 0?{row:i}:{},...l!==void 0?{col:l}:{}}},s=r=>{switch(r.type){case"cell":{const i=o(r.ref);return i===void 0?{type:"error",code:"#REF!"}:{...r,ref:i}}case"range":{const i=o(r.from),l=o(r.to);return i===void 0||l===void 0?{type:"error",code:"#REF!"}:{...r,from:i,to:l}}case"call":return{...r,args:r.args.map(s)};case"unary":case"percent":return{...r,arg:s(r.arg)};case"binary":return{...r,left:s(r.left),right:s(r.right)};case"union":return{...r,items:r.items.map(s)};default:return r}};return s(t)}function Xr(t,e,n,o){let s;try{s=Re(t).ast}catch{return t}return tn(Yr(s,e,n,o))}function Yn(t,e,n,o){if(e===0&&n===0)return t;let s;try{s=Re(t).ast}catch{return t}return tn(Hr(s,e,n,o))}const kc=["bar","column","line","area","pie","scatter","combo"],Ao=["clustered","stacked","percent","smooth","doughnut"],ko=["top","right","bottom","left","none"],Vt=1e5;class ds extends Error{}function v(t,e){throw new ds(`${t}: ${e}`)}const pe=t=>typeof t=="object"&&t!==null&&!Array.isArray(t);function We(t){let e;try{e=Re(t).ast}catch{return}if(e.type==="cell"||e.type==="range"||e.type==="error"&&e.code==="#REF!")return e}function hn(t,e){(typeof t!="string"||We(t)===void 0)&&v(e,"not a range")}function fn(t,e,n){pe(t)||v(e,"a cell offset is { row, col, dx, dy }");for(const o of["row","col"])(!Number.isInteger(t[o])||t[o]<0)&&v(`${e}.${o}`,"a non-negative integer");(t.row>=n.rows||t.col>=n.cols)&&v(e,"outside the sheet");for(const o of["dx","dy"])(typeof t[o]!="number"||!Number.isFinite(t[o])||t[o]<0)&&v(`${e}.${o}`,"a non-negative number of px")}const Et=t=>typeof t=="number"&&Number.isFinite(t)&&t>0;function Vr(t,e){pe(t)||v(e,"an axis is { title?, min?, max?, format?, log?, gridlines? }");for(const n of Object.keys(t))["title","min","max","format","log","gridlines"].includes(n)||v(`${e}.${n}`,"not a field of an axis");t.title!==void 0&&typeof t.title!="string"&&v(`${e}.title`,"a text");for(const n of["min","max"])t[n]!==void 0&&(typeof t[n]!="number"||!Number.isFinite(t[n]))&&v(`${e}.${n}`,"a number");t.format!==void 0&&typeof t.format!="string"&&v(`${e}.format`,"a number format");for(const n of["log","gridlines"])t[n]!==void 0&&typeof t[n]!="boolean"&&v(`${e}.${n}`,"true or false")}function ms(t,e,n){pe(t)||v(e,"a chart is an object");for(const r of Object.keys(t))["id","type","variant","anchor","data","title","legend","axes","labels"].includes(r)||v(`${e}.${r}`,"not a field of a chart");(typeof t.id!="string"||t.id==="")&&v(`${e}.id`,"a non-empty string"),(typeof t.type!="string"||!/^[a-z][a-zA-Z0-9.-]*$/.test(t.type))&&v(`${e}.type`,"a chart type (column, line, … or a contributed type)"),t.variant!==void 0&&!Ao.includes(t.variant)&&v(`${e}.variant`,`one of ${Ao.join(", ")}`);const o=t.anchor;if(pe(o)||v(`${e}.anchor`,"an anchor is { kind, … }"),o.kind==="cells"){fn(o.from,`${e}.anchor.from`,n),fn(o.to,`${e}.anchor.to`,n);const r=o.from,i=o.to;(i.row<r.row||i.col<r.col)&&v(`${e}.anchor`,"from after to")}else if(o.kind==="cell")fn(o.from,`${e}.anchor.from`,n),Et(o.width)||v(`${e}.anchor.width`,"a positive number of px"),Et(o.height)||v(`${e}.anchor.height`,"a positive number of px");else if(o.kind==="absolute"){for(const r of["x","y"])(typeof o[r]!="number"||!Number.isFinite(o[r])||o[r]<0)&&v(`${e}.anchor.${r}`,"a non-negative number of px");Et(o.width)||v(`${e}.anchor.width`,"a positive number of px"),Et(o.height)||v(`${e}.anchor.height`,"a positive number of px")}else v(`${e}.anchor.kind`,"cells, cell or absolute");const s=t.data;if(pe(s)||v(`${e}.data`,"the data is { series, by, headers, blanks }"),(!Array.isArray(s.series)||s.series.length===0)&&v(`${e}.data.series`,"a non-empty list"),s.series.forEach((r,i)=>{const l=`${e}.data.series[${i}]`;pe(r)||v(l,"a series is { values, … }");for(const a of Object.keys(r))["name","values","categories","x","type","axis","color"].includes(a)||v(`${l}.${a}`,"not a field of a series");hn(r.values,`${l}.values`),r.categories!==void 0&&hn(r.categories,`${l}.categories`),r.x!==void 0&&hn(r.x,`${l}.x`),r.name!==void 0&&typeof r.name!="string"&&v(`${l}.name`,"a text or a range"),r.type!==void 0&&!["column","line","area"].includes(r.type)&&v(`${l}.type`,"column, line or area"),r.axis!==void 0&&r.axis!=="primary"&&r.axis!=="secondary"&&v(`${l}.axis`,"primary or secondary"),r.color!==void 0&&(typeof r.color!="string"||!/^#[0-9a-fA-F]{6}$/.test(r.color))&&v(`${l}.color`,"a colour such as #1f77b4")}),s.by!=="columns"&&s.by!=="rows"&&v(`${e}.data.by`,"columns or rows"),(!pe(s.headers)||typeof s.headers.row!="boolean"||typeof s.headers.column!="boolean")&&v(`${e}.data.headers`,"{ row, column }, true or false each"),["gap","zero","connect"].includes(s.blanks)||v(`${e}.data.blanks`,"gap, zero or connect"),t.title!==void 0&&typeof t.title!="string"&&v(`${e}.title`,"a text or a range"),ko.includes(t.legend)||v(`${e}.legend`,`one of ${ko.join(", ")}`),t.axes!==void 0){pe(t.axes)||v(`${e}.axes`,"{ x?, y?, y2? }");for(const r of Object.keys(t.axes))["x","y","y2"].includes(r)||v(`${e}.axes.${r}`,"not an axis (x, y or y2)"),Vr(t.axes[r],`${e}.axes.${r}`)}return t.labels!==void 0&&typeof t.labels!="boolean"&&v(`${e}.labels`,"true or false"),t}function Xn(t,e,n="chart"){try{ms(t,n,e);return}catch(o){if(o instanceof ds)return o.message;throw o}}function be(t,e,n){const o=We(n);if(o===void 0||o.type==="error")return;const s=o.type==="cell"||o.type==="range"?o.sheet===void 0?e:t.sheetByName(o.sheet)?.id:void 0;if(s===void 0)return;const r=t.sheet(s);if(o.type==="cell"){const{row:u,col:h}=o.ref;return u===void 0||h===void 0?void 0:{sheet:s,zone:{top:u,left:h,bottom:u,right:h}}}if(o.type!=="range")return;const i=o.from.row??0,l=o.to.row??r.rows.count-1,a=o.from.col??0,c=o.to.col??r.cols.count-1;return{sheet:s,zone:{top:Math.min(i,l),left:Math.min(a,c),bottom:Math.max(i,l),right:Math.max(a,c)}}}const ps=t=>(t.bottom-t.top+1)*(t.right-t.left+1);function $c(t,e){const n=e.anchor;if(n.kind==="absolute")return{x:n.x,y:n.y,width:n.width,height:n.height};const o=t.cols.offsetOf(n.from.col)+n.from.dx,s=t.rows.offsetOf(n.from.row)+n.from.dy;if(n.kind==="cell")return{x:o,y:s,width:n.width,height:n.height};const r=t.cols.offsetOf(n.to.col)+n.to.dx,i=t.rows.offsetOf(n.to.row)+n.to.dy;return{x:o,y:s,width:Math.max(1,r-o),height:Math.max(1,i-s)}}function gs(t){const e=[];for(const n of t.data.series)e.push(n.values),n.categories!==void 0&&e.push(n.categories),n.x!==void 0&&e.push(n.x),n.name!==void 0&&We(n.name)!==void 0&&e.push(n.name);return e}function Wr(t,e,n){const o=[];for(const s of gs(n)){const r=be(t,e,s);r!==void 0&&o.push(r)}return o}function*$o(t){for(let e=t.top;e<=t.bottom;e+=1)for(let n=t.left;n<=t.right;n+=1)yield[e,n]}function Gr(t,e,n,o){const s=[],r=c=>{if(c===void 0)return;const u=be(e,n,c);if(u===void 0)return s.push(c),[];const h=[];for(const[d,f]of $o(u.zone)){const m=t(u.sheet,d,f);typeof m=="number"?h.push(m):h.push(m===null&&o.data.blanks==="zero"?0:null)}return h},i=c=>{const u=be(e,n,c);if(u===void 0)return s.push(c),[];const h=[];for(const[d,f]of $o(u.zone)){const m=t(u.sheet,d,f);h.push(typeof m=="number"||typeof m=="string"?m:m===null?"":String(m))}return h};let l;const a=o.data.series.map((c,u)=>{l===void 0&&c.categories!==void 0&&(l=i(c.categories));let h=`Series ${u+1}`;if(c.name!==void 0)if(We(c.name)===void 0)h=c.name;else{const p=be(e,n,c.name);if(p===void 0)s.push(c.name);else{const g=t(p.sheet,p.zone.top,p.zone.left);g!==null&&typeof g!="object"&&(h=String(g))}}const d=r(c.values),f=r(c.x),m=be(e,n,c.values)===void 0;return{name:h,values:d,...f!==void 0?{x:f}:{},...c.type!==void 0?{type:c.type}:{},...c.axis!==void 0?{axis:c.axis}:{},...c.color!==void 0?{color:c.color}:{},...m?{}:{source:c.values}}});return{categories:l??[],series:a,deleted:[...new Set(s)]}}function Kr(t,e,n){let o=0;for(const s of n.data.series){const r=be(t,e,s.values);r!==void 0&&(o+=ps(r.zone))}return o}function Zr(t,e,n){for(const o of n.data.series){const s=be(t.workbook,e,o.values);if(s!==void 0){for(const[r,i]of t.workbook.sheet(s.sheet).cells.entries(s.zone))if(typeof t.value(s.sheet,r,i)=="number")return!0}}return!1}function Ie(t,e){const n=/^[A-Za-z_][A-Za-z0-9_.]*$/.test(t)&&!/^[A-Za-z]{1,3}[0-9]+$/.test(t)?t:`'${t.replace(/'/g,"''")}'`,o=`$${mt(e.left)}$${e.top+1}`,s=`$${mt(e.right)}$${e.bottom+1}`;return`${n}!${o===s?o:`${o}:${s}`}`}function Jr(t,e,n,o=()=>!1){const s=n.bottom-n.top+1,r=n.right-n.left+1,i=(p,g)=>typeof t(p,g)=="string",l=(p,g)=>typeof t(p,g)=="number"&&!o(p,g);let a=0;for(let p=n.top;p<=n.bottom;p+=1)for(let g=n.left;g<=n.right;g+=1)l(p,g)&&(a+=1);if(a===0)return{ok:!1,reason:"NoNumericData",message:"The selection holds no number to chart."};let c=s>1;for(let p=n.left+(r>1?1:0);p<=n.right&&c;p+=1)i(n.top,p)||t(n.top,p)===null||(c=!1);if(c){let p=!1;for(let g=n.left;g<=n.right;g+=1)i(n.top,g)&&(p=!0);c=p}let u=r>1;for(let p=n.top+(c?1:0);p<=n.bottom&&u;p+=1)i(p,n.left)||o(p,n.left)||t(p,n.left)===null||(u=!1);const h={top:n.top+(c?1:0),left:n.left+(u?1:0),bottom:n.bottom,right:n.right};if(h.top>h.bottom||h.left>h.right)return{ok:!1,reason:"NoNumericData",message:"The selection holds no number to chart."};const d=ps(h);if(d>Vt)return{ok:!1,reason:"ChartTooLarge",message:`A chart holds at most ${Vt.toLocaleString("en-US")} points; this selection has ${d.toLocaleString("en-US")}.`};const f=h.bottom-h.top>=h.right-h.left,m=[];if(f)for(let p=h.left;p<=h.right;p+=1)m.push({values:Ie(e,{top:h.top,left:p,bottom:h.bottom,right:p}),...c?{name:Ie(e,{top:n.top,left:p,bottom:n.top,right:p})}:{},...u?{categories:Ie(e,{top:h.top,left:n.left,bottom:h.bottom,right:n.left})}:{}});else for(let p=h.top;p<=h.bottom;p+=1)m.push({values:Ie(e,{top:p,left:h.left,bottom:p,right:h.right}),...u?{name:Ie(e,{top:p,left:n.left,bottom:p,right:n.left})}:{},...c?{categories:Ie(e,{top:n.top,left:h.left,bottom:n.top,right:h.right})}:{}});return{ok:!0,data:{series:m,by:f?"columns":"rows",headers:{row:c,column:u},blanks:"gap"}}}const qr={op:"chart",apply(t,e){const n=t.sheet(e.sheet);e.after===null?n.charts.delete(e.id):n.charts.set(e.id,e.after)},invert:t=>({...t,before:t.after,after:t.before}),bytes:()=>512,example:()=>({op:"chart",sheet:"s1",id:"c1",before:null,after:{id:"c1",type:"column",anchor:{kind:"cells",from:{row:1,col:4,dx:0,dy:0},to:{row:10,col:9,dx:0,dy:0}},data:{series:[{values:"Sheet1!$B$2:$B$5"}],by:"columns",headers:{row:!1,column:!1},blanks:"gap"},legend:"bottom"}})};function ws(t,e){return t.workbook.hasSheet(e)?void 0:A("UnknownSheet",`No sheet '${e}'.`)}function nn(t,e,n){const o=ws(t,e);return o||(t.workbook.sheet(e).charts.get(n)??A("UnknownChart",`No chart '${n}' on this sheet.`))}const on=t=>typeof t=="object"&&t!==null&&"ok"in t&&typeof t.ok=="boolean";function ys(t,e,n){const o=Xn(n,t.workbook.limits);if(o!==void 0)return A("InvalidArgument",o);const s=Kr(t.workbook,e,n);return s>Vt?A("ChartTooLarge",`A chart holds at most ${Vt.toLocaleString("en-US")} points; this one has ${s.toLocaleString("en-US")}.`):Zr(t,e,n)?U:A("NoNumericData","The chart’s ranges hold no number to draw.")}function Qr(t,e){const n=t.workbook.sheet(e).charts;for(let o=1;;o+=1)if(!n.has(`chart${o}`))return`chart${o}`}const wt=(t,e,n,o)=>({op:"chart",sheet:t,id:e,before:n,after:o});function So(t,e){return{...e.chart,id:e.chart.id??Qr(t,e.sheet)}}const ei={type:"INSERT_CHART",allow:(t,e)=>{const n=ws(t,e.sheet);if(n)return n;const o=So(t,e);return t.workbook.sheet(e.sheet).charts.has(o.id)?A("DuplicateChart",`A chart '${o.id}' is on this sheet already.`):ys(t,e.sheet,o)},apply:(t,e)=>{const n=So(t,e);return[wt(e.sheet,n.id,null,n)]}},ti={type:"UPDATE_CHART",allow:(t,e)=>{const n=nn(t,e.sheet,e.id);return on(n)?n:"id"in e.changes||"anchor"in e.changes?A("InvalidArgument","An update changes neither the id nor the anchor (MOVE_CHART, RESIZE_CHART)."):ys(t,e.sheet,{...n,...e.changes})},apply:(t,e)=>{const n=t.workbook.sheet(e.sheet).charts.get(e.id);return[wt(e.sheet,e.id,n,{...n,...e.changes})]}};function xo(t,e){const n=t.anchor;return n.kind==="absolute"?"x"in e?{...n,x:e.x,y:e.y}:"An absolute chart moves to px (x, y), not to a cell.":"row"in e?n.kind==="cell"?{...n,from:{...n.from,row:e.row,col:e.col}}:{...n,from:{...n.from,row:e.row,col:e.col},to:{...n.to,row:e.row+(n.to.row-n.from.row),col:e.col+(n.to.col-n.from.col)}}:"A chart anchored on cells moves to a cell (row, col), not to px."}const ni={type:"MOVE_CHART",allow:(t,e)=>{const n=nn(t,e.sheet,e.id);if(on(n))return n;const o=xo(n,e.to);if(typeof o=="string")return A("InvalidArgument",o);const s=Xn({...n,anchor:o},t.workbook.limits);return s===void 0?U:A("InvalidArgument",s)},apply:(t,e)=>{const n=t.workbook.sheet(e.sheet).charts.get(e.id);return[wt(e.sheet,e.id,n,{...n,anchor:xo(n,e.to)})]}};function vo(t,e){const n=t.anchor;return n.kind==="cells"?"row"in e?{...n,to:{...n.to,row:e.row,col:e.col}}:"A chart anchored on cells is resized to a cell (row, col).":"width"in e?{...n,width:e.width,height:e.height}:"This chart is resized in px (width, height)."}const oi={type:"RESIZE_CHART",allow:(t,e)=>{const n=nn(t,e.sheet,e.id);if(on(n))return n;const o=vo(n,e.to);if(typeof o=="string")return A("InvalidArgument",o);const s=Xn({...n,anchor:o},t.workbook.limits);return s===void 0?U:A("InvalidArgument",s)},apply:(t,e)=>{const n=t.workbook.sheet(e.sheet).charts.get(e.id);return[wt(e.sheet,e.id,n,{...n,anchor:vo(n,e.to)})]}},si={type:"DELETE_CHART",allow:(t,e)=>{const n=nn(t,e.sheet,e.id);return on(n)?n:U},apply:(t,e)=>{const n=t.workbook.sheet(e.sheet).charts.get(e.id);return[wt(e.sheet,e.id,n,null)]}},ri=[ei,ti,ni,oi,si];function ge(t,e){const{at:n,n:o}=t;switch(t.kind){case"insert":return e>=n?e+o:e;case"delete":return e<n?e:e<n+o?void 0:e-o;case"move":{const{to:s}=t;return e>=n&&e<n+o?s<n?s+(e-n):s-o+(e-n):s<n&&e>=s&&e<n?e+o:s>n&&e>=n+o&&e<s?e-o:e}}}function bs(t,e,n,o){const s=n==="rows"?"row":"col",r={type:"error",code:"#REF!"},i=(u,h)=>({...u,[s]:h});let l=!1;const a=u=>{switch(u.type){case"cell":{const h=u.ref[s];if(!e(u.sheet)||h===void 0)return u;const d=ge(o,h);return d===h?u:(l=!0,d===void 0?r:{...u,ref:i(u.ref,d)})}case"range":{const h=u.from[s],d=u.to[s];if(!e(u.sheet)||h===void 0||d===void 0)return u;const f=Math.min(h,d),m=Math.max(h,d);let p,g;if(o.kind==="delete"){if(p=f>=o.at&&f<o.at+o.n?o.at:ge(o,f),g=m>=o.at&&m<o.at+o.n?o.at-1:ge(o,m),p>g)return l=!0,r}else{const T=ge(o,f),x=ge(o,m);p=Math.min(T,x),g=Math.max(T,x)}const[y,E]=h<=d?[u.from,u.to]:[u.to,u.from];return p===f&&g===m&&h<=d?u:(l=!0,{...u,from:i(y,p),to:i(E,g)})}case"call":return{...u,args:u.args.map(a)};case"unary":case"percent":return{...u,arg:a(u.arg)};case"binary":return{...u,left:a(u.left),right:a(u.right)};case"union":return{...u,items:u.items.map(a)};default:return u}},c=a(t);return l?c:t}function Vn(t,e,n,o){const r=t.sheet(e).name.toLowerCase(),i=[];for(const a of t.sheets){const c=a.id===e,u=h=>h===void 0?c:h.toLowerCase()===r;for(const[h,d,f]of a.cells.entries()){if(f.formula===void 0)continue;let m;try{m=Re(f.formula).ast}catch{continue}const p=bs(m,u,n,o);if(p===m)continue;const g=tn(p);let y=h,E=d;if(c){const x=ge(o,n==="rows"?h:d);if(x===void 0)continue;n==="rows"?y=x:E=x}const T={...f,formula:g,value:null};i.push({op:"cells",sheet:a.id,zone:{top:y,left:E,bottom:y,right:E},before:Ne([[y,E,f]]),after:Ne([[y,E,T]])})}}i.push(...ii(t,e,n,o));const l=t.sheet(e).dataSource;if(l!==null){const a=n==="rows"?"row":"col",c=ge(o,l.at[a]);c!==void 0&&c!==l.at[a]&&i.push({op:"dataSource",sheet:e,before:l,after:{...l,at:{...l.at,[a]:c}}})}return i}function Mo(t,e,n){const o=ge(t,e);return o!==void 0?o:n?Math.max(0,t.at-1):t.at}function ii(t,e,n,o){const s=t.sheet(e).name.toLowerCase(),r=[];for(const i of t.sheets){const l=i.id===e,a=c=>c===void 0?l:c.toLowerCase()===s;for(const[c,u]of i.charts){let h=!1;const d=g=>{if(g===void 0)return;const y=We(g);if(y===void 0||y.type==="error")return g;const E=bs(y,a,n,o);return E===y?g:(h=!0,tn(E))},f=u.data.series.map(g=>{const y=d(g.values),E=d(g.categories),T=d(g.x),x=g.name!==void 0&&We(g.name)!==void 0?d(g.name):g.name;return{...g,values:y,...E!==void 0?{categories:E}:{},...T!==void 0?{x:T}:{},...x!==void 0?{name:x}:{}}});let m=u.anchor;if(l&&m.kind!=="absolute"){const g=n==="rows"?"row":"col",y={...m.from,[g]:Mo(o,m.from[g],!1)};if(m.kind==="cells"){let E={...m.to,[g]:Mo(o,m.to[g],!0)};E[g]<y[g]&&(E={...E,[g]:y[g]}),m={...m,from:y,to:E}}else m={...m,from:y};JSON.stringify(m)!==JSON.stringify(u.anchor)&&(h=!0)}if(!h)continue;const p={...u,anchor:m,data:{...u.data,series:f}};r.push({op:"chart",sheet:i.id,id:c,before:u,after:p})}}return r}const U={ok:!0};function A(t,e){return{ok:!1,refusals:[{reason:t,message:e}]}}function On(t){if(t.startsWith("'"))return t.slice(1);if(t.startsWith("=")&&t.length>1)return{formula:t.slice(1)};const e=t.trim();return e!==""&&/^[+-]?(\d+\.?\d*|\.\d+)([eE][+-]?\d+)?$/.test(e)?Number(e):/^true$/i.test(e)?!0:/^false$/i.test(e)?!1:t===""?null:t}function W(t,e){return t.hasSheet(e)?t.sheet(e):A("UnknownSheet",`No sheet '${e}'.`)}const G=t=>typeof t=="object"&&t!==null&&"ok"in t&&typeof t.ok=="boolean";function yt(t,e){return![e.top,e.left,e.bottom,e.right].every(Number.isInteger)||e.top<0||e.left<0||e.top>e.bottom||e.left>e.right?A("InvalidArgument",`The zone ${JSON.stringify(e)} is not a zone.`):e.bottom>=t.rows.count||e.right>=t.cols.count?A("OutOfBounds",`The zone reaches past the sheet's ${t.rows.count} rows or ${t.cols.count} columns.`):U}function bt(t,e,n,o){const s=e==="rows"?t.rows.count:t.cols.count;return!Number.isInteger(n)||!Number.isInteger(o)||o<1||n<0?A("InvalidArgument",`${o} ${e} at ${n} is not a span.`):n+o>s?A("OutOfBounds",`${o} ${e} at ${n} reach past the sheet's ${s}.`):U}function li(t,e,n){if(e===null||typeof e!="object"||$(e))return{value:e,style:n?.style??0};const o=e.style===void 0?n?.style??0:e.style===null?0:t.styles.intern(e.style);return e.formula!==void 0?e.value!==void 0&&e.value!==null?{value:e.value,formula:e.formula,style:o}:{value:null,formula:e.formula,style:o}:{value:e.value??null,style:o}}function ai(t){if(t===null||typeof t=="string"||typeof t=="boolean")return;if(typeof t=="number")return Number.isFinite(t)?void 0:`${t} is not a cell value`;if($(t))return;if(typeof t!="object")return`${String(t)} is not a cell input`;if(t.formula!==void 0&&(typeof t.formula!="string"||t.formula===""))return"a formula is a non-empty string, without the =";if(t.style!==void 0&&t.style!==null)try{Hn(t.style)}catch(n){return n.message}const e=t.value;if(e!=null&&typeof e=="number"&&!Number.isFinite(e))return`${e} is not a cell value`}function qe(t,e,n){const o=Ve(t,e),s=new Map;for(const r of gt(o))s.set(`${r[0]},${r[1]}`,r);for(const[r,i,l]of n){const a=`${r},${i}`;l===null||l.value===null&&l.formula===void 0&&l.style===0?s.delete(a):s.set(a,[r,i,l])}return{op:"cells",sheet:t.id,zone:e,before:o,after:Ne([...s.values()])}}function To(t,e,n){return n===null?0:t.styles.intern({...t.styles.get(e),...n})}function Es(t,e,n,o,s){const r=e==="rows"?t.rows:t.cols,i={sizes:new Float64Array(o),hidden:new Uint8Array(o)},l={sizes:new Float64Array(o),hidden:new Uint8Array(o)};for(let a=0;a<o;a+=1){const c=r.sizeOf(n+a),u=r.isHidden(n+a);i.sizes[a]=c,i.hidden[a]=u?1:0;const[h,d]=s(a,c,u);l.sizes[a]=h,l.hidden[a]=d?1:0}return{op:"axis-sizes",sheet:t.id,axis:e,at:n,n:o,before:i,after:l}}function As(t,e,n,o,s){const r=[];for(const i of t){const l=e==="rows"?i.top:i.left,a=e==="rows"?i.bottom:i.right;let c=l,u=a;if(o>0){if(l>=n&&(c+=o),a>=n&&(u+=o),u>=s)continue}else{const d=-o,f=n+d;if(c=(p=>p>=f?p-d:p>=n?n:p)(l),u=a>=f?a-d:a>=n?n-1:a,u<c)continue}const h=e==="rows"?{...i,top:c,bottom:u}:{...i,left:c,right:u};h.top===h.bottom&&h.left===h.right||r.push(h)}return r}const ks=(t,e)=>JSON.stringify(t)===JSON.stringify(e),ci={type:"SET_CELLS",allow({workbook:t},e){const n=W(t,e.sheet);if(G(n))return n;if(!Array.isArray(e.cells)||e.cells.length===0||!e.cells.every(s=>Array.isArray(s)))return A("InvalidArgument","SET_CELLS takes a non-empty block of rows.");const o=Math.max(...e.cells.map(s=>s.length));if(o===0)return A("InvalidArgument","SET_CELLS takes at least one cell.");for(const s of e.cells)for(const r of s){const i=ai(r);if(i)return A("InvalidArgument",`SET_CELLS: ${i}.`)}return yt(n,{top:e.at.row,left:e.at.col,bottom:e.at.row+e.cells.length-1,right:e.at.col+o-1})},apply({workbook:t},e){const n=t.sheet(e.sheet),o=Math.max(...e.cells.map(i=>i.length)),s={top:e.at.row,left:e.at.col,bottom:e.at.row+e.cells.length-1,right:e.at.col+o-1},r=[];return e.cells.forEach((i,l)=>i.forEach((a,c)=>{const u=e.at.row+l,h=e.at.col+c;r.push([u,h,li(t,a,n.cells.get(u,h))])})),[qe(n,s,r)]}},ui={type:"SET_STYLE",allow({workbook:t},e){const n=W(t,e.sheet);if(G(n))return n;if(e.style!==null)try{Hn(e.style)}catch(o){return A("InvalidArgument",o.message)}return yt(n,e.zone)},apply({workbook:t},e){const n=t.sheet(e.sheet),o=[],{top:s,left:r,bottom:i,right:l}=e.zone;if((i-s+1)*(l-r+1)>1e6)for(const[c,u,h]of n.cells.entries(e.zone))o.push([c,u,{...h,style:To(t,h.style,e.style)}]);else for(let c=s;c<=i;c+=1)for(let u=r;u<=l;u+=1){const h=n.cells.get(c,u)??{value:null,style:0};o.push([c,u,{...h,style:To(t,h.style,e.style)}])}return[qe(n,e.zone,o)]}},hi={type:"CLEAR",allow({workbook:t},e){const n=W(t,e.sheet);return G(n)?n:e.what!==void 0&&!["all","contents","styles"].includes(e.what)?A("InvalidArgument",`CLEAR clears all, contents or styles, not '${e.what}'.`):yt(n,e.zone)},apply({workbook:t},e){const n=t.sheet(e.sheet),o=e.what??"all",s=[];for(const[r,i,l]of n.cells.entries(e.zone))o==="all"?s.push([r,i,null]):o==="contents"?s.push([r,i,{value:null,style:l.style}]):s.push([r,i,{...l,style:0}]);return[qe(n,e.zone,s)]}},fi={type:"INSERT_AXIS",allow({workbook:t},e){const n=W(t,e.sheet);if(G(n))return n;if(e.axis!=="rows"&&e.axis!=="cols")return A("InvalidArgument",`No axis '${String(e.axis)}'.`);const o=bt(n,e.axis,e.at,e.n);if(!o.ok)return o;const s=e.axis==="rows"?n.rows.count:n.cols.count,r=e.axis==="rows"?{top:s-e.n,left:0,bottom:s-1,right:n.cols.count-1}:{top:0,left:s-e.n,bottom:n.rows.count-1,right:s-1};return!n.cells.isEmpty(r)||n.mergesIn(r).length>0?A("NotEmptyAtEnd",`Inserting ${e.n} ${e.axis} would push content off the end of the sheet.`):U},apply({workbook:t},e){const n=t.sheet(e.sheet),o=e.axis==="rows"?n.rows:n.cols,s=o.count,r=o.segment(s-e.n,e.n),i={op:"axis-insert",sheet:n.id,axis:e.axis,at:e.at,n:e.n,inserted:{ids:o.freshIds(e.n),sizes:null,hidden:null},dropped:r},l=As(n.merges,e.axis,e.at,e.n,s),a=[i];return ks(l,n.merges)||a.push({op:"merges",sheet:n.id,before:n.merges,after:l}),a.push(...Vn(t,n.id,e.axis,{kind:"insert",at:e.at,n:e.n})),a}},di={type:"DELETE_AXIS",allow({workbook:t},e){const n=W(t,e.sheet);return G(n)?n:e.axis!=="rows"&&e.axis!=="cols"?A("InvalidArgument",`No axis '${String(e.axis)}'.`):bt(n,e.axis,e.at,e.n)},apply({workbook:t},e){const n=t.sheet(e.sheet),o=e.axis==="rows"?n.rows:n.cols,s=e.axis==="rows"?{top:e.at,left:0,bottom:e.at+e.n-1,right:n.cols.count-1}:{top:0,left:e.at,bottom:n.rows.count-1,right:e.at+e.n-1},r=[],i=Ve(n,s);i.rows.length>0&&r.push({op:"cells",sheet:n.id,zone:s,before:i,after:ls});const l=As(n.merges,e.axis,e.at,-e.n,o.count);return ks(l,n.merges)||r.push({op:"merges",sheet:n.id,before:n.merges,after:l}),r.push({op:"axis-delete",sheet:n.id,axis:e.axis,at:e.at,n:e.n,removed:o.segment(e.at,e.n)}),r.push(...Vn(t,n.id,e.axis,{kind:"delete",at:e.at,n:e.n})),r}},mi={type:"MOVE_AXIS",allow({workbook:t},e){const n=W(t,e.sheet);if(G(n))return n;const o=bt(n,e.axis,e.at,e.n);if(!o.ok)return o;const s=e.axis==="rows"?n.rows.count:n.cols.count;if(!Number.isInteger(e.to)||e.to<0||e.to>s||e.to>=e.at&&e.to<=e.at+e.n)return A("InvalidArgument",`Cannot move ${e.n} ${e.axis} at ${e.at} to ${e.to}.`);const r=Math.min(e.at,e.to),i=Math.max(e.at+e.n,e.to)-1,l=e.axis==="rows"?{top:r,left:0,bottom:i,right:n.cols.count-1}:{top:0,left:r,bottom:n.rows.count-1,right:i};return n.mergesIn(l).length>0?A("MergeOverlap","Moving across merged cells is not supported yet; unmerge first."):U},apply({workbook:t},e){const n=t.sheet(e.sheet),o=Math.min(e.at,e.to),s=Math.max(e.at+e.n,e.to)-1,r=e.axis==="rows"?{top:o,left:0,bottom:s,right:n.cols.count-1}:{top:0,left:o,bottom:n.rows.count-1,right:s},i=c=>c>=e.at&&c<e.at+e.n?e.to<e.at?e.to+(c-e.at):e.to-e.n+(c-e.at):e.to<e.at&&c>=e.to&&c<e.at?c+e.n:e.to>e.at&&c>=e.at+e.n&&c<e.to?c-e.n:c,l=Ve(n,r),a=gt(l).map(([c,u,h])=>e.axis==="rows"?[i(c),u,h]:[c,i(u),h]);return[{op:"cells",sheet:n.id,zone:r,before:l,after:Ne(a)},{op:"axis-move",sheet:n.id,axis:e.axis,at:e.at,n:e.n,to:e.to},...Vn(t,n.id,e.axis,{kind:"move",at:e.at,n:e.n,to:e.to})]}},pi={type:"RESIZE_AXIS",allow({workbook:t},e){const n=W(t,e.sheet);return G(n)?n:!(e.size>0)||!Number.isFinite(e.size)?A("InvalidArgument",`A size must be positive; ${e.size} was given.`):bt(n,e.axis,e.from,e.to-e.from+1)},apply({workbook:t},e){const n=t.sheet(e.sheet);return[Es(n,e.axis,e.from,e.to-e.from+1,(o,s,r)=>[e.size,r])]}},gi={type:"HIDE_AXIS",allow({workbook:t},e){const n=W(t,e.sheet);return G(n)?n:bt(n,e.axis,e.from,e.to-e.from+1)},apply({workbook:t},e){const n=t.sheet(e.sheet);return[Es(n,e.axis,e.from,e.to-e.from+1,(o,s)=>[s,e.hidden])]}},wi={type:"MERGE",allow({workbook:t},e){const n=W(t,e.sheet);if(G(n))return n;const o=yt(n,e.zone);return o.ok?e.zone.top===e.zone.bottom&&e.zone.left===e.zone.right?A("InvalidArgument","A merge spans more than one cell."):n.mergesIn(e.zone).length>0?A("MergeOverlap","The zone overlaps a merge; unmerge it first."):U:o},apply({workbook:t},e){const n=t.sheet(e.sheet),o=[];for(const[r,i]of n.cells.entries(e.zone))(r!==e.zone.top||i!==e.zone.left)&&o.push([r,i,null]);const s=[];return o.length>0&&s.push(qe(n,e.zone,o)),s.push({op:"merges",sheet:n.id,before:n.merges,after:[...n.merges,e.zone]}),s}},yi={type:"UNMERGE",allow({workbook:t},e){const n=W(t,e.sheet);if(G(n))return n;const o=yt(n,e.zone);return o.ok?n.mergesIn(e.zone).length===0?A("NoMerge","Nothing is merged there."):U:o},apply({workbook:t},e){const n=t.sheet(e.sheet),o=n.merges.filter(s=>!Te(s,e.zone));return[{op:"merges",sheet:n.id,before:n.merges,after:o}]}};function $s(t,e,n){if(typeof e!="string"||e.trim()===""||e.length>31||/[\\/?*[\]:]/.test(e)||/^'|'$/.test(e))return A("InvalidSheetName",`'${String(e)}' is not a sheet name: 1 to 31 characters, none of \\ / ? * [ ] :, no leading or trailing '.`);const o=t.sheetByName(e);return o!==void 0&&o.id!==n?A("DuplicateSheetName",`A sheet is called '${e}' already.`):U}const bi={type:"ADD_SHEET",allow({workbook:t},e){return e.at!==void 0&&(!Number.isInteger(e.at)||e.at<0||e.at>t.sheets.length)?A("OutOfBounds",`No tab position ${e.at}.`):e.id!==void 0&&t.hasSheet(e.id)?A("InvalidArgument",`A sheet has the id '${e.id}' already.`):e.name===void 0?U:$s(t,e.name)},apply({workbook:t},e){const n=t.createSheet(e.name??t.freshSheetName(),e.id);return[{op:"sheet-add",index:e.at??t.sheets.length,sheet:n}]}},Ei={type:"DELETE_SHEET",allow({workbook:t},e){const n=W(t,e.sheet);return G(n)?n:t.sheets.length===1?A("LastSheet","A workbook keeps at least one sheet."):U},apply({workbook:t},e){const n=t.sheet(e.sheet);return[{op:"sheet-delete",index:t.sheets.indexOf(n),sheet:n}]}},Ai={type:"RENAME_SHEET",allow({workbook:t},e){const n=W(t,e.sheet);return G(n)?n:$s(t,e.name,e.sheet)},apply({workbook:t},e){const n=t.sheet(e.sheet);return[{op:"sheet-rename",sheet:n.id,before:n.name,after:e.name}]}},ki={type:"MOVE_SHEET",allow({workbook:t},e){const n=W(t,e.sheet);return G(n)?n:!Number.isInteger(e.to)||e.to<0||e.to>=t.sheets.length?A("OutOfBounds",`No tab position ${e.to}.`):U},apply({workbook:t},e){const n=t.sheets.indexOf(t.sheet(e.sheet));return n===e.to?[]:[{op:"sheet-move",from:n,to:e.to}]}},$i={type:"FREEZE",allow({workbook:t},e){const n=W(t,e.sheet);if(G(n))return n;const o=(r,i)=>Number.isInteger(r)&&r>=0&&r<i;if(!o(e.rows,n.rows.count)||!o(e.cols,n.cols.count))return A("OutOfBounds",`Cannot freeze ${e.rows} rows and ${e.cols} columns.`);const s=r=>e.rows>0&&r.top<e.rows&&r.bottom>=e.rows||e.cols>0&&r.left<e.cols&&r.right>=e.cols;return n.merges.some(s)?A("MergeOverlap","A merge crosses the frozen edge."):U},apply({workbook:t},e){const n=t.sheet(e.sheet);return[{op:"frozen",sheet:n.id,before:n.frozen,after:{rows:e.rows,cols:e.cols}}]}},Si=[ci,ui,hi,fi,di,mi,pi,gi,wi,yi,bi,Ei,Ai,ki,$i],Co=["width","height","dx","dy"],xi="code",No=["stream","display_data","execute_result","error"],Ro=["source","language","outputs","result","executionCount","lastRun","run","frame"],lt=t=>typeof t=="object"&&t!==null&&!Array.isArray(t);function Ss(t,e="code"){if(!lt(t))return`${e}: a code cell is { source, language, outputs, result, run }`;for(const s of Object.keys(t))if(!Ro.includes(s))return`${e}.${s}: a code cell has ${Ro.join(", ")} only`;if(typeof t.source!="string")return`${e}.source: the code, a string`;if(t.language!=="python")return`${e}.language: 'python'`;if(!Array.isArray(t.outputs))return`${e}.outputs: a list of nbformat outputs`;for(let s=0;s<t.outputs.length;s+=1){const r=t.outputs[s];if(!lt(r)||!No.includes(r.output_type))return`${e}.outputs[${s}].output_type: one of ${No.join(", ")}`}const n=t.result;if(!(n===null||typeof n=="string"||typeof n=="boolean"||typeof n=="number"&&Number.isFinite(n)||lt(n)&&Object.keys(n).length===1&&typeof n.error=="string"&&dt(n.error)))return`${e}.result: a value (a number, a string, a boolean, null or { error })`;if(t.executionCount!==void 0&&!(Number.isInteger(t.executionCount)&&t.executionCount>=0))return`${e}.executionCount: a non-negative integer`;if(t.lastRun!==void 0&&(typeof t.lastRun!="string"||Number.isNaN(Date.parse(t.lastRun))))return`${e}.lastRun: an ISO time`;if(t.run!=="manual"&&t.run!=="auto")return`${e}.run: 'manual' or 'auto'`;if(t.frame!==void 0&&t.frame!==null){const s=t.frame;if(!lt(s))return`${e}.frame: { width, height } or null`;for(const r of Object.keys(s))if(!Co.includes(r))return`${e}.frame.${r}: a frame has ${Co.join(", ")} only`;for(const r of["width","height"])if(!(typeof s[r]=="number"&&s[r]>0&&Number.isFinite(s[r])))return`${e}.frame.${r}: a positive size in px`;for(const r of["dx","dy"])if(s[r]!==void 0&&!(typeof s[r]=="number"&&Number.isFinite(s[r])))return`${e}.frame.${r}: an offset in px, a finite number`}}function xs(t,e={}){return{source:t,language:"python",outputs:[],result:null,run:"manual",...e}}function vi(t){return lt(t)?{error:t.error}:t}const Mi={width:360,height:240};function Ti(t){if(!(t.frame===null||t.outputs.length===0))return t.frame??Mi}function we(t,e,n){return`${t.rows.materialize(e)}.${t.cols.materialize(n)}`}function Ci(t,e,n){if(t.code.size!==0)return t.code.get(`${t.rows.idAt(e)}.${t.cols.idAt(n)}`)}function vs(t,e){const[n,o]=e.split(".").map(Number),s=t.rows.indexOfId(n),r=t.cols.indexOfId(o);return s<0||r<0?void 0:{row:s,col:r}}function jt(t){const e=[];for(const[n,o]of t.code){const s=vs(t,n);s!==void 0&&e.push({...s,code:o})}return e.sort((n,o)=>n.row-o.row||n.col-o.col)}const Wn=(t,e)=>`${mt(e)}${t+1}`,Ni={op:"code",apply(t,e){const n=t.sheet(e.sheet);e.after===null?n.code.delete(e.key):n.code.set(e.key,e.after)},invert:t=>({...t,before:t.after,after:t.before}),bytes:t=>256+JSON.stringify(t.after??t.before??{}).length*2,example:t=>({op:"code",sheet:"s1",key:we(t.sheet("s1"),1,1),before:null,after:xs("1 + 1")})};function Ri(t,e,n){const{type:o,...s}=t.styles.get(e);return t.styles.intern(n===void 0?s:{...s,type:n})}function Oi(t,e){const n=t.sheet(e.sheet),o=we(n,e.row,e.col),s=n.code.get(o)??null,r={top:e.row,left:e.col,bottom:e.row,right:e.col},i=Ve(n,r),l=gt(i)[0]?.[2],a=Ri(t,l?.style??0,e.code===null?void 0:xi),c=e.code===null?a===0?null:{value:null,style:a}:{value:vi(e.code.result),style:a},u={op:"cells",sheet:n.id,zone:r,before:i,after:Ne(c===null?[]:[[e.row,e.col,c]])};return[{op:"code",sheet:n.id,key:o,before:s,after:e.code},u]}const Ii={type:"SET_CODE",allow({workbook:t},e){if(!t.hasSheet(e.sheet))return A("UnknownSheet",`No sheet '${e.sheet}'.`);const n=t.sheet(e.sheet);if(!Number.isInteger(e.row)||!Number.isInteger(e.col)||e.row<0||e.col<0||e.row>=n.rows.count||e.col>=n.cols.count)return A("OutOfBounds",`No cell at row ${e.row}, column ${e.col}.`);if(e.code!==null){const s=Ss(e.code);if(s!==void 0)return A("InvalidArgument",s)}const o=n.mergeAt(e.row,e.col);return o!==void 0&&(o.top!==e.row||o.left!==e.col)?A("MergeOverlap","A code cell cannot sit under a merge."):U},apply:({workbook:t},e)=>Oi(t,e)},et=0,At=1<<30;class Oo{count;defaultSize;#e=new Int32Array(0);#t=0;#s=0;#o=At;#r=null;#i=null;#n=null;constructor(e){if(!Number.isInteger(e.count)||e.count<1||e.count>At-1)throw new Error(`An axis holds 1 to ${At-1} indexes; ${e.count} was asked for.`);if(!(e.defaultSize>0))throw new Error(`An axis's default size must be positive; ${e.defaultSize} was given.`);this.count=e.count,this.defaultSize=e.defaultSize}idAt(e){return this.#y(e),e<this.#t?this.#e[e]:et+this.#s+(e-this.#t)}materialize(e){if(this.#y(e),e>=this.#t){const n=e+1-this.#t;this.#h(e+1);for(let o=0;o<n;o+=1)this.#e[this.#t+o]=et+this.#s+o;this.#s+=n,this.#t=e+1}return this.#e[e]}get materialized(){return this.#t}freshIds(e){const n=new Int32Array(e);for(let o=0;o<e;o+=1)n[o]=this.#o++;return n}#f(e,n){if(e.sizes!==null||e.hidden!==null)return!1;const o=this.#t-n;for(let s=0;s<n;s+=1){const r=this.count-n+s;if(r<o||e.ids[s]!==et+this.#s+(r-o))return!1}return!0}indexOfId(e){for(let n=0;n<this.#t;n+=1)if(this.#e[n]===e)return n;if(e>=et+this.#s&&e<At){const n=this.#t+(e-et-this.#s);return n<this.count?n:-1}return-1}ids(){return this.#e.slice(0,this.#t)}segment(e,n){return this.#b(e,n,!1),{ids:Int32Array.from({length:n},(o,s)=>this.idAt(e+s)),sizes:this.#r===null?null:this.#r.slice(e,e+n),hidden:this.#n===null?null:Uint8Array.from({length:n},(o,s)=>this.isHidden(e+s)?1:0)}}insert(e,n,o){if(this.#b(e,n,!0),o!==void 0&&o.ids.length!==n)throw new Error(`insert: ${n} indexes but a segment of ${o.ids.length}.`);const s=this.segment(this.count-n,n);let r;if(o!==void 0)r=o.ids.slice();else{r=new Int32Array(n);for(let l=0;l<n;l+=1)r[l]=this.#o++}if(e>this.#t&&this.materialize(e-1),this.#h(Math.min(this.#t+n,this.count)),this.#e.copyWithin(e+n,e,Math.min(this.#t,this.count-n)),this.#e.set(r,e),this.#t=Math.min(this.#t+n,this.count),this.#r!==null||o?.sizes!=null||o?.hidden!=null){this.#m();const l=this.#r;if(l.copyWithin(e+n,e,this.count-n),o?.sizes?l.set(o.sizes,e):l.fill(this.defaultSize,e,e+n),(this.#n!==null||o?.hidden)&&(this.#n===null&&(this.#n=new Uint32Array(Math.ceil(this.count/32))),Io(this.#n,this.count,e,n),o?.hidden))for(let a=0;a<n;a+=1)o.hidden[a]&&this.#g(e+a,!0);this.#a(e)}return{inserted:{ids:r,sizes:o?.sizes??null,hidden:o?.hidden??null},dropped:s}}delete(e,n,o){if(this.#b(e,n,!1),o!==void 0&&o.ids.length!==n)throw new Error(`delete: ${n} indexes but a tail of ${o.ids.length}.`);const s=this.segment(e,n);this.materialize(e+n-1);const r=o!==void 0&&!this.#f(o,n);if(r&&this.materialize(this.count-1),this.#e.copyWithin(e,e+n,this.#t),this.#t-=n,r&&(this.#e.set(o.ids,this.count-n),this.#t=this.count),this.#r!==null||o?.sizes!=null||o?.hidden!=null){this.#m();const l=this.#r;if(l.copyWithin(e,e+n,this.count),o?.sizes?l.set(o.sizes,this.count-n):l.fill(this.defaultSize,this.count-n,this.count),(this.#n!==null||o?.hidden)&&(this.#n===null&&(this.#n=new Uint32Array(Math.ceil(this.count/32))),Io(this.#n,this.count,e,-n),o?.hidden))for(let a=0;a<n;a+=1)o.hidden[a]&&this.#g(this.count-n+a,!0);this.#a(e)}return s}move(e,n,o){if(this.#b(e,n,!1),!Number.isInteger(o)||o<0||o>this.count||o>=e&&o<=e+n)throw new Error(`Cannot move ${n} index(es) at ${e} to ${o}.`);const s=Math.min(e,o),r=Math.max(e+n,o);this.materialize(r-1);const i=l=>{const a=l.slice(e,e+n);o<e?(l.copyWithin(o+n,o,e),l.set(a,o)):(l.copyWithin(e,e+n,o),l.set(a,o-n))};if(i(this.#e),this.#r!==null){if(i(this.#r),this.#n!==null){const l=Float64Array.from({length:this.count},(a,c)=>c>=s&&c<r&&this.isHidden(c)?1:0);i(l);for(let a=s;a<r;a+=1)this.#g(a,l[a]===1)}this.#a(s)}}setSegmentSizes(e,n,o,s){if(this.#b(e,s,!1),!(n===null&&o===null&&this.#r===null)){if(this.#m(),n?this.#r.set(n,e):this.#r.fill(this.defaultSize,e,e+s),o||this.#n!==null){this.#n===null&&(this.#n=new Uint32Array(Math.ceil(this.count/32)));for(let r=0;r<s;r+=1)this.#g(e+r,o?o[r]===1:!1)}this.#a(e)}}sizeOf(e){return this.#y(e),this.#r===null?this.defaultSize:this.#r[e]}effectiveSizeOf(e){return this.isHidden(e)?0:this.sizeOf(e)}resize(e,n){if(this.#y(e),!(n>0)||!Number.isFinite(n))throw new Error(`A size must be positive; ${n} was given.`);this.#m();const o=this.effectiveSizeOf(e);this.#r[e]=n;const s=this.effectiveSizeOf(e);s!==o&&this.#u(e,s-o)}get customized(){return this.#r!==null}get hasHidden(){return this.#n!==null&&this.#n.some(e=>e!==0)}isHidden(e){this.#y(e);const n=this.#n;return n!==null&&(n[e>>>5]&1<<(e&31))!==0}setHidden(e,n){if(this.isHidden(e)===n)return;this.#m(),this.#n===null&&(this.#n=new Uint32Array(Math.ceil(this.count/32)));const o=this.#r[e];n?this.#n[e>>>5]|=1<<(e&31):this.#n[e>>>5]&=~(1<<(e&31)),this.#u(e,n?-o:o)}offsetOf(e){if(!Number.isInteger(e)||e<0||e>this.count)throw new Error(`No offset at index ${e} of an axis of ${this.count}.`);if(this.#i===null)return e*this.defaultSize;let n=0;for(let o=e;o>0;o-=o&-o)n+=this.#i[o];return n}get extent(){return this.offsetOf(this.count)}indexAt(e){if(e<=0)return this.#l(0);if(this.#i===null)return Math.min(Math.floor(e/this.defaultSize),this.count-1);const n=this.#i;let o=0,s=e;for(let r=_i(this.count);r>0;r>>=1){const i=o+r;i<=this.count&&n[i]<=s&&(o=i,s-=n[i])}return Math.min(o,this.count-1)}#l(e){let n=e;for(;n<this.count-1&&this.effectiveSizeOf(n)===0;)n+=1;return n}#m(){this.#r===null&&(this.#r=new Float64Array(this.count).fill(this.defaultSize),this.#i=new Float64Array(this.count+1),this.#a(0))}#g(e,n){const o=this.#n;n?o[e>>>5]|=1<<(e&31):o[e>>>5]&=~(1<<(e&31))}#u(e,n){const o=this.#i;for(let s=e+1;s<=this.count;s+=s&-s)o[s]+=n}#a(e){const n=this.#i,o=this.count,s=e+1,r=this.#c(e),i=new Float64Array(o-e+1);i[0]=r;let l=r;for(let a=s;a<=o;a+=1){l+=this.effectiveSizeOf(a-1),i[a-e]=l;const c=a-(a&-a),u=c>=e?i[c-e]:this.#c(c);n[a]=l-u}}#c(e){const n=this.#i;let o=0;for(let s=e;s>0;s-=s&-s)o+=n[s];return o}#h(e){if(e<=this.#e.length)return;let n=Math.max(64,this.#e.length);for(;n<e;)n*=2;const o=new Int32Array(Math.min(n,this.count+1));o.set(this.#e.subarray(0,this.#t)),this.#e=o}#y(e){if(!Number.isInteger(e)||e<0||e>=this.count)throw new Error(`Index ${e} is outside an axis of ${this.count}.`)}#b(e,n,o){if(!Number.isInteger(n)||n<1)throw new Error(`A span needs at least one index; ${n} was given.`);if(!Number.isInteger(e)||e<0||e+n>this.count||o&&e>=this.count)throw new Error(`${n} index(es) at ${e} do not fit an axis of ${this.count}.`)}}function _i(t){let e=1;for(;e*2<=t;)e*=2;return e}function Io(t,e,n,o){const s=i=>(t[i>>>5]&1<<(i&31))!==0,r=(i,l)=>{l?t[i>>>5]|=1<<(i&31):t[i>>>5]&=~(1<<(i&31))};if(o>0){for(let i=e-1;i>=n+o;i-=1)r(i,s(i-o));for(let i=n;i<n+o;i+=1)r(i,!1)}else{const i=-o;for(let l=n;l<e-i;l+=1)r(l,s(l+i));for(let l=e-i;l<e;l+=1)r(l,!1)}}const Y=1024,Z=10,tt=Y-1;class zi{source;cached;parsed;constructor(e,n,o=void 0){this.source=e,this.cached=n,this.parsed=o}}class Li{#e=[];#t=[];add(e){const n=this.#t.pop()??this.#e.length;return this.#e[n]=e,n}get(e){const n=this.#e[e];if(n===void 0)throw new Error(`No formula at ${e} in the formula table.`);return n}remove(e){this.get(e),this.#e[e]=void 0,this.#t.push(e)}get size(){return this.#e.length-this.#t.length}forEach(e){for(const n of this.#e)n!==void 0&&e(n)}}function kt(t,e){const n=new Array(e-t+1);for(let o=t;o<=e;o+=1)n[o-t]=o;return n}class Ui{kind=new Uint8Array(Y);num=new Float64Array(Y);ref=new Uint32Array(Y);style=new Uint16Array(Y);filled=0}class Di{chunks=new Map}class Fi{#e;#t=new Map;#s=0;constructor(e){this.#e=e}get filled(){return this.#s}get chunkCount(){let e=0;for(const n of this.#t.values())e+=n.chunks.size;return e}columnIndexes(){return this.#t.keys()}get(e,n){const o=this.#t.get(n)?.chunks.get(e>>>Z);if(o===void 0)return null;const s=e&tt;return o.kind[s]===0&&o.style[s]===0?null:this.#o(o,s)}styleAt(e,n){const o=this.#t.get(n)?.chunks.get(e>>>Z);return o===void 0?0:o.style[e&tt]}formulaAt(e,n){const o=this.#t.get(n)?.chunks.get(e>>>Z);if(o===void 0)return;const s=e&tt;return o.kind[s]===5?this.#e.formulas.get(o.ref[s]):void 0}numberAt(e,n){const o=this.#t.get(n)?.chunks.get(e>>>Z);if(o===void 0)return;const s=e&tt;return o.kind[s]===1?o.num[s]:void 0}set(e,n,o){let s=this.#t.get(n);const r=e>>>Z;let i=s?.chunks.get(r);const l=e&tt;if(i!==void 0&&this.#i(i,l),o===null||o.value===null&&o.formula===void 0&&o.style===0){i!==void 0&&i.filled===0&&(s.chunks.delete(r),s.chunks.size===0&&this.#t.delete(n));return}s===void 0&&(s=new Di,this.#t.set(n,s)),i===void 0&&(i=new Ui,s.chunks.set(r,i)),this.#r(i,l,o)}*entries(e){const n=e!==void 0&&e.right-e.left<this.#t.size?kt(e.left,e.right):[...this.#t.keys()].sort((o,s)=>o-s);for(const o of n){if(e&&(o<e.left||o>e.right))continue;const s=this.#t.get(o);if(s===void 0)continue;const r=e===void 0?0:e.top>>>Z,i=e===void 0?1/0:e.bottom>>>Z,l=i-r<s.chunks.size?kt(r,i):[...s.chunks.keys()].sort((a,c)=>a-c);for(const a of l){const c=a<<Z;if(e&&(c+Y-1<e.top||c>e.bottom))continue;const u=s.chunks.get(a);if(u===void 0)continue;const h=e?Math.max(0,e.top-c):0,d=e?Math.min(Y-1,e.bottom-c):Y-1;for(let f=h;f<=d;f+=1)u.kind[f]===0&&u.style[f]===0||(yield[c+f,o,this.#o(u,f)])}}}scan(e,n){const o=e.right-e.left<this.#t.size?kt(e.left,e.right):[...this.#t.keys()].sort((r,i)=>r-i),s=this.#e.strings;for(const r of o){if(r<e.left||r>e.right)continue;const i=this.#t.get(r);if(i===void 0)continue;const l=e.top>>>Z,a=e.bottom>>>Z,c=a-l<i.chunks.size?kt(l,a):[...i.chunks.keys()].sort((u,h)=>u-h);for(const u of c){const h=u<<Z;if(h+Y-1<e.top||h>e.bottom)continue;const d=i.chunks.get(u);if(d===void 0)continue;const f=Math.max(0,e.top-h),m=Math.min(Y-1,e.bottom-h),{kind:p,num:g,ref:y}=d;for(let E=f;E<=m;E+=1)switch(p[E]){case 0:break;case 1:n(h+E,r,g[E],!1);break;case 3:n(h+E,r,g[E]!==0,!1);break;case 2:n(h+E,r,s.get(y[E]),!1);break;case 4:{const T=s.get(y[E]);if(!dt(T))throw new Error(`The store holds '${T}' as an error.`);n(h+E,r,ae(T),!1);break}case 5:n(h+E,r,null,!0);break}}}}lastRowIn(e){const n=this.#t.get(e);if(n===void 0)return-1;const o=Math.max(...n.chunks.keys()),s=n.chunks.get(o);for(let r=Y-1;r>=0;r-=1)if(s.kind[r]!==0||s.style[r]!==0)return(o<<Z)+r;throw new Error("A kept chunk holds nothing: the store is inconsistent.")}isEmpty(e){for(const n of this.entries(e))return!1;return!0}shiftRows(e,n,o){for(const[s,r]of[...this.#t]){const i=[];for(const[l,a]of[...r.chunks]){const c=l<<Z;if(!(c+Y-1<e))for(let u=0;u<Y;u+=1){const h=c+u;if(h<e||a.kind[u]===0&&a.style[u]===0)continue;const d=this.#o(a,u);if(this.set(h,s,null),n<0&&h<e-n)continue;const f=h+n;f<o&&i.push([f,d])}}for(const[l,a]of i)this.set(l,s,a)}}shiftCols(e,n,o){const s=[...this.#t.keys()].filter(r=>r>=e).sort((r,i)=>n>0?i-r:r-i);for(const r of s){const i=this.#t.get(r);if(this.#t.delete(r),n<0&&r<e-n){for(const[a,c]of i.chunks)for(let u=0;u<Y;u+=1)this.#i(c,u);continue}const l=r+n;if(l<o)this.#t.set(l,i);else for(const a of i.chunks.values())for(let c=0;c<Y;c+=1)this.#i(a,c)}}#o(e,n){const o=e.style[n];switch(e.kind[n]){case 0:return{value:null,style:o};case 1:return{value:e.num[n],style:o};case 3:return{value:e.num[n]!==0,style:o};case 2:return{value:this.#e.strings.get(e.ref[n]),style:o};case 4:{const s=this.#e.strings.get(e.ref[n]);if(!dt(s))throw new Error(`The store holds '${s}' as an error.`);return{value:ae(s),style:o}}case 5:{const s=this.#e.formulas.get(e.ref[n]);return{value:s.cached,formula:s.source,style:o}}}}#r(e,n,o){const{value:s,formula:r,style:i}=o;if(!Number.isInteger(i)||i<0||i>65535)throw new Error(`No style index ${i}.`);if(e.style[n]=i,r!==void 0)e.kind[n]=5,e.ref[n]=this.#e.formulas.add(new zi(r,s));else if(s===null)e.kind[n]=0;else if(typeof s=="number"){if(!Number.isFinite(s))throw new Error(`A cell cannot hold ${s}; use an error value.`);e.kind[n]=1,e.num[n]=s}else if(typeof s=="boolean")e.kind[n]=3,e.num[n]=s?1:0;else if(typeof s=="string")e.kind[n]=2,e.ref[n]=this.#e.strings.intern(s);else if($(s))e.kind[n]=4,e.ref[n]=this.#e.strings.intern(s.error);else throw new Error(`A cell cannot hold ${JSON.stringify(s)}.`);e.filled+=1,this.#s+=1}#i(e,n){const o=e.kind[n];o===0&&e.style[n]===0||(o===2||o===4?this.#e.strings.release(e.ref[n]):o===5&&this.#e.formulas.remove(e.ref[n]),e.kind[n]=0,e.num[n]=0,e.ref[n]=0,e.style[n]=0,e.filled-=1,this.#s-=1)}}class Pi{#e=[];#t=new Int32Array(64);#s=new Map;#o=[];intern(e){let n=this.#s.get(e);if(n===void 0&&(n=this.#o.pop()??this.#e.length,this.#e[n]=e,this.#s.set(e,n),n>=this.#t.length)){const o=new Int32Array(this.#t.length*2);o.set(this.#t),this.#t=o}return this.#t[n]+=1,n}release(e){const n=this.#e[e];if(n===void 0||this.#t[e]<=0)throw new Error(`The string pool holds nothing at ${e}: released twice?`);this.#t[e]-=1,this.#t[e]===0&&(this.#e[e]=void 0,this.#s.delete(n),this.#o.push(e))}get(e){const n=this.#e[e];if(n===void 0)throw new Error(`The string pool holds nothing at ${e}.`);return n}get size(){return this.#s.size}references(e){return this.#t[e]??0}}const Gn={rows:1048576,cols:16384,rowHeight:21,colWidth:100};class Bi{id;name;rows;cols;cells;merges=[];frozen={rows:0,cols:0};charts=new Map;code=new Map;dataSource=null;constructor(e,n,o,s){this.id=e,this.name=n,this.rows=new Oo({count:o.rows,defaultSize:o.rowHeight}),this.cols=new Oo({count:o.cols,defaultSize:o.colWidth}),this.cells=s}mergeAt(e,n){return this.merges.find(o=>e>=o.top&&e<=o.bottom&&n>=o.left&&n<=o.right)}mergesIn(e){return this.merges.filter(n=>Te(n,e))}}class ji{limits;sheetIdPrefix="s";strings=new Pi;styles=new br;formulas=new Li;sheets=[];#e=1;constructor(e=Gn){for(const[n,o]of Object.entries(e))if(!(typeof o=="number"&&o>0))throw new Error(`limits.${n} must be positive; ${o} was given.`);this.limits=e}createSheet(e,n){const o=n??this.#t();if(this.sheets.some(s=>s.id===o))throw new Error(`A sheet with id '${o}' exists already.`);return new Bi(o,e,this.limits,new Fi({strings:this.strings,formulas:this.formulas}))}sheet(e){const n=this.sheets.find(o=>o.id===e);if(n===void 0)throw new Error(`No sheet '${e}'; the workbook has ${this.sheets.map(o=>o.id).join(", ")||"none"}.`);return n}hasSheet(e){return this.sheets.some(n=>n.id===e)}sheetByName(e){const n=e.toLowerCase();return this.sheets.find(o=>o.name.toLowerCase()===n)}freshSheetName(){for(let e=1;;e+=1)if(this.sheetByName(`Sheet${e}`)===void 0)return`Sheet${e}`}#t(){for(;;){const e=`${this.sheetIdPrefix}${this.#e++}`;if(!this.hasSheet(e))return e}}}class _e{#e;#t;#s;#o=-1;#r=new Map;#i=[];constructor(e,n,o){this.#e=e,this.#t=n,this.#s=o}get(e){return this.#n(),this.#r.get(e)}all(){return this.#n(),this.#i}keys(){return this.#n(),this.#r.keys()}get revision(){return this.#n(),this.#o}#n(){const e=this.#e.getRevision();if(e===this.#o)return;const n=this.#e.getContributions(this.#t),o=new Map,s=[];for(const r of n){const i=Hi(r,this.#s),l=this.#s.key(r.value),a=o.get(l);if(a!==void 0)throw new Error(`The ${this.#s.label} '${l}' is contributed twice to ${this.#t.id}: by ${a.plugin} (id '${a.id}') and by ${r.plugin} (id '${r.id}'). Disable one of the two plugins, or rename one ${this.#s.label}.`);o.set(l,i),s.push(i)}this.#o=e,this.#r=o,this.#i=s}}function Hi(t,e){if(e.check)try{e.check(t.value)}catch(n){throw new Error(`${t.plugin} contributes a malformed ${e.label} (id '${t.id}'): ${n.message}`)}return{value:t.value,plugin:t.plugin,id:t.id}}function Yi(t,e,n){const o=t.getContributions(e),[s,r]=o;if(s!==void 0){if(r!==void 0&&r.order===s.order)throw new Error(`Two plugins contribute a ${n} (${e.id}) at the same order ${s.order}: ${s.plugin} (id '${s.id}') and ${r.plugin} (id '${r.id}'). Give one a lower order, or disable one.`);return{value:s.value,plugin:s.plugin,id:s.id}}}const Kn=P("datalayer.cells.patchOp"),Ge=P("datalayer.cells.command"),Zn=P("datalayer.cells.function"),Jn=P("datalayer.cells.cellType"),Ms=P("datalayer.cells.renderLayer"),Ce=P("datalayer.cells.clipboard"),qn=P("datalayer.cells.fillRule"),Xi=P("datalayer.cells.importer"),Ts=P("datalayer.cells.exporter"),Wt=P("datalayer.cells.dataSource"),Vi=P("datalayer.cells.collabProvider"),Cs=P("datalayer.cells.codeRenderer"),Ns=P("datalayer.cells.kernel"),Gt=P("datalayer.cells.toolbarItem"),Ee=P("datalayer.cells.menuItem"),Wi=P("datalayer.cells.chartType"),Gi=P("datalayer.cells.chartOption"),Ki=P("datalayer.cells.chartRenderer"),Rs=Gs("datalayer.cells.gate.edit"),Zi=[Kn,Ge,Zn,Jn,Ms,Ce,qn,Xi,Ts,Wt,Vi,Gt,Ee,Wi,Gi,Ki,Rs,Ns,Cs],ee=1024,Ji=256;function ht(t){return{top:t.at.row,left:t.at.col,bottom:t.at.row+t.rows-1,right:t.at.col+t.cols-1}}const qi={op:"dataSource",apply(t,e){t.sheet(e.sheet).dataSource=e.after===null?null:{...e.after,at:{...e.after.at}}},invert:t=>({...t,before:t.after,after:t.before}),example:()=>({op:"dataSource",sheet:"s1",before:null,after:{id:"example",at:{row:1,col:1},rows:10,cols:2}})},Qi={type:"BIND_DATA_SOURCE",allow(t,e){const{workbook:n}=t;if(!n.hasSheet(e.sheet))return A("UnknownSheet",`No sheet '${e.sheet}'.`);const o=n.sheet(e.sheet);if(e.source===null)return o.dataSource===null?A("InvalidArgument",`Sheet '${o.name}' is bound to no data source.`):{ok:!0};if(typeof e.source!="string"||e.source==="")return A("InvalidArgument","BIND_DATA_SOURCE names a data source by id, or null.");const s=t.contributions(Wt).find(u=>u.id===e.source);if(s===void 0)return A("UnknownDataSource",`No plugin contributes the data source '${e.source}'.`);const r=e.at??{row:0,col:0},i=u=>Number.isInteger(u)&&u>=0;if(!i(r.row)||!i(r.col))return A("InvalidArgument","BIND_DATA_SOURCE lands at a cell: { row, col }.");if(o.dataSource!==null)return A("InvalidArgument",`Sheet '${o.name}' is bound to the data source '${o.dataSource.id}' already; unbind it first.`);const l=s.rowCount,a=s.columns.length;if(l<1||a<1)return A("InvalidArgument",`The data source '${s.id}' has no rows or no columns.`);if(r.row+l>o.rows.count||r.col+a>o.cols.count)return A("OutOfBounds",`The data source '${s.id}' has ${l.toLocaleString("en-US")} rows and ${a} columns: from ${He({top:r.row,left:r.col,bottom:r.row,right:r.col})} it reaches past the sheet's ${o.rows.count.toLocaleString("en-US")} rows and ${o.cols.count.toLocaleString("en-US")} columns.`);const c=ht({id:s.id,at:r,rows:l,cols:a});return o.cells.isEmpty(c)?o.mergesIn(c).length>0?A("MergeOverlap",`${He(c)} holds merges; a data source lands on plain cells.`):{ok:!0}:A("InvalidArgument",`${He(c)} holds cells; a data source lands on empty cells.`)},apply(t,e){const n=t.workbook.sheet(e.sheet),o=n.dataSource;if(e.source===null)return[{op:"dataSource",sheet:n.id,before:o,after:null}];const s=t.contributions(Wt).find(i=>i.id===e.source),r={id:s.id,at:e.at??{row:0,col:0},rows:s.rowCount,cols:s.columns.length};return[{op:"dataSource",sheet:n.id,before:o,after:r}]}};class el{#e;#t;#s;#o;#r;#i=new Map;#n=new Map;stats={resident:0,loading:0,failed:0,fetches:0,evictions:0};constructor(e,n,o){if(this.#e=e,this.#t=n,this.#s=o.pages??Ji,!(Number.isInteger(this.#s)&&this.#s>=1))throw new Error(`dataSources.pages is a positive integer; ${String(o.pages)} was given.`);this.#o=o.onWritten,this.#r=o.onError}get capacity(){return this.#s}resolve(e){if(!this.#e.hasSheet(e))return;const n=this.#e.sheet(e).dataSource;if(n===null)return;const o=this.#t.revision,s=this.#n.get(e);return s!==void 0&&s.revision===o&&s.binding===n?s.out:this.#f(e,n,o,s)}#f(e,n,o,s){const r=ht(n),i=this.#t.get(n.id);let l;return i===void 0?l={binding:n,zone:r,problem:`No plugin contributes the data source '${n.id}'.`}:i.value.rowCount!==n.rows||i.value.columns.length!==n.cols?l={binding:n,zone:r,problem:`The data source '${n.id}' has ${i.value.rowCount.toLocaleString("en-US")} rows and ${i.value.columns.length} columns; the sheet binds ${n.rows.toLocaleString("en-US")} rows and ${n.cols} columns. Bind it again.`}:l={binding:n,zone:r,source:i},this.#n.set(e,{revision:o,binding:n,out:l}),s!==void 0&&s.binding===n&&s.out.source!==l.source&&this.forget(e),l}zoneOf(e){return this.resolve(e)?.zone}missing(e,n,o){const s=e.dataSource;if(s===null||n<s.at.row||n>=s.at.row+s.rows||o<s.at.col||o>=s.at.col+s.cols)return;const r=this.resolve(e.id);if(r.source===void 0)return ae("#N/A",r.problem);const i=Math.floor((n-r.zone.top)/ee),l=this.#m(e.id,i,r);if(l.state!=="resident")return this.#l(l,r)}ensureZone(e,n){const o=this.resolve(e);if(o===void 0||!Te(o.zone,n))return;if(o.source===void 0)return ae("#N/A",o.problem);const s=Math.max(n.top,o.zone.top),r=Math.min(n.bottom,o.zone.bottom),i=Math.floor((s-o.zone.top)/ee),l=Math.floor((r-o.zone.top)/ee),a=l-i+1;if(a>this.#s)return ae("#N/A",`Reading ${He(n)} needs ${a.toLocaleString("en-US")} pages of the data source '${o.binding.id}'; ${this.#s} stay resident. Read a smaller range.`);let c;for(let u=i;u<=l;u+=1){const h=this.#m(e,u,o);h.state!=="resident"&&c===void 0&&(c=this.#l(h,o))}return c}forget(e){for(const[n,o]of[...this.#i])o.sheet===e&&this.#c(n,o,!0)}forgetAll(){this.#i.clear(),this.#n.clear(),this.stats.resident=0,this.stats.loading=0,this.stats.failed=0}willApply(e){if(e.op!=="dataSource")return;const{sheet:n,before:o,after:s}=e;o!==null&&(s===null||s.id!==o.id||s.rows!==o.rows||s.cols!==o.cols)&&this.forget(n)}refuses(e){const n=[...e.filter(o=>o.op.startsWith("axis-")),...e.filter(o=>!o.op.startsWith("axis-"))];for(const o of n){const s=o.sheet;if(typeof s!="string"||!this.#e.hasSheet(s))continue;const r=this.#e.sheet(s).dataSource;if(r===null)continue;const i=ht(r),l=a=>A("ReadOnly",`${He(i)} shows the data source '${r.id}' and cannot be changed${a}.`);if(o.op==="cells"){if(Te(o.zone,i))return l("")}else if(o.op==="merges"){if(o.after.some(c=>Te(c,i)))return l(": no merge over it")}else if(o.op==="axis-insert"||o.op==="axis-delete"||o.op==="axis-move"){const a=o,c=a.axis==="rows"?i.top:i.left,u=a.axis==="rows"?i.bottom:i.right,h=f=>f>c&&f<=u,d=a.at<=u&&a.at+a.n-1>=c;if(o.op==="axis-insert"&&h(a.at))return l(`: no ${a.axis} inserted inside it`);if(o.op==="axis-delete"&&d)return l(`: no ${a.axis} deleted from it`);if(o.op==="axis-move"&&(d||h(a.to)))return l(`: no ${a.axis} moved into or out of it`)}}}#l(e,n){return e.state==="failed"?ae("#N/A",`The data source '${n.binding.id}' failed for rows ${(e.index*ee+1).toLocaleString("en-US")}–${Math.min((e.index+1)*ee,n.binding.rows).toLocaleString("en-US")}: ${e.error}`):ae("#BUSY!",`The data source '${n.binding.id}' is reading rows ${(e.index*ee+1).toLocaleString("en-US")}–${Math.min((e.index+1)*ee,n.binding.rows).toLocaleString("en-US")}.`)}#m(e,n,o){const s=`${e}:${n}`,r=this.#i.get(s);if(r!==void 0)return this.#i.delete(s),this.#i.set(s,r),r;const i={sheet:e,index:n,state:"loading"};this.#i.set(s,i),this.stats.loading+=1,this.stats.fetches+=1;const l=n*ee,a=Math.min(l+ee-1,o.binding.rows-1),c=o.source.value,u=(h,d)=>{if(!(this.#i.get(s)!==i||i.state!=="loading")){if(this.stats.loading-=1,d===void 0&&h!==void 0&&(Array.isArray(h)&&h.length===o.binding.cols?h.find(m=>!Array.isArray(m)||m.length!==a-l+1):h)!==void 0&&(d=new Error(`the data source '${c.id}' answered ${Array.isArray(h)?h.length:"no"} columns for rows ${l+1}–${a+1}, not ${o.binding.cols} columns of ${a-l+1} rows.`)),d!==void 0){i.state="failed",i.error=d.message,this.stats.failed+=1,this.#r({sheet:e,source:c.id,rows:{from:l,to:a},error:d}),this.#o(e,this.#g(o,n));return}this.#a(i),i.state="resident",this.stats.resident+=1,this.#u(e,o,n,h,l,a),this.#o(e,this.#g(o,n))}};try{Promise.resolve(c.fetch({from:l,to:a})).then(h=>u(h,void 0),h=>u(void 0,h instanceof Error?h:new Error(String(h))))}catch(h){u(void 0,h instanceof Error?h:new Error(String(h)))}return i}#g(e,n){const o=e.zone;return{top:o.top+n*ee,left:o.left,bottom:Math.min(o.top+(n+1)*ee-1,o.bottom),right:o.right}}#u(e,n,o,s,r,i){const l=this.#e.sheet(e).cells,a=n.zone;for(let c=0;c<s.length;c+=1){const u=a.left+c,h=s[c];for(let d=0;d<=i-r;d+=1){const f=h[d],m=a.top+r+d;f!=null&&l.set(m,u,{value:f,style:l.styleAt(m,u)})}}}#a(e){for(;this.stats.resident>=this.#s;){let n;for(const o of this.#i)if(o[1].state==="resident"&&o[1]!==e){n=o;break}if(n===void 0)return;this.#c(n[0],n[1],!0),this.stats.evictions+=1}}#c(e,n,o){if(this.#i.delete(e),n.state==="resident"?this.stats.resident-=1:n.state==="loading"?this.stats.loading-=1:this.stats.failed-=1,n.state!=="resident"||!o)return;const s=this.#e.sheet(n.sheet).dataSource;if(s===null)return;const r=this.#g({binding:s,zone:ht(s)},n.index),i=this.#e.sheet(n.sheet).cells;for(const[l,a]of[...i.entries(r)])i.set(l,a,null);this.#o(n.sheet,r)}}function tl(t){return t.dataSource===null?void 0:ht(t.dataSource)}const In=1;class Os extends Error{}function S(t,e){throw new Os(`${t}: ${e}`)}const H=t=>typeof t=="object"&&t!==null&&!Array.isArray(t),dn=(t,e)=>/^(0|[1-9][0-9]*)$/.test(t)&&Number(t)<e;function nl(t,e){if(!(t===null||typeof t=="string"||typeof t=="boolean")){if(typeof t=="number"){Number.isFinite(t)||S(e(),`${t} is not a value`);return}if(H(t)&&typeof t.error=="string"&&Object.keys(t).length===1){dt(t.error)||S(e(),`'${t.error}' is not an error code`);return}S(e(),`${JSON.stringify(t)} is not a value (a number, a string, a boolean, null or { error })`)}}function ol(t,e,n){H(t)||S(e,"a zone is { top, left, bottom, right }");for(const l of["top","left","bottom","right"])(!Number.isInteger(t[l])||t[l]<0)&&S(`${e}.${l}`,"a non-negative integer");const{top:o,left:s,bottom:r,right:i}=t;(o>r||s>i)&&S(e,"top-left after bottom-right"),(r>=n.rows||i>=n.cols)&&S(e,"outside the sheet")}function Is(t,e=Gn){H(t)||S("workbook","a CellsWorkbook is a JSON object"),t.version!==In&&S("version",`this is format version ${JSON.stringify(t.version)}; Cells reads version ${In}`);const n=t.styles??[];Array.isArray(n)||S("styles","a list"),n.forEach((r,i)=>Hn(r,`styles[${i}]`)),n.length>0&&Object.keys(n[0]).length>0&&S("styles[0]","style 0 is the default: {}"),(!Array.isArray(t.sheets)||t.sheets.length===0)&&S("sheets","a non-empty list");const o=new Set,s=new Set;return t.sheets.forEach((r,i)=>{const l=`sheets[${i}]`;H(r)||S(l,"a sheet is an object"),(typeof r.id!="string"||r.id==="")&&S(`${l}.id`,"a non-empty string"),o.has(r.id)&&S(`${l}.id`,`'${r.id}' is used twice`),o.add(r.id),(typeof r.name!="string"||r.name.trim()==="")&&S(`${l}.name`,"a non-empty string"),s.has(r.name.toLowerCase())&&S(`${l}.name`,`'${r.name}' is used twice`),s.add(r.name.toLowerCase()),H(r.rows)||S(`${l}.rows`,"an object keyed by row index");for(const a in r.rows){const c=r.rows[a],u=()=>`${l}.rows["${a}"]`;dn(a,e.rows)||S(u(),`'${a}' is not a row index below ${e.rows}`),(!H(c)||!H(c.cells))&&S(u(),"a row is { cells: { … } }");const h=c.cells;for(const d in h){const f=h[d],m=()=>`${u()}.cells["${d}"]`;dn(d,e.cols)||S(m(),`'${d}' is not a column index below ${e.cols}`),H(f)||S(m(),"a cell is { v?, f?, s? }");for(const p in f)p!=="v"&&p!=="f"&&p!=="s"&&S(`${m()}.${p}`,"a cell has v, f and s only");"v"in f&&nl(f.v,()=>`${m()}.v`),"f"in f&&(typeof f.f!="string"||f.f==="")&&S(`${m()}.f`,"a formula without the ="),"s"in f&&(!Number.isInteger(f.s)||f.s<0||f.s>=Math.max(1,n.length))&&S(`${m()}.s`,`no style ${JSON.stringify(f.s)}`)}}if(r.sizes!==void 0){H(r.sizes)||S(`${l}.sizes`,"{ rows?, cols? }");for(const a of["rows","cols"]){const c=r.sizes[a];if(c!==void 0){H(c)||S(`${l}.sizes.${a}`,"an object keyed by index");for(const[u,h]of Object.entries(c))dn(u,e[a])||S(`${l}.sizes.${a}["${u}"]`,"not an index of the sheet"),typeof h=="number"&&h>0&&Number.isFinite(h)||S(`${l}.sizes.${a}["${u}"]`,"a positive size")}}}if(r.hidden!==void 0){H(r.hidden)||S(`${l}.hidden`,"{ rows?, cols? }");for(const a of["rows","cols"]){const c=r.hidden[a];c!==void 0&&(Array.isArray(c)||S(`${l}.hidden.${a}`,"a list of indexes"),c.forEach((u,h)=>{(!Number.isInteger(u)||u<0||u>=e[a])&&S(`${l}.hidden.${a}[${h}]`,"not an index of the sheet")}))}}if(r.merges!==void 0&&(Array.isArray(r.merges)||S(`${l}.merges`,"a list of zones"),r.merges.forEach((a,c)=>ol(a,`${l}.merges[${c}]`,e))),r.charts!==void 0){H(r.charts)||S(`${l}.charts`,"an object of charts by id");for(const[a,c]of Object.entries(r.charts)){const u=`${l}.charts["${a}"]`,h=ms(c,u,e);h.id!==a&&S(`${u}.id`,`the chart is filed under '${a}' and says '${h.id}'`)}}if(r.code!==void 0){H(r.code)||S(`${l}.code`,"an object of code cells by cell (B4)");for(const[a,c]of Object.entries(r.code)){const u=`${l}.code["${a}"]`,h=/^([A-Z]{1,3})([1-9][0-9]*)$/.exec(a);let d=-1;if(h!==null)for(const m of h[1])d=(d+1)*26+m.charCodeAt(0)-65;(h===null||Number(h[2])>e.rows||d>=e.cols)&&S(u,`'${a}' is not a cell of the sheet`);const f=Ss(c,u);if(f!==void 0)throw new Os(f)}}if(r.dataSource!==void 0){const a=r.dataSource,c=`${l}.dataSource`;H(a)||S(c,"{ id, row, col, rows, cols }"),(typeof a.id!="string"||a.id==="")&&S(`${c}.id`,"the id of a data source");for(const u of["row","col","rows","cols"])(!Number.isInteger(a[u])||a[u]<0)&&S(`${c}.${u}`,"a non-negative integer");for(const u of["rows","cols"])a[u]<1&&S(`${c}.${u}`,"at least 1");(a.row+a.rows>e.rows||a.col+a.cols>e.cols)&&S(c,"reaches outside the sheet")}if(r.frozen!==void 0){const a=r.frozen;(!H(a)||!Number.isInteger(a.rows)||!Number.isInteger(a.cols)||a.rows<0||a.cols<0)&&S(`${l}.frozen`,"{ rows, cols }, non-negative integers")}}),t}const _o=t=>t==null?null:typeof t=="object"?ae(t.error):t,sl=t=>$(t)?{error:t.error}:t;function zo(t,e){if(t.sheets.length>0)throw new Error("loadInto fills an empty workbook.");const n=Is(e,t.limits),o=(n.styles??[]).map(s=>t.styles.intern(s));for(const s of n.sheets){const r=t.createSheet(s.name,s.id);for(const i in s.rows){const l=Number(i),a=s.rows[i].cells;for(const c in a){const u=a[c],h=u.s===void 0?0:o[u.s]??0,d=u.f===void 0?{value:_o(u.v),style:h}:{value:_o(u.v),formula:u.f,style:h};r.cells.set(l,Number(c),d)}}for(const i of["rows","cols"]){const l=i==="rows"?r.rows:r.cols;for(const[a,c]of Object.entries(s.sizes?.[i]??{}))l.resize(Number(a),c);for(const a of s.hidden?.[i]??[])l.setHidden(a,!0)}r.merges=(s.merges??[]).map(i=>({...i}));for(const[i,l]of Object.entries(s.charts??{}))r.charts.set(i,l);for(const[i,l]of Object.entries(s.code??{})){const a=/^([A-Z]+)([0-9]+)$/.exec(i);let c=-1;for(const u of a[1])c=(c+1)*26+u.charCodeAt(0)-65;r.code.set(we(r,Number(a[2])-1,c),l)}r.frozen=s.frozen?{rows:s.frozen.rows,cols:s.frozen.cols}:{rows:0,cols:0},r.dataSource=s.dataSource?{id:s.dataSource.id,at:{row:s.dataSource.row,col:s.dataSource.col},rows:s.dataSource.rows,cols:s.dataSource.cols}:null,t.sheets.push(r)}}function rl(t){const e=new Map([[0,0]]),n=[{}],o=r=>{let i=e.get(r);return i===void 0&&(i=n.length,n.push(t.styles.get(r)),e.set(r,i)),i},s=t.sheets.map(r=>{const i={},l=tl(r),a=[...r.cells.entries()].filter(([f,m])=>l===void 0||!en(l,{row:f,col:m})).sort((f,m)=>f[0]-m[0]||f[1]-m[1]);for(const[f,m,p]of a){const g={};p.value!==null&&(g.v=sl(p.value)),p.formula!==void 0&&(g.f=p.formula),p.style!==0&&(g.s=o(p.style)),(i[f]??={cells:{}}).cells[m]=g}const c={id:r.id,name:r.name,rows:i},u={},h={};for(const f of["rows","cols"]){const m=f==="rows"?r.rows:r.cols,p=il(m);Object.keys(p.sizes).length>0&&(u[f]=p.sizes),p.hidden.length>0&&(h[f]=p.hidden)}Object.keys(u).length>0&&(c.sizes=u),Object.keys(h).length>0&&(c.hidden=h),r.merges.length>0&&(c.merges=r.merges.map(f=>({...f}))),(r.frozen.rows>0||r.frozen.cols>0)&&(c.frozen={...r.frozen}),r.charts.size>0&&(c.charts=Object.fromEntries(r.charts));const d={};for(const[f,m]of r.code){const p=vs(r,f);p!==void 0&&(d[Wn(p.row,p.col)]=m)}return Object.keys(d).length>0&&(c.code=Object.fromEntries(Object.entries(d).sort(([f],[m])=>f.localeCompare(m)))),r.dataSource!==null&&(c.dataSource={id:r.dataSource.id,row:r.dataSource.at.row,col:r.dataSource.at.col,rows:r.dataSource.rows,cols:r.dataSource.cols}),c});return{version:In,sheets:s,styles:n}}function il(t){const e={},n=[];if(!t.customized)return{sizes:e,hidden:n};for(let o=0;o<t.count;o+=1){const s=t.sizeOf(o);s!==t.defaultSize&&(e[o]=s),t.isHidden(o)&&n.push(o)}return{sizes:e,hidden:n}}const _s={steps:500,bytes:64*1024*1024};class ll{limits;#e=[];#t=[];#s=0;constructor(e=_s){if(!(e.steps>=1)||!(e.bytes>=1))throw new Error("History limits must be positive.");this.limits=e}push(e){this.#e.push(e),this.#s+=e.bytes;for(const n of this.#t)this.#s-=n.bytes;for(this.#t=[];this.#e.length>this.limits.steps||this.#s>this.limits.bytes&&this.#e.length>1;)this.#s-=this.#e.shift().bytes}popUndo(){const e=this.#e.pop();return e&&this.#t.push(e),e}popRedo(){const e=this.#t.pop();return e&&this.#e.push(e),e}get canUndo(){return this.#e.length>0}get canRedo(){return this.#t.length>0}get size(){return{steps:this.#e.length,bytes:this.#s}}get undoLabel(){return this.#e.at(-1)?.label}get redoLabel(){return this.#t.at(-1)?.label}clear(){this.#e=[],this.#t=[],this.#s=0}}const Kt=1;function zs(t,e={}){return e.transpose?{rows:t.cols,cols:t.rows}:{rows:t.rows,cols:t.cols}}function al(t){const e=t;if(typeof t!="object"||t===null)throw new Error("A clipboard slice is an object.");if(e.version!==Kt)throw new Error(`This clipboard slice is version ${String(e.version)}; Cells reads version ${Kt}.`);if(!Number.isInteger(e.rows)||!Number.isInteger(e.cols)||e.rows<1||e.cols<1)throw new Error("A clipboard slice has a size of at least one cell.");if(typeof e.parts!="object"||e.parts===null)throw new Error("A clipboard slice has parts.")}function cl(t,e,n){const{workbook:o}=t,s=o.sheet(e),r=[];for(const[i,l,a]of s.cells.entries(n)){const c=a.style===0?void 0:o.styles.get(a.style),u=a.formula===void 0?a.value:t.value(e,i,l);r.push({r:i-n.top,c:l-n.left,...u!==null?{v:u}:{},...a.formula!==void 0?{f:a.formula}:{},...c?{style:c}:{}})}return r}function ul(t,e,n,o,s,r){const i=t.workbook,l=i.sheet(e),a={rows:l.rows.count,cols:l.cols.count},c=s.special??"all",u=[],h=new Set;for(const d of n){const[f,m]=s.transpose?[d.c,d.r]:[d.r,d.c],p=o.top+f,g=o.left+m,y=l.cells.get(p,g);h.add(`${p},${g}`);const E=c==="values"||c==="formulas"?y?.style??0:d.style?i.styles.intern(d.style):0;if(c==="formats")u.push([p,g,y===null?{value:null,style:E}:{...y,style:E}]);else if(c==="values"||d.f===void 0)u.push([p,g,{value:d.v??null,style:E}]);else{const T=r&&{row:r.zone.top+d.r,col:r.zone.left+d.c},x=r===void 0||r.cut?d.f:s.transpose?Xr(d.f,T,{row:p,col:g},a):Yn(d.f,p-T.row,g-T.col,a);u.push([p,g,{value:null,formula:x,style:E}])}}for(const[d,f,m]of l.cells.entries(o))h.has(`${d},${f}`)||(c==="all"?u.push([d,f,null]):c==="values"||c==="formulas"?u.push([d,f,{value:null,style:m.style}]):u.push([d,f,{...m,style:0}]));return qe(l,o,u)}function Ls(t,e){return{top:t.row,left:t.col,bottom:t.row+e.rows-1,right:t.col+e.cols-1}}function hl(t,e){if(!t.workbook.hasSheet(e.sheet))return A("UnknownSheet",`No sheet '${e.sheet}'.`);try{al(e.slice)}catch(s){return A("InvalidArgument",s.message)}const n=t.workbook.sheet(e.sheet),o=Ls(e.at,zs(e.slice,e.options));if(o.top<0||o.left<0||o.bottom>=n.rows.count||o.right>=n.cols.count)return A("OutOfBounds",`The paste of ${o.bottom-o.top+1} × ${o.right-o.left+1} cells reaches past the end of the sheet.`);for(const s of n.mergesIn(o))if(!(s.top>=o.top&&s.bottom<=o.bottom&&s.left>=o.left&&s.right<=o.right))return A("MergeOverlap","The paste would cut a merged cell in two; unmerge it first.");return U}function Sc(t){const e=n=>/[\t\n\r"]/.test(n)?`"${n.replace(/"/g,'""')}"`:n;return t.map(n=>n.map(e).join(" ")).join(`
|
|
3
3
|
`)}function xc(t){const e=[];let n=[],o="",s=!1;const r=t.replace(/\r\n?/g,`
|
|
4
4
|
`).replace(/\n$/,"");for(let i=0;i<r.length;i+=1){const l=r[i];s?l==='"'&&r[i+1]==='"'?(o+='"',i+=1):l==='"'?s=!1:o+=l:l==='"'&&o===""?s=!0:l===" "?(n.push(o),o=""):l===`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import"./percentages-BXMCSKIN-
|
|
1
|
+
import"./percentages-BXMCSKIN-DhE6_GLO.js";import"../datalayer-app-main.js";import"./floating-ui.react-dom-Bcd0th1j.js";import"./extends-CF3RwP-h.js";import"./index-CavxlEgY.js";import"./index-DoBkwclg.js";var u={paste:"चिटकवा",pasteAsPlaintext:"साधा मजकूर च्या रुपात पेस्ट करा",pasteCharts:"चार्ट चिकटवा",selectAll:"समस्त निवडा",multiSelect:"निवडित तत्व जोडा",moveCanvas:"पटल हलवा",cut:"कापा",copy:"प्रतिलिपी",copyAsPng:"PNG रूपे फळी वर कॉपी करा",copyAsSvg:"SVG रूपे फळी वर कॉपी करा",copyText:"लिखित रूपे फळी वर कॉपी करा",copySource:"स्त्रोत फळी वर कॉपी करा",convertToCode:"सांकेतिक लिपित रूपांतरित करा",bringForward:"पुढे पुढे आणा",sendToBack:"सर्वात मागे करा",bringToFront:"सर्वात पुढे आणा",sendBackward:"मागे मागे करा",delete:"हटवा",copyStyles:"शैली कॉपी करा",pasteStyles:"कॉपी केलेली शैली वापरा",stroke:"रेघे चा रंग",background:"पार्श्वभूमी",fill:"भरा",strokeWidth:"रेघ रुंदी",strokeStyle:"रेघ शैली",strokeStyle_solid:"भरीव",strokeStyle_dashed:"तुटित तुटित",strokeStyle_dotted:"ठिपके ठिपके",sloppiness:"गबाळेपणा",opacity:"अपारदर्शक्ता",textAlign:"मजकूर संरेखन",edges:"किनारी",sharp:"टोचरं",round:"गोलाकार",arrowheads:"बाण टोक",arrowhead_none:"कुठलाहि नाही",arrowhead_arrow:"बाण",arrowhead_bar:"दांडुक",arrowhead_circle:"",arrowhead_circle_outline:"",arrowhead_triangle:"त्रिकोण",arrowhead_triangle_outline:"",arrowhead_diamond:"",arrowhead_diamond_outline:"",fontSize:"अक्षर आकार",fontFamily:"अक्षर समूह",addWatermark:'"एक्सकेलीड्रॉ ने बनवलेलं" जोडा',handDrawn:"हातानी बनवलेलं",normal:"सामान्य",code:"सांकेतिक लिपि",small:"छोटे",medium:"मध्यम",large:"मोठं",veryLarge:"फार मोठं",solid:"भरीव",hachure:"हैशूर रेखांकन",zigzag:"वाकडी तिकड़ी",crossHatch:"आडव्या रेघा",thin:"पातळ",bold:"जाड",left:"डावं",center:"मधे",right:"उजवं",extraBold:"जास्त जाड",architect:"वास्तुविद्याविशारद",artist:"कलाकार",cartoonist:"व्यंग्य चित्रकार",fileTitle:"फाईलचे नाव",colorPicker:"रंग निवडक",canvasColors:"कॅनवास वर वापरलेले",canvasBackground:"पटल पार्श्वभूमि",drawingCanvas:"चित्र पटल",layers:"स्तर",actions:"क्रिया",language:"भाषा",liveCollaboration:"ज्वलंत सहयोग...",duplicateSelection:"प्रतिलिपि",untitled:"अशीर्षकांकित",name:"नाव",yourName:"तुमचे नाव",madeWithExcalidraw:"एक्सकेलीड्रॉ ने बनवलेलं",group:"समूह निवड",ungroup:"समूह निवड ला रद्द करा",collaborators:"Sahayog",showGrid:"ग्रिड दाखवा",addToLibrary:"संग्रह मधे सम्मिलित करा",removeFromLibrary:"संग्रहातून काढ़ा",libraryLoadingMessage:"संग्रह लोड होत आहे…",libraries:"संग्रह देखे",loadingScene:"दृश्य लोड होत आहे…",align:"संरेखित करा",alignTop:"वर संरेखित करा",alignBottom:"खाली संरेखित करा",alignLeft:"डावा बाजूला संरेखित करा",alignRight:"उजव्या बाजूला संरेखित करा",centerVertically:"मधल्या मधे उभं संरेखित करा",centerHorizontally:"मधल्या मधे आडवं संरेखित करा",distributeHorizontally:"आडवं वितरित करा",distributeVertically:"उभं वितरित करा",flipHorizontal:"आडवं फ्लिप करा",flipVertical:"उभं फ्लिप करा",viewMode:"पहायची पद्धत",share:"सामायिक करा",showStroke:"रेघ रंग निवड यंत्र दाखवा",showBackground:"पार्श्वभूमि: रंग निवड यंत्र दाखवा",toggleTheme:"शैली बदला",personalLib:"वैयक्तिक संग्रह",excalidrawLib:"एक्सकेलीड्रॉ संग्रह",decreaseFontSize:"अक्षर आकार छोटा करा",increaseFontSize:"अक्षर आकार मोठा करा",unbindText:"लेखन संबंध संपवा",bindText:"शब्द समूह ला पात्रात घ्या",createContainerFromText:"मजकूर कंटेनर मधे मोडून दाखवा",link:{edit:"दुवा संपादन",editEmbed:"कड़ी सम्पादित करा आणि रुतवा",create:"दुवा तयार करा",createEmbed:"नवीन कड़ी बनवा आणि रुतवा",label:"दुवा",labelEmbed:"कड़ी आणि रूतवणे",empty:"कुठलिही कड़ी दिली नाही"},lineEditor:{edit:"रेघ संपादन",exit:"रेघ संपादकाबाहेर"},elementLock:{lock:"कुलूपात ठेवा",unlock:"कुलूपातून बाहेर",lockAll:"सर्व कुलूपात ठेवा",unlockAll:"सर्व कुलूपातून बाहेर"},statusPublished:"प्रकाशित करा",sidebarLock:"साइडबार उघडं ठेवा",selectAllElementsInFrame:"चौकटीतले सर्व तत्वांचे चयन करा",removeAllElementsFromFrame:"चौकटीतून सर्व काढून टाका",eyeDropper:"चित्रफलकातून रंग निवडा",textToDiagram:"",prompt:""},E={noItems:"अजून कोणतेही आइटम जोडलेले नाही...",hint_emptyLibrary:"पटल वर एक वस्तु निवडुन एथे जोडा, किव्हा एक संग्रह जन कोष कडुन खाली स्थापित करा.",hint_emptyPrivateLibrary:"ईथे जोडण्या साठी पटल वरून एक वस्तु निवडा."},F={clearReset:"पटल पुसा",exportJSON:"फ़ाइलमधे बाहेर ठेवा",exportImage:"प्रतिमा निर्यात करा...",export:"येथे सुरक्षित करा...",copyToClipboard:"फळी वर कॉपी करा",save:"वर्तमान फ़ाइल मधे जतन करा",saveAs:"ह्या नावाने जतन करा",load:"उघडा",getShareableLink:"सामायिके साठी दुवा प्राप्त करा",close:"बंद करा",selectLanguage:"भाषा निवड करा",scrollBackToContent:"पहलेचा मजकुर वर मागे स्क्रॉल करा",zoomIn:"मोठं करून पहा",zoomOut:"छोटं करून पहा",resetZoom:"छोटं मोठं करणं बंद करा",menu:"यादि",done:"झालं",edit:"संपादित करा",undo:"पूर्ववत करा",redo:"पुन्हा करा(&R)",resetLibrary:"संग्रह पुनर्स्थित करा",createNewRoom:"एक नवी खोली बनवा",fullScreen:"पूर्ण दृश्यपटल",darkMode:"अंधार स्थिथि",lightMode:"उजेड स्थिति",zenMode:"ध्यानग्र स्थिति",objectsSnapMode:"वस्तूंपासून पकड़ा",exitZenMode:"ध्यानग्र स्थितितून बाहेर",cancel:"रद्द",clear:"स्वछ",remove:"हटवा",embed:"रुतवणे उलटे करा",publishLibrary:"प्रकाशित करा",submit:"जमा करा",confirm:"पुष्टि करा",embeddableInteractionButton:"संवादा साठी क्लिक करा"},D={clearReset:"पटल स्वच्छ होणार, तुम्हाला खात्री आहे का?",couldNotCreateShareableLink:"सामायी करण करण्या योग्य दुवा नाही बनवता आला.",couldNotCreateShareableLinkTooBig:"सामायी करण करण्या योग्य दुवा नाही बनवता आला: दृश्य फार मोठं आहे",couldNotLoadInvalidFile:"अवैध फ़ाइल लोड करता आली नाही",importBackendFailed:"बैकएंड हून मागवणे विफल झाले.",cannotExportEmptyCanvas:"रिकामा पटल जतन करता येत नाही.",couldNotCopyToClipboard:"पटल वर कॉपी नाही झाली.",decryptFailed:"डीक्रिप्ट करता आले नाही.",uploadedSecurly:"अपलोड या टोकापासून त्या टोकापर्यंत कूटबद्धित करून सुरक्षित केले गेले आहे, हयाचा अर्थ असा की एक्सकेलीड्रॉ सर्व्हर आणि तृतीय पक्ष मजकूर वाचू शकत नाहीत.",loadSceneOverridePrompt:"बाह्य रेखाचित्र लोड केल्याने तुमची तुमचा विद्यमान मजकूर बदलेल. हे काम तुम्हाला चालू ठेवायचे आहे का?",collabStopOverridePrompt:`सत्र थांबवल्याने तुमचे पूर्वीचे, स्थानिकरित्या संग्रहित रेखाचित्र अधिलिखित होईल. तुला खात्री आहे?
|
|
2
2
|
|
|
3
3
|
(तुम्हाला तुमचे स्थानिक रेखाचित्र ठेवायचे असल्यास, त्याऐवजी फक्त ब्राउझर टॅब बंद करा.)`,errorAddingToLibrary:"संग्रहात तत्व जोडू शकलो नाही",errorRemovingFromLibrary:"संग्रहातून तत्व काढू शकलो नाही",confirmAddLibrary:"हे तुमच्या संग्राहात {{numShapes}} आकार (एक किव्हा अनेक) जोडेल. तुला खात्री आहे?",imageDoesNotContainScene:"या प्रतिमेमध्ये कोणताही दृश्य डेटा असल्याचे दिसत नाही. बाहेर जतन करताना तुम्ही दृश्य रुतवले होते का?",cannotRestoreFromImage:"प्रतिमा फ़ाइल पासून दृश्य पुनः रचित नाही झाला",invalidSceneUrl:"दिलेल्या यू-आर-एल पासून दृश्य आणू शकलो नाही. तो एकतर बरोबार नाही आहे किंवा त्यात वैध एक्सकेलीड्रॉ जेसन डेटा नाही.",resetLibrary:"पटल स्वच्छ होणार, तुम्हाला खात्री आहे का?",removeItemsFromsLibrary:"संग्रहातून {{count}} तत्व (एक किव्हा अनेक) काढू?",invalidEncryptionKey:"कूटबद्धन कुंजी 22 अक्षरांची असणे आवश्यक आहे. थेट सहयोग अक्षम केले आहे.",collabOfflineWarning:`इंटरनेट कनेक्शन उपलब्ध नाही.
|
|
4
4
|
तुमचे बदल जतन केले जाणार नाहीत!`},e={unsupportedFileType:"असमर्थित फाइल प्रकार.",imageInsertError:"प्रतिमा आत घालता येत नाही. नंतर पुन्हा प्रयत्न करा...",fileTooBig:"फाइल फार मोठी आहे. आकाराची कमाल परवानगी {{maxSize}} आहे.",svgImageInsertError:"एस-वी-जी प्रतिमा आत घालवू शकलो नाही. एस-वी-जी-मार्क-अप यंत्र अयोग्य आहे.",failedToFetchImage:"प्रतिमा आणणे नाही जमले.",invalidSVGString:"अयोग्य एस-वी-जी.",cannotResolveCollabServer:"कॉलेब-सर्वर हे पोहोचत नाही आहे. पान परत लोड करायचा प्रयत्न करावे.",importLibraryError:"संग्रह प्रतिस्थापित नाही करता आला",collabSaveFailed:"काही कारणा निमित्त आतल्या डेटाबेसमध्ये जतन करू शकत नाही। समस्या तशिस राहिल्यास, तुम्ही तुमचे काम गमावणार नाही याची खात्री करण्यासाठी तुम्ही तुमची फाइल स्थानिक जतन करावी.",collabSaveFailed_sizeExceeded:`लगता है कि पृष्ठ तल काफ़ी बड़ा है, इस्कारण अंदरूनी डेटाबेस में सहेजा नहीं जा सका। किये काम को खोने न देने के लिये अपनी फ़ाइल को स्थानीय रूप से सहेजे।
|