[package]
name = "hjkl-engine"
description = "Vim FSM, motion grammar, and ex commands. Pre-1.0 churn."
keywords = ["vim", "modal", "editor", "fsm"]
categories = ["text-editors"]
version = "0.3.2"
edition = "2024"
license = "MIT"
repository = "https://github.com/kryptic-sh/hjkl-engine"
authors = ["mxaddict <mxaddict@kryptic.sh>"]
rust-version = "1.95"
homepage = "https://hjkl.kryptic.sh"
readme = "README.md"

[features]
default = ["serde", "crossterm", "ratatui"]
serde = ["dep:serde"]
crossterm = ["dep:crossterm"]
# Pulls in ratatui and the ratatui-flavoured `Style` interning surface
# (`Editor::intern_style`, `style_table`, `install_syntax_spans`) plus the
# `Rect`-based mouse helpers. Off by default for wasm / no_std consumers;
# the SPEC engine-native `Style`/`intern_engine_style` path is always
# available. Default-on at the workspace level for backwards compat.
ratatui = ["dep:ratatui", "hjkl-buffer/ratatui"]

[dev-dependencies]
proptest = "1"
serde_json = "1"

[dependencies]
# Phase 5 trait extraction (0.0.26): `ratatui` and `crossterm` are now
# both optional. Default features keep them on so existing consumers
# build unchanged; wasm / no_std hosts opt out via
# `default-features = false`.
hjkl-buffer = "0.3"
bitflags = "2"
ratatui = { version = "0.30", optional = true }
crossterm = { version = "0.29.0", features = ["event-stream"], optional = true }
regex = "1"
serde = { version = "1", features = ["derive"], optional = true }
thiserror = "2"

[package.metadata.docs.rs]
all-features = true
targets = ["x86_64-unknown-linux-gnu"]
rustdoc-args = ["--cfg", "docsrs"]
