pagespeed key alert

This commit is contained in:
Alex Holliday committed 2026-01-26 20:47:10 +00:00
1 parent 1819df5117
commit 90e9b41973
3 files changed
+29 -21

No files matched your search

@@ -12,13 +12,11 @@ import CircularProgress from "@mui/material/CircularProgress";
import type { StackProps } from "@mui/material/Stack";
import { useTheme } from "@mui/material/styles";
import { useTranslation } from "react-i18next";
import { Trans, useTranslation } from "react-i18next";
import { Link as RouterLink } from "react-router-dom";
import { Typography } from "@mui/material";
export const PageSpeedKeyPriorityFallback = () => {
const theme = useTheme();
const { t } = useTranslation();
return (
<BaseFallback>
<Alert
@@ -26,23 +24,23 @@ export const PageSpeedKeyPriorityFallback = () => {
sx={{
width: "100%",
maxWidth: 600,
backgroundColor: theme.palette.warning.light,
color: theme.palette.warning.contrastText,
"& .MuiAlert-icon": {
color: theme.palette.warning.contrastText,
},
}}
>
{t("pageSpeedWarning")}{" "}
<Link
component={RouterLink}
to="/settings"
color="inherit"
fontWeight="inherit"
>
{t("pageSpeedLearnMoreLink")}
</Link>{" "}
{t("pageSpeedAddApiKey")}
<Typography>
<Trans
i18nKey="common.alerts.pageSpeedApiKey.content"
components={{
settingsLink: (
<Link
component={RouterLink}
to="/settings"
color="inherit"
fontWeight="inherit"
/>
),
}}
/>
</Typography>
</Alert>
</BaseFallback>
);
@@ -178,8 +176,8 @@ export const MonitorBasePageWithStates = ({
if (priorityFallback) {
return (
<BasePage
loading={false}
error={false}
loading={loading}
error={error}
{...props}
>
{priorityFallback}