kernel_panic_web/kernelpanic.lol/templates/layout.html

166 lines
5.4 KiB
HTML
Raw Normal View History

<!DOCTYPE html>
<html>
<head>
2023-07-26 23:50:55 +00:00
<meta charset="UTF-8">
2023-06-26 01:34:19 +00:00
<title>{% block title %}{% endblock %}</title>
2023-09-13 22:28:13 +00:00
<style>
2023-07-26 23:50:55 +00:00
::-webkit-scrollbar {
display: none;
}
body, html {
height: 100%;
margin: 0;
display: flex;
align-items: center;
justify-content: center;
flex-direction: column;
2023-07-26 23:50:55 +00:00
margin-left: 10%;
margin-right: 10%;
width: 80vw;
scrollbar-width: none; /* For Firefox */
-ms-overflow-style: none;
2023-09-13 22:28:13 +00:00
{% block bgstuff %}
background-color: white;
{% endblock %}
}
#topbar {
width: 100%;
text-align: center;
border-bottom: 1px solid black;
2023-06-28 06:53:01 +00:00
position: sticky;
top:0;
2023-07-26 23:50:55 +00:00
animation: slideDown 3s backwards;
2023-06-28 06:53:01 +00:00
}
@keyframes slideDown {
0% {
2023-07-26 23:50:55 +00:00
left:0vw;
2023-06-28 06:53:01 +00:00
}
100% {
2023-07-26 23:50:55 +00:00
left:50vw;
2023-06-28 06:53:01 +00:00
}
}
.button {
display: inline-block;
padding: 10px;
border-right: 1px solid black;
transition: background-color 0.5s;
2023-06-26 01:34:19 +00:00
font-size: large;
}
a {
font-size: large;
color: black;
}
.button:hover {
background-color: #888;
}
.content {
2023-06-28 06:53:01 +00:00
padding-left: 10%;
padding-right: 10%;
text-align: justify;
2023-06-28 06:53:01 +00:00
overflow:scroll;
2023-07-26 23:50:55 +00:00
width:80vw;
2023-08-10 19:42:28 +00:00
font-size:large;
}
h1 {
text-align: left;
}
2023-07-26 23:50:55 +00:00
#footer {
color:inherit;
width: 100vw;
font-size: small;
-webkit-filter: invert(100%);
filter: invert(100%);
width: 100%;
text-align: center;
padding-left: 10px;
padding-right: 10px;
2023-09-13 22:28:13 +00:00
position: absolute;
display: block;
bottom: -75px;
2023-07-26 23:50:55 +00:00
background-color: inherit;
border-top: 1px solid #e7e7e7;
}
#footer a {
font-size: small;
-webkit-filter: invert(100%);
filter: invert(100%);
}
2023-08-16 07:39:28 +00:00
.content img {
max-width: 800px;
display: inline;
}
.content {
text-align: justify;
width: 80%;
}
</style>
</head>
2023-06-21 17:30:48 +00:00
<body>
2023-09-13 22:28:13 +00:00
<!-- Llegaste al código, a ver cáele al telegram -> [arroba]kprftw -->
<div id="topbar">
2023-06-26 01:34:19 +00:00
{% block topbar %}
<a href="/about"><div class="button">khe?</div></a>
2023-08-16 07:39:28 +00:00
<a href="/somos"><div class="button">quiénes?</div></a>
<a href="/blog"><div class="button">noticiones</div></a>
<a href="/miranomasesosproyectos"><div class="button">proyectazos</div></a>
2023-08-10 23:57:27 +00:00
<a href="https://pat.kernelpanic.lol/calendar/#/2/calendar/view/CH1zbFeFKLPO5SPle5JNxjKqdSaidbYPYBKFC4PDSus/"><div class="button">calendario</div></a>
<!-- Add more buttons as needed -->
2023-06-26 01:34:19 +00:00
{% endblock %}
</div>
2023-06-26 01:34:19 +00:00
<div class="content">
<h1>{{ this.title }}</h1>
2023-06-26 01:34:19 +00:00
{% block body %}{% endblock %}
</div>
<script>
document.body.addEventListener('click', function () {
var randomColor = 'rgb(' +
Math.floor(Math.random() * 256) + ',' +
Math.floor(Math.random() * 256) + ',' +
Math.floor(Math.random() * 256) + ')';
document.body.style.backgroundColor = randomColor;
document.getElementById('topbar').style.backgroundColor = randomColor;
2023-09-13 22:28:13 +00:00
var rgb = randomColor.match(/\d+/g).map(Number);
// Calculate the brightness of the color
var brightness = Math.round((parseInt(rgb[0]) * 299 + parseInt(rgb[1]) * 587 + parseInt(rgb[2]) * 114) / 1000);
// Choose black or white for the font color based on the brightness
var randomFontColor = brightness > 150 ? 'black' : 'white';
document.body.style.color = randomFontColor;
});
var buttons = document.querySelectorAll('.button');
buttons.forEach(function(button) {
2023-09-13 22:28:13 +00:00
button.addEventListener('mouseover', function() {
var randomColor = 'rgb(' +
Math.floor(Math.random() * 256) + ',' +
Math.floor(Math.random() * 256) + ',' +
Math.floor(Math.random() * 256) + ')';
2023-09-13 22:28:13 +00:00
// Convert the RGB color to an array of numbers
var rgb = randomColor.match(/\d+/g).map(Number);
// Calculate the brightness of the color
var brightness = Math.round((parseInt(rgb[0]) * 299 + parseInt(rgb[1]) * 587 + parseInt(rgb[2]) * 114) / 1000);
// Choose black or white for the font color based on the brightness
var randomFontColor = brightness > 150 ? 'black' : 'white';
this.style.backgroundColor = randomColor;
2023-09-13 22:28:13 +00:00
this.style.color = randomFontColor;
});
});
</script>
2023-07-26 23:50:55 +00:00
<div id="footer">
{% block footer %}
<p>Por la gracia de San iGNUcio desde el Cuarto de Máquinas @ 2023.</p>
<p>Contáctanos en <a href="https://twitter.com/botkernel">el twatter</a> para lo que se ocupe.</p>
{% endblock %}
</div>
2023-06-21 17:30:48 +00:00
</body>
</html>