/* eslint-disable max-len */
/* eslint-disable react/display-name */
import React from 'react';
import {FormattedDate, FormattedMessage} from 'gatsby-plugin-intl';
import {defineMessages} from 'react-intl';
import LinkTypeWrapper from '../../components/LinkTypeWrapper';
export interface IDefineMessage {
id: string,
defaultMessage: string,
description: string,
};
/*
* i18n curried functions from react-intl (aka format.js)
* using ver3 of the docs as this is what gatsby-plugin-intl uses:
* https://formatjs.io/docs/react-intl/upgrade-guide-3x#enhanced-formattedmessage--formatmessage-rich-text-formatting
*
* */
export const italicFn = (str:string) => {str};
export const boldFn = (str:string) => {str};
export const simpleLink = (href:string) => (str:string) => {str};
// eslint-disable-next-line max-len
export const linkFn = (to:string | IDefineMessage, isInternal:boolean, isOpenNewTab:boolean) => (str:string) => ;
export const FEEDBACK_EMAIL = 'Screeningtool-Support@omb.eop.gov';
// Beta Banner
export const BETA_BANNER = defineMessages({
TITLE: {
id: 'common.pages.banner.beta.title',
defaultMessage: 'This is a beta site.',
description: 'Navigate to the about page. This is the main title of the beta banner',
},
INFO: {
id: 'common.pages.banner.beta.info',
defaultMessage: `It is an early, in-progress version of the tool with limited datasets that will
be regularly updated.`,
description: 'Navigate to the about page. This is the main info of the beta banner',
},
});
export const TSD = defineMessages({
URL: {
id: '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.',
},
});
// Alerts
// Expiration month is zero-based: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/getMonth
const ALERT_1_EXPIRATION_DATE= new Date(2022, 4, 25); // May 25
export const ALERTS = {
ALERT_1_TITLE: defineMessages({
TITLE: {
id: 'common.pages.alerts.public_comment_period.title',
defaultMessage: 'Public comment period extended',
description: 'Alert title that appears on landing page.',
},
}),
EXPIRATION_DATE: ALERT_1_EXPIRATION_DATE,
ALERT_1_DESCRIPTION: