feat(frontend): add loading prop to FormField component

When loading is true, adds 'is-loading' class to the input element.
This commit is contained in:
kolaente
2026-01-10 21:12:44 +01:00
parent 1ea8a3cdba
commit bb16500cb5

View File

@@ -7,6 +7,7 @@ interface Props {
error?: string | null
id?: string
disabled?: boolean
loading?: boolean
}
const props = defineProps<Props>()
@@ -36,7 +37,10 @@ const controlClasses = computed(() => [
const inputClasses = computed(() => [
'input',
{'disabled': props.disabled},
{
'disabled': props.disabled,
'is-loading': props.loading,
},
])
// Only bind value when modelValue is explicitly provided (not undefined)