Refatora o estilo do formulário do paciente para uma aparência de cartão com tipografia maior
This commit is contained in:
parent
37e89597d9
commit
b2707e33c3
@ -85,8 +85,6 @@ function PatientForm({ onSave, onCancel, PatientDict }) {
|
||||
infoConvenio: false,
|
||||
endereco: false,
|
||||
contato: false,
|
||||
infoAdicionais: false,
|
||||
anexos: false,
|
||||
});
|
||||
|
||||
// Função para alternar o estado de colapso de uma seção
|
||||
@ -141,7 +139,7 @@ function PatientForm({ onSave, onCancel, PatientDict }) {
|
||||
setFormData(prev => ({ ...prev, [name]: telefoneFormatado }));
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
const handleCepBlur = async () => {
|
||||
const cep = formData.cep.replace(/\D/g, '');
|
||||
if (cep.length === 8) {
|
||||
@ -375,6 +373,21 @@ function PatientForm({ onSave, onCancel, PatientDict }) {
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* CAMPOS MOVIDOS */}
|
||||
<div className="col-md-12 mb-3 mt-3">
|
||||
<label style={{ fontSize: '1.1rem' }}>Observações:</label>
|
||||
<textarea className="form-control" name="observacoes" value={formData.observacoes} onChange={handleChange} style={{ fontSize: '1.1rem' }}></textarea>
|
||||
</div>
|
||||
<div className="col-md-12 mb-3">
|
||||
<label style={{ fontSize: '1.1rem' }}>Anexos do Paciente:</label>
|
||||
<div>
|
||||
<label htmlFor="anexos-input" className="btn btn-secondary" style={{ fontSize: '1.1rem' }}>Escolher arquivo</label>
|
||||
<input type="file" className="form-control d-none" name="anexos" id="anexos-input" onChange={handleChange} />
|
||||
<span className="ms-2" style={{ fontSize: '1.1rem' }}>{formData.anexos ? formData.anexos.name : 'Nenhum arquivo escolhido'}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -547,44 +560,7 @@ function PatientForm({ onSave, onCancel, PatientDict }) {
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* INFORMAÇÕES ADICIONAIS */}
|
||||
<div className="mb-5 p-4 border rounded shadow-sm">
|
||||
<h4 className="mb-4 cursor-pointer d-flex justify-content-between align-items-center" onClick={() => handleToggleCollapse('infoAdicionais')} style={{ fontSize: '1.8rem' }}>
|
||||
Informações Adicionais
|
||||
<span className="fs-5">
|
||||
{collapsedSections.infoAdicionais ? '▲' : '▼'}
|
||||
</span>
|
||||
</h4>
|
||||
<div className={`collapse${collapsedSections.infoAdicionais ? ' show' : ''}`}>
|
||||
<div className="row mt-3">
|
||||
<div className="mb-3">
|
||||
<label style={{ fontSize: '1.1rem' }}>Observações:</label>
|
||||
<textarea className="form-control" name="observacoes" value={formData.observacoes} onChange={handleChange} style={{ fontSize: '1.1rem' }}></textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* ANEXOS DO PACIENTE */}
|
||||
<div className="mb-5 p-4 border rounded shadow-sm">
|
||||
<h4 className="mb-4 cursor-pointer d-flex justify-content-between align-items-center" onClick={() => handleToggleCollapse('anexos')} style={{ fontSize: '1.8rem' }}>
|
||||
Anexos do Paciente
|
||||
<span className="fs-5">
|
||||
{collapsedSections.anexos ? '▲' : '▼'}
|
||||
</span>
|
||||
</h4>
|
||||
<div className={`collapse${collapsedSections.anexos ? ' show' : ''}`}>
|
||||
<div className="row mt-3">
|
||||
<div className="mb-3">
|
||||
<label htmlFor="anexos-input" className="btn btn-secondary" style={{ fontSize: '1.1rem' }}>Escolher arquivo</label>
|
||||
<input type="file" className="form-control d-none" name="anexos" id="anexos-input" onChange={handleChange} />
|
||||
<span className="ms-2" style={{ fontSize: '1.1rem' }}>{formData.anexos ? formData.anexos.name : 'Nenhum arquivo escolhido'}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* Botões */}
|
||||
<div className="mt-3 text-center">
|
||||
<button className="btn btn-success me-3" onClick={handleSubmit} style={{ fontSize: '1.2rem', padding: '0.75rem 1.5rem' }}>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user