Skip to content

Commit 04f767e

Browse files
committed
fix(types): adjust input action typing
Signed-off-by: Vitor Mattos <1079143+vitormattos@users.noreply.github.com>
1 parent 08758a1 commit 04f767e

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

src/components/InputAction/InputAction.vue

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
- SPDX-License-Identifier: AGPL-3.0-or-later
44
-->
55
<template>
6-
<form @submit="e => e.preventDefault()">
6+
<form @submit="onFormSubmit">
77
<input v-model="value"
88
class="input__input"
99
:placeholder="placeholder"
@@ -43,13 +43,18 @@ function clearInput() {
4343
value.value = ''
4444
}
4545
46+
function onFormSubmit(event: SubmitEvent) {
47+
event.preventDefault()
48+
}
49+
4650
function onSubmit() {
4751
emit('submit', value.value)
4852
}
4953
5054
defineExpose({
5155
value,
5256
clearInput,
57+
onFormSubmit,
5358
onSubmit,
5459
})
5560
</script>

0 commit comments

Comments
 (0)