Skip to content
This repository was archived by the owner on May 27, 2025. It is now read-only.

Commit a30b173

Browse files
committed
Try to fix?
Signed-off-by: Abhi Agarwal <abhiaagarwal01@gmail.com>
1 parent 5aea4f8 commit a30b173

File tree

3 files changed

+5
-10
lines changed

3 files changed

+5
-10
lines changed

quartz/components/ContentMeta.tsx

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Date, formatDate, getDate } from "./Date"
1+
import { Date, getDate } from "./Date"
22
import { QuartzComponentConstructor, QuartzComponentProps } from "./types"
33
import readingTime from "reading-time"
44
import { classNames } from "../util/lang"
@@ -30,12 +30,7 @@ export default ((opts?: Partial<ContentMetaOptions>) => {
3030
const segments: (string | JSX.Element)[] = []
3131

3232
if (fileData.dates) {
33-
const createdDate = fileData.dates.created
34-
segments.push(`Published ${formatDate(createdDate, cfg.locale)}`)
35-
const modifiedDate = fileData.dates.modified
36-
if (modifiedDate) {
37-
segments.push(`modified ${formatDate(modifiedDate, cfg.locale)}`)
38-
}
33+
segments.push(<Date date={getDate(cfg, fileData)!} locale={cfg.locale} />)
3934
}
4035

4136
// Display reading time if enabled

quartz/components/scripts/graph.inline.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ async function renderGraph(container: string, fullSlug: FullSlug) {
144144
}
145145

146146
const nodes = [...neighbourhood].map((url) => {
147-
const text = url.startsWith("tags/") ? "#" + url.substring(5) : data.get(url)?.title ?? url
147+
const text = url.startsWith("tags/") ? "#" + url.substring(5) : (data.get(url)?.title ?? url)
148148
return {
149149
id: url,
150150
text,

tsconfig.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
"forceConsistentCasingInFileNames": true,
1414
"esModuleInterop": true,
1515
"jsx": "react-jsx",
16-
"jsxImportSource": "preact",
16+
"jsxImportSource": "preact"
1717
},
1818
"include": ["**/*.ts", "**/*.tsx", "./package.json"],
19-
"exclude": ["build/**/*.d.ts"],
19+
"exclude": ["build/**/*.d.ts"]
2020
}

0 commit comments

Comments
 (0)