From 92ff3e2bec95705f30360116558961f86d83be99 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sun, 24 Jan 2021 20:11:17 +0300 Subject: [PATCH 001/238] Update gpl.ini Add most popular GPL-compatible licenses from https://www.gnu.org/licenses/license-list.en.html --- administrator/components/com_jedchecker/libraries/rules/gpl.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/gpl.ini b/administrator/components/com_jedchecker/libraries/rules/gpl.ini index 2697061..936c902 100644 --- a/administrator/components/com_jedchecker/libraries/rules/gpl.ini +++ b/administrator/components/com_jedchecker/libraries/rules/gpl.ini @@ -11,4 +11,4 @@ ; ; The valid constants to search for -constants="BSD" +constants="Apache,Artistic,BSD,CC0,Creative Commons Attribution,MIT,MPL" From 02ccd6fa65ef5e61ad701d9da1a64fa338224640 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sun, 31 Jan 2021 11:52:32 +0300 Subject: [PATCH 002/238] move lists of GPL and compatible licenses to separate files --- .../com_jedchecker/libraries/rules/gpl.ini | 2 +- .../com_jedchecker/libraries/rules/gpl.php | 197 ++++++++++++------ .../libraries/rules/gpl_compat.txt | 169 +++++++++++++++ .../libraries/rules/gpl_gnu.txt | 38 ++++ 4 files changed, 341 insertions(+), 65 deletions(-) create mode 100644 administrator/components/com_jedchecker/libraries/rules/gpl_compat.txt create mode 100644 administrator/components/com_jedchecker/libraries/rules/gpl_gnu.txt diff --git a/administrator/components/com_jedchecker/libraries/rules/gpl.ini b/administrator/components/com_jedchecker/libraries/rules/gpl.ini index 936c902..5056d65 100644 --- a/administrator/components/com_jedchecker/libraries/rules/gpl.ini +++ b/administrator/components/com_jedchecker/libraries/rules/gpl.ini @@ -11,4 +11,4 @@ ; ; The valid constants to search for -constants="Apache,Artistic,BSD,CC0,Creative Commons Attribution,MIT,MPL" +constants="" diff --git a/administrator/components/com_jedchecker/libraries/rules/gpl.php b/administrator/components/com_jedchecker/libraries/rules/gpl.php index cdd440b..c70e89e 100644 --- a/administrator/components/com_jedchecker/libraries/rules/gpl.php +++ b/administrator/components/com_jedchecker/libraries/rules/gpl.php @@ -47,6 +47,20 @@ class JedcheckerRulesGpl extends JEDcheckerRule */ protected $description = 'COM_JEDCHECKER_RULE_PH1_DESC'; + /** + * Regular expression to match GPL licenses. + * + * @var string + */ + protected $regex_gpl_licenses; + + /** + * Regular expression to match GPL-compatible licenses. + * + * @var string + */ + protected $regex_compat_licenses; + /** * Initiates the file search and check * @@ -54,6 +68,9 @@ class JedcheckerRulesGpl extends JEDcheckerRule */ public function check() { + // Prepare regexp + $this->init(); + // Find all php files of the extension $files = JFolder::files($this->basedir, '.php$', true, true); @@ -70,7 +87,94 @@ class JedcheckerRulesGpl extends JEDcheckerRule } /** - * Reads a file and searches for the _JEXEC statement + * Initialization (prepare regular expressions) + */ + protected function init() + { + $gpl_licenses = (array) file(__DIR__ . '/gpl_gnu.txt'); + $this->regex_gpl_licenses = $this->generate_regexp($gpl_licenses); + + $compat_licenses = (array) file(__DIR__ . '/gpl_compat.txt'); + + $extra_licenses = $this->params->get('constants'); + $extra_licenses = explode(',', $extra_licenses); + + $compat_licenses = array_merge($compat_licenses, $extra_licenses); + + $this->regex_compat_licenses = $this->generate_regexp($compat_licenses); + } + + /** + * Generate regular expression to match the given list of license names + * @param $lines + * @return string + */ + protected function generate_regexp($lines) + { + $titles = array(); + $ids = array(); + + foreach ($lines as $line) + { + $line = trim($line); + if ($line === '' || $line[0] === '#') + { + // skip empty and commented lines + continue; + } + + $title = $line; + if (substr($line, -1, 1) === ')') + { + // extract identifier + $pos = strrpos($line, '('); + if ($pos !== false) + { + $title = trim(substr($line, 0, $pos)); + + $id = trim(substr($line, $pos + 1, -1)); + + if ($id !== '') + { + $id = preg_quote($id, '#'); + $ids[$id] = 1; + } + } + } + + if ($title !== '') + { + $title = preg_quote($title, '#'); + + // expand vN.N to different version formats + $title = preg_replace('/(?<=\S)\s+v(?=\d)/', ',?\s+(?:v\.?\s*|version\s+)?', $title); + + $title = preg_replace('/\s+/', '\s+', $title); + + $titles[$title] = 1; + } + } + + if (count($titles) === 0) + { + return null; + } + + $titles = implode('|', array_keys($titles)); + + if (count($ids)) + { + $ids = implode('|', array_keys($ids)); + $titles .= + '|\blicense\b.+?(?:' . $ids . ')' . + '|\b(?:' . $ids . ')\s+license\b'; + } + + return '#^.*?(?:' . $titles . ').*?$#im'; + } + + /** + * Reads a file and searches for its license * * @param string $file - The path to the file * @@ -78,72 +182,37 @@ class JedcheckerRulesGpl extends JEDcheckerRule */ protected function find($file) { - $content = (array) file($file); - - // Get the constants to look for - $licenses = $this->params->get('constants'); - $licenses = explode(',', $licenses); - - $hascode = 0; - - foreach ($content AS $key => $line) + // check the file is empty (i.e. comments-only) + $content = php_strip_whitespace($file); + if (preg_match('#^<\?php\s+$#', $content)) { - $tline = trim($line); - - if ($tline == '' || $tline == '') - { - continue; - } - - if ($tline['0'] != '/' && $tline['0'] != '*') - { - $hascode = 1; - } - - // Search for GPL license - $gpl = stripos($line, 'GPL'); - $gnu = stripos($line, 'GNU'); - $gpl_long = stripos($line, 'general public license'); - - if ($gpl || $gnu || $gpl_long) - { - $this->report->addInfo( - $file, - JText::_('COM_JEDCHECKER_PH1_LICENSE_FOUND') . ':' . '' . $line . '', - $key - ); - - return true; - } - - // Search for the constant name - foreach ($licenses AS $license) - { - $license = trim($license); - - // Search for the license - $found = strpos($line, $license); - - // Skip the line if the license is not found - if ($found === false) - { - continue; - } - else - { - $this->report->addInfo( - $file, - JText::_('COM_JEDCHECKER_GPL_COMPATIBLE_LICENSE_WAS_FOUND') . ':' . '' . $line . '', - $key - ); - - return true; - } - } + return true; } - unset($content); + $content = file_get_contents($file); - return $hascode ? false : true; + if (preg_match($this->regex_gpl_licenses, $content, $match, PREG_OFFSET_CAPTURE)) + { + $line_no = substr_count($content, "\n", 0, $match[0][1]) + 1; + $this->report->addInfo( + $file, + JText::_('COM_JEDCHECKER_PH1_LICENSE_FOUND') . ':' . '' . $match[0][0] . '', + $line_no + ); + return true; + } + + if (preg_match($this->regex_compat_licenses, $content, $match, PREG_OFFSET_CAPTURE)) + { + $line_no = substr_count($content, "\n", 0, $match[0][1]) + 1; + $this->report->addInfo( + $file, + JText::_('COM_JEDCHECKER_GPL_COMPATIBLE_LICENSE_WAS_FOUND') . ':' . '' . $match[0][0] . '', + $line_no + ); + return true; + } + + return false; } } diff --git a/administrator/components/com_jedchecker/libraries/rules/gpl_compat.txt b/administrator/components/com_jedchecker/libraries/rules/gpl_compat.txt new file mode 100644 index 0000000..777bed6 --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/gpl_compat.txt @@ -0,0 +1,169 @@ +# Based on: +# https://www.gnu.org/licenses/license-list.en.html +# https://opensource.org/licenses/alphabetical +# https://spdx.org/licenses/ + +# Comments are marked with the "#" character in the first position of the line + +# Each line contains the full name of the license with the optional abbreviation in parenthesis + +# The version of the license (if presented) should be written in the form +# [space][the letter "v"][digit(s)] +# (see examples below) + + +# BSD Licenses +BSD License +0-clause BSD License (0BSD) +BSD Zero Clause License +Zero-Clause BSD / Free Public License v1.0.0 +1-clause BSD License (BSD-1-Clause) +BSD 1-Clause License +2-clause BSD License (BSD-2-Clause) +BSD 2-Clause "Simplified" License +BSD-2-Clause Plus Patent License (BSD-2-Clause-Patent) +BSD+Patent +FreeBSD License +3-clause BSD License (BSD-3-Clause) +BSD 3-Clause "New" or "Revised" License +Lawrence Berkeley National Labs BSD variant License (BSD-3-Clause-LBNL) +Modified BSD License +Clear BSD License + +# Other OSI Licenses +Academic Free License v1.1 (AFL-1.1) +Academic Free License v1.2 (AFL-1.2) +Academic Free License v2.0 (AFL-2.0) +Academic Free License v2.1 (AFL-2.1) +Academic Free License v3.0 (AFL-3.0) +Adaptive Public License (APL-1.0) +Apache License v1.1 (Apache-1.1) +Apache Software License v1.1 +Apache License v2.0 (Apache-2.0) +Apple Public Source License v1.0 (APSL-1.0) +Apple Public Source License v1.1 (APSL-1.1) +Apple Public Source License v1.2 (APSL-1.2) +Apple Public Source License v2.0 (APSL-2.0) +Apple Public Source License +Artistic License v1.0 (Artistic-1.0) +Artistic License +Artistic License v2.0 (Artistic-2.0) +Attribution Assurance License (AAL) +Berkeley Database License +Boost Software License (BSL-1.0) +CeCILL v2 +CeCILL License v2.1 (CECILL-2.1) +CeCILL Free Software License Agreement v2.1 +CERN Open Hardware Licence v2 - Permissive (CERN-OHL-P-2.0) +CERN Open Hardware Licence v2 - Weakly Reciprocal (CERN-OHL-W-2.0) +CERN Open Hardware Licence v2 - Strongly Reciprocal (CERN-OHL-S-2.0) +Clarified Artistic License +Common Development and Distribution License v1.0 (CDDL-1.0) +Common Public Attribution License v1.0 (CPAL-1.0) +Common Public License v1.0 (CPL-1.0) +Computer Associates Trusted Open Source License v1.1 (CATOSL-1.1) +Cryptix General License +Cryptographic Autonomy License v1.0 (CAL-1.0) +CUA Office Public License v1.0 (CUA-OPL-1.0) +Eclipse Public License v1.0 (EPL-1.0) +Eclipse Public License v2.0 (EPL-2.0) +eCos License v2.0 (eCos-2.0) +Educational Community License v1.0 (ECL-1.0) +Educational Community License v2.0 (ECL-2.0) +Eiffel Forum License v1.0 (EFL-1.0) +Eiffel Forum License v2.0 (EFL-2.0) +Entessa Public License (Entessa) +EU DataGrid Software License (EUDatagrid) +European Union Public License v1.1 (EUPL-1.1) +European Union Public License v1.2 (EUPL-1.2) +Expat License +Fair License (Fair) +Frameworx License (Frameworx-1.0) +Frameworx Open License v1.0 +Freetype Project License +Historical Permission Notice and Disclaimer (HPND) +IBM Public License v1.0 (IPL-1.0) +Independent JPEG Group License +Intel Open Source License (Intel) +IPA Font License (IPA) +ISC License (ISC) +Jabber Open Source License +LaTeX Project Public License v1.3c (LPPL-1.3c) +Licence Libre du Québec – Permissive (LiLiQ-P) v1.1 (LiliQ-P) +Licence Libre du Québec – Permissive v1.1 (LiLiQ-P-1.1) +Licence Libre du Québec – Réciprocité (LiLiQ-R) v1.1 (LiliQ-R) +Licence Libre du Québec – Réciprocité v1.1 (LiLiQ-R-1.1) +Licence Libre du Québec – Réciprocité forte (LiLiQ-R+) v1.1 (LiliQ-R+) +Licence Libre du Québec – Réciprocité forte v1.1 (LiLiQ-Rplus-1.1) +Lucent Public License ("Plan9") v1.0 (LPL-1.0) +Lucent Public License v1.0 +Lucent Public License v1.02 (LPL-1.02) +Microsoft Public License (MS-PL) +Microsoft Reciprocal License (MS-RL) +MirOS Licence (MirOS) +MIT License (MIT) +MIT No Attribution (MIT-0) +MITRE Collaborative Virtual Workspace License (CVW) +Motosoto License (Motosoto) +Mozilla Public License v1.0 (MPL-1.0) +Mozilla Public License v1.1 (MPL-1.1) +Mozilla Public License v2.0 (MPL-2.0) +Mulan Permissive Software License v2 (MulanPSL-2.0) +Multics License (Multics) +NASA Open Source Agreement v1.3 (NASA-1.3) +Naumen Public License (Naumen) +Nethack General Public License (NGPL) +Nokia Open Source License (Nokia) +Non-Profit Open Software License v3.0 (NPOSL-3.0) +NTP License (NTP) +OCLC Research Public License v2.0 (OCLC-2.0) +Open Group Test Suite License (OGTSL) +Open Software License v1.0 (OSL-1.0) +Open Software License v2.0 (OSL-2.0) +Open Software License v2.1 (OSL-2.1) +Open Software License v3.0 (OSL-3.0) +OpenLDAP License v2.7 +OpenLDAP Public License v2.8 (OLDAP-2.8) +Open LDAP Public License v2.8 +OSET Public License v2.1 (OSET-PL-2.1) +PHP License v3.0 (PHP-3.0) +PHP License v3.01 (PHP-3.01) +PostgreSQL License (PostgreSQL) +Python License (Python-2.0) +CNRI Python License (CNRI-Python) +Q Public License (QPL-1.0) +RealNetworks Public Source License v1.0 (RPSL-1.0) +Reciprocal Public License v1.1 (RPL-1.1) +Reciprocal Public License v1.5 (RPL-1.5) +Ricoh Source Code Public License (RSCPL) +SGI Free Software License B v2.0 +SIL Open Font License v1.1 (OFL-1.1) +Simple Public License v2.0 (SimPL-2.0) +Sleepycat License (Sleepycat) +Sleepycat Software Product License +Standard ML of New Jersey Copyright License +Sun Industry Standards Source License (SISSL) +Sun Public License v1.0 (SPL-1.0) +Sybase Open Watcom Public License v1.0 (Watcom-1.0) +Unicode Data Files and Software License (Unicode-DFS-2016) +Unicode License Agreement - Data Files and Software +Unicode, Inc. License Agreement for Data Files and Software +Universal Permissive License (UPL) +Universal Permissive License v1.0 (UPL-1.0) +University of Illinois/NCSA Open Source License (NCSA) +NCSA/University of Illinois Open Source License +Unlicense +Upstream Compatibility License v1.0 (UCL-1.0) +Vovida Software License v.1.0 (VSL-1.0) +W3C License (W3C) +W3C Software Notice and License +WTFPL v2 +WxWidgets Library License +wxWindows Library License (WXwindows) +X11 License +XFree86 v1.1 License +X.Net License (Xnet) +Zope Public License v2.0 (ZPL-2.0) +Zope Public License v2.1 +zlib/libpng License (Zlib) +zlib License diff --git a/administrator/components/com_jedchecker/libraries/rules/gpl_gnu.txt b/administrator/components/com_jedchecker/libraries/rules/gpl_gnu.txt new file mode 100644 index 0000000..8e2979f --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/gpl_gnu.txt @@ -0,0 +1,38 @@ +# GPL Licenses + +# Based on: +# https://www.gnu.org/licenses/license-list.en.html +# https://opensource.org/licenses/alphabetical +# https://spdx.org/licenses/ + +# Comments are marked with the "#" character in the first position of the line + +# Each line contains the full name of the license with the optional abbreviation in parenthesis + +# The version of the license (if presented) should be written in the form +# [space][the letter "v"][digit(s)] +# (see examples below) + + +GNU General Public License +GNU GPL +GNU/GPL +GNU Lesser General Public License +GNU LGPL +GNU/LGPL + +GNU General Public License v2 (GPL-2.0) +//www.gnu.org/licenses/gpl-2.0.html + +GNU General Public License v3 (GPL-3.0) +//www.gnu.org/licenses/gpl-3.0.html + +GNU Affero General Public License v3 (AGPL-3.0) +GNU Affero General Public License (AGPL) v3 +GNU Library General Public License v2 (LGPL-2.0) +GNU Lesser General Public License v2.1 (LGPL-2.1) +GNU Lesser General Public License (LGPL) v2.1 +GNU Lesser General Public License v3 (LGPL-3.0) +GNU Lesser General Public License (LGPL) v3 + +GNU All-Permissive License From 372ea55ad7986b18c2648e41e587fde88f03fa3d Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 2 Feb 2021 14:56:56 +0300 Subject: [PATCH 003/238] - fixed loading of language file - check manifest file do exist - check naming rules - drop Joomla!1.5 support ("install" root element) --- .../language/en-GB/en-GB.com_jedchecker.ini | 9 + .../libraries/rules/xmlinfo.php | 158 +++++++++++++++--- 2 files changed, 143 insertions(+), 24 deletions(-) diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index 7231b32..918481f 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -43,6 +43,15 @@ COM_JEDCHECKER_INFO_XML_DESC="The install name of your extension must match your COM_JEDCHECKER_INFO_XML_NAME_XML="The name tag in this file is: %s" COM_JEDCHECKER_INFO_XML_VERSION_XML="Version tag has the value: %s" COM_JEDCHECKER_INFO_XML_CREATIONDATE_XML="The creationDate tag has the value: %s" +COM_JEDCHECKER_INFO_XML_NO_MANIFEST="No manifest file found" +COM_JEDCHECKER_INFO_XML_NAME_MODULE_PLUGIN="Listing name contains 'module' or 'plugin'" +COM_JEDCHECKER_INFO_XML_NAME_RESERVED_KEYWORDS="Keywords such as module, plugin or template are considered reserved words and can't be used in the extension names" +COM_JEDCHECKER_INFO_XML_NAME_VERSION="Version in name/title" +COM_JEDCHECKER_INFO_XML_NAME_JOOMLA="An extension name can't start with the word 'Joomla'" +COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the extension name need to be licensed by OSM" +COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the domain name need to be licensed by OSM" +COM_JEDCHECKER_INFO_XML_NAME_ADMIN_MENU="The admin menu name '%1$s' isn't the same as the extension name '%2$s'" +COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT="The name of the plugin must comply with the JED naming conventions in the form '{Type} - {Extension Name}'" COM_JEDCHECKER_RULE_PH1="PHP Headers missing GPL License Notice" COM_JEDCHECKER_RULE_PH1_DESC="A notice is required on each PHP file stating that the file is licensed GPL (or other compatible accepted license). For more information, please click here." COM_JEDCHECKER_ERROR_GPL_NOT_FOUND="GPL or compatible license was not found" diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index b4037be..9d3a44e 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -57,11 +57,21 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule // Find all XML files of the extension $files = JFolder::files($this->basedir, '.xml$', true, true); + $manifestFound = false; + // Iterate through all the xml files foreach ($files as $file) { // Try to find the license - $this->find($file); + if ($this->find($file)) + { + $manifestFound = true; + } + } + + if (!$manifestFound) + { + $this->report->addError('', JText::_('COM_JEDCHECKER_INFO_XML_NO_MANIFEST')); } } @@ -70,51 +80,151 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule * * @param string $file - The path to the file * - * @return boolean True if the license was found, otherwise False. + * @return boolean True if the manifest file was found, otherwise False. */ protected function find($file) { $xml = JFactory::getXml($file); - // Get all the info about the file - $folder_info = pathinfo($file); - - // Get the folder path - $folder_path = $folder_info['dirname']; - - // Get the folder name - $folder_name = $folder_info['dirname']; - $folder_name_exploded = explode(DIRECTORY_SEPARATOR,$folder_name); - if ( is_array($folder_name_exploded) ) { - $folder_name = end($folder_name_exploded); - } - - // Load the language of the extension (if any) - $lang = JFactory::getLanguage(); - $lang->load($folder_name,$folder_path); - // Failed to parse the xml file. // Assume that this is not a extension manifest if (!$xml) { - return true; + return false; } // Check if this is an extension manifest - // 1.5 uses 'install', 1.6 uses 'extension' - if ($xml->getName() != 'install' && $xml->getName() != 'extension') + // 1.5 uses 'install', 1.6+ uses 'extension' + if ($xml->getName() !== 'extension') { - return true; + return false; + } + + // Get extension name (element) + $type = (string) $xml['type']; + if (isset($xml->element)) + { + $extension = (string) $xml->element; + } + else + { + $extension = (string) $xml->name; + foreach ($xml->files->children as $child) + { + if (isset($child[$type])) + { + $extension = (string) $child[$type]; + } + } + } + $extension = strtolower(JFilterInput::getInstance()->clean($extension, 'cmd')); + if ($type === 'component' && strpos($extension, 'com_') !== 0) + { + $extension = 'com_' . $extension; + } + + // Load the language of the extension (if any) + $lang = JFactory::getLanguage(); + + // search for .sys.ini translation file + $lang_dir = dirname($file); + $lang_tag = 'en-GB'; // $lang->getDefault(); + + $lookup_lang_dirs = array(); + if (isset($xml->administration->files['folder'])) + { + $lookup_lang_dirs[] = $xml->administration->files['folder'] . '/language/' . $lang_tag; + } + if (isset($xml->files['folder'])) + { + $lookup_lang_dirs[] = $xml->files['folder'] . '/language/' . $lang_tag; + } + if (isset($xml->administration->languages['folder'])) + { + $lookup_lang_dirs[] = $xml->administration->languages['folder']; + } + if (isset($xml->languages['folder'])) + { + $lookup_lang_dirs[] = $xml->languages['folder']; + } + $lookup_lang_dirs[] = ''; + + foreach ($lookup_lang_dirs as $dir) + { + $lang_sys_file = + $lang_dir . '/' . + ($dir === '' ? '' : trim($dir, '/') . '/') . + $lang_tag. '.' . $extension . '.sys.ini'; + if (is_file($lang_sys_file)) + { + $loadLanguage = new ReflectionMethod($lang, 'loadLanguage'); + $loadLanguage->setAccessible(true); + $loadLanguage->invoke($lang, $lang_sys_file, $extension); + break; + } } // Get the real extension's name now that the language has been loaded - (string) $extension_name = $lang->_($xml->name); + $extension_name = $lang->_((string) $xml->name); $info[] = JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_XML', $extension_name); $info[] = JText::sprintf('COM_JEDCHECKER_INFO_XML_VERSION_XML', (string) $xml->version); $info[] = JText::sprintf('COM_JEDCHECKER_INFO_XML_CREATIONDATE_XML', (string) $xml->creationDate); + $this->report->addInfo($file, implode('
', $info)); + // NM3 - Listing name contains “module” or “plugin” + if (preg_match('/\b(?:module|plugin)\b/i', $extension_name)) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_MODULE_PLUGIN')); + } + if (stripos($extension_name, 'template') !== false) + { + $this->report->addWarning($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_RESERVED_KEYWORDS')); + } + + // NM5 - Version in name/title + if (preg_match('/(?:\bversion\b|\d\.\d)/i', $extension_name)) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_VERSION')); + } + + if (stripos($extension_name, 'joomla') === 0) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_JOOMLA')); + } + elseif (stripos($extension_name, 'joom') !== false) + { + $this->report->addWarning($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE')); + } + + $url = (string)$xml->authorUrl; + if (stripos($url, 'joom') !== false) + { + $domain = (strpos($url, '//') === false) ? $url : parse_url(trim($url), PHP_URL_HOST); + if (stripos($domain, 'joom') !== false) { + $this->report->addWarning($file, JText::_('COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE')); + } + } + + if ($type === 'component' && isset($xml->administration->menu)) + { + $menu_name = $lang->_((string) $xml->administration->menu); + if ($extension_name !== $menu_name) + { + $this->report->addWarning($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_ADMIN_MENU', $menu_name, $extension_name)); + } + } + + if ($type === 'plugin') + { + $group = (string) $xml['group']; + if (strpos($extension_name, ucfirst($group) . ' - ') !== 0) + { + $this->report->addWarning($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT')); + } + } + // All checks passed. Return true return true; } From 070b22caaef4e7643dac2cec10fa4289bbacc2e1 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 2 Feb 2021 15:36:52 +0300 Subject: [PATCH 004/238] one more directory to lookup for language file --- .../com_jedchecker/libraries/rules/xmlinfo.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index 9d3a44e..0b30250 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -133,19 +133,20 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule $lookup_lang_dirs = array(); if (isset($xml->administration->files['folder'])) { - $lookup_lang_dirs[] = $xml->administration->files['folder'] . '/language/' . $lang_tag; + $lookup_lang_dirs[] = trim($xml->administration->files['folder'], '/') . '/language/' . $lang_tag; } if (isset($xml->files['folder'])) { - $lookup_lang_dirs[] = $xml->files['folder'] . '/language/' . $lang_tag; + $lookup_lang_dirs[] = trim($xml->files['folder'], '/') . '/language/' . $lang_tag; } + $lookup_lang_dirs[] = 'language/' . $lang_tag; if (isset($xml->administration->languages['folder'])) { - $lookup_lang_dirs[] = $xml->administration->languages['folder']; + $lookup_lang_dirs[] = trim($xml->administration->languages['folder'], '/'); } if (isset($xml->languages['folder'])) { - $lookup_lang_dirs[] = $xml->languages['folder']; + $lookup_lang_dirs[] = trim($xml->languages['folder'], '/'); } $lookup_lang_dirs[] = ''; From 74288b93d226f1ba9f491cb2b34d4176685f49c6 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 2 Feb 2021 18:58:29 +0300 Subject: [PATCH 005/238] Add XML manifest validator --- .../language/en-GB/en-GB.com_jedchecker.ini | 12 +- .../libraries/rules/xmlmanifest.php | 285 ++++++++++++++++++ .../rules/xmlmanifest_component.json | 129 ++++++++ .../libraries/rules/xmlmanifest_module.json | 117 +++++++ .../libraries/rules/xmlmanifest_plugin.json | 118 ++++++++ 5 files changed, 660 insertions(+), 1 deletion(-) create mode 100644 administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php create mode 100644 administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json create mode 100644 administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json create mode 100644 administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index 7231b32..ab71533 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -77,4 +77,14 @@ COM_JEDCHECKER_ERROR_XML_UPDATE_SERVER_LINK_NOT_FOUND="Update Server link not fo COM_JEDCHECKER_INFO_XML_UPDATE_SERVER_LINK="The Update Server link in this XML file is: %s" COM_JEDCHECKER_DELETE_FAILED="Can't delete temporary folder" COM_JEDCHECKER_DELETE_SUCCESS="Temporary folder deleted!" -COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" \ No newline at end of file +COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" +COM_JEDCHECKER_MANIFEST="XML Manifest" +COM_JEDCHECKER_MANIFEST_DESC="Validation of extension's XML manifest file" +COM_JEDCHECKER_MANIFEST_UNKNOWN_TYPE="Unknown extension type: %s" +COM_JEDCHECKER_MANIFEST_TYPE_NOT_ACCEPTED="Extension type '%s' is not accepted by JED" +COM_JEDCHECKER_MANIFEST_UNKNOWN_ATTRIBUTE="Node '%1$s' has unknown attribute '%2$s'" +COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILDREN="Node '%s' has unknown child element" +COM_JEDCHECKER_MANIFEST_MISSED_REQUIRED="Node '%1$s' doesn't contain required '%2$s' element" +COM_JEDCHECKER_MANIFEST_MULTIPLE_FOUND="Node '%1$s' contains multiple '%2$s' elements" +COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILD="Node '%1$s' contains unknown '%2$s' element" +COM_JEDCHECKER_MANIFEST_MENU_UNUSED_ATTRIBUTE="Menu item attribute '%s' is not used with 'link' attribute" \ No newline at end of file diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php new file mode 100644 index 0000000..328605d --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -0,0 +1,285 @@ + + * eaxs + * Denis Ryabov + * + * @license GNU General Public License version 2 or later; see LICENSE.txt + */ + +defined('_JEXEC') or die('Restricted access'); + + +// Include the rule base class +require_once JPATH_COMPONENT_ADMINISTRATOR . '/models/rule.php'; + + +/** + * class JedcheckerRulesXMLManifest + * + * This class validates all xml manifestes + * + * @since 1.0 + */ +class JedcheckerRulesXMLManifest extends JEDcheckerRule +{ + /** + * The formal ID of this rule. For example: SE1. + * + * @var string + */ + protected $id = 'MANIFEST'; + + /** + * The title or caption of this rule. + * + * @var string + */ + protected $title = 'COM_JEDCHECKER_MANIFEST'; + + /** + * The description of this rule. + * + * @var string + */ + protected $description = 'COM_JEDCHECKER_MANIFEST_DESC'; + + /** + * List of errors. + * + * @var string[] + */ + protected $errors; + + /** + * List of warnings. + * + * @var string[] + */ + protected $warnings; + + /** + * Rules for XML nodes + * ? - single, optional + * = - single, required, warning if missed + * ! - single, required, error if missed + * * - multiple, optional + * @var array + */ + protected $DTDNodeRules; + + /** + * Rules for attributes + * (list of allowed attributes) + * @var array + */ + protected $DTDAttrRules; + + protected $types = array( + 'component', 'file', 'language', 'library', + 'module', 'package', 'plugin', 'template' + ); + + /** + * Initiates the search and check + * + * @return void + */ + public function check() + { + // Find all XML files of the extension + $files = JFolder::files($this->basedir, '.xml$', true, true); + + // Iterate through all the xml files + foreach ($files as $file) + { + // Try to check the file + $this->find($file); + } + } + + /** + * Reads a file and validate XML manifest + * + * @param string $file - The path to the file + * + * @return boolean True if the manifest file was found, otherwise False. + */ + protected function find($file) + { + $xml = JFactory::getXml($file); + + // Failed to parse the xml file. + // Assume that this is not a extension manifest + if (!$xml) + { + return false; + } + + // Check if this is an extension manifest + if ($xml->getName() !== 'extension') + { + return false; + } + + // check extension type + $type = (string) $xml['type']; + if (!in_array($type, $this->types, true)) + { + $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_MANIFEST_UNKNOWN_TYPE', $type)); + return true; + } + + // load DTD-like data for this extension type + $json_filename = __DIR__ . '/xmlmanifest_' . $type . '.json'; + if (!is_file($json_filename)) + { + $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_MANIFEST_TYPE_NOT_ACCEPTED', $type)); + return true; + } + $data = json_decode(file_get_contents($json_filename), true); + $this->DTDNodeRules = $data['nodes']; + $this->DTDAttrRules = $data['attributes']; + + $this->errors = array(); + $this->warnings = array(); + + // validate manifest + $this->validateXml($xml, 'extension'); + + if (count($this->errors)) + { + $this->report->addError($file, implode('
', $this->errors)); + } + + if (count($this->warnings)) + { + $this->report->addWarning($file, implode('
', $this->warnings)); + } + + // All checks passed. Return true + return true; + } + + /** + * @param JXMLElement $node + * @param string $name + */ + protected function validateXml($node, $name) + { + // Check attributes + $DTDattributes = isset($this->DTDAttrRules[$name]) ? $this->DTDAttrRules[$name] : array(); + foreach ($node->attributes() as $attr) + { + $attr_name = (string)$attr->getName(); + if (!in_array($attr_name, $DTDattributes, true)) + { + $this->warnings[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_UNKNOWN_ATTRIBUTE', $name, $attr_name); + } + } + + // Check children nodes + if (!isset($this->DTDNodeRules[$name])) + { + // No children + if ($node->count() > 0) + { + $this->warnings[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILDREN', $name); + } + } else { + $DTDchildren = $this->DTDNodeRules[$name]; + + // 1) check required single elements + + foreach ($DTDchildren as $child => $mode) + { + $count = $node->$child->count(); + switch ($mode) + { + case '!': + $errors =& $this->errors; + break; + case '=': + $errors =& $this->warnings; + break; + default: + continue 2; + } + if ($count === 0) + { + $errors[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_MISSED_REQUIRED', $name, $child); + } + elseif ($count > 1) + { + $errors[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_MULTIPLE_FOUND', $name, $child); + } + unset($errors); + } + + // 2) check unknown/multiple elements + + // collect unique child node names + $child_names = array(); + foreach ($node as $child) + { + $child_names[$child->getName()] = 1; + } + $child_names = array_keys($child_names); + + foreach ($child_names as $child) + { + if (!isset($DTDchildren[$child])) + { + $this->warnings[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILD', $name, $child); + } + else + { + if ($DTDchildren[$child] === '?' && $node->$child->count() > 1) + { + $this->errors[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_MULTIPLE_FOUND', $name, $child); + } + } + } + } + + // Extra checks (if exist) + $method = 'validateXml' . $name; + if (method_exists($this, $method)) + { + $this->$method($node); + } + + // Recursion + foreach ($node as $child) + { + $child_name = $child->getName(); + if (isset($this->DTDNodeRules[$child_name])) { + $this->validateXml($child, $child_name); + } + } + } + + /** + * Extra check for menu nodes + * @param JXMLElement $node + */ + protected function validateXmlMenu($node) + { + if (isset($node['link'])) + { + $skip_attrs = array('act', 'controller', 'layout', 'sub', 'task', 'view'); + foreach ($node->attributes() as $attr) + { + $attr_name = $attr->getName(); + if (in_array($attr_name, $skip_attrs, true)) + { + $this->warnings[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_MENU_UNUSED_ATTRIBUTE', $attr_name); + } + } + } + } +} diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json new file mode 100644 index 0000000..6a6d949 --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json @@ -0,0 +1,129 @@ +{ + "nodes": { + "extension": { + "name": "!", + "element": "?", + "creationDate": "=", + "author": "=", + "authorEmail": "=", + "authorUrl": "=", + "copyright": "=", + "version": "!", + "description": "=", + "license": "!", + "scriptfile": "?", + "install": "?", + "update": "?", + "uninstall": "?", + "files": "?", + "languages": "?", + "media": "?", + "administration": "?", + "updateservers": "!", + "config": "?", + "dlid": "?" + }, + "administration": { + "menu": "=", + "submenu": "?", + "files": "=", + "languages": "=", + "media": "?" + }, + "files": { + "filename": "*", + "folder": "*" + }, + "languages": { + "language": "*" + }, + "media": { + "filename": "*", + "folder": "*" + }, + "submenu": { + "menu": "*" + }, + "install": { + "sql": "*" + }, + "update": { + "sql": "*", + "schemas": "*" + }, + "uninstall": { + "sql": "*" + }, + "sql": { + "file": "*" + }, + "schemas": { + "schemapath": "*" + }, + "updateservers": { + "server": "*" + }, + "config": { + "fields": "!" + }, + "fields": { + "fieldset": "+" + }, + "fieldset": { + "???": "*" + } + }, + "attributes": { + "extension": [ + "client", + "method", + "overwrite", + "type", + "version" + ], + "files": [ + "folder" + ], + "languages": [ + "folder" + ], + "language": [ + "client", + "tag" + ], + "media": [ + "destination", + "folder" + ], + "menu": [ + "act", + "controller", + "hidden", + "img", + "layout", + "link", + "sub", + "task", + "view" + ], + "file": [ + "charset", + "driver" + ], + "server": [ + "name", + "priority", + "type" + ], + "params": [ + "addParameterDir" + ], + "param": [ + "addParameterDir" + ], + "dlid": [ + "prefix", + "suffix" + ] + } +} \ No newline at end of file diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json new file mode 100644 index 0000000..8747f30 --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json @@ -0,0 +1,117 @@ +{ + "nodes": { + "extension": { + "name": "!", + "element": "?", + "creationDate": "=", + "author": "=", + "authorEmail": "=", + "authorUrl": "=", + "copyright": "=", + "version": "!", + "description": "=", + "license": "!", + "scriptfile": "?", + "install": "?", + "update": "?", + "uninstall": "?", + "files": "?", + "languages": "?", + "media": "?", + "updateservers": "!", + "config": "?", + "dlid": "?" + }, + "files": { + "filename": "*", + "folder": "*" + }, + "languages": { + "language": "*" + }, + "media": { + "filename": "*", + "folder": "*" + }, + "install": { + "sql": "*" + }, + "update": { + "sql": "*", + "schemas": "*" + }, + "uninstall": { + "sql": "*" + }, + "sql": { + "file": "*" + }, + "updateservers": { + "server": "*" + }, + "config": { + "fields": "!" + }, + "fields": { + "fieldset": "+" + }, + "fieldset": { + "field": "+" + }, + "field": { + "option": "*" + } + }, + "attributes": { + "extension": [ + "client", + "method", + "overwrite", + "type", + "version" + ], + "files": [ + "folder" + ], + "filename": [ + "module" + ], + "languages": [ + "folder" + ], + "language": [ + "client", + "tag" + ], + "media": [ + "destination", + "folder" + ], + "file": [ + "charset", + "driver" + ], + "server": [ + "name", + "priority", + "type" + ], + "fields": [ + "addfieldpath", + "name" + ], + "fieldset": [ + "name" + ], + "field": [ + "default", + "description", + "label", + "name", + "type" + ], + "option": [ + "value" + ] + } +} \ No newline at end of file diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json new file mode 100644 index 0000000..45bd081 --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json @@ -0,0 +1,118 @@ +{ + "nodes": { + "extension": { + "name": "!", + "element": "?", + "creationDate": "=", + "author": "=", + "authorEmail": "=", + "authorUrl": "=", + "copyright": "=", + "version": "!", + "description": "=", + "license": "!", + "scriptfile": "?", + "install": "?", + "update": "?", + "uninstall": "?", + "files": "?", + "languages": "?", + "media": "?", + "updateservers": "!", + "config": "?", + "dlid": "?" + }, + "files": { + "filename": "*", + "folder": "*" + }, + "languages": { + "language": "*" + }, + "media": { + "filename": "*", + "folder": "*" + }, + "install": { + "sql": "*" + }, + "update": { + "sql": "*", + "schemas": "*" + }, + "uninstall": { + "sql": "*" + }, + "sql": { + "file": "*" + }, + "updateservers": { + "server": "*" + }, + "config": { + "fields": "!" + }, + "fields": { + "fieldset": "+" + }, + "fieldset": { + "field": "+" + }, + "field": { + "option": "*" + } + }, + "attributes": { + "extension": [ + "client", + "group", + "method", + "overwrite", + "type", + "version" + ], + "files": [ + "folder" + ], + "filename": [ + "plugin" + ], + "languages": [ + "folder" + ], + "language": [ + "client", + "tag" + ], + "media": [ + "destination", + "folder" + ], + "file": [ + "charset", + "driver" + ], + "server": [ + "name", + "priority", + "type" + ], + "fields": [ + "addfieldpath", + "name" + ], + "fieldset": [ + "name" + ], + "field": [ + "default", + "description", + "label", + "name", + "type" + ], + "option": [ + "value" + ] + } +} \ No newline at end of file From 8e0d7381311eaeb329b0ba25b88bc803bc0c385f Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 2 Feb 2021 19:09:20 +0300 Subject: [PATCH 006/238] Add check for incorrect file/folder references in the XML manifest --- .../language/en-GB/en-GB.com_jedchecker.ini | 6 +- .../libraries/rules/xmlfiles.php | 228 ++++++++++++++++++ 2 files changed, 233 insertions(+), 1 deletion(-) create mode 100644 administrator/components/com_jedchecker/libraries/rules/xmlfiles.php diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index 7231b32..f23780e 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -77,4 +77,8 @@ COM_JEDCHECKER_ERROR_XML_UPDATE_SERVER_LINK_NOT_FOUND="Update Server link not fo COM_JEDCHECKER_INFO_XML_UPDATE_SERVER_LINK="The Update Server link in this XML file is: %s" COM_JEDCHECKER_DELETE_FAILED="Can't delete temporary folder" COM_JEDCHECKER_DELETE_SUCCESS="Temporary folder deleted!" -COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" \ No newline at end of file +COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" +COM_JEDCHECKER_XML_FILES="Check files/folders references" +COM_JEDCHECKER_XML_FILES_DESC="Check for incorrect files and folders references in the XML manifest" +COM_JEDCHECKER_XML_FILES_FILE_NOT_FOUND="File not found: %s" +COM_JEDCHECKER_XML_FILES_FOLDER_NOT_FOUND="Folder not found: %s" \ No newline at end of file diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php new file mode 100644 index 0000000..7267654 --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php @@ -0,0 +1,228 @@ + + * eaxs + * Denis Ryabov + * + * @license GNU General Public License version 2 or later; see LICENSE.txt + */ + +defined('_JEXEC') or die('Restricted access'); + + +// Include the rule base class +require_once JPATH_COMPONENT_ADMINISTRATOR . '/models/rule.php'; + + +/** + * class JedcheckerRulesXMLFiles + * + * This class searches all xml manifestes for valid files declarations + * + * @since 2.3 + */ +class JedcheckerRulesXMLFiles extends JEDcheckerRule +{ + /** + * The formal ID of this rule. For example: SE1. + * + * @var string + */ + protected $id = 'XMLFILES'; + + /** + * The title or caption of this rule. + * + * @var string + */ + protected $title = 'COM_JEDCHECKER_XML_FILES'; + + /** + * The description of this rule. + * + * @var string + */ + protected $description = 'COM_JEDCHECKER_XML_FILES_DESC'; + + /** + * List of errors. + * + * @var string[] + */ + protected $errors; + + /** + * Initiates the search and check + * + * @return void + */ + public function check() + { + // Find all XML files of the extension + $files = JFolder::files($this->basedir, '.xml$', true, true); + + // Iterate through all the xml files + foreach ($files as $file) + { + // Try to check the file + $this->find($file); + } + } + + /** + * Reads a file and validate XML manifest + * + * @param string $file - The path to the file + * + * @return boolean True if the manifest file was found, otherwise False. + */ + protected function find($file) + { + $xml = JFactory::getXml($file); + + // Failed to parse the xml file. + // Assume that this is not a extension manifest + if (!$xml) + { + return false; + } + + // Check if this is an extension manifest + if ($xml->getName() !== 'extension') + { + return false; + } + + $this->errors = array(); + + // check declared files and folders do exist + + $basedir = dirname($file) . '/'; + + // check: files[folder] (filename|folder)* + if (isset($xml->files)) + { + $node = $xml->files; + $dir = $basedir . (isset($node['folder']) ? $node['folder'] . '/' : ''); + $this->checkFiles($node->filename, $dir); + $this->checkFolders($node->folder, $dir); + } + + // check: media[folder] (filename|folder)* + if (isset($xml->media)) + { + $node = $xml->media; + $dir = $basedir . (isset($node['folder']) ? $node['folder'] . '/' : ''); + $this->checkFiles($node->filename, $dir); + $this->checkFolders($node->folder, $dir); + } + + // check files: languages[folder] language* + if (isset($xml->languages)) + { + $node = $xml->languages; + $dir = $basedir . (isset($node['folder']) ? $node['folder'] . '/' : ''); + $this->checkFiles($node->language, $dir); + } + + // check: administration files[folder] (filename|folder)* + if (isset($xml->administration->files)) + { + $node = $xml->administration->files; + $dir = $basedir . (isset($node['folder']) ? $node['folder'] . '/' : ''); + $this->checkFiles($node->filename, $dir); + $this->checkFolders($node->folder, $dir); + } + + // check: administration media[folder] (filename|folder)* + if (isset($xml->administration->media)) + { + $node = $xml->administration->media; + $dir = $basedir . (isset($node['folder']) ? $node['folder'] . '/' : ''); + $this->checkFiles($node->filename, $dir); + $this->checkFolders($node->folder, $dir); + } + + // check files: administration languages[folder] language* + if (isset($xml->administration->languages)) + { + $node = $xml->administration->languages; + $dir = $basedir . (isset($node['folder']) ? $node['folder'] . '/' : ''); + $this->checkFiles($node->language, $dir); + } + + // check file: scriptfile + if (isset($xml->scriptfile)) + { + $this->checkFiles($xml->scriptfile, $basedir); + } + + // check files: install sql file* + if (isset($xml->install->sql->file)) + { + $this->checkFiles($xml->install->sql->file, $basedir); + } + + // check files: uninstall sql file* + if (isset($xml->uninstall->sql->file)) + { + $this->checkFiles($xml->uninstall->sql->file, $basedir); + } + + // check folders: update schemas schemapath* + if (isset($xml->update->schemas->schemapath)) + { + $this->checkFolders($xml->update->schemas->schemapath, $basedir); + } + + if (count($this->errors)) + { + $this->report->addError($file, implode('
', $this->errors)); + } + + // All checks passed. Return true + return true; + } + + /** + * Check files exist + * + * @param JXMLElement $files Files to check + * @param string $dir Base directory + * + * @return void + */ + protected function checkFiles($files, $dir) + { + foreach ($files as $file) + { + if (!is_file($dir . $file)) + { + $this->errors[] = JText::sprintf('COM_JEDCHECKER_XML_FILES_FILE_NOT_FOUND', (string)$file); + } + } + } + + /** + * Check folders exist + * + * @param JXMLElement $folders Directories to check + * @param string $dir Base directory + * + * @return void + */ + protected function checkFolders($folders, $dir) + { + foreach ($folders as $folder) + { + if (!is_dir($dir . $folder)) + { + $this->errors[] = JText::sprintf('COM_JEDCHECKER_XML_FILES_FOLDER_NOT_FOUND', (string)$folder); + } + } + } +} From 46ec8bd40aaf5c2f41bda3e098148f00be4a49a8 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 2 Feb 2021 19:10:59 +0300 Subject: [PATCH 007/238] update @since tag --- .../components/com_jedchecker/libraries/rules/xmlmanifest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php index 328605d..7095a20 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -23,7 +23,7 @@ require_once JPATH_COMPONENT_ADMINISTRATOR . '/models/rule.php'; * * This class validates all xml manifestes * - * @since 1.0 + * @since 2.3 */ class JedcheckerRulesXMLManifest extends JEDcheckerRule { From 4d67fe06028e5ea5e7777921676cc827805afedc Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 3 Feb 2021 01:14:16 +0300 Subject: [PATCH 008/238] Add validation of language files --- .../language/en-GB/en-GB.com_jedchecker.ini | 14 +- .../libraries/rules/language.php | 158 ++++++++++++++++++ 2 files changed, 171 insertions(+), 1 deletion(-) create mode 100644 administrator/components/com_jedchecker/libraries/rules/language.php diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index 7231b32..1482f63 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -77,4 +77,16 @@ COM_JEDCHECKER_ERROR_XML_UPDATE_SERVER_LINK_NOT_FOUND="Update Server link not fo COM_JEDCHECKER_INFO_XML_UPDATE_SERVER_LINK="The Update Server link in this XML file is: %s" COM_JEDCHECKER_DELETE_FAILED="Can't delete temporary folder" COM_JEDCHECKER_DELETE_SUCCESS="Temporary folder deleted!" -COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" \ No newline at end of file +COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" +COM_JEDCHECKER_LANG="Language files" +COM_JEDCHECKER_LANG_DESC="Validates language files" +COM_JEDCHECKER_LANG_INCORRECT_COMMENT="Incorrect comment character, use ';' instead" +COM_JEDCHECKER_LANG_WRONG_LINE="Incorrect line without '=' character" +COM_JEDCHECKER_LANG_KEY_EMPTY="Empty key name" +COM_JEDCHECKER_LANG_KEY_WHITESPACE="Whitespace in the key is not allowed" +COM_JEDCHECKER_LANG_KEY_INVALID_CHARACTER="Incorrect character in the key name" +COM_JEDCHECKER_LANG_KEY_RESERVED="Reserved keyword in the key name" +COM_JEDCHECKER_LANG_TRANSLATION_QUOTES="All translation strings should be in double quotation marks" +COM_JEDCHECKER_LANG_TRANSLATION_EMPTY="Empty translation string" +COM_JEDCHECKER_LANG_QQ_DEPRECATED="Usage of \"_QQ_\" is deprecated since Joomla! 3.9. Use escaped double quotes (\\\") instead" +COM_JEDCHECKER_LANG_RECOMMEND_ARGNUM="Substituted values may have another order in other languages. To simplify work of translators, it's recommended to use Argnum specification, see https://www.php.net/manual/en/function.sprintf.php for details" \ No newline at end of file diff --git a/administrator/components/com_jedchecker/libraries/rules/language.php b/administrator/components/com_jedchecker/libraries/rules/language.php new file mode 100644 index 0000000..1f7467d --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/language.php @@ -0,0 +1,158 @@ + + * eaxs + * Denis Ryabov + * + * @license GNU General Public License version 2 or later; see LICENSE.txt + */ + +defined('_JEXEC') or die('Restricted access'); + + +// Include the rule base class +require_once JPATH_COMPONENT_ADMINISTRATOR . '/models/rule.php'; + + +/** + * class JedcheckerRulesLanguage + * + * This class validates language ini file + * + * @since 2.3 + */ +class JedcheckerRulesLanguage extends JEDcheckerRule +{ + /** + * The formal ID of this rule. For example: SE1. + * + * @var string + */ + protected $id = 'LANG'; + + /** + * The title or caption of this rule. + * + * @var string + */ + protected $title = 'COM_JEDCHECKER_LANG'; + + /** + * The description of this rule. + * + * @var string + */ + protected $description = 'COM_JEDCHECKER_LANG_DESC'; + + /** + * Initiates the search and check + * + * @return void + */ + public function check() + { + // Find all INI files of the extension (in the format tag.extension.ini or tag.extension.sys.ini) + $files = JFolder::files($this->basedir, '^[a-z]{2,3}-[A-Z]{2}\.\w+(?:\.sys)?\.ini$', true, true); + + // Iterate through all the ini files + foreach ($files as $file) + { + // Try to validate the file + $this->find($file); + } + } + + /** + * Reads and validates an ini file + * + * @param string $file - The path to the file + * + * @return bool True on success, otherwise False. + */ + protected function find($file) + { + $lines = file($file); + foreach ($lines as $lineno => $line) + { + $line = trim($line); + if ($line === '' || $line[0] === ';' || $line[0] === '[') + { + continue; + } + if ($line[0] === '#') + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_INCORRECT_COMMENT') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + if (strpos($line, '=') === false) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_WRONG_LINE') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + list ($key, $value) = explode('=', $line, 2); + + $key = rtrim($key); + if ($key === '') + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_EMPTY') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + if (strpos($key, ' ') !== false) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_WHITESPACE') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + if (strpbrk($key, '{}|&~![()^"') !== false) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_INVALID_CHARACTER') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + if (in_array($key, array('null', 'yes', 'no', 'true', 'false', 'on', 'off', 'none'), true)) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_RESERVED') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + $value = ltrim($value); + if (strlen($value) <2 || $value[0] !== '"' || substr($value, -1) !== '"') + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_TRANSLATION_QUOTES') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + if ($value === '""') + { + $this->report->addWarning($file, JText::_('COM_JEDCHECKER_LANG_TRANSLATION_EMPTY') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + + $value = substr($value, 1, -1); + if (strpos($value, '"_QQ_"') !== false) + { + $this->report->addInfo($file, JText::_('COM_JEDCHECKER_LANG_QQ_DEPRECATED') . + '
' . htmlspecialchars($line), $lineno); + } + + $count1 = preg_match_all('/(?<=^|[^%])%(?=[-+0 ]?\w)/', $value); + $count2 = preg_match_all('/(?<=^|[^%])%\d+\$/', $value); + if ($count1 > 1 && $count2 < $count1) { + // @todo It's not mentioned in docs + $this->report->addInfo($file, JText::_('COM_JEDCHECKER_LANG_RECOMMEND_ARGNUM') . + '
' . htmlspecialchars($line), $lineno); + } + } + + // All checks passed. Return true + return true; + } +} From 80abc68994fa2ff86cad61b34a5e0971ef4a5196 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sat, 13 Feb 2021 23:01:07 +0300 Subject: [PATCH 009/238] support of Joomla!4 --- .../libraries/rules/xmlinfo.php | 2 +- .../libraries/rules/xmllicense.php | 2 +- .../libraries/rules/xmlupdateserver.php | 6 +- .../views/uploads/tmpl/default.php | 58 +++++++++++-------- 4 files changed, 38 insertions(+), 30 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index b4037be..39dade0 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -74,7 +74,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule */ protected function find($file) { - $xml = JFactory::getXml($file); + $xml = simplexml_load_file($file); // Get all the info about the file $folder_info = pathinfo($file); diff --git a/administrator/components/com_jedchecker/libraries/rules/xmllicense.php b/administrator/components/com_jedchecker/libraries/rules/xmllicense.php index 3ce8729..b2280b2 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmllicense.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmllicense.php @@ -72,7 +72,7 @@ class JedcheckerRulesXMLlicense extends JEDcheckerRule */ protected function find($file) { - $xml = JFactory::getXml($file); + $xml = simplexml_load_file($file); // Failed to parse the xml file. // Assume that this is not a extension manifest diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlupdateserver.php b/administrator/components/com_jedchecker/libraries/rules/xmlupdateserver.php index 8e7850e..108384f 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlupdateserver.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlupdateserver.php @@ -79,7 +79,7 @@ class JedcheckerRulesXMLUpdateServer extends JEDcheckerRule foreach ($files as $file) { - $xml = JFactory::getXml($file); + $xml = simplexml_load_file($file); // Check if this is an XML and an extension manifest if ($xml && ($xml->getName() == 'install' || $xml->getName() == 'extension')) @@ -116,7 +116,7 @@ class JedcheckerRulesXMLUpdateServer extends JEDcheckerRule foreach ($files as $file) { - $xml = JFactory::getXml($file); + $xml = simplexml_load_file($file); // Check if this is an XML and an extension manifest if ($xml && ($xml->getName() == 'install' || $xml->getName() == 'extension')) @@ -174,7 +174,7 @@ class JedcheckerRulesXMLUpdateServer extends JEDcheckerRule */ protected function find($file) { - $xml = JFactory::getXml($file); + $xml = simplexml_load_file($file); // Failed to parse the xml file. // Assume that this is not a extension manifest diff --git a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php index 0c6ebef..7d48961 100644 --- a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php +++ b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php @@ -11,28 +11,35 @@ defined('_JEXEC') or die('Restricted access'); -JHtml::_('behavior.framework', true); -JHtml::stylesheet('media/com_jedchecker/css/style.min.css'); -?> - - - - =') ) { ?> @@ -114,7 +122,7 @@ function add_validation() { From 329df9856253b160d2ab7200881c6427aec5d791 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sat, 13 Feb 2021 23:53:09 +0300 Subject: [PATCH 010/238] Joomla!4 compatibility --- .../com_jedchecker/libraries/rules/xmlmanifest.php | 2 +- .../libraries/rules/xmlmanifest_component.json | 6 +++++- .../com_jedchecker/libraries/rules/xmlmanifest_module.json | 6 +++++- .../com_jedchecker/libraries/rules/xmlmanifest_plugin.json | 6 +++++- 4 files changed, 16 insertions(+), 4 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php index 7095a20..506f7f9 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -111,7 +111,7 @@ class JedcheckerRulesXMLManifest extends JEDcheckerRule */ protected function find($file) { - $xml = JFactory::getXml($file); + $xml = simplexml_load_file($file); // Failed to parse the xml file. // Assume that this is not a extension manifest diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json index 6a6d949..c155b1e 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json @@ -21,7 +21,8 @@ "administration": "?", "updateservers": "!", "config": "?", - "dlid": "?" + "dlid": "?", + "namespace": "?" }, "administration": { "menu": "=", @@ -115,6 +116,9 @@ "priority", "type" ], + "namespace": [ + "path" + ], "params": [ "addParameterDir" ], diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json index 8747f30..8792f34 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json @@ -20,7 +20,8 @@ "media": "?", "updateservers": "!", "config": "?", - "dlid": "?" + "dlid": "?", + "namespace": "?" }, "files": { "filename": "*", @@ -96,6 +97,9 @@ "priority", "type" ], + "namespace": [ + "path" + ], "fields": [ "addfieldpath", "name" diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json index 45bd081..8f75832 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json @@ -20,7 +20,8 @@ "media": "?", "updateservers": "!", "config": "?", - "dlid": "?" + "dlid": "?", + "namespace": "?" }, "files": { "filename": "*", @@ -97,6 +98,9 @@ "priority", "type" ], + "namespace": [ + "path" + ], "fields": [ "addfieldpath", "name" From 331a9e162f00ec1c4898e763810144766900ccf7 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sat, 13 Feb 2021 23:53:26 +0300 Subject: [PATCH 011/238] support for "package" type --- .../libraries/rules/xmlmanifest_package.json | 64 +++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 administrator/components/com_jedchecker/libraries/rules/xmlmanifest_package.json diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_package.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_package.json new file mode 100644 index 0000000..393aaeb --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_package.json @@ -0,0 +1,64 @@ +{ + "nodes": { + "extension": { + "name": "!", + "packagename": "!", + "creationDate": "=", + "author": "=", + "authorEmail": "=", + "authorUrl": "=", + "copyright": "=", + "version": "!", + "description": "=", + "license": "!", + "scriptfile": "?", + "update": "?", + "files": "?", + "languages": "?", + "updateservers": "!", + "dlid": "?", + "packager": "?", + "packagerurl": "?", + "blockChildUninstall": "?" + }, + "files": { + "file": "*", + "folder": "*" + }, + "languages": { + "language": "*" + }, + "updateservers": { + "server": "*" + } + }, + "attributes": { + "extension": [ + "method", + "overwrite", + "type", + "version" + ], + "files": [ + "folder" + ], + "file": [ + "client", + "group", + "id", + "type" + ], + "languages": [ + "folder" + ], + "language": [ + "client", + "tag" + ], + "server": [ + "name", + "priority", + "type" + ] + } +} \ No newline at end of file From 4f899fb39bb5098030cbe04f43d2458ac9ca5ad0 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sat, 13 Feb 2021 23:53:36 +0300 Subject: [PATCH 012/238] fix regex --- .../components/com_jedchecker/libraries/rules/xmlmanifest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php index 506f7f9..2802fd0 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -92,7 +92,7 @@ class JedcheckerRulesXMLManifest extends JEDcheckerRule public function check() { // Find all XML files of the extension - $files = JFolder::files($this->basedir, '.xml$', true, true); + $files = JFolder::files($this->basedir, '\.xml$', true, true); // Iterate through all the xml files foreach ($files as $file) From a206aa91ba57e713e1aa83182467664776834d9b Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sat, 13 Feb 2021 23:56:51 +0300 Subject: [PATCH 013/238] Joomla!4 compatibility --- .../components/com_jedchecker/libraries/rules/xmlfiles.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php index 7267654..a82b6ab 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php @@ -82,7 +82,7 @@ class JedcheckerRulesXMLFiles extends JEDcheckerRule */ protected function find($file) { - $xml = JFactory::getXml($file); + $xml = simplexml_load_file($file); // Failed to parse the xml file. // Assume that this is not a extension manifest From 0bf71c095039f29266baeb749f681ec56d9ba193 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sat, 13 Feb 2021 23:56:59 +0300 Subject: [PATCH 014/238] fix regex --- .../components/com_jedchecker/libraries/rules/xmlfiles.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php index a82b6ab..1545048 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php @@ -63,7 +63,7 @@ class JedcheckerRulesXMLFiles extends JEDcheckerRule public function check() { // Find all XML files of the extension - $files = JFolder::files($this->basedir, '.xml$', true, true); + $files = JFolder::files($this->basedir, '\.xml$', true, true); // Iterate through all the xml files foreach ($files as $file) From a1197006e578b8215a7261f23242aa1d0dd16d41 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sun, 14 Feb 2021 00:02:08 +0300 Subject: [PATCH 015/238] check packages --- .../components/com_jedchecker/libraries/rules/xmlfiles.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php index 1545048..7c6d0a6 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php @@ -104,11 +104,13 @@ class JedcheckerRulesXMLFiles extends JEDcheckerRule $basedir = dirname($file) . '/'; // check: files[folder] (filename|folder)* + // for package: files[folder] (file|folder)* if (isset($xml->files)) { $node = $xml->files; $dir = $basedir . (isset($node['folder']) ? $node['folder'] . '/' : ''); $this->checkFiles($node->filename, $dir); + $this->checkFiles($node->file, $dir); // for packages $this->checkFolders($node->folder, $dir); } From 4850ef0d43a19ca64121c1f7e46de1593f4f6e8d Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sun, 14 Feb 2021 01:18:25 +0300 Subject: [PATCH 016/238] remove check of config section from component manifest --- .../libraries/rules/xmlmanifest_component.json | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json index c155b1e..4733143 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json @@ -64,15 +64,6 @@ "updateservers": { "server": "*" }, - "config": { - "fields": "!" - }, - "fields": { - "fieldset": "+" - }, - "fieldset": { - "???": "*" - } }, "attributes": { "extension": [ @@ -119,12 +110,6 @@ "namespace": [ "path" ], - "params": [ - "addParameterDir" - ], - "param": [ - "addParameterDir" - ], "dlid": [ "prefix", "suffix" From 75d1f5f8710989d37442660af501e21601d4816d Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sun, 14 Feb 2021 01:19:04 +0300 Subject: [PATCH 017/238] add more field attributes and fieldset params --- .../libraries/rules/xmlmanifest_module.json | 14 +++++++++++++- .../libraries/rules/xmlmanifest_plugin.json | 14 +++++++++++++- 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json index 8792f34..e387a2f 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json @@ -105,14 +105,26 @@ "name" ], "fieldset": [ + "description", + "label", "name" ], "field": [ + "class", + "cols", "default", "description", + "filter", + "id", "label", + "maxLength", "name", - "type" + "required", + "rows", + "size", + "step", + "type", + "validate" ], "option": [ "value" diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json index 8f75832..3eaa7f3 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json @@ -106,14 +106,26 @@ "name" ], "fieldset": [ + "description", + "label", "name" ], "field": [ + "class", + "cols", "default", "description", + "filter", + "id", "label", + "maxLength", "name", - "type" + "required", + "rows", + "size", + "step", + "type", + "validate" ], "option": [ "value" From e83378549453be304765d72454b64f5dcb45f62a Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 18 Feb 2021 15:13:51 +0300 Subject: [PATCH 018/238] fix paths for language dirs --- .../components/com_jedchecker/libraries/rules/xmlinfo.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index 0b30250..34282ad 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -142,11 +142,11 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule $lookup_lang_dirs[] = 'language/' . $lang_tag; if (isset($xml->administration->languages['folder'])) { - $lookup_lang_dirs[] = trim($xml->administration->languages['folder'], '/'); + $lookup_lang_dirs[] = trim($xml->administration->languages['folder'], '/') . '/' . $lang_tag; } if (isset($xml->languages['folder'])) { - $lookup_lang_dirs[] = trim($xml->languages['folder'], '/'); + $lookup_lang_dirs[] = trim($xml->languages['folder'], '/') . '/' . $lang_tag; } $lookup_lang_dirs[] = ''; @@ -154,7 +154,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule { $lang_sys_file = $lang_dir . '/' . - ($dir === '' ? '' : trim($dir, '/') . '/') . + ($dir === '' ? '' : $dir . '/') . $lang_tag. '.' . $extension . '.sys.ini'; if (is_file($lang_sys_file)) { From 8b0898713d01b5d01c3d1b9d6dc8758fdb8d680b Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 18 Feb 2021 15:16:51 +0300 Subject: [PATCH 019/238] fix json --- .../com_jedchecker/libraries/rules/xmlmanifest_component.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json index 4733143..1802074 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json @@ -63,7 +63,7 @@ }, "updateservers": { "server": "*" - }, + } }, "attributes": { "extension": [ From d508bbad6b1023ca38a29bc30c615cbe19b7e200 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 18 Feb 2021 15:17:13 +0300 Subject: [PATCH 020/238] add addfieldpath attribute to all form fields --- .../com_jedchecker/libraries/rules/xmlmanifest_module.json | 5 +++++ .../com_jedchecker/libraries/rules/xmlmanifest_plugin.json | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json index e387a2f..87615ce 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json @@ -100,16 +100,21 @@ "namespace": [ "path" ], + "config": [ + "addfieldpath" + ], "fields": [ "addfieldpath", "name" ], "fieldset": [ + "addfieldpath", "description", "label", "name" ], "field": [ + "addfieldpath", "class", "cols", "default", diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json index 3eaa7f3..4eb09ef 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json @@ -101,16 +101,21 @@ "namespace": [ "path" ], + "config": [ + "addfieldpath" + ], "fields": [ "addfieldpath", "name" ], "fieldset": [ + "addfieldpath", "description", "label", "name" ], "field": [ + "addfieldpath", "class", "cols", "default", From 5bab76e834271ae800b1495e44841d4c8e6e12b0 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 18 Feb 2021 15:20:00 +0300 Subject: [PATCH 021/238] don't warn on missed unzipped files (in packages) --- .../com_jedchecker/libraries/rules/xmlfiles.php | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php index 7c6d0a6..ad15c4e 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php @@ -202,10 +202,17 @@ class JedcheckerRulesXMLFiles extends JEDcheckerRule { foreach ($files as $file) { - if (!is_file($dir . $file)) + $filename = $dir . $file; + if (is_file($filename)) { - $this->errors[] = JText::sprintf('COM_JEDCHECKER_XML_FILES_FILE_NOT_FOUND', (string)$file); + continue; } + // extra check for unzipped files + if (preg_match('/^(.*)\.(zip|tar\.gz)$/', $filename, $matches) && is_dir($matches[1])) + { + continue; + } + $this->errors[] = JText::sprintf('COM_JEDCHECKER_XML_FILES_FILE_NOT_FOUND', (string)$file); } } From f536d77cc3f29e863f91ab014fa37be01bc4d78a Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 18 Feb 2021 15:24:28 +0300 Subject: [PATCH 022/238] fix matching of plugin group in title (remove spaces for "Action Log", "Quick Icons", etc.) --- .../components/com_jedchecker/libraries/rules/xmlinfo.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index 34282ad..285f565 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -219,8 +219,9 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule if ($type === 'plugin') { - $group = (string) $xml['group']; - if (strpos($extension_name, ucfirst($group) . ' - ') !== 0) + $parts = explode(' - ', $extension_name, 2); + $extension_name_group = isset($parts[1]) ? strtolower(preg_replace('/\s/', '', $parts[0])) : false; + if ($extension_name_group !== (string) $xml['group']) { $this->report->addWarning($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT')); } From 216e4820092f509f824c78aa2c052fd6e559be7b Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 18 Feb 2021 15:25:03 +0300 Subject: [PATCH 023/238] display plugin name in the message (for packages with multiple plugins) --- .../com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini | 2 +- .../components/com_jedchecker/libraries/rules/xmlinfo.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index 918481f..655f058 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -51,7 +51,7 @@ COM_JEDCHECKER_INFO_XML_NAME_JOOMLA="An extension name can't start with the word COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the extension name need to be licensed by OSM" COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the domain name need to be licensed by OSM" COM_JEDCHECKER_INFO_XML_NAME_ADMIN_MENU="The admin menu name '%1$s' isn't the same as the extension name '%2$s'" -COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT="The name of the plugin must comply with the JED naming conventions in the form '{Type} - {Extension Name}'" +COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT="The name of the plugin ('%s') must comply with the JED naming conventions in the form '{Type} - {Extension Name}'" COM_JEDCHECKER_RULE_PH1="PHP Headers missing GPL License Notice" COM_JEDCHECKER_RULE_PH1_DESC="A notice is required on each PHP file stating that the file is licensed GPL (or other compatible accepted license). For more information, please click here." COM_JEDCHECKER_ERROR_GPL_NOT_FOUND="GPL or compatible license was not found" diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index 285f565..836aed1 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -223,7 +223,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule $extension_name_group = isset($parts[1]) ? strtolower(preg_replace('/\s/', '', $parts[0])) : false; if ($extension_name_group !== (string) $xml['group']) { - $this->report->addWarning($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT')); + $this->report->addWarning($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT', $extension_name)); } } From 53c5903fa0e3ce9c75145dd566ae464aa06c982e Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 23 Feb 2021 21:07:30 +0300 Subject: [PATCH 024/238] remove leading '*' character to deal with multi-line license names --- .../components/com_jedchecker/libraries/rules/gpl.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/administrator/components/com_jedchecker/libraries/rules/gpl.php b/administrator/components/com_jedchecker/libraries/rules/gpl.php index c70e89e..718f425 100644 --- a/administrator/components/com_jedchecker/libraries/rules/gpl.php +++ b/administrator/components/com_jedchecker/libraries/rules/gpl.php @@ -191,6 +191,9 @@ class JedcheckerRulesGpl extends JEDcheckerRule $content = file_get_contents($file); + // Remove leading "*" characters from phpDoc-like comments + $content = preg_replace('/^\s*\*/m', '', $content); + if (preg_match($this->regex_gpl_licenses, $content, $match, PREG_OFFSET_CAPTURE)) { $line_no = substr_count($content, "\n", 0, $match[0][1]) + 1; From 7741b2b0ced6b0db971633bcc01367b885c36416 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 23 Feb 2021 21:10:16 +0300 Subject: [PATCH 025/238] move licenses list to gpl directory --- .../components/com_jedchecker/libraries/rules/gpl.php | 4 ++-- .../libraries/rules/{gpl_compat.txt => gpl/compat.txt} | 0 .../libraries/rules/{gpl_gnu.txt => gpl/gnu.txt} | 0 3 files changed, 2 insertions(+), 2 deletions(-) rename administrator/components/com_jedchecker/libraries/rules/{gpl_compat.txt => gpl/compat.txt} (100%) rename administrator/components/com_jedchecker/libraries/rules/{gpl_gnu.txt => gpl/gnu.txt} (100%) diff --git a/administrator/components/com_jedchecker/libraries/rules/gpl.php b/administrator/components/com_jedchecker/libraries/rules/gpl.php index 718f425..046e538 100644 --- a/administrator/components/com_jedchecker/libraries/rules/gpl.php +++ b/administrator/components/com_jedchecker/libraries/rules/gpl.php @@ -91,10 +91,10 @@ class JedcheckerRulesGpl extends JEDcheckerRule */ protected function init() { - $gpl_licenses = (array) file(__DIR__ . '/gpl_gnu.txt'); + $gpl_licenses = (array) file(__DIR__ . '/gpl/gnu.txt'); $this->regex_gpl_licenses = $this->generate_regexp($gpl_licenses); - $compat_licenses = (array) file(__DIR__ . '/gpl_compat.txt'); + $compat_licenses = (array) file(__DIR__ . '/gpl/compat.txt'); $extra_licenses = $this->params->get('constants'); $extra_licenses = explode(',', $extra_licenses); diff --git a/administrator/components/com_jedchecker/libraries/rules/gpl_compat.txt b/administrator/components/com_jedchecker/libraries/rules/gpl/compat.txt similarity index 100% rename from administrator/components/com_jedchecker/libraries/rules/gpl_compat.txt rename to administrator/components/com_jedchecker/libraries/rules/gpl/compat.txt diff --git a/administrator/components/com_jedchecker/libraries/rules/gpl_gnu.txt b/administrator/components/com_jedchecker/libraries/rules/gpl/gnu.txt similarity index 100% rename from administrator/components/com_jedchecker/libraries/rules/gpl_gnu.txt rename to administrator/components/com_jedchecker/libraries/rules/gpl/gnu.txt From 2c28bafe4768c9d399037eb5113034401ee29ba8 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 23 Feb 2021 21:12:54 +0300 Subject: [PATCH 026/238] add extra names (BSD v2 and BSD v3) into licenses list --- .../components/com_jedchecker/libraries/rules/gpl/compat.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/administrator/components/com_jedchecker/libraries/rules/gpl/compat.txt b/administrator/components/com_jedchecker/libraries/rules/gpl/compat.txt index 777bed6..694db2e 100644 --- a/administrator/components/com_jedchecker/libraries/rules/gpl/compat.txt +++ b/administrator/components/com_jedchecker/libraries/rules/gpl/compat.txt @@ -20,11 +20,13 @@ Zero-Clause BSD / Free Public License v1.0.0 1-clause BSD License (BSD-1-Clause) BSD 1-Clause License 2-clause BSD License (BSD-2-Clause) +BSD v2 (BSDv2) BSD 2-Clause "Simplified" License BSD-2-Clause Plus Patent License (BSD-2-Clause-Patent) BSD+Patent FreeBSD License 3-clause BSD License (BSD-3-Clause) +BSD v3 (BSDv3) BSD 3-Clause "New" or "Revised" License Lawrence Berkeley National Labs BSD variant License (BSD-3-Clause-LBNL) Modified BSD License From 5fafb747f0b7ed00c12cc9db93c7067a319e2178 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:06:02 +0300 Subject: [PATCH 027/238] fix loop through children nodes --- .../com_jedchecker/libraries/rules/xmlinfo.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index 836aed1..5fea42c 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -109,11 +109,14 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule else { $extension = (string) $xml->name; - foreach ($xml->files->children as $child) + if (isset($xml->files)) { - if (isset($child[$type])) + foreach ($xml->files->children() as $child) { - $extension = (string) $child[$type]; + if (isset($child[$type])) + { + $extension = (string) $child[$type]; + } } } } From 75b6aa0f47d3ed1b99db46c3416ca6d15fa969f3 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:16:31 +0300 Subject: [PATCH 028/238] fix loading of language file --- .../libraries/rules/xmlinfo.php | 37 +++++++++++++++++-- 1 file changed, 33 insertions(+), 4 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index 5fea42c..21cef5f 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -126,6 +126,11 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule $extension = 'com_' . $extension; } + if ($type === 'plugin' && isset($xml['group'])) + { + $extension = 'plg_' . $xml['group'] . '_' . $extension; + } + // Load the language of the extension (if any) $lang = JFactory::getLanguage(); @@ -134,25 +139,49 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule $lang_tag = 'en-GB'; // $lang->getDefault(); $lookup_lang_dirs = array(); + if (isset($xml->administration->files['folder'])) { $lookup_lang_dirs[] = trim($xml->administration->files['folder'], '/') . '/language/' . $lang_tag; } + if (isset($xml->files['folder'])) { $lookup_lang_dirs[] = trim($xml->files['folder'], '/') . '/language/' . $lang_tag; } + $lookup_lang_dirs[] = 'language/' . $lang_tag; - if (isset($xml->administration->languages['folder'])) + + if (isset($xml->administration->languages)) { - $lookup_lang_dirs[] = trim($xml->administration->languages['folder'], '/') . '/' . $lang_tag; + $folder = trim($xml->administration->languages['folder'], '/'); + + foreach ($xml->administration->languages->language as $language) + { + if (trim($language['tag']) === $lang_tag) + { + $lookup_lang_dirs[] = trim($folder . '/' . dirname($language), '/'); + } + } } - if (isset($xml->languages['folder'])) + + if (isset($xml->languages)) { - $lookup_lang_dirs[] = trim($xml->languages['folder'], '/') . '/' . $lang_tag; + $folder = trim($xml->languages['folder'], '/'); + + foreach ($xml->languages->language as $language) + { + if (trim($language['tag']) === $lang_tag) + { + $lookup_lang_dirs[] = trim($folder . '/' . dirname($language), '/'); + } + } } + $lookup_lang_dirs[] = ''; + $lookup_lang_dirs = array_unique($lookup_lang_dirs); + foreach ($lookup_lang_dirs as $dir) { $lang_sys_file = From 5771fb0203003fe0ae215e69e74fa2168be26b22 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:20:09 +0300 Subject: [PATCH 029/238] add list of alternative plugin group names --- .../com_jedchecker/libraries/rules/xmlinfo.php | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index 21cef5f..c3e3921 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -47,6 +47,18 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule */ protected $description = 'COM_JEDCHECKER_INFO_XML_DESC'; + /** + * Mapping of the plugin title prefix to the plugin group + * + * @var string[] + */ + protected $pluginsGroupMap = array( + 'button' => 'editors-xtd', + 'editor' => 'editors', + 'smartsearch' => 'finder', + 'twofactorauthentication' => 'twofactorauth' + ); + /** * Initiates the search and check * @@ -253,7 +265,11 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule { $parts = explode(' - ', $extension_name, 2); $extension_name_group = isset($parts[1]) ? strtolower(preg_replace('/\s/', '', $parts[0])) : false; - if ($extension_name_group !== (string) $xml['group']) + $group = (string) $xml['group']; + + if ($extension_name_group !== $group && $extension_name_group !== str_replace('-', '', $group) + && !(isset($this->pluginsGroupMap[$extension_name_group]) && $this->pluginsGroupMap[$extension_name_group] === $group) + ) { $this->report->addWarning($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT', $extension_name)); } From c11c23c15a093df5f9b0c738f245d5a05d1ac0c0 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:24:48 +0300 Subject: [PATCH 030/238] check domain name against the list of approved domains --- .../language/en-GB/en-GB.com_jedchecker.ini | 2 +- .../libraries/rules/xmlinfo.php | 15 +++++- .../rules/xmlinfo/approved-domains.txt | 46 +++++++++++++++++++ 3 files changed, 60 insertions(+), 3 deletions(-) create mode 100644 administrator/components/com_jedchecker/libraries/rules/xmlinfo/approved-domains.txt diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index 655f058..a8717ec 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -49,7 +49,7 @@ COM_JEDCHECKER_INFO_XML_NAME_RESERVED_KEYWORDS="Keywords such as module, plugin COM_JEDCHECKER_INFO_XML_NAME_VERSION="Version in name/title" COM_JEDCHECKER_INFO_XML_NAME_JOOMLA="An extension name can't start with the word 'Joomla'" COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the extension name need to be licensed by OSM" -COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the domain name need to be licensed by OSM" +COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the domain name ('%s') need to be licensed by OSM" COM_JEDCHECKER_INFO_XML_NAME_ADMIN_MENU="The admin menu name '%1$s' isn't the same as the extension name '%2$s'" COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT="The name of the plugin ('%s') must comply with the JED naming conventions in the form '{Type} - {Extension Name}'" COM_JEDCHECKER_RULE_PH1="PHP Headers missing GPL License Notice" diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index c3e3921..b010207 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -247,8 +247,19 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule if (stripos($url, 'joom') !== false) { $domain = (strpos($url, '//') === false) ? $url : parse_url(trim($url), PHP_URL_HOST); - if (stripos($domain, 'joom') !== false) { - $this->report->addWarning($file, JText::_('COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE')); + + if (stripos($domain, 'joom') !== false) + { + // Remove "www." subdomain prefix + $domain = preg_replace('/^www\./', '', $domain); + + // Approved domains from https://tm.joomla.org/approved-domains.html + $approvedDomains = file(__DIR__ . '/xmlinfo/approved-domains.txt', FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES); + + if (!in_array($domain, $approvedDomains, true)) + { + $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE', $url)); + } } } diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo/approved-domains.txt b/administrator/components/com_jedchecker/libraries/rules/xmlinfo/approved-domains.txt new file mode 100644 index 0000000..6e8c234 --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo/approved-domains.txt @@ -0,0 +1,46 @@ +joomla.org + +hotjoomlatemplates.com +joomlanl.nl +joomla-templates.com +joomla-update.org +joomlaportal.ru +joomlavia.com +joomlatranslate.com +joomlamarketplace.online +hotjoomlatemplates.com +joomlatema.net +joomla.it +joomlaalger.org +joomla.cafe +joomlatwincities.org +joomlausersnj.com +joomlausersnyc.org +joomlact.org +joomlachicagonorth.com +joomlanh.org +joomlanh.org +joomlacarioca.com.br +novajoomla.com +joomlazur.com +joomladallas.org +joomlariodejaneiro.com.br +joomlatenerife.org +joomlage.com +joomlamadrid.org +joomschool.com +usingjoomla.com +joomla.cymru +joomlavigo.es +jug-warszawa.joomla.pl +joomlavalencia.net +jug-silesia.joomla.pl +jug-poznan.joomla.pl +joomla-canberra.org.au +joomlapay.com +joomlalondon.co.uk +mobilejoomla.com/ +myjoomla.com +joomlacontenteditor.net +joomlalabs.com +modernjoomla.com From 2cae2d0deb4287cb3ae2fa3e4d561a8b7325277d Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:44:53 +0300 Subject: [PATCH 031/238] show node content in errors/warnings messages --- .../language/en-GB/en-GB.com_jedchecker.ini | 10 +++++----- .../com_jedchecker/libraries/rules/xmlinfo.php | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index a8717ec..268791b 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -44,11 +44,11 @@ COM_JEDCHECKER_INFO_XML_NAME_XML="The name tag in this file is: %s" COM_JEDCHECKER_INFO_XML_VERSION_XML="Version tag has the value: %s" COM_JEDCHECKER_INFO_XML_CREATIONDATE_XML="The creationDate tag has the value: %s" COM_JEDCHECKER_INFO_XML_NO_MANIFEST="No manifest file found" -COM_JEDCHECKER_INFO_XML_NAME_MODULE_PLUGIN="Listing name contains 'module' or 'plugin'" -COM_JEDCHECKER_INFO_XML_NAME_RESERVED_KEYWORDS="Keywords such as module, plugin or template are considered reserved words and can't be used in the extension names" -COM_JEDCHECKER_INFO_XML_NAME_VERSION="Version in name/title" -COM_JEDCHECKER_INFO_XML_NAME_JOOMLA="An extension name can't start with the word 'Joomla'" -COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the extension name need to be licensed by OSM" +COM_JEDCHECKER_INFO_XML_NAME_MODULE_PLUGIN="Listing name ('%s') contains 'module' or 'plugin'" +COM_JEDCHECKER_INFO_XML_NAME_RESERVED_KEYWORDS="Keywords such as module, plugin or template are considered reserved words and can't be used in the extension names ('%s')" +COM_JEDCHECKER_INFO_XML_NAME_VERSION="Version in name/title ('%s')" +COM_JEDCHECKER_INFO_XML_NAME_JOOMLA="An extension name ('%s') can't start with the word 'Joomla'" +COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the extension name ('%s') need to be licensed by OSM" COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the domain name ('%s') need to be licensed by OSM" COM_JEDCHECKER_INFO_XML_NAME_ADMIN_MENU="The admin menu name '%1$s' isn't the same as the extension name '%2$s'" COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT="The name of the plugin ('%s') must comply with the JED naming conventions in the form '{Type} - {Extension Name}'" diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index b010207..d48e834 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -221,26 +221,26 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule // NM3 - Listing name contains “module” or “plugin” if (preg_match('/\b(?:module|plugin)\b/i', $extension_name)) { - $this->report->addError($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_MODULE_PLUGIN')); + $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_MODULE_PLUGIN', $extension_name)); } if (stripos($extension_name, 'template') !== false) { - $this->report->addWarning($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_RESERVED_KEYWORDS')); + $this->report->addWarning($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_RESERVED_KEYWORDS', $extension_name)); } // NM5 - Version in name/title if (preg_match('/(?:\bversion\b|\d\.\d)/i', $extension_name)) { - $this->report->addError($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_VERSION')); + $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_VERSION', $extension_name)); } if (stripos($extension_name, 'joomla') === 0) { - $this->report->addError($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_JOOMLA')); + $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_JOOMLA', $extension_name)); } elseif (stripos($extension_name, 'joom') !== false) { - $this->report->addWarning($file, JText::_('COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE')); + $this->report->addWarning($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE', $extension_name)); } $url = (string)$xml->authorUrl; From 72b55455287afe8bf3dce73dd064a839bb089d44 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 00:59:05 +0300 Subject: [PATCH 032/238] change translation string --- .../com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index 268791b..3c10c32 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -49,7 +49,7 @@ COM_JEDCHECKER_INFO_XML_NAME_RESERVED_KEYWORDS="Keywords such as module, plugin COM_JEDCHECKER_INFO_XML_NAME_VERSION="Version in name/title ('%s')" COM_JEDCHECKER_INFO_XML_NAME_JOOMLA="An extension name ('%s') can't start with the word 'Joomla'" COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the extension name ('%s') need to be licensed by OSM" -COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the domain name ('%s') need to be licensed by OSM" +COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE="Domain names that use 'Joomla' or a derivative of Joomla ('%s') need to be licensed by OSM" COM_JEDCHECKER_INFO_XML_NAME_ADMIN_MENU="The admin menu name '%1$s' isn't the same as the extension name '%2$s'" COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT="The name of the plugin ('%s') must comply with the JED naming conventions in the form '{Type} - {Extension Name}'" COM_JEDCHECKER_RULE_PH1="PHP Headers missing GPL License Notice" From 6091c866c0a60816e39bba2df716f83aa544e2b3 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:01:14 +0300 Subject: [PATCH 033/238] commenting the code --- .../components/com_jedchecker/libraries/rules/xmlinfo.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index d48e834..3e6e65d 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -113,6 +113,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule } // Get extension name (element) + $type = (string) $xml['type']; if (isset($xml->element)) { @@ -194,6 +195,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule $lookup_lang_dirs = array_unique($lookup_lang_dirs); + // Looking for language file in specified directories foreach ($lookup_lang_dirs as $dir) { $lang_sys_file = @@ -223,6 +225,8 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule { $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_MODULE_PLUGIN', $extension_name)); } + + // The "template" is reserved keyword if (stripos($extension_name, 'template') !== false) { $this->report->addWarning($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_RESERVED_KEYWORDS', $extension_name)); From 7a36ce7582bc52923f94823a376cc2b32e950d26 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:04:23 +0300 Subject: [PATCH 034/238] EOL at the end of language file (to simplify merging) --- .../com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index 3c10c32..b9f93d9 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -86,4 +86,4 @@ COM_JEDCHECKER_ERROR_XML_UPDATE_SERVER_LINK_NOT_FOUND="Update Server link not fo COM_JEDCHECKER_INFO_XML_UPDATE_SERVER_LINK="The Update Server link in this XML file is: %s" COM_JEDCHECKER_DELETE_FAILED="Can't delete temporary folder" COM_JEDCHECKER_DELETE_SUCCESS="Temporary folder deleted!" -COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" \ No newline at end of file +COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" From 77ffde4f6ccef7499d03f7ec3a99735488dfb82f Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:08:23 +0300 Subject: [PATCH 035/238] correct authors list for new rule --- .../components/com_jedchecker/libraries/rules/xmlmanifest.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php index 2802fd0..27b97ca 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -4,9 +4,7 @@ * * @copyright Copyright (C) 2017 - 2021 Open Source Matters, Inc. All rights reserved. * Copyright (C) 2008 - 2016 compojoom.com . All rights reserved. - * @author Daniel Dimitrov - * eaxs - * Denis Ryabov + * @author Denis Ryabov * * @license GNU General Public License version 2 or later; see LICENSE.txt */ From 62a887092cc31c0c48d40b144a066dc780796ebb Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:27:50 +0300 Subject: [PATCH 036/238] move dtd files to a separate directory --- .../components/com_jedchecker/libraries/rules/xmlmanifest.php | 2 +- .../dtd_component.json} | 0 .../{xmlmanifest_module.json => xmlmanifest/dtd_module.json} | 0 .../{xmlmanifest_package.json => xmlmanifest/dtd_package.json} | 0 .../{xmlmanifest_plugin.json => xmlmanifest/dtd_plugin.json} | 0 5 files changed, 1 insertion(+), 1 deletion(-) rename administrator/components/com_jedchecker/libraries/rules/{xmlmanifest_component.json => xmlmanifest/dtd_component.json} (100%) rename administrator/components/com_jedchecker/libraries/rules/{xmlmanifest_module.json => xmlmanifest/dtd_module.json} (100%) rename administrator/components/com_jedchecker/libraries/rules/{xmlmanifest_package.json => xmlmanifest/dtd_package.json} (100%) rename administrator/components/com_jedchecker/libraries/rules/{xmlmanifest_plugin.json => xmlmanifest/dtd_plugin.json} (100%) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php index 27b97ca..7755ba4 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -133,7 +133,7 @@ class JedcheckerRulesXMLManifest extends JEDcheckerRule } // load DTD-like data for this extension type - $json_filename = __DIR__ . '/xmlmanifest_' . $type . '.json'; + $json_filename = __DIR__ . '/xmlmanifest/dtd_' . $type . '.json'; if (!is_file($json_filename)) { $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_MANIFEST_TYPE_NOT_ACCEPTED', $type)); diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_component.json similarity index 100% rename from administrator/components/com_jedchecker/libraries/rules/xmlmanifest_component.json rename to administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_component.json diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_module.json similarity index 100% rename from administrator/components/com_jedchecker/libraries/rules/xmlmanifest_module.json rename to administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_module.json diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_package.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_package.json similarity index 100% rename from administrator/components/com_jedchecker/libraries/rules/xmlmanifest_package.json rename to administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_package.json diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_plugin.json similarity index 100% rename from administrator/components/com_jedchecker/libraries/rules/xmlmanifest_plugin.json rename to administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_plugin.json From f7353bf312d386a587982f5862b37e767b1d04ec Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:32:28 +0300 Subject: [PATCH 037/238] add support of any attribute (by using '*' as value) --- .../com_jedchecker/libraries/rules/xmlmanifest.php | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php index 7755ba4..5ca2c72 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -171,12 +171,17 @@ class JedcheckerRulesXMLManifest extends JEDcheckerRule { // Check attributes $DTDattributes = isset($this->DTDAttrRules[$name]) ? $this->DTDAttrRules[$name] : array(); - foreach ($node->attributes() as $attr) + + if (isset($DTDattributes[0]) && $DTDattributes[0] !== '*') { - $attr_name = (string)$attr->getName(); - if (!in_array($attr_name, $DTDattributes, true)) + foreach ($node->attributes() as $attr) { - $this->warnings[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_UNKNOWN_ATTRIBUTE', $name, $attr_name); + $attr_name = (string)$attr->getName(); + + if (!in_array($attr_name, $DTDattributes, true)) + { + $this->warnings[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_UNKNOWN_ATTRIBUTE', $name, $attr_name); + } } } From 79caa44fca1c2c0fc1576115ef7709ae46ef9d27 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:33:37 +0300 Subject: [PATCH 038/238] add support of any children (by using '*' as key) --- .../components/com_jedchecker/libraries/rules/xmlmanifest.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php index 5ca2c72..f52366a 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -193,7 +193,9 @@ class JedcheckerRulesXMLManifest extends JEDcheckerRule { $this->warnings[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILDREN', $name); } - } else { + } + elseif (!isset($this->DTDNodeRules[$name]['*'])) + { $DTDchildren = $this->DTDNodeRules[$name]; // 1) check required single elements From ab751af635b2a215504519f3919c090fbf01bb3a Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:37:02 +0300 Subject: [PATCH 039/238] remove error for missed license and updateservers tags (as they are processed by other rules) --- .../libraries/rules/xmlmanifest/dtd_component.json | 4 ++-- .../libraries/rules/xmlmanifest/dtd_module.json | 4 ++-- .../libraries/rules/xmlmanifest/dtd_package.json | 4 ++-- .../libraries/rules/xmlmanifest/dtd_plugin.json | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_component.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_component.json index 1802074..735d2a9 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_component.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_component.json @@ -10,7 +10,7 @@ "copyright": "=", "version": "!", "description": "=", - "license": "!", + "license": "?", "scriptfile": "?", "install": "?", "update": "?", @@ -19,7 +19,7 @@ "languages": "?", "media": "?", "administration": "?", - "updateservers": "!", + "updateservers": "?", "config": "?", "dlid": "?", "namespace": "?" diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_module.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_module.json index 87615ce..e4f8daa 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_module.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_module.json @@ -10,7 +10,7 @@ "copyright": "=", "version": "!", "description": "=", - "license": "!", + "license": "?", "scriptfile": "?", "install": "?", "update": "?", @@ -18,7 +18,7 @@ "files": "?", "languages": "?", "media": "?", - "updateservers": "!", + "updateservers": "?", "config": "?", "dlid": "?", "namespace": "?" diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_package.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_package.json index 393aaeb..b2b5074 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_package.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_package.json @@ -10,12 +10,12 @@ "copyright": "=", "version": "!", "description": "=", - "license": "!", + "license": "?", "scriptfile": "?", "update": "?", "files": "?", "languages": "?", - "updateservers": "!", + "updateservers": "?", "dlid": "?", "packager": "?", "packagerurl": "?", diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_plugin.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_plugin.json index 4eb09ef..e1ff6a8 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_plugin.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_plugin.json @@ -10,7 +10,7 @@ "copyright": "=", "version": "!", "description": "=", - "license": "!", + "license": "?", "scriptfile": "?", "install": "?", "update": "?", @@ -18,7 +18,7 @@ "files": "?", "languages": "?", "media": "?", - "updateservers": "!", + "updateservers": "?", "config": "?", "dlid": "?", "namespace": "?" From ffd09958305aa0481257aec5d0c4e29153b493fe Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:38:07 +0300 Subject: [PATCH 040/238] fix dtd for config section in modules and plugins --- .../rules/xmlmanifest/dtd_module.json | 39 +++++++++---------- .../rules/xmlmanifest/dtd_plugin.json | 39 +++++++++---------- 2 files changed, 36 insertions(+), 42 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_module.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_module.json index e4f8daa..1694b13 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_module.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_module.json @@ -60,7 +60,7 @@ "field": "+" }, "field": { - "option": "*" + "*": "*" } }, "attributes": { @@ -101,38 +101,35 @@ "path" ], "config": [ - "addfieldpath" + "addfieldpath", + "addfieldprefix", + "addformpath", + "addformprefix", + "addrulepath", + "addruleprefix" ], "fields": [ "addfieldpath", + "addfieldprefix", + "addformpath", + "addformprefix", + "addrulepath", + "addruleprefix", "name" ], "fieldset": [ "addfieldpath", + "addfieldprefix", + "addformpath", + "addformprefix", + "addrulepath", + "addruleprefix", "description", "label", "name" ], "field": [ - "addfieldpath", - "class", - "cols", - "default", - "description", - "filter", - "id", - "label", - "maxLength", - "name", - "required", - "rows", - "size", - "step", - "type", - "validate" - ], - "option": [ - "value" + "*" ] } } \ No newline at end of file diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_plugin.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_plugin.json index e1ff6a8..b459b2c 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_plugin.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_plugin.json @@ -60,7 +60,7 @@ "field": "+" }, "field": { - "option": "*" + "*": "*" } }, "attributes": { @@ -102,38 +102,35 @@ "path" ], "config": [ - "addfieldpath" + "addfieldpath", + "addfieldprefix", + "addformpath", + "addformprefix", + "addrulepath", + "addruleprefix" ], "fields": [ "addfieldpath", + "addfieldprefix", + "addformpath", + "addformprefix", + "addrulepath", + "addruleprefix", "name" ], "fieldset": [ "addfieldpath", + "addfieldprefix", + "addformpath", + "addformprefix", + "addrulepath", + "addruleprefix", "description", "label", "name" ], "field": [ - "addfieldpath", - "class", - "cols", - "default", - "description", - "filter", - "id", - "label", - "maxLength", - "name", - "required", - "rows", - "size", - "step", - "type", - "validate" - ], - "option": [ - "value" + "*" ] } } \ No newline at end of file From b74a082198495e6d3fbe10f1533f86480d62dd40 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:38:42 +0300 Subject: [PATCH 041/238] support both file and filename names for files children in package manifest --- .../libraries/rules/xmlmanifest/dtd_package.json | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_package.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_package.json index b2b5074..703fb88 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_package.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_package.json @@ -23,6 +23,7 @@ }, "files": { "file": "*", + "filename": "*", "folder": "*" }, "languages": { @@ -48,6 +49,12 @@ "id", "type" ], + "filename": [ + "client", + "group", + "id", + "type" + ], "languages": [ "folder" ], From a73780e5245ad5f0fd73a41bb8d9ec77b9eb4197 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 00:39:10 +0300 Subject: [PATCH 042/238] don't require menu and languages sections in components --- .../libraries/rules/xmlmanifest/dtd_component.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_component.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_component.json index 735d2a9..96f9d61 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_component.json +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_component.json @@ -25,10 +25,10 @@ "namespace": "?" }, "administration": { - "menu": "=", + "menu": "?", "submenu": "?", "files": "=", - "languages": "=", + "languages": "?", "media": "?" }, "files": { From db4d6ea7f2140f347aa6d6009725f724c75e9fd6 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:12:57 +0300 Subject: [PATCH 043/238] change title to plural --- .../com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index ab71533..16bdb1c 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -78,7 +78,7 @@ COM_JEDCHECKER_INFO_XML_UPDATE_SERVER_LINK="The Update Server link in this XML f COM_JEDCHECKER_DELETE_FAILED="Can't delete temporary folder" COM_JEDCHECKER_DELETE_SUCCESS="Temporary folder deleted!" COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" -COM_JEDCHECKER_MANIFEST="XML Manifest" +COM_JEDCHECKER_MANIFEST="XML Manifests" COM_JEDCHECKER_MANIFEST_DESC="Validation of extension's XML manifest file" COM_JEDCHECKER_MANIFEST_UNKNOWN_TYPE="Unknown extension type: %s" COM_JEDCHECKER_MANIFEST_TYPE_NOT_ACCEPTED="Extension type '%s' is not accepted by JED" @@ -87,4 +87,4 @@ COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILDREN="Node '%s' has unknown child element" COM_JEDCHECKER_MANIFEST_MISSED_REQUIRED="Node '%1$s' doesn't contain required '%2$s' element" COM_JEDCHECKER_MANIFEST_MULTIPLE_FOUND="Node '%1$s' contains multiple '%2$s' elements" COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILD="Node '%1$s' contains unknown '%2$s' element" -COM_JEDCHECKER_MANIFEST_MENU_UNUSED_ATTRIBUTE="Menu item attribute '%s' is not used with 'link' attribute" \ No newline at end of file +COM_JEDCHECKER_MANIFEST_MENU_UNUSED_ATTRIBUTE="Menu item attribute '%s' is not used with 'link' attribute" From 9855b35debcafbc32ee2c769d2a3da131423147e Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 02:27:08 +0300 Subject: [PATCH 044/238] use angle brackets for nodes names --- .../language/en-GB/en-GB.com_jedchecker.ini | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index 16bdb1c..e5922f0 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -82,9 +82,9 @@ COM_JEDCHECKER_MANIFEST="XML Manifests" COM_JEDCHECKER_MANIFEST_DESC="Validation of extension's XML manifest file" COM_JEDCHECKER_MANIFEST_UNKNOWN_TYPE="Unknown extension type: %s" COM_JEDCHECKER_MANIFEST_TYPE_NOT_ACCEPTED="Extension type '%s' is not accepted by JED" -COM_JEDCHECKER_MANIFEST_UNKNOWN_ATTRIBUTE="Node '%1$s' has unknown attribute '%2$s'" -COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILDREN="Node '%s' has unknown child element" -COM_JEDCHECKER_MANIFEST_MISSED_REQUIRED="Node '%1$s' doesn't contain required '%2$s' element" -COM_JEDCHECKER_MANIFEST_MULTIPLE_FOUND="Node '%1$s' contains multiple '%2$s' elements" -COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILD="Node '%1$s' contains unknown '%2$s' element" +COM_JEDCHECKER_MANIFEST_UNKNOWN_ATTRIBUTE="Node <%1$s> has unknown attribute '%2$s'" +COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILDREN="Node <%s> has unknown child element" +COM_JEDCHECKER_MANIFEST_MISSED_REQUIRED="Node <%1$s> doesn't contain required <%2$s> element" +COM_JEDCHECKER_MANIFEST_MULTIPLE_FOUND="Node <%1$s> contains multiple <%2$s> elements" +COM_JEDCHECKER_MANIFEST_UNKNOWN_CHILD="Node <%1$s> contains unknown <%2$s> element" COM_JEDCHECKER_MANIFEST_MENU_UNUSED_ATTRIBUTE="Menu item attribute '%s' is not used with 'link' attribute" From 825208b28c93e4d312d066c7c0343e393de424c7 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 02:27:49 +0300 Subject: [PATCH 045/238] add DTD json for language packages --- .../rules/xmlmanifest/dtd_language.json | 60 +++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_language.json diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_language.json b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_language.json new file mode 100644 index 0000000..e6002de --- /dev/null +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest/dtd_language.json @@ -0,0 +1,60 @@ +{ + "nodes": { + "extension": { + "name": "!", + "tag": "!", + "creationDate": "=", + "author": "=", + "authorEmail": "=", + "authorUrl": "=", + "copyright": "=", + "version": "!", + "description": "=", + "license": "?", + "files": "!", + "media": "?", + "fonts": "?", + "update": "?", + "updateservers": "?" + }, + "files": { + "filename": "*", + "folder": "*" + }, + "media": { + "filename": "*", + "folder": "*" + }, + "fonts": { + "filename": "*", + "folder": "*" + }, + "updateservers": { + "server": "*" + } + }, + "attributes": { + "extension": [ + "client", + "method", + "overwrite", + "type", + "version" + ], + "files": [ + "folder" + ], + "media": [ + "destination", + "folder" + ], + "fonts": [ + "folder" + ], + "server": [ + "name", + "priority", + "type" + ] + } +} \ No newline at end of file From d353c8b2f85ede8dd45fe7c6d179f1dc95630f9c Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:15:13 +0300 Subject: [PATCH 046/238] commenting the code --- .../components/com_jedchecker/libraries/rules/xmlmanifest.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php index f52366a..855228f 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -180,6 +180,7 @@ class JedcheckerRulesXMLManifest extends JEDcheckerRule if (!in_array($attr_name, $DTDattributes, true)) { + // The node has unknown attribute $this->warnings[] = JText::sprintf('COM_JEDCHECKER_MANIFEST_UNKNOWN_ATTRIBUTE', $name, $attr_name); } } @@ -276,6 +277,7 @@ class JedcheckerRulesXMLManifest extends JEDcheckerRule { if (isset($node['link'])) { + // The "link" attribute overrides any other link-related attributes (warn if they present) $skip_attrs = array('act', 'controller', 'layout', 'sub', 'task', 'view'); foreach ($node->attributes() as $attr) { From 4775ddd43b1037f0f0f3569b08e4790512c6ca86 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:17:00 +0300 Subject: [PATCH 047/238] correct authors list for new rule --- .../components/com_jedchecker/libraries/rules/xmlfiles.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php index ad15c4e..285ef2b 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php @@ -4,9 +4,7 @@ * * @copyright Copyright (C) 2017 - 2021 Open Source Matters, Inc. All rights reserved. * Copyright (C) 2008 - 2016 compojoom.com . All rights reserved. - * @author Daniel Dimitrov - * eaxs - * Denis Ryabov + * @author Denis Ryabov * * @license GNU General Public License version 2 or later; see LICENSE.txt */ From d583e82bd7f81b8b38dac6fa9ddff27b78a84285 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 23 Feb 2021 23:57:03 +0300 Subject: [PATCH 048/238] fix path for sql files --- .../com_jedchecker/libraries/rules/xmlfiles.php | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php index 285ef2b..b095317 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php @@ -129,13 +129,15 @@ class JedcheckerRulesXMLFiles extends JEDcheckerRule $this->checkFiles($node->language, $dir); } + $admindir = $basedir; + // check: administration files[folder] (filename|folder)* if (isset($xml->administration->files)) { $node = $xml->administration->files; - $dir = $basedir . (isset($node['folder']) ? $node['folder'] . '/' : ''); - $this->checkFiles($node->filename, $dir); - $this->checkFolders($node->folder, $dir); + $admindir = $basedir . (isset($node['folder']) ? $node['folder'] . '/' : ''); + $this->checkFiles($node->filename, $admindir); + $this->checkFolders($node->folder, $admindir); } // check: administration media[folder] (filename|folder)* @@ -164,19 +166,19 @@ class JedcheckerRulesXMLFiles extends JEDcheckerRule // check files: install sql file* if (isset($xml->install->sql->file)) { - $this->checkFiles($xml->install->sql->file, $basedir); + $this->checkFiles($xml->install->sql->file, $admindir); } // check files: uninstall sql file* if (isset($xml->uninstall->sql->file)) { - $this->checkFiles($xml->uninstall->sql->file, $basedir); + $this->checkFiles($xml->uninstall->sql->file, $admindir); } // check folders: update schemas schemapath* if (isset($xml->update->schemas->schemapath)) { - $this->checkFolders($xml->update->schemas->schemapath, $basedir); + $this->checkFolders($xml->update->schemas->schemapath, $admindir); } if (count($this->errors)) From 8c52d0c912ce5f9d934ca5f25d92c7c7164167df Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:18:39 +0300 Subject: [PATCH 049/238] change title --- .../com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index f23780e..14707c1 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -78,7 +78,7 @@ COM_JEDCHECKER_INFO_XML_UPDATE_SERVER_LINK="The Update Server link in this XML f COM_JEDCHECKER_DELETE_FAILED="Can't delete temporary folder" COM_JEDCHECKER_DELETE_SUCCESS="Temporary folder deleted!" COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" -COM_JEDCHECKER_XML_FILES="Check files/folders references" +COM_JEDCHECKER_XML_FILES="XML Files references" COM_JEDCHECKER_XML_FILES_DESC="Check for incorrect files and folders references in the XML manifest" COM_JEDCHECKER_XML_FILES_FILE_NOT_FOUND="File not found: %s" -COM_JEDCHECKER_XML_FILES_FOLDER_NOT_FOUND="Folder not found: %s" \ No newline at end of file +COM_JEDCHECKER_XML_FILES_FOLDER_NOT_FOUND="Folder not found: %s" From 75d8daa931d92bae556460110ba0acb7c5a204cc Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 23 Feb 2021 00:00:06 +0300 Subject: [PATCH 050/238] apply code style (spaces to tabs) --- .../libraries/rules/language.php | 238 +++++++++--------- 1 file changed, 119 insertions(+), 119 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/language.php b/administrator/components/com_jedchecker/libraries/rules/language.php index 1f7467d..c53ef29 100644 --- a/administrator/components/com_jedchecker/libraries/rules/language.php +++ b/administrator/components/com_jedchecker/libraries/rules/language.php @@ -27,132 +27,132 @@ require_once JPATH_COMPONENT_ADMINISTRATOR . '/models/rule.php'; */ class JedcheckerRulesLanguage extends JEDcheckerRule { - /** - * The formal ID of this rule. For example: SE1. - * - * @var string - */ - protected $id = 'LANG'; + /** + * The formal ID of this rule. For example: SE1. + * + * @var string + */ + protected $id = 'LANG'; - /** - * The title or caption of this rule. - * - * @var string - */ - protected $title = 'COM_JEDCHECKER_LANG'; + /** + * The title or caption of this rule. + * + * @var string + */ + protected $title = 'COM_JEDCHECKER_LANG'; - /** - * The description of this rule. - * - * @var string - */ - protected $description = 'COM_JEDCHECKER_LANG_DESC'; + /** + * The description of this rule. + * + * @var string + */ + protected $description = 'COM_JEDCHECKER_LANG_DESC'; - /** - * Initiates the search and check - * - * @return void - */ - public function check() - { - // Find all INI files of the extension (in the format tag.extension.ini or tag.extension.sys.ini) - $files = JFolder::files($this->basedir, '^[a-z]{2,3}-[A-Z]{2}\.\w+(?:\.sys)?\.ini$', true, true); + /** + * Initiates the search and check + * + * @return void + */ + public function check() + { + // Find all INI files of the extension (in the format tag.extension.ini or tag.extension.sys.ini) + $files = JFolder::files($this->basedir, '^[a-z]{2,3}-[A-Z]{2}\.\w+(?:\.sys)?\.ini$', true, true); - // Iterate through all the ini files - foreach ($files as $file) - { - // Try to validate the file - $this->find($file); - } - } + // Iterate through all the ini files + foreach ($files as $file) + { + // Try to validate the file + $this->find($file); + } + } - /** - * Reads and validates an ini file - * - * @param string $file - The path to the file - * - * @return bool True on success, otherwise False. - */ - protected function find($file) - { - $lines = file($file); - foreach ($lines as $lineno => $line) - { - $line = trim($line); - if ($line === '' || $line[0] === ';' || $line[0] === '[') - { - continue; - } - if ($line[0] === '#') - { - $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_INCORRECT_COMMENT') . - '
' . htmlspecialchars($line), $lineno); - continue; - } - if (strpos($line, '=') === false) - { - $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_WRONG_LINE') . - '
' . htmlspecialchars($line), $lineno); - continue; - } - list ($key, $value) = explode('=', $line, 2); + /** + * Reads and validates an ini file + * + * @param string $file - The path to the file + * + * @return bool True on success, otherwise False. + */ + protected function find($file) + { + $lines = file($file); + foreach ($lines as $lineno => $line) + { + $line = trim($line); + if ($line === '' || $line[0] === ';' || $line[0] === '[') + { + continue; + } + if ($line[0] === '#') + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_INCORRECT_COMMENT') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + if (strpos($line, '=') === false) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_WRONG_LINE') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + list ($key, $value) = explode('=', $line, 2); - $key = rtrim($key); - if ($key === '') - { - $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_EMPTY') . - '
' . htmlspecialchars($line), $lineno); - continue; - } - if (strpos($key, ' ') !== false) - { - $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_WHITESPACE') . - '
' . htmlspecialchars($line), $lineno); - continue; - } - if (strpbrk($key, '{}|&~![()^"') !== false) - { - $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_INVALID_CHARACTER') . - '
' . htmlspecialchars($line), $lineno); - continue; - } - if (in_array($key, array('null', 'yes', 'no', 'true', 'false', 'on', 'off', 'none'), true)) - { - $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_RESERVED') . - '
' . htmlspecialchars($line), $lineno); - continue; - } - $value = ltrim($value); - if (strlen($value) <2 || $value[0] !== '"' || substr($value, -1) !== '"') - { - $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_TRANSLATION_QUOTES') . - '
' . htmlspecialchars($line), $lineno); - continue; - } - if ($value === '""') - { - $this->report->addWarning($file, JText::_('COM_JEDCHECKER_LANG_TRANSLATION_EMPTY') . - '
' . htmlspecialchars($line), $lineno); - continue; - } + $key = rtrim($key); + if ($key === '') + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_EMPTY') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + if (strpos($key, ' ') !== false) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_WHITESPACE') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + if (strpbrk($key, '{}|&~![()^"') !== false) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_INVALID_CHARACTER') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + if (in_array($key, array('null', 'yes', 'no', 'true', 'false', 'on', 'off', 'none'), true)) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_RESERVED') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + $value = ltrim($value); + if (strlen($value) <2 || $value[0] !== '"' || substr($value, -1) !== '"') + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_TRANSLATION_QUOTES') . + '
' . htmlspecialchars($line), $lineno); + continue; + } + if ($value === '""') + { + $this->report->addWarning($file, JText::_('COM_JEDCHECKER_LANG_TRANSLATION_EMPTY') . + '
' . htmlspecialchars($line), $lineno); + continue; + } - $value = substr($value, 1, -1); - if (strpos($value, '"_QQ_"') !== false) - { - $this->report->addInfo($file, JText::_('COM_JEDCHECKER_LANG_QQ_DEPRECATED') . - '
' . htmlspecialchars($line), $lineno); - } + $value = substr($value, 1, -1); + if (strpos($value, '"_QQ_"') !== false) + { + $this->report->addInfo($file, JText::_('COM_JEDCHECKER_LANG_QQ_DEPRECATED') . + '
' . htmlspecialchars($line), $lineno); + } - $count1 = preg_match_all('/(?<=^|[^%])%(?=[-+0 ]?\w)/', $value); - $count2 = preg_match_all('/(?<=^|[^%])%\d+\$/', $value); - if ($count1 > 1 && $count2 < $count1) { - // @todo It's not mentioned in docs - $this->report->addInfo($file, JText::_('COM_JEDCHECKER_LANG_RECOMMEND_ARGNUM') . - '
' . htmlspecialchars($line), $lineno); - } - } + $count1 = preg_match_all('/(?<=^|[^%])%(?=[-+0 ]?\w)/', $value); + $count2 = preg_match_all('/(?<=^|[^%])%\d+\$/', $value); + if ($count1 > 1 && $count2 < $count1) { + // @todo It's not mentioned in docs + $this->report->addInfo($file, JText::_('COM_JEDCHECKER_LANG_RECOMMEND_ARGNUM') . + '
' . htmlspecialchars($line), $lineno); + } + } - // All checks passed. Return true - return true; - } + // All checks passed. Return true + return true; + } } From 08864234a97b799076cb0a168fe57fa170df9161 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:20:37 +0300 Subject: [PATCH 051/238] correct authors list for new rule --- .../components/com_jedchecker/libraries/rules/language.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/language.php b/administrator/components/com_jedchecker/libraries/rules/language.php index c53ef29..721fa3d 100644 --- a/administrator/components/com_jedchecker/libraries/rules/language.php +++ b/administrator/components/com_jedchecker/libraries/rules/language.php @@ -4,9 +4,7 @@ * * @copyright Copyright (C) 2017 - 2021 Open Source Matters, Inc. All rights reserved. * Copyright (C) 2008 - 2016 compojoom.com . All rights reserved. - * @author Daniel Dimitrov - * eaxs - * Denis Ryabov + * @author Denis Ryabov * * @license GNU General Public License version 2 or later; see LICENSE.txt */ From b5fe0e91b483de2acc5b2908193430e377bf4140 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 23 Feb 2021 22:26:09 +0300 Subject: [PATCH 052/238] check for BOM in language files --- .../com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini | 1 + .../components/com_jedchecker/libraries/rules/language.php | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index 1482f63..d78bad1 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -80,6 +80,7 @@ COM_JEDCHECKER_DELETE_SUCCESS="Temporary folder deleted!" COM_JEDCHECKER_EMPTY_UPLOAD_FIELD="Please, select a zipped file to be uploaded" COM_JEDCHECKER_LANG="Language files" COM_JEDCHECKER_LANG_DESC="Validates language files" +COM_JEDCHECKER_LANG_BOM_FOUND="The byte order mark (BOM) is detected" COM_JEDCHECKER_LANG_INCORRECT_COMMENT="Incorrect comment character, use ';' instead" COM_JEDCHECKER_LANG_WRONG_LINE="Incorrect line without '=' character" COM_JEDCHECKER_LANG_KEY_EMPTY="Empty key name" diff --git a/administrator/components/com_jedchecker/libraries/rules/language.php b/administrator/components/com_jedchecker/libraries/rules/language.php index 721fa3d..3216b27 100644 --- a/administrator/components/com_jedchecker/libraries/rules/language.php +++ b/administrator/components/com_jedchecker/libraries/rules/language.php @@ -77,6 +77,11 @@ class JedcheckerRulesLanguage extends JEDcheckerRule foreach ($lines as $lineno => $line) { $line = trim($line); + if ($lineno === 0 && strncmp($line, "\xEF\xBB\xBF", 3) === 0) + { + $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_BOM_FOUND'), 1); + $line = substr($line, 3); + } if ($line === '' || $line[0] === ';' || $line[0] === '[') { continue; From 14325955817ad74517ab497acfcfe3c6d8bac194 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:34:51 +0300 Subject: [PATCH 053/238] temporaty remove argnum check --- .../language/en-GB/en-GB.com_jedchecker.ini | 1 - .../com_jedchecker/libraries/rules/language.php | 8 -------- 2 files changed, 9 deletions(-) diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index d78bad1..5780104 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -90,4 +90,3 @@ COM_JEDCHECKER_LANG_KEY_RESERVED="Reserved keyword in the key name" COM_JEDCHECKER_LANG_TRANSLATION_QUOTES="All translation strings should be in double quotation marks" COM_JEDCHECKER_LANG_TRANSLATION_EMPTY="Empty translation string" COM_JEDCHECKER_LANG_QQ_DEPRECATED="Usage of \"_QQ_\" is deprecated since Joomla! 3.9. Use escaped double quotes (\\\") instead" -COM_JEDCHECKER_LANG_RECOMMEND_ARGNUM="Substituted values may have another order in other languages. To simplify work of translators, it's recommended to use Argnum specification, see https://www.php.net/manual/en/function.sprintf.php for details" \ No newline at end of file diff --git a/administrator/components/com_jedchecker/libraries/rules/language.php b/administrator/components/com_jedchecker/libraries/rules/language.php index 3216b27..3c515ca 100644 --- a/administrator/components/com_jedchecker/libraries/rules/language.php +++ b/administrator/components/com_jedchecker/libraries/rules/language.php @@ -145,14 +145,6 @@ class JedcheckerRulesLanguage extends JEDcheckerRule $this->report->addInfo($file, JText::_('COM_JEDCHECKER_LANG_QQ_DEPRECATED') . '
' . htmlspecialchars($line), $lineno); } - - $count1 = preg_match_all('/(?<=^|[^%])%(?=[-+0 ]?\w)/', $value); - $count2 = preg_match_all('/(?<=^|[^%])%\d+\$/', $value); - if ($count1 > 1 && $count2 < $count1) { - // @todo It's not mentioned in docs - $this->report->addInfo($file, JText::_('COM_JEDCHECKER_LANG_RECOMMEND_ARGNUM') . - '
' . htmlspecialchars($line), $lineno); - } } // All checks passed. Return true From c81699b61cce2889b56c136a7abb0a08a4ecfc97 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:35:15 +0300 Subject: [PATCH 054/238] Add a description for each check in the code --- .../libraries/rules/language.php | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/administrator/components/com_jedchecker/libraries/rules/language.php b/administrator/components/com_jedchecker/libraries/rules/language.php index 3c515ca..52e43fc 100644 --- a/administrator/components/com_jedchecker/libraries/rules/language.php +++ b/administrator/components/com_jedchecker/libraries/rules/language.php @@ -77,61 +77,84 @@ class JedcheckerRulesLanguage extends JEDcheckerRule foreach ($lines as $lineno => $line) { $line = trim($line); + + // Check for BOM sequence if ($lineno === 0 && strncmp($line, "\xEF\xBB\xBF", 3) === 0) { $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_BOM_FOUND'), 1); + // Romeve BOM for further checks $line = substr($line, 3); } + + // Skip empty lines, comments, and section names if ($line === '' || $line[0] === ';' || $line[0] === '[') { continue; } + + // Report incorrect comment character if ($line[0] === '#') { $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_INCORRECT_COMMENT') . '
' . htmlspecialchars($line), $lineno); continue; } + + // Check for "=" character in the line if (strpos($line, '=') === false) { $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_WRONG_LINE') . '
' . htmlspecialchars($line), $lineno); continue; } + + // Extract key and value list ($key, $value) = explode('=', $line, 2); $key = rtrim($key); + + // Check for empty key if ($key === '') { $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_EMPTY') . '
' . htmlspecialchars($line), $lineno); continue; } + + // Check for spaces in the key name if (strpos($key, ' ') !== false) { $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_WHITESPACE') . '
' . htmlspecialchars($line), $lineno); continue; } + + // Check for invalid characters (see https://www.php.net/manual/en/function.parse-ini-file.php) if (strpbrk($key, '{}|&~![()^"') !== false) { $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_INVALID_CHARACTER') . '
' . htmlspecialchars($line), $lineno); continue; } + + // Check for invalid key names (see https://www.php.net/manual/en/function.parse-ini-file.php) if (in_array($key, array('null', 'yes', 'no', 'true', 'false', 'on', 'off', 'none'), true)) { $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_KEY_RESERVED') . '
' . htmlspecialchars($line), $lineno); continue; } + $value = ltrim($value); + if (strlen($value) <2 || $value[0] !== '"' || substr($value, -1) !== '"') { $this->report->addError($file, JText::_('COM_JEDCHECKER_LANG_TRANSLATION_QUOTES') . '
' . htmlspecialchars($line), $lineno); continue; } + + // Check for empty value if ($value === '""') { $this->report->addWarning($file, JText::_('COM_JEDCHECKER_LANG_TRANSLATION_EMPTY') . @@ -139,7 +162,10 @@ class JedcheckerRulesLanguage extends JEDcheckerRule continue; } + // Remove quotes around $value = substr($value, 1, -1); + + // Check for legacy "_QQ_" code (deprecated since Joomla! 3.9 if favor of escaped double quote \"; removed in Joomla! 4) if (strpos($value, '"_QQ_"') !== false) { $this->report->addInfo($file, JText::_('COM_JEDCHECKER_LANG_QQ_DEPRECATED') . From 0ac7ee0f6b1216bffd42113a0f4fc66e09534033 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 23 Feb 2021 21:05:14 +0300 Subject: [PATCH 055/238] fixed: JFile::read is not supported by Joomla! 4 --- .../components/com_jedchecker/controllers/police.raw.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/controllers/police.raw.php b/administrator/components/com_jedchecker/controllers/police.raw.php index d162003..d2eb6b6 100644 --- a/administrator/components/com_jedchecker/controllers/police.raw.php +++ b/administrator/components/com_jedchecker/controllers/police.raw.php @@ -112,7 +112,7 @@ class JedcheckerControllerPolice extends JControllerLegacy if (JFile::exists($local)) { - $content = JFile::read($local); + $content = file_get_contents($local); if (!empty($content)) { From 1bcd291f8ce36dcc6e6767a9569d13009c346d18 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 2 Mar 2021 01:27:29 +0300 Subject: [PATCH 056/238] JError is not supported by Joomla! 4, return false is sufficient to abort installation --- administrator/components/com_jedchecker/script.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/script.php b/administrator/components/com_jedchecker/script.php index e54b2e7..443d3b6 100644 --- a/administrator/components/com_jedchecker/script.php +++ b/administrator/components/com_jedchecker/script.php @@ -34,7 +34,8 @@ class Com_JedcheckerInstallerScript { $this->loadLanguage(); - Jerror::raiseWarning(null, JText::sprintf('COM_JEDCHECKER_PHP_VERSION_INCOMPATIBLE', PHP_VERSION, '5.3.10')); + $msg = JText::sprintf('COM_JEDCHECKER_PHP_VERSION_INCOMPATIBLE', PHP_VERSION, '5.3.10'); + echo "

$msg

"; return false; } From d102979258b7f067a7cc7a9ff1ae01cbfaf7139f Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 01:56:04 +0300 Subject: [PATCH 057/238] add some comments --- .../libraries/rules/xmlinfo.php | 21 ++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index 3e6e65d..c2808d4 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -112,15 +112,19 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule return false; } - // Get extension name (element) - + // Get extension type $type = (string) $xml['type']; + + // Get extension's element name (simulates work of Joomla's installer) + + // Firstly, check for node if (isset($xml->element)) { $extension = (string) $xml->element; } else { + // Otherwise, use node or plugin/module attribute in the section $extension = (string) $xml->name; if (isset($xml->files)) { @@ -133,13 +137,18 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule } } } + + // Filter extension's element name $extension = strtolower(JFilterInput::getInstance()->clean($extension, 'cmd')); + + // Component's element name starts with com_ if ($type === 'component' && strpos($extension, 'com_') !== 0) { $extension = 'com_' . $extension; } - if ($type === 'plugin' && isset($xml['group'])) + // Plugin's element name starts with com_ + if ($type === 'plugin' && isset($xml['group']) && strpos($extension, 'plg_') !== 0) { $extension = 'plg_' . $xml['group'] . '_' . $extension; } @@ -151,6 +160,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule $lang_dir = dirname($file); $lang_tag = 'en-GB'; // $lang->getDefault(); + // Populate list of directories to look for $lookup_lang_dirs = array(); if (isset($xml->administration->files['folder'])) @@ -240,10 +250,12 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule if (stripos($extension_name, 'joomla') === 0) { + // An extension name can't start with the word "Joomla" $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_JOOMLA', $extension_name)); } elseif (stripos($extension_name, 'joom') !== false) { + // Extensions that use "Joomla" or a derivative of Joomla in the extension name need to be licensed by OSM $this->report->addWarning($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE', $extension_name)); } @@ -262,6 +274,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule if (!in_array($domain, $approvedDomains, true)) { + // Extensions that use "Joomla" or a derivative of Joomla in the domain name need to be licensed by OSM $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE', $url)); } } @@ -270,6 +283,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule if ($type === 'component' && isset($xml->administration->menu)) { $menu_name = $lang->_((string) $xml->administration->menu); + // Do name the Component's admin menu the same as the extension name if ($extension_name !== $menu_name) { $this->report->addWarning($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_ADMIN_MENU', $menu_name, $extension_name)); @@ -278,6 +292,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule if ($type === 'plugin') { + // The name of your plugin must comply with the JED naming conventions - plugins in the form “{Type} - {Extension Name}”. $parts = explode(' - ', $extension_name, 2); $extension_name_group = isset($parts[1]) ? strtolower(preg_replace('/\s/', '', $parts[0])) : false; $group = (string) $xml['group']; From 65fe32b164e56cfa4013832dbdbd1295bdd65294 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 10:40:52 +0300 Subject: [PATCH 058/238] replace check against a preinstalled domains list by the link to the Joomla! Trademark Approval Registry page --- .../language/en-GB/en-GB.com_jedchecker.ini | 2 +- .../libraries/rules/xmlinfo.php | 13 +----- .../rules/xmlinfo/approved-domains.txt | 46 ------------------- 3 files changed, 3 insertions(+), 58 deletions(-) delete mode 100644 administrator/components/com_jedchecker/libraries/rules/xmlinfo/approved-domains.txt diff --git a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini index b9f93d9..6742542 100644 --- a/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini +++ b/administrator/components/com_jedchecker/language/en-GB/en-GB.com_jedchecker.ini @@ -49,7 +49,7 @@ COM_JEDCHECKER_INFO_XML_NAME_RESERVED_KEYWORDS="Keywords such as module, plugin COM_JEDCHECKER_INFO_XML_NAME_VERSION="Version in name/title ('%s')" COM_JEDCHECKER_INFO_XML_NAME_JOOMLA="An extension name ('%s') can't start with the word 'Joomla'" COM_JEDCHECKER_INFO_XML_NAME_JOOMLA_DERIVATIVE="Extensions that use 'Joomla' or a derivative of Joomla in the extension name ('%s') need to be licensed by OSM" -COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE="Domain names that use 'Joomla' or a derivative of Joomla ('%s') need to be licensed by OSM" +COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE="Domain names that use 'Joomla' or a derivative of Joomla ('%1$s') need to be licensed by OSM. Please, check your domain name is listed on the Joomla! Trademark Approval Registry page." COM_JEDCHECKER_INFO_XML_NAME_ADMIN_MENU="The admin menu name '%1$s' isn't the same as the extension name '%2$s'" COM_JEDCHECKER_INFO_XML_NAME_PLUGIN_FORMAT="The name of the plugin ('%s') must comply with the JED naming conventions in the form '{Type} - {Extension Name}'" COM_JEDCHECKER_RULE_PH1="PHP Headers missing GPL License Notice" diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index c2808d4..a03e65d 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -266,17 +266,8 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule if (stripos($domain, 'joom') !== false) { - // Remove "www." subdomain prefix - $domain = preg_replace('/^www\./', '', $domain); - - // Approved domains from https://tm.joomla.org/approved-domains.html - $approvedDomains = file(__DIR__ . '/xmlinfo/approved-domains.txt', FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES); - - if (!in_array($domain, $approvedDomains, true)) - { - // Extensions that use "Joomla" or a derivative of Joomla in the domain name need to be licensed by OSM - $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE', $url)); - } + // Extensions that use "Joomla" or a derivative of Joomla in the domain name need to be licensed by OSM + $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_URL_JOOMLA_DERIVATIVE', $url, 'https://tm.joomla.org/approved-domains.html')); } } diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo/approved-domains.txt b/administrator/components/com_jedchecker/libraries/rules/xmlinfo/approved-domains.txt deleted file mode 100644 index 6e8c234..0000000 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo/approved-domains.txt +++ /dev/null @@ -1,46 +0,0 @@ -joomla.org - -hotjoomlatemplates.com -joomlanl.nl -joomla-templates.com -joomla-update.org -joomlaportal.ru -joomlavia.com -joomlatranslate.com -joomlamarketplace.online -hotjoomlatemplates.com -joomlatema.net -joomla.it -joomlaalger.org -joomla.cafe -joomlatwincities.org -joomlausersnj.com -joomlausersnyc.org -joomlact.org -joomlachicagonorth.com -joomlanh.org -joomlanh.org -joomlacarioca.com.br -novajoomla.com -joomlazur.com -joomladallas.org -joomlariodejaneiro.com.br -joomlatenerife.org -joomlage.com -joomlamadrid.org -joomschool.com -usingjoomla.com -joomla.cymru -joomlavigo.es -jug-warszawa.joomla.pl -joomlavalencia.net -jug-silesia.joomla.pl -jug-poznan.joomla.pl -joomla-canberra.org.au -joomlapay.com -joomlalondon.co.uk -mobilejoomla.com/ -myjoomla.com -joomlacontenteditor.net -joomlalabs.com -modernjoomla.com From 321221a49524b36149aa424e586574ab38e437fe Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 13:39:11 +0300 Subject: [PATCH 059/238] remove `@author` tag --- .../components/com_jedchecker/libraries/rules/xmlmanifest.php | 1 - 1 file changed, 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php index 855228f..be3a420 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -4,7 +4,6 @@ * * @copyright Copyright (C) 2017 - 2021 Open Source Matters, Inc. All rights reserved. * Copyright (C) 2008 - 2016 compojoom.com . All rights reserved. - * @author Denis Ryabov * * @license GNU General Public License version 2 or later; see LICENSE.txt */ From 8d7531a04784852a2605d80779063d28dcaa65bb Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 13:40:09 +0300 Subject: [PATCH 060/238] remove `@author` tag --- .../components/com_jedchecker/libraries/rules/xmlfiles.php | 1 - 1 file changed, 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php index b095317..af55d7d 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php @@ -4,7 +4,6 @@ * * @copyright Copyright (C) 2017 - 2021 Open Source Matters, Inc. All rights reserved. * Copyright (C) 2008 - 2016 compojoom.com . All rights reserved. - * @author Denis Ryabov * * @license GNU General Public License version 2 or later; see LICENSE.txt */ From ba75eb5967fbcb4f23a8a96f82addbbceadcabb1 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 13:41:07 +0300 Subject: [PATCH 061/238] remove `@author` tag --- .../components/com_jedchecker/libraries/rules/language.php | 1 - 1 file changed, 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/language.php b/administrator/components/com_jedchecker/libraries/rules/language.php index 52e43fc..b5e6c91 100644 --- a/administrator/components/com_jedchecker/libraries/rules/language.php +++ b/administrator/components/com_jedchecker/libraries/rules/language.php @@ -4,7 +4,6 @@ * * @copyright Copyright (C) 2017 - 2021 Open Source Matters, Inc. All rights reserved. * Copyright (C) 2008 - 2016 compojoom.com . All rights reserved. - * @author Denis Ryabov * * @license GNU General Public License version 2 or later; see LICENSE.txt */ From 01c5c5e550374cca714a04eb5b1b6fae7a5e5f80 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 15:56:27 +0300 Subject: [PATCH 062/238] fix copyright --- .../components/com_jedchecker/libraries/rules/xmlmanifest.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php index be3a420..682a3af 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlmanifest.php @@ -2,8 +2,7 @@ /** * @package Joomla.JEDChecker * - * @copyright Copyright (C) 2017 - 2021 Open Source Matters, Inc. All rights reserved. - * Copyright (C) 2008 - 2016 compojoom.com . All rights reserved. + * @copyright Copyright (C) 2021 Open Source Matters, Inc. All rights reserved. * * @license GNU General Public License version 2 or later; see LICENSE.txt */ From 0545fddb87a94e2a8de4173c133b79d80731417d Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 15:59:54 +0300 Subject: [PATCH 063/238] fix copyright --- .../components/com_jedchecker/libraries/rules/xmlfiles.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php index af55d7d..c836ff4 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlfiles.php @@ -2,8 +2,7 @@ /** * @package Joomla.JEDChecker * - * @copyright Copyright (C) 2017 - 2021 Open Source Matters, Inc. All rights reserved. - * Copyright (C) 2008 - 2016 compojoom.com . All rights reserved. + * @copyright Copyright (C) 2021 Open Source Matters, Inc. All rights reserved. * * @license GNU General Public License version 2 or later; see LICENSE.txt */ From 118846b53bae7cc692b93c472dfe443e5b864d8a Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 11 Mar 2021 16:00:58 +0300 Subject: [PATCH 064/238] fix copyright --- .../components/com_jedchecker/libraries/rules/language.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/language.php b/administrator/components/com_jedchecker/libraries/rules/language.php index b5e6c91..5c34171 100644 --- a/administrator/components/com_jedchecker/libraries/rules/language.php +++ b/administrator/components/com_jedchecker/libraries/rules/language.php @@ -2,8 +2,7 @@ /** * @package Joomla.JEDChecker * - * @copyright Copyright (C) 2017 - 2021 Open Source Matters, Inc. All rights reserved. - * Copyright (C) 2008 - 2016 compojoom.com . All rights reserved. + * @copyright Copyright (C) 2021 Open Source Matters, Inc. All rights reserved. * * @license GNU General Public License version 2 or later; see LICENSE.txt */ From 17e6f3b3a4e56aedeadcb2912dac7dac67a3dcb9 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 17 Mar 2021 18:44:19 +0300 Subject: [PATCH 065/238] Load jQuery explicitly --- .../components/com_jedchecker/views/uploads/tmpl/default.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php index 7d48961..d0ff58c 100644 --- a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php +++ b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php @@ -20,6 +20,9 @@ else JHtml::_('behavior.framework', true); } +// Load jQuery +JHtml::_('jquery.framework'); + JHtml::stylesheet('media/com_jedchecker/css/style.min.css'); $document = JFactory::getDocument(); From 0869a0cecb44ede9ffd2907d8f284a8a3d5d216c Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Mar 2021 15:11:59 +0300 Subject: [PATCH 066/238] fix comment text --- .../components/com_jedchecker/libraries/rules/xmlinfo.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index a03e65d..c60abcc 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -147,7 +147,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule $extension = 'com_' . $extension; } - // Plugin's element name starts with com_ + // Plugin's element name starts with plg_ if ($type === 'plugin' && isset($xml['group']) && strpos($extension, 'plg_') !== 0) { $extension = 'plg_' . $xml['group'] . '_' . $extension; From ab96c035ad9f984b5fc28db423ee5de8ce66195b Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Mar 2021 15:13:28 +0300 Subject: [PATCH 067/238] a "greedy" match (by @Llewellynvdm) --- .../components/com_jedchecker/libraries/rules/xmlinfo.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index c60abcc..5adff47 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -231,7 +231,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule $this->report->addInfo($file, implode('
', $info)); // NM3 - Listing name contains “module” or “plugin” - if (preg_match('/\b(?:module|plugin)\b/i', $extension_name)) + if (preg_match('/(?:module|plugin)/i', $extension_name)) { $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_MODULE_PLUGIN', $extension_name)); } From 0d2310f75d2de0a3f2a390c138a6543fdb559cc8 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Mar 2021 15:22:09 +0300 Subject: [PATCH 068/238] simplify regex --- .../components/com_jedchecker/libraries/rules/xmlinfo.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php index 5adff47..fc2119b 100644 --- a/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php +++ b/administrator/components/com_jedchecker/libraries/rules/xmlinfo.php @@ -231,7 +231,7 @@ class JedcheckerRulesXMLinfo extends JEDcheckerRule $this->report->addInfo($file, implode('
', $info)); // NM3 - Listing name contains “module” or “plugin” - if (preg_match('/(?:module|plugin)/i', $extension_name)) + if (preg_match('/module|plugin/i', $extension_name)) { $this->report->addError($file, JText::sprintf('COM_JEDCHECKER_INFO_XML_NAME_MODULE_PLUGIN', $extension_name)); } From b585389ddbb3def34f675ec16bbf57eb86441031 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 23 Feb 2021 23:03:19 +0300 Subject: [PATCH 069/238] new j4-style layout --- .../com_jedchecker/controllers/police.raw.php | 6 +- .../com_jedchecker/models/report.php | 74 +- .../views/uploads/tmpl/default.php | 292 ++++--- .../views/uploads/view.html.php | 31 +- media/com_jedchecker/css/j3-style.css | 285 ------- media/com_jedchecker/css/j3-style.min.css | 1 - media/com_jedchecker/css/j4-style.css | 792 ++++++++++++++++++ media/com_jedchecker/css/j4-style.min.css | 1 + media/com_jedchecker/css/style.css | 108 +-- media/com_jedchecker/css/style.min.css | 2 +- 10 files changed, 1043 insertions(+), 549 deletions(-) delete mode 100644 media/com_jedchecker/css/j3-style.css delete mode 100644 media/com_jedchecker/css/j3-style.min.css create mode 100644 media/com_jedchecker/css/j4-style.css create mode 100644 media/com_jedchecker/css/j4-style.min.css diff --git a/administrator/components/com_jedchecker/controllers/police.raw.php b/administrator/components/com_jedchecker/controllers/police.raw.php index 1a6eb1a..1fde949 100644 --- a/administrator/components/com_jedchecker/controllers/police.raw.php +++ b/administrator/components/com_jedchecker/controllers/police.raw.php @@ -76,11 +76,7 @@ class JedcheckerControllerPolice extends JControllerLegacy // Get the report and then print it $report = $police->get('report'); - echo '' - . JText::_('COM_JEDCHECKER_RULE') . ' ' . JText::_($police->get('id')) - . ' - ' . JText::_($police->get('title')) - . '
' - . $report->getHTML(); + echo $report->getHTML(); flush(); ob_flush(); diff --git a/administrator/components/com_jedchecker/models/report.php b/administrator/components/com_jedchecker/models/report.php index 8f0e761..f5c61df 100644 --- a/administrator/components/com_jedchecker/models/report.php +++ b/administrator/components/com_jedchecker/models/report.php @@ -174,7 +174,7 @@ class JEDcheckerReport extends JObject { $html = array(); - if ($this->data['count']->total == 0) + if ($this->data['count']->total === 0) { // No errors or compatibility issues found $html[] = '
'; @@ -183,63 +183,26 @@ class JEDcheckerReport extends JObject } else { - $error_count = $this->data['count']->errors; - $compat_count = $this->data['count']->compat; - $info_count = $this->data['count']->info; - $warning_count = $this->data['count']->warning; - // Go through the error list - if ($error_count > 0) + if ($this->data['count']->errors > 0) { - $collapseID = uniqid('error_'); - - $html[] = '
' . $error_count . ' ' . JText::_('COM_JEDCHECKER_ERRORS') . ' - ' . JText::_('COM_JEDCHECKER_CLICK_TO_VIEW_DETAILS') . '
'; - $html[] = '
    '; - - $html[] = $this->formatItems($this->data['errors']); - - $html[] = '
'; + $html[] = $this->formatItems($this->data['errors'], 'danger'); } - - // Go through the compat list - if ($compat_count > 0) - { - - $collapseID = uniqid('compat_'); - - $html[] = '
' . $compat_count . ' ' . JText::_('COM_JEDCHECKER_COMPAT_ISSUES') . ' - ' . JText::_('COM_JEDCHECKER_CLICK_TO_VIEW_DETAILS') . '
'; - $html[] = '
    '; - - $html[] = $this->formatItems($this->data['compat']); - - $html[] = '
'; - } - - // Go through the compat list - if ($info_count > 0) - { - - $collapseID = uniqid('info_'); - - $html[] = '
' . $info_count . ' ' . JText::_('COM_JEDCHECKER_INFO') . ' - ' . JText::_('COM_JEDCHECKER_CLICK_TO_VIEW_DETAILS') . '
'; - $html[] = '
    '; - - $html[] = $this->formatItems($this->data['info']); - - $html[] = '
'; - } - // Go through the warning list - if ($warning_count > 0) + if ($this->data['count']->warning > 0) { - $collapseID = uniqid('warning_'); + $html[] = $this->formatItems($this->data['warning'], 'warning'); - $html[] = '
' . $warning_count . ' ' . JText::_('COM_JEDCHECKER_WARNING') . ' - ' . JText::_('COM_JEDCHECKER_CLICK_TO_VIEW_DETAILS') . '
'; - $html[] = '
    '; + // Go through the compat list + if ($this->data['count']->compat > 0) + { + $html[] = $this->formatItems($this->data['compat'], 'secondary'); + } - $html[] = $this->formatItems($this->data['warning']); - - $html[] = '
'; + // Go through the info list + if ($this->data['count']->info > 0) + { + $html[] = $this->formatItems($this->data['info'], 'info'); } } @@ -279,10 +242,11 @@ class JEDcheckerReport extends JObject * Converts an item to the string representation * * @param array $items List or reports + * @param string $alertStyle Type of alert blocks * * @return string */ - protected function formatItems($items) + protected function formatItems($items, $alertStyle) { $html = array(); @@ -290,8 +254,10 @@ class JEDcheckerReport extends JObject { $num = $i + 1; + $html[] = '
'; + // Add count number - $html[] = '
  • #' . str_pad($num, 3, '0', STR_PAD_LEFT) . ' '; + $html[] = '#' . str_pad($num, 3, '0', STR_PAD_LEFT) . ' '; $html[] = $item->location; // Add line information if given @@ -316,7 +282,7 @@ class JEDcheckerReport extends JObject $html[] = ''; } - $html[] = '
  • '; + $html[] = '
    '; } return implode('', $html); diff --git a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php index 5fe2773..14cc5fe 100644 --- a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php +++ b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php @@ -11,177 +11,169 @@ defined('_JEXEC') or die('Restricted access'); -JHtml::_('behavior.framework', true); -JHtml::stylesheet('media/com_jedchecker/css/style.min.css'); -?> - - - - - - - - -
    -
    -
    - -
    -
    -

    -

    -

    -

    -

      -
    1. -
    2. -
    -

    -
    -
    -
    - - -
    -
    -
    -
    - -
    -
    -
    +?> +
    +
    +
    +
    +
    +
    - - - - - +
    +

    + +

    +

    + +

    +

    + +

    +
      +
    1. +
    2. +
    +
    +
    + .zip (both Chromium and Firefox) + application/x-gzip => .gz (both Chromium and Firefox), + .tgz (Chromium only) + application/x-compressed => .tgz (Firefox only) + application/x-tar => .tar (both Chromium and Firefox) +Note: iOS Safari doesn't support file extensions in the accept attribute, so MIME types is the only working solution +*/ ?> + + +
    +
    + + +
    +
    +
    -
    - -
    -
    -
    +
    +
    +
    + +
    +
    -
    - diff --git a/administrator/components/com_jedchecker/views/uploads/view.html.php b/administrator/components/com_jedchecker/views/uploads/view.html.php index 2997b26..afb2d7a 100644 --- a/administrator/components/com_jedchecker/views/uploads/view.html.php +++ b/administrator/components/com_jedchecker/views/uploads/view.html.php @@ -20,6 +20,9 @@ jimport('joomla.application.component.viewlegacy'); */ class JedcheckerViewUploads extends JViewLegacy { + /** @var array */ + protected $jsOptions; + /** * Display method * @@ -44,13 +47,33 @@ class JedcheckerViewUploads extends JViewLegacy */ public function getRules() { - $rules = array(); - $files = JFolder::files(JPATH_COMPONENT_ADMINISTRATOR . '/libraries/rules', '\.php$', false, false); + $existingRules = array( + 'xmlinfo', + 'xmllicense', + 'xmlmanifest', + 'xmlfiles', + 'xmlupdateserver', + 'gpl', + 'jexec', + 'errorreporting', + 'framework', + 'encoding', + 'jamss', + 'language' + ); + JLoader::discover('jedcheckerRules', JPATH_COMPONENT_ADMINISTRATOR . '/libraries/rules/'); - foreach ($files as $file) + $rules = array(); + + foreach ($existingRules as $rule) { - $rules[] = substr($file, 0, -4); + $class = 'jedcheckerRules' . ucfirst($rule); + + if (class_exists($class)) + { + $rules[] = $rule; + } } return $rules; diff --git a/media/com_jedchecker/css/j3-style.css b/media/com_jedchecker/css/j3-style.css deleted file mode 100644 index 7ca9cf5..0000000 --- a/media/com_jedchecker/css/j3-style.css +++ /dev/null @@ -1,285 +0,0 @@ -.col-md-8 { - flex: 0 0 66.66667%; - max-width: 66.66667%; -} - -.col-1, -.col-2, -.col-3, -.col-4, -.col-5, -.col-6, -.col-7, -.col-8, -.col-9, -.col-10, -.col-11, -.col-12, -.col, -.col-auto, -.col-sm-1, -.col-sm-2, -.col-sm-3, -.col-sm-4, -.col-sm-5, -.col-sm-6, -.col-sm-7, -.col-sm-8, -.col-sm-9, -.col-sm-10, -.col-sm-11, -.col-sm-12, -.col-sm, -.col-sm-auto, -.col-md-1, -.col-md-2, -.col-md-3, -.col-md-4, -.col-md-5, -.col-md-6, -.col-md-7, -.col-md-8, -.col-md-9, -.col-md-10, -.col-md-11, -.col-md-12, -.col-md, -.col-md-auto, -.col-lg-1, -.col-lg-2, -.col-lg-3, -.col-lg-4, -.col-lg-5, -.col-lg-6, -.col-lg-7, -.col-lg-8, -.col-lg-9, -.col-lg-10, -.col-lg-11, -.col-lg-12, -.col-lg, -.col-lg-auto, -.col-xl-1, -.col-xl-2, -.col-xl-3, -.col-xl-4, -.col-xl-5, -.col-xl-6, -.col-xl-7, -.col-xl-8, -.col-xl-9, -.col-xl-10, -.col-xl-11, -.col-xl-12, -.col-xl, -.col-xl-auto { - position: relative; - width: 100%; - min-height: 1px; - padding-right: 7.5px; - padding-left: 7.5px; -} - -.mb-3, -.my-3 { - margin-bottom: 1rem !important; -} - -.col-md-6 { - flex: 0 0 50%; - max-width: 50%; -} - -.col-md-4 { - flex: 0 0 33.33333%; - max-width: 31.33333%; -} - -.bg-light { - background-color: #f8f9fa !important; -} - -.card { - position: relative; - display: flex; - flex-direction: column; - min-width: 0; - word-wrap: break-word; - background-color: transparent; - background-clip: border-box; - border: 1px solid #ccc; - border-radius: .25rem; -} - -.row { - display: flex; - flex-wrap: wrap; - margin-right: -7.5px; - margin-left: -7.5px; -} - -.card-body { - box-shadow: 0 1px 2px rgba(0, 0, 0, 0.25); - flex: 1 1 auto; - padding: 1.25rem; -} - -.card-footer { - padding: .75rem 1.25rem; - background-color: transparent; - border-top: 0 solid transparent; -} - -p { - margin-top: 0; - margin-bottom: 1rem; -} - -ol, -ul, -dl { - margin-top: 0; - margin-bottom: 1rem; -} - -.form-row { - display: flex; - margin-right: -5px; - margin-left: -5px; -} - -.form-row>.col, -.form-row>[class*="col-"] { - padding-right: 5px; - padding-left: 5px; -} - -.custom-file { - position: relative; - display: inline-block; - width: 100%; - height: calc(2.7rem + 2px); - margin-bottom: 0; -} - -.custom-file-input { - position: relative; - z-index: 2; - width: 100%; - height: calc(2.7rem + 2px); - margin: 0; - opacity: 0; -} - -.custom-file-label { - position: absolute; - top: 0; - right: 0; - left: 0; - z-index: 1; - padding: .6rem 1rem; - line-height: 1.5; - color: #495057; - background-color: #fff; - border: .25rem; -} - -.invalid-feedback { - display: none; - width: 100%; - margin-top: .25rem; - font-size: 80%; - color: #c52827; -} - -.btn:not(:disabled):not(.disabled) { - cursor: pointer; -} - -.btn-success { - color: #fff; - background-color: #2f7d32; - border-color: #2f7d32; -} - -.btn { - font-weight: 400; - text-align: center; - white-space: nowrap; - vertical-align: middle; - -webkit-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; - padding: .6rem 1rem; - line-height: 1.5; - transition: color .15s ease-in-out, background-color .15s ease-in-out, border-color .15s ease-in-out, box-shadow .15s ease-in-out; -} - -.btn { - white-space: normal !important; -} - -button, -html [type="button"], -[type="reset"], -[type="submit"] { - -webkit-appearance: button; -} - -button, -select { - text-transform: none; -} - -button, -input { - overflow: visible; -} - -input, -button, -select, -optgroup, -textarea { - margin: 0; - font-family: inherit; - font-size: inherit; - line-height: inherit; -} - -button { - border-radius: 0; -} - -.text-white { - color: #fff !important; -} - -.bg-info { - background-color: #17a2b8 !important; -} - -.card-header { - padding: .75rem 1.25rem; - margin-bottom: 0; - /*background-color: transparent;*/ - background-color: rgba(0, 0, 0, .03); - border-bottom: 1px solid #ccc; -} - -.custom-file-label::after { - position: absolute; - top: 0; - right: 0; - bottom: 0; - z-index: 3; - display: block; - padding: .6rem 1rem; - line-height: 1.5; - color: white; - content: "Browse"; - background-color: #3073bb; - border-left: 1px solid #ced4da; - border-radius: 0 .25rem .25rem 0; -} \ No newline at end of file diff --git a/media/com_jedchecker/css/j3-style.min.css b/media/com_jedchecker/css/j3-style.min.css deleted file mode 100644 index 1cdff75..0000000 --- a/media/com_jedchecker/css/j3-style.min.css +++ /dev/null @@ -1 +0,0 @@ -.col-md-8{flex:0 0 66.66667%;max-width:66.66667%}.col,.col-1,.col-10,.col-11,.col-12,.col-2,.col-3,.col-4,.col-5,.col-6,.col-7,.col-8,.col-9,.col-auto,.col-lg,.col-lg-1,.col-lg-10,.col-lg-11,.col-lg-12,.col-lg-2,.col-lg-3,.col-lg-4,.col-lg-5,.col-lg-6,.col-lg-7,.col-lg-8,.col-lg-9,.col-lg-auto,.col-md,.col-md-1,.col-md-10,.col-md-11,.col-md-12,.col-md-2,.col-md-3,.col-md-4,.col-md-5,.col-md-6,.col-md-7,.col-md-8,.col-md-9,.col-md-auto,.col-sm,.col-sm-1,.col-sm-10,.col-sm-11,.col-sm-12,.col-sm-2,.col-sm-3,.col-sm-4,.col-sm-5,.col-sm-6,.col-sm-7,.col-sm-8,.col-sm-9,.col-sm-auto,.col-xl,.col-xl-1,.col-xl-10,.col-xl-11,.col-xl-12,.col-xl-2,.col-xl-3,.col-xl-4,.col-xl-5,.col-xl-6,.col-xl-7,.col-xl-8,.col-xl-9,.col-xl-auto{position:relative;width:100%;min-height:1px;padding-right:7.5px;padding-left:7.5px}.mb-3,.my-3{margin-bottom:1rem!important}.col-md-6{flex:0 0 50%;max-width:50%}.col-md-4{flex:0 0 33.33333%;max-width:31.33333%}.bg-light{background-color:#f8f9fa!important}.card{position:relative;display:flex;flex-direction:column;min-width:0;word-wrap:break-word;background-color:transparent;background-clip:border-box;border:1px solid #ccc;border-radius:.25rem}.row{display:flex;flex-wrap:wrap;margin-right:-7.5px;margin-left:-7.5px}.card-body{box-shadow:0 1px 2px rgba(0,0,0,.25);flex:1 1 auto;padding:1.25rem}.card-footer{padding:.75rem 1.25rem;background-color:transparent;border-top:0 solid transparent}p{margin-top:0;margin-bottom:1rem}dl,ol,ul{margin-top:0;margin-bottom:1rem}.form-row{display:flex;margin-right:-5px;margin-left:-5px}.form-row>.col,.form-row>[class*=col-]{padding-right:5px;padding-left:5px}.custom-file{position:relative;display:inline-block;width:100%;height:calc(2.7rem + 2px);margin-bottom:0}.custom-file-input{position:relative;z-index:2;width:100%;height:calc(2.7rem + 2px);margin:0;opacity:0}.custom-file-label{position:absolute;top:0;right:0;left:0;z-index:1;padding:.6rem 1rem;line-height:1.5;color:#495057;background-color:#fff;border:.25rem}.invalid-feedback{display:none;width:100%;margin-top:.25rem;font-size:80%;color:#c52827}.btn:not(:disabled):not(.disabled){cursor:pointer}.btn-success{color:#fff;background-color:#2f7d32;border-color:#2f7d32}.btn{font-weight:400;text-align:center;white-space:nowrap;vertical-align:middle;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;padding:.6rem 1rem;line-height:1.5;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}.btn{white-space:normal!important}[type=reset],[type=submit],button,html [type=button]{-webkit-appearance:button}button,select{text-transform:none}button,input{overflow:visible}button,input,optgroup,select,textarea{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}button{border-radius:0}.text-white{color:#fff!important}.bg-info{background-color:#17a2b8!important}.card-header{padding:.75rem 1.25rem;margin-bottom:0;background-color:rgba(0,0,0,.03);border-bottom:1px solid #ccc}.custom-file-label::after{position:absolute;top:0;right:0;bottom:0;z-index:3;display:block;padding:.6rem 1rem;line-height:1.5;color:#fff;content:"Browse";background-color:#3073bb;border-left:1px solid #ced4da;border-radius:0 .25rem .25rem 0} \ No newline at end of file diff --git a/media/com_jedchecker/css/j4-style.css b/media/com_jedchecker/css/j4-style.css new file mode 100644 index 0000000..1939488 --- /dev/null +++ b/media/com_jedchecker/css/j4-style.css @@ -0,0 +1,792 @@ +@charset "UTF-8"; +#jedchecker *, +#jedchecker *::before, +#jedchecker *::after { + box-sizing: border-box; +} +#jedchecker { + margin: 0; + font-size: 1rem; + font-weight: 400; + line-height: 1.5; + color: #495057; + -webkit-text-size-adjust: 100%; + -webkit-tap-highlight-color: rgba(0, 0, 0, 0); +} +#jedchecker h5 { + margin-top: 0; + margin-bottom: 0.5rem; + font-weight: 500; + line-height: 1.2; +} +#jedchecker h5 { + font-size: 0.9286rem; +} +#jedchecker p { + margin-top: 0; + margin-bottom: 1rem; +} +#jedchecker ol { + padding-left: 2rem; +} +#jedchecker ol { + margin-top: 0; + margin-bottom: 1rem; +} +#jedchecker strong { + font-weight: bolder; +} +#jedchecker small { + font-size: 0.875em; +} +#jedchecker a { + color: #2a69b8; + text-decoration: underline; +} +#jedchecker a:hover { + color: #173a65; +} +#jedchecker a:not([href]):not([class]), +#jedchecker a:not([href]):not([class]):hover { + color: inherit; + text-decoration: none; +} +#jedchecker pre { + font-size: 1em; + direction: ltr; + unicode-bidi: bidi-override; +} +#jedchecker pre { + display: block; + margin-top: 0; + margin-bottom: 1rem; + overflow: auto; + font-size: 0.875em; +} +#jedchecker button { + border-radius: 0; +} +#jedchecker button:focus { + outline: dotted 1px; + outline: -webkit-focus-ring-color auto 5px; +} +#jedchecker input, +#jedchecker button { + margin: 0; + font-family: inherit; + font-size: inherit; + line-height: inherit; +} +#jedchecker button { + text-transform: none; +} +#jedchecker button, +#jedchecker [type=button] { + -webkit-appearance: button; +} +#jedchecker button:not(:disabled), +#jedchecker [type=button]:not(:disabled) { + cursor: pointer; +} +#jedchecker ::-moz-focus-inner { + padding: 0; + border-style: none; +} +#jedchecker ::-webkit-inner-spin-button { + height: auto; +} +#jedchecker ::-webkit-search-decoration { + -webkit-appearance: none; +} +#jedchecker ::file-selector-button { + font: inherit; +} +#jedchecker ::-webkit-file-upload-button { + font: inherit; + -webkit-appearance: button; +} +#jedchecker .row { + --gutter-x: 2rem; + --gutter-y: 0; + display: flex; + flex-wrap: wrap; + margin-top: calc(var(--gutter-y) * -1); + margin-right: calc(var(--gutter-x) / -2); + margin-left: calc(var(--gutter-x) / -2); +} +#jedchecker .row > * { + flex-shrink: 0; + width: 100%; + max-width: 100%; + padding-right: calc(var(--gutter-x) / 2); + padding-left: calc(var(--gutter-x) / 2); + margin-top: var(--gutter-y); +} +#jedchecker .col-6 { + flex: 0 0 auto; + width: 50%; +} +#jedchecker .col-12 { + flex: 0 0 auto; + width: 100%; +} +#jedchecker .g-3 { + --gutter-x: 1rem; + --gutter-y: 1rem; +} +@media (min-width: 768px) { + #jedchecker .col-md-3 { + flex: 0 0 auto; + width: 25%; + } + #jedchecker .col-md-4 { + flex: 0 0 auto; + width: 33.3333333333%; + } + #jedchecker .col-md-8 { + flex: 0 0 auto; + width: 66.6666666667%; + } + #jedchecker .col-md-9 { + flex: 0 0 auto; + width: 75%; + } +} +#jedchecker .form-control { + display: block; + width: 100%; + padding: 0.6rem 1rem; + font-size: 1rem; + font-weight: 400; + line-height: 1.5; + color: #495057; + background-color: #fff; + background-clip: padding-box; + border: 1px solid #cdcdcd; + -webkit-appearance: none; + -moz-appearance: none; + appearance: none; + border-radius: 0.25rem; + transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; +} +#jedchecker .form-control[type=file] { + overflow: hidden; +} +#jedchecker .form-control[type=file]:not(:disabled):not([readonly]) { + cursor: pointer; +} +#jedchecker .form-control:focus { + color: #495057; + background-color: #fff; + border-color: #95b4db; + outline: 0; + box-shadow: 0 0 0 0.25rem rgba(42, 105, 183, 0.25); +} +#jedchecker .form-control::-webkit-date-and-time-value { + height: 1.5em; +} +#jedchecker .form-control::-webkit-input-placeholder { + color: #6c757d; + opacity: 1; +} +#jedchecker .form-control::-moz-placeholder { + color: #6c757d; + opacity: 1; +} +#jedchecker .form-control:-ms-input-placeholder { + color: #6c757d; + opacity: 1; +} +#jedchecker .form-control::-ms-input-placeholder { + color: #6c757d; + opacity: 1; +} +#jedchecker .form-control::placeholder { + color: #6c757d; + opacity: 1; +} +#jedchecker .form-control:disabled { + background-color: #e8e8e8; + opacity: 1; +} +#jedchecker .form-control::file-selector-button { + padding: 0.6rem 1rem; + margin: -0.6rem -1rem; + -webkit-margin-end: 1rem; + margin-inline-end: 1rem; + color: #fff; + background-color: #132f53; + pointer-events: none; + border-color: inherit; + border-style: solid; + border-width: 0; + border-inline-end-width: 1px; + border-radius: 0; + transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; +} +#jedchecker .form-control:hover:not(:disabled):not([readonly])::file-selector-button { + background-color: #122d4f; +} +#jedchecker .form-control::-webkit-file-upload-button { + padding: 0.6rem 1rem; + margin: -0.6rem -1rem; + -webkit-margin-end: 1rem; + margin-inline-end: 1rem; + color: #fff; + background-color: #132f53; + pointer-events: none; + border-color: inherit; + border-style: solid; + border-width: 0; + border-inline-end-width: 1px; + border-radius: 0; + -webkit-transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; + transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; +} +#jedchecker .form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button { + background-color: #122d4f; +} +#jedchecker .input-group { + position: relative; + display: flex; + flex-wrap: wrap; + align-items: stretch; + width: 100%; +} +#jedchecker .input-group > .form-control { + position: relative; + flex: 1 1 auto; + width: 1%; + min-width: 0; +} +#jedchecker .input-group > .form-control:focus { + z-index: 3; +} +#jedchecker .input-group .btn { + position: relative; + z-index: 2; +} +#jedchecker .input-group .btn:focus { + z-index: 3; +} +#jedchecker .input-group:not(.has-validation) > :not(:last-child):not(.dropdown-toggle):not(.dropdown-menu) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; +} +#jedchecker .input-group > :not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback) { + margin-left: -1px; + border-top-left-radius: 0; + border-bottom-left-radius: 0; +} +#jedchecker .invalid-feedback { + display: none; + width: 100%; + margin-top: 0.25rem; + font-size: 0.875em; + color: #c52827; +} +#jedchecker .btn { + display: inline-block; + font-weight: 400; + line-height: 1.5; + color: #495057; + text-align: center; + text-decoration: none; + vertical-align: middle; + cursor: pointer; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + background-color: transparent; + border: 1px solid transparent; + padding: 0.6rem 1rem; + font-size: 1rem; + border-radius: 0.25rem; + transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; +} +#jedchecker .btn:hover { + color: #495057; +} +#jedchecker .btn:focus { + outline: 0; + box-shadow: 0 0 0 0.25rem rgba(42, 105, 183, 0.25); +} +#jedchecker .btn:disabled { + pointer-events: none; + opacity: 0.4; +} +#jedchecker .btn-success { + color: #fff; + background-color: #2f7d32; + border-color: #2f7d32; +} +#jedchecker .btn-success:hover { + color: #fff; + background-color: #286a2b; + border-color: #266428; +} +#jedchecker .btn-success:focus { + color: #fff; + background-color: #286a2b; + border-color: #266428; + box-shadow: 0 0 0 0.25rem rgba(78, 145, 81, 0.5); +} +#jedchecker .btn-success:active { + color: #fff; + background-color: #266428; + border-color: #235e26; +} +#jedchecker .btn-success:active:focus { + box-shadow: 0 0 0 0.25rem rgba(78, 145, 81, 0.5); +} +#jedchecker .btn-success:disabled { + color: #fff; + background-color: #2f7d32; + border-color: #2f7d32; +} +#jedchecker .btn-light { + color: #000; + background-color: #f8f9fa; + border-color: #f8f9fa; +} +#jedchecker .btn-light:hover { + color: #000; + background-color: #f9fafb; + border-color: #f9fafb; +} +#jedchecker .btn-light:focus { + color: #000; + background-color: #f9fafb; + border-color: #f9fafb; + box-shadow: 0 0 0 0.25rem rgba(211, 212, 213, 0.5); +} +#jedchecker .btn-light:active { + color: #000; + background-color: #f9fafb; + border-color: #f9fafb; +} +#jedchecker .btn-light:active:focus { + box-shadow: 0 0 0 0.25rem rgba(211, 212, 213, 0.5); +} +#jedchecker .btn-light:disabled { + color: #000; + background-color: #f8f9fa; + border-color: #f8f9fa; +} +#jedchecker .fade { + transition: opacity 0.15s linear; +} +#jedchecker .fade:not(.show) { + opacity: 0; +} +#jedchecker .collapse:not(.show) { + display: none; +} +#jedchecker .collapsing { + height: 0; + overflow: hidden; + transition: height 0.35s ease; +} +#jedchecker .accordion-button { + position: relative; + display: flex; + align-items: center; + width: 100%; + padding: 1rem 1.25rem; + font-size: 1rem; + color: #495057; + background-color: transparent; + border: 1px solid rgba(0, 0, 0, 0.125); + border-radius: 0; + overflow-anchor: none; + transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out, border-radius 0.15s ease; +} +#jedchecker .accordion-button.collapsed { + border-bottom-width: 0; +} +#jedchecker .accordion-button:not(.collapsed) { + color: #265fa5; + background-color: #eaf0f8; +} +#jedchecker .accordion-button:not(.collapsed)::after { + background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23265fa5'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e"); + -webkit-transform: rotate(180deg); + transform: rotate(180deg); +} +#jedchecker .accordion-button::after { + flex-shrink: 0; + width: 1.25rem; + height: 1.25rem; + margin-left: auto; + content: ""; + background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23495057'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e"); + background-repeat: no-repeat; + background-size: 1.25rem; + transition: -webkit-transform 0.2s ease-in-out; + transition: transform 0.2s ease-in-out; + transition: transform 0.2s ease-in-out, -webkit-transform 0.2s ease-in-out; +} +#jedchecker .accordion-button:hover { + z-index: 2; +} +#jedchecker .accordion-button:focus { + z-index: 3; + border-color: #95b4db; + outline: 0; + box-shadow: 0 0 0 0.25rem rgba(42, 105, 183, 0.25); +} +#jedchecker .tab-content > .tab-pane { + display: none; +} +#jedchecker .tab-content > .active { + display: block; +} +#jedchecker .card { + position: relative; + display: flex; + flex-direction: column; + min-width: 0; + word-wrap: break-word; + background-color: #fff; + background-clip: border-box; + border: 0 solid transparent; + border-radius: 0.25rem; +} +#jedchecker .card > .list-group { + border-top: inherit; + border-bottom: inherit; +} +#jedchecker .card > .list-group:first-child { + border-top-width: 0; + border-top-left-radius: 0.25rem; + border-top-right-radius: 0.25rem; +} +#jedchecker .card > .list-group:last-child { + border-bottom-width: 0; + border-bottom-right-radius: 0.25rem; + border-bottom-left-radius: 0.25rem; +} +#jedchecker .card > .card-header + .list-group { + border-top: 0; +} +#jedchecker .card-body { + flex: 1 1 auto; + padding: 1rem 1rem; +} +#jedchecker .card-title { + margin-bottom: 0.5rem; +} +#jedchecker .card-text:last-child { + margin-bottom: 0; +} +#jedchecker .card-header { + padding: 0.5rem 1rem; + margin-bottom: 0; + background-color: rgba(0, 0, 0, 0.03); + border-bottom: 0 solid transparent; +} +#jedchecker .card-header:first-child { + border-radius: 0.25rem 0.25rem 0 0; +} +#jedchecker .card-footer { + padding: 0.5rem 1rem; + background-color: rgba(0, 0, 0, 0.03); + border-top: 0 solid transparent; +} +#jedchecker .card-footer:last-child { + border-radius: 0 0 0.25rem 0.25rem; +} +#jedchecker .badge { + display: inline-block; + padding: 0.3rem 0.2rem; + font-size: 0.75rem; + font-weight: 700; + line-height: 1; + color: #fff; + text-align: center; + white-space: nowrap; + vertical-align: baseline; + border-radius: 0.2rem; +} +#jedchecker .badge:empty { + display: none; +} +#jedchecker .alert { + position: relative; + padding: 1rem 1rem; + margin-bottom: 1rem; + border: 1px solid transparent; + border-radius: 0.25rem; +} +#jedchecker .alert-secondary { + color: #2c3034; + background-color: #dbdcdd; + border-color: #c8cbcd; +} +#jedchecker .alert-success { + color: #1c4b1e; + background-color: #d5e5d6; + border-color: #c1d8c2; +} +#jedchecker .alert-info { + color: #193f6e; + background-color: #d4e1f1; + border-color: #bfd2ea; +} +#jedchecker .alert-warning { + color: #664808; + background-color: #fff0d0; + border-color: #ffe9b9; +} +#jedchecker .alert-danger { + color: #761817; + background-color: #f3d4d4; + border-color: #eebfbe; +} +#jedchecker .list-group { + display: flex; + flex-direction: column; + padding-left: 0; + margin-bottom: 0; + border-radius: 0.25rem; +} +#jedchecker .list-group-item-action { + width: 100%; + color: #495057; + text-align: inherit; +} +#jedchecker .list-group-item-action:hover, +#jedchecker .list-group-item-action:focus { + z-index: 1; + color: #495057; + text-decoration: none; + background-color: #f8f9fa; +} +#jedchecker .list-group-item-action:active { + color: #495057; + background-color: #e8e8e8; +} +#jedchecker .list-group-item { + position: relative; + display: block; + padding: 0.5rem 1rem; + text-decoration: none; + background-color: #fefefe; + border: 1px solid rgba(0, 0, 0, 0.125); +} +#jedchecker .list-group-item:first-child { + border-top-left-radius: inherit; + border-top-right-radius: inherit; +} +#jedchecker .list-group-item:last-child { + border-bottom-right-radius: inherit; + border-bottom-left-radius: inherit; +} +#jedchecker .list-group-item:disabled { + color: #6c757d; + pointer-events: none; + background-color: #fefefe; +} +#jedchecker .list-group-item.active { + z-index: 2; + color: #fff; + background-color: #2a69b7; + border-color: #2a69b7; +} +#jedchecker .list-group-flush { + border-radius: 0; +} +#jedchecker .list-group-flush > .list-group-item { + border-width: 0 0 1px; +} +#jedchecker .list-group-flush > .list-group-item:last-child { + border-bottom-width: 0; +} +#jedchecker .list-group-item-action { + color: #0b1c32; + background-color: #d0d5dd; +} +#jedchecker .list-group-item-action.list-group-item-action:hover, +#jedchecker .list-group-item-action.list-group-item-action:focus { + color: #0b1c32; + background-color: #bbc0c7; +} +#jedchecker .list-group-item-action.list-group-item-action.active { + color: #fff; + background-color: #0b1c32; + border-color: #0b1c32; +} +#jedchecker .d-flex { + display: flex !important; +} +#jedchecker .border-error { + border-color: #3b0d0c !important; +} +#jedchecker .justify-content-between { + justify-content: space-between !important; +} +#jedchecker .ps-1 { + padding-left: 0.25rem !important; +} +#jedchecker .text-center { + text-align: center !important; +} +#jedchecker .text-info { + color: #2a69b8 !important; +} +#jedchecker .text-white { + color: #fff !important; +} +#jedchecker .text-muted { + color: #6c757d !important; +} +#jedchecker .bg-secondary { + background-color: #495057 !important; +} +#jedchecker .bg-success { + background-color: #2f7d32 !important; +} +#jedchecker .bg-info { + background-color: #2a69b8 !important; +} +#jedchecker .bg-warning { + background-color: #ffb514 !important; +} +#jedchecker .bg-danger { + background-color: #c52827 !important; +} +#jedchecker .bg-light { + background-color: #f8f9fa !important; +} +#jedchecker .text-nowrap { + white-space: nowrap !important; +} +#jedchecker .rounded-pill { + border-radius: 50rem !important; +} +#jedchecker { + display: flex; + flex-direction: column; + min-height: 100%; + padding: 0; + margin: 0; + text-align: start; +} +#jedchecker h5 { + font-weight: 700; +} +#jedchecker small { + font-size: 0.8rem; +} +#jedchecker .input-group input { + min-width: 220px; +} +#jedchecker .text-muted { + color: #495057 !important; + opacity: 0.7; +} +@media (max-width: 767.98px) { + #jedchecker .badge { + white-space: normal; + } +} +#jedchecker .badge.bg-warning { + color: #000; + background-color: #f9d71c !important; + border: 1px solid #4d4d4d; +} +#jedchecker .badge.bg-success { + color: #fff; + background-color: #2f7d32 !important; + border: 1px solid white; +} +#jedchecker .badge.bg-danger { + color: #fff; + background-color: #900 !important; + border: 1px solid white; +} +#jedchecker .badge.bg-secondary, +#jedchecker .badge.bg-info { + color: #495057; + background-color: #dee2e6 !important; + border: 1px solid #949da5; +} +#jedchecker .btn { + transition: none; +} +#jedchecker .card { + box-shadow: 0 2px 4px rgba(0, 0, 0, 0.16), 0 2px 4px rgba(0, 0, 0, 0.23); +} +#jedchecker .list-group-item { + background-color: #fefefe; +} +#jedchecker .alert { + margin: 1rem 0; + border-right: 0; + border-left: 0; + border-radius: 0.2rem; +} +#jedchecker .alert.alert-info { + color: #132f53; + background-color: #cacaca; + border: 1px solid #acacac; +} +#jedchecker .alert.alert-warning { + color: #495057; + background-color: #ffb514; + border: 1px solid #ffb514; +} +#jedchecker .alert.alert-success { + color: #0f2f21; + background-color: #e1f5ec; + border: 1px solid #0f2f21; +} +#jedchecker .form-control { + max-width: 100%; + background-color: #fff; + border: solid 1px #c9c9c9; + border-radius: 0.25rem; + box-shadow: inset 0 0 0 0.1rem #e9e9e9; +} +#jedchecker .form-control:focus { + border-color: #39f; + box-shadow: 0 0 0 0.2rem #eaeaea; +} +#jedchecker .form-control:disabled { + border: 0; + box-shadow: none; +} +#jedchecker * { + box-sizing: border-box; +} +#jedchecker .hidden { + display: none; +} +@media (prefers-reduced-motion: reduce) { + #jedchecker .form-control, + #jedchecker .form-control::file-selector-button, + #jedchecker .form-control::-webkit-file-upload-button, + #jedchecker .btn, + #jedchecker .fade, + #jedchecker .collapsing, + #jedchecker .accordion-button, + #jedchecker .accordion-button::after { + -webkit-transition: none; + transition: none; + } + #jedchecker *, + #jedchecker ::before, + #jedchecker ::after { + background-attachment: initial !important; + transition-delay: 0s !important; + transition-duration: 0s !important; + -webkit-animation-duration: 1ms !important; + animation-duration: 1ms !important; + -webkit-animation-delay: -1ms !important; + animation-delay: -1ms !important; + -webkit-animation-iteration-count: 1 !important; + animation-iteration-count: 1 !important; + scroll-behavior: auto !important; + } +} diff --git a/media/com_jedchecker/css/j4-style.min.css b/media/com_jedchecker/css/j4-style.min.css new file mode 100644 index 0000000..9af0ea1 --- /dev/null +++ b/media/com_jedchecker/css/j4-style.min.css @@ -0,0 +1 @@ +@charset "UTF-8";#jedchecker *,#jedchecker ::after,#jedchecker ::before{box-sizing:border-box}#jedchecker{margin:0;font-size:1rem;font-weight:400;line-height:1.5;color:#495057;-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}#jedchecker h5{margin-top:0;margin-bottom:.5rem;font-weight:500;line-height:1.2}#jedchecker h5{font-size:.9286rem}#jedchecker p{margin-top:0;margin-bottom:1rem}#jedchecker ol{padding-left:2rem}#jedchecker ol{margin-top:0;margin-bottom:1rem}#jedchecker strong{font-weight:bolder}#jedchecker small{font-size:.875em}#jedchecker a{color:#2a69b8;text-decoration:underline}#jedchecker a:hover{color:#173a65}#jedchecker a:not([href]):not([class]),#jedchecker a:not([href]):not([class]):hover{color:inherit;text-decoration:none}#jedchecker pre{font-size:1em;direction:ltr;unicode-bidi:bidi-override}#jedchecker pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:.875em}#jedchecker button{border-radius:0}#jedchecker button:focus{outline:dotted 1px;outline:-webkit-focus-ring-color auto 5px}#jedchecker button,#jedchecker input{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}#jedchecker button{text-transform:none}#jedchecker [type=button],#jedchecker button{-webkit-appearance:button}#jedchecker [type=button]:not(:disabled),#jedchecker button:not(:disabled){cursor:pointer}#jedchecker ::-moz-focus-inner{padding:0;border-style:none}#jedchecker ::-webkit-inner-spin-button{height:auto}#jedchecker ::-webkit-search-decoration{-webkit-appearance:none}#jedchecker ::file-selector-button{font:inherit}#jedchecker ::-webkit-file-upload-button{font:inherit;-webkit-appearance:button}#jedchecker .row{--gutter-x:2rem;--gutter-y:0;display:flex;flex-wrap:wrap;margin-top:calc(var(--gutter-y) * -1);margin-right:calc(var(--gutter-x)/ -2);margin-left:calc(var(--gutter-x)/ -2)}#jedchecker .row>*{flex-shrink:0;width:100%;max-width:100%;padding-right:calc(var(--gutter-x)/ 2);padding-left:calc(var(--gutter-x)/ 2);margin-top:var(--gutter-y)}#jedchecker .col-6{flex:0 0 auto;width:50%}#jedchecker .col-12{flex:0 0 auto;width:100%}#jedchecker .g-3{--gutter-x:1rem;--gutter-y:1rem}@media (min-width:768px){#jedchecker .col-md-3{flex:0 0 auto;width:25%}#jedchecker .col-md-4{flex:0 0 auto;width:33.3333333333%}#jedchecker .col-md-8{flex:0 0 auto;width:66.6666666667%}#jedchecker .col-md-9{flex:0 0 auto;width:75%}}#jedchecker .form-control{display:block;width:100%;padding:.6rem 1rem;font-size:1rem;font-weight:400;line-height:1.5;color:#495057;background-color:#fff;background-clip:padding-box;border:1px solid #cdcdcd;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:.25rem;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control[type=file]{overflow:hidden}#jedchecker .form-control[type=file]:not(:disabled):not([readonly]){cursor:pointer}#jedchecker .form-control:focus{color:#495057;background-color:#fff;border-color:#95b4db;outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .form-control::-webkit-date-and-time-value{height:1.5em}#jedchecker .form-control::-webkit-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::-moz-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control:-ms-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::-ms-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::placeholder{color:#6c757d;opacity:1}#jedchecker .form-control:disabled{background-color:#e8e8e8;opacity:1}#jedchecker .form-control::file-selector-button{padding:.6rem 1rem;margin:-.6rem -1rem;-webkit-margin-end:1rem;margin-inline-end:1rem;color:#fff;background-color:#132f53;pointer-events:none;border-color:inherit;border-style:solid;border-width:0;border-inline-end-width:1px;border-radius:0;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control:hover:not(:disabled):not([readonly])::file-selector-button{background-color:#122d4f}#jedchecker .form-control::-webkit-file-upload-button{padding:.6rem 1rem;margin:-.6rem -1rem;-webkit-margin-end:1rem;margin-inline-end:1rem;color:#fff;background-color:#132f53;pointer-events:none;border-color:inherit;border-style:solid;border-width:0;border-inline-end-width:1px;border-radius:0;-webkit-transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button{background-color:#122d4f}#jedchecker .input-group{position:relative;display:flex;flex-wrap:wrap;align-items:stretch;width:100%}#jedchecker .input-group>.form-control{position:relative;flex:1 1 auto;width:1%;min-width:0}#jedchecker .input-group>.form-control:focus{z-index:3}#jedchecker .input-group .btn{position:relative;z-index:2}#jedchecker .input-group .btn:focus{z-index:3}#jedchecker .input-group:not(.has-validation)>:not(:last-child):not(.dropdown-toggle):not(.dropdown-menu){border-top-right-radius:0;border-bottom-right-radius:0}#jedchecker .input-group>:not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback){margin-left:-1px;border-top-left-radius:0;border-bottom-left-radius:0}#jedchecker .invalid-feedback{display:none;width:100%;margin-top:.25rem;font-size:.875em;color:#c52827}#jedchecker .btn{display:inline-block;font-weight:400;line-height:1.5;color:#495057;text-align:center;text-decoration:none;vertical-align:middle;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-color:transparent;border:1px solid transparent;padding:.6rem 1rem;font-size:1rem;border-radius:.25rem;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .btn:hover{color:#495057}#jedchecker .btn:focus{outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .btn:disabled{pointer-events:none;opacity:.4}#jedchecker .btn-success{color:#fff;background-color:#2f7d32;border-color:#2f7d32}#jedchecker .btn-success:hover{color:#fff;background-color:#286a2b;border-color:#266428}#jedchecker .btn-success:focus{color:#fff;background-color:#286a2b;border-color:#266428;box-shadow:0 0 0 .25rem rgba(78,145,81,.5)}#jedchecker .btn-success:active{color:#fff;background-color:#266428;border-color:#235e26}#jedchecker .btn-success:active:focus{box-shadow:0 0 0 .25rem rgba(78,145,81,.5)}#jedchecker .btn-success:disabled{color:#fff;background-color:#2f7d32;border-color:#2f7d32}#jedchecker .btn-light{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}#jedchecker .btn-light:hover{color:#000;background-color:#f9fafb;border-color:#f9fafb}#jedchecker .btn-light:focus{color:#000;background-color:#f9fafb;border-color:#f9fafb;box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}#jedchecker .btn-light:active{color:#000;background-color:#f9fafb;border-color:#f9fafb}#jedchecker .btn-light:active:focus{box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}#jedchecker .btn-light:disabled{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}#jedchecker .fade{transition:opacity .15s linear}#jedchecker .fade:not(.show){opacity:0}#jedchecker .collapse:not(.show){display:none}#jedchecker .collapsing{height:0;overflow:hidden;transition:height .35s ease}#jedchecker .accordion-button{position:relative;display:flex;align-items:center;width:100%;padding:1rem 1.25rem;font-size:1rem;color:#495057;background-color:transparent;border:1px solid rgba(0,0,0,.125);border-radius:0;overflow-anchor:none;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out,border-radius .15s ease}#jedchecker .accordion-button.collapsed{border-bottom-width:0}#jedchecker .accordion-button:not(.collapsed){color:#265fa5;background-color:#eaf0f8}#jedchecker .accordion-button:not(.collapsed)::after{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23265fa5'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");-webkit-transform:rotate(180deg);transform:rotate(180deg)}#jedchecker .accordion-button::after{flex-shrink:0;width:1.25rem;height:1.25rem;margin-left:auto;content:"";background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23495057'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");background-repeat:no-repeat;background-size:1.25rem;transition:-webkit-transform .2s ease-in-out;transition:transform .2s ease-in-out;transition:transform .2s ease-in-out,-webkit-transform .2s ease-in-out}#jedchecker .accordion-button:hover{z-index:2}#jedchecker .accordion-button:focus{z-index:3;border-color:#95b4db;outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .tab-content>.tab-pane{display:none}#jedchecker .tab-content>.active{display:block}#jedchecker .card{position:relative;display:flex;flex-direction:column;min-width:0;word-wrap:break-word;background-color:#fff;background-clip:border-box;border:0 solid transparent;border-radius:.25rem}#jedchecker .card>.list-group{border-top:inherit;border-bottom:inherit}#jedchecker .card>.list-group:first-child{border-top-width:0;border-top-left-radius:.25rem;border-top-right-radius:.25rem}#jedchecker .card>.list-group:last-child{border-bottom-width:0;border-bottom-right-radius:.25rem;border-bottom-left-radius:.25rem}#jedchecker .card>.card-header+.list-group{border-top:0}#jedchecker .card-body{flex:1 1 auto;padding:1rem 1rem}#jedchecker .card-title{margin-bottom:.5rem}#jedchecker .card-text:last-child{margin-bottom:0}#jedchecker .card-header{padding:.5rem 1rem;margin-bottom:0;background-color:rgba(0,0,0,.03);border-bottom:0 solid transparent}#jedchecker .card-header:first-child{border-radius:.25rem .25rem 0 0}#jedchecker .card-footer{padding:.5rem 1rem;background-color:rgba(0,0,0,.03);border-top:0 solid transparent}#jedchecker .card-footer:last-child{border-radius:0 0 .25rem .25rem}#jedchecker .badge{display:inline-block;padding:.3rem .2rem;font-size:.75rem;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.2rem}#jedchecker .badge:empty{display:none}#jedchecker .alert{position:relative;padding:1rem 1rem;margin-bottom:1rem;border:1px solid transparent;border-radius:.25rem}#jedchecker .alert-secondary{color:#2c3034;background-color:#dbdcdd;border-color:#c8cbcd}#jedchecker .alert-success{color:#1c4b1e;background-color:#d5e5d6;border-color:#c1d8c2}#jedchecker .alert-info{color:#193f6e;background-color:#d4e1f1;border-color:#bfd2ea}#jedchecker .alert-warning{color:#664808;background-color:#fff0d0;border-color:#ffe9b9}#jedchecker .alert-danger{color:#761817;background-color:#f3d4d4;border-color:#eebfbe}#jedchecker .list-group{display:flex;flex-direction:column;padding-left:0;margin-bottom:0;border-radius:.25rem}#jedchecker .list-group-item-action{width:100%;color:#495057;text-align:inherit}#jedchecker .list-group-item-action:focus,#jedchecker .list-group-item-action:hover{z-index:1;color:#495057;text-decoration:none;background-color:#f8f9fa}#jedchecker .list-group-item-action:active{color:#495057;background-color:#e8e8e8}#jedchecker .list-group-item{position:relative;display:block;padding:.5rem 1rem;text-decoration:none;background-color:#fefefe;border:1px solid rgba(0,0,0,.125)}#jedchecker .list-group-item:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}#jedchecker .list-group-item:last-child{border-bottom-right-radius:inherit;border-bottom-left-radius:inherit}#jedchecker .list-group-item:disabled{color:#6c757d;pointer-events:none;background-color:#fefefe}#jedchecker .list-group-item.active{z-index:2;color:#fff;background-color:#2a69b7;border-color:#2a69b7}#jedchecker .list-group-flush{border-radius:0}#jedchecker .list-group-flush>.list-group-item{border-width:0 0 1px}#jedchecker .list-group-flush>.list-group-item:last-child{border-bottom-width:0}#jedchecker .list-group-item-action{color:#0b1c32;background-color:#d0d5dd}#jedchecker .list-group-item-action.list-group-item-action:focus,#jedchecker .list-group-item-action.list-group-item-action:hover{color:#0b1c32;background-color:#bbc0c7}#jedchecker .list-group-item-action.list-group-item-action.active{color:#fff;background-color:#0b1c32;border-color:#0b1c32}#jedchecker .d-flex{display:flex!important}#jedchecker .border-error{border-color:#3b0d0c!important}#jedchecker .justify-content-between{justify-content:space-between!important}#jedchecker .ps-1{padding-left:.25rem!important}#jedchecker .text-center{text-align:center!important}#jedchecker .text-info{color:#2a69b8!important}#jedchecker .text-white{color:#fff!important}#jedchecker .text-muted{color:#6c757d!important}#jedchecker .bg-secondary{background-color:#495057!important}#jedchecker .bg-success{background-color:#2f7d32!important}#jedchecker .bg-info{background-color:#2a69b8!important}#jedchecker .bg-warning{background-color:#ffb514!important}#jedchecker .bg-danger{background-color:#c52827!important}#jedchecker .bg-light{background-color:#f8f9fa!important}#jedchecker .text-nowrap{white-space:nowrap!important}#jedchecker .rounded-pill{border-radius:50rem!important}#jedchecker{display:flex;flex-direction:column;min-height:100%;padding:0;margin:0;text-align:start}#jedchecker h5{font-weight:700}#jedchecker small{font-size:.8rem}#jedchecker .input-group input{min-width:220px}#jedchecker .text-muted{color:#495057!important;opacity:.7}@media (max-width:767.98px){#jedchecker .badge{white-space:normal}}#jedchecker .badge.bg-warning{color:#000;background-color:#f9d71c!important;border:1px solid #4d4d4d}#jedchecker .badge.bg-success{color:#fff;background-color:#2f7d32!important;border:1px solid #fff}#jedchecker .badge.bg-danger{color:#fff;background-color:#900!important;border:1px solid #fff}#jedchecker .badge.bg-info,#jedchecker .badge.bg-secondary{color:#495057;background-color:#dee2e6!important;border:1px solid #949da5}#jedchecker .btn{transition:none}#jedchecker .card{box-shadow:0 2px 4px rgba(0,0,0,.16),0 2px 4px rgba(0,0,0,.23)}#jedchecker .list-group-item{background-color:#fefefe}#jedchecker .alert{margin:1rem 0;border-right:0;border-left:0;border-radius:.2rem}#jedchecker .alert.alert-info{color:#132f53;background-color:#cacaca;border:1px solid #acacac}#jedchecker .alert.alert-warning{color:#495057;background-color:#ffb514;border:1px solid #ffb514}#jedchecker .alert.alert-success{color:#0f2f21;background-color:#e1f5ec;border:1px solid #0f2f21}#jedchecker .form-control{max-width:100%;background-color:#fff;border:solid 1px #c9c9c9;border-radius:.25rem;box-shadow:inset 0 0 0 .1rem #e9e9e9}#jedchecker .form-control:focus{border-color:#39f;box-shadow:0 0 0 .2rem #eaeaea}#jedchecker .form-control:disabled{border:0;box-shadow:none}#jedchecker *{box-sizing:border-box}#jedchecker .hidden{display:none}@media (prefers-reduced-motion:reduce){#jedchecker .accordion-button,#jedchecker .accordion-button::after,#jedchecker .btn,#jedchecker .collapsing,#jedchecker .fade,#jedchecker .form-control,#jedchecker .form-control::-webkit-file-upload-button,#jedchecker .form-control::file-selector-button{-webkit-transition:none;transition:none}#jedchecker *,#jedchecker ::after,#jedchecker ::before{background-attachment:initial!important;transition-delay:0s!important;transition-duration:0s!important;-webkit-animation-duration:1ms!important;animation-duration:1ms!important;-webkit-animation-delay:-1ms!important;animation-delay:-1ms!important;-webkit-animation-iteration-count:1!important;animation-iteration-count:1!important;scroll-behavior:auto!important}} \ No newline at end of file diff --git a/media/com_jedchecker/css/style.css b/media/com_jedchecker/css/style.css index d4e126e..cb5bcf0 100644 --- a/media/com_jedchecker/css/style.css +++ b/media/com_jedchecker/css/style.css @@ -1,64 +1,74 @@ -#adminForm { - background: #FFF; +/* BS5 spinner */ +@-webkit-keyframes spinner-border { + to { + transform: rotate(360deg); + } } -#police-check-result { - padding: 0; +@keyframes spinner-border { + to { + transform: rotate(360deg); + } +} +#jedchecker .spinner-border { + display: inline-block; + width: 2rem; + height: 2rem; + vertical-align: text-bottom; + border: 0.25em solid currentColor; + border-right-color: transparent; + border-radius: 50%; + -webkit-animation: 0.75s linear infinite spinner-border; + animation: 0.75s linear infinite spinner-border; } -#police-check-result>div { - border-top: 1px solid #ccc; - padding: 5px 10px; +#jedchecker .spinner-border-sm { + width: 1rem; + height: 1rem; + border-width: 0.2em; } -#police-check-result .alert { - margin: 5px 0; +#jedchecker .spinner-border.hidden { + display: none; } -.copyright { - line-height: 160%; - margin: 10px; - text-align: center; +/* Style overrides */ +#jedchecker .list-group-item-action.list-group-item-action.active { + color: #fff; + background-color: #132f53 !important; + border-color: #132f53 !important; } -.rule { - font-weight: bold; +#jedchecker .badge { + border: none !important; + padding: 0.3rem 0.45rem !important; +} +#jedchecker .badge.bg-info { + background-color: #2a69b8 !important; + color: #fff; +} +#jedchecker .alert.alert-warning { + color: #664808; + background-color: #fff0d0; + border-color: #ffe9b9; +} +#jedchecker .alert.alert-info { + color: #193f6e; + background-color: #d4e1f1; + border-color: #bfcbd9; +} +#jedchecker .alert pre { + margin-bottom: 0; + white-space: pre; } -small { - font-size: 110%; - padding: 0 0 0 30px; - white-space: nowrap; - +/* fixes for Joomla! 3.x */ +#jedchecker input[type="file"] { + height: auto; } - -#police-check-result li { - margin-bottom: 0.7em; - overflow: hidden; +#jedchecker .fade.show { + opacity: 1; } - -#police-check-result ul li pre { - background: white none repeat scroll 0 0; - border: 1px solid #ccc; - display: block; - margin: 0; - overflow: hidden; - padding: 2px 6px; - text-overflow: ellipsis; - vertical-align: middle; - white-space: nowrap; +#jedchecker .collapse { + height: inherit; } - -.jamss_tooltip { - background-color: blue; - color: white; - border-radius: 20px; -} - -.jamss_tooltip.code { - background-color: #C03020; -} - -.btn { - white-space: normal !important; -} \ No newline at end of file diff --git a/media/com_jedchecker/css/style.min.css b/media/com_jedchecker/css/style.min.css index 1e3d09d..8a0f03a 100644 --- a/media/com_jedchecker/css/style.min.css +++ b/media/com_jedchecker/css/style.min.css @@ -1 +1 @@ -#adminForm{background:#fff}#police-check-result{padding:0}#police-check-result>div{border-top:1px solid #ccc;padding:5px 10px}#police-check-result .alert{margin:5px 0}.copyright{line-height:160%;margin:10px;text-align:center}.rule{font-weight:700}small{font-size:110%;padding:0 0 0 30px;white-space:nowrap}#police-check-result li{margin-bottom:.7em;overflow:hidden}#police-check-result ul li pre{background:#fff none repeat scroll 0 0;border:1px solid #ccc;display:block;margin:0;overflow:hidden;padding:2px 6px;text-overflow:ellipsis;vertical-align:middle;white-space:nowrap}.jamss_tooltip{background-color:#00f;color:#fff;border-radius:20px}.jamss_tooltip.code{background-color:#c03020}.btn{white-space:normal!important} \ No newline at end of file +@-webkit-keyframes spinner-border{to{transform:rotate(360deg)}}@keyframes spinner-border{to{transform:rotate(360deg)}}#jedchecker .spinner-border{display:inline-block;width:2rem;height:2rem;vertical-align:text-bottom;border:.25em solid currentColor;border-right-color:transparent;border-radius:50%;-webkit-animation:.75s linear infinite spinner-border;animation:.75s linear infinite spinner-border}#jedchecker .spinner-border-sm{width:1rem;height:1rem;border-width:.2em}#jedchecker .spinner-border.hidden{display:none}#jedchecker .list-group-item-action.list-group-item-action.active{color:#fff;background-color:#132f53!important;border-color:#132f53!important}#jedchecker .badge{border:none!important;padding:.3rem .45rem!important}#jedchecker .badge.bg-info{background-color:#2a69b8!important;color:#fff}#jedchecker .alert.alert-warning{color:#664808;background-color:#fff0d0;border-color:#ffe9b9}#jedchecker .alert.alert-info{color:#193f6e;background-color:#d4e1f1;border-color:#bfcbd9}#jedchecker .alert pre{margin-bottom:0;white-space:pre}#jedchecker input[type=file]{height:auto}#jedchecker .fade.show{opacity:1}#jedchecker .collapse{height:inherit} \ No newline at end of file From d62f9a38594a8dd17f4583a7a64bd8d4b016194f Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Wed, 24 Feb 2021 14:49:45 +0300 Subject: [PATCH 070/238] load minified css style --- .../components/com_jedchecker/views/uploads/tmpl/default.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php index 14cc5fe..13d678c 100644 --- a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php +++ b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php @@ -36,7 +36,7 @@ else JHtml::script('media/com_jedchecker/js/bootstrap.min.js'); } -JHtml::stylesheet('media/com_jedchecker/css/style.css'); +JHtml::stylesheet('media/com_jedchecker/css/style.min.css'); JHtml::script('media/com_jedchecker/js/script.js'); // List of rules From ddb30892bfd8ae42358257198281b21b99533a15 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 25 Feb 2021 11:36:24 +0300 Subject: [PATCH 071/238] add missed js files --- media/com_jedchecker/js/bootstrap.min.js | 7 ++ media/com_jedchecker/js/script.js | 85 ++++++++++++++++++++++++ 2 files changed, 92 insertions(+) create mode 100644 media/com_jedchecker/js/bootstrap.min.js create mode 100644 media/com_jedchecker/js/script.js diff --git a/media/com_jedchecker/js/bootstrap.min.js b/media/com_jedchecker/js/bootstrap.min.js new file mode 100644 index 0000000..e9aefb9 --- /dev/null +++ b/media/com_jedchecker/js/bootstrap.min.js @@ -0,0 +1,7 @@ +/*! + * Bootstrap v5.0.0-beta2 (https://getbootstrap.com/) + * Copyright 2011-2021 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) + * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) + */ +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("@popperjs/core")):"function"==typeof define&&define.amd?define(["@popperjs/core"],e):(t="undefined"!=typeof globalThis?globalThis:t||self).bootstrap=e(t.Popper)}(this,(function(t){"use strict";function e(t){if(t&&t.__esModule)return t;var e=Object.create(null);return t&&Object.keys(t).forEach((function(n){if("default"!==n){var i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:function(){return t[n]}})}})),e.default=t,Object.freeze(e)}var n=e(t);function i(t,e){for(var n=0;n0,i._pointerEvent=Boolean(window.PointerEvent),i._addEventListeners(),i}r(e,t);var n=e.prototype;return n.next=function(){this._isSliding||this._slide("next")},n.nextWhenVisible=function(){!document.hidden&&v(this._element)&&this.next()},n.prev=function(){this._isSliding||this._slide("prev")},n.pause=function(t){t||(this._isPaused=!0),Q(".carousel-item-next, .carousel-item-prev",this._element)&&(p(this._element),this.cycle(!0)),clearInterval(this._interval),this._interval=null},n.cycle=function(t){t||(this._isPaused=!1),this._interval&&(clearInterval(this._interval),this._interval=null),this._config&&this._config.interval&&!this._isPaused&&(this._updateInterval(),this._interval=setInterval((document.visibilityState?this.nextWhenVisible:this.next).bind(this),this._config.interval))},n.to=function(t){var e=this;this._activeElement=Q(".active.carousel-item",this._element);var n=this._getItemIndex(this._activeElement);if(!(t>this._items.length-1||t<0))if(this._isSliding)K.one(this._element,"slid.bs.carousel",(function(){return e.to(t)}));else{if(n===t)return this.pause(),void this.cycle();var i=t>n?"next":"prev";this._slide(i,this._items[t])}},n.dispose=function(){t.prototype.dispose.call(this),K.off(this._element,".bs.carousel"),this._items=null,this._config=null,this._interval=null,this._isPaused=null,this._isSliding=null,this._activeElement=null,this._indicatorsElement=null},n._getConfig=function(t){return t=s({},G,t),_("carousel",t,Z),t},n._handleSwipe=function(){var t=Math.abs(this.touchDeltaX);if(!(t<=40)){var e=t/this.touchDeltaX;this.touchDeltaX=0,e>0&&(E?this.next():this.prev()),e<0&&(E?this.prev():this.next())}},n._addEventListeners=function(){var t=this;this._config.keyboard&&K.on(this._element,"keydown.bs.carousel",(function(e){return t._keydown(e)})),"hover"===this._config.pause&&(K.on(this._element,"mouseenter.bs.carousel",(function(e){return t.pause(e)})),K.on(this._element,"mouseleave.bs.carousel",(function(e){return t.cycle(e)}))),this._config.touch&&this._touchSupported&&this._addTouchEventListeners()},n._addTouchEventListeners=function(){var t=this,e=function(e){!t._pointerEvent||"pen"!==e.pointerType&&"touch"!==e.pointerType?t._pointerEvent||(t.touchStartX=e.touches[0].clientX):t.touchStartX=e.clientX},n=function(e){!t._pointerEvent||"pen"!==e.pointerType&&"touch"!==e.pointerType||(t.touchDeltaX=e.clientX-t.touchStartX),t._handleSwipe(),"hover"===t._config.pause&&(t.pause(),t.touchTimeout&&clearTimeout(t.touchTimeout),t.touchTimeout=setTimeout((function(e){return t.cycle(e)}),500+t._config.interval))};q(".carousel-item img",this._element).forEach((function(t){K.on(t,"dragstart.bs.carousel",(function(t){return t.preventDefault()}))})),this._pointerEvent?(K.on(this._element,"pointerdown.bs.carousel",(function(t){return e(t)})),K.on(this._element,"pointerup.bs.carousel",(function(t){return n(t)})),this._element.classList.add("pointer-event")):(K.on(this._element,"touchstart.bs.carousel",(function(t){return e(t)})),K.on(this._element,"touchmove.bs.carousel",(function(e){return function(e){e.touches&&e.touches.length>1?t.touchDeltaX=0:t.touchDeltaX=e.touches[0].clientX-t.touchStartX}(e)})),K.on(this._element,"touchend.bs.carousel",(function(t){return n(t)})))},n._keydown=function(t){/input|textarea/i.test(t.target.tagName)||("ArrowLeft"===t.key?(t.preventDefault(),E?this.next():this.prev()):"ArrowRight"===t.key&&(t.preventDefault(),E?this.prev():this.next()))},n._getItemIndex=function(t){return this._items=t&&t.parentNode?q(".carousel-item",t.parentNode):[],this._items.indexOf(t)},n._getItemByDirection=function(t,e){var n="next"===t,i="prev"===t,o=this._getItemIndex(e),s=this._items.length-1;if((i&&0===o||n&&o===s)&&!this._config.wrap)return e;var r=(o+("prev"===t?-1:1))%this._items.length;return-1===r?this._items[this._items.length-1]:this._items[r]},n._triggerSlideEvent=function(t,e){var n=this._getItemIndex(t),i=this._getItemIndex(Q(".active.carousel-item",this._element));return K.trigger(this._element,"slide.bs.carousel",{relatedTarget:t,direction:e,from:i,to:n})},n._setActiveIndicatorElement=function(t){if(this._indicatorsElement){var e=Q(".active",this._indicatorsElement);e.classList.remove("active"),e.removeAttribute("aria-current");for(var n=q("[data-bs-target]",this._indicatorsElement),i=0;i0)for(var i=0;i0&&s--,"ArrowDown"===t.key&&sdocument.documentElement.clientHeight;e||(this._element.style.overflowY="hidden"),this._element.classList.add("modal-static");var n=f(this._dialog);K.off(this._element,"transitionend"),K.one(this._element,"transitionend",(function(){t._element.classList.remove("modal-static"),e||(K.one(t._element,"transitionend",(function(){t._element.style.overflowY=""})),m(t._element,n))})),m(this._element,n),this._element.focus()}},n._adjustDialog=function(){var t=this._element.scrollHeight>document.documentElement.clientHeight;(!this._isBodyOverflowing&&t&&!E||this._isBodyOverflowing&&!t&&E)&&(this._element.style.paddingLeft=this._scrollbarWidth+"px"),(this._isBodyOverflowing&&!t&&!E||!this._isBodyOverflowing&&t&&E)&&(this._element.style.paddingRight=this._scrollbarWidth+"px")},n._resetAdjustments=function(){this._element.style.paddingLeft="",this._element.style.paddingRight=""},n._checkScrollbar=function(){var t=document.body.getBoundingClientRect();this._isBodyOverflowing=Math.round(t.left+t.right)
    ',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:[0,0],container:!1,fallbackPlacements:["top","right","bottom","left"],boundary:"clippingParents",customClass:"",sanitize:!0,sanitizeFn:null,allowList:{"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},popperConfig:null},kt={HIDE:"hide.bs.tooltip",HIDDEN:"hidden.bs.tooltip",SHOW:"show.bs.tooltip",SHOWN:"shown.bs.tooltip",INSERTED:"inserted.bs.tooltip",CLICK:"click.bs.tooltip",FOCUSIN:"focusin.bs.tooltip",FOCUSOUT:"focusout.bs.tooltip",MOUSEENTER:"mouseenter.bs.tooltip",MOUSELEAVE:"mouseleave.bs.tooltip"},Lt=function(e){function i(t,i){var o;if(void 0===n)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");return(o=e.call(this,t)||this)._isEnabled=!0,o._timeout=0,o._hoverState="",o._activeTrigger={},o._popper=null,o.config=o._getConfig(i),o.tip=null,o._setListeners(),o}r(i,e);var a=i.prototype;return a.enable=function(){this._isEnabled=!0},a.disable=function(){this._isEnabled=!1},a.toggleEnabled=function(){this._isEnabled=!this._isEnabled},a.toggle=function(t){if(this._isEnabled)if(t){var e=this._initializeOnDelegatedTarget(t);e._activeTrigger.click=!e._activeTrigger.click,e._isWithActiveTrigger()?e._enter(null,e):e._leave(null,e)}else{if(this.getTipElement().classList.contains("show"))return void this._leave(null,this);this._enter(null,this)}},a.dispose=function(){clearTimeout(this._timeout),K.off(this._element,this.constructor.EVENT_KEY),K.off(this._element.closest(".modal"),"hide.bs.modal",this._hideModalHandler),this.tip&&this.tip.parentNode&&this.tip.parentNode.removeChild(this.tip),this._isEnabled=null,this._timeout=null,this._hoverState=null,this._activeTrigger=null,this._popper&&this._popper.destroy(),this._popper=null,this.config=null,this.tip=null,e.prototype.dispose.call(this)},a.show=function(){var e=this;if("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(this.isWithContent()&&this._isEnabled){var n=K.trigger(this._element,this.constructor.Event.SHOW),i=function t(e){if(!document.documentElement.attachShadow)return null;if("function"==typeof e.getRootNode){var n=e.getRootNode();return n instanceof ShadowRoot?n:null}return e instanceof ShadowRoot?e:e.parentNode?t(e.parentNode):null}(this._element),o=null===i?this._element.ownerDocument.documentElement.contains(this._element):i.contains(this._element);if(!n.defaultPrevented&&o){var s=this.getTipElement(),r=c(this.constructor.NAME);s.setAttribute("id",r),this._element.setAttribute("aria-describedby",r),this.setContent(),this.config.animation&&s.classList.add("fade");var a="function"==typeof this.config.placement?this.config.placement.call(this,s,this._element):this.config.placement,l=this._getAttachment(a);this._addAttachmentClass(l);var u=this._getContainer();k(s,this.constructor.DATA_KEY,this),this._element.ownerDocument.documentElement.contains(this.tip)||u.appendChild(s),K.trigger(this._element,this.constructor.Event.INSERTED),this._popper=t.createPopper(this._element,s,this._getPopperConfig(l)),s.classList.add("show");var h,d,p="function"==typeof this.config.customClass?this.config.customClass():this.config.customClass;p&&(h=s.classList).add.apply(h,p.split(" ")),"ontouchstart"in document.documentElement&&(d=[]).concat.apply(d,document.body.children).forEach((function(t){K.on(t,"mouseover",(function(){}))}));var g=function(){var t=e._hoverState;e._hoverState=null,K.trigger(e._element,e.constructor.Event.SHOWN),"out"===t&&e._leave(null,e)};if(this.tip.classList.contains("fade")){var _=f(this.tip);K.one(this.tip,"transitionend",g),m(this.tip,_)}else g()}}},a.hide=function(){var t=this;if(this._popper){var e=this.getTipElement(),n=function(){"show"!==t._hoverState&&e.parentNode&&e.parentNode.removeChild(e),t._cleanTipClass(),t._element.removeAttribute("aria-describedby"),K.trigger(t._element,t.constructor.Event.HIDDEN),t._popper&&(t._popper.destroy(),t._popper=null)};if(!K.trigger(this._element,this.constructor.Event.HIDE).defaultPrevented){var i;if(e.classList.remove("show"),"ontouchstart"in document.documentElement&&(i=[]).concat.apply(i,document.body.children).forEach((function(t){return K.off(t,"mouseover",b)})),this._activeTrigger.click=!1,this._activeTrigger.focus=!1,this._activeTrigger.hover=!1,this.tip.classList.contains("fade")){var o=f(e);K.one(e,"transitionend",n),m(e,o)}else n();this._hoverState=""}}},a.update=function(){null!==this._popper&&this._popper.update()},a.isWithContent=function(){return Boolean(this.getTitle())},a.getTipElement=function(){if(this.tip)return this.tip;var t=document.createElement("div");return t.innerHTML=this.config.template,this.tip=t.children[0],this.tip},a.setContent=function(){var t=this.getTipElement();this.setElementContent(Q(".tooltip-inner",t),this.getTitle()),t.classList.remove("fade","show")},a.setElementContent=function(t,e){if(null!==t)return"object"==typeof e&&g(e)?(e.jquery&&(e=e[0]),void(this.config.html?e.parentNode!==t&&(t.innerHTML="",t.appendChild(e)):t.textContent=e.textContent)):void(this.config.html?(this.config.sanitize&&(e=bt(e,this.config.allowList,this.config.sanitizeFn)),t.innerHTML=e):t.textContent=e)},a.getTitle=function(){var t=this._element.getAttribute("data-bs-original-title");return t||(t="function"==typeof this.config.title?this.config.title.call(this._element):this.config.title),t},a.updateAttachment=function(t){return"right"===t?"end":"left"===t?"start":t},a._initializeOnDelegatedTarget=function(t,e){var n=this.constructor.DATA_KEY;return(e=e||L(t.delegateTarget,n))||(e=new this.constructor(t.delegateTarget,this._getDelegateConfig()),k(t.delegateTarget,n,e)),e},a._getOffset=function(){var t=this,e=this.config.offset;return"string"==typeof e?e.split(",").map((function(t){return Number.parseInt(t,10)})):"function"==typeof e?function(n){return e(n,t._element)}:e},a._getPopperConfig=function(t){var e=this,n={placement:t,modifiers:[{name:"flip",options:{altBoundary:!0,fallbackPlacements:this.config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this.config.boundary}},{name:"arrow",options:{element:"."+this.constructor.NAME+"-arrow"}},{name:"onChange",enabled:!0,phase:"afterWrite",fn:function(t){return e._handlePopperPlacementChange(t)}}],onFirstUpdate:function(t){t.options.placement!==t.placement&&e._handlePopperPlacementChange(t)}};return s({},n,"function"==typeof this.config.popperConfig?this.config.popperConfig(n):this.config.popperConfig)},a._addAttachmentClass=function(t){this.getTipElement().classList.add("bs-tooltip-"+this.updateAttachment(t))},a._getContainer=function(){return!1===this.config.container?document.body:g(this.config.container)?this.config.container:Q(this.config.container)},a._getAttachment=function(t){return Tt[t.toUpperCase()]},a._setListeners=function(){var t=this;this.config.trigger.split(" ").forEach((function(e){if("click"===e)K.on(t._element,t.constructor.Event.CLICK,t.config.selector,(function(e){return t.toggle(e)}));else if("manual"!==e){var n="hover"===e?t.constructor.Event.MOUSEENTER:t.constructor.Event.FOCUSIN,i="hover"===e?t.constructor.Event.MOUSELEAVE:t.constructor.Event.FOCUSOUT;K.on(t._element,n,t.config.selector,(function(e){return t._enter(e)})),K.on(t._element,i,t.config.selector,(function(e){return t._leave(e)}))}})),this._hideModalHandler=function(){t._element&&t.hide()},K.on(this._element.closest(".modal"),"hide.bs.modal",this._hideModalHandler),this.config.selector?this.config=s({},this.config,{trigger:"manual",selector:""}):this._fixTitle()},a._fixTitle=function(){var t=this._element.getAttribute("title"),e=typeof this._element.getAttribute("data-bs-original-title");(t||"string"!==e)&&(this._element.setAttribute("data-bs-original-title",t||""),!t||this._element.getAttribute("aria-label")||this._element.textContent||this._element.setAttribute("aria-label",t),this._element.setAttribute("title",""))},a._enter=function(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusin"===t.type?"focus":"hover"]=!0),e.getTipElement().classList.contains("show")||"show"===e._hoverState?e._hoverState="show":(clearTimeout(e._timeout),e._hoverState="show",e.config.delay&&e.config.delay.show?e._timeout=setTimeout((function(){"show"===e._hoverState&&e.show()}),e.config.delay.show):e.show())},a._leave=function(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusout"===t.type?"focus":"hover"]=!1),e._isWithActiveTrigger()||(clearTimeout(e._timeout),e._hoverState="out",e.config.delay&&e.config.delay.hide?e._timeout=setTimeout((function(){"out"===e._hoverState&&e.hide()}),e.config.delay.hide):e.hide())},a._isWithActiveTrigger=function(){for(var t in this._activeTrigger)if(this._activeTrigger[t])return!0;return!1},a._getConfig=function(t){var e=X.getDataAttributes(this._element);return Object.keys(e).forEach((function(t){wt.has(t)&&delete e[t]})),t&&"object"==typeof t.container&&t.container.jquery&&(t.container=t.container[0]),"number"==typeof(t=s({},this.constructor.Default,e,"object"==typeof t&&t?t:{})).delay&&(t.delay={show:t.delay,hide:t.delay}),"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),_("tooltip",t,this.constructor.DefaultType),t.sanitize&&(t.template=bt(t.template,t.allowList,t.sanitizeFn)),t},a._getDelegateConfig=function(){var t={};if(this.config)for(var e in this.config)this.constructor.Default[e]!==this.config[e]&&(t[e]=this.config[e]);return t},a._cleanTipClass=function(){var t=this.getTipElement(),e=t.getAttribute("class").match(yt);null!==e&&e.length>0&&e.map((function(t){return t.trim()})).forEach((function(e){return t.classList.remove(e)}))},a._handlePopperPlacementChange=function(t){var e=t.state;e&&(this.tip=e.elements.popper,this._cleanTipClass(),this._addAttachmentClass(this._getAttachment(e.placement)))},i.jQueryInterface=function(t){return this.each((function(){var e=L(this,"bs.tooltip"),n="object"==typeof t&&t;if((e||!/dispose|hide/.test(t))&&(e||(e=new i(this,n)),"string"==typeof t)){if(void 0===e[t])throw new TypeError('No method named "'+t+'"');e[t]()}}))},o(i,null,[{key:"Default",get:function(){return At}},{key:"NAME",get:function(){return"tooltip"}},{key:"DATA_KEY",get:function(){return"bs.tooltip"}},{key:"Event",get:function(){return kt}},{key:"EVENT_KEY",get:function(){return".bs.tooltip"}},{key:"DefaultType",get:function(){return Et}}]),i}(W);T("tooltip",Lt);var Ct=new RegExp("(^|\\s)bs-popover\\S+","g"),Dt=s({},Lt.Default,{placement:"right",offset:[0,8],trigger:"click",content:"",template:''}),St=s({},Lt.DefaultType,{content:"(string|element|function)"}),Nt={HIDE:"hide.bs.popover",HIDDEN:"hidden.bs.popover",SHOW:"show.bs.popover",SHOWN:"shown.bs.popover",INSERTED:"inserted.bs.popover",CLICK:"click.bs.popover",FOCUSIN:"focusin.bs.popover",FOCUSOUT:"focusout.bs.popover",MOUSEENTER:"mouseenter.bs.popover",MOUSELEAVE:"mouseleave.bs.popover"},Ot=function(t){function e(){return t.apply(this,arguments)||this}r(e,t);var n=e.prototype;return n.isWithContent=function(){return this.getTitle()||this._getContent()},n.setContent=function(){var t=this.getTipElement();this.setElementContent(Q(".popover-header",t),this.getTitle());var e=this._getContent();"function"==typeof e&&(e=e.call(this._element)),this.setElementContent(Q(".popover-body",t),e),t.classList.remove("fade","show")},n._addAttachmentClass=function(t){this.getTipElement().classList.add("bs-popover-"+this.updateAttachment(t))},n._getContent=function(){return this._element.getAttribute("data-bs-content")||this.config.content},n._cleanTipClass=function(){var t=this.getTipElement(),e=t.getAttribute("class").match(Ct);null!==e&&e.length>0&&e.map((function(t){return t.trim()})).forEach((function(e){return t.classList.remove(e)}))},e.jQueryInterface=function(t){return this.each((function(){var n=L(this,"bs.popover"),i="object"==typeof t?t:null;if((n||!/dispose|hide/.test(t))&&(n||(n=new e(this,i),k(this,"bs.popover",n)),"string"==typeof t)){if(void 0===n[t])throw new TypeError('No method named "'+t+'"');n[t]()}}))},o(e,null,[{key:"Default",get:function(){return Dt}},{key:"NAME",get:function(){return"popover"}},{key:"DATA_KEY",get:function(){return"bs.popover"}},{key:"Event",get:function(){return Nt}},{key:"EVENT_KEY",get:function(){return".bs.popover"}},{key:"DefaultType",get:function(){return St}}]),e}(Lt);T("popover",Ot);var It={offset:10,method:"auto",target:""},jt={offset:"number",method:"string",target:"(string|element)"},Pt=function(t){function e(e,n){var i;return(i=t.call(this,e)||this)._scrollElement="BODY"===e.tagName?window:e,i._config=i._getConfig(n),i._selector=i._config.target+" .nav-link, "+i._config.target+" .list-group-item, "+i._config.target+" .dropdown-item",i._offsets=[],i._targets=[],i._activeTarget=null,i._scrollHeight=0,K.on(i._scrollElement,"scroll.bs.scrollspy",(function(){return i._process()})),i.refresh(),i._process(),i}r(e,t);var n=e.prototype;return n.refresh=function(){var t=this,e=this._scrollElement===this._scrollElement.window?"offset":"position",n="auto"===this._config.method?e:this._config.method,i="position"===n?this._getScrollTop():0;this._offsets=[],this._targets=[],this._scrollHeight=this._getScrollHeight(),q(this._selector).map((function(t){var e=h(t),o=e?Q(e):null;if(o){var s=o.getBoundingClientRect();if(s.width||s.height)return[X[n](o).top+i,e]}return null})).filter((function(t){return t})).sort((function(t,e){return t[0]-e[0]})).forEach((function(e){t._offsets.push(e[0]),t._targets.push(e[1])}))},n.dispose=function(){t.prototype.dispose.call(this),K.off(this._scrollElement,".bs.scrollspy"),this._scrollElement=null,this._config=null,this._selector=null,this._offsets=null,this._targets=null,this._activeTarget=null,this._scrollHeight=null},n._getConfig=function(t){if("string"!=typeof(t=s({},It,"object"==typeof t&&t?t:{})).target&&g(t.target)){var e=t.target.id;e||(e=c("scrollspy"),t.target.id=e),t.target="#"+e}return _("scrollspy",t,jt),t},n._getScrollTop=function(){return this._scrollElement===window?this._scrollElement.pageYOffset:this._scrollElement.scrollTop},n._getScrollHeight=function(){return this._scrollElement.scrollHeight||Math.max(document.body.scrollHeight,document.documentElement.scrollHeight)},n._getOffsetHeight=function(){return this._scrollElement===window?window.innerHeight:this._scrollElement.getBoundingClientRect().height},n._process=function(){var t=this._getScrollTop()+this._config.offset,e=this._getScrollHeight(),n=this._config.offset+e-this._getOffsetHeight();if(this._scrollHeight!==e&&this.refresh(),t>=n){var i=this._targets[this._targets.length-1];this._activeTarget!==i&&this._activate(i)}else{if(this._activeTarget&&t0)return this._activeTarget=null,void this._clear();for(var o=this._offsets.length;o--;)this._activeTarget!==this._targets[o]&&t>=this._offsets[o]&&(void 0===this._offsets[o+1]||t li > .active":".active";e=(e=q(o,i))[e.length-1]}var s=e?K.trigger(e,"hide.bs.tab",{relatedTarget:this._element}):null;if(!(K.trigger(this._element,"show.bs.tab",{relatedTarget:e}).defaultPrevented||null!==s&&s.defaultPrevented)){this._activate(this._element,i);var r=function(){K.trigger(e,"hidden.bs.tab",{relatedTarget:t._element}),K.trigger(t._element,"shown.bs.tab",{relatedTarget:e})};n?this._activate(n,n.parentNode,r):r()}}},n._activate=function(t,e,n){var i=this,o=(!e||"UL"!==e.nodeName&&"OL"!==e.nodeName?V(e,".active"):q(":scope > li > .active",e))[0],s=n&&o&&o.classList.contains("fade"),r=function(){return i._transitionComplete(t,o,n)};if(o&&s){var a=f(o);o.classList.remove("show"),K.one(o,"transitionend",r),m(o,a)}else r()},n._transitionComplete=function(t,e,n){if(e){e.classList.remove("active");var i=Q(":scope > .dropdown-menu .active",e.parentNode);i&&i.classList.remove("active"),"tab"===e.getAttribute("role")&&e.setAttribute("aria-selected",!1)}t.classList.add("active"),"tab"===t.getAttribute("role")&&t.setAttribute("aria-selected",!0),y(t),t.classList.contains("fade")&&t.classList.add("show"),t.parentNode&&t.parentNode.classList.contains("dropdown-menu")&&(t.closest(".dropdown")&&q(".dropdown-toggle").forEach((function(t){return t.classList.add("active")})),t.setAttribute("aria-expanded",!0)),n&&n()},e.jQueryInterface=function(t){return this.each((function(){var n=L(this,"bs.tab")||new e(this);if("string"==typeof t){if(void 0===n[t])throw new TypeError('No method named "'+t+'"');n[t]()}}))},o(e,null,[{key:"DATA_KEY",get:function(){return"bs.tab"}}]),e}(W);K.on(document,"click.bs.tab.data-api",'[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',(function(t){t.preventDefault(),(L(this,"bs.tab")||new xt(this)).show()})),T("tab",xt);var Ht={animation:"boolean",autohide:"boolean",delay:"number"},Bt={animation:!0,autohide:!0,delay:5e3},Mt=function(t){function e(e,n){var i;return(i=t.call(this,e)||this)._config=i._getConfig(n),i._timeout=null,i._setListeners(),i}r(e,t);var n=e.prototype;return n.show=function(){var t=this;if(!K.trigger(this._element,"show.bs.toast").defaultPrevented){this._clearTimeout(),this._config.animation&&this._element.classList.add("fade");var e=function(){t._element.classList.remove("showing"),t._element.classList.add("show"),K.trigger(t._element,"shown.bs.toast"),t._config.autohide&&(t._timeout=setTimeout((function(){t.hide()}),t._config.delay))};if(this._element.classList.remove("hide"),y(this._element),this._element.classList.add("showing"),this._config.animation){var n=f(this._element);K.one(this._element,"transitionend",e),m(this._element,n)}else e()}},n.hide=function(){var t=this;if(this._element.classList.contains("show")&&!K.trigger(this._element,"hide.bs.toast").defaultPrevented){var e=function(){t._element.classList.add("hide"),K.trigger(t._element,"hidden.bs.toast")};if(this._element.classList.remove("show"),this._config.animation){var n=f(this._element);K.one(this._element,"transitionend",e),m(this._element,n)}else e()}},n.dispose=function(){this._clearTimeout(),this._element.classList.contains("show")&&this._element.classList.remove("show"),K.off(this._element,"click.dismiss.bs.toast"),t.prototype.dispose.call(this),this._config=null},n._getConfig=function(t){return t=s({},Bt,X.getDataAttributes(this._element),"object"==typeof t&&t?t:{}),_("toast",t,this.constructor.DefaultType),t},n._setListeners=function(){var t=this;K.on(this._element,"click.dismiss.bs.toast",'[data-bs-dismiss="toast"]',(function(){return t.hide()}))},n._clearTimeout=function(){clearTimeout(this._timeout),this._timeout=null},e.jQueryInterface=function(t){return this.each((function(){var n=L(this,"bs.toast");if(n||(n=new e(this,"object"==typeof t&&t)),"string"==typeof t){if(void 0===n[t])throw new TypeError('No method named "'+t+'"');n[t](this)}}))},o(e,null,[{key:"DefaultType",get:function(){return Ht}},{key:"Default",get:function(){return Bt}},{key:"DATA_KEY",get:function(){return"bs.toast"}}]),e}(W);return T("toast",Mt),{Alert:U,Button:F,Carousel:J,Collapse:nt,Dropdown:dt,Modal:gt,Popover:Ot,ScrollSpy:Pt,Tab:xt,Toast:Mt,Tooltip:Lt}})); +//# sourceMappingURL=bootstrap.min.js.map \ No newline at end of file diff --git a/media/com_jedchecker/js/script.js b/media/com_jedchecker/js/script.js new file mode 100644 index 0000000..0ea053f --- /dev/null +++ b/media/com_jedchecker/js/script.js @@ -0,0 +1,85 @@ +function add_validation() { + // Fetch all the forms we want to apply custom Bootstrap validation styles to + var forms = document.getElementsByClassName('needs-validation'); + // Loop over them and prevent submission + var validation = Array.prototype.filter.call(forms, function(form) { + form.addEventListener('submit', function(event) { + if (form.checkValidity() === false) { + event.preventDefault(); + event.stopPropagation(); + } + form.classList.add('was-validated'); + }, false); + }); +} + +function check(url, rule) { + jQuery.ajax({ + url: url + 'index.php?option=com_jedchecker&task=police.check&format=raw&rule='+rule, + method: 'GET', + success: function(result){ + var sidebar = jQuery('#jed-' + rule); + var target = jQuery('#police-check-result-' + rule); + + target.html(result); + + var error = target.find('.alert-danger').length; + if (error) { + sidebar.find('.badge.bg-danger').text(error); + } + + var warning = target.find('.alert-warning').length; + if (warning) { + sidebar.find('.badge.bg-warning').text(warning); + } + + var compat = target.find('.alert-secondary').length; + if (compat) { + sidebar.find('.badge.bg-secondary').text(compat); + } + + var info = target.find('.alert-info').length; + if (info) { + sidebar.find('.badge.bg-info').text(info); + } + + if (target.find('.alert-success').length) { + sidebar.find('.badge.bg-success').removeClass("hidden"); + } + + sidebar.find('.spinner-border').addClass('hidden'); + } + }); +} + +var jed_collapse_init = false; +Joomla.submitbutton = function (task) { + if (task == 'check') { + jQuery(".jedchecker-results").removeClass("hidden"); + jQuery('.jedchecker-results .badge:not(.bg-success)').html(''); + jQuery('.jedchecker-results .badge.bg-success').addClass('hidden'); + jQuery('.jedchecker-results .spinner-border').removeClass('hidden'); + jQuery('.police-check-result').html('
    '); + + if (!jed_collapse_init) { + jQuery(".card-header[data-bs-toggle]") + .addClass("accordion-button collapsed") + .each(function () { + var $this = jQuery(this); + $this.attr('href', $this.attr('data-href')); + }); + + new bootstrap.Collapse(document.getElementById('jedchecker-welcome')); + new bootstrap.Collapse(document.getElementById('jedchecker-contributors')); + + jed_collapse_init = true; + } + + for (index = 0; index < jed_options["rules"].length; ++index) { + check(jed_options["url"], jed_options["rules"][index]); + } + + } else { + Joomla.submitform(task); + } +} From b983dcbcfe634d1782e9b90fb3879e6446d277ec Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sat, 27 Feb 2021 10:38:38 +0300 Subject: [PATCH 072/238] use unminified CSS in debug mode --- .../com_jedchecker/views/uploads/tmpl/default.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php index 13d678c..e04a44e 100644 --- a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php +++ b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php @@ -24,6 +24,8 @@ else // Load jQuery JHtml::_('jquery.framework'); +$cssSuffix = JDEBUG ? '.css' : '.min.css'; + // Load Bootstrap if (version_compare(JVERSION, '4.0', '>=')) { @@ -32,11 +34,11 @@ if (version_compare(JVERSION, '4.0', '>=')) } else { - JHtml::stylesheet('media/com_jedchecker/css/j4-style.min.css'); + JHtml::stylesheet('media/com_jedchecker/css/j4-style' . $cssSuffix); JHtml::script('media/com_jedchecker/js/bootstrap.min.js'); } -JHtml::stylesheet('media/com_jedchecker/css/style.min.css'); +JHtml::stylesheet('media/com_jedchecker/css/style' . $cssSuffix); JHtml::script('media/com_jedchecker/js/script.js'); // List of rules From c8b3c59daae21d2b128790522edb47de42a33baf Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 2 Mar 2021 01:21:21 +0300 Subject: [PATCH 073/238] merge similar CSS blocks to reduce file size --- media/com_jedchecker/css/j4-style.css | 24 +++-------------------- media/com_jedchecker/css/j4-style.min.css | 2 +- 2 files changed, 4 insertions(+), 22 deletions(-) diff --git a/media/com_jedchecker/css/j4-style.css b/media/com_jedchecker/css/j4-style.css index 1939488..cec2366 100644 --- a/media/com_jedchecker/css/j4-style.css +++ b/media/com_jedchecker/css/j4-style.css @@ -98,9 +98,7 @@ #jedchecker ::-webkit-search-decoration { -webkit-appearance: none; } -#jedchecker ::file-selector-button { - font: inherit; -} +#jedchecker ::file-selector-button, #jedchecker ::-webkit-file-upload-button { font: inherit; -webkit-appearance: button; @@ -209,24 +207,7 @@ background-color: #e8e8e8; opacity: 1; } -#jedchecker .form-control::file-selector-button { - padding: 0.6rem 1rem; - margin: -0.6rem -1rem; - -webkit-margin-end: 1rem; - margin-inline-end: 1rem; - color: #fff; - background-color: #132f53; - pointer-events: none; - border-color: inherit; - border-style: solid; - border-width: 0; - border-inline-end-width: 1px; - border-radius: 0; - transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; -} -#jedchecker .form-control:hover:not(:disabled):not([readonly])::file-selector-button { - background-color: #122d4f; -} +#jedchecker .form-control::file-selector-button, #jedchecker .form-control::-webkit-file-upload-button { padding: 0.6rem 1rem; margin: -0.6rem -1rem; @@ -243,6 +224,7 @@ -webkit-transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out; } +#jedchecker .form-control:hover:not(:disabled):not([readonly])::file-selector-button, #jedchecker .form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button { background-color: #122d4f; } diff --git a/media/com_jedchecker/css/j4-style.min.css b/media/com_jedchecker/css/j4-style.min.css index 9af0ea1..2aa9c2d 100644 --- a/media/com_jedchecker/css/j4-style.min.css +++ b/media/com_jedchecker/css/j4-style.min.css @@ -1 +1 @@ -@charset "UTF-8";#jedchecker *,#jedchecker ::after,#jedchecker ::before{box-sizing:border-box}#jedchecker{margin:0;font-size:1rem;font-weight:400;line-height:1.5;color:#495057;-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}#jedchecker h5{margin-top:0;margin-bottom:.5rem;font-weight:500;line-height:1.2}#jedchecker h5{font-size:.9286rem}#jedchecker p{margin-top:0;margin-bottom:1rem}#jedchecker ol{padding-left:2rem}#jedchecker ol{margin-top:0;margin-bottom:1rem}#jedchecker strong{font-weight:bolder}#jedchecker small{font-size:.875em}#jedchecker a{color:#2a69b8;text-decoration:underline}#jedchecker a:hover{color:#173a65}#jedchecker a:not([href]):not([class]),#jedchecker a:not([href]):not([class]):hover{color:inherit;text-decoration:none}#jedchecker pre{font-size:1em;direction:ltr;unicode-bidi:bidi-override}#jedchecker pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:.875em}#jedchecker button{border-radius:0}#jedchecker button:focus{outline:dotted 1px;outline:-webkit-focus-ring-color auto 5px}#jedchecker button,#jedchecker input{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}#jedchecker button{text-transform:none}#jedchecker [type=button],#jedchecker button{-webkit-appearance:button}#jedchecker [type=button]:not(:disabled),#jedchecker button:not(:disabled){cursor:pointer}#jedchecker ::-moz-focus-inner{padding:0;border-style:none}#jedchecker ::-webkit-inner-spin-button{height:auto}#jedchecker ::-webkit-search-decoration{-webkit-appearance:none}#jedchecker ::file-selector-button{font:inherit}#jedchecker ::-webkit-file-upload-button{font:inherit;-webkit-appearance:button}#jedchecker .row{--gutter-x:2rem;--gutter-y:0;display:flex;flex-wrap:wrap;margin-top:calc(var(--gutter-y) * -1);margin-right:calc(var(--gutter-x)/ -2);margin-left:calc(var(--gutter-x)/ -2)}#jedchecker .row>*{flex-shrink:0;width:100%;max-width:100%;padding-right:calc(var(--gutter-x)/ 2);padding-left:calc(var(--gutter-x)/ 2);margin-top:var(--gutter-y)}#jedchecker .col-6{flex:0 0 auto;width:50%}#jedchecker .col-12{flex:0 0 auto;width:100%}#jedchecker .g-3{--gutter-x:1rem;--gutter-y:1rem}@media (min-width:768px){#jedchecker .col-md-3{flex:0 0 auto;width:25%}#jedchecker .col-md-4{flex:0 0 auto;width:33.3333333333%}#jedchecker .col-md-8{flex:0 0 auto;width:66.6666666667%}#jedchecker .col-md-9{flex:0 0 auto;width:75%}}#jedchecker .form-control{display:block;width:100%;padding:.6rem 1rem;font-size:1rem;font-weight:400;line-height:1.5;color:#495057;background-color:#fff;background-clip:padding-box;border:1px solid #cdcdcd;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:.25rem;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control[type=file]{overflow:hidden}#jedchecker .form-control[type=file]:not(:disabled):not([readonly]){cursor:pointer}#jedchecker .form-control:focus{color:#495057;background-color:#fff;border-color:#95b4db;outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .form-control::-webkit-date-and-time-value{height:1.5em}#jedchecker .form-control::-webkit-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::-moz-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control:-ms-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::-ms-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::placeholder{color:#6c757d;opacity:1}#jedchecker .form-control:disabled{background-color:#e8e8e8;opacity:1}#jedchecker .form-control::file-selector-button{padding:.6rem 1rem;margin:-.6rem -1rem;-webkit-margin-end:1rem;margin-inline-end:1rem;color:#fff;background-color:#132f53;pointer-events:none;border-color:inherit;border-style:solid;border-width:0;border-inline-end-width:1px;border-radius:0;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control:hover:not(:disabled):not([readonly])::file-selector-button{background-color:#122d4f}#jedchecker .form-control::-webkit-file-upload-button{padding:.6rem 1rem;margin:-.6rem -1rem;-webkit-margin-end:1rem;margin-inline-end:1rem;color:#fff;background-color:#132f53;pointer-events:none;border-color:inherit;border-style:solid;border-width:0;border-inline-end-width:1px;border-radius:0;-webkit-transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button{background-color:#122d4f}#jedchecker .input-group{position:relative;display:flex;flex-wrap:wrap;align-items:stretch;width:100%}#jedchecker .input-group>.form-control{position:relative;flex:1 1 auto;width:1%;min-width:0}#jedchecker .input-group>.form-control:focus{z-index:3}#jedchecker .input-group .btn{position:relative;z-index:2}#jedchecker .input-group .btn:focus{z-index:3}#jedchecker .input-group:not(.has-validation)>:not(:last-child):not(.dropdown-toggle):not(.dropdown-menu){border-top-right-radius:0;border-bottom-right-radius:0}#jedchecker .input-group>:not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback){margin-left:-1px;border-top-left-radius:0;border-bottom-left-radius:0}#jedchecker .invalid-feedback{display:none;width:100%;margin-top:.25rem;font-size:.875em;color:#c52827}#jedchecker .btn{display:inline-block;font-weight:400;line-height:1.5;color:#495057;text-align:center;text-decoration:none;vertical-align:middle;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-color:transparent;border:1px solid transparent;padding:.6rem 1rem;font-size:1rem;border-radius:.25rem;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .btn:hover{color:#495057}#jedchecker .btn:focus{outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .btn:disabled{pointer-events:none;opacity:.4}#jedchecker .btn-success{color:#fff;background-color:#2f7d32;border-color:#2f7d32}#jedchecker .btn-success:hover{color:#fff;background-color:#286a2b;border-color:#266428}#jedchecker .btn-success:focus{color:#fff;background-color:#286a2b;border-color:#266428;box-shadow:0 0 0 .25rem rgba(78,145,81,.5)}#jedchecker .btn-success:active{color:#fff;background-color:#266428;border-color:#235e26}#jedchecker .btn-success:active:focus{box-shadow:0 0 0 .25rem rgba(78,145,81,.5)}#jedchecker .btn-success:disabled{color:#fff;background-color:#2f7d32;border-color:#2f7d32}#jedchecker .btn-light{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}#jedchecker .btn-light:hover{color:#000;background-color:#f9fafb;border-color:#f9fafb}#jedchecker .btn-light:focus{color:#000;background-color:#f9fafb;border-color:#f9fafb;box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}#jedchecker .btn-light:active{color:#000;background-color:#f9fafb;border-color:#f9fafb}#jedchecker .btn-light:active:focus{box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}#jedchecker .btn-light:disabled{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}#jedchecker .fade{transition:opacity .15s linear}#jedchecker .fade:not(.show){opacity:0}#jedchecker .collapse:not(.show){display:none}#jedchecker .collapsing{height:0;overflow:hidden;transition:height .35s ease}#jedchecker .accordion-button{position:relative;display:flex;align-items:center;width:100%;padding:1rem 1.25rem;font-size:1rem;color:#495057;background-color:transparent;border:1px solid rgba(0,0,0,.125);border-radius:0;overflow-anchor:none;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out,border-radius .15s ease}#jedchecker .accordion-button.collapsed{border-bottom-width:0}#jedchecker .accordion-button:not(.collapsed){color:#265fa5;background-color:#eaf0f8}#jedchecker .accordion-button:not(.collapsed)::after{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23265fa5'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");-webkit-transform:rotate(180deg);transform:rotate(180deg)}#jedchecker .accordion-button::after{flex-shrink:0;width:1.25rem;height:1.25rem;margin-left:auto;content:"";background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23495057'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");background-repeat:no-repeat;background-size:1.25rem;transition:-webkit-transform .2s ease-in-out;transition:transform .2s ease-in-out;transition:transform .2s ease-in-out,-webkit-transform .2s ease-in-out}#jedchecker .accordion-button:hover{z-index:2}#jedchecker .accordion-button:focus{z-index:3;border-color:#95b4db;outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .tab-content>.tab-pane{display:none}#jedchecker .tab-content>.active{display:block}#jedchecker .card{position:relative;display:flex;flex-direction:column;min-width:0;word-wrap:break-word;background-color:#fff;background-clip:border-box;border:0 solid transparent;border-radius:.25rem}#jedchecker .card>.list-group{border-top:inherit;border-bottom:inherit}#jedchecker .card>.list-group:first-child{border-top-width:0;border-top-left-radius:.25rem;border-top-right-radius:.25rem}#jedchecker .card>.list-group:last-child{border-bottom-width:0;border-bottom-right-radius:.25rem;border-bottom-left-radius:.25rem}#jedchecker .card>.card-header+.list-group{border-top:0}#jedchecker .card-body{flex:1 1 auto;padding:1rem 1rem}#jedchecker .card-title{margin-bottom:.5rem}#jedchecker .card-text:last-child{margin-bottom:0}#jedchecker .card-header{padding:.5rem 1rem;margin-bottom:0;background-color:rgba(0,0,0,.03);border-bottom:0 solid transparent}#jedchecker .card-header:first-child{border-radius:.25rem .25rem 0 0}#jedchecker .card-footer{padding:.5rem 1rem;background-color:rgba(0,0,0,.03);border-top:0 solid transparent}#jedchecker .card-footer:last-child{border-radius:0 0 .25rem .25rem}#jedchecker .badge{display:inline-block;padding:.3rem .2rem;font-size:.75rem;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.2rem}#jedchecker .badge:empty{display:none}#jedchecker .alert{position:relative;padding:1rem 1rem;margin-bottom:1rem;border:1px solid transparent;border-radius:.25rem}#jedchecker .alert-secondary{color:#2c3034;background-color:#dbdcdd;border-color:#c8cbcd}#jedchecker .alert-success{color:#1c4b1e;background-color:#d5e5d6;border-color:#c1d8c2}#jedchecker .alert-info{color:#193f6e;background-color:#d4e1f1;border-color:#bfd2ea}#jedchecker .alert-warning{color:#664808;background-color:#fff0d0;border-color:#ffe9b9}#jedchecker .alert-danger{color:#761817;background-color:#f3d4d4;border-color:#eebfbe}#jedchecker .list-group{display:flex;flex-direction:column;padding-left:0;margin-bottom:0;border-radius:.25rem}#jedchecker .list-group-item-action{width:100%;color:#495057;text-align:inherit}#jedchecker .list-group-item-action:focus,#jedchecker .list-group-item-action:hover{z-index:1;color:#495057;text-decoration:none;background-color:#f8f9fa}#jedchecker .list-group-item-action:active{color:#495057;background-color:#e8e8e8}#jedchecker .list-group-item{position:relative;display:block;padding:.5rem 1rem;text-decoration:none;background-color:#fefefe;border:1px solid rgba(0,0,0,.125)}#jedchecker .list-group-item:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}#jedchecker .list-group-item:last-child{border-bottom-right-radius:inherit;border-bottom-left-radius:inherit}#jedchecker .list-group-item:disabled{color:#6c757d;pointer-events:none;background-color:#fefefe}#jedchecker .list-group-item.active{z-index:2;color:#fff;background-color:#2a69b7;border-color:#2a69b7}#jedchecker .list-group-flush{border-radius:0}#jedchecker .list-group-flush>.list-group-item{border-width:0 0 1px}#jedchecker .list-group-flush>.list-group-item:last-child{border-bottom-width:0}#jedchecker .list-group-item-action{color:#0b1c32;background-color:#d0d5dd}#jedchecker .list-group-item-action.list-group-item-action:focus,#jedchecker .list-group-item-action.list-group-item-action:hover{color:#0b1c32;background-color:#bbc0c7}#jedchecker .list-group-item-action.list-group-item-action.active{color:#fff;background-color:#0b1c32;border-color:#0b1c32}#jedchecker .d-flex{display:flex!important}#jedchecker .border-error{border-color:#3b0d0c!important}#jedchecker .justify-content-between{justify-content:space-between!important}#jedchecker .ps-1{padding-left:.25rem!important}#jedchecker .text-center{text-align:center!important}#jedchecker .text-info{color:#2a69b8!important}#jedchecker .text-white{color:#fff!important}#jedchecker .text-muted{color:#6c757d!important}#jedchecker .bg-secondary{background-color:#495057!important}#jedchecker .bg-success{background-color:#2f7d32!important}#jedchecker .bg-info{background-color:#2a69b8!important}#jedchecker .bg-warning{background-color:#ffb514!important}#jedchecker .bg-danger{background-color:#c52827!important}#jedchecker .bg-light{background-color:#f8f9fa!important}#jedchecker .text-nowrap{white-space:nowrap!important}#jedchecker .rounded-pill{border-radius:50rem!important}#jedchecker{display:flex;flex-direction:column;min-height:100%;padding:0;margin:0;text-align:start}#jedchecker h5{font-weight:700}#jedchecker small{font-size:.8rem}#jedchecker .input-group input{min-width:220px}#jedchecker .text-muted{color:#495057!important;opacity:.7}@media (max-width:767.98px){#jedchecker .badge{white-space:normal}}#jedchecker .badge.bg-warning{color:#000;background-color:#f9d71c!important;border:1px solid #4d4d4d}#jedchecker .badge.bg-success{color:#fff;background-color:#2f7d32!important;border:1px solid #fff}#jedchecker .badge.bg-danger{color:#fff;background-color:#900!important;border:1px solid #fff}#jedchecker .badge.bg-info,#jedchecker .badge.bg-secondary{color:#495057;background-color:#dee2e6!important;border:1px solid #949da5}#jedchecker .btn{transition:none}#jedchecker .card{box-shadow:0 2px 4px rgba(0,0,0,.16),0 2px 4px rgba(0,0,0,.23)}#jedchecker .list-group-item{background-color:#fefefe}#jedchecker .alert{margin:1rem 0;border-right:0;border-left:0;border-radius:.2rem}#jedchecker .alert.alert-info{color:#132f53;background-color:#cacaca;border:1px solid #acacac}#jedchecker .alert.alert-warning{color:#495057;background-color:#ffb514;border:1px solid #ffb514}#jedchecker .alert.alert-success{color:#0f2f21;background-color:#e1f5ec;border:1px solid #0f2f21}#jedchecker .form-control{max-width:100%;background-color:#fff;border:solid 1px #c9c9c9;border-radius:.25rem;box-shadow:inset 0 0 0 .1rem #e9e9e9}#jedchecker .form-control:focus{border-color:#39f;box-shadow:0 0 0 .2rem #eaeaea}#jedchecker .form-control:disabled{border:0;box-shadow:none}#jedchecker *{box-sizing:border-box}#jedchecker .hidden{display:none}@media (prefers-reduced-motion:reduce){#jedchecker .accordion-button,#jedchecker .accordion-button::after,#jedchecker .btn,#jedchecker .collapsing,#jedchecker .fade,#jedchecker .form-control,#jedchecker .form-control::-webkit-file-upload-button,#jedchecker .form-control::file-selector-button{-webkit-transition:none;transition:none}#jedchecker *,#jedchecker ::after,#jedchecker ::before{background-attachment:initial!important;transition-delay:0s!important;transition-duration:0s!important;-webkit-animation-duration:1ms!important;animation-duration:1ms!important;-webkit-animation-delay:-1ms!important;animation-delay:-1ms!important;-webkit-animation-iteration-count:1!important;animation-iteration-count:1!important;scroll-behavior:auto!important}} \ No newline at end of file +@charset "UTF-8";#jedchecker *,#jedchecker ::after,#jedchecker ::before{box-sizing:border-box}#jedchecker{margin:0;font-size:1rem;font-weight:400;line-height:1.5;color:#495057;-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}#jedchecker h5{margin-top:0;margin-bottom:.5rem;font-weight:500;line-height:1.2}#jedchecker h5{font-size:.9286rem}#jedchecker p{margin-top:0;margin-bottom:1rem}#jedchecker ol{padding-left:2rem}#jedchecker ol{margin-top:0;margin-bottom:1rem}#jedchecker strong{font-weight:bolder}#jedchecker small{font-size:.875em}#jedchecker a{color:#2a69b8;text-decoration:underline}#jedchecker a:hover{color:#173a65}#jedchecker a:not([href]):not([class]),#jedchecker a:not([href]):not([class]):hover{color:inherit;text-decoration:none}#jedchecker pre{font-size:1em;direction:ltr;unicode-bidi:bidi-override}#jedchecker pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:.875em}#jedchecker button{border-radius:0}#jedchecker button:focus{outline:dotted 1px;outline:-webkit-focus-ring-color auto 5px}#jedchecker button,#jedchecker input{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}#jedchecker button{text-transform:none}#jedchecker [type=button],#jedchecker button{-webkit-appearance:button}#jedchecker [type=button]:not(:disabled),#jedchecker button:not(:disabled){cursor:pointer}#jedchecker ::-moz-focus-inner{padding:0;border-style:none}#jedchecker ::-webkit-inner-spin-button{height:auto}#jedchecker ::-webkit-search-decoration{-webkit-appearance:none}#jedchecker ::-webkit-file-upload-button,#jedchecker ::file-selector-button{font:inherit;-webkit-appearance:button}#jedchecker .row{--gutter-x:2rem;--gutter-y:0;display:flex;flex-wrap:wrap;margin-top:calc(var(--gutter-y) * -1);margin-right:calc(var(--gutter-x)/ -2);margin-left:calc(var(--gutter-x)/ -2)}#jedchecker .row>*{flex-shrink:0;width:100%;max-width:100%;padding-right:calc(var(--gutter-x)/ 2);padding-left:calc(var(--gutter-x)/ 2);margin-top:var(--gutter-y)}#jedchecker .col-6{flex:0 0 auto;width:50%}#jedchecker .col-12{flex:0 0 auto;width:100%}#jedchecker .g-3{--gutter-x:1rem;--gutter-y:1rem}@media (min-width:768px){#jedchecker .col-md-3{flex:0 0 auto;width:25%}#jedchecker .col-md-4{flex:0 0 auto;width:33.3333333333%}#jedchecker .col-md-8{flex:0 0 auto;width:66.6666666667%}#jedchecker .col-md-9{flex:0 0 auto;width:75%}}#jedchecker .form-control{display:block;width:100%;padding:.6rem 1rem;font-size:1rem;font-weight:400;line-height:1.5;color:#495057;background-color:#fff;background-clip:padding-box;border:1px solid #cdcdcd;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:.25rem;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control[type=file]{overflow:hidden}#jedchecker .form-control[type=file]:not(:disabled):not([readonly]){cursor:pointer}#jedchecker .form-control:focus{color:#495057;background-color:#fff;border-color:#95b4db;outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .form-control::-webkit-date-and-time-value{height:1.5em}#jedchecker .form-control::-webkit-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::-moz-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control:-ms-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::-ms-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::placeholder{color:#6c757d;opacity:1}#jedchecker .form-control:disabled{background-color:#e8e8e8;opacity:1}#jedchecker .form-control::-webkit-file-upload-button,#jedchecker .form-control::file-selector-button{padding:.6rem 1rem;margin:-.6rem -1rem;-webkit-margin-end:1rem;margin-inline-end:1rem;color:#fff;background-color:#132f53;pointer-events:none;border-color:inherit;border-style:solid;border-width:0;border-inline-end-width:1px;border-radius:0;-webkit-transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button,#jedchecker .form-control:hover:not(:disabled):not([readonly])::file-selector-button{background-color:#122d4f}#jedchecker .input-group{position:relative;display:flex;flex-wrap:wrap;align-items:stretch;width:100%}#jedchecker .input-group>.form-control{position:relative;flex:1 1 auto;width:1%;min-width:0}#jedchecker .input-group>.form-control:focus{z-index:3}#jedchecker .input-group .btn{position:relative;z-index:2}#jedchecker .input-group .btn:focus{z-index:3}#jedchecker .input-group:not(.has-validation)>:not(:last-child):not(.dropdown-toggle):not(.dropdown-menu){border-top-right-radius:0;border-bottom-right-radius:0}#jedchecker .input-group>:not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback){margin-left:-1px;border-top-left-radius:0;border-bottom-left-radius:0}#jedchecker .invalid-feedback{display:none;width:100%;margin-top:.25rem;font-size:.875em;color:#c52827}#jedchecker .btn{display:inline-block;font-weight:400;line-height:1.5;color:#495057;text-align:center;text-decoration:none;vertical-align:middle;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-color:transparent;border:1px solid transparent;padding:.6rem 1rem;font-size:1rem;border-radius:.25rem;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .btn:hover{color:#495057}#jedchecker .btn:focus{outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .btn:disabled{pointer-events:none;opacity:.4}#jedchecker .btn-success{color:#fff;background-color:#2f7d32;border-color:#2f7d32}#jedchecker .btn-success:hover{color:#fff;background-color:#286a2b;border-color:#266428}#jedchecker .btn-success:focus{color:#fff;background-color:#286a2b;border-color:#266428;box-shadow:0 0 0 .25rem rgba(78,145,81,.5)}#jedchecker .btn-success:active{color:#fff;background-color:#266428;border-color:#235e26}#jedchecker .btn-success:active:focus{box-shadow:0 0 0 .25rem rgba(78,145,81,.5)}#jedchecker .btn-success:disabled{color:#fff;background-color:#2f7d32;border-color:#2f7d32}#jedchecker .btn-light{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}#jedchecker .btn-light:hover{color:#000;background-color:#f9fafb;border-color:#f9fafb}#jedchecker .btn-light:focus{color:#000;background-color:#f9fafb;border-color:#f9fafb;box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}#jedchecker .btn-light:active{color:#000;background-color:#f9fafb;border-color:#f9fafb}#jedchecker .btn-light:active:focus{box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}#jedchecker .btn-light:disabled{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}#jedchecker .fade{transition:opacity .15s linear}#jedchecker .fade:not(.show){opacity:0}#jedchecker .collapse:not(.show){display:none}#jedchecker .collapsing{height:0;overflow:hidden;transition:height .35s ease}#jedchecker .accordion-button{position:relative;display:flex;align-items:center;width:100%;padding:1rem 1.25rem;font-size:1rem;color:#495057;background-color:transparent;border:1px solid rgba(0,0,0,.125);border-radius:0;overflow-anchor:none;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out,border-radius .15s ease}#jedchecker .accordion-button.collapsed{border-bottom-width:0}#jedchecker .accordion-button:not(.collapsed){color:#265fa5;background-color:#eaf0f8}#jedchecker .accordion-button:not(.collapsed)::after{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23265fa5'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");-webkit-transform:rotate(180deg);transform:rotate(180deg)}#jedchecker .accordion-button::after{flex-shrink:0;width:1.25rem;height:1.25rem;margin-left:auto;content:"";background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23495057'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");background-repeat:no-repeat;background-size:1.25rem;transition:-webkit-transform .2s ease-in-out;transition:transform .2s ease-in-out;transition:transform .2s ease-in-out,-webkit-transform .2s ease-in-out}#jedchecker .accordion-button:hover{z-index:2}#jedchecker .accordion-button:focus{z-index:3;border-color:#95b4db;outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .tab-content>.tab-pane{display:none}#jedchecker .tab-content>.active{display:block}#jedchecker .card{position:relative;display:flex;flex-direction:column;min-width:0;word-wrap:break-word;background-color:#fff;background-clip:border-box;border:0 solid transparent;border-radius:.25rem}#jedchecker .card>.list-group{border-top:inherit;border-bottom:inherit}#jedchecker .card>.list-group:first-child{border-top-width:0;border-top-left-radius:.25rem;border-top-right-radius:.25rem}#jedchecker .card>.list-group:last-child{border-bottom-width:0;border-bottom-right-radius:.25rem;border-bottom-left-radius:.25rem}#jedchecker .card>.card-header+.list-group{border-top:0}#jedchecker .card-body{flex:1 1 auto;padding:1rem 1rem}#jedchecker .card-title{margin-bottom:.5rem}#jedchecker .card-text:last-child{margin-bottom:0}#jedchecker .card-header{padding:.5rem 1rem;margin-bottom:0;background-color:rgba(0,0,0,.03);border-bottom:0 solid transparent}#jedchecker .card-header:first-child{border-radius:.25rem .25rem 0 0}#jedchecker .card-footer{padding:.5rem 1rem;background-color:rgba(0,0,0,.03);border-top:0 solid transparent}#jedchecker .card-footer:last-child{border-radius:0 0 .25rem .25rem}#jedchecker .badge{display:inline-block;padding:.3rem .2rem;font-size:.75rem;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.2rem}#jedchecker .badge:empty{display:none}#jedchecker .alert{position:relative;padding:1rem 1rem;margin-bottom:1rem;border:1px solid transparent;border-radius:.25rem}#jedchecker .alert-secondary{color:#2c3034;background-color:#dbdcdd;border-color:#c8cbcd}#jedchecker .alert-success{color:#1c4b1e;background-color:#d5e5d6;border-color:#c1d8c2}#jedchecker .alert-info{color:#193f6e;background-color:#d4e1f1;border-color:#bfd2ea}#jedchecker .alert-warning{color:#664808;background-color:#fff0d0;border-color:#ffe9b9}#jedchecker .alert-danger{color:#761817;background-color:#f3d4d4;border-color:#eebfbe}#jedchecker .list-group{display:flex;flex-direction:column;padding-left:0;margin-bottom:0;border-radius:.25rem}#jedchecker .list-group-item-action{width:100%;color:#495057;text-align:inherit}#jedchecker .list-group-item-action:focus,#jedchecker .list-group-item-action:hover{z-index:1;color:#495057;text-decoration:none;background-color:#f8f9fa}#jedchecker .list-group-item-action:active{color:#495057;background-color:#e8e8e8}#jedchecker .list-group-item{position:relative;display:block;padding:.5rem 1rem;text-decoration:none;background-color:#fefefe;border:1px solid rgba(0,0,0,.125)}#jedchecker .list-group-item:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}#jedchecker .list-group-item:last-child{border-bottom-right-radius:inherit;border-bottom-left-radius:inherit}#jedchecker .list-group-item:disabled{color:#6c757d;pointer-events:none;background-color:#fefefe}#jedchecker .list-group-item.active{z-index:2;color:#fff;background-color:#2a69b7;border-color:#2a69b7}#jedchecker .list-group-flush{border-radius:0}#jedchecker .list-group-flush>.list-group-item{border-width:0 0 1px}#jedchecker .list-group-flush>.list-group-item:last-child{border-bottom-width:0}#jedchecker .list-group-item-action{color:#0b1c32;background-color:#d0d5dd}#jedchecker .list-group-item-action.list-group-item-action:focus,#jedchecker .list-group-item-action.list-group-item-action:hover{color:#0b1c32;background-color:#bbc0c7}#jedchecker .list-group-item-action.list-group-item-action.active{color:#fff;background-color:#0b1c32;border-color:#0b1c32}#jedchecker .d-flex{display:flex!important}#jedchecker .border-error{border-color:#3b0d0c!important}#jedchecker .justify-content-between{justify-content:space-between!important}#jedchecker .ps-1{padding-left:.25rem!important}#jedchecker .text-center{text-align:center!important}#jedchecker .text-info{color:#2a69b8!important}#jedchecker .text-white{color:#fff!important}#jedchecker .text-muted{color:#6c757d!important}#jedchecker .bg-secondary{background-color:#495057!important}#jedchecker .bg-success{background-color:#2f7d32!important}#jedchecker .bg-info{background-color:#2a69b8!important}#jedchecker .bg-warning{background-color:#ffb514!important}#jedchecker .bg-danger{background-color:#c52827!important}#jedchecker .bg-light{background-color:#f8f9fa!important}#jedchecker .text-nowrap{white-space:nowrap!important}#jedchecker .rounded-pill{border-radius:50rem!important}#jedchecker{display:flex;flex-direction:column;min-height:100%;padding:0;margin:0;text-align:start}#jedchecker h5{font-weight:700}#jedchecker small{font-size:.8rem}#jedchecker .input-group input{min-width:220px}#jedchecker .text-muted{color:#495057!important;opacity:.7}@media (max-width:767.98px){#jedchecker .badge{white-space:normal}}#jedchecker .badge.bg-warning{color:#000;background-color:#f9d71c!important;border:1px solid #4d4d4d}#jedchecker .badge.bg-success{color:#fff;background-color:#2f7d32!important;border:1px solid #fff}#jedchecker .badge.bg-danger{color:#fff;background-color:#900!important;border:1px solid #fff}#jedchecker .badge.bg-info,#jedchecker .badge.bg-secondary{color:#495057;background-color:#dee2e6!important;border:1px solid #949da5}#jedchecker .btn{transition:none}#jedchecker .card{box-shadow:0 2px 4px rgba(0,0,0,.16),0 2px 4px rgba(0,0,0,.23)}#jedchecker .list-group-item{background-color:#fefefe}#jedchecker .alert{margin:1rem 0;border-right:0;border-left:0;border-radius:.2rem}#jedchecker .alert.alert-info{color:#132f53;background-color:#cacaca;border:1px solid #acacac}#jedchecker .alert.alert-warning{color:#495057;background-color:#ffb514;border:1px solid #ffb514}#jedchecker .alert.alert-success{color:#0f2f21;background-color:#e1f5ec;border:1px solid #0f2f21}#jedchecker .form-control{max-width:100%;background-color:#fff;border:solid 1px #c9c9c9;border-radius:.25rem;box-shadow:inset 0 0 0 .1rem #e9e9e9}#jedchecker .form-control:focus{border-color:#39f;box-shadow:0 0 0 .2rem #eaeaea}#jedchecker .form-control:disabled{border:0;box-shadow:none}#jedchecker *{box-sizing:border-box}#jedchecker .hidden{display:none}@media (prefers-reduced-motion:reduce){#jedchecker .accordion-button,#jedchecker .accordion-button::after,#jedchecker .btn,#jedchecker .collapsing,#jedchecker .fade,#jedchecker .form-control,#jedchecker .form-control::-webkit-file-upload-button,#jedchecker .form-control::file-selector-button{-webkit-transition:none;transition:none}#jedchecker *,#jedchecker ::after,#jedchecker ::before{background-attachment:initial!important;transition-delay:0s!important;transition-duration:0s!important;-webkit-animation-duration:1ms!important;animation-duration:1ms!important;-webkit-animation-delay:-1ms!important;animation-delay:-1ms!important;-webkit-animation-iteration-count:1!important;animation-iteration-count:1!important;scroll-behavior:auto!important}} \ No newline at end of file From e69d2eb2ccd5b5ff8128cb41c3c8f35fcd5b2a86 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sun, 4 Apr 2021 10:59:42 +0300 Subject: [PATCH 074/238] Add support of Bootstrap5 tooltips --- media/com_jedchecker/css/j4-style.css | 87 +++++++++++++++++++ media/com_jedchecker/css/j4-style.min.css | 2 +- media/com_jedchecker/css/style.css | 3 + media/com_jedchecker/css/style.min.css | 2 +- .../com_jedchecker/js/bootstrap.bundle.min.js | 7 ++ media/com_jedchecker/js/bootstrap.min.js | 7 -- media/com_jedchecker/js/script.js | 4 + 7 files changed, 103 insertions(+), 9 deletions(-) create mode 100644 media/com_jedchecker/js/bootstrap.bundle.min.js delete mode 100644 media/com_jedchecker/js/bootstrap.min.js diff --git a/media/com_jedchecker/css/j4-style.css b/media/com_jedchecker/css/j4-style.css index cec2366..ac0bd58 100644 --- a/media/com_jedchecker/css/j4-style.css +++ b/media/com_jedchecker/css/j4-style.css @@ -599,6 +599,73 @@ background-color: #0b1c32; border-color: #0b1c32; } +#jedchecker .tooltip { + position: absolute; + z-index: 1070; + display: block; + margin: 0; + font-style: normal; + font-weight: 400; + line-height: 1.5; + text-align: left; + text-align: start; + text-decoration: none; + text-shadow: none; + text-transform: none; + letter-spacing: normal; + word-break: normal; + word-spacing: normal; + white-space: normal; + line-break: auto; + font-size: 0.8rem; + word-wrap: break-word; + opacity: 0; +} +#jedchecker .tooltip.show { + opacity: 0.9; +} +#jedchecker .tooltip .tooltip-arrow { + position: absolute; + display: block; + width: 0.8rem; + height: 0.4rem; +} +#jedchecker .tooltip .tooltip-arrow::before { + position: absolute; + content: ""; + border-color: transparent; + border-style: solid; +} +#jedchecker .bs-tooltip-top { + padding: 0.4rem 0; +} +#jedchecker .bs-tooltip-top .tooltip-arrow { + bottom: 0; +} +#jedchecker .bs-tooltip-top .tooltip-arrow::before { + top: -1px; + border-width: 0.4rem 0.4rem 0; + border-top-color: #000; +} +#jedchecker .bs-tooltip-bottom { + padding: 0.4rem 0; +} +#jedchecker .bs-tooltip-bottom .tooltip-arrow { + top: 0; +} +#jedchecker .bs-tooltip-bottom .tooltip-arrow::before { + bottom: -1px; + border-width: 0 0.4rem 0.4rem; + border-bottom-color: #000; +} +#jedchecker .tooltip-inner { + max-width: 200px; + padding: 0.25rem 0.5rem; + color: #fff; + text-align: center; + background-color: #000; + border-radius: 0.25rem; +} #jedchecker .d-flex { display: flex !important; } @@ -608,6 +675,15 @@ #jedchecker .justify-content-between { justify-content: space-between !important; } +#jedchecker .mt-3 { + margin-top: 1rem !important; +} +#jedchecker .me-1 { + margin-right: 0.25rem !important; +} +#jedchecker .mb-1 { + margin-bottom: 0.25rem !important; +} #jedchecker .ps-1 { padding-left: 0.25rem !important; } @@ -739,6 +815,17 @@ border: 0; box-shadow: none; } +#jedchecker [role=tooltip]:not(.show) { + z-index: 1070; + display: none; + max-width: 100%; + padding: 0.5em; + margin: 0.25em; + color: #fff; + text-align: start; + background: #000; + border-radius: 0.2rem; +} #jedchecker * { box-sizing: border-box; } diff --git a/media/com_jedchecker/css/j4-style.min.css b/media/com_jedchecker/css/j4-style.min.css index 2aa9c2d..21e15c2 100644 --- a/media/com_jedchecker/css/j4-style.min.css +++ b/media/com_jedchecker/css/j4-style.min.css @@ -1 +1 @@ -@charset "UTF-8";#jedchecker *,#jedchecker ::after,#jedchecker ::before{box-sizing:border-box}#jedchecker{margin:0;font-size:1rem;font-weight:400;line-height:1.5;color:#495057;-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}#jedchecker h5{margin-top:0;margin-bottom:.5rem;font-weight:500;line-height:1.2}#jedchecker h5{font-size:.9286rem}#jedchecker p{margin-top:0;margin-bottom:1rem}#jedchecker ol{padding-left:2rem}#jedchecker ol{margin-top:0;margin-bottom:1rem}#jedchecker strong{font-weight:bolder}#jedchecker small{font-size:.875em}#jedchecker a{color:#2a69b8;text-decoration:underline}#jedchecker a:hover{color:#173a65}#jedchecker a:not([href]):not([class]),#jedchecker a:not([href]):not([class]):hover{color:inherit;text-decoration:none}#jedchecker pre{font-size:1em;direction:ltr;unicode-bidi:bidi-override}#jedchecker pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:.875em}#jedchecker button{border-radius:0}#jedchecker button:focus{outline:dotted 1px;outline:-webkit-focus-ring-color auto 5px}#jedchecker button,#jedchecker input{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}#jedchecker button{text-transform:none}#jedchecker [type=button],#jedchecker button{-webkit-appearance:button}#jedchecker [type=button]:not(:disabled),#jedchecker button:not(:disabled){cursor:pointer}#jedchecker ::-moz-focus-inner{padding:0;border-style:none}#jedchecker ::-webkit-inner-spin-button{height:auto}#jedchecker ::-webkit-search-decoration{-webkit-appearance:none}#jedchecker ::-webkit-file-upload-button,#jedchecker ::file-selector-button{font:inherit;-webkit-appearance:button}#jedchecker .row{--gutter-x:2rem;--gutter-y:0;display:flex;flex-wrap:wrap;margin-top:calc(var(--gutter-y) * -1);margin-right:calc(var(--gutter-x)/ -2);margin-left:calc(var(--gutter-x)/ -2)}#jedchecker .row>*{flex-shrink:0;width:100%;max-width:100%;padding-right:calc(var(--gutter-x)/ 2);padding-left:calc(var(--gutter-x)/ 2);margin-top:var(--gutter-y)}#jedchecker .col-6{flex:0 0 auto;width:50%}#jedchecker .col-12{flex:0 0 auto;width:100%}#jedchecker .g-3{--gutter-x:1rem;--gutter-y:1rem}@media (min-width:768px){#jedchecker .col-md-3{flex:0 0 auto;width:25%}#jedchecker .col-md-4{flex:0 0 auto;width:33.3333333333%}#jedchecker .col-md-8{flex:0 0 auto;width:66.6666666667%}#jedchecker .col-md-9{flex:0 0 auto;width:75%}}#jedchecker .form-control{display:block;width:100%;padding:.6rem 1rem;font-size:1rem;font-weight:400;line-height:1.5;color:#495057;background-color:#fff;background-clip:padding-box;border:1px solid #cdcdcd;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:.25rem;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control[type=file]{overflow:hidden}#jedchecker .form-control[type=file]:not(:disabled):not([readonly]){cursor:pointer}#jedchecker .form-control:focus{color:#495057;background-color:#fff;border-color:#95b4db;outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .form-control::-webkit-date-and-time-value{height:1.5em}#jedchecker .form-control::-webkit-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::-moz-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control:-ms-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::-ms-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::placeholder{color:#6c757d;opacity:1}#jedchecker .form-control:disabled{background-color:#e8e8e8;opacity:1}#jedchecker .form-control::-webkit-file-upload-button,#jedchecker .form-control::file-selector-button{padding:.6rem 1rem;margin:-.6rem -1rem;-webkit-margin-end:1rem;margin-inline-end:1rem;color:#fff;background-color:#132f53;pointer-events:none;border-color:inherit;border-style:solid;border-width:0;border-inline-end-width:1px;border-radius:0;-webkit-transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button,#jedchecker .form-control:hover:not(:disabled):not([readonly])::file-selector-button{background-color:#122d4f}#jedchecker .input-group{position:relative;display:flex;flex-wrap:wrap;align-items:stretch;width:100%}#jedchecker .input-group>.form-control{position:relative;flex:1 1 auto;width:1%;min-width:0}#jedchecker .input-group>.form-control:focus{z-index:3}#jedchecker .input-group .btn{position:relative;z-index:2}#jedchecker .input-group .btn:focus{z-index:3}#jedchecker .input-group:not(.has-validation)>:not(:last-child):not(.dropdown-toggle):not(.dropdown-menu){border-top-right-radius:0;border-bottom-right-radius:0}#jedchecker .input-group>:not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback){margin-left:-1px;border-top-left-radius:0;border-bottom-left-radius:0}#jedchecker .invalid-feedback{display:none;width:100%;margin-top:.25rem;font-size:.875em;color:#c52827}#jedchecker .btn{display:inline-block;font-weight:400;line-height:1.5;color:#495057;text-align:center;text-decoration:none;vertical-align:middle;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-color:transparent;border:1px solid transparent;padding:.6rem 1rem;font-size:1rem;border-radius:.25rem;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .btn:hover{color:#495057}#jedchecker .btn:focus{outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .btn:disabled{pointer-events:none;opacity:.4}#jedchecker .btn-success{color:#fff;background-color:#2f7d32;border-color:#2f7d32}#jedchecker .btn-success:hover{color:#fff;background-color:#286a2b;border-color:#266428}#jedchecker .btn-success:focus{color:#fff;background-color:#286a2b;border-color:#266428;box-shadow:0 0 0 .25rem rgba(78,145,81,.5)}#jedchecker .btn-success:active{color:#fff;background-color:#266428;border-color:#235e26}#jedchecker .btn-success:active:focus{box-shadow:0 0 0 .25rem rgba(78,145,81,.5)}#jedchecker .btn-success:disabled{color:#fff;background-color:#2f7d32;border-color:#2f7d32}#jedchecker .btn-light{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}#jedchecker .btn-light:hover{color:#000;background-color:#f9fafb;border-color:#f9fafb}#jedchecker .btn-light:focus{color:#000;background-color:#f9fafb;border-color:#f9fafb;box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}#jedchecker .btn-light:active{color:#000;background-color:#f9fafb;border-color:#f9fafb}#jedchecker .btn-light:active:focus{box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}#jedchecker .btn-light:disabled{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}#jedchecker .fade{transition:opacity .15s linear}#jedchecker .fade:not(.show){opacity:0}#jedchecker .collapse:not(.show){display:none}#jedchecker .collapsing{height:0;overflow:hidden;transition:height .35s ease}#jedchecker .accordion-button{position:relative;display:flex;align-items:center;width:100%;padding:1rem 1.25rem;font-size:1rem;color:#495057;background-color:transparent;border:1px solid rgba(0,0,0,.125);border-radius:0;overflow-anchor:none;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out,border-radius .15s ease}#jedchecker .accordion-button.collapsed{border-bottom-width:0}#jedchecker .accordion-button:not(.collapsed){color:#265fa5;background-color:#eaf0f8}#jedchecker .accordion-button:not(.collapsed)::after{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23265fa5'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");-webkit-transform:rotate(180deg);transform:rotate(180deg)}#jedchecker .accordion-button::after{flex-shrink:0;width:1.25rem;height:1.25rem;margin-left:auto;content:"";background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23495057'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");background-repeat:no-repeat;background-size:1.25rem;transition:-webkit-transform .2s ease-in-out;transition:transform .2s ease-in-out;transition:transform .2s ease-in-out,-webkit-transform .2s ease-in-out}#jedchecker .accordion-button:hover{z-index:2}#jedchecker .accordion-button:focus{z-index:3;border-color:#95b4db;outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .tab-content>.tab-pane{display:none}#jedchecker .tab-content>.active{display:block}#jedchecker .card{position:relative;display:flex;flex-direction:column;min-width:0;word-wrap:break-word;background-color:#fff;background-clip:border-box;border:0 solid transparent;border-radius:.25rem}#jedchecker .card>.list-group{border-top:inherit;border-bottom:inherit}#jedchecker .card>.list-group:first-child{border-top-width:0;border-top-left-radius:.25rem;border-top-right-radius:.25rem}#jedchecker .card>.list-group:last-child{border-bottom-width:0;border-bottom-right-radius:.25rem;border-bottom-left-radius:.25rem}#jedchecker .card>.card-header+.list-group{border-top:0}#jedchecker .card-body{flex:1 1 auto;padding:1rem 1rem}#jedchecker .card-title{margin-bottom:.5rem}#jedchecker .card-text:last-child{margin-bottom:0}#jedchecker .card-header{padding:.5rem 1rem;margin-bottom:0;background-color:rgba(0,0,0,.03);border-bottom:0 solid transparent}#jedchecker .card-header:first-child{border-radius:.25rem .25rem 0 0}#jedchecker .card-footer{padding:.5rem 1rem;background-color:rgba(0,0,0,.03);border-top:0 solid transparent}#jedchecker .card-footer:last-child{border-radius:0 0 .25rem .25rem}#jedchecker .badge{display:inline-block;padding:.3rem .2rem;font-size:.75rem;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.2rem}#jedchecker .badge:empty{display:none}#jedchecker .alert{position:relative;padding:1rem 1rem;margin-bottom:1rem;border:1px solid transparent;border-radius:.25rem}#jedchecker .alert-secondary{color:#2c3034;background-color:#dbdcdd;border-color:#c8cbcd}#jedchecker .alert-success{color:#1c4b1e;background-color:#d5e5d6;border-color:#c1d8c2}#jedchecker .alert-info{color:#193f6e;background-color:#d4e1f1;border-color:#bfd2ea}#jedchecker .alert-warning{color:#664808;background-color:#fff0d0;border-color:#ffe9b9}#jedchecker .alert-danger{color:#761817;background-color:#f3d4d4;border-color:#eebfbe}#jedchecker .list-group{display:flex;flex-direction:column;padding-left:0;margin-bottom:0;border-radius:.25rem}#jedchecker .list-group-item-action{width:100%;color:#495057;text-align:inherit}#jedchecker .list-group-item-action:focus,#jedchecker .list-group-item-action:hover{z-index:1;color:#495057;text-decoration:none;background-color:#f8f9fa}#jedchecker .list-group-item-action:active{color:#495057;background-color:#e8e8e8}#jedchecker .list-group-item{position:relative;display:block;padding:.5rem 1rem;text-decoration:none;background-color:#fefefe;border:1px solid rgba(0,0,0,.125)}#jedchecker .list-group-item:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}#jedchecker .list-group-item:last-child{border-bottom-right-radius:inherit;border-bottom-left-radius:inherit}#jedchecker .list-group-item:disabled{color:#6c757d;pointer-events:none;background-color:#fefefe}#jedchecker .list-group-item.active{z-index:2;color:#fff;background-color:#2a69b7;border-color:#2a69b7}#jedchecker .list-group-flush{border-radius:0}#jedchecker .list-group-flush>.list-group-item{border-width:0 0 1px}#jedchecker .list-group-flush>.list-group-item:last-child{border-bottom-width:0}#jedchecker .list-group-item-action{color:#0b1c32;background-color:#d0d5dd}#jedchecker .list-group-item-action.list-group-item-action:focus,#jedchecker .list-group-item-action.list-group-item-action:hover{color:#0b1c32;background-color:#bbc0c7}#jedchecker .list-group-item-action.list-group-item-action.active{color:#fff;background-color:#0b1c32;border-color:#0b1c32}#jedchecker .d-flex{display:flex!important}#jedchecker .border-error{border-color:#3b0d0c!important}#jedchecker .justify-content-between{justify-content:space-between!important}#jedchecker .ps-1{padding-left:.25rem!important}#jedchecker .text-center{text-align:center!important}#jedchecker .text-info{color:#2a69b8!important}#jedchecker .text-white{color:#fff!important}#jedchecker .text-muted{color:#6c757d!important}#jedchecker .bg-secondary{background-color:#495057!important}#jedchecker .bg-success{background-color:#2f7d32!important}#jedchecker .bg-info{background-color:#2a69b8!important}#jedchecker .bg-warning{background-color:#ffb514!important}#jedchecker .bg-danger{background-color:#c52827!important}#jedchecker .bg-light{background-color:#f8f9fa!important}#jedchecker .text-nowrap{white-space:nowrap!important}#jedchecker .rounded-pill{border-radius:50rem!important}#jedchecker{display:flex;flex-direction:column;min-height:100%;padding:0;margin:0;text-align:start}#jedchecker h5{font-weight:700}#jedchecker small{font-size:.8rem}#jedchecker .input-group input{min-width:220px}#jedchecker .text-muted{color:#495057!important;opacity:.7}@media (max-width:767.98px){#jedchecker .badge{white-space:normal}}#jedchecker .badge.bg-warning{color:#000;background-color:#f9d71c!important;border:1px solid #4d4d4d}#jedchecker .badge.bg-success{color:#fff;background-color:#2f7d32!important;border:1px solid #fff}#jedchecker .badge.bg-danger{color:#fff;background-color:#900!important;border:1px solid #fff}#jedchecker .badge.bg-info,#jedchecker .badge.bg-secondary{color:#495057;background-color:#dee2e6!important;border:1px solid #949da5}#jedchecker .btn{transition:none}#jedchecker .card{box-shadow:0 2px 4px rgba(0,0,0,.16),0 2px 4px rgba(0,0,0,.23)}#jedchecker .list-group-item{background-color:#fefefe}#jedchecker .alert{margin:1rem 0;border-right:0;border-left:0;border-radius:.2rem}#jedchecker .alert.alert-info{color:#132f53;background-color:#cacaca;border:1px solid #acacac}#jedchecker .alert.alert-warning{color:#495057;background-color:#ffb514;border:1px solid #ffb514}#jedchecker .alert.alert-success{color:#0f2f21;background-color:#e1f5ec;border:1px solid #0f2f21}#jedchecker .form-control{max-width:100%;background-color:#fff;border:solid 1px #c9c9c9;border-radius:.25rem;box-shadow:inset 0 0 0 .1rem #e9e9e9}#jedchecker .form-control:focus{border-color:#39f;box-shadow:0 0 0 .2rem #eaeaea}#jedchecker .form-control:disabled{border:0;box-shadow:none}#jedchecker *{box-sizing:border-box}#jedchecker .hidden{display:none}@media (prefers-reduced-motion:reduce){#jedchecker .accordion-button,#jedchecker .accordion-button::after,#jedchecker .btn,#jedchecker .collapsing,#jedchecker .fade,#jedchecker .form-control,#jedchecker .form-control::-webkit-file-upload-button,#jedchecker .form-control::file-selector-button{-webkit-transition:none;transition:none}#jedchecker *,#jedchecker ::after,#jedchecker ::before{background-attachment:initial!important;transition-delay:0s!important;transition-duration:0s!important;-webkit-animation-duration:1ms!important;animation-duration:1ms!important;-webkit-animation-delay:-1ms!important;animation-delay:-1ms!important;-webkit-animation-iteration-count:1!important;animation-iteration-count:1!important;scroll-behavior:auto!important}} \ No newline at end of file +@charset "UTF-8";#jedchecker *,#jedchecker ::after,#jedchecker ::before{box-sizing:border-box}#jedchecker{margin:0;font-size:1rem;font-weight:400;line-height:1.5;color:#495057;-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}#jedchecker h5{margin-top:0;margin-bottom:.5rem;font-weight:500;line-height:1.2}#jedchecker h5{font-size:.9286rem}#jedchecker p{margin-top:0;margin-bottom:1rem}#jedchecker ol{padding-left:2rem}#jedchecker ol{margin-top:0;margin-bottom:1rem}#jedchecker strong{font-weight:bolder}#jedchecker small{font-size:.875em}#jedchecker a{color:#2a69b8;text-decoration:underline}#jedchecker a:hover{color:#173a65}#jedchecker a:not([href]):not([class]),#jedchecker a:not([href]):not([class]):hover{color:inherit;text-decoration:none}#jedchecker pre{font-size:1em;direction:ltr;unicode-bidi:bidi-override}#jedchecker pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:.875em}#jedchecker button{border-radius:0}#jedchecker button:focus{outline:dotted 1px;outline:-webkit-focus-ring-color auto 5px}#jedchecker button,#jedchecker input{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}#jedchecker button{text-transform:none}#jedchecker [type=button],#jedchecker button{-webkit-appearance:button}#jedchecker [type=button]:not(:disabled),#jedchecker button:not(:disabled){cursor:pointer}#jedchecker ::-moz-focus-inner{padding:0;border-style:none}#jedchecker ::-webkit-inner-spin-button{height:auto}#jedchecker ::-webkit-search-decoration{-webkit-appearance:none}#jedchecker ::-webkit-file-upload-button,#jedchecker ::file-selector-button{font:inherit;-webkit-appearance:button}#jedchecker .row{--gutter-x:2rem;--gutter-y:0;display:flex;flex-wrap:wrap;margin-top:calc(var(--gutter-y) * -1);margin-right:calc(var(--gutter-x)/ -2);margin-left:calc(var(--gutter-x)/ -2)}#jedchecker .row>*{flex-shrink:0;width:100%;max-width:100%;padding-right:calc(var(--gutter-x)/ 2);padding-left:calc(var(--gutter-x)/ 2);margin-top:var(--gutter-y)}#jedchecker .col-6{flex:0 0 auto;width:50%}#jedchecker .col-12{flex:0 0 auto;width:100%}#jedchecker .g-3{--gutter-x:1rem;--gutter-y:1rem}@media (min-width:768px){#jedchecker .col-md-3{flex:0 0 auto;width:25%}#jedchecker .col-md-4{flex:0 0 auto;width:33.3333333333%}#jedchecker .col-md-8{flex:0 0 auto;width:66.6666666667%}#jedchecker .col-md-9{flex:0 0 auto;width:75%}}#jedchecker .form-control{display:block;width:100%;padding:.6rem 1rem;font-size:1rem;font-weight:400;line-height:1.5;color:#495057;background-color:#fff;background-clip:padding-box;border:1px solid #cdcdcd;-webkit-appearance:none;-moz-appearance:none;appearance:none;border-radius:.25rem;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control[type=file]{overflow:hidden}#jedchecker .form-control[type=file]:not(:disabled):not([readonly]){cursor:pointer}#jedchecker .form-control:focus{color:#495057;background-color:#fff;border-color:#95b4db;outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .form-control::-webkit-date-and-time-value{height:1.5em}#jedchecker .form-control::-webkit-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::-moz-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control:-ms-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::-ms-input-placeholder{color:#6c757d;opacity:1}#jedchecker .form-control::placeholder{color:#6c757d;opacity:1}#jedchecker .form-control:disabled{background-color:#e8e8e8;opacity:1}#jedchecker .form-control::-webkit-file-upload-button,#jedchecker .form-control::file-selector-button{padding:.6rem 1rem;margin:-.6rem -1rem;-webkit-margin-end:1rem;margin-inline-end:1rem;color:#fff;background-color:#132f53;pointer-events:none;border-color:inherit;border-style:solid;border-width:0;border-inline-end-width:1px;border-radius:0;-webkit-transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .form-control:hover:not(:disabled):not([readonly])::-webkit-file-upload-button,#jedchecker .form-control:hover:not(:disabled):not([readonly])::file-selector-button{background-color:#122d4f}#jedchecker .input-group{position:relative;display:flex;flex-wrap:wrap;align-items:stretch;width:100%}#jedchecker .input-group>.form-control{position:relative;flex:1 1 auto;width:1%;min-width:0}#jedchecker .input-group>.form-control:focus{z-index:3}#jedchecker .input-group .btn{position:relative;z-index:2}#jedchecker .input-group .btn:focus{z-index:3}#jedchecker .input-group:not(.has-validation)>:not(:last-child):not(.dropdown-toggle):not(.dropdown-menu){border-top-right-radius:0;border-bottom-right-radius:0}#jedchecker .input-group>:not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback){margin-left:-1px;border-top-left-radius:0;border-bottom-left-radius:0}#jedchecker .invalid-feedback{display:none;width:100%;margin-top:.25rem;font-size:.875em;color:#c52827}#jedchecker .btn{display:inline-block;font-weight:400;line-height:1.5;color:#495057;text-align:center;text-decoration:none;vertical-align:middle;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background-color:transparent;border:1px solid transparent;padding:.6rem 1rem;font-size:1rem;border-radius:.25rem;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out}#jedchecker .btn:hover{color:#495057}#jedchecker .btn:focus{outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .btn:disabled{pointer-events:none;opacity:.4}#jedchecker .btn-success{color:#fff;background-color:#2f7d32;border-color:#2f7d32}#jedchecker .btn-success:hover{color:#fff;background-color:#286a2b;border-color:#266428}#jedchecker .btn-success:focus{color:#fff;background-color:#286a2b;border-color:#266428;box-shadow:0 0 0 .25rem rgba(78,145,81,.5)}#jedchecker .btn-success:active{color:#fff;background-color:#266428;border-color:#235e26}#jedchecker .btn-success:active:focus{box-shadow:0 0 0 .25rem rgba(78,145,81,.5)}#jedchecker .btn-success:disabled{color:#fff;background-color:#2f7d32;border-color:#2f7d32}#jedchecker .btn-light{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}#jedchecker .btn-light:hover{color:#000;background-color:#f9fafb;border-color:#f9fafb}#jedchecker .btn-light:focus{color:#000;background-color:#f9fafb;border-color:#f9fafb;box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}#jedchecker .btn-light:active{color:#000;background-color:#f9fafb;border-color:#f9fafb}#jedchecker .btn-light:active:focus{box-shadow:0 0 0 .25rem rgba(211,212,213,.5)}#jedchecker .btn-light:disabled{color:#000;background-color:#f8f9fa;border-color:#f8f9fa}#jedchecker .fade{transition:opacity .15s linear}#jedchecker .fade:not(.show){opacity:0}#jedchecker .collapse:not(.show){display:none}#jedchecker .collapsing{height:0;overflow:hidden;transition:height .35s ease}#jedchecker .accordion-button{position:relative;display:flex;align-items:center;width:100%;padding:1rem 1.25rem;font-size:1rem;color:#495057;background-color:transparent;border:1px solid rgba(0,0,0,.125);border-radius:0;overflow-anchor:none;transition:color .15s ease-in-out,background-color .15s ease-in-out,border-color .15s ease-in-out,box-shadow .15s ease-in-out,border-radius .15s ease}#jedchecker .accordion-button.collapsed{border-bottom-width:0}#jedchecker .accordion-button:not(.collapsed){color:#265fa5;background-color:#eaf0f8}#jedchecker .accordion-button:not(.collapsed)::after{background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23265fa5'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");-webkit-transform:rotate(180deg);transform:rotate(180deg)}#jedchecker .accordion-button::after{flex-shrink:0;width:1.25rem;height:1.25rem;margin-left:auto;content:"";background-image:url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23495057'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");background-repeat:no-repeat;background-size:1.25rem;transition:-webkit-transform .2s ease-in-out;transition:transform .2s ease-in-out;transition:transform .2s ease-in-out,-webkit-transform .2s ease-in-out}#jedchecker .accordion-button:hover{z-index:2}#jedchecker .accordion-button:focus{z-index:3;border-color:#95b4db;outline:0;box-shadow:0 0 0 .25rem rgba(42,105,183,.25)}#jedchecker .tab-content>.tab-pane{display:none}#jedchecker .tab-content>.active{display:block}#jedchecker .card{position:relative;display:flex;flex-direction:column;min-width:0;word-wrap:break-word;background-color:#fff;background-clip:border-box;border:0 solid transparent;border-radius:.25rem}#jedchecker .card>.list-group{border-top:inherit;border-bottom:inherit}#jedchecker .card>.list-group:first-child{border-top-width:0;border-top-left-radius:.25rem;border-top-right-radius:.25rem}#jedchecker .card>.list-group:last-child{border-bottom-width:0;border-bottom-right-radius:.25rem;border-bottom-left-radius:.25rem}#jedchecker .card>.card-header+.list-group{border-top:0}#jedchecker .card-body{flex:1 1 auto;padding:1rem 1rem}#jedchecker .card-title{margin-bottom:.5rem}#jedchecker .card-text:last-child{margin-bottom:0}#jedchecker .card-header{padding:.5rem 1rem;margin-bottom:0;background-color:rgba(0,0,0,.03);border-bottom:0 solid transparent}#jedchecker .card-header:first-child{border-radius:.25rem .25rem 0 0}#jedchecker .card-footer{padding:.5rem 1rem;background-color:rgba(0,0,0,.03);border-top:0 solid transparent}#jedchecker .card-footer:last-child{border-radius:0 0 .25rem .25rem}#jedchecker .badge{display:inline-block;padding:.3rem .2rem;font-size:.75rem;font-weight:700;line-height:1;color:#fff;text-align:center;white-space:nowrap;vertical-align:baseline;border-radius:.2rem}#jedchecker .badge:empty{display:none}#jedchecker .alert{position:relative;padding:1rem 1rem;margin-bottom:1rem;border:1px solid transparent;border-radius:.25rem}#jedchecker .alert-secondary{color:#2c3034;background-color:#dbdcdd;border-color:#c8cbcd}#jedchecker .alert-success{color:#1c4b1e;background-color:#d5e5d6;border-color:#c1d8c2}#jedchecker .alert-info{color:#193f6e;background-color:#d4e1f1;border-color:#bfd2ea}#jedchecker .alert-warning{color:#664808;background-color:#fff0d0;border-color:#ffe9b9}#jedchecker .alert-danger{color:#761817;background-color:#f3d4d4;border-color:#eebfbe}#jedchecker .list-group{display:flex;flex-direction:column;padding-left:0;margin-bottom:0;border-radius:.25rem}#jedchecker .list-group-item-action{width:100%;color:#495057;text-align:inherit}#jedchecker .list-group-item-action:focus,#jedchecker .list-group-item-action:hover{z-index:1;color:#495057;text-decoration:none;background-color:#f8f9fa}#jedchecker .list-group-item-action:active{color:#495057;background-color:#e8e8e8}#jedchecker .list-group-item{position:relative;display:block;padding:.5rem 1rem;text-decoration:none;background-color:#fefefe;border:1px solid rgba(0,0,0,.125)}#jedchecker .list-group-item:first-child{border-top-left-radius:inherit;border-top-right-radius:inherit}#jedchecker .list-group-item:last-child{border-bottom-right-radius:inherit;border-bottom-left-radius:inherit}#jedchecker .list-group-item:disabled{color:#6c757d;pointer-events:none;background-color:#fefefe}#jedchecker .list-group-item.active{z-index:2;color:#fff;background-color:#2a69b7;border-color:#2a69b7}#jedchecker .list-group-flush{border-radius:0}#jedchecker .list-group-flush>.list-group-item{border-width:0 0 1px}#jedchecker .list-group-flush>.list-group-item:last-child{border-bottom-width:0}#jedchecker .list-group-item-action{color:#0b1c32;background-color:#d0d5dd}#jedchecker .list-group-item-action.list-group-item-action:focus,#jedchecker .list-group-item-action.list-group-item-action:hover{color:#0b1c32;background-color:#bbc0c7}#jedchecker .list-group-item-action.list-group-item-action.active{color:#fff;background-color:#0b1c32;border-color:#0b1c32}#jedchecker .tooltip{position:absolute;z-index:1070;display:block;margin:0;font-style:normal;font-weight:400;line-height:1.5;text-align:left;text-align:start;text-decoration:none;text-shadow:none;text-transform:none;letter-spacing:normal;word-break:normal;word-spacing:normal;white-space:normal;line-break:auto;font-size:.8rem;word-wrap:break-word;opacity:0}#jedchecker .tooltip.show{opacity:.9}#jedchecker .tooltip .tooltip-arrow{position:absolute;display:block;width:.8rem;height:.4rem}#jedchecker .tooltip .tooltip-arrow::before{position:absolute;content:"";border-color:transparent;border-style:solid}#jedchecker .bs-tooltip-top{padding:.4rem 0}#jedchecker .bs-tooltip-top .tooltip-arrow{bottom:0}#jedchecker .bs-tooltip-top .tooltip-arrow::before{top:-1px;border-width:.4rem .4rem 0;border-top-color:#000}#jedchecker .bs-tooltip-bottom{padding:.4rem 0}#jedchecker .bs-tooltip-bottom .tooltip-arrow{top:0}#jedchecker .bs-tooltip-bottom .tooltip-arrow::before{bottom:-1px;border-width:0 .4rem .4rem;border-bottom-color:#000}#jedchecker .tooltip-inner{max-width:200px;padding:.25rem .5rem;color:#fff;text-align:center;background-color:#000;border-radius:.25rem}#jedchecker .d-flex{display:flex!important}#jedchecker .border-error{border-color:#3b0d0c!important}#jedchecker .justify-content-between{justify-content:space-between!important}#jedchecker .mt-3{margin-top:1rem!important}#jedchecker .me-1{margin-right:.25rem!important}#jedchecker .mb-1{margin-bottom:.25rem!important}#jedchecker .ps-1{padding-left:.25rem!important}#jedchecker .text-center{text-align:center!important}#jedchecker .text-info{color:#2a69b8!important}#jedchecker .text-white{color:#fff!important}#jedchecker .text-muted{color:#6c757d!important}#jedchecker .bg-secondary{background-color:#495057!important}#jedchecker .bg-success{background-color:#2f7d32!important}#jedchecker .bg-info{background-color:#2a69b8!important}#jedchecker .bg-warning{background-color:#ffb514!important}#jedchecker .bg-danger{background-color:#c52827!important}#jedchecker .bg-light{background-color:#f8f9fa!important}#jedchecker .text-nowrap{white-space:nowrap!important}#jedchecker .rounded-pill{border-radius:50rem!important}#jedchecker{display:flex;flex-direction:column;min-height:100%;padding:0;margin:0;text-align:start}#jedchecker h5{font-weight:700}#jedchecker small{font-size:.8rem}#jedchecker .input-group input{min-width:220px}#jedchecker .text-muted{color:#495057!important;opacity:.7}@media (max-width:767.98px){#jedchecker .badge{white-space:normal}}#jedchecker .badge.bg-warning{color:#000;background-color:#f9d71c!important;border:1px solid #4d4d4d}#jedchecker .badge.bg-success{color:#fff;background-color:#2f7d32!important;border:1px solid #fff}#jedchecker .badge.bg-danger{color:#fff;background-color:#900!important;border:1px solid #fff}#jedchecker .badge.bg-info,#jedchecker .badge.bg-secondary{color:#495057;background-color:#dee2e6!important;border:1px solid #949da5}#jedchecker .btn{transition:none}#jedchecker .card{box-shadow:0 2px 4px rgba(0,0,0,.16),0 2px 4px rgba(0,0,0,.23)}#jedchecker .list-group-item{background-color:#fefefe}#jedchecker .alert{margin:1rem 0;border-right:0;border-left:0;border-radius:.2rem}#jedchecker .alert.alert-info{color:#132f53;background-color:#cacaca;border:1px solid #acacac}#jedchecker .alert.alert-warning{color:#495057;background-color:#ffb514;border:1px solid #ffb514}#jedchecker .alert.alert-success{color:#0f2f21;background-color:#e1f5ec;border:1px solid #0f2f21}#jedchecker .form-control{max-width:100%;background-color:#fff;border:solid 1px #c9c9c9;border-radius:.25rem;box-shadow:inset 0 0 0 .1rem #e9e9e9}#jedchecker .form-control:focus{border-color:#39f;box-shadow:0 0 0 .2rem #eaeaea}#jedchecker .form-control:disabled{border:0;box-shadow:none}#jedchecker [role=tooltip]:not(.show){z-index:1070;display:none;max-width:100%;padding:.5em;margin:.25em;color:#fff;text-align:start;background:#000;border-radius:.2rem}#jedchecker *{box-sizing:border-box}#jedchecker .hidden{display:none}@media (prefers-reduced-motion:reduce){#jedchecker .accordion-button,#jedchecker .accordion-button::after,#jedchecker .btn,#jedchecker .collapsing,#jedchecker .fade,#jedchecker .form-control,#jedchecker .form-control::-webkit-file-upload-button,#jedchecker .form-control::file-selector-button{-webkit-transition:none;transition:none}#jedchecker *,#jedchecker ::after,#jedchecker ::before{background-attachment:initial!important;transition-delay:0s!important;transition-duration:0s!important;-webkit-animation-duration:1ms!important;animation-duration:1ms!important;-webkit-animation-delay:-1ms!important;animation-delay:-1ms!important;-webkit-animation-iteration-count:1!important;animation-iteration-count:1!important;scroll-behavior:auto!important}} \ No newline at end of file diff --git a/media/com_jedchecker/css/style.css b/media/com_jedchecker/css/style.css index cb5bcf0..7500886 100644 --- a/media/com_jedchecker/css/style.css +++ b/media/com_jedchecker/css/style.css @@ -72,3 +72,6 @@ #jedchecker .collapse { height: inherit; } +#jedchecker .tooltip > .tooltip-arrow { + border-style: none; +} diff --git a/media/com_jedchecker/css/style.min.css b/media/com_jedchecker/css/style.min.css index 8a0f03a..3314110 100644 --- a/media/com_jedchecker/css/style.min.css +++ b/media/com_jedchecker/css/style.min.css @@ -1 +1 @@ -@-webkit-keyframes spinner-border{to{transform:rotate(360deg)}}@keyframes spinner-border{to{transform:rotate(360deg)}}#jedchecker .spinner-border{display:inline-block;width:2rem;height:2rem;vertical-align:text-bottom;border:.25em solid currentColor;border-right-color:transparent;border-radius:50%;-webkit-animation:.75s linear infinite spinner-border;animation:.75s linear infinite spinner-border}#jedchecker .spinner-border-sm{width:1rem;height:1rem;border-width:.2em}#jedchecker .spinner-border.hidden{display:none}#jedchecker .list-group-item-action.list-group-item-action.active{color:#fff;background-color:#132f53!important;border-color:#132f53!important}#jedchecker .badge{border:none!important;padding:.3rem .45rem!important}#jedchecker .badge.bg-info{background-color:#2a69b8!important;color:#fff}#jedchecker .alert.alert-warning{color:#664808;background-color:#fff0d0;border-color:#ffe9b9}#jedchecker .alert.alert-info{color:#193f6e;background-color:#d4e1f1;border-color:#bfcbd9}#jedchecker .alert pre{margin-bottom:0;white-space:pre}#jedchecker input[type=file]{height:auto}#jedchecker .fade.show{opacity:1}#jedchecker .collapse{height:inherit} \ No newline at end of file +@-webkit-keyframes spinner-border{to{transform:rotate(360deg)}}@keyframes spinner-border{to{transform:rotate(360deg)}}#jedchecker .spinner-border{display:inline-block;width:2rem;height:2rem;vertical-align:text-bottom;border:.25em solid currentColor;border-right-color:transparent;border-radius:50%;-webkit-animation:.75s linear infinite spinner-border;animation:.75s linear infinite spinner-border}#jedchecker .spinner-border-sm{width:1rem;height:1rem;border-width:.2em}#jedchecker .spinner-border.hidden{display:none}#jedchecker .list-group-item-action.list-group-item-action.active{color:#fff;background-color:#132f53!important;border-color:#132f53!important}#jedchecker .badge{border:none!important;padding:.3rem .45rem!important}#jedchecker .badge.bg-info{background-color:#2a69b8!important;color:#fff}#jedchecker .alert.alert-warning{color:#664808;background-color:#fff0d0;border-color:#ffe9b9}#jedchecker .alert.alert-info{color:#193f6e;background-color:#d4e1f1;border-color:#bfcbd9}#jedchecker .alert pre{margin-bottom:0;white-space:pre}#jedchecker input[type=file]{height:auto}#jedchecker .fade.show{opacity:1}#jedchecker .collapse{height:inherit}#jedchecker .tooltip>.tooltip-arrow{border-style:none} \ No newline at end of file diff --git a/media/com_jedchecker/js/bootstrap.bundle.min.js b/media/com_jedchecker/js/bootstrap.bundle.min.js new file mode 100644 index 0000000..c682e1b --- /dev/null +++ b/media/com_jedchecker/js/bootstrap.bundle.min.js @@ -0,0 +1,7 @@ +/*! + * Bootstrap v5.0.0-beta2 (https://getbootstrap.com/) + * Copyright 2011-2021 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) + * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) + */ +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).bootstrap=e()}(this,(function(){"use strict";function t(t,e){for(var n=0;n0,i._pointerEvent=Boolean(window.PointerEvent),i._addEventListeners(),i}i(o,t);var r=o.prototype;return r.next=function(){this._isSliding||this._slide("next")},r.nextWhenVisible=function(){!document.hidden&&g(this._element)&&this.next()},r.prev=function(){this._isSliding||this._slide("prev")},r.pause=function(t){t||(this._isPaused=!0),Y(".carousel-item-next, .carousel-item-prev",this._element)&&(f(this._element),this.cycle(!0)),clearInterval(this._interval),this._interval=null},r.cycle=function(t){t||(this._isPaused=!1),this._interval&&(clearInterval(this._interval),this._interval=null),this._config&&this._config.interval&&!this._isPaused&&(this._updateInterval(),this._interval=setInterval((document.visibilityState?this.nextWhenVisible:this.next).bind(this),this._config.interval))},r.to=function(t){var e=this;this._activeElement=Y(".active.carousel-item",this._element);var n=this._getItemIndex(this._activeElement);if(!(t>this._items.length-1||t<0))if(this._isSliding)B.one(this._element,"slid.bs.carousel",(function(){return e.to(t)}));else{if(n===t)return this.pause(),void this.cycle();var i=t>n?"next":"prev";this._slide(i,this._items[t])}},r.dispose=function(){t.prototype.dispose.call(this),B.off(this._element,".bs.carousel"),this._items=null,this._config=null,this._interval=null,this._isPaused=null,this._isSliding=null,this._activeElement=null,this._indicatorsElement=null},r._getConfig=function(t){return t=n({},X,t),p("carousel",t,Q),t},r._handleSwipe=function(){var t=Math.abs(this.touchDeltaX);if(!(t<=40)){var e=t/this.touchDeltaX;this.touchDeltaX=0,e>0&&(b?this.next():this.prev()),e<0&&(b?this.prev():this.next())}},r._addEventListeners=function(){var t=this;this._config.keyboard&&B.on(this._element,"keydown.bs.carousel",(function(e){return t._keydown(e)})),"hover"===this._config.pause&&(B.on(this._element,"mouseenter.bs.carousel",(function(e){return t.pause(e)})),B.on(this._element,"mouseleave.bs.carousel",(function(e){return t.cycle(e)}))),this._config.touch&&this._touchSupported&&this._addTouchEventListeners()},r._addTouchEventListeners=function(){var t=this,e=function(e){!t._pointerEvent||"pen"!==e.pointerType&&"touch"!==e.pointerType?t._pointerEvent||(t.touchStartX=e.touches[0].clientX):t.touchStartX=e.clientX},n=function(e){!t._pointerEvent||"pen"!==e.pointerType&&"touch"!==e.pointerType||(t.touchDeltaX=e.clientX-t.touchStartX),t._handleSwipe(),"hover"===t._config.pause&&(t.pause(),t.touchTimeout&&clearTimeout(t.touchTimeout),t.touchTimeout=setTimeout((function(e){return t.cycle(e)}),500+t._config.interval))};F(".carousel-item img",this._element).forEach((function(t){B.on(t,"dragstart.bs.carousel",(function(t){return t.preventDefault()}))})),this._pointerEvent?(B.on(this._element,"pointerdown.bs.carousel",(function(t){return e(t)})),B.on(this._element,"pointerup.bs.carousel",(function(t){return n(t)})),this._element.classList.add("pointer-event")):(B.on(this._element,"touchstart.bs.carousel",(function(t){return e(t)})),B.on(this._element,"touchmove.bs.carousel",(function(e){return function(e){e.touches&&e.touches.length>1?t.touchDeltaX=0:t.touchDeltaX=e.touches[0].clientX-t.touchStartX}(e)})),B.on(this._element,"touchend.bs.carousel",(function(t){return n(t)})))},r._keydown=function(t){/input|textarea/i.test(t.target.tagName)||("ArrowLeft"===t.key?(t.preventDefault(),b?this.next():this.prev()):"ArrowRight"===t.key&&(t.preventDefault(),b?this.prev():this.next()))},r._getItemIndex=function(t){return this._items=t&&t.parentNode?F(".carousel-item",t.parentNode):[],this._items.indexOf(t)},r._getItemByDirection=function(t,e){var n="next"===t,i="prev"===t,o=this._getItemIndex(e),r=this._items.length-1;if((i&&0===o||n&&o===r)&&!this._config.wrap)return e;var s=(o+("prev"===t?-1:1))%this._items.length;return-1===s?this._items[this._items.length-1]:this._items[s]},r._triggerSlideEvent=function(t,e){var n=this._getItemIndex(t),i=this._getItemIndex(Y(".active.carousel-item",this._element));return B.trigger(this._element,"slide.bs.carousel",{relatedTarget:t,direction:e,from:i,to:n})},r._setActiveIndicatorElement=function(t){if(this._indicatorsElement){var e=Y(".active",this._indicatorsElement);e.classList.remove("active"),e.removeAttribute("aria-current");for(var n=F("[data-bs-target]",this._indicatorsElement),i=0;i0)for(var i=0;i=0}function _t(t){return((ut(t)?t.ownerDocument:t.document)||window.document).documentElement}function bt(t){return"html"===lt(t)?t:t.assignedSlot||t.parentNode||t.host||_t(t)}function yt(t){if(!ft(t)||"fixed"===mt(t).position)return null;var e=t.offsetParent;if(e){var n=_t(e);if("body"===lt(e)&&"static"===mt(e).position&&"static"!==mt(n).position)return n}return e}function wt(t){for(var e=ct(t),n=yt(t);n&&vt(n)&&"static"===mt(n).position;)n=yt(n);return n&&"body"===lt(n)&&"static"===mt(n).position?e:n||function(t){for(var e=bt(t);ft(e)&&["html","body"].indexOf(lt(e))<0;){var n=mt(e);if("none"!==n.transform||"none"!==n.perspective||n.willChange&&"auto"!==n.willChange)return e;e=e.parentNode}return null}(t)||e}function Et(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function Tt(t,e,n){return Math.max(t,Math.min(e,n))}function kt(t){return Object.assign(Object.assign({},{top:0,right:0,bottom:0,left:0}),t)}function At(t,e){return e.reduce((function(e,n){return e[n]=t,e}),{})}var Lt={name:"arrow",enabled:!0,phase:"main",fn:function(t){var e,n=t.state,i=t.name,o=n.elements.arrow,r=n.modifiersData.popperOffsets,s=ht(n.placement),a=Et(s),l=[it,nt].indexOf(s)>=0?"height":"width";if(o&&r){var c=n.modifiersData[i+"#persistent"].padding,u=pt(o),f="y"===a?tt:it,d="y"===a?et:nt,h=n.rects.reference[l]+n.rects.reference[a]-r[a]-n.rects.popper[l],p=r[a]-n.rects.reference[a],g=wt(o),m=g?"y"===a?g.clientHeight||0:g.clientWidth||0:0,v=h/2-p/2,_=c[f],b=m-u[l]-c[d],y=m/2-u[l]/2+v,w=Tt(_,y,b),E=a;n.modifiersData[i]=((e={})[E]=w,e.centerOffset=w-y,e)}},effect:function(t){var e=t.state,n=t.options,i=t.name,o=n.element,r=void 0===o?"[data-popper-arrow]":o,s=n.padding,a=void 0===s?0:s;null!=r&&("string"!=typeof r||(r=e.elements.popper.querySelector(r)))&>(e.elements.popper,r)&&(e.elements.arrow=r,e.modifiersData[i+"#persistent"]={padding:kt("number"!=typeof a?a:At(a,ot))})},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]},Ot={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Dt(t){var e,n=t.popper,i=t.popperRect,o=t.placement,r=t.offsets,s=t.position,a=t.gpuAcceleration,l=t.adaptive,c=t.roundOffsets?function(t){var e=t.x,n=t.y,i=window.devicePixelRatio||1;return{x:Math.round(e*i)/i||0,y:Math.round(n*i)/i||0}}(r):r,u=c.x,f=void 0===u?0:u,d=c.y,h=void 0===d?0:d,p=r.hasOwnProperty("x"),g=r.hasOwnProperty("y"),m=it,v=tt,_=window;if(l){var b=wt(n);b===ct(n)&&(b=_t(n)),o===tt&&(v=et,h-=b.clientHeight-i.height,h*=a?1:-1),o===it&&(m=nt,f-=b.clientWidth-i.width,f*=a?1:-1)}var y,w=Object.assign({position:s},l&&Ot);return a?Object.assign(Object.assign({},w),{},((y={})[v]=g?"0":"",y[m]=p?"0":"",y.transform=(_.devicePixelRatio||1)<2?"translate("+f+"px, "+h+"px)":"translate3d("+f+"px, "+h+"px, 0)",y)):Object.assign(Object.assign({},w),{},((e={})[v]=g?h+"px":"",e[m]=p?f+"px":"",e.transform="",e))}var xt={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(t){var e=t.state,n=t.options,i=n.gpuAcceleration,o=void 0===i||i,r=n.adaptive,s=void 0===r||r,a=n.roundOffsets,l=void 0===a||a,c={placement:ht(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:o};null!=e.modifiersData.popperOffsets&&(e.styles.popper=Object.assign(Object.assign({},e.styles.popper),Dt(Object.assign(Object.assign({},c),{},{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:s,roundOffsets:l})))),null!=e.modifiersData.arrow&&(e.styles.arrow=Object.assign(Object.assign({},e.styles.arrow),Dt(Object.assign(Object.assign({},c),{},{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),e.attributes.popper=Object.assign(Object.assign({},e.attributes.popper),{},{"data-popper-placement":e.placement})},data:{}},Ct={passive:!0},St={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(t){var e=t.state,n=t.instance,i=t.options,o=i.scroll,r=void 0===o||o,s=i.resize,a=void 0===s||s,l=ct(e.elements.popper),c=[].concat(e.scrollParents.reference,e.scrollParents.popper);return r&&c.forEach((function(t){t.addEventListener("scroll",n.update,Ct)})),a&&l.addEventListener("resize",n.update,Ct),function(){r&&c.forEach((function(t){t.removeEventListener("scroll",n.update,Ct)})),a&&l.removeEventListener("resize",n.update,Ct)}},data:{}},jt={left:"right",right:"left",bottom:"top",top:"bottom"};function Nt(t){return t.replace(/left|right|bottom|top/g,(function(t){return jt[t]}))}var Pt={start:"end",end:"start"};function It(t){return t.replace(/start|end/g,(function(t){return Pt[t]}))}function Mt(t){var e=t.getBoundingClientRect();return{width:e.width,height:e.height,top:e.top,right:e.right,bottom:e.bottom,left:e.left,x:e.left,y:e.top}}function Bt(t){var e=ct(t);return{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function Ht(t){return Mt(_t(t)).left+Bt(t).scrollLeft}function Rt(t){var e=mt(t),n=e.overflow,i=e.overflowX,o=e.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+i)}function Wt(t,e){void 0===e&&(e=[]);var n=function t(e){return["html","body","#document"].indexOf(lt(e))>=0?e.ownerDocument.body:ft(e)&&Rt(e)?e:t(bt(e))}(t),i="body"===lt(n),o=ct(n),r=i?[o].concat(o.visualViewport||[],Rt(n)?n:[]):n,s=e.concat(r);return i?s:s.concat(Wt(bt(r)))}function Kt(t){return Object.assign(Object.assign({},t),{},{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function Ut(t,e){return"viewport"===e?Kt(function(t){var e=ct(t),n=_t(t),i=e.visualViewport,o=n.clientWidth,r=n.clientHeight,s=0,a=0;return i&&(o=i.width,r=i.height,/^((?!chrome|android).)*safari/i.test(navigator.userAgent)||(s=i.offsetLeft,a=i.offsetTop)),{width:o,height:r,x:s+Ht(t),y:a}}(t)):ft(e)?function(t){var e=Mt(t);return e.top=e.top+t.clientTop,e.left=e.left+t.clientLeft,e.bottom=e.top+t.clientHeight,e.right=e.left+t.clientWidth,e.width=t.clientWidth,e.height=t.clientHeight,e.x=e.left,e.y=e.top,e}(e):Kt(function(t){var e=_t(t),n=Bt(t),i=t.ownerDocument.body,o=Math.max(e.scrollWidth,e.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),r=Math.max(e.scrollHeight,e.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),s=-n.scrollLeft+Ht(t),a=-n.scrollTop;return"rtl"===mt(i||e).direction&&(s+=Math.max(e.clientWidth,i?i.clientWidth:0)-o),{width:o,height:r,x:s,y:a}}(_t(t)))}function zt(t){return t.split("-")[1]}function Ft(t){var e,n=t.reference,i=t.element,o=t.placement,r=o?ht(o):null,s=o?zt(o):null,a=n.x+n.width/2-i.width/2,l=n.y+n.height/2-i.height/2;switch(r){case tt:e={x:a,y:n.y-i.height};break;case et:e={x:a,y:n.y+n.height};break;case nt:e={x:n.x+n.width,y:l};break;case it:e={x:n.x-i.width,y:l};break;default:e={x:n.x,y:n.y}}var c=r?Et(r):null;if(null!=c){var u="y"===c?"height":"width";switch(s){case"start":e[c]=e[c]-(n[u]/2-i[u]/2);break;case"end":e[c]=e[c]+(n[u]/2-i[u]/2)}}return e}function Yt(t,e){void 0===e&&(e={});var n=e,i=n.placement,o=void 0===i?t.placement:i,r=n.boundary,s=void 0===r?"clippingParents":r,a=n.rootBoundary,l=void 0===a?"viewport":a,c=n.elementContext,u=void 0===c?"popper":c,f=n.altBoundary,d=void 0!==f&&f,h=n.padding,p=void 0===h?0:h,g=kt("number"!=typeof p?p:At(p,ot)),m="popper"===u?"reference":"popper",v=t.elements.reference,_=t.rects.popper,b=t.elements[d?m:u],y=function(t,e,n){var i="clippingParents"===e?function(t){var e=Wt(bt(t)),n=["absolute","fixed"].indexOf(mt(t).position)>=0&&ft(t)?wt(t):t;return ut(n)?e.filter((function(t){return ut(t)&>(t,n)&&"body"!==lt(t)})):[]}(t):[].concat(e),o=[].concat(i,[n]),r=o[0],s=o.reduce((function(e,n){var i=Ut(t,n);return e.top=Math.max(i.top,e.top),e.right=Math.min(i.right,e.right),e.bottom=Math.min(i.bottom,e.bottom),e.left=Math.max(i.left,e.left),e}),Ut(t,r));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}(ut(b)?b:b.contextElement||_t(t.elements.popper),s,l),w=Mt(v),E=Ft({reference:w,element:_,strategy:"absolute",placement:o}),T=Kt(Object.assign(Object.assign({},_),E)),k="popper"===u?T:w,A={top:y.top-k.top+g.top,bottom:k.bottom-y.bottom+g.bottom,left:y.left-k.left+g.left,right:k.right-y.right+g.right},L=t.modifiersData.offset;if("popper"===u&&L){var O=L[o];Object.keys(A).forEach((function(t){var e=[nt,et].indexOf(t)>=0?1:-1,n=[tt,et].indexOf(t)>=0?"y":"x";A[t]+=O[n]*e}))}return A}function qt(t,e){void 0===e&&(e={});var n=e,i=n.placement,o=n.boundary,r=n.rootBoundary,s=n.padding,a=n.flipVariations,l=n.allowedAutoPlacements,c=void 0===l?st:l,u=zt(i),f=u?a?rt:rt.filter((function(t){return zt(t)===u})):ot,d=f.filter((function(t){return c.indexOf(t)>=0}));0===d.length&&(d=f);var h=d.reduce((function(e,n){return e[n]=Yt(t,{placement:n,boundary:o,rootBoundary:r,padding:s})[ht(n)],e}),{});return Object.keys(h).sort((function(t,e){return h[t]-h[e]}))}var Vt={name:"flip",enabled:!0,phase:"main",fn:function(t){var e=t.state,n=t.options,i=t.name;if(!e.modifiersData[i]._skip){for(var o=n.mainAxis,r=void 0===o||o,s=n.altAxis,a=void 0===s||s,l=n.fallbackPlacements,c=n.padding,u=n.boundary,f=n.rootBoundary,d=n.altBoundary,h=n.flipVariations,p=void 0===h||h,g=n.allowedAutoPlacements,m=e.options.placement,v=ht(m),_=l||(v!==m&&p?function(t){if("auto"===ht(t))return[];var e=Nt(t);return[It(t),e,It(e)]}(m):[Nt(m)]),b=[m].concat(_).reduce((function(t,n){return t.concat("auto"===ht(n)?qt(e,{placement:n,boundary:u,rootBoundary:f,padding:c,flipVariations:p,allowedAutoPlacements:g}):n)}),[]),y=e.rects.reference,w=e.rects.popper,E=new Map,T=!0,k=b[0],A=0;A=0,C=x?"width":"height",S=Yt(e,{placement:L,boundary:u,rootBoundary:f,altBoundary:d,padding:c}),j=x?D?nt:it:D?et:tt;y[C]>w[C]&&(j=Nt(j));var N=Nt(j),P=[];if(r&&P.push(S[O]<=0),a&&P.push(S[j]<=0,S[N]<=0),P.every((function(t){return t}))){k=L,T=!1;break}E.set(L,P)}if(T)for(var I=function(t){var e=b.find((function(e){var n=E.get(e);if(n)return n.slice(0,t).every((function(t){return t}))}));if(e)return k=e,"break"},M=p?3:1;M>0&&"break"!==I(M);M--);e.placement!==k&&(e.modifiersData[i]._skip=!0,e.placement=k,e.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function Xt(t,e,n){return void 0===n&&(n={x:0,y:0}),{top:t.top-e.height-n.y,right:t.right-e.width+n.x,bottom:t.bottom-e.height+n.y,left:t.left-e.width-n.x}}function Qt(t){return[tt,nt,et,it].some((function(e){return t[e]>=0}))}var $t={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(t){var e=t.state,n=t.name,i=e.rects.reference,o=e.rects.popper,r=e.modifiersData.preventOverflow,s=Yt(e,{elementContext:"reference"}),a=Yt(e,{altBoundary:!0}),l=Xt(s,i),c=Xt(a,o,r),u=Qt(l),f=Qt(c);e.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:u,hasPopperEscaped:f},e.attributes.popper=Object.assign(Object.assign({},e.attributes.popper),{},{"data-popper-reference-hidden":u,"data-popper-escaped":f})}},Gt={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(t){var e=t.state,n=t.options,i=t.name,o=n.offset,r=void 0===o?[0,0]:o,s=st.reduce((function(t,n){return t[n]=function(t,e,n){var i=ht(t),o=[it,tt].indexOf(i)>=0?-1:1,r="function"==typeof n?n(Object.assign(Object.assign({},e),{},{placement:t})):n,s=r[0],a=r[1];return s=s||0,a=(a||0)*o,[it,nt].indexOf(i)>=0?{x:a,y:s}:{x:s,y:a}}(n,e.rects,r),t}),{}),a=s[e.placement],l=a.x,c=a.y;null!=e.modifiersData.popperOffsets&&(e.modifiersData.popperOffsets.x+=l,e.modifiersData.popperOffsets.y+=c),e.modifiersData[i]=s}},Zt={name:"popperOffsets",enabled:!0,phase:"read",fn:function(t){var e=t.state,n=t.name;e.modifiersData[n]=Ft({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement})},data:{}},Jt={name:"preventOverflow",enabled:!0,phase:"main",fn:function(t){var e=t.state,n=t.options,i=t.name,o=n.mainAxis,r=void 0===o||o,s=n.altAxis,a=void 0!==s&&s,l=n.boundary,c=n.rootBoundary,u=n.altBoundary,f=n.padding,d=n.tether,h=void 0===d||d,p=n.tetherOffset,g=void 0===p?0:p,m=Yt(e,{boundary:l,rootBoundary:c,padding:f,altBoundary:u}),v=ht(e.placement),_=zt(e.placement),b=!_,y=Et(v),w="x"===y?"y":"x",E=e.modifiersData.popperOffsets,T=e.rects.reference,k=e.rects.popper,A="function"==typeof g?g(Object.assign(Object.assign({},e.rects),{},{placement:e.placement})):g,L={x:0,y:0};if(E){if(r){var O="y"===y?tt:it,D="y"===y?et:nt,x="y"===y?"height":"width",C=E[y],S=E[y]+m[O],j=E[y]-m[D],N=h?-k[x]/2:0,P="start"===_?T[x]:k[x],I="start"===_?-k[x]:-T[x],M=e.elements.arrow,B=h&&M?pt(M):{width:0,height:0},H=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},R=H[O],W=H[D],K=Tt(0,T[x],B[x]),U=b?T[x]/2-N-K-R-A:P-K-R-A,z=b?-T[x]/2+N+K+W+A:I+K+W+A,F=e.elements.arrow&&wt(e.elements.arrow),Y=F?"y"===y?F.clientTop||0:F.clientLeft||0:0,q=e.modifiersData.offset?e.modifiersData.offset[e.placement][y]:0,V=E[y]+U-q-Y,X=E[y]+z-q,Q=Tt(h?Math.min(S,V):S,C,h?Math.max(j,X):j);E[y]=Q,L[y]=Q-C}if(a){var $="x"===y?tt:it,G="x"===y?et:nt,Z=E[w],J=Tt(Z+m[$],Z,Z-m[G]);E[w]=J,L[w]=J-Z}e.modifiersData[i]=L}},requiresIfExists:["offset"]};function te(t,e,n){void 0===n&&(n=!1);var i,o,r=_t(e),s=Mt(t),a=ft(e),l={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(a||!a&&!n)&&(("body"!==lt(e)||Rt(r))&&(l=(i=e)!==ct(i)&&ft(i)?{scrollLeft:(o=i).scrollLeft,scrollTop:o.scrollTop}:Bt(i)),ft(e)?((c=Mt(e)).x+=e.clientLeft,c.y+=e.clientTop):r&&(c.x=Ht(r))),{x:s.left+l.scrollLeft-c.x,y:s.top+l.scrollTop-c.y,width:s.width,height:s.height}}var ee={placement:"bottom",modifiers:[],strategy:"absolute"};function ne(){for(var t=arguments.length,e=new Array(t),n=0;n0&&r--,"ArrowDown"===t.key&&rdocument.documentElement.clientHeight;e||(this._element.style.overflowY="hidden"),this._element.classList.add("modal-static");var n=u(this._dialog);B.off(this._element,"transitionend"),B.one(this._element,"transitionend",(function(){t._element.classList.remove("modal-static"),e||(B.one(t._element,"transitionend",(function(){t._element.style.overflowY=""})),h(t._element,n))})),h(this._element,n),this._element.focus()}},r._adjustDialog=function(){var t=this._element.scrollHeight>document.documentElement.clientHeight;(!this._isBodyOverflowing&&t&&!b||this._isBodyOverflowing&&!t&&b)&&(this._element.style.paddingLeft=this._scrollbarWidth+"px"),(this._isBodyOverflowing&&!t&&!b||!this._isBodyOverflowing&&t&&b)&&(this._element.style.paddingRight=this._scrollbarWidth+"px")},r._resetAdjustments=function(){this._element.style.paddingLeft="",this._element.style.paddingRight=""},r._checkScrollbar=function(){var t=document.body.getBoundingClientRect();this._isBodyOverflowing=Math.round(t.left+t.right)
    ',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:[0,0],container:!1,fallbackPlacements:["top","right","bottom","left"],boundary:"clippingParents",customClass:"",sanitize:!0,sanitizeFn:null,allowList:{"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},popperConfig:null},Ce={HIDE:"hide.bs.tooltip",HIDDEN:"hidden.bs.tooltip",SHOW:"show.bs.tooltip",SHOWN:"shown.bs.tooltip",INSERTED:"inserted.bs.tooltip",CLICK:"click.bs.tooltip",FOCUSIN:"focusin.bs.tooltip",FOCUSOUT:"focusout.bs.tooltip",MOUSEENTER:"mouseenter.bs.tooltip",MOUSELEAVE:"mouseleave.bs.tooltip"},Se=function(t){function o(e,n){var i;if(void 0===ae)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");return(i=t.call(this,e)||this)._isEnabled=!0,i._timeout=0,i._hoverState="",i._activeTrigger={},i._popper=null,i.config=i._getConfig(n),i.tip=null,i._setListeners(),i}i(o,t);var r=o.prototype;return r.enable=function(){this._isEnabled=!0},r.disable=function(){this._isEnabled=!1},r.toggleEnabled=function(){this._isEnabled=!this._isEnabled},r.toggle=function(t){if(this._isEnabled)if(t){var e=this._initializeOnDelegatedTarget(t);e._activeTrigger.click=!e._activeTrigger.click,e._isWithActiveTrigger()?e._enter(null,e):e._leave(null,e)}else{if(this.getTipElement().classList.contains("show"))return void this._leave(null,this);this._enter(null,this)}},r.dispose=function(){clearTimeout(this._timeout),B.off(this._element,this.constructor.EVENT_KEY),B.off(this._element.closest(".modal"),"hide.bs.modal",this._hideModalHandler),this.tip&&this.tip.parentNode&&this.tip.parentNode.removeChild(this.tip),this._isEnabled=null,this._timeout=null,this._hoverState=null,this._activeTrigger=null,this._popper&&this._popper.destroy(),this._popper=null,this.config=null,this.tip=null,t.prototype.dispose.call(this)},r.show=function(){var t=this;if("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(this.isWithContent()&&this._isEnabled){var e=B.trigger(this._element,this.constructor.Event.SHOW),n=function t(e){if(!document.documentElement.attachShadow)return null;if("function"==typeof e.getRootNode){var n=e.getRootNode();return n instanceof ShadowRoot?n:null}return e instanceof ShadowRoot?e:e.parentNode?t(e.parentNode):null}(this._element),i=null===n?this._element.ownerDocument.documentElement.contains(this._element):n.contains(this._element);if(!e.defaultPrevented&&i){var o=this.getTipElement(),r=s(this.constructor.NAME);o.setAttribute("id",r),this._element.setAttribute("aria-describedby",r),this.setContent(),this.config.animation&&o.classList.add("fade");var a="function"==typeof this.config.placement?this.config.placement.call(this,o,this._element):this.config.placement,l=this._getAttachment(a);this._addAttachmentClass(l);var c=this._getContainer();E(o,this.constructor.DATA_KEY,this),this._element.ownerDocument.documentElement.contains(this.tip)||c.appendChild(o),B.trigger(this._element,this.constructor.Event.INSERTED),this._popper=se(this._element,o,this._getPopperConfig(l)),o.classList.add("show");var f,d,p="function"==typeof this.config.customClass?this.config.customClass():this.config.customClass;p&&(f=o.classList).add.apply(f,p.split(" ")),"ontouchstart"in document.documentElement&&(d=[]).concat.apply(d,document.body.children).forEach((function(t){B.on(t,"mouseover",(function(){}))}));var g=function(){var e=t._hoverState;t._hoverState=null,B.trigger(t._element,t.constructor.Event.SHOWN),"out"===e&&t._leave(null,t)};if(this.tip.classList.contains("fade")){var m=u(this.tip);B.one(this.tip,"transitionend",g),h(this.tip,m)}else g()}}},r.hide=function(){var t=this;if(this._popper){var e=this.getTipElement(),n=function(){"show"!==t._hoverState&&e.parentNode&&e.parentNode.removeChild(e),t._cleanTipClass(),t._element.removeAttribute("aria-describedby"),B.trigger(t._element,t.constructor.Event.HIDDEN),t._popper&&(t._popper.destroy(),t._popper=null)};if(!B.trigger(this._element,this.constructor.Event.HIDE).defaultPrevented){var i;if(e.classList.remove("show"),"ontouchstart"in document.documentElement&&(i=[]).concat.apply(i,document.body.children).forEach((function(t){return B.off(t,"mouseover",m)})),this._activeTrigger.click=!1,this._activeTrigger.focus=!1,this._activeTrigger.hover=!1,this.tip.classList.contains("fade")){var o=u(e);B.one(e,"transitionend",n),h(e,o)}else n();this._hoverState=""}}},r.update=function(){null!==this._popper&&this._popper.update()},r.isWithContent=function(){return Boolean(this.getTitle())},r.getTipElement=function(){if(this.tip)return this.tip;var t=document.createElement("div");return t.innerHTML=this.config.template,this.tip=t.children[0],this.tip},r.setContent=function(){var t=this.getTipElement();this.setElementContent(Y(".tooltip-inner",t),this.getTitle()),t.classList.remove("fade","show")},r.setElementContent=function(t,e){if(null!==t)return"object"==typeof e&&d(e)?(e.jquery&&(e=e[0]),void(this.config.html?e.parentNode!==t&&(t.innerHTML="",t.appendChild(e)):t.textContent=e.textContent)):void(this.config.html?(this.config.sanitize&&(e=ke(e,this.config.allowList,this.config.sanitizeFn)),t.innerHTML=e):t.textContent=e)},r.getTitle=function(){var t=this._element.getAttribute("data-bs-original-title");return t||(t="function"==typeof this.config.title?this.config.title.call(this._element):this.config.title),t},r.updateAttachment=function(t){return"right"===t?"end":"left"===t?"start":t},r._initializeOnDelegatedTarget=function(t,e){var n=this.constructor.DATA_KEY;return(e=e||T(t.delegateTarget,n))||(e=new this.constructor(t.delegateTarget,this._getDelegateConfig()),E(t.delegateTarget,n,e)),e},r._getOffset=function(){var t=this,e=this.config.offset;return"string"==typeof e?e.split(",").map((function(t){return Number.parseInt(t,10)})):"function"==typeof e?function(n){return e(n,t._element)}:e},r._getPopperConfig=function(t){var e=this,i={placement:t,modifiers:[{name:"flip",options:{altBoundary:!0,fallbackPlacements:this.config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this.config.boundary}},{name:"arrow",options:{element:"."+this.constructor.NAME+"-arrow"}},{name:"onChange",enabled:!0,phase:"afterWrite",fn:function(t){return e._handlePopperPlacementChange(t)}}],onFirstUpdate:function(t){t.options.placement!==t.placement&&e._handlePopperPlacementChange(t)}};return n({},i,"function"==typeof this.config.popperConfig?this.config.popperConfig(i):this.config.popperConfig)},r._addAttachmentClass=function(t){this.getTipElement().classList.add("bs-tooltip-"+this.updateAttachment(t))},r._getContainer=function(){return!1===this.config.container?document.body:d(this.config.container)?this.config.container:Y(this.config.container)},r._getAttachment=function(t){return De[t.toUpperCase()]},r._setListeners=function(){var t=this;this.config.trigger.split(" ").forEach((function(e){if("click"===e)B.on(t._element,t.constructor.Event.CLICK,t.config.selector,(function(e){return t.toggle(e)}));else if("manual"!==e){var n="hover"===e?t.constructor.Event.MOUSEENTER:t.constructor.Event.FOCUSIN,i="hover"===e?t.constructor.Event.MOUSELEAVE:t.constructor.Event.FOCUSOUT;B.on(t._element,n,t.config.selector,(function(e){return t._enter(e)})),B.on(t._element,i,t.config.selector,(function(e){return t._leave(e)}))}})),this._hideModalHandler=function(){t._element&&t.hide()},B.on(this._element.closest(".modal"),"hide.bs.modal",this._hideModalHandler),this.config.selector?this.config=n({},this.config,{trigger:"manual",selector:""}):this._fixTitle()},r._fixTitle=function(){var t=this._element.getAttribute("title"),e=typeof this._element.getAttribute("data-bs-original-title");(t||"string"!==e)&&(this._element.setAttribute("data-bs-original-title",t||""),!t||this._element.getAttribute("aria-label")||this._element.textContent||this._element.setAttribute("aria-label",t),this._element.setAttribute("title",""))},r._enter=function(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusin"===t.type?"focus":"hover"]=!0),e.getTipElement().classList.contains("show")||"show"===e._hoverState?e._hoverState="show":(clearTimeout(e._timeout),e._hoverState="show",e.config.delay&&e.config.delay.show?e._timeout=setTimeout((function(){"show"===e._hoverState&&e.show()}),e.config.delay.show):e.show())},r._leave=function(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusout"===t.type?"focus":"hover"]=!1),e._isWithActiveTrigger()||(clearTimeout(e._timeout),e._hoverState="out",e.config.delay&&e.config.delay.hide?e._timeout=setTimeout((function(){"out"===e._hoverState&&e.hide()}),e.config.delay.hide):e.hide())},r._isWithActiveTrigger=function(){for(var t in this._activeTrigger)if(this._activeTrigger[t])return!0;return!1},r._getConfig=function(t){var e=z.getDataAttributes(this._element);return Object.keys(e).forEach((function(t){Le.has(t)&&delete e[t]})),t&&"object"==typeof t.container&&t.container.jquery&&(t.container=t.container[0]),"number"==typeof(t=n({},this.constructor.Default,e,"object"==typeof t&&t?t:{})).delay&&(t.delay={show:t.delay,hide:t.delay}),"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),p("tooltip",t,this.constructor.DefaultType),t.sanitize&&(t.template=ke(t.template,t.allowList,t.sanitizeFn)),t},r._getDelegateConfig=function(){var t={};if(this.config)for(var e in this.config)this.constructor.Default[e]!==this.config[e]&&(t[e]=this.config[e]);return t},r._cleanTipClass=function(){var t=this.getTipElement(),e=t.getAttribute("class").match(Ae);null!==e&&e.length>0&&e.map((function(t){return t.trim()})).forEach((function(e){return t.classList.remove(e)}))},r._handlePopperPlacementChange=function(t){var e=t.state;e&&(this.tip=e.elements.popper,this._cleanTipClass(),this._addAttachmentClass(this._getAttachment(e.placement)))},o.jQueryInterface=function(t){return this.each((function(){var e=T(this,"bs.tooltip"),n="object"==typeof t&&t;if((e||!/dispose|hide/.test(t))&&(e||(e=new o(this,n)),"string"==typeof t)){if(void 0===e[t])throw new TypeError('No method named "'+t+'"');e[t]()}}))},e(o,null,[{key:"Default",get:function(){return xe}},{key:"NAME",get:function(){return"tooltip"}},{key:"DATA_KEY",get:function(){return"bs.tooltip"}},{key:"Event",get:function(){return Ce}},{key:"EVENT_KEY",get:function(){return".bs.tooltip"}},{key:"DefaultType",get:function(){return Oe}}]),o}(H);y("tooltip",Se);var je=new RegExp("(^|\\s)bs-popover\\S+","g"),Ne=n({},Se.Default,{placement:"right",offset:[0,8],trigger:"click",content:"",template:''}),Pe=n({},Se.DefaultType,{content:"(string|element|function)"}),Ie={HIDE:"hide.bs.popover",HIDDEN:"hidden.bs.popover",SHOW:"show.bs.popover",SHOWN:"shown.bs.popover",INSERTED:"inserted.bs.popover",CLICK:"click.bs.popover",FOCUSIN:"focusin.bs.popover",FOCUSOUT:"focusout.bs.popover",MOUSEENTER:"mouseenter.bs.popover",MOUSELEAVE:"mouseleave.bs.popover"},Me=function(t){function n(){return t.apply(this,arguments)||this}i(n,t);var o=n.prototype;return o.isWithContent=function(){return this.getTitle()||this._getContent()},o.setContent=function(){var t=this.getTipElement();this.setElementContent(Y(".popover-header",t),this.getTitle());var e=this._getContent();"function"==typeof e&&(e=e.call(this._element)),this.setElementContent(Y(".popover-body",t),e),t.classList.remove("fade","show")},o._addAttachmentClass=function(t){this.getTipElement().classList.add("bs-popover-"+this.updateAttachment(t))},o._getContent=function(){return this._element.getAttribute("data-bs-content")||this.config.content},o._cleanTipClass=function(){var t=this.getTipElement(),e=t.getAttribute("class").match(je);null!==e&&e.length>0&&e.map((function(t){return t.trim()})).forEach((function(e){return t.classList.remove(e)}))},n.jQueryInterface=function(t){return this.each((function(){var e=T(this,"bs.popover"),i="object"==typeof t?t:null;if((e||!/dispose|hide/.test(t))&&(e||(e=new n(this,i),E(this,"bs.popover",e)),"string"==typeof t)){if(void 0===e[t])throw new TypeError('No method named "'+t+'"');e[t]()}}))},e(n,null,[{key:"Default",get:function(){return Ne}},{key:"NAME",get:function(){return"popover"}},{key:"DATA_KEY",get:function(){return"bs.popover"}},{key:"Event",get:function(){return Ie}},{key:"EVENT_KEY",get:function(){return".bs.popover"}},{key:"DefaultType",get:function(){return Pe}}]),n}(Se);y("popover",Me);var Be={offset:10,method:"auto",target:""},He={offset:"number",method:"string",target:"(string|element)"},Re=function(t){function o(e,n){var i;return(i=t.call(this,e)||this)._scrollElement="BODY"===e.tagName?window:e,i._config=i._getConfig(n),i._selector=i._config.target+" .nav-link, "+i._config.target+" .list-group-item, "+i._config.target+" .dropdown-item",i._offsets=[],i._targets=[],i._activeTarget=null,i._scrollHeight=0,B.on(i._scrollElement,"scroll.bs.scrollspy",(function(){return i._process()})),i.refresh(),i._process(),i}i(o,t);var r=o.prototype;return r.refresh=function(){var t=this,e=this._scrollElement===this._scrollElement.window?"offset":"position",n="auto"===this._config.method?e:this._config.method,i="position"===n?this._getScrollTop():0;this._offsets=[],this._targets=[],this._scrollHeight=this._getScrollHeight(),F(this._selector).map((function(t){var e=l(t),o=e?Y(e):null;if(o){var r=o.getBoundingClientRect();if(r.width||r.height)return[z[n](o).top+i,e]}return null})).filter((function(t){return t})).sort((function(t,e){return t[0]-e[0]})).forEach((function(e){t._offsets.push(e[0]),t._targets.push(e[1])}))},r.dispose=function(){t.prototype.dispose.call(this),B.off(this._scrollElement,".bs.scrollspy"),this._scrollElement=null,this._config=null,this._selector=null,this._offsets=null,this._targets=null,this._activeTarget=null,this._scrollHeight=null},r._getConfig=function(t){if("string"!=typeof(t=n({},Be,"object"==typeof t&&t?t:{})).target&&d(t.target)){var e=t.target.id;e||(e=s("scrollspy"),t.target.id=e),t.target="#"+e}return p("scrollspy",t,He),t},r._getScrollTop=function(){return this._scrollElement===window?this._scrollElement.pageYOffset:this._scrollElement.scrollTop},r._getScrollHeight=function(){return this._scrollElement.scrollHeight||Math.max(document.body.scrollHeight,document.documentElement.scrollHeight)},r._getOffsetHeight=function(){return this._scrollElement===window?window.innerHeight:this._scrollElement.getBoundingClientRect().height},r._process=function(){var t=this._getScrollTop()+this._config.offset,e=this._getScrollHeight(),n=this._config.offset+e-this._getOffsetHeight();if(this._scrollHeight!==e&&this.refresh(),t>=n){var i=this._targets[this._targets.length-1];this._activeTarget!==i&&this._activate(i)}else{if(this._activeTarget&&t0)return this._activeTarget=null,void this._clear();for(var o=this._offsets.length;o--;)this._activeTarget!==this._targets[o]&&t>=this._offsets[o]&&(void 0===this._offsets[o+1]||t li > .active":".active";e=(e=F(o,i))[e.length-1]}var r=e?B.trigger(e,"hide.bs.tab",{relatedTarget:this._element}):null;if(!(B.trigger(this._element,"show.bs.tab",{relatedTarget:e}).defaultPrevented||null!==r&&r.defaultPrevented)){this._activate(this._element,i);var s=function(){B.trigger(e,"hidden.bs.tab",{relatedTarget:t._element}),B.trigger(t._element,"shown.bs.tab",{relatedTarget:e})};n?this._activate(n,n.parentNode,s):s()}}},o._activate=function(t,e,n){var i=this,o=(!e||"UL"!==e.nodeName&&"OL"!==e.nodeName?q(e,".active"):F(":scope > li > .active",e))[0],r=n&&o&&o.classList.contains("fade"),s=function(){return i._transitionComplete(t,o,n)};if(o&&r){var a=u(o);o.classList.remove("show"),B.one(o,"transitionend",s),h(o,a)}else s()},o._transitionComplete=function(t,e,n){if(e){e.classList.remove("active");var i=Y(":scope > .dropdown-menu .active",e.parentNode);i&&i.classList.remove("active"),"tab"===e.getAttribute("role")&&e.setAttribute("aria-selected",!1)}t.classList.add("active"),"tab"===t.getAttribute("role")&&t.setAttribute("aria-selected",!0),v(t),t.classList.contains("fade")&&t.classList.add("show"),t.parentNode&&t.parentNode.classList.contains("dropdown-menu")&&(t.closest(".dropdown")&&F(".dropdown-toggle").forEach((function(t){return t.classList.add("active")})),t.setAttribute("aria-expanded",!0)),n&&n()},n.jQueryInterface=function(t){return this.each((function(){var e=T(this,"bs.tab")||new n(this);if("string"==typeof t){if(void 0===e[t])throw new TypeError('No method named "'+t+'"');e[t]()}}))},e(n,null,[{key:"DATA_KEY",get:function(){return"bs.tab"}}]),n}(H);B.on(document,"click.bs.tab.data-api",'[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',(function(t){t.preventDefault(),(T(this,"bs.tab")||new We(this)).show()})),y("tab",We);var Ke={animation:"boolean",autohide:"boolean",delay:"number"},Ue={animation:!0,autohide:!0,delay:5e3},ze=function(t){function o(e,n){var i;return(i=t.call(this,e)||this)._config=i._getConfig(n),i._timeout=null,i._setListeners(),i}i(o,t);var r=o.prototype;return r.show=function(){var t=this;if(!B.trigger(this._element,"show.bs.toast").defaultPrevented){this._clearTimeout(),this._config.animation&&this._element.classList.add("fade");var e=function(){t._element.classList.remove("showing"),t._element.classList.add("show"),B.trigger(t._element,"shown.bs.toast"),t._config.autohide&&(t._timeout=setTimeout((function(){t.hide()}),t._config.delay))};if(this._element.classList.remove("hide"),v(this._element),this._element.classList.add("showing"),this._config.animation){var n=u(this._element);B.one(this._element,"transitionend",e),h(this._element,n)}else e()}},r.hide=function(){var t=this;if(this._element.classList.contains("show")&&!B.trigger(this._element,"hide.bs.toast").defaultPrevented){var e=function(){t._element.classList.add("hide"),B.trigger(t._element,"hidden.bs.toast")};if(this._element.classList.remove("show"),this._config.animation){var n=u(this._element);B.one(this._element,"transitionend",e),h(this._element,n)}else e()}},r.dispose=function(){this._clearTimeout(),this._element.classList.contains("show")&&this._element.classList.remove("show"),B.off(this._element,"click.dismiss.bs.toast"),t.prototype.dispose.call(this),this._config=null},r._getConfig=function(t){return t=n({},Ue,z.getDataAttributes(this._element),"object"==typeof t&&t?t:{}),p("toast",t,this.constructor.DefaultType),t},r._setListeners=function(){var t=this;B.on(this._element,"click.dismiss.bs.toast",'[data-bs-dismiss="toast"]',(function(){return t.hide()}))},r._clearTimeout=function(){clearTimeout(this._timeout),this._timeout=null},o.jQueryInterface=function(t){return this.each((function(){var e=T(this,"bs.toast");if(e||(e=new o(this,"object"==typeof t&&t)),"string"==typeof t){if(void 0===e[t])throw new TypeError('No method named "'+t+'"');e[t](this)}}))},e(o,null,[{key:"DefaultType",get:function(){return Ke}},{key:"Default",get:function(){return Ue}},{key:"DATA_KEY",get:function(){return"bs.toast"}}]),o}(H);return y("toast",ze),{Alert:R,Button:W,Carousel:$,Collapse:J,Dropdown:ve,Modal:ye,Popover:Me,ScrollSpy:Re,Tab:We,Toast:ze,Tooltip:Se}})); +//# sourceMappingURL=bootstrap.bundle.min.js.map \ No newline at end of file diff --git a/media/com_jedchecker/js/bootstrap.min.js b/media/com_jedchecker/js/bootstrap.min.js deleted file mode 100644 index e9aefb9..0000000 --- a/media/com_jedchecker/js/bootstrap.min.js +++ /dev/null @@ -1,7 +0,0 @@ -/*! - * Bootstrap v5.0.0-beta2 (https://getbootstrap.com/) - * Copyright 2011-2021 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) - * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) - */ -!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("@popperjs/core")):"function"==typeof define&&define.amd?define(["@popperjs/core"],e):(t="undefined"!=typeof globalThis?globalThis:t||self).bootstrap=e(t.Popper)}(this,(function(t){"use strict";function e(t){if(t&&t.__esModule)return t;var e=Object.create(null);return t&&Object.keys(t).forEach((function(n){if("default"!==n){var i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,i.get?i:{enumerable:!0,get:function(){return t[n]}})}})),e.default=t,Object.freeze(e)}var n=e(t);function i(t,e){for(var n=0;n0,i._pointerEvent=Boolean(window.PointerEvent),i._addEventListeners(),i}r(e,t);var n=e.prototype;return n.next=function(){this._isSliding||this._slide("next")},n.nextWhenVisible=function(){!document.hidden&&v(this._element)&&this.next()},n.prev=function(){this._isSliding||this._slide("prev")},n.pause=function(t){t||(this._isPaused=!0),Q(".carousel-item-next, .carousel-item-prev",this._element)&&(p(this._element),this.cycle(!0)),clearInterval(this._interval),this._interval=null},n.cycle=function(t){t||(this._isPaused=!1),this._interval&&(clearInterval(this._interval),this._interval=null),this._config&&this._config.interval&&!this._isPaused&&(this._updateInterval(),this._interval=setInterval((document.visibilityState?this.nextWhenVisible:this.next).bind(this),this._config.interval))},n.to=function(t){var e=this;this._activeElement=Q(".active.carousel-item",this._element);var n=this._getItemIndex(this._activeElement);if(!(t>this._items.length-1||t<0))if(this._isSliding)K.one(this._element,"slid.bs.carousel",(function(){return e.to(t)}));else{if(n===t)return this.pause(),void this.cycle();var i=t>n?"next":"prev";this._slide(i,this._items[t])}},n.dispose=function(){t.prototype.dispose.call(this),K.off(this._element,".bs.carousel"),this._items=null,this._config=null,this._interval=null,this._isPaused=null,this._isSliding=null,this._activeElement=null,this._indicatorsElement=null},n._getConfig=function(t){return t=s({},G,t),_("carousel",t,Z),t},n._handleSwipe=function(){var t=Math.abs(this.touchDeltaX);if(!(t<=40)){var e=t/this.touchDeltaX;this.touchDeltaX=0,e>0&&(E?this.next():this.prev()),e<0&&(E?this.prev():this.next())}},n._addEventListeners=function(){var t=this;this._config.keyboard&&K.on(this._element,"keydown.bs.carousel",(function(e){return t._keydown(e)})),"hover"===this._config.pause&&(K.on(this._element,"mouseenter.bs.carousel",(function(e){return t.pause(e)})),K.on(this._element,"mouseleave.bs.carousel",(function(e){return t.cycle(e)}))),this._config.touch&&this._touchSupported&&this._addTouchEventListeners()},n._addTouchEventListeners=function(){var t=this,e=function(e){!t._pointerEvent||"pen"!==e.pointerType&&"touch"!==e.pointerType?t._pointerEvent||(t.touchStartX=e.touches[0].clientX):t.touchStartX=e.clientX},n=function(e){!t._pointerEvent||"pen"!==e.pointerType&&"touch"!==e.pointerType||(t.touchDeltaX=e.clientX-t.touchStartX),t._handleSwipe(),"hover"===t._config.pause&&(t.pause(),t.touchTimeout&&clearTimeout(t.touchTimeout),t.touchTimeout=setTimeout((function(e){return t.cycle(e)}),500+t._config.interval))};q(".carousel-item img",this._element).forEach((function(t){K.on(t,"dragstart.bs.carousel",(function(t){return t.preventDefault()}))})),this._pointerEvent?(K.on(this._element,"pointerdown.bs.carousel",(function(t){return e(t)})),K.on(this._element,"pointerup.bs.carousel",(function(t){return n(t)})),this._element.classList.add("pointer-event")):(K.on(this._element,"touchstart.bs.carousel",(function(t){return e(t)})),K.on(this._element,"touchmove.bs.carousel",(function(e){return function(e){e.touches&&e.touches.length>1?t.touchDeltaX=0:t.touchDeltaX=e.touches[0].clientX-t.touchStartX}(e)})),K.on(this._element,"touchend.bs.carousel",(function(t){return n(t)})))},n._keydown=function(t){/input|textarea/i.test(t.target.tagName)||("ArrowLeft"===t.key?(t.preventDefault(),E?this.next():this.prev()):"ArrowRight"===t.key&&(t.preventDefault(),E?this.prev():this.next()))},n._getItemIndex=function(t){return this._items=t&&t.parentNode?q(".carousel-item",t.parentNode):[],this._items.indexOf(t)},n._getItemByDirection=function(t,e){var n="next"===t,i="prev"===t,o=this._getItemIndex(e),s=this._items.length-1;if((i&&0===o||n&&o===s)&&!this._config.wrap)return e;var r=(o+("prev"===t?-1:1))%this._items.length;return-1===r?this._items[this._items.length-1]:this._items[r]},n._triggerSlideEvent=function(t,e){var n=this._getItemIndex(t),i=this._getItemIndex(Q(".active.carousel-item",this._element));return K.trigger(this._element,"slide.bs.carousel",{relatedTarget:t,direction:e,from:i,to:n})},n._setActiveIndicatorElement=function(t){if(this._indicatorsElement){var e=Q(".active",this._indicatorsElement);e.classList.remove("active"),e.removeAttribute("aria-current");for(var n=q("[data-bs-target]",this._indicatorsElement),i=0;i0)for(var i=0;i0&&s--,"ArrowDown"===t.key&&sdocument.documentElement.clientHeight;e||(this._element.style.overflowY="hidden"),this._element.classList.add("modal-static");var n=f(this._dialog);K.off(this._element,"transitionend"),K.one(this._element,"transitionend",(function(){t._element.classList.remove("modal-static"),e||(K.one(t._element,"transitionend",(function(){t._element.style.overflowY=""})),m(t._element,n))})),m(this._element,n),this._element.focus()}},n._adjustDialog=function(){var t=this._element.scrollHeight>document.documentElement.clientHeight;(!this._isBodyOverflowing&&t&&!E||this._isBodyOverflowing&&!t&&E)&&(this._element.style.paddingLeft=this._scrollbarWidth+"px"),(this._isBodyOverflowing&&!t&&!E||!this._isBodyOverflowing&&t&&E)&&(this._element.style.paddingRight=this._scrollbarWidth+"px")},n._resetAdjustments=function(){this._element.style.paddingLeft="",this._element.style.paddingRight=""},n._checkScrollbar=function(){var t=document.body.getBoundingClientRect();this._isBodyOverflowing=Math.round(t.left+t.right)
    ',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:[0,0],container:!1,fallbackPlacements:["top","right","bottom","left"],boundary:"clippingParents",customClass:"",sanitize:!0,sanitizeFn:null,allowList:{"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},popperConfig:null},kt={HIDE:"hide.bs.tooltip",HIDDEN:"hidden.bs.tooltip",SHOW:"show.bs.tooltip",SHOWN:"shown.bs.tooltip",INSERTED:"inserted.bs.tooltip",CLICK:"click.bs.tooltip",FOCUSIN:"focusin.bs.tooltip",FOCUSOUT:"focusout.bs.tooltip",MOUSEENTER:"mouseenter.bs.tooltip",MOUSELEAVE:"mouseleave.bs.tooltip"},Lt=function(e){function i(t,i){var o;if(void 0===n)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");return(o=e.call(this,t)||this)._isEnabled=!0,o._timeout=0,o._hoverState="",o._activeTrigger={},o._popper=null,o.config=o._getConfig(i),o.tip=null,o._setListeners(),o}r(i,e);var a=i.prototype;return a.enable=function(){this._isEnabled=!0},a.disable=function(){this._isEnabled=!1},a.toggleEnabled=function(){this._isEnabled=!this._isEnabled},a.toggle=function(t){if(this._isEnabled)if(t){var e=this._initializeOnDelegatedTarget(t);e._activeTrigger.click=!e._activeTrigger.click,e._isWithActiveTrigger()?e._enter(null,e):e._leave(null,e)}else{if(this.getTipElement().classList.contains("show"))return void this._leave(null,this);this._enter(null,this)}},a.dispose=function(){clearTimeout(this._timeout),K.off(this._element,this.constructor.EVENT_KEY),K.off(this._element.closest(".modal"),"hide.bs.modal",this._hideModalHandler),this.tip&&this.tip.parentNode&&this.tip.parentNode.removeChild(this.tip),this._isEnabled=null,this._timeout=null,this._hoverState=null,this._activeTrigger=null,this._popper&&this._popper.destroy(),this._popper=null,this.config=null,this.tip=null,e.prototype.dispose.call(this)},a.show=function(){var e=this;if("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(this.isWithContent()&&this._isEnabled){var n=K.trigger(this._element,this.constructor.Event.SHOW),i=function t(e){if(!document.documentElement.attachShadow)return null;if("function"==typeof e.getRootNode){var n=e.getRootNode();return n instanceof ShadowRoot?n:null}return e instanceof ShadowRoot?e:e.parentNode?t(e.parentNode):null}(this._element),o=null===i?this._element.ownerDocument.documentElement.contains(this._element):i.contains(this._element);if(!n.defaultPrevented&&o){var s=this.getTipElement(),r=c(this.constructor.NAME);s.setAttribute("id",r),this._element.setAttribute("aria-describedby",r),this.setContent(),this.config.animation&&s.classList.add("fade");var a="function"==typeof this.config.placement?this.config.placement.call(this,s,this._element):this.config.placement,l=this._getAttachment(a);this._addAttachmentClass(l);var u=this._getContainer();k(s,this.constructor.DATA_KEY,this),this._element.ownerDocument.documentElement.contains(this.tip)||u.appendChild(s),K.trigger(this._element,this.constructor.Event.INSERTED),this._popper=t.createPopper(this._element,s,this._getPopperConfig(l)),s.classList.add("show");var h,d,p="function"==typeof this.config.customClass?this.config.customClass():this.config.customClass;p&&(h=s.classList).add.apply(h,p.split(" ")),"ontouchstart"in document.documentElement&&(d=[]).concat.apply(d,document.body.children).forEach((function(t){K.on(t,"mouseover",(function(){}))}));var g=function(){var t=e._hoverState;e._hoverState=null,K.trigger(e._element,e.constructor.Event.SHOWN),"out"===t&&e._leave(null,e)};if(this.tip.classList.contains("fade")){var _=f(this.tip);K.one(this.tip,"transitionend",g),m(this.tip,_)}else g()}}},a.hide=function(){var t=this;if(this._popper){var e=this.getTipElement(),n=function(){"show"!==t._hoverState&&e.parentNode&&e.parentNode.removeChild(e),t._cleanTipClass(),t._element.removeAttribute("aria-describedby"),K.trigger(t._element,t.constructor.Event.HIDDEN),t._popper&&(t._popper.destroy(),t._popper=null)};if(!K.trigger(this._element,this.constructor.Event.HIDE).defaultPrevented){var i;if(e.classList.remove("show"),"ontouchstart"in document.documentElement&&(i=[]).concat.apply(i,document.body.children).forEach((function(t){return K.off(t,"mouseover",b)})),this._activeTrigger.click=!1,this._activeTrigger.focus=!1,this._activeTrigger.hover=!1,this.tip.classList.contains("fade")){var o=f(e);K.one(e,"transitionend",n),m(e,o)}else n();this._hoverState=""}}},a.update=function(){null!==this._popper&&this._popper.update()},a.isWithContent=function(){return Boolean(this.getTitle())},a.getTipElement=function(){if(this.tip)return this.tip;var t=document.createElement("div");return t.innerHTML=this.config.template,this.tip=t.children[0],this.tip},a.setContent=function(){var t=this.getTipElement();this.setElementContent(Q(".tooltip-inner",t),this.getTitle()),t.classList.remove("fade","show")},a.setElementContent=function(t,e){if(null!==t)return"object"==typeof e&&g(e)?(e.jquery&&(e=e[0]),void(this.config.html?e.parentNode!==t&&(t.innerHTML="",t.appendChild(e)):t.textContent=e.textContent)):void(this.config.html?(this.config.sanitize&&(e=bt(e,this.config.allowList,this.config.sanitizeFn)),t.innerHTML=e):t.textContent=e)},a.getTitle=function(){var t=this._element.getAttribute("data-bs-original-title");return t||(t="function"==typeof this.config.title?this.config.title.call(this._element):this.config.title),t},a.updateAttachment=function(t){return"right"===t?"end":"left"===t?"start":t},a._initializeOnDelegatedTarget=function(t,e){var n=this.constructor.DATA_KEY;return(e=e||L(t.delegateTarget,n))||(e=new this.constructor(t.delegateTarget,this._getDelegateConfig()),k(t.delegateTarget,n,e)),e},a._getOffset=function(){var t=this,e=this.config.offset;return"string"==typeof e?e.split(",").map((function(t){return Number.parseInt(t,10)})):"function"==typeof e?function(n){return e(n,t._element)}:e},a._getPopperConfig=function(t){var e=this,n={placement:t,modifiers:[{name:"flip",options:{altBoundary:!0,fallbackPlacements:this.config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this.config.boundary}},{name:"arrow",options:{element:"."+this.constructor.NAME+"-arrow"}},{name:"onChange",enabled:!0,phase:"afterWrite",fn:function(t){return e._handlePopperPlacementChange(t)}}],onFirstUpdate:function(t){t.options.placement!==t.placement&&e._handlePopperPlacementChange(t)}};return s({},n,"function"==typeof this.config.popperConfig?this.config.popperConfig(n):this.config.popperConfig)},a._addAttachmentClass=function(t){this.getTipElement().classList.add("bs-tooltip-"+this.updateAttachment(t))},a._getContainer=function(){return!1===this.config.container?document.body:g(this.config.container)?this.config.container:Q(this.config.container)},a._getAttachment=function(t){return Tt[t.toUpperCase()]},a._setListeners=function(){var t=this;this.config.trigger.split(" ").forEach((function(e){if("click"===e)K.on(t._element,t.constructor.Event.CLICK,t.config.selector,(function(e){return t.toggle(e)}));else if("manual"!==e){var n="hover"===e?t.constructor.Event.MOUSEENTER:t.constructor.Event.FOCUSIN,i="hover"===e?t.constructor.Event.MOUSELEAVE:t.constructor.Event.FOCUSOUT;K.on(t._element,n,t.config.selector,(function(e){return t._enter(e)})),K.on(t._element,i,t.config.selector,(function(e){return t._leave(e)}))}})),this._hideModalHandler=function(){t._element&&t.hide()},K.on(this._element.closest(".modal"),"hide.bs.modal",this._hideModalHandler),this.config.selector?this.config=s({},this.config,{trigger:"manual",selector:""}):this._fixTitle()},a._fixTitle=function(){var t=this._element.getAttribute("title"),e=typeof this._element.getAttribute("data-bs-original-title");(t||"string"!==e)&&(this._element.setAttribute("data-bs-original-title",t||""),!t||this._element.getAttribute("aria-label")||this._element.textContent||this._element.setAttribute("aria-label",t),this._element.setAttribute("title",""))},a._enter=function(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusin"===t.type?"focus":"hover"]=!0),e.getTipElement().classList.contains("show")||"show"===e._hoverState?e._hoverState="show":(clearTimeout(e._timeout),e._hoverState="show",e.config.delay&&e.config.delay.show?e._timeout=setTimeout((function(){"show"===e._hoverState&&e.show()}),e.config.delay.show):e.show())},a._leave=function(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusout"===t.type?"focus":"hover"]=!1),e._isWithActiveTrigger()||(clearTimeout(e._timeout),e._hoverState="out",e.config.delay&&e.config.delay.hide?e._timeout=setTimeout((function(){"out"===e._hoverState&&e.hide()}),e.config.delay.hide):e.hide())},a._isWithActiveTrigger=function(){for(var t in this._activeTrigger)if(this._activeTrigger[t])return!0;return!1},a._getConfig=function(t){var e=X.getDataAttributes(this._element);return Object.keys(e).forEach((function(t){wt.has(t)&&delete e[t]})),t&&"object"==typeof t.container&&t.container.jquery&&(t.container=t.container[0]),"number"==typeof(t=s({},this.constructor.Default,e,"object"==typeof t&&t?t:{})).delay&&(t.delay={show:t.delay,hide:t.delay}),"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),_("tooltip",t,this.constructor.DefaultType),t.sanitize&&(t.template=bt(t.template,t.allowList,t.sanitizeFn)),t},a._getDelegateConfig=function(){var t={};if(this.config)for(var e in this.config)this.constructor.Default[e]!==this.config[e]&&(t[e]=this.config[e]);return t},a._cleanTipClass=function(){var t=this.getTipElement(),e=t.getAttribute("class").match(yt);null!==e&&e.length>0&&e.map((function(t){return t.trim()})).forEach((function(e){return t.classList.remove(e)}))},a._handlePopperPlacementChange=function(t){var e=t.state;e&&(this.tip=e.elements.popper,this._cleanTipClass(),this._addAttachmentClass(this._getAttachment(e.placement)))},i.jQueryInterface=function(t){return this.each((function(){var e=L(this,"bs.tooltip"),n="object"==typeof t&&t;if((e||!/dispose|hide/.test(t))&&(e||(e=new i(this,n)),"string"==typeof t)){if(void 0===e[t])throw new TypeError('No method named "'+t+'"');e[t]()}}))},o(i,null,[{key:"Default",get:function(){return At}},{key:"NAME",get:function(){return"tooltip"}},{key:"DATA_KEY",get:function(){return"bs.tooltip"}},{key:"Event",get:function(){return kt}},{key:"EVENT_KEY",get:function(){return".bs.tooltip"}},{key:"DefaultType",get:function(){return Et}}]),i}(W);T("tooltip",Lt);var Ct=new RegExp("(^|\\s)bs-popover\\S+","g"),Dt=s({},Lt.Default,{placement:"right",offset:[0,8],trigger:"click",content:"",template:''}),St=s({},Lt.DefaultType,{content:"(string|element|function)"}),Nt={HIDE:"hide.bs.popover",HIDDEN:"hidden.bs.popover",SHOW:"show.bs.popover",SHOWN:"shown.bs.popover",INSERTED:"inserted.bs.popover",CLICK:"click.bs.popover",FOCUSIN:"focusin.bs.popover",FOCUSOUT:"focusout.bs.popover",MOUSEENTER:"mouseenter.bs.popover",MOUSELEAVE:"mouseleave.bs.popover"},Ot=function(t){function e(){return t.apply(this,arguments)||this}r(e,t);var n=e.prototype;return n.isWithContent=function(){return this.getTitle()||this._getContent()},n.setContent=function(){var t=this.getTipElement();this.setElementContent(Q(".popover-header",t),this.getTitle());var e=this._getContent();"function"==typeof e&&(e=e.call(this._element)),this.setElementContent(Q(".popover-body",t),e),t.classList.remove("fade","show")},n._addAttachmentClass=function(t){this.getTipElement().classList.add("bs-popover-"+this.updateAttachment(t))},n._getContent=function(){return this._element.getAttribute("data-bs-content")||this.config.content},n._cleanTipClass=function(){var t=this.getTipElement(),e=t.getAttribute("class").match(Ct);null!==e&&e.length>0&&e.map((function(t){return t.trim()})).forEach((function(e){return t.classList.remove(e)}))},e.jQueryInterface=function(t){return this.each((function(){var n=L(this,"bs.popover"),i="object"==typeof t?t:null;if((n||!/dispose|hide/.test(t))&&(n||(n=new e(this,i),k(this,"bs.popover",n)),"string"==typeof t)){if(void 0===n[t])throw new TypeError('No method named "'+t+'"');n[t]()}}))},o(e,null,[{key:"Default",get:function(){return Dt}},{key:"NAME",get:function(){return"popover"}},{key:"DATA_KEY",get:function(){return"bs.popover"}},{key:"Event",get:function(){return Nt}},{key:"EVENT_KEY",get:function(){return".bs.popover"}},{key:"DefaultType",get:function(){return St}}]),e}(Lt);T("popover",Ot);var It={offset:10,method:"auto",target:""},jt={offset:"number",method:"string",target:"(string|element)"},Pt=function(t){function e(e,n){var i;return(i=t.call(this,e)||this)._scrollElement="BODY"===e.tagName?window:e,i._config=i._getConfig(n),i._selector=i._config.target+" .nav-link, "+i._config.target+" .list-group-item, "+i._config.target+" .dropdown-item",i._offsets=[],i._targets=[],i._activeTarget=null,i._scrollHeight=0,K.on(i._scrollElement,"scroll.bs.scrollspy",(function(){return i._process()})),i.refresh(),i._process(),i}r(e,t);var n=e.prototype;return n.refresh=function(){var t=this,e=this._scrollElement===this._scrollElement.window?"offset":"position",n="auto"===this._config.method?e:this._config.method,i="position"===n?this._getScrollTop():0;this._offsets=[],this._targets=[],this._scrollHeight=this._getScrollHeight(),q(this._selector).map((function(t){var e=h(t),o=e?Q(e):null;if(o){var s=o.getBoundingClientRect();if(s.width||s.height)return[X[n](o).top+i,e]}return null})).filter((function(t){return t})).sort((function(t,e){return t[0]-e[0]})).forEach((function(e){t._offsets.push(e[0]),t._targets.push(e[1])}))},n.dispose=function(){t.prototype.dispose.call(this),K.off(this._scrollElement,".bs.scrollspy"),this._scrollElement=null,this._config=null,this._selector=null,this._offsets=null,this._targets=null,this._activeTarget=null,this._scrollHeight=null},n._getConfig=function(t){if("string"!=typeof(t=s({},It,"object"==typeof t&&t?t:{})).target&&g(t.target)){var e=t.target.id;e||(e=c("scrollspy"),t.target.id=e),t.target="#"+e}return _("scrollspy",t,jt),t},n._getScrollTop=function(){return this._scrollElement===window?this._scrollElement.pageYOffset:this._scrollElement.scrollTop},n._getScrollHeight=function(){return this._scrollElement.scrollHeight||Math.max(document.body.scrollHeight,document.documentElement.scrollHeight)},n._getOffsetHeight=function(){return this._scrollElement===window?window.innerHeight:this._scrollElement.getBoundingClientRect().height},n._process=function(){var t=this._getScrollTop()+this._config.offset,e=this._getScrollHeight(),n=this._config.offset+e-this._getOffsetHeight();if(this._scrollHeight!==e&&this.refresh(),t>=n){var i=this._targets[this._targets.length-1];this._activeTarget!==i&&this._activate(i)}else{if(this._activeTarget&&t0)return this._activeTarget=null,void this._clear();for(var o=this._offsets.length;o--;)this._activeTarget!==this._targets[o]&&t>=this._offsets[o]&&(void 0===this._offsets[o+1]||t li > .active":".active";e=(e=q(o,i))[e.length-1]}var s=e?K.trigger(e,"hide.bs.tab",{relatedTarget:this._element}):null;if(!(K.trigger(this._element,"show.bs.tab",{relatedTarget:e}).defaultPrevented||null!==s&&s.defaultPrevented)){this._activate(this._element,i);var r=function(){K.trigger(e,"hidden.bs.tab",{relatedTarget:t._element}),K.trigger(t._element,"shown.bs.tab",{relatedTarget:e})};n?this._activate(n,n.parentNode,r):r()}}},n._activate=function(t,e,n){var i=this,o=(!e||"UL"!==e.nodeName&&"OL"!==e.nodeName?V(e,".active"):q(":scope > li > .active",e))[0],s=n&&o&&o.classList.contains("fade"),r=function(){return i._transitionComplete(t,o,n)};if(o&&s){var a=f(o);o.classList.remove("show"),K.one(o,"transitionend",r),m(o,a)}else r()},n._transitionComplete=function(t,e,n){if(e){e.classList.remove("active");var i=Q(":scope > .dropdown-menu .active",e.parentNode);i&&i.classList.remove("active"),"tab"===e.getAttribute("role")&&e.setAttribute("aria-selected",!1)}t.classList.add("active"),"tab"===t.getAttribute("role")&&t.setAttribute("aria-selected",!0),y(t),t.classList.contains("fade")&&t.classList.add("show"),t.parentNode&&t.parentNode.classList.contains("dropdown-menu")&&(t.closest(".dropdown")&&q(".dropdown-toggle").forEach((function(t){return t.classList.add("active")})),t.setAttribute("aria-expanded",!0)),n&&n()},e.jQueryInterface=function(t){return this.each((function(){var n=L(this,"bs.tab")||new e(this);if("string"==typeof t){if(void 0===n[t])throw new TypeError('No method named "'+t+'"');n[t]()}}))},o(e,null,[{key:"DATA_KEY",get:function(){return"bs.tab"}}]),e}(W);K.on(document,"click.bs.tab.data-api",'[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',(function(t){t.preventDefault(),(L(this,"bs.tab")||new xt(this)).show()})),T("tab",xt);var Ht={animation:"boolean",autohide:"boolean",delay:"number"},Bt={animation:!0,autohide:!0,delay:5e3},Mt=function(t){function e(e,n){var i;return(i=t.call(this,e)||this)._config=i._getConfig(n),i._timeout=null,i._setListeners(),i}r(e,t);var n=e.prototype;return n.show=function(){var t=this;if(!K.trigger(this._element,"show.bs.toast").defaultPrevented){this._clearTimeout(),this._config.animation&&this._element.classList.add("fade");var e=function(){t._element.classList.remove("showing"),t._element.classList.add("show"),K.trigger(t._element,"shown.bs.toast"),t._config.autohide&&(t._timeout=setTimeout((function(){t.hide()}),t._config.delay))};if(this._element.classList.remove("hide"),y(this._element),this._element.classList.add("showing"),this._config.animation){var n=f(this._element);K.one(this._element,"transitionend",e),m(this._element,n)}else e()}},n.hide=function(){var t=this;if(this._element.classList.contains("show")&&!K.trigger(this._element,"hide.bs.toast").defaultPrevented){var e=function(){t._element.classList.add("hide"),K.trigger(t._element,"hidden.bs.toast")};if(this._element.classList.remove("show"),this._config.animation){var n=f(this._element);K.one(this._element,"transitionend",e),m(this._element,n)}else e()}},n.dispose=function(){this._clearTimeout(),this._element.classList.contains("show")&&this._element.classList.remove("show"),K.off(this._element,"click.dismiss.bs.toast"),t.prototype.dispose.call(this),this._config=null},n._getConfig=function(t){return t=s({},Bt,X.getDataAttributes(this._element),"object"==typeof t&&t?t:{}),_("toast",t,this.constructor.DefaultType),t},n._setListeners=function(){var t=this;K.on(this._element,"click.dismiss.bs.toast",'[data-bs-dismiss="toast"]',(function(){return t.hide()}))},n._clearTimeout=function(){clearTimeout(this._timeout),this._timeout=null},e.jQueryInterface=function(t){return this.each((function(){var n=L(this,"bs.toast");if(n||(n=new e(this,"object"==typeof t&&t)),"string"==typeof t){if(void 0===n[t])throw new TypeError('No method named "'+t+'"');n[t](this)}}))},o(e,null,[{key:"DefaultType",get:function(){return Ht}},{key:"Default",get:function(){return Bt}},{key:"DATA_KEY",get:function(){return"bs.toast"}}]),e}(W);return T("toast",Mt),{Alert:U,Button:F,Carousel:J,Collapse:nt,Dropdown:dt,Modal:gt,Popover:Ot,ScrollSpy:Pt,Tab:xt,Toast:Mt,Tooltip:Lt}})); -//# sourceMappingURL=bootstrap.min.js.map \ No newline at end of file diff --git a/media/com_jedchecker/js/script.js b/media/com_jedchecker/js/script.js index 0ea053f..4d77e6c 100644 --- a/media/com_jedchecker/js/script.js +++ b/media/com_jedchecker/js/script.js @@ -83,3 +83,7 @@ Joomla.submitbutton = function (task) { Joomla.submitform(task); } } + +jQuery(document).ready(function() { + new bootstrap.Tooltip(document.getElementById('jedchecker'), {container: 'body', selector: '[data-bs-toggle=tooltip]'}); +}); From 2182167574a05244a10f9678e484e6d08d3b9ce6 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 9 Mar 2021 23:24:49 +0300 Subject: [PATCH 075/238] simplify processing of ajax results --- media/com_jedchecker/js/script.js | 21 ++++++--------------- 1 file changed, 6 insertions(+), 15 deletions(-) diff --git a/media/com_jedchecker/js/script.js b/media/com_jedchecker/js/script.js index 4d77e6c..2dbadf3 100644 --- a/media/com_jedchecker/js/script.js +++ b/media/com_jedchecker/js/script.js @@ -24,28 +24,19 @@ function check(url, rule) { target.html(result); var error = target.find('.alert-danger').length; - if (error) { - sidebar.find('.badge.bg-danger').text(error); - } + sidebar.find('.badge.bg-danger').text(error || ''); var warning = target.find('.alert-warning').length; - if (warning) { - sidebar.find('.badge.bg-warning').text(warning); - } + sidebar.find('.badge.bg-warning').text(warning || ''); var compat = target.find('.alert-secondary').length; - if (compat) { - sidebar.find('.badge.bg-secondary').text(compat); - } + sidebar.find('.badge.bg-secondary').text(compat || ''); var info = target.find('.alert-info').length; - if (info) { - sidebar.find('.badge.bg-info').text(info); - } + sidebar.find('.badge.bg-info').text(info || ''); - if (target.find('.alert-success').length) { - sidebar.find('.badge.bg-success').removeClass("hidden"); - } + var success = target.find('.alert-success').length; + sidebar.find('.badge.bg-success').toggleClass('hidden', !success); sidebar.find('.spinner-border').addClass('hidden'); } From 67f388431548d297dcec22ff8e7257f3e6acb481 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Tue, 9 Mar 2021 23:25:36 +0300 Subject: [PATCH 076/238] add processing of errors in response (timeout, server error, expired session, etc.) --- media/com_jedchecker/js/script.js | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/media/com_jedchecker/js/script.js b/media/com_jedchecker/js/script.js index 2dbadf3..f5ce430 100644 --- a/media/com_jedchecker/js/script.js +++ b/media/com_jedchecker/js/script.js @@ -38,6 +38,18 @@ function check(url, rule) { var success = target.find('.alert-success').length; sidebar.find('.badge.bg-success').toggleClass('hidden', !success); + sidebar.find('.spinner-border').addClass('hidden'); + }, + error: function(xhr, status){ + var sidebar = jQuery('#jed-' + rule); + var target = jQuery('#police-check-result-' + rule); + + target.html('' + status + ': ' + xhr.status + ' ' + xhr.statusText + ''); + + sidebar.find('.badge.bg-danger').text('?'); + sidebar.find('.badge.bg-warning,.badge.bg-secondary,.badge.bg-info').text(''); + sidebar.find('.badge.bg-success').addClass('hidden'); + sidebar.find('.spinner-border').addClass('hidden'); } }); From 03834bfedc98f4d55d06fb6061f84960e5520938 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 25 Feb 2021 11:38:13 +0300 Subject: [PATCH 077/238] display uploading animation --- .../components/com_jedchecker/views/uploads/tmpl/default.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php index e04a44e..265f967 100644 --- a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php +++ b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php @@ -86,11 +86,12 @@ Note: iOS Safari doesn't support file extensions in the accept attribute, so MIM accept="application/zip,application/x-gzip,application/x-compressed,application/x-tar" aria-describedby="extension-upload" aria-label="">
    + From f84495e24b24602ce3302d270e2965cf784f7e3a Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Thu, 25 Feb 2021 11:38:39 +0300 Subject: [PATCH 078/238] change tabs background to bg-light --- .../components/com_jedchecker/views/uploads/tmpl/default.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php index 265f967..2c1faba 100644 --- a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php +++ b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php @@ -159,7 +159,7 @@ Note: iOS Safari doesn't support file extensions in the accept attribute, so MIM $rule = new $class; ?>
    -
    +
    get('title')); ?>
    From 733bcd59376f155f12316c45395d5d6745d21eb1 Mon Sep 17 00:00:00 2001 From: Denis Ryabov Date: Sun, 4 Apr 2021 11:09:07 +0300 Subject: [PATCH 079/238] sync accept attribute with discussion on PR#90 --- .../com_jedchecker/views/uploads/tmpl/default.php | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php index 2c1faba..b5bde71 100644 --- a/administrator/components/com_jedchecker/views/uploads/tmpl/default.php +++ b/administrator/components/com_jedchecker/views/uploads/tmpl/default.php @@ -73,17 +73,8 @@ JFactory::getLanguage()->load('com_jedchecker.sys', JPATH_ADMINISTRATOR);
    - .zip (both Chromium and Firefox) - application/x-gzip => .gz (both Chromium and Firefox), - .tgz (Chromium only) - application/x-compressed => .tgz (Firefox only) - application/x-tar => .tar (both Chromium and Firefox) -Note: iOS Safari doesn't support file extensions in the accept attribute, so MIME types is the only working solution -*/ ?>