mirror of
https://github.com/status-im/MyCrypto.git
synced 2025-02-18 14:07:31 +00:00
* Remove title from account, tighten buttons and subtabs. * Send everything button in input. * Request tx to full width, adjust transaction fee spacing. * Fix token balances button spacing. * Fix address identicon flying offscreen. Tighten up identicon, show border even when theres no identicon. * Add isSelfAddress boolean to AddressField, use it on WalletInfo tab. * Use short amount again. * Unused
35 lines
1.0 KiB
TypeScript
35 lines
1.0 KiB
TypeScript
import React from 'react';
|
|
import { AddressFieldFactory } from './AddressFieldFactory';
|
|
import { donationAddressMap } from 'config';
|
|
import translate from 'translations';
|
|
import { Input } from 'components/ui';
|
|
|
|
interface Props {
|
|
isReadOnly?: boolean;
|
|
isSelfAddress?: boolean;
|
|
}
|
|
|
|
export const AddressField: React.SFC<Props> = ({ isReadOnly, isSelfAddress }) => (
|
|
<AddressFieldFactory
|
|
isSelfAddress={isSelfAddress}
|
|
withProps={({ currentTo, isValid, onChange, readOnly }) => (
|
|
<div className="input-group-wrapper">
|
|
<label className="input-group">
|
|
<div className="input-group-header">
|
|
{translate(isSelfAddress ? 'X_ADDRESS' : 'SEND_ADDR')}
|
|
</div>
|
|
<Input
|
|
className={`input-group-input ${isValid ? '' : 'invalid'}`}
|
|
type="text"
|
|
value={currentTo.raw}
|
|
placeholder={donationAddressMap.ETH}
|
|
readOnly={!!(isReadOnly || readOnly)}
|
|
spellCheck={false}
|
|
onChange={onChange}
|
|
/>
|
|
</label>
|
|
</div>
|
|
)}
|
|
/>
|
|
);
|