<?php
namespace AIAutoTool\Features\PostExporter;

if ( ! defined( 'ABSPATH' ) ) exit; // Thoát nếu truy cập trực tiếp

/**
 * AI Auto Tool - Post Exporter Feature
 * 
 * @package AIAutoTool\Features\PostExporter
 * @namespace AIAutoTool\Features\PostExporter
 */



// Include the original Post_Exporter_Plugin
require_once dirname(__FILE__) . '/post-exporter-original.php';

// Create namespace wrapper
if (!class_exists('AIAutoTool\\Features\\PostExporter\\PostExporter')) {
    class PostExporter extends \Post_Exporter_Plugin {
        public $active_option_name = 'Post_Exporter_Plugin_active';
        public $icon = '<i class="fa-solid fa-download"></i>';
        
        public function __construct() {
            parent::__construct();
        }
        
        /**
         * Render feature for integrations page
         */
        public function render_feature() {
            $box = new \AutoToolBox(
                $this->icon . ' Post Exporter',
                'Export posts and content',
                admin_url('admin.php?page=aiautotool_integrations'),
                $this->active_option_name,
                $this->active,
                '',
                false
            );
            
            echo $box->generateHTML();
        }
    }
} // End if class_exists
