{
  "version": 3,
  "sources": ["ssg:https://framerusercontent.com/modules/Ntl9auY1grIaG1T9xWWd/BYrgSWvQu58PcamkvK5r/FAQSection.js"],
  "sourcesContent": ["import { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nimport { addPropertyControls, ControlType } from \"framer\";\nimport { useState, useEffect, useRef } from \"react\"; // Learn more: https://www.framer.com/docs/guides/code-components/\nconst wrapperStyle = {\n  width: \"100%\"\n};\nconst headerStyle = {\n  // marginBottom: \"24px\",\n  cursor: \"pointer\",\n  borderRadius: \"8px\",\n  transition: \"0.35s ease all\"\n};\nconst handleStyle = {\n  position: \"absolute\",\n  top: 0,\n  left: 0,\n  height: \"24px\",\n  width: \"40px\"\n};\nconst horizontalBarStyle = {\n  height: \"2px\",\n  width: \"14px\",\n  background: \"linear-gradient(180deg, #FD72AD 0%, #BF6BFF 100%)\",\n  position: \"absolute\",\n  top: \"50%\",\n  left: \"50%\",\n  transform: \"translateX(-50%) translateY(-50%)\"\n};\nconst verticalBarStyle = {\n  height: \"14px\",\n  width: \"2px\",\n  background: \"linear-gradient(180deg, #FD72AD 0%, #BF6BFF 100%)\",\n  position: \"absolute\",\n  top: \"50%\",\n  left: \"50%\",\n  transform: \"translateX(-50%) translateY(-50%)\",\n  transition: \"0.35s ease all\"\n};\nconst titleStyle = {\n  fontSize: \"18px\",\n  lineHeight: \"28px\",\n  fontWeight: 500,\n  paddingLeft: \"40px\",\n  color: \"rgba(250, 248, 248, 1)\",\n  transition: \"0.35s ease all\"\n};\nconst bodyStyle = {\n  position: \"relative\",\n  padding: \"0px 8px\",\n  marginLeft: \"38px\",\n  marginTop: \"24px\",\n  fontSize: \"18px\",\n  lineHeight: \"28px\",\n  color: \"rgba(197, 197, 197, 1)\",\n  overflow: \"hidden\",\n  transition: \"0.35s ease all\"\n};\nconst barStyle = {\n  background: \"linear-gradient(180deg, #D56EE2 0%, #F271BC 100%)\",\n  position: \"absolute\",\n  top: \"0\",\n  left: \"0\",\n  bottom: \"0\",\n  width: \"1px\"\n};\nconst textStyle = {};\nexport default function FAQSection(props) {\n  const {\n    title,\n    body,\n    style\n  } = props;\n  const [isExpanded, setIsExpanded] = useState(true);\n  const [height, setHeight] = useState(0);\n  const bodyRef = useRef(null);\n  useEffect(() => {\n    if (height) return;\n    if (bodyRef.current.clientHeight) {\n      setHeight(bodyRef.current.clientHeight);\n      setIsExpanded(false);\n    }\n  }, [(bodyRef.current || {}).clientHeight]);\n  const updatedVerticalBarStyle = {\n    ...verticalBarStyle\n  };\n  const updatedBodyStyle = {\n    ...bodyStyle\n  };\n  if (isExpanded) {\n    if (height) updatedBodyStyle.height = `${height}px`;\n    updatedVerticalBarStyle.opacity = 0;\n  } else {\n    updatedBodyStyle.height = \"0px\";\n    updatedBodyStyle.marginTop = \"0px\";\n  }\n  let classNameFAQ = \"\";\n  try {\n    let simpleTitle = title === null || title === void 0 ? void 0 : title.replace(/[\\W_]+/g, \"\").replace(/ /g, \"\").toLowerCase().trim();\n    classNameFAQ = `gtm-sanlo-button-faq-${simpleTitle}`;\n  } catch (e) {\n    classNameFAQ = \"\";\n  } // \"...style\" enables switching between auto & fixed sizing\n  // Learn more: https://www.framer.com/docs/guides/auto-sizing\n  return /*#__PURE__*/_jsxs(\"div\", {\n    style: {\n      ...style,\n      ...wrapperStyle\n    },\n    children: [/*#__PURE__*/_jsxs(\"div\", {\n      style: headerStyle,\n      onClick: () => {\n        setIsExpanded(!isExpanded);\n      },\n      children: [/*#__PURE__*/_jsxs(\"div\", {\n        style: handleStyle,\n        children: [/*#__PURE__*/_jsx(\"div\", {\n          style: horizontalBarStyle\n        }), /*#__PURE__*/_jsx(\"div\", {\n          style: updatedVerticalBarStyle\n        })]\n      }), /*#__PURE__*/_jsx(\"div\", {\n        className: classNameFAQ,\n        style: titleStyle,\n        children: title\n      })]\n    }), /*#__PURE__*/_jsxs(\"div\", {\n      style: updatedBodyStyle,\n      ref: bodyRef,\n      children: [/*#__PURE__*/_jsx(\"div\", {\n        style: barStyle\n      }), body.map((bodyString, index) => {\n        if (!bodyString) return null;\n        const updatedTextStyle = {\n          ...textStyle\n        };\n        if (index !== 0) updatedTextStyle.marginTop = \"16px\";\n        return /*#__PURE__*/_jsx(\"div\", {\n          style: updatedTextStyle,\n          children: bodyString\n        });\n      })]\n    })]\n  });\n}\n;\nFAQSection.defaultProps = {\n  title: \"Is this a question about finance?\",\n  body: []\n}; // Learn More: https://www.framer.com/docs/property-controls/\naddPropertyControls(FAQSection, {\n  title: {\n    title: \"Title\",\n    type: ControlType.String\n  },\n  body: {\n    type: ControlType.Array,\n    control: {\n      type: ControlType.String\n    }\n  }\n});\nexport const __FramerMetadata__ = {\n  \"exports\": {\n    \"default\": {\n      \"type\": \"reactComponent\",\n      \"name\": \"FAQSection\",\n      \"slots\": [],\n      \"annotations\": {\n        \"framerContractVersion\": \"1\"\n      }\n    },\n    \"__FramerMetadata__\": {\n      \"type\": \"variable\"\n    }\n  }\n};\n//# sourceMappingURL=./FAQSection.map"],
  "mappings": "qHAGA,IAAMA,EAAe,CACnB,MAAO,MACT,EACMC,EAAc,CAElB,OAAQ,UACR,aAAc,MACd,WAAY,gBACd,EACMC,EAAc,CAClB,SAAU,WACV,IAAK,EACL,KAAM,EACN,OAAQ,OACR,MAAO,MACT,EACMC,EAAqB,CACzB,OAAQ,MACR,MAAO,OACP,WAAY,oDACZ,SAAU,WACV,IAAK,MACL,KAAM,MACN,UAAW,mCACb,EACMC,EAAmB,CACvB,OAAQ,OACR,MAAO,MACP,WAAY,oDACZ,SAAU,WACV,IAAK,MACL,KAAM,MACN,UAAW,oCACX,WAAY,gBACd,EACMC,EAAa,CACjB,SAAU,OACV,WAAY,OACZ,WAAY,IACZ,YAAa,OACb,MAAO,yBACP,WAAY,gBACd,EACMC,EAAY,CAChB,SAAU,WACV,QAAS,UACT,WAAY,OACZ,UAAW,OACX,SAAU,OACV,WAAY,OACZ,MAAO,yBACP,SAAU,SACV,WAAY,gBACd,EACMC,EAAW,CACf,WAAY,o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AAOF,EACP,IAAKJ,EACL,SAAU,CAAcO,EAAK,MAAO,CAClC,MAAOnB,CACT,CAAC,EAAGK,EAAK,IAAI,CAACe,EAAYC,IAAU,CAClC,GAAI,CAACD,EAAY,OAAO,KACxB,IAAME,EAAmB,CACvB,GAAGrB,CACL,EACA,OAAIoB,IAAU,IAAGC,EAAiB,UAAY,QAC1BH,EAAK,MAAO,CAC9B,MAAOG,EACP,SAAUF,CACZ,CAAC,CACH,CAAC,CAAC,CACJ,CAAC,CAAC,CACJ,CAAC,CACH,CAEAlB,EAAW,aAAe,CACxB,MAAO,oCACP,KAAM,CAAC,CACT,EACAqB,EAAoBrB,EAAY,CAC9B,MAAO,CACL,MAAO,QACP,KAAMsB,EAAY,MACpB,EACA,KAAM,CACJ,KAAMA,EAAY,MAClB,QAAS,CACP,KAAMA,EAAY,MACpB,CACF,CACF,CAAC",
  "names": ["wrapperStyle", "headerStyle", "handleStyle", "horizontalBarStyle", "verticalBarStyle", "titleStyle", "bodyStyle", "barStyle", "textStyle", "FAQSection", "props", "title", "body", "style", "isExpanded", "setIsExpanded", "ye", "height", "setHeight", "bodyRef", "pe", "ue", "updatedVerticalBarStyle", "updatedBodyStyle", "classNameFAQ", "u", "p", "bodyString", "index", "updatedTextStyle", "addPropertyControls", "ControlType"]
}
