import React from 'react';
import { Switch, Text, View } from 'react-native';
import PropTypes from 'prop-types';
import { SWITCH_TRACK_COLOR, themes } from '../../constants/colors';
import styles from './styles';
const SwitchContainer = React.memo(
({
children,
value,
disabled,
onValueChange,
leftLabelPrimary,
leftLabelSecondary,
rightLabelPrimary,
rightLabelSecondary,
theme,
testID,
labelContainerStyle,
leftLabelStyle
}) => (
<>
{leftLabelPrimary && (
{leftLabelPrimary}
{leftLabelSecondary}
)}
{rightLabelPrimary && (
{rightLabelPrimary}
{rightLabelSecondary}
)}
{children}
>
)
);
SwitchContainer.propTypes = {
value: PropTypes.bool,
disabled: PropTypes.bool,
leftLabelPrimary: PropTypes.string,
leftLabelSecondary: PropTypes.string,
rightLabelPrimary: PropTypes.string,
rightLabelSecondary: PropTypes.string,
onValueChange: PropTypes.func,
theme: PropTypes.string,
testID: PropTypes.string,
labelContainerStyle: PropTypes.object,
leftLabelStyle: PropTypes.object,
children: PropTypes.any
};
export default SwitchContainer;