Filter: bricks/theme_styles
Filters the array of Theme Styles loaded from the database. This allows you to modify, add, or remove Theme Styles programmatically.
Parameters
Section titled “Parameters”$styles(array): Associative array of Theme Styles, where the key is the style name and the value is an array of style data.
Example usage
Section titled “Example usage”add_filter( 'bricks/theme_styles', function( $styles ) { // Example: Add a default property to all theme styles foreach ( $styles as $key => $style ) { if ( ! isset( $styles[ $key ]['settings']['typography'] ) ) { $styles[ $key ]['settings']['typography'] = [ 'font-size' => '16px' ]; } }
return $styles;} );Was this helpful?
A quick vote and short notes help us improve these docs faster.
Leave a note for us
Thanks for sharing feedback. We're using it to improve these docs.