@mml-io/mml-web-client 0.0.0-experimental-a7b3d9a-20250319 → 0.0.0-experimental-e89bc48-20250422
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/build/index.js +11 -4
- package/build/index.js.map +2 -2
- package/package.json +5 -5
package/build/index.js
CHANGED
|
@@ -909,7 +909,8 @@
|
|
|
909
909
|
handleEvent(element, event) {
|
|
910
910
|
const nodeId = this.elementToId.get(element);
|
|
911
911
|
if (nodeId === void 0 || nodeId === null) {
|
|
912
|
-
|
|
912
|
+
console.error("Element not found for event", { nodeId, element, event });
|
|
913
|
+
return;
|
|
913
914
|
}
|
|
914
915
|
const detailWithoutElement = {
|
|
915
916
|
...event.detail
|
|
@@ -1330,10 +1331,11 @@
|
|
|
1330
1331
|
}
|
|
1331
1332
|
createWebsocketWithTimeout(timeout) {
|
|
1332
1333
|
return new Promise((resolve, reject) => {
|
|
1334
|
+
const websocket = this.websocketFactory(this.url);
|
|
1333
1335
|
const timeoutId = setTimeout(() => {
|
|
1334
1336
|
reject(new Error("websocket connection timed out"));
|
|
1337
|
+
websocket.close();
|
|
1335
1338
|
}, timeout);
|
|
1336
|
-
const websocket = this.websocketFactory(this.url);
|
|
1337
1339
|
websocket.binaryType = "arraybuffer";
|
|
1338
1340
|
websocket.addEventListener("open", () => {
|
|
1339
1341
|
clearTimeout(timeoutId);
|
|
@@ -5416,6 +5418,7 @@
|
|
|
5416
5418
|
var _Frame = class _Frame2 extends TransformableElement {
|
|
5417
5419
|
constructor() {
|
|
5418
5420
|
super();
|
|
5421
|
+
this.hasInitialized = false;
|
|
5419
5422
|
this.frameContentsInstance = null;
|
|
5420
5423
|
this.isActivelyLoaded = false;
|
|
5421
5424
|
this.timer = null;
|
|
@@ -5454,6 +5457,9 @@
|
|
|
5454
5457
|
}
|
|
5455
5458
|
}
|
|
5456
5459
|
shouldBeLoaded() {
|
|
5460
|
+
if (!this.hasInitialized) {
|
|
5461
|
+
return false;
|
|
5462
|
+
}
|
|
5457
5463
|
if (!this.isConnected) {
|
|
5458
5464
|
return false;
|
|
5459
5465
|
}
|
|
@@ -5565,8 +5571,6 @@
|
|
|
5565
5571
|
return;
|
|
5566
5572
|
}
|
|
5567
5573
|
const graphicsAdapter = this.getScene().getGraphicsAdapter();
|
|
5568
|
-
this.startEmitting();
|
|
5569
|
-
this.syncLoadState();
|
|
5570
5574
|
this.frameGraphics = graphicsAdapter.getGraphicsAdapterFactory().MMLFrameGraphicsInterface(this);
|
|
5571
5575
|
for (const name of _Frame2.observedAttributes) {
|
|
5572
5576
|
const value = this.getAttribute(name);
|
|
@@ -5574,6 +5578,9 @@
|
|
|
5574
5578
|
this.attributeChangedCallback(name, null, value);
|
|
5575
5579
|
}
|
|
5576
5580
|
}
|
|
5581
|
+
this.hasInitialized = true;
|
|
5582
|
+
this.startEmitting();
|
|
5583
|
+
this.syncLoadState();
|
|
5577
5584
|
this.applyBounds();
|
|
5578
5585
|
}
|
|
5579
5586
|
disconnectedCallback() {
|