UNPKG

@alyle/ui

Version:

Minimal Design, a set of components for Angular

65 lines (64 loc) 3.58 kB
import { ElementRef, OnChanges, OnDestroy, OnInit, Renderer2 } from '@angular/core'; import { LyIconService } from './icon.service'; import { LyTheme2, ThemeVariables, StyleRenderer } from '@alyle/ui'; import { Platform } from '@angular/cdk/platform'; import * as i0 from "@angular/core"; export declare const STYLES: (theme: ThemeVariables) => { $priority: number; $global: (_className: string) => string; root: () => (_className: string) => string; loading: (_className: string) => string; defaultIcon: (_className: string) => string; }; /** @docs-private */ export declare class LyIconBase { _theme: LyTheme2; constructor(_theme: LyTheme2); } /** @docs-private */ export declare const LyIconMixinBase: import("@alyle/ui/src/common/constructor").Constructor<import("@alyle/ui/src/common/build-common-behaviors").CanStyleUpdater> & import("@alyle/ui/src/common/constructor").Constructor<import("@alyle/ui/src/common/bg").CanBg> & import("@alyle/ui/src/common/constructor").Constructor<import("@alyle/ui/src/common/color").CanColor> & import("@alyle/ui/src/common/constructor").Constructor<import("@alyle/ui/src/common/raised").CanRaised> & import("@alyle/ui/src/common/constructor").Constructor<import("@alyle/ui/src/common/outlined").CanOutlined> & import("@alyle/ui/src/common/constructor").Constructor<import("@alyle/ui/src/common/elevation").CanElevation> & import("@alyle/ui/src/common/constructor").Constructor<import("@alyle/ui/src/common/shadow-color").CanShadowColor> & typeof LyIconBase; export declare class LyIcon extends LyIconMixinBase implements OnChanges, OnInit, OnDestroy { private iconService; private _el; private _renderer; readonly sRenderer: StyleRenderer; private _platform; readonly classes: import("@alyle/ui").LyClasses<(theme: ThemeVariables) => { $priority: number; $global: (_className: string) => string; root: () => (_className: string) => string; loading: (_className: string) => string; defaultIcon: (_className: string) => string; }>; private _icon; private _fontSet; private _previousFontSet; private _currentClass; private _fontIcon; private _iconElement?; get icon(): string; set icon(val: string); get fontSet(): string; set fontSet(key: string); get fontIcon(): string; set fontIcon(key: string); /** @docs-private */ get hostElement(): any; constructor(iconService: LyIconService, _el: ElementRef, _renderer: Renderer2, theme: LyTheme2, sRenderer: StyleRenderer, _platform: Platform); ngOnChanges(): void; private _isDefault; private _prepareSvgIcon; private _appendChild; private _addDefaultIcon; private _updateClass; ngOnInit(): void; ngOnDestroy(): void; /** * run only browser * remove current icon */ private _cleanIcon; private _updateFontClass; static ɵfac: i0.ɵɵFactoryDeclaration<LyIcon, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<LyIcon, "ly-icon", ["lyIcon"], { "bg": { "alias": "bg"; "required": false; }; "color": { "alias": "color"; "required": false; }; "raised": { "alias": "raised"; "required": false; }; "outlined": { "alias": "outlined"; "required": false; }; "elevation": { "alias": "elevation"; "required": false; }; "shadowColor": { "alias": "shadowColor"; "required": false; }; "icon": { "alias": "icon"; "required": false; }; "fontSet": { "alias": "fontSet"; "required": false; }; "fontIcon": { "alias": "fontIcon"; "required": false; }; }, {}, never, never, false, never>; }