@supr-design/flux-player 1.1.0 → 1.2.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@supr-design/flux-player",
3
- "version": "1.1.0",
3
+ "version": "1.2.0",
4
4
  "description": "Web video player with HLS, MPEG-DASH, native playback and customizable controls",
5
5
  "license": "PolyForm-Noncommercial-1.0.0",
6
6
  "type": "module",
package/styles.css CHANGED
@@ -499,3 +499,15 @@
499
499
  .flux-player-toolbar-group .flux-hidden {
500
500
  display: none;
501
501
  }
502
+
503
+ .flux-player-icon-btn > img {
504
+ width: var(--flux-player-control-iconSize, 24px);
505
+ height: var(--flux-player-control-iconSize, 24px);
506
+ object-fit: contain;
507
+ }
508
+ .flux-player-big-play > img,
509
+ .flux-player-replay > img {
510
+ width: 30px;
511
+ height: 30px;
512
+ object-fit: contain;
513
+ }
package/types.d.ts CHANGED
@@ -47,7 +47,11 @@ export interface ToolbarConfig {
47
47
  onClick: (player: Pick<PlayerInstance, 'getState' | 'seek' | 'setMuted'>) => void;
48
48
  }>;
49
49
  }
50
+ export type PlayerIconName = 'play' | 'pause' | 'replay' | 'volume' | 'mute' | 'settings' | 'pip' | 'fullscreen' | 'fullscreenExit';
51
+ /** Image URLs for built-in controls. Unspecified icons use the default artwork. */
52
+ export type PlayerIcons = Partial<Record<PlayerIconName, string>>;
50
53
  export interface UIConfig {
54
+ icons?: PlayerIcons;
51
55
  toolbar?: ToolbarConfig;
52
56
  headless?: boolean;
53
57
  target?: string | HTMLElement;
@@ -193,6 +197,7 @@ export interface PlayerInstance {
193
197
  setVolume(volume: number): void;
194
198
  setMuted(muted: boolean): void;
195
199
  setPlaybackRate(rate: number): void;
200
+ setIcons(icons: PlayerIcons): void;
196
201
  setToolbar(toolbar: ToolbarConfig): void;
197
202
  setTheme(theme: string | ThemeOverrideConfig): void;
198
203
  setQuality(level: string | number | "auto"): void;