Compare commits

7 Commits

Author SHA1 Message Date
7dbc81c5b2 Add more blocks to posts
Some checks failed
continuous-integration/drone/push Build is failing
2024-05-21 12:07:14 +02:00
4b30d58db6 Type posts 2024-05-21 12:04:23 +02:00
62e50496a2 Merge branch 'main' into t-work 2024-05-21 11:39:36 +02:00
3wc
c90d2c0d9b Fix YAML syntax
All checks were successful
continuous-integration/drone Build is passing
continuous-integration/drone/push Build is passing
2024-05-20 23:33:07 -03:00
3wc
4544c7942c Further drone boop
Some checks reported errors
continuous-integration/drone/push Build encountered an error
2024-05-20 23:31:19 -03:00
3wc
7997268fad Boop drone
Some checks reported errors
continuous-integration/drone Build was killed
continuous-integration/drone/push Build is passing
2024-05-20 23:30:08 -03:00
3wc
d8cfd644f8 Another dependency experiment
Some checks reported errors
continuous-integration/drone/push Build encountered an error
2024-05-20 23:29:07 -03:00
4 changed files with 24 additions and 14 deletions

View File

@ -14,7 +14,7 @@ steps:
registry: git.autonomic.zone
context: astro
dockerfile: astro/Dockerfile
trigger: &exclude-event-custom
when: &exclude-event-custom
branch:
- main
event:
@ -30,8 +30,8 @@ steps:
context: payload
dockerfile: payload/Dockerfile
target: dev
trigger:
<< *exclude-event-custom
when:
<<: *exclude-event-custom
- name: publish payload prod container
image: plugins/docker
@ -40,8 +40,8 @@ steps:
username: 3wordchant
repo: git.autonomic.zone/autonomic-cooperative/astro-payload-test-payload
target: prod
trigger:
<< *exclude-event-custom
when:
<<: *exclude-event-custom
- name: deploy stack
image: git.coopcloud.tech/coop-cloud/stack-ssh-deploy:latest
@ -63,8 +63,8 @@ steps:
PAYLOAD_URL: "https://admin.paystro.swarm-demo.autonomic.zone"
depends_on:
- publish payload prod container
trigger:
<< *exclude-event-custom
when:
<<: *exclude-event-custom
- name: build astro content
image: git.autonomic.zone/autonomic-cooperative/astro-payload-test-astro:latest

View File

@ -1,5 +1,10 @@
---
import { Image } from "@astrojs/image/components";
import type { Post } from "@/types/payload-types";
interface Props {
post: Post;
}
const { post } = Astro.props;
---

View File

@ -1,5 +1,10 @@
---
import Post from "@/components/Post.astro"
import PostEntry from "@/components/PostEntry.astro"
import type { Post } from "@/types/payload-types";
interface Props {
posts: Post[];
}
const { posts } = Astro.props;
---
@ -10,8 +15,9 @@ const { posts } = Astro.props;
{
posts.length > 0 ? (
posts.map((post) => (
<Post post={post}/>
))
typeof(post) === 'object') &&
<PostEntry post={post}/>
)
) : (
<p>No posts available</p>
)

View File

@ -71,7 +71,7 @@ const Posts: CollectionConfig = {
name: "content",
type: "richText",
admin: {
elements: ["h2", "h3", "h4", "link", "ol", "ul", "upload"],
elements: ["h2", "h3", "h4", "link", "ol", "ul", "upload", "blockquote", "indent"],
leaves: ["bold", "italic", "underline"],
upload: {
collections: {
@ -90,11 +90,10 @@ const Posts: CollectionConfig = {
},
},
{
name: "authors",
name: "author",
//TODO: Add active user as default
type: 'relationship',
relationTo: 'authors',
hasMany: true,
relationTo: 'authors',
admin: {
position: "sidebar",
},