@dropins/storefront-auth 0.0.1-alpha2 → 0.0.1-alpha21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/api/confirmEmail/confirmEmail.d.ts +4 -0
- package/api/confirmEmail/graphql/confirmEmail.graphql.d.ts +2 -0
- package/api/confirmEmail/index.d.ts +2 -0
- package/api/createCustomer/createCustomer.d.ts +4 -0
- package/api/createCustomer/graphql/createCustomer.graphql.d.ts +2 -0
- package/api/createCustomer/graphql/createCustomerV2.graphql.d.ts +2 -0
- package/api/createCustomer/index.d.ts +2 -0
- package/api/createCustomerAddress/createCustomerAddress.d.ts +4 -0
- package/api/createCustomerAddress/graphql/createCustomerAddress.graphql.d.ts +2 -0
- package/api/createCustomerAddress/index.d.ts +2 -0
- package/api/fetch-graphql/fetch-graphql.d.ts +8 -0
- package/api/fetch-graphql/index.d.ts +2 -0
- package/api/getAttributesForm/getAttributesForm.d.ts +4 -0
- package/api/getAttributesForm/graphql/getAttributesForm.graphql.d.ts +2 -0
- package/api/getAttributesForm/index.d.ts +2 -0
- package/api/getCustomerData/getCustomerData.d.ts +4 -0
- package/api/getCustomerData/graphql/getCustomerData.graphql.d.ts +2 -0
- package/api/getCustomerData/index.d.ts +2 -0
- package/api/getCustomerToken/getCustomerToken.d.ts +15 -0
- package/api/getCustomerToken/graphql/getCustomerToken.graphql.d.ts +2 -0
- package/api/getCustomerToken/index.d.ts +2 -0
- package/api/getStoreConfig/getStoreConfig.d.ts +4 -0
- package/api/getStoreConfig/graphql/getStoreConfig.graphql.d.ts +2 -0
- package/api/getStoreConfig/index.d.ts +2 -0
- package/api/index.d.ts +14 -0
- package/api/initialize/index.d.ts +2 -0
- package/api/initialize/initialize.d.ts +14 -0
- package/api/requestPasswordResetEmail/graphql/requestPasswordResetEmail.graphql.d.ts +2 -0
- package/api/requestPasswordResetEmail/index.d.ts +2 -0
- package/api/requestPasswordResetEmail/requestPasswordResetEmail.d.ts +4 -0
- package/api/resendConfirmationEmail/graphql/resendConfirmationEmail.graphql.d.ts +2 -0
- package/api/resendConfirmationEmail/index.d.ts +2 -0
- package/api/resendConfirmationEmail/resendConfirmationEmail.d.ts +4 -0
- package/api/resetPassword/graphql/resetPassword.graphql.d.ts +2 -0
- package/api/resetPassword/index.d.ts +2 -0
- package/api/resetPassword/resetPassword.d.ts +4 -0
- package/api/revokeCustomerToken/graphql/revokeCustomerToken.graphql.d.ts +2 -0
- package/api/revokeCustomerToken/index.d.ts +2 -0
- package/api/revokeCustomerToken/revokeCustomerToken.d.ts +4 -0
- package/api.d.ts +1 -0
- package/api.js +1 -1
- package/chunks/EmailConfirmationForm.js +1 -0
- package/chunks/ResetPasswordForm.js +1 -0
- package/chunks/SignInForm.js +1 -0
- package/chunks/SignUpForm.js +1 -0
- package/chunks/SkeletonLoader.js +1 -0
- package/chunks/confirmEmail.js +12 -0
- package/chunks/createCustomerAddress.js +61 -0
- package/chunks/getCustomerToken.js +15 -0
- package/chunks/getStoreConfig.js +15 -0
- package/chunks/index.js +1 -0
- package/chunks/index2.js +1 -0
- package/chunks/index3.js +1 -0
- package/chunks/initialize.js +1 -0
- package/chunks/network-error.js +1 -0
- package/chunks/requestPasswordResetEmail.js +5 -0
- package/chunks/resendConfirmationEmail.js +4 -0
- package/chunks/resetPassword.js +5 -0
- package/chunks/revokeCustomerToken.js +8 -0
- package/chunks/setReCaptchaToken.js +1 -0
- package/chunks/simplifyTransformAttributesForm.js +1 -0
- package/chunks/transform-attributes-form.js +1 -0
- package/chunks/useInLineAlert.js +1 -0
- package/chunks/usePasswordValidationMessage.js +1 -0
- package/components/EmailConfirmationForm/EmailConfirmationForm.d.ts +5 -0
- package/components/EmailConfirmationForm/index.d.ts +3 -0
- package/components/ResetPasswordForm/ResetPasswordForm.d.ts +6 -0
- package/components/ResetPasswordForm/index.d.ts +3 -0
- package/components/SignInForm/SignInForm.d.ts +5 -0
- package/components/SignInForm/index.d.ts +3 -0
- package/components/SignUpForm/SignUpForm.d.ts +5 -0
- package/components/SignUpForm/index.d.ts +3 -0
- package/components/SkeletonLoader/SkeletonLoader.d.ts +5 -0
- package/components/SkeletonLoader/Skeletons/ResetPasswordSkeleton.d.ts +2 -0
- package/components/SkeletonLoader/Skeletons/SignInSkeleton.d.ts +2 -0
- package/components/SkeletonLoader/Skeletons/SignUpSkeleton.d.ts +2 -0
- package/components/SkeletonLoader/Skeletons/index.d.ts +4 -0
- package/components/SkeletonLoader/index.d.ts +3 -0
- package/components/SuccessNotificationForm/SuccessNotificationForm.d.ts +6 -0
- package/components/SuccessNotificationForm/index.d.ts +3 -0
- package/components/UI/Button/Button.d.ts +16 -0
- package/components/UI/Button/index.d.ts +3 -0
- package/components/UI/Form/Form.d.ts +4 -0
- package/components/UI/Form/index.d.ts +3 -0
- package/components/UI/FormInputs/FormInputs.d.ts +5 -0
- package/components/UI/FormInputs/index.d.ts +3 -0
- package/components/UI/index.d.ts +4 -0
- package/components/UpdatePasswordForm/UpdatePasswordForm.d.ts +5 -0
- package/components/UpdatePasswordForm/index.d.ts +3 -0
- package/components/index.d.ts +10 -0
- package/configs/cookieConfigs.d.ts +7 -0
- package/configs/defaultCreateUserConfigs.d.ts +9 -0
- package/configs/patternConfigs.d.ts +3 -0
- package/containers/AuthCombine/AuthCombine.d.ts +5 -0
- package/containers/AuthCombine/index.d.ts +3 -0
- package/containers/AuthCombine.d.ts +3 -0
- package/containers/AuthCombine.js +1 -1
- package/containers/ResetPassword/ResetPassword.d.ts +5 -0
- package/containers/ResetPassword/index.d.ts +3 -0
- package/containers/ResetPassword.d.ts +3 -0
- package/containers/ResetPassword.js +1 -1
- package/containers/SignIn/SignIn.d.ts +5 -0
- package/containers/SignIn/index.d.ts +3 -0
- package/containers/SignIn.d.ts +3 -0
- package/containers/SignIn.js +1 -1
- package/containers/SignUp/SignUp.d.ts +5 -0
- package/containers/SignUp/index.d.ts +3 -0
- package/containers/SignUp.d.ts +3 -0
- package/containers/SignUp.js +1 -1
- package/containers/SuccessNotification/SuccessNotification.d.ts +5 -0
- package/containers/SuccessNotification/index.d.ts +3 -0
- package/containers/SuccessNotification.d.ts +3 -0
- package/containers/SuccessNotification.js +1 -1
- package/containers/UpdatePassword/UpdatePassword.d.ts +5 -0
- package/containers/UpdatePassword/index.d.ts +3 -0
- package/containers/UpdatePassword.d.ts +3 -0
- package/containers/UpdatePassword.js +1 -1
- package/containers/index.d.ts +7 -0
- package/data/models/attributes-form.d.ts +44 -0
- package/data/models/customer-data.d.ts +6 -0
- package/data/models/index.d.ts +7 -0
- package/data/models/password-reset-email.d.ts +5 -0
- package/data/models/reset-password.d.ts +5 -0
- package/data/models/revoke-customer-token.d.ts +5 -0
- package/data/models/store-config.d.ts +8 -0
- package/data/transforms/index.d.ts +7 -0
- package/data/transforms/transform-attributes-form.d.ts +6 -0
- package/data/transforms/transform-auth.d.ts +37 -0
- package/data/transforms/transform-customer-data.d.ts +5 -0
- package/data/transforms/transform-password-reset-email.d.ts +5 -0
- package/data/transforms/transform-reset-password.d.ts +5 -0
- package/data/transforms/transform-revoke-customer-token.d.ts +5 -0
- package/data/transforms/transform-store-config.d.ts +5 -0
- package/hooks/api/useGetAttributesForm.d.ts +14 -0
- package/hooks/api/useGetStoreConfigs.d.ts +8 -0
- package/hooks/components/useEmailConfirmationForm.d.ts +7 -0
- package/hooks/components/usePasswordValidationMessage.d.ts +16 -0
- package/hooks/components/useResetPasswordForm.d.ts +8 -0
- package/hooks/components/useSignInForm.d.ts +23 -0
- package/hooks/components/useSignUpForm.d.ts +20 -0
- package/hooks/components/useUpdatePasswordForm.d.ts +16 -0
- package/hooks/ui/useForm.d.ts +12 -0
- package/hooks/useEmailConfirmation.d.ts +11 -0
- package/hooks/useInLineAlert.d.ts +7 -0
- package/i18n/en_US.json.d.ts +76 -0
- package/lib/acdl.d.ts +9 -0
- package/lib/checkIsFunction.d.ts +2 -0
- package/lib/clearUrlAndReplace.d.ts +2 -0
- package/lib/convertToInputDateFormat.d.ts +2 -0
- package/lib/cookieUtils.d.ts +3 -0
- package/lib/fetch-error.d.ts +5 -0
- package/lib/generateRandomDigits.d.ts +2 -0
- package/lib/getFormValues.d.ts +2 -0
- package/lib/getUrlParam.d.ts +2 -0
- package/lib/mergeFormObjects.d.ts +3 -0
- package/lib/network-error.d.ts +6 -0
- package/lib/setReCaptchaToken.d.ts +2 -0
- package/lib/simplifyTransformAttributesForm.d.ts +2 -0
- package/lib/validationUniqueSymbolsPassword.d.ts +2 -0
- package/package.json +1 -1
- package/render/Provider.d.ts +8 -0
- package/render/index.d.ts +2 -0
- package/render/render.d.ts +4 -0
- package/render.d.ts +1 -0
- package/render.js +8 -1
- package/types/api/confirmEmail.types.d.ts +17 -0
- package/types/api/createCustomer.types.d.ts +24 -0
- package/types/api/createCustomerAddress.types.d.ts +47 -0
- package/types/api/getAttributesForm.types.d.ts +31 -0
- package/types/api/getCustomerData.types.d.ts +13 -0
- package/types/api/getCustomerToken.types.d.ts +11 -0
- package/types/api/passwordResetEmail.types.d.ts +9 -0
- package/types/api/resendConfirmationEmail.types.d.ts +9 -0
- package/types/api/resetPassword.types.d.ts +9 -0
- package/types/api/revokeCustomerToken.types.d.ts +9 -0
- package/types/api/storeConfig.types.d.ts +16 -0
- package/types/authCombine.types.d.ts +12 -0
- package/types/emailConfirmationForm.types.d.ts +14 -0
- package/types/form.types.d.ts +31 -0
- package/types/index.d.ts +22 -0
- package/types/notification.types.d.ts +19 -0
- package/types/resetPassword.types.d.ts +15 -0
- package/types/signIn.types.d.ts +44 -0
- package/types/signUp.types.d.ts +51 -0
- package/types/skeletonLoader.types.d.ts +6 -0
- package/types/successNotification.types.d.ts +16 -0
- package/types/updatePassword.types.d.ts +34 -0
- package/101.js +0 -1
- package/15.js +0 -1
- package/243.js +0 -1
- package/260.js +0 -1
- package/280.js +0 -1
- package/304.js +0 -1
- package/378.js +0 -1
- package/38.js +0 -1
- package/407.js +0 -1
- package/408.js +0 -1
- package/412.js +0 -1
- package/436.js +0 -1
- package/442.js +0 -1
- package/474.js +0 -1
- package/498.js +0 -1
- package/508.js +0 -1
- package/55.js +0 -1
- package/591.js +0 -1
- package/592.js +0 -1
- package/595.js +0 -1
- package/604.js +0 -1
- package/606.js +0 -1
- package/634.js +0 -1
- package/636.js +0 -1
- package/708.js +0 -1
- package/728.js +0 -1
- package/739.js +0 -1
- package/761.js +0 -1
- package/77.js +0 -1
- package/835.js +0 -1
- package/868.js +0 -1
- package/884.js +0 -1
- package/902.js +0 -1
- package/906.js +0 -1
- package/912.js +0 -1
- package/93.js +0 -1
- package/940.js +0 -1
- package/952.js +0 -1
- package/960.js +0 -1
- package/964.js +0 -1
- package/993.js +0 -1
- package/runtime.js +0 -1
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from './transform-auth';
|
|
2
|
+
export * from './transform-store-config';
|
|
3
|
+
export * from './transform-password-reset-email';
|
|
4
|
+
export * from './transform-revoke-customer-token';
|
|
5
|
+
export * from './transform-customer-data';
|
|
6
|
+
export * from './transform-attributes-form';
|
|
7
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { getAttributesFormResponse } from '../../types';
|
|
2
|
+
import { AttributesFormModel } from '../models';
|
|
3
|
+
|
|
4
|
+
export declare const cloneArrayIfExists: (fields: AttributesFormModel[]) => any;
|
|
5
|
+
export declare const transformAttributesForm: (response: getAttributesFormResponse) => AttributesFormModel[];
|
|
6
|
+
//# sourceMappingURL=transform-attributes-form.d.ts.map
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
export declare const loginContext: (ctx: any) => {
|
|
2
|
+
personalEmail: {
|
|
3
|
+
address: any;
|
|
4
|
+
};
|
|
5
|
+
userAccount: {
|
|
6
|
+
login: boolean;
|
|
7
|
+
};
|
|
8
|
+
commerce: {
|
|
9
|
+
commerceScope: {
|
|
10
|
+
storeCode: any;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
export declare const logoutContext: (ctx: any) => {
|
|
15
|
+
userAccount: {
|
|
16
|
+
logout: boolean;
|
|
17
|
+
};
|
|
18
|
+
commerce: {
|
|
19
|
+
commerceScope: {
|
|
20
|
+
storeCode: any;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
export declare const createAccountContext: (ctx: any) => {
|
|
25
|
+
personalEmail: {
|
|
26
|
+
address: any;
|
|
27
|
+
};
|
|
28
|
+
userAccount: {
|
|
29
|
+
updateProfile: any;
|
|
30
|
+
};
|
|
31
|
+
commerce: {
|
|
32
|
+
commerceScope: {
|
|
33
|
+
storeCode: any;
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
};
|
|
37
|
+
//# sourceMappingURL=transform-auth.d.ts.map
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { PasswordResetEmailResponse } from '../../types';
|
|
2
|
+
import { PasswordResetEmailModel } from '../models';
|
|
3
|
+
|
|
4
|
+
export declare const transformPasswordResetEmail: (response: PasswordResetEmailResponse) => PasswordResetEmailModel;
|
|
5
|
+
//# sourceMappingURL=transform-password-reset-email.d.ts.map
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { RevokeCustomerTokenResponse } from '../../types/api/revokeCustomerToken.types';
|
|
2
|
+
import { RevokeCustomerTokenModel } from '../models';
|
|
3
|
+
|
|
4
|
+
export declare const transformRevokeCustomerToken: (response: RevokeCustomerTokenResponse) => RevokeCustomerTokenModel;
|
|
5
|
+
//# sourceMappingURL=transform-revoke-customer-token.d.ts.map
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { inputsDefaultValueSetProps } from '../../types';
|
|
2
|
+
import { SignUpFieldsProps } from '../../configs/defaultCreateUserConfigs';
|
|
3
|
+
import { AttributesFormItemsProps } from '../../data/models';
|
|
4
|
+
|
|
5
|
+
interface UseGetAttributesFormProps {
|
|
6
|
+
fieldsConfigForApiVersion1: SignUpFieldsProps[];
|
|
7
|
+
apiVersion2: boolean;
|
|
8
|
+
inputsDefaultValueSet?: inputsDefaultValueSetProps[];
|
|
9
|
+
}
|
|
10
|
+
export declare const useGetAttributesForm: ({ inputsDefaultValueSet, fieldsConfigForApiVersion1, apiVersion2, }: UseGetAttributesFormProps) => {
|
|
11
|
+
fieldsListConfigs: AttributesFormItemsProps[];
|
|
12
|
+
};
|
|
13
|
+
export {};
|
|
14
|
+
//# sourceMappingURL=useGetAttributesForm.d.ts.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { useEmailConfirmationFormProps } from '../../types';
|
|
2
|
+
|
|
3
|
+
export declare const useEmailConfirmationForm: ({ userEmail, handleSetInLineAlertProps, }: useEmailConfirmationFormProps) => {
|
|
4
|
+
handleEmailConfirmation: () => Promise<void>;
|
|
5
|
+
disabledButton: boolean;
|
|
6
|
+
};
|
|
7
|
+
//# sourceMappingURL=useEmailConfirmationForm.d.ts.map
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ValidateLengthConfigProps, statusTypes } from '../../types';
|
|
2
|
+
|
|
3
|
+
interface UsePasswordValidationMessageProps {
|
|
4
|
+
passwordConfigs: {
|
|
5
|
+
minLength: number;
|
|
6
|
+
requiredCharacterClasses: number;
|
|
7
|
+
} | null;
|
|
8
|
+
isClickSubmit: boolean;
|
|
9
|
+
password: string;
|
|
10
|
+
}
|
|
11
|
+
export declare const usePasswordValidationMessage: ({ passwordConfigs, isClickSubmit, password, }: UsePasswordValidationMessageProps) => {
|
|
12
|
+
isValidUniqueSymbols: statusTypes;
|
|
13
|
+
defaultLengthMessage: ValidateLengthConfigProps | undefined;
|
|
14
|
+
};
|
|
15
|
+
export {};
|
|
16
|
+
//# sourceMappingURL=usePasswordValidationMessage.d.ts.map
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { UseResetPasswordFormProps } from '../../types';
|
|
2
|
+
|
|
3
|
+
export declare const useResetPasswordForm: ({ routeSignIn, onErrorCallback, setActiveComponent, handleSetInLineAlertProps, }: UseResetPasswordFormProps) => {
|
|
4
|
+
isLoading: boolean;
|
|
5
|
+
submitResetPassword: (event: any) => Promise<void>;
|
|
6
|
+
redirectToSignInPage: () => void;
|
|
7
|
+
};
|
|
8
|
+
//# sourceMappingURL=useResetPasswordForm.d.ts.map
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { AdditionalActionsAlertProps, useSignInFormProps } from '../../types';
|
|
2
|
+
|
|
3
|
+
export declare const useSignInForm: ({ emailConfirmationStatusMessage, translations, initialEmailValue, routeSignUp, routeForgotPassword, routeRedirectOnSignIn, onErrorCallback, setActiveComponent, onSuccessCallback, onSignUpLinkClick, handleSetInLineAlertProps, routeRedirectOnEmailConfirmationClose, }: useSignInFormProps) => {
|
|
4
|
+
additionalActionsAlert: AdditionalActionsAlertProps;
|
|
5
|
+
userEmail: string;
|
|
6
|
+
defaultEnhancedEmailFields: any;
|
|
7
|
+
passwordError: boolean;
|
|
8
|
+
isSuccessful: {
|
|
9
|
+
userName: string;
|
|
10
|
+
status: boolean;
|
|
11
|
+
};
|
|
12
|
+
isLoading: boolean;
|
|
13
|
+
signInPasswordValue: string;
|
|
14
|
+
showEmailConfirmationForm: boolean;
|
|
15
|
+
setShowEmailConfirmationForm: import('preact/hooks').Dispatch<import('preact/hooks').StateUpdater<boolean>>;
|
|
16
|
+
setSignInPasswordValue: import('preact/hooks').Dispatch<import('preact/hooks').StateUpdater<string>>;
|
|
17
|
+
submitLogInUser: (event: any) => Promise<void>;
|
|
18
|
+
forgotPasswordCallback: () => void;
|
|
19
|
+
onSignUpLinkClickCallback: () => void;
|
|
20
|
+
handledOnPrimaryButtonClick: () => void;
|
|
21
|
+
handleSetPassword: (value: string) => void;
|
|
22
|
+
};
|
|
23
|
+
//# sourceMappingURL=useSignInForm.d.ts.map
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { UseSingUpFormProps } from '../../types';
|
|
2
|
+
|
|
3
|
+
export declare const useSignUpForm: ({ addressesData, translations, isEmailConfirmationRequired, apiVersion2, passwordConfigs, isAutoSignInEnabled, routeRedirectOnSignIn, routeSignIn, onErrorCallback, onSuccessCallback, setActiveComponent, handleSetInLineAlertProps, routeRedirectOnEmailConfirmationClose, }: UseSingUpFormProps) => {
|
|
4
|
+
isKeepMeLogged: boolean;
|
|
5
|
+
userEmail: string;
|
|
6
|
+
showEmailConfirmationForm: boolean;
|
|
7
|
+
isSuccessful: {
|
|
8
|
+
userName: string;
|
|
9
|
+
status: boolean;
|
|
10
|
+
};
|
|
11
|
+
isClickSubmit: boolean;
|
|
12
|
+
signUpPasswordValue: string;
|
|
13
|
+
isLoading: boolean;
|
|
14
|
+
onSubmitSignUp: (event: SubmitEvent, isValid: boolean) => Promise<void>;
|
|
15
|
+
signInButton: () => void;
|
|
16
|
+
handleSetSignUpPasswordValue: (value: string) => void;
|
|
17
|
+
onKeepMeLoggedChange: ({ target }: any) => void;
|
|
18
|
+
handleHideEmailConfirmationForm: () => void;
|
|
19
|
+
};
|
|
20
|
+
//# sourceMappingURL=useSignUpForm.d.ts.map
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { AdditionalActionsAlertProps, UseUpdatePasswordFormProps } from '../../types';
|
|
2
|
+
|
|
3
|
+
export declare const useUpdatePasswordForm: ({ isEmailConfirmationRequired, signInOnSuccess, passwordConfigs, routeRedirectOnSignIn, routeWrongUrlRedirect, onErrorCallback, onSuccessCallback, handleSetInLineAlertProps, routeRedirectOnPasswordUpdate, routeSignInPage, }: UseUpdatePasswordFormProps) => {
|
|
4
|
+
additionalActionsAlert: AdditionalActionsAlertProps;
|
|
5
|
+
passwordError: boolean;
|
|
6
|
+
isSuccessful: {
|
|
7
|
+
userName: string;
|
|
8
|
+
status: boolean;
|
|
9
|
+
};
|
|
10
|
+
updatePasswordValue: string;
|
|
11
|
+
isClickSubmit: boolean;
|
|
12
|
+
isLoading: boolean;
|
|
13
|
+
submitUpdatePassword: (event: Event) => Promise<void>;
|
|
14
|
+
handleSetUpdatePasswordValue: (value: string) => void;
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=useUpdatePasswordForm.d.ts.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { useFormProps } from '../../types';
|
|
2
|
+
|
|
3
|
+
export declare const useForm: ({ fieldsConfig, submitCallback }: useFormProps) => {
|
|
4
|
+
formData: Record<string, string | number | boolean>;
|
|
5
|
+
errors: Record<string, string>;
|
|
6
|
+
formRef: import('preact').RefObject<HTMLFormElement>;
|
|
7
|
+
handleChange: (event: Event) => void;
|
|
8
|
+
handleBlur: (event: Event) => void;
|
|
9
|
+
handleSubmit: (event: SubmitEvent) => void;
|
|
10
|
+
handleFocus: () => Promise<void>;
|
|
11
|
+
};
|
|
12
|
+
//# sourceMappingURL=useForm.d.ts.map
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
interface useEmailConfirmationProps {
|
|
2
|
+
enableEmailConfirmation: boolean;
|
|
3
|
+
}
|
|
4
|
+
export declare const useEmailConfirmation: ({ enableEmailConfirmation, }: useEmailConfirmationProps) => {
|
|
5
|
+
emailConfirmationStatusMessage: {
|
|
6
|
+
text: string;
|
|
7
|
+
status: '' | 'success' | 'error';
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=useEmailConfirmation.d.ts.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { InLineAlertInterface } from '../types';
|
|
2
|
+
|
|
3
|
+
export declare const useInLineAlert: () => {
|
|
4
|
+
inLineAlertProps: InLineAlertInterface;
|
|
5
|
+
handleSetInLineAlertProps: (notification: InLineAlertInterface | undefined) => void;
|
|
6
|
+
};
|
|
7
|
+
//# sourceMappingURL=useInLineAlert.d.ts.map
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
"Auth": {
|
|
3
|
+
"PasswordValidationMessage": {
|
|
4
|
+
"chartTwoSymbols": "Use characters and numbers or symbols",
|
|
5
|
+
"chartThreeSymbols": "Use characters, numbers and symbols",
|
|
6
|
+
"chartFourSymbols": "Use uppercase characters, lowercase characters, numbers and symbols",
|
|
7
|
+
"messageLengthPassword": "At least {minLength} characters long"
|
|
8
|
+
},
|
|
9
|
+
"ResetPasswordForm": {
|
|
10
|
+
"title": "Reset your password",
|
|
11
|
+
"buttonPrimary": "Reset password",
|
|
12
|
+
"buttonSecondary": "Back to sign in"
|
|
13
|
+
},
|
|
14
|
+
"SignInForm": {
|
|
15
|
+
"title": "Sign in",
|
|
16
|
+
"buttonPrimary": "Sign in",
|
|
17
|
+
"buttonSecondary": "Sign up",
|
|
18
|
+
"buttonTertiary": "Forgot password?"
|
|
19
|
+
},
|
|
20
|
+
"SignUpForm": {
|
|
21
|
+
"title": "Sign up",
|
|
22
|
+
"buttonPrimary": "Create account",
|
|
23
|
+
"buttonSecondary": "Already a member? Sign in",
|
|
24
|
+
"privacyPolicyDefaultText": "I’ve read and accept the Terms of Use and Privacy Policy.",
|
|
25
|
+
"subscribedDefaultText": "Subscribe to our newsletter and be the first to know about new arrivals, sales and exclusive offers.",
|
|
26
|
+
"keepMeLoggedText": "Keep me logged in after account creation",
|
|
27
|
+
"failedCreateCustomerAddress": "Failed to create customer addresses:"
|
|
28
|
+
},
|
|
29
|
+
"UpdatePasswordForm": {
|
|
30
|
+
"title": "Update password",
|
|
31
|
+
"buttonPrimary": "Update password"
|
|
32
|
+
},
|
|
33
|
+
"FormText": {
|
|
34
|
+
"requiredFieldError": "This is a required field."
|
|
35
|
+
},
|
|
36
|
+
"EmailConfirmationForm": {
|
|
37
|
+
"title": "Verify your email address",
|
|
38
|
+
"subtitle": "We`ve sent an email to",
|
|
39
|
+
"mainText": "Check your inbox and click on the link we just send you to confirm your email address and activate your account.",
|
|
40
|
+
"buttonSecondary": "Resend email",
|
|
41
|
+
"buttonPrimary": "Close",
|
|
42
|
+
"accountConfirmMessage": "Account confirmed",
|
|
43
|
+
"accountConfirmationEmailSuccessMessage": "Congratulations! Your account at {email} email has been successfully confirmed."
|
|
44
|
+
},
|
|
45
|
+
"Notification": {
|
|
46
|
+
"errorNotification": "Your password update failed due to validation errors. Please check your information and try again.",
|
|
47
|
+
"updatePasswordMessage": "The password has been updated.",
|
|
48
|
+
"updatePasswordActionMessage": "Sign in",
|
|
49
|
+
"successPasswordResetEmailNotification": "If there is an account associated with {email} you will receive an email with a link to reset your password.",
|
|
50
|
+
"resendEmailNotification": {
|
|
51
|
+
"informationText": "This account is not confirmed.",
|
|
52
|
+
"buttonText": "Resend confirmation email"
|
|
53
|
+
},
|
|
54
|
+
"emailConfirmationMessage": "Please check your email for confirmation link.",
|
|
55
|
+
"technicalErrors": {
|
|
56
|
+
"technicalErrorSendEmail": "A technical error occurred while trying to send the email. Please try again later."
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
"SuccessNotification": {
|
|
60
|
+
"headingText":"Welcome!",
|
|
61
|
+
"messageText":"We are glad to see you!",
|
|
62
|
+
"primaryButtonText":"Continue shopping",
|
|
63
|
+
"secondaryButtonText":"Logout"
|
|
64
|
+
},
|
|
65
|
+
"Api": {
|
|
66
|
+
"customerTokenErrorMessage": "Unable to log in. Please try again later or contact support if the issue persists."
|
|
67
|
+
},
|
|
68
|
+
"InputPassword": {
|
|
69
|
+
"placeholder": "Password",
|
|
70
|
+
"floatingLabel": "Password *"
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
;
|
|
75
|
+
|
|
76
|
+
export default _default;
|
package/lib/acdl.d.ts
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
declare enum EventsList {
|
|
2
|
+
CREATE_ACCOUNT_EVENT = "create-account",
|
|
3
|
+
SIGN_IN = "sign-in",
|
|
4
|
+
SIGN_OUT = "sign-out"
|
|
5
|
+
}
|
|
6
|
+
export declare function pushEvent(event: string): void;
|
|
7
|
+
declare const publishEvents: (eventType: string, eventParams: any) => null | undefined;
|
|
8
|
+
export { EventsList, publishEvents };
|
|
9
|
+
//# sourceMappingURL=acdl.d.ts.map
|
package/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name": "@dropins/storefront-auth", "version": "0.0.1-
|
|
1
|
+
{"name": "@dropins/storefront-auth", "version": "0.0.1-alpha21", "@dropins/elsie": "0.32.0"}
|
package/render.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './render/index'
|
package/render.js
CHANGED
|
@@ -1 +1,8 @@
|
|
|
1
|
-
import*as e from"@dropins/tools/event-bus.js";export const id=375;export const ids=[375];export const modules={4621:(e,t,n)=>{n.d(t,{X:()=>be});var r=n(616),o=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|^--/i,a=/^(area|base|br|col|embed|hr|img|input|link|meta|param|source|track|wbr)$/,i=/[\s\n\\/='"\0<>]/,l=/^xlink:?./,s=/["&<]/;function c(e){if(!1===s.test(e+=""))return e;for(var t=0,n=0,r="",o="";n<e.length;n++){switch(e.charCodeAt(n)){case 34:o=""";break;case 38:o="&";break;case 60:o="<";break;default:continue}n!==t&&(r+=e.slice(t,n)),r+=o,t=n+1}return n!==t&&(r+=e.slice(t,n)),r}var d=function(e,t){return String(e).replace(/(\n+)/g,"$1"+(t||"\t"))},p=function(e,t,n){return String(e).length>(t||40)||!n&&-1!==String(e).indexOf("\n")||-1!==String(e).indexOf("<")},f={},u=/([A-Z])/g;function y(e){var t="";for(var n in e){var r=e[n];null!=r&&""!==r&&(t&&(t+=" "),t+="-"==n[0]?n:f[n]||(f[n]=n.replace(u,"-$1").toLowerCase()),t="number"==typeof r&&!1===o.test(n)?t+": "+r+"px;":t+": "+r+";")}return t||void 0}function m(e,t){return Array.isArray(t)?t.reduce(m,e):null!=t&&!1!==t&&e.push(t),e}function b(){this.__d=!0}function g(e,t){return{__v:e,context:t,props:e.props,setState:b,forceUpdate:b,__d:!0,__h:[]}}function v(e,t){var n=e.contextType,r=n&&t[n.__c];return null!=n?r?r.props.value:n.__:t}var h=[];function x(e,t,n,o,s,f){if(null==e||"boolean"==typeof e)return"";if("object"!=typeof e)return"function"==typeof e?"":c(e);var u=n.pretty,b=u&&"string"==typeof u?u:"\t";if(Array.isArray(e)){for(var w="",_=0;_<e.length;_++)u&&_>0&&(w+="\n"),w+=x(e[_],t,n,o,s,f);return w}if(void 0!==e.constructor)return"";var S,O=e.type,j=e.props,k=!1;if("function"==typeof O){if(k=!0,!n.shallow||!o&&!1!==n.renderRootComponent){if(O===r.FK){var P=[];return m(P,e.props.children),x(P,t,n,!1!==n.shallowHighOrder,s,f)}var A,C=e.__c=g(e,t);r.fF.__b&&r.fF.__b(e);var E=r.fF.__r;if(O.prototype&&"function"==typeof O.prototype.render){var F=v(O,t);(C=e.__c=new O(j,F)).__v=e,C._dirty=C.__d=!0,C.props=j,null==C.state&&(C.state={}),null==C._nextState&&null==C.__s&&(C._nextState=C.__s=C.state),C.context=F,O.getDerivedStateFromProps?C.state=Object.assign({},C.state,O.getDerivedStateFromProps(C.props,C.state)):C.componentWillMount&&(C.componentWillMount(),C.state=C._nextState!==C.state?C._nextState:C.__s!==C.state?C.__s:C.state),E&&E(e),A=C.render(C.props,C.state,C.context)}else for(var I=v(O,t),D=0;C.__d&&D++<25;)C.__d=!1,E&&E(e),A=O.call(e.__c,j,I);return C.getChildContext&&(t=Object.assign({},t,C.getChildContext())),r.fF.diffed&&r.fF.diffed(e),x(A,t,n,!1!==n.shallowHighOrder,s,f)}O=(S=O).displayName||S!==Function&&S.name||function(e){var t=(Function.prototype.toString.call(e).match(/^\s*function\s+([^( ]+)/)||"")[1];if(!t){for(var n=-1,r=h.length;r--;)if(h[r]===e){n=r;break}n<0&&(n=h.push(e)-1),t="UnnamedComponent"+n}return t}(S)}var T,M,L="<"+O;if(j){var U=Object.keys(j);n&&!0===n.sortAttributes&&U.sort();for(var N=0;N<U.length;N++){var R=U[N],B=j[R];if("children"!==R){if(!i.test(R)&&(n&&n.allAttributes||"key"!==R&&"ref"!==R&&"__self"!==R&&"__source"!==R)){if("defaultValue"===R)R="value";else if("defaultChecked"===R)R="checked";else if("defaultSelected"===R)R="selected";else if("className"===R){if(void 0!==j.class)continue;R="class"}else s&&l.test(R)&&(R=R.toLowerCase().replace(/^xlink:?/,"xlink:"));if("htmlFor"===R){if(j.for)continue;R="for"}"style"===R&&B&&"object"==typeof B&&(B=y(B)),"a"===R[0]&&"r"===R[1]&&"boolean"==typeof B&&(B=String(B));var $=n.attributeHook&&n.attributeHook(R,B,t,n,k);if($||""===$)L+=$;else if("dangerouslySetInnerHTML"===R)M=B&&B.__html;else if("textarea"===O&&"value"===R)T=B;else if((B||0===B||""===B)&&"function"!=typeof B){if(!(!0!==B&&""!==B||(B=R,n&&n.xml))){L=L+" "+R;continue}if("value"===R){if("select"===O){f=B;continue}"option"===O&&f==B&&void 0===j.selected&&(L+=" selected")}L=L+" "+R+'="'+c(B)+'"'}}}else T=B}}if(u){var Y=L.replace(/\n\s*/," ");Y===L||~Y.indexOf("\n")?u&&~L.indexOf("\n")&&(L+="\n"):L=Y}if(L+=">",i.test(O))throw new Error(O+" is not a valid HTML tag name in "+L);var H,K=a.test(O)||n.voidElements&&n.voidElements.test(O),z=[];if(M)u&&p(M)&&(M="\n"+b+d(M,b)),L+=M;else if(null!=T&&m(H=[],T).length){for(var q=u&&~L.indexOf("\n"),X=!1,V=0;V<H.length;V++){var W=H[V];if(null!=W&&!1!==W){var G=x(W,t,n,!0,"svg"===O||"foreignObject"!==O&&s,f);if(u&&!q&&p(G)&&(q=!0),G)if(u){var J=G.length>0&&"<"!=G[0];X&&J?z[z.length-1]+=G:z.push(G),X=J}else z.push(G)}}if(u&&q)for(var Q=z.length;Q--;)z[Q]="\n"+b+d(z[Q],b)}if(z.length||M)L+=z.join("");else if(n&&n.xml)return L.substring(0,L.length-1)+" />";return!K||H||M?(u&&~L.indexOf("\n")&&(L+="\n"),L=L+"</"+O+">"):L=L.replace(/>$/," />"),L}var w={shallow:!0};S.render=S;var _=[];function S(e,t,n){t=t||{};var o=r.fF.__s;r.fF.__s=!0;var a,i=(0,r.h)(r.FK,null);return i.__k=[e],a=n&&(n.pretty||n.voidElements||n.sortAttributes||n.shallow||n.allAttributes||n.xml||n.attributeHook)?x(e,t,n):C(e,t,!1,void 0,i),r.fF.__c&&r.fF.__c(e,_),r.fF.__s=o,_.length=0,a}function O(e){return null==e||"boolean"==typeof e?null:"string"==typeof e||"number"==typeof e||"bigint"==typeof e?(0,r.h)(null,null,e):e}function j(e,t){return"className"===e?"class":"htmlFor"===e?"for":"defaultValue"===e?"value":"defaultChecked"===e?"checked":"defaultSelected"===e?"selected":t&&l.test(e)?e.toLowerCase().replace(/^xlink:?/,"xlink:"):e}function k(e,t){return"style"===e&&null!=t&&"object"==typeof t?y(t):"a"===e[0]&&"r"===e[1]&&"boolean"==typeof t?String(t):t}var P=Array.isArray,A=Object.assign;function C(e,t,n,o,l){if(null==e||!0===e||!1===e||""===e)return"";if("object"!=typeof e)return"function"==typeof e?"":c(e);if(P(e)){var s="";l.__k=e;for(var d=0;d<e.length;d++)s+=C(e[d],t,n,o,l),e[d]=O(e[d]);return s}if(void 0!==e.constructor)return"";e.__=l,r.fF.__b&&r.fF.__b(e);var p=e.type,f=e.props;if("function"==typeof p){var u;if(p===r.FK)u=f.children;else{u=p.prototype&&"function"==typeof p.prototype.render?function(e,t){var n=e.type,o=v(n,t),a=new n(e.props,o);e.__c=a,a.__v=e,a.__d=!0,a.props=e.props,null==a.state&&(a.state={}),null==a.__s&&(a.__s=a.state),a.context=o,n.getDerivedStateFromProps?a.state=A({},a.state,n.getDerivedStateFromProps(a.props,a.state)):a.componentWillMount&&(a.componentWillMount(),a.state=a.__s!==a.state?a.__s:a.state);var i=r.fF.__r;return i&&i(e),a.render(a.props,a.state,a.context)}(e,t):function(e,t){var n,o=g(e,t),a=v(e.type,t);e.__c=o;for(var i=r.fF.__r,l=0;o.__d&&l++<25;)o.__d=!1,i&&i(e),n=e.type.call(o,e.props,a);return n}(e,t);var y=e.__c;y.getChildContext&&(t=A({},t,y.getChildContext()))}var m=C(u=null!=u&&u.type===r.FK&&null==u.key?u.props.children:u,t,n,o,e);return r.fF.diffed&&r.fF.diffed(e),e.__=void 0,r.fF.unmount&&r.fF.unmount(e),m}var b,h,x="<";if(x+=p,f)for(var w in b=f.children,f){var _=f[w];if(!("key"===w||"ref"===w||"__self"===w||"__source"===w||"children"===w||"className"===w&&"class"in f||"htmlFor"===w&&"for"in f||i.test(w)))if(_=k(w=j(w,n),_),"dangerouslySetInnerHTML"===w)h=_&&_.__html;else if("textarea"===p&&"value"===w)b=_;else if((_||0===_||""===_)&&"function"!=typeof _){if(!0===_||""===_){_=w,x=x+" "+w;continue}if("value"===w){if("select"===p){o=_;continue}"option"!==p||o!=_||"selected"in f||(x+=" selected")}x=x+" "+w+'="'+c(_)+'"'}}var S=x;if(x+=">",i.test(p))throw new Error(p+" is not a valid HTML tag name in "+x);var E="",F=!1;if(h)E+=h,F=!0;else if("string"==typeof b)E+=c(b),F=!0;else if(P(b)){e.__k=b;for(var I=0;I<b.length;I++){var D=b[I];if(b[I]=O(D),null!=D&&!1!==D){var T=C(D,t,"svg"===p||"foreignObject"!==p&&n,o,e);T&&(E+=T,F=!0)}}}else if(null!=b&&!1!==b&&!0!==b){e.__k=[O(b)];var M=C(b,t,"svg"===p||"foreignObject"!==p&&n,o,e);M&&(E+=M,F=!0)}if(r.fF.diffed&&r.fF.diffed(e),e.__=void 0,r.fF.unmount&&r.fF.unmount(e),F)x+=E;else if(a.test(p))return S+" />";return x+"</"+p+">"}S.shallowRender=function(e,t){return S(e,t,w)};const E=S;var F=n(5704),I=n(8294);function D(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function T(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?D(Object(n),!0).forEach((function(t){M(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):D(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function M(e,t,n){return t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function L(e,t,n,r,o,a,i){try{var l=e[a](i),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(r,o)}function U(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var a=e.apply(t,n);function i(e){L(a,r,o,i,l,"next",e)}function l(e){L(a,r,o,i,l,"throw",e)}i(void 0)}))}}var N=n(3078),R=n(9094),B=n(4156),$=n.n(B),Y=n(6613);const H=JSON.parse('{"Dropin":{"ExampleComponentName":{"item":{"label":"string"}},"Incrementer":{"decreaseLabel":"Decrease Quantity","increaseLabel":"Increase Quantity","label":"Quantity"},"Modal":{"Close":{"label":"Close"}},"InlineAlert":{"dismissLabel":"Dismiss Alert"},"PriceSummary":{"subTotal":{"label":"Subtotal","withTaxes":"Including taxes"},"shipping":{"label":"Shipping","editZipAction":"Apply","estimated":"Estimated Shipping","estimatedDestination":"Estimated Shipping to ","destinationLinkAriaLabel":"Change destination","zipPlaceholder":"Zip Code","withTaxes":"Including taxes","alternateField":{"zip":"Estimate using country/zip","state":"Estimate using country/state"}},"taxes":{"total":"Tax Total","totalOnly":"Tax","breakdown":"Taxes","showBreakdown":"Show Tax Breakdown","hideBreakdown":"Hide Tax Breakdown","estimated":"Estimated Tax"},"total":{"estimated":"Estimated Total","label":"Total","withoutTax":"Total excluding taxes"}},"ProgressSpinner":{"updating":{"label":"Item is updating"},"updatingChildren":{"label":"Items are updating"}},"PriceRange":{"from":{"label":"From"},"to":{"label":"to"},"asLowAs":{"label":"As low as"}},"Swatches":{"outOfStock":{"label":"out of stock swatch"},"selected":{"label":"swatch selected"},"swatch":{"label":"swatch"}},"Accordion":{"open":{"label":"Open"},"close":{"label":"Close"}},"CartItem":{"each":{"label":"each"},"quantity":{"label":"Quantity"},"remove":{"label":"Remove {product} from the cart"},"removeDefault":{"label":"Remove item from the cart"},"taxIncluded":{"label":"incl. VAT"},"updating":{"label":"{product} is updating"}}}}');var K=n(5808),z={default:H,en_US:H},q=n(5292),X=n.n(q),V=n(9893),W=n.n(V),G=n(9383),J=n.n(G),Q=n(8296),Z=n.n(Q),ee=n(9088),te=n.n(ee),ne=n(227),re={attributes:{"data-dropin":"storefront-auth","data-sdk":"0.21.2"},styleTagTransform:function(e,t){window._loadedStyles=window._loadedStyles??{};const n=e?.match(/^\.dropin-(\w+)/)?.[1],r=t.getAttribute("data-sdk"),o=n?`sdk/${n}`:t.getAttribute("data-dropin");t.setAttribute("data-dropin",o),t.removeAttribute("data-sdk");const a=window._loadedStyles[o];if(a){const o=function(e,t){const[n,r]=e.split("-"),[o,a]=t.split("-"),i=[...n.split("."),r],l=[...o.split("."),a],s=parseInt(i[0],10),c=parseInt(l[0],10);if(s!==c)return s>c?e:t;const d=parseInt(i[1],10),p=parseInt(l[1],10);if(d!==p)return d>p?e:t;const f=parseInt(i[2],10),u=parseInt(l[2],10);if(f!==u)return f>u?e:t;if(i[3]&&l[3]){const n=/(alpha|beta)(.*)/,r=i[3].match(n),o=l[3].match(n),a=r[1],s=o[1],c=parseInt(r[2],10),d=parseInt(o[2],10);if(a===s)return c>d?e:t;if("alpha"===a&&"beta"===s)return t;if("beta"===a&&"alpha"===s)return e}return i[3]?t:e}(r,a.sdk);if(!n||n&&o===a.sdk){const t=a.style.textContent;a.style.textContent=`${t}\n/* --- MERGED --- */\n${e}`}else n&&o!==a.sdk&&(a.style.textContent=`/* --- UPGRADED --- */\n${e}`);return void t.remove()}t.textContent=e,window._loadedStyles[o]={sdk:r,core:n,style:t};const i=document.querySelector("head"),{lastDropinStyleInjected:l,lastSDKStyleInjected:s}=window._loadedStyles;n?(s?i.insertBefore(t,s.nextSibling):i.insertBefore(t,i.firstChild),window._loadedStyles.lastSDKStyleInjected=t):(l?i.insertBefore(t,l.nextSibling):s?i.insertBefore(t,s.nextSibling):i.insertBefore(t,i.firstChild),window._loadedStyles.lastDropinStyleInjected=t)}};re.setAttributes=Z(),re.insert=J().bind(null,"head"),re.domAPI=W(),re.insertStyleElement=te();X()(ne.A,re);ne.A&&ne.A.locals&&ne.A.locals;var oe=n(1869),ae={attributes:{"data-dropin":"storefront-auth","data-sdk":"0.21.2"},styleTagTransform:function(e,t){window._loadedStyles=window._loadedStyles??{};const n=e?.match(/^\.dropin-(\w+)/)?.[1],r=t.getAttribute("data-sdk"),o=n?`sdk/${n}`:t.getAttribute("data-dropin");t.setAttribute("data-dropin",o),t.removeAttribute("data-sdk");const a=window._loadedStyles[o];if(a){const o=function(e,t){const[n,r]=e.split("-"),[o,a]=t.split("-"),i=[...n.split("."),r],l=[...o.split("."),a],s=parseInt(i[0],10),c=parseInt(l[0],10);if(s!==c)return s>c?e:t;const d=parseInt(i[1],10),p=parseInt(l[1],10);if(d!==p)return d>p?e:t;const f=parseInt(i[2],10),u=parseInt(l[2],10);if(f!==u)return f>u?e:t;if(i[3]&&l[3]){const n=/(alpha|beta)(.*)/,r=i[3].match(n),o=l[3].match(n),a=r[1],s=o[1],c=parseInt(r[2],10),d=parseInt(o[2],10);if(a===s)return c>d?e:t;if("alpha"===a&&"beta"===s)return t;if("beta"===a&&"alpha"===s)return e}return i[3]?t:e}(r,a.sdk);if(!n||n&&o===a.sdk){const t=a.style.textContent;a.style.textContent=`${t}\n/* --- MERGED --- */\n${e}`}else n&&o!==a.sdk&&(a.style.textContent=`/* --- UPGRADED --- */\n${e}`);return void t.remove()}t.textContent=e,window._loadedStyles[o]={sdk:r,core:n,style:t};const i=document.querySelector("head"),{lastDropinStyleInjected:l,lastSDKStyleInjected:s}=window._loadedStyles;n?(s?i.insertBefore(t,s.nextSibling):i.insertBefore(t,i.firstChild),window._loadedStyles.lastSDKStyleInjected=t):(l?i.insertBefore(t,l.nextSibling):s?i.insertBefore(t,s.nextSibling):i.insertBefore(t,i.firstChild),window._loadedStyles.lastDropinStyleInjected=t)}};ae.setAttributes=Z(),ae.insert=J().bind(null,"head"),ae.domAPI=W(),ae.insertStyleElement=te();X()(oe.A,ae);oe.A&&oe.A.locals&&oe.A.locals;var ie=["lang","langDefinitions","className","children"];function le(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function se(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?le(Object(n),!0).forEach((function(t){ce(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):le(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function ce(e,t,n){return t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function de(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var pe=(0,R.q6)({locale:"en-US"}),fe=e=>{var{lang:t="en_US",langDefinitions:n={},className:r,children:o}=e,a=de(e,ie),i=(0,R.Kr)((()=>{var e,r=$()(n.default,null!==(e=n[t])&&void 0!==e?e:{});return $()((e=>$()(z.default,z[e]||{}))(t),r)}),[t,n]),l=t.replace("_","-");return(0,I.Y)(pe.Provider,{value:{locale:l},children:(0,I.Y)(K.Dk,{definition:i,children:(0,I.Y)("div",se(se({},a),{},{className:(0,Y.L)(["dropin-design",r]),children:o}))})})},ue=n(1178);ue.events.enableLogger(!0);var ye={default:n(6601)},me=e=>{var{children:t}=e,[n,r]=(0,N.J0)("en_US");return(0,N.vJ)((()=>{var e=ue.events.on("locale",(e=>{r(e)}),{eager:!0});return()=>{null==e||e.off()}}),[]),(0,I.Y)(fe,{lang:n,langDefinitions:ye,children:t})},be=new class{constructor(e){this._provider=e}render(e,t){var n=this;return function(){var o=U((function*(o){var a,i;if(!e)throw new Error("Component is not defined");if(!o)throw new Error("Root element is not defined");var l=null!==(a=yield null===(i=e.getInitialData)||void 0===i?void 0:i.call(e,t))&&void 0!==a?a:{};(0,r.XX)((0,I.Y)(F.a,T(T({node:n._provider},n._provider.props),{},{children:(0,I.Y)(e,T(T({},t),{},{initialData:l}))})),o)}));return function(e){return o.apply(this,arguments)}}()}unmount(e){if(!e)throw new Error("Root element is not defined");(0,r.XX)(null,e)}toString(e,t,n){var r=this;return U((function*(){var o,a;if(!e)throw new Error("Component is not defined");var i=null!==(o=yield null===(a=e.getInitialData)||void 0===a?void 0:a.call(e,t))&&void 0!==o?o:{};return E((0,I.Y)(F.a,T(T({node:r._provider},r._provider.props),{},{children:(0,I.Y)(e,T(T({},t),{},{initialData:i}))})),{},T({},n))}))()}}((0,I.Y)(me,{}))},227:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(8645),o=n.n(r),a=n(278),i=n.n(a)()(o());i.push([e.id,".dropin-design{\n --color-brand-500:#454545;\n --color-brand-600:#383838;\n --color-brand-700:#2b2b2b;\n --color-neutral-50:#ffffff;\n --color-neutral-100:#fafafa;\n --color-neutral-200:#f5f5f5;\n --color-neutral-300:#e8e8e8;\n --color-neutral-400:#d6d6d6;\n --color-neutral-500:#b8b8b8;\n --color-neutral-600:#8f8f8f;\n --color-neutral-700:#666666;\n --color-neutral-800:#3d3d3d;\n --color-neutral-900:#292929;\n --color-positive-200:#eff5ef;\n --color-positive-500:#7fb078;\n --color-positive-800:#53824c;\n --color-informational-200:#eeeffb;\n --color-informational-500:#6978d9;\n --color-informational-800:#5d6dd6;\n --color-warning-200:#fdf3e9;\n --color-warning-500:#e79f5c;\n --color-warning-800:#ad5c00;\n --color-alert-200:#ffebeb;\n --color-alert-500:#db7070;\n --color-alert-800:#bf4545;\n --color-opacity-16:rgba(255, 255, 255, 0.16);\n --color-opacity-24:rgba(255, 255, 255, 0.24);\n --color-action-button-active:#ffffff;\n --color-action-button-hover:#e8e8e8;\n --color-button-active:#2b2b2b;\n --color-button-focus:#d6d6d6;\n --color-button-hover:#383838;\n --grid-1-columns:4;\n --grid-1-margins:0;\n --grid-1-gutters:16px;\n --grid-2-columns:12;\n --grid-2-margins:0;\n --grid-2-gutters:16px;\n --grid-3-columns:12;\n --grid-3-margins:0;\n --grid-3-gutters:24px;\n --grid-4-columns:12;\n --grid-4-margins:0;\n --grid-4-gutters:24px;\n --grid-5-columns:12;\n --grid-5-margins:0;\n --grid-5-gutters:24px;\n --shape-border-radius-1:3px;\n --shape-border-radius-2:8px;\n --shape-border-radius-3:24px;\n --shape-border-width-1:1px;\n --shape-border-width-2:1.5px;\n --shape-border-width-3:2px;\n --shape-border-width-4:4px;\n --shape-shadow-1:0 0 16px 0 rgba(0, 0, 0, 0.16);\n --shape-shadow-2:0 2px 16px 0 rgba(0, 0, 0, 0.16);\n --shape-shadow-3:0 2px 3px 0 rgba(0, 0, 0, 0.16);\n --shape-icon-stroke-1:1px;\n --shape-icon-stroke-2:1.5px;\n --shape-icon-stroke-3:2px;\n --shape-icon-stroke-4:4px;\n --spacing-xxsmall:4px;\n --spacing-xsmall:8px;\n --spacing-small:16px;\n --spacing-medium:24px;\n --spacing-big:32px;\n --spacing-xbig:40px;\n --spacing-xxbig:48px;\n --spacing-large:64px;\n --spacing-xlarge:72px;\n --spacing-xxlarge:96px;\n --spacing-huge:120px;\n --spacing-xhuge:144px;\n --spacing-xxhuge:192px;\n --type-base-font-family:system-ui, sans-serif;\n --type-display-1-font:normal normal 300 60px/72px var(--type-base-font-family);\n --type-display-1-letter-spacing:0.04em;\n --type-display-2-font:normal normal 300 48px/56px var(--type-base-font-family);\n --type-display-2-letter-spacing:0.04em;\n --type-display-3-font:normal normal 300 34px/40px var(--type-base-font-family);\n --type-display-3-letter-spacing:0.04em;\n --type-headline-1-font:normal normal 400 24px/32px var(--type-base-font-family);\n --type-headline-1-letter-spacing:0.04em;\n --type-headline-2-default-font:normal normal 300 20px/24px var(--type-base-font-family);\n --type-headline-2-default-letter-spacing:0.04em;\n --type-headline-2-strong-font:normal normal 400 20px/24px var(--type-base-font-family);\n --type-headline-2-strong-letter-spacing:0.04em;\n --type-body-1-default-font:normal normal 300 16px/24px var(--type-base-font-family);\n --type-body-1-default-letter-spacing:0.04em;\n --type-body-1-strong-font:normal normal 400 16px/24px var(--type-base-font-family);\n --type-body-1-strong-letter-spacing:0.04em;\n --type-body-1-emphasized-font:normal normal 700 16px/24px var(--type-base-font-family);\n --type-body-1-emphasized-letter-spacing:0.04em;\n --type-body-2-default-font:normal normal 300 14px/20px var(--type-base-font-family);\n --type-body-2-default-letter-spacing:0.04em;\n --type-body-2-strong-font:normal normal 400 14px/20px var(--type-base-font-family);\n --type-body-2-strong-letter-spacing:0.04em;\n --type-body-2-emphasized-font:normal normal 700 14px/20px var(--type-base-font-family);\n --type-body-2-emphasized-letter-spacing:0.04em;\n --type-button-1-font:normal normal 400 20px/26px var(--type-base-font-family);\n --type-button-1-letter-spacing:0.08em;\n --type-button-2-font:normal normal 400 16px/24px var(--type-base-font-family);\n --type-button-2-letter-spacing:0.08em;\n --type-details-caption-1-font:normal normal 400 12px/16px var(--type-base-font-family);\n --type-details-caption-1-letter-spacing:0.08em;\n --type-details-caption-2-font:normal normal 300 12px/16px var(--type-base-font-family);\n --type-details-caption-2-letter-spacing:0.08em;\n --type-details-overline-font:normal normal 700 12px/20px var(--type-base-font-family);\n --type-details-overline-letter-spacing:0.16em;\n}\n",""]);const l=i},1869:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(8645),o=n.n(r),a=n(278),i=n.n(a)()(o());i.push([e.id,".dropin-design a{\n --textColor:var(--color-brand-500);\n color:var(--textColor);\n text-decoration:none;\n}\n\n.dropin-design a:hover{\n --textColor:var(--color-brand-700);\n text-decoration:solid underline var(--textColor);\n text-underline-offset:6px;\n}\n\n.dropin-design a:focus-visible{\n outline:solid var(--shape-border-width-4) var(--color-neutral-400);\n border:var(--shape-border-width-1) solid var(--color-neutral-800);\n border-radius:var(--shape-border-radius-1);\n}\n",""]);const l=i},4156:e=>{var t=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var t=Object.prototype.toString.call(e);return"[object RegExp]"===t||"[object Date]"===t||function(e){return e.$$typeof===n}(e)}(e)};var n="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function r(e,t){return!1!==t.clone&&t.isMergeableObject(e)?s((n=e,Array.isArray(n)?[]:{}),e,t):e;var n}function o(e,t,n){return e.concat(t).map((function(e){return r(e,n)}))}function a(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter((function(t){return Object.propertyIsEnumerable.call(e,t)})):[]}(e))}function i(e,t){try{return t in e}catch(e){return!1}}function l(e,t,n){var o={};return n.isMergeableObject(e)&&a(e).forEach((function(t){o[t]=r(e[t],n)})),a(t).forEach((function(a){(function(e,t){return i(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,a)||(i(e,a)&&n.isMergeableObject(t[a])?o[a]=function(e,t){if(!t.customMerge)return s;var n=t.customMerge(e);return"function"==typeof n?n:s}(a,n)(e[a],t[a],n):o[a]=r(t[a],n))})),o}function s(e,n,a){(a=a||{}).arrayMerge=a.arrayMerge||o,a.isMergeableObject=a.isMergeableObject||t,a.cloneUnlessOtherwiseSpecified=r;var i=Array.isArray(n);return i===Array.isArray(e)?i?a.arrayMerge(e,n,a):l(e,n,a):r(n,a)}s.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce((function(e,n){return s(e,n,t)}),{})};var c=s;e.exports=c},1178:(t,n,r)=>{t.exports=(e=>{var t={};return r.d(t,e),t})({events:()=>e.events})},6601:e=>{e.exports=JSON.parse('{"Auth":{"PasswordValidationMessage":{"chartTwoSymbols":"Use characters and numbers or symbols","chartThreeSymbols":"Use characters, numbers and symbols","chartFourSymbols":"Use uppercase characters, lowercase characters, numbers and symbols","messageLengthPassword":"At least {minLength} characters long"},"ResetPasswordForm":{"title":"Reset your password","buttonPrimary":"Reset password","buttonSecondary":"Back to sign in"},"SignInForm":{"title":"Sign in","buttonPrimary":"Sign in","buttonSecondary":"Sign up","buttonTertiary":"Forgot password?"},"SignUpForm":{"title":"Sign up","buttonPrimary":"Create account","buttonSecondary":"Already a member? Sign in","privacyPolicyDefaultText":"I’ve read and accept the Terms of Use and Privacy Policy.","subscribedDefaultText":"Subscribe to our newsletter and be the first to know about new arrivals, sales and exclusive offers.","keepMeLoggedText":"Keep me logged in after account creation"},"UpdatePasswordForm":{"title":"Update password","buttonPrimary":"Update password"},"FormText":{"requiredFieldError":"This is a required field."},"EmailConfirmationForm":{"title":"Verify your email address","subtitle":"We`ve sent an email to","mainText":"Check your inbox and click on the link we just send you to confirm your email address and activate your account.","buttonSecondary":"Resend email","buttonPrimary":"Close","accountConfirmMessage":"Account confirmed","accountConfirmationEmailSuccessMessage":"Congratulations! Your account at {email} email has been successfully confirmed."},"Notification":{"errorNotification":"Your password update failed due to validation errors. Please check your information and try again.","updatePasswordMessage":"The password has been updated. Now you can log in with the new password.","successPasswordResetEmailNotification":"If there is an account associated with {email} you will receive an email with a link to reset your password.","resendEmailNotification":{"informationText":"This account is not confirmed.","buttonText":"Click here","additionalText":"to resend confirmation email."},"emailConfirmationMessage":"Please check your email for confirmation link.","technicalErrors":{"technicalErrorSendEmail":"A technical error occurred while trying to send the email. Please try again later."}},"Api":{"customerTokenErrorMessage":"Error - Unable to retrieve the user token"}}}')}};import t from"./runtime.js";import*as n from"./591.js";t.C(n);import*as r from"./408.js";t.C(r);import*as o from"./render.js";t.C(o);var a,i=(a=4621,t(t.s=a)).X;export{i as render};
|
|
1
|
+
(function(n,i){try{if(typeof document<"u"){const a=document.createElement("style"),o=i.styleId;for(const t in i.attributes)a.setAttribute(t,i.attributes[t]);a.setAttribute("data-dropin",o),a.appendChild(document.createTextNode(n));const r=document.querySelector('style[data-dropin="sdk"]');if(r)r.after(a);else{const t=document.querySelector('link[rel="stylesheet"], style');t?t.before(a):document.head.append(a)}}}catch(a){console.error("dropin-styles (injectCodeFunction)",a)}})(`.auth-successNotificationForm{display:flex;justify-content:center;align-items:center;flex-direction:column;border-radius:var(--shape-border-radius-2);background:var(--color-neutral-50, #fff);padding:var(--spacing-xbig) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}@media (min-width: 768px){.auth-successNotificationForm{padding:var(--spacing-big) var(--spacing-xbig) var(--spacing-xxbig) var(--spacing-xbig)}}.auth-successNotificationForm.small{padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}.auth-successNotificationForm__title{color:var(--color-neutral-800, #2b2b2b);font:var(--type-headline-2-strong-font);letter-spacing:var(--type-details-caption-1-letter-spacing);margin-bottom:var(--spacing-medium)}.auth-successNotificationForm__content-text{color:var(--color-neutral-800, #2b2b2b);font:var(--type-body-1-default-font);letter-spacing:var(--type-body-1-default-letter-spacing);text-align:center;margin-bottom:var(--spacing-xxbig)}.auth-successNotificationForm__button--top{margin-bottom:var(--spacing-xsmall)}
|
|
2
|
+
.auth-emailConfirmationForm{border-radius:8px;background-color:var(--color-neutral-50, #fff);padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small);text-align:start}@media (min-width: 768px){.auth-emailConfirmationForm{padding:var(--spacing-big) var(--spacing-xbig) var(--spacing-xxbig) var(--spacing-xbig)}}.auth-emailConfirmationForm__title{font:var(--type-headline-2-default-font);letter-spacing:var(--type-display-1-letter-spacing);color:var(--color-neutral-800, #3d3d3d)}.auth-emailConfirmationForm__subtitle{display:block;font:var(--type-details-caption-2-font);letter-spacing:var(--type-button-2-letter-spacing);color:var(--color-neutral-700, #666666)}.auth-emailConfirmationForm__notification{margin-bottom:var(--spacing-medium)}.auth-emailConfirmationForm.small{padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}.auth-emailConfirmationForm.small .auth-emailConfirmationForm-buttons{grid-template-columns:1fr;gap:20px 0}.auth-emailConfirmationForm-buttons{display:grid;grid-template-columns:auto auto;justify-content:space-between}@media (max-width: 768px){.auth-emailConfirmationForm-buttons{gap:20px 0;grid-template-columns:1fr}}.auth-emailConfirmationForm__text{display:block;font-family:var(--type-body-1-default-font);letter-spacing:var(--type-display-1-letter-spacing);color:var(--neutrals-neutral-800);padding:var(--spacing-big) 0}.auth-emailConfirmationForm.small .auth-emailConfirmationForm-buttons{justify-content:center;flex-wrap:wrap}.auth-emailConfirmationForm.small .auth-emailConfirmationForm-buttons{flex-basis:100%;margin-top:var(--spacing-medium)}.auth-emailConfirmationForm.small .auth-emailConfirmationForm-buttons>span{display:none}.auth-emailConfirmationForm-buttons>span{border:1px solid var(--color-brand-500);margin:var(--spacing-small) var(--spacing-xsmall);font:var(--type-button-2-font)}@media (max-width: 768px){.auth-emailConfirmationForm-buttons{justify-content:center;flex-wrap:wrap}.auth-emailConfirmationForm-buttons{flex-basis:100%;margin-top:var(--spacing-medium)}.auth-emailConfirmationForm-buttons>span{display:none}}
|
|
3
|
+
.auth-resetPasswordForm{border-radius:var(--shape-border-radius-2);background-color:var(--color-neutral-50, #fff);padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}@media (min-width: 768px){.auth-resetPasswordForm{padding:var(--spacing-big) var(--spacing-xxbig) var(--spacing-xxbig) var(--spacing-xxbig)}}.auth-resetPasswordForm.small{padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}.auth-resetPasswordForm.small .auth-resetPasswordForm__form__item,.auth-resetPasswordForm.small .auth-resetPasswordForm__title{margin-bottom:var(--spacing-medium)}.auth-resetPasswordForm__form{display:grid;grid-template-columns:1fr}.auth-resetPasswordForm__form__item{margin-bottom:var(--spacing-medium)}.auth-resetPasswordForm__buttons{display:grid;grid-template-columns:1fr;gap:20px 0}.auth-resetPasswordForm.small{grid-template-columns:1fr;gap:20px 0}.auth-resetPasswordForm__notification{margin-bottom:var(--spacing-medium)}.auth-resetPasswordForm__title{margin-bottom:var(--spacing-big)}@media (min-width: 768px){.auth-resetPasswordForm__title{margin-bottom:var(--spacing-xxbig)}}@media (min-width: 600px){.auth-resetPasswordForm__buttons{grid-template-columns:auto auto;justify-content:space-between}}
|
|
4
|
+
.auth-updatePasswordForm{border-radius:var(--shape-border-radius-2);background-color:var(--color-neutral-50, #fff);padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}@media (min-width: 768px){.auth-updatePasswordForm{padding:var(--spacing-big) var(--spacing-xxbig) var(--spacing-xxbig) var(--spacing-xxbig)}}.auth-updatePasswordForm.small{padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}.auth-updatePasswordForm.small .auth-updatePasswordForm__form__item{margin-bottom:var(--spacing-big)}.auth-updatePasswordForm.small .auth-updatePasswordForm__title{margin-bottom:var(--spacing-small)}.auth-updatePasswordForm__title{margin-bottom:var(--spacing-big)}@media (min-width: 768px){.auth-updatePasswordForm__title{margin-bottom:var(--spacing-xxbig)}}.auth-updatePasswordForm__form .auth-updatePasswordForm__form__item{margin-bottom:var(--spacing-big)}@media (min-width: 768px){.auth-updatePasswordForm__form .auth-updatePasswordForm__form__item{margin-bottom:var(--spacing-xxbig)}}.auth-updatePasswordForm__notification{margin-bottom:var(--spacing-medium)}
|
|
5
|
+
.auth-signInForm{border-radius:var(--shape-border-radius-2);background-color:var(--color-neutral-50, #fff);padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}@media (min-width: 768px){.auth-signInForm{padding:var(--spacing-big) var(--spacing-xxbig) var(--spacing-xxbig) var(--spacing-xxbig)}}.auth-signInForm__notification{margin-bottom:var(--spacing-medium)}.auth-signInForm.small{padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}.auth-signInForm.small .auth-signInForm__form__email,.auth-signInForm.small .auth-signInForm__form__password,.auth-signInForm.small .auth-signInForm__title{margin-bottom:var(--spacing-medium)}.auth-signInForm.small .auth-signInForm__form__buttons{grid-template-columns:1fr;gap:20px 0}.auth-signInForm__title{margin-bottom:var(--spacing-big)}@media (min-width: 768px){.auth-signInForm__title{margin-bottom:var(--spacing-xxbig)}}.auth-signInForm__form{display:grid;grid-template-columns:1fr}.auth-signInForm__form__email{margin-bottom:var(--spacing-medium)}.auth-signInForm__form__password{margin-bottom:var(--spacing-big)}.auth-signInForm__form__buttons{display:grid;grid-template-columns:auto auto;justify-content:space-between}@media (max-width: 768px){.auth-signInForm__form__buttons{gap:20px 0;grid-template-columns:1fr}}.auth-signInForm.small .auth-signInForm__form__buttons .auth-signInForm__form__buttons--combine{justify-content:center;flex-wrap:wrap}.auth-signInForm.small .auth-signInForm__form__buttons .auth-signInForm__form__buttons--combine .auth-signInForm__button--signup{flex-basis:100%;margin-top:20px}.auth-signInForm.small .auth-signInForm__form__buttons .auth-signInForm__form__buttons--combine>span{display:none}.auth-signInForm__form__buttons .auth-signInForm__form__buttons--combine{display:flex}.auth-signInForm__form__buttons .auth-signInForm__form__buttons--combine>span{border:var(--shape-border-width-1) solid var(--color-brand-500);margin:13px 10px;font:var(--type-button-2-font)}.auth-signInForm__resend-email-notification button{font:var(--type-button-3-font);color:var(--textColor);display:inline;background-color:transparent;border:none;cursor:pointer;padding:0;margin:0}.auth-signInForm__resend-email-notification button:hover{color:var(--color-brand-700);text-decoration:solid underline var(--color-brand-700);text-underline-offset:6px;color:var(--color-informational-500)}@media (max-width: 768px){.auth-signInForm__form__buttons .auth-signInForm__form__buttons--combine{justify-content:center;flex-wrap:wrap}.auth-signInForm__form__buttons .auth-signInForm__form__buttons--combine .auth-signInForm__button--signup{flex-basis:100%;margin-top:20px}.auth-signInForm__form__buttons .auth-signInForm__form__buttons--combine>span{display:none}}
|
|
6
|
+
.auth-signUpForm{border-radius:var(--shape-border-radius-2);background-color:var(--color-neutral-50, #fff);padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}@media (min-width: 768px){.auth-signUpForm{padding:var(--spacing-big) var(--spacing-xxbig) var(--spacing-xxbig) var(--spacing-xxbig)}}.auth-signUpForm.small{padding:var(--spacing-small) var(--spacing-small) var(--spacing-medium) var(--spacing-small)}.auth-signUpForm.small .auth-signUpForm__title{margin-bottom:var(--spacing-small)}.auth-signUpForm.small .auth-signUpForm__form__field .auth-signUpForm__form__field:nth-child(2),.auth-signUpForm.small .auth-signUpForm__form__field .auth-signUpForm__form__field:nth-child(3){flex-basis:100%}.auth-signUpForm.small .auth-signUpForm__form{grid-template-columns:1fr}.auth-signUpForm__title{margin-bottom:var(--spacing-big)}@media (min-width: 768px){.auth-signUpForm__title{margin-bottom:var(--spacing-xxbig)}}.auth-signUpForm__notification{margin-bottom:var(--spacing-medium)}.auth-signUpForm__form{display:flex;flex-wrap:wrap;flex-direction:row;gap:0 13px}.auth-signUpForm__form__field{margin-bottom:var(--spacing-medium);flex-basis:100%;flex-grow:1;flex-shrink:0}.auth-signUpForm__checkbox{margin-bottom:12px}.auth-signUpForm__automatic-login{margin-top:12px}.auth-signUpForm__form__field:nth-child(2),.auth-signUpForm__form__field:nth-child(3){flex-shrink:1;flex-grow:1;flex-basis:100%}.auth-signUpForm-buttons{flex-basis:100%;display:grid;grid-template-columns:1fr;gap:var(--spacing-medium) 0;justify-content:center;grid-area:buttons}@media (min-width: 768px){.auth-signUpForm-buttons{display:grid;grid-template-columns:auto auto;justify-content:space-between}.auth-signUpForm__form__field:nth-child(2),.auth-signUpForm__form__field:nth-child(3){flex-shrink:1;flex-grow:.5;flex-basis:48%}}
|
|
7
|
+
.auth-button{position:relative}.auth-button__loader-wrapper{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);opacity:0;display:none}.auth-custom-button__loader{width:20px;height:20px;border:5px solid #fff;border-radius:50%;display:inline-block;box-sizing:border-box;position:relative;animation:pulse 1s linear infinite}.auth-button__loader:after{content:"";position:absolute;width:20px;height:20px;border:5px solid #fff;border-radius:50%;display:inline-block;box-sizing:border-box;left:50%;top:50%;transform:translate(-50%,-50%);animation:scaleUp 1s linear infinite}@keyframes scaleUp{0%{transform:translate(-50%,-50%) scale(0)}60%,to{transform:translate(-50%,-50%) scale(1)}}@keyframes pulse{0%,60%,to{transform:scale(1)}80%{transform:scale(1.2)}}.auth-button.enableLoader .auth-button__text{opacity:0}.auth-button.enableLoader .auth-button__loader-wrapper{opacity:1;display:inline-flex}`,{styleId:"Auth"});
|
|
8
|
+
import{jsx as s}from"@dropins/tools/preact-jsx-runtime.js";import{deepmerge as l,Render as u}from"@dropins/tools/lib.js";import{useState as m,useEffect as f}from"@dropins/tools/preact-hooks.js";import{UIProvider as g}from"@dropins/tools/components.js";import{events as p}from"@dropins/tools/event-bus.js";import"@dropins/tools/recaptcha.js";import{c as y}from"./chunks/initialize.js";const h={PasswordValidationMessage:{chartTwoSymbols:"Use characters and numbers or symbols",chartThreeSymbols:"Use characters, numbers and symbols",chartFourSymbols:"Use uppercase characters, lowercase characters, numbers and symbols",messageLengthPassword:"At least {minLength} characters long"},ResetPasswordForm:{title:"Reset your password",buttonPrimary:"Reset password",buttonSecondary:"Back to sign in"},SignInForm:{title:"Sign in",buttonPrimary:"Sign in",buttonSecondary:"Sign up",buttonTertiary:"Forgot password?"},SignUpForm:{title:"Sign up",buttonPrimary:"Create account",buttonSecondary:"Already a member? Sign in",privacyPolicyDefaultText:"I’ve read and accept the Terms of Use and Privacy Policy.",subscribedDefaultText:"Subscribe to our newsletter and be the first to know about new arrivals, sales and exclusive offers.",keepMeLoggedText:"Keep me logged in after account creation",failedCreateCustomerAddress:"Failed to create customer addresses:"},UpdatePasswordForm:{title:"Update password",buttonPrimary:"Update password"},FormText:{requiredFieldError:"This is a required field."},EmailConfirmationForm:{title:"Verify your email address",subtitle:"We`ve sent an email to",mainText:"Check your inbox and click on the link we just send you to confirm your email address and activate your account.",buttonSecondary:"Resend email",buttonPrimary:"Close",accountConfirmMessage:"Account confirmed",accountConfirmationEmailSuccessMessage:"Congratulations! Your account at {email} email has been successfully confirmed."},Notification:{errorNotification:"Your password update failed due to validation errors. Please check your information and try again.",updatePasswordMessage:"The password has been updated.",updatePasswordActionMessage:"Sign in",successPasswordResetEmailNotification:"If there is an account associated with {email} you will receive an email with a link to reset your password.",resendEmailNotification:{informationText:"This account is not confirmed.",buttonText:"Resend confirmation email"},emailConfirmationMessage:"Please check your email for confirmation link.",technicalErrors:{technicalErrorSendEmail:"A technical error occurred while trying to send the email. Please try again later."}},SuccessNotification:{headingText:"Welcome!",messageText:"We are glad to see you!",primaryButtonText:"Continue shopping",secondaryButtonText:"Logout"},Api:{customerTokenErrorMessage:"Unable to log in. Please try again later or contact support if the issue persists."},InputPassword:{placeholder:"Password",floatingLabel:"Password *"}},b={Auth:h},w={default:b},P=({children:i})=>{var o,r;const[e,n]=m("en_US"),c=(r=(o=y)==null?void 0:o.getConfig())==null?void 0:r.langDefinitions;f(()=>{const t=p.on("locale",a=>{a!==e&&n(a)},{eager:!0});return()=>{t==null||t.off()}},[e]);const d=l(w,c??{});return s(g,{lang:e,langDefinitions:d,children:i})},F=new u(s(P,{}));export{F as render};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export interface confirmEmailResponse {
|
|
2
|
+
data: {
|
|
3
|
+
confirmEmail: {
|
|
4
|
+
customer: {
|
|
5
|
+
email: string;
|
|
6
|
+
};
|
|
7
|
+
};
|
|
8
|
+
};
|
|
9
|
+
errors?: {
|
|
10
|
+
message: string;
|
|
11
|
+
}[];
|
|
12
|
+
}
|
|
13
|
+
export interface confirmEmailProps {
|
|
14
|
+
customerEmail: string;
|
|
15
|
+
customerConfirmationKey: string;
|
|
16
|
+
}
|
|
17
|
+
//# sourceMappingURL=confirmEmail.types.d.ts.map
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export interface Customer {
|
|
2
|
+
firstname: string;
|
|
3
|
+
lastname: string;
|
|
4
|
+
email: string;
|
|
5
|
+
is_subscribed: boolean;
|
|
6
|
+
custom_attributes?: Record<string, string>[];
|
|
7
|
+
}
|
|
8
|
+
interface CreateCustomerResponse {
|
|
9
|
+
customer: Customer;
|
|
10
|
+
}
|
|
11
|
+
interface DataCreateCustomerV2 {
|
|
12
|
+
createCustomer: CreateCustomerResponse;
|
|
13
|
+
}
|
|
14
|
+
interface DataCreateCustomer {
|
|
15
|
+
createCustomer: CreateCustomerResponse;
|
|
16
|
+
}
|
|
17
|
+
export interface CreateCustomerDataResponse {
|
|
18
|
+
data: DataCreateCustomerV2 | DataCreateCustomer | null;
|
|
19
|
+
errors?: {
|
|
20
|
+
message: string;
|
|
21
|
+
}[];
|
|
22
|
+
}
|
|
23
|
+
export {};
|
|
24
|
+
//# sourceMappingURL=createCustomer.types.d.ts.map
|