microboard-temp 0.13.56 → 0.13.57

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.
@@ -13031,8 +13031,9 @@ var init_BaseItem = __esm(() => {
13031
13031
  _physicsHalfExtent = -1;
13032
13032
  get physicsHalfExtent() {
13033
13033
  if (this._physicsHalfExtent < 0) {
13034
- const w = Math.max(this.right - this.left, 1);
13035
- const h = Math.max(this.bottom - this.top, 1);
13034
+ const mbr = this.getMbr();
13035
+ const w = Math.max(mbr.getWidth(), 1);
13036
+ const h = Math.max(mbr.getHeight(), 1);
13036
13037
  this._physicsHalfExtent = Math.max(w, h) * 0.5;
13037
13038
  }
13038
13039
  return this._physicsHalfExtent;
@@ -60923,8 +60924,9 @@ class ForceGraphEngine {
60923
60924
  if (!activeIds.has(item.getId()))
60924
60925
  continue;
60925
60926
  const pos = item.transformation.getTranslation();
60926
- const w = Math.max(item.right - item.left, 1);
60927
- const h2 = Math.max(item.bottom - item.top, 1);
60927
+ const mbr = item.getMbr();
60928
+ const w = Math.max(mbr.getWidth(), 1);
60929
+ const h2 = Math.max(mbr.getHeight(), 1);
60928
60930
  snapMap.set(item.getId(), { id: item.getId(), cx: pos.x + w * 0.5, cy: pos.y + h2 * 0.5, w, h: h2 });
60929
60931
  }
60930
60932
  const snap = Array.from(snapMap.values());
package/dist/cjs/index.js CHANGED
@@ -13031,8 +13031,9 @@ var init_BaseItem = __esm(() => {
13031
13031
  _physicsHalfExtent = -1;
13032
13032
  get physicsHalfExtent() {
13033
13033
  if (this._physicsHalfExtent < 0) {
13034
- const w = Math.max(this.right - this.left, 1);
13035
- const h = Math.max(this.bottom - this.top, 1);
13034
+ const mbr = this.getMbr();
13035
+ const w = Math.max(mbr.getWidth(), 1);
13036
+ const h = Math.max(mbr.getHeight(), 1);
13036
13037
  this._physicsHalfExtent = Math.max(w, h) * 0.5;
13037
13038
  }
13038
13039
  return this._physicsHalfExtent;
@@ -60923,8 +60924,9 @@ class ForceGraphEngine {
60923
60924
  if (!activeIds.has(item.getId()))
60924
60925
  continue;
60925
60926
  const pos = item.transformation.getTranslation();
60926
- const w = Math.max(item.right - item.left, 1);
60927
- const h2 = Math.max(item.bottom - item.top, 1);
60927
+ const mbr = item.getMbr();
60928
+ const w = Math.max(mbr.getWidth(), 1);
60929
+ const h2 = Math.max(mbr.getHeight(), 1);
60928
60930
  snapMap.set(item.getId(), { id: item.getId(), cx: pos.x + w * 0.5, cy: pos.y + h2 * 0.5, w, h: h2 });
60929
60931
  }
60930
60932
  const snap = Array.from(snapMap.values());
package/dist/cjs/node.js CHANGED
@@ -13051,8 +13051,9 @@ var init_BaseItem = __esm(() => {
13051
13051
  _physicsHalfExtent = -1;
13052
13052
  get physicsHalfExtent() {
13053
13053
  if (this._physicsHalfExtent < 0) {
13054
- const w = Math.max(this.right - this.left, 1);
13055
- const h = Math.max(this.bottom - this.top, 1);
13054
+ const mbr = this.getMbr();
13055
+ const w = Math.max(mbr.getWidth(), 1);
13056
+ const h = Math.max(mbr.getHeight(), 1);
13056
13057
  this._physicsHalfExtent = Math.max(w, h) * 0.5;
13057
13058
  }
13058
13059
  return this._physicsHalfExtent;
@@ -63398,8 +63399,9 @@ class ForceGraphEngine {
63398
63399
  if (!activeIds.has(item.getId()))
63399
63400
  continue;
63400
63401
  const pos = item.transformation.getTranslation();
63401
- const w = Math.max(item.right - item.left, 1);
63402
- const h2 = Math.max(item.bottom - item.top, 1);
63402
+ const mbr = item.getMbr();
63403
+ const w = Math.max(mbr.getWidth(), 1);
63404
+ const h2 = Math.max(mbr.getHeight(), 1);
63403
63405
  snapMap.set(item.getId(), { id: item.getId(), cx: pos.x + w * 0.5, cy: pos.y + h2 * 0.5, w, h: h2 });
63404
63406
  }
63405
63407
  const snap = Array.from(snapMap.values());
@@ -13003,8 +13003,9 @@ var init_BaseItem = __esm(() => {
13003
13003
  _physicsHalfExtent = -1;
13004
13004
  get physicsHalfExtent() {
13005
13005
  if (this._physicsHalfExtent < 0) {
13006
- const w = Math.max(this.right - this.left, 1);
13007
- const h = Math.max(this.bottom - this.top, 1);
13006
+ const mbr = this.getMbr();
13007
+ const w = Math.max(mbr.getWidth(), 1);
13008
+ const h = Math.max(mbr.getHeight(), 1);
13008
13009
  this._physicsHalfExtent = Math.max(w, h) * 0.5;
13009
13010
  }
13010
13011
  return this._physicsHalfExtent;
@@ -60666,8 +60667,9 @@ class ForceGraphEngine {
60666
60667
  if (!activeIds.has(item.getId()))
60667
60668
  continue;
60668
60669
  const pos = item.transformation.getTranslation();
60669
- const w = Math.max(item.right - item.left, 1);
60670
- const h2 = Math.max(item.bottom - item.top, 1);
60670
+ const mbr = item.getMbr();
60671
+ const w = Math.max(mbr.getWidth(), 1);
60672
+ const h2 = Math.max(mbr.getHeight(), 1);
60671
60673
  snapMap.set(item.getId(), { id: item.getId(), cx: pos.x + w * 0.5, cy: pos.y + h2 * 0.5, w, h: h2 });
60672
60674
  }
60673
60675
  const snap = Array.from(snapMap.values());
package/dist/esm/index.js CHANGED
@@ -12996,8 +12996,9 @@ var init_BaseItem = __esm(() => {
12996
12996
  _physicsHalfExtent = -1;
12997
12997
  get physicsHalfExtent() {
12998
12998
  if (this._physicsHalfExtent < 0) {
12999
- const w = Math.max(this.right - this.left, 1);
13000
- const h = Math.max(this.bottom - this.top, 1);
12999
+ const mbr = this.getMbr();
13000
+ const w = Math.max(mbr.getWidth(), 1);
13001
+ const h = Math.max(mbr.getHeight(), 1);
13001
13002
  this._physicsHalfExtent = Math.max(w, h) * 0.5;
13002
13003
  }
13003
13004
  return this._physicsHalfExtent;
@@ -60659,8 +60660,9 @@ class ForceGraphEngine {
60659
60660
  if (!activeIds.has(item.getId()))
60660
60661
  continue;
60661
60662
  const pos = item.transformation.getTranslation();
60662
- const w = Math.max(item.right - item.left, 1);
60663
- const h2 = Math.max(item.bottom - item.top, 1);
60663
+ const mbr = item.getMbr();
60664
+ const w = Math.max(mbr.getWidth(), 1);
60665
+ const h2 = Math.max(mbr.getHeight(), 1);
60664
60666
  snapMap.set(item.getId(), { id: item.getId(), cx: pos.x + w * 0.5, cy: pos.y + h2 * 0.5, w, h: h2 });
60665
60667
  }
60666
60668
  const snap = Array.from(snapMap.values());
package/dist/esm/node.js CHANGED
@@ -13018,8 +13018,9 @@ var init_BaseItem = __esm(() => {
13018
13018
  _physicsHalfExtent = -1;
13019
13019
  get physicsHalfExtent() {
13020
13020
  if (this._physicsHalfExtent < 0) {
13021
- const w = Math.max(this.right - this.left, 1);
13022
- const h = Math.max(this.bottom - this.top, 1);
13021
+ const mbr = this.getMbr();
13022
+ const w = Math.max(mbr.getWidth(), 1);
13023
+ const h = Math.max(mbr.getHeight(), 1);
13023
13024
  this._physicsHalfExtent = Math.max(w, h) * 0.5;
13024
13025
  }
13025
13026
  return this._physicsHalfExtent;
@@ -63123,8 +63124,9 @@ class ForceGraphEngine {
63123
63124
  if (!activeIds.has(item.getId()))
63124
63125
  continue;
63125
63126
  const pos = item.transformation.getTranslation();
63126
- const w = Math.max(item.right - item.left, 1);
63127
- const h2 = Math.max(item.bottom - item.top, 1);
63127
+ const mbr = item.getMbr();
63128
+ const w = Math.max(mbr.getWidth(), 1);
63129
+ const h2 = Math.max(mbr.getHeight(), 1);
63128
63130
  snapMap.set(item.getId(), { id: item.getId(), cx: pos.x + w * 0.5, cy: pos.y + h2 * 0.5, w, h: h2 });
63129
63131
  }
63130
63132
  const snap = Array.from(snapMap.values());
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "microboard-temp",
3
- "version": "0.13.56",
3
+ "version": "0.13.57",
4
4
  "description": "A flexible interactive whiteboard library",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",