fix(offline): edge cases and code cleanup
- Fix online transition callback not triggering on manual mode disable - Fix $derived pattern in DownloadButton (use $derived.by) - Remove unused OptionalExtension import in offline/mod.rs
This commit is contained in:
1 parent
e7f06fcd2f
commit
a219a1dcb6
3 files changed
+9
-3
No files matched your search
@@ -49,7 +49,7 @@
|
||||
}
|
||||
}
|
||||
|
||||
const title = $derived(() => {
|
||||
const title = $derived.by(() => {
|
||||
// Show offline message when trying to download while offline
|
||||
if (isOffline && (status === 'none' || status === 'failed')) {
|
||||
return $t('offline.featureDisabled');
|
||||
@@ -77,7 +77,7 @@
|
||||
class:failed={status === 'failed'}
|
||||
class:offline={isOffline && status !== 'ready'}
|
||||
onclick={handleClick}
|
||||
title={title()}
|
||||
title={title}
|
||||
disabled={isDisabled}
|
||||
>
|
||||
{#if status === 'ready'}
|
||||
|
||||
Reference in new issue
Block a user