import React from 'react'
import { Link } from 'react-router'
+import {withNamespaces} from 'react-i18next'
class ListItem extends React.Component {
constructor(props) {
}
render() {
- const item = this.props.item
- const lang = this.props.lang
+ const {item, t} = this.props
return(
<tr>
<td>{item.alias}</td>
<td><code>{item.xpub}</code></td>
<td><Link to={`/keys/${item.id}`}>
- {lang === 'zh' ? '更多' : 'More'}
+ {t('form.more')}
</Link></td>
</tr>
)
}
}
-export default ListItem
+export default withNamespaces('translations') (ListItem)