9424 shaares
229 private links
229 private links
border-radius: max(0px, min(8px, calc((100vw - 4px - 100%) * 9999)));
→ maybe too clever as the line is hard to understand.
and
grid-template-columns: repeat(auto-fit, minmax(min(350px, 100%), 1fr));
This is a great snippet, but there is absolutely zero chance I’m going to remember how to write it every time.
Another trick is to use a toggle value stored in a css variable.