<?php
/**
 * WeCodeArt Framework.
 *
 * WARNING: This file is part of the core WeCodeArt Framework. DO NOT edit this file under any circumstances.
 * Please do all modifications in the form of a child theme.
 *
 * @package 	WeCodeArt Framework
 * @subpackage 	Conditional\is_theme_admin
 * @copyright   Copyright (c) 2025, WeCodeArt Framework
 * @since 		5.0.0
 * @version		6.3.7
 */

namespace WeCodeArt\Support\IfSo;

defined( 'ABSPATH' ) || exit;

use WeCodeArt\Config\Interfaces\Conditional;
use function WeCodeArt\Functions\get_prop;

/**
 * Conditional that is only met when in the admin.
 */
class Settings implements Conditional {

	/**
	 * @inheritdoc
	 */
	public function is_met(): bool {
		global $pagenow;

		if( $pagenow === 'themes.php' ) {
			if( get_prop( $_GET, [ 'page' ] ) === 'wecodeart' ) {
				return true;
			}
		}

		return false;
	}
}