@corbe30/fortune-excel 2.2.6 → 2.3.0
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/README.md
CHANGED
|
@@ -49,7 +49,7 @@ var ImportHelper = function (props) {
|
|
|
49
49
|
var _a, _b;
|
|
50
50
|
return __generator(this, function (_c) {
|
|
51
51
|
switch (_c.label) {
|
|
52
|
-
case 0: return [4 /*yield*/, (0, Transform_1.transformExcelToFortune)((_b = (_a = e === null || e === void 0 ? void 0 : e.target) === null || _a === void 0 ? void 0 : _a.files) === null || _b === void 0 ? void 0 : _b[0], setSheets, setKey, sheetRef
|
|
52
|
+
case 0: return [4 /*yield*/, (0, Transform_1.transformExcelToFortune)((_b = (_a = e === null || e === void 0 ? void 0 : e.target) === null || _a === void 0 ? void 0 : _a.files) === null || _b === void 0 ? void 0 : _b[0], setSheets, setKey, sheetRef)];
|
|
53
53
|
case 1:
|
|
54
54
|
_c.sent();
|
|
55
55
|
return [2 /*return*/];
|
package/dist/common/Transform.js
CHANGED
|
@@ -113,11 +113,12 @@ var transformExcelToFortune = function (file, setSheets, setKey, sheetRef) { ret
|
|
|
113
113
|
setSheets(lsh.sheets);
|
|
114
114
|
setKey(function (k) { return k + 1; });
|
|
115
115
|
setTimeout(function () {
|
|
116
|
-
|
|
117
|
-
|
|
116
|
+
var _a, _b, _c, _d;
|
|
117
|
+
for (var _i = 0, _e = lsh.sheets; _i < _e.length; _i++) {
|
|
118
|
+
var sheet = _e[_i];
|
|
118
119
|
var config = sheet.config;
|
|
119
|
-
sheetRef.setColumnWidth((config === null || config === void 0 ? void 0 : config.columnlen) || {}, { id: sheet.id });
|
|
120
|
-
sheetRef.setRowHeight((config === null || config === void 0 ? void 0 : config.rowlen) || {}, { id: sheet.id });
|
|
120
|
+
(_b = (_a = sheetRef === null || sheetRef === void 0 ? void 0 : sheetRef.current) === null || _a === void 0 ? void 0 : _a.setColumnWidth) === null || _b === void 0 ? void 0 : _b.call(_a, (config === null || config === void 0 ? void 0 : config.columnlen) || {}, { id: sheet.id });
|
|
121
|
+
(_d = (_c = sheetRef === null || sheetRef === void 0 ? void 0 : sheetRef.current) === null || _c === void 0 ? void 0 : _c.setRowHeight) === null || _d === void 0 ? void 0 : _d.call(_c, (config === null || config === void 0 ? void 0 : config.rowlen) || {}, { id: sheet.id });
|
|
121
122
|
}
|
|
122
123
|
}, 1);
|
|
123
124
|
return [2 /*return*/];
|