2024-05-28 18:33:32 -05:00
|
|
|
function rain() {
|
|
|
|
var html = ""
|
|
|
|
|
2024-06-26 18:16:19 -05:00
|
|
|
html += `<link rel="stylesheet" type="text/css" href="/themes/rain/style.css"> <script src="/themes/rain/script.js"></script>`
|
2024-06-23 16:09:39 -05:00
|
|
|
html += `<div class="rainStuff"><div class="rainContainer">`
|
2024-05-28 18:33:32 -05:00
|
|
|
|
|
|
|
var amount = 7
|
|
|
|
|
|
|
|
for (let index = 0; index < amount; index++) {
|
|
|
|
html += `<div class="rainDrop"></div>`
|
|
|
|
}
|
|
|
|
html += "<style>"
|
|
|
|
for (let index = 0; index < amount; index++) {
|
|
|
|
html += `
|
|
|
|
.rainDrop:nth-of-type(${index + 1}) {
|
2024-06-23 16:09:39 -05:00
|
|
|
animation: rainAnim${index} ${((Math.round(Math.random() * 10) / 10) * 0.3) + 0.6}s linear;
|
|
|
|
animation-delay: ${Math.round(Math.random() * 200) / 100}s;
|
2024-05-28 18:33:32 -05:00
|
|
|
animation-iteration-count: infinite;
|
2024-06-23 16:09:39 -05:00
|
|
|
animation-timing-function: cubic-bezier(0.47, 0, 0.745, 0.715);
|
2024-05-28 18:33:32 -05:00
|
|
|
}
|
|
|
|
`
|
2024-06-23 16:09:39 -05:00
|
|
|
|
|
|
|
var pos = 0
|
|
|
|
|
|
|
|
if (index % 2 == 0) {
|
|
|
|
pos = Math.random() * 30
|
|
|
|
} else {
|
|
|
|
pos = (Math.random() * 30) + 70
|
2024-05-28 18:33:32 -05:00
|
|
|
}
|
|
|
|
|
2024-06-23 16:09:39 -05:00
|
|
|
pos = Math.round(pos)
|
2024-05-28 18:33:32 -05:00
|
|
|
|
2024-06-23 16:09:39 -05:00
|
|
|
html += `@keyframes rainAnim${index} { `
|
2024-05-28 18:33:32 -05:00
|
|
|
html += `
|
2024-06-23 16:09:39 -05:00
|
|
|
0% {
|
|
|
|
top: -20vh;
|
|
|
|
right: ${pos}%;
|
|
|
|
visibility: visible;
|
2024-05-28 18:33:32 -05:00
|
|
|
}
|
|
|
|
|
2024-06-23 16:09:39 -05:00
|
|
|
90% {
|
|
|
|
top: 110vh;
|
|
|
|
right: ${pos}%;
|
2024-05-28 18:33:32 -05:00
|
|
|
visibility: visible;
|
|
|
|
}
|
2024-06-23 16:09:39 -05:00
|
|
|
90.1% {
|
|
|
|
visibility: hidden;
|
2024-05-28 18:33:32 -05:00
|
|
|
}
|
2024-06-23 16:09:39 -05:00
|
|
|
`
|
2024-05-28 18:33:32 -05:00
|
|
|
|
|
|
|
html += `}`
|
|
|
|
|
|
|
|
}
|
|
|
|
html += "</style>"
|
|
|
|
html += "</div></div>"
|
|
|
|
|
|
|
|
return html
|
|
|
|
}
|
|
|
|
|
2024-06-23 19:03:11 -05:00
|
|
|
function purpleMagic() {
|
|
|
|
var html = ""
|
|
|
|
|
2024-06-26 18:16:19 -05:00
|
|
|
html += `<link rel="stylesheet" type="text/css" href="/themes/magic/style.css"> <script src="/themes/magic/script.js"></script>`
|
2024-06-23 19:03:11 -05:00
|
|
|
html += `<div class="magicStuff"><div class="magicContainer">`
|
|
|
|
|
2024-06-26 18:16:19 -05:00
|
|
|
var amount = 15
|
2024-06-23 19:03:11 -05:00
|
|
|
|
|
|
|
for (let index = 0; index < amount; index++) {
|
|
|
|
html += `<div class="particle"></div>`
|
|
|
|
}
|
|
|
|
html += "<style>"
|
|
|
|
for (let index = 0; index < amount; index++) {
|
|
|
|
html += `
|
|
|
|
.particle:nth-of-type(${index + 1}) {
|
|
|
|
animation: magic${index} ${((Math.round(Math.random() * 10) / 10) * 0.3) + 20}s linear, sway 4s cubic-bezier(0.445, 0.05, 0.55, 0.95) alternate;
|
|
|
|
animation-delay: ${Math.round(Math.random() * 100) / 100 * 20}s;
|
|
|
|
animation-iteration-count: infinite;
|
|
|
|
|
|
|
|
}
|
|
|
|
`
|
2024-06-26 18:16:19 -05:00
|
|
|
|
|
|
|
if (index % 2 == 0) {
|
|
|
|
html.replace("alternate", "alternate-reverse")
|
|
|
|
}
|
2024-06-23 19:03:11 -05:00
|
|
|
|
|
|
|
var pos = Math.round(Math.random() * 100)
|
|
|
|
|
|
|
|
html += `@keyframes magic${index} { `
|
|
|
|
|
|
|
|
html += `
|
|
|
|
0% {
|
|
|
|
top: 110vh;
|
|
|
|
right: ${pos}%;
|
|
|
|
visibility: visible;
|
|
|
|
}
|
2024-05-28 18:33:32 -05:00
|
|
|
|
2024-06-23 19:03:11 -05:00
|
|
|
90% {
|
|
|
|
top: -10vh;
|
|
|
|
right: ${pos}%;
|
|
|
|
visibility: visible;
|
|
|
|
}
|
|
|
|
90.1% {
|
|
|
|
visibility: hidden;
|
|
|
|
}
|
|
|
|
`
|
|
|
|
|
|
|
|
html += `}`
|
|
|
|
|
|
|
|
}
|
|
|
|
html += "</style>"
|
|
|
|
html += "</div></div>"
|
|
|
|
|
|
|
|
return html
|
2024-05-28 18:33:32 -05:00
|
|
|
}
|
|
|
|
|
2024-06-26 04:56:54 -05:00
|
|
|
function code() {
|
2024-06-29 16:08:25 -05:00
|
|
|
return '<link rel="stylesheet" type="text/css" href="/themes/code/style.css">' // <script src="/themes/code/script.js"></script>'
|
2024-06-26 04:56:54 -05:00
|
|
|
}
|
|
|
|
|
2024-07-04 19:49:23 -05:00
|
|
|
var events = []
|
|
|
|
events = events.concat(Array(10).fill(""))
|
|
|
|
events.push(rain())
|
|
|
|
|
|
|
|
events = events.concat(Array(10).fill(""))
|
|
|
|
events.push(purpleMagic())
|
2024-05-28 18:33:32 -05:00
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
returnTheme: function() {
|
|
|
|
var time = new Date()
|
2024-06-23 19:06:49 -05:00
|
|
|
return events[time.getDate() % events.length]
|
2024-05-28 18:33:32 -05:00
|
|
|
},
|
|
|
|
|
|
|
|
}
|