Skip to content

Commit

Permalink
Validation messages now explain how to properly delimit values
Browse files Browse the repository at this point in the history
  • Loading branch information
dezoito committed Mar 14, 2024
1 parent 52a6606 commit c3c43e4
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/components/ui/form-grid-params.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -62,31 +62,31 @@ export const ParamsFormSchema = z.object({
temperatureList: z.custom(
(value) => validateNumberOrArray("float")(value as string | number),
{
message: `Invalid float array format. Please enter at least one valid float number.`,
message: `Invalid float array format. Please enter at least one valid float number. Use commas to delimit values.`,
},
),
repeatPenaltyList: z.custom(
(value) => validateNumberOrArray("float")(value as string | number),
{
message: `Invalid float array format. Please enter at least one valid float number.`,
message: `Invalid float array format. Please enter at least one valid float number. Use commas to delimit values.`,
},
),
topKList: z.custom(
(value) => validateNumberOrArray("int")(value as string | number),
{
message: `Invalid int array format. Please enter at least one valid integer number.`,
message: `Invalid int array format. Please enter at least one valid integer number. Use commas to delimit values.`,
},
),
topPList: z.custom(
(value) => validateNumberOrArray("float")(value as string | number),
{
message: `Invalid float array format. Please enter at least one valid float number.`,
message: `Invalid float array format. Please enter at least one valid float number. Use commas to delimit values.`,
},
),
repeatLastNList: z.custom(
(value) => validateNumberOrArray("int")(value as string | number),
{
message: `Invalid float array format. Please enter at least one valid integer number.`,
message: `Invalid float array format. Please enter at least one valid integer number. Use commas to delimit values.`,
},
),
});
Expand Down

0 comments on commit c3c43e4

Please sign in to comment.