Forks, split-off threads, cross-posts (#242 step 1c) #300

Merged
littlefox merged 7 commits from issue-284-forks into main 2026-10-22 23:28:37 +00:00
Owner

Closes #284

#242 step 1c: forks, split-off threads, cross-posts.

  • Forks as chips (chat): under a post (not the top one) with two or more replies, a chip per branch — "Namn: «ämne/första orden» · N", "N nya". Only the chosen branch is drawn, indented: the one clicked (while the same post is read), else the one being read, else the one with the first unread, else the first.
  • Split-off threads: a reply with a new subject (same_subject ignores Re:/SV:) is a thread of its own. Thread list and index group by topic root (kom_client::topics: subject fetches only the first line and remembers it; splits_off, topic_root); the parent's counts leave it out; its card says "utbruten från «…»" with a link back. In the parent's chat it's a one-line pointer; reading it shows it as its own chat under "Utbruten från «…»". Reading by thread still follows the whole tree.
  • Cross-posts: a card names the other channels ("även i X"). A reply in none of the channels of what it answers (crosses) starts a thread in its channel, "svar på ett inlägg i X" with a link; in the chat it's a pointer "Svar i X: «…»".

Verified: new e2e/tests/forks.spec.ts on seeded Grenar/Utblick (choosing a branch, following a split and back, list cards for split and cross-posted threads, a reply from another channel) and updated thread-chat spec, all in desktop/android/iphone; full e2e suite 362 passed; devserver integration tests 17 passed (new split and crossing cases); unit tests for the layout; lint with CI's three clippy commands; screenshots looked at.

🤖 Generated with Claude Code

https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8

Closes #284 #242 step 1c: forks, split-off threads, cross-posts. - **Forks as chips** (chat): under a post (not the top one) with two or more replies, a chip per branch — "Namn: «ämne/första orden» · N", "N nya". Only the chosen branch is drawn, indented: the one clicked (while the same post is read), else the one being read, else the one with the first unread, else the first. - **Split-off threads**: a reply with a new subject (`same_subject` ignores Re:/SV:) is a thread of its own. Thread list and index group by *topic root* (`kom_client::topics`: `subject` fetches only the first line and remembers it; `splits_off`, `topic_root`); the parent's counts leave it out; its card says "utbruten från «…»" with a link back. In the parent's chat it's a one-line pointer; reading it shows it as its own chat under "Utbruten från «…»". Reading by thread still follows the whole tree. - **Cross-posts**: a card names the other channels ("även i X"). A reply in none of the channels of what it answers (`crosses`) starts a thread in its channel, "svar på ett inlägg i X" with a link; in the chat it's a pointer "Svar i X: «…»". Verified: new `e2e/tests/forks.spec.ts` on seeded Grenar/Utblick (choosing a branch, following a split and back, list cards for split and cross-posted threads, a reply from another channel) and updated thread-chat spec, all in desktop/android/iphone; full e2e suite 362 passed; devserver integration tests 17 passed (new split and crossing cases); unit tests for the layout; lint with CI's three clippy commands; screenshots looked at. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
A post with two or more replies showed every branch below it, indented,
so a forked conversation read as an interleaved list. Now its branches
are chips under it (who, what, how many, how many new) and only the
chosen one is drawn: the one clicked, else the one being read, else the
one with the first unread.

Refs #284

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
A reply that changes the subject is a new conversation, but it was
drawn inside its parent's thread and counted there. Now it is a card
of its own in the thread list ("utbruten från «…»", with a link back),
left out of its parent's counts, and a one-line pointer in the parent's
chat; reading it shows it as its own chat. The thread list and index
group by topic root, found from the texts' first lines; reading by
thread still follows the whole tree.

Refs #284

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
A cross-posted thread now names the other channels it is in, and a
reply in none of the channels of what it answers starts a thread where
it is, saying "svar på ett inlägg i X" with a link, instead of being
listed under a root in another channel. In the chat such a reply is a
pointer, like a split-off thread.

Refs #284

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
Refs #284

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
Roadmap: #242 step 1c done
All checks were successful
ci / check (push) Successful in 8m45s
ci / desktop (push) Successful in 15m5s
ci / e2e (push) Successful in 36m52s
7d9335c234
Refs #284

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XJW2ocwLunyaLiUwCBHEP8
littlefox referenced this pull request from a commit 2026-10-24 13:23:56 +00:00
Sign in to join this conversation.
No description provided.