summaryrefslogtreecommitdiff
path: root/app/client/modules/biggan/views/biggan.new.js
blob: ca28b92f8d00696007fc6fc8e28bc764286f7b70 (plain)
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
import { h, Component } from 'preact'
import { bindActionCreators } from 'redux'
import { connect } from 'react-redux'
import { Link } from 'react-router-dom'
import util from '../../../util'

import { Views } from '../../../common'

import * as bigganActions from '../biggan.actions'
import bigganModule from '../biggan.module'

function BigGANNew(props){
  return (
    <Views.New
      db={props.biggan}
      path='/biggan/datasets/'
      actions={props.actions}
      module={bigganModule}
      history={props.history}
    />
  )
}

const mapStateToProps = state => ({
  biggan: state.module.biggan,
})

const mapDispatchToProps = (dispatch, ownProps) => ({
  actions: bindActionCreators(bigganActions, dispatch),
})

export default connect(mapStateToProps, mapDispatchToProps)(BigGANNew)