fix(donate): adjust verbiage and time contibuted
This commit is contained in:
@ -96,8 +96,12 @@ class DonateForm extends Component {
|
||||
: this.amounts[durationSelected][0];
|
||||
}
|
||||
|
||||
convertToTimeContributed(amount) {
|
||||
return `${numToCommas((amount / 100) * 50 * 60)} minutes`;
|
||||
convertToTimeContributed(amount, duration) {
|
||||
const timeContributed =
|
||||
duration === 'month'
|
||||
? Math.round(((amount / 100) * 50) / 12)
|
||||
: (amount / 100) * 50;
|
||||
return `${numToCommas(timeContributed)} hours`;
|
||||
}
|
||||
|
||||
getFormatedAmountLabel(amount) {
|
||||
@ -183,10 +187,9 @@ class DonateForm extends Component {
|
||||
{`Your `}
|
||||
{this.getFormatedAmountLabel(donationAmount)}
|
||||
{` donation will provide `}
|
||||
{this.convertToTimeContributed(donationAmount)}
|
||||
{` of learning to people around the world `}
|
||||
{duration === 'one-time' ? `for one ` : `each `}
|
||||
{duration === 'monthly' ? `month.` : `year.`}
|
||||
{this.convertToTimeContributed(donationAmount, duration)}
|
||||
{` of learning to people around the world`}
|
||||
{duration === 'onetime' ? `.` : ` each ${duration}.`}
|
||||
</p>
|
||||
</div>
|
||||
</Tab>
|
||||
|
@ -7,7 +7,7 @@ const DonateText = () => {
|
||||
<Col sm={10} smOffset={1} xs={12}>
|
||||
<p>freeCodeCamp is a highly efficient education nonprofit.</p>
|
||||
<p>
|
||||
In 2019 alone, we provided 1,100,000,000 minutes of free education to
|
||||
In 2019 alone, we provided 18 million hours of free education to
|
||||
people around the world.
|
||||
</p>
|
||||
<p>
|
||||
|
Reference in New Issue
Block a user