@sheetxl/scripting 0.7.6 → 0.7.7

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/LICENSE.md CHANGED
@@ -8,4 +8,4 @@ Generally, packages intended for public distribution (such as CLIs, adapters, an
8
8
 
9
9
  For more details on commercial licensing, please visit our website:
10
10
 
11
- https://www.sheetxl.com/licensing-pricing
11
+ https://www.sheetxl.com/docs/guides/licensing-pricing
package/README.md CHANGED
@@ -1,10 +1,10 @@
1
+ # SheetXL — the api-first spreadsheet
2
+
1
3
  <p align="center">
2
4
  <img src="./static/img/social-light.png#gh-light-mode-only">
3
5
  <img src="./static/img/social-dark.png#gh-dark-mode-only">
4
6
  </p>
5
7
 
6
- # SheetXL — the api-first spreadsheet
7
-
8
8
  [![Discord](https://img.shields.io/discord/1141404921246257223)](https://discord.gg/NTKdwUgK9p)
9
9
  [![npm (tag)](https://img.shields.io/npm/v/@sheetxl/studio-mui/latest?color=blue)](https://www.npmjs.com/package/@sheetxl/studio-mui)
10
10
  [![npm](https://img.shields.io/npm/dt/@sheetxl/studio-mui)](https://www.npmjs.com/package/@sheetxl/studio-mui)
@@ -1,6 +1,6 @@
1
1
  "use strict";/**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
6
- */Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});exports.TypeScriptCompiler=class{constructor(r={}){this.workerWrapper=null}async getWorkerWrapper(){if(this.workerWrapper)return this.workerWrapper;const{createCompilerWorker:r}=await Promise.resolve().then(()=>require("./zgssxHJ3y5-QRGBL.cjs"));return this.workerWrapper=await r(),this.workerWrapper}async compileModule(r){try{return(await this.getWorkerWrapper()).execute(r)}catch(e){throw console.error("Failed to compile using worker:",e),e}}terminate(){this.workerWrapper?.terminate(),this.workerWrapper=null}};
6
+ */Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});exports.TypeScriptCompiler=class{constructor(r={}){this.workerWrapper=null}async getWorkerWrapper(){if(this.workerWrapper)return this.workerWrapper;const{createCompilerWorker:r}=await Promise.resolve().then(()=>require("./CmwVJ12fmXamRf6z.cjs"));return this.workerWrapper=await r(),this.workerWrapper}async compileModule(r){try{return(await this.getWorkerWrapper()).execute(r)}catch(e){throw console.error("Failed to compile using worker:",e),e}}terminate(){this.workerWrapper?.terminate(),this.workerWrapper=null}};
@@ -1,5 +1,5 @@
1
1
  "use strict";/**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -1,9 +1,9 @@
1
1
  "use strict";/**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
6
- */Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const $=require("@sheetxl/primitives"),ae=require("@sheetxl/utils");let L=null,I=null;const oe={compilerOptions:{target:"esnext"}};async function le(h,x,b="/script.js",w="__SHEETXL"){try{const K=await(async function(){if(L)return L;if(I){if(await I,!L)throw new Error("ESBuild initialization promise resolved, but instance is not available.");return L}let p,T;I=new Promise((a,S)=>{p=a,T=S});try{const{initialize:a}=await Promise.resolve().then(()=>require("./BHP1BlRoa-6TNjiB.cjs"));return L=await a(),p(),L}catch(a){throw console.error("Failed to import or initialize esbuild:",a),I=null,T(a),a}})(),j="@sheetxl/primitives",n=`
6
+ */Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const $=require("@sheetxl/primitives"),ae=require("@sheetxl/utils");let L=null,I=null;const oe={compilerOptions:{target:"esnext"}};async function le(h,x,b="/script.js",w="__SHEETXL"){try{const K=await(async function(){if(L)return L;if(I){if(await I,!L)throw new Error("ESBuild initialization promise resolved, but instance is not available.");return L}let p,T;I=new Promise((a,S)=>{p=a,T=S});try{const{initialize:a}=await Promise.resolve().then(()=>require("./DDZSJh2MW9EeyEFt.cjs"));return L=await a(),p(),L}catch(a){throw console.error("Failed to import or initialize esbuild:",a),I=null,T(a),a}})(),j="@sheetxl/primitives",n=`
7
7
  export const FormulaContext = globalThis.${w}?.FormulaContext;
8
8
  export const ScalarType = globalThis.${w}?.ScalarType;
9
9
  export const Observable = globalThis.${w}?.Observable;
@@ -15,7 +15,7 @@
15
15
  interface FirstTest {
16
16
  isTrue?: boolean;
17
17
  }
18
- `,Y=new Map([["IReferenceRange","r"],["IRange","l"]]),Z=new Map([["IWorkbook","workbook"],["ISheet","sheet"],["ICellRanges","ranges"],["ICellRange","range"],["IFormulaContext","context"]]),V=(h,x)=>{Array.from(x.keys()).forEach(b=>{const w=x.get(b);x.set(`${h}.${b}`,w)})},ce=new Map([["Scalar","*"],["FormulaError.Known",$.ScalarType.Error],["Date","Date"],["JSON","JSON"]]),de=new Map([]),X="SheetXL";V(X,Y),V(X,Z),V(X,de);const ue=new Map([["Promise",()=>({async:!0})],["Observable",()=>({stream:!0})]]);let q=null;async function pe(){if(q)return q;try{return await(await Promise.resolve().then(()=>require("./ClckkFntgsqMKeYG.cjs"))).initialize()}catch(h){throw q=null,h}finally{q=null}}exports.compileModule=async function(h){const x=h?.source??null;if(!x)return null;const b=(h.disableBundle||h.declarationsOnly)??!1,w=[se(),pe()],K=await Promise.all(w),j=K[0],n=K[1];let F="",f=null;const p=[],T={allowJs:!0,declaration:!1,sourceMap:!1,inlineSourceMap:!1,inlineSources:!1,isolatedModules:!0,preserveConstEnums:!1,module:99,noResolve:!0,emitDeclarationOnly:!1,target:n.ScriptTarget.ES2020},a="script",S=`${a}.ts`,_="lib.d.ts",H="global.d.ts",M={[S]:x,[_]:`
18
+ `,Y=new Map([["IReferenceRange","r"],["IRange","l"]]),Z=new Map([["IWorkbook","workbook"],["ISheet","sheet"],["ICellRanges","ranges"],["ICellRange","range"],["IFormulaContext","context"]]),V=(h,x)=>{Array.from(x.keys()).forEach(b=>{const w=x.get(b);x.set(`${h}.${b}`,w)})},ce=new Map([["Scalar","*"],["FormulaError.Known",$.ScalarType.Error],["Date","Date"],["JSON","JSON"]]),de=new Map([]),X="SheetXL";V(X,Y),V(X,Z),V(X,de);const ue=new Map([["Promise",()=>({async:!0})],["Observable",()=>({stream:!0})]]);let q=null;async function pe(){if(q)return q;try{return await(await Promise.resolve().then(()=>require("./CT1xY3Cwu-Td-CM6.cjs"))).initialize()}catch(h){throw q=null,h}finally{q=null}}exports.compileModule=async function(h){const x=h?.source??null;if(!x)return null;const b=(h.disableBundle||h.declarationsOnly)??!1,w=[se(),pe()],K=await Promise.all(w),j=K[0],n=K[1];let F="",f=null;const p=[],T={allowJs:!0,declaration:!1,sourceMap:!1,inlineSourceMap:!1,inlineSources:!1,isolatedModules:!0,preserveConstEnums:!1,module:99,noResolve:!0,emitDeclarationOnly:!1,target:n.ScriptTarget.ES2020},a="script",S=`${a}.ts`,_="lib.d.ts",H="global.d.ts",M={[S]:x,[_]:`
19
19
  /**
20
20
  * Represents the completion of an asynchronous operation
21
21
  */
@@ -1,10 +1,10 @@
1
1
  "use strict";/**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
6
6
  */Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});let c=class{constructor(e){this._worker=null,this._nextId=1,this._pendingRequests=new Map,this._workerFactory=e}start(){if(typeof Worker>"u")throw new Error("Web Workers are not supported in this environment.");return this._worker||(this._worker=this._workerFactory(),this._worker.onmessage=e=>{const{id:n,result:t,error:r}=e.data,o=this._pendingRequests.get(n);if(o)if(this._pendingRequests.delete(n),r){const a=new Error(r.message);a.stack=r.stack,r.cause&&(a.cause=r.cause),o.reject(a)}else o.resolve(t)},this._worker.onerror=e=>{console.error("Worker error:",e),this._pendingRequests.forEach(n=>{n.reject(new Error(`Worker failed: ${e.message}`))}),this._pendingRequests.clear(),this._worker=null}),Promise.resolve()}execute(e){if(!this._worker)throw new Error("Worker is not initialized. Call start() first.");const n=this._nextId++;return new Promise((t,r)=>{this._pendingRequests.set(n,{resolve:t,reject:r}),this._worker.postMessage({id:n,params:e})})}terminate(){this._worker&&(this._worker.terminate(),this._worker=null)}};class u{constructor(n){this._onExecute=n}execute(n){return this._onExecute(n)}start(){return Promise.resolve()}terminate(){}}const s=`/**
7
- * @license @sheetxl/primitives - Primitives - Base types for SheetXL functions. - v0.7.6
7
+ * @license @sheetxl/primitives - Primitives - Base types for SheetXL functions. - v0.7.7
8
8
  *
9
9
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
10
10
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -223,7 +223,7 @@ var T;
223
223
  return r = typeof e == "string" ? rt.get(e) : ot.get(e), r || (r = T.Unknown), new r(t, n);
224
224
  }, T.getBuiltInById = (e) => Te.get(e) || xt;
225
225
  /**
226
- * @license @sheetxl/utils - Utils - Utilities used by most SheetXL components. - v0.7.6
226
+ * @license @sheetxl/utils - Utils - Utilities used by most SheetXL components. - v0.7.7
227
227
  *
228
228
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
229
229
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -406,7 +406,7 @@ const Ft = Object.freeze([]), Dt = Object.freeze({}), ze = (e) => e, de = () =>
406
406
  ut(e[i], t?.[i], n) === null && (o = !0, delete e[i]);
407
407
  }
408
408
  return o && Object.keys(e).length === 0 ? null : void 0;
409
- }, Ke = typeof performance == "object" && typeof performance.now == "function" ? () => performance.now() : () => Date.now(), Ve = (e) => e == null, qe = (e, t) => !(t.left > e.right || t.right < e.left || t.top > e.bottom || t.bottom < e.top), Ge = !(typeof window > "u" || !window.document || !window.document.createElement), k = { Windows: "windows", MacOS: "macos", IOS: "ios", Linux: "linux", Android: "android", Safari: "safari", Firefox: "firefox", Node: "node", Unknown: "unknown" }, oe = () => {
409
+ }, Ke = typeof performance == "object" && typeof performance.now == "function" ? () => performance.now() : () => Date.now(), Ve = (e) => e == null, Ge = (e, t) => !(t.left > e.right || t.right < e.left || t.top > e.bottom || t.bottom < e.top), qe = !(typeof window > "u" || !window.document || !window.document.createElement), k = { Windows: "windows", MacOS: "macos", IOS: "ios", Linux: "linux", Android: "android", Safari: "safari", Firefox: "firefox", Node: "node", Unknown: "unknown" }, oe = () => {
410
410
  if (dt()) return k.Node;
411
411
  const e = globalThis.navigator !== void 0 && globalThis.navigator.userAgent ? globalThis.navigator.userAgent.toLowerCase() : "";
412
412
  return e ? /(win32|win64|windows|wince)/i.test(e) ? k.Windows : /(macintosh|macintel|macppc|mac68k|macos)/i.test(e) ? k.MacOS : /(iphone|ipad|ipod)/i.test(e) ? k.IOS : /android/.test(e) ? k.Android : /linux/.test(e) ? k.Linux : /^((?!chrome|android|).)*safari/i.test(e) ? k.Safari : /^((?!chrome|android|Seamonkey).)*firefox/i.test(e) ? k.Firefox : k.Unknown : k.Unknown;
@@ -422,7 +422,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
422
422
  return Number.isFinite(t) ? t : 0;
423
423
  }, camelToPrettyCase: (e) => e.length === 1 ? e.toUpperCase() : e.replace(/([A-Z])/g, " $1").replace(/^./, function(t) {
424
424
  return t.toUpperCase();
425
- }).trim(), canUseDOM: Ge, cancelTimeout: (e) => {
425
+ }).trim(), canUseDOM: qe, cancelTimeout: (e) => {
426
426
  cancelAnimationFrame(e.id);
427
427
  }, castToString: (e) => e == null || e === void 0 ? "" : typeof e != "string" ? "" + e : e, cloneObject: (e) => Ve(e) ? e : JSON.parse(JSON.stringify(e)), consoleWithNoSource: (...e) => new Promise((t) => {
428
428
  setTimeout(() => {
@@ -537,7 +537,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
537
537
  }, isNode: dt, isNullOrUndefined: Ve, isNumeric: (e) => {
538
538
  const t = 1 * e;
539
539
  return Number.isFinite(t) && typeof t == "number";
540
- }, isObject: ne, isPromiseLike: (e) => !!e && typeof e.then == "function", isRectInsideRect: (e, t) => e.top >= t.top && e.bottom <= t.bottom && e.left >= t.left && e.right <= t.right, isRectIntersect: qe, mergeContentful: (...e) => {
540
+ }, isObject: ne, isPromiseLike: (e) => !!e && typeof e.then == "function", isRectInsideRect: (e, t) => e.top >= t.top && e.bottom <= t.bottom && e.left >= t.left && e.right <= t.right, isRectIntersect: Ge, mergeContentful: (...e) => {
541
541
  const t = e.length;
542
542
  if (t > 0 && e[t - 1] !== void 0 && !ne(e[t - 1])) return e[t - 1];
543
543
  let n = e[0] || {};
@@ -550,7 +550,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
550
550
  e();
551
551
  });
552
552
  }, openFileDialog: (e = "*.*") => new Promise((t, n) => {
553
- if (!Ge) return void n("Unable to open dialog with no dom.");
553
+ if (!qe) return void n("Unable to open dialog with no dom.");
554
554
  const r = document.createElement("input");
555
555
  r.type = "file", r.accept = e;
556
556
  let o = null, a = !1;
@@ -604,7 +604,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
604
604
  return { ip: Math.trunc(e), fp: o, ipLength: Math.ceil(Math.log10(n + 1)), fpLength: a };
605
605
  }, subtractRect: (e, t, n = !1) => {
606
606
  if (!t) return [e];
607
- if (!qe(e, t)) return [];
607
+ if (!Ge(e, t)) return [];
608
608
  const r = [];
609
609
  let o = e;
610
610
  const a = () => {
@@ -1042,9 +1042,9 @@ class tt {
1042
1042
  }
1043
1043
  var Ee;
1044
1044
  (Ee = tt || (tt = {})).ErrorMessages = mt, Ee.Global = new Ee();
1045
- const qt = "__SHEETXL";
1045
+ const Gt = "__SHEETXL";
1046
1046
  let ee = null, le = null;
1047
- async function Gt() {
1047
+ async function qt() {
1048
1048
  if (ee)
1049
1049
  return ee;
1050
1050
  if (le) {
@@ -1071,9 +1071,9 @@ const Wt = {
1071
1071
  target: "esnext"
1072
1072
  }
1073
1073
  };
1074
- async function Yt(e, t, n = "/script.js", r = qt) {
1074
+ async function Yt(e, t, n = "/script.js", r = Gt) {
1075
1075
  try {
1076
- const o = await Gt(), a = "@sheetxl/primitives", i = \`
1076
+ const o = await qt(), a = "@sheetxl/primitives", i = \`
1077
1077
  export const FormulaContext = globalThis.\${r}?.FormulaContext;
1078
1078
  export const ScalarType = globalThis.\${r}?.ScalarType;
1079
1079
  export const Observable = globalThis.\${r}?.Observable;
@@ -1280,8 +1280,8 @@ async function nn(e) {
1280
1280
  const M = s.typeName?.getText?.() ?? null, K = yt.get(M);
1281
1281
  let V = !1;
1282
1282
  K && (m.range = K, V = !0);
1283
- const q = Zt.get(M);
1284
- if (q && (m.scalar = q), q !== void 0 && (V = !0), P) {
1283
+ const G = Zt.get(M);
1284
+ if (G && (m.scalar = G), G !== void 0 && (V = !0), P) {
1285
1285
  const R = gt.get(M);
1286
1286
  if (R)
1287
1287
  return R;
@@ -1328,8 +1328,8 @@ async function nn(e) {
1328
1328
  }
1329
1329
  const V = {};
1330
1330
  c(s.type, V, m, !1), m.returnType = V;
1331
- const q = {};
1332
- fe(s) && (q.default = !0, u = P), Object.keys(q).length > 0 && (m.behavior = q), m.parameters = [];
1331
+ const G = {};
1332
+ fe(s) && (G.default = !0, u = P), Object.keys(G).length > 0 && (m.behavior = G), m.parameters = [];
1333
1333
  const H = /* @__PURE__ */ new Map();
1334
1334
  for (let R = 0; R < s.parameters.length; R++) {
1335
1335
  const b = s.parameters[R], N = {};
@@ -1355,8 +1355,8 @@ async function nn(e) {
1355
1355
  b.dotDotDotToken && (N.rest = !0), m.parameters.push(N);
1356
1356
  const C = { description: "" };
1357
1357
  L.parameters[N.name] = C;
1358
- const G = I.getSymbolAtLocation(b.name).getDocumentationComment(I);
1359
- G && G.length > 0 && G[0].text && (C.description = G[0].text), v !== void 0 && (C.defaultValue = v), H.set(N.name, N);
1358
+ const q = I.getSymbolAtLocation(b.name).getDocumentationComment(I);
1359
+ q && q.length > 0 && q[0].text && (C.description = q[0].text), v !== void 0 && (C.defaultValue = v), H.set(N.name, N);
1360
1360
  }
1361
1361
  if (s.jsDoc && s.jsDoc.length > 0) {
1362
1362
  const R = s.jsDoc;
@@ -1369,8 +1369,8 @@ async function nn(e) {
1369
1369
  if (!v) continue;
1370
1370
  v = v.toLowerCase();
1371
1371
  let C = z.comment;
1372
- const G = v === "hidden";
1373
- if (!(typeof C != "string" && !G) && (typeof C == "string" && (C = C.replace(/[\\r\\n]+/g, "\\\\n").trim()), !(!G && C && (C = C.split(/\\\\n/)[0], !C || C.length === 0)))) {
1372
+ const q = v === "hidden";
1373
+ if (!(typeof C != "string" && !q) && (typeof C == "string" && (C = C.replace(/[\\r\\n]+/g, "\\\\n").trim()), !(!q && C && (C = C.split(/\\\\n/)[0], !C || C.length === 0)))) {
1374
1374
  if (C && typeof C == "string") {
1375
1375
  const O = /\\{@link(code|plain)?\\s+([^}|]+)(?:\\s*\\|\\s*([^}]+))?\\}/g;
1376
1376
  let F, Z = C, te = [];
@@ -1505,4 +1505,4 @@ var ln = /* @__PURE__ */ Object.freeze({
1505
1505
  __proto__: null,
1506
1506
  initialize: an
1507
1507
  });
1508
- `,i=typeof self<"u"&&self.Blob&&new Blob(["URL.revokeObjectURL(import.meta.url);",s],{type:"text/javascript;charset=utf-8"});function d(e){let n;try{if(n=i&&(self.URL||self.webkitURL).createObjectURL(i),!n)throw"";const t=new Worker(n,{type:"module",name:e?.name});return t.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(n)}),t}catch{return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(s),{type:"module",name:e?.name})}}const l=async()=>{const{compileModule:e}=await Promise.resolve().then(()=>require("./p_nv7_x7esy4lWPH.cjs")),n=new u(t=>e(t));return await n.start(),n};exports.createCompilerWorker=async function(){if(typeof process<"u"&&process.versions?.node&&typeof Worker>"u")return await l();if(typeof Worker<"u"){const e=new c(()=>new d);try{return await e.start(),e}catch(n){console.error("Failed to start TypescriptCompiler worker reverting to fallback:",n)}}return await l()};
1508
+ `,i=typeof self<"u"&&self.Blob&&new Blob(["URL.revokeObjectURL(import.meta.url);",s],{type:"text/javascript;charset=utf-8"});function d(e){let n;try{if(n=i&&(self.URL||self.webkitURL).createObjectURL(i),!n)throw"";const t=new Worker(n,{type:"module",name:e?.name});return t.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(n)}),t}catch{return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(s),{type:"module",name:e?.name})}}const l=async()=>{const{compileModule:e}=await Promise.resolve().then(()=>require("./CiIdIxdpoLPl0QH4.cjs")),n=new u(t=>e(t));return await n.start(),n};exports.createCompilerWorker=async function(){if(typeof process<"u"&&process.versions?.node&&typeof Worker>"u")return await l();if(typeof Worker<"u"){const e=new c(()=>new d);try{return await e.start(),e}catch(n){console.error("Failed to start TypescriptCompiler worker reverting to fallback:",n)}}return await l()};
@@ -1,5 +1,5 @@
1
1
  "use strict";/**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -1,6 +1,6 @@
1
1
  "use strict";/**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
6
- */Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("@sheetxl/utils");let l=null,n=null,t=null;const c=Object.freeze({compileTypescript:async function(e){if(!(e?.source??null))return null;if(n&&u.CommonUtils.deepEqual(n,e))return l;const i=await(async function(){if(t)return t;const{TypeScriptCompiler:o}=await Promise.resolve().then(()=>require("./DkOTSThyA5u-_ub9.cjs"));return t=new o,t})(),r=await i.compileModule(e);return l=r,n=e,r}});exports.ScriptingUtils=c;
6
+ */Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("@sheetxl/utils");let l=null,n=null,t=null;const c=Object.freeze({compileTypescript:async function(e){if(!(e?.source??null))return null;if(n&&u.CommonUtils.deepEqual(n,e))return l;const i=await(async function(){if(t)return t;const{TypeScriptCompiler:o}=await Promise.resolve().then(()=>require("./CD_eKDY2mH4ZM0cy.cjs"));return t=new o,t})(),r=await i.compileModule(e);return l=r,n=e,r}});exports.ScriptingUtils=c;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -10,7 +10,7 @@ class o {
10
10
  }
11
11
  async getWorkerWrapper() {
12
12
  if (this.workerWrapper) return this.workerWrapper;
13
- const { createCompilerWorker: r } = await import("./Dvs1M5VqWGsB57ia.mjs");
13
+ const { createCompilerWorker: r } = await import("./vvybfUGaTdABW0HS.mjs");
14
14
  return this.workerWrapper = await r(), this.workerWrapper;
15
15
  }
16
16
  async compileModule(r) {
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -1,7 +1,7 @@
1
1
  import { ScalarType as v } from "@sheetxl/primitives";
2
2
  import { CommonUtils as ae } from "@sheetxl/utils";
3
3
  /**
4
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
4
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
5
5
  *
6
6
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
7
7
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -21,7 +21,7 @@ async function le(h, x, S = "/script.js", w = "__SHEETXL") {
21
21
  p = a, b = T;
22
22
  });
23
23
  try {
24
- const { initialize: a } = await import("./ClVFYkRxs47p7BBT.mjs");
24
+ const { initialize: a } = await import("./BUF0Pno6maQY6Flb.mjs");
25
25
  return L = await a(), p(), L;
26
26
  } catch (a) {
27
27
  throw console.error("Failed to import or initialize esbuild:", a), P = null, b(a), a;
@@ -70,7 +70,7 @@ let B = null;
70
70
  async function pe() {
71
71
  if (B) return B;
72
72
  try {
73
- return await (await import("./C0113WDySNJZE9ry.mjs")).initialize();
73
+ return await (await import("./BDtaHsISNNpG3081.mjs")).initialize();
74
74
  } catch (h) {
75
75
  throw B = null, h;
76
76
  } finally {
@@ -1,6 +1,6 @@
1
1
  import { CommonUtils as u } from "@sheetxl/utils";
2
2
  /**
3
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
3
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
4
4
  *
5
5
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
6
6
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -11,7 +11,7 @@ const p = Object.freeze({ compileTypescript: async function(t) {
11
11
  if (n && u.deepEqual(n, t)) return i;
12
12
  const l = await (async function() {
13
13
  if (e) return e;
14
- const { TypeScriptCompiler: o } = await import("./BTRF2gIszLyzwiU7.mjs");
14
+ const { TypeScriptCompiler: o } = await import("./BGjJqv_yJOQXsdHA.mjs");
15
15
  return e = new o(), e;
16
16
  })(), r = await l.compileModule(t);
17
17
  return i = r, n = t, r;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -47,7 +47,7 @@ class u {
47
47
  }
48
48
  }
49
49
  const s = `/**
50
- * @license @sheetxl/primitives - Primitives - Base types for SheetXL functions. - v0.7.6
50
+ * @license @sheetxl/primitives - Primitives - Base types for SheetXL functions. - v0.7.7
51
51
  *
52
52
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
53
53
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -266,7 +266,7 @@ var T;
266
266
  return r = typeof e == "string" ? rt.get(e) : ot.get(e), r || (r = T.Unknown), new r(t, n);
267
267
  }, T.getBuiltInById = (e) => Te.get(e) || xt;
268
268
  /**
269
- * @license @sheetxl/utils - Utils - Utilities used by most SheetXL components. - v0.7.6
269
+ * @license @sheetxl/utils - Utils - Utilities used by most SheetXL components. - v0.7.7
270
270
  *
271
271
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
272
272
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -449,7 +449,7 @@ const Ft = Object.freeze([]), Dt = Object.freeze({}), ze = (e) => e, de = () =>
449
449
  ut(e[i], t?.[i], n) === null && (o = !0, delete e[i]);
450
450
  }
451
451
  return o && Object.keys(e).length === 0 ? null : void 0;
452
- }, Ke = typeof performance == "object" && typeof performance.now == "function" ? () => performance.now() : () => Date.now(), Ve = (e) => e == null, qe = (e, t) => !(t.left > e.right || t.right < e.left || t.top > e.bottom || t.bottom < e.top), Ge = !(typeof window > "u" || !window.document || !window.document.createElement), k = { Windows: "windows", MacOS: "macos", IOS: "ios", Linux: "linux", Android: "android", Safari: "safari", Firefox: "firefox", Node: "node", Unknown: "unknown" }, oe = () => {
452
+ }, Ke = typeof performance == "object" && typeof performance.now == "function" ? () => performance.now() : () => Date.now(), Ve = (e) => e == null, Ge = (e, t) => !(t.left > e.right || t.right < e.left || t.top > e.bottom || t.bottom < e.top), qe = !(typeof window > "u" || !window.document || !window.document.createElement), k = { Windows: "windows", MacOS: "macos", IOS: "ios", Linux: "linux", Android: "android", Safari: "safari", Firefox: "firefox", Node: "node", Unknown: "unknown" }, oe = () => {
453
453
  if (dt()) return k.Node;
454
454
  const e = globalThis.navigator !== void 0 && globalThis.navigator.userAgent ? globalThis.navigator.userAgent.toLowerCase() : "";
455
455
  return e ? /(win32|win64|windows|wince)/i.test(e) ? k.Windows : /(macintosh|macintel|macppc|mac68k|macos)/i.test(e) ? k.MacOS : /(iphone|ipad|ipod)/i.test(e) ? k.IOS : /android/.test(e) ? k.Android : /linux/.test(e) ? k.Linux : /^((?!chrome|android|).)*safari/i.test(e) ? k.Safari : /^((?!chrome|android|Seamonkey).)*firefox/i.test(e) ? k.Firefox : k.Unknown : k.Unknown;
@@ -465,7 +465,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
465
465
  return Number.isFinite(t) ? t : 0;
466
466
  }, camelToPrettyCase: (e) => e.length === 1 ? e.toUpperCase() : e.replace(/([A-Z])/g, " $1").replace(/^./, function(t) {
467
467
  return t.toUpperCase();
468
- }).trim(), canUseDOM: Ge, cancelTimeout: (e) => {
468
+ }).trim(), canUseDOM: qe, cancelTimeout: (e) => {
469
469
  cancelAnimationFrame(e.id);
470
470
  }, castToString: (e) => e == null || e === void 0 ? "" : typeof e != "string" ? "" + e : e, cloneObject: (e) => Ve(e) ? e : JSON.parse(JSON.stringify(e)), consoleWithNoSource: (...e) => new Promise((t) => {
471
471
  setTimeout(() => {
@@ -580,7 +580,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
580
580
  }, isNode: dt, isNullOrUndefined: Ve, isNumeric: (e) => {
581
581
  const t = 1 * e;
582
582
  return Number.isFinite(t) && typeof t == "number";
583
- }, isObject: ne, isPromiseLike: (e) => !!e && typeof e.then == "function", isRectInsideRect: (e, t) => e.top >= t.top && e.bottom <= t.bottom && e.left >= t.left && e.right <= t.right, isRectIntersect: qe, mergeContentful: (...e) => {
583
+ }, isObject: ne, isPromiseLike: (e) => !!e && typeof e.then == "function", isRectInsideRect: (e, t) => e.top >= t.top && e.bottom <= t.bottom && e.left >= t.left && e.right <= t.right, isRectIntersect: Ge, mergeContentful: (...e) => {
584
584
  const t = e.length;
585
585
  if (t > 0 && e[t - 1] !== void 0 && !ne(e[t - 1])) return e[t - 1];
586
586
  let n = e[0] || {};
@@ -593,7 +593,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
593
593
  e();
594
594
  });
595
595
  }, openFileDialog: (e = "*.*") => new Promise((t, n) => {
596
- if (!Ge) return void n("Unable to open dialog with no dom.");
596
+ if (!qe) return void n("Unable to open dialog with no dom.");
597
597
  const r = document.createElement("input");
598
598
  r.type = "file", r.accept = e;
599
599
  let o = null, a = !1;
@@ -647,7 +647,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
647
647
  return { ip: Math.trunc(e), fp: o, ipLength: Math.ceil(Math.log10(n + 1)), fpLength: a };
648
648
  }, subtractRect: (e, t, n = !1) => {
649
649
  if (!t) return [e];
650
- if (!qe(e, t)) return [];
650
+ if (!Ge(e, t)) return [];
651
651
  const r = [];
652
652
  let o = e;
653
653
  const a = () => {
@@ -1085,9 +1085,9 @@ class tt {
1085
1085
  }
1086
1086
  var Ee;
1087
1087
  (Ee = tt || (tt = {})).ErrorMessages = mt, Ee.Global = new Ee();
1088
- const qt = "__SHEETXL";
1088
+ const Gt = "__SHEETXL";
1089
1089
  let ee = null, le = null;
1090
- async function Gt() {
1090
+ async function qt() {
1091
1091
  if (ee)
1092
1092
  return ee;
1093
1093
  if (le) {
@@ -1114,9 +1114,9 @@ const Wt = {
1114
1114
  target: "esnext"
1115
1115
  }
1116
1116
  };
1117
- async function Yt(e, t, n = "/script.js", r = qt) {
1117
+ async function Yt(e, t, n = "/script.js", r = Gt) {
1118
1118
  try {
1119
- const o = await Gt(), a = "@sheetxl/primitives", i = \`
1119
+ const o = await qt(), a = "@sheetxl/primitives", i = \`
1120
1120
  export const FormulaContext = globalThis.\${r}?.FormulaContext;
1121
1121
  export const ScalarType = globalThis.\${r}?.ScalarType;
1122
1122
  export const Observable = globalThis.\${r}?.Observable;
@@ -1323,8 +1323,8 @@ async function nn(e) {
1323
1323
  const M = s.typeName?.getText?.() ?? null, K = yt.get(M);
1324
1324
  let V = !1;
1325
1325
  K && (m.range = K, V = !0);
1326
- const q = Zt.get(M);
1327
- if (q && (m.scalar = q), q !== void 0 && (V = !0), P) {
1326
+ const G = Zt.get(M);
1327
+ if (G && (m.scalar = G), G !== void 0 && (V = !0), P) {
1328
1328
  const R = gt.get(M);
1329
1329
  if (R)
1330
1330
  return R;
@@ -1371,8 +1371,8 @@ async function nn(e) {
1371
1371
  }
1372
1372
  const V = {};
1373
1373
  c(s.type, V, m, !1), m.returnType = V;
1374
- const q = {};
1375
- fe(s) && (q.default = !0, u = P), Object.keys(q).length > 0 && (m.behavior = q), m.parameters = [];
1374
+ const G = {};
1375
+ fe(s) && (G.default = !0, u = P), Object.keys(G).length > 0 && (m.behavior = G), m.parameters = [];
1376
1376
  const H = /* @__PURE__ */ new Map();
1377
1377
  for (let R = 0; R < s.parameters.length; R++) {
1378
1378
  const b = s.parameters[R], N = {};
@@ -1398,8 +1398,8 @@ async function nn(e) {
1398
1398
  b.dotDotDotToken && (N.rest = !0), m.parameters.push(N);
1399
1399
  const C = { description: "" };
1400
1400
  L.parameters[N.name] = C;
1401
- const G = I.getSymbolAtLocation(b.name).getDocumentationComment(I);
1402
- G && G.length > 0 && G[0].text && (C.description = G[0].text), v !== void 0 && (C.defaultValue = v), H.set(N.name, N);
1401
+ const q = I.getSymbolAtLocation(b.name).getDocumentationComment(I);
1402
+ q && q.length > 0 && q[0].text && (C.description = q[0].text), v !== void 0 && (C.defaultValue = v), H.set(N.name, N);
1403
1403
  }
1404
1404
  if (s.jsDoc && s.jsDoc.length > 0) {
1405
1405
  const R = s.jsDoc;
@@ -1412,8 +1412,8 @@ async function nn(e) {
1412
1412
  if (!v) continue;
1413
1413
  v = v.toLowerCase();
1414
1414
  let C = z.comment;
1415
- const G = v === "hidden";
1416
- if (!(typeof C != "string" && !G) && (typeof C == "string" && (C = C.replace(/[\\r\\n]+/g, "\\\\n").trim()), !(!G && C && (C = C.split(/\\\\n/)[0], !C || C.length === 0)))) {
1415
+ const q = v === "hidden";
1416
+ if (!(typeof C != "string" && !q) && (typeof C == "string" && (C = C.replace(/[\\r\\n]+/g, "\\\\n").trim()), !(!q && C && (C = C.split(/\\\\n/)[0], !C || C.length === 0)))) {
1417
1417
  if (C && typeof C == "string") {
1418
1418
  const O = /\\{@link(code|plain)?\\s+([^}|]+)(?:\\s*\\|\\s*([^}]+))?\\}/g;
1419
1419
  let F, Z = C, te = [];
@@ -1575,7 +1575,7 @@ async function p() {
1575
1575
  return await l();
1576
1576
  }
1577
1577
  const l = async () => {
1578
- const { compileModule: e } = await import("./CdYur831w0feAFEx.mjs"), n = new u((t) => e(t));
1578
+ const { compileModule: e } = await import("./C9w2B1z_73Lcpp23.mjs"), n = new u((t) => e(t));
1579
1579
  return await n.start(), n;
1580
1580
  };
1581
1581
  export {
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -47,7 +47,7 @@ class u {
47
47
  }
48
48
  }
49
49
  const s = `/**
50
- * @license @sheetxl/primitives - Primitives - Base types for SheetXL functions. - v0.7.6
50
+ * @license @sheetxl/primitives - Primitives - Base types for SheetXL functions. - v0.7.7
51
51
  *
52
52
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
53
53
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -266,7 +266,7 @@ var T;
266
266
  return r = typeof e == "string" ? rt.get(e) : ot.get(e), r || (r = T.Unknown), new r(t, n);
267
267
  }, T.getBuiltInById = (e) => Te.get(e) || xt;
268
268
  /**
269
- * @license @sheetxl/utils - Utils - Utilities used by most SheetXL components. - v0.7.6
269
+ * @license @sheetxl/utils - Utils - Utilities used by most SheetXL components. - v0.7.7
270
270
  *
271
271
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
272
272
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -449,7 +449,7 @@ const Ft = Object.freeze([]), Dt = Object.freeze({}), ze = (e) => e, de = () =>
449
449
  ut(e[i], t?.[i], n) === null && (o = !0, delete e[i]);
450
450
  }
451
451
  return o && Object.keys(e).length === 0 ? null : void 0;
452
- }, Ke = typeof performance == "object" && typeof performance.now == "function" ? () => performance.now() : () => Date.now(), Ve = (e) => e == null, qe = (e, t) => !(t.left > e.right || t.right < e.left || t.top > e.bottom || t.bottom < e.top), Ge = !(typeof window > "u" || !window.document || !window.document.createElement), k = { Windows: "windows", MacOS: "macos", IOS: "ios", Linux: "linux", Android: "android", Safari: "safari", Firefox: "firefox", Node: "node", Unknown: "unknown" }, oe = () => {
452
+ }, Ke = typeof performance == "object" && typeof performance.now == "function" ? () => performance.now() : () => Date.now(), Ve = (e) => e == null, Ge = (e, t) => !(t.left > e.right || t.right < e.left || t.top > e.bottom || t.bottom < e.top), qe = !(typeof window > "u" || !window.document || !window.document.createElement), k = { Windows: "windows", MacOS: "macos", IOS: "ios", Linux: "linux", Android: "android", Safari: "safari", Firefox: "firefox", Node: "node", Unknown: "unknown" }, oe = () => {
453
453
  if (dt()) return k.Node;
454
454
  const e = globalThis.navigator !== void 0 && globalThis.navigator.userAgent ? globalThis.navigator.userAgent.toLowerCase() : "";
455
455
  return e ? /(win32|win64|windows|wince)/i.test(e) ? k.Windows : /(macintosh|macintel|macppc|mac68k|macos)/i.test(e) ? k.MacOS : /(iphone|ipad|ipod)/i.test(e) ? k.IOS : /android/.test(e) ? k.Android : /linux/.test(e) ? k.Linux : /^((?!chrome|android|).)*safari/i.test(e) ? k.Safari : /^((?!chrome|android|Seamonkey).)*firefox/i.test(e) ? k.Firefox : k.Unknown : k.Unknown;
@@ -465,7 +465,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
465
465
  return Number.isFinite(t) ? t : 0;
466
466
  }, camelToPrettyCase: (e) => e.length === 1 ? e.toUpperCase() : e.replace(/([A-Z])/g, " $1").replace(/^./, function(t) {
467
467
  return t.toUpperCase();
468
- }).trim(), canUseDOM: Ge, cancelTimeout: (e) => {
468
+ }).trim(), canUseDOM: qe, cancelTimeout: (e) => {
469
469
  cancelAnimationFrame(e.id);
470
470
  }, castToString: (e) => e == null || e === void 0 ? "" : typeof e != "string" ? "" + e : e, cloneObject: (e) => Ve(e) ? e : JSON.parse(JSON.stringify(e)), consoleWithNoSource: (...e) => new Promise((t) => {
471
471
  setTimeout(() => {
@@ -580,7 +580,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
580
580
  }, isNode: dt, isNullOrUndefined: Ve, isNumeric: (e) => {
581
581
  const t = 1 * e;
582
582
  return Number.isFinite(t) && typeof t == "number";
583
- }, isObject: ne, isPromiseLike: (e) => !!e && typeof e.then == "function", isRectInsideRect: (e, t) => e.top >= t.top && e.bottom <= t.bottom && e.left >= t.left && e.right <= t.right, isRectIntersect: qe, mergeContentful: (...e) => {
583
+ }, isObject: ne, isPromiseLike: (e) => !!e && typeof e.then == "function", isRectInsideRect: (e, t) => e.top >= t.top && e.bottom <= t.bottom && e.left >= t.left && e.right <= t.right, isRectIntersect: Ge, mergeContentful: (...e) => {
584
584
  const t = e.length;
585
585
  if (t > 0 && e[t - 1] !== void 0 && !ne(e[t - 1])) return e[t - 1];
586
586
  let n = e[0] || {};
@@ -593,7 +593,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
593
593
  e();
594
594
  });
595
595
  }, openFileDialog: (e = "*.*") => new Promise((t, n) => {
596
- if (!Ge) return void n("Unable to open dialog with no dom.");
596
+ if (!qe) return void n("Unable to open dialog with no dom.");
597
597
  const r = document.createElement("input");
598
598
  r.type = "file", r.accept = e;
599
599
  let o = null, a = !1;
@@ -647,7 +647,7 @@ const We = (e, t = !1) => (document.hasFocus() || t) && (e === document.activeEl
647
647
  return { ip: Math.trunc(e), fp: o, ipLength: Math.ceil(Math.log10(n + 1)), fpLength: a };
648
648
  }, subtractRect: (e, t, n = !1) => {
649
649
  if (!t) return [e];
650
- if (!qe(e, t)) return [];
650
+ if (!Ge(e, t)) return [];
651
651
  const r = [];
652
652
  let o = e;
653
653
  const a = () => {
@@ -1085,9 +1085,9 @@ class tt {
1085
1085
  }
1086
1086
  var Ee;
1087
1087
  (Ee = tt || (tt = {})).ErrorMessages = mt, Ee.Global = new Ee();
1088
- const qt = "__SHEETXL";
1088
+ const Gt = "__SHEETXL";
1089
1089
  let ee = null, le = null;
1090
- async function Gt() {
1090
+ async function qt() {
1091
1091
  if (ee)
1092
1092
  return ee;
1093
1093
  if (le) {
@@ -1114,9 +1114,9 @@ const Wt = {
1114
1114
  target: "esnext"
1115
1115
  }
1116
1116
  };
1117
- async function Yt(e, t, n = "/script.js", r = qt) {
1117
+ async function Yt(e, t, n = "/script.js", r = Gt) {
1118
1118
  try {
1119
- const o = await Gt(), a = "@sheetxl/primitives", i = \`
1119
+ const o = await qt(), a = "@sheetxl/primitives", i = \`
1120
1120
  export const FormulaContext = globalThis.\${r}?.FormulaContext;
1121
1121
  export const ScalarType = globalThis.\${r}?.ScalarType;
1122
1122
  export const Observable = globalThis.\${r}?.Observable;
@@ -1323,8 +1323,8 @@ async function nn(e) {
1323
1323
  const M = s.typeName?.getText?.() ?? null, K = yt.get(M);
1324
1324
  let V = !1;
1325
1325
  K && (m.range = K, V = !0);
1326
- const q = Zt.get(M);
1327
- if (q && (m.scalar = q), q !== void 0 && (V = !0), P) {
1326
+ const G = Zt.get(M);
1327
+ if (G && (m.scalar = G), G !== void 0 && (V = !0), P) {
1328
1328
  const R = gt.get(M);
1329
1329
  if (R)
1330
1330
  return R;
@@ -1371,8 +1371,8 @@ async function nn(e) {
1371
1371
  }
1372
1372
  const V = {};
1373
1373
  c(s.type, V, m, !1), m.returnType = V;
1374
- const q = {};
1375
- fe(s) && (q.default = !0, u = P), Object.keys(q).length > 0 && (m.behavior = q), m.parameters = [];
1374
+ const G = {};
1375
+ fe(s) && (G.default = !0, u = P), Object.keys(G).length > 0 && (m.behavior = G), m.parameters = [];
1376
1376
  const H = /* @__PURE__ */ new Map();
1377
1377
  for (let R = 0; R < s.parameters.length; R++) {
1378
1378
  const b = s.parameters[R], N = {};
@@ -1398,8 +1398,8 @@ async function nn(e) {
1398
1398
  b.dotDotDotToken && (N.rest = !0), m.parameters.push(N);
1399
1399
  const C = { description: "" };
1400
1400
  L.parameters[N.name] = C;
1401
- const G = I.getSymbolAtLocation(b.name).getDocumentationComment(I);
1402
- G && G.length > 0 && G[0].text && (C.description = G[0].text), v !== void 0 && (C.defaultValue = v), H.set(N.name, N);
1401
+ const q = I.getSymbolAtLocation(b.name).getDocumentationComment(I);
1402
+ q && q.length > 0 && q[0].text && (C.description = q[0].text), v !== void 0 && (C.defaultValue = v), H.set(N.name, N);
1403
1403
  }
1404
1404
  if (s.jsDoc && s.jsDoc.length > 0) {
1405
1405
  const R = s.jsDoc;
@@ -1412,8 +1412,8 @@ async function nn(e) {
1412
1412
  if (!v) continue;
1413
1413
  v = v.toLowerCase();
1414
1414
  let C = z.comment;
1415
- const G = v === "hidden";
1416
- if (!(typeof C != "string" && !G) && (typeof C == "string" && (C = C.replace(/[\\r\\n]+/g, "\\\\n").trim()), !(!G && C && (C = C.split(/\\\\n/)[0], !C || C.length === 0)))) {
1415
+ const q = v === "hidden";
1416
+ if (!(typeof C != "string" && !q) && (typeof C == "string" && (C = C.replace(/[\\r\\n]+/g, "\\\\n").trim()), !(!q && C && (C = C.split(/\\\\n/)[0], !C || C.length === 0)))) {
1417
1417
  if (C && typeof C == "string") {
1418
1418
  const O = /\\{@link(code|plain)?\\s+([^}|]+)(?:\\s*\\|\\s*([^}]+))?\\}/g;
1419
1419
  let F, Z = C, te = [];
@@ -1575,7 +1575,7 @@ async function p() {
1575
1575
  return await l();
1576
1576
  }
1577
1577
  const l = async () => {
1578
- const { compileModule: e } = await import("./DkcmG4zuw2XYLmhc.mjs"), n = new u((t) => e(t));
1578
+ const { compileModule: e } = await import("./DliHYiIt_au6lEtQ.mjs"), n = new u((t) => e(t));
1579
1579
  return await n.start(), n;
1580
1580
  };
1581
1581
  export {
@@ -1,6 +1,6 @@
1
1
  import * as s from "esbuild-wasm";
2
2
  /**
3
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
3
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
4
4
  *
5
5
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
6
6
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
2
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -10,7 +10,7 @@ class o {
10
10
  }
11
11
  async getWorkerWrapper() {
12
12
  if (this.workerWrapper) return this.workerWrapper;
13
- const { createCompilerWorker: r } = await import("./Tl3UglWc6KduHjfn.mjs");
13
+ const { createCompilerWorker: r } = await import("./-pURMpycpL9yxtfF.mjs");
14
14
  return this.workerWrapper = await r(), this.workerWrapper;
15
15
  }
16
16
  async compileModule(r) {
@@ -1,7 +1,7 @@
1
1
  import { ScalarType as v } from "@sheetxl/primitives";
2
2
  import { CommonUtils as ae } from "@sheetxl/utils";
3
3
  /**
4
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
4
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
5
5
  *
6
6
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
7
7
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -21,7 +21,7 @@ async function le(h, x, S = "/script.js", w = "__SHEETXL") {
21
21
  p = a, b = T;
22
22
  });
23
23
  try {
24
- const { initialize: a } = await import("./M6GmlkBuxsC7TAwB.mjs");
24
+ const { initialize: a } = await import("./1O0v9xwVbvy-UCRK.mjs");
25
25
  return L = await a(), p(), L;
26
26
  } catch (a) {
27
27
  throw console.error("Failed to import or initialize esbuild:", a), P = null, b(a), a;
@@ -70,7 +70,7 @@ let B = null;
70
70
  async function pe() {
71
71
  if (B) return B;
72
72
  try {
73
- return await (await import("./kuonMEfk3Bh02Lnf.mjs")).initialize();
73
+ return await (await import("./C7pUnsLL2ud1V_OB.mjs")).initialize();
74
74
  } catch (h) {
75
75
  throw B = null, h;
76
76
  } finally {
@@ -1,6 +1,6 @@
1
1
  import { CommonUtils as u } from "@sheetxl/utils";
2
2
  /**
3
- * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.6
3
+ * @license @sheetxl/scripting - Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild. - v0.7.7
4
4
  *
5
5
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
6
6
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -11,7 +11,7 @@ const p = Object.freeze({ compileTypescript: async function(t) {
11
11
  if (n && u.deepEqual(n, t)) return i;
12
12
  const l = await (async function() {
13
13
  if (e) return e;
14
- const { TypeScriptCompiler: o } = await import("./BYVdasODBnhC-lx2.mjs");
14
+ const { TypeScriptCompiler: o } = await import("./CLk0X8h6CM20cTib.mjs");
15
15
  return e = new o(), e;
16
16
  })(), r = await l.compileModule(t);
17
17
  return i = r, n = t, r;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@sheetxl/scripting",
3
3
  "description": "Scripting - Scripting engine for Macros and formulas; includes TypeScript and EsBuild.",
4
- "version": "0.7.6",
4
+ "version": "0.7.7",
5
5
  "license": "SEE LICENSE IN <LICENSE>",
6
6
  "type": "module",
7
7
  "exports": {
@@ -40,8 +40,8 @@
40
40
  "scripting"
41
41
  ],
42
42
  "dependencies": {
43
- "@sheetxl/primitives": "^0.7.6",
44
- "@sheetxl/utils": "^0.7.6",
43
+ "@sheetxl/primitives": "^0.7.7",
44
+ "@sheetxl/utils": "^0.7.7",
45
45
  "path-browserify": "^1.0.1"
46
46
  },
47
47
  "peerDependencies": {