mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-08-28 22:17:13 +00:00
fix(frontend): clean test validation output
This commit is contained in:
@@ -104,6 +104,15 @@ export const AllSettingSchema = z.object({
|
||||
|
||||
export type AllSettingInput = z.infer<typeof AllSettingSchema>;
|
||||
|
||||
// Existing installations can contain regex values saved before the backend
|
||||
// enforced its 2,048-character limit. Accept those values when reading so the
|
||||
// settings page can display and let users correct them, while keeping the
|
||||
// stricter schema above for outgoing updates.
|
||||
export const AllSettingResponseSchema = AllSettingSchema.extend({
|
||||
subJsonUserAgentRegex: z.string().optional(),
|
||||
subClashUserAgentRegex: z.string().optional(),
|
||||
});
|
||||
|
||||
export const FactoryDefaultsSchema = z.record(z.string(), z.string());
|
||||
|
||||
export type FactoryDefaults = z.infer<typeof FactoryDefaultsSchema>;
|
||||
|
||||
Reference in New Issue
Block a user