Terminal interface to find, download, and stream movies, TV shows, and live TV using local media players.
docs: update module maps with models and service layers
Samir Hossains641d1722b3e1
diff --git a/docs/architecture.md b/docs/architecture.mdindex bc11bc7..8b57100 100644--- a/docs/architecture.md+++ b/docs/architecture.md@@ -12,9 +12,12 @@ src/alternate screen, App::new + App::runlib.rs crate root, module declarationscache.rs disk cache: provider-namespaced, TTL'd, atomic writes+ config.rs Config load/save (config.json)download.rs download engine (resume, ranges, segments, retry)history.rs watch history persistencelogging.rs file logging (rotation, sanitization)+ models.rs shared domain models (SearchResult, BrowseMetrics, StreamPool, Notification)+ player.rs player detection (OnceLock) and command construction (mpv/VLC/IINA/Android)providers/mod.rs provider module treemodels.rs shared typed models (ProviderKind, CatalogItem,@@ -24,6 +27,8 @@ src/bdix/circleftp/ BDIX CircleFTP providerbdix/dhakaflix/ BDIX DhakaFlix providerm3u.rs M3U playlist parser (URL and local file)+ service.rs MovieBoxService headless engine (search, details, streams, captions)+ updater.rs GitHub release update checktui/app/ the application object and all behaviormod.rs App struct, App::new, helpers@@ -43,15 +48,12 @@ src/system.rs help, refresh, cache, theme, updates, focus, resizestate.rs AppState: all UI state + in-memory LRU cachesaction.rs the Action enum (event/message model)- config.rs Config load/save (config.json)event.rs EventHandler: input events + tick → Action channel- player.rs player detection and command constructionoverlay.rs popups, pickers, notificationsscreens/ render-only modules (home, details, help)terminal.rs terminal capability probestheme.rs color themestext.rs grapheme-safe text helpers- updater.rs GitHub release update check```## The event loopdiff --git a/docs/modules.md b/docs/modules.mdindex 7f8e04b..fd8a6f3 100644--- a/docs/modules.md+++ b/docs/modules.md@@ -8,12 +8,15 @@ responsibility.src/main.rs Entry point. Logging init, panic hook, raw mode, alternatescreen, TerminalGuard, App::new + App::run.- lib.rs Crate root: declares pub mod cache/download/history/logging/- providers/tui.+ lib.rs Crate root: declares pub mod cache/config/download/history/+ logging/models/player/providers/service/tui/updater.cache.rs Disk cache: provider-namespaced directories, TTL expiry,atomic temp-file writes, payload validation, background purge.+ config.rs Config struct: load/save config.json (provider, theme,+ auto-update, default player, bdix flag).+download.rs Download engine (pure, async): resume via .part files,HTTP ranges, optional multi-segment download, retries, cancelvia an AtomicBool, Windows-safe file stems.@@ -24,6 +27,13 @@ src/logging.rs File logging: flexi_logger, rotation (5MB, keep 3),MOVIEBOX_LOG level, URL/path sanitization for sharing.+ models.rs Pure domain data models: SearchResult, BrowseMetric,+ BrowsePreset, BrowseMetrics, SubjectStreamPool, Notification.++ player.rs Player detection (OnceLock) and command construction for+ mpv / VLC / IINA / Android intent, subtitle args, headers,+ terminal-sized window.+providers/mod.rs Module declarations.models.rs Shared types: ProviderKind, CatalogItem, MediaDetails,@@ -43,18 +53,19 @@ src/dhakaflix/ BDIX DhakaFlix provider (client + parser).m3u.rs M3U playlist parser (http(s) URL or local file).+ service.rs MovieBoxService: unified multi-provider headless client &+ engine (suggest, search, details, homepage, resolutions,+ captions, subtitle download, path resolution).++ updater.rs GitHub release update check.+tui/action.rs The Action enum: every UI event/message (input, networkresults, downloads, playback, tv, system).- config.rs Config struct: load/save config.json (provider, theme,- auto-update, default player, bdix flag).state.rs AppState: all UI state, LRU image/preview caches, and thePlayerKind enum + label()/parse(), tv manager row model.event.rs EventHandler: crossterm event stream + tick interval,forwards to the action channel.- player.rs Player detection (OnceLock) and command construction for- mpv / VLC / IINA / Android intent, subtitle args, headers,- terminal-sized window.overlay.rs Popups: notifications, pickers, confirmation, modal centering.screens/home.rs Home/startup + search list rendering (streaming and TV).@@ -63,7 +74,6 @@ src/terminal.rs Terminal capability probes (basic UI, image querying).theme.rs Color themes + terminal color detection.text.rs Grapheme-safe width/truncation helpers.- updater.rs GitHub release update check.tui/app/ The application object (App) and all behavior.mod.rs App struct, App::new, and small helpers.