widget-chatbot 2.0.0-alpha.19 → 2.0.0-alpha.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.
@@ -1,7 +1,7 @@
1
- import bn, { version as Wt, createContext as Te, useContext as ye, useState as D, useRef as K, useMemo as O, useEffect as X, memo as R, Children as Vt, isValidElement as Gt, cloneElement as zt, Fragment as Cn, createElement as vn, useCallback as Yt } from "react";
1
+ import bn, { version as Wt, createContext as Te, useContext as ye, useState as D, useRef as K, useMemo as R, useEffect as X, memo as O, Children as Vt, isValidElement as Gt, cloneElement as zt, Fragment as mn, createElement as vn, useCallback as Yt } from "react";
2
2
  import Oe from "axios";
3
3
  import ae from "dayjs";
4
- import { version as Kt, Modal as Un, Typography as V, Button as z, Form as oe, notification as ie, Radio as qt, Divider as Jt, Input as Be, Image as Qt, Skeleton as ue, Avatar as Xn, Upload as Pn, Spin as Zt, Tooltip as Se, Tag as Xt, Badge as Pt, Grid as Ce, Empty as et, Popover as hn, Mentions as Wn, Select as Vn, DatePicker as es, Result as ns, Tabs as cn } from "antd";
4
+ import { version as Kt, Modal as Un, Typography as G, Button as Y, Form as oe, notification as ie, Radio as qt, Divider as Jt, Input as Be, Image as Qt, Skeleton as ue, Avatar as Xn, Upload as Pn, Spin as Zt, Tooltip as Se, Tag as Xt, Badge as Pt, Grid as me, Empty as et, Popover as hn, Mentions as Wn, Select as Vn, DatePicker as es, Result as ns, Tabs as cn } from "antd";
5
5
  import { io as ts } from "socket.io-client";
6
6
  import ss from "react-markdown";
7
7
  import rs from "remark-gfm";
@@ -10,7 +10,7 @@ import cs from "@ant-design/icons";
10
10
  import { Pie as is } from "@ant-design/charts";
11
11
  import ke from "crypto-js";
12
12
  import { Picker as ls } from "emoji-mart";
13
- var Je = { exports: {} }, pe = {};
13
+ var Je = { exports: {} }, _e = {};
14
14
  /*
15
15
  object-assign
16
16
  (c) Sindre Sorhus
@@ -21,24 +21,24 @@ function nt() {
21
21
  if (Gn) return ln;
22
22
  Gn = 1;
23
23
  var e = Object.getOwnPropertySymbols, t = Object.prototype.hasOwnProperty, r = Object.prototype.propertyIsEnumerable;
24
- function s(c) {
25
- if (c == null)
24
+ function s(i) {
25
+ if (i == null)
26
26
  throw new TypeError("Object.assign cannot be called with null or undefined");
27
- return Object(c);
27
+ return Object(i);
28
28
  }
29
- function a() {
29
+ function l() {
30
30
  try {
31
31
  if (!Object.assign)
32
32
  return !1;
33
- var c = new String("abc");
34
- if (c[5] = "de", Object.getOwnPropertyNames(c)[0] === "5")
33
+ var i = new String("abc");
34
+ if (i[5] = "de", Object.getOwnPropertyNames(i)[0] === "5")
35
35
  return !1;
36
36
  for (var o = {}, d = 0; d < 10; d++)
37
37
  o["_" + String.fromCharCode(d)] = d;
38
- var i = Object.getOwnPropertyNames(o).map(function(f) {
38
+ var c = Object.getOwnPropertyNames(o).map(function(f) {
39
39
  return o[f];
40
40
  });
41
- if (i.join("") !== "0123456789")
41
+ if (c.join("") !== "0123456789")
42
42
  return !1;
43
43
  var u = {};
44
44
  return "abcdefghijklmnopqrst".split("").forEach(function(f) {
@@ -48,18 +48,18 @@ function nt() {
48
48
  return !1;
49
49
  }
50
50
  }
51
- return ln = a() ? Object.assign : function(c, o) {
52
- for (var d, i = s(c), u, f = 1; f < arguments.length; f++) {
51
+ return ln = l() ? Object.assign : function(i, o) {
52
+ for (var d, c = s(i), u, f = 1; f < arguments.length; f++) {
53
53
  d = Object(arguments[f]);
54
54
  for (var x in d)
55
- t.call(d, x) && (i[x] = d[x]);
55
+ t.call(d, x) && (c[x] = d[x]);
56
56
  if (e) {
57
57
  u = e(d);
58
58
  for (var g = 0; g < u.length; g++)
59
- r.call(d, u[g]) && (i[u[g]] = d[u[g]]);
59
+ r.call(d, u[g]) && (c[u[g]] = d[u[g]]);
60
60
  }
61
61
  }
62
- return i;
62
+ return c;
63
63
  }, ln;
64
64
  }
65
65
  /** @license React v17.0.2
@@ -72,22 +72,22 @@ function nt() {
72
72
  */
73
73
  var zn;
74
74
  function as() {
75
- if (zn) return pe;
75
+ if (zn) return _e;
76
76
  zn = 1, nt();
77
77
  var e = bn, t = 60103;
78
- if (pe.Fragment = 60107, typeof Symbol == "function" && Symbol.for) {
78
+ if (_e.Fragment = 60107, typeof Symbol == "function" && Symbol.for) {
79
79
  var r = Symbol.for;
80
- t = r("react.element"), pe.Fragment = r("react.fragment");
80
+ t = r("react.element"), _e.Fragment = r("react.fragment");
81
81
  }
82
- var s = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, a = Object.prototype.hasOwnProperty, c = { key: !0, ref: !0, __self: !0, __source: !0 };
83
- function o(d, i, u) {
84
- var f, x = {}, g = null, C = null;
85
- u !== void 0 && (g = "" + u), i.key !== void 0 && (g = "" + i.key), i.ref !== void 0 && (C = i.ref);
86
- for (f in i) a.call(i, f) && !c.hasOwnProperty(f) && (x[f] = i[f]);
87
- if (d && d.defaultProps) for (f in i = d.defaultProps, i) x[f] === void 0 && (x[f] = i[f]);
88
- return { $$typeof: t, type: d, key: g, ref: C, props: x, _owner: s.current };
82
+ var s = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, l = Object.prototype.hasOwnProperty, i = { key: !0, ref: !0, __self: !0, __source: !0 };
83
+ function o(d, c, u) {
84
+ var f, x = {}, g = null, m = null;
85
+ u !== void 0 && (g = "" + u), c.key !== void 0 && (g = "" + c.key), c.ref !== void 0 && (m = c.ref);
86
+ for (f in c) l.call(c, f) && !i.hasOwnProperty(f) && (x[f] = c[f]);
87
+ if (d && d.defaultProps) for (f in c = d.defaultProps, c) x[f] === void 0 && (x[f] = c[f]);
88
+ return { $$typeof: t, type: d, key: g, ref: m, props: x, _owner: s.current };
89
89
  }
90
- return pe.jsx = o, pe.jsxs = o, pe;
90
+ return _e.jsx = o, _e.jsxs = o, _e;
91
91
  }
92
92
  var an = {};
93
93
  /** @license React v17.0.2
@@ -102,86 +102,86 @@ var Yn;
102
102
  function ds() {
103
103
  return Yn || (Yn = 1, function(e) {
104
104
  process.env.NODE_ENV !== "production" && function() {
105
- var t = bn, r = nt(), s = 60103, a = 60106;
105
+ var t = bn, r = nt(), s = 60103, l = 60106;
106
106
  e.Fragment = 60107;
107
- var c = 60108, o = 60114, d = 60109, i = 60110, u = 60112, f = 60113, x = 60120, g = 60115, C = 60116, y = 60121, j = 60122, p = 60117, w = 60129, v = 60131;
107
+ var i = 60108, o = 60114, d = 60109, c = 60110, u = 60112, f = 60113, x = 60120, g = 60115, m = 60116, T = 60121, w = 60122, p = 60117, j = 60129, v = 60131;
108
108
  if (typeof Symbol == "function" && Symbol.for) {
109
109
  var h = Symbol.for;
110
- s = h("react.element"), a = h("react.portal"), e.Fragment = h("react.fragment"), c = h("react.strict_mode"), o = h("react.profiler"), d = h("react.provider"), i = h("react.context"), u = h("react.forward_ref"), f = h("react.suspense"), x = h("react.suspense_list"), g = h("react.memo"), C = h("react.lazy"), y = h("react.block"), j = h("react.server.block"), p = h("react.fundamental"), h("react.scope"), h("react.opaque.id"), w = h("react.debug_trace_mode"), h("react.offscreen"), v = h("react.legacy_hidden");
110
+ s = h("react.element"), l = h("react.portal"), e.Fragment = h("react.fragment"), i = h("react.strict_mode"), o = h("react.profiler"), d = h("react.provider"), c = h("react.context"), u = h("react.forward_ref"), f = h("react.suspense"), x = h("react.suspense_list"), g = h("react.memo"), m = h("react.lazy"), T = h("react.block"), w = h("react.server.block"), p = h("react.fundamental"), h("react.scope"), h("react.opaque.id"), j = h("react.debug_trace_mode"), h("react.offscreen"), v = h("react.legacy_hidden");
111
111
  }
112
112
  var b = typeof Symbol == "function" && Symbol.iterator, E = "@@iterator";
113
- function m(l) {
114
- if (l === null || typeof l != "object")
113
+ function C(a) {
114
+ if (a === null || typeof a != "object")
115
115
  return null;
116
- var T = b && l[b] || l[E];
117
- return typeof T == "function" ? T : null;
116
+ var y = b && a[b] || a[E];
117
+ return typeof y == "function" ? y : null;
118
118
  }
119
119
  var k = t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
120
- function S(l) {
120
+ function S(a) {
121
121
  {
122
- for (var T = arguments.length, A = new Array(T > 1 ? T - 1 : 0), N = 1; N < T; N++)
122
+ for (var y = arguments.length, A = new Array(y > 1 ? y - 1 : 0), N = 1; N < y; N++)
123
123
  A[N - 1] = arguments[N];
124
- H("error", l, A);
124
+ F("error", a, A);
125
125
  }
126
126
  }
127
- function H(l, T, A) {
127
+ function F(a, y, A) {
128
128
  {
129
129
  var N = k.ReactDebugCurrentFrame, Z = N.getStackAddendum();
130
- Z !== "" && (T += "%s", A = A.concat([Z]));
131
- var Q = A.map(function(W) {
132
- return "" + W;
130
+ Z !== "" && (y += "%s", A = A.concat([Z]));
131
+ var Q = A.map(function(V) {
132
+ return "" + V;
133
133
  });
134
- Q.unshift("Warning: " + T), Function.prototype.apply.call(console[l], console, Q);
134
+ Q.unshift("Warning: " + y), Function.prototype.apply.call(console[a], console, Q);
135
135
  }
136
136
  }
137
137
  var B = !1;
138
- function M(l) {
139
- return !!(typeof l == "string" || typeof l == "function" || l === e.Fragment || l === o || l === w || l === c || l === f || l === x || l === v || B || typeof l == "object" && l !== null && (l.$$typeof === C || l.$$typeof === g || l.$$typeof === d || l.$$typeof === i || l.$$typeof === u || l.$$typeof === p || l.$$typeof === y || l[0] === j));
138
+ function M(a) {
139
+ return !!(typeof a == "string" || typeof a == "function" || a === e.Fragment || a === o || a === j || a === i || a === f || a === x || a === v || B || typeof a == "object" && a !== null && (a.$$typeof === m || a.$$typeof === g || a.$$typeof === d || a.$$typeof === c || a.$$typeof === u || a.$$typeof === p || a.$$typeof === T || a[0] === w));
140
140
  }
141
- function L(l, T, A) {
142
- var N = T.displayName || T.name || "";
143
- return l.displayName || (N !== "" ? A + "(" + N + ")" : A);
141
+ function L(a, y, A) {
142
+ var N = y.displayName || y.name || "";
143
+ return a.displayName || (N !== "" ? A + "(" + N + ")" : A);
144
144
  }
145
- function I(l) {
146
- return l.displayName || "Context";
145
+ function H(a) {
146
+ return a.displayName || "Context";
147
147
  }
148
- function $(l) {
149
- if (l == null)
148
+ function $(a) {
149
+ if (a == null)
150
150
  return null;
151
- if (typeof l.tag == "number" && S("Received an unexpected object in getComponentName(). This is likely a bug in React. Please file an issue."), typeof l == "function")
152
- return l.displayName || l.name || null;
153
- if (typeof l == "string")
154
- return l;
155
- switch (l) {
151
+ if (typeof a.tag == "number" && S("Received an unexpected object in getComponentName(). This is likely a bug in React. Please file an issue."), typeof a == "function")
152
+ return a.displayName || a.name || null;
153
+ if (typeof a == "string")
154
+ return a;
155
+ switch (a) {
156
156
  case e.Fragment:
157
157
  return "Fragment";
158
- case a:
158
+ case l:
159
159
  return "Portal";
160
160
  case o:
161
161
  return "Profiler";
162
- case c:
162
+ case i:
163
163
  return "StrictMode";
164
164
  case f:
165
165
  return "Suspense";
166
166
  case x:
167
167
  return "SuspenseList";
168
168
  }
169
- if (typeof l == "object")
170
- switch (l.$$typeof) {
171
- case i:
172
- var T = l;
173
- return I(T) + ".Consumer";
169
+ if (typeof a == "object")
170
+ switch (a.$$typeof) {
171
+ case c:
172
+ var y = a;
173
+ return H(y) + ".Consumer";
174
174
  case d:
175
- var A = l;
176
- return I(A._context) + ".Provider";
175
+ var A = a;
176
+ return H(A._context) + ".Provider";
177
177
  case u:
178
- return L(l, l.render, "ForwardRef");
178
+ return L(a, a.render, "ForwardRef");
179
179
  case g:
180
- return $(l.type);
181
- case y:
182
- return $(l._render);
183
- case C: {
184
- var N = l, Z = N._payload, Q = N._init;
180
+ return $(a.type);
181
+ case T:
182
+ return $(a._render);
183
+ case m: {
184
+ var N = a, Z = N._payload, Q = N._init;
185
185
  try {
186
186
  return $(Q(Z));
187
187
  } catch {
@@ -191,70 +191,70 @@ function ds() {
191
191
  }
192
192
  return null;
193
193
  }
194
- var F = 0, G, J, Y, te, ee, de, ce;
194
+ var I = 0, J, z, W, te, ee, de, ce;
195
195
  function Ne() {
196
196
  }
197
197
  Ne.__reactDisabledLog = !0;
198
198
  function Ve() {
199
199
  {
200
- if (F === 0) {
201
- G = console.log, J = console.info, Y = console.warn, te = console.error, ee = console.group, de = console.groupCollapsed, ce = console.groupEnd;
202
- var l = {
200
+ if (I === 0) {
201
+ J = console.log, z = console.info, W = console.warn, te = console.error, ee = console.group, de = console.groupCollapsed, ce = console.groupEnd;
202
+ var a = {
203
203
  configurable: !0,
204
204
  enumerable: !0,
205
205
  value: Ne,
206
206
  writable: !0
207
207
  };
208
208
  Object.defineProperties(console, {
209
- info: l,
210
- log: l,
211
- warn: l,
212
- error: l,
213
- group: l,
214
- groupCollapsed: l,
215
- groupEnd: l
209
+ info: a,
210
+ log: a,
211
+ warn: a,
212
+ error: a,
213
+ group: a,
214
+ groupCollapsed: a,
215
+ groupEnd: a
216
216
  });
217
217
  }
218
- F++;
218
+ I++;
219
219
  }
220
220
  }
221
221
  function Ge() {
222
222
  {
223
- if (F--, F === 0) {
224
- var l = {
223
+ if (I--, I === 0) {
224
+ var a = {
225
225
  configurable: !0,
226
226
  enumerable: !0,
227
227
  writable: !0
228
228
  };
229
229
  Object.defineProperties(console, {
230
- log: r({}, l, {
231
- value: G
232
- }),
233
- info: r({}, l, {
230
+ log: r({}, a, {
234
231
  value: J
235
232
  }),
236
- warn: r({}, l, {
237
- value: Y
233
+ info: r({}, a, {
234
+ value: z
235
+ }),
236
+ warn: r({}, a, {
237
+ value: W
238
238
  }),
239
- error: r({}, l, {
239
+ error: r({}, a, {
240
240
  value: te
241
241
  }),
242
- group: r({}, l, {
242
+ group: r({}, a, {
243
243
  value: ee
244
244
  }),
245
- groupCollapsed: r({}, l, {
245
+ groupCollapsed: r({}, a, {
246
246
  value: de
247
247
  }),
248
- groupEnd: r({}, l, {
248
+ groupEnd: r({}, a, {
249
249
  value: ce
250
250
  })
251
251
  });
252
252
  }
253
- F < 0 && S("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
253
+ I < 0 && S("disabledDepth fell below zero. This is a bug in React. Please file an issue.");
254
254
  }
255
255
  }
256
256
  var Me = k.ReactCurrentDispatcher, Fe;
257
- function ze(l, T, A) {
257
+ function ze(a, y, A) {
258
258
  {
259
259
  if (Fe === void 0)
260
260
  try {
@@ -264,7 +264,7 @@ function ds() {
264
264
  Fe = N && N[1] || "";
265
265
  }
266
266
  return `
267
- ` + Fe + l;
267
+ ` + Fe + a;
268
268
  }
269
269
  }
270
270
  var nn = !1, Ye;
@@ -272,11 +272,11 @@ function ds() {
272
272
  var jt = typeof WeakMap == "function" ? WeakMap : Map;
273
273
  Ye = new jt();
274
274
  }
275
- function _n(l, T) {
276
- if (!l || nn)
275
+ function pn(a, y) {
276
+ if (!a || nn)
277
277
  return "";
278
278
  {
279
- var A = Ye.get(l);
279
+ var A = Ye.get(a);
280
280
  if (A !== void 0)
281
281
  return A;
282
282
  }
@@ -287,28 +287,28 @@ function ds() {
287
287
  var Q;
288
288
  Q = Me.current, Me.current = null, Ve();
289
289
  try {
290
- if (T) {
291
- var W = function() {
290
+ if (y) {
291
+ var V = function() {
292
292
  throw Error();
293
293
  };
294
- if (Object.defineProperty(W.prototype, "props", {
294
+ if (Object.defineProperty(V.prototype, "props", {
295
295
  set: function() {
296
296
  throw Error();
297
297
  }
298
298
  }), typeof Reflect == "object" && Reflect.construct) {
299
299
  try {
300
- Reflect.construct(W, []);
300
+ Reflect.construct(V, []);
301
301
  } catch (ge) {
302
302
  N = ge;
303
303
  }
304
- Reflect.construct(l, [], W);
304
+ Reflect.construct(a, [], V);
305
305
  } else {
306
306
  try {
307
- W.call();
307
+ V.call();
308
308
  } catch (ge) {
309
309
  N = ge;
310
310
  }
311
- l.call(W.prototype);
311
+ a.call(V.prototype);
312
312
  }
313
313
  } else {
314
314
  try {
@@ -316,7 +316,7 @@ function ds() {
316
316
  } catch (ge) {
317
317
  N = ge;
318
318
  }
319
- l();
319
+ a();
320
320
  }
321
321
  } catch (ge) {
322
322
  if (ge && N && typeof ge.stack == "string") {
@@ -331,7 +331,7 @@ function ds() {
331
331
  if (ne--, se--, se < 0 || U[ne] !== re[se]) {
332
332
  var xe = `
333
333
  ` + U[ne].replace(" at new ", " at ");
334
- return typeof l == "function" && Ye.set(l, xe), xe;
334
+ return typeof a == "function" && Ye.set(a, xe), xe;
335
335
  }
336
336
  while (ne >= 1 && se >= 0);
337
337
  break;
@@ -340,41 +340,41 @@ function ds() {
340
340
  } finally {
341
341
  nn = !1, Me.current = Q, Ge(), Error.prepareStackTrace = Z;
342
342
  }
343
- var we = l ? l.displayName || l.name : "", Bn = we ? ze(we) : "";
344
- return typeof l == "function" && Ye.set(l, Bn), Bn;
343
+ var we = a ? a.displayName || a.name : "", Bn = we ? ze(we) : "";
344
+ return typeof a == "function" && Ye.set(a, Bn), Bn;
345
345
  }
346
- function An(l, T, A) {
347
- return _n(l, !1);
346
+ function An(a, y, A) {
347
+ return pn(a, !1);
348
348
  }
349
- function wt(l) {
350
- var T = l.prototype;
351
- return !!(T && T.isReactComponent);
349
+ function wt(a) {
350
+ var y = a.prototype;
351
+ return !!(y && y.isReactComponent);
352
352
  }
353
- function Ke(l, T, A) {
354
- if (l == null)
353
+ function Ke(a, y, A) {
354
+ if (a == null)
355
355
  return "";
356
- if (typeof l == "function")
357
- return _n(l, wt(l));
358
- if (typeof l == "string")
359
- return ze(l);
360
- switch (l) {
356
+ if (typeof a == "function")
357
+ return pn(a, wt(a));
358
+ if (typeof a == "string")
359
+ return ze(a);
360
+ switch (a) {
361
361
  case f:
362
362
  return ze("Suspense");
363
363
  case x:
364
364
  return ze("SuspenseList");
365
365
  }
366
- if (typeof l == "object")
367
- switch (l.$$typeof) {
366
+ if (typeof a == "object")
367
+ switch (a.$$typeof) {
368
368
  case u:
369
- return An(l.render);
369
+ return An(a.render);
370
370
  case g:
371
- return Ke(l.type, T, A);
372
- case y:
373
- return An(l._render);
374
- case C: {
375
- var N = l, Z = N._payload, Q = N._init;
371
+ return Ke(a.type, y, A);
372
+ case T:
373
+ return An(a._render);
374
+ case m: {
375
+ var N = a, Z = N._payload, Q = N._init;
376
376
  try {
377
- return Ke(Q(Z), T, A);
377
+ return Ke(Q(Z), y, A);
378
378
  } catch {
379
379
  }
380
380
  }
@@ -382,88 +382,88 @@ function ds() {
382
382
  return "";
383
383
  }
384
384
  var Sn = {}, Ln = k.ReactDebugCurrentFrame;
385
- function qe(l) {
386
- if (l) {
387
- var T = l._owner, A = Ke(l.type, l._source, T ? T.type : null);
385
+ function qe(a) {
386
+ if (a) {
387
+ var y = a._owner, A = Ke(a.type, a._source, y ? y.type : null);
388
388
  Ln.setExtraStackFrame(A);
389
389
  } else
390
390
  Ln.setExtraStackFrame(null);
391
391
  }
392
- function kt(l, T, A, N, Z) {
392
+ function kt(a, y, A, N, Z) {
393
393
  {
394
394
  var Q = Function.call.bind(Object.prototype.hasOwnProperty);
395
- for (var W in l)
396
- if (Q(l, W)) {
395
+ for (var V in a)
396
+ if (Q(a, V)) {
397
397
  var U = void 0;
398
398
  try {
399
- if (typeof l[W] != "function") {
400
- var re = Error((N || "React class") + ": " + A + " type `" + W + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof l[W] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
399
+ if (typeof a[V] != "function") {
400
+ var re = Error((N || "React class") + ": " + A + " type `" + V + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + typeof a[V] + "`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");
401
401
  throw re.name = "Invariant Violation", re;
402
402
  }
403
- U = l[W](T, W, N, A, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
403
+ U = a[V](y, V, N, A, null, "SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");
404
404
  } catch (ne) {
405
405
  U = ne;
406
406
  }
407
- U && !(U instanceof Error) && (qe(Z), S("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", N || "React class", A, W, typeof U), qe(null)), U instanceof Error && !(U.message in Sn) && (Sn[U.message] = !0, qe(Z), S("Failed %s type: %s", A, U.message), qe(null));
407
+ U && !(U instanceof Error) && (qe(Z), S("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", N || "React class", A, V, typeof U), qe(null)), U instanceof Error && !(U.message in Sn) && (Sn[U.message] = !0, qe(Z), S("Failed %s type: %s", A, U.message), qe(null));
408
408
  }
409
409
  }
410
410
  }
411
- var Rn = k.ReactCurrentOwner, tn = Object.prototype.hasOwnProperty, pt = {
411
+ var Rn = k.ReactCurrentOwner, tn = Object.prototype.hasOwnProperty, _t = {
412
412
  key: !0,
413
413
  ref: !0,
414
414
  __self: !0,
415
415
  __source: !0
416
416
  }, On, Dn;
417
- function _t(l) {
418
- if (tn.call(l, "ref")) {
419
- var T = Object.getOwnPropertyDescriptor(l, "ref").get;
420
- if (T && T.isReactWarning)
417
+ function pt(a) {
418
+ if (tn.call(a, "ref")) {
419
+ var y = Object.getOwnPropertyDescriptor(a, "ref").get;
420
+ if (y && y.isReactWarning)
421
421
  return !1;
422
422
  }
423
- return l.ref !== void 0;
423
+ return a.ref !== void 0;
424
424
  }
425
- function At(l) {
426
- if (tn.call(l, "key")) {
427
- var T = Object.getOwnPropertyDescriptor(l, "key").get;
428
- if (T && T.isReactWarning)
425
+ function At(a) {
426
+ if (tn.call(a, "key")) {
427
+ var y = Object.getOwnPropertyDescriptor(a, "key").get;
428
+ if (y && y.isReactWarning)
429
429
  return !1;
430
430
  }
431
- return l.key !== void 0;
431
+ return a.key !== void 0;
432
432
  }
433
- function St(l, T) {
434
- typeof l.ref == "string" && Rn.current;
433
+ function St(a, y) {
434
+ typeof a.ref == "string" && Rn.current;
435
435
  }
436
- function Lt(l, T) {
436
+ function Lt(a, y) {
437
437
  {
438
438
  var A = function() {
439
- On || (On = !0, S("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", T));
439
+ On || (On = !0, S("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", y));
440
440
  };
441
- A.isReactWarning = !0, Object.defineProperty(l, "key", {
441
+ A.isReactWarning = !0, Object.defineProperty(a, "key", {
442
442
  get: A,
443
443
  configurable: !0
444
444
  });
445
445
  }
446
446
  }
447
- function Rt(l, T) {
447
+ function Rt(a, y) {
448
448
  {
449
449
  var A = function() {
450
- Dn || (Dn = !0, S("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", T));
450
+ Dn || (Dn = !0, S("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)", y));
451
451
  };
452
- A.isReactWarning = !0, Object.defineProperty(l, "ref", {
452
+ A.isReactWarning = !0, Object.defineProperty(a, "ref", {
453
453
  get: A,
454
454
  configurable: !0
455
455
  });
456
456
  }
457
457
  }
458
- var Ot = function(l, T, A, N, Z, Q, W) {
458
+ var Ot = function(a, y, A, N, Z, Q, V) {
459
459
  var U = {
460
460
  // This tag allows us to uniquely identify this as a React Element
461
461
  $$typeof: s,
462
462
  // Built-in properties that belong on the element
463
- type: l,
464
- key: T,
463
+ type: a,
464
+ key: y,
465
465
  ref: A,
466
- props: W,
466
+ props: V,
467
467
  // Record the component responsible for creating this element.
468
468
  _owner: Q
469
469
  };
@@ -484,169 +484,169 @@ function ds() {
484
484
  value: Z
485
485
  }), Object.freeze && (Object.freeze(U.props), Object.freeze(U)), U;
486
486
  };
487
- function Dt(l, T, A, N, Z) {
487
+ function Dt(a, y, A, N, Z) {
488
488
  {
489
- var Q, W = {}, U = null, re = null;
490
- A !== void 0 && (U = "" + A), At(T) && (U = "" + T.key), _t(T) && (re = T.ref, St(T, Z));
491
- for (Q in T)
492
- tn.call(T, Q) && !pt.hasOwnProperty(Q) && (W[Q] = T[Q]);
493
- if (l && l.defaultProps) {
494
- var ne = l.defaultProps;
489
+ var Q, V = {}, U = null, re = null;
490
+ A !== void 0 && (U = "" + A), At(y) && (U = "" + y.key), pt(y) && (re = y.ref, St(y, Z));
491
+ for (Q in y)
492
+ tn.call(y, Q) && !_t.hasOwnProperty(Q) && (V[Q] = y[Q]);
493
+ if (a && a.defaultProps) {
494
+ var ne = a.defaultProps;
495
495
  for (Q in ne)
496
- W[Q] === void 0 && (W[Q] = ne[Q]);
496
+ V[Q] === void 0 && (V[Q] = ne[Q]);
497
497
  }
498
498
  if (U || re) {
499
- var se = typeof l == "function" ? l.displayName || l.name || "Unknown" : l;
500
- U && Lt(W, se), re && Rt(W, se);
499
+ var se = typeof a == "function" ? a.displayName || a.name || "Unknown" : a;
500
+ U && Lt(V, se), re && Rt(V, se);
501
501
  }
502
- return Ot(l, U, re, Z, N, Rn.current, W);
502
+ return Ot(a, U, re, Z, N, Rn.current, V);
503
503
  }
504
504
  }
505
505
  var sn = k.ReactCurrentOwner, Nn = k.ReactDebugCurrentFrame;
506
- function je(l) {
507
- if (l) {
508
- var T = l._owner, A = Ke(l.type, l._source, T ? T.type : null);
506
+ function je(a) {
507
+ if (a) {
508
+ var y = a._owner, A = Ke(a.type, a._source, y ? y.type : null);
509
509
  Nn.setExtraStackFrame(A);
510
510
  } else
511
511
  Nn.setExtraStackFrame(null);
512
512
  }
513
513
  var rn;
514
514
  rn = !1;
515
- function on(l) {
516
- return typeof l == "object" && l !== null && l.$$typeof === s;
515
+ function on(a) {
516
+ return typeof a == "object" && a !== null && a.$$typeof === s;
517
517
  }
518
518
  function Mn() {
519
519
  {
520
520
  if (sn.current) {
521
- var l = $(sn.current.type);
522
- if (l)
521
+ var a = $(sn.current.type);
522
+ if (a)
523
523
  return `
524
524
 
525
- Check the render method of \`` + l + "`.";
525
+ Check the render method of \`` + a + "`.";
526
526
  }
527
527
  return "";
528
528
  }
529
529
  }
530
- function Nt(l) {
530
+ function Nt(a) {
531
531
  return "";
532
532
  }
533
533
  var Fn = {};
534
- function Mt(l) {
534
+ function Mt(a) {
535
535
  {
536
- var T = Mn();
537
- if (!T) {
538
- var A = typeof l == "string" ? l : l.displayName || l.name;
539
- A && (T = `
536
+ var y = Mn();
537
+ if (!y) {
538
+ var A = typeof a == "string" ? a : a.displayName || a.name;
539
+ A && (y = `
540
540
 
541
541
  Check the top-level render call using <` + A + ">.");
542
542
  }
543
- return T;
543
+ return y;
544
544
  }
545
545
  }
546
- function Hn(l, T) {
546
+ function Hn(a, y) {
547
547
  {
548
- if (!l._store || l._store.validated || l.key != null)
548
+ if (!a._store || a._store.validated || a.key != null)
549
549
  return;
550
- l._store.validated = !0;
551
- var A = Mt(T);
550
+ a._store.validated = !0;
551
+ var A = Mt(y);
552
552
  if (Fn[A])
553
553
  return;
554
554
  Fn[A] = !0;
555
555
  var N = "";
556
- l && l._owner && l._owner !== sn.current && (N = " It was passed a child from " + $(l._owner.type) + "."), je(l), S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', A, N), je(null);
556
+ a && a._owner && a._owner !== sn.current && (N = " It was passed a child from " + $(a._owner.type) + "."), je(a), S('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', A, N), je(null);
557
557
  }
558
558
  }
559
- function In(l, T) {
559
+ function In(a, y) {
560
560
  {
561
- if (typeof l != "object")
561
+ if (typeof a != "object")
562
562
  return;
563
- if (Array.isArray(l))
564
- for (var A = 0; A < l.length; A++) {
565
- var N = l[A];
566
- on(N) && Hn(N, T);
563
+ if (Array.isArray(a))
564
+ for (var A = 0; A < a.length; A++) {
565
+ var N = a[A];
566
+ on(N) && Hn(N, y);
567
567
  }
568
- else if (on(l))
569
- l._store && (l._store.validated = !0);
570
- else if (l) {
571
- var Z = m(l);
572
- if (typeof Z == "function" && Z !== l.entries)
573
- for (var Q = Z.call(l), W; !(W = Q.next()).done; )
574
- on(W.value) && Hn(W.value, T);
568
+ else if (on(a))
569
+ a._store && (a._store.validated = !0);
570
+ else if (a) {
571
+ var Z = C(a);
572
+ if (typeof Z == "function" && Z !== a.entries)
573
+ for (var Q = Z.call(a), V; !(V = Q.next()).done; )
574
+ on(V.value) && Hn(V.value, y);
575
575
  }
576
576
  }
577
577
  }
578
- function Ft(l) {
578
+ function Ft(a) {
579
579
  {
580
- var T = l.type;
581
- if (T == null || typeof T == "string")
580
+ var y = a.type;
581
+ if (y == null || typeof y == "string")
582
582
  return;
583
583
  var A;
584
- if (typeof T == "function")
585
- A = T.propTypes;
586
- else if (typeof T == "object" && (T.$$typeof === u || // Note: Memo only checks outer props here.
584
+ if (typeof y == "function")
585
+ A = y.propTypes;
586
+ else if (typeof y == "object" && (y.$$typeof === u || // Note: Memo only checks outer props here.
587
587
  // Inner props are checked in the reconciler.
588
- T.$$typeof === g))
589
- A = T.propTypes;
588
+ y.$$typeof === g))
589
+ A = y.propTypes;
590
590
  else
591
591
  return;
592
592
  if (A) {
593
- var N = $(T);
594
- kt(A, l.props, "prop", N, l);
595
- } else if (T.PropTypes !== void 0 && !rn) {
593
+ var N = $(y);
594
+ kt(A, a.props, "prop", N, a);
595
+ } else if (y.PropTypes !== void 0 && !rn) {
596
596
  rn = !0;
597
- var Z = $(T);
597
+ var Z = $(y);
598
598
  S("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?", Z || "Unknown");
599
599
  }
600
- typeof T.getDefaultProps == "function" && !T.getDefaultProps.isReactClassApproved && S("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
600
+ typeof y.getDefaultProps == "function" && !y.getDefaultProps.isReactClassApproved && S("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.");
601
601
  }
602
602
  }
603
- function Ht(l) {
603
+ function Ht(a) {
604
604
  {
605
- for (var T = Object.keys(l.props), A = 0; A < T.length; A++) {
606
- var N = T[A];
605
+ for (var y = Object.keys(a.props), A = 0; A < y.length; A++) {
606
+ var N = y[A];
607
607
  if (N !== "children" && N !== "key") {
608
- je(l), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", N), je(null);
608
+ je(a), S("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.", N), je(null);
609
609
  break;
610
610
  }
611
611
  }
612
- l.ref !== null && (je(l), S("Invalid attribute `ref` supplied to `React.Fragment`."), je(null));
612
+ a.ref !== null && (je(a), S("Invalid attribute `ref` supplied to `React.Fragment`."), je(null));
613
613
  }
614
614
  }
615
- function $n(l, T, A, N, Z, Q) {
615
+ function $n(a, y, A, N, Z, Q) {
616
616
  {
617
- var W = M(l);
618
- if (!W) {
617
+ var V = M(a);
618
+ if (!V) {
619
619
  var U = "";
620
- (l === void 0 || typeof l == "object" && l !== null && Object.keys(l).length === 0) && (U += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
620
+ (a === void 0 || typeof a == "object" && a !== null && Object.keys(a).length === 0) && (U += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
621
621
  var re = Nt();
622
622
  re ? U += re : U += Mn();
623
623
  var ne;
624
- l === null ? ne = "null" : Array.isArray(l) ? ne = "array" : l !== void 0 && l.$$typeof === s ? (ne = "<" + ($(l.type) || "Unknown") + " />", U = " Did you accidentally export a JSX literal instead of a component?") : ne = typeof l, S("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", ne, U);
624
+ a === null ? ne = "null" : Array.isArray(a) ? ne = "array" : a !== void 0 && a.$$typeof === s ? (ne = "<" + ($(a.type) || "Unknown") + " />", U = " Did you accidentally export a JSX literal instead of a component?") : ne = typeof a, S("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", ne, U);
625
625
  }
626
- var se = Dt(l, T, A, Z, Q);
626
+ var se = Dt(a, y, A, Z, Q);
627
627
  if (se == null)
628
628
  return se;
629
- if (W) {
630
- var xe = T.children;
629
+ if (V) {
630
+ var xe = y.children;
631
631
  if (xe !== void 0)
632
632
  if (N)
633
633
  if (Array.isArray(xe)) {
634
634
  for (var we = 0; we < xe.length; we++)
635
- In(xe[we], l);
635
+ In(xe[we], a);
636
636
  Object.freeze && Object.freeze(xe);
637
637
  } else
638
638
  S("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
639
639
  else
640
- In(xe, l);
640
+ In(xe, a);
641
641
  }
642
- return l === e.Fragment ? Ht(se) : Ft(se), se;
642
+ return a === e.Fragment ? Ht(se) : Ft(se), se;
643
643
  }
644
644
  }
645
- function It(l, T, A) {
646
- return $n(l, T, A, !0);
645
+ function It(a, y, A) {
646
+ return $n(a, y, A, !0);
647
647
  }
648
- function $t(l, T, A) {
649
- return $n(l, T, A, !1);
648
+ function $t(a, y, A) {
649
+ return $n(a, y, A, !1);
650
650
  }
651
651
  var Bt = $t, Ut = It;
652
652
  e.jsx = Bt, e.jsxs = Ut;
@@ -658,7 +658,7 @@ function us() {
658
658
  return Kn || (Kn = 1, process.env.NODE_ENV === "production" ? Je.exports = as() : Je.exports = ds()), Je.exports;
659
659
  }
660
660
  var n = us();
661
- const fs = "2.0.0-alpha.19", tt = "chat_session", xs = "user_uttered", gs = "bot_uttered", Cs = "ehelp_bot_uttered", ms = "https://sfchatbot.dataon.com", bs = [
661
+ const fs = "2.0.0-alpha.20", tt = "chat_session", xs = "user_uttered", gs = "bot_uttered", ms = "ehelp_bot_uttered", Cs = "https://sfchatbot.dataon.com", bs = [
662
662
  {
663
663
  label: "Didn’t address my question",
664
664
  value: "Didn’t address my question"
@@ -703,16 +703,16 @@ const fs = "2.0.0-alpha.19", tt = "chat_session", xs = "user_uttered", gs = "bot
703
703
  ".xcf"
704
704
  ], un = "w-widget-content-container", fn = "w-ticket-detail-content-container", Es = "w-wrapper-body", Ts = "w-wrapper-body-helpdesk", He = "w-header", xn = {
705
705
  FADE_IN: "w-fade-in-animate"
706
- }, ys = "https://placehold.co/600x400?text=No+Image", Ie = 3, js = "GoHRDev2025WorkPlazeDataOnDotCom", _e = "(Helpdesk Widget Chatbot)", ws = (e) => JSON.parse((e == null ? void 0 : e.replaceAll("/get_started", "")) || "{}"), st = (e) => {
706
+ }, ys = "https://placehold.co/600x400?text=No+Image", Ie = 3, js = "GoHRDev2025WorkPlazeDataOnDotCom", pe = "(Helpdesk Widget Chatbot)", ws = (e) => JSON.parse((e == null ? void 0 : e.replaceAll("/get_started", "")) || "{}"), st = (e) => {
707
707
  var t;
708
708
  try {
709
709
  return (t = new URL(e)) == null ? void 0 : t.host;
710
710
  } catch {
711
- return st(ms);
711
+ return st(Cs);
712
712
  }
713
713
  }, le = (e, t) => {
714
- var r, s, a;
715
- return ((r = Object.keys(e || {})) == null ? void 0 : r.length) > 0 ? (a = (s = Object == null ? void 0 : Object.prototype) == null ? void 0 : s.hasOwnProperty) == null ? void 0 : a.call(e, t) : !1;
714
+ var r, s, l;
715
+ return ((r = Object.keys(e || {})) == null ? void 0 : r.length) > 0 ? (l = (s = Object == null ? void 0 : Object.prototype) == null ? void 0 : s.hasOwnProperty) == null ? void 0 : l.call(e, t) : !1;
716
716
  }, Ae = (e) => {
717
717
  var r;
718
718
  const t = e == null ? void 0 : e.attachment;
@@ -724,10 +724,10 @@ const fs = "2.0.0-alpha.19", tt = "chat_session", xs = "user_uttered", gs = "bot
724
724
  chart: (t == null ? void 0 : t.type) === "charts" && le(t, "chartType")
725
725
  };
726
726
  }, rt = (e) => {
727
- var t, r, s, a;
727
+ var t, r, s, l;
728
728
  if (e) {
729
- const c = e == null ? void 0 : e.split(".")[1], o = (t = c == null ? void 0 : c.replace(/-/g, "+")) == null ? void 0 : t.replace(/_/g, "/"), d = decodeURIComponent(
730
- (a = (s = (r = window == null ? void 0 : window.atob(o)) == null ? void 0 : r.split("")) == null ? void 0 : s.map((i) => "%" + ("00" + i.charCodeAt(0).toString(16)).slice(-2))) == null ? void 0 : a.join("")
729
+ const i = e == null ? void 0 : e.split(".")[1], o = (t = i == null ? void 0 : i.replace(/-/g, "+")) == null ? void 0 : t.replace(/_/g, "/"), d = decodeURIComponent(
730
+ (l = (s = (r = window == null ? void 0 : window.atob(o)) == null ? void 0 : r.split("")) == null ? void 0 : s.map((c) => "%" + ("00" + c.charCodeAt(0).toString(16)).slice(-2))) == null ? void 0 : l.join("")
731
731
  );
732
732
  return JSON == null ? void 0 : JSON.parse(d || "{}");
733
733
  }
@@ -737,9 +737,9 @@ const fs = "2.0.0-alpha.19", tt = "chat_session", xs = "user_uttered", gs = "bot
737
737
  fileName: t = "",
738
738
  isOpenNewTab: r = !1
739
739
  }) => {
740
- var a;
740
+ var l;
741
741
  const s = document == null ? void 0 : document.createElement("a");
742
- s.href = e, s.download = t || e, r && (s.target = "_blank"), (a = document == null ? void 0 : document.body) == null || a.appendChild(s), s.click(), document.body.removeChild(s);
742
+ s.href = e, s.download = t || e, r && (s.target = "_blank"), (l = document == null ? void 0 : document.body) == null || l.appendChild(s), s.click(), document.body.removeChild(s);
743
743
  }, ks = () => "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function(e) {
744
744
  const t = crypto.getRandomValues(new Uint8Array(1))[0] % 16;
745
745
  return (e === "x" ? t : t & 3 | 8).toString(16);
@@ -750,28 +750,28 @@ const fs = "2.0.0-alpha.19", tt = "chat_session", xs = "user_uttered", gs = "bot
750
750
  }) => (e == null ? void 0 : e.length) > 0 ? [
751
751
  ...new Map(
752
752
  e.map((s) => {
753
- var a;
753
+ var l;
754
754
  return [
755
- r ? (a = String(s[t])) == null ? void 0 : a.toLowerCase() : s[t],
755
+ r ? (l = String(s[t])) == null ? void 0 : l.toLowerCase() : s[t],
756
756
  s
757
757
  ];
758
758
  })
759
759
  ).values()
760
- ] : [], ps = (e = []) => {
760
+ ] : [], _s = (e = []) => {
761
761
  const t = {}, r = [], s = [];
762
- e == null || e.forEach((c) => {
762
+ e == null || e.forEach((i) => {
763
763
  var o;
764
- le(c, "chats") ? (o = c == null ? void 0 : c.chats) == null || o.forEach((d) => {
764
+ le(i, "chats") ? (o = i == null ? void 0 : i.chats) == null || o.forEach((d) => {
765
765
  s == null || s.push(d);
766
- }) : s == null || s.push(c);
767
- }), s == null || s.forEach((c, o) => {
768
- var i, u, f;
769
- const d = c == null ? void 0 : c.generated_id;
766
+ }) : s == null || s.push(i);
767
+ }), s == null || s.forEach((i, o) => {
768
+ var c, u, f;
769
+ const d = i == null ? void 0 : i.generated_id;
770
770
  d ? (t[d] || (t[d] = []), (u = t[d]) == null || u.push({
771
- ...c,
771
+ ...i,
772
772
  indexChat: o,
773
- ...!(c != null && c.timestamp) && {
774
- timestamp: (i = ae()) == null ? void 0 : i.format("hh:mm A")
773
+ ...!(i != null && i.timestamp) && {
774
+ timestamp: (c = ae()) == null ? void 0 : c.format("hh:mm A")
775
775
  }
776
776
  }), r == null || r.push({
777
777
  keyItem: d ?? o,
@@ -782,17 +782,17 @@ const fs = "2.0.0-alpha.19", tt = "chat_session", xs = "user_uttered", gs = "bot
782
782
  },
783
783
  chats: t == null ? void 0 : t[d]
784
784
  })) : r == null || r.push({
785
- ...c,
785
+ ...i,
786
786
  keyItem: o,
787
- ...!(c != null && c.timestamp) && {
787
+ ...!(i != null && i.timestamp) && {
788
788
  timestamp: (f = ae()) == null ? void 0 : f.format("hh:mm A")
789
789
  }
790
790
  });
791
791
  });
792
- const a = yn({ ArrObj: r, key: "keyItem" });
793
- return a == null || a.forEach((c) => {
794
- c == null || delete c.keyItem;
795
- }), a;
792
+ const l = yn({ ArrObj: r, key: "keyItem" });
793
+ return l == null || l.forEach((i) => {
794
+ i == null || delete i.keyItem;
795
+ }), l;
796
796
  }, Pe = (e = {}) => {
797
797
  const r = {
798
798
  ...ot(),
@@ -802,7 +802,7 @@ const fs = "2.0.0-alpha.19", tt = "chat_session", xs = "user_uttered", gs = "bot
802
802
  }, ot = () => {
803
803
  const e = localStorage == null ? void 0 : localStorage.getItem(tt);
804
804
  return JSON.parse(e || "{}");
805
- }, _s = (e = "") => {
805
+ }, ps = (e = "") => {
806
806
  var t;
807
807
  try {
808
808
  const r = new URL(e);
@@ -812,7 +812,7 @@ const fs = "2.0.0-alpha.19", tt = "chat_session", xs = "user_uttered", gs = "bot
812
812
  }
813
813
  };
814
814
  let Jn = null;
815
- const me = (e = ".w-wrapper-body") => {
815
+ const Ce = (e = ".w-wrapper-body") => {
816
816
  const t = document.querySelector(e);
817
817
  clearTimeout(Jn), Jn = setTimeout(() => {
818
818
  t && t.scrollTo({
@@ -827,34 +827,34 @@ const me = (e = ".w-wrapper-body") => {
827
827
  r += String.fromCharCode(t[s]);
828
828
  return btoa(r);
829
829
  }, Ss = async (e, t) => {
830
- var i;
831
- const r = typeof e == "object" ? JSON == null ? void 0 : JSON.stringify(e || {}) : e, s = new TextEncoder(), a = s == null ? void 0 : s.encode(r), c = s == null ? void 0 : s.encode(t);
832
- if (c.length !== 32)
830
+ var c;
831
+ const r = typeof e == "object" ? JSON == null ? void 0 : JSON.stringify(e || {}) : e, s = new TextEncoder(), l = s == null ? void 0 : s.encode(r), i = s == null ? void 0 : s.encode(t);
832
+ if (i.length !== 32)
833
833
  throw new Error("Key length must be 32 bytes for AES-256");
834
- const o = await ((i = crypto == null ? void 0 : crypto.subtle) == null ? void 0 : i.importKey(
834
+ const o = await ((c = crypto == null ? void 0 : crypto.subtle) == null ? void 0 : c.importKey(
835
835
  "raw",
836
- c,
836
+ i,
837
837
  { name: "AES-CBC" },
838
838
  !1,
839
839
  ["encrypt"]
840
840
  )), d = await crypto.subtle.encrypt(
841
841
  { name: "AES-CBC", iv: new Uint8Array(16) },
842
842
  o,
843
- a
843
+ l
844
844
  );
845
845
  return As(d);
846
846
  }, Qe = (e) => {
847
- const t = {}, r = ct(e), s = r == null ? void 0 : r.map((a) => {
847
+ const t = {}, r = ct(e), s = r == null ? void 0 : r.map((l) => {
848
848
  var o;
849
- const c = a == null ? void 0 : a.CREATED_DATE;
849
+ const i = l == null ? void 0 : l.CREATED_DATE;
850
850
  return {
851
- ...a,
852
- DATE_KEY: (o = ae(c)) == null ? void 0 : o.format("YYYY-MM-DD")
851
+ ...l,
852
+ DATE_KEY: (o = ae(i)) == null ? void 0 : o.format("YYYY-MM-DD")
853
853
  };
854
854
  });
855
- return s == null || s.forEach((a) => {
856
- var c;
857
- t[a == null ? void 0 : a.DATE_KEY] || (t[a == null ? void 0 : a.DATE_KEY] = []), (c = t[a == null ? void 0 : a.DATE_KEY]) == null || c.push(a);
855
+ return s == null || s.forEach((l) => {
856
+ var i;
857
+ t[l == null ? void 0 : l.DATE_KEY] || (t[l == null ? void 0 : l.DATE_KEY] = []), (i = t[l == null ? void 0 : l.DATE_KEY]) == null || i.push(l);
858
858
  }), t;
859
859
  }, jn = (e) => {
860
860
  var t;
@@ -876,36 +876,39 @@ const me = (e = ".w-wrapper-body") => {
876
876
  getStartedPayload: t,
877
877
  socketURL: r,
878
878
  socketPath: s,
879
- onPayslipFn: a,
880
- title: c,
879
+ onPayslipFn: l,
880
+ title: i,
881
881
  subTitle: o,
882
882
  keyEncrypt: d,
883
- history: i,
884
- isSF: u
883
+ history: c,
884
+ modelName: u,
885
+ isSF: f
885
886
  }) => {
886
- const [f, x] = D(!1), [g, C] = D("va"), [y, j] = D(!1), [p, w] = D({}), [v, h] = D(!1), [b, E] = D(!1), m = K(!1), k = O(() => ({
887
+ const [x, g] = D(!1), [m, T] = D("va"), [w, p] = D(!1), [j, v] = D({}), [h, b] = D(!1), [E, C] = D(!1), k = K(!1), S = R(() => ({
887
888
  getStartedPayload: t,
888
889
  socketURL: r,
889
890
  socketPath: s,
890
- onPayslipFn: a,
891
- title: c,
891
+ onPayslipFn: l,
892
+ title: i,
892
893
  subTitle: o,
893
894
  keyEncrypt: d,
894
- history: i,
895
- isSF: u
895
+ history: c,
896
+ modelName: u,
897
+ isSF: f
896
898
  }), [
897
899
  t,
898
900
  r,
899
901
  s,
900
- a,
901
- c,
902
+ l,
903
+ i,
902
904
  o,
903
905
  d,
904
- i,
905
- u
906
- ]), S = O(() => rt(p == null ? void 0 : p.access_token), [p == null ? void 0 : p.access_token]);
906
+ c,
907
+ u,
908
+ f
909
+ ]), F = R(() => rt(j == null ? void 0 : j.access_token), [j == null ? void 0 : j.access_token]);
907
910
  return X(() => {
908
- w(ws(t));
911
+ v(ws(t));
909
912
  }, [t]), X(() => {
910
913
  Pe({
911
914
  chatbot_version: vs
@@ -914,155 +917,159 @@ const me = (e = ".w-wrapper-body") => {
914
917
  lt.Provider,
915
918
  {
916
919
  value: {
917
- objInitPayload: p,
918
- setOpenWidget: x,
919
- isOpenWidget: f,
920
- activeTab: g,
921
- setActiveTab: C,
922
- isExpand: y,
923
- setExpand: j,
924
- setObjInitPayload: w,
925
- parsedJWT: S,
926
- widgetProps: k,
927
- isFirstOpenWidget: v,
928
- setFirstOpenWidget: h,
929
- isFirstRenderHelpdesk: m,
930
- showReadyWSHD: b,
931
- setShowReadyWSHD: E
920
+ objInitPayload: j,
921
+ setOpenWidget: g,
922
+ isOpenWidget: x,
923
+ activeTab: m,
924
+ setActiveTab: T,
925
+ isExpand: w,
926
+ setExpand: p,
927
+ setObjInitPayload: v,
928
+ parsedJWT: F,
929
+ widgetProps: S,
930
+ isFirstOpenWidget: h,
931
+ setFirstOpenWidget: b,
932
+ isFirstRenderHelpdesk: k,
933
+ showReadyWSHD: E,
934
+ setShowReadyWSHD: C
932
935
  },
933
936
  children: e
934
937
  }
935
938
  );
936
939
  }, at = Te({}), Rs = () => ye(at), Os = ({ children: e }) => {
937
- const { objInitPayload: t } = q(), [r, s] = D({}), a = () => {
940
+ const { objInitPayload: t } = q(), [r, s] = D({}), l = () => {
938
941
  var o;
939
942
  (o = Oe(
940
943
  `${(t == null ? void 0 : t.uriService) || hs}optional/translations`
941
944
  )) == null || o.then(({ data: d }) => {
942
- var i;
945
+ var c;
943
946
  if (d) {
944
- const u = Object.keys((i = Object.values(d)) == null ? void 0 : i[0]), f = {};
947
+ const u = Object.keys((c = Object.values(d)) == null ? void 0 : c[0]), f = {};
945
948
  u == null || u.forEach((x) => {
946
949
  var g;
947
- (g = Object.keys(d)) == null || g.forEach((C) => {
948
- var y;
949
- f[x == null ? void 0 : x.toLowerCase()] = (y = d == null ? void 0 : d[C]) == null ? void 0 : y[x];
950
+ (g = Object.keys(d)) == null || g.forEach((m) => {
951
+ var T;
952
+ f[x == null ? void 0 : x.toLowerCase()] = (T = d == null ? void 0 : d[m]) == null ? void 0 : T[x];
950
953
  });
951
954
  }), s(f);
952
955
  }
953
956
  });
954
- }, c = () => {
957
+ }, i = () => {
955
958
  const o = window.indexedDB.open("language");
956
959
  o.onsuccess = (d) => {
957
960
  var u;
958
- const i = d.target.result;
961
+ const c = d.target.result;
959
962
  try {
960
- const x = i.transaction("keyvaluepairs", "readonly").objectStore("keyvaluepairs"), g = x == null ? void 0 : x.get((u = t == null ? void 0 : t.lang) == null ? void 0 : u.toLowerCase());
963
+ const x = c.transaction("keyvaluepairs", "readonly").objectStore("keyvaluepairs"), g = x == null ? void 0 : x.get((u = t == null ? void 0 : t.lang) == null ? void 0 : u.toLowerCase());
961
964
  g.onsuccess = () => {
962
965
  s(g == null ? void 0 : g.result);
963
966
  }, g.onerror = () => {
964
- a();
967
+ l();
965
968
  };
966
969
  } catch {
967
- a();
970
+ l();
968
971
  }
969
972
  }, o.onerror = () => {
970
- a();
973
+ l();
971
974
  };
972
975
  };
973
976
  return X(() => {
974
- c();
977
+ i();
975
978
  }, [t == null ? void 0 : t.uriService, t == null ? void 0 : t.lang]), /* @__PURE__ */ n.jsx(at.Provider, { value: { langDatas: r }, children: e });
976
979
  }, dt = Te({}), fe = () => ye(dt), Ds = ({ children: e }) => {
977
980
  var M;
978
- const [t, r] = D([]), [s, a] = D(!1), [c, o] = D(!1), [d, i] = D({}), [u, f] = D(!1), [x, g] = D(!1), {
979
- objInitPayload: C,
980
- widgetProps: y,
981
- setOpenWidget: j,
981
+ const [t, r] = D([]), [s, l] = D(!1), [i, o] = D(!1), [d, c] = D({}), [u, f] = D(!1), [x, g] = D(!1), {
982
+ objInitPayload: m,
983
+ widgetProps: T,
984
+ setOpenWidget: w,
982
985
  setFirstOpenWidget: p,
983
- isFirstRenderHelpdesk: w
986
+ isFirstRenderHelpdesk: j
984
987
  } = q(), v = K(null), h = K(""), b = K(""), E = (L) => {
985
988
  var $;
986
989
  if (!(($ = L == null ? void 0 : L.metadata) == null ? void 0 : $.stopped)) {
987
- const F = le(L, "text_feedback_link") && le(L, "text");
988
- r((G) => {
989
- const J = [
990
- ...G,
990
+ const I = le(L, "text_feedback_link") && le(L, "text");
991
+ r((J) => {
992
+ const z = [
993
+ ...J,
991
994
  {
992
995
  ...L,
993
- ...F && {
996
+ ...I && {
994
997
  type: "text"
995
998
  },
996
999
  sender: "response"
997
1000
  }
998
1001
  ];
999
- return ps(J);
1002
+ return _s(z);
1000
1003
  });
1001
1004
  }
1002
- a(!1), o(!1), me();
1003
- }, m = () => {
1004
- var L, I, $, F;
1005
- (L = v == null ? void 0 : v.current) == null || L.emit("session_request", { session_id: null }), (I = v == null ? void 0 : v.current) == null || I.on("session_confirm", (G) => {
1006
- h.current = G, Pe({
1007
- session_id: G == null ? void 0 : G.session_id
1005
+ l(!1), o(!1), Ce();
1006
+ }, C = (L) => {
1007
+ var H, $, I, J;
1008
+ L && k({
1009
+ msg: T == null ? void 0 : T.getStartedPayload
1010
+ }), (H = v == null ? void 0 : v.current) == null || H.emit("session_request", { session_id: null }), ($ = v == null ? void 0 : v.current) == null || $.on("session_confirm", (z) => {
1011
+ h.current = z, Pe({
1012
+ session_id: z == null ? void 0 : z.session_id
1008
1013
  });
1009
- }), ($ = v == null ? void 0 : v.current) == null || $.on(gs, E), (F = v == null ? void 0 : v.current) == null || F.on(Cs, (G) => {
1010
- const J = JSON.parse(G || "{}");
1011
- le(J, "iswidget") && g(J == null ? void 0 : J.iswidget);
1014
+ }), (I = v == null ? void 0 : v.current) == null || I.on(gs, E), (J = v == null ? void 0 : v.current) == null || J.on(ms, (z) => {
1015
+ const W = JSON.parse(z || "{}");
1016
+ le(W, "iswidget") && g(W == null ? void 0 : W.iswidget);
1012
1017
  }), u || f(!0), p(!1);
1013
1018
  }, k = ({
1014
1019
  msg: L,
1015
- additionalConfig: I = {},
1020
+ additionalConfig: H = {},
1016
1021
  isShowLoadingResponse: $ = !0
1017
1022
  }) => {
1018
- var F;
1019
- (F = v == null ? void 0 : v.current) == null || F.emit(xs, {
1023
+ var I;
1024
+ (I = v == null ? void 0 : v.current) == null || I.emit(xs, {
1020
1025
  customData: {
1021
- language: C == null ? void 0 : C.lang
1026
+ language: m == null ? void 0 : m.lang
1022
1027
  },
1023
1028
  message: L,
1024
1029
  session_id: h == null ? void 0 : h.current,
1025
- ...I
1026
- }), $ ? a(!0) : o(!0);
1027
- }, S = () => {
1028
- var I, $;
1029
- v.current && ((I = v == null ? void 0 : v.current) == null || I.off(), ($ = v == null ? void 0 : v.current) == null || $.disconnect(), v.current = null), w.current = !1;
1030
- const L = ts(
1031
- `${_s(y == null ? void 0 : y.socketURL)}://${st(
1032
- y == null ? void 0 : y.socketURL
1030
+ ...H
1031
+ }), $ ? l(!0) : o(!0);
1032
+ }, S = (L = !1) => {
1033
+ var $, I;
1034
+ v.current && (($ = v == null ? void 0 : v.current) == null || $.off(), (I = v == null ? void 0 : v.current) == null || I.disconnect(), v.current = null), j.current = !1;
1035
+ const H = ts(
1036
+ `${ps(T == null ? void 0 : T.socketURL)}://${st(
1037
+ T == null ? void 0 : T.socketURL
1033
1038
  )}`,
1034
1039
  {
1035
- path: y == null ? void 0 : y.socketPath,
1040
+ path: T == null ? void 0 : T.socketPath,
1036
1041
  transports: ["websocket"],
1037
1042
  reconnection: !0,
1038
1043
  reconnectionAttempts: 1
1039
1044
  }
1040
1045
  );
1041
- L.on("connect", m), L.on("connect_error", (F) => {
1046
+ H.on("connect", () => {
1047
+ C(L);
1048
+ }), H.on("connect_error", (J) => {
1042
1049
  console.error("connect_error widget-chatbot : ", {
1043
- err: F,
1044
- socketURL: y == null ? void 0 : y.socketURL,
1045
- socketPath: y == null ? void 0 : y.widgetProps
1050
+ err: J,
1051
+ socketURL: T == null ? void 0 : T.socketURL,
1052
+ socketPath: T == null ? void 0 : T.widgetProps
1046
1053
  }), f(!1);
1047
- }), L.io.on("reconnect", () => {
1054
+ }), H.io.on("reconnect", () => {
1048
1055
  console.error("reconnect widget-chatbot : ", {
1049
- socketURL: y == null ? void 0 : y.socketURL,
1050
- socketPath: y == null ? void 0 : y.widgetProps
1056
+ socketURL: T == null ? void 0 : T.socketURL,
1057
+ socketPath: T == null ? void 0 : T.widgetProps
1051
1058
  }), f(!1);
1052
- }), v.current = L;
1053
- }, H = () => {
1059
+ }), v.current = H;
1060
+ }, F = () => {
1054
1061
  var L;
1055
- (!((L = v == null ? void 0 : v.current) != null && L.connected) || !u) && (S(), j(!1));
1062
+ (!((L = v == null ? void 0 : v.current) != null && L.connected) || !u) && (S(), w(!1));
1056
1063
  }, B = () => {
1057
1064
  f(!1);
1058
1065
  };
1059
- return X(() => (j(!1), S(), window.addEventListener("online", H), window.addEventListener("offline", B), () => {
1060
- var L, I;
1061
- v.current && ((L = v.current) == null || L.off("connect", m), (I = v.current) == null || I.disconnect(), v.current = null), window.removeEventListener("online", H), window.removeEventListener("offline", B);
1066
+ return X(() => (w(!1), S(), window.addEventListener("online", F), window.addEventListener("offline", B), () => {
1067
+ var L, H;
1068
+ v.current && ((L = v.current) == null || L.off("connect", C), (H = v.current) == null || H.disconnect(), v.current = null), window.removeEventListener("online", F), window.removeEventListener("offline", B);
1062
1069
  }), [
1063
- JSON.stringify(C || {}),
1064
- y == null ? void 0 : y.socketURL,
1065
- y == null ? void 0 : y.socketPath
1070
+ JSON.stringify(m || {}),
1071
+ T == null ? void 0 : T.socketURL,
1072
+ T == null ? void 0 : T.socketPath
1066
1073
  ]), /* @__PURE__ */ n.jsx(
1067
1074
  dt.Provider,
1068
1075
  {
@@ -1073,9 +1080,9 @@ const me = (e = ".w-wrapper-body") => {
1073
1080
  isWaitResponse: s,
1074
1081
  socket: v == null ? void 0 : v.current,
1075
1082
  sessionId: (M = h == null ? void 0 : h.current) == null ? void 0 : M.session_id,
1076
- loadingRegenerate: c,
1083
+ loadingRegenerate: i,
1077
1084
  file: d,
1078
- setFile: i,
1085
+ setFile: c,
1079
1086
  connected: u,
1080
1087
  isHandshakeWidget: x,
1081
1088
  createSocket: S,
@@ -1367,11 +1374,11 @@ const me = (e = ".w-wrapper-body") => {
1367
1374
  }
1368
1375
  }, Ms = (e) => e.replace(/[^a-zA-Z0-9_]/g, "").trim(), _ = (e = "", t) => {
1369
1376
  var o;
1370
- const { langDatas: r } = Rs(), s = localStorage == null ? void 0 : localStorage.getItem("show_text_id"), a = Ms(String(e)), c = (r == null ? void 0 : r[a == null ? void 0 : a.toUpperCase()]) || t;
1371
- return ((o = Object.keys(r || {})) == null ? void 0 : o.length) > 0 ? s ? `WPUI_${a}` : c : t;
1377
+ const { langDatas: r } = Rs(), s = localStorage == null ? void 0 : localStorage.getItem("show_text_id"), l = Ms(String(e)), i = (r == null ? void 0 : r[l == null ? void 0 : l.toUpperCase()]) || t;
1378
+ return ((o = Object.keys(r || {})) == null ? void 0 : o.length) > 0 ? s ? `WPUI_${l}` : i : t;
1372
1379
  }, Fs = ({ isFeedback: e = !1, open: t, ...r }) => {
1373
- var a;
1374
- const s = O(() => e ? "w-modal-container-feedback" : "", [e]);
1380
+ var l;
1381
+ const s = R(() => e ? "w-modal-container-feedback" : "", [e]);
1375
1382
  return Le != null && Le.startsWith("5") ? /* @__PURE__ */ n.jsx(
1376
1383
  Un,
1377
1384
  {
@@ -1405,7 +1412,7 @@ const me = (e = ".w-wrapper-body") => {
1405
1412
  } : { visible: t },
1406
1413
  maskStyle: {
1407
1414
  backdropFilter: "blur(4x)",
1408
- ...((a = Object.keys((r == null ? void 0 : r.maskStyle) || {})) == null ? void 0 : a.length) > 0 && {
1415
+ ...((l = Object.keys((r == null ? void 0 : r.maskStyle) || {})) == null ? void 0 : l.length) > 0 && {
1409
1416
  ...r == null ? void 0 : r.maskStyle
1410
1417
  }
1411
1418
  },
@@ -1418,11 +1425,11 @@ const me = (e = ".w-wrapper-body") => {
1418
1425
  }
1419
1426
  )
1420
1427
  );
1421
- }, ut = R(Fs), Zn = ({ props: e, isModal: t = !1 }) => {
1422
- const r = (s, a) => {
1423
- var c;
1424
- return (c = Vt) == null ? void 0 : c.map(s, (o) => {
1425
- var d, i, u;
1428
+ }, ut = O(Fs), Zn = ({ props: e, isModal: t = !1 }) => {
1429
+ const r = (s, l) => {
1430
+ var i;
1431
+ return (i = Vt) == null ? void 0 : i.map(s, (o) => {
1432
+ var d, c, u;
1426
1433
  return !Gt(o) || ((d = Object.keys((o == null ? void 0 : o.props) || {})) == null ? void 0 : d.length) === 0 ? o : zt(o, {
1427
1434
  ...o == null ? void 0 : o.props,
1428
1435
  ...(o == null ? void 0 : o.type) === "thead" && {
@@ -1438,13 +1445,13 @@ const me = (e = ".w-wrapper-body") => {
1438
1445
  }
1439
1446
  }
1440
1447
  },
1441
- ...o.type === "tr" && a === "tbody" && {
1448
+ ...o.type === "tr" && l === "tbody" && {
1442
1449
  className: "ant-table-row"
1443
1450
  },
1444
1451
  ...(o == null ? void 0 : o.type) === "tbody" && {
1445
1452
  className: "ant-table-tbody"
1446
1453
  },
1447
- children: (i = o == null ? void 0 : o.props) != null && i.children ? r((u = o == null ? void 0 : o.props) == null ? void 0 : u.children, o == null ? void 0 : o.type) : o == null ? void 0 : o.props
1454
+ children: (c = o == null ? void 0 : o.props) != null && c.children ? r((u = o == null ? void 0 : o.props) == null ? void 0 : u.children, o == null ? void 0 : o.type) : o == null ? void 0 : o.props
1448
1455
  });
1449
1456
  });
1450
1457
  };
@@ -1464,9 +1471,9 @@ const me = (e = ".w-wrapper-body") => {
1464
1471
  const t = _(
1465
1472
  "OpenDetailTable",
1466
1473
  "Open Detail Table"
1467
- ), r = _("TableDetail", "Tabel Detail"), { widgetProps: s, objInitPayload: a } = q(), [c, o] = D(!1), d = {
1468
- table: ({ ...i }) => /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
1469
- /* @__PURE__ */ n.jsx(Zn, { props: i }),
1474
+ ), r = _("TableDetail", "Tabel Detail"), { widgetProps: s, objInitPayload: l } = q(), [i, o] = D(!1), d = {
1475
+ table: ({ ...c }) => /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
1476
+ /* @__PURE__ */ n.jsx(Zn, { props: c }),
1470
1477
  /* @__PURE__ */ n.jsx(
1471
1478
  "div",
1472
1479
  {
@@ -1476,7 +1483,7 @@ const me = (e = ".w-wrapper-body") => {
1476
1483
  padding: "5px 0px 10px 0px"
1477
1484
  },
1478
1485
  children: /* @__PURE__ */ n.jsx(
1479
- z,
1486
+ Y,
1480
1487
  {
1481
1488
  onClick: () => {
1482
1489
  o(!0);
@@ -1493,16 +1500,16 @@ const me = (e = ".w-wrapper-body") => {
1493
1500
  footer: null,
1494
1501
  title: r,
1495
1502
  width: 800,
1496
- open: c,
1503
+ open: i,
1497
1504
  onCancel: () => {
1498
1505
  o(!1);
1499
1506
  },
1500
- children: /* @__PURE__ */ n.jsx(Zn, { props: i, isModal: !0 })
1507
+ children: /* @__PURE__ */ n.jsx(Zn, { props: c, isModal: !0 })
1501
1508
  }
1502
1509
  )
1503
1510
  ] }),
1504
- code: ({ ...i }) => {
1505
- const { children: u, className: f, ...x } = i, g = /language-(\w+)/.exec(f || "");
1511
+ code: ({ ...c }) => {
1512
+ const { children: u, className: f, ...x } = c, g = /language-(\w+)/.exec(f || "");
1506
1513
  return g ? /* @__PURE__ */ n.jsx(
1507
1514
  os,
1508
1515
  {
@@ -1512,34 +1519,34 @@ const me = (e = ".w-wrapper-body") => {
1512
1519
  style: Ns,
1513
1520
  children: String(u).replace(/\n$/, "")
1514
1521
  }
1515
- ) : /* @__PURE__ */ n.jsx(V.Text, { code: !0, children: i == null ? void 0 : i.children });
1522
+ ) : /* @__PURE__ */ n.jsx(G.Text, { code: !0, children: c == null ? void 0 : c.children });
1516
1523
  },
1517
- a: ({ ...i }) => {
1518
- var C, y, j, p;
1519
- const u = i == null ? void 0 : i.href, f = (C = i == null ? void 0 : i.children) == null ? void 0 : C[0], x = Qn(u), g = Qn(a == null ? void 0 : a.uriBackend);
1524
+ a: ({ ...c }) => {
1525
+ var m, T, w, p;
1526
+ const u = c == null ? void 0 : c.href, f = (m = c == null ? void 0 : c.children) == null ? void 0 : m[0], x = Qn(u), g = Qn(l == null ? void 0 : l.uriBackend);
1520
1527
  if (x && g) {
1521
- const w = (y = gn(u)) == null ? void 0 : y.origin, v = (j = gn(a == null ? void 0 : a.uriBackend)) == null ? void 0 : j.origin;
1522
- if ((w == null ? void 0 : w.toLowerCase()) === (v == null ? void 0 : v.toLowerCase())) {
1528
+ const j = (T = gn(u)) == null ? void 0 : T.origin, v = (w = gn(l == null ? void 0 : l.uriBackend)) == null ? void 0 : w.origin;
1529
+ if ((j == null ? void 0 : j.toLowerCase()) === (v == null ? void 0 : v.toLowerCase())) {
1523
1530
  const h = (p = gn(u)) == null ? void 0 : p.pathname;
1524
1531
  return /* @__PURE__ */ n.jsx(
1525
1532
  "span",
1526
1533
  {
1527
- ...i,
1534
+ ...c,
1528
1535
  className: "w-link-path",
1529
1536
  onClick: (b) => {
1530
- var E, m;
1531
- b == null || b.stopPropagation(), h && ((E = Object.keys((s == null ? void 0 : s.history) || {})) == null ? void 0 : E.length) > 0 && ((m = s == null ? void 0 : s.history) == null || m.push(h));
1537
+ var E, C;
1538
+ b == null || b.stopPropagation(), h && ((E = Object.keys((s == null ? void 0 : s.history) || {})) == null ? void 0 : E.length) > 0 && ((C = s == null ? void 0 : s.history) == null || C.push(h));
1532
1539
  },
1533
1540
  children: f
1534
1541
  }
1535
1542
  );
1536
1543
  }
1537
1544
  }
1538
- return /* @__PURE__ */ n.jsx("a", { ...i, target: "_blank", className: "w-link-path" });
1545
+ return /* @__PURE__ */ n.jsx("a", { ...c, target: "_blank", className: "w-link-path" });
1539
1546
  }
1540
1547
  };
1541
1548
  return /* @__PURE__ */ n.jsx(ss, { remarkPlugins: [rs], components: d, children: e });
1542
- }, ft = R(Hs), Is = () => /* @__PURE__ */ n.jsx(
1549
+ }, ft = O(Hs), Is = () => /* @__PURE__ */ n.jsx(
1543
1550
  "svg",
1544
1551
  {
1545
1552
  width: "24",
@@ -1830,7 +1837,7 @@ const me = (e = ".w-wrapper-body") => {
1830
1837
  children: /* @__PURE__ */ n.jsx("path", { d: "M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z" })
1831
1838
  }
1832
1839
  ) }), P = ({ type: e = "", chatProps: t, ...r }) => {
1833
- const s = O(() => ({
1840
+ const s = R(() => ({
1834
1841
  minimize: Is,
1835
1842
  expand: $s,
1836
1843
  send: Bs,
@@ -1853,7 +1860,7 @@ const me = (e = ".w-wrapper-body") => {
1853
1860
  }), [e, t, r]);
1854
1861
  return /* @__PURE__ */ n.jsx(cs, { component: s == null ? void 0 : s[e], ...r });
1855
1862
  }, xt = Te({}), be = () => ye(xt), sr = ({ children: e }) => {
1856
- const [t, r] = D("va"), s = O(() => t === "va", [t]);
1863
+ const [t, r] = D("va"), s = R(() => t === "va", [t]);
1857
1864
  return /* @__PURE__ */ n.jsx(
1858
1865
  xt.Provider,
1859
1866
  {
@@ -1872,21 +1879,21 @@ const me = (e = ".w-wrapper-body") => {
1872
1879
  ), r = _(
1873
1880
  "ShareAnyCommentsOrSuggestionsToHelpUsImprove",
1874
1881
  "Share any comments or suggestions to help us improve"
1875
- ), s = _("Submit", "Submit"), a = _(
1882
+ ), s = _("Submit", "Submit"), l = _(
1876
1883
  "ThankFeedback",
1877
1884
  "Thank You for your feedback"
1878
- ), c = _(
1885
+ ), i = _(
1879
1886
  "AdditionalFeedback",
1880
1887
  "Additional Feedback"
1881
- ), [o] = oe.useForm(), [d, i] = D(!1), [u, f] = D(""), { setChats: x } = fe(), { objInitPayload: g } = q(), { activeTab: C } = be(), y = O(() => {
1888
+ ), [o] = oe.useForm(), [d, c] = D(!1), [u, f] = D(""), { setChats: x } = fe(), { objInitPayload: g } = q(), { activeTab: m } = be(), T = R(() => {
1882
1889
  var h;
1883
1890
  const v = le(e, "feedback") ? (e == null ? void 0 : e.feedback) === "like" || (e == null ? void 0 : e.feedback) === "" : !0;
1884
1891
  return typeof (e == null ? void 0 : e.text_thumbsup_link) == "string" && ((h = e == null ? void 0 : e.text_thumbsup_link) == null ? void 0 : h.trim()) !== "" && v;
1885
- }, [e]), j = O(() => {
1892
+ }, [e]), w = R(() => {
1886
1893
  var h;
1887
1894
  const v = le(e, "feedback") ? (e == null ? void 0 : e.feedback) === "dislike" || (e == null ? void 0 : e.feedback) === "" : !0;
1888
1895
  return typeof (e == null ? void 0 : e.text_thumbsdown_link) == "string" && ((h = e == null ? void 0 : e.text_thumbsdown_link) == null ? void 0 : h.trim()) !== "" && v;
1889
- }, [e]), p = O(() => {
1896
+ }, [e]), p = R(() => {
1890
1897
  if (g != null && g.uriBackend)
1891
1898
  try {
1892
1899
  return new URL(g.uriBackend).origin;
@@ -1894,15 +1901,15 @@ const me = (e = ".w-wrapper-body") => {
1894
1901
  return "";
1895
1902
  }
1896
1903
  return "";
1897
- }, [g == null ? void 0 : g.uriBackend]), w = (v) => {
1904
+ }, [g == null ? void 0 : g.uriBackend]), j = (v) => {
1898
1905
  var M;
1899
1906
  const h = v === "like" ? e == null ? void 0 : e.text_thumbsup_link : e == null ? void 0 : e.text_thumbsdown_link, {
1900
1907
  access_token: b = "",
1901
1908
  companycode: E = "",
1902
- companyid: m = "",
1909
+ companyid: C = "",
1903
1910
  uriBackend: k = "",
1904
1911
  uriBackendEnt: S = "",
1905
- lang: H = ""
1912
+ lang: F = ""
1906
1913
  } = g || {}, B = u === "another" ? o == null ? void 0 : o.getFieldValue("ADDITIONAL_FEEDBACK") : u;
1907
1914
  (M = Oe({
1908
1915
  method: "POST",
@@ -1918,64 +1925,64 @@ const me = (e = ".w-wrapper-body") => {
1918
1925
  "Content-Type": "application/json",
1919
1926
  Authorization: `Bearer ${b}`,
1920
1927
  "company-code": `${E}`,
1921
- "company-id": `${m}`,
1928
+ "company-id": `${C}`,
1922
1929
  uriBackend: `${k}`,
1923
1930
  uriBackendEnt: `${S}`,
1924
1931
  "custom-origin": `${p}`,
1925
1932
  "Acc-Name": `${E.toUpperCase()}`,
1926
- Language: `${H}`
1933
+ Language: `${F}`
1927
1934
  }
1928
1935
  })) == null || M.then((L) => {
1929
- var I, $, F;
1930
- (L == null ? void 0 : L.status) === 200 && (d && i(!1), (I = ie) == null || I.destroy(), ($ = ie) == null || $.config({
1936
+ var H, $, I;
1937
+ (L == null ? void 0 : L.status) === 200 && (d && c(!1), (H = ie) == null || H.destroy(), ($ = ie) == null || $.config({
1931
1938
  getContainer: () => document.querySelector(".w-widget-content-container"),
1932
1939
  top: 28,
1933
1940
  placement: "top",
1934
1941
  duration: 3
1935
- }), (F = ie) == null || F.success({
1936
- message: a,
1942
+ }), (I = ie) == null || I.success({
1943
+ message: l,
1937
1944
  className: "w-notification-content"
1938
- }), x((G) => {
1939
- var J;
1940
- return (J = G == null ? void 0 : G.map((Y) => {
1945
+ }), x((J) => {
1946
+ var z;
1947
+ return (z = J == null ? void 0 : J.map((W) => {
1941
1948
  var ee;
1942
- if (le(Y, "chats")) {
1943
- const de = (ee = Y == null ? void 0 : Y.chats) == null ? void 0 : ee.map((ce) => (ce == null ? void 0 : ce.indexChat) === (e == null ? void 0 : e.indexChat) ? {
1949
+ if (le(W, "chats")) {
1950
+ const de = (ee = W == null ? void 0 : W.chats) == null ? void 0 : ee.map((ce) => (ce == null ? void 0 : ce.indexChat) === (e == null ? void 0 : e.indexChat) ? {
1944
1951
  ...ce,
1945
1952
  feedback: v
1946
1953
  } : ce);
1947
1954
  return {
1948
- ...Y,
1955
+ ...W,
1949
1956
  chats: de
1950
1957
  };
1951
1958
  }
1952
- return (e == null ? void 0 : e.message_id) === (Y == null ? void 0 : Y.message_id) ? {
1953
- ...Y,
1959
+ return (e == null ? void 0 : e.message_id) === (W == null ? void 0 : W.message_id) ? {
1960
+ ...W,
1954
1961
  feedback: v
1955
- } : Y;
1956
- })) == null ? void 0 : J.flat();
1962
+ } : W;
1963
+ })) == null ? void 0 : z.flat();
1957
1964
  }));
1958
1965
  });
1959
1966
  };
1960
1967
  return X(() => {
1961
1968
  var v;
1962
1969
  (v = ie) == null || v.destroy();
1963
- }, [C]), /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
1964
- y && /* @__PURE__ */ n.jsx(
1965
- z,
1970
+ }, [m]), /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
1971
+ T && /* @__PURE__ */ n.jsx(
1972
+ Y,
1966
1973
  {
1967
1974
  icon: /* @__PURE__ */ n.jsx(P, { type: "like", chatProps: e }),
1968
1975
  onClick: () => {
1969
- (e == null ? void 0 : e.feedback) !== "like" && w("like");
1976
+ (e == null ? void 0 : e.feedback) !== "like" && j("like");
1970
1977
  }
1971
1978
  }
1972
1979
  ),
1973
- j && /* @__PURE__ */ n.jsx(
1974
- z,
1980
+ w && /* @__PURE__ */ n.jsx(
1981
+ Y,
1975
1982
  {
1976
1983
  icon: /* @__PURE__ */ n.jsx(P, { type: "dislike", chatProps: e }),
1977
1984
  onClick: () => {
1978
- (e == null ? void 0 : e.feedback) !== "dislike" && i(!0);
1985
+ (e == null ? void 0 : e.feedback) !== "dislike" && c(!0);
1979
1986
  }
1980
1987
  }
1981
1988
  ),
@@ -1986,10 +1993,10 @@ const me = (e = ".w-wrapper-body") => {
1986
1993
  isFeedback: !0,
1987
1994
  okText: s,
1988
1995
  onCancel: () => {
1989
- i(!1);
1996
+ c(!1);
1990
1997
  },
1991
1998
  onOk: () => {
1992
- w("dislike");
1999
+ j("dislike");
1993
2000
  },
1994
2001
  children: [
1995
2002
  /* @__PURE__ */ n.jsx("p", { style: { textAlign: "center", fontWeight: 600, fontSize: 14 }, children: t }),
@@ -2011,20 +2018,20 @@ const me = (e = ".w-wrapper-body") => {
2011
2018
  }
2012
2019
  ),
2013
2020
  u === "another" && /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
2014
- /* @__PURE__ */ n.jsx(Jt, { children: c }),
2021
+ /* @__PURE__ */ n.jsx(Jt, { children: i }),
2015
2022
  /* @__PURE__ */ n.jsx(oe, { form: o, layout: "vertical", children: /* @__PURE__ */ n.jsx(oe.Item, { name: "ADDITIONAL_FEEDBACK", children: /* @__PURE__ */ n.jsx(Be.TextArea, { rows: 3 }) }) })
2016
2023
  ] })
2017
2024
  ]
2018
2025
  }
2019
2026
  )
2020
2027
  ] });
2021
- }, or = R(rr), cr = ({
2028
+ }, or = O(rr), cr = ({
2022
2029
  showFeedback: e = !0,
2023
2030
  showRegenerate: t = !0,
2024
2031
  position: r = "left",
2025
2032
  ...s
2026
2033
  }) => {
2027
- const a = ks(), { chats: c, onSendMsg: o, setChats: d, loadingRegenerate: i, currRegenerateId: u } = fe(), f = O(() => s == null ? void 0 : s.sender, [s]), x = O(() => c == null ? void 0 : c.filter((p) => (p == null ? void 0 : p.sender) === "client"), [c]), g = O(() => t && f === "response" && (x == null ? void 0 : x.length) > 0 && (s == null ? void 0 : s.indexChat) === (c == null ? void 0 : c.length) - 1, [f, x, c, s == null ? void 0 : s.indexChat, t]), C = O(() => {
2034
+ const l = ks(), { chats: i, onSendMsg: o, setChats: d, loadingRegenerate: c, currRegenerateId: u } = fe(), f = R(() => s == null ? void 0 : s.sender, [s]), x = R(() => i == null ? void 0 : i.filter((p) => (p == null ? void 0 : p.sender) === "client"), [i]), g = R(() => t && f === "response" && (x == null ? void 0 : x.length) > 0 && (s == null ? void 0 : s.indexChat) === (i == null ? void 0 : i.length) - 1, [f, x, i, s == null ? void 0 : s.indexChat, t]), m = R(() => {
2028
2035
  switch (r) {
2029
2036
  case "left":
2030
2037
  return "flex-start";
@@ -2033,21 +2040,21 @@ const me = (e = ".w-wrapper-body") => {
2033
2040
  case "right":
2034
2041
  return "flex-end";
2035
2042
  }
2036
- }, [r]), y = O(() => e && (s == null ? void 0 : s.text_FeedbackIcons) === "hidup", [s, e]), j = () => {
2037
- const p = x == null ? void 0 : x[(x == null ? void 0 : x.length) - 1], w = c == null ? void 0 : c[(c == null ? void 0 : c.length) - 1];
2043
+ }, [r]), T = R(() => e && (s == null ? void 0 : s.text_FeedbackIcons) === "hidup", [s, e]), w = () => {
2044
+ const p = x == null ? void 0 : x[(x == null ? void 0 : x.length) - 1], j = i == null ? void 0 : i[(i == null ? void 0 : i.length) - 1];
2038
2045
  d(
2039
2046
  (v = []) => v == null ? void 0 : v.map((h, b) => b === (v == null ? void 0 : v.length) - 1 && (h == null ? void 0 : h.sender) === "response" ? {
2040
2047
  ...h,
2041
- generated_id: (w == null ? void 0 : w.generated_id) ?? a
2048
+ generated_id: (j == null ? void 0 : j.generated_id) ?? l
2042
2049
  // adjust with response
2043
2050
  } : h)
2044
- ), u.current = (w == null ? void 0 : w.generated_id) ?? a, o({
2051
+ ), u.current = (j == null ? void 0 : j.generated_id) ?? l, o({
2045
2052
  msg: p == null ? void 0 : p.text,
2046
2053
  additionalConfig: {
2047
- generate_id: (w == null ? void 0 : w.generated_id) ?? a
2054
+ generate_id: (j == null ? void 0 : j.generated_id) ?? l
2048
2055
  },
2049
- isShowLoadingResponse: i
2050
- }), me();
2056
+ isShowLoadingResponse: c
2057
+ }), Ce();
2051
2058
  };
2052
2059
  return /* @__PURE__ */ n.jsx(n.Fragment, { children: /* @__PURE__ */ n.jsxs(
2053
2060
  "div",
@@ -2055,24 +2062,24 @@ const me = (e = ".w-wrapper-body") => {
2055
2062
  style: {
2056
2063
  display: "flex",
2057
2064
  gap: 8,
2058
- justifyContent: C
2065
+ justifyContent: m
2059
2066
  },
2060
2067
  children: [
2061
2068
  g && /* @__PURE__ */ n.jsx(
2062
- z,
2069
+ Y,
2063
2070
  {
2064
- loading: i,
2071
+ loading: c,
2065
2072
  icon: /* @__PURE__ */ n.jsx(P, { type: "sync" }),
2066
2073
  onClick: () => {
2067
- j();
2074
+ w();
2068
2075
  }
2069
2076
  }
2070
2077
  ),
2071
- y && /* @__PURE__ */ n.jsx(or, { ...s })
2078
+ T && /* @__PURE__ */ n.jsx(or, { ...s })
2072
2079
  ]
2073
2080
  }
2074
2081
  ) });
2075
- }, mn = R(cr), ir = ({ nameFallback: e = "", ...t }) => /* @__PURE__ */ n.jsx(
2082
+ }, Cn = O(cr), ir = ({ nameFallback: e = "", ...t }) => /* @__PURE__ */ n.jsx(
2076
2083
  Qt,
2077
2084
  {
2078
2085
  ...typeof (t == null ? void 0 : t.onError) != "function" && {
@@ -2082,7 +2089,7 @@ const me = (e = ".w-wrapper-body") => {
2082
2089
  loading: "lazy",
2083
2090
  ...t
2084
2091
  }
2085
- ), kn = R(ir), lr = ({ nameFallback: e = "", ...t }) => {
2092
+ ), kn = O(ir), lr = ({ nameFallback: e = "", ...t }) => {
2086
2093
  const r = K(0);
2087
2094
  return /* @__PURE__ */ n.jsx(
2088
2095
  Xn,
@@ -2101,40 +2108,40 @@ const me = (e = ".w-wrapper-body") => {
2101
2108
  )
2102
2109
  }
2103
2110
  );
2104
- }, Ee = R(lr);
2111
+ }, Ee = O(lr);
2105
2112
  Ee.Group = Xn.Group;
2106
2113
  const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", children: [
2107
2114
  /* @__PURE__ */ n.jsx("div", {}),
2108
2115
  /* @__PURE__ */ n.jsx("div", {}),
2109
2116
  /* @__PURE__ */ n.jsx("div", {}),
2110
2117
  /* @__PURE__ */ n.jsx("div", {})
2111
- ] }), gt = R(ar), dr = () => {
2118
+ ] }), gt = O(ar), dr = () => {
2112
2119
  const { widgetProps: e } = q();
2113
2120
  return /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8, alignItems: "center" }, children: [
2114
2121
  /* @__PURE__ */ n.jsx(Ee, { src: Ze, nameFallback: e == null ? void 0 : e.title }),
2115
2122
  /* @__PURE__ */ n.jsx(gt, {})
2116
2123
  ] });
2117
- }, pn = R(dr), ur = ({ src: e, name: t }) => /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8, alignItems: "center" }, children: [
2124
+ }, _n = O(dr), ur = ({ src: e, name: t }) => /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8, alignItems: "center" }, children: [
2118
2125
  /* @__PURE__ */ n.jsx(Ee, { src: e, preview: !1, nameFallback: t }),
2119
- /* @__PURE__ */ n.jsx(V.Text, { children: t })
2120
- ] }), Ue = R(ur), fr = ({ ...e }) => {
2126
+ /* @__PURE__ */ n.jsx(G.Text, { children: t })
2127
+ ] }), Ue = O(ur), fr = ({ ...e }) => {
2121
2128
  var f, x;
2122
- const [t, r] = D(1), { loadingRegenerate: s, currRegenerateId: a } = fe(), { isExpand: c, widgetProps: o } = q(), d = O(() => e == null ? void 0 : e.sender, [e]), i = O(() => e == null ? void 0 : e.chats, [e == null ? void 0 : e.chats]), u = O(() => {
2123
- const g = i == null ? void 0 : i[(i == null ? void 0 : i.length) - 1];
2124
- return (g == null ? void 0 : g.generated_id) === a.current;
2125
- }, [i, e, a.current]);
2129
+ const [t, r] = D(1), { loadingRegenerate: s, currRegenerateId: l } = fe(), { isExpand: i, widgetProps: o } = q(), d = R(() => e == null ? void 0 : e.sender, [e]), c = R(() => e == null ? void 0 : e.chats, [e == null ? void 0 : e.chats]), u = R(() => {
2130
+ const g = c == null ? void 0 : c[(c == null ? void 0 : c.length) - 1];
2131
+ return (g == null ? void 0 : g.generated_id) === l.current;
2132
+ }, [c, e, l.current]);
2126
2133
  return X(() => {
2127
- !s && (i == null ? void 0 : i.length) > 0 && (r(i == null ? void 0 : i.length), me());
2128
- }, [s]), s && u ? /* @__PURE__ */ n.jsx(pn, {}) : /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
2134
+ !s && (c == null ? void 0 : c.length) > 0 && (r(c == null ? void 0 : c.length), Ce());
2135
+ }, [s]), s && u ? /* @__PURE__ */ n.jsx(_n, {}) : /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
2129
2136
  d === "response" && /* @__PURE__ */ n.jsx(Ue, { name: o == null ? void 0 : o.title, src: Ze }),
2130
- /* @__PURE__ */ n.jsx("div", { style: { display: "flex", gap: 8 }, children: i == null ? void 0 : i.map((g, C) => {
2137
+ /* @__PURE__ */ n.jsx("div", { style: { display: "flex", gap: 8 }, children: c == null ? void 0 : c.map((g, m) => {
2131
2138
  var p;
2132
- const y = C === ((p = e == null ? void 0 : e.chats) == null ? void 0 : p.length) - 1, j = t === C + 1;
2139
+ const T = m === ((p = e == null ? void 0 : e.chats) == null ? void 0 : p.length) - 1, w = t === m + 1;
2133
2140
  return /* @__PURE__ */ n.jsxs(
2134
2141
  "div",
2135
2142
  {
2136
2143
  style: {
2137
- display: j ? "flex" : "none",
2144
+ display: w ? "flex" : "none",
2138
2145
  flexDirection: "column",
2139
2146
  gap: 8
2140
2147
  },
@@ -2143,13 +2150,13 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2143
2150
  /* @__PURE__ */ n.jsx(
2144
2151
  "div",
2145
2152
  {
2146
- ...y && {
2147
- className: `w-regenerate-chat-last ${c ? "w-regenerate-chat-last-expand" : ""}`
2153
+ ...T && {
2154
+ className: `w-regenerate-chat-last ${i ? "w-regenerate-chat-last-expand" : ""}`
2148
2155
  },
2149
2156
  children: /* @__PURE__ */ n.jsxs(
2150
2157
  "div",
2151
2158
  {
2152
- className: `w-bubble-chat w-bubble-chat-regenerate ${`w-${d}`} ${c ? "w-bubble-chat-regenerate-expand" : ""}`,
2159
+ className: `w-bubble-chat w-bubble-chat-regenerate ${`w-${d}`} ${i ? "w-bubble-chat-regenerate-expand" : ""}`,
2153
2160
  children: [
2154
2161
  /* @__PURE__ */ n.jsx(ft, { children: g == null ? void 0 : g.text }),
2155
2162
  d === "response" && /* @__PURE__ */ n.jsx("span", { style: { fontSize: 12, color: "rgba(0,0,0,0.4)" }, children: g == null ? void 0 : g.timestamp })
@@ -2159,7 +2166,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2159
2166
  }
2160
2167
  ),
2161
2168
  /* @__PURE__ */ n.jsx(
2162
- mn,
2169
+ Cn,
2163
2170
  {
2164
2171
  showFeedback: !0,
2165
2172
  showRegenerate: !1,
@@ -2168,12 +2175,12 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2168
2175
  )
2169
2176
  ]
2170
2177
  },
2171
- C
2178
+ m
2172
2179
  );
2173
2180
  }) }),
2174
2181
  /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8, justifyContent: "center" }, children: [
2175
2182
  /* @__PURE__ */ n.jsx(
2176
- mn,
2183
+ Cn,
2177
2184
  {
2178
2185
  showRegenerate: !0,
2179
2186
  showFeedback: !1,
@@ -2182,7 +2189,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2182
2189
  ),
2183
2190
  /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 4, alignItems: "center" }, children: [
2184
2191
  /* @__PURE__ */ n.jsx(
2185
- z,
2192
+ Y,
2186
2193
  {
2187
2194
  size: "small",
2188
2195
  shape: "circle",
@@ -2193,13 +2200,13 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2193
2200
  }
2194
2201
  }
2195
2202
  ),
2196
- /* @__PURE__ */ n.jsxs(V.Text, { children: [
2203
+ /* @__PURE__ */ n.jsxs(G.Text, { children: [
2197
2204
  t,
2198
2205
  " / ",
2199
2206
  (f = e == null ? void 0 : e.chats) == null ? void 0 : f.length
2200
2207
  ] }),
2201
2208
  /* @__PURE__ */ n.jsx(
2202
- z,
2209
+ Y,
2203
2210
  {
2204
2211
  size: "small",
2205
2212
  shape: "circle",
@@ -2207,17 +2214,17 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2207
2214
  icon: /* @__PURE__ */ n.jsx(P, { type: "right" }),
2208
2215
  onClick: () => {
2209
2216
  var g;
2210
- t < ((g = e == null ? void 0 : e.chats) == null ? void 0 : g.length) && r((C) => C + 1);
2217
+ t < ((g = e == null ? void 0 : e.chats) == null ? void 0 : g.length) && r((m) => m + 1);
2211
2218
  }
2212
2219
  }
2213
2220
  )
2214
2221
  ] })
2215
2222
  ] })
2216
2223
  ] });
2217
- }, xr = R(fr), gr = ({ date: e, format: t, sender: r, ...s }) => {
2218
- var a, c;
2224
+ }, xr = O(fr), gr = ({ date: e, format: t, sender: r, ...s }) => {
2225
+ var l, i;
2219
2226
  return /* @__PURE__ */ n.jsx(
2220
- V.Text,
2227
+ G.Text,
2221
2228
  {
2222
2229
  ...s,
2223
2230
  type: "secondary",
@@ -2227,32 +2234,32 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2227
2234
  ...r === "client" && {
2228
2235
  textAlign: "right"
2229
2236
  },
2230
- ...((a = Object.keys((s == null ? void 0 : s.style) || {})) == null ? void 0 : a.length) > 0 && {
2237
+ ...((l = Object.keys((s == null ? void 0 : s.style) || {})) == null ? void 0 : l.length) > 0 && {
2231
2238
  ...s == null ? void 0 : s.style
2232
2239
  }
2233
2240
  },
2234
- children: t ? (c = ae(e)) == null ? void 0 : c.format(t) : e
2241
+ children: t ? (i = ae(e)) == null ? void 0 : i.format(t) : e
2235
2242
  }
2236
2243
  );
2237
- }, We = R(gr), Cr = ({ showResponseInfo: e = !0, ...t }) => {
2244
+ }, We = O(gr), mr = ({ showResponseInfo: e = !0, ...t }) => {
2238
2245
  var d;
2239
- const { loadingRegenerate: r, chats: s } = fe(), { widgetProps: a } = q(), c = O(() => (s == null ? void 0 : s.length) - 1 === (t == null ? void 0 : t.indexChat), [s]), o = O(() => t == null ? void 0 : t.sender, [t]);
2240
- return ((d = t == null ? void 0 : t.chats) == null ? void 0 : d.length) > 0 ? /* @__PURE__ */ n.jsx(xr, { ...t }) : r && c ? /* @__PURE__ */ n.jsx(pn, {}) : /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
2241
- o === "response" && e && /* @__PURE__ */ n.jsx(Ue, { name: a == null ? void 0 : a.title, src: Ze }),
2246
+ const { loadingRegenerate: r, chats: s } = fe(), { widgetProps: l } = q(), i = R(() => (s == null ? void 0 : s.length) - 1 === (t == null ? void 0 : t.indexChat), [s]), o = R(() => t == null ? void 0 : t.sender, [t]);
2247
+ return ((d = t == null ? void 0 : t.chats) == null ? void 0 : d.length) > 0 ? /* @__PURE__ */ n.jsx(xr, { ...t }) : r && i ? /* @__PURE__ */ n.jsx(_n, {}) : /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
2248
+ o === "response" && e && /* @__PURE__ */ n.jsx(Ue, { name: l == null ? void 0 : l.title, src: Ze }),
2242
2249
  /* @__PURE__ */ n.jsxs("div", { className: `w-bubble-chat ${`w-${o}`}`, children: [
2243
2250
  /* @__PURE__ */ n.jsx(ft, { children: t == null ? void 0 : t.text }),
2244
2251
  /* @__PURE__ */ n.jsx(We, { date: t == null ? void 0 : t.timestamp, sender: o })
2245
2252
  ] }),
2246
- /* @__PURE__ */ n.jsx(mn, { ...t })
2253
+ /* @__PURE__ */ n.jsx(Cn, { ...t })
2247
2254
  ] });
2248
- }, $e = R(Cr), mr = () => {
2255
+ }, $e = O(mr), Cr = () => {
2249
2256
  const e = _(
2250
2257
  "PleaseUploadFile",
2251
2258
  "Please upload specify file that needed to complete your request"
2252
2259
  ), t = _("ClickToUpload", "Click to upload"), r = _(
2253
2260
  "ContinueWithoutUpload",
2254
2261
  "Continue without upload"
2255
- ), { onSendMsg: s, setFile: a } = fe(), c = () => {
2262
+ ), { onSendMsg: s, setFile: l } = fe(), i = () => {
2256
2263
  s({
2257
2264
  msg: "CANCEL UPLOAD"
2258
2265
  });
@@ -2284,23 +2291,23 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2284
2291
  fileList: [],
2285
2292
  accept: ".doc, .jpg, .ods, .png, .txt, .docx, .pdf",
2286
2293
  onChange: (o) => {
2287
- a(o == null ? void 0 : o.file);
2294
+ l(o == null ? void 0 : o.file);
2288
2295
  },
2289
- children: /* @__PURE__ */ n.jsx(z, { icon: /* @__PURE__ */ n.jsx(P, { type: "upload" }), children: t })
2296
+ children: /* @__PURE__ */ n.jsx(Y, { icon: /* @__PURE__ */ n.jsx(P, { type: "upload" }), children: t })
2290
2297
  }
2291
2298
  ),
2292
- /* @__PURE__ */ n.jsx(z, { type: "dashed", onClick: c, children: r })
2299
+ /* @__PURE__ */ n.jsx(Y, { type: "dashed", onClick: i, children: r })
2293
2300
  ] })
2294
2301
  ]
2295
2302
  }
2296
2303
  );
2297
- }, br = R(mr), vr = () => {
2298
- const [e, t] = D(!1), [r, s] = D(!1), [a, c] = D(!1), [o, d] = D(3), [i, u] = D(!1), [f, x] = D(""), { widgetProps: g } = q(), { onSendMsg: C, chats: y } = fe(), { onSubmitPYPwd: j = () => {
2304
+ }, br = O(Cr), vr = () => {
2305
+ const [e, t] = D(!1), [r, s] = D(!1), [l, i] = D(!1), [o, d] = D(3), [c, u] = D(!1), [f, x] = D(""), { widgetProps: g } = q(), { onSendMsg: m, chats: T } = fe(), { onSubmitPYPwd: w = () => {
2299
2306
  }, onCheckPYAccess: p = () => {
2300
- } } = (g == null ? void 0 : g.onPayslipFn) || {}, w = _(
2307
+ } } = (g == null ? void 0 : g.onPayslipFn) || {}, j = _(
2301
2308
  "ProvidePasswordPayslip",
2302
2309
  "Please provide your password account to access the download"
2303
- ), v = _("Cancel", "Cancel"), h = _("Submit", "Submit"), b = _("Password", "Password"), E = _("IsRequired", "Is Required"), m = _(
2310
+ ), v = _("Cancel", "Cancel"), h = _("Submit", "Submit"), b = _("Password", "Password"), E = _("IsRequired", "Is Required"), C = _(
2304
2311
  "PrepareTheFiles",
2305
2312
  "Prepare the files"
2306
2313
  ), k = _(
@@ -2309,34 +2316,34 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2309
2316
  ), S = _(
2310
2317
  "VerifyAccessPayslip",
2311
2318
  "Please wait, verifying access to your payslip"
2312
- ), H = _(
2319
+ ), F = _(
2313
2320
  "WrongPwdPayslip",
2314
2321
  "The password you entered is incorrect. Please try again or contact support if you need assistance"
2315
2322
  ), B = _(
2316
2323
  "SessionExpired",
2317
2324
  "Session expired. Please log in again to continue"
2318
2325
  ), [M] = oe.useForm(), L = () => {
2319
- var F, G, J;
2320
- c(!0), u(!0), (J = (G = (F = p()) == null ? void 0 : F.then((Y) => {
2326
+ var I, J, z;
2327
+ i(!0), u(!0), (z = (J = (I = p()) == null ? void 0 : I.then((W) => {
2321
2328
  var ee, de;
2322
- const te = (de = (ee = Y == null ? void 0 : Y.data) == null ? void 0 : ee.DATA) == null ? void 0 : de.RESULT;
2323
- te && C({ msg: "Valid" }), t(te), x("");
2324
- })) == null ? void 0 : G.catch((Y) => {
2325
- console.log("err: ", Y == null ? void 0 : Y.toString()), x(Y == null ? void 0 : Y.toString());
2326
- })) == null || J.finally(() => {
2329
+ const te = (de = (ee = W == null ? void 0 : W.data) == null ? void 0 : ee.DATA) == null ? void 0 : de.RESULT;
2330
+ te && m({ msg: "Valid" }), t(te), x("");
2331
+ })) == null ? void 0 : J.catch((W) => {
2332
+ console.log("err: ", W == null ? void 0 : W.toString()), x(W == null ? void 0 : W.toString());
2333
+ })) == null || z.finally(() => {
2327
2334
  s(!1), u(!1);
2328
2335
  });
2329
- }, I = () => {
2330
- C({ msg: "cancel" }), c(!1);
2336
+ }, H = () => {
2337
+ m({ msg: "cancel" }), i(!1);
2331
2338
  }, $ = () => {
2332
- var G;
2333
- const F = M == null ? void 0 : M.getFieldValue("pwd");
2334
- (G = M == null ? void 0 : M.validateFields()) == null || G.then(() => {
2335
- var J, Y;
2336
- s(!0), (Y = (J = j(F)) == null ? void 0 : J.then(({ data: te }) => {
2339
+ var J;
2340
+ const I = M == null ? void 0 : M.getFieldValue("pwd");
2341
+ (J = M == null ? void 0 : M.validateFields()) == null || J.then(() => {
2342
+ var z, W;
2343
+ s(!0), (W = (z = w(I)) == null ? void 0 : z.then(({ data: te }) => {
2337
2344
  var ee;
2338
- (ee = te == null ? void 0 : te.DATA) != null && ee.ISVALID ? L() : (x(H), d(o - 1), s(!1));
2339
- })) == null || Y.catch((te) => {
2345
+ (ee = te == null ? void 0 : te.DATA) != null && ee.ISVALID ? L() : (x(F), d(o - 1), s(!1));
2346
+ })) == null || W.catch((te) => {
2340
2347
  var de, ce, Ne, Ve, Ge;
2341
2348
  const ee = te == null ? void 0 : te.response;
2342
2349
  if ((ee == null ? void 0 : ee.status) === 401) {
@@ -2345,7 +2352,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2345
2352
  ), Fe = (Ge = (Ve = (Ne = ee == null ? void 0 : ee.data) == null ? void 0 : Ne.MESSAGE) == null ? void 0 : Ve.toLowerCase()) == null ? void 0 : Ge.includes(
2346
2353
  "invalid password"
2347
2354
  );
2348
- Me && x(B), Fe && (x(H), d(o - 1), s(!1));
2355
+ Me && x(B), Fe && (x(F), d(o - 1), s(!1));
2349
2356
  } else
2350
2357
  console.log("err onSubmit: ", te == null ? void 0 : te.toString()), x(te == null ? void 0 : te.toString());
2351
2358
  s(!1);
@@ -2353,10 +2360,10 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2353
2360
  });
2354
2361
  };
2355
2362
  return X(() => {
2356
- var G;
2357
- const F = y == null ? void 0 : y[(y == null ? void 0 : y.length) - 1];
2358
- ((G = F == null ? void 0 : F.attachment) == null ? void 0 : G.type) === "show_password_wp" && L();
2359
- }, []), a ? i ? /* @__PURE__ */ n.jsx(
2363
+ var J;
2364
+ const I = T == null ? void 0 : T[(T == null ? void 0 : T.length) - 1];
2365
+ ((J = I == null ? void 0 : I.attachment) == null ? void 0 : J.type) === "show_password_wp" && L();
2366
+ }, []), l ? c ? /* @__PURE__ */ n.jsx(
2360
2367
  $e,
2361
2368
  {
2362
2369
  sender: "response",
@@ -2382,7 +2389,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2382
2389
  layout: "vertical",
2383
2390
  style: { display: "flex", flexDirection: "column", gap: 8 },
2384
2391
  children: [
2385
- /* @__PURE__ */ n.jsx(V.Text, { children: e ? `${m}...` : w }),
2392
+ /* @__PURE__ */ n.jsx(G.Text, { children: e ? `${C}...` : j }),
2386
2393
  !e && /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
2387
2394
  /* @__PURE__ */ n.jsx(
2388
2395
  oe.Item,
@@ -2398,9 +2405,9 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2398
2405
  }
2399
2406
  ),
2400
2407
  /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8 }, children: [
2401
- /* @__PURE__ */ n.jsx(z, { disabled: r, onClick: I, children: v }),
2408
+ /* @__PURE__ */ n.jsx(Y, { disabled: r, onClick: H, children: v }),
2402
2409
  /* @__PURE__ */ n.jsx(
2403
- z,
2410
+ Y,
2404
2411
  {
2405
2412
  type: "primary",
2406
2413
  onClick: $,
@@ -2416,38 +2423,38 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2416
2423
  )
2417
2424
  }
2418
2425
  ) : null;
2419
- }, hr = R(vr), Er = ({ ...e }) => {
2426
+ }, hr = O(vr), Er = ({ ...e }) => {
2420
2427
  var d;
2421
- const { objInitPayload: t } = q(), [r, s] = D(!1), a = _("Error", "Error"), c = O(() => rt(t == null ? void 0 : t.access_token), [t]), o = () => {
2428
+ const { objInitPayload: t } = q(), [r, s] = D(!1), l = _("Error", "Error"), i = R(() => rt(t == null ? void 0 : t.access_token), [t]), o = () => {
2422
2429
  var u, f, x, g;
2423
2430
  s(!0);
2424
- const i = e == null ? void 0 : e.attachment;
2431
+ const c = e == null ? void 0 : e.attachment;
2425
2432
  (g = (x = (f = Oe({
2426
2433
  method: "POST",
2427
- url: i == null ? void 0 : i.endpoint,
2428
- data: i == null ? void 0 : i.body,
2434
+ url: c == null ? void 0 : c.endpoint,
2435
+ data: c == null ? void 0 : c.body,
2429
2436
  headers: {
2430
2437
  Authorization: `Bearer ${t == null ? void 0 : t.access_token}`,
2431
- "Content-Type": i == null ? void 0 : i.headers["Content-Type"],
2438
+ "Content-Type": c == null ? void 0 : c.headers["Content-Type"],
2432
2439
  coid: t == null ? void 0 : t.companyid,
2433
2440
  "Company-Id": t == null ? void 0 : t.companyid,
2434
- "Acc-Name": (u = c == null ? void 0 : c.INSTANCE) == null ? void 0 : u.toLowerCase()
2441
+ "Acc-Name": (u = i == null ? void 0 : i.INSTANCE) == null ? void 0 : u.toLowerCase()
2435
2442
  },
2436
2443
  responseType: "blob"
2437
- })) == null ? void 0 : f.then((C) => {
2444
+ })) == null ? void 0 : f.then((m) => {
2438
2445
  var v;
2439
- const y = (v = i == null ? void 0 : i.body) == null ? void 0 : v.media, j = `${i == null ? void 0 : i.filename}.${y}`, p = new Blob([C == null ? void 0 : C.data]), w = URL == null ? void 0 : URL.createObjectURL(p);
2440
- Tn({ downloadURL: w, fileName: j }), URL.revokeObjectURL(w);
2441
- })) == null ? void 0 : x.catch((C) => {
2442
- var j, p, w;
2443
- const y = C == null ? void 0 : C.message;
2444
- (j = ie) == null || j.destroy(), (p = ie) == null || p.config({
2446
+ const T = (v = c == null ? void 0 : c.body) == null ? void 0 : v.media, w = `${c == null ? void 0 : c.filename}.${T}`, p = new Blob([m == null ? void 0 : m.data]), j = URL == null ? void 0 : URL.createObjectURL(p);
2447
+ Tn({ downloadURL: j, fileName: w }), URL.revokeObjectURL(j);
2448
+ })) == null ? void 0 : x.catch((m) => {
2449
+ var w, p, j;
2450
+ const T = m == null ? void 0 : m.message;
2451
+ (w = ie) == null || w.destroy(), (p = ie) == null || p.config({
2445
2452
  getContainer: () => document.querySelector(".w-widget-content-container"),
2446
2453
  top: 28,
2447
2454
  placement: "top"
2448
- }), (w = ie) == null || w.error({
2449
- message: a,
2450
- description: y,
2455
+ }), (j = ie) == null || j.error({
2456
+ message: l,
2457
+ description: T,
2451
2458
  className: "w-notification-content",
2452
2459
  duration: 3
2453
2460
  });
@@ -2462,9 +2469,9 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2462
2469
  onClick: o,
2463
2470
  style: { cursor: "pointer" },
2464
2471
  children: /* @__PURE__ */ n.jsxs(Zt, { spinning: r, children: [
2465
- /* @__PURE__ */ n.jsx(V.Link, { children: (d = e == null ? void 0 : e.attachment) == null ? void 0 : d.filename }),
2472
+ /* @__PURE__ */ n.jsx(G.Link, { children: (d = e == null ? void 0 : e.attachment) == null ? void 0 : d.filename }),
2466
2473
  /* @__PURE__ */ n.jsx(
2467
- z,
2474
+ Y,
2468
2475
  {
2469
2476
  icon: /* @__PURE__ */ n.jsx(
2470
2477
  P,
@@ -2479,18 +2486,18 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2479
2486
  ] })
2480
2487
  }
2481
2488
  );
2482
- }, Tr = R(Er), yr = ({ ...e }) => {
2483
- const t = K(), r = _("DownloadChart", "Download Chart"), s = O(() => e == null ? void 0 : e.attachment, [e == null ? void 0 : e.attachment]), a = O(() => {
2489
+ }, Tr = O(Er), yr = ({ ...e }) => {
2490
+ const t = K(), r = _("DownloadChart", "Download Chart"), s = R(() => e == null ? void 0 : e.attachment, [e == null ? void 0 : e.attachment]), l = R(() => {
2484
2491
  var o;
2485
- return (o = s == null ? void 0 : s.data) == null ? void 0 : o.map((d, i) => {
2492
+ return (o = s == null ? void 0 : s.data) == null ? void 0 : o.map((d, c) => {
2486
2493
  var u, f;
2487
2494
  return {
2488
- label: (u = s == null ? void 0 : s.labels) == null ? void 0 : u[i],
2495
+ label: (u = s == null ? void 0 : s.labels) == null ? void 0 : u[c],
2489
2496
  value: d,
2490
- color: (f = s == null ? void 0 : s.colors) == null ? void 0 : f[i]
2497
+ color: (f = s == null ? void 0 : s.colors) == null ? void 0 : f[c]
2491
2498
  };
2492
2499
  });
2493
- }, [s]), c = () => {
2500
+ }, [s]), i = () => {
2494
2501
  var d;
2495
2502
  const o = (d = document == null ? void 0 : document.querySelector(".chart_widget canvas")) == null ? void 0 : d.toDataURL();
2496
2503
  Tn({ fileName: s == null ? void 0 : s.title, downloadURL: o });
@@ -2501,7 +2508,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2501
2508
  {
2502
2509
  className: "chart_widget",
2503
2510
  ref: t,
2504
- data: a,
2511
+ data: l,
2505
2512
  angleField: "value",
2506
2513
  colorField: "label",
2507
2514
  label: {
@@ -2520,17 +2527,17 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2520
2527
  }
2521
2528
  ),
2522
2529
  /* @__PURE__ */ n.jsx("div", { style: { textAlign: "center" }, children: /* @__PURE__ */ n.jsx(
2523
- z,
2530
+ Y,
2524
2531
  {
2525
2532
  onClick: () => {
2526
- c();
2533
+ i();
2527
2534
  },
2528
2535
  children: r
2529
2536
  }
2530
2537
  ) })
2531
2538
  ] });
2532
- }, jr = R(yr), wr = ({ ...e }) => {
2533
- var t, r, s, a, c;
2539
+ }, jr = O(yr), wr = ({ ...e }) => {
2540
+ var t, r, s, l, i;
2534
2541
  switch (!0) {
2535
2542
  case ((t = Ae(e)) == null ? void 0 : t.text):
2536
2543
  return /* @__PURE__ */ n.jsx($e, { ...e });
@@ -2538,35 +2545,35 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2538
2545
  return /* @__PURE__ */ n.jsx(br, { ...e });
2539
2546
  case ((s = Ae(e)) == null ? void 0 : s.password):
2540
2547
  return /* @__PURE__ */ n.jsx(hr, { ...e });
2541
- case ((a = Ae(e)) == null ? void 0 : a.filedownload):
2548
+ case ((l = Ae(e)) == null ? void 0 : l.filedownload):
2542
2549
  return /* @__PURE__ */ n.jsx(Tr, { ...e });
2543
- case ((c = Ae(e)) == null ? void 0 : c.chart):
2550
+ case ((i = Ae(e)) == null ? void 0 : i.chart):
2544
2551
  return /* @__PURE__ */ n.jsx(jr, { ...e });
2545
2552
  default:
2546
2553
  return null;
2547
2554
  }
2548
- }, kr = R(wr), pr = () => {
2549
- const { isOpenWidget: e, widgetProps: t } = q(), { chats: r, isWaitResponse: s } = fe(), { activeTab: a } = be();
2555
+ }, kr = O(wr), _r = () => {
2556
+ const { isOpenWidget: e, widgetProps: t } = q(), { chats: r, isWaitResponse: s } = fe(), { activeTab: l } = be();
2550
2557
  return X(() => {
2551
- me();
2552
- }, [a]), e ? /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
2553
- /* @__PURE__ */ n.jsx("div", { className: "w-bubble-chat-container", children: r == null ? void 0 : r.map((c, o) => {
2554
- var i;
2555
- const d = (i = Ae(c)) == null ? void 0 : i.text;
2556
- return /* @__PURE__ */ n.jsxs(Cn, { children: [
2557
- (c == null ? void 0 : c.sender) === "response" && !d && /* @__PURE__ */ n.jsx(
2558
+ Ce();
2559
+ }, [l]), e ? /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
2560
+ /* @__PURE__ */ n.jsx("div", { className: "w-bubble-chat-container", children: r == null ? void 0 : r.map((i, o) => {
2561
+ var c;
2562
+ const d = (c = Ae(i)) == null ? void 0 : c.text;
2563
+ return /* @__PURE__ */ n.jsxs(mn, { children: [
2564
+ (i == null ? void 0 : i.sender) === "response" && !d && /* @__PURE__ */ n.jsx(
2558
2565
  Ue,
2559
2566
  {
2560
2567
  name: t == null ? void 0 : t.title,
2561
2568
  src: Ze
2562
2569
  }
2563
2570
  ),
2564
- /* @__PURE__ */ n.jsx(kr, { indexChat: o, ...c })
2571
+ /* @__PURE__ */ n.jsx(kr, { indexChat: o, ...i })
2565
2572
  ] }, o);
2566
2573
  }) }),
2567
- s && /* @__PURE__ */ n.jsx(pn, {})
2574
+ s && /* @__PURE__ */ n.jsx(_n, {})
2568
2575
  ] }) : null;
2569
- }, _r = R(pr), Ar = () => {
2576
+ }, pr = O(_r), Ar = () => {
2570
2577
  var h;
2571
2578
  const e = _(
2572
2579
  "ContinueWithoutUpload",
@@ -2575,27 +2582,27 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2575
2582
  onSendMsg: t,
2576
2583
  setChats: r,
2577
2584
  isWaitResponse: s,
2578
- loadingRegenerate: a,
2579
- file: c,
2585
+ loadingRegenerate: l,
2586
+ file: i,
2580
2587
  setFile: o,
2581
2588
  chats: d,
2582
- connected: i
2583
- } = fe(), { isActiveTabVA: u } = be(), f = O(() => {
2589
+ connected: c
2590
+ } = fe(), { isActiveTabVA: u } = be(), f = R(() => {
2584
2591
  var E;
2585
2592
  const b = d == null ? void 0 : d[(d == null ? void 0 : d.length) - 1];
2586
2593
  return (b == null ? void 0 : b.sender) === "response" && ((E = b == null ? void 0 : b.attachment) == null ? void 0 : E.type) === "fileuploader";
2587
- }, [d]), x = K(), [g, C] = D(!1), [y, j] = D(!1), p = O(() => s || !y, [y, s]), w = () => {
2588
- var m, k, S, H;
2589
- const b = (S = (k = (m = x == null ? void 0 : x.current) == null ? void 0 : m.resizableTextArea) == null ? void 0 : k.textArea) == null ? void 0 : S.value;
2594
+ }, [d]), x = K(), [g, m] = D(!1), [T, w] = D(!1), p = R(() => s || !T, [T, s]), j = () => {
2595
+ var C, k, S, F;
2596
+ const b = (S = (k = (C = x == null ? void 0 : x.current) == null ? void 0 : C.resizableTextArea) == null ? void 0 : k.textArea) == null ? void 0 : S.value;
2590
2597
  if (!(b != null && b.trim()) || s) return;
2591
- j(!1), t({ msg: b }), C(!g);
2598
+ w(!1), t({ msg: b }), m(!g);
2592
2599
  const E = {
2593
2600
  text: b,
2594
2601
  sender: "client",
2595
2602
  type: "text",
2596
- timestamp: (H = ae()) == null ? void 0 : H.format("hh:mm A")
2603
+ timestamp: (F = ae()) == null ? void 0 : F.format("hh:mm A")
2597
2604
  };
2598
- r((B) => [...B, E]), me();
2605
+ r((B) => [...B, E]), Ce();
2599
2606
  }, v = () => {
2600
2607
  t({ msg: "SKIP_WAITING_RESPONSE" });
2601
2608
  };
@@ -2603,10 +2610,10 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2603
2610
  var b;
2604
2611
  x != null && x.current && u && ((b = x == null ? void 0 : x.current) == null || b.focus());
2605
2612
  }, [u]), f ? /* @__PURE__ */ n.jsxs("div", { className: "w-input-container", style: { alignItems: "center" }, children: [
2606
- /* @__PURE__ */ n.jsx(V.Text, { children: c == null ? void 0 : c.name }),
2607
- ((h = Object == null ? void 0 : Object.keys(c || {})) == null ? void 0 : h.length) > 0 ? /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8, alignItems: "center" }, children: [
2613
+ /* @__PURE__ */ n.jsx(G.Text, { children: i == null ? void 0 : i.name }),
2614
+ ((h = Object == null ? void 0 : Object.keys(i || {})) == null ? void 0 : h.length) > 0 ? /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8, alignItems: "center" }, children: [
2608
2615
  /* @__PURE__ */ n.jsx(
2609
- z,
2616
+ Y,
2610
2617
  {
2611
2618
  danger: !0,
2612
2619
  icon: /* @__PURE__ */ n.jsx(P, { type: "delete" }),
@@ -2615,17 +2622,17 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2615
2622
  }
2616
2623
  ),
2617
2624
  /* @__PURE__ */ n.jsx(
2618
- z,
2625
+ Y,
2619
2626
  {
2620
2627
  className: "w-send-btn",
2621
2628
  style: { backgroundColor: "var(--primary-color, #395ebc)" },
2622
2629
  icon: /* @__PURE__ */ n.jsx(P, { type: "send" }),
2623
2630
  shape: "circle",
2624
- onClick: w
2631
+ onClick: j
2625
2632
  }
2626
2633
  )
2627
2634
  ] }) : /* @__PURE__ */ n.jsx(Se, { title: e, children: /* @__PURE__ */ n.jsx(
2628
- z,
2635
+ Y,
2629
2636
  {
2630
2637
  icon: /* @__PURE__ */ n.jsx(P, { type: "close" }),
2631
2638
  shape: "circle",
@@ -2641,23 +2648,23 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2641
2648
  Be.TextArea,
2642
2649
  {
2643
2650
  className: "w-input-widget",
2644
- disabled: !i,
2651
+ disabled: !c,
2645
2652
  ref: x,
2646
2653
  placeholder: "Type a message...",
2647
2654
  onKeyDown: (b) => {
2648
- ((b == null ? void 0 : b.code) === "Enter" || (b == null ? void 0 : b.key) === "Enter") && !(b != null && b.shiftKey) && w();
2655
+ ((b == null ? void 0 : b.code) === "Enter" || (b == null ? void 0 : b.key) === "Enter") && !(b != null && b.shiftKey) && j();
2649
2656
  },
2650
2657
  onChange: ({ target: { value: b } }) => {
2651
2658
  const E = /\S/;
2652
2659
  Pe({
2653
2660
  input_va_value: b
2654
- }), b && (E != null && E.test(b)) ? j(!0) : b != null && b.trim() || j(!1);
2661
+ }), b && (E != null && E.test(b)) ? w(!0) : b != null && b.trim() || w(!1);
2655
2662
  }
2656
2663
  },
2657
2664
  g
2658
2665
  ),
2659
- s || a ? /* @__PURE__ */ n.jsx(
2660
- z,
2666
+ s || l ? /* @__PURE__ */ n.jsx(
2667
+ Y,
2661
2668
  {
2662
2669
  style: { border: "none" },
2663
2670
  icon: /* @__PURE__ */ n.jsx(P, { type: "stop" }),
@@ -2666,25 +2673,25 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2666
2673
  size: "large"
2667
2674
  }
2668
2675
  ) : /* @__PURE__ */ n.jsx(
2669
- z,
2676
+ Y,
2670
2677
  {
2671
2678
  className: `w-send-btn ${p ? "w-send-btn-disabled" : ""}`,
2672
2679
  disabled: p,
2673
2680
  style: { backgroundColor: "var(--primary-color, #395ebc)" },
2674
2681
  icon: /* @__PURE__ */ n.jsx(P, { type: "send" }),
2675
2682
  shape: "circle",
2676
- onClick: w
2683
+ onClick: j
2677
2684
  }
2678
2685
  )
2679
2686
  ] });
2680
- }, Sr = R(Ar), Lr = ({ taskStatus: e }) => {
2681
- const t = _("InProgress", "In Progress"), r = _("New", "New"), s = _("Closed", "Closed"), a = _("Done", "Done"), c = _("HDCancelled", "Cancelled"), o = {
2687
+ }, Sr = O(Ar), Lr = ({ taskStatus: e }) => {
2688
+ const t = _("InProgress", "In Progress"), r = _("New", "New"), s = _("Closed", "Closed"), l = _("Done", "Done"), i = _("HDCancelled", "Cancelled"), o = {
2682
2689
  "In Progress": t,
2683
2690
  Open: r,
2684
2691
  New: r,
2685
2692
  Closed: s,
2686
- Fixed: a,
2687
- Cancelled: c
2693
+ Fixed: l,
2694
+ Cancelled: i
2688
2695
  }, d = {
2689
2696
  "In Progress": "#FFF2D6",
2690
2697
  Responded: "#FFF2D6",
@@ -2694,9 +2701,9 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2694
2701
  Fixed: "#bbfab7",
2695
2702
  Done: "#bbfab7",
2696
2703
  Cancelled: "#FFF2D6"
2697
- }, i = O(() => d[e] || d.Closed, [e]), u = O(() => o[e] || e, [e]);
2698
- return /* @__PURE__ */ n.jsx(Xt, { color: i, children: /* @__PURE__ */ n.jsx(
2699
- V.Text,
2704
+ }, c = R(() => d[e] || d.Closed, [e]), u = R(() => o[e] || e, [e]);
2705
+ return /* @__PURE__ */ n.jsx(Xt, { color: c, children: /* @__PURE__ */ n.jsx(
2706
+ G.Text,
2700
2707
  {
2701
2708
  className: "primary-color-active",
2702
2709
  style: { width: "100%", textAlign: "center" },
@@ -2704,7 +2711,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2704
2711
  children: u
2705
2712
  }
2706
2713
  ) }, e);
2707
- }, Ct = R(Lr), Rr = ({ onClick: e, ...t }) => /* @__PURE__ */ n.jsxs(
2714
+ }, mt = O(Lr), Rr = ({ onClick: e, ...t }) => /* @__PURE__ */ n.jsxs(
2708
2715
  "div",
2709
2716
  {
2710
2717
  className: "w-ticket-card-container",
@@ -2713,7 +2720,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2713
2720
  },
2714
2721
  children: [
2715
2722
  /* @__PURE__ */ n.jsx(
2716
- V.Text,
2723
+ G.Text,
2717
2724
  {
2718
2725
  strong: !0,
2719
2726
  style: {
@@ -2727,8 +2734,8 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2727
2734
  ),
2728
2735
  /* @__PURE__ */ n.jsxs("div", { className: "w-ticket-card-content-container", children: [
2729
2736
  /* @__PURE__ */ n.jsxs("div", { className: "w-ticket-card-cat-code", children: [
2730
- /* @__PURE__ */ n.jsx(V.Text, { children: (t == null ? void 0 : t.TASK_CATEGORY) || qn }),
2731
- /* @__PURE__ */ n.jsx(V.Text, { children: (t == null ? void 0 : t.TASK_CODE) || qn })
2737
+ /* @__PURE__ */ n.jsx(G.Text, { children: (t == null ? void 0 : t.TASK_CATEGORY) || qn }),
2738
+ /* @__PURE__ */ n.jsx(G.Text, { children: (t == null ? void 0 : t.TASK_CODE) || qn })
2732
2739
  ] }),
2733
2740
  /* @__PURE__ */ n.jsxs(
2734
2741
  "div",
@@ -2738,28 +2745,28 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2738
2745
  alignItems: "flex-end"
2739
2746
  },
2740
2747
  children: [
2741
- /* @__PURE__ */ n.jsx(Ct, { taskStatus: t == null ? void 0 : t.TASK_STATUS }),
2742
- /* @__PURE__ */ n.jsx(V.Text, { children: t == null ? void 0 : t.CREATED_DATE })
2748
+ /* @__PURE__ */ n.jsx(mt, { taskStatus: t == null ? void 0 : t.TASK_STATUS }),
2749
+ /* @__PURE__ */ n.jsx(G.Text, { children: t == null ? void 0 : t.CREATED_DATE })
2743
2750
  ]
2744
2751
  }
2745
2752
  )
2746
2753
  ] })
2747
2754
  ]
2748
2755
  }
2749
- ), Or = R(Rr), mt = () => {
2750
- const { objInitPayload: e, setObjInitPayload: t, parsedJWT: r } = q(), s = O(() => {
2751
- var c;
2756
+ ), Or = O(Rr), Ct = () => {
2757
+ const { objInitPayload: e, setObjInitPayload: t, parsedJWT: r } = q(), s = R(() => {
2758
+ var i;
2752
2759
  return {
2753
2760
  Authorization: `Bearer ${e == null ? void 0 : e.access_token}`,
2754
2761
  coid: r == null ? void 0 : r.COID,
2755
- "Acc-Name": (c = r == null ? void 0 : r.INSTANCE) == null ? void 0 : c.toLowerCase(),
2762
+ "Acc-Name": (i = r == null ? void 0 : r.INSTANCE) == null ? void 0 : i.toLowerCase(),
2756
2763
  "Company-Id": e == null ? void 0 : e.companyid,
2757
2764
  Language: e == null ? void 0 : e.lang
2758
2765
  };
2759
2766
  }, [e]);
2760
- return async (c) => {
2767
+ return async (i) => {
2761
2768
  var u, f, x;
2762
- const { onSuccess: o, onError: d, onFinally: i } = c ?? {};
2769
+ const { onSuccess: o, onError: d, onFinally: c } = i ?? {};
2763
2770
  (x = (f = (u = Oe({
2764
2771
  url: e == null ? void 0 : e.uriBackend,
2765
2772
  params: {
@@ -2772,9 +2779,9 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2772
2779
  headers: s,
2773
2780
  method: "POST"
2774
2781
  })) == null ? void 0 : u.then((g) => {
2775
- var j;
2776
- const C = (j = g == null ? void 0 : g.data) == null ? void 0 : j.DATA, y = {
2777
- access_token: C == null ? void 0 : C.JWT_TOKEN,
2782
+ var w;
2783
+ const m = (w = g == null ? void 0 : g.data) == null ? void 0 : w.DATA, T = {
2784
+ access_token: m == null ? void 0 : m.JWT_TOKEN,
2778
2785
  refresh_token: e == null ? void 0 : e.refresh_token,
2779
2786
  uagent: e == null ? void 0 : e.uagent,
2780
2787
  uriBackend: e == null ? void 0 : e.uriBackend,
@@ -2786,68 +2793,68 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2786
2793
  uriBackendHRMGO: e == null ? void 0 : e.uriBackendHRMGO,
2787
2794
  config: e == null ? void 0 : e.config
2788
2795
  };
2789
- t(y), typeof o == "function" && o(g);
2796
+ t(T), typeof o == "function" && o(g);
2790
2797
  })) == null ? void 0 : f.catch((g) => {
2791
2798
  typeof d == "function" && d(g);
2792
2799
  })) == null || x.finally(() => {
2793
- typeof i == "function" && i();
2800
+ typeof c == "function" && c();
2794
2801
  });
2795
2802
  };
2796
2803
  }, en = () => {
2797
2804
  var o;
2798
- const e = K(new AbortController()), { objInitPayload: t, parsedJWT: r } = q(), s = mt(), a = {
2805
+ const e = K(new AbortController()), { objInitPayload: t, parsedJWT: r } = q(), s = Ct(), l = {
2799
2806
  Authorization: `Bearer ${t == null ? void 0 : t.access_token}`,
2800
2807
  coid: r == null ? void 0 : r.COID,
2801
2808
  "Acc-Name": (o = r == null ? void 0 : r.INSTANCE) == null ? void 0 : o.toLowerCase(),
2802
2809
  "Company-Id": t == null ? void 0 : t.companyid,
2803
2810
  Language: t == null ? void 0 : t.lang
2804
- }, c = async ({
2811
+ }, i = async ({
2805
2812
  url: d,
2806
- endpoint: i,
2813
+ endpoint: c,
2807
2814
  method: u = "POST",
2808
2815
  headers: f,
2809
2816
  ...x
2810
2817
  }) => {
2811
- var j, p, w, v, h, b;
2818
+ var w, p, j, v, h, b;
2812
2819
  const g = {
2813
- url: d || `${t == null ? void 0 : t.uriBackendHRMGO}${i}`,
2820
+ url: d || `${t == null ? void 0 : t.uriBackendHRMGO}${c}`,
2814
2821
  ...e.current && {
2815
- signal: (j = e == null ? void 0 : e.current) == null ? void 0 : j.signal
2822
+ signal: (w = e == null ? void 0 : e.current) == null ? void 0 : w.signal
2816
2823
  },
2817
2824
  headers: {
2818
- ...a,
2825
+ ...l,
2819
2826
  ...f,
2820
2827
  "Company-Code": t == null ? void 0 : t.companycode
2821
2828
  },
2822
2829
  method: u,
2823
2830
  ...x
2824
- }, C = (p = Oe) == null ? void 0 : p.create(g);
2825
- return (v = (w = C == null ? void 0 : C.interceptors) == null ? void 0 : w.request) == null || v.use(
2831
+ }, m = (p = Oe) == null ? void 0 : p.create(g);
2832
+ return (v = (j = m == null ? void 0 : m.interceptors) == null ? void 0 : j.request) == null || v.use(
2826
2833
  (E) => (t != null && t.access_token && (E.headers.Authorization = `Bearer ${t == null ? void 0 : t.access_token}`), E),
2827
2834
  (E) => {
2828
2835
  Promise.reject(E);
2829
2836
  }
2830
- ), (b = (h = C == null ? void 0 : C.interceptors) == null ? void 0 : h.response) == null || b.use(
2837
+ ), (b = (h = m == null ? void 0 : m.interceptors) == null ? void 0 : h.response) == null || b.use(
2831
2838
  (E) => E,
2832
2839
  async (E) => {
2833
2840
  var k;
2834
- const m = E == null ? void 0 : E.config;
2841
+ const C = E == null ? void 0 : E.config;
2835
2842
  if (((k = E == null ? void 0 : E.response) == null ? void 0 : k.status) === 401) {
2836
2843
  const S = await s();
2837
- return m.headers.Authorization = `Bearer ${S}`, Oe(m);
2844
+ return C.headers.Authorization = `Bearer ${S}`, Oe(C);
2838
2845
  }
2839
2846
  return Promise == null ? void 0 : Promise.reject(E);
2840
2847
  }
2841
- ), await (C == null ? void 0 : C.request(g));
2848
+ ), await (m == null ? void 0 : m.request(g));
2842
2849
  };
2843
- return c.abort = () => {
2850
+ return i.abort = () => {
2844
2851
  var d;
2845
2852
  e != null && e.current && ((d = e == null ? void 0 : e.current) == null || d.abort(), e.current = new AbortController());
2846
- }, X(() => () => c.abort(), []), c;
2853
+ }, X(() => () => i.abort(), []), i;
2847
2854
  }, bt = Te({}), ve = () => ye(bt), Dr = ({ children: e }) => {
2848
- const t = en(), [r, s] = D([]), [a, c] = D(""), [o, d] = D(!1), [i, u] = D(!0), [f, x] = D(0), g = (C) => {
2849
- var y, j, p, w;
2850
- u(!0), (w = (p = t({
2855
+ const t = en(), [r, s] = D([]), [l, i] = D(""), [o, d] = D(!1), [c, u] = D(!0), [f, x] = D(0), g = (m) => {
2856
+ var T, w, p, j;
2857
+ u(!0), (j = (p = t({
2851
2858
  endpoint: "/helpdesk/myticket/ticket-list",
2852
2859
  method: "POST",
2853
2860
  data: {
@@ -2856,10 +2863,10 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2856
2863
  SEARCH: {
2857
2864
  MY_TICKET: !0,
2858
2865
  TASK_MODULE: "HD",
2859
- ...((y = Object.keys(C || {})) == null ? void 0 : y.length) > 0 && {
2860
- ...C,
2861
- ...(C == null ? void 0 : C.CREATED_DATE) && {
2862
- CREATED_DATE: (j = ae(C == null ? void 0 : C.CREATED_DATE)) == null ? void 0 : j.format(En)
2866
+ ...((T = Object.keys(m || {})) == null ? void 0 : T.length) > 0 && {
2867
+ ...m,
2868
+ ...(m == null ? void 0 : m.CREATED_DATE) && {
2869
+ CREATED_DATE: (w = ae(m == null ? void 0 : m.CREATED_DATE)) == null ? void 0 : w.format(En)
2863
2870
  }
2864
2871
  }
2865
2872
  },
@@ -2871,7 +2878,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2871
2878
  })) == null ? void 0 : p.then((v) => {
2872
2879
  var h, b, E;
2873
2880
  (h = v == null ? void 0 : v.data) != null && h.DATA && s((E = (b = v == null ? void 0 : v.data) == null ? void 0 : b.DATA) == null ? void 0 : E.LIST);
2874
- })) == null || w.finally(() => {
2881
+ })) == null || j.finally(() => {
2875
2882
  u(!1);
2876
2883
  });
2877
2884
  };
@@ -2882,12 +2889,12 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2882
2889
  {
2883
2890
  value: {
2884
2891
  listTicket: r,
2885
- ticketId: a,
2886
- setTicketId: c,
2892
+ ticketId: l,
2893
+ setTicketId: i,
2887
2894
  getListTicket: g,
2888
2895
  openFilter: o,
2889
2896
  setOpenFilter: d,
2890
- loadingListTicket: i,
2897
+ loadingListTicket: c,
2891
2898
  countFilters: f,
2892
2899
  setCountFilters: x
2893
2900
  },
@@ -2895,7 +2902,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2895
2902
  }
2896
2903
  );
2897
2904
  }, Nr = () => {
2898
- const e = _("SubjectSearch", "Subject Search"), t = _("AdvanceFilter", "Advance Filter"), r = K(null), { getListTicket: s, setOpenFilter: a, loadingListTicket: c, countFilters: o } = ve();
2905
+ const e = _("SubjectSearch", "Subject Search"), t = _("AdvanceFilter", "Advance Filter"), r = K(null), { getListTicket: s, setOpenFilter: l, loadingListTicket: i, countFilters: o } = ve();
2899
2906
  return /* @__PURE__ */ n.jsx(n.Fragment, { children: /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8, marginBottom: 12 }, children: [
2900
2907
  /* @__PURE__ */ n.jsx(
2901
2908
  Be,
@@ -2912,111 +2919,111 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
2912
2919
  }
2913
2920
  ),
2914
2921
  /* @__PURE__ */ n.jsx(Se, { title: `${t} (${o})`, children: /* @__PURE__ */ n.jsx(Pt, { count: o, children: /* @__PURE__ */ n.jsx(
2915
- z,
2922
+ Y,
2916
2923
  {
2917
- loading: c,
2924
+ loading: i,
2918
2925
  icon: /* @__PURE__ */ n.jsx(P, { type: "filter" }),
2919
2926
  onClick: () => {
2920
- a(!0);
2927
+ l(!0);
2921
2928
  }
2922
2929
  }
2923
2930
  ) }) })
2924
2931
  ] }) });
2925
- }, Mr = R(Nr), vt = Te({}), he = () => ye(vt), Fr = ({ children: e }) => {
2926
- const t = K(null), r = K(0), s = K(!1), a = K(null), [c, o] = D([]), [d, i] = D(0), [u, f] = D(!1), { objInitPayload: x, parsedJWT: g, isFirstRenderHelpdesk: C, setShowReadyWSHD: y } = q(), j = mt(), p = (b) => {
2932
+ }, Mr = O(Nr), vt = Te({}), he = () => ye(vt), Fr = ({ children: e }) => {
2933
+ const t = K(null), r = K(0), s = K(!1), l = K(null), [i, o] = D([]), [d, c] = D(0), [u, f] = D(!1), { objInitPayload: x, parsedJWT: g, isFirstRenderHelpdesk: m, setShowReadyWSHD: T } = q(), w = Ct(), p = (b) => {
2927
2934
  const E = new WebSocket(b);
2928
2935
  E.onopen = () => {
2929
- s.current = !0, r.current = 0, i(0), y(!0);
2930
- }, E.onerror = (m) => {
2931
- y(!1), console.error(`${_e} - WebSocket error:`, m);
2932
- }, E.onclose = (m) => {
2936
+ s.current = !0, r.current = 0, c(0), T(!0);
2937
+ }, E.onerror = (C) => {
2938
+ T(!1), console.error(`${pe} - WebSocket error:`, C);
2939
+ }, E.onclose = (C) => {
2933
2940
  console.warn(
2934
- `${_e} - WebSocket disconnected:`,
2935
- m
2936
- ), s.current = !1, y(!1), !(m != null && m.wasClean) && (r == null ? void 0 : r.current) < Ie && (r.current += 1, i((k) => k + 1), clearTimeout(a.current), a.current = setTimeout(w, 2e3));
2941
+ `${pe} - WebSocket disconnected:`,
2942
+ C
2943
+ ), s.current = !1, T(!1), !(C != null && C.wasClean) && (r == null ? void 0 : r.current) < Ie && (r.current += 1, c((k) => k + 1), clearTimeout(l.current), l.current = setTimeout(j, 2e3));
2937
2944
  }, E.onmessage = v(E), t.current = E;
2938
- }, w = async () => {
2939
- var L, I, $;
2945
+ }, j = async () => {
2946
+ var L, H, $;
2940
2947
  if (((L = t.current) == null ? void 0 : L.readyState) === (WebSocket == null ? void 0 : WebSocket.CONNECTING)) return;
2941
2948
  const {
2942
2949
  access_token: b,
2943
2950
  companyid: E = "",
2944
- companycode: m = "",
2951
+ companycode: C = "",
2945
2952
  lang: k = "",
2946
2953
  uriBackendHRMGO: S = ""
2947
2954
  } = x ?? {};
2948
- if (!b || !E || !m) {
2955
+ if (!b || !E || !C) {
2949
2956
  console.warn(
2950
- `${_e} - Missing required WebSocket credentials.`
2957
+ `${pe} - Missing required WebSocket credentials.`
2951
2958
  );
2952
2959
  return;
2953
2960
  }
2954
- const H = `Bearer ${b}`, B = (I = `${S}/ws`) == null ? void 0 : I.replace("https://", "wss://"), M = {
2961
+ const F = `Bearer ${b}`, B = (H = `${S}/ws`) == null ? void 0 : H.replace("https://", "wss://"), M = {
2955
2962
  COMPANY_ID: E.toString(),
2956
- COMPANY_CODE: m.toLowerCase(),
2963
+ COMPANY_CODE: C.toLowerCase(),
2957
2964
  LANGUAGE: k,
2958
2965
  ACC_NAME: ($ = g == null ? void 0 : g.INSTANCE) == null ? void 0 : $.toLowerCase(),
2959
- TOKEN: H
2966
+ TOKEN: F
2960
2967
  };
2961
2968
  try {
2962
- const F = await Ss(
2969
+ const I = await Ss(
2963
2970
  M,
2964
2971
  js
2965
2972
  );
2966
- if (!F || s.current || (r == null ? void 0 : r.current) >= Ie) {
2973
+ if (!I || s.current || (r == null ? void 0 : r.current) >= Ie) {
2967
2974
  console.warn(
2968
- `${_e} - Skipping WebSocket connection attempt.`
2975
+ `${pe} - Skipping WebSocket connection attempt.`
2969
2976
  );
2970
2977
  return;
2971
2978
  }
2972
- t.current && t.current.close(), p(`${B}?t=${F}`);
2973
- } catch (F) {
2979
+ t.current && t.current.close(), p(`${B}?t=${I}`);
2980
+ } catch (I) {
2974
2981
  console.error(
2975
- `${_e} - Failed to encrypt token:`,
2976
- F
2982
+ `${pe} - Failed to encrypt token:`,
2983
+ I
2977
2984
  );
2978
2985
  }
2979
2986
  }, v = (b) => (E) => {
2980
- var m;
2987
+ var C;
2981
2988
  try {
2982
2989
  if ((E == null ? void 0 : E.data) === "PING")
2983
2990
  b.send("PONG");
2984
2991
  else {
2985
2992
  const { DATA: k, EVENT: S } = JSON.parse(E.data || "{}");
2986
- !C.current && S === "USER_ONLINE_NOTIF" && Array.isArray(k == null ? void 0 : k.EMPLOYEES) && (o((m = k == null ? void 0 : k.EMPLOYEES) == null ? void 0 : m.filter(Boolean)), C.current = !0), S === "TOKEN_EXPIRED" && j({
2993
+ !m.current && S === "USER_ONLINE_NOTIF" && Array.isArray(k == null ? void 0 : k.EMPLOYEES) && (o((C = k == null ? void 0 : k.EMPLOYEES) == null ? void 0 : C.filter(Boolean)), m.current = !0), S === "TOKEN_EXPIRED" && w({
2987
2994
  onSuccess: () => {
2988
- w();
2995
+ j();
2989
2996
  }
2990
2997
  });
2991
2998
  }
2992
2999
  } catch {
2993
3000
  console.error(
2994
- `${_e} - Invalid WebSocket message:`,
3001
+ `${pe} - Invalid WebSocket message:`,
2995
3002
  E.data
2996
3003
  );
2997
3004
  }
2998
- }, h = ({ event: b, data: E, module: m = "HELPDESK_CHAT" }) => {
3005
+ }, h = ({ event: b, data: E, module: C = "HELPDESK_CHAT" }) => {
2999
3006
  var k;
3000
3007
  (k = t == null ? void 0 : t.current) == null || k.send(
3001
3008
  JSON.stringify({
3002
3009
  EVENT: b,
3003
3010
  DATA: E,
3004
- MODULE: m
3011
+ MODULE: C
3005
3012
  })
3006
3013
  );
3007
3014
  };
3008
3015
  return X(() => {
3009
- C.current || w();
3016
+ m.current || j();
3010
3017
  }, []), /* @__PURE__ */ n.jsx(
3011
3018
  vt.Provider,
3012
3019
  {
3013
3020
  value: {
3014
3021
  ws: t == null ? void 0 : t.current,
3015
3022
  onSendMsg: h,
3016
- userOnline: c,
3017
- connectWebSocket: w,
3023
+ userOnline: i,
3024
+ connectWebSocket: j,
3018
3025
  retryCountState: d,
3019
- setRetryCountState: i,
3026
+ setRetryCountState: c,
3020
3027
  retryCountRef: r,
3021
3028
  isGetResponse: u,
3022
3029
  setGetResponse: f
@@ -3026,10 +3033,10 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3026
3033
  );
3027
3034
  }, Hr = () => {
3028
3035
  var d;
3029
- const { widgetProps: e } = q(), { listTicket: t, setTicketId: r, loadingListTicket: s } = ve(), { onSendMsg: a, setGetResponse: c } = he(), { xs: o } = Ce.useBreakpoint();
3036
+ const { widgetProps: e } = q(), { listTicket: t, setTicketId: r, loadingListTicket: s } = ve(), { onSendMsg: l, setGetResponse: i } = he(), { xs: o } = me.useBreakpoint();
3030
3037
  return /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
3031
3038
  /* @__PURE__ */ n.jsx(Mr, {}),
3032
- s ? /* @__PURE__ */ n.jsx("div", { style: { display: "flex", flexDirection: "column", gap: 8 }, children: (d = Array.from({ length: 5 })) == null ? void 0 : d.map((i, u) => /* @__PURE__ */ n.jsx(
3039
+ s ? /* @__PURE__ */ n.jsx("div", { style: { display: "flex", flexDirection: "column", gap: 8 }, children: (d = Array.from({ length: 5 })) == null ? void 0 : d.map((c, u) => /* @__PURE__ */ n.jsx(
3033
3040
  ue.Input,
3034
3041
  {
3035
3042
  style: { height: 80, width: "100%", borderRadius: 8 }
@@ -3042,18 +3049,18 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3042
3049
  ...(t == null ? void 0 : t.length) === 0 && {
3043
3050
  style: { justifyContent: "center" }
3044
3051
  },
3045
- children: (t == null ? void 0 : t.length) > 0 ? t == null ? void 0 : t.map((i, u) => /* @__PURE__ */ vn(
3052
+ children: (t == null ? void 0 : t.length) > 0 ? t == null ? void 0 : t.map((c, u) => /* @__PURE__ */ vn(
3046
3053
  Or,
3047
3054
  {
3048
- ...i,
3055
+ ...c,
3049
3056
  key: u,
3050
3057
  onClick: () => {
3051
- c(!0), a({
3058
+ i(!0), l({
3052
3059
  event: "JOIN_ROOM",
3053
3060
  data: {
3054
- TASK_ID: i == null ? void 0 : i.TASK_ID
3061
+ TASK_ID: c == null ? void 0 : c.TASK_ID
3055
3062
  }
3056
- }), r(i == null ? void 0 : i.TASK_ID);
3063
+ }), r(c == null ? void 0 : c.TASK_ID);
3057
3064
  }
3058
3065
  }
3059
3066
  )) : /* @__PURE__ */ n.jsx(
@@ -3071,19 +3078,19 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3071
3078
  }
3072
3079
  )
3073
3080
  ] });
3074
- }, Ir = R(Hr), $r = ({ children: e, open: t, onClose: r, footer: s, styleContainer: a }) => {
3081
+ }, Ir = O(Hr), $r = ({ children: e, open: t, onClose: r, footer: s, styleContainer: l }) => {
3075
3082
  var g;
3076
- const [c, o] = D(!1), d = K(), i = K(null), u = K(), f = O(() => t ? "w-fade-in-animate" : "w-fade-out-animate", [t]), x = (C) => {
3077
- C.code === "Escape" && !C.shiftKey && !C.altKey && !C.ctrlKey && C.key === "Escape" && (C.stopPropagation(), typeof r == "function" && r());
3083
+ const [i, o] = D(!1), d = K(), c = K(null), u = K(), f = R(() => t ? "w-fade-in-animate" : "w-fade-out-animate", [t]), x = (m) => {
3084
+ m.code === "Escape" && !m.shiftKey && !m.altKey && !m.ctrlKey && m.key === "Escape" && (m.stopPropagation(), typeof r == "function" && r());
3078
3085
  };
3079
3086
  return X(() => {
3080
- const C = u.current;
3081
- return C && (clearTimeout(i.current), i.current = setTimeout(() => {
3082
- C == null || C.focus();
3083
- }, 250), C == null || C.addEventListener("keydown", x)), t && o(!1), clearTimeout(d == null ? void 0 : d.current), d.current = setTimeout(() => {
3087
+ const m = u.current;
3088
+ return m && (clearTimeout(c.current), c.current = setTimeout(() => {
3089
+ m == null || m.focus();
3090
+ }, 250), m == null || m.addEventListener("keydown", x)), t && o(!1), clearTimeout(d == null ? void 0 : d.current), d.current = setTimeout(() => {
3084
3091
  t || o(!0);
3085
3092
  }, 300), () => {
3086
- C && (C == null || C.removeEventListener("keydown", x));
3093
+ m && (m == null || m.removeEventListener("keydown", x));
3087
3094
  };
3088
3095
  }, [t]), /* @__PURE__ */ n.jsxs(
3089
3096
  "div",
@@ -3092,10 +3099,10 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3092
3099
  tabIndex: 1,
3093
3100
  ref: u,
3094
3101
  style: {
3095
- display: c ? "none" : "block",
3102
+ display: i ? "none" : "block",
3096
3103
  height: "100%",
3097
- ...((g = Object == null ? void 0 : Object.keys(a || {})) == null ? void 0 : g.length) > 0 && {
3098
- ...a
3104
+ ...((g = Object == null ? void 0 : Object.keys(l || {})) == null ? void 0 : g.length) > 0 && {
3105
+ ...l
3099
3106
  }
3100
3107
  },
3101
3108
  children: [
@@ -3104,14 +3111,14 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3104
3111
  ]
3105
3112
  }
3106
3113
  );
3107
- }, ht = R($r), Et = Te({}), De = () => ye(Et), Br = ({ children: e }) => {
3108
- const [t, r] = D([]), [s, a] = D({}), [c, o] = D(!0), [d, i] = D({}), u = K(!1), f = en(), { ticketId: x } = ve(), { ws: g, setGetResponse: C } = he(), { parsedJWT: y } = q(), j = O(() => {
3114
+ }, ht = O($r), Et = Te({}), De = () => ye(Et), Br = ({ children: e }) => {
3115
+ const [t, r] = D([]), [s, l] = D({}), [i, o] = D(!0), [d, c] = D({}), u = K(!1), f = en(), { ticketId: x } = ve(), { ws: g, setGetResponse: m } = he(), { parsedJWT: T } = q(), w = R(() => {
3109
3116
  var S;
3110
- const b = (s == null ? void 0 : s.CREATED_BY) ?? {}, E = (s == null ? void 0 : s.ASSIGNEE) ?? {}, m = (s == null ? void 0 : s.OTHER_ASSIGNEE) ?? [], k = (S = [b, E, ...m].map((H) => ({
3111
- ...H
3112
- }))) == null ? void 0 : S.filter((H) => {
3117
+ const b = (s == null ? void 0 : s.CREATED_BY) ?? {}, E = (s == null ? void 0 : s.ASSIGNEE) ?? {}, C = (s == null ? void 0 : s.OTHER_ASSIGNEE) ?? [], k = (S = [b, E, ...C].map((F) => ({
3118
+ ...F
3119
+ }))) == null ? void 0 : S.filter((F) => {
3113
3120
  var B;
3114
- return ((B = Object.keys(H || {})) == null ? void 0 : B.length) > 0;
3121
+ return ((B = Object.keys(F || {})) == null ? void 0 : B.length) > 0;
3115
3122
  });
3116
3123
  return yn({ ArrObj: k, key: "EMP_ID" });
3117
3124
  }, [s]), p = () => {
@@ -3124,22 +3131,22 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3124
3131
  PAGE: 1,
3125
3132
  TASK_ID: x
3126
3133
  }
3127
- })) == null ? void 0 : b.then((m) => {
3128
- var k, S, H, B, M, L;
3129
- if (((H = (S = (k = m == null ? void 0 : m.data) == null ? void 0 : k.DATA) == null ? void 0 : S.LIST) == null ? void 0 : H.length) > 0) {
3130
- const I = (L = (M = (B = m == null ? void 0 : m.data) == null ? void 0 : B.DATA) == null ? void 0 : M.LIST) == null ? void 0 : L.map(($) => ({
3134
+ })) == null ? void 0 : b.then((C) => {
3135
+ var k, S, F, B, M, L;
3136
+ if (((F = (S = (k = C == null ? void 0 : C.data) == null ? void 0 : k.DATA) == null ? void 0 : S.LIST) == null ? void 0 : F.length) > 0) {
3137
+ const H = (L = (M = (B = C == null ? void 0 : C.data) == null ? void 0 : B.DATA) == null ? void 0 : M.LIST) == null ? void 0 : L.map(($) => ({
3131
3138
  ...$,
3132
3139
  ACTOR: {
3133
3140
  ...$ == null ? void 0 : $.ACTOR
3134
3141
  }
3135
3142
  }));
3136
- r(Qe(I));
3143
+ r(Qe(H));
3137
3144
  } else
3138
3145
  r({});
3139
3146
  })) == null || E.finally(() => {
3140
3147
  o(!1);
3141
3148
  });
3142
- }, w = () => {
3149
+ }, j = () => {
3143
3150
  var b;
3144
3151
  (b = f({
3145
3152
  endpoint: "/helpdesk/myticket/get",
@@ -3148,30 +3155,30 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3148
3155
  TASK_ID: x
3149
3156
  }
3150
3157
  })) == null || b.then((E) => {
3151
- var m, k, S;
3152
- if ((m = E == null ? void 0 : E.data) != null && m.DATA) {
3153
- const H = (S = (k = E == null ? void 0 : E.data) == null ? void 0 : k.DATA) == null ? void 0 : S.LIST;
3154
- a(H);
3158
+ var C, k, S;
3159
+ if ((C = E == null ? void 0 : E.data) != null && C.DATA) {
3160
+ const F = (S = (k = E == null ? void 0 : E.data) == null ? void 0 : k.DATA) == null ? void 0 : S.LIST;
3161
+ l(F);
3155
3162
  } else
3156
- a({});
3163
+ l({});
3157
3164
  });
3158
3165
  }, v = (b) => {
3159
3166
  var k;
3160
- const E = (k = b == null ? void 0 : b.ACTOR) == null ? void 0 : k.EMP_ID, m = y == null ? void 0 : y.EMP_ID;
3161
- C(!0), i((S) => ({
3167
+ const E = (k = b == null ? void 0 : b.ACTOR) == null ? void 0 : k.EMP_ID, C = T == null ? void 0 : T.EMP_ID;
3168
+ m(!0), c((S) => ({
3162
3169
  ...S,
3163
3170
  [E]: !1
3164
3171
  })), u.current || r((S) => {
3165
- const H = jn(S), B = E == m ? "to" : "from", M = [...H, { ...b, CHAT_ALIGN: B }];
3172
+ const F = jn(S), B = E == C ? "to" : "from", M = [...F, { ...b, CHAT_ALIGN: B }];
3166
3173
  return Qe(M);
3167
3174
  }), u.current = !1;
3168
3175
  }, h = (b) => {
3169
3176
  if ((b == null ? void 0 : b.data) !== "PING") {
3170
- const E = JSON.parse((b == null ? void 0 : b.data) || "{}"), { DATA: m = {}, EVENT: k = "" } = E ?? {};
3171
- (k === "RECEIVE_MESSAGE" || k === "RECEIVE_ANOTHER_MESSAGE") && v(m);
3177
+ const E = JSON.parse((b == null ? void 0 : b.data) || "{}"), { DATA: C = {}, EVENT: k = "" } = E ?? {};
3178
+ (k === "RECEIVE_MESSAGE" || k === "RECEIVE_ANOTHER_MESSAGE") && v(C);
3172
3179
  }
3173
3180
  };
3174
- return X(() => (x && (p(), w()), g && x && (g == null || g.addEventListener("message", h)), () => {
3181
+ return X(() => (x && (p(), j()), g && x && (g == null || g.addEventListener("message", h)), () => {
3175
3182
  g && x && (g == null || g.removeEventListener("message", h));
3176
3183
  }), [x]), /* @__PURE__ */ n.jsx(
3177
3184
  Et.Provider,
@@ -3180,21 +3187,21 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3180
3187
  chats: t,
3181
3188
  setChats: r,
3182
3189
  detailTicket: s,
3183
- employees: j,
3190
+ employees: w,
3184
3191
  isFromSelf: u,
3185
- loadingChats: c,
3192
+ loadingChats: i,
3186
3193
  objTypingOtherEmp: d,
3187
- setTypingOtherEmp: i
3194
+ setTypingOtherEmp: c
3188
3195
  },
3189
3196
  children: e
3190
3197
  }
3191
3198
  );
3192
3199
  }, Ur = ({ onClose: e }) => {
3193
- const { xs: t } = Ce.useBreakpoint(), { employees: r, detailTicket: s, loadingChats: a } = De(), { userOnline: c } = he(), o = O(() => {
3194
- var i;
3195
- return (i = r == null ? void 0 : r.map((u) => u == null ? void 0 : u.FULL_NAME)) == null ? void 0 : i.join(", ");
3196
- }, [r]), d = O(() => t ? "click" : "hover", [t]);
3197
- return a ? /* @__PURE__ */ n.jsxs("div", { className: "w-ticket-detail-header-container", children: [
3200
+ const { xs: t } = me.useBreakpoint(), { employees: r, detailTicket: s, loadingChats: l } = De(), { userOnline: i } = he(), o = R(() => {
3201
+ var c;
3202
+ return (c = r == null ? void 0 : r.map((u) => u == null ? void 0 : u.FULL_NAME)) == null ? void 0 : c.join(", ");
3203
+ }, [r]), d = R(() => t ? "click" : "hover", [t]);
3204
+ return l ? /* @__PURE__ */ n.jsxs("div", { className: "w-ticket-detail-header-container", children: [
3198
3205
  /* @__PURE__ */ n.jsx(ue.Avatar, {}),
3199
3206
  /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: 8 }, children: [
3200
3207
  /* @__PURE__ */ n.jsx(ue.Input, {}),
@@ -3204,7 +3211,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3204
3211
  ] }) : /* @__PURE__ */ n.jsxs("div", { className: "w-ticket-detail-header-container", children: [
3205
3212
  /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8 }, children: [
3206
3213
  /* @__PURE__ */ n.jsx(
3207
- z,
3214
+ Y,
3208
3215
  {
3209
3216
  icon: /* @__PURE__ */ n.jsx(P, { type: "down" }),
3210
3217
  style: { border: "none" },
@@ -3223,9 +3230,9 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3223
3230
  backgroundColor: "#fde3cf",
3224
3231
  cursor: "pointer"
3225
3232
  },
3226
- children: r == null ? void 0 : r.map((i, u) => {
3227
- const f = c == null ? void 0 : c.includes(i == null ? void 0 : i.EMP_ID);
3228
- return /* @__PURE__ */ n.jsx(Se, { title: i == null ? void 0 : i.FULL_NAME, trigger: d, children: /* @__PURE__ */ vn(
3233
+ children: r == null ? void 0 : r.map((c, u) => {
3234
+ const f = i == null ? void 0 : i.includes(c == null ? void 0 : c.EMP_ID);
3235
+ return /* @__PURE__ */ n.jsx(Se, { title: c == null ? void 0 : c.FULL_NAME, trigger: d, children: /* @__PURE__ */ vn(
3229
3236
  Ee,
3230
3237
  {
3231
3238
  ...f && {
@@ -3234,9 +3241,9 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3234
3241
  borderRadius: "50%"
3235
3242
  }
3236
3243
  },
3237
- src: i == null ? void 0 : i.PHOTO,
3244
+ src: c == null ? void 0 : c.PHOTO,
3238
3245
  key: u,
3239
- nameFallback: i == null ? void 0 : i.FULL_NAME
3246
+ nameFallback: c == null ? void 0 : c.FULL_NAME
3240
3247
  }
3241
3248
  ) }, u);
3242
3249
  })
@@ -3248,7 +3255,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3248
3255
  {
3249
3256
  title: `${s == null ? void 0 : s.TASK_CODE} - ${s == null ? void 0 : s.SUBJECT}`,
3250
3257
  trigger: d,
3251
- children: /* @__PURE__ */ n.jsxs(V.Text, { className: "w-ticket-detail-header-text", children: [
3258
+ children: /* @__PURE__ */ n.jsxs(G.Text, { className: "w-ticket-detail-header-text", children: [
3252
3259
  s == null ? void 0 : s.TASK_CODE,
3253
3260
  " - ",
3254
3261
  s == null ? void 0 : s.SUBJECT
@@ -3256,7 +3263,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3256
3263
  }
3257
3264
  ),
3258
3265
  /* @__PURE__ */ n.jsx(Se, { title: o, trigger: d, children: /* @__PURE__ */ n.jsx(
3259
- V.Text,
3266
+ G.Text,
3260
3267
  {
3261
3268
  type: "secondary",
3262
3269
  className: "w-ticket-detail-header-text",
@@ -3268,10 +3275,10 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3268
3275
  ) })
3269
3276
  ] })
3270
3277
  ] }),
3271
- /* @__PURE__ */ n.jsx(Ct, { taskStatus: s == null ? void 0 : s.STATUS })
3278
+ /* @__PURE__ */ n.jsx(mt, { taskStatus: s == null ? void 0 : s.STATUS })
3272
3279
  ] });
3273
- }, Wr = R(Ur), Vr = ({ ...e }) => {
3274
- const t = O(() => (e == null ? void 0 : e.CHAT_ALIGN) === "to" ? "client" : "response", [e]);
3280
+ }, Wr = O(Ur), Vr = ({ ...e }) => {
3281
+ const t = R(() => (e == null ? void 0 : e.CHAT_ALIGN) === "to" ? "client" : "response", [e]);
3275
3282
  return /* @__PURE__ */ n.jsxs("div", { className: `w-bubble-chat ${`w-${t}`}`, children: [
3276
3283
  /* @__PURE__ */ n.jsx(
3277
3284
  "p",
@@ -3290,25 +3297,25 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3290
3297
  }
3291
3298
  )
3292
3299
  ] });
3293
- }, Gr = R(Vr), zr = ({ ...e }) => {
3294
- const t = _("Download", "Download"), r = O(() => (e == null ? void 0 : e.CHAT_ALIGN) === "to" ? "client" : "response", [e]), s = O(() => {
3295
- var i;
3300
+ }, Gr = O(Vr), zr = ({ ...e }) => {
3301
+ const t = _("Download", "Download"), r = R(() => (e == null ? void 0 : e.CHAT_ALIGN) === "to" ? "client" : "response", [e]), s = R(() => {
3302
+ var c;
3296
3303
  const d = e == null ? void 0 : e.ATTACHMENT;
3297
3304
  if (d)
3298
3305
  try {
3299
- const u = new URL(d), f = (i = u == null ? void 0 : u.pathname) == null ? void 0 : i.split("/");
3306
+ const u = new URL(d), f = (c = u == null ? void 0 : u.pathname) == null ? void 0 : c.split("/");
3300
3307
  return f == null ? void 0 : f[(f == null ? void 0 : f.length) - 1];
3301
3308
  } catch {
3302
3309
  return d;
3303
3310
  }
3304
3311
  return "";
3305
- }, [e]), a = O(() => {
3312
+ }, [e]), l = R(() => {
3306
3313
  if (s != null && s.includes(".")) {
3307
3314
  const d = s == null ? void 0 : s.split(".");
3308
3315
  return `.${d == null ? void 0 : d[(d == null ? void 0 : d.length) - 1]}`;
3309
3316
  }
3310
3317
  return "";
3311
- }, [e, s]), c = O(() => dn == null ? void 0 : dn.includes(a), [e, a]), o = () => {
3318
+ }, [e, s]), i = R(() => dn == null ? void 0 : dn.includes(l), [e, l]), o = () => {
3312
3319
  Tn({
3313
3320
  downloadURL: e == null ? void 0 : e.ATTACHMENT,
3314
3321
  fileName: s,
@@ -3321,10 +3328,10 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3321
3328
  className: `w-bubble-chat ${`w-${r}`}`,
3322
3329
  style: { display: "flex", flexDirection: "column" },
3323
3330
  children: [
3324
- c ? /* @__PURE__ */ n.jsx(kn, { src: e == null ? void 0 : e.ATTACHMENT, fallback: ys }) : /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8, alignItems: "center" }, children: [
3331
+ i ? /* @__PURE__ */ n.jsx(kn, { src: e == null ? void 0 : e.ATTACHMENT, fallback: ys }) : /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8, alignItems: "center" }, children: [
3325
3332
  /* @__PURE__ */ n.jsx(P, { type: "file" }),
3326
3333
  /* @__PURE__ */ n.jsx(
3327
- V.Link,
3334
+ G.Link,
3328
3335
  {
3329
3336
  onClick: o,
3330
3337
  style: { display: "block", width: 160 },
@@ -3332,8 +3339,8 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3332
3339
  }
3333
3340
  )
3334
3341
  ] }),
3335
- c && /* @__PURE__ */ n.jsx(
3336
- z,
3342
+ i && /* @__PURE__ */ n.jsx(
3343
+ Y,
3337
3344
  {
3338
3345
  onClick: o,
3339
3346
  style: {
@@ -3358,8 +3365,8 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3358
3365
  ]
3359
3366
  }
3360
3367
  ) });
3361
- }, Yr = R(zr), Kr = ({ ...e }) => {
3362
- const t = O(() => (e == null ? void 0 : e.CHAT_ALIGN) === "to" ? "client" : "response", [e]);
3368
+ }, Yr = O(zr), Kr = ({ ...e }) => {
3369
+ const t = R(() => (e == null ? void 0 : e.CHAT_ALIGN) === "to" ? "client" : "response", [e]);
3363
3370
  return /* @__PURE__ */ n.jsxs("div", { className: "w-ticket-info-chat-container", children: [
3364
3371
  /* @__PURE__ */ n.jsx(
3365
3372
  We,
@@ -3369,9 +3376,9 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3369
3376
  sender: t
3370
3377
  }
3371
3378
  ),
3372
- /* @__PURE__ */ n.jsx(V.Text, { children: e == null ? void 0 : e.MESSAGE })
3379
+ /* @__PURE__ */ n.jsx(G.Text, { children: e == null ? void 0 : e.MESSAGE })
3373
3380
  ] });
3374
- }, qr = R(Kr), Tt = () => {
3381
+ }, qr = O(Kr), Tt = () => {
3375
3382
  const { widgetProps: e } = q(), t = ke.enc.Hex.parse(
3376
3383
  ke.enc.Utf8.parse(e == null ? void 0 : e.keyEncrypt).toString()
3377
3384
  ), r = {
@@ -3379,25 +3386,25 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3379
3386
  padding: ke.pad.Pkcs7
3380
3387
  }, s = /Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini|GreatDayHR/i.test(
3381
3388
  navigator.userAgent
3382
- ), a = (o) => {
3389
+ ), l = (o) => {
3383
3390
  if (typeof o == "number" && (o = o.toString()), !o) return "";
3384
3391
  if (s) return window.encodeURIComponent(o);
3385
- const d = ke.enc.Utf8.parse(o), i = ke.AES.encrypt(
3392
+ const d = ke.enc.Utf8.parse(o), c = ke.AES.encrypt(
3386
3393
  d,
3387
3394
  t,
3388
3395
  r
3389
3396
  ).toString();
3390
- return window.encodeURIComponent(`$${i}`);
3397
+ return window.encodeURIComponent(`$${c}`);
3391
3398
  };
3392
3399
  return {
3393
3400
  paramsEncrypt: (o) => {
3394
- const [d, i = null] = o.split("?"), u = d.split("/").map((f) => {
3401
+ const [d, c = null] = o.split("?"), u = d.split("/").map((f) => {
3395
3402
  const [, x = null] = f.split(":");
3396
- return x && (e != null && e.keyEncrypt) ? a(x) : f;
3403
+ return x && (e != null && e.keyEncrypt) ? l(x) : f;
3397
3404
  }).join("/");
3398
- return i ? `${u}?${i}` : u;
3405
+ return c ? `${u}?${c}` : u;
3399
3406
  },
3400
- encrypt: a
3407
+ encrypt: l
3401
3408
  };
3402
3409
  }, Jr = ({ ...e }) => {
3403
3410
  const t = _("ViewFAQ", "View FAQ"), r = _(
@@ -3406,10 +3413,10 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3406
3413
  ), s = _(
3407
3414
  "ThisFAQIsUnavailable",
3408
3415
  "This FAQ is unavailable"
3409
- ), { paramsEncrypt: a } = Tt(), { widgetProps: c } = q(), o = O(() => (e == null ? void 0 : e.CHAT_ALIGN) === "to" ? "client" : "response", [e]), d = O(() => e == null ? void 0 : e.FAQ_ID, [e]);
3416
+ ), { paramsEncrypt: l } = Tt(), { widgetProps: i } = q(), o = R(() => (e == null ? void 0 : e.CHAT_ALIGN) === "to" ? "client" : "response", [e]), d = R(() => e == null ? void 0 : e.FAQ_ID, [e]);
3410
3417
  return /* @__PURE__ */ n.jsxs("div", { className: `w-bubble-chat ${`w-${o}`}`, children: [
3411
3418
  /* @__PURE__ */ n.jsx(
3412
- V.Text,
3419
+ G.Text,
3413
3420
  {
3414
3421
  style: {
3415
3422
  backgroundColor: "rgb(244, 245, 246)",
@@ -3423,18 +3430,18 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3423
3430
  }
3424
3431
  ),
3425
3432
  d ? /* @__PURE__ */ n.jsx(
3426
- z,
3433
+ Y,
3427
3434
  {
3428
3435
  block: !0,
3429
3436
  onClick: () => {
3430
- var i;
3431
- typeof (c == null ? void 0 : c.history) < "u" && ((i = c == null ? void 0 : c.history) == null || i.push(
3432
- a(`/standard/hrm.helpdesk.FAQ-detail/:${d}`)
3437
+ var c;
3438
+ typeof (i == null ? void 0 : i.history) < "u" && ((c = i == null ? void 0 : i.history) == null || c.push(
3439
+ l(`/standard/hrm.helpdesk.FAQ-detail/:${d}`)
3433
3440
  ));
3434
3441
  },
3435
3442
  children: t
3436
3443
  }
3437
- ) : /* @__PURE__ */ n.jsx(V.Text, { children: s }),
3444
+ ) : /* @__PURE__ */ n.jsx(G.Text, { children: s }),
3438
3445
  /* @__PURE__ */ n.jsx(
3439
3446
  We,
3440
3447
  {
@@ -3444,7 +3451,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3444
3451
  }
3445
3452
  )
3446
3453
  ] });
3447
- }, Qr = R(Jr), Zr = ({ ...e }) => {
3454
+ }, Qr = O(Jr), Zr = ({ ...e }) => {
3448
3455
  switch (e == null ? void 0 : e.CHAT_TYPE) {
3449
3456
  case "info":
3450
3457
  return /* @__PURE__ */ n.jsx(qr, { ...e });
@@ -3455,42 +3462,42 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3455
3462
  default:
3456
3463
  return null;
3457
3464
  }
3458
- }, Xr = R(Zr), Pr = () => {
3459
- var y;
3460
- const [e, t] = D([]), r = _("And", "and"), s = _("IsTyping", "Is Typing"), a = _("People", "People"), { employees: c, setTypingOtherEmp: o, objTypingOtherEmp: d } = De(), { ws: i, setGetResponse: u } = he(), { parsedJWT: f } = q(), x = O(() => e == null ? void 0 : e.filter((j) => d == null ? void 0 : d[j == null ? void 0 : j.EMP_ID]), [d, e]), g = O(() => {
3461
- const j = x == null ? void 0 : x.map((p) => p == null ? void 0 : p.FULL_NAME);
3465
+ }, Xr = O(Zr), Pr = () => {
3466
+ var T;
3467
+ const [e, t] = D([]), r = _("And", "and"), s = _("IsTyping", "Is Typing"), l = _("People", "People"), { employees: i, setTypingOtherEmp: o, objTypingOtherEmp: d } = De(), { ws: c, setGetResponse: u } = he(), { parsedJWT: f } = q(), x = R(() => e == null ? void 0 : e.filter((w) => d == null ? void 0 : d[w == null ? void 0 : w.EMP_ID]), [d, e]), g = R(() => {
3468
+ const w = x == null ? void 0 : x.map((p) => p == null ? void 0 : p.FULL_NAME);
3462
3469
  if ((x == null ? void 0 : x.length) > 2) {
3463
- const p = j == null ? void 0 : j.filter((v, h) => h <= 1), w = j == null ? void 0 : j.filter((v, h) => h > 1);
3464
- return `${p == null ? void 0 : p.join(", ")}, ${r} ${w == null ? void 0 : w.length} ${a} ${s}`;
3470
+ const p = w == null ? void 0 : w.filter((v, h) => h <= 1), j = w == null ? void 0 : w.filter((v, h) => h > 1);
3471
+ return `${p == null ? void 0 : p.join(", ")}, ${r} ${j == null ? void 0 : j.length} ${l} ${s}`;
3465
3472
  }
3466
- return `${j == null ? void 0 : j.join(", ")} ${s}`;
3467
- }, [e, x]), C = (j) => {
3468
- if ((j == null ? void 0 : j.data) !== "PING") {
3469
- const p = JSON.parse((j == null ? void 0 : j.data) || "{}"), { DATA: w = {}, EVENT: v = "" } = p ?? {}, h = w == null ? void 0 : w.EMPLOYEE_ID, b = f == null ? void 0 : f.EMP_ID;
3473
+ return `${w == null ? void 0 : w.join(", ")} ${s}`;
3474
+ }, [e, x]), m = (w) => {
3475
+ if ((w == null ? void 0 : w.data) !== "PING") {
3476
+ const p = JSON.parse((w == null ? void 0 : w.data) || "{}"), { DATA: j = {}, EVENT: v = "" } = p ?? {}, h = j == null ? void 0 : j.EMPLOYEE_ID, b = f == null ? void 0 : f.EMP_ID;
3470
3477
  if (v === "TYPING") {
3471
3478
  h === b ? u(!1) : o((k) => ({
3472
3479
  ...k,
3473
- [h]: w == null ? void 0 : w.IS_TYPING
3480
+ [h]: j == null ? void 0 : j.IS_TYPING
3474
3481
  }));
3475
- const E = c == null ? void 0 : c.find(
3476
- (k) => (k == null ? void 0 : k.EMP_ID) === (w == null ? void 0 : w.EMPLOYEE_ID)
3477
- ), m = {
3478
- ...w,
3482
+ const E = i == null ? void 0 : i.find(
3483
+ (k) => (k == null ? void 0 : k.EMP_ID) === (j == null ? void 0 : j.EMPLOYEE_ID)
3484
+ ), C = {
3485
+ ...j,
3479
3486
  ...E
3480
3487
  };
3481
3488
  t((k) => {
3482
- const S = [...k, m], H = yn({
3489
+ const S = [...k, C], F = yn({
3483
3490
  ArrObj: S,
3484
3491
  key: "EMPLOYEE_ID"
3485
3492
  });
3486
- return H == null ? void 0 : H.filter((B) => B == null ? void 0 : B.IS_TYPING);
3493
+ return F == null ? void 0 : F.filter((B) => B == null ? void 0 : B.IS_TYPING);
3487
3494
  });
3488
3495
  }
3489
3496
  }
3490
3497
  };
3491
- return X(() => (i && (i == null || i.addEventListener("message", C)), () => {
3492
- i && (i == null || i.removeEventListener("message", C));
3493
- }), [c]), (y = Object.values(d || {})) != null && y.every((j) => j === !1) ? null : /* @__PURE__ */ n.jsxs(
3498
+ return X(() => (c && (c == null || c.addEventListener("message", m)), () => {
3499
+ c && (c == null || c.removeEventListener("message", m));
3500
+ }), [i]), (T = Object.values(d || {})) != null && T.every((w) => w === !1) ? null : /* @__PURE__ */ n.jsxs(
3494
3501
  "div",
3495
3502
  {
3496
3503
  style: {
@@ -3509,40 +3516,40 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3509
3516
  backgroundColor: "#fde3cf",
3510
3517
  cursor: "pointer"
3511
3518
  },
3512
- children: x == null ? void 0 : x.map((j, p) => /* @__PURE__ */ n.jsx(Se, { title: j == null ? void 0 : j.FULL_NAME, children: /* @__PURE__ */ n.jsx(Ee, { src: j == null ? void 0 : j.PHOTO, nameFallback: j == null ? void 0 : j.FULL_NAME }) }, p))
3519
+ children: x == null ? void 0 : x.map((w, p) => /* @__PURE__ */ n.jsx(Se, { title: w == null ? void 0 : w.FULL_NAME, children: /* @__PURE__ */ n.jsx(Ee, { src: w == null ? void 0 : w.PHOTO, nameFallback: w == null ? void 0 : w.FULL_NAME }) }, p))
3513
3520
  }
3514
3521
  ),
3515
- /* @__PURE__ */ n.jsx(V.Text, { children: g }),
3522
+ /* @__PURE__ */ n.jsx(G.Text, { children: g }),
3516
3523
  (x == null ? void 0 : x.length) > 0 ? /* @__PURE__ */ n.jsx(gt, {}) : null
3517
3524
  ]
3518
3525
  }
3519
3526
  );
3520
- }, eo = R(Pr), no = () => {
3521
- var c;
3522
- const { chats: e } = De(), { widgetProps: t } = q(), { activeTab: r } = be(), s = K(), { xs: a } = Ce.useBreakpoint();
3527
+ }, eo = O(Pr), no = () => {
3528
+ var i;
3529
+ const { chats: e } = De(), { widgetProps: t } = q(), { activeTab: r } = be(), s = K(), { xs: l } = me.useBreakpoint();
3523
3530
  return X(() => {
3524
3531
  clearTimeout(s.current), s.current = setTimeout(() => {
3525
- me(".w-ticket-detail-content-container");
3532
+ Ce(".w-ticket-detail-content-container");
3526
3533
  }, 350);
3527
3534
  }, [r]), /* @__PURE__ */ n.jsxs(
3528
3535
  "div",
3529
3536
  {
3530
- className: `w-ticket-detail-content-container ${a ? t != null && t.isSF ? "w-ticket-detail-content-container-sf-mobile" : "w-ticket-detail-content-container-mobile" : ""} `,
3537
+ className: `w-ticket-detail-content-container ${l ? t != null && t.isSF ? "w-ticket-detail-content-container-sf-mobile" : "w-ticket-detail-content-container-mobile" : ""} `,
3531
3538
  children: [
3532
- (c = Object.keys(e || {})) == null ? void 0 : c.map((o) => {
3533
- var i, u;
3539
+ (i = Object.keys(e || {})) == null ? void 0 : i.map((o) => {
3540
+ var c, u;
3534
3541
  const d = e == null ? void 0 : e[o];
3535
- return /* @__PURE__ */ n.jsxs(Cn, { children: [
3536
- /* @__PURE__ */ n.jsx("div", { className: "w-datekey-chats", children: (i = ae(o)) == null ? void 0 : i.format("ddd, DD MMMM YYYY") }),
3542
+ return /* @__PURE__ */ n.jsxs(mn, { children: [
3543
+ /* @__PURE__ */ n.jsx("div", { className: "w-datekey-chats", children: (c = ae(o)) == null ? void 0 : c.format("ddd, DD MMMM YYYY") }),
3537
3544
  /* @__PURE__ */ n.jsx("div", { className: "w-bubble-chat-container", children: (u = ct(d)) == null ? void 0 : u.map((f, x) => {
3538
- var y, j;
3539
- const g = (f == null ? void 0 : f.CHAT_ALIGN) === "to" ? "client" : "response", C = f == null ? void 0 : f.CHAT_TYPE;
3540
- return /* @__PURE__ */ n.jsxs(Cn, { children: [
3541
- g === "response" && C !== "info" && /* @__PURE__ */ n.jsx(
3545
+ var T, w;
3546
+ const g = (f == null ? void 0 : f.CHAT_ALIGN) === "to" ? "client" : "response", m = f == null ? void 0 : f.CHAT_TYPE;
3547
+ return /* @__PURE__ */ n.jsxs(mn, { children: [
3548
+ g === "response" && m !== "info" && /* @__PURE__ */ n.jsx(
3542
3549
  Ue,
3543
3550
  {
3544
- src: (y = f == null ? void 0 : f.ACTOR) == null ? void 0 : y.PHOTO,
3545
- name: (j = f == null ? void 0 : f.ACTOR) == null ? void 0 : j.FULL_NAME
3551
+ src: (T = f == null ? void 0 : f.ACTOR) == null ? void 0 : T.PHOTO,
3552
+ name: (w = f == null ? void 0 : f.ACTOR) == null ? void 0 : w.FULL_NAME
3546
3553
  }
3547
3554
  ),
3548
3555
  /* @__PURE__ */ n.jsx(Xr, { ...f })
@@ -3554,21 +3561,21 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3554
3561
  ]
3555
3562
  }
3556
3563
  );
3557
- }, to = R(no), so = () => {
3558
- var c, o;
3559
- const { chats: e, loadingChats: t } = De(), { widgetProps: r } = q(), { xs: s } = Ce.useBreakpoint(), a = O(() => {
3560
- var i;
3564
+ }, to = O(no), so = () => {
3565
+ var i, o;
3566
+ const { chats: e, loadingChats: t } = De(), { widgetProps: r } = q(), { xs: s } = me.useBreakpoint(), l = R(() => {
3567
+ var c;
3561
3568
  const d = [fn];
3562
3569
  return s && (r != null && r.isSF ? d == null || d.push(
3563
3570
  `${fn}-sf-mobile`
3564
- ) : d == null || d.push(`${fn}-mobile`)), (i = d == null ? void 0 : d.filter(Boolean)) == null ? void 0 : i.join(" ");
3571
+ ) : d == null || d.push(`${fn}-mobile`)), (c = d == null ? void 0 : d.filter(Boolean)) == null ? void 0 : c.join(" ");
3565
3572
  }, [s, r == null ? void 0 : r.isSF]);
3566
3573
  return t ? /* @__PURE__ */ n.jsx(
3567
3574
  "div",
3568
3575
  {
3569
- className: `${a} w-ticket-detail-loading-chats`,
3570
- children: (c = Array.from({ length: 3 })) == null ? void 0 : c.map((d, i) => {
3571
- const u = i % 2 === 0;
3576
+ className: `${l} w-ticket-detail-loading-chats`,
3577
+ children: (i = Array.from({ length: 3 })) == null ? void 0 : i.map((d, c) => {
3578
+ const u = c % 2 === 0;
3572
3579
  return /* @__PURE__ */ n.jsxs(
3573
3580
  "div",
3574
3581
  {
@@ -3603,14 +3610,14 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3603
3610
  )
3604
3611
  ]
3605
3612
  },
3606
- i
3613
+ c
3607
3614
  );
3608
3615
  })
3609
3616
  }
3610
3617
  ) : ((o = Object.keys(e || {})) == null ? void 0 : o.length) === 0 ? /* @__PURE__ */ n.jsx(
3611
3618
  "div",
3612
3619
  {
3613
- className: a,
3620
+ className: l,
3614
3621
  style: {
3615
3622
  display: "flex",
3616
3623
  justifyContent: "center",
@@ -3619,7 +3626,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3619
3626
  children: /* @__PURE__ */ n.jsx(et, {})
3620
3627
  }
3621
3628
  ) : /* @__PURE__ */ n.jsx(to, {});
3622
- }, ro = R(so), oo = ({ ...e }) => {
3629
+ }, ro = O(so), oo = ({ ...e }) => {
3623
3630
  const t = K(0);
3624
3631
  return /* @__PURE__ */ n.jsxs(
3625
3632
  "div",
@@ -3645,23 +3652,23 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3645
3652
  }
3646
3653
  ),
3647
3654
  /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: 8 }, children: [
3648
- /* @__PURE__ */ n.jsx(V.Text, { strong: !0, style: { fontSize: 18 }, children: e == null ? void 0 : e.FULL_NAME }),
3649
- /* @__PURE__ */ n.jsx(V.Text, { children: e == null ? void 0 : e.POSITION_NAME }, e == null ? void 0 : e.POSITION_NAME),
3650
- /* @__PURE__ */ n.jsx(V.Text, { children: e == null ? void 0 : e.DEPT_NAME }),
3651
- /* @__PURE__ */ n.jsx(V.Text, { children: e == null ? void 0 : e.WORKLOCATION })
3655
+ /* @__PURE__ */ n.jsx(G.Text, { strong: !0, style: { fontSize: 18 }, children: e == null ? void 0 : e.FULL_NAME }),
3656
+ /* @__PURE__ */ n.jsx(G.Text, { children: e == null ? void 0 : e.POSITION_NAME }, e == null ? void 0 : e.POSITION_NAME),
3657
+ /* @__PURE__ */ n.jsx(G.Text, { children: e == null ? void 0 : e.DEPT_NAME }),
3658
+ /* @__PURE__ */ n.jsx(G.Text, { children: e == null ? void 0 : e.WORKLOCATION })
3652
3659
  ] })
3653
3660
  ]
3654
3661
  }
3655
3662
  );
3656
- }, co = R(oo), io = ({ setLoadingUpload: e, isLoadingUpload: t }) => {
3657
- var w, v;
3658
- const r = en(), [s, a] = D({}), c = K(null), o = _(
3663
+ }, co = O(oo), io = ({ setLoadingUpload: e, isLoadingUpload: t }) => {
3664
+ var j, v;
3665
+ const r = en(), [s, l] = D({}), i = K(null), o = _(
3659
3666
  "ImageMustSmallerThan",
3660
3667
  "Image must smaller than"
3661
3668
  ), d = _(
3662
3669
  "MaximumFileSizeExceeded",
3663
3670
  "Maximum file size exceeded"
3664
- ), { onSendMsg: i } = he(), { employees: u, setChats: f, isFromSelf: x } = De(), { ticketId: g } = ve(), { activeTab: C } = be(), y = () => {
3671
+ ), { onSendMsg: c } = he(), { employees: u, setChats: f, isFromSelf: x } = De(), { ticketId: g } = ve(), { activeTab: m } = be(), T = () => {
3665
3672
  var h;
3666
3673
  (h = r({
3667
3674
  endpoint: "/upload/get-upload-config",
@@ -3673,14 +3680,14 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3673
3680
  }
3674
3681
  }
3675
3682
  })) == null || h.then((b) => {
3676
- var m, k;
3677
- const E = (k = (m = b == null ? void 0 : b.data) == null ? void 0 : m.DATA) == null ? void 0 : k.LIST;
3678
- (E == null ? void 0 : E.length) > 0 && a(E == null ? void 0 : E[0]);
3683
+ var C, k;
3684
+ const E = (k = (C = b == null ? void 0 : b.data) == null ? void 0 : C.DATA) == null ? void 0 : k.LIST;
3685
+ (E == null ? void 0 : E.length) > 0 && l(E == null ? void 0 : E[0]);
3679
3686
  });
3680
- }, j = (h) => {
3681
- var m, k, S;
3687
+ }, w = (h) => {
3688
+ var C, k, S;
3682
3689
  const b = h.size / 1024 / 1024, E = (s == null ? void 0 : s.MAXFILESIZE) / 1024;
3683
- return b > E && ((m = ie) == null || m.destroy(), (k = ie) == null || k.config({
3690
+ return b > E && ((C = ie) == null || C.destroy(), (k = ie) == null || k.config({
3684
3691
  getContainer: () => document.querySelector(".w-widget-content-container"),
3685
3692
  top: 28,
3686
3693
  placement: "top"
@@ -3693,62 +3700,62 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3693
3700
  duration: 3
3694
3701
  })), !1;
3695
3702
  }, p = (h) => {
3696
- var E, m;
3703
+ var E, C;
3697
3704
  e(!0);
3698
3705
  const b = new FormData();
3699
- b.append("UPLOAD_CODE", s == null ? void 0 : s.UPLOAD_CODE), b.append("UPLOAD_TYPE", s == null ? void 0 : s.UPLOAD_TYPE), b.append("FILE", h), (m = (E = r({
3706
+ b.append("UPLOAD_CODE", s == null ? void 0 : s.UPLOAD_CODE), b.append("UPLOAD_TYPE", s == null ? void 0 : s.UPLOAD_TYPE), b.append("FILE", h), (C = (E = r({
3700
3707
  endpoint: "/upload/temp",
3701
3708
  data: b,
3702
3709
  headers: {
3703
3710
  "Content-Type": "multipart/form-data"
3704
3711
  }
3705
3712
  })) == null ? void 0 : E.then((k) => {
3706
- var S, H, B, M, L;
3707
- if ((H = (S = k == null ? void 0 : k.data) == null ? void 0 : S.DATA) != null && H.LIST) {
3708
- const I = (M = (B = k == null ? void 0 : k.data) == null ? void 0 : B.DATA) == null ? void 0 : M.LIST, $ = {
3709
- ATTACHMENT: I == null ? void 0 : I.VIEW_PATH,
3713
+ var S, F, B, M, L;
3714
+ if ((F = (S = k == null ? void 0 : k.data) == null ? void 0 : S.DATA) != null && F.LIST) {
3715
+ const H = (M = (B = k == null ? void 0 : k.data) == null ? void 0 : B.DATA) == null ? void 0 : M.LIST, $ = {
3716
+ ATTACHMENT: H == null ? void 0 : H.VIEW_PATH,
3710
3717
  FAQ_ID: null,
3711
3718
  MESSAGE: "",
3712
3719
  CREATED_DATE: (L = ae()) == null ? void 0 : L.format(`${En} HH:mm:ss`),
3713
3720
  CHAT_ALIGN: "to",
3714
3721
  CHAT_TYPE: "chat"
3715
3722
  };
3716
- f((F) => {
3717
- const J = [...jn(F), $];
3718
- return Qe(J);
3719
- }), x.current = !0, i({
3723
+ f((I) => {
3724
+ const z = [...jn(I), $];
3725
+ return Qe(z);
3726
+ }), x.current = !0, c({
3720
3727
  event: "SEND_MESSAGE",
3721
3728
  data: {
3722
- ATTACHMENT: I == null ? void 0 : I.TEMP_PATH,
3729
+ ATTACHMENT: H == null ? void 0 : H.TEMP_PATH,
3723
3730
  FAQ_ID: null,
3724
3731
  MESSAGE: "",
3725
- EMPLOYEES: u == null ? void 0 : u.map((F) => F == null ? void 0 : F.EMP_ID),
3732
+ EMPLOYEES: u == null ? void 0 : u.map((I) => I == null ? void 0 : I.EMP_ID),
3726
3733
  TASK_ID: g
3727
3734
  }
3728
- }), clearTimeout(c.current), c.current = setTimeout(() => {
3729
- me(".w-ticket-detail-content-container");
3735
+ }), clearTimeout(i.current), i.current = setTimeout(() => {
3736
+ Ce(".w-ticket-detail-content-container");
3730
3737
  }, 350);
3731
3738
  }
3732
- })) == null || m.finally(() => {
3739
+ })) == null || C.finally(() => {
3733
3740
  e(!1);
3734
3741
  });
3735
3742
  };
3736
3743
  return X(() => {
3737
- y();
3744
+ T();
3738
3745
  }, []), X(() => {
3739
3746
  var h;
3740
3747
  (h = ie) == null || h.destroy();
3741
- }, [C]), /* @__PURE__ */ n.jsx(
3748
+ }, [m]), /* @__PURE__ */ n.jsx(
3742
3749
  Pn,
3743
3750
  {
3744
- beforeUpload: j,
3751
+ beforeUpload: w,
3745
3752
  fileList: [],
3746
- accept: (v = (w = s == null ? void 0 : s.EXT_LIST) == null ? void 0 : w.split(",")) == null ? void 0 : v.map((h) => `.${h}`),
3753
+ accept: (v = (j = s == null ? void 0 : s.EXT_LIST) == null ? void 0 : j.split(",")) == null ? void 0 : v.map((h) => `.${h}`),
3747
3754
  onChange: (h) => {
3748
3755
  p(h == null ? void 0 : h.file);
3749
3756
  },
3750
3757
  children: /* @__PURE__ */ n.jsx(
3751
- z,
3758
+ Y,
3752
3759
  {
3753
3760
  loading: t,
3754
3761
  icon: /* @__PURE__ */ n.jsx(P, { type: "paper-clip" }),
@@ -3758,37 +3765,37 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3758
3765
  )
3759
3766
  }
3760
3767
  );
3761
- }, lo = R(io), ao = (e) => {
3768
+ }, lo = O(io), ao = (e) => {
3762
3769
  var s;
3763
3770
  const t = K(null), r = K(null);
3764
3771
  return r != null && r.current && ((s = r.current) == null || s.update(e)), X(() => {
3765
- var c;
3766
- const a = (c = window == null ? void 0 : window.customElements) == null ? void 0 : c.get("em-emoji-picker");
3767
- return r.current = new (a || ls)({ ...e, ref: t }), () => {
3772
+ var i;
3773
+ const l = (i = window == null ? void 0 : window.customElements) == null ? void 0 : i.get("em-emoji-picker");
3774
+ return r.current = new (l || ls)({ ...e, ref: t }), () => {
3768
3775
  r.current = null;
3769
3776
  };
3770
3777
  }, []), bn.createElement("div", { ref: t });
3771
3778
  }, uo = ({ refInput: e }) => {
3772
- const { xs: t } = Ce.useBreakpoint(), r = O(() => t ? "click" : "hover", [t]), s = () => {
3779
+ const { xs: t } = me.useBreakpoint(), r = R(() => t ? "click" : "hover", [t]), s = () => {
3773
3780
  var g;
3774
- const c = (g = e == null ? void 0 : e.current) == null ? void 0 : g.textarea;
3775
- if (!c)
3781
+ const i = (g = e == null ? void 0 : e.current) == null ? void 0 : g.textarea;
3782
+ if (!i)
3776
3783
  return !1;
3777
- const { selectionStart: o, selectionEnd: d, value: i } = c, u = i == null ? void 0 : i.substring(0, o), f = i == null ? void 0 : i.substring(o, d), x = i == null ? void 0 : i.substring(d);
3784
+ const { selectionStart: o, selectionEnd: d, value: c } = i, u = c == null ? void 0 : c.substring(0, o), f = c == null ? void 0 : c.substring(o, d), x = c == null ? void 0 : c.substring(d);
3778
3785
  return {
3779
3786
  before: u,
3780
3787
  selectedText: f,
3781
3788
  after: x,
3782
3789
  selectionStart: o,
3783
3790
  selectionEnd: d,
3784
- text: i
3791
+ text: c
3785
3792
  };
3786
- }, a = (c) => {
3793
+ }, l = (i) => {
3787
3794
  var x, g;
3788
3795
  (x = e == null ? void 0 : e.current) == null || x.focus();
3789
- const o = (g = e == null ? void 0 : e.current) == null ? void 0 : g.textarea, d = c == null ? void 0 : c.native;
3796
+ const o = (g = e == null ? void 0 : e.current) == null ? void 0 : g.textarea, d = i == null ? void 0 : i.native;
3790
3797
  if (!o) return;
3791
- const { before: i, after: u } = s(), f = `${i}${d}${u}`;
3798
+ const { before: c, after: u } = s(), f = `${c}${d}${u}`;
3792
3799
  typeof document.execCommand == "function" ? document.execCommand("insertText", !1, d) : o.value = f;
3793
3800
  };
3794
3801
  return /* @__PURE__ */ n.jsx(
@@ -3798,65 +3805,65 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3798
3805
  content: /* @__PURE__ */ n.jsx(
3799
3806
  ao,
3800
3807
  {
3801
- onEmojiSelect: (c) => {
3802
- a(c);
3808
+ onEmojiSelect: (i) => {
3809
+ l(i);
3803
3810
  },
3804
3811
  theme: "auto"
3805
3812
  }
3806
3813
  ),
3807
- children: /* @__PURE__ */ n.jsx(z, { icon: /* @__PURE__ */ n.jsx(P, { type: "smile" }), style: { border: "none" } })
3814
+ children: /* @__PURE__ */ n.jsx(Y, { icon: /* @__PURE__ */ n.jsx(P, { type: "smile" }), style: { border: "none" } })
3808
3815
  }
3809
3816
  );
3810
- }, fo = R(uo), xo = () => {
3811
- const [e, t] = D(0), [r, s] = D(!1), a = K(null), c = K(null), o = K(!1), d = K(null), { onSendMsg: i, setGetResponse: u, isGetResponse: f } = he(), { ticketId: x } = ve(), { isActiveTabVA: g } = be(), { employees: C, setChats: y, isFromSelf: j, detailTicket: p } = De(), w = O(() => r || !f, [r, f]), v = O(() => {
3812
- var m;
3813
- return ((m = p == null ? void 0 : p.STATUS) == null ? void 0 : m.toString().toLowerCase()) === "closed";
3814
- }, [p == null ? void 0 : p.STATUS]), h = O(() => C == null ? void 0 : C.map((m) => ({
3815
- ...m,
3817
+ }, fo = O(uo), xo = () => {
3818
+ const [e, t] = D(0), [r, s] = D(!1), l = K(null), i = K(null), o = K(!1), d = K(null), { onSendMsg: c, setGetResponse: u, isGetResponse: f } = he(), { ticketId: x } = ve(), { isActiveTabVA: g } = be(), { employees: m, setChats: T, isFromSelf: w, detailTicket: p } = De(), j = R(() => r || !f, [r, f]), v = R(() => {
3819
+ var C;
3820
+ return ((C = p == null ? void 0 : p.STATUS) == null ? void 0 : C.toString().toLowerCase()) === "closed";
3821
+ }, [p == null ? void 0 : p.STATUS]), h = R(() => m == null ? void 0 : m.map((C) => ({
3822
+ ...C,
3816
3823
  label: /* @__PURE__ */ n.jsx(
3817
3824
  hn,
3818
3825
  {
3819
3826
  placement: "left",
3820
- content: /* @__PURE__ */ n.jsx(co, { ...m }),
3821
- children: /* @__PURE__ */ n.jsx("div", { children: /* @__PURE__ */ n.jsx(Ue, { src: m == null ? void 0 : m.PHOTO, name: m == null ? void 0 : m.FULL_NAME }) })
3827
+ content: /* @__PURE__ */ n.jsx(co, { ...C }),
3828
+ children: /* @__PURE__ */ n.jsx("div", { children: /* @__PURE__ */ n.jsx(Ue, { src: C == null ? void 0 : C.PHOTO, name: C == null ? void 0 : C.FULL_NAME }) })
3822
3829
  }
3823
3830
  ),
3824
- value: m == null ? void 0 : m.FULL_NAME
3825
- })), [C]), b = () => {
3826
- var S, H, B;
3831
+ value: C == null ? void 0 : C.FULL_NAME
3832
+ })), [m]), b = () => {
3833
+ var S, F, B;
3827
3834
  u(!1);
3828
- const m = (H = (S = a == null ? void 0 : a.current) == null ? void 0 : S.textarea) == null ? void 0 : H.value;
3829
- i({
3835
+ const C = (F = (S = l == null ? void 0 : l.current) == null ? void 0 : S.textarea) == null ? void 0 : F.value;
3836
+ c({
3830
3837
  event: "SEND_MESSAGE",
3831
3838
  data: {
3832
3839
  ATTACHMENT: "",
3833
3840
  FAQ_ID: null,
3834
- MESSAGE: m,
3835
- EMPLOYEES: C == null ? void 0 : C.map((M) => M == null ? void 0 : M.EMP_ID),
3841
+ MESSAGE: C,
3842
+ EMPLOYEES: m == null ? void 0 : m.map((M) => M == null ? void 0 : M.EMP_ID),
3836
3843
  TASK_ID: x
3837
3844
  }
3838
3845
  });
3839
3846
  const k = {
3840
3847
  ATTACHMENT: "",
3841
3848
  FAQ_ID: null,
3842
- MESSAGE: m,
3849
+ MESSAGE: C,
3843
3850
  CREATED_DATE: (B = ae()) == null ? void 0 : B.format(`${En} HH:mm:ss`),
3844
3851
  CHAT_ALIGN: "to",
3845
3852
  CHAT_TYPE: "chat"
3846
3853
  };
3847
- y((M) => {
3848
- const I = [...jn(M), k];
3849
- return Qe(I);
3850
- }), j.current = !0, me(".w-ticket-detail-content-container"), t((M) => M + 1);
3854
+ T((M) => {
3855
+ const H = [...jn(M), k];
3856
+ return Qe(H);
3857
+ }), w.current = !0, Ce(".w-ticket-detail-content-container"), t((M) => M + 1);
3851
3858
  }, E = () => {
3852
- window.clearTimeout(c.current), o.current || (o.current = !0, i({
3859
+ window.clearTimeout(i.current), o.current || (o.current = !0, c({
3853
3860
  event: "TYPING",
3854
3861
  data: {
3855
3862
  TASK_ID: x,
3856
3863
  IS_TYPING: !0
3857
3864
  }
3858
- })), c.current = setTimeout(() => {
3859
- i({
3865
+ })), i.current = setTimeout(() => {
3866
+ c({
3860
3867
  event: "TYPING",
3861
3868
  data: {
3862
3869
  TASK_ID: x,
@@ -3866,9 +3873,9 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3866
3873
  }, 250);
3867
3874
  };
3868
3875
  return X(() => {
3869
- a != null && a.current && !g && x && (clearTimeout(d.current), d.current = setTimeout(() => {
3870
- var m;
3871
- (m = a == null ? void 0 : a.current) == null || m.focus();
3876
+ l != null && l.current && !g && x && (clearTimeout(d.current), d.current = setTimeout(() => {
3877
+ var C;
3878
+ (C = l == null ? void 0 : l.current) == null || C.focus();
3872
3879
  }, 500));
3873
3880
  }, [g, x]), v ? null : /* @__PURE__ */ n.jsxs(
3874
3881
  "div",
@@ -3878,7 +3885,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3878
3885
  margin: 0
3879
3886
  },
3880
3887
  children: [
3881
- /* @__PURE__ */ n.jsx(fo, { refInput: a }),
3888
+ /* @__PURE__ */ n.jsx(fo, { refInput: l }),
3882
3889
  /* @__PURE__ */ n.jsx(
3883
3890
  lo,
3884
3891
  {
@@ -3892,37 +3899,37 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3892
3899
  autoSize: {
3893
3900
  maxRows: 3
3894
3901
  },
3895
- ref: a,
3902
+ ref: l,
3896
3903
  className: "w-input-helpdesk",
3897
3904
  placeholder: "Type a message...",
3898
3905
  onChange: () => {
3899
3906
  E();
3900
3907
  },
3901
- onKeyDown: (m) => {
3902
- ((m == null ? void 0 : m.code) === "Enter" || (m == null ? void 0 : m.key) === "Enter") && !(m != null && m.shiftKey) && b();
3908
+ onKeyDown: (C) => {
3909
+ ((C == null ? void 0 : C.code) === "Enter" || (C == null ? void 0 : C.key) === "Enter") && !(C != null && C.shiftKey) && b();
3903
3910
  },
3904
- filterOption: (m, k) => {
3911
+ filterOption: (C, k) => {
3905
3912
  var B, M, L;
3906
- const S = (B = m == null ? void 0 : m.toString()) == null ? void 0 : B.toLowerCase(), H = (L = (M = k == null ? void 0 : k.FULL_NAME) == null ? void 0 : M.toString()) == null ? void 0 : L.toLowerCase();
3907
- return H == null ? void 0 : H.includes(S);
3913
+ const S = (B = C == null ? void 0 : C.toString()) == null ? void 0 : B.toLowerCase(), F = (L = (M = k == null ? void 0 : k.FULL_NAME) == null ? void 0 : M.toString()) == null ? void 0 : L.toLowerCase();
3914
+ return F == null ? void 0 : F.includes(S);
3908
3915
  },
3909
- children: h == null ? void 0 : h.map((m, k) => /* @__PURE__ */ n.jsx(Wn.Option, { ...m, children: m == null ? void 0 : m.label }, k))
3916
+ children: h == null ? void 0 : h.map((C, k) => /* @__PURE__ */ n.jsx(Wn.Option, { ...C, children: C == null ? void 0 : C.label }, k))
3910
3917
  },
3911
3918
  e
3912
3919
  ),
3913
3920
  /* @__PURE__ */ n.jsx(
3914
- z,
3921
+ Y,
3915
3922
  {
3916
- loading: w,
3917
- disabled: w,
3923
+ loading: j,
3924
+ disabled: j,
3918
3925
  className: "w-send-btn",
3919
3926
  style: {
3920
3927
  backgroundColor: "var(--primary-color, #395ebc)",
3921
- ...w && {
3928
+ ...j && {
3922
3929
  color: "white"
3923
3930
  }
3924
3931
  },
3925
- icon: /* @__PURE__ */ n.jsx(P, { type: w ? "loading" : "send" }),
3932
+ icon: /* @__PURE__ */ n.jsx(P, { type: j ? "loading" : "send" }),
3926
3933
  shape: "circle",
3927
3934
  onClick: b
3928
3935
  }
@@ -3930,20 +3937,20 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3930
3937
  ]
3931
3938
  }
3932
3939
  );
3933
- }, go = R(xo), Co = ({ title: e, subTitle: t, onClose: r, open: s, styleWrapper: a }) => {
3934
- var c;
3940
+ }, go = O(xo), mo = ({ title: e, subTitle: t, onClose: r, open: s, styleWrapper: l }) => {
3941
+ var i;
3935
3942
  return s ? /* @__PURE__ */ n.jsx(
3936
3943
  "div",
3937
3944
  {
3938
3945
  className: "w-banner-container",
3939
- ...((c = Object.keys(a || {})) == null ? void 0 : c.length) > 0 && {
3940
- style: a
3946
+ ...((i = Object.keys(l || {})) == null ? void 0 : i.length) > 0 && {
3947
+ style: l
3941
3948
  },
3942
3949
  children: /* @__PURE__ */ n.jsxs("div", { className: "w-banner-content", children: [
3943
- e && /* @__PURE__ */ n.jsx(V.Text, { style: { fontSize: 16, fontWeight: 600 }, children: e }),
3950
+ e && /* @__PURE__ */ n.jsx(G.Text, { style: { fontSize: 16, fontWeight: 600 }, children: e }),
3944
3951
  t && /* @__PURE__ */ n.jsx("div", { className: "w-banner-subtitle", children: t }),
3945
3952
  typeof r == "function" && /* @__PURE__ */ n.jsx("div", { className: "w-banner-close-btn", children: /* @__PURE__ */ n.jsx(
3946
- z,
3953
+ Y,
3947
3954
  {
3948
3955
  style: { border: "none", background: "transparent" },
3949
3956
  icon: /* @__PURE__ */ n.jsx(P, { type: "close" }),
@@ -3953,25 +3960,25 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3953
3960
  ] })
3954
3961
  }
3955
3962
  ) : null;
3956
- }, yt = R(Co), mo = () => {
3963
+ }, yt = O(mo), Co = () => {
3957
3964
  const e = _(
3958
3965
  "ForMoreInformationOfThisTicket",
3959
3966
  "For more information of this ticket"
3960
- ), t = _("ClickHere", "Click here"), { ticketId: r } = ve(), { widgetProps: s } = q(), { encrypt: a } = Tt();
3967
+ ), t = _("ClickHere", "Click here"), { ticketId: r } = ve(), { widgetProps: s } = q(), { encrypt: l } = Tt();
3961
3968
  return /* @__PURE__ */ n.jsx(
3962
3969
  yt,
3963
3970
  {
3964
3971
  subTitle: /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
3965
- /* @__PURE__ */ n.jsx(V.Text, { children: e }),
3972
+ /* @__PURE__ */ n.jsx(G.Text, { children: e }),
3966
3973
  /* @__PURE__ */ n.jsx(
3967
- V.Link,
3974
+ G.Link,
3968
3975
  {
3969
3976
  strong: !0,
3970
3977
  className: "w-reconnect-manual",
3971
3978
  onClick: () => {
3972
- const c = a(r);
3979
+ const i = l(r);
3973
3980
  s != null && s.history && (s == null || s.history.push(
3974
- `/standard/hrm.helpdesk.my-ticket.ticket-details?id=${c}`
3981
+ `/standard/hrm.helpdesk.my-ticket.ticket-details?id=${i}`
3975
3982
  ));
3976
3983
  },
3977
3984
  children: t
@@ -3984,25 +3991,25 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
3984
3991
  }
3985
3992
  }
3986
3993
  );
3987
- }, bo = R(mo), vo = ({ onClose: e, visible: t }) => /* @__PURE__ */ n.jsx(ht, { open: t, onClose: e, children: /* @__PURE__ */ n.jsxs(Br, { children: [
3994
+ }, bo = O(Co), vo = ({ onClose: e, visible: t }) => /* @__PURE__ */ n.jsx(ht, { open: t, onClose: e, children: /* @__PURE__ */ n.jsxs(Br, { children: [
3988
3995
  /* @__PURE__ */ n.jsx(Wr, { onClose: e }),
3989
3996
  /* @__PURE__ */ n.jsx(bo, {}),
3990
3997
  /* @__PURE__ */ n.jsx(ro, {}),
3991
3998
  /* @__PURE__ */ n.jsx(go, {})
3992
- ] }) }), ho = R(vo), Eo = () => {
3999
+ ] }) }), ho = O(vo), Eo = () => {
3993
4000
  const e = _("AdvanceFilter", "Advance Filter"), t = _("Subject", "Subject"), r = _(
3994
4001
  "TicketCategory",
3995
4002
  "Ticket Category"
3996
- ), s = _("TicketStatus", "Ticket Status"), a = _("CreatedDate", "Created Date"), c = _("New", "New"), o = _("Open", "Open"), d = _("Reopen", "Reopen"), i = _("InProgress", "In Progress"), u = _("Responded", "Responded"), f = _("Fixed", "Fixed"), x = _("Done", "Done"), g = _("Closed", "Closed"), C = _("HDCancelled", "Cancelled"), y = _("Clear", "Clear"), j = _("Filter", "Filter"), p = en(), [w] = oe.useForm(), { openFilter: v, setOpenFilter: h, getListTicket: b, setCountFilters: E } = ve(), [m, k] = D([]), S = O(() => {
3997
- const M = `${c}/${o}/${d}`, L = `${i}/${u}`, I = `${f}/${x}`;
4003
+ ), s = _("TicketStatus", "Ticket Status"), l = _("CreatedDate", "Created Date"), i = _("New", "New"), o = _("Open", "Open"), d = _("Reopen", "Reopen"), c = _("InProgress", "In Progress"), u = _("Responded", "Responded"), f = _("Fixed", "Fixed"), x = _("Done", "Done"), g = _("Closed", "Closed"), m = _("HDCancelled", "Cancelled"), T = _("Clear", "Clear"), w = _("Filter", "Filter"), p = en(), [j] = oe.useForm(), { openFilter: v, setOpenFilter: h, getListTicket: b, setCountFilters: E } = ve(), [C, k] = D([]), S = R(() => {
4004
+ const M = `${i}/${o}/${d}`, L = `${c}/${u}`, H = `${f}/${x}`;
3998
4005
  return [
3999
4006
  { value: 3, label: M },
4000
4007
  { value: 1, label: L },
4001
- { value: 4, label: I },
4008
+ { value: 4, label: H },
4002
4009
  { value: 6, label: g },
4003
- { value: 8, label: C }
4010
+ { value: 8, label: m }
4004
4011
  ];
4005
- }, []), H = () => {
4012
+ }, []), F = () => {
4006
4013
  var M;
4007
4014
  (M = p({
4008
4015
  endpoint: "/helpdesk/category/list",
@@ -4013,26 +4020,26 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4013
4020
  SORT: { FIELD: "ORDER_NO", ORDER: "ASC" }
4014
4021
  }
4015
4022
  })) == null || M.then((L) => {
4016
- var I, $, F;
4017
- if ((I = L == null ? void 0 : L.data) != null && I.DATA) {
4018
- const G = (F = ($ = L == null ? void 0 : L.data) == null ? void 0 : $.DATA) == null ? void 0 : F.LIST;
4023
+ var H, $, I;
4024
+ if ((H = L == null ? void 0 : L.data) != null && H.DATA) {
4025
+ const J = (I = ($ = L == null ? void 0 : L.data) == null ? void 0 : $.DATA) == null ? void 0 : I.LIST;
4019
4026
  k(
4020
- G == null ? void 0 : G.map((J) => ({
4021
- label: J == null ? void 0 : J.CATEGORY_NAME,
4022
- value: J == null ? void 0 : J.CATEGORY_CODE
4027
+ J == null ? void 0 : J.map((z) => ({
4028
+ label: z == null ? void 0 : z.CATEGORY_NAME,
4029
+ value: z == null ? void 0 : z.CATEGORY_CODE
4023
4030
  }))
4024
4031
  );
4025
4032
  }
4026
4033
  });
4027
4034
  }, B = () => {
4028
- var I, $;
4029
- const M = w == null ? void 0 : w.getFieldsValue(!0);
4035
+ var H, $;
4036
+ const M = j == null ? void 0 : j.getFieldsValue(!0);
4030
4037
  b(M);
4031
- const L = ($ = (I = Object.values(M || {})) == null ? void 0 : I.flat()) == null ? void 0 : $.filter(Boolean);
4038
+ const L = ($ = (H = Object.values(M || {})) == null ? void 0 : H.flat()) == null ? void 0 : $.filter(Boolean);
4032
4039
  E(L == null ? void 0 : L.length);
4033
4040
  };
4034
4041
  return X(() => {
4035
- H();
4042
+ F();
4036
4043
  }, []), /* @__PURE__ */ n.jsxs(
4037
4044
  ht,
4038
4045
  {
@@ -4043,32 +4050,32 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4043
4050
  },
4044
4051
  footer: /* @__PURE__ */ n.jsxs("div", { className: "w-ticket-list-advance-filter-footer", children: [
4045
4052
  /* @__PURE__ */ n.jsx(
4046
- z,
4053
+ Y,
4047
4054
  {
4048
4055
  onClick: () => {
4049
- w == null || w.resetFields(), B();
4056
+ j == null || j.resetFields(), B();
4050
4057
  },
4051
- children: y
4058
+ children: T
4052
4059
  },
4053
4060
  "clear"
4054
4061
  ),
4055
4062
  /* @__PURE__ */ n.jsx(
4056
- z,
4063
+ Y,
4057
4064
  {
4058
4065
  type: "primary",
4059
4066
  onClick: () => {
4060
4067
  B(), h(!1);
4061
4068
  },
4062
- children: j
4069
+ children: w
4063
4070
  },
4064
4071
  "filter"
4065
4072
  )
4066
4073
  ] }),
4067
4074
  children: [
4068
4075
  /* @__PURE__ */ n.jsxs("div", { style: { display: "flex", gap: 8, justifyContent: "space-between" }, children: [
4069
- /* @__PURE__ */ n.jsx(V.Text, { strong: !0, style: { fontSize: 16 }, children: e }),
4076
+ /* @__PURE__ */ n.jsx(G.Text, { strong: !0, style: { fontSize: 16 }, children: e }),
4070
4077
  /* @__PURE__ */ n.jsx(
4071
- z,
4078
+ Y,
4072
4079
  {
4073
4080
  icon: /* @__PURE__ */ n.jsx(P, { type: "close" }),
4074
4081
  onClick: () => {
@@ -4077,16 +4084,16 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4077
4084
  }
4078
4085
  )
4079
4086
  ] }),
4080
- /* @__PURE__ */ n.jsx("div", { className: "w-ticket-list-advance-filter-form-container", children: /* @__PURE__ */ n.jsxs(oe, { form: w, layout: "vertical", children: [
4087
+ /* @__PURE__ */ n.jsx("div", { className: "w-ticket-list-advance-filter-form-container", children: /* @__PURE__ */ n.jsxs(oe, { form: j, layout: "vertical", children: [
4081
4088
  /* @__PURE__ */ n.jsx(oe.Item, { label: t, name: "TASK_NAME", children: /* @__PURE__ */ n.jsx(Be, { allowClear: !0 }) }),
4082
- /* @__PURE__ */ n.jsx(oe.Item, { label: r, name: "CATEGORY_CODE", children: /* @__PURE__ */ n.jsx(Vn, { options: m, mode: "multiple", allowClear: !0 }) }),
4089
+ /* @__PURE__ */ n.jsx(oe.Item, { label: r, name: "CATEGORY_CODE", children: /* @__PURE__ */ n.jsx(Vn, { options: C, mode: "multiple", allowClear: !0 }) }),
4083
4090
  /* @__PURE__ */ n.jsx(oe.Item, { label: s, name: "TASK_STATUS", children: /* @__PURE__ */ n.jsx(Vn, { options: S, mode: "multiple", allowClear: !0 }) }),
4084
- /* @__PURE__ */ n.jsx(oe.Item, { label: a, name: "CREATED_DATE", children: /* @__PURE__ */ n.jsx(es, { style: { width: "100%" }, allowClear: !0 }) })
4091
+ /* @__PURE__ */ n.jsx(oe.Item, { label: l, name: "CREATED_DATE", children: /* @__PURE__ */ n.jsx(es, { style: { width: "100%" }, allowClear: !0 }) })
4085
4092
  ] }) })
4086
4093
  ]
4087
4094
  }
4088
4095
  );
4089
- }, To = R(Eo), yo = () => {
4096
+ }, To = O(Eo), yo = () => {
4090
4097
  const e = _(
4091
4098
  "ReconnectManually",
4092
4099
  "Reconnect Manually"
@@ -4094,11 +4101,11 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4094
4101
  "HelpdeskWebsocket",
4095
4102
  "Helpdesk Websocket"
4096
4103
  ), r = _("NotConnected", "Not Connected"), s = _("Connecting", "Connecting"), {
4097
- connectWebSocket: a,
4098
- retryCountState: c,
4104
+ connectWebSocket: l,
4105
+ retryCountState: i,
4099
4106
  setRetryCountState: o,
4100
4107
  retryCountRef: d
4101
- } = he(), i = O(() => c === Ie ? `${t} ${r}` : `${t} ${s}`, [c]);
4108
+ } = he(), c = R(() => i === Ie ? `${t} ${r}` : `${t} ${s}`, [i]);
4102
4109
  return /* @__PURE__ */ n.jsx(
4103
4110
  "div",
4104
4111
  {
@@ -4111,18 +4118,18 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4111
4118
  children: /* @__PURE__ */ n.jsx(
4112
4119
  ns,
4113
4120
  {
4114
- ...c === Ie ? {
4121
+ ...i === Ie ? {
4115
4122
  status: "warning"
4116
4123
  } : {
4117
4124
  icon: null
4118
4125
  },
4119
- title: i,
4120
- extra: c === Ie ? /* @__PURE__ */ n.jsx(
4121
- z,
4126
+ title: c,
4127
+ extra: i === Ie ? /* @__PURE__ */ n.jsx(
4128
+ Y,
4122
4129
  {
4123
4130
  type: "primary",
4124
4131
  onClick: () => {
4125
- d.current = 0, o(0), a();
4132
+ d.current = 0, o(0), l();
4126
4133
  },
4127
4134
  children: e
4128
4135
  },
@@ -4140,15 +4147,15 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4140
4147
  )
4141
4148
  }
4142
4149
  );
4143
- }, jo = R(yo), wo = () => {
4144
- const { setTicketId: e, ticketId: t, openFilter: r } = ve(), { onSendMsg: s, setGetResponse: a } = he(), { showReadyWSHD: c } = q();
4145
- return c ? /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
4150
+ }, jo = O(yo), wo = () => {
4151
+ const { setTicketId: e, ticketId: t, openFilter: r } = ve(), { onSendMsg: s, setGetResponse: l } = he(), { showReadyWSHD: i } = q();
4152
+ return i ? /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
4146
4153
  /* @__PURE__ */ n.jsx(
4147
4154
  ho,
4148
4155
  {
4149
4156
  visible: t,
4150
4157
  onClose: () => {
4151
- e(""), a(!1), s({
4158
+ e(""), l(!1), s({
4152
4159
  event: "LEAVE_ROOM",
4153
4160
  data: {
4154
4161
  TASK_ID: t
@@ -4160,19 +4167,19 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4160
4167
  /* @__PURE__ */ n.jsx("div", { style: { display: !t && !r ? "block" : "none" }, children: /* @__PURE__ */ n.jsx(Ir, {}) }),
4161
4168
  /* @__PURE__ */ n.jsx(To, {})
4162
4169
  ] }) : /* @__PURE__ */ n.jsx(jo, {});
4163
- }, ko = R(wo), po = ({ children: e, usePopover: t, ...r }) => t ? /* @__PURE__ */ n.jsx(hn, { ...r, visible: r == null ? void 0 : r.open, children: e }) : e, _o = () => {
4170
+ }, ko = O(wo), _o = ({ children: e, usePopover: t, ...r }) => t ? /* @__PURE__ */ n.jsx(hn, { ...r, visible: r == null ? void 0 : r.open, children: e }) : e, po = () => {
4164
4171
  const e = _("NeedHelp", "Need Help"), t = _(
4165
4172
  "WidgetDisconnected",
4166
4173
  "Widget Disconnected"
4167
- ), [r, s] = D(!0), a = K(), { widgetProps: c, setOpenWidget: o, isFirstOpenWidget: d, setFirstOpenWidget: i } = q(), { onSendMsg: u, connected: f, isHandshakeWidget: x } = fe(), g = () => {
4168
- o(!0), u({ msg: c == null ? void 0 : c.getStartedPayload });
4174
+ ), [r, s] = D(!0), l = K(), { widgetProps: i, setOpenWidget: o, isFirstOpenWidget: d, setFirstOpenWidget: c } = q(), { onSendMsg: u, connected: f, isHandshakeWidget: x } = fe(), g = () => {
4175
+ o(!0), u({ msg: i == null ? void 0 : i.getStartedPayload });
4169
4176
  };
4170
4177
  return X(() => {
4171
- s(!f), window.clearTimeout(a.current), a.current = setTimeout(() => {
4178
+ s(!f), window.clearTimeout(l.current), l.current = setTimeout(() => {
4172
4179
  s(!1);
4173
4180
  }, 3e3);
4174
4181
  }, [f]), /* @__PURE__ */ n.jsx(
4175
- po,
4182
+ _o,
4176
4183
  {
4177
4184
  usePopover: r && x === "show",
4178
4185
  open: r && x === "show",
@@ -4183,12 +4190,12 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4183
4190
  {
4184
4191
  className: "w-launcher-container",
4185
4192
  onClick: () => {
4186
- d || (i(!0), g()), o(!0);
4193
+ d || (c(!0), g()), o(!0);
4187
4194
  },
4188
4195
  children: [
4189
4196
  /* @__PURE__ */ n.jsx(P, { type: "chat-bubble" }),
4190
4197
  /* @__PURE__ */ n.jsxs(
4191
- V.Text,
4198
+ G.Text,
4192
4199
  {
4193
4200
  style: {
4194
4201
  fontWeight: 600,
@@ -4205,80 +4212,80 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4205
4212
  )
4206
4213
  }
4207
4214
  );
4208
- }, Ao = R(_o), So = () => {
4215
+ }, Ao = O(po), So = () => {
4209
4216
  const e = _("NotConnected", "Not Connected"), t = _(
4210
4217
  "CannotAutoReconnect",
4211
4218
  "Cannot auto reconnect"
4212
4219
  ), r = _(
4213
4220
  "ReconnectManually",
4214
4221
  "Reconnect Manually"
4215
- ), [s, a] = D(!1), { connected: c, createSocket: o } = fe(), { widgetProps: d } = q();
4222
+ ), [s, l] = D(!1), { connected: i, createSocket: o } = fe(), { widgetProps: d } = q();
4216
4223
  return X(() => {
4217
- a(!c);
4218
- }, [c]), /* @__PURE__ */ n.jsx(
4224
+ l(!i);
4225
+ }, [i]), /* @__PURE__ */ n.jsx(
4219
4226
  yt,
4220
4227
  {
4221
4228
  title: `${d == null ? void 0 : d.title} ${e}`,
4222
4229
  subTitle: /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
4223
- /* @__PURE__ */ n.jsxs(V.Text, { children: [
4230
+ /* @__PURE__ */ n.jsxs(G.Text, { children: [
4224
4231
  t,
4225
4232
  "?"
4226
4233
  ] }),
4227
4234
  /* @__PURE__ */ n.jsx(
4228
- V.Link,
4235
+ G.Link,
4229
4236
  {
4230
4237
  strong: !0,
4231
4238
  className: "w-reconnect-manual",
4232
4239
  onClick: () => {
4233
- o();
4240
+ o(!0);
4234
4241
  },
4235
4242
  children: r
4236
4243
  }
4237
4244
  )
4238
4245
  ] }),
4239
- onClose: () => a(!1),
4240
- open: !c && s
4246
+ onClose: () => l(!1),
4247
+ open: !i && s
4241
4248
  }
4242
4249
  );
4243
- }, Lo = R(
4250
+ }, Lo = O(
4244
4251
  So
4245
4252
  ), Ro = () => {
4246
- const { xs: e } = Ce.useBreakpoint(), [t, r] = D(!1), { isOpenWidget: s, widgetProps: a } = q(), { isActiveTabVA: c } = be(), o = K(null), d = O(() => {
4253
+ const { xs: e } = me.useBreakpoint(), [t, r] = D(!1), { isOpenWidget: s, widgetProps: l } = q(), { isActiveTabVA: i } = be(), o = K(null), d = R(() => {
4247
4254
  var f;
4248
4255
  const u = [un];
4249
- return e && (a != null && a.isSF ? u == null || u.push(`${un}-sf-mobile`) : u == null || u.push(`${un}-mobile`)), (f = u == null ? void 0 : u.filter(Boolean)) == null ? void 0 : f.join(" ");
4250
- }, [e, a == null ? void 0 : a.isSF]), i = Yt(
4256
+ return e && (l != null && l.isSF ? u == null || u.push(`${un}-sf-mobile`) : u == null || u.push(`${un}-mobile`)), (f = u == null ? void 0 : u.filter(Boolean)) == null ? void 0 : f.join(" ");
4257
+ }, [e, l == null ? void 0 : l.isSF]), c = Yt(
4251
4258
  (u) => {
4252
4259
  var x;
4253
4260
  const f = [u, xn == null ? void 0 : xn.FADE_IN];
4254
- return a != null && a.isSF && (f == null || f.push(`${u}-sf`)), e && (a != null && a.isSF ? f == null || f.push(`${u}-sf-mobile`) : f == null || f.push(`${u}-mobile`)), (x = f == null ? void 0 : f.filter(Boolean)) == null ? void 0 : x.join(" ");
4261
+ return l != null && l.isSF && (f == null || f.push(`${u}-sf`)), e && (l != null && l.isSF ? f == null || f.push(`${u}-sf-mobile`) : f == null || f.push(`${u}-mobile`)), (x = f == null ? void 0 : f.filter(Boolean)) == null ? void 0 : x.join(" ");
4255
4262
  },
4256
- [a == null ? void 0 : a.isSF, e]
4263
+ [l == null ? void 0 : l.isSF, e]
4257
4264
  );
4258
4265
  return X(() => {
4259
4266
  s && r(s), clearTimeout(o.current), o.current = setTimeout(() => {
4260
4267
  s || r(s);
4261
4268
  }, 250);
4262
4269
  }, [s]), t ? /* @__PURE__ */ n.jsxs("div", { className: d, children: [
4263
- /* @__PURE__ */ n.jsxs("div", { style: { display: c ? "block" : "none" }, children: [
4264
- /* @__PURE__ */ n.jsx("div", { className: i(Es), children: /* @__PURE__ */ n.jsx(_r, {}) }),
4270
+ /* @__PURE__ */ n.jsxs("div", { style: { display: i ? "block" : "none" }, children: [
4271
+ /* @__PURE__ */ n.jsx("div", { className: c(Es), children: /* @__PURE__ */ n.jsx(pr, {}) }),
4265
4272
  /* @__PURE__ */ n.jsx(Sr, {})
4266
4273
  ] }),
4267
- /* @__PURE__ */ n.jsx("div", { style: { display: c ? "none" : "block" }, children: /* @__PURE__ */ n.jsx("div", { className: i(Ts), children: /* @__PURE__ */ n.jsx(Fr, { children: /* @__PURE__ */ n.jsx(Dr, { children: /* @__PURE__ */ n.jsx(ko, {}) }) }) }) }),
4274
+ /* @__PURE__ */ n.jsx("div", { style: { display: i ? "none" : "block" }, children: /* @__PURE__ */ n.jsx("div", { className: c(Ts), children: /* @__PURE__ */ n.jsx(Fr, { children: /* @__PURE__ */ n.jsx(Dr, { children: /* @__PURE__ */ n.jsx(ko, {}) }) }) }) }),
4268
4275
  /* @__PURE__ */ n.jsx(Lo, {})
4269
4276
  ] }) : /* @__PURE__ */ n.jsx(Ao, {});
4270
- }, Oo = R(Ro), Do = ({ items: e, ...t }) => Le != null && Le.startsWith("5") || Re != null && Re.startsWith("18") ? /* @__PURE__ */ n.jsx(cn, { ...t, items: e }) : /* @__PURE__ */ n.jsx(cn, { ...t, children: e == null ? void 0 : e.map(({ ...r }) => /* @__PURE__ */ vn(
4277
+ }, Oo = O(Ro), Do = ({ items: e, ...t }) => Le != null && Le.startsWith("5") || Re != null && Re.startsWith("18") ? /* @__PURE__ */ n.jsx(cn, { ...t, items: e }) : /* @__PURE__ */ n.jsx(cn, { ...t, children: e == null ? void 0 : e.map(({ ...r }) => /* @__PURE__ */ vn(
4271
4278
  cn.TabPane,
4272
4279
  {
4273
4280
  ...r,
4274
4281
  key: r == null ? void 0 : r.key,
4275
4282
  tab: r == null ? void 0 : r.label
4276
4283
  }
4277
- )) }), No = R(Do), Mo = () => {
4284
+ )) }), No = O(Do), Mo = () => {
4278
4285
  const { isOpenWidget: e } = q(), { setActiveTab: t, activeTab: r } = be(), s = _(
4279
4286
  "VirtualAssistant",
4280
4287
  "Virtual Assistant"
4281
- ), a = _("Helpdesk", "Helpdesk"), { xs: c } = Ce.useBreakpoint();
4288
+ ), l = _("Helpdesk", "Helpdesk"), { xs: i } = me.useBreakpoint();
4282
4289
  return X(() => {
4283
4290
  const o = ot();
4284
4291
  t((o == null ? void 0 : o.activeTab) ?? r);
@@ -4286,7 +4293,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4286
4293
  "div",
4287
4294
  {
4288
4295
  className: "w-widget-tab-footer-container",
4289
- ...c && {
4296
+ ...i && {
4290
4297
  style: {
4291
4298
  borderRadius: 0
4292
4299
  }
@@ -4306,7 +4313,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4306
4313
  key: "va"
4307
4314
  },
4308
4315
  {
4309
- label: a,
4316
+ label: l,
4310
4317
  key: "helpdesk"
4311
4318
  }
4312
4319
  ]
@@ -4314,24 +4321,27 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4314
4321
  )
4315
4322
  }
4316
4323
  ) : null;
4317
- }, Fo = R(Mo), Ho = () => {
4318
- const { isOpenWidget: e, setOpenWidget: t, setExpand: r, isExpand: s, widgetProps: a } = q(), { xs: c } = Ce.useBreakpoint();
4324
+ }, Fo = O(Mo), Ho = () => {
4325
+ const { isOpenWidget: e, setOpenWidget: t, setExpand: r, isExpand: s, widgetProps: l } = q(), { xs: i } = me.useBreakpoint(), o = R(() => {
4326
+ const { title: d = "", modelName: c = "" } = l;
4327
+ return c ? `${d} (${c})` : d;
4328
+ }, [l == null ? void 0 : l.title, l == null ? void 0 : l.modelName]);
4319
4329
  return e ? /* @__PURE__ */ n.jsxs(
4320
4330
  "div",
4321
4331
  {
4322
4332
  className: `${He}-container`,
4323
- ...c && {
4333
+ ...i && {
4324
4334
  style: {
4325
4335
  borderRadius: 0
4326
4336
  }
4327
4337
  },
4328
4338
  children: [
4329
4339
  /* @__PURE__ */ n.jsxs("div", { className: `${He}-text`, children: [
4330
- /* @__PURE__ */ n.jsx("h4", { className: `${He}-title`, children: a == null ? void 0 : a.title }),
4331
- /* @__PURE__ */ n.jsx("span", { className: `${He}-subtitle`, children: a == null ? void 0 : a.subTitle })
4340
+ /* @__PURE__ */ n.jsx("h4", { className: `${He}-title`, children: o }),
4341
+ /* @__PURE__ */ n.jsx("span", { className: `${He}-subtitle`, children: l == null ? void 0 : l.subTitle })
4332
4342
  ] }),
4333
4343
  /* @__PURE__ */ n.jsxs("div", { className: `${He}-action`, children: [
4334
- !c && /* @__PURE__ */ n.jsx(
4344
+ !i && /* @__PURE__ */ n.jsx(
4335
4345
  P,
4336
4346
  {
4337
4347
  type: "expand",
@@ -4340,7 +4350,7 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4340
4350
  transition: "all 300ms"
4341
4351
  },
4342
4352
  onClick: () => {
4343
- r((o) => !o);
4353
+ r((d) => !d);
4344
4354
  }
4345
4355
  }
4346
4356
  ),
@@ -4357,21 +4367,21 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4357
4367
  ]
4358
4368
  }
4359
4369
  ) : null;
4360
- }, Io = R(Ho), $o = () => {
4361
- const { isExpand: e, isOpenWidget: t, isFirstOpenWidget: r, setOpenWidget: s } = q(), { xs: a } = Ce.useBreakpoint(), c = O(() => {
4370
+ }, Io = O(Ho), $o = () => {
4371
+ const { isExpand: e, isOpenWidget: t, isFirstOpenWidget: r, setOpenWidget: s } = q(), { xs: l } = me.useBreakpoint(), i = R(() => {
4362
4372
  var d;
4363
4373
  const o = [
4364
- a && t && "w-container-widget-mobile",
4374
+ l && t && "w-container-widget-mobile",
4365
4375
  r && (t ? "w-show-animate" : "w-close-animate"),
4366
4376
  "w-container-widget",
4367
4377
  e && "w-container-widget-expand"
4368
4378
  ];
4369
4379
  return (d = o == null ? void 0 : o.filter(Boolean)) == null ? void 0 : d.join(" ");
4370
- }, [e, a, r, t]);
4380
+ }, [e, l, r, t]);
4371
4381
  return /* @__PURE__ */ n.jsxs(
4372
4382
  "div",
4373
4383
  {
4374
- className: c,
4384
+ className: i,
4375
4385
  onKeyDown: (o) => {
4376
4386
  (o == null ? void 0 : o.code) === "Escape" && !(o != null && o.shiftKey) && !(o != null && o.altKey) && !(o != null && o.ctrlKey) && (o == null ? void 0 : o.key) === "Escape" && s(!1);
4377
4387
  },
@@ -4385,16 +4395,17 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4385
4395
  ]
4386
4396
  }
4387
4397
  );
4388
- }, Bo = R($o), Po = ({
4398
+ }, Bo = O($o), Po = ({
4389
4399
  getStartedPayload: e,
4390
4400
  socketURL: t,
4391
4401
  socketPath: r,
4392
4402
  onPayslipFn: s,
4393
- title: a,
4394
- subTitle: c,
4403
+ title: l,
4404
+ subTitle: i,
4395
4405
  keyEncrypt: o,
4396
4406
  history: d,
4397
- isSF: i = !1
4407
+ modelName: c,
4408
+ isSF: u = !1
4398
4409
  }) => /* @__PURE__ */ n.jsx(
4399
4410
  Ls,
4400
4411
  {
@@ -4402,11 +4413,12 @@ const ar = () => /* @__PURE__ */ n.jsxs("div", { className: "lds-ellipsis", chil
4402
4413
  socketURL: t,
4403
4414
  socketPath: r,
4404
4415
  onPayslipFn: s,
4405
- title: a,
4406
- subTitle: c,
4416
+ title: l,
4417
+ subTitle: i,
4407
4418
  keyEncrypt: o,
4408
4419
  history: d,
4409
- isSF: i,
4420
+ modelName: c,
4421
+ isSF: u,
4410
4422
  children: /* @__PURE__ */ n.jsx(Os, { children: /* @__PURE__ */ n.jsx(Bo, {}) })
4411
4423
  }
4412
4424
  );