@ethora/chat-component 25.2.4 → 25.2.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.
@@ -0,0 +1 @@
1
+ export declare const refreshHelper: (isEnabled: boolean, refreshFunc: any, logoutClb: any) => void;
@@ -1,3 +1,4 @@
1
1
  import { Client } from '@xmpp/client';
2
+ import { IMessage } from '../../types/types';
2
3
 
3
- export declare const getHistory: (client: Client, chatJID: string, max: number, before?: number, otherId?: string) => Promise<any>;
4
+ export declare const getHistory: (client: Client, chatJID: string, max: number, before?: number, otherId?: string) => Promise<IMessage[] | undefined>;
@@ -25,7 +25,7 @@ export declare class XmppClient implements XmppClientInterface {
25
25
  inviteRoomRequestStanza(to: string, roomJid: string): Promise<void>;
26
26
  leaveTheRoomStanza: (roomJID: string) => void;
27
27
  presenceInRoomStanza: (roomJID: string) => void;
28
- getHistoryStanza: (chatJID: string, max: number, before?: number, otherStanzaId?: string) => Promise<any>;
28
+ getHistoryStanza: (chatJID: string, max: number, before?: number, otherStanzaId?: string) => Promise<import('../types/types').IMessage[]>;
29
29
  getLastMessageArchiveStanza(roomJID: string): void;
30
30
  setRoomImageStanza: (roomJid: string, roomThumbnail: string, type: string, roomBackground?: string) => void;
31
31
  getRoomInfoStanza: (roomJID: string) => void;
@@ -71,6 +71,8 @@ export interface IRoom {
71
71
  };
72
72
  historyComplete?: boolean;
73
73
  }
74
+ export interface IRoomCompressed extends Pick<IRoom, 'jid'> {
75
+ }
74
76
  export interface RoomMember {
75
77
  ban_status: string;
76
78
  jid: string;
@@ -3,7 +3,7 @@ export declare class PriorityQueue<T> {
3
3
  private compare;
4
4
  constructor(compareFunction: (a: T, b: T) => number);
5
5
  push(item: T): void;
6
- pop(): T | undefined;
6
+ pop(size?: number): T[];
7
7
  peek(): T | undefined;
8
8
  clear(): void;
9
9
  isEmpty(): boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ethora/chat-component",
3
- "version": "25.02.04",
3
+ "version": "25.02.06",
4
4
  "type": "module",
5
5
  "main": "dist/main.js",
6
6
  "types": "dist/main.d.ts",