Skip to content

Commit

Permalink
Merge pull request #59 from VampireChicken12/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
VampireChicken12 authored Oct 19, 2023
2 parents 73ef6e1 + ac04a48 commit 8473d8d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
1 change: 1 addition & 0 deletions src/features/videoHistory/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ export async function promptUserToResumeVideo() {
// Automatically hide the prompt when the countdown reaches 0
clearInterval(countdownInterval);
prompt.style.display = "none";
overlay.style.display = "none";
}
}, 1000);
if (!document.getElementById("resume-prompt-progress-bar")) {
Expand Down
10 changes: 3 additions & 7 deletions src/pages/content/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import adjustVolumeOnScrollWheel from "@/src/features/scrollWheelVolumeControl";
import { setupVideoHistory, promptUserToResumeVideo } from "@/src/features/videoHistory";
import volumeBoost from "@/src/features/volumeBoost";
import { removeRemainingTimeDisplay, setupRemainingTime } from "@/src/features/remainingTime";
import { addLoopButton } from "@/src/features/loopButton";
import { addLoopButton, removeLoopButton } from "@/src/features/loopButton";
// TODO: Add always show progressbar feature

// eslint-disable-next-line @typescript-eslint/no-unused-vars
Expand Down Expand Up @@ -194,13 +194,9 @@ window.onload = function () {
data: { loopButtonEnabled }
} = message;
if (loopButtonEnabled) {
const loopButton = document.querySelector("button.yte-loop-button") as HTMLButtonElement | null;
if (!loopButton) return;
loopButton.style.display = "block";
addLoopButton();
} else {
const loopButton = document.querySelector("button.yte-loop-button") as HTMLButtonElement | null;
if (!loopButton) return;
loopButton.style.display = "none";
removeLoopButton();
}
break;
}
Expand Down

0 comments on commit 8473d8d

Please sign in to comment.