@lit-roa/custom-footer 0.1.8 → 0.1.10

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.
@@ -6,6 +6,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
6
6
  };
7
7
  import { LitElement, css, html, nothing } from 'lit';
8
8
  import { customElement, property, state } from 'lit/decorators.js';
9
+ import { logoMercadoPago } from './mercado-pago-logo.js';
9
10
  import { emitir, estilosBase, iconoBrandFacebook, iconoBrandInstagram, iconoBrandLinkedin, iconoBrandPinterest, iconoBrandTelegram, iconoBrandTiktok, iconoBrandWhatsapp, iconoBrandX, iconoBrandYoutube, iconoChevronDown, iconoClock, iconoMail, iconoMapPin, iconoPhone, tokens, } from '@lit-roa/base';
10
11
  const iconosRedes = {
11
12
  facebook: { icono: iconoBrandFacebook, nombre: 'Facebook' },
@@ -18,16 +19,19 @@ const iconosRedes = {
18
19
  pinterest: { icono: iconoBrandPinterest, nombre: 'Pinterest' },
19
20
  telegram: { icono: iconoBrandTelegram, nombre: 'Telegram' },
20
21
  };
21
- // TODO: cambiar por el SVG oficial del kit de marca de Mercado Pago.
22
- const mercadoPagoLogo = new URL('./mercado-pago.svg', import.meta.url).href;
23
22
  const metodosPago = {
24
23
  visa: { nombre: 'Visa', contenido: html `VISA` },
25
24
  mastercard: { nombre: 'Mastercard', contenido: html `<i></i><i></i>` },
26
25
  amex: { nombre: 'American Express', contenido: html `AMEX` },
27
- 'mercado-pago': { nombre: 'Mercado Pago', contenido: html `<img src=${mercadoPagoLogo}>` },
26
+ 'mercado-pago': { nombre: 'Mercado Pago', contenido: html `<img src=${logoMercadoPago} alt="" />` },
28
27
  };
29
- /** Ancho (px) por debajo del cual el footer pasa a una columna con acordeones. */
30
- const ANCHO_ESTRECHO = 640;
28
+ /**
29
+ * Ancho de la ventana (px) desde el cual el footer pasa a una columna con
30
+ * acordeones. Se mide con media query, como el CSS: incluye la barra de
31
+ * desplazamiento (medir el componente la restaba y el cambio llegaba ~15 px tarde).
32
+ */
33
+ const ANCHO_ESTRECHO = 700;
34
+ const CONSULTA_ESTRECHO = `(max-width: ${ANCHO_ESTRECHO}px)`;
31
35
  /**
32
36
  * Footer genérico y responsive.
33
37
  *
@@ -66,344 +70,363 @@ let LrCustomFooter = class LrCustomFooter extends LitElement {
66
70
  this.estrecho = false;
67
71
  this.abiertos = new Set();
68
72
  this.conBoletin = false;
73
+ this.alCambiarAncho = () => {
74
+ this.estrecho = this.consulta?.matches ?? false;
75
+ };
69
76
  }
70
77
  static { this.styles = [
71
78
  tokens,
72
79
  estilosBase,
73
- css `
74
- :host {
75
- display: block;
76
- --_f-fondo: var(--lr-footer-fondo, #1c1917);
77
- --_f-fondo-alterno: var(--lr-footer-fondo-alterno, rgb(255 255 255 / 0.04));
78
- --_f-texto: var(--lr-footer-texto, #e7e5e4);
79
- --_f-titulos: var(--lr-footer-titulos, #ffffff);
80
- --_f-texto-suave: var(--lr-footer-texto-suave, #a8a29e);
81
- --_f-borde: var(--lr-footer-borde, #3a3431);
82
- --_f-ancho: var(--lr-footer-ancho-maximo, 1160px);
83
- }
84
- footer {
85
- background: var(--_f-fondo);
86
- color: var(--_f-texto);
87
- font-size: 0.875rem;
88
- }
89
- .cont {
90
- max-width: var(--_f-ancho);
91
- margin: 0 auto;
92
- padding: 3rem 2rem 0;
93
- }
94
- a {
95
- color: inherit;
96
- }
97
- a:focus-visible,
98
- button:focus-visible {
99
- outline: 2px solid var(--_color-primario);
100
- outline-offset: 2px;
101
- border-radius: 4px;
102
- }
103
- svg {
104
- flex: none;
105
- }
106
-
107
- .boletin {
108
- margin-bottom: 2.75rem;
109
- }
110
- .boletin[hidden] {
111
- display: none;
112
- }
113
-
114
- .rejilla {
115
- display: grid;
116
- grid-template-columns: 1.5fr repeat(var(--_grupos, 3), 1fr) 1.3fr;
117
- gap: 2rem;
118
- }
119
-
120
- .logo {
121
- display: inline-flex;
122
- align-items: center;
123
- gap: 0.625rem;
124
- font-size: 1.375rem;
125
- font-weight: 600;
126
- color: var(--_f-titulos);
127
- text-decoration: none;
128
- }
129
- .logo img {
130
- display: block;
131
- max-height: var(--lr-footer-alto-logo, 44px);
132
- max-width: 200px;
133
- object-fit: contain;
134
- }
135
- .descripcion {
136
- color: var(--_f-texto-suave);
137
- line-height: 1.6;
138
- margin: 1rem 0 1.25rem;
139
- max-width: 300px;
140
- }
141
- .redes {
142
- display: flex;
143
- flex-wrap: wrap;
144
- gap: 0.5rem;
145
- margin: 0;
146
- padding: 0;
147
- list-style: none;
148
- }
149
- .redes a {
150
- display: grid;
151
- place-items: center;
152
- width: 38px;
153
- height: 38px;
154
- border-radius: 999px;
155
- border: 1px solid var(--_f-borde);
156
- font-size: 1.25rem;
157
- transition: background 0.15s, border-color 0.15s;
158
- }
159
- .redes a:hover {
160
- background: var(--_color-primario);
161
- border-color: var(--_color-primario);
162
- color: var(--_color-sobre-primario);
163
- }
164
-
165
- .titulo {
166
- margin: 0 0 0.875rem;
167
- font-size: 0.9375rem;
168
- font-weight: 600;
169
- color: var(--_f-titulos);
170
- }
171
- .titulo button {
172
- all: unset;
173
- box-sizing: border-box;
174
- display: flex;
175
- width: 100%;
176
- justify-content: space-between;
177
- align-items: center;
178
- padding: 1rem 0.125rem;
179
- cursor: pointer;
180
- }
181
- .titulo button svg {
182
- color: var(--_f-texto-suave);
183
- font-size: 1.125rem;
184
- transition: transform 0.2s;
185
- }
186
- .titulo button[aria-expanded='true'] svg {
187
- transform: rotate(180deg);
188
- }
189
- .enlaces {
190
- list-style: none;
191
- margin: 0;
192
- padding: 0;
193
- display: grid;
194
- gap: 0.625rem;
195
- }
196
- .enlaces a {
197
- color: var(--_f-texto-suave);
198
- text-decoration: none;
199
- }
200
- .enlaces a:hover {
201
- color: var(--_f-texto);
202
- text-decoration: underline;
203
- text-underline-offset: 3px;
204
- }
205
-
206
- .dato {
207
- display: flex;
208
- gap: 0.625rem;
209
- color: var(--_f-texto-suave);
210
- margin: 0 0 0.75rem;
211
- line-height: 1.45;
212
- font-style: normal;
213
- }
214
- .dato svg {
215
- color: var(--_color-primario);
216
- font-size: 1.125rem;
217
- margin-top: 1px;
218
- }
219
- .dato a {
220
- text-decoration: none;
221
- }
222
- .dato a:hover {
223
- text-decoration: underline;
224
- }
225
-
226
- .pie {
227
- display: flex;
228
- justify-content: space-between;
229
- align-items: center;
230
- flex-wrap: wrap;
231
- gap: 1rem;
232
- border-top: 1px solid var(--_f-borde);
233
- margin-top: 2.75rem;
234
- padding: 1.375rem 0 1.625rem;
235
- color: var(--_f-texto-suave);
236
- font-size: 0.8125rem;
237
- }
238
- .derechos {
239
- display: flex;
240
- flex-wrap: wrap;
241
- gap: 0.5rem 1rem;
242
- align-items: center;
243
- }
244
- .pagos {
245
- display: flex;
246
- gap: 0.375rem;
247
- flex-wrap: wrap;
248
- margin: 0;
249
- padding: 0;
250
- list-style: none;
251
- }
252
- .pago {
253
- height: 26px;
254
- min-width: 44px;
255
- padding: 0 0.5rem;
256
- border-radius: 5px;
257
- background: #fff;
258
- display: inline-flex;
259
- align-items: center;
260
- justify-content: center;
261
- font-weight: 800;
262
- font-size: 0.6875rem;
263
- }
264
- .pago.visa {
265
- color: #1a1f71;
266
- font-style: italic;
267
- font-size: 0.8125rem;
268
- }
269
- .pago.amex {
270
- background: #2e77bc;
271
- color: #fff;
272
- }
273
- .pago.mastercard i {
274
- width: 15px;
275
- height: 15px;
276
- border-radius: 50%;
277
- background: #eb001b;
278
- }
279
- .pago.mastercard i + i {
280
- background: #f79e1b;
281
- margin-left: -6px;
282
- opacity: 0.9;
283
- }
284
- .pago.mercado-pago {
285
- gap: 5px;
286
- padding: 2px;
287
- color: #0a0a6b;
288
- font-weight: 700;
289
- font-size: 8.5px;
290
- line-height: 1;
291
- text-align: left;
292
- min-width: 94px;
293
- }
294
-
295
- /* Celular o contenedor angosto */
296
- .estrecho .cont {
297
- padding: 2rem 1rem 0;
298
- }
299
- .estrecho .boletin {
300
- margin-bottom: 1.75rem;
301
- }
302
- .estrecho .rejilla {
303
- grid-template-columns: 1fr;
304
- gap: 0;
305
- }
306
- .estrecho .marca {
307
- text-align: center;
308
- padding-bottom: 1.5rem;
309
- }
310
- .estrecho .descripcion {
311
- margin: 0.875rem auto 1.125rem;
312
- }
313
- .estrecho .redes {
314
- justify-content: center;
315
- }
316
- .estrecho .grupo {
317
- border-top: 1px solid var(--_f-borde);
318
- }
319
- .estrecho .grupo .titulo {
320
- margin: 0;
321
- }
322
- .estrecho .enlaces {
323
- padding: 0 0.125rem 1rem;
324
- }
325
- .estrecho .enlaces[hidden] {
326
- display: none;
327
- }
328
- .estrecho .contacto {
329
- border-top: 1px solid var(--_f-borde);
330
- padding-top: 1.25rem;
331
- }
332
- .estrecho .pie {
333
- flex-direction: column;
334
- text-align: center;
335
- margin-top: 1.5rem;
336
- }
337
- .estrecho .derechos,
338
- .estrecho .pagos {
339
- justify-content: center;
340
- }
80
+ css `
81
+ :host {
82
+ display: block;
83
+ --_f-fondo: var(--lr-footer-fondo, #1c1917);
84
+ --_f-fondo-alterno: var(--lr-footer-fondo-alterno, rgb(255 255 255 / 0.04));
85
+ --_f-texto: var(--lr-footer-texto, #e7e5e4);
86
+ --_f-titulos: var(--lr-footer-titulos, #ffffff);
87
+ --_f-texto-suave: var(--lr-footer-texto-suave, #a8a29e);
88
+ --_f-borde: var(--lr-footer-borde, #3a3431);
89
+ --_f-ancho: var(--lr-footer-ancho-maximo, 1160px);
90
+ }
91
+ footer {
92
+ background: var(--_f-fondo);
93
+ color: var(--_f-texto);
94
+ font-size: 0.875rem;
95
+ }
96
+ .cont {
97
+ max-width: var(--_f-ancho);
98
+ margin: 0 auto;
99
+ padding: 3rem 2rem 0;
100
+ }
101
+ a {
102
+ color: inherit;
103
+ }
104
+ a:focus-visible,
105
+ button:focus-visible {
106
+ outline: 2px solid var(--_color-primario);
107
+ outline-offset: 2px;
108
+ border-radius: 4px;
109
+ }
110
+ svg {
111
+ flex: none;
112
+ }
113
+
114
+ .boletin {
115
+ margin-bottom: 2.75rem;
116
+ }
117
+ .boletin[hidden] {
118
+ display: none;
119
+ }
120
+
121
+ .rejilla {
122
+ display: grid;
123
+ /* Contacto con mínimo fijo: un correo largo se parte en vez de ensanchar */
124
+ grid-template-columns: 1.5fr repeat(var(--_grupos, 3), 1fr) minmax(9rem, 1.3fr);
125
+ gap: 2rem;
126
+ }
127
+
128
+ .logo {
129
+ display: inline-flex;
130
+ align-items: center;
131
+ gap: 0.625rem;
132
+ font-size: 1.375rem;
133
+ font-weight: 600;
134
+ color: var(--_f-titulos);
135
+ text-decoration: none;
136
+ }
137
+ .logo img {
138
+ display: block;
139
+ max-height: var(--lr-footer-alto-logo, 44px);
140
+ max-width: 200px;
141
+ object-fit: contain;
142
+ }
143
+ .descripcion {
144
+ color: var(--_f-texto-suave);
145
+ line-height: 1.6;
146
+ margin: 1rem 0 1.25rem;
147
+ max-width: 300px;
148
+ }
149
+ .redes {
150
+ display: flex;
151
+ flex-wrap: wrap;
152
+ gap: 0.5rem;
153
+ margin: 0;
154
+ padding: 0;
155
+ list-style: none;
156
+ }
157
+ .redes a {
158
+ display: grid;
159
+ place-items: center;
160
+ width: 38px;
161
+ height: 38px;
162
+ border-radius: 999px;
163
+ border: 1px solid var(--_f-borde);
164
+ font-size: 1.25rem;
165
+ transition: background 0.15s, border-color 0.15s;
166
+ }
167
+ .redes a:hover {
168
+ background: var(--_color-primario);
169
+ border-color: var(--_color-primario);
170
+ color: var(--_color-sobre-primario);
171
+ }
172
+
173
+ .titulo {
174
+ margin: 0 0 0.875rem;
175
+ font-size: 0.9375rem;
176
+ font-weight: 600;
177
+ color: var(--_f-titulos);
178
+ }
179
+ .titulo button {
180
+ all: unset;
181
+ box-sizing: border-box;
182
+ display: flex;
183
+ width: 100%;
184
+ justify-content: space-between;
185
+ align-items: center;
186
+ padding: 1rem 0.125rem;
187
+ cursor: pointer;
188
+ }
189
+ .titulo button svg {
190
+ color: var(--_f-texto-suave);
191
+ font-size: 1.125rem;
192
+ transition: transform 0.2s;
193
+ }
194
+ .titulo button[aria-expanded='true'] svg {
195
+ transform: rotate(180deg);
196
+ }
197
+ .enlaces {
198
+ list-style: none;
199
+ margin: 0;
200
+ padding: 0;
201
+ display: grid;
202
+ gap: 0.625rem;
203
+ }
204
+ .enlaces a {
205
+ color: var(--_f-texto-suave);
206
+ text-decoration: none;
207
+ }
208
+ .enlaces a:hover {
209
+ color: var(--_f-texto);
210
+ text-decoration: underline;
211
+ text-underline-offset: 3px;
212
+ }
213
+
214
+ .dato {
215
+ display: flex;
216
+ gap: 0.625rem;
217
+ color: var(--_f-texto-suave);
218
+ margin: 0 0 0.75rem;
219
+ line-height: 1.45;
220
+ font-style: normal;
221
+ }
222
+ .dato svg {
223
+ color: var(--_color-primario);
224
+ font-size: 1.125rem;
225
+ margin-top: 1px;
226
+ }
227
+ .dato > span,
228
+ .dato > a {
229
+ min-width: 0;
230
+ /* Correos y direcciones largas parten la línea en vez de desbordar */
231
+ overflow-wrap: anywhere;
232
+ }
233
+ .dato a {
234
+ text-decoration: none;
235
+ }
236
+ .dato a:hover {
237
+ text-decoration: underline;
238
+ }
239
+
240
+ .pie {
241
+ display: flex;
242
+ justify-content: space-between;
243
+ align-items: center;
244
+ flex-wrap: wrap;
245
+ gap: 1rem;
246
+ border-top: 1px solid var(--_f-borde);
247
+ margin-top: 2.75rem;
248
+ padding: 1.375rem 0 1.625rem;
249
+ color: var(--_f-texto-suave);
250
+ font-size: 0.8125rem;
251
+ }
252
+ .derechos {
253
+ display: flex;
254
+ flex-wrap: wrap;
255
+ gap: 0.5rem 1rem;
256
+ align-items: center;
257
+ }
258
+ .pagos {
259
+ display: flex;
260
+ gap: 0.375rem;
261
+ flex-wrap: wrap;
262
+ margin: 0;
263
+ padding: 0;
264
+ list-style: none;
265
+ }
266
+ .pago {
267
+ height: 26px;
268
+ min-width: 44px;
269
+ padding: 0 0.5rem;
270
+ border-radius: 5px;
271
+ background: #fff;
272
+ display: inline-flex;
273
+ align-items: center;
274
+ justify-content: center;
275
+ font-weight: 800;
276
+ font-size: 0.6875rem;
277
+ }
278
+ .pago.visa {
279
+ color: #1a1f71;
280
+ font-style: italic;
281
+ font-size: 0.8125rem;
282
+ }
283
+ .pago.amex {
284
+ background: #2e77bc;
285
+ color: #fff;
286
+ }
287
+ .pago.mastercard i {
288
+ width: 15px;
289
+ height: 15px;
290
+ border-radius: 50%;
291
+ background: #eb001b;
292
+ }
293
+ .pago.mastercard i + i {
294
+ background: #f79e1b;
295
+ margin-left: -6px;
296
+ opacity: 0.9;
297
+ }
298
+ .pago.mercado-pago {
299
+ gap: 5px;
300
+ padding: 2px;
301
+ color: #0a0a6b;
302
+ font-weight: 700;
303
+ font-size: 8.5px;
304
+ line-height: 1;
305
+ text-align: left;
306
+ min-width: 94px;
307
+ }
308
+
309
+ /* Tableta: la marca ocupa su propia fila y deja espacio a las columnas */
310
+ @media (max-width: 960px) {
311
+ .rejilla {
312
+ grid-template-columns: repeat(var(--_grupos, 3), minmax(0, 1fr)) minmax(9rem, 1.3fr);
313
+ }
314
+ .marca {
315
+ grid-column: 1 / -1;
316
+ }
317
+ }
318
+
319
+ /* Celular */
320
+ .estrecho .cont {
321
+ padding: 2rem 1rem 0;
322
+ }
323
+ .estrecho .boletin {
324
+ margin-bottom: 1.75rem;
325
+ }
326
+ .estrecho .rejilla {
327
+ grid-template-columns: minmax(0, 1fr);
328
+ gap: 0;
329
+ }
330
+ .estrecho .marca {
331
+ text-align: center;
332
+ padding-bottom: 1.5rem;
333
+ }
334
+ .estrecho .descripcion {
335
+ margin: 0.875rem auto 1.125rem;
336
+ }
337
+ .estrecho .redes {
338
+ justify-content: center;
339
+ }
340
+ .estrecho .grupo {
341
+ border-top: 1px solid var(--_f-borde);
342
+ }
343
+ .estrecho .grupo .titulo {
344
+ margin: 0;
345
+ }
346
+ .estrecho .enlaces {
347
+ padding: 0 0.125rem 1rem;
348
+ }
349
+ .estrecho .enlaces[hidden] {
350
+ display: none;
351
+ }
352
+ .estrecho .contacto {
353
+ border-top: 1px solid var(--_f-borde);
354
+ padding-top: 1.25rem;
355
+ }
356
+ .estrecho .pie {
357
+ flex-direction: column;
358
+ text-align: center;
359
+ margin-top: 1.5rem;
360
+ }
361
+ .estrecho .derechos,
362
+ .estrecho .pagos {
363
+ justify-content: center;
364
+ }
341
365
  `,
342
366
  ]; }
343
367
  connectedCallback() {
344
368
  super.connectedCallback();
345
- this.observador = new ResizeObserver(([entrada]) => {
346
- this.estrecho = entrada.contentRect.width < ANCHO_ESTRECHO;
347
- });
348
- this.observador.observe(this);
369
+ this.consulta = window.matchMedia(CONSULTA_ESTRECHO);
370
+ this.consulta.addEventListener('change', this.alCambiarAncho);
371
+ this.alCambiarAncho();
349
372
  }
350
373
  disconnectedCallback() {
351
374
  super.disconnectedCallback();
352
- this.observador?.disconnect();
375
+ this.consulta?.removeEventListener('change', this.alCambiarAncho);
353
376
  }
354
377
  render() {
355
378
  const { direccion, telefono, correo, horario } = this.contacto;
356
379
  const conContacto = Boolean(direccion || telefono || correo || horario);
357
380
  const derechos = this.textoDerechos || `${this.nombre}. Todos los derechos reservados.`;
358
- return html `
359
- <footer class=${this.estrecho ? 'estrecho' : ''}>
360
- <div class="cont">
361
- <div class="boletin" ?hidden=${!this.conBoletin}>
362
- <slot name="boletin" @slotchange=${this.revisarBoletin}></slot>
363
- </div>
364
-
365
- <div class="rejilla" style="--_grupos: ${this.grupos.length}">
366
- <div class="marca">
367
- ${this.renderLogo()}
368
- ${this.descripcion ? html `<p class="descripcion">${this.descripcion}</p>` : nothing}
381
+ return html `
382
+ <footer class=${this.estrecho ? 'estrecho' : ''}>
383
+ <div class="cont">
384
+ <div class="boletin" ?hidden=${!this.conBoletin}>
385
+ <slot name="boletin" @slotchange=${this.revisarBoletin}></slot>
386
+ </div>
387
+
388
+ <div class="rejilla" style="--_grupos: ${this.grupos.length}">
389
+ <div class="marca">
390
+ ${this.renderLogo()}
391
+ ${this.descripcion ? html `<p class="descripcion">${this.descripcion}</p>` : nothing}
369
392
  ${this.redes.length
370
- ? html `<ul class="redes">
371
- ${this.redes.map((r) => this.renderRed(r))}
393
+ ? html `<ul class="redes">
394
+ ${this.redes.map((r) => this.renderRed(r))}
372
395
  </ul>`
373
- : nothing}
374
- </div>
375
-
376
- ${this.grupos.map((g, i) => this.renderGrupo(g, i))}
377
-
378
- <div class="contacto">
379
- ${conContacto ? html `<h2 class="titulo">${this.tituloContacto}</h2>` : nothing}
380
- <address>
381
- ${direccion ? html `<p class="dato">${iconoMapPin}<span>${direccion}</span></p>` : nothing}
396
+ : nothing}
397
+ </div>
398
+
399
+ ${this.grupos.map((g, i) => this.renderGrupo(g, i))}
400
+
401
+ <div class="contacto">
402
+ ${conContacto ? html `<h2 class="titulo">${this.tituloContacto}</h2>` : nothing}
403
+ <address>
404
+ ${direccion ? html `<p class="dato">${iconoMapPin}<span>${direccion}</span></p>` : nothing}
382
405
  ${telefono
383
- ? html `<p class="dato">
384
- ${iconoPhone}<a href="tel:${telefono.replace(/[^\d+]/g, '')}">${telefono}</a>
406
+ ? html `<p class="dato">
407
+ ${iconoPhone}<a href="tel:${telefono.replace(/[^\d+]/g, '')}">${telefono}</a>
385
408
  </p>`
386
- : nothing}
387
- ${correo ? html `<p class="dato">${iconoMail}<a href="mailto:${correo}">${correo}</a></p>` : nothing}
388
- ${horario ? html `<p class="dato">${iconoClock}<span>${horario}</span></p>` : nothing}
389
- </address>
390
- <slot name="extra"></slot>
391
- </div>
392
- </div>
393
-
394
- <div class="pie">
395
- <div class="derechos">
396
- <span>© ${new Date().getFullYear()} ${derechos}</span>
397
- <slot name="pie"></slot>
398
- </div>
409
+ : nothing}
410
+ ${correo ? html `<p class="dato">${iconoMail}<a href="mailto:${correo}">${correo}</a></p>` : nothing}
411
+ ${horario ? html `<p class="dato">${iconoClock}<span>${horario}</span></p>` : nothing}
412
+ </address>
413
+ <slot name="extra"></slot>
414
+ </div>
415
+ </div>
416
+
417
+ <div class="pie">
418
+ <div class="derechos">
419
+ <span>© ${new Date().getFullYear()} ${derechos}</span>
420
+ <slot name="pie"></slot>
421
+ </div>
399
422
  ${this.metodosPago.length
400
- ? html `<ul class="pagos" aria-label="Métodos de pago">
401
- ${this.metodosPago.map((m) => this.renderPago(m))}
423
+ ? html `<ul class="pagos" aria-label="Métodos de pago">
424
+ ${this.metodosPago.map((m) => this.renderPago(m))}
402
425
  </ul>`
403
- : nothing}
404
- </div>
405
- </div>
406
- </footer>
426
+ : nothing}
427
+ </div>
428
+ </div>
429
+ </footer>
407
430
  `;
408
431
  }
409
432
  renderLogo() {
@@ -413,48 +436,48 @@ let LrCustomFooter = class LrCustomFooter extends LitElement {
413
436
  ? html `<img src=${this.logo} alt=${this.logoAlt || this.nombre} />`
414
437
  : html `<span>${this.nombre}</span>`;
415
438
  const enlace = { texto: this.nombre, href: this.logoHref, id: 'inicio' };
416
- return html `<a class="logo" href=${this.logoHref} @click=${(e) => this.clic(e, enlace)}>
417
- ${contenido}
439
+ return html `<a class="logo" href=${this.logoHref} @click=${(e) => this.clic(e, enlace)}>
440
+ ${contenido}
418
441
  </a>`;
419
442
  }
420
443
  renderRed({ red, url, etiqueta }) {
421
444
  const datos = iconosRedes[red];
422
445
  if (!datos)
423
446
  return nothing;
424
- return html `<li>
425
- <a href=${url} target="_blank" rel="noopener noreferrer" aria-label=${etiqueta || datos.nombre} title=${etiqueta || datos.nombre}>
426
- ${datos.icono}
427
- </a>
447
+ return html `<li>
448
+ <a href=${url} target="_blank" rel="noopener noreferrer" aria-label=${etiqueta || datos.nombre} title=${etiqueta || datos.nombre}>
449
+ ${datos.icono}
450
+ </a>
428
451
  </li>`;
429
452
  }
430
453
  renderGrupo(grupo, indice) {
431
454
  const abierto = !this.estrecho || this.abiertos.has(indice);
432
455
  const idLista = `grupo-${indice}`;
433
- return html `
434
- <nav class="grupo" aria-label=${grupo.titulo}>
435
- <h2 class="titulo">
456
+ return html `
457
+ <nav class="grupo" aria-label=${grupo.titulo}>
458
+ <h2 class="titulo">
436
459
  ${this.estrecho
437
- ? html `<button aria-expanded=${abierto} aria-controls=${idLista} @click=${() => this.alternar(indice)}>
438
- ${grupo.titulo} ${iconoChevronDown}
460
+ ? html `<button aria-expanded=${abierto} aria-controls=${idLista} @click=${() => this.alternar(indice)}>
461
+ ${grupo.titulo} ${iconoChevronDown}
439
462
  </button>`
440
- : grupo.titulo}
441
- </h2>
442
- <ul class="enlaces" id=${idLista} ?hidden=${!abierto}>
443
- ${grupo.enlaces.map((enlace) => html `<li>
444
- <a href=${enlace.href || '#'} @click=${(e) => this.clic(e, enlace, grupo.titulo)}>
445
- ${enlace.texto}
446
- </a>
447
- </li>`)}
448
- </ul>
449
- </nav>
463
+ : grupo.titulo}
464
+ </h2>
465
+ <ul class="enlaces" id=${idLista} ?hidden=${!abierto}>
466
+ ${grupo.enlaces.map((enlace) => html `<li>
467
+ <a href=${enlace.href || '#'} @click=${(e) => this.clic(e, enlace, grupo.titulo)}>
468
+ ${enlace.texto}
469
+ </a>
470
+ </li>`)}
471
+ </ul>
472
+ </nav>
450
473
  `;
451
474
  }
452
475
  renderPago(metodo) {
453
476
  const datos = metodosPago[metodo];
454
477
  if (!datos)
455
478
  return nothing;
456
- return html `<li class="pago ${metodo}" role="img" aria-label=${datos.nombre} title=${datos.nombre}>
457
- ${datos.contenido}
479
+ return html `<li class="pago ${metodo}" role="img" aria-label=${datos.nombre} title=${datos.nombre}>
480
+ ${datos.contenido}
458
481
  </li>`;
459
482
  }
460
483
  alternar(indice) {