diff --git a/public/_locales/en/messages.json b/public/_locales/en/messages.json index b1be0523..d375828c 100644 --- a/public/_locales/en/messages.json +++ b/public/_locales/en/messages.json @@ -438,7 +438,7 @@ "message": "The following submission is shorter than your minimum duration option. This could mean that this is already submitted, and just being ignored due to this option. Are you sure you would like to submit?" }, "liveOrPremiere": { - "message": "Submitting on an active livesteam or premiere is not allowed. Please wait until it finishes, then refresh the page and verify that the segments are still valid." + "message": "Submitting on an active livestream or premiere is not allowed. Please wait until it finishes, then refresh the page and verify that the segments are still valid." }, "showUploadButton": { "message": "Show Upload Button" diff --git a/public/content.css b/public/content.css index 35b82766..6f121e84 100644 --- a/public/content.css +++ b/public/content.css @@ -628,6 +628,7 @@ input::-webkit-inner-spin-button { font-size: 75%; height: 100%; align-items: center; + inline-size: max-content; } .sponsorBlockCategoryPillTitleSection { diff --git a/public/options/options.html b/public/options/options.html index 80dd6b81..37e606c7 100644 --- a/public/options/options.html +++ b/public/options/options.html @@ -2,7 +2,7 @@ - Options - SponsorBlock + __MSG_Options__ - SponsorBlock diff --git a/src/content.ts b/src/content.ts index 40291c16..8ee4bea3 100644 --- a/src/content.ts +++ b/src/content.ts @@ -725,9 +725,16 @@ async function sponsorsLookup(id: string, keepOldSubmissions = true) { // Hide all submissions smaller than the minimum duration if (Config.config.minDuration !== 0) { for (const segment of sponsorTimes) { - if (segment.segment[1] - segment.segment[0] < Config.config.minDuration - && segment.actionType !== ActionType.Poi) + const duration = segment[1] - segment[0]; + if (duration > 0 && duration < Config.config.minDuration) { segment.hidden = SponsorHideType.MinimumDuration; + } + } + for (let i = 0; i < sponsorTimes.length; i++) { + const duration = sponsorTimes[i].segment[1] - sponsorTimes[i].segment[0] ; + if (duration > 0 && duration < Config.config.minDuration) { + sponsorTimes[i].hidden = SponsorHideType.MinimumDuration; + } } } @@ -1877,7 +1884,7 @@ function getSegmentsMessage(sponsorTimes: SponsorTime[]): string { let timeMessage = utils.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; diff --git a/src/utils.ts b/src/utils.ts index e3c612bc..5b3c71dc 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -258,6 +258,8 @@ export default class Utils { localizeHtmlPage(): void { //Localize by replacing __MSG_***__ meta tags + const localizedMessage = this.getLocalizedMessage(document.title); + if (localizedMessage) document.title = localizedMessage; const objects = document.getElementsByClassName("sponsorBlockPageBody")[0].children; for (let j = 0; j < objects.length; j++) { const obj = objects[j];