px-jspreadsheet-ce 0.0.9 → 0.0.11
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/package.json +1 -1
- package/src/utils/internal.js +3 -1
- package/src/utils/worksheets.js +6 -0
package/package.json
CHANGED
package/src/utils/internal.js
CHANGED
|
@@ -705,7 +705,9 @@ export const updateCell = function (x, y, value, force) {
|
|
|
705
705
|
}
|
|
706
706
|
|
|
707
707
|
// On change
|
|
708
|
-
|
|
708
|
+
if (!obj.createTableProcess) {
|
|
709
|
+
dispatch.call(obj, 'onchange', obj, obj.records[y] && obj.records[y][x] ? obj.records[y][x].element : null, x, y, value, record.oldValue);
|
|
710
|
+
}
|
|
709
711
|
}
|
|
710
712
|
|
|
711
713
|
return record;
|
package/src/utils/worksheets.js
CHANGED
|
@@ -493,6 +493,7 @@ export const buildWorksheet = async function () {
|
|
|
493
493
|
}
|
|
494
494
|
|
|
495
495
|
libraryBase.jspreadsheet.current = obj;
|
|
496
|
+
obj.createTableProcess = true;
|
|
496
497
|
// prepareTable
|
|
497
498
|
const promises = [];
|
|
498
499
|
|
|
@@ -560,9 +561,11 @@ export const buildWorksheet = async function () {
|
|
|
560
561
|
} else {
|
|
561
562
|
// Prepare table
|
|
562
563
|
prepareTable.call(obj);
|
|
564
|
+
obj.createTableProcess = false;
|
|
563
565
|
}
|
|
564
566
|
|
|
565
567
|
await Promise.all(promises);
|
|
568
|
+
obj.createTableProcess = false;
|
|
566
569
|
|
|
567
570
|
if (typeof spreadsheet.plugins === 'object') {
|
|
568
571
|
Object.entries(spreadsheet.plugins).forEach(function ([, plugin]) {
|
|
@@ -680,8 +683,11 @@ export const updateWorksheet = function (options) {
|
|
|
680
683
|
obj.options = options;
|
|
681
684
|
obj.history = [];
|
|
682
685
|
obj.historyIndex = -1;
|
|
686
|
+
|
|
683
687
|
// Prepare table
|
|
688
|
+
obj.createTableProcess = true;
|
|
684
689
|
prepareTable.call(obj);
|
|
690
|
+
obj.createTableProcess = false;
|
|
685
691
|
};
|
|
686
692
|
|
|
687
693
|
const worksheetPublicMethods = [
|