2021-05-15 06:10:28 +02:00
|
|
|
import { connect } from 'react-redux';
|
2022-06-29 14:34:32 +02:00
|
|
|
import * as SETTINGS from 'constants/settings';
|
2021-10-17 10:36:14 +02:00
|
|
|
import { makeSelectPublishFormValue } from 'redux/selectors/publish';
|
|
|
|
import { doUpdatePublishForm } from 'redux/actions/publish';
|
2022-06-29 14:34:32 +02:00
|
|
|
import { selectClientSetting } from 'redux/selectors/settings';
|
2021-05-15 06:10:28 +02:00
|
|
|
import PublishReleaseDate from './view';
|
|
|
|
|
|
|
|
const select = (state) => ({
|
|
|
|
releaseTime: makeSelectPublishFormValue('releaseTime')(state),
|
|
|
|
releaseTimeEdited: makeSelectPublishFormValue('releaseTimeEdited')(state),
|
2022-06-23 13:27:08 +02:00
|
|
|
releaseTimeError: makeSelectPublishFormValue('releaseTimeError')(state),
|
2022-06-29 14:34:32 +02:00
|
|
|
clock24h: selectClientSetting(state, SETTINGS.CLOCK_24H),
|
2021-05-15 06:10:28 +02:00
|
|
|
});
|
|
|
|
|
|
|
|
const perform = (dispatch) => ({
|
|
|
|
updatePublishForm: (value) => dispatch(doUpdatePublishForm(value)),
|
|
|
|
});
|
|
|
|
|
|
|
|
export default connect(select, perform)(PublishReleaseDate);
|