import { ComponentRef, IterableDiffer, KeyValueDiffer, Type } from '@angular/core';
import { Component } from './component';
export interface ClassComponentType
{
new (props: P): Component;
}
export declare type FunctionComponentType
= (props: P) => NodeDef;
export interface ElementDef
{
type: string | ClassComponentType
| FunctionComponentType
| Type;
children: ChildDef[];
props: P | null;
}
export declare type TextDef = string | number;
export declare type VoidDef = boolean | null | undefined;
export declare type NodeDef = ElementDef | TextDef | VoidDef;
export declare type ChildDef = NodeDef | NodeDef[];
export declare type Key = string | number;
export interface Attributes {
key?: Key;
}
export interface ClassAttributes {
ref?: unknown;
}
export declare const ANGULAR_INPUT_MAP = 0;
export declare const ANGULAR_OUTPUT_MAP = 1;
export declare const CHILD_ANCHOR = 2;
export declare const CHILD_DIFFER = 3;
export declare const COMPONENT_INSTANCE = 4;
export declare const COMPONENT_REF = 5;
export declare const PROP_DIFFER = 6;
export declare const RENDER_RESULT = 7;
export interface VNodeMeta extends Array {
[ANGULAR_INPUT_MAP]?: {
[key: string]: string;
};
[ANGULAR_OUTPUT_MAP]?: {
[key: string]: string;
};
[CHILD_ANCHOR]?: Node;
[CHILD_DIFFER]?: IterableDiffer;
[COMPONENT_INSTANCE]?: Component;
[COMPONENT_REF]?: ComponentRef;
[PROP_DIFFER]?: KeyValueDiffer;
[RENDER_RESULT]?: VNode;
}
export interface VNode {
type: string | ClassComponentType
| FunctionComponentType
| null;
children: VNode[] | null;
key: Key | null;
props: P;
flags: number;
native: Node | null;
meta: VNodeMeta | null;
}
export interface Properties {
[name: string]: unknown;
}
export interface Styles {
[name: string]: string;
}
export declare type StateChange = Partial | ((s: S, p: P) => S);
export declare type ChildDiffer = IterableDiffer;