Shadows introduction

If you want the page to have a shadow to emphasize it's in front of the menu, or if you want each panel to have a shadow to emphasize it's in front of its parent panel, include the "shadows" extension .css file and add the shadow style to the extensions option.

<head>
   <script src="path/to/jquery.js" type="text/javascript"></script>
   <script src="path/to/jquery.mmenu.min.js" type="text/javascript"></script>
   <link href="path/to/jquery.mmenu.css" type="text/css" rel="stylesheet" />
   <link href="path/to/jquery.mmenu.pageshadow.css" type="text/css" rel="stylesheet" />
   <script type="text/javascript">
      $(document).ready(function() {
         $("#my-menu").mmenu({
            extensions: ["shadow-page"]
         });
      });
   </script>

Example

Give it a go, change the options below and see how it affects the menu in the example on the right.

  • Add a shadow to the page.
  • Add a shadow to the panels.
  • Works great with:
  • Show a small part of the parent panel.
<script type="text/javascript">
   jQuery(document).ready(function( $ ) {

   });
</script>

Available shadows

shadow-page
Adds a shadow to the page.
shadow-panels
Adds a shadow to the panels.

SCSS variables for the "shadows" extension

Variable Default value Datatype Description
$mm_pageShadow 0 0 10px rgba(#000,0.3) CSS value The box-shadow of the page.
$mm_panelShadow 0 0 10px rgba(#000,0.3) CSS value The box-shadow of the panels.
Dependencies:
Works great with:

Next extension:
Themes