import { useState } from 'react' import { FaExchangeAlt, FaMoneyBillWave } from 'react-icons/fa' export default function TransferForm() { const [amount, setAmount] = useState('') const [source, setSource] = useState('Waafi') const [destination, setDestination] = useState('DMoney') const [loading, setLoading] = useState(false) const [error, setError] = useState('') const [success, setSuccess] = useState(false) const handleSubmit = async (e) => { e.preventDefault() setLoading(true) setError('') try { // Simulate API call await new Promise(resolve => setTimeout(resolve, 1500)) setSuccess(true) } catch (err) { setError('Erreur lors du transfert') } finally { setLoading(false) } } const swapServices = () => { const temp = source setSource(destination) setDestination(temp) } return (
) }