import { DataNode, SceneNode } from './compositor';
import * as CSS from 'csstype';
type LayoutProps = Partial<DataNode['props']>;
type Size = {
    x: string | number;
    y: string | number;
};
type Position = {
    x: string | number;
    y: string | number;
};
type Duration = string | number;
type Transition = {
    delay?: Duration;
    offset?: Position;
    scale?: {
        x?: number;
        y?: number;
    };
    opacity?: number;
    timingFn?: CSS.StandardProperties['transitionTimingFunction'] | 'exit';
};
export type LayoutChild = HTMLElement & {
    data: ChildPosition;
};
export type LayoutArgs = {
    props: LayoutProps;
    children: SceneNode[];
    size: {
        x: number;
        y: number;
    };
};
export type ChildPosition = {
    position: Position;
    size: Size;
    opacity: number;
    borderRadius: number;
    zIndex: number;
    entryTransition: Transition;
    exitTransition: Transition;
    rootOffset?: {
        x: number;
        y: number;
    };
};
export type ChildPositionIndex = {
    [nodeId: string]: ChildPosition;
};
export type LayoutResult = ChildPositionIndex | HTMLElement;
export type LayoutDefinition = ({ props, children, size, }: LayoutArgs) => LayoutResult;
export type LayoutMap = {
    [name: string]: LayoutDeclaration;
};
export type LayoutName = 'Grid' | 'Free' | 'Column' | 'Row' | 'Presentation' | 'Layered' | string;
export type LayoutDeclaration = {
    name: LayoutName;
    props?: any;
    layout: LayoutDefinition;
};
export type LayoutRegister = (declaration: LayoutDeclaration | LayoutDeclaration[]) => void;
export {};
