[package]
name = "dear-file-browser"
version = "0.10.2"
edition.workspace = true
description = "File dialogs and in-UI file browser for dear-imgui-rs"
license.workspace = true
repository.workspace = true
homepage.workspace = true
categories.workspace = true
keywords.workspace = true
readme = "README.md"

[package.metadata.docs.rs]
features = ["imgui", "native-rfd"]

[features]
# Defaults: enable both backends and tracing. Runtime picks the best.
default = ["imgui", "native-rfd", "tracing"]
# ImGui UI backend; pulls small date-time crate for tooltips
imgui = ["dep:chrono", "dep:regex"]
native-rfd = ["dep:rfd"]
tracing = ["dep:tracing"]
thumbnails-image = ["imgui", "dep:image"]

[dependencies]
dear-imgui-rs = { path = "../../dear-imgui", version = "0.10" }
thiserror.workspace = true
tracing = { workspace = true, optional = true }

# Native file dialogs (desktop + wasm) — optional
rfd = { version = "0.17", optional = true, default-features = false, features = ["xdg-portal"] }
chrono = { version = "0.4", default-features = false, features = ["clock"], optional = true }
image = { version = "0.25", default-features = false, features = ["png", "jpeg"], optional = true }
regex = { version = "1.11", optional = true }
indexmap = "2"

[dev-dependencies]
pollster = { workspace = true }
