mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-16 22:07:09 +08:00
@@ -89,7 +89,10 @@ export const AddSelfhostedStep = ({
|
||||
|
||||
return (
|
||||
<AuthContainer>
|
||||
<AuthHeader title={t['com.affine.auth.sign.add-selfhosted']()} />
|
||||
<AuthHeader
|
||||
title={t['com.affine.auth.sign-in.add-selfhosted.title']()}
|
||||
subTitle={t['com.affine.auth.sign.add-selfhosted']()}
|
||||
/>
|
||||
<AuthContent>
|
||||
<AuthInput
|
||||
label={t['com.affine.auth.sign.add-selfhosted.baseurl']()}
|
||||
|
||||
@@ -2,6 +2,7 @@ import { Button, notify } from '@affine/component';
|
||||
import {
|
||||
AuthContainer,
|
||||
AuthContent,
|
||||
AuthFooter,
|
||||
AuthHeader,
|
||||
AuthInput,
|
||||
} from '@affine/component/auth-components';
|
||||
@@ -28,6 +29,7 @@ import {
|
||||
} from 'react';
|
||||
|
||||
import type { SignInState } from '.';
|
||||
import { Back } from './back';
|
||||
import * as style from './style.css';
|
||||
|
||||
const emailRegex =
|
||||
@@ -186,49 +188,53 @@ export const SignInStep = ({
|
||||
</Button>
|
||||
|
||||
{!isSelfhosted && (
|
||||
<div className={style.authMessage}>
|
||||
{/*prettier-ignore*/}
|
||||
<Trans i18nKey="com.affine.auth.sign.message">
|
||||
<>
|
||||
<div className={style.authMessage}>
|
||||
{/*prettier-ignore*/}
|
||||
<Trans i18nKey="com.affine.auth.sign.message">
|
||||
By clicking "Continue with Google/Email" above, you acknowledge that
|
||||
you agree to AFFiNE's <a href="https://affine.pro/terms" target="_blank" rel="noreferrer">Terms of Conditions</a> and <a href="https://affine.pro/privacy" target="_blank" rel="noreferrer">Privacy Policy</a>.
|
||||
</Trans>
|
||||
</div>
|
||||
)}
|
||||
|
||||
<div className={style.skipDivider}>
|
||||
<div className={style.skipDividerLine} />
|
||||
<span className={style.skipDividerText}>or</span>
|
||||
<div className={style.skipDividerLine} />
|
||||
</div>
|
||||
<div className={style.skipSection}>
|
||||
{!isSelfhosted &&
|
||||
BUILD_CONFIG.isElectron &&
|
||||
enableMultipleCloudServers ? (
|
||||
<Button
|
||||
variant="plain"
|
||||
className={style.addSelfhostedButton}
|
||||
prefix={
|
||||
<PublishIcon className={style.addSelfhostedButtonPrefix} />
|
||||
}
|
||||
onClick={onAddSelfhosted}
|
||||
>
|
||||
{t['com.affine.auth.sign.add-selfhosted']()}
|
||||
</Button>
|
||||
) : (
|
||||
<div className={style.skipText}>
|
||||
{t['com.affine.mobile.sign-in.skip.hint']()}
|
||||
</div>
|
||||
)}
|
||||
<Button
|
||||
variant="plain"
|
||||
onClick={onSkip}
|
||||
className={style.skipLink}
|
||||
prefix={<LocalWorkspaceIcon className={style.skipLinkIcon} />}
|
||||
>
|
||||
{t['com.affine.mobile.sign-in.skip.link']()}
|
||||
</Button>
|
||||
</div>
|
||||
<div className={style.skipDivider}>
|
||||
<div className={style.skipDividerLine} />
|
||||
<span className={style.skipDividerText}>or</span>
|
||||
<div className={style.skipDividerLine} />
|
||||
</div>
|
||||
<div className={style.skipSection}>
|
||||
{BUILD_CONFIG.isElectron && enableMultipleCloudServers ? (
|
||||
<Button
|
||||
variant="plain"
|
||||
className={style.addSelfhostedButton}
|
||||
prefix={
|
||||
<PublishIcon className={style.addSelfhostedButtonPrefix} />
|
||||
}
|
||||
onClick={onAddSelfhosted}
|
||||
>
|
||||
{t['com.affine.auth.sign.add-selfhosted']()}
|
||||
</Button>
|
||||
) : (
|
||||
<div className={style.skipText}>
|
||||
{t['com.affine.mobile.sign-in.skip.hint']()}
|
||||
</div>
|
||||
)}
|
||||
<Button
|
||||
variant="plain"
|
||||
onClick={onSkip}
|
||||
className={style.skipLink}
|
||||
prefix={<LocalWorkspaceIcon className={style.skipLinkIcon} />}
|
||||
>
|
||||
{t['com.affine.mobile.sign-in.skip.link']()}
|
||||
</Button>
|
||||
</div>
|
||||
</>
|
||||
)}
|
||||
</AuthContent>
|
||||
{isSelfhosted && (
|
||||
<AuthFooter>
|
||||
<Back changeState={changeState} />
|
||||
</AuthFooter>
|
||||
)}
|
||||
</AuthContainer>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user