mirror of
https://github.com/umami-software/umami.git
synced 2026-02-16 10:35:35 +01:00
Compare commits
No commits in common. "f47e1072d9d0c0ba9650cdd5eb1f458f6a1d472a" and "b0f38b266bc6fbc079b65d75bd27b5b925bec827" have entirely different histories.
f47e1072d9
...
b0f38b266b
1 changed files with 1 additions and 12 deletions
|
|
@ -1,6 +1,5 @@
|
|||
'use client';
|
||||
import { Column, useTheme } from '@umami/react-zen';
|
||||
import { useEffect } from 'react';
|
||||
import { Column } from '@umami/react-zen';
|
||||
import { WebsiteHeader } from '@/app/(main)/websites/[websiteId]/WebsiteHeader';
|
||||
import { WebsitePage } from '@/app/(main)/websites/[websiteId]/WebsitePage';
|
||||
import { WebsiteProvider } from '@/app/(main)/websites/WebsiteProvider';
|
||||
|
|
@ -11,16 +10,6 @@ import { Header } from './Header';
|
|||
|
||||
export function SharePage({ shareId }) {
|
||||
const { shareToken, isLoading } = useShareTokenQuery(shareId);
|
||||
const { setTheme } = useTheme();
|
||||
|
||||
useEffect(() => {
|
||||
const url = new URL(window?.location?.href);
|
||||
const theme = url.searchParams.get('theme');
|
||||
|
||||
if (theme === 'light' || theme === 'dark') {
|
||||
setTheme(theme);
|
||||
}
|
||||
}, []);
|
||||
|
||||
if (isLoading || !shareToken) {
|
||||
return null;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue