mirror of
https://github.com/l0ng-ai/tty7.git
synced 2026-09-21 16:02:20 +00:00
fix(sftp): make the cancel button match the one beside it
The transfer row draws its reveal button as an IconName::Close-family icon inside a 24px hit target with a tooltip; the cancel button next to it was a bare "✕" text label with neither. It is the only glyph-as-label button in the app — every other close in this file and the eight others across the UI use IconName::Close. Verified by matching the sibling's construction, not on screen: showing it needs a transfer in flight against a live SSH host.
This commit is contained in:
+11
-6
@@ -1650,13 +1650,18 @@ impl Tty7App {
|
||||
})
|
||||
.when(running, |this| {
|
||||
this.child(
|
||||
Button::new(("sftp-cancel-job", job_id as usize))
|
||||
.label("✕")
|
||||
.xsmall()
|
||||
.ghost()
|
||||
.on_click(cx.listener(move |this, _, _w, cx| {
|
||||
crate::ui::tab_strip::hit_target(
|
||||
Button::new(("sftp-cancel-job", job_id as usize))
|
||||
.icon(IconName::Close)
|
||||
.xsmall()
|
||||
.ghost(),
|
||||
)
|
||||
.tooltip(t(L10nKey::Cancel))
|
||||
.on_click(
|
||||
cx.listener(move |this, _, _w, cx| {
|
||||
this.sftp_cancel_job(job_id, cx)
|
||||
})),
|
||||
}),
|
||||
),
|
||||
)
|
||||
}),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user