mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-09 02:28:18 +00:00
Run linter, fix import error
This commit is contained in:
@@ -5,13 +5,13 @@ export * from "./integrationAuth";
|
|||||||
export * from "./integrations";
|
export * from "./integrations";
|
||||||
export * from "./keys";
|
export * from "./keys";
|
||||||
export * from "./organization";
|
export * from "./organization";
|
||||||
export * from "./ssoConfig";
|
|
||||||
export * from "./secretFolders";
|
export * from "./secretFolders";
|
||||||
export * from "./secretImports";
|
export * from "./secretImports";
|
||||||
export * from "./secrets";
|
export * from "./secrets";
|
||||||
export * from "./secretSnapshots";
|
export * from "./secretSnapshots";
|
||||||
export * from "./serviceAccounts";
|
export * from "./serviceAccounts";
|
||||||
export * from "./serviceTokens";
|
export * from "./serviceTokens";
|
||||||
|
export * from "./ssoConfig";
|
||||||
export * from "./subscriptions";
|
export * from "./subscriptions";
|
||||||
export * from "./tags";
|
export * from "./tags";
|
||||||
export * from "./users";
|
export * from "./users";
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
|
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
|
||||||
|
|
||||||
import { apiRequest } from "@app/config/request";
|
import { apiRequest } from "@app/config/request";
|
||||||
|
|
||||||
import {
|
import {
|
||||||
BillingDetails,
|
BillingDetails,
|
||||||
Invoice,
|
Invoice,
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
export {
|
export {
|
||||||
useGetSSOConfig,
|
|
||||||
useCreateSSOConfig,
|
useCreateSSOConfig,
|
||||||
|
useGetSSOConfig,
|
||||||
useUpdateSSOConfig
|
useUpdateSSOConfig
|
||||||
} from "./queries";
|
} from "./queries";
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
|
import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
|
||||||
|
|
||||||
import { apiRequest } from "@app/config/request";
|
import { apiRequest } from "@app/config/request";
|
||||||
|
|
||||||
const ssoConfigKeys = {
|
const ssoConfigKeys = {
|
||||||
@@ -40,7 +41,7 @@ export const useCreateSSOConfig = () => {
|
|||||||
audience: string;
|
audience: string;
|
||||||
}) => {
|
}) => {
|
||||||
const { data } = await apiRequest.post(
|
const { data } = await apiRequest.post(
|
||||||
`/api/v1/sso/config`,
|
"/api/v1/sso/config",
|
||||||
{
|
{
|
||||||
organizationId,
|
organizationId,
|
||||||
authProvider,
|
authProvider,
|
||||||
@@ -81,7 +82,7 @@ export const useUpdateSSOConfig = () => {
|
|||||||
audience?: string;
|
audience?: string;
|
||||||
}) => {
|
}) => {
|
||||||
const { data } = await apiRequest.patch(
|
const { data } = await apiRequest.patch(
|
||||||
`/api/v1/sso/config`,
|
"/api/v1/sso/config",
|
||||||
{
|
{
|
||||||
organizationId,
|
organizationId,
|
||||||
...(authProvider !== undefined ? { authProvider } : {}),
|
...(authProvider !== undefined ? { authProvider } : {}),
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ import { useTranslation } from "react-i18next";
|
|||||||
import Head from "next/head";
|
import Head from "next/head";
|
||||||
import Image from "next/image";
|
import Image from "next/image";
|
||||||
import Link from "next/link";
|
import Link from "next/link";
|
||||||
|
|
||||||
import { Login } from "@app/views/Login";
|
import { Login } from "@app/views/Login";
|
||||||
|
|
||||||
export default function LoginPage() {
|
export default function LoginPage() {
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ import Head from "next/head";
|
|||||||
import Image from "next/image";
|
import Image from "next/image";
|
||||||
import Link from "next/link";
|
import Link from "next/link";
|
||||||
import { useRouter } from "next/router"
|
import { useRouter } from "next/router"
|
||||||
|
|
||||||
import { LoginSSO } from "@app/views/Login";
|
import { LoginSSO } from "@app/views/Login";
|
||||||
|
|
||||||
export default function LoginSSOPage() {
|
export default function LoginSSOPage() {
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ import { useTranslation } from "react-i18next";
|
|||||||
import Head from "next/head";
|
import Head from "next/head";
|
||||||
import Image from "next/image";
|
import Image from "next/image";
|
||||||
import { useRouter } from "next/router";
|
import { useRouter } from "next/router";
|
||||||
|
|
||||||
import CodeInputStep from "@app/components/signup/CodeInputStep";
|
import CodeInputStep from "@app/components/signup/CodeInputStep";
|
||||||
import DownloadBackupPDF from "@app/components/signup/DonwloadBackupPDFStep";
|
import DownloadBackupPDF from "@app/components/signup/DonwloadBackupPDFStep";
|
||||||
import EnterEmailStep from "@app/components/signup/EnterEmailStep";
|
import EnterEmailStep from "@app/components/signup/EnterEmailStep";
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ import { useTranslation } from "react-i18next";
|
|||||||
import Head from "next/head";
|
import Head from "next/head";
|
||||||
import Image from "next/image";
|
import Image from "next/image";
|
||||||
import { useRouter } from "next/router"
|
import { useRouter } from "next/router"
|
||||||
|
|
||||||
import { SignupSSO } from "@app/views/Signup";
|
import { SignupSSO } from "@app/views/Signup";
|
||||||
|
|
||||||
export default function SignupSSOPage() {
|
export default function SignupSSOPage() {
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
import { useEffect, useState } from "react";
|
import { useEffect, useState } from "react";
|
||||||
import { useRouter } from "next/router";
|
import { useRouter } from "next/router";
|
||||||
import axios from "axios"
|
import axios from "axios"
|
||||||
|
|
||||||
import { fetchUserDetails } from "@app/hooks/api/users/queries";
|
import { fetchUserDetails } from "@app/hooks/api/users/queries";
|
||||||
import getOrganizations from "@app/pages/api/organization/GetOrgs";
|
import getOrganizations from "@app/pages/api/organization/getOrgs";
|
||||||
import { getAuthToken, isLoggedIn } from "@app/reactQuery";
|
import { getAuthToken, isLoggedIn } from "@app/reactQuery";
|
||||||
|
|
||||||
import {
|
import {
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
import { useEffect, useState } from "react";
|
import { useEffect, useState } from "react";
|
||||||
import { useRouter } from "next/router"
|
import { useRouter } from "next/router"
|
||||||
import jwt_decode from "jwt-decode";
|
import jwt_decode from "jwt-decode";
|
||||||
|
|
||||||
import {
|
import {
|
||||||
MFAStep,
|
MFAStep,
|
||||||
PasswordStep
|
PasswordStep
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import { faPlus } from "@fortawesome/free-solid-svg-icons";
|
import { faPlus } from "@fortawesome/free-solid-svg-icons";
|
||||||
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
||||||
|
|
||||||
import { useNotificationContext } from "@app/components/context/Notifications/NotificationProvider";
|
import { useNotificationContext } from "@app/components/context/Notifications/NotificationProvider";
|
||||||
import { Button , Switch } from "@app/components/v2";
|
import { Button , Switch } from "@app/components/v2";
|
||||||
import { useOrganization } from "@app/context";
|
import { useOrganization } from "@app/context";
|
||||||
@@ -8,6 +9,7 @@ import {
|
|||||||
useUpdateSSOConfig
|
useUpdateSSOConfig
|
||||||
} from "@app/hooks/api";
|
} from "@app/hooks/api";
|
||||||
import { usePopUp } from "@app/hooks/usePopUp";
|
import { usePopUp } from "@app/hooks/usePopUp";
|
||||||
|
|
||||||
import { SSOModal } from "./SSOModal";
|
import { SSOModal } from "./SSOModal";
|
||||||
|
|
||||||
const ssoAuthProviderMap: { [key: string]: string } = {
|
const ssoAuthProviderMap: { [key: string]: string } = {
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ import { useEffect } from "react";
|
|||||||
import { Controller, useForm } from "react-hook-form";
|
import { Controller, useForm } from "react-hook-form";
|
||||||
import { yupResolver } from "@hookform/resolvers/yup";
|
import { yupResolver } from "@hookform/resolvers/yup";
|
||||||
import * as yup from "yup";
|
import * as yup from "yup";
|
||||||
|
|
||||||
import { useNotificationContext } from "@app/components/context/Notifications/NotificationProvider";
|
import { useNotificationContext } from "@app/components/context/Notifications/NotificationProvider";
|
||||||
import {
|
import {
|
||||||
Button,
|
Button,
|
||||||
@@ -14,8 +15,8 @@ import {
|
|||||||
TextArea} from "@app/components/v2";
|
TextArea} from "@app/components/v2";
|
||||||
import { useOrganization } from "@app/context";
|
import { useOrganization } from "@app/context";
|
||||||
import {
|
import {
|
||||||
useGetSSOConfig,
|
|
||||||
useCreateSSOConfig,
|
useCreateSSOConfig,
|
||||||
|
useGetSSOConfig,
|
||||||
useUpdateSSOConfig
|
useUpdateSSOConfig
|
||||||
} from "@app/hooks/api";
|
} from "@app/hooks/api";
|
||||||
import { UsePopUpState } from "@app/hooks/usePopUp";
|
import { UsePopUpState } from "@app/hooks/usePopUp";
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
import { useState } from "react";
|
import { useState } from "react";
|
||||||
import {
|
|
||||||
UserInfoSSOStep,
|
|
||||||
BackupPDFStep
|
|
||||||
} from "./components";
|
|
||||||
import jwt_decode from "jwt-decode";
|
import jwt_decode from "jwt-decode";
|
||||||
|
|
||||||
|
import {
|
||||||
|
BackupPDFStep,
|
||||||
|
UserInfoSSOStep} from "./components";
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
providerAuthToken: string;
|
providerAuthToken: string;
|
||||||
}
|
}
|
||||||
@@ -45,7 +45,7 @@ export const SignupSSO = ({
|
|||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
default:
|
default:
|
||||||
return <div></div>
|
return <div />
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,8 @@
|
|||||||
import { useRouter } from "next/router"
|
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
|
import { useRouter } from "next/router"
|
||||||
import { faWarning } from "@fortawesome/free-solid-svg-icons";
|
import { faWarning } from "@fortawesome/free-solid-svg-icons";
|
||||||
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
||||||
|
|
||||||
import issueBackupKey from "@app/components/utilities/cryptography/issueBackupKey";
|
import issueBackupKey from "@app/components/utilities/cryptography/issueBackupKey";
|
||||||
import { Button } from "@app/components/v2";
|
import { Button } from "@app/components/v2";
|
||||||
|
|
||||||
|
|||||||
@@ -1,16 +1,14 @@
|
|||||||
|
|
||||||
|
import crypto from "crypto";
|
||||||
|
|
||||||
import React, { useState } from "react";
|
import React, { useState } from "react";
|
||||||
import crypto from "crypto";
|
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
import { faXmark } from "@fortawesome/free-solid-svg-icons";
|
import { faXmark } from "@fortawesome/free-solid-svg-icons";
|
||||||
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
import { FontAwesomeIcon } from "@fortawesome/react-fontawesome";
|
||||||
import jsrp from "jsrp";
|
import jsrp from "jsrp";
|
||||||
import nacl from "tweetnacl";
|
import nacl from "tweetnacl";
|
||||||
import { encodeBase64 } from "tweetnacl-util";
|
import { encodeBase64 } from "tweetnacl-util";
|
||||||
import { useGetCommonPasswords } from "@app/hooks/api";
|
|
||||||
import completeAccountInformationSignup from "@app/pages/api/auth/CompleteAccountInformationSignup";
|
|
||||||
import getOrganizations from "@app/pages/api/organization/getOrgs";
|
|
||||||
import ProjectService from "@app/services/ProjectService";
|
|
||||||
import InputField from "@app/components/basic/InputField";
|
import InputField from "@app/components/basic/InputField";
|
||||||
import checkPassword from "@app/components/utilities/checks/checkPassword";
|
import checkPassword from "@app/components/utilities/checks/checkPassword";
|
||||||
import Aes256Gcm from "@app/components/utilities/cryptography/aes-256-gcm";
|
import Aes256Gcm from "@app/components/utilities/cryptography/aes-256-gcm";
|
||||||
@@ -18,7 +16,10 @@ import { deriveArgonKey } from "@app/components/utilities/cryptography/crypto";
|
|||||||
import { saveTokenToLocalStorage } from "@app/components/utilities/saveTokenToLocalStorage";
|
import { saveTokenToLocalStorage } from "@app/components/utilities/saveTokenToLocalStorage";
|
||||||
import SecurityClient from "@app/components/utilities/SecurityClient";
|
import SecurityClient from "@app/components/utilities/SecurityClient";
|
||||||
import { Button, Input } from "@app/components/v2";
|
import { Button, Input } from "@app/components/v2";
|
||||||
import { setSignupTempToken } from "@app/reactQuery";
|
import { useGetCommonPasswords } from "@app/hooks/api";
|
||||||
|
import completeAccountInformationSignup from "@app/pages/api/auth/CompleteAccountInformationSignup";
|
||||||
|
import getOrganizations from "@app/pages/api/organization/getOrgs";
|
||||||
|
import ProjectService from "@app/services/ProjectService";
|
||||||
|
|
||||||
// eslint-disable-next-line new-cap
|
// eslint-disable-next-line new-cap
|
||||||
const client = new jsrp.client();
|
const client = new jsrp.client();
|
||||||
@@ -212,7 +213,7 @@ export const UserInfoSSOStep = ({
|
|||||||
<Input
|
<Input
|
||||||
placeholder="Jane Doe"
|
placeholder="Jane Doe"
|
||||||
value={name}
|
value={name}
|
||||||
disabled={true}
|
disabled
|
||||||
isRequired
|
isRequired
|
||||||
autoComplete="given-name"
|
autoComplete="given-name"
|
||||||
className="h-12"
|
className="h-12"
|
||||||
@@ -226,7 +227,7 @@ export const UserInfoSSOStep = ({
|
|||||||
value={organizationName}
|
value={organizationName}
|
||||||
isRequired
|
isRequired
|
||||||
className="h-12"
|
className="h-12"
|
||||||
disabled={true}
|
disabled
|
||||||
/>
|
/>
|
||||||
{organizationNameError && <p className='text-left w-full text-xs text-red-600 mt-1 ml-1'>Please, specify your organization name</p>}
|
{organizationNameError && <p className='text-left w-full text-xs text-red-600 mt-1 ml-1'>Please, specify your organization name</p>}
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,2 +1,2 @@
|
|||||||
export { UserInfoSSOStep } from "./UserInfoSSOStep";
|
export { BackupPDFStep } from "./BackupPDFStep";
|
||||||
export { BackupPDFStep } from "./BackupPDFStep";
|
export { UserInfoSSOStep } from "./UserInfoSSOStep";
|
||||||
Reference in New Issue
Block a user