-
-
Notifications
You must be signed in to change notification settings - Fork 597
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix synced nested
<Tabs>
restoration issue (#2377)
- Loading branch information
Showing
4 changed files
with
90 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@astrojs/starlight': patch | ||
--- | ||
|
||
Fixes an issue with synced `<Tabs>` components containing nested `<Tabs>` causing tab panels to not render correctly. |
47 changes: 47 additions & 0 deletions
47
packages/starlight/__e2e__/fixtures/basics/src/content/docs/tabs-nested.mdx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
--- | ||
title: Tabs | ||
--- | ||
|
||
import { Tabs, TabItem } from '@astrojs/starlight/components'; | ||
|
||
A set of tabs using the `pkg` sync key with some nested tabs using an `os` sync key. | ||
|
||
<Tabs syncKey="pkg"> | ||
|
||
<TabItem label="npm"> | ||
|
||
npm content | ||
|
||
<Tabs syncKey="os"> | ||
<TabItem label="macos">npm macOS</TabItem> | ||
<TabItem label="windows">npm Windows</TabItem> | ||
<TabItem label="linux">npm GNU/Linux</TabItem> | ||
</Tabs> | ||
|
||
</TabItem> | ||
|
||
<TabItem label="pnpm"> | ||
|
||
pnpm content | ||
|
||
<Tabs syncKey="os"> | ||
<TabItem label="macos">pnpm macOS</TabItem> | ||
<TabItem label="windows">pnpm Windows</TabItem> | ||
<TabItem label="linux">pnpm GNU/Linux</TabItem> | ||
</Tabs> | ||
|
||
</TabItem> | ||
|
||
<TabItem label="yarn"> | ||
|
||
yarn content | ||
|
||
<Tabs syncKey="os"> | ||
<TabItem label="macos">yarn macOS</TabItem> | ||
<TabItem label="windows">yarn Windows</TabItem> | ||
<TabItem label="linux">yarn GNU/Linux</TabItem> | ||
</Tabs> | ||
|
||
</TabItem> | ||
|
||
</Tabs> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters