@eduardoalvarez/arrecife 0.5.1 → 0.6.0

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.
Files changed (66) hide show
  1. package/CHANGELOG.md +45 -0
  2. package/README.md +706 -470
  3. package/dist/brand/index.cjs +112 -95
  4. package/dist/brand/index.d.cts +40 -39
  5. package/dist/brand/index.d.ts +40 -39
  6. package/dist/brand/index.js +5 -4
  7. package/dist/catalog-D13txprv.d.cts +78 -0
  8. package/dist/catalog-D13txprv.d.ts +78 -0
  9. package/dist/chart/index.cjs +100 -83
  10. package/dist/chart/index.d.cts +66 -66
  11. package/dist/chart/index.d.ts +66 -66
  12. package/dist/chart/index.js +14 -12
  13. package/dist/chunk-25YNFCIF.js +141 -0
  14. package/dist/{chunk-YZ2SDOVZ.js → chunk-6O3KWB6P.js} +30 -30
  15. package/dist/chunk-CKRSQPTX.js +36 -0
  16. package/dist/{chunk-ZEOQKRQ7.js → chunk-DKCN7BAL.js} +1 -1
  17. package/dist/chunk-GCRII2KQ.js +86 -0
  18. package/dist/chunk-JMOOFZ3B.js +42 -0
  19. package/dist/chunk-O4TAH7YJ.js +276 -0
  20. package/dist/chunk-ODBFN44D.js +45 -0
  21. package/dist/{chunk-VPT32GPG.js → chunk-PMN7NR3G.js} +2 -2
  22. package/dist/chunk-XKYHTOUJ.js +27 -0
  23. package/dist/form/index.cjs +109 -92
  24. package/dist/form/index.d.cts +43 -42
  25. package/dist/form/index.d.ts +43 -42
  26. package/dist/form/index.js +25 -23
  27. package/dist/index.cjs +1047 -914
  28. package/dist/index.d.cts +769 -777
  29. package/dist/index.d.ts +769 -777
  30. package/dist/index.js +608 -660
  31. package/dist/{label-DuTvJGxD.d.ts → label-MgHFKnFy.d.cts} +3 -3
  32. package/dist/{label-DuTvJGxD.d.cts → label-MgHFKnFy.d.ts} +3 -3
  33. package/dist/og/index.cjs +130 -130
  34. package/dist/og/index.d.cts +93 -89
  35. package/dist/og/index.d.ts +93 -89
  36. package/dist/og/index.js +106 -106
  37. package/dist/shiki/index.cjs +28 -30
  38. package/dist/shiki/index.d.cts +4 -4
  39. package/dist/shiki/index.d.ts +4 -4
  40. package/dist/shiki/index.js +12 -12
  41. package/dist/theme/index.cjs +97 -0
  42. package/dist/theme/index.d.cts +144 -0
  43. package/dist/theme/index.d.ts +144 -0
  44. package/dist/theme/index.js +2 -0
  45. package/dist/tokens/index.cjs +133 -86
  46. package/dist/tokens/index.d.cts +246 -161
  47. package/dist/tokens/index.d.ts +246 -161
  48. package/dist/tokens/index.js +2 -2
  49. package/dist/tokens/theme.css +133 -98
  50. package/dist/variants/index.cjs +192 -0
  51. package/dist/variants/index.d.cts +192 -0
  52. package/dist/variants/index.d.ts +192 -0
  53. package/dist/variants/index.js +3 -0
  54. package/llms.txt +810 -744
  55. package/package.json +20 -11
  56. package/dist/catalogo-Du5ID-Hi.d.cts +0 -77
  57. package/dist/catalogo-Du5ID-Hi.d.ts +0 -77
  58. package/dist/chunk-E3OMP2DL.js +0 -36
  59. package/dist/chunk-KPZNNMV5.js +0 -83
  60. package/dist/chunk-NHS7ETKJ.js +0 -27
  61. package/dist/chunk-TSPJOM6K.js +0 -229
  62. package/dist/chunk-UOWIDFCB.js +0 -81
  63. package/dist/tema/index.cjs +0 -94
  64. package/dist/tema/index.d.cts +0 -110
  65. package/dist/tema/index.d.ts +0 -110
  66. package/dist/tema/index.js +0 -2
@@ -1,164 +1,168 @@
1
- import { C as Cara, P as Pose } from '../catalogo-Du5ID-Hi.cjs';
1
+ import { F as Face, P as Pose } from '../catalog-D13txprv.cjs';
2
2
 
3
3
  /**
4
- * Las cuatro plantillas de Open Graph, 1200×630.
4
+ * The four Open Graph templates, 1200×630.
5
5
  *
6
- * NO son componentes de React. Devuelven el árbol de elementos que Satori
7
- * espera —`{ type, props }`— construido solo con tokens y con el catálogo de la
8
- * marca, que es dato puro. Este módulo se puede importar desde un worker, un
9
- * script de build o una función de borde sin montar nada.
6
+ * They are NOT React components. They return the element tree Satori expects —
7
+ * `{ type, props }` — built only from tokens and from the brand catalog, which
8
+ * is pure data. This module can be imported from a worker, a build script or an
9
+ * edge function without mounting anything.
10
10
  *
11
- * Es el caso que justifica la restricción de `src/tokens/`: si un token hubiera
12
- * terminado dependiendo de un componente, este archivo no existiría.
11
+ * It is the case that justifies the `src/tokens/` constraint: if a token had
12
+ * ended up depending on a component, this file would not exist.
13
13
  *
14
- * LA RETÍCULA ES UNA, del documento: eyebrow arriba, titular a la izquierda,
15
- * firma abajo y la mascota anclada a la derecha. Lo único que cambia entre
16
- * plantillas es el fondo y qué pose entra. Por eso no hay cuatro maquetaciones
17
- * aquí: hay una, y tres parámetros.
14
+ * THERE IS ONE GRID, from the document: eyebrow on top, headline on the left,
15
+ * signature at the bottom and the mascot anchored to the right. The only things
16
+ * that change between templates are the background and which pose comes in.
17
+ * Which is why there are not four layouts here: there is one, and three
18
+ * parameters.
18
19
  *
19
- * lienzo 1200×630 · margen 64
20
- * eyebrow mono 20 · tracking 0.12em
21
- * titular display 800 · 58 · máx 3 líneas al 70 % del ancho
22
- * firma mono 21 · con la aleta a 34
23
- * mascota anclada a la derecha · alto máx 430
20
+ * canvas 1200×630 · margin 64
21
+ * eyebrow mono 20 · tracking 0.12em
22
+ * headline display 800 · 58 · max 3 lines at 70 % of the width
23
+ * signature mono 21 · with the fin at 34
24
+ * mascot anchored right · max height 430
24
25
  *
25
- * La de por defecto es la excepción declarada: retícula propia de dos columnas
26
- * con la aleta a 200 y divisor en x=290, y Geist 72/700 y 28/400 en vez de la
27
- * display. Está en el documento como excepción, así que está aquí como función
28
- * aparte y no como un `if` dentro de la común.
26
+ * The default one is the declared exception: a two-column grid of its own with
27
+ * the fin at 200 and a divider at x=290, and Geist 72/700 and 28/400 instead of
28
+ * the display face. It is in the document as an exception, so it is here as a
29
+ * separate function and not as an `if` inside the shared one.
29
30
  *
30
- * LA ALETA NO ES UN PARÁMETRO. El documento avisa de que «es el error más fácil
31
- * de cometer en un generador, porque el fondo es un parámetro»: espuma en las
32
- * tres plantillas oscuras, dos azules en la de curso. Aquí la elige el modo de
33
- * la plantilla, igual que `Isotipo` la elige con `sobre`. No hay forma de pedir
34
- * la combinación mala.
31
+ * THE FIN IS NOT A PARAMETER. The document warns that «it is the easiest
32
+ * mistake to make in a generator, because the background is a parameter»: foam
33
+ * in the three dark templates, two blues in the course one. Here it is chosen by
34
+ * the template's mode, the same way `Isotype` chooses it from `background`.
35
+ * There is no way to ask for the bad combination.
35
36
  *
36
- * El titular se trunca a 3 líneas con elipsis y NUNCA baja de tamaño: un titular
37
- * a 44 y otro a 58 en el mismo feed se ven como dos marcas distintas.
37
+ * The headline truncates to 3 lines with an ellipsis and NEVER shrinks: a
38
+ * headline at 44 and another at 58 in the same feed read as two different
39
+ * brands.
38
40
  *
39
- * Las imágenes llevan `alt=''`. Satori no lo necesita —pinta a SVG—, pero la
40
- * mascota y la aleta SON decorativas aquí: lo que la tarjeta dice es el titular,
41
- * y el `alt` de una OG lo pone el `<meta property="og:image:alt">` de la página.
42
- * Además, la story las monta como `<img>` de verdad y sin `alt` no pasan axe.
41
+ * The images carry `alt=''`. Satori does not need it — it paints to SVG — but
42
+ * the mascot and the fin ARE decorative here: what the card says is the
43
+ * headline, and an OG's `alt` is set by the page's
44
+ * `<meta property="og:image:alt">`. On top of that, the story mounts them as
45
+ * real `<img>` elements and without `alt` they do not pass axe.
43
46
  *
44
- * Uso:
47
+ * Usage:
45
48
  *
46
49
  * import satori from 'satori';
47
- * import { plantillaArticulo, OG } from '@eduardoalvarez/arrecife/og';
50
+ * import { articleTemplate, OG } from '@eduardoalvarez/arrecife/og';
48
51
  *
49
- * const svg = await satori(plantillaArticulo({ title, category, readingMinutes }), {
52
+ * const svg = await satori(articleTemplate({ title, category, readingMinutes }), {
50
53
  * width: OG.width,
51
54
  * height: OG.height,
52
55
  * fonts: [...],
53
56
  * });
54
57
  */
55
58
 
56
- type NodoSatori = {
59
+ type SatoriNode = {
57
60
  type: string;
58
61
  props: Record<string, unknown> & {
59
62
  style?: Record<string, string | number>;
60
- children?: Hijo | readonly Hijo[];
63
+ children?: Child | readonly Child[];
61
64
  };
62
65
  };
63
- type Hijo = NodoSatori | string | null | undefined | false;
64
- /** El lienzo y la retícula. Son las medidas de producción. */
66
+ type Child = SatoriNode | string | null | undefined | false;
67
+ /** The canvas and the grid. These are the production measurements. */
65
68
  declare const OG: {
66
69
  readonly width: 1200;
67
70
  readonly height: 630;
68
- readonly margen: 64;
69
- /** Alto máximo de la mascota. */
70
- readonly mascota: 430;
71
- /** La aleta de la firma. */
72
- readonly aletaFirma: 34;
71
+ readonly margin: 64;
72
+ /** The mascot's maximum height. */
73
+ readonly mascot: 430;
74
+ /** The signature's fin. */
75
+ readonly signatureFin: 34;
73
76
  /**
74
- * Hueco que deja la columna cuando la pose va a la izquierda (curso).
77
+ * The gap the column leaves when the pose goes on the left (course).
75
78
  *
76
- * Son 560 y no 420 porque una pose completa a 430 de alto mide ~534 de ancho:
77
- * con el hueco justo, el tiburón se comía el titular. La reserva se mide por
78
- * el ancho real de la pose, no por el margen.
79
+ * It is 560 and not 420 because a full pose at 430 tall measures ~534 wide:
80
+ * with the exact gap, the shark ate into the headline. The reserve is measured
81
+ * by the pose's real width, not by the margin.
79
82
  */
80
- readonly reservaMascota: 560;
83
+ readonly mascotReserve: 560;
81
84
  };
82
- type DatosBase = {
85
+ type BaseData = {
83
86
  title: string;
84
87
  /**
85
- * Dónde se sirven los PNG. Satori no lee del disco: en un worker esto tiene
86
- * que ser una URL absoluta o un `data:` URI.
88
+ * Where the PNGs are served from. Satori does not read from disk: in a worker
89
+ * this has to be an absolute URL or a `data:` URI.
87
90
  */
88
91
  basePath?: string | undefined;
89
92
  };
90
93
  /**
91
- * La retícula compartida. Tres de las cuatro plantillas son esto con otro fondo
92
- * y otra pieza de mascota.
94
+ * The shared grid. Three of the four templates are this with a different
95
+ * background and a different mascot piece.
93
96
  */
94
- declare function tarjeta(opciones: {
95
- modo: 'oscuro' | 'claro';
96
- fondo: string;
97
+ declare function card(options: {
98
+ mode: 'dark' | 'light';
99
+ background: string;
97
100
  eyebrow: {
98
- texto: string;
101
+ text: string;
99
102
  color: string;
100
103
  };
101
104
  title: string;
102
- /** Línea bajo el titular, opcional. */
105
+ /** A line under the headline, optional. */
103
106
  bajada?: string | undefined;
104
- firma: string;
107
+ signature: string;
105
108
  firmaColor: string;
106
109
  base: string;
107
- /** La pieza de la derecha, ya montada. */
108
- mascota?: NodoSatori | null | undefined;
109
- /** `curso` la pone a la izquierda: es la única que invierte la retícula. */
110
+ /** The right-hand piece, already assembled. */
111
+ mascot?: SatoriNode | null | undefined;
112
+ /** `curso` puts it on the left: it is the only one that inverts the grid. */
110
113
  mascotaIzquierda?: boolean | undefined;
111
114
  tinta: string;
112
115
  tintaSecundaria: string;
113
- }): NodoSatori;
114
- type DatosArticulo = DatosBase & {
115
- /** El slug de la categoría. Va en arena, en versalitas. */
116
+ }): SatoriNode;
117
+ type ArticleData = BaseData & {
118
+ /** The category slug. It goes in sand, in small caps. */
116
119
  category?: string | undefined;
117
120
  readingMinutes?: number | undefined;
118
121
  /**
119
- * La cara, «según el tono del texto». No hay defecto pensado como neutro:
120
- * `hearts` es la que el manual asigna al OG de artículo.
122
+ * The face, «according to the text's tone». There is no default meant as
123
+ * neutral: `hearts` is the one the manual assigns to the article OG.
121
124
  */
122
- expresion?: Cara | undefined;
125
+ expression?: Face | undefined;
123
126
  };
124
- /** Artículo · degradado 145° sobre abismo, categoría y lectura en arena. */
125
- declare function plantillaArticulo(datos: DatosArticulo): NodoSatori;
126
- type DatosCurso = DatosBase & {
127
+ /** Article · 145° gradient over abyss, category and reading time in sand. */
128
+ declare function articleTemplate(data: ArticleData): SatoriNode;
129
+ type CourseData = BaseData & {
127
130
  modules?: number | undefined;
128
131
  duration?: string | undefined;
129
- /** El dominio del pie. Por defecto, el subdominio de cursos. */
132
+ /** The footer's domain. The courses subdomain by default. */
130
133
  url?: string | undefined;
131
134
  pose?: Pose | undefined;
132
135
  };
133
136
  /**
134
- * Curso · LA ÚNICA PLANTILLA EN CLARO.
137
+ * Course · THE ONLY LIGHT TEMPLATE.
135
138
  *
136
- * Pose completa a la izquierda —invierte la retícula—, eyebrow y URL en arena
137
- * oscura, y por tanto la aleta a dos azules. Esa última parte no se decide aquí:
138
- * sale de que el modo es claro.
139
+ * Full pose on the left — it inverts the grid — eyebrow and URL in dark sand,
140
+ * and therefore the two-blue fin. That last part is not decided here: it follows
141
+ * from the mode being light.
139
142
  */
140
- declare function plantillaCurso(datos: DatosCurso): NodoSatori;
141
- type DatosCharla = DatosBase & {
143
+ declare function courseTemplate(data: CourseData): SatoriNode;
144
+ type TalkData = BaseData & {
142
145
  event?: string | undefined;
143
146
  year?: string | number | undefined;
144
147
  location?: string | undefined;
145
148
  summary?: string | undefined;
146
149
  pose?: Pose | undefined;
147
150
  };
148
- /** Charla · eyebrow en bioluz con evento y año, pose sangrando por la esquina. */
149
- declare function plantillaCharla(datos: DatosCharla): NodoSatori;
150
- type DatosDefecto = Omit<DatosBase, 'title'> & {
151
- /** El nombre. Por defecto, el wordmark. */
151
+ /** Talk · eyebrow in biolume with the event and year, pose bleeding off the corner. */
152
+ declare function talkTemplate(data: TalkData): SatoriNode;
153
+ type DefaultData = Omit<BaseData, 'title'> & {
154
+ /** The name. The wordmark by default. */
152
155
  title?: string | undefined;
153
156
  description?: string | undefined;
154
157
  };
155
158
  /**
156
- * Por defecto · la excepción declarada del documento.
159
+ * Default · the document's declared exception.
157
160
  *
158
- * Retícula propia de dos columnas: la aleta en bioluz a 200 con halo, divisor en
159
- * x=290 y Geist 72/700 y 28/400 — NO la display. No comparte casco con las otras
160
- * tres porque el documento dice que la define el generador, no la tabla.
161
+ * A two-column grid of its own: the fin in biolume at 200 with a halo, a divider
162
+ * at x=290 and Geist 72/700 and 28/400 — NOT the display face. It does not share
163
+ * the shell with the other three because the document says the generator defines
164
+ * it, not the table.
161
165
  */
162
- declare function plantillaDefecto(datos?: DatosDefecto): NodoSatori;
166
+ declare function defaultTemplate(data?: DefaultData): SatoriNode;
163
167
 
164
- export { type DatosArticulo, type DatosBase, type DatosCharla, type DatosCurso, type DatosDefecto, type NodoSatori, OG, plantillaArticulo, tarjeta as plantillaBase, plantillaCharla, plantillaCurso, plantillaDefecto };
168
+ export { type ArticleData, type BaseData, type CourseData, type DefaultData, OG, type SatoriNode, type TalkData, articleTemplate, courseTemplate, defaultTemplate, card as plantillaBase, talkTemplate };
@@ -1,164 +1,168 @@
1
- import { C as Cara, P as Pose } from '../catalogo-Du5ID-Hi.js';
1
+ import { F as Face, P as Pose } from '../catalog-D13txprv.js';
2
2
 
3
3
  /**
4
- * Las cuatro plantillas de Open Graph, 1200×630.
4
+ * The four Open Graph templates, 1200×630.
5
5
  *
6
- * NO son componentes de React. Devuelven el árbol de elementos que Satori
7
- * espera —`{ type, props }`— construido solo con tokens y con el catálogo de la
8
- * marca, que es dato puro. Este módulo se puede importar desde un worker, un
9
- * script de build o una función de borde sin montar nada.
6
+ * They are NOT React components. They return the element tree Satori expects —
7
+ * `{ type, props }` — built only from tokens and from the brand catalog, which
8
+ * is pure data. This module can be imported from a worker, a build script or an
9
+ * edge function without mounting anything.
10
10
  *
11
- * Es el caso que justifica la restricción de `src/tokens/`: si un token hubiera
12
- * terminado dependiendo de un componente, este archivo no existiría.
11
+ * It is the case that justifies the `src/tokens/` constraint: if a token had
12
+ * ended up depending on a component, this file would not exist.
13
13
  *
14
- * LA RETÍCULA ES UNA, del documento: eyebrow arriba, titular a la izquierda,
15
- * firma abajo y la mascota anclada a la derecha. Lo único que cambia entre
16
- * plantillas es el fondo y qué pose entra. Por eso no hay cuatro maquetaciones
17
- * aquí: hay una, y tres parámetros.
14
+ * THERE IS ONE GRID, from the document: eyebrow on top, headline on the left,
15
+ * signature at the bottom and the mascot anchored to the right. The only things
16
+ * that change between templates are the background and which pose comes in.
17
+ * Which is why there are not four layouts here: there is one, and three
18
+ * parameters.
18
19
  *
19
- * lienzo 1200×630 · margen 64
20
- * eyebrow mono 20 · tracking 0.12em
21
- * titular display 800 · 58 · máx 3 líneas al 70 % del ancho
22
- * firma mono 21 · con la aleta a 34
23
- * mascota anclada a la derecha · alto máx 430
20
+ * canvas 1200×630 · margin 64
21
+ * eyebrow mono 20 · tracking 0.12em
22
+ * headline display 800 · 58 · max 3 lines at 70 % of the width
23
+ * signature mono 21 · with the fin at 34
24
+ * mascot anchored right · max height 430
24
25
  *
25
- * La de por defecto es la excepción declarada: retícula propia de dos columnas
26
- * con la aleta a 200 y divisor en x=290, y Geist 72/700 y 28/400 en vez de la
27
- * display. Está en el documento como excepción, así que está aquí como función
28
- * aparte y no como un `if` dentro de la común.
26
+ * The default one is the declared exception: a two-column grid of its own with
27
+ * the fin at 200 and a divider at x=290, and Geist 72/700 and 28/400 instead of
28
+ * the display face. It is in the document as an exception, so it is here as a
29
+ * separate function and not as an `if` inside the shared one.
29
30
  *
30
- * LA ALETA NO ES UN PARÁMETRO. El documento avisa de que «es el error más fácil
31
- * de cometer en un generador, porque el fondo es un parámetro»: espuma en las
32
- * tres plantillas oscuras, dos azules en la de curso. Aquí la elige el modo de
33
- * la plantilla, igual que `Isotipo` la elige con `sobre`. No hay forma de pedir
34
- * la combinación mala.
31
+ * THE FIN IS NOT A PARAMETER. The document warns that «it is the easiest
32
+ * mistake to make in a generator, because the background is a parameter»: foam
33
+ * in the three dark templates, two blues in the course one. Here it is chosen by
34
+ * the template's mode, the same way `Isotype` chooses it from `background`.
35
+ * There is no way to ask for the bad combination.
35
36
  *
36
- * El titular se trunca a 3 líneas con elipsis y NUNCA baja de tamaño: un titular
37
- * a 44 y otro a 58 en el mismo feed se ven como dos marcas distintas.
37
+ * The headline truncates to 3 lines with an ellipsis and NEVER shrinks: a
38
+ * headline at 44 and another at 58 in the same feed read as two different
39
+ * brands.
38
40
  *
39
- * Las imágenes llevan `alt=''`. Satori no lo necesita —pinta a SVG—, pero la
40
- * mascota y la aleta SON decorativas aquí: lo que la tarjeta dice es el titular,
41
- * y el `alt` de una OG lo pone el `<meta property="og:image:alt">` de la página.
42
- * Además, la story las monta como `<img>` de verdad y sin `alt` no pasan axe.
41
+ * The images carry `alt=''`. Satori does not need it — it paints to SVG — but
42
+ * the mascot and the fin ARE decorative here: what the card says is the
43
+ * headline, and an OG's `alt` is set by the page's
44
+ * `<meta property="og:image:alt">`. On top of that, the story mounts them as
45
+ * real `<img>` elements and without `alt` they do not pass axe.
43
46
  *
44
- * Uso:
47
+ * Usage:
45
48
  *
46
49
  * import satori from 'satori';
47
- * import { plantillaArticulo, OG } from '@eduardoalvarez/arrecife/og';
50
+ * import { articleTemplate, OG } from '@eduardoalvarez/arrecife/og';
48
51
  *
49
- * const svg = await satori(plantillaArticulo({ title, category, readingMinutes }), {
52
+ * const svg = await satori(articleTemplate({ title, category, readingMinutes }), {
50
53
  * width: OG.width,
51
54
  * height: OG.height,
52
55
  * fonts: [...],
53
56
  * });
54
57
  */
55
58
 
56
- type NodoSatori = {
59
+ type SatoriNode = {
57
60
  type: string;
58
61
  props: Record<string, unknown> & {
59
62
  style?: Record<string, string | number>;
60
- children?: Hijo | readonly Hijo[];
63
+ children?: Child | readonly Child[];
61
64
  };
62
65
  };
63
- type Hijo = NodoSatori | string | null | undefined | false;
64
- /** El lienzo y la retícula. Son las medidas de producción. */
66
+ type Child = SatoriNode | string | null | undefined | false;
67
+ /** The canvas and the grid. These are the production measurements. */
65
68
  declare const OG: {
66
69
  readonly width: 1200;
67
70
  readonly height: 630;
68
- readonly margen: 64;
69
- /** Alto máximo de la mascota. */
70
- readonly mascota: 430;
71
- /** La aleta de la firma. */
72
- readonly aletaFirma: 34;
71
+ readonly margin: 64;
72
+ /** The mascot's maximum height. */
73
+ readonly mascot: 430;
74
+ /** The signature's fin. */
75
+ readonly signatureFin: 34;
73
76
  /**
74
- * Hueco que deja la columna cuando la pose va a la izquierda (curso).
77
+ * The gap the column leaves when the pose goes on the left (course).
75
78
  *
76
- * Son 560 y no 420 porque una pose completa a 430 de alto mide ~534 de ancho:
77
- * con el hueco justo, el tiburón se comía el titular. La reserva se mide por
78
- * el ancho real de la pose, no por el margen.
79
+ * It is 560 and not 420 because a full pose at 430 tall measures ~534 wide:
80
+ * with the exact gap, the shark ate into the headline. The reserve is measured
81
+ * by the pose's real width, not by the margin.
79
82
  */
80
- readonly reservaMascota: 560;
83
+ readonly mascotReserve: 560;
81
84
  };
82
- type DatosBase = {
85
+ type BaseData = {
83
86
  title: string;
84
87
  /**
85
- * Dónde se sirven los PNG. Satori no lee del disco: en un worker esto tiene
86
- * que ser una URL absoluta o un `data:` URI.
88
+ * Where the PNGs are served from. Satori does not read from disk: in a worker
89
+ * this has to be an absolute URL or a `data:` URI.
87
90
  */
88
91
  basePath?: string | undefined;
89
92
  };
90
93
  /**
91
- * La retícula compartida. Tres de las cuatro plantillas son esto con otro fondo
92
- * y otra pieza de mascota.
94
+ * The shared grid. Three of the four templates are this with a different
95
+ * background and a different mascot piece.
93
96
  */
94
- declare function tarjeta(opciones: {
95
- modo: 'oscuro' | 'claro';
96
- fondo: string;
97
+ declare function card(options: {
98
+ mode: 'dark' | 'light';
99
+ background: string;
97
100
  eyebrow: {
98
- texto: string;
101
+ text: string;
99
102
  color: string;
100
103
  };
101
104
  title: string;
102
- /** Línea bajo el titular, opcional. */
105
+ /** A line under the headline, optional. */
103
106
  bajada?: string | undefined;
104
- firma: string;
107
+ signature: string;
105
108
  firmaColor: string;
106
109
  base: string;
107
- /** La pieza de la derecha, ya montada. */
108
- mascota?: NodoSatori | null | undefined;
109
- /** `curso` la pone a la izquierda: es la única que invierte la retícula. */
110
+ /** The right-hand piece, already assembled. */
111
+ mascot?: SatoriNode | null | undefined;
112
+ /** `curso` puts it on the left: it is the only one that inverts the grid. */
110
113
  mascotaIzquierda?: boolean | undefined;
111
114
  tinta: string;
112
115
  tintaSecundaria: string;
113
- }): NodoSatori;
114
- type DatosArticulo = DatosBase & {
115
- /** El slug de la categoría. Va en arena, en versalitas. */
116
+ }): SatoriNode;
117
+ type ArticleData = BaseData & {
118
+ /** The category slug. It goes in sand, in small caps. */
116
119
  category?: string | undefined;
117
120
  readingMinutes?: number | undefined;
118
121
  /**
119
- * La cara, «según el tono del texto». No hay defecto pensado como neutro:
120
- * `hearts` es la que el manual asigna al OG de artículo.
122
+ * The face, «according to the text's tone». There is no default meant as
123
+ * neutral: `hearts` is the one the manual assigns to the article OG.
121
124
  */
122
- expresion?: Cara | undefined;
125
+ expression?: Face | undefined;
123
126
  };
124
- /** Artículo · degradado 145° sobre abismo, categoría y lectura en arena. */
125
- declare function plantillaArticulo(datos: DatosArticulo): NodoSatori;
126
- type DatosCurso = DatosBase & {
127
+ /** Article · 145° gradient over abyss, category and reading time in sand. */
128
+ declare function articleTemplate(data: ArticleData): SatoriNode;
129
+ type CourseData = BaseData & {
127
130
  modules?: number | undefined;
128
131
  duration?: string | undefined;
129
- /** El dominio del pie. Por defecto, el subdominio de cursos. */
132
+ /** The footer's domain. The courses subdomain by default. */
130
133
  url?: string | undefined;
131
134
  pose?: Pose | undefined;
132
135
  };
133
136
  /**
134
- * Curso · LA ÚNICA PLANTILLA EN CLARO.
137
+ * Course · THE ONLY LIGHT TEMPLATE.
135
138
  *
136
- * Pose completa a la izquierda —invierte la retícula—, eyebrow y URL en arena
137
- * oscura, y por tanto la aleta a dos azules. Esa última parte no se decide aquí:
138
- * sale de que el modo es claro.
139
+ * Full pose on the left — it inverts the grid — eyebrow and URL in dark sand,
140
+ * and therefore the two-blue fin. That last part is not decided here: it follows
141
+ * from the mode being light.
139
142
  */
140
- declare function plantillaCurso(datos: DatosCurso): NodoSatori;
141
- type DatosCharla = DatosBase & {
143
+ declare function courseTemplate(data: CourseData): SatoriNode;
144
+ type TalkData = BaseData & {
142
145
  event?: string | undefined;
143
146
  year?: string | number | undefined;
144
147
  location?: string | undefined;
145
148
  summary?: string | undefined;
146
149
  pose?: Pose | undefined;
147
150
  };
148
- /** Charla · eyebrow en bioluz con evento y año, pose sangrando por la esquina. */
149
- declare function plantillaCharla(datos: DatosCharla): NodoSatori;
150
- type DatosDefecto = Omit<DatosBase, 'title'> & {
151
- /** El nombre. Por defecto, el wordmark. */
151
+ /** Talk · eyebrow in biolume with the event and year, pose bleeding off the corner. */
152
+ declare function talkTemplate(data: TalkData): SatoriNode;
153
+ type DefaultData = Omit<BaseData, 'title'> & {
154
+ /** The name. The wordmark by default. */
152
155
  title?: string | undefined;
153
156
  description?: string | undefined;
154
157
  };
155
158
  /**
156
- * Por defecto · la excepción declarada del documento.
159
+ * Default · the document's declared exception.
157
160
  *
158
- * Retícula propia de dos columnas: la aleta en bioluz a 200 con halo, divisor en
159
- * x=290 y Geist 72/700 y 28/400 — NO la display. No comparte casco con las otras
160
- * tres porque el documento dice que la define el generador, no la tabla.
161
+ * A two-column grid of its own: the fin in biolume at 200 with a halo, a divider
162
+ * at x=290 and Geist 72/700 and 28/400 — NOT the display face. It does not share
163
+ * the shell with the other three because the document says the generator defines
164
+ * it, not the table.
161
165
  */
162
- declare function plantillaDefecto(datos?: DatosDefecto): NodoSatori;
166
+ declare function defaultTemplate(data?: DefaultData): SatoriNode;
163
167
 
164
- export { type DatosArticulo, type DatosBase, type DatosCharla, type DatosCurso, type DatosDefecto, type NodoSatori, OG, plantillaArticulo, tarjeta as plantillaBase, plantillaCharla, plantillaCurso, plantillaDefecto };
168
+ export { type ArticleData, type BaseData, type CourseData, type DefaultData, OG, type SatoriNode, type TalkData, articleTemplate, courseTemplate, defaultTemplate, card as plantillaBase, talkTemplate };