mirror of
https://github.com/Studio-Saelix/sencho.git
synced 2026-08-22 08:06:42 +00:00
refactor(frontend): migrate Bash, Log, and Deploy feedback dialogs (#952)
- modal.tsx Modal now accepts a showClose prop that passes through to
DialogContent, so callers that render their own close affordance
(DeployFeedbackModal) can suppress the Radix close button
- DeployFeedbackModal -> Modal with showClose=false. Custom header,
scroll body, embedded terminal, and footer stay in place; Modal
provides the consistent overlay/blur chrome. DialogTitle is still
imported from the dialog primitive purely as an sr-only
accessibility wrapper, since this status panel doesn't fit the §10
ModalHeader chrome
- BashExecModal -> Modal + ModalHeader. Kicker BASH · {CONTAINER}.
The xterm container sits in the body
- LogViewer -> Modal + ModalHeader. Kicker LOGS · {CONTAINER}. The
scroll region sits in the body
This commit is contained in:
@@ -34,12 +34,15 @@ interface ModalProps {
|
||||
children: React.ReactNode;
|
||||
size?: ModalSize;
|
||||
className?: string;
|
||||
/** Pass through to DialogContent — set to false when the modal renders its own close affordance. */
|
||||
showClose?: boolean;
|
||||
}
|
||||
|
||||
export function Modal({ open, onOpenChange, children, size = 'md', className }: ModalProps) {
|
||||
export function Modal({ open, onOpenChange, children, size = 'md', className, showClose }: ModalProps) {
|
||||
return (
|
||||
<Dialog open={open} onOpenChange={onOpenChange}>
|
||||
<DialogContent
|
||||
showClose={showClose}
|
||||
className={cn(
|
||||
'p-0 gap-0 overflow-hidden grid-cols-1',
|
||||
SIZE_CLASS[size],
|
||||
|
||||
Reference in New Issue
Block a user