forked from flouthoc/blinkTitle.js
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
142 lines (107 loc) · 6.23 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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="">
<meta name="author" content="">
<link rel="icon" href="../../favicon.ico">
<title>blinkTitle.js</title>
<!-- Bootstrap core CSS -->
<link href="bootstrap.css" rel="stylesheet">
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/8.4/styles/default.min.css">
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/8.4/highlight.min.js"></script>
<script type="text/javascript" src="index.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js"></script>
<!-- Custom styles for this template -->
<!-- Just for debugging purposes. Don't actually copy these 2 lines! -->
<!--[if lt IE 9]><script src="../../assets/js/ie8-responsive-file-warning.js"></script><![endif]-->
<script src="../../assets/js/ie-emulation-modes-warning.js"></script>
<!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries -->
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
<script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
<script>hljs.initHighlightingOnLoad();</script>
</head>
<style>
#head{
height:30px;
background-color:orange;
}
</style>
<script type="text/javascript">
$(document).ready(function(){
$("#one").click(function(){
blinkTitleStop();
blinkTitle("Head's Up","Notification",500);
alert('Hi, Look at Titlebar');
});
});
$(document).ready(function(){
$("#two").click(function(){
blinkTitleStop();
blinkTitle("Head's Up","Notification",500,true);
alert('Hi, Change the Current Tab and Look at Titlebar');
});
});
</script>
<body>
<div id="head" class="col-md-12"><a href="https://github.com/argunner/blinkTitle.js"><img style="position: absolute; top: 0; left: 0; border: 0;" src="https://camo.githubusercontent.com/567c3a48d796e2fc06ea80409cc9dd82bf714434/68747470733a2f2f73332e616d617a6f6e6177732e636f6d2f6769746875622f726962626f6e732f666f726b6d655f6c6566745f6461726b626c75655f3132313632312e706e67" alt="Fork me on GitHub" data-canonical-src="https://s3.amazonaws.com/github/ribbons/forkme_left_darkblue_121621.png"></a></div>
<!-- Main jumbotron for a primary marketing message or call to action -->
<div class="jumbotron">
<div class="container">
<h1>blinkTitle.js</h1>
<p>Is a Pure Javascript Implementation of TitleBar Alert or Notification.It Can Perform Blinking of Html Titlebar When Required.</p>
<div class="col-md-12">
<table><tr><td><iframe src="http://ghbtns.com/github-btn.html?user=argunner&repo=blinkTitle.js&type=watch&size=large" height="30" width="100" frameborder="0" scrolling="0" style="width:100px; height: 30px;" allowTransparency="true"></iframe></td><td><iframe src="http://ghbtns.com/github-btn.html?user=argunner&repo=blinkTitle.js&type=fork&size=large" height="30" width="100" frameborder="0" scrolling="0" style="width:100px; height: 30px;" allowTransparency="true"></iframe></td><td><iframe src="http://ghbtns.com/github-btn.html?user=argunner&type=follow&size=large" height="30" width="240" frameborder="0" scrolling="0" style="width:240px; height: 30px;" allowTransparency="true"></iframe></td></tr></table>
</div>
<img src="op.gif"></img>
</div>
</div>
<div class="container">
<!-- Example row of columns -->
<div class="row">
<div class="col-md-12">
<center><a href="https://raw.githubusercontent.com/argunner/blinkTitle.js/master/index.js" class="btn btn-primary btn-lg">Download v1.0</a></center>
</div>
<div class="col-md-12">
<h2>Getting It Into Your Html</h2>
<pre><code class="xml"><script type="text/javascript" src="https://raw.githubusercontent.com/argunner/blinkTitle.js/master/index.js"></script></code></pre>
</div>
<div class="col-md-6">
<h2>Regular Alert</h2>
<pre><code class="javascript">blinkTitle("Head's Up","Notification",1000);</code></pre>
<p> This Basic Example of blinkTitle . The function will change toggle the title between "Head's Up" and "Notification" . Transition Time between these two messages will be 1000 millisecons </p>
<p><a class="btn btn-default" href="#" id="one" role="button">Try It</a> <a class="btn btn-default" href="#" role="button">Stop</a></p>
</div>
<div class="col-md-6">
<h2>Alert when tab out of focus</h2>
<pre><code class="javascript">blinkTitle("Head's Up","Notification",1000,true);</code></pre>
<p>This Basic Example of blinkTitle . The function will change toggle the title between "Head's Up" and "Notification" . Transition Time between these two messages will be 1000 millisecons.The Alert/Notification will be shown when Users attention in out of focus from the page.By the implementation of <b>onfocus</b> and <b>onblur</b> </p>
<p><a class="btn btn-default" href="#" id="two" role="button">Try It</a> <a class="btn btn-default" href="#" role="button">Stop</a></p>
</div>
<div class="col-md-12">
<h2>Stop It!</h2>
<pre><code class="javascript">blinkTitleStop();</code></pre>
<p>You Can Stop The blinkTitle() anytime By Using blinkTitleStop()</p>
</div>
</div>
<div class="col-md-12">
<h2>To-Do's (Not Yet Implemented)</h2>
<p>1.) Timeout Implementation</p>
<p>2.) Simplifying Arguments To JSON format</p>
<p>3.) Minifying the source</p>
</div>
</div>
<hr>
<footer>
</footer>
</div> <!-- /container -->
<!-- Bootstrap core JavaScript
================================================== -->
<!-- Placed at the end of the document so the pages load faster -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
</body>
</html>