]> git.mxchange.org Git - friendica.git/commitdiff
New home/login page style
authorfabrixxm <fabrix.xm@gmail.com>
Sun, 14 Jan 2018 17:45:00 +0000 (18:45 +0100)
committerfabrixxm <fabrix.xm@gmail.com>
Sun, 14 Jan 2018 17:45:00 +0000 (18:45 +0100)
view/theme/frio/css/style.css
view/theme/frio/img/login_bg.jpg [new file with mode: 0644]
view/theme/frio/php/default.php
view/theme/frio/style.php
view/theme/frio/templates/login.tpl

index f37c02e6369bc5d4a448c938f06c9d1e22fdd28f..2900a727f6aa00a37a9ff781ea6b158be6a2de5c 100644 (file)
@@ -3005,3 +3005,68 @@ section .profile-match-wrapper {
     float: left;
 }
 
+/** 
+ * Login page
+ */
+.mod-home.is-not-singleuser,
+.mod-login {
+    background-image: linear-gradient(to right, rgba(0,0,0, 0.7) , rgba(0,0,0, 0.4)), url($login_bg_image);
+    background-size: cover;
+    background-attachment: fixed;
+    background-position: center;
+    padding-top: 0;
+}
+.mod-home.is-not-singleuser nav.navbar,
+.mod-login nav.navbar { background-color: transparent }
+.mod-home.is-not-singleuser #topbar-second,
+.mod-login #topbar-second { 
+    background-color: transparent;
+    box-shadow: unset;
+    border: 0
+}
+.mod-home.is-not-singleuser #content > h1,
+.mod-login #content > h1 {
+    color: #eee;
+}
+
+@media screen and (min-width: 700px) {
+    .mod-home.is-not-singleuser #content > #login-form,
+    .mod-login #content > #login-form {    
+        width: 50%;
+        background-color: #fff;
+        color: #444;
+        padding: 1em;
+        float: right;
+        position: relative;
+        margin-top: 4em;
+    }
+
+    .mod-home.is-not-singleuser #content > #login-form:before,
+    .mod-login #content > #login-form:before {
+        display: block;
+        position: absolute;
+        content: " ";
+        background-color: rgba(255,255,255,0.1);
+        width:90%;
+        height: 110%;
+        top: -5%;
+        left: 5%;
+        z-index: -1;
+    }
+
+    .mod-home.is-not-singleuser #content > #login-form:after,
+    .mod-login #content > #login-form:after {
+        display: block;
+        position: absolute;
+        content: " ";
+        background-color: rgba(255,255,255,0.2);
+        width:80%;
+        height: 120%;
+        top: -10%;
+        left: 10%;
+        z-index: -1;
+    }
+}
+
+
+
diff --git a/view/theme/frio/img/login_bg.jpg b/view/theme/frio/img/login_bg.jpg
new file mode 100644 (file)
index 0000000..280c4e9
Binary files /dev/null and b/view/theme/frio/img/login_bg.jpg differ
index 768dd122f955b890cea575219bcd30ad81cc52a6..bcd11cc62a6e7c812a83ec7b383e898fb19fc38b 100644 (file)
@@ -54,9 +54,12 @@ if (!isset($minimal)) {
        }
        echo '
                <meta name="theme-color" content="' . $nav_bg . '" />';
+
+    $is_singleuser = Config::get('system','singleuser');
+    $is_singleuser_class = $is_singleuser ? "is-singleuser" : "is-not-singleuser";
 ?>
        </head>
-       <body id="top">
+       <body id="top" class="mod-<?php echo $a->module." ".$is_singleuser_class;?>">
                <a href="#content" class="sr-only sr-only-focusable">Skip to main content</a>
 <?php
        if (x($page, 'nav') && !$minimal) {
index a7b8c8a9d8fe56eb3aa754b323cf4a40ebed76da..2459277579c1a5a7d8e47a09629ab9b7c26af18b 100644 (file)
@@ -41,6 +41,7 @@ if ($a->module !== 'install') {
                $bgcolor          = Config::get("frio", "background_color");
                $contentbg_transp = Config::get("frio", "contentbg_transp");
                $background_image = Config::get("frio", "background_image");
+        $login_bg_image   = Config::get("frio", "login_bg_image");
                $bg_image_option  = Config::get("frio", "bg_image_option");
                $modified         = Config::get("frio", "css_modified");
 
@@ -96,6 +97,7 @@ $link_color       = (empty($link_color)       ? "#6fdbe8"      : $link_color);
 $bgcolor          = (empty($bgcolor)          ? "#ededed"      : $bgcolor);
 // The background image can not be empty. So we use a dummy jpg if no image was set.
 $background_image = (empty($background_image) ? 'img/none.jpg' : $background_image);
+$login_bg_image   = (empty($login_bg_image)   ? 'img/login_bg.jpg' : $login_bg_image);
 $modified         = (empty($modified)         ? time()         :$modified);
 
 $contentbg_transp = ((isset($contentbg_transp) && $contentbg_transp != "") ? $contentbg_transp : 100);
@@ -175,6 +177,7 @@ $options = array (
        '$contentbg_transp'            => $contentbg_transp,
        '$background_image'            => $background_image,
        '$background_size_img'         => $background_size_img,
+    '$login_bg_image'              => $login_bg_image,
 );
 
 $css_tpl = file_get_contents('view/theme/frio/css/style.css');
index a5e9b519e751775d9c15bde8112d101c69e11f98..1f818f5245b64d0903a9d9b9ccb3abe69fca4d6e 100644 (file)
@@ -20,7 +20,7 @@
 
                <div id="login-extra-links" class="list-unstyled">
                        {{if $register}}<a href="register" title="{{$register.title|escape:'html'}}" id="register-link">{{$register.desc}}</a>{{/if}}
-                       <a href="lostpass" title="{{$lostpass|escape:'html'}}" id="lost-password-link" class="pull-right">{{$lostlink}}</a>
+                       <a href="lostpass" title="{{$lostpass|escape:'html'}}" id="lost-password-link">{{$lostlink}}</a>
                </div>
 
                <div id="login-submit-wrapper" class="pull-right" >