Open
Description
Basic info:
- Node.js version: 14.17
- jsdom version: 18.0.0
Minimal reproduction case
The following code returns repeat(auto-fill, 300px)
instead of 300px 300px
as described in the CSS Grid spec (Note below example 19): https://www.w3.org/TR/css-grid-1/.
const { JSDOM } = require("jsdom");
const dom = new JSDOM(`
<!DOCTYPE html>
<html>
<head>
<title></title>
<style>
#gridParentElement {
width: 700px;
display: grid;
grid-template-columns: repeat(auto-fill, 300px);
}
</style>
</head>
<body>
<div id="gridParentElement">
<div class="gridChild"></div>
<div class="gridChild"></div>
</div>
</body>
</html>
`);
const element = window.document.querySelector("#gridParentElement");
console.log(window.getComputedStyle(element).gridTemplateColumns);
How does similar code behave in browsers?
In browser, the returned value should be 300px 300px
. Link to reproducible case:
Metadata
Metadata
Assignees
Labels
No labels