ahs-cti 0.0.9 → 0.0.11
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/{caroQualityAuditDashboard-TNS4L2NR.mjs → caroQualityAuditDashboard-PDXTFXYP.mjs} +4 -4
- package/{dist-react/caroQualityAuditDashboard-THYPVOCP.mjs.map → dist/caroQualityAuditDashboard-PDXTFXYP.mjs.map} +1 -1
- package/dist/index.js +133 -73
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +129 -69
- package/dist/index.mjs.map +1 -1
- package/dist/{qualityAuditDashboard-FHRGB77R.mjs → qualityAuditDashboard-L2KJETAG.mjs} +4 -4
- package/dist/{qualityAuditDashboard-FHRGB77R.mjs.map → qualityAuditDashboard-L2KJETAG.mjs.map} +1 -1
- package/dist-react/{caroQualityAuditDashboard-THYPVOCP.mjs → caroQualityAuditDashboard-7MELAQXL.mjs} +4 -4
- package/{dist/caroQualityAuditDashboard-TNS4L2NR.mjs.map → dist-react/caroQualityAuditDashboard-7MELAQXL.mjs.map} +1 -1
- package/dist-react/index.d.ts +1 -2
- package/dist-react/index.js +133 -73
- package/dist-react/index.js.map +1 -1
- package/dist-react/index.mjs +129 -69
- package/dist-react/index.mjs.map +1 -1
- package/dist-react/{qualityAuditDashboard-ZAM7HRNH.mjs → qualityAuditDashboard-APCN5BD5.mjs} +4 -4
- package/dist-react/{qualityAuditDashboard-ZAM7HRNH.mjs.map → qualityAuditDashboard-APCN5BD5.mjs.map} +1 -1
- package/package.json +1 -1
package/dist-react/index.js
CHANGED
|
@@ -21938,9 +21938,9 @@ var init_qualityAuditDashboard = __esm({
|
|
|
21938
21938
|
vizElement.parentNode.insertBefore(scriptElement, vizElement);
|
|
21939
21939
|
|
|
21940
21940
|
function scaleViz() {
|
|
21941
|
-
|
|
21942
|
-
|
|
21943
|
-
var scale =
|
|
21941
|
+
// Scale to fill the full available width (removes the empty space on the
|
|
21942
|
+
// right); height follows the dashboard's aspect ratio.
|
|
21943
|
+
var scale = window.innerWidth / 1500;
|
|
21944
21944
|
divElement.style.transform = 'scale(' + scale + ')';
|
|
21945
21945
|
}
|
|
21946
21946
|
scaleViz();
|
|
@@ -22009,9 +22009,9 @@ var init_caroQualityAuditDashboard = __esm({
|
|
|
22009
22009
|
vizElement.parentNode.insertBefore(scriptElement, vizElement);
|
|
22010
22010
|
|
|
22011
22011
|
function scaleViz() {
|
|
22012
|
-
|
|
22013
|
-
|
|
22014
|
-
var scale =
|
|
22012
|
+
// Scale to fill the full available width (removes the empty space on the
|
|
22013
|
+
// right); height follows the dashboard's aspect ratio.
|
|
22014
|
+
var scale = window.innerWidth / 1500;
|
|
22015
22015
|
divElement.style.transform = 'scale(' + scale + ')';
|
|
22016
22016
|
}
|
|
22017
22017
|
scaleViz();
|
|
@@ -22635,7 +22635,7 @@ var styles_default = useStyles;
|
|
|
22635
22635
|
// call-control-sdk/lib/components/dialog.tsx
|
|
22636
22636
|
var import_jsx_runtime2 = require("react/jsx-runtime");
|
|
22637
22637
|
var ConferenceTableRow = ({ each, isLineDialing }) => {
|
|
22638
|
-
var _a2, _b, _c, _d, _e, _f, _g, _h, _i;
|
|
22638
|
+
var _a2, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;
|
|
22639
22639
|
const state = useSDKState();
|
|
22640
22640
|
const theme = (0, import_material3.useTheme)();
|
|
22641
22641
|
const { showToast } = useToast();
|
|
@@ -22652,8 +22652,17 @@ var ConferenceTableRow = ({ each, isLineDialing }) => {
|
|
|
22652
22652
|
(line) => (line == null ? void 0 : line.status) === "DIALING" /* DIALING */ || (line == null ? void 0 : line.status) === "ONCALL" /* ONCALL */
|
|
22653
22653
|
);
|
|
22654
22654
|
const holdEnabled = ((each == null ? void 0 : each.status) === "CONFERENCE" /* CONFERENCE */ || (each == null ? void 0 : each.status) === "HOLD" /* HOLD */) && !anyLineDialingOrOnCall && !conferenceCallHoldOrUnHold;
|
|
22655
|
-
const
|
|
22656
|
-
|
|
22655
|
+
const mainCallDisconnected = (_e = state == null ? void 0 : state.conferenceLine) == null ? void 0 : _e.some(
|
|
22656
|
+
(line) => (line == null ? void 0 : line.line) === 1 && (line == null ? void 0 : line.status) === "DISCONNECTED" /* DISCONNECTED */
|
|
22657
|
+
);
|
|
22658
|
+
const anyOtherLineOnHold = (_f = state == null ? void 0 : state.conferenceLine) == null ? void 0 : _f.some(
|
|
22659
|
+
(line) => (line == null ? void 0 : line.line) !== (each == null ? void 0 : each.line) && (line == null ? void 0 : line.status) === "HOLD" /* HOLD */
|
|
22660
|
+
);
|
|
22661
|
+
const mergeEnabled = (each == null ? void 0 : each.status) === "ONCALL" /* ONCALL */ && (!mainCallDisconnected || anyOtherLineOnHold);
|
|
22662
|
+
const mainMergeEnabled = !!anyOtherLineOnHold && (each == null ? void 0 : each.status) === "ONCALL" /* ONCALL */;
|
|
22663
|
+
const mainCallIconDisabled = conferenceCallStart || (each == null ? void 0 : each.status) === "DIALING" /* DIALING */ || (each == null ? void 0 : each.status) === "ONCALL" /* ONCALL */ || (each == null ? void 0 : each.status) === "CONFERENCE" /* CONFERENCE */ || (each == null ? void 0 : each.status) === "HOLD" /* HOLD */;
|
|
22664
|
+
const isSameAsActiveCall = (each == null ? void 0 : each.phone) === ((_g = state.callData) == null ? void 0 : _g.phone_number) && !!(each == null ? void 0 : each.phone);
|
|
22665
|
+
const isDuplicateInConference = !!(each == null ? void 0 : each.phone) && (each == null ? void 0 : each.line) !== 1 && ((_h = state.conferenceLine) == null ? void 0 : _h.some(
|
|
22657
22666
|
(line) => line.line < each.line && line.phone === (each == null ? void 0 : each.phone) && !!line.phone
|
|
22658
22667
|
));
|
|
22659
22668
|
const hasPhoneConflict = isDuplicateInConference;
|
|
@@ -22701,6 +22710,33 @@ var ConferenceTableRow = ({ each, isLineDialing }) => {
|
|
|
22701
22710
|
setConferenceCallStart(false);
|
|
22702
22711
|
});
|
|
22703
22712
|
};
|
|
22713
|
+
const onReCallMainCall = (line) => {
|
|
22714
|
+
var _a3, _b2, _c2, _d2;
|
|
22715
|
+
const target = (line == null ? void 0 : line.phone) || ((_a3 = state.callData) == null ? void 0 : _a3.phone_number) || "";
|
|
22716
|
+
if (!target || target.length < 10) {
|
|
22717
|
+
showToast("Invalid phone number", "error");
|
|
22718
|
+
return;
|
|
22719
|
+
}
|
|
22720
|
+
setConferenceCallStart(true);
|
|
22721
|
+
const payload = {
|
|
22722
|
+
action: "EXTERNAL_CONFERENCE",
|
|
22723
|
+
operation: "CALL1",
|
|
22724
|
+
target,
|
|
22725
|
+
line_number: 1,
|
|
22726
|
+
userid: (_b2 = state.agentId) != null ? _b2 : "",
|
|
22727
|
+
process: (_d2 = (_c2 = state.callData) == null ? void 0 : _c2.process_name) != null ? _d2 : ""
|
|
22728
|
+
};
|
|
22729
|
+
axios_default2.post(END_POINT.CONFERENCE_CALL, payload).then((res) => {
|
|
22730
|
+
var _a4;
|
|
22731
|
+
showToast((_a4 = res.data) == null ? void 0 : _a4.message, "success");
|
|
22732
|
+
}).catch((err) => {
|
|
22733
|
+
var _a4, _b3, _c3, _d3;
|
|
22734
|
+
const message = ((_b3 = (_a4 = err.response) == null ? void 0 : _a4.data) == null ? void 0 : _b3.detail) || ((_d3 = (_c3 = err.response) == null ? void 0 : _c3.data) == null ? void 0 : _d3.message) || err.message || "An unknown error occurred";
|
|
22735
|
+
showToast(message, "error");
|
|
22736
|
+
}).finally(() => {
|
|
22737
|
+
setConferenceCallStart(false);
|
|
22738
|
+
});
|
|
22739
|
+
};
|
|
22704
22740
|
const onMergeConferenceCall = (line, data) => {
|
|
22705
22741
|
var _a3, _b2, _c2, _d2, _e2;
|
|
22706
22742
|
const line_used = __spreadValues(__spreadValues({}, line), data);
|
|
@@ -22820,7 +22856,7 @@ var ConferenceTableRow = ({ each, isLineDialing }) => {
|
|
|
22820
22856
|
},
|
|
22821
22857
|
children: /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_material3.Typography, { children: [
|
|
22822
22858
|
"Line ",
|
|
22823
|
-
(
|
|
22859
|
+
(_i = each == null ? void 0 : each.line) != null ? _i : "",
|
|
22824
22860
|
". "
|
|
22825
22861
|
] })
|
|
22826
22862
|
}
|
|
@@ -22841,7 +22877,7 @@ var ConferenceTableRow = ({ each, isLineDialing }) => {
|
|
|
22841
22877
|
borderRadius: "10px",
|
|
22842
22878
|
width: "150px"
|
|
22843
22879
|
},
|
|
22844
|
-
children: (
|
|
22880
|
+
children: (_j = each == null ? void 0 : each.status) != null ? _j : ""
|
|
22845
22881
|
}
|
|
22846
22882
|
)
|
|
22847
22883
|
}
|
|
@@ -22877,7 +22913,7 @@ var ConferenceTableRow = ({ each, isLineDialing }) => {
|
|
|
22877
22913
|
"MUTE" /* MUTE */,
|
|
22878
22914
|
"DIALING" /* DIALING */,
|
|
22879
22915
|
"RINGING" /* RINGING */
|
|
22880
|
-
].includes((
|
|
22916
|
+
].includes((_k = each == null ? void 0 : each.status) != null ? _k : "") || isLineDialing,
|
|
22881
22917
|
onKeyDown: (e) => {
|
|
22882
22918
|
const allowedKeys = [
|
|
22883
22919
|
"Backspace",
|
|
@@ -22928,6 +22964,29 @@ var ConferenceTableRow = ({ each, isLineDialing }) => {
|
|
|
22928
22964
|
gap: "10px"
|
|
22929
22965
|
},
|
|
22930
22966
|
children: [
|
|
22967
|
+
(each == null ? void 0 : each.line) === 1 && /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_jsx_runtime2.Fragment, { children: [
|
|
22968
|
+
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_material3.Tooltip, { title: "Call main number again", children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
22969
|
+
import_material3.Button,
|
|
22970
|
+
{
|
|
22971
|
+
variant: mainCallIconDisabled ? "outlined" : "contained",
|
|
22972
|
+
color: "success",
|
|
22973
|
+
sx: mainCallIconDisabled ? __spreadValues({}, disabled) : __spreadValues({}, enabled),
|
|
22974
|
+
onClick: () => onReCallMainCall(each),
|
|
22975
|
+
disabled: mainCallIconDisabled,
|
|
22976
|
+
children: conferenceCallStart ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_material3.CircularProgress, { size: "20px", color: "success" }) : /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_Call.default, { sx: { color: mainCallIconDisabled ? "inherit" : "#f3f2f2" } })
|
|
22977
|
+
}
|
|
22978
|
+
) }) }),
|
|
22979
|
+
/* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_material3.Tooltip, { title: "Merge Call", children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
22980
|
+
import_material3.Button,
|
|
22981
|
+
{
|
|
22982
|
+
variant: mainMergeEnabled ? "contained" : "outlined",
|
|
22983
|
+
sx: mainMergeEnabled ? __spreadValues({}, enabled) : __spreadValues({}, disabled),
|
|
22984
|
+
onClick: () => onMergeConferenceCall(each, { isMergeCall: true }),
|
|
22985
|
+
disabled: !mainMergeEnabled,
|
|
22986
|
+
children: conferenceCallMerge ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_material3.CircularProgress, { size: "20px" }) : /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_CallSplit.default, {})
|
|
22987
|
+
}
|
|
22988
|
+
) }) })
|
|
22989
|
+
] }),
|
|
22931
22990
|
(each == null ? void 0 : each.line) === 1 && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_material3.Tooltip, { title: (each == null ? void 0 : each.status) !== "HOLD" /* HOLD */ ? "Hold" : "Resume", children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
22932
22991
|
import_material3.Button,
|
|
22933
22992
|
{
|
|
@@ -23028,18 +23087,18 @@ var ConferenceTableRow = ({ each, isLineDialing }) => {
|
|
|
23028
23087
|
}
|
|
23029
23088
|
) }) });
|
|
23030
23089
|
})(),
|
|
23031
|
-
(each == null ? void 0 : each.line) !== 1 && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_material3.Tooltip, { title: "Merge Call", children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
23090
|
+
(each == null ? void 0 : each.line) !== 1 && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_material3.Tooltip, { title: mergeEnabled ? "Merge Call" : mainCallDisconnected && (each == null ? void 0 : each.status) === "ONCALL" /* ONCALL */ ? "Put another line on hold to merge" : "Merge Call", children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
23032
23091
|
import_material3.Button,
|
|
23033
23092
|
{
|
|
23034
|
-
variant:
|
|
23035
|
-
sx:
|
|
23093
|
+
variant: mergeEnabled ? "contained" : "outlined",
|
|
23094
|
+
sx: mergeEnabled ? __spreadValues({}, enabled) : __spreadValues({}, disabled),
|
|
23036
23095
|
onClick: () => {
|
|
23037
23096
|
onMergeConferenceCall(each, { isMergeCall: true });
|
|
23038
23097
|
},
|
|
23039
|
-
disabled:
|
|
23098
|
+
disabled: !mergeEnabled,
|
|
23040
23099
|
children: conferenceCallMerge ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_material3.CircularProgress, { size: "20px" }) : /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_CallSplit.default, {})
|
|
23041
23100
|
}
|
|
23042
|
-
) }),
|
|
23101
|
+
) }) }),
|
|
23043
23102
|
(each == null ? void 0 : each.line) !== 1 && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_material3.Tooltip, { title: (each == null ? void 0 : each.status) !== "HOLD" /* HOLD */ ? "Hold" : "Resume", children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
23044
23103
|
import_material3.Button,
|
|
23045
23104
|
{
|
|
@@ -24765,7 +24824,7 @@ var formatDuration = (seconds) => {
|
|
|
24765
24824
|
return `${mins.toString().padStart(2, "0")}:${secs.toString().padStart(2, "0")}`;
|
|
24766
24825
|
};
|
|
24767
24826
|
function CallControls({ onDataChange }) {
|
|
24768
|
-
var _a2, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E, _F, _G, _H, _I, _J, _K, _L, _M, _N, _O, _P, _Q, _R, _S, _T, _U, _V, _W, _X, _Y, _Z, __, _$, _aa, _ba, _ca, _da, _ea, _fa, _ga, _ha, _ia, _ja, _ka, _la, _ma, _na, _oa, _pa, _qa, _ra, _sa, _ta, _ua, _va, _wa, _xa, _ya, _za, _Aa, _Ba, _Ca, _Da, _Ea, _Fa, _Ga, _Ha, _Ia, _Ja, _Ka, _La, _Ma, _Na, _Oa, _Pa, _Qa, _Ra, _Sa, _Ta, _Ua, _Va, _Wa, _Xa, _Ya, _Za, __a, _$a, _ab, _bb, _cb, _db, _eb, _fb, _gb, _hb, _ib, _jb, _kb, _lb, _mb, _nb, _ob, _pb, _qb, _rb, _sb, _tb, _ub, _vb, _wb, _xb
|
|
24827
|
+
var _a2, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E, _F, _G, _H, _I, _J, _K, _L, _M, _N, _O, _P, _Q, _R, _S, _T, _U, _V, _W, _X, _Y, _Z, __, _$, _aa, _ba, _ca, _da, _ea, _fa, _ga, _ha, _ia, _ja, _ka, _la, _ma, _na, _oa, _pa, _qa, _ra, _sa, _ta, _ua, _va, _wa, _xa, _ya, _za, _Aa, _Ba, _Ca, _Da, _Ea, _Fa, _Ga, _Ha, _Ia, _Ja, _Ka, _La, _Ma, _Na, _Oa, _Pa, _Qa, _Ra, _Sa, _Ta, _Ua, _Va, _Wa, _Xa, _Ya, _Za, __a, _$a, _ab, _bb, _cb, _db, _eb, _fb, _gb, _hb, _ib, _jb, _kb, _lb, _mb, _nb, _ob, _pb, _qb, _rb, _sb, _tb, _ub, _vb, _wb, _xb;
|
|
24769
24828
|
const theme = (0, import_material4.useTheme)();
|
|
24770
24829
|
const state = useSDKState();
|
|
24771
24830
|
const { showToast } = useToast();
|
|
@@ -24954,6 +25013,8 @@ function CallControls({ onDataChange }) {
|
|
|
24954
25013
|
};
|
|
24955
25014
|
muteOrUnMute(END_POINT.MUTE_CALL, payload);
|
|
24956
25015
|
};
|
|
25016
|
+
const holdFeatureDisabled = !!((_d = state.sdkConfig) == null ? void 0 : _d.disableHoldButton) || ((_e = state.callData) == null ? void 0 : _e.disable_hold_mute) === 1;
|
|
25017
|
+
const muteFeatureDisabled = !!((_f = state.sdkConfig) == null ? void 0 : _f.disableMuteButton) || ((_g = state.callData) == null ? void 0 : _g.disable_hold_mute) === 1;
|
|
24957
25018
|
const handleEndCall = (data) => {
|
|
24958
25019
|
var _a3, _b2, _c2, _d2, _e2, _f2, _g2, _h2, _i2, _j2, _k2, _l2, _m2, _n2;
|
|
24959
25020
|
const payload = {
|
|
@@ -25102,7 +25163,7 @@ function CallControls({ onDataChange }) {
|
|
|
25102
25163
|
return () => {
|
|
25103
25164
|
if (holdInterval) clearInterval(holdInterval);
|
|
25104
25165
|
};
|
|
25105
|
-
}, [(
|
|
25166
|
+
}, [(_h = state.callData) == null ? void 0 : _h.hold, (_i = state.callData) == null ? void 0 : _i.status]);
|
|
25106
25167
|
(0, import_react12.useEffect)(() => {
|
|
25107
25168
|
var _a3, _b2, _c2, _d2;
|
|
25108
25169
|
let muteInterval;
|
|
@@ -25125,7 +25186,7 @@ function CallControls({ onDataChange }) {
|
|
|
25125
25186
|
return () => {
|
|
25126
25187
|
if (muteInterval) clearInterval(muteInterval);
|
|
25127
25188
|
};
|
|
25128
|
-
}, [(
|
|
25189
|
+
}, [(_j = state.callData) == null ? void 0 : _j.mute, (_k = state.callData) == null ? void 0 : _k.status]);
|
|
25129
25190
|
(0, import_react12.useEffect)(() => {
|
|
25130
25191
|
createAudioElement().then((audio) => {
|
|
25131
25192
|
audioRef.current = audio;
|
|
@@ -25225,6 +25286,7 @@ function CallControls({ onDataChange }) {
|
|
|
25225
25286
|
process_name: data == null ? void 0 : data.process_name,
|
|
25226
25287
|
hold: data == null ? void 0 : data.hold,
|
|
25227
25288
|
mute: data == null ? void 0 : data.mute,
|
|
25289
|
+
disable_hold_mute: data == null ? void 0 : data.disable_hold_mute,
|
|
25228
25290
|
mode: data == null ? void 0 : data.mode,
|
|
25229
25291
|
queue_name: data == null ? void 0 : data.queue_name,
|
|
25230
25292
|
auto_wrapup_time: (_a4 = data == null ? void 0 : data.auto_wrapup_time) != null ? _a4 : null
|
|
@@ -25446,19 +25508,19 @@ function CallControls({ onDataChange }) {
|
|
|
25446
25508
|
}
|
|
25447
25509
|
) });
|
|
25448
25510
|
}
|
|
25449
|
-
const isOnHold = ((
|
|
25450
|
-
const isMuted = ((
|
|
25451
|
-
const isVertical = ((
|
|
25511
|
+
const isOnHold = ((_l = state.callData) == null ? void 0 : _l.hold) === 1 && ((_n = (_m = state.callData) == null ? void 0 : _m.status) == null ? void 0 : _n.toUpperCase()) === "ONCALL" /* ONCALL */;
|
|
25512
|
+
const isMuted = ((_o = state.callData) == null ? void 0 : _o.mute) === 1 && ((_q = (_p = state.callData) == null ? void 0 : _p.status) == null ? void 0 : _q.toUpperCase()) === "ONCALL" /* ONCALL */;
|
|
25513
|
+
const isVertical = ((_r = state.sdkConfig) == null ? void 0 : _r.sdkPosition) === "vertical";
|
|
25452
25514
|
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
|
|
25453
25515
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Box, { children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Fade, { in: true, timeout: 300, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25454
25516
|
import_material4.Paper,
|
|
25455
25517
|
{
|
|
25456
|
-
ref: ((
|
|
25457
|
-
elevation: isDragging ? 4 : ((
|
|
25518
|
+
ref: ((_s = state.sdkConfig) == null ? void 0 : _s.isDraggable) ? dragRef : null,
|
|
25519
|
+
elevation: isDragging ? 4 : ((_t = state.sdkConfig) == null ? void 0 : _t.isDraggable) ? 1 : 0,
|
|
25458
25520
|
sx: {
|
|
25459
|
-
position: ((
|
|
25460
|
-
left: ((
|
|
25461
|
-
top: ((
|
|
25521
|
+
position: ((_u = state.sdkConfig) == null ? void 0 : _u.isDraggable) ? "fixed" : "relative",
|
|
25522
|
+
left: ((_v = state.sdkConfig) == null ? void 0 : _v.isDraggable) ? position.x : "auto",
|
|
25523
|
+
top: ((_w = state.sdkConfig) == null ? void 0 : _w.isDraggable) ? position.y : "auto",
|
|
25462
25524
|
display: "inline-block",
|
|
25463
25525
|
width: isVertical ? "180px" : "auto",
|
|
25464
25526
|
flexShrink: 0,
|
|
@@ -25466,7 +25528,7 @@ function CallControls({ onDataChange }) {
|
|
|
25466
25528
|
p: 0.5,
|
|
25467
25529
|
borderRadius: 3,
|
|
25468
25530
|
bgcolor: "background.paper",
|
|
25469
|
-
zIndex: ((
|
|
25531
|
+
zIndex: ((_x = state.sdkConfig) == null ? void 0 : _x.isDraggable) ? Number.MAX_SAFE_INTEGER : 0,
|
|
25470
25532
|
transition: theme.transitions.create(["box-shadow", "transform"], {
|
|
25471
25533
|
duration: theme.transitions.duration.short
|
|
25472
25534
|
}),
|
|
@@ -25492,7 +25554,7 @@ function CallControls({ onDataChange }) {
|
|
|
25492
25554
|
margin: isVertical ? "10px 8px 4px 8px" : "0px 10px"
|
|
25493
25555
|
},
|
|
25494
25556
|
children: [
|
|
25495
|
-
((
|
|
25557
|
+
((_y = state.sdkConfig) == null ? void 0 : _y.isDraggable) && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25496
25558
|
import_material4.IconButton,
|
|
25497
25559
|
{
|
|
25498
25560
|
component: "div",
|
|
@@ -25505,8 +25567,8 @@ function CallControls({ onDataChange }) {
|
|
|
25505
25567
|
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_DragIndicator.default, {})
|
|
25506
25568
|
}
|
|
25507
25569
|
),
|
|
25508
|
-
((
|
|
25509
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: ((
|
|
25570
|
+
((_z = state.sdkConfig) == null ? void 0 : _z.enableQueueName) && ((_A = state == null ? void 0 : state.callData) == null ? void 0 : _A.queue_name) && ((_B = state == null ? void 0 : state.callData) == null ? void 0 : _B.mode) !== "manual" && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Chip, { label: (_C = state == null ? void 0 : state.callData) == null ? void 0 : _C.queue_name }),
|
|
25571
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: ((_D = state.sdkConfig) == null ? void 0 : _D.disabledDialButton) ? "Outbound call feature is disabled" : "Dial", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Box, { component: "span", sx: isVertical ? { display: "block" } : {}, children: isVertical ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25510
25572
|
import_material4.Button,
|
|
25511
25573
|
{
|
|
25512
25574
|
variant: "outlined",
|
|
@@ -25525,7 +25587,7 @@ function CallControls({ onDataChange }) {
|
|
|
25525
25587
|
"BREAK" /* BREAK */,
|
|
25526
25588
|
"ONCALL" /* ONCALL */,
|
|
25527
25589
|
"RINGING" /* RINGING */
|
|
25528
|
-
].includes((
|
|
25590
|
+
].includes((_E = state.callData.status) == null ? void 0 : _E.toUpperCase()) || ((_F = state.sdkConfig) == null ? void 0 : _F.disabledDialButton) || ((_G = state.callData.status) == null ? void 0 : _G.toUpperCase()) === "WRAPUP" /* WRAPUP */ && !!((_H = state.sdkConfig) == null ? void 0 : _H.disableAlternateDialing),
|
|
25529
25591
|
sx: {
|
|
25530
25592
|
justifyContent: "flex-start",
|
|
25531
25593
|
width: "100%",
|
|
@@ -25534,12 +25596,12 @@ function CallControls({ onDataChange }) {
|
|
|
25534
25596
|
"BREAK" /* BREAK */,
|
|
25535
25597
|
"ONCALL" /* ONCALL */,
|
|
25536
25598
|
"RINGING" /* RINGING */
|
|
25537
|
-
].includes((
|
|
25599
|
+
].includes((_I = state.callData.status) == null ? void 0 : _I.toUpperCase()) || ((_J = state.sdkConfig) == null ? void 0 : _J.disabledDialButton) || ((_K = state.callData.status) == null ? void 0 : _K.toUpperCase()) === "WRAPUP" /* WRAPUP */ && !!((_L = state.sdkConfig) == null ? void 0 : _L.disableAlternateDialing) ? "action.selected" : "success.main",
|
|
25538
25600
|
borderColor: [
|
|
25539
25601
|
"BREAK" /* BREAK */,
|
|
25540
25602
|
"ONCALL" /* ONCALL */,
|
|
25541
25603
|
"RINGING" /* RINGING */
|
|
25542
|
-
].includes((
|
|
25604
|
+
].includes((_M = state.callData.status) == null ? void 0 : _M.toUpperCase()) || ((_N = state.sdkConfig) == null ? void 0 : _N.disabledDialButton) || ((_O = state.callData.status) == null ? void 0 : _O.toUpperCase()) === "WRAPUP" /* WRAPUP */ && !!((_P = state.sdkConfig) == null ? void 0 : _P.disableAlternateDialing) ? "action.selected" : "success.main"
|
|
25543
25605
|
},
|
|
25544
25606
|
children: "Dial"
|
|
25545
25607
|
}
|
|
@@ -25561,7 +25623,7 @@ function CallControls({ onDataChange }) {
|
|
|
25561
25623
|
"BREAK" /* BREAK */,
|
|
25562
25624
|
"ONCALL" /* ONCALL */,
|
|
25563
25625
|
"RINGING" /* RINGING */
|
|
25564
|
-
].includes((
|
|
25626
|
+
].includes((_Q = state.callData.status) == null ? void 0 : _Q.toUpperCase()) || ((_R = state.sdkConfig) == null ? void 0 : _R.disabledDialButton) || ((_S = state.callData.status) == null ? void 0 : _S.toUpperCase()) === "WRAPUP" /* WRAPUP */ && !!((_T = state.sdkConfig) == null ? void 0 : _T.disableAlternateDialing),
|
|
25565
25627
|
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25566
25628
|
import_WifiCalling3.default,
|
|
25567
25629
|
{
|
|
@@ -25570,7 +25632,7 @@ function CallControls({ onDataChange }) {
|
|
|
25570
25632
|
"BREAK" /* BREAK */,
|
|
25571
25633
|
"ONCALL" /* ONCALL */,
|
|
25572
25634
|
"RINGING" /* RINGING */
|
|
25573
|
-
].includes((
|
|
25635
|
+
].includes((_U = state.callData.status) == null ? void 0 : _U.toUpperCase()) || ((_V = state.sdkConfig) == null ? void 0 : _V.disabledDialButton) || ((_W = state.callData.status) == null ? void 0 : _W.toUpperCase()) === "WRAPUP" /* WRAPUP */ && !!((_X = state.sdkConfig) == null ? void 0 : _X.disableAlternateDialing) ? "action.selected" : "success.main"
|
|
25574
25636
|
}
|
|
25575
25637
|
}
|
|
25576
25638
|
)
|
|
@@ -25589,7 +25651,7 @@ function CallControls({ onDataChange }) {
|
|
|
25589
25651
|
marginRight: "10px"
|
|
25590
25652
|
},
|
|
25591
25653
|
children: [
|
|
25592
|
-
((
|
|
25654
|
+
((_Z = (_Y = state.callData) == null ? void 0 : _Y.status) == null ? void 0 : _Z.toUpperCase()) === "BREAK" /* BREAK */ && ((_$ = (__ = state.callData) == null ? void 0 : __.break_details) == null ? void 0 : _$.value) ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: state.callData.break_details.value, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25593
25655
|
import_material4.Box,
|
|
25594
25656
|
{
|
|
25595
25657
|
sx: {
|
|
@@ -25720,7 +25782,7 @@ function CallControls({ onDataChange }) {
|
|
|
25720
25782
|
width: "60px",
|
|
25721
25783
|
textAlign: "center"
|
|
25722
25784
|
},
|
|
25723
|
-
children: (
|
|
25785
|
+
children: (_ca = (_ba = (_aa = state.callData) == null ? void 0 : _aa.status) == null ? void 0 : _ba.toUpperCase()) != null ? _ca : "N/A"
|
|
25724
25786
|
}
|
|
25725
25787
|
),
|
|
25726
25788
|
onClick: handleOpenAgentStatus,
|
|
@@ -25747,7 +25809,7 @@ function CallControls({ onDataChange }) {
|
|
|
25747
25809
|
import_material4.Button,
|
|
25748
25810
|
{
|
|
25749
25811
|
variant: ["BREAK" /* BREAK */, "MISSED" /* MISSED */].includes(
|
|
25750
|
-
(
|
|
25812
|
+
(_ea = (_da = state.callData) == null ? void 0 : _da.status) == null ? void 0 : _ea.toUpperCase()
|
|
25751
25813
|
) ? "outlined" : "contained",
|
|
25752
25814
|
startIcon: isVertical ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_SupportAgent2.default, {}) : void 0,
|
|
25753
25815
|
onClick: (e) => {
|
|
@@ -25761,63 +25823,61 @@ function CallControls({ onDataChange }) {
|
|
|
25761
25823
|
},
|
|
25762
25824
|
classes: {
|
|
25763
25825
|
root: ["BREAK" /* BREAK */, "MISSED" /* MISSED */].includes(
|
|
25764
|
-
(
|
|
25826
|
+
(_ga = (_fa = state.callData) == null ? void 0 : _fa.status) == null ? void 0 : _ga.toUpperCase()
|
|
25765
25827
|
) ? "outlined" : "enabled"
|
|
25766
25828
|
},
|
|
25767
25829
|
sx: __spreadValues(__spreadValues({}, ["BREAK" /* BREAK */, "MISSED" /* MISSED */].includes(
|
|
25768
|
-
(
|
|
25830
|
+
(_ia = (_ha = state.callData) == null ? void 0 : _ha.status) == null ? void 0 : _ia.toUpperCase()
|
|
25769
25831
|
) ? outlined : enabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }),
|
|
25770
25832
|
disabled: agentReadyLoading,
|
|
25771
25833
|
children: isVertical ? "Agent Ready" : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_SupportAgent2.default, {})
|
|
25772
25834
|
}
|
|
25773
25835
|
) }),
|
|
25774
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title:
|
|
25836
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: holdFeatureDisabled ? "Hold feature is disabled" : ((_ja = state.callData) == null ? void 0 : _ja.hold) === 1 ? "Resume" : "Hold", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Box, { component: "span", sx: isVertical ? { display: "block" } : {}, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25775
25837
|
import_material4.Button,
|
|
25776
25838
|
{
|
|
25777
|
-
variant: ((
|
|
25778
|
-
startIcon: isVertical ? holdOrUnHoldLoading ? void 0 : ((
|
|
25839
|
+
variant: ((_ka = state.callData) == null ? void 0 : _ka.hold) === 1 && ((_ma = (_la = state.callData) == null ? void 0 : _la.status) == null ? void 0 : _ma.toUpperCase()) === "ONCALL" /* ONCALL */ ? "contained" : "outlined",
|
|
25840
|
+
startIcon: isVertical ? holdOrUnHoldLoading ? void 0 : ((_na = state.callData) == null ? void 0 : _na.hold) === 1 ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_PlayArrow2.default, {}) : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_Pause2.default, {}) : void 0,
|
|
25779
25841
|
onClick: (e) => {
|
|
25780
|
-
var _a3;
|
|
25781
25842
|
e.stopPropagation();
|
|
25782
|
-
if (!
|
|
25843
|
+
if (!holdFeatureDisabled) {
|
|
25783
25844
|
handleHoldToggle();
|
|
25784
25845
|
}
|
|
25785
25846
|
},
|
|
25786
|
-
sx: ((
|
|
25787
|
-
disabled: ((
|
|
25847
|
+
sx: ((_oa = state.callData) == null ? void 0 : _oa.hold) === 1 && ((_qa = (_pa = state.callData) == null ? void 0 : _pa.status) == null ? void 0 : _qa.toUpperCase()) === "ONCALL" /* ONCALL */ ? __spreadValues(__spreadValues({}, enabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : ((_sa = (_ra = state.callData) == null ? void 0 : _ra.status) == null ? void 0 : _sa.toUpperCase()) === "ONCALL" /* ONCALL */ && !holdFeatureDisabled ? __spreadValues(__spreadValues({}, outlined), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : __spreadValues(__spreadValues({}, disabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }),
|
|
25848
|
+
disabled: ((_ua = (_ta = state.callData) == null ? void 0 : _ta.status) == null ? void 0 : _ua.toUpperCase()) !== "ONCALL" /* ONCALL */ && ((_va = state.callData) == null ? void 0 : _va.hold) !== 1 || holdOrUnHoldLoading || holdFeatureDisabled,
|
|
25788
25849
|
children: holdOrUnHoldLoading ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25789
25850
|
import_material4.CircularProgress,
|
|
25790
25851
|
{
|
|
25791
25852
|
size: "20px",
|
|
25792
25853
|
sx: { color: theme.palette.primary.main }
|
|
25793
25854
|
}
|
|
25794
|
-
) : isVertical ? ((
|
|
25855
|
+
) : isVertical ? ((_wa = state.callData) == null ? void 0 : _wa.hold) === 1 ? "Resume" : "Hold" : ((_xa = state.callData) == null ? void 0 : _xa.hold) === 1 ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_PlayArrow2.default, {}) : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_Pause2.default, {})
|
|
25795
25856
|
}
|
|
25796
25857
|
) }) }),
|
|
25797
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title:
|
|
25858
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: muteFeatureDisabled ? "Mute feature is disabled" : ((_ya = state.callData) == null ? void 0 : _ya.mute) === 1 ? "Unmute" : "Mute", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Box, { component: "span", sx: isVertical ? { display: "block" } : {}, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25798
25859
|
import_material4.Button,
|
|
25799
25860
|
{
|
|
25800
25861
|
variant: ((_za = state.callData) == null ? void 0 : _za.mute) === 1 && ((_Ba = (_Aa = state.callData) == null ? void 0 : _Aa.status) == null ? void 0 : _Ba.toUpperCase()) === "ONCALL" /* ONCALL */ ? "contained" : "outlined",
|
|
25801
25862
|
startIcon: isVertical ? muteOrUnMuteLoading ? void 0 : ((_Ca = state.callData) == null ? void 0 : _Ca.mute) === 1 ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_MicOff.default, {}) : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_Mic.default, {}) : void 0,
|
|
25802
25863
|
onClick: (e) => {
|
|
25803
|
-
var _a3;
|
|
25804
25864
|
e.stopPropagation();
|
|
25805
|
-
if (!
|
|
25865
|
+
if (!muteFeatureDisabled) {
|
|
25806
25866
|
handleMuteToggle();
|
|
25807
25867
|
}
|
|
25808
25868
|
},
|
|
25809
|
-
sx:
|
|
25810
|
-
disabled: ((
|
|
25869
|
+
sx: muteFeatureDisabled || ((_Da = state.callData) == null ? void 0 : _Da.hold) === 1 ? __spreadValues(__spreadValues({}, disabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : ((_Ea = state.callData) == null ? void 0 : _Ea.mute) === 1 && ((_Ga = (_Fa = state.callData) == null ? void 0 : _Fa.status) == null ? void 0 : _Ga.toUpperCase()) === "ONCALL" /* ONCALL */ ? __spreadValues(__spreadValues({}, enabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : ((_Ia = (_Ha = state.callData) == null ? void 0 : _Ha.status) == null ? void 0 : _Ia.toUpperCase()) === "ONCALL" /* ONCALL */ ? __spreadValues(__spreadValues({}, outlined), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : __spreadValues(__spreadValues({}, disabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }),
|
|
25870
|
+
disabled: ((_Ka = (_Ja = state.callData) == null ? void 0 : _Ja.status) == null ? void 0 : _Ka.toUpperCase()) !== "ONCALL" /* ONCALL */ && ((_La = state.callData) == null ? void 0 : _La.mute) !== 1 || muteOrUnMuteLoading || ((_Ma = state.callData) == null ? void 0 : _Ma.hold) === 1 || muteFeatureDisabled,
|
|
25811
25871
|
children: muteOrUnMuteLoading ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25812
25872
|
import_material4.CircularProgress,
|
|
25813
25873
|
{
|
|
25814
25874
|
size: "20px",
|
|
25815
25875
|
sx: { color: theme.palette.primary.main }
|
|
25816
25876
|
}
|
|
25817
|
-
) : isVertical ? ((
|
|
25877
|
+
) : isVertical ? ((_Na = state.callData) == null ? void 0 : _Na.mute) === 1 ? "Unmute" : "Mute" : ((_Oa = state.callData) == null ? void 0 : _Oa.mute) === 1 ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_MicOff.default, {}) : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_Mic.default, {})
|
|
25818
25878
|
}
|
|
25819
25879
|
) }) }),
|
|
25820
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: ((
|
|
25880
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: ((_Pa = state.sdkConfig) == null ? void 0 : _Pa.disableCallTransferButton) ? "Transfer Call feature is disabled" : "Transfer Call", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Box, { component: "span", sx: isVertical ? { display: "block" } : {}, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25821
25881
|
import_material4.Button,
|
|
25822
25882
|
{
|
|
25823
25883
|
variant: state.openCallTransferDialog ? "contained" : "outlined",
|
|
@@ -25829,12 +25889,12 @@ function CallControls({ onDataChange }) {
|
|
|
25829
25889
|
sdkStateManager.setOpenCallTransferDialog(true);
|
|
25830
25890
|
}
|
|
25831
25891
|
},
|
|
25832
|
-
sx: state.openCallTransferDialog ? __spreadValues(__spreadValues({}, enabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : ((
|
|
25833
|
-
disabled: ((
|
|
25892
|
+
sx: state.openCallTransferDialog ? __spreadValues(__spreadValues({}, enabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : ((_Ra = (_Qa = state.callData) == null ? void 0 : _Qa.status) == null ? void 0 : _Ra.toUpperCase()) === "ONCALL" /* ONCALL */ && !((_Sa = state.sdkConfig) == null ? void 0 : _Sa.disableCallTransferButton) ? __spreadValues(__spreadValues({}, outlined), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : __spreadValues(__spreadValues({}, disabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }),
|
|
25893
|
+
disabled: ((_Ua = (_Ta = state.callData) == null ? void 0 : _Ta.status) == null ? void 0 : _Ua.toUpperCase()) !== "ONCALL" /* ONCALL */ || ((_Va = state.sdkConfig) == null ? void 0 : _Va.disableCallTransferButton),
|
|
25834
25894
|
children: isVertical ? "Transfer" : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_TransferWithinAStation2.default, {})
|
|
25835
25895
|
}
|
|
25836
25896
|
) }) }),
|
|
25837
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: ((
|
|
25897
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: ((_Wa = state.sdkConfig) == null ? void 0 : _Wa.disableConferenceButton) ? "Conference Call feature is disabled" : "Conference Call", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Box, { component: "span", sx: isVertical ? { display: "block" } : {}, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25838
25898
|
import_material4.Button,
|
|
25839
25899
|
{
|
|
25840
25900
|
variant: state.openConferenceDialog ? "contained" : "outlined",
|
|
@@ -25846,12 +25906,12 @@ function CallControls({ onDataChange }) {
|
|
|
25846
25906
|
sdkStateManager.setOpenConferenceDialog(true);
|
|
25847
25907
|
}
|
|
25848
25908
|
},
|
|
25849
|
-
sx: state.openConferenceDialog ? __spreadValues(__spreadValues({}, enabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : ((
|
|
25850
|
-
disabled: ((
|
|
25909
|
+
sx: state.openConferenceDialog ? __spreadValues(__spreadValues({}, enabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : ((_Ya = (_Xa = state.callData) == null ? void 0 : _Xa.status) == null ? void 0 : _Ya.toUpperCase()) === "ONCALL" /* ONCALL */ && !((_Za = state.sdkConfig) == null ? void 0 : _Za.disableConferenceButton) ? __spreadValues(__spreadValues({}, outlined), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : __spreadValues(__spreadValues({}, disabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }),
|
|
25910
|
+
disabled: ((_$a = (__a = state.callData) == null ? void 0 : __a.status) == null ? void 0 : _$a.toUpperCase()) !== "ONCALL" /* ONCALL */ || ((_ab = state.sdkConfig) == null ? void 0 : _ab.disableConferenceButton),
|
|
25851
25911
|
children: isVertical ? "Conference" : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_Group.default, {})
|
|
25852
25912
|
}
|
|
25853
25913
|
) }) }),
|
|
25854
|
-
((
|
|
25914
|
+
((_bb = state.sdkConfig) == null ? void 0 : _bb.enableSmsServices) && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: "Send SMS", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25855
25915
|
import_material4.Button,
|
|
25856
25916
|
{
|
|
25857
25917
|
variant: Boolean(ambulanceAnchorEl) ? "contained" : "outlined",
|
|
@@ -25866,15 +25926,15 @@ function CallControls({ onDataChange }) {
|
|
|
25866
25926
|
}
|
|
25867
25927
|
},
|
|
25868
25928
|
sx: Boolean(ambulanceAnchorEl) ? __spreadValues(__spreadValues({}, enabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : ["ONCALL" /* ONCALL */, "WRAPUP" /* WRAPUP */].includes(
|
|
25869
|
-
(
|
|
25929
|
+
(_db = (_cb = state.callData) == null ? void 0 : _cb.status) == null ? void 0 : _db.toUpperCase()
|
|
25870
25930
|
) ? __spreadValues(__spreadValues({}, outlined), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : __spreadValues(__spreadValues({}, disabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }),
|
|
25871
25931
|
disabled: !["ONCALL" /* ONCALL */, "WRAPUP" /* WRAPUP */].includes(
|
|
25872
|
-
(
|
|
25932
|
+
(_fb = (_eb = state.callData) == null ? void 0 : _eb.status) == null ? void 0 : _fb.toUpperCase()
|
|
25873
25933
|
),
|
|
25874
25934
|
children: isVertical ? "Send SMS" : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_SmsSharp.default, {})
|
|
25875
25935
|
}
|
|
25876
25936
|
) }),
|
|
25877
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: ((
|
|
25937
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: ((_gb = state.sdkConfig) == null ? void 0 : _gb.disableEndCallButton) ? "End Call feature is disabled" : "End Call", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Box, { component: "span", sx: isVertical ? { display: "block" } : {}, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25878
25938
|
import_material4.Button,
|
|
25879
25939
|
{
|
|
25880
25940
|
variant: [
|
|
@@ -25882,7 +25942,7 @@ function CallControls({ onDataChange }) {
|
|
|
25882
25942
|
"RINGING" /* RINGING */,
|
|
25883
25943
|
"DIALING" /* DIALING */,
|
|
25884
25944
|
"WRAPUP" /* WRAPUP */
|
|
25885
|
-
].includes((
|
|
25945
|
+
].includes((_ib = (_hb = state.callData) == null ? void 0 : _hb.status) == null ? void 0 : _ib.toUpperCase()) && !((_jb = state.sdkConfig) == null ? void 0 : _jb.disableEndCallButton) ? "contained" : "outlined",
|
|
25886
25946
|
startIcon: isVertical && !endCallLoading ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_CallEnd2.default, {}) : void 0,
|
|
25887
25947
|
onClick: (e) => {
|
|
25888
25948
|
var _a3, _b2, _c2;
|
|
@@ -25901,7 +25961,7 @@ function CallControls({ onDataChange }) {
|
|
|
25901
25961
|
"RINGING" /* RINGING */,
|
|
25902
25962
|
"DIALING" /* DIALING */,
|
|
25903
25963
|
"WRAPUP" /* WRAPUP */
|
|
25904
|
-
].includes((
|
|
25964
|
+
].includes((_lb = (_kb = state.callData) == null ? void 0 : _kb.status) == null ? void 0 : _lb.toUpperCase()) && !((_mb = state.sdkConfig) == null ? void 0 : _mb.disableEndCallButton) ? __spreadValues(__spreadProps(__spreadValues({}, enabled), {
|
|
25905
25965
|
borderRight: "1px",
|
|
25906
25966
|
backgroundColor: "error.main",
|
|
25907
25967
|
minWidth: "60px !important",
|
|
@@ -25925,11 +25985,11 @@ function CallControls({ onDataChange }) {
|
|
|
25925
25985
|
"RINGING" /* RINGING */,
|
|
25926
25986
|
"DIALING" /* DIALING */,
|
|
25927
25987
|
"WRAPUP" /* WRAPUP */
|
|
25928
|
-
].includes((
|
|
25988
|
+
].includes((_ob = (_nb = state.callData) == null ? void 0 : _nb.status) == null ? void 0 : _ob.toUpperCase()) || endCallLoading || ((_pb = state.sdkConfig) == null ? void 0 : _pb.disableEndCallButton),
|
|
25929
25989
|
children: endCallLoading ? /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.CircularProgress, { size: "20px", color: "error" }) : isVertical ? "End Call" : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_CallEnd2.default, {})
|
|
25930
25990
|
}
|
|
25931
25991
|
) }) }),
|
|
25932
|
-
!((
|
|
25992
|
+
!((_qb = state.sdkConfig) == null ? void 0 : _qb.disabledMoreOptionsButton) && processList && (processList == null ? void 0 : processList.length) > 1 && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Tooltip, { title: "Switch Process", children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
25933
25993
|
import_material4.Button,
|
|
25934
25994
|
{
|
|
25935
25995
|
variant: Boolean(moreOptionsAnchorEl) ? "contained" : "outlined",
|
|
@@ -25945,7 +26005,7 @@ function CallControls({ onDataChange }) {
|
|
|
25945
26005
|
},
|
|
25946
26006
|
sx: Boolean(moreOptionsAnchorEl) ? __spreadValues(__spreadValues({}, enabled), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }) : __spreadValues(__spreadValues({}, outlined), isVertical && { justifyContent: "flex-start", width: "100%", px: 2 }),
|
|
25947
26007
|
disabled: !["BREAK" /* BREAK */, "IDLE" /* IDLE */].includes(
|
|
25948
|
-
(
|
|
26008
|
+
(_sb = (_rb = state.callData) == null ? void 0 : _rb.status) == null ? void 0 : _sb.toUpperCase()
|
|
25949
26009
|
),
|
|
25950
26010
|
children: isVertical ? "Switch Process" : /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_MoreVert.default, {})
|
|
25951
26011
|
}
|
|
@@ -25978,7 +26038,7 @@ function CallControls({ onDataChange }) {
|
|
|
25978
26038
|
transition: theme.transitions.create(["box-shadow", "transform"], {
|
|
25979
26039
|
duration: theme.transitions.duration.short
|
|
25980
26040
|
}),
|
|
25981
|
-
visibility: showIframe && !((
|
|
26041
|
+
visibility: showIframe && !((_tb = state.sdkConfig) == null ? void 0 : _tb.disableSoftPhone) ? "visible" : "hidden",
|
|
25982
26042
|
userSelect: "none"
|
|
25983
26043
|
},
|
|
25984
26044
|
children: [
|
|
@@ -26013,7 +26073,7 @@ function CallControls({ onDataChange }) {
|
|
|
26013
26073
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_material4.Box, { children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
26014
26074
|
"iframe",
|
|
26015
26075
|
{
|
|
26016
|
-
src: `${(
|
|
26076
|
+
src: `${(_ub = state.urlConfig) == null ? void 0 : _ub.iframeURL}/static/phone/index.html?user_id=${(_vb = state.urlConfig) == null ? void 0 : _vb.id}&api_url=${(_wb = state.urlConfig) == null ? void 0 : _wb.iframeAPIURL}&token=${(_xb = state.authorization) == null ? void 0 : _xb.accessToken}`,
|
|
26017
26077
|
height: 380,
|
|
26018
26078
|
width: 420,
|
|
26019
26079
|
allow: "camera; microphone; autoplay",
|