Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
bower_components
15 changes: 13 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,17 @@
jPushMenu
=========
# jPushMenu

A jQuery version of Slide and Push Menus

Demo http://takien.github.io/jPushMenu/


# Development

Install [Bower](http://bower.io) on your local machine first, then run:

```sh
bower install
```

This will install jQuery on `bower_components` directory on your local machine.
Copy/paste jQuery file into js directory
29 changes: 29 additions & 0 deletions bower.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"name": "jPushMenu",
"description": "A jQuery version of Slide and Push Menus.",
"version": "1.1.1",
"keywords": [
"js",
"css",
"menu",
"jQuery",
"sliding menus",
"pushing menus",
"navigation",
"responsive",
"mobile menu"
],
"homepage": "http://takien.github.io/jPushMenu/",
"main": [
"css/jPushMenu.css",
"js/jPushMenu.js"
],
"ignore": [
"/.*",
"/css/demo.css",
"/index.html"
],
"dependencies": {
"jQuery": "~1.9.1"
}
}
4 changes: 2 additions & 2 deletions css/demo.css
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ body, html { font-size: 100%; padding: 0; margin: 0;}

body {
font-family: Calibri, Arial, sans-serif;
color: #47a3da;
color: #666;

}

Expand Down Expand Up @@ -110,7 +110,7 @@ a:hover {

.main > section h2 {
font-weight: 300;
color: #ccc;
color: #47a3da;
}

.main > section button {
Expand Down
177 changes: 85 additions & 92 deletions css/jPushMenu.css
Original file line number Diff line number Diff line change
@@ -1,166 +1,159 @@
/* General styles for all menus */
.cbp-spmenu {
background: #47a3da;
position: fixed;
background: #47a3da;
position: fixed;
}

.cbp-spmenu h3 {
color: #afdefa;
font-size: 1.9em;
padding: 20px;
margin: 0;
font-weight: 300;
background: #0d77b6;
color: #afdefa;
font-size: 1.9em;
padding: 20px;
margin: 0;
font-weight: 300;
background: #0d77b6;
}

.cbp-spmenu a {
display: block;
color: #fff;
font-size: 1.1em;
font-weight: 300;
display: block;
color: #fff;
font-size: 1.1em;
font-weight: 300;
}

.cbp-spmenu a:hover {
background: #258ecd;
background: #258ecd;
}

.cbp-spmenu a:active {
background: #afdefa;
color: #47a3da;
background: #afdefa;
color: #47a3da;
}

/* Orientation-dependent styles for the content of the menu */

.cbp-spmenu-vertical {
width: 240px;
height: 100%;
top: 0;
z-index: 1000;
width: 240px;
height: 100%;
top: 0;
z-index: 1000;
overflow-y: scroll;
}

.cbp-spmenu-vertical a {
border-bottom: 1px solid #258ecd;
padding: 1em;
border-bottom: 1px solid #258ecd;
padding: 1em;
}

.cbp-spmenu-horizontal {
width: 100%;
height: 150px;
left: 0;
z-index: 1000;
overflow: hidden;
width: 100%;
height: 150px;
left: 0;
z-index: 1000;
overflow: hidden;
}

.cbp-spmenu-horizontal h3 {
height: 100%;
width: 20%;
float: left;
height: 100%;
width: 20%;
float: left;
}

.cbp-spmenu-horizontal a {
float: left;
width: 20%;
padding: 0.8em;
border-left: 1px solid #258ecd;
float: left;
width: 20%;
padding: 0.8em;
border-left: 1px solid #258ecd;
}

/* Vertical menu that slides from the left or right */

.cbp-spmenu-left {
left: -240px;
left: -240px;
}

.cbp-spmenu-right {
right: -240px;
right: -240px;
}

.cbp-spmenu-left.cbp-spmenu-open {
left: 0px;
.cbp-spmenu-left.menu-open {
left: 0px;
}

.cbp-spmenu-right.cbp-spmenu-open {
right: 0px;
.cbp-spmenu-right.menu-open {
right: 0px;
}

/* Horizontal menu that slides from the top or bottom */

.cbp-spmenu-top {
top: -150px;
top: -150px;
}

.cbp-spmenu-bottom {
bottom: -150px;
bottom: -150px;
}

.cbp-spmenu-top.cbp-spmenu-open {
top: 0px;
.cbp-spmenu-top.menu-open {
top: 0px;
}

.cbp-spmenu-bottom.cbp-spmenu-open {
bottom: 0px;
.cbp-spmenu-bottom.menu-open {
bottom: 0px;
}

/* Push classes applied to the body */

.cbp-spmenu-push {
overflow-x: hidden;
position: relative;
left: 0;
.push-body {
overflow-x: hidden;
position: relative;
left: 0;
}

.cbp-spmenu-push-toright {
left: 240px;
.push-body-toright {
left: 240px;
}

.cbp-spmenu-push-toleft {
left: -240px;
.push-body-toleft {
left: -240px;
}

/* Transitions */

.cbp-spmenu,
.cbp-spmenu-push {
-webkit-transition: all 0.3s ease;
-moz-transition: all 0.3s ease;
transition: all 0.3s ease;
.push-body {
-webkit-transition: all 0.3s ease;
-moz-transition: all 0.3s ease;
transition: all 0.3s ease;
}

/* Example media queries */
@media screen and (max-width: 55.1875em) {
.cbp-spmenu-horizontal {
font-size: 75%;
height: 110px;
}

@media screen and (max-width: 55.1875em){

.cbp-spmenu-horizontal {
font-size: 75%;
height: 110px;
}

.cbp-spmenu-top {
top: -110px;
}

.cbp-spmenu-bottom {
bottom: -110px;
}
.cbp-spmenu-top {
top: -110px;
}

.cbp-spmenu-bottom {
bottom: -110px;
}
}

@media screen and (max-height: 26.375em){
@media screen and (max-height: 26.375em) {
.cbp-spmenu-vertical {
font-size: 90%;
width: 190px;
}

.cbp-spmenu-vertical {
font-size: 90%;
width: 190px;
}
.cbp-spmenu-left,
.push-body-toleft {
left: -190px;
}

.cbp-spmenu-left,
.cbp-spmenu-push-toleft {
left: -190px;
}
.cbp-spmenu-right {
right: -190px;
}

.cbp-spmenu-right {
right: -190px;
}

.cbp-spmenu-push-toright {
left: 190px;
}
}
.push-body-toright {
left: 190px;
}
}
Loading