- Version 2.0 Release update - Nov 22, 2022
+ Version 2.0 Release update - Dec 19, 2024
New & improved
diff --git a/client/src/components/UpdateBanner/UpdateBanner.module.scss b/client/src/components/UpdateBanner/UpdateBanner.module.scss
new file mode 100644
index 00000000..b1eebe03
--- /dev/null
+++ b/client/src/components/UpdateBanner/UpdateBanner.module.scss
@@ -0,0 +1,29 @@
+@use '../../styles/design-system.scss' as *;
+
+.updateBannerContainer {
+ @include u-bg("gray-cool-2");
+ @include u-padding-bottom(1);
+ @include u-padding-top(1);
+}
+
+.updateBanner {
+ max-width: 70.25rem; // Needs this exact value to align with GovBanner
+ @include u-font("body", "3xs");
+ @include u-line-height('ui', 2);
+ @include u-margin-left(auto);
+ @include u-margin-right(auto);
+
+ @include at-media-max("desktop-lg") {
+ @include u-margin-left(4);
+ @include u-margin-right(4);
+ }
+
+ @include at-media-max("desktop") {
+ @include u-margin-left(2);
+ @include u-margin-right(2);
+ }
+}
+
+.updateBannerAlert {
+ @include u-margin-top(2);
+}
diff --git a/client/src/components/UpdateBanner/UpdateBanner.module.scss.d.ts b/client/src/components/UpdateBanner/UpdateBanner.module.scss.d.ts
new file mode 100644
index 00000000..df0194c7
--- /dev/null
+++ b/client/src/components/UpdateBanner/UpdateBanner.module.scss.d.ts
@@ -0,0 +1,16 @@
+declare namespace UpdateBannerNamespace {
+ export interface IUpdateBannerScss {
+ updateBannerAlert: string;
+ updateBannerContainer: string;
+ updateBanner: string;
+ updatePillIcon: string;
+ updateHeading: string;
+ }
+}
+
+declare const UpdateBannerScssModule: UpdateBannerNamespace.IUpdateBannerScss & {
+ /** WARNING: Only available when `css-loader` is used without `style-loader` or `mini-css-extract-plugin` */
+ locals: UpdateBannerNamespace.IUpdateBannerScss;
+};
+
+export = UpdateBannerScssModule;
diff --git a/client/src/components/UpdateBanner/UpdateBanner.test.tsx b/client/src/components/UpdateBanner/UpdateBanner.test.tsx
new file mode 100644
index 00000000..c7117eb5
--- /dev/null
+++ b/client/src/components/UpdateBanner/UpdateBanner.test.tsx
@@ -0,0 +1,31 @@
+import {render} from '@testing-library/react';
+import * as React from 'react';
+import {LocalizedComponent} from '../../test/testHelpers';
+import UpdateBanner, {cutoffDate} from './UpdateBanner';
+
+describe('rendering of the UpdateBanner', () => {
+ const renderBanner = (mockCurrentDate: Date) => {
+ // make this testable at different dates so we can check large/small versions
+ jest.useFakeTimers()
+ .setSystemTime(mockCurrentDate);
+
+ const result = render(
+
+
+ ,
+ ).asFragment();
+
+ jest.useRealTimers();
+ return result;
+ };
+
+ it('renders large version before cutoff date', () => {
+ const beforeCutoff = new Date(cutoffDate);
+ beforeCutoff.setDate(beforeCutoff.getDate() - 7);
+ expect(renderBanner(beforeCutoff)).toMatchSnapshot();
+ });
+
+ it('renders small version at cutoff date', () => {
+ expect(renderBanner(cutoffDate)).toMatchSnapshot();
+ });
+});
diff --git a/client/src/components/UpdateBanner/UpdateBanner.tsx b/client/src/components/UpdateBanner/UpdateBanner.tsx
new file mode 100644
index 00000000..ed3b909e
--- /dev/null
+++ b/client/src/components/UpdateBanner/UpdateBanner.tsx
@@ -0,0 +1,35 @@
+import React from 'react';
+
+import {Alert} from '@trussworks/react-uswds';
+import * as COMMON_COPY from '../../data/copy/common';
+import * as styles from './UpdateBanner.module.scss';
+
+export const cutoffDate = new Date(2025, 0, 19); // 2025-01-19
+
+const UpdateBanner = () => {
+ const currentDate = new Date();
+
+ // show large version before cutoff date
+ const showLarge = currentDate < cutoffDate;
+
+ if (showLarge) {
+ return (
+
+
+ {COMMON_COPY.UPDATE_BANNER_CONTENT_LARGE}
+
+
+ );
+ } else {
+ return (
+
+
+ {COMMON_COPY.UPDATE_BANNER_CONTENT_SMALL}
+
+
+ );
+ }
+};
+
+export default UpdateBanner;
diff --git a/client/src/components/UpdateBanner/__snapshots__/UpdateBanner.test.tsx.snap b/client/src/components/UpdateBanner/__snapshots__/UpdateBanner.test.tsx.snap
new file mode 100644
index 00000000..6a262d3b
--- /dev/null
+++ b/client/src/components/UpdateBanner/__snapshots__/UpdateBanner.test.tsx.snap
@@ -0,0 +1,40 @@
+// Jest Snapshot v1, https://goo.gl/fbAQLP
+
+exports[`rendering of the UpdateBanner renders large version before cutoff date 1`] = `
+
+
+
+
+
+ Version 2.0 of the tool is now available
+
+
+ The Council on Environmental Quality (CEQ) made the 2.0 version of the tool available on Dec 19, 2024.
+
+
+
+
+
+`;
+
+exports[`rendering of the UpdateBanner renders small version at cutoff date 1`] = `
+
+
+
+
+ This tool has been updated.
+
+ The 2.0 version of the tool was released on Dec 19, 2024.
+
+
+
+`;
diff --git a/client/src/components/UpdateBanner/index.tsx b/client/src/components/UpdateBanner/index.tsx
new file mode 100644
index 00000000..099937b0
--- /dev/null
+++ b/client/src/components/UpdateBanner/index.tsx
@@ -0,0 +1,3 @@
+import UpdateBanner from './UpdateBanner';
+
+export default UpdateBanner;
diff --git a/client/src/data/copy/common.tsx b/client/src/data/copy/common.tsx
index 51651839..9298a3aa 100644
--- a/client/src/data/copy/common.tsx
+++ b/client/src/data/copy/common.tsx
@@ -1,10 +1,10 @@
/* eslint-disable max-len */
/* eslint-disable react/display-name */
-import React from 'react';
import {FormattedDate, FormattedMessage} from 'gatsby-plugin-intl';
+import React from 'react';
import {defineMessages} from 'react-intl';
-import LinkTypeWrapper from '../../components/LinkTypeWrapper';
import DownloadLink from '../../components/DownloadLink';
+import LinkTypeWrapper from '../../components/LinkTypeWrapper';
import {GITHUB_LINK} from '../../constants';
export interface IDefineMessage {
@@ -29,17 +29,37 @@ export const linkFn = (to:string | IDefineMessage, isInternal:boolean, isOpenNew
export const FEEDBACK_EMAIL = 'Screeningtool-Support@omb.eop.gov';
-export const METH_2_0_RELEASE_DATE = new Date(2022, 10, 22, 11, 59, 59); // Nov 22 2022
-export const METH_BETA_RELEASE_DATE = new Date(2022, 1, 18, 11, 59, 59); // Feb 18 2022
+export const METH_1_0_RELEASE_DATE = new Date(2022, 10, 22, 11, 59, 59); // Nov 22 2022
+export const METH_2_0_RELEASE_DATE = new Date(2024, 11, 19, 11, 59, 59); // Dec 19 2024
-// Beta Banner
-export const BETA_BANNER_CONTENT =
This tool has been updated. The 1.0 version of the tool was released on {relDate}.`}
- description={`Alert body that appears on landing page.`}
+// Update Banner
+export const UPDATE_BANNER_HEADING_LARGE = ;
+
+export const UPDATE_BANNER_CONTENT_LARGE = ,
+ }}
+/>;
+
+export const UPDATE_BANNER_CONTENT_SMALL = This tool has been updated. The 2.0 version of the tool was released on {relDate}.`}
+ description={`Alert body that appears at the top of pages.`}
+ values={{
+ bold: boldFn,
relDate: ,
Q4_P1: ,
Q4_P2: ,
Q10: ,
Q11: ,
Q12_P1: ,
Q17_P1: November, 2022. The tool is no longer in beta.`}
+ defaultMessage={`The tool was considered official when Federal agencies started using version 1.0 of the Climate and Economic Justice Screening Tool (CEJST) to help identify disadvantaged communities. The 1.0 version was released in November 2022. The current version, version {currentVersion}, was released in {currentVersionRelease}.`}
description={ 'Navigate to the FAQs page, this will be an answer, Q17_P1'}
values={{
link1: linkFn('https://www.whitehouse.gov/ceq/news-updates/2022/11/22/biden-harris-administration-launches-version-1-0-of-climate-and-economic-justice-screening-tool-key-step-in-implementing-president-bidens-justice40-initiative/', false, true),
+ currentVersion: VERSION_NUMBER,
+ currentVersionRelease: (),
}}
/>,
Q17_P2: technical support and other documentation and send feedback.",
"description": "Alert title that appears at the top of pages."
},
- "common.pages.alerts.banner.beta.content": {
- "defaultMessage": "This tool has been updated. The 1.0 version of the tool was released on {relDate}.",
- "description": "Alert body that appears on landing page."
+ "common.pages.alerts.banner.update.content.large": {
+ "defaultMessage": "The Council on Environmental Quality (CEQ) made the 2.0 version of the tool available on {releaseDate}.",
+ "description": "Alert body that appears at the top of pages."
+ },
+ "common.pages.alerts.banner.update.content.small": {
+ "defaultMessage": "This tool has been updated. The 2.0 version of the tool was released on {relDate}.",
+ "description": "Alert body that appears at the top of pages."
+ },
+ "common.pages.alerts.banner.update.heading.large": {
+ "defaultMessage": "Version 2.0 of the tool is now available",
+ "description": "Alert heading that appears at the top of pages"
},
"common.pages.alerts.census.tract.title": {
"defaultMessage": "Additional documentation now available",
@@ -256,7 +264,7 @@
},
"common.pages.tsd.url": {
"defaultMessage": "https://static-data-screeningtool.geoplatform.gov/data-pipeline/data/score/downloadable/cejst_technical_support_document.pdf",
- "description": "Navigate to the Alerts on any page. This will be the link to the techinical support document."
+ "description": "Navigate to the Alerts on any page. This will be the link to the technical support document."
},
"contact.page.census.tract.feedback.para3": {
"defaultMessage": "The best way to contact the Council on Environmental Quality (CEQ) is by filling out this form.",
@@ -1591,11 +1599,11 @@
"description": "Navigate to the FAQs page, this will be Q9"
},
"faqs.page.answers.Q10": {
- "defaultMessage": "Recent historic legislation, such as the Bipartisan Infrastructure Law and the Inflation Reduction Act, have created new programs or directed funds to existing programs. These investments are included in the Justice40 Initiative if they meet the eligibility criteria. Agencies will use the tool to help identify disadvantaged communities that will receive 40% of the overall benefits of those Justice40 programs.",
+ "defaultMessage": "Historic legislation, such as the Bipartisan Infrastructure Law and the Inflation Reduction Act, has created new programs and directed funds to existing ones. These investments are included in the Justice40 Initiative if they meet the eligibility criteria. Agencies will use the tool to help identify disadvantaged communities that will receive 40% of the overall benefits of those Justice40 programs.",
"description": "Navigate to the FAQs page, this will be an answer, Q10"
},
"faqs.page.answers.Q11": {
- "defaultMessage": "The Council on Environmental Quality (CEQ), the Office of Management and Budget (OMB), and the Climate Policy Office (CPO) released the Justice40 Interim Implementation Guidance on July 20, 2021. It directed agencies to develop interim definitions of disadvantaged communities. Agencies used their interim definitions during the tool’s beta phase. Agencies will now transition to using version 1.0 of the tool to geographically identify disadvantaged communities.",
+ "defaultMessage": "The Council on Environmental Quality (CEQ), the Office of Management and Budget (OMB), and the Climate Policy Office (CPO) released the Justice40 Interim Implementation Guidance on July 20, 2021. It directed agencies to develop interim definitions of disadvantaged communities. Agencies used their interim definitions during the CEJST’s beta phase, and are now using version {currentVersion} as the primary tool to geographically identify disadvantaged communities.",
"description": "Navigate to the FAQs page, this will be an answer, Q11"
},
"faqs.page.answers.Q12_P1": {
@@ -1683,7 +1691,7 @@
"description": "Navigate to the FAQs page, this will be an answer, Q16"
},
"faqs.page.answers.Q17_P1": {
- "defaultMessage": "The tool is now considered official because Federal agencies can now use version 1.0 of the Climate and Economic Justice Screening Tool (CEJST) to help identify disadvantaged communities. The 1.0 version was released in November, 2022. The tool is no longer in beta.",
+ "defaultMessage": "The tool was considered official when Federal agencies started using version 1.0 of the Climate and Economic Justice Screening Tool (CEJST) to help identify disadvantaged communities. The 1.0 version was released in November 2022. The current version, version {currentVersion}, was released in {currentVersionRelease}.",
"description": "Navigate to the FAQs page, this will be an answer, Q17_P1"
},
"faqs.page.answers.Q17_P2": {
@@ -1767,7 +1775,7 @@
"description": "Navigate to the FAQs page, this will be an answer, Q3_P3"
},
"faqs.page.answers.Q4_P1": {
- "defaultMessage": "Yes, the version 1.0 of the CEJST has some data for all the territories but not all the CEJST data are available or used for all U.S. territories.",
+ "defaultMessage": "Yes, version {currentVersion} of the CEJST has some data for all the territories, but not all the CEJST data are available or used for all U.S. territories.",
"description": "Navigate to the FAQs page, this will be an answer, Q4_P1"
},
"faqs.page.answers.Q4_P2": {
diff --git a/client/src/pages/tests/__snapshots__/about.test.tsx.snap b/client/src/pages/tests/__snapshots__/about.test.tsx.snap
index 1369708a..41b3af5b 100644
--- a/client/src/pages/tests/__snapshots__/about.test.tsx.snap
+++ b/client/src/pages/tests/__snapshots__/about.test.tsx.snap
@@ -140,32 +140,27 @@ exports[`rendering of the DatasetContainer checks if various text fields are vis