GithubHelp home page GithubHelp logo

mojaray2k / responsive-menu Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mattkersley/responsive-menu

0.0 0.0 0.0 70 KB

Turns any <ol> or <ul> into a <select> for mobiles and low browser sizes

Home Page: http://mattkersley.com/demos/responsive_menu/

responsive-menu's Introduction

jQuery Responsive Menu Plugin

A Plugin which turns your site's navigation into a dropdown (<select>) when your browser is at mobile widths.

Options

The options available for the plugin are listed below. Their default value appears next to their names, and available values below the description.

combine [true]

Convert multiple navigation lists into a single dropdown for mobiles [true/false]

groupPageText ['Main']

Any <li> elements with <ul>/<ol> present get converted to an <optgroup>. As <optgroup> isn't selectable, a "dummy" <option> is added at the top of the group with the <li>'s value. This option sets the text for the "dummy" <option> ['string']

nested [true]

This turns the <optgroup>s on and off [true/false]

prependTo ['body']

Sets the container element for the menu to be put into. ['CSS-selector']

switchWidth [480]

Sets the width (in pixels) at which the site's menu(s) will change to a <select>

topOptionText ['Select a page']

Sets the very first <option>'s display text. Setting this to NULL will prevent it from displaying ['string'/null]

Usage

The plugin can be used like any other jQuery plugin:

$('css-selector').mobileMenu({option:value, option:value});

Licence

There isn't one, because I'm nice. Feel free to say "thanks" or attribute the script to this page if you find it useful.

responsive-menu's People

Contributors

mattkersley avatar iamdustan avatar

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.