mirror of
https://github.com/DOI-DO/j40-cejst-2.git
synced 2025-08-03 12:54:19 -07:00
* Add gherkin tests for page navigation links - test that every page will load when navigating from any other page - update snapshots * Add gherkin workflows 2 - 5 - add test for Federal program officer key information and CTA - add test for Community members key information and CTA - add test for Send feedback - add test for Join the Open Source community - update snapshots * Add gherkin tests for footer links - add footerlinks feature gherkin file - adds a comment to the hyphenizeString() - adds keyword functions for footer - adds data-cy tags to footer component - updates snapshots * Adds workflow to learn more about EO * Add gherkin test for dataset links - add data-cy tags to dataset sections - modify Cy command functions names - update snapshots * Add cypress test to deploy_staging.yml * Add working directory env * Remove keywords.js from cypress test * Add a Then step to all About and Footer tests * Refactor step definitions - use globalStepDefinitions - rename keywords to commonSteps - remove keyword from exclusion list
77 lines
2.5 KiB
TypeScript
77 lines
2.5 KiB
TypeScript
import React from 'react';
|
|
import {useIntl} from 'gatsby-plugin-intl';
|
|
import {Grid} from '@trussworks/react-uswds';
|
|
|
|
import AlertWrapper from '../AlertWrapper';
|
|
import DatasetCard from '../DatasetCard';
|
|
import J40MainGridContainer from '../J40MainGridContainer';
|
|
import {hyphenizeString} from '../../../cypress/integration/common/helpers';
|
|
|
|
import * as styles from './dsContainer.module.scss';
|
|
import * as METHODOLOGY_COPY from '../../data/copy/methodology';
|
|
|
|
|
|
const DatasetContainer = () => {
|
|
const intl = useIntl();
|
|
|
|
return (
|
|
<>
|
|
<J40MainGridContainer fullWidth={true} blueBackground={true}>
|
|
<J40MainGridContainer
|
|
dataCy={`${hyphenizeString(METHODOLOGY_COPY.DATASETS.HEADING.defaultMessage)}-block`}>
|
|
|
|
<Grid row>
|
|
<Grid col={12}>
|
|
<AlertWrapper showBetaAlert={false} showLimitedDataAlert={true}/>
|
|
<h2>{intl.formatMessage(METHODOLOGY_COPY.DATASETS.HEADING)}</h2>
|
|
</Grid>
|
|
</Grid>
|
|
|
|
<Grid row>
|
|
<Grid col={12} tablet={{col: 7}} className={'j40-mb-3'}>
|
|
<p>{intl.formatMessage(METHODOLOGY_COPY.DATASETS.INFO)}</p>
|
|
</Grid>
|
|
</Grid>
|
|
|
|
<div className={styles.datasetCardsContainer}>
|
|
{METHODOLOGY_COPY.INDICATORS.map((card) => <DatasetCard
|
|
key={card.indicator}
|
|
datasetCardProps={card}
|
|
additionalIndicator={false}
|
|
/>)}
|
|
</div>
|
|
|
|
</J40MainGridContainer>
|
|
</J40MainGridContainer>
|
|
|
|
<J40MainGridContainer fullWidth={true} blueBackground={false} >
|
|
<J40MainGridContainer
|
|
dataCy={`${hyphenizeString(METHODOLOGY_COPY.DATASETS.ADDITIONAL_HEADING.defaultMessage)}-block`}>
|
|
|
|
<Grid row>
|
|
<Grid col={12}>
|
|
<h2>{intl.formatMessage(METHODOLOGY_COPY.DATASETS.ADDITIONAL_HEADING)}</h2>
|
|
</Grid>
|
|
</Grid>
|
|
|
|
<Grid row>
|
|
<Grid col={12} tablet={{col: 7}} className={'j40-mb-3'}>
|
|
<p>{intl.formatMessage(METHODOLOGY_COPY.DATASETS.ADDITIONAL_INFO)}</p>
|
|
</Grid>
|
|
</Grid>
|
|
|
|
<div className={styles.datasetCardsContainer}>
|
|
{METHODOLOGY_COPY.ADDITIONAL_INDICATORS.map((card) => <DatasetCard
|
|
key={card.indicator}
|
|
datasetCardProps={card}
|
|
additionalIndicator={true}
|
|
/>)}
|
|
</div>
|
|
|
|
</J40MainGridContainer>
|
|
</J40MainGridContainer>
|
|
</>
|
|
);
|
|
};
|
|
|
|
export default DatasetContainer;
|