/*! For license information please see 366.25a20db2d6bd574ba122.js.LICENSE.txt */ "use strict";(self.webpackChunkchat=self.webpackChunkchat||[]).push([[366],{2517:(e,t,n)=>{n.d(t,{T:()=>i});var r=n(7489),o=n(3190),i={SendMessage:function(e){var t=e.content,n=void 0===t?"":t,i=e.type,a=void 0===i?0:i,s=e.baseMessageId,c=void 0===s?null:s,l=e.timeStamp,u=e.sign;this.name=o.Hj.SendMessage,this.model={content:n,type:a,baseMessageId:c,timeStamp:l,sign:u},this.messagePackModel=(0,r.parseObjectToArray)([a,n,c,u,l])},LikeMessage:function(e){var t=e.messageId,n=void 0===t?0:t;this.name=o.Hj.LikeMessage,this.model={messageId:n},this.messagePackModel=(0,r.parseObjectToArray)([n])},UnLikeMessage:function(e){var t=e.messageId,n=void 0===t?0:t;this.name=o.Hj.UnLikeMessage,this.model={messageId:n},this.messagePackModel=(0,r.parseObjectToArray)([n])},UpdatePlayer:function(e){var t=e.nickName,n=void 0===t?null:t,i=e.defaultAvatarId,a=void 0===i?0:i;this.name=o.Hj.UpdatePlayer,this.model={nickName:n,defaultAvatarId:a},this.messagePackModel=(0,r.parseObjectToArray)([n,a])}}},11:(e,t,n)=>{n.d(t,{A:()=>W});var r=n(4914),o=n(678),i=n(8874),a=n.n(i),s=n(3444),c=n.n(s),l=n(4380),u=n.n(l),d=n(4115),f=n.n(d),m=n(3566),p=n.n(m),h=n(8402),g=n.n(h),y=n(7800),b=n(2153),v=n(4228),w=n(3190),j=n(1069),x=n(4848),k=a().div.withConfig({componentId:"sc-139wzdv-0"})(["position:absolute;bottom:0;left:0;width:100%;z-index:3;overflow:hidden;border-radius:0.5em 0.5em 1em 1em;"]),I=a().div.withConfig({componentId:"sc-139wzdv-1"})(["padding:0.75em 1em;background:#121212;"]),S=a().button.withConfig({componentId:"sc-139wzdv-2"})(["display:flex;align-items:center;justify-content:center;width:100%;cursor:pointer;border-radius:1.5em;padding:",';font-size:1em;border:1px solid;position:relative;&:nth-of-type(1){background:#1f1f1f;border-color:#454545;}&:nth-of-type(2){border-color:rgba(255,132,37,0.24);background:radial-gradient(50% 100% at 50% -0%,rgba(255,132,37,0.23) 0%,rgba(255,132,37,0) 100%);&:before{content:"";position:absolute;top:0;left:0;height:1px;width:100%;background:radial-gradient(50% 50% at 50% 50%,#ff8425 0%,rgba(255,132,37,0) 100%);}}'],w.Fr?"1em":"0.875em"),C=a().div.withConfig({componentId:"sc-139wzdv-3"})(['display:flex;align-items:center;gap:0.75em;padding:0.75em 1em;position:relative;background:#141414;&:before{content:"";position:absolute;top:0;left:0;height:0.125em;width:100%;background:radial-gradient(50% 100% at 50% 0%,#ff5c25 0%,rgba(255,92,37,0) 100%);}']),O=a().span.withConfig({componentId:"sc-139wzdv-4"})(["color:rgb(var(--white));text-transform:uppercase;font:0.75em/1 var(--mainFontMedium);"]);function T(e){var t=e.style,n=(0,o.useDispatch)(),r=(0,y.shallowSelector)(b.vR),i=(0,y.shallowSelector)(y.selectResources),a=i.strDecline,s=i.strSend;return!r||w.wY?null:(0,x.jsxs)(k,{style:t.container,children:[(0,x.jsx)(I,{style:t.bigWin,children:(0,x.jsx)(j.A,{style:t.messageByType,message:{content:"x".concat(Number(null==r?void 0:r.toFixed(2))),gameType:w.GN,type:w.TQ.ShareWin}})}),(0,x.jsxs)(C,{style:t.actions,children:[(0,x.jsx)(S,{style:t.button,type:"button",onClick:function(){n(b.o1.setSharedBigWinCoeff(0))},children:(0,x.jsx)(O,{style:t.btnTxt,children:a||"_Decline"})}),(0,x.jsx)(S,{style:t.button,type:"button",onClick:function(){(0,v._z)({content:"x".concat(Number(null==r?void 0:r.toFixed(2))),type:w.TQ.ShareWin,baseMessageId:null}),n(b.o1.setSharedBigWinCoeff(0))},children:(0,x.jsx)(O,{style:t.btnTxt,children:s||"_Send"})})]})]})}const A=(0,r.memo)(T);T.defaultProps={style:{container:{},bigWin:{},messageByType:{},actions:{},button:{},btnTxt:{}}},T.propTypes={style:c().object};var M=n(7420);function P(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n{n.d(t,{A:()=>A});var r=n(4914),o=n(8874),i=n.n(o),a=n(3444),s=n.n(a),c=n(7800),l=n(5094),u=n.n(l),d=n(3190),f=n(4848);function m(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n140,T=(n=(0,r.useState)(!1),o=2,function(e){if(Array.isArray(e))return e}(n)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,s=[],c=!0,l=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,o=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw o}}return s}}(n,o)||function(e,t){if(e){if("string"==typeof e)return m(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?m(e,t):void 0}}(n,o)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),A=T[0],M=T[1],P=(0,c.shallowSelector)(c.selectResources),B=P.strWinningOdd,E=P.strSeeMore,_=P.strHide,L=d.Fr&&!u()(),N=a.content;switch(a.type){case d.TQ.Text:return(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(k,{isInput:l,isRepliedMessage:s,buttonState:A,children:N}),g&&(0,f.jsx)(S,{children:(0,f.jsx)(C,{type:"button",onClick:function(){M((function(e){return!e}))},children:(0,f.jsx)(O,{children:A?_||"_Hide":E||"_See More"})})})]});case d.TQ.Gif:return(0,f.jsx)(y,{isSmall:s,children:(0,f.jsx)(p,{src:N,alt:"gif"})});case d.TQ.Emoji:return(0,f.jsx)(b,{isSmall:s,children:(0,f.jsx)(h,{src:N,alt:"emoji"})});case d.TQ.ShareWin:var F=a.gameType,U="".concat("https://nar-fg.cchhllpp.net/prd","/images/chat/").concat(L?"landscape":"global","/bigWin/").concat("string"==typeof F?F.toLowerCase():d.GN.toLowerCase(),"ShareWin.webp");return(0,f.jsxs)(v,{style:i.shareBigWin,isLandscape:L,children:[(0,f.jsx)(w,{style:i.shareBigWinImg,src:U,alt:"bigWin"}),(0,f.jsxs)(j,{style:i.shareBigWinInfo,children:[(0,f.jsx)(x,{style:i.shareBigWinCoeff,children:N}),(0,f.jsx)(I,{style:i.shareBigWinText,children:B||"_Winning Odd"})]})]})}}const A=(0,r.memo)(T);T.defaultProps={style:{shareBigWin:{},shareBigWinImg:{},shareBigWinInfo:{},shareBigWinCoeff:{},shareBigWinText:{}},message:{},isSmall:!1,isInput:!1},T.propTypes={style:s().object,message:s().object,isSmall:s().bool,isInput:s().bool}},5108:(e,t,n)=>{n.d(t,{A:()=>te});var r=n(4914),o=n(678),i=n(8874),a=n.n(i),s=n(3444),c=n.n(s),l=n(1118),u=n.n(l),d=n(7800),f=n(2153),m=n(6316),p=n.n(m),h=n(8739),g=n.n(h),y=n(9720),b=n.n(y),v=n(6295),w=n(5094),j=n.n(w),x=n(3190),k=n(4228),I=n(1069),S=n(4848),C=(0,v.getIsMobile)(),O=a().div.withConfig({componentId:"sc-1tebu7b-0"})(['position:absolute;top:0;left:0;width:100%;height:100%;display:flex;align-items:center;justify-content:center;border-radius:1em;border:0 none;background:radial-gradient(50% 50% at 50% 50%,rgb(104,21,21) 0%,rgba(41,7,7,0.7) 100%);z-index:1;overflow:hidden;backdrop-filter:blur(3px);&:after{content:"";position:absolute;bottom:0;left:50%;transform:translateX(-50%);background:radial-gradient(49.85% 100% at 50.15% 100%,#ff9191 0%,transparent 100%);mix-blend-mode:color-dodge;width:75%;height:0.875em;}']),T=a().span.withConfig({componentId:"sc-1tebu7b-1"})(["color:var(--white);font:0.75em/1.375 var(--mainFontBold);text-align:center;max-width:",";"],C?"55%":"65%");function A(e){var t=e.style,n=(0,d.shallowSelector)(d.selectResources).strMessageWasBlocked;return(0,S.jsx)(O,{style:t.container,children:(0,S.jsx)(T,{style:t.text,children:n||"_Your message was blocked because of Chat rules violation."})})}const M=(0,r.memo)(A);A.defaultProps={style:{container:{},text:{}}},A.propTypes={style:c().object};var P=n(7420),B="".concat("https://nar-fg.cchhllpp.net/prd","/images/chat/global/loudspeaker.webp"),E=a().div.withConfig({componentId:"sc-pw5lk7-0"})(["display:flex;align-items:center;justify-content:space-between;padding-bottom:0.5em;border-bottom:1px solid rgba(73,73,73,0.32);"]),_=(0,r.memo)(a().div.withConfig({componentId:"sc-pw5lk7-1"})(["position:relative;border-radius:1em;border:1px solid #383838;padding:0.5em;margin-bottom:1em;min-height:5.125em;background:#262626;"," &.personalMessage{border-color:#e65e32;background:rgba(230,94,50,0.08);margin-left:auto;&.influencerMessage{border-color:#e65e32;background:url(",") no-repeat top right/10.625em 6.25em,rgba(230,94,50,0.08);}","{border-bottom:1px solid rgba(217,81,40,0.32);}}&.influencerMessage{border-color:#383838;background:url(",") no-repeat top right/10.625em 6.25em,#3d3d3d;}&.blockedMessage{border-color:#a02222;}"],(function(e){return e.isLandscape&&(0,i.css)(["width:28.875em;"])}),B,E,B)),L=(0,r.memo)(a().div.withConfig({componentId:"sc-pw5lk7-2"})(["padding-top:0.5em;"])),N=(0,r.memo)(a().div.withConfig({componentId:"sc-pw5lk7-3"})(["display:flex;align-items:center;"])),F=(0,r.memo)(a().img.withConfig({componentId:"sc-pw5lk7-4"})(["width:1.5em;height:1.5em;border-radius:50%;margin-right:0.5em;"])),U=(0,r.memo)(a().div.withConfig({componentId:"sc-pw5lk7-5"})(["display:flex;flex-direction:column;justify-content:center;"])),R=(0,r.memo)(a().span.withConfig({componentId:"sc-pw5lk7-6"})(["color:rgb(var(--white));font:0.75em/1.2 var(--mainFont);"])),D=(0,r.memo)(a().span.withConfig({componentId:"sc-pw5lk7-7"})(["color:rgba(var(--white),0.48);font:0.625em/1.2 var(--mainFont);"])),W=(0,r.memo)(a().div.withConfig({componentId:"sc-pw5lk7-8"})(["display:flex;align-items:center;gap:0.5em;"])),z=(0,r.memo)(a().button.withConfig({componentId:"sc-pw5lk7-9"})(["display:flex;align-items:center;justify-content:center;flex:1 0 1.875em;height:1.5em;background:rgba(94,94,94,0.2);border:1px solid rgba(97,97,97,0.2);font-size:1em;border-radius:1em;padding:0.25em 0.5em;cursor:pointer;&.isLiked{background:#812c2c;border:1px solid rgba(255,141,141,0.2);}"])),G=a().span.withConfig({componentId:"sc-pw5lk7-10"})(["height:0.875em;width:0.875em;flex:0 0 0.875em;"]),H=(0,r.memo)(a().span.withConfig({componentId:"sc-pw5lk7-11"})(["color:rgb(var(--white));margin-left:0.33em;font:0.75em var(--mainFont);"])),Q=(0,r.memo)(a().span.withConfig({componentId:"sc-pw5lk7-12"})(["height:1.25em;width:1.25em;margin-right:0.5em;"])),Y=function(e){var t=e.message,n=e.style;if(t.hidden)return null;var r=(0,o.useDispatch)(),i=(0,d.shallowSelector)(f.St),a=i.nickName,s=i.isBlocked,c=x.Fr&&!j()();return(0,S.jsxs)(_,{isLandscape:c,style:n.messageItem,className:"\n\t\t\t\t\t".concat(t.nickName===a?"personalMessage":""," \n\t\t\t\t\t").concat(t.isInfluencer?"influencerMessage":"","\n\t\t\t\t\t").concat(t.profanityCount>0||t.containsProfanity?"blockedMessage":""),children:[(t.profanityCount>0||t.containsProfanity)&&(0,S.jsx)(M,{style:n.blockedMessage}),(0,S.jsxs)(E,{style:n.messageHeader,children:[(0,S.jsxs)(N,{style:n.messageUserInfoBlock,children:[t.isInfluencer&&(0,S.jsx)(Q,{style:n.messageInfluencerIcon,children:(0,S.jsx)(b(),{})}),(0,S.jsx)(F,{style:n.messageUserAvatar,src:t.avatarUrl,alt:"Avatar"}),(0,S.jsxs)(U,{style:n.messageUserInfo,children:[(0,S.jsx)(R,{style:n.messageUserName,children:(null==t?void 0:t.nickName)||"_User"}),(0,S.jsx)(D,{style:n.messageTime,children:(0,v.getFormattedTime)(null==t?void 0:t.date)||"_date"})]})]}),!s&&a&&(0,S.jsxs)(W,{style:n.messageActionsBlock,children:[(0,S.jsx)(z,{style:n.messageAction,type:"button",onClick:function(){return e=t,void r(f.o1.setReplyMessage(e));var e},children:(0,S.jsx)(G,{children:(0,S.jsx)(g(),{})})},"r_".concat(t.id)),(0,S.jsxs)(z,{style:n.messageAction,type:"button",className:t.isLiked?"isLiked":"",onClick:function(){return e=null==t?void 0:t.id,n=t.isLiked,r(f.o1.setUserLikedMessages(e)),void(n?(0,k.iG)({messageId:e}):(0,k.x8)({messageId:e}));var e,n},children:[(0,S.jsx)(G,{children:(0,S.jsx)(p(),{fillColor:t.isLiked?"#ff6666":"transparent",color:t.isLiked?"#ff6666":"rgb(var(--white))"})}),!!t.likeCount&&(0,S.jsx)(H,{children:t.likeCount})]},"l_".concat(t.id))]})]}),(0,S.jsxs)(L,{style:n.messageBody,children:[t.baseMessage?(0,S.jsx)(P.A,{style:n.repliedMessageBlock,message:t.baseMessage,isSmall:!0}):null,(0,S.jsx)(I.A,{style:n.messageByType,message:t})]})]})};const q=(0,r.memo)(Y);function $(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,s=[],c=!0,l=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,o=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw o}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return X(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?X(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function X(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=r-20)},onClick:k,onTouchStart:k,children:[a.map((function(e){return(0,S.jsx)(q,{message:e},e.id)})),p&&(0,S.jsxs)(K,{style:t.newMessageBtn,type:"button",onClick:x,children:[(0,S.jsx)(Z,{style:t.newMessageBtnText,children:c||"_New message"}),(0,S.jsx)(V,{style:t.chatArrowIconBlock,children:(0,S.jsx)(u(),{})})]})]})}ee.defaultProps={style:{container:{},messageItem:{},messageHeader:{},messageUserInfoBlock:{},messageInfluencerIcon:{},messageUserAvatar:{},messageUserInfo:{},messageUserName:{},messageTime:{},messageActionsBlock:{},messageAction:{},messageBody:{},messageByType:{},newMessageBtn:{},chatArrowIconBlock:{},newMessageBtnText:{}}},ee.propTypes={style:c().object};const te=(0,r.memo)(ee)},7420:(e,t,n)=>{n.d(t,{A:()=>T});var r=n(4914),o=n(8874),i=n.n(o),a=n(3444),s=n.n(a),c=n(678),l=n(6856),u=n.n(l),d=n(2677),f=n.n(d),m=n(7800),p=n(1069),h=n(2153),g=n(3190),y=n(4848);function b(e){return b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},b(e)}function v(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var w=i().div.withConfig({componentId:"sc-m5a6mp-0"})(["display:flex;align-items:center;width:100%;"]),j=i().div.withConfig({componentId:"sc-m5a6mp-1"})(["display:flex;flex-direction:column;width:100%;"]),x=i().button.withConfig({componentId:"sc-m5a6mp-2"})(["width:1.625em;height:1.625em;background:transparent;font-size:1em;border:none;cursor:pointer;padding:0;position:absolute;top:50%;transform:translateY(-50%);right:0.5em;"]),k=i().div.withConfig({componentId:"sc-m5a6mp-3"})(["display:flex;align-items:center;margin-bottom:0.25em;"]),I=i().div.withConfig({componentId:"sc-m5a6mp-4"})(["display:flex;align-items:center;justify-content:space-between;padding:0.25em 0.5em;border-radius:0.25em 0.5em 0.5em 0.25em;background:rgba(var(--white),0.16);border-left:0.25em solid rgb(var(--white));margin-bottom:0.5em;position:relative;"," "," "," ",""],(function(e){return e.isInput&&(0,o.css)(["margin-bottom:0;border-radius:0.25em 0.5em 0 0;","{max-width:calc(100% - 1.75em);}"],j)}),(function(e){return(e.messageType===g.TQ.Emoji||e.messageType===g.TQ.Gif)&&(0,o.css)(["","{flex-direction:row-reverse;justify-content:flex-end;}"],j)}),(function(e){return!e.isInput&&(e.messageType===g.TQ.Emoji||e.messageType===g.TQ.Gif)&&(0,o.css)(["","{margin-bottom:0;}"],k)}),(function(e){return e.messageType===g.TQ.ShareWin&&(0,o.css)(["padding:0.5em;","{margin-bottom:1em;}","{width:100%;max-width:100%;}","{top:0.5em;transform:translateY(0);}"],k,j,x)})),S=(0,r.memo)(i().span.withConfig({componentId:"sc-m5a6mp-5"})(["display:inline-block;height:1em;width:1em;margin-right:0.5em;"])),C=(0,r.memo)(i().p.withConfig({componentId:"sc-m5a6mp-6"})(["color:rgb(var(--white));font:0.75em var(--mainFont);margin:0;"]));function O(e){var t=e.message,n=e.style,r=e.isInput,o=e.isSmall,i=function(e){for(var t=1;t{n.d(t,{A:()=>ee});var r=n(4914),o=n(8874),i=n.n(o),a=n(3444),s=n.n(a),c=n(6789),l=n.n(c),u=n(3566),d=n.n(u),f=n(678),m=n(4134),p=n(1061),h=n.n(p),g=n(5094),y=n.n(g),b=n(7800),v=n(4228),w=n(3190),j=n(2153),x=n(4848);function k(e){return k="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},k(e)}function I(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function S(e){for(var t=1;t=0;--i){var a=this.tryEntries[i],s=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var c=r.call(a,"catchLoc"),l=r.call(a,"finallyLoc");if(c&&l){if(this.prev=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),P(n),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var o=r.arg;P(n)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:E(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),g}},t}function O(e){return function(e){if(Array.isArray(e))return P(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||M(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function T(e,t,n,r,o,i,a){try{var s=e[i](a),c=s.value}catch(e){return void n(e)}s.done?t(c):Promise.resolve(c).then(r,o)}function A(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,s=[],c=!0,l=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,o=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw o}}return s}}(e,t)||M(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function M(e,t){if(e){if("string"==typeof e)return P(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?P(e,t):void 0}}function P(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n div{width:calc((100% / 3) - 0.25em);img{width:100%;max-width:100%;object-fit:cover;}}"],w.Fr?"8.5625em":"8.6875em"),N=(0,r.memo)(i().img.withConfig({componentId:"sc-fortkv-3"})(["height:",";width:calc((100% / 3) - 0.25em);",""],w.Fr?"7.25em":"6.25em",(function(e){return e.isLandscape&&(0,o.css)(["width:calc((100% / 4) - 0.25em);"])}))),F=i().div.withConfig({componentId:"sc-fortkv-4"})(["position:relative;margin:0 0.5em;"]),U=i().div.withConfig({componentId:"sc-fortkv-5"})(["display:flex;align-content:center;justify-content:center;margin:1em 0;height:",";"],w.Fr?"1.125em":"1em"),R=i().span.withConfig({componentId:"sc-fortkv-6"})(["position:absolute;height:1.125em;width:1.125em;left:0.5em;top:50%;transform:translateY(-50%);"]),D=i().input.withConfig({componentId:"sc-fortkv-7"})(["border-radius:0.5em;background:#1a1a1a;color:#d1d1d1;font:0.875em var(--mainFontLight);height:2.5em;padding:0.57em 0.5em 0.5em 2.4em;text-align:start;border:none;width:100%;outline:none;"]);function W(e){var t=e.style,n=(0,f.useDispatch)(),o=(0,r.useRef)(null),i=A((0,r.useState)(""),2),a=i[0],s=i[1],c=A((0,r.useState)(0),2),l=c[0],u=c[1],d=A((0,r.useState)(!1),2),m=d[0],p=d[1],g=w.Fr&&!y()(),k=A((0,r.useState)([]),2),I=k[0],M=k[1],P=(0,f.useSelector)(j.Rk),W=(0,b.shallowSelector)(b.selectResources).strSearchGIF,z="".concat("https://nar-fg.cchhllpp.net/prd","/images/chat/").concat(w.Fr?"mobile":"desktop","/poweredByGiphy.webp"),G=function(){var e,t=(e=C().mark((function e(t){var n,r,o,i,a,s,c=arguments;return C().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=c.length>1&&void 0!==c[1]?c[1]:0,r=[],!t){e.next=10;break}return e.next=5,B.search(t,{offset:n,limit:20});case 5:o=e.sent,i=o.data,r=i,e.next=15;break;case 10:return e.next=12,B.trending({offset:n,limit:20});case 12:a=e.sent,s=a.data,r=s;case 15:M(0===n?r:function(e){return[].concat(O(e),O(r))}),u(n+25),p(!1);case 18:case"end":return e.stop()}}),e)})),function(){var t=this,n=arguments;return new Promise((function(r,o){var i=e.apply(t,n);function a(e){T(i,r,o,a,s,"next",e)}function s(e){T(i,r,o,a,s,"throw",e)}a(void 0)}))});return function(e){return t.apply(this,arguments)}}(),H=function(){var e=o.current;e&&e.scrollTop+e.clientHeight>=e.scrollHeight-10&&!m&&(p(!0),G(a,l))};return(0,r.useEffect)((function(){G("")}),[]),(0,r.useEffect)((function(){var e=o.current;return e.addEventListener("scroll",H),function(){e.removeEventListener("scroll",H)}}),[I,m]),(0,x.jsxs)(E,{style:t.container,children:[(0,x.jsxs)(F,{style:t.searchBlock,children:[(0,x.jsx)(R,{style:t.searchIcon,children:(0,x.jsx)(h(),{})}),(0,x.jsx)(D,{type:"text",style:t.searchInput,value:a,onChange:function(e){var t;s(e.target.value),t=e.target.value,u(0),G(t)},placeholder:W||"_Search GIF"})]}),(0,x.jsx)(U,{style:t.poweredByGiphy,children:(0,x.jsx)("img",{src:z,alt:"Powered by Giphy"})}),(0,x.jsx)(_,{style:t.gifsContainer,children:(0,x.jsx)(L,{style:t.gifs,ref:o,children:I.map((function(e){var r,o,i=(null===(r=e.images)||void 0===r||null===(r=r.fixed_height_small)||void 0===r?void 0:r.webp)||(null===(o=e.images)||void 0===o||null===(o=o.fixed_height_small_still)||void 0===o?void 0:o.url);return(0,x.jsx)(N,{onClick:function(e){return function(e,t){t.preventDefault(),t.stopPropagation(),(0,v._z)({content:e,type:w.TQ.Gif,baseMessageId:null==P?void 0:P.id}),null!=P&&P.content&&n(j.o1.setReplyMessage({}))}(i,e)},src:i,style:S(S({},t.gif),{},{cursor:"pointer"}),isLandscape:g,alt:"gif"},e.id)}))})})]})}const z=(0,r.memo)(W);W.defaultProps={style:{container:{},searchBlock:{},searchIcon:{},searchInput:{},gifsContainer:{},poweredByGiphy:{},gifs:{},gif:{}}},W.propTypes={style:s().object};var G=i().div.withConfig({componentId:"sc-10hs9b2-0"})(["display:flex;justify-content:center;margin:1em 0.25em 0;"]),H=i().div.withConfig({componentId:"sc-10hs9b2-1"})(["display:flex;flex-wrap:wrap;align-content:start;overflow:auto;flex:0 0 100%;width:100%;height:13.375em;gap:0.25em;padding:0 0.625em;&::-webkit-scrollbar{width:0.125em;height:0.125em;}&::-webkit-scrollbar-track-piece{background-color:transparent;}&::-webkit-scrollbar-thumb:vertical{height:0.3125em;background:#66462d;border-radius:0.1875em;}"]),Q=i().div.withConfig({componentId:"sc-10hs9b2-2"})(["width:",";height:",";cursor:pointer;"],w.Fr?"calc((100% / 4) - 0.25em)":"calc((100% / 5) - 0.25em)",w.Fr?"5.375em":"3.5em"),Y=i().img.withConfig({componentId:"sc-10hs9b2-3"})(["width:100%;height:100%;object-fit:contain;"]);function q(e){var t=e.style,n=(0,f.useDispatch)(),r=(0,b.shallowSelector)(j.Uu),o=(0,b.shallowSelector)(j.Rk);return(0,x.jsx)(G,{style:t.emojisContainer,children:(0,x.jsx)(H,{style:t.emojis,children:r.map((function(e){var r=e.id,i=(e.name,e.url);return(0,x.jsx)(Q,{style:t.emoji,onClick:function(){return function(e){(0,v._z)({content:e,type:w.TQ.Emoji,baseMessageId:null==o?void 0:o.id}),null!=o&&o.content&&n(j.o1.setReplyMessage({}))}(i)},children:(0,x.jsx)(Y,{style:t.img,src:i,alt:"emoji"})},"emoji_".concat(r))}))})})}const $=(0,r.memo)(q);function X(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n{function r(e){var t=(new TextEncoder).encode(e);return crypto.subtle.digest("SHA-256",t).then((function(e){return Array.from(new Uint8Array(e)).map((function(e){return e.toString(16).padStart(2,"0")})).join("")}))}n.d(t,{t:()=>r})},2213:(e,t,n)=>{n.d(t,{A:()=>l});var r=n(6295),o=n(9133),i=n(3190);function a(e){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a(e)}function s(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;tr?n:r:n},setSharedBigWinCoeff:function(e,t){var n=t.payload;e.gameInfo.sharedBigWinCoefficient=n},resetChatState:function(e){delete e.services.popups[o.BASE_POPUP_NAMES.CHAT_POPUP],delete e.services.popups[o.BASE_POPUP_NAMES.CHAT_REGISTRY_POPUP],e.services.chat={id:0,name:"",configuration:{minShareCoefficient:1e4},player:{id:0,isBlocked:!1,isInfluencer:!1,nickName:"",avatarUrl:"",canChangeNickName:!1},messages:[],pinnedMessages:[],defaultAvatars:[],emojis:[]}}}},7792:(e,t,n)=>{n.d(t,{u:()=>r});var r={services:{popups:{},chat:{id:0,name:"",configuration:{minShareCoefficient:1e4},player:{id:0,isBlocked:!1,isInfluencer:!1,nickName:"",avatarUrl:"",canChangeNickName:!1},messages:[],pinnedMessages:[],defaultAvatars:[],emojis:[]}}}},8011:(e,t,n)=>{n.d(t,{A:()=>s});var r=n(1601),o=n.n(r),i=n(6314),a=n.n(i)()(o());a.push([e.id,"",""]);const s=a},6314:e=>{e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,o,i){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(r)for(var s=0;s0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=i),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),o&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=o):u[4]="".concat(o)),t.push(u))}},t}},1601:e=>{e.exports=function(e){return e[1]}},1020:(e,t,n)=>{var r=n(4914),o=Symbol.for("react.element"),i=Symbol.for("react.fragment"),a=Object.prototype.hasOwnProperty,s=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,c={key:!0,ref:!0,__self:!0,__source:!0};function l(e,t,n){var r,i={},l=null,u=null;for(r in void 0!==n&&(l=""+n),void 0!==t.key&&(l=""+t.key),void 0!==t.ref&&(u=t.ref),t)a.call(t,r)&&!c.hasOwnProperty(r)&&(i[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===i[r]&&(i[r]=t[r]);return{$$typeof:o,type:e,key:l,ref:u,props:i,_owner:s.current}}t.Fragment=i,t.jsx=l,t.jsxs=l},4848:(e,t,n)=>{e.exports=n(1020)},4376:(e,t,n)=>{var r=n(5072),o=n.n(r),i=n(7825),a=n.n(i),s=n(7659),c=n.n(s),l=n(5056),u=n.n(l),d=n(540),f=n.n(d),m=n(1113),p=n.n(m),h=n(8011),g={};g.styleTagTransform=p(),g.setAttributes=u(),g.insert=c().bind(null,"head"),g.domAPI=a(),g.insertStyleElement=f(),o()(h.A,g),h.A&&h.A.locals&&h.A.locals},5072:e=>{var t=[];function n(e){for(var n=-1,r=0;r{var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},540:e=>{e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},5056:(e,t,n)=>{e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7825:e=>{e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var i=n.sourceMap;i&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},1113:e=>{e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}}}]);