You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
trezor-wallet/src/js/containers/TopNavigationContainer.js

31 lines
1.1 KiB

/* @flow */
'use strict';
import React, { Component, PropTypes } from 'react';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import { withRouter } from 'react-router-dom';
import TopNavigation from '../components/TopNavigation';
import * as TrezorConnectActions from '../actions/TrezorConnectActions';
import { resizeAppContainer, toggleDeviceDropdown } from '../actions/AppActions';
function mapStateToProps(state, own) {
return {
connect: state.connect
};
}
function mapDispatchToProps(dispatch) {
return {
toggleDeviceDropdown: bindActionCreators(toggleDeviceDropdown, dispatch),
resizeAppContainer: bindActionCreators(resizeAppContainer, dispatch),
acquireDevice: bindActionCreators(TrezorConnectActions.acquire, dispatch),
onSelectDevice: bindActionCreators(TrezorConnectActions.onSelectDevice, dispatch),
};
}
// export default connect(mapStateToProps, mapDispatchToProps)(TopNavigation);
export default withRouter(
connect(mapStateToProps, mapDispatchToProps)(TopNavigation)
);