18 lines
448 B
JavaScript
18 lines
448 B
JavaScript
|
$( document ).ready(function() {
|
||
|
|
||
|
// Interesting DOM Elements
|
||
|
var sidebar = $("#sidebar");
|
||
|
var page_wrapper = $("#page-wrapper");
|
||
|
|
||
|
$("#sidebar-toggle").click(function(event){
|
||
|
if(sidebar.position().left === 0){
|
||
|
sidebar.css({left: "-300px"});
|
||
|
page_wrapper.css({left: "15px"});
|
||
|
} else {
|
||
|
sidebar.css({left: "0"});
|
||
|
page_wrapper.css({left: "315px"});
|
||
|
}
|
||
|
});
|
||
|
|
||
|
});
|