Skip to content

fix: add a skip to main content link in default layout - #47694

Merged
djhi merged 2 commits into
masterfrom
gildasgarcia/fe-3805-add-skip-navigation-for-repeated-dashboard-sections
Jul 7, 2026
Merged

djhi merged 2 commits into
masterfrom
gildasgarcia/fe-3805-add-skip-navigation-for-repeated-dashboard-sections

Conversation

@djhi

@djhi djhi commented Jul 7, 2026 •

Copy link
Copy Markdown
Contributor

Problem

Screen reader and keyboard users have no way to skip the header and sidepanel navbar so they have to manually tab through every items before accessing the actual main page items.

Solution

Add a Skip to content link for them

Summary by CodeRabbit

  • New Features

    • Added a “Skip to content” link to help users jump directly to the main page area.
    • Updated the main content wrapper to a semantic main landmark with an anchor target.
  • Accessibility

    • Improved keyboard and screen reader navigation by supporting better in-page navigation and landmarks, without changing the page’s visible content.

@djhi
djhi requested a review from a team as a code owner July 7, 2026 14:30
@vercel

vercel Bot commented Jul 7, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
studio-self-hosted Ready Ready Preview, Comment Jul 7, 2026 3:05pm
studio-staging Ready Ready Preview, Comment Jul 7, 2026 3:05pm
5 Skipped Deployments
Project Deployment Actions Updated (UTC)
studio Ignored Ignored Jul 7, 2026 3:05pm
design-system Skipped Skipped Jul 7, 2026 3:05pm
docs Skipped Skipped Jul 7, 2026 3:05pm
ui-library Skipped Skipped Jul 7, 2026 3:05pm
zone-www-dot-com Skipped Skipped Jul 7, 2026 3:05pm

Request Review

@supabase

supabase Bot commented Jul 7, 2026

Copy link
Copy Markdown

This pull request has been ignored for the connected project xguihxuzqibwxjnimxev because there are no changes detected in supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@coderabbitai

coderabbitai Bot commented Jul 7, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

An error occurred during the review process. Please try again later.

📝 Walkthrough

Walkthrough

DefaultLayout.tsx adds a screen-reader-only "Skip to content" link targeting a new #main anchor, and changes the main content wrapper from a div to a semantic <main id="main"> element.

Changes

Accessibility skip-to-content update

Layer / File(s) Summary
Skip link and main landmark
apps/studio/components/layouts/DefaultLayout.tsx
Adds a sr-only "Skip to content" anchor linking to #main and replaces the content div with a semantic <main id="main"> wrapper.

Estimated code review effort: 1 (Trivial) | ~3 minutes

Possibly related PRs

  • supabase/supabase#47515: Both PRs implement a "Skip to content" navigation link targeting a main content container id.

Suggested reviewers: dnywh, ChrisChinchilla

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch gildasgarcia/fe-3805-add-skip-navigation-for-repeated-dashboard-sections

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Jul 7, 2026 •

Copy link
Copy Markdown
Contributor

🎭 Playwright Test Results

passed  231 passed
flaky  1 flaky
skipped  5 skipped

Details

stats  237 tests across 27 suites
duration  5 minutes, 8 seconds
commit  9990ca4

Flaky tests

Features › queue-table-operations.spec.ts › Queue Table Operations › pending changes persist when switching between tables

Skipped tests

Features › auth-users.spec.ts › should show web3 users as enabled when the matching web3 provider is enabled
Features › sql-editor.spec.ts › SQL Editor › snippet favourite works as expected
Features › sql-editor.spec.ts › SQL Editor › share with team works as expected
Features › sql-editor.spec.ts › SQL Editor › folders works as expected
Features › sql-editor.spec.ts › SQL Editor › other SQL snippets actions work as expected

@djhi
djhi merged commit 468aeb0 into master Jul 7, 2026
33 checks passed
@djhi
djhi deleted the gildasgarcia/fe-3805-add-skip-navigation-for-repeated-dashboard-sections branch July 7, 2026 15:33
@github-actions

github-actions Bot commented Jul 7, 2026 •

Copy link
Copy Markdown
Contributor

Braintrust eval report

Assistant (master-1783438496)

Score Average Improvements Regressions
Knowledge Usage 100% (+3pp) 1 🟢 -
Tool Usage 72.5% (-2pp) 1 🟢 1 🔴
SQL Identifier Quoting 100% (+0pp) - -
SQL Validity 90% (-5pp) - 1 🔴
Time_to_first_token 3.4tok (+0.1tok) 9 🟢 20 🔴
Llm_calls 2.85 (+0.15) 14 🟢 9 🔴
Tool_calls 3.09 (+0.23) 9 🟢 8 🔴
Errors 5.3 (+0.06) 1 🟢 6 🔴
Llm_errors 0 (+0) - -
Tool_errors 0 (+0) - -
Prompt_tokens 25214.82tok (+576.29tok) 10 🟢 15 🔴
Prompt_cached_tokens 7597.61tok (+688.55tok) 15 🟢 6 🔴
Prompt_cache_creation_tokens 0tok (+0tok) - -
Prompt_cache_creation_5m_tokens 0tok (+0tok) - -
Prompt_cache_creation_1h_tokens 0tok (+0tok) - -
Completion_tokens 609.66tok (+24.84tok) 12 🟢 17 🔴
Completion_reasoning_tokens 101.51tok (+8.69tok) 11 🟢 15 🔴
Total_tokens 25824.47tok (+601.13tok) 14 🟢 15 🔴
Estimated_cost 0$ (+0$) 14 🟢 11 🔴
Duration 17.96s (+1.44s) 8 🟢 21 🔴
Llm_duration 11.94s (+0.37s) 12 🟢 17 🔴

djhi added a commit that referenced this pull request Jul 24, 2026
## Problem

#47694 introduced a _Skip to main content_ link allowing keyboard users
to jump to the main section without having to tab through all the
navigation elements.

However, this link is completely invisible which means sighted users
will not see what is actually focused.

## Solution

The best practice for such links is to make them visible on focus. For
instance on https://tetralogical.com:
<img width="1556" height="305" alt="image"
src="https://github.com/user-attachments/assets/e36f6d73-98b0-46ca-b464-72540a482b5f"
/>

Here's what it looks like on Studio:
<img width="1835" height="335" alt="image"
src="https://github.com/user-attachments/assets/71623306-587a-48aa-b955-43d3368f6073"
/>

## How to test

- Make sure your browser allows to tab to links
(https://www.articulatesupport.com/article/How-to-Enable-Tab-Key-Navigation-on-a-Mac)
- Open
https://studio-staging-git-gildasgarcia-fe-3805-add-ski-cf6824-supabase.vercel.app
and sign in
- Once the Studio is loaded, verify the button isn't be visible
- Press _Tab_: the button should be visible.
- Press _Enter_, then press _Tab: the organizations search input should
be focused
dnywh added a commit that referenced this pull request Jul 28, 2026
…#48314)

## What kind of change does this PR introduce?

Feature / a11y polish

## What is the current behavior?

Studio and Docs each had their own skip-to-content link (different
styling and behaviour). www and design-system had none.

## What is the new behavior?

Shared `SkipToContent` in `ui-patterns`, adopted by Studio, Docs, www,
and design-system. Documented as a fragment with a short note under
Accessibility → Jumping ahead.

Tab once to reveal the button (top-left), Enter to jump to a
content-only `<main>`.

| After |
| --- |
| <img width="836" height="324" alt="CleanShot 2026-07-24 at 14 08
47@2x"
src="https://github.com/user-attachments/assets/6df29452-e53a-4eca-8f64-946f2b9f605d"
/> |

## To test

Shared steps for every app: enable Tab key navigation if needed, load
the preview, press **Tab** once — skip button should slide in top-left.
Press **Enter** — focus jumps to main content (no blue ring on
`<main>`). Press **Tab** again — first interactive control in the page
body, not the sidebar/nav. Hover the skip button — solid fill, clear
hover state, no chrome showing through.

- **Studio** —
[preview](https://studio-staging-git-dnywh-featskip-to-content-supabase.vercel.app)
→ sign in → any project page
- **Docs** —
[preview](https://docs-git-dnywh-featskip-to-content-supabase.vercel.app)
→ any docs page with sidebar
- **www** —
[preview](https://zone-www-dot-com-git-dnywh-featskip-to-content-supabase.vercel.app)
→ homepage or any marketing page with the default nav
- **Design system** —
[preview](https://design-system-git-dnywh-featskip-to-content-supabase.vercel.app)
→ any docs page (confirm Tab from content does **not** walk the
sidebar), plus [Skip to Content
fragment](https://design-system-git-dnywh-featskip-to-content-supabase.vercel.app/docs/fragments/skip-to-content)

## Additional context

Follow-up to #47694 / #48303 (Studio) and #47515 (Docs).

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Added a reusable “Skip to content” accessibility link across key
layouts and pages.
- Updated main landmarks to support keyboard focus and skip-link
navigation (`id="main"`).
- **Accessibility**
- Skip links now follow consistent landmark-target conventions and
remain hidden until focused.
- Improved documentation for skip links/jump shortcuts in persistent
chrome layouts.
- **Documentation**
- Added a dedicated Skip to Content fragment, navigation entry, and
expanded accessibility guidance.
  - Updated button description wording in component docs.
- **Tests**
  - Added component tests for SkipToContent.
- **Chores**
  - Exposed SkipToContent via additional public package entry points.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
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.

2 participants