mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2026-01-29 13:50:50 +03:00
only change color if user isVip
This commit is contained in:
@@ -379,6 +379,7 @@ async function runThePopup(messageListener?: MessageListener): Promise<void> {
|
|||||||
container.removeChild(container.firstChild);
|
container.removeChild(container.firstChild);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const isVip = Config.config.isVip;
|
||||||
for (let i = 0; i < segmentTimes.length; i++) {
|
for (let i = 0; i < segmentTimes.length; i++) {
|
||||||
const UUID = segmentTimes[i].UUID;
|
const UUID = segmentTimes[i].UUID;
|
||||||
const locked = segmentTimes[i].locked;
|
const locked = segmentTimes[i].locked;
|
||||||
@@ -431,7 +432,7 @@ async function runThePopup(messageListener?: MessageListener): Promise<void> {
|
|||||||
const downvoteButton = document.createElement("img");
|
const downvoteButton = document.createElement("img");
|
||||||
downvoteButton.id = "sponsorTimesDownvoteButtonsContainer" + UUID;
|
downvoteButton.id = "sponsorTimesDownvoteButtonsContainer" + UUID;
|
||||||
downvoteButton.className = "voteButton";
|
downvoteButton.className = "voteButton";
|
||||||
downvoteButton.src = locked ? chrome.runtime.getURL("icons/thumbs_down_locked.svg") : chrome.runtime.getURL("icons/thumbs_down.svg");
|
downvoteButton.src = locked && isVip ? chrome.runtime.getURL("icons/thumbs_down_locked.svg") : chrome.runtime.getURL("icons/thumbs_down.svg");
|
||||||
downvoteButton.addEventListener("click", () => vote(0, UUID));
|
downvoteButton.addEventListener("click", () => vote(0, UUID));
|
||||||
|
|
||||||
//uuid button
|
//uuid button
|
||||||
|
|||||||
Reference in New Issue
Block a user