blob: 87e2c6513eb6b157d1865984f84e3764a3d023d6 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
import classnames from 'classnames';
import { observer } from 'mobx-react';
import React, { Component } from 'react';
import injectStyle from 'react-jss';
import { IWithStyle } from '../typings/generic';
import styles from './styles';
interface IProps extends IWithStyle {
children: React.ReactNode;
className?: string;
}
@observer
class WrapperComponent extends Component<IProps> {
render() {
const {
children,
classes,
className,
} = this.props;
return (
<div className={classnames({
[`${classes.container}`]: true,
[`${className}`]: className,
})}>
{children}
</div>
);
}
}
export const Wrapper = injectStyle(styles)(WrapperComponent);
|