• Resolved Webmazing

    (@webmazing)


    Hi, is there any way to use the bootstrap block spacing for a custom block? We want to output the classes in our custom block.

    Thanks in advance

    • This topic was modified 12 months ago by Webmazing.
Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author kubiq

    (@kubiq)

    Hi,

    sure, eg. when you create ACF block you can just use

    if( isset( $block['tempID'] ) && $block['tempID'] ){
    	$className .= ' bs-' . $block['tempID'];
    }

    or if you use PRO version of this plugin you can also support global spacing

    if( isset( $block['bsGlobalSpacing'] ) && $block['bsGlobalSpacing'] ){
    	$className .= ' ' . $block['bsGlobalSpacing'];
    }
    Thread Starter Webmazing

    (@webmazing)

    Thanks for the very quick reply.

    we have the pro version and the global spacing works and the free version code. Does this also adds the classes for the alignment, display, etc?

    Plugin Author kubiq

    (@kubiq)

    Just add both these things and everything will work… if not let me know ??

    Thread Starter Webmazing

    (@webmazing)

    it works, thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Add spacing to custom block’ is closed to new replies.