Border Control
The border control lets you set the following border properties:
- Border width (top/right/bottom/left)
- Background style (top/right/bottom/left)
- Background color (none/solid/double/dotted/dashed)
- Border radius (top/right/bottom/left)
The example below illustrates how to apply a border via the css parameter and how to set border defaults.
class Builder_Element_Prefix_Test extends \Bricks\Element { public function set_controls() { $this->controls['titleBorder'] = [ 'tab' => 'content', 'label' => esc_html__( 'Title border', 'bricks' ), 'type' => 'border', 'css' => [ [ 'property' => 'border', 'selector' => '.prefix-test-title', ], ], 'inline' => true, 'small' => true, 'default' => [ 'width' => [ 'top' => 1, 'right' => 0, 'bottom' => 0, 'left' => 0, ], 'style' => 'solid', 'color' => [ 'hex' => '#ffff00', ], 'radius' => [ 'top' => 1, 'right' => 1, 'bottom' => 1, 'left' => 1, ], ],
]; }}Was this helpful?
A quick vote and short notes help us improve these docs faster.
Leave a note for us
Please do not include passwords, license keys, or personal data. We store submitted notes to improve the docs.
Thanks for sharing feedback. We're using it to improve these docs.