diff --git a/tabby-core/src/components/splitTab.component.ts b/tabby-core/src/components/splitTab.component.ts index 612322b5..b9b7393e 100644 --- a/tabby-core/src/components/splitTab.component.ts +++ b/tabby-core/src/components/splitTab.component.ts @@ -483,6 +483,7 @@ export class SplitTabComponent extends BaseTabComponent implements AfterViewInit newTab.parent = this this.recoveryStateChangedHint.next() this.onAfterTabAdded(newTab) + this.updateTitle() } /** diff --git a/tabby-core/src/services/profiles.service.ts b/tabby-core/src/services/profiles.service.ts index 55f48330..ac87efa5 100644 --- a/tabby-core/src/services/profiles.service.ts +++ b/tabby-core/src/services/profiles.service.ts @@ -37,13 +37,6 @@ export class ProfilesService { if (params) { const tab = this.app.openNewTab(params) ;(this.app.getParentTab(tab) ?? tab).color = profile.color ?? null - - if (profile.name) { - tab.setTitle(profile.name) - } - if (profile.disableDynamicTitle) { - tab['disableDynamicTitle'] = true - } return tab } return null @@ -51,7 +44,15 @@ export class ProfilesService { async newTabParametersForProfile

(profile: PartialProfile

): Promise|null> { const fullProfile = this.getConfigProxyForProfile(profile) - return this.providerForProfile(fullProfile)?.getNewTabParameters(fullProfile) ?? null + const params = await this.providerForProfile(fullProfile)?.getNewTabParameters(fullProfile) ?? null + if (params) { + params.inputs ??= {} + params.inputs['title'] = profile.name + if (profile.disableDynamicTitle) { + params.inputs['disableDynamicTitle'] = true + } + } + return params } getProviders (): ProfileProvider[] {