Signal counts kept current on the page: after a read, and when Jev picks something out (#258)
The page fetched the Signals' unread counts only with the feed list, so reading an item, here or in its own feed, left its Signal's badge as it was, and so did Jev adding one. The Apple Signal said 2 unread over a page with none. The page now fetches them again after a read or unread lands, and on a new signal_hits event, which the judge sends once a pass for each person it found items for. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -2,6 +2,12 @@
|
||||
/// Signals (#254): feeds you make from your own subscriptions, holding the items TypeSafe's Jev
|
||||
/// says are about the keywords you gave. A Signal is a place in the sidebar, `:signal:<id>`.
|
||||
|
||||
/// The Signals' counts again, which nothing else brings: reading an item, here or in its feed,
|
||||
/// and Jev picking one out both change them (#258). Once a burst has passed.
|
||||
const refreshSignals=(()=>{ let t: number; return ()=>{ clearTimeout(t); t=setTimeout(()=>{
|
||||
api('/api/signals').then((r: Signal[])=>{ S.signals=r; renderFeeds(); }).catch(()=>{});
|
||||
},400); }; })();
|
||||
|
||||
/// The Signal's id in a place's id, or null for anything else.
|
||||
function signalId(view: string|null){
|
||||
const m=/^:signal:(\d+)$/.exec(view||'');
|
||||
|
||||
Reference in New Issue
Block a user