PageSourceSearch

https://www.betocean.com/betocean_candy-theme-fix/js/app-out/timeout.e6f191540dd531e4c693.chunk.js

js betocean.com collected 2026-10-01 15:44:17 UTC 11,919 bytes, 2 lines download raw bytes

1export const __webpack_id__=2728;export const __webpack_ids__=[2728];export const __webpack_modules__={17130:(e,t,i)=>{i.r(t),i.d(t,{Timeout:()=>fe,TimeoutBare:()=>ve,default:()=>ye});var o={};i.r(o),i.d(o,{defaultState:()=>w,reducer:()=>R});var n=i(63412),a=i.n(n),r=i(74848),s=i(96540),c=i(90952),l=i(86624),u=i(15245),d=i(30514),p=i(15424),m=i(75132),b=i(76860),T=i(29994),v=i(37489),f=i(35103),y=i(84974),h=i(46792),E=i(53108),_=i(23745),O=i(53806),g=i(19611),x=function(e,t,i,o){return new(i||(i=Promise))((function(n,a){function r(e){try{c(o.next(e))}catch(e){a(e)}}function s(e){try{c(o.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):function(e){return e instanceof i?e:new i((function(t){t(e)}))}(e.value).then(r,s)}c((o=o.apply(e,t||[])).next())}))};var N;!function(e){e.SET_ERROR="TIMEOUT:ERROR:SET",e.TOGGLE_LOADING="TIMEOUT:LOADING:TOGGLE",e.SET_TIMEOUT_SETTINGS="TIMEOUT:SETTINGS:SET",e.SET_PLAYER_TIMEOUTS="TIMEOUT:PLAYER_TIMEOUTS:SET"}(N||(N={}));const S=e=>({type:N.TOGGLE_LOADING,payload:e}),P=e=>({type:N.SET_ERROR,payload:e});var j=i(74294),I=i(1932);const w={error:"",isLoading:!0,isEnabled:!1,availablePeriods:[],usePlayerDefinedPeriods:!1,availableProducts:[],activeTimeouts:[]},R=e=>(0,I.jM)(((t,i)=>{switch(i.type){case N.TOGGLE_LOADING:case N.TOGGLE_LOADING+e:t.isLoading=i.payload;break;case N.SET_ERROR:case N.SET_ERROR+e:t.error=i.payload;break;case N.SET_TIMEOUT_SETTINGS:case N.SET_TIMEOUT_SETTINGS+e:Object.assign(t,Object.assign(Object.assign({},i.payload),{isEnabled:Boolean(i.payload.enabled)}));break;case N.SET_PLAYER_TIMEOUTS:case N.SET_PLAYER_TIMEOUTS+e:Object.assign(t,i.payload)}}),w),{withDynamicReducer:U,useDynamicReducerSelector:k,useDynamicReducerDispatch:$}=(0,j.X)("Timeout",o);var D=function(e,t,i,o){return new(i||(i=Promise))((function(n,a){function r(e){try{c(o.next(e))}catch(e){a(e)}}function s(e){try{c(o.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):function(e){return e instanceof i?e:new i((function(t){t(e)}))}(e.value).then(r,s)}c((o=o.apply(e,t||[])).next())}))};const G=()=>{const e=$(),{showComponentError:t}=(0,y.zi)(),i=(0,h.k)(),o=(()=>{const e=(0,O.B)();return(0,s.useCallback)((t=>x(void 0,[t],void 0,(function*({count:t}){const{data:i}=yield e({ID:89909,responses:[89911,89900],description:"Get player timeout",count:t,correlationId:(0,_.NF)(`${g.cM}-`)});return i}))),[e])})(),n=(0,E.Z)();return(0,s.useCallback)((a=>D(void 0,void 0,void 0,(function*(){!a&&e(S(!0));try{const{timeouts:t=[]}=yield o({count:3}),n=t.filter((e=>"ACTIVE"===e.state));n.length&&e((e=>({type:N.SET_PLAYER_TIMEOUTS,payload:e}))({activeTimeouts:n.map((e=>Object.assign(Object.assign({},e),{startTime:i.getDateTimeLong(i.parseImsDate(e.startTime)),endTime:i.getDateTimeLong(i.parseImsDate(e.endTime))})))}))}catch(e){t(n(e))}finally{!a&&e(S(!1))}}))),[e,i,n,o,t])};var L=i(96080),M=i(22027),A=function(e,t,i,o){return new(i||(i=Promise))((function(n,a){function r(e){try{c(o.next(e))}catch(e){a(e)}}function s(e){try{c(o.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):function(e){return e instanceof i?e:new i((function(t){t(e)}))}(e.value).then(r,s)}c((o=o.apply(e,t||[])).next())}))};const C=()=>{const e=$(),{showComponentError:t}=(0,y.zi)(),i=(0,L.x)(),o=(0,E.Z)(),n=G();return(0,s.useCallback)((()=>A(void 0,void 0,void 0,(function*(){e(S(!0));try{const{timeoutConfigurationItems:t}=yield i({type:[M.IB.TIMEOUT]});if(e((e=>({type:N.SET_TIMEOUT_SETTINGS,payload:e}))(t[0])),!t[0].enabled)return;yield n(!0)}catch(e){t(o(e))}finally{e(S(!1))}}))),[e,o,t,i,n])},V={permanent:0x8000000000000000,months:2592e3,weeks:604800,days:86400,hours:3600},B=(e="",t)=>{const i=Number(t);return i*(V[e]||1)||i},F=e=>{for(const[t,i]of Object.entries(V))if(e>=i&&e%i==0)return{period:e/i,unit:t};return{period:e,unit:"seconds"}};var Y=i(66229),z=i(27411),H=i(83312),Z=function(e,t,i,o){return new(i||(i=Promise))((function(n,a){function r(e){try{c(o.next(e))}catch(e){a(e)}}function s(e){try{c(o.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):function(e){return e instanceof i?e:new i((function(t){t(e)}))}(e.value).then(r,s)}c((o=o.apply(e,t||[])).next())}))};var X=i(18336),q=i(55059),J=function(e,t,i,o){return new(i||(i=Prom
1ise))((function(n,a){function r(e){try{c(o.next(e))}catch(e){a(e)}}function s(e){try{c(o.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):function(e){return e instanceof i?e:new i((function(t){t(e)}))}(e.value).then(r,s)}c((o=o.apply(e,t||[])).next())}))};const K=()=>{const e=(0,Y.wA)(),t=(0,z.a)(),i=G(),o=(0,E.Z)(),n=(0,y.NR)(),{displayPopup:r,enablePromotionalOptOut:c}=(0,y.TP)(),l=(0,H.a)(),u=(()=>{const e=(0,O.B)();return(0,s.useCallback)((t=>Z(void 0,[t],void 0,(function*({startTime:t,period:i,emailNotificationType:o,timeoutId:n,networkClass:a,product:r}){const{data:s}=yield e(Object.assign(Object.assign(Object.assign(Object.assign({ID:89910,responses:[89912,89900],description:"Set player timeout",period:i,correlationId:(0,_.NF)(`${g.cM}-`),product:r},t&&{startTime:t}),n&&{timeoutId:n}),a&&{networkClass:a}),o&&{emailNotificationType:o}));return s}))),[e])})(),d=(0,q.H)(),{availableProducts:p,activeTimeouts:m}=k(a()(["availableProducts","activeTimeouts"])),b=(0,s.useCallback)(((t,a)=>J(void 0,void 0,void 0,(function*(){try{const{period:e="",preference:o,product:r,periodValue:s,periodUnit:b}=t,T=r||p.filter((e=>null==m?void 0:m.every((t=>t.product!==e))))[0];yield u({emailNotificationType:["START"],period:b&&s?String(B(b,s)):e,product:T}),c&&o&&(yield d([{channel:"all",type:"promotional",preference:!1,product:"all"===T?"casino, poker, bingo, sportsbook, live":T}])),yield i(),a.restart(),l(n("success"),{variant:"success"})}catch(t){e(P(o(t)))}}))),[e,n,o,c,u,l,d,i,m,p]);return(0,s.useCallback)(((i,o)=>J(void 0,void 0,void 0,(function*(){t()&&(e(P("")),r?e((0,X.HC)({onAccept:()=>J(void 0,void 0,void 0,(function*(){return yield b(i,o)})),acceptBtnText:n("popup.button.confirm"),declineBtnText:n("popup.button.cancel"),content:n("popup.content")})):yield b(i,o))}))),[n,e,t,r,b])};var Q=i(45932),W=i.n(Q),ee=i(57182);const te=()=>{const e=(0,ee.N)(),t=k(W()("availablePeriods"));return(0,s.useCallback)((i=>{const{periodValue:o,periodUnit:n=""}=i,a=o?B(n,o):0,[r,s]=t;if(!o)return{periodValue:e("period.error.required")};if(Number(o)<=0||!Number.isInteger(Number(o)))return{periodValue:e("period.error.positive")};if(Number(o)>=1e3)return{periodValue:e("period.error.tooBig")};if(a<r&&s===V.permanent){const{period:i,unit:o}=F(t[0]);return{periodValue:e("period.error.tooSmall",[`${i} ${e(`periodUnit.validate.${o}`)}`])}}if(a<r||a>s){const t=[r,s].map(F).map((t=>`${t.period} ${e(`periodUnit.validate.${t.unit}`)}`));return{periodValue:e("period.error.between",t)}}}),[e,t])},ie="ActiveTimeouts__activeTimeoutsTitle--1P5",oe="ActiveTimeouts__activeTimeout--3CO",ne="ActiveTimeouts__activeTimeoutProduct--XGD",ae=()=>{const e=(0,y.NR)(),t=k(W()("activeTimeouts"));return(null==t?void 0:t.length)?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("h3",{className:`${ie} cms-timeout-active-timeouts-title`,children:e("activeTimeout.title")}),null==t?void 0:t.map((t=>(0,r.jsxs)("div",{className:`${oe} cms-timeout-active-timeout`,children:[(0,r.jsx)("span",{className:ne,children:e(`activeTimeout.product.${t.product}`)}),(0,r.jsx)("span",{children:e("activeTimeout.until",[t.endTime])})]},t.product)))]}):null};var re=i(64853);const se="TimeoutEndMessage__timeoutEnd--1rF",ce=({values:e,submitError:t})=>{const i=(0,y.NR)(),{getDateTimeShort:o}=(0,h.k)(),n=te(),a=k(W()("usePlayerDefinedPeriods")),c=!n(e)||!a,{periodValue:l,periodUnit:u,period:d}=e,p=!l&&!d||!c||t,[m,b]=(0,s.useState)(""),T=l?B(u,l):d;return(0,s.useEffect)((()=>{if(p||Number(d)===V.permanent)return void b("");const e=()=>b(((e=0,t)=>{const i=new Date;return i.setSeconds(i.getSeconds()+Number(e)),t(i)})(T,o));e();const t=setInterval(e,6e4);return()=>clearInterval(t)}),[p,d,o,T]),p?null:Number(d)===V.permanent?(0,r.jsx)(re.A,{message:i("timeoutEnd.permanent"),className:`${se} cms-timeout-timeout-end-warning`}):(0,r.jsx)(re.A,{message:i("timeoutEnd",[m]),className:`${se} cms-timeout-timeout-end-warning`})},le="Timeout__container--uH9",ue="Timeout__description--3h0",de="Timeout__error--oQg",pe="Timeout__control--3xu",me="Timeout__controls--1x7",be="Timeout__submit--2OJ";
1var Te=function(e,t,i,o){return new(i||(i=Promise))((function(n,a){function r(e){try{c(o.next(e))}catch(e){a(e)}}function s(e){try{c(o.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):function(e){return e instanceof i?e:new i((function(t){t(e)}))}(e.value).then(r,s)}c((o=o.apply(e,t||[])).next())}))};const ve=()=>{const e=(0,y.NR)(),t=C(),i=K(),{showComponentMessage:o}=(0,y.zi)(),{products:n,availablePeriodsParsed:v,periodUnits:h}=(()=>{const e=(0,y.NR)(),{availablePeriods:t,availableProducts:i,activeTimeouts:o}=k(a()(["availablePeriods","availableProducts","activeTimeouts"]));return(0,s.useMemo)((()=>({products:i.filter((e=>null==o?void 0:o.every((t=>t.product!==e)))).map((t=>({label:e(`product.${t}`),value:t}))),availablePeriodsParsed:t.map((t=>{const{period:i,unit:o}=F(t);return{label:e(`period.${o}`,[i]),value:t}})),periodUnits:["hours","days","weeks","months"].map((t=>({label:e(`periodUnit.${t}`),value:t})))})),[i,o,t,e])})(),{enablePromotionalOptOut:E}=(0,y.TP)(),{error:_,isLoading:O,isEnabled:g,availableProducts:x,usePlayerDefinedPeriods:N}=k(a()(["error","isEnabled","isLoading","availableProducts","usePlayerDefinedPeriods"])),S=(0,s.useMemo)((()=>Object.assign(Object.assign({},N&&{periodUnit:"hours"}),n.length&&{product:n[0].value})),[n,N]),P=te();return(0,s.useEffect)((()=>{(()=>{Te(void 0,void 0,void 0,(function*(){yield t()}))})()}),[t]),(0,s.useEffect)((()=>{g||O||o(e("disabledComponent"))}),[g,O,e,o]),O?(0,r.jsx)(d.a,{}):(0,r.jsx)("div",{className:`${le} cms-timeout-container`,children:(0,r.jsx)(l.l,Object.assign({},N&&{validate:P},{formName:"TIMEOUT",onSubmit:i,validateOnBlur:!1,initialValues:S,render:({submitting:t,handleSubmit:i,submitError:o,values:a})=>(0,r.jsxs)("form",{onSubmit:e=>e.preventDefault(),className:"cms-timeout-form",children:[(0,r.jsx)(c.Pc,{subscription:{values:!0},children:({values:e})=>(0,r.jsx)(ce,{values:e,submitError:o})}),o||_&&(0,r.jsx)(f.W,{className:de,message:o||_}),(0,r.jsx)(u.F,{tagName:"p",t:e,tKey:"description",className:ue}),Boolean(n.length)&&(0,r.jsxs)(r.Fragment,{children:[x.length>1&&(0,r.jsx)(b.l,{name:"product",options:n,disabled:t,label:e("product.label"),className:`${pe} cms-timeout-product`,"aria-label":e(["product.label","playtech.mobile.system.select.aria-label"])}),!N&&(0,r.jsx)(b.l,{name:"period",disabled:t,options:v,label:e("period.label"),placeholder:e("period.placeholder"),className:`${pe} cms-timeout-select cms-timeout-period`,"aria-label":e(["period.label","playtech.mobile.system.select.aria-label"])}),N&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(m.p,{name:"periodValue",id:"periodValue",className:`${pe} cms-timeout-period-value`,label:e("periodValue.label"),placeholder:e("periodValue.placeholder"),"aria-label":e(["periodValue.label","periodValue.placeholder","playtech.mobile.system.input.aria-label"])}),(0,r.jsx)(b.l,{name:"periodUnit",disabled:t,options:h,label:e("periodUnit.label"),className:`${pe} cms-timeout-period-unit`,"aria-label":e(["periodUnit.label","playtech.mobile.system.select.aria-label"])})]}),E&&(0,r.jsx)(T.S,{name:"preference",label:e("preference.label"),disabled:t||!a.period&&!a.periodValue,className:`${pe} cms-timeout-checkbox`,"aria-label":e(["preference.label","playtech.mobile.system.checkbox.aria-label"])}),(0,r.jsx)("div",{className:me,children:(0,r.jsx)(p.$,{isNew:!0,size:"large",type:"button",onClick:i,className:`${be} cms-timeout-submit`,disabled:t||!a.period&&!a.periodValue,children:e("button.submit")})})]}),(0,r.jsx)(ae,{})]})}))})},fe=(0,v.m)({isForLoggedIn:!0,tkPrefix:"playtech.mobile.timeout."})(U()(ve)),ye=fe}};
2//# sourceMappingURL=timeout.e6f191540dd531e4c693.chunk.js.map

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.