mirror of
https://github.com/microsoft/vscode.git
synced 2026-07-10 16:58:55 -05:00
Terminal theme icon support
This commit is contained in:
@@ -58,11 +58,6 @@
|
||||
opacity: 0 !important;
|
||||
}
|
||||
|
||||
.monaco-workbench .terminal-tab::before {
|
||||
font-family: 'codicon' !important;
|
||||
font-size: 16px !important;
|
||||
}
|
||||
|
||||
.monaco-workbench .terminal-tab:not(.terminal-uri-icon)::before {
|
||||
background-image: none !important;
|
||||
}
|
||||
|
||||
@@ -191,11 +191,18 @@ export class TerminalEditorInput extends EditorInput implements IEditorCloseHand
|
||||
return this._terminalInstance?.title || this.resource.fragment;
|
||||
}
|
||||
|
||||
override getIcon(): ThemeIcon | undefined {
|
||||
if (!this._terminalInstance || !ThemeIcon.isThemeIcon(this._terminalInstance.icon)) {
|
||||
return undefined;
|
||||
}
|
||||
return this._terminalInstance.icon;
|
||||
}
|
||||
|
||||
override getLabelExtraClasses(): string[] {
|
||||
if (!this._terminalInstance) {
|
||||
return [];
|
||||
}
|
||||
const extraClasses: string[] = ['terminal-tab'];
|
||||
const extraClasses: string[] = ['terminal-tab', 'product-icon'];
|
||||
const colorClass = getColorClass(this._terminalInstance);
|
||||
if (colorClass) {
|
||||
extraClasses.push(colorClass);
|
||||
@@ -204,9 +211,6 @@ export class TerminalEditorInput extends EditorInput implements IEditorCloseHand
|
||||
if (uriClasses) {
|
||||
extraClasses.push(...uriClasses);
|
||||
}
|
||||
if (ThemeIcon.isThemeIcon(this._terminalInstance.icon)) {
|
||||
extraClasses.push(`codicon-${this._terminalInstance.icon.id}`);
|
||||
}
|
||||
return extraClasses;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user