pub mod constructors;
pub mod methods;
pub mod traits;
use ratatui::{style::Style, text::Line, widgets::Block};
use crate::primitives::tree_view::node_state::NodeState;
use crate::primitives::tree_view::tree_node::TreeNode;
pub type NodeRenderRefFn<'a, T> = Box<dyn Fn(&T, &NodeState) -> Line<'a> + 'a>;
pub type NodeFilterFn<T> = Box<dyn Fn(&T, &Option<String>) -> bool>;
pub struct TreeViewRef<'a, 'b, T> {
pub nodes: &'b [TreeNode<T>],
pub block: Option<Block<'a>>,
pub(crate) render_fn: NodeRenderRefFn<'a, T>,
pub(crate) expand_icon: &'a str,
pub(crate) collapse_icon: &'a str,
pub(crate) highlight_style: Option<Style>,
pub(crate) icon_style: Style,
pub(crate) show_filter_ui: bool,
}