Skip to content

Commit 9eda222

Browse files
committed
fix: update field ux
1 parent 0cef3e4 commit 9eda222

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

apps/frontend/src/lib/components/blocks/update-field/update-field.svelte

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,15 +64,15 @@
6464
onSubmit(input) {
6565
validateForm({ update: true })
6666
},
67-
onUpdate(event) {
67+
async onUpdate(event) {
6868
if (!event.form.valid) {
6969
console.log(event.form.errors, event.form.data)
7070
return
7171
}
7272
const data = event.form.data
7373
const field = FieldFactory.fromJSON(data).toJSON()
7474
75-
$updateFieldMutation.mutate({
75+
await $updateFieldMutation.mutateAsync({
7676
tableId: $table.id.value,
7777
field,
7878
})
@@ -125,7 +125,7 @@
125125
{#if $updateFieldMutation.isPending}
126126
<LoaderCircleIcon class="mr-2 h-5 w-5 animate-spin" />
127127
{:else}
128-
<PencilIcon class="mr-2 h-5 w-5" />
128+
<PencilIcon class="mr-2 h-4 w-4" />
129129
{/if}
130130
Update Field
131131
</Button>

0 commit comments

Comments
 (0)