Skip to content

Commit

Permalink
Fix Colorscheme
Browse files Browse the repository at this point in the history
  • Loading branch information
coolcat-creations committed Apr 25, 2020
1 parent 8383d9c commit 313adc7
Show file tree
Hide file tree
Showing 11 changed files with 61 additions and 14 deletions.
1 change: 1 addition & 0 deletions administrator/language/en-GB/tpl_atum.ini
Expand Up @@ -15,6 +15,7 @@ TPL_ATUM_COLORS_SETTINGS_BG_LIGHT_LABEL="Light Background"
TPL_ATUM_COLORS_SETTINGS_CONTRAST_COLOR_LABEL="Contrast Colour"
TPL_ATUM_COLORS_SETTINGS_LABEL="Colour Settings"
TPL_ATUM_COLORS_SETTINGS_LINK_COLOR_LABEL="Link Colour"
TPL_ATUM_COLORS_SETTINGS_LINK_SIDEBAR_COLOR_LABEL="Sidebar Link Colour"
TPL_ATUM_COLORS_SETTINGS_MONOCHROME_LABEL="Set Colour to Monochrome"
TPL_ATUM_COLORS_SETTINGS_SPECIAL_COLOR_LABEL="Special Colour"
TPL_ATUM_COLORS_SETTINGS_TEXT_DARK_LABEL="Dark Text"
Expand Down
17 changes: 17 additions & 0 deletions administrator/templates/atum/Service/HTML/Atum.php
Expand Up @@ -106,6 +106,23 @@ public static function rootcolors(Registry $params): void
}
}

$sidebarLinkColor = $params->get('sidebar-link-color');

if (static::isHex($sidebarLinkColor))
{
try
{
$sidebarLinkColor = new Hex($sidebarLinkColor);

$root[] = '--atum-sidebar-link-color: ' . $sidebarLinkColor . ';';

}
catch (\Exception $ex)
{
// Just ignore exceptions
}
}

$specialColor = $params->get('special-color');

if (static::isHex($specialColor))
Expand Down
2 changes: 1 addition & 1 deletion administrator/templates/atum/images/logo-blue.svg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion administrator/templates/atum/login.php
Expand Up @@ -110,7 +110,7 @@
<section id="content" class="content h-100">
<main class="d-flex justify-content-center align-items-center h-100">
<div class="login">
<div class="main-brand text-center">
<div class="main-brand logo text-center">
<img src="<?php echo $loginLogo; ?>"
alt="<?php echo htmlspecialchars($this->params->get('altLoginLogo', ''), ENT_COMPAT, 'UTF-8'); ?>">
</div>
Expand Down
6 changes: 3 additions & 3 deletions administrator/templates/atum/scss/_variables.scss
Expand Up @@ -17,7 +17,7 @@ $black: #000; //used for shadows
$focuscolor: #39f; //used for focus color
$dark-blue: #001b4c; //is the atum-special-color
$light-blue: #2a69b8; //is the atum-link-color
$focusshadow: 0 0 0 .2rem #d3e2f5;
$focusshadow: 0 0 0 .2rem #eaeaea;

// BS Colours
$blue: hsl(213, 63, 44%); // base color for calculation, Primary-color
Expand Down Expand Up @@ -94,7 +94,7 @@ $alert-color-level: 0;
// Global
$atum-box-shadow: 0 2px 4px rgba(0, 0, 0, .16), 0 2px 4px rgba(0, 0, 0, .23);
$enable-rounded: true;
$input-box-shadow: inset 0 0 0 .1rem lighten(theme-color("atum-link-color"), 45%);
$input-box-shadow: inset 0 0 0 .1rem #e9e9e9;
$input-btn-padding-y: .6rem;
$input-btn-padding-x: 1rem;
$input-max-width: 100%;
Expand Down Expand Up @@ -231,7 +231,7 @@ $custom-select-multiple-padding-y: .3rem;

//input
$input-padding: .6rem 1rem;
$input-border: solid 1px #6d7784;
$input-border: solid 1px #c9c9c9;

// Modals
$modal-header-height: 2.875rem;
Expand Down
3 changes: 2 additions & 1 deletion administrator/templates/atum/scss/blocks/_global.scss
Expand Up @@ -182,7 +182,8 @@ a[target="_blank"]::before {
}

.text-muted {
color: var(--atum-text-dark);
color: var(--atum-text-dark)!important;
opacity: 0.7;
}

.card-columns {
Expand Down
5 changes: 5 additions & 0 deletions administrator/templates/atum/scss/blocks/_header.scss
Expand Up @@ -115,6 +115,11 @@
color: $white;
}

.text-muted {
color: var(--atum-text-light)!important;
opacity: 0.7;
}

a,
button {

Expand Down
22 changes: 19 additions & 3 deletions administrator/templates/atum/scss/blocks/_login.scss
Expand Up @@ -40,6 +40,17 @@
padding: 15px;
}

svg.joomla-logo {
background-size: 4.4rem 2.4rem;
height: 4.4rem;
width: 2.4rem;

path {
fill: var(--atum-bg-dark);
}

}

#form-login {

.form-group {
Expand All @@ -58,8 +69,9 @@
}

#btn-login-submit {
color: rgba(255, 255, 255, .8);
background: var(--atum-bg-dark);
color: var(--atum-text-light);
background-color: var(--atum-link-color);
border-color: var(--atum-link-color);
}
}

Expand Down Expand Up @@ -91,10 +103,14 @@
padding-bottom: 1rem;
margin: 0;
font-weight: bold;
color: var(--atum-special-color);
color: var(--atum-bg-dark);
text-align: center;
}

h2 {
color: var(--atum-text-dark);
}

.btn {

@include media-breakpoint-only(xs) {
Expand Down
2 changes: 1 addition & 1 deletion administrator/templates/atum/scss/blocks/_quickicons.scss
Expand Up @@ -19,7 +19,7 @@
margin: 0 auto;
font-size: $quickicon-icon-size;
color: transparent;
background: linear-gradient(var(--atum-link-color), #5693e1);
background: linear-gradient(var(--atum-link-color), var(--atum-link-hover-color));
background-clip: text;

&.big {
Expand Down
8 changes: 4 additions & 4 deletions administrator/templates/atum/scss/blocks/_toolbar.scss
Expand Up @@ -46,18 +46,18 @@

> span {
display: inline-block;
color: var(--subhead-btn-accent);
color: var(--atum-link-color);
}

&:not([disabled]):hover,
&:not([disabled]):active,
&:not([disabled]):focus {
color: rgba(255, 255, 255, .90);
background-color: var(--subhead-btn-accent);
border-color: var(--subhead-btn-accent);
background-color: var(--atum-link-color);
border-color: var(--atum-link-hover-color);

> span {
color: rgba(255, 255, 255, .90);
color: var(--atum-text-light);
}
}

Expand Down
7 changes: 7 additions & 0 deletions administrator/templates/atum/templateDetails.xml
Expand Up @@ -87,6 +87,13 @@
default="#2a69b8"
filter="color"
/>
<field
name="sidebar-link-color"
type="color"
label="TPL_ATUM_COLORS_SETTINGS_LINK_SIDEBAR_COLOR_LABEL"
default="#3b4a5c"
filter="color"
/>
<field
name="special-color"
type="color"
Expand Down

0 comments on commit 313adc7

Please sign in to comment.