{"version":3,"file":"CurrentDateOverride.DjMHiXT4.mjs","names":["__esmMin","z","init_npm_react_18_3_1","K","c","init_jsx_runtime","withCurrentDate","jstTime","getJSTDate","year","month","day","newChildren","processChildren","props","Component","withCurrentDatePadded","processChildrenPadded","children","element","child","init_CurrentDateOverride","result","now","utcTime"],"sources":["https:/framerusercontent.com/modules/z2kcmtI2TmeQmVsLUQvT/ODPAErDrhiGKZBh4o4Th/CurrentDateOverride.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import*as React from\"react\";/**\n * Framer用 - 現在の日付を動的に表示するオーバーライド\n * YYYY年MM月DD日の形式を現在の日付に自動置換\n */// ========== ヘルパー関数 ==========\nconst processChildren=(children,year,month,day)=>{if(typeof children===\"string\"){let result=children.replace(/YYYY/g,year.toString()).replace(/MM/g,month.toString());if(day!==undefined){result=result.replace(/DD/g,day.toString());}return result;}if(/*#__PURE__*/React.isValidElement(children)){const element=children;return /*#__PURE__*/React.cloneElement(element,{...element.props,children:processChildren(element.props.children,year,month,day)});}if(Array.isArray(children)){return children.map(child=>processChildren(child,year,month,day));}return children;};const getJSTDate=()=>{const now=new Date;const jstOffset=9*60;const utcTime=now.getTime()+now.getTimezoneOffset()*6e4;return new Date(utcTime+jstOffset*6e4);};/**\n * 現在の日付（パディングなし）\n * 例: \"YYYY年MM月DD日\" → \"2025年9月28日\"\n */export function withCurrentDate(Component){return props=>{const jstTime=getJSTDate();const year=jstTime.getFullYear();const month=jstTime.getMonth()+1;const day=jstTime.getDate();const newChildren=processChildren(props.children,year,month,day);return /*#__PURE__*/_jsx(Component,{...props,children:newChildren});};}/**\n * 現在の日付（ゼロパディング付き）\n * 例: \"YYYY年MM月DD日\" → \"2025年09月28日\"\n */export function withCurrentDatePadded(Component){return props=>{const jstTime=getJSTDate();const year=jstTime.getFullYear();const month=String(jstTime.getMonth()+1).padStart(2,\"0\");const day=String(jstTime.getDate()).padStart(2,\"0\");const processChildrenPadded=children=>{if(typeof children===\"string\"){return children.replace(/YYYY/g,year.toString()).replace(/MM/g,month).replace(/DD/g,day);}if(/*#__PURE__*/React.isValidElement(children)){const element=children;return /*#__PURE__*/React.cloneElement(element,{...element.props,children:processChildrenPadded(element.props.children)});}if(Array.isArray(children)){return children.map(child=>processChildrenPadded(child));}return children;};const newChildren=processChildrenPadded(props.children);return /*#__PURE__*/_jsx(Component,{...props,children:newChildren});};}\nexport const __FramerMetadata__ = {\"exports\":{\"withCurrentDate\":{\"type\":\"reactHoc\",\"name\":\"withCurrentDate\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withCurrentDatePadded\":{\"type\":\"reactHoc\",\"name\":\"withCurrentDatePadded\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./CurrentDateOverride.map"],"mappings":"A,yHAOG,SAAgBM,EAAgB,EAAU,CAAC,MAAO,IAAO,CAAC,IAAMC,EAAQC,EAAW,EAAQC,EAAKF,EAAQ,YAAY,EAAQG,EAAMH,EAAQ,SAAS,EAAE,EAAQI,EAAIJ,EAAQ,QAAQ,EAAQK,EAAYC,EAAgBC,EAAM,SAASL,EAAKC,EAAMC,CAAG,EAAE,MAAoB,gBAAKI,EAAU,CAAC,GAAGD,EAAM,SAASF,CAAW,CAAC,CAAE,CAAE,CAG1T,SAAgBI,EAAsB,EAAU,CAAC,MAAO,IAAO,CAAC,IAAMT,EAAQC,EAAW,EAAQC,EAAKF,EAAQ,YAAY,EAAQG,EAAM,OAAOH,EAAQ,SAAS,EAAE,CAAC,CAAC,CAAC,SAAS,EAAE,GAAG,EAAQI,EAAI,OAAOJ,EAAQ,QAAQ,CAAC,CAAC,CAAC,SAAS,EAAE,GAAG,EAAQU,EAAsB,GAAU,CAAC,GAAG,OAAOC,GAAW,SAAU,OAAOA,EAAS,QAAQ,QAAQT,EAAK,SAAS,CAAC,CAAC,CAAC,QAAQ,MAAMC,CAAK,CAAC,CAAC,QAAQ,MAAMC,CAAG,EAAG,G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