diff --git a/Cargo.lock b/Cargo.lock index 5739f0e..a4f1129 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -146,9 +146,9 @@ checksum = "37b2a672a2cb129a2e41c10b1224bb368f9f37a2b16b612598138befd7b37eb5" [[package]] name = "castaway" -version = "0.2.2" +version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a17ed5635fc8536268e5d4de1e22e81ac34419e5f052d4d51f4e01dcc263fcc" +checksum = "0abae9be0aaf9ea96a3b1b8b1b55c602ca751eba1b1500220cea4ecbafe7c0d5" dependencies = [ "rustversion", ] @@ -234,13 +234,14 @@ checksum = "0b6a852b24ab71dffc585bcb46eaf7959d175cb865a7152e35b348d1b2960422" [[package]] name = "compact_str" -version = "0.7.1" +version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f86b9c4c00838774a6d902ef931eff7470720c51d90c2e32cfe15dc304737b3f" +checksum = "6050c3a16ddab2e412160b31f2c871015704239bca62f72f6e5f0be631d3f644" dependencies = [ "castaway", "cfg-if", "itoa", + "rustversion", "ryu", "static_assertions", ] @@ -327,22 +328,6 @@ version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" -[[package]] -name = "crossterm" -version = "0.27.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f476fe445d41c9e991fd07515a6f463074b782242ccf4a5b7b1d1012e70824df" -dependencies = [ - "bitflags", - "crossterm_winapi", - "libc", - "mio 0.8.11", - "parking_lot", - "signal-hook", - "signal-hook-mio", - "winapi", -] - [[package]] name = "crossterm" version = "0.28.1" @@ -351,7 +336,7 @@ checksum = "829d955a0bb380ef178a640b91779e3987da38c9aea133b20614cfed8cdea9c6" dependencies = [ "bitflags", "crossterm_winapi", - "mio 1.0.1", + "mio", "parking_lot", "rustix", "signal-hook", @@ -502,6 +487,16 @@ dependencies = [ "similar", ] +[[package]] +name = "instability" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b23a0c8dfe501baac4adf6ebbfa6eddf8f0c07f56b058cc1288017e32397846c" +dependencies = [ + "quote", + "syn", +] + [[package]] name = "is-terminal" version = "0.4.12" @@ -628,18 +623,6 @@ version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" -[[package]] -name = "mio" -version = "0.8.11" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" -dependencies = [ - "libc", - "log", - "wasi", - "windows-sys 0.48.0", -] - [[package]] name = "mio" version = "1.0.1" @@ -838,18 +821,18 @@ dependencies = [ [[package]] name = "ratatui" -version = "0.27.0" +version = "0.28.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d16546c5b5962abf8ce6e2881e722b4e0ae3b6f1a08a26ae3573c55853ca68d3" +checksum = "fdef7f9be5c0122f890d58bdf4d964349ba6a6161f705907526d891efabba57d" dependencies = [ "bitflags", "cassowary", "compact_str", - "crossterm 0.27.0", + "crossterm", + "instability", "itertools 0.13.0", "lru", "paste", - "stability", "strum", "strum_macros", "unicode-segmentation", @@ -983,7 +966,7 @@ dependencies = [ "assert_matches", "cassowary", "criterion", - "crossterm 0.28.1", + "crossterm", "insta", "num-traits", "proptest", @@ -1060,8 +1043,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34db1a06d485c9142248b7a054f034b349b212551f3dfd19c94d45a754a217cd" dependencies = [ "libc", - "mio 0.8.11", - "mio 1.0.1", + "mio", "signal-hook", ] @@ -1086,16 +1068,6 @@ version = "1.13.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" -[[package]] -name = "stability" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ff9eaf853dec4c8802325d8b6d3dffa86cc707fd7a1a4cdbf416e13b061787a" -dependencies = [ - "quote", - "syn", -] - [[package]] name = "static_assertions" version = "1.1.0" diff --git a/scm-record/Cargo.toml b/scm-record/Cargo.toml index 5e744c8..8060008 100644 --- a/scm-record/Cargo.toml +++ b/scm-record/Cargo.toml @@ -25,7 +25,7 @@ crossterm = "0.28" num-traits = "0.2" thiserror = "1.0" tracing = "0.1" -ratatui = "0.27.0" +ratatui = "0.28.1" unicode-width = "0.1" # Features: serde diff --git a/scm-record/src/render.rs b/scm-record/src/render.rs index 01e35a9..320fad4 100644 --- a/scm-record/src/render.rs +++ b/scm-record/src/render.rs @@ -410,7 +410,7 @@ impl<'a, ComponentId: Clone + Debug + Eq + Hash> Viewport<'a, ComponentId> { component: &C, ) -> DrawnRects { let widget = TopLevelWidget { component, x, y }; - let term_area = frame.size(); + let term_area = frame.area(); let mut drawn_rects = Default::default(); frame.render_stateful_widget(widget, term_area, &mut drawn_rects); drawn_rects diff --git a/scm-record/src/ui.rs b/scm-record/src/ui.rs index e400a6b..1bebc2d 100644 --- a/scm-record/src/ui.rs +++ b/scm-record/src/ui.rs @@ -564,7 +564,7 @@ impl<'state, 'input> Recorder<'state, 'input> { 'outer: loop { let menu_bar = self.make_menu_bar(); let app = self.make_app(menu_bar.clone(), None); - let term_height = usize::from(term.get_frame().size().height); + let term_height = usize::from(term.get_frame().area().height); let mut drawn_rects: Option> = None; term.draw(|frame| {