@sheetxl/react 0.6.6 → 0.6.8

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.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/react - React - React components needed to build advanced grid and spreadsheet UIs. - v0.6.6
2
+ * @license @sheetxl/react - React - React components needed to build advanced grid and spreadsheet UIs. - v0.6.8
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.
@@ -54,7 +54,7 @@ function me() {
54
54
  }), u;
55
55
  function d(P) {
56
56
  return function(_) {
57
- return function(f) {
57
+ return (function(f) {
58
58
  if (s) throw new TypeError("Generator is already executing.");
59
59
  for (; h; ) try {
60
60
  if (s = 1, n && (e = 2 & f[0] ? n.return : f[0] ? n.throw || ((e = n.return) && e.call(n), 0) : n.next) && !(e = e.call(n, f[1])).done) return e;
@@ -99,12 +99,12 @@ function me() {
99
99
  }
100
100
  if (5 & f[0]) throw f[1];
101
101
  return { value: f[0] ? f[1] : void 0, done: !0 };
102
- }([P, _]);
102
+ })([P, _]);
103
103
  };
104
104
  }
105
105
  };
106
106
  Object.defineProperty(U, "__esModule", { value: !0 }), U.JsDelivrSourceResolver = void 0;
107
- var O = function() {
107
+ var O = (function() {
108
108
  function o() {
109
109
  }
110
110
  return o.prototype.resolvePackageJson = function(a, s, n) {
@@ -149,7 +149,7 @@ function me() {
149
149
  });
150
150
  });
151
151
  }, o;
152
- }();
152
+ })();
153
153
  return U.JsDelivrSourceResolver = O, U;
154
154
  }
155
155
  var H, Q, Y, C = {}, F = {};
@@ -274,10 +274,10 @@ function q() {
274
274
  return a === -1 || n === -1 || u === 0 || u === 1 && a === n - 1 && a === s + 1 ? "" : o.slice(a, n);
275
275
  }, format: function(o) {
276
276
  if (o === null || typeof o != "object") throw new TypeError('The "pathObject" argument must be of type Object. Received type ' + typeof o);
277
- return function(a, s) {
277
+ return (function(a, s) {
278
278
  var n = s.dir || s.root, e = s.base || (s.name || "") + (s.ext || "");
279
279
  return n ? n === s.root ? n + e : n + a + e : e;
280
- }("/", o);
280
+ })("/", o);
281
281
  }, parse: function(o) {
282
282
  g(o);
283
283
  var a = { root: "", dir: "", base: "", ext: "", name: "" };
@@ -345,7 +345,7 @@ var te, re, ne, oe, z = {};
345
345
  function we() {
346
346
  if (te) return z;
347
347
  te = 1, Object.defineProperty(z, "__esModule", { value: !0 }), z.RecursionDepth = void 0;
348
- var g = function() {
348
+ var g = (function() {
349
349
  function j(O, o, a) {
350
350
  o === void 0 && (o = 0), a === void 0 && (a = 0), this.options = O, this.fileRecursionDepth = o, this.packageRecursionDepth = a;
351
351
  }
@@ -358,7 +358,7 @@ function we() {
358
358
  }, j.prototype.shouldStop = function() {
359
359
  return this.options.fileRecursionDepth > 0 && this.fileRecursionDepth >= this.options.fileRecursionDepth || this.options.packageRecursionDepth > 0 && this.packageRecursionDepth >= this.options.packageRecursionDepth;
360
360
  }, j;
361
- }();
361
+ })();
362
362
  return z.RecursionDepth = g, z;
363
363
  }
364
364
  function Pe() {
@@ -420,7 +420,7 @@ function Pe() {
420
420
  }), m;
421
421
  function b(y) {
422
422
  return function(k) {
423
- return function(p) {
423
+ return (function(p) {
424
424
  if (c) throw new TypeError("Generator is already executing.");
425
425
  for (; v; ) try {
426
426
  if (c = 1, l && (i = 2 & p[0] ? l.return : p[0] ? l.throw || ((i = l.return) && i.call(l), 0) : l.next) && !(i = i.call(l, p[1])).done) return i;
@@ -465,7 +465,7 @@ function Pe() {
465
465
  }
466
466
  if (5 & p[0]) throw p[1];
467
467
  return { value: p[0] ? p[1] : void 0, done: !0 };
468
- }([y, k]);
468
+ })([y, k]);
469
469
  };
470
470
  }
471
471
  }, n = C && C.__values || function(r) {
@@ -493,7 +493,7 @@ function Pe() {
493
493
  return v;
494
494
  };
495
495
  Object.defineProperty(C, "__esModule", { value: !0 }), C.ImportResolver = void 0;
496
- var u = function() {
496
+ var u = (function() {
497
497
  if (Y) return F;
498
498
  Y = 1;
499
499
  var r = F && F.__createBinding || (Object.create ? function(b, y, k, p) {
@@ -534,7 +534,7 @@ function Pe() {
534
534
  return b.concat(p || Array.prototype.slice.call(y));
535
535
  };
536
536
  Object.defineProperty(F, "__esModule", { value: !0 }), F.DependencyParser = void 0;
537
- var m = c(q()), v = function() {
537
+ var m = c(q()), v = (function() {
538
538
  function b() {
539
539
  this.REGEX_CLEAN = /[\n|\r]/g, this.REGEX_DETECT_IMPORT = /(?:(?:(?:import)|(?:export))(?:.)*?from\s+["']([^"']+)["'])|(?:((?:require|import))(?:\s+)?\(["']([^"']+)["']\))|(?:\/+\s+<reference\s+path=["']([^"']+)["']\s+\/>)/g, this.REGEX_NODE_MODULE = /^node:([\w\W\/]+)$/;
540
540
  }
@@ -568,9 +568,9 @@ function Pe() {
568
568
  return y.startsWith(".") ? { kind: "relative-in-package", packageName: k.packageName, sourcePath: m.join(k.sourcePath, k.importPath), importPath: y } : y.startsWith("@") ? (w = y.split("/"), { kind: "package", packageName: "".concat(w[0], "/").concat(w[1]), importPath: w.slice(2).join("/") }) : { kind: "package", packageName: (w = y.split("/"))[0], importPath: w.slice(1).join("/") };
569
569
  }
570
570
  }, b;
571
- }();
571
+ })();
572
572
  return F.DependencyParser = v, F;
573
- }(), h = be(), d = o(q()), P = ke(), _ = we(), f = function() {
573
+ })(), h = be(), d = o(q()), P = ke(), _ = we(), f = (function() {
574
574
  function r(t) {
575
575
  var c, l;
576
576
  if (this.options = t, this.loadedFiles = [], this.dependencyParser = new u.DependencyParser(), this.cache = t.sourceCache, this.sourceResolver = t.sourceResolver, this.newImportsResolved = !1, this.monaco = t.monaco, t.preloadPackages && t.versions) {
@@ -831,7 +831,7 @@ function Pe() {
831
831
  });
832
832
  });
833
833
  }, r;
834
- }();
834
+ })();
835
835
  return C.ImportResolver = f, C;
836
836
  }
837
837
  function Oe() {
@@ -893,7 +893,7 @@ function Oe() {
893
893
  }), m;
894
894
  function b(y) {
895
895
  return function(k) {
896
- return function(p) {
896
+ return (function(p) {
897
897
  if (c) throw new TypeError("Generator is already executing.");
898
898
  for (; v; ) try {
899
899
  if (c = 1, l && (i = 2 & p[0] ? l.return : p[0] ? l.throw || ((i = l.return) && i.call(l), 0) : l.next) && !(i = i.call(l, p[1])).done) return i;
@@ -938,7 +938,7 @@ function Oe() {
938
938
  }
939
939
  if (5 & p[0]) throw p[1];
940
940
  return { value: p[0] ? p[1] : void 0, done: !0 };
941
- }([y, k]);
941
+ })([y, k]);
942
942
  };
943
943
  }
944
944
  }, n = A && A.__values || function(r) {
@@ -950,10 +950,10 @@ function Oe() {
950
950
  throw new TypeError(t ? "Object is not iterable." : "Symbol.iterator is not defined.");
951
951
  };
952
952
  Object.defineProperty(A, "__esModule", { value: !0 }), A.AutoTypingsCore = void 0;
953
- var e = function() {
953
+ var e = (function() {
954
954
  if (K) return X;
955
955
  K = 1, Object.defineProperty(X, "__esModule", { value: !0 }), X.DummySourceCache = void 0;
956
- var r = function() {
956
+ var r = (function() {
957
957
  function t() {
958
958
  }
959
959
  return t.prototype.getFile = function(c) {
@@ -965,9 +965,9 @@ function Oe() {
965
965
  }, t.prototype.clear = function() {
966
966
  return Promise.resolve(void 0);
967
967
  }, t;
968
- }();
968
+ })();
969
969
  return X.DummySourceCache = r, X;
970
- }(), u = me(), h = Pe(), d = o(q()), P = ke(), _ = we(), f = function() {
970
+ })(), u = me(), h = Pe(), d = o(q()), P = ke(), _ = we(), f = (function() {
971
971
  function r(t, c) {
972
972
  var l = this;
973
973
  this.editor = t, this.options = c, this.disposables = [], this.importResolver = new h.ImportResolver(c);
@@ -1049,7 +1049,7 @@ function Oe() {
1049
1049
  });
1050
1050
  });
1051
1051
  }, r;
1052
- }();
1052
+ })();
1053
1053
  return A.AutoTypingsCore = f, A;
1054
1054
  }
1055
1055
  var ae, I = {};
@@ -1090,7 +1090,7 @@ function je() {
1090
1090
  }), h;
1091
1091
  function P(_) {
1092
1092
  return function(f) {
1093
- return function(r) {
1093
+ return (function(r) {
1094
1094
  if (n) throw new TypeError("Generator is already executing.");
1095
1095
  for (; d; ) try {
1096
1096
  if (n = 1, e && (u = 2 & r[0] ? e.return : r[0] ? e.throw || ((u = e.return) && u.call(e), 0) : e.next) && !(u = u.call(e, r[1])).done) return u;
@@ -1135,7 +1135,7 @@ function je() {
1135
1135
  }
1136
1136
  if (5 & r[0]) throw r[1];
1137
1137
  return { value: r[0] ? r[1] : void 0, done: !0 };
1138
- }([_, f]);
1138
+ })([_, f]);
1139
1139
  };
1140
1140
  }
1141
1141
  }, O = I && I.__values || function(a) {
@@ -1147,7 +1147,7 @@ function je() {
1147
1147
  throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
1148
1148
  };
1149
1149
  Object.defineProperty(I, "__esModule", { value: !0 }), I.LocalStorageCache = void 0;
1150
- var o = function() {
1150
+ var o = (function() {
1151
1151
  function a() {
1152
1152
  this.localCache = {};
1153
1153
  }
@@ -1194,7 +1194,7 @@ function je() {
1194
1194
  });
1195
1195
  });
1196
1196
  }, a.LOCALSTORAGE_PREFIX = "__autotyper_cache_", a;
1197
- }();
1197
+ })();
1198
1198
  return I.LocalStorageCache = o, I;
1199
1199
  }
1200
1200
  var ie, se = {}, ce, ue = {}, le, pe = {}, he, fe = {}, de, ve, ye, ge, L = {};
@@ -1235,7 +1235,7 @@ function Re() {
1235
1235
  }), u;
1236
1236
  function d(P) {
1237
1237
  return function(_) {
1238
- return function(f) {
1238
+ return (function(f) {
1239
1239
  if (s) throw new TypeError("Generator is already executing.");
1240
1240
  for (; h; ) try {
1241
1241
  if (s = 1, n && (e = 2 & f[0] ? n.return : f[0] ? n.throw || ((e = n.return) && e.call(n), 0) : n.next) && !(e = e.call(n, f[1])).done) return e;
@@ -1280,12 +1280,12 @@ function Re() {
1280
1280
  }
1281
1281
  if (5 & f[0]) throw f[1];
1282
1282
  return { value: f[0] ? f[1] : void 0, done: !0 };
1283
- }([P, _]);
1283
+ })([P, _]);
1284
1284
  };
1285
1285
  }
1286
1286
  };
1287
1287
  Object.defineProperty(L, "__esModule", { value: !0 }), L.UnpkgSourceResolver = void 0;
1288
- var O = function() {
1288
+ var O = (function() {
1289
1289
  function o() {
1290
1290
  }
1291
1291
  return o.prototype.resolvePackageJson = function(a, s, n) {
@@ -1330,7 +1330,7 @@ function Re() {
1330
1330
  });
1331
1331
  });
1332
1332
  }, o;
1333
- }();
1333
+ })();
1334
1334
  return L.UnpkgSourceResolver = O, L;
1335
1335
  }
1336
1336
  function Ce() {
@@ -1344,7 +1344,7 @@ function Ce() {
1344
1344
  n === void 0 && (n = s), o[n] = a[s];
1345
1345
  }), O = W && W.__exportStar || function(o, a) {
1346
1346
  for (var s in o) s === "default" || Object.prototype.hasOwnProperty.call(a, s) || j(a, o, s);
1347
- }, Object.defineProperty(g, "__esModule", { value: !0 }), O(function() {
1347
+ }, Object.defineProperty(g, "__esModule", { value: !0 }), O((function() {
1348
1348
  if (oe) return G;
1349
1349
  oe = 1;
1350
1350
  var o, a = G && G.__extends || (o = function(n, e) {
@@ -1361,14 +1361,14 @@ function Ce() {
1361
1361
  o(n, e), n.prototype = e === null ? Object.create(e) : (u.prototype = e.prototype, new u());
1362
1362
  });
1363
1363
  Object.defineProperty(G, "__esModule", { value: !0 }), G.AutoTypings = void 0;
1364
- var s = function(n) {
1364
+ var s = (function(n) {
1365
1365
  function e(u, h) {
1366
1366
  return n.call(this, u, h) || this;
1367
1367
  }
1368
1368
  return a(e, n), e;
1369
- }(Oe().AutoTypingsCore);
1369
+ })(Oe().AutoTypingsCore);
1370
1370
  return G.AutoTypings = s, G;
1371
- }(), g), O(be(), g), O(je(), g), O((ie || (ie = 1, Object.defineProperty(se, "__esModule", { value: !0 })), se), g), O((ce || (ce = 1, Object.defineProperty(ue, "__esModule", { value: !0 })), ue), g), O((le || (le = 1, Object.defineProperty(pe, "__esModule", { value: !0 })), pe), g), O((he || (he = 1, Object.defineProperty(fe, "__esModule", { value: !0 })), fe), g), O(Re(), g), O(me(), g)), W;
1371
+ })(), g), O(be(), g), O(je(), g), O((ie || (ie = 1, Object.defineProperty(se, "__esModule", { value: !0 })), se), g), O((ce || (ce = 1, Object.defineProperty(ue, "__esModule", { value: !0 })), ue), g), O((le || (le = 1, Object.defineProperty(pe, "__esModule", { value: !0 })), pe), g), O((he || (he = 1, Object.defineProperty(fe, "__esModule", { value: !0 })), fe), g), O(Re(), g), O(me(), g)), W;
1372
1372
  var g, j, O;
1373
1373
  }
1374
1374
  const Se = _e({ __proto__: null }, [ge ? ye : (ge = 1, ye = Ce())]);
@@ -1,6 +1,6 @@
1
1
  import x, { memo as ce, useState as q, useRef as h, useCallback as ie, useEffect as M } from "react";
2
2
  /**
3
- * @license @sheetxl/react - React - React components needed to build advanced grid and spreadsheet UIs. - v0.6.6
3
+ * @license @sheetxl/react - React - React components needed to build advanced grid and spreadsheet UIs. - v0.6.8
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.
@@ -31,12 +31,12 @@ function de(e) {
31
31
  }
32
32
  function Ee(e, t) {
33
33
  if (e == null) return {};
34
- var r, n, o = function(c, a) {
34
+ var r, n, o = (function(c, a) {
35
35
  if (c == null) return {};
36
36
  var s, g, j = {}, v = Object.keys(c);
37
37
  for (g = 0; g < v.length; g++) s = v[g], a.indexOf(s) >= 0 || (j[s] = c[s]);
38
38
  return j;
39
- }(e, t);
39
+ })(e, t);
40
40
  if (Object.getOwnPropertySymbols) {
41
41
  var i = Object.getOwnPropertySymbols(e);
42
42
  for (n = 0; n < i.length; n++) r = i[n], t.indexOf(r) >= 0 || Object.prototype.propertyIsEnumerable.call(e, r) && (o[r] = e[r]);
@@ -172,9 +172,9 @@ function ee(e) {
172
172
  return t = !0;
173
173
  }, r;
174
174
  }
175
- var te, re, Ce = Ie.create({ config: { paths: { vs: "https://cdn.jsdelivr.net/npm/monaco-editor@0.52.2/min/vs" } }, isInitialized: !1, resolve: null, reject: null, monaco: null }), be = (re = 2, function(e) {
175
+ var te, re, Ce = Ie.create({ config: { paths: { vs: "https://cdn.jsdelivr.net/npm/monaco-editor@0.52.2/min/vs" } }, isInitialized: !1, resolve: null, reject: null, monaco: null }), be = (re = 2, (function(e) {
176
176
  if (Array.isArray(e)) return e;
177
- }(te = Ce) || function(e, t) {
177
+ })(te = Ce) || (function(e, t) {
178
178
  if (typeof Symbol < "u" && Symbol.iterator in Object(e)) {
179
179
  var r = [], n = !0, o = !1, i = void 0;
180
180
  try {
@@ -190,16 +190,16 @@ var te, re, Ce = Ie.create({ config: { paths: { vs: "https://cdn.jsdelivr.net/np
190
190
  }
191
191
  return r;
192
192
  }
193
- }(te, re) || function(e, t) {
193
+ })(te, re) || (function(e, t) {
194
194
  if (e) {
195
195
  if (typeof e == "string") return fe(e, t);
196
196
  var r = Object.prototype.toString.call(e).slice(8, -1);
197
197
  return r === "Object" && e.constructor && (r = e.constructor.name), r === "Map" || r === "Set" ? Array.from(e) : r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r) ? fe(e, t) : void 0;
198
198
  }
199
- }(te, re) || function() {
199
+ })(te, re) || (function() {
200
200
  throw new TypeError(`Invalid attempt to destructure non-iterable instance.
201
201
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
202
- }()), z = be[0], W = be[1];
202
+ })()), z = be[0], W = be[1];
203
203
  function De(e) {
204
204
  return document.body.appendChild(e);
205
205
  }
@@ -267,11 +267,11 @@ var ne = new Promise(function(e, t) {
267
267
  function R() {
268
268
  }
269
269
  function k(e, t, r, n) {
270
- return function(o, i) {
270
+ return (function(o, i) {
271
271
  return o.editor.getModel(me(o, i));
272
- }(e, n) || function(o, i, c, a) {
272
+ })(e, n) || (function(o, i, c, a) {
273
273
  return o.editor.createModel(i, c, a ? me(o, a) : void 0);
274
- }(e, t, r, n);
274
+ })(e, t, r, n);
275
275
  }
276
276
  function me(e, t) {
277
277
  return e.Uri.parse(t);
@@ -280,10 +280,10 @@ var ze = function({ original: e, modified: t, language: r, originalLanguage: n,
280
280
  let [w, A] = q(!1), [C, p] = q(!0), m = h(null), d = h(null), D = h(null), y = h(J), u = h(H), S = h(!1);
281
281
  ae(() => {
282
282
  let l = Y.init();
283
- return l.then((f) => (d.current = f) && p(!1)).catch((f) => f?.type !== "cancelation" && console.error("Monaco initialization: error:", f)), () => m.current ? function() {
283
+ return l.then((f) => (d.current = f) && p(!1)).catch((f) => f?.type !== "cancelation" && console.error("Monaco initialization: error:", f)), () => m.current ? (function() {
284
284
  let f = m.current?.getModel();
285
285
  a || f?.original?.dispose(), s || f?.modified?.dispose(), m.current?.dispose();
286
- }() : l.cancel();
286
+ })() : l.cancel();
287
287
  }), O(() => {
288
288
  if (m.current && d.current) {
289
289
  let l = m.current.getOriginalEditor(), f = k(d.current, e || "", n || r || "text", i || "");