{
  "version": 3,
  "sources": ["ssg:https://framerusercontent.com/modules/wzF1aUkHoslINE1PWbP0/qhB83x3iUbFnEMsNrwn1/Shared.js"],
  "sourcesContent": ["import{addPropertyControls,ControlType}from\"framer\";import{fillProp}from\"https://framerusercontent.com/modules/FZjYlw33eNo8pxLbSFLX/NS2M1g7qVI7y5CFDNb6m/SuperfieldsShared.js\";const MODE_CONTROL={mode:{type:ControlType.Enum,defaultValue:\"basic\",options:[\"basic\",\"advanced\"],optionTitles:[\"Basic\",\"Advanced\"],displaySegmentedControl:true,segmentedControlDirection:\"vertical\"}};const SUPPORT_CONTROL={needHelp:{type:ControlType.Object,title:\"Need help?\",buttonTitle:\"Get Support\",icon:\"interaction\",controls:{info:{type:ControlType.Enum,defaultValue:\"info\",options:[\"info\"],optionTitles:[\"Support \uD83D\uDEDF\"],displaySegmentedControl:true,title:\"Get Support\",description:\"We're here to help! The best place to get support is to visit our documentation to find your answers. We're also available on live chat.\\n\\n[Visit Superfields docs](https://insertframe.io/docs/superfields)\"}}}};export function addPropertyControlsV2(component,controls){let showModeControl=false;for(const id of Object.keys(controls)){const control=controls[id];if(control.advanced){showModeControl=true;if(control.hidden){control.hidden=props=>props.mode!==\"advanced\"||control.hidden(props);}else{control.hidden=props=>props.mode!==\"advanced\";}}}addPropertyControls(component,{...showModeControl?MODE_CONTROL:{},...controls,...SUPPORT_CONTROL});}export function buttonPropertyControlsV2({text=\"\",stylingDescription=\"Update the button styling.\",showAppearance=true,stylingPropsStart={},stylingPropsEnd={}}){const hiddenAppearance=showAppearance?props=>props.appearance!==\"default\":undefined;const hiddenAppearanceOutside=showAppearance?props=>props.styling.appearance===\"default\":undefined;return{styling:{type:ControlType.Object,title:\"Styling \uD83C\uDFA8\",buttonTitle:\"Options\",description:stylingDescription,controls:{...showAppearance?{appearance:{type:ControlType.Enum,defaultValue:\"default\",options:[\"default\",\"custom\"],optionTitles:[\"Default\",\"Custom\"],displaySegmentedControl:true}}:{},text:{type:ControlType.String,defaultValue:text,hidden:hiddenAppearance},...stylingPropsStart,fill:fillProp({color:\"#000\",gradientColorA:\"#8C8C8C\",gradientColorB:\"#000\",hidden:hiddenAppearance}),font:{type:\"font\",controls:\"extended\",defaultFontType:\"sans-serif\",defaultValue:{fontSize:14,lineHeight:1.4},hidden:hiddenAppearance},fontColor:{type:ControlType.Color,defaultValue:\"#FFF\",hidden:hiddenAppearance},padding:{type:ControlType.Padding,defaultValue:\"10px 16px 10px 16px\",hidden:hiddenAppearance},radius:{type:ControlType.BorderRadius,defaultValue:\"8px\",hidden:hiddenAppearance},border:{type:ControlType.Border,optional:true,hidden:hiddenAppearance},shadows:{type:ControlType.BoxShadow,hidden:hiddenAppearance},bgBlur:{type:ControlType.Number,min:0,max:100,step:1,displayStepper:true,title:\"BG Blur\",hidden:hiddenAppearance},...stylingPropsEnd}},...showAppearance?{customLayer:{type:ControlType.ComponentInstance,title:\"Layer\",description:\"Connect a custom layer from outside the breakpoint\",hidden:hiddenAppearanceOutside}}:{}};}export function parseButtonPropertyControlsV2(props){const{styling,customLayer}=props;const{radius,padding,text,...otherStyling}=styling;return{...otherStyling,...parsePadding(padding),...parseRadius(radius),text,customLayer};}export const idControl={type:ControlType.Number,defaultValue:0,step:1,min:0,displayStepper:true,title:\"ID\",description:\"If using multiple collections on the same page, set a specific ID to match.\"};export function parsePadding(padding,property=\"padding\"){if(padding&&typeof padding===\"string\"){// Split the input string by spaces and convert each to an integer\nconst values=padding.trim().split(/\\s+/).map(val=>parseInt(val,10));// If only one value is provided, replicate it four times\nif(values.length===1){return{[property]:values[0],[`${property}IsMixed`]:false};}else if(values.length===4){return{[property]:null,[`${property}IsMixed`]:true,[`${property}Top`]:values[0],[`${property}Right`]:values[1],[`${property}Bottom`]:values[2],[`${property}Left`]:values[3]};}}return{[property]:0,[`${property}IsMixed`]:false};}export function parseRadius(radius,property=\"radius\"){if(radius&&typeof radius===\"string\"){// Split the input string by spaces and convert each to an integer\nconst values=radius.trim().split(/\\s+/).map(val=>parseInt(val,10));// If only one value is provided, replicate it four times\nif(values.length===1){return{[property]:values[0],[`${property}IsMixed`]:false};}else if(values.length===4){return{[property]:null,[`${property}IsMixed`]:true,[`${property}TopLeft`]:values[0],[`${property}TopRight`]:values[1],[`${property}BottomRight`]:values[2],[`${property}BottomLeft`]:values[3]};}}return{[property]:0,[`${property}IsMixed`]:false};}\nexport const __FramerMetadata__ = {\"exports\":{\"parsePadding\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"addPropertyControlsV2\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"buttonPropertyControlsV2\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"parseRadius\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"idControl\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"parseButtonPropertyControlsV2\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}"],
  "mappings": "yFAAAA,IAA+K,IAAMC,EAAa,CAAC,KAAK,CAAC,KAAKC,EAAY,KAAK,aAAa,QAAQ,QAAQ,CAAC,QAAQ,UAAU,EAAE,aAAa,CAAC,QAAQ,UAAU,EAAE,wBAAwB,GAAK,0BAA0B,UAAU,CAAC,EAAQC,EAAgB,CAAC,SAAS,CAAC,KAAKD,EAAY,OAAO,MAAM,aAAa,YAAY,cAAc,KAAK,cAAc,SAAS,CAAC,KAAK,CAAC,KAAKA,EAAY,KAAK,aAAa,OAAO,QAAQ,CAAC,MAAM,EAAE,aAAa,CAAC,mBAAY,EAAE,wBAAwB,GAAK,MAAM,cAAc,YAAY;AAAA;AAAA,kEAA+M,CAAC,CAAC,CAAC,EAAS,SAASE,EAAsBC,EAAUC,EAAS,CAAC,IAAIC,EAAgB,GAAM,QAAUC,KAAM,OAAO,KAAKF,CAAQ,EAAE,CAAC,IAAMG,EAAQH,EAASE,CAAE,EAAKC,EAAQ,WAAUF,EAAgB,GAAQE,EAAQ,OAAQA,EAAQ,OAAOC,GAAOA,EAAM,OAAO,YAAYD,EAAQ,OAAOC,CAAK,EAAQD,EAAQ,OAAOC,GAAOA,EAAM,OAAO,WAAa,CAACC,EAAoBN,EAAU,CAAC,GAAGE,EAAgBN,EAAa,CAAC,EAAE,GAAGK,EAAS,GAAGH,CAAe,CAAC,CAAE,CAAo3D,IAAMS,EAAU,CAAC,KAAKC,EAAY,OAAO,aAAa,EAAE,KAAK,EAAE,IAAI,EAAE,eAAe,GAAK,MAAM,KAAK,YAAY,6EAA6E",
  "names": ["init_ssg_sandbox_shims", "MODE_CONTROL", "ControlType", "SUPPORT_CONTROL", "addPropertyControlsV2", "component", "controls", "showModeControl", "id", "control", "props", "addPropertyControls", "idControl", "ControlType"]
}
