Add canvas element tools and categorized article editing

This commit is contained in:
2026-11-21 22:24:58 +08:00
parent 6efcdefadf
commit a5b3408358
45 changed files with 1607 additions and 660 deletions
+1 -2
View File
@@ -1,5 +1,4 @@
<?php
use App\Content\Repository;
use App\Content\View;
$e = View::escape(...);
@@ -9,7 +8,7 @@ $e = View::escape(...);
<?php foreach ($articles as $item): ?>
<li>
<div><strong><?= $e($item['title']) ?></strong>
<small><?= $e(Repository::CATEGORIES[$item['category']]) ?> · <?= $item['status'] === 'published' ? '已发布' : '草稿' ?> · <?= $e(View::date($item['updated_at'])) ?></small>
<small><?= $e(implode('、', $item['categories'])) ?> · <?= $item['status'] === 'published' ? '已发布' : '草稿' ?> · <?= $e(View::date($item['updated_at'])) ?></small>
</div>
<a class="button button-outline" href="/admin/articles/<?= $e($item['id']) ?>">编辑文章</a>
</li>