Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions frontend/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ module.exports = {
'src/v2/components/V2ResetPassword.tsx',
'src/v2/components/V2OAuthButtons.tsx',
'src/v2/components/V2OAuthComplete.tsx',
'src/v2/components/V2DiscordCallback.tsx',
'src/v2/components/V2DeleteAccount.tsx',
'src/v2/components/V2InviteRedeem.tsx',
'src/components/RegistrationInviteRequired.tsx',
Expand Down
8 changes: 4 additions & 4 deletions frontend/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ import { V2PrivacyPage, V2TermsPage } from './v2/legal/V2LegalPage';
const GuidePage = React.lazy(() => import('./components/landing/GuidePage'));
const GuidesIndexPage = React.lazy(() => import('./components/landing/GuidesIndexPage'));
const UseCasePage = React.lazy(() => import('./components/landing/UseCasePage'));
const DiscordCallback = React.lazy(() => import('./components/DiscordCallback'));
const V2DiscordCallback = React.lazy(() => import('./v2/components/V2DiscordCallback'));
const V2App = React.lazy(() => import('./v2/V2App'));
const V2LandingPage = React.lazy(() => import('./v2/landing/V2LandingPage'));
const V2CliAuthorize = React.lazy(() => import('./v2/components/V2CliAuthorize'));
Expand Down Expand Up @@ -310,9 +310,9 @@ function App(): React.ReactElement {
answers with `verifyUrl: <origin>/cli/authorize`. Deleting this
route 404'd every `commonly login` (#1534, 2026-09-04 → 09-08). */}
<Route path="/cli/authorize" element={<V2CliAuthorize />} />
<Route path="/discord/callback" element={<DiscordCallback />} />
<Route path="/discord/success" element={<DiscordCallback type="success" />} />
<Route path="/discord/error" element={<DiscordCallback type="error" />} />
<Route path="/discord/callback" element={<V2DiscordCallback />} />
<Route path="/discord/success" element={<V2DiscordCallback type="success" />} />
<Route path="/discord/error" element={<V2DiscordCallback type="error" />} />
</Routes>
</Suspense>
</div>
Expand Down
225 changes: 0 additions & 225 deletions frontend/src/components/DiscordCallback.tsx

This file was deleted.

22 changes: 20 additions & 2 deletions frontend/src/i18n/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -429,8 +429,26 @@
"continueWith": "Continue with {{provider}}"
},
"oauthComplete": {
"title": "Signing you in…",
"subtitle": "Completing sign-in with your provider."
"title": "Signing you in…"
},
"discordHandoff": {
"workingTitle": "Connecting Discord…",
"doneTitle": "Pick a channel",
"connectedTitle": "Discord connected",
"errorTitle": "Discord didn't connect",
"errorFallback": "Something went wrong during Discord authorization.",
"server": "Server",
"channel": "Channel",
"choose": "Choose a channel",
"loadingChannels": "Loading channels…",
"cancel": "Cancel",
"connect": "Connect",
"connecting": "Connecting…",
"back": "Back",
"pickChannel": "Please select a channel",
"channelsFailed": "Failed to fetch server channels",
"createFailed": "Failed to create integration",
"created": "Discord integration created successfully!"
},
"forgot": {
"title": "Reset your password",
Expand Down
22 changes: 20 additions & 2 deletions frontend/src/i18n/locales/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -428,8 +428,26 @@
"continueWith": "使用 {{provider}} 继续"
},
"oauthComplete": {
"title": "正在登录…",
"subtitle": "正在完成第三方账号登录。"
"title": "正在登录…"
},
"discordHandoff": {
"workingTitle": "正在连接 Discord…",
"doneTitle": "选择一个频道",
"connectedTitle": "Discord 已连接",
"errorTitle": "Discord 连接失败",
"errorFallback": "Discord 授权时出了问题。",
"server": "服务器",
"channel": "频道",
"choose": "选择频道",
"loadingChannels": "正在加载频道…",
"cancel": "取消",
"connect": "连接",
"connecting": "正在连接…",
"back": "返回",
"pickChannel": "请选择一个频道",
"channelsFailed": "没能获取服务器的频道",
"createFailed": "没能创建集成",
"created": "Discord 集成已创建。"
},
"forgot": {
"title": "重置密码",
Expand Down
8 changes: 5 additions & 3 deletions frontend/src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,13 @@ if (process.env.REACT_APP_SENTRY_DSN) {
// and a class added in V2App's useEffect wins only AFTER first paint, so
// every v2 load still flashed dark for a frame (Sam, 2026-08-24). '/' and
// '/v2*' are the v2 front door (and /cli/authorize, a v2 page mounted outside
// V2App that keeps the class itself); V2App's effect keeps the class in sync for
// SPA navigation after boot. Legacy deep links that redirect into /v2 may
// V2App that keeps the class itself; and the /discord/* return pages, which
// redirect into /v2 on the first effect); V2App's effect keeps the class in
// sync for SPA navigation after boot. Legacy deep links that redirect into /v2 may
// still flash once — the exception, not the entry path.
const bootPath = window.location.pathname;
if (bootPath === '/' || bootPath.startsWith('/v2') || /^\/cli\/authorize\/?$/.test(bootPath)) {
if (bootPath === '/' || bootPath.startsWith('/v2') || /^\/cli\/authorize\/?$/.test(bootPath)
|| /^\/discord\/(?:callback|success|error)\/?$/.test(bootPath)) {
document.body.classList.add('v2-canvas');
}
if (bootPath === '/guides' || bootPath.startsWith('/guides/')) {
Expand Down
8 changes: 4 additions & 4 deletions frontend/src/v2/V2App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import { useAuth } from '../context/AuthContext';
import { useTimeZoneCapture } from './hooks/useTimeZoneCapture';
import RegistrationInviteRequired from '../components/RegistrationInviteRequired';
import VerifyEmail from '../components/VerifyEmail';
import DiscordCallback from '../components/DiscordCallback';
import V2EmailVerificationBanner from './components/V2EmailVerificationBanner';
import ProtectedRoute from '../components/ProtectedRoute';
import '@fontsource-variable/bricolage-grotesque';
Expand Down Expand Up @@ -42,6 +41,7 @@ const V2Login = React.lazy(() => import('./components/V2Login'));
const V2PrimitivesPage = React.lazy(() => import('./primitives/V2PrimitivesPage'));
const V2Register = React.lazy(() => import('./components/V2Register'));
const V2OAuthComplete = React.lazy(() => import('./components/V2OAuthComplete'));
const V2DiscordCallback = React.lazy(() => import('./components/V2DiscordCallback'));
const V2ForgotPassword = React.lazy(() => import('./components/V2ForgotPassword'));
const V2ResetPassword = React.lazy(() => import('./components/V2ResetPassword'));
const V2YourTeamPage = React.lazy(() => import('./components/V2YourTeamPage'));
Expand Down Expand Up @@ -260,9 +260,9 @@ const V2App: React.FC = () => {
<Route path="forgot-password" element={<V2ForgotPassword />} />
<Route path="reset-password" element={<V2ResetPassword />} />
<Route path="verify-email" element={<VerifyEmail />} />
<Route path="discord/callback" element={<DiscordCallback />} />
<Route path="discord/success" element={<DiscordCallback type="success" />} />
<Route path="discord/error" element={<DiscordCallback type="error" />} />
<Route path="discord/callback" element={<V2DiscordCallback />} />
<Route path="discord/success" element={<V2DiscordCallback type="success" />} />
<Route path="discord/error" element={<V2DiscordCallback type="error" />} />
{/* Community access is resolved by the membership-gated pod probe.
Keep this outside V2RequireAuth so an anonymous 401 can fall
through to the public invite preview instead of the login wall. */}
Expand Down
Loading
Loading