PageSourceSearch

https://casinosanalyzer.co.nz/build/midori/assets/js/amplitude.min.js?v=5801963

js casinosanalyzer.co.nz collected 2026-09-26 03:10:34 UTC 13,620 bytes, 1 lines download raw bytes

1import{brevoUtmData,buildExternalId,elementInViewport,eventID,getAmplitudeCookie,getReferrer,getWidgetAffLinkClickIndex,isCurrentPage404ByDOM,prepareUtmParams,setCampaignParameter,utmInitParams,utmParams}from"globals";import{footerDetection}from"Footer";import{baseHttp as baseHttpAmplitude}from"baseHttp";export const amplitudeVersion=1;export const bonusRoutes=["p_bonus_casino","p_bonus_amount","p_bonus_category","p_bonus_percent","p_bonus_spin_n","p_bonus_country","p_software_bonuses","p_promo_codes_category"];export const casinoRoutes=["p_casino_category","p_casino_deposit_low","p_casino_country","p_casino_currency","p_casino_city","p_casino_country","p_casino_payment","p_casino_slot_soft","p_casino_state_usa","p_software_bonuses","p_similar_casinos","p_casino"];function loadIfExists(e,t,i){document.querySelector(e)&&t().then(e=>i(e))}document.addEventListener("DOMContentLoaded",()=>{setAmplitudeParams(document.body.dataset.routeBonus,document.body.dataset.routeId,document.body.dataset.localeLang,document.body.dataset.websiteEnv,document.body.dataset.localeCountry,document.body.dataset.geo),checkIfAnalyticsLoaded(),storeAmSessionIdInCookie()});export let ROUTE,ROUTE__ID,ROUTE__EXIST,EVENT__ID,EVENT__CAT,PAGE__CURRENT__PATH,PAGE__URL,PAGE__URL__FULL,LOCALE__LANG,WEBSITE__ENVIRONMENT,LOCALE__COUNTRY;const setAmplitudeParams=(e,t,i,n,a)=>{ROUTE=e,ROUTE__ID=t,ROUTE__EXIST=eventID.findIndex(t=>t===e),EVENT__ID=ROUTE__EXIST>-1?ROUTE__EXIST+1:eventID.length,EVENT__CAT=ROUTE__EXIST>-1?eventID[ROUTE__EXIST]:eventID[eventID.length-1],PAGE__CURRENT__PATH=document.location.pathname,PAGE__URL=document.location.origin+document.location.pathname,PAGE__URL__FULL=document.location.href,LOCALE__LANG=i,WEBSITE__ENVIRONMENT=n,LOCALE__COUNTRY=a},checkIfAnalyticsLoaded=()=>{window.ga||window.amplitude||window.zaraz?analyticsLoaded():setTimeout(()=>checkIfAnalyticsLoaded(),500)},analyticsLoaded=async e=>{setTimeout(async()=>{if(storage.setPageAffLinkClickIndex(0),setCampaignParameter(),utmInitParams(),prepareUtmParams(),sendUserProps(),visitPage(),visitPageProfile(),callViewBannerAmplitude(),showMoreBonusesClickAmplitude(),loadIfExists('[data-amplitude], #form_domain, [data-element="bonusWelcomeTypeWidgetCards"], [data-element="bonusWelcomeTypeWidgetCardsDark"]',()=>import("amplitudeBonusTableCore"),e=>e.newAmplitude()),loadIfExists("#profileHeaderNotAuth, #authBannerSignupButton, #authBannerSignup, #authSignupButton, #profileWidgetLogoutButton",()=>import("amplitudeAuthHeader"),e=>e.initAuthHeader()),loadIfExists(".card_signUp-banner, .authSignupBonusListButton, .card_community-banner",()=>import("amplitudeBannerSignupCommunity"),e=>e.initBannerSignupCommunity()),loadIfExists("#casinoScoreWidgetOptions, #casinoUserCommentWidget, #casinoWidgetInfoText, #casinoScoreWriteReviewButton, #casinoUserCommentSortOptions, .helpfulLike_click, #casinoUserCommentShowMoreButton, .card_review-banner, #summaryWidgetReadReviews, #summary_widget",()=>import("amplitudeCasinoScoreWidget"),e=>e.initCasinoScoreWidget()),loadIfExists("[data-casino-activity-log-widget]",()=>import("amplitudeActivityLog"),e=>e.casinoActivityLogAmplitude()),loadIfExists("#shopBanner, #shopBannerClose",()=>import("amplitudeShopBanner"),e=>e.initShopBanner()),loadIfExists('.bonusesFilterListingBar, input[name="bonusesFilter"], #geoSwitcherFilterPopupBox, [data-element="bonusesFilterSortTrigger"], .bonusesFilterListingBar__sort-dropdown-options, button[data-element="bonusesFilterMobBtn"], #geoSwitcher, .header_container .countries_box .country',()=>import("amplitudeBonusFiltersGeo"),e=>e.initBonusFiltersGeo()),!isCurrentPage404ByDOM()){const{registerRelatedSearchesAmplitudeEvents:e}=await import("RelatedSearchesWidget");e();const{initCrBannerAmplitudeEvents:t}=await import("CrBannerWidget");t();const{stickyWidgetDetection:i}=await import("StickyWidget");i()}footerDetection()},2e3)},updateUtmInitParams=async(e,t)=>{const i=await fetch(`${baseHttpAmplitude}/update-utm-init-params`,{method:"post",headers:{"Content-Type":"application/json"},body:JSON.stringify({user_id:e,utm_init_params:t})});return await i.json()},updateAmData=async(e,t)=>{const i=await fetch(`${baseHttpAmplitude}/update-am-data`,{method:"post",headers:{"Content-Type":"application/json"},body:JSON.stringify({user_id:e,am_data:t})});return await i.json()},sendUserProps=()=>{const e="true"===document.body.dataset.utmInitParams,t=document.body.dataset.am??null,i=document.body.dataset.userId??null,
1n=storage.getUtmInitParams(),a=storage.getUtmDataLayerPushed(),s=storage.getUtmLoggedUserDataLayerPushed();let o;if(i){JSON.stringify(JSON.parse(t))!==JSON.stringify(brevoUtmData())&&updateAmData(i,brevoUtmData()).then(e=>{})}e?(o=Object.assign({event:"addUserProperties",user_property_id:"d-v1-up",user_property_name:"user_property",website_language:JSON.stringify(LOCALE__LANG),website_environment:JSON.stringify(WEBSITE__ENVIRONMENT),website_country:JSON.stringify(LOCALE__COUNTRY),is_test:JSON.stringify(getAmplitudeCookie("ca_admin")?1:0)},e),s||(dataLayer.push(o),storage.setUtmLoggedUserDataLayerPushed("true"))):(i&&n&&updateUtmInitParams(i,n).then(e=>{}),o=Object.assign({event:"addUserProperties",user_property_id:"d-v1-up",user_property_name:"user_property",website_language:JSON.stringify(LOCALE__LANG),website_environment:JSON.stringify(WEBSITE__ENVIRONMENT),website_country:JSON.stringify(LOCALE__COUNTRY),is_test:JSON.stringify(getAmplitudeCookie("ca_admin")?1:0)},n)),a||(dataLayer.push(o),storage.setUtmDataLayerPushed("true"))};let timerStart=Date.now();const visitPage=()=>{let e=Date.now(),t=new Date(timerStart-e).getMilliseconds();const i=window.performance.getEntries().find(e=>"navigation"===e.entryType);dataLayer.push(Object.assign({event:"addEvents_visitPage",event_id:`d-v1-e${EVENT__ID}`,event_cat:EVENT__CAT,event_name:"view",page_current_path:JSON.stringify(PAGE__CURRENT__PATH),page_group:JSON.stringify(EVENT__CAT),page_url:JSON.stringify(PAGE__URL),page_url_full:JSON.stringify(PAGE__URL__FULL),page_route_id:JSON.stringify(ROUTE__ID),page_load_time:JSON.stringify(t),page_http_status_code:JSON.stringify(i.responseStatus),template_id:JSON.stringify(document.body.dataset.templateId),template_name:JSON.stringify(document.body.dataset.templateName),website_domain:JSON.stringify(document.location.hostname)},getReferrer(),utmParams()))},visitPageProfile=()=>{"/profile"===document.location.pathname&&dataLayer.push(Object.assign({event:"addEvents_visitPage",event_id:`d-v1-e${EVENT__ID}`,event_cat:"p_profile",event_name:"view",page_current_path:JSON.stringify(document.location.pathname),page_url:JSON.stringify(PAGE__URL),page_url_full:JSON.stringify(PAGE__URL__FULL),page_group:JSON.stringify("p_profile"),page_http_status_code:JSON.stringify(window.performance.getEntries().find(e=>"navigation"===e.entryType).responseStatus),page_route_id:JSON.stringify(document.body.dataset.routeId),website_domain:JSON.stringify(document.location.hostname),template_id:JSON.stringify(document.body.dataset.templateId),template_name:JSON.stringify(document.body.dataset.templateName)},getReferrer(),utmParams()))},callViewBannerAmplitude=()=>{setTimeout(()=>{document.getElementById("lockScreen")&&dataLayer.push(Object.assign({event:"addEvents_visitPage",event_id:`d-v1-e${EVENT__ID}`,event_cat:"w_website",event_name:"ban",page_http_status_code:JSON.stringify(window.performance.getEntries().find(e=>"navigation"===e.entryType).responseStatus),page_current_path:JSON.stringify(PAGE__CURRENT__PATH),page_url:JSON.stringify(PAGE__URL),page_url_full:JSON.stringify(PAGE__URL__FULL),page_group:JSON.stringify(EVENT__CAT),page_route_id:JSON.stringify(ROUTE__ID),template_id:JSON.stringify(document.body.dataset.templateId),template_name:JSON.stringify(document.body.dataset.templateName),website_domain:JSON.stringify(document.location.hostname)},getReferrer(),utmParams()))},1e3)},showMoreBonusesClickAmplitude=()=>{let e=document.getElementsByClassName("table-show-more");e&&Array.from(e).forEach(e=>{const t=e.previousElementSibling;e.addEventListener("click",()=>{dataLayer.push(Object.assign({event:"addEvents_click",event_id:`d-v1-e${EVENT__ID}`,event_cat:"w_website",event_name:"showMore",page_current_path:JSON.stringify(PAGE__CURRENT__PATH),page_url:JSON.stringify(PAGE__URL),page_url_full:JSON.stringify(PAGE__URL__FULL),page_group:JSON.stringify(EVENT__CAT),page_route_id:JSON.stringify(ROUTE__ID),widget_id:JSON.stringify(t.dataset.widgetId)??null,widget_title:JSON.stringify(t.dataset.widgetTitle)??null,widget_handler:JSON.stringify(t.dataset.widgetHandler)??null,widget_section:JSON.stringify(t.dataset.widgetSection)??null,widget_position:JSON.stringify(t.dataset.widgetPosition)??null,casino_list_for_geo:JSON.stringify(t.dataset.widgetBonusCountry)??null,website_domain:JSON.stringify(document.location.hostname)}
1,utmParams()))})})},slotDemoPlayAffClick=()=>{const e=document.querySelectorAll('a[data-amplitude="slotDemoPlayAffClick"]');if(e.length){const t=e=>{let t="";return 5===e?t="A":e>4.5&&e<=4.9?t="B":e>4&&e<=4.5?t="C":e<=4&&(t="D"),t},i=document.querySelector(".slot__preview--links"),n=i.dataset.items?JSON.parse(i.dataset.items)[0]:[],a=i.dataset.casinoBonusButtonName;e.forEach(e=>{e.addEventListener("click",async()=>{const i={widgetTitle:"slotDemoPlay",eventCat:"w_slot_demo_play",widgetPref:"showBlock",clickAffLinkVersion:35,showWidgetVersion:34,eventAffClickName:"casino_visit",casinos:[n],casino:n,btnText:a};let{casino:s,widgetTitle:o,eventCat:r,clickAffLinkVersion:_,eventAffClickName:d,btnText:c}=i;const u=document.location.pathname,g=document.location.origin+document.location.pathname,l=document.location.href,m=document.body.dataset.routeBonus,p=document.body.dataset.routeId,y=eventID.findIndex(e=>e===m),f=(y>-1||eventID.length,y>-1?eventID[y]:eventID[eventID.length-1]),S=(document.body.dataset.localeLang,document.body.dataset.websiteEnv,document.body.dataset.localeCountry,document.body.dataset.geo);let N=storage.getPageAffLinkClickIndex();N++,storage.setPageAffLinkClickIndex(N),s.casino||(s.casino={});let O=0;if(s.created){const e=new Date(s.created.date),t=new Date,i=Math.abs(t-e);O=Math.floor(i/864e5)}let b=365;if(s.expiredDate){const e=new Date(s.expiredDate.date),t=new Date;if(e<t)b=0;else{const i=Math.abs(e-t);b=Math.floor(i/864e5)+1}}const E=getWidgetAffLinkClickIndex(e?.dataset?.widgetId),J=await buildExternalId(s.id);dataLayer&&dataLayer.push(Object.assign({event:"addEvents_clickAffLink",event_id:`d-v${document.body.dataset.amplitudeVersion}-e${_}`,event_cat:r,event_name:d,page_current_path:JSON.stringify(u),page_url:JSON.stringify(g),page_url_full:JSON.stringify(l),page_group:JSON.stringify(f),widget_title:JSON.stringify(o),widget_id:JSON.stringify(null),page_route_id:JSON.stringify(p),widget_handler:JSON.stringify(widgetHandler),widget_section:JSON.stringify(widgetSection),widget_position:JSON.stringify(widgetPosition),casino_list_user_country:JSON.stringify(S),casino_user_country:JSON.stringify(S),casino_list_for_geo:JSON.stringify(!1),casino_domain:JSON.stringify(s.casino.domain),casino_bonus_title_short:JSON.stringify(s.titleShort?s.titleShort:null),casino_bonus_title_short_strlen:JSON.stringify(s.titleShort?s.titleShort.length:0),casino_id:JSON.stringify(s.casino.casinoId),casino_name:JSON.stringify(s.casino.name),casino_bonus_amount_max:JSON.stringify(s.amountMax&&!isNaN(parseInt(s.amountMax))?parseInt(s.amountMax):0),casino_bonus_percent:JSON.stringify(s.percent?s.percent:0),casino_bonus_exclusive:JSON.stringify(!!s.exclusive&&s.exclusive),casino_bonus_expired:JSON.stringify(!!s.expired&&s.expired),casino_bonus_button_name:JSON.stringify(c),casino_bonus_id:JSON.stringify(s.id),...J?{external_id:JSON.stringify(J)}:{},casino_domain_bonus_id:JSON.stringify(s.casino.domain+"_"+s.id),casino_score_geo:JSON.stringify(!!s.score&&s.score),casino_afflink_exist:JSON.stringify(!!s.affiliateUrl),casino_bonus_wagering_requirements:JSON.stringify(s.wageringRequirements&&!isNaN(parseInt(s.wageringRequirements))?parseInt(s.wageringRequirements):0),casino_bonus_deposit_min:JSON.stringify(s.depositMin?parseInt(s.depositMin):0),casino_bonus_code_exist:JSON.stringify(!!s.code),casino_bonus_label_exist:JSON.stringify(!!s.label),casino_bonus_category:JSON.stringify(Array.isArray(s.bonusCategories)?s.bonusCategories.map(e=>e.name).join(", "):null),casino_bonus_label:JSON.stringify(s.label?s.label:"Not Set"),widget_list_index:JSON.stringify(1),casino_bonus_type:JSON.stringify(Array.isArray(s.bonusTypes)?s.bonusTypes.map(e=>e.name).join(", "):null),casino_bonus_free_spins:JSON.stringify(s.freeSpins?+s.freeSpins:0),casino_score_geo_text:JSON.stringify(t(s.score)),page_afflink_click_index:JSON.stringify(N),widget_afflink_click_index:JSON.stringify(E),casino_user_country_allowed:JSON.stringify(!0),casino_bonus_currency:JSON.stringify(s.currency&&!s.currency.every(e=>null===e)?Object.values(JSON.parse(s.currency)):["Not Set"]),casino_bonus_active:JSON.stringify(!s.affiliateUrl),casino_bonus_slots:JSON.stringify(JSON.parse(s.slots).length?Object.values(JSON.parse(s.slots)):["Not Set"]),casino_bonus_category_display:JSON.stringify("Not Set"),casino_geo_rating:JSON.stringify(s.score?+s.score.toFixed(1):0),casino_bonus_active_days_left:JSON.stringify(+b),casino_bonus_days_after_create:JSON.stringify(+O),casino_bonus_code:JSON.stringify(s.co
1de?s.code:"Not Set"),casino_bonus_cashable:JSON.stringify(!!s.cashable&&s.cashable),sponsored:JSON.stringify(!!s.sponsored)},utmParams()))})})}},storeAmSessionIdInCookie=async()=>{const{amSessionCookieSync:e}=await import("storeAmSessionIdInCookie");e()};export{slotDemoPlayAffClick};

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.