Profile editing: Uploading avatar and header images (#38189)

This commit is contained in:
Echo authored and GitHub committed 2026-03-16 11:39:52 +00:00
1 parent 9c8be1e721
commit 21c27eb3af
14 files changed
+647 -39

No files matched your search

@@ -8,6 +8,7 @@ import {
setComposeQuotePolicy,
pasteLinkCompose,
cancelPasteLinkCompose,
setDragUploadEnabled,
} from '@/mastodon/actions/compose_typed';
import { timelineDelete } from 'mastodon/actions/timelines_typed';
@@ -75,6 +76,7 @@ const initialState = ImmutableMap({
is_submitting: false,
is_changing_upload: false,
is_uploading: false,
isDragDisabled: false,
should_redirect_to_compose_page: false,
progress: 0,
isUploadingThumbnail: false,
@@ -132,6 +134,7 @@ function clearAll(state) {
map.set('idempotencyKey', uuid());
map.set('quoted_status_id', null);
map.set('quote_policy', state.get('default_quote_policy'));
map.set('isDragDisabled', false);
});
}
@@ -359,6 +362,8 @@ export const composeReducer = (state = initialState, action) => {
return action.meta.requestId === state.get('fetching_link') ? state.set('fetching_link', null) : state;
} else if (cancelPasteLinkCompose.match(action)) {
return state.set('fetching_link', null);
} else if (setDragUploadEnabled.match(action)) {
return state.set('isDragDisabled', !action.payload);
}
switch(action.type) {