max-height-valid.html (1239B)
1 <!DOCTYPE html> 2 <html> 3 <head> 4 <meta charset="utf-8"> 5 <title>CSS basic box model: parsing max-height with valid values</title> 6 <link rel="author" title="Eric Willigers" href="mailto:ericwilligers@chromium.org"> 7 <link rel="help" href="https://drafts.csswg.org/css-box-3/#propdef-max-height"> 8 <meta name="assert" content="max-height supports the full grammar '[ [<length> | <percentage>] && [border-box | content-box]? ] | available | min-content | max-content | fit-content | none'."> 9 <script src="/resources/testharness.js"></script> 10 <script src="/resources/testharnessreport.js"></script> 11 <script src="/css/support/parsing-testcommon.js"></script> 12 </head> 13 <body> 14 <script> 15 test_valid_value("max-height", "none"); 16 17 test_valid_value("max-height", "10px"); 18 test_valid_value("max-height", "20%"); 19 test_valid_value("max-height", "calc(2em + 3ex)"); 20 21 test_valid_value("max-height", "min-content"); 22 test_valid_value("max-height", "max-content"); 23 test_valid_value("max-height", "fit-content"); 24 25 // The following are not yet supported by browsers: 26 // test_valid_value("max-height", "available"); 27 // test_valid_value("max-height", "10px border-box"); 28 // test_valid_value("max-height", "content-box 20%", "20% content-box"); 29 </script> 30 </body> 31 </html>