Add dialog to card payment
This commit is contained in:
@@ -27,14 +27,9 @@ export default function Soutyen({prices, paymentStatus}) {
|
||||
const [success, setSuccess] = useState(null)
|
||||
const [error, setError] = useState(null)
|
||||
const [open, setOpen] = useState(false)
|
||||
const [payementIsReady, setPaymentIsReady] = useState(false)
|
||||
const [isLoading, setIsLoading] = useState(false)
|
||||
const [clientEmail, setClientEmail] = useState('')
|
||||
|
||||
const scrollToBottom = () => {
|
||||
scrollEvent.current?.scrollIntoView({behavior: 'smooth', block: 'end', inline: 'nearest'})
|
||||
}
|
||||
|
||||
useEffect(() => {
|
||||
const getClientSecret = async () => {
|
||||
try {
|
||||
@@ -118,18 +113,6 @@ export default function Soutyen({prices, paymentStatus}) {
|
||||
|
||||
useEffect(() => {}, [router.query.payment_intent])
|
||||
|
||||
useEffect(() => {
|
||||
if (validMontant) {
|
||||
scrollToBottom()
|
||||
}
|
||||
}, [validMontant])
|
||||
|
||||
useEffect(() => {
|
||||
if (payementIsReady) {
|
||||
scrollToBottom()
|
||||
}
|
||||
}, [payementIsReady])
|
||||
|
||||
return (
|
||||
<HeadLayout
|
||||
title='Soutenir Organisation KA Internationale !'
|
||||
@@ -162,7 +145,6 @@ export default function Soutyen({prices, paymentStatus}) {
|
||||
setClientSecret={setClientSecret}
|
||||
setPaymentIntent={setPaymentIntent}
|
||||
setIsLoading={setIsLoading}
|
||||
setPaymentIsReady={setPaymentIsReady}
|
||||
error={error}
|
||||
setError={setError}
|
||||
clientEmail={clientEmail}
|
||||
|
||||
Reference in New Issue
Block a user