unified-video-framework 1.4.453 → 1.4.455

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.
@@ -616,6 +616,9 @@ export class WebPlayer extends BasePlayer {
616
616
  // Apply controls-disabled class if controls={false}
617
617
  if (!this.useCustomControls) {
618
618
  wrapper.classList.add('controls-disabled');
619
+ } else {
620
+ // Make controls visible by default when controls={true}
621
+ wrapper.classList.add('controls-visible');
619
622
  }
620
623
 
621
624
  // Assemble the player
@@ -1773,13 +1776,16 @@ export class WebPlayer extends BasePlayer {
1773
1776
  `;
1774
1777
  }
1775
1778
 
1776
- // Always add mousemove listener for hover detection
1779
+ // Add mouse event listeners for control visibility
1777
1780
  overlay.addEventListener('mouseenter', () => {
1778
1781
  this.playerWrapper?.classList.add('controls-visible');
1779
1782
  });
1780
1783
 
1781
1784
  overlay.addEventListener('mouseleave', () => {
1782
- this.playerWrapper?.classList.remove('controls-visible');
1785
+ // Only hide controls if video is playing, otherwise keep them visible
1786
+ if (this.state.isPlaying) {
1787
+ this.scheduleHideControls();
1788
+ }
1783
1789
  });
1784
1790
 
1785
1791
  container.appendChild(overlay);
@@ -1787,10 +1793,14 @@ export class WebPlayer extends BasePlayer {
1787
1793
  // Also add listeners to the container for fallback hover detection
1788
1794
  container.addEventListener('mouseenter', () => {
1789
1795
  this.playerWrapper?.classList.add('controls-visible');
1796
+ if (this.hideControlsTimeout) clearTimeout(this.hideControlsTimeout);
1790
1797
  });
1791
1798
 
1792
1799
  container.addEventListener('mouseleave', () => {
1793
- this.playerWrapper?.classList.remove('controls-visible');
1800
+ // Only hide controls if video is playing, otherwise keep them visible
1801
+ if (this.state.isPlaying) {
1802
+ this.scheduleHideControls();
1803
+ }
1794
1804
  });
1795
1805
  }
1796
1806
 
@@ -1887,6 +1897,7 @@ export class WebPlayer extends BasePlayer {
1887
1897
  this.debugLog('[YouTube] Custom controls only mode - showing custom controls, hiding YouTube native controls');
1888
1898
  this.playerWrapper.classList.remove('youtube-native-controls-mode');
1889
1899
  this.playerWrapper.classList.add('youtube-custom-controls-mode');
1900
+ this.playerWrapper.classList.add('controls-visible');
1890
1901
  this.showCustomControls();
1891
1902
  } else if (!this.youtubeNativeControls && !this.useCustomControls && this.playerWrapper) {
1892
1903
  // No controls mode - both YouTube native and custom controls are hidden
@@ -5658,8 +5669,8 @@ export class WebPlayer extends BasePlayer {
5658
5669
 
5659
5670
  .uvf-player-wrapper:hover .uvf-controls-bar,
5660
5671
  .uvf-player-wrapper.controls-visible .uvf-controls-bar {
5661
- opacity: 1;
5662
- transform: translateY(0);
5672
+ opacity: 1 !important;
5673
+ transform: translateY(0) !important;
5663
5674
  }
5664
5675
 
5665
5676
  .uvf-player-wrapper.no-cursor {
@@ -7114,8 +7125,8 @@ export class WebPlayer extends BasePlayer {
7114
7125
 
7115
7126
  .uvf-player-wrapper:hover .uvf-top-bar,
7116
7127
  .uvf-player-wrapper.controls-visible .uvf-top-bar {
7117
- opacity: 1;
7118
- transform: translateY(0);
7128
+ opacity: 1 !important;
7129
+ transform: translateY(0) !important;
7119
7130
  }
7120
7131
 
7121
7132
  /* Title Bar - After navigation buttons */
@@ -8832,18 +8843,24 @@ export class WebPlayer extends BasePlayer {
8832
8843
  display: flex !important;
8833
8844
  visibility: visible !important;
8834
8845
  pointer-events: auto !important;
8846
+ opacity: 1 !important;
8847
+ transform: translateY(0) !important;
8835
8848
  }
8836
8849
 
8837
8850
  .uvf-player-wrapper.youtube-custom-controls-mode .uvf-top-bar {
8838
8851
  display: flex !important;
8839
8852
  visibility: visible !important;
8840
8853
  pointer-events: auto !important;
8854
+ opacity: 1 !important;
8855
+ transform: translateY(0) !important;
8841
8856
  }
8842
8857
 
8843
8858
  .uvf-player-wrapper.youtube-custom-controls-mode .uvf-center-play-container {
8844
8859
  display: flex !important;
8845
8860
  visibility: visible !important;
8846
8861
  pointer-events: auto !important;
8862
+ opacity: 1 !important;
8863
+ transform: scale(1) !important;
8847
8864
  }
8848
8865
 
8849
8866
  /* Override any inline styles */