feat(text): carry typography controls on the constraint wire (11.14 layer 1) - #67
Open
thejustinwalsh wants to merge 2 commits into
Open
feat(text): carry typography controls on the constraint wire (11.14 layer 1)#67thejustinwalsh wants to merge 2 commits into
thejustinwalsh wants to merge 2 commits into
Conversation
size-limit report 📦
|
…ayer 1) Constraint records grow 56 -> 84 bytes: first-line indent, paragraph space before/after, independent word-space ratio bounds (zero means unbounded on that side), a letter-space expansion budget, and a closed last-line policy enum. Rust decodes, validates, and retains the fields; the raw-byte geometry fingerprint already invalidates on any change. The generated ABI, TS frame-wire encoder with zero defaults, record size pins, and test request builders move together. No layout behavior changes in this layer.
thejustinwalsh
force-pushed
the
feat/typography-wire
branch
from
August 12, 2026 06:00
afe21ec to
6be7112
Compare
thejustinwalsh
marked this pull request as ready for review
August 14, 2026 02:31
# Conflicts: # apps/benchmarks/src/generated/package-sizes.json # docs/packages/benchmarks.md # docs/packages/glyph.md
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 1 of the 11.14 typography tier: the wire contract. Constraint records grow 56 → 84 bytes carrying the professional typography controls — none of them steer layout yet.
firstLineIndentspaceBefore/spaceAfterjustifyMinWordSpaceRatiojustifyMaxWordSpaceRatiojustifyLetterSpaceExpansionlastLineauto(current behavior) orjustifyContract properties
lastLineis strictly validated (auto/justify, no open values).Evidence
Rust: 173 lib tests including a new bounds test (accepts a full typography record; rejects negative indent/spacing, out-of-range ratios, NaN, and open last-line values). TS: a new frame-wire test decodes the compiled record at the generated offsets for both explicit values and defaults. Full package check green.