import React from 'react'; import cn from 'classnames'; import { Button } from 'UI'; import stl from './table.module.css'; export default class Table extends React.PureComponent { state = { showAll: false }; onLoadMoreClick = () => { this.setState({ showAll: true }); } render() { const { cols, rows = [], rowProps, rowClass = '', small = false, compare = false, maxHeight = 200, onRowClick = null, isTemplate, } = this.props; const { showAll } = this.state; const isShowMoreButtonVisible = !isTemplate && rows.size > (small ? 3 : 5) && !showAll return (