first commit

This commit is contained in:
2025-06-17 11:53:18 +02:00
commit 9f0f7ba12b
8804 changed files with 1369176 additions and 0 deletions

61
layouts/chromes/html5.php Normal file
View File

@ -0,0 +1,61 @@
<?php
/**
* @package Joomla.Site
* @subpackage Layout
*
* @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*
* html5 (chosen html5 tag and font header tags)
*/
defined('_JEXEC') or die;
use Joomla\Utilities\ArrayHelper;
$module = $displayData['module'];
$params = $displayData['params'];
$attribs = $displayData['attribs'];
if ((string) $module->content === '') {
return;
}
$moduleTag = htmlspecialchars($params->get('module_tag', 'div'), ENT_QUOTES, 'UTF-8');
$moduleAttribs = [];
$moduleAttribs['class'] = 'moduletable ' . htmlspecialchars($params->get('moduleclass_sfx', ''), ENT_QUOTES, 'UTF-8');
$bootstrapSize = (int) $params->get('bootstrap_size', 0);
$moduleAttribs['class'] .= $bootstrapSize !== 0 ? ' col-md-' . $bootstrapSize : '';
$headerTag = htmlspecialchars($params->get('header_tag', 'h3'), ENT_QUOTES, 'UTF-8');
$headerClass = htmlspecialchars($params->get('header_class', ''), ENT_QUOTES, 'UTF-8');
$headerAttribs = [];
// Only output a header class if one is set
if ($headerClass !== '') {
$headerAttribs['class'] = $headerClass;
}
// Add class from attributes if any
if (!empty($attribs['class'])) {
$moduleAttribs['class'] .= ' ' . htmlspecialchars($attribs['class'], ENT_QUOTES, 'UTF-8');
}
// Only add aria if the moduleTag is not a div
if ($moduleTag !== 'div') {
if ($module->showtitle) :
$moduleAttribs['aria-labelledby'] = 'mod-' . $module->id;
$headerAttribs['id'] = 'mod-' . $module->id;
else :
$moduleAttribs['aria-label'] = $module->title;
endif;
}
$header = '<' . $headerTag . ' ' . ArrayHelper::toString($headerAttribs) . '>' . $module->title . '</' . $headerTag . '>';
?>
<<?php echo $moduleTag; ?> <?php echo ArrayHelper::toString($moduleAttribs); ?>>
<?php if ((bool) $module->showtitle) : ?>
<?php echo $header; ?>
<?php endif; ?>
<?php echo $module->content; ?>
</<?php echo $moduleTag; ?>>

13
layouts/chromes/none.php Normal file
View File

@ -0,0 +1,13 @@
<?php
/**
* @package Joomla.Site
* @subpackage Layout
*
* @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
echo $displayData['module']->content;

View File

@ -0,0 +1,35 @@
<?php
/**
* @package Joomla.Site
* @subpackage Layout
*
* @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
use Joomla\CMS\Factory;
use Joomla\CMS\Language\Text;
Factory::getApplication()->getDocument()
->getWebAssetManager()
->registerAndUseStyle('layouts.chromes.outline', 'layouts/chromes/outline.css');
$module = $displayData['module'];
?>
<div class="mod-preview">
<div class="mod-preview-info">
<div class="mod-preview-position">
<?php echo Text::sprintf('JGLOBAL_PREVIEW_POSITION', $module->position); ?>
</div>
<div class="mod-preview-style">
<?php echo Text::sprintf('JGLOBAL_PREVIEW_STYLE', $module->style); ?>
</div>
</div>
<div class="mod-preview-wrapper">
<?php echo $module->content; ?>
</div>
</div>

32
layouts/chromes/table.php Normal file
View File

@ -0,0 +1,32 @@
<?php
/**
* @package Joomla.Site
* @subpackage Layout
*
* @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*
* Module chrome that wraps the module in a table
*/
defined('_JEXEC') or die;
$module = $displayData['module'];
$params = $displayData['params'];
?>
<table
class="moduletable <?php echo htmlspecialchars($params->get('moduleclass_sfx', ''), ENT_COMPAT, 'UTF-8'); ?>">
<?php if ((bool) $module->showtitle) : ?>
<tr>
<th>
<?php echo $module->title; ?>
</th>
</tr>
<?php endif; ?>
<tr>
<td>
<?php echo $module->content; ?>
</td>
</tr>
</table>