diff options
| author | Danilo M. <danix@danix.xyz> | 2026-04-29 13:13:30 +0200 |
|---|---|---|
| committer | Danilo M. <danix@danix.xyz> | 2026-04-29 13:13:30 +0200 |
| commit | dc4eba2c6a709995a2f4718f9fb407f3057a13b8 (patch) | |
| tree | 0e5dc3a08d2e515272a1b65b7899ffdd5b4688cd /WORKFLOW.md | |
| parent | 9c50525b7ecf4f93e057ecbe162ea818b105319e (diff) | |
| download | danixxyz-dc4eba2c6a709995a2f4718f9fb407f3057a13b8.tar.gz danixxyz-dc4eba2c6a709995a2f4718f9fb407f3057a13b8.zip | |
feat: external links in main menu — A11y new-tab label + workflow docs
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'WORKFLOW.md')
| -rw-r--r-- | WORKFLOW.md | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/WORKFLOW.md b/WORKFLOW.md index c95141f..13a6da3 100644 --- a/WORKFLOW.md +++ b/WORKFLOW.md @@ -83,6 +83,24 @@ The banner appears automatically below the article header. If `successor` is set Paths are Hugo permalinks — for English articles, use `/articles/slug`, not `/en/articles/slug`. +### Add an external link to the main menu + +Add a menu entry in `hugo.toml` with `params.external = true`: + +```toml +[[menus.main]] + name = "GitHub" + url = "https://github.com/youruser" + weight = 10 + [menus.main.params] + external = true +``` + +- `name` is used as-is (not looked up in i18n) +- `url` must be a full URL including scheme +- `weight` controls order relative to other menu items +- External links open in a new tab with `rel="noopener noreferrer"` and include a screen-reader-only "(opens in new tab)" label for WCAG 2.1 AA compliance + --- ## Working on the Theme |
