Skip to content

Text version 1.0.0

Latest

Choose a tag to compare

@kipcole9 kipcole9 released this 21 Sep 00:19

[1.0.0] — 2026-09-20

First stable release. No functional change from the unreleased 0.7 series; the version bump signals API stability across the surface documented in the README and guides.

Breaking changes

  • Link detection now follows UTS #58 instead of the twitter-text rules; pass twitter_quirks: true to urls/2, emails/2, all/2 or split/2 for the previous behaviour. Text.Extract.Boundary is removed, superseded by Text.Extract.Link.

  • Predicate helpers in Text.Inflect.En, .Pluralize and .Singularize are renamed from is_foo/n to foo?/n (e.g. is_pronoun/2 → pronoun?/2); stdlib guards are untouched. The data-returning Text.Inflect.En.Helpers.is_ides/0 becomes ides_pattern/0.

Enhancements

  • The :unicode dependency requirement is ~> 2.2, based upon Unicode 18.

  • Adds Text.Extract.Link, implementing UTS #58 §3.5.1 termination against the full Unicode repertoire — 65 bracket pairs and 129 ranges of soft terminators, against the 4 pairs and 7 characters handled before.

  • Adds Text.Extract.Escape, implementing UTS #58 §4.1 minimal escaping, which rewrites a URL into its most readable form without changing where link detection ends it. minimal/1 accepts either a serialised URL or a keyword list of already-parsed parts, the latter for when a syntax character is data rather than structure.

  • Adds mix text.download_uts58 to vendor the UTS #58 conformance suites into test/fixtures/uts58/, with --release, --into, --diff and --dry-run. Both suites run as part of the test suite and pass in full.

  • URL detection now accepts hosts and paths that are wholly non-ASCII, all four UTS #46 label separators (so 普遍适用测试。我爱你 is a two-label host), hosts carrying an explicit root label (foo.example.com./path), and mailto: addresses. Script-internal punctuation such as the Tibetan tsheg is accepted in host labels, since UTS #46 processing validates the host afterwards.

Bug fixes

  • mix text.download_tlds, text.download_lemma_data and text.download_lid176 no longer crash when run without --force. not options[:force] raised an ArgumentError on the nil the option parser supplies when a boolean switch is absent, which made the up-to-date path unreachable.

  • Text.Slug.slugify/2 expectations updated for unicode_transform 1.1.0, which now emits a separator between Pinyin syllables as ICU does, so 北京 slugifies to bei-jing.