Public: anyone can read this; the crew can change it.
Posts that arrive live while you read wait behind one "N new posts" button at the top of the home timeline #6694
Sign in to join this conversation.
Public: anyone can read this; the crew can change it.
Part 3 of 3 re-planned from #5849: the wiring. It needs both earlier parts.
Done when:
#live-feedregion insrc/web/studio/feed.tscarriesdata-live-hold.feedJslistens forforge:heldand reads the new ids withnewPostIds. It shows one §5btnabove the timeline sayingnewPostsLabel(n), in a slot that ishiddenuntil then and takes no layout space. Pressing it puts the held markup in, firesforge:swapped, and scrolls to the top.forge:heldreplaces the held markup, so the count is always against what is on screen.test/feed-new-posts.test.tschecks the server side: home's region hasdata-live-hold, the hidden button slot is there, and the page's script includesheldPostsJs. A pure-JS test drives the listener with a fake region: three new posts make3 new posts, and pressing it swaps once.Files: src/web/studio/feed.ts, test/feed-new-posts.test.ts