Skip to content

Commit ac573dc

Browse files
author
Deepak Pandey
committed
Fix OAuth redirect and improve complete-profile UI
- Fix OAuth redirect to localhost by adding queryParams to Google sign-in - Improve input text visibility in complete-profile page: - Remove backdrop-blur and semi-transparent backgrounds - Change text color from gray-900 to black with font-medium - Fix username validation styling (remove opacity from success/error states) - Ensure OAuth flow works correctly for local development - Maintain production OAuth functionality
1 parent 6db17d6 commit ac573dc

File tree

2 files changed

+10
-6
lines changed

2 files changed

+10
-6
lines changed

app/auth/signin/page.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,10 @@ function SignInForm() {
9494
redirectTo: typeof window !== "undefined"
9595
? `${window.location.origin}/auth/callback?returnUrl=${encodeURIComponent(returnUrl)}`
9696
: undefined,
97+
queryParams: {
98+
access_type: 'offline',
99+
prompt: 'consent',
100+
},
97101
},
98102
});
99103
} catch (error) {

app/complete-profile/page.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ export default function CompleteProfile() {
271271
<div className="flex justify-center mb-6">
272272
<CodeuniaLogo size="lg" showText={true} noLink={true} instanceId="complete-profile" />
273273
</div>
274-
<h1 className="text-2xl font-bold text-gray-900 mb-3">
274+
<h1 className="text-2xl font-bold text-black font-medium mb-3">
275275
Welcome! Let&apos;s set up your profile
276276
</h1>
277277
<p className="text-gray-600 leading-relaxed">
@@ -290,7 +290,7 @@ export default function CompleteProfile() {
290290
type="text"
291291
value={firstName}
292292
onChange={(e) => setFirstName(e.target.value)}
293-
className="w-full border border-gray-200 rounded-xl px-4 py-3 text-sm bg-white/50 backdrop-blur-sm focus:outline-none focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 transition-all duration-200 placeholder:text-gray-400 text-gray-900"
293+
className="w-full border border-gray-200 rounded-xl px-4 py-3 text-sm bg-white focus:outline-none focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 transition-all duration-200 placeholder:text-gray-400 text-black font-medium"
294294
placeholder="Enter your first name"
295295
required
296296
/>
@@ -305,7 +305,7 @@ export default function CompleteProfile() {
305305
type="text"
306306
value={lastName}
307307
onChange={(e) => setLastName(e.target.value)}
308-
className="w-full border border-gray-200 rounded-xl px-4 py-3 text-sm bg-white/50 backdrop-blur-sm focus:outline-none focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 transition-all duration-200 placeholder:text-gray-400 text-gray-900"
308+
className="w-full border border-gray-200 rounded-xl px-4 py-3 text-sm bg-white focus:outline-none focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 transition-all duration-200 placeholder:text-gray-400 text-black font-medium"
309309
placeholder="Enter your last name"
310310
required
311311
/>
@@ -322,11 +322,11 @@ export default function CompleteProfile() {
322322
type="text"
323323
value={username}
324324
onChange={(e) => handleUsernameChange(e.target.value)}
325-
className={`w-full border rounded-xl px-4 py-3 pr-20 text-sm bg-white/50 backdrop-blur-sm focus:outline-none focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 transition-all duration-200 placeholder:text-gray-400 text-gray-900 ${
325+
className={`w-full border rounded-xl px-4 py-3 pr-20 text-sm bg-white focus:outline-none focus:ring-2 focus:ring-blue-500/20 focus:border-blue-500 transition-all duration-200 placeholder:text-gray-400 text-black font-medium ${
326326
usernameAvailable === true
327-
? 'border-green-300 bg-green-50/50'
327+
? 'border-green-300 bg-green-50'
328328
: usernameAvailable === false || usernameError
329-
? 'border-red-300 bg-red-50/50'
329+
? 'border-red-300 bg-red-50'
330330
: 'border-gray-200'
331331
}`}
332332
placeholder="Enter your username"

0 commit comments

Comments
 (0)