10 transition-property: fill, stroke;
11 transition-duration:
1000s;
12 transition-timing-function: steps(
2, start);
21 fill: rgb(
128,
128,
0);
22 stroke: rgb(
128,
128,
0);
27 <svg width=
"204" height=
"100">
28 <rect class=
"expected" x=
"2" y=
"2" stroke-width=
"2" width=
"96" height=
"96"/>
29 <rect class=
"expected" x=
"106" y=
"2" stroke-width=
"2" width=
"96" height=
"96"/>
33 <!-- Normal paint style transition. -->
34 <a href=
"//unvisited.website">
35 <svg width=
"100" height=
"100">
36 <rect class=
"target" id=
"rectA" x=
"2" y=
"2" stroke-width=
"2" width=
"96" height=
"96"/>
39 <!-- Visited link paint style transition. -->
41 <svg width=
"100" height=
"100">
42 <rect class=
"target" id=
"rectB" x=
"2" y=
"2" stroke-width=
"2" width=
"96" height=
"96"/>
47 document
.getElementsByTagName("a")[1].offsetTop
; // Force application of initial style.
48 requestAnimationFrame(function() {
49 rectA
.classList
.add('active');
50 rectB
.classList
.add('active');