WORK-503
ID:WORK-503Status:ready

Thread LocaleContext into the engine label renderers

buildStructureElement() and the MetaField block renderers currently emit labels as literals and have no access to config — they receive only (entry, name, modifierValues, icons). This is the previously-unstated prerequisite for localizing Zone 1. Thread the narrow LocaleContext (Decision D6) through, matching the engine's existing convention of passing explicit slices.

Priority:highComplexity:moderateMilestone:v0.29.0Source:SPEC-035
claude/multi-language-support-spec-5zzt9q View source

Criteria completion

Criteria completion: 0 of 3 (0%) checked; tracking started on Jul 17, no incremental history yet0%25%50%75%100%Jul 17Jul 30

Tracking started Jul 17 — check back for trends.

Branches 2
claude/multi-language-support-spec-5zzt9q current ready
main doneclaude/milestone-v0-29-0-stzywk done
History 1
  1. d92ad0c
    Created (ready)by bjornolofandersson

Scope

  • Add LocaleContext as an argument to buildStructureElement() (packages/transform/src/engine.ts) and to the MetaField / metaFields block renderers (SPEC-080 path).
  • Plumb the slice from the engine entry points down to those call sites; construct it once per render from the resolved ThemeConfig (locale + merged strings).
  • Do not localize any strings yet — this item only makes the context available. Label emission stays literal until WORK-504.
  • Keep the engine framework-agnostic and testable: prefer the narrow slice over the full ThemeConfig. (A bound t() closure is an acceptable equivalent per D6.)

Acceptance Criteria

  • buildStructureElement() and the MetaField block renderers receive a LocaleContext.
  • The context is constructed once per render and threaded, not stored in module-global state.
  • No output change (labels still literal); existing transform/engine tests stay green.

Blocked by

  • WORK-502

References

  • SPEC-035 — Resolution Mechanism (Zone 1), Decision D6.