diff --git a/client/src/Pages/PageSpeed/Create/index.css b/client/src/Pages/PageSpeed/Create/index.css
index 89a7c3466..e69de29bb 100644
--- a/client/src/Pages/PageSpeed/Create/index.css
+++ b/client/src/Pages/PageSpeed/Create/index.css
@@ -1,9 +0,0 @@
-.configure-pagespeed button {
- height: var(--env-var-height-2);
-}
-
-.configure-pagespeed .field,
-.configure-pagespeed .section-disabled,
-.configure-pagespeed .select-wrapper {
- flex: 1;
-}
diff --git a/client/src/Pages/PageSpeed/Create/index.jsx b/client/src/Pages/PageSpeed/Create/index.jsx
index 8ebe5ca5e..c2ab81add 100644
--- a/client/src/Pages/PageSpeed/Create/index.jsx
+++ b/client/src/Pages/PageSpeed/Create/index.jsx
@@ -33,21 +33,9 @@ import {
usePauseMonitor,
} from "../../../Hooks/monitorHooks";
-// Constants
-const MS_PER_MINUTE = 60000;
-const FREQUENCIES = [
- { _id: 3, name: "3 minutes" },
- { _id: 5, name: "5 minutes" },
- { _id: 10, name: "10 minutes" },
- { _id: 20, name: "20 minutes" },
- { _id: 60, name: "1 hour" },
- { _id: 1440, name: "1 day" },
- { _id: 10080, name: "1 week" },
-];
-
-const PageSpeedSetup = ({ configure }) => {
- const isConfigure = configure;
+const PageSpeedSetup = () => {
const { monitorId } = useParams();
+ const isConfigure = !!monitorId;
const CRUMBS = [
{ name: "pagespeed", path: "/pagespeed" },
...(isConfigure
@@ -82,6 +70,17 @@ const PageSpeedSetup = ({ configure }) => {
// Setup
const { t } = useTranslation();
const theme = useTheme();
+ // Constants
+ const MS_PER_MINUTE = 60000;
+ const FREQUENCIES = [
+ { _id: 3, name: t("time.threeMinutes") },
+ { _id: 5, name: t("time.fiveMinutes") },
+ { _id: 10, name: t("time.tenMinutes") },
+ { _id: 20, name: t("time.twentyMinutes") },
+ { _id: 60, name: t("time.oneHour") },
+ { _id: 1440, name: t("time.oneDay") },
+ { _id: 10080, name: t("time.oneWeek") },
+ ];
const { user } = useSelector((state) => state.auth);
const { statusColor, pagespeedStatusMsg, determineState } = useMonitorUtils();
@@ -117,7 +116,7 @@ const PageSpeedSetup = ({ configure }) => {
newErrors[err.path[0]] = err.message;
});
setErrors(newErrors);
- createToast({ body: "Please check the form for errors." });
+ createToast({ body: t("checkFormError") });
return;
}
@@ -352,7 +351,7 @@ const PageSpeedSetup = ({ configure }) => {
type={"url"}
name="url"
id="monitor-url"
- label={isConfigure ? t("url") : "URL to monitor"}
+ label={isConfigure ? t("url") : t("urlMonitor")}
startAdornment={
!isConfigure ? : undefined
}
@@ -396,7 +395,7 @@ const PageSpeedSetup = ({ configure }) => {
{
/>
}
+ element={}
/>