WP Manifestindependent plugin directory
manifest / media / wp-light-dark-mode-images

Light and Dark Mode Images

Give the featured image and Image blocks a second version for the other color scheme. Visitors in dark or light mode see the matching image.

★ 0stars

Install

Download source zip No release zip yet

This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/lw-it-solutions/wp-light-dark-mode-images/archive/refs/heads/main.zip
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

Give the featured image and Image blocks a second version for the other color scheme. Visitors in dark or light mode see the matching image.

  • Second featured image in the post sidebar (meta box in the classic editor)
  • Second image for the Image block in its block settings
  • Standard <picture> output with prefers-color-scheme, no JavaScript needed
  • Light or dark as the base scheme
  • Optional selectors for a theme's own light/dark switch

Settings > Media. Requires WordPress 6.5 and PHP 7.4. Details in readme.txt.

License

GPL-2.0-or-later, see LICENSE.