diff --git a/quartz/components/pages/TagContent.tsx b/quartz/components/pages/TagContent.tsx
index 3859f53e4150d..ae490a8fa7c0f 100644
--- a/quartz/components/pages/TagContent.tsx
+++ b/quartz/components/pages/TagContent.tsx
@@ -66,9 +66,12 @@ function TagContent(props: QuartzComponentProps) {
{i18n(cfg.locale).pages.tagContent.itemsUnderTag({ count: pages.length })}
{pages.length > numPages && (
-
- {i18n(cfg.locale).pages.tagContent.showingFirst({ count: numPages })}
-
+ <>
+ {" "}
+
+ {i18n(cfg.locale).pages.tagContent.showingFirst({ count: numPages })}
+
+ >
)}
diff --git a/quartz/i18n/locales/de-DE.ts b/quartz/i18n/locales/de-DE.ts
index e3821944b0bfb..64c9ba9df5d4d 100644
--- a/quartz/i18n/locales/de-DE.ts
+++ b/quartz/i18n/locales/de-DE.ts
@@ -69,13 +69,13 @@ export default {
folderContent: {
folder: "Ordner",
itemsUnderFolder: ({ count }) =>
- count === 1 ? "1 Datei in diesem Ordner" : `${count} Dateien in diesem Ordner.`,
+ count === 1 ? "1 Datei in diesem Ordner." : `${count} Dateien in diesem Ordner.`,
},
tagContent: {
tag: "Tag",
tagIndex: "Tag-Übersicht",
itemsUnderTag: ({ count }) =>
- count === 1 ? "1 Datei mit diesem Tag" : `${count} Dateien mit diesem Tag.`,
+ count === 1 ? "1 Datei mit diesem Tag." : `${count} Dateien mit diesem Tag.`,
showingFirst: ({ count }) => `Die ersten ${count} Tags werden angezeigt.`,
totalTags: ({ count }) => `${count} Tags insgesamt.`,
},
diff --git a/quartz/i18n/locales/en-US.ts b/quartz/i18n/locales/en-US.ts
index 4a308d79a7cd2..ac283fdafaeba 100644
--- a/quartz/i18n/locales/en-US.ts
+++ b/quartz/i18n/locales/en-US.ts
@@ -69,13 +69,13 @@ export default {
folderContent: {
folder: "Folder",
itemsUnderFolder: ({ count }) =>
- count === 1 ? "1 item under this folder" : `${count} items under this folder.`,
+ count === 1 ? "1 item under this folder." : `${count} items under this folder.`,
},
tagContent: {
tag: "Tag",
tagIndex: "Tag Index",
itemsUnderTag: ({ count }) =>
- count === 1 ? "1 item with this tag" : `${count} items with this tag.`,
+ count === 1 ? "1 item with this tag." : `${count} items with this tag.`,
showingFirst: ({ count }) => `Showing first ${count} tags.`,
totalTags: ({ count }) => `Found ${count} total tags.`,
},
diff --git a/quartz/i18n/locales/es-ES.ts b/quartz/i18n/locales/es-ES.ts
index f59d201a3b37f..37a2a79c721f6 100644
--- a/quartz/i18n/locales/es-ES.ts
+++ b/quartz/i18n/locales/es-ES.ts
@@ -69,13 +69,13 @@ export default {
folderContent: {
folder: "Carpeta",
itemsUnderFolder: ({ count }) =>
- count === 1 ? "1 artículo en esta carpeta" : `${count} artículos en esta carpeta.`,
+ count === 1 ? "1 artículo en esta carpeta." : `${count} artículos en esta carpeta.`,
},
tagContent: {
tag: "Etiqueta",
tagIndex: "Índice de Etiquetas",
itemsUnderTag: ({ count }) =>
- count === 1 ? "1 artículo con esta etiqueta" : `${count} artículos con esta etiqueta.`,
+ count === 1 ? "1 artículo con esta etiqueta." : `${count} artículos con esta etiqueta.`,
showingFirst: ({ count }) => `Mostrando las primeras ${count} etiquetas.`,
totalTags: ({ count }) => `Se encontraron ${count} etiquetas en total.`,
},
diff --git a/quartz/i18n/locales/fr-FR.ts b/quartz/i18n/locales/fr-FR.ts
index 8b7229201208a..b485d2b6e5a01 100644
--- a/quartz/i18n/locales/fr-FR.ts
+++ b/quartz/i18n/locales/fr-FR.ts
@@ -69,13 +69,13 @@ export default {
folderContent: {
folder: "Dossier",
itemsUnderFolder: ({ count }) =>
- count === 1 ? "1 élément sous ce dossier" : `${count} éléments sous ce dossier.`,
+ count === 1 ? "1 élément sous ce dossier." : `${count} éléments sous ce dossier.`,
},
tagContent: {
tag: "Étiquette",
tagIndex: "Index des étiquettes",
itemsUnderTag: ({ count }) =>
- count === 1 ? "1 élément avec cette étiquette" : `${count} éléments avec cette étiquette.`,
+ count === 1 ? "1 élément avec cette étiquette." : `${count} éléments avec cette étiquette.`,
showingFirst: ({ count }) => `Affichage des premières ${count} étiquettes.`,
totalTags: ({ count }) => `Trouvé ${count} étiquettes au total.`,
},
diff --git a/quartz/i18n/locales/it-IT.ts b/quartz/i18n/locales/it-IT.ts
index a0cc042830688..ca8818a650f35 100644
--- a/quartz/i18n/locales/it-IT.ts
+++ b/quartz/i18n/locales/it-IT.ts
@@ -69,13 +69,13 @@ export default {
folderContent: {
folder: "Cartella",
itemsUnderFolder: ({ count }) =>
- count === 1 ? "1 oggetto in questa cartella" : `${count} oggetti in questa cartella.`,
+ count === 1 ? "1 oggetto in questa cartella." : `${count} oggetti in questa cartella.`,
},
tagContent: {
tag: "Etichetta",
tagIndex: "Indice etichette",
itemsUnderTag: ({ count }) =>
- count === 1 ? "1 oggetto con questa etichetta" : `${count} oggetti con questa etichetta.`,
+ count === 1 ? "1 oggetto con questa etichetta." : `${count} oggetti con questa etichetta.`,
showingFirst: ({ count }) => `Prime ${count} etichette.`,
totalTags: ({ count }) => `Trovate ${count} etichette totali.`,
},
diff --git a/quartz/i18n/locales/nl-NL.ts b/quartz/i18n/locales/nl-NL.ts
index e239be0e1d793..d075d584a45be 100644
--- a/quartz/i18n/locales/nl-NL.ts
+++ b/quartz/i18n/locales/nl-NL.ts
@@ -70,7 +70,7 @@ export default {
folderContent: {
folder: "Map",
itemsUnderFolder: ({ count }) =>
- count === 1 ? "1 item in deze map" : `${count} items in deze map.`,
+ count === 1 ? "1 item in deze map." : `${count} items in deze map.`,
},
tagContent: {
tag: "Label",
diff --git a/quartz/i18n/locales/uk-UA.ts b/quartz/i18n/locales/uk-UA.ts
index c997a6972c7dd..b636938373c37 100644
--- a/quartz/i18n/locales/uk-UA.ts
+++ b/quartz/i18n/locales/uk-UA.ts
@@ -69,13 +69,13 @@ export default {
folderContent: {
folder: "Папка",
itemsUnderFolder: ({ count }) =>
- count === 1 ? "У цій папці 1 елемент" : `Елементів у цій папці: ${count}.`,
+ count === 1 ? "У цій папці 1 елемент." : `Елементів у цій папці: ${count}.`,
},
tagContent: {
tag: "Тег",
tagIndex: "Індекс тегу",
itemsUnderTag: ({ count }) =>
- count === 1 ? "1 елемент з цим тегом" : `Елементів з цим тегом: ${count}.`,
+ count === 1 ? "1 елемент з цим тегом." : `Елементів з цим тегом: ${count}.`,
showingFirst: ({ count }) => `Показ перших ${count} тегів.`,
totalTags: ({ count }) => `Всього знайдено тегів: ${count}.`,
},
diff --git a/quartz/plugins/transformers/toc.ts b/quartz/plugins/transformers/toc.ts
index 4c31d2062eecc..bfc2f9877fea8 100644
--- a/quartz/plugins/transformers/toc.ts
+++ b/quartz/plugins/transformers/toc.ts
@@ -6,7 +6,7 @@ import Slugger from "github-slugger"
export interface Options {
maxDepth: 1 | 2 | 3 | 4 | 5 | 6
- minEntries: 1
+ minEntries: number
showByDefault: boolean
collapseByDefault: boolean
}
@@ -52,7 +52,7 @@ export const TableOfContents: QuartzTransformerPlugin | undefin
}
})
- if (toc.length > opts.minEntries) {
+ if (toc.length > 0 && toc.length > opts.minEntries) {
file.data.toc = toc.map((entry) => ({
...entry,
depth: entry.depth - highestDepth,