Composer: Remove preselectDate

This value is only used to track when a reply happens. On soapbox-fe, a reply causes a new ComposeForm to mount, so we can track it that way instead.
stable/1.0.x
Alex Gleason 2020-05-26 17:36:56 -05:00
rodzic 188067ac48
commit e06f8ce894
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 7211D1F99744FBB7
3 zmienionych plików z 0 dodań i 4 usunięć

Wyświetl plik

@ -51,7 +51,6 @@ class ComposeForm extends ImmutablePureComponent {
spoilerText: PropTypes.string,
focusDate: PropTypes.instanceOf(Date),
caretPosition: PropTypes.number,
preselectDate: PropTypes.instanceOf(Date),
isSubmitting: PropTypes.bool,
isChangingUpload: PropTypes.bool,
isUploading: PropTypes.bool,

Wyświetl plik

@ -19,7 +19,6 @@ const mapStateToProps = state => ({
privacy: state.getIn(['compose', 'privacy']),
focusDate: state.getIn(['compose', 'focusDate']),
caretPosition: state.getIn(['compose', 'caretPosition']),
preselectDate: state.getIn(['compose', 'preselectDate']),
isSubmitting: state.getIn(['compose', 'is_submitting']),
isChangingUpload: state.getIn(['compose', 'is_changing_upload']),
isUploading: state.getIn(['compose', 'is_uploading']),

Wyświetl plik

@ -54,7 +54,6 @@ const initialState = ImmutableMap({
text: '',
focusDate: null,
caretPosition: null,
preselectDate: null,
in_reply_to: null,
is_composing: false,
is_submitting: false,
@ -247,7 +246,6 @@ export default function compose(state = initialState, action) {
map.set('privacy', privacyPreference(action.status.get('visibility'), state.get('default_privacy')));
map.set('focusDate', new Date());
map.set('caretPosition', null);
map.set('preselectDate', new Date());
map.set('idempotencyKey', uuid());
if (action.status.get('spoiler_text').length > 0) {