{"version":3,"file":"BlogCard.BtnQ1snf.mjs","names":["useState"],"sources":["https:/framerusercontent.com/modules/Y3jJ5NtISYtfMtas7OVv/tBsr17z1BtOlgQriS07F/BlogCard.js"],"sourcesContent":["// Blog Card — code component for the Rebound Template (Framer)\n// Reusable card for the Blog collection grid (`/blog`): a rounded cover\n// photo on top, with a title + publish date stacked below it, matching the\n// native layers on the live Blog page (blog-link-block / blog-cover /\n// blog-card-title-wrap / .link / small-paragraph).\n//\n// The whole card is ONE link (source uses two separate <a> — one around the\n// photo, one around the title — but per this request the card behaves as a\n// single clickable unit, same \"one link, one hover state\" approach as\n// PlayerCard.tsx).\n//\n// Title: H5-equivalent (20px / source weight 500 -> Framer 600 per project\n// font-weight+1 rule / line-height 1.2em / letter-spacing -0.02em), Dark\n// Primary by default.\n// Date: Body-16px-equivalent (16px / weight 500 / line-height 1.5em /\n// letter-spacing -0.28px, matching source \".small-paragraph\"), Paragraph\n// gray, static (no hover).\n//\n// Image height: source CSS base rule is 240px, but the live desktop render\n// (wider viewport) measures 280px — same discrepancy as other cards where\n// Framer's per-breakpoint values aren't readable/writable via MCP (see\n// framer-mcp-breakpoint-override-limitation.md). Exposed as an editable\n// Number control (default 280) so Tablet/Phone variants can be set by hand\n// in Framer's own UI.\n//\n// Decorative SVG texture overlay from the source (\".image-overlay\") is\n// intentionally not reproduced — same call as ProgramGridCard.tsx, the\n// texture isn't visually significant.\n//\n// Hover (per request, 2026-08-25): a single onMouseEnter/Leave on the whole\n// card drives two independent effects at once, same \"scale on the inner\n// <img>, never the overflow:hidden wrapper\" technique as Coach Card /\n// Player Card:\n// 1) Cover photo scales 1 -> 1.08 inside its fixed-height frame (the photo\n//    wrapper is already overflow:hidden with a fixed borderRadius, so the\n//    photo grows without bleeding past the rounded corners).\n// 2) Title color transitions Title Color -> Title Color (Hover), default\n//    Dark Primary (rgb(5, 36, 70)) -> Primary (rgb(0, 113, 235)) — the same\n//    heading hover pattern already used on Coach Card / Player Card.\n//\n// Entrance animation: the project's standard appear animation (same as\n// PrimaryButton.tsx / CoachCard.tsx / PlayerCard.tsx) — opacity 0->1,\n// y 15->0, ease-in-out, duration 0.6s, delay 0.1s, plays once at 30% in\n// view, with the usual RenderTarget.canvas guard so the card stays fully\n// visible while editing. Toggle via \"Appear Animation\".\nimport{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{useState,startTransition}from\"react\";import{addPropertyControls,ControlType,RenderTarget}from\"framer\";import{motion}from\"framer-motion\";const DEFAULT_IMAGE={src:\"https://framerusercontent.com/images/zt41lvtVdEUJAOkKMTBbwMIAw.png\",alt:\"Blog post cover\"};// Framer passes a value connected to a Color Style as an object\n// { value: \"#...\" } instead of a plain string. Same helper as\n// PrimaryButton.tsx / CoachCard.tsx / PlayerCard.tsx / ProgramGridCard.tsx.\nfunction parseToken(value){if(value&&typeof value===\"object\"&&\"value\"in value){return value.value;}return value;}/**\n * Blog Card\n *\n * @framerSupportedLayoutWidth any-prefer-fixed\n * @framerSupportedLayoutHeight auto\n */export default function BlogCard(props){const{link,openInNewTab=false,image=DEFAULT_IMAGE,imageHeight=280,title=\"Training vs playing: finding the balance\",titleColor=\"rgb(5, 36, 70)\",titleHoverColor=\"rgb(0, 113, 235)\",date=\"March 19, 2026\",dateColor=\"rgb(88, 88, 88)\",appearAnimation=true,style}=props;const[isHovered,setIsHovered]=useState(false);function handleHoverStart(){startTransition(()=>setIsHovered(true));}function handleHoverEnd(){startTransition(()=>setIsHovered(false));}const imageSrc=image?.src||DEFAULT_IMAGE.src;const imageSrcSet=image?.srcSet;const imageAlt=image?.alt||title;const hasLink=Boolean(link);const resolvedTitleColor=parseToken(titleColor);const resolvedTitleHoverColor=parseToken(titleHoverColor);const resolvedDateColor=parseToken(dateColor);// Same canvas-safety fix as AppearAnimation.tsx / CoachCard.tsx /\n// PlayerCard.tsx: \"scrolls into view\" never triggers on the static\n// Framer canvas, so an opacity:0 initial state would just render the\n// card invisible while editing. Only animate outside the canvas editor.\nconst isCanvas=RenderTarget.current()===RenderTarget.canvas;const showAppearAnimation=!isCanvas&&appearAnimation;return /*#__PURE__*/_jsxs(motion.a,{initial:showAppearAnimation?{opacity:0,y:15,scale:1,rotate:0,skewX:0,skewY:0}:undefined,whileInView:showAppearAnimation?{opacity:1,y:0,scale:1,rotate:0,skewX:0,skewY:0}:undefined,viewport:showAppearAnimation?{once:true,amount:.3}:undefined,transition:showAppearAnimation?{duration:.6,delay:.1,ease:\"easeInOut\"}:undefined,href:hasLink?link:undefined,target:hasLink&&openInNewTab?\"_blank\":undefined,rel:hasLink&&openInNewTab?\"noopener noreferrer\":undefined,role:hasLink?undefined:\"button\",tabIndex:hasLink?undefined:0,onMouseEnter:handleHoverStart,onMouseLeave:handleHoverEnd,style:{position:\"relative\",display:\"flex\",flexDirection:\"column\",width:\"100%\",textDecoration:\"none\",cursor:hasLink?\"pointer\":\"default\",...style},children:[/*#__PURE__*/_jsx(\"div\",{style:{position:\"relative\",width:\"100%\",height:imageHeight,borderRadius:10,overflow:\"hidden\",flexShrink:0},children:/*#__PURE__*/_jsx(\"img\",{src:imageSrc,srcSet:imageSrcSet,alt:imageAlt,style:{position:\"absolute\",inset:0,width:\"100%\",height:\"100%\",objectFit:\"cover\",transform:isHovered?\"scale(1.08)\":\"scale(1)\",transition:\"transform 0.4s ease\"}})}),/*#__PURE__*/_jsxs(\"div\",{style:{display:\"flex\",flexDirection:\"column\",gap:6,paddingTop:20},children:[/*#__PURE__*/_jsx(\"div\",{style:{fontFamily:'\"Instrument Sans\", sans-serif',fontSize:20,fontWeight:600,lineHeight:\"1.2em\",letterSpacing:\"-0.02em\",color:isHovered?resolvedTitleHoverColor:resolvedTitleColor,transition:\"color 0.3s ease\"},children:title}),/*#__PURE__*/_jsx(\"p\",{style:{margin:0,fontFamily:'\"Instrument Sans\", sans-serif',fontSize:16,fontWeight:500,lineHeight:\"1.5em\",letterSpacing:\"-0.28px\",color:resolvedDateColor},children:date})]})]});}addPropertyControls(BlogCard,{link:{type:ControlType.Link,title:\"Link\"},openInNewTab:{type:ControlType.Boolean,title:\"Open In New Tab\",defaultValue:false,enabledTitle:\"New Tab\",disabledTitle:\"Same Tab\"},image:{type:ControlType.ResponsiveImage,title:\"Photo\"},imageHeight:{type:ControlType.Number,title:\"Image Height\",defaultValue:280,min:150,max:600,step:10,unit:\"px\",displayStepper:true},title:{type:ControlType.String,title:\"Title\",defaultValue:\"Training vs playing: finding the balance\",placeholder:\"Post title\"},titleColor:{type:ControlType.Color,title:\"Title Color\",defaultValue:\"rgb(5, 36, 70)\"},titleHoverColor:{type:ControlType.Color,title:\"Title Color (Hover)\",defaultValue:\"rgb(0, 113, 235)\"},date:{type:ControlType.String,title:\"Date\",defaultValue:\"March 19, 2026\",placeholder:\"Publish date\"},dateColor:{type:ControlType.Color,title:\"Date Color\",defaultValue:\"rgb(88, 88, 88)\"},appearAnimation:{type:ControlType.Boolean,title:\"Appear Animation\",defaultValue:true,enabledTitle:\"On\",disabledTitle:\"Off\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"BlogCard\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutHeight\":\"auto\",\"framerSupportedLayoutWidth\":\"any-prefer-fixed\",\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./BlogCard.map"],"mappings":"gPAgDA,SAAS,EAAW,EAAM,CAAyE,OAArE,GAAO,OAAO,GAAQ,UAAU,UAAU,EAAc,EAAM,MAAc,CAAM,CAK7G,SAAwB,EAAS,EAAM,CAAC,GAAK,CAAC,OAAK,eAAa,GAAM,QAAM,EAAc,cAAY,IAAI,QAAM,2CAA2C,aAAW,iBAAiB,kBAAgB,mBAAmB,OAAK,iBAAiB,YAAU,kBAAkB,kBAAgB,GAAK,SAAO,EAAW,CAAC,EAAU,GAAcA,EAAS,EAAK,EAAE,SAAS,GAAkB,CAAC,MAAoB,EAAa,EAAI,CAAC,CAAE,CAAC,SAAS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