开发者

jquery fade in adding inline style to span

开发者 https://www.devze.com 2023-04-05 22:02 出处:网络
When using the fadeIn for a hidden span element, jquery adds display:inline to the inline styles. I understand why it does this because by default a span is a inline element although how do I set it t

When using the fadeIn for a hidden span element, jquery adds display:inline to the inline styles. I understand why it does this because by default a span is a inline element although how do I set it to always display:block;

I have to use a <span> because:


You can use .animate() instead of .fadeIn(), which (I think) won't change the display property while animating.

0

精彩评论

暂无评论...
验证码 换一张
取 消