Skip to content

Commit

Permalink
feat(docusaurus.config): Add color mode configuration
Browse files Browse the repository at this point in the history
This commit adds a new configuration for the color mode in the `docusaurus.config.ts` file. The `colorMode` object is added with properties to set the default mode to 'dark' and respect the user's preferred color scheme. This allows users to have a consistent color mode experience on the website.
  • Loading branch information
BillChirico committed Nov 8, 2023
1 parent c3b7efd commit 64c1295
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ const config: Config = {
to: 'https://apollo.volvox.tech',
},
{
to: '/apollo-docs',
to: '/apollo-docs/',
position: 'left',
label: 'Home'
},
Expand Down Expand Up @@ -139,6 +139,10 @@ const config: Config = {
darkTheme: prismThemes.oneDark,
additionalLanguages: ['json']
},
colorMode: {
defaultMode: 'dark',
respectPrefersColorScheme: true,
},
} satisfies Preset.ThemeConfig,

// Custom Plugins
Expand Down

0 comments on commit 64c1295

Please sign in to comment.