Rust · Ratatui · Local by nature

Terminal interfaces.
Thoughtfully composed.

Build a terminal UI with reusable pickers, tabs, scroll areas and overlays. Keep your interaction logic while the small pieces work together.

A library for your Rust application. MIT or Apache-2.0, at your option.

~/your-appterminal UI sketch

Own the application.
Compose the interface.

Small parts. Clear responsibilities.

More time for your application.

Use positional matches that explain search results, scrolling that reserves room for its bar, and semantic colors supplied as a light and dark pair.

Choose the pieces you need.

Core modules are available without the optional background and document-tree dependencies.

01 / FIND

Pickers with context

Subsequence scoring returns match positions. Use them to highlight the characters that made a result relevant.

pick::Filter · pick::row
02 / NAVIGATE

Tabs and scrolling

Keep tab hit regions aligned with drawn labels. Reserve the scrollbar's column instead of painting over content.

tabs · scroll::Area
03 / COMPOSE

Overlays and inspection

Position floating surfaces and present details without making the component own your application's state.

float · overlay · inspect
04 / APPEARANCE

A pair of palettes

Nine semantic color roles in each light and dark palette. Optional terminal background detection reports how it selected a mode.

theme::Palette · theme::Mode

Your first dependency

Start in a Rust project.

Use Rust 1.96 or newer. Choose a pinned Git revision, or download the same source and use a local path dependency. Cargo resolves the crate dependencies; the source archive does not bundle a Rust toolchain.

Download source ZIP ↗SHA-256 checksum

Source revision d8fa2e4b4cad66495f4f601cad94cf6790710ee1 · tuilith 0.1.0

Use the downloaded source
unzip tuilith-source-d8fa2e4b4cad.zip
# In your application's Cargo.toml:
tuilith = { path = "../tuilith", default-features = false }
# Then build your application:
cargo check

Set the path to the extracted tuilith folder relative to your application. Choose this method or the Git dependency below.

Cargo.toml · pinned source

[dependencies]
tuilith = { git = "https://github.com/aylith-labs/tuilith", rev = "d8fa2e4b4cad66495f4f601cad94cf6790710ee1", default-features = false }

A first picker · actual library API

use tuilith::pick::Filter;

let names = ["Terminal UI", "Database"];
let mut filter = Filter::new();
filter.push('t');
filter.push('u');
filter.refilter(names.iter().copied());
assert_eq!(filter.selected().unwrap().index, 0);

Keep dependency choices explicit.

FeatureWhat it addsDependency behavior
backgroundTerminal light/dark detectionUses terminal-colorsaurus
document-treeFoldable JSON document treeUses serde_json with preserve_order
os-appearanceDesktop appearance signalsImplies background; may run OS commands

Default features enable all three. Use default-features = false to begin with the core modules, then opt in to the extra behavior your application needs.

Know the pieces you use

Component origins stay close to the code.

Each component declares its lineage: original, inspired, wrapper or tracked fork. The generated provenance record accompanies the source so you can inspect those declarations.

CI checks the declarations against the repository and runs cargo-vet and cargo-deny policies. These checks include recorded trust and exemptions; they are not a claim that every dependency has received an independent audit.

Your application, with a clearer interface.

Start with a picker. Add navigation, inspection and the palette that fits your terminal.

Get started ↗