Skip to content

Version 0.7.0 (August 12th, 2026)

Latest

Choose a tag to compare

@Mc-Zen Mc-Zen released this 12 Aug 21:28
· 1 commit to main since this release

Changelog

Features:

  • The new quan function provides a new way of defining quantities and units.
  • Zero now adds alt descriptions for all numbers and units for supported languages. New translations are welcome.

Rounding:

  • ⚠️ Breaking change: the rounding API was changed to a more comprehensible model and to better reflect common applications. Numbers with an uncertainty are by default (round.follow-uncertainty: true) rounded to the precision of the uncertainty − we call this automatic rounding. If no uncertainty is present or round.follow-uncertainty: false, manually rounding is applied according to the options mode and precision. The mode: "uncertainty" has been removed.
  • ⚠️ Breaking change: zeros are now trimmed after rounding and padding is independent. This leads to the following effect of change:
    • Before: num(round: (precision: 2, pad: false)[0.299] -> 0.30
    • Now: num(round: (precision: 2, pad: false)[0.299] -> 0.3
  • Fixed a bug where rounding to zero were for negative precision led to multiple zeros being displayed in the integer part.
  • Fixed rounding to negative (integer) places.
  • Fixed rounding of 0 to a positive number of significant figures: now no trailing zeros are displayed anymore.

Input:

  • Added support for capital E in exponent notation.

Formatting:

  • New option num.trim-zeros for trimming trailing zeros.
  • New option num.omit-zero-exponent.
  • Fixed: Automatic exponents with scientific or engineering notation are now omitted when the mantissa is 0 and no explicit exponent is given.
  • Fixed prevention of line breaks and add more fine-grained line break control: after the ×, after the ± and before the unit.
  • ⚠️ Breaking change: moved the parameter breakable from set-unit to set-num since it now also affects numbers.
  • Fixed num.use-sqrt with inline fraction mode.
  • Fixed formatting of exponents with custom decimal separators.
  • Fixed an error with scientific mode with asymmetric uncertainties.
  • Fixed a tiny detail when formatting the decimal separator.

API:

  • Added queryable metadata to numbers and units.
  • Moved the internal num-state to the impl module.

I would like to thank @SeSodesa and @hpcfzl for large contributions towards the accessibility feature, @Ants-Aare for implementing the metadata and adding two new units, and @DegrangeM, @LordBaryhoba, @FilouPlains, and @Netzwerk2 for reporting important issues before they were released.

Happy solar eclipse!