Compare commits

...

1 Commits
0.5.2 ... 0.5.3

Author SHA1 Message Date
7efa375427 remove author field 2024-08-24 02:09:34 -05:00
6 changed files with 7 additions and 12 deletions

View File

@@ -1,6 +1,6 @@
FROM node:20.17.0-alpine3.20 AS base
LABEL version="0.5.2"
LABEL version="0.5.3"
LABEL description="Astro based website to use as a profile"
ENV PNPM_HOME="/pnpm"

View File

@@ -26,17 +26,12 @@ type Skills = {
skill_3_description: string;
}
type Author = {
name: string
}
export type Post = {
slug: string;
title: string;
content: string;
image: string;
published_date: string;
author: Author;
tags: string[];
image_alt: string;
}

View File

@@ -1,7 +1,7 @@
{
"name": "site-profile",
"type": "module",
"version": "0.5.2",
"version": "0.5.3",
"scripts": {
"dev": "astro dev",
"start": "astro dev",

View File

@@ -18,7 +18,7 @@ const global = await directus.request(readSingleton("global"));
const posts = await directus.request(
readItems("posts", {
fields: ['*', { author: ['*'] }],
fields: ['*'],
sort: ["-published_date"],
})
);

View File

@@ -13,7 +13,7 @@ const global = await directus.request(readSingleton("global"));
const posts = await directus.request(
readItems("posts", {
fields: ['*', { author: ['*'] }],
fields: ['*'],
sort: ["-published_date"],
})
);

View File

@@ -11,7 +11,7 @@ import { readItems } from "@directus/sdk";
export async function getStaticPaths() {
const posts = await directus.request(readItems("posts", {
fields: ['*', { author: ['*'] }],
fields: ['*'],
}));
return posts.map((post) => ({ params: { slug: post.slug }, props: post }));
}
@@ -28,7 +28,7 @@ const published_date: string = new Date(post.published_date).toLocaleDateString(
<a class="back-link" href="/projects/"><Icon icon="arrow-left" /> Projects</a>
<Hero
title={post.title}
tagline=`Published by ${post.author.name} on ${published_date}`
tagline=`Published on ${published_date}`
align="start"
>
<div class="details">