@onyx-p/imlib-web 2.1.8 → 2.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.
- package/index.esm.js +12 -14
- package/index.umd.js +12 -14
- package/package.json +1 -1
package/index.esm.js
CHANGED
@@ -20979,7 +20979,6 @@ const GroupCloseBurnAfterReadingMessage = registerMessageType$1(NotiMessageTypes
|
|
20979
20979
|
const RecallCommandMessage = registerMessageType$1(MessageTypes.RECALL, true, false, false);
|
20980
20980
|
|
20981
20981
|
class MessageCache {
|
20982
|
-
static instance;
|
20983
20982
|
loadedEndMap = new Map();
|
20984
20983
|
db = null;
|
20985
20984
|
currentAppKey = '';
|
@@ -21699,19 +21698,7 @@ class LibLoader {
|
|
21699
21698
|
};
|
21700
21699
|
}
|
21701
21700
|
const code = await webSocketServer.connect();
|
21702
|
-
|
21703
|
-
this.isInternalConnected = true;
|
21704
|
-
ConversationManager$1.get().destroyed();
|
21705
|
-
ConversationManager$1.create(this.options.appkey, accountStore.uid.toString(), this.watcher.conversationState);
|
21706
|
-
MessageReceiptManager$1.create(this.options.appkey, accountStore.uid.toString());
|
21707
|
-
MessageCache$1.create(this.options.appkey, accountStore.uid.toString());
|
21708
|
-
this.messageLoader?.stop();
|
21709
|
-
this.messageLoader = new MessageLoader(this.watcher, this.options);
|
21710
|
-
synchronizeServerTime();
|
21711
|
-
SentMessageStore.reset();
|
21712
|
-
RecallMessageStore.reset();
|
21713
|
-
DialogSecretKey$1.reset();
|
21714
|
-
}
|
21701
|
+
this.isInternalConnected = true;
|
21715
21702
|
return {
|
21716
21703
|
code
|
21717
21704
|
};
|
@@ -21730,6 +21717,15 @@ class LibLoader {
|
|
21730
21717
|
return Promise.resolve();
|
21731
21718
|
}
|
21732
21719
|
setUserLogged() {
|
21720
|
+
ConversationManager$1.get().destroyed();
|
21721
|
+
ConversationManager$1.create(this.options.appkey, accountStore.uid.toString(), this.watcher.conversationState);
|
21722
|
+
MessageReceiptManager$1.create(this.options.appkey, accountStore.uid.toString());
|
21723
|
+
MessageCache$1.create(this.options.appkey, accountStore.uid.toString());
|
21724
|
+
this.messageLoader?.stop();
|
21725
|
+
this.messageLoader = new MessageLoader(this.watcher, this.options);
|
21726
|
+
SentMessageStore.reset();
|
21727
|
+
RecallMessageStore.reset();
|
21728
|
+
DialogSecretKey$1.reset();
|
21733
21729
|
if (this.getConnectionStatus() === ConnectionStatus.CONNECTED) {
|
21734
21730
|
this.handleUserConnected();
|
21735
21731
|
}
|
@@ -21781,6 +21777,7 @@ class LibLoader {
|
|
21781
21777
|
this.watcher.onConnected?.();
|
21782
21778
|
if (accountStore.isActive) {
|
21783
21779
|
this.handleUserConnected();
|
21780
|
+
synchronizeServerTime();
|
21784
21781
|
}
|
21785
21782
|
}
|
21786
21783
|
handleDisconnect() {
|
@@ -21791,6 +21788,7 @@ class LibLoader {
|
|
21791
21788
|
this.watcher.onSuspend?.();
|
21792
21789
|
}
|
21793
21790
|
handleUserConnected() {
|
21791
|
+
logger.info('user connected -> ', accountStore.uid.toString());
|
21794
21792
|
this.messageLoader?.start();
|
21795
21793
|
setTimeout(() => {
|
21796
21794
|
if (this.connectionStatus !== ConnectionStatus.CONNECTED) return;
|
package/index.umd.js
CHANGED
@@ -20985,7 +20985,6 @@
|
|
20985
20985
|
const RecallCommandMessage = registerMessageType$1(MessageTypes.RECALL, true, false, false);
|
20986
20986
|
|
20987
20987
|
class MessageCache {
|
20988
|
-
static instance;
|
20989
20988
|
loadedEndMap = new Map();
|
20990
20989
|
db = null;
|
20991
20990
|
currentAppKey = '';
|
@@ -21705,19 +21704,7 @@
|
|
21705
21704
|
};
|
21706
21705
|
}
|
21707
21706
|
const code = await webSocketServer.connect();
|
21708
|
-
|
21709
|
-
this.isInternalConnected = true;
|
21710
|
-
ConversationManager$1.get().destroyed();
|
21711
|
-
ConversationManager$1.create(this.options.appkey, accountStore.uid.toString(), this.watcher.conversationState);
|
21712
|
-
MessageReceiptManager$1.create(this.options.appkey, accountStore.uid.toString());
|
21713
|
-
MessageCache$1.create(this.options.appkey, accountStore.uid.toString());
|
21714
|
-
this.messageLoader?.stop();
|
21715
|
-
this.messageLoader = new MessageLoader(this.watcher, this.options);
|
21716
|
-
synchronizeServerTime();
|
21717
|
-
SentMessageStore.reset();
|
21718
|
-
RecallMessageStore.reset();
|
21719
|
-
DialogSecretKey$1.reset();
|
21720
|
-
}
|
21707
|
+
this.isInternalConnected = true;
|
21721
21708
|
return {
|
21722
21709
|
code
|
21723
21710
|
};
|
@@ -21736,6 +21723,15 @@
|
|
21736
21723
|
return Promise.resolve();
|
21737
21724
|
}
|
21738
21725
|
setUserLogged() {
|
21726
|
+
ConversationManager$1.get().destroyed();
|
21727
|
+
ConversationManager$1.create(this.options.appkey, accountStore.uid.toString(), this.watcher.conversationState);
|
21728
|
+
MessageReceiptManager$1.create(this.options.appkey, accountStore.uid.toString());
|
21729
|
+
MessageCache$1.create(this.options.appkey, accountStore.uid.toString());
|
21730
|
+
this.messageLoader?.stop();
|
21731
|
+
this.messageLoader = new MessageLoader(this.watcher, this.options);
|
21732
|
+
SentMessageStore.reset();
|
21733
|
+
RecallMessageStore.reset();
|
21734
|
+
DialogSecretKey$1.reset();
|
21739
21735
|
if (this.getConnectionStatus() === exports.ConnectionStatus.CONNECTED) {
|
21740
21736
|
this.handleUserConnected();
|
21741
21737
|
}
|
@@ -21787,6 +21783,7 @@
|
|
21787
21783
|
this.watcher.onConnected?.();
|
21788
21784
|
if (accountStore.isActive) {
|
21789
21785
|
this.handleUserConnected();
|
21786
|
+
synchronizeServerTime();
|
21790
21787
|
}
|
21791
21788
|
}
|
21792
21789
|
handleDisconnect() {
|
@@ -21797,6 +21794,7 @@
|
|
21797
21794
|
this.watcher.onSuspend?.();
|
21798
21795
|
}
|
21799
21796
|
handleUserConnected() {
|
21797
|
+
logger.info('user connected -> ', accountStore.uid.toString());
|
21800
21798
|
this.messageLoader?.start();
|
21801
21799
|
setTimeout(() => {
|
21802
21800
|
if (this.connectionStatus !== exports.ConnectionStatus.CONNECTED) return;
|