@copilotkit/web-inspector 1.55.0-next.7 → 1.55.0-next.9
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/CHANGELOG.md +12 -0
- package/dist/index.cjs +24 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -0
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.mts +1 -0
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +24 -9
- package/dist/index.mjs.map +1 -1
- package/dist/index.umd.js +24 -9
- package/dist/index.umd.js.map +1 -1
- package/package.json +4 -4
- package/src/__tests__/web-inspector.spec.ts +5 -1
- package/src/index.ts +30 -11
package/CHANGELOG.md
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -87,6 +87,7 @@ var WebInspectorElement = class extends lit.LitElement {
|
|
|
87
87
|
this.dockMode = "floating";
|
|
88
88
|
this.previousBodyMargins = null;
|
|
89
89
|
this.transitionTimeoutId = null;
|
|
90
|
+
this.bodyTransitionTimeoutIds = /* @__PURE__ */ new Set();
|
|
90
91
|
this.pendingSelectedContext = null;
|
|
91
92
|
this.autoAttachCore = true;
|
|
92
93
|
this.attemptedAutoAttach = false;
|
|
@@ -1028,7 +1029,13 @@ ${argsString}</pre
|
|
|
1028
1029
|
window.removeEventListener("resize", this.handleResize);
|
|
1029
1030
|
window.removeEventListener("pointerdown", this.handleGlobalPointerDown);
|
|
1030
1031
|
}
|
|
1031
|
-
this.
|
|
1032
|
+
for (const id of this.bodyTransitionTimeoutIds) clearTimeout(id);
|
|
1033
|
+
this.bodyTransitionTimeoutIds.clear();
|
|
1034
|
+
if (this.transitionTimeoutId !== null) {
|
|
1035
|
+
clearTimeout(this.transitionTimeoutId);
|
|
1036
|
+
this.transitionTimeoutId = null;
|
|
1037
|
+
}
|
|
1038
|
+
this.removeDockStyles(true);
|
|
1032
1039
|
this.detachFromCore();
|
|
1033
1040
|
}
|
|
1034
1041
|
firstUpdated() {
|
|
@@ -1413,13 +1420,17 @@ ${argsString}</pre
|
|
|
1413
1420
|
};
|
|
1414
1421
|
if (!this.isResizing && !skipTransition) document.body.style.transition = "margin 300ms ease";
|
|
1415
1422
|
if (this.dockMode === "docked-left") document.body.style.marginLeft = `${this.contextState.window.size.width}px`;
|
|
1416
|
-
if (!this.isResizing && !skipTransition)
|
|
1417
|
-
|
|
1418
|
-
|
|
1423
|
+
if (!this.isResizing && !skipTransition) {
|
|
1424
|
+
const id = setTimeout(() => {
|
|
1425
|
+
this.bodyTransitionTimeoutIds.delete(id);
|
|
1426
|
+
if (typeof document !== "undefined" && document.body) document.body.style.transition = "";
|
|
1427
|
+
}, 300);
|
|
1428
|
+
this.bodyTransitionTimeoutIds.add(id);
|
|
1429
|
+
}
|
|
1419
1430
|
}
|
|
1420
|
-
removeDockStyles() {
|
|
1431
|
+
removeDockStyles(skipTransition = false) {
|
|
1421
1432
|
if (typeof document === "undefined" || !document.body) return;
|
|
1422
|
-
if (!this.isResizing) document.body.style.transition = "margin 300ms ease";
|
|
1433
|
+
if (!this.isResizing && !skipTransition) document.body.style.transition = "margin 300ms ease";
|
|
1423
1434
|
if (this.previousBodyMargins) {
|
|
1424
1435
|
document.body.style.marginLeft = this.previousBodyMargins.left;
|
|
1425
1436
|
document.body.style.marginBottom = this.previousBodyMargins.bottom;
|
|
@@ -1428,9 +1439,13 @@ ${argsString}</pre
|
|
|
1428
1439
|
document.body.style.marginLeft = "";
|
|
1429
1440
|
document.body.style.marginBottom = "";
|
|
1430
1441
|
}
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1442
|
+
if (!skipTransition) {
|
|
1443
|
+
const id = setTimeout(() => {
|
|
1444
|
+
this.bodyTransitionTimeoutIds.delete(id);
|
|
1445
|
+
if (typeof document !== "undefined" && document.body) document.body.style.transition = "";
|
|
1446
|
+
}, 300);
|
|
1447
|
+
this.bodyTransitionTimeoutIds.add(id);
|
|
1448
|
+
} else document.body.style.transition = "";
|
|
1434
1449
|
}
|
|
1435
1450
|
updateHostTransform(context = this.activeContext) {
|
|
1436
1451
|
if (context !== this.activeContext) return;
|