2019-08-31 04:07:25 +05:00
|
|
|
import { connect } from 'react-redux';
|
|
|
|
|
2021-06-24 01:05:22 +05:00
|
|
|
import { currentModalSelector } from '../selectors';
|
|
|
|
import ModalTypes from '../constants/ModalTypes';
|
2019-08-31 04:07:25 +05:00
|
|
|
import Project from '../components/Project';
|
|
|
|
|
2020-03-25 00:15:47 +05:00
|
|
|
const mapStateToProps = (state) => {
|
2021-06-24 01:05:22 +05:00
|
|
|
const currentModal = currentModalSelector(state);
|
2019-08-31 04:07:25 +05:00
|
|
|
|
|
|
|
return {
|
2021-06-24 01:05:22 +05:00
|
|
|
isSettingsModalOpened: currentModal === ModalTypes.PROJECT_SETTINGS,
|
2019-08-31 04:07:25 +05:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2021-06-24 01:05:22 +05:00
|
|
|
export default connect(mapStateToProps)(Project);
|