698bd5eef1
* Release date -- initial attempt (squashed and rebased) - Use white color for calendar buttons in release date input - Update icon color for release date input - Allow to set time in release date and display it under additional options - Add release date field * Upgrade to latest react-datetime-picker. I believe this also picks up the y18n security fix. * Handle dark theme and general style fixes. * [+redux] Change how release_time is edited. - `releaseTime` is now a number instead of a string, matching `release_time`. It was getting confusing what the variable units were. - `releaseTime` will always match `release_time` for an edit. It will be used in the GUI to reset just the date to the original, instead of having to reset the entire form. - `releaseTimeEdited` will be used by `updatePublishForm` in the GUI to represent the desired new release time. Set to `undefined` if we don't want to change the date. * Add 'Reset|Now|Default' buttons instead of overloading the date-picker's "X" button. Before this, the "X" button resets to the original (previous) publish date for Edits, and resets to current time for New Claims. This is very confusing, so added explicit text-based buttons -- hopefully this is more intuitive. * bump redux to master Co-authored-by: Franco Montenegro <franco.montenegro.ruke@gmail.com> Co-authored-by: Thomas Zarebczan <thomas.zarebczan@gmail.com>
14 lines
504 B
JavaScript
14 lines
504 B
JavaScript
import { connect } from 'react-redux';
|
|
import { doUpdatePublishForm, makeSelectPublishFormValue } from 'lbry-redux';
|
|
import PublishReleaseDate from './view';
|
|
|
|
const select = (state) => ({
|
|
releaseTime: makeSelectPublishFormValue('releaseTime')(state),
|
|
releaseTimeEdited: makeSelectPublishFormValue('releaseTimeEdited')(state),
|
|
});
|
|
|
|
const perform = (dispatch) => ({
|
|
updatePublishForm: (value) => dispatch(doUpdatePublishForm(value)),
|
|
});
|
|
|
|
export default connect(select, perform)(PublishReleaseDate);
|