create-block-theme/includes/class-create-block-theme.php
Vicente Canales 9ff52eb6cc
Remove font management (#595)
* Remove font management code

Since the Font Management page is on its way out via deprecation, we
should remove the js code related to it.

* lint: Add missing dependency to useSelect

* Remove php files

* remove references to index.js and php files

* remove font library react app

* remove tests & data

* remove demo text input

* Removed some unused resources

* Returned the font management portion still needed

* removed unused utility functions and their unit tests (leaving a sample unit test in its place rather than dismantling the unit tests

* Returned create-panel to pre-fixed days

---------

Co-authored-by: Jason Crist <jcrist@pbking.com>
2024-04-25 14:17:31 -04:00

74 lines
1.7 KiB
PHP

<?php
/**
* The core Create Block Theme plugin class.
*
* @since 0.0.2
* @package Create_Block_Theme
* @subpackage Create_Block_Theme/includes
* @author WordPress.org
*/
#[AllowDynamicProperties]
class Create_Block_Theme {
/**
* Define the core functionality of the plugin.
*
* @since 0.0.2
*/
public function __construct() {
$this->load_dependencies();
$this->define_admin_hooks();
}
/**
* Load the required dependencies for this plugin.
*
* @since 0.0.2
* @access private
*/
private function load_dependencies() {
/**
* The class responsible for orchestrating the actions and filters of the
* core plugin.
*/
require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-create-block-theme-loader.php';
/**
* The class responsible for defining all actions that occur in the admin area.
*/
require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/class-create-theme.php';
require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/wp-org-theme-directory.php';
require_once plugin_dir_path( dirname( __FILE__ ) ) . 'includes/class-create-block-theme-api.php';
$this->loader = new Create_Block_Theme_Loader();
}
/**
* Register all of the hooks related to the admin area functionality
* of the plugin.
*
* @since 0.0.2
* @access private
*/
private function define_admin_hooks() {
$plugin_admin = new Create_Block_Theme_Admin();
$wp_theme_directory = new WP_Theme_Directory();
$plugin_api = new Create_Block_Theme_API();
}
/**
* Run the loader to execute all of the hooks with WordPress.
*
* @since 0.0.2
*/
public function run() {
$this->loader->run();
}
}