Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace theme variables with CSS variables #140

Merged
merged 1 commit into from
Sep 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ Changelog
-------------------------
- Fix #135: Fix gallery comment URL from notifications
- Fix: Add autofocus on edit (for HumHub 1.17 - see https://github.com/humhub/humhub/issues/7136)
- Enh #140: Replace theme variables with CSS variables

1.5.5 (December 22, 2023)
-------------------------
Expand Down
11 changes: 5 additions & 6 deletions views/custom-gallery/gallery_view.php
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?php

use \humhub\modules\comment\widgets\Comments;
use humhub\modules\comment\widgets\Comments;
use humhub\modules\content\components\ContentActiveRecord;
use humhub\modules\content\widgets\ContentObjectLinks;
use \humhub\modules\gallery\assets\Assets;
use humhub\modules\gallery\assets\Assets;
use humhub\modules\gallery\helpers\Url;
use humhub\modules\gallery\models\CustomGallery;
use humhub\modules\gallery\models\Media;
Expand All @@ -14,7 +14,6 @@
use humhub\libs\Html;
use humhub\modules\gallery\widgets\GalleryList;


/* @var CustomGallery $gallery */
/* @var Media[] $media */
/* @var boolean $showMore */
Expand All @@ -24,9 +23,9 @@
?>
<div id="gallery-container" class="panel panel-default">

<div class="panel-heading clearfix" style="background-color: <?= $this->theme->variable('background-color-secondary') ?>">
<div style="margin-right:40px;" class="pull-left">
<?= Yii::t('GalleryModule.base', '<strong>Gallery</strong> ') . Html::encode($gallery->title) ?>
<div class="panel-heading clearfix" style="background-color: var(--background-color-secondary)">
<div style="margin-right:40px" class="pull-left">
<?= Yii::t('GalleryModule.base', '<strong>Gallery</strong> {title}', ['title' => Html::encode($gallery->title)]) ?>
</div>

<?= GalleryMenu::widget(['gallery' => $gallery,
Expand Down
13 changes: 5 additions & 8 deletions views/stream-gallery/gallery_view.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,11 @@
* @link https://www.humhub.org/
* @copyright Copyright (c) 2015 HumHub GmbH & Co. KG
* @license https://www.humhub.com/licences
*
*
* @package humhub.modules.gallery.views
* @since 1.0
* @author Sebastian Stumpf
*/
?>

<?php

use humhub\modules\content\components\ContentActiveRecord;
use humhub\modules\file\models\File;
Expand All @@ -30,13 +27,13 @@
$bundle = Assets::register($this);

$description = ($container instanceof Space)
? Yii::t('GalleryModule.base', 'This gallery contains all posted media files from the space.')
? Yii::t('GalleryModule.base', 'This gallery contains all posted media files from the space.')
: Yii::t('GalleryModule.base', 'This gallery contains all posted media files from the profile.');
?>

<div id="gallery-container" class="panel panel-default">

<div class="panel-heading" style="background-color: <?= $this->theme->variable('background-color-secondary') ?>"><?= Yii::t('GalleryModule.base', '<strong>Gallery</strong> ') . Yii::t('GalleryModule.base', 'of posted media files') ?></div>
<div class="panel-heading" style="background-color: var(--background-color-secondary)"><?= Yii::t('GalleryModule.base', '<strong>Gallery</strong> of posted media files') ?></div>

<div class="panel-body">
<div class="row">
Expand All @@ -51,8 +48,8 @@
<?= GalleryList::widget([
'entryList' => $files,
'parentGallery' => $gallery,
'showMore' => $showMore
'showMore' => $showMore,
]) ?>
</div>
</div>
</div>
</div>
Loading