Suggested by Madriix in https://github.com/unrealircd/unrealircd-webpanel/pull/25
(but done a bit differently by me)
Ideally this 650px would not be hardcoded and it would detect if
the menu would overflow into the "footer", eg if you have X plugins
loaded. But for now this is fine and allows about 3 items more
so we're OK.. for now.
bottom: 0;
width: 100%;
height: 55px;
+ display: none !important;
}
.topnav {
text-align: center;
font-size: 1rem;
}
+
+/* Show version and 4-icons "footer" at bottom-left,
+ * if screen height is sufficient.
+ */
+@media only screen and (min-height: 650px) {
+ footer {
+ float: left;
+ width: 160px;
+ height: 60px;
+ display: block !important;
+ }
+
+ #sidebarlol {
+ height: calc(100% - 60px - 50px);
+ }
+}
-<footer class="text-center bg-dark text-white fixed-bottom d-none d-md-block" style="background-color: #f1f1f1;">
+<footer class="text-center bg-dark text-white fixed-bottom" style="background-color: #f1f1f1;">
<!-- Grid container -->
<div class="container">
<!-- Section: Social media -->
-
- <?php $arr = []; Hook::run(HOOKTYPE_PRE_FOOTER, $arr); ?>
- <section class="mt-1">
- <a href="https://unrealircd.org/" class="btn btn-default" style="color:white">© 1999-<?php echo date('Y'); ?> UnrealIRCd</a>
+ <?php
+ $arr = []; Hook::run(HOOKTYPE_PRE_FOOTER, $arr);
+ echo "<small style=\"font-size: 70%\"><code>Admin Panel ".WEBPANEL_VERSION."</code></small>";
+ ?>
+ <section class="mt-1">
<!-- Twitter -->
<a
- class="btn btn-link btn-floating btn-lg text-white"
+ class="btn btn-link btn-floating btn-md text-white"
href="https://twitter.com/Unreal_IRCd"
role="button"
data-mdb-ripple-color="dark"
+ target="_blank"
><i class="fab fa-twitter"></i
></a>
<!-- Github -->
<a
- class="btn btn-link btn-floating btn-lg text-white"
+ class="btn btn-link btn-floating btn-md text-white"
href="https://github.com/unrealircd/unrealircd-webpanel"
role="button"
data-mdb-ripple-color="dark"
+ target="_blank"
><i style="margin-left: -18px" class="fab fa-github"></i
></a>
<!-- UnrealIRCd -->
<a
href="https://unrealircd.org"
role="button"
- data-mdb-ripple-color="dark">
- <img src="<?php echo get_config("base_url"); ?>img/unreal.jpg" width="23" height="23" style="margin-right: 25px"></a>
+ data-mdb-ripple-color="dark"
+ target="_blank">
+ <img src="<?php echo get_config("base_url"); ?>img/unreal.jpg" width="16" height="16" style="margin-left: -7px; margin-right: 24px"></a>
- <i id="bugreport" style="margin-left: -18px; margin-right: 10px;" height="1000px" class="fa fa-bug" data-toggle="tooltip" data-placement="top" title="Report a bug (Opens in new tab)"></i>
+ <i id="bugreport" style="margin-left: -18px; margin-right: 10px;" height="10px" class="fa fa-bug" data-toggle="tooltip" data-placement="top" title="Report a bug (Opens in new tab)"></i>
<?php
window.addEventListener('resize', function() {
nav_resize_check();
});
-</script>
\ No newline at end of file
+</script>
function __construct()
{
Hook::func(HOOKTYPE_PRE_HEADER, 'file_auth::session_start');
- Hook::func(HOOKTYPE_FOOTER, 'file_auth::add_footer_info');
Hook::func(HOOKTYPE_USER_LOOKUP, 'file_auth::get_user');
Hook::func(HOOKTYPE_USERMETA_ADD, 'file_auth::add_usermeta');
Hook::func(HOOKTYPE_USERMETA_DEL, 'file_auth::del_usermeta');
}
}
- // duplicate code
- public static function add_footer_info($empty)
- {
- if (!($user = unreal_get_current_user()))
- return;
-
- else {
- echo "<code>Admin Panel v" . WEBPANEL_VERSION . "</code>";
- }
- }
-
public static function add_pre_overview_card($empty)
{
if (defined('DEFAULT_USER'))
{
self::create_tables();
Hook::func(HOOKTYPE_PRE_HEADER, 'sql_auth::session_start');
- Hook::func(HOOKTYPE_FOOTER, 'sql_auth::add_footer_info');
Hook::func(HOOKTYPE_USER_LOOKUP, 'sql_auth::get_user');
Hook::func(HOOKTYPE_USERMETA_ADD, 'sql_auth::add_usermeta');
Hook::func(HOOKTYPE_USERMETA_DEL, 'sql_auth::del_usermeta');
}
-
- public static function add_footer_info($empty)
- {
- if (!($user = unreal_get_current_user()))
- return;
-
- else {
- echo "<code>Admin Panel v" . WEBPANEL_VERSION . "</code>";
- }
- }
-
public static function add_pre_overview_card($empty)
{
if (defined('SQL_DEFAULT_USER'))