mirror of
https://github.com/Eugeny/tabby.git
synced 2025-06-08 21:40:03 +00:00
feat(settings): Eugeny/tabby#8680 configurable priotity on quick connect profile selector option
This commit is contained in:
parent
aba773b546
commit
d36b2b21c9
@ -54,3 +54,4 @@ hacks:
|
|||||||
disableVibrancyWhileDragging: false
|
disableVibrancyWhileDragging: false
|
||||||
enableFluentBackground: false
|
enableFluentBackground: false
|
||||||
language: null
|
language: null
|
||||||
|
defaultQuickConnectProvider: "ssh"
|
||||||
|
@ -183,6 +183,7 @@ export class ProfilesService {
|
|||||||
freeInputPattern: this.translate.instant('Connect to "%s"...'),
|
freeInputPattern: this.translate.instant('Connect to "%s"...'),
|
||||||
description: `(${provider.name.toUpperCase()})`,
|
description: `(${provider.name.toUpperCase()})`,
|
||||||
icon: 'fas fa-arrow-right',
|
icon: 'fas fa-arrow-right',
|
||||||
|
weight: provider.id !== this.config.store.defaultQuickConnectProvider ? 1 : 0,
|
||||||
callback: query => {
|
callback: query => {
|
||||||
const profile = provider.quickConnect(query)
|
const profile = provider.quickConnect(query)
|
||||||
resolve(profile)
|
resolve(profile)
|
||||||
|
@ -149,6 +149,20 @@ ul.nav-tabs(ngbNav, #nav='ngbNav')
|
|||||||
option(ngValue='wt', translation) Windows Terminal
|
option(ngValue='wt', translation) Windows Terminal
|
||||||
option(ngValue='cygwin', translation) Cygwin
|
option(ngValue='cygwin', translation) Cygwin
|
||||||
|
|
||||||
|
.form-line
|
||||||
|
.header
|
||||||
|
.title(translate) Default "Connect to" type
|
||||||
|
.description(translate) Default connection type used by quick connect feature (ex. SSH, Telnet)
|
||||||
|
|
||||||
|
select.form-control(
|
||||||
|
[(ngModel)]='config.store.defaultQuickConnectProvider',
|
||||||
|
(ngModelChange)='config.save()',
|
||||||
|
)
|
||||||
|
option(
|
||||||
|
*ngFor='let provider of getQuickConnectProviders()',
|
||||||
|
[ngValue]='provider.id'
|
||||||
|
) {{provider.name}}
|
||||||
|
|
||||||
.form-line.content-box
|
.form-line.content-box
|
||||||
.header
|
.header
|
||||||
.title(translate) Default profile settings
|
.title(translate) Default profile settings
|
||||||
|
@ -312,4 +312,8 @@ export class ProfilesSettingsTabComponent extends BaseComponent {
|
|||||||
isProfileBlacklisted (profile: PartialProfile<Profile>): boolean {
|
isProfileBlacklisted (profile: PartialProfile<Profile>): boolean {
|
||||||
return profile.id && this.config.store.profileBlacklist.includes(profile.id)
|
return profile.id && this.config.store.profileBlacklist.includes(profile.id)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
getQuickConnectProviders (): ProfileProvider<Profile>[] {
|
||||||
|
return this.profileProviders.filter(x => x.supportsQuickConnect)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user