@wireapp/core 20.6.0 → 20.7.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 +41 -0
- package/package.json +3 -3
- package/src/main/conversation/AssetService.js +1 -1
- package/src/main/conversation/ConversationService.js +1 -0
- package/src/main/conversation/message/MessageToProtoMapper.js +1 -0
- package/src/main/linkPreview/LinkPreviewService.d.ts +1 -1
- package/src/main/linkPreview/LinkPreviewService.js +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,47 @@
|
|
|
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
|
+
## [20.7.1](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/compare/@wireapp/core@20.7.0...@wireapp/core@20.7.1) (2022-01-12)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* **core:** Map domain for image asset messages ([d583feb](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/commit/d583feb722a98d35c272fc862346ea7968cf0040))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
# [20.7.0](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/compare/@wireapp/core@20.6.2...@wireapp/core@20.7.0) (2022-01-12)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Features
|
|
21
|
+
|
|
22
|
+
* **core:** Enable link preview asset upload for federated env ([#4209](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/issues/4209)) ([232adaf](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/commit/232adafa7f76a44889c661ee0750f7ea8f31df79))
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
## [20.6.2](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/compare/@wireapp/core@20.6.1...@wireapp/core@20.6.2) (2022-01-11)
|
|
29
|
+
|
|
30
|
+
**Note:** Version bump only for package @wireapp/core
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
## [20.6.1](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/compare/@wireapp/core@20.6.0...@wireapp/core@20.6.1) (2022-01-10)
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
### Bug Fixes
|
|
40
|
+
|
|
41
|
+
* **core:** Fix url pattern for assetv4 ([31c1055](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/commit/31c10559c8e9c79a4015c8d087ef8cba5be9143f))
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
|
|
6
47
|
# [20.6.0](https://github.com/wireapp/wire-web-packages/tree/main/packages/core/compare/@wireapp/core@20.5.2...@wireapp/core@20.6.0) (2022-01-10)
|
|
7
48
|
|
|
8
49
|
|
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": "16.5.
|
|
8
|
+
"@wireapp/api-client": "16.5.2",
|
|
9
9
|
"@wireapp/cryptobox": "12.7.1",
|
|
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": "20.
|
|
73
|
-
"gitHead": "
|
|
72
|
+
"version": "20.7.1",
|
|
73
|
+
"gitHead": "1b719fb2f17b9a06a2ef95783e328d44c9e2a714"
|
|
74
74
|
}
|
|
@@ -42,7 +42,7 @@ class AssetService {
|
|
|
42
42
|
case 3:
|
|
43
43
|
return this.apiClient.asset.api.getAssetV3(assetData.assetKey, assetData.assetToken, forceCaching, progressCallback);
|
|
44
44
|
case 4:
|
|
45
|
-
return this.apiClient.asset.api.getAssetV4(assetData.assetKey, assetData.
|
|
45
|
+
return this.apiClient.asset.api.getAssetV4(assetData.assetKey, assetData.assetDomain, assetData.assetToken, forceCaching, progressCallback);
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
48
|
/**
|
|
@@ -3,5 +3,5 @@ import { LinkPreviewContent, LinkPreviewUploadedContent } from '../conversation/
|
|
|
3
3
|
export declare class LinkPreviewService {
|
|
4
4
|
private readonly assetService;
|
|
5
5
|
constructor(assetService: AssetService);
|
|
6
|
-
uploadLinkPreviewImage(linkPreview: LinkPreviewContent): Promise<LinkPreviewUploadedContent>;
|
|
6
|
+
uploadLinkPreviewImage(linkPreview: LinkPreviewContent, domain?: string): Promise<LinkPreviewUploadedContent>;
|
|
7
7
|
}
|
|
@@ -34,13 +34,13 @@ class LinkPreviewService {
|
|
|
34
34
|
constructor(assetService) {
|
|
35
35
|
this.assetService = assetService;
|
|
36
36
|
}
|
|
37
|
-
async uploadLinkPreviewImage(linkPreview) {
|
|
37
|
+
async uploadLinkPreviewImage(linkPreview, domain) {
|
|
38
38
|
const { image } = linkPreview, preview = __rest(linkPreview, ["image"]);
|
|
39
39
|
if (!image) {
|
|
40
40
|
return preview;
|
|
41
41
|
}
|
|
42
42
|
const uploadedLinkPreview = preview;
|
|
43
|
-
const asset = await (await this.assetService.uploadAsset(linkPreview.image.data)).response;
|
|
43
|
+
const asset = await (await this.assetService.uploadAsset(linkPreview.image.data, { domain })).response;
|
|
44
44
|
uploadedLinkPreview.imageUploaded = {
|
|
45
45
|
asset,
|
|
46
46
|
image,
|