1"use strict";(self.webpackChunkgoafrica=self.webpackChunkgoafrica||[]).push([[4974],{34974:function(t,e,n){n.r(e);var i=n(19755),o=n.n(i),r=n(72911),a=n(79728),l=n(90410);function c(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,u(i.key),i)}}function s(t,e,n){return e&&c(t.prototype,e),n&&c(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function d(t,e,n){return(e=u(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function u(t){var e=function(t,e){if("object"!=typeof t||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,e||"default");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:String(e)}function f(){return o()("[data-base-container-for-background-ad]")}let g=s((function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),d(this,"createBackgroundIframe",(t=>{const e=document.createElement("template");return e.innerHTML=function(t){let{width:e,height:n,platform:i="desktop",iframe:o,style:r=""}=t;return`<iframe\n width="${e}"\n height="${n}"\n src="${o}?request_info=${(0,a.i)()}&platform=${encodeURIComponent(i)}"\n style="${r}"\n frameborder="0"\n marginwidth="0"\n marginheight="0"\n vspace="0"\n hspace="0"\n allowtransparency="true"\n scrolling="no"\n allowfullscreen="true"></iframe>`}({width:0,height:0,iframe:t.iframeUrl,style:"display: none;"}).trim(),e.content.firstChild})),d(this,"calcPosition",((t,e)=>{let{position:n}=e;const i=.6*t.width,o=t.width,r=(document.documentElement.clientWidth-f().outerWidth())/2,a=Math.min(Math.max(i,r),o),l=a-r,c=.4*i,s=f().position().top;let d={width:a,height:t.height/2*a/t.width,top:s-Math.min(window.scrollY,s)};return d="left"===n?{...d,left:-l}:{...d,right:-l},d=l>c?{...d,display:"none"}:{...d,display:"block"},d})),d(this,"defaultAddCss",((t,e)=>{let{position:n}=e;return{...this.calcPosition(t,{position:n}),position:"fixed",backgroundImage:`url(${t.referenceUrl})`,backgroundRepeat:"no-repeat",backgroundSize:"cover",backgroundPosition:"left"===n?"0 0":"0 100%",cursor:"pointer"}})),d(this,"attachEvent",((t,e,n)=>{o()(window).resize((()=>{e.css(this.calcPosition(t,n))})),document.addEventListener("scroll",(()=>{e.css(this.calcPosition(t,n))}))})),d(this,"installAd",((t,e,n)=>{const i=o()(`#goafrica-background-ad-${e.position}`);i.css(this.defaultAddCss(t,e)),this.attachEvent(t,i,e),i.on("click",(()=>{n()}))})),d(this,"showAd",(t=>{let{ad:e,image:n,link:i}=t;try{if("none"===this.calcPosition(n,{position:"left"}).display)return;const t=()=>{null!=e.link?window.open(i):window.location.assign(i)};this.installAd(n,{position:"left"},t),this.installAd(n,{position:"right"},t);const o=this.createBackgroundIframe(e);if(null==o)return;document.body.appendChild(o)}catch(t){console.warn(t)}})),d(this,"install",(async t=>{const{category:e,country:n,homepage:i=null}=t,{companyAd:o=null,companyStaticAd:c=null}=await(0,l.Ic)({format:"background",slot:"background",category:e,country:n,homepage:i});null==c?null==o||this.showAd({ad:o,image:o.backgroundMedia.image,link:r.Z.generate("goafrica_company_ad_click_redirection",{adId:o.id,mediaId:o.backgroundMedia.id,slot:"background",request_info:(0,a.i)()})}):this.showAd({ad:c,image:c.media,link:r.Z.generate("goafrica_company_static_ad_click_redirection",{adId:c.id,request_info:(0,a.i)()})})}))}));var h=n(73955),m=n.n(h);n(67545);function p(t,e){for(var n=0;n<e.length;n++){var i=e[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,b(i.key),i)}}function w(t,e,n){return e&&p(t.prototype,e),n&&p(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function y(t,e,n){return(e=b(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function b(t){var e=function(t,e){if("object"!=typeof t||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var i=n.call(t,e||"default");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}
1(t,"string");return"symbol"==typeof e?e:String(e)}let v=w((function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),y(this,"showAd",(t=>{let{selector:e,ad:n,image:i,media:r,slot:l}=t;const c=m()("goafrica-target-ad-"),s=function(t){let{platform:e="desktop",iframe:n}=t;return`<iframe\n width="0"\n height="0"\n src="${n}?request_info=${(0,a.i)()}&platform=${encodeURIComponent(e)}"\n style="display: none;"\n frameborder="0"\n marginwidth="0"\n marginheight="0"\n vspace="0"\n hspace="0"\n allowtransparency="true"\n scrolling="no"\n allowfullscreen="true"></iframe>`}({iframe:n.iframeUrl}),d=o()(`<div\n class="goafrica-ad \n fade in hidden \n ls:flex ls:w-offset-container-ls lm:w-offset-container-lm ll:w-offset-container-ll \n justify-end fixed \n bottom-0 \n ${"target_left"===l?"left-0":""}\n ${"target_right"===l?"right-0":""}\n "\n id="${c}">\n <div class="relative mb-8 rounded-lg overflow-hidden shadow-boxHover w-250px mr-4">\n <button type="button"\n class="close absolute mr-3 mt-3 top-0 right-0 text-18 opacity-15 hover:opacity-75"\n aria-label={Translator.trans("ui.close")}\n data-toggle="toggle-display"\n data-target="#${c}">\n <span aria-hidden="true">×</span>\n </button>\n <button class="m-0 p-0 border-none" id="${c}-button">\n <img src="${i.referenceUrl}" class="w-full h-auto" />\n </button>\n ${s}\n </div>\n </div>`);d.find("[data-toggle=toggle-display]").on("click",(t=>{t.preventDefault(),o()(`#${c}`).remove()})),d.find(`#${c}-button`).on("click",(t=>{t.preventDefault();const e=Routing.generate("goafrica_company_ad_click_redirection",{adId:n.id,mediaId:r.id,slot:l,request_info:(0,a.i)()});null!=n.link?window.open(e):window.location.assign(e)})),o()(e).append(d)})),y(this,"installLeft",(async t=>{const{selector:e,category:n=null,country:i=null}=t,{companyAd:o=null}=await(0,l.Ic)({format:"target_left",slot:"target_left",category:n,country:i});null!=o&&this.showAd({selector:e,ad:o,slot:"target_left",media:o.targetLeftMedia,image:o.targetLeftMedia.image})})),y(this,"installRight",(async t=>{const{selector:e,category:n=null,country:i=null}=t,{companyAd:o=null}=await(0,l.Ic)({format:"target_right",slot:"target_right",category:n,country:i});null!=o&&this.showAd({selector:e,ad:o,slot:"target_right",media:o.targetRightMedia,image:o.targetRightMedia.image})}))}));n.e(227).then(n.bind(n,30227));const k=new g,_=new v;if(null!=window.GoafricaBackgroundAd_onLoaded)for(let t of window.GoafricaBackgroundAd_onLoaded)t(k);if(window.GoafricaBackgroundAd_onLoaded={push:t=>{t(k)}},null!=window.GoAfricaTargetAd_onLoaded)for(let t of window.GoAfricaTargetAd_onLoaded)t(_);window.GoAfricaTargetAd_onLoaded={push:t=>{t(_)}}}}]);
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.