Partial fix where height is lower than total monitors, but there is no

area for scrollbar (area.len() == 1)
This commit is contained in:
Marco De Araujo 2026-01-08 13:33:37 -04:00
parent 142f76684b
commit 74464f6a48

View file

@ -163,9 +163,13 @@ impl App {
fn render_main(frame: &mut Frame, area: Vec<Rect>, state: &mut DashboardViewState) {
render_monitor_list(frame, area[0], state);
let total_monitors = state.get_all_monitors().len();
if !state.show_vertical_scrollbar(area[0].height) {
return;
}
if area[0].height > total_monitors as u16 {
if area.len() <= 1 {
let _formgen = area[0].height;
dbg!(area[0].height);
return;
}