mirror of
https://github.com/microsoft/playwright.git
synced 2025-06-26 21:40:17 +00:00

This is fixing a case where the test failed with strict mode violation, but all the matched elements are not highlighted in the trace. For example, all the buttons will be highlighted when the following line fails due to strict mode violation: ```ts await page.locator('button').click(); ``` To achieve this, we mark elements during `querySelector` phase instead of inside `onBeforeInputAction`. This allows us to only mark from inside the `InjectedScript` and remove the other way of marking from inside the `Snapshotter`.