From 3d3a94c991801a6f91695f993ab54151fc70e6d1 Mon Sep 17 00:00:00 2001 From: AnimeDL Date: Sat, 13 Apr 2024 17:21:57 -0700 Subject: [PATCH] vtt2ass: Add support for text-decoration Adds support for underline text-decoration subtitles, fixes #658 --- modules/module.vtt2ass.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/modules/module.vtt2ass.ts b/modules/module.vtt2ass.ts index b85668d..dee43ce 100644 --- a/modules/module.vtt2ass.ts +++ b/modules/module.vtt2ass.ts @@ -126,6 +126,13 @@ function parseStyle(stylegroup: string, line: string, style: any) { break; } break; + case 'text-decoration': + if (st[1] === 'underline') { + style[8] = -1; + } else { + console.warn(`vtt2ass: Unknown text-decoration value: ${st[1]}`); + } + break; case 'font-style': if (st[1] === 'italic') { style[7] = -1;