@vonage/client-sdk 1.2.0-alpha.9 → 1.2.0-rc.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/README.md +4 -107
- package/dist/client/VonageClient.d.ts +62 -26
- package/dist/client/index.cjs +15271 -12515
- package/dist/client/index.mjs +15268 -12515
- package/dist/coreExtend.d.ts +16 -6
- package/dist/kotlin/JsUnions.d.ts +251 -0
- package/dist/kotlin/clientsdk-clientcore_js.d.ts +221 -84
- package/dist/lib/MediaClient.d.ts +1 -0
- package/dist/utils/ClientConfig.d.ts +26 -1
- package/dist/utils/ConnectivityManager.d.ts +11 -0
- package/dist/utils/ConversationModels.d.ts +2 -0
- package/dist/utils/index.d.ts +3 -3
- package/dist/vonageClientSDK.js +18510 -19444
- package/dist/vonageClientSDK.min.js +1 -2
- package/dist/vonageClientSDK.min.mjs +1 -2
- package/dist/vonageClientSDK.mjs +18507 -19444
- package/package.json +3 -3
- package/snippet.js +9 -1
- package/dist/kotlin/ConversationEvents.d.ts +0 -171
- package/dist/kotlin/From.d.ts +0 -26
- package/dist/utils/ConversationMessageModels.d.ts +0 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vonage/client-sdk",
|
|
3
|
-
"version": "1.2.0-
|
|
3
|
+
"version": "1.2.0-rc.1",
|
|
4
4
|
"description": "",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "dist/client/index.mjs",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"snippets": "node snippet.js $PWD",
|
|
29
29
|
"start": "node dist/Client.js",
|
|
30
30
|
"build:watch": "tsc -w",
|
|
31
|
-
"check": "tsc ./examples
|
|
31
|
+
"check": "tsc --project ./examples/tsconfig.json --noEmit --skipLibCheck --strictNullChecks true",
|
|
32
32
|
"lint": "eslint . --ext .ts",
|
|
33
33
|
"lint:fix": "eslint . --ext .ts --fix",
|
|
34
34
|
"clean": "rm -Rf node_modules/*; rm -Rf dist/"
|
|
@@ -76,7 +76,7 @@
|
|
|
76
76
|
"events": "^3.3.0",
|
|
77
77
|
"rtc-stats-adapter": "^1.2.0",
|
|
78
78
|
"sdp-transform": "^2.14.1",
|
|
79
|
-
"socket.io-client": "^
|
|
79
|
+
"socket.io-client": "^4.7.2",
|
|
80
80
|
"socketio-wildcard": "^2.0.0",
|
|
81
81
|
"webrtc-adapter": "^8.2.3"
|
|
82
82
|
}
|
package/snippet.js
CHANGED
|
@@ -45,6 +45,14 @@ let current_example = 0;
|
|
|
45
45
|
const files = readdirSync(input_path);
|
|
46
46
|
console.log('Input files: ', files);
|
|
47
47
|
|
|
48
|
+
const camalize = (str) =>
|
|
49
|
+
str.toLowerCase().replace(/[^a-zA-Z0-9]+(.)/g, (m, chr) => chr.toUpperCase());
|
|
50
|
+
|
|
51
|
+
const getFileName = (str) =>
|
|
52
|
+
str.startsWith('snippet')
|
|
53
|
+
? `snippet_${camalize(str.replace('snippet', ''))}.txt`
|
|
54
|
+
: `${str.replace(/ /g, '_')}.txt`;
|
|
55
|
+
|
|
48
56
|
files.forEach((file) => {
|
|
49
57
|
const format = file.split('.').pop();
|
|
50
58
|
const comments = comments_by_format[format];
|
|
@@ -70,7 +78,7 @@ files.forEach((file) => {
|
|
|
70
78
|
examples[current_example] = {
|
|
71
79
|
title: title.trim(),
|
|
72
80
|
format: format,
|
|
73
|
-
file_name: title.trim().
|
|
81
|
+
file_name: getFileName(title.trim().toLowerCase()),
|
|
74
82
|
content: ``
|
|
75
83
|
};
|
|
76
84
|
indentationLevel = line.search(comment_prefix);
|
|
@@ -1,171 +0,0 @@
|
|
|
1
|
-
import { vonage } from './clientsdk-clientcore_js';
|
|
2
|
-
import { From } from './From';
|
|
3
|
-
/**
|
|
4
|
-
* A MemberInvitedEvent is a ConversationEvent with a type of 'member:invited'
|
|
5
|
-
*
|
|
6
|
-
* @property id The event id
|
|
7
|
-
* @property timestamp The event timestamp
|
|
8
|
-
* @property conversationId The conversation id
|
|
9
|
-
* @property from The event sender
|
|
10
|
-
* @property body The invited member
|
|
11
|
-
* @interface
|
|
12
|
-
*/
|
|
13
|
-
export type MemberInvitedEvent = {
|
|
14
|
-
kind: 'member:invited';
|
|
15
|
-
from: From;
|
|
16
|
-
} & vonage.MemberInvitedEventJS;
|
|
17
|
-
/**
|
|
18
|
-
* A MemberJoinedEvent is a ConversationEvent with a type of 'member:joined'
|
|
19
|
-
*
|
|
20
|
-
* @property id the id property of the MemberJoinedEvent
|
|
21
|
-
* @property timestamp the timestamp property of the MemberJoinedEvent
|
|
22
|
-
* @property conversationId the conversationId property of the MemberJoinedEvent
|
|
23
|
-
* @property from the from property of the MemberJoinedEvent
|
|
24
|
-
* @property body the body property of the MemberJoinedEvent
|
|
25
|
-
* @interface
|
|
26
|
-
*/
|
|
27
|
-
export type MemberJoinedEvent = {
|
|
28
|
-
kind: 'member:joined';
|
|
29
|
-
from: From;
|
|
30
|
-
} & vonage.MemberJoinedEventJS;
|
|
31
|
-
/**
|
|
32
|
-
* A MemberLeftEvent is a ConversationEvent with a type of 'member:left'
|
|
33
|
-
*
|
|
34
|
-
* @property id the id property of the MemberLeftEvent
|
|
35
|
-
* @property timestamp the timestamp property of the MemberLeftEvent
|
|
36
|
-
* @property conversationId the conversationId property of the MemberLeftEvent
|
|
37
|
-
* @property from the from property of the MemberLeftEvent
|
|
38
|
-
* @property body the body property of the MemberLeftEvent
|
|
39
|
-
* @interface
|
|
40
|
-
*/
|
|
41
|
-
export type MemberLeftEvent = {
|
|
42
|
-
kind: 'member:left';
|
|
43
|
-
from: From;
|
|
44
|
-
} & vonage.MemberLeftEventJS;
|
|
45
|
-
/**
|
|
46
|
-
* A TextMessageEvent is a ConversationEvent with a type of 'message:text'
|
|
47
|
-
*
|
|
48
|
-
* @property id the id property of the TextMessageEvent
|
|
49
|
-
* @property timestamp the timestamp property of the TextMessageEvent
|
|
50
|
-
* @property conversationId the conversationId property of the TextMessageEvent
|
|
51
|
-
* @property from the from property of the TextMessageEvent
|
|
52
|
-
* @property body the body property of the TextMessageEvent
|
|
53
|
-
* @interface
|
|
54
|
-
*/
|
|
55
|
-
export type TextMessageEvent = {
|
|
56
|
-
kind: 'message:text';
|
|
57
|
-
from: From;
|
|
58
|
-
} & vonage.TextMessageEventJS;
|
|
59
|
-
/**
|
|
60
|
-
* A CustomMessageEvent is a ConversationEvent with a type of 'message:custom'
|
|
61
|
-
*
|
|
62
|
-
* @property id the id property of the CustomMessageEvent
|
|
63
|
-
* @property timestamp the timestamp property of the CustomMessageEvent
|
|
64
|
-
* @property conversationId the conversationId property of the CustomMessageEvent
|
|
65
|
-
* @property from the from property of the CustomMessageEvent
|
|
66
|
-
* @property body the body property of the CustomMessageEvent
|
|
67
|
-
* @interface
|
|
68
|
-
*/
|
|
69
|
-
export type CustomMessageEvent = {
|
|
70
|
-
kind: 'message:custom';
|
|
71
|
-
from: From;
|
|
72
|
-
} & vonage.CustomMessageEventJS;
|
|
73
|
-
/**
|
|
74
|
-
* A AudioMessageEvent is a ConversationEvent with a type of 'message:audio'
|
|
75
|
-
*
|
|
76
|
-
* @property id the id property of the AudioMessageEvent
|
|
77
|
-
* @property timestamp the timestamp property of the AudioMessageEvent
|
|
78
|
-
* @property conversationId the conversationId property of the AudioMessageEvent
|
|
79
|
-
* @property from the from property of the AudioMessageEvent
|
|
80
|
-
* @property body the body property of the AudioMessageEvent
|
|
81
|
-
* @interface
|
|
82
|
-
*/
|
|
83
|
-
export type AudioMessageEvent = {
|
|
84
|
-
kind: 'message:audio';
|
|
85
|
-
from: From;
|
|
86
|
-
} & vonage.AudioMessageEventJS;
|
|
87
|
-
/**
|
|
88
|
-
* A VideoMessageEvent is a ConversationEvent with a type of 'message:video'
|
|
89
|
-
*
|
|
90
|
-
* @property id the id property of the VideoMessageEvent
|
|
91
|
-
* @property timestamp the timestamp property of the VideoMessageEvent
|
|
92
|
-
* @property conversationId the conversationId property of the VideoMessageEvent
|
|
93
|
-
* @property from the from property of the VideoMessageEvent
|
|
94
|
-
* @property body the body property of the VideoMessageEvent
|
|
95
|
-
* @interface
|
|
96
|
-
*/
|
|
97
|
-
export type VideoMessageEvent = {
|
|
98
|
-
kind: 'message:video';
|
|
99
|
-
from: From;
|
|
100
|
-
} & vonage.VideoMessageEventJS;
|
|
101
|
-
/**
|
|
102
|
-
* A ImageMessageEvent is a ConversationEvent with a type of 'message:image'
|
|
103
|
-
*
|
|
104
|
-
* @property id the id property of the ImageMessageEvent
|
|
105
|
-
* @property timestamp the timestamp property of the ImageMessageEvent
|
|
106
|
-
* @property conversationId the conversationId property of the ImageMessageEvent
|
|
107
|
-
* @property from the from property of the ImageMessageEvent
|
|
108
|
-
* @property body the body property of the ImageMessageEvent
|
|
109
|
-
* @interface
|
|
110
|
-
*/
|
|
111
|
-
export type ImageMessageEvent = {
|
|
112
|
-
kind: 'message:image';
|
|
113
|
-
from: From;
|
|
114
|
-
} & vonage.ImageMessageEventJS;
|
|
115
|
-
/**
|
|
116
|
-
* A FileMessageEvent is a ConversationEvent with a type of 'message:file'
|
|
117
|
-
*
|
|
118
|
-
* @property id the id property of the FileMessageEvent
|
|
119
|
-
* @property timestamp the timestamp property of the FileMessageEvent
|
|
120
|
-
* @property conversationId the conversationId property of the FileMessageEvent
|
|
121
|
-
* @property from the from property of the FileMessageEvent
|
|
122
|
-
* @property body the body property of the FileMessageEvent
|
|
123
|
-
* @interface
|
|
124
|
-
*/
|
|
125
|
-
export type FileMessageEvent = {
|
|
126
|
-
kind: 'message:file';
|
|
127
|
-
from: From;
|
|
128
|
-
} & vonage.FileMessageEventJS;
|
|
129
|
-
/**
|
|
130
|
-
* A VCardMessageEvent is a ConversationEvent with a type of 'message:vcard'
|
|
131
|
-
*
|
|
132
|
-
* @property id the id property of the VCardMessageEvent
|
|
133
|
-
* @property timestamp the timestamp property of the VCardMessageEvent
|
|
134
|
-
* @property conversationId the conversationId property of the VCardMessageEvent
|
|
135
|
-
* @property from the from property of the VCardMessageEvent
|
|
136
|
-
* @property body the body property of the VCardMessageEvent
|
|
137
|
-
* @interface
|
|
138
|
-
*/
|
|
139
|
-
export type VCardMessageEvent = {
|
|
140
|
-
kind: 'message:vcard';
|
|
141
|
-
from: From;
|
|
142
|
-
} & vonage.VCardMessageEventJS;
|
|
143
|
-
/**
|
|
144
|
-
* A LocationMessageEvent is a ConversationEvent with a type of 'message:location'
|
|
145
|
-
*
|
|
146
|
-
* @property id the id property of the LocationMessageEvent
|
|
147
|
-
* @property timestamp the timestamp property of the LocationMessageEvent
|
|
148
|
-
* @property conversationId the conversationId property of the LocationMessageEvent
|
|
149
|
-
* @property from the from property of the LocationMessageEvent
|
|
150
|
-
* @property body the body property of the LocationMessageEvent
|
|
151
|
-
* @interface
|
|
152
|
-
*/
|
|
153
|
-
export type LocationMessageEvent = {
|
|
154
|
-
kind: 'message:location';
|
|
155
|
-
from: From;
|
|
156
|
-
} & vonage.LocationMessageEventJS;
|
|
157
|
-
/**
|
|
158
|
-
* A TemplateMessageEvent is a ConversationEvent with a type of 'message:template'
|
|
159
|
-
*
|
|
160
|
-
* @property id the id property of the TemplateMessageEvent
|
|
161
|
-
* @property timestamp the timestamp property of the TemplateMessageEvent
|
|
162
|
-
* @property conversationId the conversationId property of the TemplateMessageEvent
|
|
163
|
-
* @property from the from property of the TemplateMessageEvent
|
|
164
|
-
* @property body the body property of the TemplateMessageEvent
|
|
165
|
-
* @interface
|
|
166
|
-
*/
|
|
167
|
-
export type TemplateMessageEvent = {
|
|
168
|
-
kind: 'message:template';
|
|
169
|
-
from: From;
|
|
170
|
-
} & vonage.TemplateMessageEventJS;
|
|
171
|
-
export type ConversationEvent = MemberInvitedEvent | MemberJoinedEvent | MemberLeftEvent | TextMessageEvent | CustomMessageEvent | AudioMessageEvent | VideoMessageEvent | ImageMessageEvent | FileMessageEvent | VCardMessageEvent | LocationMessageEvent | TemplateMessageEvent;
|
package/dist/kotlin/From.d.ts
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { vonage } from './clientsdk-clientcore_js';
|
|
2
|
-
/**
|
|
3
|
-
* The EmbeddedInfo type
|
|
4
|
-
*
|
|
5
|
-
* @property kind the kind property of the EmbeddedInfo
|
|
6
|
-
* @property memberId the memberId property of the EmbeddedInfo
|
|
7
|
-
* @property user the user property of the EmbeddedInfo
|
|
8
|
-
* @interface
|
|
9
|
-
*/
|
|
10
|
-
export type EmbeddedInfo = {
|
|
11
|
-
kind: 'embeddedInfo';
|
|
12
|
-
} & vonage.EmbeddedInfoJS;
|
|
13
|
-
/**
|
|
14
|
-
* The System type
|
|
15
|
-
*
|
|
16
|
-
* @property kind the kind property of the System
|
|
17
|
-
* @interface
|
|
18
|
-
*/
|
|
19
|
-
export type System = {
|
|
20
|
-
kind: 'system';
|
|
21
|
-
} & typeof vonage.SystemJS;
|
|
22
|
-
/**
|
|
23
|
-
* A From is a union of EmbeddedInfo, System
|
|
24
|
-
* @interface
|
|
25
|
-
*/
|
|
26
|
-
export type From = EmbeddedInfo | System;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import vonage from '../utils/vonage';
|
|
2
|
-
export type TextMessageEvent = vonage.TextMessageEventJS;
|
|
3
|
-
export declare const TextMessageEvent: typeof vonage.TextMessageEventJS;
|
|
4
|
-
export type CustomMessageEvent = vonage.CustomMessageEventJS;
|
|
5
|
-
export declare const CustomMessageEvent: typeof vonage.CustomMessageEventJS;
|