<?php
/**
 * Plugin Name:       Hulk Account Pages for WooCommerce
 * Plugin URI:        https://hulkplugins.com/product/hulk-account-pages-for-woocommerce
 * Description:       Easily add and manage pages in the "My Account" section of your WooCommerce store.
 * Author:            HulkPlugins
 * Author URI:        https://hulkplugins.com
 * License:           GPL v2 or later
 * License URI:       https://www.gnu.org/licenses/gpl-2.0.html
 * Text Domain:       hulk-account-pages-for-woocommerce
 * Domain Path:       /languages
 * Version:           1.0.0
 * Requires PHP:      7.4
 * Requires at least: 6.2
 * Requires Plugins:  woocommerce
 *
 * @package         HulkPlugins\Woo\AccountPages
 */

namespace HulkPlugins\Woo\AccountPages;

use HulkPlugins\Woo\AccountPages\Admin\Controllers\AccountPageLimitNotice;
use HulkPlugins\Woo\AccountPages\Admin\Controllers\AccountPageMetaBoxClassicController;
use HulkPlugins\Woo\AccountPages\Admin\Controllers\AccountPageMetaBoxController;
use HulkPlugins\Woo\AccountPages\Admin\Controllers\AccountPagesController;
use HulkPlugins\Woo\AccountPages\Admin\Controllers\PluginController;
use HulkPlugins\Woo\AccountPages\Frontend\Controllers\WooMyAccountController;

defined( 'ABSPATH' ) || exit;

if ( function_exists( 'HulkPlugins\Woo\AccountPages\hulk_woo_ap_fs' ) ) {
	hulk_woo_ap_fs()->set_basename( false, __FILE__ );
} else {
	// Composer autoload
	require_once plugin_dir_path( __FILE__ ) . 'vendor/autoload.php';

	// Freemius
	require_once plugin_dir_path( __FILE__ ) . 'freemius.php';

	// Constants
	require_once plugin_dir_path( __FILE__ ) . 'constants.php';

	// Set the activation hook for a plugin.
	register_activation_hook( __FILE__, [ PluginController::class, 'activate' ] );

	PluginController::getInstance()->init_hooks();
	AccountPagesController::getInstance()->init_hooks();
	AccountPageMetaBoxController::getInstance()->init_hooks();
	AccountPageMetaBoxClassicController::getInstance()->init_hooks();
	WooMyAccountController::getInstance()->init_hooks();
	AccountPageLimitNotice::getInstance()->init_hooks();
}
