fix: recover saved photo uploads and lower car-body description minimum

Read saved document status from maps and plain objects, acknowledge verified document retries without replacing stored images, and preserve upload authorization and resend behavior. Lower the car-body narrative minimum to 30 characters with Persian errors and boundary regression coverage.
This commit is contained in:
SepehrYahyaee
2026-11-21 12:35:49 +03:30
parent 8f15040080
commit e33f5736a2
12 changed files with 202 additions and 29 deletions
+4 -2
View File
@@ -345,11 +345,13 @@ export function localizeErrorMessage(
const lower = message.toLowerCase();
if (wording[lower]) return wording[lower];
if (
/car_body.*description.*(?:100|۱۰۰)|description.*must.*(?:100|۱۰۰).*characters/i.test(
/car_body.*description.*(?:30|۳۰|100|۱۰۰)|description.*must.*(?:30|۳۰|100|۱۰۰).*characters/i.test(
message,
)
)
return "شرح حادثه باید حداقل ۱۰۰ کاراکتر باشد.";
return /(?:30|۳۰)/.test(message)
? "شرح حادثه باید حداقل ۳۰ کاراکتر باشد."
: "شرح حادثه باید حداقل ۱۰۰ کاراکتر باشد.";
const operation =
/^failed to (fetch|get|load|send|upload|submit|add|create|update|verify|delete|remove) (.+)$/i.exec(
message,