mirror of
https://github.com/fosrl/pangolin.git
synced 2025-08-18 00:09:34 +02:00
fix email and allow localhost in ip field
This commit is contained in:
parent
e0875b361d
commit
bb16fd1db8
3 changed files with 4 additions and 1 deletions
|
@ -1,3 +1,5 @@
|
||||||
|
import React from "react";
|
||||||
|
|
||||||
export default function ButtonLink({
|
export default function ButtonLink({
|
||||||
href,
|
href,
|
||||||
children,
|
children,
|
||||||
|
|
|
@ -65,7 +65,7 @@ import {
|
||||||
import { SwitchInput } from "@app/components/SwitchInput";
|
import { SwitchInput } from "@app/components/SwitchInput";
|
||||||
|
|
||||||
const addTargetSchema = z.object({
|
const addTargetSchema = z.object({
|
||||||
ip: z.string().ip(),
|
ip: z.union([z.string().ip(), z.literal("localhost")]),
|
||||||
method: z.string(),
|
method: z.string(),
|
||||||
port: z.coerce.number().int().positive()
|
port: z.coerce.number().int().positive()
|
||||||
// protocol: z.string(),
|
// protocol: z.string(),
|
||||||
|
|
|
@ -149,6 +149,7 @@ export default function GeneralForm() {
|
||||||
<form
|
<form
|
||||||
onSubmit={form.handleSubmit(onSubmit)}
|
onSubmit={form.handleSubmit(onSubmit)}
|
||||||
className="space-y-4"
|
className="space-y-4"
|
||||||
|
id="general-settings-form"
|
||||||
>
|
>
|
||||||
<FormField
|
<FormField
|
||||||
control={form.control}
|
control={form.control}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue