import React from 'react';
import { StyleSheet, View } from 'react-native';
import { Switch } from 'react-native-elements';
import { COLORS } from '../common';
function StyleSwitch(_a) {
    var checked = _a.checked, setChecked = _a.setChecked, scale = _a.scale, disabled = _a.disabled, containerStyle = _a.containerStyle, switchStyle = _a.switchStyle;
    var scaleStyle = scale !== 1 ? { transform: [{ scaleX: scale }, { scaleY: scale }] } : {};
    return (<View style={[styles.container, containerStyle || {}]}>
      <Switch value={checked} onValueChange={setChecked} style={[scaleStyle, switchStyle || {}]} color={COLORS.PRIMARY6} thumbColor={COLORS.GRAY0} trackColor={disabled
            ? { true: COLORS.GRAY2, false: COLORS.GRAY2 }
            : { true: COLORS.PRIMARY6, false: COLORS.GRAY4 }} ios_backgroundColor={disabled ? COLORS.GRAY2 : COLORS.GRAY4} hitSlop={{ top: 10, bottom: 10, right: 10, left: 10 }} disabled={disabled}/>
    </View>);
}
var styles = StyleSheet.create({
    container: {
        flexDirection: 'row',
        justifyContent: 'center',
        alignItems: 'center',
    },
});
StyleSwitch.defaultProps = {
    checked: false,
    scale: 1,
    disabled: false,
};
export default StyleSwitch;
//# sourceMappingURL=StyleSwitch.js.map