Block Style Modifiers is a simple WordPress plugin that allows you to add multiple block styles to Gutenberg blocks.
Style Modifiers are additive CSS classes that:
- Can be applied in addition to a Block Style
- Can be selected multiple at the same time
- Support both checkbox (non-exclusive) and radio (exclusive) behavior per category
- Are predefined and documented by themes or plugins
- Preserve class order, allowing advanced CSS control
Category Behavior
Style modifiers are organized into categories with two behaviors:
- Non-exclusive categories (checkbox): Multiple modifiers can be selected simultaneously (default:
exclusive: false)
- Exclusive categories (radio): Only one modifier from the category can be selected at a time (
exclusive: true)
Registering Categories
Categories are registered independently using
block_style_modifiers_register_category() before any modifiers that belong to them. Modifiers then reference the category by its slug (string).
block_style_modifiers_register_category( $slug, $args )
$slug - Language-independent identifier for grouping (required, first argument)
label - Translatable UI label (required)
description - Optional category description
exclusive - Boolean flag for radio behavior (default: false)
1.0.8
- Added:
block_style_modifiers_register_category() function for registering categories independently
- Added: Custom categories and custom modifiers can now be saved and loaded from the database
- Changed: Category registration is now a two-step process — register the category first, then reference it by slug string in
block_style_modifiers_register_style()
- Breaking: Category field in
block_style_modifiers_register_style() is now a slug string, not an object
- Updated: Documentation with new two-step registration examples
1.0.7
- Added: 5 new animation types (Slide Down, Slide Left, Slide Right, Rotate In, Flip In X)
- Added: 4 new hover effects (Shake, Brighten, Darken, Blur to Focus)
- Improved: Architecture - Animations now only apply to wrapper blocks (Group, Row, Stack, etc.)
- Improved: Architecture - Hover effects now only apply to content blocks (Image, Cover, Media & Text)
- Fixed: CSS property conflicts between animations and hover effects
- Fixed: Grayscale effect renamed to "Grayscale to Color on Hover" for clarity
- Removed: Overlay hover effect (redundant with Darken effect)
- Performance: Optimized will-change properties for better GPU acceleration
- Accessibility: All new effects respect prefers-reduced-motion
1.0.6
- Added: Structured category object support (slug, label, description, exclusive)
- Added: Exclusive category behavior (radio selection within categories)
- Added: Non-exclusive category behavior (checkbox selection - default)
- Breaking: Category must now be a structured object (string format no longer supported)
- Updated: Documentation with structured category examples
- Added: Default modifiers
1.0.5
- Added: Structured category object support (slug, label, description, exclusive)
- Added: Exclusive category behavior (radio selection within categories)
- Added: Non-exclusive category behavior (checkbox selection - default)
- Breaking: Category must now be a structured object (string format no longer supported)
- Updated: Documentation with structured category examples
- Updated: Block Style Modifier Pack with theme-independent default modifiers
- Improved: Category-based grouping and selection UI
1.0.4
Updated: readme.txt
1.0.3
Updated: readme.txt
1.0.2
Updated: readme.txt
1.0.1
- Added: Source code section in readme.
- Escaped: $inline_style variable to prevent potential security issues.
1.0.0
- Initial release of Block Style Modifiers.