diff --git a/quartz/components/Head.tsx b/quartz/components/Head.tsx
index 46ba5e002..7b9815ca0 100644
--- a/quartz/components/Head.tsx
+++ b/quartz/components/Head.tsx
@@ -6,7 +6,8 @@ import { QuartzComponent, QuartzComponentConstructor, QuartzComponentProps } fro
export default (() => {
const Head: QuartzComponent = ({ cfg, fileData, externalResources }: QuartzComponentProps) => {
- const title = fileData.frontmatter?.title ?? i18n(cfg.locale).propertyDefaults.title
+ const title =
+ (fileData.frontmatter?.title ?? i18n(cfg.locale).propertyDefaults.title) + cfg.pageTitleSuffix
const description =
fileData.description?.trim() ?? i18n(cfg.locale).propertyDefaults.description
const { css, js } = externalResources
diff --git a/quartz/components/PageList.tsx b/quartz/components/PageList.tsx
index 1e5d232df..cc0124a8f 100644
--- a/quartz/components/PageList.tsx
+++ b/quartz/components/PageList.tsx
@@ -4,9 +4,9 @@ import { Date, getDate } from "./Date"
import { QuartzComponent, QuartzComponentProps } from "./types"
import { GlobalConfiguration } from "../cfg"
-export function byDateAndAlphabetical(
- cfg: GlobalConfiguration,
-): (f1: QuartzPluginData, f2: QuartzPluginData) => number {
+export type SortFn = (f1: QuartzPluginData, f2: QuartzPluginData) => number
+
+export function byDateAndAlphabetical(cfg: GlobalConfiguration): SortFn {
return (f1, f2) => {
if (f1.dates && f2.dates) {
// sort descending
@@ -27,10 +27,12 @@ export function byDateAndAlphabetical(
type Props = {
limit?: number
+ sort?: SortFn
} & QuartzComponentProps
-export const PageList: QuartzComponent = ({ cfg, fileData, allFiles, limit }: Props) => {
- let list = allFiles.sort(byDateAndAlphabetical(cfg))
+export const PageList: QuartzComponent = ({ cfg, fileData, allFiles, limit, sort }: Props) => {
+ const sorter = sort ?? byDateAndAlphabetical(cfg)
+ let list = allFiles.sort(sorter)
if (limit) {
list = list.slice(0, limit)
}
@@ -44,11 +46,13 @@ export const PageList: QuartzComponent = ({ cfg, fileData, allFiles, limit }: Pr
return (
- {page.dates && (
-
-
-
- )}
+
+ {page.dates && (
+
+
+
+ )}
+
)
diff --git a/quartz/components/Search.tsx b/quartz/components/Search.tsx
index 01e5a353d..8b9755518 100644
--- a/quartz/components/Search.tsx
+++ b/quartz/components/Search.tsx
@@ -19,24 +19,16 @@ export default ((userOpts?: Partial
) => {
const searchPlaceholder = i18n(cfg.locale).components.search.searchBarPlaceholder
return (
-
+
+
-
{RightComponent}
+