css calc() function returns 0 on height attribute with percentage
Categories
(Core :: CSS Parsing and Computation, defect)
Tracking
()
People
(Reporter: matthieu.xillo, Unassigned)
Details
Attachments
(1 file)
77.22 KB,
application/zip
|
Details |
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Firefox/68.0
Steps to reproduce:
Just load the following HTML code:
<html><head></head><body><div style="background-color: #F00;width: 100%;height: 100%;height: calc(100% - 50px);"></div></body></html>
Actual results:
The div doesn't appear, because its height is equal to 0.
Expected results:
The div should appear, with the right height.
The width attribute doesn't have this issue. Strange.
Reporter | ||
Updated•5 years ago
|
Reporter | ||
Comment 1•5 years ago
|
||
Actually, using vh instead of % seems to work well.
Comment 2•5 years ago
|
||
Hi Matthieu,
i have managed to reproduce the bug also on windows on release version(ie shows div correctly ). I will assign a component in order to make it verified by a developer.
Regards
David
Updated•5 years ago
|
Comment 3•5 years ago
|
||
This is only on quirks mode, and it's a WebKit/Chromium quirk. If you add <!doctype html>
, then Chromium and Firefox behave the same.
So this is ~invalid, we track the Chromium interop issue in bug 1259924.
Description
•