{"version":3,"sources":["webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/header/client/js/cookie.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/header-master-expedient/client/js/store/actions.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/modal-msi/client/js/index.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/modal-msi/client/js/config.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/modal-origins/client/js/index.js","webpack:///./node_modules/@bluekiri/alexandria-contrib-components/components/origin-list/client/js/index.js","webpack:///./node_modules/@bluekiri/alexandria-contrib-components/components/origin-list/client/js/prototype.js","webpack:///./node_modules/@bluekiri/alexandria-contrib-components/components/origin-list/client/js/config.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/modal-origins/client/js/prototype.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/modal-origins/client/js/config.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/header-master-expedient/client/js/index.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/header-master-expedient/client/js/prototype.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/header-master-expedient/client/js/store/reducer.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/header-master-expedient/client/js/services/index.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/header-master-expedient/client/js/config.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/header/client/js/welcome.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/header/client/js/tooltip.js","webpack:///./node_modules/@bluekiri/alexandria-logitravel/components/header/client/js/index.js"],"names":["module","exports","getCookie","cname","name","concat","splitCookie","document","cookie","split","i","length","value","charAt","substring","indexOf","setCookie","cookieName","cookieValue","nDays","today","Date","expire","nDaysFinal","setTime","getTime","toGMTString","DESTROY","LOGOUT","types","actions","destroy","type","logout","elementExist","require","ModalClient","ImageClient","config","selector","arguments","undefined","modal","configuration","instance","element","querySelector","_objectSpread","images","_toConsumableArray","querySelectorAll","map","item","index","image","css","OriginListCLient","prototype","Object","create","origin","onOpen","addEventListener","onClose","removeEventListener","randomId","getConfig","id","dataset","init","initialize","$","buildRequest","_JSON$stringify2","session","JSON","stringify","_defineProperty","SessionCode","parameterName","prototypeConfiguration","this","parse","get","setCookieAutoOrigin","autoOrigin","ck_name","ck_value","onClickOrigin","e","target","parentElement","newSelectedOrigin","selectedOrigin","classList","remove","selectedClass","icon","lastChild","nodeName","appendChild","add","attributes","originOption","endpoint","verb","toLowerCase","setTimeout","promise","post","url","data","contentType","withCredentials","done","window","location","reload","fail","console","error","executeAjax","bindEvents","bind","contains","code","base","component","logitravel","result","hooks","Store","take","_require3","fromEvent","of","_require4","reducer","services","setupStore","store","headerMasterExpedient","setupActions","_this","dispatch","setupReactions","_this2","reactions","subscribe","state","action","unsubscribe","keys","forEach","key","parentNode","removeChild","endpoints","pipe","next","response","err","message","_this3","subscriptions","_this4","start","initialState","_require2","catchError","switchMap","fromFetch","ok","json","statusText","initWelcome","$containerModalLogin","literals","links","login","href","find","attr","title","_ref","html","loginModalNewUserTitle","loginModalNewUserDescription","loginModalNewUserButtonText","loginModalNewUserFooterText","loginModalButtonText","replaceData","tippy","tooltips","initTooltips","tippySelector","tippyTitle","tippytemplateId","tippyTheme","htmlElementExists","useTitle","tippyArrow","tippyTrigger","tippyConfig","delay","arrow","arrowType","duration","animation","placement","theme","allowTitleHTML","maxWidth","interactive","trigger","onShown","$buttonLogout","popper","on","urlLogout","currentTarget","sessionCode","ajax","complete","xhr","status","googleyolo","disableAutoSignIn","then","finally","parent","crossDomain","dataType","ModalMsiClient","ModalOriginsClient","HeaderMasterExpedient","addClassActive","listItemClass","dropdownClass","listItem","dropdown","hasClass","addClass","removeClass","triggers","modalCookie","closeButton","loginModal","click","elementLanguageDropdown","event","languageSelected","language","language_url","success","warn","elementCurrencyDropdown","currencySelected","currency","currency_url","userAgent","navigator","test","preventDefault"],"mappings":";sFAgCAA,EAAOC,QAAU,CACbC,UA7Bc,SAAA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AAa,kCACbD,KAAMpC,KAAKC,UAAU,CACjBgL,SAAUD,IAEdnB,SAAU,OACVsB,QAAS,WACL3I,OAAOmH,OAAOlH,SAASC,UAE3BrF,KAAM,OACN8E,IAAKxE,EAAOuN,eAGhBtI,QAAQwI,KAAK,kDAO7BxL,EAAE,iCAAiCmJ,GAAG,SAAS,WAC3C,IAAMsC,EAA0BzL,EAAE,uCAC9ByL,GACAA,EAAwBtC,GAAG,SAAS,SAAAgC,GAChC,IAAMpN,EAASqC,KAAKO,MAAMX,EAAE,uBAAuB+G,KAAK,gBAClD2E,EAAmBP,EAAM9B,cAAcxJ,QAAQ8L,SAEjD5N,EAAO6N,aACP5L,EAAEuJ,KAAK,CACH9G,YAAa,kCACbD,KAAMpC,KAAKC,UAAU,CACjBsL,SAAUD,IAEdzB,SAAU,OACVsB,QAAS,WACL3I,OAAOmH,OAAOlH,SAASC,UAE3BrF,KAAM,OACN8E,IAAKxE,EAAO6N,eAGhB5I,QAAQwI,KAAK,qDAOjCnB,EAAe,gCAAiC,uBAChDA,EAAe,gCAAiC,uBAahD,IAAMwB,EAAYC,UAAUD,UAAU1J,cAErB,kHAAkH4J,KAC/HF,IAIA7L,EAAE,0CAA0CmJ,GAAG,SAAS,SAAAjI,GACpD,QAAIlB,EAAEkB,EAAEmI,eAAeqB,SAAS,qBAGhC1K,EAAE,0CAA0C4K,YAAY,mBACxD5K,EAAEkB,EAAEmI,eAAesB,SAAS,mBAC5BzJ,EAAE8K,kBACK","file":"vendors~header.bundle.js","sourcesContent":["/* ==========================================================================\n Header > Client > Cookie\n ========================================================================== */\n\nconst getCookie = cname => {\n const name = `${cname}=`;\n const splitCookie = document.cookie.split(';');\n for (let i = 0; i < splitCookie.length; i++) {\n let value = splitCookie[i];\n while (value.charAt(0) === ' ') {\n value = value.substring(1);\n }\n if (value.indexOf(name) === 0) {\n return value.substring(name.length, value.length);\n }\n }\n return '';\n};\n\nconst setCookie = (cookieName, cookieValue, nDays) => {\n const today = new Date();\n const expire = new Date();\n\n let nDaysFinal = nDays;\n if (nDays === null || nDays === 0) {\n nDaysFinal = 1;\n }\n\n expire.setTime(today.getTime() + 3600000 * 24 * nDaysFinal);\n document.cookie = `${cookieName}=${cookieValue};expires=${expire.toGMTString()};path=/`;\n};\n\nmodule.exports = {\n getCookie,\n setCookie\n};\n","/* ==========================================================================\n HeaderMasterExpedient > Client > Store > Actions\n ========================================================================== */\n\n/* Types */\nconst DESTROY = 'HEADER_MASTER_EXPEDIENT::DESTROY';\nconst LOGOUT = 'HEADER_MASTER_EXPEDIENT::LOGOUT';\n\n/* Actions */\nconst destroy = () => ({ type: DESTROY });\nconst logout = () => ({ type: LOGOUT });\n\n/* Exports */\nmodule.exports = {\n types: {\n DESTROY,\n LOGOUT\n },\n actions: {\n destroy,\n logout\n }\n};\n","/* ==========================================================================\n ModalMsi > Client\n ========================================================================== */\n\n/* Import modules */\nconst { elementExist } = require('@bluekiri/alexandria/helpers/domHelpers');\nconst ModalClient = require('@bluekiri/alexandria-contrib-components/components/modal/client/js');\nconst ImageClient = require('@bluekiri/alexandria-contrib-components/components/image/client/js');\nconst config = require('./config');\n\n/**\n * ModalMsi component\n * @param {selector} String selector for the component in the client side.\n */\nmodule.exports = function ModalMsi(\n selector = `[data-component=\"Modal\"][data-type=\"${config().type.modal}\"]`,\n configuration = {}\n) {\n if (elementExist(selector)) {\n /* Instance */\n const instance = {};\n\n /* Element */\n instance.element = document.querySelector(selector);\n\n /* Config */\n instance.config = { ...config(), ...configuration };\n\n /* Images */\n instance.images = [...instance.element.querySelectorAll('[data-component=\"Image\"]')].map((item, index) =>\n ImageClient(`${selector} [data-component=\"Image\"][data-type=\"${config().type.image}-${index}\"]`, {\n ...configuration.image\n })\n );\n\n /* Modal */\n instance.modal = ModalClient(selector, {\n ...configuration.modal,\n type: config().type.modal\n });\n\n /* Returns */\n return instance;\n }\n};\n","/* ==========================================================================\n ModalMsi > Client > Config\n ========================================================================== */\n\n/* Config */\nconst config = {\n type: {\n modal: 'modal-msi',\n image: 'modal-msi-image'\n },\n css: {\n modal: 'modal--msi'\n }\n};\n\n/* Exports */\nmodule.exports = () => config;\n","/* ==========================================================================\n ModalOrigins > Client\n ========================================================================== */\n\n/* Import modules */\nconst { elementExist } = require('@bluekiri/alexandria/helpers/domHelpers');\nconst ModalClient = require('@bluekiri/alexandria-contrib-components/components/modal/client/js');\nconst OriginListCLient = require('@bluekiri/alexandria-contrib-components/components/origin-list/client/js');\nconst prototype = require('./prototype');\nconst config = require('./config');\n\n/**\n * ModalOrigins component\n * @param {selector} String selector for the component in the client side.\n */\nmodule.exports = function ModalOrigins(\n selector = `[data-component=\"Modal\"][data-type=\"${config().type.modal}\"]`,\n configuration = {}\n) {\n if (elementExist(selector)) {\n /* Instance */\n const instance = Object.create(prototype);\n\n /* Element */\n instance.element = document.querySelector(selector);\n\n /* Config */\n instance.config = { ...config(), ...configuration };\n\n /* Origins */\n instance.origin = OriginListCLient(`${selector} [data-component=\"OriginList\"]`, {\n ...configuration.origin\n });\n\n /* Modal */\n instance.modal = ModalClient(selector, {\n ...configuration.modal,\n type: config().type.modal,\n onOpen: () => instance.addEventListener(),\n onClose: () => instance.removeEventListener()\n });\n\n /* Clean */\n instance.removeEventListener();\n\n /* Return */\n return instance;\n }\n};\n","/* Import modules */\nconst { elementExist } = require('@bluekiri/alexandria/helpers/domHelpers');\nconst { randomId } = require('@bluekiri/alexandria/helpers/dataHelpers');\nconst prototype = require('./prototype');\nconst config = require('./config');\n\nmodule.exports = function OriginListClient(selector = '[data-component=\"OriginList\"]', configuration = {}) {\n if (elementExist(selector)) {\n const instance = Object.create(prototype);\n\n instance.element = document.querySelector(selector);\n\n instance.config = { ...config(), ...instance.getConfig(), ...configuration };\n\n instance.id = instance.element.dataset.id || randomId('origin-list');\n\n if (instance.config.init) instance.initialize();\n\n return instance;\n }\n};\n","const $ = require('jquery/dist/jquery');\n\nconst buildRequest = function fn(configuration, instance) {\n if (configuration.session) {\n return JSON.stringify({ SessionCode: configuration.session, [configuration.parameterName]: instance.value });\n }\n return JSON.stringify({ [configuration.parameterName]: instance.value, Source: 900 });\n};\n\nconst executeAjax = function fn(instance) {\n const configuration = instance.config;\n\n // Exit in case we dont have the information we need\n if (!(configuration.endpoint && configuration.parameterName && configuration.verb)) return false;\n\n const verb = configuration.verb.toLowerCase();\n\n setTimeout(() => {\n let promise;\n if (verb === 'post') {\n promise = $.post({\n url: configuration.endpoint,\n data: buildRequest(configuration, instance),\n contentType: 'application/json; charset=utf-8',\n withCredentials: true\n });\n } else if (verb === 'get') {\n promise = $.get({\n url: configuration.endpoint,\n data: buildRequest(configuration, instance),\n contentType: 'application/json; charset=utf-8',\n withCredentials: true\n });\n }\n\n if (promise) {\n promise\n .done(() => {\n window.location.reload(true);\n })\n .fail(() => {\n console.error('Oooopsss ... An error has occurred to change the origin :(');\n });\n }\n }, 1);\n\n return true;\n};\n\nmodule.exports = {\n getConfig: function fn() {\n let prototypeConfiguration = {};\n\n if (this.element) {\n const configuration = this.element.dataset.config;\n\n if (configuration) {\n prototypeConfiguration = JSON.parse(configuration);\n this.element.dataset.config = '';\n }\n }\n\n return prototypeConfiguration;\n },\n get: function fn() {\n return this.value || '';\n },\n setCookieAutoOrigin: function fn() {\n if (this.config && this.config.autoOrigin) {\n document.cookie = `${this.config.autoOrigin.ck_name}=${this.config.autoOrigin.ck_value};path=/`;\n }\n },\n onClickOrigin: function fn(e) {\n if (e.target.parentElement === this.element) {\n const newSelectedOrigin = e.target;\n\n if (newSelectedOrigin === this.selectedOrigin) return false;\n\n this.setCookieAutoOrigin();\n\n // --> We have a selected origin?\n if (this.selectedOrigin) {\n // --> Delete current origin to set the new\n this.selectedOrigin.classList.remove(this.config.selectedClass);\n const icon = this.selectedOrigin.lastChild;\n\n if (icon && icon.nodeName === 'SPAN') {\n newSelectedOrigin.appendChild(icon);\n }\n }\n // --> Set the new origin\n this.selectedOrigin = newSelectedOrigin;\n this.selectedOrigin.classList.add(this.config.selectedClass);\n this.value = this.selectedOrigin.attributes[this.config.originOption].value;\n\n // --> Try to set the new origin in session using an API\n executeAjax(this);\n\n return true;\n }\n return false;\n },\n bindEvents: function bindEvents() {\n this.onClickOrigin = this.onClickOrigin.bind(this);\n },\n addEventListener: function fn() {\n this.bindEvents();\n this.element.addEventListener('click', this.onClickOrigin);\n\n return this;\n },\n removeEventListener: function fn() {\n this.element.removeEventListener('click', this.onClickOrigin);\n\n return this;\n },\n initialize: function fn() {\n const selectedOrigin = this.element.querySelector(`.${this.config.selectedClass}`);\n\n if (!selectedOrigin) return this;\n\n const checkHasSelected = selectedOrigin.classList.contains(this.config.selectedClass);\n\n if (checkHasSelected) {\n this.selectedOrigin = selectedOrigin;\n this.value = selectedOrigin.dataset.code;\n }\n\n this.addEventListener();\n\n return this;\n }\n};\n","const base = {\n component: 'OriginList',\n init: true,\n originOption: 'data-code',\n selectedClass: 'selected'\n};\n\nconst configuration = {\n logitravel: {\n ...base,\n ...{\n endpoint: '/mybookings/origin/setorigin',\n parameterName: 'airportcode',\n verb: 'post'\n }\n }\n};\n\nmodule.exports = function fn(type = 'logitravel') {\n return configuration[type] || base;\n};\n","/* ==========================================================================\n ModalOrigins > Client > Prototype\n ========================================================================== */\n\n/* Prototype */\nconst prototype = {\n /* Add event listener */\n addEventListener: function addEventListener() {\n /* Origin List */\n this.origin.addEventListener();\n\n return this;\n },\n /* Remove event listener */\n removeEventListener: function removeEventListener() {\n /* Origin List */\n this.origin.removeEventListener();\n\n return this;\n }\n};\n\n/* Exports */\nmodule.exports = prototype;\n","/* ==========================================================================\n ModalOrigins > Client > Config\n ========================================================================== */\n\n/* Config */\nconst config = {\n type: {\n modal: 'modal-origins'\n },\n css: {\n modal: 'modal--origins'\n }\n};\n\n/* Exports */\nmodule.exports = () => config;\n","/* ==========================================================================\n HeaderMasterExpedient > Client\n ========================================================================== */\n\n/* Import modules */\nconst { elementExist } = require('@bluekiri/alexandria/helpers/domHelpers');\nconst prototype = require('./prototype');\nconst config = require('./config');\n\n/**\n * HeaderMasterExpedient component\n * @param {selector} String selector for the component in the client side.\n */\nmodule.exports = function HeaderMasterExpedient(\n selector = '[data-component=HeaderMasterExpedient]',\n configuration = {}\n) {\n if (elementExist(selector)) {\n /* Instance */\n const instance = Object.create(prototype);\n\n /* Element */\n instance.element = document.querySelector(selector);\n\n /* Config */\n instance.config = {\n ...config(),\n ...configuration,\n ...(function getConfig() {\n if (!instance.element.dataset.config) return '';\n\n const result = JSON.parse(instance.element.dataset.config);\n instance.element.dataset.config = '';\n\n return result;\n })()\n };\n\n /* Hooks */\n instance.hooks = {\n logout: instance.element.querySelector('[data-logout]')\n };\n\n /* Init */\n instance.init();\n\n /* Return */\n return instance;\n }\n};\n","/* ==========================================================================\n HeaderMasterExpedient > Prototype\n ========================================================================== */\n\n/* Modules */\nconst { Store } = require('@bluekiri/alexandria/helpers/state');\n\nconst { take } = require('rxjs/operators');\nconst { fromEvent, of } = require('rxjs');\nconst { actions, types } = require('./store/actions');\nconst { reducer } = require('./store/reducer');\n\nconst services = require('./services');\n\n/* Prototype */\nconst prototype = {\n /* Setup store */\n setupStore() {\n if (this.store) return this;\n\n this.store = new Store({\n headerMasterExpedient: reducer\n });\n\n return this;\n },\n /* Setup actions */\n setupActions() {\n if (this.actions) return this;\n\n this.actions = {\n destroy: () => {\n return this.store.dispatch(actions.destroy());\n },\n logout: () => {\n return this.store.dispatch(actions.logout());\n }\n };\n\n return this;\n },\n /* Setup reactions */\n setupReactions() {\n if (this.reactions) return this;\n\n this.reactions = {\n destroy: this.store.subscribe((state, action) => {\n if (action.type !== types.DESTROY) return;\n\n /* Unsubscribe */\n this.unsubscribe();\n [...Object.keys(this.reactions)].forEach(key => this.reactions[key].unsubscribe());\n\n /* Clean DOM */\n this.element.parentNode.removeChild(this.element);\n\n /* Clean references */\n [...Object.keys(this)].forEach(key => delete this[key]);\n }),\n logout: this.store.subscribe((state, action) => {\n if (action.type !== types.LOGOUT) return;\n\n services\n .logout(this.config.endpoints.logout)\n .pipe(take(1))\n .subscribe({\n next: response => {\n if (response.result) {\n this.actions.destroy();\n }\n },\n error: err => {\n return of({ error: true, message: err.message });\n }\n });\n })\n };\n\n return this;\n },\n /* Subscribe */\n subscribe() {\n if (this.subscriptions) this.unsubscribe();\n\n this.subscriptions = {\n logout: fromEvent(this.hooks.logout, 'click').subscribe(() => {\n this.actions.logout();\n })\n };\n\n return this;\n },\n /* Unsubscribe */\n unsubscribe() {\n if (!this.subscriptions) return this;\n\n [...Object.keys(this.subscriptions)].forEach(key => this.subscriptions[key].unsubscribe());\n\n return this;\n },\n /* Start */\n start() {\n if (!this.config.start) return this;\n\n return this;\n },\n /* Init */\n init() {\n if (!this.config.init) return this;\n\n /* Setup store */\n this.setupStore();\n\n /* Setup actions */\n this.setupActions();\n\n /* Setup reactions */\n this.setupReactions();\n\n /* Subscribe */\n this.subscribe();\n\n /* Start */\n this.start();\n\n return this;\n }\n};\n\n/* Exports */\nmodule.exports = prototype;\n","/* ==========================================================================\n HeaderMasterExpedient > Client > Store > Reducer\n ========================================================================== */\n\n/* Modules */\nconst { types } = require('./actions');\n\n/* Initial state */\nconst initialState = {};\n\n/* Reducer */\nfunction reducer(state = initialState, action) {\n switch (action.type) {\n case types.DESTROY:\n return state;\n case types.LOGOUT:\n return {\n ...state\n };\n default:\n return state;\n }\n}\n\n/* Exports */\nmodule.exports = {\n reducer\n};\n","/* ==========================================================================\n HeaderMasterExpedient > Client > Services\n ========================================================================== */\n\n/* Modules */\nconst { of } = require('rxjs');\nconst { catchError, switchMap } = require('rxjs/operators');\nconst { fromFetch } = require('rxjs/fetch');\n\n/**\n * Get destinations from a remote server\n * @param {string} endpoint\n * @param {object} params\n * @returns {JSON} data\n */\nfunction logout(endpoint = '') {\n /* Build url */\n\n return fromFetch(endpoint).pipe(\n switchMap(response => {\n if (response.ok) {\n return response.json();\n }\n return of({ error: true, message: `Error fetching data searcher ${response.statusText}` });\n }),\n catchError(err => {\n return of({ error: true, message: err.message });\n })\n );\n}\n\n/* Exports */\nmodule.exports = {\n logout\n};\n","/* ==========================================================================\n HeaderMasterExpedient > Client > Config\n ========================================================================== */\n\n/* Import modules */\n\n/* Config */\nconst config = {\n component: 'HeaderMasterExpedient',\n name: 'header-master-expedient',\n init: true,\n start: true\n};\n\nmodule.exports = () => config;\n","/* ==========================================================================\n Header > Client > Welcome\n ========================================================================== */\n\nconst $ = require('jquery');\nconst { getCookie } = require('./cookie');\n\nfunction initWelcome() {\n const modalNewUserCookie = getCookie('login_modal_new_user');\n\n if (modalNewUserCookie === '') {\n const $containerModalLogin = $('#loginModal');\n const literals = $('#loginModal').data('literals');\n const links = {\n login: {\n href: $containerModalLogin.find('.log-in__link').attr('href'),\n title: $containerModalLogin.find('.log-in__link').attr('title')\n },\n create: {\n href: $containerModalLogin.find('.footer-modal__link').attr('href'),\n title: $containerModalLogin.find('.footer-modal__link').attr('title')\n }\n };\n\n document.cookie = 'login_modal_new_user=1; expire=; path=/;';\n replaceData({ $containerModalLogin, literals, links });\n }\n}\nfunction replaceData({ $containerModalLogin, literals, links }) {\n if ($containerModalLogin) return;\n $containerModalLogin.find('.content__title').html(literals.loginModalNewUserTitle);\n $containerModalLogin.find('.content__description').html(literals.loginModalNewUserDescription);\n $containerModalLogin.find('.log-in .Button').html(literals.loginModalNewUserButtonText);\n $containerModalLogin.find('.footer-modal__text').html(`${literals.loginModalNewUserFooterText}  `);\n $containerModalLogin.find('.footer-modal__link').html(literals.loginModalButtonText);\n $containerModalLogin.find('.icon__content').html('');\n $containerModalLogin\n .find('.log-in__link')\n .attr('href', links.create.href)\n .attr('title', links.create.title);\n $containerModalLogin.find('.log-in__link').html(links.create.title);\n $containerModalLogin\n .find('.footer-modal__link')\n .attr('href', links.login.href)\n .attr('title', links.login.title);\n $containerModalLogin.find('.footer-modal__link').html(links.login.title);\n}\n\nmodule.exports = {\n initWelcome\n};\n","/* ==========================================================================\n Header > Client > Tooltip\n ========================================================================== */\n\nconst $ = require('jquery');\nconst tippy = require('tippy.js');\nconst { setCookie } = require('./cookie');\n\nconst tooltips = [\n ['.popover-phone', true, '', 'header', true, 'mouseenter'],\n ['#Header-popover-cert0', false, '#Header-cert0', 'header', 'true', 'mouseenter'],\n ['#Header-popover-cert1', false, '#Header-cert1', 'header', 'true', 'mouseenter'],\n ['#Header-popover-user', false, '#Header-user-logged', 'user', 'true', 'mouseenter'],\n ['#list-language', false, '#languageDropdown', 'languages', 'false', 'click'],\n ['#list-currency', false, '#currencyDropdown', 'currencies', 'false', 'click']\n];\n\nfunction initTooltips() {\n tooltips.forEach(element => {\n const tippySelector = element[0];\n const tippyTitle = element[1];\n const tippytemplateId = element[2];\n const tippyTheme = element[3];\n const htmlElementExists = element[1] === false && $(element[2]).length;\n const useTitle = element[1];\n const tippyArrow = element[4];\n const tippyTrigger = element[5];\n if (htmlElementExists || useTitle) {\n let tippyConfig = {};\n if (tippySelector === '#Header-popover-user') {\n tippyConfig = {\n delay: 0,\n arrow: tippyArrow,\n arrowType: 'sharp',\n duration: 0,\n animation: 'scale',\n placement: 'bottom',\n theme: `light base ${tippyTheme}`,\n allowTitleHTML: tippyTitle,\n maxWidth: '300px',\n interactive: true,\n trigger: tippyTrigger,\n html: tippytemplateId,\n onShown(instance) {\n const $buttonLogout = $(instance.popper).find('.js-logout');\n if ($buttonLogout.length) {\n $buttonLogout.on('click', e => {\n const urlLogout = $(e.currentTarget).data('urlLogout');\n const sessionCode = $(e.currentTarget).data('sessionCode');\n if (urlLogout && sessionCode) {\n $.ajax({\n complete: xhr => {\n if (xhr.status === 200) {\n if (window.googleyolo) {\n window.googleyolo\n .disableAutoSignIn()\n .then(\n () => {\n // Do nothing\n },\n () => {\n // Error, write cookie to disable onetap\n setCookie('ck_disable_onetap', 'true', 1 / 24);\n }\n )\n .finally(() => {\n window.parent.location.reload(true);\n });\n } else {\n // Just disable One Tap by cookie and reload page\n setCookie('ck_disable_onetap', 'true', 1 / 24);\n window.parent.location.reload(true);\n }\n }\n },\n crossDomain: true,\n data: {\n sessionCode\n },\n dataType: 'jsonp',\n url: urlLogout\n });\n }\n });\n }\n }\n };\n } else {\n tippyConfig = {\n delay: 0,\n arrow: tippyArrow,\n arrowType: 'sharp',\n duration: 0,\n animation: 'scale',\n placement: 'bottom',\n theme: `light base ${tippyTheme}`,\n allowTitleHTML: tippyTitle,\n maxWidth: '300px',\n interactive: true,\n trigger: tippyTrigger,\n html: tippytemplateId\n };\n }\n\n tippy(`.Header ${tippySelector}`, tippyConfig);\n }\n });\n}\n\nmodule.exports = {\n initTooltips\n};\n","const $ = require('jquery');\n\nconst ModalMsiClient = require('../../../modal-msi/client/js');\nconst ModalOriginsClient = require('../../../modal-origins/client/js');\nconst HeaderMasterExpedient = require('../../../header-master-expedient/client/js');\n\nconst { initWelcome } = require('./welcome');\nconst { initTooltips } = require('./tooltip');\nconst { getCookie, setCookie } = require('./cookie');\n\n// eslint-disable-next-line max-statements\n$(() => {\n // Welcome\n initWelcome();\n\n // Tooltips\n initTooltips();\n\n // Modal Origins\n ModalOriginsClient('.Header [data-component=\"Modal\"][data-type=\"modal-origins\"]', {\n modal: {\n triggers: [document.querySelector('.Header [data-modal-open=\"modal-origins\"]')]\n }\n });\n\n // Modal MSI\n ModalMsiClient('.Header [data-component=\"Modal\"][data-type=\"modal-msi\"]', {\n modal: {\n triggers: [...document.querySelectorAll('[data-modal-open=\"modal-msi\"]')]\n }\n });\n\n // Header Master Expedient\n HeaderMasterExpedient('[data-component=\"HeaderMasterExpedient\"]');\n\n // Login Modal\n const modalCookie = getCookie('login_modal_closed');\n const closeButton = $('.close-button');\n const loginModal = $('#loginModal');\n const warningCookie = 'warning_closed';\n\n closeButton.click(() => {\n document.cookie = 'login_modal_closed=1; expire=; path=/;';\n loginModal.css('display', 'none');\n });\n\n if (loginModal && modalCookie === '') {\n setTimeout(() => {\n loginModal.css('display', 'block');\n }, 6000);\n }\n\n /* Event to close top warning and cookies */\n checkWarning(warningCookie);\n $('.message-alert__content-close').on('click', () => {\n setCookie(warningCookie);\n $(`.message-alert`).addClass('message-alert__hidden');\n });\n\n // DROPDOWN LANGUAGE ITEM CLICK EVENT\n $('.options-list__item--language').on('click', () => {\n const elementLanguageDropdown = $('.dropdown--language .dropdown__item');\n if (elementLanguageDropdown) {\n elementLanguageDropdown.on('click', event => {\n const config = JSON.parse($('.dropdown--language').attr('data-config'));\n const languageSelected = event.currentTarget.dataset.language;\n\n if (config.language_url) {\n $.ajax({\n contentType: 'application/json; charset=utf-8',\n data: JSON.stringify({\n language: languageSelected\n }),\n dataType: 'json',\n success: () => {\n window.parent.location.reload();\n },\n type: 'POST',\n url: config.language_url\n });\n } else {\n console.warn(\"WARNING: Origin url hasn't been defined.\");\n }\n });\n }\n });\n\n // DROPDOWN CURRENCY ITEM CLICK EVENT\n $('.options-list__item--currency').on('click', () => {\n const elementCurrencyDropdown = $('.dropdown--currency .dropdown__item');\n if (elementCurrencyDropdown) {\n elementCurrencyDropdown.on('click', event => {\n const config = JSON.parse($('.dropdown--currency').attr('data-config'));\n const currencySelected = event.currentTarget.dataset.currency;\n\n if (config.currency_url) {\n $.ajax({\n contentType: 'application/json; charset=utf-8',\n data: JSON.stringify({\n currency: currencySelected\n }),\n dataType: 'json',\n success: () => {\n window.parent.location.reload();\n },\n type: 'POST',\n url: config.currency_url\n });\n } else {\n console.warn(\"WARNING: Origin url hasn't been defined.\");\n }\n });\n }\n });\n});\n\naddClassActive('.options-list__item--currency', '.dropdown--currency');\naddClassActive('.options-list__item--language', '.dropdown--language');\n\nfunction addClassActive(listItemClass, dropdownClass) {\n const listItem = $(listItemClass);\n const dropdown = $(dropdownClass);\n\n if (dropdown.hasClass('dropdown--language') || dropdown.hasClass('dropdown--currency')) {\n listItem.addClass('active');\n } else {\n listItem.removeClass('active');\n }\n}\n\nconst userAgent = navigator.userAgent.toLowerCase();\n// eslint-disable-next-line max-len\nconst isTablet = /(ipad|tablet|(android(?!.*mobile))|(windows(?!.*phone)(.*touch))|kindle|playbook|silk|(puffin(?!.*(IP|AP|WP))))/.test(\n userAgent\n);\n\nif (isTablet) {\n $('.Header .menu-tabs .menu-item.dropdown').on('click', e => {\n if ($(e.currentTarget).hasClass('js-menu-clicked')) {\n return true;\n }\n $('.Header .menu-tabs .menu-item.dropdown').removeClass('js-menu-clicked');\n $(e.currentTarget).addClass('js-menu-clicked');\n e.preventDefault();\n return false;\n });\n}\n\nfunction checkWarning(cookie) {\n if (getCookie(cookie) === '') {\n $(`.message-alert`).removeClass('message-alert__hidden');\n }\n}\n"],"sourceRoot":""}