-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlanding.js
More file actions
83 lines (72 loc) · 1.93 KB
/
landing.js
File metadata and controls
83 lines (72 loc) · 1.93 KB
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
$(document).ready (function(){
quote();
$(".icon").tooltip({ show: { effect: "blind", duration: 800, selector: true } });
});
var seqNum;
function imageChange(){
var images =
[
{ image: "assets/img/audrey.jpg"
, text: "if only"
}
,
{ image: "assets/img/bernie.jpg"
, text: "colonel sanders for fried chicken 2k16"
}
,
{ image: "assets/img/ditto.png"
, text : "same"
}
,
{ image: "assets/img/doge.jpg"
, text : "me"
}
,
{ image: "assets/img/grumpcat.jpg"
, text : "on my period"
}
,
{ image: "assets/img/marinette.png"
, text : "me during the last hr of a hackathon"
}
,
{ image: "assets/img/tacobell.jpg"
, text : "the happiest place on earth"
}
,
{ image: "assets/img/tubss.jpg"
, text : "i love eating curry"
}
,
{ image: "assets/img/mulan.jpg"
, text : "i was a fool in school for cutting gym"
}
,
{ image: "assets/img/sriracha.jpg"
, text : "hot sauce in my bag swag"
}
];
var randNum = Math.floor(Math.random() * images.length);
// to prevent two images in a row, check if the previous image
// is the image now
if (seqNum === randNum) {
randNum = (randNum == images.length) ? randNum-1 : randNum+1;
}
seqNum = randNum;
document.getElementById('propic').src = images[randNum].image;
$("#propic").attr('title', images[randNum].text).tooltip('fixTitle').tooltip('show');
// $("#propic").attr('src', images[randNum].image).tooltip('show');
}
function quote (){
var quotes =
[ 'it\'s like i\'m a developer or something'
, 'software engineer by night, snorlax by day'
, '70% sparkling water, 30% sriracha, 100% carbs'
, 'git add, git commit, git push, git some sleep'
, 'manhole covers are round because they\'re not edgy enough'
, 'of course i speak python. hisssssss'
, 'fighting evil by moonlight. fixing bugs by daylight.'
];
var randNum = Math.floor(Math.random() * quotes.length);
document.getElementById("titleSub").innerHTML = quotes[randNum];
}