cuny-academic-commons / cbox-theme

Default theme for Commons In A Box
GNU General Public License v2.0
20 stars 15 forks source link

Prevent JS error after joyride completion #235

Closed christianwach closed 8 years ago

christianwach commented 9 years ago

The cbox theme uses a rather old version of jQuery Joyride, but upgrading to the latest would be a fair bit of effort. This PR solves an issue where, after joyride completion, a DOM element $('#joyRidePopup' + prevCount) cannot be found, thus throwing a JS error. For some, this means that the Activity filter links in the sidebar no longer work because they are AJAX-driven.

christianwach commented 8 years ago

Bump. Anyone found this to be the case? The PR works for me.

MrMaz commented 8 years ago

Sort of off topic, but... Infinity 2.0 is pretty much done (it was a massive overhaul to move all options to the theme customizer and full responsive, etc). I ended up dropping joyride because of seemingly random errors I couldn't track down. They stopped maintaining the standalone version, the last commit was over 2 years ago.

Infinity 2.0 is based on Foundation 5, which has the option to bundle joyride, but I'm not sure if it's maintained any better? I didn't have time to dig into it. I'm considering adding it back as a plugin, (similar to how the slider was handled in Infinity 1.3), if it's still being maintained and working properly.

christianwach commented 8 years ago

@MrMaz Thanks for the reminder, but I think we're going to have to support this version of the theme for some time to come.

MrMaz commented 8 years ago

@christianwach I understand. Just advising that the standalone joyride is falling way behind jQuery development, new browser versions, etc... so it might only be a matter of time before there are no simple workarounds. It might be possible to pull a fully maintained version of joyride out of the Foundation 5 bundle, but I haven't looked into it.

christianwach commented 8 years ago

@MrMaz Gotcha. It would be no great loss to me to see the back of Joyride - but given it's in 1.3, it shouldn't do what it currently does. Fancy testing this PR? ;-)

christianwach commented 8 years ago

Thanks!