用户域一次性收口:统一公开主页资源归属并折叠作者页双路径
把 uh-forum 样式收进 user-home 路由、author.php 收成 301 回退、公开主页脚本以 author.js 为唯一实现,并去掉 enqueue/body class 中的 is_author 分叉。
This commit is contained in:
@@ -19,135 +19,6 @@
|
||||
color: var(--c-primary, #1890ff);
|
||||
}
|
||||
|
||||
/* ── §7.9 Forum user page tabs ── */
|
||||
|
||||
.uh-forum__subtabs {
|
||||
display: flex;
|
||||
gap: 4px;
|
||||
margin-bottom: 16px;
|
||||
padding-bottom: 12px;
|
||||
border-bottom: 1px solid var(--c-border, #e8e8e8);
|
||||
}
|
||||
|
||||
.uh-forum__subtab {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
padding: 6px 14px;
|
||||
border-radius: var(--radius-pill, 999px);
|
||||
font-size: 13px;
|
||||
color: var(--c-text-3, #999);
|
||||
text-decoration: none;
|
||||
transition: all .2s;
|
||||
}
|
||||
|
||||
.uh-forum__subtab:hover {
|
||||
color: var(--c-text-1, #333);
|
||||
background: var(--c-fill-1, #f5f5f5);
|
||||
}
|
||||
|
||||
.uh-forum__subtab.is-active {
|
||||
background: var(--c-primary, #1890ff);
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.uh-forum__subtab-count {
|
||||
font-size: 11px;
|
||||
opacity: .7;
|
||||
}
|
||||
|
||||
.uh-forum__list {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.uh-forum__item {
|
||||
padding: 12px 0;
|
||||
border-bottom: 1px solid var(--c-border-light, #f5f5f5);
|
||||
}
|
||||
|
||||
.uh-forum__item:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
|
||||
.uh-forum__item-title {
|
||||
display: block;
|
||||
font-size: 15px;
|
||||
font-weight: 500;
|
||||
color: var(--c-text-1, #333);
|
||||
text-decoration: none;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
|
||||
.uh-forum__item-title:hover {
|
||||
color: var(--c-primary, #1890ff);
|
||||
}
|
||||
|
||||
.uh-forum__item-meta {
|
||||
display: flex;
|
||||
gap: 12px;
|
||||
font-size: 12px;
|
||||
color: var(--c-text-3, #999);
|
||||
}
|
||||
|
||||
.uh-forum__item-meta i {
|
||||
margin-right: 3px;
|
||||
}
|
||||
|
||||
.uh-forum__section-title {
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
color: var(--c-text-2, #666);
|
||||
margin: 16px 0 10px;
|
||||
padding-bottom: 6px;
|
||||
border-bottom: 1px solid var(--c-border-light, #f5f5f5);
|
||||
}
|
||||
|
||||
.uh-forum__section-title i {
|
||||
margin-right: 4px;
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
.uh-forum__plate-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
|
||||
gap: 10px;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.uh-forum__plate-card {
|
||||
display: block;
|
||||
padding: 12px;
|
||||
border: 1px solid var(--c-border, #e8e8e8);
|
||||
border-radius: var(--radius, 6px);
|
||||
text-decoration: none;
|
||||
transition: border-color .2s, box-shadow .2s;
|
||||
}
|
||||
|
||||
.uh-forum__plate-card:hover {
|
||||
border-color: var(--c-primary, #1890ff);
|
||||
box-shadow: 0 2px 8px rgba(0, 0, 0, .06);
|
||||
}
|
||||
|
||||
.uh-forum__plate-name {
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
color: var(--c-text-1, #333);
|
||||
margin-bottom: 6px;
|
||||
}
|
||||
|
||||
.uh-forum__plate-stats {
|
||||
display: flex;
|
||||
gap: 10px;
|
||||
font-size: 12px;
|
||||
color: var(--c-text-3, #999);
|
||||
}
|
||||
|
||||
.uh-forum__pagination {
|
||||
margin-top: 16px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
/* ── §7.3 Hidden content block [aksrt_hide] ── */
|
||||
|
||||
.aksrt-forum-hide {
|
||||
|
||||
+117
-23
@@ -559,36 +559,130 @@
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.aksrt-user-home .uh-forum__section-head {
|
||||
/* User-home forum tab (owned by public user home route) */
|
||||
.aksrt-user-home .uh-forum__subtabs {
|
||||
display: flex;
|
||||
align-items: flex-start;
|
||||
justify-content: space-between;
|
||||
gap: 16px;
|
||||
margin-bottom: 18px;
|
||||
padding-bottom: 14px;
|
||||
border-bottom: 1px solid var(--color-line-soft, rgba(0,0,0,0.06));
|
||||
gap: 4px;
|
||||
margin-bottom: 16px;
|
||||
padding-bottom: 12px;
|
||||
border-bottom: 1px solid var(--c-border, #e8e8e8);
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__section-title-main {
|
||||
margin: 0 0 6px;
|
||||
font-size: 20px;
|
||||
color: var(--color-ink);
|
||||
.aksrt-user-home .uh-forum__subtab {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
padding: 6px 14px;
|
||||
border-radius: var(--radius-pill, 999px);
|
||||
font-size: 13px;
|
||||
color: var(--c-text-3, #999);
|
||||
text-decoration: none;
|
||||
transition: all .2s;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__section-desc {
|
||||
margin: 0;
|
||||
color: var(--color-ink-3);
|
||||
.aksrt-user-home .uh-forum__subtab:hover {
|
||||
color: var(--c-text-1, #333);
|
||||
background: var(--c-fill-1, #f5f5f5);
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__subtab.is-active {
|
||||
background: var(--c-primary, #1890ff);
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__subtab-count {
|
||||
font-size: 11px;
|
||||
opacity: .7;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__list {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__item {
|
||||
padding: 12px 0;
|
||||
border-bottom: 1px solid var(--c-border-light, #f5f5f5);
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__item:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__item-title {
|
||||
display: block;
|
||||
font-size: 15px;
|
||||
font-weight: 500;
|
||||
color: var(--c-text-1, #333);
|
||||
text-decoration: none;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__item-title:hover {
|
||||
color: var(--c-primary, #1890ff);
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__item-meta {
|
||||
display: flex;
|
||||
gap: 12px;
|
||||
font-size: 12px;
|
||||
color: var(--c-text-3, #999);
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__item-meta i {
|
||||
margin-right: 3px;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__section-title {
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
color: var(--c-text-2, #666);
|
||||
margin: 16px 0 10px;
|
||||
padding-bottom: 6px;
|
||||
border-bottom: 1px solid var(--c-border-light, #f5f5f5);
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__section-title i {
|
||||
margin-right: 4px;
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__section-link {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
padding: 8px 14px;
|
||||
border-radius: 999px;
|
||||
background: var(--surface-2);
|
||||
color: var(--color-ink-2);
|
||||
.aksrt-user-home .uh-forum__plate-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
|
||||
gap: 10px;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__plate-card {
|
||||
display: block;
|
||||
padding: 12px;
|
||||
border: 1px solid var(--c-border, #e8e8e8);
|
||||
border-radius: var(--radius, 6px);
|
||||
text-decoration: none;
|
||||
transition: border-color .2s, box-shadow .2s;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__plate-card:hover {
|
||||
border-color: var(--c-primary, #1890ff);
|
||||
box-shadow: 0 2px 8px rgba(0, 0, 0, .06);
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__plate-name {
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
color: var(--c-text-1, #333);
|
||||
margin-bottom: 6px;
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__plate-stats {
|
||||
display: flex;
|
||||
gap: 10px;
|
||||
font-size: 12px;
|
||||
color: var(--c-text-3, #999);
|
||||
}
|
||||
|
||||
.aksrt-user-home .uh-forum__pagination {
|
||||
margin-top: 16px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
+3
-2
@@ -1,7 +1,8 @@
|
||||
/**
|
||||
* AKSRT Author Page
|
||||
* AKSRT Public User Home runtime
|
||||
*
|
||||
* Handles public author dashboard tabs and profile cover uploads.
|
||||
* Handles public user-home dashboard tabs and cover uploads.
|
||||
* Loaded on /user/{nicename}/ (author archives 301-redirect here).
|
||||
*
|
||||
* @package AKSRT
|
||||
*/
|
||||
|
||||
@@ -1,70 +1,10 @@
|
||||
/**
|
||||
* AKSRT User Home — 公开用户主页专属脚本
|
||||
* Deprecated path.
|
||||
*
|
||||
* 负责公开主页 Tab 切换和 URL 同步。
|
||||
* Public user-home tabs/cover are handled by assets/js/author.js
|
||||
* (enqueued as aksrt-author on profile/user-home routes).
|
||||
* This file intentionally does nothing to avoid double-binding.
|
||||
*/
|
||||
|
||||
(function() {
|
||||
(function () {
|
||||
'use strict';
|
||||
|
||||
function initUserHomeTabs() {
|
||||
var tabContainer = document.querySelector('.dashboard--public .dashboard-tabs');
|
||||
if (!tabContainer) return;
|
||||
|
||||
var tabs = tabContainer.querySelectorAll('[data-tab]');
|
||||
var panels = {};
|
||||
var defaultTab = tabs.length ? tabs[0].getAttribute('data-tab') : 'posts';
|
||||
|
||||
tabs.forEach(function(tab) {
|
||||
var name = tab.getAttribute('data-tab');
|
||||
var panel = document.getElementById('panel-' + name);
|
||||
if (panel) {
|
||||
panels[name] = { tab: tab, panel: panel };
|
||||
}
|
||||
});
|
||||
|
||||
function switchTo(name) {
|
||||
if (!panels[name]) name = defaultTab;
|
||||
|
||||
Object.keys(panels).forEach(function(key) {
|
||||
var active = key === name;
|
||||
panels[key].tab.classList.toggle('is-active', active);
|
||||
panels[key].tab.setAttribute('aria-selected', active ? 'true' : 'false');
|
||||
panels[key].panel.classList.toggle('is-active', active);
|
||||
panels[key].panel.hidden = !active;
|
||||
});
|
||||
}
|
||||
|
||||
function tabFromUrl() {
|
||||
var m = window.location.search.match(/[?&]tab=([^&]+)/);
|
||||
return m ? decodeURIComponent(m[1]) : defaultTab;
|
||||
}
|
||||
|
||||
function updateUrl(name) {
|
||||
if (!window.history.replaceState) return;
|
||||
var u = new URL(window.location);
|
||||
if (name === defaultTab) {
|
||||
u.searchParams.delete('tab');
|
||||
} else {
|
||||
u.searchParams.set('tab', name);
|
||||
}
|
||||
window.history.replaceState({}, '', u);
|
||||
}
|
||||
|
||||
tabs.forEach(function(tab) {
|
||||
tab.addEventListener('click', function() {
|
||||
var name = this.getAttribute('data-tab');
|
||||
switchTo(name);
|
||||
updateUrl(name);
|
||||
});
|
||||
});
|
||||
|
||||
switchTo(tabFromUrl());
|
||||
}
|
||||
|
||||
if (document.readyState === 'loading') {
|
||||
document.addEventListener('DOMContentLoaded', initUserHomeTabs);
|
||||
} else {
|
||||
initUserHomeTabs();
|
||||
}
|
||||
})();
|
||||
|
||||
+17
-122
@@ -1,136 +1,31 @@
|
||||
<?php
|
||||
/**
|
||||
* Author Archive Template — 作者归档页
|
||||
* Author archive fallback.
|
||||
*
|
||||
* 渲染 /author/{nicename}/ 的完整作者归档页面:
|
||||
* - 作者 Hero 区(头图、头像、身份、统计、操作按钮)
|
||||
* - 作者文章列表(WordPress 主循环)
|
||||
* - 可扩展挂载点:aksrt_author_before_content / aksrt_author_after_content
|
||||
*
|
||||
* 数据聚合复用 aksrt_get_user_dashboard_view(),与 page-user-home.php 同源。
|
||||
* Canonical public profile is /user/{nicename}/ (page-user-home.php).
|
||||
* class-aksrt-user.php already 301-redirects is_author() there; this file
|
||||
* remains only as a last-resort template if rewrite/redirect is bypassed.
|
||||
*
|
||||
* @package AKSRT
|
||||
*/
|
||||
|
||||
defined('ABSPATH') || exit;
|
||||
|
||||
global $wp_query;
|
||||
$author_id = (int) get_queried_object_id();
|
||||
if (!$author_id) {
|
||||
$author_id = (int) get_query_var('author');
|
||||
}
|
||||
|
||||
$author_id = (int) get_query_var('author');
|
||||
$author = $author_id ? get_userdata($author_id) : null;
|
||||
|
||||
if (!$author || is_wp_error($author)) {
|
||||
wp_safe_redirect(home_url('/'));
|
||||
$user = $author_id ? get_userdata($author_id) : null;
|
||||
if ($user instanceof WP_User && function_exists('aksrt_get_user_home_url')) {
|
||||
wp_safe_redirect(aksrt_get_user_home_url($user), 301);
|
||||
exit;
|
||||
}
|
||||
|
||||
get_header();
|
||||
if ($user instanceof WP_User) {
|
||||
wp_safe_redirect(home_url('/user/' . trailingslashit($user->user_nicename)), 301);
|
||||
exit;
|
||||
}
|
||||
|
||||
$user_id = (int) $author->ID;
|
||||
$dashboard = function_exists('aksrt_get_user_dashboard_view')
|
||||
? aksrt_get_user_dashboard_view($user_id, ['viewer_id' => get_current_user_id()])
|
||||
: [];
|
||||
|
||||
$user_home_settings = class_exists('AKSRT_Settings')
|
||||
? AKSRT_Settings::get_user_home_settings()
|
||||
: [
|
||||
'tabs' => ['posts', 'comments', 'favorites'],
|
||||
'sidebar' => true,
|
||||
'cover' => true,
|
||||
'follow' => true,
|
||||
'posts_per_page' => 10,
|
||||
];
|
||||
|
||||
require_once AKSRT_DIR . '/templates/parts/user-shared-helpers.php';
|
||||
?>
|
||||
|
||||
<main id="main-content" class="site-main container content-shell content-shell--stream aksrt-author-page" tabindex="-1">
|
||||
<div class="content-wrap">
|
||||
<div class="content-layout<?php echo !empty($user_home_settings['sidebar']) ? '' : ' content-layout--no-sidebar'; ?> aksrt-author-page__layout">
|
||||
<div class="content-layout__primary">
|
||||
|
||||
<?php
|
||||
get_template_part('templates/parts/user/author-hero', null, [
|
||||
'user' => $author,
|
||||
'dashboard' => $dashboard,
|
||||
'user_home_settings' => $user_home_settings,
|
||||
'is_author_page' => true,
|
||||
]);
|
||||
?>
|
||||
|
||||
<?php do_action('aksrt_author_before_content', $user_id); ?>
|
||||
|
||||
<div class="aksrt-author-page__content aksrt-theme-box">
|
||||
<div class="aksrt-author-page__content-header">
|
||||
<h2 class="aksrt-author-page__section-title">
|
||||
<i class="fas fa-file-alt" aria-hidden="true"></i>
|
||||
<?php esc_html_e('发布的文章', 'aksrt'); ?>
|
||||
</h2>
|
||||
</div>
|
||||
|
||||
<?php if (have_posts()) : ?>
|
||||
<div class="aksrt-author-page__posts">
|
||||
<?php while (have_posts()) : the_post(); ?>
|
||||
<?php get_template_part('templates/parts/content', 'profile-list-item', [
|
||||
'action' => [
|
||||
'type' => 'view',
|
||||
'url' => get_permalink(),
|
||||
'label' => __('阅读', 'aksrt'),
|
||||
],
|
||||
]); ?>
|
||||
<?php endwhile; ?>
|
||||
</div>
|
||||
|
||||
<?php
|
||||
$total_pages = (int) $wp_query->max_num_pages;
|
||||
$current_page = max(1, (int) get_query_var('paged'));
|
||||
if ($total_pages > 1) :
|
||||
?>
|
||||
<div class="aksrt-author-page__pagination">
|
||||
<?php
|
||||
echo paginate_links([
|
||||
'total' => $total_pages,
|
||||
'current' => $current_page,
|
||||
'mid_size' => 2,
|
||||
'prev_text' => '<i class="fas fa-chevron-left"></i>',
|
||||
'next_text' => '<i class="fas fa-chevron-right"></i>',
|
||||
]);
|
||||
?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php else : ?>
|
||||
<div class="aksrt-author-page__empty">
|
||||
<div class="aksrt-author-page__empty-icon">
|
||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" width="30" height="30"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/><path d="M14 2v6h6"/><path d="M9 13h6M9 17h6M9 9h1"/></svg>
|
||||
</div>
|
||||
<p class="aksrt-author-page__empty-title"><?php esc_html_e('暂无文章', 'aksrt'); ?></p>
|
||||
<p class="aksrt-author-page__empty-desc"><?php echo esc_html(sprintf(__('%s 还没有发布任何文章。', 'aksrt'), $author->display_name)); ?></p>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
|
||||
<?php do_action('aksrt_author_after_content', $user_id); ?>
|
||||
</div>
|
||||
|
||||
<?php if (!empty($user_home_settings['sidebar'])) : ?>
|
||||
<aside class="content-layout__aside sidebar aksrt-author-page__aside" role="complementary" aria-label="<?php esc_attr_e('作者页侧栏', 'aksrt'); ?>">
|
||||
<?php
|
||||
$sidebar_id = is_active_sidebar('author-sidebar') ? 'author-sidebar' : 'sidebar-blog';
|
||||
if (is_active_sidebar('all_sidebar_top')) {
|
||||
dynamic_sidebar('all_sidebar_top');
|
||||
}
|
||||
if (is_active_sidebar($sidebar_id)) {
|
||||
dynamic_sidebar($sidebar_id);
|
||||
}
|
||||
if (is_active_sidebar('all_sidebar_bottom')) {
|
||||
dynamic_sidebar('all_sidebar_bottom');
|
||||
}
|
||||
?>
|
||||
</aside>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
|
||||
<?php get_footer(); ?>
|
||||
wp_safe_redirect(home_url('/'), 302);
|
||||
exit;
|
||||
|
||||
@@ -712,7 +712,8 @@ if (!function_exists('aksrt_is_user_home_page')) :
|
||||
* 判断当前是否为公开用户主页
|
||||
*/
|
||||
function aksrt_is_user_home_page(): bool {
|
||||
return (bool) get_query_var('user_nicename');
|
||||
return (bool) get_query_var('user_nicename')
|
||||
|| is_page_template('templates/pages/page-user-home.php');
|
||||
}
|
||||
endif;
|
||||
|
||||
|
||||
@@ -151,7 +151,6 @@ trait AKSRT_Scripts_Part_1b {
|
||||
$is_auth_page = $is_auth_route
|
||||
|| (function_exists('aksrt_is_auth_page_request') && aksrt_is_auth_page_request());
|
||||
$is_profile_page = $is_profile_route
|
||||
|| is_author()
|
||||
|| (function_exists('aksrt_is_user_home_page') && aksrt_is_user_home_page())
|
||||
|| (function_exists('aksrt_is_user_center_page') && aksrt_is_user_center_page())
|
||||
|| is_page_template('templates/pages/page-profile.php')
|
||||
@@ -238,13 +237,12 @@ trait AKSRT_Scripts_Part_1b {
|
||||
file_exists($profile_css_path) ? (string) filemtime($profile_css_path) : $version
|
||||
);
|
||||
|
||||
// 本人中心 vs 公开主页/作者页拆分加载
|
||||
// 本人中心 vs 公开主页拆分加载
|
||||
$is_public_user_home = $is_profile_route
|
||||
|| is_author()
|
||||
|| (function_exists('aksrt_is_user_home_page') && aksrt_is_user_home_page())
|
||||
|| is_page_template('templates/pages/page-user-home.php');
|
||||
if ($is_public_user_home) {
|
||||
// /user/{nicename}/ 与 /author/{nicename}/ 共用公开主页样式
|
||||
// /user/{nicename}/ 公开主页
|
||||
$user_home_css_path = get_template_directory() . '/assets/css/routes/user-home.css';
|
||||
wp_enqueue_style(
|
||||
'aksrt-route-user-home',
|
||||
@@ -533,12 +531,6 @@ trait AKSRT_Scripts_Part_1b {
|
||||
}
|
||||
}
|
||||
|
||||
// 作者归档(虽然 author.php 在 Phase 3 会重定向,但保留兼容)
|
||||
if (is_author()) {
|
||||
$enqueue_module('pages');
|
||||
$enqueue_module('post-card');
|
||||
$enqueue_module('comments');
|
||||
}
|
||||
|
||||
// 404 页面
|
||||
if (is_404()) {
|
||||
|
||||
@@ -112,12 +112,9 @@ trait AKSRT_Scripts_Part_2 {
|
||||
if (function_exists('aksrt_is_user_center_page') && aksrt_is_user_center_page()) {
|
||||
$classes[] = 'aksrt-user-center';
|
||||
}
|
||||
if ((function_exists('aksrt_is_user_home_page') && aksrt_is_user_home_page()) || is_author()) {
|
||||
if (function_exists('aksrt_is_user_home_page') && aksrt_is_user_home_page()) {
|
||||
$classes[] = 'aksrt-user-home';
|
||||
}
|
||||
if (is_author()) {
|
||||
$classes[] = 'aksrt-author-page';
|
||||
}
|
||||
if (function_exists('aksrt_is_auth_page_request') && aksrt_is_auth_page_request()) {
|
||||
$classes[] = 'auth-page';
|
||||
}
|
||||
|
||||
@@ -7,6 +7,12 @@
|
||||
- 内容面板:panels-core.php / panel-forum.php / panel-follow.php
|
||||
- 侧栏:sidebar.php
|
||||
- 列表项:templates/parts/content-profile-*.php
|
||||
- 样式:assets/css/routes/user-home.css(含 uh-forum)+ shared profile.css
|
||||
- 脚本:assets/js/author.js(公开主页 tab / cover;author 归档 301 到 /user/)
|
||||
|
||||
作者归档:
|
||||
- author.php 仅作 301 回退到 /user/{nicename}/
|
||||
- 不再维护独立作者页 UI
|
||||
|
||||
旧 uh-* 草稿 partial 已删除,勿再引入。
|
||||
-->
|
||||
|
||||
Reference in New Issue
Block a user