fix: correctly clean up deband

This commit is contained in:
ThaUnknown 2025-04-28 14:49:26 +02:00
parent 6057f8d57e
commit e3c96176d0
No known key found for this signature in database
4 changed files with 3 additions and 6 deletions

View file

@ -1,6 +1,6 @@
{
"name": "ui",
"version": "6.0.17",
"version": "6.0.18",
"license": "BUSL-1.1",
"private": true,
"packageManager": "pnpm@9.14.4",

View file

@ -227,10 +227,10 @@
function createDeband (video: HTMLVideoElement | undefined, playerDeband: boolean) {
if (!playerDeband || !video) return cleanupDeband()
if (deband) cleanupDeband()
deband = new VideoDeband(video)
deband.canvas.classList.add('deband-canvas', 'w-full', 'h-full', 'pointer-events-none', 'object-contain')
video.before(deband.canvas)
return { destroy: cleanupDeband }
}
$: createDeband(video, $settings.playerDeband)

View file

@ -76,10 +76,6 @@
<Button on:click={copyLogs} class='btn btn-primary'>Copy To Clipboard</Button>
</SettingCard>
<SettingCard title='Open Torrent Devtools' description="Open devtools for the detached torrent process, this allows to inspect code execution and memory. DO NOT PASTE ANY CODE IN THERE, YOU'RE LIKELY BEING SCAMMED IF SOMEONE TELLS YOU TO!">
<Button on:click={native.openTorrentDevtools} class='btn btn-primary'>Open Devtools</Button>
</SettingCard>
<SettingCard title='Open UI Devtools' description="Open devtools for the UI process, this allows to inspect media playback information, rendering performance and more. DO NOT PASTE ANY CODE IN THERE, YOU'RE LIKELY BEING SCAMMED IF SOMEONE TELLS YOU TO!">
<Button on:click={native.openUIDevtools} class='btn btn-primary'>Open Devtools</Button>
</SettingCard>

View file

@ -32,6 +32,7 @@
],
"include": [
"src/service-worker/index.ts",
"src/**/*.js",
"src/**/*.ts",
"src/**/*.d.ts",
"src/**/*.svelte",