Commit 2524c1ce authored by Aral Balkan's avatar Aral Balkan

Fix custom donation amount value; fix button font size

parent 8aa47106
......@@ -285,7 +285,7 @@ input[name="donationAmount"]:checked + label
@media only screen and (min-width: 380px) {
#donateButton
{
font-size: 21px;
font-size: 20px;
}
}
......
......@@ -8,6 +8,8 @@
html {
color: black;
background-color: white;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Cantarell, Ubuntu,
Helvetica, Arial, sans-serif
}
</style>
<link rel='stylesheet' href='css/index.css'>
......
......@@ -55,8 +55,7 @@ function getDonationAmount () {
// If the person has not chosen a donation amount, check if they entered a custom amount.
if (selectedDonationAmount == 0)
{
selectedDonationAmount = Number(document.getElementById('otherDonationAmount').value) * 100
console.log('Donation amount: ' + selectedDonationAmount)
selectedDonationAmount = Number(document.getElementById('otherDonationAmount').value)
}
return selectedDonationAmount
......@@ -82,13 +81,9 @@ document.getElementById('donateButton').addEventListener('click', function(e) {
// Get the details we need for the server call.
var selectedDonationType = document.querySelector('input[name="donationType"]:checked').value
console.log("Selected donation type: " + selectedDonationType)
var isDonationRecurring = (selectedDonationType == 'monthly')
var donationAmount = getDonationAmount()
console.log("Donation amount >>>> " + donationAmount)
console.log(`Is donation recurring? ${isDonationRecurring}`)
const stripeRedirect = isDonationRecurring ? stripe.redirectToCheckout({
//
// Patronage.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment