mirror of
https://github.com/Eugeny/tabby.git
synced 2025-07-19 18:07:58 +00:00
fixed SVG icons in tab headers - fixes #5926
This commit is contained in:
@@ -40,7 +40,10 @@
|
||||
)
|
||||
.input-group-append
|
||||
.input-group-text
|
||||
i([class]='"fa-fw " + profile.icon')
|
||||
profile-icon(
|
||||
[icon]='profile.icon',
|
||||
[color]='profile.color'
|
||||
)
|
||||
|
||||
ng-template(#rt,let-r='result',let-t='term')
|
||||
i([class]='"fa-fw " + r')
|
||||
|
@@ -58,14 +58,9 @@ ul.nav-tabs(ngbNav, #nav='ngbNav')
|
||||
[class.list-group-item-action]='!profile.isBuiltin',
|
||||
(click)='profile.isBuiltin ? null : editProfile(profile)'
|
||||
)
|
||||
i.icon(
|
||||
class='fa-fw {{profile.icon}}',
|
||||
[style.color]='profile.color',
|
||||
*ngIf='!iconIsSVG(profile.icon)'
|
||||
)
|
||||
.icon(
|
||||
[fastHtmlBind]='profile.icon',
|
||||
*ngIf='iconIsSVG(profile.icon)'
|
||||
profile-icon(
|
||||
[icon]='profile.icon',
|
||||
[color]='profile.color'
|
||||
)
|
||||
|
||||
.no-wrap {{profile.name}}
|
||||
|
@@ -1,8 +1,8 @@
|
||||
.icon {
|
||||
profile-icon {
|
||||
width: 1.25rem;
|
||||
margin-right: 0.25rem;
|
||||
}
|
||||
|
||||
.icon + * {
|
||||
profile-icon + * {
|
||||
margin-left: 10px;
|
||||
}
|
||||
|
@@ -225,10 +225,6 @@ export class ProfilesSettingsTabComponent extends BaseComponent {
|
||||
return !this.filter || (profile.name + '$' + (this.getDescription(profile) ?? '')).toLowerCase().includes(this.filter.toLowerCase())
|
||||
}
|
||||
|
||||
iconIsSVG (icon?: string): boolean {
|
||||
return icon?.startsWith('<') ?? false
|
||||
}
|
||||
|
||||
getDescription (profile: PartialProfile<Profile>): string|null {
|
||||
return this.profilesService.getDescription(profile)
|
||||
}
|
||||
|
Reference in New Issue
Block a user