-
Notifications
You must be signed in to change notification settings - Fork 0
/
custom.js
47 lines (38 loc) · 1.19 KB
/
custom.js
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
$(document).ready(function() {
//should be fixed in core
$('i.fa-rss').each(function() {
$(this).addClass('fas');
} );
//should be fixed in core
$('.forum-viewtopic').find('ul.dropdown-menu li').each(function() {
$(this).addClass('dropdown-item');
} );
$('.forum-viewtopic').find('ul.dropdown-menu').each(function() {
$(this).addClass('dropdown-menu-right');
} );
$('#forum-viewforum').find('ul.dropdown-menu').each(function() {
$(this).addClass('dropdown-menu-right');
} );
$('.btn-group').find('ul.dropdown-menu li').each(function() {
$(this).addClass('dropdown-item');
} );
// hide #back-top first
$("#back-top").hide();
// fade in #back-top
$(function () {
$(window).scroll(function () {
if ($(this).scrollTop() > 100) {
$('#back-top').fadeIn();
} else {
$('#back-top').fadeOut();
}
});
// scroll body to 0px on click
$('#back-top a').click(function () {
$('body,html').animate({
scrollTop: 0
}, 500);
return false;
});
});
});