Skip to content

Commit c0df7d9

Browse files
committed
Website Button Popover
1 parent b130803 commit c0df7d9

File tree

1 file changed

+14
-2
lines changed

1 file changed

+14
-2
lines changed

index.html

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ <h2>Spice up your website with live HTML5 mockups of popular devices</h2>
155155
<div class="screen">
156156
<!-- PUT CONTENTS HERE -->
157157
</div>
158-
<div class="button">
158+
<div class="button" data-toggle="popover" data-placement="bottom" data-content="Device buttons are perfectly rendered out and can be hooked to links or JavaScript events">
159159
<!-- You can hook the "home button" to some JavaScript events or just remove it -->
160160
</div>
161161
</div>
@@ -185,8 +185,8 @@ <h2>Spice up your website with live HTML5 mockups of popular devices</h2>
185185

186186

187187
<script src="bower_components/jquery/dist/jquery.min.js"></script>
188-
<script src="bower_components/bootstrap/dist/js/bootstrap.min.js"></script>
189188
<script src="bower_components/tether/dist/js/tether.min.js"></script>
189+
<script src="bower_components/bootstrap/dist/js/bootstrap.min.js"></script>
190190

191191
<script>
192192
(function (i, s, o, g, r, a, m) {
@@ -203,6 +203,18 @@ <h2>Spice up your website with live HTML5 mockups of popular devices</h2>
203203

204204
ga('create', 'UA-103554950-1', 'auto');
205205
ga('send', 'pageview');
206+
207+
$(function () {
208+
$('[data-toggle="popover"]').popover();
209+
210+
$('.col-md-4')
211+
.on('mouseenter', function() {
212+
$('[data-toggle="popover"]').popover('show');
213+
})
214+
.on('mouseleave', function() {
215+
$('[data-toggle="popover"]').popover('hide');
216+
});
217+
});
206218
</script>
207219
</body>
208220

0 commit comments

Comments
 (0)