feat: add member terminal trigger and align terminal panel bottom-center
This commit is contained in:
@@ -21,11 +21,13 @@
|
||||
this._buildPanel();
|
||||
}
|
||||
|
||||
// Adjust position to be left of the details drawer
|
||||
this._adjustRightOffset();
|
||||
if (!this.resizeHandler) {
|
||||
this.resizeHandler = () => this._adjustRightOffset();
|
||||
window.addEventListener('resize', this.resizeHandler);
|
||||
// Reset any leftover inline positioning so CSS centering applies
|
||||
if (this.container) {
|
||||
this.container.style.right = '';
|
||||
this.container.style.left = '';
|
||||
this.container.style.top = '';
|
||||
this.container.style.bottom = '';
|
||||
this.container.style.width = '';
|
||||
}
|
||||
|
||||
// Show panel with animation
|
||||
@@ -193,17 +195,6 @@
|
||||
return text;
|
||||
}
|
||||
}
|
||||
|
||||
_adjustRightOffset() {
|
||||
try {
|
||||
const drawer = document.querySelector('.details-drawer');
|
||||
const isOpen = drawer && drawer.classList.contains('open');
|
||||
const width = isOpen ? drawer.getBoundingClientRect().width : 0;
|
||||
if (this.container) {
|
||||
this.container.style.right = `${width}px`;
|
||||
}
|
||||
} catch (_) { /* no-op */ }
|
||||
}
|
||||
}
|
||||
|
||||
// Expose singleton API
|
||||
|
||||
Reference in New Issue
Block a user