From 5515d2d96327a0fe468b08a04f5f194ff768af12 Mon Sep 17 00:00:00 2001 From: PavelMakarchuk Date: Wed, 20 Nov 2024 17:22:01 -0500 Subject: [PATCH 1/2] Add SALT/AMT calculator Fixes #2218 --- src/PolicyEngine.jsx | 2 ++ src/applets/SaltAMTCalculator.jsx | 33 +++++++++++++++++++++++++++++++ 2 files changed, 35 insertions(+) create mode 100644 src/applets/SaltAMTCalculator.jsx diff --git a/src/PolicyEngine.jsx b/src/PolicyEngine.jsx index 3d6f1165a..7f57382ef 100644 --- a/src/PolicyEngine.jsx +++ b/src/PolicyEngine.jsx @@ -50,6 +50,7 @@ import CTCComparison from "./applets/CTCComparison"; import CTCCalculator from "./applets/CTCCalculator"; import { wrappedResponseJson } from "./data/wrappedJson"; import US2024ElectionCalculator from "./applets/US2024ElectionCalculator"; +import SaltAMTCalculator from "./applets/SaltAMTCalculator"; const PolicyPage = lazy(() => import("./pages/PolicyPage")); const HouseholdPage = lazy(() => import("./pages/HouseholdPage")); @@ -376,6 +377,7 @@ export default function PolicyEngine() { path="/us/2024-election-calculator" element={} /> + } /> {/* Redirect for unrecognized paths */} } /> diff --git a/src/applets/SaltAMTCalculator.jsx b/src/applets/SaltAMTCalculator.jsx new file mode 100644 index 000000000..6fb0a15a3 --- /dev/null +++ b/src/applets/SaltAMTCalculator.jsx @@ -0,0 +1,33 @@ +import Header from "../layout/Header"; +import { Helmet } from "react-helmet"; +import style from "../style"; +import { useWindowHeight } from "../hooks/useWindow"; + +export default function SaltAMTCalculator() { + const windowHeight = useWindowHeight(); + + return ( + <> + + SALT-AMT Calculator | PolicyEngine + +
+
+