summaryrefslogtreecommitdiff
path: root/client/components/Modal.jsx
blob: 3681ce4ae0e6fd759bef4e811b201729a52c02a0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
import { h, Component } from 'preact'

export default class Modal extends Component {
  constructor(props) {
    super()
  }
  render() {
    const className = this.props.visible ? 'modal visible' : 'modal'
    return (
      <div class={className}>
        <div class='inner'>
          {this.props.children}
        </div>
      </div>
    )
  }
}