refactor(auth): refresh auth entry layout#192
Conversation
# Conflicts: # frontend/src/features/auth/components/layout/AuthLayout.tsx # frontend/src/features/auth/screens/AuthPages.scss
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f862857c15
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| <AuthProviderButton | ||
| label={t("auth.login.schoolAuth", "學校認證")} | ||
| variant="sso" | ||
| onClick={() => navigate(buildAuthLink("/register/campus-sso"))} |
There was a problem hiding this comment.
Filter registration SSO choices to supported providers
When auth options contain multiple campus providers and only some have supports_registration: true, this new registration button sends users to /register/campus-sso, but CampusSsoScreen still renders every provider with category === "campus"; since the OAuth callback creates or links users without checking supports_registration, login-only campus providers become selectable for account creation. The registration flow needs to pass/filter the supported providers on this screen before exposing them.
Useful? React with 👍 / 👎.
變更目標
/register/campus-sso再選學校,避免直接展開 NYCU provider。AuthPages.scss的大型 SCSS 拆成 layout/forms/providers/callback,並收斂重複 mobile screen 特例。非目標
影響範圍
frontend/src/features/auth/**frontend/src/i18n/locales/*/common.json驗證
npm test -- AuthProviderOptionsScreen.test.tsx:通過,7 tests。npm run check:i18n:通過。bash .codex/skills/qjudge-quality-gates-owner/scripts/check-carbon-style.sh:通過。npm run build:通過;仍有既有_scrollbar.scssslash-div deprecation 與 chunk size warning。node .codex/skills/qjudge-quality-gates-owner/scripts/lint-architecture.js --root frontend/src:通過。node .codex/skills/qjudge-quality-gates-owner/scripts/lint-naming.js --root frontend/src:失敗於 repo-wide 既有命名違規,未指向本次新增 auth SCSS 檔。風險與回滾