@crtobiasdelsud/portal-ui 1.0.13 → 1.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@crtobiasdelsud/portal-ui",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.15",
|
|
4
4
|
"description": "Componentes compartidos entre el portal (Next) y el CMS (Vite) — widgets, views, providers para adapters y article pool.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./src/index.js",
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
2
|
|
|
3
|
-
import ArticleHeroFull from
|
|
4
|
-
import AuthorBlock from
|
|
5
|
-
import ShareBlock from
|
|
6
|
-
import EditorOutputFull from
|
|
7
|
-
import
|
|
8
|
-
import styles from './Full.module.scss'
|
|
3
|
+
import ArticleHeroFull from "../ArticleHeroFull/ArticleHeroFull.jsx";
|
|
4
|
+
import AuthorBlock from "../AuthorBlock/AuthorBlock.jsx";
|
|
5
|
+
import ShareBlock from "../ShareBlock/ShareBlock.jsx";
|
|
6
|
+
import EditorOutputFull from "../EditorOutputFull/EditorOutputFull.jsx";
|
|
7
|
+
import styles from "./Full.module.scss";
|
|
9
8
|
|
|
10
9
|
/**
|
|
11
10
|
* Réplica de la screen `ArticleDetailFull` (camino non-AMP) del portal —
|
|
@@ -15,22 +14,14 @@ import styles from './Full.module.scss'
|
|
|
15
14
|
* zona post-body de widgets desde el registry).
|
|
16
15
|
*/
|
|
17
16
|
export default function Full({ article }) {
|
|
18
|
-
const imagenEpigrafe =
|
|
17
|
+
const imagenEpigrafe =
|
|
18
|
+
article.imagen?.epigrafe ?? article.imagenEpigrafe ?? null;
|
|
19
19
|
|
|
20
|
-
const
|
|
21
|
-
{ label: 'Inicio', href: '/' },
|
|
22
|
-
...(article.categoria?.parent
|
|
23
|
-
? [{ label: article.categoria.parent.nombre ?? '', href: `/${article.categoria.parent.slug ?? ''}` }]
|
|
24
|
-
: []),
|
|
25
|
-
{ label: article.categoria?.nombre ?? '', href: `/${article.categoria?.slug ?? ''}` },
|
|
26
|
-
]
|
|
27
|
-
|
|
28
|
-
// Carrusel: la portada (principal) + las secundarias de la galería.
|
|
29
|
-
const galeria = Array.isArray(article.imagen?.galeria) ? article.imagen.galeria : []
|
|
20
|
+
const galeria = Array.isArray(article.imagen?.galeria) ? article.imagen.galeria : [];
|
|
30
21
|
const imagenes = [
|
|
31
22
|
...(article.imagen?.url ? [{ url: article.imagen.url, epigrafe: imagenEpigrafe }] : []),
|
|
32
23
|
...galeria.filter((g) => g?.url).map((g) => ({ url: g.url, epigrafe: g.epigrafe ?? null })),
|
|
33
|
-
]
|
|
24
|
+
];
|
|
34
25
|
|
|
35
26
|
return (
|
|
36
27
|
<>
|
|
@@ -44,22 +35,18 @@ export default function Full({ article }) {
|
|
|
44
35
|
categoria={article.categoria ?? null}
|
|
45
36
|
/>
|
|
46
37
|
|
|
47
|
-
<div className={styles.
|
|
48
|
-
<
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
/>
|
|
56
|
-
<ShareBlock />
|
|
57
|
-
</div>
|
|
38
|
+
<div className={styles.author}>
|
|
39
|
+
<AuthorBlock
|
|
40
|
+
autor={article.autor}
|
|
41
|
+
publicarComoOrg={article.publicarComoOrg}
|
|
42
|
+
fechaPublicacion={article.fechaPublicacion}
|
|
43
|
+
/>
|
|
44
|
+
<ShareBlock />
|
|
45
|
+
</div>
|
|
58
46
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
</div>
|
|
47
|
+
<div className={styles.body}>
|
|
48
|
+
<EditorOutputFull data={article.cuerpo} />
|
|
62
49
|
</div>
|
|
63
50
|
</>
|
|
64
|
-
)
|
|
51
|
+
);
|
|
65
52
|
}
|
|
@@ -39,18 +39,23 @@
|
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
41
|
|
|
42
|
-
/*
|
|
42
|
+
/* Marcador / highlighter — WYSIWYG con el CMS.
|
|
43
|
+
- Sin style inline → usa el primary del sitio (semitransparente) como fondo.
|
|
44
|
+
- Con style inline (background-color custom) → respeta el color elegido. */
|
|
43
45
|
.body :global(mark:not([style])),
|
|
44
46
|
.body :global(.cdx-marker:not([style])) {
|
|
45
|
-
background: transparent;
|
|
46
|
-
color:
|
|
47
|
+
background: color-mix(in srgb, var(--eo-primary, #B1043F) 20%, transparent);
|
|
48
|
+
color: inherit;
|
|
47
49
|
font-style: inherit;
|
|
50
|
+
padding: 0 0.1em;
|
|
51
|
+
border-radius: 2px;
|
|
48
52
|
}
|
|
49
53
|
|
|
50
|
-
/* mark CON color inline (background-color del plugin) → texto negro, fondo del color elegido */
|
|
51
54
|
.body :global(mark[style]) {
|
|
52
|
-
color:
|
|
55
|
+
color: inherit;
|
|
53
56
|
font-style: inherit;
|
|
57
|
+
padding: 0 0.1em;
|
|
58
|
+
border-radius: 2px;
|
|
54
59
|
}
|
|
55
60
|
|
|
56
61
|
.listUl,
|
|
@@ -46,18 +46,23 @@
|
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
48
|
|
|
49
|
-
/*
|
|
49
|
+
/* Marcador / highlighter — WYSIWYG con el CMS.
|
|
50
|
+
- Sin style inline → usa el primary del sitio (semitransparente) como fondo.
|
|
51
|
+
- Con style inline (background-color custom) → respeta el color elegido. */
|
|
50
52
|
.body :global(mark:not([style])),
|
|
51
53
|
.body :global(.cdx-marker:not([style])) {
|
|
52
|
-
background: transparent;
|
|
53
|
-
color:
|
|
54
|
+
background: color-mix(in srgb, var(--eo-primary, #B1043F) 20%, transparent);
|
|
55
|
+
color: inherit;
|
|
54
56
|
font-style: inherit;
|
|
57
|
+
padding: 0 0.1em;
|
|
58
|
+
border-radius: 2px;
|
|
55
59
|
}
|
|
56
60
|
|
|
57
|
-
/* mark CON color inline (background-color del plugin) → texto negro, fondo del color elegido */
|
|
58
61
|
.body :global(mark[style]) {
|
|
59
|
-
color:
|
|
62
|
+
color: inherit;
|
|
60
63
|
font-style: inherit;
|
|
64
|
+
padding: 0 0.1em;
|
|
65
|
+
border-radius: 2px;
|
|
61
66
|
}
|
|
62
67
|
|
|
63
68
|
.listUl,
|