mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-06 21:27:10 +00:00
Update SecretSyncConnectionField.tsx
This commit is contained in:
@@ -1,4 +1,3 @@
|
|||||||
import { useMemo } from "react";
|
|
||||||
import { Controller, useFormContext } from "react-hook-form";
|
import { Controller, useFormContext } from "react-hook-form";
|
||||||
import { faInfoCircle } from "@fortawesome/free-solid-svg-icons";
|
import { faInfoCircle } from "@fortawesome/free-solid-svg-icons";
|
||||||
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
||||||
@@ -9,10 +8,7 @@ import { OrgPermissionSubjects, useOrgPermission } from "@app/context";
|
|||||||
import { OrgPermissionAppConnectionActions } from "@app/context/OrgPermissionContext/types";
|
import { OrgPermissionAppConnectionActions } from "@app/context/OrgPermissionContext/types";
|
||||||
import { APP_CONNECTION_MAP } from "@app/helpers/appConnections";
|
import { APP_CONNECTION_MAP } from "@app/helpers/appConnections";
|
||||||
import { SECRET_SYNC_CONNECTION_MAP } from "@app/helpers/secretSyncs";
|
import { SECRET_SYNC_CONNECTION_MAP } from "@app/helpers/secretSyncs";
|
||||||
import {
|
import { useListAvailableAppConnections } from "@app/hooks/api/appConnections";
|
||||||
TAvailableAppConnection,
|
|
||||||
useListAvailableAppConnections
|
|
||||||
} from "@app/hooks/api/appConnections";
|
|
||||||
|
|
||||||
import { TSecretSyncForm } from "./schemas";
|
import { TSecretSyncForm } from "./schemas";
|
||||||
|
|
||||||
@@ -20,7 +16,7 @@ type Props = {
|
|||||||
onChange?: VoidFunction;
|
onChange?: VoidFunction;
|
||||||
};
|
};
|
||||||
|
|
||||||
export const SecretSyncConnectionField = ({ onChange: callback, filterConnections }: Props) => {
|
export const SecretSyncConnectionField = ({ onChange: callback }: Props) => {
|
||||||
const { permission } = useOrgPermission();
|
const { permission } = useOrgPermission();
|
||||||
const { control, watch } = useFormContext<TSecretSyncForm>();
|
const { control, watch } = useFormContext<TSecretSyncForm>();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user