JSFiddle - React, Tailwind, and code Playground

HTML

<div id=a>specified: brightness(0.5)</div>
<div id=b>specified: brightness(50%)</div>

CSS

div {
  background: blue;
  color: white;
  margin: 1em;
  padding: 1em;
}
#a {
  filter: brightness(0.5);
}
#b {
  filter: brightness(50%);
}

JavaScript

[ a, b ].forEach(div => {
  div.innerText += `\ncomputed: ${getComputedStyle(div).filter}`;
})