zenno: format

This commit is contained in:
2026-03-31 12:07:38 -04:00
parent 08deedea8f
commit 22ca5c98f3
15 changed files with 196 additions and 179 deletions
+17 -17
View File
@@ -1,25 +1,25 @@
<script lang="ts">
import { character } from '$lib/data/character'
import { character } from '$lib/data/character';
interface Props {
id: string
value: number
label?: string
region?: keyof typeof character
required?: boolean
}
interface Props {
id: string;
value: number;
label?: string;
region?: keyof typeof character;
required?: boolean;
}
let { id, value = $bindable(), label, region = 'global', required = false }: Props = $props()
let { id, value = $bindable(), label, region = 'global', required = false }: Props = $props();
</script>
{#if label}
<label for={id}>{label}</label>
<label for={id}>{label}</label>
{/if}
<select id={id} bind:value={value} required={required}>
{#if !required}
<option value=0></option>
{/if}
{#each character[region] as c}
<option value={c.chara_id}>{c.name}</option>
{/each}
<select {id} bind:value {required}>
{#if !required}
<option value="0"></option>
{/if}
{#each character[region] as c}
<option value={c.chara_id}>{c.name}</option>
{/each}
</select>