fix(fava): Respect ledger ordering

This commit pulls in an upstream patch which I made in
<https://github.com/beancount/fava/pull/1833>. The upstream patch is a
fix for the issue.

Change-Id: I33d93f01a04d774dfe1ba2dbc13bc99231e4846b
Reviewed-on: https://git.clicks.codes/c/Infra/NixFiles/+/794
Reviewed-by: Samuel Shuert <coded@clicks.codes>
Tested-by: Skyler Grey <minion@clicks.codes>
diff --git a/overlays/fava/default.nix b/overlays/fava/default.nix
new file mode 100644
index 0000000..1a9d549
--- /dev/null
+++ b/overlays/fava/default.nix
@@ -0,0 +1,24 @@
+# SPDX-FileCopyrightText: 2024 Clicks Codes
+#
+# SPDX-License-Identifier: GPL-3.0-only
+
+{inputs, ...}: final: prev: {
+  fava = prev.fava.overrideAttrs (prevAttrs: let
+    version = "1.28";
+  in {
+    inherit version;
+    src = prev.fetchPypi {
+      pname = "fava";
+      inherit version;
+      hash = "sha256-sWHVkR0/0VMGzH5OMxOCK4usf7G0odzMtr82ESRQhrk=";
+    };
+
+    propagatedBuildInputs = prevAttrs.propagatedBuildInputs ++ [
+      prev.python3.pkgs.watchfiles
+    ];
+
+    patches = (prevAttrs.patches or []) ++ [
+      ./1833-respect-ordering.patch
+    ];
+  });
+}