microboard-temp 0.4.80 → 0.4.82
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/cjs/browser.js +7 -3
- package/dist/cjs/index.js +7 -3
- package/dist/cjs/node.js +7 -3
- package/dist/esm/browser.js +7 -3
- package/dist/esm/index.js +7 -3
- package/dist/esm/node.js +7 -3
- package/package.json +1 -1
package/dist/cjs/browser.js
CHANGED
|
@@ -20792,6 +20792,10 @@ class SpatialIndex {
|
|
|
20792
20792
|
if ("index" in item && item.index) {
|
|
20793
20793
|
item.removeChildItems(item.index.list());
|
|
20794
20794
|
}
|
|
20795
|
+
if (item.parent !== "Board") {
|
|
20796
|
+
const parentFrame = this.items.getById(item.parent);
|
|
20797
|
+
parentFrame?.removeChildItems(item);
|
|
20798
|
+
}
|
|
20795
20799
|
this.itemsArray.splice(this.itemsArray.indexOf(item), 1);
|
|
20796
20800
|
this.itemsIndex.remove(item);
|
|
20797
20801
|
this.Mbr = new Mbr;
|
|
@@ -48025,11 +48029,11 @@ class Deck extends BaseItem {
|
|
|
48025
48029
|
updateMbr() {
|
|
48026
48030
|
const { translateX, translateY } = this.transformation.matrix;
|
|
48027
48031
|
const items = this.index.list();
|
|
48028
|
-
const itemsMbr = items[0]
|
|
48032
|
+
const itemsMbr = items[0]?.getMbr().combine(items.slice(1).map((item) => item.getMbr()));
|
|
48029
48033
|
this.left = translateX;
|
|
48030
48034
|
this.top = translateY;
|
|
48031
|
-
this.right = translateX + itemsMbr
|
|
48032
|
-
this.bottom = translateY + itemsMbr
|
|
48035
|
+
this.right = translateX + (itemsMbr?.getWidth() || 0);
|
|
48036
|
+
this.bottom = translateY + (itemsMbr?.getHeight() || 0);
|
|
48033
48037
|
}
|
|
48034
48038
|
deserialize(data) {
|
|
48035
48039
|
super.deserialize(data);
|
package/dist/cjs/index.js
CHANGED
|
@@ -20792,6 +20792,10 @@ class SpatialIndex {
|
|
|
20792
20792
|
if ("index" in item && item.index) {
|
|
20793
20793
|
item.removeChildItems(item.index.list());
|
|
20794
20794
|
}
|
|
20795
|
+
if (item.parent !== "Board") {
|
|
20796
|
+
const parentFrame = this.items.getById(item.parent);
|
|
20797
|
+
parentFrame?.removeChildItems(item);
|
|
20798
|
+
}
|
|
20795
20799
|
this.itemsArray.splice(this.itemsArray.indexOf(item), 1);
|
|
20796
20800
|
this.itemsIndex.remove(item);
|
|
20797
20801
|
this.Mbr = new Mbr;
|
|
@@ -48025,11 +48029,11 @@ class Deck extends BaseItem {
|
|
|
48025
48029
|
updateMbr() {
|
|
48026
48030
|
const { translateX, translateY } = this.transformation.matrix;
|
|
48027
48031
|
const items = this.index.list();
|
|
48028
|
-
const itemsMbr = items[0]
|
|
48032
|
+
const itemsMbr = items[0]?.getMbr().combine(items.slice(1).map((item) => item.getMbr()));
|
|
48029
48033
|
this.left = translateX;
|
|
48030
48034
|
this.top = translateY;
|
|
48031
|
-
this.right = translateX + itemsMbr
|
|
48032
|
-
this.bottom = translateY + itemsMbr
|
|
48035
|
+
this.right = translateX + (itemsMbr?.getWidth() || 0);
|
|
48036
|
+
this.bottom = translateY + (itemsMbr?.getHeight() || 0);
|
|
48033
48037
|
}
|
|
48034
48038
|
deserialize(data) {
|
|
48035
48039
|
super.deserialize(data);
|
package/dist/cjs/node.js
CHANGED
|
@@ -23264,6 +23264,10 @@ class SpatialIndex {
|
|
|
23264
23264
|
if ("index" in item && item.index) {
|
|
23265
23265
|
item.removeChildItems(item.index.list());
|
|
23266
23266
|
}
|
|
23267
|
+
if (item.parent !== "Board") {
|
|
23268
|
+
const parentFrame = this.items.getById(item.parent);
|
|
23269
|
+
parentFrame?.removeChildItems(item);
|
|
23270
|
+
}
|
|
23267
23271
|
this.itemsArray.splice(this.itemsArray.indexOf(item), 1);
|
|
23268
23272
|
this.itemsIndex.remove(item);
|
|
23269
23273
|
this.Mbr = new Mbr;
|
|
@@ -50498,11 +50502,11 @@ class Deck extends BaseItem {
|
|
|
50498
50502
|
updateMbr() {
|
|
50499
50503
|
const { translateX, translateY } = this.transformation.matrix;
|
|
50500
50504
|
const items = this.index.list();
|
|
50501
|
-
const itemsMbr = items[0]
|
|
50505
|
+
const itemsMbr = items[0]?.getMbr().combine(items.slice(1).map((item) => item.getMbr()));
|
|
50502
50506
|
this.left = translateX;
|
|
50503
50507
|
this.top = translateY;
|
|
50504
|
-
this.right = translateX + itemsMbr
|
|
50505
|
-
this.bottom = translateY + itemsMbr
|
|
50508
|
+
this.right = translateX + (itemsMbr?.getWidth() || 0);
|
|
50509
|
+
this.bottom = translateY + (itemsMbr?.getHeight() || 0);
|
|
50506
50510
|
}
|
|
50507
50511
|
deserialize(data) {
|
|
50508
50512
|
super.deserialize(data);
|
package/dist/esm/browser.js
CHANGED
|
@@ -20641,6 +20641,10 @@ class SpatialIndex {
|
|
|
20641
20641
|
if ("index" in item && item.index) {
|
|
20642
20642
|
item.removeChildItems(item.index.list());
|
|
20643
20643
|
}
|
|
20644
|
+
if (item.parent !== "Board") {
|
|
20645
|
+
const parentFrame = this.items.getById(item.parent);
|
|
20646
|
+
parentFrame?.removeChildItems(item);
|
|
20647
|
+
}
|
|
20644
20648
|
this.itemsArray.splice(this.itemsArray.indexOf(item), 1);
|
|
20645
20649
|
this.itemsIndex.remove(item);
|
|
20646
20650
|
this.Mbr = new Mbr;
|
|
@@ -47874,11 +47878,11 @@ class Deck extends BaseItem {
|
|
|
47874
47878
|
updateMbr() {
|
|
47875
47879
|
const { translateX, translateY } = this.transformation.matrix;
|
|
47876
47880
|
const items = this.index.list();
|
|
47877
|
-
const itemsMbr = items[0]
|
|
47881
|
+
const itemsMbr = items[0]?.getMbr().combine(items.slice(1).map((item) => item.getMbr()));
|
|
47878
47882
|
this.left = translateX;
|
|
47879
47883
|
this.top = translateY;
|
|
47880
|
-
this.right = translateX + itemsMbr
|
|
47881
|
-
this.bottom = translateY + itemsMbr
|
|
47884
|
+
this.right = translateX + (itemsMbr?.getWidth() || 0);
|
|
47885
|
+
this.bottom = translateY + (itemsMbr?.getHeight() || 0);
|
|
47882
47886
|
}
|
|
47883
47887
|
deserialize(data) {
|
|
47884
47888
|
super.deserialize(data);
|
package/dist/esm/index.js
CHANGED
|
@@ -20634,6 +20634,10 @@ class SpatialIndex {
|
|
|
20634
20634
|
if ("index" in item && item.index) {
|
|
20635
20635
|
item.removeChildItems(item.index.list());
|
|
20636
20636
|
}
|
|
20637
|
+
if (item.parent !== "Board") {
|
|
20638
|
+
const parentFrame = this.items.getById(item.parent);
|
|
20639
|
+
parentFrame?.removeChildItems(item);
|
|
20640
|
+
}
|
|
20637
20641
|
this.itemsArray.splice(this.itemsArray.indexOf(item), 1);
|
|
20638
20642
|
this.itemsIndex.remove(item);
|
|
20639
20643
|
this.Mbr = new Mbr;
|
|
@@ -47867,11 +47871,11 @@ class Deck extends BaseItem {
|
|
|
47867
47871
|
updateMbr() {
|
|
47868
47872
|
const { translateX, translateY } = this.transformation.matrix;
|
|
47869
47873
|
const items = this.index.list();
|
|
47870
|
-
const itemsMbr = items[0]
|
|
47874
|
+
const itemsMbr = items[0]?.getMbr().combine(items.slice(1).map((item) => item.getMbr()));
|
|
47871
47875
|
this.left = translateX;
|
|
47872
47876
|
this.top = translateY;
|
|
47873
|
-
this.right = translateX + itemsMbr
|
|
47874
|
-
this.bottom = translateY + itemsMbr
|
|
47877
|
+
this.right = translateX + (itemsMbr?.getWidth() || 0);
|
|
47878
|
+
this.bottom = translateY + (itemsMbr?.getHeight() || 0);
|
|
47875
47879
|
}
|
|
47876
47880
|
deserialize(data) {
|
|
47877
47881
|
super.deserialize(data);
|
package/dist/esm/node.js
CHANGED
|
@@ -23101,6 +23101,10 @@ class SpatialIndex {
|
|
|
23101
23101
|
if ("index" in item && item.index) {
|
|
23102
23102
|
item.removeChildItems(item.index.list());
|
|
23103
23103
|
}
|
|
23104
|
+
if (item.parent !== "Board") {
|
|
23105
|
+
const parentFrame = this.items.getById(item.parent);
|
|
23106
|
+
parentFrame?.removeChildItems(item);
|
|
23107
|
+
}
|
|
23104
23108
|
this.itemsArray.splice(this.itemsArray.indexOf(item), 1);
|
|
23105
23109
|
this.itemsIndex.remove(item);
|
|
23106
23110
|
this.Mbr = new Mbr;
|
|
@@ -50335,11 +50339,11 @@ class Deck extends BaseItem {
|
|
|
50335
50339
|
updateMbr() {
|
|
50336
50340
|
const { translateX, translateY } = this.transformation.matrix;
|
|
50337
50341
|
const items = this.index.list();
|
|
50338
|
-
const itemsMbr = items[0]
|
|
50342
|
+
const itemsMbr = items[0]?.getMbr().combine(items.slice(1).map((item) => item.getMbr()));
|
|
50339
50343
|
this.left = translateX;
|
|
50340
50344
|
this.top = translateY;
|
|
50341
|
-
this.right = translateX + itemsMbr
|
|
50342
|
-
this.bottom = translateY + itemsMbr
|
|
50345
|
+
this.right = translateX + (itemsMbr?.getWidth() || 0);
|
|
50346
|
+
this.bottom = translateY + (itemsMbr?.getHeight() || 0);
|
|
50343
50347
|
}
|
|
50344
50348
|
deserialize(data) {
|
|
50345
50349
|
super.deserialize(data);
|