PluginProbe ʕ •ᴥ•ʔ
ShopEngine Elementor WooCommerce Builder Addon – All in One WooCommerce Solution / 4.9.2
ShopEngine Elementor WooCommerce Builder Addon – All in One WooCommerce Solution v4.9.2
4.9.2 4.9.1 4.9.0 2.0.0 2.1.0 2.2.0 2.2.1 2.2.2 2.3.0 2.4.0 2.5.0 2.5.1 3.0.0 3.1.0 3.1.1 4.0.0 4.0.1 4.1.0 4.1.1 4.2.0 4.2.1 4.3.0 4.3.1 4.4.0 4.5.0 4.5.1 4.6.0 4.6.1 4.6.2 4.6.3 4.6.4 4.6.5 4.6.6 4.6.7 4.6.8 4.6.9 4.7.0 4.7.1 4.7.2 4.7.3 4.7.4 4.7.5 4.7.6 4.7.7 4.7.8 4.7.9 4.8.0 4.8.1 4.8.2 4.8.3 4.8.4 4.8.5 4.8.6 4.8.7 4.8.8 4.8.9 trunk 0.1.2-beta 0.1.3-beta 0.1.4-beta 1.0.0 1.1.0 1.1.1 1.1.2 1.1.3 1.2.0 1.2.1 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.4.0 1.4.1 1.5.0 1.5.1 1.6.0 1.6.1 1.7.0 1.8.0 1.8.1 1.9.0
shopengine / compatibility / conflicts / manifest.php
shopengine / compatibility / conflicts Last commit date
manifest.php 5 days ago theme-hooks.php 5 days ago
manifest.php
155 lines
1 <?php
2
3 namespace ShopEngine\Compatibility\Conflicts;
4
5 use ShopEngine\Widgets\Widget_Helper;
6
7 class Manifest {
8
9 public function init() {
10
11 add_action('elementor/element/before_section_start', [$this, 'elementor_editor_conflict'], 10, 2);
12 add_action('elementor/element/before_section_start', function ($element) {
13
14 /**
15 * In woodmart theme image with gallery does not work properly. so temporary fix
16 * Hooks tried are -
17 * elementor/editor/before_enqueue_scripts
18 * elementor/element/before_section_start
19 * elementor/element/after_section_end
20 */
21 wp_enqueue_script('wc-flexslider');
22
23 /**
24 * remove unwanted breadcrumb in shop and archive page
25 */
26 remove_action('woocommerce_before_main_content', 'woocommerce_breadcrumb', 20, 0);
27
28 global $is_used_shopengine_template;
29 if($is_used_shopengine_template) {
30 remove_action('woocommerce_before_single_product', 'woocommerce_output_all_notices', 10);
31 }
32 }, 9000, 1);
33
34
35 // Check if the Yith Delivery Date Plugin Is There
36 if(class_exists('\YITH_Delivery_Date_Shipping_Manager')){
37
38 // They added this action specifically after 2.7.0 version so we need to check if we are using 2.7.0 or higher
39 if ( version_compare( WC()->version, '2.7.0', '>=' ) ) {
40
41 $yith_date_manager = \YITH_Delivery_Date_Shipping_Manager::get_instance();
42
43 // Remove the actual action that used by Yith.
44 remove_action( 'woocommerce_checkout_shipping', array( $yith_date_manager, 'print_delivery_from' ), 20 );
45
46 // Invoked their own method to print delivery from
47 add_action( 'woocommerce_after_order_notes', array( $yith_date_manager, 'print_delivery_from' ), 20 );
48 }
49 }
50
51 // Removed the single product layout from Astra Theme
52 if(is_plugin_active('astra-addon/astra-addon.php')) {
53
54 add_action('wp', function() {
55 if (class_exists('ASTRA_Ext_WooCommerce_Markup')) {
56
57 global $wp_filter;
58
59 // Get the instance of the ASTRA_Ext_WooCommerce_Markup class
60 $astra_instance = null;
61 foreach ($wp_filter['wp']->callbacks as $priority => $filters) {
62 foreach ($filters as $filter) {
63 if (is_array($filter['function']) && is_object($filter['function'][0]) && get_class($filter['function'][0]) === 'ASTRA_Ext_WooCommerce_Markup') {
64 $astra_instance = $filter['function'][0];
65 break 2;
66 }
67 }
68 }
69
70 if ($astra_instance) {
71 remove_action('wp', array($astra_instance, 'woo_single_product_layouts'), 99);
72 }
73 }
74 }, 10);
75 }
76
77
78 // Check if the Unlimited Elements for Elementor Pro plugin is active
79 if (is_plugin_active('unlimited-elements-for-elementor-premium/unlimited-elements-pro.php')) {
80
81 add_action('elementor/init', [$this, 'remove_unlimited_elements_background_hooks'], 999);
82
83 }
84
85 }
86
87 // This function will remove the background overlay hooks added by Unlimited Elements for Elementor Pro plugin
88 public function remove_unlimited_elements_background_hooks() {
89 $hooks = array(
90 'elementor/element/section/section_background_overlay/after_section_end',
91 'elementor/element/container/section_background_overlay/after_section_end',
92 );
93
94 global $wp_filter;
95
96 foreach ($hooks as $hook) {
97 if (empty($wp_filter[$hook]) || empty($wp_filter[$hook]->callbacks)) {
98 continue;
99 }
100
101 foreach ($wp_filter[$hook]->callbacks as $priority => $callbacks) {
102 foreach ($callbacks as $callback) {
103 $function = isset($callback['function']) ? $callback['function'] : null;
104
105 if (!is_array($function) || empty($function[0]) || empty($function[1])) {
106 continue;
107 }
108
109 if (!is_object($function[0])) {
110 continue;
111 }
112
113 if (get_class($function[0]) === 'UniteCreatorElementorIntegrate' && $function[1] === 'onSectionStyleControlsAdd') {
114 remove_action($hook, $function, $priority);
115 }
116 }
117 }
118 }
119 }
120
121 public function elementor_editor_conflict($element, $section_id) {
122
123 $in_editor_mode = \Elementor\Plugin::$instance->editor->is_edit_mode();
124
125 if('shopengine-cross-sells' === $element->get_name() && $in_editor_mode) {
126
127 Theme_Hooks::instance()->theme_conflicts_in_elementor_editor_cross_sells();
128
129 } elseif('shopengine-related' === $element->get_name() && $in_editor_mode) {
130
131 Theme_Hooks::instance()->theme_conflicts_in_elementor_editor_related_products();
132
133 } elseif('shopengine-account-dashboard' === $element->get_name() && $in_editor_mode) {
134
135 Theme_Hooks::instance()->theme_conflicts_my_account_page();
136
137 } elseif('shopengine-cart-table' === $element->get_name() && $in_editor_mode) {
138
139 Theme_Hooks::instance()->theme_conflicts_empty_cart_page();
140
141 } elseif('shopengine-archive-products' === $element->get_name() && $in_editor_mode) {
142
143 Theme_Hooks::instance()->theme_conflicts_in_editor__archive_products_widget();
144
145 } elseif('shopengine-product-tabs' === $element->get_name() && $in_editor_mode) {
146
147 Theme_Hooks::instance()->theme_conflicts_in_editor__product_tabs_widget();
148
149 } elseif('shopengine-up-sells' === $element->get_name() && $in_editor_mode) {
150
151 Theme_Hooks::instance()->theme_conflicts_in_elementor_editor_up_sells();
152 }
153 }
154 }
155