{"version":3,"file":"PriceDisplay.Bhc-R-OM.mjs","names":["c"],"sources":["https:/framerusercontent.com/modules/k847LPNIMdkhfIs0ouwF/tP61WRYoAPbFjFQz5S1S/AdditionalService.js","https:/framerusercontent.com/modules/jTRIrvvdhM8hGc8tF4E7/s6vu6FXPQQ7NhnKgCzzl/EvaluateCoupons.js","https:/framerusercontent.com/modules/t32tReeHmrCTzbf5rVbb/uxgyUjDrP8WDAIlKKyPZ/PriceDisplay.js"],"sourcesContent":["// AdditionalService.tsx\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{createStore}from\"https://framer.com/m/framer/store.js@^1.0.0\";const useAdditionalServiceStore=createStore({adult:1,child:0,checkedBBQGrill:false,checkedBBQFood:false,checkedStretch:false,checkedCatering:false,BBQGrillValue:\"1인\",BBQFoodValue:\"인원수\",StretchValue:\"인원수\",CateringValue:\"인원수\",BBQGrillPrice:0,BBQFoodPrice:2e4,StretchPrice:0,CateringPrice:0});function extractNumber(value){const match=value.match(/^(\\d+)인$/);return match?Number(match[1]):0;}export function createAdditionalServiceList(myStore,store){const serviceKeys=[\"BBQGrill\",\"BBQFood\",\"Stretch\",\"Catering\"];const labels={BBQGrill:\"BBQ 그릴 준비\",BBQFood:\"BBQ 식재료 준비\",Stretch:\"모닝 스트레칭 클래스\",Catering:\"케이터링 서비스\"};if(store.membership===\"All-Free\"){return serviceKeys.filter(key=>myStore[`checked${key}`]&&myStore[`${key}Value`]!==\"인원수\").map(key=>({type:labels[key],amount:0}));}return serviceKeys.filter(key=>myStore[`checked${key}`]&&myStore[`${key}Value`]!==\"인원수\").map(key=>({type:labels[key],amount:extractNumber(myStore[`${key}Value`])*myStore[`${key}Price`]}));}const TOTAL_MAX=8;const ADULT_MIN=1;const ADULT_MAX=8;const CHILD_MIN=0;const CHILD_MAX=8;// 텍스트 표시: 성인 n명\nexport function displayAdult(Component){return props=>{const[store]=useAdditionalServiceStore();const label=`성인   ${store.adult}명`;return /*#__PURE__*/_jsx(Component,{...props,text:label});};}// 텍스트 표시: 아동 n명\nexport function displayChild(Component){return props=>{const[store]=useAdditionalServiceStore();const label=`영유아   ${store.child}명`;return /*#__PURE__*/_jsx(Component,{...props,text:label});};}// ✅ 체크 상태 토글 버튼\nexport function toggleBBQGrill(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();const toggle=()=>{setStore({checkedBBQGrill:!store.checkedBBQGrill});};return /*#__PURE__*/_jsx(Component,{...props,onClick:toggle});};}export function toggleBBQFood(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();const toggle=()=>{setStore({checkedBBQFood:!store.checkedBBQFood});};return /*#__PURE__*/_jsx(Component,{...props,onClick:toggle});};}export function toggleStretch(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();const toggle=()=>{setStore({checkedStretch:!store.checkedStretch});};return /*#__PURE__*/_jsx(Component,{...props,onClick:toggle});};}export function toggleCatering(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();const toggle=()=>{setStore({checkedCatering:!store.checkedCatering});};return /*#__PURE__*/_jsx(Component,{...props,onClick:toggle});};}export function handleBBQFoodDropdown(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();const handleChange=event=>{const selectedValue=event.target.value;setStore({BBQFoodValue:selectedValue});};return /*#__PURE__*/_jsx(Component,{...props,value:store.BBQFoodValue,onChange:handleChange});};}export function handleStretchDropdown(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();const handleChange=event=>{const selectedValue=event.target.value;setStore({StretchValue:selectedValue});};return /*#__PURE__*/_jsx(Component,{...props,value:store.StretchValue,onChange:handleChange});};}export function handleCateringDropdown(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();const handleChange=event=>{const selectedValue=event.target.value;setStore({CateringValue:selectedValue});};return /*#__PURE__*/_jsx(Component,{...props,value:store.CateringValue,onChange:handleChange});};}// 증가 버튼: 성인\nexport function incrementAdult(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();const increment=()=>{// const total = store.adult + store.child\nconst total=store.adult;if(total<ADULT_MAX){setStore({adult:store.adult+1});}};return /*#__PURE__*/_jsx(Component,{...props,onClick:increment});};}// 감소 버튼: 성인\nexport function decrementAdult(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();const decrement=()=>{const total=store.adult+store.child;if(store.adult>ADULT_MIN){setStore({adult:store.adult-1});}};return /*#__PURE__*/_jsx(Component,{...props,onClick:decrement});};}// 증가 버튼: 아동\nexport function incrementChild(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();// const total = store.adult + store.child\nconst total=store.child;const increment=()=>{if(total<CHILD_MAX){setStore({child:store.child+1});}};return /*#__PURE__*/_jsx(Component,{...props,onClick:increment});};}// 감소 버튼: 아동\nexport function decrementChild(Component){return props=>{const[store,setStore]=useAdditionalServiceStore();const decrement=()=>{if(store.child>CHILD_MIN){setStore({child:store.child-1});}};return /*#__PURE__*/_jsx(Component,{...props,onClick:decrement});};}export{useAdditionalServiceStore};\nexport const __FramerMetadata__ = {\"exports\":{\"displayChild\":{\"type\":\"reactHoc\",\"name\":\"displayChild\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"displayAdult\":{\"type\":\"reactHoc\",\"name\":\"displayAdult\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useAdditionalServiceStore\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"handleBBQFoodDropdown\":{\"type\":\"reactHoc\",\"name\":\"handleBBQFoodDropdown\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"toggleBBQGrill\":{\"type\":\"reactHoc\",\"name\":\"toggleBBQGrill\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"handleStretchDropdown\":{\"type\":\"reactHoc\",\"name\":\"handleStretchDropdown\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"incrementChild\":{\"type\":\"reactHoc\",\"name\":\"incrementChild\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"toggleBBQFood\":{\"type\":\"reactHoc\",\"name\":\"toggleBBQFood\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"createAdditionalServiceList\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"toggleCatering\":{\"type\":\"reactHoc\",\"name\":\"toggleCatering\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"incrementAdult\":{\"type\":\"reactHoc\",\"name\":\"incrementAdult\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"decrementAdult\":{\"type\":\"reactHoc\",\"name\":\"decrementAdult\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"toggleStretch\":{\"type\":\"reactHoc\",\"name\":\"toggleStretch\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"decrementChild\":{\"type\":\"reactHoc\",\"name\":\"decrementChild\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"handleCateringDropdown\":{\"type\":\"reactHoc\",\"name\":\"handleCateringDropdown\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./AdditionalService.map","// EvaluateCoupons.ts\nimport{membershipPrices,unmuDayLimits}from\"https://framerusercontent.com/modules/eNYxylYRmdtVvI7ZdKLb/2FPh1zA43f4qtPiB9nF4/UnmuMembership.js\";function getKSTDate(baseDate=new Date){const utc=baseDate.getTime()+baseDate.getTimezoneOffset()*6e4;return new Date(utc+9*60*60*1e3);}function toDate(obj){return new Date(obj.year,obj.month,obj.day);}function getKey(d){return`${d.getFullYear()}-${String(d.getMonth()+1).padStart(2,\"0\")}-${String(d.getDate()).padStart(2,\"0\")}`;}// Step 1: Initial price 계산\nexport function calculateInitialPrices(store,categoryMap,firstDate,secondDate){let first=null;let second=null;if(firstDate&&secondDate){// alert(JSON.stringify(firstDate))\n// alert(JSON.stringify(secondDate))\nfirst=toDate(firstDate);second=new Date(toDate(secondDate));}else{first=toDate(store.firstDate);second=new Date(toDate(store.secondDate));}second.setDate(second.getDate()-1)// 퇴실일은 계산에 포함 X\n;const dailyItems=[];const basePrices=[];const categoryCount={Weekday:0,Weekend:0,Peak:0};const isUnmu=[\"UNMU 6\",\"UNMU 9\",\"UNMU 12\",\"UNMU 24\"].includes(store.membership);for(let d=new Date(first);d<=second;d.setDate(d.getDate()+1)){const key=getKey(d);const category=categoryMap[key]??\"Weekday\";const basePrice=membershipPrices[\"Non-Member\"][category];basePrices.push(basePrice);let price;if(store.membership===\"Non-Member\"){price=basePrice;}else if(isUnmu){const limits=unmuDayLimits[store.membership];let categoryKey=\"Weekday\";if(category===\"Weekend\")categoryKey=\"Weekend\";else if(category===\"Peak-Weekday\"||category===\"Peak-Weekend\")categoryKey=\"Peak\";const current=categoryCount[categoryKey];const allowed=limits[categoryKey];if(current<allowed){price=Math.round(basePrice*1);}else{price=Math.round(basePrice*1.4);}categoryCount[categoryKey]+=1;}else{// 'All-Free' case\nprice=0;}dailyItems.push({date:key,price,category});}// initialPrice는 basePrice만 더해서 계산\nconst initialPrice=basePrices.reduce((acc,val)=>acc+val,0);return{initialPrice,dailyItems};}// Step 2~10: 쿠폰 필터링\nexport function filterCoupons(coupons,store,dailyItems){const{membership_number,enteredCouponCode,signupDate}=store;const totalPrice=dailyItems.reduce((acc,i)=>acc+i.price,0);const stayLength=dailyItems.length;const stayDates=dailyItems.map(i=>i.date);const allCategories=new Set(dailyItems.map(i=>i.category));const signup=signupDate?getKSTDate(new Date(signupDate)):undefined;const now=getKSTDate();const signupDiffDays=signup?(now.getTime()-signup.getTime())/(1e3*60*60*24):Infinity;const passedCoupons=coupons.filter(c=>{if(!c.enabled){return false;}if(c.type===\"personal\"){if(!membership_number){return false;}if(!c.allowed_members?.includes(membership_number)){return false;}}if(c.type===\"code\"){// console.log(\"CHECKING FOR CODE COUPONS\")\n// if (!enteredCouponCode || enteredCouponCode !== c.code) {\nif(!enteredCouponCode||!enteredCouponCode.includes(c.code)){return false;}}const conditions=Array.isArray(c.conditions_json)?c.conditions_json:[];for(const cond of conditions){if(cond.type===\"membership\"){if(!cond.members.includes(store.membership)){return false;}}if(cond.type===\"signup_within_days\"){if(signupDiffDays>Number(cond.days)){return false;}}if(cond.type===\"minimum_price\"){if(totalPrice<(Number(cond.min)??0)){return false;}}if(cond.type===\"relay\"){if(stayLength<(Number(cond.min)??0)){return false;}if(cond.max&&stayLength>Number(cond.max)){return false;}}if(cond.type===\"date\"){const start=cond.startDate?getKSTDate(new Date(cond.startDate)):null;const end=cond.endDate?getKSTDate(new Date(cond.endDate)):null;const matched=stayDates.some(d=>{const date=getKSTDate(new Date(d));return(!start||date>=start)&&(!end||date<=end);});if(!matched){return false;}}if(cond.type===\"seasonal\"){const allowed=new Set(cond.allowedCategories||[]);const matched=[...allCategories].some(c=>allowed.has(c));if(!matched){return false;}}}return true;});return passedCoupons;}// Step 11~16: 쿠폰별 금액 계산\nexport function evaluateCoupons(coupons,dailyItems,usedMileage=0,store){const totalPrice=dailyItems.reduce((sum,d)=>sum+d.price,0);if(store?.remarks?.includes(\"phase-1\")||store?.membership===\"All-Free\"){const id=store?.membership===\"All-Free\"?\"all-free\":\"phase-1\";return{discountedPrice:0,details:[{id,amount:totalPrice}]};}const couponSums={};const perCouponLog={};const dailyLog={};const appliedPerStayCoupons=new Set;for(const day of dailyItems){const originalPrice=day.price;let currentPrice=originalPrice;const appliedToday=[];const applicableCoupons=coupons.filter(coupon=>{if(!coupon.conditions_json||coupon.conditions_json.length===0)return true;let hasDateCondition=false;let passesDateCondition=true;let hasSeasonalCondition=false;let passesSeasonalCondition=true;coupon.conditions_json.forEach(cond=>{if(cond.type===\"date\"){hasDateCondition=true;const start=cond.startDate?getKSTDate(new Date(cond.startDate)):null;const end=cond.endDate?getKSTDate(new Date(cond.endDate)):null;const d=getKSTDate(new Date(day.date));if(start&&d<start||end&&d>end){passesDateCondition=false;}}if(cond.type===\"seasonal\"){hasSeasonalCondition=true;if(!cond.allowedCategories?.includes(day.category)){passesSeasonalCondition=false;}}});const dateOK=!hasDateCondition||passesDateCondition;const seasonalOK=!hasSeasonalCondition||passesSeasonalCondition;return dateOK&&seasonalOK;});for(const coupon of applicableCoupons){if(!coupon.id)continue;// TODO : phase-n 조건 적용하는 코드\nconst isFirstDay=day.date===dailyItems[0].date;const hasRelayCondition=(coupon.conditions_json||[]).some(cond=>cond.type===\"relay\");if(isFirstDay&&hasRelayCondition){continue;}const discountValue=Number(coupon.discount_value);let amount=0;const before=currentPrice;if(coupon.discount_type===\"percentage\"){amount=Math.round(currentPrice*(discountValue/100));currentPrice-=amount;}else if(coupon.discount_type===\"fixed\"){if(coupon.scope===\"per_day\"){amount=discountValue;currentPrice-=amount;}else if(coupon.scope===\"per_stay\"){if(appliedPerStayCoupons.has(coupon.id)){continue;}amount=discountValue;currentPrice-=amount;appliedPerStayCoupons.add(coupon.id)// 적용 기록\n;}}couponSums[coupon.id]=(couponSums[coupon.id]||0)+amount;perCouponLog[coupon.id]=perCouponLog[coupon.id]||[];perCouponLog[coupon.id].push({date:day.date,amount,type:coupon.discount_type});dailyLog[`${day.date}::${coupon.id}`]={couponId:coupon.id,amount};appliedToday.push({couponId:coupon.id,name:coupon.name||coupon.id,before,after:currentPrice,amount,type:coupon.discount_type});}const totalDayDiscount=originalPrice-currentPrice;}// Step 14: 조건 검사\nconst validCoupons=coupons.filter(c=>{const cond=(c.conditions_json||[]).find(x=>x.type===\"applied_discount\");if(!cond)return true;const total=couponSums[c.id]||0;if(cond.min!==undefined&&total<Number(cond.min)){return false;}if(cond.max!==undefined&&total>Number(cond.max)){couponSums[c.id]=Number(cond.max);}return true;});const groupedByDate={};Object.keys(dailyLog).forEach(key=>{const[date]=key.split(\"::\");groupedByDate[date]=(groupedByDate[date]||0)+dailyLog[key].amount;});const totalDiscount=validCoupons.reduce((sum,c)=>sum+(couponSums[c.id]||0),0);// Step 16: 마일리지 적용\nconst totalBeforeMileage=dailyItems.reduce((sum,d)=>sum+d.price,0)-totalDiscount;const mileageApplied=Math.min(usedMileage,totalBeforeMileage);const finalDiscountedPrice=totalBeforeMileage-mileageApplied;const details=validCoupons.map(c=>({id:c.id,amount:couponSums[c.id]||0}));if(mileageApplied>0){details.push({// id: `mileage${mileageApplied}`,\nid:`mileage`,amount:mileageApplied});}return{discountedPrice:finalDiscountedPrice,details};}\nexport const __FramerMetadata__ = {\"exports\":{\"evaluateCoupons\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"calculateInitialPrices\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"filterCoupons\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}","// PriceDisplay.tsx\nimport{jsx as _jsx}from\"react/jsx-runtime\";import*as React from\"react\";import{useStore}from\"https://framerusercontent.com/modules/r9TbzE6j44OxXp6KiYut/wSCmIMlurrrfW8HmuHIE/MonthDisplay.js\";import{useEffect,useMemo}from\"react\";import{calculateInitialPrices,filterCoupons,evaluateCoupons}from\"https://framerusercontent.com/modules/jTRIrvvdhM8hGc8tF4E7/s6vu6FXPQQ7NhnKgCzzl/EvaluateCoupons.js\";import{useAdditionalServiceStore,createAdditionalServiceList}from\"https://framerusercontent.com/modules/k847LPNIMdkhfIs0ouwF/tP61WRYoAPbFjFQz5S1S/AdditionalService.js\";import{parseDate}from\"https://framerusercontent.com/modules/OM3DCPQsxhCoiGUHGyyF/eYwss7k9yRshF1fsaErq/CheckAuth.js\";import{motion}from\"framer-motion\";const FadeIn=({children})=>/*#__PURE__*/_jsx(motion.div,{initial:{opacity:0,y:0},animate:{opacity:1,y:0},exit:{opacity:0,y:0},transition:{duration:.4,ease:\"easeOut\"},children:children});// ✅ 공휴일 카테고리 가져오기\nexport function useHolidayCategoryMap(){const[categories,setCategories]=React.useState({});const[isLoading,setIsLoading]=React.useState(true);React.useEffect(()=>{fetch(\"https://terene-db-server.onrender.com/api/days\").then(res=>res.json()).then(data=>{const map={};for(const item of data){map[item.date]=item.category;}setCategories(map);}).catch(err=>console.error(\"Holiday fetch error\",err)).finally(()=>setIsLoading(false));},[]);return{categories,isLoading};}// ✅ 문자열 → 카테고리 매핑\nexport function toCategoryMap(input){const allowed=[\"Weekday\",\"Weekend\",\"Peak-Weekday\",\"Peak-Weekend\"];const result={};for(const key in input){const value=input[key];result[key]=allowed.includes(value)?value:\"Weekday\";}return result;}export function useCoupons(){const[coupons,setCoupons]=React.useState([]);const[isLoading,setIsLoading]=React.useState(true);React.useEffect(()=>{fetch(\"https://terene-db-server.onrender.com/api/coupons\").then(res=>res.json()).then(data=>{const sorted=(data||[]).sort((a,b)=>a.priority-b.priority);setCoupons(sorted);}).catch(err=>console.error(\"Coupon fetch error:\",err)).finally(()=>setIsLoading(false));},[]);return{coupons,isLoading};}function useDiscountCalculation(){const queryParams=new URLSearchParams(window.location.search);const first=queryParams.get(\"first\");const second=queryParams.get(\"second\");const firstDate=first?parseDate(first):null;const secondDate=second?parseDate(second):null;const[store]=useStore();const{categories,isLoading:categoryLoading}=useHolidayCategoryMap();const{coupons,isLoading:couponLoading}=useCoupons();const isReady=store.firstDate&&store.secondDate||firstDate&&secondDate;const result=useMemo(()=>{if(!isReady||categoryLoading||couponLoading)return null;const categoryMap=toCategoryMap(categories);const{initialPrice,dailyItems}=calculateInitialPrices(store,categoryMap,firstDate,secondDate);const filtered=filterCoupons(coupons,store,dailyItems);const{discountedPrice}=evaluateCoupons(filtered,dailyItems,store.usedMileage,store);return{initialPrice,discountedPrice};},[store,categories,coupons,firstDate,secondDate,categoryLoading,couponLoading]);return{isLoading:!isReady||categoryLoading||couponLoading,data:result};}// ✅ 안전하게 날짜가 모두 존재할 때만 가격 계산 및 렌더링\nexport function displayInitialPrice(Component){return props=>{const queryParams=new URLSearchParams(window.location.search);const first=queryParams.get(\"first\");const second=queryParams.get(\"second\");const firstDate=first?parseDate(first):null;const secondDate=second?parseDate(second):null;const[store]=useStore();const{categories,isLoading:categoryLoading}=useHolidayCategoryMap();const{coupons,isLoading:couponLoading}=useCoupons();const isStoreReady=store.firstDate&&store.secondDate||firstDate&&secondDate;if(!isStoreReady||categoryLoading||couponLoading)return null;const categoryMap=toCategoryMap(categories);const{initialPrice}=calculateInitialPrices(store,categoryMap,firstDate,secondDate);return(// <FadeIn>\n/*#__PURE__*/_jsx(Component,{...props,text:initialPrice>0?initialPrice.toLocaleString(\"ko-KR\")+\" 원\":\"0 원\"}));};}export function displayDiscountedPrice(Component){return props=>{const queryParams=new URLSearchParams(window.location.search);const first=queryParams.get(\"first\");const second=queryParams.get(\"second\");const firstDate=first?parseDate(first):null;const secondDate=second?parseDate(second):null;const[store]=useStore();const{categories,isLoading:categoryLoading}=useHolidayCategoryMap();const{coupons,isLoading:couponLoading}=useCoupons();const isStoreReady=store.firstDate&&store.secondDate||firstDate&&secondDate;if(!isStoreReady||categoryLoading||couponLoading)return null;const categoryMap=toCategoryMap(categories);const{dailyItems}=calculateInitialPrices(store,categoryMap);const filtered=filterCoupons(coupons,store,dailyItems);const{discountedPrice}=evaluateCoupons(filtered,dailyItems,store.usedMileage,store);return /*#__PURE__*/_jsx(FadeIn,{children:/*#__PURE__*/_jsx(Component,{...props,text:discountedPrice>0?discountedPrice.toLocaleString(\"ko-KR\")+\" 원\":\"0 원\"})});};}function transitionStyle(visible){return{opacity:visible?1:0,color:\"inherit\",transition:\"opacity 0.3s ease-in-out\",display:\"inline-block\"};}export function displayDiscountBar(Component){return props=>{const queryParams=new URLSearchParams(window.location.search);const first=queryParams.get(\"first\");const second=queryParams.get(\"second\");const firstDate=first?parseDate(first):null;const secondDate=second?parseDate(second):null;const[store]=useStore();const{categories,isLoading:categoryLoading}=useHolidayCategoryMap();const{coupons,isLoading:couponLoading}=useCoupons();const isStoreReady=store.firstDate&&store.secondDate||firstDate&&secondDate;if(!isStoreReady||categoryLoading||couponLoading)return null;const categoryMap=toCategoryMap(categories);const{initialPrice,dailyItems}=calculateInitialPrices(store,categoryMap);const filtered=filterCoupons(coupons,store,dailyItems);const{discountedPrice}=evaluateCoupons(filtered,dailyItems,store.usedMileage,store);const show=initialPrice!==Math.max(discountedPrice,0);const baseStyle=transitionStyle(show);const width=initialPrice>=1e8?144:initialPrice>=1e7?128:112;const barStyle={...baseStyle,width,position:\"relative\",right:0,transform:`translateX(${92-width}px)`};return /*#__PURE__*/_jsx(FadeIn,{children:/*#__PURE__*/_jsx(Component,{...props,style:barStyle})});};}export function displaySoftInitialPrice(Component){return props=>{const queryParams=new URLSearchParams(window.location.search);const first=queryParams.get(\"first\");const second=queryParams.get(\"second\");const firstDate=first?parseDate(first):null;const secondDate=second?parseDate(second):null;const[store]=useStore();const{categories,isLoading:categoryLoading}=useHolidayCategoryMap();const{coupons,isLoading:couponLoading}=useCoupons();const isStoreReady=store.firstDate&&store.secondDate||firstDate&&secondDate;if(!isStoreReady||categoryLoading||couponLoading)return null;const categoryMap=toCategoryMap(categories);const{initialPrice}=calculateInitialPrices(store,categoryMap,firstDate,secondDate);return /*#__PURE__*/_jsx(FadeIn,{children:/*#__PURE__*/_jsx(Component,{...props,text:initialPrice>0?initialPrice.toLocaleString(\"ko-KR\")+\" 원\":\"0 원\"})});};}export function getAdditionalPrice(){const[store]=useStore();const[additionalServiceStore]=useAdditionalServiceStore();const additionalServiceList=createAdditionalServiceList(additionalServiceStore,store);const totalAmount=additionalServiceList.reduce((sum,service)=>{return sum+service.amount;},0);return totalAmount;}export function displayIntegratedPrice(Component){return props=>{const queryParams=new URLSearchParams(window.location.search);const first=queryParams.get(\"first\");const second=queryParams.get(\"second\");const firstDate=first?parseDate(first):null;const secondDate=second?parseDate(second):null;const[store]=useStore();const{categories,isLoading:categoryLoading}=useHolidayCategoryMap();const additionalPrice=getAdditionalPrice();const{coupons,isLoading:couponLoading}=useCoupons();const isStoreReady=store.firstDate&&store.secondDate||firstDate&&secondDate;if(!isStoreReady||categoryLoading||couponLoading)return null;const categoryMap=toCategoryMap(categories);const{dailyItems}=calculateInitialPrices(store,categoryMap,firstDate,secondDate);const filtered=filterCoupons(coupons,store,dailyItems);const{discountedPrice}=evaluateCoupons(filtered,dailyItems,store.usedMileage,store);const integratedPrice=store.membership===\"All-Free\"?0:Math.max(discountedPrice,0)+additionalPrice;const text=integratedPrice>0?integratedPrice.toLocaleString(\"ko-KR\")+\" 원\":\"0 원\";return /*#__PURE__*/_jsx(FadeIn,{children:/*#__PURE__*/_jsx(Component,{...props,text:text})});};}export function displayVatPrice(Component){return props=>{const queryParams=new URLSearchParams(window.location.search);const first=queryParams.get(\"first\");const second=queryParams.get(\"second\");const firstDate=first?parseDate(first):null;const secondDate=second?parseDate(second):null;const[store]=useStore();const{categories,isLoading:categoryLoading}=useHolidayCategoryMap();const additionalPrice=getAdditionalPrice();const{coupons,isLoading:couponLoading}=useCoupons();const isStoreReady=store.firstDate&&store.secondDate||firstDate&&secondDate;if(!isStoreReady||categoryLoading||couponLoading)return null;const categoryMap=toCategoryMap(categories);const{dailyItems}=calculateInitialPrices(store,categoryMap,firstDate,secondDate);const filtered=filterCoupons(coupons,store,dailyItems);const{discountedPrice}=evaluateCoupons(filtered,dailyItems,store.usedMileage,store);const integratedPrice=Math.max(discountedPrice,0)+additionalPrice;const vatPrice=store.membership===\"All-Free\"?0:Math.round(integratedPrice*.1);const text=vatPrice>0?vatPrice.toLocaleString(\"ko-KR\")+\" 원\":\"0 원\";return /*#__PURE__*/_jsx(FadeIn,{children:/*#__PURE__*/_jsx(Component,{...props,text:text})});};}export function displayDepositPrice(Component){const queryParams=new URLSearchParams(window.location.search);const first=queryParams.get(\"first\");const second=queryParams.get(\"second\");const firstDate=first?parseDate(first):null;const secondDate=second?parseDate(second):null;return props=>{const[store]=useStore();const{categories,isLoading:categoryLoading}=useHolidayCategoryMap();const{coupons,isLoading:couponLoading}=useCoupons();const isStoreReady=store.firstDate&&store.secondDate||firstDate&&secondDate;if(!isStoreReady||categoryLoading||couponLoading)return null;const depositPrice=store.membership===\"All-Free\"?0:3e5;const text=depositPrice>0?depositPrice.toLocaleString(\"ko-KR\")+\" 원\":\"0 원\";return /*#__PURE__*/_jsx(FadeIn,{children:/*#__PURE__*/_jsx(Component,{...props,text:text})});};}export function displayFinalPrice(Component){return props=>{const queryParams=new URLSearchParams(window.location.search);const first=queryParams.get(\"first\");const second=queryParams.get(\"second\");const firstDate=first?parseDate(first):null;const secondDate=second?parseDate(second):null;const[store,setStore]=useStore();const{categories,isLoading:categoryLoading}=useHolidayCategoryMap();const additionalPrice=getAdditionalPrice();const{coupons,isLoading:couponLoading}=useCoupons();const isStoreReady=store.firstDate&&store.secondDate||firstDate&&secondDate;const priceData=useMemo(()=>{if(!isStoreReady||categoryLoading||couponLoading)return null;const categoryMap=toCategoryMap(categories);const{dailyItems}=calculateInitialPrices(store,categoryMap,firstDate,secondDate);const initialPrice=dailyItems.reduce((sum,item)=>sum+item.price,0);const filtered=filterCoupons(coupons,store,dailyItems);const{discountedPrice,details}=evaluateCoupons(filtered,dailyItems,store.usedMileage,store);const integratedPrice=store.membership===\"All-Free\"?0:Math.max(discountedPrice,0)+additionalPrice;const vatPrice=Math.round(integratedPrice*.1);const finalPrice=store.membership===\"All-Free\"?0:integratedPrice+vatPrice+3e5;const text=finalPrice>0?finalPrice.toLocaleString(\"ko-KR\")+\" 원\":\"0 원\";return{initialPrice,discountedPrice,additionalPrice,integratedPrice,vatPrice,finalPrice,text,details};},[isStoreReady,categoryLoading,couponLoading,store,categories,coupons,additionalPrice]);useEffect(()=>{if(!priceData)return;setStore(prev=>{const isSame=prev.finalPrice===priceData.finalPrice&&prev.initialPrice===priceData.initialPrice&&prev.discountedPrice===priceData.discountedPrice&&prev.additionalPrice===priceData.additionalPrice&&prev.integratedPrice===priceData.integratedPrice&&prev.vatPrice===priceData.vatPrice;if(isSame)return prev;// alert(\"setStore\")  -- 무한 반복형 코드 없는지 점검용\nreturn{...prev,initialPrice:priceData.initialPrice,discountedPrice:priceData.discountedPrice,additionalPrice:priceData.additionalPrice,integratedPrice:priceData.integratedPrice,vatPrice:priceData.vatPrice,finalPrice:priceData.finalPrice,couponDetails:priceData.details};});},[priceData?.initialPrice,priceData?.discountedPrice,priceData?.additionalPrice,priceData?.integratedPrice,priceData?.vatPrice,priceData?.finalPrice]);if(!priceData)return null;return /*#__PURE__*/_jsx(FadeIn,{children:/*#__PURE__*/_jsx(Component,{...props,text:priceData.text})});};}\nexport const __FramerMetadata__ = {\"exports\":{\"displayDiscountedPrice\":{\"type\":\"reactHoc\",\"name\":\"displayDiscountedPrice\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useCoupons\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"displaySoftInitialPrice\":{\"type\":\"reactHoc\",\"name\":\"displaySoftInitialPrice\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"displayInitialPrice\":{\"type\":\"reactHoc\",\"name\":\"displayInitialPrice\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"displayVatPrice\":{\"type\":\"reactHoc\",\"name\":\"displayVatPrice\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"displayDiscountBar\":{\"type\":\"reactHoc\",\"name\":\"displayDiscountBar\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"displayFinalPrice\":{\"type\":\"reactHoc\",\"name\":\"displayFinalPrice\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"toCategoryMap\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"getAdditionalPrice\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useHolidayCategoryMap\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"displayIntegratedPrice\":{\"type\":\"reactHoc\",\"name\":\"displayIntegratedPrice\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"displayDepositPrice\":{\"type\":\"reactHoc\",\"name\":\"displayDepositPrice\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}"],"mappings":"4fACkZ,SAAS,EAAc,EAAM,CAAC,IAAM,EAAM,EAAM,MAAM,WAAW,CAAC,OAAO,EAAM,OAAO,EAAM,GAAG,CAAC,CAAG,UAAgB,EAA4B,EAAQ,EAAM,CAAC,IAAM,E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