magical markdown slides
Rust 100.0%
19 1 0

Clone this repository

https://tangled.org/desertthunder.dev/lantern
git@tangled.org:desertthunder.dev/lantern

For self-hosted knots, clone URLs may differ based on your setup.

README.md

lantern#

A modern, fast, terminal presentation tool inspired by maaslalani/slides, built with Rust.

Now with image support (if your terminal supports it!)

Rendered on Ghostty

Rendered on iTerm2

Quickstart#

Installation#

From a local clone:

cargo install --path cli

From GitHub:

cargo install --git https://github.com/stormlightlabs/lantern.git lantern-cli

From Tangled:

cargo install --git https://tangled.sh/desertthunder.dev/lantern lantern-cli

Create Your First Deck#

Create a markdown file presentation.md:

---
theme: nord
---

# Welcome to lantern

A terminal presentation tool built with Rust

---

## Features

- Base16 theming system
- Syntax highlighting
- Live reload
- Export to image/video

---

## Code Example

```rust
fn main() {
    println!("Hello, lantern!");
}
```

---

## That's it

Press `q` to quit, `←/→` to navigate

Present#

# Interactive TUI mode
lantern present presentation.md

# Print to stdout
lantern print presentation.md

# With custom theme
lantern present presentation.md --theme catppuccin-mocha
Key Action
, j, n Next slide
, k, p Previous slide
q Quit

Design Principles#

Color as Data: All color use flows through typed wrappers using owo-colors. No ad-hoc ANSI escapes.

Themeable: Built on the Base16 theming system with 10 prebuilt themes (Catppuccin, Nord, Gruvbox Material, Solarized, Oxocarbon). Each theme defines 16 semantic colors mapped to content and UI elements. Themes can be selected via frontmatter, CLI flags, or environment variables.

Reproducible: Everything is reproducible in plain text — decks can render without TUI (using lantern print).

Composable: Parser → Model → Renderer are independent modules with tests and traits.

Portable: Runs on any terminal supporting UTF-8; dependencies limited to core crates.

Testing#

This project uses cargo-llvm-cov for coverage

Installation:

# MacOS
brew install cargo-llvm-cov

# Linux
cargo +stable install cargo-llvm-cov --locked

Run tests:

cargo llvm-cov

# Open the browser
cargo llvm-cov --open