mattermost-mobile/app/constants/events.ts
Felipe Martin 9793383832
feat: support fillewillbedownloaded and sendtoastmessage pluginapi (#9416)
* Handle FileWillBeDownloaded plugin hook rejections

- Add WebSocket handler for file_download_rejected events
- Show rejected files as file cards instead of broken thumbnails
- Display plugin rejection message in snackbar
- Store rejection reason in EphemeralStore for later retrieval
- Re-render file components when rejection events arrive
- Remove blurred preview to prevent visual blink on rejection

* chore: lint

* chore: lint and test

* fix: removed event from useEffect
2026-02-16 17:10:25 +01:00

45 lines
1.3 KiB
TypeScript

// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import keyMirror from '@utils/key_mirror';
export default keyMirror({
ACCOUNT_SELECT_TABLET_VIEW: null,
CHANNEL_ARCHIVED: null,
CHANNEL_SWITCH: null,
CLOSE_BOTTOM_SHEET: null,
CLOSE_GALLERY: null,
CONFIG_CHANGED: null,
LICENSE_CHANGED: null,
FREEZE_SCREEN: null,
GALLERY_ACTIONS: null,
LEAVE_CHANNEL: null,
LEAVE_TEAM: null,
LOADING_CHANNEL_POSTS: null,
NOTIFICATION_ERROR: null,
REMOVE_USER_FROM_CHANNEL: null,
MANAGE_USER_CHANGE_ROLE: null,
SERVER_LOGOUT: null,
SERVER_VERSION_CHANGED: null,
SESSION_EXPIRED: null,
TAB_BAR_VISIBLE: null,
TEAM_LOAD_ERROR: null,
TEAM_SWITCH: null,
USER_TYPING: null,
USER_STOP_TYPING: null,
POST_LIST_SCROLL_TO_BOTTOM: null,
SWIPEABLE: null,
ITEM_IN_VIEWPORT: null,
SEND_TO_POST_DRAFT: null,
CRT_TOGGLED: null,
JOIN_CALL_BAR_VISIBLE: null,
DRAFT_SWIPEABLE: null,
ACTIVE_SCREEN: null,
ACTIVE_SERVER_CHANGED: null,
FILE_ADD_REMOVED: null,
POST_DELETED_FOR_CHANNEL: null,
KEYBOARD_STATE_CHANGED: null,
CLOSE_INPUT_ACCESSORY_VIEW: null,
EMOJI_PICKER_SEARCH_FOCUSED: null,
FILE_REJECTED: null,
});