← All changes
|
app/Elementor/Widgets/Controls/ArchiveDescSettings.php
+70
-70
2.1.11
→
1.1.4
View file →
| @@ -1,70 +1,70 @@ | ||
| 1 | -<?php | |
| 2 | -/** | |
| 3 | - * Main ProductDescription class. | |
| 4 | - * | |
| 5 | - * @package RadiusTheme\SB | |
| 6 | - */ | |
| 7 | - | |
| 8 | -namespace RadiusTheme\SB\Elementor\Widgets\Controls; | |
| 9 | - | |
| 10 | -use Elementor\Controls_Manager; | |
| 11 | -use RadiusTheme\SB\Elementor\Helper\ControlHelper; | |
| 12 | - | |
| 13 | -// Do not allow directly accessing this file. | |
| 14 | -if ( ! defined( 'ABSPATH' ) ) { | |
| 15 | - exit( 'This script cannot be accessed directly.' ); | |
| 16 | -} | |
| 17 | - | |
| 18 | -/** | |
| 19 | - * Product Description class | |
| 20 | - */ | |
| 21 | -class ArchiveDescSettings { | |
| 22 | - /** | |
| 23 | - * Widget Field | |
| 24 | - * | |
| 25 | - * @return array | |
| 26 | - */ | |
| 27 | - public static function widget_fields( $widget ) { | |
| 28 | - $fields = [ | |
| 29 | - 'section_style' => [ | |
| 30 | - 'mode' => 'section_start', | |
| 31 | - 'label' => esc_html__( 'Style', 'shopbuilder' ), | |
| 32 | - ], | |
| 33 | - 'typo' => [ | |
| 34 | - 'mode' => 'group', | |
| 35 | - 'type' => 'typography', | |
| 36 | - 'label' => esc_html__( 'Typography', 'shopbuilder' ), | |
| 37 | - 'selector' => $widget->selectors['typo'], | |
| 38 | - ], | |
| 39 | - 'align' => [ | |
| 40 | - 'mode' => 'responsive', | |
| 41 | - 'label' => esc_html__( 'Alignment', 'shopbuilder' ), | |
| 42 | - 'type' => 'choose', | |
| 43 | - 'options' => ControlHelper::alignment(), | |
| 44 | - 'default' => '', | |
| 45 | - 'selectors' => [ | |
| 46 | - $widget->selectors['align'] => 'text-align: {{VALUE}};', | |
| 47 | - ], | |
| 48 | - ], | |
| 49 | - 'text_color' => [ | |
| 50 | - 'label' => esc_html__( 'Text Color', 'shopbuilder' ), | |
| 51 | - 'type' => 'color', | |
| 52 | - 'default' => '', | |
| 53 | - 'selectors' => [ | |
| 54 | - $widget->selectors['text_color'] => 'color: {{VALUE}};', | |
| 55 | - ], | |
| 56 | - ], | |
| 57 | - 'text_shadow' => [ | |
| 58 | - 'mode' => 'group', | |
| 59 | - 'type' => 'text-shadow', | |
| 60 | - 'selector' => $widget->selectors['text_shadow'], | |
| 61 | - ], | |
| 62 | - 'section_style_end' => [ | |
| 63 | - 'mode' => 'section_end', | |
| 64 | - ], | |
| 65 | - ]; | |
| 66 | - return $fields; | |
| 67 | - } | |
| 68 | - | |
| 69 | - | |
| 70 | -} | |
| 1 | +<?php | |
| 2 | +/** | |
| 3 | + * Main ProductDescription class. | |
| 4 | + * | |
| 5 | + * @package RadiusTheme\SB | |
| 6 | + */ | |
| 7 | + | |
| 8 | +namespace RadiusTheme\SB\Elementor\Widgets\Controls; | |
| 9 | + | |
| 10 | +use Elementor\Controls_Manager; | |
| 11 | +use RadiusTheme\SB\Elementor\Helper\ControlHelper; | |
| 12 | + | |
| 13 | +// Do not allow directly accessing this file. | |
| 14 | +if ( ! defined( 'ABSPATH' ) ) { | |
| 15 | + exit( 'This script cannot be accessed directly.' ); | |
| 16 | +} | |
| 17 | + | |
| 18 | +/** | |
| 19 | + * Product Description class | |
| 20 | + */ | |
| 21 | +class ArchiveDescSettings { | |
| 22 | + /** | |
| 23 | + * Widget Field | |
| 24 | + * | |
| 25 | + * @return array | |
| 26 | + */ | |
| 27 | + public static function widget_fields( $widget ) { | |
| 28 | + $fields = [ | |
| 29 | + 'section_style' => [ | |
| 30 | + 'mode' => 'section_start', | |
| 31 | + 'label' => esc_html__( 'Style', 'shopbuilder' ), | |
| 32 | + ], | |
| 33 | + 'typo' => [ | |
| 34 | + 'mode' => 'group', | |
| 35 | + 'type' => 'typography', | |
| 36 | + 'label' => esc_html__( 'Typography', 'shopbuilder' ), | |
| 37 | + 'selector' => $widget->selectors['typo'], | |
| 38 | + ], | |
| 39 | + 'align' => [ | |
| 40 | + 'mode' => 'responsive', | |
| 41 | + 'label' => esc_html__( 'Alignment', 'shopbuilder' ), | |
| 42 | + 'type' => 'choose', | |
| 43 | + 'options' => ControlHelper::alignment(), | |
| 44 | + 'default' => '', | |
| 45 | + 'selectors' => [ | |
| 46 | + $widget->selectors['align'] => 'text-align: {{VALUE}};', | |
| 47 | + ], | |
| 48 | + ], | |
| 49 | + 'text_color' => [ | |
| 50 | + 'label' => esc_html__( 'Text Color', 'shopbuilder' ), | |
| 51 | + 'type' => 'color', | |
| 52 | + 'default' => '', | |
| 53 | + 'selectors' => [ | |
| 54 | + $widget->selectors['text_color'] => 'color: {{VALUE}};', | |
| 55 | + ], | |
| 56 | + ], | |
| 57 | + 'text_shadow' => [ | |
| 58 | + 'mode' => 'group', | |
| 59 | + 'type' => 'text-shadow', | |
| 60 | + 'selector' => $widget->selectors['text_shadow'], | |
| 61 | + ], | |
| 62 | + 'section_style_end' => [ | |
| 63 | + 'mode' => 'section_end', | |
| 64 | + ], | |
| 65 | + ]; | |
| 66 | + return $fields; | |
| 67 | + } | |
| 68 | + | |
| 69 | + | |
| 70 | +} | |