summaryrefslogtreecommitdiff
path: root/app/client/common/player.component.js
blob: 6045db160a504a2fd2d8b6181ec6f04790b711fe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import { h, Component } from 'preact'
import { connect } from 'react-redux'

function Player(props) {
  let className = props.fullscreen ? 'player fullscreen' : 'player'
  if (props.square) {
    className += ' square'
  }
  return (
    <div className={className}>
      <canvas width={props.width} height={props.height} />
    </div>
  )
}

const mapStateToProps = state => ({
})

const mapDispatchToProps = (dispatch, ownProps) => ({
})

export default connect(mapStateToProps, mapDispatchToProps)(Player)