You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
191 lines
4.4 KiB
HTML
191 lines
4.4 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>Infraordinary</title>
|
|
|
|
<style>
|
|
@font-face {
|
|
font-family: Montserrat;
|
|
src: url(Montserrat-VariableFont_wght.ttf);
|
|
}
|
|
html,
|
|
body {
|
|
margin: 0 0;
|
|
font-family: Montserrat;
|
|
padding: 0 0;
|
|
width: 100%;
|
|
height: 100%;
|
|
}
|
|
|
|
* {
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
body {
|
|
padding: 2rem;
|
|
}
|
|
|
|
h1,
|
|
h2,
|
|
h3 {
|
|
margin: 0 0;
|
|
text-align: center;
|
|
}
|
|
|
|
h2{
|
|
font-weight: 400;
|
|
}
|
|
|
|
|
|
|
|
main {
|
|
max-width: min(900px, calc(100vw - 4rem));
|
|
margin: 2rem auto;
|
|
}
|
|
|
|
|
|
button,
|
|
input[type="submit"] {
|
|
margin: 1rem auto;
|
|
background-color: black;
|
|
outline: none;
|
|
color: white;
|
|
padding: .5rem 1rem;
|
|
border-radius: 2px;
|
|
border: none;
|
|
z-index: 2;
|
|
cursor: pointer;
|
|
transition: .2s linear;
|
|
border: 2px solid black;
|
|
width: 100%;
|
|
font-weight: bolder;
|
|
}
|
|
|
|
button:hover,
|
|
input[type="submit"]:hover {
|
|
background-color: white;
|
|
border: 2px solid black;
|
|
color: black;
|
|
}
|
|
|
|
form {
|
|
display: flex;
|
|
flex-direction: column;
|
|
border: 2px dashed black;
|
|
margin: 2rem auto;
|
|
padding: 2rem;
|
|
gap: 1rem;
|
|
position: relative;
|
|
}
|
|
|
|
form[loading="true"] * {
|
|
opacity: 0;
|
|
}
|
|
|
|
@keyframes spinning {
|
|
0% {
|
|
transform: rotate(0deg);
|
|
}
|
|
|
|
100% {
|
|
transform: rotate(360deg);
|
|
}
|
|
}
|
|
|
|
form[loading="true"]:before {
|
|
content: "";
|
|
position: absolute;
|
|
width: 2rem;
|
|
height: 2rem;
|
|
border-top: 2px solid black;
|
|
border-left: 2px solid black;
|
|
border-radius: 100%;
|
|
z-index: 2;
|
|
top: calc(50% - 1rem);
|
|
left: calc(50% - 1rem);
|
|
transform: translate3d(-50%, -50%, 0);
|
|
animation: .5s linear infinite spinning;
|
|
}
|
|
|
|
.error {
|
|
color: red;
|
|
}
|
|
|
|
.title{
|
|
display: flex;
|
|
margin: auto;
|
|
position: relative;
|
|
margin-bottom: 20%;
|
|
font-size: .9rem;
|
|
}
|
|
|
|
|
|
.logo{
|
|
position: absolute;
|
|
right: -10%;
|
|
top: -20%;
|
|
z-index: -10;
|
|
opacity: 0.5;
|
|
max-width: 300px;
|
|
}
|
|
@media only screen and (min-width: 801px){
|
|
.logo{
|
|
right: 0;
|
|
opacity: 1;
|
|
top: -60%;
|
|
}
|
|
|
|
.title{
|
|
margin-bottom: 10%;
|
|
}
|
|
}
|
|
</style>
|
|
</head>
|
|
|
|
<body>
|
|
<main class="container">
|
|
|
|
<div class="title">
|
|
<h1>Ministry of the <br>Infra-Ordinary</h1>
|
|
<img src="iologo.svg" class="logo">
|
|
</div>
|
|
<h2>Upload your Infraordinary Observations:</h2>
|
|
<p>Help us broaden our perspectives on the infra-ordinary, and upload your media here!</p>
|
|
|
|
{% if error %}
|
|
<h1 class="error">Oops.. Something went wrong: {{ error }}!</h1>
|
|
{% endif %}
|
|
|
|
{% if submitted %}
|
|
<p>Thank you for your contribution!<br>
|
|
<b>Consider becoming an M.I.O Agent (see paper form)</b>
|
|
</p>
|
|
<a href="/">back</a>
|
|
|
|
{% else %}
|
|
|
|
<form method="POST" action="upload" enctype="multipart/form-data">
|
|
<input type="file" name="file" accept="image/*,video/*,audio/*" required>
|
|
<input type="submit">
|
|
</form>
|
|
|
|
{% endif %}
|
|
</main>
|
|
<script type="text/javascript">
|
|
window.addEventListener("DOMContentLoaded", function () {
|
|
var form = document.querySelector("form");
|
|
if (!form) return false
|
|
|
|
form.addEventListener("submit", function () {
|
|
console.log("submit")
|
|
form.setAttribute("loading", "true");
|
|
})
|
|
})
|
|
</script>
|
|
</body>
|
|
|
|
</html>
|