Created
June 24, 2021 01:43
-
-
Save justintadlock/694d9e71b1fe3bf0036b919b8592b43a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$block_styles = [ | |
'core/button' => [ | |
'fill-white' => __( 'Fill White', 'frost' ), | |
'outline-white' => __( 'Outline White', 'frost' ) | |
] | |
]; | |
foreach ( $block_styles as $block => $styles ) { | |
foreach ( $styles as $name => $label ) { | |
register_block_style( $block, [ | |
'name' => $name, | |
'label' => $label | |
] ); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment