{
  "version": 3,
  "sources": ["ssg:https://framerusercontent.com/modules/n9cR4gFLy0DjoxfkLrIe/eDj1MxSfupkYrrIeXQ6b/Shared.js", "ssg:https://framerusercontent.com/modules/57wf7vVSsscumOXz4NV8/kLLe9w97bPfPTwFHjkRV/ThemeVariants.js"],
  "sourcesContent": ["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{ControlType}from\"framer\";import{motion}from\"framer-motion\";export const borderPropertyControl=(hidden=null)=>({type:ControlType.Object,optional:true,hidden,controls:{color:{type:ControlType.Color,defaultValue:\"#222\"},width:{type:ControlType.FusedNumber,defaultValue:1,toggleKey:\"widthIsMixed\",toggleTitles:[\"All\",\"Individual\"],valueKeys:[\"widthTop\",\"widthRight\",\"widthBottom\",\"widthLeft\"],valueLabels:[\"T\",\"R\",\"B\",\"L\"],min:0},style:{type:ControlType.Enum,defaultValue:\"solid\",options:[\"solid\",\"dashed\",\"dotted\",\"double\"],optionTitles:[\"Solid\",\"Dashed\",\"Dotted\",\"Double\"]}}});export function Border({width,widthIsMixed,widthTop,widthRight,widthBottom,widthLeft,style,color,transition}){return /*#__PURE__*/_jsx(motion.div,{animate:{borderColor:color},style:{position:\"absolute\",inset:0,borderWidth:widthIsMixed?`${widthTop}px ${widthRight}px ${widthBottom}px ${widthLeft}px`:`${width}px`,borderStyle:style,borderRadius:\"inherit\",pointerEvents:\"none\"},initial:false,transition:transition});}export function EmptyState({title,subtitle,maxWidth=0}){return /*#__PURE__*/_jsxs(\"div\",{style:{display:\"flex\",width:\"100%\",height:\"100%\",placeContent:\"center\",placeItems:\"center\",flexDirection:\"column\",gap:16,backgroundColor:\"rgba(136, 85, 255, 0.1)\",borderRadius:6,border:\"1px dashed rgb(136, 85, 255)\",color:\"rgb(136, 85, 255)\",fontSize:16,padding:20,minHeight:200,maxWidth:maxWidth||undefined},children:[/*#__PURE__*/_jsx(\"p\",{style:{margin:0,fontWeight:600,textAlign:\"center\"},children:title}),/*#__PURE__*/_jsx(\"p\",{style:{margin:0,opacity:.7,// maxWidth: 500,\nlineHeight:1.5,textAlign:\"center\"},children:subtitle})]});}EmptyState.displayName=\"Empty State\";\nexport const __FramerMetadata__ = {\"exports\":{\"borderPropertyControl\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"Border\":{\"type\":\"reactComponent\",\"name\":\"Border\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"EmptyState\":{\"type\":\"reactComponent\",\"name\":\"EmptyState\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Shared.map", "import{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{useState,useEffect,cloneElement}from\"react\";import{EmptyState}from\"https://framerusercontent.com/modules/n9cR4gFLy0DjoxfkLrIe/eDj1MxSfupkYrrIeXQ6b/Shared.js\";const THEME_ATTRIBUTE=\"framestack-theme\";const SIGNAL_NAME=\"framestack-theme-changed\";/**\n * @framerSupportedLayoutWidth any\n * @framerSupportedLayoutHeight any\n */export default function ThemeVariants(props){var _props_light,_props_dark,_props_dark1,_props_light1,_props_style,_props_style1;const[isDarkTheme,setIsDarkTheme]=useState(null);useEffect(()=>{const updateTheme=()=>{// For compatibility with the Theme Toggle component.\n// https://Framestack.co/components/theme-toggle\n// If the site does not have a theme toggle, the device theme will be used.\nconst currentToggleState=document.body.getAttribute(THEME_ATTRIBUTE);// Check if page has the theme toggle attribute.\nif(!currentToggleState||currentToggleState==\"deviceTheme\"){if(document.body.hasAttribute(\"data-framer-theme\")){setIsDarkTheme(document.body.getAttribute(\"data-framer-theme\")==\"dark\");}else{const mediaQuery=window.matchMedia(\"(prefers-color-scheme: dark)\");setIsDarkTheme(mediaQuery.matches);}}else{// Use device theme\nsetIsDarkTheme(currentToggleState==\"dark\")// light or dark\n;}};// Event listener for changes in the device theme\nconst osThemeChange=e=>{setIsDarkTheme(e.matches);};// Update the theme when the page loads\nupdateTheme();// Listen for theme changes made by the theme toggle component\nwindow.addEventListener(SIGNAL_NAME,updateTheme);// Listen for changes in the device theme\nconst mediaQuery=window.matchMedia(\"(prefers-color-scheme: dark)\");mediaQuery.addListener(osThemeChange);// Clean up the event listeners when the theme toggle component unmounts\nreturn()=>{window.removeEventListener(SIGNAL_NAME,updateTheme);mediaQuery.removeListener(osThemeChange);};},[]);// Before the theme has been determined, render nothing.\n// This prevents flashing while the page loads.\nif(isDarkTheme===null){return null;}// Empty state\nif(!((_props_light=props.light)===null||_props_light===void 0?void 0:_props_light[0])||!((_props_dark=props.dark)===null||_props_dark===void 0?void 0:_props_dark[0])){return /*#__PURE__*/_jsx(EmptyState,{title:\"Add dark and light layers.\",subtitle:\"Use the properties panel on the right side to connect layers for dark and light theme.\"});}let layer=isDarkTheme?(_props_dark1=props.dark)===null||_props_dark1===void 0?void 0:_props_dark1[0]:(_props_light1=props.light)===null||_props_light1===void 0?void 0:_props_light1[0];if(layer&&(((_props_style=props.style)===null||_props_style===void 0?void 0:_props_style.width)||((_props_style1=props.style)===null||_props_style1===void 0?void 0:_props_style1.height))){layer=/*#__PURE__*/cloneElement(layer,{style:{...layer.props.style,...props.style}});}if(!layer){return /*#__PURE__*/_jsx(\"div\",{style:{minWidth:100,minHeight:100}});}return layer;}ThemeVariants.displayName=\"Theme Variants\";addPropertyControls(ThemeVariants,{light:{type:ControlType.ComponentInstance,title:\"Light\"},dark:{type:ControlType.ComponentInstance,title:\"Dark\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"ThemeVariants\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutWidth\":\"any\",\"framerSupportedLayoutHeight\":\"any\",\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}"],
  "mappings": "8JAAoiC,SAASA,EAAW,CAAC,MAAAC,EAAM,SAAAC,EAAS,SAAAC,EAAS,CAAC,EAAE,CAAC,OAA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E,EAAW,eAAeE,CAAa,CAAE,CAAE,EAAE,CAAC,CAAC,EAE3GR,IAAc,KAAM,OAAO,KAC9B,GAAG,EAAG,GAAAN,EAAaD,EAAM,SAAS,MAAMC,IAAe,SAAcA,EAAa,CAAC,IAAI,EAAG,GAAAC,EAAYF,EAAM,QAAQ,MAAME,IAAc,SAAcA,EAAY,CAAC,GAAI,OAAoBe,EAAKC,EAAW,CAAC,MAAM,6BAA6B,SAAS,wFAAwF,CAAC,EAAG,IAAIC,EAAMZ,GAAaJ,EAAaH,EAAM,QAAQ,MAAMG,IAAe,OAAO,OAAOA,EAAa,CAAC,GAAGC,EAAcJ,EAAM,SAAS,MAAMI,IAAgB,OAAO,OAAOA,EAAc,CAAC,EAAoR,OAA/Qe,IAAU,GAAAd,EAAaL,EAAM,SAAS,MAAMK,IAAe,SAAcA,EAAa,OAAU,GAAAC,EAAcN,EAAM,SAAS,MAAMM,IAAgB,SAAcA,EAAc,UAAUa,EAAmBC,EAAaD,EAAM,CAAC,MAAM,CAAC,GAAGA,EAAM,MAAM,MAAM,GAAGnB,EAAM,KAAK,CAAC,CAAC,GAAOmB,GAA2BF,EAAK,MAAM,CAAC,MAAM,CAAC,SAAS,IAAI,UAAU,GAAG,CAAC,CAAC,CAAgB,CAAClB,EAAc,YAAY,iBAAiBsB,EAAoBtB,EAAc,CAAC,MAAM,CAAC,KAAKuB,EAAY,kBAAkB,MAAM,OAAO,EAAE,KAAK,CAAC,KAAKA,EAAY,kBAAkB,MAAM,MAAM,CAAC,CAAC",
  "names": ["EmptyState", "title", "subtitle", "maxWidth", "u", "p", "THEME_ATTRIBUTE", "SIGNAL_NAME", "ThemeVariants", "props", "_props_light", "_props_dark", "_props_dark1", "_props_light1", "_props_style", "_props_style1", "isDarkTheme", "setIsDarkTheme", "ye", "ue", "updateTheme", "currentToggleState", "mediaQuery", "window", "osThemeChange", "e", "p", "EmptyState", "layer", "q", "addPropertyControls", "ControlType"]
}
