* added config to support code split * splitting config * moved the window declaration in EE file as its dependency will be updated in EE * CE: Splitting ApiConstants and SocialLogin constants * CE: split login page * CE: moved getSocialLoginButtonProps func to EE file as it's dependencies will be updated in EE * added key icon * CE: created a factory class to share social auths list * Minor style fix for social btns * Updated the third party auth styles * updated jest config * updated third party login registry class
19 lines
515 B
TypeScript
19 lines
515 B
TypeScript
export * from "ce/constants/SocialLogin";
|
|
import {
|
|
SocialLoginButtonProps,
|
|
SocialLoginButtonPropsList,
|
|
SocialLoginType,
|
|
} from "ce/constants/SocialLogin";
|
|
|
|
export const getSocialLoginButtonProps = (
|
|
logins: SocialLoginType[],
|
|
): SocialLoginButtonProps[] => {
|
|
return logins.map((login) => {
|
|
const socialLoginButtonProps = SocialLoginButtonPropsList[login];
|
|
if (!socialLoginButtonProps) {
|
|
throw Error("Social login not registered: " + login);
|
|
}
|
|
return socialLoginButtonProps;
|
|
});
|
|
};
|