Welcome to your new Jekyll theme! In this directory, you'll find the files you need to be able to package up your theme into a gem. Put your layouts in _layouts, your includes in _includes, your sass files in _sass and any other assets in assets.
To experiment with this code, add some sample content and run bundle exec jekyll serve – this directory is setup just like a Jekyll site!
TODO: Delete this and the text above, and describe your gem
Con remote_theme: Coderic/jekyll-theme-coderic, Jekyll fusiona el _config.yml del tema. No hace falta jekyll-sitemap: el archivo assets/sitemap.xml del tema (Liquid, permalink: /sitemap.xml) lista cada URL por idioma (site.languages), compatible con jekyll-polyglot. En Jekyll 4 solo se cargan como páginas del tema los archivos bajo assets/ (ThemeAssetsReader). robots.txt (misma plantilla Liquid) va en la raíz de cada portal, no en la gema del tema.
Instalación publicando el tema como gema Ruby: añadí gem "jekyll-theme-coderic" al Gemfile y en _config.yml usá theme: jekyll-theme-coderic. Luego ejecutá bundle (o gem install jekyll-theme-coderic).
No copies _includes/subnav.html en tu sitio salvo necesidad excepcional: Jekyll usará el include del tema (remote_theme / theme). Define el menú solo en YAML.
El include _includes/subnav.html resuelve los datos en este orden:
site.data[<active_lang>].subnav→ archivo_data/<lang>/subnav.yml(p. ej._data/es/subnav.yml).- Si está vacío o ausente:
site.data[<default_lang>].subnav→_data/<default_lang>/subnav.yml. - Si sigue vacío: por defecto no se usa ningún menú empaquetado ni
_data/subnav.ymlraíz (no se pinta subnav hasta tener YAML por idioma). - Solo si en
_config.ymlestáuse_theme_subnav_fallback: true: se asignasite.data.subnav(merge del sitio + datos del tema; útil en demos o sitios que solo definen_data/subnav.ymlraíz).
Configuración útil en _config.yml:
use_theme_subnav_fallback: true: tras los pasos 1–2, si aún no hay ítems, usarsite.data.subnav(incluye demo del tema si no lo anulas con tus propios datos).- Omisión o
false(recomendado en producción con_data/<lang>/subnav.yml): si faltan datos por idioma, el subnav no muestra el menú del tema por defecto.
La clave antigua hide_theme_subnav_fallback ya no tiene efecto; sustituir por use_theme_subnav_fallback con la semántica anterior invertida (opt-in para usar el fallback del tema).
Los enlaces internos del menú pasan por _includes/coderic_i18n_href.html para convivir con jekyll-polyglot.
El conmutador de idioma del subnav usa los tags Liquid static_href / endstatic_href de Polyglot en los enlaces del menú. Los sitios sin Polyglot deben usar otro include o no incluir este bloque tal cual.
_includes/seo_resolve.html: resuelve<title>y meta description parapage.net_page,page.i18n_source,page.i18n, datos porpage.pages_data_keyy seccionesorganization/impact/governance, y fallbacks (page.title,site.portal_name, etc.)._includes/head.html: aplica esa resolución, añaderel="canonical", alternateshreflang(másx-default), meta Open Graph (og:title,og:description,og:url,og:type,og:locale) y Twitter Card (summary). Consite.urlvacío (demo local), se omiten canonical/OG para no emitir URLs rotas.- Compatible con jekyll-polyglot (
site.active_lang). Opcional:site.noindexañade meta robots noindex yrobots.txtconDisallow: /.
assets/sitemap.xml(permalink: /sitemap.xml): recorre colecciones,site.html_pagesy archivos estáticos (.htm/.html/.xhtml/.pdf) como el plugin oficial; para cada recurso HTML emite una entrada por idioma ensite.languages(idioma por defecto conabsolute_url; resto/{lang}{path}), alineado con lashreflangdelhead. Con Polyglot,page.urlen la pasadadefault_langno lleva prefijo; sin duplicar por idioma el sitemap omitía/es/....- El archivo está en
exclude_from_localization: un solo/sitemap.xmlen la raíz del sitio generado, como recomienda Polyglot. - En producción, fijá
url(ybaseurl) en_config.yml. robots.txt: cada portal Coderic lo mantiene en la raíz del repo del sitio (misma plantilla Liquid que antes estaba en el tema):noindex→Disallow: /; si no,Allow: /y líneaSitemap:consite.url+site.baseurl. Mantenerrobots.txtenexclude_from_localizationdel sitio (junto consitemap.xml) para Polyglot.- Por defecto
sitemap: falseen el front matter decallback.html,profile.htmlyhello-world.htmldel tema; en otras páginas usásitemap: falsecuando no deban indexarse. - Google Search Console (“No se ha podido obtener”): revisá en Cloudflare que Bot Fight Mode / reglas WAF no bloqueen Googlebot en
GET /sitemap.xml; en Pages, el archivo_headersen el repo (incluido víaincludeen_config.yml) fijaContent-Typecorrecto. Un sitemap con<loc>vacío (XML inválido) también puede hacer fallar la lectura: la plantilla del tema omite esas entradas.
Referencias: Google Search Central.
Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/jekyll-theme-coderic. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.
To set up your environment to develop this theme, run bundle install.
Your theme is setup just like a normal Jekyll site! To test your theme, run bundle exec jekyll serve and open your browser at http://localhost:4000. This starts a Jekyll server using your theme. Add pages, documents, data, etc. like normal to test your theme's contents. As you make modifications to your theme and to your content, your site will regenerate and you should see the changes in the browser after a refresh, just like normal.
When your theme is released, the files tracked in jekyll-theme-coderic.gemspec are bundled (layouts, includes such as seo_resolve.html, _config.yml, assets/sitemap.xml, páginas raíz OAuth, etc.). Cada portal del ecosistema incluye su propio robots.txt en la raíz del sitio. Edit the regexp in the gemspec if you add new top-level assets to the gem.
Para probar Authorization Code + PKCE contra un servidor OIDC de referencia (mismo flujo que usa el tema con oauth_demo_sign_in: false y /callback/):
- Herramienta: AuthTester (documentación del servicio).
- Descubrimiento OpenID:
/.well-known/openid-configuration— ahí salenauthorization_endpointytoken_endpoint. - En
_config.ymldel tema (valores por defecto del demo) se usanoidc_client_id: "test"y las URLs explícitas de authorize/token del tester, según lo descrito en la página del tool (“no client registration required” para empezar conclient_id=test). - Abrí el sitio con el mismo origen que
urlen_config.yml(p. ej. siurleshttp://localhost:4000, entrá conhttp://localhost:4000, no mezclar con127.0.0.1, porque elredirect_uriysessionStoragedel PKCE deben coincidir).
Si el tester te ofrece una pantalla configure con requestId en la URL (p. ej. …/oauth/authorize/configure?requestId=…), ese ID es por sesión: generalo desde la UI del AuthTester; no lo versiones en el repo.
Si el intercambio de code en el navegador falla por CORS en el token_endpoint, el AS no permite llamadas cross-origin desde el browser: en ese caso haría falta un backend (BFF) que canjee el código; el AuthTester suele estar pensado para pruebas de cliente.
El OAuth 2.0 Playground sirve para flujos guiados con servidor simulado; un flujo Implicit allí no usa el redirect_uri /callback/ de este tema (ver sección Implicit más abajo).
| Campo | Valor |
|---|---|
client_id |
9Jyz5ULUVj0DhodVIypTLAnb |
client_secret |
8ltclob04WAcZ6jrnHQxQgzbxGIWRKBV29ypp-vgB9IQx_dm |
| Usuario (login) | cheerful-peafowl@example.com |
| Contraseña | Successful-Dove-72 |
Registro: Client Registration.
No es el flujo PKCE del tema; solo referencia del playground con authorization-server.com:
https://authorization-server.com/authorize?
response_type=token
&client_id=9Jyz5ULUVj0DhodVIypTLAnb
&redirect_uri=https://www.oauth.com/playground/implicit.html
&scope=photo
&state=<valor-que-asigna-el-playground>
Con PKCE en este tema, el redirect_uri debe ser {origen}/callback/ de tu sitio Jekyll.
The theme is available as open source under the terms of the MIT License.