bootstrap 3 ftw

This commit is contained in:
Feliciaan De Palmenaer 2015-03-27 01:07:43 +01:00
parent 7a8b8b7434
commit 0426b71556
3 changed files with 36 additions and 105 deletions

View file

@ -1,90 +1,5 @@
/* Custom CSS */
body { body {
margin: 0; min-height: 2000px;
padding: 0; padding-top: 70px;
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
color: #444;
}
/*
* Create dark grey header with a white logo
*/
header {
background-color: #2B2B2B;
height: 35px;
width: 100%;
opacity: .9;
margin-bottom: 10px;
}
header h1.logo {
margin: 0;
font-size: 1.7em;
color: #fff;
text-transform: uppercase;
float: left;
}
header h1.logo:hover {
color: #fff;
text-decoration: none;
}
/*
* Center the body content
*/
.container {
width: 940px;
margin: 0 auto;
}
div.jumbo {
padding: 10px 0 30px 0;
background-color: #eeeeee;
-webkit-border-radius: 6px;
-moz-border-radius: 6px;
border-radius: 6px;
}
div.login {
padding: 10px 0 30px 0;
background-color: #eeeeee;
-webkit-border-radius: 6px;
-moz-border-radius: 6px;
border-radius: 6px;
}
h2 {
font-size: 3em;
margin-top: 40px;
text-align: center;
letter-spacing: -2px;
}
h3 {
font-size: 1.7em;
font-weight: 100;
margin-top: 30px;
text-align: center;
letter-spacing: -1px;
color: #999;
}
.menu {
float: right;
margin-top: 8px;
}
.menu li {
display: inline;
}
.menu li + li {
margin-left: 35px;
}
.menu li a {
color: #999;
text-decoration: none;
} }

View file

@ -1,6 +1,6 @@
{% extends "layout.html" %} {% extends "layout.html" %}
{% block content %} {% block content %}
<div class="jumbo"> <div class="jumbotron">
<h2>Welcome to FoodBot</h2> <h2>Welcome to FoodBot</h2>
<h3>This is the home page for FoodBot</h3> <h3>This is the home page for FoodBot</h3>
</div> </div>

View file

@ -1,35 +1,51 @@
<!DOCTYPE html> <!DOCTYPE html>
<html> <html>
<head lang="en"> <head lang="en">
<meta charset="UTF-8"> <meta charset="utf-8">
<title>FoodBot</title> <meta http-equiv="X-UA-Compatible" content="IE=edge">
<link rel="stylesheet" href="{{ url_for('static', filename='css/main.css') }}"> <meta name="viewport" content="width=device-width, initial-scale=1">
<title>FoodBot</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css">
<link rel="stylesheet" href="{{ url_for('static', filename='css/main.css') }}">
</head> </head>
<body> <body>
<nav class="navbar navbar-default navbar-fixed-top">
<header>
<div class="container"> <div class="container">
<h1 class="logo">FOODBOT</h1> <div class="navbar-header">
<nav> <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
<ul class="menu"> <span class="sr-only">Toggle navigation</span>
<li><a href="{{ url_for('home') }}">Home</a></li> <span class="icon-bar"></span>
<li><a href="{{ url_for('stats') }}">Stats</a></li> <span class="icon-bar"></span>
<li><a href="{{ url_for('about') }}">About</a></li> <span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="{{ url_for('home') }}">FOODBOT</a>
</div>
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav">
<li><a href="{{ url_for('home') }}">Home</a></li>
<li><a href="{{ url_for('about') }}">About</a></li>
<li><a href="{{ url_for('stats') }}">Stats</a></li>
</ul>
<ul class="nav navbar-nav navbar-right">
{% if current_user.is_anonymous() %} {% if current_user.is_anonymous() %}
<li><a href="{{ url_for('login') }}">Login</a></li> <li><a href="{{ url_for('login') }}">Login</a></li>
{% else %} {% else %}
<li><a href="#">{{ current_user.username }}</a></li>
<li><a href="{{ url_for('logout') }}">Logout</a></li> <li><a href="{{ url_for('logout') }}">Logout</a></li>
<li>{{ current_user.username }}</li>
{% endif %} {% endif %}
</ul> </ul>
</nav> </div><!--/.nav-collapse -->
</div> </div>
</header> </nav>
<div class="container"> <div class="container">
{% block content %} {% block content %}
{% endblock %} {% endblock %}
</div> </div>
<!-- jQuery (necessary for Bootstrap's JavaScript plugins) -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
<!-- Include all compiled plugins (below), or include individual files as needed -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/js/bootstrap.min.js"></script>
</body> </body>
</html> </html>