Share prepared layout with CSSOM

This commit is contained in:
SGavrl committed 2026-07-30 22:08:01 +00:00
1 parent 6d4ce11aa1
commit 5057715358
3 files changed
+242 -76

No files matched your search

+7
View File
@@ -1790,6 +1790,13 @@ impl Page {
// the overwhelming majority of real markup.
let base_url = self.resolve_base_url();
let base_url = base_url.as_ref().map(|u| u.as_str());
if let Some(js) = &self.js {
if let Some(png) = js.screenshot_prepared(viewport, base_url) {
return Some(png);
}
}
// Compatibility path for a page without a JS runtime or an ad-hoc
// viewport/base that does not match the runtime's CSSOM render key.
let scroll = self
.js
.as_ref()