1import{s as q,D as lt,r as n,a5 as ct,a6 as pt,j as t,a7 as dt,T as g,a as ut,c as mt,B as C,L as H,a8 as Y,a9 as gt,a0 as ht,aa as xt,a1 as bt,d as ft,m as St,ab as Pt,l as Et,ac as At,f as yt,E as A,ad as It,F as Ct,v as y,ae as Tt,af as jt,ag as Ft,ah as V,a3 as d,ai as wt,aj as vt,ak as X,al as I,am as Q,C as Rt,an as Dt,ao as Mt,O as Lt,N as $t,ap as kt,n as c,aq as Nt,ar as Bt,as as _t,_ as zt,o as M,at as Ut,au as Wt}from"./index-Dbs4T2cU.js";import{S as Ot,H as Gt}from"./HTMLContentsDisplay-BnopwZ5Z.js";import{O as Ht}from"./OpgDetailPage-CLAu-hm2.js";import{P as Vt}from"./PlanPurchaseDialog-CmsczTAE.js";import{u as Xt}from"./usePutLastAccessContents-B3bki9ME.js";import{C as Qt}from"./CustomMuiChip-CEBZdHJv.js";import"./Chip-BUqQj-zK.js";const L="ConfirmEmailDialog",m={noPlanPaper:`${L}-noPlanPaper`,dialogContent:`${L}-dialogContent`,dialogActions:`${L}-dialogActions`},qt=q(lt)(({theme:a})=>({[`& .${m.noPlanPaper}`]:{width:"100%",maxWidth:490,margin:a.spacing(6)},[`& .${m.dialogContent}`]:{padding:a.spacing(0,6)},[`& .${m.dialogActions}`]:{gridGap:8,padding:a.spacing(4,6),"& > a":{padding:a.spacing(2,2.75),lineHeight:"26px",fontSize:"15px",letterSpacing:"0.46px",[a.breakpoints.down("sm")]:{width:"100%"}},"& > :not(:first-of-type)":{marginLeft:0,padding:a.spacing(2,5.5)},[a.breakpoints.down("sm")]:{flexDirection:"column-reverse"}}})),Yt=({open:a,onClose:r,urlPath:h})=>{const x=ct(),b=pt(x.breakpoints.down("sm"));return t.jsxs(qt,{fullWidth:!0,open:a,onClose:r,PaperProps:{className:m.noPlanPaper},children:[t.jsx(dt,{children:t.jsx(g,{variant:"h6",fontSize:b?18:20,lineHeight:b?"24px":"32px",fontWeight:700,children:"ãå©ç¨ã®ã¢ã«ã¦ã³ãã«ã¯ãã¡ã¼ã«ã¢ãã¬ã¹ãç»é²ããã¦ããã¾ãã"})}),t.jsx(ut,{className:m.dialogContent,children:t.jsxs(g,{variant:"body1",color:"textSecondary",children:["ã¡ã¼ã«ã¢ãã¬ã¹ã®ç»é²ããªãå ´åãå¿åããå
容ãå¾ã§ç¢ºèªãããã¨ãã§ãã¾ããã",t.jsx("br",{}),"ã¾ããã¡ã¼ã«ã§å½é¸éç¥ãè¡ããããªå ´åã«ã¯ãå½é¸éç¥ãåãåããã¨ãã§ãã¾ããã"]})}),t.jsxs(mt,{className:m.dialogActions,children:[t.jsx(C,{color:"primary",variant:"text",component:H,to:Y.APPLY.replace(/:urlPath/,h),children:"ãã®ã¾ã¾å¿å"}),t.jsx(C,{color:"primary",variant:"contained",component:H,to:gt.NEW_EMAIL,children:"ã¡ã¼ã«ã¢ãã¬ã¹ãç»é²ãã¦å¿å"})]})]})},Kt=n.memo(Yt),p="ApplicationFormScreen",s={wrapper:`${p}-wrapper`,img:`${p}-img`,icon:`${p}-icon`,desc:`${p}-desc`,btnGroup:`${p}-btnGroup`,note:`${p}-note`,...ht[p]},Zt=a=>({[`& .${s.wrapper}`]:{width:"calc(100% - 48px)",margin:a.spacing(4,"auto",20),[a.breakpoints.up("sm")]:{width:"calc(100% - 96px)",marginBottom:a.spacing(40)},[a.breakpoints.up("md")]:{maxWidth:784},[a.breakpoints.up("lg")]:{maxWidth:768}},[`& .${s.img}`]:{width:"100%",margin:"auto",[a.breakpoints.up("md")]:{maxWidth:784},[a.breakpoints.up("lg")]:{maxWidth:768}},[`& .${s.icon}`]:{width:15,height:12,marginLeft:"6px !important",marginRight:"-6px !important"},[`& .${s.desc}`]:{marginBottom:a.spacing(40),[a.breakpoints.up("sm")]:{marginBottom:a.spacing(10)},"& img":{maxWidth:"100%",height:"auto"},"& blockquote":{marginLeft:a.spacing(6),paddingLeft:a.spacing(4),borderLeft:"2px solid #ccc"}},[`& .${s.btnGroup}`]:{position:"fixed",bottom:0,left:0,right:0,zIndex:1,boxShadow:a.shadows[24],borderRadius:"16px 16px 0 0",background:a.palette.background.default,padding:a.spacing(6),[a.breakpoints.up("sm")]:{background:"unset",position:"static",boxShadow:"none",borderRadius:0,padding:0,marginBottom:a.spacing(10)}},[`& .${s.note}`]:{marginRight:a.spacing(2)}}),Jt=bt(Zt,ft[p]),ta=q(xt)(({theme:a,...r})=>({...Jt(a,r)})),aa=()=>{const a=new URLSearchParams(window.location.search).get("preview");return{previewQuery:a,isPreviewMode:!!a}},ea={[d.PREPARED]:"åä»å",[d.RECEIVED]:"åä»çµäº",[d.RECEIVING]:"åä»ä¸"},pa=()=>{const a=St(),{urlPath:r}=Pt(),h=Et(),{loginWithRedirect:x}=n.useContext(At),[b,K]=n.useState(!0),[Z,T]=n.useState(!1),[J,$]=n.useState(!1),[j,tt]=n.useState(null),[at,et]=n.useState(null),[f,k]=n.useState(null),{previewQuery:F,isPreviewMode:N}=aa(),it=n.useMemo(()=>f?.filter(i=>
1i.enabledFanclubBillingPlanSetting)||[],[f]),[e,B]=n.useState(null),{fanclubMemberId:S,signed:w,isFreeMember:_,isSuperUser:z}=yt(),v=A(i=>i.auth.fanclubMemberSetting),P=A(i=>i.app.fanclubSiteInfo),U=A(i=>i.app.appPath),W=A(i=>i.app.fanclubSiteUserInfo?.fanclubSite?.fanclubMember?.mailAddress);Xt(),n.useEffect(()=>{const i=F?`?preview=${F}`:"";a(It({urlPath:`${r}${i}`,fanclubSiteId:Ct()})).then(y).then(o=>{B(o);const u=[];if(P){const{fanclubSiteId:R}=P;u.push(a(Tt({fanclubSiteId:R,formCode:o.applicationFormCode})).then(y).then(k).catch(()=>k(null))),S&&u.push(a(jt({fanclubMemberId:S.toString(),fanclubSiteId:R})).then(y).then(D=>{const O=D.fanclubSpecificProfile?.activeFanclubMembership?.fanclubBillingPlan,st=D.fanclubSpecificProfile?.activeFanclubMembership?.memberNo,rt=D.fanclubSpecificProfile?.activeFanclubMembership?.expireBufferingEndAt;O?tt(O):st&&rt&&a(Ft({fanclubSiteId:R,fanclubMemberId:S.toString()})).then(y).then(G=>{G&&et(G)})}))}return Promise.all(u)}).catch(()=>B(null)).finally(()=>K(!1))},[a,r,P,S,F]);const{receptionStart:nt,receptionEnd:ot,receptionStatus:E}=n.useMemo(()=>{const i=e?V(e.receptionStart):null,o=e?.receptionEnd?V(e.receptionEnd):null;let u=d.RECEIVING;return o&&wt(o)?u=d.RECEIVED:i&&vt(i)&&(u=d.PREPARED),{receptionStart:i&&X(i)||"",receptionEnd:o&&X(o)||"ç¡æé",receptionStatus:u}},[e]),l=n.useMemo(()=>{if(E===d.PREPARED)return{text:"åä»å",buttonText:"å¿åæç¶ãã¸",disable:!0};if(E===d.RECEIVED)return{text:w&&e?.haveApplicationFormAnswers?"å¿åæ¸ã¿":"åä»çµäº",buttonText:"å¿åæç¶ãã¸",disable:!0};if(!w||!v)return{text:"å¿åããã«ã¯ä¼å¡ç»é²ãã¦ãã ããã",disable:!1,buttonText:"å¿åæç¶ãã¸",handler:()=>{const o=e?.applicationFormAuthorizationType?.id;o&&(o===I.ALL_USERS?x({prompt:"login"}):T(!0))}};if(e?.haveApplicationFormAnswers)return{text:"å¿åæ¸ã¿",buttonText:"å¿åæç¶ãã¸",disable:!0};const i=_&&e?.applicationFormAuthorizationType?.id!==I.ALL_USERS;return!z&&!v.allPublishedContentsAccessible&&(i||e?.applicationFormAuthorizationType?.id===I.LIMITED_PLAN&&!f?.find(o=>o.id===j?.id))?{text:"å¿åããã«ã¯ä¼å¡ç»é²ãã¦ãã ããã",buttonText:"ä¼å¡ãã©ã³ãè³¼å
¥ãã¦å¿å",disable:!1,hideText:i,handler:()=>{e?.applicationFormAuthorizationType&&T(!0)}}:{text:t.jsxs(t.Fragment,{children:[t.jsx(Rt,{withFixedColor:!0,href:`${U||""}${Dt.STATIC_CONTENT}?content_type=${Mt.APPLICATION_FORM_TERMS_OF_SERVICE}&application_form_code=${e?.applicationFormCode}`,target:"_blank",children:"å¿åè¦ç´"}),"ã«åæãã¦"]}),buttonText:"å¿åæç¶ãã¸",disable:e?.applicationFormStatusId!==Q.PUBLIC,handler:()=>{e?.applicationFormAuthorizationType&&e?.applicationFormStatusId===Q.PUBLIC&&(W?h.push(Y.APPLY.replace(/:urlPath/,r)):$(!0))}}},[E,w,v,e?.haveApplicationFormAnswers,e?.applicationFormAuthorizationType,e?.a
1pplicationFormCode,e?.applicationFormStatusId,_,z,f,U,x,j?.id,W,h,r]);return b?t.jsx(Lt,{isFullScreen:!0}):e?t.jsxs(t.Fragment,{children:[t.jsx(Ot,{}),t.jsx(Ht,{image:e.thumbnailImageUrl,title:e.title,description:e.description||void 0,platformId:P?.platformId}),t.jsx(kt,{}),t.jsxs(ta,{children:[t.jsx(c,{className:s.img,children:t.jsx(Nt,{src:e.thumbnailImageUrl,block:!0,aspectRatio:Bt.SIXTEEN_TO_NINE})}),t.jsxs(c,{className:s.wrapper,mt:4,children:[t.jsxs(c,{display:"flex",justifyContent:"space-between",alignItems:"center",children:[t.jsx(Qt,{icon:t.jsx(_t,{className:s.icon}),label:"ä¼å¡éå®",size:"small",color:"white",fontWeight:"fontWeightMedium",customColor:"gradient.main",style:{visibility:e.applicationFormAuthorizationType?.id===I.ALL_USERS?"hidden":"visible"}}),t.jsx(zt,{breakpoints:"sm",breakDirection:"down",children:t.jsxs(c,{display:"flex",alignItems:"center",children:[!l.hideText&&t.jsx(M,{variant:"body2",className:s.note,children:l.text}),t.jsx(C,{variant:"contained",color:"primary",size:"large",disabled:l.disable||N||!e.applicationFormAuthorizationType,onClick:l.handler,children:l.buttonText})]})})]}),t.jsx(M,{sx:{wordBreak:"break-all"},variant:"h6",fontWeight:"fontWeightBold",children:e.title}),t.jsxs(c,{display:"flex",alignItems:"center",my:5,children:[t.jsx(c,{display:"flex",px:2.5,color:"secondary.darkText",children:t.jsx(Ut,{iconKey:"ScheduleIcon",color:"inherit"})}),t.jsxs(c,{children:[t.jsx(g,{fontSize:14,children:ea[E]}),t.jsxs(M,{variant:"caption",color:"textSecondary",children:["å仿éï¼",nt," ~ ",ot]})]})]}),e.description&&t.jsx(g,{variant:"body2",wordBreak:"break-all",className:s.desc,children:t.jsx(Gt,{content:e.description})}),t.jsxs(c,{className:s.btnGroup,children:[t.jsx(c,{mb:4,children:t.jsx(g,{variant:"body2",textAlign:"center",children:l.text})}),t.jsx(C,{variant:"contained",color:"primary",size:"large",fullWidth:!0,disabled:l.disable||N||!e.applicationFormAuthorizationType,onClick:l.handler,children:l.buttonText})]})]})]}),t.jsx(Vt,{open:Z,onClose:()=>T(!1),availablePlans:it,userBillingPlan:j,userExpiredBilling:at,contentCode:r,contentType:Wt.APPLICATION}),t.jsx(Kt,{open:J,onClose:()=>$(!1),urlPath:r})]}):t.jsx($t,{notFound:!0})};export{pa as default};
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.