今天爱分享给大家带来transform 中含有 position: fixed 失效的问题解决,希望能够帮助到大家。
话不多说,直接上代码!!!
原代码是这样的
.down-icon {
width: .27rem;
height: 0.27rem;
border-top: .02rem solid #6D3942;
border-left: .02rem solid #6D3942;
transform: rotate(45deg);
position: fixed;
left: 0;
bottom: 0.4rem;
left: 0;
right: 0;
margin: auto;
}
结果没有任何反应,其中的transform: rotate(45deg);并没有管用
解决办法:
将position: fixed;放在父元素内,添加一个子元素transform: rotate(45deg);放在子元素内
.down-icon {
width: .27rem;
height: 0.27rem;
position: fixed;
left: 0;
bottom: 0.4rem;
left: 0;
right: 0;
margin: auto;
i{
display: block;
width: 100%;
height: 100%;
border-top: .02rem solid #6D3942;
border-left: .02rem solid #6D3942;
transform: rotate(45deg);
}
}
此时效果可以实现
原文链接:https://blog.itblood.com/460.html,转载请注明出处。

![SuccubusHeaven 淫魔天堂 V20250208 官方中文版+全回想[更新/追加内容] (サキュバスヘヴン) [大作ACT/中文/全动态]](/wp-content/uploads/replace/2025/07/19/84acaa3eec2ac839819c1d6623a8cc78.webp)