tui-popup 0.1.1

A simple popup for ratatui
Documentation

tui-popup

Crates.io badge License badge Docs.rs badge Deps.rs badge Discord badge

A popup widget for Ratatui

Example

use ratatui::prelude::*;
use tui_popup::Popup;

fn render(frame: &mut Frame) {
    let popup = Popup::new("tui-popup demo", "Press any key to exit");
    frame.render_widget(popup.to_widget(), frame.size());
}

demo

Features

  • automatically centers
  • automatically sizes to content
  • style text
  • configure size / position
  • handle text wrapping in body -> size
  • set border set / style
  • mouse / keyboard events for moving
  • mouse / keyboard events for close action