Initial commit

This commit is contained in:
2025-03-10 09:21:24 +01:00
commit 037b593c6b
44 changed files with 6411 additions and 0 deletions

View File

@ -0,0 +1,20 @@
<script lang="ts">
import { Input } from "flowbite-svelte";
let { value }: { value: Date } = $props();
const formatDateTimeLocal = (date: Date) => {
const pad = (num) => num.toString().padStart(2, "0");
return `${date.getFullYear()}-${pad(date.getMonth() + 1)}-${pad(date.getDate())}T${pad(date.getHours())}:${pad(date.getMinutes())}`;
};
</script>
<Input
type="datetime-local"
value={formatDateTimeLocal(value)}
onchange={(e) => {
// @ts-ignore
value = new Date(e.target.value);
}}
required
/>