PageSourceSearch

https://play.millionaire.co.uk/_next/static/chunks/3512.0e9c0faec54d84bd.js

js millionaire.co.uk collected 2026-10-10 02:38:42 UTC 12,965 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3512,5573],{93265:function(e,n,l){l.r(n);var o=l(52322),a=l(2784),i=l(26702),t=l(66437),d=l(64622),r=l(63602),s=l(91599),u=l(26925),c=l(51286);let v=e=>{var n;let[l,v]=(0,a.useState)([]),{config:m}=(0,d.useBrandConfig)(),h=(0,t.qn)("".concat(null==m?void 0:null===(n=m.UrlName)||void 0===n?void 0:n.toLowerCase(),"-comConsent"));(0,a.useEffect)(()=>{let e=(null==h?void 0:h.length)>0?h:[],n=null==e?void 0:e.map(e=>({...e,Enabled:!1}));v(n)},[]);let p=async n=>{(0,u.Z)("/api/player/doUpdateMediaSelect",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(new s.Z({ReceivePartner:!0,ReceiveEmail:!0,ReceivePhone:!0,ReceivePost:!0,ReceiveSMS:!0,PlayerCommunicationConsent:n}))}).then(()=>{(0,c.JG)("/api/player/getPlayerDetails").catch()}),null==e||e.portalClose()},f=e=>{p(e)},_=()=>{let e=null==l?void 0:l.map(e=>({...e,Enabled:!1}));p(e)};return(0,o.jsx)(r.J9,{initialValues:{},onSubmit:()=>null,children:n=>{let{setFieldValue:a}=n;return(0,o.jsx)(o.Fragment,{children:(0,o.jsx)(i.Z,{onClose:()=>null==e?void 0:e.portalClose(),onAcceptMedia:e=>f(e),onDeclineMedia:()=>_(),consentData:l,setFieldValue:a,popupOptions:e})})}})};n.default=v},16184:function(e,n,l){l.d(n,{v:function(){return o}});let o="PlayMode"},8482:function(e,n,l){var o,a,i=l(52322),t=l(2784),d=l(98123),r=l(35599),s=l(76308),u=l(65573),c=l(56528);(o=a||(a={}))[o.email=-100]="email",o[o.sms=-101]="sms",o[o.post=-102]="post",o[o.phone=-103]="phone",o[o.push=-104]="push",o[o.partner=-105]="partner";let v=e=>{switch(e){case a.email:return"Email";case a.sms:return"SMS";case a.post:return"Post";case a.phone:return"Phone";case a.push:return"Push";case a.partner:return"Partner";default:return}},m=e=>{switch(e){case u.PLAY_MODES.casino:return"Casino";case u.PLAY_MODES.sport:return"Sport";case u.PLAY_MODES.bingo:return"Bingo";case u.PLAY_MODES.live:return"Live";default:return}},h=e=>{let{userConsent:n,onToggleAll:l}=e,{t:o}=(0,d.$G)(["lexicons"]),a=null==n?void 0:n.every(e=>e.Enabled);return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("div",{className:"form__line"}),(0,i.jsxs)("label",{className:"consent-check-all",children:[(0,i.jsx)(c.Z,{id:"checkbox-checkAll",checked:a,onChange:l}),o("check_all")]})]})},p=e=>{let{consentData:n,setFieldValue:l,isPopup:o=!1,isAccountDetails:u=!1,hasError:p=!1,setHasError:f}=e,[_,x]=(0,t.useState)(n),[b]=(0,t.useState)((0,r.YX)(s.q.abandon_registration_2)),{t:y}=(0,d.$G)(["lexicons"]);(0,t.useEffect)(()=>{var e;!u&&(null==b?void 0:null===(e=b.PlayerCommunicationConsent)||void 0===e?void 0:e.length)>0?x(b.PlayerCommunicationConsent):x(n)},[]),(0,t.useEffect)(()=>
1{l("PlayerCommunicationConsent",_)},[_,l]);let C=e=>null==_?void 0:_.find(n=>null===n.PlayMode&&n.CommunicationChannel===e),g=(e,n)=>null==_?void 0:_.find(l=>l.PlayMode===e&&l.CommunicationChannel===n),j=e=>{let n=C(e);p&&f&&f(!1),n&&x(e=>null==e?void 0:e.map(e=>e.Id===n.Id?{...e,Enabled:!e.Enabled}:e))},P=(e,n)=>{p&&f&&f(!1);let l=g(e,n);l&&x(e=>null==e?void 0:e.map(e=>e.Id===l.Id?{...e,Enabled:!e.Enabled}:e))},N=()=>{p&&f&&f(!1);let e=null==_?void 0:_.every(e=>e.Enabled),n=null==_?void 0:_.map(n=>({...n,Enabled:!e}));x(n)},M=null==_?void 0:_.filter(e=>null===e.PlayMode),k=null==_?void 0:_.filter(e=>null!==e.PlayMode),w=Array.from(new Set(null==k?void 0:k.map(e=>e.PlayMode))),S=Array.from(new Set(null==k?void 0:k.map(e=>e.CommunicationChannel)));return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)("div",{className:"marketing-consent ".concat(p?"form__input-wrapper__invalid":""),"data-testid":"div__MarketingConsent-marketingContainer",style:{display:"table",width:"100%",...p&&o?{marginBottom:"5px"}:{}},children:[(null==k?void 0:k.length)>0&&(0,i.jsx)("div",{className:"checkbox-grid playmode-consent-grid",children:(0,i.jsxs)("table",{className:"consent-table",children:[(0,i.jsx)("thead",{children:(0,i.jsxs)("tr",{children:[(0,i.jsx)("th",{className:"column-header"}),null==w?void 0:w.map(e=>(0,i.jsx)("th",{className:"playmode-header",children:m(e)},e))]})}),(0,i.jsx)("tbody",{children:null==S?void 0:S.map(e=>(0,i.jsxs)("tr",{children:[(0,i.jsx)("td",{className:"channel-label",children:v(e)}),null==w?void 0:w.map(n=>{let l=g(n,e);return(0,i.jsx)("td",{className:"checkbox-cell",children:l?(0,i.jsx)(c.Z,{id:"checkbox-".concat(n,"-").concat(e),checked:l.Enabled,onChange:()=>P(n,e)}):null},n)})]},e))})]})}),(null==M?void 0:M.length)>0&&(0,i.jsx)("div",{className:"global-consent-section",children:null==M?void 0:M.map(e=>e.CommunicationChannel!==a.post&&(0,i.jsx)("div",{className:"global-consent-item",children:(0,i.jsxs)("label",{children:[v(e.CommunicationChannel),":"," ",(0,i.jsx)(c.Z,{id:"checkbox-".concat(e.Id,"-").concat(e.CommunicationChannel),checked:e.Enabled,onChange:()=>j(e.CommunicationChannel)})]})},e.Id))}),(0,i.jsx)(h,{userConsent:_,onToggleAll:N})]}),p&&(0,i.jsx)("div",{className:"form__input-error consent-error-message",children:y("marketing_consent_empty_validation")})]})};n.Z=p},26702:function(e,n,l){l.d(n,{Z:function(){return s}});var o=l(52322),a=l(2784),i=l(98123),t=l(8482),d=l(66437),r=l(64622);function s(e){var n,l,s,u,c,v;let{onAcceptMedia:m,onDeclineMedia:h,onClose:p,consentData:f,setFieldValue:_,popupOptions:x}=e,[b,y]=(0,a.useState)(!1),[C,g]=(0,a.useState)(f),[j,P]=(0,a.useState)(!1),{config:N}=(0,r.useBrandConfig)(),{popup:M}=x||{},k=(0,d.qn)("".concat(null==N?void 0:null===(n=N.UrlName)||void 0===n?void 0:n.toLowerCase(),"-comConsent")),{t:w}=(0,i.$G)(["lexicons"]);(0,a.useEffect)(()=>{(null==k?void 0:k.length)>0&&g(k)},[]),(0,a.useEffect)(()=>{j&&C.some(e=>e.Enabled)&&P(!1)},[C,j]);let S=(e,n)=>{g(n)},E=()=>{if(b){if(!C.some(e=>e.Enabled)){P(!0);return}_("PlayerCommunicationConsent",C),m(C)}else h()};return(0,o.jsx)("div",{className:"modal__wrap  open",children:(0,o.jsx)("div",{className:"modal__container new",children:(0,o.jsx)("div",{className:"modal__body ",children:(0,o.jsxs)("div",{className:"modal-form__body new",children:[(0,o.jsxs)("div",{className:"modal-form__header",children:[(0,o.jsx)("div",{className:"modal-form__nav",children:(0,o.jsx)("div",{className:"modal-form__title new",children:(0,o.jsx)("span",{children:w(M?null==M?void 0:null===(l=M.Title)||void 0===l?void 0:l.Text:"opt_out_special_offers")})})}),(0,o.jsx)("div",{className:"modal-form-close-button","data-testid":"button__MediaPopupOptOutConfirmation-close",onClick:p})]}),(0,o.jsx)("div",{className:"modal-form__text new translation-format",children:w(M?null==M?void 0:null===(s=M.Body)||void 0===s?void 0:null===(u=s[0])||void 0===u?void 0:u.Text:"continue_confirmation")}),(0,o.jsx)("div",{className:"form__column",children:(0,o.jsxs)("div",{className:"form__row flex__nowrap",children:[(0,o.jsxs)("div",{className:"checkbox",children:[(0,o.jsx)("input",{id:"showInnerConsent",className:"checkbox__input","data-testid":"input__MediaPopupOptOutConfirmation-innerAgreeConsent",type:"checkbox",checked:b,onChange:()=>{y(!b)}}),(0,o.jsx)("label",{className:"checkbox__label",htmlFor:"showInnerConsent"})]}),(0,o.jsx)("span",{className:"checkbox__text form__label bigger",children:w("agree_unique_promotional_offers")})]})}),b&&(0,o.jsx)(t.Z,{consentData:(null==C?void 0:C.length)>0?C:f,setFieldValue:S,isPopup:!0,hasError:j,setHasError:e=>P(e)}),(0,o.jsx)("div",{className:"modal-form__button new",children:(0,o.jsx)("button",{className:"btn rounded",onClick:E,"data-testid":"button__MediaPopupOptOutConfirmation-continue",children:w(M?null==M?void 0:null===(c=M.Buttons)||void 0===c?void 0:null===(v=c[0])||void 0===v?void 0:v.Text:"continue")})})]})})})})}},56528:function(e,n,l){l.d(n,{Z:function(){return a}});var o=l(52322);
1function a(e){let{id:n="checkboxId",text:l,onChange:a,defaultChecked:i,sanitation:t,checked:d}=e;return(0,o.jsxs)("div",{className:"form__row flex__align-item--start",style:{flexFlow:"nowrap"},children:[(0,o.jsxs)("div",{className:"checkbox",children:[(0,o.jsx)("input",{id:n,"data-testid":"checkbox__Checkbox-input",className:"checkbox__input",type:"checkbox",checked:d,defaultChecked:i,onChange:()=>a()}),(0,o.jsx)("label",{className:"checkbox__label",htmlFor:n})]}),t?(0,o.jsx)("span",{className:"lexicons-wrapper",dangerouslySetInnerHTML:{__html:t}},"text-sanitation"):(0,o.jsx)("span",{className:"checkbox__text form__label",children:l})]})}},66437:function(e,n,l){l.d(n,{L_:function(){return d},qn:function(){return t},y9:function(){return i}});var o=l(36954),a=l.n(o);let i=(e,n)=>{let l=JSON.stringify(n),o=a().compressToBase64(encodeURI(l));null==window||window.localStorage.setItem(e,o)},t=e=>{let n=null==window?void 0:window.localStorage.getItem(e),l=decodeURI(a().decompressFromBase64(n));return l?JSON.parse(l):null},d=e=>{var n;(null==window?void 0:window.localStorage)&&(null==window?void 0:null===(n=window.localStorage)||void 0===n?void 0:n.getItem(e))&&window.localStorage.removeItem(e)}},76308:function(e,n,l){l.d(n,{q:function(){return o}});let o={abandon_registration_2:"abandon-registration-2",abandon_registration_3:"abandon-registration_3",popup_id_in_display:"popup_id_in_display"}},65573:function(e,n,l){l.r(n),l.d(n,{PLAY_MODES:function(){return a},PlayBingoMode:function(){return _},PlayCasinoMode:function(){return p},PlayLiveMode:function(){return f},PlayModeProvider:function(){return j},PlaySportsMode:function(){return h},normalizePlayMode:function(){return C},usePlayModeContext:function(){return P}});var o,a,i=l(52322),t=l(2784),d=l(97112),r=l(5632),s=l(64622),u=l(16184);let c=(e,n)=>{if(e&&n){if(e===(null==n?void 0:n.playModeNameSport))return{id:null==n?void 0:n.playModeIdSport,value:null==n?void 0:n.playModeNameSport};if(e===(null==n?void 0:n.playModeName))return{id:null==n?void 0:n.playModeId,value:null==n?void 0:n.playModeName};if(e===(null==n?void 0:n.playModeNameLive))return{id:null==n?void 0:n.playModeIdLive,value:null==n?void 0:n.playModeNameLive};if(e===(null==n?void 0:n.playModeNameBingo))return{id:null==n?void 0:n.playModeIdBingo,value:null==n?void 0:n.playModeNameBingo}}},v=(e,n,l)=>{if(!e)return!1;switch(null==e?void 0:e.value){case"sport":return null==n?void 0:n.SportEnabled;case"live":return null==n?void 0:n.LiveEnabled;case"bingo":return(null==n?void 0:n.BingoEnabled)&&(null==l?void 0:l.jurisdictionId)===721;default:return!0}};var m=l(73549);let h={id:707,value:"sport"},p={id:706,value:"casino"},f={id:912,value:"live"},_={id:911,value:"bingo"};(o=a||(a={}))[o.sport=707]="sport",o[o.casino=706]="casino",o[o.live=912]="live",o[o.bingo=911]="bingo";let x={[h.id]:h,[p.id]:p,[f.id]:f,[_.id]:_},b={[h.value]:h,[p.value]:p,[f.value]:f,[_.value]:_},y=e=>Array.isArray(e)?e[0]:e,C=e=>{if(!e)return;let n=Number(e.id);if(Number.isFinite(n)&&x[n])return x[n];let l="string"==typeof e.value?e.value.toLowerCase():void 0;if(l&&b[l])return b[l]},g=(0,t.createContext)(void 0),j=e=>{let{children:n}=e,{config:l,defaultData:o}=(0,s.useBrandConfig)(),{getSessionItem:a,addSessionItem:h}=(0,m.Z)(),x=(0,d.EE)(),b=(0,r.useRouter)(),[j,P]=(0,t.useState)({id:0,value:"Default"}),N=(0,t.useCallback)(e=>{h(u.v,e),P(e)},[h]),M=(0,t.useCallback)(()=>{try{return C(a(u.v))}catch(e){return}},[a]),k=(0,t.useCallback)(()=>{var e;let n=y(null===(e=b.query)||void 0===e?void 0:e.mode),a=C(n?c(n,x):void 0),i=null!=a?a:M(),t=null!=i?i:C({id:null==l?void 0:l.DefaultPlayMode}),d=t&&v(t,l,o)?t:p;return d},[x,o,M,b.query,l]),w=(0,t.useCallback)(e=>{b.push(e).then(()=>{"/sportsbook"===e&&setTimeout(()=>{scrollTo({top:0,left:0,behavior:"smooth"})},300)})},[b]),S=(0,t.useCallback)(e=>{var n;let l=null!==(n=C(e))&&void 0!==n?n:p;N(l)},[N]),E=(0,t.useCallback)(e=>{var n;let l=null!==(n=C(e))&&void 0!==n?n:p,o=l.value===f.value?"/live":l.value===_.value?"/bingo":l.value===p.value?"/":"/sportsbook";console.info("playMode",l),N(l),o!==(null==b?void 0:b.pathname)&&w(o)},[w,null==b?void 0:b.pathname,N]);return(0,t.useEffect)(()=>
1{if((null==b?void 0:b.isReady)&&(null==l?void 0:l.WhiteLabelId)&&(null==o?void 0:o.jurisdictionId)){let e=k();(null==e?void 0:e.id)!==(null==j?void 0:j.id)&&(console.info("[Play Mode] Determined Play Mode >>> ",e),N(e))}},[null==o?void 0:o.jurisdictionId,k,null==b?void 0:b.isReady,null==l?void 0:l.WhiteLabelId,null==j?void 0:j.id,N]),(0,i.jsx)(g.Provider,{value:{playMode:j,setPlayMode:S,navLinkRedirect:E},children:n})},P=()=>{let e=(0,t.useContext)(g);if(void 0===e)throw Error("usePlayModeContext must be used within a PlayModeProvider");return e}},91599:function(e,n,l){l.d(n,{Z:function(){return i}});var o=l(24511),a=l(11768);class i extends a.Z{constructor(e){super(),this.PlayerId=0,this.ReceiveEmail=!1,this.ReceiveSMS=!1,this.ReceivePhone=!1,this.ReceivePost=!1,this.Token="",this.PlayerCommunicationConsent=[],Object.assign(this,e)}}i.schema=o.Ry({PlayerId:o.Rx(),ReceiveEmail:o.O7(),ReceiveSMS:o.O7(),ReceivePhone:o.O7(),ReceivePost:o.O7(),Token:o.Z_(),PlayerCommunicationConsent:o.IX().of(o.Ry({Id:o.Rx(),PlayerId:o.Rx(),PlayMode:o.Rx(),CommunicationChannel:o.Rx(),Enabled:o.O7(),IsDeleted:o.O7()}))}).noUnknown()}}]);

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.