Static CMS v4 (#252)
All checks were successful
website-main / prod-build (push) Successful in 13s
website-main / test-build (push) Successful in 5s

Reviewed-on: #252
This commit is contained in:
2023-12-13 12:42:59 +01:00
parent 71dd4d4d81
commit 25af663be4
22 changed files with 178 additions and 205 deletions

View File

@ -1,4 +1,4 @@
import { DateFormat, MarkdownProps } from "../props.js";
import { EditorProps, DateFormat, MarkdownProps, ImageProps } from "../props.js";
import {
AuthorRelation,
DescriptionText,
@ -14,22 +14,21 @@ const BlogCollection = {
'Diese Artikel werden im Bereich "Aktuelles" auf der Schulhomepage angezeigt. Sie können sowohl direkt veröffentlicht, als auch als Entwurf gespeichert werden.',
icon: "news",
folder: "content/blog",
create: true,
editor: {
preview: true,
frame: true,
size: "half",
},
...EditorProps,
filter: {
field: "type",
value: "post",
},
view_groups: [
{
label: "Entwurf",
field: "draft",
},
],
view_groups: {
default: "draft",
groups: [
{
name: "draft",
label: "Entwurf",
field: "draft",
},
],
},
sortable_fields: {
fields: ["date", "title"],
default: {
@ -53,9 +52,9 @@ const BlogCollection = {
name: "image",
label: "Titelbild",
hint: "16:9 Seitenverhältnis beachten",
widget: "image",
required: true,
default: "/media/image.webp",
...ImageProps,
required: true,
},
AuthorRelation,
{
@ -102,7 +101,6 @@ const BlogCollection = {
{
name: "body",
label: "Inhalt",
widget: "markdown",
required: true,
...MarkdownProps,
},