Skip to content

Releases: ratatui/ratatui-textarea

ratatui-textarea-v0.9.1

16 Apr 20:16
0c449df

Choose a tag to compare

🐛 Bug Fixes

  • Properly handle crossterm's BackTab key when converting to Input by @bentheiii in #25

ratatui-textarea-v0.9.0

06 Apr 20:30
da69116

Choose a tag to compare

We're excited to announce the new version of ratatui-textarea! 🎉

In this release, we have moved the long-standing pull requests from the original tui-textarea repository and merged them!

🚀 Features

  • Add unicode-aware soft wrapping and wrapped cursor navigation by @srothgan in #23

Wrapping now respects Unicode grapheme boundaries, and Up/Down cursor movement follows
wrapped visual rows instead of only logical lines:

You can configure wrapping with TextArea::set_wrap_mode(...) and choose between
WrapMode::None, WrapMode::Word, WrapMode::Glyph, and WrapMode::WordOrGlyph:

use ratatui_textarea::{TextArea, WrapMode};

let mut textarea = TextArea::default();
textarea.set_wrap_mode(WrapMode::WordOrGlyph);
  • Upgrade placeholder to accept styled Text by @pm100 in #16

Placeholders can now be full ratatui_core::text::Text values instead of just a plain string
and style, so you can render rich multi-span and multi-line placeholder content while the
textarea is empty:

use ratatui_core::style::{Color, Style};
use ratatui_core::text::{Line, Span};
use ratatui_textarea::TextArea;

let mut textarea = TextArea::default();
textarea.set_styled_placeholder(Line::from(vec![
    Span::styled("Required: ", Style::default().fg(Color::Red)),
    Span::raw("enter your name"),
]));
  • Add TextArea::clear() method by @pm100 in #15
use ratatui_textarea::TextArea;

let mut textarea = TextArea::from(["hello", "world"]);
assert!(textarea.clear());
assert!(textarea.is_empty());
  • Improve vim example with replace mode, arrow keys, J, S, r/R, Ctrl+[ by @pm100 in #22

🐛 Bug Fixes

  • Clamp cursor after undo/redo to prevent out-of-bounds panic by @pm100 in #20
  • Add portable-atomic feature for targets without native AtomicU64 by @pm100 in #21
  • Preserve modified flag in editor example by @pm100 in #12
  • Don't treat underscores as punctuation for word movement by @pm100 in #11
  • Use correct cursor scroll position for wide (CJK) characters by @pm100 in #10

📚 Documentation

  • Fix typo in README line number section by @pm100 in #14

ratatui-textarea-v0.8.0

21 Feb 18:55
3b55ebc

Choose a tag to compare

We're excited to announce the first version of ratatui-textarea! (fork of tui-textarea)

Migrating from tui-textarea:

[dependencies]
-tui-textarea = 0.7.0
+ratatui-textarea = 0.8.0

🚀 Features

  • [breaking] Remove tui-rs support and update ratatui to 0.30.0 by @dotdash in #3

🚜 Refactor

  • Apply suggestion for clippy::double-ended-iterator-last by @orhun in #1
  • Update tui-textarea references to ratatui-textarea by @orhun in #1

📚 Documentation

  • Remove mentions about tui-rs support by @JayanAXHF in #2
  • (readme) Add note about fork by @orhun in #1
  • (license) Add ratatui developers to the license by @orhun in #1

⚙️ Miscellaneous Tasks

  • Set up release-plz workflow by @orhun in #4