From ab5efac75fb0f20afe74bef33a2cf7e9ba0ba40f Mon Sep 17 00:00:00 2001
From: bfahrenfort <59982409+bfahrenfort@users.noreply.github.com>
Date: Sun, 01 Oct 2023 16:47:22 +0000
Subject: [PATCH] Fix: RSS title escaping (#521)

---
 quartz/components/Explorer.tsx |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/quartz/components/Explorer.tsx b/quartz/components/Explorer.tsx
index de6b5e0..79d8781 100644
--- a/quartz/components/Explorer.tsx
+++ b/quartz/components/Explorer.tsx
@@ -15,7 +15,12 @@
   sortFn: (a, b) => {
     // Sort order: folders first, then files. Sort folders and files alphabetically
     if ((!a.file && !b.file) || (a.file && b.file)) {
-      return a.displayName.localeCompare(b.displayName)
+      // numeric: true: Whether numeric collation should be used, such that "1" < "2" < "10"
+      // sensitivity: "base": Only strings that differ in base letters compare as unequal. Examples: a ≠ b, a = á, a = A
+      return a.displayName.localeCompare(b.displayName, undefined, {
+        numeric: true,
+        sensitivity: "base",
+      })
     }
     if (a.file && !b.file) {
       return 1

--
Gitblit v1.10.0