better view on mobiles

This commit is contained in:
Karl 2025-06-06 11:21:32 +01:00
parent 2ff03fe101
commit a75c7c554a

View File

@ -1,12 +1,17 @@
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="UTF-8" /> <meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Create An Image</title> <title>Create An Image</title>
<style> <style>
/* ---------- reset ---------- */ /* ---------- reset ---------- */
* { margin: 0; padding: 0; box-sizing: border-box; } * {
margin: 0;
padding: 0;
box-sizing: border-box;
}
/* ---------- layout ---------- */ /* ---------- layout ---------- */
body { body {
@ -20,6 +25,7 @@
font-family: Arial, sans-serif; font-family: Arial, sans-serif;
padding: 20px; padding: 20px;
} }
textarea { textarea {
width: 80vw; width: 80vw;
height: 200px; height: 200px;
@ -33,12 +39,15 @@
color: #eee; color: #eee;
border: 1px solid #333; border: 1px solid #333;
} }
.button-group { .button-group {
display: flex; display: flex;
gap: 20px; gap: 20px;
align-items: center; align-items: center;
} }
button, select {
button,
select {
background: #333; background: #333;
color: white; color: white;
border: none; border: none;
@ -48,8 +57,11 @@
cursor: pointer; cursor: pointer;
transition: background 0.3s; transition: background 0.3s;
} }
button:hover, button:hover,
select:hover { background: #555; } select:hover {
background: #555;
}
/* ---------- spinner ---------- */ /* ---------- spinner ---------- */
#spinner-overlay { #spinner-overlay {
@ -62,6 +74,7 @@
visibility: hidden; visibility: hidden;
z-index: 1000; z-index: 1000;
} }
.spinner { .spinner {
width: 50px; width: 50px;
height: 50px; height: 50px;
@ -70,9 +83,39 @@
border-radius: 50%; border-radius: 50%;
animation: spin 0.8s linear infinite; animation: spin 0.8s linear infinite;
} }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes spin {
to {
transform: rotate(360deg);
}
}
@media (max-width: 600px) {
body {
min-height: 100dvh;
height: auto;
justify-content: flex-start;
padding-top: 40px;
}
.button-group {
flex-direction: column;
align-items: stretch;
width: 100%;
}
button,
select {
width: 100%;
}
textarea {
height: 150px;
}
}
</style> </style>
</head> </head>
<body> <body>
<h1 style="margin-bottom: 20px;">Create An Image</h1> <h1 style="margin-bottom: 20px;">Create An Image</h1>
@ -151,4 +194,5 @@
} }
</script> </script>
</body> </body>
</html> </html>