Carry mid-segment paragraph breaks from the editor to the server #69
Loading…
Reference in a new issue
No description provided.
Delete branch "paragraph-breaks-mid-segment-controls"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Transcript administrators can start a new paragraph at a segment boundary, but not in the middle of a segment's text. #68 added paragraph breaks and stored each one on a segment, so a break mid-sentence means splitting that segment in two. The store can't split a segment yet.
This change builds everything between the click and that split, so the next change only has to teach the store to split:
POST /admin/transcripts/{slug}/segments/{id}/paragraph-breakwith the segment's text and the break's offset. A break at either end of a segment still takes the boundary path from #68. Both Shift-click and the context menu reach the new endpoint.501 Not Implementeduntil the store can split. It retargets the response to the editor's error region, so an error never replaces the transcript. A malformed segment ID answers400the same way.Until the split lands, a break inside a segment reports "Paragraph breaks within a segment are not implemented yet." Before this change, that click did nothing at all.
Testing gap: no browser test exercises the context menu's paragraph action, here or before this change. Only Shift-click runs in a browser.
Co-Authored-By: Claude Opus 5 noreply@anthropic.com
ddf3655172c011a679efc011a679ef6495f88e0d6495f88e0da48b40b24ca48b40b24cd138ed8c1bLet the editor request a paragraph break inside a segmentto Tell editors why a paragraph break inside a segment does nothingTell editors why a paragraph break inside a segment does nothingto Report that a paragraph break inside a segment isn't supported yetReport that a paragraph break inside a segment isn't supported yetto Carry mid-segment paragraph breaks from the editor to the serverd138ed8c1b3a40ed2664