Skip to content

Commit 1e3a538

Browse files
authored
chore: minor changes page component subscription (#1903)
* chore: minor changes * chore: add changelog
1 parent 4ce1431 commit 1e3a538

File tree

7 files changed

+193
-170
lines changed

7 files changed

+193
-170
lines changed

apps/status-page/src/app/(status-page)/[domain]/(public)/manage/[token]/page.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ export default function VerifyPage() {
9393
Manage your subscription to receive updates on the status page.
9494
</FormCardDescription>
9595
</FormCardHeader>
96-
<FormCardContent>
96+
<FormCardContent className="px-0">
9797
<FormManageSubscription
9898
id="manage-subscription-form"
9999
defaultValues={{

apps/status-page/src/app/(status-page)/[domain]/(public)/verify/[token]/page.tsx

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,26 @@ export default function VerifyPage() {
4141
>
4242
{title}
4343
</StatusBlankTitle>
44-
<StatusBlankLink
45-
href="../"
46-
disabled={verifyEmailMutation.isPending || !verifyEmailMutation.data}
47-
>
48-
Go back
49-
</StatusBlankLink>
44+
<div className="flex justify-center gap-2">
45+
<StatusBlankLink
46+
href="/"
47+
disabled={
48+
verifyEmailMutation.isPending || !verifyEmailMutation.data
49+
}
50+
>
51+
Go back
52+
</StatusBlankLink>
53+
{verifyEmailMutation.isSuccess && (
54+
<StatusBlankLink
55+
href={`/manage/${token}`}
56+
disabled={
57+
verifyEmailMutation.isPending || !verifyEmailMutation.data
58+
}
59+
>
60+
Manage
61+
</StatusBlankLink>
62+
)}
63+
</div>
5064
</StatusBlankContent>
5165
</StatusBlankContainer>
5266
);

apps/status-page/src/components/forms/form-card.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,8 @@ import { cn } from "@openstatus/ui/lib/utils";
1111

1212
import { type VariantProps, cva } from "class-variance-authority";
1313

14-
// py-0
1514
const formCardVariants = cva(
16-
"group relative w-full overflow-hidden py-0 shadow-none gap-4",
15+
"group relative w-full overflow-hidden py-0 shadow-none gap-4 rounded-lg",
1716
{
1817
variants: {
1918
variant: {

apps/status-page/src/components/forms/form-manage-subscription.tsx

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ export function FormManageSubscription({
8787
control={form.control}
8888
name="subscribeComponents"
8989
render={({ field }) => (
90-
<FormItem className="flex items-center gap-2">
90+
<FormItem className="flex items-center gap-2 px-4">
9191
<FormControl>
9292
<Checkbox
9393
checked={field.value}
@@ -108,7 +108,10 @@ export function FormManageSubscription({
108108
if (tracker.type === "group") {
109109
const groupIds = tracker.components.map((c) => c.id);
110110
return (
111-
<div key={tracker.groupId} className="flex flex-col gap-2">
111+
<div
112+
key={tracker.groupId}
113+
className="flex flex-col gap-2 px-4"
114+
>
112115
<FormField
113116
control={form.control}
114117
name="pageComponents"
@@ -189,7 +192,7 @@ export function FormManageSubscription({
189192
control={form.control}
190193
name="pageComponents"
191194
render={({ field }) => (
192-
<FormItem className="flex items-center gap-2">
195+
<FormItem className="flex items-center gap-2 px-4">
193196
<FormControl>
194197
<Checkbox
195198
checked={field.value?.includes(
@@ -219,7 +222,7 @@ export function FormManageSubscription({
219222
);
220223
})
221224
) : (
222-
<StatusBlankContainer>
225+
<StatusBlankContainer className="px-4">
223226
<StatusBlankTitle>
224227
No components to subscribe to
225228
</StatusBlankTitle>

0 commit comments

Comments
 (0)