1!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).disw={})}(this,function(e){"use strict";const t="dev",n="uat",o="prod",r={isValidEnv(){try{return"prod"!==o}catch(e){return!0}},log(e,t=""){this.isValidEnv()},warn(e){this.isValidEnv()},error(e){this.isValidEnv()},debug(e,t=""){this.isValidEnv()}},i="disw.featureFlags",a="disw.featureFlags.cache",c=500;let u={},s=!1,l="prod";function d(){return"prod"!==l}function f(){if(!d())return{};try{const e=localStorage.getItem(i);if(!e)return{};const t=JSON.parse(e);if("object"==typeof t&&null!==t&&!Array.isArray(t))return t}catch{r.warn("[features] Failed to parse localStorage overrides â ignoring.")}return{}}async function p(e){const{apiUrl:t,timeout:n=c,env:o}=e;l=o||function(){try{const e=window.disw?.context?.getEnv?.();if(e)return e}catch{}try{const e="prod";if(e&&""!==e)return e}catch{}try{const e=window.location?.hostname||"";if("localhost"===e||"127.0.0.1"===e)return"dev";if(e.includes("-dev")||e.includes(".dev."))return"dev";if(e.includes("-uat")||e.includes(".uat.")||e.includes("-qa"))return"uat";if(e.includes("-staging")||e.includes(".staging."))return"staging"}catch{}return"prod"}();const i=await async function(e,t){const n=new AbortController,o=setTimeout(()=>n.abort(),t);try{const t=await fetch(e,{method:"GET",signal:n.signal,headers:{Accept:"application/json"}});if(clearTimeout(o),!t.ok)return r.warn(`[features] API returned ${t.status} â falling back to defaults.`),null;const i=await t.json();if("object"!=typeof i||null===i||Array.isArray(i))return r.warn("[features] API returned malformed response â falling back to defaults."),null;const a={};for(const[e,t]of Object.entries(i))a[e]=Boolean(t);return a}catch(e){return clearTimeout(o),e instanceof Error&&"AbortError"===e.name?r.warn(`[features] API request timed out after ${t}ms â falling back to defaults.`):r.warn(`[features] API request failed: ${e} â falling back to defaults.`),null}}(t,n);if(i)u={...i},function(e){try{localStorage.setItem(a,JSON.stringify(e))}catch{r.warn("[features] Failed to save flags to localStorage cache.")}}(i),r.log("[features] Loaded live feature flags from API (cached to localStorage).");else{const e=function(){try{const e=localStorage.getItem(a);if(!e)return null;const t=JSON.parse(e);if("object"==typeof t&&null!==t&&!Array.isArray(t))return t}catch{r.warn("[features] Failed to parse localStorage cache â ignoring.")}return null}();e?(u={...e},r.log("[features] API unavailable â using cached flag values from localStorage.")):(u={},r.warn("[features] API unavailable, no cache â all flags will return false (fail-closed)."))}const d=f();Object.keys(d).length>0&&(u={...u,...d},r.log(`[features] Applied ${Object.keys(d).length} localStorage override(s).`)),s=!0,r.log(`[features] Initialization complete. Flags: ${JSON.stringify(u)}`)}function _(e){return s?u[e]??!1:(r.warn(`[features] isEnabled('${e}') called before initialization â returning false.`),!1)}function g(){return{...u}}function m(e,t){d()?(u[e]=t,function(e,t){try{const n=f();n[e]=t,localStorage.setItem(i,JSON.stringify(n))}catch{r.warn("[features] Failed to persist override to localStorage.")}}(e,t),r.log(`[features] ${e} = ${t} (applied + persisted).`)):r.warn("[features] Overrides are not allowed in production.")}function h(e){m(e,!0)}function y(e){m(e,!1)}function v(e){m(e,!(u[e]??!1))}function w(e,t){d()?(u[e]=t,r.log(`[features] Override applied: ${e} = ${t} (ephemeral, until refresh).`)):r.warn("[features] Overrides are not allowed in production.")}function C(){if(d())try{localStorage.removeItem(i),r.log("[features] All localStorage overrides cleared. Refresh to apply.")}catch{r.warn("[features] Failed to clear localStorage overrides.")}else r.warn("[features] Overrides are not allowed in production.")}var b={isEnabled:_,getAll:g,set:m,enable:h,disable:y,toggle:v,override:w,clearOverrides:C};const S={LOCALES:"locales",ACCOUNT:"ACCOUNT",USER:"USER",BREADCRUMBS:"BREADCRUMBS",ECOMMERCE:"ECOMMERCE",CART:"CART",CONSENT:"CONSENT",COUNTRY:"COUNTRY",REGION:"REGION",DROP_DOWN:"DROP_DOWN",NUMERIC_STEPPER:"NUMERIC_STEPPER",ADDED_TO_CART_MODAL:"ADDED_TO_CART_MODAL",DYNAMIC_KIT_SLIDEOUT:"DYNAMIC_KIT_SLIDEOUT",DYNAMIC_KIT_ADD_TO_CART:"DYNAMIC_KIT_ADD_TO_CART",BASE_KIT_SLIDER:"BASE_KIT_SLIDEOUT",BASE_KIT_OPEN_SLIDEOUT:"BASE_KIT_OPEN_SLIDEOUT",MINI_CART:"MINI_CART",FULL_CART:"FULL_CART",LIVE_CHAT:"LIVE_CHAT",SUBCRIPTION_TERMS_CONFLICT_MODAL:"SUBSCRIPTION_TERMS_CONFLICT_MODAL",VOLUME_BASED_PRICING_MODEL:"VOLUME_BASED_PRICING_MODEL",VISITOR:"VISITOR",TRIAL:"TRIAL",RELATED_RESOURCES:"RELATED_RESOURCES"},I=new Map,T=new Map;function L(e){const t=Math.floor(1e3*Math.random()+1);return I.has(e)&&I.get(e)?.[t]?L(e):t}function E(e,...t){if(I.has(e))for(const n of Object.values(I.get(e))){const e=n;setTimeout(()=>{e(...t)},0)}T.set(e,t)}function A(e,t){const n=L(e);return I.has(e)||I.set(e,{}),I.get(e)[n]=t,T.has(e)&&t(...T.get(e)),function(){delete I.get(e)[n]}}var R=Object.freeze({__proto__:null,events:S,emit:E,subscribe:A});const N="en-US",k=N,U=[{code:"bg-BG",name:"Bulgarian",nativeLanguageName:"бÑлгаÑÑки",fallbackCode:N,localeLanguage:"BG",countryName:"Bulgaria"},{code:"cs-CZ",name:"Czech",nativeLanguageName:"ÄeÅ¡tina",fallbackCode:N,localeLanguage:"CS",countryName:"Czech Republic"},{code:"da-DK",name:"Danish",nativeLanguageName:"Dansk",fallbackCode:N,localeLanguage:"DA",countryName:"Denmark"},{code:"de-DE",name:"German (Germany)",nativeLanguageName:"Deutsch",fallbackCode:N,localeLanguage:"DE",countryName:"Deutschland"},{code:"de-CH",name:"German (Switzerland)",nativeLanguageName:"Deutsch (Schweiz)",fallbackCode:N,localeLanguage:"DE",countryName:"Schweiz"},{code:"et-EE",name:"Estonian",nativeLanguageName:"Eesti",fallbackCode:N,localeLanguage:"ET",countryName:"Estonia"},{code:"en-GB",name:"English (UK)",nativeLanguageName:"English (UK)",fallbackCode:N,localeLanguage:"EN",countryName:"UK, Australia, Ireland, India, UAE, South Africa, Singapore, Saudi Arabia, Qatar, Philippines, Oman, Malaysia, Kuwait, Israel, Indonesia, Bangladesh, Thailand"},{code:N,name:"U.S. English",nativeLanguageName:"English (US)",fallbackCode:null,localeLanguage:"EN",countryName:"United States"}
1,{code:"es-ES",name:"Spanish (Spain)",nativeLanguageName:"Español (España)",fallbackCode:N,localeLanguage:"ES",countryName:"España"},{code:"es-MX",name:"Spanish (Mexico)",nativeLanguageName:"Español (México)",fallbackCode:N,localeLanguage:"ES",countryName:"MexÃco, Argentina, Bolivia, Chile, Colombia, Ecuador, Peru, Uruguay"},{code:"fi-FI",name:"Finnish",nativeLanguageName:"Suomi",fallbackCode:N,localeLanguage:"FI",countryName:"Finland"},{code:"fr-CA",name:"French (Canada)",nativeLanguageName:"Français (Canada)",fallbackCode:N,localeLanguage:"FR",countryName:"Canada"},{code:"fr-FR",name:"French (France)",nativeLanguageName:"Français (France)",fallbackCode:N,localeLanguage:"FR",countryName:"France"},{code:"el-GR",name:"Greek",nativeLanguageName:"Îλληνικά",fallbackCode:N,localeLanguage:"EL",countryName:"Greece"},{code:"hr-HR",name:"Croatian",nativeLanguageName:"Hrvatski",fallbackCode:N,localeLanguage:"HR",countryName:"Croatia"},{code:"it-IT",name:"Italian (Italy)",nativeLanguageName:"Italiano",fallbackCode:N,localeLanguage:"IT",countryName:"Italia"},{code:"lv-LV",name:"Latvian",nativeLanguageName:"LatvieÅ¡u",fallbackCode:N,localeLanguage:"LV",countryName:"Latvia"},{code:"lt-LT",name:"Lithuanian",nativeLanguageName:"Lietuvių",fallbackCode:N,localeLanguage:"LT",countryName:"Lithuania"},{code:"hu-HU",name:"Hungarian",nativeLanguageName:"Magyar",fallbackCode:N,localeLanguage:"HU",countryName:"Hungary"},{code:"nl-NL",name:"Dutch",nativeLanguageName:"Nederlands",fallbackCode:N,localeLanguage:"NL",countryName:"Netherland, Belgium"},{code:"no-NO",name:"Norse / Norwegian",nativeLanguageName:"Norge",fallbackCode:N,localeLanguage:"NO",countryName:"Norway"},{code:"pl-PL",name:"Polish (Poland)",nativeLanguageName:"Polski",fallbackCode:N,localeLanguage:"PL",countryName:"Polska"},{code:"pt-BR",name:"Portuguese (Brazil)",nativeLanguageName:"Português (Brasil)",fallbackCode:N,localeLanguage:"PT",countryName:"Brasil"},{code:"pt-PT",name:"Portuguese (Portugal)",nativeLanguageName:"Português (Portugal)",fallbackCode:N,localeLanguage:"PT",countryName:"Portugal"},{code:"ro-RO",name:"Romanian",nativeLanguageName:"RomânÄ",fallbackCode:N,localeLanguage:"RO",countryName:"Romania"},{code:"ru-RU",name:"Russian (Russia)",nativeLanguageName:"Ð ÑÑÑкий",fallbackCode:N,localeLanguage:"RU",countryName:"РоÑÑиÑ"},{code:"sk-SK",name:"Slovak",nativeLanguageName:"SlovenÄina",fallbackCode:N,localeLanguage:"SK",countryName:"Slovakia"},{code:"sl-SI",name:"Slovenian",nativeLanguageName:"SlovenÅ¡Äina",fallbackCode:N,localeLanguage:"SL",countryName:"Slovenia"},{code:"sr-Latn-RS",name:"Serbian (Latin, Serbia)",nativeLanguageName:"Srpski",fallbackCode:N,localeLanguage:"SR",countryName:"Serbia"},{code:"sv-SE",name:"Swedish",nativeLanguageName:"Svenska",fallbackCode:N,localeLanguage:"SV",countryName:"Sweden"},{code:"th-TH",name:"Thai",nativeLanguageName:"à¹à¸à¸¢",fallbackCode:N,localeLanguage:"TH",countryName:"Thailand"},{code:"vi-VN",name:"Vietnamese",nativeLanguageName:"Tiếng Viá»t",fallbackCode:N,localeLanguage:"VI",countryName:"Vietnam"},{code:"tr-TR",name:"Turkish",nativeLanguageName:"Türkçe",fallbackCode:N,localeLanguage:"TR",countryName:"Turkey"},{code:"uk-UA",name:"Ukrainian",nativeLanguageName:"УкÑаÑнÑÑка",fallbackCode:N,localeLanguage:"UK",countryName:"Ukraine"},{code:"zh-CN",name:"Chinese (Simplified)",nativeLanguageName:"䏿ï¼ç®ä½ï¼",fallbackCode:N,localeLanguage:"ZH",countryName:"China"},{code:"zh-TW",name:"Chinese (Traditional)",nativeLanguageName:"䏿ï¼ç¹é«ï¼",fallbackCode:N,localeLanguage:"ZH",countryName:"Taiwan"},{code:"ja-JP",name:"Japanese (Kanji)",nativeLanguageName:"æ¥æ¬èª",fallbackCode:N,localeLanguage:"JA",countryName:"Japan"},{code:"ko-KR",name:"Korean",nativeLanguageName:"íêµì´",fallbackCode:N,localeLanguage:"KO",countryName:"South Korea"}],P={getCurrentUrl:()=>"undefined"==typeof window?"":window.location.href,getPathname:()=>"undefined"==typeof window?"":window.location.pathname,getSearch:()=>"undefined"==typeof window?"":window.location.search,getHash:()=>"undefined"==typeof window?"":window.location.hash,getOrigin:()=>"undefined"==typeof window?"":window.location.origin,getHostname:()=>"undefined"==typeof window?"":window.location.hostname,getProtocol:()=>"undefined"==typeof window?"":window.location.protocol,getPort:()=>"undefined"==typeof window?"":window.location.port,navigate(e){"undefined"!=typeof window&&(window.location.href=e)},assignAndNavigate(e){"undefined"!=typeof window&&window.location.assign(e)},reload(){"undefined"!=typeof window&&window.location.reload()},replace(e){"undefined"!=typeof window&&window.location.replace(e)},pushState(e,t,n){"undefined"!=typeof window&&window.history&&window.history.pushState(e,t,n)},replaceState(e,t,n){"undefined"!=typeof window&&window.history&&window.history.replaceState(e,t,n)}};let O=U.map(e=>e.code);function D(){return[...O]}function M(e){if(!Array.isArray(e))throw new Error("setSupportedLocales: Expected array of locale codes");O=[...e]}const $=/^[a-z]{2}(-[A-Z][a-z]{3})?-[A-Z]{2}$/,x=/^\/([a-z]{2}-[A-Z]{2}|[a-z]{2}-[a-z]{2})(?=\/|$)/;function B(e,t=null,n="preserve"){if(!e||"string"!=typeof e)return e;const o=F(e);if("lowercase"===n)return o.toLowerCase();if("uppercase"===n){const e=o.split("-");return 2===e.length?`${e[0].toLowerCase()}-${e[1].toUpperCase()}`:o}return t?function(e,t){if(!e||!t)return t;const n=e.split("-"),o=t.split("-"),r=n[n.length-1],i=o[o.length-1];if(!r||!i||o.length<2)return t;const a=r===r.toLowerCase()?i.toLowerCase():i.toUpperCase(),c=[...o];c[0]=c[0].toLowerCase(),c[c.length-1]=a,3===c.length&&(c[1]=c[1].toLowerCase());return c.join("-")}(t,o):o}function F(e){if(!e||"string"!=typeof e)return e;const t=e.split("-");if(3===t.length){const[e,n,o]=t;if(4===n.length&&n.match(/^[A-Z][a-z]{3}$/))return`${e}-${o}
1`}return e}function j(e){if(!e)return[];const t=e.split("-");if(t.length<2)return[];const n=t[0];if(2!==n.length)return[];const o=t[t.length-1];if(2!==o.length)return[];const r=U.map(e=>e.code);return r.filter(e=>{const t=e.split("-"),r=t[0];if(2!==r.length)return!1;const i=t[t.length-1];if(2!==i.length)return!1;const a=r.toLowerCase()===n.toLowerCase(),c=i.toLowerCase()===o.toLowerCase();return a&&c})}function V(e){if(!e||"string"!=typeof e)return null;const t=e.match(x);return!t||t.length<2?null:t[1]}function H(e,t=P.getPathname()){if(!e||"string"!=typeof e||!$.test(e)){r.debug("generateLocalePath: Invalid locale code provided:",e);const n=new Error("generateLocalePath: Invalid locale code format");throw n.localeCode=e,n.pathname=t,n.code="INVALID_LOCALE_FORMAT",n}const n=V(t);if(!n){r.debug("generateLocalePath: There is no valid locale pattern in the URL path:",t);const e=new Error("generateLocalePath: No valid locale pattern found in the URL path");throw e.pathname=t,e.code="NO_LOCALE_IN_PATH",e}const o=B(e,n);return t.replace(x,`/${o}`)}function z(e){if(!e||"string"!=typeof e)return null;const t=U.find(t=>t.code===e);if(t)return t;const n=j(e);for(const e of n){const t=U.find(t=>t.code===e);if(t)return t}return null}function q(){const e=D(),t=V(P.getPathname());if(t){const n=function(e,t){if(!e||"string"!=typeof e||!Array.isArray(t))return null;const n=function(e){if(!e||"string"!=typeof e)return null;const t=e.split("-");if(2===t.length){const[e,n]=t;return`${e.toLowerCase()}-${n.toUpperCase()}`}return e}(e);if(!n)return null;const o=t.find(e=>n.toLowerCase()===B(e).toLowerCase());if(o)return o;const r=j(n);for(const e of r)if(t.includes(e))return e;return null}(t,e);if(n)return n}const n="undefined"!=typeof window&&window.navigator&&window.navigator.language||"";if(n){if(e.includes(n))return n;const t=j(n);for(const n of t)if(e.includes(n))return n}return k}function G(e){return e&&e.startsWith("//")}function K(e,t){return t?e.replace(/^https:/,""):e}function W(e){return V(e)?e.replace(/^\/([a-z]{2}-[A-Z]{2}|[a-z]{2}-[a-z]{2})/,""):e}function J(e,t,n=null,o="preserve"){const r=n||V(P.getPathname()),i=B(e,r,o);var a;return`/${r?i:i.toLowerCase()}${(a=t).startsWith("/")?a:`/${a}`}`}function Y(e){return e||q()}function Z(e,t,n="preserve"){const o=G(e),i=function(e){return e.startsWith("//")?`https:${e}`:e}(e),a=function(e){try{return new URL(e)}catch(t){return r.warn("Invalid URL format:",e,t),null}}(i);if(!a)return e;if("preserve"!==n){const e=V(a.pathname),r=J(t,W(a.pathname),e,n);a.pathname=r;return K(a.toString(),o)}try{const e=H(t,a.pathname);a.pathname=e;return K(a.toString(),o)}catch(e){const r=V(a.pathname),i=J(t,W(a.pathname),r,n);a.pathname=i;return K(a.toString(),o)}}function Q(e,t=null,n=null){if(!e||"string"!=typeof e)return r.warn("buildUrl: Invalid URL or path provided:",e),e;let o,i,a;return t&&"object"==typeof t?(o=Y(t.localeCode),i=t.baseUrl||null,a=t.caseFormat||"preserve"):(o=Y(t),i=n,a="preserve"),function(e){return function(e){return e&&(e.startsWith("http://")||e.startsWith("https://"))}(e)||G(e)}(e)?Z(e,o,a):function(e,t,n=null,o="preserve"){if("preserve"!==o){const r=V(e),i=J(t,W(e),r,o);return n?new URL(i,n).toString():i}try{const o=H(t,e);return n?new URL(o,n).toString():o}catch(r){const i=V(e),a=J(t,W(e),i,o);return n?new URL(a,n).toString():a}}(e,o,i,a)}function X(e,t,n=null){const o=V(e);let r,i;if(n&&"object"==typeof n?(r=n.localeCode||null,i=n.caseFormat||"preserve"):(r=n,i="preserve"),!o&&!r)return null;return J(r||o,W(t),o,i)}class ee{constructor(e=null,t=null){this.sourcePath=e,this.targetPath=e,this.targetLocale=t,this.isExternal=e&&(e.startsWith("http://")||e.startsWith("https://"))}to(e){return this.targetPath=e,this.isExternal=e&&(e.startsWith("http://")||e.startsWith("https://")),this}withLocale(e){return this.targetLocale=e,this}go(){if(!this.targetPath)return void r.warn("NavigationBuilder: No target path specified");const e=this._buildUrl();e&&P.assignAndNavigate(e)}getUrl(){return this.targetPath?this._buildUrl():(r.warn("NavigationBuilder: No target path specified"),"")}
1_buildUrl(){return this.sourcePath&&this.targetLocale?X(this.sourcePath,this.targetPath,this.targetLocale):Q(this.targetPath,this.targetLocale)}}function te(e,t=null){const n=Q(e,t);n&&P.assignAndNavigate(n)}var ne={buildUrl:Q,buildUrlFrom:X,navigate:function(e=null,t=null){return new ee(e,t)},navigateTo:te,switchToLocale:function(e){te(P.getPathname(),e)}};function oe(){return window.disw.chat.getContactSalesUrl()}function re(){return U}function ie(){return q()}function ae(){return k}function ce(){return D()}function ue(){return D().map(e=>U.find(t=>t.code===e)).filter(Boolean)}function se(e){r.warn("switchLocale() is deprecated. Use generateLocalePath() and handle navigation in your application.");const t=ie();if(t&&t!==k){const t=H(e);t&&P.navigate(P.getOrigin()+t)}else r.warn("There is no locale in the URL!")}function le(){return r.warn("getDefaultLocale() is deprecated. Use getDefaultLocaleCode() instead."),k}var de={getCurrentLocaleCode:ie,getAllLocales:re,getSupportedLocales:ce,getSupportedLanguages:ue,findLocaleByCode:z,generateLocalePath:H,getDefaultLocaleCode:ae,normalizeLocaleCode:F,navigation:ne,switchLocale:se,getDefaultLocale:le,getContactSalesUrlWithCurrentLocale:oe};const fe="Namespace not found for API Key, make sure you set it up.";function pe(e){try{return atob(e)}catch{throw new Error("Failed to decode API Key: invalid base64 string.")}}function _e(e){return{visitorCountry:e.headers.get("x-viewer-country"),visitorIP:e.headers.get("x-viewer-ip"),visitorIsBot:ge(e.headers.get("x-viewer-is-bot")),visitorIsInternal:ge(e.headers.get("x-viewer-is-internal"))}}function ge(e){return"true"===e||"false"!==e&&null}function me(e){return e.json().then(t=>({body:t,headers:_e(e)}))}function he({authenticationUrl:e}){return fetch(`${e}/session`,{credentials:"include",method:"GET"}).then(me)}function ye({authenticationUrl:e,jwt:t}){const n=function({method:e,jwt:t}){const n=new Headers;t&&n.set("authorization",`Bearer ${t}`);const o={method:e,credentials:"include",headers:n};return o}({method:"GET",jwt:t});return fetch(`${e}/profile`,n).then(e=>e.json())}const ve="prod";let we={authenticated:!1,user:void 0,profile:void 0,idToken:void 0,notifications:void 0,notificationSummary:void 0},Ce=!1,be=De(ve),Se=[];const Ie={country:null,ip:null,isBot:null,isInternal:null};async function Te(e={}){const{userRequired:t=!1,redirectUrl:n,authEnv:o=ve,checkCookiesDisabled:r=!1}=e;be=De(o),Se=Array.isArray(e.extraProfileLinks)?e.extraProfileLinks:[],we={user:void 0,profile:void 0,notifications:void 0,notificationSummary:void 0};try{const{body:e,headers:o}=await he({authenticationUrl:be});Object.assign(Ie,function(e){return{country:e.visitorCountry,ip:e.visitorIP,isBot:e.visitorIsBot,isInternal:e.visitorIsInternal}}(o)),function(e=!1){E(S.VISITOR,Ie,e)}();const{authenticated:i,csrfToken:a,sid:c,token:u,idToken:s,user:l}=e;if(t&&!i&&Ae(n),we.authenticated=i,we.sid=c,we.csrfToken=a,we.idToken=s,r)if(i)we.cookiesDisabled=!1;else{const{body:e}=await he({authenticationUrl:be}),{sid:t}=e;we.cookiesDisabled=c!==t}i&&(we.user={...l,jwt:u,picture:Me(l.picture,l.givenName,l.familyName)}),Le()}catch(e){Le(e)}}function Le(e=!1){E(S.ACCOUNT,we,e),E(S.USER,we.user,e)}async function Ee(){we.notificationSummary=[],Ce=null,E(S.ACCOUNT,we,Ce)}function Ae(e=P.getCurrentUrl()){P.navigate(Re(e))}function Re(e=P.getCurrentUrl()){return`${be}/login?returnTo=${encodeURIComponent(e)}`}function Ne(e=P.getCurrentUrl()){return`${be}/login/academic?returnTo=${encodeURIComponent(e)}`}function ke(e=P.getCurrentUrl()){return`${be}/login/google?returnTo=${encodeURIComponent(e)}`}function Ue(e=P.getCurrentUrl()){return`${be}/login/linkedin?returnTo=${encodeURIComponent(e)}`}function Pe(e=P.getCurrentUrl()){return`${be}/logout?returnTo=${encodeURIComponent(e)}`}function Oe(e=P.getCurrentUrl()){return`${be}/login?view=signup&returnTo=${encodeURIComponent(e)}`}function De(e){let t="https://api.sw.siemens.com/auth";return"dev"===e&&(t="https://api.stage.swi.siemens.com/auth"),t}function Me(e,t,n){if(!e)return e;try{const o=new URL(e),r=`${t?.[0]||""}${n?.[0]||""}`.toUpperCase();return o.searchParams.set("d","initials"),o.searchParams.set("initials",r),o.toString()}catch{return e}}var $e={subscribeToAccount:function(e){return A(S.ACCOUNT,e)},subscribeToUser:function(e){return A(S.USER,e)},subscribeToVisitor:function(e){return A(S.VISITOR,e)},setUser:function(e){we.user=e,Le()},loadProfile:function(){ye({authenticationUrl:be,jwt:we.user?.jwt}).then(e=>{we.profile=e,Ce=null,E(S.ACCOUNT,we,Ce)}).catch(e=>Ce=e)},getAppState:async function(e,t=be){return async function({encodedApiKey:e,authenticationUrl:t}
1){if(!e||"string"!=typeof e)throw new Error("encodedApiKey is required and must be a base64 encoded string");const n=pe(e),o=await fetch(`${t}/app-state`,{credentials:"include",method:"GET",headers:{"x-api-key":n}});if(401===o.status)throw new Error(fe);return me(o)}({encodedApiKey:e,authenticationUrl:t})},setAppState:async function(e,t,n=be){return async function({state:e,encodedApiKey:t,authenticationUrl:n}){if("object"!=typeof e&&"string"!=typeof e)throw new Error("State must be an object or a string.");if(!t||"string"!=typeof t)throw new Error("encodedApiKey is required and must be a base64 encoded string");const o=pe(t),r="string"==typeof e?e:JSON.stringify(e),i=await fetch(`${n}/app-state`,{credentials:"include",method:"POST",headers:{"Content-Type":"application/json","x-api-key":o},body:r});if(401===i.status)throw new Error(fe);return i.json()}({state:e,encodedApiKey:t,authenticationUrl:n})},loadUserNotifications:async function(){we.notifications=[],Ce=null,E(S.ACCOUNT,we,Ce)},loadUserNotificationSummary:Ee,dismissUserNotifications:async function(){try{await Ee()}catch(e){Ce=e}},login:Ae,academicLogin:function(e=P.getCurrentUrl()){P.navigate(Ne(e))},linkedinLogin:function(e=P.getCurrentUrl()){P.navigate(Ue(e))},googleLogin:function(e=P.getCurrentUrl()){P.navigate(ke(e))},logout:function(e=P.getCurrentUrl()){localStorage.removeItem("lastActiveStep"),localStorage.removeItem("lastActiveTime"),localStorage.removeItem("lastCheckoutCartId"),localStorage.removeItem("payment-details");const t=document.createElement("form");t.method="POST",t.action=Pe(e);const n=document.createElement("input");n.type="hidden",n.name="csrfToken",n.value=we.csrfToken??"",t.appendChild(n),document.body.appendChild(t),t.submit(),document.body.removeChild(t)},createAccount:function(e=P.getCurrentUrl()){P.navigate(Oe(e))},getLoginUrl:Re,getAcademicLoginUrl:Ne,getGoogleLoginUrl:ke,getLinkedinLoginUrl:Ue,getLogoutUrl:Pe,getCreateAccountUrl:Oe,getAccount:function(){return we},getExtraProfileLinks:function(){return Se}};const xe={},Be={};function Fe(e){return xe[e]}var je={setVideoPlayer:function(e,t){Be[e]&&(Be[e].forEach(({event:e,callback:n})=>{t.on(e,n)}),delete Be[e]),xe[e]=t},getVideoPlayer:Fe,removeVideoPlayer:function(e){delete xe[e]},pauseVideo:function(e){const t=Fe(e);t&&t.pause()},playVideo:function(e){const t=Fe(e);t&&t.play()},addEvent:function(e,t,n){const o=Fe(e);o?o.on(t,n):(Be[e]||(Be[e]=[]),Be[e].push({event:t,callback:n}))}};let Ve;const He=new Uint8Array(16);function ze(){if(!Ve&&(Ve="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Ve))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Ve(He)}const qe=[];for(let e=0;e<256;++e)qe.push((e+256).toString(16).slice(1));var Ge={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function Ke(e,t,n){if(Ge.randomUUID&&!t&&!e)return Ge.randomUUID();const o=(e=e||{}).random||(e.rng||ze)();if(o[6]=15&o[6]|64,o[8]=63&o[8]|128,t){n=n||0;for(let e=0;e<16;++e)t[n+e]=o[e];return t}return function(e,t=0){return qe[e[t+0]]+qe[e[t+1]]+qe[e[t+2]]+qe[e[t+3]]+"-"+qe[e[t+4]]+qe[e[t+5]]+"-"+qe[e[t+6]]+qe[e[t+7]]+"-"+qe[e[t+8]]+qe[e[t+9]]+"-"+qe[e[t+10]]+qe[e[t+11]]+qe[e[t+12]]+qe[e[t+13]]+qe[e[t+14]]+qe[e[t+15]]}(o)}const We=["cmpid","elqaid","elqcampaignId","etrc","gclid","sfc","spi","stc","utm_campaign","utm_content","utm_creative_format","utm_id","utm_marketing_tactic","utm_medium","utm_source","utm_source_platform","utm_term"],Je=["www.google.","yahoo.com","bing.com","microsoft.com","duckduckgo.com","search.aol.com","ask.com","excite.com","baidu.com","yandex.com","lycos.com","swisscows.com","startpage.com","gibiru.com","searchencrypt.com","onesearch.com","linkedin.com","instagram.com","fb.com","fb.co","facebook.com","tiktok.com","snapchat.com","pinterest.com","reddit.com","twitter.com","tumblr.com"],Ye=({sessionId:e,userId:t})=>{const n=""===document.referrer?void 0:document.referrer,o=P.getSearch().slice(1).split("&").reduce((e,t)=>{const[n,o]=t.split("=");return We.includes(n)?{...e,[n]:o}:e},{}),r=Je.some(e=>new RegExp(`${e.replace(".","\\.")}.*`,"i").test(n));if(!Object.keys(o).length&&!r)return;if(P.getCurrentUrl().length>2048||document.referrer.length>2048)return;const i={eventTime:(new Date).toISOString(),referrer:n,sessionId:e,url:P.getCurrentUrl(),userId:t},a={method:"POST",headers:{"Content-Type":"application/json","x-api-key":"tB2
1CviD9oG39EpgMeZS641qKP6LGW82j6kZhlk8z"},body:JSON.stringify(i)};fetch("https://api.sw.siemens.com/ct",a).catch(e=>{})};window.dataLayer=window.dataLayer||[];const Ze=e=>{window.gtmLoaded?window.dataLayer.push(e):window.gtmPreLoadDataLayer.push(e)},Qe={identify:(e,t)=>{Ze({userProperties:void 0}),Ze({event:"identify",userId:e,userProperties:t,hitId:Ke()})},page:(e,t,n)=>{Ze({pageProperties:void 0}),Ze({event:"page",pageCategory:e,pageName:t,pageProperties:n,hitId:Ke()})},track:(e,t)=>{Ze({eventProperties:void 0}),Ze({event:"track",eventName:e,eventProperties:t,hitId:Ke()})}};function Xe(e){!function(e,t,n,o,r){e[o]=e[o]||[],e[o].push({"gtm.start":(new Date).getTime(),event:"gtm.js"});let i=t.getElementsByTagName(n)[0],a=t.createElement(n);a.async=!0,a.src=`https://g.sw.siemens.com/a0fe7e389dc0e3bf.js?id=${r}`,i.parentNode.insertBefore(a,i)}(window,document,"script","dataLayer",e)}function et(e){if(document.body)document.body.appendChild(e);else{const t=new MutationObserver(()=>{document.body&&(document.body.appendChild(e),t.disconnect())});t.observe(document.documentElement,{childList:!0})}}function tt(e){!function(e,t){const n=document.createElement("script");n.id="usercentrics-cmp",n.setAttribute("data-version",e),n.setAttribute("data-settings-id",t),n.src=`https://data.cdn.siemens.com/?settingsId=${t}`,n.async=!0,et(n)}(e.cookieBannerVersion,e.cookieBannerSettingsId),function(e){const t=document.createElement("script");t.src=`https://${e}.siemens.com/ste/cookiemonster/cookiemonster.js`,t.async=!0,t.addEventListener("load",function(){window.cookieMonster&&(window.cookieMonster.once("targ",()=>{Ze({ad_storage:!0}),Ze({personalization_storage:!0})}),window.cookieMonster.once("fnct",()=>{Ze({functionality_storage:!0})}),window.cookieMonster.once("perf",()=>{Ze({analytics_storage:!0})}),window.cookieMonster.once("reqd",()=>{Ze({security_storage:!0})}))}),et(t)}(e.cookieMonsterHost)}async function nt(e={},t=Xe){if(!e.hasOwnProperty("gtmId"))throw new Error("config.gtmId is required");e.cookieBannerEnabled=e.cookieBannerEnabled??!0,e.cookieBannerSettingsId=e.cookieBannerSettingsId||"GXj83XOdm",e.cookieBannerVersion=e.cookieBannerVersion||"latest",e.cookieMonsterHost=e.cookieMonsterHost||"w3",window.gtmLoaded=!1,window.gtmPreLoadDataLayer=[],window.analytics=Qe,window.dataLayer.push(["config",e.gtmId,{send_page_view:!1,client_storage:"none"}]),window.dataLayer.push(["js",new Date]),void 0!==e.pageId&&(window.dataLayer.push({pageId:e.pageId}),window.analytics.pageId=e.pageId),e.cookieBannerEnabled&&tt(e),disw.account.subscribeToAccount(n=>((e,t,n)=>{e&&e.sid&&(window.gtmLoaded||(Ye({sessionId:e.sid,userId:e.user?.contact_id}),window.dataLayer.push({sessionId:e.sid})),e.user&&e.user.contact_id&&window.dataLayer.push({userId:e.user.contact_id}),void 0!==e.cookiesEnabled&&window.dataLayer.push({cookiesEnabled:e.cookiesEnabled}),window.gtmLoaded||(window.dataLayer.push({initialPageHitId:Ke()}),n(t.gtmId),window.gtmLoaded=!0,window.dataLayer.push(...window.gtmPreLoadDataLayer)))})(n,e,t))}window._mtm=window._mtm||[],window.__dequeueMTM=function(){window.mtmPreLoadDataLayer&&Array.isArray(window.mtmPreLoadDataLayer)&&(window.mtmPreLoadDataLayer.forEach(e=>{window._mtm.push(e)}),window.mtmPreLoadDataLayer=[]),window.segmentLoaded=!0};const ot=e=>{window.segmentLoaded?window._mtm.push(e):window.mtmPreLoadDataLayer.push(e)};window.__setConsent=function(e){!function(e,t=!1){E(S.CONSENT,e,t)}(e)};const rt={identify:(e,t)=>{ot({userProperties:void 0});const n={event:"identify",userProperties:t,hitId:Ke()};null!=e&&(n.userId=e),ot(n)},page:(e,t,n)=>{ot({pageProperties:void 0}),ot({event:"page",pageCategory:e,pageName:t,pageProperties:n,hitId:Ke()})},subscribeToConsent:e=>A(S.CONSENT,e),track:(e,t)=>{ot({eventProperties:void 0}),ot({event:"track",eventName:e,eventProperties:t,hitId:Ke()})}};function it(e){e&&(e.ip||e.country||null!==e.isBot||null!==e.isInternal)&&window._mtm.push({event:"visitor",visitorIpAddress:e.ip??"",visitorCountry:e.country??"",visitorIsBot:e.isBot??!1,visitorIsInternal:e.isInternal??!1})}function at(e){Array.isArray(e)&&e.length>0&&window._mtm.push({event:"region",visitorRegion:e})}function ct(e){window._mtm.push({"mtm.startTime":(new Date).getTime(),event:"mtm.Start"}),function(){let t=document,n=t.createElement("script"),o=t.getElementsByTagName("script")[0];n.async=!0,n.src=`https://metrics.siemens-cdn.com/js/container_${e}.js`,o.parentNode.insertBefore(n,o)}()}function ut(e,t){const n=document.createElement("script");n.id="usercentrics-cmp",n.setAttribute("data-version",e),n.setAttribute("data-settings-id",t),n.src=`https://data.cdn.siemens.com/?settingsId=${t}`,n.async=!0,function(e){if(document.body)document.body.appendChild(e);else{const t=new MutationObserver(()=>{document.body&&(document.body.appendChild(e),t.disconnect())});t.observe(document.documentElement,{childList:!0})}}(n)}async function st(e={},t=ct){if(!e.hasOwnProperty("containerId"))throw new Error("config.containerId is required");e.cookieBannerEnabled=e.cookieBannerEnabled??!0,e.cookieBannerSettingsId=e.cookieBannerSettingsId||"GXj83XOdm",e.cookieBannerVersion=e.cookieBannerVersion||"latest",window.mtmLoaded=!1,window.segmentLoaded=!1,window.mtmPreLoadDataLayer=[],window.analytics=rt,disw.account.subscribeToVisitor(it),disw.region.subscribeToRegion(at),void 0!==e.pageId&&(window._mtm.push({pageId:e.pageId}),window.analytics.pageId=e.pageId),e.cookieBannerEnabled&&ut(e.cookieBannerVersion,e.cookieBannerSettingsId),disw.account.subscribeToAccount(n=>((e,t,n)=>{e&&e.sid&&(window.mtmLoaded||(Ye({sessionId:e.sid,userId:e.user?.contact_id}),window._mtm.push({sessionId:e.sid})),e.user&&e.user.contact_id&&window._mtm.push({userId:e.user.contact_id}),void 0!==e.cookiesDisabled&&window._mtm.push({cookiesDisabled:e.cookiesDisabled}),window.mtmLoaded||(window._mtm.push({initialPageHitId:Ke()}),n(t.containerId),window.mtmLoaded=!0))})(n,e,t))}const lt="https://static.sw.cdn.siemens.com",dt="https://identity.industrysoftware.automation.siemens.com/WebkeyLogin/DigitalExchangeUpdateProfile",ft=`${lt}/translations`;function pt(e){return"prod"===e?"https://api.sw.siemens.com/v1":"uat"===e?"https://api.stage.swi.siemens.com/v1":"mock"===e?"https://8d5fe0eb-1bbc-4761-8c10-24e86337d7f9.mock.pstmn.io/dex-services-svc":"https://api.dev.
1swi.siemens.com/v1"}function _t(e){return pt(e)}function gt(e){return pt(e).replace("v1","taxonomy")}const mt=`${lt}/disw`;function ht(e,t=k,n="prod",o="static"){return`${mt}/breadcrumbs/${e}/${n}/breadcrumbs-${t}.json`}function yt(e){const t=new URLSearchParams(P.getSearch()).get(e);try{return t?atob(t):void 0}catch(e){return}}function vt(e,t,n){if(!t||!n||!e)return e;try{const o=new URL(e);return o.searchParams.get(t)||o.searchParams.set(t,n),o.toString()}catch(t){return e}}const wt="prod";let Ct={},bt=[],St=[],It=yt("bc");function Tt(e,t){Array.isArray(e)?t&&(t.push(...e),bt=t):r.warn("pages param is not an array; ignoring")}async function Lt(e,t,n){try{Ct=await async function(e,t=k,n="prod"){if(!e)return{};const o=new AbortController;return setTimeout(()=>o.abort(),5e3),fetch(ht(e,t,n),{signal:o.signal}).then(e=>e.json()).catch(()=>(r.log(`Could not load breadcrumbs for locale ${t}; refetching for ${k}`),fetch(ht(e,k,n),{signal:o.signal}).then(e=>e.json()).catch(e=>e)))}(e,t,n)}catch(e){r.warn("Could not load breadcrumbs",e)}}function Et(e){if(!e)return;let t=[];const n=Rt(e);if(!n)return;t.push(n);const o=Et(n.parent);return o&&t.push(...o),t}function At(e){const t=Et(e);return t?t.reverse().map(e=>({url:e.url,label:e.name})):[]}function Rt(e){if(e)return Ct&&Ct.pages&&Ct.pages.find(t=>t.id==e)}var Nt={getPage:Rt,getPageBreadcrumbs:At,getCurrentPageBreadcrumbs:function(e=void 0){if(e){const t=At(e);t.push(...bt);return[...new Set(t.map(JSON.stringify))].map(JSON.parse)}return bt},subscribeToBreadcrumbs:function(e){return A(S.BREADCRUMBS,e)},getConfiguredPages:function(){return St}};async function kt(e,t=k,n="prod"){if(!e)return{};const o=new AbortController;return setTimeout(()=>o.abort(),3e3),fetch(function(e,t=k,n="prod"){return`${ft}/${n}/${e}/translation-${t}`}(e,t,n),{signal:o.signal}).then(e=>e.ok?e.json():void 0).catch(e=>{})}const Ut="prod";let Pt=Ut,Ot=!0;const Dt=e=>{if("object"!=typeof e)return e;const t={};for(const n in e)t[n]=e[n].replace(new RegExp(/\{(.*?)\}/,"g"),"{{$1}}");return t};var Mt={loadLocalizationTokens:async function(e,t,n=!1){let o;const r=`tokens_${t}_${e}`;if(t&&"string"==typeof t){const e=t.split("-");2===e.length&&(t=`${e[0].toLowerCase()}-${e[1].toUpperCase()}`)}try{if(Ot){const e=window.sessionStorage.getItem(r);e&&(o=JSON.parse(e))}return o||(o=await kt(e,t,Pt),o&&window.sessionStorage.setItem(r,JSON.stringify(o))),n?Dt(o):o}catch(e){return e}},doubleTokenBraces:Dt,getLocalizationEnv:function(){return Pt}};const $t=(e=!1)=>["localhost","127.0.0.1"].includes(location.hostname)?"localhost":["local.sw.siemens.com","plm-local.sw.siemens.com","x1-local.siemens.com","one-local.siemens.com"].includes(location.hostname)?location.hostname:".siemens.com",xt=e=>{const t=document.cookie.split("; ").find(t=>t.trimStart().startsWith(`${e}=`));if(t)return decodeURIComponent(t.split("=")[1])},Bt=(e,t,n)=>{const{expires:o,maxAge:r,sameSite:i,domain:a,path:c}=n;let u=`${e}=${encodeURIComponent(t)};`;r?u=`${u} Max-Age=${r};`:o&&(u=`${u} Expires=${o.toUTCString()};`),a&&(u=`${u} Domain=${a};`),c&&(u=`${u} Path=${c};`),i&&(u=`${u} SameSite=${i};${"None"===i&&" Secure;"}`),document.cookie=u},Ft="SelectedCountry";let jt;let Vt={countryname:"United States",countrycode:"US",default:!0},Ht=o;async function zt(e={}){const{env:i=o}=e;Ht=i,jt=$t([t,n].includes(Ht));const a=function(){const e=xt(Ft);if(e)return JSON.parse(e);return e}(),c=window?.disw?.account?.getAccount()?.authenticated;if(c)await Wt({countrycode:"",countryname:""});else{if(a)return Vt=await qt(a?.countrycode),Jt(Vt),void E(S.COUNTRY,Vt,!1);try{const{countryCode:e,countryName:t}=await async function(e=o){const t=_t(e),n=new AbortController;return setTimeout(()=>n.abort(),1e4),fetch(`${t}/country/locate`,{signal:n.signal}).then(e=>e.ok?e.json():void 0).catch(e=>{r.log(`Error determining country: ${e}`)})}(Ht);await Wt(await qt(e))}catch(e){r.error(`Failed to fetch country: ${e}`),await Wt(Vt)}}}async function qt(e){const t=await Gt(window?.disw?.locales?.getCurrentLocaleCode()||"en-US"),n=t?.countries?.find(t=>t.value===e);if(!n?.label){const t=`Country with code ${e} not found in the list.`;throw r.error(t),new Error(t)}return{countrycode:e,countryname:n.label,default:!1}}async function Gt(e){const t=`countries_${e}`;try{const n=window.sessionStorage.getItem(t);if(n)return JSON.parse(n);const o=await Kt(e,Ht,1);return window.sessionStorage.setItem(t,JSON.stringify(o)),o}catch(e){r.error(e)}}async function Kt(e,t,n){let o;try{return o=await async function(e,t){const n=_t(t),o=new AbortController;return setTimeout(()=>
1o.abort(),1e4),fetch(`${n}/country/${e}`,{signal:o.signal}).then(e=>{if(e.ok)return e.json();throw Error(e.statusText)}).catch(e=>{throw e})}(e,t),o}catch(o){if(n>0)return Kt(e,t,n-1);throw r.error(`Error loading country data: ${o} with retries '${n}'`),o}}async function Wt(e){const t=window?.disw?.account?.getAccount();if(t?.authenticated){if(!t?.user?.countryCode)return r.warn("User is authenticated but no country code found in profile"),Vt={countryname:"",countrycode:""},void E(S.COUNTRY,void 0,!1);try{const e=await qt(t.user.countryCode);return Jt(e),Vt=e,void E(S.COUNTRY,e,!1)}catch(e){return r.error(`Error setting country name for logged-in user: ${e}`),Vt={countryname:"",countrycode:""},void E(S.COUNTRY,void 0,!1)}}e?.countryname?(Jt(e),Vt=e,E(S.COUNTRY,e,!1)):E(S.COUNTRY,void 0,!1)}function Jt(e){Bt(Ft,JSON.stringify(e),{maxAge:3456e4,domain:jt,path:"/",sameSite:"Strict"})}var Yt={getAllCountries:Gt,setCountry:Wt,subscribeToCountry:function(e){return A(S.COUNTRY,e)},getCountry:function(){return Vt},getCountryEnv:function(){return Ht}};async function Zt(e=o){const t=`${gt(e)}/latest/marketplace-countries`,n=new AbortController;if(setTimeout(()=>n.abort(),1e4),!t)return r.warn("Missing 'PUBLIC_API_KEY' or 'apiUrl' for taxonomy regions api call"),[];const i={"Content-Type":"application/json","x-api-key":"1c919bab-55c2-4596-8932-95f51643ff07"};r.log(`Fetching regions from API at: ${t}`);try{const e=await fetch(t,{method:"GET",headers:i,mode:"cors",signal:n.signal});if(!e.ok)throw new Error(`Failed to fetch regions: ${e.status} - ${e.statusText}`);const o=function(e){const t=new Map;e.forEach(e=>{e.marketplaceRegions?.forEach(n=>{const o=n.uri,r=n.label;t.has(o)||t.set(o,{label:r,uri:o,countryCodes:[]}),t.get(o).countryCodes.push(e.countryCode)})});const n=["ASEAN","MEA","OTHERS"],o=Array.from(t.values()).map(({label:e,uri:t,countryCodes:o})=>{const r=n.includes(e)?[e.toUpperCase()]:[...o];return{uri:t,label:e,region:r,countryCodes:o}});return o}(await e.json());return o}catch(e){throw r.log(`Error fetching regions: ${e}`),e}}const Qt="regionSelector.region",Xt="regionSelector.regionsData",en=["WW"],tn="region";let nn=null,on=en;const rn=["BN","KH","ID","LA","MY","MM","PH","SG","TH","VN"];function an(e){if(!e||"string"!=typeof e)return;const t=e.toUpperCase();return rn.includes(t)?[t,"ASEAN"]:[t]}function cn(e){nn&&(function(e,t){return e.length===t.length&&e.every((e,n)=>e===t[n])}(e,nn)||(!function(){const e=P.getSearch();if(!e)return;const t=new URLSearchParams(e);if(!t.has(tn))return;t.delete(tn);const n=t.toString(),o=`${P.getPathname()}${n?`?${n}`:""}${P.getHash()}`;P.replaceState(null,"",o),r.log(`Removed "${tn}" query param from URL: ${o}`)}(),nn=null))}async function un(e={}){const{env:t=o}=e;window?.disw.account.subscribeToVisitor(sn),A(S.REGION,e=>{!function(e){const t=window.ninetailed;t&&t.identify(window.disw?.account?.getAccount()?.sid,{enriched:{region:e}});const n=window.analytics;n&&n.identify(void 0,{region:e})}(e)}),await async function(e){if(pn())r.log("Using existing regions data from localStorage");else try{!function(e){r.log(`Storing regions data in localStorage: ${e.length} regions`);try{localStorage.setItem(Xt,JSON.stringify(e))}catch(e){r.warn(`Failed to store regions data in localStorage: ${e}`)}}(await Zt(e)),r.log("Successfully fetched and stored regions data")}catch(e){r.warn(`Failed to fetch regions data: ${e}`)}}(t);const n=function(){const e=P.getSearch();if(!e)return null;const t=new URLSearchParams(e).get(tn);if(!t)return null;const n=t.toUpperCase(),o=ln();if(o){const e=o.find(e=>e.region.some(e=>e.toUpperCase()===n));return e?(r.log(`Region from query string: ${JSON.stringify(e.region)}`),e.region):(r.log(`Unrecognized region query param "${t}", falling back to Global (WW)`),[...en])}return r.log(`Region data unavailable; ignoring region query param "${t}"`),null}();if(null!==n)return nn=n,void dn(n);!function(){const e=fn();e&&on!=e&&(on=e,E(S.REGION,e,!1))}()}function sn(e){if(fn())return;let t="";if(e?.country)t=e.country,r.log("Getting country from visitor session",t);else{r.log("Getting country from country module",t);const e=window?.disw?.country?.getCountry();e?.countrycode&&(t=e.countrycode),e.default&&(t="WW",r.log("Country was set to default, using GLOBAL instead with value WW"))}const n=an(t);n&&dn(n)}function ln(){return pn()}function dn(e){Array.isArray(e)&&0!==e.length?(!function(e){r.log(`Storing region locally in localStorage: ${JSON.stringify(e)}`);try{localStorage.setItem(Qt,JSON.stringify(e))}catch(e){r.warn(`Failed to store region in localStorage: ${e}`)}}(e),on=[...e],cn(on),E(S.REGION,on,!1),r.log(`Region set to: ${JSON.stringify(on)}`)):r.warn("Invalid region provided to setRegion. Region must be a non-empty array.")}function fn(){try{const e=localStorage.getItem(Qt);if(e){const t=JSON.parse(e);if(Array.isArray(t))return t}}
1catch(e){r.warn(`Failed to retrieve or parse stored region: ${e}`)}return null}function pn(){try{const e=localStorage.getItem(Xt);if(e){const t=JSON.parse(e);if(Array.isArray(t))return t}}catch(e){r.warn(`Failed to retrieve or parse stored regions data: ${e}`)}return null}var _n={getRegions:ln,getRegion:function(){return[...on]},setRegion:dn,subscribeToRegion:function(e){return A(S.REGION,e)},mapCountryToRegion:an,getAseanCountryCodes:function(){return rn}};let gn,mn,hn,yn;function vn(e){return bn(e)?"":wn("object"==typeof e?JSON.stringify(e):e)}function wn(e){return window.btoa(unescape(encodeURIComponent(e)))}function Cn(e){return decodeURIComponent(escape(window.atob(e)))}function bn(e){return""===e||null==e||0===e.length||"object"==typeof e&&0===Object.keys(e).length}const Sn={prod:["resources.sw","webinars.sw","trials.sw"],dev:["resources-qa","webinars-qa","trials.dev.swi"],uat:["resources-uat","webinars-uat","trials.qa.swi"]};function In(e,t="lnc"){const n=vn(e),o=/(\?{1}[a-z]*=[a-z]*&*)/im,r=Sn[yn]??Sn.prod;for(const e of r)document.querySelectorAll(`a[href*="//${e}"]`).forEach(e=>{e.search.includes(`${t}=`)||(o.test(e.search)?e.href+=`&${t}=${n}`:e.href+=`?${t}=${n}`)})}function Tn(e){if(!(e&&e.site&&e.page&&e.locale))return;const t={site:e.site,page:e.page,locale:e.locale};In(t,"bc");new MutationObserver(e=>{for(const n of e)if("childList"===n.type&&n.addedNodes.length>0){In(t,"bc");break}}).observe(document,{childList:!0,subtree:!0})}var Ln,En,An,Rn,Nn,kn,Un,Pn,On,Dn,Mn,$n,xn,Bn,Fn,jn={createContext:vn,getContext:function(e){const t=function(e){if(!window)return;e=e.replace(/[\[]/,"\\[").replace(/[\]]/,"\\]");const t=new RegExp(`[\\?&]${e}=([^&#]*)`).exec(P.getSearch());return null===t?"":decodeURIComponent(t[1].replace(/\+/g," "))}(e);if(bn(t))return"";const n=Cn(t);try{return JSON.parse(n)}catch(e){return n}},str_to_base64:wn,base64_to_str:Cn,addContextToLinks:In,addContextToUrl:function(e,t=["lnc","bc"]){const n=window.disw.locales.getCurrentLocaleCode();let o=e;if(t.includes("bc")&&gn&&mn&&n){o=vt(o,"bc",vn({page:gn,site:mn,locale:n}))}if(t.includes("lnc")&&hn&&n){o=vt(o,"lnc",vn({slug:hn,locale:n}))}return o},observeAndDecorateResourceLinks:Tn,getPageId:function(){return gn},getCurrentSite:function(){return mn},getSlug:function(){return hn}},Vn={},Hn=[],zn=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,qn=Array.isArray;function Gn(e,t){for(var n in t)e[n]=t[n];return e}function Kn(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function Wn(e,t,n){var o,r,i,a={};for(i in t)"key"==i?o=t[i]:"ref"==i?r=t[i]:a[i]=t[i];if(arguments.length>2&&(a.children=arguments.length>3?Ln.call(arguments,2):n),"function"==typeof e&&null!=e.defaultProps)for(i in e.defaultProps)void 0===a[i]&&(a[i]=e.defaultProps[i]);return Jn(e,a,o,r,null)}function Jn(e,t,n,o,r){var i={type:e,props:t,key:n,ref:o,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:null==r?++An:r,__i:-1,__u:0};return null==r&&null!=En.vnode&&En.vnode(i),i}function Yn(e){return e.children}function Zn(e,t){this.props=e,this.context=t}function Qn(e,t){if(null==t)return e.__?Qn(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e)return n.__e;return"function"==typeof e.type?Qn(e):null}function Xn(e){if(e.__P&&e.__d){var t=e.__v,n=t.__e,o=[],r=[],i=Gn({},t);i.__v=t.__v+1,En.vnode&&En.vnode(i),lo(e.__P,i,t,e.__n,e.__P.namespaceURI,32&t.__u?[n]:null,o,null==n?Qn(t):n,!!(32&t.__u),r),i.__v=t.__v,i.__.__k[i.__i]=i,function(e,t,n){for(var o=0;o<n.length;o++)go(n[o],n[++o],n[++o]);En.__c&&En.__c(t,e),e.some(function(t){try{e=t.__h,t.__h=[],e.some(function(e){e.call(t)})}catch(e){En.__e(e,t.__v)}})}(o,i,r),t.__e=t.__=null,i.__e!=n&&eo(i)}}function eo(e){if(null!=(e=e.__)&&null!=e.__c)return e.__e=e.__c.base=null,e.__k.some(function(t){if(null!=t&&null!=t.__e)return e.__e=e.__c.base=t.__e}),eo(e)}function to(e){(!e.__d&&(e.__d=!0)&&Rn.push(e)&&!no.__r++||Nn!=En.debounceRendering)&&((Nn=En.debounceRendering)||kn)(no)}function no(){try{for(var e,t=1;Rn.length;)Rn.length>t&&Rn.sort(Un),e=Rn.shift(),t=Rn.length,Xn(e)}finally{Rn.length=no.__r=0}}function oo(e,t,n,o,r,i,a,c,u,s,l){var d,f,p,_,g,m,h,y=o&&o.__k||Hn,v=t.length;for(u=function(e,t,n,o,r){var i,a,c,u,s,l=n.length,d=l,f=0;for(e.__k=new Array(r),i=0;i<r;i++)null!=(a=t[i])&&"boolean"!=typeof a&&"function"!=typeof a?("string"==typeof a||"number"==typeof a||"bigint"==typeof a||a.constructor==String?a=e.__k[i]=Jn(null,a,null,null,null):qn(a)?a=e.__k[i]=Jn(Yn,{children:a},null,null,null):void 0===a.constructor&&a.__b>0?a=e.__k[i]=Jn(a.type,a.props,a.key,a.ref?a.ref:null,a.__v):e.__k[i]=a,u=i+f,a.__=e,a.__b=e.__b+1,c=null,-1!=(s=a.__i=ao(a,n,u,d))&&(d--,(c=n[s])&&(c.__u|=2)),null==c||null==c.__v?(-1==s&&(r>l?f--:r<l&&f++),"function"!=typeof a.type&&(a.__u|=4)):s!=u&&(s==u-1?f--:s==u+1?f++:(s>u?f--:f++,a.__u|=4))):e.__k[i]=null;if(d)for(i=0;i<l;i++)null!=(c=n[i])&&!(2&c.__u)&&(c.__e==o&&(o=Qn(c)),mo(c,c));return o}(n,t,y,u,v),d=0;d<v;d++)null!=(p=n.__k[d])&&(f=-1!=p.__i&&y[p.__i]||Vn,p.__i=d,m=lo(e,p,f,r,i,a,c,u,s,l),_=p.__e,p.ref&&f.ref!=p.ref&&(f.ref&&go(f.ref,null,p),l.push(p.ref,p.__c||_,p)),null==g&&null!=_&&(g=_),(h=!!(4&p.__u))||f.__k===p.__k?(u=ro(p,u,e,h),h&&f.__e&&(f.__e=null)):"function"==typeof p.t
vendor: 6,361 bytes, line 1
1ype&&void 0!==m?u=m:_&&(u=_.nextSibling),p.__u&=-7);return n.__e=g,u}function ro(e,t,n,o){var r,i;if("function"==typeof e.type){for(r=e.__k,i=0;r&&i<r.length;i++)r[i]&&(r[i].__=e,t=ro(r[i],t,n,o));return t}e.__e!=t&&(o&&(t&&e.type&&!t.parentNode&&(t=Qn(e)),n.insertBefore(e.__e,t||null)),t=e.__e);do{t=t&&t.nextSibling}while(null!=t&&8==t.nodeType);return t}function io(e,t){return t=t||[],null==e||"boolean"==typeof e||(qn(e)?e.some(function(e){io(e,t)}):t.push(e)),t}function ao(e,t,n,o){var r,i,a,c=e.key,u=e.type,s=t[n],l=null!=s&&!(2&s.__u);if(null===s&&null==c||l&&c==s.key&&u==s.type)return n;if(o>(l?1:0))for(r=n-1,i=n+1;r>=0||i<t.length;)if(null!=(s=t[a=r>=0?r--:i++])&&!(2&s.__u)&&c==s.key&&u==s.type)return a;return-1}function co(e,t,n){"-"==t[0]?e.setProperty(t,null==n?"":n):e[t]=null==n?"":"number"!=typeof n||zn.test(t)?n:n+"px"}function uo(e,t,n,o,r){var i,a;e:if("style"==t)if("string"==typeof n)e.style.cssText=n;else{if("string"==typeof o&&(e.style.cssText=o=""),o)for(t in o)n&&t in n||co(e.style,t,"");if(n)for(t in n)o&&n[t]==o[t]||co(e.style,t,n[t])}else if("o"==t[0]&&"n"==t[1])i=t!=(t=t.replace(Mn,"$1")),a=t.toLowerCase(),t=a in e||"onFocusOut"==t||"onFocusIn"==t?a.slice(2):t.slice(2),e.l||(e.l={}),e.l[t+i]=n,n?o?n[Dn]=o[Dn]:(n[Dn]=$n,e.addEventListener(t,i?Bn:xn,i)):e.removeEventListener(t,i?Bn:xn,i);else{if("http://www.w3.org/2000/svg"==r)t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=t&&"height"!=t&&"href"!=t&&"list"!=t&&"form"!=t&&"tabIndex"!=t&&"download"!=t&&"rowSpan"!=t&&"colSpan"!=t&&"role"!=t&&"popover"!=t&&t in e)try{e[t]=null==n?"":n;break e}catch(e){}"function"==typeof n||(null==n||!1===n&&"-"!=t[4]?e.removeAttribute(t):e.setAttribute(t,"popover"==t&&1==n?"":n))}}function so(e){return function(t){if(this.l){var n=this.l[t.type+e];if(null==t[On])t[On]=$n++;else if(t[On]<n[Dn])return;return n(En.event?En.event(t):t)}}}function lo(e,t,n,o,r,i,a,c,u,s){var l,d,f,p,_,g,m,h,y,v,w,C,b,S,I,T=t.type;if(void 0!==t.constructor)return null;128&n.__u&&(u=!!(32&n.__u),i=[c=t.__e=n.__e]),(l=En.__b)&&l(t);e:if("function"==typeof T)try{if(h=t.props,y=T.prototype&&T.prototype.render,v=(l=T.contextType)&&o[l.__c],w=l?v?v.props.value:l.__:o,n.__c?m=(d=t.__c=n.__c).__=d.__E:(y?t.__c=d=new T(h,w):(t.__c=d=new Zn(h,w),d.constructor=T,d.render=ho),v&&v.sub(d),d.state||(d.state={}),d.__n=o,f=d.__d=!0,d.__h=[],d._sb=[]),y&&null==d.__s&&(d.__s=d.state),y&&null!=T.getDerivedStateFromProps&&(d.__s==d.state&&(d.__s=Gn({},d.__s)),Gn(d.__s,T.getDerivedStateFromProps(h,d.__s))),p=d.props,_=d.state,d.__v=t,f)y&&null==T.getDerivedStateFromProps&&null!=d.componentWillMount&&d.componentWillMount(),y&&null!=d.componentDidMount&&d.__h.push(d.componentDidMount);else{if(y&&null==T.getDerivedStateFromProps&&h!==p&&null!=d.componentWillReceiveProps&&d.componentWillReceiveProps(h,w),t.__v==n.__v||!d.__e&&null!=d.shouldComponentUpdate&&!1===d.shouldComponentUpdate(h,d.__s,w)){t.__v!=n.__v&&(d.props=h,d.state=d.__s,d.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.some(function(e){e&&(e.__=t)}),Hn.push.apply(d.__h,d._sb),d._sb=[],d.__h.length&&a.push(d);break e}null!=d.componentWillUpdate&&d.componentWillUpdate(h,d.__s,w),y&&null!=d.componentDidUpdate&&d.__h.push(function(){d.componentDidUpdate(p,_,g)})}if(d.context=w,d.props=h,d.__P=e,d.__e=!1,C=En.__r,b=0,y)d.state=d.__s,d.__d=!1,C&&C(t),l=d.render(d.props,d.state,d.context),Hn.push.apply(d.__h,d._sb),d._sb=[];else do{d.__d=!1,C&&C(t),l=d.render(d.props,d.state,d.context),d.state=d.__s}while(d.__d&&++b<25);d.state=d.__s,null!=d.getChildContext&&(o=Gn(Gn({},o),d.getChildContext())),y&&!f&&null!=d.getSnapshotBeforeUpdate&&(g=d.getSnapshotBeforeUpdate(p,_)),S=null!=l&&l.type===Yn&&null==l.key?po(l.props.children):l,c=oo(e,qn(S)?S:[S],t,n,o,r,i,a,c,u,s),d.base=t.__e,t.__u&=-161,d.__h.length&&a.push(d),m&&(d.__E=d.__=null)}catch(e){if(t.__v=null,u||null!=i)if(e.then){for(t.__u|=u?160:128;c&&8==c.nodeType&&c.nextSibling;)c=c.nextSibling;i[i.indexOf(c)]=null,t.__e=c}else{for(I=i.length;I--;)Kn(i[I]);fo(t)}else t.__e=n.__e,t.__k=n.__k,e.then||fo(t);En.__e(e,t,n)}else null==i&&t.__v==n.__v?(t.__k=n.__k,t.__e=n.__e):c=t.__e=_o(n.__e,t,n,o,r,i,a,u,s);return(l=En.diffed)&&l(t),128&t.__u?void 0:c}function fo(e){e&&(e.__c&&(e.__c.__e=!0),e.__k&&e.__k.some(fo))}function po(e){return"object"!=typeof e||null==e||e.__b>0?e:qn(e)?e.map(po):void 0!==e.constructor?null:Gn({},e)}function _o(e,t,n,o,r,i,a,c,u){var s,l,d,f,p,_,g,m=n.props||Vn,h=t.props,y=t.type;if("svg"==y?r="http://www.w3.org/2000/svg":"math"==y?r="http://www.w3.org/1998/Math/MathML":r||(r="http://www.w3.org/1999/xhtml"),null!=i)for(s=0;s<i.length;s++)if((p=i[s])&&"setAttribute"in p==!!y&&(y?p.localName==y:3==p.nodeType)){e=p,i[s]=null;break}if(null==e){if(null==y)return document.createTextNode(h);e=document.createElementNS(r,y,h.is&&h),c&&(En.__m&&En.__m(t,i),c=!1),i=null}if(null==y)m===h||c&&e.data==h||(e.data=h);else{if(i="textarea"==y&&null!=h.defaultValue?null:i&&Ln.call(e.childNodes),!c&&null!=i)for(m={},s=0;s<e.attributes.length;s++)m[(p=e.attributes[s]).name]=p.value;for(s in m)p=m[s],"dangerouslySetInnerHTML"==s?d=p:"children"==s||s in h||"value"==s&&"defaultValue"in h||"checked"==s&&"defaultChecked"in h||uo(e,s,null,p,r);for(s in h)p=h[s],"children"==s?f=p:"dangerouslySetInnerHTML"==s?l=p:"value"==s?_=p:"checked"==s?g=p:c&&"function"!=typeof p||m[s]===p||uo(e,s,p,m[s],r);if(l)c||d&&(l.__html==d.__html||l.__html==e.innerHTML)||(e.innerHTML=l.__html),t.__k=[];else if(d&&(e.innerHTML=""),oo("template"==t.type?e.content:e,qn(f)?f:[f],t,n,o,"foreignObject"==y?"http://www.w3.org/1999/xhtml":r,i,a,i?i[0]:n.__k&&Qn(n,0),c,u),null!=i)for(s=i.length;s--;)Kn(i[s]);c&&"textarea"!=y||(s="value","progress"==y&&null==_?e.removeAttribute("value"):null!=_&&(_!==e[s]||"progress"==y&&!_||"option"==y&&_!=m[s])&&uo(e,s,_,m[s],r),s="checked",null!=g&&g!=e[s]&&uo(e,s,g,m[s],r))}return e}function go(e,t,n){try{if("function"==typeof e){var o="function"==typeof e.__u;o&&e.__u(),o&&null==t||(e.__u=e(t))}else e.current=t}catch(e){En.__e(e,n)}}function mo(e,t,n){var o,r;if(En.unmount&&En.unmount(e),(o=e.ref)&&(o.current&&o.current!=e.__e||go(o,null,t)),null!=(o=e.__c)){if(o.componentWillUnmount)try{o.componentWillUnmount()}catch(e){En.__e(e,t)}o.base=o.__P=null}if(o=e.__k)for(r=0;r<o.length;r++)o[r]&&mo(o[r],t,n||"function"!=typeof e.type);n||Kn(e.__e),e.__c=e.__=e.__e=void 0}
vendor: 3,291 bytes, line 1
1function ho(e,t,n){return this.constructor(e,n)}Ln=Hn.slice,En={__e:function(e,t,n,o){for(var r,i,a;t=t.__;)if((r=t.__c)&&!r.__)try{if((i=r.constructor)&&null!=i.getDerivedStateFromError&&(r.setState(i.getDerivedStateFromError(e)),a=r.__d),null!=r.componentDidCatch&&(r.componentDidCatch(e,o||{}),a=r.__d),a)return r.__E=r}catch(t){e=t}throw e}},An=0,Zn.prototype.setState=function(e,t){var n;n=null!=this.__s&&this.__s!=this.state?this.__s:this.__s=Gn({},this.state),"function"==typeof e&&(e=e(Gn({},n),this.props)),e&&Gn(n,e),null!=e&&this.__v&&(t&&this._sb.push(t),to(this))},Zn.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),to(this))},Zn.prototype.render=Yn,Rn=[],kn="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Un=function(e,t){return e.__v.__b-t.__v.__b},no.__r=0,Pn=Math.random().toString(8),On="__d"+Pn,Dn="__a"+Pn,Mn=/(PointerCapture)$|Capture$/i,$n=0,xn=so(!1),Bn=so(!0),Fn=0;var yo,vo,wo,Co=[],bo=En,So=bo.__b,Io=bo.__r,To=bo.diffed,Lo=bo.__c,Eo=bo.unmount,Ao=bo.__;function Ro(){for(var e;e=Co.shift();){var t=e.__H;if(e.__P&&t)try{t.__h.some(Uo),t.__h.some(Po),t.__h=[]}catch(n){t.__h=[],bo.__e(n,e.__v)}}}bo.__b=function(e){yo=null,So&&So(e)},bo.__=function(e,t){e&&t.__k&&t.__k.__m&&(e.__m=t.__k.__m),Ao&&Ao(e,t)},bo.__r=function(e){Io&&Io(e);var t=(yo=e.__c).__H;t&&(vo===yo?(t.__h=[],yo.__h=[],t.__.some(function(e){e.__N&&(e.__=e.__N),e.u=e.__N=void 0})):(t.__h.some(Uo),t.__h.some(Po),t.__h=[])),vo=yo},bo.diffed=function(e){To&&To(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(1!==Co.push(t)&&wo===bo.requestAnimationFrame||((wo=bo.requestAnimationFrame)||ko)(Ro)),t.__H.__.some(function(e){e.u&&(e.__H=e.u),e.u=void 0})),vo=yo=null},bo.__c=function(e,t){t.some(function(e){try{e.__h.some(Uo),e.__h=e.__h.filter(function(e){return!e.__||Po(e)})}catch(n){t.some(function(e){e.__h&&(e.__h=[])}),t=[],bo.__e(n,e.__v)}}),Lo&&Lo(e,t)},bo.unmount=function(e){Eo&&Eo(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.some(function(e){try{Uo(e)}catch(e){t=e}}),n.__H=void 0,t&&bo.__e(t,n.__v))};var No="function"==typeof requestAnimationFrame;function ko(e){var t,n=function(){clearTimeout(o),No&&cancelAnimationFrame(t),setTimeout(e)},o=setTimeout(n,35);No&&(t=requestAnimationFrame(n))}function Uo(e){var t=yo,n=e.__c;"function"==typeof n&&(e.__c=void 0,n()),yo=t}function Po(e){var t=yo;e.__c=e.__(),yo=t}function Oo(e,t){for(var n in e)if("__source"!==n&&!(n in t))return!0;for(var o in t)if("__source"!==o&&e[o]!==t[o])return!0;return!1}function Do(e,t){this.props=e,this.context=t}(Do.prototype=new Zn).isPureReactComponent=!0,Do.prototype.shouldComponentUpdate=function(e,t){return Oo(this.props,e)||Oo(this.state,t)};var Mo=En.__b;En.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),Mo&&Mo(e)};var $o=En.__e;En.__e=function(e,t,n,o){if(e.then)for(var r,i=t;i=i.__;)if((r=i.__c)&&r.__c)return null==t.__e&&(t.__e=n.__e,t.__k=n.__k),r.__c(e,t);$o(e,t,n,o)};var xo=En.unmount;function Bo(e,t,n){return e&&(e.__c&&e.__c.__H&&(e.__c.__H.__.forEach(function(e){"function"==typeof e.__c&&e.__c()}),e.__c.__H=null),null!=(e=function(e,t){for(var n in t)e[n]=t[n];return e}({},e)).__c&&(e.__c.__P===n&&(e.__c.__P=t),e.__c.__e=!0,e.__c=null),e.__k=e.__k&&e.__k.map(function(e){return Bo(e,t,n)})),e}
1function Fo(e,t,n){return e&&n&&(e.__v=null,e.__k=e.__k&&e.__k.map(function(e){return Fo(e,t,n)}),e.__c&&e.__c.__P===t&&(e.__e&&n.appendChild(e.__e),e.__c.__e=!0,e.__c.__P=n)),e}function jo(){this.__u=0,this.o=null,this.__b=null}function Vo(e){var t=e.__&&e.__.__c;return t&&t.__a&&t.__a(e)}function Ho(){this.i=null,this.l=null}En.unmount=function(e){var t=e.__c;t&&(t.__z=!0),t&&t.__R&&t.__R(),t&&32&e.__u&&(e.type=null),xo&&xo(e)},(jo.prototype=new Zn).__c=function(e,t){var n=t.__c,o=this;null==o.o&&(o.o=[]),o.o.push(n);var r=Vo(o.__v),i=!1,a=function(){i||o.__z||(i=!0,n.__R=null,r?r(u):u())};n.__R=a;var c=n.__P;n.__P=null;var u=function(){if(! --o.__u){if(o.state.__a){var e=o.state.__a;o.__v.__k[0]=Fo(e,e.__c.__P,e.__c.__O)}var t;for(o.setState({__a:o.__b=null});t=o.o.pop();)t.__P=c,t.forceUpdate()}};o.__u++||32&t.__u||o.setState({__a:o.__b=o.__v.__k[0]}),e.then(a,a)},jo.prototype.componentWillUnmount=function(){this.o=[]},jo.prototype.render=function(e,t){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),o=this.__v.__k[0].__c;this.__v.__k[0]=Bo(this.__b,n,o.__O=o.__P)}this.__b=null}var r=t.__a&&Wn(Yn,null,e.fallback);return r&&(r.__u&=-33),[Wn(Yn,null,t.__a?null:e.children),r]};var zo=function(e,t,n){if(++n[1]===n[0]&&e.l.delete(t),e.props.revealOrder&&("t"!==e.props.revealOrder[0]||!e.l.size))for(n=e.i;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;e.i=n=n[2]}};(Ho.prototype=new Zn).__a=function(e){var t=this,n=Vo(t.__v),o=t.l.get(e);return o[0]++,function(r){var i=function(){t.props.revealOrder?(o.push(r),zo(t,e,o)):r()};n?n(i):i()}},Ho.prototype.render=function(e){this.i=null,this.l=new Map;var t=io(e.children);e.revealOrder&&"b"===e.revealOrder[0]&&t.reverse();for(var n=t.length;n--;)this.l.set(t[n],this.i=[1,0,this.i]);return e.children},Ho.prototype.componentDidUpdate=Ho.prototype.componentDidMount=function(){var e=this;this.l.forEach(function(t,n){zo(e,n,t)})};var qo="undefined"!=typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,Go=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,Ko=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,Wo=/[A-Z0-9]/g,Jo="undefined"!=typeof document,Yo=function(e){return("undefined"!=typeof Symbol&&"symbol"==typeof Symbol()?/fil|che|rad/:/fil|che|ra/).test(e)};Zn.prototype.isReactComponent=!0,["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(e){Object.defineProperty(Zn.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})});var Zo=En.event;En.event=function(e){return Zo&&(e=Zo(e)),e.persist=function(){},e.isPropagationStopped=function(){return this.cancelBubble},e.isDefaultPrevented=function(){return this.defaultPrevented},e.nativeEvent=e};var Qo={configurable:!0,get:function(){return this.class}},Xo=En.vnode;En.vnode=function(e){"string"==typeof e.type&&function(e){var t=e.props,n=e.type,o={},r=-1==n.indexOf("-");for(var i in t){var a=t[i];if(!("value"===i&&"defaultValue"in t&&null==a||Jo&&"children"===i&&"noscript"===n||"class"===i||"className"===i)){var c=i.toLowerCase();"defaultValue"===i&&"value"in t&&null==t.value?i="value":"download"===i&&!0===a?a="":"translate"===c&&"no"===a?a=!1:"o"===c[0]&&"n"===c[1]?"ondoubleclick"===c?i="ondblclick":"onchange"!==c||"input"!==n&&"textarea"!==n||Yo(t.type)?"onfocus"===c?i="onfocusin":"onblur"===c?i="onfocusout":Ko.test(i)&&(i=c):c=i="oninput":r&&Go.test(i)?i=i.replace(Wo,"-$&").toLowerCase():null===a&&(a=void 0),"oninput"===c&&o[i=c]&&(i="oninputCapture"),o[i]=a}}"select"==n&&(o.multiple&&Array.isArray(o.value)&&(o.value=io(t.children).forEach(function(e){e.props.selected=-1!=o.value.indexOf(e.props.value)})),null!=o.defaultValue&&(o.value=io(t.children).forEach(function(e){e.props.selected=o.multiple?-1!=o.defaultValue.indexOf(e.props.value):o.defaultValue==e.props.value}))),t.class&&!t.className?(o.class=t.class,Object.defineProperty(o,"className",Qo)):t.className&&(o.class=o.className=t.className),e.props=o}(e),e.$$typeof=qo,Xo&&Xo(e)};var er=En.__r;En.__r=function(e){er&&er(e),e.__c};var tr,nr=En.diffed;En.diffed=function(e){nr&&nr(e);var t=e.props,n=e.__e;null!=n&&"textarea"===e.type&&"value"in t&&t.value!==n.value&&(n.value=null==t.value?"":t.value)},"function"==typeof SuppressedError&&SuppressedError;new class{constructor(){this.globalEventName="disw-user-info-event","undefined"==typeof window||window.__userInfoEventStore||(window.__userInfoEventStore=new Map)}subscribe(e,t){const n=t=>{var n;try{const o=null===(n=t.detail)||void 0===n?void 0:n.event;o&&e(o)}catch(e){}};"undefined"!=typeof window&&window.addEventListener(this.globalEventName,n);return!1!==(null==t?void 0:t.replay)&&this.replayEventsToSubscriber(e),()=>{"undefined"!=typeof window&&window.removeEventListener(this.globalEventName,n)}}emit(e){if("undefined"!=typeof window){window.__userInfoEventStore||(window.__userInfoEventStore=new Map),window.__userInfoEventStore.set(e.type,e);try{const t=new CustomEvent(this.globalEventName,{detail:{event:e,timestamp:Date.now()}});window.dispatchEvent(t)}catch(e){}}}replayEventsToSubscriber(e){if("undefined"==typeof window||!window.__userInfoEventStore)return;["success","created","error"].forEach(t=>{var n;const o=null===(n=window.__userInfoEventStore)||void 0===n?void 0:n.get(t);if(o)try{e(o)}catch(e){}})}
1emitSuccess(e){this.emit({type:"success",data:e})}emitCreated(e){this.emit({type:"created",data:e})}emitError(e){this.emit({type:"error",error:e})}getListenerCount(){return 0}getEventBacklog(){return"undefined"!=typeof window&&window.__userInfoEventStore?new Map(window.__userInfoEventStore):new Map}clearEventBacklog(){"undefined"!=typeof window&&window.__userInfoEventStore&&window.__userInfoEventStore.clear()}},function(e){function t(e){var n,o;return this.getChildContext||(n=new Set,(o={})[t.__c]=this,this.getChildContext=function(){return o},this.componentWillUnmount=function(){n=null},this.shouldComponentUpdate=function(e){this.props.value!=e.value&&n.forEach(function(e){e.__e=!0,to(e)})},this.sub=function(e){n.add(e);var t=e.componentWillUnmount;e.componentWillUnmount=function(){n&&n.delete(e),t&&t.call(e)}}),e.children}t.__c="__cC"+Fn++,t.__=e,t.Provider=t.__l=(t.Consumer=function(e,t){return e.children(t)}).contextType=t}(null);class or{}class rr extends or{constructor(){super(...arguments),this.isSalesRep=!1}transformShoppingCart(e){var t,n,o,r,i,a,c,u,s,l,d,f,p,_,g,m,h;return e&&"object"==typeof e?{cartId:null!==(t=e.cartId)&&void 0!==t?t:"",currency:null!==(n=e.currency)&&void 0!==n?n:"",createdDate:null!==(o=e.createdDate)&&void 0!==o?o:"",expiryDate:null!==(r=e.expiryDate)&&void 0!==r?r:null,assistedCart:null!==(i=e.assistedCart)&&void 0!==i&&i,hasPreviousPOA:null!==(a=e.hasPreviousPOA)&&void 0!==a&&a,cartItems:Array.isArray(e.cartItems)?e.cartItems:[],promotionCodes:Array.isArray(e.promotionCodes)?e.promotionCodes:[],totalQuantity:null!==(c=e.totalQuantity)&&void 0!==c?c:0,subTotal:null!==(u=e.subTotal)&&void 0!==u?u:0,totalDiscountValue:null!==(s=e.totalDiscountValue)&&void 0!==s?s:0,totalTax:null!==(l=e.totalTax)&&void 0!==l?l:0,grandTotal:null!==(d=e.grandTotal)&&void 0!==d?d:0,selectedPaymentMethod:null!==(f=e.selectedPaymentMethod)&&void 0!==f?f:null,checkoutConfiguration:null!==(p=e.checkoutConfiguration)&&void 0!==p?p:{hasEca:!1,hasAX:!1,hasFloating:!1,hasNodeLocked:!1,hasInsightHub:!1,hasIndustrialEdge:!1},soldThrough:null!==(_=e.soldThrough)&&void 0!==_?_:"",cartSource:null!==(g=e.cartSource)&&void 0!==g?g:"",expansionSubscriptionName:null!==(m=e.expansionSubscriptionName)&&void 0!==m?m:"",portfolio:null!==(h=e.portfolio)&&void 0!==h?h:null,rejectionReason:Array.isArray(e.rejectionReason)?e.rejectionReason:[]}:{cartId:"",currency:"",createdDate:"",expiryDate:null,assistedCart:!1,hasPreviousPOA:!1,cartItems:[],promotionCodes:[],totalQuantity:0,subTotal:0,totalDiscountValue:0,totalTax:0,grandTotal:0,selectedPaymentMethod:null,checkoutConfiguration:{hasEca:!1,hasAX:!1,hasFloating:!1,hasHardware:!1,hasNodeLocked:!1,hasInsightHub:!1,hasIndustrialEdge:!1,hasDigitalServices:!1},soldThrough:"",cartSource:"",expansionSubscriptionName:"",portfolio:null,rejectionReason:[]}}transformCartCompositeProducts({items:e,compositeProductsLoading:t}){if(!e||0===e.length)return;return{items:e.map(e=>{var t,n,o,r,i,a,c,u,s,l,d,f,p,_,g,m,h,y,v,w,C,b,S;const I={id:(null===(t=e.productDetails)||void 0===t?void 0:t.productId)||"",price:(null===(o=null===(n=e.pricing)||void 0===n?void 0:n.subTotal)||void 0===o?void 0:o.toString())||"0",currency:(null===(r=e.pricing)||void 0===r?void 0:r.currency)||"USD",displayTerm:(null===(a=null===(i=e.attributes)||void 0===i?void 0:i.find(e=>"Subscription Term"===e.name))||void 0===a?void 0:a.displayValue)||"Annual",autoRenew:(null===(c=e.pricing)||void 0===c?void 0:c.autoRenew)||!1,priceAdjustmentTiers:(null===(s=null===(u=e.pricing)||void 0===u?void 0:u.priceAdjustment)||void 0===s?void 0:s.priceAdjustmentTiers)||[],term:(null===(l=e.pricing)||void 0===l?void 0:l.term)||"annually upfront"},T="Add-on"!==(null===(d=e.productDetails)||void 0===d?void 0:d.kitType)||(null===(p=null===(f=e.productDetails)||void 0===f?void 0:f.quantityRules)||void 0===p?void 0:p.minimum)&&parseFloat(e.productDetails.quantityRules.minimum)>0;return{productName:(null===(_=e.productDetails)||void 0===_?void 0:_.productName)||"",productId:(null===(g=e.productDetails)||void 0===g?void 0:g.productId)||"",pricingOption:I,numberSeats:(null===(m=e.pricing)||void 0===m?void 0:m.quantity)||1,setNumberSeats:e=>{},minimumQuantity:(null===(y=null===(h=e.productDetails)||void 0===h?void 0:h.quantityRules)||void 0===y?void 0:y.minimum)||(T?"1":"0"),maximumQuantity:(null===(w=null===(v=e.productDetails)||void 0===v?void 0:v.quantityRules)||void 0===w?void 0:w.maximum)||"100",required:T,name:(null===(C=e.productDetails)||void 0===C?void 0:C.productName)||"",productSku:(null===(b=e.productDetails)||void 0===b?void 0:b.productSku)||"",selectedPricingOption:I,pricingOptions:[I],productLoading:!1,paymentOptions:(null===(S=e.productDetails)||void 0===S?void 0:S.paymentOptions)||[],preRequisites:{},soldThrough:e.soldThrough||"",portfolio:e.portfolio||"",termsAndConditions:[],productTypology:e.productTypology||{class:"",classification:"",type:""},sellerInfo:e.sellerInfo||null}}),compositeProductsLoading:t}}transformCatalogCompositeProducts({compositeProducts:e,compositeProductsLoading:t}){if(!e||0===e.length)return;const n=[];
1return e.forEach(e=>{var t,o;const r={id:e.productId,price:e.unitPrice||e.listPrice||"0",currency:"USD",displayTerm:"Annual",autoRenew:!0,term:"annually upfront"},i=(null===(t=e.minimumQuantity)||void 0===t?void 0:t.toString())||"0",a=(e.minimumQuantity||0)>0,c={productName:e.name,productId:e.productId,pricingOption:r,numberSeats:e.minimumQuantity||1,setNumberSeats:e=>{},minimumQuantity:i,maximumQuantity:(null===(o=e.maximumQuantity)||void 0===o?void 0:o.toString())||"100",required:a,name:e.name,productSku:e.productId,selectedPricingOption:r,pricingOptions:[r],productLoading:!1,paymentOptions:[],preRequisites:{},soldThrough:"",portfolio:"",termsAndConditions:[],productTypology:{class:"",classification:"",type:""},sellerInfo:null,currentCartQuantity:e.currentCartQuantity||0,trialEligible:e.trialEligible};n.push(c)}),{items:n,compositeProductsLoading:t}}transformPaymentOption(e){}transformProduct(e){var t,n,o,r,i,a,c,u,s;if(!e)return;const l=(null===(t=e.quantityRules)||void 0===t?void 0:t.minimum)||"1",d=(null===(n=e.quantityRules)||void 0===n?void 0:n.maximum)||"100",f="DYNAMIC_KIT"===e.displayType||"Dynamic Kit"===(null===(o=e.productTypology)||void 0===o?void 0:o.classification)||"Dynamic Kit"===(null===(r=e.productTypology)||void 0===r?void 0:r.type),p=this._getCurrentCountry(),_=Array.isArray(e.entitlementCountries);let g=!0,m=[],h=null;if(!this.isSalesRep&&p&&_){const t=e.entitlementCountries.map(e=>(e||"").toString().trim().toLowerCase()),n=(p||"").toString().trim().toLowerCase();g=t.includes(n)}const y=Array.isArray(null===(i=e.variations)||void 0===i?void 0:i.items)&&e.variations.items.length>0;g?f||(m=((null===(a=e.variations)||void 0===a?void 0:a.items)||[]).map(e=>{var t,n,o,r,i,a,c;const u=null===(t=e.attributes)||void 0===t?void 0:t.find(e=>"Subscription Term"===e.name);return{id:e.id||"",price:(null===(n=e.pricing)||void 0===n?void 0:n.value)||"0",currency:(null===(o=e.pricing)||void 0===o?void 0:o.currency)||"USD",displayTerm:(null==u?void 0:u.displayValue)||"",autoRenew:!0,term:(null==u?void 0:u.value)||"",priceAdjustmentTiers:(null===(i=null===(r=e.pricing)||void 0===r?void 0:r.priceAdjustment)||void 0===i?void 0:i.priceAdjustmentTiers)||[],priceScheduleType:(null===(c=null===(a=e.pricing)||void 0===a?void 0:a.priceAdjustment)||void 0===c?void 0:c.scheduleType)||"",attributes:null==e?void 0:e.attributes,minCutoffDate:e.minCutoffDate}}),y||(h="noPricingInAPI")):(m=[],h="countryNotSupported");return{name:e.name,minLicenses:l,maxLicenses:d,pricingOptions:m,productId:e.productId,productSku:e.productSku,paymentOptions:e.paymentOptions||[],preRequisites:e.preRequisites||{},soldThrough:e.soldThrough||"",portfolio:e.portfolio||"",termsAndConditions:e.termsAndConditions||[],productTypology:e.productTypology||{class:"",classification:"",type:""},sellerInfo:e.sellerInfo||null,licenseType:e.licenseType||"",userType:e.userType||"",trialCompleted:!1===e.enableAddToCart||"false"===e.enableAddToCart,reasonForNoPricing:h,isDynamicKitInSupportedCountry:f&&g,baseKitVariationAttributes:null!==(u=null===(c=null==e?void 0:e.variations)||void 0===c?void 0:c.attributes)&&void 0!==u?u:[],baseKitAddOns:null!==(s=null==e?void 0:e.addOns)&&void 0!==s?s:[],showListPrice:e.showListPrice,requireAccessCode:null==e?void 0:e.requireAccessCode,productFamily:e.productFamily||"",isPersonalized:e.isPersonalized||!1,variations:(null==e?void 0:e.variations)||{items:[],attributes:[]}}}transformPricingOption(e){var t,n,o;if(!e)return;const r=null===(t=e.attributes)||void 0===t?void 0:t.find(e=>"Subscription Term"===e.name);return{id:e.id||"",price:(null===(n=e.pricing)||void 0===n?void 0:n.value)||"0",currency:(null===(o=e.pricing)||void 0===o?void 0:o.currency)||"USD",displayTerm:(null==r?void 0:r.displayValue)||"",autoRenew:!0,term:(null==r?void 0:r.value)||""}}_getCurrentCountry(){var e,t;try{const n=null===(t=null===(e=null===window||void 0===window?void 0:window.disw)||void 0===e?void 0:e.country)||void 0===t?void 0:t.getCountry();if(!(null==n?void 0:n.countrycode))return;const o=n.countrycode.toUpperCase(),r=rr.COUNTRY_CODE_TO_NAME[o];return r||n.countryname}catch(e){return}}}rr.COUNTRY_CODE_TO_NAME={US:"United States",GB:"United Kingdom",DE:"Germany",FR:"France",IT:"Italy",ES:"Spain",NL:"Netherlands",BE:"Belgium",AT:"Austria",CH:"Switzerland",SE:"Sweden",NO:"Norway",DK:"Denmark",FI:"Finland",PL:"Poland",CZ:"Czech Republic",HU:"Hungary",RO:"Romania",BG:"Bulgaria",GR:"Greece",PT:"Portugal",IE:"Ireland",LU:"Luxembourg",SK:"Slovakia",SI:"Slovenia",HR:"Croatia",EE:"Estonia",LV:"Latvia",LT:"Lithuania",CA:"Canada",MX:"Mexico",BR:"Brazil",AR:"Argentina",CL:"Chile",CO:"Colombia",PE:"Peru",AU:"Australia",NZ:"New Zealand",JP:"Japan",KR:"Korea, Republic of",CN:"China",IN:"India",SG:"Singapore",MY:"Malaysia",TH:"Thailand",ID:"Indonesia",PH:"Philippines",VN:"Vietnam",ZA:"South Africa",AE:"United Arab Emirates",SA:"Saudi Arabia",IL:"Israel",TR:"Turkey",RU:"Russia",UA:"Ukraine",TW:"Taiwan"},new rr,new rr,function(e){e.ONE_TIME="One Time",e.CREDIT_CARD="Credit Card",e.INVOICE_PAYMENT="Invoice Payment",e.REQUEST_FOR_QUOTE="Request for Quote",e.PAYMENT_ON_ACCOUNT="Payment on Account"}(tr||(tr={}));let ir,ar=o,cr=!1,ur=`${_t(o)}/checkout`,sr=dt;const lr="cartClearedAfterCheckout";const dr=e=>{((e,t)=>
1{const{domain:n,path:o}=t;let r=`${e}=;`;n&&(r=`${r} Domain=${n};`),o&&(r=`${r} Path=${o};`),document.cookie=`${r} Expires=Thu, 01 Jan 1970 00:00:00 GMT`})(e,{domain:ir,path:"/"})};var fr={ANNUAL_SUBSCRIPTION_TERM:"Yearly",ANNUAL_SUBSCRIPTION_DISPLAY_TERM:"Annual Subscription",SAME_PRODUCT_DIFFERENT_TERM:"SAME_PRODUCT_DIFFERENT_TERM",MONTHLY_SUBSCRIPTION_TERM:"Monthly",MONTHLY_SUBSCRIPTION_DISPLAY_TERM:"Monthly Subscription",THREE_YEAR_SUBSCRIPTION_DISPLAY_TERM:"3 Year Subscription",clearCartDataAfterCheckout:function(){const e=`${window.disw.country.getCountry().countrycode}_cartId`;dr(e),E(S.CART,null,lr)},getCartCheckoutServiceUrl:function(){return ur},getWebkeyUpdateProfileUrl:function(){return sr},isCheckoutEnabled:function(){return cr},subscribeToCart:function(e){return A(S.CART,e)},subscribeToECommerce:function(e){return A(S.ECOMMERCE,e)},subscribeToFullCart:function(e){return A(S.FULL_CART,e)},subscribeToMiniCart:function(e){return A(S.MINI_CART,e)},toggleFullCart:async function(e){const t=P.getPathname();if(!t.includes("/cart")){const e=t.replace(/\/([a-z]{2}-([a-z]{2}|[A-Z]{2}))\/(.*)/,"/$1/cart");P.navigate(P.getOrigin()+e)}},toggleMiniCart:function(e){E(S.MINI_CART,e)},updateCartData:function(e){E(S.CART,e,!1)},CART_ERROR_INITIALIZING_CART:"initializingCart",CART_ERROR_FETCHING_CART_DATA:"fetchingCartData",ECOMMERCE_PRODUCT_FETCHED:"productFetched",CART_CLEARED_AFTER_CHECKOUT:lr,getCartEnv:function(){return ar},_setCartEnv:function(e){ar=e},emitCartEvent:function(...e){E(S.CART,...e)},emitEcommerceEvent:function(...e){E(S.ECOMMERCE,...e)}};const pr="Cart Viewed",_r="Checkout Started",gr="Coupon Entered",mr="Coupon Applied",hr="Coupon Denied",yr="Coupon Removed",vr="Product Added",wr="Product Removed",Cr="Checkout Step Viewed",br="Checkout Step Completed",Sr="Order Completed",Ir="Product Viewed",Tr="Product Clicked",Lr="Product List Viewed";let Er;const Ar={items:[]},Rr=[window.disw.cart?.CART_ERROR_INITIALIZING_CART,window.disw.cart?.CART_ERROR_FETCHING_CART_DATA],Nr=(e,t)=>window.analytics&&window.analytics.track?window.analytics.track(e,t):null,kr=()=>Er?.items?.map((e,t)=>({name:e.product?.name,position:parseInt(t??0,10),price:Ur(e.product.pricingOptions?.find(e=>!0===e.autoRenew)?.price),product_id:e.product?.productSku,quantity:parseInt(e.quantity,10),sku:e.product?.productSku})),Ur=e=>null==e||isNaN(e)?0:parseFloat(e),Pr=()=>{const e=P.getCurrentUrl(),t=new URL(e);return`${t.origin}${t.pathname}`};var Or={registerAnalytics:()=>{try{window.disw.cart.subscribeToCart((e,t)=>{t?Rr.some(e=>e===t)&&(Er=Ar):Er=e})}catch(e){}},registerCartUpdate:e=>{Er=e},cartViewed:e=>{if(Er||e){e&&(Er=e);try{const e={cart_id:Er?.id,products:kr()||[]};if(e.products?.length<=0)return;return Nr(pr,e)}catch(e){}}},checkoutStarted:()=>{try{const e={cart_id:Er?.id,currency:Er?.currency,discount:Ur(Er?.discount),order_id:"",products:kr(),revenue:Ur(Er?.subTotal),...Er?.promotionCodes[0]&&{coupon:Er?.promotionCodes[0]}};return Nr(_r,e)}catch(e){}},couponEntered:e=>{try{return Nr(gr,{cart_id:Er?.id,coupon_id:e,order_id:""})}catch(e){}},couponApplied:e=>{try{const t={cart_id:Er?.id,coupon_id:e,coupon_name:e,order_id:"",discount:Ur(Er?.discount)};return Nr(mr,t)}catch(e){}},couponDenied:(e,t)=>{try{return Nr(hr,{cart_id:Er?.id,coupon_id:e,coupon_name:e,order_id:"",reason:t||Er?.message})}catch(e){}},couponRemoved:e=>{try{const t={order_id:"",cart_id:Er?.id,coupon_id:e,coupon_name:e,discount:Ur(Er?.discount)};return Nr(yr,t)}catch(e){}},productAdded:(e,t,n=0,o)=>{try{const r=Er.items.find(t=>t.product?.pricingOptions?.find(t=>t.id===e)),i=r.product?.pricingOptions?.find(t=>t.id===e),a={cart_id:Er?.id,image_url:r.product?.thumbnail,name:r.product?.name,sku:r.product?.productSku,price:Ur(i?.price),product_id:r.product?.productSku,position:parseInt(n??0,10),quantity:parseInt(o,10),url:Pr(),...t&&{coupon:t}};return Nr(vr,a)}catch(e){}},productRemoved:(e,t,n=0,o)=>{try{const r=Er.items.find(t=>t.id===e),i=r?.product?.pricingOptions?.find(e=>!0===e.autoRenew),a={cart_id:Er?.id,image_url:r?.product?.thumbnail,name:r?.product?.name,sku:r?.product?.productSku,price:Ur(i?.price),product_id:r?.product?.productSku,position:parseInt(n??0,10),quantity:Math.abs(parseInt(o,10)),url:Pr(),...t&&{coupon:t}};return Nr(wr,a)}catch(e){}},productDecreased:(e,t,n=0,o)=>{try{const r=Er.items.find(t=>t.product?.pricingOptions?.find(t=>
1t.id===e)),i=r?.product?.pricingOptions?.find(t=>t.id===e),a={cart_id:Er?.id,image_url:r?.product?.thumbnail,name:r?.product?.name,sku:r?.product?.productSku,price:Ur(i?.price),product_id:r?.product?.productSku,position:parseInt(n??0,10),quantity:Math.abs(parseInt(o,10)),url:Pr(),...t&&{coupon:t}};return Nr(wr,a)}catch(e){}},checkoutStepViewed:(e,t="")=>{if(Er)try{return Nr(Cr,{checkout_id:Er?.id,step:e+1,payment_method:t})}catch(e){}},checkoutStepCompleted:(e,t="")=>{if(Er)try{return Nr(br,{checkout_id:Er?.id,step:e+1,payment_method:t})}catch(e){}},orderCompleted:e=>{if(Er)try{const t={cart_id:Er?.id,order_id:e,products:kr(),revenue:Ur(Er?.subTotal),discount:Ur(Er?.discount),currency:Er?.currency,email:Er?.webkey,subtotal:Ur(Er?.subTotal),tax:Ur(Er?.tax),total:Ur(Er?.total),...Er?.promotionCodes[0]&&{coupon:Er?.promotionCodes[0]}};return Nr(Sr,t)}catch(e){}},productViewed:e=>{if(e)try{const t={name:e.name,sku:e.productSku,image_url:e?.thumbnail,url:Pr(),product_id:e.productSku};return Nr(Ir,t)}catch(e){}},productClicked:e=>{if(e)try{const t={name:e.name,sku:e.sku,image_url:e?.image?.url,url:Pr(),product_id:e.sku,quantity:e?.quantity};return Nr(Tr,t)}catch(e){}},productListViewed:(e,t)=>{if(e)try{return Nr(Lr,{list_id:t,products:e})}catch(e){}}};var Dr={numericStepperIncreased:function(e,t){E(S.NUMERIC_STEPPER,{increase:!0,change:!1,changeValue:t},e)},numericStepperDecreased:function(e,t){E(S.NUMERIC_STEPPER,{increase:!1,change:!1,changeValue:t},e)},numericStepperChanged:function(e,t){E(S.NUMERIC_STEPPER,{increase:!1,change:!0,changeValue:t},e)},subscribeToNumericStepper:function(e){return A(S.NUMERIC_STEPPER,e)}};var Mr={resultsReceived:function(e,t){E(S.RELATED_RESOURCES,{resultCount:t},e)},subscribeToRelatedResources:function(e){return A(S.RELATED_RESOURCES,e)}};var $r={dropDownChanged:function(e,t){E(S.DROP_DOWN,{change:!0,changeValue:t},e)},subscribeToDropDown:function(e){return A(S.DROP_DOWN,e)}};var xr={closeModal:function(e,t){E(S.ADDED_TO_CART_MODAL,!!e,t)},subscribeToModal:function(e){return A(S.ADDED_TO_CART_MODAL,e)}};var Br={closeModal:function(e,t){const n="boolean"==typeof e?{success:e}:e;n.success,E(S.DYNAMIC_KIT_ADD_TO_CART,n,t)},subscribeToModal:function(e){return A(S.DYNAMIC_KIT_ADD_TO_CART,e)}};var Fr={closeSlideout:function(e,t){E(S.BASE_KIT_SLIDER,"boolean"==typeof e?{success:e}:e,t)},subscribeToSlideout:function(e){return A(S.BASE_KIT_SLIDER,e)},openSlideout:function(e){E(S.BASE_KIT_OPEN_SLIDEOUT,e)},subscribeToOpenSlideout:function(e){return A(S.BASE_KIT_OPEN_SLIDEOUT,e)}};var jr={closeModal:function(e,t,n){E(S.SUBSCRIPTION_TERMS_CONFLICT_MODAL,e,t,n)},subscribeToModal:function(e){return A(S.SUBSCRIPTION_TERMS_CONFLICT_MODAL,e)}};var Vr={closeModal:function(){E(S.VOLUME_BASED_PRICING_MODEL,{})},subscribeToModal:function(e){return A(S.VOLUME_BASED_PRICING_MODEL,e)}};const Hr=["fullCart"],zr=["ccrz__Cart","ccrz__CheckoutNew","ccrz__OrderConfirmation","cart","checkout"],qr="proactiveResolved",Gr=["RU"],Kr=[o,n,t];let Wr,Jr,Yr,Zr,Qr=o,Xr="https://resources.sw.siemens.com/en-US/contact-plm-store";async function ei(e={}){const{env:t=o,pageId:n}=e;return Qr=t,Zr=n,Kr.some(e=>e===Qr),await(async e=>{const t=new AbortController;setTimeout(()=>t.abort(),1e4);const n=P.getHostname(),o=`${_t(e)}/livechat/configuration/${n}`;return fetch(o,{signal:t.signal}).then(e=>{if(e.ok)return e.json();throw Error(e.statusText)}).catch(e=>{throw e})})(Qr).then(e=>{e&&(Xr=e.contactSalesUrl?.trim()||Xr,Wr=e.timeToPopUp,Jr=e.timeToAutoClose,Yr=e.liveChatSwitch)}).catch(()=>{}),ri()}const ti=()=>[n,t].some(e=>e===Qr);function ni(){window.icPatronChat?E(S.LIVE_CHAT):P.navigate(window.disw.context.addContextToUrl(Xr))}async function oi(){const e=await(async e=>{const t=new AbortController;setTimeout(()=>t.abort(),1e4);const n=`${_t(e)}/livechat/schedule/false/chatbox/global`;return fetch(n,{signal:t.signal}).then(e=>e.ok?e.json():void 0).catch(e=>{throw e})})(Qr);return!!e&&e.open}function ri(){return{CONTACT_SALES_URL:ci(),timeToPopUp:Wr,timeToAutoClose:Jr,liveChatSwitch:Yr}}const ii=()=>Gr,ai=()=>{const e=new URLSearchParams(P.getSearch());if(Hr.some(t=>e.has(t)))return!0;const t=P.getPathname().split("/");return!!zr.some(e=>t.includes(e))},ci=()=>{const e=window.disw.locales.getCurrentLocaleCode();if(!e)return"";const t="sr-Latn-RS"===e?"sr-RS":e;return Xr.replace("en-US",t)};var ui={getLiveChatConfiguration:ri,initializeChat:ei,initiateMarketingPreliminaryModal:function(){ni()},initiateSalesPreliminaryModal:function(){ni()},initiateLiveChat:ni,isChatAgentAvailable:oi,getLiveIconData:async function(){return{isChatAgentAvailable:await oi(),areCookiesEnabled:!!document.cookie.split("; ").find(e=>e.trimStart().startsWith("fs_uid="))}},getPageId:function(){return Zr},isChatDisabledForCountry:async function(){try{const e=ii();if(e.length>0){const t=window.disw.country.getCountry();if(t?.countrycode&&e.includes(t.countrycode))return!0}}catch(e){}return!1},isDevModeEnabled:ti,isPotentiallyHighValueJourney:ai,isPurchasingAvailableOnPage:()=>!!document.querySelector(".btn-commerce-active"),isProactiveCookieSet:()=>void 0!==xt(qr),markProactiveResolved:e=>{((e,t=!1)=>{let n=new Date;n.setTime(n.getTime()+24*e*60*60*1e3),Bt(qr,"",t?{expires:n,path:"/"}:{expires:n,domain:".siemens.com",path:"/"})})(e,ti())},shouldBlockProactivePop:()=>ai(),subscribeToLiveChat:function(e){return A(S.LIVE_CHAT,e)},getContactSalesUrl:ci};const si="1c919bab-55c2-4596-8932-95f51643ff07",li=gt("prod"),di=new Map,fi="taxonomy_cac
1he_",pi=(e,t,n)=>`${e}:${t}:${n}`,_i=e=>{const t=(e=>{try{const t=sessionStorage.getItem(fi+e);if(null!==t)return JSON.parse(t)}catch(e){}})(e);return void 0!==t?(di.set(e,t),t):di.has(e)?di.get(e):void 0},gi=(e,t)=>{((e,t)=>{try{sessionStorage.setItem(fi+e,JSON.stringify(t))}catch(e){}})(e,t),di.set(e,t)},mi=()=>{try{return window?.disw?.locales?.getCurrentLocaleCode?.()||"en-US"}catch{return"en-US"}},hi=async(e,t)=>{let n,o;"string"==typeof e?(n=e,o=t):(n=e.locale||mi(),o=e.offeringUri);const r=pi(n,"offering",o),i=_i(r);if(void 0!==i)return i;try{if(!li)return null;const e=await fetch(`${li}/latest/offerings/${n}/${o}?cache=true`,{method:"GET",headers:{"x-api-key":si}});if(!e.ok)return null;const t=await e.json();return gi(r,t),t}catch(e){return null}},yi=async(e,t)=>{let n,o;"string"==typeof e?(n=e,o=t):(n=e.locale||mi(),o=e.sellerUri);const r=pi(n,"seller",o),i=_i(r);if(void 0!==i)return i;try{if(!li)return null;const e=await fetch(`${li}/latest/sellers/${n}/${o}?cache=true`,{method:"GET",headers:{"x-api-key":si}});if(!e.ok)return null;const t=await e.json();return gi(r,t),t}catch(e){return null}};var vi={getTaxonomyEnrichedOfferings:async e=>{try{const t={};if(!li)return[];const n=li;for(const o of e){const e=await fetch(`${n}/latest/offerings/${o}?cache=true`,{method:"GET",headers:{"x-api-key":si}});if(!e.ok)return[];const r=await e.json();t[o]=r}return t}catch(e){return[]}},getTaxonomyEnrichedOffering:hi,getTaxonomyEnrichedSeller:yi,getTaxonomyOfferingUrl:async e=>{const{uri:t,locale:n=mi()}=e;try{const e=await hi({locale:n,offeringUri:t});return e?.offeringPageUrl||null}catch(e){return null}},getTaxonomySellerUrl:async e=>{const{uri:t,locale:n=mi()}=e;try{const e=await yi({locale:n,sellerUri:t});return e?.sellerPageUrl||null}catch(e){return null}},getTaxonomyOfferingUrlByEcbeId:async e=>{const{ecbeId:t,locale:n=mi()}=e,o=pi(n,"offering-ecbe",t),r=_i(o);if(void 0!==r)return r;try{if(!li)return null;const e=await fetch(`${li}/latest/offerings?ecbeId=${t}&cache=true`,{method:"GET",headers:{"x-api-key":si}});if(!e.ok)return null;const r=await e.json();if(!r||0===r.length)return null;const i=r[0],a=i.offeringPageUrl;gi(o,a);const c=pi(n,"offering",i.uri);return gi(c,i),a}catch(e){return null}},clearTaxonomyCache:e=>{if(!e){di.clear();try{const e=[];for(let t=0;t<sessionStorage.length;t++){const n=sessionStorage.key(t);n&&n.startsWith(fi)&&e.push(n)}e.forEach(e=>sessionStorage.removeItem(e))}catch(e){}return}const t=e.replace("*",""),n=[];for(const e of di.keys())e.includes(t)&&n.push(e);n.forEach(e=>di.delete(e));try{const e=[];for(let n=0;n<sessionStorage.length;n++){const o=sessionStorage.key(n);if(o&&o.startsWith(fi)){o.substring(15).includes(t)&&e.push(o)}}e.forEach(e=>sessionStorage.removeItem(e))}catch(e){}}};const wi={auto:"format,compress"},Ci=e=>{if("string"!=typeof e)return!1;const t=e.split(":");if(2!==t.length)return!1;const[n,o]=t.map(Number);return!isNaN(n)&&!isNaN(o)&&n>0&&o>0};function bi(e,t){const n=(e=>{const t={};return"number"==typeof e.width&&(t.w=Math.round(e.width)),"number"==typeof e.height&&(t.h=Math.round(e.height)),"number"==typeof e.maxWidth&&(t["max-w"]=Math.round(e.maxWidth)),"number"==typeof e.maxHeight&&(t["max-h"]=Math.round(e.maxHeight)),Ci(e.aspectRatio)&&(t.ar=e.aspectRatio),e.fit&&(t.fit=e.fit),Array.isArray(e.crop)&&e.crop.length>0&&(t.crop=e.crop.join(",")),"number"==typeof e.quality&&(t.q=Math.max(1,Math.min(100,e.quality))),{...wi,...t}})(t),o=new URLSearchParams(n).toString();return e.includes("?")?`${e}&${o}`:`${e}?${o}`}var Si={imgCtfToS3Url:function(e,t="en-US",n={}){if(!e||!e.url)return"";try{const o=/^(https?\:)\/\/(([^:\/?#]*)(?:\:([0-9]+))?)([\/]{0,1}[^?#]*)(\?[^#]*|)(#.*|)$/,r=e.url.match(o);if(!r)throw new Error("Invalid Contentful URL");const i=r[5];if(!i)throw new Error("Invalid Contentful Image URL");const a=i.split("/");if(a.length<5)throw new Error("Invalid Contentful Image URL");const c=a[2],u=e.fileName??a[4];if(!c||!u)throw new Error("Invalid Contentful Image URL");const s=`https://images.sw.cdn.siemens.com/siemens-disw-assets/public/${c}/${t}/${encodeURIComponent(u)}`;return bi(s,n)}catch(e){return""}},appendImgixParamsToUrl:bi};function Ii(e,t=!1){E(S.TRIAL,e,t)}var Ti={emitTrial:Ii,setTrial:function(e){window.disw.trial=e,Ii(e)},subscribeToTrial:function(e){return A(S.TRIAL,e)}};function Li(r,i,a){return r?zt({...i}).then(()=>(e.didInitCountry=!0,Ei(a))).then(()=>async function(e={}){const{env:r=o,checkout:i}=e;
1var a,c;ar=r,i&&(a=i.enabled,c=!1,cr="boolean"==typeof a?a:"string"==typeof a?"true"===a.toLowerCase():c),ir=$t([t,n].includes(ar)),ur=`${_t(ar)}/checkout`,sr=ar===t?"https://webtest.industrysoftware.automation.siemens.com/WebkeyLogin/DigitalExchangeUpdateProfile":dt}({...r})).then(()=>{e.didInitCart=!0}):Ei(a)}function Ei(t){return t?p(t).then(()=>{e.didInitFeatures=!0}):Promise.resolve()}e.didInitFeatures=!1,e.didInitLocales=!1,e.didInitAccount=!1,e.didInitGTM=!1,e.didInitMTM=!1,e.didInitBreadcrumbs=!0,e.didInitCountry=!1,e.didInitCart=!1,e.didInitLocalizations=!1,e.didInitContextData=!1,e.didInitLiveChat=!1,e.currentTrialId=void 0,e.didInitRegion=!1;const Ai={...$e},Ri={...de},Ni={...je},ki={...Nt},Ui={...jn},Pi={...Mt},Oi={...Yt},Di={..._n},Mi={...fr},$i={...Or},xi={...Mr},Bi={...Dr},Fi={...$r},ji={...xr},Vi={...Br},Hi={...Fr},zi={...jr},qi={...Vr},Gi={...ui},Ki={...vi},Wi={...Si},Ji={...b},Yi={...P},Zi={...Ti};e.NavigationService=Yi,e.account=Ai,e.addedToCartModal=ji,e.baseKitSlideout=Hi,e.breadcrumbs=ki,e.cart=Mi,e.cartAnalytics=$i,e.chat=Gi,e.context=Ui,e.country=Oi,e.dropDown=Fi,e.dynamicKitSlideout=Vi,e.features=Ji,e.getCurrentTrialId=function(){return e.currentTrialId},e.getDidInitAccount=function(){return e.didInitAccount},e.getDidInitBreadcrumbs=function(){return e.didInitBreadcrumbs},e.getDidInitCart=function(){return e.didInitCart},e.getDidInitContextData=function(){return e.didInitContextData},e.getDidInitCountrys=function(){return e.didInitCountry},e.getDidInitLiveChat=function(){return e.didInitLiveChat},e.getDidInitLocales=function(){return e.didInitLocales},e.getDidInitLocalizations=function(){return e.didInitLocalizations},e.getDidInitRegion=function(){return e.didInitRegion},e.getdidInitGTM=function(){return e.didInitGTM},e.getdidInitMTM=function(){return e.didInitMTM},e.imgix=Wi,e.init=async function(t={}){const{features:n,locales:o,account:i,mtm:a,gtm:c,breadcrumbs:u,country:s,cart:l,localizations:d,context:f,chat:p,trials:_,region:g}=t;!function(e){let t=window.disw.NavigationService.getCurrentUrl();e(t);const n=new MutationObserver(()=>{window.disw.NavigationService.getCurrentUrl()!==t&&(t=window.disw.NavigationService.getCurrentUrl(),e(t))});n.observe(document,{subtree:!0,childList:!0,attributes:!1})}(e=>{const t=!e.includes("/checkout"),[n,o,r]=function(e,t){const n=localStorage.getItem(e);return[n?JSON.parse(n):t||null,function(t){const n=JSON.stringify(t);localStorage.setItem(e,n)},function(){localStorage.removeItem(e)}]}("checkout-local-data");t&&r()}),o&&(!function(e){if(!0===e)M(U.map(e=>e.code));else if(e&&Array.isArray(e)){if(0===e.length)return void r.warn("initializeLocales: Empty array passed - this would disable all locales! Keeping default behavior (all locales enabled).");M(e.reduce((e,t)=>{if(!$.test(t))return r.warn(`Invalid locale code format: ${t}`),e;const n=z(t);return n&&(e.includes(n.code)||e.push(n.code)),e},[]))}R&&E&&S&&E(S.LOCALES,{locales:{getCurrentLocaleCode:ie,getAllLocales:re,getSupportedLocales:ce,getSupportedLanguages:ue,findLocaleByCode:z,generateLocalePath:H,getDefaultLocaleCode:ae,navigation:ne,switchLocale:se,getDefaultLocale:le,getContactSalesUrlWithCurrentLocale:oe},didInitLocales:!0})}(o),e.didInitLocales=!0),void 0===i||!0===i?(Te().then(()=>{Li(l,s,n)}),e.didInitAccount=!0):"object"!=typeof i||Array.isArray(i)?r.warn("Account not initialized!"):(Te({...i}).then(()=>{Li(l,s,n),_&&(e.currentTrialId=_.trialId)}),e.didInitAccount=!0),a?(st({...a}),e.didInitMTM=!0):c&&(nt({...c}),e.didInitGTM=!0),u&&(!async function(e={}){const{site:t,locale:n=de.getCurrentLocaleCode(),env:o=wt,pages:i,overrides:a=!0}=e;if(Array.isArray(i)&&(St=i),t||i)if(It&&a)try{let e=JSON.parse(It);await Lt(e.site,n,o),Tt(i,At(e.page)),E(S.BREADCRUMBS,bt,!1)}catch(e){r.error(e),E(S.BREADCRUMBS,bt,e)}else i&&Tt(i,[]),await Lt(t,n,o),E(S.BREADCRUMBS,[],!1);else r.warn("'site' or 'pages' must be specified to load breadcrumbs")}({...u}),e.didInitBreadcrumbs=!0);const m=yt("bc");if(m)try{Tn(JSON.parse(m))}catch(e){r.warn("Could not parse bc query parameter for resource link decoration",e)}s&&!l&&zt({...s}).then(()=>{e.didInitCountry=!0}),async function(e={}){const{env:t=Ut,sessionStorage:n=!0}=e;
1Pt="prod"===t?"prod":"uat"===t?"stage":"qa"===t||"dev"===t?"dev":Ut,Ot=n}({env:"prod",...d}),e.didInitLocalizations=!0,f&&(!async function(e={}){const{pageId:t,site:n,slug:o,env:r}=e;gn=t,mn=n,hn=o,yn=r}({env:"prod",...f}),e.didInitContextData=!0),p&&(ei({...p}),e.didInitLiveChat=!0),void 0===g||!0===g?(un({env:"prod"}),e.didInitRegion=!0):"object"!=typeof g||Array.isArray(g)?r.warn("Region not initialized!"):(un({...g}),e.didInitRegion=!0)},e.locales=Ri,e.localizationTokens=Pi,e.numericStepper=Bi,e.region=Di,e.relatedResources=xi,e.subscriptionTermsConflictModal=zi,e.taxonomy=Ki,e.trialService=Zi,e.video=Ni,e.volumeBasedPricingModel=qi,Object.defineProperty(e,"__esModule",{value:!0})}); 2//# sourceMappingURL=xd-utils.min.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.