Unlock Hidden Power: 6 Little-Known Ways to Master Custom Block Styles in WordPress

Unlock Hidden Power: 6 Little-Known Ways to Master Custom Block Styles in WordPress
"styles": {
       "blocks": {
           "core/image":{
               "variations": {
                   "red-border":{
                       "border": {
                               "color":"#cf2e2e",
                               "style": "solid",
                               "width": "4px",
                               "radius":"15px"
                       }
                   }
               }
           },

These two code snippets work together because the name used in the register_block_style() function in your functions.php file and the variations’ name arguments in your theme.json file are identical. 

Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28

You May Have Missed