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

open not picked up yet opened this
opened this

Part 3 of 3 re-planned from #5849: the wiring. It needs both earlier parts.

Done when:

  • [ ] The #live-feed region in src/web/studio/feed.ts carries data-live-hold.
  • [ ] feedJs listens for forge:held and reads the new ids with newPostIds. It shows one §5 btn above the timeline saying newPostsLabel(n), in a slot that is hidden until then and takes no layout space. Pressing it puts the held markup in, fires forge:swapped, and scrolls to the top.
  • [ ] A later forge:held replaces the held markup, so the count is always against what is on screen.
  • [ ] test/feed-new-posts.test.ts checks the server side: home's region has data-live-hold, the hidden button slot is there, and the page's script includes heldPostsJs. A pure-JS test drives the listener with a fake region: three new posts make 3 new posts, and pressing it swaps once.
  • [ ] Unlike #5849, no real-browser CLS test; the hidden slot is what keeps layout still. A look on the preview shows the button.

Files: src/web/studio/feed.ts, test/feed-new-posts.test.ts

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs