Reply in a thread
A participant wants to answer a thread, or one particular reply in it, without leaving the conversation.

As a participant, I want to answer a thread, or one particular reply in it, without leaving the conversation, so that my answer lands exactly where it belongs.

Situation

I am reading a thread and have an identity selected on this phone. I may have arrived from a document, from All comments, or from a notification in Activity.

What I do

    Tap the field at the bottom, "Write a reply…", and type.

    Tap the send button.

    To answer one specific reply, tap "Reply" under it, then type and send.

    To change my mind, tap the close button next to "Replying to Name".

What I should see

    A reply field stays fixed at the bottom of the thread and rides above the keyboard.

    The field grows as I type, up to a few lines.

    The send button is dimmed while the field is empty and while a reply is being published.

    Sending without choosing a reply answers the first comment of the thread.

    After sending, the field empties, my reply appears in the thread, and the phone gives a short success tap. The keyboard stays up.

    The count under the first comment goes up, for example from "No replies yet." to "1 reply".

    Each reply has a "Reply" button under it. Tapping it puts the cursor in the field and shows "Replying to Name" above it.

    A reply sent that way appears indented under the comment I chose and carries "Replying to Name".

    The close button beside "Replying to Name" (read aloud as "Reply to the thread instead") returns to answering the first comment.

    After a reply is published, the target returns to the first comment.

    In a thread opened from Activity, my reply goes to my own server, the one the notification came from.

When something goes wrong

    If publishing fails, a red line appears above the field and my text is kept so I can send again. I may see "The server refused the comment (409): …", "Couldn't reach the server.", or "The reply version is unavailable. Refresh the thread and try again." For the last one I pull down to reload and resend.

Not included

    My reply appears only after the server accepts it; nothing is shown in the meantime except the dimmed send button (Current limits).

    Replies are one plain paragraph: no formatting, pictures or quoted text.

    Replies cannot be edited or deleted.

    The unsent text is one draft for all threads, so it follows me into another thread.

    With no identity there is no field; see the story below.

Trace

Story US-DISC-04, status Shipped. These links are kept in step with the traceability matrix and with the "User stories" section of every page listed here.

Design

Page

Part it plays

Thread

The screen with the pinned composer and per-reply "Reply" buttons

DiscussComposer

The pinned field, the "Replying to" line, the error line and Send

DiscussBubble

The new reply, indented, with "Replying to Name"

input, textarea, select and label

The growing textarea

button

Reply, Send and the close button

image and symbols

The send and close symbols

Composers

One pinned composer, two targets; keyboard handling

The three composers compared

The thread composer next to the compose sheet and the agents composer

Refresh, haptics and progress

Success haptic; Send disabled while posting

Badges, countdowns and connection status

What signals posting, success and refusal

Forms and inputs

Red error above the field, draft kept

Reading another site in place

Which server a reply goes to

Moving between tabs and into the app

Replying in a thread opened from Activity

Honest state: loading, failure and empty

A refused reply says why

Roles, headings and labels

Labels "Send" and "Reply to the thread instead"

Representative strings

Exact placeholder and error wording

Implementation

Page

Part it plays

Discuss: posting a comment

postComment for replies: parent checks, reply versions, publish

Discuss: screens and components

DiscussThreadScreen send target and DiscussComposer

Discuss: root contract wiring

discussDraft, discussReplyTo, discussSetReply focus, discussAfterPost

Discuss: threading logic

replyVersions and how the new reply nests

Discuss: loading and posting

The parent lookup and the listing dropped after a post

Crypto: changes, refs, comments and profiles

Comment blob with reply parent and thread root versions

Crypto: parity vectors against the original client

Reply bytes match the original client

Identity: key storage

The signer for the current identity

Publishing signed blobs

POST /api/PublishBlobs

Root declarations: Read and Discuss

discussPosted refreshes discussions and discussThreads

Read: root contract wiring

readContextServer, including the Activity thread context

Contract views and built-in calls

focus, haptic and interactive-widget built-ins

Contract UI tests

The reply steps of the write test; the Activity thread reply test

Bun unit tests

Reply refusals and reply version unit tests

The local test server

The local server whose publish endpoint refuses with 409

Current limits and known gaps

No optimistic insert; plain paragraph

Code

File

What

discuss.contract L152-184

DiscussComposer

discuss.contract L207-214

the reply target and the send action of DiscussThreadScreen

discuss.contract L234-240

the per-reply "Reply" button and the pinned composer

app.contract L333-357

discussEdit, discussSetReply, discussPost, discussAfterPost

app.contract L118-119

discussPosted mutation and discussPostError

src/discuss/load.ts L158-229

postComment (parent checks at 182-189)

src/discuss/logic.ts L232-238

replyVersions

src/crypto/comment.ts L486-500

createComment

src/identity/index.ts L107-114

signerFor

Tests

File

What it checks

discuss.test.contract

discuss: post a comment and replies on dev.hyper.media with a throwaway key

open-site-activity.test.contract

Activity thread fetch and reply use the configured server, not the covered document origin

src/discuss/__tests__/load.test.ts

posting refuses a reply parent from another document before signing or publishing; reply to a nested parent without a root version is refused; posting a valid nested reply sends current document, parent and root versions

src/discuss/__tests__/logic.test.ts

a reply targets the tapped comment, the root stays the thread root (RN bug fix); a reply to a reply signs replyParent = that reply, threadRoot = the root

Delivery

Delivered by #1470, #1484.

Do you like what you are reading? Subscribe to receive updates.

Unsubscribe anytime

Attributes
Epic
Discussion
name
Reply in a thread
Story
US-DISC-04
Status
Shipped
summary
A participant wants to answer a thread, or one particular reply in it, without leaving the conversation.