joggink/jquerymobiledropdown — pull request #10 by erunyon (2011-12-22 16:02:54+00:00)
Title: Adding a number of options I needed for a work project that others may find useful.

The changes include the following:

Additional config options:
appendTo: Pass a selector to which the nav will be appended instead of the parent of the actual nav. In my case, I usually put the nav at the bottom of the markup and include skip-links to jump to the nav. The site I'm working on also wanted the primary nav at the top of the site in a drop-down. So using this option, I can provide quick access to the top-level nav while keeping the primary nav where it is at the bottom (and visible). Default is the 'parent'

className: Pass an optional class name that can be used for styling purposes. Default is 'mobileselect'

useWindowWidth: I use Safari to test my responsive designs, so I needed to test for the width of the window and not the screen. Default is 'false'.

Other changes:
When checking for "current", the legacy CMS I'm using puts "current" on the link instead of the parent "li". So I added a check for self as well as parent.

The drop-down that was generated on my site was adding "selected" to all elements since the empty string was resulting in true. Changed both checks to return false instead of an empty string.