CSS rgba Background color checking

I found a strange CSS check result: when rgba()used for background, it does not check, however a workaround rgba()for background-color. Why does this rule exist? Is this a validation error?

Try to confirm the following there , and you can see the result:

div {
   background: rgba(0, 0, 0, 0.5);
}

and

div {
   background-color: rgba(0, 0, 0, 0.5);
}
+5
source share
1 answer

I think this is a validation error. For example, the HSL color space is also rejected.

.accepted {
   background-color: hsl(1, 1%, 1%);
}

.rejected {
   background: hsl(1, 1%, 1%);
}
+1
source

All Articles