microboard-temp 0.13.67 → 0.13.69
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 +10 -1
- package/dist/cjs/index.js +10 -1
- package/dist/cjs/node.js +10 -1
- package/dist/esm/browser.js +10 -1
- package/dist/esm/index.js +10 -1
- package/dist/esm/node.js +10 -1
- package/package.json +1 -1
package/dist/cjs/browser.js
CHANGED
|
@@ -61039,7 +61039,7 @@ class ForceGraphEngine {
|
|
|
61039
61039
|
const dist = Math.sqrt(dx * dx + dy * dy) || 1;
|
|
61040
61040
|
const maxDimA = Math.max(s1.w, s1.h);
|
|
61041
61041
|
const maxDimB = Math.max(s2.w, s2.h);
|
|
61042
|
-
const targetDist = (maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB);
|
|
61042
|
+
const targetDist = ((maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB)) * 1.5;
|
|
61043
61043
|
const force = (dist - targetDist) * conf.FG_SPRING_K;
|
|
61044
61044
|
const fx = dx / dist * force;
|
|
61045
61045
|
const fy = dy / dist * force;
|
|
@@ -62060,7 +62060,16 @@ class Board {
|
|
|
62060
62060
|
select: select2
|
|
62061
62061
|
});
|
|
62062
62062
|
const items = Object.keys(newMap).map((id) => this.items.getById(id)).filter((item) => typeof item !== "undefined");
|
|
62063
|
+
for (const item of items) {
|
|
62064
|
+
const mbr = item.getMbr();
|
|
62065
|
+
const pos = item.transformation.getTranslation();
|
|
62066
|
+
console.log(`[nest-pre] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) mbr=(${mbr.left.toFixed(0)},${mbr.top.toFixed(0)},${mbr.right.toFixed(0)},${mbr.bottom.toFixed(0)}) parent=${item.parent}`);
|
|
62067
|
+
}
|
|
62063
62068
|
this.handleNesting(items);
|
|
62069
|
+
for (const item of items) {
|
|
62070
|
+
const pos = item.transformation.getTranslation();
|
|
62071
|
+
console.log(`[nest-post] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) parent=${item.parent}`);
|
|
62072
|
+
}
|
|
62064
62073
|
this.selection.removeAll();
|
|
62065
62074
|
this.selection.add(items);
|
|
62066
62075
|
this.selection.setContext("EditUnderPointer");
|
package/dist/cjs/index.js
CHANGED
|
@@ -61039,7 +61039,7 @@ class ForceGraphEngine {
|
|
|
61039
61039
|
const dist = Math.sqrt(dx * dx + dy * dy) || 1;
|
|
61040
61040
|
const maxDimA = Math.max(s1.w, s1.h);
|
|
61041
61041
|
const maxDimB = Math.max(s2.w, s2.h);
|
|
61042
|
-
const targetDist = (maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB);
|
|
61042
|
+
const targetDist = ((maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB)) * 1.5;
|
|
61043
61043
|
const force = (dist - targetDist) * conf.FG_SPRING_K;
|
|
61044
61044
|
const fx = dx / dist * force;
|
|
61045
61045
|
const fy = dy / dist * force;
|
|
@@ -62060,7 +62060,16 @@ class Board {
|
|
|
62060
62060
|
select: select2
|
|
62061
62061
|
});
|
|
62062
62062
|
const items = Object.keys(newMap).map((id) => this.items.getById(id)).filter((item) => typeof item !== "undefined");
|
|
62063
|
+
for (const item of items) {
|
|
62064
|
+
const mbr = item.getMbr();
|
|
62065
|
+
const pos = item.transformation.getTranslation();
|
|
62066
|
+
console.log(`[nest-pre] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) mbr=(${mbr.left.toFixed(0)},${mbr.top.toFixed(0)},${mbr.right.toFixed(0)},${mbr.bottom.toFixed(0)}) parent=${item.parent}`);
|
|
62067
|
+
}
|
|
62063
62068
|
this.handleNesting(items);
|
|
62069
|
+
for (const item of items) {
|
|
62070
|
+
const pos = item.transformation.getTranslation();
|
|
62071
|
+
console.log(`[nest-post] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) parent=${item.parent}`);
|
|
62072
|
+
}
|
|
62064
62073
|
this.selection.removeAll();
|
|
62065
62074
|
this.selection.add(items);
|
|
62066
62075
|
this.selection.setContext("EditUnderPointer");
|
package/dist/cjs/node.js
CHANGED
|
@@ -63514,7 +63514,7 @@ class ForceGraphEngine {
|
|
|
63514
63514
|
const dist = Math.sqrt(dx * dx + dy * dy) || 1;
|
|
63515
63515
|
const maxDimA = Math.max(s1.w, s1.h);
|
|
63516
63516
|
const maxDimB = Math.max(s2.w, s2.h);
|
|
63517
|
-
const targetDist = (maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB);
|
|
63517
|
+
const targetDist = ((maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB)) * 1.5;
|
|
63518
63518
|
const force = (dist - targetDist) * conf.FG_SPRING_K;
|
|
63519
63519
|
const fx = dx / dist * force;
|
|
63520
63520
|
const fy = dy / dist * force;
|
|
@@ -64535,7 +64535,16 @@ class Board {
|
|
|
64535
64535
|
select: select2
|
|
64536
64536
|
});
|
|
64537
64537
|
const items = Object.keys(newMap).map((id) => this.items.getById(id)).filter((item) => typeof item !== "undefined");
|
|
64538
|
+
for (const item of items) {
|
|
64539
|
+
const mbr = item.getMbr();
|
|
64540
|
+
const pos = item.transformation.getTranslation();
|
|
64541
|
+
console.log(`[nest-pre] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) mbr=(${mbr.left.toFixed(0)},${mbr.top.toFixed(0)},${mbr.right.toFixed(0)},${mbr.bottom.toFixed(0)}) parent=${item.parent}`);
|
|
64542
|
+
}
|
|
64538
64543
|
this.handleNesting(items);
|
|
64544
|
+
for (const item of items) {
|
|
64545
|
+
const pos = item.transformation.getTranslation();
|
|
64546
|
+
console.log(`[nest-post] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) parent=${item.parent}`);
|
|
64547
|
+
}
|
|
64539
64548
|
this.selection.removeAll();
|
|
64540
64549
|
this.selection.add(items);
|
|
64541
64550
|
this.selection.setContext("EditUnderPointer");
|
package/dist/esm/browser.js
CHANGED
|
@@ -60782,7 +60782,7 @@ class ForceGraphEngine {
|
|
|
60782
60782
|
const dist = Math.sqrt(dx * dx + dy * dy) || 1;
|
|
60783
60783
|
const maxDimA = Math.max(s1.w, s1.h);
|
|
60784
60784
|
const maxDimB = Math.max(s2.w, s2.h);
|
|
60785
|
-
const targetDist = (maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB);
|
|
60785
|
+
const targetDist = ((maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB)) * 1.5;
|
|
60786
60786
|
const force = (dist - targetDist) * conf.FG_SPRING_K;
|
|
60787
60787
|
const fx = dx / dist * force;
|
|
60788
60788
|
const fy = dy / dist * force;
|
|
@@ -61803,7 +61803,16 @@ class Board {
|
|
|
61803
61803
|
select: select2
|
|
61804
61804
|
});
|
|
61805
61805
|
const items = Object.keys(newMap).map((id) => this.items.getById(id)).filter((item) => typeof item !== "undefined");
|
|
61806
|
+
for (const item of items) {
|
|
61807
|
+
const mbr = item.getMbr();
|
|
61808
|
+
const pos = item.transformation.getTranslation();
|
|
61809
|
+
console.log(`[nest-pre] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) mbr=(${mbr.left.toFixed(0)},${mbr.top.toFixed(0)},${mbr.right.toFixed(0)},${mbr.bottom.toFixed(0)}) parent=${item.parent}`);
|
|
61810
|
+
}
|
|
61806
61811
|
this.handleNesting(items);
|
|
61812
|
+
for (const item of items) {
|
|
61813
|
+
const pos = item.transformation.getTranslation();
|
|
61814
|
+
console.log(`[nest-post] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) parent=${item.parent}`);
|
|
61815
|
+
}
|
|
61807
61816
|
this.selection.removeAll();
|
|
61808
61817
|
this.selection.add(items);
|
|
61809
61818
|
this.selection.setContext("EditUnderPointer");
|
package/dist/esm/index.js
CHANGED
|
@@ -60775,7 +60775,7 @@ class ForceGraphEngine {
|
|
|
60775
60775
|
const dist = Math.sqrt(dx * dx + dy * dy) || 1;
|
|
60776
60776
|
const maxDimA = Math.max(s1.w, s1.h);
|
|
60777
60777
|
const maxDimB = Math.max(s2.w, s2.h);
|
|
60778
|
-
const targetDist = (maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB);
|
|
60778
|
+
const targetDist = ((maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB)) * 1.5;
|
|
60779
60779
|
const force = (dist - targetDist) * conf.FG_SPRING_K;
|
|
60780
60780
|
const fx = dx / dist * force;
|
|
60781
60781
|
const fy = dy / dist * force;
|
|
@@ -61796,7 +61796,16 @@ class Board {
|
|
|
61796
61796
|
select: select2
|
|
61797
61797
|
});
|
|
61798
61798
|
const items = Object.keys(newMap).map((id) => this.items.getById(id)).filter((item) => typeof item !== "undefined");
|
|
61799
|
+
for (const item of items) {
|
|
61800
|
+
const mbr = item.getMbr();
|
|
61801
|
+
const pos = item.transformation.getTranslation();
|
|
61802
|
+
console.log(`[nest-pre] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) mbr=(${mbr.left.toFixed(0)},${mbr.top.toFixed(0)},${mbr.right.toFixed(0)},${mbr.bottom.toFixed(0)}) parent=${item.parent}`);
|
|
61803
|
+
}
|
|
61799
61804
|
this.handleNesting(items);
|
|
61805
|
+
for (const item of items) {
|
|
61806
|
+
const pos = item.transformation.getTranslation();
|
|
61807
|
+
console.log(`[nest-post] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) parent=${item.parent}`);
|
|
61808
|
+
}
|
|
61800
61809
|
this.selection.removeAll();
|
|
61801
61810
|
this.selection.add(items);
|
|
61802
61811
|
this.selection.setContext("EditUnderPointer");
|
package/dist/esm/node.js
CHANGED
|
@@ -63239,7 +63239,7 @@ class ForceGraphEngine {
|
|
|
63239
63239
|
const dist = Math.sqrt(dx * dx + dy * dy) || 1;
|
|
63240
63240
|
const maxDimA = Math.max(s1.w, s1.h);
|
|
63241
63241
|
const maxDimB = Math.max(s2.w, s2.h);
|
|
63242
|
-
const targetDist = (maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB);
|
|
63242
|
+
const targetDist = ((maxDimA + maxDimB) * 0.5 + Math.max(maxDimA, maxDimB)) * 1.5;
|
|
63243
63243
|
const force = (dist - targetDist) * conf.FG_SPRING_K;
|
|
63244
63244
|
const fx = dx / dist * force;
|
|
63245
63245
|
const fy = dy / dist * force;
|
|
@@ -64260,7 +64260,16 @@ class Board {
|
|
|
64260
64260
|
select: select2
|
|
64261
64261
|
});
|
|
64262
64262
|
const items = Object.keys(newMap).map((id) => this.items.getById(id)).filter((item) => typeof item !== "undefined");
|
|
64263
|
+
for (const item of items) {
|
|
64264
|
+
const mbr = item.getMbr();
|
|
64265
|
+
const pos = item.transformation.getTranslation();
|
|
64266
|
+
console.log(`[nest-pre] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) mbr=(${mbr.left.toFixed(0)},${mbr.top.toFixed(0)},${mbr.right.toFixed(0)},${mbr.bottom.toFixed(0)}) parent=${item.parent}`);
|
|
64267
|
+
}
|
|
64263
64268
|
this.handleNesting(items);
|
|
64269
|
+
for (const item of items) {
|
|
64270
|
+
const pos = item.transformation.getTranslation();
|
|
64271
|
+
console.log(`[nest-post] ${item.itemType} ${item.getId()}: pos=(${pos.x.toFixed(0)},${pos.y.toFixed(0)}) parent=${item.parent}`);
|
|
64272
|
+
}
|
|
64264
64273
|
this.selection.removeAll();
|
|
64265
64274
|
this.selection.add(items);
|
|
64266
64275
|
this.selection.setContext("EditUnderPointer");
|