Skip to content

Commit 33368f0

Browse files
committed
Improving examples, removing old stuff - preliminary go at bootstrap with jGrowl
1 parent c3a96aa commit 33368f0

14 files changed

+219
-326
lines changed

examples/bootstrap.html

Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="utf-8">
5+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
6+
<meta name="viewport" content="width=device-width, initial-scale=1">
7+
<meta name="description" content="">
8+
<meta name="author" content="">
9+
10+
<title>jGrowl and Bootstrap</title>
11+
12+
<link rel="stylesheet" href="../jquery.jgrowl.css" type="text/css"/>
13+
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css">
14+
15+
<!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
16+
<!--[if lt IE 9]>
17+
<script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
18+
<script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
19+
<![endif]-->
20+
21+
<style>
22+
body {
23+
padding-top: 50px;
24+
}
25+
</style>
26+
</head>
27+
28+
<body>
29+
<div id="jGrowl-container1" class="jGrowl top-right"></div>
30+
31+
<div class="navbar navbar-inverse navbar-fixed-top" role="navigation">
32+
<div class="container">
33+
<div class="navbar-header">
34+
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
35+
<span class="sr-only">Toggle navigation</span>
36+
<span class="icon-bar"></span>
37+
<span class="icon-bar"></span>
38+
<span class="icon-bar"></span>
39+
</button>
40+
<a class="navbar-brand" href="#">jGrowl</a>
41+
</div>
42+
<div class="collapse navbar-collapse">
43+
<ul class="nav navbar-nav">
44+
<li class="active"><a href="#">Home</a></li>
45+
<li><a href="#about">About</a></li>
46+
<li><a href="#contact">Contact</a></li>
47+
</ul>
48+
</div><!--/.nav-collapse -->
49+
</div>
50+
</div>
51+
52+
<div class="container">
53+
54+
<div>
55+
<h1>jGrowl and Bootstrap</h1>
56+
<p class="lead">This is a Bootstrap starter template with jGrowl integrated. As you can see it's extremely easy to make jGrowl look and feel like part of Bootstrap.</p>
57+
</div>
58+
<div id="jGrowl-container2" class="jGrowl"></div>
59+
</div><!-- /.container -->
60+
61+
62+
<!-- Bootstrap core JavaScript
63+
================================================== -->
64+
<!-- Placed at the end of the document so the pages load faster -->
65+
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
66+
<script src="//netdna.bootstrapcdn.com/bootstrap/3.1.1/js/bootstrap.min.js"></script>
67+
<script type="text/javascript" src="../jquery.jgrowl.js"></script>
68+
<script type="text/javascript">
69+
(function($){
70+
$(function(){
71+
$.jGrowl.defaults.closerTemplate = '<div class="alert alert-info">Close All</div>';
72+
73+
var alertTypes = ['success', 'info', 'warning', 'danger'];
74+
75+
for (var i=0; i<10; i++) {
76+
setTimeout(function(){
77+
var alertType = alertTypes[Math.floor(Math.random()*alertTypes.length)];
78+
79+
$('#jGrowl-container1').jGrowl({
80+
header: alertType.substring(0, 1).toUpperCase() + alertType.substring(1) + ' Notification',
81+
message: 'Hello world ',
82+
group: 'alert-' + alertType,
83+
life: 5000
84+
});
85+
}, i*2000);
86+
}
87+
});
88+
})(jQuery);
89+
</script>
90+
</body>
91+
</html>

examples/iphone.png

-9.41 KB
Binary file not shown.

examples/jgrowl-pool.html

Lines changed: 0 additions & 65 deletions
This file was deleted.

0 commit comments

Comments
 (0)