-
Notifications
You must be signed in to change notification settings - Fork 16
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 #612 from psarando/CORE-2025-data-limits-announcement
CORE-2025 Add Data Limits dashboard announcement
- Loading branch information
Showing
4 changed files
with
70 additions
and
0 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
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,65 @@ | ||
/** | ||
* A dashboard item for displaying important announcements. | ||
* | ||
* @author psarando | ||
*/ | ||
import React from "react"; | ||
|
||
import { useTranslation, Trans } from "i18n"; | ||
|
||
import { QUOTA_ENFORCE_URL } from "../constants"; | ||
import ExternalLink from "components/utils/ExternalLink"; | ||
|
||
import { | ||
Card, | ||
CardHeader, | ||
CardContent, | ||
Typography, | ||
useTheme, | ||
} from "@mui/material"; | ||
|
||
import AnnounceIcon from "@mui/icons-material/Warning"; | ||
|
||
export default function Announcement() { | ||
const theme = useTheme(); | ||
const { t } = useTranslation("dashboard"); | ||
|
||
return ( | ||
<Card | ||
style={{ | ||
marginTop: theme.spacing(2), | ||
marginBottom: theme.spacing(2), | ||
}} | ||
> | ||
<CardHeader | ||
avatar={ | ||
<AnnounceIcon | ||
style={{ color: theme.palette.gold }} | ||
fontSize="large" | ||
/> | ||
} | ||
title={ | ||
<Typography variant="subtitle2"> | ||
{t("dataStorageLimits")} | ||
</Typography> | ||
} | ||
style={{ | ||
backgroundColor: theme.palette.secondary.main, | ||
color: theme.palette.secondary.contrastText, | ||
}} | ||
/> | ||
<CardContent> | ||
<Typography variant="body2" gutterBottom> | ||
<Trans | ||
t={t} | ||
i18nKey="quotaEnforceAnnouncement" | ||
components={{ | ||
b: <b />, | ||
infoLink: <ExternalLink href={QUOTA_ENFORCE_URL} />, | ||
}} | ||
/> | ||
</Typography> | ||
</CardContent> | ||
</Card> | ||
); | ||
} |
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