css - transform-origin 旋转参考点
大家讲道理
大家讲道理 2017-04-17 11:52:28
0
2
732

有A,B两个p,如何实现A以B 为中心做rotate 呢?
我看transform-origin,只能以自己为参考点坐旋转

大家讲道理
大家讲道理

光阴似箭催人老,日月如移越少年。

reply all(2)
巴扎黑

I have a hunch that you will definitely fall into a trap in the future, because the effect you create with rotate is probably not what you actually want.
I suggest you read this article. What you want should be the effect mentioned in this article: http://m.open-open.com/m/lib/...

大家讲道理

Just change the current transform-origin position of A to the position of the center point of B. You can think of it as rotating with B as the center. If you take B away, it will still follow B The original position is centered and rotated

You can often just change your thinking. transform-origin is just the position and has nothing to do with other elements

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template