feat: add user avatar functionality and update related routes

- Implemented avatar upload and deletion in the Auth context.
- Updated UserProfile component to handle avatar display and actions.
- Modified backend routes to return anonymous user ID when auth is disabled.
- Added avatar_url column to users table in the database.
- Enhanced UI for user menu and profile modal to support avatar display.
- Updated translations for new avatar-related strings.
- Improved stock status calculation for medications in the planner.
This commit is contained in:
Daniel Volz
2025-12-28 00:43:45 +01:00
parent be68fb5dad
commit bd5c864e84
14 changed files with 745 additions and 113 deletions
+9 -1
View File
@@ -259,7 +259,15 @@
"passwordReset": "Passwort zurückgesetzt",
"passwordResetSuccess": "Ihr Passwort wurde zurückgesetzt. Weiterleitung zur Anmeldung...",
"profileUpdated": "Profil erfolgreich aktualisiert",
"rememberMe": "Angemeldet bleiben"
"rememberMe": "Angemeldet bleiben",
"localAccount": "Lokales Konto",
"updatePassword": "Passwort ändern",
"fillAllFields": "Bitte alle Passwortfelder ausfüllen",
"signOut": "Abmelden",
"uploadAvatar": "Avatar hochladen",
"removeAvatar": "Avatar entfernen",
"avatarUpdated": "Avatar aktualisiert",
"avatarRemoved": "Avatar entfernt"
},
"common": {
"loading": "Wird geladen...",
+9 -1
View File
@@ -261,7 +261,15 @@
"passwordReset": "Password Reset",
"passwordResetSuccess": "Your password has been reset. Redirecting to login...",
"profileUpdated": "Profile updated successfully",
"rememberMe": "Remember me"
"rememberMe": "Remember me",
"localAccount": "Local Account",
"updatePassword": "Update Password",
"fillAllFields": "Please fill in all password fields",
"signOut": "Sign Out",
"uploadAvatar": "Upload avatar",
"removeAvatar": "Remove avatar",
"avatarUpdated": "Avatar updated",
"avatarRemoved": "Avatar removed"
},
"common": {
"loading": "Loading...",