| 1 | # Changelog |
| 2 | |
| 3 | ## [0.11.0] |
| 4 | |
| 5 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.10.0...v0.11.0) |
| 6 | |
| 7 | ### Added |
| 8 | - New `ControlSequences8Bit` option to treat 8-bit ECMA-48 (C1) escape sequences as zero-width. (#22) |
| 9 | |
| 10 | ### Changed |
| 11 | - Upgraded uax29 dependency to v2.7.0 for 8-bit escape sequence support in the grapheme iterator. |
| 12 | - Truncation now validates that preserved trailing escape sequences are zero-width, preventing edge cases where non-zero-width sequences could leak into output. |
| 13 | |
| 14 | ### Note |
| 15 | - `ControlSequences8Bit` is deliberately ignored by `TruncateString` and `TruncateBytes`, because C1 byte values (0x80–0x9F) overlap with UTF-8 multi-byte encoding. |
| 16 | |
| 17 | ## [0.10.0] |
| 18 | |
| 19 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.9.0...v0.10.0) |
| 20 | |
| 21 | ### Added |
| 22 | - New `ControlSequences` option to treat ECMA-48/ANSI escape sequences as zero-width. (#20) |
| 23 | - `TruncateString` and `TruncateBytes` now preserve trailing ANSI escape sequences (such as SGR resets) when `ControlSequences` is true, preventing color bleed in terminal output. |
| 24 | |
| 25 | ### Changed |
| 26 | - Removed `stringish` dependency; generic type constraints are now inline `~string | []byte`. |
| 27 | - Upgraded uax29 dependency to v2.6.0 for ANSI escape sequence support in the grapheme iterator. |
| 28 | |
| 29 | ## [0.9.0] |
| 30 | |
| 31 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.8.0...v0.9.0) |
| 32 | |
| 33 | ### Changed |
| 34 | - Unicode 17 support: East Asian Width and emoji data updated to Unicode 17.0.0. (#18) |
| 35 | - Upgraded uax29 dependency to v2.5.0 (Unicode 17 grapheme segmentation). |
| 36 | |
| 37 | ## [0.8.0] |
| 38 | |
| 39 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.7.0...v0.8.0) |
| 40 | |
| 41 | ### Changed |
| 42 | - Performance: ASCII fast path that applies to any run of printable |
| 43 | ASCII. 2x-10x faster for ASCII text vs v0.7.0. (#16) |
| 44 | - Upgraded uax29 dependency to v2.4.0 for Unicode 16 support. Text that includes |
| 45 | Indic_Conjunct_Break may segment differently (and more correctly). (#15) |
| 46 | |
| 47 | ## [0.7.0] |
| 48 | |
| 49 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.6.2...v0.7.0) |
| 50 | |
| 51 | ### Added |
| 52 | - New `TruncateString` and `TruncateBytes` methods to truncate strings to a |
| 53 | maximum display width, with optional tail (like an ellipsis). (#13) |
| 54 | |
| 55 | ## [0.6.2] |
| 56 | |
| 57 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.6.1...v0.6.2) |
| 58 | |
| 59 | ### Changed |
| 60 | - Internal: reduced property categories for simpler trie. |
| 61 | |
| 62 | ## [0.6.1] |
| 63 | |
| 64 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.6.0...v0.6.1) |
| 65 | |
| 66 | ### Changed |
| 67 | - Perf improvements: replaced the ASCII lookup table with a simple |
| 68 | function. A bit more cache-friendly. More inlining. |
| 69 | - Bug fix: single regional indicators are now treated as width 2, since that |
| 70 | is what actual terminals do. |
| 71 | |
| 72 | ## [0.6.0] |
| 73 | |
| 74 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.5.0...v0.6.0) |
| 75 | |
| 76 | ### Added |
| 77 | - New `StringGraphemes` and `BytesGraphemes` methods, for iterating over the |
| 78 | widths of grapheme clusters. |
| 79 | |
| 80 | ### Changed |
| 81 | - Fast ASCII lookups |
| 82 | |
| 83 | ## [0.5.0] |
| 84 | |
| 85 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.4.1...v0.5.0) |
| 86 | |
| 87 | ### Added |
| 88 | - Unicode 16 support |
| 89 | - Improved emoji presentation handling per Unicode TR51 |
| 90 | |
| 91 | ### Changed |
| 92 | - Corrected VS15 (U+FE0E) handling: now preserves base character width (no-op) per Unicode TR51 |
| 93 | - Performance optimizations: reduced property lookups |
| 94 | |
| 95 | ### Fixed |
| 96 | - VS15 variation selector now correctly preserves base character width instead of forcing width 1 |
| 97 | |
| 98 | ## [0.4.1] |
| 99 | |
| 100 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.4.0...v0.4.1) |
| 101 | |
| 102 | ### Changed |
| 103 | - Updated uax29 dependency |
| 104 | - Improved flag handling |
| 105 | |
| 106 | ## [0.4.0] |
| 107 | |
| 108 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.3.1...v0.4.0) |
| 109 | |
| 110 | ### Added |
| 111 | - Support for variation selectors (VS15, VS16) and regional indicator pairs (flags) |
| 112 | |
| 113 | ## [0.3.1] |
| 114 | |
| 115 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.3.0...v0.3.1) |
| 116 | |
| 117 | ### Added |
| 118 | - Fuzz testing support |
| 119 | |
| 120 | ### Changed |
| 121 | - Updated stringish dependency |
| 122 | |
| 123 | ## [0.3.0] |
| 124 | |
| 125 | [Compare](https://github.com/clipperhouse/displaywidth/compare/v0.2.0...v0.3.0) |
| 126 | |
| 127 | ### Changed |
| 128 | - Dropped compatibility with go-runewidth |
| 129 | - Trie implementation cleanup |