Skip to content

Connect Carbon tabs to their panels (OSS-439) - #709

Merged
athNdev merged 1 commit into
mainfrom
codex/oss439-tabs-relationships
Nov 20, 2026
Merged

athNdev merged 1 commit into
mainfrom
codex/oss439-tabs-relationships

Conversation

@athNdev

@athNdev athNdev commented Nov 20, 2026 •

Copy link
Copy Markdown
Owner

OSS-439

Every Carbon tab has a unique, reciprocal panel target. Tab enters the selected panel, including empty views. Inactive panel shells stay empty and hidden, and their components remain unmounted.

The audit covered Server detail, Modpacks Library and Import, Studio workspace and Add Mod, Login, Modules, Player detail, World Library detail, Settings and the shipped homepage Studio example. The standalone World View route has no CarbonTabs group.

Rebased on main 7138443edb719ba2b24bc0a11b22496da29b94a4, including #706 and #708. The existing Modpacks tab badge loads still fetch Favorites and Imported collections at page load. Server Files still defers its listing request until activation.

Verification

Head: 46c927e9486dd1ee64e6fd8c75ff85f69aad841b

  • The hidden panel shell is internal. Removing it from the public Carbon barrel restored the design-system documentation contract. All 59 website/design-system tests and the brand-asset check passed. The complete website build validated routes and assets across 77 HTML pages and passed both version checks.
  • Production-build Chromium passed 428 checks, including globally unique tab IDs, reciprocal targets, one visible panel, Tab focus on empty and populated views, arrows/Home/End, deferred Server Files, Name the modpack browse filters for assistive technology (OSS-437) #706 filters, and Keep narrow settings controls readable and reachable #708 narrow Settings controls.
  • Supplemental Chromium checks covered Login, Modules, Player detail, World Library detail, both Studio groups, and the homepage Studio prerender and hydration.
  • bun run check reported zero Svelte diagnostics. bun run test passed 473 tests, with six opt-in live cases skipped. Both knowledge lint passes and git diff --check passed.
  • Verification used production static assets with loopback RPC fixtures.

Summary by CodeRabbit

  • Accessibility
    • Improved keyboard navigation and screen-reader relationships across tabbed pages, with clear focus indicators and focusable content panels.
    • Inactive tab content stays hidden until selected, and some content loads only when its tab is opened.
    • Modpacks pages are checked across mobile, tablet, and desktop widths in both themes.
  • Bug Fixes
    • Modpack cards now show “Metadata unreadable” when saved loader or game-version details are malformed.

@coderabbitai

coderabbitai Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

Changes: Tab panel accessibility

Layer / File(s) Summary
Shared inactive panels and page integration
web/carbon-panel/src/lib/components/carbon/CarbonInactiveTabPanels.svelte, web/carbon-panel/demo/StudioFragment.svelte, web/carbon-panel/src/routes/library/[id]/+page.svelte, web/carbon-panel/src/routes/login/+page.svelte, web/carbon-panel/src/routes/modules/+page.svelte, web/carbon-panel/src/routes/players/[key]/+page.svelte, web/carbon-panel/src/routes/servers/[id]/+page.svelte, web/carbon-panel/src/routes/settings/+page.svelte
The new component renders empty hidden panels for inactive tabs. The demo and listed pages add linked panels or make active panels keyboard-focusable with focus styling.
Modpacks and studio tab panels
web/carbon-panel/src/routes/modpacks/+page.svelte, web/carbon-panel/src/routes/modpacks/studio/[id]/+page.svelte
The Modpacks library and import tabs, studio workspace tabs, and Add Mods source tabs use linked panels. Modpack cards display “Metadata unreadable” for malformed loader or game-version metadata.
Packaged browser checks and coverage guidance
scripts/manual-review/e2e/a11y-check.mjs, knowledge/decisions/frontend-a11y-coverage.md, knowledge/workflows/frontend-change-rules-2.md
Browser checks validate tab relationships and keyboard movement, test that inactive content is not mounted, and run Modpacks at 360, 768, and 1440 pixels in both themes. The guidance documents the coverage and tab-panel requirements.

Possibly related PRs

  • athNdev/carbonpanel#706: Adds Modpacks filter labels and a browser guard on the same filter selectors changed by this PR.

Suggested reviewers: nickheyer

Change: Bug fix

Merge Risk: Minimal · up to 46c92

This change connects tabs to their panels and makes active panels keyboard-focusable across several pages. No actionable merge-blocking risk was found, and the change is easy to revert.

Security architecture risk: Minimal · up to 46c92

The change links existing tabs to their panels and improves keyboard access without expanding privileges, exposing new server operations, or changing persistent-state behavior.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 52ffcd43-d628-48c8-8054-1cc4ba32440a
Commits

Reviewing files that changed from the base of the PR and between 4bc64ce and 46c927e.

Files selected for processing: 11

  • knowledge/decisions/frontend-a11y-coverage.md
  • knowledge/workflows/frontend-change-rules-2.md
  • scripts/manual-review/e2e/a11y-check.mjs
  • web/carbon-panel/src/routes/library/[id]/+page.svelte
  • web/carbon-panel/src/routes/login/+page.svelte
  • web/carbon-panel/src/routes/modpacks/+page.svelte
  • web/carbon-panel/src/routes/modpacks/studio/[id]/+page.svelte
  • web/carbon-panel/src/routes/modules/+page.svelte
  • web/carbon-panel/src/routes/players/[key]/+page.svelte
  • web/carbon-panel/src/routes/servers/[id]/+page.svelte
  • web/carbon-panel/src/routes/settings/+page.svelte

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 1 remain after this review.

@athNdev
athNdev force-pushed the codex/oss439-tabs-relationships branch from 74206f9 to 4bc64ce Compare November 20, 2026 19:19
@athNdev
athNdev marked this pull request as ready for review November 20, 2026 19:19

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 issues found across 13 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="scripts/manual-review/e2e/a11y-check.mjs">

<violation number="1" location="scripts/manual-review/e2e/a11y-check.mjs:1137">
P3: This checks only unique panel targets; duplicate tab IDs still pass the reciprocal-label check and make panel labels ambiguous. Check `tab.tabId` uniqueness too.</violation>
</file>

<file name="web/carbon-panel/src/routes/modpacks/+page.svelte">

<violation number="1" location="web/carbon-panel/src/routes/modpacks/+page.svelte:505">
P2: The inactive panels do not defer their data requests: `onMount` still calls `loadFavorites()` and `loadUploadedPacks()` on every visit. Start each view's load when its tab is selected so inactive views do not fetch before selection.</violation>
</file>

Reply with feedback, questions, or to request a fix.

View guided diff | Turn on auto-fix | Re-trigger cubic

<!-- Library view control: Browse / Imported / Favorites -->
<CarbonTabs tabs={libraryTabs} bind:selectedTab={activeView} />
<CarbonTabs tabs={libraryTabs} bind:selectedTab={activeView} idPrefix="modpacks" />
<CarbonInactiveTabPanels tabs={libraryTabs} selectedTab={activeView} idPrefix="modpacks" />

@cubic-dev-ai cubic-dev-ai Bot Nov 20, 2026 •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: The inactive panels do not defer their data requests: onMount still calls loadFavorites() and loadUploadedPacks() on every visit. Start each view's load when its tab is selected so inactive views do not fetch before selection.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At web/carbon-panel/src/routes/modpacks/+page.svelte, line 505:

<comment>The inactive panels do not defer their data requests: `onMount` still calls `loadFavorites()` and `loadUploadedPacks()` on every visit. Start each view's load when its tab is selected so inactive views do not fetch before selection.</comment>

<file context>
@@ -500,349 +501,357 @@ one at https://mozilla.org/MPL/2.0/.
 	<!-- Library view control: Browse / Imported / Favorites -->
-	<CarbonTabs tabs={libraryTabs} bind:selectedTab={activeView} />
+	<CarbonTabs tabs={libraryTabs} bind:selectedTab={activeView} idPrefix="modpacks" />
+	<CarbonInactiveTabPanels tabs={libraryTabs} selectedTab={activeView} idPrefix="modpacks" />
 
-	{#if selectedIndexer === 'fuego'}
</file context>
Fix with cubic

);
if (
tabs.length < 2 ||
new Set(tabs.map((tab) => tab.id)).size !== tabs.length ||

@cubic-dev-ai cubic-dev-ai Bot Nov 20, 2026 •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: This checks only unique panel targets; duplicate tab IDs still pass the reciprocal-label check and make panel labels ambiguous. Check tab.tabId uniqueness too.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At scripts/manual-review/e2e/a11y-check.mjs, line 1137:

<comment>This checks only unique panel targets; duplicate tab IDs still pass the reciprocal-label check and make panel labels ambiguous. Check `tab.tabId` uniqueness too.</comment>

<file context>
@@ -1120,9 +1111,47 @@ async function runPackagedRouteJourney(browser, base, theme = 'light') {
+	);
+	if (
+		tabs.length < 2 ||
+		new Set(tabs.map((tab) => tab.id)).size !== tabs.length ||
+		tabs.filter((tab) => tab.selected).length !== 1 ||
+		tabs.find((tab) => tab.selected)?.tabId !== selectedId ||
</file context>
Suggested change
new Set(tabs.map((tab) => tab.id)).size !== tabs.length ||
new Set(tabs.map((tab) => tab.tabId)).size !== tabs.length ||
new Set(tabs.map((tab) => tab.id)).size !== tabs.length ||
Fix with cubic

@athNdev
athNdev force-pushed the codex/oss439-tabs-relationships branch from 4bc64ce to 46c927e Compare November 20, 2026 19:47
@athNdev
athNdev merged commit 86f8053 into main Nov 20, 2026
24 checks passed
@athNdev
athNdev deleted the codex/oss439-tabs-relationships branch November 20, 2026 19:59
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