Skip to content

Commit 438f91a

Browse files
committed
fix: april fools
this didn't work last year lmao
1 parent 9154213 commit 438f91a

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

src/routes/+layout.server.ts

Lines changed: 0 additions & 5 deletions
This file was deleted.

src/routes/+layout.svelte

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,9 @@
2626
import { m } from "$lib/paraglide/messages.js";
2727
import { log } from "$lib/util/logger.js";
2828
29-
let { children, data } = $props();
29+
let { children } = $props();
3030
let enablePlausible = $state(false);
31+
let isAprilFools = $state(false);
3132
3233
let scrollPositions = new Map<string, number>();
3334
@@ -67,6 +68,9 @@
6768
};
6869
6970
onMount(() => {
71+
const now = new Date();
72+
isAprilFools = now.getDate() === 1 && now.getMonth() === 3;
73+
7074
initAnimStores();
7175
7276
const handleResize = () => {
@@ -166,7 +170,7 @@
166170
src="{PUB_PLAUSIBLE_URL}/js/script.js"
167171
></script>
168172
{/if}
169-
{#if data.isAprilFools}
173+
{#if isAprilFools}
170174
<style>
171175
* {
172176
font-family: "Comic Sans MS", "Comic Sans", cursive !important;

0 commit comments

Comments
 (0)