This commit is contained in:
Timothy Jaeryang Baek 2026-08-23 12:59:59 -04:00
parent fca3be5416
commit 0fb542b376
2 changed files with 3 additions and 3 deletions

View file

@ -310,7 +310,6 @@
open={$showControls}
bind:width={controlsWidth}
minWidth={350}
maxWidth={640}
storageKey="chatControlsSize"
className="h-full z-10 bg-white dark:bg-gray-900"
>

View file

@ -5,7 +5,7 @@
export let side: 'left' | 'right' = 'right';
export let width = 350;
export let minWidth = 300;
export let maxWidth = 640;
export let maxWidth: number | null = null;
export let storageKey = '';
export let className = '';
export let resizerId = 'controls-resizer';
@ -14,7 +14,8 @@
let startClientX = 0;
let startWidth = 0;
const clamp = (value: number) => Math.min(maxWidth, Math.max(minWidth, value));
const clamp = (value: number) =>
maxWidth === null ? Math.max(minWidth, value) : Math.min(maxWidth, Math.max(minWidth, value));
const persistWidth = () => {
if (storageKey) {