From f69db0923c8083b410590b242610d7e8bfe7e055 Mon Sep 17 00:00:00 2001 From: Boris Yakubchik Date: Tue, 27 Jul 2021 09:27:53 -0400 Subject: [PATCH] jxl works! --- main.ts | 2 ++ src/app/components/views/file-path.service.ts | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/main.ts b/main.ts index 64feb4c83..4d807d61f 100644 --- a/main.ts +++ b/main.ts @@ -65,6 +65,8 @@ if (args[0]) { const gotTheLock = app.requestSingleInstanceLock(); // Open file on windows from file double click +app.commandLine.appendSwitch('enable-features', 'JXL'); + if (!gotTheLock) { app.quit(); } else { diff --git a/src/app/components/views/file-path.service.ts b/src/app/components/views/file-path.service.ts index 8130dd9a2..6f8a24b9e 100644 --- a/src/app/components/views/file-path.service.ts +++ b/src/app/components/views/file-path.service.ts @@ -34,9 +34,9 @@ export class FilePathService { folderPath, 'vha-' + hubName, subfolder, - hash + (video ? '.mp4' : '.jpg') + hash + (video ? '.mp4' : '.jxl') )).replace(/\\/g, '/') - .replace(/[ \(\)]/g, (match) => { return this.replaceMap[match] }) + .replace(/[ \(\)]/g, (match) => { return this.replaceMap[match]; }); // ^^^^^ replace the ` ` (space) as well as parentheses `(` and `)` with URL encoding from the `replaceMap` }