communication-react-19
Version:
React library for building modern communication user experiences utilizing Azure Communication Services (React 19 compatible fork)
47 lines • 2.79 kB
TypeScript
/// <reference types="react" />
import { ChatMessage, MessageAttachedStatus } from '../../types/ChatMessage';
import { BlockedMessage } from '../../types/ChatMessage';
import { InlineImageOptions } from '../ChatMessage/ChatMessageContent';
import { MessageThreadStrings } from '../MessageThread';
import { MentionDisplayOptions } from '../MentionPopover';
import { AttachmentMenuAction } from '../../types/Attachment';
import { AttachmentMetadata } from "../../../../acs-ui-common/src";
import { ComponentLocale } from '../../localization/LocalizationProvider';
import { Theme } from '@fluentui/react';
/** @private
* Return the string value for the FluentUI message attached prop based on the message's attached status.
* @param attached - The message's attached status.
*/
export declare const getFluentUIAttachedValue: (messageAttachedStatus?: MessageAttachedStatus) => 'bottom' | 'top' | 'center' | undefined;
/**
* @private
* Get the message bubble content for the message.
*/
export declare function getMessageBubbleContent(message: ChatMessage | /* @conditional-compile-remove(data-loss-prevention) */ BlockedMessage, strings: MessageThreadStrings, userId: string, inlineImageOptions: InlineImageOptions | undefined, mentionDisplayOptions?: MentionDisplayOptions,
/**
* Optional callback to render message attachments in the message component.
*/
onRenderAttachmentDownloads?: (message: ChatMessage) => JSX.Element,
/**
* Optional callback to define custom actions for attachments.
*/
actionsForAttachment?: (attachment: AttachmentMetadata, message?: ChatMessage) => AttachmentMenuAction[]): JSX.Element;
/** @private */
export declare const generateDefaultTimestamp: (createdOn: Date, showDate: boolean | undefined, strings: MessageThreadStrings) => string;
/** @private */
export declare const generateCustomizedTimestamp: (createdOn: Date, locale: ComponentLocale, onDisplayDateTimeString?: (messageDate: Date) => string) => string;
/**
* @private
* Get the edited tag for the message if it is edited.
*/
export declare const getMessageEditedDetails: (message: ChatMessage | /* @conditional-compile-remove(data-loss-prevention) */ BlockedMessage, theme: Theme, editedTag: string) => JSX.Element | undefined;
/**
* Removes Fluent UI keyboard navigation styles from the given HTMLDivElement.
*
* This function removes the 'tabindex' and 'data-tabster' attributes from the provided
* HTMLDivElement, making it non-focusable and removing any associated keyboard navigation styles.
*
* @param node - The HTMLDivElement from which to remove the keyboard navigation styles. If null, the function does nothing.
*/
export declare const removeFluentUIKeyboardNavigationStyles: (node: HTMLDivElement | null) => void;
//# sourceMappingURL=ChatMessageComponentUtils.d.ts.map