@vindral/web-sdk 4.2.0-9-g20d8006e → 4.2.1

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/api-client.d.ts CHANGED
@@ -30,7 +30,7 @@ type Tagged<BaseType, Tag extends PropertyKey> = BaseType & {
30
30
  };
31
31
  };
32
32
  type AudioCodec = "aac" | "opus" | "mp3";
33
- type VideoCodec = "h264" | "av1";
33
+ type VideoCodec = "h264" | "h265" | "av1";
34
34
  type WebCodecsHardwareAccelerationPreference = "no-preference" | "prefer-hardware" | "prefer-software";
35
35
  interface ClientOverrides {
36
36
  maxVideoBitRate?: number;
@@ -70,8 +70,8 @@ interface TrackObject {
70
70
  displayWidth?: number;
71
71
  displayHeight?: number;
72
72
  language?: string;
73
- ["com.vindral.variant_uid"]?: string;
74
- ["com.vindral.drm"]?: string;
73
+ "com.vindral.variant_uid"?: string;
74
+ "com.vindral.drm"?: string;
75
75
  }
76
76
  interface CatalogRoot {
77
77
  version: number;
package/api-client.js CHANGED
@@ -1,2 +1,2 @@
1
- import { t as e } from "./B5bZayjf.js";
1
+ import { t as e } from "./DeYmk5AL.js";
2
2
  export { e as ApiClient };
package/cast-sender.d.ts CHANGED
@@ -53,7 +53,7 @@ declare const LogLevel: {
53
53
  TRACE: "trace";
54
54
  OFF: "off";
55
55
  };
56
- type VideoCodec = "h264" | "av1";
56
+ type VideoCodec = "h264" | "h265" | "av1";
57
57
  interface ReconnectState {
58
58
  /**
59
59
  * The number or retry attempts so far.
@@ -365,27 +365,27 @@ export interface CastSenderEvents {
365
365
  /**
366
366
  * When a connection has been established with a CastReceiver
367
367
  */
368
- ["connected"]: void;
368
+ connected: void;
369
369
  /**
370
370
  * When a previous session has been resumed
371
371
  */
372
- ["resumed"]: void;
372
+ resumed: void;
373
373
  /**
374
374
  * When a CastReceiver has lost or stopped a connection
375
375
  */
376
- ["disconnected"]: void;
376
+ disconnected: void;
377
377
  /**
378
378
  * When a connection attempt was initiated unsuccessfully
379
379
  */
380
- ["failed"]: void;
380
+ failed: void;
381
381
  /**
382
382
  * When the remote connection emits a metadata event
383
383
  */
384
- ["metadata"]: Metadata;
384
+ metadata: Metadata;
385
385
  /**
386
386
  * When the remote connection receives a server wallclock time event
387
387
  */
388
- ["server wallclock time"]: number;
388
+ "server wallclock time": number;
389
389
  }
390
390
  /**
391
391
  * Used for initializing the CastSender
package/cast-sender.js CHANGED
@@ -1,2 +1,2 @@
1
- import { t as e } from "./BdFcdkj1.js";
1
+ import { t as e } from "./D5iA4gy8.js";
2
2
  export { e as CastSender };
package/core.d.ts CHANGED
@@ -129,7 +129,7 @@ declare class UserAgentInformation {
129
129
  };
130
130
  }
131
131
  export type AudioCodec = "aac" | "opus" | "mp3";
132
- export type VideoCodec = "h264" | "av1";
132
+ export type VideoCodec = "h264" | "h265" | "av1";
133
133
  /**
134
134
  * The current reconnect state to use to decide whether to kep reconnecting or not
135
135
  */
@@ -481,8 +481,8 @@ interface TrackObject {
481
481
  displayWidth?: number;
482
482
  displayHeight?: number;
483
483
  language?: string;
484
- ["com.vindral.variant_uid"]?: string;
485
- ["com.vindral.drm"]?: string;
484
+ "com.vindral.variant_uid"?: string;
485
+ "com.vindral.drm"?: string;
486
486
  }
487
487
  interface CatalogRoot {
488
488
  version: number;
@@ -906,6 +906,7 @@ interface JitterModuleStatistics {
906
906
  interface MseModuleStatistics {
907
907
  quotaErrorCount: number;
908
908
  mediaSourceOpenTime: number;
909
+ playbackStallCount: number;
909
910
  totalVideoFrames?: number;
910
911
  droppedVideoFrames?: number;
911
912
  successfulVideoAppendCalls?: number;
@@ -1526,6 +1527,8 @@ export declare class Vindral extends Emitter<PublicVindralEvents> {
1526
1527
  private suspend;
1527
1528
  private unsuspend;
1528
1529
  private getRuntimeInfo;
1530
+ private getPlaybackBufferState;
1531
+ private onMediaElementBufferState;
1529
1532
  private onMediaElementState;
1530
1533
  private onBufferEvent;
1531
1534
  /**
@@ -1643,7 +1646,7 @@ export interface PublicVindralEvents {
1643
1646
  * In case of a fatal error it is appropriate to indicate what the error was to the user, either by displaying the error.message or
1644
1647
  * by using the error.code() as a key to look up a localization string. To resume streaming it is required to create a new Vindral instance.
1645
1648
  */
1646
- ["error"]: Readonly<VindralError>;
1649
+ error: Readonly<VindralError>;
1647
1650
  /**
1648
1651
  * When the instance needs user input to activate audio or sometimes video playback.
1649
1652
  * Is called with an object
@@ -1654,51 +1657,51 @@ export interface PublicVindralEvents {
1654
1657
  * }
1655
1658
  * ```
1656
1659
  */
1657
- ["needs user input"]: NeedsUserInputContext;
1660
+ "needs user input": NeedsUserInputContext;
1658
1661
  /**
1659
1662
  * When a timed metadata event has been triggered
1660
1663
  */
1661
- ["metadata"]: Readonly<Metadata>;
1664
+ metadata: Readonly<Metadata>;
1662
1665
  /**
1663
1666
  * When the playback state changes
1664
1667
  */
1665
- ["playback state"]: Readonly<PlaybackState>;
1668
+ "playback state": Readonly<PlaybackState>;
1666
1669
  /**
1667
1670
  * When the connection state changes
1668
1671
  */
1669
- ["connection state"]: Readonly<ConnectionState>;
1672
+ "connection state": Readonly<ConnectionState>;
1670
1673
  /**
1671
1674
  * When the available rendition levels is changed
1672
1675
  */
1673
- ["rendition levels"]: ReadonlyArray<RenditionLevel>;
1676
+ "rendition levels": ReadonlyArray<RenditionLevel>;
1674
1677
  /**
1675
1678
  * When the rendition level is changed
1676
1679
  */
1677
- ["rendition level"]: Readonly<RenditionLevel>;
1680
+ "rendition level": Readonly<RenditionLevel>;
1678
1681
  /**
1679
1682
  * When the available languages is changed
1680
1683
  */
1681
- ["languages"]: ReadonlyArray<string>;
1684
+ languages: ReadonlyArray<string>;
1682
1685
  /**
1683
1686
  * When the available text tracks are changed
1684
1687
  */
1685
- ["text tracks"]: ReadonlyArray<string>;
1688
+ "text tracks": ReadonlyArray<string>;
1686
1689
  /**
1687
1690
  * When the available channels is changed
1688
1691
  */
1689
- ["channels"]: ReadonlyArray<Channel>;
1692
+ channels: ReadonlyArray<Channel>;
1690
1693
  /**
1691
1694
  * When a context switch state change has occured.
1692
1695
  * E.g. when a channel change has been requested, or quality is changed.
1693
1696
  */
1694
- ["context switch"]: Readonly<ContextSwitchState>;
1697
+ "context switch": Readonly<ContextSwitchState>;
1695
1698
  /**
1696
1699
  * Emitted when a wallclock time message has been received from the server.
1697
1700
  *
1698
1701
  * Note: This is the edge server wallclock time and thus may differ slightly
1699
1702
  * between two viewers if they are connected to different edge servers.
1700
1703
  */
1701
- ["server wallclock time"]: Readonly<number>;
1704
+ "server wallclock time": Readonly<number>;
1702
1705
  /**
1703
1706
  * Is emitted during connection whether the channel is live or not.
1704
1707
  *
@@ -1708,41 +1711,41 @@ export interface PublicVindralEvents {
1708
1711
  * Note: If the web-sdk is instantiated at the same time as you are starting the stream it is possible
1709
1712
  * that this emits false until the started state has propagated through the system.
1710
1713
  */
1711
- ["is live"]: boolean;
1714
+ "is live": boolean;
1712
1715
  /**
1713
1716
  * Emitted when a channel switch has been completed and the first frame of the new channel is rendered.
1714
1717
  * A string containing the channel id of the new channel is provided as an argument.
1715
1718
  */
1716
- ["channel switch"]: Readonly<ChannelSwitchContext>;
1719
+ "channel switch": Readonly<ChannelSwitchContext>;
1717
1720
  /**
1718
1721
  * Emmitted when a channel switch fails.
1719
1722
  * A string containing the channel id of the current channel is provided as an argument.
1720
1723
  */
1721
- ["channel switch failed"]: Readonly<ChannelSwitchContext>;
1724
+ "channel switch failed": Readonly<ChannelSwitchContext>;
1722
1725
  /**
1723
1726
  * Emitted when a language switch has been completed and the new language starts playing.
1724
1727
  */
1725
- ["language switch"]: Readonly<LanguageSwitchContext>;
1728
+ "language switch": Readonly<LanguageSwitchContext>;
1726
1729
  /**
1727
1730
  * Emitted when the volume state changes.
1728
1731
  *
1729
1732
  * This is triggered triggered both when the user changes the volume through the Vindral instance, but also
1730
1733
  * from external sources such as OS media shortcuts or other native UI outside of the browser.
1731
1734
  */
1732
- ["volume state"]: Readonly<VolumeState>;
1735
+ "volume state": Readonly<VolumeState>;
1733
1736
  /**
1734
1737
  * Emitted when the timeshift URLs are updated.
1735
1738
  */
1736
- ["timeshift info"]: Readonly<TimeShiftInfo>;
1739
+ "timeshift info": Readonly<TimeShiftInfo>;
1737
1740
  /**
1738
1741
  * Emitted for each CMAF fragment received via the MoQ/VoQ path.
1739
1742
  * Contains raw fMP4 bytes suitable for recording.
1740
1743
  *
1741
1744
  * @internal Not part of the public API — may change without notice.
1742
1745
  */
1743
- ["cmaf fragment"]: Readonly<CmafFragmentEvent>;
1744
- ["buffer state event"]: Readonly<BufferStateEvent>;
1745
- ["initialized media"]: void;
1746
+ "cmaf fragment": Readonly<CmafFragmentEvent>;
1747
+ "buffer state event": Readonly<BufferStateEvent>;
1748
+ "initialized media": void;
1746
1749
  }
1747
1750
 
1748
1751
  export {};
package/core.js CHANGED
@@ -1,3 +1,3 @@
1
- import { t as e } from "./qbVRZqFN.js";
1
+ import { t as e } from "./TRlsfsv0.js";
2
2
  import { a as t, c as n, i as r, l as i, n as a, o, r as s, s as c, u as l } from "./C01DcfYu.js";
3
3
  export { a as AUTHENTICATION_EXPIRED_CODE, s as AUTHENTICATION_FAILED_CODE, r as CHANNEL_NOT_FOUND_CODE, t as CONNECTION_FAILED_AFTER_RETRIES_CODE, o as CONNECTION_FAILED_CODE, c as DISCONNECTED_BY_EDGE, n as INACTIVITY_CODE, i as NO_INCOMING_DATA, e as Vindral, l as VindralError };
package/legacy.d.ts CHANGED
@@ -132,7 +132,7 @@ declare class UserAgentInformation {
132
132
  };
133
133
  }
134
134
  export type AudioCodec = "aac" | "opus" | "mp3";
135
- export type VideoCodec = "h264" | "av1";
135
+ export type VideoCodec = "h264" | "h265" | "av1";
136
136
  /**
137
137
  * The current reconnect state to use to decide whether to kep reconnecting or not
138
138
  */
@@ -484,8 +484,8 @@ interface TrackObject {
484
484
  displayWidth?: number;
485
485
  displayHeight?: number;
486
486
  language?: string;
487
- ["com.vindral.variant_uid"]?: string;
488
- ["com.vindral.drm"]?: string;
487
+ "com.vindral.variant_uid"?: string;
488
+ "com.vindral.drm"?: string;
489
489
  }
490
490
  interface CatalogRoot {
491
491
  version: number;
@@ -921,6 +921,7 @@ interface JitterModuleStatistics {
921
921
  interface MseModuleStatistics {
922
922
  quotaErrorCount: number;
923
923
  mediaSourceOpenTime: number;
924
+ playbackStallCount: number;
924
925
  totalVideoFrames?: number;
925
926
  droppedVideoFrames?: number;
926
927
  successfulVideoAppendCalls?: number;
@@ -1541,6 +1542,8 @@ export declare class Vindral extends Emitter<PublicVindralEvents> {
1541
1542
  private suspend;
1542
1543
  private unsuspend;
1543
1544
  private getRuntimeInfo;
1545
+ private getPlaybackBufferState;
1546
+ private onMediaElementBufferState;
1544
1547
  private onMediaElementState;
1545
1548
  private onBufferEvent;
1546
1549
  /**
@@ -1658,7 +1661,7 @@ export interface PublicVindralEvents {
1658
1661
  * In case of a fatal error it is appropriate to indicate what the error was to the user, either by displaying the error.message or
1659
1662
  * by using the error.code() as a key to look up a localization string. To resume streaming it is required to create a new Vindral instance.
1660
1663
  */
1661
- ["error"]: Readonly<VindralError>;
1664
+ error: Readonly<VindralError>;
1662
1665
  /**
1663
1666
  * When the instance needs user input to activate audio or sometimes video playback.
1664
1667
  * Is called with an object
@@ -1669,51 +1672,51 @@ export interface PublicVindralEvents {
1669
1672
  * }
1670
1673
  * ```
1671
1674
  */
1672
- ["needs user input"]: NeedsUserInputContext;
1675
+ "needs user input": NeedsUserInputContext;
1673
1676
  /**
1674
1677
  * When a timed metadata event has been triggered
1675
1678
  */
1676
- ["metadata"]: Readonly<Metadata>;
1679
+ metadata: Readonly<Metadata>;
1677
1680
  /**
1678
1681
  * When the playback state changes
1679
1682
  */
1680
- ["playback state"]: Readonly<PlaybackState>;
1683
+ "playback state": Readonly<PlaybackState>;
1681
1684
  /**
1682
1685
  * When the connection state changes
1683
1686
  */
1684
- ["connection state"]: Readonly<ConnectionState>;
1687
+ "connection state": Readonly<ConnectionState>;
1685
1688
  /**
1686
1689
  * When the available rendition levels is changed
1687
1690
  */
1688
- ["rendition levels"]: ReadonlyArray<RenditionLevel>;
1691
+ "rendition levels": ReadonlyArray<RenditionLevel>;
1689
1692
  /**
1690
1693
  * When the rendition level is changed
1691
1694
  */
1692
- ["rendition level"]: Readonly<RenditionLevel>;
1695
+ "rendition level": Readonly<RenditionLevel>;
1693
1696
  /**
1694
1697
  * When the available languages is changed
1695
1698
  */
1696
- ["languages"]: ReadonlyArray<string>;
1699
+ languages: ReadonlyArray<string>;
1697
1700
  /**
1698
1701
  * When the available text tracks are changed
1699
1702
  */
1700
- ["text tracks"]: ReadonlyArray<string>;
1703
+ "text tracks": ReadonlyArray<string>;
1701
1704
  /**
1702
1705
  * When the available channels is changed
1703
1706
  */
1704
- ["channels"]: ReadonlyArray<Channel>;
1707
+ channels: ReadonlyArray<Channel>;
1705
1708
  /**
1706
1709
  * When a context switch state change has occured.
1707
1710
  * E.g. when a channel change has been requested, or quality is changed.
1708
1711
  */
1709
- ["context switch"]: Readonly<ContextSwitchState>;
1712
+ "context switch": Readonly<ContextSwitchState>;
1710
1713
  /**
1711
1714
  * Emitted when a wallclock time message has been received from the server.
1712
1715
  *
1713
1716
  * Note: This is the edge server wallclock time and thus may differ slightly
1714
1717
  * between two viewers if they are connected to different edge servers.
1715
1718
  */
1716
- ["server wallclock time"]: Readonly<number>;
1719
+ "server wallclock time": Readonly<number>;
1717
1720
  /**
1718
1721
  * Is emitted during connection whether the channel is live or not.
1719
1722
  *
@@ -1723,41 +1726,41 @@ export interface PublicVindralEvents {
1723
1726
  * Note: If the web-sdk is instantiated at the same time as you are starting the stream it is possible
1724
1727
  * that this emits false until the started state has propagated through the system.
1725
1728
  */
1726
- ["is live"]: boolean;
1729
+ "is live": boolean;
1727
1730
  /**
1728
1731
  * Emitted when a channel switch has been completed and the first frame of the new channel is rendered.
1729
1732
  * A string containing the channel id of the new channel is provided as an argument.
1730
1733
  */
1731
- ["channel switch"]: Readonly<ChannelSwitchContext>;
1734
+ "channel switch": Readonly<ChannelSwitchContext>;
1732
1735
  /**
1733
1736
  * Emmitted when a channel switch fails.
1734
1737
  * A string containing the channel id of the current channel is provided as an argument.
1735
1738
  */
1736
- ["channel switch failed"]: Readonly<ChannelSwitchContext>;
1739
+ "channel switch failed": Readonly<ChannelSwitchContext>;
1737
1740
  /**
1738
1741
  * Emitted when a language switch has been completed and the new language starts playing.
1739
1742
  */
1740
- ["language switch"]: Readonly<LanguageSwitchContext>;
1743
+ "language switch": Readonly<LanguageSwitchContext>;
1741
1744
  /**
1742
1745
  * Emitted when the volume state changes.
1743
1746
  *
1744
1747
  * This is triggered triggered both when the user changes the volume through the Vindral instance, but also
1745
1748
  * from external sources such as OS media shortcuts or other native UI outside of the browser.
1746
1749
  */
1747
- ["volume state"]: Readonly<VolumeState>;
1750
+ "volume state": Readonly<VolumeState>;
1748
1751
  /**
1749
1752
  * Emitted when the timeshift URLs are updated.
1750
1753
  */
1751
- ["timeshift info"]: Readonly<TimeShiftInfo>;
1754
+ "timeshift info": Readonly<TimeShiftInfo>;
1752
1755
  /**
1753
1756
  * Emitted for each CMAF fragment received via the MoQ/VoQ path.
1754
1757
  * Contains raw fMP4 bytes suitable for recording.
1755
1758
  *
1756
1759
  * @internal Not part of the public API — may change without notice.
1757
1760
  */
1758
- ["cmaf fragment"]: Readonly<CmafFragmentEvent>;
1759
- ["buffer state event"]: Readonly<BufferStateEvent>;
1760
- ["initialized media"]: void;
1761
+ "cmaf fragment": Readonly<CmafFragmentEvent>;
1762
+ "buffer state event": Readonly<BufferStateEvent>;
1763
+ "initialized media": void;
1761
1764
  }
1762
1765
  /**
1763
1766
  * Available events to listen to
@@ -1766,27 +1769,27 @@ export interface CastSenderEvents {
1766
1769
  /**
1767
1770
  * When a connection has been established with a CastReceiver
1768
1771
  */
1769
- ["connected"]: void;
1772
+ connected: void;
1770
1773
  /**
1771
1774
  * When a previous session has been resumed
1772
1775
  */
1773
- ["resumed"]: void;
1776
+ resumed: void;
1774
1777
  /**
1775
1778
  * When a CastReceiver has lost or stopped a connection
1776
1779
  */
1777
- ["disconnected"]: void;
1780
+ disconnected: void;
1778
1781
  /**
1779
1782
  * When a connection attempt was initiated unsuccessfully
1780
1783
  */
1781
- ["failed"]: void;
1784
+ failed: void;
1782
1785
  /**
1783
1786
  * When the remote connection emits a metadata event
1784
1787
  */
1785
- ["metadata"]: Metadata;
1788
+ metadata: Metadata;
1786
1789
  /**
1787
1790
  * When the remote connection receives a server wallclock time event
1788
1791
  */
1789
- ["server wallclock time"]: number;
1792
+ "server wallclock time": number;
1790
1793
  }
1791
1794
  /**
1792
1795
  * Used for initializing the CastSender
@@ -1882,15 +1885,15 @@ interface AirPlaySenderEvents {
1882
1885
  /**
1883
1886
  * When airplay targets are available.
1884
1887
  */
1885
- ["available"]: void;
1888
+ available: void;
1886
1889
  /**
1887
1890
  * When a connection has been established with an airplay target.
1888
1891
  */
1889
- ["connected"]: void;
1892
+ connected: void;
1890
1893
  /**
1891
1894
  * When the airplay target has lost or stopped a connection.
1892
1895
  */
1893
- ["disconnected"]: void;
1896
+ disconnected: void;
1894
1897
  }
1895
1898
  interface AirPlayConfig {
1896
1899
  /**