diff --git a/modules/module.vtt2ass.ts b/modules/module.vtt2ass.ts index 54a44b1..7199a8c 100644 --- a/modules/module.vtt2ass.ts +++ b/modules/module.vtt2ass.ts @@ -299,6 +299,10 @@ function convert(css: Css, vtt: Vtt[]) { events[x.type as keyof typeof events].pop(); const previousLinePop = events[x.type as keyof typeof events].pop(); events[x.type as keyof typeof events].push(previousLinePop + '\\N'+x.text); + } else if ((currentStart - previousStart) <= 3) { + const currentLinePop = events[x.type as keyof typeof events].pop(); + const previousLinePop = events[previousLine.type as keyof typeof events].pop(); + events[x.type as keyof typeof events].push(currentLinePop as string, previousLinePop as string); } } previousLine = x;