Build 562131stable
Module 344005
1,665 characters · in 7baf2fb867b41ecc.jsDependencies
Source Raw
function(e,n,a){a.d(n,{oS:()=>p,Ay:()=>m}),a(321073);var l,o,t=a(64700),i=a(284009),r=a.n(i),u=((l={})[l.GAME_PROFILE_DISABLED=1]="GAME_PROFILE_DISABLED",l),d=((o={})[o.THRILLER=0]="THRILLER",o[o.SCIENCE_FICTION=1]="SCIENCE_FICTION",o[o.ACTION=2]="ACTION",o[o.HORROR=3]="HORROR",o[o.SURVIVAL=4]="SURVIVAL",o[o.FANTASY=5]="FANTASY",o[o.HISTORICAL=6]="HISTORICAL",o[o.STEALTH=7]="STEALTH",o[o.COMEDY=8]="COMEDY",o[o.BUSINESS=9]="BUSINESS",o[o.DRAMA=10]="DRAMA",o[o.NON_FICTION=11]="NON_FICTION",o[o.KIDS=12]="KIDS",o[o.SANDBOX=13]="SANDBOX",o[o.OPEN_WORLD=14]="OPEN_WORLD",o[o.WARFARE=15]="WARFARE",o[o.EDUCATIONAL=16]="EDUCATIONAL",o[o.MYSTERY=17]="MYSTERY",o[o.PARTY=18]="PARTY",o[o.ROMANCE=19]="ROMANCE",o[o.EROTIC=20]="EROTIC",o),s=a(665260),I=a(311043),A=a(174459),E=a(738250),R=a(652215);let O=function(e,n){let a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],l=arguments.length>3?arguments[3]:void 0;A.default.track(R.HAw.GAME_PROFILE_ENTRY_POINT_AVAILABLE,{game_profile_available:e,application_id:n,rejection_reason:a,source:l})},c=e=>{if(null==e)return["no match"];let n=[];return s.Lt(e.gameFlags,u.GAME_PROFILE_DISABLED)&&n.push("profile disabled"),e.themes.includes(d.EROTIC)&&n.push("nsfw"),n},f=e=>0===c(e).length,p=e=>f(I.A.getGame(e)),m=e=>{let{applicationId:n="",gameId:a,source:l,trackEntryPointImpression:o=!0}=e,i=t.useRef(!1),{gameId:u,gameRecord:d,isLoading:s}=(0,E.A)({applicationId:n,gameId:a}),I=f(d);return t.useEffect(()=>{if(!i.current&&o&&!s&&null!=d){r()(null!=l,"Cannot track a Game Profile Entry Point Impressions without a source.");let e=c(d);O(I,d.id,e,l),i.current=!0}},[d,I,s,l,o]),{shouldOpenGameProfile:I,gameId:u}}}