mirror of
https://github.com/Stone-Red-Code/website.git
synced 2026-09-04 09:15:58 +02:00
@@ -8,8 +8,8 @@ import { PageContent } from "../components/PageContent"
|
|||||||
|
|
||||||
// @todo maybe find alternative type for data
|
// @todo maybe find alternative type for data
|
||||||
const Archive: FC<any> = ({ data }) => {
|
const Archive: FC<any> = ({ data }) => {
|
||||||
const { relativePath, ctime } = data.file
|
const { relativePath } = data.file
|
||||||
const { body, excerpt, fields, timeToRead } = data.file.post
|
const { body, excerpt, fields, timeToRead, frontmatter } = data.file.post
|
||||||
|
|
||||||
const title = humanize(relativePath)
|
const title = humanize(relativePath)
|
||||||
|
|
||||||
@@ -21,7 +21,7 @@ const Archive: FC<any> = ({ data }) => {
|
|||||||
basePath="/archives"
|
basePath="/archives"
|
||||||
title={title}
|
title={title}
|
||||||
authors={fields.authors}
|
authors={fields.authors}
|
||||||
createdAt={ctime}
|
createdAt={frontmatter.created_at}
|
||||||
timeToRead={timeToRead}
|
timeToRead={timeToRead}
|
||||||
shifted={false}
|
shifted={false}
|
||||||
/>
|
/>
|
||||||
@@ -36,7 +36,6 @@ export const query = graphql`
|
|||||||
query Archive($file: String!) {
|
query Archive($file: String!) {
|
||||||
file(relativePath: { eq: $file }) {
|
file(relativePath: { eq: $file }) {
|
||||||
relativePath
|
relativePath
|
||||||
ctime
|
|
||||||
post: childMdx {
|
post: childMdx {
|
||||||
body
|
body
|
||||||
excerpt
|
excerpt
|
||||||
@@ -47,6 +46,9 @@ export const query = graphql`
|
|||||||
avatar
|
avatar
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
frontmatter {
|
||||||
|
created_at
|
||||||
|
}
|
||||||
timeToRead
|
timeToRead
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user