We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7d85074 commit 4931201Copy full SHA for 4931201
src/core/focusManager.ts
@@ -18,7 +18,11 @@ class FocusManager extends Subscribable {
18
this.removeEventListener()
19
}
20
this.removeEventListener = setup((focused?: boolean) => {
21
- this.setFocused(focused)
+ if (typeof focused === 'boolean') {
22
+ this.setFocused(focused)
23
+ } else {
24
+ this.onFocus()
25
+ }
26
})
27
28
src/core/onlineManager.ts
@@ -18,7 +18,11 @@ class OnlineManager extends Subscribable {
this.removeEventListener = setup((online?: boolean) => {
- this.setOnline(online)
+ if (typeof online === 'boolean') {
+ this.setOnline(online)
+ this.onOnline()
0 commit comments