CSS changes for small screens

This commit is contained in:
Dusk 2021-09-21 22:50:09 +02:00
parent 61793bdb5f
commit e5c37f4ead
2 changed files with 29 additions and 19 deletions

View File

@ -24,20 +24,6 @@
//Check if home and back buttons are needed
if($currentdir != $basedir) {
echo("<div id=\"navigation\">");
echo("<a href=\"/\">Inici</a><br/>");
//Solve ocurrences where url has ?q=./
if (dirname($_GET["q"]) == ".") {
$parentdir = "";
}
else $parentdir = dirname($_GET["q"]);
echo("<a href=\"?q=" . $parentdir . "\">Arrere</a><br/>");
echo("</div>");
}
echo("<hr style=\"border:2px dashed #e87d3e; margin-bottom: 65px\"/>"); echo("<hr style=\"border:2px dashed #e87d3e; margin-bottom: 65px\"/>");
@ -84,6 +70,21 @@
} }
printf('<p class="path">/%s</p>', $_GET["q"]); printf('<p class="path">/%s</p>', $_GET["q"]);
//Check if home and back buttons are needed
if($currentdir != $basedir) {
echo("<div id=\"navigation\">");
echo("<a href=\"/\">Inici</a><br/>");
//Solve ocurrences where url has ?q=./
if (dirname($_GET["q"]) == ".") {
$parentdir = "";
}
else $parentdir = dirname($_GET["q"]);
echo("<a href=\"?q=" . $parentdir . "\">Arrere</a><br/>");
echo("</div>");
}
?> ?>
</body> </body>
</html> </html>

View File

@ -2,8 +2,8 @@ body {
background-color: #2e2e2e; background-color: #2e2e2e;
color: #d6d6d6; color: #d6d6d6;
font-family: "Courier New", monospace; font-family: "Courier New", monospace;
font-size: 1.1em; font-size: 1em;
margin: 75px 20%; margin: 75px 25%;
text-align: center; text-align: center;
} }
@ -41,15 +41,17 @@ a:hover {
bottom: 25px; bottom: 25px;
left: 25px; left: 25px;
background-color: #101010; background-color: #101010;
font-size: max(1.5vw, 1em);
} }
#files { #files {
padding: 20px; padding: 10px;
text-align: left; text-align: justify;
display: inline-block; display: inline-block;
border: 2px dashed #d6d6d6; border: 2px dashed #d6d6d6;
min-width: 400px;
background-color: #101010; background-color: #101010;
font-size: min(2.5vw, 1.4em);
} }
.path { .path {
@ -62,3 +64,10 @@ hr {
border: 1.5px solid #d6d6d6; border: 1.5px solid #d6d6d6;
} }
@media only screen and (max-width: 600px) {
body {
margin: 75px 15%;
}
#navigation {
position: static;
}