PageSourceSearch

https://www.bizbash.com/assets/index.es-CZ6BWE4M.js

js bizbash.com collected 2026-09-24 15:20:31 UTC 129,007 bytes, 5 lines download raw bytes

1import{o as e}from"./rolldown-runtime-C0FnF6B9.js";import{a as t}from"./vendor-html-parser-DOJ8foyv.js";import{i as n,t as r}from"./vendor-react-BREUBCH4.js";import{Vt as i,ht as a,tt as o}from"./errorBoundary-CheDi6wM.js";var s={CONTENT_PAGE:`Newsletter Subscription from Content Page`,CONTENT_PAGE_RSB:`Newsletter Subscription from Content Page RSB`,HOME_PAGE:`Newsletter Subscription from Home page`,SITE_REGISTRATION:`Newsletter Subscription after Site Registration`,MENU_SECTIONS:`Newsletter subscription from Menu sections`,FOOTER:`Newsletter subscription from Footer`,SUBSCRIPTION_PAGE:`Newsletter subscription from the subscription page`,SUBSCRIPTION_MODULE:`Newsletter subscription from subscription module`},c={HEADER_MEGA_MENU:`Site Registration`,UNPAID_GATED_IIRIS:`Unpaid Gated with IIRIS content via Reg`,UNPAID_GATED_IIRIS_EXTERNAL_FORM:`Unpaid Gated with IIRIS and External form content via Reg`,PAID_GATED:`Site Registration for Paid Content Access`,PAID_PRODUCT_TAXONOMY:`Paid Product via Reg`},l=(e={})=>{let{isGatedContent:t,isGatedAsPaid:n,isExternalFormFlow:r,isPaidProductTaxonomy:i}=e;return n&&!i?c.PAID_GATED:t&&r?c.UNPAID_GATED_IIRIS_EXTERNAL_FORM:t?c.UNPAID_GATED_IIRIS:i?c.PAID_PRODUCT_TAXONOMY:c.HEADER_MEGA_MENU},u={NEWSLETTER_SUBSCRIBE:`NewsletterSubscribeTransaction`,SITE_REGISTRATION:`SiteRegistrationTransaction`,LEAD_GEN:`LeadGenTransaction`},d={transactionInitiated:`success`,formSubmitted:`N/A`,submissionSucceeded:`N/A`,formHTMLName:`N/A`,elnPackageVersion:`N/A`},f=e=>({...d,formInstanceName:e===i.BIO_PROCESS_INTERNATIONAL?`Hubspot`:`Netline`}),p={transactionInitiated:`success`,formSubmitted:`incomplete`,submissionSucceeded:`incomplete`},m={Eloqua:`Lead Gen from Eloqua form`,Hubspot:`Lead Gen from Hubspot form`},h={LIVE_WEBINAR:`Live Webinar`,ON_DEMAND_WEBINAR:`On-Demand Webinar`},g={NewsletterSubscription:`NewsletterSubscription`,SiteRegistration:`IIRIS Site Registration`,LeadGen:m.Eloqua},_={siteRegSource:`IIRIS Passport`,userLoggedIn:`Logged In`,transactionInitiated:`success`,transactionCompletionStatus:`success`,downstreamUpdateStatus:`success`},v={transactionCompletionStatus:`failure`,downstreamUpdateStatus:`incomplete`},y={transactionCompletionStatus:`success`,downstreamUpdateStatus:`failure`},b={[i.AI_BUSINESS]:`Tech`,[i.THE_AESTHETIC_GUIDE]:`Connect`,[i.BATTERY_TECH]:`Markets`,[i.BEEF_MAGAZINE]:`Markets`,[i.BIO_PROCESS_INTERNATIONAL]:`Connect`,bioprocessintl:`Connect`,[i.BIO_XCONOMY]:`Connect`,[i.BIZ_BASH]:`Connect`,[i.CATERSOURCE]:`Connect`,[i.CONNECTING_AFRICA]:`Connect`,[i.CONTENT_MARKETING_INSTITUTE]:`Festivals`,[i.DARK_READING]:`Tech`,[i.DATA_CENTER_KNOWLEDGE]:`Tech`,[i.DESIGN_NEWS]:`Markets`,[i.EV_INFRASTRUCTURE_NEWS]:`Markets`,[i.FARM_PROGRESS]:`Markets`,[i.FEED_STUFFS]:`Markets`,[i.FI_GLOBAL]:`Markets`,[i.FIN_TECH_FUTURES]:`Festivals`,[i.FOOD_SERVICE_DIRECTOR]:`Connect`,[i.GAME_DEVELOPER]:`Tech`,[i.INFORMATION_WEEK]:`Tech`,[i.INSIDE_SELF_STORAGE]:`Markets`,[i.LICENSE_GLOBAL]:`Markets`,[i.LIGHT_READING]:`Tech`,[i.MDDI]:`Markets`,[i.NATIONAL_HOG_FARMER]:`Markets`,[i.NATION_S_RESTAURANT_NEWS]:`Connect`,[i.NEW_HOPE]:`Markets`,[i.NO_JITTER]:`Tech`,[i.ORGANIC_PRODUCE_NETWORK]:`Markets`,[i.PACKAGING_DIGEST]:`Markets`,[i.PLASTICS_TODAY]:`Markets`,[i.POWDER_BULK_SOLIDS]:`Markets`,[i.SEATRADE_CRUISE]:`Markets`,[i.SEATRADE_MARITIME]:`Markets`,[i.SOLAR_POWER_PORTAL]:`Markets`,[i.SUPERMARKET_NEWS]:`Connect`,[i.SUPPLY_SIDE_FBJ]:`Markets`,[i.SUPPLY_SIDE_SJ]:`Markets`,[i.TELECOMS]:`Tech`,[i.TRADE_SHOW_NEWS_NETWORK]:`Connect`,[i.URGENT_COMMS]:`Tech`,[i.VITA_FOODS_INSIGHTS]:`Markets`,[i.WASTE360]:`Markets`,[i.WEALTH_MANAGEMENT]:`Connect`,[i.WORLD_HEALTH_EXHIBITIONS_INSIGHTS]:`Markets`},x=`/api/track-transaction`,S=e=>{let t=ee(e.siteName);return{...e,divisionId:t,...typeof window<`u`&&{origin:window.location.origin,siteUrl:window.location.origin,actionPoint:e.actionPoint||window.location.href}}},ee=e=>e&&b[e]||`N/A`,te=()=>({...a()}),ne=(e,t)=>n=>{if(typeof window>`u`)return;let r=S({...t,eventType:e,date:new Date().toUTCString(),...n});try{window.fetch(x,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(r),keepalive:!0}
1).catch(()=>{})}catch{}},C=r(),w=e(t()),T=(e,t)=>n=>{let r=S({...t,eventType:e,date:new Date().toUTCString(),...n}),i=new Blob([JSON.stringify(r)],{type:`application/json`});navigator.sendBeacon(x,i)},E=(e,t,n,r)=>{let i=(0,C.c)(11),a;i[0]===Symbol.for(`react.memo_cache_sentinel`)?(a={},i[0]=a):a=i[0];let o=(0,w.useRef)(a),s;i[1]!==t||i[2]!==e?(s=T(e,t),i[1]=t,i[2]=e,i[3]=s):s=i[3];let c=s,l;i[4]!==r||i[5]!==n||i[6]!==c?(l=()=>{n().then(e=>{o.current=e});let e=()=>{document.visibilityState===`hidden`&&c({...o.current,...r})};return window.addEventListener(`visibilitychange`,e),()=>window.removeEventListener(`visibilitychange`,e)},i[4]=r,i[5]=n,i[6]=c,i[7]=l):l=i[7];let u;i[8]!==r||i[9]!==n?(u=[n,r],i[8]=r,i[9]=n,i[10]=u):u=i[10],(0,w.useEffect)(l,u)},D=e(n()),O=typeof globalThis<`u`?globalThis:typeof window<`u`?window:typeof global<`u`?global:typeof self<`u`?self:{};function k(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,`default`)?e.default:e}var re={exports:{}},A={},j;function ie(){if(j)return A;j=1;var e=Symbol.for(`react.transitional.element`),t=Symbol.for(`react.fragment`);function n(t,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:e,type:t,key:i,ref:n===void 0?null:n,props:r}}return A.Fragment=t,A.jsx=n,A.jsxs=n,A}var ae;function oe(){return ae||(ae=1,re.exports=ie()),re.exports}var M=oe(),N=(e=>(e.REQUIRED=`IsRequiredCondition`,e.URL=`PreventUrlCondition`,e.XSS=`PreventXSSCondition`,e.LENGTH=`TextLengthCondition`,e.EMAIL=`IsEmailAddressCondition`,e.IFOTHER=`IsIfOtherFieldCondition`,e.NUMBERS_ONLY=`IsNumbersOnlyCondition`,e.ALLOW_EMPTY=`IsAllowedEmptyCondition`,e.CUSTOM_CONDITION=`IsCustomCondition`,e))(N||{}),P=(e=>(e.ELOQUA=`ELOQUA`,e.HUBSPOT=`HUBSPOT`,e))(P||{}),F=(e=>(e.DISPLAY=`DISPLAY`,e))(F||{}),I=(e=>(e.STATE=`state`,e.COUNTRY=`country`,e.CONSENT=`consent`,e.THIRD_PARTY_CONSENT=`thirdPartyConsent`,e.NEWSLETTER_LIST=`newsletterList`,e.EMAIL_ADDRESS=`emailAddress`,e.BUSINESS_EMAIL=`business_email`,e.MARKETO_EMAIL=`Email`,e.MARKETO_COUNTRY=`Country`,e.HUBSPOT_EMAIL=`email`,e))(I||{}),L=(e=>(e[e.COLLAPSED=1]=`COLLAPSED`,e[e.EXPANDED=2]=`EXPANDED`,e[e.STATE=3]=`STATE`,e[e.CONSENT=4]=`CONSENT`,e[e.SUCCESS=5]=`SUCCESS`,e))(L||{}),se=`contact_url_confirm`,ce=`eln-hp-contact`,le=`[data-eln-honeypot]`,ue={position:`absolute`,left:`-9999px`,width:`1px`,height:`1px`,overflow:`hidden`},R={CONTAINER_DIV:`eln-newsletter-success-container`,PLAIN_TEXT:`eln-newsletter-success-paragraph-text`,EMPHASIS_TEXT:`eln-newsletter-success-emphasis-text`,THANKYOU_TITLE:`eln-newsletter-success-title`,BUTTON:`eln-newsletter-success-button`},de={CONTAINER_DIV:`eln-error-container`,PLAIN_TEXT:`eln-error-paragraph-text`,ERROR_TITLE:`eln-error-title`,BUTTON:`eln-error-button`},fe={CONTAINER:`eln-newsletter-formlayout-container`,SUBMIT_CONTAINER:`eln-newsletter-formlayout-submit-container`},z={CONTAINER:`eln-newsletter-consent-container`,THIRD_PARTY_CONTAINER:`eln-third-party-consent-container`,A:`eln-third-party-consent-a`,P:`eln-third-party-consent-p`},B={CONTAINER:`eln-newsletter-newsletterlist-container`,ITEM:`eln-newsletter-newsletterlist-item`,TITLE:`eln-newsletter-newsletterlist-title`,INPUT_CONTAINER:`eln-newsletter-newsletterlist-input-container`,CONTENT_CONTAINER:`eln-newsletter-newsletterlist-content-container`,FREQUENCY:`eln-newsletter-newsletterlist-frequency`,FREQUENCY_A:`eln-newsletter-newsletterlist-frequency-a`,FREQUENCY_P:`eln-newsletter-newsletterlist-frequency-p`},V={FORM:`eln-newsletter-form`,CONTAINER:`eln-newsletter-form-container`,TEXT_INPUT_FRAGMENT:`eln-newsletter-form-text-input-fragment`,LABEL_FRAGMENT:`eln-newsletter-form-label-fragment`,SELECT_INPUT_FRAGMENT:`eln-newsletter-form-select-input-fragment`,CHECKBOX_INPUT_FRAGMENT:`eln-newsletter-form-checkbox-input-fragment`,SELECT_STATE_PROVINCE_HIDDEN:`eln-newsletter-form-select-state-province-hidden`,SELECT_MULTIPLE:`eln-newsletter-form-select-multiple`,VALIDATION_HEADER:`eln-form-validation-header`,VALIDATION_ERRORED_FIELD:`eln-form-errored-field`,VALIDATION_ERROR_NEWSLETTER:`eln-newsletter-error`,SELECT_ELEMENT:`eln-newsletter-form-select-element`,SELECT_OPTION_ELEMENT:`eln-newsletter-form-select-option-element`,INPUT_ELEMENT:`eln-newsletter-form-input-element`,A:`eln-newsletter-form-a`,P:`eln-newsletter-form-p`,CHECKBOX_CONTAINER:`eln-newsletter-form-checkbox-container`,RADIO_OPTION_ELEMENT:`eln-newsletter-form-radio-option-element`,CAPTCHA:`eln-newsletter-form-captcha`,CAPTCHA_CONTAINER:`eln-newsletter-form-captcha-container`},pe={CONTAINER:`eln-ui-spinner-container`,LOADING:`eln-ui-spinner-loading`},H=(e=>(e.ERROR=`ERROR`,e.PENDING=`PENDING`,e.SUCCESS=`SUCCESS`,e.NEW=`NEW`,e))(H||{}),U={CONTAINER:`eln-entitlement-formlayout-container`,TITLE:`eln-entitlement-formlayout-title`,DESCRIPTION:`eln-entitlement-formlayout-description`,HUBSPOT_HELPER_TEXT_WRAPPER:`eln-entitlement-formlayour-helper-text-wrapper`,HUBSPOT_HELPER_TEXT_LINKS:`eln-entitlement-formlayour-helper-text-links`},me=[`company`,`job_title`,`areaResponsibility`,`job_level`,`company_
1size`,`annualSales`,`C_BusPhone`],he=[`state_or_province`,`state`,`typeConcept`,`type_concept`,`responsibilitiesOther`,`complianceOther`,`technologyRequirementsOther`,`State`],ge={nrn:[`company`,`job_title`,`areaResponsibility`,`job_level`,`company_size`,`annualSales`,`C_BusPhone`]},_e={nrn:[`typeConcept`,`type_concept`],bioprocessintl:[`state_or_province`,`state`,`State`]},ve={foodbeverageinsider:`Food & Beverage Insider`,naturalproductsinsider:`Natural Products Insider`,newhope:`New Hope Network`,licenseglobal:`License Global`,designnews:`Design News`,batterytech:`Battery Tech`,powderbulksolids:`Powder Bulk Solids`,packagingdigest:`Packaging Digest`,plastictoday:`Plastics Today`,mddi:`MDDI`,constructionext:`Construction Next (WOC360, Roofing, PoolSpaPro)`,waste360:`Waste360`,insideselfstorage:`Inside Self Storage`,supermarketnews:`Supermarket News`,organicproducenetwork:`Organic Produce Network`,seatradecruise:`Seatrade Cruise News`,seatrademaritime:`Seatrade Maritime News`,supplysidesj:`SupplySide Supplement Journal`,supplysidefbj:`SupplySide Food & Beverage Journal`,figlobal:`Fi Global Insights`,vitafoodsinsights:`Vitafoods Insights`,specialevents:`Special Events`,catersource:`Catersource`,worldhealthexhibitions:`World Health Expo Insights`,nrn:`Nation's Restaurant News`,wealthmanagement:`Wealth Management`,contentmarketinginstitute:`Content Marketing Institute`,foodservicedirector:`FoodService Director`},ye=`Please choose first party consent agreement`,be=`Please choose consent agreement`,xe={[P.ELOQUA]:{business_email:`business_email`,first_name:`first_name`,last_name:`last_name`,country:`country`,state:`state`,firstPartyConsent:`firstPartyConsent`,thirdPartyConsent:`thirdPartyConsent`},[P.HUBSPOT]:{email:`business_email`,firstname:`first_name`,lastname:`last_name`,country:`country`,state:`state`,first_party_consent:`firstPartyConsent`,third_party_consent:`thirdPartyConsent`}},Se={wealthmanagement:[`cfpBoardID`,`crd_id`]},Ce={cfpBoardID:{messageOverride:`Invalid CFP ID entry`,rules:[{type:N.NUMBERS_ONLY,message:`This field requires numberic characters only`},{type:N.ALLOW_EMPTY,message:``}]},crd_id:{messageOverride:`Invalid CRD ID entry`,rules:[{type:N.LENGTH,message:`Invalid number of characters`,minimum:`6`,maximum:`7`},{type:N.NUMBERS_ONLY,message:`This field requires numberic characters only`},{type:N.ALLOW_EMPTY,message:``}]}},we=[`business_email`],Te=[`country`],Ee=`Access granted`,De=`Your account gives you access to this content.`,Oe=e=>{let t=document.cookie.split(`; `).map(e=>{let[t,n=``]=e.split(/=(.*)/s);return[decodeURIComponent(t),decodeURIComponent(n)]});return Object.fromEntries(t)[e]||null},ke=()=>{let e=Oe(`utm_parameters`);return e?e.split(`,`).map(e=>{let[t,...n]=e.split(`:`);return[t,n.join(`:`)]}).map(([e,t])=>({key:e,value:t})):[]},Ae=()=>ke().reduce((e,{key:t,value:n})=>(t&&!(t in e)&&(e[t]=n),e),{}),je=`0.8.20`,Me=()=>o.create({headers:{"x-eln-fe-version":je}}),Ne=(e,t,n,r,i)=>{let a={data:{type:n,id:r},gatingAction:i},o=[...ke()];return{data:{id:e,type:`gated-content-form-data`,attributes:{dynamicFields:[],thirdPartyConsent:!1,emailAddress:e},relationships:{gatedContent:a,user:{data:{id:t}},form:{data:{type:`forms`,id:``}}}},meta:{tracking:o}}},W=(e,t)=>{if(!t)return e;let n=new URLSearchParams;Object.entries(t).forEach(([e,t])=>{t!=null&&t!==``&&n.set(e,String(t))});let r=n.toString();return r?`${e}?${r}`:e},Pe=e=>Ie(e)&&!e.attributes.elements.some(e=>e.fieldName===`is_new_form`),Fe=(e,t)=>t&&e===`wealthmanagement`,Ie=e=>e.formType===P.HUBSPOT,Le=(e,t)=>{let n=[`sponsor_name`,`sponsorname`];return e.map(e=>(n.includes((e?.fieldName)?.toLowerCase())&&(e.value=t),e))},Re=e=>!e||Object.keys(e).length===0,ze=(e,t)=>e?.find(e=>e?.fieldName===t)?.value||``,Be=e=>{let t=ge[e]||[],n=_e[e];return n?[...t,...he.filter(e=>!n.includes(e))]:[...t,...he]},Ve=(e,t)=>({industry:e.industries||e.business_types,job_function:e.job_functions,JF_JobFunction:e.job_functions})[t];function He(e){let t=(e||``).toLowerCase();return![`testautomation`,`testautomationuat`].includes(t)}var Ue=(e,t)=>({wealthmanagement:{primaryBusinessClass:t.primaryBusiness||t.primaryBusinessClass||``,primaryBusiness:t.primaryBusiness||t.primaryBusinessClass||``}})[e]||void 0,We=e=>e?.toUpperCase()??P.ELOQUA,Ge=(e,t)=>
1[`article`].includes(e)&&t,Ke=e=>e===I.EMAIL_ADDRESS||e===I.BUSINESS_EMAIL||e===I.MARKETO_EMAIL||e===I.HUBSPOT_EMAIL,qe=({forceThirdPartyConsentAsFalse:e=!1,elements:t})=>e&&!(t!=null&&t.length),Je=e=>e instanceof Error?e:Error(String(e)),Ye=(e,t)=>{let n=new Set(e);return n.has(t)?n.delete(t):n.add(t),n},Xe=e=>typeof e!=`string`||!e?``:e.includes(`-`)?e.split(`-`)[1]??``:e,Ze=class{constructor(e,t,n,r,i,a,o,s){this.getPlatformApiServiceHeaders=()=>{var e;let t={Authorization:this.authorization||`Bearer anonymous`,"Content-Type":`application/json`,"x-site-id":this.siteId.toLowerCase(),"x-product-id":this.productId,...typeof window<`u`&&{"X-Origin-Url":window.location.href}};return(e=this.iirisUserProfile)!=null&&e.id&&(t[`x-iiris-id`]=this.iirisUserProfile.id),this.subBrandId&&(t[`x-sub-brand-id`]=this.subBrandId),t},this.getFormFieldValueByName=(e,t)=>{let n=t?.find(t=>t.htmlName===e);return n?n.value:``},this.mapDataAttributes=e=>e.formFields?{emailAddress:this.getFormFieldValueByName(`emailAddress`,e.formFields),firstName:this.getFormFieldValueByName(`firstName`,e.formFields),lastName:this.getFormFieldValueByName(`lastName`,e.formFields),country:this.getFormFieldValueByName(`country`,e.formFields),job:this.getFormFieldValueByName(`job`,e.formFields),company:this.getFormFieldValueByName(`company`,e.formFields),industry:this.getFormFieldValueByName(`industry`,e.formFields),state:this.getFormFieldValueByName(`state`,e.formFields),JF_JobFunction:this.getFormFieldValueByName(`JF_JobFunction`,e.formFields),phone:this.getFormFieldValueByName(`phone`,e.formFields),consent:e.firstPartyConsent}:{},this.buildNewsletterSubscriptionPayload=(e,t,n,r)=>{let i=this.getEmailAddress(e,n),{formFields:a}=e,o=e.newsletterList.map(e=>({data:{type:`newsletters`,id:e}})),s=[];r&&a&&(s=r.filter(e=>e.elementType!==`text`&&e.elementType!==`button`&&a.some(({htmlName:t})=>t===e.fieldName)).map(e=>{let t=a.find(t=>t.htmlName===e.fieldName);return{questionCode:e.fieldName,questionText:e.label,answer:t.value}}));let c=[...ke()],l=n?{}:this.mapDataAttributes(e),u={data:{id:i,type:`newsletter-subscriptions`,attributes:{dynamicFields:s,...l,...e.honeypot===void 0?{}:{honeypot:e.honeypot}},relationships:{user:n?this.getUserRelationship(n):null,newsletters:o,form:this.getFormRelationship(e.formId),userProfileForm:this.getFormRelationship(e.formId)}},meta:{tracking:c},captchaToken:t,context:this.context};return t&&(u.captchaToken=t),u},this.putNewslettersSubscription=async(e,t,n,r,i)=>{let a=e.emailAddress||this.getEmailAddress(e,n);return Me().put(`${this.platformServiceBaseUrl}/newsletter-subscriptions/${a}`,{...this.buildNewsletterSubscriptionPayload(e,t,n,r)},{headers:{...this.getPlatformApiServiceHeaders(),"x-reg-event":i||!1}})},this.buildGatedContentPayload=(e,t,n,r,i)=>{let a={data:{type:e.contentType,id:e.contentId},gatingAction:e.gatingAction},o=[];n&&r&&(o=n.filter(e=>e.elementType!==`text`&&e.elementType!==`button`).map(e=>{let t=r.find(t=>t.htmlName===e.fieldName).value;return{questionCode:(e.fieldNamePrefix||``)+e.fieldName,questionText:e.label,answer:t}}));let s=this.getEmailAddress(e,t),c=[...ke()],l=t?{}:this.mapDataAttributes(e),u={data:{id:s,type:`gated-content-form-data`,attributes:{dynamicFields:o,thirdPartyConsent:e.thirdPartyConsent,...l,emailAddress:s,...e.honeypot===void 0?{}:{honeypot:e.honeypot}},relationships:{gatedContent:a,user:t?this.getUserRelationship(t):null,form:this.getFormRelationship(e.formId)}},captchaToken:i,meta:{tracking:c}};return i&&(u.captchaToken=i),u},this.submitGatedContentFormData=async(e,t,n,r,i)=>Me().post(`${this.platformServiceBaseUrl}/gated-content-form-data`,{...this.buildGatedContentPayload(e,t,n,r,i)},{headers:{...this.getPlatformApiServiceHeaders()}}),this.getFormById=async(e,t=!1,n)=>Me().get(`${this.platformServiceBaseUrl}/forms/${e}`,{headers:{...this.getPlatformApiServiceHeaders(),"x-reg-event":t,...n}}).then(e=>e.data.data),this.getNewsletterData=async e=>{let t=W(this.platformServiceBaseUrl+`/newsletters`,e.filters),n=(await Me().get(t,{headers:{...this.getPlatformApiServiceHeaders(),"x-reg-event":e.isRegisterEvent}})).data.data;return Array.isArray(n)&&n.length>0?{form_id:n[0].relationships.form.data.id,form_storage:n[0].relationships.form.data.formStorage,newsletters:n.map(e=>({title:e.title,newsletter_code:e.id,newsletter_description:e.description,frequency_description:e.frequency,sample_url:{title:e.s
1ample?.title,href:e.sample?.link}}))}:{form_id:``,form_storage:``,newsletters:[]}},this.getEntitlementData=async(e,t)=>{let n=await Me().get(this.platformServiceBaseUrl+`/${e}/${t}`,{headers:{...this.getPlatformApiServiceHeaders()}}),r=n?.data?.data?.attributes||{},i=n?.data?.config;return i.attributes=r,i},this.getEntitlementFormConfiguration=async()=>(await Me().get(this.platformServiceBaseUrl+`/entitlement-form-configuration`,{headers:{...this.getPlatformApiServiceHeaders()}}))?.data,this.getUserRelationship=e=>({data:{type:`users`,id:e.id}}),this.getFormRelationship=e=>({data:{type:`forms`,id:e}}),this.platformServiceBaseUrl=`${e}/${a||`v1`}`,this.siteId=t,this.authorization=n,this.context=r,this.subBrandId=i,this.iirisUserProfile=o,this.productId=s||``}getEmailAddress(e,t){return t?t.business_email:this.getFormFieldValueByName(`email`,e.formFields)||this.getFormFieldValueByName(`Email`,e.formFields)||this.getFormFieldValueByName(`emailAddress`,e.formFields)||this.getFormFieldValueByName(`business_email`,e.formFields)||this.getFormFieldValueByName(`USER_PROFILE_emailAddress`,e.formFields)||this.getFormFieldValueByName(`USER_PROFILE_business_email`,e.formFields)}},Qe=async e=>{var t;let n=new Ze(e.platformServiceBaseUrl,e.clientId,e.authorization,e.context,e.subBrandId,e.version,void 0,e.productId),r={filters:{tag:e.newsletterTag||``,state:e.countryState||``,shouldUseAlternativeForm:e.context?.shouldUseAlternativeForm??!1,...e.newsletterVariant&&{newsletterVariant:e.newsletterVariant}},isRegisterEvent:e.isOpenOnRegister||!1},i=await n.getNewsletterData(r),a;return i.form_id&&!e.iirisUserProfile&&(a=(await n.getFormById(i.form_id,e.isOpenOnRegister,{"x-subscription-event":!0}))?.formType),{...Ae(),elnPackageVersion:je,formInstanceName:a,formHTMLName:i?.form_id||``,userLoggedIn:(t=e.iirisUserProfile)!=null&&t.id?`Logged In`:`Anonymous`}},$e=async e=>{let t=new Ze(e.platformServiceBaseUrl,e.clientId,e.authorization,void 0,e.subBrandId,e.version,e.iirisUserProfile,e.productId),n=await t.getEntitlementFormConfiguration(),r=e.formId||n?.default_gating_form,i;return r&&(i=(await t.getFormById(r,!1,{"x-content-type":e.contentType}))?.formType),{...Ae(),elnPackageVersion:je,formInstanceName:i||`Eloqua`,formHTMLName:r||``,userLoggedIn:e.authorization?`Logged In`:`Anonymous`}},et=class{constructor(){this.validateFormField=(e,t,n=``)=>{var r;let i=t.validations,a=[];if((r=t.validations)!=null&&r.some(e=>e.type===N.ALLOW_EMPTY)&&!e)return[];i?.forEach(n=>{switch(n.type){case N.REQUIRED:return this.isEmpty(e)?a.push(this.errorMessage(n,t)):null;case N.URL:return this.isUrl(e)?a.push(this.errorMessage(n,t)):null;case N.XSS:return this.isXss(e)?a.push(this.errorMessage(n,t)):null;case N.LENGTH:return this.isInvalidLength(e,n.minimum,n.maximum)?a.push(this.errorMessage(n,t,[{name:`minimum`,value:n.minimum},{name:`maximum`,value:n.maximum}])):null;case N.EMAIL:return!this.isEmpty(e)&&this.isInvalidEmail(e)?a.push(this.errorMessage(n,t)):null;case N.NUMBERS_ONLY:return this.isNumeric(e)?null:a.push(this.errorMessage(n,t));case N.IFOTHER:return this.isOther(e)?a.push(this.errorMessage(n,t)):null;default:return null}});let o=this.getFieldCustomOverrideMessage(t,n);return a.length&&o?o:a},this.errorMessage=(e,t,n)=>({code:e.type,message:e.message,params:n||[],formElement:t}),this.isEmpty=e=>e===``,this.isInvalidEmail=e=>!e.match(/(^[A-Z0-9!#$%&'*+\-/=?^_`{|}~][A-Z0-9!#$%&'*+\-/=?^_`{|}~.]{0,62}@(([A-Z0-9](?:[A-Z0-9-]{0,61}[A-Z0-9])?)(\.[A-Z0-9](?:[A-Z0-9-]{0,61}[A-Z0-9])?)+)$)/i),this.isUrl=e=>!!e.match(/(telnet|ftp|https|http?):\/\/(?:[a-z0-9][a-z0-9-]{0,61}[a-z0-9]\.|[a-z0-9]\.)+[a-z]{2,63}/i),this.isXss=e=>!!e.match(/(<([^>]+)>)/i),this.isInvalidLength=(e,t,n)=>{let r=t?+t:0,i=n?+n:0;return r>i||r===0&&i===0||e.length<r||e.length>i},this.isOther=e=>!!e.match(/^Other.*/i),this.isNumeric=e=>/^\d+$/.test(e),this.getFieldCustomOverrideMessage=(e,t)=>{var n,r;if(!(!((n=Se[t])!=null&&n.includes(e.fieldName))&&!((r=Ce[e.fieldName])!=null&&r.messageOverride)))return[{code:N.CUSTOM_CONDITION,message:Ce[e.fieldName].messageOverride||``,params:[],formElement:e}]}}},tt={exports:{}},nt;function rt(){return nt||(nt=1,function(e){(function(){var t={}.hasOwnProperty;function n(){for(var e=[],r=0;r<arguments.length;r++){var i=arguments[r];if(i){var a=typeof i;if(a===`string`||a===`number`)e.push(i);else if(Array.isArray(i)){if(i.length){var o=n.apply(null,i);o&&e.push(o)}}else if(a===`object`){if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes(`[native code]`)){e.push(i.toString());continue}for(var s in i)t.call(i,s)&&i[s]&&e.push(s)}}}return e.join(` `)}e.exports?(n.default=n,e.exports=n):window.classNames=n}
1)()}(tt)),tt.exports}var G=k(rt()),it={exports:{}};it.exports;var at;function ot(){return at||(at=1,function(e,t){var n=`__lodash_hash_undefined__`,r=9007199254740991,i=`[object Arguments]`,a=`[object Array]`,o=`[object Boolean]`,s=`[object Date]`,c=`[object Error]`,l=`[object Function]`,u=`[object Map]`,d=`[object Number]`,f=`[object Object]`,p=`[object RegExp]`,m=`[object Set]`,h=`[object String]`,g=`[object WeakMap]`,_=`[object ArrayBuffer]`,v=`[object DataView]`,y=`[object Float32Array]`,b=`[object Float64Array]`,x=`[object Int8Array]`,S=`[object Int16Array]`,ee=`[object Int32Array]`,te=`[object Uint8Array]`,ne=`[object Uint8ClampedArray]`,C=`[object Uint16Array]`,w=`[object Uint32Array]`,T=/[\\^$.*+?()[\]{}|]/g,E=/^\[object .+?Constructor\]$/,D=/^(?:0|[1-9]\d*)$/,k={};k[y]=k[b]=k[x]=k[S]=k[ee]=k[te]=k[ne]=k[C]=k[w]=!0,k[i]=k[a]=k[_]=k[o]=k[v]=k[s]=k[c]=k[l]=k[u]=k[d]=k[f]=k[p]=k[m]=k[h]=k[g]=!1;var re=typeof O==`object`&&O&&O.Object===Object&&O,A=typeof self==`object`&&self&&self.Object===Object&&self,j=re||A||Function(`return this`)(),ie=t&&!t.nodeType&&t,ae=ie&&e&&!e.nodeType&&e,oe=ae&&ae.exports===ie,M=oe&&re.process,N=function(){try{return ae&&ae.require&&ae.require(`util`).types||M&&M.binding&&M.binding(`util`)}catch{}}(),P=N&&N.isTypedArray;function F(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function I(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function L(e){return function(t){return e(t)}}function se(e,t){return e?.[t]}function ce(e,t){return function(n){return e(t(n))}}var le=Array.prototype,ue=Function.prototype,R=Object.prototype,de=j[`__core-js_shared__`],fe=ue.toString,z=R.hasOwnProperty,B=function(){var e=/[^.]+$/.exec(de&&de.keys&&de.keys.IE_PROTO||``);return e?`Symbol(src)_1.`+e:``}(),V=R.toString,pe=fe.call(Object),H=RegExp(`^`+fe.call(z).replace(T,`\\$&`).replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,`$1.*?`)+`$`),U=oe?j.Buffer:void 0,me=j.Symbol,he=j.Uint8Array;U&&U.allocUnsafe;var ge=ce(Object.getPrototypeOf,Object),_e=Object.create,ve=R.propertyIsEnumerable,ye=le.splice,be=me?me.toStringTag:void 0,xe=function(){try{var e=_t(Object,`defineProperty`);return e({},``,{}),e}catch{}}(),Se=U?U.isBuffer:void 0,Ce=Math.max,we=Date.now,Te=_t(j,`Map`),Ee=_t(Object,`create`),De=function(){function e(){}return function(t){if(!Bt(t))return{};if(_e)return _e(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function Oe(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function ke(){this.__data__=Ee?Ee(null):{},this.size=0}function Ae(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=+!!t,t}function je(e){var t=this.__data__;if(Ee){var r=t[e];return r===n?void 0:r}return z.call(t,e)?t[e]:void 0}function Me(e){var t=this.__data__;return Ee?t[e]!==void 0:z.call(t,e)}function Ne(e,t){var r=this.__data__;return this.size+=+!this.has(e),r[e]=Ee&&t===void 0?n:t,this}Oe.prototype.clear=ke,Oe.prototype.delete=Ae,Oe.prototype.get=je,Oe.prototype.has=Me,Oe.prototype.set=Ne;function W(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Pe(){this.__data__=[],this.size=0}function Fe(e){var t=this.__data__,n=et(t,e);return n<0?!1:(n==t.length-1?t.pop():ye.call(t,n,1),--this.size,!0)}function Ie(e){var t=this.__data__,n=et(t,e);return n<0?void 0:t[n][1]}function Le(e){return et(this.__data__,e)>-1}function Re(e,t){var n=this.__data__,r=et(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}W.prototype.clear=Pe,W.prototype.delete=Fe,W.prototype.get=Ie,W.prototype.has=Le,W.prototype.set=Re;function ze(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Be(){this.size=0,this.__data__={hash:new Oe,map:new(Te||W),string:new Oe}}function Ve(e){var t=gt(this,e).delete(e);return this.size-=+!!t,t}function He(e){return gt(this,e).get(e)}function Ue(e){return gt(this,e).has(e)}function We(e,t){var n=gt(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}ze.prototype.clear=Be,ze.prototype.delete=Ve,ze.prototype.get=He,ze.prototype.has=Ue,ze.prototype.set=We;function Ge(e){var t=this.__data__=new W(e);this.size=t.size}function Ke(){this.__data__=new W,this.size=0}function qe(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function Je(e){return this.__data__.get(e)}function Ye(e){return this.__data__.has(e)}function Xe(e,t){var n=this.__data__;if(n instanceof W){var r=n.__data__;if(!Te||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new ze(r)}return n.set(e,t),this.size=n.size,this}Ge.prototype.clear=Ke,Ge.prototype.delete=qe,Ge.prototype.get=Je,Ge.prototype.has=Ye,Ge.prototype.set=Xe;function Ze(e,t){var n=Pt(e),r=!n&&Nt(e),i=!n&&!r&&Lt(e),a=!n&&!r&&!i&&Ht(e),o=n||r||i||a,s=o?I(e.length,String):[],c=s.length;for(var l in e)o&&(l==`length`||i&&(l==`offset`||l==`parent`)||a&&(l==`buffer`||l==`byteLength`||l==`byteOffset`)||bt(l,c))||s.push(l);return s}function Qe(e,t,n){(n!==void 0&&!Mt(e[t],n)||n===void 0&&!(t in e))&&tt(e,t,n)}function $e(e,t,n){var r=e[t];(!(z.call(e,t)&&Mt(r,n))||n===void 0&&!(t in e))&&tt(e,t,n)}function et(e,t){for(var n=e.length;n--;)if(Mt(e[n][0],t))return n;return-1}function tt(e,t,n){t==`__proto__`&&xe?xe(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var nt=ht();
1function rt(e){return e==null?e===void 0?`[object Undefined]`:`[object Null]`:be&&be in Object(e)?vt(e):Et(e)}function G(e){return J(e)&&rt(e)==i}function it(e){return!Bt(e)||Ct(e)?!1:(Rt(e)?H:E).test(jt(e))}function at(e){return J(e)&&zt(e.length)&&!!k[rt(e)]}function ot(e){if(!Bt(e))return Tt(e);var t=wt(e),n=[];for(var r in e)r==`constructor`&&(t||!z.call(e,r))||n.push(r);return n}function st(e,t,n,r,i){e!==t&&nt(t,function(a,o){if(i||=new Ge,Bt(a))ct(e,t,o,n,st,r,i);else{var s=r?r(Ot(e,o),a,o+``,e,t,i):void 0;s===void 0&&(s=a),Qe(e,o,s)}},Wt)}function ct(e,t,n,r,i,a,o){var s=Ot(e,n),c=Ot(t,n),l=o.get(c);if(l){Qe(e,n,l);return}var u=a?a(s,c,n+``,e,t,o):void 0,d=u===void 0;if(d){var f=Pt(c),p=!f&&Lt(c),m=!f&&!p&&Ht(c);u=c,f||p||m?Pt(s)?u=s:It(s)?u=ft(s):p?(d=!1,u=lt(c)):m?(d=!1,u=dt(c)):u=[]:Vt(c)||Nt(c)?(u=s,Nt(s)?u=Ut(s):(!Bt(s)||Rt(s))&&(u=yt(c))):d=!1}d&&(o.set(c,u),i(u,c,r,a,o),o.delete(c)),Qe(e,n,u)}function K(e,t){return kt(Dt(e,t,qt),e+``)}var q=xe?function(e,t){return xe(e,`toString`,{configurable:!0,enumerable:!1,value:Kt(t),writable:!0})}:qt;function lt(e,t){return e.slice()}function ut(e){var t=new e.constructor(e.byteLength);return new he(t).set(new he(e)),t}function dt(e,t){var n=ut(e.buffer);return new e.constructor(n,e.byteOffset,e.length)}function ft(e,t){var n=-1,r=e.length;for(t||=Array(r);++n<r;)t[n]=e[n];return t}function pt(e,t,n,r){var i=!n;n||={};for(var a=-1,o=t.length;++a<o;){var s=t[a],c=void 0;c===void 0&&(c=e[s]),i?tt(n,s,c):$e(n,s,c)}return n}function mt(e){return K(function(t,n){var r=-1,i=n.length,a=i>1?n[i-1]:void 0,o=i>2?n[2]:void 0;for(a=e.length>3&&typeof a==`function`?(i--,a):void 0,o&&xt(n[0],n[1],o)&&(a=i<3?void 0:a,i=1),t=Object(t);++r<i;){var s=n[r];s&&e(t,s,r,a)}return t})}function ht(e){return function(e,t,n){for(var r=-1,i=Object(e),a=n(e),o=a.length;o--;){var s=a[++r];if(t(i[s],s,i)===!1)break}return e}}function gt(e,t){var n=e.__data__;return St(t)?n[typeof t==`string`?`string`:`hash`]:n.map}function _t(e,t){var n=se(e,t);return it(n)?n:void 0}function vt(e){var t=z.call(e,be),n=e[be];try{e[be]=void 0;var r=!0}catch{}var i=V.call(e);return r&&(t?e[be]=n:delete e[be]),i}function yt(e){return typeof e.constructor==`function`&&!wt(e)?De(ge(e)):{}}function bt(e,t){var n=typeof e;return t??=r,!!t&&(n==`number`||n!=`symbol`&&D.test(e))&&e>-1&&e%1==0&&e<t}function xt(e,t,n){if(!Bt(n))return!1;var r=typeof t;return(r==`number`?Ft(n)&&bt(t,n.length):r==`string`&&t in n)?Mt(n[t],e):!1}function St(e){var t=typeof e;return t==`string`||t==`number`||t==`symbol`||t==`boolean`?e!==`__proto__`:e===null}function Ct(e){return!!B&&B in e}function wt(e){var t=e&&e.constructor;return e===(typeof t==`function`&&t.prototype||R)}function Tt(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}function Et(e){return V.call(e)}function Dt(e,t,n){return t=Ce(t===void 0?e.length-1:t,0),function(){for(var r=arguments,i=-1,a=Ce(r.length-t,0),o=Array(a);++i<a;)o[i]=r[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=r[i];return s[t]=n(o),F(e,this,s)}}function Ot(e,t){if((t!==`constructor`||typeof e[t]!=`function`)&&t!=`__proto__`)return e[t]}var kt=At(q);function At(e){var t=0,n=0;return function(){var r=we(),i=16-(r-n);if(n=r,i>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function jt(e){if(e!=null){try{return fe.call(e)}catch{}try{return e+``}catch{}}return``}function Mt(e,t){return e===t||e!==e&&t!==t}var Nt=G(function(){return arguments}())?G:function(e){return J(e)&&z.call(e,`callee`)&&!ve.call(e,`callee`)},Pt=Array.isArray;function Ft(e){return e!=null&&zt(e.length)&&!Rt(e)}function It(e){return J(e)&&Ft(e)}var Lt=Se||Y;function Rt(e){if(!Bt(e))return!1;var t=rt(e);return t==l||t==`[object GeneratorFunction]`||t==`[object AsyncFunction]`||t==`[object Proxy]`}function zt(e){return typeof e==`number`&&e>-1&&e%1==0&&e<=r}function Bt(e){var t=typeof e;return e!=null&&(t==`object`||t==`function`)}function J(e){return typeof e==`object`&&!!e}function Vt(e){if(!J(e)||rt(e)!=f)return!1;var t=ge(e);if(t===null)return!0;var n=z.call(t,`constructor`)&&t.constructor;return typeof n==`function`&&n instanceof n&&fe.call(n)==pe}var Ht=P?L(P):at;function Ut(e){return pt(e,Wt(e))}function Wt(e){return Ft(e)?Ze(e):ot(e)}var Gt=mt(function(e,t,n){st(e,t,n)});function Kt(e){return function(){return e}}function qt(e){return e}function Y(){return!1}e.exports=Gt}(it,it.exports)),it.exports}var st=k(ot()),ct=(e,t)=>
1st({base:{h1:``,p:``,span:``,a:``,button:``,form:``,label:``,input:``,checkbox:``,radio:``,select:``,option:``},formLayout:{container:t===`newsletter`?fe.CONTAINER:U.CONTAINER,formContainer:V.CONTAINER,formContainerRow:`row`,formContainerRowWide:``,form:V.FORM,submitContainer:fe.SUBMIT_CONTAINER,captchaContainer:V.CAPTCHA_CONTAINER,submit:``,title:t===`entitlement`?U.TITLE:``,unlockedTitle:t===`entitlement`?U.TITLE:``,unlockedDescription:t===`entitlement`?U.DESCRIPTION:``,description:t===`entitlement`?U.DESCRIPTION:``,checkbox:V.CHECKBOX_INPUT_FRAGMENT,select:V.SELECT_INPUT_FRAGMENT,selectLabelSpan:``,selectState:V.SELECT_STATE_PROVINCE_HIDDEN,selectMultiple:V.SELECT_MULTIPLE,label:V.LABEL_FRAGMENT,input:V.SELECT_INPUT_FRAGMENT,textInput:V.TEXT_INPUT_FRAGMENT,textInputLabelSpan:``,validationErroredField:V.VALIDATION_ERRORED_FIELD,validationHeader:V.VALIDATION_HEADER,a:V.A,p:V.P,selectElement:V.SELECT_ELEMENT,selectOptionElement:V.SELECT_OPTION_ELEMENT,radioOptionElement:V.RADIO_OPTION_ELEMENT,inputElement:V.INPUT_ELEMENT,checkboxContainer:V.CHECKBOX_CONTAINER,hubspotHelperTextWrapper:U.HUBSPOT_HELPER_TEXT_WRAPPER,hubspotHelperTextLinks:U.HUBSPOT_HELPER_TEXT_LINKS},consentLayout:{container:z.CONTAINER,thirdPartyContainer:z.THIRD_PARTY_CONTAINER,a:z.A,p:z.P,input:``,label:``},errorLayout:{container:de.CONTAINER_DIV,title:de.ERROR_TITLE,plainText:de.PLAIN_TEXT,button:de.BUTTON},newsletterLayout:{container:B.CONTAINER,item:B.ITEM,inputContainer:B.INPUT_CONTAINER,input:``,consentContainer:B.CONTENT_CONTAINER,itemTitle:B.TITLE,itemFrequency:B.FREQUENCY,itemFrequencyA:B.FREQUENCY_A,itemFrequencyP:B.FREQUENCY_P,validationError:V.VALIDATION_ERROR_NEWSLETTER,success:{container:R.CONTAINER_DIV,thankYouTitle:R.THANKYOU_TITLE,plainText:R.PLAIN_TEXT,emphasisText:R.EMPHASIS_TEXT,button:R.BUTTON},captcha:V.CAPTCHA},spinnerLayout:{container:pe.CONTAINER,loading:pe.LOADING}},e),K=(0,w.createContext)(ct(void 0,`newsletter`)),q=()=>(0,w.useContext)(K),lt=({element:e,align:t=`center`})=>{let{base:n,formLayout:r}=(0,w.useContext)(K),i=e.elementType===`select`?r.selectLabelSpan:r.textInputLabelSpan;return M.jsxs(`label`,{style:{textAlign:t},className:G(n.label,r.label),htmlFor:e.fieldName,children:[e.label,e.isRequired&&M.jsx(`span`,{className:G(n.span,i),children:`*`})]})},ut=({element:e,handleChange:t})=>{let{base:n,formLayout:r}=(0,w.useContext)(K);return M.jsxs(M.Fragment,{children:[M.jsx(lt,{element:e}),M.jsx(`input`,{className:G(n.input,r.input),name:e.fieldName,type:e.inputType,placeholder:e.placeholder,required:e.isRequired,disabled:e.disabled,onInput:t,value:e.value||``,"data-testid":e.fieldName},e.fieldName)]})},dt=({element:e,handleChange:t})=>{let{base:n,formLayout:r}=(0,w.useContext)(K),i=e.inputType===`multiple`;return M.jsxs(M.Fragment,{children:[M.jsx(lt,{element:e}),M.jsx(`select`,{className:G(n.select,r.selectElement,i&&r.selectMultiple),name:e.fieldName,required:e.isRequired,onInput:t,multiple:i,"data-testid":e.fieldName,children:e.optionList?.map((e,t)=>{if(t===0){if(!e.value)return M.jsx(`option`,{className:G(n.option,r.selectOptionElement),value:``,children:e.displayName},t);if(e.value!==``)return M.jsxs(w.Fragment,{children:[!i&&M.jsx(`option`,{className:G(n.option,r.selectOptionElement),value:``,children:`Please select`}),M.jsx(`option`,{className:G(n.option,r.selectOptionElement),value:e.value,children:e.displayName})]},t)}return M.jsx(`option`,{className:G(n.option,r.selectOptionElement),value:e.value,children:e.displayName},t)})})]})},ft=({element:e,handleChange:t})=>e.elementType===`checkbox`&&e?.optionList?.length>0?M.jsxs(M.Fragment,{children:[M.jsx(lt,{element:e}),M.jsx(mt,{element:e,handleChange:t})]}):M.jsx(pt,{name:e.fieldName,label:e.label,value:e.value,required:e.isRequired,onChange:t}),pt=({name:e,label:t,value:n,required:r,onChange:i})=>{let{base:a,formLayout:o}=(0,w.useContext)(K);return M.jsxs(`div`,{className:o.checkboxContainer,children:[M.jsx(`input`,{className:G(a.input,a.checkbox),type:`checkbox`,onInput:i,name:e,value:n,required:r}),M.jsx(`label`,{className:a.label,htmlFor:e,dangerouslySetInnerHTML:{__html:t}},e),r&&M.jsx(`span`,{className:G(a.span,o.selectLabelSpan),children:`*`})]})},mt=({element:e,handleChange:t})=>{let{optionList:n}=e,[r,i]=w.useState([]),a=e=>{let{checked:n,value:a}=e.target,o=[];o=n?[...r,a]:r.filter(e=>e!==a),i(o),t(e,o)};return M.jsx(M.Fragment,{children:n?.map(t=>{let n=e.fieldName+`-option-`+t.displayName;return M.jsx(pt,{name:n,label:t.displayName,value:t.value,required:!1,onChange:a})})})},ht=({element:e,handleChange:t})=>{let{formLayout:n,base:r}=(0,w.useContext)(K);return M.jsxs(`div`,{style:{marginTop:5},children:[M.jsx(lt,{element:e,align:`left`}),M.jsx(`div`,{style:{marginTop:15}}),(e?.optionList)?.map((i,a)=>M.jsxs(`div`,{className:n.radioOptionElement,children:[M.jsx(`input`,{id:i.displayName,name:e.fieldName,type:`radio`,className:G(r.option,n.selectOptionElement),value:i.value,onChange:t,"data-testid":e.fieldName},a),M.jsx(`label`,{htmlFor:i.displayName,children:i.displayName})]}))]})},gt=({element:e,handleChange:t})=>e.elementType===`button`||e.isHidden?null:e.elementType===`checkbox`?M.jsx(ft,{element:e,handleChange:t}):e.elementType===`radio`?M.jsx(ht,{element:e,handleChange:t}):e.elementType!==`text`&&e.elementType!==`select`?M.jsx(ut,{element:e,handleChange:t}):e.elementType===`select`?M.jsx(dt,{element:e,handleChange:t}):M.jsx(lt,{element:e}),_t=({element:e,handleChange:t,showErrorMessages:n,showAllViolations:r,
1wideInputElements:i=[],onFocus:a,className:o})=>{var s;let{base:c,formLayout:l}=(0,w.useContext)(K);if(e.elementType===`button`)return null;let u=e=>M.jsx(`p`,{className:G(c.p,l.p),children:e.message},e.message),d=n&&(r||e.touched)&&!!((s=e?.errors)!=null&&s.length),f=G((i.includes(e.fieldName)?l.formContainerRowWide:l.formContainerRow)||`row`,o,{[l.validationErroredField]:d});return M.jsx(`div`,{className:f,onFocus:a,children:M.jsxs(`div`,{className:G(e.classNames),children:[M.jsx(gt,{element:e,handleChange:t}),d&&(e?.errors)?.map(u)]})})},vt=e=>typeof e==`object`?e:[e],yt=(e,t)=>Ot(e,t),bt=(e,t)=>!yt(e,t),xt=(e,t)=>e.indexOf(t)>-1,St=(e,t)=>!xt(e,t),Ct=(e,t)=>e<t,wt=(e,t,n)=>t<e&&e<n,Tt=(e,t,n)=>!wt(e,t,n),Et=(e,t)=>vt(e)?.some(e=>vt(t).indexOf(e)>=0),Dt=(e,t)=>!Et(e,t),Ot=(e,t)=>JSON.stringify([...vt(e)].sort())===JSON.stringify([...vt(t)].sort()),kt={EQ:yt,NEQ:bt,CONTAINS:xt,DOESNT_CONTAIN:St,STR_STARTS_WITH:(e,t)=>e.substring(0,t.length)===t,STR_ENDS_WITH:(e,t)=>e.slice(-t.length)===t,LT:Ct,LTE:(e,t)=>e<=t,GT:(e,t)=>e>t,GTE:(e,t)=>e>=t,BETWEEN:wt,NOT_BETWEEN:Tt,WITHIN_TIME_REVERSE:Ct,WITHIN_TIME:(e,t)=>t<e&&e<=new Date,SET_ALL:(e,t)=>vt(e)?.every(e=>t.indexOf(e)>=0),SET_ANY:Et,SET_NOT_ANY:Dt,SET_EQ:Ot,SET_NEQ:(e,t)=>!Ot(e,t),IS_NOT_EMPTY:e=>e.length===void 0?!!e:!!e.length},At=(e,t)=>{let n=!0;return t?.forEach(t=>{let r=typeof kt[t.operator]==`function`?kt[t.operator]:()=>!1;n&&=r(e,t.strValue)||r(e,t.strValues)||r(e,t.numberValue)||r(e,t.numberValue)}),n},jt=[`SQ_PPC-A01`,`SQ_PPC-A02`,`SQ_PPC-A03`,`SQ_PPC-A04`,`SQ_PPC-A05`,`SQ_PPC-A06`,`SQ_PPC-A07`,`SQ_PPC-A08`,`SQ_PPC-A09`,`SQ_PPC-A10`,`SQ_PPC-A11`,`SQ_PPC-A12`,`SQ_PPC-A13`,`SQ_PPC-A14`,`SQ_PPC-A15`,`SQ_PPC-A16`],Mt=[`PC_LIC-02`,`PC_LIC-08`,`PC_LIC-10`,`PC_LIC-11`,`PC_LIC-12`,`PC_LIC-13`,`PC_LIC-15`,`PC_LIC-16`,`PC_LIC-17`,`PC_LIC-18`,`PC_LIC-19`,`PC_LIC-21`,`PC_LIC-22`,`PC_LIC-25`,`PC_LIC-27`,`PC_LIC-28`,`PC_LIC-30`,`PC_LIC-31`,`PC_LIC-32`,`PC_LIC-33`,`PC_LIC-34`],Nt=(e,t)=>{if(!e||!t)return;let n=t.optionList;e.fieldName===`industry`&&(t.fieldName===`PPC_PropertyCategory`||t.fieldName===`PC_ProductCategory`)&&(e.value===`NOB_LCNSOR`||e.value===`NOB_CSLCSNG`?(n=n.filter(e=>jt.includes(e.value)),t.optionList=n):(n=n.filter(e=>Mt.includes(e.value)),t.optionList=n))},Pt=new et,Ft=({elements:e,showErrorMessages:t,showAllViolations:n,onChange:r,siteId:i,handleCountryChange:a,wideInputElemets:o=[]})=>{let{base:s,formLayout:c}=q(),l=(0,w.useState)(0)[1],u=e=>e.validations?.some(({type:e})=>e===`IsRequiredCondition`),d=e=>{var t;return Be(i).includes(e.fieldName)&&!((t=e.validations)!=null&&t.some(e=>e.type===`IsRequiredCondition`))},f=e=>({checkbox:[c.checkbox],checkboxes:[c.checkbox],select:[c.select],radio:[s.radio]})[e.elementType]||[c.textInput],p=()=>e.reduce((e,t)=>{var n;let r=e.set(t.fieldName,{...t,isRequired:u(t),classNames:f(t),isHidden:d(t)});if((n=t.dependentElements)!=null&&n.length)for(let{element:n}of t.dependentElements)e.set(n.fieldName,{...n,isRequired:!1,classNames:f(t),isHidden:!0,validations:[]});return r},new Map),m=(0,w.useMemo)(()=>e.map(e=>e.fieldName).sort().join(`,`),[e]),h=(0,w.useMemo)(()=>p(),[m]),g=e=>({...e,classNames:f(e),isHidden:!0,isRequired:!1,value:``,validations:[]}),_=(e,t)=>{let{currentTarget:n}=e,r=``,o=h,s=n.name,c=h.get(s);if(t&&(s=n.name.split(`-option-`)[0],c=h.get(s)),!c)throw Error(`FormBuilder: Element with name ${n.name} not found`);c.elementType!==`radio`&&e.preventDefault(),r=c.elementType===`select`&&c.inputType===`multiple`?Array.from(n?.selectedOptions,e=>e.value).join(`;`):n.value,c.elementType===`select`&&c.fieldName.toLowerCase()===`country`&&a&&a(r),c.elementType===`checkbox`&&(r=``+n?.checked),t&&t.length>0&&(r=t.join(`|`)),t&&!(t!=null&&t.length)&&(r=``),c.elementType===`radio`&&(r=n.value),c.errors=Pt.validateFormField(r,c,i),c.value=r,c.touched=!0,h.set(s,c);let d=c?.dependentElements||[];for(let{element:e}of d){let t=g(e);o.set(e.fieldName,t)}let p=d.filter(({filters:e})=>e.some(({strValues:e})=>e.includes(r)));for(let{formFieldAction:e,element:t,filters:n}of p){let i=g(t);e===F.DISPLAY&&(i.classNames=f(t),i.isHidden=!At(r,n),i.isRequired=u(t),i.validations=t.validations,Nt(c,i)),o.set(t.fieldName,i)}l(Date.now()),v()},v=()=>{if(!e.length){r([],[]);return}for(let[e,t]of Array.from(h.entries())){let n=Pt.validateFormField(t.value||``,t,i);n.length>0&&h.set(e,{...t,errors:n})}let t=Array.from(h.values()).map(e=>({htmlName:e.fieldName,value:e.value||``,touched:!!e.touched,violations:e.errors?.map(t=>`${e.label}: ${t.message}`)||[]}));
1l(Date.now()),r(t,Array.from(h.values()))};(0,w.useEffect)(()=>{v()},[m]);let y=Array.from(h);return M.jsxs(`div`,{className:c.formContainer,children:[y.map(([e,r],i)=>!r.isHidden&&r.inputType!==`hidden`&&M.jsx(_t,{showAllViolations:n,element:r,handleChange:_,showErrorMessages:!!t,wideInputElements:o},e||String(i))),y.map(([,e],t)=>e.fieldName===`grab_text_to_display`&&M.jsxs(`div`,{className:c.hubspotHelperTextWrapper,children:[M.jsxs(`p`,{children:[`I can withdraw my consent and unsubscribe at any time by e-mailing`,` `,M.jsxs(`a`,{className:c.hubspotHelperTextLinks,href:`https://mail.google.com/mail/?view=cm&fs=1&[email protected]`,children:[`[email protected].`,` `]}),`I acknowledge`,` `,M.jsxs(`a`,{className:c.hubspotHelperTextLinks,href:`https://www.thermofisher.com/hu/en/home/global/privacy-policy/legal-entities.html`,children:[`Thermo Fisher Scientific`,` `]}),` `,`(including its affiliates) will process my Personal Information according to its`,` `,M.jsx(`a`,{className:c.hubspotHelperTextLinks,href:`https://www.thermofisher.com/hu/en/home/global/privacy-policy.html#tfs_corp`,children:`Privacy policy`}),` `,`, which includes information about my rights.`]}),M.jsxs(`p`,{children:[`By submitting this form, you agree to BioProcess International's`,` `,M.jsx(`a`,{className:c.hubspotHelperTextLinks,href:`https://bioprocessintl.com/privacy-policy/?__hstc=251652889.2210c1268a7583985068da06b0fab63e.1702226753936.1708619750110.1708680249237.10&__hssc=251652889.1.1708680249237&__hsfp=3475455948`,children:`Privacy Policy`})]})]},`fm-`+t))]})},It=()=>M.jsxs(`div`,{style:ue,"aria-hidden":`true`,children:[M.jsx(`label`,{htmlFor:ce,children:`Website`}),M.jsx(`input`,{"data-eln-honeypot":!0,id:ce,name:se,type:`text`,autoComplete:`off`,tabIndex:-1,defaultValue:``})]}),Lt=e=>e.querySelector(le)?.value??``,Rt=(e,t)=>{let n=`{email}`;return t?e&&t?.includes(n)?t?.replace(n,e):t:``};function zt({email:e,returnFunction:t,successVerbiage:n}){let{base:r,newsletterLayout:{success:i}}=q(),a=Rt(e,n?.successPageSummary);return M.jsxs(`div`,{className:i.container,children:[M.jsx(`h1`,{className:G(r.h1,i.thankYouTitle),children:n.successPageTitle}),M.jsx(`p`,{className:G(r.p,i.plainText),children:a}),M.jsx(`button`,{onClick:()=>t(),className:G(r.button,i.button),children:`return to site`})]})}function Bt({newsletters:e=[],changeHandler:t,showInvalidErrorMessage:n=!1}){let{base:r,newsletterLayout:i}=q();return M.jsxs(`div`,{className:i.container,children:[e.map((e,n)=>M.jsxs(`div`,{className:i.item,children:[M.jsx(`div`,{className:i.inputContainer,children:M.jsx(`input`,{className:G(r.input,r.checkbox,i.input),type:`checkbox`,value:e.newsletter_code,name:`newsletterList`,onInput:t,"data-title":e.title})}),M.jsxs(`div`,{className:i.consentContainer,children:[M.jsxs(`p`,{className:r.p,children:[M.jsx(`span`,{className:G(r.span,i.itemTitle),children:e.title}),e.newsletter_description]}),M.jsxs(`div`,{className:i.itemFrequency,children:[M.jsx(`p`,{className:G(r.p,i.itemFrequencyP),children:e.frequency_description}),M.jsx(`a`,{className:G(r.a,i.itemFrequencyA),href:e.sample_url.href,target:`_blank`,rel:`noreferrer`,children:e.sample_url.title})]})]})]},n)),n&&M.jsx(`div`,{className:i.validationError,children:M.jsx(`p`,{className:r.p,children:`Please ensure at least one newsletter is selected and no errors are displayed`})})]})}var J=(e=>(e.categoryA=`A`,e.categoryB=`B`,e.categoryC=`C`,e.categoryD=`D`,e))(J||{}),Vt=class{constructor(){this.countryCodesCategoryA=[`AT`,`BE`,`CY`,`CZ`,`DK`,`DE`,`GR`,`IT`,`LT`,`MT`,`NL`,`NO`,`PL`,`PT`,`RO`,`SK`,`CH`,`ES`,`CA`,`KR`,`BG`],this.countryCodesCategoryB=[`HR`,`FR`,`IE`,`SI`,`JP`],this.countryCodesCategoryC=[`EE`,`FI`,`HU`,`IL`,`LV`,`LU`,`UA`,`SE`,`GB`,`BR`,`MX`,`ZA`],this.getCategoryByCountryCode=e=>{if(e){if(this.countryCodesCategoryA.includes(e))return`A`;if(this.countryCodesCategoryB.includes(e))return`B`;if(this.countryCodesCategoryC.includes(e))return`C`}return`D`},this.getOptOutMessage=({base:e,consentLayout:t},n)=>M.jsxs(M.Fragment,{children:[`You can opt out of receiving these messages `,n===`D`?``:`from Informa`,` at any time by clicking unsubscribe or contacting us. You can find more information in our\xA0`,M.jsx(`a`,{className:G(e.a,t.a),href:`https://www.informa.com/privacy-policy/`,target:`_blank`,rel:`noreferrer`,children:`Privacy Policy`}),`.`]}
1),this.getFirstConsentValue=(e,t,n)=>{if(!e)return!1;switch(this.getCategoryByCountryCode(e)){case`A`:return n&&!t?!0:t===`CR_OPTIN`;case`B`:case`C`:return t!==`CR_OPTOUT`;case`D`:return!0;default:return t===`CR_OPTIN`}},this.getThirdConsentValue=(e,t)=>{if(!e)return!1;switch(this.getCategoryByCountryCode(e)){case`A`:return t!==`CR_OPTOUT`;case`D`:return!0;case`C`:return t!==`CR_OPTOUT`;default:return t===`CR_OPTIN`}}}getValueByElement(e){switch(e.type){case`checkbox`:let t=e.value;return e.checked?t:t===`CR_OPTOUT`?`CR_OPTIN`:`CR_OPTOUT`;case`radio`:return e.value}return``}getFirstPartyTouchedValue(e,t){let n=this.getCategoryByCountryCode(t);return e.type===`checkbox`&&(n===`B`||n===`C`)||e.checked}},Ht=new Vt;function Ut(e){let t=q();if(e!=null&&e.countryCode){let{base:n,consentLayout:r}=t,i=Ht.getCategoryByCountryCode(e.countryCode),a=Ht.getOptOutMessage(t,i);return i===J.categoryA?M.jsxs(`div`,{className:r.container,"data-testid":`first-party-consent`,children:[M.jsx(`p`,{className:G(n.p,r.p),children:`We’d like to keep in touch to send your news and promotions from Informa about products and services relevant to you. These may include information from our selected partners however, we will not share your details unless you agree to us doing so directly.`}),M.jsxs(`label`,{className:G(n.label,r.label),children:[M.jsx(`input`,{className:G(n.input,n.radio),type:`radio`,value:`CR_OPTIN`,name:`consent`,required:!0,onInput:e.changeHandler,"data-testid":`checkbox-consent`,defaultChecked:e.defaultCheckedYes||!1}),`Yes`]}),M.jsxs(`label`,{className:G(n.label,r.label),children:[M.jsx(`input`,{className:G(n.input,n.radio),type:`radio`,value:`CR_OPTOUT`,name:`consent`,onInput:e.changeHandler}),`No`]}),e.hideConsentContent?M.jsx(M.Fragment,{}):M.jsx(`p`,{className:G(n.p,r.p),children:a}),e.error&&M.jsx(`p`,{className:G(n.p,r.p),children:ye})]}):i===J.categoryB||i===J.categoryC?M.jsxs(`div`,{className:r.container,"data-testid":`first-party-consent`,children:[M.jsxs(`label`,{className:G(n.label,r.label),children:[M.jsx(`input`,{className:G(n.input,n.checkbox,r.input),type:`checkbox`,value:`CR_OPTOUT`,name:`consent`,onInput:e.changeHandler,"data-testid":`checkbox-consent`}),M.jsxs(`p`,{className:G(n.p,r.p),children:[`Tick here if you `,M.jsx(`b`,{children:`do not want`}),` news and promotions from Informa about products and services relevant to you. These may include information from our selected partners however, we will not share your details unless you agree to us doing so directly.`]})]}),e.hideConsentContent?M.jsx(M.Fragment,{}):a]}):M.jsxs(`div`,{className:r.container,"data-testid":`first-party-consent`,children:[M.jsx(`p`,{className:G(n.p,r.p),children:`By continuing you agree that Informa may contact you with updates about products and services relevant to you. These may include information from our selected partners.`}),e.hideConsentContent?M.jsx(M.Fragment,{}):M.jsxs(M.Fragment,{children:[M.jsx(`p`,{className:G(n.p,r.p),children:a}),M.jsxs(`label`,{className:G(n.label,r.label),children:[`I agree to the`,` `,M.jsx(`a`,{className:G(n.a,r.a),href:`https://www.informa.com/privacy-policy/`,target:`_blank`,rel:`noreferrer`,children:`Privacy Policy`})]})]})]})}return null}function Wt(){let{spinnerLayout:e}=q();return M.jsx(`div`,{className:e.container,children:M.jsx(`div`,{className:e.loading})})}function Gt({title:e,message:t,returnFunction:n}){let{base:r,errorLayout:i}=q();return M.jsxs(`div`,{className:i.container,children:[M.jsx(`h1`,{className:G(r.h1,i.title),children:e}),M.jsx(`p`,{className:G(r.p,i.plainText),children:t}),M.jsx(`button`,{className:G(r.button,i.button),onClick:()=>n(),children:`return to site`})]})}var Kt=(e,...t)=>{console.log(`component message: `,e,t)},qt=({validationErrors:e=[],otherErrors:t=[]})=>{let{base:n,formLayout:r}=(0,w.useContext)(K),i=[...e,...t];return i.length?M.jsx(`div`,{className:r.validationHeader,"data-testid":`validation-error-box`,children:i.map((e,t)=>M.jsx(`p`,{className:n.p,children:e},t))}):M.jsx(M.Fragment,{})};function Y(e){if(e===void 0)throw ReferenceError(`this hasn't been initialised - super() hasn't been called`);return e}function Jt(e,t){return Jt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Jt(e,t)}function Yt(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Jt(e,t)}var Xt=Object.defineProperty,Zt=Object.defineProperties,Qt=Object.getOwnPropertyDescriptors,$t=Object.getOwnPropertySymbols,en=Object.prototype.hasOwnProperty,tn=Object.prototype.propertyIsEnumerable,nn=(e,t,n)=>t in e?Xt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,X=(e,t)=>{for(var n in t||={})en.call(t,n)&&nn(e,n,t[n]);if($t)for(var n of $t(t))tn.call(t,n)&&nn(e,n,t[n]);return e},rn=(e,t)=>Zt(e,Qt(t)),an=(e,t)=>{var n={};
1for(var r in e)en.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&$t)for(var r of $t(e))t.indexOf(r)<0&&tn.call(e,r)&&(n[r]=e[r]);return n},Z=(e,t,n)=>(nn(e,typeof t==`symbol`?t:t+``,n),n),on=(e,t,n)=>new Promise((r,i)=>{var a=e=>{try{s(n.next(e))}catch(e){i(e)}},o=e=>{try{s(n.throw(e))}catch(e){i(e)}},s=e=>e.done?r(e.value):Promise.resolve(e.value).then(a,o);s((n=n.apply(e,t)).next())}),sn=`hCaptcha-script`,cn=`hCaptchaOnLoad`,ln=`script-error`,un=`@hCaptcha/loader`;function dn(e){return Object.entries(e).filter(([,e])=>e||e===!1).map(([e,t])=>`${encodeURIComponent(e)}=${encodeURIComponent(String(t))}`).join(`&`)}function fn(e){let t=e&&e.ownerDocument||document;return{document:t,window:t.defaultView||t.parentWindow||window}}function pn(e){return e||document.head}function mn(e){e.setTag(`source`,un),e.setTag(`url`,document.URL),e.setContext(`os`,{UA:navigator.userAgent}),e.setContext(`browser`,X({},hn())),e.setContext(`device`,rn(X({},gn()),{screen_width_pixels:screen.width,screen_height_pixels:screen.height,language:navigator.language,orientation:screen.orientation?.type||`Unknown`,processor_count:navigator.hardwareConcurrency,platform:navigator.platform}))}function hn(){let e=navigator.userAgent,t,n;return e.indexOf(`Firefox`)===-1?e.indexOf(`Edg`)===-1?e.indexOf(`Chrome`)!==-1&&e.indexOf(`Safari`)!==-1?(t=`Chrome`,
1n=e.match(/Chrome\/([\d.]+)/)?.[1]):e.indexOf(`Safari`)!==-1&&e.indexOf(`Chrome`)===-1?(t=`Safari`,n=e.match(/Version\/([\d.]+)/)?.[1]):e.indexOf(`Opera`)!==-1||e.indexOf(`OPR`)!==-1?(t=`Opera`,n=e.match(/(Opera|OPR)\/([\d.]+)/)?.[2]):e.indexOf(`MSIE`)!==-1||e.indexOf(`Trident`)!==-1?(t=`Internet Explorer`,n=e.match(/(MSIE |rv:)([\d.]+)/)?.[2]):(t=`Unknown`,n=`Unknown`):(t=`Microsoft Edge`,n=e.match(/Edg\/([\d.]+)/)?.[1]):(t=`Firefox`,n=e.match(/Firefox\/([\d.]+)/)?.[1]),{name:t,version:n}}function gn(){let e=navigator.userAgent,t;t=e.indexOf(`Win`)===-1?e.indexOf(`Mac`)===-1?e.indexOf(`Linux`)===-1?e.indexOf(`Android`)===-1?e.indexOf(`like Mac`)!==-1||e.indexOf(`iPhone`)!==-1||e.indexOf(`iPad`)!==-1?`iOS`:`Unknown`:`Android`:`Linux`:`Mac`:`Windows`;let n;return n=/Mobile|iPhone|iPod|Android/i.test(e)?`Mobile`:/Tablet|iPad/i.test(e)?`Tablet`:`Desktop`,{model:t,family:t,device:n}}var _n=class e{constructor(e){Z(this,`_parent`),Z(this,`breadcrumbs`,[]),Z(this,`context`,{}),Z(this,`extra`,{}),Z(this,`tags`,{}),Z(this,`request`),Z(this,`user`),this._parent=e}get parent(){return this._parent}child(){return new e(this)}setRequest(e){return this.request=e,this}removeRequest(){return this.request=void 0,this}addBreadcrumb(e){return typeof e.timestamp>`u`&&(e.timestamp=new Date().toISOString()),this.breadcrumbs.push(e),this}setExtra(e,t){return this.extra[e]=t,this}removeExtra(e){return delete this.extra[e],this}setContext(e,t){return typeof t.type>`u`&&(t.type=e),this.context[e]=t,this}removeContext(e){return delete this.context[e],this}setTags(e){return this.tags=X(X({},this.tags),e),this}setTag(e,t){return this.tags[e]=t,this}removeTag(e){return delete this.tags[e],this}setUser(e){return this.user=e,this}removeUser(){return this.user=void 0,this}toBody(){let e=[],t=this;for(;t;)e.push(t),t=t.parent;return e.reverse().reduce((e,t)=>(e.breadcrumbs=[...e.breadcrumbs??[],...t.breadcrumbs],e.extra=X(X({},e.extra),t.extra),e.contexts=X(X({},e.contexts),t.context),e.tags=X(X({},e.tags),t.tags),t.user&&(e.user=t.user),t.request&&(e.request=t.request),e),{breadcrumbs:[],extra:{},contexts:{},tags:{},request:void 0,user:void 0})}clear(){this.breadcrumbs=[],this.context={},this.tags={},this.user=void 0}},vn=/^\s*at (?:(.*?) ?\()?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,yn=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js))(?::(\d+))?(?::(\d+))?\s*$/i,bn=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,xn=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+))?@)([\w.-]+)(?::(\d+))?\/(.+)/,Sn=`?`,Cn=`An unknown error occurred`,wn=`0.0.4`;function Tn(e){for(let t=0;t<e.length;t++)e[t]=Math.floor(Math.random()*256);return e}function Q(e){return(e+256).toString(16).substring(1)}function En(){let e=Tn(Array(16));return e[6]=e[6]&15|64,e[8]=e[8]&63|128,Q(e[0])+Q(e[1])+Q(e[2])+Q(e[3])+`-`+Q(e[4])+Q(e[5])+`-`+Q(e[6])+Q(e[7])+`-`+Q(e[8])+Q(e[9])+`-`+Q(e[10])+Q(e[11])+Q(e[12])+Q(e[13])+Q(e[14])+Q(e[15])}var Dn=[[vn,`chrome`],[bn,`winjs`],[yn,`gecko`]];function On(e){var t,n;if(!e.stack)return null;let r=[],i=(t=e.stack).split?.call(t,`
2`)??[];for(let t=0;t<i.length;++t){let a=null,o=null,s=null;for(let[e,n]of Dn)if(o=e.exec(i[t]),o){s=n;break}if(!(!o||!s)){if(s===`chrome`)a={filename:(n=o[2])!=null&&n.startsWith(`address at `)?o[2].substring(11):o[2],function:o[1]||Sn,lineno:o[3]?+o[3]:null,colno:o[4]?+o[4]:null};else if(s===`winjs`)a={filename:o[2],function:o[1]||Sn,lineno:+o[3],colno:o[4]?+o[4]:null};else if(s===`gecko`)t===0&&!o[5]&&e.columnNumber!==void 0&&r.length>0&&(r[0].column=e.columnNumber+1),a={filename:o[3],function:o[1]||Sn,lineno:o[4]?+o[4]:null,colno:o[5]?+o[5]:null};else continue;!a.function&&a.lineno&&(a.function=Sn),r.push(a)}}return r.length?r.reverse():null}function kn(e){let t=On(e);return{type:e.name,value:e.message,stacktrace:{frames:t??[]}}}function An(e){let t=xn.exec(e),n=t?t.slice(1):[];if(n.length!==6)throw Error(`Invalid DSN`);let r=n[5].split(`/`),i=r.slice(0,-1).join(`/`);
2return n[0]+`://`+n[3]+(n[4]?`:`+n[4]:``)+(i?`/`+i:``)+`/api/`+r.pop()+`/envelope/?sentry_version=7&sentry_key=`+n[1]+(n[2]?`&sentry_secret=`+n[2]:``)}function jn(e,t,n){let r=X({event_id:En().replaceAll(`-`,``),platform:`javascript`,sdk:{name:`@hcaptcha/sentry`,version:wn},environment:t,release:n,timestamp:Date.now()/1e3},e.scope.toBody());if(e.type===`exception`){r.message=e.error?.message??`Unknown error`,r.fingerprint=[r.message];let t=[],n=e.error;for(let e=0;e<5&&n&&(t.push(kn(n)),!(!n.cause||!(n.cause instanceof Error)));e++)n=n.cause;r.exception={values:t.reverse()}}return e.type===`message`&&(r.message=e.message,r.level=e.level),r}function Mn(e){if(e instanceof Error)return e;if(typeof e==`string`)return Error(e);if(typeof e==`object`&&e&&!Array.isArray(e)){let t=e,{message:n}=t,r=an(t,[`message`]),i=Error(typeof n==`string`?n:Cn);return Object.assign(i,r)}let t=Error(Cn);return Object.assign(t,{cause:e})}function Nn(e,t,n){return on(this,null,function*(){try{if(typeof fetch<`u`&&typeof AbortSignal<`u`){let r;if(n){let e=new AbortController;r=e.signal,setTimeout(()=>e.abort(),n)}let i=yield fetch(e,rn(X({},t),{signal:r})),a=yield i.text();return{status:i.status,body:a}}return yield new Promise((r,i)=>{let a=new XMLHttpRequest;if(a.open(t?.method??`GET`,e),a.onload=()=>r({status:a.status,body:a.responseText}),a.onerror=()=>i(Error(`XHR Network Error`)),t?.headers)for(let[e,n]of Object.entries(t.headers))a.setRequestHeader(e,n);if(n){let e=setTimeout(()=>{a.abort(),i(Error(`Request timed out`))},n);a.onloadend=()=>{clearTimeout(e)}}a.send((t?.body)?.toString())})}catch(e){return{status:0,body:(e?.toString)?.call(e)??`Unknown error`}}})}var $,Pn=($=class{constructor(e){Z(this,`apiURL`),Z(this,`dsn`),Z(this,`environment`),Z(this,`release`),Z(this,`sampleRate`),Z(this,`debug`),Z(this,`_scope`),Z(this,`shouldBuffer`,!1),Z(this,`bufferlimit`,20),Z(this,`buffer`,[]),this.environment=e.environment,this.release=e.release,this.sampleRate=e.sampleRate??1,this.debug=e.debug??!1,this._scope=e.scope??new _n,this.apiURL=An(e.dsn),this.dsn=e.dsn,this.shouldBuffer=e.buffer??!1,this.bufferlimit=e.bufferLimit??20}static init(e){$._instance||($._instance=new $(e))}static get instance(){if(!$._instance)throw Error(`Sentry has not been initialized`);return $._instance}log(...e){this.debug&&console.log(...e)}get scope(){return this._scope}static get scope(){return $.instance.scope}withScope(e){e(this._scope.child())}static withScope(e){$.instance.withScope(e)}captureException(e,t){this.captureEvent({type:`exception`,level:`error`,error:Mn(e),scope:t??this._scope})}static captureException(e,t){$.instance.captureException(e,t)}captureMessage(e,t=`info`,n){this.captureEvent({type:`message`,level:t,message:e,scope:n??this._scope})}static captureMessage(e,t=`info`,n){$.instance.captureMessage(e,t,n)}captureEvent(e){if(Math.random()>=this.sampleRate){this.log(`Dropped event due to sample rate`);return}if(this.shouldBuffer){if(this.buffer.length>=this.bufferlimit)return;this.buffer.push(e)}else this.sendEvent(e)}sendEvent(e,t=5e3){return on(this,null,function*(){try{this.log(`Sending sentry event`,e);let n=jn(e,this.environment,this.release),r={event_id:n.event_id,dsn:this.dsn},i=JSON.stringify(r)+`
3`+JSON.stringify({type:`event`})+`
4`+JSON.stringify(n),a=yield Nn(this.apiURL,{method:`POST`,headers:{"Content-Type":`application/x-sentry-envelope`},body:i},t);this.log(`Sentry response`,a.status),a.status!==200&&(console.log(a.body),console.error(`Failed to send event to Sentry`,a))}catch(e){console.error(`Failed to send event`,e)}})}flush(e=5e3){return on(this,null,function*(){try{this.log(`Flushing sentry events`,this.buffer.length);let t=this.buffer.splice(0,this.buffer.length).map(t=>this.sendEvent(t,e));yield Promise.all(t),this.log(`Flushed all events`)}catch(e){console.error(`Failed to flush events`,e)}})}static flush(e=5e3){return $.instance.flush(e)}static reset(){$._instance=void 0}},Z($,`_instance`),$),Fn=`https://[email protected]/6`,In=`2.0.0`,Ln=`production`;function Rn(e=!0){if(!e)return zn();Pn.init({dsn:Fn,release:In,environment:Ln});let t=Pn.scope;return mn(t),zn(t)}function zn(e=null){return{addBreadcrumb:t=>{e&&e.addBreadcrumb(t)},captureRequest:t=>
4{e&&e.setRequest(t)},captureException:t=>{e&&Pn.captureException(t,e)}}}function Bn({scriptLocation:e,query:t,loadAsync:n=!0,crossOrigin:r,apihost:i=`https://js.hcaptcha.com`,cleanup:a=!0,secureApi:o=!1,scriptSource:s=``}={},c){let l=pn(e),u=fn(l);return new Promise((e,d)=>{let f=u.document.createElement(`script`);f.id=sn,f.src=s?`${s}?onload=${cn}`:o?`${i}/1/secure-api.js?onload=${cn}`:`${i}/1/api.js?onload=${cn}`,f.crossOrigin=r,f.async=n;let p=(e,t)=>{try{!o&&a&&l.removeChild(f),t(e)}catch(e){d(e)}};f.onload=t=>p(t,e),f.onerror=e=>{c&&c(f.src),p(e,d)},f.src+=t===``?``:`&${t}`,l.appendChild(f)})}var Vn=[];function Hn(e={cleanup:!0},t){try{t.addBreadcrumb({category:un,message:`hCaptcha loader params`,data:e});let n=fn(pn(e.scriptLocation)),r=Vn.find(({scope:e})=>e===n.window);if(r)return t.addBreadcrumb({category:un,message:`hCaptcha already loaded`}),r.promise;let i=new Promise((i,a)=>on(this,null,function*(){try{n.window[cn]=()=>{t.addBreadcrumb({category:un,message:`hCaptcha script called onload function`}),i(n.window.hcaptcha)},yield Bn(X({query:dn({custom:e.custom,render:e.render,sentry:e.sentry,assethost:e.assethost,imghost:e.imghost,reportapi:e.reportapi,endpoint:e.endpoint,host:e.host,recaptchacompat:e.recaptchacompat,hl:e.hl})},e),e=>{t.captureRequest({url:e,method:`GET`})}),t.addBreadcrumb({category:un,message:`hCaptcha loaded`,data:r})}catch{t.addBreadcrumb({category:un,message:`hCaptcha failed to load`});let e=Vn.findIndex(e=>e.scope===n.window);e!==-1&&Vn.splice(e,1),a(Error(ln))}}));return Vn.push({promise:i,scope:n.window}),i}catch(e){return t.captureException(e),Promise.reject(Error(ln))}}function Un(e,t,n=0){return on(this,null,function*(){let r=n<2?`Retry loading hCaptcha Api`:`Exceeded maximum retries`;try{return yield Hn(e,t)}catch(i){return t.addBreadcrumb({category:un,message:r}),n>=2?(t.captureException(i),Promise.reject(i)):(n+=1,Un(e,t,n))}})}function Wn(){return on(this,arguments,function*(e={}){return yield Un(e,Rn(e.sentry))})}function Gn(e){var t=e&&e.ownerDocument||document;return{document:t,window:t.defaultView||t.parentWindow||window}}function Kn(e){return e||document.head}var qn=function(e){Yt(t,e);function t(t){var n;return n=e.call(this,t)||this,n._hcaptcha=void 0,n.renderCaptcha=n.renderCaptcha.bind(Y(n)),n.resetCaptcha=n.resetCaptcha.bind(Y(n)),n.removeCaptcha=n.removeCaptcha.bind(Y(n)),n.isReady=n.isReady.bind(Y(n)),n._onReady=null,n.loadCaptcha=n.loadCaptcha.bind(Y(n)),n.handleOnLoad=n.handleOnLoad.bind(Y(n)),n.handleSubmit=n.handleSubmit.bind(Y(n)),n.handleExpire=n.handleExpire.bind(Y(n)),n.handleError=n.handleError.bind(Y(n)),n.handleOpen=n.handleOpen.bind(Y(n)),n.handleClose=n.handleClose.bind(Y(n)),n.handleChallengeExpired=n.handleChallengeExpired.bind(Y(n)),n.ref=w.createRef(),n.apiScriptRequested=!1,n.sentryHub=null,n.captchaId=``,n.state={isApiReady:!1,isRemoved:!1,elementId:t.id},n}var n=t.prototype;return n.componentDidMount=function(){var e=this,t=Gn(Kn(this.props.scriptLocation));if(this._hcaptcha=t.window.hcaptcha||void 0,typeof this._hcaptcha<`u`){this.setState({isApiReady:!0},function(){e.renderCaptcha()});return}this.loadCaptcha()},n.componentWillUnmount=function(){var e=this._hcaptcha,t=this.captchaId;this.isReady()&&(e.reset(t),e.remove(t))},n.shouldComponentUpdate=function(e,t){return this.state.isApiReady===t.isApiReady&&this.state.isRemoved===t.isRemoved},n.componentDidUpdate=function(e){var t=this;[`sitekey`,`size`,`theme`,`tabindex`,`languageOverride`,`endpoint`].every(function(n){return e[n]===t.props[n]})||this.removeCaptcha(function(){t.renderCaptcha()})},n.loadCaptcha=function(){if(!this.apiScriptRequested){var e=this.props,t=e.apihost,n=e.assethost,r=e.endpoint,i=e.host,a=e.imghost,o=e.languageOverride,s=e.reCaptchaCompat,c=e.reportapi,l=e.sentry,u=e.custom,d=e.loadAsync,f=e.scriptLocation,p=e.scriptSource,m=e.secureApi,h=e.cleanup;Wn({render:`explicit`,apihost:t,assethost:n,endpoint:r,hl:o,host:i,imghost:a,recaptchacompat:s===!1?`off`:null,reportapi:c,sentry:l,custom:u,loadAsync:d,scriptLocation:f,scriptSource:p,secureApi:m,cleanup:h===void 0||h}).then(this.handleOnLoad,this.handleError).catch(this.handleError),this.apiScriptRequested=!0}},n.renderCaptcha=function(e){var t=this,n=this.props.onReady,r=this.state.isApiReady,i=this.captchaId;
4if(!(!r||i)){var a=Object.assign({"open-callback":this.handleOpen,"close-callback":this.handleClose,"error-callback":this.handleError,"chalexpired-callback":this.handleChallengeExpired,"expired-callback":this.handleExpire,callback:this.handleSubmit},this.props,{hl:this.props.hl||this.props.languageOverride,languageOverride:void 0}),o=this._hcaptcha.render(this.ref.current,a);this.captchaId=o,this.setState({isRemoved:!1},function(){e&&e(),n&&n(),t._onReady&&t._onReady(o)})}},n.resetCaptcha=function(){var e=this._hcaptcha,t=this.captchaId;this.isReady()&&e.reset(t)},n.removeCaptcha=function(e){var t=this,n=this._hcaptcha,r=this.captchaId;this.isReady()&&this.setState({isRemoved:!0},function(){t.captchaId=``,n.remove(r),e&&e()})},n.handleOnLoad=function(){var e=this;this.setState({isApiReady:!0},function(){e._hcaptcha=Gn(Kn(e.props.scriptLocation)).window.hcaptcha,e.renderCaptcha(function(){var t=e.props.onLoad;t&&t()})})},n.handleSubmit=function(e){var t=this.props.onVerify,n=this.state.isRemoved,r=this._hcaptcha,i=this.captchaId;if(!(typeof r>`u`||n)){var a=r.getResponse(i),o=r.getRespKey(i);t&&t(a,o)}},n.handleExpire=function(){var e=this.props.onExpire,t=this._hcaptcha,n=this.captchaId;this.isReady()&&(t.reset(n),e&&e())},n.handleError=function(e){var t=this.props.onError,n=this._hcaptcha,r=this.captchaId;this.isReady()&&n.reset(r),t&&t(e)},n.isReady=function(){var e=this.state,t=e.isApiReady,n=e.isRemoved;return t&&!n},n.handleOpen=function(){!this.isReady()||!this.props.onOpen||this.props.onOpen()},n.handleClose=function(){!this.isReady()||!this.props.onClose||this.props.onClose()},n.handleChallengeExpired=function(){!this.isReady()||!this.props.onChalExpired||this.props.onChalExpired()},n.execute=function(e){var t=this;e===void 0&&(e=null),e=typeof e==`object`?e:null;try{var n=this._hcaptcha,r=this.captchaId;if(!this.isReady()){var i,a=new Promise(function(n,r){t._onReady=function(i){try{var a=t._hcaptcha;e&&e.async?a.execute(i,e).then(n).catch(r):n(a.execute(i,e))}catch(e){r(e)}}});return(i=e)!=null&&i.async?a:null}return n.execute(r,e)}catch(t){return e&&e.async?Promise.reject(t):null}},n.close=function(){var e=this._hcaptcha,t=this.captchaId;if(this.isReady())return e.close(t)},n.setData=function(e){var t=this._hcaptcha,n=this.captchaId;this.isReady()&&(e&&typeof e!=`object`&&(e=null),t.setData(n,e))},n.getResponse=function(){return this._hcaptcha.getResponse(this.captchaId)},n.getRespKey=function(){return this._hcaptcha.getRespKey(this.captchaId)},n.render=function(){var e=this.state.elementId;return w.createElement(`div`,{ref:this.ref,id:e})},t}(w.Component),Jn=()=>`fa44b35a-449e-425e-9a86-275625a43dc6`,Yn=({className:e,setToken:t,error:n})=>{let r=e=>t(e),{base:i,formLayout:a}=(0,w.useContext)(K),o=()=>t(void 0),s=Jn();return M.jsxs(`div`,{className:e,children:[M.jsx(qn,{sitekey:s,onVerify:r,onExpire:o}),n&&M.jsx(`p`,{className:G(i.p,a.p),children:`Captcha is invalid!`})]})},Xn=new Vt;function Zn({formId:e,newsletters:t,onCountryStateChanged:n,platformApiService:r,subscriptionState:i,subscriptionStateHandler:a,elements:o,hideFirstPartyConsent:s,hideThirdPartyConsent:c,iirisUserProfile:l,inContextValidationMessage:u,returnButtonFunction:d,sponsorName:f,isOpenOnRegister:p,completionCallback:m,successVerbiage:h}){let{base:g,formLayout:_}=q(),[v,y]=(0,w.useState)(),[b,x]=(0,w.useState)({elements:o,firstPartyConsentOption:``,firstPartyConsentTouched:!1,values:{formId:null,countryCode:``,emailAddress:l?.business_email||``,firstPartyConsent:!1,newsletterList:[],formFields:[]},showAllViolations:!1}),S=!l&&He(r.siteId);function ee(e,t){let r=e.find(e=>e.htmlName===I.COUNTRY||e.htmlName===I.MARKETO_COUNTRY)?.value||``,i=b.values.formFields?.find(e=>e.htmlName===I.STATE)?.value||``,a=e.find(e=>e.htmlName===I.STATE)?.value||``;i!==a&&n(a);let o=e.find(e=>e.htmlName===I.EMAIL_ADDRESS||e.htmlName===I.BUSINESS_EMAIL||e.htmlName===I.MARKETO_EMAIL)?.value||``;x(n=>({...n,elements:t,values:{...n.values,emailAddress:o,countryCode:r,formFields:e}}))}function te(){if(!b.values.countryCode||s||c)return!0;switch(Xn.getCategoryByCountryCode(b.values.countryCode)){case J.categoryA:return b.f
4irstPartyConsentTouched;case J.categoryB:return b.firstPartyConsentTouched;case J.categoryC:return b.firstPartyConsentTouched;case J.categoryD:return!0;default:return!0}}let ne=async t=>{if(t.preventDefault(),x(e=>({...e,showAllViolations:!0})),!te()||S&&!v)return;let n=Xn.getFirstConsentValue(b.values.countryCode,b.firstPartyConsentOption),{newsletterList:i,formFields:o}=b.values,s=i.length>0,c=o.some(({violations:e})=>e.length);if(!s||c)return;a({isSuccessful:!1,message:`Submitting data...`,status:H.PENDING});let u=l?.business_email||b.values.emailAddress,d=Lt(t.currentTarget);try{(await r.putNewslettersSubscription({emailAddress:u,formFields:o,newsletterList:b.values.newsletterList.map(e=>e.newsletter_code),firstPartyConsent:n,formId:e,honeypot:d},v,l,b.elements,p)).status===200&&(m?.({transactionInitiated:`success`,formSubmitted:`success`,submissionSucceeded:`success`}),a({isSuccessful:!0,message:`SUCCESS`,status:H.SUCCESS}))}catch(e){Kt(e),e.response?.status===409?(m?.({transactionInitiated:`success`,formSubmitted:`success`,submissionSucceeded:`failure`}),a({isSuccessful:!1,message:e.response.data,status:H.ERROR})):(m?.({transactionInitiated:`success`,formSubmitted:`failure`,submissionSucceeded:`failure`}),a({isSuccessful:!1,message:`A problem has occurred with processing your request, please wait a few minutes and try again.`,status:H.ERROR}))}},C=e=>{let t=e?.length>0;return x(e=>({...e,inValidNewsletter:!t})),t},T=e=>{let t=Xn.getCategoryByCountryCode(e);return t===J.categoryB||t===J.categoryC},E=e=>{x(t=>({...t,firstPartyConsentOption:``,firstPartyConsentTouched:T(e)}))},D=e=>{let t=e.currentTarget;t.name===I.CONSENT?k(t):t.name===I.NEWSLETTER_LIST&&O(t,e.target.dataset.title)},O=(e,t)=>{let{newsletterList:n}=b.values,r=e.checked?[...n,{newsletter_code:e.value,title:t}]:n.filter(n=>n.newsletter_code!==e.value||n.title!==t);x(e=>({...e,values:{...e.values,newsletterList:r}})),C(r)},k=e=>{let t=Xn.getValueByElement(e),n=Xn.getFirstPartyTouchedValue(e,b.values.countryCode);x(e=>({...e,firstPartyConsentOption:t,firstPartyConsentTouched:n,values:{...e.values}}))},re=e=>{let t=e.find(e=>e.elementType===`button`);return t?t.label:`Submit`},A=e=>e.includes(`Captcha is invalid!`),j=()=>{let{values:e,showAllViolations:t}=b,n=e.newsletterList.length===0&&t,r=e.formFields.filter(e=>e.touched||t).flatMap(({violations:e})=>e),i=[];return n&&i.push(`Please ensure at least one newsletter is selected and no errors are displayed`),!te()&&t&&i.push(`Please choose consent agreement`),t&&S&&!v&&i.push(`Captcha is invalid!`),{errors:r,otherErrors:i}},ie=b.values.newsletterList.length===0&&b.showAllViolations,{errors:ae,otherErrors:oe}=j(),N=o?re(o):`Subscribe`,P=i&&i.status;return P===H.ERROR?M.jsx(Gt,{title:`A problem has occurred`,message:i.message,returnFunction:d}):P===H.PENDING?M.jsx(Wt,{}):P===H.SUCCESS?M.jsx(zt,{email:l?.business_email||b.values.emailAddress,successVerbiage:h,returnFunction:d}):t?M.jsx(`div`,{className:_.container,children:M.jsxs(`form`,{noValidate:!0,className:G(g.form,_.form),onSubmit:ne,children:[M.jsx(It,{}),!u&&M.jsx(qt,{validationErrors:ae,otherErrors:oe}),M.jsx(Bt,{showInvalidErrorMessage:u&&ie,newsletters:t,changeHandler:D}),o&&M.jsx(Ft,{elements:o,onChange:ee,showAllViolations:b.showAllViolations,showErrorMessages:u,siteId:r.siteId,handleCountryChange:E}),!s&&M.jsx(Ut,{sponsorName:f,countryCode:b.values.countryCode,changeHandler:D,error:u&&b.showAllViolations&&oe.includes(be)}),M.jsxs(`div`,{className:_.submitContainer,children:[S&&M.jsx(Yn,{className:_.captchaContainer,setToken:y,error:u&&b.showAllViolations&&A(oe)}),M.jsx(`button`,{className:G(g.button,_.submit),type:`submit`,children:N})]})]})}):null}var Qn=e=>new Promise((t,n)=>{try{let r=document.createElement(`script`);Object.keys(e).forEach(t=>{r[t]=e[t]}),r.addEventListener(`load`,()=>{t({status:!0})}),r.addEventListener(`error`,()=>{n({status:!1,message:`Failed to load the script ${e.src}`})}),document.body.appendChild(r)}catch(e){n(e)}});function $n({formId:e,configs:t={},region:n=`eu1`}){return(0,w.useEffect)(()=>{let{portalId:r}=t;Qn({src:`//js-${n}.hs-scripts.com/${r}.js`,type:`text/javascript`,id:`hs-script-loader`,async:!0,defer:!0}).then(()=>{Qn({src:`//js-${n}
4.hsforms.net/forms/v2.js`,type:`text/javascript`,charset:`utf-8`}).then(()=>{window.hbspt&&window.hbspt.forms.create({region:n,portalId:r,formId:e,target:`#hubspotForm`})})})},[]),M.jsx(`div`,{style:{display:`none`},children:M.jsx(`div`,{id:`hubspotForm`})})}function er({formResponse:e}){let{formId:t,formType:n,configs:r={}}=e;return n===P.HUBSPOT?M.jsx($n,{configs:r,formId:t}):null}function tr(e){let t=new Ze(e.platformServiceBaseUrl,e.clientId,e.authorization,e.context,e.subBrandId,e.version,void 0,e.productId),[n,r]=(0,w.useState)({}),[i,a]=(0,w.useState)(e.iirisUserProfile?.state||``),[o,s]=(0,w.useState)({isSuccessful:!1,message:`PRE-SUB`,status:H.PENDING}),c=async t=>{a(t);let n={tag:e.newsletterTag||``,state:t};await p({filters:n,isRegisterEvent:e.isOpenOnRegister||!1,...e.newsletterVariant&&{newsletterVariant:e.newsletterVariant}})},l=t=>{s({isSuccessful:t.isSuccessful,message:t.message,status:t.status}),t.isSuccessful&&e.onSuccessSubscribe&&e.onSuccessSubscribe()},u=t=>{var r;let i=t?.contentStackData??n.contentStackData,a=t?.formData??n.formData;return{...Ae(),elnPackageVersion:je,formInstanceName:a?.formType||i?.formType,formHTMLName:i?.formId||``,userLoggedIn:(r=e.iirisUserProfile)!=null&&r.id?`Logged In`:`Anonymous`}},d=()=>{e.returnButtonFunction()},f=async(e,n)=>{let i=await t.getFormById(e,n,{"x-subscription-event":!0});s(e=>({...e,status:H.NEW})),r(e=>({...e,formData:i,hideFirstPartyConsent:Pe(i)}))},p=async n=>{let i=await t.getNewsletterData(n);return s(t=>({...t,status:e.iirisUserProfile?H.NEW:t.status})),r(e=>({...e,contentStackData:{formType:i.form_storage,formId:i.form_id,newsletters:i.newsletters}})),i},m=(t,n)=>{var r;(r=e.completionCallback)==null||r.call(e,{...u(n),...t})},h=async t=>{let n;try{let r={filters:{tag:e.newsletterTag||``,state:t,shouldUseAlternativeForm:e.context?.shouldUseAlternativeForm??!1,...e.newsletterVariant&&{newsletterVariant:e.newsletterVariant}},isRegisterEvent:e.isOpenOnRegister||!1};n=await p(r),n.form_id&&!e.iirisUserProfile&&await f(n.form_id,e.isOpenOnRegister)}catch(e){Kt(e),m({transactionInitiated:`failure`,formSubmitted:`failure`,submissionSucceeded:`failure`},n?{contentStackData:{formType:n.form_storage,formId:n.form_id}}:void 0),s(e=>({...e,status:H.ERROR,message:`We are having issues responding to your request! Please try again later.`}))}};(0,w.useEffect)(()=>{h(i)},[i]);let g=(0,w.useMemo)(()=>n?.formData||{},[n?.formData]),_=(0,w.useMemo)(()=>g?.attributes?.elements||[],[g?.attributes?.elements]),v=(0,w.useMemo)(()=>Le(_,e.sponsorName||``),[_,e.sponsorName]);return M.jsxs(`div`,{children:[M.jsx(er,{formResponse:g}),M.jsx(K.Provider,{value:ct(e.classNames,`newsletter`),children:M.jsx(Zn,{newsletters:n?.contentStackData?.newsletters,elements:v,platformApiService:t,subscriptionStateHandler:l,subscriptionState:o,returnButtonFunction:d,iirisUserProfile:e.iirisUserProfile,inContextValidationMessage:e.inContextValidationMessage,formId:n?.contentStackData?.formId,onCountryStateChanged:c,hideFirstPartyConsent:n.hideFirstPartyConsent,hideThirdPartyConsent:n.hideThirdPartyConsent,isOpenOnRegister:e.isOpenOnRegister,completionCallback:m,successVerbiage:e.successVerbiage})})]})}var nr=new Vt,rr={webinar:`attend the webinar`,white_paper:`download the document`,video:`watch the video`,slideshow:`play the slideshow`,article:`read the article`,recipe:`read the recipe`,multi_section_article:`read the multi-section article`,publication_issue:`read the publication issue`,podcast:`listen to the podcast`,enhanced_list_landing_page:`view the Enhanced List`,enhanced_list_child_page:`view the Enhanced List`};function ir({changeHandler:e,contentType:t,countryCode:n,error:r,sponsorName:i=`the Sponsors mentioned above`}){let a=q(),{base:o,consentLayout:s,formLayout:c}=a,l=rr?.[t?.toLowerCase()]||`access this content`,u=nr.getCategoryByCountryCode(n),d=nr.getOptOutMessage(a,u),f=G(s.thirdPartyContainer,{[c.validationErroredField]:r});return n?u===J.categoryA?M.jsxs(`div`,{className:f,"data-testid":`third-party-consent`,children:[M.jsxs(`p`,{className:o.p,children:[`I’d like to hear from `,i,` about their products and services which are relevant to me.`,` `,d]}),M.jsxs(`div`,{children:[M.jsxs(`label`,{className:o.label,children:[M.jsx(`input`,{className:G(o.input,o.radio),type:`radio`,value:`CR_OPTIN`,name:`thirdPartyConsent`,required:!0,onInput:e,"data-testid":`checkbox-third-party-consent`,defaultChecked:!0}),`Yes`]}),M.jsxs(`label`,{className:o.label,children:[M.jsx(`input`,{className:G(o.input,o.radio),type:`radio`,value:`CR_OPTOUT`,name:`thirdPartyConsent`,onInput:e}),`No`]})]})]}):u===J.categoryB?M.jsx(`div`,{className:f,"data-testid":`third-party-consent`,children:M.jsxs(`label`,{className:G(o.label,`eln-third-party-consent-
4B`),children:[M.jsx(`input`,{className:G(o.input,o.checkbox),type:`checkbox`,value:`CR_OPTIN`,name:`thirdPartyConsent`,onInput:e,"data-testid":`checkbox-third-party-consent`}),M.jsxs(`p`,{className:o.p,children:[`Yes, I'd like to hear from `,i,` about their products and services which are relevant to me.`,` `,d]})]})}):u===J.categoryC?M.jsx(`div`,{className:f,"data-testid":`third-party-consent`,children:M.jsxs(`label`,{className:G(o.label,`eln-third-party-consent-B`),children:[M.jsx(`input`,{className:G(o.input,o.checkbox),type:`checkbox`,value:`CR_OPTOUT`,name:`thirdPartyConsent`,onInput:e,"data-testid":`checkbox-third-party-consent`}),M.jsxs(`p`,{className:o.p,children:[`Tick here if you do not want to hear from `,i,` about their products and services relevant to you.`,` `,d]})]})}):M.jsxs(`div`,{className:f,"data-testid":`third-party-consent`,children:[M.jsxs(`p`,{className:o.p,children:[`By signing up to `,l,` you agree to our terms and conditions and privacy policy. By continuing, you agree that Informa may contact you with updates about our related products and services including those of our carefully selected partners. Also, `,i,` may follow-up and contact you about their products and services. `,d]}),M.jsxs(`label`,{className:o.label,children:[`I agree to the\xA0`,M.jsx(`a`,{className:o.a,href:`https://www.informa.com/privacy-policy/`,target:`_blank`,rel:`noreferrer`,children:`Privacy Policy`})]})]}):null}var ar={},or=JSON.parse(`[["AF","AFG","004","ISO 3166-2:AF"],["AL","ALB","008","ISO 3166-2:AL"],["DZ","DZA","012","ISO 3166-2:DZ"],["AS","ASM","016","ISO 3166-2:AS"],["AD","AND","020","ISO 3166-2:AD"],["AO","AGO","024","ISO 3166-2:AO"],["AI","AIA","660","ISO 3166-2:AI"],["AQ","ATA","010","ISO 3166-2:AQ"],["AG","ATG","028","ISO 3166-2:AG"],["AR","ARG","032","ISO 3166-2:AR"],["AM","ARM","051","ISO 3166-2:AM"],["AW","ABW","533","ISO 3166-2:AW"],["AU","AUS","036","ISO 3166-2:AU"],["AT","AUT","040","ISO 3166-2:AT"],["AZ","AZE","031","ISO 3166-2:AZ"],["BS","BHS","044","ISO 3166-2:BS"],["BH","BHR","048","ISO 3166-2:BH"],["BD","BGD","050","ISO 3166-2:BD"],["BB","BRB","052","ISO 3166-2:BB"],["BY","BLR","112","ISO 3166-2:BY"],["BE","BEL","056","ISO 3166-2:BE"],["BZ","BLZ","084","ISO 3166-2:BZ"],["BJ","BEN","204","ISO 3166-2:BJ"],["BM","BMU","060","ISO 3166-2:BM"],["BT","BTN","064","ISO 3166-2:BT"],["BO","BOL","068","ISO 3166-2:BO"],["BA","BIH","070","ISO 3166-2:BA"],["BW","BWA","072","ISO 3166-2:BW"],["BV","BVT","074","ISO 3166-2:BV"],["BR","BRA","076","ISO 3166-2:BR"],["IO","IOT","086","ISO 3166-2:IO"],["BN","BRN","096","ISO 3166-2:BN"],["BG","BGR","100","ISO 3166-2:BG"],["BF","BFA","854","ISO 3166-2:BF"],["BI","BDI","108","ISO 3166-2:BI"],["KH","KHM","116","ISO 3166-2:KH"],["CM","CMR","120","ISO 3166-2:CM"],["CA","CAN","124","ISO 3166-2:CA"],["CV","CPV","132","ISO 3166-2:CV"],["KY","CYM","136","ISO 3166-2:KY"],["CF","CAF","140","ISO 3166-2:CF"],["TD","TCD","148","ISO 3166-2:TD"],["CL","CHL","152","ISO 3166-2:CL"],["CN","CHN","156","ISO 3166-2:CN"],["CX","CXR","162","ISO 3166-2:CX"],["CC","CCK","166","ISO 3166-2:CC"],["CO","COL","170","ISO 3166-2:CO"],["KM","COM","174","ISO 3166-2:KM"],["CG","COG","178","ISO 3166-2:CG"],["CD","COD","180","ISO 3166-2:CD"],["CK","COK","184","ISO 3166-2:CK"],["CR","CRI","188","ISO 3166-2:CR"],["CI","CIV","384","ISO 3166-2:CI"],["HR","HRV","191","ISO 3166-2:HR"],["CU","CUB","192","ISO 3166-2:CU"],["CY","CYP","196","ISO 3166-2:CY"],["CZ","CZE","203","ISO 3166-2:CZ"],["DK","DNK","208","ISO 3166-2:DK"],["DJ","DJI","262","ISO 3166-2:DJ"],["DM","DMA","212","ISO 3166-2:DM"],["DO","DOM","214","ISO 3166-2:DO"],["EC","ECU","218","ISO 3166-2:EC"],["EG","EGY","818","ISO 3166-2:EG"],["SV","SLV","222","ISO 3166-2:SV"],["GQ","GNQ","226","ISO 3166-2:GQ"],["ER","ERI","232","ISO 3166-2:ER"],["EE","EST","233","ISO 3166-2:EE"],["ET","ETH","231","ISO 3166-2:ET"],["FK","FLK","238","ISO 3166-2:FK"],["FO","FRO","234","ISO 3166-2:FO"],["FJ","FJI","242","ISO 3166-2:FJ"],["FI","FIN","246","ISO 3166-2:FI"],["FR","FRA","250","ISO 3166-2:FR"],["GF","GUF","254","ISO 3166-2:GF"],["PF","PYF","258","ISO 3166-2:PF"],["TF","ATF","260","ISO 3166-2:TF"],["GA","GAB","266","ISO 3166-2:GA"],["GM","GMB","270","ISO 3166-2:GM"],["GE","GEO","268","ISO 3166-2:GE"],["DE","DEU","276","ISO 3166-2:DE"],["GH","GHA","288","ISO 3166-2:GH"],["GI","GIB","292","ISO 3166-2:GI"],["GR","GRC","300","ISO 3166-2:GR"],["GL","GRL","304","ISO 3166-2:GL"],["GD","GRD","308","ISO 3166-2:GD"],["GP","GLP","312","ISO 3166-2:GP"],["GU","GUM","316","ISO 3166-2:GU"],["GT","GTM","320","ISO 3166-2:GT"],["GN","GIN","324","ISO 3166-2:GN"],["GW","GNB","624","ISO 3166-2:GW"],["GY","GUY","328","ISO 3166-2:GY"],["HT","HTI","332","ISO 3166-2:HT"],["HM","HMD","334","ISO 3166-2:HM"],["VA","VAT","336","ISO 3166-2:VA"],["HN","HND","340","ISO 3166-2:HN"],["HK","HKG","344","ISO 3166-2:HK"],["HU","HUN","348","ISO 3166-2:HU"],["IS","ISL","352","ISO 3166-2:IS"],["IN","IND","356","ISO 3166-2:IN"],["ID","IDN","360","ISO 3166-2:ID"],["IR","IRN","364","ISO 3166-2:IR"],["IQ","IRQ","368","ISO 3166-2:IQ"],["IE","IRL","372","ISO 3166-2:IE"],["IL","ISR","376","ISO 3166-2:IL"],["IT","ITA","380","ISO 3166-2:IT"],["JM","JAM","388","ISO 3166-2:JM"],["JP","JPN","392","ISO 3166-2:JP"],["JO","JOR","400","ISO 3166-2:JO"],["KZ","KAZ","398","ISO 3166-2:KZ"],["KE","KEN","404","ISO 3166-2:KE"],["KI","KIR","296","ISO 3166-2:KI"],["KP","PRK","408","ISO 3166-2:KP"],["KR","KOR","410","ISO 3166-2:KR"],["KW","KWT","414","ISO 3166-2:KW"],["KG","KGZ","417","ISO 3166-2:KG"],["LA","LAO","418","ISO 3166-2:LA"],["LV","LVA","428","ISO 3166-2:LV"],["LB","LBN","422","ISO 3166-2:LB"],["LS","LSO","426","ISO 3166-2:LS"],["LR","LBR","430","ISO 3166-2:LR"],["LY","LBY","434","ISO 3166-2:LY"],["LI","LIE","438","ISO 3166-2:LI"],["LT","LTU","440","ISO 3166-2:LT"],["LU","LUX","442","ISO 3166-2:LU"],["MO","MAC","446","ISO 3166-2:MO"],["MG","MDG","450","ISO 3166-2:MG"],["MW","MWI","454","ISO 3166-2:MW"],["MY","MYS","458","ISO 3166-2:MY"],["MV","MDV","462","ISO 3166-2:MV"],["ML","MLI","466","ISO 3166-2:ML"],["MT","MLT","470","ISO 3166-2:MT"],["MH","MHL","584","ISO 3166-2:MH"],["MQ","MTQ","474","ISO 3166-2:MQ"],["MR","MRT","478","ISO 3166-2:MR"],["MU","MUS","480","ISO 3166-2:MU"],["YT","MYT","175","ISO 3166-2:YT"],["MX","MEX","484","ISO 3166-2:MX"],["FM","FSM","583","ISO 3166-2:FM"],["MD","MDA","498","ISO 3166-2:MD"],["MC","MCO","492","ISO 3166-2:MC"],["MN","MNG","496","ISO 3166-2:MN"],["MS","MSR","500","ISO 3166-2:MS"],["MA","MAR","504","ISO 3166-2:MA"],["MZ","MOZ","508","ISO 3166-2:MZ"],["MM","MMR","104","ISO 3166-2:MM"],["NA","NAM","516","ISO 3166-2:NA"],["NR","NRU","520","ISO 3166-2:NR"],["NP","NPL","524","ISO 3166-2:NP"],["NL","NLD","528","ISO 3166-2:NL"],["NC","NCL","540","ISO 3166-2:NC"],["NZ","NZL","554","ISO 3166-2:NZ"],["NI","NIC","558","ISO 3166-2:NI"],["NE","NER","562","ISO 3166-2:NE"],["NG","NGA","566","ISO 3166-2:NG"],["NU","NIU","570","ISO 3166-2:NU"],["NF","NFK","574","ISO 3166-2:NF"],["MP","MNP","580","ISO 3166-2:MP"],["MK","MKD","807","ISO 3166-2:MK"],["NO","NOR","578","ISO 3166-2:NO"],["OM","OMN","512","ISO 3166-2:OM"],["PK","PAK","586","ISO 3166-2:PK"],["PW","PLW","585","ISO 3166-2:PW"],["PS","PSE","275","ISO 3166-2:PS"],["PA","PAN","591","ISO 3166-2:PA"],["PG","PNG","598","ISO 3166-2:PG"],["PY","PRY","600","ISO 3166-2:PY"],["PE","PER","604","ISO 3166-2:PE"],["PH","PHL","608","ISO 3166-2:PH"],["PN","PCN","612","ISO 3166-2:PN"],["PL","POL","616","ISO 3166-2:PL"],["PT","PRT","620","ISO 3166-2:PT"],["PR","PRI","630","ISO 3166-2:PR"],["QA","QAT","634","ISO 3166-2:QA"],["RE","REU","638","ISO 3166-2:RE"],["RO","ROU","642","ISO 3166-2:RO"],["RU","RUS","643","ISO 3166-2:RU"],["RW","RWA","646","ISO 3166-2:RW"],["SH","SHN","654","ISO 3166-2:SH"],["KN","KNA","659","ISO 3166-2:KN"],["LC","LCA","662","ISO 3166-2:LC"],["PM","SPM","666","ISO 3166-2:PM"],["VC","VCT","670","ISO 3166-2:VC"],["WS","WSM","882","ISO 3166-2:WS"],["SM","SMR","674","ISO 3166-2:SM"],["ST","STP","678","ISO 3166-2:ST"],["SA","SAU","682","ISO 3166-2:SA"],["SN","SEN","686","ISO 3166-2:SN"],["SC","SYC","690","ISO 3166-2:SC"],["SL","SLE","694","ISO 3166-2:SL"],["SG","SGP","702","ISO 3166-2:SG"],["SK","SVK","703","ISO 3166-2:SK"],["SI","SVN","705","ISO 3166-2:SI"],["SB","SLB","090","ISO 3166-2:SB"],["SO","SOM","706","ISO 3166-2:SO"],["ZA","ZAF","710","ISO 3166-2:ZA"],["GS","SGS","239","ISO 3166-2:GS"],["ES","ESP","724","ISO 3166-2:ES"],["LK","LKA","144","ISO 3166-2:LK"],["SD","SDN","729","ISO 3166-2:SD"],["SR","SUR","740","ISO 3166-2:SR"],["SJ","SJM","744","ISO 3166-2:SJ"],["SZ","SWZ","748","ISO 3166-2:SZ"],["SE","SWE","752","ISO 3166-2:SE"],["CH","CHE","756","ISO 3166-2:CH"],["SY","SYR","760","ISO 3166-2:SY"],["TW","TW
4N","158","ISO 3166-2:TW"],["TJ","TJK","762","ISO 3166-2:TJ"],["TZ","TZA","834","ISO 3166-2:TZ"],["TH","THA","764","ISO 3166-2:TH"],["TL","TLS","626","ISO 3166-2:TL"],["TG","TGO","768","ISO 3166-2:TG"],["TK","TKL","772","ISO 3166-2:TK"],["TO","TON","776","ISO 3166-2:TO"],["TT","TTO","780","ISO 3166-2:TT"],["TN","TUN","788","ISO 3166-2:TN"],["TR","TUR","792","ISO 3166-2:TR"],["TM","TKM","795","ISO 3166-2:TM"],["TC","TCA","796","ISO 3166-2:TC"],["TV","TUV","798","ISO 3166-2:TV"],["UG","UGA","800","ISO 3166-2:UG"],["UA","UKR","804","ISO 3166-2:UA"],["AE","ARE","784","ISO 3166-2:AE"],["GB","GBR","826","ISO 3166-2:GB"],["US","USA","840","ISO 3166-2:US"],["UM","UMI","581","ISO 3166-2:UM"],["UY","URY","858","ISO 3166-2:UY"],["UZ","UZB","860","ISO 3166-2:UZ"],["VU","VUT","548","ISO 3166-2:VU"],["VE","VEN","862","ISO 3166-2:VE"],["VN","VNM","704","ISO 3166-2:VN"],["VG","VGB","092","ISO 3166-2:VG"],["VI","VIR","850","ISO 3166-2:VI"],["WF","WLF","876","ISO 3166-2:WF"],["EH","ESH","732","ISO 3166-2:EH"],["YE","YEM","887","ISO 3166-2:YE"],["ZM","ZMB","894","ISO 3166-2:ZM"],["ZW","ZWE","716","ISO 3166-2:ZW"],["AX","ALA","248","ISO 3166-2:AX"],["BQ","BES","535","ISO 3166-2:BQ"],["CW","CUW","531","ISO 3166-2:CW"],["GG","GGY","831","ISO 3166-2:GG"],["IM","IMN","833","ISO 3166-2:IM"],["JE","JEY","832","ISO 3166-2:JE"],["ME","MNE","499","ISO 3166-2:ME"],["BL","BLM","652","ISO 3166-2:BL"],["MF","MAF","663","ISO 3166-2:MF"],["RS","SRB","688","ISO 3166-2:RS"],["SX","SXM","534","ISO 3166-2:SX"],["SS","SSD","728","ISO 3166-2:SS"],["XK","XKK","983","ISO 3166-2:XK"]]`),sr=`br.cy.dv.sw.eu.af.am.ha.ku.ml.mt.no.ps.sd.so.sq.ta.tg.tt.ug.ur.vi.ar.az.be.bg.bn.bs.ca.cs.da.de.el.en.es.et.fa.fi.fr.ga.gl.he.hi.hr.hu.hy.id.is.it.ja.ka.kk.km.ko.ky.lt.lv.mk.mn.mr.ms.nb.nl.nn.pl.pt.ro.ru.sk.sl.sr.sv.th.tk.tr.uk.uz.zh`.split(`.`),cr={},lr;function ur(){if(lr)return cr;lr=1,cr.remove=a;for(var e=[{base:` `,chars:`\xA0`},{base:`0`,chars:`߀`},{base:`A`,chars:`ⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ`},{base:`AA`,chars:`Ꜳ`},{base:`AE`,chars:`ÆǼǢ`},{base:`AO`,chars:`Ꜵ`},{base:`AU`,chars:`Ꜷ`},{base:`AV`,chars:`ꜸꜺ`},{base:`AY`,chars:`Ꜽ`},{base:`B`,chars:`ⒷBḂḄḆɃƁ`},{base:`C`,chars:`ⒸCꜾḈĆCĈĊČÇƇȻ`},{base:`D`,chars:`ⒹDḊĎḌḐḒḎĐƊƉᴅꝹ`},{base:`Dh`,chars:`Ð`},{base:`DZ`,chars:`DZDŽ`},{base:`Dz`,chars:`DzDž`},{base:`E`,chars:`ɛⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎᴇ`},{base:`F`,chars:`ꝼⒻFḞƑꝻ`},{base:`G`,chars:`ⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾɢ`},{base:`H`,chars:`ⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ`},{base:`I`,chars:`ⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ`},{base:`J`,chars:`ⒿJĴɈȷ`},{base:`K`,chars:`ⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ`},{base:`L`,chars:`ⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ`},{base:`LJ`,chars:`LJ`},{base:`Lj`,chars:`Lj`},{base:`M`,chars:`ⓂMḾṀṂⱮƜϻ`},{base:`N`,chars:`ꞤȠⓃNǸŃÑṄŇṆŅṊṈƝꞐᴎ`},{base:`NJ`,chars:`NJ`},{base:`Nj`,chars:`Nj`},{base:`O`,chars:`ⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ`},{base:`OE`,chars:`Œ`},{base:`OI`,chars:`Ƣ`},{base:`OO`,chars:`Ꝏ`},{base:`OU`,chars:`Ȣ`},{base:`P`,chars:`ⓅPṔṖƤⱣꝐꝒꝔ`},{base:`Q`,chars:`ⓆQꝖꝘɊ`},{base:`R`,chars:`ⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ`},{base:`S`,chars:`ⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ`},{base:`T`,chars:`ⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ`},{base:`Th`,chars:`Þ`},{base:`TZ`,chars:`Ꜩ`},{base:`U`,chars:`ⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ`},{base:`V`,chars:`ⓋVṼṾƲꝞɅ`},{base:`VY`,chars:`Ꝡ`},{base:`W`,chars:`ⓌWẀẂŴẆẄẈⱲ`},{base:`X`,chars:`ⓍXẊẌ`},{base:`Y`,chars:`ⓎYỲÝŶỸȲẎŸỶỴƳɎỾ`},{base:`Z`,chars:`ⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ`},{base:`a`,chars:`ⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐɑ`},{base:`aa`,chars:`ꜳ`},{base:`ae`,chars:`æǽǣ`},{base:`ao`,chars:`ꜵ`},{base:`au`,chars:`ꜷ`},{base:`av`,chars:`ꜹꜻ`},{base:`ay`,chars:`ꜽ`},{base:`b`,chars:`ⓑbḃḅḇƀƃɓƂ`},{base:`c`,chars:`cⓒćĉċčçḉƈȼꜿↄ`}
4,{base:`d`,chars:`ⓓdḋďḍḑḓḏđƌɖɗƋᏧԁꞪ`},{base:`dh`,chars:`ð`},{base:`dz`,chars:`dzdž`},{base:`e`,chars:`ⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇǝ`},{base:`f`,chars:`ⓕfḟƒ`},{base:`ff`,chars:`ff`},{base:`fi`,chars:`fi`},{base:`fl`,chars:`fl`},{base:`ffi`,chars:`ffi`},{base:`ffl`,chars:`ffl`},{base:`g`,chars:`ⓖgǵĝḡğġǧģǥɠꞡꝿᵹ`},{base:`h`,chars:`ⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ`},{base:`hv`,chars:`ƕ`},{base:`i`,chars:`ⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı`},{base:`j`,chars:`ⓙjĵǰɉ`},{base:`k`,chars:`ⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ`},{base:`l`,chars:`ⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇɭ`},{base:`lj`,chars:`lj`},{base:`m`,chars:`ⓜmḿṁṃɱɯ`},{base:`n`,chars:`ⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥлԉ`},{base:`nj`,chars:`nj`},{base:`o`,chars:`ⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿꝋꝍɵɔᴑ`},{base:`oe`,chars:`œ`},{base:`oi`,chars:`ƣ`},{base:`oo`,chars:`ꝏ`},{base:`ou`,chars:`ȣ`},{base:`p`,chars:`ⓟpṕṗƥᵽꝑꝓꝕρ`},{base:`q`,chars:`ⓠqɋꝗꝙ`},{base:`r`,chars:`ⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ`},{base:`s`,chars:`ⓢsśṥŝṡšṧṣṩșşȿꞩꞅẛʂ`},{base:`ss`,chars:`ß`},{base:`t`,chars:`ⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ`},{base:`th`,chars:`þ`},{base:`tz`,chars:`ꜩ`},{base:`u`,chars:`ⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ`},{base:`v`,chars:`ⓥvṽṿʋꝟʌ`},{base:`vy`,chars:`ꝡ`},{base:`w`,chars:`ⓦwẁẃŵẇẅẘẉⱳ`},{base:`x`,chars:`ⓧxẋẍ`},{base:`y`,chars:`ⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ`},{base:`z`,chars:`ⓩzźẑżžẓẕƶȥɀⱬꝣ`}],t={},n=0;n<e.length;n+=1)for(var r=e[n].chars,i=0;i<r.length;i+=1)t[r[i]]=e[n].base;
4function a(e){return e.replace(/[^\u0000-\u007e]/g,function(e){return t[e]||e})}return cr.replacementList=e,cr.diacriticsMap=t,cr}var dr;function fr(){return dr||(dr=1,function(e){let t=or,n=sr,r=ur().remove,i={},a={},o={},s={},c={};t.forEach(function(e){let t=e;a[t[0]]=t[1],o[t[1]]=t[0],s[t[2]]=t[0],c[t[0]]=t[2]});function l(e){return(`000`+(e||``)).slice(-3)}function u(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function d(e,t){return Object.keys(e).reduce(function(n,r){let i=e[r];return n[r]=t(i,r),n},{})}function f(e,t){switch(e){case`official`:return Array.isArray(t)?t[0]:t;case`all`:return typeof t==`string`?[t]:t;case`alias`:return Array.isArray(t)?t[1]||t[0]:t;default:throw TypeError(`LocaleNameType must be one of these: all, official, alias!`)}}e.registerLocale=function(e){if(!e.locale)throw TypeError(`Missing localeData.locale`);if(!e.countries)throw TypeError(`Missing localeData.countries`);i[e.locale]=e.countries};function p(e){return o[e]}e.alpha3ToAlpha2=p;function m(e){return a[e]}e.alpha2ToAlpha3=m;function h(e){return c[p(e)]}e.alpha3ToNumeric=h;function g(e){return c[e]}e.alpha2ToNumeric=g;function _(e){let t=l(e);return m(s[t])}e.numericToAlpha3=_;function v(e){let t=l(e);return s[t]}e.numericToAlpha2=v;function y(e){if(typeof e==`string`){if(/^[0-9]*$/.test(e))return _(e);if(e.length===2)return m(e.toUpperCase());if(e.length===3)return e.toUpperCase()}if(typeof e==`number`)return _(e)}e.toAlpha3=y;function b(e){if(typeof e==`string`){if(/^[0-9]*$/.test(e))return v(e);if(e.length===2)return e.toUpperCase();if(e.length===3)return p(e.toUpperCase())}if(typeof e==`number`)return v(e)}e.toAlpha2=b,e.getName=function(e,t,n={}){`select`in n||(n.select=`official`);try{let r=i[t.toLowerCase()][b(e)];return f(n.select,r)}catch{return}},e.getNames=function(e,t={}){`select`in t||(t.select=`official`);let n=i[e.toLowerCase()];return n===void 0?{}:d(n,function(e){return f(t.select,e)})},e.getAlpha2Code=function(e,t){let n=e=>e.toLowerCase(),r=(e,t)=>n(e)===n(t);try{let n=i[t.toLowerCase()];for(let t in n)if(u(n,t)){if(typeof n[t]==`string`&&r(n[t],e))return t;if(Array.isArray(n[t])){for(let i of n[t])if(r(i,e))return t}}return}catch{return}},e.getSimpleAlpha2Code=function(e,t){let n=e=>r(e.toLowerCase()),a=(e,t)=>n(e)===n(t);try{let n=i[t.toLowerCase()];for(let t in n)if(u(n,t)){if(typeof n[t]==`string`&&a(n[t],e))return t;if(Array.isArray(n[t])){for(let r of n[t])if(a(r,e))return t}}return}catch{return}},e.getAlpha2Codes=function(){return a},e.getAlpha3Code=function(t,n){let r=e.getAlpha2Code(t,n);if(r)return e.toAlpha3(r)},e.getSimpleAlpha3Code=function(t,n){let r=e.getSimpleAlpha2Code(t,n);if(r)return e.toAlpha3(r)},e.getAlpha3Codes=function(){return o},e.getNumericCodes=function(){return s},e.langs=function(){return Object.keys(i)},e.getSupportedLanguages=function(){return n},e.isValid=function(e){if(!e)return!1;let t=e.toString().toUpperCase();return u(o,t)||u(a,t)||u(s,t)}}(ar)),ar}var pr=k(fr()),mr={locale:`en`,countries:{AF:`Afghanistan`,AL:`Albania`,DZ:`Algeria`,AS:`American Samoa`,AD:`Andorra`,AO:`Angola`,AI:`Anguilla`,AQ:`Antarctica`,AG:`Antigua and Barbuda`,AR:`Argentina`,AM:`Armenia`,AW:`Aruba`,AU:`Australia`,AT:`Austria`,AZ:`Azerbaijan`,BS:`Bahamas`,BH:`Bahrain`,BD:`Bangladesh`,BB:`Barbados`,BY:`Belarus`,BE:`Belgium`,BZ:`Belize`,BJ:`Benin`,BM:`Bermuda`,BT:`Bhutan`,BO:`Bolivia`,BA:`Bosnia and Herzegovina`,BW:`Botswana`,BV:`Bouvet Island`,BR:`Brazil`,IO:`British Indian Ocean Territory`,BN:`Brunei Darussalam`,BG:`Bulgaria`,BF:`Burkina Faso`,BI:`Burundi`,KH:`Cambodia`,CM:`Cameroon`,CA:`Canada`,CV:`Cape Verde`,KY:`Cayman Islands`,CF:`Central African Republic`,TD:`Chad`,CL:`Chile`,CN:[`People's Republic of China`,`China`],CX:`Christmas Island`,CC:`Cocos (Keeling) Islands`,CO:`Colombia`,KM:`Comoros`,CG:[`Republic of the Congo`,`Congo`],CD:[`Democratic Republic of the Congo`,`Congo`],CK:`Cook Islands`,CR:`Costa Rica`,CI:[`Cote d'Ivoire`,`Côte d'Ivoire`,`Ivory Coast`],HR:`Croatia`,CU:`Cuba`,CY:`Cyprus`,CZ:[`Czech Republic`,`Czechia`],DK:`Denmark`,DJ:`Djibouti`,DM:`Dominica`,DO:`Dominican Republic`,EC:`Ecuador`,EG:`Egypt`,SV:`El Salvador`,GQ:`Equatorial Guinea`,ER:`Eritrea`,EE:`Estonia`,ET:`Ethiopia`,FK:`Falkland Islands (Malvinas)`,FO:`Faroe Islands`,FJ:`Fiji`,FI:`Finland`,FR:`France`,GF:`French Guiana`,PF:`French Polynesia`,TF:`French Southern Territories`,GA:`Gabon`,GM:[`Republic of The Gambia`,`The Gambia`,`Gambia`],GE:`Georgia`,DE:`Germany`,GH:`Ghana`,GI:`Gibraltar`,GR:`Greece`,GL:`Greenland`,GD:`Grenada`,GP:`Guadeloupe`,GU:`Guam`,GT:`Guatemala`,GN:`Guinea`,GW:`Guinea-Bissau`,GY:`Guyana`,HT:`Haiti`,HM:`Heard Island and McDonald Islands`,VA:`Holy See (Vatican City State)`,HN:`Honduras`,HK:`Hong Kong`,HU:`Hungary`,IS:`Iceland`,IN:`India`,ID:`Indonesia`,IR:[`Islamic Republic of Iran`,`Iran`],IQ:`Iraq`,IE:`Ireland`,IL:`Israel`,IT:`Italy`,JM:`Jamaica`,JP:`Japan`,JO:`Jordan`,KZ:`K
4azakhstan`,KE:`Kenya`,KI:`Kiribati`,KP:`North Korea`,KR:[`South Korea`,`Korea, Republic of`,`Republic of Korea`],KW:`Kuwait`,KG:`Kyrgyzstan`,LA:`Lao People's Democratic Republic`,LV:`Latvia`,LB:`Lebanon`,LS:`Lesotho`,LR:`Liberia`,LY:`Libya`,LI:`Liechtenstein`,LT:`Lithuania`,LU:`Luxembourg`,MO:`Macao`,MG:`Madagascar`,MW:`Malawi`,MY:`Malaysia`,MV:`Maldives`,ML:`Mali`,MT:`Malta`,MH:`Marshall Islands`,MQ:`Martinique`,MR:`Mauritania`,MU:`Mauritius`,YT:`Mayotte`,MX:`Mexico`,FM:`Micronesia, Federated States of`,MD:`Moldova, Republic of`,MC:`Monaco`,MN:`Mongolia`,MS:`Montserrat`,MA:`Morocco`,MZ:`Mozambique`,MM:`Myanmar`,NA:`Namibia`,NR:`Nauru`,NP:`Nepal`,NL:[`Netherlands`,`The Netherlands`,`Netherlands (Kingdom of the)`],NC:`New Caledonia`,NZ:`New Zealand`,NI:`Nicaragua`,NE:`Niger`,NG:`Nigeria`,NU:`Niue`,NF:`Norfolk Island`,MK:[`The Republic of North Macedonia`,`North Macedonia`],MP:`Northern Mariana Islands`,NO:`Norway`,OM:`Oman`,PK:`Pakistan`,PW:`Palau`,PS:[`State of Palestine`,`Palestine`],PA:`Panama`,PG:`Papua New Guinea`,PY:`Paraguay`,PE:`Peru`,PH:`Philippines`,PN:[`Pitcairn`,`Pitcairn Islands`],PL:`Poland`,PT:`Portugal`,PR:`Puerto Rico`,QA:`Qatar`,RE:`Reunion`,RO:`Romania`,RU:[`Russian Federation`,`Russia`],RW:`Rwanda`,SH:`Saint Helena`,KN:`Saint Kitts and Nevis`,LC:`Saint Lucia`,PM:`Saint Pierre and Miquelon`,VC:`Saint Vincent and the Grenadines`,WS:`Samoa`,SM:`San Marino`,ST:`Sao Tome and Principe`,SA:`Saudi Arabia`,SN:`Senegal`,SC:`Seychelles`,SL:`Sierra Leone`,SG:`Singapore`,SK:`Slovakia`,SI:`Slovenia`,SB:`Solomon Islands`,SO:`Somalia`,ZA:`South Africa`,GS:`South Georgia and the South Sandwich Islands`,ES:`Spain`,LK:`Sri Lanka`,SD:`Sudan`,SR:`Suriname`,SJ:`Svalbard and Jan Mayen`,SZ:`Eswatini`,SE:`Sweden`,CH:`Switzerland`,SY:`Syrian Arab Republic`,TW:[`Taiwan, Province of China`,`Taiwan`],TJ:`Tajikistan`,TZ:[`United Republic of Tanzania`,`Tanzania`],TH:`Thailand`,TL:`Timor-Leste`,TG:`Togo`,TK:`Tokelau`,TO:`Tonga`,TT:`Trinidad and Tobago`,TN:`Tunisia`,TR:[`Türkiye`,`Turkey`],TM:`Turkmenistan`,TC:`Turks and Caicos Islands`,TV:`Tuvalu`,UG:`Uganda`,UA:`Ukraine`,AE:[`United Arab Emirates`,`UAE`],GB:[`United Kingdom`,`UK`,`Great Britain`],US:[`United States of America`,`United States`,`USA`,`U.S.A.`,`US`,`U.S.`],UM:`United States Minor Outlying Islands`,UY:`Uruguay`,UZ:`Uzbekistan`,VU:`Vanuatu`,VE:`Venezuela`,VN:`Vietnam`,VG:`Virgin Islands, British`,VI:`Virgin Islands, U.S.`,WF:`Wallis and Futuna`,EH:`Western Sahara`,YE:`Yemen`,ZM:`Zambia`,ZW:`Zimbabwe`,AX:[`Åland Islands`,`Aland Islands`],BQ:`Bonaire, Sint Eustatius and Saba`,CW:`Curaçao`,GG:`Guernsey`,IM:`Isle of Man`,JE:`Jersey`,ME:`Montenegro`,BL:`Saint Barthélemy`,MF:`Saint Martin (French part)`,RS:`Serbia`,SX:`Sint Maarten (Dutch part)`,SS:`South Sudan`,XK:`Kosovo`}},hr=2,gr=new class{constructor(e){this.adapter=e}getCountryCode(e){return this.adapter.getCode(e)}}(new class{constructor(){pr.registerLocale(mr),this.library=pr}getCode(e){return e?.length===hr||!e?e:this.library.getAlpha2Code(e,`en`)||e}}),_r=new Vt,vr=e=>{let t=_r.getCategoryByCountryCode(e);return{thirdPartyConsentTouched:t===J.categoryA,thirdPartyConsentOption:t===J.categoryA?`CR_OPTIN`:``}},yr=e=>{let t=_r.getCategoryByCountryCode(e);return{firstPartyConsentTouched:t===J.categoryA,firstPartyConsentOption:t===J.categoryA?`CR_OPTIN`:``}},br=(e,t,n,r)=>{let i=xe[We(r)],a=e.reduce((e,{htmlName:t,value:n})=>(i[t]&&(e[i[t]]=n),e),{}),o=Ae(),s=gr.getCountryCode(t?.country||a.country),c=Xe(t?.state||a?.state)||``;return{...o,...t,...a,...n,country:s,state:c}};function xr(e){let t=q(),n=(0,w.useRef)(!1),r=()=>{!n.current&&e.formInteractionCallback&&(n.current=!0,e.formInteractionCallback())},[i,a]=(0,w.useState)({contentType:e.contentType,contentId:e.contentId,thirdPartyConsent:!1,formFields:[],formId:null,countryCode:gr.getCountryCode(e.countryCode),emailAddress:e.iirisUserProfile?.business_email||e.emailAddress||``,firstPartyConsent:!1}),[o,s]=(0,w.useState)({elements:e.elements,showAllViolations:!1,...vr(e.countryCode),firstPartyConsentOption:``,firstPartyConsentTouched:!1}),[c,l]=(0,w.useState)(),u=!e.iirisUserProfile&&He(e.platformApiService.siteId);function d(t,n){E&&D&&(t=[{htmlName:D.fieldName,value:e.emailAddress??i.emailAddress,violations:[],touched:!0},...t]);let r=t.find(e=>e.htmlName===I.COUNTRY||e.htmlName===I.MARKETO_COUNTRY)?.value||e.countryCode,o=gr.getCountryCode(r),c=t.find(e=>e.htmlName===I.EMAIL_ADDRESS||e.htmlName===I.BUSINESS_EMAIL||e.htmlName===I.MARKETO_EMAIL)?.value||``;s(e=>({...e,elements:n,...yr(o)})),a(e=>
4({...e,emailAddress:c,countryCode:o,formFields:t}))}let f=e=>{let t=e.value;e.type===`checkbox`&&(t=e.checked?e.value:``),e.type===`radio`&&(t=e.value),s(n=>({...n,thirdPartyConsentOption:t,thirdPartyConsentTouched:e.checked}))},p=e=>{s(t=>({...t,firstPartyConsentOption:_r.getValueByElement(e),firstPartyConsentTouched:!0}))},m=e=>{e.preventDefault();let t=e.currentTarget;t.name===I.THIRD_PARTY_CONSENT?f(t):t.name===I.CONSENT&&p(t)},h=(t,n,r)=>r&&r===`wealthmanagement`&&e.hideThirdPartyConsent?!1:_r.getThirdConsentValue(t,n),g=async t=>{var n,r;if((n=e.submissionCallback)==null||n.call(e),s(e=>({...e,showAllViolations:!0})),u&&!c)return;let a=!e.forceThirdPartyConsentAsFalse&&h(i.countryCode,o.thirdPartyConsentOption,e.platformApiService.siteId),{formFields:l}=i,d=e.iirisUserProfile||a?!0:_r.getFirstConsentValue(i.countryCode,o.firstPartyConsentOption,a),f=br(l,e.iirisUserProfile,{firstPartyConsent:d,thirdPartyConsent:a},e.formStorage);if(l.some(({violations:e})=>e.length))return;let p={formFields:l,emailAddress:e.iirisUserProfile?.business_email||i.emailAddress||e.emailAddress||``,thirdPartyConsent:a,firstPartyConsent:d,contentType:e.contentType,contentId:e.contentId,formId:e.formId||``,gatingAction:e.gatingAction,honeypot:t},m={isSuccessful:!1,message:`Submitting data...`,status:H.PENDING},g=E&&D?[D,...o.elements??[]]:o.elements;e.subscriptionStateHandler(m);try{let t=await e.platformApiService.submitGatedContentFormData(p,e.iirisUserProfile,g,l,c);if(t.status===200){m.isSuccessful=!0,m.message=`SUCCESS`,m.status=H.SUCCESS;let n={...t,data:{...t.data,submissionData:f}};e.completionCallback(n)}}catch(t){Kt(t),m.isSuccessful=!1,m.message=`A problem has occurred with processing your request, please wait a few minutes and try again.`,m.status=H.ERROR,e.subscriptionStateHandler(m),(r=e.submissionErrorCallback)==null||r.call(e,t)}},_=async e=>{e.preventDefault(),await g(Lt(e.currentTarget))},v=e=>e.includes(`Captcha is invalid!`),y=()=>{let e=i.formFields.filter(e=>e.touched||o.showAllViolations).flatMap(({violations:e})=>e),t=[];return o.showAllViolations&&u&&!c&&t.push(`Captcha is invalid!`),{errors:e,otherErrors:t}},b=e.subscriptionState&&e.subscriptionState.status,{elements:x=[],inContextValidationMessage:S,iirisUserProfile:ee,hideFirstPartyConsent:te,hideThirdPartyConsent:ne}=e,{errors:C,otherErrors:T}=y(),E=Ge(e.contentType,e.isLeadGenPage||!1),D=E?x.find(e=>Ke(e.fieldName)):void 0,O=E&&e.emailAddress?x.filter(e=>!Ke(e.fieldName)):x,k=qe(e);(0,w.useEffect)(()=>{var t;(t=e.unlockedContentCallback)==null||t.call(e,k)},[k]);let re=k?Ee:e.title,A=k?De:e.subtitle,j=k&&e.unlockedSubmitButtonText?e.unlockedSubmitButtonText:e.submitButtonText;if(b===H.PENDING)return M.jsx(Wt,{});if(b===H.ERROR)return M.jsx(Gt,{title:`A problem has occurred`,message:`A problem has occurred with processing your request, please wait a few minutes and try again.`,returnFunction:e.completionCallback});{let{base:n,formLayout:a}=t,s=k?G(n.p,a.unlockedTitle):G(n.p,a.title),c=k?G(n.p,a.unlockedDescription):G(n.p,a.description);return M.jsx(`div`,{className:a.container,onFocus:r,children:M.jsxs(`form`,{noValidate:!0,className:G(n.form,a.form),onSubmit:_,children:[M.jsx(It,{}),M.jsxs(`div`,{children:[typeof re==`string`?M.jsx(`p`,{className:s,children:re}):re,typeof A==`string`?M.jsx(`p`,{className:c,children:A}):A]}),!S&&M.jsx(qt,{validationErrors:C,otherErrors:T}),O&&M.jsx(Ft,{onChange:d,elements:O,showAllViolations:o.showAllViolations,showErrorMessages:S,siteId:e.platformApiService.siteId,wideInputElemets:E?Te:we}),!te&&!ee&&M.jsx(Ut,{sponsorName:e.sponsorName,countryCode:gr.getCountryCode(i.countryCode),changeHandler:m,hideConsentContent:!te&&!ee,error:S&&T.includes(ye),defaultCheckedYes:h(i.countryCode,o.thirdPartyConsentOption,e.platformApiService.siteId)}),!ne&&M.jsx(ir,{contentType:e.contentType,countryCode:gr.getCountryCode(e.countryCode||i.countryCode),changeHandler:m,error:S&&o.showAllViolations,sponsorName:e.sponsorName}),u&&M.jsx(Yn,{className:a.captchaContainer,setToken:l,error:S&&o.showAllViolations&&v(T)}),M.jsx(`button`,{className:G(n.button,a.submit),children:j??`Continue`})]})})}}var Sr=(e,t)=>
4e.length?e.map(e=>(Se[t]&&Se[t].includes(e.fieldName)&&(e.validations=[...Ce[e.fieldName].rules]),e)):[],Cr={email:`business_email`,firstname:`first_name`,lastname:`last_name`,address:`BPIADD`,city:`City`,zip:`BPIPCZ`,phone:`BPIPH`,company:`company`,jobtitle:`job_title`},wr={Email:`business_email`,FirstName:`first_name`,LastName:`last_name`,Title:`job_title`,Company:`company`,businessType:`industry`,jobFunction:`job_function`,Country:`country`,State:`state`,Phone:`phone`,Demo_JobLevel:`job_level`,Demo_FSD_ManagementType:`company_type`,Demo_EmployeeLocation:`job_area`,Demo_FSD_AnnualFBPurchases:`company_revenue`,numberofLocations:`job_area`,fsd_annual_fb_purchases:`company_revenue`,fsd_management_type:`company_type`,company_name:`company`,phone_number:`phone`,nature_of_business:`industry`,employee_location:`job_area`},Tr=e=>({foodservicedirector:wr,bioprocessintl:Cr})[e]||{},Er=(e,t)=>typeof e==`string`&&Object.keys(t).includes(e),Dr=[`industry`,`job_function`,`JF_JobFunction`],Or=(e,t,n)=>{let r=ve[n]||``,i=Ve(e,t);if(!i||i.length===0)return;let a=i.find(e=>e.brand===r||e.brand===n);return a?a.id:i[0]?.id},kr=({clientId:e,user:t,element:n})=>{let r=Tr(e)[n.fieldName]||n.fieldName;if(Er(r,t)&&t[r])return t[r];if(Dr.includes(r))return Or(t,r,e);let i=Ue(e,t);return i?i[n.fieldName]||``:void 0};function Ar(e){let t=new Ze(e.platformServiceBaseUrl,e.clientId,e.authorization,void 0,e.subBrandId,e.version,e.iirisUserProfile,e.productId),[n,r]=(0,w.useState)({forms:{}}),[i,a]=(0,w.useState)({isSuccessful:!1,message:`PRE-SUB`,status:H.PENDING}),o=(0,w.useRef)(null),s=e=>{o.current&&o.current.scrollIntoView({behavior:`smooth`,block:`start`}),a({isSuccessful:e.isSuccessful,message:e.message,status:e.status})},c=(t,n)=>n.reduce((n,r)=>kr({clientId:e.clientId,user:t,element:r})?n.filter(e=>e.fieldName!==r.fieldName):n,n),l=(t,n)=>{let r=[`business_email`,`email`,`firstname`,`lastname`,`state`,`region`,`country`,`business_email`,`first_name`,`last_name`];return n.reduce((n,i)=>{let a=kr({clientId:e.clientId,user:t,element:i});return r.includes(i.fieldName)||a!=null&&a!==``?n.filter(e=>e.fieldName!==i.fieldName):n},n)},u=t=>{let n=t.attributes.elements.filter(e=>e.elementType!==`button`).filter(t=>e.clientId!==`nrn`||p(t));return{...t,attributes:{...t.attributes,elements:n}}},d=async()=>{let{default_gating_form:n}=await t.getEntitlementFormConfiguration()||{},i={},o=e.entryData?.gateWithExternalForm,s=!1,d=!1,f=!1,p=e.entryData.sponsors&&e.entryData.sponsors?.length>1?`sponsors mentioned above`:e.entryData.sponsors?.[0]?.title??``;if(e.entryData.sponsorshipGatingExternalFormId){let n=await t.getFormById(e.entryData.sponsorshipGatingExternalFormId,!1,{"x-content-type":e.contentType});d=Fe(e.clientId,e.entryData?.isPaidContent||!1)||n.hideThirdPartyConsent,s=!e.iirisUserProfile,f=n.hideThirdPartyConsent,e.iirisUserProfile&&(n.attributes.elements=c(e.iirisUserProfile,n.attributes.elements)),e.entryData.gateWithSiteReg||(s=!1),i[e.entryData.sponsorshipGatingExternalFormId]=u(n)}else if(n){let r=await t.getFormById(n,!1,{"x-content-type":e.contentType});(!e.entryData.gateWithExternalForm||e.entryData.gateWithExternalForm===`None`)&&(o=r.formType===P.HUBSPOT?P.HUBSPOT:P.ELOQUA),e.iirisUserProfile&&(r.attributes.elements=l(e.iirisUserProfile,r.attributes.elements)),i[n]=u(r)}a(e=>({...e,status:H.NEW})),r(t=>({formId:e.entryData.sponsorshipGatingExternalFormId,formStorage:e.entryData.gateWithExternalForm===`None`?o:e.entryData.gateWithExternalForm,forms:{...t.forms,...i},error:null,hideFirstPartyConsent:s,hideThirdPartyConsent:d,forceThirdPartyConsentAsFalse:f,sponsorName:p||void 0}))},f=async()=>{var t;try{a(e=>({...e,status:H.PENDING})),await d()}catch(n){(t=e.loadErrorCallback)==null||t.call(e,n),Kt(n),a(e=>({...e,status:H.ERROR,message:`We are having issues responding to your request! Please try again later.`})),r(e=>({...e,error:!0}))}},p=e=>!me.includes(e.fieldName)||!!e.validations?.some(e=>e.type===`IsRequiredCondition`);(0,w.useEffect)(()=>{var t;(t=e.loadSuccessCallback)==null||t.call(e)},[]),(0,w.useEffect)(()=>{f()},[e.iirisUserProfile]);let m=(0,w.useMemo)(()=>{let t=[];
4return Object.keys(n.forms).forEach(e=>{let r=n.forms[e];t=[...t,...r?.attributes?.elements||[]]}),Sr(t,e.clientId)},[n.forms,e.clientId]),h=(0,w.useMemo)(()=>Le(m,n.sponsorName||``),[m,n.sponsorName]),g=(0,w.useMemo)(()=>Object.keys(n.forms).map(e=>{let t=n.forms[e];return M.jsx(er,{formResponse:t},e)}),[n.forms]);return M.jsxs(`div`,{ref:o,children:[g,M.jsx(K.Provider,{value:ct(e.classNames,`entitlement`),children:M.jsx(xr,{platformApiService:t,contentType:e.contentType,contentId:e.contentId,submissionCallback:e.submissionCallback,completionCallback:e.completionCallback,submissionErrorCallback:e.submissionErrorCallback,loadErrorCallback:e.loadErrorCallback,formInteractionCallback:e.formInteractionCallback,countryCode:e.iirisUserProfile?.country,iirisUserProfile:e.iirisUserProfile,elements:h,subscriptionStateHandler:s,subscriptionState:i,inContextValidationMessage:e.inContextValidationMessage,formId:n.formId||``,hideFirstPartyConsent:n.hideFirstPartyConsent,gatingAction:e.gatingAction,hideThirdPartyConsent:n.hideThirdPartyConsent,sponsorName:n.sponsorName,title:e.overrides?.title??`Gain Access`,forceThirdPartyConsentAsFalse:n.forceThirdPartyConsentAsFalse,subtitle:m.length?e.overrides?.subtitle||`Please provide us with a few more details to continue.`:void 0,submitButtonText:e.overrides?.submitButtonText,formStorage:n.formStorage,isLeadGenPage:e.isLeadGenPage,emailAddress:e.emailAddress||``,unlockedSubmitButtonText:e.overrides?.unlockedSubmitButtonText||``,unlockedContentCallback:e.unlockedContentCallback})})]})}var jr=e=>(t,n)=>{let r=t?`${e}-${t}`:e;return n?`${r} ${r}--${n}`:r},Mr=e=>{var t;return!!((t=e.validations)!=null&&t.some(({type:e})=>e===`IsRequiredCondition`))},Nr=e=>e.filter(e=>e.inputType!==`hidden`||e.elementType===`button`).reduce((e,t)=>{var n;let r=e.set(t.fieldName,{...t,isRequired:Mr(t),isHidden:!1,value:``});if((n=t.dependentElements)!=null&&n.length)for(let{element:n}of t.dependentElements)e.set(n.fieldName,{...n,isRequired:!1,isHidden:!0,validations:[]});return r},new Map),Pr=e=>({...e,isHidden:!0,isRequired:!1,value:``,validations:[]}),Fr=(e,t,n)=>{let[r,i]=(0,w.useState)(!1),[a,o]=(0,w.useState)(new Map),[s,c]=(0,w.useState)(),l=(0,w.useRef)(n?.onLoadError);l.current=n?.onLoadError,(0,w.useEffect)(()=>{(async()=>{var n;if(t){i(!0);try{let n=await e.getFormById(t);o(Nr(n.attributes.elements)),c(n.formType)}catch(e){(n=l.current)==null||n.call(l,e)}finally{i(!1)}}})().then()},[t]);let u=new et,d=e=>{if(!t)return;e.preventDefault();let{currentTarget:n}=e,r=n.value,i=a.get(n.name);if(!i)throw Error(`use-form: Element with name ${n.name} not found`);i.elementType===`checkbox`&&(r=``+n?.checked),i.errors=u.validateFormField(r,i),i.value=r,i.touched=!0,a.set(n.name,i);let s=i?.dependentElements||[];for(let{element:e}of s){let t=Pr(e);a.set(e.fieldName,t)}let c=s.filter(({filters:e})=>e.some(({strValues:e})=>e.includes(r)));for(let{formFieldAction:e,element:t,filters:n}of c){let i=Pr(t);e===F.DISPLAY&&(i.isHidden=!At(r,n),i.isRequired=Mr(t),i.validations=t.validations),a.set(t.fieldName,i)}o(new Map(a))},f=e=>{if(!t)return!0;let n=!1;for(let[t,r]of Array.from(a)){if(e&&!e.includes(t))continue;let i=u.validateFormField(r.value,r);i!=null&&i.length&&(r.errors=i,a.set(t,r),n=!0)}return o(new Map(a)),!n},p=Array.from(a.values()).map(e=>e);return{loading:r,fields:p,formType:s,handleChange:d,validate:f,errors:p.filter(e=>e.errors?.length).flatMap(e=>(e?.errors)?.map(t=>`${e.label}: ${t.message}`))}},Ir=new Vt,Lr=(e,t)=>{let[n,r]=(0,w.useState)(!1),[i,a]=(0,w.useState)(``),[o,s]=(0,w.useState)(!1),[c,l]=(0,w.useState)(``),[u,d]=(0,w.useState)([]);(0,w.useEffect)(()=>{if(t){let n=Ir.getCategoryByCountryCode(t);a(n),l(``),s(n===J.categoryB||n===J.categoryC),r(e===`firstParty`?Ir.getFirstConsentValue(t,``):Ir.getThirdConsentValue(t,``))}},[t,e]);let f=n=>{let i=n.currentTarget,a=Ir.getValueByElement(i),o=e===`firstParty`?Ir.getFirstConsentValue(t,a):Ir.getThirdConsentValue(t,a);r(o),l(a),s(!0)},p=()=>{if(!t)return!0;switch(i){case J.categoryA:return o;case J.categoryD:return!0;default:return!0}};return{category:i,value:n,isValid:p(),handleChange:f,validate:()=>{let e=p();return d(e?[]:[`Please choose consent agreement`]),e},errors:u}},Rr=e=>new Ze(e.elnUrl,e.brandId,e.authorization,e.context,e.subBrandId,e.elnVersion,e.iirisUserProfile,e.productId),zr={loadFailure:{transactionInitiated:`failure`,formSubmitted:`failure`,submissionSucceeded:`failure`},submitSuccess:{transactionInitiated:`success`,formSubmitted:`success`,submissionSucceeded:`success`},submitConflict:{transactionInitiated:`success`,formSubmitted:`success`,submissionSucceeded:`failure`},submitFailure:{transactionInitiated:`success`,formSubmitted:`failure`,submissionSucceeded:`failure`}},Br=new Set([`US`,`CA`,`AU`,`BR`,`CN`,`IN`,`MX`]),Vr=`Please select at least one newsletter`,Hr=`We are having issues responding to your request! Please try again later.`,Ur=e=>
4({...e.utmParams,elnPackageVersion:e.packageVersion,formInstanceName:e.formType,formHTMLName:e.formId,userLoggedIn:e.profileId?`Logged In`:`Anonymous`}),Wr=e=>e?.response?.status===409?zr.submitConflict:zr.submitFailure,Gr=e=>{let t=Rr({elnUrl:e.platformServiceBaseUrl,elnVersion:e.version,authorization:e.authorization,brandId:e.clientId,subBrandId:e.subBrandId,context:e.context,iirisUserProfile:e.iirisUserProfile,productId:e.productId}),[n,r]=(0,w.useState)(L.COLLAPSED),[i,a]=(0,w.useState)(()=>new Set(e.newsletters?.length===1?[e.newsletters[0].newsletter_code]:[])),[o,s]=(0,w.useState)(new Set),[c,l]=(0,w.useState)(null),[u,d]=(0,w.useState)(null),[f,p]=(0,w.useState)(!1),[m,h]=(0,w.useState)(!1),[g,_]=(0,w.useState)(``),v=e=>{_(e||``)},[y,b]=(0,w.useState)(`idle`),x=(0,w.useRef)([]),S=!Re(e.iirisUserProfile),ee=e.iirisUserProfile?.business_email||``,te=S&&n<L.EXPANDED?L.EXPANDED:n,{loading:ne,fields:C,formType:T,handleChange:E,validate:D}=Fr(t,e.formId,{onLoadError:t=>{var n;d(Hr),k(zr.loadFailure),(n=e.onError)==null||n.call(e,Je(t))}}),O=(0,w.useCallback)(()=>Ur({formId:e.formId,formType:T,profileId:e.iirisUserProfile?.id,utmParams:Ae(),packageVersion:je}),[e.formId,e.iirisUserProfile,T]),k=t=>{var n;(n=e.completionCallback)==null||n.call(e,{...O(),...t})},[re,A]=(0,w.useState)(``),j=re||ze(C,`country`),{category:ie,value:ae,isValid:oe,handleChange:M,validate:N,errors:P}=Lr(`firstParty`,j),F=C.find(e=>e.fieldName.toLowerCase().includes(`email`)),I=C.filter(e=>e!==F),se=S?ee:F?.value||``,ce=S?[]:C,le=(0,w.useRef)(!1),{onLoad:ue}=e;(0,w.useEffect)(()=>{!le.current&&!ne&&C.length>0&&(le.current=!0,ue?.(O()))},[ne,C.length,ue,O]);let R=t=>{r(n=>{var r;return t>n?((r=e.onStageChange)==null||r.call(e,t),t):n})},de=()=>{R(L.EXPANDED)},fe=e=>{R(L.EXPANDED),a(t=>{let n=Ye(t,e);return l(n.size===0?Vr:null),n})},z=e=>{s(t=>{let n=Ye(t,e);return l(n.size===0?Vr:null),n})},B=e=>{let t=Br.has(e);R(t?L.STATE:L.CONSENT)},V=e=>{E(e);let t=e.currentTarget,n=t.name?.toLowerCase()||``;n===`country`?B(t.value):(n.includes(`state`)||n.includes(`province`))&&R(L.CONSENT)},pe=(e,t)=>{x.current=e;for(let t of e){let e=t.htmlName.toLowerCase();if(e.includes(`country`)&&t.value&&(A(t.value),t.touched)){let e=Br.has(t.value);R(e?L.STATE:L.CONSENT)}(e.includes(`state`)||e.includes(`province`))&&t.value&&t.touched&&R(L.CONSENT)}},H=()=>x.current.every(e=>{var t;return!((t=e.violations)!=null&&t.length)}),U=()=>{let e=i.size>0;if(e||l(Vr),S)return e;let t=F?.fieldName,n=D(t?[t]:[]),r=H(),a=N();return e&&n&&r&&a&&!!g},me=()=>[{htmlName:F?.fieldName||`emailAddress`,value:se,touched:F?.touched||!1,violations:[]},...x.current],he=t=>({formId:e.formId,countryCode:j,emailAddress:se,firstPartyConsent:ae,newsletterList:t,formFields:me()}),ge=n=>t.putNewslettersSubscription(he(n),g,e.iirisUserProfile,ce),_e=async t=>{var n,r,a;if(t.preventDefault(),(n=e.onSubmit)==null||n.call(e),h(!0),d(null),U())try{p(!0),await ge(Array.from(i)),R(L.SUCCESS),k(zr.submitSuccess),h(!1),(r=e.onSuccess)==null||r.call(e,{})}catch(t){d(Hr),k(Wr(t)),(a=e.onError)==null||a.call(e,Je(t))}finally{p(!1)}},ve=async()=>{var t,n;let r=Array.from(o);if(h(!0),d(null),r.length===0){l(Vr);return}b(`loading`);try{await ge(r),b(`done`),k(zr.submitSuccess),(t=e.onAddSubscriptionsSuccess)==null||t.call(e,r)}catch(t){d(Hr),b(`idle`),k(Wr(t)),(n=e.onError)==null||n.call(e,Je(t))}};return{stage:te,isLoggedIn:S,profileEmail:ee,formLoading:ne,emailField:F,otherFields:I,formFields:C,countryCode:j,handleFieldChange:V,handleFormFieldChange:E,handleFormBuilderChange:pe,handleCountryChange:B,selectedCodes:i,secondarySelectedCodes:o,handleNewsletterToggle:fe,handleSecondaryToggle:z,consentCategory:ie,consentValue:ae,consentIsValid:oe,handleConsentChange:M,handleEmailFocus:de,handleSubmit:_e,errors:[...c?[c]:[],...P||[]],newsletterError:c,submissionError:u,showAllViolations:m,submitting:f,captchaToken:g,setCaptchaToken:v,addSubscriptionsState:y,handleAddSubscriptions:ve,validate:U}},Kr=8,qr=(e,t)=>{let[n,r]=(0,w.useState)(null);return(0,w.useEffect)(()=>{if(!t){r(null);return}let n=()=>{let t=e.current?.getBoundingClientRect();t&&r({top:t.bottom+Kr,left:t.left})};return n(),window.addEventListener(`scroll`,n,!0),window.addEventListener(`resize`,n),()=>{window.removeEventListener(`scroll`,n,!0),window.removeEventListener(`resize`,n)}},[t,e]),n},Jr=jr(`eln-newsletter-subscription`);function Yr({title:e,description:t,icon:n}){let[r,i]=(0,w.useState)(!1),a=(0,w.useId)(),o=(0,w.useRef)(null),s=qr(o,r);return M.jsxs(`span`,{className:Jr(`card-info`),children:[M.jsx(`button`,{ref:o,type:`button`,className:Jr(`card-info-button`),"aria-label":`More information about ${e}`,"aria-expanded":r,"aria-controls":a,onClick:()=>i(e=>!e),onBlur:()=>i(!1),onKeyDown:e=>{e.key===`Escape`&&i(!1)},children:M.jsx(`span`,{className:Jr(`card-info-icon`),"aria-hidden":`true`,children:n})}),r&&s?(0,D.createPortal)(M.jsx(`span`,{role:`tooltip`,id:a,className:Jr(`card-tooltip`),style:{position:`fixed`,top:s.top,left
4:s.left},children:t}),document.body):null]})}var Xr=jr(`eln-newsletter-subscription`);function Zr({newsletter:e,checked:t,onChange:n,cardInfoIcon:r,cardFrequencyIcon:i}){var a,o;let s=()=>{n(e.newsletter_code)};return M.jsxs(`div`,{className:Xr(`card`),onClick:e=>{let t=e.target;t.closest(`label`)||t.closest(`button`)||t.tagName===`A`||s()},children:[M.jsxs(`div`,{className:Xr(`card-header`),children:[M.jsxs(`label`,{className:Xr(`card-label`),children:[M.jsx(`input`,{className:Xr(`card-checkbox`),type:`checkbox`,checked:t,onChange:s,name:`newsletterSubscriptionList`,value:e.newsletter_code}),M.jsx(`span`,{className:Xr(`card-title`),children:e.title})]}),e.description?M.jsx(Yr,{title:e.title,description:e.description,icon:r}):null]}),e.frequency||(a=e.sample_url)!=null&&a.href?M.jsxs(`div`,{className:Xr(`card-meta`),children:[e.frequency?M.jsxs(`span`,{className:Xr(`card-frequency`),children:[i?M.jsx(`span`,{className:Xr(`card-frequency-icon`),"aria-hidden":`true`,children:i}):null,e.frequency]}):null,(o=e.sample_url)!=null&&o.href?M.jsx(`a`,{className:Xr(`card-sample-link`),href:e.sample_url.href,target:`_blank`,rel:`noreferrer`,children:e.sample_url.title}):null]}):null]})}var Qr=jr(`eln-newsletter-subscription`);function $r({newsletters:e,selectedCodes:t,onToggle:n,error:r,cardInfoIcon:i,cardFrequencyIcon:a}){return M.jsxs(`div`,{className:Qr(`card-grid`),children:[e.map(e=>M.jsx(Zr,{newsletter:e,checked:t.has(e.newsletter_code),onChange:n,cardInfoIcon:i,cardFrequencyIcon:a},e.newsletter_code)),r?M.jsx(`p`,{className:Qr(`card-grid-error`),children:r}):null]})}var ei=jr(`eln-newsletter-subscription`);function ti({message:e}){return M.jsx(`p`,{className:ei(`submission-error`),role:`alert`,children:e})}var ni=jr(`eln-newsletter-subscription`),ri=(e,{emailPlaceholder:t,isLoggedIn:n,profileEmail:r})=>e&&{...e,...t?{placeholder:t}:{},...n?{value:r,disabled:!0}:{}};function ii({stage:e,emailField:t,emailPlaceholder:n,isLoggedIn:r,profileEmail:i,otherFields:a,newsletters:o,selectedCodes:s,onNewsletterToggle:c,onEmailFieldChange:l,onEmailFocus:u,onFormChange:d,onConsentChange:f,onSubmit:p,onCountryChange:m,countryCode:h,showAllViolations:g,consentValid:_=!0,inContextValidation:v,siteId:y,hideFirstPartyConsent:b,newsletterError:x,submissionError:S,submitLabel:ee,cardInfoIcon:te,cardFrequencyIcon:ne,submitting:C,captchaToken:w,setCaptchaToken:T,shouldShowCaptcha:E}){let D=ri(t,{emailPlaceholder:n,isLoggedIn:r,profileEmail:i}),O=e>=L.EXPANDED,k=!r&&a.length>0,re=!b,A=O&&E;return M.jsx(`div`,{className:ni(`form`),children:M.jsxs(`form`,{noValidate:!0,onSubmit:p,children:[D?M.jsx(_t,{element:D,handleChange:l,showAllViolations:g,showErrorMessages:v||g,onFocus:u,className:ni(`email-field`)}):null,M.jsx(`div`,{className:ni(`expandable`),"data-expanded":O,inert:!O,children:M.jsxs(`div`,{className:ni(`expandable-content`),children:[M.jsx($r,{newsletters:o,selectedCodes:s,onToggle:c,error:g?x:null,cardInfoIcon:te,cardFrequencyIcon:ne}),k?M.jsx(`div`,{className:ni(`fields`),children:M.jsx(Ft,{elements:a,onChange:d,showAllViolations:g,showErrorMessages:v||g,siteId:y,handleCountryChange:m})}):null,re?M.jsx(`div`,{className:ni(`consent`),children:M.jsx(Ut,{countryCode:h,changeHandler:f,error:g&&!_})}):null,A&&T?M.jsx(Yn,{className:ni(`captcha`),setToken:T,error:g&&!w}):null]})}),S?M.jsx(ti,{message:S}):null,t?M.jsx(`button`,{className:ni(`submit`),type:`submit`,disabled:C,children:ee}):null]})})}var ai=jr(`eln-newsletter-subscription`);function oi({email:e,successTitle:t,successMessage:n,secondaryNewsletters:r,onAddSubscriptions:i,addSubscriptionsState:a,successSecondaryTitle:o=`Sign up for additional newsletters`,successSecondarySubtitle:s=`Enhance your experience and get deeper insights by subscribing to additional newsletters.`,successAddSubscriptionsLabel:c=`Add Subscriptions +`,successAddSubscriptionsConfirmation:l=`Additional newsletters have been added to your subscription.`,cardInfoIcon:u,cardFrequencyIcon:d,newsletterError:f,submissionError:p,showAllViolations:m,secondarySelectedCodes:h,onSecondaryToggle:g}){let _=()=>{i?.()},v=Rt(e,n);return M.jsxs(`div`,{className:ai(`success`),children:[M.jsx(`h1`,{className:ai(`success-title`),children:t}),M.jsx(`p`,{className:ai(`success-message`),children:v}),r.length>0?M.jsxs(`div`,{className:ai(`success-secondary`),children:[M.jsx(`h2`,{className:ai(`success-secondary-title`),children:o}),M.jsx(`p`,{className:ai(`success-secondary-subtitle`),children:s}),M.jsx($r,{newsletters:r,selectedCodes:h,onToggle:g,cardInfoIcon:u,cardFrequencyIcon:d,error:m?f:null}),p?M.jsx(ti,{message:p}):null,a===`done`?null:M.jsx(`button`,{className:ai(`success-add-btn`),onClick:_,disabled:a===`loading`,children:c}),a===`done`?M.jsx(`p`,{className:ai(`success-add-confirmation`),children:l}):null]}):null]})}var si=jr(`eln-newsletter-subscription`),ci=[];function li(e){let{stage:t,isLoggedIn:n,profileEmail:r,formLoading:i,emailField:a,otherFields:o,handleFormFieldChange:s,handleFormBuilderChange:c,handleCountryChange:l,countryCode:u,selectedCodes:d,secondarySelectedCodes:f,handleNewsletterToggle:p,handleSecondaryToggle:m,consentIsValid:h,handleConsentChange:g,handleEmailFocus:_,handleSubmit:v,newsletterError:y,submissionError:b,showAllViolations:x,submitting:S,captchaToken:ee,setCaptchaToken:te,addSubscriptionsState:ne,handleAddSubscriptions:C}=Gr({platformServiceBaseUrl:e.platformServiceBaseUrl,clientId:e.clientId,formId:e.formId,authorization:e.authorization,subBrandId:e.subBrandId,version:e.version,productId:e.productId,newsletters:e.newsletters,secondaryNewsletters:e.secondaryNewsletters,iirisUserProfile:e.iirisUserProfile,context:e.context,onLoad:e.onLoad,onStageChange:e.onStageChange,onSubmit:e.onSubmit,onSuccess:e.onSuccess,onAddSubscriptionsSuccess:e.onAddSubscriptionsSuccess,onError:e.onError,completionCallback:e.completionCallback}),w=ct(e.classNames,`newsletter`);if(i||S||ne===`loading`)return M.jsx(Wt,{});let T=t===L.SUCCESS,E=e.secondaryNewsletters||ci;return M.jsx(K.Provider,{value:w,children:M.jsxs(`div`,{className:si(null,`stage-${t}`),children:[e.title?M.jsx(`h2`,{className:si(`title`),children:e.title}):null,e.subtitle?M.jsx(`p`,{className:si(`subtitle`),children:e.subt
4itle}):null,T?M.jsx(oi,{email:a?.value||``,successTitle:e.successTitle,successMessage:e.successMessage,secondaryNewsletters:E,onAddSubscriptions:C,addSubscriptionsState:ne,successSecondaryTitle:e.successSecondaryTitle,successSecondarySubtitle:e.successSecondarySubtitle,successAddSubscriptionsLabel:e.successAddSubscriptionsLabel,successAddSubscriptionsConfirmation:e.successAddSubscriptionsConfirmation,cardInfoIcon:e.cardInfoIcon,cardFrequencyIcon:e.cardFrequencyIcon,newsletterError:y,submissionError:b,showAllViolations:x,secondarySelectedCodes:f,onSecondaryToggle:m}):M.jsx(ii,{stage:t,emailField:a,emailPlaceholder:e.emailPlaceholder,isLoggedIn:n,profileEmail:r,otherFields:o,newsletters:e.newsletters,selectedCodes:d,onNewsletterToggle:p,onEmailFieldChange:s,onEmailFocus:_,onFormChange:c,onConsentChange:g,onSubmit:v,onCountryChange:l,countryCode:u,showAllViolations:x,consentValid:h,inContextValidation:e.inContextValidation||!1,siteId:e.clientId,hideFirstPartyConsent:n,newsletterError:y,submissionError:b,submitLabel:e.submitLabel||`Subscribe`,cardInfoIcon:e.cardInfoIcon,cardFrequencyIcon:e.cardFrequencyIcon,submitting:S,captchaToken:ee,setCaptchaToken:te,shouldShowCaptcha:!e.iirisUserProfile&&He(e.clientId)})]})})}export{l as C,f as S,h as _,tr as a,g as b,T as c,te as d,p as f,v as g,y as h,Qe as i,E as l,s as m,L as n,$e as o,b as p,Ar as r,Ne as s,li as t,ne as u,m as v,u as x,_ as y};
5//# sourceMappingURL=index.es-CZ6BWE4M.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.