Skip to content

Commit

Permalink
Merge pull request #2701 from peterdanwan/issue-2700
Browse files Browse the repository at this point in the history
feat: hide cinema mode button on YT when the setting is disabled
  • Loading branch information
ImprovedTube authored Dec 4, 2024
2 parents 9db12bb + 2ec23ce commit 78c5767
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions js&css/web-accessible/core.js
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,14 @@ document.addEventListener('it-message-from-extension', function () {
}
break

case 'playerCinemaModeButton' :
if (ImprovedTube.storage.player_cinema_mode_button === false) {
if (ImprovedTube.elements.buttons['it-cinema-mode-button']) {
ImprovedTube.elements.buttons['it-cinema-mode-button']?.remove();
ImprovedTube.elements.buttons['it-cinema-mode-styles']?.remove();
}
}

case 'playerRepeatButton':
if (ImprovedTube.storage.player_repeat_button === false) {
if (ImprovedTube.elements.buttons['it-repeat-button']) {
Expand Down

0 comments on commit 78c5767

Please sign in to comment.