joyent-portal/ui/src/components/table-simple-table/table-body.js

26 lines
492 B
JavaScript
Raw Normal View History

import { clearfix, Baseline } from '../../shared/composers';
import styled from 'styled-components';
import React from 'react';
2017-01-19 16:59:59 +02:00
const StyledTableBody = styled.article`
box-shadow: 0 2px 0 0 rgba(0, 0, 0, 0.05);
${clearfix}
`;
const TableBody = ({
children,
...props
}) => children.length <= 1 ? null : (
<StyledTableBody {...props}>
{children}
</StyledTableBody>
);
2017-01-19 16:59:59 +02:00
TableBody.propTypes = {
children: React.PropTypes.node
};
export default Baseline(
2017-02-15 03:19:26 +02:00
StyledTableBody
);