Skip to content

docs(layer-runtime): record that a StyleX build reading Core's built layer viewport inset gets undefined variables - #12314

Merged
cixzhang merged 6 commits into
mainfrom
lane4/layer-viewport-inset-consumer
Nov 21, 2026
Merged

cixzhang merged 6 commits into
mainfrom
lane4/layer-viewport-inset-consumer

Conversation

@cixzhang

@cixzhang cixzhang commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

Summary

A StyleX build outside Core that resolves the published @astryxdesign/core/Layer/layerViewportInset.stylex module to its built dist file reads the layer gutter and caps as CSS variables that Core's stylesheet does not define, so the declaration that uses them is invalid. A swizzled layer component imports the module by that path. A build that compiles the published source entry (the source export condition) defines them. This PR records that as a current gap in architecture:layer-runtime INV11 and adds a consumer build test that asserts the gap. It changes no behavior: the fix waits on an owner decision.

What changes

  • docs/architecture/layer-runtime.md: an "INV11 gap" paragraph under Current gaps (a StyleX build outside Core that resolves the module to its built file gets an undefined variable; a build of the source entry does not; no record decides the fix), the new test in verified_by, and an "INV11 gap" verification row.
  • packages/core/src/Layer/layerViewportInset.consumer-build.test.mjs: builds the entry as Core publishes it, compiles an app file that reads maxBlockSize, maxInlineSize and gutterBlockStart with the app's own StyleX, and asserts that the three variables it references are ones Core's stylesheet does not define. The test fails when the gap closes, and also when its harness breaks (an it.fails would stay green then).

Why it is a gap, not a quick fix

  • StyleX decides that an import is a .stylex module from its specifier, so renaming the built file changes nothing.
  • An app's build turns each constant into a hashed variable and resolves it only from constants it compiled itself, so defineConsts values from a precompiled package never reach it.
  • stylex.defineConsts throws at run time unless compiled, so the module cannot ship uncompiled.
  • Variables defined once on :root would resolve the per-layer keyboard cap and themed spacing there, not on the layer.

Writing rubric results

  • R1 narration: none; the gap paragraph states the current fact.
  • R2 research in the record: none; the StyleX reasons are in this description, not the record.
  • R3 evidence naming a change: none; the verification row names the test and its state.
  • R4 rejected alternatives over one line or outside a decision: none.
  • R5 pull request or issue references remaining: none (searched # + digits, /pull/, /issues/).
  • R6 ruled open questions still listing options: none.
  • R7 project status: none; the paragraph states a current gap in the record's INV11 gap: form, not what is built or what goes first.

Testing

  • vitest run packages/core/src/Layer/layerViewportInset.consumer-build.test.mjs: passes, with the app's CSS referencing three undefined variables.
  • layerViewportInset.source-build.test.mjs still passes.
  • pnpm check:knowledge passes.

Overlap checked: #12307, #12179, #11894, #11859, #11112, #10126, #10124, #10095, #9816, #8485, #8217, #8201, #8133, #8125, #8095, #8084, #8080 (the open ones but #8095 edit other parts of docs/architecture/layer-runtime.md, and #8095's current head no longer changes it; none edits the Current gaps paragraph, verified_by entry or verification row this adds; #12179, #11859, #10126, #10124, #10095, #8217, #8084 and #8080 merge cleanly with main and with this change in that file; #9816, #8485, #8201, #8133 and #8125 already conflict with main there, and so with this change; #11112 and #11894 have merged and #12307 is closed; none touches Layer/layerViewportInset.stylex.ts or the new test)

Owner: fix-loop lane 4. Land path: Specs consistency stamp, CodeBunny, CI, then the shipper merges (records and a test only).

…ead the layer viewport inset

The INV11 gap: a StyleX build outside Core that imports the published
layer viewport inset module, as a swizzled layer component does, gets an
undefined variable, because the module's constants resolve only inside
Core's own build. The consumer build test shows it as an expected
failure.
@vercel

vercel Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
astryx Ready Ready Preview Nov 21, 2026 10:22am UTC

Request Review

@astracat-bot

astracat-bot Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

AI review status for this pull request.

Review status Updated
🟢 Reviewed (for maintainers only) Nov 21, 2026, 2:38 PM UTC

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Nov 17, 2026
@cixzhang cixzhang added the lane:4 Astryx fix-loop lane 4 owns this label Nov 17, 2026
@github-actions github-actions Bot added the needs:spec-owner-review Current knowledge records await owner approval label Nov 17, 2026
@cixzhang

Copy link
Copy Markdown
Contributor Author

/approve-spec 17ef1e8

@github-actions github-actions Bot removed the needs:spec-owner-review Current knowledge records await owner approval label Nov 17, 2026
@github-actions

github-actions Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

PR Analysis Report

🔎 Preview · 1fe6277

Storybook · Sandbox · built from this PR's head

Modified components

Component Size LoC Visual · A11y · RTL
LayerProvider 4.4 kB (0) · 20 B CSS (0) — ✓ · ✓ · ✗
layer — — — · ✓ · —
Layer — — ✓ · ✓ · —

Package size: no published package changed; no new dependencies.

Touched components checked; for the full suites, add ci:run-visual for Visual, ci:run-a11y for Accessibility, ci:run-rtl for RTL.


Generated by PR Enrichment workflow | View full report

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the INV11 gap is real for builds that read Core's built entry, but the record and the title state it more broadly than the test shows.

  • The new gap paragraph (docs/architecture/layer-runtime.md lines 759–762), its verification row (line 959) and the title say every StyleX build outside Core gets undefined variables because the constants resolve only inside Core's build, yet the test covers only a build that resolves the module to its built dist file, while a build that compiles the published source entry (src/Layer/layerViewportInset.stylex.ts, which Astryx's own Vite and Next.js build helpers resolve to) defines all three constants, so please scope that wording to builds that resolve the built file.

Non-blocking: it.fails also passes when the test errors for an unrelated reason, such as a wrong alias path, so pinning today's three undefined references in a plain it would make the row fail both when the gap closes and when the harness breaks.

Claims and files checked

Review mode: same-head; reason: none

  • Claim: every StyleX build outside Core that imports the published module gets undefined variables. False as stated: true for a build that reads the built file, false for one that compiles the published source entry.
  • Claim: a swizzled layer component imports the module by its published path. Verified in the swizzle module graph.
  • Claim: the record adds a gap paragraph, a verified_by entry and a verification row, and leaves INV11's text unchanged. Verified.
  • Claim: the test builds the entry as Core publishes it. Verified: its output equals Core's own dist build of that file.
  • Claim: the test compiles an app module reading three constants and checks that every referenced variable is defined. Verified.
  • Claim: it.fails keeps CI green and fails once the gap closes. Verified; it also stays green on unrelated errors.
  • Claim: StyleX recognises a .stylex module from its import specifier, so renaming the built file changes nothing. Verified in the StyleX compiler.
  • Claim: an app build resolves constants only from ones it compiled itself. Verified: the app CSS keeps unresolved variable references.
  • Claim: stylex.defineConsts throws at run time unless compiled. Verified in the StyleX runtime.
  • Claim: variables defined once on :root would resolve the keyboard cap and themed spacing there. Verified by how custom properties substitute.
  • Claim: the writing rubric results hold. Verified.
  • Claim: the test reports one expected failure, fails without it.fails, the source-build test still passes and the knowledge check passes. Verified by running each.
  • Claim: the listed overlapping pull requests touch other parts of the record, the named ones merge cleanly and the others already conflict with main, and the open lift constant change does not touch the new test. Verified by test merges.
  • Claim: the change alters no behavior. Verified: no public API row and no shipped file changes.
  • File docs/architecture/layer-runtime.md: blocking finding on the gap's scope.
  • File packages/core/src/Layer/layerViewportInset.consumer-build.test.mjs: non-blocking note on it.fails.

Automated review (maintainer link)

Comment thread docs/architecture/layer-runtime.md Resolved
…; the test asserts it

A build that compiles the published source entry defines the constants, so
the INV11 gap names a StyleX build that resolves the module to its built
dist file. The consumer build test now asserts the three undefined
references, so it fails both when the gap closes and when its harness
breaks.
@cixzhang cixzhang changed the title docs(layer-runtime): record that a StyleX build outside Core cannot read the layer viewport inset docs(layer-runtime): record that a StyleX build reading Core's built layer viewport inset gets undefined variables Nov 17, 2026
@cixzhang

Copy link
Copy Markdown
Contributor Author

/approve-spec 02d521b

@github-actions github-actions Bot added needs:spec-owner-review Current knowledge records await owner approval and removed needs:spec-owner-review Current knowledge records await owner approval labels Nov 17, 2026

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the record paragraph, its verification row and the new test agree and are correct; two clauses in the description's overlap note are false at the listed pull requests' current heads.

  • The overlap note says none of the listed pull requests touches Layer/layerViewportInset*, but #12307 adds a test case to packages/core/src/Layer/layerViewportInset.source-build.test.mjs, so please narrow that clause, for example to "none touches Layer/layerViewportInset.stylex.ts or the new test; #12307 adds a case to layerViewportInset.source-build.test.mjs".
  • Regression: the overlap note says each listed pull request edits docs/architecture/layer-runtime.md, but #8095's current head no longer changes that file, so please drop it from the list or say it no longer edits the record.
Claims and files checked

Review mode: same-head; reason: none

  • Changed rules (0).
  • Claim: a StyleX build outside Core that resolves the module to its built file reads the gutter and caps as variables Core's stylesheet does not define, so the declaration is invalid. Verified by the new test (three undefined references).
  • Claim: a swizzled layer component imports the module by its published path. Verified in the swizzle module graph.
  • Claim: a build that compiles the published source entry defines them. Verified: compiled in the app's own build, all three constants are inlined.
  • Claim: the pull request records the gap under INV11, adds a test that asserts it, and changes no behavior. Verified: the record diff is additions only and the test ships in no package.
  • Claim: the record gains a Current gaps paragraph, a verified_by entry and an "INV11 gap" verification row. Verified.
  • Claim: the test builds the entry as Core publishes it, compiles an app file that reads the three constants with the app's own StyleX, and asserts that the three variables it references are ones Core's stylesheet does not define. Verified.
  • Claim: the test fails when the gap closes and when its harness breaks. Verified with a copy that compiles the source entry and a copy whose alias points at a missing file.
  • Claim: the StyleX behaviour the description cites (specifier-based .stylex detection, constants resolved only from definitions the app compiled, defineConsts throwing uncompiled, per-layer values resolving on :root). Verified.
  • Claim: the writing rubric results R1 to R7 hold for the added record text. Verified.
  • Claim: the new test, the source-build test and the knowledge check pass. Verified.
  • Claim: each listed pull request edits other parts of the record. False: #8095 no longer changes it; the other 16 do.
  • Claim: none of the listed pull requests edits the paragraph, entry or row this one adds. Verified by test merges.
  • Claim: all but #8485 merge cleanly with this change in the record, and #8485 already conflicts with main there. Verified by test merges.
  • Claim: none of the listed pull requests touches Layer/layerViewportInset* or the new test. False: #12307 changes layerViewportInset.source-build.test.mjs; none touches the new test.
  • Claim: the land path covers records and a test only. Verified.
  • File docs/architecture/layer-runtime.md: clear.
  • File packages/core/src/Layer/layerViewportInset.consumer-build.test.mjs: clear.

Automated review (maintainer link)

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: CI has not run on this head yet because the pull request is a draft; it runs once the pull request is marked ready for review, and the merge guard requires it to pass.

The record paragraph, its verification row and the new test agree, and the corrected overlap note now holds at every listed pull request's current head, so nothing is left to change.

Claims and files checked

Review mode: same-head; reason: none

  • Changed rules (0).
  • Claim: a StyleX build outside Core that resolves the module to its built file reads the gutter and caps as variables Core's stylesheet does not define, so the declaration is invalid. Verified by the new test (three undefined references).
  • Claim: a swizzled layer component imports the module by its published path. Verified in the swizzle module graph.
  • Claim: a build that compiles the published source entry defines them. Verified: compiled in the app's own build, all three constants are inlined.
  • Claim: the pull request records the gap under INV11, adds a test that asserts it, and changes no behavior. Verified: the record diff is additions only and the test ships in no package.
  • Claim: the record gains a Current gaps paragraph, a verified_by entry and an "INV11 gap" verification row. Verified.
  • Claim: the test builds the entry as Core publishes it, compiles an app file that reads the three constants with the app's own StyleX, and asserts that the three variables it references are ones Core's stylesheet does not define. Verified.
  • Claim: the test fails when the gap closes and when its harness breaks. Verified with a copy that compiles the source entry and a copy whose alias points at a missing file.
  • Claim: the StyleX behaviour the description cites (specifier-based .stylex detection, constants resolved only from definitions the app compiled, defineConsts throwing uncompiled, per-layer values resolving on :root). Verified.
  • Claim: the writing rubric results R1 to R7 hold for the added record text. Verified.
  • Claim: the new test, the source-build test and the knowledge check pass. Verified.
  • Claim: all listed pull requests but #8095 edit other parts of the record, and #8095's current head no longer changes it. Verified at their current heads.
  • Claim: none of them edits the paragraph, entry or row this one adds. Verified by test merges.
  • Claim: all but #8485 merge cleanly with this change in the record, and #8485 already conflicts with main there. Verified by test merges.
  • Claim: none touches Layer/layerViewportInset.stylex.ts or the new test, and #12307 adds a case to layerViewportInset.source-build.test.mjs. Verified.
  • Claim: the land path covers records and a test only. Verified.
  • File docs/architecture/layer-runtime.md: clear.
  • File packages/core/src/Layer/layerViewportInset.consumer-build.test.mjs: clear.

Automated review (maintainer link)

…pr12314

# Conflicts:
#	docs/architecture/layer-runtime.md
@github-actions github-actions Bot added the needs:spec-owner-review Current knowledge records await owner approval label Nov 21, 2026
@cixzhang

Copy link
Copy Markdown
Contributor Author

/approve-spec a59d8ce

@github-actions github-actions Bot removed the needs:spec-owner-review Current knowledge records await owner approval label Nov 21, 2026

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the record paragraph, its verification row and the new test are correct and agree at this head; one claim in the description's overlap note is not true for the current heads of the pull requests it lists.

  • Regression: the overlap note says all but #8485 merge cleanly with this change in docs/architecture/layer-runtime.md, but #8125, #8133, #8201 and #9816 also conflict with main there (and so with this change), and #11112, #11894 and #12307 have landed, so please restate that clause for the current heads or drop the overlap note.
Claims and files checked

Review mode: same-head; reason: none

  • Changed rules (0): none.
  • Claim: a StyleX build outside Core that resolves the module to its built file reads the gutter and caps as variables Core's stylesheet does not define, so the declaration is invalid. Verified by the new test (three undefined references).
  • Claim: a swizzled layer component imports the module by its published path. Verified in the swizzle module graph, which keeps a StyleX module on its exported path.
  • Claim: a build that compiles the published source entry defines them. Verified: compiled in the app's own build, all three constants are inlined.
  • Claim: the pull request records the gap under INV11, adds a test that asserts it, and changes no behavior. Verified: the record diff is additions only and the test ships in no package.
  • Claim: the record gains a Current gaps paragraph, a verified_by entry and an "INV11 gap" verification row. Verified.
  • Claim: the test builds the entry as Core publishes it, compiles an app file that reads the three constants with the app's own StyleX, and asserts that the three variables it references are ones Core's stylesheet does not define. Verified.
  • Claim: the test fails when the gap closes and when its harness breaks. Verified with a copy that compiles the source entry and a copy whose alias points at a missing file.
  • Claim: the StyleX behaviour the description cites (specifier-based .stylex detection, constants resolved only from definitions the app compiled, defineConsts throwing uncompiled, per-layer values resolving on :root). Verified.
  • Claim: the writing rubric results R1 to R7 hold for the added record text. Verified.
  • Claim: the new test, the source-build test and the knowledge check pass. Verified at this head.
  • Claim: all listed pull requests but #8095 edit other parts of the record, and #8095's current head no longer changes it. Verified at their current heads.
  • Claim: none of them edits the paragraph, entry or row this one adds. Verified by test merges.
  • Claim: all but #8485 merge cleanly with this change in the record, and #8485 already conflicts with main there. False: #8125, #8133, #8201 and #9816 also conflict with main there, and #11112, #11894 and #12307 have landed.
  • Claim: none touches Layer/layerViewportInset.stylex.ts or the new test, and #12307 adds a case to layerViewportInset.source-build.test.mjs. Verified.
  • Claim: the land path covers records and a test only. Verified.
  • File docs/architecture/layer-runtime.md: clear; the finding concerns the description's note about it.
  • File packages/core/src/Layer/layerViewportInset.consumer-build.test.mjs: clear.

Automated review (maintainer link)

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: CI is still running on this head, and test-node (4/9) failed on a 30-second timeout in packages/cli/api/render/render.interactive.test.mjs, a CLI render test this pull request does not change; please re-run that job, since the merge guard requires every required check to pass.

The record paragraph, its verification row and the new test agree, and the overlap note still holds for the current heads of every pull request it lists against the current main.

Claims and files checked

Review mode: same-head; reason: none

  • Changed rules (0): none.
  • Claim: a StyleX build outside Core that resolves the module to its built file reads the gutter and caps as variables Core's stylesheet does not define, so the declaration is invalid. Verified by the new test (three undefined references).
  • Claim: a swizzled layer component imports the module by that path. Verified in the swizzle module graph, which keeps a StyleX module on its exported path.
  • Claim: a build that compiles the published source entry defines them. Verified: compiled in the app's own build, every constant is inlined.
  • Claim: the pull request records the gap under INV11, adds a test that asserts it, and changes no behavior. Verified: the record diff is additions only and the test ships in no package.
  • Claim: the record gains a Current gaps paragraph, a verified_by entry and an "INV11 gap" verification row. Verified.
  • Claim: the test builds the entry as Core publishes it, compiles an app file that reads the three constants with the app's own StyleX, and asserts that the three variables it references are ones Core's stylesheet does not define. Verified.
  • Claim: the test fails when the gap closes and when its harness breaks. Verified with a copy whose app build compiles the source entry and a copy whose alias names a missing file.
  • Claim: StyleX detects a .stylex import from its specifier, resolves constants only from definitions it compiled, throws on an uncompiled defineConsts, and definitions on :root would resolve per-layer values at the root. Verified in the StyleX compiler and runtime and by custom-property semantics.
  • Claim: the writing rubric results R1 to R7 hold for the added record text. Verified.
  • Claim: the new test, the source-build test and the knowledge check pass. Verified at this head.
  • Claim: the open listed pull requests other than #8095 edit other parts of the record, and #8095 no longer changes it. Verified at their current heads.
  • Claim: none of them edits the paragraph, entry or row this one adds. Verified by test merges against the current main and this head.
  • Claim: #12179, #11859, #10126, #10124, #10095, #8217, #8084 and #8080 merge cleanly with main and with this change in the record. Verified.
  • Claim: #9816, #8485, #8201, #8133 and #8125 already conflict with main there, and so with this change. Verified: the same conflicts with and without this change.
  • Claim: #11112 and #11894 have merged and #12307 is closed. Verified.
  • Claim: none of them touches the viewport inset module or the new test. Verified.
  • Claim: the land path covers records and a test only. Verified.
  • File docs/architecture/layer-runtime.md: clear.
  • File packages/core/src/Layer/layerViewportInset.consumer-build.test.mjs: clear.

Automated review (maintainer link)

@cixzhang
cixzhang marked this pull request as ready for review November 21, 2026 06:12
@cixzhang
cixzhang marked this pull request as draft November 21, 2026 06:59
@cixzhang

Copy link
Copy Markdown
Contributor Author

/approve-spec 90c6163

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: CI has not run on this head because the pull request is a draft again; it runs once the pull request is marked ready for review, and the merge guard requires it to pass.

This head only merges main and leaves this pull request's own changes as they were: the record paragraph, its verification row and the new test agree, and the overlap note still holds against the current main.

Claims and files checked

Review mode: carry-forward; reason: none

  • Changed rules (0): none.
  • Claim: a StyleX build outside Core that resolves the module to its built file reads the gutter and caps as variables Core's stylesheet does not define, so the declaration is invalid. Verified by the new test (three undefined references).
  • Claim: a swizzled layer component imports the module by that path. Verified in the swizzle module graph, which keeps a StyleX module on its exported path.
  • Claim: a build that compiles the published source entry defines them. Verified: compiled in the app's own build, every constant is inlined.
  • Claim: the pull request records the gap under INV11, adds a test that asserts it, and changes no behavior. Verified: the record diff is additions only and the test ships in no package.
  • Claim: the record gains a Current gaps paragraph, a verified_by entry and an "INV11 gap" verification row. Verified.
  • Claim: the test builds the entry as Core publishes it, compiles an app file that reads the three constants with the app's own StyleX, and asserts that the three variables it references are ones Core's stylesheet does not define. Verified.
  • Claim: the test fails when the gap closes and when its harness breaks. Verified with a copy whose app build compiles the source entry and a copy whose alias names a missing file.
  • Claim: StyleX detects a .stylex import from its specifier, resolves constants only from definitions it compiled, throws on an uncompiled defineConsts, and definitions on :root would resolve per-layer values at the root. Verified in the StyleX compiler and runtime and by custom-property semantics.
  • Claim: the writing rubric results R1 to R7 hold for the added record text. Verified.
  • Claim: the new test, the source-build test and the knowledge check pass. Verified on the same patch; nothing they read changed in the merge of main.
  • Claim: the open listed pull requests other than #8095 edit other parts of the record, and #8095 no longer changes it. Verified at their current heads.
  • Claim: none of them edits the paragraph, entry or row this one adds. Verified by test merges against the current main and this head.
  • Claim: #12179, #11859, #10126, #10124, #10095, #8217, #8084 and #8080 merge cleanly with main and with this change in the record. Verified.
  • Claim: #9816, #8485, #8201, #8133 and #8125 already conflict with main there, and so with this change. Verified: the same conflicts with and without this change.
  • Claim: #11112 and #11894 have merged and #12307 is closed. Verified.
  • Claim: none of them touches the viewport inset module or the new test. Verified.
  • Claim: the land path covers records and a test only. Verified.
  • File docs/architecture/layer-runtime.md: clear.
  • File packages/core/src/Layer/layerViewportInset.consumer-build.test.mjs: clear.

Automated review (maintainer link)

@cixzhang

Copy link
Copy Markdown
Contributor Author

/approve-spec 1fe6277

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved: CI passed on this head.

The record paragraph, its verification row and the new test agree, the new test passes in CI on this head, and the overlap note still holds against the current main.

Claims and files checked

Review mode: same-head; reason: none

  • Changed rules (0): none.
  • Claim: a StyleX build outside Core that resolves the module to its built file reads the gutter and caps as variables Core's stylesheet does not define, so the declaration is invalid. Verified by the new test (three undefined references), which passes in CI on this head.
  • Claim: a swizzled layer component imports the module by that path. Verified in the swizzle module graph, which keeps a StyleX module on its exported path.
  • Claim: a build that compiles the published source entry defines them. Verified: compiled in the app's own build, every constant is inlined.
  • Claim: the pull request records the gap under INV11, adds a test that asserts it, and changes no behavior. Verified: the record diff is additions only and the test ships in no package.
  • Claim: the record gains a Current gaps paragraph, a verified_by entry and an "INV11 gap" verification row. Verified.
  • Claim: the test builds the entry as Core publishes it, compiles an app file that reads the three constants with the app's own StyleX, and asserts that the three variables it references are ones Core's stylesheet does not define. Verified.
  • Claim: the test fails when the gap closes and when its harness breaks. Verified with a copy whose app build compiles the source entry and a copy whose alias names a missing file.
  • Claim: StyleX detects a .stylex import from its specifier, resolves constants only from definitions it compiled, throws on an uncompiled defineConsts, and definitions on :root would resolve per-layer values at the root. Verified in the StyleX compiler and runtime and by custom-property semantics.
  • Claim: the writing rubric results R1 to R7 hold for the added record text. Verified.
  • Claim: the new test, the source-build test and the knowledge check pass. Verified: both tests pass in CI on this head, and the knowledge check passes at this head.
  • Claim: the open listed pull requests other than #8095 edit other parts of the record, and #8095 no longer changes it. Verified at their current heads.
  • Claim: none of them edits the paragraph, entry or row this one adds. Verified by test merges against the current main and this head.
  • Claim: #12179, #11859, #10126, #10124, #10095, #8217, #8084 and #8080 merge cleanly with main and with this change in the record. Verified, including the new heads of #11859 and #8080.
  • Claim: #9816, #8485, #8201, #8133 and #8125 already conflict with main there, and so with this change. Verified: the same conflicts with and without this change.
  • Claim: #11112 and #11894 have merged and #12307 is closed. Verified.
  • Claim: none of them touches the viewport inset module or the new test. Verified.
  • Claim: the land path covers records and a test only. Verified.
  • File docs/architecture/layer-runtime.md: clear.
  • File packages/core/src/Layer/layerViewportInset.consumer-build.test.mjs: clear.

Automated review (maintainer link)

@cixzhang
cixzhang marked this pull request as ready for review November 21, 2026 14:14
@cixzhang
cixzhang merged commit 6dfc0b6 into main Nov 21, 2026
151 checks passed
@github-actions
github-actions Bot deleted the lane4/layer-viewport-inset-consumer branch November 22, 2026 06:04

This branch was successfully deployed

1 active deployment
Preview — 1fe6277e Deployed Nov 21, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot. lane:4 Astryx fix-loop lane 4 owns this

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant