1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 | import { AbsoluteSourceSpan, ParseSourceSpan } from '@angular/compiler';
|
10 | import { NgCompiler } from '@angular/compiler-cli/src/ngtsc/core';
|
11 | import { AbsoluteFsPath } from '@angular/compiler-cli/src/ngtsc/file_system';
|
12 | import { DirectiveSymbol, TemplateTypeChecker } from '@angular/compiler-cli/src/ngtsc/typecheck/api';
|
13 | import * as e from '@angular/compiler/src/expression_parser/ast';
|
14 | import * as t from '@angular/compiler/src/render3/r3_ast';
|
15 | import * as ts from 'typescript';
|
16 | export declare function getTextSpanOfNode(node: t.Node | e.AST): ts.TextSpan;
|
17 | export declare function toTextSpan(span: AbsoluteSourceSpan | ParseSourceSpan | e.ParseSpan): ts.TextSpan;
|
18 | interface NodeWithKeyAndValue extends t.Node {
|
19 | keySpan: ParseSourceSpan;
|
20 | valueSpan?: ParseSourceSpan;
|
21 | }
|
22 | export declare function isTemplateNodeWithKeyAndValue(node: t.Node | e.AST): node is NodeWithKeyAndValue;
|
23 | export declare function isWithinKey(position: number, node: NodeWithKeyAndValue): boolean;
|
24 | export declare function isWithinKeyValue(position: number, node: NodeWithKeyAndValue): boolean;
|
25 | export declare function isTemplateNode(node: t.Node | e.AST): node is t.Node;
|
26 | export declare function isExpressionNode(node: t.Node | e.AST): node is e.AST;
|
27 | export interface TemplateInfo {
|
28 | template: t.Node[];
|
29 | component: ts.ClassDeclaration;
|
30 | }
|
31 |
|
32 |
|
33 |
|
34 | export declare function getTemplateInfoAtPosition(fileName: string, position: number, compiler: NgCompiler): TemplateInfo | undefined;
|
35 |
|
36 |
|
37 |
|
38 |
|
39 |
|
40 |
|
41 |
|
42 |
|
43 |
|
44 |
|
45 |
|
46 | export declare function getDirectiveMatchesForElementTag(element: t.Template | t.Element, directives: DirectiveSymbol[]): Set<DirectiveSymbol>;
|
47 | export declare function makeElementSelector(element: t.Element | t.Template): string;
|
48 |
|
49 |
|
50 |
|
51 |
|
52 |
|
53 |
|
54 |
|
55 |
|
56 |
|
57 |
|
58 |
|
59 | export declare function getDirectiveMatchesForAttribute(name: string, hostNode: t.Template | t.Element, directives: DirectiveSymbol[]): Set<DirectiveSymbol>;
|
60 |
|
61 |
|
62 |
|
63 |
|
64 | export declare function filterAliasImports(displayParts: ts.SymbolDisplayPart[]): ts.SymbolDisplayPart[];
|
65 | export declare function isDollarEvent(n: t.Node | e.AST): n is e.PropertyRead;
|
66 |
|
67 |
|
68 |
|
69 |
|
70 | export declare function flatMap<T, R>(items: T[] | readonly T[], f: (item: T) => R[] | readonly R[]): R[];
|
71 | export declare function isTypeScriptFile(fileName: string): boolean;
|
72 | export declare function isExternalTemplate(fileName: string): boolean;
|
73 | export declare function isWithin(position: number, span: AbsoluteSourceSpan | ParseSourceSpan): boolean;
|
74 |
|
75 |
|
76 |
|
77 |
|
78 | export declare function getTemplateLocationFromShimLocation(templateTypeChecker: TemplateTypeChecker, shimPath: AbsoluteFsPath, positionInShimFile: number): {
|
79 | templateUrl: AbsoluteFsPath;
|
80 | span: ParseSourceSpan;
|
81 | } | null;
|
82 | export {};
|