This commit is contained in:
Vaica committed 2026-06-22 00:52:51 +08:00
1 parent d664326648
commit 612cafe5ad
6 files changed
+22 -7

No files matched your search

+1 -2
View File
@@ -73,8 +73,7 @@ export default function EditPostPage({
type="button"
onClick={async () => {
await fetch("/api/hugo");
const previewBase = `${location.protocol}//${location.hostname}:1313`;
window.open(`${previewBase}/${post.frontMatter.slug}.html`, "_blank");
window.open(`/preview/${post.frontMatter.slug}.html`, "_blank");
}}
className="flex items-center gap-1.5 px-3 py-1.5 text-[12px] rounded-md border border-line text-muted hover:text-accent hover:border-accent/30 transition-colors"
title="预览"