Skip to content

fix(editor): tab strip follows the Editor's theme (panels 0.4.0) - #1915

Merged
callumalpass merged 1 commit into
mainfrom
editor-light-mode-tabs
Nov 25, 2026
Merged

callumalpass merged 1 commit into
mainfrom
editor-light-mode-tabs

Conversation

@callumalpass

Copy link
Copy Markdown
Member

With the Editor set to light on a system in dark mode, the tab strip rendered dark and the active tab's title was close to invisible. In dark mode it used the panels library's stock greys instead of the Editor's colours.

Cause — in @mdbase-dev/panels 0.3.1:

  • The colour defaults were declared on .mp-workspace itself, so the Editor's --mp-* theme on .editor-panels (an ancestor) never applied.
  • The workspace forced color-scheme: light dark, so light-dark() inside it (the Editor's own tokens included) followed the system instead of the Editor's data-theme.

Fix — mdbase-dev/mdbase-panels#1, released as 0.4.0:

  • Defaults move to :where(:root), so a theme set on any ancestor applies.
  • The workspace no longer sets color-scheme.

This PR only moves the Editor to 0.4.0; the Editor's existing styles apply unchanged. 0.4.0 is the first panels release from its tag workflow, published with provenance via an npm trusted publisher added today.

Checks

  • pnpm ci:local passed.
  • Editor typecheck and 1,317 unit tests passed.
  • Editor Playwright --project chromium: 230 passed.
  • Headless Chrome renders with the Editor's tokens and stylesheets, for Editor light/dark × system light/dark: all four follow the Editor's theme. Before the fix, light on a dark system rendered dark.

Release note: changelog.d/editor-light-mode-tabs.md.

@mdbase-dev/panels 0.3.1 declared its colour defaults on .mp-workspace and
forced color-scheme: light dark there, so the Editor's --mp-* theme on
.editor-panels never applied and light-dark() inside the workspace followed the
system: an Editor in light mode on a dark system showed a dark tab strip with a
near-invisible active title. 0.4.0 (mdbase-dev/mdbase-panels#1) takes ancestor
themes and the page's colour scheme, so the Editor's existing styles apply
unchanged.
@callumalpass
callumalpass added this pull request to the merge queue Nov 25, 2026
Merged via the queue into main with commit 132cbed Nov 25, 2026
34 checks passed
@callumalpass
callumalpass deleted the editor-light-mode-tabs branch November 25, 2026 04:10
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