Wrap the reply chip to the width of a message
The chip sat outside the row that holds the text, so it wrapped against the whole row: wider than any message in the column, and on a narrow window out to the window's own edge, where the message beside it stops well short to leave the ↩ and ☺ their room. It goes in the text's column now. It is a quote of a line, so it takes the width a line has and lines up with the one it belongs to — which puts it under the sender's name rather than above it, where it reads as part of what they said rather than as a heading over them. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
57c7119 parent: 74c483a modified
src/frq/app.jolt +7 -3 | @@ -374,9 +374,6 @@ | ||
| 374 | 374 | ;; The jump target is what a "go to message" click scrolls to. |
| 375 | 375 | :scroll-here (boolean (and (:id m) (= (:id m) @s/jump-to)))} |
| 376 | 376 | [(if highlit? :card :vbox) {:key :body :spacing 2 :margin 0} |
| 377 | - [:vbox {:key :reply-chip} | |
| 378 | - (when-let [reply-to (:reply-to m)] | |
| 379 | - [reply-chip @s/current reply-to])] | |
| 380 | 377 | ;; A run from one person reads as one block; repeating the nick on every |
| 381 | 378 | ;; line is what made a busy channel look like a list of headers. The time |
| 382 | 379 | ;; rides on that same line, for the same reason: once per run, not once |
| @@ -427,6 +424,13 @@ | ||
| 427 | 424 | ;; a message and the reactions on it, coming from nothing anyone asked |
| 428 | 425 | ;; for. |
| 429 | 426 | [:vbox {:key :text :spacing 2} |
| 427 | + ;; What this answers, in the column the answer itself is in: the chip | |
| 428 | + ;; is a quote of a line, so it wraps to the width a line has. Outside | |
| 429 | + ;; this column it wrapped to the whole row instead — wider than any | |
| 430 | + ;; message, and out to the window's edge on a narrow screen. | |
| 431 | + [:vbox {:key :reply-chip} | |
| 432 | + (when-let [reply-to (:reply-to m)] | |
| 433 | + [reply-chip @s/current reply-to])] | |
| 430 | 434 | (map-indexed (fn [j run] (run-node j run (:system? m))) |
| 431 | 435 | (text-runs (:text m))) |
| 432 | 436 | [:vbox {:key :reactions-row :margin-top 6} |
| @@ -374,9 +374,6 @@ | |||
| 374 | ;; The jump target is what a "go to message" click scrolls to. | 374 | ;; The jump target is what a "go to message" click scrolls to. |
| 375 | :scroll-here (boolean (and (:id m) (= (:id m) @s/jump-to)))} | 375 | :scroll-here (boolean (and (:id m) (= (:id m) @s/jump-to)))} |
| 376 | [(if highlit? :card :vbox) {:key :body :spacing 2 :margin 0} | 376 | [(if highlit? :card :vbox) {:key :body :spacing 2 :margin 0} |
| 377 | - [:vbox {:key :reply-chip} | ||
| 378 | - (when-let [reply-to (:reply-to m)] | ||
| 379 | - [reply-chip @s/current reply-to])] | ||
| 380 | ;; A run from one person reads as one block; repeating the nick on every | 377 | ;; A run from one person reads as one block; repeating the nick on every |
| 381 | ;; line is what made a busy channel look like a list of headers. The time | 378 | ;; line is what made a busy channel look like a list of headers. The time |
| 382 | ;; rides on that same line, for the same reason: once per run, not once | 379 | ;; rides on that same line, for the same reason: once per run, not once |
| @@ -427,6 +424,13 @@ | |||
| 427 | ;; a message and the reactions on it, coming from nothing anyone asked | 424 | ;; a message and the reactions on it, coming from nothing anyone asked |
| 428 | ;; for. | 425 | ;; for. |
| 429 | [:vbox {:key :text :spacing 2} | 426 | [:vbox {:key :text :spacing 2} |
| 427 | + ;; What this answers, in the column the answer itself is in: the chip | ||
| 428 | + ;; is a quote of a line, so it wraps to the width a line has. Outside | ||
| 429 | + ;; this column it wrapped to the whole row instead — wider than any | ||
| 430 | + ;; message, and out to the window's edge on a narrow screen. | ||
| 431 | + [:vbox {:key :reply-chip} | ||
| 432 | + (when-let [reply-to (:reply-to m)] | ||
| 433 | + [reply-chip @s/current reply-to])] | ||
| 430 | (map-indexed (fn [j run] (run-node j run (:system? m))) | 434 | (map-indexed (fn [j run] (run-node j run (:system? m))) |
| 431 | (text-runs (:text m))) | 435 | (text-runs (:text m))) |
| 432 | [:vbox {:key :reactions-row :margin-top 6} | 436 | [:vbox {:key :reactions-row :margin-top 6} |