From 471bddcedb38c42e03b8b0a9d40df87db75b92b1 Mon Sep 17 00:00:00 2001 From: Maxwell Austensen Date: Thu, 11 Dec 2025 13:17:28 -0500 Subject: [PATCH 1/2] remove contentful-common-strings and the old covid banner using it --- package.json | 6 +-- src/components/header.tsx | 38 -------------- yarn.lock | 106 +------------------------------------- 3 files changed, 4 insertions(+), 146 deletions(-) diff --git a/package.json b/package.json index 5e821b34..d1d3eeb3 100644 --- a/package.json +++ b/package.json @@ -9,7 +9,6 @@ "@contentful/rich-text-plain-text-renderer": "^13.4.0", "@contentful/rich-text-react-renderer": "^15.0.0", "@contentful/rich-text-types": "^14.1.0", - "@justfixnyc/contentful-common-strings": "^0.1.0", "@justfixnyc/geosearch-requester": "^0.0.6", "@justfixnyc/util": "^0.4.1", "@lingui/react": "^2.8.3", @@ -78,9 +77,8 @@ "scripts": { "postinstall": "lingui compile", "lingui": "lingui", - "build": "yarn contentful-common-strings && gatsby build", - "develop": "yarn contentful-common-strings --dev && gatsby develop", - "contentful-common-strings": "contentful-common-strings fetch -o src/common-strings.json", + "build": "gatsby build", + "develop": "gatsby develop", "format": "prettier --write '**/*.tsx'", "prettier": "prettier", "prettier:check": "prettier \"**/*.{ts,tsx,js,scss}\" --check", diff --git a/src/components/header.tsx b/src/components/header.tsx index 42b17008..83e03217 100644 --- a/src/components/header.tsx +++ b/src/components/header.tsx @@ -3,17 +3,12 @@ import { Trans } from "@lingui/macro"; import "../styles/header.scss"; import { LocaleLink } from "../components/locale-link"; -import { useCurrentLocale } from "../util/use-locale"; -import { ContentfulCommonStrings } from "@justfixnyc/contentful-common-strings"; import _commonStrings from "../common-strings.json"; -import { documentToReactComponents } from "@contentful/rich-text-react-renderer"; -import { INLINES } from "@contentful/rich-text-types"; import { OutboundLink } from "../util/links"; import FocusTrap from "focus-trap-react"; import { FooterLanguageToggle } from "./footer"; import classnames from "classnames"; -const commonStrings = new ContentfulCommonStrings(_commonStrings as any); const isDemoSite = process.env.GATSBY_DEMO_SITE === "1"; @@ -70,38 +65,6 @@ const useScrollDirection = (): "up" | "down" => { return scrollDir; }; -const MoratoriumBanner: React.FC<{}> = () => { - const [isVisible, setVisibility] = useState(true); - const locale = useCurrentLocale(); - - const content = commonStrings.get("covidMoratoriumBanner", locale); - if (!content) return null; - - return ( -
-
-
-
-
-
- ); -}; - const HeaderLink: React.FC<{ link: LinkWithLabel }> = ({ link }) => link[0].charAt(0) === "/" ? (
- {isLandingPage && } Date: Thu, 11 Dec 2025 13:18:04 -0500 Subject: [PATCH 2/2] format --- src/components/header.tsx | 1 - 1 file changed, 1 deletion(-) diff --git a/src/components/header.tsx b/src/components/header.tsx index 83e03217..2d1b0d4b 100644 --- a/src/components/header.tsx +++ b/src/components/header.tsx @@ -9,7 +9,6 @@ import FocusTrap from "focus-trap-react"; import { FooterLanguageToggle } from "./footer"; import classnames from "classnames"; - const isDemoSite = process.env.GATSBY_DEMO_SITE === "1"; export const CAREERS_PAGE_URL = "https://justfix.breezy.hr/";