@mindexec/cli 0.2.287 → 0.2.289
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
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
const DEBUG = false;
|
|
6
6
|
const FPS_DEBUG = false;
|
|
7
7
|
const FRAME_PERF_DEBUG = false;
|
|
8
|
-
const MINDMAP_CORE_BUILD_ID = '20260620-css3d-flat-wheel-
|
|
8
|
+
const MINDMAP_CORE_BUILD_ID = '20260620-css3d-flat-wheel-v735';
|
|
9
9
|
const CanvasPhase = Object.freeze({
|
|
10
10
|
Booting: 'booting',
|
|
11
11
|
BoardFileLoading: 'board-file-loading',
|
|
@@ -4030,6 +4030,7 @@ ${summaryLines.map(line => `<div>${escapeNodeFrameDebugHtml(line)}</div>`).join(
|
|
|
4030
4030
|
this._lastLocalSnapGridOpacity = '';
|
|
4031
4031
|
this._localSnapGridStyleDeferredForZoom = false;
|
|
4032
4032
|
this._localSnapGridPointerWakeDeferredForZoom = false;
|
|
4033
|
+
this._lastLocalSnapGridPointerSnapKey = '';
|
|
4033
4034
|
this._lastSnapGridClientX = null;
|
|
4034
4035
|
this._lastSnapGridClientY = null;
|
|
4035
4036
|
this._animationIdleTimerId = null;
|
|
@@ -4099,24 +4100,48 @@ ${summaryLines.map(line => `<div>${escapeNodeFrameDebugHtml(line)}</div>`).join(
|
|
|
4099
4100
|
|
|
4100
4101
|
const roundedX = Math.round(nextX * 2) / 2;
|
|
4101
4102
|
const roundedY = Math.round(nextY * 2) / 2;
|
|
4102
|
-
|
|
4103
|
-
|
|
4103
|
+
const fallbackGrid = Math.max(1, Number(this.GRID_SIZE || 10));
|
|
4104
|
+
let pointerSnapKey = `screen:${Math.round(roundedX / fallbackGrid)}|${Math.round(roundedY / fallbackGrid)}`;
|
|
4105
|
+
if (this.container && this.camera?.isPerspectiveCamera) {
|
|
4106
|
+
const viewportMetrics = getCachedViewportMetrics(this);
|
|
4107
|
+
const width = Math.max(1, Number(viewportMetrics.width || 0));
|
|
4108
|
+
const height = Math.max(1, Number(viewportMetrics.height || 0));
|
|
4109
|
+
const left = Number(viewportMetrics.left || 0);
|
|
4110
|
+
const top = Number(viewportMetrics.top || 0);
|
|
4111
|
+
const centerX = Math.max(0, Math.min(width, roundedX - left));
|
|
4112
|
+
const centerY = Math.max(0, Math.min(height, roundedY - top));
|
|
4113
|
+
const snappedCenter = this._getLocalSnapGridSnappedScreenCenter(centerX, centerY, width, height, this.camera);
|
|
4114
|
+
pointerSnapKey = snappedCenter.snapKey || pointerSnapKey;
|
|
4115
|
+
}
|
|
4116
|
+
|
|
4117
|
+
if (this._lastLocalSnapGridPointerSnapKey === pointerSnapKey) {
|
|
4104
4118
|
return false;
|
|
4105
4119
|
}
|
|
4106
4120
|
|
|
4121
|
+
const previousX = this._lastSnapGridClientX;
|
|
4122
|
+
const previousY = this._lastSnapGridClientY;
|
|
4107
4123
|
this._lastSnapGridClientX = roundedX;
|
|
4108
4124
|
this._lastSnapGridClientY = roundedY;
|
|
4125
|
+
this._lastLocalSnapGridPointerSnapKey = pointerSnapKey;
|
|
4109
4126
|
this._localSnapGridPointerRevision = Math.max(0, Number(this._localSnapGridPointerRevision || 0)) + 1;
|
|
4110
4127
|
this._lastLocalSnapGridTransformKey = '';
|
|
4128
|
+
if (previousX !== roundedX || previousY !== roundedY) {
|
|
4129
|
+
this._lastLocalSnapGridClientMovedAt =
|
|
4130
|
+
typeof performance !== 'undefined' && typeof performance.now === 'function'
|
|
4131
|
+
? performance.now()
|
|
4132
|
+
: Date.now();
|
|
4133
|
+
}
|
|
4111
4134
|
return true;
|
|
4112
4135
|
}
|
|
4113
4136
|
|
|
4114
4137
|
_getLocalSnapGridSnappedScreenCenter(rawCenterX, rawCenterY, width, height, camera = null) {
|
|
4115
4138
|
const safeWidth = Math.max(1, Number(width || 0));
|
|
4116
4139
|
const safeHeight = Math.max(1, Number(height || 0));
|
|
4140
|
+
const fallbackGrid = Math.max(1, Number(this.GRID_SIZE || 10));
|
|
4117
4141
|
const fallback = {
|
|
4118
4142
|
centerX: Math.max(0, Math.min(safeWidth, Number(rawCenterX || 0))),
|
|
4119
|
-
centerY: Math.max(0, Math.min(safeHeight, Number(rawCenterY || 0)))
|
|
4143
|
+
centerY: Math.max(0, Math.min(safeHeight, Number(rawCenterY || 0))),
|
|
4144
|
+
snapKey: `screen:${Math.round(Number(rawCenterX || 0) / fallbackGrid)}|${Math.round(Number(rawCenterY || 0) / fallbackGrid)}`
|
|
4120
4145
|
};
|
|
4121
4146
|
const activeCamera = camera || this.camera;
|
|
4122
4147
|
if (!activeCamera?.isPerspectiveCamera) {
|
|
@@ -4135,7 +4160,7 @@ ${summaryLines.map(line => `<div>${escapeNodeFrameDebugHtml(line)}</div>`).join(
|
|
|
4135
4160
|
const cameraY = Number(activeCamera.position?.y || 0);
|
|
4136
4161
|
const worldX = cameraX + ((fallback.centerX / safeWidth) - 0.5) * viewWidth;
|
|
4137
4162
|
const worldY = cameraY + (0.5 - (fallback.centerY / safeHeight)) * viewHeight;
|
|
4138
|
-
const grid =
|
|
4163
|
+
const grid = fallbackGrid;
|
|
4139
4164
|
const snappedWorldX = Math.round(worldX / grid) * grid;
|
|
4140
4165
|
const snappedWorldY = Math.round(worldY / grid) * grid;
|
|
4141
4166
|
const snappedCenterX = (((snappedWorldX - cameraX) / viewWidth) + 0.5) * safeWidth;
|
|
@@ -4143,7 +4168,8 @@ ${summaryLines.map(line => `<div>${escapeNodeFrameDebugHtml(line)}</div>`).join(
|
|
|
4143
4168
|
|
|
4144
4169
|
return {
|
|
4145
4170
|
centerX: Math.max(0, Math.min(safeWidth, snappedCenterX)),
|
|
4146
|
-
centerY: Math.max(0, Math.min(safeHeight, snappedCenterY))
|
|
4171
|
+
centerY: Math.max(0, Math.min(safeHeight, snappedCenterY)),
|
|
4172
|
+
snapKey: `world:${Math.round(snappedWorldX / grid)}|${Math.round(snappedWorldY / grid)}`
|
|
4147
4173
|
};
|
|
4148
4174
|
}
|
|
4149
4175
|
|
|
@@ -4188,6 +4214,7 @@ ${summaryLines.map(line => `<div>${escapeNodeFrameDebugHtml(line)}</div>`).join(
|
|
|
4188
4214
|
this._lastLocalSnapGridKey = '';
|
|
4189
4215
|
this._lastLocalSnapGridTransformKey = '';
|
|
4190
4216
|
this._lastLocalSnapGridPositionRevision = -1;
|
|
4217
|
+
this._lastLocalSnapGridPointerSnapKey = '';
|
|
4191
4218
|
this._lastLocalSnapGridOpacity = '';
|
|
4192
4219
|
this._localSnapGridStyleDeferredForZoom = false;
|
|
4193
4220
|
return layer;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
self.assetsManifest = {
|
|
2
|
-
"version": "
|
|
2
|
+
"version": "2SnxEkqN",
|
|
3
3
|
"assets": [
|
|
4
4
|
{
|
|
5
5
|
"hash": "sha256-+CSYMcqLNTsq3VnH11jgYyOCCdxvHzL74CBmo4sCmMU=",
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
"url": "_content/MindExecution.Shared/js/marked.min.js"
|
|
79
79
|
},
|
|
80
80
|
{
|
|
81
|
-
"hash": "sha256-
|
|
81
|
+
"hash": "sha256-YPH1ZXPDehAzNUpwIQ5DDMHMHxxnB/JfwtJhuBoplR8=",
|
|
82
82
|
"url": "_content/MindExecution.Shared/js/mind-map-core.js"
|
|
83
83
|
},
|
|
84
84
|
{
|