+3
-6
src/layout.tsx
+3
-6
src/layout.tsx
···
1
-
import { createEffect, ErrorBoundary, onMount, Show, Suspense } from "solid-js";
1
+
import { createEffect, ErrorBoundary, Show, Suspense } from "solid-js";
2
2
import { A, RouteSectionProps, useLocation, useParams } from "@solidjs/router";
3
3
import { loginState } from "./components/login.jsx";
4
4
import { RecordEditor } from "./components/create.jsx";
···
15
15
const Layout = (props: RouteSectionProps<unknown>) => {
16
16
const params = useParams();
17
17
const location = useLocation();
18
-
19
-
onMount(() => {
20
-
if (location.search.includes("kawaii=true")) localStorage.kawaii = "true";
21
-
});
18
+
if (location.search.includes("kawaii=true")) localStorage.kawaii = "true";
22
19
23
20
createEffect(async () => {
24
21
if (params.repo && !params.repo.startsWith("did:")) {
···
47
44
<A href="/" class="font-mono font-bold hover:underline">
48
45
PDSls
49
46
</A>
50
-
<Show when={location.search.includes("kawaii=true") || kawaii()}>
47
+
<Show when={localStorage.kawaii === "true" || kawaii()}>
51
48
<a
52
49
href="https://bsky.app/profile/ninikyuu.bsky.social/post/3l3tq5xwqf22o"
53
50
target="_blank"