@fileverse-dev/fortune-core 1.0.71 → 1.0.73
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/es/events/paste.js +0 -2
- package/es/modules/formula.js +7 -1
- package/lib/events/paste.js +0 -2
- package/lib/modules/formula.js +7 -1
- package/package.json +1 -1
package/es/events/paste.js
CHANGED
|
@@ -855,7 +855,6 @@ function pasteHandlerOfCopyPaste(ctx, copyRange) {
|
|
|
855
855
|
var value = null;
|
|
856
856
|
if ((_f = copyData[h - mth]) === null || _f === void 0 ? void 0 : _f[c - mtc]) {
|
|
857
857
|
value = _.cloneDeep(copyData[h - mth][c - mtc]);
|
|
858
|
-
console.log("value", value);
|
|
859
858
|
if ((value === null || value === void 0 ? void 0 : value.v) && (value === null || value === void 0 ? void 0 : value.f) && (value === null || value === void 0 ? void 0 : value.isDataBlockFormula) && arr.length === 1) {
|
|
860
859
|
value.m = "Loading...";
|
|
861
860
|
}
|
|
@@ -876,7 +875,6 @@ function pasteHandlerOfCopyPaste(ctx, copyRange) {
|
|
|
876
875
|
}
|
|
877
876
|
var funcV = execfunction(ctx, func, h, c, undefined, undefined, true);
|
|
878
877
|
var afterUpdateCell = ctx.hooks.afterUpdateCell;
|
|
879
|
-
console.log("fortune about to call afterUpdateCell");
|
|
880
878
|
if (afterUpdateCell && arr.length === 1) {
|
|
881
879
|
afterUpdateCell(h, c, null, __assign(__assign({}, value), {
|
|
882
880
|
v: funcV[1],
|
package/es/modules/formula.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
1
2
|
var __assign = this && this.__assign || function () {
|
|
2
3
|
__assign = Object.assign || function (t) {
|
|
3
4
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
@@ -95,6 +96,9 @@ var FormulaCache = function () {
|
|
|
95
96
|
for (var row = startRow; row <= endRow; row += 1) {
|
|
96
97
|
var colFragment = [];
|
|
97
98
|
for (var col = startCol; col <= endCol; col += 1) {
|
|
99
|
+
if (_typeof(options) === "object" && row === options.row && col === options.column) {
|
|
100
|
+
continue;
|
|
101
|
+
}
|
|
98
102
|
var cell = ((_c = context === null || context === void 0 ? void 0 : context.formulaCache.execFunctionGlobalData) === null || _c === void 0 ? void 0 : _c["".concat(row, "_").concat(col, "_").concat(id)]) || ((_d = flowdata === null || flowdata === void 0 ? void 0 : flowdata[row]) === null || _d === void 0 ? void 0 : _d[col]);
|
|
99
103
|
var v = that.tryGetCellAsNumber(cell);
|
|
100
104
|
if ((((_e = cell === null || cell === void 0 ? void 0 : cell.m) === null || _e === void 0 ? void 0 : _e.includes("ETH")) || ((_f = cell === null || cell === void 0 ? void 0 : cell.m) === null || _f === void 0 ? void 0 : _f.includes("SOL")) || ((_g = cell === null || cell === void 0 ? void 0 : cell.m) === null || _g === void 0 ? void 0 : _g.includes("BTC"))) && cryptoDenomination !== "Error") {
|
|
@@ -698,7 +702,9 @@ export function execfunction(ctx, txt, r, c, id, calcChainSet, isrefresh, notIns
|
|
|
698
702
|
ctx.calculateSheetId = id;
|
|
699
703
|
ctx.formulaCache.parser.context = ctx;
|
|
700
704
|
var parsedResponse = ctx.formulaCache.parser.parse(txt.substring(1), {
|
|
701
|
-
sheetId: id || ctx.currentSheetId
|
|
705
|
+
sheetId: id || ctx.currentSheetId,
|
|
706
|
+
row: r,
|
|
707
|
+
column: c
|
|
702
708
|
});
|
|
703
709
|
var formulaError = parsedResponse.error;
|
|
704
710
|
var result = parsedResponse.result;
|
package/lib/events/paste.js
CHANGED
|
@@ -863,7 +863,6 @@ function pasteHandlerOfCopyPaste(ctx, copyRange) {
|
|
|
863
863
|
var value = null;
|
|
864
864
|
if ((_f = copyData[h - mth]) === null || _f === void 0 ? void 0 : _f[c - mtc]) {
|
|
865
865
|
value = _lodash.default.cloneDeep(copyData[h - mth][c - mtc]);
|
|
866
|
-
console.log("value", value);
|
|
867
866
|
if ((value === null || value === void 0 ? void 0 : value.v) && (value === null || value === void 0 ? void 0 : value.f) && (value === null || value === void 0 ? void 0 : value.isDataBlockFormula) && arr.length === 1) {
|
|
868
867
|
value.m = "Loading...";
|
|
869
868
|
}
|
|
@@ -884,7 +883,6 @@ function pasteHandlerOfCopyPaste(ctx, copyRange) {
|
|
|
884
883
|
}
|
|
885
884
|
var funcV = (0, _formula.execfunction)(ctx, func, h, c, undefined, undefined, true);
|
|
886
885
|
var afterUpdateCell = ctx.hooks.afterUpdateCell;
|
|
887
|
-
console.log("fortune about to call afterUpdateCell");
|
|
888
886
|
if (afterUpdateCell && arr.length === 1) {
|
|
889
887
|
afterUpdateCell(h, c, null, __assign(__assign({}, value), {
|
|
890
888
|
v: funcV[1],
|
package/lib/modules/formula.js
CHANGED
|
@@ -39,6 +39,7 @@ var _color = require("./color");
|
|
|
39
39
|
var _location = require("./location");
|
|
40
40
|
var _2 = require(".");
|
|
41
41
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
42
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
42
43
|
var __assign = void 0 && (void 0).__assign || function () {
|
|
43
44
|
__assign = Object.assign || function (t) {
|
|
44
45
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
@@ -125,6 +126,9 @@ var FormulaCache = exports.FormulaCache = function () {
|
|
|
125
126
|
for (var row = startRow; row <= endRow; row += 1) {
|
|
126
127
|
var colFragment = [];
|
|
127
128
|
for (var col = startCol; col <= endCol; col += 1) {
|
|
129
|
+
if (_typeof(options) === "object" && row === options.row && col === options.column) {
|
|
130
|
+
continue;
|
|
131
|
+
}
|
|
128
132
|
var cell = ((_c = context === null || context === void 0 ? void 0 : context.formulaCache.execFunctionGlobalData) === null || _c === void 0 ? void 0 : _c["".concat(row, "_").concat(col, "_").concat(id)]) || ((_d = flowdata === null || flowdata === void 0 ? void 0 : flowdata[row]) === null || _d === void 0 ? void 0 : _d[col]);
|
|
129
133
|
var v = that.tryGetCellAsNumber(cell);
|
|
130
134
|
if ((((_e = cell === null || cell === void 0 ? void 0 : cell.m) === null || _e === void 0 ? void 0 : _e.includes("ETH")) || ((_f = cell === null || cell === void 0 ? void 0 : cell.m) === null || _f === void 0 ? void 0 : _f.includes("SOL")) || ((_g = cell === null || cell === void 0 ? void 0 : cell.m) === null || _g === void 0 ? void 0 : _g.includes("BTC"))) && cryptoDenomination !== "Error") {
|
|
@@ -727,7 +731,9 @@ function execfunction(ctx, txt, r, c, id, calcChainSet, isrefresh, notInsertFunc
|
|
|
727
731
|
ctx.calculateSheetId = id;
|
|
728
732
|
ctx.formulaCache.parser.context = ctx;
|
|
729
733
|
var parsedResponse = ctx.formulaCache.parser.parse(txt.substring(1), {
|
|
730
|
-
sheetId: id || ctx.currentSheetId
|
|
734
|
+
sheetId: id || ctx.currentSheetId,
|
|
735
|
+
row: r,
|
|
736
|
+
column: c
|
|
731
737
|
});
|
|
732
738
|
var formulaError = parsedResponse.error;
|
|
733
739
|
var result = parsedResponse.result;
|