@fileverse-dev/dsheet 4.1.23-stabilise-package-4 → 4.1.23-stabilise-package-5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.es.js CHANGED
@@ -1,5 +1,5 @@
1
- import { C as s, f as o, g as t, S as r, h as l, j as n, k as d, T as S, l as c, n as i, o as h, p as m, q as p, t as C, u, v as E, w as F, x, z as g, A as R, B as f, D as A, E as I, F as L, G as w, H as T, I as v, J as y, K as D, L as M, M as O, N as b, O as k, P, Q as V } from "./index-YKT7Lz7Z.js";
2
- import { cG as B, cH as G, cI as H, cO as K, by as U, e as X, f as _, l as J, a as j, du as q, dv as N, bh as Q, dw as Y, dx as Z, dB as W, dC as $, dE as ee, J as ae, dS as se, eq as oe, ba as te } from "./executeStringFunction-BsVLVYUB.js";
1
+ import { C as s, f as o, g as t, S as r, h as l, j as n, k as d, T as S, l as c, n as i, o as h, p as m, q as p, t as C, u, v as E, w as F, x, z as g, A as R, B as f, D as A, E as I, F as L, G as w, H as T, I as v, J as y, K as D, L as M, M as O, N as b, O as k, P, Q as V } from "./index-B2qRWUrt.js";
2
+ import { cG as B, cH as G, cI as H, cO as K, by as U, e as X, f as _, l as J, a as j, du as q, dv as N, bh as Q, dw as Y, dx as Z, dB as W, dC as $, dE as ee, J as ae, dS as se, eq as oe, ba as te } from "./executeStringFunction-BEXVKyb4.js";
3
3
  import { FLVURL as le } from "@fileverse-dev/formulajs";
4
4
  import { E as de, S as Se } from "./constants-8Ij49Lxv.js";
5
5
  export {
@@ -0,0 +1,15 @@
1
+ import { Context } from '../context';
2
+
3
+ /** Same cap as `execfunction` (MAX_RANGE_DEPS in formula.ts). */
4
+ export declare const MAX_TEXT_RANGE_DEPS = 10000;
5
+ export type FormulaTextDeps = {
6
+ /** `${sheetId}:${r}:${c}` of every cell the formula reads. */
7
+ deps: Set<string>;
8
+ /** Too wide or unresolvable to list: the formula runs on every commit. */
9
+ wide: boolean;
10
+ };
11
+ /**
12
+ * Collect the references of formula text `f` (with its leading `=`) written
13
+ * in cell (`r`, `c`) of tab `sheetId`.
14
+ */
15
+ export declare function collectFormulaTextDeps(ctx: Context, f: string, sheetId: string, r: number, c: number): FormulaTextDeps;
@@ -5,19 +5,14 @@ export declare const FORMULA_WARMUP_DEBOUNCE_MS = 2000;
5
5
  export declare const FORMULA_WARMUP_IDLE_TIMEOUT_MS = 1000;
6
6
  export type FormulaWarmupResult = 'complete' | 'aborted';
7
7
  export type FormulaWarmupOptions = {
8
- /** Longest a slice keeps evaluating before it yields (default 8). */
8
+ /** Longest a slice keeps reading formulas before it yields (default 8). */
9
9
  budgetMs: number;
10
10
  /** Runs the next slice later (idle callback in the app). */
11
11
  schedule: (cb: () => void) => void;
12
12
  isCancelled?: () => boolean;
13
13
  };
14
14
  /**
15
- * Formula functions that are `async` (they fetch over the network, e.g.
16
- * ETHERSCAN, EOA). The warm-up records their arguments but never calls them.
17
- */
18
- export declare function isAsyncFormulaFunction(name: string): boolean;
19
- /**
20
- * Walk the calc chain in slices and record every formula's dependencies, then
15
+ * Walk the calc chain in slices and read every formula's references, then
21
16
  * mark the graph complete (C8). Resolves 'aborted' if the graph is cleared
22
17
  * while it runs, a tab holding formulas is sparse, or `isCancelled` says so.
23
18
  *
@@ -131,6 +131,12 @@ export declare function resetFormulaDependencyIndexes(ctx: Context): void;
131
131
  * has recorded its dependencies, unless the graph was invalidated meanwhile.
132
132
  */
133
133
  export declare function finishFullFormulaPass(ctx: Context, epoch: number | null | undefined): void;
134
+ /**
135
+ * INDIRECT and OFFSET would resolve references at run time, which the graph
136
+ * cannot see. Today both evaluate to an error (formulajs implements neither),
137
+ * but formulas using them are kept on every commit's run list regardless.
138
+ */
139
+ export declare const RUNTIME_REFERENCE_RE: RegExp;
134
140
  export declare function execfunction(ctx: Context, txt: string, r: number, c: number, id?: string, calcChainSet?: Set<string>, isrefresh?: boolean, notInsertFunc?: boolean): any[];
135
141
  export declare function groupValuesRefresh(ctx: Context): void;
136
142
  /** Apply worker chunk output onto the live context (main thread only). */
@@ -1,10 +1,10 @@
1
1
  import * as BZ from "yjs";
2
- import { i as Yl, a as hl, b as ul, s as eZ, r as Il, y as pl, d as Rl, m as sl } from "./index-YKT7Lz7Z.js";
3
- import { g as al } from "./executeStringFunction-BsVLVYUB.js";
2
+ import { i as Yl, a as hl, b as ul, s as eZ, r as Il, y as pl, d as Rl, m as sl } from "./index-B2qRWUrt.js";
3
+ import { g as al } from "./executeStringFunction-BEXVKyb4.js";
4
4
  import { Workbook as Kl } from "exceljs";
5
5
  import Jl from "luckyexcel";
6
- import { e as xl, b as Ml, n as Sl } from "./xlsx-hyperlink-inline-07QbQDEt.js";
7
- import { parseDefinedNamesFromXlsxBuffer as Nl, excelEntriesToDefinedNames as OZ } from "./xlsx-defined-names-D3F23p2Z.js";
6
+ import { e as xl, b as Ml, n as Sl } from "./xlsx-hyperlink-inline-yhXVMMJ9.js";
7
+ import { parseDefinedNamesFromXlsxBuffer as Nl, excelEntriesToDefinedNames as OZ } from "./xlsx-defined-names-BPf5_A0O.js";
8
8
  import { toast as fZ } from "@fileverse/ui";
9
9
  var Zl = { exports: {} };
10
10
  (function(m) {
@@ -1,5 +1,5 @@
1
- import { i as w } from "./executeStringFunction-BsVLVYUB.js";
2
- import { J as x } from "./xlsx-hyperlink-inline-07QbQDEt.js";
1
+ import { i as w } from "./executeStringFunction-BEXVKyb4.js";
2
+ import { J as x } from "./xlsx-hyperlink-inline-yhXVMMJ9.js";
3
3
  function g(o) {
4
4
  return o.startsWith("_xlnm.");
5
5
  }
@@ -1,9 +1,9 @@
1
1
  import { utils as S, write as nt } from "xlsx-js-style";
2
2
  import { Workbook as pt } from "exceljs";
3
3
  import { toast as rt } from "@fileverse/ui";
4
- import { J as dt, c as X, g as ht, a as mt } from "./xlsx-hyperlink-inline-07QbQDEt.js";
5
- import { b as gt } from "./executeStringFunction-BsVLVYUB.js";
6
- import { e as bt } from "./index-YKT7Lz7Z.js";
4
+ import { J as dt, c as X, g as ht, a as mt } from "./xlsx-hyperlink-inline-yhXVMMJ9.js";
5
+ import { b as gt } from "./executeStringFunction-BEXVKyb4.js";
6
+ import { e as bt } from "./index-B2qRWUrt.js";
7
7
  const xt = {
8
8
  1: "thin",
9
9
  2: "hair",
@@ -854,7 +854,7 @@ const Z = (t) => {
854
854
  O
855
855
  );
856
856
  });
857
- const { applyDefinedNamesToExcelWorkbook: ct } = await import("./xlsx-defined-names-D3F23p2Z.js");
857
+ const { applyDefinedNamesToExcelWorkbook: ct } = await import("./xlsx-defined-names-BPf5_A0O.js");
858
858
  ct(
859
859
  B,
860
860
  (k = (C = (s = t.current).getWorkbookContext) == null ? void 0 : C.call(s)) == null ? void 0 : k.definedNames,
@@ -1,5 +1,5 @@
1
- import { g as Rt, c as yt } from "./executeStringFunction-BsVLVYUB.js";
2
- import { c as wt } from "./index-YKT7Lz7Z.js";
1
+ import { g as Rt, c as yt } from "./executeStringFunction-BEXVKyb4.js";
2
+ import { c as wt } from "./index-B2qRWUrt.js";
3
3
  function jt(J, nt) {
4
4
  const g = J.getImages();
5
5
  if (!g.length) return [];
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@fileverse-dev/dsheet",
3
3
  "private": false,
4
4
  "description": "DSheet",
5
- "version": "4.1.23-stabilise-package-4",
5
+ "version": "4.1.23-stabilise-package-5",
6
6
  "repository": {
7
7
  "type": "git",
8
8
  "url": "git+https://github.com/fileverse/fileverse-dsheets.git"