Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I wish percentages in CSS were more explicit:

  #foobar {
    width: 100% of container width;
    height: 100% of contents height;
  }


This exists, you can specify containers and then use 100cqw container query length percentage units https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_contain...


Same idea I had when commenting - this just needs some good old explicit reference (can be optional)!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: