kernel_panic_web/kernelpanic.lol/templates/layout.html

93 lines
2.6 KiB
HTML
Raw Normal View History

<!DOCTYPE html>
<html>
<head>
2023-06-26 01:34:19 +00:00
<title>{% block title %}{% endblock %}</title>
<style>
body, html {
height: 100%;
margin: 0;
display: flex;
align-items: center;
justify-content: center;
flex-direction: column;
}
#topbar {
width: 100%;
text-align: center;
border-bottom: 1px solid black;
2023-06-28 06:53:01 +00:00
position: sticky;
top:0;
animation: slideDown 2s forwards;
}
@keyframes slideDown {
0% {
top:50vh;
}
100% {
top:0;
}
}
.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;
}
h1 {
text-align: left;
}
2023-06-26 01:34:19 +00:00
</style>
</head>
2023-06-21 17:30:48 +00:00
<body>
2023-06-26 01:34:19 +00:00
<div id="topbar">
2023-06-26 01:34:19 +00:00
{% block topbar %}
<a href="/about"><div class="button">khe?</div></a>
<a href="/blog"><div class="button">noticiones</div></a>
<a href="/miranomasesosproyectos"><div class="button">proyectazos</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;
});
var buttons = document.querySelectorAll('.button');
buttons.forEach(function(button) {
button.addEventListener('click', function() {
var randomColor = 'rgb(' +
Math.floor(Math.random() * 256) + ',' +
Math.floor(Math.random() * 256) + ',' +
Math.floor(Math.random() * 256) + ')';
this.style.backgroundColor = randomColor;
});
});
</script>
2023-06-21 17:30:48 +00:00
</body>
</html>