fix: regular-weight consent text and balanced state headings on visitor pages

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01EFUzfj5akPxyikzGc2iAHM
This commit is contained in:
ngqileandClaude Opus 5.5 committed 2026-12-01 23:17:52 +08:00
1 parent 370c9f4ad0
commit 372cd7244e
3 files changed
+7 -2

No files matched your search

@@ -24,4 +24,9 @@ describe("RegistrationForm look", () => {
expect(screen.getByText("English text").parentElement?.className).toContain("text-muted-foreground");
expect(screen.getByText("Teks Melayu")).toBeTruthy();
});
it("sets the consent sentences in regular weight", () => {
wrap(<RegistrationForm {...props} />);
expect(screen.getByText(/I agree to INS/).closest("span[class*=space-y]")).toHaveClass("font-normal");
});
});
@@ -126,7 +126,7 @@ export function RegistrationForm({ tooManyKey, info, initial, submit, onDone, on
</div>
<Label htmlFor="reg-consent" className={CONSENT_ROW}>
<Checkbox id="reg-consent" className={`${BOX} mt-0.5`} checked={form.consent} onCheckedChange={(on) => set({ consent: on === true })} aria-invalid={!!errors.consent} aria-describedby={errors.consent ? "reg-consent-error" : undefined} />
<span className="space-y-1">
<span className="space-y-1 font-normal">
<span className="block">{t("RegConsentEn", { company: info.companyName })}</span>
<span className="block">{t("RegConsentMs", { company: info.companyName })}</span>
</span>
@@ -50,7 +50,7 @@ export function VisitorState({ icon: Icon, heading, text, action, role, tone = "
<span className={`flex size-12 items-center justify-center rounded-full ${tone === "error" ? "bg-destructive/10 text-destructive" : "bg-accent text-accent-foreground"}`}>
<Icon className="size-6" aria-hidden="true" />
</span>
<Heading className="text-lg font-semibold">{heading}</Heading>
<Heading className="text-lg font-semibold text-balance">{heading}</Heading>
{text && <p className="text-sm text-muted-foreground">{text}</p>}
{action}
</div>