Skip to content

Commit

Permalink
Fix editor form save bug
Browse files Browse the repository at this point in the history
  • Loading branch information
solomonhawk committed Nov 20, 2024
1 parent e1bc6da commit 9161df8
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -230,10 +230,10 @@ export function TableUpdateForm({

return (
<Form {...form}>
<Header table={table} />

<FlexCol asChild>
<form onSubmit={form.handleSubmit(handleSubmit)}>
<form onSubmit={form.handleSubmit(handleSubmit)} className="space-y-16">
<Header table={table} />

<FlexCol asChild role="presentation" onKeyDown={handleKeyDown}>
<fieldset
disabled={form.formState.isSubmitting || isDisabled}
Expand Down
2 changes: 1 addition & 1 deletion apps/web/src/features/table/pages/edit/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export function TableEdit() {
});

return (
<FlexCol className="space-y-16 p-12 sm:p-16">
<FlexCol className="p-12 sm:p-16">
<TableUpdateForm
table={table}
isDisabled={tableQuery.isPlaceholderData}
Expand Down
1 change: 1 addition & 0 deletions packages/ui/src/components/ui/button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
<Comp
className={cn(buttonVariants({ variant, size, className }))}
ref={ref}
type="button"
{...props}
/>
);
Expand Down

0 comments on commit 9161df8

Please sign in to comment.