@leankylin-sheet/react 4.0.63 → 4.0.64
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.
|
@@ -123,4 +123,5 @@ export declare function generateAPIs(context: Context, setContext: (recipe: (ctx
|
|
|
123
123
|
calculateSheetByCells: (cells: any) => void;
|
|
124
124
|
dataToCelldata: (data: CellMatrix | undefined) => CellWithRowAndCol[];
|
|
125
125
|
celldataToData: (celldata: CellWithRowAndCol[], rowCount?: number, colCount?: number) => CellMatrix | null;
|
|
126
|
+
setCtx: (cb: (ctx: Context) => void) => void;
|
|
126
127
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Settings, CellWithRowAndCol, Sheet as SheetType, Op, CellMatrix } from "@leankylin-sheet/core";
|
|
1
|
+
import { Settings, Context, CellWithRowAndCol, Sheet as SheetType, Op, CellMatrix } from "@leankylin-sheet/core";
|
|
2
2
|
import React from "react";
|
|
3
3
|
import "./index.css";
|
|
4
4
|
import { RefValues } from "../../context";
|
|
@@ -131,5 +131,6 @@ declare const Workbook: React.ForwardRefExoticComponent<Settings & AdditionalPro
|
|
|
131
131
|
calculateSheetByCells: (cells: any) => void;
|
|
132
132
|
dataToCelldata: (data: CellMatrix | undefined) => CellWithRowAndCol[];
|
|
133
133
|
celldataToData: (celldata: CellWithRowAndCol[], rowCount?: number | undefined, colCount?: number | undefined) => CellMatrix | null;
|
|
134
|
+
setCtx: (cb: (ctx: Context) => void) => void;
|
|
134
135
|
}>>;
|
|
135
136
|
export default Workbook;
|
package/dist/index.esm.js
CHANGED
|
@@ -10330,6 +10330,11 @@ function generateAPIs(context, setContext, handleUndo, handleRedo, settings, cel
|
|
|
10330
10330
|
},
|
|
10331
10331
|
celldataToData: function celldataToData(celldata, rowCount, colCount) {
|
|
10332
10332
|
return api.celldataToData(celldata, rowCount, colCount);
|
|
10333
|
+
},
|
|
10334
|
+
setCtx: function setCtx(cb) {
|
|
10335
|
+
setContext(function (draftCtx) {
|
|
10336
|
+
return cb(draftCtx);
|
|
10337
|
+
});
|
|
10333
10338
|
}
|
|
10334
10339
|
};
|
|
10335
10340
|
}
|
package/dist/index.js
CHANGED
|
@@ -10340,6 +10340,11 @@ function generateAPIs(context, setContext, handleUndo, handleRedo, settings, cel
|
|
|
10340
10340
|
},
|
|
10341
10341
|
celldataToData: function celldataToData(celldata, rowCount, colCount) {
|
|
10342
10342
|
return core.api.celldataToData(celldata, rowCount, colCount);
|
|
10343
|
+
},
|
|
10344
|
+
setCtx: function setCtx(cb) {
|
|
10345
|
+
setContext(function (draftCtx) {
|
|
10346
|
+
return cb(draftCtx);
|
|
10347
|
+
});
|
|
10343
10348
|
}
|
|
10344
10349
|
};
|
|
10345
10350
|
}
|
package/dist/index.umd.js
CHANGED
|
@@ -110013,6 +110013,11 @@
|
|
|
110013
110013
|
},
|
|
110014
110014
|
celldataToData: function celldataToData(celldata, rowCount, colCount) {
|
|
110015
110015
|
return index.celldataToData(celldata, rowCount, colCount);
|
|
110016
|
+
},
|
|
110017
|
+
setCtx: function setCtx(cb) {
|
|
110018
|
+
setContext(function (draftCtx) {
|
|
110019
|
+
return cb(draftCtx);
|
|
110020
|
+
});
|
|
110016
110021
|
}
|
|
110017
110022
|
};
|
|
110018
110023
|
}
|