Browse Source

removed useless `eslint-disable-line react/jsx-no-literals`

master
Thibaut Boustany 7 years ago
parent
commit
dc53e79539
No known key found for this signature in database GPG Key ID: 32475B11A2B13EEC
  1. 2
      src/components/AccountPage/index.js
  2. 4
      src/components/CurrentAddress/index.js
  3. 2
      src/components/DashboardPage/AccountCard.js
  4. 15
      src/components/MainSideBar/index.js
  5. 6
      src/components/Onboarding/steps/GenuineCheck.js
  6. 6
      src/components/Onboarding/steps/SelectPIN/SelectPINblue.js
  7. 8
      src/components/Onboarding/steps/SelectPIN/SelectPINnano.js
  8. 6
      src/components/Onboarding/steps/WriteSeed/WriteSeedBlue.js
  9. 6
      src/components/Onboarding/steps/WriteSeed/WriteSeedNano.js
  10. 8
      src/components/Onboarding/steps/WriteSeed/WriteSeedRestore.js
  11. 2
      src/components/RequestAmount/index.js
  12. 6
      src/components/SettingsPage/index.js
  13. 7
      src/components/base/StepperNumber/index.js
  14. 2
      src/components/modals/AddAccounts/steps/02-step-connect-device.js
  15. 12
      src/components/modals/AddAccounts/steps/03-step-import.js
  16. 2
      src/components/modals/OperationDetails.js

2
src/components/AccountPage/index.js

@ -143,7 +143,7 @@ class AccountPage extends PureComponent<Props, State> {
<BalanceSummary
accounts={[account]}
chartColor={account.currency.color}
chartId={`account-chart-${account.id}`} /* eslint-disable-line react/jsx-no-literals */
chartId={`account-chart-${account.id}`}
counterValue={counterValue}
daysCount={daysCount}
selectedTime={selectedTime}

4
src/components/CurrentAddress/index.js

@ -183,8 +183,8 @@ class CurrentAddress extends PureComponent<Props> {
<Box>
{accountName ? (
<Trans i18nKey="app:currentAddress.for" parent="div">
{/* eslint-disable-line react/jsx-no-literals */}
Address for <strong>{accountName}</strong>
{'Address for '}
<strong>{accountName}</strong>
</Trans>
) : (
t('app:currentAddress.title')

2
src/components/DashboardPage/AccountCard.js

@ -89,7 +89,7 @@ class AccountCard extends PureComponent<{
height={52}
hideAxis
isInteractive={false}
id={`account-chart-${account.id}`} /* eslint-disable-line react/jsx-no-literals */
id={`account-chart-${account.id}`}
unit={account.unit}
/>
</Box>

15
src/components/MainSideBar/index.js

@ -94,10 +94,8 @@ class MainSideBar extends PureComponent<Props> {
icon={IconPieChart}
iconActiveColor="wallet"
onClick={this.handleClickDashboard}
isActive={pathname === '/'} /* eslint-disable-line react/jsx-no-literals */
hasNotif={
updateStatus === 'downloaded' /* eslint-disable-line react/jsx-no-literals */
}
isActive={pathname === '/'}
hasNotif={updateStatus === 'downloaded'}
/>
<SideBarListItem
label={t('app:send.title')}
@ -118,14 +116,14 @@ class MainSideBar extends PureComponent<Props> {
icon={IconManager}
iconActiveColor="wallet"
onClick={this.handleClickManager}
isActive={pathname === '/manager'} /* eslint-disable-line react/jsx-no-literals */
isActive={pathname === '/manager'}
/>
<SideBarListItem
label={t('app:sidebar.exchange')}
icon={IconExchange}
iconActiveColor="wallet"
onClick={this.handleClickExchange}
isActive={pathname === '/exchange'} /* eslint-disable-line react/jsx-no-literals */
isActive={pathname === '/exchange'}
/>
</SideBarList>
<Space of={40} />
@ -139,10 +137,7 @@ class MainSideBar extends PureComponent<Props> {
key={account.id}
account={account}
push={this.push}
isActive={
pathname ===
`/account/${account.id}` /* eslint-disable-line react/jsx-no-literals */
}
isActive={pathname === `/account/${account.id}`}
/>
))}
</SideBarList>

6
src/components/Onboarding/steps/GenuineCheck.js

@ -128,7 +128,7 @@ class GenuineCheck extends PureComponent<StepProps, State> {
<CardWrapper>
<Box justify="center">
<Box horizontal>
<IconOptionRow>1.</IconOptionRow>{/* eslint-disable-line react/jsx-no-literals */}
<IconOptionRow>{'1.'}</IconOptionRow>
<CardTitle>{t('onboarding:genuineCheck.steps.step1.title')}</CardTitle>
</Box>
</Box>
@ -145,7 +145,7 @@ class GenuineCheck extends PureComponent<StepProps, State> {
<CardWrapper isDisabled={!genuine.pinStepPass}>
<Box justify="center">
<Box horizontal>
<IconOptionRow>2.</IconOptionRow>{/* eslint-disable-line react/jsx-no-literals */}
<IconOptionRow>{'2.'}</IconOptionRow>
<CardTitle>{t('onboarding:genuineCheck.steps.step2.title')}</CardTitle>
</Box>
</Box>
@ -162,7 +162,7 @@ class GenuineCheck extends PureComponent<StepProps, State> {
<CardWrapper isDisabled={!genuine.recoveryStepPass}>
<Box justify="center">
<Box horizontal>
<IconOptionRow>3.</IconOptionRow>{/* eslint-disable-line react/jsx-no-literals */}
<IconOptionRow>{'3.'}</IconOptionRow>
<CardTitle>{t('onboarding:genuineCheck.steps.step3.title')}</CardTitle>
</Box>
</Box>

6
src/components/Onboarding/steps/SelectPIN/SelectPINblue.js

@ -23,17 +23,17 @@ class SelectPIN extends PureComponent<Props, *> {
const stepsLedgerBlue = [
{
key: 'step1',
icon: <IconOptionRow>1.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('onboarding:selectPIN.instructions.ledgerBlue.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>2.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: t('onboarding:selectPIN.instructions.ledgerBlue.step2'),
},
{
key: 'step3',
icon: <IconOptionRow>3.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: t('onboarding:selectPIN.instructions.ledgerBlue.step3'),
},
]

8
src/components/Onboarding/steps/SelectPIN/SelectPINnano.js

@ -23,22 +23,22 @@ class SelectPINnano extends PureComponent<Props, *> {
const stepsLedgerNano = [
{
key: 'step1',
icon: <IconOptionRow>1.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('onboarding:selectPIN.instructions.ledgerNano.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>2.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: t('onboarding:selectPIN.instructions.ledgerNano.step2'),
},
{
key: 'step3',
icon: <IconOptionRow>3.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: t('onboarding:selectPIN.instructions.ledgerNano.step3'),
},
{
key: 'step4',
icon: <IconOptionRow>4.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'4.'}</IconOptionRow>,
desc: t('onboarding:selectPIN.instructions.ledgerNano.step4'),
},
]

6
src/components/Onboarding/steps/WriteSeed/WriteSeedBlue.js

@ -29,17 +29,17 @@ class WriteSeedBlue extends PureComponent<Props, *> {
const steps = [
{
key: 'step1',
icon: <IconOptionRow>1.</IconOptionRow>, /* eslint-disable-line react/jsx-no-literals */
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('onboarding:writeSeed.blue.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>2.</IconOptionRow>, /* eslint-disable-line react/jsx-no-literals */
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: t('onboarding:writeSeed.blue.step2'),
},
{
key: 'step3',
icon: <IconOptionRow>3.</IconOptionRow>, /* eslint-disable-line react/jsx-no-literals */
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: t('onboarding:writeSeed.blue.step3'),
},
]

6
src/components/Onboarding/steps/WriteSeed/WriteSeedNano.js

@ -29,17 +29,17 @@ class WriteSeedNano extends PureComponent<Props, *> {
const steps = [
{
key: 'step1',
icon: <IconOptionRow>1.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('onboarding:writeSeed.nano.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>2.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: t('onboarding:writeSeed.nano.step2'),
},
{
key: 'step3',
icon: <IconOptionRow>3.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: t('onboarding:writeSeed.nano.step3'),
},
]

8
src/components/Onboarding/steps/WriteSeed/WriteSeedRestore.js

@ -30,22 +30,22 @@ class WriteSeedRestore extends PureComponent<Props, *> {
const steps = [
{
key: 'step1',
icon: <IconOptionRow>1.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'1.'}</IconOptionRow>,
desc: t('onboarding:writeSeed.restore.step1'),
},
{
key: 'step2',
icon: <IconOptionRow>2.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'2.'}</IconOptionRow>,
desc: t('onboarding:writeSeed.restore.step2'),
},
{
key: 'step3',
icon: <IconOptionRow>3.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'3.'}</IconOptionRow>,
desc: t('onboarding:writeSeed.restore.step3'),
},
{
key: 'step4',
icon: <IconOptionRow>4.</IconOptionRow> /* eslint-disable-line react/jsx-no-literals */,
icon: <IconOptionRow>{'4.'}</IconOptionRow>,
desc: t('onboarding:writeSeed.restore.step4'),
},
]

2
src/components/RequestAmount/index.js

@ -155,7 +155,7 @@ export class RequestAmount extends PureComponent<Props> {
onChange={this.onLeftChange}
renderRight={<InputRight>{account.unit.code}</InputRight>}
/>
<InputCenter>=</InputCenter> {/* eslint-disable-line react/jsx-no-literals */}
<InputCenter>{'='}</InputCenter>
<InputCurrency
containerProps={containerProps}
defaultUnit={rightUnit}

6
src/components/SettingsPage/index.js

@ -121,11 +121,7 @@ class SettingsPage extends PureComponent<Props, State> {
<Pills mb={4} items={this._items} activeKey={tab.key} onChange={this.handleChangeTab} />
<Switch>
{this._items.map(i => (
<Route
key={i.key}
path={`${match.url}/${i.key}`} /* eslint-disable-line react/jsx-no-literals */
render={i.value && i.value(props)}
/>
<Route key={i.key} path={`${match.url}/${i.key}`} render={i.value && i.value(props)} />
))}
<Route render={defaultItem.value && defaultItem.value(props)} />
</Switch>

7
src/components/base/StepperNumber/index.js

@ -140,15 +140,14 @@ class StepperNumber extends PureComponent<Props, State> {
const isMin = this.isMin(value)
const isMax = this.isMax(value)
/* eslint-disable react/jsx-no-literals */
return (
<Container>
<Btn onMouseDown={!isMin ? this.handleMouseDown('decrement') : undefined} disabled={isMin}>
-
<Btn onMouseDown={!isMin ? this.handleMouseDown('decrement') : undefined} disabled={isMin}>
{'-'}
</Btn>
<Num>{value}</Num>
<Btn onMouseDown={!isMax ? this.handleMouseDown('increment') : undefined} disabled={isMax}>
+
{'+'}
</Btn>
</Container>
)

2
src/components/modals/AddAccounts/steps/02-step-connect-device.js

@ -18,7 +18,6 @@ function StepConnectDevice({ t, currency, currentDevice, setState }: StepProps)
<Fragment>
<Box align="center" mb={6}>
<CurrencyCircleIcon mb={3} size={40} currency={currency} />
{/* eslint-disable react/jsx-no-literals */}
<Box ff="Open Sans" fontSize={4} color="dark" textAlign="center" style={{ width: 370 }}>
<Trans i18nKey="app:addAccounts.connectDevice.desc" parent="div">
{`You're about to import your `}
@ -28,7 +27,6 @@ function StepConnectDevice({ t, currency, currentDevice, setState }: StepProps)
{` account(s) from your Ledger device. Please follow the steps below:`}
</Trans>
</Box>
{/* eslint-enable react/jsx-no-literals */}
</Box>
<ConnectDevice
t={t}

12
src/components/modals/AddAccounts/steps/03-step-import.js

@ -160,16 +160,18 @@ class StepImport extends PureComponent<StepProps> {
onUpdateAccount={this.handleUpdateAccount}
onSelectAll={this.handleSelectAll}
onUnselectAll={this.handleUnselectAll}
isLoading={scanStatus === 'scanning'} /* eslint-disable-line react/jsx-no-literals */
isLoading={scanStatus === 'scanning'}
/>
<AccountsList
title={t('app:addAccounts.createNewAccount.title')}
emptyText={t('app:addAccounts.createNewAccount.noOperationOnLastAccount')}
title={t('app:addAccounts.createNewAccount')}
emptyText={
'You cannot create a new account because your last account has no operations'
}
accounts={creatableAccounts}
checkedIds={checkedAccountsIds}
onToggleAccount={this.handleToggleAccount}
onUpdateAccount={this.handleUpdateAccount}
isLoading={scanStatus === 'scanning'} /* eslint-disable-line react/jsx-no-literals */
isLoading={scanStatus === 'scanning'}
/>
</Box>
@ -234,7 +236,7 @@ export const StepImportFooter = ({
return (
<Fragment>
{currency && <CurrencyBadge mr="auto" currency={currency} />}
<Button primary disabled={scanStatus !== 'finished'} onClick={onClick}> {/* eslint-disable-line react/jsx-no-literals */}
<Button primary disabled={scanStatus !== 'finished'} onClick={onClick}>
{ctaWording}
</Button>
</Fragment>

2
src/components/modals/OperationDetails.js

@ -153,7 +153,7 @@ const OperationDetails = connect(mapStateToProps)((props: Props) => {
? t('app:operationDetails.confirmed')
: t('app:operationDetails.notConfirmed')}
</Box>
<Box>{`(${confirmations})`}</Box> {/* eslint-disable-line react/jsx-no-literals */}
<Box>{`(${confirmations})`}</Box>
</ColRight>
</Line>
<B />

Loading…
Cancel
Save