Can't change box shadow distance unit type

I can’t change the box shadow distance unit type. The option to change it from “px” is grayed out. I am not able to select any other unit type (ONLY for “distance”). I have tried typing in the box, “20vw” or “20%” to no avail.

This question has been asked before and was closed before a solution was found.


Here is my site Read-Only: LINK
(how to share your site Read-Only link)

According to W3C spec on box-shadow , it only accept Distance Unit type <length> as the value.

While <percentage> is a sub type of Numeric Data Types , not part of <length> . See W3C spec on Values and Units .

original post

This is IMO the best answer you can get but there are many other resources if you look around and want do dive deep into W3C specs to have discussion why. There are another ways to achieve this underlines as using pseudo classes :before and/or :after etc…

Hi @adam1 if you don’t have further question related to this topic feel free to close your request as solved.

Good to know, thanks!

1 Like