Terminal interface to find, download, and stream movies, TV shows, and live TV using local media players.
Initial commit
Samir Hossainsde97baee85ec
diff --git a/.gitignore b/.gitignorenew file mode 100644index 0000000..e35ea19--- /dev/null+++ b/.gitignore@@ -0,0 +1,20 @@+debug/+target/+**/*.rs.bk+*.pdb+.vscode/+.idea/+*.swp+*.swo+*.iml+.DS_Store+.DS_Store?+._*+.Spotlight-V100+.Trashes+ehthumbs.db+Thumbs.db+.AppleDouble+.LSOverride+debug_*.json+*.log\ No newline at end of filediff --git a/CONTRIBUTING.md b/CONTRIBUTING.mdnew file mode 100644index 0000000..f17600b--- /dev/null+++ b/CONTRIBUTING.md@@ -0,0 +1,39 @@+# Contributing to MovieBox++Thank you for your interest in contributing to MovieBox!++## Pull Request Process++1. Ensure any install or build dependencies are removed before the end of the layer when doing a build.+2. Update the README.md with details of changes to the interface, this includes new environment variables, exposed ports, useful file locations and container parameters.+3. Ensure your code passes all linting (`cargo clippy -- -D warnings`) and formatting (`cargo fmt --check`) checks.+4. Add tests for any new features or bug fixes.+5. The PR will be reviewed by a maintainer and merged when approved.++## Development setup++Ensure you have the latest stable Rust compiler.+```sh+rustup default stable+```++### Running Tests++Run the full test suite locally:+```sh+cargo test+```++### Code Style++We follow standard Rust idioms.+All code must be formatted using `rustfmt`.++```sh+cargo fmt+```++Use `clippy` to catch common mistakes.+```sh+cargo clippy --all-targets --all-features -- -D warnings+```diff --git a/Cargo.lock b/Cargo.locknew file mode 100644index 0000000..552f1c6--- /dev/null+++ b/Cargo.lock@@ -0,0 +1,4111 @@+# This file is automatically @generated by Cargo.+# It is not intended for manual editing.+version = 4++[[package]]+name = "adler2"+version = "2.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa"++[[package]]+name = "aho-corasick"+version = "1.1.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ddd31a130427c27518df266943a5308ed92d4b226cc639f5a8f1002816174301"+dependencies = [+ "memchr",+]++[[package]]+name = "aligned"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ee4508988c62edf04abd8d92897fca0c2995d907ce1dfeaf369dac3716a40685"+dependencies = [+ "as-slice",+]++[[package]]+name = "aligned-vec"+version = "0.6.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dc890384c8602f339876ded803c97ad529f3842aba97f6392b3dba0dd171769b"+dependencies = [+ "equator",+]++[[package]]+name = "allocator-api2"+version = "0.2.21"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "683d7910e743518b0e34f1186f92494becacb047c7b6bf616c96772180fef923"++[[package]]+name = "anyhow"+version = "1.0.103"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2a4385e2e34eb35d6b3efe798b9eb88096925d87726c0798709bf56d9ed84af3"++[[package]]+name = "approx"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cab112f0a86d568ea0e627cc1d6be74a1e9cd55214684db5561995f6dad897c6"+dependencies = [+ "num-traits",+]++[[package]]+name = "arbitrary"+version = "1.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c3d036a3c4ab069c7b410a2ce876bd74808d2d0888a82667669f8e783a898bf1"++[[package]]+name = "arg_enum_proc_macro"+version = "0.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ae92a5119aa49cdbcf6b9f893fe4e1d98b04ccbf82ee0584ad948a44a734dea"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "arrayvec"+version = "0.7.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d3fb67a6e08acf24fdeccbac2cb6ac4305825bd1f117462e0e6f2f193345ad56"++[[package]]+name = "as-slice"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "516b6b4f0e40d50dcda9365d53964ec74560ad4284da2e7fc97122cd83174516"+dependencies = [+ "stable_deref_trait",+]++[[package]]+name = "atomic"+version = "0.6.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a89cbf775b137e9b968e67227ef7f775587cde3fd31b0d8599dbd0f598a48340"+dependencies = [+ "bytemuck",+]++[[package]]+name = "atomic-waker"+version = "1.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0"++[[package]]+name = "autocfg"+version = "1.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53"++[[package]]+name = "av-scenechange"+version = "0.14.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0f321d77c20e19b92c39e7471cf986812cbb46659d2af674adc4331ef3f18394"+dependencies = [+ "aligned",+ "anyhow",+ "arg_enum_proc_macro",+ "arrayvec",+ "log",+ "num-rational",+ "num-traits",+ "pastey",+ "rayon",+ "thiserror 2.0.18",+ "v_frame",+ "y4m",+]++[[package]]+name = "av1-grain"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8cfddb07216410377231960af4fcab838eaa12e013417781b78bd95ee22077f8"+dependencies = [+ "anyhow",+ "arrayvec",+ "log",+ "nom 8.0.0",+ "num-rational",+ "v_frame",+]++[[package]]+name = "avif-serialize"+version = "0.8.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e7178fe5f7d460b13895ebb9dcb28a3a6216d2df2574a0806cb51b555d297f38"+dependencies = [+ "arrayvec",+]++[[package]]+name = "aws-lc-rs"+version = "1.17.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4342d8937fc7e5dd9b1c60292261c0670c882a2cd1719cfc11b1af41731e32ad"+dependencies = [+ "aws-lc-sys",+ "zeroize",+]++[[package]]+name = "aws-lc-sys"+version = "0.42.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6d9ceb1da931507a12f4fccea479dccd00da1943e1b4ae72d8e502d707361444"+dependencies = [+ "cc",+ "cmake",+ "dunce",+ "fs_extra",+ "pkg-config",+]++[[package]]+name = "base64"+version = "0.22.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6"++[[package]]+name = "base64-simd"+version = "0.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "339abbe78e73178762e23bea9dfd08e697eb3f3301cd4be981c0f78ba5859195"+dependencies = [+ "outref",+ "vsimd",+]++[[package]]+name = "bit-set"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0700ddab506f33b20a03b13996eccd309a48e5ff77d0d95926aa0210fb4e95f1"+dependencies = [+ "bit-vec",+]++[[package]]+name = "bit-vec"+version = "0.6.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "349f9b6a179ed607305526ca489b34ad0a41aed5f7980fa90eb03160b69598fb"++[[package]]+name = "bit_field"+version = "0.10.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e4b40c7323adcfc0a41c4b88143ed58346ff65a288fc144329c5c45e05d70c6"++[[package]]+name = "bitflags"+version = "1.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a"++[[package]]+name = "bitflags"+version = "2.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b588b76d00fde79687d7646a9b5bdf3cc0f655e0bbd080335a95d7e96f3587da"++[[package]]+name = "bitstream-io"+version = "4.10.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7eff00be299a18769011411c9def0d827e8f2d7bf0c3dbf53633147a8867fd1f"+dependencies = [+ "no_std_io2",+]++[[package]]+name = "bitvec"+version = "1.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ddcec3d12c579d40898fe0a9a358a803c23e9c52ca3c425707f81c9436211837"+dependencies = [+ "funty",+ "radium",+ "tap",+ "wyz",+]++[[package]]+name = "block-buffer"+version = "0.10.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71"+dependencies = [+ "generic-array",+]++[[package]]+name = "block-buffer"+version = "0.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d2f6c7dbe95a6ed67ad9f18e57daf93a2f034c524b99fd2b76d18fdfeb6660aa"+dependencies = [+ "hybrid-array",+]++[[package]]+name = "built"+version = "0.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f4ad8f11f288f48ca24471bbd51ac257aaeaaa07adae295591266b792902ae64"++[[package]]+name = "bumpalo"+version = "3.20.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "72f5acc6cb2ba439de613abc23857ec3d78374d8ed5ac84e9d11336e87da8649"++[[package]]+name = "by_address"+version = "1.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "64fa3c856b712db6612c019f14756e64e4bcea13337a6b33b696333a9eaa2d06"++[[package]]+name = "bytemuck"+version = "1.25.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d6aedf8ae72766347502cf3cb4f41cf5e9cc37d28bee90f1fdaaae15f9cf9424"+dependencies = [+ "bytemuck_derive",+]++[[package]]+name = "bytemuck_derive"+version = "1.11.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f65693059b6b9c588b9f62fed1cedbf0a8b805631457ea162d68f0de186f3de5"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "byteorder-lite"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8f1fe948ff07f4bd06c30984e69f5b4899c516a3ef74f34df92a2df2ab535495"++[[package]]+name = "bytes"+version = "1.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc652a48c352aef3ea3aed32080501cf3ef6ed5da78602a020c991775b0aff04"++[[package]]+name = "castaway"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dec551ab6e7578819132c713a93c022a05d60159dc86e7a7050223577484c55a"+dependencies = [+ "rustversion",+]++[[package]]+name = "cc"+version = "1.2.67"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e17dd265a7d0f31ef544e1b20e03add05d3b45b491b633b10d67145d2acc1a38"+dependencies = [+ "find-msvc-tools",+ "jobserver",+ "libc",+ "shlex",+]++[[package]]+name = "cfg-if"+version = "1.0.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9330f8b2ff13f34540b44e946ef35111825727b38d33286ef986142615121801"++[[package]]+name = "cfg_aliases"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "613afe47fcd5fac7ccf1db93babcb082c5994d996f20b8b159f2ad1658eb5724"++[[package]]+name = "chacha20"+version = "0.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d524456ba66e72eb8b115ff89e01e497f8e6d11d78b70b1aa13c0fbd97540a81"+dependencies = [+ "cfg-if",+ "cpufeatures 0.3.0",+ "rand_core 0.10.1",+]++[[package]]+name = "cmake"+version = "0.1.58"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c0f78a02292a74a88ac736019ab962ece0bc380e3f977bf72e376c5d78ff0678"+dependencies = [+ "cc",+]++[[package]]+name = "cmov"+version = "0.5.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0c9ea0ac24bc397ab3c98583a3c9ba74fa56b09a4449bbe172b9b1ddb016027a"++[[package]]+name = "color_quant"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b"++[[package]]+name = "combine"+version = "4.6.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ba5a308b75df32fe02788e748662718f03fde005016435c444eea572398219fd"+dependencies = [+ "bytes",+ "memchr",+]++[[package]]+name = "compact_str"+version = "0.9.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9dfdd1c2274d9aa354115b09dc9a901d6c5576818cdf70d14cae2bdb47df00ab"+dependencies = [+ "castaway",+ "cfg-if",+ "itoa",+ "rustversion",+ "ryu",+ "static_assertions",+]++[[package]]+name = "const-oid"+version = "0.10.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a6ef517f0926dd24a1582492c791b6a4818a4d94e789a334894aa15b0d12f55c"++[[package]]+name = "convert_case"+version = "0.10.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "633458d4ef8c78b72454de2d54fd6ab2e60f9e02be22f3c6104cdc8a4e0fceb9"+dependencies = [+ "unicode-segmentation",+]++[[package]]+name = "core-foundation"+version = "0.9.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f"+dependencies = [+ "core-foundation-sys",+ "libc",+]++[[package]]+name = "core-foundation"+version = "0.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b2a6cd9ae233e7f62ba4e9353e81a88df7fc8a5987b8d445b4d90c879bd156f6"+dependencies = [+ "core-foundation-sys",+ "libc",+]++[[package]]+name = "core-foundation-sys"+version = "0.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b"++[[package]]+name = "cpufeatures"+version = "0.2.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280"+dependencies = [+ "libc",+]++[[package]]+name = "cpufeatures"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8b2a41393f66f16b0823bb79094d54ac5fbd34ab292ddafb9a0456ac9f87d201"+dependencies = [+ "libc",+]++[[package]]+name = "crc32fast"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9481c1c90cbf2ac953f07c8d4a58aa3945c425b7185c9154d67a65e4230da511"+dependencies = [+ "cfg-if",+]++[[package]]+name = "critical-section"+version = "1.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "790eea4361631c5e7d22598ecd5723ff611904e3344ce8720784c93e3d83d40b"++[[package]]+name = "crossbeam-deque"+version = "0.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5181e0de7b61eb03a81e347d6dd8797bae9da5146707b51077e2d71a54ec0ceb"+dependencies = [+ "crossbeam-epoch",+ "crossbeam-utils",+]++[[package]]+name = "crossbeam-epoch"+version = "0.9.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2d6914041f254d6e9176c01941b21115dcfb7089e55135a35411081bd106ef3f"+dependencies = [+ "crossbeam-utils",+]++[[package]]+name = "crossbeam-utils"+version = "0.8.22"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "61803da095bee82a81bb1a452ecc25d3b2f1416d1897eb86430c6159ef717c17"++[[package]]+name = "crossterm"+version = "0.29.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d8b9f2e4c67f833b660cdb0a3523065869fb35570177239812ed4c905aeff87b"+dependencies = [+ "bitflags 2.13.1",+ "crossterm_winapi",+ "derive_more",+ "document-features",+ "mio",+ "parking_lot",+ "rustix 1.1.4",+ "signal-hook",+ "signal-hook-mio",+ "winapi",+]++[[package]]+name = "crossterm_winapi"+version = "0.9.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "acdd7c62a3665c7f6830a51635d9ac9b23ed385797f70a83bb8bafe9c572ab2b"+dependencies = [+ "winapi",+]++[[package]]+name = "crunchy"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "460fbee9c2c2f33933d720630a6a0bac33ba7053db5344fac858d4b8952d77d5"++[[package]]+name = "crypto-common"+version = "0.1.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "78c8292055d1c1df0cce5d180393dc8cce0abec0a7102adb6c7b1eef6016d60a"+dependencies = [+ "generic-array",+ "typenum",+]++[[package]]+name = "crypto-common"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ce6e4c961d6cd6c9a86db418387425e8bdeaf05b3c8bc1411e6dca4c252f1453"+dependencies = [+ "hybrid-array",+]++[[package]]+name = "csscolorparser"+version = "0.6.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "eb2a7d3066da2de787b7f032c736763eb7ae5d355f81a68bab2675a96008b0bf"+dependencies = [+ "lab",+ "phf",+]++[[package]]+name = "ctutils"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7d5515a3834141de9eafb9717ad39eea8247b5674e6066c404e8c4b365d2a29e"+dependencies = [+ "cmov",+]++[[package]]+name = "darling"+version = "0.20.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc7f46116c46ff9ab3eb1597a45688b6715c6e628b5c133e288e709a29bcb4ee"+dependencies = [+ "darling_core",+ "darling_macro",+]++[[package]]+name = "darling_core"+version = "0.20.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0d00b9596d185e565c2207a0b01f8bd1a135483d02d9b7b0a54b11da8d53412e"+dependencies = [+ "fnv",+ "ident_case",+ "proc-macro2",+ "quote",+ "strsim",+ "syn 2.0.119",+]++[[package]]+name = "darling_macro"+version = "0.20.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fc34b93ccb385b40dc71c6fceac4b2ad23662c7eeb248cf10d529b7e055b6ead"+dependencies = [+ "darling_core",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "deltae"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5729f5117e208430e437df2f4843f5e5952997175992d1414f94c57d61e270b4"++[[package]]+name = "deranged"+version = "0.5.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7cd812cc2bc1d69d4764bd80df88b4317eaef9e773c75226407d9bc0876b211c"++[[package]]+name = "derive_more"+version = "2.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d751e9e49156b02b44f9c1815bcb94b984cdcc4396ecc32521c739452808b134"+dependencies = [+ "derive_more-impl",+]++[[package]]+name = "derive_more-impl"+version = "2.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "799a97264921d8623a957f6c3b9011f3b5492f557bbb7a5a19b7fa6d06ba8dcb"+dependencies = [+ "convert_case",+ "proc-macro2",+ "quote",+ "rustc_version",+ "syn 2.0.119",+]++[[package]]+name = "digest"+version = "0.10.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292"+dependencies = [+ "block-buffer 0.10.4",+ "crypto-common 0.1.7",+]++[[package]]+name = "digest"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f1dd6dbb5841937940781866fa1281a1ff7bd3bf827091440879f9994983d5c2"+dependencies = [+ "block-buffer 0.12.1",+ "const-oid",+ "crypto-common 0.2.2",+ "ctutils",+]++[[package]]+name = "displaydoc"+version = "0.2.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1ac70aa55017e108007fbaf5aa0f54b021c98f92ff8af59d42eda9da96e3dd4f"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "document-features"+version = "0.2.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d4b8a88685455ed29a21542a33abd9cb6510b6b129abadabdcef0f4c55bc8f61"+dependencies = [+ "litrs",+]++[[package]]+name = "dunce"+version = "1.0.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813"++[[package]]+name = "either"+version = "1.16.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "91622ff5e7162018101f2fea40d6ebf4a78bbe5a49736a2020649edf9693679e"++[[package]]+name = "encoding_rs"+version = "0.8.35"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "75030f3c4f45dafd7586dd6780965a8c7e8e285a5ecb86713e63a79c5b2766f3"+dependencies = [+ "cfg-if",+]++[[package]]+name = "equator"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4711b213838dfee0117e3be6ac926007d7f433d7bbe33595975d4190cb07e6fc"+dependencies = [+ "equator-macro",+]++[[package]]+name = "equator-macro"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "44f23cf4b44bfce11a86ace86f8a73ffdec849c9fd00a386a53d278bd9e81fb3"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "equivalent"+version = "1.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f"++[[package]]+name = "errno"+version = "0.3.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb"+dependencies = [+ "libc",+ "windows-sys 0.61.2",+]++[[package]]+name = "euclid"+version = "0.22.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f1a05365e3b1c6d1650318537c7460c6923f1abdd272ad6842baa2b509957a06"+dependencies = [+ "num-traits",+]++[[package]]+name = "exr"+version = "1.74.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "711fe42c9964295e01ee3fba3f9fe0e1d24b98886950d68efe81b1c76e21adf3"+dependencies = [+ "bit_field",+ "half",+ "lebe",+ "miniz_oxide",+ "num-complex",+ "pulp",+ "rayon-core",+ "smallvec",+ "zune-inflate",+]++[[package]]+name = "fancy-regex"+version = "0.11.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b95f7c0680e4142284cf8b22c14a476e87d61b004a3a0861872b32ef7ead40a2"+dependencies = [+ "bit-set",+ "regex",+]++[[package]]+name = "fast-srgb8"+version = "1.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dd2e7510819d6fbf51a5545c8f922716ecfb14df168a3242f7d33e0239efe6a1"++[[package]]+name = "fax"+version = "0.2.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "caf1079563223d5d59d83c85886a56e586cfd5c1a26292e971a0fa266531ac5a"++[[package]]+name = "fdeflate"+version = "0.3.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e6853b52649d4ac5c0bd02320cddc5ba956bdb407c4b75a2c6b75bf51500f8c"+dependencies = [+ "simd-adler32",+]++[[package]]+name = "filedescriptor"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e40758ed24c9b2eeb76c35fb0aebc66c626084edd827e07e1552279814c6682d"+dependencies = [+ "libc",+ "thiserror 1.0.69",+ "winapi",+]++[[package]]+name = "find-msvc-tools"+version = "0.1.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5baebc0774151f905a1a2cc41989300b1e6fbb29aff0ceffa1064fdd3088d582"++[[package]]+name = "finl_unicode"+version = "1.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9844ddc3a6e533d62bba727eb6c28b5d360921d5175e9ff0f1e621a5c590a4d5"++[[package]]+name = "fixedbitset"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80"++[[package]]+name = "flate2"+version = "1.1.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "843fba2746e448b37e26a819579957415c8cef339bf08564fe8b7ddbd959573c"+dependencies = [+ "crc32fast",+ "miniz_oxide",+]++[[package]]+name = "fnv"+version = "1.0.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1"++[[package]]+name = "foldhash"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb"++[[package]]+name = "form_urlencoded"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cb4cb245038516f5f85277875cdaa4f7d2c9a0fa0468de06ed190163b1581fcf"+dependencies = [+ "percent-encoding",+]++[[package]]+name = "fs_extra"+version = "1.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "42703706b716c37f96a77aea830392ad231f44c9e9a67872fa5548707e11b11c"++[[package]]+name = "funty"+version = "2.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c"++[[package]]+name = "futures-channel"+version = "0.3.32"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "07bbe89c50d7a535e539b8c17bc0b49bdb77747034daa8087407d655f3f7cc1d"+dependencies = [+ "futures-core",+]++[[package]]+name = "futures-core"+version = "0.3.32"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7e3450815272ef58cec6d564423f6e755e25379b217b0bc688e295ba24df6b1d"++[[package]]+name = "futures-sink"+version = "0.3.32"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c39754e157331b013978ec91992bde1ac089843443c49cbc7f46150b0fad0893"++[[package]]+name = "futures-task"+version = "0.3.32"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "037711b3d59c33004d3856fbdc83b99d4ff37a24768fa1be9ce3538a1cde4393"++[[package]]+name = "futures-util"+version = "0.3.32"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "389ca41296e6190b48053de0321d02a77f32f8a5d2461dd38762c0593805c6d6"+dependencies = [+ "futures-core",+ "futures-task",+ "pin-project-lite",+ "slab",+]++[[package]]+name = "generic-array"+version = "0.14.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a"+dependencies = [+ "typenum",+ "version_check",+]++[[package]]+name = "getrandom"+version = "0.2.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ff2abc00be7fca6ebc474524697ae276ad847ad0a6b3faa4bcb027e9a4614ad0"+dependencies = [+ "cfg-if",+ "js-sys",+ "libc",+ "wasi",+ "wasm-bindgen",+]++[[package]]+name = "getrandom"+version = "0.3.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd"+dependencies = [+ "cfg-if",+ "libc",+ "r-efi 5.3.0",+ "wasip2",+]++[[package]]+name = "getrandom"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099"+dependencies = [+ "cfg-if",+ "js-sys",+ "libc",+ "r-efi 6.0.0",+ "rand_core 0.10.1",+ "wasm-bindgen",+]++[[package]]+name = "gif"+version = "0.14.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ee8cfcc411d9adbbaba82fb72661cc1bcca13e8bba98b364e62b2dba8f960159"+dependencies = [+ "color_quant",+ "weezl",+]++[[package]]+name = "h2"+version = "0.4.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6cb093c84e8bd9b188d4c4a8cb6579fc016968d14c99882163cd3ff402a4f155"+dependencies = [+ "atomic-waker",+ "bytes",+ "fnv",+ "futures-core",+ "futures-sink",+ "http",+ "indexmap",+ "slab",+ "tokio",+ "tokio-util",+ "tracing",+]++[[package]]+name = "half"+version = "2.7.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6ea2d84b969582b4b1864a92dc5d27cd2b77b622a8d79306834f1be5ba20d84b"+dependencies = [+ "cfg-if",+ "crunchy",+ "zerocopy",+]++[[package]]+name = "hashbrown"+version = "0.16.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100"+dependencies = [+ "allocator-api2",+ "equivalent",+ "foldhash",+]++[[package]]+name = "hashbrown"+version = "0.17.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a"+dependencies = [+ "allocator-api2",+ "equivalent",+ "foldhash",+]++[[package]]+name = "heck"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea"++[[package]]+name = "hex"+version = "0.4.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70"++[[package]]+name = "hmac"+version = "0.13.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6303bc9732ae41b04cb554b844a762b4115a61bfaa81e3e83050991eeb56863f"+dependencies = [+ "digest 0.11.3",+]++[[package]]+name = "http"+version = "1.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6970f50e31d6fc17d3fa27329444bfa74e196cf62e95052a3f6fee181dba6425"+dependencies = [+ "bytes",+ "itoa",+]++[[package]]+name = "http-body"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ca2a8f2913ee65f60facd6a5905613afaa448497a0230cc41ce022d93290bc2c"+dependencies = [+ "bytes",+ "http",+]++[[package]]+name = "http-body-util"+version = "0.1.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e9f41fd6a08e4d4ec69df65976da761afd5ad5e58a9d4acb46bd1c953a9e3ff2"+dependencies = [+ "bytes",+ "futures-core",+ "http",+ "http-body",+ "pin-project-lite",+]++[[package]]+name = "httparse"+version = "1.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87"++[[package]]+name = "hybrid-array"+version = "0.4.13"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "818356c5132c1fede50f837ca96afbe78ff42413047f4abb886217845e1b6c8c"+dependencies = [+ "typenum",+]++[[package]]+name = "hyper"+version = "1.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "55281c53a1894c864990125767da440a4e630446785086f52523b20033b74498"+dependencies = [+ "atomic-waker",+ "bytes",+ "futures-channel",+ "futures-core",+ "h2",+ "http",+ "http-body",+ "httparse",+ "itoa",+ "pin-project-lite",+ "smallvec",+ "tokio",+ "want",+]++[[package]]+name = "hyper-rustls"+version = "0.27.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "33ca68d021ef39cf6463ab54c1d0f5daf03377b70561305bb89a8f83aab66e0f"+dependencies = [+ "http",+ "hyper",+ "hyper-util",+ "rustls",+ "tokio",+ "tokio-rustls",+ "tower-service",+]++[[package]]+name = "hyper-util"+version = "0.1.20"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "96547c2556ec9d12fb1578c4eaf448b04993e7fb79cbaad930a656880a6bdfa0"+dependencies = [+ "base64",+ "bytes",+ "futures-channel",+ "futures-util",+ "http",+ "http-body",+ "hyper",+ "ipnet",+ "libc",+ "percent-encoding",+ "pin-project-lite",+ "socket2",+ "system-configuration",+ "tokio",+ "tower-service",+ "tracing",+ "windows-registry",+]++[[package]]+name = "icu_collections"+version = "2.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4c6b649701667bbe825c3b7e6388cb521c23d88644678e83c0c4d0a621a34b43"+dependencies = [+ "displaydoc",+ "potential_utf",+ "yoke",+ "zerofrom",+ "zerovec",+]++[[package]]+name = "icu_locale_core"+version = "2.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "edba7861004dd3714265b4db54a3c390e880ab658fec5f7db895fae2046b5bb6"+dependencies = [+ "displaydoc",+ "litemap",+ "tinystr",+ "writeable",+ "zerovec",+]++[[package]]+name = "icu_normalizer"+version = "2.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5f6c8828b67bf8908d82127b2054ea1b4427ff0230ee9141c54251934ab1b599"+dependencies = [+ "icu_collections",+ "icu_normalizer_data",+ "icu_properties",+ "icu_provider",+ "smallvec",+ "zerovec",+]++[[package]]+name = "icu_normalizer_data"+version = "2.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7aedcccd01fc5fe81e6b489c15b247b8b0690feb23304303a9e560f37efc560a"++[[package]]+name = "icu_properties"+version = "2.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "020bfc02fe870ec3a66d93e677ccca0562506e5872c650f893269e08615d74ec"+dependencies = [+ "icu_collections",+ "icu_locale_core",+ "icu_properties_data",+ "icu_provider",+ "zerotrie",+ "zerovec",+]++[[package]]+name = "icu_properties_data"+version = "2.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "616c294cf8d725c6afcd8f55abc17c56464ef6211f9ed59cccffe534129c77af"++[[package]]+name = "icu_provider"+version = "2.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "85962cf0ce02e1e0a629cc34e7ca3e373ce20dda4c4d7294bbd0bf1fdb59e614"+dependencies = [+ "displaydoc",+ "icu_locale_core",+ "writeable",+ "yoke",+ "zerofrom",+ "zerotrie",+ "zerovec",+]++[[package]]+name = "icy_sixel"+version = "0.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "85518b9086bf01117761b90e7691c0ef3236fa8adfb1fb44dd248fe5f87215d5"+dependencies = [+ "quantette",+ "thiserror 2.0.18",+]++[[package]]+name = "ident_case"+version = "1.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39"++[[package]]+name = "idna"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3b0875f23caa03898994f6ddc501886a45c7d3d62d04d2d90788d47be1b1e4de"+dependencies = [+ "idna_adapter",+ "smallvec",+ "utf8_iter",+]++[[package]]+name = "idna_adapter"+version = "1.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3acae9609540aa318d1bc588455225fb2085b9ed0c4f6bd0d9d5bcd86f1a0344"+dependencies = [+ "icu_normalizer",+ "icu_properties",+]++[[package]]+name = "image"+version = "0.25.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "85ab80394333c02fe689eaf900ab500fbd0c2213da414687ebf995a65d5a6104"+dependencies = [+ "bytemuck",+ "byteorder-lite",+ "color_quant",+ "exr",+ "gif",+ "image-webp",+ "moxcms",+ "num-traits",+ "png",+ "qoi",+ "ravif",+ "rayon",+ "rgb",+ "tiff",+ "zune-core",+ "zune-jpeg",+]++[[package]]+name = "image-webp"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "525e9ff3e1a4be2fbea1fdf0e98686a6d98b4d8f937e1bf7402245af1909e8c3"+dependencies = [+ "byteorder-lite",+ "quick-error",+]++[[package]]+name = "imgref"+version = "1.12.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "89194689a993ab15268672e99e7b0e19da2da3268ac682e8f02d29d4d1434cd7"++[[package]]+name = "indexmap"+version = "2.14.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9"+dependencies = [+ "equivalent",+ "hashbrown 0.17.1",+]++[[package]]+name = "indoc"+version = "2.0.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "79cf5c93f93228cf8efb3ba362535fb11199ac548a09ce117c9b1adc3030d706"+dependencies = [+ "rustversion",+]++[[package]]+name = "instability"+version = "0.3.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6778b0196eefee7df739db78758e5cf9b37412268bfa5650bfeed028aed20d9c"+dependencies = [+ "darling",+ "indoc",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "interpolate_name"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c34819042dc3d3971c46c2190835914dfbe0c3c13f61449b2997f4e9722dfa60"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "ipnet"+version = "2.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d98f6fed1fde3f8c21bc40a1abb88dd75e67924f9cffc3ef95607bad8017f8e2"++[[package]]+name = "itertools"+version = "0.14.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2b192c782037fadd9cfa75548310488aabdbf3d2da73885b31bd0abd03351285"+dependencies = [+ "either",+]++[[package]]+name = "itoa"+version = "1.0.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682"++[[package]]+name = "jni"+version = "0.22.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5efd9a482cf3a427f00d6b35f14332adc7902ce91efb778580e180ff90fa3498"+dependencies = [+ "cfg-if",+ "combine",+ "jni-macros",+ "jni-sys",+ "log",+ "simd_cesu8",+ "thiserror 2.0.18",+ "walkdir",+ "windows-link",+]++[[package]]+name = "jni-macros"+version = "0.22.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a00109accc170f0bdb141fed3e393c565b6f5e072365c3bd58f5b062591560a3"+dependencies = [+ "proc-macro2",+ "quote",+ "rustc_version",+ "simd_cesu8",+ "syn 2.0.119",+]++[[package]]+name = "jni-sys"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c6377a88cb3910bee9b0fa88d4f42e1d2da8e79915598f65fb0c7ee14c878af2"+dependencies = [+ "jni-sys-macros",+]++[[package]]+name = "jni-sys-macros"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "38c0b942f458fe50cdac086d2f946512305e5631e720728f2a61aabcd47a6264"+dependencies = [+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "jobserver"+version = "0.1.35"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1c00acbd29eabad4a2392fa0e921c874934dbbf4194312ad20f04a0ed67a3cb3"+dependencies = [+ "getrandom 0.4.3",+ "libc",+]++[[package]]+name = "js-sys"+version = "0.3.103"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "53b44bfcdb3f8d5837a46dae1ca9660a837176eee74a28b229bc626816589102"+dependencies = [+ "cfg-if",+ "futures-util",+ "wasm-bindgen",+]++[[package]]+name = "kasuari"+version = "0.4.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bde5057d6143cc94e861d90f591b9303d6716c6b9602309150bd068853c10899"+dependencies = [+ "hashbrown 0.16.1",+ "portable-atomic",+ "thiserror 2.0.18",+]++[[package]]+name = "lab"+version = "0.11.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bf36173d4167ed999940f804952e6b08197cae5ad5d572eb4db150ce8ad5d58f"++[[package]]+name = "lazy_static"+version = "1.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe"++[[package]]+name = "lebe"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7a79a3332a6609480d7d0c9eab957bca6b455b91bb84e66d19f5ff66294b85b8"++[[package]]+name = "libc"+version = "0.2.186"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "68ab91017fe16c622486840e4c83c9a37afeff978bd239b5293d61ece587de66"++[[package]]+name = "libfuzzer-sys"+version = "0.4.13"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a9fd2f41a1cba099f79a0b6b6c35656cf7c03351a7bae8ff0f28f25270f929d2"+dependencies = [+ "arbitrary",+ "cc",+]++[[package]]+name = "libm"+version = "0.2.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6d2cec3eae94f9f509c767b45932f1ada8350c4bdb85af2fcab4a3c14807981"++[[package]]+name = "line-clipping"+version = "0.3.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3f50e8f47623268b5407192d26876c4d7f89d686ca130fdc53bced4814cd29f8"+dependencies = [+ "bitflags 2.13.1",+]++[[package]]+name = "linux-raw-sys"+version = "0.4.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab"++[[package]]+name = "linux-raw-sys"+version = "0.12.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32a66949e030da00e8c7d4434b251670a91556f4144941d37452769c25d58a53"++[[package]]+name = "litemap"+version = "0.8.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "92daf443525c4cce67b150400bc2316076100ce0b3686209eb8cf3c31612e6f0"++[[package]]+name = "litrs"+version = "1.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "11d3d7f243d5c5a8b9bb5d6dd2b1602c0cb0b9db1621bafc7ed66e35ff9fe092"++[[package]]+name = "lock_api"+version = "0.4.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "224399e74b87b5f3557511d98dff8b14089b3dadafcab6bb93eab67d3aace965"+dependencies = [+ "scopeguard",+]++[[package]]+name = "log"+version = "0.4.33"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ceec5bc11778974d1bcb055b18002eba7f4b3518b6a0081b3af5f21666da9ad"++[[package]]+name = "loop9"+version = "0.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0fae87c125b03c1d2c0150c90365d7d6bcc53fb73a9acaef207d2d065860f062"+dependencies = [+ "imgref",+]++[[package]]+name = "lru"+version = "0.18.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0b6180140927ee907000b0aa540091f6ea512ead4447c92b8fc35bc72788a5a6"+dependencies = [+ "hashbrown 0.17.1",+]++[[package]]+name = "lru-slab"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "112b39cec0b298b6c1999fee3e31427f74f676e4cb9879ed1a121b43661a4154"++[[package]]+name = "mac_address"+version = "1.1.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c0aeb26bf5e836cc1c341c8106051b573f1766dfa05aa87f0b98be5e51b02303"+dependencies = [+ "nix",+ "winapi",+]++[[package]]+name = "maybe-rayon"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8ea1f30cedd69f0a2954655f7188c6a834246d2bcf1e315e2ac40c4b24dc9519"+dependencies = [+ "cfg-if",+ "rayon",+]++[[package]]+name = "md-5"+version = "0.11.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "69b6441f590336821bb897fb28fc622898ccceb1d6cea3fde5ea86b090c4de98"+dependencies = [+ "cfg-if",+ "digest 0.11.3",+]++[[package]]+name = "memchr"+version = "2.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98"++[[package]]+name = "memmem"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a64a92489e2744ce060c349162be1c5f33c6969234104dbd99ddb5feb08b8c15"++[[package]]+name = "memoffset"+version = "0.9.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a"+dependencies = [+ "autocfg",+]++[[package]]+name = "mime"+version = "0.3.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a"++[[package]]+name = "minimal-lexical"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a"++[[package]]+name = "miniz_oxide"+version = "0.8.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1fa76a2c86f704bdb222d66965fb3d63269ce38518b83cb0575fca855ebb6316"+dependencies = [+ "adler2",+ "simd-adler32",+]++[[package]]+name = "mio"+version = "1.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "30d65c71f1ce40ab09135ce117d742b9f8a19ff91a41a8b57ed50bc2de59c427"+dependencies = [+ "libc",+ "log",+ "wasi",+ "windows-sys 0.61.2",+]++[[package]]+name = "moviebox"+version = "0.1.0"+dependencies = [+ "base64",+ "crossterm",+ "hmac",+ "image",+ "md-5",+ "rand 0.10.2",+ "ratatui",+ "ratatui-image",+ "reqwest",+ "serde",+ "serde_json",+ "thiserror 2.0.18",+ "tokio",+ "url",+]++[[package]]+name = "moxcms"+version = "0.8.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bb85c154ba489f01b25c0d36ae69a87e4a1c73a72631fc6c0eb6dde34a73e44b"+dependencies = [+ "num-traits",+ "pxfm",+]++[[package]]+name = "new_debug_unreachable"+version = "1.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086"++[[package]]+name = "nix"+version = "0.29.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "71e2746dc3a24dd78b3cfcb7be93368c6de9963d30f43a6a73998a9cf4b17b46"+dependencies = [+ "bitflags 2.13.1",+ "cfg-if",+ "cfg_aliases",+ "libc",+ "memoffset",+]++[[package]]+name = "no_std_io2"+version = "0.9.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "418abd1b6d34fbf6cae440dc874771b0525a604428704c76e48b29a5e67b8003"+dependencies = [+ "memchr",+]++[[package]]+name = "nom"+version = "7.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d273983c5a657a70a3e8f2a01329822f3b8c8172b73826411a55751e404a0a4a"+dependencies = [+ "memchr",+ "minimal-lexical",+]++[[package]]+name = "nom"+version = "8.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "df9761775871bdef83bee530e60050f7e54b1105350d6884eb0fb4f46c2f9405"+dependencies = [+ "memchr",+]++[[package]]+name = "noop_proc_macro"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0676bb32a98c1a483ce53e500a81ad9c3d5b3f7c920c28c24e9cb0980d0b5bc8"++[[package]]+name = "num-bigint"+version = "0.4.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c89e69e7e0f03bea5ef08013795c25018e101932225a656383bd384495ecc367"+dependencies = [+ "num-integer",+ "num-traits",+]++[[package]]+name = "num-complex"+version = "0.4.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "73f88a1307638156682bada9d7604135552957b7818057dcef22705b4d509495"+dependencies = [+ "bytemuck",+ "num-traits",+]++[[package]]+name = "num-conv"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "521739c6d2bac4aa25192232afe6841231376b2b26d4d9fae5ecf8ca5772e441"++[[package]]+name = "num-derive"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed3955f1a9c7c0c15e092f9c887db08b1fc683305fdf6eb6684f22555355e202"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "num-integer"+version = "0.1.46"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f"+dependencies = [+ "num-traits",+]++[[package]]+name = "num-rational"+version = "0.4.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f83d14da390562dca69fc84082e73e548e1ad308d24accdedd2720017cb37824"+dependencies = [+ "num-bigint",+ "num-integer",+ "num-traits",+]++[[package]]+name = "num-traits"+version = "0.2.19"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841"+dependencies = [+ "autocfg",+ "libm",+]++[[package]]+name = "num_threads"+version = "0.1.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c7398b9c8b70908f6371f47ed36737907c87c52af34c268fed0bf0ceb92ead9"+dependencies = [+ "libc",+]++[[package]]+name = "once_cell"+version = "1.21.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50"++[[package]]+name = "openssl-probe"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7c87def4c32ab89d880effc9e097653c8da5d6ef28e6b539d313baaacfbafcbe"++[[package]]+name = "ordered-float"+version = "4.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7bb71e1b3fa6ca1c61f383464aaf2bb0e2f8e772a1f01d486832464de363b951"+dependencies = [+ "num-traits",+]++[[package]]+name = "ordered-float"+version = "5.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b7d950ca161dc355eaf28f82b11345ed76c6e1f6eb1f4f4479e0323b9e2fbd0e"+dependencies = [+ "num-traits",+]++[[package]]+name = "outref"+version = "0.5.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1a80800c0488c3a21695ea981a54918fbb37abf04f4d0720c453632255e2ff0e"++[[package]]+name = "palette"+version = "0.7.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4cbf71184cc5ecc2e4e1baccdb21026c20e5fc3dcf63028a086131b3ab00b6e6"+dependencies = [+ "approx",+ "bytemuck",+ "fast-srgb8",+ "libm",+ "palette_derive",+]++[[package]]+name = "palette_derive"+version = "0.7.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f5030daf005bface118c096f510ffb781fc28f9ab6a32ab224d8631be6851d30"+dependencies = [+ "by_address",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "parking_lot"+version = "0.12.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "93857453250e3077bd71ff98b6a65ea6621a19bb0f559a85248955ac12c45a1a"+dependencies = [+ "lock_api",+ "parking_lot_core",+]++[[package]]+name = "parking_lot_core"+version = "0.9.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2621685985a2ebf1c516881c026032ac7deafcda1a2c9b7850dc81e3dfcb64c1"+dependencies = [+ "cfg-if",+ "libc",+ "redox_syscall",+ "smallvec",+ "windows-link",+]++[[package]]+name = "paste"+version = "1.0.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a"++[[package]]+name = "pastey"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "35fb2e5f958ec131621fdd531e9fc186ed768cbe395337403ae56c17a74c68ec"++[[package]]+name = "percent-encoding"+version = "2.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220"++[[package]]+name = "pest"+version = "2.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "47627dd7305c6a2d6c8c6bcd24c5a4c17dbbf425f4f9c5313e724b38fc9782e9"+dependencies = [+ "memchr",+ "ucd-trie",+]++[[package]]+name = "pest_derive"+version = "2.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4b4254325ecad416ab689e27ba51da03ba01a9632bc6e108f5fe7c3c4ad29d58"+dependencies = [+ "pest",+ "pest_generator",+]++[[package]]+name = "pest_generator"+version = "2.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6c4c0e91ead7a8f7acecbca6f003fc2e8282b1dbe2dd9c9d2f16aba42995e0a7"+dependencies = [+ "pest",+ "pest_meta",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "pest_meta"+version = "2.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f9744bc48116fee06334924bb5f2bad41eed5e89bd26e29b0b799f9a3f82c210"+dependencies = [+ "pest",+]++[[package]]+name = "phf"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1fd6780a80ae0c52cc120a26a1a42c1ae51b247a253e4e06113d23d2c2edd078"+dependencies = [+ "phf_macros",+ "phf_shared",+]++[[package]]+name = "phf_codegen"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "aef8048c789fa5e851558d709946d6d79a8ff88c0440c587967f8e94bfb1216a"+dependencies = [+ "phf_generator",+ "phf_shared",+]++[[package]]+name = "phf_generator"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3c80231409c20246a13fddb31776fb942c38553c51e871f8cbd687a4cfb5843d"+dependencies = [+ "phf_shared",+ "rand 0.8.7",+]++[[package]]+name = "phf_macros"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f84ac04429c13a7ff43785d75ad27569f2951ce0ffd30a3321230db2fc727216"+dependencies = [+ "phf_generator",+ "phf_shared",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "phf_shared"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "67eabc2ef2a60eb7faa00097bd1ffdb5bd28e62bf39990626a582201b7a754e5"+dependencies = [+ "siphasher",+]++[[package]]+name = "pin-project-lite"+version = "0.2.17"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd"++[[package]]+name = "pkg-config"+version = "0.3.33"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "19f132c84eca552bf34cab8ec81f1c1dcc229b811638f9d283dceabe58c5569e"++[[package]]+name = "png"+version = "0.18.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "60769b8b31b2a9f263dae2776c37b1b28ae246943cf719eb6946a1db05128a61"+dependencies = [+ "bitflags 2.13.1",+ "crc32fast",+ "fdeflate",+ "flate2",+ "miniz_oxide",+]++[[package]]+name = "portable-atomic"+version = "1.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c33a9471896f1c69cecef8d20cbe2f7accd12527ce60845ff44c153bb2a21b49"++[[package]]+name = "potential_utf"+version = "0.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0103b1cef7ec0cf76490e969665504990193874ea05c85ff9bab8b911d0a0564"+dependencies = [+ "zerovec",+]++[[package]]+name = "powerfmt"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391"++[[package]]+name = "ppv-lite86"+version = "0.2.21"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "85eae3c4ed2f50dcfe72643da4befc30deadb458a9b590d720cde2f2b1e97da9"+dependencies = [+ "zerocopy",+]++[[package]]+name = "proc-macro2"+version = "1.0.106"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934"+dependencies = [+ "unicode-ident",+]++[[package]]+name = "profiling"+version = "1.0.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3d595e54a326bc53c1c197b32d295e14b169e3cfeaa8dc82b529f947fba6bcf5"+dependencies = [+ "profiling-procmacros",+]++[[package]]+name = "profiling-procmacros"+version = "1.0.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4488a4a36b9a4ba6b9334a32a39971f77c1436ec82c38707bce707699cc3bbcb"+dependencies = [+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "pulp"+version = "0.22.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "046aa45b989642ec2e4717c8e72d677b13edd831a4d3b6cf37d9a3e54912496a"+dependencies = [+ "bytemuck",+ "cfg-if",+ "libm",+ "num-complex",+ "paste",+ "pulp-wasm-simd-flag",+ "raw-cpuid",+ "reborrow",+ "version_check",+]++[[package]]+name = "pulp-wasm-simd-flag"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1d8f70e07b9c3962945a74e59ca1c511bba65b6419468acc217c457d93f3c740"++[[package]]+name = "pxfm"+version = "0.1.30"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d55d956fa96f5ec02be2e13af0e20391a5aa83d6a074e3ad368959d0fab299ea"++[[package]]+name = "qoi"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7f6d64c71eb498fe9eae14ce4ec935c555749aef511cca85b5568910d6e48001"+dependencies = [+ "bytemuck",+]++[[package]]+name = "quantette"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c98fecda8b16396ff9adac67644a523dd1778c42b58606a29df5c31ca925d174"+dependencies = [+ "bitvec",+ "bytemuck",+ "image",+ "libm",+ "num-traits",+ "ordered-float 5.3.0",+ "palette",+ "rand 0.9.5",+ "rand_xoshiro",+ "rayon",+ "ref-cast",+ "wide",+]++[[package]]+name = "quick-error"+version = "2.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3"++[[package]]+name = "quinn"+version = "0.11.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0c1a41e437b6bbd489372cd4971de128e85c855f56c57f283d20ff016cf7c0a8"+dependencies = [+ "bytes",+ "cfg_aliases",+ "pin-project-lite",+ "quinn-proto",+ "quinn-udp",+ "rustc-hash",+ "rustls",+ "socket2",+ "thiserror 2.0.18",+ "tokio",+ "tracing",+ "web-time",+]++[[package]]+name = "quinn-proto"+version = "0.11.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2f4bfc015262b9df63c8845072ce59068853ff5872180c2ce2f13038b970e560"+dependencies = [+ "aws-lc-rs",+ "bytes",+ "getrandom 0.4.3",+ "lru-slab",+ "rand 0.10.2",+ "rand_pcg",+ "ring",+ "rustc-hash",+ "rustls",+ "rustls-pki-types",+ "slab",+ "thiserror 2.0.18",+ "tinyvec",+ "tracing",+ "web-time",+]++[[package]]+name = "quinn-udp"+version = "0.5.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "35a133f956daabe89a61a685c2649f13d82d5aa4bd5d12d1277e1072a21c0694"+dependencies = [+ "cfg_aliases",+ "libc",+ "once_cell",+ "socket2",+ "tracing",+ "windows-sys 0.61.2",+]++[[package]]+name = "quote"+version = "1.0.46"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dfbc457d0c7a0759a614551b11a6409e5951f6c7537be1f1b7682b9ae9230368"+dependencies = [+ "proc-macro2",+]++[[package]]+name = "r-efi"+version = "5.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f"++[[package]]+name = "r-efi"+version = "6.0.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf"++[[package]]+name = "radium"+version = "0.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dc33ff2d4973d518d823d61aa239014831e521c75da58e3df4840d3f47749d09"++[[package]]+name = "rand"+version = "0.8.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "22f6172bdec972074665ed81ed53b71da00bfc44b65a753cfde883ec4c702a1a"+dependencies = [+ "libc",+ "rand_chacha 0.3.1",+ "rand_core 0.6.4",+]++[[package]]+name = "rand"+version = "0.9.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b9ef1d0d795eb7d84685bca4f72f3649f064e6641543d3a8c415898726a57b41"+dependencies = [+ "rand_chacha 0.9.0",+ "rand_core 0.9.5",+]++[[package]]+name = "rand"+version = "0.10.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c7f5fa3a058cd35567ef9bfa5e75732bee0f9e4c55fa90477bef2dfcdbc4be80"+dependencies = [+ "chacha20",+ "getrandom 0.4.3",+ "rand_core 0.10.1",+]++[[package]]+name = "rand_chacha"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88"+dependencies = [+ "ppv-lite86",+ "rand_core 0.6.4",+]++[[package]]+name = "rand_chacha"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d3022b5f1df60f26e1ffddd6c66e8aa15de382ae63b3a0c1bfc0e4d3e3f325cb"+dependencies = [+ "ppv-lite86",+ "rand_core 0.9.5",+]++[[package]]+name = "rand_core"+version = "0.6.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c"+dependencies = [+ "getrandom 0.2.17",+]++[[package]]+name = "rand_core"+version = "0.9.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "76afc826de14238e6e8c374ddcc1fa19e374fd8dd986b0d2af0d02377261d83c"+dependencies = [+ "getrandom 0.3.4",+]++[[package]]+name = "rand_core"+version = "0.10.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "63b8176103e19a2643978565ca18b50549f6101881c443590420e4dc998a3c69"++[[package]]+name = "rand_pcg"+version = "0.10.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "caa0f4137e1c0a72f4c651489402276c8e8e1cf081f3b0ba156d2cbeef09e86a"+dependencies = [+ "rand_core 0.10.1",+]++[[package]]+name = "rand_xoshiro"+version = "0.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f703f4665700daf5512dcca5f43afa6af89f09db47fb56be587f80636bda2d41"+dependencies = [+ "rand_core 0.9.5",+]++[[package]]+name = "ratatui"+version = "0.30.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3274ba0a2c5e1bcad2a2005d20f4dc59dad26b2eb0940fb094500dba4099d57d"+dependencies = [+ "instability",+ "ratatui-core",+ "ratatui-crossterm",+ "ratatui-macros",+ "ratatui-termina",+ "ratatui-termwiz",+ "ratatui-widgets",+ "serde",+]++[[package]]+name = "ratatui-core"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cbb175c433c8e28a809d1f5773a2ae96e68c0ce40db865cbab1020bf33ae479c"+dependencies = [+ "bitflags 2.13.1",+ "compact_str",+ "critical-section",+ "hashbrown 0.17.1",+ "itertools",+ "kasuari",+ "lru",+ "palette",+ "serde",+ "strum",+ "thiserror 2.0.18",+ "unicode-segmentation",+ "unicode-truncate",+ "unicode-width",+]++[[package]]+name = "ratatui-crossterm"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "567584a3b0e6a8203c23de40b4861497266725eb5363dbfd18a1edd603cca9f0"+dependencies = [+ "cfg-if",+ "crossterm",+ "instability",+ "ratatui-core",+]++[[package]]+name = "ratatui-image"+version = "11.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e000b7a22eae639460bc6ec8bb1cc689ecae5b0ed21935cd7d7dd52d38270c86"+dependencies = [+ "base64-simd",+ "icy_sixel",+ "image",+ "pkg-config",+ "rand 0.8.7",+ "ratatui",+ "rustix 0.38.44",+ "self_cell",+ "thiserror 1.0.69",+ "windows",+]++[[package]]+name = "ratatui-macros"+version = "0.7.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed7dc68daa7498a43e4d68e0eb078427e10c38fbcfbb1e42d955f1fa2140d814"+dependencies = [+ "ratatui-core",+ "ratatui-widgets",+]++[[package]]+name = "ratatui-termina"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c0bf912d9e66f057a759d92e386a280ea886b352ab757d6ac4d653c7ed2c43c2"+dependencies = [+ "instability",+ "ratatui-core",+ "termina",+]++[[package]]+name = "ratatui-termwiz"+version = "0.1.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "faf03e0380b7744054d6cb74224fe3adf062a029754933f575ca1e3b4c2ce977"+dependencies = [+ "ratatui-core",+ "termwiz",+]++[[package]]+name = "ratatui-widgets"+version = "0.3.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "66e3d19bcc9130ca376277d93b60767ff121ace3be06f5f95f81dd68956407d1"+dependencies = [+ "bitflags 2.13.1",+ "hashbrown 0.17.1",+ "indoc",+ "instability",+ "itertools",+ "line-clipping",+ "ratatui-core",+ "serde",+ "strum",+ "time",+ "unicode-segmentation",+ "unicode-width",+]++[[package]]+name = "rav1e"+version = "0.8.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "43b6dd56e85d9483277cde964fd1bdb0428de4fec5ebba7540995639a21cb32b"+dependencies = [+ "aligned-vec",+ "arbitrary",+ "arg_enum_proc_macro",+ "arrayvec",+ "av-scenechange",+ "av1-grain",+ "bitstream-io",+ "built",+ "cfg-if",+ "interpolate_name",+ "itertools",+ "libc",+ "libfuzzer-sys",+ "log",+ "maybe-rayon",+ "new_debug_unreachable",+ "noop_proc_macro",+ "num-derive",+ "num-traits",+ "paste",+ "profiling",+ "rand 0.9.5",+ "rand_chacha 0.9.0",+ "simd_helpers",+ "thiserror 2.0.18",+ "v_frame",+ "wasm-bindgen",+]++[[package]]+name = "ravif"+version = "0.13.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e52310197d971b0f5be7fe6b57530dcd27beb35c1b013f29d66c1ad73fbbcc45"+dependencies = [+ "avif-serialize",+ "imgref",+ "loop9",+ "quick-error",+ "rav1e",+ "rayon",+ "rgb",+]++[[package]]+name = "raw-cpuid"+version = "11.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "498cd0dc59d73224351ee52a95fee0f1a617a2eae0e7d9d720cc622c73a54186"+dependencies = [+ "bitflags 2.13.1",+]++[[package]]+name = "rayon"+version = "1.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fb39b166781f92d482534ef4b4b1b2568f42613b53e5b6c160e24cfbfa30926d"+dependencies = [+ "either",+ "rayon-core",+]++[[package]]+name = "rayon-core"+version = "1.13.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "22e18b0f0062d30d4230b2e85ff77fdfe4326feb054b9783a3460d8435c8ab91"+dependencies = [+ "crossbeam-deque",+ "crossbeam-utils",+]++[[package]]+name = "reborrow"+version = "0.5.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "03251193000f4bd3b042892be858ee50e8b3719f2b08e5833ac4353724632430"++[[package]]+name = "redox_syscall"+version = "0.5.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d"+dependencies = [+ "bitflags 2.13.1",+]++[[package]]+name = "ref-cast"+version = "1.0.25"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f354300ae66f76f1c85c5f84693f0ce81d747e2c3f21a45fef496d89c960bf7d"+dependencies = [+ "ref-cast-impl",+]++[[package]]+name = "ref-cast-impl"+version = "1.0.25"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b7186006dcb21920990093f30e3dea63b7d6e977bf1256be20c3563a5db070da"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "regex"+version = "1.13.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f020237b6c8eed93db2e2cb53c00c60a8e1bc73da7d073199a1180401450218d"+dependencies = [+ "aho-corasick",+ "memchr",+ "regex-automata",+ "regex-syntax",+]++[[package]]+name = "regex-automata"+version = "0.4.16"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8fcfdb36bda0c880c5931cdc7a2bcdc8ba4556847b9d912bca70bc94708711ad"+dependencies = [+ "aho-corasick",+ "memchr",+ "regex-syntax",+]++[[package]]+name = "regex-syntax"+version = "0.8.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4"++[[package]]+name = "reqwest"+version = "0.13.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "219c5811de6525e5416c7d5d53bb656d3afdbc6c5af816e0802bcfa42dbdc1c3"+dependencies = [+ "base64",+ "bytes",+ "encoding_rs",+ "futures-core",+ "h2",+ "http",+ "http-body",+ "http-body-util",+ "hyper",+ "hyper-rustls",+ "hyper-util",+ "js-sys",+ "log",+ "mime",+ "percent-encoding",+ "pin-project-lite",+ "quinn",+ "rustls",+ "rustls-pki-types",+ "rustls-platform-verifier",+ "serde",+ "serde_json",+ "sync_wrapper",+ "tokio",+ "tokio-rustls",+ "tower",+ "tower-http",+ "tower-service",+ "url",+ "wasm-bindgen",+ "wasm-bindgen-futures",+ "web-sys",+]++[[package]]+name = "rgb"+version = "0.8.53"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "47b34b781b31e5d73e9fbc8689c70551fd1ade9a19e3e28cfec8580a79290cc4"++[[package]]+name = "ring"+version = "0.17.14"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a4689e6c2294d81e88dc6261c768b63bc4fcdb852be6d1352498b114f61383b7"+dependencies = [+ "cc",+ "cfg-if",+ "getrandom 0.2.17",+ "libc",+ "untrusted",+ "windows-sys 0.52.0",+]++[[package]]+name = "rustc-hash"+version = "2.1.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d"++[[package]]+name = "rustc_version"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92"+dependencies = [+ "semver",+]++[[package]]+name = "rustix"+version = "0.38.44"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154"+dependencies = [+ "bitflags 2.13.1",+ "errno",+ "libc",+ "linux-raw-sys 0.4.15",+ "windows-sys 0.59.0",+]++[[package]]+name = "rustix"+version = "1.1.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6fe4565b9518b83ef4f91bb47ce29620ca828bd32cb7e408f0062e9930ba190"+dependencies = [+ "bitflags 2.13.1",+ "errno",+ "libc",+ "linux-raw-sys 0.12.1",+ "windows-sys 0.61.2",+]++[[package]]+name = "rustls"+version = "0.23.42"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3c54fcab019b409d04215d3a17cb438fd7fbf192ee61461f20f4fe18704bc138"+dependencies = [+ "aws-lc-rs",+ "once_cell",+ "rustls-pki-types",+ "rustls-webpki",+ "subtle",+ "zeroize",+]++[[package]]+name = "rustls-native-certs"+version = "0.8.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dab5152771c58876a2146916e53e35057e1a4dfa2b9df0f0305b07f611fdea4d"+dependencies = [+ "openssl-probe",+ "rustls-pki-types",+ "schannel",+ "security-framework",+]++[[package]]+name = "rustls-pki-types"+version = "1.15.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "764899a24af3980067ee14bc143654f297b22eaebfe3c7b6b211920a5a59b046"+dependencies = [+ "web-time",+ "zeroize",+]++[[package]]+name = "rustls-platform-verifier"+version = "0.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "26d1e2536ce4f35f4846aa13bff16bd0ff40157cdb14cc056c7b14ba41233ba0"+dependencies = [+ "core-foundation 0.10.1",+ "core-foundation-sys",+ "jni",+ "log",+ "once_cell",+ "rustls",+ "rustls-native-certs",+ "rustls-platform-verifier-android",+ "rustls-webpki",+ "security-framework",+ "security-framework-sys",+ "webpki-root-certs",+ "windows-sys 0.61.2",+]++[[package]]+name = "rustls-platform-verifier-android"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f87165f0995f63a9fbeea62b64d10b4d9d8e78ec6d7d51fb2125fda7bb36788f"++[[package]]+name = "rustls-webpki"+version = "0.103.13"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "61c429a8649f110dddef65e2a5ad240f747e85f7758a6bccc7e5777bd33f756e"+dependencies = [+ "aws-lc-rs",+ "ring",+ "rustls-pki-types",+ "untrusted",+]++[[package]]+name = "rustversion"+version = "1.0.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f"++[[package]]+name = "ryu"+version = "1.0.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9774ba4a74de5f7b1c1451ed6cd5285a32eddb5cccb8cc655a4e50009e06477f"++[[package]]+name = "safe_arch"+version = "0.9.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "629516c85c29fe757770fa03f2074cf1eac43d44c02a3de9fc2ef7b0e207dfdd"+dependencies = [+ "bytemuck",+]++[[package]]+name = "same-file"+version = "1.0.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502"+dependencies = [+ "winapi-util",+]++[[package]]+name = "schannel"+version = "0.1.29"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "91c1b7e4904c873ef0710c1f407dde2e6287de2bebc1bbbf7d430bb7cbffd939"+dependencies = [+ "windows-sys 0.61.2",+]++[[package]]+name = "scopeguard"+version = "1.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49"++[[package]]+name = "security-framework"+version = "3.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b7f4bc775c73d9a02cde8bf7b2ec4c9d12743edf609006c7facc23998404cd1d"+dependencies = [+ "bitflags 2.13.1",+ "core-foundation 0.10.1",+ "core-foundation-sys",+ "libc",+ "security-framework-sys",+]++[[package]]+name = "security-framework-sys"+version = "2.17.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6ce2691df843ecc5d231c0b14ece2acc3efb62c0a398c7e1d875f3983ce020e3"+dependencies = [+ "core-foundation-sys",+ "libc",+]++[[package]]+name = "self_cell"+version = "1.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2ab42ca02749e120097e328d91d415325bdf43b1c72c4c8badf37375fe40a813"++[[package]]+name = "semver"+version = "1.0.28"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd"++[[package]]+name = "serde"+version = "1.0.228"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9a8e94ea7f378bd32cbbd37198a4a91436180c5bb472411e48b5ec2e2124ae9e"+dependencies = [+ "serde_core",+ "serde_derive",+]++[[package]]+name = "serde_core"+version = "1.0.228"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "41d385c7d4ca58e59fc732af25c3983b67ac852c1a25000afe1175de458b67ad"+dependencies = [+ "serde_derive",+]++[[package]]+name = "serde_derive"+version = "1.0.228"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "serde_json"+version = "1.0.150"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e8014e44b4736ed0538adeecded0fce2a272f22dc9578a7eb6b2d9993c74cfb9"+dependencies = [+ "itoa",+ "memchr",+ "serde",+ "serde_core",+ "zmij",+]++[[package]]+name = "sha2"+version = "0.10.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a7507d819769d01a365ab707794a4084392c824f54a7a6a7862f8c3d0892b283"+dependencies = [+ "cfg-if",+ "cpufeatures 0.2.17",+ "digest 0.10.7",+]++[[package]]+name = "shlex"+version = "2.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f8fadd59c855ef2080decdef8ff161eb6661b86933c9d82e5ba29dc602a55aba"++[[package]]+name = "signal-hook"+version = "0.3.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d881a16cf4426aa584979d30bd82cb33429027e42122b169753d6ef1085ed6e2"+dependencies = [+ "libc",+ "signal-hook-registry",+]++[[package]]+name = "signal-hook-mio"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b75a19a7a740b25bc7944bdee6172368f988763b744e3d4dfe753f6b4ece40cc"+dependencies = [+ "libc",+ "mio",+ "signal-hook",+]++[[package]]+name = "signal-hook-registry"+version = "1.4.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c4db69cba1110affc0e9f7bcd48bbf87b3f4fc7c61fc9155afd4c469eb3d6c1b"+dependencies = [+ "errno",+ "libc",+]++[[package]]+name = "simd-adler32"+version = "0.3.10"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "3a219298ac11a56ea9a6d2120044824d6f01aeb034955e7af7bc16858527deea"++[[package]]+name = "simd_cesu8"+version = "1.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "11031e251abf8611c80f460e19dbdeb54a66db918e49c65a7065b46ac7aec520"+dependencies = [+ "rustc_version",+ "simdutf8",+]++[[package]]+name = "simd_helpers"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "95890f873bec569a0362c235787f3aca6e1e887302ba4840839bcc6459c42da6"+dependencies = [+ "quote",+]++[[package]]+name = "simdutf8"+version = "0.1.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e3a9fe34e3e7a50316060351f37187a3f546bce95496156754b601a5fa71b76e"++[[package]]+name = "siphasher"+version = "1.0.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8ee5873ec9cce0195efcb7a4e9507a04cd49aec9c83d0389df45b1ef7ba2e649"++[[package]]+name = "slab"+version = "0.4.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5"++[[package]]+name = "smallvec"+version = "1.15.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8ed6a63f02c8539c91a8685a86f4099661ba3da017932f6ebbea6de3f0fa7c90"++[[package]]+name = "socket2"+version = "0.6.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c3d1e2c7f27f8d4cb10542a02c49005dbd6e93095799d6f3be745fae9f8fedd4"+dependencies = [+ "libc",+ "windows-sys 0.61.2",+]++[[package]]+name = "stable_deref_trait"+version = "1.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596"++[[package]]+name = "static_assertions"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f"++[[package]]+name = "strsim"+version = "0.11.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f"++[[package]]+name = "strum"+version = "0.28.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9628de9b8791db39ceda2b119bbe13134770b56c138ec1d3af810d045c04f9bd"+dependencies = [+ "strum_macros",+]++[[package]]+name = "strum_macros"+version = "0.28.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ab85eea0270ee17587ed4156089e10b9e6880ee688791d45a905f5b1ca36f664"+dependencies = [+ "heck",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "subtle"+version = "2.6.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292"++[[package]]+name = "syn"+version = "1.0.109"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237"+dependencies = [+ "proc-macro2",+ "quote",+ "unicode-ident",+]++[[package]]+name = "syn"+version = "2.0.119"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "872831b642d1a07999a962a351ed35b955ea2cfc8f3862091e2a240a84f17297"+dependencies = [+ "proc-macro2",+ "quote",+ "unicode-ident",+]++[[package]]+name = "sync_wrapper"+version = "1.0.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0bf256ce5efdfa370213c1dabab5935a12e49f2c58d15e9eac2870d3b4f27263"+dependencies = [+ "futures-core",+]++[[package]]+name = "synstructure"+version = "0.13.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "728a70f3dbaf5bab7f0c4b1ac8d7ae5ea60a4b5549c8a5914361c99147a709d2"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "system-configuration"+version = "0.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a13f3d0daba03132c0aa9767f98351b3488edc2c100cda2d2ec2b04f3d8d3c8b"+dependencies = [+ "bitflags 2.13.1",+ "core-foundation 0.9.4",+ "system-configuration-sys",+]++[[package]]+name = "system-configuration-sys"+version = "0.6.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8e1d1b10ced5ca923a1fcb8d03e96b8d3268065d724548c0211415ff6ac6bac4"+dependencies = [+ "core-foundation-sys",+ "libc",+]++[[package]]+name = "tap"+version = "1.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369"++[[package]]+name = "termina"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9048a889effe34a5cddee0af7f53285198b16dca3be510858d38dfdb3e62a04e"+dependencies = [+ "bitflags 2.13.1",+ "parking_lot",+ "rustix 1.1.4",+ "signal-hook",+ "windows-sys 0.61.2",+]++[[package]]+name = "terminfo"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "d4ea810f0692f9f51b382fff5893887bb4580f5fa246fde546e0b13e7fcee662"+dependencies = [+ "fnv",+ "nom 7.1.3",+ "phf",+ "phf_codegen",+]++[[package]]+name = "termios"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "411c5bf740737c7918b8b1fe232dca4dc9f8e754b8ad5e20966814001ed0ac6b"+dependencies = [+ "libc",+]++[[package]]+name = "termwiz"+version = "0.23.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4676b37242ccbd1aabf56edb093a4827dc49086c0ffd764a5705899e0f35f8f7"+dependencies = [+ "anyhow",+ "base64",+ "bitflags 2.13.1",+ "fancy-regex",+ "filedescriptor",+ "finl_unicode",+ "fixedbitset",+ "hex",+ "lazy_static",+ "libc",+ "log",+ "memmem",+ "nix",+ "num-derive",+ "num-traits",+ "ordered-float 4.6.0",+ "pest",+ "pest_derive",+ "phf",+ "sha2",+ "signal-hook",+ "siphasher",+ "terminfo",+ "termios",+ "thiserror 1.0.69",+ "ucd-trie",+ "unicode-segmentation",+ "vtparse",+ "wezterm-bidi",+ "wezterm-blob-leases",+ "wezterm-color-types",+ "wezterm-dynamic",+ "wezterm-input-types",+ "winapi",+]++[[package]]+name = "thiserror"+version = "1.0.69"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52"+dependencies = [+ "thiserror-impl 1.0.69",+]++[[package]]+name = "thiserror"+version = "2.0.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4288b5bcbc7920c07a1149a35cf9590a2aa808e0bc1eafaade0b80947865fbc4"+dependencies = [+ "thiserror-impl 2.0.18",+]++[[package]]+name = "thiserror-impl"+version = "1.0.69"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "thiserror-impl"+version = "2.0.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ebc4ee7f67670e9b64d05fa4253e753e016c6c95ff35b89b7941d6b856dec1d5"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "tiff"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b63feaf3343d35b6ca4d50483f94843803b0f51634937cc2ec519fc32232bc52"+dependencies = [+ "fax",+ "flate2",+ "half",+ "quick-error",+ "weezl",+ "zune-jpeg",+]++[[package]]+name = "time"+version = "0.3.53"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "18dfaaeddcb932337b5e7866ee7d0ce9b76d2fd092997146f187ec09b4558a50"+dependencies = [+ "deranged",+ "libc",+ "num-conv",+ "num_threads",+ "powerfmt",+ "serde_core",+ "time-core",+]++[[package]]+name = "time-core"+version = "0.1.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9e1c906769ad99c88eaa54e728060edef082f8e358ff32030cb7c7d315e81109"++[[package]]+name = "tinystr"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c8323304221c2a851516f22236c5722a72eaa19749016521d6dff0824447d96d"+dependencies = [+ "displaydoc",+ "zerovec",+]++[[package]]+name = "tinyvec"+version = "1.12.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bb4ebadaa0af04fab11ae01eb5f9fdb5f9c5b875506e210e71c07873528baa7f"+dependencies = [+ "tinyvec_macros",+]++[[package]]+name = "tinyvec_macros"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20"++[[package]]+name = "tokio"+version = "1.52.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8fc7f01b389ac15039e4dc9531aa973a135d7a4135281b12d7c1bc79fd57fffe"+dependencies = [+ "bytes",+ "libc",+ "mio",+ "parking_lot",+ "pin-project-lite",+ "signal-hook-registry",+ "socket2",+ "tokio-macros",+ "windows-sys 0.61.2",+]++[[package]]+name = "tokio-macros"+version = "2.7.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "385a6cb71ab9ab790c5fe8d67f1645e6c450a7ce006a33de03daa956cf70a496"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "tokio-rustls"+version = "0.26.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1729aa945f29d91ba541258c8df89027d5792d85a8841fb65e8bf0f4ede4ef61"+dependencies = [+ "rustls",+ "tokio",+]++[[package]]+name = "tokio-util"+version = "0.7.18"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9ae9cec805b01e8fc3fd2fe289f89149a9b66dd16786abd8b19cfa7b48cb0098"+dependencies = [+ "bytes",+ "futures-core",+ "futures-sink",+ "pin-project-lite",+ "tokio",+]++[[package]]+name = "tower"+version = "0.5.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ebe5ef63511595f1344e2d5cfa636d973292adc0eec1f0ad45fae9f0851ab1d4"+dependencies = [+ "futures-core",+ "futures-util",+ "pin-project-lite",+ "sync_wrapper",+ "tokio",+ "tower-layer",+ "tower-service",+]++[[package]]+name = "tower-http"+version = "0.6.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4cfcf7e2740e6fc6d4d688b4ef00650406bb94adf4731e43c096c3a19fe40840"+dependencies = [+ "bitflags 2.13.1",+ "bytes",+ "futures-util",+ "http",+ "http-body",+ "pin-project-lite",+ "tower",+ "tower-layer",+ "tower-service",+ "url",+]++[[package]]+name = "tower-layer"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e"++[[package]]+name = "tower-service"+version = "0.3.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3"++[[package]]+name = "tracing"+version = "0.1.44"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "63e71662fa4b2a2c3a26f570f037eb95bb1f85397f3cd8076caed2f026a6d100"+dependencies = [+ "pin-project-lite",+ "tracing-core",+]++[[package]]+name = "tracing-core"+version = "0.1.36"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "db97caf9d906fbde555dd62fa95ddba9eecfd14cb388e4f491a66d74cd5fb79a"+dependencies = [+ "once_cell",+]++[[package]]+name = "try-lock"+version = "0.2.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b"++[[package]]+name = "typenum"+version = "1.20.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6f5e870be6c3b371b77fe0ee0bafb859fa4964b4404c27de1d380043c4dda20"++[[package]]+name = "ucd-trie"+version = "0.1.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2896d95c02a80c6d6a5d6e953d479f5ddf2dfdb6a244441010e373ac0fb88971"++[[package]]+name = "unicode-ident"+version = "1.0.24"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75"++[[package]]+name = "unicode-segmentation"+version = "1.13.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8"++[[package]]+name = "unicode-truncate"+version = "2.0.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "16b380a1238663e5f8a691f9039c73e1cdae598a30e9855f541d29b08b53e9a5"+dependencies = [+ "itertools",+ "unicode-segmentation",+ "unicode-width",+]++[[package]]+name = "unicode-width"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b4ac048d71ede7ee76d585517add45da530660ef4390e49b098733c6e897f254"++[[package]]+name = "untrusted"+version = "0.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1"++[[package]]+name = "url"+version = "2.5.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ff67a8a4397373c3ef660812acab3268222035010ab8680ec4215f38ba3d0eed"+dependencies = [+ "form_urlencoded",+ "idna",+ "percent-encoding",+ "serde",+]++[[package]]+name = "utf8_iter"+version = "1.0.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be"++[[package]]+name = "utf8parse"+version = "0.2.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821"++[[package]]+name = "uuid"+version = "1.24.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bf3923a6f5c4c6382e0b653c4117f48d631ea17f38ed86e2a828e6f7412f5239"+dependencies = [+ "atomic",+ "getrandom 0.4.3",+ "js-sys",+ "wasm-bindgen",+]++[[package]]+name = "v_frame"+version = "0.3.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "666b7727c8875d6ab5db9533418d7c764233ac9c0cff1d469aec8fa127597be2"+dependencies = [+ "aligned-vec",+ "num-traits",+ "wasm-bindgen",+]++[[package]]+name = "version_check"+version = "0.9.5"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a"++[[package]]+name = "vsimd"+version = "0.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c3082ca00d5a5ef149bb8b555a72ae84c9c59f7250f013ac822ac2e49b19c64"++[[package]]+name = "vtparse"+version = "0.6.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6d9b2acfb050df409c972a37d3b8e08cdea3bddb0c09db9d53137e504cfabed0"+dependencies = [+ "utf8parse",+]++[[package]]+name = "walkdir"+version = "2.5.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b"+dependencies = [+ "same-file",+ "winapi-util",+]++[[package]]+name = "want"+version = "0.3.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e"+dependencies = [+ "try-lock",+]++[[package]]+name = "wasi"+version = "0.11.1+wasi-snapshot-preview1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b"++[[package]]+name = "wasip2"+version = "1.0.1+wasi-0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0562428422c63773dad2c345a1882263bbf4d65cf3f42e90921f787ef5ad58e7"+dependencies = [+ "wit-bindgen",+]++[[package]]+name = "wasm-bindgen"+version = "0.2.126"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4b067c0c11094aef6b7a801c1e34a26affafdf3d051dba08456b868789aaf9a4"+dependencies = [+ "cfg-if",+ "once_cell",+ "rustversion",+ "wasm-bindgen-macro",+ "wasm-bindgen-shared",+]++[[package]]+name = "wasm-bindgen-futures"+version = "0.4.76"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c62df1340f32221cb9c54d6a27b030e3dba64361d4a95bed55f9aacb44da291d"+dependencies = [+ "js-sys",+ "wasm-bindgen",+]++[[package]]+name = "wasm-bindgen-macro"+version = "0.2.126"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "167ce5e579f6bcf889c4f7175a8a5a585de84e8ff93976ce393efa5f2837aab1"+dependencies = [+ "quote",+ "wasm-bindgen-macro-support",+]++[[package]]+name = "wasm-bindgen-macro-support"+version = "0.2.126"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f3997c7839262f4ef12cf90b818d6340c18e80f263f1a94bf157d0ec4420380e"+dependencies = [+ "bumpalo",+ "proc-macro2",+ "quote",+ "syn 2.0.119",+ "wasm-bindgen-shared",+]++[[package]]+name = "wasm-bindgen-shared"+version = "0.2.126"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dc1b4cb0cc549fcf58d7dfc081778139b3d283a081644e833e84682ad71cea24"+dependencies = [+ "unicode-ident",+]++[[package]]+name = "web-sys"+version = "0.3.103"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8622dcb61c0bcc9fffa6938bed81210af2da9a7e4a1a834b2e37a59b6dfb6141"+dependencies = [+ "js-sys",+ "wasm-bindgen",+]++[[package]]+name = "web-time"+version = "1.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5a6580f308b1fad9207618087a65c04e7a10bc77e02c8e84e9b00dd4b12fa0bb"+dependencies = [+ "js-sys",+ "wasm-bindgen",+]++[[package]]+name = "webpki-root-certs"+version = "1.0.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0d46a5a140e6f7afeccd8eae97eff335163939eac8b929834875168b29b3d267"+dependencies = [+ "rustls-pki-types",+]++[[package]]+name = "weezl"+version = "0.1.12"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "a28ac98ddc8b9274cb41bb4d9d4d5c425b6020c50c46f25559911905610b4a88"++[[package]]+name = "wezterm-bidi"+version = "0.2.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0c0a6e355560527dd2d1cf7890652f4f09bb3433b6aadade4c9b5ed76de5f3ec"+dependencies = [+ "log",+ "wezterm-dynamic",+]++[[package]]+name = "wezterm-blob-leases"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "692daff6d93d94e29e4114544ef6d5c942a7ed998b37abdc19b17136ea428eb7"+dependencies = [+ "getrandom 0.3.4",+ "mac_address",+ "sha2",+ "thiserror 1.0.69",+ "uuid",+]++[[package]]+name = "wezterm-color-types"+version = "0.3.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7de81ef35c9010270d63772bebef2f2d6d1f2d20a983d27505ac850b8c4b4296"+dependencies = [+ "csscolorparser",+ "deltae",+ "lazy_static",+ "wezterm-dynamic",+]++[[package]]+name = "wezterm-dynamic"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5f2ab60e120fd6eaa68d9567f3226e876684639d22a4219b313ff69ec0ccd5ac"+dependencies = [+ "log",+ "ordered-float 4.6.0",+ "strsim",+ "thiserror 1.0.69",+ "wezterm-dynamic-derive",+]++[[package]]+name = "wezterm-dynamic-derive"+version = "0.1.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "46c0cf2d539c645b448eaffec9ec494b8b19bd5077d9e58cb1ae7efece8d575b"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 1.0.109",+]++[[package]]+name = "wezterm-input-types"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7012add459f951456ec9d6c7e6fc340b1ce15d6fc9629f8c42853412c029e57e"+dependencies = [+ "bitflags 1.3.2",+ "euclid",+ "lazy_static",+ "serde",+ "wezterm-dynamic",+]++[[package]]+name = "wide"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "13ca908d26e4786149c48efcf6c0ea09ab0e06d1fe3c17dc1b4b0f1ca4a7e788"+dependencies = [+ "bytemuck",+ "safe_arch",+]++[[package]]+name = "winapi"+version = "0.3.9"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "5c839a674fcd7a98952e593242ea400abe93992746761e38641405d28b00f419"+dependencies = [+ "winapi-i686-pc-windows-gnu",+ "winapi-x86_64-pc-windows-gnu",+]++[[package]]+name = "winapi-i686-pc-windows-gnu"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6"++[[package]]+name = "winapi-util"+version = "0.1.11"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22"+dependencies = [+ "windows-sys 0.61.2",+]++[[package]]+name = "winapi-x86_64-pc-windows-gnu"+version = "0.4.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"++[[package]]+name = "windows"+version = "0.58.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "dd04d41d93c4992d421894c18c8b43496aa748dd4c081bac0dc93eb0489272b6"+dependencies = [+ "windows-core",+ "windows-targets",+]++[[package]]+name = "windows-core"+version = "0.58.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "6ba6d44ec8c2591c134257ce647b7ea6b20335bf6379a27dac5f1641fcf59f99"+dependencies = [+ "windows-implement",+ "windows-interface",+ "windows-result 0.2.0",+ "windows-strings 0.1.0",+ "windows-targets",+]++[[package]]+name = "windows-implement"+version = "0.58.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "2bbd5b46c938e506ecbce286b6628a02171d56153ba733b6c741fc627ec9579b"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "windows-interface"+version = "0.58.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "053c4c462dc91d3b1504c6fe5a726dd15e216ba718e84a0e46a88fbe5ded3515"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "windows-link"+version = "0.2.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5"++[[package]]+name = "windows-registry"+version = "0.6.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "02752bf7fbdcce7f2a27a742f798510f3e5ad88dbe84871e5168e2120c3d5720"+dependencies = [+ "windows-link",+ "windows-result 0.4.1",+ "windows-strings 0.5.1",+]++[[package]]+name = "windows-result"+version = "0.2.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1d1043d8214f791817bab27572aaa8af63732e11bf84aa21a45a78d6c317ae0e"+dependencies = [+ "windows-targets",+]++[[package]]+name = "windows-result"+version = "0.4.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5"+dependencies = [+ "windows-link",+]++[[package]]+name = "windows-strings"+version = "0.1.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "4cd9b125c486025df0eabcb585e62173c6c9eddcec5d117d3b6e8c30e2ee4d10"+dependencies = [+ "windows-result 0.2.0",+ "windows-targets",+]++[[package]]+name = "windows-strings"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091"+dependencies = [+ "windows-link",+]++[[package]]+name = "windows-sys"+version = "0.52.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d"+dependencies = [+ "windows-targets",+]++[[package]]+name = "windows-sys"+version = "0.59.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b"+dependencies = [+ "windows-targets",+]++[[package]]+name = "windows-sys"+version = "0.61.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc"+dependencies = [+ "windows-link",+]++[[package]]+name = "windows-targets"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973"+dependencies = [+ "windows_aarch64_gnullvm",+ "windows_aarch64_msvc",+ "windows_i686_gnu",+ "windows_i686_gnullvm",+ "windows_i686_msvc",+ "windows_x86_64_gnu",+ "windows_x86_64_gnullvm",+ "windows_x86_64_msvc",+]++[[package]]+name = "windows_aarch64_gnullvm"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3"++[[package]]+name = "windows_aarch64_msvc"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469"++[[package]]+name = "windows_i686_gnu"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b"++[[package]]+name = "windows_i686_gnullvm"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66"++[[package]]+name = "windows_i686_msvc"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66"++[[package]]+name = "windows_x86_64_gnu"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78"++[[package]]+name = "windows_x86_64_gnullvm"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d"++[[package]]+name = "windows_x86_64_msvc"+version = "0.52.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec"++[[package]]+name = "wit-bindgen"+version = "0.46.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "f17a85883d4e6d00e8a97c586de764dabcc06133f7f1d55dce5cdc070ad7fe59"++[[package]]+name = "writeable"+version = "0.6.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "1ffae5123b2d3fc086436f8834ae3ab053a283cfac8fe0a0b8eaae044768a4c4"++[[package]]+name = "wyz"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "05f360fc0b24296329c78fda852a1e9ae82de9cf7b27dae4b7f62f118f77b9ed"+dependencies = [+ "tap",+]++[[package]]+name = "y4m"+version = "0.8.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "7a5a4b21e1a62b67a2970e6831bc091d7b87e119e7f9791aef9702e3bef04448"++[[package]]+name = "yoke"+version = "0.8.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "709fe23a0424b6a435d82152b1bd3fdfb0833487d5fa90d05d42762a9891fef5"+dependencies = [+ "stable_deref_trait",+ "yoke-derive",+ "zerofrom",+]++[[package]]+name = "yoke-derive"+version = "0.8.2"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "de844c262c8848816172cef550288e7dc6c7b7814b4ee56b3e1553f275f1858e"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+ "synstructure",+]++[[package]]+name = "zerocopy"+version = "0.8.54"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "b7cbbc0a705a0fd05cc3676525980d2bf5a9bc4adac6d6475209a7887cf59d19"+dependencies = [+ "zerocopy-derive",+]++[[package]]+name = "zerocopy-derive"+version = "0.8.54"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e2e817b7b52d0c7358d3246da9d69935ebb18116b2b102b4230dac079b4862f5"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "zerofrom"+version = "0.1.8"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0ec05a11813ea801ff6d75110ad09cd0824ddba17dfe17128ea0d5f68e6c5272"+dependencies = [+ "zerofrom-derive",+]++[[package]]+name = "zerofrom-derive"+version = "0.1.7"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "11532158c46691caf0f2593ea8358fed6bbf68a0315e80aae9bd41fbade684a1"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+ "synstructure",+]++[[package]]+name = "zeroize"+version = "1.9.0"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "e13c156562582aa81c60cb29407084cdb54c4164760106ab78e6c5b0858cf64e"++[[package]]+name = "zerotrie"+version = "0.2.4"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "0f9152d31db0792fa83f70fb2f83148effb5c1f5b8c7686c3459e361d9bc20bf"+dependencies = [+ "displaydoc",+ "yoke",+ "zerofrom",+]++[[package]]+name = "zerovec"+version = "0.11.6"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "90f911cbc359ab6af17377d242225f4d75119aec87ea711a880987b18cd7b239"+dependencies = [+ "yoke",+ "zerofrom",+ "zerovec-derive",+]++[[package]]+name = "zerovec-derive"+version = "0.11.3"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "625dc425cab0dca6dc3c3319506e6593dcb08a9f387ea3b284dbd52a92c40555"+dependencies = [+ "proc-macro2",+ "quote",+ "syn 2.0.119",+]++[[package]]+name = "zmij"+version = "1.0.23"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b"++[[package]]+name = "zune-core"+version = "0.5.1"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "cb8a0807f7c01457d0379ba880ba6322660448ddebc890ce29bb64da71fb40f9"++[[package]]+name = "zune-inflate"+version = "0.2.54"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "73ab332fe2f6680068f3582b16a24f90ad7096d5d39b974d1c0aff0125116f02"+dependencies = [+ "simd-adler32",+]++[[package]]+name = "zune-jpeg"+version = "0.5.15"+source = "registry+https://github.com/rust-lang/crates.io-index"+checksum = "27bc9d5b815bc103f142aa054f561d9187d191692ec7c2d1e2b4737f8dbd7296"+dependencies = [+ "zune-core",+]diff --git a/Cargo.toml b/Cargo.tomlnew file mode 100644index 0000000..ebb39ec--- /dev/null+++ b/Cargo.toml@@ -0,0 +1,32 @@+[package]+name = "moviebox"+version = "0.1.0"+edition = "2024"+description = "A terminal user interface (TUI) client for MovieBox API."+repository = "https://github.com/mesamirh/MovieBox"+homepage = "https://github.com/mesamirh/MovieBox"+license = "MIT OR Apache-2.0"+keywords = ["tui", "moviebox", "scraper", "streaming", "cli"]+categories = ["command-line-utilities", "multimedia"]+readme = "README.md"+rust-version = "1.85.0"++[dependencies]+base64 = "0.22.1"+crossterm = "0.29.0"+hmac = "0.13.0"+image = "0.25.10"+md-5 = "0.11.0"+rand = "0.10.2"+ratatui = "0.30.2"+ratatui-image = "11.0.6"+reqwest = { version = "0.13.4", features = ["json"] }+serde = { version = "1.0.228", features = ["derive"] }+serde_json = "1.0.150"+thiserror = "2.0.18"+tokio = { version = "1.52.3", features = ["full"] }+url = "2.5.8"++[lib]+name = "moviebox"+path = "src/lib.rs"diff --git a/LICENSE b/LICENSEnew file mode 100644index 0000000..015503c--- /dev/null+++ b/LICENSE@@ -0,0 +1,21 @@+MIT License++Copyright (c) 2026 MovieBox Contributors++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all+copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE+SOFTWARE.diff --git a/README.md b/README.mdnew file mode 100644index 0000000..a484a84--- /dev/null+++ b/README.md@@ -0,0 +1,59 @@+# MovieBox++A lightning fast, zero-config terminal user interface (TUI) for streaming movies and TV series directly from your terminal.++## Installation++```sh+cargo install moviebox+```++*Note: Requires `mpv` installed on your system for video playback.*++## Usage++Launch the app from your terminal:++```sh+moviebox+```++- **Search**: Press `/` to search for movies or shows.+- **Play**: Select a result and press `Enter` to stream instantly.+- **Logs**: Press `Ctrl+L` to view internal network logs.+- **Quit**: Press `q` or `Esc` to exit.++## Features++- Instant streaming with `mpv`+- Full metadata (seasons, episodes, dubs, and subs)+- Built in geo-unblocking (zero VPN required)+- Copy direct stream URLs to clipboard++## Screenshots++<details>+<summary>Click to view screenshots</summary>++<br>++### Home Screen+<img src="assets/screenshots/1-home.jpg" alt="Home Screen" width="800">++### Search Results+<img src="assets/screenshots/2-search.jpg" alt="Search Results" width="800">++### Movie Details+<img src="assets/screenshots/3-movie.jpg" alt="Movie Details" width="800">++### Stream Selection+<img src="assets/screenshots/4-streams.jpg" alt="Stream Selection" width="800">++### TV Series Details+<img src="assets/screenshots/5-series.jpg" alt="TV Series Details" width="800">++</details>++## License++Dual-licensed under MIT or Apache-2.0.diff --git a/SECURITY.md b/SECURITY.mdnew file mode 100644index 0000000..55afda0--- /dev/null+++ b/SECURITY.md@@ -0,0 +1,12 @@+# Security Policy++## Supported Versions++| Version | Supported |+| ------- | ------------------ |+| >= 0.1.x| :white_check_mark: |+| < 0.1.0 | :x: |++## Reporting a Vulnerability++If you discover a security vulnerability within this project, please send an e-mail to the maintainers. All security vulnerabilities will be promptly addressed.diff --git a/assets/screenshots/1-home.jpg b/assets/screenshots/1-home.jpgnew file mode 100644index 0000000..52ab7afBinary files /dev/null and b/assets/screenshots/1-home.jpg differdiff --git a/assets/screenshots/2-search.jpg b/assets/screenshots/2-search.jpgnew file mode 100644index 0000000..f495b69Binary files /dev/null and b/assets/screenshots/2-search.jpg differdiff --git a/assets/screenshots/3-movie.jpg b/assets/screenshots/3-movie.jpgnew file mode 100644index 0000000..32c179dBinary files /dev/null and b/assets/screenshots/3-movie.jpg differdiff --git a/assets/screenshots/4-streams.jpg b/assets/screenshots/4-streams.jpgnew file mode 100644index 0000000..dd95b8cBinary files /dev/null and b/assets/screenshots/4-streams.jpg differdiff --git a/assets/screenshots/5-series.jpg b/assets/screenshots/5-series.jpgnew file mode 100644index 0000000..bcec4e8Binary files /dev/null and b/assets/screenshots/5-series.jpg differdiff --git a/src/lib.rs b/src/lib.rsnew file mode 100644index 0000000..8a76791--- /dev/null+++ b/src/lib.rs@@ -0,0 +1,3 @@++pub mod tui;+pub mod v3;diff --git a/src/main.rs b/src/main.rsnew file mode 100644index 0000000..1fd1284--- /dev/null+++ b/src/main.rs@@ -0,0 +1,13 @@+use moviebox::tui::app::App;++#[tokio::main]+async fn main() -> std::io::Result<()> {+ let mut terminal = ratatui::init();++ let mut app = App::new();+ let result = app.run(&mut terminal).await;++ ratatui::restore();++ result+}diff --git a/src/tui/action.rs b/src/tui/action.rsnew file mode 100644index 0000000..e9a86c5--- /dev/null+++ b/src/tui/action.rs@@ -0,0 +1,39 @@+#[derive(Debug, Clone)]+pub enum Action {+ Tick,+ Key(crossterm::event::KeyEvent),+ Quit,+ GoBack,+ SelectLanguage(usize),+ ToggleLogs,+ ToggleHelp,+ Search(String),+ SearchSuccess(serde_json::Value),+ SearchFailure(String),+ MoveUp,+ MoveDown,+ MoveLeft,+ MoveRight,+ Submit,+ FetchPreview(String),+ PreviewSuccess(String, serde_json::Value),+ PreviewFailure(String),+ CopyLink,+ PlayStream,+ DownloadStream,+ UpdateDownload(Option<f64>, Option<String>),+ CancelDownload,+ FetchDetails(String),+ DetailsSuccess(String, serde_json::Value),+ DetailsFailure(String),+ FetchResources {+ subject_id: String,+ season: usize,+ episode: usize,+ resolution: String,+ },+ ResourcesSuccess(serde_json::Value),+ ResourcesFailure(String),+ PosterSuccess(String, std::sync::Arc<image::DynamicImage>),+ Log(String),+}diff --git a/src/tui/app.rs b/src/tui/app.rsnew file mode 100644index 0000000..cdcf01b--- /dev/null+++ b/src/tui/app.rs@@ -0,0 +1,1450 @@+use ratatui::{DefaultTerminal, Frame};+use std::time::Duration;+use tokio::sync::mpsc;++use crate::tui::{+ action::Action,+ event::EventHandler,+ state::{AppState, InputMode, Screen, SearchResult},+ theme::Theme,+};+use crate::v3::client::MovieBoxClient;++pub struct App {+ state: AppState,+ theme: Theme,+ client: MovieBoxClient,+ action_sender: mpsc::UnboundedSender<Action>,+ action_receiver: mpsc::UnboundedReceiver<Action>,+}++impl Default for App {+ fn default() -> Self {+ Self::new()+ }+}++impl App {+ pub fn new() -> Self {+ let (action_sender, action_receiver) = mpsc::unbounded_channel();+ Self {+ state: AppState::default(),+ theme: Theme::default(),+ client: MovieBoxClient::new(),+ action_sender,+ action_receiver,+ }+ }++ fn get_selected_link(&self) -> Option<String> {+ self.state+ .selected_resources+ .as_ref()+ .and_then(|res| res.get("list"))+ .and_then(|l| l.as_array())+ .and_then(|list| {+ let idx = self.state.resource_list_state.selected().unwrap_or(0);+ list.get(idx)+ })+ .and_then(|file| file.get("resourceLink"))+ .and_then(|r| r.as_str())+ .map(|s| s.to_string())+ }++ pub async fn run(&mut self, terminal: &mut DefaultTerminal) -> std::io::Result<()> {+ if self.state.image_picker.is_none() {+ let picker = ratatui_image::picker::Picker::from_query_stdio()+ .unwrap_or_else(|_| ratatui_image::picker::Picker::halfblocks());+ self.state.image_picker = Some(picker);+ }++ let mut events = EventHandler::new(Duration::from_millis(60));++ let init_sender = self.action_sender.clone();+ let client_clone = self.client.clone();+ tokio::spawn(async move {+ init_sender+ .send(Action::Log(+ "Initializing MovieBox client session...".to_string(),+ ))+ .ok();+ match client_clone.init().await {+ Ok(_) => {+ init_sender+ .send(Action::Log(+ "MovieBox client initialized successfully.".to_string(),+ ))+ .ok();+ }+ Err(e) => {+ init_sender+ .send(Action::Log(format!("Initialization failed: {:?}", e)))+ .ok();+ }+ }+ });++ loop {+ terminal.draw(|frame| self.draw(frame))?;++ tokio::select! {+ Some(action) = events.next() => {+ if let Some(quit) = self.handle_action(action).await {+ return Ok(quit);+ }+ }+ Some(action) = self.action_receiver.recv() => {+ if let Some(quit) = self.handle_action(action).await {+ return Ok(quit);+ }+ }+ }+ }+ }++ async fn handle_action(&mut self, action: Action) -> Option<()> {+ match action {+ Action::Tick => {+ self.state.tick_count = self.state.tick_count.wrapping_add(1);+ if self.state.toast_timer > 0 {+ self.state.toast_timer -= 1;+ if self.state.toast_timer == 0 {+ self.state.toast_message = None;+ }+ }+ }+ Action::Quit => {+ self.state.add_log("Quitting...".to_string());+ return Some(());+ }+ Action::Key(key) => {+ use crossterm::event::{KeyCode, KeyModifiers};++ if key.modifiers.contains(KeyModifiers::CONTROL) {+ match key.code {+ KeyCode::Char('c') => {+ self.action_sender.send(Action::Quit).ok();+ return Some(());+ }+ KeyCode::Char('l') => {+ self.action_sender.send(Action::ToggleLogs).ok();+ }+ _ => {}+ }+ }++ if let KeyCode::Char('x') | KeyCode::Char('X') = key.code+ && self.state.download_progress.is_some()+ {+ self.action_sender.send(Action::CancelDownload).ok();+ return Some(());+ }++ match self.state.input_mode {+ InputMode::Editing => match key.code {+ KeyCode::Esc => {+ self.state.input_mode = InputMode::Normal;+ self.state.status_message = "Ready".to_string();+ }+ KeyCode::Enter => {+ let query = self.state.search_query.trim().to_string();+ if !query.is_empty() {+ self.state.input_mode = InputMode::Normal;+ self.action_sender.send(Action::Search(query)).ok();+ }+ }+ KeyCode::Backspace => {+ self.state.search_query.pop();+ }+ KeyCode::Char(c) => {+ self.state.search_query.push(c);+ }+ _ => {}+ },+ InputMode::Normal => match self.state.active_screen {+ Screen::Home => match key.code {+ KeyCode::Esc => {+ self.action_sender.send(Action::GoBack).ok();+ }+ KeyCode::Up => {+ self.action_sender.send(Action::MoveUp).ok();+ }+ KeyCode::Down => {+ self.action_sender.send(Action::MoveDown).ok();+ }+ KeyCode::Enter => {+ self.action_sender.send(Action::Submit).ok();+ }+ KeyCode::Char('?') => {+ self.action_sender.send(Action::ToggleHelp).ok();+ }+ KeyCode::Char(c)+ if (key.modifiers.is_empty()+ || key.modifiers == KeyModifiers::SHIFT) =>+ {+ self.state.input_mode = InputMode::Editing;+ self.state.search_query.push(c);+ self.state.status_message =+ "Enter query to search movies...".to_string();+ }+ _ => {}+ },+ Screen::Details => match key.code {+ KeyCode::Char('q') => {+ self.action_sender.send(Action::Quit).ok();+ }+ KeyCode::Char('y') | KeyCode::Char('c') => {+ self.action_sender.send(Action::CopyLink).ok();+ }+ KeyCode::Char('p') | KeyCode::Char('P') => {+ self.action_sender.send(Action::PlayStream).ok();+ }+ KeyCode::Char('d') | KeyCode::Char('D') => {+ self.action_sender.send(Action::DownloadStream).ok();+ }+ KeyCode::Char('?') => {+ self.action_sender.send(Action::ToggleHelp).ok();+ }+ KeyCode::Char('b') | KeyCode::Esc => {+ self.action_sender.send(Action::GoBack).ok();+ }+ KeyCode::Up | KeyCode::Char('k') => {+ self.action_sender.send(Action::MoveUp).ok();+ }+ KeyCode::Down | KeyCode::Char('j') => {+ self.action_sender.send(Action::MoveDown).ok();+ }+ KeyCode::Left | KeyCode::Char('h') => {+ self.action_sender.send(Action::MoveLeft).ok();+ }+ KeyCode::Right | KeyCode::Char('l') => {+ self.action_sender.send(Action::MoveRight).ok();+ }+ KeyCode::Enter => {+ match self.state.details_pane {+ crate::tui::state::DetailsPane::Streams => {+ self.action_sender.send(Action::PlayStream).ok();+ }+ crate::tui::state::DetailsPane::Seasons => {+ self.action_sender.send(Action::MoveRight).ok();+ }+ crate::tui::state::DetailsPane::Episodes => {+ if let Some(res) = &self.state.selected_details+ && let Some(id) = res.get("id").and_then(|i| i.as_str())+ {+ let se_idx = self+ .state+ .season_list_state+ .selected()+ .unwrap_or(0);+ let ep_idx = self+ .state+ .episode_list_state+ .selected()+ .unwrap_or(0);++ if let Some(season) =+ self.state.available_seasons.get(se_idx)+ {+ let se = season+ .get("se")+ .and_then(|s| s.as_i64())+ .unwrap_or(1)+ as usize;+ let ep = ep_idx + 1;+ self.state.selected_season = se;+ self.state.selected_episode = ep;+ self.state.resource_list_state.select(None); // Reset stream selection+ self.action_sender+ .send(Action::FetchResources {+ subject_id: id.to_string(),+ season: se,+ episode: ep,+ resolution: "".to_string(),+ })+ .ok();+ self.action_sender.send(Action::MoveRight).ok();+ }+ }+ }+ crate::tui::state::DetailsPane::Languages => {+ let idx =+ self.state.language_list_state.selected().unwrap_or(0);+ self.action_sender.send(Action::SelectLanguage(idx)).ok();+ }+ }+ }+ _ => {}+ },+ _ => {}+ },+ }+ }+ Action::ToggleLogs => {+ self.state.show_logs = !self.state.show_logs;+ }+ Action::ToggleHelp => {+ self.state.show_help = !self.state.show_help;+ }+ Action::GoBack => {+ if self.state.show_help {+ self.state.show_help = false;+ return None;+ }+ match self.state.active_screen {+ Screen::Home => {+ if !self.state.search_results.is_empty() {+ self.state.search_results.clear();+ self.state.search_query.clear();+ self.state.search_preview = None;+ self.state.status_message = "Search cleared.".to_string();+ }+ }+ Screen::Search => {+ self.state.active_screen = Screen::Home;+ }+ Screen::Details => {+ self.state.active_screen = Screen::Home;+ self.state.status_message =+ "Select a movie/series and press Enter".to_string();+ }+ }+ }+ Action::SelectLanguage(idx) => {+ if let Some(details) = &self.state.selected_details+ && let Some(dubs) = details.get("dubs").and_then(|d| d.as_array())+ && let Some(dub) = dubs.get(idx)+ && let Some(id) = dub.get("subjectId").and_then(|i| i.as_str())+ {+ let next_id = id.to_string();+ self.state.selected_details = None;+ self.state.selected_resources = None;+ self.state.resource_list_state.select(None);+ self.state.language_chosen = true;+ self.state.status_message = "Switching language...".to_string();+ self.action_sender.send(Action::FetchDetails(next_id)).ok();+ }+ }+ Action::Search(query) => {+ self.state.is_loading = true;+ self.state.status_message = format!("Searching for '{}'...", query);+ self.state.add_log(format!("API Search request: {}", query));++ let client = self.client.clone();+ let sender = self.action_sender.clone();+ tokio::spawn(async move {+ match client.search(&query, 1).await {+ Ok(res) => {+ sender.send(Action::SearchSuccess(res)).ok();+ }+ Err(e) => {+ sender.send(Action::SearchFailure(format!("{:?}", e))).ok();+ }+ }+ });+ }+ Action::SearchSuccess(payload) => {+ self.state.is_loading = false;+ self.state.search_results.clear();++ let mut count = 0;+ let subjects_opt = payload+ .get("results")+ .and_then(|r| r.as_array())+ .and_then(|arr| arr.first())+ .and_then(|first| first.get("subjects"))+ .and_then(|s| s.as_array());++ if let Some(subjects) = subjects_opt {+ let query_lower = self.state.search_query.to_lowercase().trim().to_string();+ for item in subjects {+ let id = item+ .get("subjectId")+ .and_then(|si| si.as_str())+ .unwrap_or("")+ .to_string();+ let raw_title = item+ .get("title")+ .and_then(|t| t.as_str())+ .unwrap_or("Unknown")+ .to_string();++ let clean_title = raw_title+ .split('[')+ .next()+ .unwrap_or(&raw_title)+ .trim()+ .to_string();++ if !query_lower.is_empty()+ && !clean_title.to_lowercase().contains(&query_lower)+ {+ continue;+ }++ let stype = item+ .get("subjectType")+ .and_then(|s| s.as_i64())+ .unwrap_or(0);+ let release_year = item+ .get("releaseDate")+ .and_then(|rd| rd.as_str())+ .unwrap_or("N/A")+ .to_string();++ let is_duplicate = self.state.search_results.iter().any(|r| {+ r.title == clean_title+ && r.release_year == release_year+ && r.stype == stype+ });++ if !id.is_empty() && !is_duplicate {+ self.state.search_results.push(SearchResult {+ id,+ title: clean_title,+ stype,+ release_year,+ });+ count += 1;+ }+ }+ self.state.search_results.sort_by(|a, b| {+ b.stype+ .cmp(&a.stype)+ .then_with(|| b.release_year.cmp(&a.release_year))+ });+ }++ self.state+ .search_list_state+ .select(if count > 0 { Some(0) } else { None });+ self.state.status_message = format!("Found {} results.", count);+ self.state+ .add_log(format!("Search completed: {} items loaded.", count));++ if let Some(res) = self.state.search_results.first() {+ self.action_sender+ .send(Action::FetchPreview(res.id.clone()))+ .ok();+ }+ }+ Action::SearchFailure(err) => {+ self.state.is_loading = false;+ self.state.status_message = format!("Search failed: {}", err);+ self.state.add_log(format!("Search API Error: {}", err));+ }+ Action::MoveUp => {+ match self.state.active_screen {+ Screen::Home => {+ let current = self.state.search_list_state.selected().unwrap_or(0);+ if current > 0 {+ self.state.search_list_state.select(Some(current - 1));+ if let Some(res) = self.state.search_results.get(current - 1) {+ self.action_sender+ .send(Action::FetchPreview(res.id.clone()))+ .ok();+ }+ }+ }+ Screen::Details => {+ match self.state.details_pane {+ crate::tui::state::DetailsPane::Streams => {+ let current =+ self.state.resource_list_state.selected().unwrap_or(0);+ if current > 0 {+ self.state.resource_list_state.select(Some(current - 1));+ }+ }+ crate::tui::state::DetailsPane::Seasons => {+ let current = self.state.season_list_state.selected().unwrap_or(0);+ if current > 0 {+ self.state.season_list_state.select(Some(current - 1));+ self.state.selected_season = current; // 1-based index based on position (if we store them ordered)+ }+ }+ crate::tui::state::DetailsPane::Episodes => {+ let current = self.state.episode_list_state.selected().unwrap_or(0);+ if current > 0 {+ self.state.episode_list_state.select(Some(current - 1));+ }+ }+ crate::tui::state::DetailsPane::Languages => {+ let current =+ self.state.language_list_state.selected().unwrap_or(0);+ if current > 0 {+ self.state.language_list_state.select(Some(current - 1));+ }+ }+ }+ }+ _ => {}+ }+ }+ Action::MoveDown => {+ match self.state.active_screen {+ Screen::Home => {+ let current = self.state.search_list_state.selected().unwrap_or(0);+ if current + 1 < self.state.search_results.len() {+ self.state.search_list_state.select(Some(current + 1));+ if let Some(res) = self.state.search_results.get(current + 1) {+ self.action_sender+ .send(Action::FetchPreview(res.id.clone()))+ .ok();+ }+ }+ }+ Screen::Details => {+ match self.state.details_pane {+ crate::tui::state::DetailsPane::Streams => {+ let res_opt = &self.state.selected_resources;+ let list_opt = res_opt+ .as_ref()+ .and_then(|r| r.get("list"))+ .and_then(|l| l.as_array());+ if let Some(list) = list_opt {+ let current =+ self.state.resource_list_state.selected().unwrap_or(0);+ if current + 1 < list.len() {+ self.state.resource_list_state.select(Some(current + 1));+ }+ }+ }+ crate::tui::state::DetailsPane::Seasons => {+ let current = self.state.season_list_state.selected().unwrap_or(0);+ if current + 1 < self.state.available_seasons.len() {+ self.state.season_list_state.select(Some(current + 1));+ }+ }+ crate::tui::state::DetailsPane::Episodes => {+ let current = self.state.episode_list_state.selected().unwrap_or(0);+ if let Some(season) = self+ .state+ .available_seasons+ .get(self.state.season_list_state.selected().unwrap_or(0))+ {+ let max_ep =+ season.get("maxEp").and_then(|m| m.as_i64()).unwrap_or(1)+ as usize;+ if current + 1 < max_ep {+ self.state.episode_list_state.select(Some(current + 1));+ }+ }+ }+ crate::tui::state::DetailsPane::Languages => {+ let current =+ self.state.language_list_state.selected().unwrap_or(0);+ if let Some(details) = &self.state.selected_details+ && let Some(dubs) =+ details.get("dubs").and_then(|d| d.as_array())+ && current + 1 < dubs.len()+ {+ self.state.language_list_state.select(Some(current + 1));+ }+ }+ }+ }+ _ => {}+ }+ }+ Action::MoveLeft => {+ if self.state.active_screen == Screen::Details {+ match self.state.details_pane {+ crate::tui::state::DetailsPane::Streams => {+ if !self.state.available_seasons.is_empty() {+ self.state.details_pane = crate::tui::state::DetailsPane::Episodes;+ } else {+ if let Some(dubs) = self+ .state+ .selected_details+ .as_ref()+ .and_then(|d| d.get("dubs"))+ .and_then(|d| d.as_array())+ && dubs.len() > 1+ {+ self.state.details_pane =+ crate::tui::state::DetailsPane::Languages;+ }+ }+ }+ crate::tui::state::DetailsPane::Episodes => {+ self.state.details_pane = crate::tui::state::DetailsPane::Seasons;+ }+ crate::tui::state::DetailsPane::Seasons => {+ if let Some(dubs) = self+ .state+ .selected_details+ .as_ref()+ .and_then(|d| d.get("dubs"))+ .and_then(|d| d.as_array())+ && dubs.len() > 1+ {+ self.state.details_pane = crate::tui::state::DetailsPane::Languages;+ }+ }+ crate::tui::state::DetailsPane::Languages => {}+ }+ }+ }+ Action::MoveRight => {+ if self.state.active_screen == Screen::Details {+ match self.state.details_pane {+ crate::tui::state::DetailsPane::Seasons => {+ self.state.details_pane = crate::tui::state::DetailsPane::Episodes;+ }+ crate::tui::state::DetailsPane::Episodes => {+ self.state.details_pane = crate::tui::state::DetailsPane::Streams;+ }+ crate::tui::state::DetailsPane::Streams => {}+ crate::tui::state::DetailsPane::Languages => {+ let has_multiple = self+ .state+ .selected_details+ .as_ref()+ .and_then(|d| d.get("dubs"))+ .and_then(|d| d.as_array())+ .is_some_and(|a| a.len() > 1);+ if !has_multiple || self.state.language_chosen {+ if !self.state.available_seasons.is_empty() {+ self.state.details_pane =+ crate::tui::state::DetailsPane::Seasons;+ } else {+ self.state.details_pane =+ crate::tui::state::DetailsPane::Streams;+ }+ }+ }+ }+ }+ }+ Action::Submit => {+ if self.state.active_screen == Screen::Home {+ let idx_opt = self.state.search_list_state.selected();+ let item_opt =+ idx_opt.and_then(|idx| self.state.search_results.get(idx).cloned());+ if let Some(item) = item_opt {+ self.state.active_screen = Screen::Details;+ self.state.selected_details = None;+ self.state.selected_resources = None;+ self.state.resource_list_state.select(None);+ self.state.language_chosen = false;+ self.state.status_message =+ format!("Loading details for {}...", item.title);++ let sender = self.action_sender.clone();+ sender.send(Action::FetchDetails(item.id)).ok();+ }+ }+ }+ Action::FetchDetails(id) => {+ self.state.is_loading = true;+ let client = self.client.clone();+ let sender = self.action_sender.clone();+ let id_clone = id.clone();+ tokio::spawn(async move {+ match client.get_details(&id_clone).await {+ Ok(details) => {+ sender.send(Action::DetailsSuccess(id_clone, details)).ok();+ }+ Err(e) => {+ sender.send(Action::DetailsFailure(format!("{:?}", e))).ok();+ }+ }+ });+ }+ Action::FetchPreview(id) => {+ self.state.preview_loading = true;+ let client = self.client.clone();+ let sender = self.action_sender.clone();+ let id_clone = id.clone();+ tokio::spawn(async move {+ match client.get_details(&id_clone).await {+ Ok(details) => {+ sender.send(Action::PreviewSuccess(id_clone, details)).ok();+ }+ Err(e) => {+ sender.send(Action::PreviewFailure(format!("{:?}", e))).ok();+ }+ }+ });+ }+ Action::PreviewSuccess(id, json) => {+ let current_id = self+ .state+ .search_list_state+ .selected()+ .and_then(|idx| self.state.search_results.get(idx))+ .map(|res| res.id.clone());++ if current_id.as_deref() != Some(id.as_str()) {+ return None; // Discard outdated preview+ }++ self.state.preview_loading = false;+ self.state.search_preview = Some(json.clone());+ self.state.poster_image = None; // Reset poster+ self.state.poster_protocol = None; // Reset cached protocol+ if let Some(cover_val) = json.get("cover")+ && let Some(url) = cover_val.get("url").and_then(|u| u.as_str())+ {+ let url_clone = url.to_string();+ let action_tx = self.action_sender.clone();+ let id_clone = id.clone();+ tokio::spawn(async move {+ if let Ok(resp) = reqwest::get(&url_clone).await+ && let Ok(bytes) = resp.bytes().await+ && let Ok(img) = image::load_from_memory(&bytes)+ {+ let _ = action_tx+ .send(Action::PosterSuccess(id_clone, std::sync::Arc::new(img)));+ }+ });+ }+ }+ Action::PosterSuccess(id, img) => {+ let current_id = self+ .state+ .search_list_state+ .selected()+ .and_then(|idx| self.state.search_results.get(idx))+ .map(|res| res.id.clone());++ if current_id.as_deref() == Some(id.as_str()) {+ self.state.poster_image = Some((*img).clone());+ self.state.poster_protocol = None;+ }+ }+ Action::PreviewFailure(err) => {+ self.state.preview_loading = false;+ self.state.add_log(format!("Preview fetch failed: {}", err));+ }+ Action::CopyLink => {+ if self.state.active_screen == Screen::Details+ && let Some(link) = self.get_selected_link()+ {+ use std::io::Write;+ use std::process::{Command, Stdio};+ let child = Command::new("pbcopy").stdin(Stdio::piped()).spawn();+ if let Ok(mut child) = child {+ if let Some(mut stdin) = child.stdin.take() {+ let _ = stdin.write_all(link.as_bytes());+ }+ let _ = child.wait();+ self.state.toast_message = Some("[ ✓ ] Copied stream link!".to_string());+ self.state.toast_timer = 30; // ~1.8 seconds+ self.state.add_log(+ "Stream link successfully copied to macOS clipboard.".to_string(),+ );+ } else {+ self.state.status_message = format!("Link: {}", link);+ }+ }+ }+ Action::PlayStream => {+ if self.state.active_screen == Screen::Details+ && let Some(link) = self.get_selected_link()+ {+ use std::process::{Command, Stdio};+ self.state.toast_message = Some("[ i ] Launching MPV...".to_string());+ self.state.toast_timer = 40;+ let child = Command::new("mpv")+ .arg(&link)+ .stdout(Stdio::null())+ .stderr(Stdio::null())+ .spawn();+ if child.is_ok() {+ self.action_sender+ .send(Action::Log("MPV started successfully.".to_string()))+ .ok();+ } else {+ self.state.toast_message = Some("[ ✗ ] Failed to launch MPV!".to_string());+ self.state.toast_timer = 60;+ self.state+ .add_log("Error starting mpv process. Command failed.".to_string());+ }+ }+ }+ Action::DownloadStream => {+ if self.state.active_screen == Screen::Details {+ let link_opt = self.get_selected_link();+ let title = self+ .state+ .selected_details+ .as_ref()+ .and_then(|d| d.get("title"))+ .and_then(|t| t.as_str())+ .unwrap_or("MovieBox_Stream")+ .to_string();+ let ext = "mp4";+ let filename = format!(+ "{}_{}.{}",+ title.replace(" ", "_").replace("/", "_"),+ std::time::SystemTime::now()+ .duration_since(std::time::UNIX_EPOCH)+ .unwrap()+ .as_secs(),+ ext+ );++ let home = std::env::var("HOME").unwrap_or_else(|_| ".".to_string());+ let filepath = std::path::PathBuf::from(home)+ .join("Downloads")+ .join(&filename);++ if let Some(link) = link_opt {+ self.state.toast_message =+ Some("[ ↓ ] Starting native download...".to_string());+ self.state.toast_timer = 40;+ self.state.download_status = Some("Connecting...".to_string());+ self.state.download_progress = Some(0.0);+ self.state+ .cancel_download+ .store(false, std::sync::atomic::Ordering::SeqCst);++ let cancel_token = self.state.cancel_download.clone();+ let sender = self.action_sender.clone();+ tokio::spawn(async move {+ let client = reqwest::Client::new();+ let head_res = client.head(&link).send().await;+ let (total_size, supports_ranges) = match head_res {+ Ok(r) => {+ let size = r.content_length().unwrap_or(0);+ let ranges = r+ .headers()+ .get(reqwest::header::ACCEPT_RANGES)+ .and_then(|v| v.to_str().ok())+ .unwrap_or("")+ == "bytes";+ (size, ranges)+ }+ Err(e) => {+ sender+ .send(Action::UpdateDownload(+ None,+ Some(format!("Head Error: {}", e)),+ ))+ .ok();+ tokio::time::sleep(std::time::Duration::from_secs(3)).await;+ sender.send(Action::UpdateDownload(None, None)).ok();+ return;+ }+ };++ if total_size > 1024 * 1024 && supports_ranges {+ let num_connections = 16;+ let chunk_size = total_size / num_connections;+ let mut handles = vec![];++ let downloaded_total =+ std::sync::Arc::new(std::sync::atomic::AtomicU64::new(0));+ let start_time = std::time::Instant::now();++ let ui_downloaded = downloaded_total.clone();+ let ui_sender = sender.clone();+ let ui_cancel = cancel_token.clone();+ let ui_handle = tokio::spawn(async move {+ loop {+ tokio::time::sleep(std::time::Duration::from_millis(200))+ .await;+ if ui_cancel.load(std::sync::atomic::Ordering::Relaxed) {+ break;+ }++ let current_dl = ui_downloaded+ .load(std::sync::atomic::Ordering::Relaxed);+ let progress = (current_dl as f64 / total_size as f64)+ .clamp(0.0, 1.0)+ * 100.0;+ let elapsed = start_time.elapsed().as_secs_f64();+ let speed_bps = if elapsed > 0.0 {+ current_dl as f64 / elapsed+ } else {+ 0.0+ };+ let speed_mbps = speed_bps / 1024.0 / 1024.0;+ let remaining_bytes =+ total_size.saturating_sub(current_dl) as f64;+ let eta_secs = if speed_bps > 0.0 {+ remaining_bytes / speed_bps+ } else {+ 0.0+ };++ let status = format!(+ "{:.1} MB / {:.1} MB | {:.1} MB/s | ETA: {:.0}s [16x]",+ current_dl as f64 / 1024.0 / 1024.0,+ total_size as f64 / 1024.0 / 1024.0,+ speed_mbps,+ eta_secs+ );+ ui_sender+ .send(Action::UpdateDownload(+ Some(progress),+ Some(status),+ ))+ .ok();+ if current_dl >= total_size {+ break;+ }+ }+ });++ let mut temp_files = vec![];+ for i in 0..num_connections {+ let start = i * chunk_size;+ let end = if i == num_connections - 1 {+ total_size - 1+ } else {+ start + chunk_size - 1+ };++ let part_filepath =+ filepath.with_extension(format!("part{}", i));+ temp_files.push(part_filepath.clone());++ let client_clone = client.clone();+ let link_clone = link.clone();+ let dl_total = downloaded_total.clone();+ let c_token = cancel_token.clone();++ handles.push(tokio::spawn(async move {+ let file_res =+ tokio::fs::File::create(&part_filepath).await;+ if file_res.is_err() {+ return Err(());+ }+ let mut file = tokio::io::BufWriter::with_capacity(+ 128 * 1024,+ file_res.unwrap(),+ );++ let req = client_clone+ .get(&link_clone)+ .header(+ reqwest::header::RANGE,+ format!("bytes={}-{}", start, end),+ )+ .send()+ .await;+ if req.is_err() {+ return Err(());+ }+ let mut res = req.unwrap();++ use tokio::io::AsyncWriteExt;+ let expected_size = end - start + 1;+ let mut part_downloaded = 0;+ while let Ok(Some(chunk)) = res.chunk().await {+ if c_token.load(std::sync::atomic::Ordering::Relaxed) {+ return Err(());+ }++ let chunk_to_write = if part_downloaded+ + chunk.len() as u64+ > expected_size+ {+ &chunk[..(expected_size - part_downloaded) as usize]+ } else {+ &chunk[..]+ };++ if file.write_all(chunk_to_write).await.is_err() {+ return Err(());+ }+ dl_total.fetch_add(+ chunk_to_write.len() as u64,+ std::sync::atomic::Ordering::Relaxed,+ );+ part_downloaded += chunk_to_write.len() as u64;++ if part_downloaded >= expected_size {+ break;+ }+ }+ let _ = file.flush().await;+ Ok(())+ }));+ }++ let mut any_err = false;+ for h in handles {+ if let Ok(res) = h.await {+ if res.is_err() {+ any_err = true;+ }+ } else {+ any_err = true;+ }+ }+ ui_handle.abort();++ if cancel_token.load(std::sync::atomic::Ordering::Relaxed) {+ for tmp in &temp_files {+ let _ = tokio::fs::remove_file(tmp).await;+ }+ sender+ .send(Action::UpdateDownload(+ None,+ Some("Download Cancelled".to_string()),+ ))+ .ok();+ tokio::time::sleep(std::time::Duration::from_secs(2)).await;+ sender.send(Action::UpdateDownload(None, None)).ok();+ return;+ }++ if any_err {+ for tmp in &temp_files {+ let _ = tokio::fs::remove_file(tmp).await;+ }+ sender+ .send(Action::UpdateDownload(+ None,+ Some("Failed to download parts".to_string()),+ ))+ .ok();+ tokio::time::sleep(std::time::Duration::from_secs(3)).await;+ sender.send(Action::UpdateDownload(None, None)).ok();+ return;+ }++ sender+ .send(Action::UpdateDownload(+ Some(100.0),+ Some("Merging parts...".to_string()),+ ))+ .ok();+ if let Ok(final_file) = tokio::fs::File::create(&filepath).await {+ use tokio::io::AsyncWriteExt;+ let mut final_buf = tokio::io::BufWriter::with_capacity(+ 1024 * 1024,+ final_file,+ );+ let mut merge_ok = true;+ for tmp in &temp_files {+ if let Ok(mut part_file) = tokio::fs::File::open(tmp).await+ {+ if tokio::io::copy(&mut part_file, &mut final_buf)+ .await+ .is_err()+ {+ merge_ok = false;+ break;+ }+ } else {+ merge_ok = false;+ break;+ }+ }+ let _ = final_buf.flush().await;+ for tmp in &temp_files {+ let _ = tokio::fs::remove_file(tmp).await;+ }++ if merge_ok {+ sender+ .send(Action::UpdateDownload(+ Some(100.0),+ Some("Completed!".to_string()),+ ))+ .ok();+ } else {+ let _ = tokio::fs::remove_file(&filepath).await;+ sender+ .send(Action::UpdateDownload(+ None,+ Some("Failed to merge parts".to_string()),+ ))+ .ok();+ }+ }+ tokio::time::sleep(std::time::Duration::from_secs(3)).await;+ sender.send(Action::UpdateDownload(None, None)).ok();+ } else {+ match client.get(&link).send().await {+ Ok(mut response) => {+ if !response.status().is_success() {+ sender+ .send(Action::UpdateDownload(+ None,+ Some(format!(+ "Error: Status {}",+ response.status()+ )),+ ))+ .ok();+ return;+ }+ let mut downloaded: u64 = 0;+ if let Ok(file) = tokio::fs::File::create(&filepath).await {+ use tokio::io::AsyncWriteExt;+ let mut buf_writer =+ tokio::io::BufWriter::with_capacity(+ 1024 * 1024,+ file,+ );+ let start_time = std::time::Instant::now();+ let mut last_ui_update = std::time::Instant::now();++ sender+ .send(Action::UpdateDownload(+ None,+ Some(format!("Downloading to {}", filename)),+ ))+ .ok();+ while let Ok(Some(chunk)) = response.chunk().await {+ if cancel_token+ .load(std::sync::atomic::Ordering::Relaxed)+ {+ let _ = tokio::fs::remove_file(&filepath).await;+ sender+ .send(Action::UpdateDownload(+ None,+ Some("Download Cancelled".to_string()),+ ))+ .ok();+ tokio::time::sleep(+ std::time::Duration::from_secs(2),+ )+ .await;+ sender+ .send(Action::UpdateDownload(None, None))+ .ok();+ return;+ }+ if buf_writer.write_all(&chunk).await.is_err() {+ sender+ .send(Action::UpdateDownload(+ None,+ Some("File write error!".to_string()),+ ))+ .ok();+ return;+ }+ downloaded += chunk.len() as u64;++ let now = std::time::Instant::now();+ if now.duration_since(last_ui_update).as_millis()+ > 200+ {+ last_ui_update = now;+ let progress = if total_size > 0 {+ (downloaded as f64 / total_size as f64)+ * 100.0+ } else {+ 0.0+ };++ let elapsed = now+ .duration_since(start_time)+ .as_secs_f64();+ let speed_bps = if elapsed > 0.0 {+ downloaded as f64 / elapsed+ } else {+ 0.0+ };+ let speed_mbps = speed_bps / 1024.0 / 1024.0;++ let remaining_bytes = total_size+ .saturating_sub(downloaded)+ as f64;+ let eta_secs = if speed_bps > 0.0 {+ remaining_bytes / speed_bps+ } else {+ 0.0+ };++ let status = format!(+ "{:.1} MB / {:.1} MB | {:.1} MB/s | ETA: {:.0}s [1x]",+ downloaded as f64 / 1024.0 / 1024.0,+ total_size as f64 / 1024.0 / 1024.0,+ speed_mbps,+ eta_secs+ );+ sender+ .send(Action::UpdateDownload(+ Some(progress),+ Some(status),+ ))+ .ok();+ }+ }+ let _ = buf_writer.flush().await;+ sender+ .send(Action::UpdateDownload(+ Some(100.0),+ Some("Completed!".to_string()),+ ))+ .ok();+ tokio::time::sleep(std::time::Duration::from_secs(3))+ .await;+ sender.send(Action::UpdateDownload(None, None)).ok();+ } else {+ sender+ .send(Action::UpdateDownload(+ None,+ Some("Failed to create file".to_string()),+ ))+ .ok();+ tokio::time::sleep(std::time::Duration::from_secs(3))+ .await;+ sender.send(Action::UpdateDownload(None, None)).ok();+ }+ }+ Err(e) => {+ sender+ .send(Action::UpdateDownload(+ None,+ Some(format!("Network Error: {}", e)),+ ))+ .ok();+ tokio::time::sleep(std::time::Duration::from_secs(3)).await;+ sender.send(Action::UpdateDownload(None, None)).ok();+ }+ }+ }+ });+ }+ }+ }+ Action::DetailsSuccess(id, payload) => {+ let _ = std::fs::write(+ "debug_details.json",+ serde_json::to_string_pretty(&payload).unwrap(),+ );+ self.state.selected_details = Some(payload.clone());+ let stype = payload+ .get("subjectType")+ .and_then(|s| s.as_i64())+ .or_else(|| payload.get("stype").and_then(|s| s.as_i64()))+ .unwrap_or(1);++ if let Some(seasons_arr) = payload+ .get("seasons")+ .and_then(|s| s.get("seasons"))+ .and_then(|s| s.as_array())+ {+ self.state.available_seasons = seasons_arr.clone();+ } else if stype == 2 {+ let max_ep = payload+ .get("resourceDetectors")+ .and_then(|r| r.as_array())+ .and_then(|a| a.first())+ .and_then(|r| r.get("totalEpisode"))+ .and_then(|t| t.as_i64())+ .unwrap_or(1);++ self.state.available_seasons = vec![serde_json::json!({+ "se": 1,+ "maxEp": max_ep,+ "allEp": format!("1-{}", max_ep)+ })];+ } else {+ self.state.available_seasons.clear();+ }++ self.state.season_list_state.select(Some(0));+ self.state.episode_list_state.select(Some(0));++ if let Some(dubs) = payload.get("dubs").and_then(|d| d.as_array()) {+ let mut current_idx = 0;+ let current_id = payload.get("id").and_then(|i| i.as_str()).unwrap_or("");+ for (i, dub) in dubs.iter().enumerate() {+ if dub.get("subjectId").and_then(|i| i.as_str()) == Some(current_id) {+ current_idx = i;+ }+ }+ self.state.language_list_state.select(Some(current_idx));+ } else {+ self.state.language_list_state.select(Some(0));+ }++ self.state.selected_season = 1;+ self.state.selected_episode = 1;++ let has_multiple_dubs = payload+ .get("dubs")+ .and_then(|d| d.as_array())+ .is_some_and(|a| a.len() > 1);++ if has_multiple_dubs && !self.state.language_chosen {+ self.state.details_pane = crate::tui::state::DetailsPane::Languages;+ self.state.is_loading = false;+ self.state.status_message = "Please select a language dubbing.".to_string();+ } else {+ if stype == 2 && !self.state.available_seasons.is_empty() {+ self.state.details_pane = crate::tui::state::DetailsPane::Episodes;+ } else {+ self.state.details_pane = crate::tui::state::DetailsPane::Streams;+ }++ let (se, ep) = if stype == 2 {+ (1usize, 1usize)+ } else {+ (0usize, 0usize)+ };+ let sender = self.action_sender.clone();+ sender+ .send(Action::FetchResources {+ subject_id: id,+ season: se,+ episode: ep,+ resolution: "".to_string(),+ })+ .ok();+ }+ }+ Action::DetailsFailure(err) => {+ self.state.is_loading = false;+ self.state.status_message = format!("Details fetch failed: {}", err);+ }+ Action::FetchResources {+ subject_id,+ season,+ episode,+ resolution: _,+ } => {+ let client = self.client.clone();+ let sender = self.action_sender.clone();+ tokio::spawn(async move {+ match client.get_all_resources(&subject_id, season, episode).await {+ Ok(res) => {+ sender.send(Action::ResourcesSuccess(res)).ok();+ }+ Err(e) => {+ sender+ .send(Action::ResourcesFailure(format!("{:?}", e)))+ .ok();+ }+ }+ });+ }+ Action::ResourcesSuccess(payload) => {+ let mut sorted_payload = payload.clone();+ if let Some(obj) = sorted_payload.as_object_mut()+ && let Some(list) = obj.get_mut("list").and_then(|l| l.as_array_mut())+ {+ list.sort_by(|a, b| {+ let res_a = a.get("resolution").and_then(|r| r.as_i64()).unwrap_or(0);+ let res_b = b.get("resolution").and_then(|r| r.as_i64()).unwrap_or(0);+ res_b.cmp(&res_a) // Descending+ });+ }+ self.state.is_loading = false;+ self.state.selected_resources = Some(sorted_payload);++ let mut count = 0;+ if let Some(list) = payload.get("list").and_then(|l| l.as_array()) {+ count = list.len();+ }++ self.state+ .resource_list_state+ .select(if count > 0 { Some(0) } else { None });+ self.state.status_message = format!("Resolved {} direct stream sources.", count);+ }+ Action::ResourcesFailure(err) => {+ self.state.is_loading = false;+ if err.contains("406") || err.to_lowercase().contains("exhausted") {+ self.state.status_message =+ "Error: No streams found on server (unreleased or removed).".to_string();+ } else {+ self.state.status_message = format!("Error: Links resolution failed: {}", err);+ }+ }+ Action::UpdateDownload(prog, stat) => {+ self.state.download_progress = prog;+ self.state.download_status = stat;+ }+ Action::CancelDownload => {+ self.state+ .cancel_download+ .store(true, std::sync::atomic::Ordering::SeqCst);+ self.state.download_status = Some("Cancelling...".to_string());+ self.state.toast_message = Some("[ ! ] Cancelling download...".to_string());+ self.state.toast_timer = 40;+ }+ Action::Log(msg) => {+ self.state.add_log(msg);+ }+ }+ None+ }++ fn draw(&mut self, frame: &mut Frame) {+ let area = frame.area();++ match self.state.active_screen {+ Screen::Home => {+ super::screens::home::draw(frame, area, &mut self.state, &self.theme);+ }+ Screen::Details => {+ super::screens::details::draw(frame, area, &mut self.state, &self.theme);+ }+ _ => {}+ }++ if self.state.show_logs {+ super::screens::logs::draw(frame, area, &self.state, &self.theme);+ }++ if self.state.show_help {+ super::screens::help::draw(frame, area, &self.state, &self.theme);+ }++ if let Some(prog) = self.state.download_progress {+ use ratatui::layout::{Constraint, Direction, Layout};+ use ratatui::style::{Color, Modifier, Style};+ use ratatui::widgets::{Block, Borders, Gauge};++ let chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([Constraint::Min(0), Constraint::Length(3)])+ .split(area);++ let status = self+ .state+ .download_status+ .as_deref()+ .unwrap_or("Downloading...");+ let gauge = Gauge::default()+ .block(+ Block::default()+ .borders(Borders::ALL)+ .title(format!(" Download: {} [X] Cancel ", status)),+ )+ .gauge_style(+ Style::default()+ .fg(Color::Cyan)+ .add_modifier(Modifier::BOLD),+ )+ .ratio((prog / 100.0).clamp(0.0, 1.0));+ frame.render_widget(gauge, chunks[1]);+ }++ if let Some(msg) = &self.state.toast_message {+ use ratatui::layout::{Constraint, Direction, Layout};+ use ratatui::style::{Color, Style};+ use ratatui::widgets::{Block, Borders, Paragraph};++ let chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([Constraint::Min(0), Constraint::Length(3)])+ .split(area);++ let h_chunks = Layout::default()+ .direction(Direction::Horizontal)+ .constraints([Constraint::Percentage(70), Constraint::Percentage(30)])+ .split(chunks[0]);++ let toast_area = Layout::default()+ .direction(Direction::Vertical)+ .constraints([Constraint::Min(0), Constraint::Length(3)])+ .split(h_chunks[1])[1];++ let p = Paragraph::new(msg.clone())+ .block(Block::default().borders(Borders::ALL))+ .style(Style::default().fg(Color::Green));+ frame.render_widget(p, toast_area);+ }+ }+}diff --git a/src/tui/event.rs b/src/tui/event.rsnew file mode 100644index 0000000..be43b7f--- /dev/null+++ b/src/tui/event.rs@@ -0,0 +1,53 @@+use crate::tui::action::Action;+use crossterm::event::{Event as CrosstermEvent, KeyEventKind};+use std::time::Duration;+use tokio::sync::mpsc;++pub struct EventHandler {+ receiver: mpsc::UnboundedReceiver<Action>,+ #[allow(dead_code)]+ sender: mpsc::UnboundedSender<Action>,+}++impl EventHandler {+ pub fn new(tick_rate: Duration) -> Self {+ let (sender, receiver) = mpsc::unbounded_channel();+ let event_sender = sender.clone();++ tokio::spawn(async move {+ loop {+ let polled = crossterm::event::poll(Duration::from_millis(50)).unwrap_or(false);+ if polled {+ let key_opt = match crossterm::event::read() {+ Ok(CrosstermEvent::Key(key)) => Some(key),+ _ => None,+ };+ if let Some(key) = key_opt {+ let is_press = key.kind == KeyEventKind::Press;+ if is_press && event_sender.send(Action::Key(key)).is_err() {+ break;+ }+ }+ }+ tokio::task::yield_now().await;+ }+ });++ let tick_sender = sender.clone();+ tokio::spawn(async move {+ let mut interval = tokio::time::interval(tick_rate);+ loop {+ interval.tick().await;+ if tick_sender.send(Action::Tick).is_err() {+ break;+ }+ }+ });++ Self { receiver, sender }+ }++ pub async fn next(&mut self) -> Option<Action> {+ self.receiver.recv().await+ }+}diff --git a/src/tui/mod.rs b/src/tui/mod.rsnew file mode 100644index 0000000..b1a3097--- /dev/null+++ b/src/tui/mod.rs@@ -0,0 +1,11 @@+pub mod action;+pub mod app;+pub mod event;+pub mod state;+pub mod theme;+pub mod screens {+ pub mod details;+ pub mod help;+ pub mod home;+ pub mod logs;+}diff --git a/src/tui/screens/details.rs b/src/tui/screens/details.rsnew file mode 100644index 0000000..a852bb2--- /dev/null+++ b/src/tui/screens/details.rs@@ -0,0 +1,578 @@+use crate::tui::{state::AppState, theme::Theme};+use ratatui::{+ Frame,+ layout::{Alignment, Constraint, Direction, Layout, Rect},+ text::{Line, Span},+ widgets::{Block, Borders, Cell, Paragraph, Row, Table, Wrap},+};++pub fn draw(frame: &mut Frame, area: Rect, state: &mut AppState, theme: &Theme) {+ let chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([+ Constraint::Length(23), // Metadata header (Title, Release, Synopsis)+ Constraint::Min(4), // Stream links lists+ ])+ .split(area);++ let details_json = match &state.selected_details {+ Some(d) => d,+ None => {+ let spinner_frames = ['⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏'];+ let spinner = spinner_frames[(state.tick_count as usize) % spinner_frames.len()];++ let vertical_chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([+ Constraint::Percentage(45),+ Constraint::Length(1),+ Constraint::Percentage(50),+ ])+ .split(area);++ let loading_p = Paragraph::new(format!("{} Loading details...", spinner))+ .alignment(ratatui::layout::Alignment::Center)+ .style(theme.text_dim);++ frame.render_widget(loading_p, vertical_chunks[1]);+ return;+ }+ };++ let title = details_json+ .get("title")+ .and_then(|t| t.as_str())+ .unwrap_or("Unknown");+ let intro = details_json+ .get("description")+ .and_then(|d| d.as_str())+ .or_else(|| details_json.get("intro").and_then(|i| i.as_str()))+ .unwrap_or("No description available.");+ let year = details_json+ .get("releaseDate")+ .and_then(|y| y.as_str())+ .or_else(|| details_json.get("year").and_then(|y| y.as_str()))+ .unwrap_or("N/A");+ let type_val = details_json+ .get("subjectType")+ .and_then(|s| s.as_i64())+ .or_else(|| details_json.get("stype").and_then(|s| s.as_i64()))+ .unwrap_or(1);+ let type_str = if type_val == 2 { "Series" } else { "Movie" };++ let genres = details_json+ .get("genre")+ .and_then(|g| g.as_array())+ .map(|a| {+ a.iter()+ .filter_map(|v| v.as_str())+ .collect::<Vec<_>>()+ .join(", ")+ })+ .unwrap_or_else(|| "N/A".to_string());+ let duration = details_json+ .get("duration")+ .and_then(|d| d.as_str())+ .unwrap_or("N/A");+ let country = details_json+ .get("countryName")+ .and_then(|c| c.as_str())+ .unwrap_or("N/A");+ let content_rating = details_json+ .get("contentRating")+ .and_then(|c| c.as_str())+ .unwrap_or("N/A");+ let imdb_rating = details_json+ .get("imdbRatingValue")+ .and_then(|r| {+ r.as_f64()+ .map(|rf| rf.to_string())+ .or_else(|| r.as_str().map(|s| s.to_string()))+ })+ .unwrap_or_else(|| "N/A".to_string());++ let details_block = Block::default()+ .borders(Borders::ALL)+ .border_type(ratatui::widgets::BorderType::Rounded)+ .title(" Subject Info ")+ .title_style(theme.title)+ .border_style(theme.border);++ let inner_area = details_block.inner(chunks[0]);+ frame.render_widget(details_block.clone(), chunks[0]);++ let v_chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([Constraint::Length(15), Constraint::Min(1)])+ .split(inner_area);++ let top_area = v_chunks[0];+ let synopsis_area = v_chunks[1];++ let h_chunks = Layout::default()+ .direction(Direction::Horizontal)+ .constraints([+ Constraint::Length(20),+ Constraint::Length(2),+ Constraint::Min(1),+ ])+ .split(top_area);++ let poster_area = h_chunks[0];+ let meta_area = h_chunks[2];++ if let Some(img) = &state.poster_image {+ if state.poster_protocol.as_ref().map(|(r, _)| *r) != Some(poster_area)+ && let Some(picker) = &mut state.image_picker+ {+ let size = ratatui::layout::Size::new(poster_area.width, poster_area.height);+ if let Ok(proto) =+ picker.new_protocol(img.clone(), size, ratatui_image::Resize::Fit(None))+ {+ state.poster_protocol = Some((poster_area, proto));+ }+ }+ if let Some((_, proto)) = &state.poster_protocol {+ frame.render_widget(ratatui_image::Image::new(proto), poster_area);+ }+ } else {+ let spinner_frames = ['⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏'];+ let current_spinner = spinner_frames[(state.tick_count as usize) % spinner_frames.len()];++ let placeholder = Paragraph::new(format!("\n\n\n\n\n {} Loading Art...", current_spinner))+ .style(theme.text_dim)+ .alignment(Alignment::Center);+ frame.render_widget(placeholder, poster_area);+ }++ let mut staff_list = Vec::new();+ if let Some(staff) = details_json.get("staffList").and_then(|s| s.as_array()) {+ for person in staff.iter().take(3) {+ if let Some(name) = person.get("name").and_then(|n| n.as_str()) {+ staff_list.push(name.to_string());+ }+ }+ }+ let cast = if staff_list.is_empty() {+ "N/A".to_string()+ } else {+ staff_list.join(", ")+ };++ let mut dubs_list = Vec::new();+ if let Some(dubs) = details_json.get("dubs").and_then(|d| d.as_array()) {+ for dub in dubs {+ if let Some(lang) = dub.get("lanName").and_then(|n| n.as_str()) {+ let mut name = if lang.to_lowercase().starts_with("original") {+ "Original".to_string()+ } else {+ lang.replace("dub", "")+ .replace("Dub", "")+ .trim()+ .to_string()+ };+ if name.to_lowercase() == "ptbr" {+ name = "Portuguese (BR)".to_string();+ }+ if !dubs_list.contains(&name) {+ dubs_list.push(name);+ }+ }+ }+ }++ dubs_list.sort_by(|a, b| {+ if a == "Original" {+ std::cmp::Ordering::Less+ } else if b == "Original" {+ std::cmp::Ordering::Greater+ } else {+ a.cmp(b)+ }+ });+ let dubbing_str = if dubs_list.is_empty() {+ "N/A".to_string()+ } else {+ dubs_list.join(", ")+ };++ let viewers = details_json+ .get("viewers")+ .and_then(|v| v.as_i64())+ .unwrap_or(0);++ let label_style = theme.header;+ let val_style = theme.text;++ let meta_lines = vec![+ Line::from(vec![+ Span::styled("Title: ", label_style),+ Span::styled(title, val_style),+ ]),+ Line::from(vec![+ Span::styled("Type: ", label_style),+ Span::styled(type_str, val_style),+ ]),+ Line::from(vec![+ Span::styled("Genre: ", label_style),+ Span::styled(genres, val_style),+ ]),+ Line::from(vec![+ Span::styled("Released: ", label_style),+ Span::styled(year, val_style),+ ]),+ Line::from(vec![+ Span::styled("Duration: ", label_style),+ Span::styled(duration, val_style),+ ]),+ Line::from(vec![+ Span::styled("Rating: ", label_style),+ Span::styled(+ format!("{} (IMDb: {})", content_rating, imdb_rating),+ val_style,+ ),+ ]),+ Line::from(vec![+ Span::styled("Country: ", label_style),+ Span::styled(country, val_style),+ ]),+ Line::from(vec![+ Span::styled("Cast: ", label_style),+ Span::styled(cast, val_style),+ ]),+ Line::from(vec![+ Span::styled("Dubbing: ", label_style),+ Span::styled(dubbing_str, val_style),+ ]),+ Line::from(vec![+ Span::styled("Viewers: ", label_style),+ Span::styled(viewers.to_string(), val_style),+ ]),+ ];++ let synopsis_lines = vec![+ Line::from(vec![Span::styled("Synopsis:", label_style)]),+ Line::from(vec![]),+ ];++ frame.render_widget(+ Paragraph::new(meta_lines).wrap(Wrap { trim: true }),+ meta_area,+ );++ let mut syn_lines = synopsis_lines;+ syn_lines.push(Line::from(vec![Span::styled(intro, theme.text_dim)]));+ let intro_p = Paragraph::new(syn_lines).wrap(Wrap { trim: true });+ frame.render_widget(intro_p, synopsis_area);++ let has_languages = if let Some(dubs) = details_json.get("dubs").and_then(|d| d.as_array()) {+ dubs.len() > 1+ } else {+ false+ };++ let (is_series, bottom_chunks) = if type_val == 2 && !state.available_seasons.is_empty() {+ if has_languages {+ (+ true,+ Layout::default()+ .direction(Direction::Horizontal)+ .constraints([+ Constraint::Percentage(15), // Languages+ Constraint::Percentage(15), // Seasons+ Constraint::Percentage(15), // Episodes+ Constraint::Percentage(55), // Streams+ ])+ .split(chunks[1]),+ )+ } else {+ (+ true,+ Layout::default()+ .direction(Direction::Horizontal)+ .constraints([+ Constraint::Percentage(15), // Seasons+ Constraint::Percentage(15), // Episodes+ Constraint::Percentage(70), // Streams+ ])+ .split(chunks[1]),+ )+ }+ } else {+ if has_languages {+ (+ false,+ Layout::default()+ .direction(Direction::Horizontal)+ .constraints([+ Constraint::Percentage(20), // Languages+ Constraint::Percentage(80), // Streams+ ])+ .split(chunks[1]),+ )+ } else {+ (+ false,+ Layout::default()+ .direction(Direction::Horizontal)+ .constraints([Constraint::Percentage(100)])+ .split(chunks[1]),+ )+ }+ };++ if has_languages {+ use ratatui::widgets::{List, ListItem};+ let mut lang_items = Vec::new();+ if let Some(dubs) = details_json.get("dubs").and_then(|d| d.as_array()) {+ for dub in dubs {+ if let Some(lang) = dub.get("lanName").and_then(|n| n.as_str()) {+ let mut name = if lang.to_lowercase().starts_with("original") {+ "Original".to_string()+ } else {+ lang.replace("dub", "")+ .replace("Dub", "")+ .trim()+ .to_string()+ };+ if name.to_lowercase() == "ptbr" {+ name = "Portuguese (BR)".to_string();+ }+ lang_items.push(ListItem::new(name).style(theme.text));+ }+ }+ }+ let lang_border = if state.details_pane == crate::tui::state::DetailsPane::Languages {+ theme.border_focus+ } else {+ theme.border+ };+ let lang_list = List::new(lang_items)+ .block(+ Block::default()+ .borders(Borders::ALL)+ .border_type(ratatui::widgets::BorderType::Rounded)+ .title(" Audio/Dub ")+ .border_style(lang_border),+ )+ .highlight_style(theme.highlight.bg(ratatui::style::Color::Rgb(30, 30, 50)))+ .highlight_symbol(">> ");++ frame.render_stateful_widget(lang_list, bottom_chunks[0], &mut state.language_list_state);+ }++ if is_series {+ use ratatui::widgets::{List, ListItem};+ let seasons_items: Vec<ListItem> = state+ .available_seasons+ .iter()+ .map(|s| {+ let se_num = s.get("se").and_then(|v| v.as_i64()).unwrap_or(1);+ ListItem::new(format!("Season {}", se_num)).style(theme.text)+ })+ .collect();++ let seasons_border = if state.details_pane == crate::tui::state::DetailsPane::Seasons {+ theme.border_focus+ } else {+ theme.border+ };+ let seasons_list = List::new(seasons_items)+ .block(+ Block::default()+ .borders(Borders::ALL)+ .border_type(ratatui::widgets::BorderType::Rounded)+ .title(" Seasons ")+ .border_style(seasons_border),+ )+ .highlight_style(theme.highlight.bg(ratatui::style::Color::Rgb(30, 30, 50)))+ .highlight_symbol(">> ");++ let seasons_area = if has_languages {+ bottom_chunks[1]+ } else {+ bottom_chunks[0]+ };+ frame.render_stateful_widget(seasons_list, seasons_area, &mut state.season_list_state);++ let ep_items: Vec<ListItem> = if let Some(season) = state+ .available_seasons+ .get(state.season_list_state.selected().unwrap_or(0))+ {+ let max_ep = season.get("maxEp").and_then(|m| m.as_i64()).unwrap_or(1);+ (1..=max_ep)+ .map(|ep| ListItem::new(format!("Episode {}", ep)).style(theme.text))+ .collect()+ } else {+ vec![]+ };++ let eps_border = if state.details_pane == crate::tui::state::DetailsPane::Episodes {+ theme.border_focus+ } else {+ theme.border+ };+ let eps_list = List::new(ep_items)+ .block(+ Block::default()+ .borders(Borders::ALL)+ .border_type(ratatui::widgets::BorderType::Rounded)+ .title(" Episodes ")+ .border_style(eps_border),+ )+ .highlight_style(theme.highlight.bg(ratatui::style::Color::Rgb(30, 30, 50)))+ .highlight_symbol(">> ");++ let eps_area = if has_languages {+ bottom_chunks[2]+ } else {+ bottom_chunks[1]+ };+ frame.render_stateful_widget(eps_list, eps_area, &mut state.episode_list_state);+ }++ let streams_area = if is_series {+ if has_languages {+ bottom_chunks[3]+ } else {+ bottom_chunks[2]+ }+ } else {+ if has_languages {+ bottom_chunks[1]+ } else {+ bottom_chunks[0]+ }+ };+ let streams_border = if state.details_pane == crate::tui::state::DetailsPane::Streams {+ theme.border_focus+ } else {+ theme.border+ };++ let streams_block = Block::default()+ .borders(Borders::ALL)+ .border_type(ratatui::widgets::BorderType::Rounded)+ .title(" Streams | [Enter/P] Play [D] Download [C] Copy Link [B/Esc] Back ")+ .title_style(theme.title)+ .border_style(streams_border);++ let table = match &state.selected_resources {+ Some(res) => {+ if let Some(list) = res.get("list").and_then(|l| l.as_array()) {+ let rows: Vec<Row> = list+ .iter()+ .map(|file| {+ let resolution =+ file.get("resolution").and_then(|r| r.as_i64()).unwrap_or(0);+ let codec = file+ .get("codecName")+ .and_then(|c| c.as_str())+ .unwrap_or("None");+ let upload_by = file+ .get("uploadBy")+ .and_then(|u| u.as_str())+ .unwrap_or("None");+ let size_str = file.get("size").and_then(|s| s.as_str()).unwrap_or("0");+ let size_formatted = if let Ok(bytes) = size_str.parse::<f64>() {+ let mb = bytes / 1024.0 / 1024.0;+ if mb > 1024.0 {+ format!("{:.1} GB", mb / 1024.0)+ } else {+ format!("{:.0} MB", mb)+ }+ } else {+ "Unknown".to_string()+ };++ let subs_count = file+ .get("extCaptions")+ .and_then(|c| c.as_array())+ .map(|a| a.len())+ .unwrap_or(0);+ let subs_str = if subs_count > 0 {+ format!("{} subs", subs_count)+ } else {+ "None".to_string()+ };++ Row::new(vec![+ Cell::from(format!("{}p", resolution)).style(theme.header),+ Cell::from(codec).style(theme.text),+ Cell::from(size_formatted).style(theme.text_dim),+ Cell::from(subs_str).style(if subs_count > 0 {+ theme.border_focus+ } else {+ theme.text_dim+ }),+ Cell::from(upload_by).style(theme.text),+ ])+ })+ .collect();++ let widths = [+ Constraint::Length(6),+ Constraint::Length(6),+ Constraint::Length(9),+ Constraint::Length(8),+ Constraint::Min(15),+ ];++ Table::new(rows, widths)+ .header(+ Row::new(vec!["Res", "Codec", "Size", "Subs", "Uploader"])+ .style(theme.title),+ )+ .block(streams_block)+ .row_highlight_style(theme.highlight.bg(ratatui::style::Color::Rgb(30, 30, 50))) // Cool subtle glow animation+ .highlight_symbol(">> ")+ } else {+ let has_multiple_dubs = state+ .selected_details+ .as_ref()+ .and_then(|d| d.get("dubs"))+ .and_then(|d| d.as_array())+ .is_some_and(|a| a.len() > 1);+ let msg = if has_multiple_dubs && !state.language_chosen {+ "Please select a language dubbing first."+ } else {+ "No streaming files available."+ };+ let r = Row::new(vec![Cell::from(msg)]);+ Table::new(vec![r], [Constraint::Percentage(100)]).block(streams_block)+ }+ }+ None => {+ let has_multiple_dubs = state+ .selected_details+ .as_ref()+ .and_then(|d| d.get("dubs"))+ .and_then(|d| d.as_array())+ .is_some_and(|a| a.len() > 1);++ let msg = if state.is_loading {+ let spinner_frames = ['⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏'];+ let spinner = spinner_frames[(state.tick_count as usize) % spinner_frames.len()];+ format!("{} Loading streams...", spinner)+ } else if state.status_message.to_lowercase().contains("failed")+ || state.status_message.to_lowercase().contains("error")+ {+ state.status_message.clone()+ } else if has_multiple_dubs && !state.language_chosen {+ "Select a language/dubbing and press Enter to load streams.".to_string()+ } else {+ "Failed to load streams.".to_string()+ };+ let r = Row::new(vec![Cell::from(msg).style(if state.is_loading {+ theme.text_dim+ } else if has_multiple_dubs && !state.language_chosen {+ theme.border_focus+ } else {+ theme.error+ })]);+ Table::new(vec![r], [Constraint::Percentage(100)]).block(streams_block)+ }+ };++ frame.render_stateful_widget(table, streams_area, &mut state.resource_list_state);+}diff --git a/src/tui/screens/help.rs b/src/tui/screens/help.rsnew file mode 100644index 0000000..cafe26c--- /dev/null+++ b/src/tui/screens/help.rs@@ -0,0 +1,82 @@+use crate::tui::{state::AppState, theme::Theme};+use ratatui::{+ Frame,+ layout::{Alignment, Constraint, Direction, Layout, Rect},+ text::{Line, Span},+ widgets::{Block, BorderType, Borders, Clear, Paragraph},+};++pub fn draw(frame: &mut Frame, area: Rect, _state: &AppState, theme: &Theme) {+ let popup_layout = Layout::default()+ .direction(Direction::Vertical)+ .constraints([+ Constraint::Percentage(25),+ Constraint::Length(14),+ Constraint::Percentage(25),+ ])+ .split(area);++ let popup_chunk = Layout::default()+ .direction(Direction::Horizontal)+ .constraints([+ Constraint::Percentage(25),+ Constraint::Min(40),+ Constraint::Percentage(25),+ ])+ .split(popup_layout[1])[1];++ frame.render_widget(Clear, popup_chunk);++ let help_text = vec![+ Line::from(vec![+ Span::styled(" [q] ", theme.header),+ Span::styled("Quit Application", theme.text),+ ]),+ Line::from(vec![+ Span::styled(" [?] ", theme.header),+ Span::styled("Toggle Help Menu", theme.text),+ ]),+ Line::from(vec![+ Span::styled(" [/], [s] ", theme.header),+ Span::styled("Search Movies/Series", theme.text),+ ]),+ Line::from(vec![+ Span::styled(" [l] ", theme.header),+ Span::styled("Toggle Logs", theme.text),+ ]),+ Line::from(vec![+ Span::styled(" [b], ESC ", theme.header),+ Span::styled("Go Back / Clear", theme.text),+ ]),+ Line::from(vec![+ Span::styled(" [↑]/[k] ", theme.header),+ Span::styled("Move Up", theme.text),+ ]),+ Line::from(vec![+ Span::styled(" [↓]/[j] ", theme.header),+ Span::styled("Move Down", theme.text),+ ]),+ Line::from(vec![+ Span::styled(" [Enter] ", theme.header),+ Span::styled("Select / Submit", theme.text),+ ]),+ Line::from(vec![+ Span::styled(" [y] ", theme.header),+ Span::styled("Copy URL (Details Screen)", theme.text),+ ]),+ ];++ let block = Block::default()+ .title(" Keybindings Help ")+ .title_alignment(Alignment::Center)+ .title_style(theme.title)+ .borders(Borders::ALL)+ .border_type(BorderType::Rounded)+ .border_style(theme.border_focus);++ let p = Paragraph::new(help_text)+ .block(block)+ .alignment(Alignment::Left);++ frame.render_widget(p, popup_chunk);+}diff --git a/src/tui/screens/home.rs b/src/tui/screens/home.rsnew file mode 100644index 0000000..7b88e8d--- /dev/null+++ b/src/tui/screens/home.rs@@ -0,0 +1,431 @@+use crate::tui::{+ state::{AppState, InputMode},+ theme::Theme,+};+use ratatui::{+ Frame,+ layout::{Alignment, Constraint, Direction, Layout, Rect},+ text::{Line, Span},+ widgets::{Block, BorderType, Borders, Cell, Paragraph, Row, Table, Wrap},+};++pub fn draw(frame: &mut Frame, area: Rect, state: &mut AppState, theme: &Theme) {+ let search_content = if state.input_mode == InputMode::Editing {+ format!(" {}█", state.search_query)+ } else {+ if state.search_query.is_empty() {+ " (Press '/' to search)".to_string()+ } else {+ format!(" {}", state.search_query)+ }+ };++ let border_style = match state.input_mode {+ InputMode::Editing => theme.border_focus,+ InputMode::Normal => theme.border,+ };++ if state.search_results.is_empty()+ && !state.is_loading+ && !state.status_message.to_lowercase().contains("fail")+ {+ let is_narrow = area.width < 60;+ let logo_height = if is_narrow { 3 } else { 5 };+ let logo_text = if is_narrow {+ r"█▀▄▀█ █▀█ █ █ █ █▀▀ █▀▄ █▀█ ▀▄▀+█ ▀ █ █▄█ ▀▄▀ █ ██▄ █▄▀ █▄█ █ █"+ } else {+ r" __ __ ___ __ __ ___ ___ ___ ___ __ __+ | \/ |/ _ \ \ \ / /|_ _|| __|| _ ) / _ \ \ \/ /+ | |\/| | (_) | \ V / | | | _| | _ \| (_) | > <+ |_| |_|\___/ \_/ |___||___||___/ \___/ /_/\_\ "+ };++ let vertical_chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([+ Constraint::Percentage(30), // Top padding+ Constraint::Length(logo_height), // Dynamic logo height+ Constraint::Length(3), // Search bar height+ Constraint::Length(2), // Status text+ Constraint::Percentage(30), // Bottom padding+ ])+ .split(area);++ let horizontal_chunks = Layout::default()+ .direction(Direction::Horizontal)+ .constraints([+ Constraint::Percentage(5), // Left padding+ Constraint::Percentage(90), // Ample centered space for logo+ Constraint::Percentage(5), // Right padding+ ])+ .split(vertical_chunks[1]); // Logo horizontal constraints++ let search_chunks = Layout::default()+ .direction(Direction::Horizontal)+ .constraints([+ Constraint::Percentage(20),+ Constraint::Percentage(60),+ Constraint::Percentage(20),+ ])+ .split(vertical_chunks[2]); // Search bar horizontal constraints++ let title_art = Paragraph::new(logo_text)+ .alignment(Alignment::Center)+ .style(theme.title);++ let search_bar = Paragraph::new(search_content)+ .block(+ Block::default()+ .borders(Borders::ALL)+ .border_type(BorderType::Rounded)+ .title(" Search ")+ .title_style(theme.title)+ .border_style(border_style),+ )+ .style(theme.text);++ let intro = Paragraph::new(state.status_message.as_str())+ .alignment(Alignment::Center)+ .style(theme.text_dim);++ frame.render_widget(title_art, horizontal_chunks[1]);+ frame.render_widget(search_bar, search_chunks[1]);+ frame.render_widget(intro, vertical_chunks[3]);+ } else {+ let chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([+ Constraint::Length(3), // Top header / search input+ Constraint::Min(4), // Main content panel+ ])+ .split(area);++ let search_bar = Paragraph::new(search_content)+ .block(+ Block::default()+ .borders(Borders::ALL)+ .border_type(BorderType::Rounded)+ .title(" Search ")+ .title_style(theme.title)+ .border_style(border_style),+ )+ .style(theme.text);+ frame.render_widget(search_bar, chunks[0]);++ let content_split = Layout::default()+ .direction(Direction::Horizontal)+ .constraints([Constraint::Percentage(50), Constraint::Percentage(50)])+ .split(chunks[1]);++ let list_block = Block::default()+ .borders(Borders::ALL)+ .border_type(BorderType::Rounded)+ .title(" Results ")+ .title_style(theme.title)+ .border_style(theme.border);++ if state.is_loading {+ let spinner_frames = ['⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏'];+ let spinner = spinner_frames[(state.tick_count as usize) % spinner_frames.len()];++ let inner_area = list_block.inner(content_split[0]);+ frame.render_widget(list_block, content_split[0]);++ let v_chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([+ Constraint::Percentage(45),+ Constraint::Length(1),+ Constraint::Percentage(50),+ ])+ .split(inner_area);++ let p = Paragraph::new(format!("{} Searching...", spinner))+ .alignment(Alignment::Center)+ .style(theme.text_dim);+ frame.render_widget(p, v_chunks[1]);+ } else if !state.search_results.is_empty() {+ let rows: Vec<Row> = state+ .search_results+ .iter()+ .map(|res| {+ let type_tag = if res.stype == 1 {+ "MOVIE"+ } else if res.stype == 2 {+ "TV"+ } else {+ "OTHER"+ };+ Row::new(vec![+ Cell::from(type_tag).style(theme.header),+ Cell::from(res.title.as_str()).style(theme.text),+ Cell::from(res.release_year.as_str()).style(theme.text_dim),+ ])+ })+ .collect();++ let widths = [+ Constraint::Length(8),+ Constraint::Percentage(70),+ Constraint::Length(10),+ ];++ let table = Table::new(rows, widths)+ .header(Row::new(vec!["Type", "Title", "Date"]).style(theme.title))+ .block(list_block)+ .row_highlight_style(theme.highlight.bg(ratatui::style::Color::Rgb(30, 30, 50)))+ .highlight_symbol(">> ");++ frame.render_stateful_widget(table, content_split[0], &mut state.search_list_state);+ } else {+ let inner_area = list_block.inner(content_split[0]);+ frame.render_widget(list_block, content_split[0]);++ let v_chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([+ Constraint::Percentage(45),+ Constraint::Length(1),+ Constraint::Percentage(50),+ ])+ .split(inner_area);++ let p = Paragraph::new(state.status_message.clone())+ .alignment(Alignment::Center)+ .style(theme.error);+ frame.render_widget(p, v_chunks[1]);+ }++ let preview_block = Block::default()+ .borders(Borders::ALL)+ .border_type(BorderType::Rounded)+ .title(" Info Preview ")+ .title_style(theme.title)+ .border_style(theme.border);++ let preview_area = content_split[1];++ if state.preview_loading {+ let spinner_frames = ['⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏'];+ let spinner = spinner_frames[(state.tick_count as usize) % spinner_frames.len()];++ let inner_area = preview_block.inner(preview_area);+ frame.render_widget(preview_block, preview_area);++ let v_chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([+ Constraint::Percentage(45),+ Constraint::Length(1),+ Constraint::Percentage(50),+ ])+ .split(inner_area);++ let loading_p = Paragraph::new(format!("{} Loading metadata...", spinner))+ .alignment(Alignment::Center)+ .style(theme.text_dim);+ frame.render_widget(loading_p, v_chunks[1]);+ } else if let Some(preview) = &state.search_preview {+ let inner_area = preview_block.inner(preview_area);+ frame.render_widget(preview_block.clone(), preview_area);++ let v_chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([Constraint::Length(15), Constraint::Min(1)])+ .split(inner_area);++ let top_area = v_chunks[0];+ let synopsis_area = v_chunks[1];++ let chunks = Layout::default()+ .direction(Direction::Horizontal)+ .constraints([+ Constraint::Length(20),+ Constraint::Length(2),+ Constraint::Min(1),+ ])+ .split(top_area);++ let poster_area = chunks[0];+ let meta_area = chunks[2];++ if let Some(img) = &state.poster_image {+ if state.poster_protocol.as_ref().map(|(r, _)| *r) != Some(poster_area)+ && let Some(picker) = &mut state.image_picker+ {+ let size = ratatui::layout::Size::new(poster_area.width, poster_area.height);+ if let Ok(proto) =+ picker.new_protocol(img.clone(), size, ratatui_image::Resize::Fit(None))+ {+ state.poster_protocol = Some((poster_area, proto));+ }+ }+ if let Some((_, proto)) = &state.poster_protocol {+ frame.render_widget(ratatui_image::Image::new(proto), poster_area);+ }+ } else {+ let spinner_frames = ['⠋', '⠙', '⠹', '⠸', '⠼', '⠴', '⠦', '⠧', '⠇', '⠏'];+ let current_spinner =+ spinner_frames[(state.tick_count as usize) % spinner_frames.len()];++ let v_chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([+ Constraint::Percentage(45),+ Constraint::Length(1),+ Constraint::Percentage(50),+ ])+ .split(poster_area);++ let placeholder = Paragraph::new(format!("{} Loading Art...", current_spinner))+ .style(theme.text_dim)+ .alignment(Alignment::Center);+ frame.render_widget(placeholder, v_chunks[1]);+ }++ let title = preview+ .get("title")+ .and_then(|t| t.as_str())+ .unwrap_or("Unknown");+ let description = preview+ .get("description")+ .and_then(|d| d.as_str())+ .or_else(|| preview.get("intro").and_then(|i| i.as_str()))+ .unwrap_or("No description available.");+ let release_date = preview+ .get("releaseDate")+ .and_then(|y| y.as_str())+ .or_else(|| preview.get("year").and_then(|y| y.as_str()))+ .unwrap_or("N/A");+ let imdb_rating = preview+ .get("imdbRatingValue")+ .and_then(|r| {+ r.as_f64()+ .map(|rf| rf.to_string())+ .or_else(|| r.as_str().map(|s| s.to_string()))+ })+ .unwrap_or_else(|| "N/A".to_string());++ let genres = preview+ .get("genre")+ .and_then(|g| g.as_array())+ .map(|a| {+ a.iter()+ .filter_map(|v| v.as_str())+ .collect::<Vec<_>>()+ .join(", ")+ })+ .unwrap_or_else(|| "N/A".to_string());+ let duration = preview+ .get("duration")+ .and_then(|d| d.as_str())+ .unwrap_or("N/A");+ let country = preview+ .get("countryName")+ .and_then(|c| c.as_str())+ .unwrap_or("N/A");+ let content_rating = preview+ .get("contentRating")+ .and_then(|c| c.as_str())+ .unwrap_or("N/A");++ let type_val = preview+ .get("subjectType")+ .and_then(|s| s.as_i64())+ .unwrap_or(1);+ let type_str = if type_val == 2 { "TV Series" } else { "Movie" };++ let viewers = preview.get("viewers").and_then(|v| v.as_i64()).unwrap_or(0);++ let mut staff_list = Vec::new();+ if let Some(staff) = preview.get("staffList").and_then(|s| s.as_array()) {+ for person in staff.iter().take(3) {+ if let Some(name) = person.get("name").and_then(|n| n.as_str()) {+ staff_list.push(name.to_string());+ }+ }+ }+ let cast = if staff_list.is_empty() {+ "N/A".to_string()+ } else {+ staff_list.join(", ")+ };++ let label_style = theme.header;+ let val_style = theme.text;++ let meta_lines = vec![+ Line::from(vec![+ Span::styled("Title: ", label_style),+ Span::styled(title, val_style),+ ]),+ Line::from(vec![+ Span::styled("Type: ", label_style),+ Span::styled(type_str, val_style),+ ]),+ Line::from(vec![+ Span::styled("Genre: ", label_style),+ Span::styled(genres, val_style),+ ]),+ Line::from(vec![+ Span::styled("Released: ", label_style),+ Span::styled(release_date, val_style),+ ]),+ Line::from(vec![+ Span::styled("Duration: ", label_style),+ Span::styled(duration, val_style),+ ]),+ Line::from(vec![+ Span::styled("Rating: ", label_style),+ Span::styled(+ format!("{} (IMDb: {})", content_rating, imdb_rating),+ val_style,+ ),+ ]),+ Line::from(vec![+ Span::styled("Country: ", label_style),+ Span::styled(country, val_style),+ ]),+ Line::from(vec![+ Span::styled("Cast: ", label_style),+ Span::styled(cast, val_style),+ ]),+ Line::from(vec![+ Span::styled("Viewers: ", label_style),+ Span::styled(viewers.to_string(), val_style),+ ]),+ ];++ let synopsis_lines = vec![+ Line::from(vec![Span::styled("Synopsis:", label_style)]),+ Line::from(vec![]),+ ];++ let meta_p = Paragraph::new(meta_lines).wrap(Wrap { trim: true });+ frame.render_widget(meta_p, meta_area);++ let mut syn_lines = synopsis_lines;+ syn_lines.push(Line::from(vec![Span::styled(description, theme.text_dim)]));+ let p = Paragraph::new(syn_lines).wrap(Wrap { trim: true });+ frame.render_widget(p, synopsis_area);+ } else {+ let inner_area = preview_block.inner(preview_area);+ frame.render_widget(preview_block, preview_area);++ let v_chunks = Layout::default()+ .direction(Direction::Vertical)+ .constraints([+ Constraint::Percentage(45),+ Constraint::Length(1),+ Constraint::Percentage(50),+ ])+ .split(inner_area);++ let empty_p = Paragraph::new("Select a result to preview info.")+ .alignment(Alignment::Center)+ .style(theme.text_dim);+ frame.render_widget(empty_p, v_chunks[1]);+ }+ }+}diff --git a/src/tui/screens/logs.rs b/src/tui/screens/logs.rsnew file mode 100644index 0000000..ebe8b32--- /dev/null+++ b/src/tui/screens/logs.rs@@ -0,0 +1,46 @@+use crate::tui::{state::AppState, theme::Theme};+use ratatui::{+ Frame,+ layout::Rect,+ widgets::{Block, Borders, Clear, List, ListItem},+};++pub fn draw(frame: &mut Frame, area: Rect, state: &AppState, theme: &Theme) {+ let popup_layout = ratatui::layout::Layout::default()+ .direction(ratatui::layout::Direction::Vertical)+ .constraints([+ ratatui::layout::Constraint::Percentage(20),+ ratatui::layout::Constraint::Percentage(60),+ ratatui::layout::Constraint::Percentage(20),+ ])+ .split(area);++ let popup_area = ratatui::layout::Layout::default()+ .direction(ratatui::layout::Direction::Horizontal)+ .constraints([+ ratatui::layout::Constraint::Percentage(15),+ ratatui::layout::Constraint::Percentage(70),+ ratatui::layout::Constraint::Percentage(15),+ ])+ .split(popup_layout[1])[1];++ frame.render_widget(Clear, popup_area); // Clear background under popup++ let list_items: Vec<ListItem> = state+ .logs+ .iter()+ .map(|log| ListItem::new(log.as_str()))+ .collect();++ let logs_block = Block::default()+ .borders(Borders::ALL)+ .title(" Trace Log Console [Press 'l' to toggle] ")+ .title_style(theme.title)+ .border_style(theme.border_focus);++ let logs_list = List::new(list_items)+ .block(logs_block)+ .style(theme.text_dim);++ frame.render_widget(logs_list, popup_area);+}diff --git a/src/tui/state.rs b/src/tui/state.rsnew file mode 100644index 0000000..5426401--- /dev/null+++ b/src/tui/state.rs@@ -0,0 +1,130 @@+use ratatui::widgets::{ListState, TableState};++#[derive(Debug, Clone, Copy, PartialEq, Eq)]+pub enum Screen {+ Home,+ Search,+ Details,+}++#[derive(Default, PartialEq)]+pub enum DetailsPane {+ #[default]+ Streams,+ Seasons,+ Episodes,+ Languages,+}++#[derive(Debug, Clone, Copy, PartialEq, Eq)]+pub enum InputMode {+ Normal,+ Editing,+}++#[derive(Debug, Clone)]+pub struct SearchResult {+ pub id: String,+ pub title: String,+ pub stype: i64,+ pub release_year: String,+}++pub struct AppState {+ pub active_screen: Screen,+ pub input_mode: InputMode,+ pub search_query: String,+ pub search_results: Vec<SearchResult>,+ pub search_list_state: TableState,++ pub selected_details: Option<serde_json::Value>,+ pub selected_resources: Option<serde_json::Value>,+ pub resource_list_state: TableState,++ pub details_pane: DetailsPane,+ pub selected_season: usize,+ pub selected_episode: usize,+ pub season_list_state: ListState,+ pub episode_list_state: ListState,+ pub language_list_state: ListState,+ pub available_seasons: Vec<serde_json::Value>,++ pub search_preview: Option<serde_json::Value>,+ pub preview_loading: bool,++ pub tick_count: u64,+ pub poster_image: Option<image::DynamicImage>,+ pub poster_protocol: Option<(ratatui::layout::Rect, ratatui_image::protocol::Protocol)>,+ pub image_picker: Option<ratatui_image::picker::Picker>,++ pub show_logs: bool,+ pub show_help: bool,+ pub logs: Vec<String>,+ pub logs_scroll: usize,++ pub active_error: Option<String>,+ pub is_loading: bool,+ pub status_message: String,++ pub toast_message: Option<String>,+ pub toast_timer: usize,++ pub download_progress: Option<f64>,+ pub download_status: Option<String>,+ pub cancel_download: std::sync::Arc<std::sync::atomic::AtomicBool>,++ pub language_chosen: bool,+}++impl Default for AppState {+ fn default() -> Self {+ Self {+ active_screen: Screen::Home,+ input_mode: InputMode::Normal,+ search_query: String::new(),+ search_results: Vec::new(),+ search_list_state: TableState::default(),+ selected_details: None,+ selected_resources: None,+ resource_list_state: TableState::default(),++ details_pane: DetailsPane::default(),+ selected_season: 1,+ selected_episode: 1,+ season_list_state: ListState::default(),+ episode_list_state: ListState::default(),+ language_list_state: ListState::default(),+ available_seasons: vec![],++ search_preview: None,+ preview_loading: false,+ tick_count: 0,+ poster_image: None,+ poster_protocol: None,+ image_picker: None,+ show_logs: false,+ show_help: false,+ logs: vec!["MovieBox TUI started.".to_string()],+ logs_scroll: 0,+ active_error: None,+ is_loading: false,+ status_message: "Ready.".to_string(),+ toast_message: None,+ toast_timer: 0,+ download_progress: None,+ download_status: None,+ cancel_download: std::sync::Arc::new(std::sync::atomic::AtomicBool::new(false)),+ language_chosen: false,+ }+ }+}++impl AppState {+ pub fn add_log(&mut self, msg: String) {+ self.logs.push(msg);+ if self.logs.len() > 200 {+ self.logs.remove(0);+ }+ self.logs_scroll = self.logs.len().saturating_sub(1);+ }+}diff --git a/src/tui/theme.rs b/src/tui/theme.rsnew file mode 100644index 0000000..79c19b6--- /dev/null+++ b/src/tui/theme.rs@@ -0,0 +1,41 @@+use ratatui::style::{Color, Modifier, Style};++#[derive(Debug, Clone)]+pub struct Theme {+ pub border: Style,+ pub border_focus: Style,+ pub text: Style,+ pub text_dim: Style,+ pub title: Style,+ pub highlight: Style,+ pub header: Style,+ pub error: Style,+ pub success: Style,+ pub shortcut: Style,+ pub overlay: Style,+}++impl Default for Theme {+ fn default() -> Self {+ Self {+ border: Style::default().fg(Color::Rgb(88, 91, 112)), // Surface 1+ border_focus: Style::default().fg(Color::Rgb(137, 180, 250)), // Blue+ text: Style::default().fg(Color::Rgb(205, 214, 244)), // Text+ text_dim: Style::default().fg(Color::Rgb(166, 173, 200)), // Subtext 1+ title: Style::default()+ .fg(Color::Rgb(203, 166, 247))+ .add_modifier(Modifier::BOLD), // Mauve+ highlight: Style::default()+ .bg(Color::Rgb(49, 50, 68))+ .fg(Color::Rgb(137, 180, 250))+ .add_modifier(Modifier::BOLD), // Surface 0 + Blue fg+ header: Style::default()+ .fg(Color::Rgb(245, 194, 231))+ .add_modifier(Modifier::BOLD), // Flamingo+ error: Style::default().fg(Color::Rgb(243, 139, 168)), // Red+ success: Style::default().fg(Color::Rgb(166, 227, 161)), // Green+ shortcut: Style::default().fg(Color::Rgb(250, 179, 135)), // Peach+ overlay: Style::default().fg(Color::Rgb(108, 112, 134)), // Overlay 0+ }+ }+}diff --git a/src/v3/client.rs b/src/v3/client.rsnew file mode 100644index 0000000..a32512a--- /dev/null+++ b/src/v3/client.rs@@ -0,0 +1,191 @@+use crate::v3::crypto::build_signed_headers;+use reqwest::Response;+use serde_json::Value;+use std::sync::Arc;+use tokio::sync::RwLock;++const HOST_POOL: &[&str] = &[+ "https://api6.aoneroom.com",+ "https://api5.aoneroom.com",+ "https://api4.aoneroom.com",+ "https://api4sg.aoneroom.com",+ "https://api3.aoneroom.com",+ "https://api6sg.aoneroom.com",+ "https://api.inmoviebox.com",+];++const RETRY_STATUS_CODES: &[u16] = &[403, 406, 407, 429, 500, 502, 503, 504];++#[derive(thiserror::Error, Debug)]+pub enum ScraperError {+ #[error("Reqwest error: {0}")]+ Reqwest(#[from] reqwest::Error),+ #[error("API error status: {0}")]+ ApiStatus(u16),+ #[error("All hosts exhausted")]+ HostsExhausted,+ #[error("JSON error: {0}")]+ Json(#[from] serde_json::Error),+ #[error("Missing expected token")]+ MissingToken,+}++#[derive(Clone)]+pub struct MovieBoxClient {+ client: reqwest::Client,+ runtime_token: Arc<RwLock<Option<String>>>,+ active_base_idx: Arc<RwLock<usize>>,+ user_agent: String,+ client_info: String,+ spoofed_ip: String,+}++impl Default for MovieBoxClient {+ fn default() -> Self {+ Self::new()+ }+}++impl MovieBoxClient {+ pub fn new() -> Self {+ let client = reqwest::Client::builder()+ .timeout(std::time::Duration::from_secs(5))+ .build()+ .expect("Failed to build reqwest client; TLS backend may be missing");++ let (user_agent, client_info) = crate::v3::crypto::generate_client_info_and_ua();+ let spoofed_ip = crate::v3::crypto::random_spoofed_ip();++ Self {+ client,+ runtime_token: Arc::new(RwLock::new(None)),+ active_base_idx: Arc::new(RwLock::new(0)),+ user_agent,+ client_info,+ spoofed_ip,+ }+ }++ pub fn user_agent(&self) -> &str {+ &self.user_agent+ }++ pub fn client_info(&self) -> &str {+ &self.client_info+ }++ pub fn spoofed_ip(&self) -> &str {+ &self.spoofed_ip+ }++ pub async fn init(&self) -> Result<(), ScraperError> {+ let path = "/wefeed-mobile-bff/tab-operating?page=1&tabId=0&version=";+ let _ = self.get(path).await?;++ let token = self.runtime_token.read().await;+ if token.is_none() {+ return Err(ScraperError::MissingToken);+ }+ Ok(())+ }++ async fn absorb_x_user(&self, headers: &reqwest::header::HeaderMap) {+ let Some(x_user_val) = headers.get("x-user") else {+ return;+ };+ let Ok(x_user_str) = x_user_val.to_str() else {+ return;+ };+ let Ok(json): Result<Value, _> = serde_json::from_str(x_user_str) else {+ return;+ };+ let Some(token) = json.get("token").and_then(|t| t.as_str()) else {+ return;+ };+ if !token.is_empty() {+ let mut write_token = self.runtime_token.write().await;+ *write_token = Some(token.to_string());+ }+ }++ pub async fn get(&self, path_and_query: &str) -> Result<Value, ScraperError> {+ self.request("GET", path_and_query, None).await+ }++ pub async fn post(&self, path_and_query: &str, body: &Value) -> Result<Value, ScraperError> {+ let body_str = serde_json::to_string(body)?;+ self.request("POST", path_and_query, Some(&body_str)).await+ }++ async fn request(+ &self,+ method: &str,+ path_and_query: &str,+ body: Option<&str>,+ ) -> Result<Value, ScraperError> {+ let start_idx = *self.active_base_idx.read().await;++ for i in 0..HOST_POOL.len() {+ let idx = (start_idx + i) % HOST_POOL.len();+ let base = HOST_POOL[idx];+ let url = format!("{}{}", base, path_and_query);++ let token = self.runtime_token.read().await.clone();+ let headers = build_signed_headers(+ method,+ &url,+ body,+ token.as_deref(),+ &self.user_agent,+ &self.client_info,+ &self.spoofed_ip,+ );++ let mut builder = match method {+ "POST" => self.client.post(&url),+ _ => self.client.get(&url),+ };++ builder = builder.headers(headers);+ if let Some(b) = body {+ builder = builder.body(b.to_string());+ }++ match builder.send().await {+ Ok(resp) => {+ self.absorb_x_user(resp.headers()).await;+ let status = resp.status().as_u16();++ if RETRY_STATUS_CODES.contains(&status) {+ continue;+ }++ let mut active_idx = self.active_base_idx.write().await;+ *active_idx = idx;++ return self.parse_response(resp).await;+ }+ Err(_) => {+ continue;+ }+ }+ }++ Err(ScraperError::HostsExhausted)+ }++ async fn parse_response(&self, resp: Response) -> Result<Value, ScraperError> {+ let status = resp.status();+ if !status.is_success() {+ return Err(ScraperError::ApiStatus(status.as_u16()));+ }++ let body_val: Value = resp.json().await?;++ if let Some(data) = body_val.get("data") {+ Ok(data.clone())+ } else {+ Ok(body_val)+ }+ }+}diff --git a/src/v3/crypto.rs b/src/v3/crypto.rsnew file mode 100644index 0000000..01ec7a9--- /dev/null+++ b/src/v3/crypto.rs@@ -0,0 +1,291 @@+use base64::Engine;+use hmac::{Hmac, KeyInit, Mac};+use md5::{Digest, Md5};+use std::collections::BTreeMap;+use std::time::{SystemTime, UNIX_EPOCH};+use url::Url;++const SECRET_KEY_DEFAULT: &str = "76iRl07s0xSN9jqmEWAt79EBJZulIQIsV64FZr2O";+const SIGNATURE_BODY_MAX_BYTES: usize = 102_400;++type HmacMd5 = Hmac<Md5>;++fn md5_hex(data: &[u8]) -> String {+ let mut hasher = Md5::new();+ hasher.update(data);+ hasher+ .finalize()+ .iter()+ .map(|b| format!("{:02x}", b))+ .collect()+}++fn b64_decode(val: &str) -> Vec<u8> {+ let mut padded = val.to_string();+ let padding = (4 - padded.len() % 4) % 4;+ padded.push_str(&"=".repeat(padding));+ base64::engine::general_purpose::STANDARD+ .decode(padded)+ .unwrap_or_default()+}++fn b64_encode(data: &[u8]) -> String {+ base64::engine::general_purpose::STANDARD.encode(data)+}++pub fn generate_x_client_token(ts: u64) -> String {+ let ts_str = ts.to_string();+ let reversed_ts: String = ts_str.chars().rev().collect();+ let hash_val = md5_hex(reversed_ts.as_bytes());+ format!("{},{}", ts_str, hash_val)+}++fn sorted_query_string(url: &str) -> String {+ let Ok(parsed) = Url::parse(url) else {+ return String::new();+ };++ let mut params = BTreeMap::new();+ for (k, v) in parsed.query_pairs() {+ params+ .entry(k.into_owned())+ .or_insert_with(Vec::new)+ .push(v.into_owned());+ }++ if params.is_empty() {+ return String::new();+ }++ let mut parts = Vec::new();+ for (key, values) in params {+ for val in values {+ parts.push(format!("{}={}", key, val));+ }+ }+ parts.join("&")+}++pub fn build_canonical_string(+ method: &str,+ accept: Option<&str>,+ content_type: Option<&str>,+ url: &str,+ body: Option<&str>,+ timestamp_ms: u64,+) -> String {+ let parsed = Url::parse(url).expect("URL is valid by construction from base and path");+ let path = parsed.path();+ let query = sorted_query_string(url);+ let canonical_url = if query.is_empty() {+ path.to_string()+ } else {+ format!("{}?{}", path, query)+ };++ let body_bytes = body.map(|b| b.as_bytes());+ let (body_hash, body_length) = if let Some(bytes) = body_bytes {+ let len = bytes.len();+ let truncated = if len > SIGNATURE_BODY_MAX_BYTES {+ &bytes[..SIGNATURE_BODY_MAX_BYTES]+ } else {+ bytes+ };+ (md5_hex(truncated), len.to_string())+ } else {+ (String::new(), String::new())+ };++ format!(+ "{}\n{}\n{}\n{}\n{}\n{}\n{}",+ method.to_uppercase(),+ accept.unwrap_or(""),+ content_type.unwrap_or(""),+ body_length,+ timestamp_ms,+ body_hash,+ canonical_url+ )+}++pub fn generate_x_tr_signature(+ method: &str,+ accept: Option<&str>,+ content_type: Option<&str>,+ url: &str,+ body: Option<&str>,+ timestamp_ms: u64,+) -> String {+ let canonical = build_canonical_string(method, accept, content_type, url, body, timestamp_ms);+ let secret_bytes = b64_decode(SECRET_KEY_DEFAULT);++ let mut mac = HmacMd5::new_from_slice(&secret_bytes).expect("HMAC can take key of any size");+ mac.update(canonical.as_bytes());+ let sig_b64 = b64_encode(&mac.finalize().into_bytes());++ format!("{}|2|{}", timestamp_ms, sig_b64)+}++pub fn build_signed_headers(+ method: &str,+ url: &str,+ body: Option<&str>,+ auth_token: Option<&str>,+ user_agent: &str,+ client_info: &str,+ spoofed_ip: &str,+) -> reqwest::header::HeaderMap {+ let ts = SystemTime::now()+ .duration_since(UNIX_EPOCH)+ .expect("System time is after UNIX EPOCH")+ .as_millis() as u64;++ let accept = "application/json";+ let content_type = "application/json";++ let client_token = generate_x_client_token(ts);+ let signature =+ generate_x_tr_signature(method, Some(accept), Some(content_type), url, body, ts);++ let mut headers = reqwest::header::HeaderMap::new();++ headers.insert(reqwest::header::USER_AGENT, user_agent.parse().expect("Valid ASCII"));+ headers.insert("Accept", accept.parse().expect("Valid ASCII"));+ headers.insert("Content-Type", content_type.parse().expect("Valid ASCII"));+ headers.insert("Connection", "keep-alive".parse().expect("Valid ASCII"));+ headers.insert("X-Client-Token", client_token.parse().expect("Valid ASCII"));+ headers.insert("x-tr-signature", signature.parse().expect("Valid ASCII"));+ headers.insert("X-Client-Info", client_info.parse().expect("Valid ASCII"));+ headers.insert("X-Client-Status", "0".parse().expect("Valid ASCII"));++ headers.insert("X-Forwarded-For", spoofed_ip.parse().expect("Valid ASCII"));+ headers.insert("X-Real-IP", spoofed_ip.parse().expect("Valid ASCII"));+ headers.insert("Client-IP", spoofed_ip.parse().expect("Valid ASCII"));+ headers.insert("CF-Connecting-IP", spoofed_ip.parse().expect("Valid ASCII"));++ if let Some(token) = auth_token {+ headers.insert(+ reqwest::header::AUTHORIZATION,+ format!("Bearer {}", token).parse().expect("Valid ASCII"),+ );+ }++ headers+}++pub(crate) fn generate_client_info_and_ua() -> (String, String) {+ use rand::RngExt;+ let mut rng = rand::rng();++ let android_versions = [+ ("9", "PQ3A.190605.03081104"),+ ("10", "QP1A.191005.007.A3"),+ ("11", "RP1A.200720.011"),+ ("12", "S1B.220414.015"),+ ("13", "TQ2A.230405.003"),+ ];+ let redmi_devices = [+ ("23078RKD5C", "Redmi"),+ ("2201117TY", "Redmi"),+ ("2201117TG", "Redmi"),+ ("22101316G", "Redmi"),+ ("21121210G", "Redmi"),+ ("M2012K11AG", "Redmi"),+ ("M2007J20CG", "Redmi"),+ ];+ let version_codes = [50020042, 50020043, 50020044, 50020045, 50020046];+ let network_types = ["NETWORK_WIFI", "NETWORK_MOBILE"];+ let timezones = [+ "Asia/Kolkata",+ "Asia/Shanghai",+ "Asia/Tokyo",+ "America/New_York",+ "Europe/London",+ ];++ let android = android_versions[rng.random_range(0..android_versions.len())];+ let device = redmi_devices[rng.random_range(0..redmi_devices.len())];+ let version_code = version_codes[rng.random_range(0..version_codes.len())];+ let network = network_types[rng.random_range(0..network_types.len())];+ let timezone = timezones[rng.random_range(0..timezones.len())];+ let gaid = random_uuid();+ let device_id = random_hex(32);++ let user_agent = format!(+ "com.community.oneroom/{} (Linux; U; Android {}; en_US; {}; Build/{}; Cronet/135.0.7012.3)",+ version_code, android.0, device.0, android.1+ );++ let client_info = format!(+ r#"{{"package_name":"com.community.oneroom","version_name":"3.0.03.0529.03","version_code":{},"os":"android","os_version":"{}","install_ch":"ps","device_id":"{}","install_store":"ps","gaid":"{}","brand":"{}","model":"{}","system_language":"en","net":"{}","region":"US","timezone":"{}","sp_code":"40401","X-Play-Mode":"2"}}"#,+ version_code, android.0, device_id, gaid, device.1, device.0, network, timezone+ );++ (user_agent, client_info)+}++fn random_hex(len: usize) -> String {+ use rand::RngExt;+ let mut rng = rand::rng();+ (0..len)+ .map(|_| format!("{:x}", rng.random_range(0..16)))+ .collect()+}++fn random_uuid() -> String {+ format!(+ "{}-{}-{}-{}-{}",+ random_hex(8),+ random_hex(4),+ random_hex(4),+ random_hex(4),+ random_hex(12)+ )+}++pub(crate) fn random_spoofed_ip() -> String {+ use rand::RngExt;+ let mut rng = rand::rng();+ let host: u8 = rng.random_range(1..254);+ format!("103.241.224.{}", host)+}++#[cfg(test)]+mod tests {+ use super::*;++ #[test]+ fn test_generate_x_client_token() {+ let ts = 1629876543210;+ let token = generate_x_client_token(ts);+ assert!(token.starts_with("1629876543210,"));+ let parts: Vec<&str> = token.split(',').collect();+ assert_eq!(parts.len(), 2);+ assert_eq!(parts[1].len(), 32); // MD5 is 32 hex chars+ }++ #[test]+ fn test_build_canonical_string() {+ let ts = 1000;+ let url = "https://api.example.com/test?b=2&a=1";+ let canonical = build_canonical_string("GET", Some("application/json"), Some("application/json"), url, None, ts);++ let parts: Vec<&str> = canonical.split('\n').collect();+ assert_eq!(parts.len(), 7);+ assert_eq!(parts[0], "GET");+ assert_eq!(parts[1], "application/json");+ assert_eq!(parts[2], "application/json");+ assert_eq!(parts[3], ""); // body length+ assert_eq!(parts[4], "1000"); // ts+ assert_eq!(parts[5], ""); // body hash+ assert_eq!(parts[6], "/test?a=1&b=2"); // sorted query+ }++ #[test]+ fn test_generate_x_tr_signature() {+ let ts = 1000;+ let url = "https://api.example.com/test";+ let sig = generate_x_tr_signature("GET", Some("application/json"), Some("application/json"), url, None, ts);+ assert!(sig.starts_with("1000|2|"));+ }+}diff --git a/src/v3/mod.rs b/src/v3/mod.rsnew file mode 100644index 0000000..8ef78e9--- /dev/null+++ b/src/v3/mod.rs@@ -0,0 +1,123 @@+pub mod client;+pub mod crypto;++use client::{ScraperError, MovieBoxClient};+use serde_json::{Value, json};++impl MovieBoxClient {+ pub async fn get_homepage(&self, page: usize) -> Result<Value, ScraperError> {+ let path = format!(+ "/wefeed-mobile-bff/tab-operating?page={}&tabId=0&version=",+ page+ );+ self.get(&path).await+ }++ pub async fn search(&self, query: &str, page: usize) -> Result<Value, ScraperError> {+ let payload = json!({+ "keyword": query,+ "page": page,+ "perPage": 20,+ "subjectType": "All",+ "tabId": "All"+ });+ self.post("/wefeed-mobile-bff/subject-api/search/v2", &payload)+ .await+ }++ pub async fn get_details(&self, subject_id: &str) -> Result<Value, ScraperError> {+ let path = format!(+ "/wefeed-mobile-bff/subject-api/get?subjectId={}",+ subject_id+ );+ self.get(&path).await+ }++ pub async fn get_resources(+ &self,+ subject_id: &str,+ season: usize,+ episode: usize,+ page: usize,+ resolution: Option<&str>,+ ) -> Result<Value, ScraperError> {+ let res_param = if let Some(r) = resolution {+ if r.is_empty() {+ String::new()+ } else {+ format!("&resolution={}", r)+ }+ } else {+ String::new()+ };++ let path = if season == 0 && episode == 0 {+ format!(+ "/wefeed-mobile-bff/subject-api/resource?subjectId={}&page={}&perPage=20{}",+ subject_id, page, res_param+ )+ } else {+ format!(+ "/wefeed-mobile-bff/subject-api/resource?subjectId={}&se={}&ep={}&page={}&perPage=20{}",+ subject_id, season, episode, page, res_param+ )+ };+ self.get(&path).await+ }++ pub async fn get_play_info(+ &self,+ subject_id: &str,+ season: usize,+ episode: usize,+ ) -> Result<Value, ScraperError> {+ let path = if season == 0 && episode == 0 {+ format!(+ "/wefeed-mobile-bff/subject-api/play-info?subjectId={}",+ subject_id+ )+ } else {+ format!(+ "/wefeed-mobile-bff/subject-api/play-info?subjectId={}&se={}&ep={}",+ subject_id, season, episode+ )+ };+ self.get(&path).await+ }++ pub async fn get_all_resources(+ &self,+ subject_id: &str,+ season: usize,+ episode: usize,+ ) -> Result<Value, ScraperError> {+ let resolutions = ["1080", "720", "480", "360", ""];+ let mut handles = Vec::new();++ for res in resolutions {+ let c = self.clone();+ let sid = subject_id.to_string();+ let r = res.to_string();+ handles.push(tokio::spawn(async move {+ c.get_resources(&sid, season, episode, 1, Some(&r)).await+ }));+ }++ let mut all_list = Vec::new();+ for h in handles {+ if let Ok(Ok(res)) = h.await+ && let Some(list) = res.get("list").and_then(|l| l.as_array())+ {+ all_list.extend(list.clone());+ }+ }++ if all_list.is_empty() {+ Err(ScraperError::ApiStatus(404))+ } else {+ let mut combined = serde_json::Map::new();+ combined.insert("list".to_string(), serde_json::Value::Array(all_list));+ Ok(serde_json::Value::Object(combined))+ }+ }+}