-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
71 lines (62 loc) · 3.26 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Bootstrap 3 Starter</title>
<meta name="title" content="">
<meta name="description" content="">
<meta name="author" content="Aaron Rosenbaum">
<meta name="copyright" content="2014">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta name="mobile-web-app-capable" content="yes">
<meta name="viewport" content="width=device-width,initial-scale=1.0,user-scalable=no">
<!--[if lt IE 9]>
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
<script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js"></script>
<![endif]-->
<link rel="stylesheet" href="css/bootstrap.min.css">
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.min.css">
<link rel="stylesheet" href="css/style.css">
</head>
<body>
<div id="content">
<header>
<h1>Sitename</h1>
<a id="menu-toggle" class="visible-xxs" href="#" data-toggle="menu" data-context="#content"><i class="fa fa-bars"></i></a>
<nav role="menu">
<a href="#"><i class="fa fa-home"></i><span>Lorem Ipsum</span></a>
<a href="#"><i class="fa fa-info"></i><span>Dolor Sit Amet</span></a>
<a href="#"><i class="fa fa-folder"></i><span>Consectetuer </span></a>
<a href="#"><i class="fa fa-bullhorn"></i><span>Adipiscing Elit</span></a>
<a href="#"><i class="fa fa-envelope"></i><span>Sed Diam</span></a>
<a href="#"><i class="fa fa-book"></i><span>Nonummy Nibh</span></a>
</nav>
</header>
<div class="container">
<div class="row">
<div class="col-md-4">
<p>This was written by Aaron Rosenbaum as a proof of concept for sliding semantically correct navigation.</p>
<p>This project is hosted on <a href="http://github.com/arosenb2/responsive-navigation-panel"><i class="fa fa-github"></i> Github</a>.</p>
</div>
<div class="col-md-8">
<p>For this snippet, I placed the <code><nav></code> tag inside the header and position it to the left of <code>#content</code> with CSS and animate the transition. It only activates the alternate layout when viewed from a phone (480px wide or less).</p>
<p>CSS3 was used for the animation and shadows. This solution should work in all modern browsers, along with IE8 and higher.</p>
</div>
</div>
</div>
</div>
<script type="text/javascript" src="js/jquery-1.10.2.min.js"></script>
<script type="text/javascript" src="js/bootstrap.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$("[data-toggle='menu']").on("click",function(){
$($(this).data("context")).toggleClass("reveal");
$("nav").toggleClass("active");
});
});
</script>
</body>
</html>