A music player that connects to your cloud/distributed storage.
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix: atproto output set isOnline

+14 -1
+14 -1
src/components/output/raw/atproto/element.js
··· 74 74 // SIGNALS 75 75 76 76 #did = signal(/** @type {string | null} */ (null)); 77 + #isOnline = signal(navigator.onLine); 77 78 78 79 // STATE 79 80 80 81 did = this.#did.get; 81 82 82 83 ready = computed(() => { 83 - return this.#did.value !== null && navigator.onLine; 84 + return this.#did.value !== null && this.#isOnline.value; 84 85 }); 85 86 86 87 // LIFECYCLE ··· 100 101 super.connectedCallback(); 101 102 102 103 this.#tryRestore(); 104 + 105 + globalThis.addEventListener("online", this.#online); 106 + globalThis.addEventListener("offline", this.#offline); 103 107 } 108 + 109 + /** @override */ 110 + disconnectedCallback() { 111 + globalThis.removeEventListener("online", this.#online); 112 + globalThis.removeEventListener("offline", this.#offline); 113 + } 114 + 115 + #offline = () => this.#isOnline.set(false); 116 + #online = () => this.#isOnline.set(true); 104 117 105 118 // AUTH 106 119