]> git.joonet.de Git - adminer.git/commitdiff
Narrows screens: Move lang and logout under h1
authorJakub Vrana <jakub@vrana.cz>
Sun, 23 Feb 2025 10:18:28 +0000 (11:18 +0100)
committerJakub Vrana <jakub@vrana.cz>
Sun, 23 Feb 2025 10:25:07 +0000 (11:25 +0100)
adminer/include/adminer.inc.php
adminer/include/design.inc.php
adminer/static/default.css
compile.php
editor/include/adminer.inc.php

index 0297d97eae8093b72425ab5bed056e4239802c81..af07b5368bfa68587f0978b08bb3466b3ca4cbad 100644 (file)
@@ -955,6 +955,7 @@ class Adminer {
 </span>
 </h1>
 <?php
+               switch_lang();
                if ($missing == "auth") {
                        $output = "";
                        foreach ((array) $_SESSION["pwds"] as $vendor => $servers) {
index fd7b4498f8accf2081eaa777e3360c69d94eab75..b34fb180e989a90aadb581a1a81e6c911fcc63fa 100644 (file)
@@ -179,7 +179,10 @@ function page_footer($missing = "") {
        ?>
 </div>
 
-<?php switch_lang(); ?>
+<div id="menu">
+<?php $adminer->navigation($missing); ?>
+</div>
+
 <?php if ($missing != "auth") { ?>
 <form action="" method="post">
 <p class="logout">
@@ -189,9 +192,6 @@ function page_footer($missing = "") {
 </p>
 </form>
 <?php } ?>
-<div id="menu">
-<?php $adminer->navigation($missing); ?>
-</div>
 <?php
        echo script("setupSubmitHighlight(document);");
 }
index 095bb08c8f110de3c2a322a771033b147371f61f..986e41656977f222d61124f62c9a85f60fa7cfdf 100644 (file)
@@ -68,14 +68,14 @@ input.wayoff { left: -1000px; position: absolute; }
 .logout { margin-top: .5em; position: absolute; top: 0; right: 0; }
 .loadmore { margin-left: 1ex; }
 /* .edit used in designs */
-#menu { position: absolute; margin: 10px 0 0; padding: 0 0 30px 0; top: 2em; left: 0; width: 19em; }
+#menu { position: absolute; margin: 10px 0 0; top: 2em; left: 0; width: 19em; }
 #menu p, #logins, #tables { padding: .8em 1em; margin: 0; border-bottom: 1px solid #ccc; }
 #logins li, #tables li { list-style: none; }
 #dbs { overflow: hidden; }
 #logins, #tables { white-space: nowrap; overflow: hidden; }
 #logins a, #tables a, #tables span { background: #fff; }
 #content { margin: 2em 0 0 21em; padding: 10px 20px 20px 0; }
-#lang { position: absolute; top: 0; left: 0; line-height: 1.8em; padding: .3em 1em; }
+#lang { position: absolute; top: -2.6em; left: 0; padding: .3em 1em; }
 #breadcrumb { white-space: nowrap; position: absolute; top: 0; left: 21em; background: #eee; height: 2em; line-height: 1.8em; padding: 0 1em; margin: 0 0 0 -18px; }
 #h1 { color: #777; text-decoration: none; font-style: italic; }
 #version { color: red; }
@@ -96,10 +96,10 @@ input.wayoff { left: -1000px; position: absolute; }
 
 @media all and (max-width: 880px) {
        .pages { left: auto; }
-       .logout { position: static; padding: 0 1em; }
+       .logout { position: static; padding: 0 1em 1em; }
        #menu { position: static; width: auto; }
        #content { margin-left: 10px; }
-       #lang { position: static; border-top: 1px solid #999; }
+       #lang { position: static; }
        #breadcrumb { left: auto; }
        .rtl .pages { right: auto; }
        .rtl #content { margin-right: 10px; }
index c939f45aa30d3c7185d9ddef356948a770e747e9..821f43535ea9d15a8c17eb4bb843033546cffd97 100755 (executable)
@@ -431,7 +431,7 @@ $file = str_replace("\r", "", $file);
 if ($_SESSION["lang"]) {
        // single language version
        $file = preg_replace_callback("~(<\\?php\\s*echo )?lang\\('((?:[^\\\\']+|\\\\.)*)'([,)])(;\\s*\\?>)?~s", 'remove_lang', $file);
-       $file = str_replace("<?php switch_lang(); ?>\n", "", $file);
+       $file = str_replace("switch_lang();", "", $file);
        $file = str_replace('<?php echo $LANG; ?>', $_SESSION["lang"], $file);
 }
 $file = str_replace('<?php echo script_src("static/editing.js"); ?>' . "\n", "", $file);
index 8b8c44f8469c4f839e37fa87c768aa609f8e065d..92a64975b8bf9daafea775d7ee89f2a92153a0a2 100644 (file)
@@ -587,6 +587,7 @@ qsl('div').onclick = whisperClick;", "")
 </span>
 </h1>
 <?php
+               switch_lang();
                if ($missing == "auth") {
                        $first = true;
                        foreach ((array) $_SESSION["pwds"] as $vendor => $servers) {