-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.js
137 lines (133 loc) · 3.18 KB
/
main.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
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
function addContent(){
const showcase = document.getElementById('showcase');
return data.map(data => {
const render =
`<div class='box'>
<a target='_blank' href='${data.url}'>
<img alt='${data.title}' src='${data.img}'>
<div class='title-grad'>
<span class='title'>${data.title}</span>
</div>
</a>
</div>`;
showcase.insertAdjacentHTML("beforeend", render);
});
}
window.onload = addContent;
const data = [
{
title: "JavaScript Drum Kit",
url: "01_drum/index.html",
img: "img/01.jpg"
},
{
title: "JS and CSS Clock",
url: "02_clock/index.html",
img: "img/02.jpg"
},
{
title: "Update CSS Variables with JS",
url: "03_cssvar/index.html",
img: "img/03.jpg"
},
{
title: "Flex Panel Gallery",
url: "05_flex/index.html",
img: "img/05.jpg"
},
{
title: "Type Ahead",
url: "06_type/index.html",
img: "img/06.jpg"
},
{
title: "HTML5 Canvas",
url: "08_canvas/index.html",
img: "img/08.jpg"
},
{
title: "Hold Shift and Check Checkboxes",
url: "10_check/index.html",
img: "img/10.jpg"
},
{
title: "Custom Video Player",
url: "11_vid/index.html",
img: "11 - Custom Video Player/image/11_port.jpg"
},
{
title: "Key Sequence Detection",
url: "12_keyseq/index.html",
img: "12 - Key Sequence Detection/image/12_port.jpg"
},
{
title: "Slide in on Scroll",
url: "13_slide/index.html",
img: "13 - Slide in on Scroll/image/13_port.jpg"
},
{
title: "Local Storage",
url: "15_localstorage/index.html",
img: "15 - LocalStorage/image/14_port.jpg"
},
{
title: "Mouse Move Shadows",
url: "16_mousemove/index.html",
img: "16 - Mouse Move Shadow/image/16_port.jpg"
},
{
title: "Webcam Fun",
url: "19_webcam/index.html",
img: "19 - Webcam Fun/image/19_port.jpg"
},
{
title: "Speech Detection",
url: "20_speech/index.html",
img: "20 - Speech Detection/image/20_port.jpg"
},
{
title: "Follow Along Link Highlighter",
url: "21_geolocation/index.html",
img: "22 - Follow Along Link Highlighter/image/22_port.jpg"
},
{
title: "Follow Along Link Highlighter",
url: "22_followalong/index.html",
img: "22 - Follow Along Link Highlighter/image/22_port.jpg"
},
{
title: "Speech Synthesis",
url: "23_speechsynth/index.html",
img: "23 - Speech Synthesis/image/23_port.jpg"
},
{
title: "Sticky Nav & Parallax",
url: "24_stickynav/index.html",
img: "24 - Sticky Nav/image/24_port.jpg"
},
{
title: "Stripe Follow Along Nav",
url: "26_followalongnav/index.html",
img: "26 - Stripe Follow Along Nav/image/26_port.jpg"
},
{
title: "Click and Drag",
url: "27_clickdrag/index.html",
img: "27 - Click and Drag/image/27_port.jpg"
},
{
title: "Video Speed Controller",
url: "28_vidspeed/index.html",
img: "28 - Video Speed Controller/image/28_port.jpg"
},
{
title: "Countdown Timer",
url: "29_countdown/index.html",
img: "29 - Countdown Timer/image/29_port.jpg"
},
{
title: "Whack A Mole",
url: "30_whackamole/index.html",
img: "30 - Whack A Mole/image/30_port.jpg"
}
];