Skip to content

Commit 71afd18

Browse files
authored
docs: fix dark mode logo
1 parent 0a81faf commit 71afd18

File tree

3 files changed

+24
-1
lines changed

3 files changed

+24
-1
lines changed

apps/website/docs/guide/01-getting-started/01-introduction.mdx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,16 @@ title: Introduction
33
description: A brief intro to CommandKit
44
---
55

6+
import Logo from './Logo';
7+
68
<div
79
align="center"
810
style={{
911
margin: '2rem 0',
1012
}}
1113
>
12-
<img src="/img/ckit_logo.svg" width="60%" />
14+
<Logo/>
15+
1316
<br />
1417
<div
1518
style={{
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
import React from 'react';
2+
import { useColorMode } from '@docusaurus/theme-common';
3+
4+
export default function Logo() {
5+
const { colorMode } = useColorMode();
6+
const logo =
7+
colorMode === 'dark' ? '/img/ckit_logo.svg' : '/img/ckit_logo_d.svg';
8+
return <img src={logo} width="60%" alt="CommandKit Logo" />;
9+
}

apps/website/static/img/ckit_logo_d.svg

Lines changed: 11 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)