feat: Implement contact form submission with API integration and status feedback, refactor user profiles page layout and scrolling, and remove updateSession call from profile settings.

This commit is contained in:
pradeepkumar
2026-03-20 12:43:23 +05:30
parent f71d47f3b7
commit 64f4234220
4 changed files with 69 additions and 47 deletions

View File

@@ -311,17 +311,8 @@ export function ProfileSettingsForm({
});
}
// Update session name without causing a page refresh
try {
const fullName = `${formData.firstName} ${formData.lastName}`.trim();
await updateSession({
user: { name: fullName },
});
} catch {
// Session update can fail silently - profile is already saved
}
// Dispatch event to notify header and other components to refresh profile data
// (Don't call updateSession as it can trigger a full page reload in next-auth v5)
window.dispatchEvent(new Event('profile-updated'));
if (onSave) {