Skip to content

Commit 1ba2342

Browse files
authored
fix(dashboard): subscribers form submission (#7981)
1 parent 5af1d21 commit 1ba2342

File tree

3 files changed

+10
-3
lines changed

3 files changed

+10
-3
lines changed

apps/dashboard/src/components/subscribers/create-subscriber-form.tsx

+1
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ export const CreateSubscriberForm = (props: CreateSubscriberFormProps) => {
7676
noValidate
7777
onSubmit={form.handleSubmit(onSubmit)}
7878
className="flex h-full flex-col overflow-y-auto"
79+
id="create-subscriber"
7980
>
8081
<div className="flex flex-col items-stretch gap-6 p-5">
8182
<div className="flex items-center gap-3">

apps/dashboard/src/components/subscribers/subscriber-overview-form.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ const basicSetup = { lineNumbers: true, defaultKeymap: true };
3737
const toastOptions: ExternalToast = {
3838
position: 'bottom-right',
3939
classNames: {
40-
toast: 'mb-4 right-0',
40+
toast: 'mb-4 right-0 pointer-events-none',
4141
},
4242
};
4343

apps/dashboard/src/pages/create-subscriber.tsx

+8-2
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import { ExternalToast } from 'sonner';
2020
const toastOptions: ExternalToast = {
2121
position: 'bottom-right',
2222
classNames: {
23-
toast: 'mb-4 right-0',
23+
toast: 'mb-4 right-0 pointer-events-none',
2424
},
2525
};
2626

@@ -96,7 +96,13 @@ export function CreateSubscriberPage() {
9696
</Link>
9797
</span>
9898
</div>
99-
<Button variant="secondary" type="submit" disabled={isPending} isLoading={isPending}>
99+
<Button
100+
variant="secondary"
101+
type="submit"
102+
disabled={isPending}
103+
isLoading={isPending}
104+
form="create-subscriber"
105+
>
100106
Create subscriber
101107
</Button>
102108
</div>

0 commit comments

Comments
 (0)