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: dasl offline read issue

+6 -2
+6 -2
src/components/transformer/output/bytes/dasl-sync/element.js
··· 174 174 this.facets = this.managerProp( 175 175 { save: async (v) => local()?.facets.save(v) }, 176 176 remote.facets, 177 + remote.ready, 177 178 facets, 178 179 ); 179 180 180 181 this.playlistItems = this.managerProp( 181 182 { save: async (v) => local()?.playlistItems.save(v) }, 182 183 remote.playlistItems, 184 + remote.ready, 183 185 playlistItems, 184 186 ); 185 187 186 188 this.tracks = this.managerProp( 187 189 { save: async (v) => local()?.tracks.save(v) }, 188 190 remote.tracks, 191 + remote.ready, 189 192 tracks, 190 193 ); 191 194 ··· 393 396 * @template {{ id: string; updatedAt: string }} T 394 397 * @param {{ save: (bytes: Uint8Array) => Promise<void> | void }} local 395 398 * @param {{ collection: SignalReader<{ state: "loading" } | { state: "loaded"; data: Uint8Array | undefined }>, reload: () => Promise<void>, save: (bytes: Uint8Array) => Promise<void> }} remote 399 + * @param {SignalReader<boolean>} remoteReady 396 400 * @param {SignalReader<Container<T>>} container 397 401 * @returns {{ collection: SignalReader<{ state: "loading" } | { state: "loaded"; data: T[] }>, reload: () => Promise<void>, save: (items: T[]) => Promise<void> }} 398 402 */ 399 - managerProp(local, remote, container) { 403 + managerProp(local, remote, remoteReady, container) { 400 404 return { 401 405 collection: computed(() => { 402 406 const c = container(); 403 407 404 - if (remote.collection().state === "loading") { 408 + if (remoteReady() && remote.collection().state === "loading") { 405 409 return { state: "loading" }; 406 410 } 407 411