Better content for the default page

This commit is contained in:
Kuba Orlik 2025-03-02 22:26:20 +01:00
parent a69e1097f0
commit cfbc163950

View File

@ -1,4 +1,5 @@
import { App, Collection, FieldTypes, Policies } from "sealious";
import { Collection, FieldTypes, Policies } from "sealious";
import type { App } from "sealious";
import { CRUDRoles } from "../policy-types/roles.js";
import assert from "assert";
import TheApp from "../app.js";
@ -24,8 +25,32 @@ export default class Pages extends Collection {
if (all_pages.empty) {
await app.collections.pages.suCreate({
url: "/",
content: [],
content: [
{
component_name: "hero",
args: {
color: "text-accent-on-text-bg",
title: "Welcome to Sealious-Playground",
title_color: "accent1",
subtitle: "Go to /admin to edit the pages",
content: "",
buttons: [
{
text: "Go to Admin",
href: "/admin",
variant: "accent2",
},
{
text: "Learn more about Sealcode Stack",
href: "https://forum.sealcode.org/t/the-sealious-based-application-architecture-sealcode-stack/1841",
variant: "accent1",
},
],
},
},
],
title: "Homepage",
domain: "",
});
}
});