Skip to content

WordPress Plugin to help you optimize your image alternative texts and make your site more accessible.

License

Notifications You must be signed in to change notification settings

goodwp/altinator-wp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Altinator

A WordPress plugin to help you optimize your image alternative texts and make your site more accessible.

Features

  • Media library filters for images with/without alt text
  • Help tab in the media library about alt texts
  • Quick-edit alt texts directly in the media library list view
  • Frontend inspector module to highlight images missing alt text on your site
  • Settings page to enable/disable features and configure modules
  • Extensible via WordPress hooks and filters

Installation

  1. Upload the plugin files to the /wp-content/plugins/altinator directory, or install the plugin through the WordPress plugins screen directly.
  2. Activate the plugin through the 'Plugins' screen in WordPress.
  3. (Optional) Configure the plugin via the "Altinator" settings under Settings > Altinator.

Altinator Plugin Hooks

Actions

  • altinator/boot: Fires after the plugin and all its services are booted. Use this to boot your own service providers/services after Altinator is ready.
  • altinator/init_container: Fires after the DI container is initialized. Allows adding/changing services or providers.
  • altinator/migration: Fires after plugin migrations are run. Params: new version, old version.
  • altinator/activation: Fires after plugin activation code. Param: main plugin instance.
  • altinator/deactivation: Fires after plugin deactivation code. Param: main plugin instance.

Filters

Local Development Environment

The local development environment is based on DDEV.

After the first setup, remove the ##ddev-generated header from the wp-config.php file and change the ddev-include code to

$ddev_settings = __DIR__ . '/wp-config-ddev.php';
if ( getenv( 'IS_DDEV_PROJECT' ) == 'true' && is_readable( $ddev_settings ) ) {
	require_once( $ddev_settings );
}

It is recommended to run all tasks inside the ddev container.

Development Tasks/Scripts

  • PHP code style: composer run phpcs / composer run phpcs:fix
  • PHPStan: composer run phpstan
  • Code quality: composer run code-quality
  • Tests: WP-Browser and Codeception
  • JS/CSS formatting: npm run format
  • JS/CSS build: npm run build
  • Translations: composer run i18n
  • Build plugin zip: composer run build

Releasing

  1. Run linting, phpcs, phpcs:fix + phpstan
  2. Update version
    • in main plugin file headers (/altinator.php)
    • in src/Plugin.php
    • in package.json
    • in composer.json + run ddev composer update -- --lock
    • stable tag in readme.txt
  3. Add changelog entry in readme.txt and CHANGELOG.md
  4. Update "Tested up to" as needed
  5. Run translation updates
  6. Create PR/merge into main (triggers CI jobs)
  7. Create a new release with a new tag in main vX.Y.Z with changelog

License

GPL-3.0-or-later

See Also

Security

If you believe you have found a security vulnerability, please do not create a public issue or post it publicly anywhere else. You can responsibly disclose the problem directly via GitHubs security reporting feature via email to mail at fabiantodt.at

About

WordPress Plugin to help you optimize your image alternative texts and make your site more accessible.

Resources

License

Security policy

Stars

Watchers

Forks