PageSourceSearch

https://storyweaver.org.in/assets/QuickViewModal.CNqjUz-u.js

js storyweaver.org.in collected 2026-09-24 08:42:50 UTC 4,591 bytes, 2 lines download raw bytes

1import{r as e,j as s}from"./react-vendor.B75MsAI9.js";import{u as l,t as o,s as i,p as a,m as t,o as r,aY as n,cq as u,M as d,cr as c,L as m,S as p,O as g,ce as h,cs as b,aR as k,E as y,F as f,aX as j,aZ as _,ct as v,b5 as x,g as w,a as S,a4 as C}from"./AuthModalContainer.CwDh3qj_.js";import{S as L}from"./main.Bj0Ml4GZ.js";import{a as R}from"./LazyFontLoader.pvie9HdJ.js";import"./RTLProvider.Dbr8G8Qw.js";const B=(e,l,o)=>e?e.map((e,i)=>s.jsx(m,{isInternal:!0,href:g.userProfile(e.slug),onClick:o.bind(null,e.slug,l),children:e.name},i)):[],$=({book:C,onCloseClicked:$,online:H,isRtl:A})=>{const M=l(),q=o();i();const N=a(e=>e.viewport),F=a(e=>e.book.isFetchingAssets);a(e=>e.user.profile.email);const T=a(e=>e.user.profile.id),z=a(e=>e.user.profile.profile_type),V=a(e=>e.book.eventCategory),P=a(e=>e.book.readSource),I=a(e=>e.book.isSupplementary),[W,D]=e.useState(!1),[E,G]=e.useState(!1),[O,Q]=e.useState(!1),X="pb-quick-view-modal",{isGif:Y}=C,Z=(e,s,l)=>{$()},J=s.jsxs(t,{mergeTop:!0,mergeBottom:!N.large,mergeSides:!0,children:[s.jsx(r,{variant:"primary",fullWidth:!0,label:M("Book.read-now"),onClick:()=>{k.shouldShowMandatoryLogin()&&H?q(y({stage:f.mandatoryLogin})):(D(!0),q(j({slug:C.slug,isAudio:!1,isFlpHome:P===n.flpHome,isStem:P===n.stem})).then(()=>{$(),q(_({book:C,readSource:P,flpBook:P===n.flpHome,isSupplementary:I})),q(v({slug:C.slug}))}),window.dataLayer.push({event:S.startReading,category:V,label:w.quickViewModal,item_type:w.bookLangLevel,item_id:C.id,item_value:`${C.language}_${"5"===C.level?x.emergentReader:C.level}`,user_id:T,user_profile:z}),k.storyRead(C.slug))},loading:F&&W}),P!==n.flpHome&&s.jsx(r,{fullWidth:!0,label:M("global.view-details"),onClick:()=>{$(),window.dataLayer.push({event:S.clickedStory,category:V,label:w.quickViewModal,item_type:w.bookLangLevel,item_id:C.id,item_value:`${C.language}_${"5"===C.level?x.emergentReader:C.level}`,user_id:T,user_profile:z}),window.location.href="stem"===P?g.stemBook(C.slug):g.bookDetails(C.slug)}})]});let K;K=C.isTranslation||C.isRelevelled?B(C.authors,C.isTranslation?u.translatedBy:u.writtenBy,Z):B(C.authors,u.writtenBy,Z);const U=B(C.illustrators,u.illustratedBy,Z),ee=s.jsxs("span",{children:[C.isTranslation?M("Book.translated-by"):C.isRelevelled?M("Book.relevelled-by"):M("Book.written-by")," ",R(K,M("global.list-conjunction"))]}),se=U.length>0?s.jsxs("span",{children:[M("Book.illustrated-by")," ",R(U,M("global.list-conjunction"))]}):null,le=F&&E?s.jsx(c,{size:"m"}):s.jsx(m,{onClick:()=>{k.shouldShowMandatoryLogin()&&H?q(y({stage:f.mandatoryLogin})):(G(!0),q(j({slug:C.slug,isAudio:!0,isFlpHome:P===n.flpHome,isStem:"stem"===P})).then(()=>{$(),q(_({book:C,showAudioBookReader:!0,readSource:P,flpBook:P===n.flpHome,isSupplementary:I})),q(v({slug:C.slug}))}),k.storyRead(C.slug))},theme:"dark",children:s.jsx(p,{name:"readalong",size:"m",pushRight:!0})});return s.jsxs(d,{onClose:()=>{$(),window.dataLayer.push({event:S.closedQuickView,category:V,label:w.quickViewModal,item_type:null,item_id:null,item_value:null,user_id:T,user_profile:z})},footer:J,isRtl:A,children:[s.jsx("h2",{className:`${X}__title`,children:C.title||C.name}),(C.isAudio||Y)&&s.jsxs("div",{className:`${X}__action-icon`,children:[F&&O?s.jsx(c,{size:"m"}):s.jsx(m,{onClick:()=>{k.shouldShowMandatoryLogin()&&H?q(y({stage:f.mandatoryLogin})):(Q(!0),q(j({slug:C.slug,isAudio:!1,isFlpHome:P===n.flpHome,isStem:P===n.stem})).then(()=>{$(),q(_({book:C,startPage:1,readSource:P,flpBook:P===n.flpHome,isSupplementary:I})),q(v({slug:C.slug}))}),k.storyRead(C.slug))},theme:"dark",children:s.jsx(p,{name:Y?"gif":"read",size:"m",pushRight:!0})}),C.isAudio?le:null]}),s.jsxs("p",{className:`${X}__credits`,children:[ee," ",se]}),C.description?s.jsx("p",{children:C.description}):null,s.jsxs("div",{className:`${X}__footer`,children:[s.jsxs("div",{className:`${X}__stats`,children:[C.likesCount?s.jsx(L,{iconVariant:"accent",icon:"heart",value:C.likesCount}):null,C.readsCount?s.jsx(L,{icon:"book",value:C.readsCount}):null]}),s.jsx("div",{children:C.publisher&&C.publisher.slug?s.jsx(m,{href:g.profile(h[b[C.publisher.type]],C.publisher.slug),isInternal:!0,onClick:()=>$(),children:s.jsx("img",{className:`${X}__publisher-logo`,src:C.publisher.logo,alt:`${M("global.logo-of")} ${C.publisher.name}`})}):s.jsx("img",{className:`${X}__publisher-logo`,src:C.publisher.logo,alt:`${M("global.logo-of")} ${C.publisher.name}`})})]})]})};$.propTypes={book:C.object.isRequired,onCloseClicked:C.func.isRequired,online:C.bool,isSupplementary:C.bool,readSource:C.string};export{$ as default};
2//# sourceMappingURL=QuickViewModal.CNqjUz-u.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.