Skip to content

Commit 6ebb176

Browse files
committed
Fix Direct Upload icons
1 parent 41ab175 commit 6ebb176

File tree

2 files changed

+27
-1
lines changed

2 files changed

+27
-1
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
"format:core:fix": "npm run format:core -- --write",
1717
"format:content": "npx prettier --write \"**/*.{md,mdx,astro}\"",
1818
"format:data": "npx prettier --write \"**/*.{json,yaml,yml}\"",
19-
"postinstall": "npm run sync",
19+
"postinstall": "npx patch-package && npm run sync",
2020
"preview": "npx astro preview",
2121
"script:optimize-svgs": "npx tsx scripts/optimize-svgs.ts",
2222
"start": "npx astro dev",
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
diff --git a/node_modules/@astrojs/starlight/user-components/Tabs.astro b/node_modules/@astrojs/starlight/user-components/Tabs.astro
2+
index 257174e..053d6f7 100644
3+
--- a/node_modules/@astrojs/starlight/user-components/Tabs.astro
4+
+++ b/node_modules/@astrojs/starlight/user-components/Tabs.astro
5+
@@ -3,10 +3,11 @@ import Icon from './Icon.astro';
6+
import { processPanels } from './rehype-tabs';
7+
8+
interface Props {
9+
+ IconComponent?: typeof Icon;
10+
syncKey?: string;
11+
}
12+
13+
-const { syncKey } = Astro.props;
14+
+const { syncKey, IconComponent = Icon } = Astro.props;
15+
const panelHtml = await Astro.slots.render('default');
16+
const { html, panels } = processPanels(panelHtml);
17+
18+
@@ -84,7 +85,7 @@ if (isSynced) {
19+
aria-selected={idx === 0 ? 'true' : 'false'}
20+
tabindex={idx !== 0 ? -1 : 0}
21+
>
22+
- {icon && <Icon name={icon} />}
23+
+ {icon && <IconComponent name={icon} />}
24+
{label}
25+
</a>
26+
</li>

0 commit comments

Comments
 (0)