Coder Social home page Coder Social logo

Comments (6)

arielsalminen avatar arielsalminen commented on July 28, 2024

@davatron5000 This is a good question, so would love to hear some more input on this matter.

from responsive-nav.js.

jshawl avatar jshawl commented on July 28, 2024

In case you end up removing the tab-index option jshawl@f29b957

from responsive-nav.js.

davatron5000 avatar davatron5000 commented on July 28, 2024

It might be good to expose this setting through the API, because it could be good for some applications, but only as a conditional enhancement. Like:

if(opts.tabIndex) {
  setAttributes(toggle, {
    "tabindex": opts.tabIndex
  }
}

Then the default would just be 0 or false. I guess it depends if its necessary for the plugin to work. I think the general rule of thumb for tabindex is: "if you don't need it, don't use it".

from responsive-nav.js.

arielsalminen avatar arielsalminen commented on July 28, 2024

@davatron5000 I like that approach. Based on this, I would probably remove it completely from the defaults and use something like that.

But also: not sure if it needs a setting at all(?) as one can also use “customToggle” option and write his/her own html for the toggle if needed.

from responsive-nav.js.

arielsalminen avatar arielsalminen commented on July 28, 2024

@davatron5000 Decided to remove the whole option after considering this more, so closing this issue.

If someone feels it's needed, we can continue the discussion here. :-)

from responsive-nav.js.

davatron5000 avatar davatron5000 commented on July 28, 2024

@viljamis I think that's a good call! I looked into it more and it seems that fussing with tab-index typically results in disaster. So yay! Nice work. New favorite plugin 🍔

from responsive-nav.js.

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.