The communications platform that puts data protection first.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
Rocket.Chat/apps/meteor/app/ui-utils/client/lib/MessageAction.ts

33 lines
844 B

import type { Keys as IconName } from '@rocket.chat/icons';
import type { TranslationKey } from '@rocket.chat/ui-contexts';
type MessageActionGroup = 'menu';
export type MessageActionContext =
| 'message'
| 'threads'
| 'message-mobile'
| 'pinned'
| 'direct'
| 'starred'
| 'mentions'
| 'federated'
| 'videoconf'
| 'search'
| 'videoconf-threads';
type MessageActionType = 'communication' | 'interaction' | 'duplication' | 'apps' | 'management';
export type MessageActionConfig = {
id: string;
icon: IconName;
variant?: 'danger' | 'success' | 'warning';
label: TranslationKey;
tooltip?: string;
order: number;
group: MessageActionGroup;
context?: MessageActionContext[];
action: (e: Pick<Event, 'preventDefault' | 'stopPropagation' | 'currentTarget'> | undefined) => any;
type?: MessageActionType;
disabled?: boolean;
};