PluginProbe
Easy Elements for Elementor – Addons & Website Templates / 1.2.1
Easy Elements for Elementor – Addons & Website Templates v1.2.1
1.5.3 1.5.2 1.5.1 1.5.0 1.4.9 1.4.6 1.4.7 1.4.8 1.4.5 1.4.4 1.4.3 1.2.7 1.2.8 1.2.9 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 1.3.7 1.3.8 1.3.9 1.4.0 All 47 releases
← All changes | widgets/button/button.php +11 -7 1.3.01.2.1 View file →
@@ -1,6 +1,5 @@
1 1 <?php
2 -namespace Easyel\EasyElements\Widgets;
3 2 use Elementor\Controls_Manager;
4 3 use Elementor\Widget_Base;
5 4
6 5 if ( ! defined( 'ABSPATH' ) ) {
@@ -7,8 +6,19 @@
7 6 exit;
8 7 }
9 8
10 9 class Easyel_Button_Widget extends \Elementor\Widget_Base {
10 +
11 + public function get_style_depends() {
12 + $handle = 'eel-button-style';
13 + $css_path = plugin_dir_path( __FILE__ ) . 'css/button.min.css';
14 +
15 + if ( ! wp_style_is( $handle, 'registered' ) && file_exists( $css_path ) ) {
16 + wp_register_style( $handle, plugins_url( 'css/button.min.css', __FILE__ ), [], defined( 'WP_DEBUG' ) && WP_DEBUG ? filemtime( $css_path ) : EASYELEMENTS_VER );
17 + }
18 + return [ $handle ];
19 + }
20 +
11 21 public function get_name() {
12 22 return 'eel-button';
13 23 }
14 24
@@ -26,14 +36,8 @@
26 36
27 37 public function get_keywords() {
28 38 return [ 'button', 'link', 'click', 'text' ];
29 39 }
30 -
31 - public function get_style_depends() {
32 - return [
33 - 'eel-button',
34 - ];
35 - }
36 40
37 41 protected function register_controls() {
38 42
39 43 $this->start_controls_section(