Skip to content

Commit 926f855

Browse files
author
Jacob Krol
committed
Erase CNAME
1 parent d71168c commit 926f855

File tree

2 files changed

+35
-30
lines changed

2 files changed

+35
-30
lines changed

docs/CNAME

Lines changed: 0 additions & 1 deletion
This file was deleted.

scripts/js-main.js

Lines changed: 35 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -7,35 +7,24 @@ $(document).ready(function() {
77
name_tag();
88
disable_smooth_scroll();
99
// dropdown_title_active(); KEEP DROPDOWN TITLE ACTIVE
10+
set_side_scroll_box();
11+
begin_side_scroll();
1012

11-
$('.side-scroll-outer').css('width', $(window).width());
12-
$('.side-scroll-inner').css('width', 4*$(window).width());
13-
$('.side-scroll-inner .content-block').css('width', $(window).width());
14-
15-
// setTimeout(function side_scroll(){
16-
17-
// make the div slides instead of jumping to the destination
18-
// $('.side-scroll-inner').css('transition', 'transform 1.0s ease');
19-
20-
// var shiftVal = '-'+String($(window).width())+"px";
21-
// will slide 30px to the right, can be negative (-100px), percentage (100%)
22-
// $('.side-scroll-inner').css('transform', 'translateX('+shiftVal+')');
23-
24-
// setTimeout(side_scroll, 2000);
25-
26-
// }, 2000);
27-
28-
// var sso = $('side-scroll-outer');
29-
// sso.css('padding-bottom', sso.offsetHeight - sso.clientHeight + "px");
13+
let menu = {
14+
background: $('#menu').css('background'),
15+
border: $('#menu').css('border')
16+
};
17+
18+
setInterval(function navbar() {
19+
if(!pageYOffset) {
20+
$('#menu').css({'background': 'none'})
21+
.css({'border': 'none'});
22+
} else {
23+
$('#menu').animate({backgroundColor: menu.background}, 1000);
24+
//.animate({'borderBottomColor': menu.border}, "slow");
25+
}
26+
}, 1);
3027

31-
var shiftVal = 0,
32-
numPanels = 4;
33-
setInterval(function side_scroll() {
34-
shiftVal += (shiftVal < (numPanels-1)*$(window).width() ? $(window).width() : -(numPanels-1)*$(window).width());
35-
// $('.side-scroll-outer').scrollLeft(shiftVal);
36-
37-
$('.side-scroll-outer').animate( {scrollLeft: shiftVal }, 1500 );
38-
}, 4000);
3928

4029
});
4130

@@ -76,8 +65,8 @@ function dropdown_title_active() {
7665
}
7766

7867
function background_image() {
79-
$('.overlay').css('height', $(window).height() - $('#menu').height());
80-
$('.overlay').css('top', $('#menu').height());
68+
$('.overlay').css('height', $(window).height());// - $('#menu').height());
69+
//$('.overlay').css('top', $('#menu').height());
8170
$('header').css('height', $(window).height());
8271
}
8372

@@ -103,3 +92,20 @@ function disable_smooth_scroll() {
10392
}
10493
}
10594

95+
function set_side_scroll_box() {
96+
$('.side-scroll-outer').css('width', $(window).width());
97+
$('.side-scroll-inner').css('width', 4*$(window).width());
98+
$('.side-scroll-inner .content-block').css('width', $(window).width());
99+
}
100+
101+
function begin_side_scroll() {
102+
var shiftVal = 0,
103+
numPanels = 4;
104+
setInterval(function side_scroll() {
105+
shiftVal += (shiftVal < (numPanels-1)*$(window).width() ? $(window).width() : -(numPanels-1)*$(window).width());
106+
// $('.side-scroll-outer').scrollLeft(shiftVal);
107+
108+
$('.side-scroll-outer').animate( {scrollLeft: shiftVal }, 1500 );
109+
}, 4000);
110+
}
111+

0 commit comments

Comments
 (0)