corp-chat-library-antd-react-socket 1.1.9 → 1.2.0

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.
Files changed (2) hide show
  1. package/dist/index.js +76 -76
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -82,7 +82,7 @@ function nl() {
82
82
  })(un)), un.exports;
83
83
  }
84
84
  var ol = nl();
85
- const Re = /* @__PURE__ */ aa(ol);
85
+ const Me = /* @__PURE__ */ aa(ol);
86
86
  function Z(e) {
87
87
  "@babel/helpers - typeof";
88
88
  return Z = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
@@ -201,7 +201,7 @@ var ll = /* @__PURE__ */ re.forwardRef(function(e, t) {
201
201
  (Ce = M.current) !== null && Ce !== void 0 && Ce.contains(je.target) && y?.();
202
202
  }, k = sl(e), L = /* @__PURE__ */ tc(D, {
203
203
  value: S,
204
- className: Re((r = D.props) === null || r === void 0 ? void 0 : r.className, !k && b?.variant) || null
204
+ className: Me((r = D.props) === null || r === void 0 ? void 0 : r.className, !k && b?.variant) || null
205
205
  }), H = ge(null);
206
206
  if (re.useImperativeHandle(t, function() {
207
207
  return {
@@ -220,11 +220,11 @@ var ll = /* @__PURE__ */ re.forwardRef(function(e, t) {
220
220
  onMouseDown: function(je) {
221
221
  return je.preventDefault();
222
222
  },
223
- className: Re(U, x(x({}, "".concat(U, "-hidden"), !W), "".concat(U, "-has-suffix"), !!c))
223
+ className: Me(U, x(x({}, "".concat(U, "-hidden"), !W), "".concat(U, "-has-suffix"), !!c))
224
224
  }, te);
225
225
  }
226
- var ie = "".concat(s, "-affix-wrapper"), le = Re(ie, x(x(x(x(x({}, "".concat(s, "-disabled"), v), "".concat(ie, "-disabled"), v), "".concat(ie, "-focused"), f), "".concat(ie, "-readonly"), h), "".concat(ie, "-input-with-clear-btn"), c && p && S), _?.affixWrapper, b?.affixWrapper, b?.variant), fe = (c || p) && /* @__PURE__ */ re.createElement("span", {
227
- className: Re("".concat(s, "-suffix"), b?.suffix),
226
+ var ie = "".concat(s, "-affix-wrapper"), le = Me(ie, x(x(x(x(x({}, "".concat(s, "-disabled"), v), "".concat(ie, "-disabled"), v), "".concat(ie, "-focused"), f), "".concat(ie, "-readonly"), h), "".concat(ie, "-input-with-clear-btn"), c && p && S), _?.affixWrapper, b?.affixWrapper, b?.variant), fe = (c || p) && /* @__PURE__ */ re.createElement("span", {
227
+ className: Me("".concat(s, "-suffix"), b?.suffix),
228
228
  style: A?.suffix
229
229
  }, B, c);
230
230
  L = /* @__PURE__ */ re.createElement($, lt({
@@ -234,12 +234,12 @@ var ll = /* @__PURE__ */ re.forwardRef(function(e, t) {
234
234
  }, P?.affixWrapper, {
235
235
  ref: M
236
236
  }), l && /* @__PURE__ */ re.createElement("span", {
237
- className: Re("".concat(s, "-prefix"), b?.prefix),
237
+ className: Me("".concat(s, "-prefix"), b?.prefix),
238
238
  style: A?.prefix
239
239
  }, l), L, fe);
240
240
  }
241
241
  if (al(e)) {
242
- var ue = "".concat(s, "-group"), se = "".concat(ue, "-addon"), pe = "".concat(ue, "-wrapper"), be = Re("".concat(s, "-wrapper"), ue, _?.wrapper, b?.wrapper), Fe = Re(pe, x({}, "".concat(pe, "-disabled"), v), _?.group, b?.groupWrapper);
242
+ var ue = "".concat(s, "-group"), se = "".concat(ue, "-addon"), pe = "".concat(ue, "-wrapper"), be = Me("".concat(s, "-wrapper"), ue, _?.wrapper, b?.wrapper), Fe = Me(pe, x({}, "".concat(pe, "-disabled"), v), _?.group, b?.groupWrapper);
243
243
  L = /* @__PURE__ */ re.createElement(E, {
244
244
  className: Fe,
245
245
  ref: H
@@ -252,7 +252,7 @@ var ll = /* @__PURE__ */ re.forwardRef(function(e, t) {
252
252
  }, d)));
253
253
  }
254
254
  return /* @__PURE__ */ re.cloneElement(L, {
255
- className: Re((n = L.props) === null || n === void 0 ? void 0 : n.className, g) || null,
255
+ className: Me((n = L.props) === null || n === void 0 ? void 0 : n.className, g) || null,
256
256
  style: V(V({}, (o = L.props) === null || o === void 0 ? void 0 : o.style), m),
257
257
  hidden: C
258
258
  });
@@ -477,7 +477,7 @@ var yl = ["autoComplete", "onChange", "onFocus", "onBlur", "onPressEnter", "onKe
477
477
  T.current && (T.current = !1), $(!1), i?.(ne);
478
478
  }, we = function(ne) {
479
479
  B(""), j(), w.current && Bo(w.current, ne, n);
480
- }, Ae = pe && "".concat(u, "-out-of-range"), _e = function() {
480
+ }, Pe = pe && "".concat(u, "-out-of-range"), _e = function() {
481
481
  var ne = vl(e, [
482
482
  "prefixCls",
483
483
  "onPressEnter",
@@ -505,7 +505,7 @@ var yl = ["autoComplete", "onChange", "onFocus", "onBlur", "onPressEnter", "onKe
505
505
  onBlur: rt,
506
506
  onKeyDown: je,
507
507
  onKeyUp: Ce,
508
- className: Re(u, x({}, "".concat(u, "-disabled"), d), C?.input),
508
+ className: Me(u, x({}, "".concat(u, "-disabled"), d), C?.input),
509
509
  style: _?.input,
510
510
  ref: w,
511
511
  size: g,
@@ -524,7 +524,7 @@ var yl = ["autoComplete", "onChange", "onFocus", "onBlur", "onPressEnter", "onKe
524
524
  maxLength: ue
525
525
  }) : "".concat(se).concat(ne ? " / ".concat(ue) : "");
526
526
  return /* @__PURE__ */ re.createElement(re.Fragment, null, fe.show && /* @__PURE__ */ re.createElement("span", {
527
- className: Re("".concat(u, "-show-count-suffix"), x({}, "".concat(u, "-show-count-has-suffix"), !!h), C?.count),
527
+ className: Me("".concat(u, "-show-count-suffix"), x({}, "".concat(u, "-show-count-has-suffix"), !!h), C?.count),
528
528
  style: V({}, _?.count)
529
529
  }, Se), h);
530
530
  }
@@ -532,7 +532,7 @@ var yl = ["autoComplete", "onChange", "onFocus", "onBlur", "onPressEnter", "onKe
532
532
  };
533
533
  return /* @__PURE__ */ re.createElement(ll, lt({}, A, {
534
534
  prefixCls: u,
535
- className: Re(m, Ae),
535
+ className: Me(m, Pe),
536
536
  handleReset: we,
537
537
  value: W,
538
538
  focused: D,
@@ -2098,7 +2098,7 @@ function Vn() {
2098
2098
  }, e);
2099
2099
  })), Vn.apply(this, arguments);
2100
2100
  }
2101
- function Pe(e) {
2101
+ function Re(e) {
2102
2102
  return Fn(e);
2103
2103
  }
2104
2104
  function ii(e, t) {
@@ -2157,7 +2157,7 @@ var Co = /* @__PURE__ */ (function(e) {
2157
2157
  resetCount: 0
2158
2158
  }), x(oe(o), "cancelRegisterFunc", null), x(oe(o), "mounted", !1), x(oe(o), "touched", !1), x(oe(o), "dirty", !1), x(oe(o), "validatePromise", void 0), x(oe(o), "prevValidating", void 0), x(oe(o), "errors", Qe), x(oe(o), "warnings", Qe), x(oe(o), "cancelRegister", function() {
2159
2159
  var l = o.props, c = l.preserve, u = l.isListField, d = l.name;
2160
- o.cancelRegisterFunc && o.cancelRegisterFunc(u, c, Pe(d)), o.cancelRegisterFunc = null;
2160
+ o.cancelRegisterFunc && o.cancelRegisterFunc(u, c, Re(d)), o.cancelRegisterFunc = null;
2161
2161
  }), x(oe(o), "getNamePath", function() {
2162
2162
  var l = o.props, c = l.name, u = l.fieldContext, d = u.prefixName, g = d === void 0 ? [] : d;
2163
2163
  return c !== void 0 ? [].concat(X(g), X(c)) : [];
@@ -2220,7 +2220,7 @@ var Co = /* @__PURE__ */ (function(e) {
2220
2220
  break;
2221
2221
  }
2222
2222
  case "dependenciesUpdate": {
2223
- var _ = v.map(Pe);
2223
+ var _ = v.map(Re);
2224
2224
  if (_.some(function(b) {
2225
2225
  return Ht(u.relatedFields, b);
2226
2226
  })) {
@@ -2413,7 +2413,7 @@ x(Co, "defaultProps", {
2413
2413
  valuePropName: "value"
2414
2414
  });
2415
2415
  function _a(e) {
2416
- var t, r = e.name, n = pt(e, xu), o = F.useContext(Wt), i = F.useContext(qr), a = r !== void 0 ? Pe(r) : void 0, s = (t = n.isListField) !== null && t !== void 0 ? t : !!i, l = "keep";
2416
+ var t, r = e.name, n = pt(e, xu), o = F.useContext(Wt), i = F.useContext(qr), a = r !== void 0 ? Re(r) : void 0, s = (t = n.isListField) !== null && t !== void 0 ? t : !!i, l = "keep";
2417
2417
  return s || (l = "_".concat((a || []).join("_"))), process.env.NODE_ENV !== "production" && n.preserve === !1 && s && a.length <= 1 && Ee(!1, "`preserve` should not apply on Form.List fields."), /* @__PURE__ */ F.createElement(Co, lt({
2418
2418
  key: l,
2419
2419
  name: a,
@@ -2427,8 +2427,8 @@ function Eu(e) {
2427
2427
  keys: [],
2428
2428
  id: 0
2429
2429
  }), u = c.current, d = F.useMemo(function() {
2430
- var h = Pe(s.prefixName) || [];
2431
- return [].concat(X(h), X(Pe(t)));
2430
+ var h = Re(s.prefixName) || [];
2431
+ return [].concat(X(h), X(Re(t)));
2432
2432
  }, [s.prefixName, t]), g = F.useMemo(function() {
2433
2433
  return V(V({}, s), {}, {
2434
2434
  prefixName: d
@@ -2662,9 +2662,9 @@ var jt = /* @__PURE__ */ (function() {
2662
2662
  return r.getFieldEntities(!0);
2663
2663
  var o = r.getFieldsMap(!0);
2664
2664
  return n.map(function(i) {
2665
- var a = Pe(i);
2665
+ var a = Re(i);
2666
2666
  return o.get(a) || {
2667
- INVALIDATE_NAME_PATH: Pe(i)
2667
+ INVALIDATE_NAME_PATH: Re(i)
2668
2668
  };
2669
2669
  });
2670
2670
  }), x(this, "getFieldsValue", function(n, o) {
@@ -2687,10 +2687,10 @@ var jt = /* @__PURE__ */ (function() {
2687
2687
  var f = "getMeta" in u ? u.getMeta() : null;
2688
2688
  a(f) && c.push(m);
2689
2689
  }
2690
- }), ii(r.store, c.map(Pe));
2690
+ }), ii(r.store, c.map(Re));
2691
2691
  }), x(this, "getFieldValue", function(n) {
2692
2692
  r.warningUnhooked();
2693
- var o = Pe(n);
2693
+ var o = Re(n);
2694
2694
  return ht(r.store, o);
2695
2695
  }), x(this, "getFieldsError", function(n) {
2696
2696
  r.warningUnhooked();
@@ -2701,25 +2701,25 @@ var jt = /* @__PURE__ */ (function() {
2701
2701
  errors: i.getErrors(),
2702
2702
  warnings: i.getWarnings()
2703
2703
  } : {
2704
- name: Pe(n[a]),
2704
+ name: Re(n[a]),
2705
2705
  errors: [],
2706
2706
  warnings: []
2707
2707
  };
2708
2708
  });
2709
2709
  }), x(this, "getFieldError", function(n) {
2710
2710
  r.warningUnhooked();
2711
- var o = Pe(n), i = r.getFieldsError([o])[0];
2711
+ var o = Re(n), i = r.getFieldsError([o])[0];
2712
2712
  return i.errors;
2713
2713
  }), x(this, "getFieldWarning", function(n) {
2714
2714
  r.warningUnhooked();
2715
- var o = Pe(n), i = r.getFieldsError([o])[0];
2715
+ var o = Re(n), i = r.getFieldsError([o])[0];
2716
2716
  return i.warnings;
2717
2717
  }), x(this, "isFieldsTouched", function() {
2718
2718
  r.warningUnhooked();
2719
2719
  for (var n = arguments.length, o = new Array(n), i = 0; i < n; i++)
2720
2720
  o[i] = arguments[i];
2721
2721
  var a = o[0], s = o[1], l, c = !1;
2722
- o.length === 0 ? l = null : o.length === 1 ? Array.isArray(a) ? (l = a.map(Pe), c = !1) : (l = null, c = a) : (l = a.map(Pe), c = s);
2722
+ o.length === 0 ? l = null : o.length === 1 ? Array.isArray(a) ? (l = a.map(Re), c = !1) : (l = null, c = a) : (l = a.map(Re), c = s);
2723
2723
  var u = r.getFieldEntities(!0), d = function(f) {
2724
2724
  return f.isFieldTouched();
2725
2725
  };
@@ -2756,7 +2756,7 @@ var jt = /* @__PURE__ */ (function() {
2756
2756
  return o.some(function(a) {
2757
2757
  return a.isFieldValidating();
2758
2758
  });
2759
- var i = n.map(Pe);
2759
+ var i = n.map(Re);
2760
2760
  return o.some(function(a) {
2761
2761
  var s = a.getNamePath();
2762
2762
  return Ht(i, s) && a.isFieldValidating();
@@ -2812,7 +2812,7 @@ var jt = /* @__PURE__ */ (function() {
2812
2812
  }), r.notifyWatch();
2813
2813
  return;
2814
2814
  }
2815
- var i = n.map(Pe);
2815
+ var i = n.map(Re);
2816
2816
  i.forEach(function(a) {
2817
2817
  var s = r.getInitialValue(a);
2818
2818
  r.updateStore(it(r.store, a, s));
@@ -2825,7 +2825,7 @@ var jt = /* @__PURE__ */ (function() {
2825
2825
  r.warningUnhooked();
2826
2826
  var o = r.store, i = [];
2827
2827
  n.forEach(function(a) {
2828
- var s = a.name, l = pt(a, _u), c = Pe(s);
2828
+ var s = a.name, l = pt(a, _u), c = Re(s);
2829
2829
  i.push(c), "value" in l && r.updateStore(it(r.store, c, l.value)), r.notifyObservers(o, [c], {
2830
2830
  type: "setField",
2831
2831
  data: a
@@ -2917,7 +2917,7 @@ var jt = /* @__PURE__ */ (function() {
2917
2917
  relatedFields: [o].concat(X(i))
2918
2918
  }), i;
2919
2919
  }), x(this, "updateValue", function(n, o) {
2920
- var i = Pe(n), a = r.store;
2920
+ var i = Re(n), a = r.store;
2921
2921
  r.updateStore(it(r.store, i, o)), r.notifyObservers(a, [i], {
2922
2922
  type: "valueUpdate",
2923
2923
  source: "internal"
@@ -2951,7 +2951,7 @@ var jt = /* @__PURE__ */ (function() {
2951
2951
  r.getFieldEntities().forEach(function(l) {
2952
2952
  var c = l.props.dependencies;
2953
2953
  (c || []).forEach(function(u) {
2954
- var d = Pe(u);
2954
+ var d = Re(u);
2955
2955
  a.update(d, function() {
2956
2956
  var g = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : /* @__PURE__ */ new Set();
2957
2957
  return g.add(l), g;
@@ -2992,7 +2992,7 @@ var jt = /* @__PURE__ */ (function() {
2992
2992
  r.warningUnhooked();
2993
2993
  var i, a;
2994
2994
  Array.isArray(n) || typeof n == "string" || typeof o == "string" ? (i = n, a = o) : a = n;
2995
- var s = !!i, l = s ? i.map(Pe) : [], c = [], u = String(Date.now()), d = /* @__PURE__ */ new Set(), g = a || {}, m = g.recursive, v = g.dirty;
2995
+ var s = !!i, l = s ? i.map(Re) : [], c = [], u = String(Date.now()), d = /* @__PURE__ */ new Set(), g = a || {}, m = g.recursive, v = g.dirty;
2996
2996
  r.getFieldEntities(!0).forEach(function(p) {
2997
2997
  if (s || l.push(p.getNamePath()), !(!p.props.rules || !p.props.rules.length) && !(v && !p.isFieldDirty())) {
2998
2998
  var S = p.getNamePath();
@@ -3209,7 +3209,7 @@ function Ru() {
3209
3209
  m.current = g;
3210
3210
  var v = vt(Wt), h = s || v, f = h && h._init;
3211
3211
  process.env.NODE_ENV !== "production" && Ee(t.length === 2 ? s ? f : !0 : f, "useWatch requires a form instance since it can not auto detect from context.");
3212
- var y = Pe(n), p = ge(y);
3212
+ var y = Re(n), p = ge(y);
3213
3213
  return p.current = y, Pu(y), de(
3214
3214
  function() {
3215
3215
  if (f) {
@@ -4539,7 +4539,7 @@ function nr(e, t) {
4539
4539
  const r = t || 255;
4540
4540
  return e > r ? r : e < 0 ? 0 : e;
4541
4541
  }
4542
- class Me {
4542
+ class Ae {
4543
4543
  constructor(t) {
4544
4544
  x(this, "isValid", !0), x(this, "r", 0), x(this, "g", 0), x(this, "b", 0), x(this, "a", 1), x(this, "_h", void 0), x(this, "_s", void 0), x(this, "_l", void 0), x(this, "_v", void 0), x(this, "_max", void 0), x(this, "_min", void 0), x(this, "_brightness", void 0);
4545
4545
  function r(n) {
@@ -4551,7 +4551,7 @@ class Me {
4551
4551
  };
4552
4552
  const n = t.trim();
4553
4553
  /^#?[A-F\d]{3,8}$/i.test(n) ? this.fromHexString(n) : o("rgb") ? this.fromRgbString(n) : o("hsl") ? this.fromHslString(n) : (o("hsv") || o("hsb")) && this.fromHsvString(n);
4554
- } else if (t instanceof Me)
4554
+ } else if (t instanceof Ae)
4555
4555
  this.r = t.r, this.g = t.g, this.b = t.b, this.a = t.a, this._h = t._h, this._s = t._s, this._l = t._l, this._v = t._v;
4556
4556
  else if (r("rgb"))
4557
4557
  this.r = nr(t.r), this.g = nr(t.g), this.b = nr(t.b), this.a = typeof t.a == "number" ? nr(t.a, 1) : 1;
@@ -4895,8 +4895,8 @@ function Ei(e, t, r) {
4895
4895
  return r ? n = e.v + Gd * t : n = e.v - Kd * t, n = Math.max(0, Math.min(1, n)), Math.round(n * 100) / 100;
4896
4896
  }
4897
4897
  function mr(e) {
4898
- for (var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, r = [], n = new Me(e), o = n.toHsv(), i = rs; i > 0; i -= 1) {
4899
- var a = new Me({
4898
+ for (var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, r = [], n = new Ae(e), o = n.toHsv(), i = rs; i > 0; i -= 1) {
4899
+ var a = new Ae({
4900
4900
  h: Ci(o, i, !0),
4901
4901
  s: xi(o, i, !0),
4902
4902
  v: Ei(o, i, !0)
@@ -4905,7 +4905,7 @@ function mr(e) {
4905
4905
  }
4906
4906
  r.push(n);
4907
4907
  for (var s = 1; s <= ns; s += 1) {
4908
- var l = new Me({
4908
+ var l = new Ae({
4909
4909
  h: Ci(o, s),
4910
4910
  s: xi(o, s),
4911
4911
  v: Ei(o, s)
@@ -4914,7 +4914,7 @@ function mr(e) {
4914
4914
  }
4915
4915
  return t.theme === "dark" ? Xd.map(function(c) {
4916
4916
  var u = c.index, d = c.amount;
4917
- return new Me(t.backgroundColor || "#141414").mix(r[u], d).toHexString();
4917
+ return new Ae(t.backgroundColor || "#141414").mix(r[u], d).toHexString();
4918
4918
  }) : r.map(function(c) {
4919
4919
  return c.toHexString();
4920
4920
  });
@@ -4986,7 +4986,7 @@ function Yd(e, {
4986
4986
  colorPrimary: s,
4987
4987
  colorBgBase: l,
4988
4988
  colorTextBase: c
4989
- } = e, u = t(s), d = t(n), g = t(o), m = t(i), v = t(a), h = r(l, c), f = e.colorLink || e.colorInfo, y = t(f), p = new Me(m[1]).mix(new Me(m[3]), 50).toHexString();
4989
+ } = e, u = t(s), d = t(n), g = t(o), m = t(i), v = t(a), h = r(l, c), f = e.colorLink || e.colorInfo, y = t(f), p = new Ae(m[1]).mix(new Ae(m[3]), 50).toHexString();
4990
4990
  return Object.assign(Object.assign({}, h), {
4991
4991
  colorPrimaryBg: u[1],
4992
4992
  colorPrimaryBgHover: u[2],
@@ -5043,7 +5043,7 @@ function Yd(e, {
5043
5043
  colorLinkHover: y[4],
5044
5044
  colorLink: y[6],
5045
5045
  colorLinkActive: y[7],
5046
- colorBgMask: new Me("#000").setA(0.45).toRgbString(),
5046
+ colorBgMask: new Ae("#000").setA(0.45).toRgbString(),
5047
5047
  colorWhite: "#fff"
5048
5048
  });
5049
5049
  }
@@ -5149,7 +5149,7 @@ function nf(e) {
5149
5149
  // 4
5150
5150
  };
5151
5151
  }
5152
- const Je = (e, t) => new Me(e).setA(t).toRgbString(), or = (e, t) => new Me(e).darken(t).toHexString(), of = (e) => {
5152
+ const Je = (e, t) => new Ae(e).setA(t).toRgbString(), or = (e, t) => new Ae(e).darken(t).toHexString(), of = (e) => {
5153
5153
  const t = mr(e);
5154
5154
  return {
5155
5155
  1: t[0],
@@ -5238,16 +5238,16 @@ function ff(e, t) {
5238
5238
  let l = a.clone();
5239
5239
  return l = s?.(l) || l, l.toRgbString();
5240
5240
  }, o = (a, s) => {
5241
- const l = new Me(a), c = mr(l.toRgbString());
5241
+ const l = new Ae(a), c = mr(l.toRgbString());
5242
5242
  r[`${s}-color`] = n(l), r[`${s}-color-disabled`] = c[1], r[`${s}-color-hover`] = c[4], r[`${s}-color-active`] = c[6], r[`${s}-color-outline`] = l.clone().setA(0.2).toRgbString(), r[`${s}-color-deprecated-bg`] = c[0], r[`${s}-color-deprecated-border`] = c[2];
5243
5243
  };
5244
5244
  if (t.primaryColor) {
5245
5245
  o(t.primaryColor, "primary");
5246
- const a = new Me(t.primaryColor), s = mr(a.toRgbString());
5246
+ const a = new Ae(t.primaryColor), s = mr(a.toRgbString());
5247
5247
  s.forEach((c, u) => {
5248
5248
  r[`primary-${u + 1}`] = c;
5249
5249
  }), r["primary-color-deprecated-l-35"] = n(a, (c) => c.lighten(35)), r["primary-color-deprecated-l-20"] = n(a, (c) => c.lighten(20)), r["primary-color-deprecated-t-20"] = n(a, (c) => c.tint(20)), r["primary-color-deprecated-t-50"] = n(a, (c) => c.tint(50)), r["primary-color-deprecated-f-12"] = n(a, (c) => c.setA(c.a * 0.12));
5250
- const l = new Me(s[0]);
5250
+ const l = new Ae(s[0]);
5251
5251
  r["primary-color-active-deprecated-f-30"] = n(l, (c) => c.setA(c.a * 0.3)), r["primary-color-active-deprecated-d-02"] = n(l, (c) => c.darken(2));
5252
5252
  }
5253
5253
  return t.successColor && o(t.successColor, "success"), t.warningColor && o(t.warningColor, "warning"), t.errorColor && o(t.errorColor, "error"), t.infoColor && o(t.infoColor, "info"), `
@@ -5672,25 +5672,25 @@ function Mr(e, t) {
5672
5672
  g: n,
5673
5673
  b: o,
5674
5674
  a: i
5675
- } = new Me(e).toRgb();
5675
+ } = new Ae(e).toRgb();
5676
5676
  if (i < 1)
5677
5677
  return e;
5678
5678
  const {
5679
5679
  r: a,
5680
5680
  g: s,
5681
5681
  b: l
5682
- } = new Me(t).toRgb();
5682
+ } = new Ae(t).toRgb();
5683
5683
  for (let c = 0.01; c <= 1; c += 0.01) {
5684
5684
  const u = Math.round((r - a * (1 - c)) / c), d = Math.round((n - s * (1 - c)) / c), g = Math.round((o - l * (1 - c)) / c);
5685
5685
  if (En(u) && En(d) && En(g))
5686
- return new Me({
5686
+ return new Ae({
5687
5687
  r: u,
5688
5688
  g: d,
5689
5689
  b: g,
5690
5690
  a: Math.round(c * 100) / 100
5691
5691
  }).toRgbString();
5692
5692
  }
5693
- return new Me({
5693
+ return new Ae({
5694
5694
  r,
5695
5695
  g: n,
5696
5696
  b: o,
@@ -5817,9 +5817,9 @@ function ls(e) {
5817
5817
  screenXXLMin: u,
5818
5818
  boxShadowPopoverArrow: "2px 2px 5px rgba(0, 0, 0, 0.05)",
5819
5819
  boxShadowCard: `
5820
- 0 1px 2px -2px ${new Me("rgba(0, 0, 0, 0.16)").toRgbString()},
5821
- 0 3px 6px 0 ${new Me("rgba(0, 0, 0, 0.12)").toRgbString()},
5822
- 0 5px 12px 4px ${new Me("rgba(0, 0, 0, 0.09)").toRgbString()}
5820
+ 0 1px 2px -2px ${new Ae("rgba(0, 0, 0, 0.16)").toRgbString()},
5821
+ 0 3px 6px 0 ${new Ae("rgba(0, 0, 0, 0.12)").toRgbString()},
5822
+ 0 5px 12px 4px ${new Ae("rgba(0, 0, 0, 0.09)").toRgbString()}
5823
5823
  `,
5824
5824
  boxShadowDrawerRight: `
5825
5825
  -6px 0 16px 0 rgba(0, 0, 0, 0.08),
@@ -6369,10 +6369,10 @@ function ng(e, t, r, n) {
6369
6369
  de(function() {
6370
6370
  I && (we.current = !0), I !== void 0 && H === xt && ((we.current || I) && P?.(I), we.current = !0);
6371
6371
  }, [I, H]);
6372
- var Ae = k;
6373
- return be[at] && Ce === Dt && (Ae = V({
6372
+ var Pe = k;
6373
+ return be[at] && Ce === Dt && (Pe = V({
6374
6374
  transition: "none"
6375
- }, Ae)), [H, Ce, Ae, I ?? t];
6375
+ }, Pe)), [H, Ce, Pe, I ?? t];
6376
6376
  }
6377
6377
  function og(e) {
6378
6378
  var t = e;
@@ -6411,7 +6411,7 @@ function og(e) {
6411
6411
  P === at ? T = "prepare" : Os(P) ? T = "active" : P === Dt && (T = "start");
6412
6412
  var w = Vi(g, "".concat(b, "-").concat(T));
6413
6413
  $ = d(V(V({}, E), {}, {
6414
- className: Re(Vi(g, b), x(x({}, w, w && T), g, typeof g == "string")),
6414
+ className: Me(Vi(g, b), x(x({}, w, w && T), g, typeof g == "string")),
6415
6415
  style: A
6416
6416
  }), D);
6417
6417
  }
@@ -6661,7 +6661,7 @@ const yg = (e) => {
6661
6661
  transfer: ke,
6662
6662
  avatar: rt,
6663
6663
  message: we,
6664
- tag: Ae,
6664
+ tag: Pe,
6665
6665
  table: _e,
6666
6666
  card: $e,
6667
6667
  tabs: ae,
@@ -6750,7 +6750,7 @@ const yg = (e) => {
6750
6750
  transfer: ke,
6751
6751
  avatar: rt,
6752
6752
  message: we,
6753
- tag: Ae,
6753
+ tag: Pe,
6754
6754
  table: _e,
6755
6755
  card: $e,
6756
6756
  tabs: ae,
@@ -6871,7 +6871,7 @@ const Sg = (e) => {
6871
6871
  isFirstItem: i,
6872
6872
  isLastItem: a
6873
6873
  } = r, s = o === "vertical" ? "-vertical-" : "-";
6874
- return Re(`${e}-compact${s}item`, {
6874
+ return Me(`${e}-compact${s}item`, {
6875
6875
  [`${e}-compact${s}first-item`]: i,
6876
6876
  [`${e}-compact${s}last-item`]: a,
6877
6877
  [`${e}-compact${s}item-rtl`]: t === "rtl"
@@ -7075,7 +7075,7 @@ function Ag() {
7075
7075
  var Ig = ["className", "icon", "spin", "rotate", "tabIndex", "onClick", "twoToneColor"];
7076
7076
  Is(Xr.primary);
7077
7077
  var an = /* @__PURE__ */ F.forwardRef(function(e, t) {
7078
- var r = e.className, n = e.icon, o = e.spin, i = e.rotate, a = e.tabIndex, s = e.onClick, l = e.twoToneColor, c = pt(e, Ig), u = F.useContext(Oo), d = u.prefixCls, g = d === void 0 ? "anticon" : d, m = u.rootClassName, v = Re(m, g, x(x({}, "".concat(g, "-").concat(n.name), !!n.name), "".concat(g, "-spin"), !!o || n.name === "loading"), r), h = a;
7078
+ var r = e.className, n = e.icon, o = e.spin, i = e.rotate, a = e.tabIndex, s = e.onClick, l = e.twoToneColor, c = pt(e, Ig), u = F.useContext(Oo), d = u.prefixCls, g = d === void 0 ? "anticon" : d, m = u.rootClassName, v = Me(m, g, x(x({}, "".concat(g, "-").concat(n.name), !!n.name), "".concat(g, "-spin"), !!o || n.name === "loading"), r), h = a;
7079
7079
  h === void 0 && s && (h = -1);
7080
7080
  var f = i ? {
7081
7081
  msTransform: "rotate(".concat(i, "deg)"),
@@ -7113,7 +7113,7 @@ const jg = (e) => {
7113
7113
  }), t;
7114
7114
  };
7115
7115
  function Bi(e, t, r) {
7116
- return Re({
7116
+ return Me({
7117
7117
  [`${e}-status-success`]: t === "success",
7118
7118
  [`${e}-status-warning`]: t === "warning",
7119
7119
  [`${e}-status-error`]: t === "error",
@@ -8200,8 +8200,8 @@ const Ws = /* @__PURE__ */ Xi((e, t) => {
8200
8200
  const {
8201
8201
  deprecated: we
8202
8202
  } = Kt("Input");
8203
- [["bordered", "variant"], ["addonAfter", "Space.Compact"], ["addonBefore", "Space.Compact"]].forEach(([Ae, _e]) => {
8204
- we(!(Ae in e), Ae, _e);
8203
+ [["bordered", "variant"], ["addonAfter", "Space.Compact"], ["addonBefore", "Space.Compact"]].forEach(([Pe, _e]) => {
8204
+ we(!(Pe in e), Pe, _e);
8205
8205
  });
8206
8206
  }
8207
8207
  const {
@@ -8217,8 +8217,8 @@ const Ws = /* @__PURE__ */ Xi((e, t) => {
8217
8217
  compactSize: L,
8218
8218
  compactItemClassnames: H
8219
8219
  } = Cg($, _), B = Sg((we) => {
8220
- var Ae;
8221
- return (Ae = i ?? L) !== null && Ae !== void 0 ? Ae : we;
8220
+ var Pe;
8221
+ return (Pe = i ?? L) !== null && Pe !== void 0 ? Pe : we;
8222
8222
  }), W = re.useContext(Yr), U = a ?? W, {
8223
8223
  status: te,
8224
8224
  hasFeedback: ie,
@@ -8227,8 +8227,8 @@ const Ws = /* @__PURE__ */ Xi((e, t) => {
8227
8227
  if (process.env.NODE_ENV !== "production") {
8228
8228
  const we = Kt("Input");
8229
8229
  de(() => {
8230
- var Ae;
8231
- ue && !se.current && process.env.NODE_ENV !== "production" && we(document.activeElement === ((Ae = E.current) === null || Ae === void 0 ? void 0 : Ae.input), "usage", "When Input is focused, dynamic add or remove prefix / suffix will make it lose focus caused by dom structure change. Read more: https://ant.design/components/input/#FAQ"), se.current = ue;
8230
+ var Pe;
8231
+ ue && !se.current && process.env.NODE_ENV !== "production" && we(document.activeElement === ((Pe = E.current) === null || Pe === void 0 ? void 0 : Pe.input), "usage", "When Input is focused, dynamic add or remove prefix / suffix will make it lose focus caused by dom structure change. Read more: https://ant.design/components/input/#FAQ"), se.current = ue;
8232
8232
  }, [ue]);
8233
8233
  }
8234
8234
  const pe = kg(E), be = (we) => {
@@ -8250,7 +8250,7 @@ const Ws = /* @__PURE__ */ Xi((e, t) => {
8250
8250
  styles: Object.assign(Object.assign({}, D), h),
8251
8251
  suffix: je,
8252
8252
  allowClear: Ce,
8253
- className: Re(m, f, j, T, H, A),
8253
+ className: Me(m, f, j, T, H, A),
8254
8254
  onChange: z,
8255
8255
  addonBefore: g && /* @__PURE__ */ re.createElement(Di, {
8256
8256
  form: !0,
@@ -8261,23 +8261,23 @@ const Ws = /* @__PURE__ */ Xi((e, t) => {
8261
8261
  space: !0
8262
8262
  }, d),
8263
8263
  classNames: Object.assign(Object.assign(Object.assign({}, p), I), {
8264
- input: Re({
8264
+ input: Me({
8265
8265
  [`${$}-sm`]: B === "small",
8266
8266
  [`${$}-lg`]: B === "large",
8267
8267
  [`${$}-rtl`]: _ === "rtl"
8268
8268
  }, p?.input, I.input, M),
8269
- variant: Re({
8269
+ variant: Me({
8270
8270
  [`${$}-${ke}`]: rt
8271
8271
  }, Bi($, fe)),
8272
- affixWrapper: Re({
8272
+ affixWrapper: Me({
8273
8273
  [`${$}-affix-wrapper-sm`]: B === "small",
8274
8274
  [`${$}-affix-wrapper-lg`]: B === "large",
8275
8275
  [`${$}-affix-wrapper-rtl`]: _ === "rtl"
8276
8276
  }, M),
8277
- wrapper: Re({
8277
+ wrapper: Me({
8278
8278
  [`${$}-group-rtl`]: _ === "rtl"
8279
8279
  }, M),
8280
- groupWrapper: Re({
8280
+ groupWrapper: Me({
8281
8281
  [`${$}-group-wrapper-sm`]: B === "small",
8282
8282
  [`${$}-group-wrapper-lg`]: B === "large",
8283
8283
  [`${$}-group-wrapper-rtl`]: _ === "rtl",
@@ -8626,7 +8626,7 @@ const Rt = /* @__PURE__ */ aa(fh), Us = Jr(void 0), gh = ({ children: e }) => {
8626
8626
  if (console.log("init", ke), ke && a && c && h && d) {
8627
8627
  console.log("Attempting to connect with:", { HTTP_HOST: c, BFF_PORT: h, userdata: a });
8628
8628
  const q = setTimeout(() => {
8629
- we();
8629
+ we(), Pe(null).then();
8630
8630
  }, 0);
8631
8631
  return () => {
8632
8632
  clearTimeout(q), console.log("Cleaning up socket connection"), t.current?.disconnect();
@@ -8653,7 +8653,7 @@ const Rt = /* @__PURE__ */ aa(fh), Us = Jr(void 0), gh = ({ children: e }) => {
8653
8653
  }, [c]), de(() => {
8654
8654
  a && (console.log("userdataRef"), l.current = a);
8655
8655
  }, [a]);
8656
- const Ae = Xe(async (q = null) => {
8656
+ const Pe = Xe(async (q = null) => {
8657
8657
  if (console.log("fetchChatsList"), fe(!0), m)
8658
8658
  try {
8659
8659
  if (!y || !S || !d) {
@@ -8865,7 +8865,7 @@ const Rt = /* @__PURE__ */ aa(fh), Us = Jr(void 0), gh = ({ children: e }) => {
8865
8865
  loadingChat: ue,
8866
8866
  loadingSendSms: pe,
8867
8867
  /* methods */
8868
- fetchChatsList: Ae,
8868
+ fetchChatsList: Pe,
8869
8869
  fetchChatMessages: _e,
8870
8870
  sendSms: $e,
8871
8871
  markMessagesAsRead: ae,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "corp-chat-library-antd-react-socket",
3
3
  "description": "React chat component with Ant Design and Socket.io support",
4
- "version": "1.1.9",
4
+ "version": "1.2.0",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
7
7
  "types": "./dist/index.d.ts",