bigbuffet-rw/app/soapbox/components/column.js

28 lines
529 B
JavaScript
Raw Normal View History

2020-03-27 13:59:38 -07:00
import React from 'react';
import PropTypes from 'prop-types';
2021-10-05 20:01:16 -07:00
import classNames from 'classnames';
2020-03-27 13:59:38 -07:00
export default class Column extends React.PureComponent {
static propTypes = {
2021-10-05 20:01:16 -07:00
className: PropTypes.string,
2020-03-27 13:59:38 -07:00
children: PropTypes.node,
label: PropTypes.string,
};
render() {
2021-10-05 20:01:16 -07:00
const { className, label, children } = this.props;
2020-03-27 13:59:38 -07:00
return (
2021-10-05 20:01:16 -07:00
<div
role='region'
aria-label={label}
className={classNames('column', className)}
>
2020-03-27 13:59:38 -07:00
{children}
</div>
);
}
}