From b2484b900ef62970eb1b0c244cfb1da240a2620f Mon Sep 17 00:00:00 2001 From: iris-ai <4+iris-ai@noreply.localhost> Date: Fri, 18 Sep 2026 13:14:09 -0400 Subject: [PATCH] Record that a leftover share narrows the frame like px and rel Bryan's decision of 2026-09-18, which answers the Pad question and makes the code's leftover filter in declared_lens a bug. Co-Authored-By: Claude Fable 5.1 --- docs/HANDOFF.md | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/docs/HANDOFF.md b/docs/HANDOFF.md index e817d41..e6ff0c9 100644 --- a/docs/HANDOFF.md +++ b/docs/HANDOFF.md @@ -50,6 +50,13 @@ where it stands. The step list the plan carried is gone: steps 1 to 5 are in too), an inset's margins, the root. A box that is an *answer* (a row's height, a stack sized by a child) is never anything's frame. - `rel` overflows on purpose when it sums past one or has pixels beside it. +- **A `leftover` share narrows the frame exactly as a declared `px` or `rel` + does** (Bryan, 2026-09-18: "Leftover was always intended to narrow the + frame just like the other two"). The code's `declared_lens` filtering + `leftover` out of what narrows a child's frame is a bug, and so is the + wording above and in the plan that a frame is narrowed only by a declared + length, an inset or the root. `rel(1.0)` inside a share is the share; + inside a padded share it is the share less the padding, so it fits. - `Inset` and `Outset` take `px`, `rel` and `leftover` margins. Outset adds its margins to the child's report and moves the child in; Inset draws the child in a frame with the margins subtracted and reports the child's size @@ -459,7 +466,18 @@ beside a `leftover` child in a horizontally scrolling row) needs its own decision; Compose gives the text an unbounded width there. None of this was run; it is what the traces and the two experiments point at. -**Question 2, `Pad`.** The contradiction is not specific to `Pad`. A +**Question 2, `Pad`.** Answered by the decision above that a share narrows +the frame: the overflow in the example comes from the pad sitting in a +`leftover` share whose length did not narrow the frame, and once it does, +`rel(1.0)` inside the pad is the share less the padding and fits. `Pad` +stays an outset. What follows for `Span` is that a `leftover` child's frame +is only known once the room is divided, so the child cannot be settled at +a measuring ask made in the room; it must be given its share as its frame +when placed, which is one more reason for the single decided-box evaluation +recommended above. The paragraph below is the earlier reading, kept for the +record. + +The contradiction is not specific to `Pad`. A `rel(1.0)` child directly in a half-row `Fill` slot overflows its slot because `rel` is of the row, and Bryan accepted that. A `rel(1.0)` inside a pad in that slot overflows the pad's box for the same reason and by the same