“爆炸” Jquery效果只显示左侧

发布于 2024-12-16 19:42:27 字数 618 浏览 5 评论 0原文

我有一个 jQuery UI 手风琴,我试图使用 JQuery 效果在单击时“爆炸”。由于某种原因,效果仅显示在左侧。有什么想法吗?

$(this).effect('explode', { pieces: '50' }, 800);

另外,我目前正在以 200px 的固定高度对“ui.newContent”的高度进行动画处理,如下所示:

ui.newContent.delay(000).animate({ height: 200,'padding-top': 20,'padding-bottom': 20}, 700);

但我需要的是能够对每个内容 div 的“自然”完整高度进行动画处理。

我尝试使用:

var fullHeight = $(this).height()

但我无法让它工作。

这是一个现场演示: http://jsfiddle.net/ifthatdoesntdoit/Cb68E/10/

谢谢

I have a jQuery UI Accordion that I am attempting to 'Explode' on click using the JQuery effect. For some reason the effect only shows to the left. Any ideas?

$(this).effect('explode', { pieces: '50' }, 800);

Also, I am currently animating the height of the 'ui.newContent' at a fixed height of 200px as follows:

ui.newContent.delay(000).animate({ height: 200,'padding-top': 20,'padding-bottom': 20}, 700);

but what I need is to be able to animate the 'natural' full height of each content div.

I tried using:

var fullHeight = $(this).height()

but I wasn't able to get it working.

Here's a live demo: http://jsfiddle.net/ifthatdoesntdoit/Cb68E/10/

Thanks

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文