Skip to content

Commit

Permalink
Changed class name for manage packages extension (#8789)
Browse files Browse the repository at this point in the history
* Adds rule for .icon extensions

* revert

* Fixed issue and formatted for consistency

* reverted change for regular menuentryaction

* changed id back to old name

* Removed comment

* removed space
  • Loading branch information
smartguest authored Jan 4, 2020
1 parent fa2fcf2 commit 362af3c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/vs/platform/actions/browser/menuEntryActionViewItem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -333,13 +333,13 @@ export class LabeledMenuItemActionItem extends MenuEntryActionViewItem {
iconClass = MenuEntryActionViewItem.ICON_PATH_TO_CSS_RULES.get(iconPathMapKey)!;
} else {
iconClass = ids.nextId();
createCSSRule(`.icon.${iconClass}`, `background-image: ${asCSSUrl(item.icon.light || item.icon.dark)}`);
createCSSRule(`.vs-dark .icon.${iconClass}, .hc-black .icon.${iconClass}`, `background-image: ${asCSSUrl(item.icon.dark)}`);
createCSSRule(`.codicon.${iconClass}`, `background-image: ${asCSSUrl(item.icon.light || item.icon.dark)}`);
createCSSRule(`.vs-dark .codicon.${iconClass}, .hc-black .codicon.${iconClass}`, `background-image: ${asCSSUrl(item.icon.dark)}`);
MenuEntryActionViewItem.ICON_PATH_TO_CSS_RULES.set(iconPathMapKey, iconClass);
}

addClasses(this.label, 'icon', iconClass, this._defaultCSSClassToAdd);
this._labeledItemClassDispose = toDisposable(() => removeClasses(this.label, 'icon', iconClass, this._defaultCSSClassToAdd));
addClasses(this.label, 'codicon', this._defaultCSSClassToAdd, iconClass);
this._labeledItemClassDispose = toDisposable(() => removeClasses(this.label, 'codicon', this._defaultCSSClassToAdd, iconClass));
}
}

Expand Down

0 comments on commit 362af3c

Please sign in to comment.