mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-05 00:26:24 +00:00
resolved merge conflict issues and updated use of translations
This commit is contained in:
Generated
+39160
File diff suppressed because it is too large
Load Diff
@@ -131,7 +131,10 @@
|
|||||||
"need-account": "Need an Infisical account?",
|
"need-account": "Need an Infisical account?",
|
||||||
"create-account": "Create an account",
|
"create-account": "Create an account",
|
||||||
"forgot-password": "Forgot your password?",
|
"forgot-password": "Forgot your password?",
|
||||||
"error-login": "Wrong credentials."
|
"error-login": "Wrong credentials.",
|
||||||
|
"continue-with-google": "Continue with Google",
|
||||||
|
"continue-with-email": "Continue with Email",
|
||||||
|
"other-option": "Log in with other option"
|
||||||
},
|
},
|
||||||
"mfa": {
|
"mfa": {
|
||||||
"title": "Sign Up",
|
"title": "Sign Up",
|
||||||
@@ -295,6 +298,10 @@
|
|||||||
"signup": "Sign Up",
|
"signup": "Sign Up",
|
||||||
"already-have-account": "Have an account? Log in",
|
"already-have-account": "Have an account? Log in",
|
||||||
"forgot-password": "Forgot your password?",
|
"forgot-password": "Forgot your password?",
|
||||||
|
"initial-title": "Create your Infisical account",
|
||||||
|
"continue-with-google": "Continue with Google",
|
||||||
|
"continue-with-email": "Continue with Email",
|
||||||
|
"create-policy": "By signing up, you agree to our Terms of Service and Privacy Policy.",
|
||||||
"verify": "Verify",
|
"verify": "Verify",
|
||||||
"step1-start": "Let's get started",
|
"step1-start": "Let's get started",
|
||||||
"step1-privacy": "By creating an account, you agree to our Terms and have read and acknowledged the Privacy Policy.",
|
"step1-privacy": "By creating an account, you agree to our Terms and have read and acknowledged the Privacy Policy.",
|
||||||
|
|||||||
@@ -3,8 +3,6 @@ import Link from 'next/link';
|
|||||||
import { faGoogle } from '@fortawesome/free-brands-svg-icons';
|
import { faGoogle } from '@fortawesome/free-brands-svg-icons';
|
||||||
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
||||||
|
|
||||||
import { getTranslatedStaticProps } from '@app/components/utilities/withTranslateProps';
|
|
||||||
|
|
||||||
import { Button } from '../v2';
|
import { Button } from '../v2';
|
||||||
|
|
||||||
export default function InitialLoginStep({
|
export default function InitialLoginStep({
|
||||||
@@ -19,37 +17,35 @@ export default function InitialLoginStep({
|
|||||||
<h1 className='text-xl font-medium text-transparent bg-clip-text bg-gradient-to-b from-white to-bunker-200 text-center mb-8' >Login to Infisical</h1>
|
<h1 className='text-xl font-medium text-transparent bg-clip-text bg-gradient-to-b from-white to-bunker-200 text-center mb-8' >Login to Infisical</h1>
|
||||||
<div className='lg:w-1/6 w-1/4 min-w-[20rem] rounded-md'>
|
<div className='lg:w-1/6 w-1/4 min-w-[20rem] rounded-md'>
|
||||||
<Button
|
<Button
|
||||||
colorSchema="primary"
|
colorSchema="primary"
|
||||||
variant="solid"
|
variant="solid"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
window.open('/api/v1/oauth/redirect/google')
|
window.open('/api/v1/oauth/redirect/google')
|
||||||
}}
|
}}
|
||||||
leftIcon={<FontAwesomeIcon icon={faGoogle} className="mr-1" />}
|
leftIcon={<FontAwesomeIcon icon={faGoogle} className="mr-1" />}
|
||||||
className="h-14 w-full mx-0"
|
className="h-14 w-full mx-0"
|
||||||
>
|
>
|
||||||
{t('login:continue-with-google')}
|
{t('login.continue-with-google')}
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
<div className='lg:w-1/6 w-1/4 min-w-[20rem] text-center rounded-md mt-4'>
|
<div className='lg:w-1/6 w-1/4 min-w-[20rem] text-center rounded-md mt-4'>
|
||||||
<Button
|
<Button
|
||||||
colorSchema="primary"
|
colorSchema="primary"
|
||||||
variant="outline_bg"
|
variant="outline_bg"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
setIsLoginWithEmail(true);
|
setIsLoginWithEmail(true);
|
||||||
}}
|
}}
|
||||||
isFullWidth
|
isFullWidth
|
||||||
className="h-14 w-full mx-0"
|
className="h-14 w-full mx-0"
|
||||||
>
|
>
|
||||||
{t('login:continue-with-email')}
|
{t('login.continue-with-email')}
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
<div className="mt-4 text-bunker-400 text-sm flex flex-row">
|
<div className="mt-4 text-bunker-400 text-sm flex flex-row">
|
||||||
<span className="mr-1">Don't have an acount yet?</span>
|
<span className="mr-1">Don't have an acount yet?</span>
|
||||||
<Link href="/signup">
|
<Link href="/signup">
|
||||||
<span className='hover:underline hover:underline-offset-4 hover:decoration-primary-700 hover:text-bunker-200 duration-200 cursor-pointer'>{t('login:create-account')}</span>
|
<span className='hover:underline hover:underline-offset-4 hover:decoration-primary-700 hover:text-bunker-200 duration-200 cursor-pointer'>{t('login.create-account')}</span>
|
||||||
</Link>
|
</Link>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
|
|
||||||
export const getStaticProps = getTranslatedStaticProps(['login']);
|
|
||||||
|
|||||||
@@ -119,13 +119,13 @@ export default function LoginStep({
|
|||||||
</div>
|
</div>
|
||||||
<div className="text-bunker-400 text-sm flex flex-row w-max mx-auto">
|
<div className="text-bunker-400 text-sm flex flex-row w-max mx-auto">
|
||||||
<Link href="/verify-email">
|
<Link href="/verify-email">
|
||||||
<span className='hover:underline hover:underline-offset-4 hover:decoration-primary-700 hover:text-bunker-200 duration-200 cursor-pointer'>{t('login:forgot-password')}</span>
|
<span className='hover:underline hover:underline-offset-4 hover:decoration-primary-700 hover:text-bunker-200 duration-200 cursor-pointer'>{t('login.forgot-password')}</span>
|
||||||
</Link>
|
</Link>
|
||||||
</div>
|
</div>
|
||||||
{false && (
|
{false && (
|
||||||
<div className="w-full p-2 flex flex-row items-center bg-white/10 text-gray-300 rounded-md max-w-md mx-auto mt-4">
|
<div className="w-full p-2 flex flex-row items-center bg-white/10 text-gray-300 rounded-md max-w-md mx-auto mt-4">
|
||||||
<FontAwesomeIcon icon={faWarning} className="ml-2 mr-6 text-6xl" />
|
<FontAwesomeIcon icon={faWarning} className="ml-2 mr-6 text-6xl" />
|
||||||
{t('common:maintenance-alert')}
|
{t('common.maintenance-alert')}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</form>
|
</form>
|
||||||
|
|||||||
@@ -1,13 +1,12 @@
|
|||||||
import React, { useState } from 'react';
|
import React, { useState } from 'react';
|
||||||
|
import { useTranslation } from 'react-i18next';
|
||||||
import Link from 'next/link';
|
import Link from 'next/link';
|
||||||
import { useRouter } from 'next/router';
|
import { useRouter } from 'next/router';
|
||||||
import { useTranslation } from 'next-i18next';
|
|
||||||
|
|
||||||
import Button from '@app/components/basic/buttons/Button';
|
import Button from '@app/components/basic/buttons/Button';
|
||||||
import Error from '@app/components/basic/Error';
|
import Error from '@app/components/basic/Error';
|
||||||
import InputField from '@app/components/basic/InputField';
|
import InputField from '@app/components/basic/InputField';
|
||||||
import attemptLogin from '@app/components/utilities/attemptLogin';
|
import attemptLogin from '@app/components/utilities/attemptLogin';
|
||||||
import { getTranslatedStaticProps } from '@app/components/utilities/withTranslateProps';
|
|
||||||
|
|
||||||
import SecurityClient from '../utilities/SecurityClient';
|
import SecurityClient from '../utilities/SecurityClient';
|
||||||
|
|
||||||
@@ -62,11 +61,11 @@ export default function PasswordInputStep({
|
|||||||
<form onSubmit={(e) => e.preventDefault()}>
|
<form onSubmit={(e) => e.preventDefault()}>
|
||||||
<div className="h-7/12 mx-auto w-full max-w-md rounded-xl bg-bunker py-4 px-6 pt-8 drop-shadow-xl">
|
<div className="h-7/12 mx-auto w-full max-w-md rounded-xl bg-bunker py-4 px-6 pt-8 drop-shadow-xl">
|
||||||
<p className="mx-auto mb-6 flex w-max justify-center text-3xl font-semibold text-bunker-100">
|
<p className="mx-auto mb-6 flex w-max justify-center text-3xl font-semibold text-bunker-100">
|
||||||
{t('login:login')}
|
{t('login.login')}
|
||||||
</p>
|
</p>
|
||||||
<div className="relative mt-6 flex max-h-24 w-full items-center justify-center rounded-lg md:mt-2 md:max-h-28 md:p-2">
|
<div className="relative mt-6 flex max-h-24 w-full items-center justify-center rounded-lg md:mt-2 md:max-h-28 md:p-2">
|
||||||
<InputField
|
<InputField
|
||||||
label={t('common:password')}
|
label={t('common.password')}
|
||||||
onChangeHandler={setPassword}
|
onChangeHandler={setPassword}
|
||||||
type="password"
|
type="password"
|
||||||
value={password}
|
value={password}
|
||||||
@@ -81,17 +80,17 @@ export default function PasswordInputStep({
|
|||||||
type="button"
|
type="button"
|
||||||
className="ml-1.5 text-sm font-normal text-primary-700 underline-offset-4 duration-200 hover:text-primary"
|
className="ml-1.5 text-sm font-normal text-primary-700 underline-offset-4 duration-200 hover:text-primary"
|
||||||
>
|
>
|
||||||
{t('login:forgot-password')}
|
{t('login.forgot-password')}
|
||||||
</button>
|
</button>
|
||||||
</Link>
|
</Link>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{!isLoading && loginError && <Error text={t('login:error-login') ?? ''} />}
|
{!isLoading && loginError && <Error text={t('login.error-login') ?? ''} />}
|
||||||
<div className="mx-auto mt-4 flex max-h-20 w-full max-w-md flex-col items-center justify-center text-sm md:p-2">
|
<div className="mx-auto mt-4 flex max-h-20 w-full max-w-md flex-col items-center justify-center text-sm md:p-2">
|
||||||
<div className="text-l m-8 mt-6 px-8 py-3 text-lg">
|
<div className="text-l m-8 mt-6 px-8 py-3 text-lg">
|
||||||
<Button
|
<Button
|
||||||
type="submit"
|
type="submit"
|
||||||
text={t('login:login') ?? ''}
|
text={t('login.login') ?? ''}
|
||||||
onButtonPressed={async () => handleLogin()}
|
onButtonPressed={async () => handleLogin()}
|
||||||
loading={isLoading}
|
loading={isLoading}
|
||||||
size="lg"
|
size="lg"
|
||||||
@@ -100,13 +99,13 @@ export default function PasswordInputStep({
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="mt-4 flex flex-row items-center justify-center md:pb-4">
|
<div className="mt-4 flex flex-row items-center justify-center md:pb-4">
|
||||||
<p className="flex w-max justify-center text-sm text-gray-400">{t('login:need-account')}</p>
|
<p className="flex w-max justify-center text-sm text-gray-400">{t('login.need-account')}</p>
|
||||||
<Link href="/signup">
|
<Link href="/signup">
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
className="ml-1.5 text-sm font-normal text-primary-700 underline-offset-4 duration-200 hover:text-primary"
|
className="ml-1.5 text-sm font-normal text-primary-700 underline-offset-4 duration-200 hover:text-primary"
|
||||||
>
|
>
|
||||||
{t('login:create-account')}
|
{t('login.create-account')}
|
||||||
</button>
|
</button>
|
||||||
</Link>
|
</Link>
|
||||||
</div>
|
</div>
|
||||||
@@ -121,11 +120,9 @@ export default function PasswordInputStep({
|
|||||||
type="button"
|
type="button"
|
||||||
className="ml-1.5 text-sm font-normal text-primary-700 underline-offset-4 duration-200 hover:text-primary"
|
className="ml-1.5 text-sm font-normal text-primary-700 underline-offset-4 duration-200 hover:text-primary"
|
||||||
>
|
>
|
||||||
{t('login:other-option')}
|
{t('login.other-option')}
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
export const getStaticProps = getTranslatedStaticProps(['auth', 'login']);
|
|
||||||
|
|||||||
@@ -3,8 +3,6 @@ import Link from 'next/link';
|
|||||||
import { faGoogle } from '@fortawesome/free-brands-svg-icons';
|
import { faGoogle } from '@fortawesome/free-brands-svg-icons';
|
||||||
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
||||||
|
|
||||||
import { getTranslatedStaticProps } from '@app/components/utilities/withTranslateProps';
|
|
||||||
|
|
||||||
import { Button } from '../v2';
|
import { Button } from '../v2';
|
||||||
|
|
||||||
export default function InitialSignupStep({
|
export default function InitialSignupStep({
|
||||||
@@ -15,42 +13,40 @@ export default function InitialSignupStep({
|
|||||||
const { t } = useTranslation();
|
const { t } = useTranslation();
|
||||||
|
|
||||||
return <div className='flex flex-col mx-auto w-full justify-center items-center '>
|
return <div className='flex flex-col mx-auto w-full justify-center items-center '>
|
||||||
<h1 className='text-xl font-medium text-transparent bg-clip-text bg-gradient-to-b from-white to-bunker-200 text-center mb-8' >{t('signup:initial-title')}</h1>
|
<h1 className='text-xl font-medium text-transparent bg-clip-text bg-gradient-to-b from-white to-bunker-200 text-center mb-8' >{t('signup.initial-title')}</h1>
|
||||||
<div className='lg:w-1/6 w-1/4 min-w-[20rem] rounded-md'>
|
<div className='lg:w-1/6 w-1/4 min-w-[20rem] rounded-md'>
|
||||||
<Button
|
<Button
|
||||||
colorSchema="primary"
|
colorSchema="primary"
|
||||||
variant="solid"
|
variant="solid"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
window.open('/api/v1/oauth/redirect/google')
|
window.open('/api/v1/oauth/redirect/google')
|
||||||
}}
|
}}
|
||||||
leftIcon={<FontAwesomeIcon icon={faGoogle} className="mr-1" />}
|
leftIcon={<FontAwesomeIcon icon={faGoogle} className="mr-1" />}
|
||||||
className="h-14 w-full mx-0"
|
className="h-14 w-full mx-0"
|
||||||
>
|
>
|
||||||
{t('signup:continue-with-google')}
|
{t('signup.continue-with-google')}
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
<div className='lg:w-1/6 w-1/4 min-w-[20rem] text-center rounded-md mt-4'>
|
<div className='lg:w-1/6 w-1/4 min-w-[20rem] text-center rounded-md mt-4'>
|
||||||
<Button
|
<Button
|
||||||
colorSchema="primary"
|
colorSchema="primary"
|
||||||
variant="outline_bg"
|
variant="outline_bg"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
setIsSignupWithEmail(true);
|
setIsSignupWithEmail(true);
|
||||||
}}
|
}}
|
||||||
isFullWidth
|
isFullWidth
|
||||||
className="h-14 w-full mx-0"
|
className="h-14 w-full mx-0"
|
||||||
>
|
>
|
||||||
{t('signup:continue-with-email')}
|
{t('signup.continue-with-email')}
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
<div className='lg:w-1/6 w-1/4 min-w-[20rem] px-8 text-center mt-6 text-xs text-bunker-400'>
|
<div className='lg:w-1/6 w-1/4 min-w-[20rem] px-8 text-center mt-6 text-xs text-bunker-400'>
|
||||||
{t('signup:create-policy')}
|
{t('signup.create-policy')}
|
||||||
</div>
|
</div>
|
||||||
<div className="mt-2 text-bunker-400 text-xs flex flex-row">
|
<div className="mt-2 text-bunker-400 text-xs flex flex-row">
|
||||||
<Link href="/login">
|
<Link href="/login">
|
||||||
<span className='hover:underline hover:underline-offset-4 hover:decoration-primary-700 hover:text-bunker-200 duration-200 cursor-pointer'>{t('signup:already-have-account')}</span>
|
<span className='hover:underline hover:underline-offset-4 hover:decoration-primary-700 hover:text-bunker-200 duration-200 cursor-pointer'>{t('signup.already-have-account')}</span>
|
||||||
</Link>
|
</Link>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
|
|
||||||
export const getStaticProps = getTranslatedStaticProps(['signup']);
|
|
||||||
|
|||||||
@@ -109,8 +109,8 @@ export default function Login() {
|
|||||||
<div className="flex justify-center mb-4 mt-20">
|
<div className="flex justify-center mb-4 mt-20">
|
||||||
<Image src="/images/gradientLogo.svg" height={90} width={120} alt="Infisical logo" />
|
<Image src="/images/gradientLogo.svg" height={90} width={120} alt="Infisical logo" />
|
||||||
</div>
|
</div>
|
||||||
{renderView(step)}
|
|
||||||
</Link>
|
</Link>
|
||||||
|
{renderView(step)}
|
||||||
<div className="absolute right-4 top-0 mt-4 flex items-center justify-center">
|
<div className="absolute right-4 top-0 mt-4 flex items-center justify-center">
|
||||||
<div className="mx-auto w-48">
|
<div className="mx-auto w-48">
|
||||||
<ListBox
|
<ListBox
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ export default function SignUp() {
|
|||||||
const [attributionSource, setAttributionSource] = useState('');
|
const [attributionSource, setAttributionSource] = useState('');
|
||||||
const [code, setCode] = useState('123456');
|
const [code, setCode] = useState('123456');
|
||||||
const [codeError, setCodeError] = useState(false);
|
const [codeError, setCodeError] = useState(false);
|
||||||
const [step, setStep] = useState(5);
|
const [step, setStep] = useState(1);
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
const { data: serverDetails } = useFetchServerStatus();
|
const { data: serverDetails } = useFetchServerStatus();
|
||||||
const [isSignupWithEmail, setIsSignupWithEmail] = useState(false);
|
const [isSignupWithEmail, setIsSignupWithEmail] = useState(false);
|
||||||
@@ -146,9 +146,9 @@ export default function SignUp() {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
// if (serverDetails?.emailConfigured) {
|
if (serverDetails?.emailConfigured) {
|
||||||
return <TeamInviteStep />
|
return <TeamInviteStep />
|
||||||
// }
|
}
|
||||||
|
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
@@ -156,11 +156,11 @@ export default function SignUp() {
|
|||||||
return (
|
return (
|
||||||
<div className="bg-gradient-to-tr from-bunker-600 to-bunker-800 min-h-screen flex flex-col justify-center pb-28 px-6 ">
|
<div className="bg-gradient-to-tr from-bunker-600 to-bunker-800 min-h-screen flex flex-col justify-center pb-28 px-6 ">
|
||||||
<Head>
|
<Head>
|
||||||
<title>{t('common:head-title', { title: t('signup:title') })}</title>
|
<title>{t('common.head-title', { title: t('signup.title') })}</title>
|
||||||
<link rel="icon" href="/infisical.ico" />
|
<link rel="icon" href="/infisical.ico" />
|
||||||
<meta property="og:image" content="/images/message.png" />
|
<meta property="og:image" content="/images/message.png" />
|
||||||
<meta property="og:title" content={t('signup:og-title') as string} />
|
<meta property="og:title" content={t('signup.og-title') as string} />
|
||||||
<meta name="og:description" content={t('signup:og-description') as string} />
|
<meta name="og:description" content={t('signup.og-description') as string} />
|
||||||
</Head>
|
</Head>
|
||||||
<div className="flex justify-center mb-8 mt-20">
|
<div className="flex justify-center mb-8 mt-20">
|
||||||
<Image src="/images/gradientLogo.svg" height={90} width={120} alt="Infisical Logo" />
|
<Image src="/images/gradientLogo.svg" height={90} width={120} alt="Infisical Logo" />
|
||||||
|
|||||||
Reference in New Issue
Block a user