Bug 218895
| Summary: | Opacity doesn't work on picture element if child img is display block | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | James Long <jameslong> |
| Component: | Images | Assignee: | Nobody <webkit-unassigned> |
| Status: | NEW | ||
| Severity: | Normal | CC: | koivisto, sabouhallawa, simon.fraser, smoley, webkit-bug-importer, zalan |
| Priority: | P2 | Keywords: | InRadar |
| Version: | WebKit Nightly Build | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| See Also: | https://bugs.webkit.org/show_bug.cgi?id=287407 | ||
James Long
If a picture element is given an opacity, the opacity is applied. However, if the picture element has a child img element that has display:block, the opacity isn't honoured unless the picture element has display:block as well.
Expected behaviour: the opacity should be applied even with a display:block child.
This affects Opera, Chrome and the latest version of Edge. It doesn't affect pre-webkit Edge and it doesn't affect Firefox.
You can see this bug in this fiddle: https://jsfiddle.net/Skateside/k6zbeq1j/
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Alexey Proskuryakov
The report doesn't explicitly mention WebKit, but I can reproduce in Safari indeed.
Changing a behavior where we match Chrome can have negative compatibility effect of course.
Radar WebKit Bug Importer
<rdar://problem/71545258>