summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/css/css-ui/accent-color-invalidation-currentcolor.html
blob: 804e8544b8990333d62a13b1a9850c69282247cc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<!DOCTYPE html>
<html class="reftest-wait">
<link rel=help href="https://bugs.chromium.org/p/chromium/issues/detail?id=1225661">
<link rel=author href="mailto:jarhar@chromium.org">
<link rel=match href="accent-color-invalidation-currentcolor-ref.html">

<div style="accent-color: currentColor">
  The following checkbox should be red: <input type=checkbox checked>
</div>

<script>
async function rAF() {
  return new Promise(resolve => requestAnimationFrame(resolve));
}

(async () => {
  await rAF();
  await rAF();
  document.querySelector('input').style = 'color: red';
  await rAF();
  await rAF();
  document.documentElement.classList.remove('reftest-wait');
})();
</script>