avbridge 2.9.0 → 2.10.0

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/dist/element.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var chunkEY6DZEDT_cjs = require('./chunk-EY6DZEDT.cjs');
3
+ var chunkNQULEIA3_cjs = require('./chunk-NQULEIA3.cjs');
4
4
  require('./chunk-S4WAZC2T.cjs');
5
5
  require('./chunk-BYGZN4Z5.cjs');
6
6
  require('./chunk-2IJ66NTD.cjs');
@@ -296,7 +296,7 @@ var AvbridgeVideoElement = class extends HTMLElementCtor {
296
296
  this._dispatch("loadstart", {});
297
297
  let player;
298
298
  try {
299
- player = await chunkEY6DZEDT_cjs.createPlayer({
299
+ player = await chunkNQULEIA3_cjs.createPlayer({
300
300
  source,
301
301
  target: this._videoEl,
302
302
  // Honor the consumer's preferred initial strategy. "auto" means
@@ -1,4 +1,4 @@
1
- import { a as MediaInput, n as StrategyName, S as StrategyClass, U as UnifiedPlayer, e as AudioTrackInfo, o as SubtitleTrackInfo, D as DiagnosticsSnapshot, s as AvbridgeVideoElementEventMap } from './player-DEcidWk6.cjs';
1
+ import { a as MediaInput, o as StrategyName, n as StrategyClass, U as UnifiedPlayer, e as AudioTrackInfo, p as SubtitleTrackInfo, D as DiagnosticsSnapshot, t as AvbridgeVideoElementEventMap } from './player-DDdNVFDv.cjs';
2
2
 
3
3
  /**
4
4
  * `<avbridge-video>` — `HTMLMediaElement`-compatible primitive backed by the
package/dist/element.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { a as MediaInput, n as StrategyName, S as StrategyClass, U as UnifiedPlayer, e as AudioTrackInfo, o as SubtitleTrackInfo, D as DiagnosticsSnapshot, s as AvbridgeVideoElementEventMap } from './player-DEcidWk6.js';
1
+ import { a as MediaInput, o as StrategyName, n as StrategyClass, U as UnifiedPlayer, e as AudioTrackInfo, p as SubtitleTrackInfo, D as DiagnosticsSnapshot, t as AvbridgeVideoElementEventMap } from './player-DDdNVFDv.js';
2
2
 
3
3
  /**
4
4
  * `<avbridge-video>` — `HTMLMediaElement`-compatible primitive backed by the
package/dist/element.js CHANGED
@@ -1,4 +1,4 @@
1
- import { createPlayer } from './chunk-SN4WZE24.js';
1
+ import { createPlayer } from './chunk-3GKM5DFM.js';
2
2
  import './chunk-5KVLE6YI.js';
3
3
  import './chunk-GYIJU44C.js';
4
4
  import './chunk-CPJLFFCC.js';
package/dist/index.cjs CHANGED
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
3
  var chunkOTFS7DC4_cjs = require('./chunk-OTFS7DC4.cjs');
4
- var chunkEY6DZEDT_cjs = require('./chunk-EY6DZEDT.cjs');
4
+ var chunkNQULEIA3_cjs = require('./chunk-NQULEIA3.cjs');
5
5
  var chunkS4WAZC2T_cjs = require('./chunk-S4WAZC2T.cjs');
6
6
  var chunkBYGZN4Z5_cjs = require('./chunk-BYGZN4Z5.cjs');
7
7
  var chunk2IJ66NTD_cjs = require('./chunk-2IJ66NTD.cjs');
@@ -763,31 +763,31 @@ Object.defineProperty(exports, "remux", {
763
763
  });
764
764
  Object.defineProperty(exports, "FALLBACK_AUDIO_CODECS", {
765
765
  enumerable: true,
766
- get: function () { return chunkEY6DZEDT_cjs.FALLBACK_AUDIO_CODECS; }
766
+ get: function () { return chunkNQULEIA3_cjs.FALLBACK_AUDIO_CODECS; }
767
767
  });
768
768
  Object.defineProperty(exports, "FALLBACK_VIDEO_CODECS", {
769
769
  enumerable: true,
770
- get: function () { return chunkEY6DZEDT_cjs.FALLBACK_VIDEO_CODECS; }
770
+ get: function () { return chunkNQULEIA3_cjs.FALLBACK_VIDEO_CODECS; }
771
771
  });
772
772
  Object.defineProperty(exports, "NATIVE_AUDIO_CODECS", {
773
773
  enumerable: true,
774
- get: function () { return chunkEY6DZEDT_cjs.NATIVE_AUDIO_CODECS; }
774
+ get: function () { return chunkNQULEIA3_cjs.NATIVE_AUDIO_CODECS; }
775
775
  });
776
776
  Object.defineProperty(exports, "NATIVE_VIDEO_CODECS", {
777
777
  enumerable: true,
778
- get: function () { return chunkEY6DZEDT_cjs.NATIVE_VIDEO_CODECS; }
778
+ get: function () { return chunkNQULEIA3_cjs.NATIVE_VIDEO_CODECS; }
779
779
  });
780
780
  Object.defineProperty(exports, "UnifiedPlayer", {
781
781
  enumerable: true,
782
- get: function () { return chunkEY6DZEDT_cjs.UnifiedPlayer; }
782
+ get: function () { return chunkNQULEIA3_cjs.UnifiedPlayer; }
783
783
  });
784
784
  Object.defineProperty(exports, "classify", {
785
785
  enumerable: true,
786
- get: function () { return chunkEY6DZEDT_cjs.classifyContext; }
786
+ get: function () { return chunkNQULEIA3_cjs.classifyContext; }
787
787
  });
788
788
  Object.defineProperty(exports, "createPlayer", {
789
789
  enumerable: true,
790
- get: function () { return chunkEY6DZEDT_cjs.createPlayer; }
790
+ get: function () { return chunkNQULEIA3_cjs.createPlayer; }
791
791
  });
792
792
  Object.defineProperty(exports, "srtToVtt", {
793
793
  enumerable: true,
package/dist/index.d.cts CHANGED
@@ -1,5 +1,5 @@
1
- import { A as AudioCodec, V as VideoCodec, M as MediaContext, C as Classification, a as MediaInput, T as TransportConfig, b as ConvertOptions, c as ConvertResult, d as TranscodeOptions } from './player-DEcidWk6.cjs';
2
- export { e as AudioTrackInfo, f as ContainerKind, g as CreatePlayerOptions, D as DiagnosticsSnapshot, F as FetchFn, H as HardwareAccelerationHint, O as OutputAudioCodec, h as OutputFormat, i as OutputVideoCodec, P as PlaybackSession, j as PlayerEventMap, k as PlayerEventName, l as Plugin, m as ProgressInfo, S as StrategyClass, n as StrategyName, o as SubtitleTrackInfo, p as TranscodeQuality, U as UnifiedPlayer, q as VideoTrackInfo, r as createPlayer } from './player-DEcidWk6.cjs';
1
+ import { A as AudioCodec, V as VideoCodec, M as MediaContext, C as Classification, a as MediaInput, T as TransportConfig, b as ConvertOptions, c as ConvertResult, d as TranscodeOptions } from './player-DDdNVFDv.cjs';
2
+ export { e as AudioTrackInfo, f as ContainerKind, g as CreatePlayerOptions, D as DiagnosticsSnapshot, F as FetchFn, H as HardwareAccelerationHint, O as OutputAudioCodec, h as OutputFormat, i as OutputVideoCodec, P as PlaybackSession, j as PlayerEventMap, k as PlayerEventName, l as Plugin, m as ProgressInfo, S as SettingsSectionConfig, n as StrategyClass, o as StrategyName, p as SubtitleTrackInfo, q as TranscodeQuality, U as UnifiedPlayer, r as VideoTrackInfo, s as createPlayer } from './player-DDdNVFDv.cjs';
3
3
 
4
4
  /**
5
5
  * Codecs we know `<video>` and MSE support across modern desktop + Android.
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { A as AudioCodec, V as VideoCodec, M as MediaContext, C as Classification, a as MediaInput, T as TransportConfig, b as ConvertOptions, c as ConvertResult, d as TranscodeOptions } from './player-DEcidWk6.js';
2
- export { e as AudioTrackInfo, f as ContainerKind, g as CreatePlayerOptions, D as DiagnosticsSnapshot, F as FetchFn, H as HardwareAccelerationHint, O as OutputAudioCodec, h as OutputFormat, i as OutputVideoCodec, P as PlaybackSession, j as PlayerEventMap, k as PlayerEventName, l as Plugin, m as ProgressInfo, S as StrategyClass, n as StrategyName, o as SubtitleTrackInfo, p as TranscodeQuality, U as UnifiedPlayer, q as VideoTrackInfo, r as createPlayer } from './player-DEcidWk6.js';
1
+ import { A as AudioCodec, V as VideoCodec, M as MediaContext, C as Classification, a as MediaInput, T as TransportConfig, b as ConvertOptions, c as ConvertResult, d as TranscodeOptions } from './player-DDdNVFDv.js';
2
+ export { e as AudioTrackInfo, f as ContainerKind, g as CreatePlayerOptions, D as DiagnosticsSnapshot, F as FetchFn, H as HardwareAccelerationHint, O as OutputAudioCodec, h as OutputFormat, i as OutputVideoCodec, P as PlaybackSession, j as PlayerEventMap, k as PlayerEventName, l as Plugin, m as ProgressInfo, S as SettingsSectionConfig, n as StrategyClass, o as StrategyName, p as SubtitleTrackInfo, q as TranscodeQuality, U as UnifiedPlayer, r as VideoTrackInfo, s as createPlayer } from './player-DDdNVFDv.js';
3
3
 
4
4
  /**
5
5
  * Codecs we know `<video>` and MSE support across modern desktop + Android.
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { mimeForFormat, generateFilename, createOutputFormat } from './chunk-CL6UEUQF.js';
2
2
  export { remux } from './chunk-CL6UEUQF.js';
3
- export { FALLBACK_AUDIO_CODECS, FALLBACK_VIDEO_CODECS, NATIVE_AUDIO_CODECS, NATIVE_VIDEO_CODECS, UnifiedPlayer, classifyContext as classify, createPlayer } from './chunk-SN4WZE24.js';
3
+ export { FALLBACK_AUDIO_CODECS, FALLBACK_VIDEO_CODECS, NATIVE_AUDIO_CODECS, NATIVE_VIDEO_CODECS, UnifiedPlayer, classifyContext as classify, createPlayer } from './chunk-3GKM5DFM.js';
4
4
  export { srtToVtt } from './chunk-5KVLE6YI.js';
5
5
  import { probe, buildMediabunnySourceFromInput } from './chunk-GYIJU44C.js';
6
6
  export { probe } from './chunk-GYIJU44C.js';
@@ -401,6 +401,28 @@ interface ConvertResult {
401
401
  */
402
402
  notes?: string[];
403
403
  }
404
+ /**
405
+ * Configuration for a custom settings section added to `<avbridge-player>`
406
+ * via {@link addSettingsSection}. Sections render in the bottom-sheet
407
+ * settings panel alongside built-in sections (Speed, Audio, Subtitles,
408
+ * Fit, Stats for Nerds). The player owns rendering — consumers describe
409
+ * data; avbridge renders it in a consistent visual style.
410
+ */
411
+ interface SettingsSectionConfig {
412
+ /** Unique id for this section. Used to update/remove later. */
413
+ id: string;
414
+ /** Display label (e.g. "Quality", "Translate"). */
415
+ label: string;
416
+ /** Items to show when the section is expanded. */
417
+ items: Array<{
418
+ id: string;
419
+ label: string;
420
+ /** Mark the currently-selected item. */
421
+ active?: boolean;
422
+ }>;
423
+ /** Called when the user picks an item. */
424
+ onSelect(itemId: string): void;
425
+ }
404
426
 
405
427
  declare class UnifiedPlayer {
406
428
  private readonly options;
@@ -480,4 +502,4 @@ declare class UnifiedPlayer {
480
502
  }
481
503
  declare function createPlayer(options: CreatePlayerOptions): Promise<UnifiedPlayer>;
482
504
 
483
- export { type AudioCodec as A, type Classification as C, type DiagnosticsSnapshot as D, type FetchFn as F, type HardwareAccelerationHint as H, type MediaContext as M, type OutputAudioCodec as O, type PlaybackSession as P, type StrategyClass as S, type TransportConfig as T, UnifiedPlayer as U, type VideoCodec as V, type MediaInput as a, type ConvertOptions as b, type ConvertResult as c, type TranscodeOptions as d, type AudioTrackInfo as e, type ContainerKind as f, type CreatePlayerOptions as g, type OutputFormat as h, type OutputVideoCodec as i, type PlayerEventMap as j, type PlayerEventName as k, type Plugin as l, type ProgressInfo as m, type StrategyName as n, type SubtitleTrackInfo as o, type TranscodeQuality as p, type VideoTrackInfo as q, createPlayer as r, type AvbridgeVideoElementEventMap as s };
505
+ export { type AudioCodec as A, type Classification as C, type DiagnosticsSnapshot as D, type FetchFn as F, type HardwareAccelerationHint as H, type MediaContext as M, type OutputAudioCodec as O, type PlaybackSession as P, type SettingsSectionConfig as S, type TransportConfig as T, UnifiedPlayer as U, type VideoCodec as V, type MediaInput as a, type ConvertOptions as b, type ConvertResult as c, type TranscodeOptions as d, type AudioTrackInfo as e, type ContainerKind as f, type CreatePlayerOptions as g, type OutputFormat as h, type OutputVideoCodec as i, type PlayerEventMap as j, type PlayerEventName as k, type Plugin as l, type ProgressInfo as m, type StrategyClass as n, type StrategyName as o, type SubtitleTrackInfo as p, type TranscodeQuality as q, type VideoTrackInfo as r, createPlayer as s, type AvbridgeVideoElementEventMap as t };
@@ -401,6 +401,28 @@ interface ConvertResult {
401
401
  */
402
402
  notes?: string[];
403
403
  }
404
+ /**
405
+ * Configuration for a custom settings section added to `<avbridge-player>`
406
+ * via {@link addSettingsSection}. Sections render in the bottom-sheet
407
+ * settings panel alongside built-in sections (Speed, Audio, Subtitles,
408
+ * Fit, Stats for Nerds). The player owns rendering — consumers describe
409
+ * data; avbridge renders it in a consistent visual style.
410
+ */
411
+ interface SettingsSectionConfig {
412
+ /** Unique id for this section. Used to update/remove later. */
413
+ id: string;
414
+ /** Display label (e.g. "Quality", "Translate"). */
415
+ label: string;
416
+ /** Items to show when the section is expanded. */
417
+ items: Array<{
418
+ id: string;
419
+ label: string;
420
+ /** Mark the currently-selected item. */
421
+ active?: boolean;
422
+ }>;
423
+ /** Called when the user picks an item. */
424
+ onSelect(itemId: string): void;
425
+ }
404
426
 
405
427
  declare class UnifiedPlayer {
406
428
  private readonly options;
@@ -480,4 +502,4 @@ declare class UnifiedPlayer {
480
502
  }
481
503
  declare function createPlayer(options: CreatePlayerOptions): Promise<UnifiedPlayer>;
482
504
 
483
- export { type AudioCodec as A, type Classification as C, type DiagnosticsSnapshot as D, type FetchFn as F, type HardwareAccelerationHint as H, type MediaContext as M, type OutputAudioCodec as O, type PlaybackSession as P, type StrategyClass as S, type TransportConfig as T, UnifiedPlayer as U, type VideoCodec as V, type MediaInput as a, type ConvertOptions as b, type ConvertResult as c, type TranscodeOptions as d, type AudioTrackInfo as e, type ContainerKind as f, type CreatePlayerOptions as g, type OutputFormat as h, type OutputVideoCodec as i, type PlayerEventMap as j, type PlayerEventName as k, type Plugin as l, type ProgressInfo as m, type StrategyName as n, type SubtitleTrackInfo as o, type TranscodeQuality as p, type VideoTrackInfo as q, createPlayer as r, type AvbridgeVideoElementEventMap as s };
505
+ export { type AudioCodec as A, type Classification as C, type DiagnosticsSnapshot as D, type FetchFn as F, type HardwareAccelerationHint as H, type MediaContext as M, type OutputAudioCodec as O, type PlaybackSession as P, type SettingsSectionConfig as S, type TransportConfig as T, UnifiedPlayer as U, type VideoCodec as V, type MediaInput as a, type ConvertOptions as b, type ConvertResult as c, type TranscodeOptions as d, type AudioTrackInfo as e, type ContainerKind as f, type CreatePlayerOptions as g, type OutputFormat as h, type OutputVideoCodec as i, type PlayerEventMap as j, type PlayerEventName as k, type Plugin as l, type ProgressInfo as m, type StrategyClass as n, type StrategyName as o, type SubtitleTrackInfo as p, type TranscodeQuality as q, type VideoTrackInfo as r, createPlayer as s, type AvbridgeVideoElementEventMap as t };