diff --git a/frontend/src/i18n/locales/en.json b/frontend/src/i18n/locales/en.json index 727cc96eb0..42ad7501a4 100644 --- a/frontend/src/i18n/locales/en.json +++ b/frontend/src/i18n/locales/en.json @@ -355,6 +355,8 @@ "submit": "Create account", "creating": "Creating account...", "alreadyHaveAccount": "Already have an account?", + "terms": "Terms", + "privacy": "Privacy Policy", "errors": { "failed": "Registration failed." }, @@ -1039,6 +1041,8 @@ "twitter": "X / Twitter", "legal": "Legal", "license": "License (Apache-2.0)", + "terms": "Terms", + "privacy": "Privacy", "copyright": "© {{year}} Commonly. Code licensed under Apache-2.0; the Commonly name and logo are trademarks of the Commonly project." } }, diff --git a/frontend/src/i18n/locales/zh-CN.json b/frontend/src/i18n/locales/zh-CN.json index e9260fe305..c649d09010 100644 --- a/frontend/src/i18n/locales/zh-CN.json +++ b/frontend/src/i18n/locales/zh-CN.json @@ -355,6 +355,8 @@ "submit": "注册", "creating": "正在注册…", "alreadyHaveAccount": "已有账号?", + "terms": "服务条款", + "privacy": "隐私政策", "errors": { "failed": "注册失败。" }, @@ -1038,6 +1040,8 @@ "twitter": "X / Twitter", "legal": "法律信息", "license": "许可证(Apache-2.0)", + "terms": "服务条款", + "privacy": "隐私政策", "copyright": "© {{year}} Commonly。代码采用 Apache-2.0 许可;Commonly 名称和标志是 Commonly 项目的商标。" } }, diff --git a/frontend/src/v2/__tests__/V2Register.test.tsx b/frontend/src/v2/__tests__/V2Register.test.tsx index 6c303f46d1..0030d559b3 100644 --- a/frontend/src/v2/__tests__/V2Register.test.tsx +++ b/frontend/src/v2/__tests__/V2Register.test.tsx @@ -220,6 +220,13 @@ describe('V2Register', () => { // a stranger with no code read hosting as locked. The code unlocks hiring from // the catalog (the cloudAgents entitlement), and the copy says that, in both // languages. + it('links the signup form to the public Terms and Privacy pages (TASK-530)', async () => { + renderRegister(); + + expect(await screen.findByRole('link', { name: 'Terms' })).toHaveAttribute('href', '/terms'); + expect(screen.getByRole('link', { name: 'Privacy Policy' })).toHaveAttribute('href', '/privacy'); + }); + it('never tells a stranger the invitation code unlocks hosting', async () => { renderRegister(); diff --git a/frontend/src/v2/components/V2Register.tsx b/frontend/src/v2/components/V2Register.tsx index ba14429a24..c9cd3bbec9 100644 --- a/frontend/src/v2/components/V2Register.tsx +++ b/frontend/src/v2/components/V2Register.tsx @@ -244,6 +244,11 @@ const V2Register: React.FC = () => { {' '} {t('auth.login.submit')} +
+ {t('auth.register.terms')} + {' · '} + {t('auth.register.privacy')} +
); diff --git a/frontend/src/v2/landing/V2LandingPage.tsx b/frontend/src/v2/landing/V2LandingPage.tsx index eaa8b11ea1..66eb936c5e 100644 --- a/frontend/src/v2/landing/V2LandingPage.tsx +++ b/frontend/src/v2/landing/V2LandingPage.tsx @@ -964,6 +964,8 @@ const V2LandingPage: React.FC = () => {
{t('landing.footer.legal')}
+ {t('landing.footer.terms')} + {t('landing.footer.privacy')} {t('landing.footer.license')}