Skip to content

test: check the chrome root sits at the document origin instead of staying static - #5507

Merged
leaf-agent merged 1 commit into
mainfrom
fix/issue-5475-aim-test
Nov 5, 2026
Merged

leaf-agent merged 1 commit into
mainfrom
fix/issue-5475-aim-test

Conversation

@leaf-agent

Copy link
Copy Markdown
Collaborator

test_an_aimed_comment_keeps_its_place_with_on_me_open asserts that Leaf's interface root (.lf-chrome) stays position: static, so an authored div { position: relative } can't capture its coordinate plane. #5228 deliberately made that root position: absolute at the document origin, at the largest z-index, as html's last child (browser/base.css, :root > .lf-chrome), so the assertion fails on main for both widths even though the plane hasn't moved.

The test now reads what it protects: the root's box, plus the scroll offset, sits at [0, 0] while the page sets a margin and border on html and positions every div. The root and body static assertions and the composer placement checks are unchanged. No product code changes.

tests/browser/test_render_aim.py::test_an_aimed_comment_keeps_its_place_with_on_me_open[900] and [1200] failed on main and pass with this change.

Refs #5475 — automated triage

…position

#5228 made Leaf's interface root `position: absolute` at the document's
origin (`base.css`, `:root > .lf-chrome`), so the aim test's assertion that
it stays `static` fails on main. What the test protects is that an authored
`div { position: relative }` and a margin and border on `html` can't move the
chrome's document coordinate plane; it now asserts the root's box sits at the
document origin.

Refs #5475
@leaf-agent
leaf-agent merged commit 803f36a into main Nov 5, 2026
5 checks passed
@leaf-agent
leaf-agent deleted the fix/issue-5475-aim-test branch November 5, 2026 17:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant