Skip to content

Commit 8406c4f

Browse files
committed
docs(theme-extension): add minimal TS example for theme.light and theme.dark overrides
1 parent 1badc73 commit 8406c4f

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

docusaurus/docs/cms/admin-panel-customization/theme-extension.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,25 @@ To extend the theme, use either:
2121
:::strapi Strapi Design System
2222
The default <ExternalLink to="https://github.com/strapi/design-system/tree/main/packages/design-system/src/themes" text="Strapi theme"/> defines various theme-related keys (shadows, colors…) that can be updated through the `config.theme.light` and `config.theme.dark` keys in `./admin/src/app.js`. The <ExternalLink to="https://design-system.strapi.io/" text="Strapi Design System"/> is fully customizable and has a dedicated <ExternalLink to="https://design-system-git-main-strapijs.vercel.app" text="StoryBook"/> documentation.
2323
:::
24+
25+
### Example (TypeScript)
26+
27+
```ts title="/src/admin/app.ts"
28+
export default {
29+
config: {
30+
theme: {
31+
light: {
32+
colors: {
33+
primary600: '#4A6EFF',
34+
},
35+
},
36+
dark: {
37+
colors: {
38+
primary600: '#9DB2FF',
39+
},
40+
},
41+
},
42+
},
43+
bootstrap() {},
44+
}
45+
```

0 commit comments

Comments
 (0)