@daily-co/daily-js
Advanced tools
Comparing version 0.12.0 to 0.13.0
@@ -18,13 +18,14 @@ // Type definitions for daily-js | ||
| 'en' | ||
| 'es' | ||
| 'fi' | ||
| 'fr' | ||
| 'it' | ||
| 'jp' | ||
| 'ka' | ||
| 'nl' | ||
| 'no' | ||
| 'pl' | ||
| 'pt' | ||
| 'pl' | ||
| 'sv' | ||
| 'es' | ||
| 'tr' | ||
| 'it' | ||
| 'ka' | ||
| 'jp'; | ||
| 'tr'; | ||
@@ -74,3 +75,5 @@ export type DailyLanguageSetting = DailyLanguage | 'user'; | ||
| 'live-streaming-error' | ||
| 'lang-updated' | ||
| 'access-state-updated' | ||
| 'meeting-session-updated' | ||
| 'waiting-participant-added' | ||
@@ -354,2 +357,6 @@ | 'waiting-participant-updated' | ||
export interface DailyMeetingSession { | ||
id: string; | ||
} | ||
export interface DailyEventObjectNoPayload { | ||
@@ -427,2 +434,7 @@ action: Extract< | ||
export interface DailyEventObjectMeetingSessionUpdated { | ||
action: Extract<DailyEvent, 'meeting-session-updated'>; | ||
meetingSession: DailyMeetingSession; | ||
} | ||
export interface DailyEventObjectTrack { | ||
@@ -510,2 +522,8 @@ action: Extract<DailyEvent, 'track-started' | 'track-stopped'>; | ||
export interface DailyEventObjectLangUpdated { | ||
action: Extract<DailyEvent, 'lang-updated'>; | ||
lang: DailyLanguage; | ||
langSetting: DailyLanguageSetting; | ||
} | ||
export type DailyEventObject< | ||
@@ -531,2 +549,4 @@ T extends DailyEvent = any | ||
? DailyEventObjectAccessState | ||
: T extends DailyEventObjectMeetingSessionUpdated['action'] | ||
? DailyEventObjectMeetingSessionUpdated | ||
: T extends DailyEventObjectTrack['action'] | ||
@@ -548,2 +568,4 @@ ? DailyEventObjectTrack | ||
? DailyEventObjectActiveSpeakerModeChange | ||
: T extends DailyEventObjectLangUpdated['action'] | ||
? DailyEventObjectLangUpdated | ||
: any; | ||
@@ -656,2 +678,5 @@ | ||
setDailyLang(lang: DailyLanguageSetting): DailyCall; | ||
getMeetingSession(): Promise<{ | ||
meetingSession: DailyMeetingSession; | ||
}>; | ||
setUserName( | ||
@@ -658,0 +683,0 @@ name: string, |
{ | ||
"name": "@daily-co/daily-js", | ||
"version": "0.12.0", | ||
"version": "0.13.0", | ||
"engines": { | ||
@@ -5,0 +5,0 @@ "node": ">=10.0.0" |
@@ -60,2 +60,4 @@ // | ||
export const DAILY_EVENT_MEETING_SESSION_UPDATED = 'meeting-session-updated'; | ||
export const DAILY_EVENT_WAITING_PARTICIPANT_ADDED = | ||
@@ -97,2 +99,4 @@ 'waiting-participant-added'; | ||
export const DAILY_EVENT_LANG_UPDATED = 'lang-updated'; | ||
export const DAILY_EVENT_ERROR = 'error'; | ||
@@ -139,2 +143,3 @@ | ||
export const DAILY_METHOD_SET_LANG = 'set-daily-lang'; | ||
export const DAILY_METHOD_GET_MEETING_SESSION = 'get-meeting-session'; | ||
export const DAILY_METHOD_SET_USER_NAME = 'set-user-name'; | ||
@@ -141,0 +146,0 @@ export const DAILY_METHOD_DETECT_ALL_FACES = 'detect-all-faces'; |
@@ -102,3 +102,3 @@ // This method should be used instead of window.navigator.userAgent, which | ||
version = getFirefoxVersion(); | ||
return version.major < 80; | ||
return version.major < 78; | ||
case 'Safari': | ||
@@ -105,0 +105,0 @@ version = getSafariVersion(); |
import ScriptMessageChannel from './ScriptMessageChannel'; | ||
import { EventEmitter } from 'events'; | ||
import { randomStringId } from '../../utils'; | ||
@@ -92,5 +93,5 @@ // This file is imported by both daily-js and the call machine. Make sure we | ||
if (callback) { | ||
let ts = Date.now(); | ||
this._messageCallbacks[ts] = callback; | ||
message.callbackStamp = ts; | ||
let stamp = randomStringId(); | ||
this._messageCallbacks[stamp] = callback; | ||
message.callbackStamp = stamp; | ||
} | ||
@@ -97,0 +98,0 @@ // console.log(`[ReactNativeMessageChannel] ${logMessage}`, message); |
import ScriptMessageChannel from './ScriptMessageChannel'; | ||
import { IFRAME_MESSAGE_MARKER } from '../CommonIncludes'; | ||
import { randomStringId } from '../../utils'; | ||
@@ -77,5 +78,5 @@ /** | ||
if (callback) { | ||
let ts = Date.now(); | ||
this._messageCallbacks[ts] = callback; | ||
msg.callbackStamp = ts; | ||
let stamp = randomStringId(); | ||
this._messageCallbacks[stamp] = callback; | ||
msg.callbackStamp = stamp; | ||
} | ||
@@ -82,0 +83,0 @@ const w = iframe ? iframe.contentWindow : window; |
import { isSfuSupported } from './shared-with-pluot-core/Environment'; | ||
export function randomStringId() { | ||
return Date.now() + Math.random().toString(); | ||
} | ||
export function notImplementedError() { | ||
@@ -4,0 +8,0 @@ throw new Error('Method must be implemented in subclass'); |
Sorry, the diff of this file is too big to display
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
425632
5174