added social media icons to login page

This commit is contained in:
Ralf Becker 2014-07-24 14:44:07 +00:00
parent 47506d6def
commit 25a4e26364
4 changed files with 67 additions and 7 deletions

View File

@ -2089,7 +2089,7 @@ html * {
html { html {
margin: 0px !important; margin: 0px !important;
padding: 0px !important; padding: 0px !important;
width: 99% !important; width: 99.9% !important;
height: 99% !important; height: 99% !important;
} }
body { body {
@ -2098,7 +2098,7 @@ body {
color: #000000; color: #000000;
margin: 0px !important; margin: 0px !important;
padding: 0px !important; padding: 0px !important;
width: 99% !important; width: 99.9% !important;
height: 99% !important; height: 99% !important;
font-size: 11px; font-size: 11px;
line-height: 1.28; line-height: 1.28;
@ -2118,6 +2118,14 @@ body {
* @version $Id$ * @version $Id$
*/ */
@import-once "def_colors.less"; @import-once "def_colors.less";
#socialMedia {
float: right;
position: relative;
top: -30px;
}
#socialMedia a {
margin-left: 10px;
}
/* ################################################################################## /* ##################################################################################
* login page * login page
*/ */

View File

@ -68,4 +68,18 @@ class pixelegg_framework extends jdots_framework
{ {
return egw_framework::_get_css(); return egw_framework::_get_css();
} }
/**
* displays a login screen
*
* Reimplemented to allow to include JSONP file with social media urls from egroupware.org
*
* @param string $extra_vars for login url
*/
function login_screen($extra_vars)
{
self::csp_script_src_attrs('https://www.egroupware.org');
return parent::login_screen($extra_vars);
}
} }

View File

@ -1,17 +1,47 @@
/* /*
* To change this license header, choose License Headers in Project Properties. * To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates * To change this template file, choose Tools | Templates
* and open the template in the editor. * and open the template in the editor.
*/ */
//egw_LAB.wait(function() { egw_LAB.wait(function() {
// $j(document).ready(function() { $j.ajax('https://www.egroupware.org/social.js', {
dataType: "jsonp",
jsonp: false,
jsonpCallback: "do_social",
cache: true
}).done(function(_data)
{
$j(document).ready(function() {
var social = $j(document.createElement('div'))
.attr({
id: "socialMedia",
class: "socialMedia"
})
.appendTo($j('#centerBox'));
for(var i=0; i < _data.length; ++i)
{
var data = _data[i];
var url = data.lang ? data.lang[$j('meta[name="language"]').attr('content')] : null || data.url;
$j(document.createElement('a')).attr({
href: url,
target: '_blank'
})
.appendTo(social)
.append($j(document.createElement('img'))
.attr('src', data.svg));
}
});
});
});
// $j('img.bgfade').hide(); // $j('img.bgfade').hide();
//// var dg_H = $j(window).height(); //// var dg_H = $j(window).height();
//// var dg_W = $j(window).width(); //// var dg_W = $j(window).width();
//// $j('#wrap').css({'height':dg_H,'width':dg_W}); //// $j('#wrap').css({'height':dg_H,'width':dg_W});
// //
// function anim() { // function anim() {
// $j("#wrap img.bgfade").first().appendTo('#wrap').fadeOut(3500); // $j("#wrap img.bgfade").first().appendTo('#wrap').fadeOut(3500);
// $j("#wrap img").first().fadeIn(3500); // $j("#wrap img").first().fadeIn(3500);
@ -20,5 +50,5 @@
//anim(); //anim();
//$j(window).resize(function(){window.location.href=window.location.href}); //$j(window).resize(function(){window.location.href=window.location.href});
// }); // });
// //
//}); //});

View File

@ -17,6 +17,14 @@
@import-once "def_colors.less"; @import-once "def_colors.less";
//############################################################################################################## //##############################################################################################################
#socialMedia {
float: right;
position: relative;
top: -30px;
}
#socialMedia a {
margin-left: 10px;
}
/* ################################################################################## /* ##################################################################################
* login page * login page