export type Unit = 'px' | 'em' | 'rem' | '%' | 'vh' | 'vw';
export type ConstLength = 'auto' | 'min-content' | 'max-content' | 'fit-content';
export type ConstCursor = 'auto' | 'default' | 'none' | 'context-menu' | 'help' | 'pointer' | 'progress' | 'wait' | 'cell' | 'crosshair' | 'text' | 'vertical-text' | 'alias' | 'copy' | 'move' | 'no-drop' | 'not-allowed' | 'e-resize' | 'n-resize' | 'ne-resize' | 'nw-resize' | 's-resize' | 'se-resize' | 'sw-resize' | 'w-resize' | 'ew-resize' | 'ns-resize' | 'nesw-resize' | 'nwse-resize' | 'col-resize' | 'row-resize' | 'all-scroll' | 'zoom-in' | 'zoom-out' | 'grab' | 'grabbing';
export interface CursorImg {
    type: 'img';
    src: string;
}
export interface LengthDefine<T extends Unit = Unit> {
    value: number;
    unit: T;
}
export type Direction = 'left' | 'top' | 'bottom' | 'right' | 'center';
export type DirectionSelect<T> = [T?, T?, T?, T?];
export type AxiosSelect<T> = [T?, T?];
export type Color = string;
export interface LinearGradient {
    angle?: number;
    width?: LengthDefine;
    colorList: {
        color: Color;
        position: number;
    }[];
}
export type ConstShape = {
    type: 'closest-corner' | 'closest-side' | 'farthest-corner' | 'farthest-side';
};
export type CircleShape = {
    type: 'circle';
    r?: LengthDefine;
};
export type EllipseShape = {
    type: 'ellipse';
    xr?: LengthDefine;
    yr?: LengthDefine;
};
export type RadialGradientShape = ConstShape | CircleShape | EllipseShape;
export type RadialGradientPosition = AxiosSelect<Direction> | AxiosSelect<LengthDefine<Exclude<Unit, '%'>>>;
export interface RadialGradient {
    shape?: RadialGradientShape;
    position?: RadialGradientPosition;
    width?: LengthDefine;
    colorList: {
        color: Color;
        position: number;
    }[];
}
export type BGImgDefine = {
    src?: string;
    size?: 'auto' | 'cover' | 'contain' | AxiosSelect<LengthDefine>;
    position?: AxiosSelect<Direction> | AxiosSelect<LengthDefine>;
    repeat?: AxiosSelect<'stretch' | 'repeat' | 'space' | 'round' | 'no-repeat'>;
    attachment?: 'scroll' | 'fixed' | 'local';
};
export type BgColor = {
    type: 'color';
    value: Color;
};
export type BGImage = {
    type: 'img';
    value: BGImgDefine;
} | {
    type: 'linearGradient';
    value: LinearGradient;
} | {
    type: 'radialGradient';
    value: RadialGradient;
};
export type BackgroundDefine = BGImage[] | [...BGImage[], BgColor];
export interface BoxShadow {
    isInset?: boolean;
    offsetX?: LengthDefine;
    offsetY?: LengthDefine;
    blurRadius?: LengthDefine;
    spreadRadius?: LengthDefine;
    color?: Color;
}
export type SpaceDefine = LengthDefine | ConstLength;
export type DisplayDefine = '' | 'flex' | 'inline-flex' | 'inline-grid' | 'grid';
export type FlexDirectionDefine = 'row' | 'column';
export type AlignItemsDefine = 'start' | 'center' | 'end' | 'stretch';
export type JustifyContentDefine = 'start' | 'center' | 'end' | 'stretch' | 'space-around' | 'space-between';
export type GridAutoFlowDefine = 'row' | 'column' | 'row dense' | 'column dense';
export type BorderLineStyle = 'dashed' | 'solid' | 'dotted' | 'double';
export interface BorderDefine {
    width?: LengthDefine;
    lineStyle?: BorderLineStyle;
    color?: Color;
}
export type UndefinedNumber = number | undefined;
export type Number3D = [UndefinedNumber, UndefinedNumber, UndefinedNumber];
export interface Rotate3D {
    type: 'rotate3D';
    value: Tuple4<UndefinedNumber>;
}
export interface Translate3D {
    type: 'translate3D';
    value: Number3D;
}
export interface Scale3D {
    type: 'scale3D';
    value: Number3D;
}
export type TransformDefine = Rotate3D | Translate3D | Scale3D;
type Tuple4<TItem> = [TItem, ...TItem[]] & {
    length: 4;
};
export type Matrix4D = Tuple4<Tuple4<number>>;
export interface TransitionDefine {
    property: 'all' | 'width' | 'height' | 'margin' | 'padding' | 'border-radius' | 'color' | 'background' | 'transform';
    duration?: number;
    function?: 'linear' | 'ease' | 'ease-in' | 'ease-in-out';
}
export interface StyleDefine {
    display?: DisplayDefine;
    flexDirection?: FlexDirectionDefine;
    alignItems?: AlignItemsDefine;
    justifyContent?: JustifyContentDefine;
    gridAutoFlow?: GridAutoFlowDefine;
    gridTemplate?: AxiosSelect<SpaceDefine[]>;
    gridGap?: AxiosSelect<LengthDefine>;
    width?: SpaceDefine;
    maxWidth?: SpaceDefine;
    minWidth?: SpaceDefine;
    height?: SpaceDefine;
    maxHeight?: SpaceDefine;
    minHeight?: SpaceDefine;
    margin?: DirectionSelect<LengthDefine>;
    padding?: DirectionSelect<LengthDefine>;
    borderWidth?: DirectionSelect<LengthDefine>;
    borderStyle?: DirectionSelect<BorderLineStyle>;
    borderColor?: DirectionSelect<Color>;
    outline?: BorderDefine;
    borderRadius?: DirectionSelect<LengthDefine>;
    color?: Color;
    background?: BackgroundDefine;
    fontSize?: LengthDefine;
    fontWeight?: 'normal' | 'bold';
    fontStyle?: 'normal' | 'italic';
    boxSizing?: 'content-box' | 'border-box';
    boxShadow?: BoxShadow[];
    cursor?: ConstCursor | CursorImg;
    overflow?: AxiosSelect<'unset' | 'hidden' | 'visible' | 'auto' | 'scroll'>;
    transform?: TransformDefine[];
    transition?: TransitionDefine[];
}
export interface FieldRenderProps<T> {
    label: string;
    value?: T;
    disabled?: boolean;
    style?: StyleDefine;
    onChange?: (value?: T) => void;
}
export interface StyleRenderConfig {
    groupLabelMap: Record<string, string>;
    fieldRender: {
        [key in keyof StyleDefine]: {
            groupKey: string;
            label: string;
            Render: (props: FieldRenderProps<StyleDefine[key]>) => React.ReactNode;
        };
    };
}
export type StyleExpression = {
    type: 'style_express';
    styleVarId?: string;
};
export declare namespace StyleVar {
    type Type = 'length' | 'space' | 'color' | 'linearGradient' | 'radialGradient' | 'boxShadow' | 'transform';
    interface Base<T extends Type, V> {
        type: T;
        alias?: string;
        value?: V;
        disabled?: boolean;
    }
    interface Length extends Base<'length', LengthDefine> {
    }
    interface Space extends Base<'space', SpaceDefine> {
    }
    interface ColorVar extends Base<'color', Color> {
    }
    interface LinearGradientVar extends Base<'linearGradient', LinearGradient> {
    }
    interface RadialGradientVar extends Base<'radialGradient', RadialGradient> {
    }
    interface BoxShadowVar extends Base<'boxShadow', BoxShadow[]> {
    }
    interface Transform extends Base<'transform', TransformDefine[]> {
    }
    type Desc = Length | Space | ColorVar | LinearGradientVar | RadialGradientVar | BoxShadowVar | Transform;
}
export interface StyleVarGroup {
    active?: boolean;
    disabled?: boolean;
    id: string;
    alias: string;
    vars: Record<string, StyleVar.Desc>;
}
export interface ClassName {
    alias?: string;
    disabled?: boolean;
    hoverValue?: StyleDefine;
    value?: StyleDefine;
}
export {};
