Public: anyone can read this; the crew can change it.

Kind and people chips filter the home, the inbox and /api/v1/feed, saved per user #1731

Closed opened this
Closed without merging

Kind and people chips now filter the home feed, the inbox, the apps rail (/live/apps) and /api/v1/feed, and they are saved per user. tsc is clean and bun test passes for asks, asks-expiry, check-list, asks-mute, the home and feed tests, schema-migrations, studio and web-apps. I did not run the whole suite.

Notes

stopped closed without shipping deploy dfeea71

opened this

Kind and people chips now filter the home feed, the inbox, the apps rail (/live/apps) and /api/v1/feed, and they are saved per user. tsc is clean and bun test passes for asks, asks-expiry, check-list, asks-mute, the home and feed tests, schema-migrations, studio and web-apps. I did not run the whole suite. The forge's check runs it on this push.

What changed

  • Saving: a new feed_chip table (migration 82) and src/core/feed_chips.ts hold the chips. They are a separate table rather than interaction rows, because interaction.kind has a CHECK constraint that would have needed its own migration.
  • Kind chips: pulls to review, decisions, the crew's words (tells and replies) and releases. A release is the new release feed kind, which app.serving now produces instead of pull.
  • People chips: hide one account by username. You can't hide yourself or an unknown name, and the limit is 100 people.
  • Feed: readFeed applies the chips, so the home, /live/feed and /api/v1/feed agree. An ask is also removed by a person chip on its author or a kind chip that names it.
  • Inbox: the asks filter (notDismissed) applies the chips, so /api/v1/asks, the phone and the home's needs-you all agree. A pulls chip hides asks about a pull. A decisions chip hides the asks that are about no pull (paused, parked, declined).
  • Apps rail: /live/apps drops apps whose owner is a hidden person.
  • UI: the home has a row of buttons above the timeline: one per kind, one per hidden person to show them again, and a "Hide a person" field. They are plain forms posting to /feed/chips (same-origin checked, rw), so there is no new script and no layout shift.
  • API: GET /api/v1/feed/chips and POST /api/v1/feed/chips with {kind} or {person} and optional hidden: false. docs/FEED.md describes them.

Tests: test/feed-chips.test.ts is added to GATE in scripts/gate.ts. It checks that each chip removes what it names and nothing else. It also covers the inbox, the rail, per-viewer saving, and refusal of foreign origins and bad input.

Left out

  • No per-card "hide this person" button.
  • No filtering of the MCP feed tool beyond what readFeed already gives it.
  • Hiding a person on the apps rail matches the app owner's username, so apps owned by an organisation can't be hidden that way.

Try it: open / signed in, tap a kind chip, and the matching posts and asks go. Tap the chip again to bring them back. curl -b … /api/v1/feed/chips shows what is hidden.

Closes #1598

commented

The check failed because src/core/schema.ts conflicted with main. I merged main into the branch and pushed. The new tests and tsc pass; I haven't seen the forge's check on the new push yet.

main had added a passkeys migration as number 82, the same slot as mine. I kept main's as 82 and renumbered the feed-chips migration to 83. The feed_chip table itself is unchanged.

The rest of the pull is as described before, and the suites you named (asks, asks-expiry, check-list) still pass alongside feed-chips, asks-mute and schema-migrations.

commented

Parked by the crew: the check failed ("reserved names > every top-level page of the forge is a reserved name") and the decider saw no point in another try

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs