Skip to content

Releases: daily-co/daily-js

0.24.0

30 Mar 18:38
Compare
Choose a tag to compare

Features

  • ✨ Beta ✨ New enable_pip_ui room and domain configuration property to enable Daily Prebuilt's Picture in Picture controls. When PiP is enabled, the video tile will show the active speaker or a grid view, depending on your current Daily Prebuilt settings.
curl -H "Content-Type: application/json" \
     -H "Authorization: Bearer $DAILY_API_KEY" \
     -XPOST -d \
     '{"properties":{"enable_pip_ui":true}}' \
     https://api.daily.co/v1/
  • 🪞 Our enable_prejoin_ui property is now available as a meeting token configuration, in addition to its existing room and domain configuration properties. This new token property will override the room and domain values for the same property.

  • 🌊 Live streaming improvement: Automatically retry RTMP connections if there is an error unless the URLs have all failed.

  • 📦 Advanced: Override default video constraints that Daily uses when it calls getUserMedia() by providing a new DailyIframe property: userMediaVideoConstraints

const callObject = DailyIframe.createCallObject({
  url,
  dailyConfig: {
    userMediaVideoConstraints: { frameRate: 10 },
  },
});

userMediaVideoConstraints can be a MediaTrackConstraints object or true when used with react-native-daily-js.

  • ▶️ persistentTrack is now officially in Daily's TypeScript definitions! 🎉 Using this track in your app can help avoid browser bugs related to auto-playing media tracks.

  • 🔀 startCamera() can now be used without a url parameter, in case you want to change the Daily room in between calling startCamera() and pre-authenticating or joining the room.

Bugfixes

  • 🐛 Flip the assumption that a user is on Plan B, because it’s no longer a good assumption. At this point >99% of users are on unified plan browsers, so if there is a race condition for the browser information not being available, we should assume the browser can support unified and not vice-versa.
  • 🐞 Fix virtual background key typo from throwing an error and causing a freeze by scrubbing invalid processor keys.

0.23.0

15 Feb 22:28
Compare
Choose a tag to compare

Features

  • Beta: Replacing your video background with an image is now supported, using the updateInputSettings() method. You can specify any custom image, or select from one of 10 pre-canned images provided by Daily, or just rely on Daily’s default background image:
callObject.updateInputSettings({
  video: {
    processor: {
      type: 'background-image',
      config?: {
        source?: 'default' | <public url to jpg, jpeg, or png> |	<int: 1-10>		
      }
    }
  }
});
  • Pre-beta: startRemoteMediaPlayer() now allows you to specify simulcast encoding settings:
callObject.startRemoteMediaPlayer({
  url: 'http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4',
  settings: { 
    state: 'play', 
    simulcastEncodings: [
      { maxBitrate: 80000, maxFramerate: 10, scaleResolutionDownBy: 4 },
      { maxBitrate: 200000, maxFramerate: 15, scaleResolutionDownBy: 2 },
      { maxBitrate: 600000, maxFramerate: 30}]
    }
});
  • Pre-beta: You can now get a new errorType'remote-media-player-error'—in the 'nonfatal-error' event, when an error occurs in a remote media player (started with startRemoteMediaPlayer()).

Bugfixes

  • If you’ve specified a false input device either up-front (i.e. join({ url, audioSource: false })) or in the middle of a call (i.e. setInputDevicesAsync({ audioSource: false })), then the corresponding track state will now be reported as 'off' as if it were a normal user mute (i.e. setLocalAudio(false)):
callObject.participants().local.tracks.audio.state; // 'off'
callObject.participants().local.tracks.audio.off.byUser; // true

// ...and from another participant's point of view...
callObject.participants()['some-id'].tracks.audio.state; // 'off'
callObject.participants()['some-id'].tracks.audio.off.byUser; // true

Prior to this change, participants would see tracks with no backing input source reported as either permanently 'interrupted' (if it was their own track) or permanently 'loading' (if it was a remote track).

Other improvements

  • Pre-beta: room() info now returns whether your domain has the enable_advanced_chat feature flag set (which controls a Prebuilt-only pre-beta feature).

0.22.0

18 Jan 17:18
Compare
Choose a tag to compare

Features

  • Prebuilt Only: Introduced a new enable_people_ui room and domain property which allows for enabling/disabling prebuilt’s people panel.
  • Prebuilt Only (experimental): Introduced a new experimental_optimize_large_calls room property which enables various optimizations for supporting large calls such as
    • auto muting people when the join
    • subscribing only to the most recent 8 speakers' audio tracks
    • disables active speaker view
    • limiting the grid view to a maximum 12 video tiles
    • set the maximum number of subscriptions to 30
  • Added a new nonfatal-error event type for reporting screenshare issues. Now if there is an error when a user tries to start screen sharing, you can catch this with the following:
call.on('nonfatal-error', (evt) => {
  if (evt.type === 'screen-share-error') {
		console.log(evt.errorMsg);
	}
});
  • Experimental!!!: Introduced new API for adding, controlling, and subscribing to external media sources (i.e. remote media player) to a daily call as one of the participants in a meeting. This API is in progress. If you are interested in using it, please contact help@daily.co.

Bugfixes

  • Fixed unhandled error for invalid URLs during bundle load

Other improvements

  • Updated type for app-message event payload to accept generic data type
  • Added ability to serve up daily-js using webpack-dev-server

0.21.0

28 Oct 17:21
Compare
Choose a tag to compare

Features

  • Introduced a new event, live-streaming-started that corresponds to when a live streaming has started for the call. The event payload optionally includes the streaming layout:

    {
      "action": "live-streaming-started",
      "layout": {} // see layout object in [startLiveStreaming](https://docs.daily.co/reference/daily-js/instance-methods/start-live-streaming)
    }
  • Beta (cloud recording): Added support for recording-started and recording-stopped for cloud-beta recording. All recording-started events will now include the type of recording started (ie. "local", "cloud", "rtp-tracks", "output-byte-stream", or "cloud-beta"). When the type is cloud-beta or rtp-tracks, the recording-started event will also include startedBy with the participant id of the person who started the recording. cloud-beta recordings will also include the same layout property as live streaming events.

    {
      "action": "recording-started",
      "callFrameId": "16149871051110.5607513282111183",
      "layout": { "preset": "default" }, // only for rtp-tracks recordings
      "local": true, // only present for local and cloud recordings if you started the recording
      "recordingId": "cab2be92-1551-42d8-bcdf-11fe7bd81923", // only for cloud recordings
      "startedBy": "1c6d5474-b133-4993-c943-f1ffdbb38cad", // the participant that started a cloud-beta or rtp-tracks recording
      "type": "cloud-beta" // or rtp-tracks, local, cloud, or output-byte-stream
    }

Bugfixes

  • added missing userName to the DailyCallOptions type
  • Beta (background blur): added better validation for the optional config object passed in as part of processor in updateInputSettings
  • Beta (background blur): changed the strength value from being an int ranging from 0-10 to a float percentage value, ranging from 0-1.
  • Resolved an issue that would cause cloud-beta or rtp-tracks recordings to stop if startRecording() was called multiple times in the same session.

0.20.0

13 Oct 17:32
Compare
Choose a tag to compare

Features

  • Added language support for Russian. See docs on [setDailyLang()](https://docs.daily.co/reference/daily-js/instance-methods/set-daily-lang#main) and the IFrame Properties for information on setting the language. Use ru to specify Russian.
  • Beta (background blur): In Prebuilt only, added support for enabling/disabling UI for turning on background blur. To enable, you must set the (not documented) enable_video_processing_ui property to true in your domain or room properties. This is defaulted to false. Please contact help@daily.co for more details and the implications of turning this feature on.
  • Beta (background blur): Added ability to detect if a device/browser supports video processing (ie. background blur). See supportsVideoProcessing returned by supportedBrowser().

0.19.0

30 Sep 20:03
Compare
Choose a tag to compare

Features

  • For prebuilt users, Added show-local-video-changed event that fires when a local participant hides or shows their own video element (when the setShowLocalVideo() method is called)..

  • Introduced new method, getNetworkTopology() which indicates whether the call is happening over an "sfu" or "peer" connection type.

    let { topology } = await call.getNetworkTopology();
    // topology will be set to 'sfu' | 'peer' | 'none' (if not in the call)
  • Added support for new portrait layouts to live streaming with the options of a 'vertical' or 'inset' layout. See the portrait option in the docs for more information.

  • Beta Deepgram transcription support. Have a look at startTranscription() to get started.

  • Beta support for background blur / processing of the local camera. IMPORTANT: This is an early Beta. For more information on how to use this feature, please contact help@daily.co. Full documentation and support coming soon.

Bugfixes

  • Fix DailyCallOptions to allow audioSource/videoSource to be set via boolean.

Other improvements

  • Improved TypeScript definitions for recording/streaming options
  • Removed default values from startRecording and updateRecording to allow for detection of user-set vs. default values down the line in validation

0.18.0

02 Sep 13:19
Compare
Choose a tag to compare

Features

  • Introduces a new beta recording type, cloud-beta, which records a Daily call server-side.

    • Set the enable_recording property for a room or meeting token to cloud-beta to test it out. Be advised that this feature is beta and is subject to change

    • You can now pass a layout property to start startRecording that determines how participants' camera streams will be displayed in the recording. This layout object includes a preset key that specifies a default (grid), single-participant, or active-participant layout value. The default value can be set with an additional max_cam_streams key to indicate the number of participant videos displayed.

      await call.startRecording({
        width: 1280,
        height: 720,
          backgroundColor: "#FF1F2D3D",
        layout: {
          preset: "default",
          max_cam_streams: 5,
        },
      });
    • The new updateRecording method makes it possible to update the layout value mid-recording.

      await call.updateRecording({
        layout: {
          preset: "single-participant",
            session_id: "abcd123..."
        }
      });
    • Additional Notes:

      • The new layout property of startRecording and updateRecording method are only applicable for the new cloud-beta recording type.
      • Cloud recording is only available to Scale Plans and is an additional charge. See daily.co/pricing.

    For more details on these recording improvements, please contact daily

0.17.0

17 Aug 20:30
Compare
Choose a tag to compare

Features

  • Shipped activeSpeakerMode iframe property to control whether Daily Prebuilt displays the person currently speaking ({ activeSpeakerMode: true } ; this is the default) or a grid of call participants ({ activeSpeakerMode: false } ).

    Set Daily Prebuilt to grid mode

    DailyIFrame.createFrame({ activeSpeakerMode: false });
    
  • New iframe property layoutConfig customizes how the grid of video tiles behaves when the browser is resized (if the call is in grid mode, of course)

    Example layoutConfig usage

    DailyIframe.createFrame({
      layoutConfig: {
        grid: {
          minTilesPerPage: 3, // default: 1, minimum required: 1
          maxTilesPerPage: 36 // default: 25, maximum allowable: 49
        }
      }
    });
    
  • Added 'staged' media track subscription state that corresponds to setting up the connections for a track, but not transmitting data across that connection. This lets you "stage" tracks that you know you'll need soon, for later rapid transition into the fully "subscribed" state, without using any extra bandwidth. Reminder: Track subscriptions are only supported when your call is in SFU mode.

    Example 'staged' usage

    call.updateParticipant(id, {
      setSubscribedTracks: {
        video: 'staged',
      },
    });
    
  • Launched several affordances to give you control over how you want to receive the video tracks that you're subscribed to. These are referred to as receive settings. The first—and so far only—configurable receive settings are the desired maximum simulcast layers for video and screenVideo. A higher simulcast layer corresponds to higher quality. The new affordances are:

    Note: Simulcast layer settings only apply when a call is in SFU mode.

    Example usage: update receive settings for a participant on the fly

    call.updateReceiveSettings({
      'some-participant-id': { video: { layer: 0 } }
    });
    

0.16.0

28 Jul 21:56
Compare
Choose a tag to compare

Features

  • You can now customize colors when using Daily Prebuilt. Pass your own hex codes as a theme property to join() or createFrame(), or use the new setTheme() method. You can inspect your custom theme using the theme() method and get notified when you’ve changed it via the ‘theme-updated’ event.

Other improvements

  • preAuth() now rejects its Promise with a meaningful error when there's a room-related error (e.g. when in invalid or expired room is specified), with its contents matching the corresponding 'error' event's payload.

0.15.0

06 Jul 22:07
Compare
Choose a tag to compare

Bugfixes

  • Fixed a bug where the 'active-speaker-change' event wouldn't fire immediately upon join() if it wasn't the first time join() was invoked on the call object (i.e. if you were reusing the same call object for multiple calls).