38 lines
1.6 KiB
Plaintext
38 lines
1.6 KiB
Plaintext
page CaptchaGate {
|
|
state returnTo = ctx.url.searchParams.get("returnTo") || "/protected"
|
|
|
|
seo {
|
|
title = "Complete security verification"
|
|
robots = "noindex,nofollow"
|
|
}
|
|
|
|
view {
|
|
<main class="grid min-h-screen place-items-center bg-[var(--wire-color-bg)] px-4 py-10 text-[var(--wire-color-text)]">
|
|
<form
|
|
method="post"
|
|
action="/api/page-grant"
|
|
class="w-full max-w-xl rounded-2xl border border-[var(--wire-color-border)] bg-[var(--wire-color-surface)] p-5 shadow-[var(--wire-shadow-1)] sm:p-7"
|
|
>
|
|
<input type="hidden" name="returnTo" value='{returnTo}' />
|
|
|
|
<p class="mb-2 text-sm font-semibold text-[var(--wire-color-primary)]">Protected page</p>
|
|
<h1 class="m-0 text-2xl font-bold">Confirm you are human</h1>
|
|
<p class="mb-5 mt-2 text-sm leading-6 text-[var(--wire-color-muted)]">Complete this once to access protected showcase pages for 15 minutes.</p>
|
|
|
|
<Captcha
|
|
endpoint="/api/captcha/challenge"
|
|
verifyEndpoint="/api/captcha/verify"
|
|
type="alphanumeric"
|
|
action="protected-page-access"
|
|
disturbance="50"
|
|
required="true"
|
|
/>
|
|
|
|
<button type="submit" class="mt-4 h-11 w-full rounded-[var(--wire-radius-sm)] bg-[var(--wire-color-primary)] px-5 font-semibold text-[var(--wire-color-primary-contrast)]">
|
|
Continue to protected page
|
|
</button>
|
|
</form>
|
|
</main>
|
|
}
|
|
}
|