diff --git a/src/components/landing/FeaturesSection/Github.tsx b/src/components/landing/FeaturesSection/Github.tsx index b4c13002..12a7ce88 100644 --- a/src/components/landing/FeaturesSection/Github.tsx +++ b/src/components/landing/FeaturesSection/Github.tsx @@ -3,6 +3,7 @@ import GitHubCalendar from 'react-github-calendar' import { useColorMode } from '@docusaurus/theme-common' import { Icon } from '@iconify/react' +import ThemedImage from '@theme/ThemedImage' interface GithubProps { className?: string @@ -11,9 +12,9 @@ interface GithubProps { export default function Github({ className }: GithubProps) { const { isDarkTheme } = useColorMode() - const githubStatsUrl = (type: 'overview' | 'languages') => + const githubStatsUrl = (type: 'overview' | 'languages', isDark: boolean) => `https://raw.githubusercontent.com/kuizuo/github-stats/master/generated/${type}.svg#gh-${ - isDarkTheme ? 'dark' : 'light' + isDark ? 'dark' : 'light' }-mode-only` return ( @@ -24,8 +25,20 @@ export default function Github({ className }: GithubProps) {