Derive all the things

This commit is contained in:
Jon Staab
2025-02-06 08:50:50 -08:00
parent 6a3a02bc34
commit 72919cb1c2
2 changed files with 2 additions and 2 deletions

View File

@@ -26,7 +26,7 @@
const {url, event, showActivity = false}: Props = $props()
const thunk = $thunks[event.id]
const thunk = $derived($thunks[event.id])
const deleted = deriveIsDeleted(repository, event)
const path = makeSpacePath(url, "threads", event.id)
const filters = [{kinds: [COMMENT], "#E": [event.id]}]

View File

@@ -27,7 +27,7 @@
: publishThunk((thunk as Thunk).request)
}
const status = throttled(300, thunk.status)
const status = $derived(throttled(300, thunk.status))
const ps = $derived(Object.values($status))
const canCancel = $derived(ps.length === 0 && $userSettingValues.send_delay > 0)
const isFailure = $derived(!canCancel && ps.every(s => [Failure, Timeout].includes(s.status)))