1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1669],{32441:function(e,o,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/namaayeshgah",function(){return t(25864)}])},80899:function(e,o,t){"use strict";t.d(o,{Z:function(){return d}});var a=t(85893),n=t(67294),i=t(73935),s=t(97163),c=t(67799),l=t(26299),r=t.n(l);class d extends n.PureComponent{componentDidMount(){"undefined"!=typeof document&&(this.modalRoot=document.body,this.modalRoot.appendChild(this.el),this.props.isOpen&&(document.body.style.overflow="hidden",this.setBodyOverflow=!0))}componentDidUpdate(e){"undefined"!=typeof document&&(this.props.isOpen&&!e.isOpen?(document.body.style.overflow="hidden",this.setBodyOverflow=!0):!this.props.isOpen&&e.isOpen&&this.setBodyOverflow&&(document.body.style.overflow="auto",this.setBodyOverflow=!1))}componentWillUnmount(){this.modalRoot.removeChild(this.el),document.body.style.overflow="auto"}render(){let{isOpen:e,isfull:o,children:t,forArticle:n=!1}=this.props;return e?n?(0,a.jsx)("div",{children:o?(0,a.jsx)("div",{className:r().back,onClick:this.handleBackdropClick,children:t}):(0,a.jsx)("div",{className:"".concat(r().overlay),onClick:this.handleBackdropClick,children:t})}):(0,i.createPortal)((0,a.jsx)("div",{children:o?(0,a.jsx)("div",{className:r().back,onClick:this.handleBackdropClick,children:t}):(0,a.jsx)("div",{className:"".concat(r().overlay," ").concat(this.context===c.Q2.dark?r().dark:""),onClick:this.handleBackdropClick,children:t})}),this.el):null}constructor(e){super(e),this.modalRoot=null,this.setBodyOverflow=!1,this.handleBackdropClick=e=>{var o;if(e.target!==e.currentTarget)return;let t=null!==(o=this.props.onClickOverlay)&&void 0!==o?o:this.props.closeModal;null==t||t()},this.el="undefined"!=typeof document?document.createElement("div"):{}}}d.contextType=s.Ni},25864:function(e,o,t){"use strict";t.r(o),t.d(o,{__N_SSP:function(){return N},default:function(){return B}});var a=t(85893),n=t(9008),i=t.n(n),s=t(67294),c=t(59595),l=t.n(c),r=t(60550),d=t(3634),u=t.n(d);let _=e=>{let{isPrimary:o,isActive:t,userInfo:n,onSelect:i,isEmail:s=!1}=e;return(0,a.jsxs)("div",{className:"".concat(u().accountOption," ").concat(t?u().active:""),onClick:()=>i(o),children:[(0,a.jsx)("input",{type:"radio",checked:t,readOnly:!0,className:u().toggleButton}),(0,a.jsx)("div",{children:o?(0,a.jsxs)("div",{className:u().primaryOption,children:[(0,a.jsx)("p",{className:u().primaryOptionTitle,children:s?"Ø§ÙØ²Ùد٠کتاب ب٠اÛÙ
ÛÙ:":"Ø§ÙØ²Ùد٠کتاب ب٠شÙ
ار٠تÙÙÙ:"}),(0,a.jsx)("p",{className:u().primaryOptionInfo,children:s?n:(0,r.Iq)(n)})]}):(0,a.jsx)("div",{className:u().otherOption,children:(0,a.jsxs)("p",{className:u().otherOptionTitle,children:["Ø§ÙØ²Ùد٠کتاب ب٠شÙ
ار٠تÙÙÙ/ اÛÙ
Û٠دÛگر"," "]})})})]})};var m=e=>{let{userInfo:o,isPrimaryInfoPicked:t,setIsPrimaryInfoPicked:n,isEmail:i,buttonText:s,onButtonClick:c}=e;return(0,a.jsxs)("div",{className:u().accountPicker,children:[(0,a.jsx)(_,{isPrimary:!0,isActive:t,userInfo:o,onSelect:n,isEmail:i}),(0,a.jsx)(_,{isPrimary:!1,isActive:!t,userInfo:o,onSelect:n}),(0,a.jsx)("button",{className:u().button,onClick:c,children:s})]})},h=t(49706),p=t(55386),v=t(6998),f=t(11163),x=t(80899),g=t(52717),k=t.n(g),j=e=>{let{isOpen:o,closeModal:t,userInfo:n,isEmail:i,onAddBookClick:s}=e;return(0,a.jsx)(x.Z,{isfull:!1,isOpen:o,closeModal:t,children:(0,a.jsxs)("div",{className:k().confirmationModal,children:[(0,a.jsxs)("div",{className:k().confirmationModalContent,children:[(0,a.jsx)("img",{src:"/images/namaayeshgah/image.png",alt:"confirmation"}),(0,a.jsxs)("p",{className:k().confirmationModalText,children:[i?(0,a.jsx)("span",{children:"اÛ٠کتاب Ø¨Ù ØØ³Ø§Ø¨ Ú©Ø§Ø±Ø¨Ø±Û Ø¨Ø§ اÛÙ
ÛÙ"}):(0,a.jsx)("span",{children:"اÛ٠کتاب Ø¨Ù ØØ³Ø§Ø¨ Ú©Ø§Ø±Ø¨Ø±Û Ø¨Ø§ Ø´Ù
ارÙâÛ ØªÙÙÙ"}),(0,a.jsx)("span",{className:k().userInfo,children:n}),(0,a.jsx)("span",{children:"Ø§ÙØ²Ùد٠Ù
ÛâØ´ÙØ¯."})]})]}),(0,a.jsxs)("div",{className:k().buttons,children:[(0,a.jsx)("button",{className:"".concat(k().addButton," ").concat(k().button),onClick:s,children:"Ø§ÙØ²Ùد٠کتاب"}),(0,a.jsx)("button",{className:"".concat(k().cancelButton," ").concat(k().button),onClick:t,children:"بازگشت"})]})]})})},b=t(76446),y=t(4896),P=e=>{let{bookData:o,paramPhoneNumber:t,coupon:n}=e,{isAuthenticated:i,loading:c,user:r,logout:d}=(0,s.useContext)(h.V),{isMobile:u}=(0,p.V)(),{windowWidth:_}
1=(0,v.Z)(),x=(0,f.useRouter)(),[g,k]=(0,s.useState)(t),[P,N]=(0,s.useState)(!0),[B,T]=(0,s.useState)(!1),[C,O]=(0,s.useState)(u),[I,w]=(0,s.useState)(!1),[M,S]=(0,s.useState)(!1),F=async()=>{var e,o;let t=await b.ZP.post("/mybook/v2/campaign/namayeshgah",{code:n,phoneNumber:B?null:g,email:B?g:null});(null==t?void 0:t.Status)===0&&(null==t?void 0:null===(e=t.Data)||void 0===e?void 0:e.status)===0?(S(!0),w(!1)):(document.dispatchEvent(new CustomEvent("showToast",{detail:{msg:(null==t?void 0:null===(o=t.Data)||void 0===o?void 0:o.errorMessage)||(null==t?void 0:t.Message),type:y.pC.Error}})),w(!1),S(!1))};(0,s.useEffect)(()=>{_<992?O(!0):O(!1)},[_]),(0,s.useEffect)(()=>{c||(i&&!c?(null==r?void 0:r.phone)?k(r.phone):(k(r.email),T(!0)):k(t))},[i,c,r]);let E=()=>(0,a.jsxs)("div",{className:l().bookSection,children:[(0,a.jsx)("img",{src:o.imageUrl,alt:o.title,className:"".concat(l().bookImage," ").concat("Audio"===o.type?l().audioBookImage:l().textBookImage)}),(0,a.jsxs)("div",{className:l().bookInfo,children:[(0,a.jsx)("p",{className:l().bookTitle,children:o.title}),(0,a.jsxs)("div",{className:l().bookAuthorBox,children:[o.author&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("p",{className:l().bookAuthor,children:o.author}),(0,a.jsx)("p",{style:{color:"#00A2A4",margin:0},children:"â¢"})]}),(0,a.jsx)("p",{className:l().bookType,children:"Text"===o.type?"کتاب اÙکترÙÙÛÚ©Û":"Audio"===o.type?"کتاب ØµÙØªÛ":""})]})]})]});return(0,a.jsxs)("div",{className:"".concat(l().festivalPage," container"),children:[(0,a.jsxs)("div",{className:l().pageHeader,children:[(0,a.jsx)("img",{src:"/images/download/LastTaaghche.webp",alt:o.title,className:l().taaghcheImg}),(0,a.jsx)("div",{className:"".concat(l().taaghcheLogo," icon-logo")})]}),(0,a.jsxs)("div",{className:l().pageContentWrapper,children:[!C&&(0,a.jsx)(E,{}),(0,a.jsxs)("div",{className:l().pageContent,children:[(0,a.jsx)("div",{className:l().introduction,children:(0,a.jsx)("div",{className:l().introductionText,children:M?(0,a.jsxs)("div",{className:l().successText,children:[(0,a.jsx)("img",{src:"/images/namaayeshgah/checkmark.svg",alt:"success"}),(0,a.jsx)("p",{className:l().successTextTitle,children:"کتاب با Ù
ÙÙÙÛØª ب٠کتابخاÙ٠طاÙÚ٠اضاÙ٠شد"})]}):(0,a.jsx)(a.Fragment,{children:(0,a.jsxs)("p",{children:["Ø¯ÙØ³Øª Ú©ØªØ§Ø¨Ø®ÙØ§ÙÙ
!",(0,a.jsx)("br",{}),"Ú©ØªØ§Ø¨Û Ú©Ù Ø§Ø² ÙÙ
Ø§ÛØ´Ú¯Ø§Ù Ø®Ø±ÛØ¯ÙâØ§Û Ø¢Ù
Ø§Ø¯Ù Ø¯Ø±ÛØ§Ùت است."]})})})}),C&&(0,a.jsx)(E,{}),M?(0,a.jsxs)("div",{className:l().successButtons,children:[(0,a.jsxs)("button",{className:"".concat(l().libraryButton," ").concat(l().button),onClick:()=>x.push("/mylibrary?type=".concat(o.type)),children:["Ø´Ø±ÙØ¹ Ù
Ø·Ø§ÙØ¹Ù"," "]}),(0,a.jsxs)("button",{className:"".concat(l().downloadButton," ").concat(l().button),onClick:()=>x.push("/download"),children:["داÙÙÙØ¯ اپÙÛÚ©ÛØ´Ù طاÙÚÙ"," "]})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(m,{userInfo:g,isPrimaryInfoPicked:P,setIsPrimaryInfoPicked:N,isEmail:B,buttonText:P?"Ø§ÙØ²Ùد٠کتاب":"ÙØ±Ùد Ø¨Ù ØØ³Ø§Ø¨ کاربرÛ",onButtonClick:()=>{P?w(!0):(d(),x.push("/login"))}}),(0,a.jsxs)("div",{className:l().information,children:[(0,a.jsx)("img",{src:"/icons/ic-information.svg",alt:"information"}),(0,a.jsx)("p",{className:l().informationText,children:"اÛ٠کتاب Ø¨Ù ØØ³Ø§Ø¨ کاربرÛâ Ø¨Ø§ Ø´Ù
ار٠تÙÙÙ ÛØ§ اÛÙ
ÛÙÛ Ú©Ù Ù
ÛâØ®ÙØ§ÙÛ Ø§Ø¶Ø§ÙÙ Ù
ÛâØ´ÙØ¯ ٠در کتابخاÙÙâÛ Ø·Ø§ÙÚ٠در دسترس Ø®ÙØ§Ùد Ø¨ÙØ¯."})]})]})]})]}),(0,a.jsx)(j,{isOpen:I,closeModal:()=>w(!1),userInfo:g,isEmail:B,onAddBookClick:F})]})},N=!0,B=e=>{var o,t,n,s,c,l,r,d;let{book:u,phoneNumber:_,coupon:m}=e,h={imageUrl:u.coverUri+"?w=150",title:u.title,author:(null==u?void 0:null===(t=u.authors)||void 0===t?void 0:null===(o=t[0])||void 0===o?void 0:o.firstName)||(null==u?void 0:null===(s=u.authors)||void 0===s?void 0:null===(n=s[0])||void 0===n?void 0:n.lastName)?(null!==(r=null==u?void 0:null===(c=u.authors[0])||void 0===c?void 0:c.firstName)&&void 0!==r?r:"")+" "+(null!==(d=null==u?void 0:null===(l=u.authors[0])||void 0===l?void 0:l.lastName)&&void 0!==d?d:""):null,type:u.type};return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)(i(),{children:[(0,a.jsx)("title",{children:"ÙÙ
Ø§ÛØ´Ú¯Ø§Ù کتاب | طاÙÚÙ"}),(0,a.jsx)("meta",{name:"robots",content:"noindex"})]}),(0,a.jsx)(P,{bookData:h,paramPhoneNumber:_,coupon:m})]})}},26299:function(e){e.exports={back:"modal_back__6USx7",BackFlash:"modal_BackFlash__b92aa",overlay:"modal_overlay__MR62_",OverlayFlash:"modal_OverlayFlash__9gYzB",content:"modal_content__ChqFp",OverlayFlashDark:"modal_OverlayFlashDark__H8t0a",dark:"modal_dark__Q7Thb"}},3634:function(e){e.exports={accountPicker:"accountPicker_accountPicker__FTCL_",accountOption:"accountPicker_accountOption__73KPk",active:"accountPicker_active__0XxcC",toggleButton:"accountPicker_toggleButton__yCWMF",primaryOption:"accountPicker_primaryOption__nQoi_",primaryOptionTitle:"accountPicker_primaryOptionTitle__c8LX2",primaryOptionInfo:"accountPicker_primaryOptionInfo__U17CB",otherOption:"accountPicker_otherOption__6q_Pv",otherOptionTitle:"accountPicker_otherOptionTitle__h6eNo",button:"accountPicker_button__14pMq"}},52717:function(e){e.exports={confirmationModal:"confirmationModal_confirmationModal__ikRqD",confirmationModalContent:"confirmationModal_confirmationModalContent__DU5EO",confirmationModalText:"confirmationModal_confirmationModalText__FHICD",userInfo:"confirmationModal_userInfo__eh7pG",buttons:"confirmationModal_buttons__SqWPk",button:"confirmationModal_button__Jz7gS",addButton:"confirmationModal_addButton__jg0_V",cancelButton:"confirmationModal_cancelButton__6f_A6"}},59595:function(e){e.exports={festivalPage:"festivalPage_festivalPage__as9Fm",pageHeader:"festivalPage_pageHeader__ExcYK",taaghcheLogo:"festivalPage_taaghcheLogo__IQc06",taaghcheImg:"festivalPage_taaghcheImg__JwwKU",pageContentWrapper:"festivalPage_pageContentWrapper__5yxQQ",bookSection:"festivalPage_bookSection__dpzoU",audio
1BookImage:"festivalPage_audioBookImage__8s8sw",textBookImage:"festivalPage_textBookImage__F4FHL",bookImage:"festivalPage_bookImage__9Nb72",bookInfo:"festivalPage_bookInfo__5g4Nk",bookTitle:"festivalPage_bookTitle__JuekV",bookAuthorBox:"festivalPage_bookAuthorBox__vsE2B",bookAuthor:"festivalPage_bookAuthor__a1Thm",bookType:"festivalPage_bookType__ZlSJx",pageContent:"festivalPage_pageContent__L1sxU",introduction:"festivalPage_introduction__qPG_Y",introductionText:"festivalPage_introductionText__Dl1wU",successText:"festivalPage_successText__5zGd3",successTextIcon:"festivalPage_successTextIcon__rqBuI",successTextTitle:"festivalPage_successTextTitle__FpnCm",information:"festivalPage_information__yZgbw",informationText:"festivalPage_informationText__SJzTw",successButtons:"festivalPage_successButtons__4Sdc5",button:"festivalPage_button__zOGGB",libraryButton:"festivalPage_libraryButton__2dhXZ",downloadButton:"festivalPage_downloadButton__RYgXF"}}},function(e){e.O(0,[9774,2888,179],function(){return e(e.s=32441)}),_N_E=e.O()}]);
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.