mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2024-11-10 01:01:55 +01:00
Fix german title not being shortened
This commit is contained in:
parent
814df46521
commit
e489d0f913
1 changed files with 1 additions and 1 deletions
|
@ -160,7 +160,7 @@ module.exports = env => {
|
|||
if (path.match(/(\/|\\)_locales(\/|\\).+/)) {
|
||||
const parsed = JSON.parse(content.toString());
|
||||
if (env.browser.toLowerCase() === "safari") {
|
||||
parsed.fullName.message = parsed.fullName.message.match(/^.+(?= -)/)?.[0] || parsed.fullName.message;
|
||||
parsed.fullName.message = parsed.fullName.message.match(/^.+(?= [-–])/)?.[0] || parsed.fullName.message;
|
||||
if (parsed.fullName.message.length > 50) {
|
||||
parsed.fullName.message = parsed.fullName.message.slice(0, 47) + "...";
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue