improve form

This commit is contained in:
mohadeseh safari committed 2025-03-25 20:54:50 -04:00
1 parent 89d010a54b
commit a5780efff5
1 file changed
+7 -8
+7 -8
View File
@@ -41,9 +41,9 @@ const CreateMonitor = () => {
]; ];
const expectedValuePlaceholders = { const expectedValuePlaceholders = {
regex: "^[\w.-]+@gmail.com$", regex: "^2[0-9]{2}$",
equal: "janet@gmail.com", equal: "200",
include: "@gmail.com", include: "success",
}; };
const monitorTypeMaps = { const monitorTypeMaps = {
@@ -465,8 +465,7 @@ const CreateMonitor = () => {
color={theme.palette.primary.contrastTextTertiary} color={theme.palette.primary.contrastTextTertiary}
opacity={0.8} opacity={0.8}
> >
The expected value is used to match against response result, and the The expected value to check in the response. Examples: HTTP status code, text in response body, or specific value from JSON data.
match determines the status.
</Typography> </Typography>
</Stack> </Stack>
<Stack> <Stack>
@@ -475,7 +474,7 @@ const CreateMonitor = () => {
id="json-path" id="json-path"
label="JSON Path" label="JSON Path"
isOptional={true} isOptional={true}
placeholder="data.email" placeholder="data.status"
value={monitor.jsonPath} value={monitor.jsonPath}
onChange={(event) => handleChange(event, "jsonPath")} onChange={(event) => handleChange(event, "jsonPath")}
error={errors["jsonPath"] ? true : false} error={errors["jsonPath"] ? true : false}
@@ -486,8 +485,8 @@ const CreateMonitor = () => {
color={theme.palette.primary.contrastTextTertiary} color={theme.palette.primary.contrastTextTertiary}
opacity={0.8} opacity={0.8}
> >
This expression will be evaluated against the reponse JSON data and Optional path to extract specific data from JSON responses. Common examples: "status", "data.status", "meta.code". Leave empty to check the entire response.
the result will be used to match against the expected value. See&nbsp; See&nbsp;
<Typography <Typography
component="a" component="a"
href="https://jmespath.org/" href="https://jmespath.org/"