Skip to content

Commit

Permalink
Add initial changes for GOCDB skin
Browse files Browse the repository at this point in the history
  • Loading branch information
Sae126V committed Dec 7, 2024
1 parent 5474afb commit 2f08e8c
Show file tree
Hide file tree
Showing 66 changed files with 294 additions and 415 deletions.
33 changes: 0 additions & 33 deletions config/local_info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -123,31 +123,6 @@
<Scopes>show</Scopes>
</menus>

<!-- css
Provide names or hex colour values for the background as
implemented in lib\Gocdb_Services\Config.php (called by
docs\web_portal\css\web_portal.php).
[Note that these values are used as part of the dynamic css
style sheet fetched by the browser after the base html is
returned.]
Colours can be specified as CSS colour names -
https://www.w3schools.com/colors/colors_names.asp
or hex values.
Gradient direction supplied as
https://www.w3schools.com/csSref/func_linear-gradient.asp
supporting 2-way and diagonal gradients e.g. "to bottom"
and "to bottom left" are supported with up to 3 colours.
If a 3 colour specification is not required, specify
an empty 3rd element.
-->
<css>
<backgroundDirection>to bottom left</backgroundDirection>
<backgroundColour1>#F7F9FE</backgroundColour1>
<backgroundColour2>#DEE9FB</backgroundColour2>
<backgroundColour3>#D0DFF9</backgroundColour3>
<headingTextColour>#00AC00</headingTextColour>
</css>

<!-- name_mapping
Basic rather primitive gocdb entity name mapping.
Provide word mappings to be used to 'rename' gocdb entities for use in
Expand Down Expand Up @@ -204,14 +179,6 @@
<name>BIG_PROJECT</name>
</default_scope>
<css>
<backgroundDirection>to bottom</backgroundDirection>
<backgroundColour1>MidnightBlue</backgroundColour1>
<backgroundColour2>#76a3d6</backgroundColour2>
<backgroundColour3></backgroundColour3>
<headingTextColour>Sienna</headingTextColour>
</css>
<menus>
<Projects>hide</Projects>
<NGI>show</NGI>
Expand Down
13 changes: 0 additions & 13 deletions config/local_info.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -42,19 +42,6 @@

<xs:element name="API_all_auth_realms" type="xs:boolean" minOccurs="0"/>

<xs:element name="css" minOccurs="0">
<xs:complexType>
<xs:all>
<!-- Use string type to allow standard colour names -->
<xs:element name="backgroundColour1" type="xs:string"/>
<xs:element name="backgroundColour2" type="xs:string"/>
<xs:element name="backgroundColour3" type="xs:string"/>
<xs:element name="backgroundDirection" type="xs:string"/>
<xs:element name="headingTextColour" type="xs:string"/>

</xs:all>
</xs:complexType>
</xs:element>
<xs:element name="name_mapping" minOccurs="0">
<xs:complexType>
<xs:all>
Expand Down
174 changes: 0 additions & 174 deletions htdocs/landing/home.css

This file was deleted.

15 changes: 12 additions & 3 deletions htdocs/landing/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,22 @@
require_once __DIR__.'/../../lib/Gocdb_Services/Factory.php';
$configServ = \Factory::getConfigService();
$configServ->setLocalInfoOverride($_SERVER['SERVER_NAME']);
$origin = 'https://' . $_SERVER['HTTP_HOST'];
$brandingFilePAth = __DIR__ . '/../web_portal/css/branding.css';
?>
<!doctype html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>GOCDB</title>
<link rel="stylesheet" type="text/css" href="home.css" />
<link rel="stylesheet" type="text/css" href="<?php echo $origin; ?>/portal/css/web_portal.php" />
<?php

if (file_exists($brandingFilePAth)) {
echo '<link rel="stylesheet" type="text/css" href="'
. $origin . '/portal/css/branding.css" />';
}
?>
<link rel="SHORTCUT ICON" href="Logo-1.4-FavIcon-32x32.regional.ico" />
<link href="https://fonts.googleapis.com/css?family=PT+Sans" rel="stylesheet">
</head>
Expand Down Expand Up @@ -39,7 +48,7 @@
?>
</div>
<div style="width: 80%; margin-left: auto; margin-right: auto;">
<a href="/portal/" style="width:68%; font-size:1.7em" class="button">Access GOCDB using your IGTF X.509 Certificate</a>
<a href="/portal/" style="width:68%; font-size:1.7em" class="button gocdb_btn">Access GOCDB using your IGTF X.509 Certificate</a>
<p>or</p>
<p>Access GOCDB using one of the following:</p>
<div>
Expand All @@ -48,7 +57,7 @@
$egi_target = urlencode("https://" . $hostname . "/portal/");
$egi_redirect = "https://" . $hostname . "/Shibboleth.sso/Login?target=" . $egi_target;
?>
<a style="width:30%; display:inline-block; font-size:1.5em" href="<?php echo $egi_redirect; ?>" class="button">EGI Check-In</a>
<a style="width:30%; display:inline-block; font-size:1.5em" href="<?php echo $egi_redirect; ?>" class="button gocdb_btn">EGI Check-In</a>
</div>
<p>Browse the <a href="https://wiki.egi.eu/wiki/GOCDB" class="docLink hover">GOCDB documentation index</a> on the EGI wiki.</p>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ function Get_Standard_Top_Section_HTML($title = null)
if (!empty(\Factory::$properties['LOGOUTURL'])) {
$html .= "<div style='text-align: right;'>";
$html .= '<a href="' . htmlspecialchars(\Factory::$properties['LOGOUTURL']) .
'"><b><font class="btn btn-danger btn-xs">Logout</font></b></a>';
'"><b><font class="btn btn-danger btn-xs gocdb_btn_danger">Logout</font></b></a>';
$html .= "</div>";
}

Expand Down Expand Up @@ -106,7 +106,8 @@ function Get_Search_Form_HTML()
$html .= '<form class="Indented" method="post" ' .
'action="index.php?Page_Type=Search">';
$html .= '<input type="text" name="SearchString" class="Search"/>';
$html .= '<input type="submit" value="Submit" class="Search_Button"/>';
$html .= '<input type="submit" value="Submit"';
$html .= 'class="Search_Button gocdb_btn gocdb_btn_props"/>';
$html .= '</form>';
return $html;
}
Expand Down
Loading

0 comments on commit 2f08e8c

Please sign in to comment.