roosterjs 8.19.1 → 8.19.2

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/rooster.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- // Type definitions for roosterjs (Version 8.19.1)
1
+ // Type definitions for roosterjs (Version 8.19.2)
2
2
  // Generated by dts tool from roosterjs
3
3
  // Project: https://github.com/Microsoft/roosterjs
4
4
 
package/dist/rooster.js CHANGED
@@ -23679,10 +23679,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
23679
23679
  * and the last cell always going to be last selected in the table.
23680
23680
  */
23681
23681
  function normalizeTableSelection(vTable) {
23682
- if (!vTable || !vTable.selection) {
23682
+ var _a = (vTable === null || vTable === void 0 ? void 0 : vTable.selection) || {}, firstCell = _a.firstCell, lastCell = _a.lastCell;
23683
+ if (!vTable || !vTable.selection || !firstCell || !lastCell) {
23683
23684
  return null;
23684
23685
  }
23685
- var _a = vTable.selection, firstCell = _a.firstCell, lastCell = _a.lastCell;
23686
23686
  var rows = vTable.table.rows;
23687
23687
  var newFirst = {
23688
23688
  x: Math.min(firstCell.x, lastCell.x),
@@ -23707,8 +23707,8 @@ function normalizeTableSelection(vTable) {
23707
23707
  coord.x = rowsCells - 1;
23708
23708
  }
23709
23709
  };
23710
- fixCoordinates(firstCell);
23711
- fixCoordinates(lastCell);
23710
+ fixCoordinates(newFirst);
23711
+ fixCoordinates(newLast);
23712
23712
  return { firstCell: newFirst, lastCell: newLast };
23713
23713
  }
23714
23714
  exports.default = normalizeTableSelection;