Skip to content

48116 frontend [ templates ] localize empty checklist validation errors#269

Open
aicarma-artyom-maslov wants to merge 1 commit into
masterfrom
frontend/templates/48116__localize_empty_checklist_error
Open

48116 frontend [ templates ] localize empty checklist validation errors#269
aicarma-artyom-maslov wants to merge 1 commit into
masterfrom
frontend/templates/48116__localize_empty_checklist_error

Conversation

@aicarma-artyom-maslov

@aicarma-artyom-maslov aicarma-artyom-maslov commented Jul 13, 2026

Copy link
Copy Markdown
Collaborator

Note

Low Risk
Localized error mapping only in getErrorMessage and locale files; no auth or data-path changes.

Overview
Template save/API validation errors for checklists now resolve to localized message keys instead of raw English backend strings.

getErrorMessage gains mapValidationMessage: blank-value errors (value: this field may not be blank.) map to validation.checklist-item-empty when details.api_name starts with citem-, otherwise validation.field-empty. The backend message Checklist items not exists or invalid. maps to validation.checklist-items-invalid. ICustomError.details now includes optional api_name for that branching.

New copy was added in en_US and ru_RU for those keys, with unit tests covering the three mapping cases.

Reviewed by Cursor Bugbot for commit 911d198. Bugbot is set up for automated code reviews on this repo. Configure here.

Note

Localize empty checklist validation errors in frontend templates

  • Adds two new localization keys (validation.checklist-item-empty and validation.checklist-items-invalid) to the en_US.ts and ru_RU.ts locale files.
  • Extends getErrorMessage in getErrorMessage.ts with a mapValidationMessage helper that detects blank-value errors and returns validation.checklist-item-empty when details.api_name starts with citem-, or validation.field-empty otherwise.
  • Maps the backend message 'Checklist items not exists or invalid.' to validation.checklist-items-invalid in the error mapper.
  • Adds unit tests covering all three new mappings in getErrorMessage.test.ts.

Macroscope summarized 911d198.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Frontend Web client changes request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant