{"version":3,"file":"ShadowEmbed.BXB-RoaP.mjs","names":["useRef","useState","__esmMin","init_npm_react_18_3_1","init_ssg_sandbox_shims","window","te","le","_e","c","init_jsx_runtime","de","addPropertyControls","ControlType","init_framer_CaDWdxiz","ResponsiveText","props","containerRef","fontSize","setFontSize","font","frame","lastHeight","resizeFont","h","lineHeight","ro","check","style","minFontSize","text","init_ResponsiveText","ShadowEmbed","dropShadow","shadowX","shadowY","shadowBlur","shadowOpacity","htmlCode","init_ShadowEmbed"],"sources":["https:/framerusercontent.com/modules/AijjhyOh4D5694z7Bel7/N8KMcFOD6xqDc2Xs8jOZ/ResponsiveText.js","https:/framerusercontent.com/modules/sMCWrCWKFoReVpELu0TO/cgCtrzqH8PJhRPxT0CiV/ShadowEmbed.js"],"sourcesContent":["// Responsive text that auto-scales font size to fill container height, width expands with text length, text is editable via prop. Font size is always based on container height, so all instances in a stack row/column match.\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{useRef,useLayoutEffect,useState,startTransition}from\"react\";import{addPropertyControls,ControlType}from\"framer\";/**\n * ResponsiveText\n *\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight fixed\n */export default function ResponsiveText(props){const{text,font,color,style,minFontSize}=props;const containerRef=useRef(null);const[fontSize,setFontSize]=useState(font?.fontSize?parseFloat(font.fontSize):40);useLayoutEffect(()=>{if(!containerRef.current)return;let frame=null;let lastHeight=0;const resizeFont=()=>{const h=containerRef.current?.offsetHeight||0;if(h&&h!==lastHeight){lastHeight=h;// Use lineHeight from font control to fit text\nlet lineHeight=1;if(font&&font.lineHeight){if(typeof font.lineHeight===\"string\"&&font.lineHeight.endsWith(\"em\")){lineHeight=parseFloat(font.lineHeight);}else if(typeof font.lineHeight===\"number\"){lineHeight=font.lineHeight;}else{lineHeight=Number(font.lineHeight)||1;}}// Prevent division by zero\nif(!lineHeight)lineHeight=1;// Fit fontSize so that fontSize * lineHeight = container height\nstartTransition(()=>setFontSize(h/lineHeight));}};resizeFont();// Use ResizeObserver for robust detection\nlet ro=null;if(typeof window!==\"undefined\"&&window.ResizeObserver){ro=new window.ResizeObserver(resizeFont);ro.observe(containerRef.current);}else{// fallback\nconst check=()=>{resizeFont();frame=window.requestAnimationFrame(check);};frame=window.requestAnimationFrame(check);}return()=>{if(ro)ro.disconnect();if(frame)window.cancelAnimationFrame(frame);};},[font,style?.height]);return /*#__PURE__*/_jsx(\"div\",{ref:containerRef,style:{...style,width:\"max-content\",height:\"100%\",display:\"flex\",alignItems:\"center\",position:\"relative\",overflow:props.overflowVisible?\"visible\":\"hidden\"},children:/*#__PURE__*/_jsx(\"h1\",{style:{...font,fontSize:Math.max(fontSize,minFontSize),color,lineHeight:1,whiteSpace:\"nowrap\",display:\"inline-block\",margin:0},children:text})});}addPropertyControls(ResponsiveText,{text:{type:ControlType.String,title:\"Text\",defaultValue:\"Responsive Text\"},color:{type:ControlType.Color,title:\"Color\",defaultValue:\"#000000\"},font:{type:ControlType.Font,title:\"Font\",controls:\"extended\",defaultFontType:\"sans-serif\",defaultValue:{fontSize:\"40px\",variant:\"Bold\",letterSpacing:\"-0.04em\",lineHeight:\"1em\"}},overflowVisible:{type:ControlType.Boolean,title:\"Overflow Visible\",defaultValue:false,enabledTitle:\"Visible\",disabledTitle:\"Hidden\"},minFontSize:{type:ControlType.Number,title:\"Min Font Size\",defaultValue:12,min:1,max:200,step:1,unit:\"px\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"ResponsiveText\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutHeight\":\"fixed\",\"framerSupportedLayoutWidth\":\"auto\",\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./ResponsiveText.map","// Shadow Embed component with customizable shadow controls\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";/**\n * @framerSupportedLayoutWidth fixed\n * @framerSupportedLayoutHeight fixed\n */export default function ShadowEmbed(props){const{htmlCode=\"\",shadowX=0,shadowY=10,shadowBlur=20,shadowOpacity=.3,style}=props;const dropShadow=`drop-shadow(${shadowX}px ${shadowY}px ${shadowBlur}px rgba(0, 0, 0, ${shadowOpacity}))`;return /*#__PURE__*/_jsx(\"div\",{style:{...style,position:\"relative\",width:\"100%\",height:\"100%\",overflow:\"hidden\",display:\"flex\",alignItems:\"center\",justifyContent:\"center\"},children:/*#__PURE__*/_jsx(\"div\",{style:{width:\"100%\",height:\"100%\",filter:dropShadow},dangerouslySetInnerHTML:{__html:htmlCode}})});}addPropertyControls(ShadowEmbed,{htmlCode:{type:ControlType.String,title:\"HTML Code\",defaultValue:\"\",displayTextArea:true,placeholder:\"Paste your embed code here...\"},shadowX:{type:ControlType.Number,title:\"Shadow X\",defaultValue:0,min:-200,max:200,step:1,unit:\"px\"},shadowY:{type:ControlType.Number,title:\"Shadow Y\",defaultValue:10,min:-200,max:200,step:1,unit:\"px\"},shadowBlur:{type:ControlType.Number,title:\"Shadow Blur\",defaultValue:20,min:0,max:100,step:1,unit:\"px\"},shadowOpacity:{type:ControlType.Number,title:\"Shadow Opacity\",defaultValue:.3,min:0,max:1,step:.01}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"ShadowEmbed\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutWidth\":\"fixed\",\"framerSupportedLayoutHeight\":\"fixed\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./ShadowEmbed.map"],"mappings":"A,6MAMG,SAAwBe,EAAe,EAAM,CAAC,GAAK,CAAC,OAAK,OAAK,QAAM,QAAM,eAAaC,EAAYC,EAAajB,EAAO,IAAI,EAAO,CAACkB,EAASC,GAAalB,EAASmB,GAAM,SAAS,WAAWA,EAAK,QAAQ,EAAE,EAAE,EAKY,OALVb,MAAoB,CAAC,GAAG,CAACU,EAAa,QAAQ,OAAO,IAAII,EAAM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