Browse Source
Don't display QR code on recipient field in Send modal
master
meriadec
7 years ago
No known key found for this signature in database
GPG Key ID: 1D2FC2305E2CB399
2 changed files with
16 additions and
20 deletions
-
src/components/RecipientAddress/index.js
-
src/components/modals/Send/fields/RecipientField.js
|
|
@ -85,27 +85,23 @@ class RecipientAddress extends PureComponent<Props, State> { |
|
|
|
const { onChange, withQrCode, value, ...rest } = this.props |
|
|
|
const { qrReaderOpened } = this.state |
|
|
|
|
|
|
|
const renderRight = withQrCode ? ( |
|
|
|
<Right onClick={this.handleClickQrCode}> |
|
|
|
<IconQrCode size={16} /> |
|
|
|
{qrReaderOpened && ( |
|
|
|
<Fragment> |
|
|
|
<BackgroundLayer /> |
|
|
|
<WrapperQrCode> |
|
|
|
<QRCodeCameraPickerCanvas onPick={this.handleOnPick} /> |
|
|
|
</WrapperQrCode> |
|
|
|
</Fragment> |
|
|
|
)} |
|
|
|
</Right> |
|
|
|
) : null |
|
|
|
|
|
|
|
return ( |
|
|
|
<Box relative justifyContent="center"> |
|
|
|
<Input |
|
|
|
{...rest} |
|
|
|
value={value} |
|
|
|
withQrCode={withQrCode} |
|
|
|
onChange={onChange} |
|
|
|
renderRight={ |
|
|
|
<Right onClick={this.handleClickQrCode}> |
|
|
|
<IconQrCode size={16} /> |
|
|
|
{qrReaderOpened && ( |
|
|
|
<Fragment> |
|
|
|
<BackgroundLayer /> |
|
|
|
<WrapperQrCode> |
|
|
|
<QRCodeCameraPickerCanvas onPick={this.handleOnPick} /> |
|
|
|
</WrapperQrCode> |
|
|
|
</Fragment> |
|
|
|
)} |
|
|
|
</Right> |
|
|
|
} |
|
|
|
/> |
|
|
|
<Input {...rest} value={value} onChange={onChange} renderRight={renderRight} /> |
|
|
|
</Box> |
|
|
|
) |
|
|
|
} |
|
|
|
|
|
@ -81,7 +81,7 @@ class RecipientField<Transaction> extends Component<Props<Transaction>, { isVali |
|
|
|
/> |
|
|
|
<RecipientAddress |
|
|
|
autoFocus={autoFocus} |
|
|
|
withQrCode |
|
|
|
withQrCode={false} |
|
|
|
error={ |
|
|
|
!value || isValid |
|
|
|
? null |
|
|
|