@webex/cc-task 1.28.0-ccwidgets.99 → 1.28.0-next.10
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/index.js +111 -111
- package/dist/types/OutdialCall/index.d.ts +2 -1
- package/dist/types/Utils/constants.d.ts +15 -0
- package/dist/types/Utils/task-util.d.ts +118 -16
- package/dist/types/Utils/timer-utils.d.ts +29 -0
- package/dist/types/Utils/useHoldTimer.d.ts +9 -0
- package/dist/types/helper.d.ts +67 -26
- package/dist/types/task.types.d.ts +27 -7
- package/package.json +9 -6
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const MEDIA_TYPE_TELEPHONY = "telephony";
|
|
2
|
+
export declare const MEDIA_TYPE_CHAT = "chat";
|
|
3
|
+
export declare const MEDIA_TYPE_EMAIL = "email";
|
|
4
|
+
export declare const MAX_PARTICIPANTS_IN_MULTIPARTY_CONFERENCE = 7;
|
|
5
|
+
export declare enum DestinationAgentType {
|
|
6
|
+
EP_DN = "EpDn",
|
|
7
|
+
EPDN = "EPDN",
|
|
8
|
+
ENTRY_POINT = "EntryPoint",
|
|
9
|
+
EP = "EP"
|
|
10
|
+
}
|
|
11
|
+
export declare const TIMER_LABEL_WRAP_UP = "Wrap Up";
|
|
12
|
+
export declare const TIMER_LABEL_POST_CALL = "Post Call";
|
|
13
|
+
export declare const TIMER_LABEL_CONSULT_ON_HOLD = "Consult on Hold";
|
|
14
|
+
export declare const TIMER_LABEL_CONSULT_REQUESTED = "Consult Requested";
|
|
15
|
+
export declare const TIMER_LABEL_CONSULTING = "Consulting";
|
|
@@ -1,23 +1,125 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ILogger } from '@webex/cc-store';
|
|
2
|
+
import { ITask, Interaction } from '@webex/contact-center';
|
|
3
|
+
import { Visibility } from '@webex/cc-components';
|
|
4
|
+
export declare function findHoldTimestamp(interaction: Interaction, mType?: string): number | null;
|
|
5
|
+
/**
|
|
6
|
+
* Get visibility for Accept button
|
|
7
|
+
*/
|
|
8
|
+
export declare function getAcceptButtonVisibility(isBrowser: boolean, isPhoneDevice: boolean, webRtcEnabled: boolean, isCall: boolean, isDigitalChannel: boolean): Visibility;
|
|
9
|
+
/**
|
|
10
|
+
* Get visibility for Decline button
|
|
11
|
+
*/
|
|
12
|
+
export declare function getDeclineButtonVisibility(isBrowser: boolean, webRtcEnabled: boolean, isCall: boolean): Visibility;
|
|
13
|
+
/**
|
|
14
|
+
* Get visibility for End button (matches Agent Desktop behavior)
|
|
15
|
+
*/
|
|
16
|
+
export declare function getEndButtonVisibility(isBrowser: boolean, isEndCallEnabled: boolean, isCall: boolean, isConsultInitiatedOrAcceptedOrBeingConsulted: boolean, isConferenceInProgress: boolean, isConsultCompleted: boolean, isHeld: boolean, consultCallHeld: boolean, task?: ITask, agentId?: string): Visibility;
|
|
17
|
+
/**
|
|
18
|
+
* Get visibility for Mute/Unmute button
|
|
19
|
+
*/
|
|
20
|
+
export declare function getMuteUnmuteButtonVisibility(isBrowser: boolean, webRtcEnabled: boolean, isCall: boolean, isBeingConsulted: boolean): Visibility;
|
|
21
|
+
/**
|
|
22
|
+
* Get visibility for Hold/Resume button
|
|
23
|
+
*/
|
|
24
|
+
export declare function getHoldResumeButtonVisibility(isTelephonySupported: boolean, isCall: boolean, isConferenceInProgress: boolean, isConsultInProgress: boolean, isHeld: boolean, isBeingConsulted: boolean, isConsultCompleted: boolean): Visibility;
|
|
25
|
+
/**
|
|
26
|
+
* Get visibility for Pause/Resume Recording button
|
|
27
|
+
*/
|
|
28
|
+
export declare function getPauseResumeRecordingButtonVisibility(isTelephonySupported: boolean, isCall: boolean, isConferenceInProgress: boolean, isConsultInitiatedOrAccepted: boolean): Visibility;
|
|
29
|
+
/**
|
|
30
|
+
* Get visibility for Recording Indicator
|
|
31
|
+
*/
|
|
32
|
+
export declare function getRecordingIndicatorVisibility(isCall: boolean): Visibility;
|
|
33
|
+
/**
|
|
34
|
+
* Get visibility for Transfer button
|
|
35
|
+
*/
|
|
36
|
+
export declare function getTransferButtonVisibility(isTransferVisibility: boolean, isConferenceInProgress: boolean, isConsultInitiatedOrAccepted: boolean): Visibility;
|
|
37
|
+
/**
|
|
38
|
+
* Get visibility for Conference button
|
|
39
|
+
*/
|
|
40
|
+
export declare function getConferenceButtonVisibility(isBrowser: boolean, webRtcEnabled: boolean, isCall: boolean, isChat: boolean, isBeingConsulted: boolean, conferenceEnabled: boolean): Visibility;
|
|
41
|
+
/**
|
|
42
|
+
* Get visibility for Exit Conference button
|
|
43
|
+
*/
|
|
44
|
+
export declare function getExitConferenceButtonVisibility(isConferenceInProgress: boolean, isConsultInitiatedOrAccepted: boolean, consultCallHeld: boolean, isHeld: boolean, isConsultCompleted: boolean, conferenceEnabled: boolean): Visibility;
|
|
45
|
+
/**
|
|
46
|
+
* Get visibility for Merge Conference button
|
|
47
|
+
*/
|
|
48
|
+
export declare function getMergeConferenceButtonVisibility(isConsultInitiatedOrAccepted: boolean, isConsultAccepted: boolean, consultCallHeld: boolean, isConferenceInProgress: boolean, isCustomerInCall: boolean, conferenceEnabled: boolean): Visibility;
|
|
49
|
+
/**
|
|
50
|
+
* Get visibility for Consult button
|
|
51
|
+
*/
|
|
52
|
+
export declare function getConsultButtonVisibility(isTelephonySupported: boolean, isCall: boolean, isConsultInProgress: boolean, isCustomerInCall: boolean, conferenceParticipantsCount: number, maxParticipantsInConference: number, isBeingConsulted: boolean, isHeld: boolean, isConsultCompleted: boolean, isConferenceInProgress: boolean): Visibility;
|
|
53
|
+
/**
|
|
54
|
+
* Get visibility for End Consult button
|
|
55
|
+
*/
|
|
56
|
+
export declare function getEndConsultButtonVisibility(isEndConsultEnabled: boolean, isTelephonySupported: boolean, isCall: boolean, isConsultInitiatedOrAccepted: boolean): Visibility;
|
|
57
|
+
/**
|
|
58
|
+
* Get visibility for Consult Transfer button
|
|
59
|
+
*/
|
|
60
|
+
export declare function getConsultTransferButtonVisibility(isConsultInitiatedOrAccepted: boolean, isConsultAccepted: boolean, consultCallHeld: boolean, isConferenceInProgress: boolean, isCustomerInCall: boolean): Visibility;
|
|
61
|
+
/**
|
|
62
|
+
* Get visibility for Merge Conference Consult button
|
|
63
|
+
*/
|
|
64
|
+
export declare function getMergeConferenceConsultButtonVisibility(isConsultAccepted: boolean, isConsultInitiated: boolean, consultCallHeld: boolean, isCustomerInCall: boolean, conferenceEnabled: boolean): Visibility;
|
|
65
|
+
/**
|
|
66
|
+
* Get visibility for Consult Transfer Consult button
|
|
67
|
+
*/
|
|
68
|
+
export declare function getConsultTransferConsultButtonVisibility(isConsultAccepted: boolean, isConsultInitiated: boolean, consultCallHeld: boolean, isCustomerInCall: boolean): Visibility;
|
|
69
|
+
/**
|
|
70
|
+
* Get visibility for Mute/Unmute Consult button
|
|
71
|
+
*/
|
|
72
|
+
export declare function getMuteUnmuteConsultButtonVisibility(isBrowser: boolean, webRtcEnabled: boolean, isCall: boolean, isConsultInitiated: boolean, isBeingConsulted: boolean): Visibility;
|
|
73
|
+
/**
|
|
74
|
+
* Get visibility for Switch to Main Call button
|
|
75
|
+
*/
|
|
76
|
+
export declare function getSwitchToMainCallButtonVisibility(isBeingConsulted: boolean, isConsultAccepted: boolean, isConsultInitiated: boolean, consultCallHeld: boolean, isCustomerInCall: boolean, isConferenceInProgress: boolean): Visibility;
|
|
77
|
+
/**
|
|
78
|
+
* Get visibility for Switch to Consult button
|
|
79
|
+
*/
|
|
80
|
+
export declare function getSwitchToConsultButtonVisibility(isBeingConsulted: boolean, consultCallHeld: boolean): Visibility;
|
|
81
|
+
/**
|
|
82
|
+
* Get visibility for Wrapup button
|
|
83
|
+
*/
|
|
84
|
+
export declare function getWrapupButtonVisibility(task: ITask): Visibility;
|
|
2
85
|
/**
|
|
3
86
|
* This function determines the visibility of various controls based on the task's data.
|
|
87
|
+
* @param deviceType The device type (Browser, Extension, AgentDN)
|
|
88
|
+
* @param featureFlags Feature flags configuration object
|
|
4
89
|
* @param task The task object
|
|
5
|
-
* @
|
|
90
|
+
* @param agentId The agent ID
|
|
91
|
+
* @param conferenceEnabled Whether conference is enabled
|
|
92
|
+
* @param logger Optional logger instance
|
|
93
|
+
* @returns An object containing the visibility and state of various controls
|
|
6
94
|
*/
|
|
7
95
|
export declare function getControlsVisibility(deviceType: string, featureFlags: {
|
|
8
96
|
[key: string]: boolean;
|
|
9
|
-
}, task: ITask): {
|
|
10
|
-
accept:
|
|
11
|
-
decline:
|
|
12
|
-
end:
|
|
13
|
-
muteUnmute:
|
|
14
|
-
holdResume:
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
97
|
+
}, task: ITask, agentId: string, conferenceEnabled: boolean, logger?: ILogger): {
|
|
98
|
+
accept: Visibility;
|
|
99
|
+
decline: Visibility;
|
|
100
|
+
end: Visibility;
|
|
101
|
+
muteUnmute: Visibility;
|
|
102
|
+
holdResume: Visibility;
|
|
103
|
+
pauseResumeRecording: Visibility;
|
|
104
|
+
recordingIndicator: Visibility;
|
|
105
|
+
transfer: Visibility;
|
|
106
|
+
conference: Visibility;
|
|
107
|
+
exitConference: Visibility;
|
|
108
|
+
mergeConference: Visibility;
|
|
109
|
+
consult: Visibility;
|
|
110
|
+
endConsult: Visibility;
|
|
111
|
+
consultTransfer: Visibility;
|
|
112
|
+
consultTransferConsult: Visibility;
|
|
113
|
+
mergeConferenceConsult: Visibility;
|
|
114
|
+
muteUnmuteConsult: Visibility;
|
|
115
|
+
switchToMainCall: Visibility;
|
|
116
|
+
switchToConsult: Visibility;
|
|
117
|
+
wrapup: Visibility;
|
|
118
|
+
isConferenceInProgress: boolean;
|
|
119
|
+
isConsultInitiated: boolean;
|
|
120
|
+
isConsultInitiatedAndAccepted: boolean;
|
|
121
|
+
isConsultReceived: boolean;
|
|
122
|
+
isConsultInitiatedOrAccepted: boolean;
|
|
123
|
+
isHeld: boolean;
|
|
124
|
+
consultCallHeld: boolean;
|
|
22
125
|
};
|
|
23
|
-
export declare function findHoldTimestamp(interaction: Interaction, mType?: string): number | null;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { ITask } from '@webex/cc-store';
|
|
2
|
+
import { ControlVisibility } from '@webex/cc-components';
|
|
3
|
+
/**
|
|
4
|
+
* Timer data structure containing label and timestamp
|
|
5
|
+
*/
|
|
6
|
+
export interface TimerData {
|
|
7
|
+
label: string | null;
|
|
8
|
+
timestamp: number;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Calculate state timer label and timestamp based on task state.
|
|
12
|
+
* Priority: Wrap Up > Post Call
|
|
13
|
+
*
|
|
14
|
+
* @param currentTask - The current task object
|
|
15
|
+
* @param controlVisibility - Control visibility flags
|
|
16
|
+
* @param agentId - The current agent ID
|
|
17
|
+
* @returns TimerData object with label and timestamp
|
|
18
|
+
*/
|
|
19
|
+
export declare function calculateStateTimerData(currentTask: ITask | null, controlVisibility: ControlVisibility | null, agentId: string): TimerData;
|
|
20
|
+
/**
|
|
21
|
+
* Calculate consult timer label and timestamp based on consult state.
|
|
22
|
+
* Handles consult on hold vs active consulting states.
|
|
23
|
+
*
|
|
24
|
+
* @param currentTask - The current task object
|
|
25
|
+
* @param controlVisibility - Control visibility flags
|
|
26
|
+
* @param agentId - The current agent ID
|
|
27
|
+
* @returns TimerData object with label and timestamp
|
|
28
|
+
*/
|
|
29
|
+
export declare function calculateConsultTimerData(currentTask: ITask | null, controlVisibility: ControlVisibility | null, agentId: string): TimerData;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ITask } from '@webex/cc-store';
|
|
2
|
+
/**
|
|
3
|
+
* Custom hook to manage hold timer using a Web Worker
|
|
4
|
+
* Prioritizes consult hold over main call hold
|
|
5
|
+
*
|
|
6
|
+
* @param currentTask - The current task object
|
|
7
|
+
* @returns holdTime - The elapsed time in seconds since the call was put on hold
|
|
8
|
+
*/
|
|
9
|
+
export declare const useHoldTimer: (currentTask: ITask | null) => number;
|
package/dist/types/helper.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { ITask } from '@webex/
|
|
2
|
-
import { useCallControlProps, UseTaskListProps, UseTaskProps, useOutdialCallProps } from './task.types';
|
|
3
|
-
import { BuddyDetails, DestinationType,
|
|
1
|
+
import { AddressBookEntriesResponse, AddressBookEntrySearchParams, ITask } from '@webex/contact-center';
|
|
2
|
+
import { useCallControlProps, UseTaskListProps, UseTaskProps, useOutdialCallProps, TargetType } from './task.types';
|
|
3
|
+
import { BuddyDetails, DestinationType, PaginatedListParams, Participant } from '@webex/cc-store';
|
|
4
|
+
import { OutdialAniEntriesResponse } from '@webex/contact-center/dist/types/services/config/types';
|
|
4
5
|
export declare const useTaskList: (props: UseTaskListProps) => {
|
|
5
6
|
taskList: Record<string, ITask>;
|
|
6
7
|
acceptTask: (task: ITask) => void;
|
|
@@ -13,6 +14,7 @@ export declare const useIncomingTask: (props: UseTaskProps) => {
|
|
|
13
14
|
accept: () => void;
|
|
14
15
|
reject: () => void;
|
|
15
16
|
isBrowser: boolean;
|
|
17
|
+
isDeclineButtonEnabled: boolean;
|
|
16
18
|
};
|
|
17
19
|
export declare const useCallControl: (props: useCallControlProps) => {
|
|
18
20
|
currentTask: ITask;
|
|
@@ -22,43 +24,82 @@ export declare const useCallControl: (props: useCallControlProps) => {
|
|
|
22
24
|
toggleMute: () => Promise<void>;
|
|
23
25
|
isMuted: boolean;
|
|
24
26
|
wrapupCall: (wrapUpReason: string, auxCodeId: string) => void;
|
|
25
|
-
isHeld: boolean;
|
|
26
|
-
setIsHeld: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
27
27
|
isRecording: boolean;
|
|
28
28
|
setIsRecording: import("react").Dispatch<import("react").SetStateAction<boolean>>;
|
|
29
29
|
buddyAgents: BuddyDetails[];
|
|
30
|
+
loadingBuddyAgents: boolean;
|
|
30
31
|
loadBuddyAgents: () => Promise<void>;
|
|
31
|
-
queues: ContactServiceQueue[];
|
|
32
|
-
loadQueues: () => Promise<void>;
|
|
33
32
|
transferCall: (to: string, type: DestinationType) => Promise<void>;
|
|
34
|
-
consultCall: (consultDestination: string, destinationType: DestinationType) => Promise<void>;
|
|
33
|
+
consultCall: (consultDestination: string, destinationType: DestinationType, allowParticipantsToInteract: boolean) => Promise<void>;
|
|
35
34
|
endConsultCall: () => Promise<void>;
|
|
36
|
-
consultTransfer: (
|
|
35
|
+
consultTransfer: () => Promise<void>;
|
|
36
|
+
consultConference: () => Promise<void>;
|
|
37
|
+
switchToMainCall: () => Promise<void>;
|
|
38
|
+
switchToConsult: () => Promise<void>;
|
|
39
|
+
exitConference: () => Promise<void>;
|
|
37
40
|
consultAgentName: string;
|
|
38
41
|
setConsultAgentName: import("react").Dispatch<import("react").SetStateAction<string>>;
|
|
39
|
-
consultAgentId: string;
|
|
40
|
-
setConsultAgentId: import("react").Dispatch<import("react").SetStateAction<string>>;
|
|
41
42
|
holdTime: number;
|
|
42
43
|
startTimestamp: number;
|
|
43
|
-
|
|
44
|
-
|
|
44
|
+
stateTimerLabel: string;
|
|
45
|
+
stateTimerTimestamp: number;
|
|
46
|
+
consultTimerLabel: string;
|
|
47
|
+
consultTimerTimestamp: number;
|
|
48
|
+
lastTargetType: TargetType;
|
|
49
|
+
setLastTargetType: import("react").Dispatch<import("react").SetStateAction<TargetType>>;
|
|
45
50
|
controlVisibility: {
|
|
46
|
-
accept:
|
|
47
|
-
decline:
|
|
48
|
-
end:
|
|
49
|
-
muteUnmute:
|
|
50
|
-
holdResume:
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
51
|
+
accept: import("@webex/cc-components").Visibility;
|
|
52
|
+
decline: import("@webex/cc-components").Visibility;
|
|
53
|
+
end: import("@webex/cc-components").Visibility;
|
|
54
|
+
muteUnmute: import("@webex/cc-components").Visibility;
|
|
55
|
+
holdResume: import("@webex/cc-components").Visibility;
|
|
56
|
+
pauseResumeRecording: import("@webex/cc-components").Visibility;
|
|
57
|
+
recordingIndicator: import("@webex/cc-components").Visibility;
|
|
58
|
+
transfer: import("@webex/cc-components").Visibility;
|
|
59
|
+
conference: import("@webex/cc-components").Visibility;
|
|
60
|
+
exitConference: import("@webex/cc-components").Visibility;
|
|
61
|
+
mergeConference: import("@webex/cc-components").Visibility;
|
|
62
|
+
consult: import("@webex/cc-components").Visibility;
|
|
63
|
+
endConsult: import("@webex/cc-components").Visibility;
|
|
64
|
+
consultTransfer: import("@webex/cc-components").Visibility;
|
|
65
|
+
consultTransferConsult: import("@webex/cc-components").Visibility;
|
|
66
|
+
mergeConferenceConsult: import("@webex/cc-components").Visibility;
|
|
67
|
+
muteUnmuteConsult: import("@webex/cc-components").Visibility;
|
|
68
|
+
switchToMainCall: import("@webex/cc-components").Visibility;
|
|
69
|
+
switchToConsult: import("@webex/cc-components").Visibility;
|
|
70
|
+
wrapup: import("@webex/cc-components").Visibility;
|
|
71
|
+
isConferenceInProgress: boolean;
|
|
72
|
+
isConsultInitiated: boolean;
|
|
73
|
+
isConsultInitiatedAndAccepted: boolean;
|
|
74
|
+
isConsultReceived: boolean;
|
|
75
|
+
isConsultInitiatedOrAccepted: boolean;
|
|
76
|
+
isHeld: boolean;
|
|
77
|
+
consultCallHeld: boolean;
|
|
58
78
|
};
|
|
59
79
|
secondsUntilAutoWrapup: number;
|
|
60
80
|
cancelAutoWrapup: () => void;
|
|
81
|
+
conferenceParticipants: Participant[];
|
|
82
|
+
getAddressBookEntries: ({ page, pageSize, search }: PaginatedListParams) => Promise<AddressBookEntriesResponse>;
|
|
83
|
+
getEntryPoints: ({ page, pageSize, search }: PaginatedListParams) => Promise<import("@webex/contact-center").EntryPointListResponse>;
|
|
84
|
+
getQueuesFetcher: ({ page, pageSize, search }: PaginatedListParams) => Promise<{
|
|
85
|
+
data: import("@webex/contact-center").ContactServiceQueue[];
|
|
86
|
+
meta: {
|
|
87
|
+
page: number;
|
|
88
|
+
pageSize: number;
|
|
89
|
+
total: number;
|
|
90
|
+
totalPages: number;
|
|
91
|
+
};
|
|
92
|
+
} | {
|
|
93
|
+
data: any[];
|
|
94
|
+
meta: {
|
|
95
|
+
page: number;
|
|
96
|
+
totalPages: number;
|
|
97
|
+
};
|
|
98
|
+
}>;
|
|
61
99
|
};
|
|
62
100
|
export declare const useOutdialCall: (props: useOutdialCallProps) => {
|
|
63
|
-
startOutdial: (destination: string) => void;
|
|
101
|
+
startOutdial: (destination: string, origin?: string) => void;
|
|
102
|
+
getOutdialANIEntries: () => Promise<OutdialAniEntriesResponse>;
|
|
103
|
+
getAddressBookEntries: (params: AddressBookEntrySearchParams) => Promise<AddressBookEntriesResponse>;
|
|
104
|
+
isTelephonyTaskActive: boolean;
|
|
64
105
|
};
|
|
@@ -3,11 +3,31 @@ export type UseTaskProps = Pick<TaskProps, 'incomingTask' | 'deviceType' | 'logg
|
|
|
3
3
|
export type UseTaskListProps = Pick<TaskProps, 'cc' | 'taskList' | 'deviceType' | 'logger'> & Partial<Pick<TaskProps, 'onTaskAccepted' | 'onTaskDeclined' | 'onTaskSelected'>>;
|
|
4
4
|
export type IncomingTaskProps = Pick<TaskProps, 'incomingTask'> & Partial<Pick<TaskProps, 'onAccepted' | 'onRejected'>>;
|
|
5
5
|
export type TaskListProps = Partial<Pick<TaskProps, 'onTaskAccepted' | 'onTaskDeclined' | 'onTaskSelected'>>;
|
|
6
|
-
export type CallControlProps = Partial<Pick<ControlProps, 'onHoldResume' | 'onEnd' | 'onWrapUp' | 'onRecordingToggle' | 'callControlClassName' | 'callControlConsultClassName' | 'onToggleMute'>>;
|
|
7
|
-
export type useCallControlProps = Pick<ControlProps, 'currentTask' | 'logger' | '
|
|
8
|
-
export type Participant = {
|
|
9
|
-
id: string;
|
|
10
|
-
pType: 'Customer' | 'Agent' | string;
|
|
11
|
-
name?: string;
|
|
12
|
-
};
|
|
6
|
+
export type CallControlProps = Partial<Pick<ControlProps, 'onHoldResume' | 'onEnd' | 'onWrapUp' | 'onRecordingToggle' | 'callControlClassName' | 'callControlConsultClassName' | 'onToggleMute' | 'conferenceEnabled' | 'consultTransferOptions'>>;
|
|
7
|
+
export type useCallControlProps = Pick<ControlProps, 'currentTask' | 'logger' | 'deviceType' | 'featureFlags' | 'isMuted' | 'conferenceEnabled' | 'agentId'> & Partial<Pick<ControlProps, 'onHoldResume' | 'onEnd' | 'onWrapUp' | 'onRecordingToggle' | 'onToggleMute'>>;
|
|
13
8
|
export type useOutdialCallProps = Pick<OutdialCallProps, 'cc' | 'logger'>;
|
|
9
|
+
export interface OutdialProps {
|
|
10
|
+
/**
|
|
11
|
+
* Flag to determine if the address book is enabled.
|
|
12
|
+
* Defaults to true if not provided.
|
|
13
|
+
*/
|
|
14
|
+
isAddressBookEnabled?: boolean;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Helper interface for device type checks
|
|
18
|
+
*/
|
|
19
|
+
export interface DeviceTypeFlags {
|
|
20
|
+
isBrowser: boolean;
|
|
21
|
+
isAgentDN: boolean;
|
|
22
|
+
isExtension: boolean;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Target types for consult/transfer operations
|
|
26
|
+
*/
|
|
27
|
+
export declare const TARGET_TYPE: {
|
|
28
|
+
readonly AGENT: "agent";
|
|
29
|
+
readonly QUEUE: "queue";
|
|
30
|
+
readonly ENTRY_POINT: "entryPoint";
|
|
31
|
+
readonly DIAL_NUMBER: "dialNumber";
|
|
32
|
+
};
|
|
33
|
+
export type TargetType = (typeof TARGET_TYPE)[keyof typeof TARGET_TYPE];
|
package/package.json
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webex/cc-task",
|
|
3
3
|
"description": "Webex Contact Center Widgets: Task",
|
|
4
|
-
"
|
|
4
|
+
"license": "Cisco's General Terms (https://www.cisco.com/site/us/en/about/legal/contract-experience/index.html)",
|
|
5
|
+
"version": "1.28.0-next.10",
|
|
5
6
|
"main": "dist/index.js",
|
|
6
7
|
"types": "dist/types/index.d.ts",
|
|
7
8
|
"publishConfig": {
|
|
@@ -18,12 +19,14 @@
|
|
|
18
19
|
"build:src": "yarn run clean:dist && webpack",
|
|
19
20
|
"build:watch": "webpack --watch",
|
|
20
21
|
"test:unit": "tsc --project tsconfig.test.json && jest --coverage",
|
|
21
|
-
"test:styles": "eslint"
|
|
22
|
+
"test:styles": "eslint",
|
|
23
|
+
"deploy:npm": "yarn npm publish"
|
|
22
24
|
},
|
|
23
25
|
"dependencies": {
|
|
24
|
-
"@webex/cc-components": "1.28.0-
|
|
25
|
-
"@webex/cc-store": "1.28.0-
|
|
26
|
-
"mobx-react-lite": "^4.1.0"
|
|
26
|
+
"@webex/cc-components": "1.28.0-next.10",
|
|
27
|
+
"@webex/cc-store": "1.28.0-next.4",
|
|
28
|
+
"mobx-react-lite": "^4.1.0",
|
|
29
|
+
"react-error-boundary": "^6.0.0"
|
|
27
30
|
},
|
|
28
31
|
"devDependencies": {
|
|
29
32
|
"@babel/core": "7.25.2",
|
|
@@ -36,7 +39,7 @@
|
|
|
36
39
|
"@testing-library/react": "16.0.1",
|
|
37
40
|
"@types/jest": "29.5.14",
|
|
38
41
|
"@types/react-test-renderer": "18",
|
|
39
|
-
"@webex/test-fixtures": "0.0.0",
|
|
42
|
+
"@webex/test-fixtures": "0.0.0-next.1",
|
|
40
43
|
"babel-jest": "29.7.0",
|
|
41
44
|
"babel-loader": "9.2.1",
|
|
42
45
|
"eslint": "^9.20.1",
|