animation2code benchmark
For best compatibility, please view this dashboard in a Chrome browser.
← back to Only CSS: Joint Animation

model output

Claude Sonnet 4.6

Only CSS: Joint Animation

A 0.85T 0.33
compare with ground truth →
1<!DOCTYPE html>
2<html lang="en">
3<head>
4<meta charset="UTF-8">
5<meta name="viewport" content="width=device-width, initial-scale=1.0">
6<title>Rotating Rectangle</title>
7<style>
8  * {
9    margin: 0;
10    padding: 0;
11    box-sizing: border-box;
12  }
13
14  body {
15    width: 1024px;
16    height: 768px;
17    background: #ffffff;
18    display: flex;
19    align-items: center;
20    justify-content: center;
21    overflow: hidden;
22  }
23
24  .container {
25    position: relative;
26    width: 290px;
27    height: 70px;
28    display: flex;
29    align-items: center;
30    justify-content: center;
31    animation: rotate 2s linear infinite;
32  }
33
34  .rectangle {
35    position: absolute;
36    width: 290px;
37    height: 70px;
38    background-color: #4aabdb;
39    border-radius: 2px;
40  }
41
42  .dot {
43    position: absolute;
44    width: 14px;
45    height: 14px;
46    background: radial-gradient(circle at 40% 35%, #ffd700, #f5a623);
47    border-radius: 50%;
48    z-index: 2;
49  }
50
51  @keyframes rotate {
52    0% {
53      transform: rotate(0deg);
54    }
55    100% {
56      transform: rotate(360deg);
57    }
58  }
59</style>
60</head>
61<body>
62  <div class="container">
63    <div class="rectangle"></div>
64    <div class="dot"></div>
65  </div>
66</body>
67</html>