1import{a6 as S,a1 as w,f as D,a3 as I,T as h,y as C,r as u,Y as _,q as N,v as R,u as g,z as L,al as b,j as t,o as y,c as f,b as M,a as P,s as v,a5 as k}from"./entry.B8DI74JY.js";import{u as A}from"./useDeny.BHmznGJL.js";import{c as O}from"./wysiwyg.DdX2Bi8J.js";import{u as H}from"./useErrorHandler.gRZDZEoA.js";import{c as T}from"./commonClass.Dw9dIX-c.js";import{C as U}from"./contentType.BNSGteN-.js";import{P as W}from"./deny.YQBOkYUJ.js";import{P as x}from"./permissionType.D8eGudH1.js";import"./useSnackbar.LTSk-Dt4.js";import"./index.CS7R4WcE.js";const G=()=>({getStandalonePage:async n=>{var c,o;await S();const{data:r,error:i}=await w(`/standalonePage/queries/getStandalonePageDetail/${n}`);if(i.value||!r.value)throw new Error(((o=(c=i.value)==null?void 0:c.data)==null?void 0:o.message)||"ç¹è¨ãã¼ã¸æ
å ±ã®èªã¿è¾¼ã¿ã«å¤±æãã¾ãã");return r.value}}),m={STANDARD:"standard",WIDE:"wide"},Y={key:0,class:"mt-20 flex justify-center"},B=["innerHTML"],Z=D({__name:"[pageCode]",setup(E){const n=I(),r=h(),{getStandalonePage:i}=G(),{setDenyItem:c}=A(),o=C(()=>typeof n.params.pageCode=="string"?n.params.pageCode:""),d=u(!1),s=u({id:"",title:"",pageCode:"",body:void 0,widthType:m.STANDARD,permissionType:x.PERMISSION_GROUP,permissionGroupId:"",permissionGroup:void 0,productIds:[],giftIds:[],isPermissionDenied:!1}),p=async()=>{d.value=!0;try{if(!o.value)throw new Error("ãã®ãã¼ã¸ã¯åå¨ããªãããç¡å¹ãªURLã§ãã");const e=await i(o.value);if(W in e&&e.isPermissionDenied){const a={id:e.id,contentType:U.PAGES,toPath:`pages/${o.value}`,item:e,buttonText:"TOPã¸",buttonLink:"/",isExternal:!0};return c(a),r.push(`/deny?to=/${a.toPath}`)}s.value=e,s.value.body=await O(s.value.body),g({title:e.title,meta:[{name:"description",content:e.title},{property:"og:title",content:e.title},{property:"og:description",content:e.title}]})}catch(e){H(e,{customMessage:"ãã®ãã¼ã¸ã¯åå¨ããªãããç¡å¹ãªURLã§ãã"}),k("/",!0)}finally{d.value=!1}};return _(async()=>{await p()}),N(async()=>{const{metaTitle:e,metaDescription:a,ogImage:l}=await R();g({title:e,meta:[{name:"description",content:a},{property:"og:title",content:e},{property:"og:description",content:a},{property:"og:image",content:l}]})}),L(o,async(e,a)=>{e!==a&&await p()}),(e,a)=>{const l=b("Loading");return t(d)||!t(s)?(y(),f("div",Y,[M(l)])):(y(),f("div",{key:1,class:v(t(s).widthType!==t(m).WIDE?("commonClass"in e?e.commonClass:t(T)).contents():"")},[P("div",{class:v(t(s).widthType!==t(m).WIDE?("commonClass"in e?e.commonClass:t(T)).innerNormal():"")},[P("div",{innerHTML:t(s).body,class:"rich-text"},null,8,B)],2)],2))}}});export{Z 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.