-
Notifications
You must be signed in to change notification settings - Fork 51
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replace theme variables with CSS variables
- Loading branch information
1 parent
dab90d8
commit 7a47431
Showing
7 changed files
with
11 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,18 @@ | ||
<?php | ||
|
||
|
||
namespace humhub\modules\custom_pages\widgets; | ||
|
||
use humhub\components\Widget; | ||
use humhub\modules\ui\view\components\Theme; | ||
|
||
/** | ||
* Class CustomPageInlineStyle for custom pages inline styling | ||
* @package modules\custom_pages\widgets | ||
*/ | ||
class CustomPageInlineStyle extends Widget | ||
{ | ||
/** | ||
* @var Theme | ||
*/ | ||
public $theme; | ||
|
||
public function run() | ||
{ | ||
$linkColor = $this->theme->variable('link', $this->theme->variable('info')); | ||
return $this->render('inline-style', [ | ||
'linkColor' => $linkColor, | ||
]); | ||
return $this->render('inline-style'); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,9 @@ | ||
<?php | ||
/* @var $linkColor string */ | ||
?> | ||
|
||
<style> | ||
.custom-pages-page a, .panel .panel-body p a { | ||
color: <?= $linkColor ?>; | ||
color: var(--link); | ||
} | ||
|
||
.custom-pages-page a:hover, .panel .panel-body p a:hover { | ||
color: <?= $linkColor ?>; | ||
color: var(--link); | ||
text-decoration: underline; | ||
} | ||
</style> | ||
|