feat(feed): bound feed lifecycle to 30-day window with nonblocking refresh
Persisted feeds keep only episodes from the last 30 days (plus completed downloads); older episodes live in volatile memory and survive refreshes via union merge, with per-feed in-memory caches capped at 500. Refresh batches run at FETCH_CONCURRENCY=4 with per-feed incremental apply (no Promise.all barrier), config.json writes are trailing-edge debounced (250ms, immediate flushPendingSave for unsubscribes), and cold fetch-more refetches abort at FETCH_TIMEOUT_MS. A shared activity store powers a global top-right indicator covering refresh, fetch-more, subscribe, search, and downloads. Also includes the in-flight incremental RSS parsing (chunked with event-loop yields) and refresh spinner work this tree already carried.
This commit is contained in:
@@ -66,6 +66,7 @@ type TestPaneProps = {
|
||||
current?: (() => unknown) | unknown;
|
||||
preview?: unknown;
|
||||
focused?: unknown;
|
||||
currentBorder?: unknown;
|
||||
width?: number;
|
||||
height?: number;
|
||||
};
|
||||
@@ -83,6 +84,7 @@ async function renderPaneRow(props: TestPaneProps): Promise<{
|
||||
preview={props.preview as any}
|
||||
currentLabel="List"
|
||||
focused={props.focused as any}
|
||||
currentBorder={props.currentBorder as any}
|
||||
/>
|
||||
</ThemeProvider>
|
||||
),
|
||||
@@ -232,4 +234,17 @@ describe("PaneRow current-pane borders", () => {
|
||||
expect(borderColumns(spans)).toEqual([20, 69]);
|
||||
expect(frameText(spans)).not.toMatch(boxGlyphs);
|
||||
});
|
||||
|
||||
test("currentBorder=['left'] removes the right edge (left only)", async () => {
|
||||
const { spans, destroy } = await renderPaneRow({
|
||||
parent: null,
|
||||
current: () => <text>ITEM</text>,
|
||||
preview: null,
|
||||
currentBorder: ["left"],
|
||||
});
|
||||
cleanups.push(destroy);
|
||||
// Only the left border glyph at column 20 — no right edge at 69.
|
||||
expect(borderColumns(spans)).toEqual([20]);
|
||||
expect(frameText(spans)).not.toMatch(boxGlyphs);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user