]> Lady’s Gitweb - GitWikiWeb/commitdiff
Allow negative years in timelines
authorLady <redacted>
Sat, 23 Sep 2023 23:48:30 +0000 (19:48 -0400)
committerLady <redacted>
Sat, 23 Sep 2023 23:48:30 +0000 (19:48 -0400)
build.js

index 2381a51c426a552ca7d4620385c2678098d08a54..97bb702d6996af1f9e7f3ca3af1dc103c50e784a 100644 (file)
--- a/build.js
+++ b/build.js
@@ -257,7 +257,7 @@ class GitWikiWebPage {
                       return {
                         label: text,
                         year:
-                          /^([0-9X]{4})(?:-[0-9X]{2}(?:-[0-9X]{2})?)?$/u
+                          /^(-?[0-9X]{4})(?:-[0-9X]{2}(?:-[0-9X]{2})?)?$/u
                             .exec(text)?.[1] ?? text,
                       };
                     }
This page took 0.020075 seconds and 4 git commands to generate.