mirror of
https://github.com/Kong/insomnia
synced 2024-11-08 14:49:53 +00:00
b198e6170b
* Removed some unnecessary rendering * Only PureComponents and some other stuff * Removed all functional components * Only deal with nunjucks marks * Remove ref assign functions in modals * Lots of tweaks * A bit snappier * A bit snappier
22 lines
479 B
JavaScript
22 lines
479 B
JavaScript
import React, {PureComponent, PropTypes} from 'react';
|
|
import classnames from 'classnames';
|
|
|
|
class ModalBody extends PureComponent {
|
|
render () {
|
|
const {className, children, noScroll, ...props} = this.props;
|
|
return (
|
|
<div className={classnames('modal__body', {
|
|
'modal__body--no-scroll': noScroll
|
|
}, className)} {...props}>
|
|
{children}
|
|
</div>
|
|
);
|
|
}
|
|
}
|
|
|
|
ModalBody.propTypes = {
|
|
noScroll: PropTypes.bool
|
|
};
|
|
|
|
export default ModalBody;
|