Commit 8217f5ab by luoqi

feat(web): 助手最大化占满窗口(inset-3,不写死宽高)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
parent 1e1d5ac9
Pipeline #3385 failed in 0 seconds
...@@ -58,7 +58,7 @@ export function AssistantWidget() { ...@@ -58,7 +58,7 @@ export function AssistantWidget() {
'fixed z-[60] flex flex-col overflow-hidden rounded-xl border border-slate-100 shadow-2xl', 'fixed z-[60] flex flex-col overflow-hidden rounded-xl border border-slate-100 shadow-2xl',
'transition-[opacity,transform] duration-150', 'transition-[opacity,transform] duration-150',
maximized maximized
? 'inset-0 m-auto h-[min(88vh,900px)] w-[min(1000px,94vw)]' // 居中放大(margin:auto 定宽高居中) ? 'inset-3' // 最大化:填满窗口(留 12px 边距),不写死宽高,随窗口自适应
: cn(!winRect && 'bottom-4 right-4', 'h-[620px] max-h-[78vh] w-[400px] max-w-[calc(100vw-2rem)]'), : cn(!winRect && 'bottom-4 right-4', 'h-[620px] max-h-[78vh] w-[400px] max-w-[calc(100vw-2rem)]'),
open ? 'translate-y-0 opacity-100' : 'pointer-events-none invisible translate-y-2 opacity-0', open ? 'translate-y-0 opacity-100' : 'pointer-events-none invisible translate-y-2 opacity-0',
)} )}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment