UNPKG

elmer-ui-core

Version:

web app framework

88 lines (87 loc) 4 kB
export declare type TypeAnimationProperty = { left?: number | string; top?: number | string; width?: number | string; height?: number | string; margin?: number | string; marginLeft?: number | string; marginTop?: number | string; marginRight?: number | string; marginBottom?: number | string; paddingLeft?: number | string; paddingTop?: number | string; paddingRight?: number | string; paddingBottom?: number | string; padding?: number | string; borderWidth?: number | string; borderLeftWidth?: number | string; borderTopWidth?: number | string; borderRightWidth?: number | string; borderBottomWidth?: number | string; borderColor?: string; borderLeftColor?: string; borderTopColor?: string; borderRightColor?: string; borderBottomColor?: string; backgroundColor?: string; color?: string; fontSize?: string; opacity?: number; transformTranslate?: number | string; transformTranslate3d?: number | string; transformTranslateX?: number | string; transformTranslateY?: number | string; transformTranslateZ?: number | string; transformScale?: number | string; transformScale3d?: number | string; transformScaleX?: number | string; transformScaleY?: number | string; transformScaleZ?: number | string; transformRotate?: number | string; transformRotate3d?: number | string; transformRotateX?: number | string; transformRotateY?: number | string; transformRotateZ?: number | string; transformSkew?: number | string; transformSkewX?: number | string; transformSkewY?: number | string; }; declare type TypeAnimationTransformPropertyKeys = "transformTranslate" | "transformTranslate3d" | "transformTranslateX" | "transformTranslateY" | "transformTranslateZ" | "transformScalc" | "transformScalc3d" | "transformScalcX" | "transformScalcY" | "transformScalcZ" | "transformRotate" | "transformRotate3d" | "transformRotateX" | "transformRotateY" | "transformRotateZ" | "transformSkew" | "transformSkewX" | "transformSkewY"; export declare type TypeAnimationCssRule = { [P in Exclude<keyof TypeAnimationProperty, TypeAnimationTransformPropertyKeys>]: TypeAnimationProperty[P]; } & { transform?: string; webkitTransform?: string; mozTransform?: string; msTransform?: string; oTransform?: string; }; export declare type TypeAnimationContext = { cssKey?: string; unit?: string; value1Unit?: string; value2Unit?: string; value3Unit?: string; value4Unit?: string; value1?: number | string | number[] | string[]; value2?: number | string | number[] | string[]; value3?: number | string | number[] | string[]; value4?: number | string | number[] | string[]; }; export declare type TypeAnimationPropertyData = { [P in keyof TypeAnimationProperty]: TypeAnimationContext; }; export declare const isCssEmpty: (cssValue: any) => boolean; export declare const calcPropertyData: (resultData: any, key: any, value: string | number) => void; export declare const calcPropertyConfigData: (configData: TypeAnimationProperty) => TypeAnimationPropertyData; export declare const readWillChangeCssDefaultData: (dom: HTMLElement, from: TypeAnimationProperty, to: TypeAnimationProperty) => TypeAnimationPropertyData; export declare const convertAnimationDataToCssProperty: (animationData: TypeAnimationPropertyData) => TypeAnimationCssRule; declare const _default: { converAnimationProperty: (animationData: TypeAnimationPropertyData) => TypeAnimationCssRule; converOption: (configData: TypeAnimationProperty) => TypeAnimationPropertyData; gradient: (startColor: string, endColor: string, step: any) => any[]; hexToRgb: (hex: string) => number[]; readWillChangeCssDefaultData: (dom: HTMLElement, from: TypeAnimationProperty, to: TypeAnimationProperty) => TypeAnimationPropertyData; rgbToHex: (r: number, g: number, b: number) => string; }; export default _default;