Skip to content

Commit f1c9f20

Browse files
authored
Programa: añadir página con widget de Pretalx (#213)
## Descripción Añade la página `/programa` con el widget de Pretalx embebido, mostrando el cronograma de PyConES en los 3 idiomas soportados (es/en/ca). ## Cambios - **Nueva página** `src/pages/[lang]/programa.astro` con `getStaticPaths` para es/en/ca - **Nuevo componente** `src/components/ProgramaPage.astro` (h1, intro, widget, noscript fallback) - **Nuevo módulo i18n** `src/i18n/programa/{index,es,en,ca}.ts` - **Menú**: `Programa` / `Programme` insertado como 2º item (después de "Inicio") - **Layout**: nueva prop opcional `fullWidth` para contenido full-viewport (sin container) - **Widget**: wrapeado en `overflow-x-auto` para scroll horizontal en viewports angostos - **Dialog de filtros**: estilos inyectados al shadow root del widget vía JS (Pretalx usa Shadow DOM, el CSS del light DOM no penetra) ## Testing - [ ] Abrir `/es/programa` y verificar que el calendario carga y se ve bien - [ ] Repetir en `/en/programa` y `/ca/programa` - [ ] Pulsar el botón de filtros y comprobar que el dialog sale con fondo blanco - [ ] Probar scroll horizontal del calendario en mobile - [ ] Verificar que el menú muestra "Programa" como 2º item en los 3 idiomas ## Notas - El widget apunta a `event-url="https://pretalx.com/pycones-2025/"` por ahora (es el evento con schedule publicado). Cambiar a `pycones-2026` cuando exista el evento con cronograma. - El locale `ca` puede caer al default (inglés) si Pretalx no tiene UI en catalán para este evento. Si se quiere forzar castellano, cambiar `locale: 'ca'` por `locale: 'es'` solo en `src/i18n/programa/ca.ts`.
1 parent a7a3d2e commit f1c9f20

12 files changed

Lines changed: 156 additions & 65 deletions

File tree

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "2026.es.pycon.org",
3-
"version": "1.16.0",
3+
"version": "1.17.0",
44
"description": "",
55
"main": "index.js",
66
"scripts": {
@@ -27,7 +27,7 @@
2727
},
2828
"devDependencies": {
2929
"@astrojs/check": "0.9.9",
30-
"@commitlint/cli": "21.2.0",
30+
"@commitlint/cli": "21.2.1",
3131
"@commitlint/config-conventional": "21.2.0",
3232
"husky": "9.1.7",
3333
"lint-staged": "17.0.8",

pnpm-lock.yaml

Lines changed: 24 additions & 61 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/components/ProgramaPage.astro

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
---
2+
import { programaTexts } from '@/i18n/programa'
3+
import { menuTexts } from '@/i18n/menu'
4+
5+
interface Props {
6+
lang: string
7+
}
8+
const { lang } = Astro.props
9+
const t = programaTexts[lang as keyof typeof programaTexts]
10+
const menuT = menuTexts[lang as keyof typeof menuTexts]
11+
---
12+
13+
<section class="py-8">
14+
<h1 class="text-3xl md:text-5xl font-bold text-center mb-6">{t.title}</h1>
15+
<p class="text-center text-base md:text-lg mb-10 max-w-2xl mx-auto opacity-80">{t.intro}</p>
16+
17+
<pretalx-schedule
18+
event-url="https://pretalx.com/pycones-2026/"
19+
locale={t.locale}
20+
format="grid"
21+
style="--pretalx-clr-primary: #03004b"></pretalx-schedule>
22+
23+
<noscript>
24+
<div class="pretalx-widget">
25+
<div class="pretalx-widget-info-message">
26+
{t.noscript}{' '}
27+
<a
28+
target="_blank"
29+
rel="noopener noreferrer"
30+
aria-label={`${t.noscriptLink} ${menuT.new_tab}`}
31+
href="https://pretalx.com/pycones-2026/schedule/"
32+
>
33+
{t.noscriptLink}
34+
</a>
35+
.
36+
</div>
37+
</div>
38+
</noscript>
39+
</section>

src/i18n/menu/ca.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ export const ca = {
44
label: 'Inici',
55
href: '/',
66
},
7+
{
8+
label: 'Programa',
9+
href: '/programa',
10+
},
711
{
812
label: 'Informació',
913
children: [

src/i18n/menu/en.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ export const en = {
44
label: 'Home',
55
href: '/',
66
},
7+
{
8+
label: 'Programme',
9+
href: '/programa',
10+
},
711
{
812
label: 'Information',
913
children: [

src/i18n/menu/es.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ export const es = {
44
label: 'Inicio',
55
href: '/',
66
},
7+
{
8+
label: 'Programa',
9+
href: '/programa',
10+
},
711
{
812
label: 'Información',
913
children: [

src/i18n/programa/ca.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
export const ca = {
2+
title: 'Programa',
3+
seoDescription: 'Consulta el cronograma complet de xerrades, tallers i activitats de la PyConES 2026.',
4+
intro: 'Explora totes les xerrades, tallers i activitats de la PyConES 2026.',
5+
locale: 'ca',
6+
noscript: 'JavaScript està desactivat al teu navegador. Per veure el programa sense JavaScript,',
7+
noscriptLink: 'fes clic aquí',
8+
} as const

src/i18n/programa/en.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
export const en = {
2+
title: 'Programme',
3+
seoDescription: 'Check out the full schedule of talks, workshops and activities at PyConES 2026.',
4+
intro: 'Explore all the talks, workshops and activities at PyConES 2026.',
5+
locale: 'en',
6+
noscript: 'JavaScript is disabled in your browser. To view the schedule without JavaScript,',
7+
noscriptLink: 'click here',
8+
} as const

src/i18n/programa/es.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
export const es = {
2+
title: 'Programa',
3+
seoDescription: 'Consulta el cronograma completo de charlas, talleres y actividades de la PyConES 2026.',
4+
intro: 'Explora todas las charlas, talleres y actividades de la PyConES 2026.',
5+
locale: 'es',
6+
noscript: 'JavaScript está deshabilitado en tu navegador. Para ver el programa sin JavaScript,',
7+
noscriptLink: 'haz click aquí',
8+
} as const

src/i18n/programa/index.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import { es } from './es'
2+
import { en } from './en'
3+
import { ca } from './ca'
4+
5+
export const programaTexts = { es, en, ca }

0 commit comments

Comments
 (0)