Coder Social home page Coder Social logo

Comments (6)

davidtmiller avatar davidtmiller commented on August 17, 2024 2

Fixed in #83 - closing this one out!

from startbootstrap-creative.

davidtmiller avatar davidtmiller commented on August 17, 2024

Should be fixed in #77

from startbootstrap-creative.

srccd avatar srccd commented on August 17, 2024

Still seems to be failing. I admit I could be missing something, but if I try to add a simplistic accordion/collapse, it doesn't work - even with a fresh d/l of gh-pages.
<h4><a data-toggle="collapse" data-parent="#accordion" href="#collapse1">test question? &raquo;</a></h4><div id="collapse1" class="panel-collapse collapse"><p>test answer!</p></div>

Removing the "Smooth scrolling using jQuery easing" segment in the creative.js gets it working again.

from startbootstrap-creative.

srccd avatar srccd commented on August 17, 2024

Changing the line I referenced in the original post above to something like the following resolves the issue.
$('a[href*="#"]:not([href="#"], [data-toggle="collapse"])').click(function() {

from startbootstrap-creative.

davidtmiller avatar davidtmiller commented on August 17, 2024

Thanks for bringing this up again. Your solution works for just the collapse conflict, but this will still conflict with a lot of other things, including modals and anything else that is targeting an id through a link.

I think the only way to truly fix this up with no conflicts is to add a class to all page scrolling triggers and then adjust the JS accordingly. So, for example, all navigation links that currently look like this:

<a class="nav-link" href="#target">Link</a>

will need to change to something like this:

<a class="nav-link js-scroll-trigger" href="#target">Link</a>

with the JS changing from this:

$('a[href*="#"]:not([href="#"])').click(function() {

to this:

$('a.js-scroll-trigger[href*="#"]:not([href="#"])').click(function() {

I feel like this is the only real solution to the scroll triggers not interfering with anything. I'd love to not use a special JS only class, but I'm afraid this is the only way I know how to prevent conflicts.

from startbootstrap-creative.

davidtmiller avatar davidtmiller commented on August 17, 2024

Fixed in the latest commit, I'll make the pr to the gh-pages branch once a few more updates have been made.

from startbootstrap-creative.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.