From fb9e7bb85602ecec1f83cd148dffbfb5e99d5714 Mon Sep 17 00:00:00 2001 From: Romain Hamel Date: Mon, 30 Jun 2025 15:04:52 +0200 Subject: [PATCH] feat(Input/Textarea): add `default-value` prop (#4404) Co-authored-by: Benjamin Canac --- src/runtime/components/Input.vue | 26 ++++++++++++++------------ src/runtime/components/Textarea.vue | 25 ++++++++++++++----------- 2 files changed, 28 insertions(+), 23 deletions(-) diff --git a/src/runtime/components/Input.vue b/src/runtime/components/Input.vue index f7a111ba..52c1c526 100644 --- a/src/runtime/components/Input.vue +++ b/src/runtime/components/Input.vue @@ -8,7 +8,7 @@ import type { AcceptableValue, ComponentConfig } from '../types/utils' type Input = ComponentConfig -export interface InputProps extends UseComponentIconsProps { +export interface InputProps extends UseComponentIconsProps { /** * The element or component this component should render as. * @defaultValue 'div' @@ -38,6 +38,8 @@ export interface InputProps extends UseComponentIconsProps { disabled?: boolean /** Highlight the ring color like a focus state. */ highlight?: boolean + modelValue?: T + defaultValue?: T modelModifiers?: { string?: boolean number?: boolean @@ -65,6 +67,7 @@ export interface InputSlots {