ysyt-react-agent-lib 1.2.19 → 1.2.20
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/{ConsultModel-B_fLiQBh.mjs → ConsultModel-NOhzCzrd.mjs} +2 -2
- package/dist/{ConsultModel-CrHr2sC7.js → ConsultModel-oPMIoo5r.js} +1 -1
- package/dist/{TransferModel-ChcIcMX5.js → TransferModel-1zcxBpkk.js} +1 -1
- package/dist/{TransferModel-CK-_QKxd.mjs → TransferModel-Df3UJnMz.mjs} +2 -2
- package/dist/{index-CPZ7ggaQ.mjs → index-C-DyyNtr.mjs} +236 -236
- package/dist/{index-DHBJa5Bp.js → index-CKrnxkxp.js} +17 -17
- package/dist/{index-B4HQMqho.mjs → index-MdxI5z8R.mjs} +1 -1
- package/dist/{index-B6Kl661y.js → index-ybEs-re3.js} +1 -1
- package/dist/ysyt-react-agent-lib.cjs.js +1 -1
- package/dist/ysyt-react-agent-lib.es.js +1 -1
- package/package.json +2 -2
|
@@ -1685,7 +1685,7 @@ function gE() {
|
|
|
1685
1685
|
function H(K) {
|
|
1686
1686
|
return typeof K == "object" && K !== null && K.$$typeof === t;
|
|
1687
1687
|
}
|
|
1688
|
-
function
|
|
1688
|
+
function J(K) {
|
|
1689
1689
|
return I(K) === s;
|
|
1690
1690
|
}
|
|
1691
1691
|
function Z(K) {
|
|
@@ -1712,7 +1712,7 @@ function gE() {
|
|
|
1712
1712
|
function me(K) {
|
|
1713
1713
|
return I(K) === u;
|
|
1714
1714
|
}
|
|
1715
|
-
Pt.ContextConsumer = f, Pt.ContextProvider = x, Pt.Element = q, Pt.ForwardRef = E, Pt.Fragment = h, Pt.Lazy = y, Pt.Memo = R, Pt.Portal = b, Pt.Profiler = T, Pt.StrictMode = B, Pt.Suspense = D, Pt.SuspenseList = N, Pt.isAsyncMode = Y, Pt.isConcurrentMode = P, Pt.isContextConsumer = U, Pt.isContextProvider = X, Pt.isElement = H, Pt.isForwardRef =
|
|
1715
|
+
Pt.ContextConsumer = f, Pt.ContextProvider = x, Pt.Element = q, Pt.ForwardRef = E, Pt.Fragment = h, Pt.Lazy = y, Pt.Memo = R, Pt.Portal = b, Pt.Profiler = T, Pt.StrictMode = B, Pt.Suspense = D, Pt.SuspenseList = N, Pt.isAsyncMode = Y, Pt.isConcurrentMode = P, Pt.isContextConsumer = U, Pt.isContextProvider = X, Pt.isElement = H, Pt.isForwardRef = J, Pt.isFragment = Z, Pt.isLazy = ee, Pt.isMemo = W, Pt.isPortal = Ae, Pt.isProfiler = le, Pt.isStrictMode = ue, Pt.isSuspense = te, Pt.isSuspenseList = me, Pt.isValidElementType = M, Pt.typeOf = I;
|
|
1716
1716
|
}()), Pt;
|
|
1717
1717
|
}
|
|
1718
1718
|
var of;
|
|
@@ -2028,8 +2028,8 @@ function xE(t) {
|
|
|
2028
2028
|
return function(I) {
|
|
2029
2029
|
var f = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : I, x = r(), q = x.theme, E = x.realToken, h = x.hashId, y = x.token, R = x.cssVar, b = i(), T = b.rootPrefixCls, B = b.iconPrefixCls, D = n(), N = R ? "css" : "js", G = bE(function() {
|
|
2030
2030
|
var H = /* @__PURE__ */ new Set();
|
|
2031
|
-
return R && Object.keys(v.unitless || {}).forEach(function(
|
|
2032
|
-
H.add(Na(
|
|
2031
|
+
return R && Object.keys(v.unitless || {}).forEach(function(J) {
|
|
2032
|
+
H.add(Na(J, R.prefix)), H.add(Na(J, tf(w, R.prefix)));
|
|
2033
2033
|
}), cE(N, H);
|
|
2034
2034
|
}, [N, w, R == null ? void 0 : R.prefix]), L = wE(N), Y = L.max, P = L.min, U = {
|
|
2035
2035
|
theme: q,
|
|
@@ -2060,13 +2060,13 @@ function xE(t) {
|
|
|
2060
2060
|
}), function() {
|
|
2061
2061
|
if (v.injectStyle === !1)
|
|
2062
2062
|
return [];
|
|
2063
|
-
var H = yE(y),
|
|
2063
|
+
var H = yE(y), J = H.token, Z = H.flush, ee = lf(w, E, V), W = ".".concat(I), Ae = af(w, E, ee, {
|
|
2064
2064
|
deprecatedTokens: v.deprecatedTokens
|
|
2065
2065
|
});
|
|
2066
2066
|
R && ee && nt(ee) === "object" && Object.keys(ee).forEach(function(me) {
|
|
2067
2067
|
ee[me] = "var(".concat(Na(me, tf(w, R.prefix)), ")");
|
|
2068
2068
|
});
|
|
2069
|
-
var le = Xt(
|
|
2069
|
+
var le = Xt(J, {
|
|
2070
2070
|
componentCls: W,
|
|
2071
2071
|
prefixCls: I,
|
|
2072
2072
|
iconCls: ".".concat(B),
|
|
@@ -3923,7 +3923,7 @@ function Dy(t, e, n, r) {
|
|
|
3923
3923
|
function H() {
|
|
3924
3924
|
return n();
|
|
3925
3925
|
}
|
|
3926
|
-
var
|
|
3926
|
+
var J = Te(!1);
|
|
3927
3927
|
function Z() {
|
|
3928
3928
|
D(wi), Y(null, !0);
|
|
3929
3929
|
}
|
|
@@ -3932,7 +3932,7 @@ function Dy(t, e, n, r) {
|
|
|
3932
3932
|
if (Ue !== wi) {
|
|
3933
3933
|
var Se = H();
|
|
3934
3934
|
if (!(Qe && !Qe.deadline && Qe.target !== Se)) {
|
|
3935
|
-
var pe =
|
|
3935
|
+
var pe = J.current, Me;
|
|
3936
3936
|
Ue === Va && pe ? Me = I == null ? void 0 : I(Se, Qe) : Ue === va && pe ? Me = f == null ? void 0 : f(Se, Qe) : Ue === Ca && pe && (Me = x == null ? void 0 : x(Se, Qe)), pe && Me !== !1 && Z();
|
|
3937
3937
|
}
|
|
3938
3938
|
}
|
|
@@ -3964,7 +3964,7 @@ function Dy(t, e, n, r) {
|
|
|
3964
3964
|
});
|
|
3965
3965
|
}, u))), ce === zV && Z(), By;
|
|
3966
3966
|
}), K = _(me, 2), de = K[0], ce = K[1], ye = o0(ce);
|
|
3967
|
-
|
|
3967
|
+
J.current = ye;
|
|
3968
3968
|
var Ie = Te(null);
|
|
3969
3969
|
e0(function() {
|
|
3970
3970
|
if (!(U.current && Ie.current === e)) {
|
|
@@ -4279,7 +4279,7 @@ const Wy = (t) => {
|
|
|
4279
4279
|
mentions: U,
|
|
4280
4280
|
modal: X,
|
|
4281
4281
|
progress: H,
|
|
4282
|
-
result:
|
|
4282
|
+
result: J,
|
|
4283
4283
|
slider: Z,
|
|
4284
4284
|
breadcrumb: ee,
|
|
4285
4285
|
menu: W,
|
|
@@ -4369,7 +4369,7 @@ const Wy = (t) => {
|
|
|
4369
4369
|
mentions: U,
|
|
4370
4370
|
modal: X,
|
|
4371
4371
|
progress: H,
|
|
4372
|
-
result:
|
|
4372
|
+
result: J,
|
|
4373
4373
|
slider: Z,
|
|
4374
4374
|
breadcrumb: ee,
|
|
4375
4375
|
menu: W,
|
|
@@ -4644,7 +4644,7 @@ function $y() {
|
|
|
4644
4644
|
B++;
|
|
4645
4645
|
}
|
|
4646
4646
|
}
|
|
4647
|
-
function
|
|
4647
|
+
function J() {
|
|
4648
4648
|
{
|
|
4649
4649
|
if (B--, B === 0) {
|
|
4650
4650
|
var O = {
|
|
@@ -4764,7 +4764,7 @@ function $y() {
|
|
|
4764
4764
|
}
|
|
4765
4765
|
}
|
|
4766
4766
|
} finally {
|
|
4767
|
-
Ae = !1, Z.current = ve,
|
|
4767
|
+
Ae = !1, Z.current = ve, J(), Error.prepareStackTrace = $;
|
|
4768
4768
|
}
|
|
4769
4769
|
var Be = O ? O.displayName || O.name : "", lt = Be ? W(Be) : "";
|
|
4770
4770
|
return typeof O == "function" && le.set(O, lt), lt;
|
|
@@ -10028,7 +10028,7 @@ const ge = { on: (t, e) => (dA.on(t, e), ge), off(t, e) {
|
|
|
10028
10028
|
dA.emit(t, e), dA.emit(je.EVENT_ALL, { event: t, data: e });
|
|
10029
10029
|
}, clearAllListeners() {
|
|
10030
10030
|
dA.all.clear();
|
|
10031
|
-
} },
|
|
10031
|
+
} }, z = { agentInfo: {}, isRtcReconnecting: !1, sessionId: "", enableBrowserAlert: !1, autoStateTimer: null, autoAnswerTimer: null, logBuiltinEnabled: !1, browserAlertTime: 3e3, latency: 0, monitoredAgentNo: "", earSpeakAgent: "", stateObject: { state: xt.BUSY, state_name: "忙碌" } }, Cr = { isCalling: !1, direction: null, outCallIsAnswer: !1, incomingIsAnswer: !1, transferIsAnswer: !1, isMeeting: !1, isHold: !1, displayText: "", isMuted: !1, consultIsAnswer: !1, actionConfigs: [], answerDevice: 1, selectOutNumber: "", customerObject: void 0, isNextState: !0, isSipConnected: !1 }, j = new class extends x0 {
|
|
10032
10032
|
updateIsCalling(t) {
|
|
10033
10033
|
this.setState({ isCalling: t });
|
|
10034
10034
|
}
|
|
@@ -10040,7 +10040,7 @@ const ge = { on: (t, e) => (dA.on(t, e), ge), off(t, e) {
|
|
|
10040
10040
|
}
|
|
10041
10041
|
updateIsHold(t) {
|
|
10042
10042
|
var n;
|
|
10043
|
-
if (((n =
|
|
10043
|
+
if (((n = z.stateObject) == null ? void 0 : n.state) === xt.UNREGISTERED) return;
|
|
10044
10044
|
const e = this.get("actionConfigs");
|
|
10045
10045
|
if (t) {
|
|
10046
10046
|
const r = [...e.filter((i) => i !== "hold")];
|
|
@@ -10055,7 +10055,7 @@ const ge = { on: (t, e) => (dA.on(t, e), ge), off(t, e) {
|
|
|
10055
10055
|
this.setState({ displayText: t }), ge.emit(oe.CALL_PROGRESS, t);
|
|
10056
10056
|
}
|
|
10057
10057
|
updateActionConfigs(t, e = !0) {
|
|
10058
|
-
const { show_satisfaction: n } =
|
|
10058
|
+
const { show_satisfaction: n } = z.agentInfo || {}, r = this.get("answerDevice"), i = t.filter((o) => (n !== 0 || o !== "satisfaction" || !e) && (r !== 2 || o !== "answer"));
|
|
10059
10059
|
this.setState({ actionConfigs: i }), ge.emit(je.PHONE_BAR_OPERATION, i);
|
|
10060
10060
|
}
|
|
10061
10061
|
updateConsultIsAnswer(t) {
|
|
@@ -10063,7 +10063,7 @@ const ge = { on: (t, e) => (dA.on(t, e), ge), off(t, e) {
|
|
|
10063
10063
|
}
|
|
10064
10064
|
updateIsMuted(t) {
|
|
10065
10065
|
var n;
|
|
10066
|
-
if (((n =
|
|
10066
|
+
if (((n = z.stateObject) == null ? void 0 : n.state) === xt.UNREGISTERED) return;
|
|
10067
10067
|
const e = this.get("actionConfigs");
|
|
10068
10068
|
if (t) {
|
|
10069
10069
|
const r = [...e.filter((i) => i !== "mute")];
|
|
@@ -10098,7 +10098,7 @@ const ge = { on: (t, e) => (dA.on(t, e), ge), off(t, e) {
|
|
|
10098
10098
|
this.setState({ customerObject: t });
|
|
10099
10099
|
}
|
|
10100
10100
|
updateIsNextState(t) {
|
|
10101
|
-
this.setState({ isNextState: t }), t ? ge.emit(je.NETWORK_ONLINE) : (
|
|
10101
|
+
this.setState({ isNextState: t }), t ? ge.emit(je.NETWORK_ONLINE) : (z.stateObject = { state: xt.OFFLINE, state_name: "离线" }, this.updateActionConfigs([]), ge.emit(oe.AGENT_STATE, z.stateObject), ge.emit(je.NETWORK_OFFLINE));
|
|
10102
10102
|
}
|
|
10103
10103
|
updateIsSipConnected(t) {
|
|
10104
10104
|
this.setState({ isSipConnected: t });
|
|
@@ -10131,7 +10131,7 @@ let Bw = class {
|
|
|
10131
10131
|
async start() {
|
|
10132
10132
|
const e = Qf.makeURI(`sip:${this.config.user}@${this.config.server}`);
|
|
10133
10133
|
if (!e) throw new Error("无效的SIP配置");
|
|
10134
|
-
const n = { uri: e, authorizationUsername: this.config.user, authorizationPassword: this.config.password, sendInitialProvisionalResponse: !1, transportOptions: { server: this.config.webSocket, connectionTimeout: 10, keepAliveInterval: 20, keepAliveDebounce: 10 }, contactName: this.config.user, contactParams: { transport: "wss" }, userAgentString: "SwiftSIP/2.0.21", sessionDescriptionHandlerFactoryOptions: { alwaysAcquireMediaFirst: !0, peerConnectionConfiguration: { iceServers: [{ urls: "stun:stun.l.google.com:19302" }], iceCandidatePoolSize: 0, iceTransportPolicy: "all", rtcpMuxPolicy: "require", bundlePolicy: "balanced", certificates: void 0, peerIdentity: void 0 }, iceGatheringTimeout: 1e3 }, logBuiltinEnabled:
|
|
10134
|
+
const n = { uri: e, authorizationUsername: this.config.user, authorizationPassword: this.config.password, sendInitialProvisionalResponse: !1, transportOptions: { server: this.config.webSocket, connectionTimeout: 10, keepAliveInterval: 20, keepAliveDebounce: 10 }, contactName: this.config.user, contactParams: { transport: "wss" }, userAgentString: "SwiftSIP/2.0.21", sessionDescriptionHandlerFactoryOptions: { alwaysAcquireMediaFirst: !0, peerConnectionConfiguration: { iceServers: [{ urls: "stun:stun.l.google.com:19302" }], iceCandidatePoolSize: 0, iceTransportPolicy: "all", rtcpMuxPolicy: "require", bundlePolicy: "balanced", certificates: void 0, peerIdentity: void 0 }, iceGatheringTimeout: 1e3 }, logBuiltinEnabled: z.logBuiltinEnabled };
|
|
10135
10135
|
this.userAgent = new Qf(n), this.setupEventListeners(), await this.userAgent.start(), await this.register();
|
|
10136
10136
|
}
|
|
10137
10137
|
setupEventListeners() {
|
|
@@ -10143,7 +10143,7 @@ let Bw = class {
|
|
|
10143
10143
|
n = wr.WEB_RTC_CONNECTING;
|
|
10144
10144
|
break;
|
|
10145
10145
|
case gt.Connected:
|
|
10146
|
-
n = wr.WEB_RTC_CONNECTED, this.reconnectAttempts = 0,
|
|
10146
|
+
n = wr.WEB_RTC_CONNECTED, this.reconnectAttempts = 0, z.isRtcReconnecting = !1, j.updateIsSipConnected(!0), this.reconnectTimer && (clearTimeout(this.reconnectTimer), this.reconnectTimer = null);
|
|
10147
10147
|
break;
|
|
10148
10148
|
case gt.Disconnecting:
|
|
10149
10149
|
n = wr.WEB_RTC_DISCONNECTING, j.updateIsSipConnected(!1);
|
|
@@ -10152,7 +10152,7 @@ let Bw = class {
|
|
|
10152
10152
|
if (j.updateIsSipConnected(!1), this.isManuallyStopped) return void console.warn("[SIP] 手动断开,不触发重连");
|
|
10153
10153
|
ge.emit(je.FAIL_NOTIFICATION, "软电话链接失败"), n = wr.WEB_RTC_DISCONNECTED;
|
|
10154
10154
|
const i = j.get("answerDevice");
|
|
10155
|
-
if (!
|
|
10155
|
+
if (!z.isRtcReconnecting && this.reconnectAttempts < this.maxReconnectAttempts && i === 1) {
|
|
10156
10156
|
this.reconnectAttempts++;
|
|
10157
10157
|
const o = 1e3 * this.reconnectAttempts;
|
|
10158
10158
|
console.warn(`SIP WebSocket 断开,第 ${this.reconnectAttempts} 次尝试重连,${o}ms 后重试...`), this.reconnectTimer = setTimeout(() => {
|
|
@@ -10242,7 +10242,7 @@ let Bw = class {
|
|
|
10242
10242
|
async answerCall() {
|
|
10243
10243
|
var e;
|
|
10244
10244
|
if (!this.incomingInvitation) throw new Error("无来电可接听");
|
|
10245
|
-
|
|
10245
|
+
z.autoAnswerTimer && (clearTimeout(z.autoAnswerTimer), z.autoAnswerTimer = null);
|
|
10246
10246
|
try {
|
|
10247
10247
|
await this.incomingInvitation.accept(), this.activeSession = this.incomingInvitation, this.incomingInvitation = null;
|
|
10248
10248
|
} catch (n) {
|
|
@@ -10293,14 +10293,14 @@ let Bw = class {
|
|
|
10293
10293
|
this.userAgent && (await this.userAgent.stop(), this.userAgent = null);
|
|
10294
10294
|
}
|
|
10295
10295
|
async reconnect() {
|
|
10296
|
-
if (!
|
|
10297
|
-
|
|
10296
|
+
if (!z.isRtcReconnecting) {
|
|
10297
|
+
z.isRtcReconnecting = !0;
|
|
10298
10298
|
try {
|
|
10299
10299
|
await this.destroy(), this.isManuallyStopped = !1, await this.start(), this.isOffline = !1, this.reconnectAttempts = 0;
|
|
10300
10300
|
} catch (e) {
|
|
10301
|
-
console.error("重连失败", e),
|
|
10301
|
+
console.error("重连失败", e), z.isRtcReconnecting = !1;
|
|
10302
10302
|
} finally {
|
|
10303
|
-
|
|
10303
|
+
z.isRtcReconnecting = !1;
|
|
10304
10304
|
}
|
|
10305
10305
|
}
|
|
10306
10306
|
}
|
|
@@ -10314,7 +10314,7 @@ let Bw = class {
|
|
|
10314
10314
|
o.type === "candidate-pair" && o.state === "succeeded" && o.currentRoundTripTime != null && (i.rtt = +(1e3 * o.currentRoundTripTime).toFixed(2)), o.type === "inbound-rtp" && o.kind === "audio" && (i.jitter = +(1e3 * o.jitter).toFixed(2), i.packetsLost = o.packetsLost, i.packetsReceived = o.packetsReceived, o.bytesReceived && o.timestamp && (i.recvBitrate = +(o.bytesReceived / 1024).toFixed(2))), o.type === "outbound-rtp" && o.kind === "audio" && (i.packetsSent = o.packetsSent, o.bytesSent && o.timestamp && (i.sendBitrate = +(o.bytesSent / 1024).toFixed(2))), o.type === "codec" && o.mimeType && (i.codec = o.mimeType);
|
|
10315
10315
|
}), { ...i, rtt: (i == null ? void 0 : i.rtt) || 40 };
|
|
10316
10316
|
}
|
|
10317
|
-
return { rtt:
|
|
10317
|
+
return { rtt: z.latency || 1 };
|
|
10318
10318
|
}
|
|
10319
10319
|
};
|
|
10320
10320
|
class kf extends Error {
|
|
@@ -10756,12 +10756,12 @@ class jA {
|
|
|
10756
10756
|
constructor() {
|
|
10757
10757
|
this.roleData = { agentInfo: () => {
|
|
10758
10758
|
var e;
|
|
10759
|
-
if (!((e =
|
|
10759
|
+
if (!((e = z.agentInfo) != null && e.agent_no)) throw new Error(JSON.stringify({ code: 1, msg: "请先登录" }));
|
|
10760
10760
|
}, requestInfo: (e) => {
|
|
10761
10761
|
if (!e.data) throw new Error(JSON.stringify({ code: 1, msg: 'Parameter "data" is required' }));
|
|
10762
10762
|
}, changeDevice: (e) => {
|
|
10763
10763
|
if (!e) throw new Error(JSON.stringify({ code: 1, msg: 'Parameter "device" is required' }));
|
|
10764
|
-
const { answer_devices: n } =
|
|
10764
|
+
const { answer_devices: n } = z.agentInfo;
|
|
10765
10765
|
if (!n.split(",").map((r) => Number(r)).includes(e)) throw new Error(JSON.stringify({ code: 1, msg: "当前状态不支持" }));
|
|
10766
10766
|
}, changeState: (e, n) => {
|
|
10767
10767
|
if (!e) throw new Error(JSON.stringify({ code: 1, msg: 'Parameter "state" is required' }));
|
|
@@ -10769,7 +10769,7 @@ class jA {
|
|
|
10769
10769
|
if (e === 2 && (n === "通话中" || n === "整理")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态不支持" }));
|
|
10770
10770
|
if (![1, 2].includes(e)) throw new Error(JSON.stringify({ code: 1, msg: "当前状态不支持" }));
|
|
10771
10771
|
}, setAgentExplicit: (e) => {
|
|
10772
|
-
const { out_display_select_switch: n, out_display_data: r } =
|
|
10772
|
+
const { out_display_select_switch: n, out_display_data: r } = z.agentInfo;
|
|
10773
10773
|
if (n !== 1) throw new Error(JSON.stringify({ code: 1, msg: "当前坐席设置未开启允许指定外显" }));
|
|
10774
10774
|
if (!e) throw new Error(JSON.stringify({ code: 1, msg: 'Parameter "number" is required' }));
|
|
10775
10775
|
if (!(r || "").split("#").includes(e)) throw new Error(JSON.stringify({ code: 1, msg: "当前外显号码不存在" }));
|
|
@@ -10779,10 +10779,10 @@ class jA {
|
|
|
10779
10779
|
this.roleData.agentInfo(), this.roleData.requestInfo(e);
|
|
10780
10780
|
const { data: n, success: r } = e, { device: i } = n;
|
|
10781
10781
|
i === 1 && await jA.initRtcFn(), this.roleData.changeDevice(i);
|
|
10782
|
-
const { agent_no: o } =
|
|
10782
|
+
const { agent_no: o } = z.agentInfo;
|
|
10783
10783
|
await ((a) => Kn(`${Dr}/device/change`, a))({ agent_no: o, answer_device: i }), j.updateAnswerDevice(i);
|
|
10784
10784
|
const A = j.get("actionConfigs");
|
|
10785
|
-
j.updateActionConfigs(A), i === 2 &&
|
|
10785
|
+
j.updateActionConfigs(A), i === 2 && z.stateObject.state === xt.UNREGISTERED && await this._changeState({ data: { ...z.stateBeforeChange, state_name: z.stateBeforeChange.state === xt.IDLE ? "空闲" : "忙碌" } }, "q"), r == null || r({ code: 0, msg: "请求成功" });
|
|
10786
10786
|
} catch (n) {
|
|
10787
10787
|
throw ge.emit(je.FAIL_NOTIFICATION, JSON.parse(n.message).msg), n;
|
|
10788
10788
|
}
|
|
@@ -10797,7 +10797,7 @@ class jA {
|
|
|
10797
10797
|
async _agentLogin(e) {
|
|
10798
10798
|
try {
|
|
10799
10799
|
const r = await (n = { agent_no: e }, Kn(`${Dr}/agent/login`, n));
|
|
10800
|
-
|
|
10800
|
+
z.agentInfo = r.data;
|
|
10801
10801
|
} catch (r) {
|
|
10802
10802
|
throw ge.emit(je.FAIL_NOTIFICATION, JSON.parse(r.message).msg), r;
|
|
10803
10803
|
}
|
|
@@ -10805,9 +10805,9 @@ class jA {
|
|
|
10805
10805
|
}
|
|
10806
10806
|
async _changeState(e, n) {
|
|
10807
10807
|
try {
|
|
10808
|
-
|
|
10809
|
-
const { data: r, success: i } = e, { state: o, state_name: A } = r, { agent_no: a } =
|
|
10810
|
-
await Lf({ agent_no: a, state_name: A, state: o }, n), o === xt.IDLE ? j.updateActionConfigs(Zn) : o === xt.BUSY && j.updateActionConfigs(cs),
|
|
10808
|
+
z.autoStateTimer && (clearTimeout(z.autoStateTimer), z.autoStateTimer = null), this.roleData.agentInfo(), this.roleData.requestInfo(e);
|
|
10809
|
+
const { data: r, success: i } = e, { state: o, state_name: A } = r, { agent_no: a } = z.agentInfo;
|
|
10810
|
+
await Lf({ agent_no: a, state_name: A, state: o }, n), o === xt.IDLE ? j.updateActionConfigs(Zn) : o === xt.BUSY && j.updateActionConfigs(cs), z.stateObject = { state: o, state_name: A }, i == null || i({ code: 0, msg: "请求成功" });
|
|
10811
10811
|
} catch (r) {
|
|
10812
10812
|
throw ge.emit(je.FAIL_NOTIFICATION, JSON.parse(r.message).msg), r;
|
|
10813
10813
|
}
|
|
@@ -10826,18 +10826,18 @@ class jA {
|
|
|
10826
10826
|
async changeState(e, n) {
|
|
10827
10827
|
try {
|
|
10828
10828
|
if (j.get("isCalling")) throw new Error(JSON.stringify({ code: 1, msg: "当前正在通话中,请勿切换设备" }));
|
|
10829
|
-
|
|
10829
|
+
z.autoStateTimer && (clearTimeout(z.autoStateTimer), z.autoStateTimer = null), this.roleData.agentInfo(), this.roleData.requestInfo(e);
|
|
10830
10830
|
const { data: r, success: i } = e, { state: o, state_name: A } = r;
|
|
10831
10831
|
this.roleData.changeState(o, A);
|
|
10832
|
-
const { agent_no: a } =
|
|
10833
|
-
await Lf({ agent_no: a, state_name: A, state: o }, n), (
|
|
10832
|
+
const { agent_no: a } = z.agentInfo;
|
|
10833
|
+
await Lf({ agent_no: a, state_name: A, state: o }, n), (z.stateObject.state === xt.IDLE || z.stateObject.state === xt.BUSY && A !== "整理") && (z.stateBeforeChange = z.stateObject), o === xt.IDLE ? j.updateActionConfigs(Zn) : o === xt.BUSY && j.updateActionConfigs(cs), z.stateObject = { state: o, state_name: A }, i == null || i({ code: 0, msg: "请求成功" });
|
|
10834
10834
|
} catch (r) {
|
|
10835
10835
|
throw ge.emit(je.FAIL_NOTIFICATION, JSON.parse(r.message).msg), r;
|
|
10836
10836
|
}
|
|
10837
10837
|
}
|
|
10838
10838
|
async getIdleAgentList(e) {
|
|
10839
10839
|
var r;
|
|
10840
|
-
const { agent_no: n } =
|
|
10840
|
+
const { agent_no: n } = z.agentInfo;
|
|
10841
10841
|
try {
|
|
10842
10842
|
this.roleData.agentInfo();
|
|
10843
10843
|
const i = await ((o) => Kn(`${Dr}/agent/free`, o))({ agent_no: n });
|
|
@@ -10859,7 +10859,7 @@ class jA {
|
|
|
10859
10859
|
var n;
|
|
10860
10860
|
try {
|
|
10861
10861
|
this.roleData.agentInfo(), this.roleData.requestInfo(e), this.roleData.setAgentExplicit(e.data.number);
|
|
10862
|
-
const { agent_id: r } =
|
|
10862
|
+
const { agent_id: r } = z.agentInfo;
|
|
10863
10863
|
await ((i) => Kn(`${Sa}/agent/update`, i))({ agent_id: r, out_display_number: e.data.number }), j.updateSelectOutNumber(e.data.number), (n = e.success) == null || n.call(e, { code: 0, msg: "请求成功" });
|
|
10864
10864
|
} catch (r) {
|
|
10865
10865
|
throw ge.emit(je.FAIL_NOTIFICATION, JSON.parse(r.message).msg), r;
|
|
@@ -10880,7 +10880,7 @@ class jA {
|
|
|
10880
10880
|
async getCallRecord(e) {
|
|
10881
10881
|
try {
|
|
10882
10882
|
this.roleData.agentInfo();
|
|
10883
|
-
const { success: n } = e, r = /* @__PURE__ */ new Date(), i = new Date(r.getFullYear(), r.getMonth(), r.getDate(), 0, 0, 0), o = new Date(r.getFullYear(), r.getMonth(), r.getDate(), 23, 59, 59), A = [this.formatDate(i), this.formatDate(o)], { agent_no: a } =
|
|
10883
|
+
const { success: n } = e, r = /* @__PURE__ */ new Date(), i = new Date(r.getFullYear(), r.getMonth(), r.getDate(), 0, 0, 0), o = new Date(r.getFullYear(), r.getMonth(), r.getDate(), 23, 59, 59), A = [this.formatDate(i), this.formatDate(o)], { agent_no: a } = z.agentInfo, s = await ((g) => Kn(`${Sa}/agent/recordpage`, g))({ start_time: A[0], end_time: A[1], page_no: 1, page_size: 10, agent_no: a }), { code: l, msg: u, data: d } = s;
|
|
10884
10884
|
n == null || n({ code: l, msg: u, data: d });
|
|
10885
10885
|
} catch (n) {
|
|
10886
10886
|
throw ge.emit(je.FAIL_NOTIFICATION, JSON.parse(n.message).msg), n;
|
|
@@ -10889,7 +10889,7 @@ class jA {
|
|
|
10889
10889
|
async logout(e) {
|
|
10890
10890
|
this.roleData.agentInfo();
|
|
10891
10891
|
try {
|
|
10892
|
-
const { agent_no: n } =
|
|
10892
|
+
const { agent_no: n } = z.agentInfo, { data: r, success: i } = e;
|
|
10893
10893
|
await ((o) => Kn(`${Dr}/agent/logout`, o))({ ...r, agent_no: n }), i == null || i({ code: 0, msg: "" });
|
|
10894
10894
|
} catch (n) {
|
|
10895
10895
|
throw ge.emit(je.FAIL_NOTIFICATION, JSON.parse(n.message).msg), n;
|
|
@@ -10897,16 +10897,16 @@ class jA {
|
|
|
10897
10897
|
}
|
|
10898
10898
|
async listenCall(e) {
|
|
10899
10899
|
try {
|
|
10900
|
-
const { agent_no: n } =
|
|
10900
|
+
const { agent_no: n } = z.agentInfo, { data: r, success: i } = e;
|
|
10901
10901
|
if (this.roleData.agentInfo(), this.roleData.requestInfo(e), !r.monitored_agent_no) throw new Error(JSON.stringify({ code: 1, msg: 'Parameter "monitored_agent_no" is required' }));
|
|
10902
|
-
await ((o) => Kn(`${Dr}/call/monitor`, o))({ ...r, monitor_agent_no: n }),
|
|
10902
|
+
await ((o) => Kn(`${Dr}/call/monitor`, o))({ ...r, monitor_agent_no: n }), z.monitoredAgentNo = r.monitored_agent_no, i == null || i({ code: 0, msg: "" });
|
|
10903
10903
|
} catch (n) {
|
|
10904
10904
|
throw ge.emit(je.FAIL_NOTIFICATION, JSON.parse(n.message).msg), n;
|
|
10905
10905
|
}
|
|
10906
10906
|
}
|
|
10907
10907
|
async earCall(e) {
|
|
10908
10908
|
try {
|
|
10909
|
-
const { agentInfo: n, monitoredAgentNo: r } =
|
|
10909
|
+
const { agentInfo: n, monitoredAgentNo: r } = z, { agent_no: i } = n;
|
|
10910
10910
|
this.roleData.agentInfo();
|
|
10911
10911
|
const { success: o } = e;
|
|
10912
10912
|
if (!r) throw new Error(JSON.stringify({ code: 1, msg: "当前未有监听坐席" }));
|
|
@@ -10917,7 +10917,7 @@ class jA {
|
|
|
10917
10917
|
}
|
|
10918
10918
|
async stopEarCall(e) {
|
|
10919
10919
|
try {
|
|
10920
|
-
const { agentInfo: n, earSpeakAgent: r } =
|
|
10920
|
+
const { agentInfo: n, earSpeakAgent: r } = z;
|
|
10921
10921
|
if (!r) throw new Error(JSON.stringify({ code: 1, msg: "当前没有正在耳语的坐席" }));
|
|
10922
10922
|
const { agent_no: i } = n;
|
|
10923
10923
|
this.roleData.agentInfo();
|
|
@@ -10929,7 +10929,7 @@ class jA {
|
|
|
10929
10929
|
}
|
|
10930
10930
|
async forceInsert(e) {
|
|
10931
10931
|
try {
|
|
10932
|
-
const { agentInfo: n, monitoredAgentNo: r } =
|
|
10932
|
+
const { agentInfo: n, monitoredAgentNo: r } = z, { agent_no: i } = n;
|
|
10933
10933
|
this.roleData.agentInfo();
|
|
10934
10934
|
const { success: o } = e;
|
|
10935
10935
|
if (!r) throw new Error(JSON.stringify({ code: 1, msg: "当前未有监听坐席" }));
|
|
@@ -10940,7 +10940,7 @@ class jA {
|
|
|
10940
10940
|
}
|
|
10941
10941
|
async forceDisconnect(e) {
|
|
10942
10942
|
try {
|
|
10943
|
-
const { agentInfo: n, monitoredAgentNo: r } =
|
|
10943
|
+
const { agentInfo: n, monitoredAgentNo: r } = z, { agent_no: i } = n;
|
|
10944
10944
|
this.roleData.agentInfo();
|
|
10945
10945
|
const { success: o } = e;
|
|
10946
10946
|
if (!r) throw new Error(JSON.stringify({ code: 1, msg: "当前未有监听坐席" }));
|
|
@@ -10951,7 +10951,7 @@ class jA {
|
|
|
10951
10951
|
}
|
|
10952
10952
|
}
|
|
10953
10953
|
const nS = console.log, Kf = (...t) => {
|
|
10954
|
-
|
|
10954
|
+
z.logBuiltinEnabled && nS(...t);
|
|
10955
10955
|
};
|
|
10956
10956
|
let oi = null;
|
|
10957
10957
|
class ln {
|
|
@@ -10969,16 +10969,16 @@ class ln {
|
|
|
10969
10969
|
this.sipClient = e;
|
|
10970
10970
|
}
|
|
10971
10971
|
stateIdleChange(e) {
|
|
10972
|
-
const { state: n } =
|
|
10973
|
-
n !== xt.IDLE && this.apiClient._changeState({ data: { ...
|
|
10972
|
+
const { state: n } = z.stateObject;
|
|
10973
|
+
n !== xt.IDLE && this.apiClient._changeState({ data: { ...z.stateBeforeChange, state_name: z.stateBeforeChange.state === xt.IDLE ? "空闲" : "忙碌" } }, e);
|
|
10974
10974
|
}
|
|
10975
10975
|
inCallAutoAnswer() {
|
|
10976
|
-
const { soft_device_auto_answer: e, auto_answer_time: n } =
|
|
10976
|
+
const { soft_device_auto_answer: e, auto_answer_time: n } = z.agentInfo, r = e === 1, i = j.get("direction");
|
|
10977
10977
|
if (r && i === bn.INCOMING) {
|
|
10978
10978
|
const o = Number(n) || 0;
|
|
10979
|
-
o > 0 && (
|
|
10979
|
+
o > 0 && (z.autoAnswerTimer = setTimeout(() => {
|
|
10980
10980
|
var A;
|
|
10981
|
-
(A = this.sipClient) == null || A.answerCall(),
|
|
10981
|
+
(A = this.sipClient) == null || A.answerCall(), z.autoAnswerTimer = null;
|
|
10982
10982
|
}, 1e3 * o - 500));
|
|
10983
10983
|
}
|
|
10984
10984
|
}
|
|
@@ -10993,18 +10993,18 @@ class ln {
|
|
|
10993
10993
|
putAgentState(e, n) {
|
|
10994
10994
|
if (!e) return;
|
|
10995
10995
|
if (n === 5) return void this.stateIdleChange("device_type5");
|
|
10996
|
-
|
|
10997
|
-
const { post_call_process_time: r } =
|
|
10998
|
-
if (
|
|
10999
|
-
const { state: o } =
|
|
10996
|
+
z.sessionId = "";
|
|
10997
|
+
const { post_call_process_time: r } = z.agentInfo, i = r || 0;
|
|
10998
|
+
if (z.autoStateTimer && (clearTimeout(z.autoStateTimer), z.autoStateTimer = null), j.updateCustomerInfo(void 0), i > 0) {
|
|
10999
|
+
const { state: o } = z.stateObject;
|
|
11000
11000
|
if (o === xt.IDLE) return;
|
|
11001
|
-
this.apiClient._changeState({ data: { state: xt.BUSY, state_name: "整理" } }, "ez"),
|
|
11002
|
-
|
|
11001
|
+
this.apiClient._changeState({ data: { state: xt.BUSY, state_name: "整理" } }, "ez"), z.autoStateTimer = setTimeout(() => {
|
|
11002
|
+
z.autoStateTimer = null, this.stateIdleChange(`delay${i}`);
|
|
11003
11003
|
}, 1e3 * i);
|
|
11004
11004
|
} else this.stateIdleChange("delay0");
|
|
11005
11005
|
}
|
|
11006
11006
|
stateBusyChange() {
|
|
11007
|
-
|
|
11007
|
+
z.sessionId = "", clearTimeout(z.autoStateTimer), j.updateCustomerInfo(void 0), this.apiClient._changeState({ data: { state: xt.BUSY, state_name: "忙碌" } }, "dm");
|
|
11008
11008
|
}
|
|
11009
11009
|
initWebSocket() {
|
|
11010
11010
|
var n;
|
|
@@ -11018,43 +11018,43 @@ class ln {
|
|
|
11018
11018
|
const i = JSON.parse(r.data), { type: o, data: A, code: a, msg: s, msg_id: l } = i;
|
|
11019
11019
|
if (o === 0 && l) {
|
|
11020
11020
|
const d = this.pendingMessages.get(l), g = performance.now() - d;
|
|
11021
|
-
|
|
11021
|
+
z.latency = parseFloat(g.toFixed(2)), this.pendingMessages.delete(l);
|
|
11022
11022
|
}
|
|
11023
11023
|
if (o !== 0 && Kf("%cWebSocket 收到消息:", "color: blue; font-weight: bold;", i), o !== it.OUT_CALL && o !== it.PREVIEW_OUT_CALL || (a !== 0 ? (j.reset(), ge.emit(oe.OUT_FAILED, s), ge.emit(je.FAIL_NOTIFICATION, s), j.updateActionConfigs(Zn), setTimeout(() => {
|
|
11024
11024
|
j.updateCustomerInfo(void 0);
|
|
11025
|
-
}, 500), this.stateIdleChange("h")) : a === 0 && (ge.emit(oe.OUT_SUCCESS), clearTimeout(
|
|
11025
|
+
}, 500), this.stateIdleChange("h")) : a === 0 && (ge.emit(oe.OUT_SUCCESS), z.sessionId = A.session_id, clearTimeout(z.autoStateTimer))), o === it.AGENT_STATE) {
|
|
11026
11026
|
const { state: d, state_name: g } = A;
|
|
11027
|
-
|
|
11027
|
+
z.stateObject = { state: d, state_name: g }, (u = z.stateBeforeChange) != null && u.state || z.stateObject.state !== xt.IDLE && (z.stateObject.state !== xt.BUSY || g === "整理") || (z.stateBeforeChange = z.stateObject), g === "振铃中" && j.updateDisplayText(Zt.AGENT_RINGING);
|
|
11028
11028
|
const p = j.get("isCalling");
|
|
11029
|
-
d !== xt.UNREGISTERED || p || j.updateActionConfigs(zw), d === xt.IDLE &&
|
|
11029
|
+
d !== xt.UNREGISTERED || p || j.updateActionConfigs(zw), d === xt.IDLE && z.stateObject.state === xt.UNREGISTERED && j.updateActionConfigs(Zn), ge.emit(oe.AGENT_STATE, { state: d, state_name: g });
|
|
11030
11030
|
} else if (o === it.OUT_CALL_INCOMING_CALL) {
|
|
11031
11031
|
try {
|
|
11032
11032
|
await this.getCustomerInfo(A.trace_id || A.customer_phone);
|
|
11033
11033
|
} catch (d) {
|
|
11034
11034
|
console.error(d);
|
|
11035
11035
|
}
|
|
11036
|
-
A.preview_task_id ? ge.emit(oe.PREVIEW_OUT_INCOMING_CALL, { customer_phone: A.customer_phone, session_id: A.session_id, preview_task_id: A.preview_task_id, trace_id: A.trace_id }) : A.direction === 0 ? ge.emit(oe.OUT_INCOMING_CALL, { customer_phone: A.customer_phone, session_id: A.session_id, trace_id: A.trace_id }) : A.direction === 8 && ge.emit(oe.INTERNAL_OUT_INCOMING_CALL, { customer_phone: A.customer_phone, session_id: A.session_id, trace_id: A.trace_id }),
|
|
11036
|
+
A.preview_task_id ? ge.emit(oe.PREVIEW_OUT_INCOMING_CALL, { customer_phone: A.customer_phone, session_id: A.session_id, preview_task_id: A.preview_task_id, trace_id: A.trace_id }) : A.direction === 0 ? ge.emit(oe.OUT_INCOMING_CALL, { customer_phone: A.customer_phone, session_id: A.session_id, trace_id: A.trace_id }) : A.direction === 8 && ge.emit(oe.INTERNAL_OUT_INCOMING_CALL, { customer_phone: A.customer_phone, session_id: A.session_id, trace_id: A.trace_id }), z.sessionId = A.session_id, j.updateActionConfigs(Jw, A.direction !== 8);
|
|
11037
11037
|
} else if (o === it.OUT_CALL_END) {
|
|
11038
|
-
if (
|
|
11039
|
-
if (j.updateDisplayText(""), A.device_type === 1 && A.agent_no ===
|
|
11040
|
-
else if (A.device_type === 2 && A.agent_no ===
|
|
11041
|
-
else if (A.device_type === 2 && A.agent_no !==
|
|
11038
|
+
if (z.sessionId !== A.session_id) return;
|
|
11039
|
+
if (j.updateDisplayText(""), A.device_type === 1 && A.agent_no === z.agentInfo.agent_no) j.reset(), ge.emit(oe.OUT_HANGUP, { session_id: A.session_id }), j.updateActionConfigs(Zn), this.putAgentState(!0);
|
|
11040
|
+
else if (A.device_type === 2 && A.agent_no === z.agentInfo.agent_no) j.reset(), ge.emit(oe.OUR_SIDE_CONSULT_HANGUP, { session_id: A.session_id }), j.updateActionConfigs(Zn), this.putAgentState(!0);
|
|
11041
|
+
else if (A.device_type === 2 && A.agent_no !== z.agentInfo.agent_no)
|
|
11042
11042
|
j.get("isCalling") && (j.updateDisplayText(Zt.CALLING), ge.emit(oe.OTHER_SIDE_CONSULT_HANGUP, { session_id: A.session_id }), j.updateActionConfigs(Ei));
|
|
11043
|
-
else if (A.device_type === 3 && A.agent_no ===
|
|
11044
|
-
else if (A.device_type === 4 && A.agent_no ===
|
|
11045
|
-
else if (A.device_type === 4 && A.agent_no !==
|
|
11043
|
+
else if (A.device_type === 3 && A.agent_no === z.agentInfo.agent_no) j.reset(), ge.emit(oe.THREE_WAY_OUR_SIDE_HANGUP, { session_id: A.session_id }), j.updateActionConfigs(Zn), this.putAgentState(!0);
|
|
11044
|
+
else if (A.device_type === 4 && A.agent_no === z.agentInfo.agent_no) j.reset(), ge.emit(oe.TRANSFER_END, { session_id: A.session_id }), j.updateActionConfigs(Zn), this.putAgentState(!0);
|
|
11045
|
+
else if (A.device_type === 4 && A.agent_no !== z.agentInfo.agent_no) {
|
|
11046
11046
|
ge.emit(oe.TRANSFER_FAILED, "未知原因"), ge.emit(je.FAIL_NOTIFICATION, "转接失败");
|
|
11047
11047
|
const d = j.get("direction");
|
|
11048
11048
|
d === bn.OUTGOING ? j.updateActionConfigs(Ei) : d === bn.INCOMING && j.updateActionConfigs(Li);
|
|
11049
|
-
} else A.device_type === 5 && A.agent_no ===
|
|
11050
|
-
} else if (o === it.OUT_CALL_RINGING) A.type === 1 && (ge.emit(oe.OUT_RINGING, { session_id:
|
|
11051
|
-
else if (o === it.OUT_CALL_ANSWER) clearTimeout(
|
|
11052
|
-
else if (o === it.CONSULT_RINGING) ge.emit(oe.CONSULT_RINGING, { session_id: A.session_id }), j.updateDisplayText(Zt.AGENT_RINGING), j.updateActionConfigs([]), clearTimeout(
|
|
11049
|
+
} else A.device_type === 5 && A.agent_no === z.agentInfo.agent_no && (z.monitoredAgentNo = "", z.earSpeakAgent = "", j.reset(), ge.emit(oe.LISTEN_HANGUP, { session_id: A.session_id }), j.updateActionConfigs(Zn), this.putAgentState(!0, 5));
|
|
11050
|
+
} else if (o === it.OUT_CALL_RINGING) A.type === 1 && (ge.emit(oe.OUT_RINGING, { session_id: z.sessionId, type: A.type }), j.updateDisplayText(Zt.RINGING));
|
|
11051
|
+
else if (o === it.OUT_CALL_ANSWER) clearTimeout(z.autoStateTimer), j.updateIsCalling(!0), j.updateOutCallIsAnswer(!0), j.updateDisplayText(Zt.CALLING), A.direction === 8 ? (ge.emit(oe.INTERNAL_OUT_OFF_ANSWER, { session_id: z.sessionId }), j.updateActionConfigs(Pl)) : (ge.emit(oe.OUT_OFF_ANSWER, { session_id: z.sessionId }), j.updateActionConfigs(Ei));
|
|
11052
|
+
else if (o === it.CONSULT_RINGING) ge.emit(oe.CONSULT_RINGING, { session_id: A.session_id }), j.updateDisplayText(Zt.AGENT_RINGING), j.updateActionConfigs([]), clearTimeout(z.autoStateTimer);
|
|
11053
11053
|
else if (o === it.CONSULT_ANSWER) ge.emit(oe.CONSULT_OFF_HOOK, { session_id: A.session_id }), j.updateConsultIsAnswer(!0), j.updateDisplayText(Zt.CONSULTING), j.updateActionConfigs(Yf);
|
|
11054
11054
|
else if (o === it.CONSULT_FAIL) ge.emit(oe.CONSULT_FAILED, { custom_reason: A.custom_reason }), j.updateDisplayText(Zt.CALLING), j.updateActionConfigs(Ei);
|
|
11055
|
-
else if (o === it.CONSULT_CALL_IN) ge.emit(oe.CONSULT_INCOMING, { agent_no: A.agent_no, agent_mane: A.agent_name, session_id: A.session_id }),
|
|
11055
|
+
else if (o === it.CONSULT_CALL_IN) ge.emit(oe.CONSULT_INCOMING, { agent_no: A.agent_no, agent_mane: A.agent_name, session_id: A.session_id }), z.sessionId = A.session_id, j.updateIsCalling(!0), j.updateDirection(bn.CONSULT), j.updateDisplayText(Zt.CONSULT_CALL_IN), j.updateActionConfigs(Ia), z.enableBrowserAlert && xo.show("📞 咨询来电", `坐席 [${A.agent_name}] 正在咨询...`, () => {
|
|
11056
11056
|
ge.emit(je.NOTIFICATION_CLICK, { agent_mane: A.agent_name, agent_no: A.agent_no });
|
|
11057
|
-
},
|
|
11057
|
+
}, z.browserAlertTime);
|
|
11058
11058
|
else if (o === it.CONSULT_CALL_IN_SUCCESS) ge.emit(oe.CONSULT_CALL_IN_SUCCESS, { session_id: A.session_id }), j.updateConsultIsAnswer(!0), j.updateDisplayText(Zt.CALLING), j.updateActionConfigs(Ww);
|
|
11059
11059
|
else if (o === it.CONSULT_RETURN_CALL_SUCCESS) A.status === "success" ? (j.updateConsultIsAnswer(!1), ge.emit(oe.CONSULT_RETURN_CALL_SUCCESS), j.updateDisplayText(Zt.CALLING), ge.emit(oe.OTHER_SIDE_CONSULT_HANGUP), j.updateActionConfigs(Ei)) : ge.emit(je.FAIL_NOTIFICATION, "媒体失败");
|
|
11060
11060
|
else if (o === it.MUTE) a === 0 ? (j.updateIsMuted(!0), ge.emit(oe.MUTE_SUCCESS), j.updateDisplayText(Zt.MUTING)) : (ge.emit(oe.MUTE_FAILED, s), ge.emit(je.FAIL_NOTIFICATION, s));
|
|
@@ -11065,44 +11065,44 @@ class ln {
|
|
|
11065
11065
|
else if (o === it.CONSULT_TRANSFER_FAILED) ge.emit(oe.CONSULT_TRANSFER_FAILED, A.status);
|
|
11066
11066
|
else if (o === it.CONSULT_TRANSFER_OFF_HOOK) j.updateDirection(bn.INCOMING), j.updateDisplayText(Zt.CALLING), ge.emit(oe.CONSULT_TRANSFER_OFF_HOOK), j.updateActionConfigs(Li), j.updateIncomingIsAnswer(!0), j.updateConsultIsAnswer(!1);
|
|
11067
11067
|
else if (o === it.INCOMING_CALL) {
|
|
11068
|
-
clearTimeout(
|
|
11068
|
+
clearTimeout(z.autoStateTimer), z.sessionId = A.session_id;
|
|
11069
11069
|
try {
|
|
11070
11070
|
await this.getCustomerInfo(A.trace_id || A.customer_phone);
|
|
11071
11071
|
} catch (d) {
|
|
11072
11072
|
console.error(d);
|
|
11073
11073
|
}
|
|
11074
|
-
j.updateIsCalling(!0), j.updateDirection(bn.INCOMING), j.updateDisplayText(Zt.INCOMING_CALL), this.inCallAutoAnswer(), A.direction === 1 && ge.emit(oe.INCOMING_CALL, { customer_phone: A.customer_phone, trace_id: A.trace_id, session_id: A.session_id }), A.direction === 8 && ge.emit(oe.INCOMING_CALL_IN, { customer_phone: A.customer_phone, trace_id: A.trace_id, session_id: A.session_id }), A.direction === 3 && ge.emit(oe.PREDICT_INCOMING_CALL, { customer_phone: A.customer_phone, trace_id: A.trace_id, session_id: A.session_id }), A.direction === 6 && ge.emit(oe.DUAL_CALL_INCOMING_CALL, { customer_phone: A.customer_phone, trace_id: A.trace_id, session_id: A.session_id }), j.updateActionConfigs(Ia),
|
|
11074
|
+
j.updateIsCalling(!0), j.updateDirection(bn.INCOMING), j.updateDisplayText(Zt.INCOMING_CALL), this.inCallAutoAnswer(), A.direction === 1 && ge.emit(oe.INCOMING_CALL, { customer_phone: A.customer_phone, trace_id: A.trace_id, session_id: A.session_id }), A.direction === 8 && ge.emit(oe.INCOMING_CALL_IN, { customer_phone: A.customer_phone, trace_id: A.trace_id, session_id: A.session_id }), A.direction === 3 && ge.emit(oe.PREDICT_INCOMING_CALL, { customer_phone: A.customer_phone, trace_id: A.trace_id, session_id: A.session_id }), A.direction === 6 && ge.emit(oe.DUAL_CALL_INCOMING_CALL, { customer_phone: A.customer_phone, trace_id: A.trace_id, session_id: A.session_id }), j.updateActionConfigs(Ia), z.enableBrowserAlert && xo.show("📞 客户来电", `客户 [${A.customer_phone}] 正在呼入...`, () => {
|
|
11075
11075
|
ge.emit(je.NOTIFICATION_CLICK, { customer_phone: A.customer_phone });
|
|
11076
|
-
},
|
|
11077
|
-
} else if (o === it.INCOMING_CALL_OFF_HOOK) j.updateIncomingIsAnswer(!0), A.direction === 8 ? (j.updateActionConfigs(Pl), ge.emit(oe.INCOMING_CALL_IN_OFF_HOOK, { session_id:
|
|
11076
|
+
}, z.browserAlertTime);
|
|
11077
|
+
} else if (o === it.INCOMING_CALL_OFF_HOOK) j.updateIncomingIsAnswer(!0), A.direction === 8 ? (j.updateActionConfigs(Pl), ge.emit(oe.INCOMING_CALL_IN_OFF_HOOK, { session_id: z.sessionId })) : (j.updateActionConfigs(Li), ge.emit(oe.INCOMING_CALL_OFF_HOOK, { session_id: z.sessionId })), j.updateDisplayText(Zt.CALLING);
|
|
11078
11078
|
else if (o === it.INCOMING_CALL_END) {
|
|
11079
|
-
if (
|
|
11080
|
-
if (j.updateDisplayText(""), A.device_type !== 1 && A.device_type !== 7 || A.agent_no !==
|
|
11081
|
-
else if (A.device_type === 2 && A.agent_no !==
|
|
11082
|
-
else if (A.device_type === 3 && A.agent_no ===
|
|
11083
|
-
else if (A.device_type === 4 && A.agent_no ===
|
|
11084
|
-
else if (A.device_type === 4 && A.agent_no !==
|
|
11079
|
+
if (z.sessionId !== A.session_id) return;
|
|
11080
|
+
if (j.updateDisplayText(""), A.device_type !== 1 && A.device_type !== 7 || A.agent_no !== z.agentInfo.agent_no) if (A.device_type === 2 && A.agent_no === z.agentInfo.agent_no) j.reset(), ge.emit(oe.OUR_SIDE_CONSULT_HANGUP, { session_id: A.session_id }), this.putAgentState(!0), j.updateActionConfigs(Zn);
|
|
11081
|
+
else if (A.device_type === 2 && A.agent_no !== z.agentInfo.agent_no) j.updateDisplayText(Zt.CALLING), ge.emit(oe.OTHER_SIDE_CONSULT_HANGUP, { session_id: A.session_id }), j.updateActionConfigs(Ei);
|
|
11082
|
+
else if (A.device_type === 3 && A.agent_no === z.agentInfo.agent_no) this.putAgentState(!0), j.reset(), ge.emit(oe.THREE_WAY_OUR_SIDE_HANGUP, { session_id: A.session_id }), j.updateActionConfigs(Zn);
|
|
11083
|
+
else if (A.device_type === 4 && A.agent_no === z.agentInfo.agent_no) this.putAgentState(!0), j.reset(), ge.emit(oe.TRANSFER_END, { session_id: A.session_id }), j.updateActionConfigs(Zn);
|
|
11084
|
+
else if (A.device_type === 4 && A.agent_no !== z.agentInfo.agent_no) {
|
|
11085
11085
|
ge.emit(oe.TRANSFER_FAILED, "未知原因"), ge.emit(je.FAIL_NOTIFICATION, "转接失败");
|
|
11086
11086
|
const d = j.get("direction");
|
|
11087
11087
|
d === bn.OUTGOING ? j.updateActionConfigs(Ei) : d === bn.INCOMING && j.updateActionConfigs(Li);
|
|
11088
|
-
} else A.device_type === 5 && A.agent_no ===
|
|
11088
|
+
} else A.device_type === 5 && A.agent_no === z.agentInfo.agent_no && (this.putAgentState(!0, 5), z.monitoredAgentNo = "", z.earSpeakAgent = "", j.reset(), ge.emit(oe.LISTEN_HANGUP, { session_id: A.session_id }), j.updateActionConfigs(Zn));
|
|
11089
11089
|
else this.putAgentState(!0), j.reset(), ge.emit(oe.INCOMING_CALL_END, { session_id: A.session_id }), j.updateActionConfigs(Zn);
|
|
11090
11090
|
} else if (o === it.SATISFACTION_EVALUATION) a === 0 ? ge.emit(oe.SATISFACTION_EVALUATION_SUCCESS) : (ge.emit(oe.SATISFACTION_EVALUATION_FAILED, s), ge.emit(je.FAIL_NOTIFICATION, s));
|
|
11091
11091
|
else if (o === it.CONSULT_THREE_WAY) a !== 0 ? (ge.emit(oe.CONSULT_THREE_WAY_FAILED, s), ge.emit(je.FAIL_NOTIFICATION, s)) : a === 0 && j.updateIsMeeting(!0);
|
|
11092
11092
|
else if (o === it.CONSULT_THREE_WAY_RESULT) A.status === "success" ? (j.updateDirection(bn.MEETING), j.updateDisplayText(Zt.MEETING), j.updateActionConfigs(Xw), ge.emit(oe.CONSULT_THREE_WAY_SUCCESS)) : (ge.emit(oe.CONSULT_THREE_WAY_FAILED, { conf_name: A.conf_name }), j.updateIsMeeting(!1));
|
|
11093
|
-
else if (o === it.TRANSFER_INCOMING_CALL) clearTimeout(
|
|
11093
|
+
else if (o === it.TRANSFER_INCOMING_CALL) clearTimeout(z.autoStateTimer), A.agent_no === z.agentInfo.agent_no ? (j.updateDisplayText(Zt.TRANSFERRING), ge.emit(oe.TRANSFER_PROGRESS), j.updateActionConfigs([]), j.updateTransferIsAnswer(!0)) : (z.sessionId = A.session_id, ge.emit(oe.TRANSFER_INCOMING_CALL, { agent_no: A.agent_no, agent_name: A.agent_name, session_id: A.session_id }), j.updateIsCalling(!0), j.updateDirection(bn.TRANSFER), j.updateDisplayText(Zt.TRANSFER_INCOMING_CALL), j.updateActionConfigs(Ia), z.enableBrowserAlert && xo.show("📞 转接来电", `坐席 [${A.agent_no}] 正在转接...`, () => {
|
|
11094
11094
|
ge.emit(je.NOTIFICATION_CLICK, { agent_no: A.agent_no });
|
|
11095
|
-
},
|
|
11096
|
-
else if (o === it.TRANSFER_OFF_HOOK) ge.emit(oe.TRANSFER_OFF_HOOK, { session_id:
|
|
11095
|
+
}, z.browserAlertTime));
|
|
11096
|
+
else if (o === it.TRANSFER_OFF_HOOK) ge.emit(oe.TRANSFER_OFF_HOOK, { session_id: z.sessionId }), j.updateTransferIsAnswer(!1), j.updateDisplayText(Zt.CALLING), j.updateActionConfigs(Li, A.direction !== 8);
|
|
11097
11097
|
else if (o === it.TRANSFER_FAILED) {
|
|
11098
11098
|
if (A.status === "failed") {
|
|
11099
11099
|
ge.emit(oe.TRANSFER_FAILED, "未知原因"), ge.emit(je.FAIL_NOTIFICATION, "转接失败");
|
|
11100
11100
|
const d = j.get("direction");
|
|
11101
11101
|
d === bn.OUTGOING ? j.updateActionConfigs(Ei) : d === bn.INCOMING && j.updateActionConfigs(Li);
|
|
11102
11102
|
}
|
|
11103
|
-
} else o === it.KICK_OFFLINE ? ge.emit(je.KICK_OFF) : o === it.CONTINUOUS_NOT_ANSWER ? (ge.emit(je.FAIL_NOTIFICATION, `已连续 ${A.miss_count} 次未接, 设置忙碌`), this.stateBusyChange()) : o === it.SIGN_OUT ? ge.emit(je.SIGN_OUT) : o === it.SIGN_IN_SWITCH_DEVICE ? ge.emit(je.SIGN_IN_SWITCH_DEVICE, A) : o === it.LISTEN_INCOMING_CALL ? (clearTimeout(
|
|
11103
|
+
} else o === it.KICK_OFFLINE ? ge.emit(je.KICK_OFF) : o === it.CONTINUOUS_NOT_ANSWER ? (ge.emit(je.FAIL_NOTIFICATION, `已连续 ${A.miss_count} 次未接, 设置忙碌`), this.stateBusyChange()) : o === it.SIGN_OUT ? ge.emit(je.SIGN_OUT) : o === it.SIGN_IN_SWITCH_DEVICE ? ge.emit(je.SIGN_IN_SWITCH_DEVICE, A) : o === it.LISTEN_INCOMING_CALL ? (clearTimeout(z.autoStateTimer), z.sessionId = A.session_id, j.updateIsCalling(!0), j.updateDirection(bn.INCOMING), this.inCallAutoAnswer(), j.updateDisplayText(Zt.LISTENING), j.updateActionConfigs(Ia), ge.emit(oe.LISTEN_INCOMING_CALL, { session_id: A.session_id }), z.enableBrowserAlert && xo.show("📞 监听来电", "正在来电...", () => {
|
|
11104
11104
|
ge.emit(je.NOTIFICATION_CLICK, { customer_phone: A.customer_phone });
|
|
11105
|
-
},
|
|
11105
|
+
}, z.browserAlertTime)) : o === it.LISTEN_INCOMING_CALL_OFF_HOOK ? (z.monitoredAgentNo = A.monitored_agent_no, z.earSpeakAgent = "", j.updateIncomingIsAnswer(!0), ge.emit(oe.LISTEN_INCOMING_CALL_OFF_HOOK, { session_id: z.sessionId, monitored_agent_no: A.monitored_agent_no }), j.updateActionConfigs(Hf), j.updateDisplayText(Zt.CALLING)) : o === it.LISTEN_CALL_FAILED ? A.status === "failed" && (ge.emit(oe.LISTEN_CALL_FAILED), z.monitoredAgentNo = "") : o === it.EAR_SPEECH ? A.status === "success" ? (A.monitored_agent_no === z.agentInfo.agent_no && (j.updateActionConfigs(_w), ge.emit(oe.EAR_SPEECH_BE_SUCCESS)), A.monitor_agent_no === z.agentInfo.agent_no && (j.updateActionConfigs($w), ge.emit(oe.EAR_SPEECH_SUCCESS, { monitored_agent_no: A.monitored_agent_no, monitor_agent_no: A.monitor_agent_no }), z.earSpeakAgent = A.monitored_agent_no)) : ge.emit(oe.EAR_SPEECH_FAILED) : o === it.STOP_EAR_SPEECH ? A.status === "success" ? (A.monitored_agent_no === z.agentInfo.agent_no && j.updateActionConfigs(Li), A.monitor_agent_no === z.agentInfo.agent_no && j.updateActionConfigs(Hf), z.earSpeakAgent = "", ge.emit(oe.STOP_EAR_SPEECH_SUCCESS)) : ge.emit(oe.STOP_EAR_SPEECH_FAILED) : o === it.CALL_FORCE_INSERT ? A.status === "success" ? (A.monitored_agent_no === z.agentInfo.agent_no && (j.updateActionConfigs(tS), ge.emit(oe.CALL_FORCE_INSERT_SUCCESS, { monitored_agent_no: A.monitored_agent_no, monitor_agent_no: A.monitor_agent_no })), A.monitor_agent_no === z.agentInfo.agent_no && (j.updateActionConfigs(eS), ge.emit(oe.CALL_FORCE_INSERT_SUCCESS_LISTENER, { monitored_agent_no: A.monitored_agent_no, monitor_agent_no: A.monitor_agent_no }))) : ge.emit(oe.CALL_FORCE_INSERT_FAILED) : o === it.INTERNAL_CALL_START_CONSULT ? A.agent_no === z.agentInfo.agent_no ? (j.updateConsultIsAnswer(!0), j.updateActionConfigs(Yf), j.updateDisplayText(Zt.CONSULTING)) : (j.updateDisplayText(Zt.OTHER_SIDE_CONSULTING), j.updateActionConfigs([])) : o === it.INTERNAL_CALL_END_CONSULT ? (j.updateActionConfigs(Pl), j.updateDisplayText(""), j.updateConsultIsAnswer(!1)) : o === it.CALL_SIP_INCOMING_CALL && ge.emit(oe.CALL_SIP_INCOMING_CALL);
|
|
11106
11106
|
}, this.ws.onclose = (r) => {
|
|
11107
11107
|
ge.emit(je.FAIL_NOTIFICATION, "链接已断开,请检查网络"), this.stopHeartbeat();
|
|
11108
11108
|
const i = j.get("isNextState");
|
|
@@ -11157,13 +11157,13 @@ class rS {
|
|
|
11157
11157
|
this.sipClient = null, this.sipClient = e;
|
|
11158
11158
|
}
|
|
11159
11159
|
roleMute() {
|
|
11160
|
-
const e = j.get("isCalling"), n =
|
|
11160
|
+
const e = j.get("isCalling"), n = z.sessionId;
|
|
11161
11161
|
if (!e) throw new Error(JSON.stringify({ code: 1, msg: "当前没有通话" }));
|
|
11162
11162
|
if (!n) throw new Error(JSON.stringify({ code: 1, msg: "当前没有通话" }));
|
|
11163
11163
|
}
|
|
11164
11164
|
holdCall() {
|
|
11165
11165
|
this.roleMute();
|
|
11166
|
-
const e = j.get("isHold"), { sessionId: n } =
|
|
11166
|
+
const e = j.get("isHold"), { sessionId: n } = z;
|
|
11167
11167
|
if (n) {
|
|
11168
11168
|
if (!j.get("actionConfigs").includes("hold")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿保持" }));
|
|
11169
11169
|
if (e) throw new Error(JSON.stringify({ code: 1, msg: "当前已处于保持状态" }));
|
|
@@ -11172,7 +11172,7 @@ class rS {
|
|
|
11172
11172
|
}
|
|
11173
11173
|
unholdCall() {
|
|
11174
11174
|
this.roleMute();
|
|
11175
|
-
const { isHold: e } = j.getState(), { sessionId: n } =
|
|
11175
|
+
const { isHold: e } = j.getState(), { sessionId: n } = z;
|
|
11176
11176
|
if (!j.get("actionConfigs").includes("unhold")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿取消保持" }));
|
|
11177
11177
|
if (n) {
|
|
11178
11178
|
if (!e) throw new Error(JSON.stringify({ code: 1, msg: "当前未处于保持状态" }));
|
|
@@ -11188,12 +11188,12 @@ class rS {
|
|
|
11188
11188
|
}
|
|
11189
11189
|
cancelCall() {
|
|
11190
11190
|
if (!j.get("isCalling")) throw new Error(JSON.stringify({ code: 1, msg: "当前没有通话" }));
|
|
11191
|
-
const e =
|
|
11191
|
+
const e = z.sessionId;
|
|
11192
11192
|
ge.emit(oe.REJECT, { session_id: e }), ln.__internalSend({ type: it.AGENT_HANGUP, data: { session_id: e } });
|
|
11193
11193
|
}
|
|
11194
11194
|
async consultCall(e) {
|
|
11195
11195
|
this.roleMute();
|
|
11196
|
-
const { isCalling: n, outCallIsAnswer: r, consultIsAnswer: i, incomingIsAnswer: o } = j.getState(), A =
|
|
11196
|
+
const { isCalling: n, outCallIsAnswer: r, consultIsAnswer: i, incomingIsAnswer: o } = j.getState(), A = z.sessionId;
|
|
11197
11197
|
if (!j.get("actionConfigs").includes("consult")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿调用咨询" }));
|
|
11198
11198
|
if (i) throw new Error(JSON.stringify({ code: 1, msg: "当前正在咨询" }));
|
|
11199
11199
|
if (!(n || r || o)) throw new Error(JSON.stringify({ code: 1, msg: "当前没有通话" }));
|
|
@@ -11222,51 +11222,51 @@ class rS {
|
|
|
11222
11222
|
}
|
|
11223
11223
|
async hangup() {
|
|
11224
11224
|
if (!j.get("isCalling")) throw new Error(JSON.stringify({ code: 1, msg: "当前没有通话" }));
|
|
11225
|
-
const e =
|
|
11225
|
+
const e = z.sessionId;
|
|
11226
11226
|
ln.__internalSend({ type: it.AGENT_HANGUP, data: { session_id: e } });
|
|
11227
11227
|
}
|
|
11228
11228
|
mute() {
|
|
11229
11229
|
this.roleMute();
|
|
11230
|
-
const e = j.get("actionConfigs"), n = j.get("isMuted"), r =
|
|
11230
|
+
const e = j.get("actionConfigs"), n = j.get("isMuted"), r = z.sessionId;
|
|
11231
11231
|
if (n) throw new Error(JSON.stringify({ code: 1, msg: "当前未处于静音状态" }));
|
|
11232
11232
|
if (!e.includes("mute")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿调用静音" }));
|
|
11233
11233
|
ln.__internalSend({ type: it.MUTE, data: { session_id: r } });
|
|
11234
11234
|
}
|
|
11235
11235
|
unmute() {
|
|
11236
11236
|
this.roleMute();
|
|
11237
|
-
const e = j.get("actionConfigs"), n = j.get("isMuted"), r =
|
|
11237
|
+
const e = j.get("actionConfigs"), n = j.get("isMuted"), r = z.sessionId;
|
|
11238
11238
|
if (!n) throw new Error(JSON.stringify({ code: 1, msg: "当前未处于未静音状态" }));
|
|
11239
11239
|
if (!e.includes("unmute")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿调用静音" }));
|
|
11240
11240
|
ln.__internalSend({ type: it.UNMUTE, data: { session_id: r } });
|
|
11241
11241
|
}
|
|
11242
11242
|
consultTransfer() {
|
|
11243
11243
|
this.roleMute();
|
|
11244
|
-
const e = j.get("consultIsAnswer"), n =
|
|
11244
|
+
const e = j.get("consultIsAnswer"), n = z.sessionId;
|
|
11245
11245
|
if (!j.get("actionConfigs").includes("consult_transfer")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿调用咨询转移" }));
|
|
11246
11246
|
if (!e) throw new Error(JSON.stringify({ code: 1, msg: "当前未处于咨询中" }));
|
|
11247
11247
|
ln.__internalSend({ type: it.CONSULT_TRANSFER, data: { session_id: n } });
|
|
11248
11248
|
}
|
|
11249
11249
|
satisfactionEvaluation() {
|
|
11250
11250
|
this.roleMute();
|
|
11251
|
-
const e =
|
|
11251
|
+
const e = z.sessionId;
|
|
11252
11252
|
if (!j.get("actionConfigs").includes("satisfaction")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿调用满意度评价" }));
|
|
11253
11253
|
ln.__internalSend({ type: it.SATISFACTION_EVALUATION, data: { session_id: e } });
|
|
11254
11254
|
}
|
|
11255
11255
|
startConference() {
|
|
11256
11256
|
if (this.roleMute(), !j.get("actionConfigs").includes("conference")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿调用三方会议" }));
|
|
11257
|
-
const e =
|
|
11257
|
+
const e = z.sessionId;
|
|
11258
11258
|
if (!j.get("consultIsAnswer")) throw new Error(JSON.stringify({ code: 1, msg: "当前未处于咨询中" }));
|
|
11259
11259
|
ln.__internalSend({ type: it.CONSULT_THREE_WAY, data: { session_id: e } });
|
|
11260
11260
|
}
|
|
11261
11261
|
consultRetrieve() {
|
|
11262
11262
|
if (this.roleMute(), !j.get("actionConfigs").includes("consult_retrieve")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿取回通话" }));
|
|
11263
|
-
const e =
|
|
11263
|
+
const e = z.sessionId;
|
|
11264
11264
|
if (!j.get("consultIsAnswer")) throw new Error(JSON.stringify({ code: 1, msg: "当前未处于咨询中" }));
|
|
11265
11265
|
ln.__internalSend({ type: it.CONSULT_RETURN_CALL, data: { session_id: e } });
|
|
11266
11266
|
}
|
|
11267
11267
|
async transferAgent(e) {
|
|
11268
11268
|
if (this.roleMute(), !j.get("actionConfigs").includes("transfer")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿转接" }));
|
|
11269
|
-
const { transferIsAnswer: n } = j.getState(), r =
|
|
11269
|
+
const { transferIsAnswer: n } = j.getState(), r = z.sessionId;
|
|
11270
11270
|
if (n) throw new Error(JSON.stringify({ code: 1, msg: "当前正在转接" }));
|
|
11271
11271
|
ln.__internalSend({ type: it.TRANSFER, data: { session_id: r, transfer_type: 0, transfer_dest: e } });
|
|
11272
11272
|
}
|
|
@@ -11274,7 +11274,7 @@ class rS {
|
|
|
11274
11274
|
if (this.roleMute(), !j.get("actionConfigs").includes("transfer")) throw new Error(JSON.stringify({ code: 1, msg: "当前状态请勿转接" }));
|
|
11275
11275
|
if (!e) throw new Error(JSON.stringify({ code: 1, msg: "号码不能为空" }));
|
|
11276
11276
|
if (!/^\d+$/.test(e)) throw new Error(JSON.stringify({ code: 1, msg: "号码格式错误" }));
|
|
11277
|
-
const { transferIsAnswer: n } = j.getState(), r =
|
|
11277
|
+
const { transferIsAnswer: n } = j.getState(), r = z.sessionId;
|
|
11278
11278
|
if (n) throw new Error(JSON.stringify({ code: 1, msg: "当前正在转接" }));
|
|
11279
11279
|
if (n) throw new Error(JSON.stringify({ code: 1, msg: "当前正在转接" }));
|
|
11280
11280
|
ln.__internalSend({ type: it.TRANSFER, data: { session_id: r, transfer_type: 2, transfer_dest: e } });
|
|
@@ -11298,7 +11298,7 @@ const Bs = class Bs {
|
|
|
11298
11298
|
}), kn(this, WA, () => {
|
|
11299
11299
|
}), this.initWebRtc = async () => {
|
|
11300
11300
|
if (ct(this, On)) return;
|
|
11301
|
-
const e =
|
|
11301
|
+
const e = z.agentInfo.sip_account_list.find((n) => n.device_type === 1);
|
|
11302
11302
|
if (!e) throw new Error(JSON.stringify({ code: 1, msg: "未找到 sip_account_list" }));
|
|
11303
11303
|
{
|
|
11304
11304
|
const n = e.sip_register_addr;
|
|
@@ -11317,7 +11317,7 @@ const Bs = class Bs {
|
|
|
11317
11317
|
let n = "";
|
|
11318
11318
|
const r = new URL(Ii).host;
|
|
11319
11319
|
n = Ii.includes("https") ? `wss://${r}` : `ws://${r}`;
|
|
11320
|
-
const { agent_no: i } =
|
|
11320
|
+
const { agent_no: i } = z.agentInfo;
|
|
11321
11321
|
ln.getInstance({ url: `${n}/ccs-ws/api/v1/ws/call/${i}?Authorization=`, sipClient: ct(this, On) }), setTimeout(() => {
|
|
11322
11322
|
ct(this, hn)._changeState({ data: { state: xt.BUSY, state_name: "忙碌" }, success: () => {
|
|
11323
11323
|
j.updateDisplayText(""), ge.emit(oe.AGENT_STATE, { state: xt.BUSY, state_name: "忙碌" });
|
|
@@ -11325,7 +11325,7 @@ const Bs = class Bs {
|
|
|
11325
11325
|
}, 10);
|
|
11326
11326
|
} else ln.__internalClose(), j.updateIsCalling(!1), j.updateOutCallIsAnswer(!1), j.updateIncomingIsAnswer(!1), j.updateIsMuted(!1), j.updateConsultIsAnswer(!1), j.updateIsHold(!1), j.updateCustomerInfo(void 0), j.updateDisplayText("离线");
|
|
11327
11327
|
})), kn(this, ZA, j.subscribeKey("answerDevice", async (e) => {
|
|
11328
|
-
e === 1 ?
|
|
11328
|
+
e === 1 ? z.stateObject.state === xt.UNREGISTERED && await ct(this, hn)._changeState({ data: { ...z.stateBeforeChange, state_name: z.stateBeforeChange.state === xt.IDLE ? "空闲" : "忙碌" } }, "qq") : await this.destroyRtc();
|
|
11329
11329
|
})), this.on(je.KICK_OFF, () => {
|
|
11330
11330
|
this.destroy();
|
|
11331
11331
|
}), window.addEventListener("beforeunload", (e) => {
|
|
@@ -11355,9 +11355,9 @@ const Bs = class Bs {
|
|
|
11355
11355
|
const o = new URL(Ii).host;
|
|
11356
11356
|
i = Ii.includes("https") ? `wss://${o}` : `ws://${o}`;
|
|
11357
11357
|
const A = ln.getInstance({ url: `${i}/ccs-ws/api/v1/ws/call/${jl}?Authorization=`, sipClient: null, onOpen: async () => {
|
|
11358
|
-
|
|
11359
|
-
const { current_answer_device: a, current_state: s, out_display_number: l, out_display_select_switch: u } =
|
|
11360
|
-
s === xt.IDLE ? (j.updateActionConfigs(Zn),
|
|
11358
|
+
z.logBuiltinEnabled = n || !1, z.browserAlertTime = r || 5e3, await ct(this, hn)._agentLogin(jl);
|
|
11359
|
+
const { current_answer_device: a, current_state: s, out_display_number: l, out_display_select_switch: u } = z.agentInfo;
|
|
11360
|
+
s === xt.IDLE ? (j.updateActionConfigs(Zn), z.stateObject = { state: s, state_name: "空闲" }, z.stateBeforeChange = z.stateObject) : s === xt.BUSY ? (j.updateActionConfigs(cs), z.stateObject = { state: s, state_name: "忙碌" }, z.stateBeforeChange = z.stateObject) : s === xt.UNREGISTERED && (j.updateActionConfigs(cs), z.stateObject = { state: s, state_name: "未注册" }), u === 1 ? j.updateSelectOutNumber(l) : j.updateSelectOutNumber(""), j.updateAnswerDevice(a), jA.setInitRtcFn(this.initWebRtc), a === 1 && (await this.initWebRtc(), A.setSipClient(ct(this, On))), kn(this, un, new rS(ct(this, On))), z.enableBrowserAlert = e, e && xo.requestPermission(), ge.emit(je.AGENT_INIT_STATUS, !0), kn(this, $i, !0), clearInterval(sr._timer), sr._timer = null, ga(this, Ui, U0).call(this);
|
|
11361
11361
|
} });
|
|
11362
11362
|
} catch {
|
|
11363
11363
|
ge.emit(je.AGENT_INIT_STATUS, !1), kn(this, $i, !1);
|
|
@@ -11394,12 +11394,12 @@ const Bs = class Bs {
|
|
|
11394
11394
|
const e = (n) => (...r) => n.apply(this, r);
|
|
11395
11395
|
return { changeDevice: e((n) => ct(this, hn).changeDevice(n)), changeState: e(async (n) => {
|
|
11396
11396
|
const r = j.get("answerDevice");
|
|
11397
|
-
if (
|
|
11397
|
+
if (z.stateObject.state === xt.UNREGISTERED && r === 1) {
|
|
11398
11398
|
await ct(this, On).reconnect();
|
|
11399
11399
|
let i = "";
|
|
11400
11400
|
const o = new URL(Ii).host;
|
|
11401
11401
|
i = Ii.includes("https") ? `wss://${o}` : `ws://${o}`;
|
|
11402
|
-
const { agent_no: A } =
|
|
11402
|
+
const { agent_no: A } = z.agentInfo;
|
|
11403
11403
|
ln.getInstance({ url: `${i}/ccs-ws/api/v1/ws/call/${A}?Authorization=`, sipClient: ct(this, On) });
|
|
11404
11404
|
}
|
|
11405
11405
|
await ct(this, hn).changeState(n, "c");
|
|
@@ -11411,7 +11411,7 @@ const Bs = class Bs {
|
|
|
11411
11411
|
}, listenAgentCall: (n) => ct(this, hn).listenCall(n) };
|
|
11412
11412
|
}
|
|
11413
11413
|
getAgentData() {
|
|
11414
|
-
const { agent_no: e, agent_name: n, answer_devices: r, out_display_data: i, out_display_select_switch: o, current_state: A } =
|
|
11414
|
+
const { agent_no: e, agent_name: n, answer_devices: r, out_display_data: i, out_display_select_switch: o, current_state: A } = z.agentInfo, { stateObject: a } = z, s = { 1: "软电话", 2: "手机模式", 3: "SIP话机" };
|
|
11415
11415
|
return { agent_no: e, agent_name: n, init_state: A, default_device: j.get("answerDevice"), out_display_data: i, out_display_select_switch: o, answer_devices: (r || "").split(",").map((l) => ({ value: Number(l), label: s[Number(l)] })), stateObject: a };
|
|
11416
11416
|
}
|
|
11417
11417
|
async getRealTimeCustomerInfo() {
|
|
@@ -11419,11 +11419,11 @@ const Bs = class Bs {
|
|
|
11419
11419
|
}
|
|
11420
11420
|
setBrowserAlert(e) {
|
|
11421
11421
|
if (typeof e != "boolean") throw new Error(JSON.stringify({ code: 1, msg: "参数类型错误" }));
|
|
11422
|
-
|
|
11422
|
+
z.logBuiltinEnabled = e || !1;
|
|
11423
11423
|
}
|
|
11424
11424
|
setBrowserAlertTime(e) {
|
|
11425
11425
|
if (typeof e != "number") throw new Error(JSON.stringify({ code: 1, msg: "参数类型错误" }));
|
|
11426
|
-
|
|
11426
|
+
z.browserAlertTime = e || 3e3;
|
|
11427
11427
|
}
|
|
11428
11428
|
};
|
|
11429
11429
|
On = new WeakMap(), hn = new WeakMap(), un = new WeakMap(), _i = new WeakMap(), ZA = new WeakMap(), zA = new WeakMap(), $i = new WeakMap(), JA = new WeakMap(), WA = new WeakMap(), Ui = new WeakSet(), k0 = async function() {
|
|
@@ -12504,16 +12504,16 @@ function sI(t, e, n) {
|
|
|
12504
12504
|
return function(f, x, q) {
|
|
12505
12505
|
var E = f.attrs, h = f.componentStyle, y = f.defaultProps, R = f.foldedComponentIds, b = f.styledComponentId, T = f.target, B = ne.useContext(cv), D = ih(), N = f.shouldForwardProp || D.shouldForwardProp;
|
|
12506
12506
|
process.env.NODE_ENV !== "production" && Ug(b);
|
|
12507
|
-
var G = MS(x, B, y) || Lo, L = function(
|
|
12508
|
-
for (var W, Ae = tr(tr({}, Z), { className: void 0, theme: ee }), le = 0; le <
|
|
12509
|
-
var ue = Yo(W =
|
|
12507
|
+
var G = MS(x, B, y) || Lo, L = function(J, Z, ee) {
|
|
12508
|
+
for (var W, Ae = tr(tr({}, Z), { className: void 0, theme: ee }), le = 0; le < J.length; le += 1) {
|
|
12509
|
+
var ue = Yo(W = J[le]) ? W(Ae) : W;
|
|
12510
12510
|
for (var te in ue) Ae[te] = te === "className" ? Ji(Ae[te], ue[te]) : te === "style" ? tr(tr({}, Ae[te]), ue[te]) : ue[te];
|
|
12511
12511
|
}
|
|
12512
12512
|
return Z.className && (Ae.className = Ji(Ae.className, Z.className)), Ae;
|
|
12513
12513
|
}(E, x, G), Y = L.as || T, P = {};
|
|
12514
12514
|
for (var U in L) L[U] === void 0 || U[0] === "$" || U === "as" || U === "theme" && L.theme === G || (U === "forwardedAs" ? P.as = L.forwardedAs : N && !N(U, Y) || (P[U] = L[U], N || process.env.NODE_ENV !== "development" || AS(U) || Ah.has(U) || !Au.has(Y) || (Ah.add(U), console.warn('styled-components: it looks like an unknown prop "'.concat(U, '" is being sent through to the DOM, which will likely trigger a React console error. If you would like automatic filtering of unknown props, you can opt-into that behavior via `<StyleSheetManager shouldForwardProp={...}>` (connect an API like `@emotion/is-prop-valid`) or consider using transient props (`$` prefix for automatic filtering.)')))));
|
|
12515
|
-
var X = function(
|
|
12516
|
-
var ee = ih(), W =
|
|
12515
|
+
var X = function(J, Z) {
|
|
12516
|
+
var ee = ih(), W = J.generateAndInjectStyles(Z, ee.styleSheet, ee.stylis);
|
|
12517
12517
|
return process.env.NODE_ENV !== "production" && Ug(W), W;
|
|
12518
12518
|
}(h, L);
|
|
12519
12519
|
process.env.NODE_ENV !== "production" && f.warnTooManyClasses && f.warnTooManyClasses(X);
|
|
@@ -20651,7 +20651,7 @@ var ld = /* @__PURE__ */ c.createContext({
|
|
|
20651
20651
|
onValuesChange: V,
|
|
20652
20652
|
onFieldsChange: function(H) {
|
|
20653
20653
|
if (I.triggerFormChange(r, H), v) {
|
|
20654
|
-
for (var
|
|
20654
|
+
for (var J = arguments.length, Z = new Array(J > 1 ? J - 1 : 0), ee = 1; ee < J; ee++)
|
|
20655
20655
|
Z[ee - 1] = arguments[ee];
|
|
20656
20656
|
v.apply(void 0, [H].concat(Z));
|
|
20657
20657
|
}
|
|
@@ -20697,8 +20697,8 @@ var ld = /* @__PURE__ */ c.createContext({
|
|
|
20697
20697
|
H.preventDefault(), H.stopPropagation(), q.submit();
|
|
20698
20698
|
},
|
|
20699
20699
|
onReset: function(H) {
|
|
20700
|
-
var
|
|
20701
|
-
H.preventDefault(), q.resetFields(), (
|
|
20700
|
+
var J;
|
|
20701
|
+
H.preventDefault(), q.resetFields(), (J = S.onReset) === null || J === void 0 || J.call(S, H);
|
|
20702
20702
|
}
|
|
20703
20703
|
}), U);
|
|
20704
20704
|
};
|
|
@@ -21049,7 +21049,7 @@ var Zv = /* @__PURE__ */ ne.forwardRef(function(t, e) {
|
|
|
21049
21049
|
}), L) {
|
|
21050
21050
|
var U = null;
|
|
21051
21051
|
if (w) {
|
|
21052
|
-
var X = !V && !v && S, H = "".concat(a, "-clear-icon"),
|
|
21052
|
+
var X = !V && !v && S, H = "".concat(a, "-clear-icon"), J = nt(w) === "object" && w !== null && w !== void 0 && w.clearIcon ? w.clearIcon : "✖";
|
|
21053
21053
|
U = /* @__PURE__ */ ne.createElement("button", {
|
|
21054
21054
|
type: "button",
|
|
21055
21055
|
tabIndex: -1,
|
|
@@ -21060,7 +21060,7 @@ var Zv = /* @__PURE__ */ ne.forwardRef(function(t, e) {
|
|
|
21060
21060
|
return de.preventDefault();
|
|
21061
21061
|
},
|
|
21062
21062
|
className: se(H, F(F({}, "".concat(H, "-hidden"), !X), "".concat(H, "-has-suffix"), !!l))
|
|
21063
|
-
},
|
|
21063
|
+
}, J);
|
|
21064
21064
|
}
|
|
21065
21065
|
var Z = "".concat(a, "-affix-wrapper"), ee = se(Z, F(F(F(F(F({}, "".concat(a, "-disabled"), V), "".concat(Z, "-disabled"), V), "".concat(Z, "-focused"), m), "".concat(Z, "-readonly"), v), "".concat(Z, "-input-with-clear-btn"), l && w && S), f == null ? void 0 : f.affixWrapper, x == null ? void 0 : x.affixWrapper, x == null ? void 0 : x.variant), W = (l || w) && /* @__PURE__ */ ne.createElement("span", {
|
|
21066
21066
|
className: se("".concat(a, "-suffix"), x == null ? void 0 : x.suffix),
|
|
@@ -21115,7 +21115,7 @@ var B4 = ["autoComplete", "onChange", "onFocus", "onBlur", "onPressEnter", "onKe
|
|
|
21115
21115
|
D.current && Kv(D.current, pe);
|
|
21116
21116
|
}, L = Dn(t.defaultValue, {
|
|
21117
21117
|
value: t.value
|
|
21118
|
-
}), Y = _(L, 2), P = Y[0], U = Y[1], X = P == null ? "" : String(P), H = vt(null),
|
|
21118
|
+
}), Y = _(L, 2), P = Y[0], U = Y[1], X = P == null ? "" : String(P), H = vt(null), J = _(H, 2), Z = J[0], ee = J[1], W = zv(C, m), Ae = W.max || V, le = W.strategy(X), ue = !!Ae && le > Ae;
|
|
21119
21119
|
Wo(e, function() {
|
|
21120
21120
|
var Se;
|
|
21121
21121
|
return {
|
|
@@ -21621,10 +21621,10 @@ const ia = /* @__PURE__ */ Rr((t, e) => {
|
|
|
21621
21621
|
var Oe;
|
|
21622
21622
|
return (Oe = o ?? Y) !== null && Oe !== void 0 ? Oe : Ve;
|
|
21623
21623
|
}), X = ne.useContext(di), H = A ?? X, {
|
|
21624
|
-
status:
|
|
21624
|
+
status: J,
|
|
21625
21625
|
hasFeedback: Z,
|
|
21626
21626
|
feedbackIcon: ee
|
|
21627
|
-
} = gn(Lr), W = il(
|
|
21627
|
+
} = gn(Lr), W = il(J, i), Ae = J4(t) || !!Z, le = Te(Ae);
|
|
21628
21628
|
if (process.env.NODE_ENV !== "production") {
|
|
21629
21629
|
const Ve = fn("Input");
|
|
21630
21630
|
Ht(() => {
|
|
@@ -21852,7 +21852,7 @@ const n6 = /* @__PURE__ */ c.forwardRef((t, e) => {
|
|
|
21852
21852
|
mask: V,
|
|
21853
21853
|
type: v,
|
|
21854
21854
|
inputMode: C
|
|
21855
|
-
},
|
|
21855
|
+
}, J = (Z) => {
|
|
21856
21856
|
const ee = typeof l == "function" ? l(Z) : l;
|
|
21857
21857
|
return ee ? /* @__PURE__ */ c.createElement("span", {
|
|
21858
21858
|
className: `${I}-separator`
|
|
@@ -21885,7 +21885,7 @@ const n6 = /* @__PURE__ */ c.forwardRef((t, e) => {
|
|
|
21885
21885
|
value: Ae,
|
|
21886
21886
|
onActiveChange: X,
|
|
21887
21887
|
autoFocus: ee === 0 && p
|
|
21888
|
-
}, H)), l && ee < r - 1 &&
|
|
21888
|
+
}, H)), l && ee < r - 1 && J(ee));
|
|
21889
21889
|
}))));
|
|
21890
21890
|
});
|
|
21891
21891
|
var r6 = { icon: { tag: "svg", attrs: { viewBox: "64 64 896 896", focusable: "false" }, children: [{ tag: "path", attrs: { d: "M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z" } }, { tag: "path", attrs: { d: "M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z" } }] }, name: "eye-invisible", theme: "outlined" }, i6 = function(e, n) {
|
|
@@ -23453,7 +23453,7 @@ const dx = {
|
|
|
23453
23453
|
style: Y,
|
|
23454
23454
|
classNames: P,
|
|
23455
23455
|
styles: U
|
|
23456
|
-
} = pi("button"), X = (n = q ?? G) !== null && n !== void 0 ? n : !0, H = D("btn", o), [
|
|
23456
|
+
} = pi("button"), X = (n = q ?? G) !== null && n !== void 0 ? n : !0, H = D("btn", o), [J, Z, ee] = ix(H), W = gn(di), Ae = p ?? W, le = gn(o1), ue = br(() => ux(i), [i]), [te, me] = vt(ue.loading), [K, de] = vt(!1), ce = Te(null), ye = ao(e, ce), Ie = PC.count(m) === 1 && !C && !Da(b), Ve = Te(!0);
|
|
23457
23457
|
ne.useEffect(() => (Ve.current = !1, () => {
|
|
23458
23458
|
Ve.current = !0;
|
|
23459
23459
|
}), []), Ht(() => {
|
|
@@ -23525,7 +23525,7 @@ const dx = {
|
|
|
23525
23525
|
mount: Ve.current
|
|
23526
23526
|
}), $e = m || m === 0 ? h6(m, Ie && X) : null;
|
|
23527
23527
|
if (et.href !== void 0)
|
|
23528
|
-
return
|
|
23528
|
+
return J(/* @__PURE__ */ ne.createElement("a", Object.assign({}, et, {
|
|
23529
23529
|
className: se(rt, {
|
|
23530
23530
|
[`${H}-disabled`]: Ae
|
|
23531
23531
|
}),
|
|
@@ -23548,7 +23548,7 @@ const dx = {
|
|
|
23548
23548
|
return Da(b) || (De = /* @__PURE__ */ ne.createElement(sg, {
|
|
23549
23549
|
component: "Button",
|
|
23550
23550
|
disabled: te
|
|
23551
|
-
}, De)),
|
|
23551
|
+
}, De)), J(De);
|
|
23552
23552
|
}), zo = gx;
|
|
23553
23553
|
zo.Group = g6;
|
|
23554
23554
|
zo.__ANT_BUTTON = !0;
|
|
@@ -24093,11 +24093,11 @@ function Lx(t) {
|
|
|
24093
24093
|
var Yx = ["prefixCls", "defaultValue", "value", "autoSize", "onResize", "className", "style", "disabled", "onChange", "onInternalAutoSize"], ac = 0, sc = 1, lc = 2, Hx = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
24094
24094
|
var n = t, r = n.prefixCls, i = n.defaultValue, o = n.value, A = n.autoSize, a = n.onResize, s = n.className, l = n.style, u = n.disabled, d = n.onChange, g = n.onInternalAutoSize, p = yt(n, Yx), V = Dn(i, {
|
|
24095
24095
|
value: o,
|
|
24096
|
-
postState: function(
|
|
24097
|
-
return
|
|
24096
|
+
postState: function(J) {
|
|
24097
|
+
return J ?? "";
|
|
24098
24098
|
}
|
|
24099
|
-
}), v = _(V, 2), m = v[0], C = v[1], w = function(
|
|
24100
|
-
C(
|
|
24099
|
+
}), v = _(V, 2), m = v[0], C = v[1], w = function(J) {
|
|
24100
|
+
C(J.target.value), d == null || d(J);
|
|
24101
24101
|
}, S = c.useRef();
|
|
24102
24102
|
c.useImperativeHandle(e, function() {
|
|
24103
24103
|
return {
|
|
@@ -24109,7 +24109,7 @@ var Yx = ["prefixCls", "defaultValue", "value", "autoSize", "onResize", "classNa
|
|
|
24109
24109
|
}, [A]), I = _(M, 2), f = I[0], x = I[1], q = !!A, E = function() {
|
|
24110
24110
|
try {
|
|
24111
24111
|
if (document.activeElement === S.current) {
|
|
24112
|
-
var
|
|
24112
|
+
var J = S.current, Z = J.selectionStart, ee = J.selectionEnd, W = J.scrollTop;
|
|
24113
24113
|
S.current.setSelectionRange(Z, ee), S.current.scrollTop = W;
|
|
24114
24114
|
}
|
|
24115
24115
|
} catch {
|
|
@@ -24130,8 +24130,8 @@ var Yx = ["prefixCls", "defaultValue", "value", "autoSize", "onResize", "classNa
|
|
|
24130
24130
|
}, [R]);
|
|
24131
24131
|
var L = c.useRef(), Y = function() {
|
|
24132
24132
|
Yt.cancel(L.current);
|
|
24133
|
-
}, P = function(
|
|
24134
|
-
R === lc && (a == null || a(
|
|
24133
|
+
}, P = function(J) {
|
|
24134
|
+
R === lc && (a == null || a(J), A && (Y(), L.current = Yt(function() {
|
|
24135
24135
|
G();
|
|
24136
24136
|
})));
|
|
24137
24137
|
};
|
|
@@ -24154,7 +24154,7 @@ var Yx = ["prefixCls", "defaultValue", "value", "autoSize", "onResize", "classNa
|
|
|
24154
24154
|
var n, r = t.defaultValue, i = t.value, o = t.onFocus, A = t.onBlur, a = t.onChange, s = t.allowClear, l = t.maxLength, u = t.onCompositionStart, d = t.onCompositionEnd, g = t.suffix, p = t.prefixCls, V = p === void 0 ? "rc-textarea" : p, v = t.showCount, m = t.count, C = t.className, w = t.style, S = t.disabled, M = t.hidden, I = t.classNames, f = t.styles, x = t.onResize, q = t.onClear, E = t.onPressEnter, h = t.readOnly, y = t.autoSize, R = t.onKeyDown, b = yt(t, Kx), T = Dn(r, {
|
|
24155
24155
|
value: i,
|
|
24156
24156
|
defaultValue: r
|
|
24157
|
-
}), B = _(T, 2), D = B[0], N = B[1], G = D == null ? "" : String(D), L = ne.useState(!1), Y = _(L, 2), P = Y[0], U = Y[1], X = ne.useRef(!1), H = ne.useState(null),
|
|
24157
|
+
}), B = _(T, 2), D = B[0], N = B[1], G = D == null ? "" : String(D), L = ne.useState(!1), Y = _(L, 2), P = Y[0], U = Y[1], X = ne.useRef(!1), H = ne.useState(null), J = _(H, 2), Z = J[0], ee = J[1], W = Te(null), Ae = Te(null), le = function() {
|
|
24158
24158
|
var De;
|
|
24159
24159
|
return (De = Ae.current) === null || De === void 0 ? void 0 : De.textArea;
|
|
24160
24160
|
}, ue = function() {
|
|
@@ -24401,7 +24401,7 @@ const Xx = /* @__PURE__ */ Rr((t, e) => {
|
|
|
24401
24401
|
} = tA(B, C), X = ji((ee) => {
|
|
24402
24402
|
var W;
|
|
24403
24403
|
return (W = o ?? P) !== null && W !== void 0 ? W : ee;
|
|
24404
|
-
}), [H,
|
|
24404
|
+
}), [H, J] = ug("textArea", V, i), Z = e1(s ?? w);
|
|
24405
24405
|
return N(Y(/* @__PURE__ */ c.createElement(Zx, Object.assign({
|
|
24406
24406
|
autoComplete: S
|
|
24407
24407
|
}, v, {
|
|
@@ -24416,7 +24416,7 @@ const Xx = /* @__PURE__ */ Rr((t, e) => {
|
|
|
24416
24416
|
[`${B}-lg`]: X === "large"
|
|
24417
24417
|
}, G, l == null ? void 0 : l.textarea, f.textarea),
|
|
24418
24418
|
variant: se({
|
|
24419
|
-
[`${B}-${H}`]:
|
|
24419
|
+
[`${B}-${H}`]: J
|
|
24420
24420
|
}, qs(B, b)),
|
|
24421
24421
|
affixWrapper: se(`${B}-textarea-affix-wrapper`, {
|
|
24422
24422
|
[`${B}-affix-wrapper-rtl`]: C === "rtl",
|
|
@@ -24605,7 +24605,7 @@ var I1 = /* @__PURE__ */ c.memo(function(t) {
|
|
|
24605
24605
|
});
|
|
24606
24606
|
process.env.NODE_ENV !== "production" && (I1.displayName = "PopupContent");
|
|
24607
24607
|
var b1 = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
24608
|
-
var n = t.popup, r = t.className, i = t.prefixCls, o = t.style, A = t.target, a = t.onVisibleChanged, s = t.open, l = t.keepDom, u = t.fresh, d = t.onClick, g = t.mask, p = t.arrow, V = t.arrowPos, v = t.align, m = t.motion, C = t.maskMotion, w = t.forceRender, S = t.getPopupContainer, M = t.autoDestroy, I = t.portal, f = t.zIndex, x = t.onMouseEnter, q = t.onMouseLeave, E = t.onPointerEnter, h = t.onPointerDownCapture, y = t.ready, R = t.offsetX, b = t.offsetY, T = t.offsetR, B = t.offsetB, D = t.onAlign, N = t.onPrepare, G = t.stretch, L = t.targetWidth, Y = t.targetHeight, P = typeof n == "function" ? n() : n, U = s || l, X = (S == null ? void 0 : S.length) > 0, H = c.useState(!S || !X),
|
|
24608
|
+
var n = t.popup, r = t.className, i = t.prefixCls, o = t.style, A = t.target, a = t.onVisibleChanged, s = t.open, l = t.keepDom, u = t.fresh, d = t.onClick, g = t.mask, p = t.arrow, V = t.arrowPos, v = t.align, m = t.motion, C = t.maskMotion, w = t.forceRender, S = t.getPopupContainer, M = t.autoDestroy, I = t.portal, f = t.zIndex, x = t.onMouseEnter, q = t.onMouseLeave, E = t.onPointerEnter, h = t.onPointerDownCapture, y = t.ready, R = t.offsetX, b = t.offsetY, T = t.offsetR, B = t.offsetB, D = t.onAlign, N = t.onPrepare, G = t.stretch, L = t.targetWidth, Y = t.targetHeight, P = typeof n == "function" ? n() : n, U = s || l, X = (S == null ? void 0 : S.length) > 0, H = c.useState(!S || !X), J = _(H, 2), Z = J[0], ee = J[1];
|
|
24609
24609
|
if (nn(function() {
|
|
24610
24610
|
!Z && X && A && ee(!0);
|
|
24611
24611
|
}, [Z, X, A]), !Z)
|
|
@@ -24827,7 +24827,7 @@ function uR(t, e, n, r, i, o, A) {
|
|
|
24827
24827
|
height: P.height
|
|
24828
24828
|
};
|
|
24829
24829
|
}
|
|
24830
|
-
var U = f.getBoundingClientRect(), X = q.getComputedStyle(f), H = X.height,
|
|
24830
|
+
var U = f.getBoundingClientRect(), X = q.getComputedStyle(f), H = X.height, J = X.width;
|
|
24831
24831
|
U.x = (S = U.x) !== null && S !== void 0 ? S : U.left, U.y = (M = U.y) !== null && M !== void 0 ? M : U.top;
|
|
24832
24832
|
var Z = x.documentElement, ee = Z.clientWidth, W = Z.clientHeight, Ae = Z.scrollWidth, le = Z.scrollHeight, ue = Z.scrollTop, te = Z.scrollLeft, me = U.height, K = U.width, de = G.height, ce = G.width, ye = {
|
|
24833
24833
|
left: 0,
|
|
@@ -24845,7 +24845,7 @@ function uR(t, e, n, r, i, o, A) {
|
|
|
24845
24845
|
f.style.left = "auto", f.style.top = "auto", f.style.right = "0", f.style.bottom = "0";
|
|
24846
24846
|
var et = f.getBoundingClientRect();
|
|
24847
24847
|
f.style.left = y, f.style.top = R, f.style.right = b, f.style.bottom = T, f.style.overflow = B, (I = f.parentElement) === null || I === void 0 || I.removeChild(N);
|
|
24848
|
-
var rt = LA(Math.round(K / parseFloat(
|
|
24848
|
+
var rt = LA(Math.round(K / parseFloat(J) * 1e3) / 1e3), Pe = LA(Math.round(me / parseFloat(H) * 1e3) / 1e3);
|
|
24849
24849
|
if (rt === 0 || Pe === 0 || kA(n) && !og(n))
|
|
24850
24850
|
return;
|
|
24851
24851
|
var Ee = D.offset, Xe = D.targetOffset, ut = dm(U, Ee), $e = _(ut, 2), De = $e[0], xe = $e[1], at = dm(G, Xe), st = _(at, 2), Ct = st[0], Ot = st[1];
|
|
@@ -24980,7 +24980,7 @@ function gR(t, e, n, r, i, o, A, a) {
|
|
|
24980
24980
|
var fR = ["prefixCls", "children", "action", "showAction", "hideAction", "popupVisible", "defaultPopupVisible", "onPopupVisibleChange", "afterPopupVisibleChange", "mouseEnterDelay", "mouseLeaveDelay", "focusDelay", "blurDelay", "mask", "maskClosable", "getPopupContainer", "forceRender", "autoDestroy", "destroyPopupOnHide", "popup", "popupClassName", "popupStyle", "popupPlacement", "builtinPlacements", "popupAlign", "zIndex", "stretch", "getPopupClassNameFromAlign", "fresh", "alignPoint", "onPopupClick", "onPopupAlign", "arrow", "popupMotion", "maskMotion", "popupTransitionName", "popupAnimation", "maskTransitionName", "maskAnimation", "className", "getTriggerDOMNode"];
|
|
24981
24981
|
function hR() {
|
|
24982
24982
|
var t = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : pg, e = /* @__PURE__ */ c.forwardRef(function(n, r) {
|
|
24983
|
-
var i = n.prefixCls, o = i === void 0 ? "rc-trigger-popup" : i, A = n.children, a = n.action, s = a === void 0 ? "hover" : a, l = n.showAction, u = n.hideAction, d = n.popupVisible, g = n.defaultPopupVisible, p = n.onPopupVisibleChange, V = n.afterPopupVisibleChange, v = n.mouseEnterDelay, m = n.mouseLeaveDelay, C = m === void 0 ? 0.1 : m, w = n.focusDelay, S = n.blurDelay, M = n.mask, I = n.maskClosable, f = I === void 0 ? !0 : I, x = n.getPopupContainer, q = n.forceRender, E = n.autoDestroy, h = n.destroyPopupOnHide, y = n.popup, R = n.popupClassName, b = n.popupStyle, T = n.popupPlacement, B = n.builtinPlacements, D = B === void 0 ? {} : B, N = n.popupAlign, G = n.zIndex, L = n.stretch, Y = n.getPopupClassNameFromAlign, P = n.fresh, U = n.alignPoint, X = n.onPopupClick, H = n.onPopupAlign,
|
|
24983
|
+
var i = n.prefixCls, o = i === void 0 ? "rc-trigger-popup" : i, A = n.children, a = n.action, s = a === void 0 ? "hover" : a, l = n.showAction, u = n.hideAction, d = n.popupVisible, g = n.defaultPopupVisible, p = n.onPopupVisibleChange, V = n.afterPopupVisibleChange, v = n.mouseEnterDelay, m = n.mouseLeaveDelay, C = m === void 0 ? 0.1 : m, w = n.focusDelay, S = n.blurDelay, M = n.mask, I = n.maskClosable, f = I === void 0 ? !0 : I, x = n.getPopupContainer, q = n.forceRender, E = n.autoDestroy, h = n.destroyPopupOnHide, y = n.popup, R = n.popupClassName, b = n.popupStyle, T = n.popupPlacement, B = n.builtinPlacements, D = B === void 0 ? {} : B, N = n.popupAlign, G = n.zIndex, L = n.stretch, Y = n.getPopupClassNameFromAlign, P = n.fresh, U = n.alignPoint, X = n.onPopupClick, H = n.onPopupAlign, J = n.arrow, Z = n.popupMotion, ee = n.maskMotion, W = n.popupTransitionName, Ae = n.popupAnimation, le = n.maskTransitionName, ue = n.maskAnimation, te = n.className, me = n.getTriggerDOMNode, K = yt(n, fR), de = E || h || !1, ce = c.useState(!1), ye = _(ce, 2), Ie = ye[0], Ve = ye[1];
|
|
24984
24984
|
nn(function() {
|
|
24985
24985
|
Ve(S1());
|
|
24986
24986
|
}, []);
|
|
@@ -25117,7 +25117,7 @@ function hR() {
|
|
|
25117
25117
|
var vl = /* @__PURE__ */ c.cloneElement(at, k(k({}, vi), AA)), Cl = {
|
|
25118
25118
|
x: cn,
|
|
25119
25119
|
y: Jn
|
|
25120
|
-
}, ql =
|
|
25120
|
+
}, ql = J ? k({}, J !== !0 ? J : {}) : null;
|
|
25121
25121
|
return /* @__PURE__ */ c.createElement(c.Fragment, null, /* @__PURE__ */ c.createElement(Vi, {
|
|
25122
25122
|
disabled: !mt,
|
|
25123
25123
|
ref: xe,
|
|
@@ -25282,7 +25282,7 @@ function ER(t, e) {
|
|
|
25282
25282
|
}, H = function() {
|
|
25283
25283
|
var W = t.openClassName;
|
|
25284
25284
|
return W !== void 0 ? W : "".concat(A, "-open");
|
|
25285
|
-
},
|
|
25285
|
+
}, J = /* @__PURE__ */ ne.cloneElement(q, {
|
|
25286
25286
|
className: se((n = q.props) === null || n === void 0 ? void 0 : n.className, B && H()),
|
|
25287
25287
|
ref: Gi(q) ? Hr(G, so(q)) : void 0
|
|
25288
25288
|
}), Z = m;
|
|
@@ -25306,7 +25306,7 @@ function ER(t, e) {
|
|
|
25306
25306
|
onPopupVisibleChange: L,
|
|
25307
25307
|
onPopupClick: Y,
|
|
25308
25308
|
getPopupContainer: V
|
|
25309
|
-
}),
|
|
25309
|
+
}), J);
|
|
25310
25310
|
}
|
|
25311
25311
|
const yR = /* @__PURE__ */ ne.forwardRef(ER), wR = (t) => typeof t != "object" && typeof t != "function" || t === null;
|
|
25312
25312
|
function SR(t, e, n, r) {
|
|
@@ -25606,7 +25606,7 @@ function kR(t) {
|
|
|
25606
25606
|
return "+ ".concat(t.length, " ...");
|
|
25607
25607
|
}
|
|
25608
25608
|
function UR(t, e) {
|
|
25609
|
-
var n = t.prefixCls, r = n === void 0 ? "rc-overflow" : n, i = t.data, o = i === void 0 ? [] : i, A = t.renderItem, a = t.renderRawItem, s = t.itemKey, l = t.itemWidth, u = l === void 0 ? 10 : l, d = t.ssr, g = t.style, p = t.className, V = t.maxCount, v = t.renderRest, m = t.renderRawRest, C = t.suffix, w = t.component, S = w === void 0 ? "div" : w, M = t.itemComponent, I = t.onVisibleChange, f = yt(t, QR), x = d === "full", q = BR(), E = fA(q, null), h = _(E, 2), y = h[0], R = h[1], b = y || 0, T = fA(q, /* @__PURE__ */ new Map()), B = _(T, 2), D = B[0], N = B[1], G = fA(q, 0), L = _(G, 2), Y = L[0], P = L[1], U = fA(q, 0), X = _(U, 2), H = X[0],
|
|
25609
|
+
var n = t.prefixCls, r = n === void 0 ? "rc-overflow" : n, i = t.data, o = i === void 0 ? [] : i, A = t.renderItem, a = t.renderRawItem, s = t.itemKey, l = t.itemWidth, u = l === void 0 ? 10 : l, d = t.ssr, g = t.style, p = t.className, V = t.maxCount, v = t.renderRest, m = t.renderRawRest, C = t.suffix, w = t.component, S = w === void 0 ? "div" : w, M = t.itemComponent, I = t.onVisibleChange, f = yt(t, QR), x = d === "full", q = BR(), E = fA(q, null), h = _(E, 2), y = h[0], R = h[1], b = y || 0, T = fA(q, /* @__PURE__ */ new Map()), B = _(T, 2), D = B[0], N = B[1], G = fA(q, 0), L = _(G, 2), Y = L[0], P = L[1], U = fA(q, 0), X = _(U, 2), H = X[0], J = X[1], Z = fA(q, 0), ee = _(Z, 2), W = ee[0], Ae = ee[1], le = vt(null), ue = _(le, 2), te = ue[0], me = ue[1], K = vt(null), de = _(K, 2), ce = de[0], ye = de[1], Ie = c.useMemo(function() {
|
|
25610
25610
|
return ce === null && x ? Number.MAX_SAFE_INTEGER : ce || 0;
|
|
25611
25611
|
}, [ce, y]), Ve = vt(!1), Oe = _(Ve, 2), Qe = Oe[0], Ue = Oe[1], Se = "".concat(r, "-item"), pe = Math.max(Y, H), Me = V === B1, Ye = o.length && Me, et = V === O1, rt = Ye || typeof V == "number" && o.length > V, Pe = br(function() {
|
|
25612
25612
|
var Ke = o;
|
|
@@ -25632,7 +25632,7 @@ function UR(t, e) {
|
|
|
25632
25632
|
});
|
|
25633
25633
|
}
|
|
25634
25634
|
function at(Ke, _e) {
|
|
25635
|
-
|
|
25635
|
+
J(_e), P(H);
|
|
25636
25636
|
}
|
|
25637
25637
|
function st(Ke, _e) {
|
|
25638
25638
|
Ae(_e);
|
|
@@ -26070,7 +26070,7 @@ var eT = ["title", "attribute", "elementRef"], tT = ["style", "className", "even
|
|
|
26070
26070
|
var ue = N(le);
|
|
26071
26071
|
g == null || g(Is(ue)), S(ue);
|
|
26072
26072
|
}
|
|
26073
|
-
},
|
|
26073
|
+
}, J = function(le) {
|
|
26074
26074
|
if (p == null || p(le), le.which === At.ENTER) {
|
|
26075
26075
|
var ue = N(le);
|
|
26076
26076
|
g == null || g(Is(ue)), S(ue);
|
|
@@ -26091,7 +26091,7 @@ var eT = ["title", "attribute", "elementRef"], tT = ["style", "className", "even
|
|
|
26091
26091
|
style: k(k({}, X), n),
|
|
26092
26092
|
className: se(y, F(F(F({}, "".concat(y, "-active"), Y), "".concat(y, "-selected"), U), "".concat(y, "-disabled"), T), r),
|
|
26093
26093
|
onClick: H,
|
|
26094
|
-
onKeyDown:
|
|
26094
|
+
onKeyDown: J,
|
|
26095
26095
|
onFocus: Z
|
|
26096
26096
|
}), s, /* @__PURE__ */ c.createElement(L1, {
|
|
26097
26097
|
props: k(k({}, t), {}, {
|
|
@@ -26289,7 +26289,7 @@ function dT(t) {
|
|
|
26289
26289
|
}));
|
|
26290
26290
|
}
|
|
26291
26291
|
var gT = ["style", "className", "title", "eventKey", "warnKey", "disabled", "internalPopupClose", "children", "itemIcon", "expandIcon", "popupClassName", "popupOffset", "popupStyle", "onClick", "onMouseEnter", "onMouseLeave", "onTitleClick", "onTitleMouseEnter", "onTitleMouseLeave"], fT = ["active"], hT = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
26292
|
-
var n = t.style, r = t.className, i = t.title, o = t.eventKey, A = t.warnKey, a = t.disabled, s = t.internalPopupClose, l = t.children, u = t.itemIcon, d = t.expandIcon, g = t.popupClassName, p = t.popupOffset, V = t.popupStyle, v = t.onClick, m = t.onMouseEnter, C = t.onMouseLeave, w = t.onTitleClick, S = t.onTitleMouseEnter, M = t.onTitleMouseLeave, I = yt(t, gT), f = F1(o), x = c.useContext(Yr), q = x.prefixCls, E = x.mode, h = x.openKeys, y = x.disabled, R = x.overflowDisabled, b = x.activeKey, T = x.selectedKeys, B = x.itemIcon, D = x.expandIcon, N = x.onItemClick, G = x.onOpenChange, L = x.onActive, Y = c.useContext(mg), P = Y._internalRenderSubMenuItem, U = c.useContext(U1), X = U.isSubPathKey, H = rA(),
|
|
26292
|
+
var n = t.style, r = t.className, i = t.title, o = t.eventKey, A = t.warnKey, a = t.disabled, s = t.internalPopupClose, l = t.children, u = t.itemIcon, d = t.expandIcon, g = t.popupClassName, p = t.popupOffset, V = t.popupStyle, v = t.onClick, m = t.onMouseEnter, C = t.onMouseLeave, w = t.onTitleClick, S = t.onTitleMouseEnter, M = t.onTitleMouseLeave, I = yt(t, gT), f = F1(o), x = c.useContext(Yr), q = x.prefixCls, E = x.mode, h = x.openKeys, y = x.disabled, R = x.overflowDisabled, b = x.activeKey, T = x.selectedKeys, B = x.itemIcon, D = x.expandIcon, N = x.onItemClick, G = x.onOpenChange, L = x.onActive, Y = c.useContext(mg), P = Y._internalRenderSubMenuItem, U = c.useContext(U1), X = U.isSubPathKey, H = rA(), J = "".concat(q, "-submenu"), Z = y || a, ee = c.useRef(), W = c.useRef();
|
|
26293
26293
|
process.env.NODE_ENV !== "production" && A && Et(!1, "SubMenu should not leave undefined `key`.");
|
|
26294
26294
|
var Ae = u ?? B, le = d ?? D, ue = h.includes(o), te = !R && ue, me = X(T, o), K = j1(o, Z, S, M), de = K.active, ce = yt(K, fT), ye = c.useState(!1), Ie = _(ye, 2), Ve = Ie[0], Oe = Ie[1], Qe = function(st) {
|
|
26295
26295
|
Z || Oe(st);
|
|
@@ -26325,12 +26325,12 @@ var gT = ["style", "className", "title", "eventKey", "warnKey", "disabled", "int
|
|
|
26325
26325
|
isSubMenu: !0
|
|
26326
26326
|
})
|
|
26327
26327
|
}, /* @__PURE__ */ c.createElement("i", {
|
|
26328
|
-
className: "".concat(
|
|
26328
|
+
className: "".concat(J, "-arrow")
|
|
26329
26329
|
}));
|
|
26330
|
-
}, [E, le, t, te,
|
|
26330
|
+
}, [E, le, t, te, J]), ut = /* @__PURE__ */ c.createElement("div", ke({
|
|
26331
26331
|
role: "menuitem",
|
|
26332
26332
|
style: Me,
|
|
26333
|
-
className: "".concat(
|
|
26333
|
+
className: "".concat(J, "-title"),
|
|
26334
26334
|
tabIndex: Z ? null : -1,
|
|
26335
26335
|
ref: ee,
|
|
26336
26336
|
title: typeof i == "string" ? i : null,
|
|
@@ -26346,7 +26346,7 @@ var gT = ["style", "className", "title", "eventKey", "warnKey", "disabled", "int
|
|
|
26346
26346
|
var De = $e.current;
|
|
26347
26347
|
ut = /* @__PURE__ */ c.createElement(uT, {
|
|
26348
26348
|
mode: De,
|
|
26349
|
-
prefixCls:
|
|
26349
|
+
prefixCls: J,
|
|
26350
26350
|
visible: !s && te && E !== "inline",
|
|
26351
26351
|
popupClassName: g,
|
|
26352
26352
|
popupOffset: p,
|
|
@@ -26371,7 +26371,7 @@ var gT = ["style", "className", "title", "eventKey", "warnKey", "disabled", "int
|
|
|
26371
26371
|
}, I, {
|
|
26372
26372
|
component: "li",
|
|
26373
26373
|
style: n,
|
|
26374
|
-
className: se(
|
|
26374
|
+
className: se(J, "".concat(J, "-").concat(E), r, F(F(F(F({}, "".concat(J, "-open"), te), "".concat(J, "-active"), pe), "".concat(J, "-selected"), me), "".concat(J, "-disabled"), Z)),
|
|
26375
26375
|
onMouseEnter: Ue,
|
|
26376
26376
|
onMouseLeave: Se
|
|
26377
26377
|
}), ut, !R && /* @__PURE__ */ c.createElement(dT, {
|
|
@@ -26480,7 +26480,7 @@ function Cm(t, e, n, r, i) {
|
|
|
26480
26480
|
return e && (o = qd(e, A, i)), qg(o, n);
|
|
26481
26481
|
}
|
|
26482
26482
|
var vT = ["prefixCls", "rootClassName", "style", "className", "tabIndex", "items", "children", "direction", "id", "mode", "inlineCollapsed", "disabled", "disabledOverflow", "subMenuOpenDelay", "subMenuCloseDelay", "forceSubMenuRender", "defaultOpenKeys", "openKeys", "activeKey", "defaultActiveFirst", "selectable", "multiple", "defaultSelectedKeys", "selectedKeys", "onSelect", "onDeselect", "inlineIndent", "motion", "defaultMotions", "triggerSubMenuAction", "builtinPlacements", "itemIcon", "expandIcon", "overflowedIndicator", "overflowedIndicatorPopupClassName", "getPopupContainer", "onClick", "onOpenChange", "onKeyDown", "openAnimation", "openTransitionName", "_internalRenderMenuItem", "_internalRenderSubMenuItem", "_internalComponents"], Yi = [], CT = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
26483
|
-
var n, r = t, i = r.prefixCls, o = i === void 0 ? "rc-menu" : i, A = r.rootClassName, a = r.style, s = r.className, l = r.tabIndex, u = l === void 0 ? 0 : l, d = r.items, g = r.children, p = r.direction, V = r.id, v = r.mode, m = v === void 0 ? "vertical" : v, C = r.inlineCollapsed, w = r.disabled, S = r.disabledOverflow, M = r.subMenuOpenDelay, I = M === void 0 ? 0.1 : M, f = r.subMenuCloseDelay, x = f === void 0 ? 0.1 : f, q = r.forceSubMenuRender, E = r.defaultOpenKeys, h = r.openKeys, y = r.activeKey, R = r.defaultActiveFirst, b = r.selectable, T = b === void 0 ? !0 : b, B = r.multiple, D = B === void 0 ? !1 : B, N = r.defaultSelectedKeys, G = r.selectedKeys, L = r.onSelect, Y = r.onDeselect, P = r.inlineIndent, U = P === void 0 ? 24 : P, X = r.motion, H = r.defaultMotions,
|
|
26483
|
+
var n, r = t, i = r.prefixCls, o = i === void 0 ? "rc-menu" : i, A = r.rootClassName, a = r.style, s = r.className, l = r.tabIndex, u = l === void 0 ? 0 : l, d = r.items, g = r.children, p = r.direction, V = r.id, v = r.mode, m = v === void 0 ? "vertical" : v, C = r.inlineCollapsed, w = r.disabled, S = r.disabledOverflow, M = r.subMenuOpenDelay, I = M === void 0 ? 0.1 : M, f = r.subMenuCloseDelay, x = f === void 0 ? 0.1 : f, q = r.forceSubMenuRender, E = r.defaultOpenKeys, h = r.openKeys, y = r.activeKey, R = r.defaultActiveFirst, b = r.selectable, T = b === void 0 ? !0 : b, B = r.multiple, D = B === void 0 ? !1 : B, N = r.defaultSelectedKeys, G = r.selectedKeys, L = r.onSelect, Y = r.onDeselect, P = r.inlineIndent, U = P === void 0 ? 24 : P, X = r.motion, H = r.defaultMotions, J = r.triggerSubMenuAction, Z = J === void 0 ? "hover" : J, ee = r.builtinPlacements, W = r.itemIcon, Ae = r.expandIcon, le = r.overflowedIndicator, ue = le === void 0 ? "..." : le, te = r.overflowedIndicatorPopupClassName, me = r.getPopupContainer, K = r.onClick, de = r.onOpenChange, ce = r.onKeyDown, ye = r.openAnimation, Ie = r.openTransitionName, Ve = r._internalRenderMenuItem, Oe = r._internalRenderSubMenuItem, Qe = r._internalComponents, Ue = yt(r, vT), Se = c.useMemo(function() {
|
|
26484
26484
|
return [Cm(g, d, Yi, Qe, o), Cm(g, d, Yi, {}, o)];
|
|
26485
26485
|
}, [g, d, Qe]), pe = _(Se, 2), Me = pe[0], Ye = pe[1], et = c.useState(!1), rt = _(et, 2), Pe = rt[0], Ee = rt[1], Xe = c.useRef(), ut = _R(V), $e = p === "rtl";
|
|
26486
26486
|
process.env.NODE_ENV !== "production" && Et(!ye && !Ie, "`openAnimation` and `openTransitionName` is removed. Please use `motion` or `defaultMotion` instead.");
|
|
@@ -27010,7 +27010,7 @@ const qm = {
|
|
|
27010
27010
|
style: {
|
|
27011
27011
|
width: G
|
|
27012
27012
|
}
|
|
27013
|
-
}, i || X) : null,
|
|
27013
|
+
}, i || X) : null, J = Object.assign(Object.assign({}, s), {
|
|
27014
27014
|
flex: `0 0 ${G}`,
|
|
27015
27015
|
maxWidth: G,
|
|
27016
27016
|
minWidth: G,
|
|
@@ -27028,7 +27028,7 @@ const qm = {
|
|
|
27028
27028
|
}, /* @__PURE__ */ c.createElement("aside", Object.assign({
|
|
27029
27029
|
className: Z
|
|
27030
27030
|
}, D, {
|
|
27031
|
-
style:
|
|
27031
|
+
style: J,
|
|
27032
27032
|
ref: e
|
|
27033
27033
|
}), /* @__PURE__ */ c.createElement("div", {
|
|
27034
27034
|
className: `${h}-children`
|
|
@@ -27177,7 +27177,7 @@ var yo = {
|
|
|
27177
27177
|
overlayInnerStyle: k(k({}, y), N == null ? void 0 : N.body)
|
|
27178
27178
|
}, R);
|
|
27179
27179
|
}, X = function() {
|
|
27180
|
-
var
|
|
27180
|
+
var J = c.Children.only(p), Z = (J == null ? void 0 : J.props) || {}, ee = k(k({}, Z), {}, {
|
|
27181
27181
|
"aria-describedby": R ? L : null
|
|
27182
27182
|
});
|
|
27183
27183
|
return /* @__PURE__ */ c.cloneElement(p, ee);
|
|
@@ -27287,16 +27287,16 @@ const HT = /* @__PURE__ */ c.forwardRef((t, e) => {
|
|
|
27287
27287
|
style: Y,
|
|
27288
27288
|
classNames: P,
|
|
27289
27289
|
styles: U
|
|
27290
|
-
} = pi("tooltip"), X = fn("Tooltip"), H = c.useRef(null),
|
|
27290
|
+
} = pi("tooltip"), X = fn("Tooltip"), H = c.useRef(null), J = () => {
|
|
27291
27291
|
var Ee;
|
|
27292
27292
|
(Ee = H.current) === null || Ee === void 0 || Ee.forceAlign();
|
|
27293
27293
|
};
|
|
27294
27294
|
c.useImperativeHandle(e, () => {
|
|
27295
27295
|
var Ee, Xe;
|
|
27296
27296
|
return {
|
|
27297
|
-
forceAlign:
|
|
27297
|
+
forceAlign: J,
|
|
27298
27298
|
forcePopupAlign: () => {
|
|
27299
|
-
X.deprecated(!1, "forcePopupAlign", "forceAlign"),
|
|
27299
|
+
X.deprecated(!1, "forcePopupAlign", "forceAlign"), J();
|
|
27300
27300
|
},
|
|
27301
27301
|
nativeElement: (Ee = H.current) === null || Ee === void 0 ? void 0 : Ee.nativeElement,
|
|
27302
27302
|
popupElement: (Xe = H.current) === null || Xe === void 0 ? void 0 : Xe.popupElement
|
|
@@ -28625,12 +28625,12 @@ const la = (t) => {
|
|
|
28625
28625
|
[`${T}-rtl`]: E === "rtl"
|
|
28626
28626
|
}, Y.props.className),
|
|
28627
28627
|
disabled: (e = Y.props.disabled) !== null && e !== void 0 ? e : a
|
|
28628
|
-
}), U = a ? [] : A, X = !!(U != null && U.includes("contextMenu")), [H,
|
|
28628
|
+
}), U = a ? [] : A, X = !!(U != null && U.includes("contextMenu")), [H, J] = Dn(!1, {
|
|
28629
28629
|
value: p ?? v
|
|
28630
28630
|
}), Z = An((K) => {
|
|
28631
28631
|
V == null || V(K, {
|
|
28632
28632
|
source: "trigger"
|
|
28633
|
-
}), m == null || m(K),
|
|
28633
|
+
}), m == null || m(K), J(K);
|
|
28634
28634
|
}), ee = se(u, d, N, G, B, h == null ? void 0 : h.className, {
|
|
28635
28635
|
[`${T}-rtl`]: E === "rtl"
|
|
28636
28636
|
}), W = x1({
|
|
@@ -28642,7 +28642,7 @@ const la = (t) => {
|
|
|
28642
28642
|
}), Ae = c.useCallback(() => {
|
|
28643
28643
|
n != null && n.selectable && (n != null && n.multiple) || (V == null || V(!1, {
|
|
28644
28644
|
source: "menu"
|
|
28645
|
-
}),
|
|
28645
|
+
}), J(!1));
|
|
28646
28646
|
}, [n == null ? void 0 : n.selectable, n == null ? void 0 : n.multiple]), le = () => {
|
|
28647
28647
|
let K;
|
|
28648
28648
|
return n != null && n.items ? K = /* @__PURE__ */ c.createElement(iA, Object.assign({}, n)) : typeof I == "function" ? K = I() : K = I, s && (K = s(K)), K = c.Children.only(typeof K == "string" ? /* @__PURE__ */ c.createElement("span", null, K) : K), /* @__PURE__ */ c.createElement(ZT, {
|
|
@@ -28755,17 +28755,17 @@ const s5 = /* @__PURE__ */ c.forwardRef((t, e) => {
|
|
|
28755
28755
|
[`${B}-gap-col-${x}`]: h
|
|
28756
28756
|
}, g, p, G), Y = se(`${B}-item`, (n = M == null ? void 0 : M.item) !== null && n !== void 0 ? n : s.item);
|
|
28757
28757
|
let P = 0;
|
|
28758
|
-
const U = b.map((
|
|
28758
|
+
const U = b.map((J, Z) => {
|
|
28759
28759
|
var ee;
|
|
28760
|
-
|
|
28761
|
-
const W = (
|
|
28760
|
+
J != null && (P = Z);
|
|
28761
|
+
const W = (J == null ? void 0 : J.key) || `${Y}-${Z}`;
|
|
28762
28762
|
return /* @__PURE__ */ c.createElement(A5, {
|
|
28763
28763
|
className: Y,
|
|
28764
28764
|
key: W,
|
|
28765
28765
|
index: Z,
|
|
28766
28766
|
split: C,
|
|
28767
28767
|
style: (ee = I == null ? void 0 : I.item) !== null && ee !== void 0 ? ee : l.item
|
|
28768
|
-
},
|
|
28768
|
+
}, J);
|
|
28769
28769
|
}), X = c.useMemo(() => ({
|
|
28770
28770
|
latestIndex: P
|
|
28771
28771
|
}), [P]);
|
|
@@ -28853,11 +28853,11 @@ const $1 = (t) => {
|
|
|
28853
28853
|
htmlType: u,
|
|
28854
28854
|
href: x,
|
|
28855
28855
|
title: E
|
|
28856
|
-
}, d),
|
|
28856
|
+
}, d), J = /* @__PURE__ */ c.createElement(zo, {
|
|
28857
28857
|
type: o,
|
|
28858
28858
|
danger: A,
|
|
28859
28859
|
icon: q
|
|
28860
|
-
}), [Z, ee] = h([H,
|
|
28860
|
+
}), [Z, ee] = h([H, J]);
|
|
28861
28861
|
return /* @__PURE__ */ c.createElement(Ig.Compact, Object.assign({
|
|
28862
28862
|
className: X,
|
|
28863
28863
|
size: P,
|
|
@@ -28892,28 +28892,28 @@ process.env.NODE_ENV !== "production" && (rC.displayName = "InfoCircleFilled");
|
|
|
28892
28892
|
var iC = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
28893
28893
|
var n = t.prefixCls, r = t.style, i = t.className, o = t.duration, A = o === void 0 ? 4.5 : o, a = t.showProgress, s = t.pauseOnHover, l = s === void 0 ? !0 : s, u = t.eventKey, d = t.content, g = t.closable, p = t.closeIcon, V = p === void 0 ? "x" : p, v = t.props, m = t.onClick, C = t.onNoticeClose, w = t.times, S = t.hovering, M = c.useState(!1), I = _(M, 2), f = I[0], x = I[1], q = c.useState(0), E = _(q, 2), h = E[0], y = E[1], R = c.useState(0), b = _(R, 2), T = b[0], B = b[1], D = S || f, N = A > 0 && a, G = function() {
|
|
28894
28894
|
C(u);
|
|
28895
|
-
}, L = function(
|
|
28896
|
-
(
|
|
28895
|
+
}, L = function(J) {
|
|
28896
|
+
(J.key === "Enter" || J.code === "Enter" || J.keyCode === At.ENTER) && G();
|
|
28897
28897
|
};
|
|
28898
28898
|
c.useEffect(function() {
|
|
28899
28899
|
if (!D && A > 0) {
|
|
28900
|
-
var H = Date.now() - T,
|
|
28900
|
+
var H = Date.now() - T, J = setTimeout(function() {
|
|
28901
28901
|
G();
|
|
28902
28902
|
}, A * 1e3 - T);
|
|
28903
28903
|
return function() {
|
|
28904
|
-
l && clearTimeout(
|
|
28904
|
+
l && clearTimeout(J), B(Date.now() - H);
|
|
28905
28905
|
};
|
|
28906
28906
|
}
|
|
28907
28907
|
}, [A, D, w]), c.useEffect(function() {
|
|
28908
28908
|
if (!D && N && (l || T === 0)) {
|
|
28909
|
-
var H = performance.now(),
|
|
28910
|
-
cancelAnimationFrame(
|
|
28909
|
+
var H = performance.now(), J, Z = function ee() {
|
|
28910
|
+
cancelAnimationFrame(J), J = requestAnimationFrame(function(W) {
|
|
28911
28911
|
var Ae = W + T - H, le = Math.min(Ae / (A * 1e3), 1);
|
|
28912
28912
|
y(le * 100), le < 1 && ee();
|
|
28913
28913
|
});
|
|
28914
28914
|
};
|
|
28915
28915
|
return Z(), function() {
|
|
28916
|
-
l && cancelAnimationFrame(
|
|
28916
|
+
l && cancelAnimationFrame(J);
|
|
28917
28917
|
};
|
|
28918
28918
|
}
|
|
28919
28919
|
}, [A, T, D, N, w]);
|
|
@@ -28926,13 +28926,13 @@ var iC = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
|
28926
28926
|
ref: e,
|
|
28927
28927
|
className: se(X, i, F({}, "".concat(X, "-closable"), g)),
|
|
28928
28928
|
style: r,
|
|
28929
|
-
onMouseEnter: function(
|
|
28929
|
+
onMouseEnter: function(J) {
|
|
28930
28930
|
var Z;
|
|
28931
|
-
x(!0), v == null || (Z = v.onMouseEnter) === null || Z === void 0 || Z.call(v,
|
|
28931
|
+
x(!0), v == null || (Z = v.onMouseEnter) === null || Z === void 0 || Z.call(v, J);
|
|
28932
28932
|
},
|
|
28933
|
-
onMouseLeave: function(
|
|
28933
|
+
onMouseLeave: function(J) {
|
|
28934
28934
|
var Z;
|
|
28935
|
-
x(!1), v == null || (Z = v.onMouseLeave) === null || Z === void 0 || Z.call(v,
|
|
28935
|
+
x(!1), v == null || (Z = v.onMouseLeave) === null || Z === void 0 || Z.call(v, J);
|
|
28936
28936
|
},
|
|
28937
28937
|
onClick: m
|
|
28938
28938
|
}), /* @__PURE__ */ c.createElement("div", {
|
|
@@ -28943,8 +28943,8 @@ var iC = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
|
28943
28943
|
onKeyDown: L,
|
|
28944
28944
|
"aria-label": "Close"
|
|
28945
28945
|
}, P, {
|
|
28946
|
-
onClick: function(
|
|
28947
|
-
|
|
28946
|
+
onClick: function(J) {
|
|
28947
|
+
J.preventDefault(), J.stopPropagation(), G();
|
|
28948
28948
|
}
|
|
28949
28949
|
}), Y.closeIcon), N && /* @__PURE__ */ c.createElement("progress", {
|
|
28950
28950
|
className: "".concat(X, "-progress"),
|
|
@@ -29002,19 +29002,19 @@ var iC = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
|
29002
29002
|
s(r);
|
|
29003
29003
|
}
|
|
29004
29004
|
}), function(D, N) {
|
|
29005
|
-
var G = D.config, L = D.className, Y = D.style, P = D.index, U = G, X = U.key, H = U.times,
|
|
29006
|
-
return pe.key ===
|
|
29005
|
+
var G = D.config, L = D.className, Y = D.style, P = D.index, U = G, X = U.key, H = U.times, J = String(X), Z = G, ee = Z.className, W = Z.style, Ae = Z.classNames, le = Z.styles, ue = yt(Z, v5), te = f.findIndex(function(pe) {
|
|
29006
|
+
return pe.key === J;
|
|
29007
29007
|
}), me = {};
|
|
29008
29008
|
if (E) {
|
|
29009
29009
|
var K = f.length - 1 - (te > -1 ? te : P - 1), de = r === "top" || r === "bottom" ? "-50%" : "0";
|
|
29010
29010
|
if (K > 0) {
|
|
29011
29011
|
var ce, ye, Ie;
|
|
29012
|
-
me.height = T ? (ce = p.current[
|
|
29012
|
+
me.height = T ? (ce = p.current[J]) === null || ce === void 0 ? void 0 : ce.offsetHeight : m == null ? void 0 : m.offsetHeight;
|
|
29013
29013
|
for (var Ve = 0, Oe = 0; Oe < K; Oe++) {
|
|
29014
29014
|
var Qe;
|
|
29015
29015
|
Ve += ((Qe = p.current[f[f.length - 1 - Oe].key]) === null || Qe === void 0 ? void 0 : Qe.offsetHeight) + b;
|
|
29016
29016
|
}
|
|
29017
|
-
var Ue = (T ? Ve : K * y) * (r.startsWith("top") ? 1 : -1), Se = !T && m !== null && m !== void 0 && m.offsetWidth && (ye = p.current[
|
|
29017
|
+
var Ue = (T ? Ve : K * y) * (r.startsWith("top") ? 1 : -1), Se = !T && m !== null && m !== void 0 && m.offsetWidth && (ye = p.current[J]) !== null && ye !== void 0 && ye.offsetWidth ? ((m == null ? void 0 : m.offsetWidth) - y * 2 * (K < 3 ? K : 3)) / ((Ie = p.current[J]) === null || Ie === void 0 ? void 0 : Ie.offsetWidth) : 1;
|
|
29018
29018
|
me.transform = "translate3d(".concat(de, ", ").concat(Ue, "px, 0) scaleX(").concat(Se, ")");
|
|
29019
29019
|
} else
|
|
29020
29020
|
me.transform = "translate3d(".concat(de, ", 0, 0)");
|
|
@@ -29025,19 +29025,19 @@ var iC = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
|
29025
29025
|
style: k(k(k({}, Y), me), le == null ? void 0 : le.wrapper),
|
|
29026
29026
|
onMouseEnter: function() {
|
|
29027
29027
|
return I(function(Me) {
|
|
29028
|
-
return Me.includes(
|
|
29028
|
+
return Me.includes(J) ? Me : [].concat(be(Me), [J]);
|
|
29029
29029
|
});
|
|
29030
29030
|
},
|
|
29031
29031
|
onMouseLeave: function() {
|
|
29032
29032
|
return I(function(Me) {
|
|
29033
29033
|
return Me.filter(function(Ye) {
|
|
29034
|
-
return Ye !==
|
|
29034
|
+
return Ye !== J;
|
|
29035
29035
|
});
|
|
29036
29036
|
});
|
|
29037
29037
|
}
|
|
29038
29038
|
}, /* @__PURE__ */ ne.createElement(iC, ke({}, ue, {
|
|
29039
29039
|
ref: function(Me) {
|
|
29040
|
-
te > -1 ? p.current[
|
|
29040
|
+
te > -1 ? p.current[J] = Me : delete p.current[J];
|
|
29041
29041
|
},
|
|
29042
29042
|
prefixCls: i,
|
|
29043
29043
|
classNames: Ae,
|
|
@@ -29919,18 +29919,18 @@ var Fm = function(e) {
|
|
|
29919
29919
|
}, cB = function(e) {
|
|
29920
29920
|
var n = e.id, r = e.prefixCls, i = e.values, o = e.open, A = e.searchValue, a = e.autoClearSearchValue, s = e.inputRef, l = e.placeholder, u = e.disabled, d = e.mode, g = e.showSearch, p = e.autoFocus, V = e.autoComplete, v = e.activeDescendantId, m = e.tabIndex, C = e.removeIcon, w = e.maxTagCount, S = e.maxTagTextLength, M = e.maxTagPlaceholder, I = M === void 0 ? function(K) {
|
|
29921
29921
|
return "+ ".concat(K.length, " ...");
|
|
29922
|
-
} : M, f = e.tagRender, x = e.onToggleOpen, q = e.onRemove, E = e.onInputChange, h = e.onInputPaste, y = e.onInputKeyDown, R = e.onInputMouseDown, b = e.onInputCompositionStart, T = e.onInputCompositionEnd, B = e.onInputBlur, D = c.useRef(null), N = vt(0), G = _(N, 2), L = G[0], Y = G[1], P = vt(!1), U = _(P, 2), X = U[0], H = U[1],
|
|
29922
|
+
} : M, f = e.tagRender, x = e.onToggleOpen, q = e.onRemove, E = e.onInputChange, h = e.onInputPaste, y = e.onInputKeyDown, R = e.onInputMouseDown, b = e.onInputCompositionStart, T = e.onInputCompositionEnd, B = e.onInputBlur, D = c.useRef(null), N = vt(0), G = _(N, 2), L = G[0], Y = G[1], P = vt(!1), U = _(P, 2), X = U[0], H = U[1], J = "".concat(r, "-selection"), Z = o || d === "multiple" && a === !1 || d === "tags" ? A : "", ee = d === "tags" || d === "multiple" && a === !1 || g && (o || X);
|
|
29923
29923
|
sB(function() {
|
|
29924
29924
|
Y(D.current.scrollWidth);
|
|
29925
29925
|
}, [Z]);
|
|
29926
29926
|
var W = function(de, ce, ye, Ie, Ve) {
|
|
29927
29927
|
return /* @__PURE__ */ c.createElement("span", {
|
|
29928
29928
|
title: gC(de),
|
|
29929
|
-
className: se("".concat(
|
|
29929
|
+
className: se("".concat(J, "-item"), F({}, "".concat(J, "-item-disabled"), ye))
|
|
29930
29930
|
}, /* @__PURE__ */ c.createElement("span", {
|
|
29931
|
-
className: "".concat(
|
|
29931
|
+
className: "".concat(J, "-item-content")
|
|
29932
29932
|
}, ce), Ie && /* @__PURE__ */ c.createElement(ml, {
|
|
29933
|
-
className: "".concat(
|
|
29933
|
+
className: "".concat(J, "-item-remove"),
|
|
29934
29934
|
onMouseDown: Fm,
|
|
29935
29935
|
onClick: Ve,
|
|
29936
29936
|
customizeIcon: C
|
|
@@ -29967,7 +29967,7 @@ var Fm = function(e) {
|
|
|
29967
29967
|
title: ce
|
|
29968
29968
|
}, ce, !1);
|
|
29969
29969
|
}, te = /* @__PURE__ */ c.createElement("div", {
|
|
29970
|
-
className: "".concat(
|
|
29970
|
+
className: "".concat(J, "-search"),
|
|
29971
29971
|
style: {
|
|
29972
29972
|
width: L
|
|
29973
29973
|
},
|
|
@@ -30000,10 +30000,10 @@ var Fm = function(e) {
|
|
|
30000
30000
|
attrs: Ao(e, !0)
|
|
30001
30001
|
}), /* @__PURE__ */ c.createElement("span", {
|
|
30002
30002
|
ref: D,
|
|
30003
|
-
className: "".concat(
|
|
30003
|
+
className: "".concat(J, "-search-mirror"),
|
|
30004
30004
|
"aria-hidden": !0
|
|
30005
30005
|
}, Z, " ")), me = /* @__PURE__ */ c.createElement($r, {
|
|
30006
|
-
prefixCls: "".concat(
|
|
30006
|
+
prefixCls: "".concat(J, "-overflow"),
|
|
30007
30007
|
data: i,
|
|
30008
30008
|
renderItem: le,
|
|
30009
30009
|
renderRest: ue,
|
|
@@ -30012,9 +30012,9 @@ var Fm = function(e) {
|
|
|
30012
30012
|
maxCount: w
|
|
30013
30013
|
});
|
|
30014
30014
|
return /* @__PURE__ */ c.createElement("span", {
|
|
30015
|
-
className: "".concat(
|
|
30015
|
+
className: "".concat(J, "-wrap")
|
|
30016
30016
|
}, me, !i.length && !Z && /* @__PURE__ */ c.createElement("span", {
|
|
30017
|
-
className: "".concat(
|
|
30017
|
+
className: "".concat(J, "-placeholder")
|
|
30018
30018
|
}, l));
|
|
30019
30019
|
}, uB = function(e) {
|
|
30020
30020
|
var n = e.inputElement, r = e.prefixCls, i = e.id, o = e.inputRef, A = e.disabled, a = e.autoFocus, s = e.autoComplete, l = e.activeDescendantId, u = e.mode, d = e.open, g = e.values, p = e.placeholder, V = e.tabIndex, v = e.showSearch, m = e.searchValue, C = e.activeValue, w = e.maxLength, S = e.onInputKeyDown, M = e.onInputMouseDown, I = e.onInputChange, f = e.onInputPaste, x = e.onInputCompositionStart, q = e.onInputCompositionEnd, E = e.onInputBlur, h = e.title, y = c.useState(!1), R = _(y, 2), b = R[0], T = R[1], B = u === "combobox", D = B || v, N = g[0], G = m || "";
|
|
@@ -30297,7 +30297,7 @@ function VB(t) {
|
|
|
30297
30297
|
var vB = ["id", "prefixCls", "className", "showSearch", "tagRender", "direction", "omitDomProps", "displayValues", "onDisplayValuesChange", "emptyOptions", "notFoundContent", "onClear", "mode", "disabled", "loading", "getInputElement", "getRawInputElement", "open", "defaultOpen", "onDropdownVisibleChange", "activeValue", "onActiveValueChange", "activeDescendantId", "searchValue", "autoClearSearchValue", "onSearch", "onSearchSplit", "tokenSeparators", "allowClear", "prefix", "suffixIcon", "clearIcon", "OptionList", "animation", "transitionName", "dropdownStyle", "dropdownClassName", "dropdownMatchSelectWidth", "dropdownRender", "dropdownAlign", "placement", "builtinPlacements", "getPopupContainer", "showAction", "onFocus", "onBlur", "onKeyUp", "onKeyDown", "onMouseDown"], CB = ["value", "onChange", "removeIcon", "placeholder", "autoFocus", "maxTagCount", "maxTagTextLength", "maxTagPlaceholder", "choiceTransitionName", "onInputKeyDown", "onPopupScroll", "tabIndex"], Rs = function(e) {
|
|
30298
30298
|
return e === "tags" || e === "multiple";
|
|
30299
30299
|
}, mC = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
30300
|
-
var n, r = t.id, i = t.prefixCls, o = t.className, A = t.showSearch, a = t.tagRender, s = t.direction, l = t.omitDomProps, u = t.displayValues, d = t.onDisplayValuesChange, g = t.emptyOptions, p = t.notFoundContent, V = p === void 0 ? "Not Found" : p, v = t.onClear, m = t.mode, C = t.disabled, w = t.loading, S = t.getInputElement, M = t.getRawInputElement, I = t.open, f = t.defaultOpen, x = t.onDropdownVisibleChange, q = t.activeValue, E = t.onActiveValueChange, h = t.activeDescendantId, y = t.searchValue, R = t.autoClearSearchValue, b = t.onSearch, T = t.onSearchSplit, B = t.tokenSeparators, D = t.allowClear, N = t.prefix, G = t.suffixIcon, L = t.clearIcon, Y = t.OptionList, P = t.animation, U = t.transitionName, X = t.dropdownStyle, H = t.dropdownClassName,
|
|
30300
|
+
var n, r = t.id, i = t.prefixCls, o = t.className, A = t.showSearch, a = t.tagRender, s = t.direction, l = t.omitDomProps, u = t.displayValues, d = t.onDisplayValuesChange, g = t.emptyOptions, p = t.notFoundContent, V = p === void 0 ? "Not Found" : p, v = t.onClear, m = t.mode, C = t.disabled, w = t.loading, S = t.getInputElement, M = t.getRawInputElement, I = t.open, f = t.defaultOpen, x = t.onDropdownVisibleChange, q = t.activeValue, E = t.onActiveValueChange, h = t.activeDescendantId, y = t.searchValue, R = t.autoClearSearchValue, b = t.onSearch, T = t.onSearchSplit, B = t.tokenSeparators, D = t.allowClear, N = t.prefix, G = t.suffixIcon, L = t.clearIcon, Y = t.OptionList, P = t.animation, U = t.transitionName, X = t.dropdownStyle, H = t.dropdownClassName, J = t.dropdownMatchSelectWidth, Z = t.dropdownRender, ee = t.dropdownAlign, W = t.placement, Ae = t.builtinPlacements, le = t.getPopupContainer, ue = t.showAction, te = ue === void 0 ? [] : ue, me = t.onFocus, K = t.onBlur, de = t.onKeyUp, ce = t.onKeyDown, ye = t.onMouseDown, Ie = yt(t, vB), Ve = Rs(m), Oe = (A !== void 0 ? A : Ve) || m === "combobox", Qe = k({}, Ie);
|
|
30301
30301
|
CB.forEach(function(It) {
|
|
30302
30302
|
delete Qe[It];
|
|
30303
30303
|
}), l == null || l.forEach(function(It) {
|
|
@@ -30488,7 +30488,7 @@ var vB = ["id", "prefixCls", "className", "showSearch", "tagRender", "direction"
|
|
|
30488
30488
|
dropdownStyle: X,
|
|
30489
30489
|
dropdownClassName: H,
|
|
30490
30490
|
direction: s,
|
|
30491
|
-
dropdownMatchSelectWidth:
|
|
30491
|
+
dropdownMatchSelectWidth: J,
|
|
30492
30492
|
dropdownRender: Z,
|
|
30493
30493
|
dropdownAlign: ee,
|
|
30494
30494
|
placement: W,
|
|
@@ -30956,7 +30956,7 @@ var Id = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
|
30956
30956
|
pageY: I,
|
|
30957
30957
|
startTop: E
|
|
30958
30958
|
};
|
|
30959
|
-
var
|
|
30959
|
+
var J = function(te) {
|
|
30960
30960
|
w(!0), f(Sd(te, l)), h(H.current.top), A(), te.stopPropagation(), te.preventDefault();
|
|
30961
30961
|
};
|
|
30962
30962
|
c.useEffect(function() {
|
|
@@ -30965,10 +30965,10 @@ var Id = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
|
30965
30965
|
}, te = R.current, me = b.current;
|
|
30966
30966
|
return te.addEventListener("touchstart", ue, {
|
|
30967
30967
|
passive: !1
|
|
30968
|
-
}), me.addEventListener("touchstart",
|
|
30968
|
+
}), me.addEventListener("touchstart", J, {
|
|
30969
30969
|
passive: !1
|
|
30970
30970
|
}), function() {
|
|
30971
|
-
te.removeEventListener("touchstart", ue), me.removeEventListener("touchstart",
|
|
30971
|
+
te.removeEventListener("touchstart", ue), me.removeEventListener("touchstart", J);
|
|
30972
30972
|
};
|
|
30973
30973
|
}, []);
|
|
30974
30974
|
var Z = c.useRef();
|
|
@@ -31048,7 +31048,7 @@ var Id = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
|
31048
31048
|
ref: b,
|
|
31049
31049
|
className: se("".concat(W, "-thumb"), F({}, "".concat(W, "-thumb-moving"), C)),
|
|
31050
31050
|
style: k(k({}, le), p),
|
|
31051
|
-
onMouseDown:
|
|
31051
|
+
onMouseDown: J
|
|
31052
31052
|
}));
|
|
31053
31053
|
});
|
|
31054
31054
|
process.env.NODE_ENV !== "production" && (Id.displayName = "ScrollBar");
|
|
@@ -31068,7 +31068,7 @@ function FB(t, e) {
|
|
|
31068
31068
|
return Object.values(D.maps).reduce(function(qe, Be) {
|
|
31069
31069
|
return qe + Be;
|
|
31070
31070
|
}, 0);
|
|
31071
|
-
}, [D.id, D.maps]), Y = G && u && (Math.max(A * u.length, L) > o || !!v), P = V === "rtl", U = se(r, F({}, "".concat(r, "-rtl"), P), i), X = u || DB, H = Te(),
|
|
31071
|
+
}, [D.id, D.maps]), Y = G && u && (Math.max(A * u.length, L) > o || !!v), P = V === "rtl", U = se(r, F({}, "".concat(r, "-rtl"), P), i), X = u || DB, H = Te(), J = Te(), Z = Te(), ee = vt(0), W = _(ee, 2), Ae = W[0], le = W[1], ue = vt(0), te = _(ue, 2), me = te[0], K = te[1], de = vt(!1), ce = _(de, 2), ye = ce[0], Ie = ce[1], Ve = function() {
|
|
31072
31072
|
Ie(!0);
|
|
31073
31073
|
}, Oe = function() {
|
|
31074
31074
|
Ie(!1);
|
|
@@ -31099,7 +31099,7 @@ function FB(t, e) {
|
|
|
31099
31099
|
if (!Y) {
|
|
31100
31100
|
var qe;
|
|
31101
31101
|
return {
|
|
31102
|
-
scrollHeight: ((qe =
|
|
31102
|
+
scrollHeight: ((qe = J.current) === null || qe === void 0 ? void 0 : qe.offsetHeight) || 0,
|
|
31103
31103
|
start: 0,
|
|
31104
31104
|
end: X.length - 1,
|
|
31105
31105
|
offset: void 0
|
|
@@ -31275,7 +31275,7 @@ function FB(t, e) {
|
|
|
31275
31275
|
offsetY: ut,
|
|
31276
31276
|
scrollWidth: v,
|
|
31277
31277
|
onInnerResize: B,
|
|
31278
|
-
ref:
|
|
31278
|
+
ref: J,
|
|
31279
31279
|
innerProps: I,
|
|
31280
31280
|
rtl: P,
|
|
31281
31281
|
extra: tt
|
|
@@ -31380,7 +31380,7 @@ var UB = function(e, n) {
|
|
|
31380
31380
|
return clearTimeout(ue);
|
|
31381
31381
|
};
|
|
31382
31382
|
}, [A, l]);
|
|
31383
|
-
var
|
|
31383
|
+
var J = function(te) {
|
|
31384
31384
|
te !== void 0 && w(te, {
|
|
31385
31385
|
selected: !M.has(te)
|
|
31386
31386
|
}), a || u(!1);
|
|
@@ -31406,7 +31406,7 @@ var UB = function(e, n) {
|
|
|
31406
31406
|
case At.TAB:
|
|
31407
31407
|
case At.ENTER: {
|
|
31408
31408
|
var ye, Ie = R[P];
|
|
31409
|
-
Ie && !(Ie != null && (ye = Ie.data) !== null && ye !== void 0 && ye.disabled) && !T ?
|
|
31409
|
+
Ie && !(Ie != null && (ye = Ie.data) !== null && ye !== void 0 && ye.disabled) && !T ? J(Ie.value) : J(void 0), A && te.preventDefault();
|
|
31410
31410
|
break;
|
|
31411
31411
|
}
|
|
31412
31412
|
// >>> Close
|
|
@@ -31493,7 +31493,7 @@ var UB = function(e, n) {
|
|
|
31493
31493
|
P === te || rt || X(te);
|
|
31494
31494
|
},
|
|
31495
31495
|
onClick: function() {
|
|
31496
|
-
rt ||
|
|
31496
|
+
rt || J(ye);
|
|
31497
31497
|
},
|
|
31498
31498
|
style: Se
|
|
31499
31499
|
}), /* @__PURE__ */ c.createElement("div", {
|
|
@@ -31683,17 +31683,17 @@ function $B(t) {
|
|
|
31683
31683
|
return !t || nt(t) !== "object";
|
|
31684
31684
|
}
|
|
31685
31685
|
var EC = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
31686
|
-
var n = t.id, r = t.mode, i = t.prefixCls, o = i === void 0 ? "rc-select" : i, A = t.backfill, a = t.fieldNames, s = t.inputValue, l = t.searchValue, u = t.onSearch, d = t.autoClearSearchValue, g = d === void 0 ? !0 : d, p = t.onSelect, V = t.onDeselect, v = t.dropdownMatchSelectWidth, m = v === void 0 ? !0 : v, C = t.filterOption, w = t.filterSort, S = t.optionFilterProp, M = t.optionLabelProp, I = t.options, f = t.optionRender, x = t.children, q = t.defaultActiveFirstOption, E = t.menuItemSelectedIcon, h = t.virtual, y = t.direction, R = t.listHeight, b = R === void 0 ? 200 : R, T = t.listItemHeight, B = T === void 0 ? 20 : T, D = t.labelRender, N = t.value, G = t.defaultValue, L = t.labelInValue, Y = t.onChange, P = t.maxCount, U = yt(t, XB), X = YB(n), H = Rs(r),
|
|
31686
|
+
var n = t.id, r = t.mode, i = t.prefixCls, o = i === void 0 ? "rc-select" : i, A = t.backfill, a = t.fieldNames, s = t.inputValue, l = t.searchValue, u = t.onSearch, d = t.autoClearSearchValue, g = d === void 0 ? !0 : d, p = t.onSelect, V = t.onDeselect, v = t.dropdownMatchSelectWidth, m = v === void 0 ? !0 : v, C = t.filterOption, w = t.filterSort, S = t.optionFilterProp, M = t.optionLabelProp, I = t.options, f = t.optionRender, x = t.children, q = t.defaultActiveFirstOption, E = t.menuItemSelectedIcon, h = t.virtual, y = t.direction, R = t.listHeight, b = R === void 0 ? 200 : R, T = t.listItemHeight, B = T === void 0 ? 20 : T, D = t.labelRender, N = t.value, G = t.defaultValue, L = t.labelInValue, Y = t.onChange, P = t.maxCount, U = yt(t, XB), X = YB(n), H = Rs(r), J = !!(!I && x), Z = c.useMemo(function() {
|
|
31687
31687
|
return C === void 0 && r === "combobox" ? !1 : C;
|
|
31688
31688
|
}, [C, r]), ee = c.useMemo(
|
|
31689
31689
|
function() {
|
|
31690
|
-
return pC(a,
|
|
31690
|
+
return pC(a, J);
|
|
31691
31691
|
},
|
|
31692
31692
|
/* eslint-disable react-hooks/exhaustive-deps */
|
|
31693
31693
|
[
|
|
31694
31694
|
// We stringify fieldNames to avoid unnecessary re-renders.
|
|
31695
31695
|
JSON.stringify(a),
|
|
31696
|
-
|
|
31696
|
+
J
|
|
31697
31697
|
]
|
|
31698
31698
|
/* eslint-enable react-hooks/exhaustive-deps */
|
|
31699
31699
|
), W = Dn("", {
|
|
@@ -31792,9 +31792,9 @@ var EC = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
|
31792
31792
|
}, [Xe, w, le]), De = c.useMemo(function() {
|
|
31793
31793
|
return pB($e, {
|
|
31794
31794
|
fieldNames: ee,
|
|
31795
|
-
childrenAsData:
|
|
31795
|
+
childrenAsData: J
|
|
31796
31796
|
});
|
|
31797
|
-
}, [$e, ee,
|
|
31797
|
+
}, [$e, ee, J]), xe = function(we) {
|
|
31798
31798
|
var He = ce(we);
|
|
31799
31799
|
if (Oe(He), Y && // Trigger event only when value changed
|
|
31800
31800
|
(He.length !== pe.length || He.some(function(O, fe) {
|
|
@@ -31879,11 +31879,11 @@ var EC = /* @__PURE__ */ c.forwardRef(function(t, e) {
|
|
|
31879
31879
|
direction: y,
|
|
31880
31880
|
listHeight: b,
|
|
31881
31881
|
listItemHeight: B,
|
|
31882
|
-
childrenAsData:
|
|
31882
|
+
childrenAsData: J,
|
|
31883
31883
|
maxCount: P,
|
|
31884
31884
|
optionRender: f
|
|
31885
31885
|
});
|
|
31886
|
-
}, [P, te, De, Rt, Kt, Ke, E, et, ee, h, m, y, b, B,
|
|
31886
|
+
}, [P, te, De, Rt, Kt, Ke, E, et, ee, h, m, y, b, B, J, f]);
|
|
31887
31887
|
return process.env.NODE_ENV !== "production" && (JB(t), WB(de, ee)), /* @__PURE__ */ c.createElement(Tg.Provider, {
|
|
31888
31888
|
value: Vt
|
|
31889
31889
|
}, /* @__PURE__ */ c.createElement(mC, ke({}, U, {
|
|
@@ -32233,7 +32233,7 @@ const xC = "SECRET_COMBOBOX_MODE_DO_NOT_USE", RC = (t, e) => {
|
|
|
32233
32233
|
virtual: G,
|
|
32234
32234
|
popupMatchSelectWidth: L,
|
|
32235
32235
|
popupOverflow: Y
|
|
32236
|
-
} = c.useContext(Gt), P = pi("select"), [, U] = Tr(), X = g ?? (U == null ? void 0 : U.controlHeight), H = B("select", r),
|
|
32236
|
+
} = c.useContext(Gt), P = pi("select"), [, U] = Tr(), X = g ?? (U == null ? void 0 : U.controlHeight), H = B("select", r), J = B(), Z = M ?? N, {
|
|
32237
32237
|
compactSize: ee,
|
|
32238
32238
|
compactItemClassnames: W
|
|
32239
32239
|
} = tA(H, Z), [Ae, le] = ug("select", x, i), ue = ti(H), [te, me, K] = N2(H, ue), de = c.useMemo(() => {
|
|
@@ -32290,7 +32290,7 @@ const xC = "SECRET_COMBOBOX_MODE_DO_NOT_USE", RC = (t, e) => {
|
|
|
32290
32290
|
}, Ee, {
|
|
32291
32291
|
style: Object.assign(Object.assign({}, P.style), I),
|
|
32292
32292
|
dropdownMatchSelectWidth: Ie,
|
|
32293
|
-
transitionName: gg(
|
|
32293
|
+
transitionName: gg(J, "slide-up", E),
|
|
32294
32294
|
builtinPlacements: rO(C, Y),
|
|
32295
32295
|
listHeight: u,
|
|
32296
32296
|
listItemHeight: X,
|
|
@@ -32823,7 +32823,7 @@ const kO = {
|
|
|
32823
32823
|
空闲: 1,
|
|
32824
32824
|
离线: 0,
|
|
32825
32825
|
未注册: 4
|
|
32826
|
-
}, jO = _m(() => import("./ConsultModel-
|
|
32826
|
+
}, jO = _m(() => import("./ConsultModel-NOhzCzrd.mjs")), PO = _m(() => import("./TransferModel-Df3UJnMz.mjs")), gc = an.div`
|
|
32827
32827
|
width: 25px;
|
|
32828
32828
|
height: 25px;
|
|
32829
32829
|
background: ${({
|
|
@@ -32855,7 +32855,7 @@ const kO = {
|
|
|
32855
32855
|
idle: m,
|
|
32856
32856
|
unavailable: C,
|
|
32857
32857
|
selectOutNumberColor: w
|
|
32858
|
-
} = e || {}, S = Te(), M = Te(), [I, f] = vt(new Audio(bO)), [x, q] = vt(new Audio(MO)), [E, h] = vt(), [y, R] = vt(), [b, T] = vt(!1), [B, D] = vt((/* @__PURE__ */ new Date()).getTime()), [N, G] = vt(), [L, Y] = vt(), [P, U] = vt([]), [X, H] = vt([]), [
|
|
32858
|
+
} = e || {}, S = Te(), M = Te(), [I, f] = vt(new Audio(bO)), [x, q] = vt(new Audio(MO)), [E, h] = vt(), [y, R] = vt(), [b, T] = vt(!1), [B, D] = vt((/* @__PURE__ */ new Date()).getTime()), [N, G] = vt(), [L, Y] = vt(), [P, U] = vt([]), [X, H] = vt([]), [J, Z] = vt(""), [ee, W] = vt(!1), [Ae, le] = vt([]), [ue, te] = vt(""), [me, K] = vt(""), [de, ce] = vt(!1), [ye, Ie] = vt(!1), [Ve, Oe] = vt(), [Qe, Ue] = vt((/* @__PURE__ */ new Date()).getTime()), [Se, pe] = vt(!0), [Me, Ye] = vt(""), et = (Q) => {
|
|
32859
32859
|
switch (Q) {
|
|
32860
32860
|
case xt.IDLE:
|
|
32861
32861
|
return m || "#1D92E9";
|
|
@@ -33601,9 +33601,9 @@ const kO = {
|
|
|
33601
33601
|
children: [/* @__PURE__ */ ie.jsxs("div", {
|
|
33602
33602
|
className: "ysyt-strip",
|
|
33603
33603
|
children: [/* @__PURE__ */ ie.jsx("div", {
|
|
33604
|
-
children:
|
|
33604
|
+
children: J ? /* @__PURE__ */ ie.jsx("span", {
|
|
33605
33605
|
className: "ysyt-strip-state-name",
|
|
33606
|
-
children:
|
|
33606
|
+
children: J
|
|
33607
33607
|
}) : /* @__PURE__ */ ie.jsx(eC, {
|
|
33608
33608
|
trigger: ["click"],
|
|
33609
33609
|
menu: {
|