Файловый менеджер - Редактировать - /home/opticamezl/www/newok/mod_menu.zip
Назад
PK �Q�\�V� index.htmlnu &1i� <!DOCTYPE html><title></title> PK �Q�\�28��# �# src/Helper/MenuHelper.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2009 Open Source Matters, Inc. <https://www.joomla.org> * @license GNU General Public License version 2 or later; see LICENSE.txt */ namespace Joomla\Module\Menu\Site\Helper; use Joomla\CMS\Cache\CacheControllerFactoryInterface; use Joomla\CMS\Cache\Controller\OutputController; use Joomla\CMS\Factory; use Joomla\CMS\Language\Multilanguage; use Joomla\CMS\Router\Route; // phpcs:disable PSR1.Files.SideEffects \defined('_JEXEC') or die; // phpcs:enable PSR1.Files.SideEffects /** * Helper for mod_menu * * @since 1.5 */ class MenuHelper { /** * Get a list of the menu items. * * @param \Joomla\Registry\Registry &$params The module options. * * @return array * * @since 1.5 */ public static function getList(&$params) { $app = Factory::getApplication(); $menu = $app->getMenu(); // Get active menu item $base = self::getBase($params); $levels = Factory::getUser()->getAuthorisedViewLevels(); asort($levels); // Compose cache key $cacheKey = 'menu_items' . $params . implode(',', $levels) . '.' . $base->id; /** @var OutputController $cache */ $cache = Factory::getContainer()->get(CacheControllerFactoryInterface::class) ->createCacheController('output', ['defaultgroup' => 'mod_menu']); if ($cache->contains($cacheKey)) { $items = $cache->get($cacheKey); } else { $path = $base->tree; $start = (int) $params->get('startLevel', 1); $end = (int) $params->get('endLevel', 0); $showAll = $params->get('showAllChildren', 1); $items = $menu->getItems('menutype', $params->get('menutype')); $hidden_parents = []; $lastitem = 0; if ($items) { $inputVars = $app->getInput()->getArray(); foreach ($items as $i => $item) { $item->parent = false; $itemParams = $item->getParams(); if (isset($items[$lastitem]) && $items[$lastitem]->id == $item->parent_id && $itemParams->get('menu_show', 1) == 1) { $items[$lastitem]->parent = true; } if ( ($start && $start > $item->level) || ($end && $item->level > $end) || (!$showAll && $item->level > 1 && !\in_array($item->parent_id, $path)) || ($start > 1 && !\in_array($item->tree[$start - 2], $path)) ) { unset($items[$i]); continue; } // Exclude item with menu item option set to exclude from menu modules if (($itemParams->get('menu_show', 1) == 0) || \in_array($item->parent_id, $hidden_parents)) { $hidden_parents[] = $item->id; unset($items[$i]); continue; } $item->current = true; foreach ($item->query as $key => $value) { if (!isset($inputVars[$key]) || $inputVars[$key] !== $value) { $item->current = false; break; } } $item->deeper = false; $item->shallower = false; $item->level_diff = 0; if (isset($items[$lastitem])) { $items[$lastitem]->deeper = ($item->level > $items[$lastitem]->level); $items[$lastitem]->shallower = ($item->level < $items[$lastitem]->level); $items[$lastitem]->level_diff = ($items[$lastitem]->level - $item->level); } $lastitem = $i; $item->active = false; $item->flink = $item->link; // Reverted back for CMS version 2.5.6 switch ($item->type) { case 'separator': break; case 'heading': // No further action needed. break; case 'url': if ((strpos($item->link, 'index.php?') === 0) && (strpos($item->link, 'Itemid=') === false)) { // If this is an internal Joomla link, ensure the Itemid is set. $item->flink = $item->link . '&Itemid=' . $item->id; } break; case 'alias': $item->flink = 'index.php?Itemid=' . $itemParams->get('aliasoptions'); // Get the language of the target menu item when site is multilingual if (Multilanguage::isEnabled()) { $newItem = Factory::getApplication()->getMenu()->getItem((int) $itemParams->get('aliasoptions')); // Use language code if not set to ALL if ($newItem != null && $newItem->language && $newItem->language !== '*') { $item->flink .= '&lang=' . $newItem->language; } } break; default: $item->flink = 'index.php?Itemid=' . $item->id; break; } if ((strpos($item->flink, 'index.php?') !== false) && strcasecmp(substr($item->flink, 0, 4), 'http')) { $item->flink = Route::_($item->flink, true, $itemParams->get('secure')); } else { $item->flink = Route::_($item->flink); } // We prevent the double encoding because for some reason the $item is shared for menu modules and we get double encoding // when the cause of that is found the argument should be removed $item->title = htmlspecialchars($item->title, ENT_COMPAT, 'UTF-8', false); $item->menu_icon = htmlspecialchars($itemParams->get('menu_icon_css', ''), ENT_COMPAT, 'UTF-8', false); $item->anchor_css = htmlspecialchars($itemParams->get('menu-anchor_css', ''), ENT_COMPAT, 'UTF-8', false); $item->anchor_title = htmlspecialchars($itemParams->get('menu-anchor_title', ''), ENT_COMPAT, 'UTF-8', false); $item->anchor_rel = htmlspecialchars($itemParams->get('menu-anchor_rel', ''), ENT_COMPAT, 'UTF-8', false); $item->menu_image = htmlspecialchars($itemParams->get('menu_image', ''), ENT_COMPAT, 'UTF-8', false); $item->menu_image_css = htmlspecialchars($itemParams->get('menu_image_css', ''), ENT_COMPAT, 'UTF-8', false); } if (isset($items[$lastitem])) { $items[$lastitem]->deeper = (($start ?: 1) > $items[$lastitem]->level); $items[$lastitem]->shallower = (($start ?: 1) < $items[$lastitem]->level); $items[$lastitem]->level_diff = ($items[$lastitem]->level - ($start ?: 1)); } } $cache->store($items, $cacheKey); } return $items; } /** * Get base menu item. * * @param \Joomla\Registry\Registry &$params The module options. * * @return object * * @since 3.0.2 */ public static function getBase(&$params) { // Get base menu item from parameters if ($params->get('base')) { $base = Factory::getApplication()->getMenu()->getItem($params->get('base')); } else { $base = false; } // Use active menu item if no base found if (!$base) { $base = self::getActive($params); } return $base; } /** * Get active menu item. * * @param \Joomla\Registry\Registry &$params The module options. * * @return object * * @since 3.0.2 */ public static function getActive(&$params) { $menu = Factory::getApplication()->getMenu(); return $menu->getActive() ?: self::getDefault(); } /** * Get default menu item (home page) for current language. * * @return object */ public static function getDefault() { $menu = Factory::getApplication()->getMenu(); // Look for the home menu if (Multilanguage::isEnabled()) { return $menu->getDefault(Factory::getLanguage()->getTag()); } return $menu->getDefault(); } } PK �Q�\9��ik k mod_menu.phpnu �[��� <?php /** * @package Joomla.Administrator * @subpackage mod_menu * * @copyright (C) 2006 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\Helper\ModuleHelper; use Joomla\Module\Menu\Administrator\Menu\CssMenu; $enabled = !$app->getInput()->getBool('hidemainmenu'); $menu = new CssMenu($app); $root = $menu->load($params, $enabled); $root->level = 0; // Render the module layout require ModuleHelper::getLayoutPath('mod_menu', $params->get('layout', 'default')); PK �Q�\��L� � mod_menu.xmlnu �[��� <?xml version="1.0" encoding="UTF-8"?> <extension type="module" client="administrator" method="upgrade"> <name>mod_menu</name> <author>Joomla! Project</author> <creationDate>2006-03</creationDate> <copyright>(C) 2006 Open Source Matters, Inc.</copyright> <license>GNU General Public License version 2 or later; see LICENSE.txt</license> <authorEmail>admin@joomla.org</authorEmail> <authorUrl>www.joomla.org</authorUrl> <version>3.0.0</version> <description>MOD_MENU_XML_DESCRIPTION</description> <namespace path="src">Joomla\Module\Menu</namespace> <files> <filename module="mod_menu">mod_menu.php</filename> <folder>src</folder> <folder>tmpl</folder> </files> <languages> <language tag="en-GB">language/en-GB/mod_menu.ini</language> <language tag="en-GB">language/en-GB/mod_menu.sys.ini</language> </languages> <help key="Admin_Modules:_Administrator_Menu" /> <config> <fields name="params"> <fieldset name="basic" addfieldprefix="Joomla\Component\Menus\Administrator\Field"> <field name="menutype" type="menu" label="MOD_MENU_FIELD_MENUTYPE_LABEL" clientid="1" > <option value="*">MOD_MENU_FIELD_MENUTYPE_OPTION_PREDEFINED</option> </field> <field name="preset" type="menuPreset" default="default" label="MOD_MENU_FIELD_PRESET_LABEL" description="MOD_MENU_FIELD_PRESET_DESC" showon="menutype:*" /> <field name="check" type="radio" label="MOD_MENU_FIELD_CHECK_LABEL" description="MOD_MENU_FIELD_CHECK_DESC" layout="joomla.form.field.radio.switcher" default="1" filter="integer" showon="menutype!:*" > <option value="0">JNO</option> <option value="1">JYES</option> </field> <field name="shownew" type="radio" label="MOD_MENU_FIELD_SHOWNEW" layout="joomla.form.field.radio.switcher" default="1" filter="integer" showon="menutype:*" > <option value="0">JHIDE</option> <option value="1">JSHOW</option> </field> <field name="showhelp" type="radio" label="MOD_MENU_FIELD_SHOWHELP" layout="joomla.form.field.radio.switcher" default="1" filter="integer" showon="menutype:*" > <option value="0">JHIDE</option> <option value="1">JSHOW</option> </field> <field name="forum_url" type="url" label="MOD_MENU_FIELD_FORUMURL_LABEL" description="MOD_MENU_FIELD_FORUMURL_DESC" filter="url" default="" showon="menutype:*" validate="url" /> </fieldset> <fieldset name="advanced"> <field name="layout" type="modulelayout" label="JFIELD_ALT_LAYOUT_LABEL" class="form-select" validate="moduleLayout" /> <field name="moduleclass_sfx" type="textarea" label="COM_MODULES_FIELD_MODULECLASS_SFX_LABEL" rows="3" validate="CssIdentifier" /> </fieldset> </fields> </config> </extension> PK �Q�\ٴ]a� � tmpl/collapse-default.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2021 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\HTML\HTMLHelper; use Joomla\CMS\Language\Text; HTMLHelper::_('bootstrap.collapse'); ?> <nav class="navbar navbar-expand-md" aria-label="<?php echo htmlspecialchars($module->title, ENT_QUOTES, 'UTF-8'); ?>"> <button class="navbar-toggler navbar-toggler-right" type="button" data-bs-toggle="collapse" data-bs-target="#navbar<?php echo $module->id; ?>" aria-controls="navbar<?php echo $module->id; ?>" aria-expanded="false" aria-label="<?php echo Text::_('MOD_MENU_TOGGLE'); ?>"> <span class="icon-menu" aria-hidden="true"></span> </button> <div class="collapse navbar-collapse" id="navbar<?php echo $module->id; ?>"> <?php require __DIR__ . '/default.php'; ?> </div> </nav> PK �Q�\��' tmpl/default_url.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2009 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\Filter\OutputFilter; use Joomla\CMS\HTML\HTMLHelper; $attributes = []; if ($item->anchor_title) { $attributes['title'] = $item->anchor_title; } if ($item->anchor_css) { $attributes['class'] = $item->anchor_css; } if ($item->anchor_rel) { $attributes['rel'] = $item->anchor_rel; } $linktype = $item->title; if ($item->menu_icon) { // The link is an icon if ($itemParams->get('menu_text', 1)) { // If the link text is to be displayed, the icon is added with aria-hidden $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span>' . $item->title; } else { // If the icon itself is the link, it needs a visually hidden text $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span><span class="visually-hidden">' . $item->title . '</span>'; } } elseif ($item->menu_image) { // The link is an image, maybe with an own class $image_attributes = []; if ($item->menu_image_css) { $image_attributes['class'] = $item->menu_image_css; } $linktype = HTMLHelper::_('image', $item->menu_image, $item->title, $image_attributes); if ($itemParams->get('menu_text', 1)) { $linktype .= '<span class="image-title">' . $item->title . '</span>'; } } if ($item->browserNav == 1) { $attributes['target'] = '_blank'; $attributes['rel'] = 'noopener noreferrer'; if ($item->anchor_rel == 'nofollow') { $attributes['rel'] .= ' nofollow'; } } elseif ($item->browserNav == 2) { $options = 'toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes,' . $params->get('window_open'); $attributes['onclick'] = "window.open(this.href, 'targetWindow', '" . $options . "'); return false;"; } echo HTMLHelper::_('link', OutputFilter::ampReplace(htmlspecialchars($item->flink, ENT_COMPAT, 'UTF-8', false)), $linktype, $attributes); PK �Q�\L�J] tmpl/default.phpnu �[��� <?php /** * @package Joomla.Administrator * @subpackage mod_menu * * @copyright (C) 2009 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\Helper\ModuleHelper; use Joomla\CMS\Language\Text; $doc = $app->getDocument(); $class = $enabled ? 'nav flex-column main-nav' : 'nav flex-column main-nav disabled'; /** @var Joomla\CMS\WebAsset\WebAssetManager $wa */ $wa = $doc->getWebAssetManager(); $wa->getRegistry()->addExtensionRegistryFile('com_cpanel'); $wa->useScript('metismenujs') ->registerAndUseScript('mod_menu.admin-menu', 'mod_menu/admin-menu.min.js', [], ['defer' => true], ['metismenujs']) ->useScript('com_cpanel.admin-system-loader'); // Recurse through children of root node if they exist if ($root->hasChildren()) { echo '<nav class="main-nav-container" aria-label="' . Text::_('MOD_MENU_ARIA_MAIN_MENU') . '">'; echo '<ul id="menu' . $module->id . '" class="' . $class . '">' . "\n"; // WARNING: Do not use direct 'include' or 'require' as it is important to isolate the scope for each call $menu->renderSubmenu(ModuleHelper::getLayoutPath('mod_menu', 'default_submenu'), $root); echo "</ul></nav>\n"; } PK �Q�\�V� tmpl/index.htmlnu &1i� <!DOCTYPE html><title></title> PK �Q�\��� � tmpl/default_heading.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2012 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\HTML\HTMLHelper; $title = $item->anchor_title ? ' title="' . $item->anchor_title . '"' : ''; $anchor_css = $item->anchor_css ?: ''; $linktype = $item->title; if ($item->menu_icon) { // The link is an icon if ($itemParams->get('menu_text', 1)) { // If the link text is to be displayed, the icon is added with aria-hidden $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span>' . $item->title; } else { // If the icon itself is the link, it needs a visually hidden text $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span><span class="visually-hidden">' . $item->title . '</span>'; } } elseif ($item->menu_image) { // The link is an image, maybe with its own class $image_attributes = []; if ($item->menu_image_css) { $image_attributes['class'] = $item->menu_image_css; } $linktype = HTMLHelper::_('image', $item->menu_image, $item->title, $image_attributes); if ($itemParams->get('menu_text', 1)) { $linktype .= '<span class="image-title">' . $item->title . '</span>'; } } ?> <span class="mod-menu__heading nav-header <?php echo $anchor_css; ?>"<?php echo $title; ?>><?php echo $linktype; ?></span> PK �Q�\��:�� � tmpl/default_separator.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2009 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\HTML\HTMLHelper; $title = $item->anchor_title ? ' title="' . $item->anchor_title . '"' : ''; $anchor_css = $item->anchor_css ?: ''; $linktype = $item->title; if ($item->menu_icon) { // The link is an icon if ($itemParams->get('menu_text', 1)) { // If the link text is to be displayed, the icon is added with aria-hidden $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span>' . $item->title; } else { // If the icon itself is the link, it needs a visually hidden text $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span><span class="visually-hidden">' . $item->title . '</span>'; } } elseif ($item->menu_image) { // The link is an image, maybe with its own class $image_attributes = []; if ($item->menu_image_css) { $image_attributes['class'] = $item->menu_image_css; } $linktype = HTMLHelper::_('image', $item->menu_image, $item->title, $image_attributes); if ($itemParams->get('menu_text', 1)) { $linktype .= '<span class="image-title">' . $item->title . '</span>'; } } ?> <span class="mod-menu__separator separator <?php echo $anchor_css; ?>"<?php echo $title; ?>><?php echo $linktype; ?></span> PK �Q�\kWĉs s tmpl/default_component.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2009 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\Filter\OutputFilter; use Joomla\CMS\HTML\HTMLHelper; $attributes = []; if ($item->anchor_title) { $attributes['title'] = $item->anchor_title; } if ($item->anchor_css) { $attributes['class'] = $item->anchor_css; } if ($item->anchor_rel) { $attributes['rel'] = $item->anchor_rel; } if ($item->id == $active_id) { $attributes['aria-current'] = 'location'; if ($item->current) { $attributes['aria-current'] = 'page'; } } $linktype = $item->title; if ($item->menu_icon) { // The link is an icon if ($itemParams->get('menu_text', 1)) { // If the link text is to be displayed, the icon is added with aria-hidden $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span>' . $item->title; } else { // If the icon itself is the link, it needs a visually hidden text $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span><span class="visually-hidden">' . $item->title . '</span>'; } } elseif ($item->menu_image) { // The link is an image, maybe with its own class $image_attributes = []; if ($item->menu_image_css) { $image_attributes['class'] = $item->menu_image_css; } $linktype = HTMLHelper::_('image', $item->menu_image, $item->title, $image_attributes); if ($itemParams->get('menu_text', 1)) { $linktype .= '<span class="image-title">' . $item->title . '</span>'; } } if ($item->browserNav == 1) { $attributes['target'] = '_blank'; } elseif ($item->browserNav == 2) { $options = 'toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes'; $attributes['onclick'] = "window.open(this.href, 'targetWindow', '" . $options . "'); return false;"; } echo HTMLHelper::_('link', OutputFilter::ampReplace(htmlspecialchars($item->flink, ENT_COMPAT, 'UTF-8', false)), $linktype, $attributes); PK u�\xɿ� � dropdown-metismenu_heading.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2020 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\HTML\HTMLHelper; use Joomla\Utilities\ArrayHelper; $attributes = []; if ($item->anchor_title) { $attributes['title'] = $item->anchor_title; } $attributes['class'] = 'mod-menu__heading nav-header'; $attributes['class'] .= $item->anchor_css ? ' ' . $item->anchor_css : null; $linktype = $item->title; if ($item->menu_icon) { // The link is an icon if ($itemParams->get('menu_text', 1)) { // If the link text is to be displayed, the icon is added with aria-hidden $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span>' . $item->title; } else { // If the icon itself is the link, it needs a visually hidden text $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span><span class="visually-hidden">' . $item->title . '</span>'; } } elseif ($item->menu_image) { // The link is an image, maybe with an own class $image_attributes = []; if ($item->menu_image_css) { $image_attributes['class'] = $item->menu_image_css; } $linktype = HTMLHelper::_('image', $item->menu_image, $item->title, $image_attributes); if ($itemParams->get('menu_text', 1)) { $linktype .= '<span class="image-title">' . $item->title . '</span>'; } } if ($showAll && $item->deeper) { $attributes['class'] .= ' mm-collapsed mm-toggler mm-toggler-nolink'; $attributes['aria-haspopup'] = 'true'; $attributes['aria-expanded'] = 'false'; echo '<button ' . ArrayHelper::toString($attributes) . '>' . $linktype . '</button>'; } else { echo '<span ' . ArrayHelper::toString($attributes) . '>' . $linktype . '</span>'; } PK u�\G�� � dropdown-metismenu.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2020 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\Helper\ModuleHelper; use Joomla\Utilities\ArrayHelper; /** @var \Joomla\CMS\WebAsset\WebAssetManager $wa */ $wa = $app->getDocument()->getWebAssetManager(); $wa->registerAndUseScript('metismenu', 'media/templates/site/cassiopeia/js/mod_menu/menu-metismenu.min.js', [], ['defer' => true], ['metismenujs']); $attributes = []; $attributes['class'] = 'mod-menu mod-menu_dropdown-metismenu metismenu mod-list ' . $class_sfx; if ($tagId = $params->get('tag_id', '')) { $attributes['id'] = $tagId; } $start = (int) $params->get('startLevel', 1); ?> <ul <?php echo ArrayHelper::toString($attributes); ?>> <?php foreach ($list as $i => &$item) { // Skip sub-menu items if they are set to be hidden in the module's options if (!$showAll && $item->level > $start) { continue; } $itemParams = $item->getParams(); $class = []; $class[] = 'metismenu-item item-' . $item->id . ' level-' . ($item->level - $start + 1); 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 ($showAll) { if ($item->deeper) { $class[] = 'deeper'; } if ($item->parent) { $class[] = 'parent'; } } echo '<li class="' . implode(' ', $class) . '">'; switch ($item->type) : case 'separator': case 'component': case 'heading': case 'url': require ModuleHelper::getLayoutPath('mod_menu', 'dropdown-metismenu_' . $item->type); break; default: require ModuleHelper::getLayoutPath('mod_menu', 'dropdown-metismenu_url'); endswitch; switch (true) : // The next item is deeper. case $showAll && $item->deeper: echo '<ul class="mm-collapse">'; break; // The next item is shallower. case $item->shallower: echo '</li>'; echo str_repeat('</ul></li>', $item->level_diff); break; // The next item is on the same level. default: echo '</li>'; break; endswitch; } ?></ul> PK u�\�`�� � dropdown-metismenu_separator.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2020 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\HTML\HTMLHelper; use Joomla\Utilities\ArrayHelper; $attributes = []; if ($item->anchor_title) { $attributes['title'] = $item->anchor_title; } $attributes['class'] = 'mod-menu__separator separator'; $attributes['class'] .= $item->anchor_css ? ' ' . $item->anchor_css : null; $linktype = $item->title; if ($item->menu_icon) { // The link is an icon if ($itemParams->get('menu_text', 1)) { // If the link text is to be displayed, the icon is added with aria-hidden $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span>' . $item->title; } else { // If the icon itself is the link, it needs a visually hidden text $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span><span class="visually-hidden">' . $item->title . '</span>'; } } elseif ($item->menu_image) { // The link is an image, maybe with an own class $image_attributes = []; if ($item->menu_image_css) { $image_attributes['class'] = $item->menu_image_css; } $linktype = HTMLHelper::_('image', $item->menu_image, $item->title, $image_attributes); if ($itemParams->get('menu_text', 1)) { $linktype .= '<span class="image-title">' . $item->title . '</span>'; } } if ($showAll && $item->deeper) { $attributes['class'] .= ' mm-collapsed mm-toggler mm-toggler-nolink'; $attributes['aria-haspopup'] = 'true'; $attributes['aria-expanded'] = 'false'; echo '<button ' . ArrayHelper::toString($attributes) . '>' . $linktype . '</button>'; } else { echo '<span ' . ArrayHelper::toString($attributes) . '>' . $linktype . '</span>'; } PK u�\`�'�, , dropdown-metismenu_component.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2020 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\Filter\OutputFilter; use Joomla\CMS\HTML\HTMLHelper; $attributes = []; if ($item->anchor_title) { $attributes['title'] = $item->anchor_title; } if ($item->anchor_css) { $attributes['class'] = $item->anchor_css; } if ($item->anchor_rel) { $attributes['rel'] = $item->anchor_rel; } if ($item->id == $active_id) { $attributes['aria-current'] = 'location'; if ($item->current) { $attributes['aria-current'] = 'page'; } } $linktype = $item->title; if ($item->menu_icon) { // The link is an icon if ($itemParams->get('menu_text', 1)) { // If the link text is to be displayed, the icon is added with aria-hidden $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span>' . $item->title; } else { // If the icon itself is the link, it needs a visually hidden text $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span><span class="visually-hidden">' . $item->title . '</span>'; } } elseif ($item->menu_image) { // The link is an image, maybe with an own class $image_attributes = []; if ($item->menu_image_css) { $image_attributes['class'] = $item->menu_image_css; } $linktype = HTMLHelper::_('image', $item->menu_image, $item->title, $image_attributes); if ($itemParams->get('menu_text', 1)) { $linktype .= '<span class="image-title">' . $item->title . '</span>'; } } if ($item->browserNav == 1) { $attributes['target'] = '_blank'; } elseif ($item->browserNav == 2) { $options = 'toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes'; $attributes['onclick'] = "window.open(this.href, 'targetWindow', '" . $options . "'); return false;"; } echo HTMLHelper::link(OutputFilter::ampReplace(htmlspecialchars($item->flink, ENT_COMPAT, 'UTF-8', false)), $linktype, $attributes); if ($showAll && $item->deeper) { echo '<button class="mm-collapsed mm-toggler mm-toggler-link" aria-haspopup="true" aria-expanded="false" aria-label="' . $item->title . '"></button>'; } PK u�\?v�< < dropdown-metismenu_url.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2020 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\Filter\OutputFilter; use Joomla\CMS\HTML\HTMLHelper; $attributes = []; if ($item->anchor_title) { $attributes['title'] = $item->anchor_title; } if ($item->anchor_css) { $attributes['class'] = $item->anchor_css; } if ($item->anchor_rel) { $attributes['rel'] = $item->anchor_rel; } $linktype = $item->title; if ($item->menu_icon) { // The link is an icon if ($itemParams->get('menu_text', 1)) { // If the link text is to be displayed, the icon is added with aria-hidden $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span>' . $item->title; } else { // If the icon itself is the link, it needs a visually hidden text $linktype = '<span class="p-2 ' . $item->menu_icon . '" aria-hidden="true"></span><span class="visually-hidden">' . $item->title . '</span>'; } } elseif ($item->menu_image) { // The link is an image, maybe with an own class $image_attributes = []; if ($item->menu_image_css) { $image_attributes['class'] = $item->menu_image_css; } $linktype = HTMLHelper::_('image', $item->menu_image, $item->title, $image_attributes); if ($itemParams->get('menu_text', 1)) { $linktype .= '<span class="image-title">' . $item->title . '</span>'; } } if ($item->browserNav == 1) { $attributes['target'] = '_blank'; $attributes['rel'] = 'noopener noreferrer'; if ($item->anchor_rel == 'nofollow') { $attributes['rel'] .= ' nofollow'; } } elseif ($item->browserNav == 2) { $options = 'toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes,' . $params->get('window_open'); $attributes['onclick'] = "window.open(this.href, 'targetWindow', '" . $options . "'); return false;"; } echo HTMLHelper::link(OutputFilter::ampReplace(htmlspecialchars($item->flink, ENT_COMPAT, 'UTF-8', false)), $linktype, $attributes); if ($showAll && $item->deeper) { echo '<button class="mm-collapsed mm-toggler mm-toggler-link" aria-haspopup="true" aria-expanded="false" aria-label="' . $item->title . '"></button>'; } PK u�\����� � collapse-metismenu.phpnu �[��� <?php /** * @package Joomla.Site * @subpackage mod_menu * * @copyright (C) 2021 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\HTML\HTMLHelper; use Joomla\CMS\Language\Text; HTMLHelper::_('bootstrap.collapse'); ?> <nav class="navbar navbar-expand-lg" aria-label="<?php echo htmlspecialchars($module->title, ENT_QUOTES, 'UTF-8'); ?>"> <button class="navbar-toggler navbar-toggler-right" type="button" data-bs-toggle="collapse" data-bs-target="#navbar<?php echo $module->id; ?>" aria-controls="navbar<?php echo $module->id; ?>" aria-expanded="false" aria-label="<?php echo Text::_('MOD_MENU_TOGGLE'); ?>"> <span class="icon-menu" aria-hidden="true"></span> </button> <div class="collapse navbar-collapse" id="navbar<?php echo $module->id; ?>"> <?php require __DIR__ . '/dropdown-metismenu.php'; ?> </div> </nav> PK � �\�o�k k js/menu-es5.min.jsnu �[��� (function(){"use strict";/** * @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org> * @license GNU General Public License version 2 or later; see LICENSE.txt */(function(){function v(u,r){var a=u.querySelector("ul");a&&(a.setAttribute("aria-hidden","false"),a.classList.add(r.menuHoverClass))}function h(u,r){var a=u.querySelector("ul");a&&(a.setAttribute("aria-hidden","true"),a.classList.remove(r.menuHoverClass))}function b(u){var r={menuHoverClass:"show-menu",dir:"ltr"},a=u.querySelectorAll(":scope > li");a.forEach(function(n){var o=n.querySelector("a");o&&(o.tabIndex="0",o.addEventListener("mouseover",v(n,r)),o.addEventListener("mouseout",h(n,r)));var d=n.querySelector("span");d&&(d.tabIndex="0",d.addEventListener("mouseover",v(n,r)),d.addEventListener("mouseout",h(n,r))),n.addEventListener("mouseover",function(t){var i=t.currentTarget,e=i.querySelector("ul");e&&(e.setAttribute("aria-hidden","false"),e.classList.add(r.menuHoverClass))}),n.addEventListener("mouseout",function(t){var i=t.currentTarget,e=i.querySelector("ul");e&&(e.setAttribute("aria-hidden","true"),e.classList.remove(r.menuHoverClass))}),n.addEventListener("focus",function(t){var i=t.currentTarget,e=i.querySelector("ul");e&&(e.setAttribute("aria-hidden","true"),e.classList.add(r.menuHoverClass))}),n.addEventListener("blur",function(t){var i=t.currentTarget,e=i.querySelector("ul");e&&(e.setAttribute("aria-hidden","false"),e.classList.remove(r.menuHoverClass))}),n.addEventListener("keydown",function(t){var i=t.key,e=t.target,s=e.parentElement,f=s.parentElement,c=s.previousElementSibling,l=s.nextElementSibling;if(c||(c=f.children[f.children.length-1]),!l){var g=f.children;l=g[0]}switch(i){case"ArrowLeft":t.preventDefault(),r.dir==="rtl"?l.children[0].focus():c.children[0].focus();break;case"ArrowRight":t.preventDefault(),r.dir==="rtl"?c.children[0].focus():l.children[0].focus();break;case"ArrowUp":{t.preventDefault();var m=s.parentElement.parentElement;m.nodeName==="LI"?m.children[0].focus():c.children[0].focus();break}case"ArrowDown":if(t.preventDefault(),s.classList.contains("parent")){var L=s.querySelector("ul");if(L!=null){var y=L.querySelector("li");y.children[0].focus()}else l.children[0].focus()}else l.children[0].focus();break}})})}document.addEventListener("DOMContentLoaded",function(){var u=document.querySelectorAll(".nav");[].forEach.call(u,function(r){b(r)})})})()})(); PK � �\C�i�" " js/menu-es5.min.js.gznu �[��� � ŕMo�8��,(L�[��� 1��t�ٞ�hjdqC���Ў�/d�qb���A�4�}f�(�,����%Bg�����G�b�x�n�c�B�wgo߳�c�&f���"�T��`���S��t:��?cy�"?.���BH�c����� �g��w����b`�XD� �,���E��聎��x��MD.P�'��Y��g7�RD���4��0*��d� :sҸ���^����(�MJ}�H���F�qx�.H�xn� a¼��0�xQz �J��yV��&NO� /*�]� ���!<�^�n�q�#�UuĞ�ͦ�a%uخ�pY�NGDEfp*x���m[o��Z�i>�9AKȋ�J�BZ&^4�,Y��ծv��eYu:�z._&_$_��w{����4)�!��@h����8Ȑ�sC��ٖ�ob���w?hmN�9�z9��ky�*N�~�{��Iъ4iPcӢ�<� PQ��ma�bN�؍x���Ix������~�.���m�����VyCjN����_� ���^o��i��6�ɹ5 �9b���&ޥ%���dOB�*�Zk��'��=�SKg ٵ��� �ܗ���� ���u�A�Ƽ;�UX��F�x�T�T�\��(�+�i��j���)]W�=��'&�1�q! ���r5��N{��j��C���t;oy��Q.�'`��K��r!U�yٻ����뗋��ESA��;Y�f����I���pY��8#�5ދ���| P.1�X^����o�k PK � �\�C : : js/admin-menu.jsnu �[��� /** * @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org> * @license GNU General Public License version 2 or later; see LICENSE.txt */ const allMenus = document.querySelectorAll('ul.main-nav'); allMenus.forEach(menu => { // eslint-disable-next-line no-new, no-undef new MetisMenu(menu); }); const wrapper = document.getElementById('wrapper'); const sidebar = document.getElementById('sidebar-wrapper'); const menuToggleIcon = document.getElementById('menu-collapse-icon'); // If the sidebar doesn't exist, for example, on edit views, then remove the "closed" class if (!sidebar) { wrapper.classList.remove('closed'); } if (sidebar && !sidebar.getAttribute('data-hidden')) { // Sidebar const menuToggle = document.getElementById('menu-collapse'); const firsts = [].slice.call(sidebar.querySelectorAll('.collapse-level-1')); // Apply 2nd level collapse firsts.forEach(first => { const seconds = [].slice.call(first.querySelectorAll('.collapse-level-1')); seconds.forEach(second => { if (second) { second.classList.remove('collapse-level-1'); second.classList.add('collapse-level-2'); } }); }); // Toggle menu menuToggle.addEventListener('click', event => { event.preventDefault(); wrapper.classList.toggle('closed'); menuToggleIcon.classList.toggle('icon-toggle-on'); menuToggleIcon.classList.toggle('icon-toggle-off'); const listItems = [].slice.call(document.querySelectorAll('.main-nav > li')); listItems.forEach(item => { item.classList.remove('open'); }); const elem = document.querySelector('.child-open'); if (elem) { elem.classList.remove('child-open'); } window.dispatchEvent(new CustomEvent('joomla:menu-toggle', { detail: wrapper.classList.contains('closed') ? 'closed' : 'open', bubbles: true, cancelable: true })); }); // Sidebar Nav const allLinks = wrapper.querySelectorAll('a.no-dropdown, a.collapse-arrow, .menu-dashboard > a'); const currentUrl = window.location.href; const mainNav = document.querySelector('ul.main-nav'); const menuParents = [].slice.call(document.querySelectorAll('ul.main-nav li.parent > a')); const subMenusClose = [].slice.call(document.querySelectorAll('ul.main-nav li.parent .close')); // Set active class allLinks.forEach(link => { if (!link.href.match(/index\.php$/) && currentUrl.indexOf(link.href) === 0 || link.href.match(/index\.php$/) && currentUrl.match(/index\.php$/)) { link.setAttribute('aria-current', 'page'); link.classList.add('mm-active'); // Auto Expand Levels if (!link.parentNode.classList.contains('parent')) { const firstLevel = link.closest('.collapse-level-1'); const secondLevel = link.closest('.collapse-level-2'); if (firstLevel) firstLevel.parentNode.classList.add('mm-active'); if (firstLevel) firstLevel.classList.add('mm-show'); if (secondLevel) secondLevel.parentNode.classList.add('mm-active'); if (secondLevel) secondLevel.classList.add('mm-show'); } } }); // Child open toggle const openToggle = ({ currentTarget }) => { let menuItem = currentTarget.parentNode; if (menuItem.tagName.toLowerCase() === 'span') { menuItem = currentTarget.parentNode.parentNode; } if (menuItem.classList.contains('open')) { mainNav.classList.remove('child-open'); menuItem.classList.remove('open'); } else { const siblings = [].slice.call(menuItem.parentNode.children); siblings.forEach(sibling => { sibling.classList.remove('open'); }); wrapper.classList.remove('closed'); if (menuToggleIcon.classList.contains('icon-toggle-off')) { menuToggleIcon.classList.toggle('icon-toggle-off'); menuToggleIcon.classList.toggle('icon-toggle-on'); } mainNav.classList.add('child-open'); if (menuItem.parentNode.classList.contains('main-nav')) { menuItem.classList.add('open'); } } window.dispatchEvent(new CustomEvent('joomla:menu-toggle', { detail: 'open', bubbles: true, cancelable: true })); }; menuParents.forEach(parent => { parent.addEventListener('click', openToggle); parent.addEventListener('keyup', openToggle); }); // Menu close subMenusClose.forEach(subMenu => { subMenu.addEventListener('click', () => { const menuChildsOpen = [].slice.call(mainNav.querySelectorAll('.open')); menuChildsOpen.forEach(menuChild => { menuChild.classList.remove('open'); }); mainNav.classList.remove('child-open'); }); }); } PK � �\'~T� � js/admin-menu-es5.min.jsnu �[��� (function(){"use strict";/** * @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org> * @license GNU General Public License version 2 or later; see LICENSE.txt */var d=document.querySelectorAll("ul.main-nav");d.forEach(function(e){new MetisMenu(e)});var c=document.getElementById("wrapper"),s=document.getElementById("sidebar-wrapper"),o=document.getElementById("menu-collapse-icon");if(s||c.classList.remove("closed"),s&&!s.getAttribute("data-hidden")){var u=document.getElementById("menu-collapse"),m=[].slice.call(s.querySelectorAll(".collapse-level-1"));m.forEach(function(e){var a=[].slice.call(e.querySelectorAll(".collapse-level-1"));a.forEach(function(l){l&&(l.classList.remove("collapse-level-1"),l.classList.add("collapse-level-2"))})}),u.addEventListener("click",function(e){e.preventDefault(),c.classList.toggle("closed"),o.classList.toggle("icon-toggle-on"),o.classList.toggle("icon-toggle-off");var a=[].slice.call(document.querySelectorAll(".main-nav > li"));a.forEach(function(t){t.classList.remove("open")});var l=document.querySelector(".child-open");l&&l.classList.remove("child-open"),window.dispatchEvent(new CustomEvent("joomla:menu-toggle",{detail:c.classList.contains("closed")?"closed":"open",bubbles:!0,cancelable:!0}))});var p=c.querySelectorAll("a.no-dropdown, a.collapse-arrow, .menu-dashboard > a"),i=window.location.href,n=document.querySelector("ul.main-nav"),v=[].slice.call(document.querySelectorAll("ul.main-nav li.parent > a")),f=[].slice.call(document.querySelectorAll("ul.main-nav li.parent .close"));p.forEach(function(e){if((!e.href.match(/index\.php$/)&&i.indexOf(e.href)===0||e.href.match(/index\.php$/)&&i.match(/index\.php$/))&&(e.setAttribute("aria-current","page"),e.classList.add("mm-active"),!e.parentNode.classList.contains("parent"))){var a=e.closest(".collapse-level-1"),l=e.closest(".collapse-level-2");a&&a.parentNode.classList.add("mm-active"),a&&a.classList.add("mm-show"),l&&l.parentNode.classList.add("mm-active"),l&&l.classList.add("mm-show")}});var r=function(a){var l=a.currentTarget,t=l.parentNode;if(t.tagName.toLowerCase()==="span"&&(t=l.parentNode.parentNode),t.classList.contains("open"))n.classList.remove("child-open"),t.classList.remove("open");else{var g=[].slice.call(t.parentNode.children);g.forEach(function(h){h.classList.remove("open")}),c.classList.remove("closed"),o.classList.contains("icon-toggle-off")&&(o.classList.toggle("icon-toggle-off"),o.classList.toggle("icon-toggle-on")),n.classList.add("child-open"),t.parentNode.classList.contains("main-nav")&&t.classList.add("open")}window.dispatchEvent(new CustomEvent("joomla:menu-toggle",{detail:"open",bubbles:!0,cancelable:!0}))};v.forEach(function(e){e.addEventListener("click",r),e.addEventListener("keyup",r)}),f.forEach(function(e){e.addEventListener("click",function(){var a=[].slice.call(n.querySelectorAll(".open"));a.forEach(function(l){l.classList.remove("open")}),n.classList.remove("child-open")})})}})(); PK � �\Jщ�� � js/menu-es5.jsnu �[��� (function () { 'use strict'; /** * @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org> * @license GNU General Public License version 2 or later; see LICENSE.txt */ (function () { function topLevelMouseOver(el, settings) { var ulChild = el.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'false'); ulChild.classList.add(settings.menuHoverClass); } } function topLevelMouseOut(el, settings) { var ulChild = el.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'true'); ulChild.classList.remove(settings.menuHoverClass); } } function setupNavigation(nav) { var settings = { menuHoverClass: 'show-menu', dir: 'ltr' }; var topLevelChilds = nav.querySelectorAll(':scope > li'); // Set tabIndex to -1 so that top_level_childs can't receive focus until menu is open topLevelChilds.forEach(function (topLevelEl) { var linkEl = topLevelEl.querySelector('a'); if (linkEl) { linkEl.tabIndex = '0'; linkEl.addEventListener('mouseover', topLevelMouseOver(topLevelEl, settings)); linkEl.addEventListener('mouseout', topLevelMouseOut(topLevelEl, settings)); } var spanEl = topLevelEl.querySelector('span'); if (spanEl) { spanEl.tabIndex = '0'; spanEl.addEventListener('mouseover', topLevelMouseOver(topLevelEl, settings)); spanEl.addEventListener('mouseout', topLevelMouseOut(topLevelEl, settings)); } topLevelEl.addEventListener('mouseover', function (_ref) { var currentTarget = _ref.currentTarget; var ulChild = currentTarget.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'false'); ulChild.classList.add(settings.menuHoverClass); } }); topLevelEl.addEventListener('mouseout', function (_ref2) { var currentTarget = _ref2.currentTarget; var ulChild = currentTarget.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'true'); ulChild.classList.remove(settings.menuHoverClass); } }); topLevelEl.addEventListener('focus', function (_ref3) { var currentTarget = _ref3.currentTarget; var ulChild = currentTarget.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'true'); ulChild.classList.add(settings.menuHoverClass); } }); topLevelEl.addEventListener('blur', function (_ref4) { var currentTarget = _ref4.currentTarget; var ulChild = currentTarget.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'false'); ulChild.classList.remove(settings.menuHoverClass); } }); topLevelEl.addEventListener('keydown', function (event) { var keyName = event.key; var curEl = event.target; var curLiEl = curEl.parentElement; var curUlEl = curLiEl.parentElement; var prevLiEl = curLiEl.previousElementSibling; var nextLiEl = curLiEl.nextElementSibling; if (!prevLiEl) { prevLiEl = curUlEl.children[curUlEl.children.length - 1]; } if (!nextLiEl) { var _curUlEl$children = curUlEl.children; nextLiEl = _curUlEl$children[0]; } switch (keyName) { case 'ArrowLeft': event.preventDefault(); if (settings.dir === 'rtl') { nextLiEl.children[0].focus(); } else { prevLiEl.children[0].focus(); } break; case 'ArrowRight': event.preventDefault(); if (settings.dir === 'rtl') { prevLiEl.children[0].focus(); } else { nextLiEl.children[0].focus(); } break; case 'ArrowUp': { event.preventDefault(); var parent = curLiEl.parentElement.parentElement; if (parent.nodeName === 'LI') { parent.children[0].focus(); } else { prevLiEl.children[0].focus(); } break; } case 'ArrowDown': event.preventDefault(); if (curLiEl.classList.contains('parent')) { var child = curLiEl.querySelector('ul'); if (child != null) { var childLi = child.querySelector('li'); childLi.children[0].focus(); } else { nextLiEl.children[0].focus(); } } else { nextLiEl.children[0].focus(); } break; } }); }); } document.addEventListener('DOMContentLoaded', function () { var navs = document.querySelectorAll('.nav'); [].forEach.call(navs, function (nav) { setupNavigation(nav); }); }); })(); })(); PK � �\��V�� � js/admin-menu-es5.min.js.gznu �[��� � �VMo�6��W0D!�Egs�U�ݦ�"@�-���0�����������$��{�4�GΛ7�d�֪��e|Aۀ$D�U����서�_�k��V�v������-yp�WH� F�A��$���� �`>���� H秗+(�ڀ���O� -z0�vl�"���}�Β�<1�$ �ۛ��k��r6��'�t���F�_��� ��Gcm��A����AU�`��sr�Q�;�-C��E�U��S���㯏7%�sM��r']�|���'�h�\9c� �k�,兞���2Qz��U�,�Yv����-!B^�DK9_�Z�#W�\ԣ���!uI*0��V��N ���(�E�KnZv �XH؇4|a���>R��f��^��|ɗ\�)|=CSn�d"Y�/TlV���~� �&2.6��tj6��z���y���6��4��N��D�!�ٓKb�2#_�"]���s`�R�*mʼ�.L��6e#G̵-�\�:4U�⛥�jCtu�N;����Q@Ţ��7�V�F�6����Ӱ�A����`��V������?�T{ ��K��ͭ �N�����ݕ��_�K�=ZWh��İ�<N�=H�=������-�hc�.&ߋ#W4&�4�C�'���8Y�N���%~�[6U�Àg����'�K��������,c(ÖÁא�֧�RA�&���a��TԳ<�uq���^ua��iaGC���$�[ ��eп���V���P�yZ)��q@;S� �\kޏ^� ]�fr���Em.���(#L�Fݭ�����,5��,�2����#�����}�8�T�&આ���e ͣ��t_�_Toؠx�v���w���|��#��w�m���_M'��.Ժ��7�#L���>�}��|l�]r1����߾c���k��������n$�%g�8�'~T� PK � �\q��R js/menu.min.js.gznu �[��� � ��QO9��>?D62���v���RJOG��xp�I�űS{���~�ӆ@��t��j<;�ߌ��s|xx@�G&юj$��s��ݟ��<�9j �"�$ȥג|�'�8>��f�{c�d���|B�t��|Q9�w8�Iy:��l��= �8�K� H��wuݓx���1^u���5��5��\�������58�"��Q^�N�y� ��dFU�ꨶƀ���K@��R;�R�&���r>����Λ��#�1o*G�)��2�,��|=�����6H����#m� �3�-� ]�,�rbO隥��,���ٗ��T�S������ �Xo ��;ftr�����%���H�H�)��O��z�(Oyi:f��~ f/ �vWcs�c�_U��/3�*n�t:��!�� w�����Ya/�nG��o�{�.���}������"���pU��������Vn=R:@��h�� 9-��v� ]9����e�Y�5ˏ�,WC�k�L�z���w�\��Gv�oJ��\��,�0��i���*;d\�46VUE#:z�WB'�raƋ�-Z"��r%�O�����Z��{i|��b�Za���߸� }0p�����/�ixk�͊墵Fa�lK��'���QY�}���y�������|v�4l�.����k�% ;�4�� :/������<xlcA0T�շi��7_o:�Ք���y�I��kwx՝O�4g�<�q� � PK � �\��.� � js/admin-menu.min.jsnu �[��� /** * @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org> * @license GNU General Public License version 2 or later; see LICENSE.txt */const allMenus=document.querySelectorAll("ul.main-nav");allMenus.forEach(o=>{new MetisMenu(o)});const wrapper=document.getElementById("wrapper"),sidebar=document.getElementById("sidebar-wrapper"),menuToggleIcon=document.getElementById("menu-collapse-icon");if(sidebar||wrapper.classList.remove("closed"),sidebar&&!sidebar.getAttribute("data-hidden")){const o=document.getElementById("menu-collapse");[].slice.call(sidebar.querySelectorAll(".collapse-level-1")).forEach(e=>{[].slice.call(e.querySelectorAll(".collapse-level-1")).forEach(l=>{l&&(l.classList.remove("collapse-level-1"),l.classList.add("collapse-level-2"))})}),o.addEventListener("click",e=>{e.preventDefault(),wrapper.classList.toggle("closed"),menuToggleIcon.classList.toggle("icon-toggle-on"),menuToggleIcon.classList.toggle("icon-toggle-off"),[].slice.call(document.querySelectorAll(".main-nav > li")).forEach(c=>{c.classList.remove("open")});const l=document.querySelector(".child-open");l&&l.classList.remove("child-open"),window.dispatchEvent(new CustomEvent("joomla:menu-toggle",{detail:wrapper.classList.contains("closed")?"closed":"open",bubbles:!0,cancelable:!0}))});const i=wrapper.querySelectorAll("a.no-dropdown, a.collapse-arrow, .menu-dashboard > a"),n=window.location.href,t=document.querySelector("ul.main-nav"),r=[].slice.call(document.querySelectorAll("ul.main-nav li.parent > a")),d=[].slice.call(document.querySelectorAll("ul.main-nav li.parent .close"));i.forEach(e=>{if((!e.href.match(/index\.php$/)&&n.indexOf(e.href)===0||e.href.match(/index\.php$/)&&n.match(/index\.php$/))&&(e.setAttribute("aria-current","page"),e.classList.add("mm-active"),!e.parentNode.classList.contains("parent"))){const s=e.closest(".collapse-level-1"),l=e.closest(".collapse-level-2");s&&s.parentNode.classList.add("mm-active"),s&&s.classList.add("mm-show"),l&&l.parentNode.classList.add("mm-active"),l&&l.classList.add("mm-show")}});const a=({currentTarget:e})=>{let s=e.parentNode;s.tagName.toLowerCase()==="span"&&(s=e.parentNode.parentNode),s.classList.contains("open")?(t.classList.remove("child-open"),s.classList.remove("open")):([].slice.call(s.parentNode.children).forEach(c=>{c.classList.remove("open")}),wrapper.classList.remove("closed"),menuToggleIcon.classList.contains("icon-toggle-off")&&(menuToggleIcon.classList.toggle("icon-toggle-off"),menuToggleIcon.classList.toggle("icon-toggle-on")),t.classList.add("child-open"),s.parentNode.classList.contains("main-nav")&&s.classList.add("open")),window.dispatchEvent(new CustomEvent("joomla:menu-toggle",{detail:"open",bubbles:!0,cancelable:!0}))};r.forEach(e=>{e.addEventListener("click",a),e.addEventListener("keyup",a)}),d.forEach(e=>{e.addEventListener("click",()=>{[].slice.call(t.querySelectorAll(".open")).forEach(l=>{l.classList.remove("open")}),t.classList.remove("child-open")})})} PK � �\�H�� � js/menu.jsnu �[��� /** * @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org> * @license GNU General Public License version 2 or later; see LICENSE.txt */ (() => { function topLevelMouseOver(el, settings) { const ulChild = el.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'false'); ulChild.classList.add(settings.menuHoverClass); } } function topLevelMouseOut(el, settings) { const ulChild = el.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'true'); ulChild.classList.remove(settings.menuHoverClass); } } function setupNavigation(nav) { const settings = { menuHoverClass: 'show-menu', dir: 'ltr' }; const topLevelChilds = nav.querySelectorAll(':scope > li'); // Set tabIndex to -1 so that top_level_childs can't receive focus until menu is open topLevelChilds.forEach(topLevelEl => { const linkEl = topLevelEl.querySelector('a'); if (linkEl) { linkEl.tabIndex = '0'; linkEl.addEventListener('mouseover', topLevelMouseOver(topLevelEl, settings)); linkEl.addEventListener('mouseout', topLevelMouseOut(topLevelEl, settings)); } const spanEl = topLevelEl.querySelector('span'); if (spanEl) { spanEl.tabIndex = '0'; spanEl.addEventListener('mouseover', topLevelMouseOver(topLevelEl, settings)); spanEl.addEventListener('mouseout', topLevelMouseOut(topLevelEl, settings)); } topLevelEl.addEventListener('mouseover', ({ currentTarget }) => { const ulChild = currentTarget.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'false'); ulChild.classList.add(settings.menuHoverClass); } }); topLevelEl.addEventListener('mouseout', ({ currentTarget }) => { const ulChild = currentTarget.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'true'); ulChild.classList.remove(settings.menuHoverClass); } }); topLevelEl.addEventListener('focus', ({ currentTarget }) => { const ulChild = currentTarget.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'true'); ulChild.classList.add(settings.menuHoverClass); } }); topLevelEl.addEventListener('blur', ({ currentTarget }) => { const ulChild = currentTarget.querySelector('ul'); if (ulChild) { ulChild.setAttribute('aria-hidden', 'false'); ulChild.classList.remove(settings.menuHoverClass); } }); topLevelEl.addEventListener('keydown', event => { const keyName = event.key; const curEl = event.target; const curLiEl = curEl.parentElement; const curUlEl = curLiEl.parentElement; let prevLiEl = curLiEl.previousElementSibling; let nextLiEl = curLiEl.nextElementSibling; if (!prevLiEl) { prevLiEl = curUlEl.children[curUlEl.children.length - 1]; } if (!nextLiEl) { [nextLiEl] = curUlEl.children; } switch (keyName) { case 'ArrowLeft': event.preventDefault(); if (settings.dir === 'rtl') { nextLiEl.children[0].focus(); } else { prevLiEl.children[0].focus(); } break; case 'ArrowRight': event.preventDefault(); if (settings.dir === 'rtl') { prevLiEl.children[0].focus(); } else { nextLiEl.children[0].focus(); } break; case 'ArrowUp': { event.preventDefault(); const parent = curLiEl.parentElement.parentElement; if (parent.nodeName === 'LI') { parent.children[0].focus(); } else { prevLiEl.children[0].focus(); } break; } case 'ArrowDown': event.preventDefault(); if (curLiEl.classList.contains('parent')) { const child = curLiEl.querySelector('ul'); if (child != null) { const childLi = child.querySelector('li'); childLi.children[0].focus(); } else { nextLiEl.children[0].focus(); } } else { nextLiEl.children[0].focus(); } break; } }); }); } document.addEventListener('DOMContentLoaded', () => { const navs = document.querySelectorAll('.nav'); [].forEach.call(navs, nav => { setupNavigation(nav); }); }); })(); PK � �\q� � js/menu.min.jsnu �[��� /** * @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org> * @license GNU General Public License version 2 or later; see LICENSE.txt */(()=>{function h(i,t){const n=i.querySelector("ul");n&&(n.setAttribute("aria-hidden","false"),n.classList.add(t.menuHoverClass))}function m(i,t){const n=i.querySelector("ul");n&&(n.setAttribute("aria-hidden","true"),n.classList.remove(t.menuHoverClass))}function v(i){const t={menuHoverClass:"show-menu",dir:"ltr"};i.querySelectorAll(":scope > li").forEach(s=>{const a=s.querySelector("a");a&&(a.tabIndex="0",a.addEventListener("mouseover",h(s,t)),a.addEventListener("mouseout",m(s,t)));const d=s.querySelector("span");d&&(d.tabIndex="0",d.addEventListener("mouseover",h(s,t)),d.addEventListener("mouseout",m(s,t))),s.addEventListener("mouseover",({currentTarget:r})=>{const e=r.querySelector("ul");e&&(e.setAttribute("aria-hidden","false"),e.classList.add(t.menuHoverClass))}),s.addEventListener("mouseout",({currentTarget:r})=>{const e=r.querySelector("ul");e&&(e.setAttribute("aria-hidden","true"),e.classList.remove(t.menuHoverClass))}),s.addEventListener("focus",({currentTarget:r})=>{const e=r.querySelector("ul");e&&(e.setAttribute("aria-hidden","true"),e.classList.add(t.menuHoverClass))}),s.addEventListener("blur",({currentTarget:r})=>{const e=r.querySelector("ul");e&&(e.setAttribute("aria-hidden","false"),e.classList.remove(t.menuHoverClass))}),s.addEventListener("keydown",r=>{const e=r.key,l=r.target.parentElement,f=l.parentElement;let u=l.previousElementSibling,c=l.nextElementSibling;switch(u||(u=f.children[f.children.length-1]),c||([c]=f.children),e){case"ArrowLeft":r.preventDefault(),t.dir==="rtl"?c.children[0].focus():u.children[0].focus();break;case"ArrowRight":r.preventDefault(),t.dir==="rtl"?u.children[0].focus():c.children[0].focus();break;case"ArrowUp":{r.preventDefault();const o=l.parentElement.parentElement;o.nodeName==="LI"?o.children[0].focus():u.children[0].focus();break}case"ArrowDown":if(r.preventDefault(),l.classList.contains("parent")){const o=l.querySelector("ul");o!=null?o.querySelector("li").children[0].focus():c.children[0].focus()}else c.children[0].focus();break}})})}document.addEventListener("DOMContentLoaded",()=>{const i=document.querySelectorAll(".nav");[].forEach.call(i,t=>{v(t)})})})(); PK � �\�+�� � js/admin-menu-es5.jsnu �[��� (function () { 'use strict'; /** * @copyright (C) 2019 Open Source Matters, Inc. <https://www.joomla.org> * @license GNU General Public License version 2 or later; see LICENSE.txt */ var allMenus = document.querySelectorAll('ul.main-nav'); allMenus.forEach(function (menu) { // eslint-disable-next-line no-new, no-undef new MetisMenu(menu); }); var wrapper = document.getElementById('wrapper'); var sidebar = document.getElementById('sidebar-wrapper'); var menuToggleIcon = document.getElementById('menu-collapse-icon'); // If the sidebar doesn't exist, for example, on edit views, then remove the "closed" class if (!sidebar) { wrapper.classList.remove('closed'); } if (sidebar && !sidebar.getAttribute('data-hidden')) { // Sidebar var menuToggle = document.getElementById('menu-collapse'); var firsts = [].slice.call(sidebar.querySelectorAll('.collapse-level-1')); // Apply 2nd level collapse firsts.forEach(function (first) { var seconds = [].slice.call(first.querySelectorAll('.collapse-level-1')); seconds.forEach(function (second) { if (second) { second.classList.remove('collapse-level-1'); second.classList.add('collapse-level-2'); } }); }); // Toggle menu menuToggle.addEventListener('click', function (event) { event.preventDefault(); wrapper.classList.toggle('closed'); menuToggleIcon.classList.toggle('icon-toggle-on'); menuToggleIcon.classList.toggle('icon-toggle-off'); var listItems = [].slice.call(document.querySelectorAll('.main-nav > li')); listItems.forEach(function (item) { item.classList.remove('open'); }); var elem = document.querySelector('.child-open'); if (elem) { elem.classList.remove('child-open'); } window.dispatchEvent(new CustomEvent('joomla:menu-toggle', { detail: wrapper.classList.contains('closed') ? 'closed' : 'open', bubbles: true, cancelable: true })); }); // Sidebar Nav var allLinks = wrapper.querySelectorAll('a.no-dropdown, a.collapse-arrow, .menu-dashboard > a'); var currentUrl = window.location.href; var mainNav = document.querySelector('ul.main-nav'); var menuParents = [].slice.call(document.querySelectorAll('ul.main-nav li.parent > a')); var subMenusClose = [].slice.call(document.querySelectorAll('ul.main-nav li.parent .close')); // Set active class allLinks.forEach(function (link) { if (!link.href.match(/index\.php$/) && currentUrl.indexOf(link.href) === 0 || link.href.match(/index\.php$/) && currentUrl.match(/index\.php$/)) { link.setAttribute('aria-current', 'page'); link.classList.add('mm-active'); // Auto Expand Levels if (!link.parentNode.classList.contains('parent')) { var firstLevel = link.closest('.collapse-level-1'); var secondLevel = link.closest('.collapse-level-2'); if (firstLevel) firstLevel.parentNode.classList.add('mm-active'); if (firstLevel) firstLevel.classList.add('mm-show'); if (secondLevel) secondLevel.parentNode.classList.add('mm-active'); if (secondLevel) secondLevel.classList.add('mm-show'); } } }); // Child open toggle var openToggle = function openToggle(_ref) { var currentTarget = _ref.currentTarget; var menuItem = currentTarget.parentNode; if (menuItem.tagName.toLowerCase() === 'span') { menuItem = currentTarget.parentNode.parentNode; } if (menuItem.classList.contains('open')) { mainNav.classList.remove('child-open'); menuItem.classList.remove('open'); } else { var siblings = [].slice.call(menuItem.parentNode.children); siblings.forEach(function (sibling) { sibling.classList.remove('open'); }); wrapper.classList.remove('closed'); if (menuToggleIcon.classList.contains('icon-toggle-off')) { menuToggleIcon.classList.toggle('icon-toggle-off'); menuToggleIcon.classList.toggle('icon-toggle-on'); } mainNav.classList.add('child-open'); if (menuItem.parentNode.classList.contains('main-nav')) { menuItem.classList.add('open'); } } window.dispatchEvent(new CustomEvent('joomla:menu-toggle', { detail: 'open', bubbles: true, cancelable: true })); }; menuParents.forEach(function (parent) { parent.addEventListener('click', openToggle); parent.addEventListener('keyup', openToggle); }); // Menu close subMenusClose.forEach(function (subMenu) { subMenu.addEventListener('click', function () { var menuChildsOpen = [].slice.call(mainNav.querySelectorAll('.open')); menuChildsOpen.forEach(function (menuChild) { menuChild.classList.remove('open'); }); mainNav.classList.remove('child-open'); }); }); } })(); PK � �\�Ͽ�� � js/admin-menu.min.js.gznu �[��� � �VMo�6��W0D!�Egs�]y�M�E�$[ ��m45�٥I��� ��-Ŷ"9q��$�gޛy������_�-���B䒢��w?�OtoK'݊�y�����y�UU�]h����7���`< ��ǻ/�#pB�?ʉV�4�%8��A�:�E 7B �\_^��_��=������$��S�,��\� ����=h���Z\j�ʤF,1=E�uWBΉ��+���|4K�tT篜( p��3W��o�9���̫&���!݅,����l��ZZs82���j- ���`:RS�d||lRr���7��`a�@���C�+/IN��xʇ����E�\�9L�n�Y���q �Rh�TY|ۇ�%���t�d�U;�5���+�$D��щc�n"�;>��5]Sf��j &D�8�\%�a�^8���a*Je]R�=R����N�4��ƈ�S��Eٮ #��A��x%{ �E����k)�+����H'I/={>�R&�ϕ/D�� �$��e�]�︖��f�1[����.�Қ ��;�?= �^ؤ�L4���9��H�b�axz���6U������Ʀ��En+Ð�ͪp�V�M����.Gc$0e&k��V����sS�5沣I�DZ�B80��������81�#�Zj5%�6M�E������? h����iJj7�e���+1}�i�ྥn�)����"1Å���/�b� �2O�i����;D�ӭ\�j |�U)�_r��t��۩o�ڵ����IqŎK�lۉ�۩Y5~nak���w��<bv'�����K�DF�/��IB�{���^�kYxO�k����g�T��ā9^����A��u�Q�$!�B��|�P:�_�W�'@=��@�?��<r-���w��[ߵ~�����5e�����^� �_�����?$���.� PK �>�\�(g`� � tmpl/default_submenu.phpnu �[��� <?php /** * @package Joomla.Administrator * @subpackage mod_menu * * @copyright (C) 2017 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\Language\Text; use Joomla\CMS\Router\Route; use Joomla\CMS\Uri\Uri; /** * ========================================================================================================= * IMPORTANT: The scope of this layout file is the `var \Joomla\Module\Menu\Administrator\Menu\CssMenu` object * and NOT the module context. * ========================================================================================================= */ /** @var \Joomla\Module\Menu\Administrator\Menu\CssMenu $this */ $class = 'item'; $currentParams = $current->getParams(); // Build the CSS class suffix if (!$this->enabled) { $class .= ' disabled'; } elseif ($current->type == 'separator') { $class = $current->title ? 'menuitem-group' : 'divider'; } elseif ($current->hasChildren()) { $class .= ' parent'; } if ($current->level == 1) { $class .= ' item-level-1'; } elseif ($current->level == 2) { $class .= ' item-level-2'; } elseif ($current->level == 3) { $class .= ' item-level-3'; } // Set the correct aria role and print the item if ($current->type == 'separator') { echo '<li class="' . $class . '" role="presentation">'; } else { echo '<li class="' . $class . '">'; } // Print a link if it exists $linkClass = []; $dataToggle = ''; $iconClass = ''; $itemIconClass = ''; $itemImage = ''; if ($current->hasChildren()) { $linkClass[] = 'has-arrow'; if ($current->level > 2) { $dataToggle = ' data-bs-toggle="dropdown"'; } } else { $linkClass[] = 'no-dropdown'; } // Implode out $linkClass for rendering $linkClass = ' class="' . implode(' ', $linkClass) . '" '; // Get the menu link $link = $current->link; // Get the menu image class $itemIconClass = $currentParams->get('menu_icon'); // Get the menu image $itemImage = $currentParams->get('menu_image'); // Get the menu icon $icon = $this->getIconClass($current); $iconClass = ($icon != '' && $current->level == 1) ? '<span class="' . $icon . '" aria-hidden="true"></span>' : ''; $ajax = !empty($current->ajaxbadge) ? '<span class="menu-badge"><span class="icon-spin icon-spinner mt-1 system-counter" data-url="' . $current->ajaxbadge . '"></span></span>' : ''; $iconImage = $current->icon; $homeImage = ''; if ($iconClass === '' && $itemIconClass) { $iconClass = '<span class="' . $itemIconClass . '" aria-hidden="true"></span>'; } if ($iconImage) { if (substr($iconImage, 0, 6) == 'class:' && substr($iconImage, 6) == 'icon-home') { $iconImage = '<span class="home-image icon-home" aria-hidden="true"></span>'; $iconImage .= '<span class="visually-hidden">' . Text::_('JDEFAULT') . '</span>'; } elseif (substr($iconImage, 0, 6) == 'image:') { $iconImage = ' <span class="badge">' . substr($iconImage, 6) . '</span>'; } else { $iconImage = ''; } } $itemImage = (empty($itemIconClass) && $itemImage) ? ' <img src="' . Uri::root() . $itemImage . '" alt=""> ' : ''; // If the item image is not set, the item title would not have margin. Here we add it. if ($icon == '' && $iconClass == '' && $current->level == 1 && $current->target == '') { $iconClass = '<span aria-hidden="true" class="icon-fw"></span>'; } if ($link != '' && $current->target != '') { echo '<a' . $linkClass . $dataToggle . ' href="' . $link . '" target="' . $current->target . '">' . $iconClass . '<span class="sidebar-item-title">' . $itemImage . Text::_($current->title) . '</span>' . $ajax . '</a>'; } elseif ($link != '' && $current->type !== 'separator') { echo '<a' . $linkClass . $dataToggle . ' href="' . $link . '" aria-label="' . Text::_($current->title) . '">' . $iconClass . '<span class="sidebar-item-title">' . $itemImage . Text::_($current->title) . '</span>' . $iconImage . '</a>'; } elseif ($current->title != '' && $current->type !== 'separator') { echo '<a' . $linkClass . $dataToggle . ' href="#">' . $iconClass . '<span class="sidebar-item-title">' . $itemImage . Text::_($current->title) . '</span>' . $ajax . '</a>'; } elseif ($current->title != '' && $current->type === 'separator') { echo '<span class="sidebar-item-title">' . Text::_($current->title) . '</span>' . $ajax; } else { echo '<span>' . Text::_($current->title) . '</span>' . $ajax; } if ($currentParams->get('menu-quicktask') && (int) $this->params->get('shownew', 1) === 1) { $params = $current->getParams(); $user = $this->application->getIdentity(); $link = $params->get('menu-quicktask'); $icon = $params->get('menu-quicktask-icon', 'plus'); $title = $params->get('menu-quicktask-title', 'MOD_MENU_QUICKTASK_NEW'); $permission = $params->get('menu-quicktask-permission'); $scope = $current->scope !== 'default' ? $current->scope : null; if (!$permission || $user->authorise($permission, $scope)) { echo '<span class="menu-quicktask"><a href="' . $link . '">'; echo '<span class="icon-' . $icon . '" title="' . htmlentities(Text::_($title)) . '" aria-hidden="true"></span>'; echo '<span class="visually-hidden">' . Text::_($title) . '</span>'; echo '</a></span>'; } } if (!empty($current->dashboard)) { $titleDashboard = Text::sprintf('MOD_MENU_DASHBOARD_LINK', Text::_($current->title)); echo '<span class="menu-dashboard"><a href="' . Route::_('index.php?option=com_cpanel&view=cpanel&dashboard=' . $current->dashboard) . '">' . '<span class="icon-th-large" title="' . $titleDashboard . '" aria-hidden="true"></span>' . '<span class="visually-hidden">' . $titleDashboard . '</span>' . '</a></span>'; } // Recurse through children if they exist if ($this->enabled && $current->hasChildren()) { if ($current->level > 1) { $id = $current->id ? ' id="menu-' . strtolower($current->id) . '"' : ''; echo '<ul' . $id . ' class="mm-collapse collapse-level-' . $current->level . '">' . "\n"; } else { echo '<ul id="collapse' . $this->getCounter() . '" class="collapse-level-1 mm-collapse">' . "\n"; } // WARNING: Do not use direct 'include' or 'require' as it is important to isolate the scope for each call $this->renderSubmenu(__FILE__, $current); echo "</ul>\n"; } echo "</li>\n"; PK �>�\ۡ�B�F �F src/Menu/CssMenu.phpnu �[��� <?php /** * @package Joomla.Administrator * @subpackage mod_menu * * @copyright (C) 2006 Open Source Matters, Inc. <https://www.joomla.org> * @license GNU General Public License version 2 or later; see LICENSE.txt */ namespace Joomla\Module\Menu\Administrator\Menu; use Joomla\CMS\Application\CMSApplication; use Joomla\CMS\Component\ComponentHelper; use Joomla\CMS\Language\Associations; use Joomla\CMS\Language\Text; use Joomla\CMS\Menu\AdministratorMenuItem; use Joomla\CMS\Table\Table; use Joomla\CMS\Uri\Uri; use Joomla\Component\Menus\Administrator\Helper\MenusHelper; use Joomla\Registry\Registry; use Joomla\Utilities\ArrayHelper; // phpcs:disable PSR1.Files.SideEffects \defined('_JEXEC') or die; // phpcs:enable PSR1.Files.SideEffects /** * Tree based class to render the admin menu * * @since 1.5 */ class CssMenu { /** * The root of the menu * * @var AdministratorMenuItem * * @since 4.0.0 */ protected $root; /** * An array of AdministratorMenuItem nodes * * @var AdministratorMenuItem[] * * @since 4.0.0 */ protected $nodes = []; /** * The module options * * @var Registry * * @since 3.8.0 */ protected $params; /** * The menu bar state * * @var boolean * * @since 3.8.0 */ protected $enabled; /** * The application * * @var CMSApplication * * @since 4.0.0 */ protected $application; /** * A counter for unique IDs * * @var integer * * @since 4.0.0 */ protected $counter = 0; /** * CssMenu constructor. * * @param CMSApplication $application The application * * @since 4.0.0 */ public function __construct(CMSApplication $application) { $this->application = $application; $this->root = new AdministratorMenuItem(); } /** * Populate the menu items in the menu tree object * * @param Registry $params Menu configuration parameters * @param bool $enabled Whether the menu should be enabled or disabled * * @return AdministratorMenuItem Root node of the menu tree * * @since 3.7.0 */ public function load($params, $enabled) { $this->params = $params; $this->enabled = $enabled; $menutype = $this->params->get('menutype', '*'); if ($menutype === '*') { $name = $this->params->get('preset', 'default'); $this->root = MenusHelper::loadPreset($name); } else { $this->root = MenusHelper::getMenuItems($menutype, true); // Can we access everything important with this menu? Create a recovery menu! if ( $this->enabled && $this->params->get('check', 1) && $this->check($this->root, $this->params) ) { $this->params->set('recovery', true); // In recovery mode, load the preset inside a special root node. $this->root = new AdministratorMenuItem(['level' => 0]); $heading = new AdministratorMenuItem(['title' => 'MOD_MENU_RECOVERY_MENU_ROOT', 'type' => 'heading']); $this->root->addChild($heading); MenusHelper::loadPreset('default', true, $heading); $this->preprocess($this->root); $this->root->addChild(new AdministratorMenuItem(['type' => 'separator'])); // Add link to exit recovery mode $uri = clone Uri::getInstance(); $uri->setVar('recover_menu', 0); $this->root->addChild(new AdministratorMenuItem(['title' => 'MOD_MENU_RECOVERY_EXIT', 'type' => 'url', 'link' => $uri->toString()])); return $this->root; } } $this->preprocess($this->root); return $this->root; } /** * Method to render a given level of a menu using provided layout file * * @param string $layoutFile The layout file to be used to render * @param AdministratorMenuItem $node Node to render the children of * * @return void * * @since 3.8.0 */ public function renderSubmenu($layoutFile, $node) { if (is_file($layoutFile)) { $children = $node->getChildren(); foreach ($children as $current) { $current->level = $node->level + 1; // This sets the scope to this object for the layout file and also isolates other `include`s require $layoutFile; } } } /** * Check the flat list of menu items for important links * * @param AdministratorMenuItem $node The menu items array * @param Registry $params Module options * * @return boolean Whether to show recovery menu * * @since 3.8.0 */ protected function check($node, Registry $params) { $me = $this->application->getIdentity(); $authMenus = $me->authorise('core.manage', 'com_menus'); $authModules = $me->authorise('core.manage', 'com_modules'); if (!$authMenus && !$authModules) { return false; } $items = $node->getChildren(true); $types = array_column($items, 'type'); $elements = array_column($items, 'element'); $rMenu = $authMenus && !\in_array('com_menus', $elements); $rModule = $authModules && !\in_array('com_modules', $elements); $rContainer = !\in_array('container', $types); if ($rMenu || $rModule || $rContainer) { $recovery = $this->application->getUserStateFromRequest('mod_menu.recovery', 'recover_menu', 0, 'int'); if ($recovery) { return true; } $missing = []; if ($rMenu) { $missing[] = Text::_('MOD_MENU_IMPORTANT_ITEM_MENU_MANAGER'); } if ($rModule) { $missing[] = Text::_('MOD_MENU_IMPORTANT_ITEM_MODULE_MANAGER'); } if ($rContainer) { $missing[] = Text::_('MOD_MENU_IMPORTANT_ITEM_COMPONENTS_CONTAINER'); } $uri = clone Uri::getInstance(); $uri->setVar('recover_menu', 1); $table = Table::getInstance('MenuType'); $menutype = $params->get('menutype'); $table->load(['menutype' => $menutype]); $menutype = $table->get('title', $menutype); $message = Text::sprintf('MOD_MENU_IMPORTANT_ITEMS_INACCESSIBLE_LIST_WARNING', $menutype, implode(', ', $missing), $uri); $this->application->enqueueMessage($message, 'warning'); } return false; } /** * Filter and perform other preparatory tasks for loaded menu items based on access rights and module configurations for display * * @param AdministratorMenuItem $parent A menu item to process * * @return void * * @since 3.8.0 */ protected function preprocess($parent) { $user = $this->application->getIdentity(); $language = $this->application->getLanguage(); $noSeparator = true; $children = $parent->getChildren(); /** * Trigger onPreprocessMenuItems for the current level of backend menu items. * $children is an array of AdministratorMenuItem objects. A plugin can traverse the whole tree, * but new nodes will only be run through this method if their parents have not been processed yet. */ $this->application->triggerEvent('onPreprocessMenuItems', ['com_menus.administrator.module', $children, $this->params, $this->enabled]); foreach ($children as $item) { $itemParams = $item->getParams(); // Exclude item with menu item option set to exclude from menu modules if ($itemParams->get('menu_show', 1) == 0) { $parent->removeChild($item); continue; } $item->scope = $item->scope ?? 'default'; $item->icon = $item->icon ?? ''; // Whether this scope can be displayed. Applies only to preset items. Db driven items should use un/published state. if (($item->scope === 'help' && $this->params->get('showhelp', 1) == 0) || ($item->scope === 'edit' && !$this->params->get('shownew', 1))) { $parent->removeChild($item); continue; } if (substr($item->link, 0, 8) === 'special:') { $special = substr($item->link, 8); if ($special === 'language-forum') { $item->link = 'index.php?option=com_admin&view=help&layout=langforum'; } elseif ($special === 'custom-forum') { $item->link = $this->params->get('forum_url'); } } $uri = new Uri($item->link); $query = $uri->getQuery(true); /** * If component is passed in the link via option variable, we set $item->element to this value for further * processing. It is needed for links from menu items of third party extensions link to Joomla! core * components like com_categories, com_fields... */ if ($option = $uri->getVar('option')) { $item->element = $option; } // Exclude item if is not enabled if ($item->element && !ComponentHelper::isEnabled($item->element)) { $parent->removeChild($item); continue; } /* * Multilingual Associations if the site is not set as multilingual and/or Associations is not enabled in * the Language Filter plugin */ if ($item->element === 'com_associations' && !Associations::isEnabled()) { $parent->removeChild($item); continue; } // Exclude Mass Mail if disabled in global configuration if ($item->scope === 'massmail' && ($this->application->get('mailonline', 1) == 0 || $this->application->get('massmailoff', 0) == 1)) { $parent->removeChild($item); continue; } // Exclude item if the component is not authorised $assetName = $item->element; if ($item->element === 'com_categories') { $assetName = $query['extension'] ?? 'com_content'; } elseif ($item->element === 'com_fields') { // Only display Fields menus when enabled in the component $createFields = null; if (isset($query['context'])) { $createFields = ComponentHelper::getParams(strstr($query['context'], '.', true))->get('custom_fields_enable', 1); } if (!$createFields) { $parent->removeChild($item); continue; } list($assetName) = isset($query['context']) ? explode('.', $query['context'], 2) : ['com_fields']; } elseif ($item->element === 'com_cpanel' && $item->link === 'index.php') { continue; } elseif ( $item->link === 'index.php?option=com_cpanel&view=help' || $item->link === 'index.php?option=com_cpanel&view=cpanel&dashboard=help' ) { if ($this->params->get('showhelp', 1)) { continue; } // Exclude help menu item if set such in mod_menu $parent->removeChild($item); continue; } elseif ($item->element === 'com_workflow') { // Only display Workflow menus when enabled in the component $workflow = null; if (isset($query['extension'])) { $parts = explode('.', $query['extension']); $workflow = ComponentHelper::getParams($parts[0])->get('workflow_enabled') && $user->authorise('core.manage.workflow', $parts[0]); } if (!$workflow) { $parent->removeChild($item); continue; } list($assetName) = isset($query['extension']) ? explode('.', $query['extension'], 2) : ['com_workflow']; } elseif (\in_array($item->element, ['com_config', 'com_privacy', 'com_actionlogs'], true) && !$user->authorise('core.admin')) { // Special case for components which only allow super user access $parent->removeChild($item); continue; } elseif ($item->element === 'com_joomlaupdate' && !$user->authorise('core.admin')) { $parent->removeChild($item); continue; } elseif ( ($item->link === 'index.php?option=com_installer&view=install' || $item->link === 'index.php?option=com_installer&view=languages') && !$user->authorise('core.admin') ) { continue; } elseif ($item->element === 'com_admin') { if (isset($query['view']) && $query['view'] === 'sysinfo' && !$user->authorise('core.admin')) { $parent->removeChild($item); continue; } } elseif ($item->link === 'index.php?option=com_messages&view=messages' && !$user->authorise('core.manage', 'com_users')) { $parent->removeChild($item); continue; } if ($assetName && !$user->authorise(($item->scope === 'edit') ? 'core.create' : 'core.manage', $assetName)) { $parent->removeChild($item); continue; } // Exclude if link is invalid if (is_null($item->link) || !\in_array($item->type, ['separator', 'heading', 'container']) && trim($item->link) === '') { $parent->removeChild($item); continue; } // Process any children if exists if ($item->hasChildren()) { $this->preprocess($item); } // Populate automatic children for container items if ($item->type === 'container') { $exclude = (array) $itemParams->get('hideitems') ?: []; $components = MenusHelper::getMenuItems('main', false, $exclude); // We are adding the nodes first to preprocess them, then sort them and add them again. foreach ($components->getChildren() as $c) { $item->addChild($c); } $this->preprocess($item); $children = ArrayHelper::sortObjects($item->getChildren(), 'text', 1, false, true); foreach ($children as $c) { $item->addChild($c); } } // Exclude if there are no child items under heading or container if (\in_array($item->type, ['heading', 'container']) && !$item->hasChildren() && empty($item->components)) { $parent->removeChild($item); continue; } // Remove repeated and edge positioned separators, It is important to put this check at the end of any logical filtering. if ($item->type === 'separator') { if ($noSeparator) { $parent->removeChild($item); continue; } $noSeparator = true; } else { $noSeparator = false; } // Ok we passed everything, load language at last only if ($item->element) { $language->load($item->element . '.sys', JPATH_ADMINISTRATOR) || $language->load($item->element . '.sys', JPATH_ADMINISTRATOR . '/components/' . $item->element); } if ($item->type === 'separator' && $itemParams->get('text_separator') == 0) { $item->title = ''; } $item->text = Text::_($item->title); } // If last one was a separator remove it too. $last = end($parent->getChildren()); if ($last && $last->type === 'separator' && $last->getSibling(false) && $last->getSibling(false)->type === 'separator') { $parent->removeChild($last); } } /** * Method to get the CSS class name for an icon identifier or create one if * a custom image path is passed as the identifier * * @param AdministratorMenuItem $node Node to get icon data from * * @return string CSS class name * * @since 3.8.0 */ public function getIconClass($node) { $identifier = $node->class; // Top level is special if (trim($identifier) == '') { return null; } // We were passed a class name if (substr($identifier, 0, 6) == 'class:') { $class = substr($identifier, 6); } else { // We were passed background icon url. Build the CSS class for the icon if ($identifier == null) { return null; } $class = preg_replace('#\.[^.]*$#', '', basename($identifier)); $class = preg_replace('#\.\.[^A-Za-z0-9\.\_\- ]#', '', $class); } $html = 'icon-' . $class . ' icon-fw'; return $html; } /** * Create unique identifier * * @return string * * @since 4.0.0 */ public function getCounter() { $this->counter++; return $this->counter; } } PK �Q�\�V� index.htmlnu &1i� PK �Q�\�28��# �# Y src/Helper/MenuHelper.phpnu �[��� PK �Q�\9��ik k y$ mod_menu.phpnu �[��� PK �Q�\��L� � '