All Versions
44
Latest Version
Avg Release Cycle
28 days
Latest Release
-

Changelog History
Page 1

  • v3.9.1 Changes

    ๐Ÿš€ This is the changelog for Cldr_units v3.9.1 released on November 15th, 2021. For older changelogs please consult the release tag on GitHub

    ๐Ÿ› Bug Fixes

    • ๐Ÿ‘Œ Support parsing units with multiple "per" clauses like "gallon per feet per second".

    • ๐Ÿ›  Fix canonical unit name for currency units. This also fixes unit math with currency units.

    • โž• Add display_name/2 to backend modules.

  • v3.9.0 Changes

    ๐Ÿš€ This is the changelog for Cldr_units v3.9.0 released on November 14th, 2021. For older changelogs please consult the release tag on GitHub

    ๐Ÿ› Bug Fixes

    • Use import Config not deprecated use Mix.Config in config files. Only significant for developers of ex_cldr_units.

    • ๐Ÿ‘‰ Make decimal a required dependency, not optional, since various pattern matches expect its presence.

    โœจ Enhancements

    • โž• Add support for currency-based units. This allows for calculations and formatting of units such as "$2 per gallon". For this example, the unit would be created with Cldr.Unit.new(2, "curr-usd-per-gallon"). The inverse is also possible, for example:
    iex> MyApp.Cldr.Unit.to_string(Cldr.Unit.new!(2, "curr-usd-per-gallon"))
    {:ok, "$2.00 per gallon"}
    
    iex> MyApp.Cldr.Unit.to_string(Cldr.Unit.new!(2, "gallon-per-curr-usd"))
    {:ok, "2 gallons per US dollar"}
    
    • โž• Add support for binary factor prefixed units. These units are factors of 1024 and include "kibi", "mebi", "gibi", "tebi", "pebi", "exbi", "zebi" and "yobi". For example:
    iex> MyApp.Cldr.Unit.to_string Cldr.Unit.new!(3, :gibibyte)
    {:ok, "3 gibibytes"}
    
    • โž• Add support for integer prefixes for units. This is useful for units like "liters per 100 kilometers" or "25 calories per 100 grams". For example:
    iex> MyApp.Cldr.Unit.to_string Cldr.Unit.new!(25, "calorie_per_100-gram")
    {:ok, "25 calories per 100 grams"}
    
  • v3.8.0 Changes

    ๐Ÿš€ This is the changelog for Cldr_units v3.8.0 released on October 27th, 2021. For older changelogs please consult the release tag on GitHub

    โœจ Enhancements

    • ๐Ÿš€ Updates to use CLDR 40 data. The release notes say:

    In CLDR v40, the focus is on Grammatical features (gender and case) for units of measurement in additional locales. In many languages, forming grammatical phrases requires dealing with grammatical gender and case. Without that, it can sound as bad as "on top of 3 hours" instead of "in 3 hours":

    • Phase 1 (CLDR v39) of grammatical features included just 12 locales (da, de, es, fr, hi, it, nl, no, pl, pt, ru, sv).

    • Phase 2 (CLDR v40, this release) has expanded the number of locales by 29 (am, ar, bn, ca, cs, el, fi, gu, he, hr, hu, hy, is, kn, lt, lv, ml, mr, nb, pa, ro, si, sk, sl, sr, ta, te, uk, ur), but for a more restricted number of units.

    ๐Ÿ—„ Deprecations

    • Don't call deprecated Cldr.Config.get_locale/2, use Cldr.Locale.Loader.get_config/2 instead.

    • Don't call deprecated Cldr.Config.known_locale_names/1, call Cldr.Locale.Loader.known_locale_names/1 instead.

  • v3.8.0-rc.2 Changes

    ๐Ÿš€ This is the changelog for Cldr_units v3.8.0-rc.2 released on October 25th, 2021. For older changelogs please consult the release tag on GitHub

    ๐Ÿ—„ Deprecations

    • Don't call deprecated Cldr.Config.known_locale_names/1, call Cldr.Locale.Loader.known_locale_names/1 instead.
  • v3.8.0-rc.1 Changes

    ๐Ÿš€ This is the changelog for Cldr_units v3.8.0-rc.1 released on October 24th, 2021. For older changelogs please consult the release tag on GitHub

    ๐Ÿ—„ Deprecations

    • Don't call deprecated Cldr.Config.get_locale/2, use Cldr.Locale.Loader.get_config/2 instead.
  • v3.8.0-rc.0 Changes

    ๐Ÿš€ This is the changelog for Cldr_units v3.8.0-rc.0 released on October 3rd, 2021. For older changelogs please consult the release tag on GitHub

    โœจ Enhancements

    • ๐Ÿš€ Updates to use CLDR 40 data. The release notes say:

    In CLDR v40, the focus is on Grammatical features (gender and case) for units of measurement in additional locales. In many languages, forming grammatical phrases requires dealing with grammatical gender and case. Without that, it can sound as bad as "on top of 3 hours" instead of "in 3 hours":

    • Phase 1 (CLDR v39) of grammatical features included just 12 locales (da, de, es, fr, hi, it, nl, no, pl, pt, ru, sv).
    • ๐Ÿš€ Phase 2 (CLDR v40, this release) has expanded the number of locales by 29 (am, ar, bn, ca, cs, el, fi, gu, he, hr, hu, hy, is, kn, lt, lv, ml, mr, nb, pa, ro, si, sk, sl, sr, ta, te, uk, ur), but for a more restricted number of units.
  • v3.7.1 Changes

    ๐Ÿš€ This is the changelog for Cldr_units v3.7.1 released on August 20th, 2021. For older changelogs please consult the release tag on GitHub

    ๐Ÿ› Bug Fixes

    • ๐Ÿ›  Fix doc errors. Thanks to @maennchen for the report. Doc errors in other ex_cldr packages are also updated.
  • v3.7.0 Changes

    ๐Ÿš€ This is the changelog for Cldr_units v3.7.0 released on July 1st, 2021. For older changelogs please consult the release tag on GitHub

    โœจ Enhancements

    • โž• Add support for the Cldr.DisplayName protocol for t:Cldr.Unit structs.

    • ๐Ÿ“ฆ Updated to ex_cldr version 2.23.0 which changes the names of some of the fields in the "-u-" extension to match the CLDR canonical name. In particular the field name measurement_system changes to ms. Also the value of ms for the UK System will be :imperial not :uksystem.

  • v3.6.0 Changes

    ๐Ÿš€ This is the changelog for Cldr_units v3.6.0 released on June 12th, 2021. For older changelogs please consult the release tag on GitHub

    โœจ Enhancements

    • โž• Add Cldr.Unit.parse/2 to parse unit strings of the form 1kg into a t:Cldr.Unit struct.
  • v3.5.3 Changes

    ๐Ÿš€ This is the changelog for Cldr_units v3.5.3 released on May 20th, 2021. For older changelogs please consult the release tag on GitHub

    ๐Ÿ› Bug Fixes

    • ๐Ÿ”ง Fixes formatting units when invoking MyApp.Cldr.Unit.to_string/2 (ie on the backend module) and no default backend is configured. Thanks again to @maennchen. Closes #22. Require at least ex_cldr version 2.22.1