Skip to content

Localize Web version 0.7.0

Latest

Choose a tag to compare

@kipcole9 kipcole9 released this 13 May 05:38

[0.7.0] — 2026-05-13

Enhancements

  • Localize.HTML.Message — new function component (and Localize.HTML.message/1 facade) that renders an MF2 message preserving inline markup. The link default renderer uses Phoenix's <.link> and so accepts href, navigate, or patch MF2 attributes; per-call :components and config :localize_web, :mf2_markup, components: %{…} override the defaults, and unknown tags raise Localize.HTML.Message.UnknownMarkupError.

  • Localize.HTML.t/1 and t/2 — new compile-time macros for HEEx templates that combine Gettext extraction, MF2 binding interpolation, and markup rendering in one call: {t("Read {#bold}terms{/bold}")}. Elixir #{@user.name} interpolations have the assigns prefix stripped so derived binding names match what a developer would write (@user.nameuser_name).

Test infrastructure

  • mix test now runs mix localize.download_locales first, populating CLDR data for the locales referenced by the suite (en, fr, de, th, ja, ar, zh, zh-Hans, zh-Hant). Fresh checkouts and CI no longer fail on missing locale display data.