mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-07 00:27:30 +00:00
Minor frontend fixes on Azure App Connection forms
This commit is contained in:
+7
-3
@@ -120,7 +120,7 @@ export const AzureAppConfigurationConnectionForm = ({ appConnection, onSubmit }:
|
|||||||
|
|
||||||
const selectedMethod = watch("method");
|
const selectedMethod = watch("method");
|
||||||
|
|
||||||
const onSubmitHandler = (formData: FormData) => {
|
const onSubmitHandler = async (formData: FormData) => {
|
||||||
const state = crypto.randomBytes(16).toString("hex");
|
const state = crypto.randomBytes(16).toString("hex");
|
||||||
switch (formData.method) {
|
switch (formData.method) {
|
||||||
case AzureAppConfigurationConnectionMethod.OAuth:
|
case AzureAppConfigurationConnectionMethod.OAuth:
|
||||||
@@ -135,7 +135,7 @@ export const AzureAppConfigurationConnectionForm = ({ appConnection, onSubmit }:
|
|||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case AzureAppConfigurationConnectionMethod.ClientSecret:
|
case AzureAppConfigurationConnectionMethod.ClientSecret:
|
||||||
onSubmit(formData);
|
await onSubmit(formData);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new Error(`Unhandled Azure Connection method: ${(formData as FormData).method}`);
|
throw new Error(`Unhandled Azure Connection method: ${(formData as FormData).method}`);
|
||||||
@@ -249,7 +249,11 @@ export const AzureAppConfigurationConnectionForm = ({ appConnection, onSubmit }:
|
|||||||
label="Client Secret"
|
label="Client Secret"
|
||||||
errorText={error?.message}
|
errorText={error?.message}
|
||||||
>
|
>
|
||||||
<Input {...field} type="password" placeholder="Enter your Client Secret" />
|
<Input
|
||||||
|
{...field}
|
||||||
|
type="password"
|
||||||
|
placeholder="~JzD8e6S.tH~w8XRaNnKcb7W1fM4rCns7FY"
|
||||||
|
/>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
|
|||||||
+7
-3
@@ -121,7 +121,7 @@ export const AzureClientSecretsConnectionForm = ({ appConnection, onSubmit }: Pr
|
|||||||
|
|
||||||
const selectedMethod = watch("method");
|
const selectedMethod = watch("method");
|
||||||
|
|
||||||
const onSubmitHandler = (formData: FormData) => {
|
const onSubmitHandler = async (formData: FormData) => {
|
||||||
const state = crypto.randomBytes(16).toString("hex");
|
const state = crypto.randomBytes(16).toString("hex");
|
||||||
switch (formData.method) {
|
switch (formData.method) {
|
||||||
case AzureClientSecretsConnectionMethod.OAuth:
|
case AzureClientSecretsConnectionMethod.OAuth:
|
||||||
@@ -137,7 +137,7 @@ export const AzureClientSecretsConnectionForm = ({ appConnection, onSubmit }: Pr
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case AzureClientSecretsConnectionMethod.ClientSecret:
|
case AzureClientSecretsConnectionMethod.ClientSecret:
|
||||||
onSubmit(formData);
|
await onSubmit(formData);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new Error(`Unhandled Azure Connection method: ${(formData as FormData).method}`);
|
throw new Error(`Unhandled Azure Connection method: ${(formData as FormData).method}`);
|
||||||
@@ -240,7 +240,11 @@ export const AzureClientSecretsConnectionForm = ({ appConnection, onSubmit }: Pr
|
|||||||
label="Client Secret"
|
label="Client Secret"
|
||||||
errorText={error?.message}
|
errorText={error?.message}
|
||||||
>
|
>
|
||||||
<Input {...field} type="password" placeholder="Enter your Client Secret" />
|
<Input
|
||||||
|
{...field}
|
||||||
|
type="password"
|
||||||
|
placeholder="~JzD8e6S.tH~w8XRaNnKcb7W1fM4rCns7FY"
|
||||||
|
/>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
|
|||||||
+7
-3
@@ -172,10 +172,10 @@ export const AzureDevOpsConnectionForm = ({ appConnection, onSubmit }: Props) =>
|
|||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case AzureDevOpsConnectionMethod.AccessToken:
|
case AzureDevOpsConnectionMethod.AccessToken:
|
||||||
onSubmit(formData);
|
await onSubmit(formData);
|
||||||
break;
|
break;
|
||||||
case AzureDevOpsConnectionMethod.ClientSecret:
|
case AzureDevOpsConnectionMethod.ClientSecret:
|
||||||
onSubmit(formData);
|
await onSubmit(formData);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new Error(`Unhandled Azure Connection method: ${(formData as FormData).method}`);
|
throw new Error(`Unhandled Azure Connection method: ${(formData as FormData).method}`);
|
||||||
@@ -303,7 +303,11 @@ export const AzureDevOpsConnectionForm = ({ appConnection, onSubmit }: Props) =>
|
|||||||
label="Client Secret"
|
label="Client Secret"
|
||||||
errorText={error?.message}
|
errorText={error?.message}
|
||||||
>
|
>
|
||||||
<Input {...field} type="password" placeholder="Enter your Client Secret" />
|
<Input
|
||||||
|
{...field}
|
||||||
|
type="password"
|
||||||
|
placeholder="~JzD8e6S.tH~w8XRaNnKcb7W1fM4rCns7FY"
|
||||||
|
/>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
|
|||||||
+7
-3
@@ -120,7 +120,7 @@ export const AzureKeyVaultConnectionForm = ({ appConnection, onSubmit }: Props)
|
|||||||
|
|
||||||
const selectedMethod = watch("method");
|
const selectedMethod = watch("method");
|
||||||
|
|
||||||
const onSubmitHandler = (formData: FormData) => {
|
const onSubmitHandler = async (formData: FormData) => {
|
||||||
const state = crypto.randomBytes(16).toString("hex");
|
const state = crypto.randomBytes(16).toString("hex");
|
||||||
|
|
||||||
switch (formData.method) {
|
switch (formData.method) {
|
||||||
@@ -136,7 +136,7 @@ export const AzureKeyVaultConnectionForm = ({ appConnection, onSubmit }: Props)
|
|||||||
);
|
);
|
||||||
break;
|
break;
|
||||||
case AzureKeyVaultConnectionMethod.ClientSecret:
|
case AzureKeyVaultConnectionMethod.ClientSecret:
|
||||||
onSubmit(formData);
|
await onSubmit(formData);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new Error(`Unhandled Azure Connection method: ${(formData as FormData).method}`);
|
throw new Error(`Unhandled Azure Connection method: ${(formData as FormData).method}`);
|
||||||
@@ -251,7 +251,11 @@ export const AzureKeyVaultConnectionForm = ({ appConnection, onSubmit }: Props)
|
|||||||
label="Client Secret"
|
label="Client Secret"
|
||||||
errorText={error?.message}
|
errorText={error?.message}
|
||||||
>
|
>
|
||||||
<Input {...field} type="password" placeholder="Enter your Client Secret" />
|
<Input
|
||||||
|
{...field}
|
||||||
|
type="password"
|
||||||
|
placeholder="~JzD8e6S.tH~w8XRaNnKcb7W1fM4rCns7FY"
|
||||||
|
/>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user