Skip to content

Drop the Community placeholder; mark outbound links as opening in a new tab - #224

Merged
neuromechanist merged 2 commits into
stagingfrom
feature/nav-external-links-and-drop-community
Jul 31, 2026
Merged

neuromechanist merged 2 commits into
stagingfrom
feature/nav-external-links-and-drop-community

Conversation

@neuromechanist

Copy link
Copy Markdown
Contributor

Closes #222.

Community is gone

The nav entry, the footer's "Forum" link, and src/pages/community.astro are removed. The page was a placeholder saying a forum "will land in Phase 4" and pointing people at github.com/nemarDatasets in the meantime — a top-level nav slot spent on a surface with nothing behind it.

The footer column that held it is renamed Community -> Project, because it still holds About and Support and those are real. Removing the column outright would have taken two working links with it.

/community now 404s. It was a stub with no inbound links from elsewhere on the site, so the exposure is bookmarks; flagging it rather than adding a redirect for a page that only ever said "not yet".

Two host.test.ts cases used /community as a sample marketing path. Dropped from both — the remaining paths cover the same classification, and the second list is now entirely real routes.

The need this was standing in for is per-dataset discussion, now tracked as #223 (frontend) and nemar-cli#1043 (backend).

Outbound links open in a new tab, behind a 45-degree arrow

New src/components/ExternalLink.astro, used for every nav and footer link that leaves nemar.org: the citation dashboard, the docs site, the Data column's three hosts, both GitHub organizations, and the Astro / Cloudflare Pages attribution.

Deliberately not applied to every rel="external" in the codebase. Download anchors — BidsTree.astro's per-file links, the archive action — carry rel="external" too, and neither the arrow nor target="_blank" belongs on them: they start a download rather than a navigation, so the arrow would promise a page that never appears.

Details worth noting:

  • rel="noopener" is the one that matters with target="_blank"; without it the opened page gets a live window.opener handle back. noreferrer rides along.
  • A visually-hidden "(opens in a new tab)" accompanies the icon. A decorative arrow tells a sighted user what is about to happen and a screen-reader user nothing at all.
  • The icon is sized in em, so it tracks whatever type scale the caller uses — nav, footer columns, and the smaller build line all render it correctly with nothing passed in.
  • Applied to the Astro/Cloudflare attribution too. Two arrows in one short line is busier than leaving them bare, but a marker applied only to links someone judged important stops being a reliable signal.

Also: skip a redirect hop

https://dashboard.nemar.org/citations 308-redirects to /citations/. The nav, the footer, and getRetiredRedirect in src/lib/host.ts all linked the non-canonical form, so every visitor paid an extra round trip — and from /citation-dashboard that was a redirect landing on a redirect. All three now link /citations/.

Verified

Rendered against the dev server: /community returns 404; nav shows five entries with target="_blank" on exactly the two external ones; footer columns are Explore / Project / Data / GitHub with arrows on every outbound link and none on Discover, About, or Support. Screenshotted in dark and light.

test 1015/1015, typecheck 0 errors, lint clean.

Filed alongside, not in this PR

The nav and footer advertised a Community surface backed by a
placeholder page promising a forum that does not exist and was not being
built. Nav entry, footer Forum link, and the page are gone; the footer
column is now Project, describing what is actually under it.

Links that leave nemar.org -- the citation dashboard, the docs site, the
data/api hosts, the GitHub orgs, the build attribution -- now open in a
new tab behind a 45-degree arrow. Not applied to download anchors, which
also carry rel=external but start a download rather than a navigation.

Also links the canonical /citations/ so visitors skip a 308 hop.

Closes #222
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 31, 2026 •

Copy link
Copy Markdown

Astro scopes .primary-nav__list a to Nav's own elements, but the anchor
renders inside ExternalLink.astro and carries that component's scope id
instead -- so the rule missed it and Citation Dashboard and Documentation
fell back to the default link colour and a larger size. Same in the
footer columns.

:global() on the descendant, scope kept on the container, so this stays
confined to the nav and the footer nav.
@neuromechanist
neuromechanist merged commit 2bb432d into staging Jul 31, 2026
5 checks passed
@neuromechanist
neuromechanist deleted the feature/nav-external-links-and-drop-community branch July 31, 2026 04:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant