feat: 友链/书库/移动端导航/排行榜等多模块功能
新增模块: - 友链(friendlink)后端处理 + 前端管理页与友链板 - 书库(library):导入、章节、封面、阅读页、横竖版自适应 AdaptiveCoverSlot - 顶栏导航(header_nav)配置与 MobileTabBar/MobileRailDrawers 移动端抽屉 - 排行榜 service 测试、站点页面测试、时间线发布(timeline_release) 其它改动: - 后端 handlers/services 全量小幅调整 - 前端组件、库函数、URL/品牌/站点 URL 工具更新 - Lightbox 图片、MdEntries 条目卡、coverColor 派生色相等前端能力
This commit is contained in:
@@ -29,6 +29,7 @@ import { requestCanonical } from "@/lib/canonicalMeta";
|
||||
import { userPath, leaderboardPath, type UrlStyle } from "@/lib/urlStyle";
|
||||
import Avatar from "@/components/Avatar";
|
||||
import LevelBadge from "@/components/LevelBadge";
|
||||
import MobileRailDrawers from "@/components/MobileRailDrawers";
|
||||
|
||||
interface PageProps {
|
||||
searchParams: Promise<{ period?: string; metric?: string }>;
|
||||
@@ -411,7 +412,7 @@ function RulesPanel({ s }: { s: PublicSettings }) {
|
||||
))}
|
||||
</ul>
|
||||
<p className="meta text-[11.5px] mt-3 leading-relaxed">
|
||||
累计积分即贡献值,决定等级与总榜排名;消费仅扣余额,不减少累计值。
|
||||
贡献值 = 周期内累计获得的积分,按上方规则逐笔入账;消费仅扣余额,不减少累计值。
|
||||
</p>
|
||||
</section>
|
||||
);
|
||||
@@ -442,7 +443,21 @@ export default async function LeaderboardPage({ searchParams }: PageProps) {
|
||||
const totalScore = entries.reduce((acc, e) => acc + e.score, 0);
|
||||
|
||||
return (
|
||||
<div className="grid gap-5 lg:gap-6 lg:grid-cols-[minmax(0,1fr)_320px] items-start">
|
||||
<>
|
||||
{/* 移动端:右栏(我的排名 + 贡献值规则)收进右抽屉,lg 起隐藏 */}
|
||||
<MobileRailDrawers
|
||||
right={{
|
||||
label: "排名与规则",
|
||||
content: (
|
||||
<>
|
||||
<MyRankPanel me={me} authed={authed} period={period} metric={metric} />
|
||||
<RulesPanel s={settings} />
|
||||
</>
|
||||
),
|
||||
}}
|
||||
/>
|
||||
|
||||
<div className="grid gap-5 lg:gap-6 lg:grid-cols-[minmax(0,1fr)_320px] items-start">
|
||||
{/* 左栏:贡献排行榜 */}
|
||||
<div className="min-w-0">
|
||||
{/* Hero:渐变洗底 + 光斑装饰 */}
|
||||
@@ -592,11 +607,12 @@ export default async function LeaderboardPage({ searchParams }: PageProps) {
|
||||
)}
|
||||
</div>
|
||||
|
||||
{/* 右栏:我的排名 + 贡献值规则 */}
|
||||
<aside className="space-y-4 lg:sticky lg:top-[76px]">
|
||||
{/* 右栏:我的排名 + 贡献值规则(移动端收进右抽屉) */}
|
||||
<aside className="hidden lg:block space-y-4 lg:sticky lg:top-[76px]">
|
||||
<MyRankPanel me={me} authed={authed} period={period} metric={metric} />
|
||||
<RulesPanel s={settings} />
|
||||
</aside>
|
||||
</div>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user