CometChatIncomingCall
is a Component that serves as a visual representation when the user receives an incoming call, such as a voice call or video call, providing options to answer or decline the call.
CometChatIncomingCall
being a custom component, offers versatility in its integration. It can be seamlessly launched via button clicks or any user-triggered action, enhancing the overall user experience and facilitating smoother interactions within the application.
onAccept
is triggered when you click the accept button of the Incoming Call
component. You can override this action using the following code snippet.
onDecline
is triggered when you click the Decline button of the Incoming Call
component. This action does not have a predefined behavior. You can override this action using the following code snippet.
Component
. By using event you can extend existing functionality. Being global events, they can be applied in Multiple Locations and are capable of being Added or Removed.
The list of events emitted by the Incoming Call component is as follows.
Event | Description |
---|---|
ccCallRejected | This event is triggered when the initiated call is rejected by the receiver. |
ccCallAccepted | This event is triggered when the initiated call is accepted by the receiver. |
ccCallEnded | This event is triggered when the initiated call successfully ends. |
ccCallFailled | This event is triggered when an error occurs during the intiated call. |
IncomingCall
Component by applying the IncomingCallStyle
to it using the following code snippet.
Property | Description | Code |
---|---|---|
call | CometChat call object consumed by the component to launch itself | disableSoundForMessages={true} |
customSoundForCalls | Used to set custom sound for incoming calls | customSoundForCalls?: string |
disableSoundForCalls | Used to disable/enable the sound of incoming calls, by default it is set to false | disableSoundForCalls?: string |