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gBAAoB,MAAO,CAAEP,UAAW,aACpC,gBAAoB,IAAa,CAAEmJ,IAAK1F,EAAS9E,KAAM,eAC3D,gBAAoB,MAAO,CAAEqB,UAAW,aACpC,gBAAoB,IAAa,CAAEmJ,IAAK1F,EAAS9E,KAAM,cAC3D,gBAAoB,MAAO,CAAEqB,UAAW,aACpC,gBAAoB,IAAa,CAAEmJ,IAAK1F,EAAS9E,KAAM,gBAAiB4B,KAAM,WAAYyL,SAAUjM,EAAM6L,SAAW,IAAMK,KAAKC,MAAsB,IAAhBD,KAAKE,aAC/I,gBAAoB,MAAO,CAAEnM,UAAW,cACpC,gBAAoB,IAAQ,CAAEO,KAAM,SAAUqJ,SAAUb,EAAYc,IAAK,CAAC,cAAe,cAAe,eACpG3J,EAAE,gCACF6I,GAAc,gBAAoB,IAAS,CAAEqD,QAAQ,UAtB9D,gBAAoB,WAAgB,KAsB0C,G,kCC5GtF,MAAMC,EAAoBhJ,SACtB,IAAIZ,SAAQ,CAACC,EAAS4J,UACQ,IAAtB9H,OAAOW,WAIlBX,OAAOW,WAAWoH,OAAM,WACpB/H,OAAOW,WAAWqH,QAAQhI,OAAOiI,0BAA2B,CAAEC,OAAQ,KAAM5M,MAAK,SAAU6M,GACnFA,EACAjK,EAAQiK,GAGRL,GAER,GACJ,IAZIA,GAYF,G","sources":["webpack:///./node_modules/final-form-focus/dist/final-form-focus.es.js","webpack:///./assets/src/components/account/AddressSuggestions.tsx","webpack:///./node_modules/p-debounce/index.js","webpack:///./assets/src/components/account/RegisterForm.tsx","webpack:///./assets/src/components/account/RegisterPage.tsx","webpack:///./assets/src/components/account/RegisterPageLoader.tsx","webpack:///./assets/src/components/confirm/ConfirmSummary.tsx","webpack:///./assets/src/components/confirm/ConfirmLoader.tsx","webpack:///./assets/src/components/newsletter/NewsletterFormApp.tsx","webpack:///./assets/src/utils/recaptchaUtils.ts"],"sourcesContent":["import { getIn } from 'final-form';\n\n// \n\n/**\n * Predicate to identify inputs that can have focus() called on them\n */\nvar isFocusableInput = function isFocusableInput(wtf) {\n return !!(wtf && typeof wtf.focus === 'function');\n};\n\n// \n/**\n * Gets all the inputs inside all forms on the page\n */\n\nvar getAllInputs = function getAllInputs() {\n if (typeof document === 'undefined') {\n return [];\n }\n\n return Array.prototype.slice.call(document.forms).reduce(function (accumulator, form) {\n return accumulator.concat(Array.prototype.slice.call(form).filter(isFocusableInput));\n }, []);\n};\n\n// \n/**\n * Finds the input by looking if the name attribute path is existing in the errors object\n */\n\nvar findInput = function findInput(inputs, errors) {\n return inputs.find(function (input) {\n return input.name && getIn(errors, input.name);\n });\n};\n\n// \n\nvar noop = function noop() {};\n\nvar createDecorator = function createDecorator(getInputs, findInput$$1) {\n return function (form) {\n var focusOnFirstError = function focusOnFirstError(errors) {\n if (!getInputs) {\n getInputs = getAllInputs;\n }\n\n if (!findInput$$1) {\n findInput$$1 = findInput;\n }\n\n var firstInput = findInput$$1(getInputs(), errors);\n\n if (firstInput) {\n firstInput.focus();\n }\n }; // Save original submit function\n\n\n var originalSubmit = form.submit; // Subscribe to errors, and keep a local copy of them\n\n var state = {};\n var unsubscribe = form.subscribe(function (nextState) {\n state = nextState;\n }, {\n errors: true,\n submitErrors: true\n }); // What to do after submit\n\n var afterSubmit = function afterSubmit() {\n var _state = state,\n errors = _state.errors,\n submitErrors = _state.submitErrors;\n\n if (errors && Object.keys(errors).length) {\n focusOnFirstError(errors);\n } else if (submitErrors && Object.keys(submitErrors).length) {\n focusOnFirstError(submitErrors);\n }\n }; // Rewrite submit function\n\n\n form.submit = function () {\n var result = originalSubmit.call(form);\n\n if (result && typeof result.then === 'function') {\n // async\n result.then(afterSubmit, noop);\n } else {\n // sync\n afterSubmit();\n }\n\n return result;\n };\n\n return function () {\n unsubscribe();\n form.submit = originalSubmit;\n };\n };\n};\n\n// \n/**\n * Generates a function to get all the inputs in a form with the specified name\n */\n\nvar getFormInputs = function getFormInputs(name) {\n return function () {\n if (typeof document === 'undefined') {\n return [];\n } // $FlowFixMe\n\n\n var form = document.forms[name];\n return form && form.length ? Array.prototype.slice.call(form).filter(isFocusableInput) : []; // cast cheat to get from HTMLFormElement children to FocusableInput\n };\n};\n\n//\n\nexport default createDecorator;\nexport { getFormInputs };\n","import Address from '@components/order/Address';\nimport ModalDialog from '@ui/modal/ModalDialog';\nimport RadioGroup from '@ui/radioGroup/RadioGroup';\nimport RadioGroupItem from '@ui/radioGroup/RadioGroupItem';\nimport React from 'react';\nimport { withTranslation } from 'react-i18next';\nconst AddressSuggestions = (props) => {\n const { t } = props;\n const printOptions = () => {\n var _a, _b;\n let result = [];\n if (((_a = props.addressValidation) === null || _a === void 0 ? void 0 : _a.addressSuggestions.length) > 0) {\n result = result.concat(((_b = props.addressValidation) === null || _b === void 0 ? void 0 : _b.addressSuggestions) || []).map((data, i) => (React.createElement(RadioGroupItem, { key: i, content: React.createElement(\"div\", { className: \"optionbox__item__content\" },\n React.createElement(\"div\", { className: \"option-address\" },\n React.createElement(\"div\", { className: \"option-address__detail\" },\n React.createElement(Address, { address: data, noname: true, nophone: true, monoline: true, nocountry: true })))), id: i })));\n }\n result = result.concat(React.createElement(RadioGroupItem, { key: \"confirm\", parentClass: \"confirm-not-valid-address\", content: React.createElement(\"div\", { className: \"optionbox__item__content\" },\n React.createElement(\"div\", { className: \"option-address\" },\n React.createElement(\"h3\", null, t('checkout.shipping.keeppreviousaddress')),\n React.createElement(\"div\", { className: \"option-address__detail\" },\n React.createElement(Address, { address: props.formProps.values, monoline: true, noname: true, nophone: true, nocountry: true })))), id: 'confirm' }));\n return result;\n };\n return (React.createElement(ModalDialog, { className: \"address-doctor-modal\", title: t('checkout.shipping.cannotfindaddress.title'), subtitle: t('checkout.shipping.cannotfindaddress.subtitle'), isOpen: true, onRequestClose: () => props.closeAddressSuggestionModal() },\n React.createElement(React.Fragment, null,\n React.createElement(\"div\", { className: \"suggested-addresses-wrapper\" },\n React.createElement(\"div\", { className: \"suggested-addresses\" },\n React.createElement(\"h3\", null,\n t('checkout.shipping.cannotfindaddress.suggested'),\n \":\"),\n React.createElement(RadioGroup, { type: \"horizontal-more-items\", labelId: \"addressbooklabel\", id: \"addressbookid\", setSelected: (id) => {\n props.confirmAddressSuggestion(id);\n } }, printOptions()))))));\n};\nexport default withTranslation()(AddressSuggestions);\n","const pDebounce = (fn, wait, options = {}) => {\n\tif (!Number.isFinite(wait)) {\n\t\tthrow new TypeError('Expected `wait` to be a finite number');\n\t}\n\n\tlet leadingValue;\n\tlet timeout;\n\tlet resolveList = [];\n\n\treturn function (...arguments_) {\n\t\treturn new Promise(resolve => {\n\t\t\tconst shouldCallNow = options.before && !timeout;\n\n\t\t\tclearTimeout(timeout);\n\n\t\t\ttimeout = setTimeout(() => {\n\t\t\t\ttimeout = null;\n\n\t\t\t\tconst result = options.before ? leadingValue : fn.apply(this, arguments_);\n\n\t\t\t\tfor (resolve of resolveList) {\n\t\t\t\t\tresolve(result);\n\t\t\t\t}\n\n\t\t\t\tresolveList = [];\n\t\t\t}, wait);\n\n\t\t\tif (shouldCallNow) {\n\t\t\t\tleadingValue = fn.apply(this, arguments_);\n\t\t\t\tresolve(leadingValue);\n\t\t\t} else {\n\t\t\t\tresolveList.push(resolve);\n\t\t\t}\n\t\t});\n\t};\n};\n\npDebounce.promise = function_ => {\n\tlet currentPromise;\n\n\treturn async function (...arguments_) {\n\t\tif (currentPromise) {\n\t\t\treturn currentPromise;\n\t\t}\n\n\t\ttry {\n\t\t\tcurrentPromise = function_.apply(this, arguments_);\n\t\t\treturn await currentPromise;\n\t\t} finally {\n\t\t\tcurrentPromise = undefined;\n\t\t}\n\t};\n};\n\nexport default pDebounce;\n","import ErrorBox from '@components/common/ErrorBox';\nimport Button from '@ui/button/Button';\nimport DwFormField from '@ui/formfield/DwFormField';\nimport Loader from '../../ui/loading/Loading';\nimport api from '@utils/api';\nimport formutils from '@utils/formutils';\nimport createDecorator from 'final-form-focus';\nimport React, { useEffect, useRef, useState, useMemo } from 'react';\nimport { Form } from 'react-final-form';\nimport { withTranslation } from 'react-i18next';\nimport Icon from '../common/Icon';\nimport { Swiper, SwiperSlide } from 'swiper/react';\nimport { Pagination } from 'swiper';\nimport AddressForm from '@components/checkout/AddressForm';\nimport AddressSuggestions from './AddressSuggestions';\nimport pDebounce from 'p-debounce';\nimport GoogleMapScript from '@components/storelocator/scripts/GoogleMapScript';\nimport { getRecaptchaToken } from '@utils/recaptchaUtils';\nconst focusOnError = createDecorator(); // must be outside the component\nconst RegisterForm = (props) => {\n const { t } = props;\n const [formdef, setFormdef] = useState();\n const [initialValues, setInitialValues] = useState();\n const [errors, setErrors] = useState([]);\n const [isSubmitting, setIsSubmitting] = useState(false);\n const registerFormRef = useRef(null);\n const oldValues = useRef();\n const [addressValidation, setAddressValidation] = useState({ addressinvalid: false, addressSuggestions: [] });\n const params = new URLSearchParams(window.location.search);\n useEffect(() => {\n let val = {};\n api.getForm('profile', val).then((data) => {\n props.email && (val.email = props.email);\n setInitialValues(val);\n setFormdef(data);\n oldValues.current = val;\n });\n if (params.get('orderNumber')) {\n api.getOrderDetail(params.get('orderNumber'), params.get('token')).then((data) => { });\n }\n }, []);\n const closeAddressSuggestionModal = () => {\n setAddressValidation({ addressinvalid: false, addressSuggestions: [] });\n };\n const confirmAddressSuggestion = (id, form, values) => {\n if (id === 'confirm') {\n form.mutators.global({\n validated: true,\n validatedHash: values.address1 + values.city + values.postalCode + values.stateCode,\n });\n }\n else {\n let address = addressValidation.addressSuggestions[id];\n address.validated = true;\n address.validatedHash = address.address1 + address.city + address.postalCode + address.stateCode;\n form.mutators.global(address);\n }\n // handleSaveAddress(values) // dispatchEvent(new Event('submit'));\n setAddressValidation({ addressinvalid: false, addressSuggestions: [] });\n };\n const onSubmit = async (values, form) => {\n setErrors([]);\n setIsSubmitting(true);\n let errors = await validate(values);\n if (errors && Object.keys(errors).length > 0) {\n return errors;\n }\n if (values.validated) {\n let validatedHash = values.address1 + values.city + values.postalCode + values.stateCode;\n if (values.validatedHash != validatedHash) {\n values.validated = false;\n }\n else {\n return sendRegistration(values);\n }\n }\n // ADDRESS DOCTOR VALIDATION AND AFTER SUBMIT\n setErrors([]);\n try {\n let addressDoctorOjbect = {\n address1: values.address1,\n addressId: values.addressId,\n city: values.city,\n countryCode: values.country,\n postalCode: values.postalCode,\n stateCode: values.stateCode,\n };\n await api.addressDoctorValidation(Object.assign(Object.assign({}, addressDoctorOjbect), { shouldValidate: true })).then((data) => {\n if (!data.success && data.suggestionModal && data.suggestions.length > 0) {\n console.log('Mostrare modale con seguenti suggestions: ', data.suggestions);\n setAddressValidation({ addressinvalid: true, addressSuggestions: data.suggestions });\n setIsSubmitting(false);\n }\n else if (!data.success && !data.suggestionModal && data.suggestion) {\n console.log('Aggiornare form con indirizzo corretto -> ', data.suggestion);\n form.mutators.global(Object.assign(Object.assign({}, values), Object.assign(Object.assign({}, data.suggestion), { validated: true })));\n sendRegistration(Object.assign(Object.assign({}, values), Object.assign(Object.assign({}, data.suggestion), { validated: true })));\n }\n else {\n console.log('Indirizzo corretto');\n sendRegistration(values);\n }\n });\n }\n catch (e) {\n console.error('error:' + e);\n sendRegistration(values);\n }\n finally {\n return;\n }\n };\n const sendRegistration = async (values) => {\n let googleRecaptchaToken;\n if (typeof window.grecaptcha !== 'undefined') {\n googleRecaptchaToken = await getRecaptchaToken();\n }\n if (params.get('destination')) {\n values.destination = params.get('destination');\n }\n return api\n .register(values, formdef, googleRecaptchaToken, props.registerurl)\n .then((data) => {\n if (data.error) {\n setIsSubmitting(false);\n if (data.error.length > 0) {\n setErrors([data.error]);\n }\n else {\n setErrors([data.message]);\n }\n }\n if (!formutils.checkValidationAfterSubmit(data, errors)) {\n return errors;\n }\n if (data.success) {\n window.location.replace(data.redirectUrl);\n }\n })\n .catch((e) => { setErrors([e]); setIsSubmitting(false); });\n };\n const validate = async (values) => {\n const validateErrors = {};\n let data = await api.searchMail(values.email);\n if (data.success) {\n validateErrors.email = t('common.error.email.exist');\n }\n if (values.password) {\n if (/^\\s|\\s$/.test(values.password)) {\n validateErrors.password = t('common.error.password.space');\n }\n }\n if (!values.addressId) {\n validateErrors.addressId = t('required.field');\n }\n let backValidation = await formutils.validateForm(values, formdef, 'profile');\n let totalValidation = Object.assign(Object.assign({}, backValidation), validateErrors);\n return totalValidation;\n };\n const memoDebouncedValidate = useMemo(() => {\n return pDebounce(validate, 150);\n }, [formdef]);\n const renderRegisterValueProposition = () => {\n const { t } = props;\n let valuesToRender = [{ name: \"new\", icon: \"label\" }, { name: \"order\", icon: \"history\" }, { name: \"quick\", icon: \"bag\" }, { name: \"wishlist\", icon: \"wishlist-empty\" }];\n return (React.createElement(Swiper, { slidesPerView: 1, modules: [Pagination], className: \"value-proposition-wrapper\", pagination: { clickable: true } }, valuesToRender.map((value, i) => (React.createElement(SwiperSlide, { key: i, className: \"value-proposition--item\" },\n React.createElement(Icon, { name: value.icon, large: \"l\" }),\n React.createElement(\"p\", { className: 'value-proposition--item-title' }, t(`account.valueproposition.${value.name}.title`)),\n React.createElement(\"p\", { className: 'value-proposition--item-subtitle' },\n t(`account.valueproposition.${value.name}.subtitle`),\n React.createElement(\"br\", null),\n t('required.fields')))))));\n };\n const addressFieldsAutocomplete = (values, mutators) => {\n if (oldValues.current.lastname === values.lastName && oldValues.current.lastname !== values.lastname) {\n mutators.setValue('lastName', values.lastname);\n }\n if (oldValues.current.firstname === values.firstName && oldValues.current.firstname !== values.firstname) {\n mutators.setValue('firstName', values.firstname);\n }\n if (oldValues.current.phone === values.addressPhone && oldValues.current.phone !== values.phone) {\n mutators.setValue('addressPhone', values.phone);\n }\n oldValues.current = values;\n };\n if (!formdef) {\n return React.createElement(React.Fragment, null);\n }\n return (React.createElement(GoogleMapScript, null,\n React.createElement(\"div\", { className: \"register-container\" },\n React.createElement(\"h1\", { className: \"register-title\" }, t('account.signup.title')),\n React.createElement(\"p\", { className: \"register-subtitle\" },\n t('account.signup.description'),\n React.createElement(\"br\", null),\n React.createElement(\"div\", { className: \"form-helper--small\" }, t('required.fields'))),\n renderRegisterValueProposition(),\n React.createElement(\"p\", { className: \"section-title\" }, t('account.registration.createaccount.title')),\n React.createElement(Form, { onSubmit: onSubmit, initialValues: initialValues, validate: memoDebouncedValidate, mutators: {\n global: formutils.globalMutator,\n setValue: ([key, value], state, { changeValue }) => {\n changeValue(state, key, () => value);\n },\n }, decorators: [focusOnError], render: ({ handleSubmit, form, submitting, pristine, values }) => {\n return (React.createElement(\"form\", { ref: registerFormRef, onSubmit: (e) => {\n handleSubmit(e);\n } },\n React.createElement(\"div\", { className: \"field-row\" },\n React.createElement(DwFormField, { def: formdef, name: \"email\", type: 'email', autocomplete: \"email\" }),\n React.createElement(DwFormField, { def: formdef, name: \"password\", type: \"password\", showPassword: true, autocomplete: \"new-password\" })),\n React.createElement(\"div\", { className: \"field-row\" },\n React.createElement(DwFormField, { def: formdef, name: \"firstname\", autocomplete: \"given-name\", onChange: (e) => {\n addressFieldsAutocomplete(Object.assign(Object.assign({}, values), { firstname: e.target.value }), form.mutators);\n } }),\n React.createElement(DwFormField, { def: formdef, name: \"lastname\", autocomplete: \"family-name\", onChange: (e) => {\n addressFieldsAutocomplete(Object.assign(Object.assign({}, values), { lastname: e.target.value }), form.mutators);\n } })),\n React.createElement(\"div\", { className: \"field-row\" },\n React.createElement(DwFormField, { def: formdef, name: \"phone\", onChange: (e) => {\n addressFieldsAutocomplete(Object.assign(Object.assign({}, values), { phone: e.target.value }), form.mutators);\n } })),\n React.createElement(\"p\", { className: \"section-title\" }, t('account.registration.primaryshipping.title')),\n React.createElement(AddressForm, { formdef: formdef, values: values, mutator: form.mutators.global, autocomplete: true, isRegisterForm: true }),\n React.createElement(\"p\", { className: \"section-title\" }, t('account.mktgprofile')),\n React.createElement(\"div\", { className: \"box-check\" },\n React.createElement(DwFormField, { def: formdef, type: \"checkbox\", name: \"marketingPref\" })),\n React.createElement(Button, { type: \"submit\", disabled: isSubmitting || submitting, cls: ['cta-primary'] }, t('account.button.create')),\n React.createElement(ErrorBox, { errors: errors }),\n isSubmitting && React.createElement(Loader, null),\n (addressValidation === null || addressValidation === void 0 ? void 0 : addressValidation.addressinvalid) && (React.createElement(AddressSuggestions, { addressValidation: addressValidation, closeAddressSuggestionModal: closeAddressSuggestionModal, confirmAddressSuggestion: (id) => confirmAddressSuggestion(id, form, values), formProps: { form, submitting, pristine, values } }))));\n } }))));\n};\nexport default withTranslation()(RegisterForm);\n","import React from 'react';\nimport { withTranslation } from 'react-i18next';\nimport RegisterForm from '@components/account/RegisterForm';\nimport Icon from '../common/Icon';\nimport ContactInfo from '@components/checkout/ContactInfo';\nconst renderRegisterValueProposition = (props) => {\n const { t } = props;\n let valuesToRender = [{ name: \"new\", icon: \"label\" }, { name: \"order\", icon: \"history\" }, { name: \"quick\", icon: \"bag\" }, { name: \"wishlist\", icon: \"wishlist-empty\" }];\n return (React.createElement(React.Fragment, null,\n React.createElement(\"div\", { className: \"value-proposition-wrapper\" }, valuesToRender.map((value) => (React.createElement(\"div\", { key: value.name, className: \"value-proposition--item\" },\n React.createElement(Icon, { name: value.icon, large: \"m\" }),\n React.createElement(\"p\", { className: 'value-proposition--item-title' }, t(`account.valueproposition.${value.name}.title`)),\n React.createElement(\"p\", { className: 'value-proposition--item-subtitle' }, t(`account.valueproposition.${value.name}.subtitle`)))))),\n React.createElement(ContactInfo, { contactus: props.contactusurl, onlyContactBox: true })));\n};\nconst RegisterPage = (props) => {\n return (React.createElement(React.Fragment, null,\n React.createElement(\"div\", { className: \"register-side\" },\n React.createElement(RegisterForm, Object.assign({}, props))),\n React.createElement(\"div\", { className: \"right-side\" }, renderRegisterValueProposition(props))));\n};\nexport default withTranslation()(RegisterPage);\n","import React from 'react';\nimport { Provider } from 'react-redux';\nimport { configureAccountStore } from '@state';\nimport RegisterPage from './RegisterPage';\nconst store = configureAccountStore();\nconst RegisterPageLoader = (props) => {\n return (React.createElement(Provider, { store: store },\n React.createElement(RegisterPage, Object.assign({}, props)),\n ' '));\n};\nexport default RegisterPageLoader;\n","import React from 'react';\nimport OrderSummary from '../checkout/OrderSummary';\nimport SFMCUtils from 'src/scripts/utils/SFMCUtils';\nconst ConfirmSummary = (props) => {\n const bagFromPdict = JSON.parse(props.order);\n const order = bagFromPdict;\n order.items = bagFromPdict.items.items;\n console.log(order);\n SFMCUtils.pushThankyou(order.items);\n return (React.createElement(React.Fragment, null, order && React.createElement(OrderSummary, { bag: order, pageSelector: \"thankyou\", isthankyou: true })));\n};\nexport default ConfirmSummary;\n","import ConfirmSummary from '@components/confirm/ConfirmSummary';\nimport { configureCheckoutStore } from '@state';\nimport React from 'react';\nimport { Provider } from 'react-redux';\nconst store = configureCheckoutStore();\nconst Confirm = (props) => {\n return (React.createElement(Provider, { store: store },\n React.createElement(ConfirmSummary, Object.assign({}, props))));\n};\nexport default Confirm;\n","import React, { useState, useEffect } from 'react';\nimport customEventBus from '../../scripts/libs/eventBus';\nimport CustomMessages from '../../scripts/constants/customMessages';\nimport { withTranslation } from 'react-i18next';\nimport api from '@utils/api';\nimport formutils from '@utils/formutils';\nimport { Form } from 'react-final-form';\nimport DwFormField from '@ui/formfield/DwFormField';\nimport Button from '@ui/button/Button';\nimport classNames from 'classnames';\nimport Loading from '@ui/loading/Loading';\nimport { getRecaptchaToken } from '@utils/recaptchaUtils';\nconst NewsletterFormApp = (props) => {\n const { t } = props;\n const [formdef, setFormdef] = useState();\n const [email, setEmail] = useState();\n const [errors, setErrors] = useState([]);\n const [initialValues, setInitialValues] = useState();\n const [isSubmitting, setIsSubmitting] = useState(false);\n const [feedbackMessage, setFeedbackMessage] = useState(null);\n useEffect(() => {\n api.getProfile().then(profile => {\n let val = {};\n api.getForm('profileNewsletterSubscription', val).then(profileForm => {\n //console.log(profileForm);\n setFormdef(profileForm);\n });\n });\n }, []);\n const validate = async (values) => {\n let backValidator = await formutils.validateForm(values, formdef, 'profileNewsletterSubscription');\n const frontValidator = {};\n const fields = ['marketingPref'];\n fields.forEach(field => {\n if (!values[field]) {\n frontValidator[field] = t('required.field');\n }\n });\n let errors = Object.assign(Object.assign({}, backValidator), frontValidator);\n return errors;\n };\n const onSubmit = async (values) => {\n setErrors([]);\n let errors = await validate(values);\n if (errors && Object.keys(errors).length > 0) {\n setIsSubmitting(false);\n return errors;\n }\n let gToken = '';\n try {\n gToken = await getRecaptchaToken();\n }\n catch (e) {\n // ERRORE GENERICO\n return;\n }\n return api\n .newsletterSubmit(values, formdef, gToken, props.campaign)\n .then((data) => {\n if (data) {\n if (data.success) {\n customEventBus.emit(CustomMessages.DATALAYER.NEWSLETTER.signup, {});\n }\n if (data.message) {\n setFeedbackMessage(data.message);\n setTimeout(() => {\n window.micromodalInstance.forceClose('modal-newsletter');\n }, 3000);\n }\n if (data.recaptchError) {\n console.log(\"CAPTCHA ERROR\");\n return;\n }\n }\n })\n .catch((e) => {\n setIsSubmitting(false);\n });\n };\n customEventBus.on(CustomMessages.NEWSLETTER.open, (data) => {\n if (props.context === 'modal') {\n setEmail(data.email);\n setFeedbackMessage(null);\n }\n });\n if (!formdef) {\n return React.createElement(React.Fragment, null);\n }\n if (feedbackMessage) {\n return (React.createElement(\"div\", { className: classNames('newsletter-form-container', { center: props.context !== 'modal' }) },\n props.context !== 'modal' && props.title && props.title !== '' && (React.createElement(\"h2\", { className: \"title-text\" }, props.title)),\n React.createElement(\"p\", { className: 'feedback-text' }, feedbackMessage)));\n }\n return (React.createElement(\"div\", { className: classNames('newsletter-form-container', { center: props.context !== 'modal' }) },\n props.context !== 'modal' && props.title && props.title !== '' && (React.createElement(\"h2\", { className: \"title-text\" }, props.title)),\n React.createElement(\"div\", { className: \"description-text\" }, props.description && props.description !== '' ? props.description : t('account.newsletter.subtitle')),\n React.createElement(Form, { onSubmit: onSubmit, initialValues: { email: email }, validate: validate, render: ({ handleSubmit, form, submitting, pristine, values }) => (React.createElement(\"form\", { onSubmit: handleSubmit, className: \"newsletter-form\" },\n React.createElement(\"div\", { className: 'field-row' },\n React.createElement(DwFormField, { def: formdef, name: \"email\", type: \"email\" })),\n React.createElement(\"div\", { className: 'field-row' },\n React.createElement(DwFormField, { def: formdef, name: \"firstname\" })),\n React.createElement(\"div\", { className: 'field-row' },\n React.createElement(DwFormField, { def: formdef, name: \"lastname\" })),\n React.createElement(\"div\", { className: 'field-row' },\n React.createElement(DwFormField, { def: formdef, name: \"marketingPref\", type: \"checkbox\", idSuffix: props.campaign + '_' + Math.floor(Math.random() * 10000000) })),\n React.createElement(\"div\", { className: \"submit-row\" },\n React.createElement(Button, { type: \"submit\", disabled: submitting, cls: ['cta-primary', 'btn-profile', 'cta-submit'] },\n t('globals.newsletter.subscribe'),\n submitting && React.createElement(Loading, { inline: true }))))) })));\n};\nexport default withTranslation()(NewsletterFormApp);\n","export const getRecaptchaToken = async () => {\n return new Promise((resolve, reject) => {\n if (typeof window.grecaptcha === 'undefined') {\n reject();\n return;\n }\n window.grecaptcha.ready(function () {\n window.grecaptcha.execute(window.googleRecaptchaClientSide, { action: '' }).then(function (token) {\n if (token) {\n resolve(token);\n }\n else {\n reject();\n }\n });\n });\n });\n};\n"],"names":["isFocusableInput","wtf","focus","getAllInputs","document","Array","prototype","slice","call","forms","reduce","accumulator","form","concat","filter","findInput","inputs","errors","find","input","name","noop","getInputs","findInput$$1","focusOnFirstError","firstInput","originalSubmit","submit","state","unsubscribe","subscribe","nextState","submitErrors","afterSubmit","_state","Object","keys","length","result","then","props","className","title","t","subtitle","isOpen","onRequestClose","closeAddressSuggestionModal","type","labelId","id","setSelected","confirmAddressSuggestion","_a","_b","addressValidation","addressSuggestions","map","data","i","key","content","address","noname","nophone","monoline","nocountry","parentClass","formProps","values","printOptions","pDebounce","fn","wait","options","Number","isFinite","TypeError","leadingValue","timeout","resolveList","arguments_","Promise","resolve","shouldCallNow","before","clearTimeout","setTimeout","apply","this","push","promise","function_","currentPromise","async","undefined","focusOnError","withTranslation","formdef","setFormdef","useState","initialValues","setInitialValues","setErrors","isSubmitting","setIsSubmitting","registerFormRef","useRef","oldValues","setAddressValidation","addressinvalid","params","URLSearchParams","window","location","search","useEffect","val","api","email","current","get","sendRegistration","googleRecaptchaToken","grecaptcha","destination","registerurl","error","message","formutils","success","replace","redirectUrl","catch","e","validate","validateErrors","password","test","addressId","backValidation","assign","memoDebouncedValidate","useMemo","addressFieldsAutocomplete","mutators","lastname","lastName","setValue","firstname","firstName","phone","addressPhone","GoogleMapScript","slidesPerView","modules","pagination","clickable","icon","value","Icon","large","renderRegisterValueProposition","onSubmit","validated","validatedHash","address1","city","postalCode","stateCode","addressDoctorOjbect","countryCode","country","shouldValidate","suggestionModal","suggestions","console","log","suggestion","global","changeValue","decorators","render","handleSubmit","submitting","pristine","ref","DwFormField","def","autocomplete","showPassword","onChange","target","AddressForm","mutator","isRegisterForm","Button","disabled","cls","ErrorBox","AddressSuggestions","ContactInfo","contactus","contactusurl","onlyContactBox","store","bagFromPdict","JSON","parse","order","items","SFMCUtils","OrderSummary","bag","pageSelector","isthankyou","setEmail","feedbackMessage","setFeedbackMessage","profile","profileForm","backValidator","frontValidator","forEach","field","context","center","description","gToken","campaign","micromodalInstance","forceClose","recaptchError","idSuffix","Math","floor","random","inline","getRecaptchaToken","reject","ready","execute","googleRecaptchaClientSide","action","token"],"sourceRoot":""}