Compare commits

...

2 Commits

2 changed files with 10 additions and 10 deletions

View File

@ -382,10 +382,10 @@ export default function PacientesPage() {
<TableCell> <TableCell>
<DropdownMenu> <DropdownMenu>
<DropdownMenuTrigger asChild> <DropdownMenuTrigger asChild>
<Button variant="ghost" className="h-8 w-8 p-0"> <button className="h-8 w-8 p-0 flex items-center justify-center rounded-md hover:bg-accent">
<span className="sr-only">Abrir menu</span> <span className="sr-only">Abrir menu</span>
<MoreHorizontal className="h-4 w-4" /> <MoreHorizontal className="h-4 w-4" />
</Button> </button>
</DropdownMenuTrigger> </DropdownMenuTrigger>
<DropdownMenuContent align="end"> <DropdownMenuContent align="end">
<DropdownMenuItem onClick={() => handleViewDetails(patient.id)}> <DropdownMenuItem onClick={() => handleViewDetails(patient.id)}>

View File

@ -395,8 +395,8 @@ export function PatientRegistrationForm({
if (inline && onClose) { if (inline && onClose) {
onClose() onClose()
} else if (onOpenChange) { } else {
onOpenChange(false) onOpenChange?.(false)
} }
// Show success message (you might want to use a toast notification) // Show success message (you might want to use a toast notification)
@ -412,8 +412,8 @@ export function PatientRegistrationForm({
const handleCancel = () => { const handleCancel = () => {
if (inline && onClose) { if (inline && onClose) {
onClose() onClose()
} else if (onOpenChange) { } else {
onOpenChange(false) onOpenChange?.(false)
} }
} }
@ -464,10 +464,10 @@ export function PatientRegistrationForm({
<div className="space-y-2"> <div className="space-y-2">
<Label htmlFor="photo" className="cursor-pointer"> <Label htmlFor="photo" className="cursor-pointer">
<Button type="button" variant="outline" asChild> <Button type="button" variant="outline" asChild>
<span> <label htmlFor="photo" className="cursor-pointer">
<Upload className="mr-2 h-4 w-4" /> <Upload className="mr-2 h-4 w-4" />
Carregar Foto Carregar Foto
</span> </label>
</Button> </Button>
</Label> </Label>
<Input id="photo" type="file" accept="image/*" className="hidden" onChange={handlePhotoUpload} /> <Input id="photo" type="file" accept="image/*" className="hidden" onChange={handlePhotoUpload} />
@ -1028,7 +1028,7 @@ export function PatientRegistrationForm({
} }
return ( return (
<Dialog open={open} onOpenChange={onOpenChange}> <Dialog open={open} onOpenChange={onOpenChange ?? (() => { })}>
<DialogContent className="max-w-4xl max-h-[90vh] overflow-y-auto"> <DialogContent className="max-w-4xl max-h-[90vh] overflow-y-auto">
<DialogHeader> <DialogHeader>
<DialogTitle className="flex items-center gap-2"> <DialogTitle className="flex items-center gap-2">
@ -1630,7 +1630,7 @@ export function PatientRegistrationForm({
{/* Botões de Ação */} {/* Botões de Ação */}
<div className="flex justify-end gap-4 pt-6 border-t"> <div className="flex justify-end gap-4 pt-6 border-t">
<Button type="button" variant="outline" onClick={() => onOpenChange(false)} disabled={isSubmitting}> <Button type="button" variant="outline" onClick={() => onOpenChange?.(false)} disabled={isSubmitting}>
<XCircle className="mr-2 h-4 w-4" /> <XCircle className="mr-2 h-4 w-4" />
Cancelar Cancelar
</Button> </Button>