UNPKG

1.53 kBTypeScriptView Raw
1/**
2 * @license
3 * Copyright Google Inc. All Rights Reserved.
4 *
5 * Use of this source code is governed by an MIT-style license that can be
6 * found in the LICENSE file at https://angular.io/license
7 */
8import { CompileDirectiveMetadata, CompileStylesheetMetadata } from './compile_metadata';
9import { UrlResolver } from './url_resolver';
10import { OutputContext } from './util';
11export declare const HOST_ATTR: string;
12export declare const CONTENT_ATTR: string;
13export declare class StylesCompileDependency {
14 name: string;
15 moduleUrl: string;
16 setValue: (value: any) => void;
17 constructor(name: string, moduleUrl: string, setValue: (value: any) => void);
18}
19export declare class CompiledStylesheet {
20 outputCtx: OutputContext;
21 stylesVar: string;
22 dependencies: StylesCompileDependency[];
23 isShimmed: boolean;
24 meta: CompileStylesheetMetadata;
25 constructor(outputCtx: OutputContext, stylesVar: string, dependencies: StylesCompileDependency[], isShimmed: boolean, meta: CompileStylesheetMetadata);
26}
27export declare class StyleCompiler {
28 private _urlResolver;
29 private _shadowCss;
30 constructor(_urlResolver: UrlResolver);
31 compileComponent(outputCtx: OutputContext, comp: CompileDirectiveMetadata): CompiledStylesheet;
32 compileStyles(outputCtx: OutputContext, comp: CompileDirectiveMetadata, stylesheet: CompileStylesheetMetadata, shim?: boolean): CompiledStylesheet;
33 needsStyleShim(comp: CompileDirectiveMetadata): boolean;
34 private _compileStyles;
35 private _shimIfNeeded;
36}