generated from ncsa/react-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #215 from policy-design-lab/release-0.12.0
Release 0.12.0
- Loading branch information
Showing
12 changed files
with
412 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,102 @@ | ||
import { Button, Grid, Typography } from "@mui/material"; | ||
import { makeStyles } from "@mui/styles"; | ||
import * as React from "react"; | ||
import DownloadIcon from "@mui/icons-material/Download"; | ||
|
||
export default function CardIFrame({ | ||
title, | ||
author, | ||
date, | ||
link, | ||
iframeTitle, | ||
iframeLink, | ||
iframeWidth, | ||
iframeHeight | ||
}): JSX.Element { | ||
const useStyles = makeStyles(() => ({ | ||
downloadButton: { | ||
"&:hover": { | ||
backgroundColor: "transparent" | ||
} | ||
} | ||
})); | ||
const classes = useStyles(); | ||
|
||
return ( | ||
<Grid container className="paperCard" sx={{ display: "flex", justifyContent: "space-between" }}> | ||
<Grid container xs={12} sm={12}> | ||
<Grid className="inCardContainer mainItems" container xs={12} sm={12}> | ||
<Grid | ||
container | ||
xs={12} | ||
sm={12} | ||
sx={{ display: "flex", alignItems: "center", justifyContent: "space-between" }} | ||
> | ||
<Grid item xs={12} sm={9}> | ||
<Typography variant="h3" component="div"> | ||
{title} | ||
</Typography> | ||
</Grid> | ||
<Grid item xs={12} sm={3} sx={{ display: "flex", justifyContent: "end" }}> | ||
<a href={link} target="_blank" rel="noopener noreferrer"> | ||
<Button | ||
variant="contained" | ||
className={classes.downloadButton} | ||
sx={{ | ||
border: "2px solid #2F7164", | ||
backgroundColor: "transparent", | ||
color: "#2F7164", | ||
minWidth: 15, | ||
minHeight: 4, | ||
borderRadius: 0 | ||
}} | ||
> | ||
<Typography variant="subtitle1"> | ||
<strong>Download PDF</strong> | ||
</Typography>{" "} | ||
<DownloadIcon sx={{ mx: 1, my: 2 }} /> | ||
</Button> | ||
</a> | ||
</Grid> | ||
</Grid> | ||
</Grid> | ||
<Grid className="inCardContainer subItems" container xs={12} sm={12} sx={{ display: "flex" }}> | ||
<Grid item xs={12} sm={6}> | ||
<Typography variant="body1" component="div"> | ||
Author: {author} | ||
</Typography> | ||
</Grid> | ||
<Grid item xs={12} sm={6} sx={{ display: "flex", justifyContent: "end" }}> | ||
<Typography variant="body1" component="div"> | ||
Date: {date} | ||
</Typography> | ||
</Grid> | ||
</Grid> | ||
<Grid item xs={12} sm={12} className="inCardContainer subItems" sx={{ justifyContent: "center" }}> | ||
<Typography variant="body1" component="div"> | ||
As Congress considers reauthorizing the Farm Bill, vital resources that are available to farmers | ||
and ranchers today are at risk — specifically the $18 billion investment from the Inflation | ||
Reduction Act (IRA) for the U.S. Department of Agriculture’s (USDA) popular conservation | ||
programs. This issue brief provides a first look at what farmers stand to lose in each state if | ||
these investments are eliminated by Congress. | ||
</Typography> | ||
</Grid> | ||
<Grid | ||
className="inCardContainer subItems" | ||
container | ||
xs={12} | ||
sm={12} | ||
sx={{ display: "flex", justifyContent: "center" }} | ||
> | ||
<iframe | ||
title={iframeTitle} | ||
width={iframeWidth} | ||
height={iframeHeight} | ||
src={iframeLink} | ||
allowFullScreen | ||
/> | ||
</Grid> | ||
</Grid> | ||
</Grid> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
import { Button, Grid, Typography } from "@mui/material"; | ||
import { makeStyles } from "@mui/styles"; | ||
import * as React from "react"; | ||
import DownloadIcon from "@mui/icons-material/Download"; | ||
|
||
export default function CardPaper({ title, author, date, link }): JSX.Element { | ||
const useStyles = makeStyles(() => ({ | ||
downloadButton: { | ||
"&:hover": { | ||
backgroundColor: "transparent" | ||
} | ||
} | ||
})); | ||
const classes = useStyles(); | ||
return ( | ||
<Grid | ||
container | ||
className="paperCard" | ||
sx={{ display: "flex", alignItems: "end", justifyContent: "space-between" }} | ||
> | ||
<Grid container xs={12} sm={7}> | ||
<Grid className="inCardContainer mainItems" container xs={12} sm={12}> | ||
<Grid item xs={12} sm={12}> | ||
<Typography variant="h3" component="div"> | ||
{title} | ||
</Typography> | ||
</Grid> | ||
</Grid> | ||
<Grid | ||
className="inCardContainer subItems" | ||
container | ||
xs={12} | ||
sm={8} | ||
sx={{ display: "flex", justifyContent: "space-between" }} | ||
> | ||
<Grid item xs={12} sm={8}> | ||
<Typography variant="body1" component="div"> | ||
Author: {author} | ||
</Typography> | ||
</Grid> | ||
<Grid item xs={12} sm={4}> | ||
<Typography variant="body1" component="div"> | ||
Date: {date} | ||
</Typography> | ||
</Grid> | ||
</Grid> | ||
</Grid> | ||
|
||
<Grid container xs={12} sm={5} sx={{ display: "flex", justifyContent: "flex-end" }}> | ||
<a href={link} target="_blank" rel="noopener noreferrer"> | ||
<Button | ||
variant="contained" | ||
className={classes.downloadButton} | ||
sx={{ | ||
border: "2px solid #2F7164", | ||
backgroundColor: "transparent", | ||
color: "#2F7164", | ||
minWidth: 15, | ||
minHeight: 4, | ||
borderRadius: 0 | ||
}} | ||
> | ||
<Typography variant="subtitle1"> | ||
<strong>Download PDF</strong> | ||
</Typography>{" "} | ||
<DownloadIcon sx={{ mx: 1, my: 2 }} /> | ||
</Button> | ||
</a> | ||
</Grid> | ||
</Grid> | ||
); | ||
} |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.