我已经在What We Do下实现了此手风琴脚本
我需要向每个导航项添加上下箭头,如this pic中所示。我在哪里以及如何将两种状态(无效箭头和有效箭头)编码到jQuery中。我以为我需要将此代码编码到jQuery中?
最佳答案
您可以使用一些简单的CSS类来完成此操作,因为a
在打开时具有不同的类:toggler toggler-closed
和toggler toggler-opened
.toggler.toggler-opened {
/* a background image on the right side with arrow down? */
}
.toggler.toggler-closed {
/* a background image on the right side with arrow to the right? */
}