| @@ -1,47 +1,47 @@ | ||
| 1 | -<?php | |
| 2 | - | |
| 3 | -namespace UltimateStoreKit\Includes; | |
| 4 | - | |
| 5 | -use UltimateStoreKit\Admin\ModuleService; | |
| 6 | - | |
| 7 | -if (!defined('ABSPATH')) exit; // Exit if accessed directly | |
| 8 | - | |
| 9 | -class Pro_Widget_Map | |
| 10 | -{ | |
| 11 | - | |
| 12 | - public function get_pro_widget_map() | |
| 13 | - { | |
| 14 | - | |
| 15 | - $arr_obj = ModuleService::get_widget_settings( | |
| 16 | - function ($settings) { | |
| 17 | - $core_widgets = $settings['settings_fields']['ultimate_store_kit_active_modules']; | |
| 18 | - | |
| 19 | - $arr = []; | |
| 20 | - | |
| 21 | - foreach ($core_widgets as $key => $widget) { | |
| 22 | - | |
| 23 | - if ('pro' == $widget['widget_type']) { | |
| 24 | - | |
| 25 | - $ar = [ | |
| 26 | - 'categories' => ['ultimate-store-kit-pro'], | |
| 27 | - 'name' => $widget['name'], | |
| 28 | - 'title' => $widget['label'], | |
| 29 | - 'icon' => 'usk-icon-' . $widget['name'] . ' bdt-pro-unlock-icon', | |
| 30 | - 'action_button' => [ | |
| 31 | - 'classes' => ['elementor-button', 'elementor-button-success'], | |
| 32 | - 'text' => esc_html__('See it in Action', 'ultimate-store-kit'), | |
| 33 | - 'url' => esc_url($widget['demo_url']) | |
| 34 | - ] | |
| 35 | - ]; | |
| 36 | - | |
| 37 | - array_push($arr, $ar); | |
| 38 | - } | |
| 39 | - } | |
| 40 | - | |
| 41 | - return $arr; | |
| 42 | - } | |
| 43 | - ); | |
| 44 | - | |
| 45 | - return $arr_obj; | |
| 46 | - } | |
| 47 | -} | |
| 1 | +<?php | |
| 2 | + | |
| 3 | +namespace UltimateStoreKit\Includes; | |
| 4 | + | |
| 5 | +use UltimateStoreKit\Admin\ModuleService; | |
| 6 | + | |
| 7 | +if (!defined('ABSPATH')) exit; // Exit if accessed directly | |
| 8 | + | |
| 9 | +class Pro_Widget_Map | |
| 10 | +{ | |
| 11 | + | |
| 12 | + public function get_pro_widget_map() | |
| 13 | + { | |
| 14 | + | |
| 15 | + $arr_obj = ModuleService::get_widget_settings( | |
| 16 | + function ($settings) { | |
| 17 | + $core_widgets = $settings['settings_fields']['ultimate_store_kit_active_modules']; | |
| 18 | + | |
| 19 | + $arr = []; | |
| 20 | + | |
| 21 | + foreach ($core_widgets as $key => $widget) { | |
| 22 | + | |
| 23 | + if ('pro' == $widget['widget_type']) { | |
| 24 | + | |
| 25 | + $ar = [ | |
| 26 | + 'categories' => ['ultimate-store-kit-pro'], | |
| 27 | + 'name' => $widget['name'], | |
| 28 | + 'title' => $widget['label'], | |
| 29 | + 'icon' => 'usk-icon-' . $widget['name'] . ' bdt-pro-unlock-icon', | |
| 30 | + 'action_button' => [ | |
| 31 | + 'classes' => ['elementor-button', 'elementor-button-success'], | |
| 32 | + 'text' => esc_html__('See it in Action', 'ultimate-store-kit'), | |
| 33 | + 'url' => esc_url($widget['demo_url']) | |
| 34 | + ] | |
| 35 | + ]; | |
| 36 | + | |
| 37 | + array_push($arr, $ar); | |
| 38 | + } | |
| 39 | + } | |
| 40 | + | |
| 41 | + return $arr; | |
| 42 | + } | |
| 43 | + ); | |
| 44 | + | |
| 45 | + return $arr_obj; | |
| 46 | + } | |
| 47 | +} | |