import * as React from "react";
import {TouchableHighlight, View} from "react-native";
import {IProps} from "./base";
import basic from "../../basicPage";


const CompositeBase: React.FC<IProps> = (props) => {
    const children = <View style={{flex: 1}}>{props.children}</View>
    if (props.isContent) return children;
    return <TouchableHighlight style={{flex: 1}} activeOpacity={1} onPress={() => basic.inputBlur()}>
        {children}
    </TouchableHighlight>
}

export default CompositeBase
