Install
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/carmopereira/carmo-cover-block/archive/refs/heads/main.zipExtends the core Cover block with an ACF background image that replaces the block's background on desktop screens.
Description
This plugin extends the core Gutenberg Cover block, adding an Advanced Custom Fields (ACF) image field control in the editor. When a field is selected, its image is injected as the Cover block's background on desktop screens (min-width: 768px) via a scoped media query, leaving the block's own background untouched on smaller screens.
Requires Advanced Custom Fields to be installed and active.
Installation
- Upload the plugin files to the
/wp-content/plugins/carmo-cover-blockdirectory, or install the plugin through the WordPress plugins screen directly. - Activate the plugin through the 'Plugins' screen in WordPress.
- Make sure Advanced Custom Fields is installed and active.
- Edit a Cover block and select the ACF image field to use as its desktop background.
Frequently Asked Questions
Does this affect all blocks?
No. It only affects blocks of type core/cover.
Do I need Advanced Custom Fields installed?
Yes. The plugin relies on ACF's get_field() to retrieve the background image, and does nothing if ACF is not active.
Changelog
0.2.8
- Set plugin author
0.2.7
- Update Tested up to and Stable tag
0.2.6
- Extend core/cover with ACF background support instead of a custom block
- Inject desktop ACF background via media query, mobile support removed
0.1.0
- Release