用户中心 PHP 整包减层:修复 profile 面板映射并模块化上下文组装
This commit is contained in:
@@ -2,19 +2,19 @@
|
||||
|
||||
当前主路径:
|
||||
- 壳层:templates/pages/page-profile.php
|
||||
- 挂载点:header / sidebar / mobile-tabs / panel-* / account-modals / runtime-config
|
||||
- 上下文:inc/helpers/aksrt-user-center.php
|
||||
- aksrt_get_user_center_render_context()
|
||||
- aksrt_user_center_resolve_tabs()
|
||||
- aksrt_capture_user_center_view() (profile → form 映射)
|
||||
- 挂载点:header / sidebar / mobile-tabs / panel / account-modals / runtime-config
|
||||
- 渲染器:inc/helpers/user-center-renderers/profile-*.php
|
||||
- profile 面板内容文件为 profile-form.php
|
||||
|
||||
样式归属:
|
||||
- assets/css/routes/user-center.css
|
||||
- shell.css — 容器/侧栏/内容区/抽屉
|
||||
- credits.css — 余额卡/流水
|
||||
- settings.css — 设置区/邀请面板
|
||||
- responsive.css — 移动端 tabs/断点/a11y
|
||||
- shell.css / credits.css / settings.css / responsive.css
|
||||
- assets/css/routes/profile.css — 共享头区/列表/弹窗
|
||||
|
||||
脚本归属:
|
||||
- assets/js/routes/user-center.js
|
||||
|
||||
旧 uc-* 草稿 partial 与 templates/parts/profile/part-* 拆分残片已删除,勿再引入。
|
||||
-->
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
<?php
|
||||
/** User center comments panel. @package AKSRT */
|
||||
defined('ABSPATH') || exit;
|
||||
$panel = is_array($args['panel'] ?? null) ? $args['panel'] : [];
|
||||
?>
|
||||
<div id="panel-<?php echo esc_attr($panel['key'] ?? 'comments'); ?>" class="dashboard-panel<?php echo !empty($panel['is_active']) ? ' is-active' : ''; ?>" role="tabpanel"<?php echo empty($panel['is_active']) ? ' hidden' : ''; ?> data-panel-loaded="<?php echo !empty($panel['is_loaded']) ? 'true' : 'false'; ?>" data-tab-url="<?php echo esc_url($panel['url'] ?? ''); ?>">
|
||||
<?php echo $panel['html'] ?? ''; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
|
||||
</div>
|
||||
@@ -1,8 +0,0 @@
|
||||
<?php
|
||||
/** User center credits panel. @package AKSRT */
|
||||
defined('ABSPATH') || exit;
|
||||
$panel = is_array($args['panel'] ?? null) ? $args['panel'] : [];
|
||||
?>
|
||||
<div id="panel-<?php echo esc_attr($panel['key'] ?? 'credits'); ?>" class="dashboard-panel<?php echo !empty($panel['is_active']) ? ' is-active' : ''; ?>" role="tabpanel"<?php echo empty($panel['is_active']) ? ' hidden' : ''; ?> data-panel-loaded="<?php echo !empty($panel['is_loaded']) ? 'true' : 'false'; ?>" data-tab-url="<?php echo esc_url($panel['url'] ?? ''); ?>">
|
||||
<?php echo $panel['html'] ?? ''; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
|
||||
</div>
|
||||
@@ -1,8 +0,0 @@
|
||||
<?php
|
||||
/** User center favorites panel. @package AKSRT */
|
||||
defined('ABSPATH') || exit;
|
||||
$panel = is_array($args['panel'] ?? null) ? $args['panel'] : [];
|
||||
?>
|
||||
<div id="panel-<?php echo esc_attr($panel['key'] ?? 'favorites'); ?>" class="dashboard-panel<?php echo !empty($panel['is_active']) ? ' is-active' : ''; ?>" role="tabpanel"<?php echo empty($panel['is_active']) ? ' hidden' : ''; ?> data-panel-loaded="<?php echo !empty($panel['is_loaded']) ? 'true' : 'false'; ?>" data-tab-url="<?php echo esc_url($panel['url'] ?? ''); ?>">
|
||||
<?php echo $panel['html'] ?? ''; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
|
||||
</div>
|
||||
@@ -1,8 +0,0 @@
|
||||
<?php
|
||||
/** User center posts panel. @package AKSRT */
|
||||
defined('ABSPATH') || exit;
|
||||
$panel = is_array($args['panel'] ?? null) ? $args['panel'] : [];
|
||||
?>
|
||||
<div id="panel-<?php echo esc_attr($panel['key'] ?? 'posts'); ?>" class="dashboard-panel<?php echo !empty($panel['is_active']) ? ' is-active' : ''; ?>" role="tabpanel"<?php echo empty($panel['is_active']) ? ' hidden' : ''; ?> data-panel-loaded="<?php echo !empty($panel['is_loaded']) ? 'true' : 'false'; ?>" data-tab-url="<?php echo esc_url($panel['url'] ?? ''); ?>">
|
||||
<?php echo $panel['html'] ?? ''; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
|
||||
</div>
|
||||
@@ -1,8 +0,0 @@
|
||||
<?php
|
||||
/** User center profile panel. @package AKSRT */
|
||||
defined('ABSPATH') || exit;
|
||||
$panel = is_array($args['panel'] ?? null) ? $args['panel'] : [];
|
||||
?>
|
||||
<div id="panel-<?php echo esc_attr($panel['key'] ?? 'profile'); ?>" class="dashboard-panel<?php echo !empty($panel['is_active']) ? ' is-active' : ''; ?>" role="tabpanel"<?php echo empty($panel['is_active']) ? ' hidden' : ''; ?> data-panel-loaded="<?php echo !empty($panel['is_loaded']) ? 'true' : 'false'; ?>" data-tab-url="<?php echo esc_url($panel['url'] ?? ''); ?>">
|
||||
<?php echo $panel['html'] ?? ''; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
|
||||
</div>
|
||||
@@ -1,8 +0,0 @@
|
||||
<?php
|
||||
/** User center settings panel. @package AKSRT */
|
||||
defined('ABSPATH') || exit;
|
||||
$panel = is_array($args['panel'] ?? null) ? $args['panel'] : [];
|
||||
?>
|
||||
<div id="panel-<?php echo esc_attr($panel['key'] ?? 'settings'); ?>" class="dashboard-panel<?php echo !empty($panel['is_active']) ? ' is-active' : ''; ?>" role="tabpanel"<?php echo empty($panel['is_active']) ? ' hidden' : ''; ?> data-panel-loaded="<?php echo !empty($panel['is_loaded']) ? 'true' : 'false'; ?>" data-tab-url="<?php echo esc_url($panel['url'] ?? ''); ?>">
|
||||
<?php echo $panel['html'] ?? ''; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
|
||||
</div>
|
||||
Reference in New Issue
Block a user