@reactoo/watchtogether-sdk-js 2.5.41 → 2.5.42
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/package.json
CHANGED
package/src/models/room.js
CHANGED
|
@@ -54,17 +54,19 @@ let room = function () {
|
|
|
54
54
|
}))
|
|
55
55
|
},
|
|
56
56
|
|
|
57
|
-
createRoom: ({title, description, isPublic,
|
|
57
|
+
createRoom: ({title, description, isPublic, isStudioLayout, wtChannelId, isHd, disableSync, reduceRoomControls, hasStudioChat, maxParticipants, customAttributes, chatRoomId, linkedRoomId, dotAttribute} = {}) => {
|
|
58
|
+
let _da = dotAttribute
|
|
59
|
+
? (Array.isArray(dotAttribute)
|
|
60
|
+
? dotAttribute.reduce((p, cv) => (p[cv.name] = cv.value) && p || p, {})
|
|
61
|
+
: {[dotAttribute.name]: dotAttribute.value})
|
|
62
|
+
: {};
|
|
58
63
|
return this.__privates.auth.__client
|
|
59
64
|
.then(client => client.apis.wt.createRoom({}, {
|
|
60
65
|
requestBody: {
|
|
61
66
|
title,
|
|
62
67
|
description,
|
|
63
68
|
isPublic,
|
|
64
|
-
isListed,
|
|
65
69
|
isStudioLayout,
|
|
66
|
-
instanceType: this.__instanceType,
|
|
67
|
-
allowedParticipants,
|
|
68
70
|
wtChannelId,
|
|
69
71
|
isHd,
|
|
70
72
|
disableSync,
|
|
@@ -73,12 +75,14 @@ let room = function () {
|
|
|
73
75
|
linkedRoomId,
|
|
74
76
|
hasStudioChat,
|
|
75
77
|
maxParticipants,
|
|
76
|
-
customAttributes
|
|
78
|
+
customAttributes,
|
|
79
|
+
..._da,
|
|
80
|
+
instanceType: this.__instanceType,
|
|
77
81
|
}
|
|
78
82
|
}))
|
|
79
83
|
},
|
|
80
84
|
|
|
81
|
-
updateRoom: ({roomId, title, description, isPublic,
|
|
85
|
+
updateRoom: ({roomId, title, description, isPublic, recordings, slug, password, maxParticipants, setInstanceType = false, wtChannelId, isHd, isStudioLayout, hasStudioChat, reduceRoomControls, chatRoomId, linkedRoomId, disableSync, defaultRegion, customAttributes, dotAttribute} = {}) => {
|
|
82
86
|
let _da = dotAttribute
|
|
83
87
|
? (Array.isArray(dotAttribute)
|
|
84
88
|
? dotAttribute.reduce((p, cv) => (p[cv.name] = cv.value) && p || p, {})
|
|
@@ -87,13 +91,11 @@ let room = function () {
|
|
|
87
91
|
return this.__privates.auth.__client
|
|
88
92
|
.then(client => client.apis.wt.updateRoom({id: roomId}, {
|
|
89
93
|
requestBody: {
|
|
90
|
-
..._da,
|
|
91
94
|
title,
|
|
92
95
|
description,
|
|
93
96
|
slug,
|
|
94
97
|
password,
|
|
95
98
|
isPublic,
|
|
96
|
-
isListed,
|
|
97
99
|
isHd,
|
|
98
100
|
isStudioLayout,
|
|
99
101
|
hasStudioChat,
|
|
@@ -104,7 +106,10 @@ let room = function () {
|
|
|
104
106
|
disableSync,
|
|
105
107
|
defaultRegion,
|
|
106
108
|
customAttributes,
|
|
107
|
-
wtChannelId,
|
|
109
|
+
wtChannelId,
|
|
110
|
+
..._da,
|
|
111
|
+
...(setInstanceType && {instanceType: setInstanceType === true ? this.__instanceType : setInstanceType}),
|
|
112
|
+
...(recordings && {recordings})
|
|
108
113
|
}
|
|
109
114
|
}))
|
|
110
115
|
},
|