diff --git a/src/app/dashboard/page.tsx b/src/app/dashboard/page.tsx index 3e8c1f6..bcf7975 100644 --- a/src/app/dashboard/page.tsx +++ b/src/app/dashboard/page.tsx @@ -6,6 +6,8 @@ import { UserButton } from "@clerk/nextjs"; import CopyButton from "@/components/CopyButton"; import DeleteMonumentButton from "@/components/DeleteMonumentButton"; import DeleteImageButton from "@/components/DeleteImageButton"; +import { generateMonumentQR } from "@/lib/qrcode"; +import { APP_DOMAIN } from "@/lib/config"; export default async function DashboardPage() { const { userId } = await auth(); @@ -20,7 +22,8 @@ export default async function DashboardPage() { redirect("/onboarding"); } - const monumentUrl = `https://${user.subdomain}.${process.env.NEXT_PUBLIC_APP_DOMAIN}`; + const monumentUrl = `https://${user.subdomain}.${APP_DOMAIN}`; + const qrCode = await generateMonumentQR(user.subdomain); return (
@@ -62,13 +67,13 @@ export default function SubdomainPicker({ value, onChange }: SubdomainPickerPropПроверка на достапност...
} {!checking && available === true && ( -✓ {slug}.testbed.mk е достапен!
+✓ {slug}.{APP_DOMAIN} е достапен!
)} {!checking && available === false && (✗ Овој поддомен е веќе зафатен.
)} - {!checking && available === null && slug.length > 0 && slug.length < 3 && ( -Потребни се најмалку 3 карактери.
+ {!checking && available === null && slug.length > 0 && slug.length < SUBDOMAIN_MIN_LENGTH && ( +Потребни се најмалку {SUBDOMAIN_MIN_LENGTH} карактери.
)}- {dates} -
- )} -{dates}
- )} - -- {data.description} -
-- {dates} -
- )} - {data.description && ( -- {data.description} -
- )} -{dates}
- )} - {data.description && ( -- {data.description} -
- )} -{dates}
- )} - - -- {data.description} -
-+ {dates} +
+ )} + {data.description && ( ++ {data.description} +
+ )} +{dates}
+ )} + {data.description && ( ++ {data.description} +
+ )} ++ {dates} +
+ )} +{dates}
+ )} + ++ {data.description} +
+{dates}
+ )} + + ++ {data.description} +
+