@fileverse-dev/dsheet 1.2.26 → 1.2.27
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 +33 -31
- package/package.json +4 -4
package/dist/index.es.js
CHANGED
|
@@ -69461,7 +69461,7 @@ function NB(e) {
|
|
|
69461
69461
|
function wu(e, t) {
|
|
69462
69462
|
e = Ge(e), t = Ge(t);
|
|
69463
69463
|
const r = Or(e, t);
|
|
69464
|
-
return r || (t ? e > 0 && t < 0 ? At : Math.floor(e / t) * t : r1);
|
|
69464
|
+
return r || (e === 0 && t === 0 ? 0 : t ? e > 0 && t < 0 ? At : Math.floor(e / t) * t : r1);
|
|
69465
69465
|
}
|
|
69466
69466
|
wu.MATH = (e, t = 1, r = 0) => {
|
|
69467
69467
|
e = Ge(e), t = Ge(t), r = Ge(r);
|
|
@@ -165893,11 +165893,12 @@ var _W = function() {
|
|
|
165893
165893
|
var r = t.visible, a = document.getElementById("placeholder-data-verification");
|
|
165894
165894
|
return !r || !a ? null : /* @__PURE__ */ zN(/* @__PURE__ */ P.createElement(_W, null), a);
|
|
165895
165895
|
}, Ns = function(t) {
|
|
165896
|
-
var r = t.tooltip, a = t.onClick, n = t.iconId, i = t.disabled, l = t.selected, c = t.children, f = t.style;
|
|
165896
|
+
var r = t.tooltip, a = t.onClick, n = t.iconId, i = t.disabled, l = t.selected, c = t.children, f = t.style, s = t.id;
|
|
165897
165897
|
return /* @__PURE__ */ P.createElement(u0, {
|
|
165898
165898
|
text: r,
|
|
165899
165899
|
placement: "bottom"
|
|
165900
165900
|
}, /* @__PURE__ */ P.createElement("div", {
|
|
165901
|
+
id: s,
|
|
165901
165902
|
className: "fortune-toolbar-button fortune-toolbar-item",
|
|
165902
165903
|
onClick: a,
|
|
165903
165904
|
tabIndex: 0,
|
|
@@ -168077,6 +168078,7 @@ var Vyt = function(e, t, r, a) {
|
|
|
168077
168078
|
});
|
|
168078
168079
|
if (Se === "splitColumn")
|
|
168079
168080
|
return /* @__PURE__ */ P.createElement(Ns, {
|
|
168081
|
+
id: "splitColumn",
|
|
168080
168082
|
iconId: Se,
|
|
168081
168083
|
tooltip: ye,
|
|
168082
168084
|
key: Se,
|
|
@@ -168094,6 +168096,7 @@ var Vyt = function(e, t, r, a) {
|
|
|
168094
168096
|
return /* @__PURE__ */ P.createElement(P.Fragment, null, /* @__PURE__ */ P.createElement(Lyt, {
|
|
168095
168097
|
visible: Re
|
|
168096
168098
|
}), /* @__PURE__ */ P.createElement(Ns, {
|
|
168099
|
+
id: "dataVerification",
|
|
168097
168100
|
iconId: Se,
|
|
168098
168101
|
tooltip: ye,
|
|
168099
168102
|
key: Se,
|
|
@@ -168844,9 +168847,21 @@ var Vyt = function(e, t, r, a) {
|
|
|
168844
168847
|
G && (G.innerHTML = V), Pv(b.fxInput.current), d(function(K) {
|
|
168845
168848
|
K.functionCandidates = [], K.defaultCandidates = [], K.functionHint = O;
|
|
168846
168849
|
});
|
|
168847
|
-
return;
|
|
168848
168850
|
}
|
|
168849
|
-
}, [d]), E = It(function(
|
|
168851
|
+
}, [d]), E = It(function() {
|
|
168852
|
+
var O = D();
|
|
168853
|
+
O && O.classList.remove("luckysheet-formula-search-item-active");
|
|
168854
|
+
}, [D]), k = function() {
|
|
168855
|
+
var V, G, K = new DOMParser(), I = K.parseFromString("<div>".concat((G = (V = b.fxInput) === null || V === void 0 ? void 0 : V.current) === null || G === void 0 ? void 0 : G.innerHTML, "</div>"), "text/html"), X = I.querySelectorAll("span"), z = X[X.length - 1];
|
|
168856
|
+
return z == null ? void 0 : z.innerText;
|
|
168857
|
+
}, A = It(function(O) {
|
|
168858
|
+
var V, G, K;
|
|
168859
|
+
if (!O.target.className.includes("sign-fortune")) {
|
|
168860
|
+
L.current = (V = b.fxInput) === null || V === void 0 ? void 0 : V.current.innerText;
|
|
168861
|
+
var I = (K = (G = D()) === null || G === void 0 ? void 0 : G.querySelector(".luckysheet-formula-search-func")) === null || K === void 0 ? void 0 : K.textContent, X = k();
|
|
168862
|
+
I && !Hh(X) && (j(I), O.preventDefault(), O.stopPropagation());
|
|
168863
|
+
}
|
|
168864
|
+
}, [D, j]), S = It(function(O) {
|
|
168850
168865
|
var V;
|
|
168851
168866
|
if (h.allowEdit !== !1) {
|
|
168852
168867
|
var G = m2((V = b.fxInput) === null || V === void 0 ? void 0 : V.current);
|
|
@@ -168858,7 +168873,7 @@ var Vyt = function(e, t, r, a) {
|
|
|
168858
168873
|
`), document.execCommand("delete", !1), O.stopPropagation();
|
|
168859
168874
|
else {
|
|
168860
168875
|
var I = O;
|
|
168861
|
-
|
|
168876
|
+
A(I);
|
|
168862
168877
|
}
|
|
168863
168878
|
return;
|
|
168864
168879
|
}
|
|
@@ -168870,14 +168885,14 @@ var Vyt = function(e, t, r, a) {
|
|
|
168870
168885
|
var J = X == null ? void 0 : X.querySelectorAll(".luckysheet-formula-search-item"), le = J == null ? void 0 : J[J.length - 1];
|
|
168871
168886
|
U = le || null;
|
|
168872
168887
|
}
|
|
168873
|
-
|
|
168888
|
+
E(), U && U.classList.add("luckysheet-formula-search-item-active");
|
|
168874
168889
|
}
|
|
168875
168890
|
O.preventDefault();
|
|
168876
168891
|
} else if (O.key === "ArrowDown" && h.luckysheetCellUpdate.length > 0) {
|
|
168877
168892
|
if (document.getElementById("luckysheet-formula-search-c")) {
|
|
168878
168893
|
for (var X = document.getElementById("luckysheet-formula-search-c"), z = X == null ? void 0 : X.querySelector(".luckysheet-formula-search-item-active"), ne = z ? z.nextElementSibling : null; ne && !ne.classList.contains("luckysheet-formula-search-item"); )
|
|
168879
168894
|
ne = ne.nextElementSibling;
|
|
168880
|
-
ne || (ne = (X == null ? void 0 : X.querySelector(".luckysheet-formula-search-item")) || null),
|
|
168895
|
+
ne || (ne = (X == null ? void 0 : X.querySelector(".luckysheet-formula-search-item")) || null), E(), ne && ne.classList.add("luckysheet-formula-search-item-active");
|
|
168881
168896
|
}
|
|
168882
168897
|
O.preventDefault();
|
|
168883
168898
|
}
|
|
@@ -168909,16 +168924,13 @@ var Vyt = function(e, t, r, a) {
|
|
|
168909
168924
|
}
|
|
168910
168925
|
});
|
|
168911
168926
|
}
|
|
168912
|
-
}, [h.allowEdit, h.luckysheetCellUpdate.length, b.fxInput, d]),
|
|
168913
|
-
var V, G, K = new DOMParser(), I = K.parseFromString("<div>".concat((G = (V = b.fxInput) === null || V === void 0 ? void 0 : V.current) === null || G === void 0 ? void 0 : G.innerHTML, "</div>"), "text/html"), X = I.querySelectorAll("span"), z = X[X.length - 1];
|
|
168914
|
-
return z == null ? void 0 : z.innerText;
|
|
168915
|
-
}, A = function() {
|
|
168927
|
+
}, [h.allowEdit, h.luckysheetCellUpdate.length, b.fxInput, d]), C = function() {
|
|
168916
168928
|
var V, G, K, I, X = (V = document.getElementsByClassName("cell-hint")) === null || V === void 0 ? void 0 : V[0], z = (G = document.getElementsByClassName("fx-hint")) === null || G === void 0 ? void 0 : G[0], U = (K = document.getElementsByClassName("fx-search")) === null || K === void 0 ? void 0 : K[0], J = (I = document.getElementsByClassName("cell-search")) === null || I === void 0 ? void 0 : I[0];
|
|
168917
168929
|
U && (U.style.display = "block"), J && (J.style.display = "none"), X && (X.style.display = "none"), z && (z.style.display = "block");
|
|
168918
|
-
},
|
|
168930
|
+
}, F = It(function() {
|
|
168919
168931
|
var O, V, G;
|
|
168920
168932
|
if (!h.isFlvReadOnly) {
|
|
168921
|
-
|
|
168933
|
+
C(), !((V = (O = b.fxInput) === null || O === void 0 ? void 0 : O.current) === null || V === void 0) && V.innerText.includes("=") && /^=?[A-Za-z]*$/.test(k()) ? c(!0) : c(!1);
|
|
168922
168934
|
var K = m2((G = b.fxInput) === null || G === void 0 ? void 0 : G.current);
|
|
168923
168935
|
m(K);
|
|
168924
168936
|
var I = g.current;
|
|
@@ -168929,19 +168941,9 @@ var Vyt = function(e, t, r, a) {
|
|
|
168929
168941
|
});
|
|
168930
168942
|
}
|
|
168931
168943
|
}
|
|
168932
|
-
}, [b.cellInput, b.fxInput, d]),
|
|
168944
|
+
}, [b.cellInput, b.fxInput, d]), H = ea(function() {
|
|
168933
168945
|
return !(h.allowEdit === !1 || x || !Xr(h, h.luckysheet_select_save));
|
|
168934
|
-
}, [h.config, h.luckysheet_select_save, h.luckysheetfile, h.currentSheetId, x])
|
|
168935
|
-
var V, G, K;
|
|
168936
|
-
if (!O.target.className.includes("sign-fortune")) {
|
|
168937
|
-
L.current = (V = b.fxInput) === null || V === void 0 ? void 0 : V.current.innerText;
|
|
168938
|
-
var I = (K = (G = D()) === null || G === void 0 ? void 0 : G.querySelector(".luckysheet-formula-search-func")) === null || K === void 0 ? void 0 : K.textContent, X = k();
|
|
168939
|
-
I && !Hh(X) && (j(I), O.preventDefault(), O.stopPropagation());
|
|
168940
|
-
}
|
|
168941
|
-
}, [D, j]), H = It(function() {
|
|
168942
|
-
var O = D();
|
|
168943
|
-
O && O.classList.remove("luckysheet-formula-search-item-active");
|
|
168944
|
-
}, [D]);
|
|
168946
|
+
}, [h.config, h.luckysheet_select_save, h.luckysheetfile, h.currentSheetId, x]);
|
|
168945
168947
|
return /* @__PURE__ */ P.createElement("div", {
|
|
168946
168948
|
className: "fortune-fx-editor"
|
|
168947
168949
|
}, /* @__PURE__ */ P.createElement(Qyt, null), /* @__PURE__ */ P.createElement("div", {
|
|
@@ -168961,7 +168963,7 @@ var Vyt = function(e, t, r, a) {
|
|
|
168961
168963
|
}, /* @__PURE__ */ P.createElement(dW, {
|
|
168962
168964
|
onMouseUp: function() {
|
|
168963
168965
|
var V;
|
|
168964
|
-
|
|
168966
|
+
C();
|
|
168965
168967
|
var G = m2((V = b.fxInput) === null || V === void 0 ? void 0 : V.current);
|
|
168966
168968
|
m(G);
|
|
168967
168969
|
},
|
|
@@ -168972,22 +168974,22 @@ var Vyt = function(e, t, r, a) {
|
|
|
168972
168974
|
id: "luckysheet-functionbox-cell",
|
|
168973
168975
|
"aria-autocomplete": "list",
|
|
168974
168976
|
onFocus: R,
|
|
168975
|
-
onKeyDown:
|
|
168976
|
-
onChange:
|
|
168977
|
+
onKeyDown: S,
|
|
168978
|
+
onChange: F,
|
|
168977
168979
|
tabIndex: 0,
|
|
168978
|
-
allowEdit:
|
|
168980
|
+
allowEdit: H && !h.isFlvReadOnly
|
|
168979
168981
|
}), l && /* @__PURE__ */ P.createElement(pW, {
|
|
168980
168982
|
from: "fx",
|
|
168981
168983
|
onMouseMove: function(V) {
|
|
168982
168984
|
if (document.getElementById("luckysheet-formula-search-c")) {
|
|
168983
168985
|
var G = V.target.closest(".luckysheet-formula-search-item");
|
|
168984
168986
|
if (!G) return;
|
|
168985
|
-
|
|
168987
|
+
E(), G.classList.add("luckysheet-formula-search-item-active");
|
|
168986
168988
|
}
|
|
168987
168989
|
V.preventDefault();
|
|
168988
168990
|
},
|
|
168989
168991
|
onMouseDown: function(V) {
|
|
168990
|
-
|
|
168992
|
+
A(V);
|
|
168991
168993
|
}
|
|
168992
168994
|
}), /* @__PURE__ */ P.createElement("div", {
|
|
168993
168995
|
className: "fx-hint"
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@fileverse-dev/dsheet",
|
|
3
3
|
"private": false,
|
|
4
4
|
"description": "DSheet",
|
|
5
|
-
"version": "1.2.
|
|
5
|
+
"version": "1.2.27",
|
|
6
6
|
"main": "dist/index.es.js",
|
|
7
7
|
"module": "dist/index.es.js",
|
|
8
8
|
"exports": {
|
|
@@ -34,8 +34,8 @@
|
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@fileverse-dev/dsheets-templates": "^0.0.28",
|
|
37
|
-
"@fileverse-dev/formulajs": "^4.4.
|
|
38
|
-
"@fileverse-dev/fortune-react": "^1.2.
|
|
37
|
+
"@fileverse-dev/formulajs": "^4.4.30",
|
|
38
|
+
"@fileverse-dev/fortune-react": "^1.2.28",
|
|
39
39
|
"@fileverse/ui": "^4.1.7-patch-40",
|
|
40
40
|
"classnames": "^2.5.1",
|
|
41
41
|
"exceljs": "^4.4.0",
|
|
@@ -78,4 +78,4 @@
|
|
|
78
78
|
"typescript": "^5.2.2",
|
|
79
79
|
"vite": "^5.0.0"
|
|
80
80
|
}
|
|
81
|
-
}
|
|
81
|
+
}
|