fix: make TextInput give value for onInput argument

This commit is contained in:
2026-08-24 11:07:22 +02:00
parent 93fc75b59b
commit 0251c94d8f
3 changed files with 4 additions and 5 deletions
@@ -299,8 +299,7 @@
labelText={$t("pages.admin.charges.headers.amount")}
helperText={$t("pages.admin.charges.create.fields.amountHelper")}
required={true}
onInput={(e) =>
onAmountInput(e.target instanceof HTMLInputElement ? e.target.value : "")}
onInput={(value) => onAmountInput(value.toString())}
onBlur={onAmountBlur}
/>
<Select
@@ -28,7 +28,7 @@
labelText?: string;
helperText?: string;
error?: string;
onInput?: (event: Event) => void;
onInput?: (value: string | number) => void;
onBlur?: (event?: FocusEvent) => void;
onFocus?: (event?: FocusEvent) => void;
} = $props();
@@ -55,7 +55,7 @@
id={finalId}
onblur={onBlur}
onfocus={onFocus}
oninput={onInput}
oninput={() => onInput?.(value)}
{name}
{type}
{required}
@@ -85,7 +85,7 @@
placeholder={$t("pages.project.edit.campaignInfo.media.videoPlaceholder")}
bind:value={videoUrl}
error={validationError}
onInput={(e) => handleUrlChange((e.target as HTMLInputElement).value)}
onInput={(value) => handleUrlChange(value.toString())}
/>
{/if}
</div>