import { useColor } from '@/hooks/useColor'; import React from 'react'; import { Text } from '@/components/ui/text'; import { View } from '@/components/ui/view'; import { Switch as RNSwitch, SwitchProps as RNSwitchProps, TextStyle, } from 'react-native'; interface SwitchProps extends RNSwitchProps { label?: string; error?: string; labelStyle?: TextStyle; } export function Switch({ label, error, labelStyle, ...props }: SwitchProps) { const mutedColor = useColor('muted'); const primary = useColor('primary'); const danger = useColor('red'); return ( {label && ( {label} )} {error && ( {error} )} ); }