From 026f7a546144024aed2830b1260904b81fe10da7 Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 13 Oct 2026 12:44:35 +0000 Subject: [PATCH 1/2] Tabs: Restore fit-content width for horizontal tab lists The Emotion to SCSS Modules migration copied the nested `:where([aria-orientation="horizontal"])` rule verbatim. Emotion's stylis compat plugin treated a nested selector starting with `:` as `&:`, so it targeted the tab list itself. In Sass it compiles to a descendant selector that matches nothing, which let horizontal tab lists stretch to full width. Co-Authored-By: Claude Opus 5.5 (1M context) Claude-Session: https://claude.ai/code/session_01BDbQ9jxcSLqXLn4uJiKVpH --- packages/components/src/tabs/style.module.scss | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/components/src/tabs/style.module.scss b/packages/components/src/tabs/style.module.scss index f325fd8161a754..7cf5bedddcc76c 100644 --- a/packages/components/src/tabs/style.module.scss +++ b/packages/components/src/tabs/style.module.scss @@ -10,7 +10,7 @@ flex-direction: column; } - :where([aria-orientation="horizontal"]) { + &:where([aria-orientation="horizontal"]) { width: fit-content; } From b07c7b97f36735d5215eb15b51d169f2b19f88cd Mon Sep 17 00:00:00 2001 From: Claude Date: Tue, 13 Oct 2026 12:46:17 +0000 Subject: [PATCH 2/2] Add changelog entry Co-Authored-By: Claude Opus 5.5 (1M context) Claude-Session: https://claude.ai/code/session_01BDbQ9jxcSLqXLn4uJiKVpH --- packages/components/CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/components/CHANGELOG.md b/packages/components/CHANGELOG.md index 114012fe507d97..732d1d37527112 100644 --- a/packages/components/CHANGELOG.md +++ b/packages/components/CHANGELOG.md @@ -19,6 +19,7 @@ ### Bug Fixes +- `Tabs`: Restore the `fit-content` width of horizontal tab lists, which stretched to full width after the SCSS Modules migration ([#84626](https://github.com/WordPress/gutenberg/pull/84626)). - `InputControl`, `NumberControl`, `UnitControl`: Ignore the drag gesture for touch input, where it has no cursor affordance and is easy to trigger by accident ([#38865](https://github.com/WordPress/gutenberg/issues/38865), [#81519](https://github.com/WordPress/gutenberg/pull/81519)). - `Modal`: Keep focus inside the dialog when `focusOnMount="firstContentElement"` finds no tabbable elements in the content ([#84344](https://github.com/WordPress/gutenberg/pull/84344)). - `navigateRegions`: Only outline the Publish and Save controls when their region has focus ([#84343](https://github.com/WordPress/gutenberg/pull/84343)).