import React from 'react'; import { View, Text, Pressable } from 'react-native'; import { useTheme } from '../../utils/ThemeContext'; import SubscriptionButton from './SubscriptionButton'; export type BillingCycle = 'monthly' | 'yearly'; interface BillingToggleProps { billingCycle: BillingCycle; onChange: (cycle: BillingCycle) => void; yearlyDiscount?: string; } export const BillingToggle: React.FC = ({ billingCycle, onChange, yearlyDiscount = '50%', }) => { const { theme } = useTheme(); return ( onChange('monthly')} > Monatlich onChange('yearly')} > Jährlich {yearlyDiscount && ( {yearlyDiscount} Rabatt )} ); }; export default BillingToggle;