@vlprojects-chat/chat 0.17.0-LD-8093.4 → 0.17.0-LD-8093.6

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.mjs +14 -13
  2. package/package.json +1 -1
package/dist/index.mjs CHANGED
@@ -33943,20 +33943,21 @@ let gp = class extends br({
33943
33943
  }
33944
33944
  startMessageProcessing() {
33945
33945
  const e = lp(this), t = (n) => {
33946
- var i;
33947
33946
  const r = /* @__PURE__ */ new Map();
33948
- n.forEach(({ channelId: s, message: a }) => {
33949
- var c;
33950
- r.has(s) || r.set(s, []), (c = r.get(s)) == null || c.push(a);
33951
- }), r.forEach((s, a) => {
33952
- const c = e.chat.channels.get(a);
33953
- c && (s.forEach((l) => l.randomId && c.drafts.cancelDraft(l.randomId)), c.addMessages(s));
33947
+ n.forEach(({ channelId: o, message: i }) => {
33948
+ var s;
33949
+ r.has(o) || r.set(o, []), (s = r.get(o)) == null || s.push(i);
33950
+ }), r.forEach((o, i) => {
33951
+ const s = e.chat.channels.get(i);
33952
+ s && (o.forEach((a) => a.randomId && s.drafts.cancelDraft(a.randomId)), s.addMessages(o));
33953
+ }), setTimeout(() => {
33954
+ var i;
33955
+ const o = e.chat.channelsList.filter(({ type: s }) => [nn.Public, nn.Private].includes(s)).map((s) => s.unreadMessagesCount).reduce((s, a) => s + a, 0);
33956
+ console.log(` ${sl.UpdateUnreadMsgCount}=> ${o}`), (i = e.chat.hostEventBus) == null || i.emit(
33957
+ sl.UpdateUnreadMsgCount,
33958
+ { count: o }
33959
+ );
33954
33960
  });
33955
- const o = e.chat.channelsList.filter(({ type: s }) => [nn.Public, nn.Private].includes(s)).map((s) => s.unreadMessagesCount);
33956
- console.log(`${sl.UpdateUnreadMsgCount}=> ${o}`), (i = e.chat.hostEventBus) == null || i.emit(
33957
- sl.UpdateUnreadMsgCount,
33958
- { count: o }
33959
- );
33960
33961
  };
33961
33962
  return Rj(
33962
33963
  this.messageChunk,
@@ -39128,7 +39129,7 @@ const yP = {
39128
39129
  }, gce = () => {
39129
39130
  const e = pe.useContext(_2);
39130
39131
  return e ? e.chatSnackbarContainer : null;
39131
- }, vce = "@vlprojects-chat/chat", yce = "vlprojects", bce = "0.17.0-LD-8093.3", wce = "vlprojects chat", Sce = "ISC", Ece = "dist/index.d.ts", xce = "./dist/index.mjs", Cce = "./dist/index.mjs", Tce = [
39132
+ }, vce = "@vlprojects-chat/chat", yce = "vlprojects", bce = "0.17.0-LD-8093.5", wce = "vlprojects chat", Sce = "ISC", Ece = "dist/index.d.ts", xce = "./dist/index.mjs", Cce = "./dist/index.mjs", Tce = [
39132
39133
  "dist"
39133
39134
  ], Oce = {
39134
39135
  type: "git",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@vlprojects-chat/chat",
3
3
  "author": "vlprojects",
4
- "version": "0.17.0-LD-8093.4",
4
+ "version": "0.17.0-LD-8093.6",
5
5
  "description": "vlprojects chat",
6
6
  "license": "ISC",
7
7
  "types": "dist/index.d.ts",