@fileverse-dev/dsheet 0.0.108 → 0.0.110

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.d.ts CHANGED
@@ -1,3 +1,4 @@
1
1
  export { default as DsheetEditor } from './package/dsheet-editor';
2
2
  export { formulaResponseUiSync } from './package/utils/formula-ui-sync';
3
+ export { executeStringFunction } from './package/utils/executeStringFunction';
3
4
  export { FLVURL } from '@fileverse-dev/formulajs';
package/dist/index.es.js CHANGED
@@ -170063,12 +170063,12 @@ const L6t = ({
170063
170063
  formulaResponseUiSync: l9
170064
170064
  });
170065
170065
  }, J6t = async (e, r) => {
170066
- var t, a, n, o, i, s, u;
170066
+ var t, a, n, o, i, s;
170067
170067
  try {
170068
- const l = await e;
170069
- if (typeof l == "string" && l.includes("Error")) {
170068
+ const u = await e;
170069
+ if (typeof u == "string" && u.includes("Error")) {
170070
170070
  dq(
170071
- l,
170071
+ u,
170072
170072
  r.sheetEditorRef,
170073
170073
  r.row,
170074
170074
  r.column,
@@ -170076,15 +170076,15 @@ const L6t = ({
170076
170076
  );
170077
170077
  return;
170078
170078
  }
170079
- if (typeof l == "string" && l.includes("RATE_LIMIT_REACHED") && r.dataBlockApiKeyHandler) {
170080
- X6t(l, r.dataBlockApiKeyHandler, r);
170079
+ if (typeof u == "string" && u.includes("RATE_LIMIT_REACHED") && r.dataBlockApiKeyHandler) {
170080
+ X6t(u, r.dataBlockApiKeyHandler, r);
170081
170081
  return;
170082
170082
  }
170083
- Array.isArray(l) ? hq(l, r) : zC(l, r);
170084
- const c = (t = r.sheetEditorRef.current) == null ? void 0 : t.getWorkbookContext(), f = (o = (n = (a = r.newValue) == null ? void 0 : a.f) == null ? void 0 : n.match(/^=([A-Z0-9_]+)\s*\(/)) == null ? void 0 : o[1], d = (i = c == null ? void 0 : c.formulaCache.functionlistMap[f || ""]) == null ? void 0 : i.API_KEY;
170085
- (s = r.storeApiKey) == null || s.call(r, d), (u = r.onDataBlockApiResponse) == null || u.call(r, f);
170086
- } catch (l) {
170087
- console.error("Error processing regular promise:", l), zC("Error processing data", r);
170083
+ Array.isArray(u) ? hq(u, r) : zC(u, r);
170084
+ const l = (t = r.sheetEditorRef.current) == null ? void 0 : t.getWorkbookContext(), c = (o = (n = (a = r.newValue) == null ? void 0 : a.f) == null ? void 0 : n.match(/^=([A-Z0-9_]+)\s*\(/)) == null ? void 0 : o[1], f = (i = l == null ? void 0 : l.formulaCache.functionlistMap[c || ""]) == null ? void 0 : i.API_KEY;
170085
+ (s = r.storeApiKey) == null || s.call(r, f);
170086
+ } catch (u) {
170087
+ console.error("Error processing regular promise:", u), zC("Error processing data", r);
170088
170088
  }
170089
170089
  }, Q6t = async (e, r) => {
170090
170090
  var i, s, u;
@@ -170114,7 +170114,7 @@ function a5t(e) {
170114
170114
  return /^0x?[a-fA-F0-9]+$/.test(e);
170115
170115
  }
170116
170116
  const n5t = async (e) => {
170117
- var s;
170117
+ var s, u, l, c;
170118
170118
  const { newValue: r, sheetEditorRef: t } = e;
170119
170119
  if (G6t(r))
170120
170120
  return;
@@ -170133,7 +170133,11 @@ const n5t = async (e) => {
170133
170133
  ct: { fa: "@", t: "s" }
170134
170134
  }));
170135
170135
  const { row: a, column: n } = V6t(e), o = { ...e, row: a, column: n };
170136
- r.m === P6t && (await Q6t(r, o), e != null && e.dataBlockCalcFunction && i5t({ params: o }));
170136
+ if (r.m === P6t) {
170137
+ await Q6t(r, o), e != null && e.dataBlockCalcFunction && i5t({ params: o });
170138
+ const f = (l = (u = r.f) == null ? void 0 : u.match(/^=([A-Z0-9_]+)\s*\(/)) == null ? void 0 : l[1];
170139
+ (c = e.onDataBlockApiResponse) == null || c.call(e, f);
170140
+ }
170137
170141
  const i = e == null ? void 0 : e.dataBlockCalcFunction;
170138
170142
  QE({ dataBlockCalcFunction: i, sheetEditorRef: t, currentRow: e.row, currentColumn: e.column });
170139
170143
  }, i5t = ({ params: e }) => {
@@ -292764,9 +292768,10 @@ const aAt = ({
292764
292768
  sheetEditorRef: w,
292765
292769
  storeApiKey: A,
292766
292770
  onDuneChartEmbed: S,
292767
- onSheetCountChange: x
292771
+ onSheetCountChange: x,
292772
+ onDataBlockApiResponse: N
292768
292773
  }) => {
292769
- const [N, D] = _t(!1);
292774
+ const [D, j] = _t(!1);
292770
292775
  return /* @__PURE__ */ cr.jsx(
292771
292776
  YJ,
292772
292777
  {
@@ -292795,14 +292800,15 @@ const aAt = ({
292795
292800
  onboardingHandler: p,
292796
292801
  dataBlockApiKeyHandler: g,
292797
292802
  isTemplateOpen: f,
292798
- exportDropdownOpen: N,
292799
- setExportDropdownOpen: D,
292803
+ exportDropdownOpen: D,
292804
+ setExportDropdownOpen: j,
292800
292805
  dsheetId: o,
292801
292806
  selectedTemplate: l,
292802
292807
  storeApiKey: A,
292803
292808
  allowComments: t,
292804
292809
  onDuneChartEmbed: S,
292805
- onSheetCountChange: x
292810
+ onSheetCountChange: x,
292811
+ onDataBlockApiResponse: N
292806
292812
  }
292807
292813
  )
292808
292814
  }
@@ -292811,5 +292817,6 @@ const aAt = ({
292811
292817
  export {
292812
292818
  CAt as DsheetEditor,
292813
292819
  Gie as FLVURL,
292820
+ XE as executeStringFunction,
292814
292821
  l9 as formulaResponseUiSync
292815
292822
  };
@@ -7,5 +7,5 @@ import { DsheetProps } from './types';
7
7
  * @param props - Component properties
8
8
  * @returns The SpreadsheetEditor component
9
9
  */
10
- declare const SpreadsheetEditor: ({ isCollaborative, isReadOnly, allowComments, renderNavbar, enableIndexeddbSync, dsheetId, portalContent, onChange, username, selectedTemplate, toggleTemplateSidebar, isTemplateOpen, enableWebrtc, onboardingComplete, onboardingHandler, commentData, getCommentCellUI, dataBlockApiKeyHandler, setFetchingURLData, setShowFetchURLModal, setInputFetchURLDataBlock, sheetEditorRef: externalSheetEditorRef, storeApiKey, onDuneChartEmbed, onSheetCountChange, }: DsheetProps) => JSX.Element;
10
+ declare const SpreadsheetEditor: ({ isCollaborative, isReadOnly, allowComments, renderNavbar, enableIndexeddbSync, dsheetId, portalContent, onChange, username, selectedTemplate, toggleTemplateSidebar, isTemplateOpen, enableWebrtc, onboardingComplete, onboardingHandler, commentData, getCommentCellUI, dataBlockApiKeyHandler, setFetchingURLData, setShowFetchURLModal, setInputFetchURLDataBlock, sheetEditorRef: externalSheetEditorRef, storeApiKey, onDuneChartEmbed, onSheetCountChange, onDataBlockApiResponse, }: DsheetProps) => JSX.Element;
11
11
  export default SpreadsheetEditor;
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@fileverse-dev/dsheet",
3
3
  "private": false,
4
4
  "description": "DSheet",
5
- "version": "0.0.108",
5
+ "version": "0.0.110",
6
6
  "main": "dist/index.es.js",
7
7
  "module": "dist/index.es.js",
8
8
  "exports": {