Skip to content

Commit

Permalink
fix: use theme-based color for Snowfall component in LayoutContent
Browse files Browse the repository at this point in the history
  • Loading branch information
chimpdev committed Dec 17, 2024
1 parent 53b450f commit 3afe142
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions client/app/layout-content.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,12 @@ import FullPageLoading from './components/FullPageLoading';
import useLanguageStore from '@/stores/language';
import ReportButtonProvider from '@/app/components/Providers/ReportButton';
import Snowfall from 'react-snowfall';
import useThemeStore from '@/stores/theme';

export default function RootLayoutContent({ children }) {
const language = useLanguageStore(state => state.language);
const showFullPageLoading = useGeneralStore(state => state.showFullPageLoading);
const theme = useThemeStore(state => state.theme);

useEffect(() => {
const html = document.documentElement;
Expand All @@ -40,6 +42,7 @@ export default function RootLayoutContent({ children }) {
zIndex: 9999999,
position: 'fixed'
}}
color={theme === 'dark' ? '#fff' : '#000'}
/>

<Script
Expand Down

0 comments on commit 3afe142

Please sign in to comment.