Skip to content

Commit 0bbb34b

Browse files
committed
refactor(form): use v-model for data and enable reset button
1 parent 83bf073 commit 0bbb34b

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

app/assets/sass/form.scss

+4
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,7 @@
1313
}
1414
}
1515
}
16+
17+
.p-formkit-data-debug {
18+
padding-top: 1rem;
19+
}

app/pages/form/index.vue

+3-1
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,9 @@ async function submitHandler() {
128128

129129
<div v-if="data" class="min-w-25rem">
130130
<FormKitDataEdit
131-
:schema="schema" :data="data"
131+
v-model="data"
132+
:schema="schema"
133+
:show-reset="true"
132134
:debug-schema="false" :debug-data="true"
133135
:submit-label="t('save')"
134136
@data-saved="submitHandler"

0 commit comments

Comments
 (0)