transform:rotate()
时间: 2023-10-16 18:25:25 浏览: 128
css3的transform造成z-index无效解决方案
`transform:rotate()` is a CSS property that allows you to rotate an element by a certain degree. The degree value can be positive or negative, and can be specified in degrees, radians, or gradians.
For example, the following code will rotate an element by 45 degrees:
```
.rotate {
transform: rotate(45deg);
}
```
You can also use other transform functions in conjunction with `rotate()`, such as `scale()` and `translate()`, to create more complex transformations.
阅读全文