+ client: add icons to the whois info

This commit is contained in:
Ildar Kamalov
2019-09-24 15:28:59 +03:00
committed by Simon Zolin
parent fcf37da312
commit ba62d42949
13 changed files with 192 additions and 102 deletions

View File

@@ -6,8 +6,8 @@ import ReactTable from 'react-table';
import { MODAL_TYPE, CLIENT_ID } from '../../../helpers/constants';
import Card from '../../ui/Card';
import Modal from './Modal';
import WrapCell from './WrapCell';
import WhoisCell from './WhoisCell';
import wrapCell from './wrapCell';
import whoisCell from './whoisCell';
class ClientsTable extends Component {
handleFormAdd = (values) => {
@@ -103,7 +103,7 @@ class ClientsTable extends Component {
Header: this.props.t('table_name'),
accessor: 'name',
minWidth: 120,
Cell: WrapCell,
Cell: wrapCell,
},
{
Header: this.props.t('settings'),
@@ -138,11 +138,17 @@ class ClientsTable extends Component {
return (
<div className="logs__row logs__row--icons">
{value && value.length > 0 ? value.map(service => (
<svg className="service__icon service__icon--table" title={service} key={service}>
<use xlinkHref={`#service_${service}`} />
</svg>
)) : ''}
{value && value.length > 0
? value.map(service => (
<svg
className="service__icon service__icon--table"
title={service}
key={service}
>
<use xlinkHref={`#service_${service}`} />
</svg>
))
: ''}
</div>
);
},
@@ -151,7 +157,7 @@ class ClientsTable extends Component {
Header: this.props.t('whois'),
accessor: 'whois_info',
minWidth: 200,
Cell: WhoisCell,
Cell: whoisCell(this.props.t),
},
{
Header: this.props.t('requests_count'),