keyword
auto-fill — CSS reference
Repeats as many eligible tracks as fit the definite available space, retaining empty repeated tracks. Gaps count toward the space budget.
Formal Syntax & Structure
css syntaxcss
repeat(auto-fill, minmax(100px, 1fr))Working Example
Example Snippetcss
<!doctype html><html lang="en"><meta charset="utf-8"><title>auto-fill</title><style>body{margin:0}#g{display:grid;width:300px;grid-template-columns:repeat(auto-fill,minmax(100px,1fr));}#g>*{background:#146e73;color:white;box-sizing:border-box}#b{background:#345d8e}#c{background:#79518e}</style><body><div id="g"><div id="a">A</div></div></body></html>