From 6603ddfe234187ed6c49ae71731ec0f9a660f018 Mon Sep 17 00:00:00 2001 From: Alexis Date: Tue, 2 Jun 2026 10:44:51 +0200 Subject: [PATCH 1/4] feat(ui): mejorar estilos y estructura de componentes en el dashboard MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Se ajustan los estilos y la estructura de varios componentes en el dashboard, incluyendo ExportDropdown, ResearcherCard, SwordProfileSelect y SyncButton, para mejorar la presentación y la responsividad. Se añade soporte para clases personalizadas en SyncButton y se integra el nuevo sistema de exportación en GroupResultsPage. --- .../components/dashboard/ExportDropdown.jsx | 5 +- .../components/dashboard/ResearcherCard.jsx | 2 +- .../dashboard/SwordProfileSelect.jsx | 22 ++++--- .../src/components/dashboard/SyncButton.jsx | 4 +- frontend/src/pages/DashboardPage.jsx | 6 +- frontend/src/pages/GroupResultsPage.jsx | 66 ++++++++----------- 6 files changed, 51 insertions(+), 54 deletions(-) diff --git a/frontend/src/components/dashboard/ExportDropdown.jsx b/frontend/src/components/dashboard/ExportDropdown.jsx index d9a5c23..88e38d8 100644 --- a/frontend/src/components/dashboard/ExportDropdown.jsx +++ b/frontend/src/components/dashboard/ExportDropdown.jsx @@ -49,19 +49,20 @@ export function ExportDropdown({ } return ( -
+
{actions && ( -
+
{actions}
)} diff --git a/frontend/src/components/dashboard/SwordProfileSelect.jsx b/frontend/src/components/dashboard/SwordProfileSelect.jsx index 77c7fc1..2d9f651 100644 --- a/frontend/src/components/dashboard/SwordProfileSelect.jsx +++ b/frontend/src/components/dashboard/SwordProfileSelect.jsx @@ -48,28 +48,32 @@ export function SwordProfileSelect({ return (
- Destino: -
+ + Destino: + +
{open && (
{options.map(({ value: optionValue, label, desc }, idx) => (
-
+
{desc}
diff --git a/frontend/src/components/dashboard/SyncButton.jsx b/frontend/src/components/dashboard/SyncButton.jsx index 70a6469..bca8420 100644 --- a/frontend/src/components/dashboard/SyncButton.jsx +++ b/frontend/src/components/dashboard/SyncButton.jsx @@ -5,7 +5,7 @@ import { Spinner } from "../ui/Spinner"; * Primary action button on the dashboard. Swaps icon + colour scheme * depending on the sync lifecycle (idle → loading → success flash). */ -export function SyncButton({ onClick, status = "idle" }) { +export function SyncButton({ onClick, status = "idle", className = "" }) { const isLoading = status === "loading"; const isSuccess = status === "success"; @@ -20,7 +20,7 @@ export function SyncButton({ onClick, status = "idle" }) { type="button" onClick={onClick} disabled={isLoading} - className={`inline-flex items-center gap-2 rounded-lg px-[18px] py-2.5 text-sm font-medium transition-colors disabled:cursor-not-allowed ${palette}`} + className={`inline-flex items-center justify-center gap-2 rounded-lg px-[18px] py-2.5 text-sm font-medium transition-colors disabled:cursor-not-allowed ${palette} ${className}`.trim()} > {isLoading ? ( diff --git a/frontend/src/pages/DashboardPage.jsx b/frontend/src/pages/DashboardPage.jsx index bedf4dd..b0c60a4 100644 --- a/frontend/src/pages/DashboardPage.jsx +++ b/frontend/src/pages/DashboardPage.jsx @@ -224,7 +224,11 @@ export function DashboardPage() { researcher={researcher} actions={ <> - + 0 - ? `Descargar lo nuevo de todos (${allNewIds.length})` - : "Todo descargado" - : `Descargar todo (${allIds.length})`; - - const globalDisabled = - Boolean(globalExporting) || - (isAuthenticated ? allNewIds.length === 0 : allIds.length === 0); - return (
@@ -233,33 +239,15 @@ export function GroupResultsPage() { {/* Global export buttons */} {!loading && results.length > 0 && ( -
- - {["xml", "zip"].map((fmt) => ( - - ))} -
+ )}
From 35eef2ff906114f572457b92fb7c0ff3ecefe49b Mon Sep 17 00:00:00 2001 From: Alexis Date: Tue, 2 Jun 2026 10:58:43 +0200 Subject: [PATCH 2/4] feat(ui): mejorar la responsividad y estructura de PublicationsTable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Se ajustan los estilos en PublicationsTable para mejorar la responsividad en dispositivos móviles. Se modifica la estructura del componente para incluir un mensaje de estado cuando no se encuentran publicaciones y se optimizan los estilos de los elementos de entrada y botones. --- .../dashboard/PublicationsTable.jsx | 320 +++++++++++------- 1 file changed, 207 insertions(+), 113 deletions(-) diff --git a/frontend/src/components/dashboard/PublicationsTable.jsx b/frontend/src/components/dashboard/PublicationsTable.jsx index 3f7191e..2334fa2 100644 --- a/frontend/src/components/dashboard/PublicationsTable.jsx +++ b/frontend/src/components/dashboard/PublicationsTable.jsx @@ -258,7 +258,7 @@ export function PublicationsTable({ )}

-
+
-
+
@@ -366,123 +366,217 @@ export function PublicationsTable({ ) : loading ? ( ) : ( - - - - - {COLUMNS.map((col) => ( - - ))} - - - + <> +
{filtered.length === 0 ? ( -
- - +

+ No se encontraron publicaciones con los filtros aplicados. +

) : ( - pageRows.map((pub, i) => { - const isSelected = selectedIds.has(pub.id); - return ( - +
+ +
+
+ {pageRows.map((pub, i) => { + const isSelected = selectedIds.has(pub.id); + return ( +
+
+ toggleRow(pub.id)} + ariaLabel={`Seleccionar publicación ${pub.title}`} + /> +
+
+ {isAuthenticated && pub.downloaded_by_me === false && ( + + + Nuevo + + )} +

+ {pub.title} +

+
+
+
+
+

+ Revista:{" "} + {pub.journal || "—"} +

+

+ Año:{" "} + {pub.publication_year ?? "—"} +

+

+ DOI:{" "} + {pub.doi ? ( + + {pub.doi} + + ) : ( + + — + + )} +

+
+ +
+
+
+ ); + })} +
+ + )} + + +
e.stopPropagation()} - > - - toggleSort(col.key)} - className={`select-none border-b border-surface-border/60 px-4 py-2.5 text-left text-xs font-medium tracking-wide text-ink-secondary${col.thClass ? ` ${col.thClass}` : ""}`} - > - - {col.label.toUpperCase()} - - -
- No se encontraron publicaciones con los filtros aplicados. -
+ + + + {COLUMNS.map((col) => ( + - + + + {filtered.length === 0 ? ( + + + + ) : ( + pageRows.map((pub, i) => { + const isSelected = selectedIds.has(pub.id); + return ( + + + + + + - - - - - - ); - }) - )} - -
e.stopPropagation()} + > + + toggleSort(col.key)} + className={`select-none border-b border-surface-border/60 px-4 py-2.5 text-left text-xs font-medium tracking-wide text-ink-secondary${col.thClass ? ` ${col.thClass}` : ""}`} > - { - e.stopPropagation(); - toggleRow(pub.id); - }} - > - toggleRow(pub.id)} - ariaLabel={`Seleccionar publicación ${pub.title}`} + + {col.label.toUpperCase()} + - - - {isAuthenticated && pub.downloaded_by_me === false && ( - + + ))} +
+ No se encontraron publicaciones con los filtros aplicados. +
{ + e.stopPropagation(); + toggleRow(pub.id); + }} + > + toggleRow(pub.id)} + ariaLabel={`Seleccionar publicación ${pub.title}`} + /> + + + {isAuthenticated && pub.downloaded_by_me === false && ( + + + Nuevo + + )} + {pub.title} + + + {pub.journal || "—"} + + {pub.publication_year ?? "—"} + + {pub.doi ? ( + e.stopPropagation()} + className="whitespace-nowrap font-mono text-xs text-brand-accent hover:underline" > - - Nuevo + {pub.doi} + + ) : ( + + — )} - {pub.title} - - - {pub.journal || "—"} - - {pub.publication_year ?? "—"} - - {pub.doi ? ( - e.stopPropagation()} - className="whitespace-nowrap font-mono text-xs text-brand-accent hover:underline" - > - {pub.doi} - - ) : ( - - — - - )} - - -
+ + + + + + ); + }) + )} + + + )}
From 63ef7b256145aeb3c6d33c61f22340f548a08132 Mon Sep 17 00:00:00 2001 From: Alexis Date: Tue, 2 Jun 2026 11:10:22 +0200 Subject: [PATCH 3/4] feat(ui): ajustar estilos y estructura en los filtros de PublicationsTable para mejorar la responsividad MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Se modifican los estilos y la estructura del componente PublicationsTable, optimizando la disposición de botones y campos de entrada para una mejor experiencia en dispositivos móviles. Se asegura que los elementos se alineen correctamente y se añaden clases para mejorar la presentación visual. --- .../src/components/dashboard/PublicationsTable.jsx | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/frontend/src/components/dashboard/PublicationsTable.jsx b/frontend/src/components/dashboard/PublicationsTable.jsx index 2334fa2..f294b50 100644 --- a/frontend/src/components/dashboard/PublicationsTable.jsx +++ b/frontend/src/components/dashboard/PublicationsTable.jsx @@ -258,13 +258,13 @@ export function PublicationsTable({ )}

-
+
-
+
-
+
-
+
{hasYearFilter && ( From 02725dfa2c2c77bd36cabf9eb8005402a5e53eef Mon Sep 17 00:00:00 2001 From: Alexis Date: Tue, 2 Jun 2026 12:38:04 +0200 Subject: [PATCH 4/4] feat(ui): mejorar la estructura y estilos en el Footer y LandingPage MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Se ajustan los estilos y la estructura del componente Footer para mejorar la presentación y la alineación de los elementos. Además, se modifica el texto en LandingPage para una mejor claridad en la comunicación. Se optimizan las clases de Tailwind para una mejor responsividad y experiencia de usuario. --- .../dashboard/PublicationsTable.jsx | 108 +++++++++++------- frontend/src/components/layout/Footer.jsx | 18 +-- frontend/src/pages/GroupResultsPage.jsx | 10 +- frontend/src/pages/LandingPage.jsx | 2 +- 4 files changed, 87 insertions(+), 51 deletions(-) diff --git a/frontend/src/components/dashboard/PublicationsTable.jsx b/frontend/src/components/dashboard/PublicationsTable.jsx index f294b50..7142cd8 100644 --- a/frontend/src/components/dashboard/PublicationsTable.jsx +++ b/frontend/src/components/dashboard/PublicationsTable.jsx @@ -271,7 +271,8 @@ export function PublicationsTable({ }`} > - Filtros + Filtros + Filtros avanzados {hasYearFilter && ( -
- - ({ - value: String(y), - label: String(y), - }))} - className="w-full" - /> +
+

+ Filtrar por año de publicación +

+ {yearFilterSummary && ( + + {yearFilterSummary} + + )}
-
- - ({ - value: String(y), - label: String(y), - }))} - className="w-full" - /> + +
+
+ + ({ + value: String(y), + label: String(y), + }))} + className="w-full" + /> +
+ +
+ — +
+ +
+ + ({ + value: String(y), + label: String(y), + }))} + className="w-full" + /> +
+ + {hasYearFilter && ( + + )}
+ {hasYearFilter && ( diff --git a/frontend/src/components/layout/Footer.jsx b/frontend/src/components/layout/Footer.jsx index eb9b709..04d29aa 100644 --- a/frontend/src/components/layout/Footer.jsx +++ b/frontend/src/components/layout/Footer.jsx @@ -6,11 +6,11 @@ export default function Footer() {
{/* Main row */} -
+
{/* Brand */} -
-
+
+
ORCID2SWORD @@ -19,16 +19,16 @@ export default function Footer() {

- Sincronización de publicaciones ORCID al repositorio institucional. + Extracción y preparación de publicaciones ORCID para repositorios académicos.

{/* Compatible con */}
- + Compatible con -
+
{technologies.map((tech) => ( {/* Institutional links */} -
+
{/* Universidad de Jaén */}
@@ -65,7 +65,7 @@ export default function Footer() {
diff --git a/frontend/src/pages/GroupResultsPage.jsx b/frontend/src/pages/GroupResultsPage.jsx index 613de83..68c1a46 100644 --- a/frontend/src/pages/GroupResultsPage.jsx +++ b/frontend/src/pages/GroupResultsPage.jsx @@ -214,6 +214,14 @@ export function GroupResultsPage() {
+ + + Volver al inicio + + {/* Page header */}
@@ -282,7 +290,6 @@ export function GroupResultsPage() { swordProfile, ) } - swordProfile={swordProfile} /> ))}
@@ -343,7 +350,6 @@ function ResearcherResultCard({ isAuthenticated, exporting, onExport, - swordProfile, }) { const researcher = bundle.researcher ?? {}; const publications = bundle.publications ?? []; diff --git a/frontend/src/pages/LandingPage.jsx b/frontend/src/pages/LandingPage.jsx index 8a9ce27..f26d92f 100644 --- a/frontend/src/pages/LandingPage.jsx +++ b/frontend/src/pages/LandingPage.jsx @@ -221,7 +221,7 @@ export function LandingPage() { Tus publicaciones, listas para depositar.

- Conecta tu ORCID y descárgalas en XML cuando quieras. + Conecta tu ORCID y descárgalas cuando quieras.