aboutsummaryrefslogtreecommitdiff
path: root/src/ui.rs
diff options
context:
space:
mode:
authorOgulcan Celik <ogulcancelik@gmail.com>2026-07-15 03:58:07 +0300
committerOgulcan Celik <ogulcancelik@gmail.com>2026-07-15 04:02:14 +0300
commit2c7c8beb079c5fd58a2e53efd2058df050ad9f55 (patch)
tree6756f671dc728d915b1d6ebececa8cf7f70b66fb /src/ui.rs
parent88370e1516182ab519d22a12fa82d5780a40fee6 (diff)
feat: add floating popup panes
refs #1125
Diffstat (limited to 'src/ui.rs')
-rw-r--r--src/ui.rs12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/ui.rs b/src/ui.rs
index 349a033a..85574989 100644
--- a/src/ui.rs
+++ b/src/ui.rs
@@ -38,7 +38,10 @@ use self::mobile::{
use self::navigator::render_navigator_overlay;
pub(crate) use self::onboarding::onboarding_welcome_continue_rect;
use self::onboarding::render_onboarding_overlay;
-use self::panes::{compute_pane_infos, render_panes, resize_tab_panes};
+pub(crate) use self::panes::popup_pane_rects;
+use self::panes::{
+ compute_pane_infos, render_panes, render_popup_pane, resize_popup_pane, resize_tab_panes,
+};
pub(crate) use self::release_notes::{
product_announcement_display_lines, release_notes_close_button_rect,
release_notes_display_lines, release_notes_wrapped_line_count, PRODUCT_ANNOUNCEMENT_MODAL_SIZE,
@@ -287,6 +290,7 @@ fn compute_view_internal(
);
if resize_panes {
resize_background_tab_panes_for_desktop(app, terminal_runtimes, main_area, cell_size);
+ resize_popup_pane(app, terminal_runtimes, terminal_area, cell_size);
}
let toast_hit_area = app
@@ -364,6 +368,7 @@ fn compute_mobile_view(
);
if resize_panes {
resize_background_tab_panes_to_area(app, terminal_runtimes, terminal_area, cell_size);
+ resize_popup_pane(app, terminal_runtimes, terminal_area, cell_size);
}
let header_hits = compute_mobile_header_hit_areas(app, header_rect);
@@ -424,6 +429,7 @@ pub fn render_with_runtime_registry(
// Ambient notifications sit above panes, but below interactive overlays.
render_notifications(app, frame, terminal_area);
+ render_popup_pane(app, terminal_runtimes, frame, terminal_area);
match app.mode {
Mode::Onboarding => render_onboarding_overlay(app, frame, frame.area()),
@@ -1392,6 +1398,8 @@ mod tests {
command: "lazygit".to_string(),
action: crate::config::CustomCommandAction::Pane,
description: Some("open lazygit".to_string()),
+ width: None,
+ height: None,
},
crate::config::CustomCommandKeybind {
bindings: crate::config::ActionKeybinds::prefix("alt+h"),
@@ -1399,6 +1407,8 @@ mod tests {
command: "echo hello".to_string(),
action: crate::config::CustomCommandAction::Shell,
description: None,
+ width: None,
+ height: None,
},
];