GithubHelp home page GithubHelp logo

primaapriansyah / yamm3 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from geedmo/yamm3

0.0 1.0 0.0 1.04 MB

Yet another megamenu for Bootstrap 3

Home Page: http://geedmo.github.io/yamm3/

License: MIT License

CSS 6.32% HTML 89.82% JavaScript 3.86%

yamm3's Introduction

Yamm

This is Yet another megamenu for Bootstrap 3 from Twitter.

Lightweight and pure CSS megamenu that uses the standard navbar markup and the fluid grid system classes from Bootstrap 3. Work for fixed and responsive layout and has the facility to include (almost) any Bootstrap elements.

####Demo

Markup

  1. Reuse navbar markup and add class .yamm at the top.

  2. Then add your markup into the .dropdown-menu

  3. Optionally use .yamm-content to wrap content with padding.

Example

<nav class="navbar yamm navbar-default " role="navigation">
    ...
    <ul class="nav navbar-nav">
        <li class="dropdown">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown</a>
            <ul class="dropdown-menu">
                <li>
                    <div class="yamm-content">
                    <div class="row"> 
                        ...
                </li>
            </ul>
        </li>
    </ul>
    ...
</nav>

Fullwidth

By default every mega-dropdown will take the content size so is possible to use add .yamm-fw to .dropdown to expand it fullwidth.
Yamm works better with fullwidth menus.

Example

<nav class="navbar yamm navbar-default " role="navigation">
...
     <ul class="nav navbar-nav">
       <li class="dropdown yamm-fw">
             ...
       </li>
     </ul>
...
</nav>

Javascript

If necessary, this code will prevent unexpected menu close when using some components (like accordion, forms, etc)

$(document).on('click', '.yamm .dropdown-menu', function(e) {
   e.stopPropagation()
})

Install via composer

{ 
	"require": {
		"geedmo/yamm3": "dev-master"
	}
}

Install with bower

bower install yamm3 --save

AngularJS

Check it at hjzheng/angular-mega-menu

Compile

Run the following commands in the repository folder

  • npm install
  • gulp

To compile yamm with demo

  • gulp demo

License

yamm3's People

Contributors

geedmo avatar igormukhingmailcom avatar x0xmaximus avatar

Watchers

Prima Utama Apriansyah 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.