<?php
/**
 * Recommended plugins for Asthir
 */

function asthir_magical_plugins($plugins) {
    $theme_plugins = array(
        'magical-posts-display' => array(
            'name'        => __('Posts Display', 'asthir'),
            'slug'        => 'magical-posts-display',
            'file'        => 'magical-posts-display/magical-posts-display.php',
            'description' => __('Display posts in beautiful layouts.', 'asthir'),
            'category'    => 'Content Display',
            'essential'    => false,
            'featured'    => true,
            'is_local'    => false,
        ),
        'magical-addons-for-elementor' => array(
            'name'        => __('Magical Addons', 'asthir'),
            'slug'        => 'magical-addons-for-elementor',
            'file'        => 'magical-addons-for-elementor/magical-addons-for-elementor.php',
            'description' => __('Premium quality addons for Elementor page builder.', 'asthir'),
            'category'    => 'Page Builder',
            'essential'    => false,
            'featured'    => true,
            'is_local'    => false,
        ),
        'gallery-box' => array(
            'name'        => __('Gallery Box', 'asthir'),
            'slug'        => 'gallery-box',
            'file'        => 'gallery-box/gallery-box.php',
            'description' => __('Beautiful gallery and lightbox plugin.', 'asthir'),
            'category'    => 'Media',
            'essential'    => false,
            'featured'    => true,
            'is_local'    => false,
        ),
        'click-to-top' => array(
            'name'        => __('Click To Top', 'asthir'),
            'slug'        => 'click-to-top',
            'file'        => 'click-to-top/click-to-top.php',
            'description' => __('One-click scroll to top button.', 'asthir'),
            'category'    => 'Utility',
            'essential'    => false,
            'featured'    => true,
            'is_local'    => false,
        ),
        'easy-share-solution' => array(
            'name'        => __('Easy Share', 'asthir'),
            'slug'        => 'easy-share-solution',
            'file'        => 'easy-share-solution/easy-share-solution.php',
            'description' => __('Easily add social sharing buttons.', 'asthir'),
            'category'    => 'Utility',
            'essential'    => false,
            'featured'    => true,
            'is_local'    => false,
        ),
        'wp-edit-password-protected' => array(
            'name'        => __('Password Protected', 'asthir'),
            'slug'        => 'wp-edit-password-protected',
            'file'        => 'wp-edit-password-protected/wp-edit-password-protected.php',
            'description' => __('Manage password protection.', 'asthir'),
            'category'    => 'Security',
            'essential'    => false,
            'featured'    => true,
            'is_local'    => false,
        ),
    );

    if (in_array('woocommerce/woocommerce.php', apply_filters('active_plugins', get_option('active_plugins')))) {
        $theme_plugins['magical-products-display'] = array(
            'name'        => __('Magical Products Display', 'asthir'),
            'slug'        => 'magical-products-display',
            'file'        => 'magical-products-display/magical-products-display.php',
            'description' => __('Display WooCommerce products in beautiful layouts.', 'asthir'),
            'category'    => 'eCommerce',
            'essential'    => false,
            'featured'    => true,
            'is_local'    => false,
        );
    }

    return array_merge($plugins, $theme_plugins);
}
add_filter('magical_plugin_activation_recommended_plugins', 'asthir_magical_plugins');
