Improve error message handling with user-friendly messages

- Add ErrorMessageParser in Kotlin and Swift to detect network errors
  and technical messages, replacing them with human-readable text
- Update all ViewModels to use ErrorMessageParser.parse() for error display
- Remove redundant error popup from LoginView (error shows inline only)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Trey t
2025-12-11 20:46:43 -06:00
parent 1839bd0e11
commit 258ccf7354
18 changed files with 201 additions and 66 deletions

View File

@@ -468,7 +468,7 @@ private extension ResidenceDetailView {
} catch {
await MainActor.run {
self.isDeleting = false
self.viewModel.errorMessage = error.localizedDescription
self.viewModel.errorMessage = ErrorMessageParser.parse(error.localizedDescription)
}
}
}
@@ -500,7 +500,7 @@ private extension ResidenceDetailView {
}
} catch {
await MainActor.run {
self.contractorsError = error.localizedDescription
self.contractorsError = ErrorMessageParser.parse(error.localizedDescription)
self.isLoadingContractors = false
}
}