autoprefixer icon indicating copy to clipboard operation
autoprefixer copied to clipboard

feat: add `dppx` when the browser does not support the `x` unit in resolution media queries

Open yisibl opened this issue 3 years ago • 2 comments

css-values-4 adds x as an alias for dppx unit, but not every browser in media queries supports x unit. So I think it would be better to add a fallback for x unit.

x unit support in: Chrome 68+, Edge 79+, Opera 55+, Safari 16+, Firefox 62+

See also:

  • https://chromestatus.com/feature/5150549246738432
  • https://developer.mozilla.org/en-US/docs/Web/CSS/resolution#browser_compatibility
  • Caniuse PR: https://github.com/Fyrd/caniuse/pull/6381
image

yisibl avatar Jul 16 '22 11:07 yisibl

I have added a PR of x unit for caniuse as well. https://github.com/Fyrd/caniuse/pull/6381

yisibl avatar Jul 17 '22 12:07 yisibl