-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcontact.html
More file actions
138 lines (117 loc) · 6.59 KB
/
contact.html
File metadata and controls
138 lines (117 loc) · 6.59 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
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
138
<!DOCTYPE html>
<html lang="en">
<header>
<title>./m64.jar</title>
<!-- Heading thingies -->
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
<link rel="manifest" href="/site.webmanifest">
<meta name="msapplication-TileColor" content="#da532c">
<meta name="theme-color" content="#ffffff">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- Style -->
<link rel="stylesheet" href="style/contact.css?ver=4">
<!-- Fonts -->
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Alegreya+Sans+SC:wght@900&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css2?family=DM+Sans:wght@500&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css2?family=DM+Sans:wght@500&family=Noto+Sans+Mono:wght@100..900&family=Poppins&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css2?family=DM+Sans:wght@500&family=Noto+Sans+Mono:wght@100..900&family=Poppins&family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap" rel="stylesheet">
<script src="https://kit.fontawesome.com/2ef25d02cd.js" crossorigin="anonymous"></script>
<script defer src="app.js"></script>
</header>
<body>
<nav id="navbar">
<a class="link item" href="/">
<i class="fa-solid fa-user nav-icon"></i>
<span>About</span>
</a>
<a class="link item" href="/projects">
<i class="fa-solid fa-folder-open nav-icon"></i>
<span>Projects</span>
</a>
<a class="link item active" href="/contact">
<i class="fas fa-envelope-open nav-icon"></i>
<span>Contact</span>
</a>
<a class="link item" target="_blank" href="https://bmc.link/M64DiamondStar">
<i class="fa-solid fa-gem nav-icon"></i>
<span>Donate</span>
</a>
</nav>
<div id="wrapper">
<div class="page-content">
<div class="section-wrapper">
<section class="intro">
<h2 class="scramble"><i class="fa-solid fa-address-book"></i> Contact me</h2>
<p>There're a few ways to contact me. You can use SpigotMC, <br>E-Mail or Discord, but I'm most active on Discord if you're looking for a quick response.</p>
<div class="btn-row">
<a class="btn link" href= "mailto: info@m64.dev" target="_blank" rel="M64's Mail">
<i class="fa-solid fa-envelope"> Mail</i>
</a>
<a class="btn link" href="https://discord.com/invite/Scv9afJwXp" target="_blank" rel="M64's Hangout">
<i class="fa-brands fa-discord"> Discord</i>
</a>
<a class="btn link" href="https://www.spigotmc.org/members/m64diamondstar.551660/" target="_blank" rel="M64's Spigot">
<i class="fa-solid fa-faucet"> Spigot</i>
</a>
</div>
</section>
</div>
</div>
</div>
<script>
document.addEventListener("DOMContentLoaded", function() {
const elements = document.querySelectorAll('.scramble');
elements.forEach(element => scrambleText(element, 750)); // Total duration of 1.5 seconds
function scrambleText(element, duration) {
const originalHtml = element.innerHTML; // Store original HTML to restore later
const textNodes = getTextNodes(element);
let iteration = 0;
const chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789';
function update() {
let scrambledHtml = originalHtml;
// Scramble text nodes
textNodes.forEach(node => {
const originalText = node.textContent;
const scrambledText = originalText.split('').map((char, i) => {
if (char === ' ') return char; // Preserve spaces
if (iteration >= (duration / 60) / originalText.length * i) return char; // Reveal original characters progressively
return chars[Math.floor(Math.random() * chars.length)];
}).join('');
scrambledHtml = scrambledHtml.replace(originalText, scrambledText); // Update only the text part
});
element.innerHTML = scrambledHtml; // Apply scrambled text
iteration++;
if (iteration < (duration / 60)) {
setTimeout(update, 60); // Update every 60ms for smoother animation
} else {
element.innerHTML = originalHtml; // Restore original HTML
}
}
update();
}
// Helper function to get all text nodes within an element
function getTextNodes(element) {
const textNodes = [];
function walk(node) {
if (node.nodeType === Node.TEXT_NODE) {
textNodes.push(node);
} else if (node.nodeType === Node.ELEMENT_NODE) {
node.childNodes.forEach(walk);
}
}
walk(element);
return textNodes;
}
});
</script>
<footer>
<p>
© m64.dev <script>document.addEventListener('DOMContentLoaded', function() {document.getElementById("year").innerHTML = new Date().getFullYear();});</script><span id="year"></span>
</p>
</footer>
</body>
</html>