@azure/communication-react
Version:
React library for building modern communication user experiences utilizing Azure Communication Services
46 lines • 2.79 kB
TypeScript
import { StartCallOptions } from '@azure/communication-calling';
import { TeamsCall, TeamsCallAgent } from '@azure/communication-calling';
import { CommunicationIdentifier } from '@azure/communication-common';
import { Common } from "../../../acs-ui-common/src";
import { StatefulCallClient, StatefulDeviceManager } from "../../../calling-stateful-client/src";
import { ReactElement } from 'react';
import { CommonCallingHandlers, DeepNoiseSuppressionEffectDependency, VideoBackgroundEffectsDependency } from './createCommonHandlers';
/**
* Object containing all the teams call handlers required for calling components.
*
* Calling related components from this package are able to pick out relevant handlers from this object.
* See {@link useHandlers} and {@link usePropsFor}.
*
* @public
*/
export interface TeamsCallingHandlers extends CommonCallingHandlers {
onStartCall: (participants: CommunicationIdentifier[], options?: StartCallOptions) => undefined | TeamsCall;
}
/**
* Create the default implementation of {@link TeamsCallingHandlers} for teams call.
*
* Useful when implementing a custom component that utilizes the providers
* exported from this library.
*
* @public
*/
export declare const createDefaultTeamsCallingHandlers: (callClient: StatefulCallClient, callAgent?: TeamsCallAgent, deviceManager?: StatefulDeviceManager, call?: TeamsCall, options?: {
onResolveVideoBackgroundEffectsDependency?: () => Promise<VideoBackgroundEffectsDependency>;
onResolveDeepNoiseSuppressionDependency?: () => Promise<DeepNoiseSuppressionEffectDependency>;
}) => TeamsCallingHandlers;
/**
* Create a set of default handlers for given component. Memoization is applied to the result. Multiple invocations with
* the same arguments will return the same handler instances. DeclarativeCallAgent, DeclarativeDeviceManager, and
* DeclarativeCall may be undefined. If undefined, their associated handlers will not be created and returned.
*
* @param callClient - StatefulCallClient returned from
* {@link @azure/communication-react#createStatefulCallClient}.
* @param callAgent - Instance of {@link @azure/communication-calling#TeamsCallClient}.
* @param deviceManager - Instance of {@link @azure/communication-calling#DeviceManager}.
* @param call - Instance of {@link @azure/communication-calling#TeamsCall}.
* @param _ - React component that you want to generate handlers for.
*
* @public
*/
export declare const createTeamsCallingHandlersForComponent: <Props>(callClient: StatefulCallClient, callAgent: undefined | TeamsCallAgent, deviceManager: StatefulDeviceManager | undefined, call: undefined | TeamsCall, _Component: (props: Props) => ReactElement | null) => Common<TeamsCallingHandlers, Props>;
//# sourceMappingURL=createTeamsCallHandlers.d.ts.map