Add configurable skip delay (0-30s) for Skip Intro and Skip Credits
This commit is contained in:
@@ -1,9 +1,17 @@
|
||||
const DEFAULT_SETTINGS = {
|
||||
plexUrl: "https://app.plex.tv",
|
||||
skipIntro: true,
|
||||
skipCredits: true
|
||||
skipCredits: true,
|
||||
introDelaySeconds: 0,
|
||||
creditsDelaySeconds: 0
|
||||
};
|
||||
|
||||
function clampDelaySeconds(value) {
|
||||
const num = Number(value);
|
||||
if (!Number.isFinite(num)) return 0;
|
||||
return Math.min(30, Math.max(0, Math.round(num)));
|
||||
}
|
||||
|
||||
function normalizePlexUrl(input) {
|
||||
let value = (input || "").trim();
|
||||
if (!value) return DEFAULT_SETTINGS.plexUrl;
|
||||
|
||||
Reference in New Issue
Block a user