@wireapp/core 25.0.0 → 25.2.1
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/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,36 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [25.2.1](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/compare/@wireapp/core@25.2.0...@wireapp/core@25.2.1) (2022-05-11)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @wireapp/core
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
# [25.2.0](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/compare/@wireapp/core@25.1.0...@wireapp/core@25.2.0) (2022-05-11)
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
### Features
|
|
18
|
+
|
|
19
|
+
* Add MLS device creation types ([#4259](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/issues/4259)) ([c88ed7c](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/commit/c88ed7cf3804828b4fe8e56d842a6207abea4c2d))
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
# [25.1.0](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/compare/@wireapp/core@25.0.0...@wireapp/core@25.1.0) (2022-05-04)
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
### Features
|
|
29
|
+
|
|
30
|
+
* Allow complete payload to crete conversations ([#4258](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/issues/4258)) ([a6d53e2](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/commit/a6d53e219e6ed96309ab02469b803ac461d38603))
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
|
|
6
36
|
# [25.0.0](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/compare/@wireapp/core@24.4.7...@wireapp/core@25.0.0) (2022-05-02)
|
|
7
37
|
|
|
8
38
|
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"dependencies": {
|
|
6
6
|
"@types/long": "4.0.1",
|
|
7
7
|
"@types/node": "~14",
|
|
8
|
-
"@wireapp/api-client": "19.
|
|
8
|
+
"@wireapp/api-client": "19.1.1",
|
|
9
9
|
"@wireapp/cryptobox": "12.8.0",
|
|
10
10
|
"bazinga64": "5.10.0",
|
|
11
11
|
"hash.js": "1.1.7",
|
|
@@ -69,6 +69,6 @@
|
|
|
69
69
|
"test:project": "yarn dist && yarn test",
|
|
70
70
|
"test:node": "nyc jasmine --config=jasmine.json"
|
|
71
71
|
},
|
|
72
|
-
"version": "25.
|
|
73
|
-
"gitHead": "
|
|
72
|
+
"version": "25.2.1",
|
|
73
|
+
"gitHead": "3bcb0a0f2c4ddbdb5460827b4eb3b84cee05e939"
|
|
74
74
|
}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import type { APIClient } from '@wireapp/api-client';
|
|
2
|
-
import type {
|
|
2
|
+
import type { CreateClientPayload, RegisteredClient, UpdateClientPayload } from '@wireapp/api-client/src/client/';
|
|
3
3
|
export declare class ClientBackendRepository {
|
|
4
4
|
private readonly apiClient;
|
|
5
5
|
constructor(apiClient: APIClient);
|
|
6
6
|
getClients(): Promise<RegisteredClient[]>;
|
|
7
|
-
postClient(client:
|
|
7
|
+
postClient(client: CreateClientPayload): Promise<RegisteredClient>;
|
|
8
|
+
putClient(clientId: string, updates: UpdateClientPayload): Promise<void>;
|
|
8
9
|
}
|
|
@@ -29,6 +29,9 @@ class ClientBackendRepository {
|
|
|
29
29
|
postClient(client) {
|
|
30
30
|
return this.apiClient.api.client.postClient(client);
|
|
31
31
|
}
|
|
32
|
+
putClient(clientId, updates) {
|
|
33
|
+
return this.apiClient.api.client.putClient(clientId, updates);
|
|
34
|
+
}
|
|
32
35
|
}
|
|
33
36
|
exports.ClientBackendRepository = ClientBackendRepository;
|
|
34
37
|
//# sourceMappingURL=ClientBackendRepository.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { APIClient } from '@wireapp/api-client';
|
|
2
|
-
import { MessageSendingStatus, Conversation, DefaultConversationRoleName, MutedStatus, QualifiedUserClients, UserClients, ClientMismatch } from '@wireapp/api-client/src/conversation';
|
|
2
|
+
import { MessageSendingStatus, Conversation, DefaultConversationRoleName, MutedStatus, NewConversation, QualifiedUserClients, UserClients, ClientMismatch } from '@wireapp/api-client/src/conversation';
|
|
3
3
|
import type { ConversationMemberLeaveEvent } from '@wireapp/api-client/src/event';
|
|
4
4
|
import type { QualifiedId, UserPreKeyBundleMap } from '@wireapp/api-client/src/user';
|
|
5
5
|
import { GenericMessage } from '@wireapp/protocol-messaging';
|
|
@@ -149,7 +149,24 @@ export declare class ConversationService {
|
|
|
149
149
|
deleteMessageEveryone(conversationId: string, messageIdToDelete: string, userIds?: string[] | QualifiedId[] | UserClients | QualifiedUserClients, sendAsProtobuf?: boolean, conversationDomain?: string, callbacks?: MessageSendingCallbacks): Promise<DeleteMessage>;
|
|
150
150
|
leaveConversation(conversationId: string): Promise<ConversationMemberLeaveEvent>;
|
|
151
151
|
leaveConversations(conversationIds?: string[]): Promise<ConversationMemberLeaveEvent[]>;
|
|
152
|
-
|
|
152
|
+
/**
|
|
153
|
+
* Create a group conversation.
|
|
154
|
+
* @param {string} name
|
|
155
|
+
* @param {string|string[]} otherUserIds
|
|
156
|
+
* @deprecated
|
|
157
|
+
* @returns Promise
|
|
158
|
+
*/
|
|
159
|
+
createConversation(name: string, otherUserIds: string | string[]): Promise<Conversation>;
|
|
160
|
+
/**
|
|
161
|
+
* Create a group conversation.
|
|
162
|
+
*
|
|
163
|
+
* @note Do not include yourself as the requestor
|
|
164
|
+
* @see https://staging-nginz-https.zinfra.io/swagger-ui/#!/conversations/createGroupConversation
|
|
165
|
+
*
|
|
166
|
+
* @param conversationData Payload object for group creation
|
|
167
|
+
* @returns Resolves when the conversation was created
|
|
168
|
+
*/
|
|
169
|
+
createConversation(conversationData: NewConversation): Promise<Conversation>;
|
|
153
170
|
getConversations(conversationId: string): Promise<Conversation>;
|
|
154
171
|
getConversations(conversationIds?: string[]): Promise<Conversation[]>;
|
|
155
172
|
getAsset({ assetId, assetToken, otrKey, sha256 }: RemoteData): Promise<Uint8Array>;
|
|
@@ -613,14 +613,20 @@ class ConversationService {
|
|
|
613
613
|
}
|
|
614
614
|
return Promise.all(conversationIds.map(conversationId => this.leaveConversation(conversationId)));
|
|
615
615
|
}
|
|
616
|
-
createConversation(
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
616
|
+
createConversation(conversationData, otherUserIds) {
|
|
617
|
+
let payload;
|
|
618
|
+
if (typeof conversationData === 'string') {
|
|
619
|
+
const ids = typeof otherUserIds === 'string' ? [otherUserIds] : otherUserIds;
|
|
620
|
+
payload = {
|
|
621
|
+
name: conversationData,
|
|
622
|
+
receipt_mode: null,
|
|
623
|
+
users: ids !== null && ids !== void 0 ? ids : [],
|
|
624
|
+
};
|
|
625
|
+
}
|
|
626
|
+
else {
|
|
627
|
+
payload = conversationData;
|
|
628
|
+
}
|
|
629
|
+
return this.apiClient.api.conversation.postConversation(payload);
|
|
624
630
|
}
|
|
625
631
|
async getConversations(conversationIds) {
|
|
626
632
|
if (!conversationIds || !conversationIds.length) {
|