| 1 |
<?php |
| 2 |
defined('ABSPATH') || exit; |
| 3 |
|
| 4 |
/** |
| 5 |
* Module Name: Button |
| 6 |
* Description: Display Button content |
| 7 |
*/ |
| 8 |
class TB_Buttons_Module extends Themify_Builder_Component_Module { |
| 9 |
|
| 10 |
public static function get_module_name():string { |
| 11 |
return __('Button', 'themify'); |
| 12 |
} |
| 13 |
|
| 14 |
public static function get_module_icon():string { |
| 15 |
return 'mouse-alt'; |
| 16 |
} |
| 17 |
|
| 18 |
|
| 19 |
public static function get_js_css():array { |
| 20 |
return array( |
| 21 |
'css' => 1 |
| 22 |
); |
| 23 |
} |
| 24 |
|
| 25 |
public static function get_styling_image_fields() : array { |
| 26 |
return [ |
| 27 |
'background_image' => '.module', |
| 28 |
'b_i' => '.module .module-buttons-item a', |
| 29 |
'bic_b_i' => '.module .module-buttons-item em' |
| 30 |
]; |
| 31 |
} |
| 32 |
|
| 33 |
public static function get_translatable_repeatable_fields( $module ) { |
| 34 |
return [ |
| 35 |
'content_button' => [ |
| 36 |
'label' => 'LINE', |
| 37 |
'link' => 'LINK', |
| 38 |
'title' => 'LINE', |
| 39 |
'btn_class' => 'LINE', |
| 40 |
'onclick' => 'LINE' |
| 41 |
] |
| 42 |
]; |
| 43 |
} |
| 44 |
} |