{"version":3,"file":"Notes.2J4llqqa.mjs","names":["React.useMemo","baseColorString","backgroundColorString","c"],"sources":["https:/framer.com/m/framer/default-utils.js@^0.45.0","https:/framerusercontent.com/modules/e3x4jPb1EG4euVPWc4mR/DcqkjAY8EPVJ6ETf0Jqb/Notes.js"],"sourcesContent":["import{defaultEvents,localeOptions,fontControls,fontSizeOptions,emptyStateStyle,containerStyles,fontStack}from\"https://framerusercontent.com/modules/VTUDdizacRHpwbkOamr7/AykinQJbgwl92LvMGZwu/constants.js\";import{useOnEnter,useOnExit}from\"https://framerusercontent.com/modules/D4TWeLfcxT6Tysr2BlYg/iZjmqdxVx1EOiM3k1FaW/useOnNavigationTargetChange.js\";import{useConstant}from\"https://framerusercontent.com/modules/ExNgrA7EJTKUPpH6vIlN/eiOrSJ2Ab5M9jPCvVwUz/useConstant.js\";import{colorTokentoValue,colorFromToken}from\"https://framerusercontent.com/modules/D2Lz5CmnNVPZFFiZXalt/QaCzPbriZBfXWZIIycFI/colorFromToken.js\";import{isMotionValue}from\"https://framerusercontent.com/modules/3mKFSGQqKHV82uOV1eBc/5fbRLvOpxZC0JOXugvwm/isMotionValue.js\";import{useUniqueClassName,randomID}from\"https://framerusercontent.com/modules/xDiQsqBGXzmMsv7AlEVy/uhunpMiNsbXxzjlXsg1y/useUniqueClassName.js\";import{getVariantControls}from\"https://framerusercontent.com/modules/ETACN5BJyFTSo0VVDJfu/NHRqowOiXkF9UwOzczF7/variantUtils.js\";import{useIsBrowserSafari}from\"https://framerusercontent.com/modules/eMBrwoqQK7h6mEeGQUH8/GuplvPJVjmxpk9zqOTcb/isBrowser.js\";import{useMultiOnChange,useOnChange}from\"https://framerusercontent.com/modules/v9AWX2URmiYsHf7GbctE/XxKAZ9KlhWqf5x1JMyyF/useOnChange.js\";import{mstoMinAndSec,secondsToMinutes}from\"https://framerusercontent.com/modules/4zHZnO5JojN1PrIbu2jm/revv9QCWpkh8lPzi2jje/time.js\";import{useAutoMotionValue}from\"https://framerusercontent.com/modules/kNDwabfjDEb3vUxkQlZS/fSIr3AOAYbGlfSPgXpYu/useAutoMotionValue.js\";import{useFontControls}from\"https://framerusercontent.com/modules/cuQH4dmpDnV8YK1mSgQX/KqRXqunFjE6ufhpc7ZRu/useFontControls.js\";import{useRenderTarget,useIsInPreview,useIsOnCanvas}from\"https://framerusercontent.com/modules/afBE9Yx1W6bY5q32qPxe/m3q7puE2tbo1S2C0s0CT/useRenderTarget.js\";import{useControlledState}from\"https://framerusercontent.com/modules/zGkoP8tPDCkoBzMdt5uq/0zFSjxIYliHxrQQnryFX/useControlledState.js\";import{usePadding,useRadius,paddingControl,borderRadiusControl}from\"https://framerusercontent.com/modules/5SM58HxZHxjjv7aLMOgQ/WXz9i6mVki0bBCrKdqB3/propUtils.js\";import{detectAutoSizingAxis}from\"https://framerusercontent.com/modules/8CkHAZatUz1UR8jNTcfD/HwbnIAZlUmQ2oTpcLkaH/detectAutoSizingAxis.js\";export{useOnEnter,useOnExit,defaultEvents,isMotionValue,colorFromToken,colorTokentoValue,localeOptions,fontControls,fontSizeOptions,emptyStateStyle,containerStyles,fontStack,useUniqueClassName,getVariantControls,useIsBrowserSafari,randomID,useConstant,useMultiOnChange,useOnChange,usePadding,useRadius,paddingControl,borderRadiusControl,mstoMinAndSec,useFontControls,secondsToMinutes,useAutoMotionValue,useRenderTarget,useIsInPreview,useControlledState,detectAutoSizingAxis,useIsOnCanvas,};\nexport const __FramerMetadata__ = {\"exports\":{\"useConstant\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"isMotionValue\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"fontControls\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"defaultEvents\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useUniqueClassName\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useMultiOnChange\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useOnChange\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useIsOnCanvas\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useOnExit\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"fontSizeOptions\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"colorTokentoValue\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useRadius\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"getVariantControls\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"colorFromToken\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"containerStyles\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"usePadding\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"fontStack\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useControlledState\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useFontControls\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useAutoMotionValue\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"emptyStateStyle\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useIsInPreview\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useIsBrowserSafari\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"detectAutoSizingAxis\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"borderRadiusControl\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"mstoMinAndSec\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"randomID\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"localeOptions\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useOnEnter\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"secondsToMinutes\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useRenderTarget\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"paddingControl\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}}}}","import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import*as React from\"react\";import{addPropertyControls,ControlType,RenderTarget,Color}from\"framer\";import{defaultEvents,fontStack}from\"https://framer.com/m/framer/default-utils.js@^0.45.0\";const colors={blue:\"#0099FF\",darkBlue:\"#0066FF\",purple:\"#8855FF\",red:\"#FF5588\",green:\"#22CC66\",yellow:\"#FFBB00\"};/**\n * STICKY\n *\n * @framerIntrinsicWidth 180\n * @framerIntrinsicHeight 180\n *\n * @framerSupportedLayoutWidth any\n * @framerSupportedLayoutHeight any\n */ export function Notes(props){const{note=\"\",shadow,color,preview,alignment,smallFont,onClick,onMouseEnter,onMouseLeave,onMouseDown,onMouseUp,useScriptFont}=props;const[baseColorString,backgroundColorString]=React.useMemo(()=>{const baseColor=Color(colors[color]);const hslColor=Color.toHsl(baseColor);hslColor.l=0.95;const baseColorString=Color(colors[color]).toValue();const backgroundColorString=Color(hslColor).toValue();return[baseColorString,backgroundColorString];},[color]);const centerAligned=alignment===\"center\";const hasContent=note.length>0;return(/*#__PURE__*/ _jsxs(\"div\",{style:{flex:1,width:\"100%\",height:\"100%\",display:\"flex\",alignItems:centerAligned?\"center\":\"flex-start\",backgroundColor:backgroundColorString,overflow:\"hidden\",paddingLeft:smallFont?15:18,paddingTop:useScriptFont?12:14,paddingBottom:useScriptFont?12:14,paddingRight:smallFont?15:18,borderRadius:8,visibility:RenderTarget.current()===RenderTarget.preview&&!preview?\"hidden\":\"visible\",fontFamily:useScriptFont?\"Nanum Pen Script\":fontStack,//@ts-ignore\nfontDisplay:\"fallback\",boxShadow:shadow?\"0 4px 10px rgba(0,0,0,0.08)\":\"none\"},onClick,onMouseEnter,onMouseLeave,onMouseDown,onMouseUp,children:[/*#__PURE__*/ _jsx(\"link\",{href:\"https://fonts.googleapis.com/css?family=Nanum+Pen+Script&display=swap\",rel:\"stylesheet\"}),/*#__PURE__*/ _jsx(\"p\",{style:{width:\"max-content\",wordBreak:\"break-word\",overflowWrap:\"break-word\",overflow:\"hidden\",whiteSpace:\"pre-wrap\",margin:0,fontSize:smallFont?useScriptFont?18:12:useScriptFont?32:24,lineHeight:smallFont?useScriptFont?1.15:1.4:useScriptFont?1.08:1.3,textAlign:alignment,color:baseColorString,display:\"-webkit-box\",opacity:hasContent?1:0.5,// lineClamp: 7,\nWebkitBoxOrient:\"vertical\"},children:hasContent?note:\"Write something...\"})]}));}Notes.defaultProps={useScriptFont:false,color:\"blue\",width:180,height:180,shadow:false};addPropertyControls(Notes,{note:{type:ControlType.String,displayTextArea:true,placeholder:`Write something… \\n\\n\\n`},color:{type:ControlType.Enum,defaultValue:\"blue\",options:Object.keys(colors),optionTitles:Object.keys(colors).map(c=>c.replace(/^\\w/,c=>c.toUpperCase()))},alignment:{title:\"Text Align\",type:ControlType.Enum,displaySegmentedControl:true,optionTitles:[\"Left\",\"Center\",\"Right\"],options:[\"left\",\"center\",\"right\"]},useScriptFont:{type:ControlType.Boolean,disabledTitle:\"Default\",enabledTitle:\"Script\",title:\"Font\"},smallFont:{type:ControlType.Boolean,disabledTitle:\"Big\",enabledTitle:\"Small\",title:\"Text Size\"},preview:{type:ControlType.Boolean,defaultValue:true,title:\"In Preview\",enabledTitle:\"Show\",disabledTitle:\"Hide\"},shadow:{type:ControlType.Boolean,defaultValue:Notes.defaultProps.shadow,title:\"Shadow\",enabledTitle:\"Show\",disabledTitle:\"Hide\"},...defaultEvents});Notes.displayName=\"Sticky Note\";\nexport const __FramerMetadata__ = {\"exports\":{\"Notes\":{\"type\":\"reactComponent\",\"name\":\"Notes\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerIntrinsicWidth\":\"180\",\"framerSupportedLayoutHeight\":\"any\",\"framerIntrinsicHeight\":\"180\",\"framerSupportedLayoutWidth\":\"any\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Notes.map"],"mappings":"iuBAA6M,IAAiJ,IAAwH,IAAgJ,IAA4H,IAA+I,IAAgI,IAA6H,IAAyI,IAA0Q,IAAgI,IAA6J,IAAsI,IAAkK,ICQlkE,SAAgB,EAAM,EAAM,CAAC,GAAK,CAAC,OAAK,GAAG,SAAO,QAAM,UAAQ,YAAU,YAAU,UAAQ,eAAa,eAAa,cAAY,YAAU,iBAAe,EAAW,CAAC,EAAgB,GAAuBA,MAAkB,CAAC,IAAM,EAAU,EAAM,EAAO,GAAO,CAAO,EAAS,EAAM,MAAM,EAAU,CAAC,EAAS,EAAE,IAAK,IAAMC,EAAgB,EAAM,EAAO,GAAO,CAAC,SAAS,CAAOC,EAAsB,EAAM,EAAS,CAAC,SAAS,CAAC,MAAM,CAACD,EAAgBC,EAAsB,EAAG,CAAC,EAAM,CAAC,CAAO,EAAc,IAAY,SAAe,EAAW,EAAK,OAAO,EAAE,OAAqB,EAAM,MAAM,CAAC,MAAM,CAAC,KAAK,EAAE,MAAM,OAAO,OAAO,OAAO,QAAQ,OAAO,WAAW,EAAc,SAAS,aAAa,gBAAgB,EAAsB,SAAS,SAAS,YAAY,EAAU,GAAG,GAAG,WAAW,EAAc,GAAG,GAAG,cAAc,EAAc,GAAG,GAAG,aAAa,EAAU,GAAG,GAAG,aAAa,EAAE,WAAW,EAAa,SAAS,GAAG,EAAa,SAAS,CAAC,EAAQ,SAAS,UAAU,WAAW,EAAc,mBAAmB,EACx/B,YAAY,WAAW,UAAU,EAAO,8BAA8B,OAAO,CAAC,UAAQ,eAAa,eAAa,cAAY,YAAU,SAAS,CAAe,EAAK,OAAO,CAAC,K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