fix: adicionar importacao de Users e renderizacao segura de StepIcon no MapaInterativo

This commit is contained in:
2026-09-10 14:32:17 +00:00
parent 323092dcdb
commit 13306da676
+24 -20
View File
@@ -32,7 +32,8 @@ import {
Layers, Layers,
Clock, Clock,
Check, Check,
ChevronRight ChevronRight,
Users
} from 'lucide-react'; } from 'lucide-react';
import { cn } from '@/lib/utils'; import { cn } from '@/lib/utils';
@@ -720,23 +721,25 @@ export default function MapaInterativo() {
{/* DRAWER / GAVETA LATERAL DIDÁTICA (O Coração da Experiência) */} {/* DRAWER / GAVETA LATERAL DIDÁTICA (O Coração da Experiência) */}
<Sheet open={selectedStep !== null} onOpenChange={(open) => !open && setSelectedStep(null)}> <Sheet open={selectedStep !== null} onOpenChange={(open) => !open && setSelectedStep(null)}>
<SheetContent side="right" className="w-full sm:max-w-lg overflow-y-auto p-6 space-y-6"> <SheetContent side="right" className="w-full sm:max-w-lg overflow-y-auto p-6 space-y-6">
{selectedStep && ( {selectedStep && (() => {
<> const StepIcon = selectedStep.icon;
{/* Cabeçalho do Drawer */} return (
<SheetHeader className="space-y-2 border-b border-border/60 pb-4"> <>
<div className="flex items-center gap-2"> {/* Cabeçalho do Drawer */}
<Badge variant="outline" className={selectedStep.phaseColor.badge}> <SheetHeader className="space-y-2 border-b border-border/60 pb-4">
Etapa {selectedStep.orderNumber} • {selectedStep.phaseName} <div className="flex items-center gap-2">
</Badge> <Badge variant="outline" className={selectedStep.phaseColor.badge}>
</div> Etapa {selectedStep.orderNumber} • {selectedStep.phaseName}
<SheetTitle className="text-xl font-extrabold text-foreground flex items-center gap-2"> </Badge>
<selectedStep.icon className={cn("h-6 w-6", selectedStep.phaseColor.accent)} /> </div>
{selectedStep.title} <SheetTitle className="text-xl font-extrabold text-foreground flex items-center gap-2">
</SheetTitle> {StepIcon && <StepIcon className={cn("h-6 w-6", selectedStep.phaseColor.accent)} />}
<SheetDescription className="text-xs text-muted-foreground"> {selectedStep.title}
{selectedStep.subtitle} </SheetTitle>
</SheetDescription> <SheetDescription className="text-xs text-muted-foreground">
</SheetHeader> {selectedStep.subtitle}
</SheetDescription>
</SheetHeader>
{/* Botão de Ação Direta para a Tela Real */} {/* Botão de Ação Direta para a Tela Real */}
<div> <div>
@@ -821,8 +824,9 @@ export default function MapaInterativo() {
))} ))}
</div> </div>
</div> </div>
</> </>
)} );
})()}
</SheetContent> </SheetContent>
</Sheet> </Sheet>
</div> </div>