使用jQueryUI Accordionfunction的Scrollspy

所以我已经设法弄清楚如何使用scrolllspy,但是我没有意识到我的目录对于导航来说太长了。 我想知道如何添加手风琴类型的function,以便我的导航栏目录在滚动后传递关联的锚点时会崩溃。 我基本上是在寻找与bootstrap网站相同的function,因为它附带了侧边栏。 我已经看过这个: 使用bootstrap scrollspy作为崩溃的div,到一个附加的侧边栏但是我不确定这是否与我正在寻找的东西相同。 我也考虑过使用Greg Franko编写的TOCIFY插件,但我不确定如何实现它。 我一直在阅读TOCIFY文档,但我不确定它是什么我必须改变。

目前我的scrollspyfunction正在使用此设置:

 

Executive Summary

Introduction & Background

Mount Royal University (MRU) has a long-standing history of student-centered leadership and learning. We are known to be an institution that cares about the success and the health of our students, and we have strong services that support mental health promotion and respond well to mental health issues and concerns. In addition to excellent service providers, MRU has many positive practices and policies in place to support students.  Recent trends suggest that the prevalence of mental health issues is on the rise among young adults. More students are entering into university with pre-existing mental health conditions, more are seeking help, and often issues are complex and multifaceted.  Given that rates of mental illness are on the rise, and given that our student population has reported stress levels higher than other students at post-secondary institutions in North American, a review of our student mental health practices and procedures was warranted.

你可以在这里看到它: https : //googledrive.com/host/0BwvPQbnPrz_LTlBjelIwemxaZzg/index.html

如有任何帮助或建议,我将不胜感激。 如果我的研究不够广泛并且已经得到回答,我会道歉。