fix: render segment overrides and skip progress
This commit is contained in:
@@ -27,6 +27,7 @@ export const resolveActiveSegments = (): void => {
|
||||
state.activeSegments = state.parsedSegments.filter(s => {
|
||||
const t = normalizeType(s.type);
|
||||
if (!t) return false;
|
||||
const isOverride = (s.source || '').toLowerCase() === 'override';
|
||||
|
||||
const len = s.end - s.start;
|
||||
// duration filter
|
||||
@@ -34,6 +35,9 @@ export const resolveActiveSegments = (): void => {
|
||||
// bounds check
|
||||
if (s.start < 0 || s.end <= s.start || s.end > bounds + 1) return false;
|
||||
|
||||
// User overrides should render even if they don't fit AniSkip's usual OP/ED heuristics.
|
||||
if (isOverride) return true;
|
||||
|
||||
// intro: starts early, before 50% of video
|
||||
if (t === 'op') {
|
||||
return s.start <= MAX_INTRO_START && s.start <= bounds * 0.5;
|
||||
|
||||
Reference in New Issue
Block a user