feat(visual): visual adjustments #37

Merged
JoaoGustavo-dev merged 4 commits from feature/visual-adjustments into develop 2025-10-04 01:21:57 +00:00
9 changed files with 97 additions and 68 deletions
Showing only changes of commit 7b0406f815 - Show all commits

View File

@ -327,9 +327,10 @@ export default function DoutoresPage() {
/>
</div>
<Button
variant="outline"
onClick={handleClickBuscar}
disabled={loading || !search.trim()}
variant="secondary"
onClick={handleBuscarServidor}
disabled={loading}
className="hover:bg-primary hover:text-white"
>
Buscar
</Button>

View File

@ -204,7 +204,7 @@ export default function PacientesPage() {
onKeyDown={(e) => e.key === "Enter" && handleBuscarServidor()}
/>
</div>
<Button variant="secondary" onClick={handleBuscarServidor}>Buscar</Button>
<Button variant="secondary" onClick={handleBuscarServidor} className="hover:bg-primary hover:text-white">Buscar</Button>
<Button onClick={handleAdd}>
<Plus className="mr-2 h-4 w-4" />
Novo paciente

View File

@ -43,7 +43,7 @@ export default function NovoAgendamentoPage() {
};
const handleCancel = () => {
router.back();
router.push("/calendar");
};
return (

View File

@ -21,6 +21,15 @@ export default function FinanceiroPage() {
const isPr = pathname?.startsWith("/procedimento");
const isFi = pathname?.startsWith("/financeiro");
const handleSave = () => {
// Lógica de salvar será implementada
console.log("Salvando informações financeiras...");
};
const handleCancel = () => {
router.push("/calendar");
};
return (
<div className="w-full min-h-screen flex flex-col bg-background">
{/* HEADER */}
@ -142,7 +151,7 @@ export default function FinanceiroPage() {
</main>
{/* RODAPÉ FIXO */}
<FooterAgenda />
<FooterAgenda onSave={handleSave} onCancel={handleCancel} />
</div>
);
}

View File

@ -20,6 +20,16 @@ export default function ProcedimentoPage() {
const isAg = pathname?.startsWith("/agendamento");
const isPr = pathname?.startsWith("/procedimento");
const isFi = pathname?.startsWith("/financeiro");
const handleSave = () => {
// Lógica de salvar será implementada
console.log("Salvando procedimentos...");
};
const handleCancel = () => {
router.push("/calendar");
};
const tab = (active: boolean, extra = "") =>
`px-4 py-1.5 text-[13px] border ${
active
@ -83,7 +93,7 @@ export default function ProcedimentoPage() {
</main>
{/* RODAPÉ FIXO */}
<FooterAgenda />
<FooterAgenda onSave={handleSave} onCancel={handleCancel} />
</div>
);
}

View File

@ -60,8 +60,8 @@ export default function HeaderAgenda() {
<button
type="button"
aria-label="Histórico"
onClick={() => router.back()}
aria-label="Voltar para Calendário"
onClick={() => router.push("/calendar")}
className="inline-flex h-8 w-8 items-center justify-center rounded-md border border-border bg-background text-muted-foreground hover:bg-primary hover:text-white hover:border-primary transition-colors"
>
<RotateCcw className="h-4 w-4" />

View File

@ -130,19 +130,36 @@ export function CalendarRegistrationForm({ formData, onFormChange }: CalendarReg
</div>
</div>
<div className="md:col-span-12 space-y-2">
<div
className="flex items-center justify-between cursor-pointer"
onClick={() => setIsAdditionalInfoOpen(!isAdditionalInfoOpen)}
>
<Label className="text-sm font-medium cursor-pointer">Informações adicionais</Label>
<ChevronDown className={`h-4 w-4 text-muted-foreground transition-transform duration-200 ${isAdditionalInfoOpen ? 'rotate-180' : ''}`} />
</div>
{isAdditionalInfoOpen && (
<div className="space-y-2">
<Label className="text-[13px]">Documentos e anexos</Label>
<Textarea name="documentos" rows={5} className="text-[13px] resize-none rounded-md transition-colors hover:bg-muted/30" value={formData.documentos || ''} onChange={handleChange} />
</div>
)}
<div
className="flex items-center justify-between cursor-pointer"
onClick={() => setIsAdditionalInfoOpen(!isAdditionalInfoOpen)}
>
<div className="flex items-center gap-2">
<Label className="text-sm font-medium cursor-pointer text-primary m-0">Informações adicionais</Label>
<ChevronDown className={`h-4 w-4 text-primary transition-transform duration-200 ${isAdditionalInfoOpen ? 'rotate-180' : ''}`} />
</div>
</div>
{isAdditionalInfoOpen && (
<div className="space-y-2">
<div className="relative">
<select
name="documentos"
className="h-11 w-full rounded-md border border-gray-300 dark:border-input bg-background text-foreground pr-8 pl-3 text-[13px] appearance-none transition-colors hover:bg-muted/30 hover:border-gray-400"
value={formData.documentos || ''}
onChange={handleChange}
>
<option value="" disabled>
Documentos e anexos
</option>
<option value="identidade">Identidade / CPF</option>
<option value="comprovante_residencia">Comprovante de residência</option>
<option value="guias">Guias / Encaminhamentos</option>
<option value="outros">Outros</option>
</select>
<ChevronDown className="pointer-events-none absolute right-3 top-1/2 -translate-y-1/2 h-4 w-4 text-primary" />
</div>
</div>
)}
</div>
</div>
</div>

View File

@ -132,6 +132,8 @@ const initial: FormData = {
// AgendaEditor removido - restaurando o textarea original abaixo
export function DoctorRegistrationForm({
open = true,
onOpenChange,
@ -466,10 +468,10 @@ if (missingFields.length > 0) {
)}
</div>
<div className="space-y-2">
<Label htmlFor="photo" className="cursor-pointer">
<Button type="button" variant="outline" asChild>
<Label htmlFor="photo" className="cursor-pointer rounded-md transition-colors">
<Button type="button" variant="ghost" asChild className="bg-primary text-primary-foreground border-transparent hover:bg-primary">
<span>
<Upload className="mr-2 h-4 w-4" /> Carregar Foto
<Upload className="mr-2 h-4 w-4 text-primary-foreground" /> Carregar Foto
</span>
</Button>
</Label>
@ -522,27 +524,27 @@ if (missingFields.length > 0) {
</div>
<div className="space-y-2">
<Label>Currículo</Label>
<div className="flex items-center gap-2">
<Label htmlFor="curriculo-input" className="cursor-pointer">
<Button type="button" variant="outline" asChild>
<span>
<Upload className="mr-2 h-4 w-4" />
Anexar PDF ou DOC
</span>
</Button>
</Label>
<Input
id="curriculo-input"
type="file"
className="hidden"
onChange={(e) => setField("curriculo", e.target.files?.[0] || null)}
accept=".pdf,.doc,.docx"
/>
{form.curriculo && <span className="text-sm text-muted-foreground">{form.curriculo.name}</span>}
</div>
</div>
<div className="space-y-2">
<Label>Currículo</Label>
<div className="flex items-center gap-2">
<Label htmlFor="curriculo-input" className="cursor-pointer">
<Button type="button" variant="ghost" asChild className="bg-primary text-primary-foreground border-transparent hover:bg-primary">
<span>
<Upload className="mr-2 h-4 w-4 text-primary-foreground" />
Anexar PDF ou DOC
</span>
</Button>
</Label>
<Input
id="curriculo-input"
type="file"
className="hidden"
onChange={(e) => setField("curriculo", e.target.files?.[0] || null)}
accept=".pdf,.doc,.docx"
/>
{form.curriculo && <span className="text-sm text-primary-foreground">{form.curriculo.name}</span>}
</div>
</div>
<div className="grid grid-cols-2 gap-4">
<div className="space-y-2">
@ -644,7 +646,7 @@ if (missingFields.length > 0) {
</Button>
</div>
))}
<Button type="button" variant="outline" onClick={addFormacao}>
<Button type="button" onClick={addFormacao}>
Adicionar Formação
</Button>
</CardContent>
@ -752,17 +754,7 @@ if (missingFields.length > 0) {
</div>
</div>
<div className="space-y-2">
<Label>Agenda/Horário</Label>
// Dentro do form, apenas exiba o campo se precisar dele visualmente, mas não envie
<textarea
value={form.agenda_horario}
onChange={(e) => setField("agenda_horario", e.target.value)}
placeholder="Descreva os dias e horários de atendimento"
disabled={true} // Torne o campo apenas visual, sem enviar
/>
</div>
{/* Agenda/Horário removido conforme solicitado */}
<div className="space-y-4">
<Label>Dados Bancários</Label>
@ -902,10 +894,10 @@ if (missingFields.length > 0) {
<div className="space-y-2">
<Label>Adicionar anexos</Label>
<div className="border-2 border-dashed rounded-lg p-4">
<Label htmlFor="anexos" className="cursor-pointer block w-full">
<Label htmlFor="anexos" className="cursor-pointer block w-full rounded-md p-4 bg-primary text-primary-foreground">
<div className="flex flex-col items-center justify-center text-center">
<Upload className="h-7 w-7 mb-2" />
<p className="text-sm text-muted-foreground">Clique para adicionar documentos (PDF, imagens, etc.)</p>
<Upload className="h-7 w-7 mb-2 text-primary-foreground" />
<p className="text-sm text-primary-foreground">Clique para adicionar documentos (PDF, imagens, etc.)</p>
</div>
</Label>
<Input id="anexos" type="file" multiple className="hidden" onChange={addLocalAnexos} />

View File

@ -359,10 +359,10 @@ export function PatientRegistrationForm({
)}
</div>
<div className="space-y-2">
<Label htmlFor="photo" className="cursor-pointer">
<Button type="button" variant="outline" asChild>
<Label htmlFor="photo" className="cursor-pointer rounded-md transition-colors">
<Button type="button" variant="ghost" asChild className="bg-primary text-primary-foreground border-transparent hover:bg-primary">
<span>
<Upload className="mr-2 h-4 w-4" /> Carregar Foto
<Upload className="mr-2 h-4 w-4 text-primary-foreground" /> Carregar Foto
</span>
</Button>
</Label>
@ -550,10 +550,10 @@ export function PatientRegistrationForm({
<div className="space-y-2">
<Label>Adicionar anexos</Label>
<div className="border-2 border-dashed rounded-lg p-4">
<Label htmlFor="anexos" className="cursor-pointer block w-full">
<Label htmlFor="anexos" className="cursor-pointer block w-full rounded-md p-4 bg-primary text-primary-foreground">
<div className="flex flex-col items-center justify-center text-center">
<Upload className="h-7 w-7 mb-2" />
<p className="text-sm text-muted-foreground">Clique para adicionar documentos (PDF, imagens, etc.)</p>
<Upload className="h-7 w-7 mb-2 text-primary-foreground" />
<p className="text-sm text-primary-foreground">Clique para adicionar documentos (PDF, imagens, etc.)</p>
</div>
</Label>
<Input id="anexos" type="file" multiple className="hidden" onChange={addLocalAnexos} />