mirror of
https://github.com/zadam/trilium.git
synced 2025-10-20 23:29:02 +02:00
fix(website): screenshot not loading due to SSR
This commit is contained in:
parent
c25f783980
commit
bd2eb6fdbb
@ -54,6 +54,7 @@ function HeroSection() {
|
|||||||
let screenshotUrl: string | null = null;
|
let screenshotUrl: string | null = null;
|
||||||
const colorScheme = useColorScheme();
|
const colorScheme = useColorScheme();
|
||||||
|
|
||||||
|
if (colorScheme) {
|
||||||
switch (platform) {
|
switch (platform) {
|
||||||
case "macos":
|
case "macos":
|
||||||
screenshotUrl = `/screenshot_desktop_mac_${colorScheme}.webp`;
|
screenshotUrl = `/screenshot_desktop_mac_${colorScheme}.webp`;
|
||||||
@ -65,6 +66,7 @@ function HeroSection() {
|
|||||||
screenshotUrl = `/screenshot_desktop_win_${colorScheme}.webp`;
|
screenshotUrl = `/screenshot_desktop_win_${colorScheme}.webp`;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Section className="hero-section">
|
<Section className="hero-section">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user