Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@daily-co/daily-js

Package Overview
Dependencies
Maintainers
19
Versions
152
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@daily-co/daily-js - npm Package Compare versions

Comparing version 0.21.0 to 0.22.0

91

index.d.ts

@@ -67,2 +67,3 @@ // Type definitions for daily-js

| 'error'
| 'nonfatal-error'
| 'click'

@@ -80,2 +81,5 @@ | 'mousedown'

| 'lang-updated'
| 'remote-media-player-started'
| 'remote-media-player-stopped'
| 'remote-media-player-updated'
| 'access-state-updated'

@@ -112,2 +116,7 @@ | 'meeting-session-updated'

export type DailyNonFatalErrorType =
| 'input-settings-error'
| 'screen-share-error'
| 'video-processor-error';
export type DailyNetworkTopology = 'sfu' | 'peer';

@@ -125,2 +134,3 @@

version: string;
supportsFullscreen: boolean;
supportsScreenShare: boolean;

@@ -388,7 +398,10 @@ supportsSfu: boolean;

enable_screenshare?: boolean;
enable_advanced_chat?: boolean;
enable_chat?: boolean;
enable_knocking?: boolean;
enable_network_ui?: boolean;
enable_people_ui?: boolean;
enable_prejoin_ui?: boolean;
enable_video_processing_ui?: boolean;
experimental_optimize_large_calls?: boolean;
start_video_off?: boolean;

@@ -420,2 +433,3 @@ start_audio_off?: boolean;

enable_network_ui?: boolean;
enable_people_ui?: boolean;
enable_prejoin_ui?: boolean;

@@ -526,2 +540,8 @@ enable_video_processing_ui?: boolean;

export interface DailyEventObjectNonFatalError {
action: Extract<DailyEvent, 'nonfatal-error'>;
type: DailyNonFatalErrorType;
errorMsg: string;
}
export interface DailyEventObjectGenericError {

@@ -643,5 +663,5 @@ action: Extract<DailyEvent, 'load-attempt-failed' | 'live-streaming-error'>;

export interface DailyEventObjectAppMessage {
export interface DailyEventObjectAppMessage<Data = any> {
action: Extract<DailyEvent, 'app-message'>;
data: any;
data: Data;
fromId: string;

@@ -680,2 +700,18 @@ }

export interface DailyEventObjectRemoteMediaPlayerUpdate {
action: Extract<
DailyEvent,
'remote-media-player-started' | 'remote-media-player-updated'
>;
updatedBy: string;
playerState: DailyRemoteMediaPlayerState;
}
export interface DailyEventObjectRemoteMediaPlayerStopped {
action: Extract<DailyEvent, 'remote-media-player-stopped'>;
session_id: string;
updatedBy: string;
reason: DailyRemoteMediaPlayerStopReason;
}
export type DailyEventObject<

@@ -691,2 +727,4 @@ T extends DailyEvent = any

? DailyEventObjectFatalError
: T extends DailyEventObjectNonFatalError['action']
? DailyEventObjectNonFatalError
: T extends DailyEventObjectGenericError['action']

@@ -708,2 +746,6 @@ ? DailyEventObjectGenericError

? DailyEventObjectRecordingStarted
: T extends DailyEventObjectRemoteMediaPlayerUpdate['action']
? DailyEventObjectRemoteMediaPlayerUpdate
: T extends DailyEventObjectRemoteMediaPlayerStopped['action']
? DailyEventObjectRemoteMediaPlayerStopped
: T extends DailyEventObjectMouseEvent['action']

@@ -789,2 +831,16 @@ ? DailyEventObjectMouseEvent

export type DailyRemoteMediaPlayerSettingPlay = 'play';
export type DailyRemoteMediaPlayerSettingPause = 'pause';
export type DailyRemoteMediaPlayerStatePlaying = 'playing';
export type DailyRemoteMediaPlayerStatePaused = 'paused';
export type DailyRemoteMediaPlayerStateBuffering = 'buffering';
export type DailyRemoteMediaPlayerEOS = 'EOS';
export type DailyRemoteMediaPlayerPeerStopped = 'stopped-by-peer';
export type DailyRemoteMediaPlayerStopReason =
| DailyRemoteMediaPlayerEOS
| DailyRemoteMediaPlayerPeerStopped;
export type DailyAccess = 'unknown' | SpecifiedDailyAccess;

@@ -815,2 +871,26 @@

export interface DailyRemoteMediaPlayerSettings {
state: DailyRemoteMediaPlayerSettingPlay | DailyRemoteMediaPlayerSettingPause;
// other fields like position, enocding-settings
}
export interface DailyRemoteMediaPlayerStartOptions {
url: string;
settings?: DailyRemoteMediaPlayerSettings;
}
export interface DailyRemoteMediaPlayerUpdateOptions {
session_id: string;
settings: DailyRemoteMediaPlayerSettings;
}
export interface DailyRemoteMediaPlayerState {
session_id: string;
state:
| DailyRemoteMediaPlayerStatePlaying
| DailyRemoteMediaPlayerStatePaused
| DailyRemoteMediaPlayerStateBuffering;
settings: DailyRemoteMediaPlayerSettings;
}
export interface DailyCall {

@@ -906,2 +986,9 @@ iframe(): HTMLIFrameElement | null;

stopLiveStreaming(): void;
startRemoteMediaPlayer(
options: DailyRemoteMediaPlayerStartOptions
): Promise<DailyRemoteMediaPlayerState>;
stopRemoteMediaPlayer(session_id: string): Promise<void>;
updateRemoteMediaPlayer(
options: DailyRemoteMediaPlayerUpdateOptions
): Promise<DailyRemoteMediaPlayerState>;
startTranscription(): void;

@@ -908,0 +995,0 @@ stopTranscription(): void;

6

package.json
{
"name": "@daily-co/daily-js",
"version": "0.21.0",
"version": "0.22.0",
"engines": {

@@ -19,2 +19,3 @@ "node": ">=10.0.0"

"scripts": {
"dev": "NODE_ENV=development npx webpack-dev-server --progress -c webpack.config.js",
"build": "npm run build-main && npm run build-module",

@@ -46,3 +47,4 @@ "build-dev": "NODE_ENV=development npm run build",

"webpack": "^4.41.5",
"webpack-cli": "^3.3.11"
"webpack-cli": "^3.3.11",
"webpack-dev-server": "^3.11.0"
},

@@ -49,0 +51,0 @@ "dependencies": {

@@ -178,3 +178,11 @@ import { callObjectBundleUrl } from './utils';

// console.log("[LoadAttempt] starting...");
const url = callObjectBundleUrl(this._meetingOrBaseUrl);
let url;
try {
url = callObjectBundleUrl(this._meetingOrBaseUrl);
} catch (e) {
this._failureCallback(
`Failed to get call object bundle URL ${url}: ${e}`
);
return;
}
const loadedFromIOSCache = await this._tryLoadFromIOSCache(url);

@@ -181,0 +189,0 @@ !loadedFromIOSCache && this._loadFromNetwork(url);

@@ -46,8 +46,11 @@ import {

}
const track = p.local
? getLocalCustomTrack(state, trackEntryKey, kind)
: getRemoteCustomTrack(state, p.session_id, trackEntryKey, kind);
const trackInfo = p.tracks[trackEntryKey];
if (track && trackInfo && trackInfo.state === 'playable') {
p.tracks[trackEntryKey].track = track;
if (trackInfo) {
const track = p.local
? getLocalCustomTrack(state, trackEntryKey, kind)
: getRemoteCustomTrack(state, p.session_id, trackEntryKey, kind);
if (trackInfo.state === 'playable') {
p.tracks[trackEntryKey].track = track;
}
trackInfo.persistentTrack = track;
}

@@ -54,0 +57,0 @@ }

@@ -95,2 +95,10 @@ //

export const DAILY_EVENT_REMOTE_MEDIA_PLAYER_STARTED =
'remote-media-player-started';
export const DAILY_EVENT_REMOTE_MEDIA_PLAYER_UPDATED =
'remote-media-player-updated';
export const DAILY_EVENT_REMOTE_MEDIA_PLAYER_STOPPED =
'remote-media-player-stopped';
export const DAILY_REMOTE_MEDIA_PLAYER_ERROR_TYPE = 'remote-media-player';
export const DAILY_EVENT_LOCAL_SCREEN_SHARE_STARTED =

@@ -122,7 +130,6 @@ 'local-screen-share-started';

export const DAILY_INPUT_SETTINGS_ERROR_TYPE = 'input-settings-error';
export const DAILY_SCREEN_SHARE_ERROR_TYPE = 'screen-share-error';
export const DAILY_VIDEO_PROCESSOR_ERROR_TYPE = 'video-processor-error';
export const DAILY_EVENT_ERROR = 'error';
export const DAILY_EVENT_MEDIA_INGEST_ERROR = 'media-ingest-error';
//

@@ -184,4 +191,12 @@ // internal

'daily-method-stop-live-streaming';
export const DAILY_METHOD_START_TRANSCRIPTION = 'daily-method-start-transcription';
export const DAILY_METHOD_STOP_TRANSCRIPTION = 'daily-method-stop-transcription';
export const DAILY_METHOD_START_REMOTE_MEDIA_PLAYER =
'daily-method-start-remote-media-player';
export const DAILY_METHOD_STOP_REMOTE_MEDIA_PLAYER =
'daily-method-stop-remote-media-player';
export const DAILY_METHOD_UPDATE_REMOTE_MEDIA_PLAYER =
'daily-method-update-remote-media-player';
export const DAILY_METHOD_START_TRANSCRIPTION =
'daily-method-start-transcription';
export const DAILY_METHOD_STOP_TRANSCRIPTION =
'daily-method-stop-transcription';
export const DAILY_METHOD_PREAUTH = 'daily-method-preauth';

@@ -221,1 +236,17 @@ export const DAILY_METHOD_REQUEST_ACCESS = 'daily-method-request-access';

};
export const DAILY_JS_REMOTE_MEDIA_PLAYER_SETTING = {
PLAY: 'play',
PAUSE: 'pause',
};
export const DAILY_JS_REMOTE_MEDIA_PLAYER_STATE = {
PLAYING: 'playing',
PAUSED: 'paused',
BUFFERING: 'buffering',
STOPPED: 'stopped',
};
export const PARTICIPANT_TYPE = {
REMOTE_MEDIA_PLAYER: 'remote-media-player',
};

@@ -50,2 +50,9 @@ // This method should be used instead of window.navigator.userAgent, which

export function isFullscreenSupported() {
if (isReactNative()) return false;
if (!document) return false;
const iframe = document.createElement('iframe');
return !!iframe.requestFullscreen || !!iframe.webkitRequestFullscreen;
}
const supportedBrowsersForVideoProcessors = ['Chrome', 'Firefox'];

@@ -52,0 +59,0 @@

@@ -10,3 +10,3 @@ // todo: add debug target

mode: mode,
devtool: mode === 'development' ? 'inline-source-map' : false,
devtool: mode === 'development' ? 'eval-source-map' : false,
entry: './src/main.js',

@@ -46,4 +46,7 @@ output: {

},
devServer: {
port: process.env.PORT || 8081,
},
};
module.exports = [bundle];

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc