{"version":3,"sources":["webpack:///./LifeDirect.Web/scripts/src/objects/siteheader.ts","webpack:///./LifeDirect.Web/scripts/src/objects/sitefooter.ts","webpack:///external \"jQuery\"","webpack:///./LifeDirect.Web/scripts/src/objects/mobilenav.ts","webpack:///./LifeDirect.Web/scripts/src/pages/landing.ts","webpack:///./LifeDirect.Web/scripts/src/objects/lightwindowhelper.ts"],"names":["contactBtn","document","querySelector","addEventListener","event","preventDefault","open","name","hideAccountMenu","e","forced","accountMenuEl","$","first","contains","target","off","hide","on","show","footerSecurityBtn","footerLegalBtn","module","exports","jQuery","mobilenav","menu","menubtn","html","body","pagewrapper","menubtnbreakpoint","menuminwidth","menumaxwidth","menuwidth","sneakpeek","pagex","position","left","startx","opening","allowPageScroll","scrollTopOnShow","pushPage","showOnResizeToDesk","hideOnResizeToDesk","showOnResizeToMobile","hideOnResizeToMobile","hideOnClickOutside","addRightMargin","startShowingCallback","startHidingCallback","init","opts","undefined","length","sizemenu","togglesubmenu","window","resize","displaynav","mobileContactBtn","requestCallBtn","evt","CustomEvent","dispatchEvent","addClass","css","width","animateProperties","animate","completeCalled","scrollTop","duration","complete","removeClass","windowwidth","fillwidth","min","max","submenu","this","closest","submenulist","find","hasClass","stop","slideUp","slideDown","landing","reviewData","objc","date","attachLightwindowToClick","elSelector","lightwindowName","lightwindowUrl","els","querySelectorAll","i","filePath","lightWindowManager","validLightWindows","push","click","$btnText","months","Array","getDate","getMonth","getFullYear","formatDate","Date","ajax","url","type","data","dataType","contentType","async","success","res","textStatus","xhr","value","d","averageReview","parseFloat","toString","toFixed","numberOfReviews","remove","numstars","stars","startype","averagereview","substring","ratingstars","el","createElement","ratingValue","reviewCount","message","JSON","parse","text","stringify","appendChild","addStructuredData","error","status","console","log","LightWindow","parentLightWindow","preloaderMarkup","lwContainerTemplate","alertTemplate","title","footer","alertwindow","parentElement","cover","childLightWindow","openedLightWindows","currentLightWindow","coverNumber","fadeLength","preloaderElement","cacheEl","shouldCache","lastFocus","activeElement","scrollbarWidth","isFixedElementFixApplied","prototype","that","append","Image","src","each","verticallyCenter","which","lw","getTopLightWindow","closebtn","setTimeout","lwToSubmit","getTopCover","$lwel","lwenterkey","openEl","args","currentTarget","attr","options","context","defaults","isUndismissable","addChildLightWindow","display","close","extend","lightWindowId","lightWindowUrl","urlOverride","initfunction","callbackonclose","showPopUp","callback","fetchLightWindow","beforeSend","showCover","trackPopUpEventInGTM","showAlert","$lwContainer","dataLayer","LightWindowUrl","fixedElementFix","isApplyFix","index","element","originalMarginLeft","lwtype","$body","oldBodyWidth","bodyScrollTop","prepend","lastMouseDownEl","myCover","fadeIn","content","lwclassnames","$cover","detach","className","replace","val","trigger","scroll","$lwFocusEl","eq","innerHeight","offsetTop","is","tabIndex","focus","unbind","topPosition","height","outerHeight","topcover","toplw","closeTopLightWindow","shouldremove","onComplete","hideLightWindow","fadeOut","bodyTop","top","coverstoremove","curlw","$childlw","hideChildren","hideChildrenItem","hideChildrenLightWindows","isValidLightWindow","inArray","addValidLightWindows","arr","item","classnames","alertlw","getTime"],"mappings":"8FAAA,8BAEIA,EAAaC,SAASC,cAAc,0BAEpCF,GACAA,EAAWG,iBAAiB,SAAS,SAAUC,GAC3CA,EAAMC,iBACN,IAAmBC,KAAK,CAAEC,KAAM,eAIxC,IAAIC,EAAkB,SAAlBA,EAA4BC,EAAGC,GAC/B,IAAIC,EAAgBC,EAAE,mBAAmBC,UAC1B,IAAXH,IAAqBE,EAAEE,SAASH,EAAc,GAAIF,EAAEM,SAAWN,EAAEM,QAAUJ,EAAc,WACxE,IAANF,GACPA,EAAEJ,iBAENO,EAAE,QAAQI,IAAI,QAASR,GACvBG,EAAcM,SAWtBL,EAAE,QAAQM,GAAG,QAAS,4BAA4B,SAAUT,GAAKD,EAAgBC,GAAG,MACpFG,EAAE,QAAQM,GAAG,QAAS,6BARA,SAAUT,GAC5BA,EAAEJ,iBACkBO,EAAE,mBAAmBC,QAC3BM,OACdP,EAAE,QAAQM,GAAG,QAASV,O,mDC1B1B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C,CAuxBGzF,K","file":"landing.f146cbf4d66b3733ce8f.js","sourcesContent":["import { lightWindowManager } from \"./lightwindowhelper\";\n\nvar contactBtn = document.querySelector('.js-siteheader-contact');\n\nif (contactBtn) {\n contactBtn.addEventListener('click', function (event) {\n event.preventDefault();\n lightWindowManager.open({ name: 'contact' });\n });\n}\n\nvar hideAccountMenu = function (e, forced) {\n var accountMenuEl = $('.js-accountmenu').first();\n if (forced === true || (!$.contains(accountMenuEl[0], e.target) && e.target != accountMenuEl[0])) {\n if (typeof e !== \"undefined\") {\n e.preventDefault();\n }\n $('body').off('click', hideAccountMenu);\n accountMenuEl.hide();\n }\n};\n\nvar showAccountMenu = function (e) {\n e.preventDefault();\n var accountMenuEl = $('.js-accountmenu').first();\n accountMenuEl.show();\n $('body').on('click', hideAccountMenu);\n};\n\n$('body').on('click', '.js-accountmenu-closebtn', function (e) { hideAccountMenu(e, true) });\n$('body').on('click', '.js-siteheader-accountbtn', showAccountMenu);\n","import { lightWindowManager } from \"./lightwindowhelper\";\n\nvar footerContactBtn = document.querySelector('.js-footer-contact');\nif (footerContactBtn) {\n\tdocument.querySelector('.js-footer-contact').addEventListener('click', function (event) {\n\t\tevent.preventDefault();\n\t\tlightWindowManager.open({ name: 'contact' });\n\t});\n}\nvar footerSecurityBtn = document.querySelector('.js-footer-securityandprivacy');\nif (footerSecurityBtn) {\n\tfooterSecurityBtn.addEventListener('click', function (event) {\n\t\tevent.preventDefault();\n\t\tlightWindowManager.open({ name: 'security' });\n\t});\n}\nvar footerLegalBtn = document.querySelector('.js-footer-legalanddisclaimer');\nif (footerLegalBtn) {\n\tfooterLegalBtn.addEventListener('click', function (event) {\n\t\tevent.preventDefault();\n\t\tlightWindowManager.open({ name: 'legal' });\n\t});\n}","module.exports = jQuery;","import { lightWindowManager } from \"./lightwindowhelper\";\n\ninterface IOptions {\n open?: boolean;\n pushPage?: boolean;\n scrollTopOnShow?: boolean;\n allowPageScroll?: boolean;\n showOnResizeToDesk?: boolean;\n hideOnResizeToDesk?: boolean;\n showOnResizeToMobile?: boolean;\n hideOnResizeToMobile?: boolean;\n hideOnClickOutside?: boolean;\n addRightMargin?: boolean;\n}\n\ninterface IMobileNav extends IOptions {\n // options\n menu: JQuery;\n menubtn: JQuery;\n html: JQuery;\n body: JQuery;\n pagewrapper: JQuery;\n menubtnbreakpoint: number;\n menuminwidth: number;\n menumaxwidth: number;\n menuwidth: number;\n sneakpeek: number;\n\n pagex: number;\n startx: null;\n opening: boolean;\n\n // functions\n init: (opts?: IOptions) => void;\n displaynav: () => void;\n show: () => void;\n hide: () => void;\n resize: () => void;\n sizemenu: () => void;\n togglesubmenu: () => void;\n\n // Optional functions\n startShowingCallback?: () => void;\n startHidingCallback?: () => void;\n}\n\nexport let mobilenav: IMobileNav;\n\ndeclare global {\n // eslint-disable-next-line\n interface Window {\n mobilenav: IMobileNav;\n }\n}\n\n(function () {\n mobilenav = {\n menu: $(\".js-mobilenav\"),\n menubtn: $(\".js-siteheader-menubtn\"),\n html: $(\"html\"),\n body: $(\"body\"),\n pagewrapper: $(\".js-pagewrapper\"),\n menubtnbreakpoint: 768,\n menuminwidth: 240,\n menumaxwidth: 360,\n menuwidth: 240,\n sneakpeek: 80,\n open: false,\n pagex: $(\".js-pagewrapper\").position().left,\n startx: null,\n opening: false,\n allowPageScroll: false,\n scrollTopOnShow: true,\n pushPage: true,\n showOnResizeToDesk: false,\n hideOnResizeToDesk: true,\n showOnResizeToMobile: false,\n hideOnResizeToMobile: false,\n hideOnClickOutside: true,\n addRightMargin: false,\n startShowingCallback: null,\n startHidingCallback: null,\n\n init: function (opts) {\n //use options\n if (opts) {\n if (opts.open !== undefined) {\n mobilenav.open = opts.open;\n }\n if (opts.pushPage !== undefined) {\n mobilenav.pushPage = opts.pushPage;\n }\n if (opts.allowPageScroll !== undefined) {\n mobilenav.allowPageScroll = opts.allowPageScroll;\n }\n if (opts.scrollTopOnShow !== undefined) {\n mobilenav.scrollTopOnShow = opts.scrollTopOnShow;\n }\n if (opts.showOnResizeToDesk !== undefined) {\n mobilenav.showOnResizeToDesk = opts.showOnResizeToDesk;\n }\n if (opts.hideOnResizeToDesk !== undefined) {\n mobilenav.hideOnResizeToDesk = opts.hideOnResizeToDesk;\n }\n if (opts.showOnResizeToDesk !== undefined) {\n mobilenav.showOnResizeToDesk = opts.showOnResizeToDesk;\n }\n if (opts.hideOnResizeToMobile !== undefined) {\n mobilenav.hideOnResizeToMobile = opts.hideOnResizeToMobile;\n }\n if (opts.hideOnClickOutside !== undefined) {\n mobilenav.hideOnClickOutside = opts.hideOnClickOutside;\n }\n if (opts.addRightMargin !== undefined) {\n mobilenav.addRightMargin = opts.addRightMargin;\n }\n }\n\n if (mobilenav.menu.length > 0) {\n //only run if mobilenav exists on the page\n mobilenav.sizemenu();\n mobilenav.menubtn.on(\"click\", mobilenav.show);\n mobilenav.menu.on(\n \"click\",\n \".js-mobilenav-submenuheading\",\n mobilenav.togglesubmenu\n );\n $(window).on(\"debouncedresize\", mobilenav.resize);\n }\n\n if (mobilenav.open) {\n mobilenav.displaynav();\n }\n\n const mobileContactBtn = document.querySelector(\".js-mobilenav-contact\");\n if (mobileContactBtn) {\n mobileContactBtn.addEventListener(\"click\", function (e) {\n e.preventDefault();\n lightWindowManager.open({ name: \"contact\" });\n });\n }\n\n const requestCallBtn = document.querySelector(\".js-mobilenav-requestcall\");\n if (requestCallBtn) {\n requestCallBtn.addEventListener(\"click\", function (e) {\n e.preventDefault();\n lightWindowManager.open({ name: \"requestcallback\" });\n });\n }\n\n const evt = new CustomEvent(\"mobilenavloaded\");\n window.dispatchEvent(evt);\n },\n displaynav: function () {\n mobilenav.html.addClass(\"nav-is-open\");\n mobilenav.open = true;\n if (mobilenav.allowPageScroll === false) {\n mobilenav.html.addClass(\"is-mobilenavscrollonly\");\n }\n mobilenav.menu.css({ width: mobilenav.menuwidth });\n const animateProperties = {\n left: mobilenav.menuwidth\n };\n if (mobilenav.pushPage === true) {\n if (mobilenav.addRightMargin === true) {\n animateProperties[\"margin-right\"] = mobilenav.menuwidth;\n }\n mobilenav.pagewrapper.animate(animateProperties, 300, function () {\n mobilenav.menubtn.off(\"click\").on(\"click\", mobilenav.hide);\n if (mobilenav.hideOnClickOutside === true) {\n mobilenav.pagewrapper\n .off(\"click.mobilenavdisplay\")\n .on(\"click.mobilenavdisplay\", mobilenav.hide);\n }\n });\n } else {\n mobilenav.menubtn.off(\"click\").on(\"click\", mobilenav.hide);\n }\n },\n show: function () {\n if (typeof mobilenav.startShowingCallback === \"function\") {\n mobilenav.startShowingCallback();\n }\n\n let completeCalled = false;\n mobilenav.menubtn.off(\"click\");\n if (mobilenav.scrollTopOnShow === true) {\n if ($(\"html\").scrollTop() === 0 && $(\"body\").scrollTop() === 0) {\n mobilenav.displaynav();\n } else {\n $(\"html, body\").animate(\n { scrollTop: \"0px\" },\n {\n duration: 300,\n complete: function () {\n if (!completeCalled) {\n completeCalled = true;\n mobilenav.displaynav();\n }\n }\n }\n );\n }\n } else {\n mobilenav.displaynav();\n }\n },\n hide: function () {\n if (typeof mobilenav.startHidingCallback === \"function\") {\n mobilenav.startHidingCallback();\n }\n\n const animateProperties = {\n left: \"0px\"\n };\n mobilenav.menubtn.off(\"click\", mobilenav.hide);\n mobilenav.pagewrapper.off(\"click.mobilenavdisplay\");\n if (mobilenav.addRightMargin === true) {\n animateProperties[\"margin-right\"] = \"0px\";\n }\n mobilenav.pagewrapper.animate(animateProperties, 300, function () {\n mobilenav.html.removeClass(\"nav-is-open\");\n mobilenav.html.removeClass(\"is-openingmobilenav\");\n mobilenav.html.removeClass(\"is-mobilenavscrollonly\");\n mobilenav.open = false;\n mobilenav.opening = false;\n mobilenav.menubtn.on(\"click\", mobilenav.show);\n });\n },\n resize: function () {\n const smallwindow = $(window).width() < mobilenav.menubtnbreakpoint;\n if (smallwindow) {\n mobilenav.sizemenu();\n if (mobilenav.showOnResizeToMobile === true) {\n mobilenav.show();\n } else if (mobilenav.hideOnResizeToMobile === true) {\n mobilenav.hide();\n }\n } else {\n if (mobilenav.showOnResizeToDesk === true) {\n mobilenav.show();\n } else if (mobilenav.hideOnResizeToDesk === true) {\n mobilenav.hide();\n }\n }\n },\n sizemenu: function () {\n const windowwidth = $(window).width();\n const fillwidth = windowwidth - mobilenav.sneakpeek;\n const min = mobilenav.menuminwidth;\n const max = mobilenav.menumaxwidth;\n\n if (windowwidth > min + mobilenav.sneakpeek) {\n if (fillwidth < max) {\n mobilenav.menuwidth = fillwidth;\n } else {\n mobilenav.menuwidth = max;\n }\n } else {\n mobilenav.menuwidth = min;\n }\n if (mobilenav.open) {\n mobilenav.menu.css({ width: mobilenav.menuwidth });\n if (mobilenav.pushPage === true) {\n mobilenav.pagewrapper.addClass('nav-is-open');\n if (mobilenav.addRightMargin === true) {\n mobilenav.pagewrapper.css({\n \"margin-right\": mobilenav.menuwidth\n });\n }\n }\n }\n },\n togglesubmenu: function () {\n const submenu = $(this).closest(\".js-mobilenav-submenu\");\n const submenulist = submenu.find(\".js-mobilenav-submenu-list\");\n if (!submenu.hasClass(\"is-open\")) {\n submenulist.stop();\n submenulist.slideDown(100);\n submenu.addClass(\"is-open\");\n } else {\n submenulist.stop();\n submenulist.slideUp(100);\n submenu.removeClass(\"is-open\");\n }\n }\n };\n window.mobilenav = mobilenav;\n})();\n","import { lightWindowManager } from \"../objects/lightwindowhelper\";\nimport * as siteHeader from \"../objects/siteheader\";\nimport * as siteFooter from \"../objects/sitefooter\";\nimport * as MobileNav from \"../objects/mobilenav\";\n\nexport var landing = function () {\n // legacy js files need to be explicitly referenced\n // otherwise webpack excludes them\n const mn = MobileNav;\n const sh = siteHeader;\n const sf = siteFooter;\n\n window.lightWindowManager = lightWindowManager;\n\n lightWindowManager.validLightWindows.push(\n 'reviews',\n 'myldtour',\n 'contact',\n 'cashback',\n 'holidaypack'\n );\n\n function attachLightwindowToClick(elSelector: string, lightwindowName: string, lightwindowUrl: string) {\n var els = document.querySelectorAll(elSelector);\n for (let i = 0; i < els.length; i++) {\n els[i].addEventListener('click', function (event) {\n event.preventDefault();\n lightWindowManager.open({ name: lightwindowName, filePath: lightwindowUrl });\n });\n }\n };\n\n attachLightwindowToClick('.js-show-reviews', 'reviews', '/lightwindow/reviews.aspx');\n attachLightwindowToClick('.js-reasonstouseld-myld-tour', 'myldtour', '/lightwindow/myldtour.aspx');\n attachLightwindowToClick('.js-landingcontactsection-show-contact', 'contact', '/lightwindow/contact.aspx');\n attachLightwindowToClick('.js-cashback', 'cashback', '/page_fragments/lightwindow_cashback.aspx');\n attachLightwindowToClick('.js-promotion', 'promotion', '/page_fragments/lightwindow_promotion.aspx?key=FreePTWillPopup');\n attachLightwindowToClick(\".js-nib-health-reward\", 'promotion', '/page_fragments/lightwindow_promotion.aspx?key=NibHealthReward');\n\n $('.js-reasonstouseld2-morebenefitsbtn').click(function () {\n var $btnText = $('.js-reasonstouseld2-morebenefitsbtn-text');\n if ($btnText.html() == 'More benefits') {\n $btnText.html('Fewer benefits');\n $('.js-reasonstouseld2-listitem').css({ 'display': 'inline-block' });\n } else {\n $btnText.html('More benefits');\n $('.js-reasonstouseld2-listitem').css({ 'display': 'none' });\n }\n });\n\n\n (function ratingdata() {\n var reviewData: any = {};\n var objc: any = {};\n var date = formatDate(new Date());\n $.ajax({\n url: \"/service.aspx/CustomerRating_OverallCB\",\n type: \"POST\",\n data: \"\",\n dataType: \"json\",\n contentType: \"application/json;charset=utf-8\",\n async: true,\n success: function (res, textStatus, xhr) {\n objc = res.d;\n reviewData.averageReview = convertFloatHelper(objc[0]);\n reviewData.numberOfReviews = objc[1];\n $('.js-customerfeedback-overallrating-loading').remove();\n $('.js-customerfeedback-overallrating-rating').html('' + reviewData.averageReview + '/5');\n $('.js-customerfeedback-overallrating-date').html(date);\n ratingstars(5);\n addStructuredData(reviewData);\n },\n error: function (xhr, status, e) {\n console.log('There was an error getting the customer rating data.');\n }\n\t\t});\n\n function addStructuredData(reviewData) {\n var el = document.createElement('script');\n el.type = 'application/ld+json';\n var ratingValue = (reviewData.averageReview != null) ? reviewData.averageReview : 4.6;\n var reviewCount = (reviewData.numberOfReviews != null) ? reviewData.numberOfReviews : 9000;\n var message = {\n \"@context\": \"http://schema.org\",\n \"@type\": \"Organization\",\n \"review\": [\n {\n \"@type\": \"Review\",\n \"reviewRating\": {\n \"@type\": \"Rating\",\n \"ratingValue\": \"5\"\n },\n \"author\": {\n \"@type\": \"Person\",\n \"name\": \"Dion Ahern\"\n },\n \"reviewBody\": \"Awesome - made the process so much easier.\"\n },\n {\n \"@type\": \"Review\",\n \"reviewRating\": {\n \"@type\": \"Rating\",\n \"ratingValue\": \"5\"\n },\n \"author\": {\n \"@type\": \"Person\",\n \"name\": \"David Page\"\n },\n \"reviewBody\": \"Fantastic. So easy, so immediate, so responsive.Thank you.\"\n },\n {\n \"@type\": \"Review\",\n \"reviewRating\": {\n \"@type\": \"Rating\",\n \"ratingValue\": \"5\"\n },\n \"author\": {\n \"@type\": \"Person\",\n \"name\": \"Erica Willoughby\"\n },\n \"reviewBody\": \"Easy to use and very quick to respond.\"\n },\n {\n \"@type\": \"Review\",\n \"reviewRating\": {\n \"@type\": \"Rating\",\n \"ratingValue\": \"5\"\n },\n \"author\": {\n \"@type\": \"Person\",\n \"name\": \"Caryn Peden\"\n },\n \"reviewBody\": \"Very friendly service. Timely updates. Thanks so much.\"\n }\n ],\n \"aggregateRating\": {\n \"@type\": \"AggregateRating\",\n \"reviewCount\": JSON.parse(reviewCount),\n \"ratingValue\": JSON.parse(ratingValue)\n }\n };\n\n el.text = JSON.stringify(message);\n document.querySelector('body').appendChild(el);\n }\n\n function ratingstars(numstars) {\n var stars = '',\n startype = '',\n averagereview = reviewData.averageReview;\n for (let i = 0; i < numstars; i++) {\n startype = averagereview - (i + 1) > 0 ? 'icon-star--full' : 'icon-star--' + averagereview.substring(2);\n stars += '';\n if (i === numstars - 1) {\n $('.js-customerfeedback-overallrating-stars').html(stars);\n }\n }\n }\n /*\n *\tReturns a date in d-MMM-yyyy format\n */\n function formatDate(date) {\n var months = new Array(\"Jan\", \"Feb\", \"Mar\", \"Apr\", \"May\", \"Jun\", \"Jul\", \"Aug\", \"Sept\", \"Oct\", \"Nov\", \"Dec\");\n return date.getDate() + ' ' + months[date.getMonth()] + ' ' + date.getFullYear();\n }\n function convertFloatHelper(value) {\n return parseFloat(value.toString()).toFixed(1);\n }\n }());\n\n window.mobilenav && window.mobilenav.init();\n};\n\nlanding();","interface ILightWindowOptions {\n data?: string;\n name?: string;\n context?: string | any;\n shouldCache?: boolean;\n isUndismissable?: boolean;\n childLightWindow?: any;\n filePath?: string;\n initfunction?: () => void;\n callbackonclose?: () => void;\n callback?: () => void;\n}\n\ntype ILightWindow = ((\n this: ILightWindowState,\n parentLightWindow?: ILightWindow\n) => void) &\n ILightWindowState;\n\ninterface ILightWindowState {\n validLightWindows?: any;\n preloaderMarkup?: string;\n lwContainerTemplate?: string;\n alertTemplate?: (message: string, title: string, footer: string) => string;\n parentLightWindow?: ILightWindow;\n parentElement?: any;\n cover?: any;\n childLightWindow?: ILightWindow;\n openedLightWindows?: string[];\n currentLightWindow?: any;\n coverNumber?: number;\n fadeLength?: number;\n preloaderElement?: any;\n cacheEl?: any;\n shouldCache?: boolean;\n lastFocus?: Element;\n scrollbarWidth?: number;\n isFixedElementFixApplied?: boolean;\n /**\n * These functions are called, but not sure where they're defined\n */\n\n hasClass?: (className: string) => boolean;\n getTopCover?: () => any;\n find?: (className: string) => any;\n\n // prototypes\n init?: () => void;\n open?: (options: ILightWindowOptions) => void;\n openEl?: (e: any) => void;\n display?: (name: any, args: ILightWindowOptions) => void;\n close?: (name, shouldremove?: boolean, onComplete?: () => void) => void;\n getTopLightWindow?: () => ILightWindow;\n showAlert?: (args: {}) => void;\n verticallyCenter?: (e: any) => void;\n}\n\ndeclare global {\n interface Window {\n dataLayer: any;\n lightWindowManager: ILightWindow;\n }\n\n interface TElement {\n childLightWindow?: ILightWindow;\n }\n}\n\nexport var lightWindowManager: ILightWindow;\n\n(function ($: JQueryStatic) {\n const LightWindow: ILightWindow = function LightWindow(\n parentLightWindow?: ILightWindow\n ): void {\n this.validLightWindows = parentLightWindow\n ? parentLightWindow.validLightWindows\n : [\"contact\", \"security\", \"legal\", \"tvad\"];\n this.preloaderMarkup =\n '
';\n this.lwContainerTemplate =\n '
';\n this.alertTemplate = function (message, title, footer) {\n let alertwindow = \"\";\n title = title || \"\";\n const hastitle =\n typeof title !== \"undefined\" && title.length > 0 ? \"\" : \" is-hidden\";\n footer =\n footer ||\n '
';\n alertwindow +=\n '

' +\n title +\n \"

\";\n alertwindow +=\n '
' + message + \"
\";\n alertwindow += footer;\n return alertwindow;\n };\n this.parentLightWindow = parentLightWindow;\n this.parentElement = parentLightWindow ? parentLightWindow.cover : $(\"body\");\n this.cover = undefined;\n this.childLightWindow = undefined;\n this.openedLightWindows = [];\n this.currentLightWindow = undefined;\n this.coverNumber = parentLightWindow ? parentLightWindow.coverNumber + 1 : 0;\n this.fadeLength = 150;\n this.preloaderElement = undefined;\n this.cacheEl = undefined;\n this.shouldCache = undefined;\n this.lastFocus = document.activeElement;\n this.scrollbarWidth = 0;\n this.isFixedElementFixApplied = false;\n };\n\n LightWindow.prototype.init = function (): void {\n const that = this;\n\n if (!that.parentLightWindow && $(\".js-lightwindowcache\").length === 0) {\n $(\"body\").append('
');\n }\n that.cacheEl = $(\".js-lightwindowcache\");\n\n //preload error icon incase of network issues\n new Image().src = \"/images/svg/icons/icon-alert-error.svg?v=1\";\n\n // window resize\n $(window).resize(function () {\n $(\".lwindow:visible\").each(function () {\n that.verticallyCenter($(this));\n });\n });\n\n // lightwindow keyboard functionality\n $(document).on(\"keydown\", function (event) {\n const e = event;\n switch (e.which) {\n case 27: // esc\n //trigger close window\n if (lightWindowManager.currentLightWindow) {\n // only close the highest lightwindow\n const lw = lightWindowManager.getTopLightWindow();\n const closebtn = $(lw)\n .find(\".js-lightwindow-close:visible\")\n .first();\n if (closebtn.length > 0) {\n closebtn.addClass(\"is-active\");\n closebtn.click();\n setTimeout(function () {\n //remove the class from the clicked element\n closebtn.removeClass(\"is-active\");\n }, 150);\n }\n }\n break;\n\n case 13: // enterkey, trigger click on js-lightwindow-enterkey (useful to dismiss alerts)\n var lwToSubmit = lightWindowManager.getTopCover();\n if (typeof lwToSubmit !== \"undefined\") {\n const $lwel = lightWindowManager.getTopLightWindow();\n if ($lwel && !$lwel.hasClass(\"is-lwtransitioning\")) {\n const lwenterkey = $lwel.find(\".js-lightwindow-enterkey\");\n //check what element has focus, don't want to trigger click if we have tabbed to an item in the lightwindow\n if (\n $lwel[0] === document.activeElement ||\n lwToSubmit.cover === document.activeElement ||\n lwenterkey[0] === document.activeElement ||\n document.body === document.activeElement\n ) {\n if (lwenterkey.length > 0) {\n //add class to show what element was clicked\n lwenterkey.addClass(\"is-active\");\n lwenterkey.click();\n setTimeout(function () {\n //remove the class from the clicked element\n lwenterkey.removeClass(\"is-active\");\n }, 150);\n }\n }\n }\n }\n break;\n\n default:\n return; // exit this handler for other keys\n }\n });\n\n //generic element click lightwindow open event listener\n $(\"body\").on(\"click\", \".js-open-lightwindow\", function (e) {\n lightWindowManager.openEl(e);\n });\n };\n\n LightWindow.prototype.openEl = function (e): void {\n /* open a lightwindow from an element click */\n //convenience method, this should only be used for GET lightwindows not POST\n let args: any = {},\n name,\n filePath,\n shouldCache;\n name = $(e.currentTarget).attr(\"data-lw-name\");\n filePath = $(e.currentTarget).attr(\"data-lw-path\"); //if necessary params should be in query string\n shouldCache = $(e.currentTarget).attr(\"data-lw-domcache\"); //should the window persist in the dom\n\n if (typeof name !== \"undefined\") {\n args.name = name;\n }\n if (typeof filePath !== \"undefined\") {\n args.filePath = filePath;\n }\n if (typeof shouldCache !== \"undefined\") {\n if (shouldCache === \"false\") {\n args.shouldCache = false;\n } else if (shouldCache === \"true\") {\n args.shouldCache = true;\n }\n }\n\n lightWindowManager.open(args);\n };\n\n LightWindow.prototype.open = function (options: ILightWindowOptions) {\n const that = this;\n const currentLw = that;\n that.lastFocus = document.activeElement;\n\n const defaults: ILightWindowOptions = {\n name: undefined,\n context: \"top\",\n shouldCache: true,\n isUndismissable: false\n };\n\n let context;\n\n // set options to defaults extended with options\n options = $.extend({}, defaults, options);\n\n // set the context\n context = options.context;\n\n function addChildLightWindow() {\n if (typeof lightWindowManager.currentLightWindow === \"undefined\") {\n // display lightwindow\n context.display(options.name, options);\n } else {\n if (context.childLightWindow) {\n // close all children then add lightwindow\n context.childLightWindow.close(\n context.childLightWindow.currentLightWindow,\n null,\n function () {\n // create new lightwindow in the given context\n context.childLightWindow = new LightWindow(context);\n context.childLightWindow.display(options.name, options);\n }\n );\n } else {\n // create new lightwindow in the given context\n context.childLightWindow = new LightWindow(context);\n context.childLightWindow.display(options.name, options);\n }\n }\n }\n\n if (options.context === that) {\n if (typeof that.currentLightWindow === \"undefined\") {\n // display lightwindow\n context.display(options.name, options);\n } else {\n // close current and all children then display lightwindow\n context.close(context.currentLightWindow, null, function () {\n context.display(options.name, options);\n });\n }\n } else if (options.context === \"top\") {\n context = lightWindowManager.getTopCover();\n addChildLightWindow();\n } else if (options.context === \"asChild\") {\n context = currentLw;\n addChildLightWindow();\n }\n };\n\n LightWindow.prototype.display = function (name, args: ILightWindowOptions): void {\n const that = this;\n args = args || {};\n args.data = args.data || \"\";\n\n args.filePath = args.filePath || \"/lightwindow/\" + name + \".aspx\";\n\n const lightWindowId = \"#\" + this.lightWindowId(name);\n const lightWindowUrl = that.urlOverride(name) || args.filePath;\n //lightWindowUrl += (lightWindowUrl.indexOf('?') > 0 ? '&' : '?') + 'isPopup=1';\n that.currentLightWindow = name;\n that.lastFocus = document.activeElement;\n\n this.shouldCache =\n typeof args.shouldCache !== \"undefined\" ? args.shouldCache : true; //important we set this everytime, so we don't inherit a previous lightwindows property\n this.initfunction = args.initfunction ? args.initfunction : undefined; //important we set this everytime, whether it's a function or undefined, so we don't inherit a previous alerts function\n this.callbackonclose = args.callbackonclose ? args.callbackonclose : undefined; //important we set this everytime, whether it's a function or undefined, so we don't inherit a previous alerts function\n\n const $lwContainer = $(\"#\" + this.lightWindowId(name));\n if ($lwContainer[0]) {\n that.showPopUp(name);\n if (typeof args.callback === \"function\") {\n args.callback();\n }\n } else {\n var fetchLightWindow = function () {\n $.ajax({\n url: lightWindowUrl,\n type: \"POST\",\n data: args.data,\n dataType: \"html\",\n contentType: \"application/x-www-form-urlencoded\",\n beforeSend: function (xhr) {\n that.showCover(undefined, undefined, args.isUndismissable);\n that.preloaderElement.show();\n },\n success: function (res, textStatus, xhr) {\n if (that.cover) {\n //check the user hasn't already closed the cover\n that.preloaderElement.hide();\n that.trackPopUpEventInGTM(lightWindowUrl);\n that.showPopUp(name, res);\n that.openedLightWindows.push(name);\n if (typeof args.callback === \"function\") {\n args.callback();\n }\n }\n },\n error: function (xhr, status, e) {\n if (that.cover) {\n //check the user hasn't already closed the cover\n that.showAlert({\n message:\n \"Sorry, there was an error loading the requested content.\",\n title: undefined,\n callbackonclose: undefined,\n footer:\n '',\n initfunction: function ($lwContainer) {\n $lwContainer\n .find(\".js-alert-cancel\")\n .on(\"click\", function () {\n that.close(name);\n });\n $lwContainer\n .find(\".js-alert-retry\")\n .on(\"click\", function () {\n setTimeout(fetchLightWindow, 300);\n });\n }\n });\n }\n }\n });\n };\n fetchLightWindow();\n }\n };\n\n LightWindow.prototype.trackPopUpEventInGTM = function (lightWindowUrl: string) {\n window.dataLayer = window.dataLayer || [];\n window.dataLayer.push({ LightWindowUrl: lightWindowUrl });\n window.dataLayer.push({ event: \"LightWindowOpenNew\" });\n };\n\n LightWindow.prototype.fixedElementFix = function (isApplyFix: boolean): void {\n if (\n isApplyFix === true &&\n lightWindowManager.isFixedElementFixApplied === false\n ) {\n $(\".js-fixed--marginleft\").each(function (index, element) {\n const originalMarginLeft = parseFloat($(element).css(\"margin-left\"));\n $(element).css(\n \"margin-left\",\n originalMarginLeft - lightWindowManager.scrollbarWidth / 2 + \"px\"\n );\n });\n $(\".js-fixed--width100\").each(function (index, element) {\n $(element).css(\n \"width\",\n \"calc(100% - \" + lightWindowManager.scrollbarWidth + \"px\"\n );\n });\n lightWindowManager.isFixedElementFixApplied = true;\n } else if (\n isApplyFix === false &&\n lightWindowManager.isFixedElementFixApplied === true\n ) {\n $(\".js-fixed--marginleft\").each(function (index, element) {\n const originalMarginLeft = parseFloat($(element).css(\"margin-left\"));\n $(element).css(\n \"margin-left\",\n originalMarginLeft + lightWindowManager.scrollbarWidth / 2 + \"px\"\n );\n });\n $(\".js-fixed--width100\").each(function (index, element) {\n $(element).css(\"width\", \"100%\");\n });\n lightWindowManager.isFixedElementFixApplied = false;\n }\n };\n\n LightWindow.prototype.showCover = function (\n name,\n lwtype: string,\n isUndismissable: boolean\n ): any {\n const that = this;\n lwtype = lwtype || \"lightwindow\";\n const $body = $(\"body\");\n const oldBodyWidth = $body.width();\n $body.css(\"overflow\", \"hidden\");\n that.scrollbarWidth = $body.width() - oldBodyWidth;\n $body.css(\"width\", \"calc(100% - \" + that.scrollbarWidth + \"px)\");\n that.fixedElementFix(true);\n\n // only handle page scrolling fix on the main lightwindow\n if (!that.parentLightWindow) {\n const bodyScrollTop = $(document).scrollTop();\n $body.css(\"top\", -bodyScrollTop).css(\"position\", \"fixed\");\n }\n\n if (that.cover) {\n that.cover.off(\"click\");\n }\n\n if (!that.cover) {\n that.cover = $(\n '
'\n );\n\n that.preloaderElement = $(that.preloaderMarkup);\n that.cover.html(that.preloaderElement);\n that.cover.css(\"text-align\", \"center\");\n\n if (that.parentLightWindow) {\n $(that.parentElement).append(that.cover);\n } else {\n //adding to body, prepend so at the top\n that.parentElement.prepend(that.cover);\n }\n }\n if (lwtype !== \"alert\" && isUndismissable !== true) {\n that.cover.lastMouseDownEl = undefined;\n that.cover.off(\"mousedown.lastEl\").on(\"mousedown.lastEl\", function (e) {\n /* prevent clicks that begin on elements that are hidden before the click is released from allowing the cover to think it was clicked\n * e.g. custom dropdown options being clicked.\n * then compare the mousedown event target to the click event target to make sure the user intended to click the cover\n */\n that.cover.lastMouseDownEl = e.target;\n });\n that.cover.off(\"click\").on(\"click\", function (e) {\n // prevent closing on child elements\n if (\n e.target !== this ||\n (that.cover.lastMouseDownEl !== undefined &&\n that.cover.lastMouseDownEl !== this)\n )\n return;\n\n // disable click on self and parents\n let myCover = that;\n while (myCover) {\n if (myCover.cover) {\n myCover.cover.off(\"click\");\n }\n myCover = myCover.parentLightWindow;\n }\n\n //close the parent most lightwindow\n lightWindowManager.close(lightWindowManager.currentLightWindow);\n });\n }\n\n $(that.cover).fadeIn(that.fadeLength);\n $(that.cover).scrollTop(0);\n return $(that.cover);\n };\n\n LightWindow.prototype.showPopUp = function (\n name: string,\n content: string,\n lwtype: string,\n lwclassnames: string\n ) {\n const that = this;\n let $lwContainer = $(\"#\" + this.lightWindowId(name));\n let $cover;\n lwclassnames =\n lwclassnames && typeof lwclassnames !== \"undefined\" ? lwclassnames : \"\";\n lwtype = lwtype || \"lightwindow\";\n if (!$lwContainer[0] || lwtype === \"alert\") {\n // add the content\n $lwContainer = $(this.lwContainerTemplate);\n $lwContainer.html(content);\n $lwContainer.attr(\"id\", this.lightWindowId(name));\n $lwContainer.css(\"z-index\", \"auto\");\n\n if ($lwContainer.find(\".js-lightwindowproperties-type\").length > 0) {\n //add the type of lightwindow after the default lightwindow class\n $lwContainer[0].className = $lwContainer[0].className.replace(\n \" lightwindow \",\n \" lightwindow \" +\n $lwContainer.find(\".js-lightwindowproperties-type\").val() +\n \" \"\n );\n }\n\n if ($lwContainer.find(\".js-lightwindowproperties-classnames\").length > 0) {\n lwclassnames +=\n \" \" + $lwContainer.find(\".js-lightwindowproperties-classnames\").val();\n }\n $lwContainer.addClass(\n name + \"panel\" + (\" js-\" + name + \"panel\") + (\" \" + lwclassnames)\n );\n\n // add to the page\n $cover = $(that.cover);\n $cover.append($lwContainer);\n $lwContainer = $cover.find(\".js-\" + name + \"panel\");\n\n if (typeof that.initfunction === \"function\") {\n that.initfunction($lwContainer);\n }\n } else {\n const el = $lwContainer.detach();\n $cover = lightWindowManager.getTopCover().showCover(name);\n $cover.append(el);\n that.cover = $cover;\n $lwContainer = $cover.find(\".js-\" + name + \"panel\");\n }\n\n $(\".js-\" + name + \"panel\").trigger(\"lw-show\");\n\n // show lightwindow\n $lwContainer.addClass(\"is-lwtransitioning\").show();\n setTimeout(function () {\n $lwContainer.removeClass(\"is-lwtransitioning\");\n }, 150);\n\n // set focus\n const scroll = $(that.cover).scrollTop();\n let $lwFocusEl = $lwContainer.find(\".js-lwfocus, input, textarea, button\").eq(0); //TODO: also handle dropdowns\n if (!$lwFocusEl.length) {\n $lwFocusEl = $lwContainer;\n } else {\n if (window.innerHeight <= 1024 && $lwContainer[0].offsetTop * 2 < 352) {\n if (\n ($lwFocusEl.is(\"input\") &&\n $lwFocusEl.type != \"button\" &&\n $lwFocusEl.type != \"submit\") ||\n $lwFocusEl.type == \"textarea\"\n ) {\n $lwFocusEl = $lwContainer;\n }\n }\n }\n if ($lwFocusEl === $lwContainer) {\n $lwContainer[0].tabIndex = 1;\n }\n $lwFocusEl.focus();\n $(that.cover).scrollTop(scroll);\n\n // vertically center\n that.verticallyCenter($lwContainer);\n $lwContainer.removeClass(\"lightwindow--closed\");\n\n // close button\n if (lwtype !== \"alert\") {\n if ($lwContainer.find(\".js-lightwindow-close\")) {\n $lwContainer\n .find(\".js-lightwindow-close\")\n .unbind(\"click.closelw\")\n .on(\"click.closelw\", function (e) {\n e.preventDefault();\n that.close(name);\n });\n }\n }\n };\n\n LightWindow.prototype.verticallyCenter = function ($lwContainer) {\n let topPosition = $(this.cover).height() / 2 - $lwContainer.outerHeight(true) / 2;\n if (topPosition < 0) topPosition = 0;\n $lwContainer.css(\"top\", topPosition);\n };\n\n LightWindow.prototype.getTopCover = function () {\n let topcover = lightWindowManager;\n //find the highest cover\n while (topcover.currentLightWindow && topcover.childLightWindow) {\n topcover = topcover.childLightWindow;\n }\n return topcover;\n };\n\n LightWindow.prototype.getTopLightWindow = function () {\n let toplw = lightWindowManager;\n //find the highest lightwindow\n while (\n toplw.childLightWindow &&\n toplw.childLightWindow.cover.find(\".js-lightwindow:visible\").length > 0\n ) {\n toplw = toplw.childLightWindow;\n }\n if (toplw.cover) {\n return toplw.cover.find(\".js-lightwindow:visible\");\n } else {\n return false;\n }\n };\n\n LightWindow.prototype.closeTopLightWindow = function () {\n lightWindowManager\n .getTopLightWindow()\n .find(\".js-lightwindow-close\")\n .first()\n .click();\n };\n\n LightWindow.prototype.close = function (name, shouldremove, onComplete) {\n if (typeof shouldremove !== \"undefined\" && shouldremove !== null) {\n console.log(\n \"fn lightwindow.close shouldremove arg is deprecated, use lightwindow property shouldCache instead\"\n );\n }\n function hideLightWindow() {\n if (name && $(\"#\" + that.lightWindowId(name)).length > 0) {\n $(\"#\" + that.lightWindowId(name)).tabIndex = \"-1\";\n // hide the lightwindow\n $(\"#\" + that.lightWindowId(name))\n .addClass(\"lightwindow--closed is-lwtransitioning\")\n .fadeOut(that.fadeLength, function () {\n // close any opened tooltips in the lightwindow\n $(that.cover).find(\".tooltip-container\").removeClass(\"show\");\n $(\".js-\" + name + \"panel\").trigger(\"lw-hide\");\n })\n .removeClass(\"is-lwtransitioning\");\n } else {\n //must have failed to load lightwindow\n }\n\n $(that.cover).fadeOut(230, function () {\n if (!that.parentLightWindow) {\n const bodyTop = $(\"body\").position().top * -1;\n $(\"body\")\n .css(\"overflow\", \"\")\n .css(\"width\", \"\")\n .css(\"position\", \"\")\n .css(\"top\", \"\");\n that.fixedElementFix(false);\n\n // scroll back down since we remove position fixed\n if (bodyTop > 0) {\n $(document).scrollTop(bodyTop);\n }\n }\n\n $(that.cover).find(\".js-lightwindow\").hide();\n\n if (typeof that.parentLightWindow !== \"undefined\") {\n that.parentLightWindow.childLightWindow = undefined;\n }\n\n that.lastFocus.focus();\n if (typeof that.callbackonclose === \"function\") {\n that.callbackonclose();\n }\n\n const coverstoremove = [];\n let curlw = that;\n // move current and any children to our cache div\n while (curlw) {\n var $childlw;\n if (typeof curlw.cover !== \"undefined\") {\n //push the curlw into our array for removal handling\n coverstoremove.push(curlw);\n $childlw = curlw.cover.find(\".js-lightwindow\");\n if (curlw.shouldCache == true) {\n //if we should cache, detach and append into cache div\n $childlw.detach();\n lightWindowManager.cacheEl.append($childlw);\n }\n }\n curlw = curlw.childLightWindow;\n }\n\n if (that.coverNumber === 0) {\n that.childLightWindow = undefined;\n }\n\n $.each(coverstoremove, function (index, el) {\n //remove the lightwindow\n $(this.cover).remove();\n //reset the lightwindows cover and child\n this.cover = undefined;\n this.childLightWindow = undefined;\n //unlink it from its previous parent\n if (this.parentLightWindow) {\n this.parentLightWindow.childLightWindow = undefined;\n }\n //clear shouldCache\n this.shouldCache = undefined;\n });\n\n if (typeof onComplete === \"function\") {\n onComplete();\n }\n });\n }\n\n function hideChildrenLightWindows(i) {\n //loop over children lightwindows and hide them starting from most nested\n const duration = 230;\n if (i >= 0) {\n const $el = hideChildren[i].cover.find(\".js-lightwindow\");\n $el.addClass(\"lightwindow--closed is-lwtransitioning\")\n .fadeOut(that.fadeLength)\n .removeClass(\"is-lwtransitioning\");\n $(hideChildren[i].cover).fadeOut(duration, function () {\n hideChildrenLightWindows(i - 1);\n });\n }\n if (i === 0) {\n setTimeout(function () {\n hideLightWindow();\n }, duration);\n }\n }\n\n var that = this;\n while (\n name != that.currentLightWindow &&\n typeof that.childLightWindow !== \"undefined\"\n ) {\n that = that.childLightWindow;\n }\n\n that.currentLightWindow = undefined;\n\n if (that.cover) {\n that.cover.off(\"click\");\n if (that.cover.find(\".js-lightwindow-close\").length > 0) {\n that.cover.find(\".js-lightwindow-close\").unbind(\"click.closelw\");\n }\n }\n\n // add children lightwindows to array\n var hideChildren = [];\n let hideChildrenItem = that.childLightWindow;\n while (hideChildrenItem) {\n hideChildren.push(hideChildrenItem);\n hideChildrenItem = hideChildrenItem.childLightWindow;\n }\n if (hideChildren.length > 0) {\n hideChildrenLightWindows(hideChildren.length - 1);\n } else {\n hideLightWindow();\n }\n };\n\n LightWindow.prototype.urlOverride = function (name: string): string | null {\n switch (name) {\n case \"cashback\":\n return \"/page_fragments/lightwindow_cashback.aspx\";\n case \"lifecalc\":\n return \"/page_fragments/lightwindow_lifecalc.aspx\";\n case \"edityourtripdetails\":\n return \"/travel-insurance/edityourtripdetails.aspx\";\n case \"travel-voucher-terms\":\n return \"/page_fragments/lightwindow_travelvouchertnc.aspx\";\n default:\n return null;\n }\n };\n\n LightWindow.prototype.isValidLightWindow = function (name) {\n return $.inArray(name, this.validLightWindows) !== -1;\n };\n\n LightWindow.prototype.addValidLightWindows = function (arr) {\n //check we haven't already added lightwindows to the valid list before adding them\n const that = this;\n $.each(arr, function (i, item) {\n if (that.isValidLightWindow(item) === false) {\n lightWindowManager.validLightWindows.push(item);\n }\n });\n };\n\n LightWindow.prototype.lightWindowId = function (name) {\n return name + \"panel\";\n };\n\n LightWindow.prototype.showAlert = function (args) {\n //message, title, callbackonclose, footer, initfunction, classnames\n args = $.extend(\n {\n message: \"Sorry, an error has occurred.\",\n title: undefined,\n callbackonclose: undefined,\n footer: undefined,\n initfunction: undefined,\n classnames: undefined,\n shouldCache: false\n },\n args\n );\n\n let alertlw = this;\n const that = this;\n const uniqueid = new Date().getTime();\n const name = \"alert\" + uniqueid;\n that.lastFocus = document.activeElement;\n /* if not lightWindowManager, create alert as child of child most lightwindow,\n * otherwise alert is just lightWindowManager\n */\n if (typeof that.currentLightWindow !== \"undefined\") {\n while (alertlw.childLightWindow) {\n // find the child most lightwindow\n alertlw = alertlw.childLightWindow;\n }\n alertlw.childLightWindow = new LightWindow(alertlw); //create new lightwindow as child\n alertlw = alertlw.childLightWindow;\n }\n alertlw.currentLightWindow = name;\n\n alertlw.shouldCache = args.shouldCache; //important we set this everytime so we don't inherit a previous lightwindows property\n alertlw.initfunction = args.initfunction; //important we set this everytime, whether it's a function or undefined, so we don't inherit a previous alerts function\n alertlw.callbackonclose = args.callbackonclose; //important we set this everytime, whether it's a function or undefined, so we don't inherit a previous alerts function\n\n alertlw.showCover(name, \"alert\");\n alertlw.showPopUp(\n name,\n alertlw.alertTemplate(args.message, args.title, args.footer),\n \"alert\",\n args.classnames\n );\n alertlw.cover.find(\".js-alert-message\").html(args.message);\n const closebtn = alertlw.cover.find(\".js-alert-close\");\n if (closebtn.length > 0) {\n closebtn.on(\"click.closelw\", function (event) {\n alertlw.close(name);\n });\n }\n };\n\n if (!window.lightWindowManager) {\n // avoid double loading\n lightWindowManager = new LightWindow();\n lightWindowManager.init();\n window.lightWindowManager = lightWindowManager;\n }\n})($);\n"],"sourceRoot":""}