Skip to content

Commit

Permalink
Merge pull request #387 from t3solution/5.3.7
Browse files Browse the repository at this point in the history
New release v5.3.7
  • Loading branch information
t3solution committed Mar 7, 2024
2 parents 551ab36 + b29501e commit 82d8c06
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 17 deletions.
16 changes: 14 additions & 2 deletions Classes/Controller/ConfigController.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,19 @@ public function initializeAction(): void
*/
public function listAction(bool $deleted = false, bool $created = false, bool $updateSss = false): ResponseInterface
{
if (empty($this->settings['sitepackage'])) {
$baseDir = GeneralUtility::getFileAbsFileName('fileadmin/T3SB/');
} else {
if (ExtensionManagementUtility::isLoaded('t3sb_package')) {
$baseDir = GeneralUtility::getFileAbsFileName('EXT:t3sb_package/T3SB/');
}
}
$cdnHint = false;
$file = $baseDir.'Resources/Public/Contrib/Bootstrap/scss/bootstrap.scss';
if (file_exists($file) && $this->settings['cdn']['enable']) {
$cdnHint = true;
}

if ($this->isSiteroot && $this->rootPageId) {
$pidList = parent::getTreeList($this->rootPageId, 999999, 0, '1');
$allConfig = [];
Expand Down Expand Up @@ -74,6 +87,7 @@ public function listAction(bool $deleted = false, bool $created = false, bool $u
$assignedOptions['updateScss'] = $updateSss;
$assignedOptions['deleted'] = $deleted;
$assignedOptions['created'] = $created;
$assignedOptions['cdnHint'] = $cdnHint;

if (!empty($this->settings['customScss']) && (int)$this->settings['customScss'] === 1) {
$customScss = parent::getCustomScss('custom-variables');
Expand Down Expand Up @@ -252,8 +266,6 @@ public function constantsAction(): ResponseInterface
} else {
if (ExtensionManagementUtility::isLoaded('t3sb_package')) {
$baseDir = GeneralUtility::getFileAbsFileName("EXT:t3sb_package/T3SB/");
} else {
throw new \InvalidArgumentException('Your t3sb_package is not loaded!', 1657464787);
}
}

Expand Down
6 changes: 5 additions & 1 deletion Classes/DataProcessing/ConfigProcessor.php
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,11 @@ public function process(ContentObjectRenderer $cObj, array $contentObjectConfigu
} elseif (($field === 'tx_t3sbootstrap_titlecolor' || $field === 'tx_t3sbootstrap_subtitlecolor') && str_starts_with($override, '--bs-')) {
$processedData['data'][$field] = 'var('.$override.')';
} else {
$processedData['data'][$field] = $override;
if ($processedData['data']['tx_t3sbootstrap_container'] === '0') {
// no override if container = none
} else {
$processedData['data'][$field] = $override;
}
}
}
}
Expand Down
18 changes: 5 additions & 13 deletions Configuration/FlexForms/CardSetting.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
<default>0</default>
</config>
</effect>

<effectColor>
<label>Card Hover Effect Color</label>
<displayCond>
Expand Down Expand Up @@ -82,7 +81,6 @@
<default>primary</default>
</config>
</effectColor>

<maxwidth>
<label>Card max-width == image width</label>
<displayCond>
Expand Down Expand Up @@ -316,26 +314,25 @@
<label>Horizontal</label>
<displayCond>
<and>
<numIndex index="0">FIELD:sDEF.multiImage.enable:=:0</numIndex>
<numIndex index="0">USER:T3SBS\T3sbootstrap\UserFunction\TcaMatcher->cardWrapperParent</numIndex>
<numIndex index="1">FIELD:sDEF.multiImage.enable:=:0</numIndex>
<numIndex index="1">FIELD:sDEF.tiling.enable:=:0</numIndex>
</and>
</displayCond>
<config>
<type>check</type>
</config>
</horizontal>

<tiling.enable>
<label>Tiling card with text and image</label>
<description>Best in 2 columns with the following setting "col-lg-6 col-md-12 col-12"</description>
<description>Only in 2 columns and best with the following setting "col-lg-6 col-md-12 col-12"</description>
<displayCond>USER:T3SBS\T3sbootstrap\UserFunction\TcaMatcher->twoColumnsParent</displayCond>
<onChange>reload</onChange>
<config>
<type>check</type>
<default>0</default>
</config>
</tiling.enable>

<tiling.position>
<label>Tiling position of the Image</label>
<displayCond>FIELD:sDEF.tiling.enable:=:1</displayCond>
Expand All @@ -352,18 +349,13 @@
<numIndex index="1">right</numIndex>
</numIndex>
</items>
<default>left</default>
<default>left</default>
</config>
</tiling.position>
<multiImage.enable>
<label>Enable Profile Card</label>
<description>You need at least two images for the profile card. The second is the circular, smaller image</description>
<displayCond>
<and>
<numIndex index="0">FIELD:sDEF.horizontal:=:0</numIndex>
<numIndex index="1">FIELD:sDEF.tiling.enable:=:0</numIndex>
</and>
</displayCond>
<displayCond>FIELD:sDEF.tiling.enable:=:0</displayCond>
<onChange>reload</onChange>
<config>
<type>check</type>
Expand Down
5 changes: 5 additions & 0 deletions Resources/Private/Backend/Templates/Config/List.html
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,11 @@ <h3>Global pages override is set in Constant Editor:</h3>
</div>

<f:if condition="{admin}">
<f:if condition="{cdnHint}">
<div class="alert alert-danger text-center mt-4" role="alert">
You run the scheduler task "T3SB CDN to local" but did not deactivate "Enable CDN" in the Constant Editor!
</div>
</f:if>
<f:if condition="{settings.customScss}">
<f:then>
<f:if condition="{customScss}">
Expand Down
2 changes: 1 addition & 1 deletion ext_emconf.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
'title' => 'Bootstrap Components',
'description' => 'Startup extension to use bootstrap 5 classes, components and more out of the box. Example and info: www.t3sbootstrap.de',
'category' => 'templates',
'version' => '5.3.6',
'version' => '5.3.7',
'state' => 'stable',
'author' => 'Helmut Hackbarth',
'author_email' => 'typo3@t3solution.de',
Expand Down

0 comments on commit 82d8c06

Please sign in to comment.