Skip to content

Commit

Permalink
Docs: Fix Bug
Browse files Browse the repository at this point in the history
Theme Enabled svg on the main page did not display
correctly on firefox. Use React Native code to show
this svg instead of html native code
  • Loading branch information
mert-kurttutan committed Mar 17, 2023
1 parent b2054b1 commit c640a4a
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 7 deletions.
2 changes: 1 addition & 1 deletion docs/src/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

/* You can override the default Infima variables here. */
:root {
--ifm-color-primary: #2e8555;
--ifm-color-primary: #2b743d;
--ifm-color-primary-dark: #29784c;
--ifm-color-primary-darker: #277148;
--ifm-color-primary-darkest: #205d3b;
Expand Down
19 changes: 13 additions & 6 deletions docs/src/pages/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,27 @@ import Layout from '@theme/Layout';

import styles from './index.module.css';

import ThemedImage from '@theme/ThemedImage';
import useBaseUrl from '@docusaurus/useBaseUrl';



function HomepageHeader() {
const {siteConfig} = useDocusaurusContext();
return (
<header className={clsx('hero hero--primary', styles.heroBanner)}>
<div className="container">
<h1 className="hero__title">{siteConfig.title}</h1>
<p className="hero__subtitle">{siteConfig.tagline}</p>

<p align="center">
<picture align="center">
<source media="(prefers-color-scheme: dark)" srcset="https://user-images.githubusercontent.com/88637659/213171745-7acf07df-6578-4a50-a106-1a7b368f8d6c.svg"/>
<img alt="Shows a bar chart with benchmark results." src="https://user-images.githubusercontent.com/88637659/213173736-6e91724c-8de1-4568-9d52-297b4b5ff0d2.svg" />
</picture>
</p>
<ThemedImage
alt="Docusaurus themed image"
sources={{
light: useBaseUrl('https://user-images.githubusercontent.com/88637659/213171745-7acf07df-6578-4a50-a106-1a7b368f8d6c.svg'),
dark: useBaseUrl('https://user-images.githubusercontent.com/88637659/213173736-6e91724c-8de1-4568-9d52-297b4b5ff0d2.svg'),
}}
/>;
</p>
</div>
</header>
);
Expand Down

1 comment on commit c640a4a

@vercel
Copy link

@vercel vercel bot commented on c640a4a Mar 17, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.