feat(projects): remove thumbnail and preview field to get images by content id
This commit is contained in:
@@ -79,10 +79,12 @@ export const useProjectsStore = defineStore("projects", {
|
||||
this.projects = [];
|
||||
|
||||
for (const project of projects.value) {
|
||||
const parts = project.id.replace(".md", "").split("/");
|
||||
const id = parts[parts.length - 1]!;
|
||||
this.projects.push({
|
||||
description: project.description,
|
||||
thumbnail: project.thumbnail,
|
||||
preview: createImage(project.preview),
|
||||
thumbnail: `/images/projects/thumbnails/${id}.webp`,
|
||||
preview: createImage(`/images/projects/previews/${id}.webp`),
|
||||
url: project.url,
|
||||
body: simplifyMarkdownAST(project.body),
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user