{
  "version": 3,
  "sources": ["ssg:https://framerusercontent.com/modules/aopoeKXiCpIOlT3vWwvB/N7pGZcSHvWsShmJvLVfg/Book.js"],
  "sourcesContent": ["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";/*\n * @framerDisableUnlink\n *\n * @framerSupportedLayoutWidth any\n * @framerSupportedLayoutHeight auto\n */export default function Book(props){const{image,title,backgroundColor,textColor,font,variant,filter,widthContent}=props;const height=widthContent*5;const maxTitleHeight=height*.9;const widthImage=widthContent*4;const widthButton=widthContent+widthImage;const buttonStyle={display:\"flex\",flexDirection:\"row\",justifyContent:\"flex-start\",outline:\"none\",flexShrink:0,width:`${widthButton}px`,perspective:\"1000px\",gap:\"0px\",transition:\"all 500ms ease 0s\",willChange:\"auto\",transform:\"translateX(0px)\",marginLeft:`${calculateMargin(widthContent,variant?65:30)-widthContent}px`,marginRight:`${calculateMargin(widthImage,variant?30:81)-widthImage}px`};const contentStyle={transformStyle:\"preserve-3d\",display:\"flex\",alignItems:\"flex-start\",justifyContent:\"center\",flexShrink:0,width:`${widthContent}px`,height:`${height}px`,transformOrigin:\"right center\",backgroundColor:backgroundColor,color:textColor,transform:variant?\"rotateY(-65deg)\":\"rotateY(-30deg)\",transition:\"all 500ms ease 0s\",willChange:\"auto\",filter:\"brightness(0.8) contrast(2)\",userSelect:\"none\"};const imageContainerStyle={transformStyle:\"preserve-3d\",position:\"relative\",flexShrink:0,overflow:\"hidden\",transformOrigin:variant?\"left center\":\"left\",transform:variant?\"rotateY(30deg)\":\"rotateY(81deg)\",transition:\"all 500ms ease 0s\",willChange:\"auto\",filter:\"brightness(0.8) contrast(2)\",userSelect:\"none\"};const titleStyle={writingMode:\"vertical-rl\",marginTop:\"12px\",userSelect:\"none\",textOverflow:\"ellipsis\",whiteSpace:\"nowrap\",maxHeight:`${maxTitleHeight}px`};const filterContentStyle={pointerEvents:\"none\",position:\"fixed\",zIndex:\"50\",height:`${height}px`,width:\"100%\",opacity:\"0.4\",filter:filter?'url(\"#paper\")':\"\",userSelect:\"none\"};const filterImageStyle={pointerEvents:\"none\",position:\"fixed\",zIndex:\"50\",height:`${height}px`,width:`${widthImage}px`,opacity:\"0.4\",filter:filter?'url(\"#paper\")':\"\",userSelect:\"none\"};const shadowStyle={pointerEvents:\"none\",userSelect:\"none\",position:\"absolute\",top:\"0px\",left:\"0px\",zIndex:\"50\",height:`${height}px`,width:`${widthImage}px`,background:\"linear-gradient(to right, rgba(255, 255, 255, 0) 2px, rgba(255, 255, 255, 0.5) 3px, rgba(255, 255, 255, 0.25) 4px, rgba(255, 255, 255, 0.25) 6px, transparent 7px, transparent 9px, rgba(255, 255, 255, 0.25) 9px, transparent 12px)\"};const imageStyle={transition:\"all 500ms ease 0s\",willChange:\"auto\",width:`${widthImage}px`,height:`${height}px`,maxHeight:\"100%\",userSelect:\"none\"};return /*#__PURE__*/_jsxs(\"div\",{children:[/*#__PURE__*/_jsx(\"svg\",{style:{position:\"absolute\",inset:0,visibility:\"hidden\"},children:/*#__PURE__*/_jsx(\"defs\",{children:/*#__PURE__*/_jsxs(\"filter\",{id:\"paper\",x:\"0%\",y:\"0%\",width:\"100%\",height:\"100%\",children:[/*#__PURE__*/_jsx(\"feTurbulence\",{type:\"fractalNoise\",baseFrequency:\"1\",numOctaves:\"8\",result:\"noise\"}),/*#__PURE__*/_jsx(\"feDiffuseLighting\",{in:\"noise\",lightingColor:\"white\",surfaceScale:\"1\",result:\"diffLight\",children:/*#__PURE__*/_jsx(\"feDistantLight\",{azimuth:\"45\",elevation:\"35\"})})]})})}),/*#__PURE__*/_jsxs(\"div\",{style:buttonStyle,children:[/*#__PURE__*/_jsxs(\"div\",{style:contentStyle,children:[/*#__PURE__*/_jsx(\"span\",{style:filterContentStyle}),/*#__PURE__*/_jsx(\"h2\",{style:{...font,...titleStyle},children:title})]}),/*#__PURE__*/_jsxs(\"div\",{style:imageContainerStyle,children:[/*#__PURE__*/_jsx(\"span\",{style:filterImageStyle}),/*#__PURE__*/_jsx(\"span\",{style:shadowStyle}),/*#__PURE__*/_jsx(\"img\",{alt:image&&image.alt?image.alt:defaultProperty.image.alt,src:image?image.src:defaultProperty.image.src,style:imageStyle})]})]})]});}addPropertyControls(Book,{image:{type:ControlType.ResponsiveImage,title:\"Image\"},title:{type:ControlType.String,title:\"Title\",defaultValue:\"Think And Grow Rich\"},backgroundColor:{type:ControlType.Color,title:\"Background Color\",defaultValue:\"rgb(255, 202, 126)\"},textColor:{type:ControlType.Color,title:\"Text Color\",defaultValue:\"rgb(8, 21, 59)\"},font:{type:ControlType.Font,title:\"Font\",defaultValue:\"Inter\",controls:\"extended\"},variant:{type:ControlType.Boolean,title:\"Variant\",enabledTitle:\"Open\",disabledTitle:\"Close\"},filter:{type:ControlType.Boolean,title:\"Filter\",enabledTitle:\"With\",disabledTitle:\"Without\"},widthContent:{type:ControlType.Number,title:\"Size\",defaultValue:50,description:\"More components at [Framer University](https://frameruni.link/cc).\"}});const defaultProperty={image:{src:\"https://framerusercontent.com/images/l5lP01syB8XZqU1kYdWFfQ5fGX0.png\",srcSet:\"https://framerusercontent.com/images/l5lP01syB8XZqU1kYdWFfQ5fGX0.png 401w\",alt:\"Think And Grow Rich\"}};Book.displayName=\"3D Book\";const calculateMargin=(width,rotationAngle)=>{var radians=rotationAngle*Math.PI/180;var horizontalDisplacement=width*Math.cos(radians);return horizontalDisplacement;};\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"Book\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerDisableUnlink\":\"*\",\"framerSupportedLayoutHeight\":\"auto\",\"framerSupportedLayoutWidth\":\"any\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Book.map"],
  "mappings": "gEAKkB,SAARA,EAAsBC,EAAM,CAAC,GAAK,CAAC,MAAAC,EAAM,MAAAC,EAAM,gBAAAC,EAAgB,UAAAC,EAAU,KAAAC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EAAK,MAAM,CAAC,IAAIrB,GAAOA,EAAM,IAAIA,EAAM,IAAIsB,EAAgB,MAAM,IAAI,IAAItB,EAAMA,EAAM,IAAIsB,EAAgB,MAAM,IAAI,MAAMH,CAAU,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAE,CAACI,EAAoBzB,EAAK,CAAC,MAAM,CAAC,KAAK0B,EAAY,gBAAgB,MAAM,OAAO,EAAE,MAAM,CAAC,KAAKA,EAAY,OAAO,MAAM,QAAQ,aAAa,qBAAqB,EAAE,gBAAgB,CAAC,KAAKA,EAAY,MAAM,MAAM,mBAAmB,aAAa,oBAAoB,EAAE,UAAU,CAAC,KAAKA,EAAY,MAAM,MAAM,aAAa,aAAa,gBAAgB,EAAE,KAAK,CAAC,KAAKA,EAAY,KAAK,MAAM,OAAO,aAAa,QAAQ,SAAS,UAAU,EAAE,QAAQ,CAAC,KAAKA,EAAY,QAAQ,MAAM,UAAU,aAAa,OAAO,cAAc,OAAO,EAAE,OAAO,CAAC,KAAKA,EAAY,QAAQ,MAAM,SAAS,aAAa,OAAO,cAAc,SAAS,EAAE,aAAa,CAAC,KAAKA,EAAY,OAAO,MAAM,OAAO,aAAa,GAAG,YAAY,oEAAoE,CAAC,CAAC,EAAE,IAAMF,EAAgB,CAAC,MAAM,CAAC,IAAI,uEAAuE,OAAO,4EAA4E,IAAI,qBAAqB,CAAC,EAAExB,EAAK,YAAY,UAAU,IAAMc,EAAgB,CAACa,EAAMC,IAAgB,CAAC,IAAIC,EAAQD,EAAc,KAAK,GAAG,IAAQE,EAAuBH,EAAM,KAAK,IAAIE,CAAO,EAAE,OAAOC,CAAuB",
  "names": ["Book", "props", "image", "title", "backgroundColor", "textColor", "font", "variant", "filter", "widthContent", "height", "maxTitleHeight", "widthImage", "buttonStyle", "calculateMargin", "contentStyle", "imageContainerStyle", "titleStyle", "filterContentStyle", "filterImageStyle", "shadowStyle", "imageStyle", "u", "p", "defaultProperty", "addPropertyControls", "ControlType", "width", "rotationAngle", "radians", "horizontalDisplacement"]
}
