mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-25 08:41:05 +00:00
..
This commit is contained in:
parent
dddf432f1c
commit
c7ec9cceff
1 changed files with 3 additions and 7 deletions
|
|
@ -25,13 +25,9 @@ impl Widget for Which<'_> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
let height = cands.0.len() as u16 + 2;
|
let height = area.height.min(cands.0.len() as u16 + 2);
|
||||||
let area = Rect {
|
let y = area.height.saturating_sub(height + 2);
|
||||||
x: 1,
|
let area = Rect { x: area.width.min(1), y, width: area.width.saturating_sub(2), height };
|
||||||
y: area.height.saturating_sub(height + 2),
|
|
||||||
width: area.width.saturating_sub(2),
|
|
||||||
height,
|
|
||||||
};
|
|
||||||
|
|
||||||
let chunks = layout::Layout::new(Direction::Horizontal, [
|
let chunks = layout::Layout::new(Direction::Horizontal, [
|
||||||
Constraint::Ratio(1, 3),
|
Constraint::Ratio(1, 3),
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue