diff --git a/app/complete-profile/page.tsx b/app/complete-profile/page.tsx index 808a8eac..448d8a9a 100644 --- a/app/complete-profile/page.tsx +++ b/app/complete-profile/page.tsx @@ -68,6 +68,9 @@ export default function CompleteProfile() { if (profile.first_name) setFirstName(profile.first_name); if (profile.last_name) setLastName(profile.last_name); if (profile.username) setUsername(profile.username); + } else { + // Profile is null, which means there was an error but we can continue + console.log('Profile not found, continuing with form setup'); } } catch (profileError) { console.error('Error checking profile:', profileError); @@ -283,14 +286,14 @@ export default function CompleteProfile() { - setFirstName(e.target.value)} - 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" - placeholder="Enter your first name" - required - /> + setFirstName(e.target.value)} + 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" + placeholder="Enter your first name" + required + /> {/* Last Name */} @@ -298,14 +301,14 @@ export default function CompleteProfile() { - setLastName(e.target.value)} - 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" - placeholder="Enter your last name" - required - /> + setLastName(e.target.value)} + 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" + placeholder="Enter your last name" + required + /> {/* Username Input */} @@ -315,23 +318,23 @@ export default function CompleteProfile() {
- handleUsernameChange(e.target.value)} - 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 ${ - usernameAvailable === true - ? 'border-green-300 bg-green-50/50' - : usernameAvailable === false || usernameError - ? 'border-red-300 bg-red-50/50' - : 'border-gray-200' - }`} - placeholder="Enter your username" - minLength={3} - maxLength={30} - title="Username can only contain letters, numbers, hyphens, and underscores" - required - /> + handleUsernameChange(e.target.value)} + 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 ${ + usernameAvailable === true + ? 'border-green-300 bg-green-50/50' + : usernameAvailable === false || usernameError + ? 'border-red-300 bg-red-50/50' + : 'border-gray-200' + }`} + placeholder="Enter your username" + minLength={3} + maxLength={30} + title="Username can only contain letters, numbers, hyphens, and underscores" + required + />
{isCheckingUsername && ( diff --git a/app/layout.tsx b/app/layout.tsx index 3c594e2d..05983ec3 100644 --- a/app/layout.tsx +++ b/app/layout.tsx @@ -53,9 +53,7 @@ export default function RootLayout({ ` }} /> - {/* Preload critical resources */} - - + {/* Preload critical resources - removed local font preloads since we use Google Fonts */} {/* Structured Data */}