@azure/communication-react 1.19.0-alpha-202407240016 → 1.19.0-alpha-202407260014
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/communication-react.d.ts +245 -22
- package/dist/dist-cjs/communication-react/{ChatMessageComponentAsRichTextEditBox-DeQxSr_Z.js → ChatMessageComponentAsRichTextEditBox-CWwHwLsl.js} +22 -18
- package/dist/dist-cjs/communication-react/ChatMessageComponentAsRichTextEditBox-CWwHwLsl.js.map +1 -0
- package/dist/dist-cjs/communication-react/{RichTextSendBoxWrapper-B-YGfNz1.js → RichTextSendBoxWrapper-OHSjE5aJ.js} +2 -3
- package/dist/dist-cjs/communication-react/{RichTextSendBoxWrapper-B-YGfNz1.js.map → RichTextSendBoxWrapper-OHSjE5aJ.js.map} +1 -1
- package/dist/dist-cjs/communication-react/{index-DCOkbnBI.js → index-Dl3wPPJe.js} +483 -240
- package/dist/dist-cjs/communication-react/index-Dl3wPPJe.js.map +1 -0
- package/dist/dist-cjs/communication-react/index.js +2 -2
- package/dist/dist-esm/acs-ui-common/src/index.d.ts +1 -0
- package/dist/dist-esm/acs-ui-common/src/index.js +2 -0
- package/dist/dist-esm/acs-ui-common/src/index.js.map +1 -1
- package/dist/dist-esm/acs-ui-common/src/removeImageTags.d.ts +7 -0
- package/dist/dist-esm/acs-ui-common/src/removeImageTags.js +18 -0
- package/dist/dist-esm/acs-ui-common/src/removeImageTags.js.map +1 -0
- package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js +1 -1
- package/dist/dist-esm/acs-ui-common/src/telemetryVersion.js.map +1 -1
- package/dist/dist-esm/calling-component-bindings/src/baseSelectors.d.ts +14 -1
- package/dist/dist-esm/calling-component-bindings/src/baseSelectors.js +16 -0
- package/dist/dist-esm/calling-component-bindings/src/baseSelectors.js.map +1 -1
- package/dist/dist-esm/calling-component-bindings/src/handlers/createHandlers.d.ts +2 -0
- package/dist/dist-esm/calling-component-bindings/src/handlers/createHandlers.js +17 -0
- package/dist/dist-esm/calling-component-bindings/src/handlers/createHandlers.js.map +1 -1
- package/dist/dist-esm/calling-component-bindings/src/handlers/createTeamsCallHandlers.d.ts +2 -0
- package/dist/dist-esm/calling-component-bindings/src/handlers/createTeamsCallHandlers.js +17 -0
- package/dist/dist-esm/calling-component-bindings/src/handlers/createTeamsCallHandlers.js.map +1 -1
- package/dist/dist-esm/calling-component-bindings/src/hooks/usePropsFor.d.ts +3 -1
- package/dist/dist-esm/calling-component-bindings/src/hooks/usePropsFor.js +13 -1
- package/dist/dist-esm/calling-component-bindings/src/hooks/usePropsFor.js.map +1 -1
- package/dist/dist-esm/calling-component-bindings/src/incomingCallStackSelector.d.ts +16 -0
- package/dist/dist-esm/calling-component-bindings/src/incomingCallStackSelector.js +33 -0
- package/dist/dist-esm/calling-component-bindings/src/incomingCallStackSelector.js.map +1 -0
- package/dist/dist-esm/calling-component-bindings/src/index.d.ts +2 -0
- package/dist/dist-esm/calling-component-bindings/src/index.js +1 -0
- package/dist/dist-esm/calling-component-bindings/src/index.js.map +1 -1
- package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.d.ts +6 -1
- package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.js +12 -0
- package/dist/dist-esm/calling-component-bindings/src/utils/callUtils.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/BetaToStableTypes.d.ts +2 -7
- package/dist/dist-esm/calling-stateful-client/src/BetaToStableTypes.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.d.ts +2 -2
- package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.js +1 -2
- package/dist/dist-esm/calling-stateful-client/src/CallAgentDeclarativeCommon.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/CallClientState.d.ts +62 -3
- package/dist/dist-esm/calling-stateful-client/src/CallClientState.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/CallContext.d.ts +2 -1
- package/dist/dist-esm/calling-stateful-client/src/CallContext.js +6 -0
- package/dist/dist-esm/calling-stateful-client/src/CallContext.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/Converter.d.ts +4 -3
- package/dist/dist-esm/calling-stateful-client/src/Converter.js +25 -0
- package/dist/dist-esm/calling-stateful-client/src/Converter.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/DeviceManagerDeclarative.js +3 -1
- package/dist/dist-esm/calling-stateful-client/src/DeviceManagerDeclarative.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/IncomingCallSubscriber.d.ts +1 -2
- package/dist/dist-esm/calling-stateful-client/src/IncomingCallSubscriber.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/TypeGuards.d.ts +2 -2
- package/dist/dist-esm/calling-stateful-client/src/TypeGuards.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/index-public.d.ts +2 -1
- package/dist/dist-esm/calling-stateful-client/src/index-public.js.map +1 -1
- package/dist/dist-esm/calling-stateful-client/src/index.d.ts +1 -1
- package/dist/dist-esm/calling-stateful-client/src/index.js.map +1 -1
- package/dist/dist-esm/communication-react/src/index.d.ts +4 -2
- package/dist/dist-esm/communication-react/src/index.js +1 -1
- package/dist/dist-esm/communication-react/src/index.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageComponentWrapper.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/ChatMessage/ChatMessageComponentWrapper.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsEditBoxPicker.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.js +22 -15
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.js +2 -2
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/ChatMyMessageComponent.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/FluentChatMyMessageComponent.js +6 -6
- package/dist/dist-esm/react-components/src/components/ChatMessage/MyMessageComponents/FluentChatMyMessageComponent.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.js +2 -2
- package/dist/dist-esm/react-components/src/components/Dialpad/Dialpad.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/IncomingCallNotification.d.ts +27 -1
- package/dist/dist-esm/react-components/src/components/IncomingCallNotification.js +73 -36
- package/dist/dist-esm/react-components/src/components/IncomingCallNotification.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/IncomingCallStack.d.ts +76 -0
- package/dist/dist-esm/react-components/src/components/IncomingCallStack.js +23 -0
- package/dist/dist-esm/react-components/src/components/IncomingCallStack.js.map +1 -0
- package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.d.ts +0 -5
- package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.js +3 -23
- package/dist/dist-esm/react-components/src/components/MeetingConferencePhoneInfo.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/MessageThread.d.ts +8 -7
- package/dist/dist-esm/react-components/src/components/MessageThread.js +3 -3
- package/dist/dist-esm/react-components/src/components/MessageThread.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/CopyPastePlugin.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/CopyPastePlugin.js +15 -5
- package/dist/dist-esm/react-components/src/components/RichTextEditor/Plugins/CopyPastePlugin.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.d.ts +1 -1
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.js +3 -3
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextEditor.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextInputBoxComponent.d.ts +1 -1
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextInputBoxComponent.js +2 -2
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextInputBoxComponent.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.d.ts +17 -11
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.js +35 -17
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBox.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBoxErrors.js +12 -3
- package/dist/dist-esm/react-components/src/components/RichTextEditor/RichTextSendBoxErrors.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/SendBoxErrorBar.d.ts +22 -0
- package/dist/dist-esm/react-components/src/components/SendBoxErrorBar.js +58 -6
- package/dist/dist-esm/react-components/src/components/SendBoxErrorBar.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/VideoGallery/useVideoTileContextualMenuProps.js +15 -15
- package/dist/dist-esm/react-components/src/components/VideoGallery/useVideoTileContextualMenuProps.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/index.d.ts +3 -0
- package/dist/dist-esm/react-components/src/components/index.js +3 -0
- package/dist/dist-esm/react-components/src/components/index.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/styles/AttachmentCard.styles.d.ts +1 -1
- package/dist/dist-esm/react-components/src/components/styles/MessageThread.styles.d.ts +1 -1
- package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.d.ts +3 -3
- package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.js +11 -11
- package/dist/dist-esm/react-components/src/components/utils/SendBoxUtils.js.map +1 -1
- package/dist/dist-esm/react-components/src/components/utils/formatPhoneNumber.d.ts +2 -2
- package/dist/dist-esm/react-components/src/components/utils/formatPhoneNumber.js +6 -2
- package/dist/dist-esm/react-components/src/components/utils/formatPhoneNumber.js.map +1 -1
- package/dist/dist-esm/react-components/src/localization/locales/en-US/strings.json +13 -6
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js +3 -3
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/NetworkReconnectTile.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/SidePane.js +7 -9
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/SidePane.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/usePeoplePane.js +36 -33
- package/dist/dist-esm/react-composites/src/composites/CallComposite/components/SidePane/usePeoplePane.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.js +16 -9
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ChatScreen.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.d.ts +5 -10
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.js +17 -33
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/ImageUpload/ImageUploadUtils.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/Strings.d.ts +16 -0
- package/dist/dist-esm/react-composites/src/composites/ChatComposite/Strings.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js +2 -2
- package/dist/dist-esm/react-composites/src/composites/common/MeetingPhoneInfoPaneContent.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/common/SendBoxPicker.js +3 -3
- package/dist/dist-esm/react-composites/src/composites/common/SendBoxPicker.js.map +1 -1
- package/dist/dist-esm/react-composites/src/composites/localization/locales/en-US/strings.json +5 -1
- package/package.json +2 -3
- package/dist/dist-cjs/communication-react/ChatMessageComponentAsRichTextEditBox-DeQxSr_Z.js.map +0 -1
- package/dist/dist-cjs/communication-react/index-DCOkbnBI.js.map +0 -1
@@ -66,6 +66,7 @@ import { IIconProps } from '@fluentui/react';
|
|
66
66
|
import { ILinkStyles } from '@fluentui/react';
|
67
67
|
import { IMessageBarProps } from '@fluentui/react';
|
68
68
|
import { IncomingCall } from '@azure/communication-calling';
|
69
|
+
import { IncomingCallKind } from '@azure/communication-calling';
|
69
70
|
import { IPersonaStyleProps } from '@fluentui/react';
|
70
71
|
import { IPersonaStyles } from '@fluentui/react';
|
71
72
|
import { IRawStyle } from '@fluentui/react';
|
@@ -154,6 +155,38 @@ export declare interface ActiveErrorMessage {
|
|
154
155
|
timestamp?: Date;
|
155
156
|
}
|
156
157
|
|
158
|
+
/**
|
159
|
+
* Represents an active incoming call.
|
160
|
+
* @beta
|
161
|
+
*/
|
162
|
+
export declare interface ActiveIncomingCall {
|
163
|
+
/**
|
164
|
+
* Unique identifier for the incoming call.
|
165
|
+
*/
|
166
|
+
id: string;
|
167
|
+
/**
|
168
|
+
* Information about the caller.
|
169
|
+
*/
|
170
|
+
callerInfo: {
|
171
|
+
/**
|
172
|
+
* Display name of the caller.
|
173
|
+
*/
|
174
|
+
displayName: string;
|
175
|
+
};
|
176
|
+
/**
|
177
|
+
* Start time of the incoming call.
|
178
|
+
*/
|
179
|
+
startTime: Date;
|
180
|
+
/**
|
181
|
+
* End time of the incoming call.
|
182
|
+
*/
|
183
|
+
endTime?: Date;
|
184
|
+
/**
|
185
|
+
* Whether or not the call is a voip capable call.
|
186
|
+
*/
|
187
|
+
videoAvailable: boolean;
|
188
|
+
}
|
189
|
+
|
157
190
|
/**
|
158
191
|
* Active notifications to be shown via {@link NotificationStack}.
|
159
192
|
*
|
@@ -1600,7 +1633,7 @@ export declare interface CallClientState {
|
|
1600
1633
|
* It is keyed by {@link @azure/communication-calling#IncomingCall.id}.
|
1601
1634
|
*/
|
1602
1635
|
incomingCalls: {
|
1603
|
-
[key: string]: IncomingCallState;
|
1636
|
+
[key: string]: IncomingCallState | /* @conditional-compile-remove(one-to-n-calling) */ TeamsIncomingCallState;
|
1604
1637
|
};
|
1605
1638
|
/**
|
1606
1639
|
* Incoming Calls that have ended are stored here so the callEndReason could be checked.
|
@@ -1609,7 +1642,7 @@ export declare interface CallClientState {
|
|
1609
1642
|
* Only {@link MAX_CALL_HISTORY_LENGTH} Calls are kept in the history. Oldest calls are evicted if required.
|
1610
1643
|
*/
|
1611
1644
|
incomingCallsEnded: {
|
1612
|
-
[key: string]: IncomingCallState;
|
1645
|
+
[key: string]: IncomingCallState | /* @conditional-compile-remove(one-to-n-calling) */ TeamsIncomingCallState;
|
1613
1646
|
};
|
1614
1647
|
/**
|
1615
1648
|
* Proxy of {@link @azure/communication-calling#DeviceManager}. Please review {@link DeviceManagerState}.
|
@@ -2878,6 +2911,29 @@ export declare type CallIdChangedListener = (event: {
|
|
2878
2911
|
callId: string;
|
2879
2912
|
}) => void;
|
2880
2913
|
|
2914
|
+
/**
|
2915
|
+
* State to track the types {@link CallInfo} and {@link TeamsCallInfo}
|
2916
|
+
* @public
|
2917
|
+
*/
|
2918
|
+
export declare interface CallInfoState {
|
2919
|
+
/**
|
2920
|
+
* GroupId of the call that you joined
|
2921
|
+
*/
|
2922
|
+
groupId?: string;
|
2923
|
+
/**
|
2924
|
+
* The teams meeting thread id
|
2925
|
+
*/
|
2926
|
+
threadId?: string;
|
2927
|
+
/**
|
2928
|
+
* participant id of the local user
|
2929
|
+
*/
|
2930
|
+
participantId: string;
|
2931
|
+
/**
|
2932
|
+
* Differentiator between the Call and TeamsCall types
|
2933
|
+
*/
|
2934
|
+
kind: IncomingCallKind;
|
2935
|
+
}
|
2936
|
+
|
2881
2937
|
/**
|
2882
2938
|
* Common props used to reference calling declarative client state.
|
2883
2939
|
*
|
@@ -2897,6 +2953,8 @@ export declare type CallingBaseSelectorProps = {
|
|
2897
2953
|
*/
|
2898
2954
|
export declare interface CallingHandlers extends CommonCallingHandlers {
|
2899
2955
|
onStartCall: (participants: CommunicationIdentifier[], options?: StartCallOptions) => Call | undefined;
|
2956
|
+
onAcceptCall: (incomingCallId: string, useVideo?: boolean) => Promise<void>;
|
2957
|
+
onRejectCall: (incomingCallId: string) => Promise<void>;
|
2900
2958
|
}
|
2901
2959
|
|
2902
2960
|
/**
|
@@ -5056,6 +5114,22 @@ export declare interface ChatCompositeStrings {
|
|
5056
5114
|
* Upload Attachment Button text
|
5057
5115
|
*/
|
5058
5116
|
uploadAttachment: string;
|
5117
|
+
/**
|
5118
|
+
* Error Message for image data is not provided for image upload
|
5119
|
+
*/
|
5120
|
+
uploadImageDataNotProvided: string;
|
5121
|
+
/**
|
5122
|
+
* Error Message for upload image is too large
|
5123
|
+
*/
|
5124
|
+
uploadImageIsTooLarge: string;
|
5125
|
+
/**
|
5126
|
+
* Error Message for unsupported image extension for image upload
|
5127
|
+
*/
|
5128
|
+
uploadImageExtensionIsNotAllowed: string;
|
5129
|
+
/**
|
5130
|
+
* Error Message for unable to upload image
|
5131
|
+
*/
|
5132
|
+
uploadImageFailed: string;
|
5059
5133
|
}
|
5060
5134
|
|
5061
5135
|
/**
|
@@ -7604,7 +7678,7 @@ export declare const fromFlatCommunicationIdentifier: (id: string) => Communicat
|
|
7604
7678
|
*
|
7605
7679
|
* @public
|
7606
7680
|
*/
|
7607
|
-
export declare type GetCallingSelector<Component extends (props: any) => JSX.Element | undefined> = AreEqual<Component, typeof VideoGallery> extends true ? VideoGallerySelector : AreEqual<Component, typeof DevicesButton> extends true ? DevicesButtonSelector : AreEqual<Component, typeof MicrophoneButton> extends true ? MicrophoneButtonSelector : AreEqual<Component, typeof CameraButton> extends true ? CameraButtonSelector : AreEqual<Component, typeof ScreenShareButton> extends true ? ScreenShareButtonSelector : AreEqual<Component, typeof ParticipantList> extends true ? ParticipantListSelector : AreEqual<Component, typeof ParticipantsButton> extends true ? ParticipantsButtonSelector : AreEqual<Component, typeof EndCallButton> extends true ? EmptySelector : AreEqual<Component, typeof ErrorBar> extends true ? CallErrorBarSelector : AreEqual<Component, typeof Dialpad> extends true ? EmptySelector : AreEqual<Component, typeof HoldButton> extends true ? HoldButtonSelector : AreEqual<Component, typeof NotificationStack> extends true ? NotificationStackSelector : undefined;
|
7681
|
+
export declare type GetCallingSelector<Component extends (props: any) => JSX.Element | undefined> = AreEqual<Component, typeof VideoGallery> extends true ? VideoGallerySelector : AreEqual<Component, typeof DevicesButton> extends true ? DevicesButtonSelector : AreEqual<Component, typeof MicrophoneButton> extends true ? MicrophoneButtonSelector : AreEqual<Component, typeof CameraButton> extends true ? CameraButtonSelector : AreEqual<Component, typeof ScreenShareButton> extends true ? ScreenShareButtonSelector : AreEqual<Component, typeof ParticipantList> extends true ? ParticipantListSelector : AreEqual<Component, typeof ParticipantsButton> extends true ? ParticipantsButtonSelector : AreEqual<Component, typeof EndCallButton> extends true ? EmptySelector : AreEqual<Component, typeof ErrorBar> extends true ? CallErrorBarSelector : AreEqual<Component, typeof Dialpad> extends true ? EmptySelector : AreEqual<Component, typeof HoldButton> extends true ? HoldButtonSelector : AreEqual<Component, typeof NotificationStack> extends true ? NotificationStackSelector : AreEqual<Component, typeof IncomingCallStack> extends true ? IncomingCallStackSelector : undefined;
|
7608
7682
|
|
7609
7683
|
/**
|
7610
7684
|
* Get the selector for a specified component.
|
@@ -7938,10 +8012,24 @@ export declare interface IncomingCallNotificationProps {
|
|
7938
8012
|
* Callback to reject the call
|
7939
8013
|
*/
|
7940
8014
|
onReject: () => void;
|
8015
|
+
/**
|
8016
|
+
* Callback when the notification is dismissed
|
8017
|
+
*/
|
8018
|
+
onDismiss?: () => void;
|
7941
8019
|
/**
|
7942
8020
|
* Styles for the incoming call notification component.
|
7943
8021
|
*/
|
7944
8022
|
styles?: IncomingCallNotificationStyles;
|
8023
|
+
/**
|
8024
|
+
* Strings for the incoming call notification component.
|
8025
|
+
*/
|
8026
|
+
strings?: IncomingCallNotificationStrings;
|
8027
|
+
/**
|
8028
|
+
* Options for whether to show the accept with video button
|
8029
|
+
*/
|
8030
|
+
acceptOptions: {
|
8031
|
+
showAcceptWithVideo: boolean;
|
8032
|
+
};
|
7945
8033
|
}
|
7946
8034
|
|
7947
8035
|
/**
|
@@ -7951,7 +8039,7 @@ export declare interface IncomingCallNotificationProps {
|
|
7951
8039
|
*/
|
7952
8040
|
export declare interface IncomingCallNotificationStrings {
|
7953
8041
|
/**
|
7954
|
-
*Placeholder CallerID for the incoming call notification.
|
8042
|
+
* Placeholder CallerID for the incoming call notification.
|
7955
8043
|
*/
|
7956
8044
|
incomingCallNotificationPlaceholderId?: string;
|
7957
8045
|
/**
|
@@ -7970,6 +8058,18 @@ export declare interface IncomingCallNotificationStrings {
|
|
7970
8058
|
* Aria label for the reject button in the incoming call notification.
|
7971
8059
|
*/
|
7972
8060
|
incomingCallNoticicationRejectAriaLabel?: string;
|
8061
|
+
/**
|
8062
|
+
* Label for the accept button in the incoming call notification.
|
8063
|
+
*/
|
8064
|
+
incomingCallNotificationAcceptButtonLabel?: string;
|
8065
|
+
/**
|
8066
|
+
* Label for the accept with video button in the incoming call notification.
|
8067
|
+
*/
|
8068
|
+
incomingCallNotificationAccceptWithVideoButtonLabel?: string;
|
8069
|
+
/**
|
8070
|
+
* label for the reject button in the incoming call notification.
|
8071
|
+
*/
|
8072
|
+
incomingCallNotificationRejectButtonLabel?: string;
|
7973
8073
|
}
|
7974
8074
|
|
7975
8075
|
/**
|
@@ -7996,6 +8096,59 @@ export declare interface IncomingCallNotificationStyles {
|
|
7996
8096
|
avatarContainer?: IStackStyles;
|
7997
8097
|
}
|
7998
8098
|
|
8099
|
+
/**
|
8100
|
+
* Wrapper to manage multiple incoming calls
|
8101
|
+
* @param props - {@link IncomingCallManagerProps}
|
8102
|
+
* @returns
|
8103
|
+
* @beta
|
8104
|
+
*/
|
8105
|
+
export declare const IncomingCallStack: (props: IncomingCallStackProps) => JSX.Element;
|
8106
|
+
|
8107
|
+
/**
|
8108
|
+
* Props for the IncomingCallManager component.
|
8109
|
+
* @beta
|
8110
|
+
*/
|
8111
|
+
export declare interface IncomingCallStackProps {
|
8112
|
+
/**
|
8113
|
+
* List of incoming calls.
|
8114
|
+
*/
|
8115
|
+
activeIncomingCalls: ActiveIncomingCall[];
|
8116
|
+
/**
|
8117
|
+
* List of incoming calls that have ended.
|
8118
|
+
*/
|
8119
|
+
removedIncomingCalls: ActiveIncomingCall[];
|
8120
|
+
/**
|
8121
|
+
* Handler to accept the incoming call.
|
8122
|
+
* @param incomingCallId - Id of the incoming call to accept.
|
8123
|
+
* @param useVideo - Whether to accept with video.
|
8124
|
+
* @returns void
|
8125
|
+
*/
|
8126
|
+
onAcceptCall: (incomingCallId: string, useVideo?: boolean) => void;
|
8127
|
+
/**
|
8128
|
+
* Handler to reject the incoming call.
|
8129
|
+
* @param incomingCallId - id of the incoming call to reject
|
8130
|
+
* @returns - void
|
8131
|
+
*/
|
8132
|
+
onRejectCall: (incomingCallId: string) => void;
|
8133
|
+
/**
|
8134
|
+
* Styles for the incoming call notifications.
|
8135
|
+
*/
|
8136
|
+
styles?: IncomingCallNotificationStyles;
|
8137
|
+
/**
|
8138
|
+
* Strings for the incoming call notifications.
|
8139
|
+
*/
|
8140
|
+
strings?: IncomingCallNotificationStrings;
|
8141
|
+
}
|
8142
|
+
|
8143
|
+
/**
|
8144
|
+
* Selector to get the active and removed incoming calls.
|
8145
|
+
* @beta
|
8146
|
+
*/
|
8147
|
+
export declare type IncomingCallStackSelector = (state: CallClientState) => {
|
8148
|
+
activeIncomingCalls: ActiveIncomingCall[];
|
8149
|
+
removedIncomingCalls: ActiveIncomingCall[];
|
8150
|
+
};
|
8151
|
+
|
7999
8152
|
/**
|
8000
8153
|
* State only version of {@link @azure/communication-calling#IncomingCall}. {@link StatefulCallClient} will
|
8001
8154
|
* automatically detect incoming calls and add their state to the state exposed by {@link StatefulCallClient}.
|
@@ -8007,6 +8160,10 @@ export declare interface IncomingCallState {
|
|
8007
8160
|
* Proxy of {@link @azure/communication-calling#IncomingCall.id}.
|
8008
8161
|
*/
|
8009
8162
|
id: string;
|
8163
|
+
/**
|
8164
|
+
* Proxy of {@link @azure/communication-calling#IncomingCall.callInfo}.
|
8165
|
+
*/
|
8166
|
+
info: CallInfoState;
|
8010
8167
|
/**
|
8011
8168
|
* Proxy of {@link @azure/communication-calling#IncomingCall.callerInfo}.
|
8012
8169
|
*/
|
@@ -8924,9 +9081,9 @@ export declare interface MessageThreadStrings {
|
|
8924
9081
|
/** String for aria text in attachment card group*/
|
8925
9082
|
attachmentCardGroupMessage: string;
|
8926
9083
|
/**
|
8927
|
-
* Error message indicating that
|
9084
|
+
* Error message indicating that one or more image uploads are not complete.
|
8928
9085
|
*/
|
8929
|
-
|
9086
|
+
imageUploadsPendingError: string;
|
8930
9087
|
}
|
8931
9088
|
|
8932
9089
|
/**
|
@@ -10410,18 +10567,19 @@ export declare type ResourceFetchResult = {
|
|
10410
10567
|
*/
|
10411
10568
|
export declare interface RichTextEditBoxOptions extends RichTextEditorOptions {
|
10412
10569
|
/**
|
10413
|
-
* Optional callback to
|
10570
|
+
* Optional callback to handle an inline image that's inserted in the rich text editor.
|
10571
|
+
* When not provided, pasting images into rich text editor will be disabled.
|
10414
10572
|
*/
|
10415
|
-
|
10573
|
+
onInsertInlineImage?: (imageUrl: string, imageFileName: string, messageId: string) => void;
|
10416
10574
|
/**
|
10417
|
-
* Optional callback to remove the
|
10575
|
+
* Optional callback to remove the image upload or delete the image from server before sending.
|
10418
10576
|
*/
|
10419
10577
|
onCancelInlineImageUpload?: (imageId: string, messageId: string) => void;
|
10420
10578
|
/**
|
10421
10579
|
* Optional Record of type {@link AttachmentMetadataInProgress}
|
10422
|
-
* to render inline images being
|
10580
|
+
* to render inline images being inserted in the MessageThread's edit boxes.
|
10423
10581
|
*/
|
10424
|
-
|
10582
|
+
messagesInlineImages?: Record<string, AttachmentMetadataInProgress[]>;
|
10425
10583
|
}
|
10426
10584
|
|
10427
10585
|
/**
|
@@ -10452,18 +10610,19 @@ export declare const RichTextSendBox: (props: RichTextSendBoxProps) => JSX.Eleme
|
|
10452
10610
|
*/
|
10453
10611
|
export declare interface RichTextSendBoxOptions extends RichTextEditorOptions {
|
10454
10612
|
/**
|
10455
|
-
* Optional callback to
|
10613
|
+
* Optional callback to handle an inline image that's inserted in the rich text editor.
|
10614
|
+
* When not provided, pasting images into rich text editor will be disabled.
|
10456
10615
|
*/
|
10457
|
-
|
10616
|
+
onInsertInlineImage?: (imageUrl: string, imageFileName: string) => void;
|
10458
10617
|
/**
|
10459
|
-
* Optional callback to remove the
|
10618
|
+
* Optional callback to remove the image upload or delete the image from server before sending.
|
10460
10619
|
*/
|
10461
10620
|
onCancelInlineImageUpload?: (imageId: string) => void;
|
10462
10621
|
/**
|
10463
10622
|
* Optional Array of type {@link AttachmentMetadataInProgress}
|
10464
|
-
* to render inline images being
|
10623
|
+
* to render inline images being inserted in the RichTextSendBox.
|
10465
10624
|
*/
|
10466
|
-
|
10625
|
+
inlineImages?: AttachmentMetadataInProgress[];
|
10467
10626
|
}
|
10468
10627
|
|
10469
10628
|
/**
|
@@ -10508,7 +10667,7 @@ export declare interface RichTextSendBoxProps {
|
|
10508
10667
|
*/
|
10509
10668
|
onCancelAttachmentUpload?: (attachmentId: string) => void;
|
10510
10669
|
/**
|
10511
|
-
* Optional callback to remove the
|
10670
|
+
* Optional callback to remove the image upload or delete the image from server before sending.
|
10512
10671
|
*/
|
10513
10672
|
onCancelInlineImageUpload?: (imageId: string) => void;
|
10514
10673
|
/**
|
@@ -10520,14 +10679,15 @@ export declare interface RichTextSendBoxProps {
|
|
10520
10679
|
*/
|
10521
10680
|
onTyping?: () => Promise<void>;
|
10522
10681
|
/**
|
10523
|
-
* Optional callback to
|
10682
|
+
* Optional callback to handle an inline image that's inserted in the rich text editor.
|
10683
|
+
* When not provided, pasting images into rich text editor will be disabled.
|
10524
10684
|
*/
|
10525
|
-
|
10685
|
+
onInsertInlineImage?: (imageUrl: string, imageFileName: string) => void;
|
10526
10686
|
/**
|
10527
|
-
* Optional
|
10528
|
-
* to render inline images being
|
10687
|
+
* Optional Array of type {@link AttachmentMetadataInProgress}
|
10688
|
+
* to render inline images being inserted in the RichTextSendBox.
|
10529
10689
|
*/
|
10530
|
-
|
10690
|
+
inlineImages?: AttachmentMetadataInProgress[];
|
10531
10691
|
}
|
10532
10692
|
|
10533
10693
|
/**
|
@@ -10640,6 +10800,10 @@ export declare interface RichTextStrings {
|
|
10640
10800
|
* Text for announcement when the numbered list style is applied.
|
10641
10801
|
*/
|
10642
10802
|
richTextNumberedListAppliedAnnouncement: string;
|
10803
|
+
/**
|
10804
|
+
* Error message indicating image upload is not complete.
|
10805
|
+
*/
|
10806
|
+
imageUploadsPendingError: string;
|
10643
10807
|
}
|
10644
10808
|
|
10645
10809
|
/**
|
@@ -10724,6 +10888,29 @@ export declare interface SendBoxErrorBarError {
|
|
10724
10888
|
* Unix Timestamp. Preferred generation using `Date.now()`
|
10725
10889
|
*/
|
10726
10890
|
timestamp: number;
|
10891
|
+
/**
|
10892
|
+
* ErrorBar type. Defaults to `warning`.
|
10893
|
+
*/
|
10894
|
+
errorBarType?: SendBoxErrorBarType;
|
10895
|
+
}
|
10896
|
+
|
10897
|
+
/**
|
10898
|
+
* @beta
|
10899
|
+
* Error bar type for {@link SendBoxErrorBarError}
|
10900
|
+
*/
|
10901
|
+
export declare enum SendBoxErrorBarType {
|
10902
|
+
/** Info styled MessageBar */
|
10903
|
+
info = 0,
|
10904
|
+
/** Error styled MessageBar */
|
10905
|
+
error = 1,
|
10906
|
+
/** Blocked styled MessageBar */
|
10907
|
+
blocked = 2,
|
10908
|
+
/** SevereWarning styled MessageBar */
|
10909
|
+
severeWarning = 3,
|
10910
|
+
/** Success styled MessageBar */
|
10911
|
+
success = 4,
|
10912
|
+
/** Warning styled MessageBar */
|
10913
|
+
warning = 5
|
10727
10914
|
}
|
10728
10915
|
|
10729
10916
|
/**
|
@@ -11560,6 +11747,8 @@ export declare type TeamsCallAdapterArgsCommon = {
|
|
11560
11747
|
*/
|
11561
11748
|
export declare interface TeamsCallingHandlers extends CommonCallingHandlers {
|
11562
11749
|
onStartCall: (participants: CommunicationIdentifier[], options?: StartCallOptions) => undefined | /* @conditional-compile-remove(teams-identity-support) */ TeamsCall;
|
11750
|
+
onAcceptCall: (incomingCallId: string, useVideo?: boolean) => Promise<void>;
|
11751
|
+
onRejectCall: (incomingCallId: string) => Promise<void>;
|
11563
11752
|
}
|
11564
11753
|
|
11565
11754
|
/**
|
@@ -11575,6 +11764,40 @@ export declare type TeamsIncomingCallManagement = {
|
|
11575
11764
|
incomingCalls: ReadonlyArray<TeamsIncomingCall>;
|
11576
11765
|
};
|
11577
11766
|
|
11767
|
+
/**
|
11768
|
+
* State only version of {@link @azure/communication-calling#TeamsIncomingCall}
|
11769
|
+
* @beta
|
11770
|
+
*/
|
11771
|
+
export declare interface TeamsIncomingCallState {
|
11772
|
+
/**
|
11773
|
+
* Proxy of {@link @azure/communication-calling#TeamsIncomingCall.id}.
|
11774
|
+
*/
|
11775
|
+
id: string;
|
11776
|
+
/**
|
11777
|
+
* Proxy of {@link @azure/communication-calling#TeamsIncomingCall.teamsCallInfo}.
|
11778
|
+
*/
|
11779
|
+
info: CallInfoState;
|
11780
|
+
/**
|
11781
|
+
* Proxy of {@link @azure/communication-calling#TeamsIncomingCall.callerInfo}.
|
11782
|
+
*/
|
11783
|
+
callerInfo: CallerInfo;
|
11784
|
+
/**
|
11785
|
+
* Set to the state returned by 'callEnded' event on {@link @azure/communication-calling#IncomingCall} when received.
|
11786
|
+
* This property is added by the stateful layer and is not a proxy of SDK state.
|
11787
|
+
*/
|
11788
|
+
callEndReason?: CallEndReason;
|
11789
|
+
/**
|
11790
|
+
* Stores the local date when the call started on the client. This property is added by the stateful layer and is not
|
11791
|
+
* a proxy of SDK state.
|
11792
|
+
*/
|
11793
|
+
startTime: Date;
|
11794
|
+
/**
|
11795
|
+
* Stores the local date when the call ended on the client. This property is added by the stateful layer and is not a
|
11796
|
+
* proxy of SDK state. It is undefined if the call is not ended yet.
|
11797
|
+
*/
|
11798
|
+
endTime?: Date;
|
11799
|
+
}
|
11800
|
+
|
11578
11801
|
/**
|
11579
11802
|
* Arguments for creating the Azure Communication Services implementation of {@link TeamsCallAdapter}.
|
11580
11803
|
*
|
@@ -4,7 +4,7 @@ var react = require('@fluentui/react');
|
|
4
4
|
var reactChat = require('@fluentui-contrib/react-chat');
|
5
5
|
var reactComponents = require('@fluentui/react-components');
|
6
6
|
require('@azure/communication-common');
|
7
|
-
var index = require('./index-
|
7
|
+
var index = require('./index-Dl3wPPJe.js');
|
8
8
|
var React = require('react');
|
9
9
|
require('react-dom/client');
|
10
10
|
require('@azure/communication-chat');
|
@@ -30,7 +30,6 @@ require('@fluentui/react-hooks');
|
|
30
30
|
require('react-use-draggable-scroll');
|
31
31
|
require('@fluentui/react-window-provider');
|
32
32
|
require('copy-to-clipboard');
|
33
|
-
require('libphonenumber-js');
|
34
33
|
require('reselect');
|
35
34
|
require('@azure/communication-calling');
|
36
35
|
require('@azure/communication-calling-effects');
|
@@ -46,9 +45,9 @@ const ChatMessageComponentAsRichTextEditBox = (props) => {
|
|
46
45
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
47
46
|
onPaste,
|
48
47
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
49
|
-
|
48
|
+
onInsertInlineImage,
|
50
49
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
51
|
-
|
50
|
+
inlineImages,
|
52
51
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
53
52
|
onCancelInlineImageUpload } = props;
|
54
53
|
const initialContent = React.useMemo(() => {
|
@@ -89,8 +88,8 @@ const ChatMessageComponentAsRichTextEditBox = (props) => {
|
|
89
88
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
90
89
|
const imageUploadErrorMessage = React.useMemo(() => {
|
91
90
|
var _a, _b;
|
92
|
-
return (_b = (_a =
|
93
|
-
}, [
|
91
|
+
return (_b = (_a = inlineImages === null || inlineImages === void 0 ? void 0 : inlineImages.filter((image) => image.error).pop()) === null || _a === void 0 ? void 0 : _a.error) === null || _b === void 0 ? void 0 : _b.message;
|
92
|
+
}, [inlineImages]);
|
94
93
|
const submitEnabled = messageState === 'OK';
|
95
94
|
const editContainerStyles = index.useChatMessageRichTextEditContainerStyles();
|
96
95
|
const chatMyMessageStyles = index.useChatMyMessageStyles();
|
@@ -129,16 +128,20 @@ const ChatMessageComponentAsRichTextEditBox = (props) => {
|
|
129
128
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
130
129
|
setAttachmentUploadsPendingError(undefined);
|
131
130
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
132
|
-
if (index.hasIncompleteAttachmentUploads(
|
133
|
-
setAttachmentUploadsPendingError({
|
131
|
+
if (index.hasIncompleteAttachmentUploads(inlineImages)) {
|
132
|
+
setAttachmentUploadsPendingError({
|
133
|
+
message: strings.imageUploadsPendingError,
|
134
|
+
timestamp: Date.now(),
|
135
|
+
errorBarType: index.SendBoxErrorBarType.info
|
136
|
+
});
|
134
137
|
return;
|
135
138
|
}
|
136
139
|
let content = textValue;
|
137
140
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
138
141
|
content = index.removeBrokenImageContentAndClearImageSizeStyles(content);
|
139
142
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
140
|
-
if (index.isAttachmentUploadCompleted(
|
141
|
-
index.insertImagesToContentString(textValue,
|
143
|
+
if (index.isAttachmentUploadCompleted(inlineImages)) {
|
144
|
+
index.insertImagesToContentString(textValue, inlineImages, (content) => {
|
142
145
|
onSubmit(content, /* @conditional-compile-remove(file-sharing-acs) */ attachmentMetadata || []);
|
143
146
|
});
|
144
147
|
return;
|
@@ -151,10 +154,10 @@ const ChatMessageComponentAsRichTextEditBox = (props) => {
|
|
151
154
|
}, [
|
152
155
|
submitEnabled,
|
153
156
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
154
|
-
|
157
|
+
inlineImages,
|
155
158
|
textValue,
|
156
159
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
157
|
-
strings.
|
160
|
+
strings.imageUploadsPendingError,
|
158
161
|
onSubmit,
|
159
162
|
/* @conditional-compile-remove(file-sharing-acs) */
|
160
163
|
attachmentMetadata
|
@@ -203,7 +206,7 @@ const ChatMessageComponentAsRichTextEditBox = (props) => {
|
|
203
206
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
204
207
|
index.cancelInlineImageUpload({
|
205
208
|
imageSrcArray,
|
206
|
-
|
209
|
+
inlineImages,
|
207
210
|
messageId: message.messageId,
|
208
211
|
editBoxOnCancelInlineImageUpload: onCancelInlineImageUpload,
|
209
212
|
sendBoxOnCancelInlineImageUpload: undefined
|
@@ -211,7 +214,7 @@ const ChatMessageComponentAsRichTextEditBox = (props) => {
|
|
211
214
|
setText(content);
|
212
215
|
}, [
|
213
216
|
setText,
|
214
|
-
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
217
|
+
/* @conditional-compile-remove(rich-text-editor-image-upload) */ inlineImages,
|
215
218
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */ onCancelInlineImageUpload,
|
216
219
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */ message.messageId
|
217
220
|
]);
|
@@ -223,7 +226,8 @@ const ChatMessageComponentAsRichTextEditBox = (props) => {
|
|
223
226
|
attachmentProgressError: imageUploadErrorMessage
|
224
227
|
? {
|
225
228
|
message: imageUploadErrorMessage,
|
226
|
-
timestamp: Date.now()
|
229
|
+
timestamp: Date.now(),
|
230
|
+
errorBarType: index.SendBoxErrorBarType.error
|
227
231
|
}
|
228
232
|
: undefined }),
|
229
233
|
React.createElement(index.RichTextInputBoxComponent, { placeholderText: strings.editBoxPlaceholderText, onChange: onChangeHandler, editorComponentRef: editTextFieldRef, initialContent: initialContent, strings: richTextLocaleStrings, disabled: false, actionComponents: actionButtons, richTextEditorStyleProps: index.editBoxRichTextEditorStyle, isHorizontalLayoutDisabled: true,
|
@@ -232,8 +236,8 @@ const ChatMessageComponentAsRichTextEditBox = (props) => {
|
|
232
236
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
233
237
|
onPaste: onPaste,
|
234
238
|
/* @conditional-compile-remove(rich-text-editor-image-upload) */
|
235
|
-
|
236
|
-
|
239
|
+
onInsertInlineImage: (imageUrl, imageFileName) => {
|
240
|
+
onInsertInlineImage && onInsertInlineImage(imageUrl, imageFileName, message.messageId);
|
237
241
|
} })));
|
238
242
|
};
|
239
243
|
const attached = message.attached === true ? 'center' : message.attached === 'bottom' ? 'bottom' : 'top';
|
@@ -248,4 +252,4 @@ const ChatMessageComponentAsRichTextEditBox = (props) => {
|
|
248
252
|
|
249
253
|
exports.ChatMessageComponentAsRichTextEditBox = ChatMessageComponentAsRichTextEditBox;
|
250
254
|
exports.default = ChatMessageComponentAsRichTextEditBox;
|
251
|
-
//# sourceMappingURL=ChatMessageComponentAsRichTextEditBox-
|
255
|
+
//# sourceMappingURL=ChatMessageComponentAsRichTextEditBox-CWwHwLsl.js.map
|
package/dist/dist-cjs/communication-react/ChatMessageComponentAsRichTextEditBox-CWwHwLsl.js.map
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"ChatMessageComponentAsRichTextEditBox-CWwHwLsl.js","sources":["../../../../react-components/src/components/ChatMessage/MyMessageComponents/ChatMessageComponentAsRichTextEditBox.tsx"],"sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\nimport { mergeStyles, Stack } from '@fluentui/react';\nimport { ChatMyMessage } from '@fluentui-contrib/react-chat';\nimport { mergeClasses } from '@fluentui/react-components';\nimport { _formatString } from '@internal/acs-ui-common';\n/* @conditional-compile-remove(rich-text-editor-image-upload) */\nimport { AttachmentMetadataInProgress } from '@internal/acs-ui-common';\nimport { useTheme } from '../../../theming';\nimport React, { useCallback, useEffect, useMemo, useState } from 'react';\n/* @conditional-compile-remove(file-sharing-acs) */\nimport { useReducer } from 'react';\nimport { editBoxWidthStyles, richTextEditBoxActionButtonIcon } from '../../styles/EditBox.styles';\nimport { InputBoxButton } from '../../InputBoxButton';\nimport { MessageThreadStrings } from '../../MessageThread';\nimport { useChatMyMessageStyles } from '../../styles/MessageThread.styles';\nimport { ChatMessage } from '../../../types';\nimport { _AttachmentUploadCards } from '../../Attachment/AttachmentUploadCards';\n/* @conditional-compile-remove(file-sharing-acs) */\nimport { AttachmentMetadata } from '@internal/acs-ui-common';\nimport { useChatMessageRichTextEditContainerStyles } from '../../styles/ChatMessageComponent.styles';\nimport { MAXIMUM_LENGTH_OF_MESSAGE } from '../../utils/SendBoxUtils';\n/* @conditional-compile-remove(rich-text-editor-image-upload) */\nimport {\n cancelInlineImageUpload,\n hasIncompleteAttachmentUploads,\n insertImagesToContentString,\n isAttachmentUploadCompleted,\n removeBrokenImageContentAndClearImageSizeStyles\n} from '../../utils/SendBoxUtils';\nimport {\n getMessageState,\n onRenderCancelIcon,\n onRenderSubmitIcon\n} from '../../utils/ChatMessageComponentAsEditBoxUtils';\n/* @conditional-compile-remove(file-sharing-acs) */\nimport {\n attachmentMetadataReducer,\n getMessageWithAttachmentMetadata,\n doesMessageContainMultipleAttachments\n} from '../../utils/ChatMessageComponentAsEditBoxUtils';\nimport { RichTextEditorComponentRef } from '../../RichTextEditor/RichTextEditor';\nimport { RichTextInputBoxComponent } from '../../RichTextEditor/RichTextInputBoxComponent';\nimport { editBoxRichTextEditorStyle, richTextActionButtonsStyle } from '../../styles/RichTextEditor.styles';\nimport { RichTextSendBoxErrors } from '../../RichTextEditor/RichTextSendBoxErrors';\nimport { useLocale } from '../../../localization';\n/* @conditional-compile-remove(file-sharing-acs) */\nimport { FluentV9ThemeProvider } from '../../../theming/FluentV9ThemeProvider';\n/* @conditional-compile-remove(file-sharing-acs) */\nimport { attachmentUploadCardsStyles } from '../../styles/SendBox.styles';\n/* @conditional-compile-remove(rich-text-editor-image-upload) */\nimport { SendBoxErrorBarError, SendBoxErrorBarType } from '../../SendBoxErrorBar';\n/* @conditional-compile-remove(rich-text-editor-image-upload) */\nimport { BROKEN_IMAGE_SVG_DATA } from '../../styles/Common.style';\n\n/** @private */\nexport type ChatMessageComponentAsRichTextEditBoxProps = {\n onCancel?: (messageId: string) => void;\n onSubmit: (\n text: string,\n /* @conditional-compile-remove(file-sharing-acs) */\n attachmentMetadata?: AttachmentMetadata[]\n ) => void;\n message: ChatMessage;\n strings: MessageThreadStrings;\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n onPaste?: (event: { content: DocumentFragment }) => void;\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n onCancelInlineImageUpload?: (imageId: string, messageId: string) => void;\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n onInsertInlineImage?: (imageUrl: string, imageFileName: string, messageId: string) => void;\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n inlineImages?: AttachmentMetadataInProgress[];\n};\n\n/**\n * @private\n */\nexport const ChatMessageComponentAsRichTextEditBox = (\n props: ChatMessageComponentAsRichTextEditBoxProps\n): JSX.Element => {\n const {\n onCancel,\n onSubmit,\n strings,\n message,\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n onPaste,\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n onInsertInlineImage,\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n inlineImages,\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n onCancelInlineImageUpload\n } = props;\n\n const initialContent = useMemo(() => {\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n const content = message.content;\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n const document = new DOMParser().parseFromString(content ?? '', 'text/html');\n // The broken image element is a div element with all the attributes of the original image element.\n // We need to convert it to a img element so the Rooster knows how to render it.\n // And we need to copy over all the attributes such as id, width, etc.\n // which is needed for sending the message with the images correctly.\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n document.querySelectorAll('.broken-image-wrapper').forEach((brokenImage) => {\n const imageElement = document.createElement('img');\n const attributes = brokenImage.attributes;\n for (const attribute of attributes) {\n imageElement.setAttribute(attribute.name, attribute.value);\n }\n\n imageElement.src = BROKEN_IMAGE_SVG_DATA;\n imageElement.style.width = '3rem';\n imageElement.style.height = '3rem';\n brokenImage.parentElement?.replaceChild(imageElement, brokenImage);\n });\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n return document.body.innerHTML;\n return message.content;\n }, [message]);\n\n const [textValue, setTextValue] = useState<string>(initialContent || '');\n\n /* @conditional-compile-remove(file-sharing-acs) */\n const [attachmentMetadata, handleAttachmentAction] = useReducer(\n attachmentMetadataReducer,\n getMessageWithAttachmentMetadata(message) ?? []\n );\n\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n const [attachmentUploadsPendingError, setAttachmentUploadsPendingError] = useState<SendBoxErrorBarError | undefined>(\n undefined\n );\n const editTextFieldRef = React.useRef<RichTextEditorComponentRef>(null);\n const theme = useTheme();\n const messageState = useMemo(() => {\n return getMessageState(textValue, /* @conditional-compile-remove(file-sharing-acs) */ attachmentMetadata ?? []);\n }, [/* @conditional-compile-remove(file-sharing-acs) */ attachmentMetadata, textValue]);\n\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n const imageUploadErrorMessage = useMemo(() => {\n return inlineImages?.filter((image) => image.error).pop()?.error?.message;\n }, [inlineImages]);\n\n const submitEnabled = messageState === 'OK';\n\n const editContainerStyles = useChatMessageRichTextEditContainerStyles();\n const chatMyMessageStyles = useChatMyMessageStyles();\n const locale = useLocale().strings;\n\n const setText = useCallback((newValue?: string): void => {\n setTextValue(newValue ?? '');\n }, []);\n\n useEffect(() => {\n editTextFieldRef.current?.focus();\n }, []);\n\n const textTooLongMessage = useMemo(() => {\n return messageState === 'too long'\n ? _formatString(strings.editBoxTextLimit, { limitNumber: `${MAXIMUM_LENGTH_OF_MESSAGE}` })\n : undefined;\n }, [messageState, strings.editBoxTextLimit]);\n\n const iconClassName = useCallback(\n (isHover: boolean) => {\n const color = isHover ? theme.palette.accent : theme.palette.neutralSecondary;\n return mergeStyles(richTextEditBoxActionButtonIcon, { color });\n },\n [theme.palette.accent, theme.palette.neutralSecondary]\n );\n\n const onRenderThemedCancelIcon = useCallback(\n (isHover: boolean) => {\n return onRenderCancelIcon(iconClassName(isHover));\n },\n [iconClassName]\n );\n\n const onRenderThemedSubmitIcon = useCallback(\n (isHover: boolean) => {\n return onRenderSubmitIcon(iconClassName(isHover));\n },\n [iconClassName]\n );\n\n /* @conditional-compile-remove(file-sharing-acs) */\n const hasMultipleAttachments = useMemo(() => {\n return doesMessageContainMultipleAttachments(message);\n }, [message]);\n\n const onSubmitHandler = useCallback((): void => {\n if (!submitEnabled) {\n return;\n }\n // Don't send message until all attachments have been uploaded successfully\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n setAttachmentUploadsPendingError(undefined);\n\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n if (hasIncompleteAttachmentUploads(inlineImages)) {\n setAttachmentUploadsPendingError({\n message: strings.imageUploadsPendingError,\n timestamp: Date.now(),\n errorBarType: SendBoxErrorBarType.info\n });\n return;\n }\n\n let content = textValue;\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n content = removeBrokenImageContentAndClearImageSizeStyles(content);\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n if (isAttachmentUploadCompleted(inlineImages)) {\n insertImagesToContentString(textValue, inlineImages, (content) => {\n onSubmit(content, /* @conditional-compile-remove(file-sharing-acs) */ attachmentMetadata || []);\n });\n return;\n }\n // it's very important to pass an empty attachment here\n // so when user removes all attachments, UI can reflect it instantly\n // if you set it to undefined, the attachments pre-edited would still be there\n // until edit message event is received\n onSubmit(content, /* @conditional-compile-remove(file-sharing-acs) */ attachmentMetadata || []);\n }, [\n submitEnabled,\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n inlineImages,\n textValue,\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n strings.imageUploadsPendingError,\n onSubmit,\n /* @conditional-compile-remove(file-sharing-acs) */\n attachmentMetadata\n ]);\n\n const actionButtons = useMemo(() => {\n return (\n <Stack horizontal>\n <InputBoxButton\n className={richTextActionButtonsStyle}\n ariaLabel={strings.editBoxCancelButton}\n tooltipContent={strings.editBoxCancelButton}\n onRenderIcon={onRenderThemedCancelIcon}\n onClick={() => {\n onCancel && onCancel(message.messageId);\n }}\n id={'dismissIconWrapper'}\n data-testId={strings.editBoxCancelButton}\n />\n <InputBoxButton\n className={richTextActionButtonsStyle}\n ariaLabel={strings.editBoxSubmitButton}\n tooltipContent={strings.editBoxSubmitButton}\n onRenderIcon={onRenderThemedSubmitIcon}\n onClick={(e) => {\n onSubmitHandler();\n e.stopPropagation();\n }}\n id={'submitIconWrapper'}\n data-testId={strings.editBoxSubmitButton}\n />\n </Stack>\n );\n }, [\n message.messageId,\n onCancel,\n onRenderThemedCancelIcon,\n onRenderThemedSubmitIcon,\n strings.editBoxCancelButton,\n strings.editBoxSubmitButton,\n onSubmitHandler\n ]);\n const richTextLocaleStrings = useMemo(() => {\n /* @conditional-compile-remove(rich-text-editor) */\n return { ...locale.richTextSendBox, ...strings };\n return locale.sendBox;\n }, [\n /* @conditional-compile-remove(rich-text-editor) */ locale.richTextSendBox,\n /* @conditional-compile-remove(rich-text-editor) */ strings,\n locale.sendBox\n ]);\n\n /* @conditional-compile-remove(file-sharing-acs) */\n const onCancelAttachmentUpload = useCallback((attachmentId: string) => {\n // edit box only capable of removing attachments\n // we need to expand attachment actions\n // if we want to support more actions e.g. add\n handleAttachmentAction({ type: 'remove', id: attachmentId });\n }, []);\n\n /* @conditional-compile-remove(file-sharing-acs) */\n const onRenderAttachmentUploads = useCallback(() => {\n return (\n <Stack className={attachmentUploadCardsStyles}>\n <FluentV9ThemeProvider v8Theme={theme}>\n <_AttachmentUploadCards\n attachments={attachmentMetadata}\n onCancelAttachmentUpload={onCancelAttachmentUpload}\n />\n </FluentV9ThemeProvider>\n </Stack>\n );\n }, [attachmentMetadata, onCancelAttachmentUpload, theme]);\n\n const onChangeHandler = useCallback(\n (\n content: string | undefined,\n /* @conditional-compile-remove(rich-text-editor-image-upload) */ imageSrcArray?: Array<string>\n ) => {\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n cancelInlineImageUpload({\n imageSrcArray,\n inlineImages,\n messageId: message.messageId,\n editBoxOnCancelInlineImageUpload: onCancelInlineImageUpload,\n sendBoxOnCancelInlineImageUpload: undefined\n });\n setText(content);\n },\n [\n setText,\n /* @conditional-compile-remove(rich-text-editor-image-upload) */ inlineImages,\n /* @conditional-compile-remove(rich-text-editor-image-upload) */ onCancelInlineImageUpload,\n /* @conditional-compile-remove(rich-text-editor-image-upload) */ message.messageId\n ]\n );\n\n const getContent = (): JSX.Element => {\n return (\n <Stack className={mergeStyles(editBoxWidthStyles)}>\n <RichTextSendBoxErrors\n textTooLongMessage={textTooLongMessage}\n systemMessage={message.failureReason}\n /* @conditional-compile-remove(rich-text-editor-image-upload) */ attachmentUploadsPendingError={\n attachmentUploadsPendingError\n }\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n attachmentProgressError={\n imageUploadErrorMessage\n ? {\n message: imageUploadErrorMessage,\n timestamp: Date.now(),\n errorBarType: SendBoxErrorBarType.error\n }\n : undefined\n }\n />\n <RichTextInputBoxComponent\n placeholderText={strings.editBoxPlaceholderText}\n onChange={onChangeHandler}\n editorComponentRef={editTextFieldRef}\n initialContent={initialContent}\n strings={richTextLocaleStrings}\n disabled={false}\n actionComponents={actionButtons}\n richTextEditorStyleProps={editBoxRichTextEditorStyle}\n isHorizontalLayoutDisabled={true}\n /* @conditional-compile-remove(file-sharing-acs) */\n onRenderAttachmentUploads={onRenderAttachmentUploads}\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n onPaste={onPaste}\n /* @conditional-compile-remove(rich-text-editor-image-upload) */\n onInsertInlineImage={(imageUrl: string, imageFileName: string) => {\n onInsertInlineImage && onInsertInlineImage(imageUrl, imageFileName, message.messageId);\n }}\n />\n </Stack>\n );\n };\n\n const attached = message.attached === true ? 'center' : message.attached === 'bottom' ? 'bottom' : 'top';\n return (\n <ChatMyMessage\n attached={attached}\n root={{\n className: mergeClasses(\n chatMyMessageStyles.root,\n /* @conditional-compile-remove(file-sharing-acs) */\n hasMultipleAttachments ? chatMyMessageStyles.multipleAttachmentsInEditing : undefined\n )\n }}\n body={{\n className: mergeClasses(\n editContainerStyles.body,\n attached !== 'top' ? editContainerStyles.bodyAttached : undefined\n )\n }}\n >\n {getContent()}\n </ChatMyMessage>\n );\n};\n\nexport default ChatMessageComponentAsRichTextEditBox;\n"],"names":["useMemo","BROKEN_IMAGE_SVG_DATA","useState","useReducer","attachmentMetadataReducer","getMessageWithAttachmentMetadata","useTheme","getMessageState","useChatMessageRichTextEditContainerStyles","useChatMyMessageStyles","useLocale","useCallback","useEffect","_formatString","MAXIMUM_LENGTH_OF_MESSAGE","mergeStyles","richTextEditBoxActionButtonIcon","onRenderCancelIcon","onRenderSubmitIcon","doesMessageContainMultipleAttachments","hasIncompleteAttachmentUploads","SendBoxErrorBarType","removeBrokenImageContentAndClearImageSizeStyles","isAttachmentUploadCompleted","insertImagesToContentString","Stack","InputBoxButton","richTextActionButtonsStyle","attachmentUploadCardsStyles","FluentV9ThemeProvider","_AttachmentUploadCards","cancelInlineImageUpload","editBoxWidthStyles","RichTextSendBoxErrors","RichTextInputBoxComponent","editBoxRichTextEditorStyle","ChatMyMessage","mergeClasses"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AA2EA;;AAEG;AACU,MAAA,qCAAqC,GAAG,CACnD,KAAiD,KAClC;;AACf,IAAA,MAAM,EACJ,QAAQ,EACR,QAAQ,EACR,OAAO,EACP,OAAO;;IAEP,OAAO;;IAEP,mBAAmB;;IAEnB,YAAY;;IAEZ,yBAAyB,EAC1B,GAAG,KAAK,CAAC;AAEV,IAAA,MAAM,cAAc,GAAGA,a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SAAS,EAAEC,4BAAY,CACrB,mBAAmB,CAAC,IAAI;;YAExB,sBAAsB,GAAG,mBAAmB,CAAC,4BAA4B,GAAG,SAAS,CACtF;AACF,SAAA,EACD,IAAI,EAAE;YACJ,SAAS,EAAEA,4BAAY,CACrB,mBAAmB,CAAC,IAAI,EACxB,QAAQ,KAAK,KAAK,GAAG,mBAAmB,CAAC,YAAY,GAAG,SAAS,CAClE;AACF,SAAA,EAAA,EAEA,UAAU,EAAE,CACC,EAChB;AACJ;;;;;"}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
'use strict';
|
2
2
|
|
3
3
|
var React = require('react');
|
4
|
-
var index = require('./index-
|
4
|
+
var index = require('./index-Dl3wPPJe.js');
|
5
5
|
require('@fluentui/react');
|
6
6
|
require('@fluentui/react-components');
|
7
7
|
require('@fluentui-contrib/react-chat');
|
@@ -9,7 +9,6 @@ require('@azure/communication-common');
|
|
9
9
|
require('@fluentui/react-hooks');
|
10
10
|
require('react-use-draggable-scroll');
|
11
11
|
require('copy-to-clipboard');
|
12
|
-
require('libphonenumber-js');
|
13
12
|
require('react-dom/client');
|
14
13
|
require('@azure/communication-chat');
|
15
14
|
require('events');
|
@@ -51,4 +50,4 @@ const RichTextSendBoxWrapper = (props) => {
|
|
51
50
|
};
|
52
51
|
|
53
52
|
exports.RichTextSendBoxWrapper = RichTextSendBoxWrapper;
|
54
|
-
//# sourceMappingURL=RichTextSendBoxWrapper-
|
53
|
+
//# sourceMappingURL=RichTextSendBoxWrapper-OHSjE5aJ.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"RichTextSendBoxWrapper-
|
1
|
+
{"version":3,"file":"RichTextSendBoxWrapper-OHSjE5aJ.js","sources":["../../../../react-composites/src/composites/common/RichTextSendBoxWrapper.tsx"],"sourcesContent":["// Copyright (c) Microsoft Corporation.\n// Licensed under the MIT License.\n\n/* @conditional-compile-remove(rich-text-editor-composite-support) */\nimport React from 'react';\n/* @conditional-compile-remove(rich-text-editor-composite-support) */\nimport { usePropsFor } from '../ChatComposite/hooks/usePropsFor';\n/* @conditional-compile-remove(rich-text-editor-composite-support) */\nimport { RichTextSendBox, RichTextSendBoxProps } from '@internal/react-components';\n\n/* @conditional-compile-remove(rich-text-editor-composite-support) */\n/**\n * @private\n *\n * Wrapper for RichTextSendBox component to allow us to use usePropsFor with richTextSendBox\n * before lazyLoading is done\n */\nexport const RichTextSendBoxWrapper = (props: RichTextSendBoxProps): JSX.Element => {\n const richTextSendBoxProps = usePropsFor(RichTextSendBox);\n\n return <RichTextSendBox {...richTextSendBoxProps} {...props} />;\n};\n"],"names":["usePropsFor","RichTextSendBox"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AAEA;AAOA;AACA;;;;;AAKG;AACU,MAAA,sBAAsB,GAAG,CAAC,KAA2B,KAAiB;AACjF,IAAA,MAAM,oBAAoB,GAAGA,iBAAW,CAACC,qBAAe,CAAC,CAAC;AAE1D,IAAA,OAAO,oBAACA,qBAAe,EAAA,MAAA,CAAA,MAAA,CAAA,EAAA,EAAK,oBAAoB,EAAM,KAAK,EAAI,CAAC;AAClE;;;;"}
|