mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-10-24 12:23:39 +02:00
25 lines
518 B
JavaScript
25 lines
518 B
JavaScript
|
import React, { PureComponent } from 'react'
|
||
|
import PropTypes from 'prop-types'
|
||
|
|
||
|
export default class CurrencyDisplay extends PureComponent {
|
||
|
static propTypes = {
|
||
|
className: PropTypes.string,
|
||
|
displayValue: PropTypes.string,
|
||
|
prefix: PropTypes.string,
|
||
|
}
|
||
|
|
||
|
render () {
|
||
|
const { className, displayValue, prefix } = this.props
|
||
|
const text = `${prefix || ''}${displayValue}`
|
||
|
|
||
|
return (
|
||
|
<div
|
||
|
className={className}
|
||
|
title={text}
|
||
|
>
|
||
|
{ text }
|
||
|
</div>
|
||
|
)
|
||
|
}
|
||
|
}
|