Smilia: children's dental clinic website (WordPress theme and plugin)

This commit is contained in:
jimagie committed 2026-10-22 19:36:36 +05:00
commit 4f4b5f2c0a
266 files changed
+16459

No files matched your search

@@ -0,0 +1,47 @@
<?php
namespace Smilia\Core;
defined( 'ABSPATH' ) || exit;
final class Plugin {
private static ?Plugin $instance = null;
public static function instance(): Plugin {
if ( null === self::$instance ) {
self::$instance = new self();
}
return self::$instance;
}
public function register(): void {
add_action( 'init', array( $this, 'load_textdomain' ) );
( new Post_Types() )->register();
( new Meta_Fields() )->register();
( new Settings() )->register();
( new Content() )->register();
( new Blocks() )->register();
( new Booking() )->register();
( new Captcha() )->register();
( new Seo() )->register();
( new Sitemap() )->register();
( new I18n() )->register();
( new Demo_Access() )->register();
}
public function load_textdomain(): void {
load_plugin_textdomain( 'smilia-core', false, dirname( plugin_basename( SMILIA_CORE_FILE ) ) . '/languages' );
}
public static function activate(): void {
( new Post_Types() )->register_types();
flush_rewrite_rules();
Booking::schedule_cleanup();
}
public static function deactivate(): void {
flush_rewrite_rules();
Booking::unschedule_cleanup();
}
}