@ethora/chat-component 25.6.8 → 25.6.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/main.js
CHANGED
|
@@ -2171,17 +2171,13 @@ async function Vu(n) {
|
|
|
2171
2171
|
}
|
|
2172
2172
|
function _n(n, e) {
|
|
2173
2173
|
return new Promise((i, t) => {
|
|
2174
|
-
|
|
2174
|
+
setTimeout(() => {
|
|
2175
2175
|
try {
|
|
2176
2176
|
e && e();
|
|
2177
|
-
} catch
|
|
2178
|
-
console.error("Error in timeout callback:", s);
|
|
2177
|
+
} catch {
|
|
2179
2178
|
}
|
|
2180
|
-
t(
|
|
2179
|
+
t();
|
|
2181
2180
|
}, n);
|
|
2182
|
-
return () => {
|
|
2183
|
-
clearTimeout(r);
|
|
2184
|
-
};
|
|
2185
2181
|
});
|
|
2186
2182
|
}
|
|
2187
2183
|
async function Hd(n, e) {
|
|
@@ -2397,17 +2393,18 @@ function t0(n, e, i) {
|
|
|
2397
2393
|
}
|
|
2398
2394
|
const ys = async (n, e, i = 2e3) => {
|
|
2399
2395
|
let t;
|
|
2400
|
-
const r = () => n.off("stanza", t)
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2396
|
+
const r = () => n.off("stanza", t);
|
|
2397
|
+
return new Promise(async (s, a) => {
|
|
2398
|
+
let A = !1;
|
|
2399
|
+
const o = (d, l) => {
|
|
2400
|
+
A || (A = !0, setTimeout(() => {
|
|
2401
|
+
r(), d(l);
|
|
2405
2402
|
}, i));
|
|
2406
2403
|
};
|
|
2407
|
-
t = (
|
|
2408
|
-
|
|
2404
|
+
t = (d) => {
|
|
2405
|
+
d.is("presence") && d.attrs.id === "presenceInRoom" && d.attrs.from?.startsWith(e) && o(s, d);
|
|
2409
2406
|
}, n.on("stanza", t);
|
|
2410
|
-
const
|
|
2407
|
+
const f = Y.xml(
|
|
2411
2408
|
"presence",
|
|
2412
2409
|
{
|
|
2413
2410
|
from: n.jid?.toString(),
|
|
@@ -2417,12 +2414,15 @@ const ys = async (n, e, i = 2e3) => {
|
|
|
2417
2414
|
Y.xml("x", { xmlns: "http://jabber.org/protocol/muc" })
|
|
2418
2415
|
);
|
|
2419
2416
|
try {
|
|
2420
|
-
await n.send(
|
|
2421
|
-
} catch (
|
|
2422
|
-
return r(),
|
|
2417
|
+
await n.send(f);
|
|
2418
|
+
} catch (d) {
|
|
2419
|
+
return r(), a(d);
|
|
2423
2420
|
}
|
|
2424
|
-
|
|
2425
|
-
|
|
2421
|
+
await _n(
|
|
2422
|
+
2e3,
|
|
2423
|
+
() => o(a, new Error("Presence in room timeout"))
|
|
2424
|
+
).catch(() => {
|
|
2425
|
+
});
|
|
2426
2426
|
});
|
|
2427
2427
|
};
|
|
2428
2428
|
function r0(n, e) {
|
|
@@ -4890,7 +4890,7 @@ const Cv = {
|
|
|
4890
4890
|
},
|
|
4891
4891
|
popMessageFromHeap: (n) => {
|
|
4892
4892
|
const e = new Map(n.messageHeap ?? []), i = e.keys().next().value;
|
|
4893
|
-
i && (e.delete(i), n.messageHeap = Array.from(e.entries()));
|
|
4893
|
+
console.log(i), i && (e.delete(i), n.messageHeap = Array.from(e.entries()));
|
|
4894
4894
|
},
|
|
4895
4895
|
clearHeap: (n) => {
|
|
4896
4896
|
n.messageHeap = [];
|
|
@@ -30620,9 +30620,9 @@ const Kx = ({
|
|
|
30620
30620
|
}
|
|
30621
30621
|
), i?.refreshTokens?.enabled && iA();
|
|
30622
30622
|
}
|
|
30623
|
-
t(Qe({ loading: !1 }))
|
|
30623
|
+
t(Qe({ loading: !1 }));
|
|
30624
30624
|
} catch (w) {
|
|
30625
|
-
A(!
|
|
30625
|
+
A(!0), s(!1), t(Qe({ loading: !1 })), console.log(w);
|
|
30626
30626
|
}
|
|
30627
30627
|
})();
|
|
30628
30628
|
}, [b.xmppPassword, b.defaultWallet?.walletAddress]), {
|