refactor(autoload): migrate theme classes to Composer PSR-4

Move 288 types from global AKSRT_* + inc/classes manual requires into
namespace AKSRT\{Domain} under src/AKSRT/, wire composer.json psr-4,
and slim bootstrap to helpers/modules/hooks only. Split multi-class
widget/gateway files, update admin contract audit paths, and document
the layout in ADR/README.
This commit is contained in:
2026-07-17 13:29:22 +08:00
parent 8f349b40fb
commit aaf458af1c
404 changed files with 13602 additions and 7705 deletions
+3 -3
View File
@@ -60,7 +60,7 @@ if (!function_exists('aksrt_single_build_context')) :
);
}
$paid_settings = class_exists('AKSRT_Settings') ? AKSRT_Settings::get_paid_content_settings() : [];
$paid_settings = class_exists('\AKSRT\Settings\Settings') ? \AKSRT\Settings\Settings::get_paid_content_settings() : [];
$paid_display = is_array($paid_settings['display'] ?? null) ? $paid_settings['display'] : [];
$paid_box_position = sanitize_key((string) ($paid_display['box_position'] ?? 'top'));
// Zibll positions: box_top | top | bottom | box_bottom (do not collapse).
@@ -149,10 +149,10 @@ if (!function_exists('aksrt_single_is_docs_page')) :
* Docs fast-path: true when the current post should leave the unified single surface.
*/
function aksrt_single_is_docs_page(int $post_id): bool {
if (!class_exists('AKSRT_Docs_Presenter')) {
if (!class_exists('\AKSRT\Core\DocsPresenter')) {
return false;
}
return (bool) AKSRT_Docs_Presenter::get_instance()->is_docs_page($post_id);
return (bool) \AKSRT\Core\DocsPresenter::get_instance()->is_docs_page($post_id);
}
endif;