Skip to main content

tui_vfx_recipes/
lib.rs

1// <FILE>src/lib.rs</FILE> - <DESC>Library entry point for tui-vfx-recipes</DESC>
2// <VERS>VERSION: 0.2.0</VERS>
3// <WCTX>Add prelude module for single-import convenience</WCTX>
4// <CLOG>Add prelude module re-exporting common types from all dependencies</CLOG>
5
6//! # TUI VFX Recipes
7//!
8//! JSON recipe loading, parsing, and validation for the tui-vfx ecosystem.
9//!
10//! This crate provides:
11//! - JSON schema definitions for visual effect recipes
12//! - Recipe parsing and validation
13//! - Template inheritance and resolution
14//! - Recipe registry for managing collections of recipes
15//! - Preview and animation management
16//! - Ratatui buffer integration via Grid adapter
17//!
18//! ## Quick Start
19//!
20//! ```rust,ignore
21//! use tui_vfx_recipes::prelude::*;
22//!
23//! // Load a recipe
24//! let recipe = load(Path::new("recipes/my_effect.json"), Path::new("."))?;
25//!
26//! // Create a preview manager
27//! let mut manager = PreviewManager::new();
28//! let item = preview_from_recipe_config(recipe.config());
29//! manager.add(item, Instant::now());
30//!
31//! // Render in your loop
32//! manager.tick(now);
33//! manager.render(frame_area, &mut buffer, now);
34//! ```
35//!
36//! ## Features
37//!
38//! - `async` - Enable async recipe loading with tokio
39//!
40//! ## Note
41//!
42//! This crate is under active development. Some imports may need adjustment
43//! as the tui-vfx library stabilizes.
44
45// Prelude for convenient single-import access
46pub mod prelude;
47
48// Application-level types for recipe system
49pub mod types;
50
51// Interaction state types
52pub mod interactions;
53
54// Pipeline inspection infrastructure
55#[macro_use]
56pub mod inspector;
57
58// Animation state management
59pub mod state;
60
61// Rendering types and functions
62pub mod rendering;
63
64// Preview functionality
65pub mod preview;
66
67// Theme and appearance
68pub mod theme;
69
70// Animated trait
71pub mod traits;
72
73// Animation manager
74pub mod manager;
75
76// Ratatui compatibility
77pub mod compat;
78
79// Recipe schema definitions
80pub mod recipe_schema;
81
82// Recipe loading and parsing
83pub mod recipe;
84
85// Built-in recipe definitions
86pub mod recipes;
87
88// Recipe registry
89pub mod registry;
90
91// Re-exports for convenience
92pub use inspector::InspectorContext;
93pub use recipe::{Recipe, RecipeError, load, parse};
94pub use registry::cls_recipe_registry::RecipeRegistry;
95pub use state::AnimationPhase;
96
97// <FILE>src/lib.rs</FILE> - <DESC>Library entry point for tui-vfx-recipes</DESC>
98// <VERS>END OF VERSION: 0.2.0</VERS>