style(compiler): reformat of codebase with new clang-format version (#36520)
This commit reformats the packages/compiler tree using the new version of clang-format. PR Close #36520
This commit is contained in:
@ -14,12 +14,16 @@
|
||||
|
||||
import {CssSelector} from './selector';
|
||||
|
||||
export interface Inject { token: any; }
|
||||
export interface Inject {
|
||||
token: any;
|
||||
}
|
||||
export const createInject = makeMetadataFactory<Inject>('Inject', (token: any) => ({token}));
|
||||
export const createInjectionToken = makeMetadataFactory<object>(
|
||||
'InjectionToken', (desc: string) => ({_desc: desc, ɵprov: undefined}));
|
||||
|
||||
export interface Attribute { attributeName?: string; }
|
||||
export interface Attribute {
|
||||
attributeName?: string;
|
||||
}
|
||||
export const createAttribute =
|
||||
makeMetadataFactory<Attribute>('Attribute', (attributeName?: string) => ({attributeName}));
|
||||
|
||||
@ -37,14 +41,17 @@ export const createContentChildren = makeMetadataFactory<Query>(
|
||||
(selector?: any, data: any = {}) =>
|
||||
({selector, first: false, isViewQuery: false, descendants: false, ...data}));
|
||||
export const createContentChild = makeMetadataFactory<Query>(
|
||||
'ContentChild', (selector?: any, data: any = {}) =>
|
||||
({selector, first: true, isViewQuery: false, descendants: true, ...data}));
|
||||
'ContentChild',
|
||||
(selector?: any, data: any = {}) =>
|
||||
({selector, first: true, isViewQuery: false, descendants: true, ...data}));
|
||||
export const createViewChildren = makeMetadataFactory<Query>(
|
||||
'ViewChildren', (selector?: any, data: any = {}) =>
|
||||
({selector, first: false, isViewQuery: true, descendants: true, ...data}));
|
||||
'ViewChildren',
|
||||
(selector?: any, data: any = {}) =>
|
||||
({selector, first: false, isViewQuery: true, descendants: true, ...data}));
|
||||
export const createViewChild = makeMetadataFactory<Query>(
|
||||
'ViewChild', (selector: any, data: any) =>
|
||||
({selector, first: true, isViewQuery: true, descendants: true, ...data}));
|
||||
'ViewChild',
|
||||
(selector: any, data: any) =>
|
||||
({selector, first: true, isViewQuery: true, descendants: true, ...data}));
|
||||
|
||||
export interface Directive {
|
||||
selector?: string;
|
||||
@ -94,15 +101,21 @@ export interface Pipe {
|
||||
}
|
||||
export const createPipe = makeMetadataFactory<Pipe>('Pipe', (p: Pipe) => ({pure: true, ...p}));
|
||||
|
||||
export interface Input { bindingPropertyName?: string; }
|
||||
export interface Input {
|
||||
bindingPropertyName?: string;
|
||||
}
|
||||
export const createInput =
|
||||
makeMetadataFactory<Input>('Input', (bindingPropertyName?: string) => ({bindingPropertyName}));
|
||||
|
||||
export interface Output { bindingPropertyName?: string; }
|
||||
export interface Output {
|
||||
bindingPropertyName?: string;
|
||||
}
|
||||
export const createOutput = makeMetadataFactory<Output>(
|
||||
'Output', (bindingPropertyName?: string) => ({bindingPropertyName}));
|
||||
|
||||
export interface HostBinding { hostPropertyName?: string; }
|
||||
export interface HostBinding {
|
||||
hostPropertyName?: string;
|
||||
}
|
||||
export const createHostBinding = makeMetadataFactory<HostBinding>(
|
||||
'HostBinding', (hostPropertyName?: string) => ({hostPropertyName}));
|
||||
|
||||
@ -140,7 +153,9 @@ export interface Injectable {
|
||||
}
|
||||
export const createInjectable =
|
||||
makeMetadataFactory('Injectable', (injectable: Injectable = {}) => injectable);
|
||||
export interface SchemaMetadata { name: string; }
|
||||
export interface SchemaMetadata {
|
||||
name: string;
|
||||
}
|
||||
|
||||
export const CUSTOM_ELEMENTS_SCHEMA: SchemaMetadata = {
|
||||
name: 'custom-elements'
|
||||
@ -155,7 +170,9 @@ export const createSelf = makeMetadataFactory('Self');
|
||||
export const createSkipSelf = makeMetadataFactory('SkipSelf');
|
||||
export const createHost = makeMetadataFactory('Host');
|
||||
|
||||
export interface Type extends Function { new (...args: any[]): any; }
|
||||
export interface Type extends Function {
|
||||
new(...args: any[]): any;
|
||||
}
|
||||
export const Type = Function;
|
||||
|
||||
export enum SecurityContext {
|
||||
@ -240,7 +257,10 @@ export const enum InjectFlags {
|
||||
Optional = 1 << 3,
|
||||
}
|
||||
|
||||
export const enum ArgumentType {Inline = 0, Dynamic = 1}
|
||||
export const enum ArgumentType {
|
||||
Inline = 0,
|
||||
Dynamic = 1
|
||||
}
|
||||
|
||||
export const enum BindingFlags {
|
||||
TypeElementAttribute = 1 << 0,
|
||||
@ -255,7 +275,10 @@ export const enum BindingFlags {
|
||||
Types = TypeElementAttribute | TypeElementClass | TypeElementStyle | TypeProperty
|
||||
}
|
||||
|
||||
export const enum QueryBindingType {First = 0, All = 1}
|
||||
export const enum QueryBindingType {
|
||||
First = 0,
|
||||
All = 1
|
||||
}
|
||||
|
||||
export const enum QueryValueType {
|
||||
ElementRef = 0,
|
||||
@ -324,7 +347,7 @@ export const enum SelectorFlags {
|
||||
|
||||
// These are a copy the CSS types from core/src/render3/interfaces/projection.ts
|
||||
// They are duplicated here as they cannot be directly referenced from core.
|
||||
export type R3CssSelector = (string | SelectorFlags)[];
|
||||
export type R3CssSelector = (string|SelectorFlags)[];
|
||||
export type R3CssSelectorList = R3CssSelector[];
|
||||
|
||||
function parserSelectorToSimpleSelector(selector: CssSelector): R3CssSelector {
|
||||
@ -363,7 +386,7 @@ function parserSelectorToR3Selector(selector: CssSelector): R3CssSelector {
|
||||
return positive.concat(...negative);
|
||||
}
|
||||
|
||||
export function parseSelectorToR3Selector(selector: string | null): R3CssSelectorList {
|
||||
export function parseSelectorToR3Selector(selector: string|null): R3CssSelectorList {
|
||||
return selector ? CssSelector.parse(selector).map(parserSelectorToR3Selector) : [];
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user