diff --git a/accessibility-checker.php b/accessibility-checker.php index 14d8b4058..dd55a623c 100755 --- a/accessibility-checker.php +++ b/accessibility-checker.php @@ -10,7 +10,7 @@ * Plugin Name: Accessibility Checker * Plugin URI: https://a11ychecker.com * Description: Audit and check your website for accessibility before you hit publish. In-post accessibility scanner and guidance. - * Version: 1.41.0 + * Version: 1.42.0 * Requires PHP: 7.4 * Author: Equalize Digital * Author URI: https://equalizedigital.com @@ -36,7 +36,7 @@ // Current plugin version. if ( ! defined( 'EDAC_VERSION' ) ) { - define( 'EDAC_VERSION', '1.41.0' ); + define( 'EDAC_VERSION', '1.42.0' ); } // Current database version. diff --git a/changelog.txt b/changelog.txt index f773c68cd..4b651a8d1 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,5 +1,10 @@ *** Accessibility Checker *** +2026-05-18 - version 1.42.0 +* Updated - add support for role="none" in several of the link and image alt related rules. +* Updated - added support for named anchors as jump links. +* New - added system info checker for compatibility checking of plugins and themes. + 2026-05-13 - version 1.41.0 * Updated - the possible heading rule now accounts for elements with role="heading" appropriately. * Fix - several language translations are now properly detected by WordPress when using them. diff --git a/includes/classes/SystemInfo/SystemInfo.php b/includes/classes/SystemInfo/SystemInfo.php index 72ba82a3b..a79d44499 100644 --- a/includes/classes/SystemInfo/SystemInfo.php +++ b/includes/classes/SystemInfo/SystemInfo.php @@ -20,15 +20,24 @@ class SystemInfo { * @return array> */ public static function get_active_plugins() { - $active_plugins = []; + if ( ! function_exists( 'get_plugin_data' ) ) { + require_once ABSPATH . 'wp-admin/includes/plugin.php'; + } - foreach ( wp_get_active_and_valid_plugins() as $plugin_path ) { - $plugin_data = get_plugin_data( $plugin_path, false, false ); - $active_plugins[] = [ - 'name' => $plugin_data['Name'] ?? '', - 'slug' => self::get_plugin_slug_from_path( $plugin_path ), - 'version' => $plugin_data['Version'] ?? '', - ]; + $active_plugins = []; + $plugins = wp_get_active_and_valid_plugins(); + + if ( is_array( $plugins ) ) { + foreach ( $plugins as $plugin_path ) { + $plugin_data = get_plugin_data( $plugin_path, false, false ); + if ( is_array( $plugin_data ) ) { + $active_plugins[] = [ + 'name' => $plugin_data['Name'] ?? '', + 'slug' => self::get_plugin_slug_from_path( $plugin_path ), + 'version' => $plugin_data['Version'] ?? '', + ]; + } + } } return $active_plugins; diff --git a/package-lock.json b/package-lock.json index cbdab636d..efa294bc5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "accessibility-checker", - "version": "1.41.0", + "version": "1.42.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "accessibility-checker", - "version": "1.41.0", + "version": "1.42.0", "hasInstallScript": true, "license": "GPL-2.0+", "devDependencies": { diff --git a/package.json b/package.json index 64e667ce9..1b7a9ca34 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "accessibility-checker", - "version": "1.41.0", + "version": "1.42.0", "description": "Audit and check your website for accessibility before you hit publish. In-post accessibility scanner and guidance.", "author": "Equalize Digital", "license": "GPL-2.0+", diff --git a/readme.txt b/readme.txt index 565733a7e..31e21529b 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: equalizedigital, alh0319, stevejonesdev Tags: accessibility, EAA, WCAG, ADA, WP accessibility, accessibility scanner Requires at least: 6.7 Tested up to: 7.0 -Stable tag: 1.41.0 +Stable tag: 1.42.0 Requires PHP: 7.4 License: GPL-2.0-or-later License URI: https://www.gnu.org/licenses/gpl-2.0.html @@ -279,6 +279,11 @@ You can report security bugs through the Patchstack Vulnerability Disclosure Pro == Changelog == +2026-05-18 - version 1.42.0 +* Updated - add support for role="none" in several of the link and image alt related rules. +* Updated - added support for named anchors as jump links. +* New - added system info checker for compatibility checking of plugins and themes. + 2026-05-13 - version 1.41.0 * Updated - the possible heading rule now accounts for elements with role="heading" appropriately. * Fix - several language translations are now properly detected by WordPress when using them. diff --git a/tests/phpunit/Admin/SystemInfoTest.php b/tests/phpunit/Admin/SystemInfoTest.php index 3ee51b34e..f45b8a1d9 100644 --- a/tests/phpunit/Admin/SystemInfoTest.php +++ b/tests/phpunit/Admin/SystemInfoTest.php @@ -152,6 +152,32 @@ public function testGetActivePluginsEntriesAreAllStrings() { } } + /** + * Active plugin slugs match WordPress active-and-valid plugin list. + * + * @return void + */ + public function testGetActivePluginsMatchesActiveAndValidPluginList() { + $expected_slugs = []; + $active_paths = wp_get_active_and_valid_plugins(); + + if ( is_array( $active_paths ) ) { + $expected_slugs = array_map( [ SystemInfo::class, 'get_plugin_slug_from_path' ], $active_paths ); + } + + $actual_slugs = array_map( + static function ( $plugin ) { + return is_array( $plugin ) && isset( $plugin['slug'] ) ? $plugin['slug'] : ''; + }, + SystemInfo::get_active_plugins() + ); + + sort( $expected_slugs ); + sort( $actual_slugs ); + + $this->assertSame( $expected_slugs, $actual_slugs ); + } + /** * A non-WP_Theme value returns an empty array. *