Add ThemedImage to control logo color in dark mode

This commit is contained in:
Pete Gonzalez 2024-02-26 22:39:53 -08:00
parent e42289ecfa
commit 67b1204505
2 changed files with 11 additions and 2 deletions

View file

@ -4,8 +4,16 @@ hide_title: true
custom_edit_url: null
---
import { ThemedImage } from '@site/src/components/ThemedImage';
<div style={{ display: 'flex', justifyContent: 'center', alignItems: 'center' }}>
<img src="images/site/sparo-logo.svg" alt="Sparo" title="Sparo" style={{ width: '380px', paddingTop: '30px' }} />
<ThemedImage
srcLight="images/site/sparo-logo.svg"
srcDark="images/site/sparo-logo-dark.svg"
alt="Sparo"
title="Sparo"
style={{ width: '380px', paddingTop: '30px' }}
/>
</div>
> 🚧 UNDER CONSTRUCTION 🚧

View file

@ -82,7 +82,8 @@ const config = {
title: '',
logo: {
alt: 'Sparo',
src: 'images/site/sparo-title.svg'
src: 'images/site/sparo-title.svg',
srcDark: 'images/site/sparo-title-dark.svg'
},
items: [
{