@@ -33,26 +33,28 @@ export default function Modal({ open, onOpenChange, title, description, children
3333 animate = { { opacity : 1 , scale : 1 , y : 0 } }
3434 exit = { { opacity : 0 , scale : 0.96 , y : 12 } }
3535 transition = { { duration : 0.2 , ease : 'easeOut' } }
36- style = { { maxHeight : '90vh' , overflowY : 'auto' } }
3736 className = { `fixed z-50 left-1/2 top-1/2 -translate-x-1/2 -translate-y-1/2
3837 w-full ${ widths [ size ] ?? widths . md } mx-4
39- glass-card p-6 outline-none` }
38+ glass-card outline-none flex flex-col` }
39+ style = { { maxHeight : '90vh' } }
4040 >
4141 { /* Header */ }
42- { ( title || description ) && (
43- < div className = "mb-5" >
44- { title && (
45- < Dialog . Title className = "text-lg font-bold text-[var(--color-text)] leading-tight" >
46- { title }
47- </ Dialog . Title >
48- ) }
49- { description && (
50- < Dialog . Description className = "text-sm text-[var(--color-text-muted)] mt-1" >
51- { description }
52- </ Dialog . Description >
53- ) }
54- </ div >
55- ) }
42+ < div className = "flex-shrink-0 px-6 pt-6 pb-0" >
43+ { ( title || description ) && (
44+ < div className = "mb-5 pr-8" >
45+ { title && (
46+ < Dialog . Title className = "text-lg font-bold text-[var(--color-text)] leading-tight" >
47+ { title }
48+ </ Dialog . Title >
49+ ) }
50+ { description && (
51+ < Dialog . Description className = "text-sm text-[var(--color-text-muted)] mt-1" >
52+ { description }
53+ </ Dialog . Description >
54+ ) }
55+ </ div >
56+ ) }
57+ </ div >
5658
5759 { /* Close */ }
5860 < Dialog . Close asChild >
@@ -63,7 +65,10 @@ export default function Modal({ open, onOpenChange, title, description, children
6365 </ button >
6466 </ Dialog . Close >
6567
66- { children }
68+ { /* Scrollable content */ }
69+ < div className = "flex-1 overflow-y-auto px-6 pb-6" >
70+ { children }
71+ </ div >
6772 </ motion . div >
6873 </ Dialog . Content >
6974 </ Dialog . Portal >
0 commit comments