@sheetxl/mcp 0.8.0-beta.14 → 0.8.0-beta.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/{DIy1659Yv5-fD69E.js → 9U9XCqqdn-q3i2fj.js} +1 -1
- package/assets/{2zIY9Xuml4y8NI05.js → B-MqXm_7luDLwazY.js} +1 -1
- package/assets/{DUYoUViqY5U6uQX3.js → B2Ek-DWpZMGJ0V1Z.js} +2 -2
- package/assets/{CH9M37mRwnS0t9wM.js → B2udpZ-uIaql3AUh.js} +5 -5
- package/assets/{CHHJZPAuM3OjbzF6.js → B4VnJacrzr1x4PHR.js} +4 -4
- package/assets/{B5xHa5bjZu5ONrm5.js → B5lHOOQ_rkP4Mi2r.js} +1 -1
- package/assets/{DWTpPijG5yeNFR0W.js → B7gUyrfLln3TiyKM.js} +1 -1
- package/assets/{a7BoASyT8yQZY9hJ.js → B9US2ZrF93KOjmAx.js} +1 -1
- package/assets/{CdF5MxGnISAZ41oQ.js → BBb_3gEGzmEzbTIk.js} +24 -24
- package/assets/{33QTHR3r6ZujxFx8.js → BCy1zP97fsiIcvj6.js} +1 -1
- package/assets/{CwJyw5Yxpj4PGh14.js → BFXeoFUbuc4IKTz9.js} +1 -1
- package/assets/{D94hlZEaHtGHdN_K.js → BFdeov2e_xUQPEY_.js} +6 -6
- package/assets/{D3BAmD-1AfFtHdC6.js → BG5kgbDRXMc0re6W.js} +8 -8
- package/assets/{UX2ywz3gr7q-MlHr.js → BJxfinOazQqqByc-.js} +1 -1
- package/assets/{hRLLK6I6m0uGKWo8.js → BOPsJmq7v7HOKUkO.js} +5 -5
- package/assets/{DPazQ_nZv-sXUwO3.js → BPwmBu_aouERJjiW.js} +1 -1
- package/assets/{DkFK1iu4vqjLZMja.js → BQMDOjNBMjAx9WiW.js} +1 -1
- package/assets/{CBNNl8igIyeHY4St.js → BQbF1RkUH8WyXqSD.js} +1 -1
- package/assets/{DpGuA6U12gwyGHEM.js → BRzp6DEIYUgM3NkN.js} +3 -3
- package/assets/{W-MzzQHZuRxr8adc.js → BSxTn2BhkEEeF9x_.js} +2 -2
- package/assets/{CfiVUfpeONJ3rf31.js → BTQhJQ3e0hsiousD.js} +1 -1
- package/assets/{Doqy_uDSQTCv6a6X.js → BZPTaa0WjpoUAbgZ.js} +1 -1
- package/assets/{CPDkdp0yI4DwUHGZ.js → BbAmA46MhQSu3ZF_.js} +1 -1
- package/assets/{yNiBIhsMP9BCWd67.js → BbcUxIZe3YXywsQR.js} +1 -1
- package/assets/{QXKcNTuZqOauSidr.js → BeLr36oL3jmeXFFi.js} +1 -1
- package/assets/{9MRZ5Yc2RBgcqZSp.js → Bg95xYj5siqhHVEz.js} +2 -2
- package/assets/{DTlvhtB9hvPdbdxu.js → Bh0PNKlrR4VAqnP8.js} +5161 -5154
- package/assets/{ZBYHyJs7CQgnnHfR.js → BjqQjxBuoXza8oqg.js} +1 -1
- package/assets/{DSSrCrejjpWoszj7.js → BlPubAFi7DY7VrAo.js} +1 -1
- package/assets/{eHAVGCUcMAfNjEGt.js → BleMG0hAQgjE8fTa.js} +2 -2
- package/assets/{DoIU_ohoCBwTZV9G.js → Bn8D2bebQ2tFfwQt.js} +19 -19
- package/assets/{DUUt1z6Y_cpxEpYY.js → BrcQmHcE7Hcr1erJ.js} +1 -1
- package/assets/{B9qiPx_BXxo1jgcx.js → BsQZI1vXTRE63Zy-.js} +21 -21
- package/assets/{EeSGsbh_r4N-qs4w.js → BtjqpAKczftx91BQ.js} +1 -1
- package/assets/{BYtBi8vLoB41QkV8.js → Btys7KwtvV3hz2F6.js} +4 -4
- package/assets/{w8YWSMNTTn45ImnB.js → BuUEsifnQALe49uk.js} +1 -1
- package/assets/{CULV-2mwmqYYpAjM.js → By-7OWXShMlFFejV.js} +1 -1
- package/assets/{PmooYGqWqoTxPExF.js → C0CiMKC3lWK1z9p5.js} +2 -2
- package/assets/{aqguaobnu61szXWM.js → C2OrZ8LZ-TI6eYG0.js} +1 -1
- package/assets/{Dl87mJoXDkCkzBi7.js → C4z2IilWTuu2TWXw.js} +2 -2
- package/assets/{DBFXsbIHDxbMBrzV.js → C7ONfuYIWRmDu_vs.js} +1 -1
- package/assets/{ByziR0Anm39Bw0Bc.js → C7Z1li2XjWi6bkrp.js} +3 -3
- package/assets/{C1w8NQeox7_92swz.js → C97xDe_wBbLZh_uW.js} +1 -1
- package/assets/{BOcWUnxWSG1d5Ljc.js → CGBGyaCGdlZFQYK0.js} +1 -1
- package/assets/{DCHsM8bfVisYJFTT.js → CJ5WQnaoCsdr5gf4.js} +1 -1
- package/assets/{GnXTzeDYWWeEf5yV.js → CMK6tIDVqYYvK4GZ.js} +1 -1
- package/assets/{DK0VM9-qrEXBm8Ud.js → CMWAsUQ66V8fYrME.js} +2 -2
- package/assets/{CDGeuGB9CBXeCIm6.js → CNz3LdmvsOEJoLO9.js} +1 -1
- package/assets/{DZZ5R3msiytVNCqK.js → CWVWdbY1B1-WLl9k.js} +55 -55
- package/assets/{CeDqeFLuUfN8UIGx.js → CWl6oHiJxkNKRixk.js} +1 -1
- package/assets/{ddJqSu7gXUkXjGxZ.js → CXHslDxkWCuEcCSQ.js} +1 -1
- package/assets/{B6BP5l2qmeZhqVV7.js → CZTSZL3T_f-vSXqM.js} +2 -2
- package/assets/{DuZ6DXQGttY3Lrhd.js → CduNzsdbTigxH-ZK.js} +124 -124
- package/assets/{BFwNQZVRnbNt-gRJ.js → CecTe22WURiXbVdY.js} +1 -1
- package/assets/{CVFTQ0OwsUt03r4o.js → Cf2dcwmmmf13Rywg.js} +1 -1
- package/assets/{OU7gC5JF-lyDOOid.js → Cf9LpgZz-W5blzy_.js} +2 -2
- package/assets/{ThqyayHHaBxzfaAt.js → Cfhv_Yw_LT8VzAMt.js} +1 -1
- package/assets/{CjwzOAnab_dpAqiG.js → Cg51xaLRUkVOMdCZ.js} +1 -1
- package/assets/{B9w1dNK8pNq-Z1P3.js → ChWpsFGl-BYOnX_A.js} +1 -1
- package/assets/{CcLPa6zB5PH3OG2O.js → ClNQN3vEg5b5qUDp.js} +8 -8
- package/assets/{BiAEoWSl8c6jcUnS.js → Crt2kLdGIlBHANgg.js} +1 -1
- package/assets/{CMTDUipnLiOj5pbe.js → CudNpUD78SrtJIiy.js} +2 -2
- package/assets/{BmxgDCZk_aMDms4i.js → CvngwB17_ve4W49b.js} +27 -27
- package/assets/{Dfd7kvLIFNqu-m-r.js → CwPBmcY6xSP8dNlh.js} +11 -11
- package/assets/{PRSerWiAGYu8MVnd.js → CxjchwpiqxPM1XKd.js} +54 -54
- package/assets/{CtpcYuBFU6fxsUhs.js → D-ffk16w8c5w0mxI.js} +1 -1
- package/assets/{D81iH5MJJfq2t9FP.js → D0CHDsemn0S31ltt.js} +1 -1
- package/assets/{DUzaW_op2vBTwOOI.js → D7oUtYjetuykGhQ5.js} +1 -1
- package/assets/{DkPXpv81Y5teMd-R.js → D8J14MLlN2HRXdXB.js} +1 -1
- package/assets/{BW8XjynUqlfvuQUV.js → DA_ar3QKLKtJ9fJD.js} +1 -1
- package/assets/{CXM1IYmE-TDInPwr.js → DB-tkqI6wFXDKEfB.js} +1 -1
- package/assets/{C55MTJ_5qW94RElE.js → DD8HNAUFroTCuD-b.js} +96 -96
- package/assets/{CpOhY88x6AgVxvTz.js → DDnwKPJSznyfYDZS.js} +2 -2
- package/assets/{cv7k-VAIJtYeL9k4.js → DEW2GxfGYqVFvrfg.js} +1 -1
- package/assets/{CgjR_TiVOcuxg5tO.js → DH7sGHzxUqIQkDnd.js} +1 -1
- package/assets/{BMnNvUCJu35tT_aO.js → DJiLWtmPR2OQNjzi.js} +1 -1
- package/assets/{BOF64A2D2KKcv_fo.js → DKLm4nWzynGw1Kr9.js} +1 -1
- package/assets/{B_-VPqfsse8AlCTm.js → DPCKMM7sgWbrtB8z.js} +1 -1
- package/assets/{B-jE7tAMA559MtNt.js → DTfl-4Iboi6TQU5m.js} +3 -3
- package/assets/{Df2IAW-O7Gwl7V1l.js → DVchxwp6w6lu2Ihu.js} +2 -2
- package/assets/{COFze3jkZDQRSij9.js → DaoSWy3EFlqpZaLr.js} +196 -196
- package/assets/{ZTEO4JX22YIOkrJg.js → DcWTBOi_iBFc6U4J.js} +3 -3
- package/assets/Dht2mcOSyYlPY32b.js +14 -0
- package/assets/{9dbZwzIWefGss7is.js → Diee6f_qAmcZBd2_.js} +1 -1
- package/assets/{CwdOInoJwCxXnhog.js → DkibD_CEVePaoj_y.js} +2 -2
- package/assets/{DvD_K4M5HgJ4uJ8L.js → DlBdhv6NHgrNp5Yo.js} +2 -2
- package/assets/{BWsXOU_jh_cA8m8I.js → DoILAmhKUOlKWRVw.js} +1 -1
- package/assets/{cdIvC9t9tYtVn4nc.js → DpdHDTFOeuzDVNEe.js} +46 -46
- package/assets/{C-5LlJ5qhC7Ef0gV.js → DsCI_ZYm_jDjXF3J.js} +14 -14
- package/assets/{Du_JrYiYGJo5_B9H.js → DvUUArnZwoYOKOuk.js} +1 -1
- package/assets/{BXC6616BWEWNZ2-D.js → DwLZpYUp85UHBE3H.js} +1 -1
- package/assets/{BNfBq8Eic3Cl-f6A.js → DwWngYJTgC0KLbih.js} +1 -1
- package/assets/{C1rIlmARlinuie5E.js → Dz8UUJ7Xc2oN5PBG.js} +1 -1
- package/assets/{Dg7xy50qHwqkYd4g.js → FS9NbEKgQvz5wqvZ.js} +1 -1
- package/assets/{D2w3KjYuONW1G1kX.js → F_f0jJqM5MrXGbwC.js} +3 -3
- package/assets/{TzsPqmpG77I4ewVt.js → FzNG48GE_wso6RII.js} +1 -1
- package/assets/{BwisWvPpXRhyIP4O.js → JO3zH9hupFSV6vj2.js} +1 -1
- package/assets/{C-CNmTrzNS-ZlQ8j.js → LEJp05fjmflKgyqF.js} +148 -148
- package/assets/{Cm3Q_-DDdnVHRBxr.js → LyLlBk--VJD2V-f8.js} +4 -4
- package/assets/{DnmjS548g7nY6EUS.js → OVRdpPUzR0-ueTxE.js} +1 -1
- package/assets/{mcFLzsOH35mvmd3C.js → PpFbmF0DFeUdpb9I.js} +1 -1
- package/assets/{B66aeGYrHLbGpuN9.js → S16s2h9qoYVBlVEa.js} +320 -320
- package/assets/{BkBCkgPNrFR5N9fo.js → SHZe9VOU1prGs1F9.js} +1 -1
- package/assets/{DihigEGfNCLR8UPN.js → U1XXGEPuuqIAzYl1.js} +1 -1
- package/assets/{zu-72oKE_gCkrozc.js → ZuYfVKlp41IJnrOS.js} +1 -1
- package/assets/{8vRAQlvTcvMLeio0.js → _d5XJ7dn1CKKYrep.js} +2 -2
- package/assets/{BoTScfjgygCozDVi.js → _fUXIv6nKvgZkhxn.js} +2 -2
- package/assets/{C2Rgsb69SnMOohGt.js → fDMpDhXp36CatF-G.js} +1 -1
- package/assets/{B9QlqO6n3MCBsvoj.js → hulrR0PldUxMJm_F.js} +3 -3
- package/assets/{B-1_xSqUFCJ6jNjn.js → iujMYIEPx_v3sdPf.js} +15 -15
- package/assets/{CutEBbZl8oFbTlXZ.js → jPUOH4FHF4b-rapv.js} +1 -1
- package/assets/{BDZ1FGc1zFqO1nK7.js → jadLBUNBVR9mbZ35.js} +149 -149
- package/assets/{D2_T0KSaye0ncjQa.js → jiEe5eKV3BFPBWfi.js} +67 -67
- package/assets/{KpCEdfpsHnfkyqjx.js → oxjm7Yr7u7MeaO5P.js} +1 -1
- package/assets/{B6b9ytNrHR-ijcOa.js → vZZi_iKYHm05gAye.js} +1 -1
- package/assets/{st-UQngeBG4hwKoy.js → wfVh0olISLRWdv9Q.js} +1 -1
- package/assets/{HKLw8b2xTdu5c1w5.js → xmTQJJVyCrcq77WR.js} +1 -1
- package/assets/{DZRp3_yqPS6Lshho.js → xnhBSX6lAcmBM65y.js} +1 -1
- package/index.js +29 -29
- package/lib.js +1 -1
- package/licenses/dependencies.txt +57 -57
- package/package.json +8 -8
- package/screenshot-page/assets/B2MJPcMcsuv6FekC.js +1 -0
- package/screenshot-page/assets/{BCl5buf87xUgIfEB.js → BSdFVGZNhU6YHbMI.js} +1 -1
- package/screenshot-page/assets/{Cv8FG9PPBkkPw86e.js → BTMW3ukmc44U2fy7.js} +1 -1
- package/screenshot-page/assets/{Miyn0clMq0rovRIo.js → BTboCICZ-951XWsi.js} +1 -1
- package/screenshot-page/assets/B_W2QroTKADz3ABp.js +2 -0
- package/screenshot-page/assets/{Bor_tayB4yBfNOH5.js → Bj-vfAT28PK-tWWa.js} +2 -2
- package/screenshot-page/assets/{CvL9XK3Ht1mP-rGz.js → BnoVwUBEor8NgQNs.js} +2 -2
- package/screenshot-page/assets/{DzZRUd0p22CBa27b.js → BzQ5GyiXq8gTz-H-.js} +1 -1
- package/screenshot-page/assets/CwqNb7JYzC03lCj0.js +1 -0
- package/screenshot-page/assets/CzhH7lTYQrYGHct6.js +1 -0
- package/screenshot-page/assets/{CnZJ44ncMxZ4ivcB.js → D66vSE1ConAuENmB.js} +7 -7
- package/screenshot-page/assets/DCVUZ_ayOXFwV2d_.js +3 -0
- package/screenshot-page/assets/DFE-fKq5NV7_O8V6.js +1 -0
- package/screenshot-page/assets/{zHHZFbk5RXnrxbOc.js → DK_QSosKV62NDcuT.js} +9 -9
- package/screenshot-page/assets/{Bz2U7weS0spa8Xbh.js → DTFRGj188QuLKEXw.js} +1 -1
- package/screenshot-page/assets/{DDpAoGAPzo1c4vl5.js → DXQLzGmxoyN3kfQi.js} +3 -3
- package/screenshot-page/assets/DXWWyJlMSWgDFxs1.js +10 -0
- package/screenshot-page/assets/{DqM1wwsmN1J4MXMm.js → Dsx0NUmGIxS7SvZ8.js} +1 -1
- package/screenshot-page/assets/Q5EKmzoJZCE81Om-.js +2 -0
- package/screenshot-page/assets/{BYRwTzX1q407lHUS.js → TfhknTx8vxQkw4zV.js} +2 -2
- package/screenshot-page/assets/VvqAh6BWzaD5OUPF.js +1 -0
- package/screenshot-page/assets/{CE0MnsfMjqV2ICzk.js → hp_-JA1DMK4Yoztn.js} +12 -12
- package/screenshot-page/assets/{BRqSWCr2mTVNFquQ.js → l32n8O_A78Qqduv3.js} +1 -1
- package/screenshot-page/assets/sHBomL5R4-_px8rD.js +1 -0
- package/screenshot-page/assets/skRJ2qjA7kcmnOsh.js +39 -0
- package/screenshot-page/index.html +3 -3
- package/assets/Cfvhcua4c6onouhP.js +0 -14
- package/screenshot-page/assets/04d8koPx6lzeMYRQ.js +0 -39
- package/screenshot-page/assets/Bwql3QifB2cv7Mqp.js +0 -3
- package/screenshot-page/assets/CFOaI8g7pJuPzsyk.js +0 -1
- package/screenshot-page/assets/DUJzubL4qqOyizfu.js +0 -1
- package/screenshot-page/assets/DWiI5I3RtoKvVT66.js +0 -1
- package/screenshot-page/assets/D_H2dlsQ8PJ0r1WD.js +0 -10
- package/screenshot-page/assets/DsL71n5SxCVjL6Ho.js +0 -2
- package/screenshot-page/assets/IfF7Tv-nhz6Ikpn0.js +0 -1
- package/screenshot-page/assets/Rm5Sf5E6t8bk_Y3r.js +0 -1
- package/screenshot-page/assets/b3AbgxQkoaCiBi15.js +0 -1
- package/screenshot-page/assets/qm3VY0bH7F7EgSdi.js +0 -2
|
@@ -1,36 +1,36 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license @sheetxl/mcp - MCP server exposing SheetXL spreadsheet operations as tools and resources. - v0.8.0-beta.
|
|
2
|
+
* @license @sheetxl/mcp - MCP server exposing SheetXL spreadsheet operations as tools and resources. - v0.8.0-beta.15
|
|
3
3
|
*
|
|
4
4
|
* (C) 2026-present SheetXL Inc. & Michael T. Ford
|
|
5
5
|
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
6
|
*/
|
|
7
|
-
import { ht as e } from "./
|
|
8
|
-
import { a as t } from "./
|
|
9
|
-
import { a as n, c as r, d as i, o as s, p as l } from "./
|
|
10
|
-
import { Ai as o,
|
|
11
|
-
var z = (e, t) => e + t, D = (e, t) => e - t, M = (e, t) =>
|
|
7
|
+
import { ht as e } from "./BQMDOjNBMjAx9WiW.js";
|
|
8
|
+
import { a as t } from "./iujMYIEPx_v3sdPf.js";
|
|
9
|
+
import { a as n, c as r, d as i, o as s, p as l } from "./BQbF1RkUH8WyXqSD.js";
|
|
10
|
+
import { Ai as o, B as a, Fi as u, Fr as c, Gr as f, In as p, Mn as d, Mt as g, Pt as v, U as h, Xt as m, Yt as y, _i as I, bi as b, c as x, ea as R, ei as E, f as T, fr as A, gi as S, gr as w, ha as C, ir as N, it as F, mr as P, mt as L, ni as k, ra as $, ta as O, va as B, y as V } from "./Bh0PNKlrR4VAqnP8.js";
|
|
11
|
+
var z = (e, t) => e + t, D = (e, t) => e - t, M = (e, t) => w(e + t, e), W = (e, t) => w(e - t, e), U = (e, t) => A(e * t), _ = (e, t) => 0 === t ? i.BuiltIn.Div0 : A(e / t), j = (e, t) => {
|
|
12
12
|
if (0 === e) {
|
|
13
13
|
if (t < 0) return i.BuiltIn.Div0;
|
|
14
14
|
if (0 === t) return NaN;
|
|
15
15
|
}
|
|
16
16
|
if (e < 0) {
|
|
17
|
-
if (Number.isInteger(t) && Math.abs(t) <= 4294967294) return
|
|
17
|
+
if (Number.isInteger(t) && Math.abs(t) <= 4294967294) return A(e ** t);
|
|
18
18
|
const n = Number((1 / t).toPrecision(15));
|
|
19
|
-
return Number.isInteger(n) && 1 === Math.abs(n % 2) ?
|
|
19
|
+
return Number.isInteger(n) && 1 === Math.abs(n % 2) ? A(-((-e) ** t)) : NaN;
|
|
20
20
|
}
|
|
21
|
-
return
|
|
21
|
+
return A(e ** t);
|
|
22
22
|
}, G = (e = "", t = "") => {
|
|
23
23
|
null === e && (e = ""), null === t && (t = "");
|
|
24
24
|
const n = typeof t;
|
|
25
|
-
"boolean" == typeof e && (e =
|
|
25
|
+
"boolean" == typeof e && (e = F(e)), "boolean" === n && (t = F(t));
|
|
26
26
|
const r = "" + e + t;
|
|
27
27
|
return r.length > s.MAX_TEXT_LENGTH ? r.slice(0, s.MAX_TEXT_LENGTH) : r;
|
|
28
|
-
}, H = (e, t = null, n = null) => 0 === e.compare(t, n), X = (e, t = null, n = null) => 0 !== e.compare(t, n),
|
|
28
|
+
}, H = (e, t = null, n = null) => 0 === e.compare(t, n), X = (e, t = null, n = null) => 0 !== e.compare(t, n), K = (e, t = null, n = null) => e.compare(t, n) > 0, Z = (e, t = null, n = null) => e.compare(t, n) >= 0, q = (e, t = null, n = null) => e.compare(t, n) < 0, Y = (e, t = null, n = null) => e.compare(t, n) <= 0, J = {
|
|
29
29
|
type: l.Number,
|
|
30
30
|
coerce: [l.Boolean, l.String],
|
|
31
31
|
onError: "value",
|
|
32
32
|
misalignValue: i.BuiltIn.NA
|
|
33
|
-
},
|
|
33
|
+
}, Q = {
|
|
34
34
|
type: l.String,
|
|
35
35
|
coerce: [l.Boolean, l.Number],
|
|
36
36
|
onError: "value",
|
|
@@ -45,10 +45,10 @@ var z = (e, t) => e + t, D = (e, t) => e - t, M = (e, t) => N(e + t, e), W = (e,
|
|
|
45
45
|
let s, o;
|
|
46
46
|
if (t?.isIRange ? s = t : n?.isIRange && (o = n), !s && !o) {
|
|
47
47
|
const s = e.getRuntime();
|
|
48
|
-
return t = f(s, t,
|
|
48
|
+
return t = f(s, t, b(t, !0), l.Number, !0), n = f(s, n, b(n, !0), l.Number, !0), t && i.isError(t) ? t : n && i.isError(n) ? n : r(t, n);
|
|
49
49
|
}
|
|
50
50
|
const a = !s, u = a ? t : n;
|
|
51
|
-
return (s ?? o).broadcast(u, (t, n) => t && i.isError(t) ? t : n && i.isError(n) ? n :
|
|
51
|
+
return (s ?? o).broadcast(u, (t, n) => t && i.isError(t) ? t : n && i.isError(n) ? n : E(a ? r(n, t) : r(t, n), e), J).fillEmpty(0);
|
|
52
52
|
}, re = (e, t, r, s) => {
|
|
53
53
|
if (d(t) || d(r)) return i.BuiltIn.Value;
|
|
54
54
|
if (n(t) || n(r)) return i.BuiltIn.Value;
|
|
@@ -70,9 +70,9 @@ var z = (e, t) => e + t, D = (e, t) => e - t, M = (e, t) => N(e + t, e), W = (e,
|
|
|
70
70
|
if ("-" !== t) throw new i.Value(`Unrecognized prefix: ${t}`);
|
|
71
71
|
if (s = -s, n?.isIRange && (r = n), !r) {
|
|
72
72
|
const t = e.getRuntime();
|
|
73
|
-
return "number" != typeof (n = f(t, n,
|
|
73
|
+
return "number" != typeof (n = f(t, n, b(n, !0), l.Number, !0)) ? i.BuiltIn.Value : n * s;
|
|
74
74
|
}
|
|
75
|
-
return r.broadcast(s, (e, t) => e && i.isError(e) ? e : t && i.isError(t) ? t : U(e, t),
|
|
75
|
+
return r.broadcast(s, (e, t) => e && i.isError(e) ? e : t && i.isError(t) ? t : U(e, t), J);
|
|
76
76
|
}, le = (e) => e.getCode() <= i.Code.NA ? e : i.BuiltIn.Value, oe = (e, t, n, r, s) => {
|
|
77
77
|
if (i.isError(t)) return le(t);
|
|
78
78
|
if (n && i.isError(n)) return le(n);
|
|
@@ -114,17 +114,17 @@ var z = (e, t) => e + t, D = (e, t) => e - t, M = (e, t) => N(e + t, e), W = (e,
|
|
|
114
114
|
let s, o;
|
|
115
115
|
if (t?.isIRange ? s = t : n?.isIRange && (o = n), !s && !o) {
|
|
116
116
|
const s = e.getRuntime();
|
|
117
|
-
return t = f(s, t,
|
|
117
|
+
return t = f(s, t, b(t, !0), l.String, !1), n = f(s, n, b(n, !0), l.String, !1), i.isError(t) ? t : i.isError(n) ? n : r(t, n);
|
|
118
118
|
}
|
|
119
119
|
const a = !s, u = a ? t : n;
|
|
120
|
-
return (s ?? o).broadcast(u, (e, t) => e && i.isError(e) ? e : t && i.isError(t) ? t : a ? r(t, e) : r(e, t),
|
|
120
|
+
return (s ?? o).broadcast(u, (e, t) => e && i.isError(e) ? e : t && i.isError(t) ? t : a ? r(t, e) : r(e, t), Q);
|
|
121
121
|
})(e, t, n, G),
|
|
122
122
|
"=": (e, t, n) => re(e, t, n, H),
|
|
123
123
|
"<>": (e, t, n) => re(e, t, n, X),
|
|
124
|
-
">": (e, t, n) => re(e, t, n,
|
|
124
|
+
">": (e, t, n) => re(e, t, n, K),
|
|
125
125
|
"<": (e, t, n) => re(e, t, n, q),
|
|
126
|
-
">=": (e, t, n) => re(e, t, n,
|
|
127
|
-
"<=": (e, t, n) => re(e, t, n,
|
|
126
|
+
">=": (e, t, n) => re(e, t, n, Z),
|
|
127
|
+
"<=": (e, t, n) => re(e, t, n, Y)
|
|
128
128
|
}, ue = {
|
|
129
129
|
"+": (e, t, n) => ne(e, t, n, M),
|
|
130
130
|
"-": (e, t, n) => ne(e, t, n, W)
|
|
@@ -173,14 +173,14 @@ var de = class {
|
|
|
173
173
|
const r = n[e], i = this.references.get(r);
|
|
174
174
|
i ? (i.hasHorizontalAbs && (t.hasHorizontalAbs = !0), i.hasVerticalAbs && (t.hasVerticalAbs = !0), s[e] = i.index) : s[e] = -1, i && this.rootReferences.delete(i);
|
|
175
175
|
}
|
|
176
|
-
if (this.rootReferences.add(t),
|
|
176
|
+
if (this.rootReferences.add(t), Ke.includes(i)) {
|
|
177
177
|
const r = n[0], i = !!r && r.type === $.Cell, s = n[1], l = !!s && s.type === $.Cell;
|
|
178
178
|
i && l && void 0 !== s.referenceIndex && void 0 !== r.referenceIndex && (this.referenceIndices.splice(s.referenceIndex, 1), s.referenceIndex = r.referenceIndex, e.referenceIndex = r.referenceIndex, this.referenceIndices[r.referenceIndex] = t.index);
|
|
179
179
|
} else "#" === i && n[0] && (e.referenceIndex = n[0].referenceIndex);
|
|
180
180
|
return;
|
|
181
181
|
}
|
|
182
182
|
if (n === $.Error || n === $.Named) {
|
|
183
|
-
const r = n === $.Named ? e.value.nameId :
|
|
183
|
+
const r = n === $.Named ? e.value.nameId : x(e.value);
|
|
184
184
|
let i = this.names.get(r);
|
|
185
185
|
t.op = n, void 0 === i && (i = this.names.size, this.names.set(r, i)), t.value = i, this.rootReferences.add(t), e.referenceIndex = this.referenceIndices.length, this.referenceIndices.push(t.index);
|
|
186
186
|
return;
|
|
@@ -198,11 +198,11 @@ var de = class {
|
|
|
198
198
|
}
|
|
199
199
|
}
|
|
200
200
|
};
|
|
201
|
-
function ge(e, t = !1, n =
|
|
201
|
+
function ge(e, t = !1, n = T) {
|
|
202
202
|
const r = [], i = /* @__PURE__ */ new Set(), s = (e, n, s) => {
|
|
203
203
|
const l = {
|
|
204
204
|
type: e.type,
|
|
205
|
-
value: e.type === $.Error ?
|
|
205
|
+
value: e.type === $.Error ? P(e.value) : e.value
|
|
206
206
|
};
|
|
207
207
|
void 0 !== e.image && (l.text = ((e) => {
|
|
208
208
|
const n = t ? e.value?.scopeImage : void 0;
|
|
@@ -220,41 +220,41 @@ function ge(e, t = !1, n = S) {
|
|
|
220
220
|
};
|
|
221
221
|
void 0 !== i && (l.evalIndex = i), n && (l.context = n), r.push(l);
|
|
222
222
|
};
|
|
223
|
-
(function e(o,
|
|
224
|
-
const
|
|
223
|
+
(function e(o, u, c) {
|
|
224
|
+
const f = o.evalIndex ?? c ?? 0, p = o.type, d = (t, r, i) => {
|
|
225
225
|
if (!t) return;
|
|
226
226
|
const s = t.length;
|
|
227
227
|
for (let o = 0; o < s; o++) e(t[o], r, i), o < s - 1 && l($.Separator, ",", r, i, n.separatorFunction);
|
|
228
228
|
};
|
|
229
229
|
if (o.isLiteral) {
|
|
230
|
-
if (l($.Whitespace, o.wsBefore,
|
|
231
|
-
l($.Type, "{",
|
|
230
|
+
if (l($.Whitespace, o.wsBefore, u, f), p === $.Array) {
|
|
231
|
+
l($.Type, "{", u, f);
|
|
232
232
|
const t = o.value, r = t.length;
|
|
233
233
|
for (let i = 0; i < r; i++) {
|
|
234
|
-
const s = t[i], o = s.value,
|
|
235
|
-
for (let t = 0; t <
|
|
234
|
+
const s = t[i], o = s.value, a = o.length;
|
|
235
|
+
for (let t = 0; t < a; t++) {
|
|
236
236
|
const r = o[t];
|
|
237
|
-
l($.Whitespace, r.wsBefore,
|
|
237
|
+
l($.Whitespace, r.wsBefore, u, f), e(r, u, f), l($.Whitespace, r.wsAfter, u, f), t < a - 1 && l($.Separator, ",", u, f, n.separatorColumn);
|
|
238
238
|
}
|
|
239
|
-
i < r - 1 && (l($.Whitespace, s.wsBefore,
|
|
239
|
+
i < r - 1 && (l($.Whitespace, s.wsBefore, u, f), l($.Separator, ";", u, f, n.separatorRow), l($.Whitespace, s.wsAfter, u, f));
|
|
240
240
|
}
|
|
241
|
-
o.error || l($.Type, "}",
|
|
242
|
-
} else
|
|
243
|
-
type:
|
|
241
|
+
o.error || l($.Type, "}", u, f);
|
|
242
|
+
} else p === $.String ? (o = {
|
|
243
|
+
type: p,
|
|
244
244
|
value: "\"" + `${o.value}`.replace(/"/g, "\"\"") + "\"",
|
|
245
245
|
image: o.image
|
|
246
|
-
}, s(o,
|
|
247
|
-
l($.Whitespace, o.wsAfter,
|
|
248
|
-
} else if (
|
|
249
|
-
else if (
|
|
250
|
-
else if (
|
|
251
|
-
o.inputs?.[0] && e(o.inputs[0],
|
|
252
|
-
const t = s(o,
|
|
253
|
-
"#" === o.value && void 0 !== t.text && !o.wsBefore && i.has(n) && (n.text = (n.text ?? "") + t.text, t.text = ""), l($.Whitespace, o.wsAfter,
|
|
246
|
+
}, s(o, u, f)) : s(o, u, f);
|
|
247
|
+
l($.Whitespace, o.wsAfter, u, f);
|
|
248
|
+
} else if (p === $.Infix) e(o.inputs[0], u, f), l($.Whitespace, o.wsBefore, u, f), s(o, u, f), l($.Whitespace, o.wsAfter, u, f), e(o.inputs[1], u, f);
|
|
249
|
+
else if (p === $.Prefix) l($.Whitespace, o.wsBefore, u, f), s(o, u, f), l($.Whitespace, o.wsAfter, u, f), o.inputs && e(o.inputs[0], u, f);
|
|
250
|
+
else if (p === $.Postfix) {
|
|
251
|
+
o.inputs?.[0] && e(o.inputs[0], u, f), l($.Whitespace, o.wsBefore, u, f);
|
|
252
|
+
const t = s(o, u, f), n = r[r.length - 2];
|
|
253
|
+
"#" === o.value && void 0 !== t.text && !o.wsBefore && i.has(n) && (n.text = (n.text ?? "") + t.text, t.text = ""), l($.Whitespace, o.wsAfter, u, f);
|
|
254
254
|
} else {
|
|
255
|
-
l($.Whitespace, o.wsBefore,
|
|
256
|
-
const
|
|
257
|
-
switch (
|
|
255
|
+
l($.Whitespace, o.wsBefore, u, f);
|
|
256
|
+
const c = o.inputs;
|
|
257
|
+
switch (p) {
|
|
258
258
|
case $.Function: {
|
|
259
259
|
const t = String(o.value), i = {
|
|
260
260
|
type: $.Function,
|
|
@@ -262,19 +262,19 @@ function ge(e, t = !1, n = S) {
|
|
|
262
262
|
text: o.image ?? t,
|
|
263
263
|
evalIndex: o.evalIndex
|
|
264
264
|
};
|
|
265
|
-
|
|
265
|
+
u && (i.context = u), r.push(i);
|
|
266
266
|
const s = {
|
|
267
267
|
name: t,
|
|
268
268
|
argIndex: -1,
|
|
269
269
|
type: o.binder?.kind ?? "function"
|
|
270
270
|
};
|
|
271
|
-
if (
|
|
272
|
-
const t =
|
|
271
|
+
if (u?.bound && (s.bound = u.bound), l($.Paren, "(", s, o.evalIndex), c) {
|
|
272
|
+
const t = c.length, r = o.binder?.kind, i = "lambda" === r ? 1 : "let" === r ? 2 : 0;
|
|
273
273
|
let a = s.bound;
|
|
274
274
|
for (let o = 0; o < t; o++) {
|
|
275
|
-
const
|
|
276
|
-
if (
|
|
277
|
-
const e =
|
|
275
|
+
const u = i && o >= i ? c[o - i] : void 0;
|
|
276
|
+
if (u?.binding?.declaration) {
|
|
277
|
+
const e = u.value.nameId, t = "let" === r ? bt(c[o - 1]) : void 0;
|
|
278
278
|
a = It(a, t ? {
|
|
279
279
|
name: e,
|
|
280
280
|
params: t
|
|
@@ -284,15 +284,15 @@ function ge(e, t = !1, n = S) {
|
|
|
284
284
|
...s,
|
|
285
285
|
argIndex: o
|
|
286
286
|
};
|
|
287
|
-
a && (p.bound = a), e(
|
|
287
|
+
a && (p.bound = a), e(c[o], p, f), o < t - 1 && l($.Separator, ",", p, f, n.separatorFunction);
|
|
288
288
|
}
|
|
289
289
|
}
|
|
290
290
|
o.error || l($.Paren, ")", s, o.evalIndex);
|
|
291
291
|
break;
|
|
292
292
|
}
|
|
293
293
|
case $.Call: {
|
|
294
|
-
const t =
|
|
295
|
-
if (t && e(t,
|
|
294
|
+
const t = a(o), i = r.length;
|
|
295
|
+
if (t && e(t, u, f), t?.type === $.Named) for (let e = i; e < r.length; e++) {
|
|
296
296
|
const t = r[e];
|
|
297
297
|
t.type !== $.Whitespace && (t.evalIndex = o.evalIndex, t.type === $.Named && (t.type = $.Function, t.value = t.value.name));
|
|
298
298
|
}
|
|
@@ -301,30 +301,30 @@ function ge(e, t = !1, n = S) {
|
|
|
301
301
|
argIndex: -1,
|
|
302
302
|
type: "function"
|
|
303
303
|
};
|
|
304
|
-
|
|
305
|
-
const
|
|
306
|
-
for (let t = 0; t <
|
|
304
|
+
u?.bound && (s.bound = u.bound), l($.Paren, "(", s, o.evalIndex);
|
|
305
|
+
const c = C(o), p = c.length;
|
|
306
|
+
for (let t = 0; t < p; t++) {
|
|
307
307
|
const r = {
|
|
308
308
|
...s,
|
|
309
309
|
argIndex: t
|
|
310
310
|
};
|
|
311
|
-
e(
|
|
311
|
+
e(c[t], r, f), t < p - 1 && l($.Separator, ",", r, f, n.separatorFunction);
|
|
312
312
|
}
|
|
313
313
|
o.error || l($.Paren, ")", s, o.evalIndex);
|
|
314
314
|
break;
|
|
315
315
|
}
|
|
316
316
|
case $.Cell:
|
|
317
|
-
s(o,
|
|
317
|
+
s(o, u, f);
|
|
318
318
|
break;
|
|
319
319
|
case $.Paren:
|
|
320
|
-
l(
|
|
320
|
+
l(p, "(", u, f), d(c, u, f), o.error || l(p, ")", u, f);
|
|
321
321
|
break;
|
|
322
322
|
case $.TableReference: {
|
|
323
323
|
const n = o.value?.tableId ?? "", s = {
|
|
324
324
|
name: n,
|
|
325
325
|
argIndex: -1,
|
|
326
326
|
type: "table"
|
|
327
|
-
},
|
|
327
|
+
}, a = r.length, p = o.image;
|
|
328
328
|
let d, g = !1;
|
|
329
329
|
if (n && p) {
|
|
330
330
|
let e = 0;
|
|
@@ -333,56 +333,56 @@ function ge(e, t = !1, n = S) {
|
|
|
333
333
|
-1 !== t && 33 === p.charCodeAt(t + 1) && (e = t + 2);
|
|
334
334
|
}
|
|
335
335
|
const n = p.indexOf("[", e);
|
|
336
|
-
if (g = 0 === n && null !=
|
|
337
|
-
else if (!
|
|
336
|
+
if (g = 0 === n && null != c, n > 0) d = p.slice(0, n);
|
|
337
|
+
else if (!c) {
|
|
338
338
|
const e = p.lastIndexOf("!");
|
|
339
339
|
d = t || -1 === e ? p : p.slice(e + 1);
|
|
340
340
|
}
|
|
341
341
|
}
|
|
342
|
-
if (!n || g && t || l($.TableReference, n,
|
|
343
|
-
const t =
|
|
342
|
+
if (!n || g && t || l($.TableReference, n, u, f, d), c && l($.Paren, "[", s, f), c) {
|
|
343
|
+
const t = c.length;
|
|
344
344
|
for (let n = 0; n < t; n++) {
|
|
345
345
|
const r = {
|
|
346
346
|
...s,
|
|
347
347
|
argIndex: n
|
|
348
348
|
};
|
|
349
|
-
e(
|
|
349
|
+
e(c[n], r, f), n < t - 1 && l($.Separator, ",", r, f);
|
|
350
350
|
}
|
|
351
351
|
}
|
|
352
|
-
|
|
352
|
+
c && !o.error && l($.Paren, "]", s, f);
|
|
353
353
|
const v = o.referenceIndex;
|
|
354
|
-
for (let e =
|
|
354
|
+
for (let e = a; e < r.length; e++) void 0 !== v && (r[e].referenceIndex = v), i.add(r[e]);
|
|
355
355
|
break;
|
|
356
356
|
}
|
|
357
357
|
case $.TableSpecifier:
|
|
358
358
|
case $.TableColumn: {
|
|
359
359
|
const e = o.image, t = null != e && e.startsWith("[") && e.endsWith("]");
|
|
360
|
-
t && l($.Paren, "[",
|
|
360
|
+
t && l($.Paren, "[", u, f);
|
|
361
361
|
const n = {
|
|
362
|
-
table: "table" ===
|
|
362
|
+
table: "table" === u?.type ? u.name : "",
|
|
363
363
|
name: o.value
|
|
364
364
|
}, i = {
|
|
365
|
-
type:
|
|
365
|
+
type: p,
|
|
366
366
|
value: n,
|
|
367
367
|
text: t ? e.slice(1, -1) : e ?? n.name
|
|
368
368
|
};
|
|
369
|
-
void 0 !==
|
|
369
|
+
void 0 !== f && (i.evalIndex = f), u && (i.context = u), r.push(i), t && l($.Paren, "]", u, f);
|
|
370
370
|
break;
|
|
371
371
|
}
|
|
372
372
|
case $.List:
|
|
373
|
-
|
|
373
|
+
d(c, u, f);
|
|
374
374
|
break;
|
|
375
375
|
case $.Named: {
|
|
376
|
-
const e = s(o,
|
|
376
|
+
const e = s(o, u, f), t = o.value;
|
|
377
377
|
e.value = t.scope ? {
|
|
378
378
|
name: t.nameId,
|
|
379
379
|
scope: t.scope
|
|
380
380
|
} : { name: t.nameId }, o.binding?.declaration && o.binding.optional && (e.value.optional = !0), o.binding && (e.type = $.Parameter, o.binding.declaration && (e.value.declaration = !0)), delete e.referenceIndex;
|
|
381
381
|
break;
|
|
382
382
|
}
|
|
383
|
-
default: void 0 !== o.value && s(o,
|
|
383
|
+
default: void 0 !== o.value && s(o, u, f), c && c.forEach((t) => e(t, u, f));
|
|
384
384
|
}
|
|
385
|
-
l($.Whitespace, o.wsAfter,
|
|
385
|
+
l($.Whitespace, o.wsAfter, u, f);
|
|
386
386
|
}
|
|
387
387
|
})(e);
|
|
388
388
|
const o = /* @__PURE__ */ new Map();
|
|
@@ -391,14 +391,14 @@ function ge(e, t = !1, n = S) {
|
|
|
391
391
|
t ? t.push(e) : o.set(e.referenceIndex, [e]);
|
|
392
392
|
}
|
|
393
393
|
for (const e of o.values()) 1 === e.length ? e[0].refSide = "self" : (e[0].refSide = "left", e[e.length - 1].refSide = "right");
|
|
394
|
-
const
|
|
394
|
+
const u = /* @__PURE__ */ new Map();
|
|
395
395
|
for (const e of r) if (void 0 !== e.referenceIndex && void 0 !== e.evalIndex) {
|
|
396
|
-
const t =
|
|
397
|
-
(void 0 === t || e.evalIndex < t) &&
|
|
396
|
+
const t = u.get(e.referenceIndex);
|
|
397
|
+
(void 0 === t || e.evalIndex < t) && u.set(e.referenceIndex, e.evalIndex);
|
|
398
398
|
}
|
|
399
|
-
if (
|
|
399
|
+
if (u.size > 0) {
|
|
400
400
|
for (const e of r) if (void 0 !== e.referenceIndex) {
|
|
401
|
-
const t =
|
|
401
|
+
const t = u.get(e.referenceIndex);
|
|
402
402
|
void 0 !== t && (e.evalIndex = t);
|
|
403
403
|
}
|
|
404
404
|
}
|
|
@@ -411,8 +411,8 @@ function ve(e, t) {
|
|
|
411
411
|
if (s === $.Cell || s === $.Named || s === $.Error) {
|
|
412
412
|
const e = s === $.Cell ? i.value?.scope : ($.Named, i.value?.scope ?? void 0), r = s === $.Error ? void 0 !== i.text && I(i.text) : i.text?.includes("!") ?? !1;
|
|
413
413
|
if (e && void 0 !== i.text && !r) {
|
|
414
|
-
const r = t?.resolve(
|
|
415
|
-
n +=
|
|
414
|
+
const r = t?.resolve(R.Sheet, e)?.toString() ?? e;
|
|
415
|
+
n += y(r) + "!" + i.text;
|
|
416
416
|
continue;
|
|
417
417
|
}
|
|
418
418
|
if (s === $.Named) {
|
|
@@ -443,7 +443,7 @@ function me(e) {
|
|
|
443
443
|
const t = function(e) {
|
|
444
444
|
if (null !== e.value && "object" == typeof e.value) return e.value;
|
|
445
445
|
const t = e.value, n = e.inputs;
|
|
446
|
-
let r = !1, i = !1, s = !1, l = !1, o = null, a = null,
|
|
446
|
+
let r = !1, i = !1, s = !1, l = !1, o = null, a = null, u = !1;
|
|
447
447
|
const f = (e) => {
|
|
448
448
|
e?.type === $.TableColumn && (o = e.value, a = e.value);
|
|
449
449
|
};
|
|
@@ -451,23 +451,23 @@ function me(e) {
|
|
|
451
451
|
const t = e.type;
|
|
452
452
|
if (t === $.TableSpecifier) {
|
|
453
453
|
const t = e.value.toUpperCase().trim();
|
|
454
|
-
"#ALL" === t ? i = !0 : "#HEADERS" === t ? s = !0 : "#TOTALS" === t ? l = !0 : "#DATA" === t ? r = !0 : "@" !== t && "#THIS ROW" !== t || (
|
|
454
|
+
"#ALL" === t ? i = !0 : "#HEADERS" === t ? s = !0 : "#TOTALS" === t ? l = !0 : "#DATA" === t ? r = !0 : "@" !== t && "#THIS ROW" !== t || (u = !0);
|
|
455
455
|
} else if (t === $.TableColumn) f(e);
|
|
456
456
|
else if (t === $.Infix && ":" === e.value) {
|
|
457
457
|
const t = e.inputs?.[0], n = e.inputs?.[1];
|
|
458
458
|
t?.type === $.TableColumn && (o = t.value), n?.type === $.TableColumn && (a = n.value);
|
|
459
459
|
} else if (t === $.Prefix && "@" === e.value) {
|
|
460
|
-
|
|
460
|
+
u = !0;
|
|
461
461
|
const t = e.inputs?.[0];
|
|
462
462
|
t?.type === $.Infix && ":" === t.value ? (t.inputs?.[0]?.type === $.TableColumn && (o = t.inputs[0].value), t.inputs?.[1]?.type === $.TableColumn && (a = t.inputs[1].value)) : f(t);
|
|
463
463
|
}
|
|
464
464
|
}
|
|
465
465
|
return {
|
|
466
466
|
tableId: t,
|
|
467
|
-
spec:
|
|
467
|
+
spec: c(i, s, r, l),
|
|
468
468
|
columnFromId: o,
|
|
469
469
|
columnToId: a,
|
|
470
|
-
isThisRow:
|
|
470
|
+
isThisRow: u
|
|
471
471
|
};
|
|
472
472
|
}(e);
|
|
473
473
|
return {
|
|
@@ -677,7 +677,7 @@ function Le(t) {
|
|
|
677
677
|
r("string" == typeof t ? t : t?.tableId);
|
|
678
678
|
} else if (e.type === $.Cell) {
|
|
679
679
|
const t = e.value?.scope;
|
|
680
|
-
i(t),
|
|
680
|
+
i(t), m(t) && r(t);
|
|
681
681
|
} else e.type === $.Error && i(e.value?.scope);
|
|
682
682
|
}), n;
|
|
683
683
|
}
|
|
@@ -910,7 +910,7 @@ function je(e, t) {
|
|
|
910
910
|
for (let t = 0; t < 1 << c; t++) {
|
|
911
911
|
const n = (e) => {
|
|
912
912
|
const r = a.indexOf(e);
|
|
913
|
-
if (-1 !== r) return
|
|
913
|
+
if (-1 !== r) return N(t & 1 << r ? "TRUE" : "FALSE");
|
|
914
914
|
const i = { ...e };
|
|
915
915
|
return delete i.evalIndex, delete i.firstCell, delete i.inLazy, delete i.lazyArg, delete i.hasLazyArgs, delete i.deferred, e.inputs && (i.inputs = e.inputs.map((e) => e ? n(e) : e)), i;
|
|
916
916
|
};
|
|
@@ -936,7 +936,7 @@ function He(e, n, r, i = !1, s = null, l = null) {
|
|
|
936
936
|
n && n.inputs && (e.inputs = n.inputs.map((e) => t.get(e) ?? e));
|
|
937
937
|
}), [t.get(e), n];
|
|
938
938
|
}(u);
|
|
939
|
-
const
|
|
939
|
+
const c = p(a), f = [], d = [], g = new de();
|
|
940
940
|
let h, m = !1;
|
|
941
941
|
(function(e, t) {
|
|
942
942
|
if (!e || !t) return;
|
|
@@ -963,14 +963,14 @@ function He(e, n, r, i = !1, s = null, l = null) {
|
|
|
963
963
|
let t = h.get(e);
|
|
964
964
|
return void 0 === t && h.set(e, t = []), t;
|
|
965
965
|
}, I = (e, t) => {
|
|
966
|
-
void 0 === e ?
|
|
966
|
+
void 0 === e ? f.push(t) : y(e).push(t);
|
|
967
967
|
}, b = (e) => {
|
|
968
968
|
e?.type !== $.Infix || "+" !== e.value && "-" !== e.value || (e.snapsCancellation = !0);
|
|
969
969
|
};
|
|
970
970
|
o = O(o, (t, n, r) => {
|
|
971
971
|
const i = t.type, s = t.evalIndex;
|
|
972
|
-
if (
|
|
973
|
-
if (m = m || !
|
|
972
|
+
if (c[s] = null, i === $.TableColumn || i === $.TableSpecifier || t.isReference && pe(r, $.TableReference)) return;
|
|
973
|
+
if (m = m || !Qe(t), t.binding?.declaration) return d[t.binding.slot] = -1, void (c[s] = void 0);
|
|
974
974
|
const l = ((e, t, n) => {
|
|
975
975
|
if (ke(e, t)) return e;
|
|
976
976
|
for (let e = n.length - 1; e >= 0; e--) if (ke(n[e], n[e - 1])) return n[e];
|
|
@@ -980,14 +980,14 @@ function He(e, n, r, i = !1, s = null, l = null) {
|
|
|
980
980
|
if (o && "let" === o.kind) {
|
|
981
981
|
const e = t.inputs, n = e?.length ?? 0;
|
|
982
982
|
let r = 0;
|
|
983
|
-
for (let t = 0; t + 1 < n && r < o.slots.length; t += 2) e[t]?.binding?.declaration && (
|
|
983
|
+
for (let t = 0; t + 1 < n && r < o.slots.length; t += 2) e[t]?.binding?.declaration && (d[o.slots[r++]] = e[t + 1]?.evalIndex ?? -1);
|
|
984
984
|
}
|
|
985
|
-
if ((t.isReference || n && n.isReference) && (
|
|
985
|
+
if ((t.isReference || n && n.isReference) && (g.processNode(t, n), t.isReference)) {
|
|
986
986
|
if (i === $.Named) return void (void 0 !== l && I(l, t));
|
|
987
987
|
if (i === $.Cell || i === $.TableReference || i === $.Error) return;
|
|
988
988
|
if (i === $.Infix || i === $.Prefix || i === $.Postfix || i === $.List) return void I(l, t);
|
|
989
989
|
}
|
|
990
|
-
if (t.isLiteral) if (i !== $.Array)
|
|
990
|
+
if (t.isLiteral) if (i !== $.Array) c[s] = t.value;
|
|
991
991
|
else {
|
|
992
992
|
const n = t.value, r = n.length, i = p(r);
|
|
993
993
|
for (let e = 0; e < r; e++) {
|
|
@@ -995,7 +995,7 @@ function He(e, n, r, i = !1, s = null, l = null) {
|
|
|
995
995
|
for (let e = 0; e < r; e++) {
|
|
996
996
|
const n = t[e];
|
|
997
997
|
let r = null;
|
|
998
|
-
if (n && (r = n.type === $.Error ?
|
|
998
|
+
if (n && (r = n.type === $.Error ? x(n.value) : n.value, n.type === $.Prefix)) {
|
|
999
999
|
const e = n.value;
|
|
1000
1000
|
r = n.inputs[0].value, "-" === e && (r = -r);
|
|
1001
1001
|
}
|
|
@@ -1003,18 +1003,18 @@ function He(e, n, r, i = !1, s = null, l = null) {
|
|
|
1003
1003
|
}
|
|
1004
1004
|
i[e] = s;
|
|
1005
1005
|
}
|
|
1006
|
-
const l =
|
|
1007
|
-
|
|
1006
|
+
const l = S(i);
|
|
1007
|
+
c[s] = new k(e, l.values, l.coords, void 0, l.isLiteral);
|
|
1008
1008
|
}
|
|
1009
1009
|
else {
|
|
1010
1010
|
if (i !== $.Empty) return "lambda" === t.binder?.kind && b(t.inputs[t.inputs.length - 1]), I(l, t), t;
|
|
1011
|
-
|
|
1011
|
+
c[s] = void 0;
|
|
1012
1012
|
}
|
|
1013
1013
|
}), b(o), h?.forEach((e, t) => {
|
|
1014
1014
|
t.deferred = e;
|
|
1015
1015
|
});
|
|
1016
|
-
const
|
|
1017
|
-
|
|
1016
|
+
const R = p(g.cells.size);
|
|
1017
|
+
g.cells.forEach((e, t) => {
|
|
1018
1018
|
const n = t.value, r = n.colIndex, i = n.rowIndex, s = n.$colIndex, l = n.$rowIndex, o = {
|
|
1019
1019
|
colStart: r,
|
|
1020
1020
|
rowStart: i,
|
|
@@ -1025,23 +1025,23 @@ function He(e, n, r, i = !1, s = null, l = null) {
|
|
|
1025
1025
|
$colEnd: s,
|
|
1026
1026
|
$rowEnd: l
|
|
1027
1027
|
};
|
|
1028
|
-
r === Number.MIN_SAFE_INTEGER && (o.colEnd = Number.MAX_SAFE_INTEGER), i === Number.MIN_SAFE_INTEGER && (o.rowEnd = Number.MAX_SAFE_INTEGER), n.scope && (o.scope = n.scope),
|
|
1028
|
+
r === Number.MIN_SAFE_INTEGER && (o.colEnd = Number.MAX_SAFE_INTEGER), i === Number.MIN_SAFE_INTEGER && (o.rowEnd = Number.MAX_SAFE_INTEGER), n.scope && (o.scope = n.scope), R[e] = o;
|
|
1029
1029
|
});
|
|
1030
|
-
const E =
|
|
1031
|
-
for (let e = 0; e < E; e++)
|
|
1030
|
+
const E = R.length, A = p(E);
|
|
1031
|
+
for (let e = 0; e < E; e++) A[e] = {
|
|
1032
1032
|
colStart: 0,
|
|
1033
1033
|
rowStart: 0,
|
|
1034
1034
|
colEnd: 0,
|
|
1035
1035
|
rowEnd: 0,
|
|
1036
1036
|
scope: null
|
|
1037
1037
|
};
|
|
1038
|
-
const
|
|
1039
|
-
|
|
1040
|
-
|
|
1038
|
+
const w = p(g.references.size);
|
|
1039
|
+
g.references.forEach((e) => {
|
|
1040
|
+
w[e.index] = e;
|
|
1041
1041
|
});
|
|
1042
|
-
const
|
|
1043
|
-
|
|
1044
|
-
|
|
1042
|
+
const C = [];
|
|
1043
|
+
g.rootReferences.forEach((e) => {
|
|
1044
|
+
C.push(e.index);
|
|
1045
1045
|
}), function(e, t, n = !1) {
|
|
1046
1046
|
if (n) {
|
|
1047
1047
|
const t = (e) => {
|
|
@@ -1103,20 +1103,20 @@ function He(e, n, r, i = !1, s = null, l = null) {
|
|
|
1103
1103
|
}
|
|
1104
1104
|
};
|
|
1105
1105
|
let F;
|
|
1106
|
-
N(
|
|
1107
|
-
const P = i ?
|
|
1106
|
+
N(f), h?.forEach(N);
|
|
1107
|
+
const P = i ? v(t(e.getLocale()).decimal) : T, L = {
|
|
1108
1108
|
runtime: e,
|
|
1109
1109
|
symbols: n,
|
|
1110
1110
|
getFunction: l,
|
|
1111
1111
|
ast: o,
|
|
1112
|
-
evaluations:
|
|
1113
|
-
executions:
|
|
1114
|
-
bindings:
|
|
1115
|
-
referencesAbsolute:
|
|
1116
|
-
referencesExecute:
|
|
1117
|
-
referencesRelative:
|
|
1118
|
-
referencesRoot:
|
|
1119
|
-
referenceIndices:
|
|
1112
|
+
evaluations: c,
|
|
1113
|
+
executions: f,
|
|
1114
|
+
bindings: d,
|
|
1115
|
+
referencesAbsolute: A,
|
|
1116
|
+
referencesExecute: w,
|
|
1117
|
+
referencesRelative: R,
|
|
1118
|
+
referencesRoot: C,
|
|
1119
|
+
referenceIndices: g.referenceIndices,
|
|
1120
1120
|
formatReferenceIndices: Te(o, l),
|
|
1121
1121
|
getTokens: () => F ??= ge(o, i, P),
|
|
1122
1122
|
namedIds: Ee(o),
|
|
@@ -1165,29 +1165,29 @@ Object.freeze([
|
|
|
1165
1165
|
">="
|
|
1166
1166
|
]
|
|
1167
1167
|
]);
|
|
1168
|
-
var
|
|
1168
|
+
var Ke = Object.freeze([
|
|
1169
1169
|
":",
|
|
1170
1170
|
".:.",
|
|
1171
1171
|
".:",
|
|
1172
1172
|
":."
|
|
1173
|
-
]),
|
|
1173
|
+
]), Ze = Object.freeze([
|
|
1174
1174
|
":",
|
|
1175
1175
|
" ",
|
|
1176
1176
|
".:.",
|
|
1177
1177
|
".:",
|
|
1178
1178
|
":."
|
|
1179
|
-
]), qe = Object.freeze(["@"]),
|
|
1179
|
+
]), qe = Object.freeze(["@"]), Ye = Object.freeze(["#"]), Je = Object.freeze(Ze.concat(Ye)), Qe = (Object.freeze(Ze.concat(qe).concat(Ye)), (e) => {
|
|
1180
1180
|
if (!e) return !1;
|
|
1181
1181
|
const t = e.type;
|
|
1182
1182
|
if (t === $.Cell) return !0;
|
|
1183
1183
|
if (t === $.TableReference) return !0;
|
|
1184
1184
|
if (t === $.Infix) {
|
|
1185
|
-
if (!
|
|
1185
|
+
if (!Ze.includes(e.value)) return !1;
|
|
1186
1186
|
const t = e.inputs, n = t[0], r = t[1];
|
|
1187
|
-
return
|
|
1187
|
+
return Qe(n) && Qe(r);
|
|
1188
1188
|
}
|
|
1189
|
-
return t === $.List && (e.inputs?.every(
|
|
1190
|
-
}), et = (e) => !!(e && (e.type === $.Infix &&
|
|
1189
|
+
return t === $.List && (e.inputs?.every(Qe) ?? !1);
|
|
1190
|
+
}), et = (e) => !!(e && (e.type === $.Infix && Je.includes(e.value) || e.type === $.Postfix && Ye.includes(e.value) || e.type === $.Array || e.type === $.TableReference)), tt = Object.freeze([
|
|
1191
1191
|
"+",
|
|
1192
1192
|
"-",
|
|
1193
1193
|
"*",
|
|
@@ -1401,7 +1401,7 @@ var Ze = Object.freeze([
|
|
|
1401
1401
|
}
|
|
1402
1402
|
return gt.test(n) && !vt.has(n.toUpperCase()) && e.image === `[${n}]` ? n : void 0;
|
|
1403
1403
|
}, mt = (e) => {
|
|
1404
|
-
const t =
|
|
1404
|
+
const t = u(e.image ?? e.value);
|
|
1405
1405
|
t.image = e.image ?? e.value, t.wsBefore = e.wsBefore;
|
|
1406
1406
|
const n = {
|
|
1407
1407
|
type: $.Call,
|
|
@@ -1596,7 +1596,7 @@ var Tt = (e) => {
|
|
|
1596
1596
|
const t = e.value;
|
|
1597
1597
|
return t.rowIndex === Number.MIN_SAFE_INTEGER && !0 !== t.$colIndex && !t.scope;
|
|
1598
1598
|
}, At = (e) => {
|
|
1599
|
-
const t =
|
|
1599
|
+
const t = u(e.image);
|
|
1600
1600
|
return V(t, e), t;
|
|
1601
1601
|
}, St = (e) => e?.type === $.Cell, wt = (e, t = null) => {
|
|
1602
1602
|
if (!e) return e;
|
|
@@ -1617,7 +1617,7 @@ var Tt = (e) => {
|
|
|
1617
1617
|
const t = e.value, n = e.image;
|
|
1618
1618
|
if (!0 === t?.$colIndex || !0 === t?.$rowIndex) return void (i ??= `'${n ?? "a reference"}' cannot be absolute here. A LET/LAMBDA name that is a cell reference makes every reference in the formula a name, and a name cannot contain '$'.`);
|
|
1619
1619
|
if (void 0 === n) return;
|
|
1620
|
-
const r =
|
|
1620
|
+
const r = u(n);
|
|
1621
1621
|
V(r, e);
|
|
1622
1622
|
const s = t?.scope;
|
|
1623
1623
|
return s && (r.value.scope = s, r.value.scopeImage = t.scopeImage), r;
|
|
@@ -1655,7 +1655,7 @@ var Tt = (e) => {
|
|
|
1655
1655
|
function Nt(e, t, n, r, i) {
|
|
1656
1656
|
const s = r;
|
|
1657
1657
|
let l;
|
|
1658
|
-
const o = () => (void 0 === l && (l = i && n ? t.bind(
|
|
1658
|
+
const o = () => (void 0 === l && (l = i && n ? t.bind(R.Table, "", { at: {
|
|
1659
1659
|
scope: n,
|
|
1660
1660
|
rowIndex: i.rowIndex,
|
|
1661
1661
|
colIndex: i.colIndex
|
|
@@ -1666,7 +1666,7 @@ function Nt(e, t, n, r, i) {
|
|
|
1666
1666
|
if (a === $.Cell) {
|
|
1667
1667
|
const n = e.value;
|
|
1668
1668
|
if (n?.scope) {
|
|
1669
|
-
const r = t.bind(
|
|
1669
|
+
const r = t.bind(R.Sheet, n.scope, s);
|
|
1670
1670
|
null !== r && (l || (l = { ...e }), l.value = {
|
|
1671
1671
|
...n,
|
|
1672
1672
|
scope: r
|
|
@@ -1677,10 +1677,10 @@ function Nt(e, t, n, r, i) {
|
|
|
1677
1677
|
if (r && !e.binding) {
|
|
1678
1678
|
const i = function(e, t, n, r) {
|
|
1679
1679
|
if (t.scope) {
|
|
1680
|
-
const e = n.bind(
|
|
1681
|
-
if (null === e ||
|
|
1680
|
+
const e = n.bind(R.Sheet, t.scope, r);
|
|
1681
|
+
if (null === e || L(e)) return;
|
|
1682
1682
|
}
|
|
1683
|
-
const i = n.bind(
|
|
1683
|
+
const i = n.bind(R.Table, t.nameId, { existing: !0 });
|
|
1684
1684
|
if (null === i) return;
|
|
1685
1685
|
const s = {
|
|
1686
1686
|
type: $.TableReference,
|
|
@@ -1693,7 +1693,7 @@ function Nt(e, t, n, r, i) {
|
|
|
1693
1693
|
return "string" == typeof l && void 0 !== e.image && (s.image = l + e.image), s;
|
|
1694
1694
|
}(e, r, t, s);
|
|
1695
1695
|
if (i) return i;
|
|
1696
|
-
const o = r.scope ? t.bind(
|
|
1696
|
+
const o = r.scope ? t.bind(R.Sheet, r.scope, s) : null, a = (null !== o ? L(o) ? o : t.resolve(R.Sheet, o)?.toString() ?? r.scope : r.scope) ?? n, u = t.bind(R.NamedFormula, r.nameId, a ? { scope: a } : void 0);
|
|
1697
1697
|
null === u && null === o || (l || (l = { ...e }), l.value = {
|
|
1698
1698
|
...r,
|
|
1699
1699
|
nameId: u ?? r.nameId,
|
|
@@ -1703,7 +1703,7 @@ function Nt(e, t, n, r, i) {
|
|
|
1703
1703
|
} else if (a === $.Error) {
|
|
1704
1704
|
const n = e.value;
|
|
1705
1705
|
if (n?.scope) {
|
|
1706
|
-
const r = t.bind(
|
|
1706
|
+
const r = t.bind(R.Sheet, n.scope, s);
|
|
1707
1707
|
null !== r && (l || (l = { ...e }), l.value = {
|
|
1708
1708
|
...n,
|
|
1709
1709
|
scope: r
|
|
@@ -1712,7 +1712,7 @@ function Nt(e, t, n, r, i) {
|
|
|
1712
1712
|
} else if (a === $.TableReference) {
|
|
1713
1713
|
const n = e.value;
|
|
1714
1714
|
if (n) {
|
|
1715
|
-
const r = t.bind(
|
|
1715
|
+
const r = t.bind(R.Table, n);
|
|
1716
1716
|
l || (l = { ...e }), null !== r && (l.value = r);
|
|
1717
1717
|
} else if ("string" == typeof n) {
|
|
1718
1718
|
const n = o();
|
|
@@ -1724,13 +1724,13 @@ function Nt(e, t, n, r, i) {
|
|
|
1724
1724
|
} else if (a === $.TableColumn) {
|
|
1725
1725
|
const n = e.value;
|
|
1726
1726
|
if (n) {
|
|
1727
|
-
const r = pe(i, $.TableReference), s = r?.value || (r ? o() ?? void 0 : void 0), a = t.bind(
|
|
1727
|
+
const r = pe(i, $.TableReference), s = r?.value || (r ? o() ?? void 0 : void 0), a = t.bind(R.TableColumn, n, s ? { tableName: s } : void 0);
|
|
1728
1728
|
l || (l = { ...e }), null !== a && (l.value = a);
|
|
1729
1729
|
}
|
|
1730
1730
|
} else if (a === $.Function) {
|
|
1731
1731
|
const n = e.value;
|
|
1732
1732
|
if (n) {
|
|
1733
|
-
const r = t.bind(
|
|
1733
|
+
const r = t.bind(R.Function, n);
|
|
1734
1734
|
l || (l = { ...e }), null !== r && (l.value = r);
|
|
1735
1735
|
}
|
|
1736
1736
|
}
|
|
@@ -1742,7 +1742,7 @@ function Ft(e, t) {
|
|
|
1742
1742
|
const r = e.inputs;
|
|
1743
1743
|
if (!r) return !0;
|
|
1744
1744
|
for (let e = 0; e < r.length && n; e++) O(r[e], (e) => {
|
|
1745
|
-
e.type === $.TableColumn && null === t.resolve(
|
|
1745
|
+
e.type === $.TableColumn && null === t.resolve(R.TableColumn, e.value) && (n = !1);
|
|
1746
1746
|
});
|
|
1747
1747
|
return n;
|
|
1748
1748
|
}
|
|
@@ -1753,8 +1753,8 @@ function Pt(e, t) {
|
|
|
1753
1753
|
if ("" === e.value) return void (n = "A structured reference without a table name must be in a table that has its columns.");
|
|
1754
1754
|
const r = e.value;
|
|
1755
1755
|
if (!t || "string" != typeof r) return;
|
|
1756
|
-
const i = t.resolve(
|
|
1757
|
-
null === t.bind(
|
|
1756
|
+
const i = t.resolve(R.Table, r)?.toString() ?? r;
|
|
1757
|
+
null === t.bind(R.Table, i, { existing: !0 }) ? n = `There is no table named '${i}'.` : Ft(e, t) || (n = "The table has no such column.");
|
|
1758
1758
|
}), n;
|
|
1759
1759
|
}
|
|
1760
|
-
export { ye as A, je as C, ut as D, ue as E, ve as O, it as S, me as T, et as _, It as a, ge as b, Re as c,
|
|
1760
|
+
export { ye as A, je as C, ut as D, ue as E, ve as O, it as S, me as T, et as _, It as a, ge as b, Re as c, Ke as d, ae as f, ct as g, ce as h, Ie as i, yt as j, wt as k, We as l, be as m, Et as n, Nt as o, at as p, He as r, Pt as s, Ct as t, Xe as u, fe as v, st as w, he as x, ft as y };
|