Skip to content

Commit

Permalink
fix(FormattedMessages) id fixes batch 2
Browse files Browse the repository at this point in the history
  • Loading branch information
TheLeoB committed May 23, 2018
1 parent ef6241e commit 2dee353
Show file tree
Hide file tree
Showing 9 changed files with 36 additions and 36 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ class ExchangeCheckout extends React.PureComponent {
<Form onSubmit={onSubmit}>
<LabelWrapper>
<Label>
<FormattedMessage id='scenes.buysell.exchangecheckout.enter_amount' defaultMessage='Enter Amount:' />
<FormattedMessage id='scenes.buysell.exchangecheckout.enteramount' defaultMessage='Enter Amount:' />
</Label>
{ rate && !minError &&
<Rate>
Expand All @@ -123,7 +123,7 @@ class ExchangeCheckout extends React.PureComponent {
minError &&
<Rate>
<Text size='12px' color={'error'} weight={300} >
<FormattedMessage id='scenes.buysell.exchangecheckout.synced' defaultMessage='Please enter an amount greater than {min} {curr}.' values={{ min: limits.min, curr: this.props.fiatLimits ? fiat : crypto }} />
<FormattedMessage id='scenes.buysell.exchangecheckout.enteramount.details' defaultMessage='Please enter an amount greater than {min} {curr}.' values={{ min: limits.min, curr: this.props.fiatLimits ? fiat : crypto }} />
</Text>
</Rate>
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ const OrderCheckout = ({ quoteR, account, onFetchQuote, reason, finishAccountSet
const disableInputs = limits.max < limits.min || (reason.indexOf('has_remaining') < 0 && reason) || limits.effectiveMax < limits.min

const wantToHelper = () => type === 'buy'
? <FormattedMessage id='buy.output_method.title.buy' defaultMessage='I want to buy' />
: <FormattedMessage id='buy.output_method.title.sell' defaultMessage='I want to sell' />
? <FormattedMessage id='buy.sfoxcheckout.outputmethod.title.buy' defaultMessage='I want to buy' />
: <FormattedMessage id='buy.sfoxcheckout.title.sell' defaultMessage='I want to sell' />
const payWithHelper = () => type === 'buy'
? <FormattedMessage id='buy.input_method.title.buy_with' defaultMessage='I will pay with' />
: <FormattedMessage id='buy.output_method.title.sell_with' defaultMessage='I will receive funds into' />
? <FormattedMessage id='buy.sfoxcheckout.inputmethod.title.buywith' defaultMessage='I will pay with' />
: <FormattedMessage id='buy.sfoxcheckout.outputmethod.title.sellwith' defaultMessage='I will receive funds into' />

const limitsHelper = (quoteR, limits) => {
if (quoteR.error) return true
Expand All @@ -36,7 +36,7 @@ const OrderCheckout = ({ quoteR, account, onFetchQuote, reason, finishAccountSet
const submitButtonHelper = () => (
reason.indexOf('has_remaining') > -1
? <StepTransition next Component={Button} style={spacing('mt-45')} nature='primary' fullwidth disabled={!Remote.Success.is(quoteR) || limitsHelper(quoteR, limits)}>
<FormattedMessage id='review_order' defaultMessage='Review Order' />
<FormattedMessage id='buy.sfoxcheckout.revieworder' defaultMessage='Review Order' />
</StepTransition>
: <div style={{ ...flex('col'), ...spacing('mt-15') }}>
<Text size='14px' weight={300}>
Expand All @@ -63,7 +63,7 @@ const OrderCheckout = ({ quoteR, account, onFetchQuote, reason, finishAccountSet
.map((quote) => '$' + quote.rate)
.getOrElse(
<Fragment>
<FormattedMessage id='loading' defaultMessage='Loading' />
<FormattedMessage id='buy.sfoxcheckout.loading' defaultMessage='Loading' />
{'...'}
</Fragment>
)}
Expand All @@ -81,7 +81,7 @@ const OrderCheckout = ({ quoteR, account, onFetchQuote, reason, finishAccountSet
reason.indexOf('has_remaining') > -1
? <Fragment>
<Text style={spacing('ml-10')} size='16px' weight={600}>
<FormattedMessage id='amount' defaultMessage='Amount' />
<FormattedMessage id='buy.sfoxcheckout.amount' defaultMessage='Amount' />
</Text>
<div style={spacing('mt-10')}>
<QuoteInput
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,21 +42,21 @@ const renderDetailsRow = (id, message, value, color) => (
export const OrderDetails = ({ quoteR, account, onRefreshQuote, type }) => (
<ExchangeCheckoutWrapper>
<Text size='32px' weight={600} style={spacing('mb-10')}>
<FormattedMessage id='buy.almost_there' defaultMessage="You're almost there" />
<FormattedMessage id='buy.sfoxcheckout.almostthere' defaultMessage="You're almost there" />
</Text>
<Text size='14px' weight={300} style={spacing('mb-20')}>
<FormattedMessage id='buy.review_order_subtext' defaultMessage='Before we can start processing your order, review the order details below. If everything looks good to you, click submit to complete your order.' />
<FormattedMessage id='buy.sfoxcheckout.revieworder.subtext' defaultMessage='Before we can start processing your order, review the order details below. If everything looks good to you, click submit to complete your order.' />
</Text>
<Text size='14px' weight={300} style={spacing('mt-20')}>
<FormattedMessage id='buy.connected_account' defaultMessage='Your Connected Account' />:
<FormattedMessage id='buy.sfoxcheckout.connectedaccount' defaultMessage='Your Connected Account' />:
</Text>
<MethodContainer style={spacing('mt-10')}>
<Icon style={spacing('ml-15')} name='bank-filled' size='26px' />
<FundingSource account={account} />
</MethodContainer>
<div style={{ ...flex('row align/center justify/end'), ...spacing('mt-20') }}>
<Text size='12px' weight={500} style={spacing('mr-10')}>
<FormattedMessage id='exchange_rate' defaultMessage='Exchange Rate' />
<FormattedMessage id='buy.sfoxcheckout.exchangerate' defaultMessage='Exchange Rate' />
</Text>
<Text size='12px' weight={300}>
1 BTC = {quoteR.map((quote) => `$${quote.rate}`).getOrElse('~')}
Expand Down Expand Up @@ -109,27 +109,27 @@ export const OrderSubmit = ({ quoteR, onSubmit, busy, clearTradeError }) => (
{
busy
? <HeartbeatLoader height='20px' width='20px' color='white' />
: <FormattedMessage id='submit' defaultMessage='Submit' />
: <FormattedMessage id='buysell.sfoxcheckout.orderreview.submit' defaultMessage='Submit' />
}
</Button>
<CancelWrapper style={{ ...flex('row justify/center'), ...spacing('mt-15') }}>
<StepTransition prev Component={Link}>
<FormattedMessage id='cancel' defaultMessage='Cancel' />
<FormattedMessage id='buysell.sfoxcheckout.orderreview.cancel' defaultMessage='Cancel' />
</StepTransition>
</CancelWrapper>
</Fragment>
}
<StyledFaqRow
title={<FormattedMessage id='faq.how_long_to_receive_q' defaultMessage='How long does it take to get my funds?' />}
description={<FormattedMessage id='faq.how_long_to_receive_a' defaultMessage='A bitcoin is never late, nor is it early. A bitcoin arrives precisely when it intends to.' />}
title={<FormattedMessage id='buysell.sfoxcheckout.orderreview.faq.howlongtoreceive.question' defaultMessage='How long does it take to get my funds?' />}
description={<FormattedMessage id='buysell.sfoxcheckout.orderreview.faq.howlongtoreceive.answer' defaultMessage='A bitcoin is never late, nor is it early. A bitcoin arrives precisely when it intends to.' />}
/>
<StyledFaqRow
title={<FormattedMessage id='faq.exchange_rate_q' defaultMessage='What is the exchange rate?' />}
description={<FormattedMessage id='faq.exchange_rate_a' defaultMessage='The exchange rate varies from minute to minute.' />}
title={<FormattedMessage id='buysell.sfoxcheckout.orderreview.faq.exchangerate.question' defaultMessage='What is the exchange rate?' />}
description={<FormattedMessage id='buysell.sfoxcheckout.orderreview.faq.exchangerate.answer' defaultMessage='The exchange rate varies from minute to minute.' />}
/>
<StyledFaqRow
title={<FormattedMessage id='faq.exchange_fees_q' defaultMessage='What are the fees?' />}
description={<FormattedMessage id='faq.exchange_fees_a' defaultMessage='Each exchange takes a small percentage of the total amount as a fee.' />}
title={<FormattedMessage id='buysell.sfoxcheckout.orderreview.faq.exchangefees.question' defaultMessage='What are the fees?' />}
description={<FormattedMessage id='buysell.sfoxcheckout.orderreview.faq.exchangefees.answer' defaultMessage='Each exchange takes a small percentage of the total amount as a fee.' />}
/>
</Fragment>
)
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ import React from 'react'
import { FormattedMessage } from 'react-intl'

export const TermsAndConditionsMessage = () =>
<FormattedMessage id='modals.exchange.agreetermsandconditions' defaultMessage='You must agree to the terms and conditions' />
<FormattedMessage id='modals.exchange.shapeshift.agreetermsandconditions' defaultMessage='You must agree to the terms and conditions' />
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ const Success = props => {
<Wrapper>
<Header>
<Text size='13px' weight={500} capitalize>
{status === 'complete' && <FormattedMessage id='modals.exchange.shapeshift.title_success' defaultMessage='Success! Your exchange is complete' />}
{status !== 'complete' && <FormattedMessage id='modals.exchange.shapeshift.title_inprogress' defaultMessage='Exchange In Progress' />}
{status === 'complete' && <FormattedMessage id='modals.exchange.shapeshift.title.success' defaultMessage='Success! Your exchange is complete' />}
{status !== 'complete' && <FormattedMessage id='modals.exchange.shapeshift.title.inprogress' defaultMessage='Exchange In Progress' />}
</Text>
</Header>
<Body>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const TradeItem = props => {
</TableCell>
<TableCell width='15%'>
<Link size='14px' weight={300} capitalize onClick={handleClick}>
<FormattedMessage id='scenes.exchangehistory.list.tradeitem' defaultMessage='View details' />
<FormattedMessage id='scenes.exchangehistory.list.tradeitem.viewdetails' defaultMessage='View details' />
</Link>
</TableCell>
<TableCell width='30%'>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,23 +33,23 @@ const List = props => {
<TableHeader >
<TableCell width='15%'>
<Text size='13px' weight={500} capitalize>
<FormattedMessage id='scenes.exchangehistory.list.status' defaultMessage='Status' />
<FormattedMessage id='scenes.exchangehistory.list.incomplete.status' defaultMessage='Status' />
</Text>
</TableCell>
<TableCell width='15%' />
<TableCell width='30%'>
<Text size='13px' weight={500} capitalize>
<FormattedMessage id='scenes.exchangehistory.list.date' defaultMessage='Date' />
<FormattedMessage id='scenes.exchangehistory.list.incomplete.date' defaultMessage='Date' />
</Text>
</TableCell>
<TableCell width='20%'>
<Text size='13px' weight={500} capitalize>
<FormattedMessage id='scenes.exchangehistory.list.exchanged' defaultMessage='Exchanged' />
<FormattedMessage id='scenes.exchangehistory.list.incomplete.xchanged' defaultMessage='Exchanged' />
</Text>
</TableCell>
<TableCell width='20%'>
<Text size='13px' weight={500} capitalize>
<FormattedMessage id='scenes.exchangehistory.list.received' defaultMessage='To Be Received' />
<FormattedMessage id='scenes.exchangehistory.list.incomplete.received' defaultMessage='To Be Received' />
</Text>
</TableCell>
</TableHeader>
Expand All @@ -60,29 +60,29 @@ const List = props => {
{showComplete &&
<Container>
<Text style={spacing('mb-15')} size='16px' weight={500} capitalize>
<FormattedMessage padding-bottom='10px' id='scenes.exchangehistory.list.exchanges' defaultMessage='Completed Exchanges' />
<FormattedMessage padding-bottom='10px' id='scenes.exchangehistory.list.complete.exchanges' defaultMessage='Completed Exchanges' />
</Text>
<Table>
<TableHeader>
<TableCell width='15%'>
<Text size='13px' weight={500} capitalize>
<FormattedMessage id='scenes.exchangehistory.list.status' defaultMessage='Status' />
<FormattedMessage id='scenes.exchangehistory.list.complete.status' defaultMessage='Status' />
</Text>
</TableCell>
<TableCell width='15%' />
<TableCell width='30%'>
<Text size='13px' weight={500} capitalize>
<FormattedMessage id='scenes.exchangehistory.list.date' defaultMessage='Date' />
<FormattedMessage id='scenes.exchangehistory.list.complete.date' defaultMessage='Date' />
</Text>
</TableCell>
<TableCell width='20%'>
<Text size='13px' weight={500} capitalize>
<FormattedMessage id='scenes.exchangehistory.list.exchanged' defaultMessage='Exchanged' />
<FormattedMessage id='scenes.exchangehistory.list.complete.xchanged' defaultMessage='Exchanged' />
</Text>
</TableCell>
<TableCell width='20%'>
<Text size='13px' weight={500} capitalize>
<FormattedMessage id='scenes.exchangehistory.list.received' defaultMessage='Received' />
<FormattedMessage id='scenes.exchangehistory.list.complete.received' defaultMessage='Received' />
</Text>
</TableCell>
</TableHeader>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const Actions = props => (
<Wrapper>
{ props.error === 'invalid_link' &&
<Text size='18px' weight={300} color='white'>
<FormattedMessage id='scenes.actions.invalid_link' defaultMessage='The link provided is invalid.' />
<FormattedMessage id='scenes.actions.goals.invalidlink' defaultMessage='The link provided is invalid.' />
</Text>
}
</Wrapper>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ const Help = (props) => {
<FormattedMessage id='scenes.help.2fa' defaultMessage="I've lost my 2FA Device" />
</Text>
<Text size='13px' weight={300}>
<FormattedMessage id='scenes.help.2fa_explain' defaultMessage='Reset two factor authentication to regain access to your wallet' />
<FormattedMessage id='scenes.help.2fa.explain' defaultMessage='Reset two factor authentication to regain access to your wallet' />
</Text>
</Left>
<Right>
Expand Down

0 comments on commit 2dee353

Please sign in to comment.