Skip to content

[Web] Translate measurement descriptions in ObjectTutorialModal #553

Description

@mustafa-5493

📝 [Web] Translate measurement descriptions in ObjectTutorialModal

Description

Follow-up to #292. Short measurement labels (Slope, Width, etc.) are already localized via the object.<TYPE>.measurement.<key>.label namespace introduced in #534. The long-form description strings , the plain-language explanation of why each threshold matters, rendered inside ObjectTutorialModal still live in English in objectTypeConfig.js and were intentionally deferred.

There are roughly 25 descriptions across 9 object types. They're long-ish prose (one sentence each) but mechanical to translate.

Feature / Task Details

  • Add object.<TYPE>.measurement.<key>.description entries to en.json and tr.json for every measurement currently defined in objectTypeConfig.js.
  • Extend localizeObjectType to translate description (parallel to how it translates label), falling back to the config's English description for any missing key.
  • Drop the deferral note in objectTypeConfig.js's docstring (or update it to point at the new keys).
  • No new tests strictly required , fall-through covers any missed keys, and existing tests stay green.

Deliverables

  • Updated frontend/src/utils/objectTypeConfig.js (extend localizeObjectType)
  • Updated frontend/src/i18n/locales/en.json and tr.json

Acceptance Criteria

  • Opening "How to measure" on any object in TR shows Turkish descriptions
  • EN mode is identical to before
  • Missing-key fallback still shows the English description from the config
  • All existing tests pass

Metadata

Metadata

Assignees

Labels

Type

No fields configured for Task.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions