Keep a feed, an OPML or a Patreon creator out of All Subscriptions (#288)
A switch in the feed's settings, In All Subscriptions, on its subscription as hide_from_all. All Subscriptions' list and count leave out a feed hidden on its own or through the OPML it is in, and the page's unread count does the same. Signals read every feed as before, and Currently Listening, which is All Subscriptions' in-progress filter, keeps an episode under way whatever the feed's setting. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -35,6 +35,11 @@ const VIEWS: Record<string,{title: string, icon: string, url?: string, blurb?: s
|
||||
blurb:'Episodes you started and have not finished, across every feed you subscribe to. Pick one up where you left off.'},
|
||||
':all':{title:'All Subscriptions',icon:ICON.all},
|
||||
};
|
||||
/// Whether a feed's items are in All Subscriptions: not when it, or the OPML or creator it came
|
||||
/// from, is hidden from it (#288). The server leaves out the same.
|
||||
const inAll=(f: Feed)=>!f.hide_from_all&&!(f.group&&S.feeds.some(g=>g.id===f.group&&g.hide_from_all));
|
||||
/// All Subscriptions' unread count.
|
||||
const unreadInAll=()=>S.feeds.reduce((n,f)=>n+(inAll(f)?f.unread||0:0),0);
|
||||
/// Feeds being checked right now, from the event stream, and since when: their rows, and the row
|
||||
/// of a folder holding one, carry a spinner.
|
||||
const scanning=new Map<string, number>();
|
||||
@@ -90,7 +95,7 @@ function renderFeeds(){
|
||||
const drawn=new Map<string,HTMLImageElement[]>();
|
||||
for(const img of $$<HTMLImageElement>('img',list)){ const k=img.outerHTML; if(!drawn.has(k)) drawn.set(k,[]); drawn.get(k)!.push(img); }
|
||||
list.innerHTML='';
|
||||
const unreadAll=S.feeds.reduce((n,f)=>n+(f.unread||0),0);
|
||||
const unreadAll=unreadInAll();
|
||||
const places=document.createElement('div');
|
||||
places.className='places';
|
||||
for(const [id,v] of Object.entries(VIEWS)){
|
||||
|
||||
Reference in New Issue
Block a user