关于calc的踩坑

it2025-05-28  7

错误写法: margin-right: calc((100%-4.26rem*4)/3);

正确写法 margin-right: calc((100% - 4*4.26rem)/3);

单位要写在后面, 不然计算不出正确的结果

最新回复(0)