{"version":3,"file":"GoogleSignInButton.tZh8fLDs.mjs","names":["useRef","useState"],"sources":["https:/framerusercontent.com/modules/t9j5mc1vzpVDeeZr1ShX/hCSAtvBwLrpTApcd1usq/GoogleSignInButton.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{useRef,useState}from\"react\";import{Events,Icon,StandardButton,standardButtonPropertyControls,useThentyForm,useSSO}from\"https://framerusercontent.com/modules/diyk5889JEo4mM5y5sJr/WO0BY8LwVoqggEJBPHWk/ThentyShared.js\";/**\n * @framerSupportedLayoutWidth any-prefer-fixed\n * @framerSupportedLayoutHeight any\n * @framerIntrinsicWidth 300\n * @framerDisableUnlink\n */export default function GoogleSignInButton(props){const{text,icon,loadingEvent}=props;const ref=useRef(null);const[loading,setLoading]=useState(false);const{setFormState,fireFormEvent}=useThentyForm(ref);const urlParams=new URLSearchParams(window?.location?.search);const planId=urlParams?.get(\"planID\");const{isLoadingGoogle}=useSSO(planId);const onClick=()=>{fireFormEvent(Events.GoogleSignIn);setLoading(true);};const iconElement=icon&&/*#__PURE__*/_jsx(Icon,{image:icon.image,color:icon.color,size:icon.size,defaultImage:`url(\"data:image/svg+xml,${encodeURIComponent(`<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M22.56 12.25C22.56 11.47 22.49 10.72 22.36 10H12V14.255H17.92C17.665 15.63 16.89 16.795 15.725 17.575V20.335H19.28C21.36 18.42 22.56 15.6 22.56 12.25Z\" fill=\"#4285F4\"/><path d=\"M11.9999 23C14.9699 23 17.4599 22.015 19.2799 20.335L15.7249 17.575C14.7399 18.235 13.4799 18.625 11.9999 18.625C9.13492 18.625 6.70992 16.69 5.84492 14.09H2.16992V16.94C3.97992 20.535 7.69992 23 11.9999 23Z\" fill=\"#34A853\"/><path d=\"M5.845 14.09C5.625 13.43 5.5 12.725 5.5 12C5.5 11.275 5.625 10.57 5.845 9.91V7.06H2.17C1.425 8.545 1 10.225 1 12C1 13.775 1.425 15.455 2.17 16.94L5.845 14.09Z\" fill=\"#FBBC05\"/><path d=\"M11.9999 5.375C13.6149 5.375 15.0649 5.93 16.2049 7.02L19.3599 3.865C17.4549 2.09 14.9649 1 11.9999 1C7.69992 1 3.97992 3.465 2.16992 7.06L5.84492 9.91C6.70992 7.31 9.13492 5.375 11.9999 5.375Z\" fill=\"#EA4335\"/></svg>`)}\")`});return /*#__PURE__*/_jsxs(StandardButton,{ref:ref,...props,loading:loading||isLoadingGoogle,onClick:onClick,gap:icon?.gap||0,\"data-no-enter-focus\":true,children:[icon?.location===\"left\"&&iconElement,text,icon?.location===\"right\"&&iconElement]});}GoogleSignInButton.displayName=\"Google Sign In Button\";addPropertyControls(GoogleSignInButton,{text:{type:ControlType.String,defaultValue:\"Sign In with Google\"},...standardButtonPropertyControls({loadingSpinner:true,defaultLoadingSpinnerLocation:\"right\",iconProps:{icon:{type:ControlType.Object,optional:true,defaultValue:{size:20,gap:8},controls:{image:{type:ControlType.Image},color:{type:ControlType.Color,optional:true},size:{type:ControlType.Number,defaultValue:20,min:1,step:1,displayStepper:true},gap:{type:ControlType.Number,defaultValue:8,min:0,step:1,displayStepper:true},location:{type:ControlType.Enum,defaultValue:\"left\",options:[\"left\",\"right\"],optionTitles:[\"Left\",\"Right\"],displaySegmentedControl:true}}}}}),loadingEvent:{type:ControlType.EventHandler,title:\"Loading\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"GoogleSignInButton\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutHeight\":\"any\",\"framerDisableUnlink\":\"\",\"framerIntrinsicWidth\":\"300\",\"framerContractVersion\":\"1\",\"framerSupportedLayoutWidth\":\"any-prefer-fixed\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./GoogleSignInButton.map"],"mappings":"gSAKG,SAAwB,EAAmB,EA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