!function(e){function t(t){for(var r,o,l=t[0],s=t[1],u=t[2],c=0,p=[];c<l.length;c++)o=l[c],a[o]&&p.push(a[o][0]),a[o]=0;for(r in s)Object.prototype.hasOwnProperty.call(s,r)&&(e[r]=s[r]);for(g&&g(t);p.length;)p.shift()();return i.push.apply(i,u||[]),n()}function n(){for(var e,t=0;t<i.length;t++){for(var n=i[t],r=!0,l=1;l<n.length;l++){var s=n[l];0!==a[s]&&(r=!1)}r&&(i.splice(t--,1),e=o(o.s=n[0]))}return e}var r={},a={8:0},i=[];function o(t){if(r[t])return r[t].exports;var n=r[t]={i:t,l:!1,exports:{}};return e[t].call(n.exports,n,n.exports,o),n.l=!0,n.exports}o.m=e,o.c=r,o.d=function(e,t,n){o.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(e,t){if(1&t&&(e=o(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(o.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)o.d(n,r,function(t){return e[t]}.bind(null,r));return n},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="";var l=window.webpackJsonp=window.webpackJsonp||[],s=l.push.bind(l);l.push=t,l=l.slice();for(var u=0;u<l.length;u++)t(l[u]);var g=s;i.push([56,0]),n()}({56:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n(57),n(0),n(58),n(5);const r=n(59);t.languageSwitcher=new r.LanguageSwitcher(document)},57:function(e,t,n){e.exports=n.p+"../templates/login-layout.html"},58:function(e,t,n){e.exports=n.p+"map.png"},59:function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});t.LanguageSwitcher=class{constructor(t){this.availableLanguages=["de","en","fr","it"],this.urlExpression=new RegExp("([?&])lang=.*?(&|$)","i"),e(t).ready(()=>{this.$linkDE=e("#link-de"),this.$linkFR=e("#link-fr"),this.$linkIT=e("#link-it"),this.$linkEN=e("#link-en"),this.$languageSelectDesktop=e("#language-select-desktop > sdx-select-option"),this.$languageWrapperMobile=e("#language-wrapper-mobile"),this.navigator=navigator,this.registerLanguageChangeDesktopListener(),this.registerLanguageChangeMobileListener(),this.enableLanguageSwitching()})}enableLanguageSwitching(){let t=this.getCurrentLocale();switch(e("sdx-select-option[value="+t+"]").attr("selected","true"),t){case"de":this.$linkDE.hide();break;case"en":this.$linkEN.hide();break;case"fr":this.$linkFR.hide();break;case"it":this.$linkIT.hide()}}getPreferredBrowserLanguage(){let e=this.navigator.languages?this.navigator.languages[0]:this.navigator.language;return e.indexOf("-")>0?e.substr(0,e.indexOf("-")):e}getLanguageCookie(){var e=("; "+document.cookie).split("; org.springframework.web.servlet.i18n.CookieLocaleResolver.LOCALE=");if(2==e.length)return e.pop().split(";").shift()}updateLocaleParam(e){let t=location.href,n=-1!==t.indexOf("?")?"&":"?";t=t.match(this.urlExpression)?t.replace(/(lang=)[^\&]+/,"$1"+e):t+n+"lang="+e,window.location.href=t}getCurrentLocale(){let t=this.getLanguageCookie();return t||(t=this.getPreferredBrowserLanguage()),e.inArray(t,this.availableLanguages)>=0?t:this.availableLanguages[0]}registerLanguageChangeDesktopListener(){this.$languageSelectDesktop.on("click",e=>{this.updateLocaleParam(e.target.getAttribute("value"))})}registerLanguageChangeMobileListener(){this.$languageWrapperMobile.children("a").on("click",e=>{this.updateLocaleParam(e.target.getAttribute("data-lang"))})}}}).call(this,n(1))}});