fix: replace raw ai_consent_required code with translatable message and consent prompt
All checks were successful
CI / Lint, Unit Tests & Build (push) Successful in 7m20s
CI / Deploy production (on server) (push) Successful in 24s

- Centralize AI consent 403 responses in server-consent helpers
- Return human-readable message + code + i18n errorKey from all AI APIs
- Update dashboard and AI clients to detect code/errorKey and translate
- Add consent.ai.requiredToast i18n keys (fr/en)
This commit is contained in:
Antigravity
2026-07-18 17:32:00 +00:00
parent 86505659cf
commit 324bf40658
41 changed files with 404 additions and 97 deletions

View File

@@ -3806,7 +3806,8 @@
"revoked": "Consent not granted",
"revokedToast": "AI processing consent successfully revoked.",
"complianceBadge": "GDPR compliance",
"auditFailed": "Could not record your consent. Please try again."
"auditFailed": "Could not record your consent. Please try again.",
"requiredToast": "Enable AI processing in Settings → AI to use this feature."
}
},
"account": {

View File

@@ -3812,7 +3812,8 @@
"revoked": "Consentement non accordé",
"revokedToast": "Consentement IA révoqué avec succès.",
"complianceBadge": "Conformité RGPD",
"auditFailed": "Impossible d'enregistrer votre consentement. Réessayez."
"auditFailed": "Impossible d'enregistrer votre consentement. Réessayez.",
"requiredToast": "Activez le traitement IA dans Paramètres → IA pour utiliser cette fonctionnalité."
}
},
"account": {