@webex/internal-plugin-board 2.59.1 → 2.59.3-next.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/.eslintrc.js +6 -6
- package/README.md +42 -42
- package/babel.config.js +3 -3
- package/dist/board.js +161 -161
- package/dist/board.js.map +1 -1
- package/dist/config.js +21 -21
- package/dist/config.js.map +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/realtime-channel-collection.js +4 -4
- package/dist/realtime-channel-collection.js.map +1 -1
- package/dist/realtime-channel.js +4 -4
- package/dist/realtime-channel.js.map +1 -1
- package/dist/realtime.js +48 -48
- package/dist/realtime.js.map +1 -1
- package/jest.config.js +3 -3
- package/package.json +20 -19
- package/process +1 -1
- package/src/board.js +764 -764
- package/src/config.js +44 -44
- package/src/index.js +105 -105
- package/src/realtime-channel-collection.js +18 -18
- package/src/realtime-channel.js +40 -40
- package/src/realtime.js +252 -252
- package/test/integration/spec/board.js +717 -717
- package/test/integration/spec/realtime.js +194 -194
- package/test/integration/spec/sharing-mercury.js +285 -285
- package/test/unit/spec/board.js +635 -635
- package/test/unit/spec/encryption.js +255 -255
- package/test/unit/spec/realtime.js +473 -473
package/.eslintrc.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
const config = {
|
|
2
|
-
root: true,
|
|
3
|
-
extends: ['@webex/eslint-config-legacy'],
|
|
4
|
-
};
|
|
5
|
-
|
|
6
|
-
module.exports = config;
|
|
1
|
+
const config = {
|
|
2
|
+
root: true,
|
|
3
|
+
extends: ['@webex/eslint-config-legacy'],
|
|
4
|
+
};
|
|
5
|
+
|
|
6
|
+
module.exports = config;
|
package/README.md
CHANGED
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
# @webex/internal-plugin-board
|
|
2
|
-
|
|
3
|
-
[](https://github.com/RichardLitt/standard-readme)
|
|
4
|
-
|
|
5
|
-
> Plugin for the Board service
|
|
6
|
-
|
|
7
|
-
This is an internal Cisco Webex plugin. As such, it does not strictly adhere to semantic versioning. Use at your own risk. If you're not working on one of our first party clients, please look at our [developer api](https://developer.webex.com/) and stick to our public plugins.
|
|
8
|
-
|
|
9
|
-
- [Install](#install)
|
|
10
|
-
- [Usage](#usage)
|
|
11
|
-
- [Contribute](#contribute)
|
|
12
|
-
- [Maintainers](#maintainers)
|
|
13
|
-
- [License](#license)
|
|
14
|
-
|
|
15
|
-
## Install
|
|
16
|
-
|
|
17
|
-
```bash
|
|
18
|
-
npm install --save @webex/internal-plugin-board
|
|
19
|
-
```
|
|
20
|
-
|
|
21
|
-
## Usage
|
|
22
|
-
|
|
23
|
-
```js
|
|
24
|
-
import '@webex/internal-plugin-board';
|
|
25
|
-
|
|
26
|
-
import WebexCore from '@webex/webex-core';
|
|
27
|
-
|
|
28
|
-
const webex = new WebexCore();
|
|
29
|
-
webex.internal.board.WHATEVER;
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
## Maintainers
|
|
33
|
-
|
|
34
|
-
This package is maintained by [Cisco Webex for Developers](https://developer.webex.com/).
|
|
35
|
-
|
|
36
|
-
## Contribute
|
|
37
|
-
|
|
38
|
-
Pull requests welcome. Please see [CONTRIBUTING.md](https://github.com/webex/webex-js-sdk/blob/master/CONTRIBUTING.md) for more details.
|
|
39
|
-
|
|
40
|
-
## License
|
|
41
|
-
|
|
42
|
-
© 2016-2020 Cisco and/or its affiliates. All Rights Reserved.
|
|
1
|
+
# @webex/internal-plugin-board
|
|
2
|
+
|
|
3
|
+
[](https://github.com/RichardLitt/standard-readme)
|
|
4
|
+
|
|
5
|
+
> Plugin for the Board service
|
|
6
|
+
|
|
7
|
+
This is an internal Cisco Webex plugin. As such, it does not strictly adhere to semantic versioning. Use at your own risk. If you're not working on one of our first party clients, please look at our [developer api](https://developer.webex.com/) and stick to our public plugins.
|
|
8
|
+
|
|
9
|
+
- [Install](#install)
|
|
10
|
+
- [Usage](#usage)
|
|
11
|
+
- [Contribute](#contribute)
|
|
12
|
+
- [Maintainers](#maintainers)
|
|
13
|
+
- [License](#license)
|
|
14
|
+
|
|
15
|
+
## Install
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
npm install --save @webex/internal-plugin-board
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Usage
|
|
22
|
+
|
|
23
|
+
```js
|
|
24
|
+
import '@webex/internal-plugin-board';
|
|
25
|
+
|
|
26
|
+
import WebexCore from '@webex/webex-core';
|
|
27
|
+
|
|
28
|
+
const webex = new WebexCore();
|
|
29
|
+
webex.internal.board.WHATEVER;
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## Maintainers
|
|
33
|
+
|
|
34
|
+
This package is maintained by [Cisco Webex for Developers](https://developer.webex.com/).
|
|
35
|
+
|
|
36
|
+
## Contribute
|
|
37
|
+
|
|
38
|
+
Pull requests welcome. Please see [CONTRIBUTING.md](https://github.com/webex/webex-js-sdk/blob/master/CONTRIBUTING.md) for more details.
|
|
39
|
+
|
|
40
|
+
## License
|
|
41
|
+
|
|
42
|
+
© 2016-2020 Cisco and/or its affiliates. All Rights Reserved.
|
package/babel.config.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
const babelConfigLegacy = require('@webex/babel-config-legacy');
|
|
2
|
-
|
|
3
|
-
module.exports = babelConfigLegacy;
|
|
1
|
+
const babelConfigLegacy = require('@webex/babel-config-legacy');
|
|
2
|
+
|
|
3
|
+
module.exports = babelConfigLegacy;
|
package/dist/board.js
CHANGED
|
@@ -31,15 +31,15 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
31
31
|
children: {
|
|
32
32
|
realtime: _realtime.default
|
|
33
33
|
},
|
|
34
|
-
/**
|
|
35
|
-
* Adds Content to a Channel
|
|
36
|
-
* If contents length is greater than config.board.numberContentsPerPageForAdd, this method
|
|
37
|
-
* will break contents into chunks and make multiple GET request to the
|
|
38
|
-
* board service
|
|
39
|
-
* @memberof Board.BoardService
|
|
40
|
-
* @param {Board~Channel} channel
|
|
41
|
-
* @param {Array} contents - Array of {@link Board~Content} objects
|
|
42
|
-
* @returns {Promise<Board~Content>}
|
|
34
|
+
/**
|
|
35
|
+
* Adds Content to a Channel
|
|
36
|
+
* If contents length is greater than config.board.numberContentsPerPageForAdd, this method
|
|
37
|
+
* will break contents into chunks and make multiple GET request to the
|
|
38
|
+
* board service
|
|
39
|
+
* @memberof Board.BoardService
|
|
40
|
+
* @param {Board~Channel} channel
|
|
41
|
+
* @param {Array} contents - Array of {@link Board~Content} objects
|
|
42
|
+
* @returns {Promise<Board~Content>}
|
|
43
43
|
*/
|
|
44
44
|
addContent: function addContent(channel, contents) {
|
|
45
45
|
var _this = this;
|
|
@@ -52,15 +52,15 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
52
52
|
return _this._addContentChunk.bind(_this, channel, part);
|
|
53
53
|
}));
|
|
54
54
|
},
|
|
55
|
-
/**
|
|
56
|
-
* Adds Image to a Channel
|
|
57
|
-
* Uploads image to webex files and adds SCR + downloadUrl to the persistence
|
|
58
|
-
* service
|
|
59
|
-
* @memberof Board.BoardService
|
|
60
|
-
* @param {Board~Channel} channel
|
|
61
|
-
* @param {File} image - image to be uploaded
|
|
62
|
-
* @param {Object} metadata - metadata such as displayName
|
|
63
|
-
* @returns {Promise<Board~Content>}
|
|
55
|
+
/**
|
|
56
|
+
* Adds Image to a Channel
|
|
57
|
+
* Uploads image to webex files and adds SCR + downloadUrl to the persistence
|
|
58
|
+
* service
|
|
59
|
+
* @memberof Board.BoardService
|
|
60
|
+
* @param {Board~Channel} channel
|
|
61
|
+
* @param {File} image - image to be uploaded
|
|
62
|
+
* @param {Object} metadata - metadata such as displayName
|
|
63
|
+
* @returns {Promise<Board~Content>}
|
|
64
64
|
*/
|
|
65
65
|
addImage: function addImage(channel, image, metadata) {
|
|
66
66
|
var _this2 = this;
|
|
@@ -77,12 +77,12 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
77
77
|
}]);
|
|
78
78
|
});
|
|
79
79
|
},
|
|
80
|
-
/**
|
|
81
|
-
* Set a snapshot image for a board
|
|
82
|
-
*
|
|
83
|
-
* @param {Board~Channel} channel
|
|
84
|
-
* @param {File} image
|
|
85
|
-
* @returns {Promise<Board~Channel>}
|
|
80
|
+
/**
|
|
81
|
+
* Set a snapshot image for a board
|
|
82
|
+
*
|
|
83
|
+
* @param {Board~Channel} channel
|
|
84
|
+
* @param {File} image
|
|
85
|
+
* @returns {Promise<Board~Channel>}
|
|
86
86
|
*/
|
|
87
87
|
setSnapshotImage: function setSnapshotImage(channel, image) {
|
|
88
88
|
var _this3 = this;
|
|
@@ -116,12 +116,12 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
116
116
|
return res.body;
|
|
117
117
|
});
|
|
118
118
|
},
|
|
119
|
-
/**
|
|
120
|
-
* Creates a Channel
|
|
121
|
-
* @memberof Board.BoardService
|
|
122
|
-
* @param {Conversation~ConversationObject} conversation
|
|
123
|
-
* @param {Board~Channel} channel
|
|
124
|
-
* @returns {Promise<Board~Channel>}
|
|
119
|
+
/**
|
|
120
|
+
* Creates a Channel
|
|
121
|
+
* @memberof Board.BoardService
|
|
122
|
+
* @param {Conversation~ConversationObject} conversation
|
|
123
|
+
* @param {Board~Channel} channel
|
|
124
|
+
* @returns {Promise<Board~Channel>}
|
|
125
125
|
*/
|
|
126
126
|
createChannel: function createChannel(conversation, channel) {
|
|
127
127
|
return this.webex.request({
|
|
@@ -144,14 +144,14 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
144
144
|
}
|
|
145
145
|
}, channel);
|
|
146
146
|
},
|
|
147
|
-
/**
|
|
148
|
-
* Deletes a Channel from a Conversation
|
|
149
|
-
* @memberof Board.BoardService
|
|
150
|
-
* @param {Conversation~ConversationObject} conversation
|
|
151
|
-
* @param {Board~Channel} channel
|
|
152
|
-
* @param {Object} options
|
|
153
|
-
* @param {Object} options.preventDeleteActiveChannel Returns error if channel is in use
|
|
154
|
-
* @returns {Promise}
|
|
147
|
+
/**
|
|
148
|
+
* Deletes a Channel from a Conversation
|
|
149
|
+
* @memberof Board.BoardService
|
|
150
|
+
* @param {Conversation~ConversationObject} conversation
|
|
151
|
+
* @param {Board~Channel} channel
|
|
152
|
+
* @param {Object} options
|
|
153
|
+
* @param {Object} options.preventDeleteActiveChannel Returns error if channel is in use
|
|
154
|
+
* @returns {Promise}
|
|
155
155
|
*/
|
|
156
156
|
deleteChannel: function deleteChannel(conversation, channel) {
|
|
157
157
|
var _this4 = this;
|
|
@@ -183,12 +183,12 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
183
183
|
return res.body;
|
|
184
184
|
});
|
|
185
185
|
},
|
|
186
|
-
/**
|
|
187
|
-
* Locks and marks a channel for deletion
|
|
188
|
-
* If a channel is being used, it will return 409 - Conflict
|
|
189
|
-
* @memberof Board.BoardService
|
|
190
|
-
* @param {Board~Channel} channel
|
|
191
|
-
* @returns {Promise}
|
|
186
|
+
/**
|
|
187
|
+
* Locks and marks a channel for deletion
|
|
188
|
+
* If a channel is being used, it will return 409 - Conflict
|
|
189
|
+
* @memberof Board.BoardService
|
|
190
|
+
* @param {Board~Channel} channel
|
|
191
|
+
* @returns {Promise}
|
|
192
192
|
*/
|
|
193
193
|
lockChannelForDeletion: function lockChannelForDeletion(channel) {
|
|
194
194
|
return this.webex.request({
|
|
@@ -201,10 +201,10 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
201
201
|
return res.body;
|
|
202
202
|
});
|
|
203
203
|
},
|
|
204
|
-
/**
|
|
205
|
-
* Keeps a channel as 'active' to prevent other people from deleting it
|
|
206
|
-
* @param {Board~Channel} channel
|
|
207
|
-
* @returns {Promise}
|
|
204
|
+
/**
|
|
205
|
+
* Keeps a channel as 'active' to prevent other people from deleting it
|
|
206
|
+
* @param {Board~Channel} channel
|
|
207
|
+
* @returns {Promise}
|
|
208
208
|
*/
|
|
209
209
|
keepActive: function keepActive(channel) {
|
|
210
210
|
return this.webex.request({
|
|
@@ -212,12 +212,12 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
212
212
|
uri: "".concat(channel.channelUrl, "/keepAlive")
|
|
213
213
|
});
|
|
214
214
|
},
|
|
215
|
-
/**
|
|
216
|
-
* Decrypts a collection of content objects
|
|
217
|
-
*
|
|
218
|
-
* @memberof Board.BoardService
|
|
219
|
-
* @param {Array} contents curves, text, and images
|
|
220
|
-
* @returns {Promise<Array>} Resolves with an array of {@link Board~Content} objects.
|
|
215
|
+
/**
|
|
216
|
+
* Decrypts a collection of content objects
|
|
217
|
+
*
|
|
218
|
+
* @memberof Board.BoardService
|
|
219
|
+
* @param {Array} contents curves, text, and images
|
|
220
|
+
* @returns {Promise<Array>} Resolves with an array of {@link Board~Content} objects.
|
|
221
221
|
*/
|
|
222
222
|
decryptContents: function decryptContents(contents) {
|
|
223
223
|
var _this5 = this;
|
|
@@ -235,24 +235,24 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
235
235
|
});
|
|
236
236
|
}));
|
|
237
237
|
},
|
|
238
|
-
/**
|
|
239
|
-
* Decryts a single STRING content object
|
|
240
|
-
* @memberof Board.BoardService
|
|
241
|
-
* @param {string} encryptionKeyUrl
|
|
242
|
-
* @param {string} encryptedData
|
|
243
|
-
* @returns {Promise<Board~Content>}
|
|
238
|
+
/**
|
|
239
|
+
* Decryts a single STRING content object
|
|
240
|
+
* @memberof Board.BoardService
|
|
241
|
+
* @param {string} encryptionKeyUrl
|
|
242
|
+
* @param {string} encryptedData
|
|
243
|
+
* @returns {Promise<Board~Content>}
|
|
244
244
|
*/
|
|
245
245
|
decryptSingleContent: function decryptSingleContent(encryptionKeyUrl, encryptedData) {
|
|
246
246
|
return this.webex.internal.encryption.decryptText(encryptionKeyUrl, encryptedData).then(function (res) {
|
|
247
247
|
return JSON.parse(res);
|
|
248
248
|
});
|
|
249
249
|
},
|
|
250
|
-
/**
|
|
251
|
-
* Decryts a single FILE content object
|
|
252
|
-
* @memberof Board.BoardService
|
|
253
|
-
* @param {string} encryptionKeyUrl
|
|
254
|
-
* @param {object} encryptedContent {file, payload}
|
|
255
|
-
* @returns {Promise<Board~Content>}
|
|
250
|
+
/**
|
|
251
|
+
* Decryts a single FILE content object
|
|
252
|
+
* @memberof Board.BoardService
|
|
253
|
+
* @param {string} encryptionKeyUrl
|
|
254
|
+
* @param {object} encryptedContent {file, payload}
|
|
255
|
+
* @returns {Promise<Board~Content>}
|
|
256
256
|
*/
|
|
257
257
|
decryptSingleFileContent: function decryptSingleFileContent(encryptionKeyUrl, encryptedContent) {
|
|
258
258
|
var _this6 = this;
|
|
@@ -278,11 +278,11 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
278
278
|
return encryptedContent;
|
|
279
279
|
});
|
|
280
280
|
},
|
|
281
|
-
/**
|
|
282
|
-
* Deletes all Content from a Channel
|
|
283
|
-
* @memberof Board.BoardService
|
|
284
|
-
* @param {Board~Channel} channel
|
|
285
|
-
* @returns {Promise} Resolves with an content response
|
|
281
|
+
/**
|
|
282
|
+
* Deletes all Content from a Channel
|
|
283
|
+
* @memberof Board.BoardService
|
|
284
|
+
* @param {Board~Channel} channel
|
|
285
|
+
* @returns {Promise} Resolves with an content response
|
|
286
286
|
*/
|
|
287
287
|
deleteAllContent: function deleteAllContent(channel) {
|
|
288
288
|
return this.webex.request({
|
|
@@ -292,12 +292,12 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
292
292
|
return res.body;
|
|
293
293
|
});
|
|
294
294
|
},
|
|
295
|
-
/**
|
|
296
|
-
* Deletes Contents from a Channel except the ones listed in contentsToKeep
|
|
297
|
-
* @memberof Board.BoardService
|
|
298
|
-
* @param {Board~Channel} channel
|
|
299
|
-
* @param {Array<Board~Content>} contentsToKeep Array of board objects (curves, text, and images) with valid contentId (received from server)
|
|
300
|
-
* @returns {Promise} Resolves with an content response
|
|
295
|
+
/**
|
|
296
|
+
* Deletes Contents from a Channel except the ones listed in contentsToKeep
|
|
297
|
+
* @memberof Board.BoardService
|
|
298
|
+
* @param {Board~Channel} channel
|
|
299
|
+
* @param {Array<Board~Content>} contentsToKeep Array of board objects (curves, text, and images) with valid contentId (received from server)
|
|
300
|
+
* @returns {Promise} Resolves with an content response
|
|
301
301
|
*/
|
|
302
302
|
deletePartialContent: function deletePartialContent(channel, contentsToKeep) {
|
|
303
303
|
var body = contentsToKeep.map(function (content) {
|
|
@@ -314,12 +314,12 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
314
314
|
return res.body;
|
|
315
315
|
});
|
|
316
316
|
},
|
|
317
|
-
/**
|
|
318
|
-
* Encrypts a collection of content
|
|
319
|
-
* @memberof Board.BoardService
|
|
320
|
-
* @param {string} encryptionKeyUrl channel.defaultEncryptionKeyUrl
|
|
321
|
-
* @param {Array} contents Array of {@link Board~Content} objects. (curves, text, and images)
|
|
322
|
-
* @returns {Promise<Array>} Resolves with an array of encrypted {@link Board~Content} objects.
|
|
317
|
+
/**
|
|
318
|
+
* Encrypts a collection of content
|
|
319
|
+
* @memberof Board.BoardService
|
|
320
|
+
* @param {string} encryptionKeyUrl channel.defaultEncryptionKeyUrl
|
|
321
|
+
* @param {Array} contents Array of {@link Board~Content} objects. (curves, text, and images)
|
|
322
|
+
* @returns {Promise<Array>} Resolves with an array of encrypted {@link Board~Content} objects.
|
|
323
323
|
*/
|
|
324
324
|
encryptContents: function encryptContents(encryptionKeyUrl, contents) {
|
|
325
325
|
var _this7 = this;
|
|
@@ -343,12 +343,12 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
343
343
|
});
|
|
344
344
|
}));
|
|
345
345
|
},
|
|
346
|
-
/**
|
|
347
|
-
* Encrypts a single STRING content object
|
|
348
|
-
* @memberof Board.BoardService
|
|
349
|
-
* @param {string} encryptionKeyUrl
|
|
350
|
-
* @param {Board~Content} content
|
|
351
|
-
* @returns {Promise<Board~Content>}
|
|
346
|
+
/**
|
|
347
|
+
* Encrypts a single STRING content object
|
|
348
|
+
* @memberof Board.BoardService
|
|
349
|
+
* @param {string} encryptionKeyUrl
|
|
350
|
+
* @param {Board~Content} content
|
|
351
|
+
* @returns {Promise<Board~Content>}
|
|
352
352
|
*/
|
|
353
353
|
encryptSingleContent: function encryptSingleContent(encryptionKeyUrl, content) {
|
|
354
354
|
return this.webex.internal.encryption.encryptText(encryptionKeyUrl, (0, _stringify.default)(content)).then(function (res) {
|
|
@@ -358,12 +358,12 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
358
358
|
};
|
|
359
359
|
});
|
|
360
360
|
},
|
|
361
|
-
/**
|
|
362
|
-
* Encrypts a single FILE content object
|
|
363
|
-
* @memberof Board.BoardService
|
|
364
|
-
* @param {string} encryptionKeyUrl
|
|
365
|
-
* @param {Board~Content} content
|
|
366
|
-
* @returns {Promise<Board~Content>}
|
|
361
|
+
/**
|
|
362
|
+
* Encrypts a single FILE content object
|
|
363
|
+
* @memberof Board.BoardService
|
|
364
|
+
* @param {string} encryptionKeyUrl
|
|
365
|
+
* @param {Board~Content} content
|
|
366
|
+
* @returns {Promise<Board~Content>}
|
|
367
367
|
*/
|
|
368
368
|
encryptSingleFileContent: function encryptSingleFileContent(encryptionKeyUrl, content) {
|
|
369
369
|
var _this8 = this;
|
|
@@ -388,13 +388,13 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
388
388
|
};
|
|
389
389
|
});
|
|
390
390
|
},
|
|
391
|
-
/**
|
|
392
|
-
* Retrieves contents from a specified channel
|
|
393
|
-
* @memberof Board.BoardService
|
|
394
|
-
* @param {Board~Channel} channel
|
|
395
|
-
* @param {Object} options
|
|
396
|
-
* @param {Object} options.qs
|
|
397
|
-
* @returns {Promise<Page<Board~Channel>>} Resolves with an array of Content items
|
|
391
|
+
/**
|
|
392
|
+
* Retrieves contents from a specified channel
|
|
393
|
+
* @memberof Board.BoardService
|
|
394
|
+
* @param {Board~Channel} channel
|
|
395
|
+
* @param {Object} options
|
|
396
|
+
* @param {Object} options.qs
|
|
397
|
+
* @returns {Promise<Page<Board~Channel>>} Resolves with an array of Content items
|
|
398
398
|
*/
|
|
399
399
|
getContents: function getContents(channel, options) {
|
|
400
400
|
var _this9 = this;
|
|
@@ -410,11 +410,11 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
410
410
|
return new _webexCore.Page(res, _this9.webex);
|
|
411
411
|
});
|
|
412
412
|
},
|
|
413
|
-
/**
|
|
414
|
-
* Gets a Channel
|
|
415
|
-
* @memberof Board.BoardService
|
|
416
|
-
* @param {Board~Channel} channel
|
|
417
|
-
* @returns {Promise<Board~Channel>}
|
|
413
|
+
/**
|
|
414
|
+
* Gets a Channel
|
|
415
|
+
* @memberof Board.BoardService
|
|
416
|
+
* @param {Board~Channel} channel
|
|
417
|
+
* @returns {Promise<Board~Channel>}
|
|
418
418
|
*/
|
|
419
419
|
getChannel: function getChannel(channel) {
|
|
420
420
|
return this.webex.request({
|
|
@@ -424,14 +424,14 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
424
424
|
return res.body;
|
|
425
425
|
});
|
|
426
426
|
},
|
|
427
|
-
/**
|
|
428
|
-
* Gets Channels
|
|
429
|
-
* @memberof Board.BoardService
|
|
430
|
-
* @param {Conversation~ConversationObject} conversation
|
|
431
|
-
* @param {Object} options
|
|
432
|
-
* @param {number} options.channelsLimit number of boards to return per page
|
|
433
|
-
* @param {number} options.type type of whiteboard: whiteboard or annotated
|
|
434
|
-
* @returns {Promise<Page<Board~Channel>>} Resolves with an array of Channel items
|
|
427
|
+
/**
|
|
428
|
+
* Gets Channels
|
|
429
|
+
* @memberof Board.BoardService
|
|
430
|
+
* @param {Conversation~ConversationObject} conversation
|
|
431
|
+
* @param {Object} options
|
|
432
|
+
* @param {number} options.channelsLimit number of boards to return per page
|
|
433
|
+
* @param {number} options.type type of whiteboard: whiteboard or annotated
|
|
434
|
+
* @returns {Promise<Page<Board~Channel>>} Resolves with an array of Channel items
|
|
435
435
|
*/
|
|
436
436
|
getChannels: function getChannels(conversation, options) {
|
|
437
437
|
var _this10 = this;
|
|
@@ -451,10 +451,10 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
451
451
|
return new _webexCore.Page(res, _this10.webex);
|
|
452
452
|
});
|
|
453
453
|
},
|
|
454
|
-
/**
|
|
455
|
-
* Pings persistence
|
|
456
|
-
* @memberof Board.BoardService
|
|
457
|
-
* @returns {Promise<Object>} ping response body
|
|
454
|
+
/**
|
|
455
|
+
* Pings persistence
|
|
456
|
+
* @memberof Board.BoardService
|
|
457
|
+
* @returns {Promise<Object>} ping response body
|
|
458
458
|
*/
|
|
459
459
|
ping: function ping() {
|
|
460
460
|
return this.webex.request({
|
|
@@ -478,11 +478,11 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
478
478
|
return message;
|
|
479
479
|
});
|
|
480
480
|
},
|
|
481
|
-
/**
|
|
482
|
-
* Registers with Mercury
|
|
483
|
-
* @memberof Board.BoardService
|
|
484
|
-
* @param {Object} data - Mercury bindings
|
|
485
|
-
* @returns {Promise<Board~Registration>}
|
|
481
|
+
/**
|
|
482
|
+
* Registers with Mercury
|
|
483
|
+
* @memberof Board.BoardService
|
|
484
|
+
* @param {Object} data - Mercury bindings
|
|
485
|
+
* @returns {Promise<Board~Registration>}
|
|
486
486
|
*/
|
|
487
487
|
register: function register(data) {
|
|
488
488
|
return this.webex.request({
|
|
@@ -494,11 +494,11 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
494
494
|
return res.body;
|
|
495
495
|
});
|
|
496
496
|
},
|
|
497
|
-
/**
|
|
498
|
-
* Registers with Mercury for sharing web socket
|
|
499
|
-
* @memberof Board.BoardService
|
|
500
|
-
* @param {Board~Channel} channel
|
|
501
|
-
* @returns {Promise<Board~Registration>}
|
|
497
|
+
/**
|
|
498
|
+
* Registers with Mercury for sharing web socket
|
|
499
|
+
* @memberof Board.BoardService
|
|
500
|
+
* @param {Board~Channel} channel
|
|
501
|
+
* @returns {Promise<Board~Registration>}
|
|
502
502
|
*/
|
|
503
503
|
registerToShareMercury: function registerToShareMercury(channel) {
|
|
504
504
|
var _this11 = this;
|
|
@@ -525,12 +525,12 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
525
525
|
return res.body;
|
|
526
526
|
});
|
|
527
527
|
},
|
|
528
|
-
/**
|
|
529
|
-
* Remove board binding from existing mercury connection
|
|
530
|
-
* @memberof Board.BoardService
|
|
531
|
-
* @param {Board~Channel} channel
|
|
532
|
-
* @param {String} binding - the binding as provided in board registration
|
|
533
|
-
* @returns {Promise<Board~Registration>}
|
|
528
|
+
/**
|
|
529
|
+
* Remove board binding from existing mercury connection
|
|
530
|
+
* @memberof Board.BoardService
|
|
531
|
+
* @param {Board~Channel} channel
|
|
532
|
+
* @param {String} binding - the binding as provided in board registration
|
|
533
|
+
* @returns {Promise<Board~Registration>}
|
|
534
534
|
*/
|
|
535
535
|
unregisterFromSharedMercury: function unregisterFromSharedMercury(channel, binding) {
|
|
536
536
|
var webSocketUrl = this.webex.internal.device.webSocketUrl;
|
|
@@ -559,15 +559,15 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
559
559
|
return res.body;
|
|
560
560
|
});
|
|
561
561
|
},
|
|
562
|
-
/**
|
|
563
|
-
* Encrypts and uploads image to WebexFiles
|
|
564
|
-
* @memberof Board.BoardService
|
|
565
|
-
* @param {Board~Channel} channel
|
|
566
|
-
* @param {File} file - File to be uploaded
|
|
567
|
-
* @param {Object} options
|
|
568
|
-
* @param {Object} options.hiddenSpace - true for hidden, false for open space
|
|
569
|
-
* @private
|
|
570
|
-
* @returns {Object} Encrypted Scr and KeyUrl
|
|
562
|
+
/**
|
|
563
|
+
* Encrypts and uploads image to WebexFiles
|
|
564
|
+
* @memberof Board.BoardService
|
|
565
|
+
* @param {Board~Channel} channel
|
|
566
|
+
* @param {File} file - File to be uploaded
|
|
567
|
+
* @param {Object} options
|
|
568
|
+
* @param {Object} options.hiddenSpace - true for hidden, false for open space
|
|
569
|
+
* @private
|
|
570
|
+
* @returns {Object} Encrypted Scr and KeyUrl
|
|
571
571
|
*/
|
|
572
572
|
_uploadImage: function _uploadImage(channel, file, options) {
|
|
573
573
|
var _this13 = this;
|
|
@@ -628,11 +628,11 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
628
628
|
});
|
|
629
629
|
});
|
|
630
630
|
},
|
|
631
|
-
/** Authorize transcoder (for sharing whiteboard to mobile)
|
|
632
|
-
*
|
|
633
|
-
* @param {Board~Channel} board
|
|
634
|
-
* @memberof Board.BoardService
|
|
635
|
-
* @returns {String} authorization
|
|
631
|
+
/** Authorize transcoder (for sharing whiteboard to mobile)
|
|
632
|
+
*
|
|
633
|
+
* @param {Board~Channel} board
|
|
634
|
+
* @memberof Board.BoardService
|
|
635
|
+
* @returns {String} authorization
|
|
636
636
|
*/
|
|
637
637
|
authorizeMediaInjector: function authorizeMediaInjector(board) {
|
|
638
638
|
var _this15 = this;
|
|
@@ -661,18 +661,18 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
661
661
|
return undefined;
|
|
662
662
|
}).catch(function (err) {
|
|
663
663
|
return (
|
|
664
|
-
/* We want to resolve any errors so that whiteboard share will still work
|
|
665
|
-
* except mobile being able to receive the share
|
|
664
|
+
/* We want to resolve any errors so that whiteboard share will still work
|
|
665
|
+
* except mobile being able to receive the share
|
|
666
666
|
*/
|
|
667
667
|
_promise.default.resolve(err)
|
|
668
668
|
);
|
|
669
669
|
});
|
|
670
670
|
},
|
|
671
|
-
/** Unauthorize transcoder (for stopping whiteboard share to mobile)
|
|
672
|
-
*
|
|
673
|
-
* @param {Board~Channel} board
|
|
674
|
-
* @memberof Board.BoardService
|
|
675
|
-
* @returns {Array} list of authIds removed
|
|
671
|
+
/** Unauthorize transcoder (for stopping whiteboard share to mobile)
|
|
672
|
+
*
|
|
673
|
+
* @param {Board~Channel} board
|
|
674
|
+
* @memberof Board.BoardService
|
|
675
|
+
* @returns {Array} list of authIds removed
|
|
676
676
|
*/
|
|
677
677
|
unauthorizeMediaInjector: function unauthorizeMediaInjector(board) {
|
|
678
678
|
var _this16 = this;
|
|
@@ -682,8 +682,8 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
682
682
|
return this.webex.internal.encryption.kms.listAuthorizations({
|
|
683
683
|
kroUri: board.kmsResourceUrl
|
|
684
684
|
}).then(function (authorizations) {
|
|
685
|
-
/* Attempt to remove the authorization made from starting whiteboard share
|
|
686
|
-
* Also removing any previous authorizations that were not cleared
|
|
685
|
+
/* Attempt to remove the authorization made from starting whiteboard share
|
|
686
|
+
* Also removing any previous authorizations that were not cleared
|
|
687
687
|
*/
|
|
688
688
|
var promises = authorizations.map(function (auth) {
|
|
689
689
|
var authId = auth.authId;
|
|
@@ -694,8 +694,8 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
694
694
|
return _promise.default.resolve(authId);
|
|
695
695
|
}).catch(function (err) {
|
|
696
696
|
return (
|
|
697
|
-
/* We don't want this to error out, otherwise the
|
|
698
|
-
* Promise.all will not process the rest of the request
|
|
697
|
+
/* We don't want this to error out, otherwise the
|
|
698
|
+
* Promise.all will not process the rest of the request
|
|
699
699
|
*/
|
|
700
700
|
_promise.default.resolve(err)
|
|
701
701
|
);
|
|
@@ -709,7 +709,7 @@ var Board = _webexCore.WebexPlugin.extend({
|
|
|
709
709
|
return _promise.default.resolve([]);
|
|
710
710
|
});
|
|
711
711
|
},
|
|
712
|
-
version: "2.59.
|
|
712
|
+
version: "2.59.0"
|
|
713
713
|
});
|
|
714
714
|
var _default = Board;
|
|
715
715
|
exports.default = _default;
|