-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
75 lines (69 loc) · 2.52 KB
/
index.html
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
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="initial-scale=1.0, width=device-width, maximum-scale=1, user-scalable=no" />
<link rel="shortcut icon" type="image/png" href="assets/favicon.png">
<link rel="stylesheet" href="src/css/main.css">
<link rel="manifest" id="manifest">
<title>Alberto Elias</title>
<script>
const manifestJSON = {
"short_name": "Alberto Elias",
"name": "Alberto Elias",
"description": "My personal website",
"start_url": "/index.html"
}
const randomThemeInt = Math.floor(Math.random() * (4 - 1 + 1) + 1)
switch (randomThemeInt) {
case 1:
document.documentElement.classList.add('yellow-theme');
manifestJSON.background_color = '#FAE480'
manifestJSON.theme_color = '#FAE480'
break;
case 2:
document.documentElement.classList.add('green-theme');
manifestJSON.background_color = '#36855F'
manifestJSON.theme_color = '#36855F'
break;
case 3:
document.documentElement.classList.add('dark-theme');
manifestJSON.background_color = '#40484E'
manifestJSON.theme_color = '#40484E'
break;
case 4:
document.documentElement.classList.add('purple-theme');
manifestJSON.background_color = '#733667'
manifestJSON.theme_color = '#733667'
break;
}
const stringManifest = JSON.stringify(manifestJSON);
const blob = new Blob([stringManifest], {type: 'application/json'});
const manifestURL = URL.createObjectURL(blob);
document.querySelector('#manifest').setAttribute('href', manifestURL);
</script>
</head>
<body>
<svg style="display:none;" xmlns="http://www.w3.org/2000/svg">
<symbol id="arrow-right" height="24" width="24" viewBox="0 -960 960 960"><path d="M647-440H160v-80h487L423-744l57-56 320 320-320 320-57-56 224-224Z"/></symbol>
<symbol id="caret-right" height="24" width="24" viewBox="0 -960 960 960"><path d="m321-80-71-71 329-329-329-329 71-71 400 400L321-80Z"/></symbol>
</svg>
<div class="bio-wrapper">
<section class="bio"></section>
</div>
<div class="js-console-wrapper">
<section class="js-console hljs">
<div class="js-console-drag">
<span class="js-console-drag-divider"></span>
</div>
<ul class="js-console__commands"></ul>
<div class="js-console__input-wrapper">
<span class="js-console__input-gt">></span>
<input type="text" placeholder="Press enter to submit" class="js-console__input" autofocus>
</div>
</section>
</div>
<script src="src/js/vendor/highlight.pack.js"></script>
<script type="module" src="src/js/main.js"></script>
</body>
</html>