mirror of
https://github.com/Eugeny/tabby.git
synced 2025-10-05 22:44:55 +00:00
set default cancel button in message boxes
This commit is contained in:
@@ -209,10 +209,11 @@ export class SSHTabComponent extends BaseTerminalTabComponent {
|
||||
{
|
||||
type: 'warning',
|
||||
message: `Disconnect from ${this.profile?.options.host}?`,
|
||||
buttons: ['Cancel', 'Disconnect'],
|
||||
defaultId: 1,
|
||||
buttons: ['Disconnect', 'Do not close'],
|
||||
defaultId: 0,
|
||||
cancelId: 1,
|
||||
}
|
||||
)).response === 1
|
||||
)).response === 0
|
||||
}
|
||||
|
||||
async openSFTP (): Promise<void> {
|
||||
|
@@ -27,6 +27,7 @@ export class CommonSFTPContextMenu extends SFTPContextMenuItemProvider {
|
||||
type: 'warning',
|
||||
message: `Delete ${item.fullPath}?`,
|
||||
defaultId: 0,
|
||||
cancelId: 1,
|
||||
buttons: ['Delete', 'Cancel'],
|
||||
})).response === 0) {
|
||||
await this.deleteItem(item, panel.sftp)
|
||||
|
Reference in New Issue
Block a user