You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

23 lines
571 B

import React from 'react'
import PropTypes from 'prop-types'
import path from 'path'
import { FaBitcoin } from 'react-icons/lib/fa'
import Isvg from 'react-inlinesvg'
const CryptoIcon = ({ currency, styles }) => {
switch (currency) {
case 'btc':
return <FaBitcoin style={styles} />
case 'ltc':
return <Isvg style={styles} src={path.join(__dirname, '..', 'resources/litecoin.svg')} />
default:
return <span />
}
}
CryptoIcon.propTypes = {
currency: PropTypes.string.isRequired,
styles: PropTypes.object
}
export default CryptoIcon