feat(text): apply paragraph spacing and first-line indent (11.14 layer 2) - #68
Open
thejustinwalsh wants to merge 1 commit into
Open
feat(text): apply paragraph spacing and first-line indent (11.14 layer 2)#68thejustinwalsh wants to merge 1 commit into
thejustinwalsh wants to merge 1 commit into
Conversation
size-limit report 📦
|
…r 2) spaceBefore shifts a thread's first band exactly once where the paragraph truly starts; resumed threads and region breaks swallow it. spaceAfter rides every block measurement so consumers stack paragraphs from reported extents. firstLineIndent narrows the paragraph's first composed line and shifts the pen on the paragraph-direction side: LTR pens move right, RTL pens keep their origin while the reduced available width pulls the right edge inward, so alignment and justification compose over the reduced slot unchanged. Measurements mirror both, the intrinsic pass reuses the constraint-carried values, and the public Text gains wordSpacing style plus the contentBox typography fields. Proven red-green at flow-composition, measurement, and Three integration levels.
thejustinwalsh
force-pushed
the
feat/paragraph-spacing-indent
branch
from
August 12, 2026 06:00
d95ab8e to
fd0dac5
Compare
thejustinwalsh
marked this pull request as ready for review
August 14, 2026 02:32
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Layer 2 of the 11.14 typography tier:
spaceBefore,spaceAfter, andfirstLineIndentbegin steering layout, and the publicTextgainswordSpacingstyle plus the contentBox typography fields.Semantics
spaceBeforeshifts a thread's first band exactly once, where the paragraph truly starts. Resumed threads (resumeCluster/resumeRegionnonzero) and region breaks swallow it — standard fragmentation behavior.spaceAfterrides every block measurement, so consumers stack paragraphs from reported extents. It participates in at-most axis resolution and overflow detection.firstLineIndentnarrows the paragraph's first composed line (the break decision sees the reduced width) and shifts the pen on the paragraph-direction side: LTR pens move right; RTL pens keep their origin while the reduced available width pulls the right edge inward. Alignment and justification compose over the reduced slot unchanged. Measurements include the indent in first-line inline extents, and the intrinsic pass reuses the same constraint-carried values.Evidence
Red-green at three levels: flow-composition unit tests (band shift, resume immunity, first-line break narrowing), a measurement unit test (indent in inline extent, space-after in block extent), and a Three integration segment pinning the exact 30-unit pen shift, 8-unit baseline shift, and content extents through the real Wasm engine. 176 Rust lib tests; full package check green.