Skip to content

Map iframe/embed/video width/height attributes to CSS dimension properties - #609

Merged
nicoburns merged 2 commits into
mainfrom
devin/1785860000-embedded-dimension-attrs
Aug 4, 2026
Merged

Map iframe/embed/video width/height attributes to CSS dimension properties#609
nicoburns merged 2 commits into
mainfrom
devin/1785860000-embedded-dimension-attrs

Conversation

@nicoburns

@nicoburns nicoburns commented Aug 4, 2026

Copy link
Copy Markdown
Member

Summary

Follow-up to #607 (companion to the abspos static-position fix in #608).

Per HTML rendering, the width/height attributes on iframe, embed and video map to the corresponding CSS dimension properties, including percentages (<iframe height="50%">). Previously they were only consumed as pixel intrinsic sizes in the replaced layout path, so percentage values were ignored. This adds the mapping in synthesize_presentational_hints_for_legacy_attributes (same pattern as the existing table/svg dimension mappings).

WPT results

Newly passing vs main (no regressions in css-flexbox, css/CSS2/normal-flow, css/CSS2/positioning):

  • css/CSS2/positioning/absolute-replaced-height-005/007/012/014/019/026/033.xht

Together with #608 this also fixes inline-replaced-height-005.xht and inline-block-replaced-height-005.xht.

Link to Devin session: https://app.devin.ai/sessions/0f8547b7fbb949e28e9acdbedb1ca8d2
Requested by: @nicoburns

WPT results

10 newly passing, 0 newly failing (net +10).

Full diff (10 changed tests)
+ Fail => Pass css/CSS2/floats-clear/float-replaced-height-005.xht
+ Fail => Pass css/CSS2/normal-flow/inline-block-replaced-height-005.xht
+ Fail => Pass css/CSS2/normal-flow/inline-replaced-height-005.xht
+ Fail => Pass css/CSS2/positioning/absolute-replaced-height-005.xht
+ Fail => Pass css/CSS2/positioning/absolute-replaced-height-007.xht
+ Fail => Pass css/CSS2/positioning/absolute-replaced-height-012.xht
+ Fail => Pass css/CSS2/positioning/absolute-replaced-height-014.xht
+ Fail => Pass css/CSS2/positioning/absolute-replaced-height-019.xht
+ Fail => Pass css/CSS2/positioning/absolute-replaced-height-026.xht
+ Fail => Pass css/CSS2/positioning/absolute-replaced-height-033.xht

Generated by the WPT workflow.

@nicoburns nicoburns self-assigned this Aug 4, 2026
@devin-ai-integration

Copy link
Copy Markdown
Contributor

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR that start with 'DevinAI' or '@devin'.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment, CI, and merge conflict monitoring

@devin-ai-integration
devin-ai-integration Bot force-pushed the devin/1785860000-embedded-dimension-attrs branch from 6d05cd2 to d40dc98 Compare August 4, 2026 16:40
@nicoburns
nicoburns marked this pull request as ready for review August 4, 2026 16:40
@nicoburns
nicoburns merged commit e6885a6 into main Aug 4, 2026
15 checks passed
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