更新网页架构,新增外部工具分区,优化web样式

This commit is contained in:
MasonLiu committed 2026-09-08 23:53:35 +08:00
1 parent 0c3d3d4977
commit c5b6f4b4c2
15 files changed
+1207 -713

No files matched your search

+13 -4
View File
@@ -44,6 +44,8 @@ foreach ($partOrder as $part) {
$rows[] = ['part' => $part, 'articles' => $items];
}
$total = count($all);
// 从库首页“文章区”卡片进入阅读时(?from=nav),顶部返回按钮语义切换
$fromNav = (isset($_GET['from']) && (string)$_GET['from'] === 'nav');
// 当前阅读文章
$cur = null;
@@ -67,9 +69,16 @@ layout_head($cur ? (string)$cur['title'] : '文章库');
<!-- 顶部栏:返回首页 / 当页名(列表为文章库、阅读时显示文章标题)/ 分区·段落开关 -->
<header class="art-topbar">
<div class="art-topbar-nav">
<a class="btn btn-sm" href="../index.php" title="返回站点首页">← 首页</a>
<?php if ($cur): ?>
<?php if ($fromNav): ?>
<a class="btn btn-sm" href="index.php" title="返回文章区首页(文章列表)">← 文章区首页</a>
<?php if ($cur): ?>
<a class="btn btn-sm" href="javascript:history.back()" title="返回上一页(回到来源页面)">← 返回上一页</a>
<?php endif; ?>
<?php else: ?>
<a class="btn btn-sm" href="../index.php" title="返回站点首页">← 首页</a>
<?php if ($cur): ?>
<a class="btn btn-sm" href="index.php" title="返回文章区首页(文章列表)">← 文章区首页</a>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="art-topbar-title"><?= $cur ? he((string)$cur['title']) : '📚 文章库' ?></div>
@@ -146,10 +155,10 @@ layout_head($cur ? (string)$cur['title'] : '文章库');
<div class="art-list">
<div class="art-list-head">
<h1>全部文章 <span class="tip">(共 <?= $total ?> 篇)</span></h1>
<p class="tip">点击任意文章开始阅读;左侧「文章目录」可随时切换文章,中间「段落目录」可快速跳转。</p>
<p class="tip st-tip">点击任意文章开始阅读;左侧「文章目录」可随时切换文章,中间「段落目录」可快速跳转。</p>
</div>
<?php if (!$rows): ?>
<div class="panel-card"><p class="tip">文章库还没有内容,站长可在后台「文章管理」中发布。</p></div>
<div class="panel-card"><p class="tip">文章库还没有内容<span class="st-tip">,站长可在后台「文章管理」中发布</span>。</p></div>
<?php endif; ?>
<?php foreach ($rows as $g): ?>
<div class="art-part-block">