feat: widen LeftPanel to 680px when admin tab is active

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
root
2026-03-10 13:27:21 +00:00
parent d2fd013312
commit 7b8ba95189

View File

@@ -324,6 +324,8 @@ export class LeftPanel {
expand(tab: 'stats' | 'events' | 'inventions' | 'resources' | 'log' | 'admin'): void {
this.activeTab = tab;
this.expanded = true;
const width = tab === 'admin' ? 680 : 340;
this.panel.style.width = `${width}px`;
this.showContent(tab);
this.updateTabs();
this.container.style.transform = 'translateY(-50%) translateX(0)';
@@ -340,6 +342,7 @@ export class LeftPanel {
collapse(): void {
this.expanded = false;
this.panel.style.width = '340px';
this.container.style.transform = 'translateY(-50%) translateX(-340px)';
this.updateTabs();
document.dispatchEvent(new CustomEvent('left-panel-closed'));