mirror of
https://github.com/logto-io/logto.git
synced 2025-03-03 22:15:32 -05:00
refactor: sign-in content (#1398)
* refactor: sign-in content * fix: update phrase key
This commit is contained in:
parent
4e19a8fbb9
commit
5c685d9412
6 changed files with 13 additions and 13 deletions
|
@ -156,7 +156,7 @@ const Preview = ({ signInExperience, className }: Props) => {
|
||||||
setPlatform('mobile');
|
setPlatform('mobile');
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{t('sign_in_exp.preview.mobile')}
|
{t('sign_in_exp.preview.native')}
|
||||||
</TabNavItem>
|
</TabNavItem>
|
||||||
<TabNavItem
|
<TabNavItem
|
||||||
isActive={platform === 'desktopWeb'}
|
isActive={platform === 'desktopWeb'}
|
||||||
|
|
|
@ -29,7 +29,7 @@ const SignInMethodsForm = () => {
|
||||||
primaryMethod?: SignInMethodKey
|
primaryMethod?: SignInMethodKey
|
||||||
) => {
|
) => {
|
||||||
if (oldPrimaryMethod) {
|
if (oldPrimaryMethod) {
|
||||||
// The secondary sign in method should select the old primary method by default.
|
// The secondary sign-in method should select the old primary method by default.
|
||||||
setValue(`signInMethods.${oldPrimaryMethod}`, true);
|
setValue(`signInMethods.${oldPrimaryMethod}`, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -74,7 +74,7 @@ const SignInExperience = () => {
|
||||||
|
|
||||||
const formatted = signInExperienceParser.toRemoteModel(formData);
|
const formatted = signInExperienceParser.toRemoteModel(formData);
|
||||||
|
|
||||||
// Sign in methods changed, need to show confirm modal first.
|
// Sign-in methods changed, need to show confirm modal first.
|
||||||
if (!compareSignInMethods(data, formatted)) {
|
if (!compareSignInMethods(data, formatted)) {
|
||||||
setDataToCompare(formatted);
|
setDataToCompare(formatted);
|
||||||
|
|
||||||
|
|
|
@ -59,7 +59,7 @@ describe('validate terms of use', () => {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
describe('check whether the social sign in method state is enabled', () => {
|
describe('check whether the social sign-in method state is enabled', () => {
|
||||||
it('should be truthy when sign-in method state is primary', () => {
|
it('should be truthy when sign-in method state is primary', () => {
|
||||||
expect(isEnabled(SignInMethodState.Primary)).toBeTruthy();
|
expect(isEnabled(SignInMethodState.Primary)).toBeTruthy();
|
||||||
});
|
});
|
||||||
|
|
|
@ -313,7 +313,7 @@ const translation = {
|
||||||
description: 'Customize the sign in UI to match your brand and view in real time',
|
description: 'Customize the sign in UI to match your brand and view in real time',
|
||||||
tabs: {
|
tabs: {
|
||||||
branding: 'Branding',
|
branding: 'Branding',
|
||||||
methods: 'Sign in methods',
|
methods: 'Sign-in methods',
|
||||||
others: 'Others',
|
others: 'Others',
|
||||||
},
|
},
|
||||||
welcome: {
|
welcome: {
|
||||||
|
@ -357,12 +357,12 @@ const translation = {
|
||||||
terms_of_use_tip: 'Terms of use URL',
|
terms_of_use_tip: 'Terms of use URL',
|
||||||
},
|
},
|
||||||
sign_in_methods: {
|
sign_in_methods: {
|
||||||
title: 'SIGN IN METHODS',
|
title: 'SIGN-IN METHODS',
|
||||||
primary: 'Primary sign in method',
|
primary: 'Primary sign-in method',
|
||||||
enable_secondary: 'Enable secondary sign in',
|
enable_secondary: 'Enable secondary sign in',
|
||||||
enable_secondary_description:
|
enable_secondary_description:
|
||||||
"Once it's turned on, you app will support more sign in method(s) besides the primary one. ",
|
"Once it's turned on, you app will support more sign-in method(s) besides the primary one. ",
|
||||||
methods: 'Sign in method',
|
methods: 'Sign-in method',
|
||||||
methods_sms: 'Phone number sign in',
|
methods_sms: 'Phone number sign in',
|
||||||
methods_email: 'Email sign in',
|
methods_email: 'Email sign in',
|
||||||
methods_social: 'Social sign in',
|
methods_social: 'Social sign in',
|
||||||
|
@ -405,19 +405,19 @@ const translation = {
|
||||||
},
|
},
|
||||||
save_alert: {
|
save_alert: {
|
||||||
description:
|
description:
|
||||||
'You are changing sign in methods. This will impact some of your users. Are you sure you want to do that?',
|
'You are changing sign-in methods. This will impact some of your users. Are you sure you want to do that?',
|
||||||
before: 'Before',
|
before: 'Before',
|
||||||
after: 'After',
|
after: 'After',
|
||||||
},
|
},
|
||||||
preview: {
|
preview: {
|
||||||
title: 'Sign In Preview',
|
title: 'Sign-in Preview',
|
||||||
languages: {
|
languages: {
|
||||||
english: 'English',
|
english: 'English',
|
||||||
chinese: 'Chinese',
|
chinese: 'Chinese',
|
||||||
},
|
},
|
||||||
dark: 'Dark',
|
dark: 'Dark',
|
||||||
light: 'Light',
|
light: 'Light',
|
||||||
mobile: 'Mobile',
|
native: 'native',
|
||||||
desktop_web: 'Desktop Web',
|
desktop_web: 'Desktop Web',
|
||||||
mobile_web: 'Mobile Web',
|
mobile_web: 'Mobile Web',
|
||||||
},
|
},
|
||||||
|
|
|
@ -403,7 +403,7 @@ const translation = {
|
||||||
},
|
},
|
||||||
dark: '深色',
|
dark: '深色',
|
||||||
light: '浅色',
|
light: '浅色',
|
||||||
mobile: '移动',
|
native: '原生',
|
||||||
desktop_web: '桌面网页',
|
desktop_web: '桌面网页',
|
||||||
mobile_web: '移动网页',
|
mobile_web: '移动网页',
|
||||||
},
|
},
|
||||||
|
|
Loading…
Add table
Reference in a new issue