mirror of
https://github.com/fosrl/pangolin.git
synced 2025-08-21 09:48:39 +02:00
Watch target inputs
This commit is contained in:
parent
6d519af198
commit
f438d2ddbf
1 changed files with 4 additions and 6 deletions
|
@ -163,6 +163,9 @@ export default function ReverseProxyTargets(props: {
|
||||||
} as z.infer<typeof addTargetSchema>
|
} as z.infer<typeof addTargetSchema>
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const watchedIp = addTargetForm.watch("ip");
|
||||||
|
const watchedPort = addTargetForm.watch("port");
|
||||||
|
|
||||||
const tlsSettingsForm = useForm<TlsSettingsValues>({
|
const tlsSettingsForm = useForm<TlsSettingsValues>({
|
||||||
resolver: zodResolver(tlsSettingsSchema),
|
resolver: zodResolver(tlsSettingsSchema),
|
||||||
defaultValues: {
|
defaultValues: {
|
||||||
|
@ -818,12 +821,7 @@ export default function ReverseProxyTargets(props: {
|
||||||
type="submit"
|
type="submit"
|
||||||
variant="outlinePrimary"
|
variant="outlinePrimary"
|
||||||
className="mt-6"
|
className="mt-6"
|
||||||
disabled={
|
disabled={!(watchedIp && watchedPort)}
|
||||||
!(
|
|
||||||
addTargetForm.getValues("ip") &&
|
|
||||||
addTargetForm.getValues("port")
|
|
||||||
)
|
|
||||||
}
|
|
||||||
>
|
>
|
||||||
Add Target
|
Add Target
|
||||||
</Button>
|
</Button>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue