mirror of
https://github.com/status-im/MyCrypto.git
synced 2025-01-23 17:38:57 +00:00
9cac0298a2
* Manage modal focus * Add isOpen prop to CustomNodeModal * Remove outline overrides * Update outline style for inputs * Fix modal focus management & Cleanup CustomNodeModal * Add aria-label on modal close button * Fix modal scroll to top * Add aria-live property for notifications * Add aria-busy to Spinner component * Fix border styles for generatewallet password inputs * Update token balances inputs * Remove multiple h1's & Update styles * Add alt text to all img elements * Update swap link from bity to shapeshift * Update aria-labels and alt text * Only show keystore password input when required * Revert "Only show keystore password input when required" This reverts commit 7ec5de52da0982cd3131f365b142f6915638d831. * address changes requested
43 lines
1.5 KiB
TypeScript
43 lines
1.5 KiB
TypeScript
import { RestartSwapAction } from 'actions/swap';
|
|
import bityLogo from 'assets/images/logo-bity.svg';
|
|
import shapeshiftLogo from 'assets/images/shapeshift-dark.svg';
|
|
import { shapeshiftReferralURL, bitboxReferralURL } from 'config';
|
|
import React, { PureComponent } from 'react';
|
|
import translate from 'translations';
|
|
import './SwapInfoHeader.scss';
|
|
|
|
export interface SwapInfoHeaderTitleProps {
|
|
provider: string;
|
|
restartSwap(): RestartSwapAction;
|
|
}
|
|
|
|
export default class SwapInfoHeaderTitle extends PureComponent<SwapInfoHeaderTitleProps, {}> {
|
|
public render() {
|
|
const { provider } = this.props;
|
|
const logoToRender = provider === 'shapeshift' ? shapeshiftLogo : bityLogo;
|
|
return (
|
|
<section className="SwapInfo-top row text-center">
|
|
<div className="col-xs-3 text-left">
|
|
<button className="SwapInfo-top-back" onClick={this.props.restartSwap}>
|
|
<i className="fa fa-arrow-left" />
|
|
Start New Swap
|
|
</button>
|
|
</div>
|
|
<div className="col-xs-6">
|
|
<h3 className="SwapInfo-top-title">{translate('SWAP_information')}</h3>
|
|
</div>
|
|
<div className="col-xs-3">
|
|
<a
|
|
className="SwapInfo-top-logo"
|
|
href={provider === 'shapeshift' ? shapeshiftReferralURL : bitboxReferralURL}
|
|
target="_blank"
|
|
rel="noopener noreferrer"
|
|
>
|
|
<img className="SwapInfo-top-logo-img" src={logoToRender} alt={provider + ' logo'} />
|
|
</a>
|
|
</div>
|
|
</section>
|
|
);
|
|
}
|
|
}
|