Skip to content

Commit

Permalink
refactor(gui): rename GuiIconsType to GuiIconsConfig
Browse files Browse the repository at this point in the history
  • Loading branch information
nzbin committed Aug 4, 2024
1 parent 7ddc162 commit 93ec1ba
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions projects/gui/gui-icons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,19 +52,19 @@ export const svgIcons = {

export type GuiIconType = keyof typeof svgIcons;

export type GuiIconsType = {
export type GuiIconsConfig = {
[k in GuiIconType]: string;
};

/** Injection token that can be used to provide the default icons. */
export const GUI_ICONS_CONFIG = new InjectionToken<GuiIconsType>('GUI_ICONS_CONFIG');
export const GUI_ICONS_CONFIG = new InjectionToken<GuiIconsConfig>('gui-icons-config');

@Injectable({ providedIn: 'root' })
export class GuiIconsRegistry {
constructor(
private _iconRegistry: MatIconRegistry,
private _sanitizer: DomSanitizer,
@Optional() @Inject(GUI_ICONS_CONFIG) private _defaultIcons?: GuiIconsType
@Optional() @Inject(GUI_ICONS_CONFIG) private _defaultIcons?: GuiIconsConfig
) {}

add(...iconNames: GuiIconType[]) {
Expand Down

0 comments on commit 93ec1ba

Please sign in to comment.