fix: make it work with new vite

This commit is contained in:
Max Richter
2026-01-10 19:28:09 +01:00
parent 694feb083d
commit 8d712322c0
66 changed files with 590 additions and 1544 deletions

View File

@@ -10,11 +10,8 @@ export default function Counter(props: CounterProps) {
props.count.value = Math.max(1, props.count.value);
return (
<div class="flex items-center px-1 py-2 rounded-xl">
<Button
class=""
onClick={() => props.count.value -= 1}
>
<TbCircleMinus />
<Button onClick={() => props.count.value -= 1}>
<TbCircleMinus class="h-6 w-6" />
</Button>
<input
class="text-3xl bg-transparent inline text-center -mx-4"
@@ -27,7 +24,7 @@ export default function Counter(props: CounterProps) {
}}
/>
<Button onClick={() => props.count.value += 1}>
<TbCirclePlus />
<TbCirclePlus class="h-6 w-6" />
</Button>
</div>
);

View File

@@ -4,7 +4,6 @@ import { useEventListener } from "@lib/hooks/useEventListener.ts";
import { menus } from "@islands/KMenu/commands.ts";
import { MenuEntry } from "@islands/KMenu/types.ts";
import * as icons from "@components/icons.tsx";
import { IS_BROWSER } from "fresh/runtime";
import { isKMenuOpen } from "@lib/kmenu.ts";
const KMenuEntry = (
{ entry, activeIndex, index }: {
@@ -155,17 +154,17 @@ export const KMenu = (
} else {
input.current?.blur();
}
}, IS_BROWSER ? document?.body : undefined);
}, typeof document !== "undefined" ? document?.body : undefined);
return (
<div
class={`${visible.value ? "opacity-100" : "opacity-0"} pointer-events-${
visible.value ? "auto" : "none"
class={`${visible.value ? "opacity-100" : "opacity-0"} ${
visible.value ? "pointer-events-auto" : "pointer-events-none"
} transition grid place-items-center w-full h-full fixed top-0 left-0 z-50`}
style={{ background: "#141217ee" }}
>
<div
class={`relative w-1/2 max-h-64 max-w-[400px] rounded-2xl shadow-2xl nnoisy-gradient overflow-hidden after:opacity-10 bg-gray-700`}
class={`relative w-1/2 max-h-64 max-w-100 rounded-2xl shadow-2xl nnoisy-gradient overflow-hidden after:opacity-10 bg-gray-700`}
style={{ background: "#2B2930", color: "#818181" }}
>
<div

View File

@@ -8,7 +8,7 @@ export function Link(
props: {
href?: string;
class?: string;
style?: preact.JSX.CSSProperties;
style?: preact.CSSProperties;
children: preact.ComponentChildren;
"data-thumb"?: string;
},