mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2025-12-24 00:18:27 +03:00
Merge branch 'master' of github.com:ajayyy/SponsorBlock
This commit is contained in:
@@ -178,7 +178,7 @@ class SubmissionNoticeComponent extends React.Component<SubmissionNoticeProps, S
|
||||
// Check if any non music categories are being used on a music video
|
||||
if (this.contentContainer().videoInfo?.microformat?.playerMicroformatRenderer?.category === "Music") {
|
||||
for (const sponsorTime of sponsorTimesSubmitting) {
|
||||
if (!sponsorTime.category.startsWith("music_")) {
|
||||
if (sponsorTime.category === "sponsor") {
|
||||
if (!confirm(chrome.i18n.getMessage("nonMusicCategoryOnMusic"))) return;
|
||||
|
||||
break;
|
||||
|
||||
@@ -1243,7 +1243,7 @@ function openInfoMenu() {
|
||||
|
||||
//close button
|
||||
let closeButton = document.createElement("div");
|
||||
closeButton.innerText = "Close Popup";
|
||||
closeButton.innerText = chrome.i18n.getMessage("closePopup");
|
||||
closeButton.classList.add("smallLink");
|
||||
closeButton.setAttribute("align", "center");
|
||||
closeButton.addEventListener("click", closeInfoMenu);
|
||||
|
||||
10
src/popup.ts
10
src/popup.ts
@@ -418,8 +418,8 @@ async function runThePopup(messageListener?: MessageListener) {
|
||||
extraInfo = " (" + chrome.i18n.getMessage("hiddenDueToDuration") + ")";
|
||||
}
|
||||
|
||||
sponsorTimeButton.innerText = getFormattedTime(request.sponsorTimes[i].segment[0]) + " to " + getFormattedTime(request.sponsorTimes[i].segment[1]) + extraInfo;
|
||||
|
||||
sponsorTimeButton.innerText = getFormattedTime(request.sponsorTimes[i].segment[0]) + " " + chrome.i18n.getMessage("to") + " " + getFormattedTime(request.sponsorTimes[i].segment[1]) + extraInfo;
|
||||
|
||||
let votingButtons = document.createElement("div");
|
||||
|
||||
let UUID = request.sponsorTimes[i].UUID;
|
||||
@@ -474,7 +474,7 @@ async function runThePopup(messageListener?: MessageListener) {
|
||||
let timeMessage = getFormattedTime(sponsorTimes[i].segment[s]);
|
||||
//if this is an end time
|
||||
if (s == 1) {
|
||||
timeMessage = " to " + timeMessage;
|
||||
timeMessage = " " + chrome.i18n.getMessage("to") + " " + timeMessage;
|
||||
} else if (i > 0) {
|
||||
//add commas if necessary
|
||||
timeMessage = ", " + timeMessage;
|
||||
@@ -531,7 +531,7 @@ async function runThePopup(messageListener?: MessageListener) {
|
||||
let timeMessage = getFormattedTime(sponsorTimes[i][s]);
|
||||
//if this is an end time
|
||||
if (s == 1) {
|
||||
timeMessage = " to " + timeMessage;
|
||||
timeMessage = " " + chrome.i18n.getMessage("to") + " " + timeMessage;
|
||||
} else if (i > 0) {
|
||||
//add commas if necessary
|
||||
timeMessage = timeMessage;
|
||||
@@ -640,7 +640,7 @@ async function runThePopup(messageListener?: MessageListener) {
|
||||
colonText.innerText = ":";
|
||||
|
||||
let toText = document.createElement("span");
|
||||
toText.innerText = " to ";
|
||||
toText.innerText = " " + chrome.i18n.getMessage("to") + " ";
|
||||
|
||||
//remove all children to replace
|
||||
while (sponsorTimeContainer.firstChild) {
|
||||
|
||||
Reference in New Issue
Block a user