{"version":3,"file":"AvoidLayoutJumping_Prod.wnuli2cd.mjs","names":["Phosphor","React.useContext","React.useMemo","React.Fragment","useRef","React.useId","useRef"],"sources":["https:/framerusercontent.com/modules/EYUJlAxleO0qG4nzfff4/8dVGWbUG6inGcIQrH6PM/QhrH4flab.js","https:/framerusercontent.com/modules/h8ioHyt4BUxuvVCE1Q10/aTM6mEMGlM19JjX8exDe/AvoidLayoutJumping_Prod.js"],"sourcesContent":["// Generated by Framer (ed41f9e)\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{addFonts,addPropertyControls,ComponentViewportProvider,cx,getFonts,getPropertyControls,SmartComponentScopedContainer,useComponentViewport,useLocaleInfo,useVariantState,withCSS}from\"framer\";import{LayoutGroup,motion,MotionConfigContext}from\"framer-motion\";import*as React from\"react\";import{useRef}from\"react\";import{Icon as Phosphor}from\"https://framerusercontent.com/modules/tYScH7LTqUtz5KUaUAYP/p8dptk4UIND8hbFWz9V7/Phosphor.js\";const PhosphorFonts=getFonts(Phosphor);const PhosphorControls=getPropertyControls(Phosphor);const serializationHash=\"framer-gZ25q\";const variantClassNames={jJWhsMVgq:\"framer-v-ej8eq7\"};function addPropertyOverrides(overrides,...variants){const nextOverrides={};variants?.forEach(variant=>variant&&Object.assign(nextOverrides,overrides[variant]));return nextOverrides;}const transition1={bounce:.2,delay:0,duration:.4,type:\"spring\"};const Transition=({value,children})=>{const config=React.useContext(MotionConfigContext);const transition=value??config.transition;const contextValue=React.useMemo(()=>({...config,transition}),[JSON.stringify(transition)]);return /*#__PURE__*/_jsx(MotionConfigContext.Provider,{value:contextValue,children:children});};const Variants=motion.create(React.Fragment);const getProps=({height,icon,id,width,...props})=>{return{...props,jgNhBns78:icon??props.jgNhBns78??\"Mountains\"};};const createLayoutDependency=(props,variants)=>{if(props.layoutDependency)return variants.join(\"-\")+props.layoutDependency;return variants.join(\"-\");};const Component=/*#__PURE__*/React.forwardRef(function(props,ref){const fallbackRef=useRef(null);const refBinding=ref??fallbackRef;const defaultLayoutId=React.useId();const{activeLocale,setLocale}=useLocaleInfo();const componentViewport=useComponentViewport();const{style,className,layoutId,variant,jgNhBns78,...restProps}=getProps(props);const{baseVariant,classNames,clearLoadingGesture,gestureHandlers,gestureVariant,isLoading,setGestureState,setVariant,variants}=useVariantState({defaultVariant:\"jJWhsMVgq\",ref:refBinding,variant,variantClassNames});const layoutDependency=createLayoutDependency(props,variants);const sharedStyleClassNames=[];const scopingClassNames=cx(serializationHash,...sharedStyleClassNames);return /*#__PURE__*/_jsx(LayoutGroup,{id:layoutId??defaultLayoutId,children:/*#__PURE__*/_jsx(Variants,{animate:variants,initial:false,children:/*#__PURE__*/_jsx(Transition,{value:transition1,children:/*#__PURE__*/_jsx(motion.div,{...restProps,...gestureHandlers,className:cx(scopingClassNames,\"framer-ej8eq7\",className,classNames),\"data-border\":true,\"data-framer-name\":\"default\",layoutDependency:layoutDependency,layoutId:\"jJWhsMVgq\",ref:refBinding,style:{\"--border-bottom-width\":\"2px\",\"--border-color\":\"var(--token-ad8a243a-2208-4872-a6dd-71bee6b85edd, rgba(189, 125, 8, 0.2))\",\"--border-left-width\":\"2px\",\"--border-right-width\":\"2px\",\"--border-style\":\"solid\",\"--border-top-width\":\"2px\",backgroundColor:\"var(--token-6d7a5182-19b2-4be6-b47f-87a1aaa77be2, rgb(248, 242, 235))\",borderBottomLeftRadius:16,borderBottomRightRadius:16,borderTopLeftRadius:16,borderTopRightRadius:16,...style},children:/*#__PURE__*/_jsx(ComponentViewportProvider,{children:/*#__PURE__*/_jsx(SmartComponentScopedContainer,{className:\"framer-1g3thha-container\",isAuthoredByUser:true,isModuleExternal:true,layoutDependency:layoutDependency,layoutId:\"xQEf7mdja-container\",nodeId:\"xQEf7mdja\",rendersWithMotion:true,scopeId:\"QhrH4flab\",children:/*#__PURE__*/_jsx(Phosphor,{color:\"var(--token-67d5610b-5e91-4dc3-8a14-badc9d93e5cc, rgb(189, 125, 8))\",height:\"100%\",iconSearch:\"House\",iconSelection:jgNhBns78,id:\"xQEf7mdja\",layoutId:\"xQEf7mdja\",mirrored:false,selectByList:true,style:{height:\"100%\",width:\"100%\"},weight:\"regular\",width:\"100%\"})})})})})})});});const css=[\"@supports (aspect-ratio: 1) { body { --framer-aspect-ratio-supported: auto; } }\",\".framer-gZ25q.framer-1no2fcr, .framer-gZ25q .framer-1no2fcr { display: block; }\",\".framer-gZ25q.framer-ej8eq7 { height: 60px; overflow: var(--overflow-clip-fallback, clip); position: relative; width: 60px; will-change: var(--framer-will-change-override, transform); }\",\".framer-gZ25q .framer-1g3thha-container { flex: none; height: 30px; left: calc(50.00000000000002% - 30px / 2); position: absolute; top: calc(50.00000000000002% - 30px / 2); width: 30px; }\",'.framer-gZ25q[data-border=\"true\"]::after, .framer-gZ25q [data-border=\"true\"]::after { content: \"\"; border-width: var(--border-top-width, 0) var(--border-right-width, 0) var(--border-bottom-width, 0) var(--border-left-width, 0); border-color: var(--border-color, none); border-style: var(--border-style, none); width: 100%; height: 100%; position: absolute; box-sizing: border-box; left: 0; top: 0; border-radius: inherit; pointer-events: none; }'];/**\n * This is a generated Framer component.\n * @framerIntrinsicHeight 60\n * @framerIntrinsicWidth 60\n * @framerCanvasComponentVariantDetails {\"propertyName\":\"variant\",\"data\":{\"default\":{\"layout\":[\"fixed\",\"fixed\"]}}}\n * @framerVariables {\"jgNhBns78\":\"icon\"}\n * @framerImmutableVariables true\n * @framerDisplayContentsDiv false\n * @framerAutoSizeImages true\n * @framerComponentViewportWidth true\n * @framerColorSyntax true\n */const FramerQhrH4flab=withCSS(Component,css,\"framer-gZ25q\");export default FramerQhrH4flab;FramerQhrH4flab.displayName=\"Icon Component\";FramerQhrH4flab.defaultProps={height:60,width:60};addPropertyControls(FramerQhrH4flab,{jgNhBns78:PhosphorControls?.[\"iconSelection\"]&&{...PhosphorControls[\"iconSelection\"],defaultValue:\"Mountains\",description:undefined,hidden:undefined,title:\"Icon\"}});addFonts(FramerQhrH4flab,[{explicitInter:true,fonts:[]},...PhosphorFonts],{supportsExplicitInterCodegen:true});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"FramerQhrH4flab\",\"slots\":[],\"annotations\":{\"framerIntrinsicWidth\":\"60\",\"framerComponentViewportWidth\":\"true\",\"framerAutoSizeImages\":\"true\",\"framerCanvasComponentVariantDetails\":\"{\\\"propertyName\\\":\\\"variant\\\",\\\"data\\\":{\\\"default\\\":{\\\"layout\\\":[\\\"fixed\\\",\\\"fixed\\\"]}}}\",\"framerIntrinsicHeight\":\"60\",\"framerContractVersion\":\"1\",\"framerImmutableVariables\":\"true\",\"framerColorSyntax\":\"true\",\"framerDisplayContentsDiv\":\"false\",\"framerVariables\":\"{\\\"jgNhBns78\\\":\\\"icon\\\"}\"}},\"Props\":{\"type\":\"tsType\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./QhrH4flab.map","import{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType,RenderTarget}from\"framer\";import{useEffect,useRef}from\"react\";/**\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n *\n * @framerDisableUnlink\n */export default function AvoidLayoutJumping({direction,style}){const isCanvas=RenderTarget.current()===RenderTarget.canvas;const ref=useRef(null);const rafId=useRef();const vertical=direction===\"vertical\"||direction===\"both\";const horizontal=direction===\"horizontal\"||direction===\"both\";useEffect(()=>{if(isCanvas)return;const parent=ref.current?.parentElement?.parentElement;if(!parent)return;const container=parent.parentElement;if(!container)return;const updateSize=()=>{const rect=parent.getBoundingClientRect();if(horizontal){container.style.width=`${rect.width}px`;}if(vertical){container.style.height=`${rect.height}px`;}rafId.current=requestAnimationFrame(updateSize);};// Start the RAF loop\nrafId.current=requestAnimationFrame(updateSize);return()=>{if(rafId.current){cancelAnimationFrame(rafId.current);}if(container){if(horizontal){container.style.width=\"\";}if(vertical){container.style.height=\"\";}}};},[direction]);return /*#__PURE__*/_jsx(\"div\",{ref:ref,style:{...style}});}AvoidLayoutJumping.displayName=\"Layout Jump Preventer\";addPropertyControls(AvoidLayoutJumping,{direction:{type:ControlType.Enum,defaultValue:\"vertical\",options:[\"vertical\",\"horizontal\",\"both\"],optionTitles:[\"Vertical\",\"Horizontal\",\"Both\"],displaySegmentedControl:true,segmentedControlDirection:\"vertical\",// @ts-ignore\noptionIcons:[\"direction-vertical\",\"direction-horizontal\",\"direction-all\"],description:\"More components at [Framer University](https://frameruni.link/cc).\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"AvoidLayoutJumping\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerDisableUnlink\":\"\",\"framerSupportedLayoutWidth\":\"auto\",\"framerSupportedLayoutHeight\":\"auto\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./AvoidLayoutJumping_Prod.map"],"mappings":"8bAC2C,IAAoM,IAAkE,IAA4B,IAAoJ,CAAM,EAAc,EAASA,EAAS,CAAO,EAAiB,EAAoBA,EAAS,CAAO,EAAkB,eAAqB,EAAkB,CAAC,UAAU,kBAAkB,CAA8L,EAAY,CAAC,OAAO,GAAG,MAAM,EAAE,SAAS,GAAG,KAAK,SAAS,CAAO,GAAY,CAAC,QAAM,cAAY,CAAC,IAAM,EAAOC,EAAiB,EAAoB,CAAO,EAAW,GAAO,EAAO,WAAiB,EAAaC,OAAmB,CAAC,GAAG,EAAO,aAAW,EAAE,CAAC,KAAK,UAAU,EAAW,CAAC,CAAC,CAAC,OAAoB,EAAK,EAAoB,SAAS,CAAC,MAAM,EAAsB,WAAS,CAAC,EAAS,EAAS,EAAO,OAAOC,EAAe,CAAO,GAAU,CAAC,SAAO,OAAK,KAAG,QAAM,GAAG,MAAgB,CAAC,GAAG,EAAM,UAAU,GAAM,EAAM,WAAW,YAAY,EAAS,GAAwB,EAAM,IAAe,EAAM,iBAAwB,EAAS,KAAK,IAAI,CAAC,EAA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