feat: add password change functionality

- Add password change button to sidebar account menu
- Create PasswordChangeDialog component with shadcn UI components
- Implement backend API endpoint /api/v1/user/change-password
- Add form validation with current password verification
- Include internationalization support for Chinese and English
- Add proper error handling and success notifications

Co-Authored-By: Rock <rockchinq@gmail.com>
This commit is contained in:
Devin AI
2025-08-17 03:03:36 +00:00
parent 29f0075bd8
commit dd30d08c68
7 changed files with 257 additions and 0 deletions

View File

@@ -622,6 +622,16 @@ class HttpClient {
new_password: newPassword,
});
}
public changePassword(
currentPassword: string,
newPassword: string,
): Promise<{ user: string }> {
return this.post('/api/v1/user/change-password', {
current_password: currentPassword,
new_password: newPassword,
});
}
}
const getBaseURL = (): string => {