feat(lattes): melhorias na integracao Lattes e estilos da secao
- Aprimorar extracao de dados Lattes no backend - Melhorar estilos CSS da secao Lattes - Ajustes no componente ConsultorCard para exibicao do Lattes
This commit is contained in:
@@ -1335,8 +1335,9 @@
|
||||
|
||||
.modal-item {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.75rem;
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
gap: 0.2rem;
|
||||
padding: 0.6rem 0.8rem;
|
||||
background: rgba(255, 255, 255, 0.03);
|
||||
border-radius: 8px;
|
||||
@@ -1355,6 +1356,42 @@
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.modal-item-detail {
|
||||
color: var(--muted);
|
||||
font-size: 0.8rem;
|
||||
}
|
||||
|
||||
.modal-item-sub {
|
||||
display: block;
|
||||
width: 100%;
|
||||
margin-top: 0.25rem;
|
||||
font-size: 0.75rem;
|
||||
line-height: 1.3;
|
||||
}
|
||||
|
||||
.modal-section-title {
|
||||
color: var(--accent-2);
|
||||
font-size: 0.75rem;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.5px;
|
||||
margin: 1.25rem 0 0.5rem;
|
||||
padding-bottom: 0.25rem;
|
||||
border-bottom: 1px solid var(--stroke);
|
||||
}
|
||||
|
||||
.modal-section-title:first-of-type {
|
||||
margin-top: 0.75rem;
|
||||
}
|
||||
|
||||
.lattes-link-inline {
|
||||
color: var(--accent) !important;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.lattes-link-inline:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
.modal-summary {
|
||||
display: flex;
|
||||
gap: 1.5rem;
|
||||
|
||||
@@ -765,47 +765,122 @@ const ItemDetalheModal = ({ item, tipo, onClose }) => {
|
||||
}
|
||||
|
||||
case 'producoes_lattes': {
|
||||
const producoes = item.producoes || item.producoes_recentes || [];
|
||||
const titulacoes = item.titulacoes || [];
|
||||
const idiomas = item.idiomas || [];
|
||||
const orientacoes = item.orientacoes_concluidas || [];
|
||||
const endereco = item.endereco_profissional;
|
||||
return (
|
||||
<div className="modal-detalhe-content">
|
||||
<div className="modal-detalhe-row">
|
||||
<span className="modal-detalhe-label">Total</span>
|
||||
<span className="modal-detalhe-value">{item.total_producoes ?? 0}</span>
|
||||
<span className="modal-detalhe-label">ID Lattes</span>
|
||||
<a
|
||||
href={item.url}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
className="modal-detalhe-value lattes-link-inline"
|
||||
>
|
||||
{item.id_lattes} ↗
|
||||
</a>
|
||||
</div>
|
||||
<div className="modal-detalhe-row">
|
||||
<span className="modal-detalhe-label">Bibliográfica</span>
|
||||
<span className="modal-detalhe-value">{item.producao_bibliografica ?? 0}</span>
|
||||
</div>
|
||||
<div className="modal-detalhe-row">
|
||||
<span className="modal-detalhe-label">Técnica</span>
|
||||
<span className="modal-detalhe-value">{item.producao_tecnica ?? 0}</span>
|
||||
</div>
|
||||
<div className="modal-detalhe-row">
|
||||
<span className="modal-detalhe-label">Orientações</span>
|
||||
<span className="modal-detalhe-value">{item.orientacoes_lattes ?? 0}</span>
|
||||
</div>
|
||||
{item.data_atualizacao_lattes && (
|
||||
{item.nacionalidade && (
|
||||
<div className="modal-detalhe-row">
|
||||
<span className="modal-detalhe-label">Atualização</span>
|
||||
<span className="modal-detalhe-value">{formatDate(item.data_atualizacao_lattes)}</span>
|
||||
<span className="modal-detalhe-label">Nacionalidade</span>
|
||||
<span className="modal-detalhe-value">{item.nacionalidade}</span>
|
||||
</div>
|
||||
)}
|
||||
<div className="modal-detalhe-row">
|
||||
<span className="modal-detalhe-label">Produções recentes</span>
|
||||
<span className="modal-detalhe-value">{producoes.length}</span>
|
||||
</div>
|
||||
{producoes.length > 0 ? (
|
||||
<ul className="modal-list" style={{ marginTop: '0.6rem' }}>
|
||||
{producoes.map((prod, idx) => (
|
||||
<li key={idx} className="modal-item">
|
||||
<span className="modal-item-main">{prod.titulo || 'Sem título'}</span>
|
||||
<span className="muted">{prod.ano || '-'}</span>
|
||||
{prod.natureza && <span className="badge">{prod.natureza}</span>}
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
) : (
|
||||
<p className="modal-empty">Nenhuma produção encontrada.</p>
|
||||
|
||||
{titulacoes.length > 0 && (
|
||||
<>
|
||||
<h5 className="modal-section-title">Formação Acadêmica</h5>
|
||||
<ul className="modal-list">
|
||||
{titulacoes.map((t, idx) => (
|
||||
<li key={idx} className="modal-item">
|
||||
<span className="modal-item-main">
|
||||
<strong>{t.grau}</strong>
|
||||
{t.area && ` em ${t.area}`}
|
||||
</span>
|
||||
<span className="modal-item-detail">
|
||||
{t.ies_sigla || t.ies_nome}
|
||||
{t.ano && ` (${t.ano})`}
|
||||
</span>
|
||||
{t.programa && (
|
||||
<span className="modal-item-sub muted">Programa: {t.programa}</span>
|
||||
)}
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
</>
|
||||
)}
|
||||
|
||||
{idiomas.length > 0 && (
|
||||
<>
|
||||
<h5 className="modal-section-title">Idiomas</h5>
|
||||
<ul className="modal-list">
|
||||
{idiomas.map((i, idx) => (
|
||||
<li key={idx} className="modal-item">
|
||||
<span className="modal-item-main">{i.idioma}</span>
|
||||
<span className="modal-item-detail muted">
|
||||
{[
|
||||
i.proficiencia_leitura && `Leitura: ${i.proficiencia_leitura}`,
|
||||
i.proficiencia_escrita && `Escrita: ${i.proficiencia_escrita}`,
|
||||
i.proficiencia_fala && `Fala: ${i.proficiencia_fala}`,
|
||||
].filter(Boolean).join(' | ')}
|
||||
</span>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
</>
|
||||
)}
|
||||
|
||||
{orientacoes.length > 0 && (
|
||||
<>
|
||||
<h5 className="modal-section-title">
|
||||
Orientações Concluídas ({item.total_orientacoes})
|
||||
</h5>
|
||||
<ul className="modal-list">
|
||||
{orientacoes.slice(0, 10).map((o, idx) => (
|
||||
<li key={idx} className="modal-item">
|
||||
<span className="modal-item-main">{o.orientando || 'Orientando não informado'}</span>
|
||||
<span className="modal-item-detail">
|
||||
{o.tipo?.replace('Orientação ', '').replace(' Concluída', '')}
|
||||
{o.ano && ` (${o.ano})`}
|
||||
{o.ies && ` - ${o.ies}`}
|
||||
</span>
|
||||
{o.titulo && (
|
||||
<span className="modal-item-sub muted" style={{ fontSize: '0.75rem' }}>
|
||||
{o.titulo.length > 80 ? o.titulo.substring(0, 80) + '...' : o.titulo}
|
||||
</span>
|
||||
)}
|
||||
</li>
|
||||
))}
|
||||
{item.total_orientacoes > 10 && (
|
||||
<li className="modal-item muted">
|
||||
... e mais {item.total_orientacoes - 10} orientações
|
||||
</li>
|
||||
)}
|
||||
</ul>
|
||||
</>
|
||||
)}
|
||||
|
||||
{endereco && (
|
||||
<>
|
||||
<h5 className="modal-section-title">Endereço Profissional</h5>
|
||||
<div className="modal-detalhe-row">
|
||||
<span className="modal-detalhe-value">
|
||||
{[
|
||||
endereco.logradouro,
|
||||
endereco.numero,
|
||||
endereco.bairro,
|
||||
endereco.cidade,
|
||||
endereco.pais
|
||||
].filter(Boolean).join(', ')}
|
||||
</span>
|
||||
</div>
|
||||
</>
|
||||
)}
|
||||
|
||||
{titulacoes.length === 0 && idiomas.length === 0 && orientacoes.length === 0 && (
|
||||
<p className="modal-empty">Dados detalhados não disponíveis no ATUACAPES.</p>
|
||||
)}
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user