feat(editorial): validate publications and preserve partial event updates
This commit is contained in:
1 parent
76f0420d64
commit
db4acbb46e
14 files changed
+613
-16
No files matched your search
@@ -25,9 +25,11 @@ export interface ArticlePreviewData {
|
||||
export function ArticlePreview({
|
||||
data,
|
||||
onClose,
|
||||
title,
|
||||
}: {
|
||||
data: ArticlePreviewData | null;
|
||||
onClose: () => void;
|
||||
title?: string;
|
||||
}) {
|
||||
const t = useTranslations("pages.admin.articles.form");
|
||||
const document = data
|
||||
@@ -42,13 +44,13 @@ export function ArticlePreview({
|
||||
>
|
||||
<DialogContent className="sm:max-w-4xl h-[85dvh] flex flex-col min-h-0">
|
||||
<DialogHeader>
|
||||
<DialogTitle>{t("previewTitle")}</DialogTitle>
|
||||
<DialogTitle>{title ?? t("previewTitle")}</DialogTitle>
|
||||
</DialogHeader>
|
||||
<p className="text-xs text-muted-foreground">
|
||||
{t("previewDescription")}
|
||||
</p>
|
||||
<iframe
|
||||
title={t("previewFrame")}
|
||||
title={title ?? t("previewFrame")}
|
||||
sandbox=""
|
||||
srcDoc={document}
|
||||
className="min-h-0 flex-1 w-full bg-background rounded border"
|
||||
|
||||
Reference in new issue
Block a user