export declare const isObject: (item: any) => boolean; export declare const deepMerge: (target: any, ...sources: any[]) => any; /** * @desc 解析上下左右值 * * @param {Array} values - 上右下左值 * @param {String} key - 样式key,如margin、padding等 */ export declare const parseToStyle: (values: number[], key: string) => { [key: string]: number; }; /** * @desc 解析上下左右值 * * @param {Array} values - 上右下左值 * @param {String} key - 样式key,如margin、padding等 */ export declare const parseToCss: (values: number[], key: string) => any[]; /** * @desc 从 theme 中取需要的 `theme` 值, * * @param {Object} props - props,必须包含theme * @param {String} key - theme key * @param {String | Number} defaultValue - 默认主题值 * * @example * * 优先级: (以Slider为例) * getTheme(props, 'slider.thumbTintColor', '#fff'); * * props.thumbTintColor -> * props.theme.slider.thumbTintColor -> * props.theme.slider[props.theme.slider.type].thumbTintColor -> * props.theme.slider[props.theme.type].thumbTintColor * * ```javascript * const StyledView = styled(View)` * background-color: ${props => getTheme(props, 'slider.thumbTintColor', defaultTheme.slider.light.thumbTintColor)}; * `; * ``` * * ```javascript * const defaultTheme = { * type: 'light', * slider: { * type: 'dark', * light: { * thumbTintColor: '#fff', * }, * dark: { * thumbTintColor: '#333', * // thumbTintColor: props => props.disabled ? '#999' : '#fff', * } * } * } * ``` */ export declare const getTheme: (props: { [key: string]: any; }, key: string, defaultValue?: string | number) => any; export declare const createGetTheme: (namespace: string) => (key: string, defaultValue: string | number) => string | number; export declare const getValueFormObject: (namespace: string, object: Record) => string | number | null; declare type styleType = Record & Record[]; export declare const getPropsFromStyle: (namespace: string, style: styleType) => string | number | void; export {};