8258ed804a
Standards Compliance / Secret Scanning (push) Successful in 3s
Standards Compliance / License Header Validation (push) Successful in 4s
Standards Compliance / Repository Structure Validation (push) Successful in 5s
Standards Compliance / Coding Standards Check (push) Failing after 3s
Standards Compliance / Version Consistency Check (push) Successful in 3s
Standards Compliance / Workflow Configuration Check (push) Failing after 2s
Standards Compliance / Documentation Quality Check (push) Successful in 3s
Standards Compliance / README Completeness Check (push) Successful in 3s
Standards Compliance / Git Repository Hygiene (push) Successful in 2s
Standards Compliance / Script Integrity Validation (push) Successful in 4s
Standards Compliance / Line Length Check (push) Failing after 4s
Standards Compliance / File Naming Standards (push) Successful in 2s
Standards Compliance / Insecure Code Pattern Detection (push) Successful in 3s
Standards Compliance / Code Complexity Analysis (push) Successful in 3s
Standards Compliance / Code Duplication Detection (push) Successful in 4s
Standards Compliance / Dead Code Detection (push) Successful in 3s
Standards Compliance / File Size Limits (push) Successful in 2s
CodeQL Security Scanning / Analyze (javascript) (push) Failing after 1m9s
Standards Compliance / Binary File Detection (push) Successful in 4s
CodeQL Security Scanning / Analyze (actions) (push) Failing after 1m11s
Standards Compliance / TODO/FIXME Tracking (push) Successful in 3s
Standards Compliance / Dependency Vulnerability Scanning (push) Successful in 5s
Standards Compliance / Broken Link Detection (push) Successful in 5s
Standards Compliance / Unused Dependencies Check (push) Successful in 7s
Standards Compliance / API Documentation Coverage (push) Successful in 3s
Standards Compliance / Accessibility Check (push) Successful in 3s
Standards Compliance / Performance Metrics (push) Successful in 3s
Standards Compliance / Enterprise Readiness Check (push) Successful in 3s
Standards Compliance / Repository Health Check (push) Successful in 4s
Standards Compliance / Terraform Configuration Validation (push) Successful in 6s
CodeQL Security Scanning / Security Scan Summary (push) Successful in 1s
Standards Compliance / Compliance Summary (push) Successful in 1s
Repo Health / Access control (push) Successful in 1s
Repo Health / Release configuration (push) Failing after 3s
Repo Health / Scripts governance (push) Successful in 3s
Repo Health / Repository health (push) Failing after 3s
Auto-Update SHA Hash / Update SHA-256 Hash in updates.xml (release) Failing after 5s
All files renamed from mokocassiopeia to mokoonyx. Update server points to MokoOnyx repo. Bridge migration removed (clean standalone template). Version reset to 01.00.00. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
107 lines
3.1 KiB
PHP
107 lines
3.1 KiB
PHP
<?php
|
|
/**
|
|
* Copyright (C) 2025 Moko Consulting <hello@mokoconsulting.tech>
|
|
*
|
|
* This file is part of a Moko Consulting project.
|
|
*
|
|
* SPDX-License-Identifier: GPL-3.0-or-later
|
|
*/
|
|
|
|
/**
|
|
* Main Menu - Mobile responsive collapsible dropdown menu override
|
|
* Bootstrap 5 responsive navbar with hamburger menu
|
|
*/
|
|
|
|
defined('_JEXEC') or die;
|
|
|
|
use Joomla\CMS\Helper\ModuleHelper;
|
|
|
|
$id = '';
|
|
|
|
if ($tagId = $params->get('tag_id', '')) {
|
|
$id = ' id="' . $tagId . '"';
|
|
}
|
|
|
|
// Get module class suffix
|
|
$moduleclass_sfx = htmlspecialchars($params->get('moduleclass_sfx', ''), ENT_COMPAT, 'UTF-8');
|
|
|
|
// The menu class is deprecated. Use mod-menu instead
|
|
?>
|
|
<nav class="mod-menu mod-menu-main navbar navbar-expand-lg<?php echo $moduleclass_sfx; ?>"<?php echo $id; ?>>
|
|
<div class="container-fluid">
|
|
<!-- Hamburger toggle button for mobile -->
|
|
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#horizontalMenuCollapse-<?php echo $module->id; ?>" aria-controls="horizontalMenuCollapse-<?php echo $module->id; ?>" aria-expanded="false" aria-label="Toggle Menu">
|
|
<span class="fa-solid fa-bars" aria-hidden="true"></span>
|
|
</button>
|
|
|
|
<!-- Collapsible menu content -->
|
|
<div class="collapse navbar-collapse" id="horizontalMenuCollapse-<?php echo $module->id; ?>">
|
|
<ul class="navbar-nav mod-menu-main__list">
|
|
<?php foreach ($list as $i => &$item) :
|
|
$itemParams = $item->getParams();
|
|
$class = 'nav-item mod-menu-main__item item-' . $item->id;
|
|
|
|
if ($item->id == $default_id) {
|
|
$class .= ' default';
|
|
}
|
|
|
|
if ($item->id == $active_id || ($item->type === 'alias' && $itemParams->get('aliasoptions') == $active_id)) {
|
|
$class .= ' current';
|
|
}
|
|
|
|
if (in_array($item->id, $path)) {
|
|
$class .= ' active';
|
|
} elseif ($item->type === 'alias') {
|
|
$aliasToId = $itemParams->get('aliasoptions');
|
|
|
|
if (count($path) > 0 && $aliasToId == $path[count($path) - 1]) {
|
|
$class .= ' active';
|
|
} elseif (in_array($aliasToId, $path)) {
|
|
$class .= ' alias-parent-active';
|
|
}
|
|
}
|
|
|
|
if ($item->type === 'separator') {
|
|
$class .= ' divider';
|
|
}
|
|
|
|
if ($item->deeper) {
|
|
$class .= ' deeper dropdown';
|
|
}
|
|
|
|
if ($item->parent) {
|
|
$class .= ' parent';
|
|
}
|
|
|
|
echo '<li class="' . $class . '">';
|
|
|
|
switch ($item->type) :
|
|
case 'separator':
|
|
case 'component':
|
|
case 'heading':
|
|
case 'url':
|
|
require ModuleHelper::getLayoutPath('mod_menu', 'horizontal_' . $item->type);
|
|
break;
|
|
|
|
default:
|
|
require ModuleHelper::getLayoutPath('mod_menu', 'horizontal_url');
|
|
break;
|
|
endswitch;
|
|
|
|
// The next item is deeper.
|
|
if ($item->deeper) {
|
|
echo '<ul class="dropdown-menu mod-menu-main__dropdown">';
|
|
} elseif ($item->shallower) {
|
|
// The next item is shallower.
|
|
echo '</li>';
|
|
echo str_repeat('</ul></li>', $item->level_diff);
|
|
} else {
|
|
// The next item is on the same level.
|
|
echo '</li>';
|
|
}
|
|
endforeach;
|
|
?></ul>
|
|
</div>
|
|
</div>
|
|
</nav>
|