@daily-co/daily-js
Advanced tools
Comparing version 0.9.981 to 0.9.982
{ | ||
"name": "@daily-co/daily-js", | ||
"version": "0.9.981", | ||
"version": "0.9.982", | ||
"engines": { | ||
@@ -5,0 +5,0 @@ "node": ">=10.0.0" |
@@ -85,4 +85,5 @@ | ||
export const DAILY_METHOD_SET_NETWORK_TOPOLOGY = 'set-network-topology'; | ||
export const DAILY_METHOD_SET_PLAY_DING = 'daily-method-set-play-ding'; | ||
export const DAILY_CUSTOM_TRACK = 'daily-custom-track'; | ||
export const DAILY_UI_REQUEST_FULLSCREEN = 'request-fullscreen'; | ||
export const DAILY_UI_EXIT_FULLSCREEN = 'request-exit-fullscreen'; |
@@ -79,2 +79,3 @@ import EventEmitter from 'events'; | ||
DAILY_METHOD_SET_NETWORK_TOPOLOGY, | ||
DAILY_METHOD_SET_PLAY_DING, | ||
DAILY_CUSTOM_TRACK, | ||
@@ -390,4 +391,6 @@ DAILY_UI_REQUEST_FULLSCREEN, | ||
destroy() { | ||
try { this.leave(); } catch (e) {} | ||
async destroy() { | ||
try { | ||
await this.leave(); | ||
} catch (e) {} | ||
let iframe = this.iframe(); | ||
@@ -707,3 +710,5 @@ if (iframe) { | ||
if (this._iframe) { | ||
this._iframe.src = ''; | ||
// resetting the iframe src maybe interferes with sending the | ||
// ks beacon? | ||
// this._iframe.src = ''; | ||
} | ||
@@ -743,2 +748,6 @@ this._loaded = false; | ||
getNetworkStats() { | ||
if (this._meetingState !== DAILY_STATE_JOINED) { | ||
let stats = { latest: {} }; | ||
return { stats }; | ||
} | ||
return new Promise((resolve, reject) => { | ||
@@ -757,3 +766,3 @@ let k = (msg) => { | ||
async enumerateDevices(kind) { | ||
if (this._callObjectMode && this.meetingState !== DAILY_STATE_JOINED) { | ||
if (this._callObjectMode) { | ||
let raw = await navigator.mediaDevices.enumerateDevices(); | ||
@@ -870,2 +879,11 @@ return { devices: raw.map((d) => JSON.parse(JSON.stringify(d))) }; | ||
setPlayNewParticipantSound(arg) { | ||
if (!(typeof arg === 'number' || | ||
arg === true || | ||
arg === false)) { | ||
throw new Error(`argument to setShouldPlayNewParticipantSound should be true, false, or a number, but is ${arg}`); | ||
} | ||
this._sendIframeMsg({ action: DAILY_METHOD_SET_PLAY_DING, arg }); | ||
} | ||
// | ||
@@ -1353,2 +1371,17 @@ // internal methods | ||
safe[p] = DAILY_CUSTOM_TRACK; | ||
} else if (p === 'dailyConfig') { | ||
if (props[p].modifyLocalSdpHook) { | ||
if (window._dailyConfig) { | ||
window._dailyConfig.modifyLocalSdpHook = props[p].modifyLocalSdpHook; | ||
} | ||
delete props[p].modifyLocalSdpHook; | ||
} | ||
if (props[p].modifyRemoteSdpHook) { | ||
if (window._dailyConfig) { | ||
window._dailyConfig.modifyRemoteSdpHook = | ||
props[p].modifyRemoteSdpHook; | ||
} | ||
delete props[p].modifyRemoteSdpHook; | ||
} | ||
safe[p] = props[p]; | ||
} else { | ||
@@ -1355,0 +1388,0 @@ safe[p] = props[p]; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2404778
24
2043